From 7ee74555812522d40f297865a673320ebe8c45a3 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 8 Oct 2025 13:58:13 +0000 Subject: [PATCH] Deploy to GitHub pages --- .nojekyll | 0 404.html | 276 ++ CNAME | 1 + bindings-cpp/index.html | 681 ++++ bindings/index.html | 402 +++ c-api/functions/index.html | 2991 +++++++++++++++++ c-api/introduction/index.html | 437 +++ coding-style-guide/index.html | 592 ++++ features/basic/index.html | 545 +++ features/debugging/index.html | 465 +++ features/differences/index.html | 385 +++ features/profiling/index.html | 374 +++ features/threading/index.html | 490 +++ features/ub/index.html | 346 ++ gsoc2024/guide/index.html | 407 +++ gsoc2024/ideas/index.html | 383 +++ gsoc2025/guide/index.html | 407 +++ gsoc2025/ideas/index.html | 369 ++ index.html | 407 +++ license/index.html | 356 ++ modules/array2d/index.html | 517 +++ modules/base64/index.html | 353 ++ modules/bisect/index.html | 450 +++ modules/cmath/index.html | 537 +++ modules/collections/index.html | 537 +++ modules/colorcvt/index.html | 357 ++ modules/cute_png/index.html | 371 ++ modules/dataclasses/index.html | 437 +++ modules/datetime/index.html | 494 +++ modules/easing/index.html | 373 ++ modules/enum/index.html | 360 ++ modules/functools/index.html | 431 +++ modules/gc/index.html | 367 ++ modules/heapq/index.html | 469 +++ modules/importlib/index.html | 346 ++ modules/json/index.html | 353 ++ modules/libhv/index.html | 486 +++ modules/lz4/index.html | 377 +++ modules/math/index.html | 562 ++++ modules/operator/index.html | 578 ++++ modules/pickle/index.html | 376 +++ modules/pkpy/index.html | 420 +++ modules/random/index.html | 388 +++ modules/sys/index.html | 382 +++ modules/time/index.html | 360 ++ modules/traceback/index.html | 353 ++ modules/typing/index.html | 406 +++ modules/unicodedata/index.html | 354 ++ modules/vmath/index.html | 573 ++++ performance/index.html | 533 +++ quick-start/index.html | 468 +++ resources/css/retype.css | 5 + resources/fonts/Inter-italic-latin-var.woff2 | Bin 0 -> 56536 bytes resources/fonts/Inter-roman-latin-var.woff2 | Bin 0 -> 52468 bytes resources/js/config.js | 1 + resources/js/lunr.js | 39 + resources/js/mermaid.js | 4 + resources/js/prism.js | 5 + resources/js/retype.js | 27 + resources/js/search.json | 1 + resources/lunr.js.LICENSE.txt | 61 + resources/mermaid.js.LICENSE.txt | 26 + resources/prism.js.LICENSE.txt | 8 + resources/retype.LICENSE.txt | 248 ++ resources/retype.js.LICENSE.txt | 28 + robots.txt | 4 + sitemap.xml.gz | Bin 0 -> 631 bytes static/debugger/debugger_demo.png | Bin 0 -> 595912 bytes static/debugger/launch_json.png | Bin 0 -> 269646 bytes static/logo.png | Bin 0 -> 25653 bytes static/profiler_demo.png | Bin 0 -> 529960 bytes static/web/index.html | 310 ++ static/web/lib/pocketpy.js | 1 + static/web/lib/pocketpy.wasm | Bin 0 -> 381471 bytes static/web/static/codejar/codejar.js | 423 +++ static/web/static/codejar/linenumbers.js | 60 + .../highlight.js/github-dark-dimmed.min.css | 11 + .../web/static/highlight.js/highlight.min.js | 1152 +++++++ 78 files changed, 26096 insertions(+) create mode 100644 .nojekyll create mode 100644 404.html create mode 100644 CNAME create mode 100644 bindings-cpp/index.html create mode 100644 bindings/index.html create mode 100644 c-api/functions/index.html create mode 100644 c-api/introduction/index.html create mode 100644 coding-style-guide/index.html create mode 100644 features/basic/index.html create mode 100644 features/debugging/index.html create mode 100644 features/differences/index.html create mode 100644 features/profiling/index.html create mode 100644 features/threading/index.html create mode 100644 features/ub/index.html create mode 100644 gsoc2024/guide/index.html create mode 100644 gsoc2024/ideas/index.html create mode 100644 gsoc2025/guide/index.html create mode 100644 gsoc2025/ideas/index.html create mode 100644 index.html create mode 100644 license/index.html create mode 100644 modules/array2d/index.html create mode 100644 modules/base64/index.html create mode 100644 modules/bisect/index.html create mode 100644 modules/cmath/index.html create mode 100644 modules/collections/index.html create mode 100644 modules/colorcvt/index.html create mode 100644 modules/cute_png/index.html create mode 100644 modules/dataclasses/index.html create mode 100644 modules/datetime/index.html create mode 100644 modules/easing/index.html create mode 100644 modules/enum/index.html create mode 100644 modules/functools/index.html create mode 100644 modules/gc/index.html create mode 100644 modules/heapq/index.html create mode 100644 modules/importlib/index.html create mode 100644 modules/json/index.html create mode 100644 modules/libhv/index.html create mode 100644 modules/lz4/index.html create mode 100644 modules/math/index.html create mode 100644 modules/operator/index.html create mode 100644 modules/pickle/index.html create mode 100644 modules/pkpy/index.html create mode 100644 modules/random/index.html create mode 100644 modules/sys/index.html create mode 100644 modules/time/index.html create mode 100644 modules/traceback/index.html create mode 100644 modules/typing/index.html create mode 100644 modules/unicodedata/index.html create mode 100644 modules/vmath/index.html create mode 100644 performance/index.html create mode 100644 quick-start/index.html create mode 100644 resources/css/retype.css create mode 100644 resources/fonts/Inter-italic-latin-var.woff2 create mode 100644 resources/fonts/Inter-roman-latin-var.woff2 create mode 100644 resources/js/config.js create mode 100644 resources/js/lunr.js create mode 100644 resources/js/mermaid.js create mode 100644 resources/js/prism.js create mode 100644 resources/js/retype.js create mode 100644 resources/js/search.json create mode 100644 resources/lunr.js.LICENSE.txt create mode 100644 resources/mermaid.js.LICENSE.txt create mode 100644 resources/prism.js.LICENSE.txt create mode 100644 resources/retype.LICENSE.txt create mode 100644 resources/retype.js.LICENSE.txt create mode 100644 robots.txt create mode 100644 sitemap.xml.gz create mode 100644 static/debugger/debugger_demo.png create mode 100644 static/debugger/launch_json.png create mode 100644 static/logo.png create mode 100644 static/profiler_demo.png create mode 100644 static/web/index.html create mode 100644 static/web/lib/pocketpy.js create mode 100755 static/web/lib/pocketpy.wasm create mode 100644 static/web/static/codejar/codejar.js create mode 100644 static/web/static/codejar/linenumbers.js create mode 100644 static/web/static/highlight.js/github-dark-dimmed.min.css create mode 100644 static/web/static/highlight.js/highlight.min.js diff --git a/.nojekyll b/.nojekyll new file mode 100644 index 00000000..e69de29b diff --git a/404.html b/404.html new file mode 100644 index 00000000..d2fd4d0c --- /dev/null +++ b/404.html @@ -0,0 +1,276 @@ + + + + + + + + + + + + Not Found | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+ +
+

Oops! The page you’re looking for doesn’t exist.

+

You may have mistyped the address or the page may have been moved.

+ Go to homepage +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/CNAME b/CNAME new file mode 100644 index 00000000..7845b750 --- /dev/null +++ b/CNAME @@ -0,0 +1 @@ +pocketpy.dev \ No newline at end of file diff --git a/bindings-cpp/index.html b/bindings-cpp/index.html new file mode 100644 index 00000000..1d3eeead --- /dev/null +++ b/bindings-cpp/index.html @@ -0,0 +1,681 @@ + + + + + + + + + + + + Write C++ Bindings | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Write C++ Bindings +

+
+ +

+ # + Quick Start +

+
+

pkpy provides a pybind11 compatible layer which allows users to do convenient bindings.

+

To begin with, use py::scoped_interpreter guard{} to start the interpreter before using any Python objects. +Or explicitly call py::interpreter::initialize() and py::interpreter::finalize().

+ +

+ # + module +

+
+
+
#include <pybind11/pybind11.h>
+namespace py = pybind11;
+
+PYBIND11_EMBEDDED_MODULE(example, m) {
+    m.def("add", [](int a, int b) {
+        return a + b;
+    });
+
+    auto math = m.def_submodule("math");
+}
+
+ +

+ # + function +

+
+
+
int add(int a, int b) { return a + b; }
+
+int add(int a, int b, int c) { return a + b + c; }
+
+void register_function(py::module_& m)
+{
+    m.def("add", py::overload_cast<int, int>(&add));
+
+    // support function overload
+    m.def("add", py::overload_cast<int, int, int>(&add));
+
+    // bind with default arguments
+    m.def("sub", [](int a, int b) { 
+        return a - b; 
+    }, py::arg("a") = 1, py::arg("b") = 2);
+
+    // bind *args
+    m.def("add", [](py::args args) {
+        int sum = 0;
+        for (auto& arg : args) {
+            sum += arg.cast<int>();
+        }
+        return sum;
+    });
+
+    // bind **kwargs
+    m.def("add", [](py::kwargs kwargs) {
+        int sum = 0;
+        for (auto item : kwargs) {
+            sum += item.second.cast<int>();
+        }
+        return sum;
+    });
+}
+
+ +

+ # + class +

+
+
+
struct Point
+{
+    const int x;
+    int y;
+
+public:
+    Point() : x(0), y(0) {}
+
+    Point(int x, int y) : x(x), y(y) {}
+
+    Point(const Point& p) : x(p.x), y(p.y) {}
+
+    std::string stringfy() const { 
+        return "(" + std::to_string(x) + ", " + std::to_string(y) + ")"; 
+    }
+};
+
+struct Point3D : Point
+{
+private:
+    int z;
+
+public:
+    Point3D(int x, int y, int z) : Point(x, y), z(z) {}
+
+    int get_z() const { return z; }
+
+    void set_z(int z) { this->z = z; }
+};
+
+void bind_class(py::module_& m)
+{
+    py::class_<Point>(m, "Point")
+        .def(py::init<>())
+        .def(py::init<int, int>())
+        .def(py::init<const Point&>())
+        .def_readonly("x", &Point::x)
+        .def_readwrite("y", &Point::y)
+        .def("__str__", &Point::stringfy);
+
+    // only support single inheritance
+    py::class_<Point3D, Point>(m, "Point3D", py::dynamic_attr())
+        .def(py::init<int, int, int>())
+        .def_property("z", &Point3D::get_z, &Point3D::set_z);
+
+    // dynamic_attr will enable the dict of bound class
+}
+
+ +

+ # + operators +

+
+
+
#include <pybind11/operators.h>
+namespace py = pybind11;
+
+struct Int {
+    int value;
+
+    Int(int value) : value(value) {}
+
+    Int operator+(const Int& other) const {
+        return Int(value + other.value);
+    }
+
+    Int operator-(const Int& other) const {
+        return Int(value - other.value);
+    }
+
+    bool operator==(const Int& other) const {
+        return value == other.value;
+    }
+
+    bool operator!=(const Int& other) const {
+        return value != other.value;
+    }
+};
+
+void bind_operators(py::module_& m)
+{
+    py::class_<Int>(m, "Int")
+        .def(py::init<int>())
+        .def(py::self + py::self)
+        .def(py::self - py::self)
+        .def(py::self == py::self)
+        .def(py::self != py::self);
+        // other operators are similar
+}
+
+ +

+ # + py::object +

+
+

py::object is just simple wrapper around PyVar. It supports some convenient methods to interact with Python objects.

+

here are some common methods:

+
+
obj.attr("x"); // access attribute
+obj[1]; // access item
+
+obj.is_none(); // same as obj is None in Python
+obj.is(obj2); // same as obj is obj2 in Python
+
+// operators
+obj + obj2; // same as obj + obj2 in Python
+// ...
+obj == obj2; // same as obj == obj2 in Python
+// ...
+
+obj(...); // same as obj.__call__(...)
+
+py::cast(obj); // cast to Python object
+obj.cast<T>; // cast to C++ type
+
+py::type::of(obj); // get type of obj
+py::type::of<T>(); // get type of T, if T is registered
+
+

you can also create some builtin objects with their according wrappers:

+
+
py::bool_ b = {true};
+py::int_ i = {1};
+py::float_ f = {1.0};
+py::str s = {"hello"};
+py::list l = {1, 2, 3};
+py::tuple t = {1, 2, 3};
+// ...
+
+ +

+ # + More Examples +

+
+

More examples please see the test folder in the GSoC repository. All tested features are supported.

+ +

+ # + Limits and Comparison +

+
+

This is a feature list of pybind11 for pocketpy. It lists all completed and pending features. It also lists the features that cannot be implemented in the current version of pocketpy.

+ +

+ # + Function +

+
+
    +
  • Function overloading
  • +
  • Return value policy
  • +
  • is_prepend
  • +
  • *args and **kwargs
  • +
  • Keep-alive
  • +
  • Call Guard
  • +
  • Default arguments
  • +
  • Keyword-Only arguments
  • +
  • Positional-Only arguments
  • +
  • Allow/Prohibiting None arguments
  • +
+ +

+ # + Class +

+
+
    +
  • Creating bindings for a custom type
  • +
  • Binding lambda functions
  • +
  • Dynamic attributes
  • +
  • Inheritance and automatic downcasting
  • +
  • Enumerations and internal types
  • +
  • Instance and static fields
  • +
+
+

Binding static fields may never be implemented in pocketpy because it requires a metaclass, which is a heavy and infrequently used feature.

+
+ +

+ # + Exceptions +

+
+

Need further discussion.

+ +

+ # + Smart pointers +

+
+
    +
  • std::shared_ptr
  • +
  • std::unique_ptr
  • +
  • Custom smart pointers
  • +
+ +

+ # + Type conversions +

+
+
    +
  • Python built-in types
  • +
  • STL Containers
  • +
  • Functional
  • +
  • Chrono
  • +
+ +

+ # + Python C++ interface +

+
+

Need further discussion.

+
    +
  • object
  • +
  • none
  • +
  • type
  • +
  • bool_
  • +
  • int_
  • +
  • float_
  • +
  • str
  • +
  • bytes
  • +
  • bytearray
  • +
  • tuple
  • +
  • list
  • +
  • set
  • +
  • dict
  • +
  • slice
  • +
  • iterable
  • +
  • iterator
  • +
  • function
  • +
  • buffer
  • +
  • memoryview
  • +
  • capsule
  • +
+ +

+ # + Miscellaneous +

+
+
    +
  • Global Interpreter Lock (GIL)
  • +
  • Binding sequence data types, iterators, the slicing protocol, etc.
  • +
  • Convenient operators binding
  • +
+ +

+ # + Differences between CPython and pocketpy +

+
+
    +
  • only add, sub and mul have corresponding right versions in pocketpy. So if you bind int() >> py::self, it will has no effect in pocketpy.

    +
  • +
  • __new__ and __del__ are not supported in pocketpy.

    +
  • +
  • in-place operators, such as +=, -=, *=, etc., are not supported in pocketpy.

    +
  • +
  • the return value of globals is immutable in pocketpy.

    +
  • +
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/bindings/index.html b/bindings/index.html new file mode 100644 index 00000000..f499a61c --- /dev/null +++ b/bindings/index.html @@ -0,0 +1,402 @@ + + + + + + + + + + + + Write C Bindings | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Write C Bindings +

+
+

In order to use a C/C++ library in python, you need to write bindings for it.

+

pkpy uses an universal signature to wrap a C function pointer as a python function or method, i.e py_CFunction.

+
+
typedef bool (*py_CFunction)(int argc, py_Ref argv);
+
+
    +
  • argc is the number of arguments passed to the function.
  • +
  • argv is the pointer to the first argument.
  • +
+

If successful, the function should return true and set the return value in py_retval(). In case there is no return value, you should use py_newnone(py_retval()). +If an error occurs, the function should raise an exception and return false.

+ +

+ # + Steps +

+
+

Say you have a function add that takes two integers and returns their sum.

+
+
int add(int a, int b) {
+    return a + b;
+}
+
+

Here is how you can write the binding for it:

+
+
// 1. Define a wrapper function with the signature `py_CFunction`.
+bool py_add(int argc, py_Ref argv) {
+    // 2. Check the number of arguments.
+    PY_CHECK_ARGC(2);
+    // 3. Check the type of arguments.
+    PY_CHECK_ARG_TYPE(0, tp_int);
+    PY_CHECK_ARG_TYPE(1, tp_int);
+    // 4. Convert the arguments into C types.
+    int _0 = py_toint(py_arg(0));
+    int _1 = py_toint(py_arg(1));
+    // 5. Call the original function.
+    int res = add(_0, _1);
+    // 6. Set the return value.
+    py_newint(py_retval(), res);
+    // 7. Return `true`.
+    return true;
+}
+
+

Once you have the wrapper function, you can bind it to a python module via py_bindfunc.

+
+
py_GlobalRef mod = py_getmodule("__main__");
+py_bindfunc(mod, "add", py_add);
+
+

Alternatively, you can use py_bind with a signature, which allows you to specify some default values.

+
+
py_GlobalRef mod = py_getmodule("__main__");
+py_bind(mod, "add(a, b=1)", py_add);
+
+

See also:

+ + + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/c-api/functions/index.html b/c-api/functions/index.html new file mode 100644 index 00000000..6afdc02e --- /dev/null +++ b/c-api/functions/index.html @@ -0,0 +1,2991 @@ + + + + + + + + + + + + Functions | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Functions +

+
+ +

+ # + py_initialize +

+
+
+
/// Initialize pocketpy and the default VM.
+PK_API void py_initialize();
+
+ +

+ # + py_finalize +

+
+
+
/// Finalize pocketpy and free all VMs. This opearation is irreversible.
+/// After this call, you cannot use any function from this header anymore.
+PK_API void py_finalize();
+
+ +

+ # + py_currentvm +

+
+
+
/// Get the current VM index.
+PK_API int py_currentvm();
+
+ +

+ # + py_switchvm +

+
+
+
/// Switch to a VM.
+/// @param index index of the VM ranging from 0 to 16 (exclusive). `0` is the default VM.
+PK_API void py_switchvm(int index);
+
+ +

+ # + py_resetvm +

+
+
+
/// Reset the current VM.
+PK_API void py_resetvm();
+
+ +

+ # + py_resetallvm +

+
+
+
/// Reset All VMs.
+PK_API void py_resetallvm();
+
+ +

+ # + py_getvmctx +

+
+
+
/// Get the current VM context. This is used for user-defined data.
+PK_API void* py_getvmctx();
+
+ +

+ # + py_setvmctx +

+
+
+
/// Set the current VM context. This is used for user-defined data.
+PK_API void py_setvmctx(void* ctx);
+
+ +

+ # + py_callbacks +

+
+
+
/// Setup the callbacks for the current VM.
+PK_API py_Callbacks* py_callbacks();
+
+ +

+ # + py_sys_setargv +

+
+
+
/// Set `sys.argv`. Used for storing command-line arguments.
+PK_API void py_sys_setargv(int argc, char** argv);
+
+ +

+ # + py_sys_settrace +

+
+
+
/// Set the trace function for the current VM.
+PK_API void py_sys_settrace(py_TraceFunc func, bool reset);
+
+ +

+ # + py_gc_collect +

+
+
+
/// Invoke the garbage collector.
+PK_API int py_gc_collect();
+
+ +

+ # + py_malloc +

+
+
+
/// Wrapper for `PK_MALLOC(size)`.
+PK_API void* py_malloc(size_t size);
+
+ +

+ # + py_realloc +

+
+
+
/// Wrapper for `PK_REALLOC(ptr, size)`.
+PK_API void* py_realloc(void* ptr, size_t size);
+
+ +

+ # + py_free +

+
+
+
/// Wrapper for `PK_FREE(ptr)`.
+PK_API void py_free(void* ptr);
+
+ +

+ # + py_True +

+
+
+
/// A shorthand for `True`.
+PK_API py_GlobalRef py_True();
+
+ +

+ # + py_False +

+
+
+
/// A shorthand for `False`.
+PK_API py_GlobalRef py_False();
+
+ +

+ # + py_None +

+
+
+
/// A shorthand for `None`.
+PK_API py_GlobalRef py_None();
+
+ +

+ # + py_NIL +

+
+
+
/// A shorthand for `nil`. `nil` is not a valid python object.
+PK_API py_GlobalRef py_NIL();
+
+ +

+ # + py_Frame_newglobals +

+
+
+
/// Python equivalent to `globals()` with respect to the given frame.
+PK_API void py_Frame_newglobals(py_Frame* frame, py_OutRef out);
+
+ +

+ # + py_Frame_newlocals +

+
+
+
/// Python equivalent to `locals()` with respect to the given frame.
+PK_API void py_Frame_newlocals(py_Frame* frame, py_OutRef out);
+
+ +

+ # + py_Frame_function +

+
+
+
/// Get the function object of the frame.
+/// Returns `NULL` if not available.
+PK_API py_StackRef py_Frame_function(py_Frame* frame);
+
+ +

+ # + py_compile + raise + + return + +

+
+
+
/// Compile a source string into a code object.
+/// Use python's `exec()` or `eval()` to execute it.
+PK_API bool py_compile(const char* source,
+                       const char* filename,
+                       enum py_CompileMode mode,
+                       bool is_dynamic);
+
+ +

+ # + py_exec + raise + + return + +

+
+
+
/// Run a source string.
+/// @param source source string.
+/// @param filename filename (for error messages).
+/// @param mode compile mode. Use `EXEC_MODE` for statements `EVAL_MODE` for expressions.
+/// @param module target module. Use NULL for the main module.
+/// @return `true` if the execution is successful or `false` if an exception is raised.
+PK_API bool py_exec(const char* source,
+                    const char* filename,
+                    enum py_CompileMode mode,
+                    py_Ref module);
+
+ +

+ # + py_eval + raise + + return + +

+
+
+
/// Evaluate a source string. Equivalent to `py_exec(source, "<string>", EVAL_MODE, module)`.
+PK_API bool py_eval(const char* source, py_Ref module);
+
+ +

+ # + py_smartexec + raise + + return + +

+
+
+
/// Run a source string with smart interpretation.
+/// Example:
+/// `py_newstr(py_r0(), "abc");`
+/// `py_newint(py_r1(), 123);`
+/// `py_smartexec("print(_0, _1)", NULL, py_r0(), py_r1());`
+/// `// "abc 123" will be printed`.
+PK_API bool py_smartexec(const char* source, py_Ref module, ...);
+
+ +

+ # + py_smarteval + raise + + return + +

+
+
+
/// Evaluate a source string with smart interpretation.
+/// Example:
+/// `py_newstr(py_r0(), "abc");`
+/// `py_smarteval("len(_)", NULL, py_r0());`
+/// `int res = py_toint(py_retval());`
+/// `// res will be 3`.
+PK_API bool py_smarteval(const char* source, py_Ref module, ...);
+
+ +

+ # + py_newint +

+
+
+
/// Create an `int` object.
+PK_API void py_newint(py_OutRef, py_i64);
+
+ +

+ # + py_newtrivial +

+
+
+
/// Create a trivial value object.
+PK_API void py_newtrivial(py_OutRef out, py_Type type, void* data, int size);
+
+ +

+ # + py_newfloat +

+
+
+
/// Create a `float` object.
+PK_API void py_newfloat(py_OutRef, py_f64);
+
+ +

+ # + py_newbool +

+
+
+
/// Create a `bool` object.
+PK_API void py_newbool(py_OutRef, bool);
+
+ +

+ # + py_newstr +

+
+
+
/// Create a `str` object from a null-terminated string (utf-8).
+PK_API void py_newstr(py_OutRef, const char*);
+
+ +

+ # + py_newstrn +

+
+
+
/// Create a `str` object with `n` UNINITIALIZED bytes plus `'\0'`.
+PK_API char* py_newstrn(py_OutRef, int);
+
+ +

+ # + py_newstrv +

+
+
+
/// Create a `str` object from a `c11_sv`.
+PK_API void py_newstrv(py_OutRef, c11_sv);
+
+ +

+ # + py_newfstr +

+
+
+
/// Create a formatted `str` object.
+PK_API void py_newfstr(py_OutRef, const char*, ...);
+
+ +

+ # + py_newnone +

+
+
+
/// Create a `None` object.
+PK_API void py_newnone(py_OutRef);
+
+ +

+ # + py_newnotimplemented +

+
+
+
/// Create a `NotImplemented` object.
+PK_API void py_newnotimplemented(py_OutRef);
+
+ +

+ # + py_newellipsis +

+
+
+
/// Create a `...` object.
+PK_API void py_newellipsis(py_OutRef);
+
+ +

+ # + py_newnil +

+
+
+
/// Create a `nil` object. `nil` is an invalid representation of an object.
+/// Don't use it unless you know what you are doing.
+PK_API void py_newnil(py_OutRef);
+
+ +

+ # + py_newnativefunc +

+
+
+
/// Create a `nativefunc` object.
+PK_API void py_newnativefunc(py_OutRef, py_CFunction);
+
+ +

+ # + py_newfunction +

+
+
+
/// Create a `function` object.
+PK_API py_Name py_newfunction(py_OutRef out,
+                              const char* sig,
+                              py_CFunction f,
+                              const char* docstring,
+                              int slots);
+
+ +

+ # + py_newboundmethod +

+
+
+
/// Create a `boundmethod` object.
+PK_API void py_newboundmethod(py_OutRef out, py_Ref self, py_Ref func);
+
+ +

+ # + py_newobject +

+
+
+
/// Create a new object.
+/// @param out output reference.
+/// @param type type of the object.
+/// @param slots number of slots. Use `-1` to create a `__dict__`.
+/// @param udsize size of your userdata.
+/// @return pointer to the userdata.
+PK_API void* py_newobject(py_OutRef out, py_Type type, int slots, int udsize);
+
+ +

+ # + py_name +

+
+
+
/// Convert a null-terminated string to a name.
+PK_API py_Name py_name(const char*);
+
+ +

+ # + py_name2ref +

+
+
+
/// Convert a name to a python `str` object with cache.
+PK_API py_GlobalRef py_name2ref(py_Name);
+
+ +

+ # + py_namev +

+
+
+
/// Convert a `c11_sv` to a name.
+PK_API py_Name py_namev(c11_sv);
+
+ +

+ # + py_name2sv +

+
+
+
/// Convert a name to a `c11_sv`.
+PK_API c11_sv py_name2sv(py_Name);
+
+ +

+ # + py_bind +

+
+
+
/// Bind a function to the object via "decl-based" style.
+/// @param obj the target object.
+/// @param sig signature of the function. e.g. `add(x, y)`.
+/// @param f function to bind.
+PK_API void py_bind(py_Ref obj, const char* sig, py_CFunction f);
+
+ +

+ # + py_bindmethod +

+
+
+
/// Bind a method to type via "argc-based" style.
+/// @param type the target type.
+/// @param name name of the method.
+/// @param f function to bind.
+PK_API void py_bindmethod(py_Type type, const char* name, py_CFunction f);
+
+ +

+ # + py_bindstaticmethod +

+
+
+
/// Bind a static method to type via "argc-based" style.
+/// @param type the target type.
+/// @param name name of the method.
+/// @param f function to bind.
+PK_API void py_bindstaticmethod(py_Type type, const char* name, py_CFunction f);
+
+ +

+ # + py_bindfunc +

+
+
+
/// Bind a function to the object via "argc-based" style.
+/// @param obj the target object.
+/// @param name name of the function.
+/// @param f function to bind.
+PK_API void py_bindfunc(py_Ref obj, const char* name, py_CFunction f);
+
+ +

+ # + py_bindproperty +

+
+
+
/// Bind a property to type.
+/// @param type the target type.
+/// @param name name of the property.
+/// @param getter getter function.
+/// @param setter setter function. Use `NULL` if not needed.
+PK_API void py_bindproperty(py_Type type, const char* name, py_CFunction getter, py_CFunction setter);
+
+ +

+ # + py_bindmagic +

+
+
+
/// Bind a magic method to type.
+PK_API void py_bindmagic(py_Type type, py_Name name, py_CFunction f);
+
+ +

+ # + py_macrobind +

+
+
+
/// Bind a compile-time function via "decl-based" style.
+PK_API void py_macrobind(const char* sig, py_CFunction f);
+
+ +

+ # + py_macroget +

+
+
+
/// Get a compile-time function by name.
+PK_API py_ItemRef py_macroget(py_Name name);
+
+ +

+ # + py_toint +

+
+
+
/// Convert an `int` object in python to `int64_t`.
+PK_API py_i64 py_toint(py_Ref);
+
+ +

+ # + py_totrivial +

+
+
+
/// Get the address of the trivial value object (16 bytes).
+PK_API void* py_totrivial(py_Ref);
+
+ +

+ # + py_tofloat +

+
+
+
/// Convert a `float` object in python to `double`.
+PK_API py_f64 py_tofloat(py_Ref);
+
+ +

+ # + py_castfloat + raise + +

+
+
+
/// Cast a `int` or `float` object in python to `double`.
+/// If successful, return true and set the value to `out`.
+/// Otherwise, return false and raise `TypeError`.
+PK_API bool py_castfloat(py_Ref, py_f64* out);
+
+ +

+ # + py_castfloat32 + raise + +

+
+
+
/// 32-bit version of `py_castfloat`.
+PK_API bool py_castfloat32(py_Ref, float* out);
+
+ +

+ # + py_castint + raise + +

+
+
+
/// Cast a `int` object in python to `int64_t`.
+PK_API bool py_castint(py_Ref, py_i64* out);
+
+ +

+ # + py_tobool +

+
+
+
/// Convert a `bool` object in python to `bool`.
+PK_API bool py_tobool(py_Ref);
+
+ +

+ # + py_totype +

+
+
+
/// Convert a `type` object in python to `py_Type`.
+PK_API py_Type py_totype(py_Ref);
+
+ +

+ # + py_touserdata +

+
+
+
/// Convert a user-defined object to its userdata.
+PK_API void* py_touserdata(py_Ref);
+
+ +

+ # + py_tosv +

+
+
+
/// Convert a `str` object in python to `c11_sv`.
+PK_API c11_sv py_tosv(py_Ref);
+
+ +

+ # + py_bytes_resize +

+
+
+
/// Resize a `bytes` object. It can only be resized down.
+PK_API void py_bytes_resize(py_Ref, int size);
+
+ +

+ # + py_newtype +

+
+
+
/// Create a new type.
+/// @param name name of the type.
+/// @param base base type.
+/// @param module module where the type is defined. Use `NULL` for built-in types.
+/// @param dtor destructor function. Use `NULL` if not needed.
+PK_API py_Type py_newtype(const char* name, py_Type base, const py_GlobalRef module, py_Dtor dtor);
+
+ +

+ # + py_istype +

+
+
+
/// Check if the object is exactly the given type.
+PK_API bool py_istype(py_Ref, py_Type);
+
+ +

+ # + py_typeof +

+
+
+
/// Get the type of the object.
+PK_API py_Type py_typeof(py_Ref self);
+
+ +

+ # + py_isinstance +

+
+
+
/// Check if the object is an instance of the given type.
+PK_API bool py_isinstance(py_Ref obj, py_Type type);
+
+ +

+ # + py_issubclass +

+
+
+
/// Check if the derived type is a subclass of the base type.
+PK_API bool py_issubclass(py_Type derived, py_Type base);
+
+ +

+ # + py_gettype +

+
+
+
/// Get type by module and name. e.g. `py_gettype("time", py_name("struct_time"))`.
+/// Return `0` if not found.
+PK_API py_Type py_gettype(const char* module, py_Name name);
+
+ +

+ # + py_checktype + raise + +

+
+
+
/// Check if the object is an instance of the given type exactly.
+/// Raise `TypeError` if the check fails.
+PK_API bool py_checktype(py_Ref self, py_Type type);
+
+ +

+ # + py_checkinstance + raise + +

+
+
+
/// Check if the object is an instance of the given type or its subclass.
+/// Raise `TypeError` if the check fails.
+PK_API bool py_checkinstance(py_Ref self, py_Type type);
+
+ +

+ # + py_tpfindmagic +

+
+
+
/// Search the magic method from the given type to the base type.
+/// Return `NULL` if not found.
+PK_API py_GlobalRef py_tpfindmagic(py_Type, py_Name name);
+
+ +

+ # + py_tpfindname +

+
+
+
/// Search the name from the given type to the base type.
+/// Return `NULL` if not found.
+PK_API py_ItemRef py_tpfindname(py_Type, py_Name name);
+
+ +

+ # + py_tpbase +

+
+
+
/// Get the base type of the given type.
+PK_API py_Type py_tpbase(py_Type type);
+
+ +

+ # + py_tpobject +

+
+
+
/// Get the type object of the given type.
+PK_API py_GlobalRef py_tpobject(py_Type type);
+
+ +

+ # + py_tpsetfinal +

+
+
+
/// Disable the type for subclassing.
+PK_API void py_tpsetfinal(py_Type type);
+
+ +

+ # + py_tphookattributes +

+
+
+
/// Set attribute hooks for the given type.
+PK_API void py_tphookattributes(py_Type type,
+                                bool (*getattribute)(py_Ref self, py_Name name) PY_RAISE PY_RETURN,
+                                bool (*setattribute)(py_Ref self, py_Name name, py_Ref val)
+                                    PY_RAISE PY_RETURN,
+                                bool (*delattribute)(py_Ref self, py_Name name) PY_RAISE,
+                                bool (*getunboundmethod)(py_Ref self, py_Name name) PY_RETURN);
+
+ +

+ # + py_inspect_currentfunction +

+
+
+
/// Get the current `function` object on the stack.
+/// Return `NULL` if not available.
+/// NOTE: This function should be placed at the beginning of your decl-based bindings.
+PK_API py_StackRef py_inspect_currentfunction();
+
+ +

+ # + py_inspect_currentmodule +

+
+
+
/// Get the current `module` object where the code is executed.
+/// Return `NULL` if not available.
+PK_API py_GlobalRef py_inspect_currentmodule();
+
+ +

+ # + py_inspect_currentframe +

+
+
+
/// Get the current frame object.
+/// Return `NULL` if not available.
+PK_API py_Frame* py_inspect_currentframe();
+
+ +

+ # + py_newglobals +

+
+
+
/// Python equivalent to `globals()`.
+PK_API void py_newglobals(py_OutRef);
+
+ +

+ # + py_newlocals +

+
+
+
/// Python equivalent to `locals()`.
+PK_API void py_newlocals(py_OutRef);
+
+ +

+ # + py_getreg +

+
+
+
/// Get the i-th register.
+/// All registers are located in a contiguous memory.
+PK_API py_GlobalRef py_getreg(int i);
+
+ +

+ # + py_setreg +

+
+
+
/// Set the i-th register.
+PK_API void py_setreg(int i, py_Ref val);
+
+ +

+ # + py_retval +

+
+
+
/// Get the last return value.
+/// Please note that `py_retval()` cannot be used as input argument.
+PK_API py_GlobalRef py_retval();
+
+ +

+ # + py_getdict +

+
+
+
/// Get an item from the object's `__dict__`.
+/// Return `NULL` if not found.
+PK_API py_ItemRef py_getdict(py_Ref self, py_Name name);
+
+ +

+ # + py_setdict +

+
+
+
/// Set an item to the object's `__dict__`.
+PK_API void py_setdict(py_Ref self, py_Name name, py_Ref val);
+
+ +

+ # + py_deldict +

+
+
+
/// Delete an item from the object's `__dict__`.
+/// Return `true` if the deletion is successful.
+PK_API bool py_deldict(py_Ref self, py_Name name);
+
+ +

+ # + py_emplacedict +

+
+
+
/// Prepare an insertion to the object's `__dict__`.
+PK_API py_ItemRef py_emplacedict(py_Ref self, py_Name name);
+
+ +

+ # + py_applydict + raise + +

+
+
+
/// Apply a function to all items in the object's `__dict__`.
+/// Return `true` if the function is successful for all items.
+/// NOTE: Be careful if `f` modifies the object's `__dict__`.
+PK_API bool py_applydict(py_Ref self, bool (*f)(py_Name name, py_Ref val, void* ctx), void* ctx);
+
+ +

+ # + py_cleardict +

+
+
+
/// Clear the object's `__dict__`. This function is dangerous.
+PK_API void py_cleardict(py_Ref self);
+
+ +

+ # + py_getslot +

+
+
+
/// Get the i-th slot of the object.
+/// The object must have slots and `i` must be in valid range.
+PK_API py_ObjectRef py_getslot(py_Ref self, int i);
+
+ +

+ # + py_setslot +

+
+
+
/// Set the i-th slot of the object.
+PK_API void py_setslot(py_Ref self, int i, py_Ref val);
+
+ +

+ # + py_getbuiltin +

+
+
+
/// Get variable in the `builtins` module.
+PK_API py_ItemRef py_getbuiltin(py_Name name);
+
+ +

+ # + py_getglobal +

+
+
+
/// Get variable in the `__main__` module.
+PK_API py_ItemRef py_getglobal(py_Name name);
+
+ +

+ # + py_setglobal +

+
+
+
/// Set variable in the `__main__` module.
+PK_API void py_setglobal(py_Name name, py_Ref val);
+
+ +

+ # + py_peek +

+
+
+
/// Get the i-th object from the top of the stack.
+/// `i` should be negative, e.g. (-1) means TOS.
+PK_API py_StackRef py_peek(int i);
+
+ +

+ # + py_push +

+
+
+
/// Push the object to the stack.
+PK_API void py_push(py_Ref src);
+
+ +

+ # + py_pushnil +

+
+
+
/// Push a `nil` object to the stack.
+PK_API void py_pushnil();
+
+ +

+ # + py_pushnone +

+
+
+
/// Push a `None` object to the stack.
+PK_API void py_pushnone();
+
+ +

+ # + py_pushname +

+
+
+
/// Push a `py_Name` to the stack. This is used for keyword arguments.
+PK_API void py_pushname(py_Name name);
+
+ +

+ # + py_pop +

+
+
+
/// Pop an object from the stack.
+PK_API void py_pop();
+
+ +

+ # + py_shrink +

+
+
+
/// Shrink the stack by n.
+PK_API void py_shrink(int n);
+
+ +

+ # + py_pushtmp +

+
+
+
/// Get a temporary variable from the stack.
+PK_API py_StackRef py_pushtmp();
+
+ +

+ # + py_pushmethod +

+
+
+
/// Get the unbound method of the object.
+/// Assume the object is located at the top of the stack.
+/// If return true:  `[self] -> [unbound, self]`.
+/// If return false: `[self] -> [self]` (no change).
+PK_API bool py_pushmethod(py_Name name);
+
+ +

+ # + py_pusheval + raise + +

+
+
+
/// Evaluate an expression and push the result to the stack.
+/// This function is used for testing.
+PK_API bool py_pusheval(const char* expr, py_GlobalRef module);
+
+ +

+ # + py_vectorcall + raise + + return + +

+
+
+
/// Call a callable object via pocketpy's calling convention.
+/// You need to prepare the stack using the following format:
+/// `callable, self/nil, arg1, arg2, ..., k1, v1, k2, v2, ...`.
+/// `argc` is the number of positional arguments excluding `self`.
+/// `kwargc` is the number of keyword arguments.
+/// The result will be set to `py_retval()`.
+/// The stack size will be reduced by `2 + argc + kwargc * 2`.
+PK_API bool py_vectorcall(uint16_t argc, uint16_t kwargc);
+
+ +

+ # + py_call + raise + + return + +

+
+
+
/// Call a function.
+/// It prepares the stack and then performs a `vectorcall(argc, 0, false)`.
+/// The result will be set to `py_retval()`.
+/// The stack remains unchanged if successful.
+PK_API bool py_call(py_Ref f, int argc, py_Ref argv);
+
+ +

+ # + py_tpcall + raise + + return + +

+
+
+
/// Call a type to create a new instance.
+PK_API bool py_tpcall(py_Type type, int argc, py_Ref argv);
+
+ +

+ # + py_callcfunc + raise + + return + +

+
+
+
/// Call a `py_CFunction` in a safe way.
+/// This function does extra checks to help you debug `py_CFunction`.
+PK_API bool py_callcfunc(py_CFunction f, int argc, py_Ref argv);
+
+ +

+ # + py_binaryop + raise + + return + +

+
+
+
/// Perform a binary operation.
+/// The result will be set to `py_retval()`.
+/// The stack remains unchanged after the operation.
+PK_API bool py_binaryop(py_Ref lhs, py_Ref rhs, py_Name op, py_Name rop);
+
+ +

+ # + py_binaryadd + raise + + return + +

+
+
+
/// lhs + rhs
+PK_API bool py_binaryadd(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binarysub + raise + + return + +

+
+
+
/// lhs - rhs
+PK_API bool py_binarysub(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binarymul + raise + + return + +

+
+
+
/// lhs * rhs
+PK_API bool py_binarymul(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binarytruediv + raise + + return + +

+
+
+
/// lhs / rhs
+PK_API bool py_binarytruediv(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binaryfloordiv + raise + + return + +

+
+
+
/// lhs // rhs
+PK_API bool py_binaryfloordiv(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binarymod + raise + + return + +

+
+
+
/// lhs % rhs
+PK_API bool py_binarymod(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binarypow + raise + + return + +

+
+
+
/// lhs ** rhs
+PK_API bool py_binarypow(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binarylshift + raise + + return + +

+
+
+
/// lhs << rhs
+PK_API bool py_binarylshift(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binaryrshift + raise + + return + +

+
+
+
/// lhs >> rhs
+PK_API bool py_binaryrshift(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binaryand + raise + + return + +

+
+
+
/// lhs & rhs
+PK_API bool py_binaryand(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binaryor + raise + + return + +

+
+
+
/// lhs | rhs
+PK_API bool py_binaryor(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binaryxor + raise + + return + +

+
+
+
/// lhs ^ rhs
+PK_API bool py_binaryxor(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_binarymatmul + raise + + return + +

+
+
+
/// lhs @ rhs
+PK_API bool py_binarymatmul(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_eq + raise + + return + +

+
+
+
/// lhs == rhs
+PK_API bool py_eq(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_ne + raise + + return + +

+
+
+
/// lhs != rhs
+PK_API bool py_ne(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_lt + raise + + return + +

+
+
+
/// lhs < rhs
+PK_API bool py_lt(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_le + raise + + return + +

+
+
+
/// lhs <= rhs
+PK_API bool py_le(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_gt + raise + + return + +

+
+
+
/// lhs > rhs
+PK_API bool py_gt(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_ge + raise + + return + +

+
+
+
/// lhs >= rhs
+PK_API bool py_ge(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_isidentical +

+
+
+
/// Python equivalent to `lhs is rhs`.
+PK_API bool py_isidentical(py_Ref, py_Ref);
+
+ +

+ # + py_bool + raise + +

+
+
+
/// Python equivalent to `bool(val)`.
+/// 1: true, 0: false, -1: error
+PK_API int py_bool(py_Ref val);
+
+ +

+ # + py_equal + raise + +

+
+
+
/// Compare two objects.
+/// 1: lhs == rhs, 0: lhs != rhs, -1: error
+PK_API int py_equal(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_less + raise + +

+
+
+
/// Compare two objects.
+/// 1: lhs < rhs, 0: lhs >= rhs, -1: error
+PK_API int py_less(py_Ref lhs, py_Ref rhs);
+
+ +

+ # + py_callable +

+
+
+
/// Python equivalent to `callable(val)`.
+PK_API bool py_callable(py_Ref val);
+
+ +

+ # + py_hash + raise + +

+
+
+
/// Get the hash value of the object.
+PK_API bool py_hash(py_Ref, py_i64* out);
+
+ +

+ # + py_iter + raise + + return + +

+
+
+
/// Get the iterator of the object.
+PK_API bool py_iter(py_Ref);
+
+ +

+ # + py_next + raise + + return + +

+
+
+
/// Get the next element from the iterator.
+/// 1: success, 0: StopIteration, -1: error
+PK_API int py_next(py_Ref);
+
+ +

+ # + py_str + raise + + return + +

+
+
+
/// Python equivalent to `str(val)`.
+PK_API bool py_str(py_Ref val);
+
+ +

+ # + py_repr + raise + + return + +

+
+
+
/// Python equivalent to `repr(val)`.
+PK_API bool py_repr(py_Ref val);
+
+ +

+ # + py_len + raise + + return + +

+
+
+
/// Python equivalent to `len(val)`.
+PK_API bool py_len(py_Ref val);
+
+ +

+ # + py_getattr + raise + + return + +

+
+
+
/// Python equivalent to `getattr(self, name)`.
+PK_API bool py_getattr(py_Ref self, py_Name name);
+
+ +

+ # + py_setattr + raise + +

+
+
+
/// Python equivalent to `setattr(self, name, val)`.
+PK_API bool py_setattr(py_Ref self, py_Name name, py_Ref val);
+
+ +

+ # + py_delattr + raise + +

+
+
+
/// Python equivalent to `delattr(self, name)`.
+PK_API bool py_delattr(py_Ref self, py_Name name);
+
+ +

+ # + py_getitem + raise + + return + +

+
+
+
/// Python equivalent to `self[key]`.
+PK_API bool py_getitem(py_Ref self, py_Ref key);
+
+ +

+ # + py_setitem + raise + +

+
+
+
/// Python equivalent to `self[key] = val`.
+PK_API bool py_setitem(py_Ref self, py_Ref key, py_Ref val);
+
+ +

+ # + py_delitem + raise + +

+
+
+
/// Python equivalent to `del self[key]`.
+PK_API bool py_delitem(py_Ref self, py_Ref key);
+
+ +

+ # + py_getmodule +

+
+
+
/// Get a module by path.
+PK_API py_GlobalRef py_getmodule(const char* path);
+
+ +

+ # + py_newmodule +

+
+
+
/// Create a new module.
+PK_API py_GlobalRef py_newmodule(const char* path);
+
+ +

+ # + py_importlib_reload + raise + + return + +

+
+
+
/// Reload an existing module.
+PK_API bool py_importlib_reload(py_Ref module);
+
+ +

+ # + py_import + raise + + return + +

+
+
+
/// Import a module.
+/// The result will be set to `py_retval()`.
+/// -1: error, 0: not found, 1: success
+PK_API int py_import(const char* path);
+
+ +

+ # + py_checkexc +

+
+
+
/// Check if there is an unhandled exception.
+PK_API bool py_checkexc();
+
+ +

+ # + py_matchexc + return + +

+
+
+
/// Check if the unhandled exception is an instance of the given type.
+/// If match, the exception will be stored in `py_retval()`.
+PK_API bool py_matchexc(py_Type type);
+
+ +

+ # + py_clearexc +

+
+
+
/// Clear the unhandled exception.
+/// @param p0 the unwinding point. Use `NULL` if not needed.
+PK_API void py_clearexc(py_StackRef p0);
+
+ +

+ # + py_printexc +

+
+
+
/// Print the unhandled exception.
+PK_API void py_printexc();
+
+ +

+ # + py_formatexc +

+
+
+
/// Format the unhandled exception and return a null-terminated string.
+/// The returned string should be freed by the caller.
+PK_API char* py_formatexc();
+
+ +

+ # + py_exception + raise + +

+
+
+
/// Raise an exception by type and message. Always return false.
+PK_API bool py_exception(py_Type type, const char* fmt, ...);
+
+ +

+ # + py_raise + raise + +

+
+
+
/// Raise an exception object. Always return false.
+PK_API bool py_raise(py_Ref);
+
+ +

+ # + KeyError + raise + +

+
+
+

+PK_API bool KeyError(py_Ref key);
+
+ +

+ # + StopIteration + raise + +

+
+
+

+PK_API bool StopIteration();
+
+ +

+ # + py_debugger_waitforattach +

+
+
+

+PK_API void py_debugger_waitforattach(const char* hostname, unsigned short port);
+
+ +

+ # + py_debugger_status +

+
+
+

+PK_API int py_debugger_status();
+
+ +

+ # + py_debugger_exceptionbreakpoint +

+
+
+

+PK_API void py_debugger_exceptionbreakpoint(py_Ref exc);
+
+ +

+ # + py_debugger_exit +

+
+
+

+PK_API void py_debugger_exit(int code);
+
+ +

+ # + py_newtuple +

+
+
+
/// Create a `tuple` with `n` UNINITIALIZED elements.
+/// You should initialize all elements before using it.
+PK_API py_ObjectRef py_newtuple(py_OutRef, int n);
+
+ +

+ # + py_tuple_data +

+
+
+

+PK_API py_ObjectRef py_tuple_data(py_Ref self);
+
+ +

+ # + py_tuple_getitem +

+
+
+

+PK_API py_ObjectRef py_tuple_getitem(py_Ref self, int i);
+
+ +

+ # + py_tuple_setitem +

+
+
+

+PK_API void py_tuple_setitem(py_Ref self, int i, py_Ref val);
+
+ +

+ # + py_tuple_len +

+
+
+

+PK_API int py_tuple_len(py_Ref self);
+
+ +

+ # + py_newlist +

+
+
+
/// Create an empty `list`.
+PK_API void py_newlist(py_OutRef);
+
+ +

+ # + py_newlistn +

+
+
+
/// Create a `list` with `n` UNINITIALIZED elements.
+/// You should initialize all elements before using it.
+PK_API void py_newlistn(py_OutRef, int n);
+
+ +

+ # + py_list_data +

+
+
+

+PK_API py_ItemRef py_list_data(py_Ref self);
+
+ +

+ # + py_list_getitem +

+
+
+

+PK_API py_ItemRef py_list_getitem(py_Ref self, int i);
+
+ +

+ # + py_list_setitem +

+
+
+

+PK_API void py_list_setitem(py_Ref self, int i, py_Ref val);
+
+ +

+ # + py_list_delitem +

+
+
+

+PK_API void py_list_delitem(py_Ref self, int i);
+
+ +

+ # + py_list_len +

+
+
+

+PK_API int py_list_len(py_Ref self);
+
+ +

+ # + py_list_swap +

+
+
+

+PK_API void py_list_swap(py_Ref self, int i, int j);
+
+ +

+ # + py_list_append +

+
+
+

+PK_API void py_list_append(py_Ref self, py_Ref val);
+
+ +

+ # + py_list_emplace +

+
+
+

+PK_API py_ItemRef py_list_emplace(py_Ref self);
+
+ +

+ # + py_list_clear +

+
+
+

+PK_API void py_list_clear(py_Ref self);
+
+ +

+ # + py_list_insert +

+
+
+

+PK_API void py_list_insert(py_Ref self, int i, py_Ref val);
+
+ +

+ # + py_newdict +

+
+
+
/// Create an empty `dict`.
+PK_API void py_newdict(py_OutRef);
+
+ +

+ # + py_dict_getitem + raise + + return + +

+
+
+
/// -1: error, 0: not found, 1: found
+PK_API int py_dict_getitem(py_Ref self, py_Ref key);
+
+ +

+ # + py_dict_setitem + raise + +

+
+
+
/// true: success, false: error
+PK_API bool py_dict_setitem(py_Ref self, py_Ref key, py_Ref val);
+
+ +

+ # + py_dict_delitem + raise + +

+
+
+
/// -1: error, 0: not found, 1: found (and deleted)
+PK_API int py_dict_delitem(py_Ref self, py_Ref key);
+
+ +

+ # + py_dict_getitem_by_str + raise + + return + +

+
+
+
/// -1: error, 0: not found, 1: found
+PK_API int py_dict_getitem_by_str(py_Ref self, const char* key);
+
+ +

+ # + py_dict_getitem_by_int + raise + + return + +

+
+
+
/// -1: error, 0: not found, 1: found
+PK_API int py_dict_getitem_by_int(py_Ref self, py_i64 key);
+
+ +

+ # + py_dict_setitem_by_str + raise + +

+
+
+
/// true: success, false: error
+PK_API bool py_dict_setitem_by_str(py_Ref self, const char* key, py_Ref val);
+
+ +

+ # + py_dict_setitem_by_int + raise + +

+
+
+
/// true: success, false: error
+PK_API bool py_dict_setitem_by_int(py_Ref self, py_i64 key, py_Ref val);
+
+ +

+ # + py_dict_delitem_by_str + raise + +

+
+
+
/// -1: error, 0: not found, 1: found (and deleted)
+PK_API int py_dict_delitem_by_str(py_Ref self, const char* key);
+
+ +

+ # + py_dict_delitem_by_int + raise + +

+
+
+
/// -1: error, 0: not found, 1: found (and deleted)
+PK_API int py_dict_delitem_by_int(py_Ref self, py_i64 key);
+
+ +

+ # + py_dict_apply + raise + +

+
+
+
/// true: success, false: error
+PK_API bool py_dict_apply(py_Ref self, bool (*f)(py_Ref key, py_Ref val, void* ctx), void* ctx);
+
+ +

+ # + py_dict_len +

+
+
+
/// noexcept
+PK_API int py_dict_len(py_Ref self);
+
+ +

+ # + py_newslice +

+
+
+
/// Create an UNINITIALIZED `slice` object.
+/// You should use `py_setslot()` to set `start`, `stop`, and `step`.
+PK_API py_ObjectRef py_newslice(py_OutRef);
+
+ +

+ # + py_newsliceint +

+
+
+
/// Create a `slice` object from 3 integers.
+PK_API void py_newsliceint(py_OutRef out, py_i64 start, py_i64 stop, py_i64 step);
+
+ +

+ # + py_newRandom +

+
+
+

+PK_API void py_newRandom(py_OutRef out);
+
+ +

+ # + py_Random_seed +

+
+
+

+PK_API void py_Random_seed(py_Ref self, py_i64 seed);
+
+ +

+ # + py_Random_random +

+
+
+

+PK_API py_f64 py_Random_random(py_Ref self);
+
+ +

+ # + py_Random_uniform +

+
+
+

+PK_API py_f64 py_Random_uniform(py_Ref self, py_f64 a, py_f64 b);
+
+ +

+ # + py_Random_randint +

+
+
+

+PK_API py_i64 py_Random_randint(py_Ref self, py_i64 a, py_i64 b);
+
+ +

+ # + py_newarray2d +

+
+
+

+PK_API void py_newarray2d(py_OutRef out, int width, int height);
+
+ +

+ # + py_array2d_getwidth +

+
+
+

+PK_API int py_array2d_getwidth(py_Ref self);
+
+ +

+ # + py_array2d_getheight +

+
+
+

+PK_API int py_array2d_getheight(py_Ref self);
+
+ +

+ # + py_array2d_getitem +

+
+
+

+PK_API py_ObjectRef py_array2d_getitem(py_Ref self, int x, int y);
+
+ +

+ # + py_array2d_setitem +

+
+
+

+PK_API void py_array2d_setitem(py_Ref self, int x, int y, py_Ref val);
+
+ +

+ # + py_newvec2 +

+
+
+

+PK_API void py_newvec2(py_OutRef out, c11_vec2);
+
+ +

+ # + py_newvec3 +

+
+
+

+PK_API void py_newvec3(py_OutRef out, c11_vec3);
+
+ +

+ # + py_newvec2i +

+
+
+

+PK_API void py_newvec2i(py_OutRef out, c11_vec2i);
+
+ +

+ # + py_newvec3i +

+
+
+

+PK_API void py_newvec3i(py_OutRef out, c11_vec3i);
+
+ +

+ # + py_newcolor32 +

+
+
+

+PK_API void py_newcolor32(py_OutRef out, c11_color32);
+
+ +

+ # + py_newmat3x3 +

+
+
+

+PK_API c11_mat3x3* py_newmat3x3(py_OutRef out);
+
+ +

+ # + py_tovec2 +

+
+
+

+PK_API c11_vec2 py_tovec2(py_Ref self);
+
+ +

+ # + py_tovec3 +

+
+
+

+PK_API c11_vec3 py_tovec3(py_Ref self);
+
+ +

+ # + py_tovec2i +

+
+
+

+PK_API c11_vec2i py_tovec2i(py_Ref self);
+
+ +

+ # + py_tovec3i +

+
+
+

+PK_API c11_vec3i py_tovec3i(py_Ref self);
+
+ +

+ # + py_tomat3x3 +

+
+
+

+PK_API c11_mat3x3* py_tomat3x3(py_Ref self);
+
+ +

+ # + py_tocolor32 +

+
+
+

+PK_API c11_color32 py_tocolor32(py_Ref self);
+
+ +

+ # + py_json_dumps + raise + + return + +

+
+
+
/// Python equivalent to `json.dumps(val)`.
+PK_API bool py_json_dumps(py_Ref val, int indent);
+
+ +

+ # + py_json_loads + raise + + return + +

+
+
+
/// Python equivalent to `json.loads(val)`.
+PK_API bool py_json_loads(const char* source);
+
+ +

+ # + py_pickle_dumps + raise + + return + +

+
+
+
/// Python equivalent to `pickle.dumps(val)`.
+PK_API bool py_pickle_dumps(py_Ref val);
+
+ +

+ # + py_pickle_loads + raise + + return + +

+
+
+
/// Python equivalent to `pickle.loads(val)`.
+PK_API bool py_pickle_loads(const unsigned char* data, int size);
+
+ +

+ # + py_watchdog_begin +

+
+
+
/// Begin the watchdog with `timeout` in milliseconds.
+/// `PK_ENABLE_WATCHDOG` must be defined to `1` to use this feature.
+/// You need to call `py_watchdog_end()` later.
+/// If `timeout` is reached, `TimeoutError` will be raised.
+PK_API void py_watchdog_begin(py_i64 timeout);
+
+ +

+ # + py_watchdog_end +

+
+
+
/// Reset the watchdog.
+PK_API void py_watchdog_end();
+
+ +

+ # + py_profiler_begin +

+
+
+

+PK_API void py_profiler_begin();
+
+ +

+ # + py_profiler_end +

+
+
+

+PK_API void py_profiler_end();
+
+ +

+ # + py_profiler_reset +

+
+
+

+PK_API void py_profiler_reset();
+
+ +

+ # + py_profiler_report +

+
+
+

+PK_API char* py_profiler_report();
+
+ +

+ # + py_replinput +

+
+
+
/// An utility function to read a line from stdin for REPL.
+PK_API int py_replinput(char* buf, int max_size);
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/c-api/introduction/index.html b/c-api/introduction/index.html new file mode 100644 index 00000000..bb10ea19 --- /dev/null +++ b/c-api/introduction/index.html @@ -0,0 +1,437 @@ + + + + + + + + + + + + Introduction | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Introduction +

+
+

All public functions in the C API are prefixed with py_ in pocketpy.h.

+ +

+ # + Overview +

+
+

pocketpy works with opaque references. py_Ref is used to reference objects in the virtual machine. It is your responsibility to ensure a reference is valid before using it. See following reference types:

+
+
/// A generic reference to a python object.
+typedef py_TValue* py_Ref;
+/// A reference which has the same lifespan as the python object.
+typedef py_TValue* py_ObjectRef;
+/// A global reference which has the same lifespan as the VM.
+typedef py_TValue* py_GlobalRef;
+/// A specific location in the value stack of the VM.
+typedef py_TValue* py_StackRef;
+/// An item reference to a container object. It invalidates when the container is modified.
+typedef py_TValue* py_ItemRef;
+/// An output reference for returning a value.
+typedef py_TValue* py_OutRef;
+
+

You can store python objects into "stack" or "register". +We provide 8 registers and you can get references to them by py_reg(). +Also, py_retval() is a special register that is used to store the return value of a py_CFunction. +Registers are shared so they could be overwritten easily. +If you want to store python objects across function calls, you should store them into the stack via py_push() and py_pop().

+ +

+ # + Data Types +

+
+

You can do conversions between C types and python objects using the following functions:

+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
C typePython typeC to PythonPython to C
char,short,int,longintpy_newint()py_toint()
float,doublefloatpy_newfloat()py_tofloat(), py_castfloat()
boolboolpy_newbool()py_tobool()
const char*strpy_newstr()py_tostr()
void*,intptr_tintpy_newint()(void*)py_toint()
+
+
+ +

+ # + PY_RAISE macro +

+
+

Mark a function that can raise an exception on failure.

+
    +
  • If the function returns bool, then false means an exception is raised.
  • +
  • If the function returns int, then -1 means an exception is raised.
  • +
+ +

+ # + PY_RETURN macro +

+
+

Mark a function that can store a value in py_retval() on success.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/coding-style-guide/index.html b/coding-style-guide/index.html new file mode 100644 index 00000000..0a2bd85b --- /dev/null +++ b/coding-style-guide/index.html @@ -0,0 +1,592 @@ + + + + + + + + + + + + Coding Style Guide | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Coding Style Guide +

+
+ +

+ # + Indentation +

+
+

Use four spaces for indentation. Do not use TAB.

+ +

+ # + Strings +

+
+
+
# Prefer single quotes for strings
+s = 'this is a string'
+
+# Use double quotes only if the string itself contains a single quote
+s = "this ' is single quote"
+
+ +

+ # + Docstrings +

+
+

Always use triple quotes for docstrings.

+
+
def f():
+    """This is a multi-line docstring.
+
+    Here is some content. Docstrings partially support Markdown.
+    """
+
+def g():
+    """This is a single-line docstring."""
+
+

Use natural language to describe the function's purpose. Do not enumerate each parameter and return value.

+
+
# Correct
+def add(a: int, b: int):
+    """Add two integers `a` and `b`."""
+
+# Incorrect
+def add(a: int, b: int):
+    """
+    @param a, the first argument
+    @param b, the second argument
+    @return, the result of a + b
+    """
+
+ +

+ # + Spaces +

+
+
+
# Add a space after `,` or `:`
+a, b = 1, 2
+c = [1, 2, 3]
+d = {'key': 'value'}
+
+# Spaces may be added around operators
+res = 1 + 2
+if res < 2: pass
+# Spaces can also be selectively added to indicate operator precedence
+x = x * 2 - 1
+hypot2 = x * x + y * y
+c = (a + b) * (a - b)
+
+# Add a space after `:` in type annotations
+def f(a: int, b: float): ...
+def g() -> int: ...
+
+# Add spaces around `=` when specifying default values in function parameters
+def f(a: int = 1, b: int | None = None): ...
+# However, omit spaces if the parameter has no type annotation
+def f(a=1, b=2): pass
+
+# Do not add spaces in keyword arguments when calling functions
+print(1, 2, 3, end='', sep=',')
+f(a=10, b=20)
+
+ +

+ # + Naming Conventions +

+
+
    +
  • Classes: CapitalizedWords
  • +
  • Functions and variables: lower_case_with_underscores
  • +
  • Constants and enums: UPPER_CASE_WITH_UNDERSCORES or CapitalizedWords
  • +
  • Anonymous ordered variables: _0, _1, _2
  • +
  • Discarded variables: _
  • +
  • Some standard library functions: lowercase
  • +
+

Here are some commonly used naming conventions:

+
    +
  • self: The first parameter of an instance method
  • +
  • cls: The first parameter of class methods and __new__
  • +
+ +

+ # + Using Abbreviations +

+
+

Use abbreviations only for temporary variables and internal implementations.

+

Abbreviations should be well-established, include key syllables of the original word, and be immediately recognizable.

+
    +
  • context -> ctx (✔)
  • +
  • temporary -> tmp (✔)
  • +
  • distribution -> dist (✔)
  • +
  • visited -> vis ()
  • +
+
+
# Incorrect: Using abbreviations in public function parameters
+def some_pub_fn(ctx, req_id, data):
+    pass
+
+# Correct
+def some_public_function(context, request_id, data):
+    pass
+
+ +

+ # + Using Precise Terminology +

+
+

Naming should convey precise meanings, especially when multiple synonyms exist.

+

For example, count, size, and length all relate to quantity, but they have different nuances:

+
    +
  • count: Represents a counted value
  • +
  • length: Represents the number of elements in a container
  • +
  • size: Represents the byte size of an object
  • +
+
+
s = 'aaabc⭐'
+count = s.count('a')
+length = len(s)
+size = len(s.encode())
+
+print(f"{s!r} has a length of {length}, a size of {size} bytes, and contains {count} occurrences of 'a'")
+# 'aaabc⭐' has a length of 6, a size of 8 bytes, and contains 3 occurrences of 'a'
+
+ +

+ # + Using Professional Terminology +

+
+
    +
  • For item quantities in a game: quantity is better than item_count
  • +
  • For grid counts: area (meaning surface area) is better than grid_count
  • +
+ +

+ # + Avoiding Built-in Names +

+
+
+
# Incorrect: Overwriting `builtins.map`
+map = [[1, 2, 3], [4, 5, 6]]
+# Incorrect: Overwriting `builtins.type`
+type = some_thing.type
+
+ +

+ # + Internal Functions and Classes +

+
+

Use a single underscore _ as a prefix for internal functions. Never use a double underscore __ (except for magic methods).

+
+
def _internal_func():
+    """This is an internal function."""
+
+class _InternalClass:
+    def _internal_f(self): pass
+
+ +

+ # + Importing Modules +

+
+
    +
  1. Import standard library modules first.
  2. +
  3. Then import third-party dependencies.
  4. +
  5. Finally, import project-specific modules.
  6. +
+
+
from typing import Any
+from collections import deque
+
+from array2d import array2d
+
+from ..utils import logger
+
+ +

+ # + Coding Practices +

+
+

Use is not when checking for None. Do not explicitly compare with True or False.

+
+
# Correct
+if x is not None: pass
+
+# Incorrect
+if x != None: pass
+
+# Correct
+x = True
+if x: pass
+if not x: pass
+
+# Incorrect
+if x == True: pass
+if x is True: pass
+if x != False: pass
+
+

The if statement implicitly calls bool(), so it can be used to check if a container is empty.

+
+
not_empty_list = [1]
+not_empty_string = '1'
+truth = True
+
+if not_empty_list:
+    print('true value')
+
+if not_empty_string:
+    print('true value')
+
+if truth:
+    print('true value')
+
+# Explicitly checking for emptiness is also valid
+if len(not_empty_list) > 0: pass
+
+ +

+ # + References +

+
+

PEP 8 – Style Guide for Python Code

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/features/basic/index.html b/features/basic/index.html new file mode 100644 index 00000000..c2d82b07 --- /dev/null +++ b/features/basic/index.html @@ -0,0 +1,545 @@ + + + + + + + + + + + + Basic Features | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Basic Features +

+
+

The following table shows the basic features of pkpy with respect to cpython.

+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
NameExampleSupported
If Elseif..else..elif
Loopfor/while/break/continue
Functiondef f(x,*args,y=1):
Subclassclass A(B):
List[1, 2, 'a']
ListComp[i for i in range(5)]
Slicea[1:2], a[:2], a[1:]
Tuple(1, 2, 'a')
Dict{'a': 1, 'b': 2}
F-Stringf'value is {x}'
Unpackinga, b = 1, 2
Star Unpackinga, *b = [1, 2, 3]
Exceptionraise/try..except..
Dynamic Codeeval()/exec()
Reflectionhasattr()/getattr()/setattr()
Importimport/from..import
Context Blockwith <expr> as <id>:
Type Annotationdef f(a:int, b:float=1)
Generatoryield i
Decorator@cache
Match Casematch code: case 200:
+
+ +

+ # + Supported magic methods +

+
+ +

+ # + Unary operators +

+
+
    +
  • __repr__
  • +
  • __str__
  • +
  • __hash__
  • +
  • __len__
  • +
  • __iter__
  • +
  • __next__
  • +
  • __neg__
  • +
+ +

+ # + Logical operators +

+
+
    +
  • __eq__
  • +
  • __lt__
  • +
  • __le__
  • +
  • __gt__
  • +
  • __ge__
  • +
  • __contains__
  • +
+ +

+ # + Binary operators +

+
+
    +
  • __add__
  • +
  • __radd__
  • +
  • __sub__
  • +
  • __rsub__
  • +
  • __mul__
  • +
  • __rmul__
  • +
  • __truediv__
  • +
  • __floordiv__
  • +
  • __mod__
  • +
  • __pow__
  • +
  • __matmul__
  • +
  • __lshift__
  • +
  • __rshift__
  • +
  • __and__
  • +
  • __or__
  • +
  • __xor__
  • +
  • __invert__
  • +
+ +

+ # + Indexer +

+
+
    +
  • __getitem__
  • +
  • __setitem__
  • +
  • __delitem__
  • +
+ +

+ # + Specials +

+
+
    +
  • __new__
  • +
  • __init__
  • +
  • __call__
  • +
  • __divmod__
  • +
  • __enter__
  • +
  • __exit__
  • +
  • __name__
  • +
  • __all__
  • +
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/features/debugging/index.html b/features/debugging/index.html new file mode 100644 index 00000000..aaf130db --- /dev/null +++ b/features/debugging/index.html @@ -0,0 +1,465 @@ + + + + + + + + + + + + Debugging | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Debugging +

+
+ +

+ # + Install VSCode Extension +

+
+

To debug a pocketpy program, you need to install our VSCode extension first:

+

https://marketplace.visualstudio.com/items?itemName=pocketpy.pocketpy

+
+
+ +
+ +

+ # + Create a launch.json file +

+
+

Navigate to the Debug view in VSCode, and click on "create a launch.json file" link. +In the dropdown menu, select "pocketpy".

+

+ launch_json +
launch_json
+
+

+

Then a default launch.json file will be created in the .vscode folder +with a sample pocketpy debug configuration.

+ +

+ # + How does it work? +

+
+

pocketpy provides a C-API py_debugger_waitforattach, +which starts a debug server and waits for the VSCode extension to attach. +When the debugger is attached, the program will continue to run.

+
    +
  • If you are using pocketpy's standalone executable main.exe, you can pass --debug flag to it. This will automatically call py_debugger_waitforattach("127.0.0.1", 6110) before running your program.
  • +
  • If you are embedding pocketpy as a library, you need to call py_debugger_waitforattach manually in your C/C++ code.
  • +
+ +

+ # + Configuration +

+
+
    +
  • type: must be pocketpy
  • +
  • request: can be attach or launch
  • +
  • name: the name of this configuration
  • +
  • port: the port number of the debug server, must match the one in py_debugger_waitforattach
  • +
  • host: the host of the debug server, must match the one in py_debugger_waitforattach
  • +
  • sourceFolder: the root folder of your python source code, default to ${workspaceFolder}. However, +sometimes you may run your program from a subfolder, in this case you need to set sourceFolder to the correct path. If this is not set correctly, breakpoints will not be hit.
  • +
  • program: (for launch mode only) the path to the executable file which calls py_debugger_waitforattach, e.g. the pocketpy standalone executable main.exe.
  • +
  • args: (for launch mode only) the arguments to pass to the executable file, e.g. --debug and the script path if you are using main.exe.
  • +
  • cwd: (for launch mode only) the working directory to launch the executable file, default to ${workspaceFolder}.
  • +
+ +

+ # + For attach mode +

+
+

In this mode, you need to start your pocketpy program manually which must call py_debugger_waitforattach first. +After the program starts, you can let VSCode attach to the debug server.

+
+
{
+    "type": "pocketpy",
+    "request": "attach",
+    "name": "Attach to pocketpy program",
+    "port": 6110,
+    "host": "localhost",
+    "sourceFolder": "${workspaceFolder}"
+}
+
+ +

+ # + For launch mode +

+
+

In this mode, VSCode will start your program with the specified program, args and cwd. +After the program starts, VSCode attempts to attach to the debug server automatically.

+
+
{
+    "type": "pocketpy",
+    "request": "launch",
+    "name": "Launch pocketpy program",
+    "port": 6110,
+    "host": "localhost",
+    "sourceFolder": "${workspaceFolder}",
+    "program": "${workspaceFolder}/pocketpy/main.exe",
+    "args": [
+        "--debug"
+    ],
+    "cwd": "${workspaceFolder}"
+}
+
+ +

+ # + Showcase +

+
+

+ debugger_demo +
debugger_demo
+
+

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/features/differences/index.html b/features/differences/index.html new file mode 100644 index 00000000..f79cf062 --- /dev/null +++ b/features/differences/index.html @@ -0,0 +1,385 @@ + + + + + + + + + + + + Comparison with CPython | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Comparison with CPython +

+
+

cpython is the reference implementation of the Python programming language. It is written in C and is the most widely used implementation of Python.

+ +

+ # + The design goal +

+
+

pkpy aims to be an alternative to lua for +game scripting, not cpython for general purpose programming.

+
    +
  • For syntax and semantics, pkpy is designed to be as close to cpython as possible.
  • +
  • For ecosystem and others, pkpy is not compatible with cpython.
  • +
+

pkpy supports most of the syntax and semantics of python. +For performance and simplicity, some features are not implemented, or behave differently. +The easiest way to test a feature is to try it on your browser.

+ +

+ # + Unimplemented features +

+
+
    +
  1. Descriptor protocol __get__ and __set__. However, @property is implemented.
  2. +
  3. __slots__ in class definition.
  4. +
  5. else clause in try..except.
  6. +
  7. Inplace methods like __iadd__ and __imul__.
  8. +
  9. __del__ in class definition.
  10. +
  11. Multiple inheritance.
  12. +
+ +

+ # + Different behaviors +

+
+
    +
  1. positional and keyword arguments are strictly evaluated.
  2. +
  3. int does not derive from bool.
  4. +
  5. int is 64-bit.
  6. +
  7. Raw string cannot have boundary quotes in it, even escaped. See #55.
  8. +
  9. In a starred unpacked assignment, e.g. a, b, *c = x, the starred variable can only be presented in the last position. a, *b, c = x is not supported.
  10. +
  11. A Tab is equivalent to 4 spaces. You can mix Tab and spaces in indentation, but it is not recommended.
  12. +
  13. A return, break, continue in try/except/with block will make the finally block not executed.
  14. +
  15. match is a keyword and match..case is equivalent to if..elif..else.
  16. +
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/features/profiling/index.html b/features/profiling/index.html new file mode 100644 index 00000000..1407e85e --- /dev/null +++ b/features/profiling/index.html @@ -0,0 +1,374 @@ + + + + + + + + + + + + Profiling | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Profiling +

+
+

To profile your pocketpy program, you can run main.exe with --profile flag.

+

For example, to profile test/test_math.py, run

+
+
main.exe --profile test/test_math.py
+
+

This will output a JSON report file named profile_report.json in the current directory, +which records the time spent for each line. To visualize the report, please install our VSCode extension.

+

https://marketplace.visualstudio.com/items?itemName=pocketpy.pocketpy

+
+
+ +
+

With pocketpy VSCode extension, press F1 and type pocketpy: Load Line Profiler Report, +select 1. the profile_report.json file; 2. the source root of the program. Then you will see a nice visualization of the profiling result.

+

+ profiler_report +
profiler_report
+
+

+

Press ESC to exit the report view.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/features/threading/index.html b/features/threading/index.html new file mode 100644 index 00000000..b48d26c4 --- /dev/null +++ b/features/threading/index.html @@ -0,0 +1,490 @@ + + + + + + + + + + + + Threading | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Threading +

+
+

pocketpy organizes its state by VM structure. +Users can have at maximum 16 VM instances (index from 0 to 15). +Each VM instance can only be accessed by exactly one thread at a time. +If you are trying to run two python scripts in parallel refering the same VM instance, +you will crash it definitely.

+

However, there are two ways to achieve multi-threading in pocketpy.

+

One way is to use a native threading library such as pthread. +You can wrap the multi-threading logic into a C function and bind it to pocketpy. +Be careful and not to access the same VM instance from multiple threads at the same time. +You need to lock critical resources or perform a deep copy of all needed data.

+ +

+ # + ComputeThread +

+
+

The other way is to use pkpy.ComputeThread. +It is like an isolate in Dart language. +ComputeThread is a true multi-threading model to allow you run python scripts in parallel without lock, +backed by a separate VM instance.

+

ComputeThread is highly designed for computational intensive tasks in games. +For example, you can run game logic in main thread (VM 0) and run world generation in another thread (e.g. VM 1).

+
graph TD
+    subgraph Main Thread
+        A[Game Start]
+        B[Submit WorldGen Job]
+        C[Frame 1]
+        D[Frame 2]
+        E[Frame 3]
+        F[...]
+        G[Get WorldGen Result]
+        H[Render World]
+    end
+    subgraph WorldGen Thread
+        O[Generate Biomes]
+        P[Generate Terrain]
+        Q[Generate Creatures]
+        R[Dump Result]
+    end
+    A --> B
+    B --> C
+    C --> D
+    D --> E
+    E --> F
+    F --> G
+    G --> H
+
+    O --> P
+    P --> Q
+    Q --> R
+
+    B --> O
+    R --> G
+ +

+ # + main.py +

+
+
+
import time
+from pkpy import ComputeThread
+
+thread = ComputeThread(1)
+print("Game Start")
+
+# import worldgen.py
+thread.exec('from worldgen import gen_world')
+
+print("Submit WorldGen Job")
+thread.submit_call('gen_world', 3, (100, 100), 10)
+
+# wait for worldgen to finish
+for i in range(1, 100000):
+    print('Frame:', i)
+    time.sleep(1)
+    if thread.is_done:
+        break
+
+error = thread.last_error()
+if error is not None:
+    print("Error:", error)
+else:
+    retval = thread.last_retval()
+    biomes = retval['biomes']
+    terrain = retval['terrain']
+    creatures = retval['creatures']
+    print("World Generation Complete", len(biomes), len(terrain), len(creatures))
+
+ +

+ # + worldgen.py +

+
+
+
import time
+import random
+
+def gen_world(biome_count: int, terrain_size: tuple[int, int], creature_count: int) -> dict:
+    # simulate a long computation
+    time.sleep(3)
+
+    # generate world data
+    all_biomes = ["forest", "desert", "ocean", "mountain", "swamp"]
+    all_creatures = ["wolf", "bear", "fish", "bird", "lizard"]
+
+    width, height = terrain_size
+
+    terrain_data = [
+        random.randint(1, 10)
+        for _ in range(width * height)
+    ]
+
+    creatures = [
+        {
+            "name": random.choice(all_creatures),
+            "x": random.randint(0, width - 1),
+            "y": random.randint(0, height - 1),
+        }
+        for i in range(creature_count)
+    ]
+
+    return {
+        "biomes": all_biomes[:biome_count],
+        "terrain": terrain_data,
+        "creatures": creatures,
+    }
+
+

Run main.py and you will see the result like this:

+
+
Game Start
+Submit WorldGen Job
+Frame: 1
+Frame: 2
+Frame: 3
+Frame: 4
+World Generation Complete 3 10000 10
+
+

ComputeThread uses pickle module to serialize the data between threads. +Parameters and return values must be supported by pickle. +See pickle for more details.

+

Since ComputeThread is backed by a separate VM instance, +it does not share any state with the main thread +except for the parameters you pass to it. +Therefore, common python modules will be imported twice in each thread.

+

If you want to identify which VM instance the module is running in, +you can call pkpy.currentvm or let your ComputeThread set some special flags +before importing these modules.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/features/ub/index.html b/features/ub/index.html new file mode 100644 index 00000000..c21d104a --- /dev/null +++ b/features/ub/index.html @@ -0,0 +1,346 @@ + + + + + + + + + + + + Undefined Behaviour | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Undefined Behaviour +

+
+

These are the undefined behaviours of pkpy. The behaviour of pkpy is undefined if you do the following things.

+
    +
  1. Delete a builtin object. For example, del int.__add__.
  2. +
  3. Call an unbound method with the wrong type of self. For example, int.__add__('1', 2).
  4. +
  5. Type T's __new__ returns an object that is not an instance of T.
  6. +
  7. Call __new__ with a type that is not a subclass of type.
  8. +
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/gsoc2024/guide/index.html b/gsoc2024/guide/index.html new file mode 100644 index 00000000..93969719 --- /dev/null +++ b/gsoc2024/guide/index.html @@ -0,0 +1,407 @@ + + + + + + + + + + + + Application Guide | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Application Guide +

+
+

Before starting, please read the Ideas page and choose a project you are interested in. +Set up a C++ compiler, clone pocketpy sources from github and try to build. +This helps you confirm that your skills and experience match the requirements of the project.

+ +

+ # + Build guide for beginners +

+
+

First, you need to install these tools:

+
    +
  1. Python(>= 3.8), I am sure you already have it.
  2. +
  3. A C++ compiler, such as GCC, Clang or MSVC. If you are on Linux, gcc and g++ are already installed. If you are on Windows, you can install Visual Studio with C++ development tools.
  4. +
  5. CMake(>= 3.10), a cross-platform build tool. You can use pip install cmake to install it.
  6. +
+

Then, clone pocketpy sources from github and try to build:

+
+
git clone https://github.com/pocketpy/pocketpy
+cd pocketpy
+
+python cmake_build.py
+
+

If everything goes well, you will get a main executable (main.exe on Windows) in the root directory of pocketpy. +Simply run it and you will enter pocketpy's REPL.

+
+
pocketpy 1.4.0 (Jan 24 2024, 12:39:13) [32 bit] on emscripten
+https://github.com/pocketpy/pocketpy
+Type "exit()" to exit.
+>>>
+>>> "Hello, world"
+'Hello, world'
+
+ +

+ # + Application guide +

+
+

Your need to send an email to blueloveth@foxmail.com with the following information:

+
    +
  1. A brief introduction about yourself, including the most related open sourced project you have worked on before. It is highly recommended to attach your Github profile link.
  2. +
  3. A technical proposal for the project you are interested in working on, including: +
      +
    • Your understanding of the project.
    • +
    • The technical approach/architecture you will adopt.
    • +
    • The challenges you might face and how you will overcome them.
    • +
    +
  4. +
  5. A timeline for the project, including the milestones and deliverables.
  6. +
  7. Other information required by the Google Summer of Code program.
  8. +
+ +

+ # + Coding style guide +

+
+

See Coding Style Guide.

+ +

+ # + Contact us +

+
+

If you have any questions, you can join our Discord +or contact me via email. +We are glad to help you with your application.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/gsoc2024/ideas/index.html b/gsoc2024/ideas/index.html new file mode 100644 index 00000000..de237455 --- /dev/null +++ b/gsoc2024/ideas/index.html @@ -0,0 +1,383 @@ + + + + + + + + + + + + Project Ideas | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Project Ideas +

+
+ +

+ # + Implement pybind11 for bindings +

+
+
    +
  • Difficulty Level: 5/5 (Hard)
  • +
  • Skill: Advanced C++ with metaprogramming; Python
  • +
  • Project Length: Medium (175 hours)
  • +
+
+

https://summerofcode.withgoogle.com/archive/2024/projects/Ji2Mi97o

+
+

pocketpy has provided a low-level API for creating bindings. It is fast, lightweight and easy to debug. +However, it still requires a lot of boilerplate code to create bindings for complex C++ classes. +The community has long expected a high-level API for creating bindings.

+

pybind11 +is the most popular C++ library for creating Python bindings for CPython. A bunch of Python libraries are using it. pybind11 adopts a template metaprogramming approach to automatically generate bindings for C++ classes.

+

Our goal is to introduce a pybind11 compatible solution to pocketpy as an alternative way to create bindings +for functions and classes. +You can use C++17 features to implement it, instead of C++11 used in pybind11.

+

See https://github.com/pocketpy/pocketpy/issues/216 for more details.

+ +

+ # + Add numpy module +

+
+
    +
  • Difficulty Level: 4/5 (Intermediate)
  • +
  • Skill: Intermediate C++; Python; Linear Algebra
  • +
  • Project Length: Medium (175 hours)
  • +
+
+

https://summerofcode.withgoogle.com/archive/2024/projects/sJLuASSP

+
+

Though pocketpy is designed for game scripting, +some people are using it for scientific computing. +It would be nice to have a numpy module in pocketpy.

+

numpy is a huge project. +Our goal is to implement a most commonly used subset of numpy in pocketpy. +You can mix C++ and Python code to simplify the overall workloads.

+

See https://github.com/pocketpy/pocketpy/issues/202 for more details.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/gsoc2025/guide/index.html b/gsoc2025/guide/index.html new file mode 100644 index 00000000..a41aa96d --- /dev/null +++ b/gsoc2025/guide/index.html @@ -0,0 +1,407 @@ + + + + + + + + + + + + Application Guide | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Application Guide +

+
+

Before starting, please read the Ideas page and choose a project you are interested in. +Set up a C11 compiler, clone pocketpy sources from github and try to build. +This helps you confirm that your skills and experience match the requirements of the project.

+ +

+ # + Build guide for beginners +

+
+

First, you need to install these tools:

+
    +
  1. Python(>= 3.8), I am sure you already have it.
  2. +
  3. A C11 compiler, such as GCC, Clang or MSVC. If you are on Linux, gcc is already installed. If you are on Windows, you can install Visual Studio with C/C++ development tools.
  4. +
  5. CMake(>= 3.10), a cross-platform build tool. You can use pip install cmake to install it.
  6. +
+

Then, clone pocketpy sources from github and try to build:

+
+
git clone https://github.com/pocketpy/pocketpy
+cd pocketpy
+
+python cmake_build.py
+
+

If everything goes well, you will get a main executable (main.exe on Windows) in the root directory of pocketpy. +Simply run it and you will enter pocketpy's REPL.

+
+
pocketpy 2.0.5 (Jan 17 2025, 14:36:15) [64 bit] on darwin
+https://github.com/pocketpy/pocketpy
+Type "exit()" to exit.
+>>> 
+>>> "Hello, world"
+'Hello, world'
+
+ +

+ # + Application guide +

+
+

Your need to send an email to blueloveth@foxmail.com with the following information:

+
    +
  1. A brief introduction about yourself, including the most related open sourced project you have worked on before. It is highly recommended to attach your Github profile link.
  2. +
  3. A technical proposal for the project you are interested in working on, including: +
      +
    • Your understanding of the project.
    • +
    • The technical approach/architecture you will adopt.
    • +
    • The challenges you might face and how you will overcome them.
    • +
    +
  4. +
  5. A timeline for the project, including the milestones and deliverables.
  6. +
  7. Other information required by the Google Summer of Code program.
  8. +
+ +

+ # + Coding style guide +

+
+

See Coding Style Guide.

+ +

+ # + Contact us +

+
+

If you have any questions, you can join our Discord +or contact me via email. +We are glad to help you with your application.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/gsoc2025/ideas/index.html b/gsoc2025/ideas/index.html new file mode 100644 index 00000000..0582c006 --- /dev/null +++ b/gsoc2025/ideas/index.html @@ -0,0 +1,369 @@ + + + + + + + + + + + + Project Ideas | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Project Ideas +

+
+ +

+ # + VSCode plugin for debugging pocketpy applications +

+
+
    +
  • Difficulty Level: 3/5 (Medium)
  • +
  • Skill: TypeScript; C
  • +
  • Project Length: Medium
  • +
+

Community users have reported that there is no convenient way to debug python applications interpreted by pocketpy. Fortunately, VSCode provides a mechanism of Debugger Extension that allows us to integrate pocketpy debugger into VSCode UI through Debug Adapter Protocol (DAP).

+

This project aims to develop a VSCode plugin like Python Debugger, which implements DAP for pocketpy. With this plugin, users can launch their pocketpy applications in VSCode with breakpoints, call stacks, and variable inspection. Students with experience in TypeScript will be helpful for this project.

+ +

+ # + Develop math operators for cTensor library +

+
+
    +
  • Difficulty Level: 4/5 (Hard)
  • +
  • Skill: C; Further Mathematics
  • +
  • Project Length: Small or Medium
  • +
+

pocketpy is providing a tensor library cTensor for users who want to integrate neural networks into their applications. cTensor implements automatic differentiation and dynamic compute graph. It allows users to train and deploy neural networks on client-side devices like mobile phones and microcontrollers (e.g. ESP32-C3). We have a runable prototype located at pocketpy/cTensor. But math operators have not been implemented yet.

+

In this project, students will develop forward and backward math operators, as well as basic neural network layers and optimizers (e.g. SGD, Adam). The project is written in C11. +We expect students to have a good understanding of further mathematics and C programming.

+
+

This year we also accept custom project ideas. If you are not interested in the above, you can propose your own idea and contact me via blueloveth@foxmail.com. We will discuss the feasibility and mentorship for your idea.

+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/index.html b/index.html new file mode 100644 index 00000000..12477e17 --- /dev/null +++ b/index.html @@ -0,0 +1,407 @@ + + + + + + + + + + + + Welcome to pocketpy | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Welcome to pocketpy +

+
+

pocketpy is a portable Python 3.x interpreter, written in C11. +It aims to be an alternative to Lua for game scripting, with elegant syntax, powerful features and competitive performance. +pocketpy has no dependencies other than the C standard library, which can be easily integrated into your C/C++ project. +Developers are able to write Python bindings via C-API or pybind11 compatible interfaces.

+ + +

+ # + What it looks like +

+
+
+
def is_prime(x):
+  if x < 2:
+    return False
+  for i in range(2, x):
+    if x % i == 0:
+      return False
+  return True
+
+primes = [i for i in range(2, 20) if is_prime(i)]
+print(primes)
+# [2, 3, 5, 7, 11, 13, 17, 19]
+
+ +

+ # + Supported platforms +

+
+

pkpy should work on any platform with a C11 compiler. +These platforms are officially tested.

+
    +
  • Windows 64-bit
  • +
  • Linux 64-bit / 32-bit
  • +
  • macOS 64-bit
  • +
  • Android 64-bit / 32-bit
  • +
  • iOS 64-bit
  • +
  • Emscripten 32-bit
  • +
  • Raspberry Pi OS 64-bit
  • +
+ +

+ # + Star the repo +

+
+

If you find pkpy useful, consider star this repository (●'◡'●)

+ +

You can sponsor this project via these ways.

+ +

Your sponsorship will help us develop pkpy continuously.

+ +

+ # + Upgrade to v2.0 +

+
+

pkpy v2.0 is a C11 project instead of C++17. All your existing code for v1.x won't work anymore.

+

We provide two API sets for v2.0, C-API and pybind11 API (C++17). If you are a C user, use the C-API. If you are a C++ user, use the pybind11 API.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/license/index.html b/license/index.html new file mode 100644 index 00000000..d2818eaf --- /dev/null +++ b/license/index.html @@ -0,0 +1,356 @@ + + + + + + + + + + + + License | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + License +

+
+

pkpy is licensed under the MIT License.

+
+
MIT License
+
+Copyright (c) 2025 blueloveTH
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/array2d/index.html b/modules/array2d/index.html new file mode 100644 index 00000000..c38382f9 --- /dev/null +++ b/modules/array2d/index.html @@ -0,0 +1,517 @@ + + + + + + + + + + + + array2d | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + array2d +

+
+

Efficient general-purpose 2D array.

+ +

+ # + Source code +

+
+
+
from typing import Callable, Literal, overload, Iterator, Self
+from vmath import vec2i
+
+Neighborhood = Literal['Moore', 'von Neumann']
+
+class array2d_like[T]:
+    @property
+    def n_cols(self) -> int: ...
+    @property
+    def n_rows(self) -> int: ...
+    @property
+    def width(self) -> int: ...
+    @property
+    def height(self) -> int: ...
+    @property
+    def shape(self) -> vec2i: ...
+    @property
+    def numel(self) -> int: ...
+
+    @overload
+    def is_valid(self, col: int, row: int) -> bool: ...
+    @overload
+    def is_valid(self, pos: vec2i) -> bool: ...
+
+    def get[R](self, col: int, row: int, default: R = None) -> T | R:
+        """Get the value at the given position.
+
+        If the position is out of bounds, returns the default value.
+        """
+
+    def index(self, value: T) -> vec2i:
+        """Get the position of the first occurrence of the given value.
+
+        Raises `ValueError` if the value is not found.
+        """
+
+    def render(self) -> str: ...
+
+    def all(self: array2d_like[bool]) -> bool: ...
+    def any(self: array2d_like[bool]) -> bool: ...
+
+    def map[R](self, f: Callable[[T], R]) -> array2d[R]: ...
+    def apply(self, f: Callable[[T], T]) -> None: ...
+    def zip_with[R, U](self, other: array2d_like[U], f: Callable[[T, U], R]) -> array2d[R]: ...
+    def copy(self) -> 'array2d[T]': ...
+    def tolist(self) -> list[list[T]]: ...
+
+    def __le__(self, other: T | array2d_like[T]) -> array2d[bool]: ...
+    def __lt__(self, other: T | array2d_like[T]) -> array2d[bool]: ...
+    def __ge__(self, other: T | array2d_like[T]) -> array2d[bool]: ...
+    def __gt__(self, other: T | array2d_like[T]) -> array2d[bool]: ...
+    def __eq__(self, other: T | array2d_like[T]) -> array2d[bool]: ...  # type: ignore
+    def __ne__(self, other: T | array2d_like[T]) -> array2d[bool]: ...  # type: ignore
+
+    def __add__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __sub__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __mul__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __truediv__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __floordiv__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __mod__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __pow__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+
+    def __and__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __or__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __xor__(self, other: T | array2d_like[T]) -> array2d[T]: ...
+    def __invert__(self) -> array2d[T]: ...
+
+    def __iter__(self) -> Iterator[tuple[vec2i, T]]: ...
+    def __repr__(self) -> str: ...
+
+    @overload
+    def __getitem__(self, index: vec2i) -> T: ...
+    @overload
+    def __getitem__(self, index: tuple[int, int]) -> T: ...
+    @overload
+    def __getitem__(self, index: tuple[slice, slice]) -> array2d_view[T]: ...
+    @overload
+    def __getitem__(self, index: tuple[slice, int] | tuple[int, slice]) -> array2d_view[T]: ...
+    @overload
+    def __getitem__(self, mask: array2d_like[bool]) -> list[T]: ...
+    @overload
+    def __setitem__(self, index: vec2i, value: T): ...
+    @overload
+    def __setitem__(self, index: tuple[int, int], value: T): ...
+    @overload
+    def __setitem__(self, index: tuple[slice, slice], value: T | 'array2d_like[T]'): ...
+    @overload
+    def __setitem__(self, index: tuple[slice, int] | tuple[int, slice], value: T | 'array2d_like[T]'): ...
+    @overload
+    def __setitem__(self, mask: array2d_like[bool], value: T): ...
+
+    # algorithms
+    def count(self, value: T) -> int:
+        """Count the number of cells with the given value."""
+
+    def count_neighbors(self, value: T, neighborhood: Neighborhood) -> array2d[int]:
+        """Count the number of neighbors with the given value for each cell."""
+
+    def get_bounding_rect(self, value: T) -> tuple[int, int, int, int]:
+        """Get the bounding rectangle of the given value.
+
+        Returns a tuple `(x, y, width, height)` or raise `ValueError` if the value is not found.
+        """
+
+    def convolve(self: array2d_like[int], kernel: array2d_like[int], padding: int) -> array2d[int]:
+        """Convolve the array with the given kernel."""
+
+    def get_connected_components(self, value: T, neighborhood: Neighborhood) -> tuple[array2d[int], int]:
+        """Get connected components of the grid via BFS algorithm.
+
+        Returns the `visited` array and the number of connected components,
+        where `0` means unvisited, and non-zero means the index of the connected component.
+        """
+
+
+class array2d_view[T](array2d_like[T]):
+    @property
+    def origin(self) -> vec2i: ...
+
+
+class array2d[T](array2d_like[T]):
+    def __new__(
+            cls,
+            n_cols: int,
+            n_rows: int,
+            default: T | Callable[[vec2i], T] | None = None
+            ): ...
+
+    @staticmethod
+    def fromlist(data: list[list[T]]) -> array2d[T]: ...
+
+
+class chunked_array2d[T, TContext]:
+    def __new__(
+            cls,
+            chunk_size: int,
+            default: T = None,
+            context_builder: Callable[[vec2i], TContext] | None = None,
+            ): ...
+
+    @property
+    def chunk_size(self) -> int: ...
+    @property
+    def default(self) -> T: ...
+    @property
+    def context_builder(self) -> Callable[[vec2i], TContext] | None: ...
+
+    def __getitem__(self, index: vec2i) -> T: ...
+    def __setitem__(self, index: vec2i, value: T): ...
+    def __delitem__(self, index: vec2i): ...
+    def __iter__(self) -> Iterator[tuple[vec2i, TContext]]: ...
+    def __len__(self) -> int: ...
+
+    def clear(self) -> None: ...
+    def copy(self) -> Self: ...
+
+    def world_to_chunk(self, world_pos: vec2i) -> tuple[vec2i, vec2i]:
+        """Converts world position to chunk position and local position."""
+
+    def add_chunk(self, chunk_pos: vec2i) -> TContext: ...
+    def remove_chunk(self, chunk_pos: vec2i) -> bool: ...
+    def move_chunk(self, src_chunk_pos: vec2i, dst_chunk_pos: vec2i) -> bool: ...
+    def get_context(self, chunk_pos: vec2i) -> TContext | None: ...
+
+    def view(self) -> array2d_view[T]: ...
+    def view_rect(self, pos: vec2i, width: int, height: int) -> array2d_view[T]: ...
+    def view_chunk(self, chunk_pos: vec2i) -> array2d_view[T]: ...
+    def view_chunks(self, chunk_pos: vec2i, width: int, height: int) -> array2d_view[T]: ...
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/base64/index.html b/modules/base64/index.html new file mode 100644 index 00000000..4dc02760 --- /dev/null +++ b/modules/base64/index.html @@ -0,0 +1,353 @@ + + + + + + + + + + + + base64 | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + base64 +

+
+ +

+ # + base64.b64encode(b: bytes) -> bytes +

+
+

Encode bytes-like object b using the standard Base64 alphabet.

+ +

+ # + base64.b64decode(b: str | bytes) -> bytes +

+
+

Decode Base64 encoded bytes-like object b.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/bisect/index.html b/modules/bisect/index.html new file mode 100644 index 00000000..94dff38d --- /dev/null +++ b/modules/bisect/index.html @@ -0,0 +1,450 @@ + + + + + + + + + + + + bisect | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + bisect +

+
+ +

+ # + bisect.bisect_left(a, x) +

+
+

Return the index where to insert item x in list a, assuming a is sorted.

+ +

+ # + bisect.bisect_right(a, x) +

+
+

Return the index where to insert item x in list a, assuming a is sorted.

+ +

+ # + bisect.insort_left(a, x) +

+
+

Insert item x in list a, and keep it sorted assuming a is sorted.

+

If x is already in a, insert it to the left of the leftmost x.

+ +

+ # + bisect.insort_right(a, x) +

+
+

Insert item x in list a, and keep it sorted assuming a is sorted.

+

If x is already in a, insert it to the right of the rightmost x.

+ +

+ # + Source code +

+
+
+
"""Bisection algorithms."""
+
+def insort_right(a, x, lo=0, hi=None):
+    """Insert item x in list a, and keep it sorted assuming a is sorted.
+
+    If x is already in a, insert it to the right of the rightmost x.
+
+    Optional args lo (default 0) and hi (default len(a)) bound the
+    slice of a to be searched.
+    """
+
+    lo = bisect_right(a, x, lo, hi)
+    a.insert(lo, x)
+
+def bisect_right(a, x, lo=0, hi=None):
+    """Return the index where to insert item x in list a, assuming a is sorted.
+
+    The return value i is such that all e in a[:i] have e <= x, and all e in
+    a[i:] have e > x.  So if x already appears in the list, a.insert(x) will
+    insert just after the rightmost x already there.
+
+    Optional args lo (default 0) and hi (default len(a)) bound the
+    slice of a to be searched.
+    """
+
+    if lo < 0:
+        raise ValueError('lo must be non-negative')
+    if hi is None:
+        hi = len(a)
+    while lo < hi:
+        mid = (lo+hi)//2
+        if x < a[mid]: hi = mid
+        else: lo = mid+1
+    return lo
+
+def insort_left(a, x, lo=0, hi=None):
+    """Insert item x in list a, and keep it sorted assuming a is sorted.
+
+    If x is already in a, insert it to the left of the leftmost x.
+
+    Optional args lo (default 0) and hi (default len(a)) bound the
+    slice of a to be searched.
+    """
+
+    lo = bisect_left(a, x, lo, hi)
+    a.insert(lo, x)
+
+
+def bisect_left(a, x, lo=0, hi=None):
+    """Return the index where to insert item x in list a, assuming a is sorted.
+
+    The return value i is such that all e in a[:i] have e < x, and all e in
+    a[i:] have e >= x.  So if x already appears in the list, a.insert(x) will
+    insert just before the leftmost x already there.
+
+    Optional args lo (default 0) and hi (default len(a)) bound the
+    slice of a to be searched.
+    """
+
+    if lo < 0:
+        raise ValueError('lo must be non-negative')
+    if hi is None:
+        hi = len(a)
+    while lo < hi:
+        mid = (lo+hi)//2
+        if a[mid] < x: lo = mid+1
+        else: hi = mid
+    return lo
+
+# Create aliases
+bisect = bisect_right
+insort = insort_right
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/cmath/index.html b/modules/cmath/index.html new file mode 100644 index 00000000..fbcd1e5d --- /dev/null +++ b/modules/cmath/index.html @@ -0,0 +1,537 @@ + + + + + + + + + + + + cmath | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + cmath +

+
+

Mathematical functions for complex numbers.

+

https://docs.python.org/3/library/cmath.html

+ +

+ # + Source code +

+
+
+
import math
+
+class complex:
+    def __init__(self, real, imag=0):
+        self._real = float(real)
+        self._imag = float(imag)
+
+    @property
+    def real(self):
+        return self._real
+
+    @property
+    def imag(self):
+        return self._imag
+
+    def conjugate(self):
+        return complex(self.real, -self.imag)
+
+    def __repr__(self):
+        s = ['(', str(self.real)]
+        s.append('-' if self.imag < 0 else '+')
+        s.append(str(abs(self.imag)))
+        s.append('j)')
+        return ''.join(s)
+
+    def __eq__(self, other):
+        if type(other) is complex:
+            return self.real == other.real and self.imag == other.imag
+        if type(other) in (int, float):
+            return self.real == other and self.imag == 0
+        return NotImplemented
+
+    def __ne__(self, other):
+        res = self == other
+        if res is NotImplemented:
+            return res
+        return not res
+
+    def __add__(self, other):
+        if type(other) is complex:
+            return complex(self.real + other.real, self.imag + other.imag)
+        if type(other) in (int, float):
+            return complex(self.real + other, self.imag)
+        return NotImplemented
+
+    def __radd__(self, other):
+        return self.__add__(other)
+
+    def __sub__(self, other):
+        if type(other) is complex:
+            return complex(self.real - other.real, self.imag - other.imag)
+        if type(other) in (int, float):
+            return complex(self.real - other, self.imag)
+        return NotImplemented
+
+    def __rsub__(self, other):
+        if type(other) is complex:
+            return complex(other.real - self.real, other.imag - self.imag)
+        if type(other) in (int, float):
+            return complex(other - self.real, -self.imag)
+        return NotImplemented
+
+    def __mul__(self, other):
+        if type(other) is complex:
+            return complex(self.real * other.real - self.imag * other.imag,
+                           self.real * other.imag + self.imag * other.real)
+        if type(other) in (int, float):
+            return complex(self.real * other, self.imag * other)
+        return NotImplemented
+
+    def __rmul__(self, other):
+        return self.__mul__(other)
+
+    def __truediv__(self, other):
+        if type(other) is complex:
+            denominator = other.real ** 2 + other.imag ** 2
+            real_part = (self.real * other.real + self.imag * other.imag) / denominator
+            imag_part = (self.imag * other.real - self.real * other.imag) / denominator
+            return complex(real_part, imag_part)
+        if type(other) in (int, float):
+            return complex(self.real / other, self.imag / other)
+        return NotImplemented
+
+    def __pow__(self, other: int | float):
+        if type(other) in (int, float):
+            return complex(self.__abs__() ** other * math.cos(other * phase(self)),
+                           self.__abs__() ** other * math.sin(other * phase(self)))
+        return NotImplemented
+
+    def __abs__(self) -> float:
+        return math.sqrt(self.real ** 2 + self.imag ** 2)
+
+    def __neg__(self):
+        return complex(-self.real, -self.imag)
+
+    def __hash__(self):
+        return hash((self.real, self.imag))
+
+
+# Conversions to and from polar coordinates
+
+def phase(z: complex):
+    return math.atan2(z.imag, z.real)
+
+def polar(z: complex):
+    return z.__abs__(), phase(z)
+
+def rect(r: float, phi: float):
+    return r * math.cos(phi) + r * math.sin(phi) * 1j
+
+# Power and logarithmic functions
+
+def exp(z: complex):
+    return math.exp(z.real) * rect(1, z.imag)
+
+def log(z: complex, base=2.718281828459045):
+    return math.log(z.__abs__(), base) + phase(z) * 1j
+
+def log10(z: complex):
+    return log(z, 10)
+
+def sqrt(z: complex):
+    return z ** 0.5
+
+# Trigonometric functions
+
+def acos(z: complex):
+    return -1j * log(z + sqrt(z * z - 1))
+
+def asin(z: complex):
+    return -1j * log(1j * z + sqrt(1 - z * z))
+
+def atan(z: complex):
+    return 1j / 2 * log((1 - 1j * z) / (1 + 1j * z))
+
+def cos(z: complex):
+    return (exp(z) + exp(-z)) / 2
+
+def sin(z: complex):
+    return (exp(z) - exp(-z)) / (2 * 1j)
+
+def tan(z: complex):
+    return sin(z) / cos(z)
+
+# Hyperbolic functions
+
+def acosh(z: complex):
+    return log(z + sqrt(z * z - 1))
+
+def asinh(z: complex):
+    return log(z + sqrt(z * z + 1))
+
+def atanh(z: complex):
+    return 1 / 2 * log((1 + z) / (1 - z))
+
+def cosh(z: complex):
+    return (exp(z) + exp(-z)) / 2
+
+def sinh(z: complex):
+    return (exp(z) - exp(-z)) / 2
+
+def tanh(z: complex):
+    return sinh(z) / cosh(z)
+
+# Classification functions
+
+def isfinite(z: complex):
+    return math.isfinite(z.real) and math.isfinite(z.imag)
+
+def isinf(z: complex):
+    return math.isinf(z.real) or math.isinf(z.imag)
+
+def isnan(z: complex):
+    return math.isnan(z.real) or math.isnan(z.imag)
+
+def isclose(a: complex, b: complex):
+    return math.isclose(a.real, b.real) and math.isclose(a.imag, b.imag)
+
+# Constants
+
+pi = math.pi
+e = math.e
+tau = 2 * pi
+inf = math.inf
+infj = complex(0, inf)
+nan = math.nan
+nanj = complex(0, nan)
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/collections/index.html b/modules/collections/index.html new file mode 100644 index 00000000..3dfdce62 --- /dev/null +++ b/modules/collections/index.html @@ -0,0 +1,537 @@ + + + + + + + + + + + + collections | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + collections +

+
+ +

+ # + collections.Counter(iterable) +

+
+

Return a dict containing the counts of each element in iterable.

+ +

+ # + collections.deque +

+
+

A double-ended queue.

+ +

+ # + collections.defaultdict +

+
+

A dictionary that returns a default value when a key is not found.

+ +

+ # + Source code +

+
+
+
from typing import TypeVar, Iterable
+
+def Counter[T](iterable: Iterable[T]):
+    a: dict[T, int] = {}
+    for x in iterable:
+        if x in a:
+            a[x] += 1
+        else:
+            a[x] = 1
+    return a
+
+
+class defaultdict(dict):
+    def __init__(self, default_factory, *args):
+        super().__init__(*args)
+        self.default_factory = default_factory
+
+    def __missing__(self, key):
+        self[key] = self.default_factory()
+        return self[key]
+
+    def __repr__(self) -> str:
+        return f"defaultdict({self.default_factory}, {super().__repr__()})"
+
+    def copy(self):
+        return defaultdict(self.default_factory, self)
+
+
+class deque[T]:
+    _head: int
+    _tail: int
+    _maxlen: int | None
+    _capacity: int
+    _data: list[T]
+
+    def __init__(self, iterable: Iterable[T] = None, maxlen: int | None = None):
+        if maxlen is not None:
+            assert maxlen > 0
+
+        self._head = 0
+        self._tail = 0
+        self._maxlen = maxlen
+        self._capacity = 8 if maxlen is None else maxlen + 1
+        self._data = [None] * self._capacity # type: ignore
+
+        if iterable is not None:
+            self.extend(iterable)
+
+    @property
+    def maxlen(self) -> int | None:
+        return self._maxlen
+
+    def __resize_2x(self):
+        backup = list(self)
+        self._capacity *= 2
+        self._head = 0
+        self._tail = len(backup)
+        self._data.clear()
+        self._data.extend(backup)
+        self._data.extend([None] * (self._capacity - len(backup)))
+
+    def append(self, x: T):
+        if (self._tail + 1) % self._capacity == self._head:
+            if self._maxlen is None:
+                self.__resize_2x()
+            else:
+                self.popleft()
+        self._data[self._tail] = x
+        self._tail = (self._tail + 1) % self._capacity
+
+    def appendleft(self, x: T):
+        if (self._tail + 1) % self._capacity == self._head:
+            if self._maxlen is None:
+                self.__resize_2x()
+            else:
+                self.pop()
+        self._head = (self._head - 1) % self._capacity
+        self._data[self._head] = x
+
+    def copy(self):
+        return deque(self, maxlen=self.maxlen)
+
+    def count(self, x: T) -> int:
+        n = 0
+        for item in self:
+            if item == x:
+                n += 1
+        return n
+
+    def extend(self, iterable: Iterable[T]):
+        for x in iterable:
+            self.append(x)
+
+    def extendleft(self, iterable: Iterable[T]):
+        for x in iterable:
+            self.appendleft(x)
+
+    def pop(self) -> T:
+        if self._head == self._tail:
+            raise IndexError("pop from an empty deque")
+        self._tail = (self._tail - 1) % self._capacity
+        x = self._data[self._tail]
+        self._data[self._tail] = None
+        return x
+
+    def popleft(self) -> T:
+        if self._head == self._tail:
+            raise IndexError("pop from an empty deque")
+        x = self._data[self._head]
+        self._data[self._head] = None
+        self._head = (self._head + 1) % self._capacity
+        return x
+
+    def clear(self):
+        i = self._head
+        while i != self._tail:
+            self._data[i] = None # type: ignore
+            i = (i + 1) % self._capacity
+        self._head = 0
+        self._tail = 0
+
+    def rotate(self, n: int = 1):
+        if len(self) == 0:
+            return
+        if n > 0:
+            n = n % len(self)
+            for _ in range(n):
+                self.appendleft(self.pop())
+        elif n < 0:
+            n = -n % len(self)
+            for _ in range(n):
+                self.append(self.popleft())
+
+    def __len__(self) -> int:
+        return (self._tail - self._head) % self._capacity
+
+    def __contains__(self, x: object) -> bool:
+        for item in self:
+            if item == x:
+                return True
+        return False
+
+    def __iter__(self):
+        i = self._head
+        while i != self._tail:
+            yield self._data[i]
+            i = (i + 1) % self._capacity
+
+    def __eq__(self, other: object) -> bool:
+        if not isinstance(other, deque):
+            return NotImplemented
+        if len(self) != len(other):
+            return False
+        for x, y in zip(self, other):
+            if x != y:
+                return False
+        return True
+
+    def __ne__(self, other: object) -> bool:
+        if not isinstance(other, deque):
+            return NotImplemented
+        return not self == other
+
+    def __repr__(self) -> str:
+        if self.maxlen is None:
+            return f"deque({list(self)!r})"
+        return f"deque({list(self)!r}, maxlen={self.maxlen})"
+
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/colorcvt/index.html b/modules/colorcvt/index.html new file mode 100644 index 00000000..5ea236d8 --- /dev/null +++ b/modules/colorcvt/index.html @@ -0,0 +1,357 @@ + + + + + + + + + + + + colorcvt | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + colorcvt +

+
+

Provide color conversion functions.

+ +

+ # + Source code +

+
+
+
from vmath import vec3
+
+def linear_srgb_to_srgb(rgb: vec3) -> vec3: ...
+def srgb_to_linear_srgb(rgb: vec3) -> vec3: ...
+def srgb_to_hsv(rgb: vec3) -> vec3: ...
+def hsv_to_srgb(hsv: vec3) -> vec3: ...
+def oklch_to_linear_srgb(lch: vec3) -> vec3: ...
+def linear_srgb_to_oklch(rgb: vec3) -> vec3: ...
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/cute_png/index.html b/modules/cute_png/index.html new file mode 100644 index 00000000..0092bb7a --- /dev/null +++ b/modules/cute_png/index.html @@ -0,0 +1,371 @@ + + + + + + + + + + + + cute_png | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + cute_png +

+
+
+
+ +
+

Wraps cute_png.h for PNG image loading and saving.

+ +

+ # + Source code +

+
+
+
from array2d import array2d
+from vmath import color32
+
+def loads(data: bytes) -> array2d[color32]: ...
+def dumps(image: array2d[color32]) -> bytes: ...
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/dataclasses/index.html b/modules/dataclasses/index.html new file mode 100644 index 00000000..c2ba5f80 --- /dev/null +++ b/modules/dataclasses/index.html @@ -0,0 +1,437 @@ + + + + + + + + + + + + dataclasses | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + dataclasses +

+
+ +

+ # + dataclasses.dataclass +

+
+

A decorator that is used to add special method to classes, including __init__, __repr__ and __eq__.

+ +

+ # + dataclasses.asdict(obj) -> dict +

+
+

Convert a dataclass instance to a dictionary.

+ +

+ # + Source code +

+
+
+
def _get_annotations(cls: type):
+    inherits = []
+    while cls is not object:
+        inherits.append(cls)
+        cls = cls.__base__
+    inherits.reverse()
+    res = {}
+    for cls in inherits:
+        res.update(cls.__annotations__)
+    return res.keys()
+
+def _wrapped__init__(self, *args, **kwargs):
+    cls = type(self)
+    cls_d = cls.__dict__
+    fields = _get_annotations(cls)
+    i = 0   # index into args
+    for field in fields:
+        if field in kwargs:
+            setattr(self, field, kwargs.pop(field))
+        else:
+            if i < len(args):
+                setattr(self, field, args[i])
+                i += 1
+            elif field in cls_d:    # has default value
+                setattr(self, field, cls_d[field])
+            else:
+                raise TypeError(f"{cls.__name__} missing required argument {field!r}")
+    if len(args) > i:
+        raise TypeError(f"{cls.__name__} takes {len(fields)} positional arguments but {len(args)} were given")
+    if len(kwargs) > 0:
+        raise TypeError(f"{cls.__name__} got an unexpected keyword argument {next(iter(kwargs))!r}")
+
+def _wrapped__repr__(self):
+    fields = _get_annotations(type(self))
+    obj_d = self.__dict__
+    args: list = [f"{field}={obj_d[field]!r}" for field in fields]
+    return f"{type(self).__name__}({', '.join(args)})"
+
+def _wrapped__eq__(self, other):
+    if type(self) is not type(other):
+        return False
+    fields = _get_annotations(type(self))
+    for field in fields:
+        if getattr(self, field) != getattr(other, field):
+            return False
+    return True
+
+def _wrapped__ne__(self, other):
+    return not self.__eq__(other)
+
+def dataclass(cls: type):
+    assert type(cls) is type
+    cls_d = cls.__dict__
+    if '__init__' not in cls_d:
+        cls.__init__ = _wrapped__init__
+    if '__repr__' not in cls_d:
+        cls.__repr__ = _wrapped__repr__
+    if '__eq__' not in cls_d:
+        cls.__eq__ = _wrapped__eq__
+    if '__ne__' not in cls_d:
+        cls.__ne__ = _wrapped__ne__
+    fields = _get_annotations(cls)
+    has_default = False
+    for field in fields:
+        if field in cls_d:
+            has_default = True
+        else:
+            if has_default:
+                raise TypeError(f"non-default argument {field!r} follows default argument")
+    return cls
+
+def asdict(obj) -> dict:
+    fields = _get_annotations(type(obj))
+    obj_d = obj.__dict__
+    return {field: obj_d[field] for field in fields}
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/datetime/index.html b/modules/datetime/index.html new file mode 100644 index 00000000..06c219a4 --- /dev/null +++ b/modules/datetime/index.html @@ -0,0 +1,494 @@ + + + + + + + + + + + + datetime | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + datetime +

+
+ +

+ # + datetime.now() +

+
+

Returns the current date and time as a datetime object.

+ +

+ # + date.today() +

+
+

Returns the current local date as a date object.

+ +

+ # + Source code +

+
+
+
from time import localtime
+import operator
+
+class timedelta:
+    def __init__(self, days=0, seconds=0):
+        self.days = days
+        self.seconds = seconds
+
+    def __repr__(self):
+        return f"datetime.timedelta(days={self.days}, seconds={self.seconds})"
+
+    def __eq__(self, other) -> bool:
+        if not isinstance(other, timedelta):
+            return NotImplemented
+        return (self.days, self.seconds) == (other.days, other.seconds)
+
+    def __ne__(self, other) -> bool:
+        if not isinstance(other, timedelta):
+            return NotImplemented
+        return (self.days, self.seconds) != (other.days, other.seconds)
+
+
+class date:
+    def __init__(self, year: int, month: int, day: int):
+        self.year = year
+        self.month = month
+        self.day = day
+
+    @staticmethod
+    def today():
+        t = localtime()
+        return date(t.tm_year, t.tm_mon, t.tm_mday)
+
+    def __cmp(self, other, op):
+        if not isinstance(other, date):
+            return NotImplemented
+        if self.year != other.year:
+            return op(self.year, other.year)
+        if self.month != other.month:
+            return op(self.month, other.month)
+        return op(self.day, other.day)
+
+    def __eq__(self, other) -> bool:
+        return self.__cmp(other, operator.eq)
+
+    def __ne__(self, other) -> bool:
+        return self.__cmp(other, operator.ne)
+
+    def __lt__(self, other: 'date') -> bool:
+        return self.__cmp(other, operator.lt)
+
+    def __le__(self, other: 'date') -> bool:
+        return self.__cmp(other, operator.le)
+
+    def __gt__(self, other: 'date') -> bool:
+        return self.__cmp(other, operator.gt)
+
+    def __ge__(self, other: 'date') -> bool:
+        return self.__cmp(other, operator.ge)
+
+    def __str__(self):
+        return f"{self.year}-{self.month:02}-{self.day:02}"
+
+    def __repr__(self):
+        return f"datetime.date({self.year}, {self.month}, {self.day})"
+
+
+class datetime(date):
+    def __init__(self, year: int, month: int, day: int, hour: int, minute: int, second: int):
+        super().__init__(year, month, day)
+        # Validate and set hour, minute, and second
+        if not 0 <= hour <= 23:
+            raise ValueError("Hour must be between 0 and 23")
+        self.hour = hour
+        if not 0 <= minute <= 59:
+            raise ValueError("Minute must be between 0 and 59")
+        self.minute = minute
+        if not 0 <= second <= 59:
+            raise ValueError("Second must be between 0 and 59")
+        self.second = second
+
+    def date(self) -> date:
+        return date(self.year, self.month, self.day)
+
+    @staticmethod
+    def now():
+        t = localtime()
+        tm_sec = t.tm_sec
+        if tm_sec == 60:
+            tm_sec = 59
+        return datetime(t.tm_year, t.tm_mon, t.tm_mday, t.tm_hour, t.tm_min, tm_sec)
+
+    def __str__(self):
+        return f"{self.year}-{self.month:02}-{self.day:02} {self.hour:02}:{self.minute:02}:{self.second:02}"
+
+    def __repr__(self):
+        return f"datetime.datetime({self.year}, {self.month}, {self.day}, {self.hour}, {self.minute}, {self.second})"
+
+    def __cmp(self, other, op):
+        if not isinstance(other, datetime):
+            return NotImplemented
+        if self.year != other.year:
+            return op(self.year, other.year)
+        if self.month != other.month:
+            return op(self.month, other.month)
+        if self.day != other.day:
+            return op(self.day, other.day)
+        if self.hour != other.hour:
+            return op(self.hour, other.hour)
+        if self.minute != other.minute:
+            return op(self.minute, other.minute)
+        return op(self.second, other.second)
+
+    def __eq__(self, other) -> bool:
+        return self.__cmp(other, operator.eq)
+
+    def __ne__(self, other) -> bool:
+        return self.__cmp(other, operator.ne)
+
+    def __lt__(self, other) -> bool:
+        return self.__cmp(other, operator.lt)
+
+    def __le__(self, other) -> bool:
+        return self.__cmp(other, operator.le)
+
+    def __gt__(self, other) -> bool:
+        return self.__cmp(other, operator.gt)
+
+    def __ge__(self, other) -> bool:
+        return self.__cmp(other, operator.ge)
+
+
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/easing/index.html b/modules/easing/index.html new file mode 100644 index 00000000..a819dde6 --- /dev/null +++ b/modules/easing/index.html @@ -0,0 +1,373 @@ + + + + + + + + + + + + easing | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + easing +

+
+

Python wrapper for easing functions.

+
    +
  • easing.Linear(t: float) -> float
  • +
  • easing.InSine(t: float) -> float
  • +
  • easing.OutSine(t: float) -> float
  • +
  • easing.InOutSine(t: float) -> float
  • +
  • easing.InQuad(t: float) -> float
  • +
  • easing.OutQuad(t: float) -> float
  • +
  • easing.InOutQuad(t: float) -> float
  • +
  • easing.InCubic(t: float) -> float
  • +
  • easing.OutCubic(t: float) -> float
  • +
  • easing.InOutCubic(t: float) -> float
  • +
  • easing.InQuart(t: float) -> float
  • +
  • easing.OutQuart(t: float) -> float
  • +
  • easing.InOutQuart(t: float) -> float
  • +
  • easing.InQuint(t: float) -> float
  • +
  • easing.OutQuint(t: float) -> float
  • +
  • easing.InOutQuint(t: float) -> float
  • +
  • easing.InExpo(t: float) -> float
  • +
  • easing.OutExpo(t: float) -> float
  • +
  • easing.InOutExpo(t: float) -> float
  • +
  • easing.InCirc(t: float) -> float
  • +
  • easing.OutCirc(t: float) -> float
  • +
  • easing.InOutCirc(t: float) -> float
  • +
  • easing.InBack(t: float) -> float
  • +
  • easing.OutBack(t: float) -> float
  • +
  • easing.InOutBack(t: float) -> float
  • +
  • easing.InElastic(t: float) -> float
  • +
  • easing.OutElastic(t: float) -> float
  • +
  • easing.InOutElastic(t: float) -> float
  • +
  • easing.InBounce(t: float) -> float
  • +
  • easing.OutBounce(t: float) -> float
  • +
  • easing.InOutBounce(t: float) -> float
  • +
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/enum/index.html b/modules/enum/index.html new file mode 100644 index 00000000..d715ebaa --- /dev/null +++ b/modules/enum/index.html @@ -0,0 +1,360 @@ + + + + + + + + + + + + enum | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + enum +

+
+ +

+ # + enum.Enum +

+
+

Base class for creating enumerated constants.

+

Example:

+
+
from enum import Enum
+
+class Color(Enum):
+    RED = 1
+    GREEN = 2
+    BLUE = 3
+
+print(Color.RED)    # Color.RED
+print(Color.RED.name)    # 'RED'
+print(Color.RED.value)    # 1
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/functools/index.html b/modules/functools/index.html new file mode 100644 index 00000000..952f22ab --- /dev/null +++ b/modules/functools/index.html @@ -0,0 +1,431 @@ + + + + + + + + + + + + functools | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + functools +

+
+ +

+ # + functools.cache +

+
+

A decorator that caches a function's return value each time it is called. If called later with the same arguments, the cached value is returned, and not re-evaluated.

+ +

+ # + functools.lru_cache(maxsize=128) +

+
+

A decorator that wraps a function with a memoizing callable that saves up to the maxsize most recent calls.

+ +

+ # + functools.reduce(function, sequence, initial=...) +

+
+

Apply a function of two arguments cumulatively to the items of a sequence, from left to right, so as to reduce the sequence to a single value. For example, functools.reduce(lambda x, y: x+y, [1, 2, 3, 4, 5]) calculates ((((1+2)+3)+4)+5). The left argument, x, is the accumulated value and the right argument, y, is the update value from the sequence. If the optional initial is present, it is placed before the items of the sequence in the calculation, and serves as a default when the sequence is empty.

+ +

+ # + functools.partial(f, *args, **kwargs) +

+
+

Return a new partial object which when called will behave like f called with the positional arguments args and keyword arguments kwargs. If more arguments are supplied to the call, they are appended to args. If additional keyword arguments are supplied, they extend and override kwargs.

+ +

+ # + Source code +

+
+
+
class cache:
+    def __init__(self, f):
+        self.f = f
+        self.cache = {}
+
+    def __call__(self, *args):
+        if args not in self.cache:
+            self.cache[args] = self.f(*args)
+        return self.cache[args]
+
+class lru_cache:
+    def __init__(self, maxsize=128):
+        self.maxsize = maxsize
+        self.cache = {}
+
+    def __call__(self, f):
+        def wrapped(*args):
+            if args in self.cache:
+                res = self.cache.pop(args)
+                self.cache[args] = res
+                return res
+
+            res = f(*args)
+            if len(self.cache) >= self.maxsize:
+                first_key = next(iter(self.cache))
+                self.cache.pop(first_key)
+            self.cache[args] = res
+            return res
+        return wrapped
+
+def reduce(function, sequence, initial=...):
+    it = iter(sequence)
+    if initial is ...:
+        try:
+            value = next(it)
+        except StopIteration:
+            raise TypeError("reduce() of empty sequence with no initial value")
+    else:
+        value = initial
+    for element in it:
+        value = function(value, element)
+    return value
+
+class partial:
+    def __init__(self, f, *args, **kwargs):
+        self.f = f
+        if not callable(f):
+            raise TypeError("the first argument must be callable")
+        self.args = args
+        self.kwargs = kwargs
+
+    def __call__(self, *args, **kwargs):
+        kwargs.update(self.kwargs)
+        return self.f(*self.args, *args, **kwargs)
+
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/gc/index.html b/modules/gc/index.html new file mode 100644 index 00000000..0ef81871 --- /dev/null +++ b/modules/gc/index.html @@ -0,0 +1,367 @@ + + + + + + + + + + + + gc | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + gc +

+
+ +

+ # + gc.collect() +

+
+

Invoke the garbage collector.

+ +

+ # + gc.enable() +

+
+

Enable automatic garbage collection.

+ +

+ # + gc.disable() +

+
+

Disable automatic garbage collection.

+ +

+ # + gc.isenabled() +

+
+

Return True if automatic garbage collection is enabled, False otherwise.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/heapq/index.html b/modules/heapq/index.html new file mode 100644 index 00000000..fa9eab71 --- /dev/null +++ b/modules/heapq/index.html @@ -0,0 +1,469 @@ + + + + + + + + + + + + heapq | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + heapq +

+
+ +

+ # + heapq.heappush(heap, item) +

+
+

Push the value item onto the heap, maintaining the heap invariant.

+ +

+ # + heapq.heappop(heap) +

+
+

Pop and return the smallest item from the heap, maintaining the heap invariant. If the heap is empty, IndexError is raised. To access the smallest item without popping it, use heap[0].

+ +

+ # + heapq.heapify(x) +

+
+

Transform list x into a heap, in-place, in linear time.

+ +

+ # + heapq.heappushpop(heap, item) +

+
+

Push item on the heap, then pop and return the smallest item from the heap. The combined action runs more efficiently than heappush() followed by a separate heappop().

+ +

+ # + heapq.heapreplace(heap, item) +

+
+

Pop and return the smallest item from the heap, and also push the new item. The heap size doesn’t change. If the heap is empty, IndexError is raised.

+ +

+ # + Source code +

+
+
+
# Heap queue algorithm (a.k.a. priority queue)
+def heappush(heap, item):
+    """Push item onto heap, maintaining the heap invariant."""
+    heap.append(item)
+    _siftdown(heap, 0, len(heap)-1)
+
+def heappop(heap):
+    """Pop the smallest item off the heap, maintaining the heap invariant."""
+    lastelt = heap.pop()    # raises appropriate IndexError if heap is empty
+    if heap:
+        returnitem = heap[0]
+        heap[0] = lastelt
+        _siftup(heap, 0)
+        return returnitem
+    return lastelt
+
+def heapreplace(heap, item):
+    """Pop and return the current smallest value, and add the new item.
+
+    This is more efficient than heappop() followed by heappush(), and can be
+    more appropriate when using a fixed-size heap.  Note that the value
+    returned may be larger than item!  That constrains reasonable uses of
+    this routine unless written as part of a conditional replacement:
+
+        if item > heap[0]:
+            item = heapreplace(heap, item)
+    """
+    returnitem = heap[0]    # raises appropriate IndexError if heap is empty
+    heap[0] = item
+    _siftup(heap, 0)
+    return returnitem
+
+def heappushpop(heap, item):
+    """Fast version of a heappush followed by a heappop."""
+    if heap and heap[0] < item:
+        item, heap[0] = heap[0], item
+        _siftup(heap, 0)
+    return item
+
+def heapify(x):
+    """Transform list into a heap, in-place, in O(len(x)) time."""
+    n = len(x)
+    # Transform bottom-up.  The largest index there's any point to looking at
+    # is the largest with a child index in-range, so must have 2*i + 1 < n,
+    # or i < (n-1)/2.  If n is even = 2*j, this is (2*j-1)/2 = j-1/2 so
+    # j-1 is the largest, which is n//2 - 1.  If n is odd = 2*j+1, this is
+    # (2*j+1-1)/2 = j so j-1 is the largest, and that's again n//2-1.
+    for i in reversed(range(n//2)):
+        _siftup(x, i)
+
+# 'heap' is a heap at all indices >= startpos, except possibly for pos.  pos
+# is the index of a leaf with a possibly out-of-order value.  Restore the
+# heap invariant.
+def _siftdown(heap, startpos, pos):
+    newitem = heap[pos]
+    # Follow the path to the root, moving parents down until finding a place
+    # newitem fits.
+    while pos > startpos:
+        parentpos = (pos - 1) >> 1
+        parent = heap[parentpos]
+        if newitem < parent:
+            heap[pos] = parent
+            pos = parentpos
+            continue
+        break
+    heap[pos] = newitem
+
+def _siftup(heap, pos):
+    endpos = len(heap)
+    startpos = pos
+    newitem = heap[pos]
+    # Bubble up the smaller child until hitting a leaf.
+    childpos = 2*pos + 1    # leftmost child position
+    while childpos < endpos:
+        # Set childpos to index of smaller child.
+        rightpos = childpos + 1
+        if rightpos < endpos and not heap[childpos] < heap[rightpos]:
+            childpos = rightpos
+        # Move the smaller child up.
+        heap[pos] = heap[childpos]
+        pos = childpos
+        childpos = 2*pos + 1
+    # The leaf at pos is empty now.  Put newitem there, and bubble it up
+    # to its final resting place (by sifting its parents down).
+    heap[pos] = newitem
+    _siftdown(heap, startpos, pos)
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/importlib/index.html b/modules/importlib/index.html new file mode 100644 index 00000000..83c02170 --- /dev/null +++ b/modules/importlib/index.html @@ -0,0 +1,346 @@ + + + + + + + + + + + + importlib | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + importlib +

+
+ +

+ # + importlib.reload(module) +

+
+

Reload a previously imported module. The argument must be a module object, so it must have been successfully imported before. This is useful if you have edited the module source file using an external editor and want to try out the new version without leaving the Python interpreter. The return value is the module object (the same as the argument).

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/json/index.html b/modules/json/index.html new file mode 100644 index 00000000..f5fe916f --- /dev/null +++ b/modules/json/index.html @@ -0,0 +1,353 @@ + + + + + + + + + + + + json | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + json +

+
+ +

+ # + json.loads(data: str) +

+
+

Decode a JSON string into a python object.

+ +

+ # + json.dumps(obj, indent=0) -> str +

+
+

Encode a python object into a JSON string.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/libhv/index.html b/modules/libhv/index.html new file mode 100644 index 00000000..a381f893 --- /dev/null +++ b/modules/libhv/index.html @@ -0,0 +1,486 @@ + + + + + + + + + + + + libhv | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + libhv +

+
+
+
+ +
+

libhv is a git submodule located at 3rd/libhv/libhv. If you cannot find it, please run the following command to initialize the submodule:

+
+
git submodule update --init --recursive
+
+

Simple bindings for libhv, which provides cross platform implementation of the following:

+
    +
  • HTTP server
  • +
  • HTTP client
  • +
  • WebSocket server
  • +
  • WebSocket client
  • +
+ +

+ # + Source code +

+
+
+
from typing import Literal, Generator, Callable, Union
+
+WsChannelId = int
+HttpStatusCode = int
+HttpHeaders = dict[str, str]
+ErrorCode = int
+
+class Future[T]:
+    @property
+    def completed(self) -> bool: ...
+    def cancel(self) -> None: ...
+    def __iter__(self) -> Generator[T, None, None]: ...
+
+class HttpResponse(Future['HttpResponse']):
+    @property
+    def status_code(self) -> int: ...
+    @property
+    def headers(self) -> dict[str, str]: ...
+    @property
+    def text(self) -> str: ...
+    @property
+    def content(self) -> bytes: ...
+
+    def json(self): ...
+
+
+class HttpClient:
+    def get(self, url: str, /, params=None, headers=None, timeout=10) -> HttpResponse: ...
+    def post(self, url: str, /, params=None, headers=None, data=None, json=None, timeout=10) -> HttpResponse: ...
+    def put(self, url: str, /, params=None, headers=None, data=None, json=None, timeout=10) -> HttpResponse: ...
+    def delete(self, url: str, /, params=None, headers=None, timeout=10) -> HttpResponse: ...
+
+
+class HttpRequest:
+    @property
+    def method(self) -> Literal['GET', 'POST', 'PUT', 'DELETE']: ...
+    @property
+    def path(self) -> str: ...
+    @property
+    def url(self) -> str: ...
+    @property
+    def headers(self) -> HttpHeaders: ...
+    @property
+    def data(self) -> str | bytes: ...
+
+class HttpServer:
+    def __init__(self, host: str, port: int, /) -> None: ...
+    def start(self) -> ErrorCode: ...
+    def stop(self) -> ErrorCode: ...
+    def dispatch[T](self, fn: Callable[
+        [HttpRequest],
+        T | tuple[T, HttpStatusCode] | tuple[T, HttpStatusCode, HttpHeaders]
+        ], /) -> bool:
+        """Dispatch one HTTP request through `fn`. `fn` should return one of the following:
+
+        + object
+        + (object, status_code)
+        + (object, status_code, headers)
+
+        Return `True` if dispatched, otherwise `False`.
+        """
+
+    def ws_set_ping_interval(self, milliseconds: int, /) -> None:
+        """Set WebSocket ping interval in milliseconds."""
+
+    def ws_close(self, channel: WsChannelId, /) -> ErrorCode:
+        """Close WebSocket channel."""
+
+    def ws_send(self, channel: WsChannelId, data: str, /) -> int:
+        """Send WebSocket message through `channel`."""
+
+    def ws_recv(self) -> Union[
+        tuple[Literal['onopen'], tuple[WsChannelId, HttpRequest]],
+        tuple[Literal['onmessage'], tuple[WsChannelId, str]],
+        tuple[Literal['onclose'], WsChannelId],
+        None
+    ]:
+        """Receive one WebSocket message.
+        Return one of the following or `None` if nothing to receive.
+
+        + `"onopen"`: (channel, request)
+        + `"onclose"`: channel
+        + `"onmessage"`: (channel, body)
+        """
+
+class WebSocketClient:
+    def open(self, url: str, headers=None, /) -> ErrorCode: ...
+    def close(self) -> ErrorCode: ...
+
+    def send(self, data: str, /) -> int:
+        """Send WebSocket message."""
+
+    def recv(self) -> Union[
+        tuple[Literal['onopen'], None],
+        tuple[Literal['onclose'], None],
+        tuple[Literal['onmessage'], str],
+        None
+    ]:
+        """Receive one WebSocket message.
+        Return one of the following or `None` if nothing to receive.
+
+        + `"onopen"`: `None`
+        + `"onclose"`: `None`
+        + `"onmessage"`: body
+        """
+
+
+def strerror(errno: ErrorCode, /) -> str:
+    """Get error message by errno via `hv_strerror`."""
+
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/lz4/index.html b/modules/lz4/index.html new file mode 100644 index 00000000..0b233d0f --- /dev/null +++ b/modules/lz4/index.html @@ -0,0 +1,377 @@ + + + + + + + + + + + + lz4 | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + lz4 +

+
+
+
+ +
+

LZ4 compression and decompression.

+ +

+ # + Source code +

+
+
+
def compress(data: bytes) -> bytes:
+    """Compress the given data into LZ4 block format.
+
+    This function is equivalent to `lz4.block.compress` of https://pypi.org/project/lz4/.
+    """
+
+def decompress(data: bytes) -> bytes:
+    """Decompress the given LZ4 block format data produced by `lz4.compress()`.
+
+    This function is equivalent to `lz4.block.decompress` of https://pypi.org/project/lz4/.
+    """
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/math/index.html b/modules/math/index.html new file mode 100644 index 00000000..2f74d461 --- /dev/null +++ b/modules/math/index.html @@ -0,0 +1,562 @@ + + + + + + + + + + + + math | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + math +

+
+ +

+ # + math.pi +

+
+

3.141592653589793

+ +

+ # + math.e +

+
+

2.718281828459045

+ +

+ # + math.inf +

+
+

The inf.

+ +

+ # + math.nan +

+
+

The nan.

+ +

+ # + math.ceil(x) +

+
+

Return the ceiling of x as a float, the smallest integer value greater than or equal to x.

+ +

+ # + math.fabs(x) +

+
+

Return the absolute value of x.

+ +

+ # + math.floor(x) +

+
+

Return the floor of x as a float, the largest integer value less than or equal to x.

+ +

+ # + math.fsum(iterable) +

+
+

Return an accurate floating point sum of values in the iterable. Avoids loss of precision by tracking multiple intermediate partial sums:

+
+
>>> sum([0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1])
+0.9999999999999999
+>>> fsum([0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1, 0.1])
+1.0
+
+ +

+ # + math.gcd(a, b) +

+
+

Return the greatest common divisor of the integers a and b.

+ +

+ # + math.isfinite(x) +

+
+

Return True if x is neither an infinity nor a NaN, and False otherwise.

+ +

+ # + math.isinf(x) +

+
+

Return True if x is a positive or negative infinity, and False otherwise.

+ +

+ # + math.isnan(x) +

+
+

Return True if x is a NaN (not a number), and False otherwise.

+ +

+ # + math.isclose(a, b) +

+
+

Return True if the values a and b are close to each other and False otherwise.

+ +

+ # + math.exp(x) +

+
+

Return e raised to the power of x.

+ +

+ # + math.log(x) +

+
+

Return the natural logarithm of x (to base e).

+ +

+ # + math.log2(x) +

+
+

Return the base-2 logarithm of x. This is usually more accurate than log(x, 2).

+ +

+ # + math.log10(x) +

+
+

Return the base-10 logarithm of x. This is usually more accurate than log(x, 10).

+ +

+ # + math.pow(x, y) +

+
+

Return x raised to the power y.

+ +

+ # + math.sqrt(x) +

+
+

Return the square root of x.

+ +

+ # + math.acos(x) +

+
+

Return the arc cosine of x, in radians.

+ +

+ # + math.asin(x) +

+
+

Return the arc sine of x, in radians.

+ +

+ # + math.atan(x) +

+
+

Return the arc tangent of x, in radians.

+ +

+ # + math.atan2(y, x) +

+
+

Return atan(y / x), in radians. The result is between -pi and pi. The vector in the plane from the origin to point (x, y) makes this angle with the positive X axis. The point of atan2() is that the signs of both inputs are known to it, so it can compute the correct quadrant for the angle. For example, atan(1) and atan2(1, 1) are both pi/4, but atan2(-1, -1) is -3*pi/4.

+ +

+ # + math.cos(x) +

+
+

Return the cosine of x radians.

+ +

+ # + math.sin(x) +

+
+

Return the sine of x radians.

+ +

+ # + math.tan(x) +

+
+

Return the tangent of x radians.

+ +

+ # + math.degrees(x) +

+
+

Convert angle x from radians to degrees.

+ +

+ # + math.radians(x) +

+
+

Convert angle x from degrees to radians.

+ +

+ # + math.modf(x) +

+
+

Return the fractional and integer parts of x. Both results carry the sign of x and are floats.

+ +

+ # + math.copysign(x, y) +

+
+

Return a float with the magnitude (absolute value) of x but the sign of y.

+ +

+ # + math.factorial(x) +

+
+

Return x factorial as an integer.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/operator/index.html b/modules/operator/index.html new file mode 100644 index 00000000..7a442f24 --- /dev/null +++ b/modules/operator/index.html @@ -0,0 +1,578 @@ + + + + + + + + + + + + operator | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + operator +

+
+

The operator module exports a set of efficient functions corresponding to the intrinsic operators of Python. For example, operator.add(x, y) is equivalent to the expression x+y. Many function names are those used for special methods, without the double underscores.

+ +

+ # + Mapping Operators to Functions +

+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
OperationSyntaxFunction
Orderinga <= ble(a, b)
Orderinga < blt(a, b)
Orderinga >= bge(a, b)
Orderinga > bgt(a, b)
Equalitya == beq(a, b)
Equalitya != bne(a, b)
Bitwise ANDa & band_(a, b)
Bitwise ORa | bor_(a, b)
Bitwise XORa ^ bxor(a, b)
Bitwise Inversion~ainvert(a)
Left Shifta << blshift(a, b)
Right Shifta >> brshift(a, b)
Identitya is bis_(a, b)
Identitya is not bis_not(a, b)
Negation (Logical)not anot_(a)
Negation (Arithmetic)-aneg(a)
Truth Testbool(a)truth(a)
Containment Testb in acontains(a, b)
Additiona + badd(a, b)
Subtractiona - bsub(a, b)
Multiplicationa * bmul(a, b)
Divisiona / btruediv(a, b)
Divisiona // bfloordiv(a, b)
Moduloa % bmod(a, b)
Exponentiationa ** bpow(a, b)
Matrix Multiplicationa @ bmatmul(a, b)
Indexinga[b]getitem(a, b)
Index Assignmenta[b] = csetitem(a, b, c)
Index Deletiondel a[b]delitem(a, b)
+
+ +

+ # + In-place Operators +

+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
OperationSyntaxFunction
Additiona += biadd(a, b)
Subtractiona -= bisub(a, b)
Multiplicationa *= bimul(a, b)
Divisiona /= bitruediv(a, b)
Divisiona //= bifloordiv(a, b)
Moduloa %= bimod(a, b)
Bitwise ANDa &= biand(a, b)
Bitwise ORa |= bior(a, b)
Bitwise XORa ^= bixor(a, b)
Left Shifta <<= bilshift(a, b)
Right Shifta >>= birshift(a, b)
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/pickle/index.html b/modules/pickle/index.html new file mode 100644 index 00000000..61f2b647 --- /dev/null +++ b/modules/pickle/index.html @@ -0,0 +1,376 @@ + + + + + + + + + + + + pickle | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + pickle +

+
+ +

+ # + pickle.dumps(obj) -> bytes +

+
+

Return the pickled representation of an object as a bytes object.

+ +

+ # + pickle.loads(b: bytes) +

+
+

Return the unpickled object from a bytes object.

+ +

+ # + What can be pickled and unpickled? +

+
+

The following types can be pickled:

+
    +
  • None, True, and False;
  • +
  • integers, floating-point numbers;
  • +
  • strings, bytes;
  • +
  • tuples, lists, sets, and dictionaries containing only picklable objects;
  • +
  • functions (user-defined) accessible from the top level of a module (using def, not lambda);
  • +
  • classes accessible from the top level of a module;
  • +
  • instances of such classes
  • +
+

The following magic methods are available:

+
    +
  • __getnewargs__
  • +
  • __getstate__
  • +
  • __setstate__
  • +
  • __reduce__
  • +
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/pkpy/index.html b/modules/pkpy/index.html new file mode 100644 index 00000000..3ccec5a5 --- /dev/null +++ b/modules/pkpy/index.html @@ -0,0 +1,420 @@ + + + + + + + + + + + + pkpy | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + pkpy +

+
+

Provide internal access to the pocketpy interpreter.

+ +

+ # + Source code +

+
+
+
from typing import Self, Literal
+from vmath import vec2, vec2i
+
+class TValue[T]:
+    def __new__(cls, value: T) -> Self: ...
+
+    @property
+    def value(self) -> T: ...
+
+# TValue_int = TValue[int]
+# TValue_float = TValue[float]
+# TValue_vec2i = TValue[vec2i]
+# TValue_vec2 = TValue[vec2]
+
+configmacros: dict[str, int]
+
+def memory_usage() -> str:
+    """Return a summary of the memory usage."""
+
+def is_user_defined_type(t: type) -> bool:
+    """Check if a type is user-defined. This means the type was created by executing python `class` statement."""
+
+def enable_full_buffering_mode() -> None:
+    """Enable full buffering mode for ASCII drawings."""
+
+def currentvm() -> int:
+    """Return the current VM index."""
+
+
+def watchdog_begin(timeout: int):
+    """Begin the watchdog with `timeout` in milliseconds.
+
+    `PK_ENABLE_WATCHDOG` must be defined to `1` to use this feature.
+    You need to call `watchdog_end()` later.
+    If `timeout` is reached, `TimeoutError` will be raised.
+    """
+def watchdog_end() -> None:
+    """End the watchdog after a call to `watchdog_begin()`."""
+
+def profiler_begin() -> None: ...
+def profiler_end() -> None: ...
+def profiler_reset() -> None: ...
+def profiler_report() -> dict[str, list[list]]: ...
+
+class ComputeThread:
+    def __init__(self, vm_index: Literal[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15]): ...
+
+    @property
+    def is_done(self) -> bool:
+        """Check if the current job is done."""
+
+    def wait_for_done(self) -> None:
+        """Wait for the current job to finish."""
+
+    def last_error(self) -> str | None: ...
+    def last_retval(self): ...
+
+    def submit_exec(self, source: str) -> None:
+        """Submit a job to execute some source code."""
+
+    def submit_eval(self, source: str) -> None:
+        """Submit a job to evaluate some source code."""
+
+    def submit_call(self, eval_src: str, *args, **kwargs) -> None:
+        """Submit a job to call a function with arguments."""
+
+    def exec(self, source: str) -> None:
+        """Directly execute some source code."""
+
+    def eval(self, source: str):
+        """Directly evaluate some source code."""
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/random/index.html b/modules/random/index.html new file mode 100644 index 00000000..1a1a0ad8 --- /dev/null +++ b/modules/random/index.html @@ -0,0 +1,388 @@ + + + + + + + + + + + + random | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + random +

+
+ +

+ # + random.seed(a) +

+
+

Set the random seed.

+ +

+ # + random.random() +

+
+

Return a random float number in the range [0.0, 1.0).

+ +

+ # + random.randint(a, b) +

+
+

Return a random integer in the range [a, b].

+ +

+ # + random.uniform(a, b) +

+
+

Return a random float number in the range [a, b).

+ +

+ # + random.choice(seq) +

+
+

Return a random element from a sequence.

+ +

+ # + random.shuffle(seq) +

+
+

Shuffle a sequence inplace.

+ +

+ # + random.choices(population, weights=None, k=1) +

+
+

Return a k sized list of elements chosen from the population with replacement.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/sys/index.html b/modules/sys/index.html new file mode 100644 index 00000000..94a265b1 --- /dev/null +++ b/modules/sys/index.html @@ -0,0 +1,382 @@ + + + + + + + + + + + + sys | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + sys +

+
+ +

+ # + sys.version +

+
+

The version of pkpy.

+ +

+ # + sys.platform +

+
+

May be one of:

+
    +
  • win32
  • +
  • linux
  • +
  • darwin
  • +
  • android
  • +
  • ios
  • +
  • emscripten
  • +
+ +

+ # + sys.argv +

+
+

The command line arguments. Set by py_sys_setargv.

+ +

+ # + sys.setrecursionlimit(limit: int) +

+
+

Set the maximum depth of the Python interpreter stack to limit. This limit prevents infinite recursion from causing an overflow of the C stack and crashing the interpreter.

+ +

+ # + sys.getrecursionlimit() -> int +

+
+

Return the current value of the recursion limit.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/time/index.html b/modules/time/index.html new file mode 100644 index 00000000..bd33b972 --- /dev/null +++ b/modules/time/index.html @@ -0,0 +1,360 @@ + + + + + + + + + + + + time | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + time +

+
+ +

+ # + time.time() +

+
+

Returns the current time in seconds since the epoch as a floating point number.

+ +

+ # + time.sleep(secs) +

+
+

Suspend execution of the calling thread for the given number of seconds.

+ +

+ # + time.localtime() +

+
+

Returns the current struct time as a struct_time object.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/traceback/index.html b/modules/traceback/index.html new file mode 100644 index 00000000..575608d0 --- /dev/null +++ b/modules/traceback/index.html @@ -0,0 +1,353 @@ + + + + + + + + + + + + traceback | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + traceback +

+
+ +

+ # + traceback.print_exc() -> None +

+
+

Print the last exception and its traceback.

+ +

+ # + traceback.format_exc() -> str +

+
+

Return the last exception and its traceback as a string.

+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/typing/index.html b/modules/typing/index.html new file mode 100644 index 00000000..c5419e7a --- /dev/null +++ b/modules/typing/index.html @@ -0,0 +1,406 @@ + + + + + + + + + + + + typing | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + typing +

+
+

Placeholder module for type hints.

+ +

+ # + Source code +

+
+
+
class _Placeholder:
+    def __init__(self, *args, **kwargs):
+        pass
+    def __getitem__(self, *args):
+        return self
+    def __call__(self, *args, **kwargs):
+        return self
+    def __and__(self, other):
+        return self
+    def __or__(self, other):
+        return self
+    def __xor__(self, other):
+        return self
+
+
+_PLACEHOLDER = _Placeholder()
+
+Sequence = _PLACEHOLDER
+List = _PLACEHOLDER
+Dict = _PLACEHOLDER
+Tuple = _PLACEHOLDER
+Set = _PLACEHOLDER
+Any = _PLACEHOLDER
+Union = _PLACEHOLDER
+Optional = _PLACEHOLDER
+Callable = _PLACEHOLDER
+Type = _PLACEHOLDER
+TypeAlias = _PLACEHOLDER
+NewType = _PLACEHOLDER
+
+Literal = _PLACEHOLDER
+LiteralString = _PLACEHOLDER
+
+Iterable = _PLACEHOLDER
+Generator = _PLACEHOLDER
+Iterator = _PLACEHOLDER
+
+Hashable = _PLACEHOLDER
+
+TypeVar = _PLACEHOLDER
+Self = _PLACEHOLDER
+
+Protocol = object
+Generic = object
+Never = object
+
+TYPE_CHECKING = False
+
+# decorators
+overload = lambda x: x
+final = lambda x: x
+
+# exhaustiveness checking
+assert_never = lambda x: x
+
+TypedDict = dict
+NotRequired = _PLACEHOLDER
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/unicodedata/index.html b/modules/unicodedata/index.html new file mode 100644 index 00000000..f89c6335 --- /dev/null +++ b/modules/unicodedata/index.html @@ -0,0 +1,354 @@ + + + + + + + + + + + + unicodedata | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + unicodedata +

+
+ +

+ # + unicodedata.east_asian_width(char: str) -> str +

+
+

Returns the East Asian width of a Unicode character. The width is one of the following values:

+
    +
  • F: Fullwidth
  • +
  • H: Halfwidth
  • +
  • N: Neutral
  • +
  • Na: Narrow
  • +
  • W: Wide
  • +
  • A: Ambiguous
  • +
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/modules/vmath/index.html b/modules/vmath/index.html new file mode 100644 index 00000000..2df4c4b6 --- /dev/null +++ b/modules/vmath/index.html @@ -0,0 +1,573 @@ + + + + + + + + + + + + vmath | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + vmath +

+
+

Provide vector math operations.

+ +

+ # + Source code +

+
+
+
from typing import overload, Iterator
+
+class _vecF[T]:
+    ONE: T
+    ZERO: T
+
+    def __add__(self, other: T) -> T: ...
+    def __sub__(self, other: T) -> T: ...
+    @overload
+    def __mul__(self, other: float) -> T: ...
+    @overload
+    def __mul__(self, other: T) -> T: ...
+    def __truediv__(self, other: float) -> T: ...
+
+    def dot(self, other: T) -> float: ...
+    def length(self) -> float: ...
+    def length_squared(self) -> float: ...
+    def normalize(self) -> T: ...
+
+    # dummy iter for unpacking
+    def __iter__(self) -> Iterator[float]: ...
+
+class _vecI[T]:
+    ONE: T
+    ZERO: T
+
+    def __add__(self, other: T) -> T: ...
+    def __sub__(self, other: T) -> T: ...
+    @overload
+    def __mul__(self, other: int) -> T: ...
+    @overload
+    def __mul__(self, other: T) -> T: ...
+    def __floordiv__(self, other: int) -> T: ...
+
+    def __hash__(self) -> int: ...
+
+    def dot(self, other: T) -> int: ...
+
+    # dummy iter for unpacking
+    def __iter__(self) -> Iterator[int]: ...
+
+
+class vec2(_vecF['vec2']):
+    LEFT: vec2
+    RIGHT: vec2
+    UP: vec2
+    DOWN: vec2
+
+    @property
+    def x(self) -> float: ...
+    @property
+    def y(self) -> float: ...
+
+    def with_x(self, x: float) -> vec2: ...
+    def with_y(self, y: float) -> vec2: ...
+    def with_z(self, z: float) -> vec3: ...
+
+    @overload
+    def __init__(self, x: float, y: float) -> None: ...
+    @overload
+    def __init__(self, xy: vec2i) -> None: ...
+
+    def rotate(self, radians: float) -> vec2:
+        """Rotate the vector by `radians`.
+
+        + If y axis is top to bottom, positive value means clockwise (default)
+        + If y axis is bottom to top, positive value means counter-clockwise
+        """
+
+    @staticmethod
+    def angle(__from: vec2, __to: vec2) -> float:
+        """Return the angle in radians between vectors `from` and `to`.
+
+        The result range is `[-pi, pi]`.
+
+        + If y axis is top to bottom, positive value means clockwise (default)
+        + If y axis is bottom to top, positive value means counter-clockwise
+        """
+
+    @staticmethod
+    def smooth_damp(current: vec2, target: vec2, current_velocity: vec2, smooth_time: float, max_speed: float, delta_time: float) -> tuple[vec2, vec2]:
+        """Smoothly change a vector towards a desired goal over time.
+
+        Returns a new value that is closer to the target and current velocity.
+        """
+
+
+class mat3x3:
+    def __init__(self, _11, _12, _13, _21, _22, _23, _31, _32, _33) -> None: ...
+
+    def __getitem__(self, index: tuple[int, int]) -> float: ...
+    def __setitem__(self, index: tuple[int, int], value: float) -> None: ...
+
+    @overload
+    def __matmul__(self, other: mat3x3) -> mat3x3: ...
+    @overload
+    def __matmul__(self, other: vec3) -> vec3: ...
+
+    def __invert__(self) -> mat3x3: ...
+
+    def matmul(self, other: mat3x3, out: mat3x3) -> mat3x3 | None: ...
+    def determinant(self) -> float: ...
+
+    def copy(self) -> mat3x3: ...
+    def inverse(self) -> mat3x3: ...
+
+    def copy_(self, other: mat3x3) -> None: ...
+    def inverse_(self) -> None: ...
+
+    @staticmethod
+    def zeros() -> mat3x3: ...
+    @staticmethod
+    def identity() -> mat3x3: ...
+
+    # affine transformations
+    @staticmethod
+    def trs(t: vec2, r: float, s: vec2) -> mat3x3: ...
+
+    def copy_trs_(self, t: vec2, r: float, s: vec2) -> None: ...
+
+    def t(self) -> vec2: ...
+    def r(self) -> float: ...
+    def s(self) -> vec2: ...
+
+    def transform_point(self, p: vec2) -> vec2: ...
+    def transform_vector(self, v: vec2) -> vec2: ...
+
+
+class vec2i(_vecI['vec2i']):
+    LEFT: vec2i
+    RIGHT: vec2i
+    UP: vec2i
+    DOWN: vec2i
+
+    @property
+    def x(self) -> int: ...
+    @property
+    def y(self) -> int: ...
+
+    def with_x(self, x: int) -> vec2i: ...
+    def with_y(self, y: int) -> vec2i: ...
+
+    def __init__(self, x: int, y: int) -> None: ...
+
+
+class vec3i(_vecI['vec3i']):
+    @property
+    def x(self) -> int: ...
+    @property
+    def y(self) -> int: ...
+    @property
+    def z(self) -> int: ...
+
+    def with_x(self, x: int) -> vec3i: ...
+    def with_y(self, y: int) -> vec3i: ...
+    def with_z(self, z: int) -> vec3i: ...
+
+    def __init__(self, x: int, y: int, z: int) -> None: ...
+
+
+class vec3(_vecF['vec3']):
+    @property
+    def x(self) -> float: ...
+    @property
+    def y(self) -> float: ...
+    @property
+    def z(self) -> float: ...
+
+    @property
+    def xy(self) -> vec2: ...
+
+    def with_x(self, x: float) -> vec3: ...
+    def with_y(self, y: float) -> vec3: ...
+    def with_z(self, z: float) -> vec3: ...
+    def with_xy(self, xy: vec2) -> vec3: ...
+
+    @overload
+    def __init__(self, x: float, y: float, z: float) -> None: ...
+    @overload
+    def __init__(self, xyz: vec3i) -> None: ...
+
+
+# Color32
+class color32:
+    def __new__(cls, r: int, g: int, b: int, a: int) -> 'color32': ...
+    def __eq__(self, other: object) -> bool: ...
+    def __ne__(self, other: object) -> bool: ...
+    def __repr__(self) -> str: ...
+    def __hash__(self) -> int: ...
+
+    @property
+    def r(self) -> int: ...
+    @property
+    def g(self) -> int: ...
+    @property
+    def b(self) -> int: ...
+    @property
+    def a(self) -> int: ...
+
+    def with_r(self, r: int) -> 'color32': ...
+    def with_g(self, g: int) -> 'color32': ...
+    def with_b(self, b: int) -> 'color32': ...
+    def with_a(self, a: int) -> 'color32': ...
+
+    @staticmethod
+    def from_hex(hex: str) -> 'color32': ...
+    @staticmethod
+    def from_vec3(vec: vec3) -> 'color32': ...
+    @staticmethod
+    def from_vec3i(vec: vec3i) -> 'color32': ...
+
+    def to_hex(self) -> str: ...
+    def to_vec3(self) -> vec3: ...
+    def to_vec3i(self) -> vec3i: ...
+
+    def ansi_fg(self, text: str) -> str: ...
+    def ansi_bg(self, text: str) -> str: ...
+
+    @staticmethod
+    def alpha_blend(src: color32, dst: color32 | None) -> color32: ...
+
+
+def rgb(r: int, g: int, b: int) -> color32: ...
+def rgba(r: int, g: int, b: int, a: float) -> color32: ...
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/performance/index.html b/performance/index.html new file mode 100644 index 00000000..3980c378 --- /dev/null +++ b/performance/index.html @@ -0,0 +1,533 @@ + + + + + + + + + + + + Performance | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Performance +

+
+

Currently, pkpy is as fast as cpython 3.9. +Performance results for cpython 3.9 are applicable to for pkpy.

+

Here is a benchmark result of v1.2.6. +Files are located in benchmarks/.

+ +

+ # + win32 64-bit cpy39 +

+
+
+
CPython: 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:36:42) [MSC v.1929 64 bit (AMD64)]
+System: 64-bit
+Testing directory: benchmarks/
+> benchmarks/fib.py
+  cpython:  0.986091s (100%)
+  pocketpy: 0.985427s (99.93%)
+> benchmarks/loop_0.py
+  cpython:  0.515685s (100%)
+  pocketpy: 0.344132s (66.73%)
+> benchmarks/loop_1.py
+  cpython:  0.938407s (100%)
+  pocketpy: 0.595634s (63.47%)
+> benchmarks/loop_2.py
+  cpython:  1.188671s (100%)
+  pocketpy: 0.735259s (61.86%)
+> benchmarks/loop_3.py
+  cpython:  4.957218s (100%)
+  pocketpy: 2.314210s (46.68%)
+> benchmarks/primes.py
+  cpython:  9.146332s (100%)
+  pocketpy: 8.507227s (93.01%)
+> benchmarks/recursive.py
+  cpython:  0.044789s (100%)
+  pocketpy: 0.031252s (69.78%)
+> benchmarks/simple.py
+  cpython:  0.516624s (100%)
+  pocketpy: 0.453159s (87.72%)
+> benchmarks/sort.py
+  cpython:  0.929597s (100%)
+  pocketpy: 0.406802s (43.76%)
+> benchmarks/sum.py
+  cpython:  0.047151s (100%)
+  pocketpy: 0.031266s (66.31%)
+ALL TESTS PASSED
+
+ +

+ # + linux 64-bit cpy38 +

+
+
+
CPython: 3.8.10 (default, May 26 2023, 14:05:08) [GCC 9.4.0]
+System: 64-bit
+Testing directory: benchmarks/
+> benchmarks/fib.py
+  cpython:  0.739547s (100%)
+  pocketpy: 0.613591s (82.97%)
+> benchmarks/loop_0.py
+  cpython:  0.356003s (100%)
+  pocketpy: 0.224396s (63.03%)
+> benchmarks/loop_1.py
+  cpython:  0.661924s (100%)
+  pocketpy: 0.446577s (67.47%)
+> benchmarks/loop_2.py
+  cpython:  0.937243s (100%)
+  pocketpy: 0.514324s (54.88%)
+> benchmarks/loop_3.py
+  cpython:  3.671752s (100%)
+  pocketpy: 1.876151s (51.10%)
+> benchmarks/primes.py
+  cpython:  7.293947s (100%)
+  pocketpy: 5.427518s (74.41%)
+> benchmarks/recursive.py
+  cpython:  0.021559s (100%)
+  pocketpy: 0.010227s (47.44%)
+> benchmarks/simple.py
+  cpython:  0.408654s (100%)
+  pocketpy: 0.265084s (64.87%)
+> benchmarks/sort.py
+  cpython:  0.372539s (100%)
+  pocketpy: 0.243566s (65.38%)
+> benchmarks/sum.py
+  cpython:  0.021242s (100%)
+  pocketpy: 0.010113s (47.61%)
+ALL TESTS PASSED
+
+ +

+ # + linux 32-bit cpy39 +

+
+
+
CPython: 3.9.18 (main, Aug 26 2023, 11:50:23) [GCC 10.3.1 20211027]
+System: 32-bit
+Testing directory: benchmarks/
+> benchmarks/fib.py
+  cpython:  1.967908s (100%)
+  pocketpy: 0.960947s (48.83%)
+> benchmarks/loop_0.py
+  cpython:  1.063461s (100%)
+  pocketpy: 0.396626s (37.30%)
+> benchmarks/loop_1.py
+  cpython:  1.563821s (100%)
+  pocketpy: 0.639663s (40.90%)
+> benchmarks/loop_2.py
+  cpython:  2.626848s (100%)
+  pocketpy: 0.757444s (28.83%)
+> benchmarks/loop_3.py
+  cpython:  13.428345s (100%)
+  pocketpy: 2.852351s (21.24%)
+> benchmarks/primes.py
+  cpython:  18.174904s (100%)
+  pocketpy: 8.423515s (46.35%)
+> benchmarks/recursive.py
+  cpython:  0.025673s (100%)
+  pocketpy: 0.012470s (48.57%)
+> benchmarks/simple.py
+  cpython:  1.042090s (100%)
+  pocketpy: 0.480013s (46.06%)
+> benchmarks/sort.py
+  cpython:  0.989279s (100%)
+  pocketpy: 0.379171s (38.33%)
+> benchmarks/sum.py
+  cpython:  0.024227s (100%)
+  pocketpy: 0.012477s (51.50%)
+ALL TESTS PASSED
+
+

See actions/runs.

+ +

+ # + Primes benchmarks +

+
+

These are the results of the primes benchmark on Intel i5-12400F, WSL (Ubuntu 20.04 LTS).

+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
nameversiontimefile
c++gnu++110.104s ■□□□□□□□□□□□□□□□benchmarks/primes.cpp
lua5.3.31.576s ■■■■■■■■■□□□□□□□benchmarks/primes.lua
pkpy1.2.72.385s ■■■■■■■■■■■■■□□□benchmarks/primes.py
cpython3.8.102.871s ■■■■■■■■■■■■■■■■benchmarks/primes.py
+
+
+
$ time lua benchmarks/primes.lua 
+
+real    0m1.576s
+user    0m1.514s
+sys     0m0.060s
+$ time ./main benchmarks/primes.py 
+
+real    0m2.385s
+user    0m2.247s
+sys     0m0.100s
+$ time python benchmarks/primes.py 
+
+real    0m2.871s
+user    0m2.798s
+sys     0m0.060s
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/quick-start/index.html b/quick-start/index.html new file mode 100644 index 00000000..f493e916 --- /dev/null +++ b/quick-start/index.html @@ -0,0 +1,468 @@ + + + + + + + + + + + + Quick Start | Portable Python 3.x Interpreter in Modern C + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+
+ + +
+ + +
+ + + +
+ +
+ + + + +
+ + + + + +
+ +
+ + +
+ + +
+ +
+
+ +
+
+ + + + +
+
+
+
+ + +
+ + + + + + + + +
+ +
+
+
+
+ +
+ + +

+ # + Quick Start +

+
+

You have two options to integrate pkpy into your project.

+ +

+ # + Use the single header file +

+
+

Download the pocketpy.h and pocketpy.c on our GitHub Release page. +And #include it in your project.

+ +

+ # + Use CMake +

+
+

Clone the whole repository as a submodule into your project, +In your CMakelists.txt, add the following lines:

+
+
add_subdirectory(pocketpy)
+target_link_libraries(<your_target> pocketpy)
+
+

See CMakeLists.txt for details.

+

It is safe to use main branch in production if CI badge is green.

+ +

+ # + Compile flags +

+
+

To compile it with your project, these flags must be set:

+
    +
  • --std=c11 flag must be set
  • +
  • For MSVC, /utf-8 and /experimental:c11atomics flag must be set
  • +
  • NDEBUG macro should be defined for release build, or you will get poor performance
  • +
+ +

+ # + Get prebuilt binaries +

+
+

We have prebuilt binaries, +check them out on our GitHub Actions.

+

You can download an artifact there which contains the following files.

+
+
├── android
+│   ├── arm64-v8a
+│   │   └── libpocketpy.so
+│   ├── armeabi-v7a
+│   │   └── libpocketpy.so
+│   └── x86_64
+│       └── libpocketpy.so
+├── ios
+│   └── libpocketpy.a
+├── linux
+│   └── x86_64
+│       ├── libpocketpy.so
+│       └── main
+└── windows
+    └── x86_64
+        ├── main.exe
+        └── pocketpy.dll
+
+ +

+ # + Example +

+
+
+
#include "pocketpy.h"
+#include <stdio.h>
+
+static bool int_add(int argc, py_Ref argv) {
+    PY_CHECK_ARGC(2);
+    PY_CHECK_ARG_TYPE(0, tp_int);
+    PY_CHECK_ARG_TYPE(1, tp_int);
+    py_i64 a = py_toint(py_arg(0));
+    py_i64 b = py_toint(py_arg(1));
+    py_newint(py_retval(), a + b);
+    return true;
+}
+
+int main() {
+    // Initialize pocketpy
+    py_initialize();
+
+    // Hello world!
+    bool ok = py_exec("print('Hello world!')", "<string>", EXEC_MODE, NULL);
+    if(!ok) goto __ERROR;
+
+    // Create a list: [1, 2, 3]
+    py_Ref r0 = py_getreg(0);
+    py_newlistn(r0, 3);
+    py_newint(py_list_getitem(r0, 0), 1);
+    py_newint(py_list_getitem(r0, 1), 2);
+    py_newint(py_list_getitem(r0, 2), 3);
+
+    // Eval the sum of the list
+    py_Ref f_sum = py_getbuiltin(py_name("sum"));
+    py_push(f_sum);
+    py_pushnil();
+    py_push(r0);
+    ok = py_vectorcall(1, 0);
+    if(!ok) goto __ERROR;
+
+    printf("Sum of the list: %d\n", (int)py_toint(py_retval()));  // 6
+
+    // Bind native `int_add` as a global variable
+    py_newnativefunc(r0, int_add);
+    py_setglobal(py_name("add"), r0);
+
+    // Call `add` in python
+    ok = py_exec("add(3, 7)", "<string>", EVAL_MODE, NULL);
+    if(!ok) goto __ERROR;
+
+    py_i64 res = py_toint(py_retval());
+    printf("Sum of 2 variables: %d\n", (int)res);  // 10
+
+    py_finalize();
+    return 0;
+
+__ERROR:
+    py_printexc();
+    py_finalize();
+    return 1;
+}
+
+ + + + +
+ +
+ + +
+ + + + + + + +
+ +
+
+ + + +
+ + +
+ + + + diff --git a/resources/css/retype.css b/resources/css/retype.css new file mode 100644 index 00000000..75f83699 --- /dev/null +++ b/resources/css/retype.css @@ -0,0 +1,5 @@ +/*! Retype v3.11.0 | retype.com | Copyright 2025. Retype, Inc. All rights reserved. */ + +:root{--base-white:#fff;--base-black:#000;--base-text-muted:var(--gray-400);--base-text:var(--gray-700);--base-text-strong:var(--gray-900);--base-bg:var(--base-white);--base-border:var(--gray-200);--base-border-hover:var(--gray-300);--base-border-strong:var(--gray-400);--base-link:#5694EF;--base-link-hover:#304F93;--base-link-weight:400;--base-item-text:var(--base-text-strong);--base-item-text-active:var(--base-link);--base-item-bg:var(--transparent);--base-item-bg-hover:#F4F5FD;--base-item-bg-active:#E6EDFB;--transparent:transparent;--skeleton-bg:var(--gray-200);--branding-label-text:#5694EF;--branding-label-bg:#F4F5FD;--branding-label-border:#A9C0F8;--header-bg:var(--base-bg);--header-border:var(--base-border);--header-text:var(--base-link);--header-text-weight:var(--base-link-weight);--header-text-hover:var(--base-link-hover);--search-text:var(--base-text);--search-placeholder:var(--base-text-muted);--search-bg:var(--header-bg);--search-border:var(--base-border);--search-border-hover:var(--base-border-hover);--search-border-focus:var(--base-border-hover);--search-hint-text:var(--search-placeholder);--search-hint-bg:var(--header-bg);--search-hint-border:var(--search-border);--filter-text:var(--base-text);--filter-placeholder:var(--base-text-muted);--filter-bg:var(--sidebar-left-bg);--filter-border:var(--base-border);--filter-border-hover:var(--base-border-hover);--filter-border-focus:var(--base-border-hover);--body-bg:var(--base-bg);--body-text:var(--base-text);--body-link:var(--base-link);--body-link-hover:var(--base-link-hover);--body-link-weight:var(--base-link-weight);--heading-text:var(--gray-900);--scheme-menu-item-bg:var(--base-item-bg);--scheme-menu-item-bg-hover:var(--base-item-bg-hover);--scheme-menu-item-bg-active:var(--base-item-bg-active);--scheme-menu-item-text:var(--base-text);--scheme-menu-item-text-active:var(--base-item-text-active);--sidebar-left-bg:var(--base-bg);--sidebar-left-border:var(--base-border);--nav-bg:var(--sidebar-left-bg);--nav-item-bg-hover:var(--base-item-bg-hover);--nav-item-bg-active:var(--base-item-bg-active);--nav-item-bg-active-hover:var(--base-item-bg-active);--nav-item-text:var(--gray-900);--nav-item-text-hover:var(--base-item-text-active);--nav-item-text-active:var(--base-item-text-active);--nav-item-text-active-hover:var(--base-item-text-active);--nav-item-text-active-weight:var(--base-link-weight);--nav-item-button:var(--gray-400);--nav-item-button-active-hover:#C8D7FD;--nav-item-border-active:#5694EF;--nav-item-text-stack:var(--gray-700);--nav-item-text-stack-case:uppercase;--nav-item-text-stack-weight:600;--nav-badge-margin-left:auto;--nav-badge-margin-left-alt:0.75rem;--sidebar-right-bg:var(--base-bg);--sidebar-right-border:var(--base-border);--toc-heading:var(--gray-700);--toc-text:var(--gray-700);--toc-text-hover:#5694EF;--toc-text-active:#5694EF;--toc-border-active:#5694EF;--toc-heading-case:uppercase;--toc-heading-weight:600;--footer-text:var(--gray-500);--footer-link:var(--base-link);--footer-link-hover:var(--base-link-hover);--footer-link-weight:var(--base-link-weight);--badge-base:#E6EDFB;--badge-base-hover:#E6EDFB;--badge-base-text:#5694EF;--badge-base-text-hover:#5694EF;--badge-base-border:#C8D7FD;--badge-base-border-hover:#86A7F5;--badge-primary:#E4EBFD;--badge-primary-hover:#E4EBFD;--badge-primary-text:#4482FB;--badge-primary-text-hover:#4482FB;--badge-primary-border:#C9D9FC;--badge-primary-border-hover:#82A9F8;--badge-secondary:var(--gray-100);--badge-secondary-hover:var(--gray-100);--badge-secondary-text:var(--gray-600);--badge-secondary-text-hover:var(--gray-600);--badge-secondary-border:var(--gray-200);--badge-secondary-border-hover:var(--gray-400);--badge-success:#E2F4F0;--badge-success-hover:#E2F4F0;--badge-success-text:#49887A;--badge-success-text-hover:#49887A;--badge-success-border:#CCE3E2;--badge-success-border-hover:#87C6B6;--badge-danger:#F9E1E1;--badge-danger-hover:#F9E1E1;--badge-danger-text:#BF4640;--badge-danger-text-hover:#BF4640;--badge-danger-border:#EDC9C4;--badge-danger-border-hover:#E07D7B;--badge-warning:#FBF3E2;--badge-warning-hover:#FBF3E2;--badge-warning-text:#B68D38;--badge-warning-text-hover:#B68D38;--badge-warning-border:#F8E6C2;--badge-warning-border-hover:#E9C476;--badge-info:var(--transparent);--badge-info-hover:var(--transparent);--badge-info-text:#5694EF;--badge-info-text-hover:#A9C0F8;--badge-info-border:#5694EF;--badge-info-border-hover:#A9C0F8;--badge-light:var(--base-white);--badge-light-hover:var(--gray-100);--badge-light-text:var(--gray-600);--badge-light-text-hover:var(--gray-600);--badge-light-border:var(--gray-200);--badge-light-border-hover:var(--gray-400);--badge-dark:var(--gray-700);--badge-dark-hover:var(--gray-600);--badge-dark-text:var(--base-white);--badge-dark-text-hover:var(--base-white);--badge-dark-border:var(--gray-700);--badge-dark-border-hover:var(--gray-500);--badge-ghost:var(--body-bg);--badge-ghost-hover:var(--gray-50);--badge-ghost-text:var(--gray-300);--badge-ghost-text-hover:var(--gray-300);--badge-ghost-border:var(--gray-200);--badge-ghost-border-hover:var(--gray-300);--badge-contrast:var(--gray-900);--badge-contrast-hover:var(--gray-600);--badge-contrast-text:var(--base-white);--badge-contrast-text-hover:var(--base-white);--badge-contrast-border:var(--gray-900);--badge-contrast-border-hover:var(--gray-800);--button-base:#5694EF;--button-base-hover:#4469C0;--button-base-text:#F4F5FD;--button-primary:#4482FB;--button-primary-hover:#436AC0;--button-primary-text:#F5F8FC;--button-secondary:var(--gray-500);--button-secondary-hover:var(--gray-700);--button-secondary-text:var(--gray-50);--button-success:#5CA99A;--button-success-hover:#49887A;--button-success-text:#EEF5F4;--button-danger:#D14E44;--button-danger-hover:#A83C36;--button-danger-text:#FAECEC;--button-warning:#E4B045;--button-warning-hover:#CE9E3E;--button-warning-text:#5B4319;--button-info:var(--transparent);--button-info-hover:var(--transparent);--button-info-text:#5694EF;--button-info-text-hover:#A9C0F8;--button-info-border:#5694EF;--button-info-border-hover:#A9C0F8;--button-light:var(--gray-200);--button-light-hover:var(--gray-300);--button-light-text:var(--gray-900);--button-dark:var(--gray-700);--button-dark-hover:var(--gray-600);--button-dark-text:var(--gray-50);--button-ghost:var(--gray-100);--button-ghost-hover:var(--gray-150);--button-ghost-text:var(--gray-300);--button-contrast:var(--gray-900);--button-contrast-hover:var(--gray-700);--button-contrast-text:var(--gray-50);--callout-base-bg:var(--base-white);--callout-base-border:var(--base-border);--callout-base:#5694EF;--callout-primary:#4482FB;--callout-secondary:var(--gray-500);--callout-success:#5CA99A;--callout-tip:#87C6B6;--callout-danger:#D14E44;--callout-warning:#E4B045;--callout-info:#A9C0F8;--callout-question:#9E6BDB;--callout-light:var(--gray-300);--callout-dark:var(--gray-900);--callout-ghost:var(--gray-100);--callout-contrast:var(--gray-600);--callout-contrast-bg:var(--gray-900);--callout-contrast-text:var(--gray-300);--callout-contrast-border:var(--gray-900);--image-rounded:0px;--image-border:var(--base-border);--image-border-width:0;--list-checked:#5694EF;--list-unchecked:var(--gray-300);--tab-text-active:#5694EF;--tab-border-active:#5694EF;--tab-text:var(--gray-500);--tab-text-hover:#5694EF;--tab-border:var(--transparent);--tab-border-hover:var(--gray-300);--mix-50:10%;--mix-100:15%;--mix-200:30%;--mix-300:50%;--mix-400:70%;--mix-600:90%;--mix-700:80%;--mix-800:60%;--mix-900:40%;--gray-50:#f8f9fc;--gray-100:#f4f6fc;--gray-150:#edf0f6;--gray-200:#e4e8f1;--gray-250:#d2d9e3;--gray-300:#bdc8da;--gray-350:#a4b1c6;--gray-400:#8693a9;--gray-450:#65718c;--gray-500:#525e78;--gray-550:#46536d;--gray-600:#3f4a64;--gray-650:#313c56;--gray-700:#2c3047;--gray-750:#1f2236;--gray-800:#181d2d;--gray-850:#101523;--gray-900:#090d1c;--dark-50:#fafafa;--dark-100:#f7f7f7;--dark-150:#f2f2f2;--dark-200:#eee;--dark-250:#e0e0e0;--dark-300:#c4c4c4;--dark-350:#9e9e9e;--dark-400:#616161;--dark-450:#424242;--dark-500:#353535;--dark-550:#323232;--dark-600:#2d2d2d;--dark-650:#2c2c2c;--dark-700:#272727;--dark-750:#252525;--dark-800:#222;--dark-850:#1e1e1e;--dark-900:#121212;}.dark{--base-text-muted:var(--gray-400);--base-text:var(--dark-300);--base-text-strong:var(--base-white);--base-bg:var(--dark-900);--base-border:var(--dark-650);--base-border-hover:var(--gray-550);--base-border-strong:var(--gray-450);--base-link-hover:#A9C0F8;--base-item-bg-hover:var(--dark-600);--base-item-bg-active:var(--dark-550);--skeleton-bg:var(--dark-600);--branding-label-text:#5694EF;--branding-label-border:#5694EF;--branding-label-bg:transparent;--heading-text:var(--base-white);--search-border:var(--base-border-hover);--search-border-hover:var(--base-border-strong);--search-border-focus:var(--base-border-strong);--filter-border:var(--base-border-hover);--filter-border-hover:var(--base-border-strong);--filter-border-focus:var(--base-border-strong);--nav-item-text:var(--dark-300);--nav-item-text-stack:var(--base-text-strong);--nav-item-button:var(--dark-400);--toc-heading:var(--dark-400);--toc-text:var(--dark-300);--footer-text:var(--dark-350);--badge-base-hover:#C8D7FD;--badge-primary-hover:#C9D9FC;--badge-secondary-hover:var(--gray-250);--badge-success-hover:#CCE3E2;--badge-danger-hover:#EDC9C4;--badge-warning-hover:#F8E6C2;--badge-light-hover:var(--dark-200);--badge-light-text:var(--dark-600);--badge-light-text-hover:var(--dark-600);--badge-light-border:var(--transparent);--badge-dark:var(--dark-450);--badge-dark-hover:var(--dark-400);--badge-dark-border:var(--dark-450);--badge-dark-border-hover:var(--dark-400);--badge-ghost:var(--dark-550);--badge-ghost-hover:var(--dark-450);--badge-ghost-text:var(--dark-400);--badge-ghost-text-hover:var(--dark-450);--badge-ghost-border:var(--dark-450);--badge-ghost-border-hover:var(--dark-450);--badge-contrast:var(--base-white);--badge-contrast-hover:var(--dark-200);--badge-contrast-text:var(--dark-850);--badge-contrast-text-hover:var(--dark-850);--badge-contrast-border:var(--base-white);--badge-contrast-border-hover:var(--base-white);--button-secondary-hover:var(--dark-450);--button-light:var(--dark-250);--button-light-hover:var(--dark-350);--button-light-text:var(--base-black);--button-dark:var(--dark-550);--button-dark-hover:var(--dark-450);--button-dark-text:var(--dark-350);--button-ghost:var(--dark-600);--button-ghost-hover:var(--dark-450);--button-ghost-text:var(--dark-400);--button-contrast:var(--base-white);--button-contrast-hover:var(--dark-300);--button-contrast-text:var(--base-black);--callout-base-bg:var(--dark-800);--callout-contrast-bg:var(--base-white);--callout-contrast-text:var(--dark-800);--callout-contrast-border:var(--dark-700);--list-unchecked:var(--dark-400);--tab-text-active:#5694EF;--tab-border-active:#5694EF;--tab-text:var(--dark-350);--tab-border-hover:var(--dark-450)}.nav-item-text-stack-case{text-transform:var(--nav-item-text-stack-case)}.toc-heading-case{text-transform:var(--toc-heading-case)} + +/* ! tailwindcss v3.3.7 | MIT License | https://tailwindcss.com */*,:after,:before{border-color:var(--gray-200);border-style:solid;border-width:0;box-sizing:border-box}:after,:before{--tw-content:""}html{-webkit-text-size-adjust:100%;font-feature-settings:normal;font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;font-variation-settings:normal;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4}body{line-height:inherit;margin:0}hr{border-top-width:1px;color:inherit;height:0}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,pre,samp{font-feature-settings:normal;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em;font-variation-settings:normal}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{border-collapse:collapse;border-color:inherit;text-indent:0}button,input,optgroup,select,textarea{font-feature-settings:inherit;color:inherit;font-family:inherit;font-size:100%;font-variation-settings:inherit;font-weight:inherit;line-height:inherit;margin:0;padding:0}button,select{text-transform:none}[type=button],[type=reset],[type=submit],button{-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dd,dl,figure,h1,h2,h3,h4,h5,h6,hr,p,pre{margin:0}fieldset{margin:0}fieldset,legend{padding:0}menu,ol,ul{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{color:var(--gray-400);opacity:1}input::placeholder,textarea::placeholder{color:var(--gray-400);opacity:1}[role=button],button{cursor:pointer}:disabled{cursor:default}audio,canvas,embed,iframe,img,object,svg,video{display:block;vertical-align:middle}img,video{height:auto;max-width:100%}[hidden]{display:none}*,:after,:before{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }::backdrop{--tw-border-spacing-x:0;--tw-border-spacing-y:0;--tw-translate-x:0;--tw-translate-y:0;--tw-rotate:0;--tw-skew-x:0;--tw-skew-y:0;--tw-scale-x:1;--tw-scale-y:1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness:proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width:0px;--tw-ring-offset-color:#fff;--tw-ring-color:rgba(59,130,246,.5);--tw-ring-offset-shadow:0 0 #0000;--tw-ring-shadow:0 0 #0000;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: }.content-left{display:table;float:left;margin-right:1.75rem}.content-center{display:grid;justify-items:center}.content-leftplus{display:table;float:left;margin-left:-1.5rem;margin-right:1.75rem}@media (min-width:1200px){.content-leftplus{margin-left:-8rem}}@media (min-width:1440px){.content-leftplus{margin-left:-12rem}}.content-right,.content-rightplus{display:table;float:right;margin-left:1.75rem}.content-rightplus{margin-right:-1.5rem}@media (min-width:1200px){.content-rightplus{margin-right:-8rem}}@media (min-width:1440px){.content-rightplus{margin-right:-12rem}}.content-centerplus{display:grid;justify-items:center;margin-left:-1.5rem;margin-right:-1.5rem}@media (min-width:1200px){.content-centerplus{margin-left:-8rem;margin-right:-8rem}}@media (min-width:1440px){.content-centerplus{margin-left:-12rem;margin-right:-12rem}}.caption-float{caption-side:bottom;display:table-caption}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.invisible{visibility:hidden}.collapse{visibility:collapse}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{inset:0}.bottom-0{bottom:0}.bottom-6{bottom:1.5rem}.left-0{left:0}.right-0{right:0}.right-25{right:6.25rem}.right-3{right:.75rem}.right-6{right:1.5rem}.top-0{top:0}.top-1\/2{top:50%}.top-16{top:4rem}.top-20{top:5rem}.top-4{top:1rem}.top-40{top:10rem}.top-5{top:1.25rem}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-5{z-index:5}.z-50{z-index:50}.float-left{float:left}.clear-both{clear:both}.m-0{margin:0}.m-3{margin:.75rem}.-mx-px{margin-left:-1px;margin-right:-1px}.mx-1{margin-left:.25rem;margin-right:.25rem}.mx-2{margin-left:.5rem;margin-right:.5rem}.mx-auto{margin-left:auto;margin-right:auto}.my-2{margin-bottom:.5rem;margin-top:.5rem}.my-2\.5{margin-bottom:.625rem;margin-top:.625rem}.-mb-0{margin-bottom:0}.-mb-0\.5{margin-bottom:-.125rem}.-mb-px{margin-bottom:-1px}.-ml-1{margin-left:-.25rem}.-ml-4{margin-left:-1rem}.-ml-6{margin-left:-1.5rem}.-mr-2{margin-right:-.5rem}.-mt-1{margin-top:-.25rem}.-mt-2{margin-top:-.5rem}.-mt-3{margin-top:-.75rem}.-mt-3\.5{margin-top:-.875rem}.-mt-5{margin-top:-1.25rem}.-mt-px{margin-top:-1px}.mb-0{margin-bottom:0}.mb-1{margin-bottom:.25rem}.mb-10{margin-bottom:2.5rem}.mb-12{margin-bottom:3rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-5{margin-bottom:1.25rem}.mb-6{margin-bottom:1.5rem}.mb-8{margin-bottom:2rem}.mb-px{margin-bottom:1px}.ml-0{margin-left:0}.ml-0\.5{margin-left:.125rem}.ml-1{margin-left:.25rem}.ml-2{margin-left:.5rem}.ml-3{margin-left:.75rem}.ml-3\.5{margin-left:.875rem}.ml-4{margin-left:1rem}.ml-5{margin-left:1.25rem}.ml-auto{margin-left:auto}.ml-nav-badge-margin-left{margin-left:var(--nav-badge-margin-left)}.ml-nav-badge-margin-left-alt{margin-left:var(--nav-badge-margin-left-alt)}.mr-0{margin-right:0}.mr-1{margin-right:.25rem}.mr-1\.5{margin-right:.375rem}.mr-2{margin-right:.5rem}.mr-3{margin-right:.75rem}.mr-4{margin-right:1rem}.mr-6{margin-right:1.5rem}.mr-8{margin-right:2rem}.mt-0{margin-top:0}.mt-0\.75{margin-top:.1875rem}.mt-1{margin-top:.25rem}.mt-1\.5{margin-top:.375rem}.mt-12{margin-top:3rem}.mt-14{margin-top:3.5rem}.mt-2{margin-top:.5rem}.mt-20{margin-top:5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-6{margin-top:1.5rem}.mt-auto{margin-top:auto}.mt-px{margin-top:1px}.line-clamp-1{-webkit-line-clamp:1}.line-clamp-1,.line-clamp-3{-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.line-clamp-3{-webkit-line-clamp:3}.block{display:block}.inline-block{display:inline-block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.contents{display:contents}.hidden{display:none}.aspect-video{aspect-ratio:16/9}.h-10{height:2.5rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-20{height:5rem}.h-3{height:.75rem}.h-4{height:1rem}.h-4\.5{height:1.125rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-7{height:1.75rem}.h-8{height:2rem}.h-full{height:100%}.h-screen{height:100vh}.max-h-10{max-height:2.5rem}.max-h-60{max-height:15rem}.max-h-\[32rem\]{max-height:32rem}.w-1{width:.25rem}.w-1\.5{width:.375rem}.w-1\/2{width:50%}.w-10{width:2.5rem}.w-12{width:3rem}.w-14{width:3.5rem}.w-2{width:.5rem}.w-24{width:6rem}.w-32{width:8rem}.w-4{width:1rem}.w-4\.5{width:1.125rem}.w-4\/5{width:80%}.w-40{width:10rem}.w-48{width:12rem}.w-5{width:1.25rem}.w-6{width:1.5rem}.w-7{width:1.75rem}.w-75{width:18.75rem}.w-8{width:2rem}.w-96{width:24rem}.w-\[42rem\]{width:42rem}.w-full{width:100%}.w-px{width:1px}.min-w-0{min-width:0}.max-w-core{max-width:49.75rem}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.grow{flex-grow:1}.grow-0{flex-grow:0}.origin-center{transform-origin:center}.-translate-y-1\/2{--tw-translate-y:-50%}.-translate-y-1\/2,.-translate-y-2{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-2{--tw-translate-y:-0.5rem}.translate-x-0{--tw-translate-x:0px}.translate-x-0,.translate-x-full{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-full{--tw-translate-x:100%}.translate-y-0{--tw-translate-y:0px}.translate-y-0,.translate-y-4{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-4{--tw-translate-y:1rem}.rotate-45{--tw-rotate:45deg}.rotate-45,.rotate-90{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-90{--tw-rotate:90deg}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes spin{to{transform:rotate(1turn)}}.animate-spin{animation:spin 1s linear infinite}.cursor-default{cursor:default}.cursor-pointer{cursor:pointer}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize{resize:both}.list-none{list-style-type:none}.grid-flow-col{grid-auto-flow:column}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.flex-nowrap{flex-wrap:nowrap}.content-center{align-content:center}.items-center{align-items:center}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.self-end{align-self:flex-end}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overflow-x-hidden{overflow-x:hidden}.overflow-x-clip{overflow-x:clip}.truncate{overflow:hidden;text-overflow:ellipsis}.truncate,.whitespace-nowrap{white-space:nowrap}.break-normal{overflow-wrap:normal;word-break:normal}.break-words{overflow-wrap:break-word}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-3xl{border-radius:1.5rem}.rounded-full{border-radius:9999px}.rounded-image-rounded{border-radius:var(--image-rounded)}.rounded-lg{border-radius:.5rem}.rounded-md{border-radius:.375rem}.rounded-none{border-radius:0}.rounded-sm{border-radius:.125rem}.rounded-xl{border-radius:.75rem}.rounded-b-md{border-bottom-left-radius:.375rem;border-bottom-right-radius:.375rem}.rounded-l{border-bottom-left-radius:.25rem;border-top-left-radius:.25rem}.rounded-l-lg{border-bottom-left-radius:.5rem;border-top-left-radius:.5rem}.rounded-r{border-bottom-right-radius:.25rem;border-top-right-radius:.25rem}.rounded-r-lg{border-bottom-right-radius:.5rem;border-top-right-radius:.5rem}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.rounded-bl{border-bottom-left-radius:.25rem}.rounded-bl-lg{border-bottom-left-radius:.5rem}.rounded-br{border-bottom-right-radius:.25rem}.rounded-br-full{border-bottom-right-radius:9999px}.rounded-br-lg{border-bottom-right-radius:.5rem}.rounded-tl{border-top-left-radius:.25rem}.rounded-tl-lg{border-top-left-radius:.5rem}.rounded-tr{border-top-right-radius:.25rem}.rounded-tr-lg{border-top-right-radius:.5rem}.border{border-width:1px}.border-0{border-width:0}.border-4{border-width:4px}.border-image-border-width{border-width:var(--image-border-width)}.border-b{border-bottom-width:1px}.border-b-2{border-bottom-width:2px}.border-l{border-left-width:1px}.border-l-0{border-left-width:0}.border-r{border-right-width:1px}.border-r-0{border-right-width:0}.border-t{border-top-width:1px}.border-t-0{border-top-width:0}.border-solid{border-style:solid}.border-badge-base-border{border-color:var(--badge-base-border)}.border-badge-contrast-border{border-color:var(--badge-contrast-border)}.border-badge-danger-border{border-color:var(--badge-danger-border)}.border-badge-dark-border{border-color:var(--badge-dark-border)}.border-badge-ghost-border{border-color:var(--badge-ghost-border)}.border-badge-info-border{border-color:var(--badge-info-border)}.border-badge-light-border{border-color:var(--badge-light-border)}.border-badge-primary-border{border-color:var(--badge-primary-border)}.border-badge-secondary-border{border-color:var(--badge-secondary-border)}.border-badge-success-border{border-color:var(--badge-success-border)}.border-badge-warning-border{border-color:var(--badge-warning-border)}.border-base-500{border-color:#5694EF}.border-base-border{border-color:var(--base-border)}.border-button-info-border{border-color:var(--button-info-border)}.border-callout-base-border{border-color:var(--callout-base-border)}.border-callout-contrast-border{border-color:var(--callout-contrast-border)}.border-filter-border{border-color:var(--filter-border)}.border-gray-200{border-color:var(--gray-200)}.border-gray-300{border-color:var(--gray-300)}.border-gray-400{border-color:var(--gray-400)}.border-gray-500{border-color:var(--gray-500)}.border-gray-600{border-color:var(--gray-600)}.border-header-border{border-color:var(--header-border)}.border-image-border{border-color:var(--image-border)}.border-search-border{border-color:var(--search-border)}.border-search-hint-border{border-color:var(--search-hint-border)}.border-sidebar-left-border{border-color:var(--sidebar-left-border)}.border-sidebar-right-border{border-color:var(--sidebar-right-border)}.border-tab-border{border-color:var(--tab-border)}.border-tab-border-active{border-color:var(--tab-border-active)}.border-tab-border-hover{border-color:var(--tab-border-hover)}.border-transparent{border-color:transparent}.border-white{--tw-border-opacity:1;border-color:rgb(255 255 255/var(--tw-border-opacity))}.border-opacity-50{--tw-border-opacity:0.5}.bg-badge-base{background-color:var(--badge-base)}.bg-badge-contrast{background-color:var(--badge-contrast)}.bg-badge-danger{background-color:var(--badge-danger)}.bg-badge-dark{background-color:var(--badge-dark)}.bg-badge-ghost{background-color:var(--badge-ghost)}.bg-badge-info{background-color:var(--badge-info)}.bg-badge-light{background-color:var(--badge-light)}.bg-badge-primary{background-color:var(--badge-primary)}.bg-badge-secondary{background-color:var(--badge-secondary)}.bg-badge-success{background-color:var(--badge-success)}.bg-badge-warning{background-color:var(--badge-warning)}.bg-base-500{background-color:#5694EF}.bg-base-bg{background-color:var(--base-bg)}.bg-base-item-bg{background-color:var(--base-item-bg)}.bg-base-item-bg-hover{background-color:var(--base-item-bg-hover)}.bg-base-link{background-color:var(--base-link)}.bg-body-bg{background-color:var(--body-bg)}.bg-branding-label-bg{background-color:var(--branding-label-bg)}.bg-button-base{background-color:var(--button-base)}.bg-button-contrast{background-color:var(--button-contrast)}.bg-button-danger{background-color:var(--button-danger)}.bg-button-dark{background-color:var(--button-dark)}.bg-button-ghost{background-color:var(--button-ghost)}.bg-button-info{background-color:var(--button-info)}.bg-button-light{background-color:var(--button-light)}.bg-button-primary{background-color:var(--button-primary)}.bg-button-secondary{background-color:var(--button-secondary)}.bg-button-success{background-color:var(--button-success)}.bg-button-warning{background-color:var(--button-warning)}.bg-callout-base{background-color:var(--callout-base)}.bg-callout-base-bg{background-color:var(--callout-base-bg)}.bg-callout-contrast{background-color:var(--callout-contrast)}.bg-callout-contrast-bg{background-color:var(--callout-contrast-bg)}.bg-callout-danger{background-color:var(--callout-danger)}.bg-callout-dark{background-color:var(--callout-dark)}.bg-callout-ghost{background-color:var(--callout-ghost)}.bg-callout-info{background-color:var(--callout-info)}.bg-callout-light{background-color:var(--callout-light)}.bg-callout-primary{background-color:var(--callout-primary)}.bg-callout-question{background-color:var(--callout-question)}.bg-callout-secondary{background-color:var(--callout-secondary)}.bg-callout-success{background-color:var(--callout-success)}.bg-callout-tip{background-color:var(--callout-tip)}.bg-callout-warning{background-color:var(--callout-warning)}.bg-danger-100{background-color:#F9E1E1}.bg-dark-450{background-color:var(--dark-450)}.bg-dark-500{background-color:var(--dark-500)}.bg-dark-550{background-color:var(--dark-550)}.bg-dark-850{background-color:var(--dark-850)}.bg-dark-900{background-color:var(--dark-900)}.bg-filter-bg{background-color:var(--filter-bg)}.bg-gray-100{background-color:var(--gray-100)}.bg-gray-200{background-color:var(--gray-200)}.bg-gray-300{background-color:var(--gray-300)}.bg-gray-400{background-color:var(--gray-400)}.bg-gray-600{background-color:var(--gray-600)}.bg-gray-700{background-color:var(--gray-700)}.bg-gray-900{background-color:var(--gray-900)}.bg-header-bg{background-color:var(--header-bg)}.bg-nav-item-bg-active{background-color:var(--nav-item-bg-active)}.bg-nav-item-bg-hover{background-color:var(--nav-item-bg-hover)}.bg-nav-item-border-active{background-color:var(--nav-item-border-active)}.bg-scheme-menu-item-bg{background-color:var(--scheme-menu-item-bg)}.bg-search-bg{background-color:var(--search-bg)}.bg-search-hint-bg{background-color:var(--search-hint-bg)}.bg-sidebar-left-bg{background-color:var(--sidebar-left-bg)}.bg-sidebar-right-bg{background-color:var(--sidebar-right-bg)}.bg-skeleton-bg{background-color:var(--skeleton-bg)}.bg-success-100{background-color:#E2F4F0}.bg-toc-border-active{background-color:var(--toc-border-active)}.bg-transparent{background-color:transparent}.bg-warning-100{background-color:#FBF3E2}.bg-white{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.bg-opacity-25{--tw-bg-opacity:0.25}.bg-opacity-50{--tw-bg-opacity:0.5}.bg-opacity-70{--tw-bg-opacity:0.7}.bg-opacity-80{--tw-bg-opacity:0.8}.bg-opacity-95{--tw-bg-opacity:0.95}.object-cover{-o-object-fit:cover;object-fit:cover}.p-0{padding:0}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.px-0{padding-left:0;padding-right:0}.px-1{padding-left:.25rem;padding-right:.25rem}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.py-0{padding-bottom:0;padding-top:0}.py-0\.5{padding-bottom:.125rem;padding-top:.125rem}.py-1{padding-bottom:.25rem;padding-top:.25rem}.py-1\.5{padding-bottom:.375rem;padding-top:.375rem}.py-2{padding-bottom:.5rem;padding-top:.5rem}.py-3{padding-bottom:.75rem;padding-top:.75rem}.py-4{padding-bottom:1rem;padding-top:1rem}.py-6{padding-bottom:1.5rem;padding-top:1.5rem}.pb-12{padding-bottom:3rem}.pb-16{padding-bottom:4rem}.pb-2{padding-bottom:.5rem}.pb-3{padding-bottom:.75rem}.pb-4{padding-bottom:1rem}.pb-5{padding-bottom:1.25rem}.pb-6{padding-bottom:1.5rem}.pb-9\/16{padding-bottom:56.25%}.pl-0{padding-left:0}.pl-1{padding-left:.25rem}.pl-3{padding-left:.75rem}.pl-4{padding-left:1rem}.pl-5{padding-left:1.25rem}.pl-6{padding-left:1.5rem}.pl-8{padding-left:2rem}.pr-14{padding-right:3.5rem}.pr-3{padding-right:.75rem}.pr-4{padding-right:1rem}.pr-5{padding-right:1.25rem}.pr-6{padding-right:1.5rem}.pt-1{padding-top:.25rem}.pt-2{padding-top:.5rem}.pt-3{padding-top:.75rem}.pt-3\/4{padding-top:75%}.pt-4{padding-top:1rem}.pt-6{padding-top:1.5rem}.pt-9\/16{padding-top:56.25%}.pt-9\/21{padding-top:42.857%}.pt-full{padding-top:100%}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.align-middle{vertical-align:middle}.font-body{font-family:Inter var,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-2xl{font-size:1.5rem}.text-2xs{font-size:.75rem}.text-3xs{font-size:.675rem}.text-base{font-size:1rem}.text-lg{font-size:1.125rem}.text-sm{font-size:.875rem}.text-xl{font-size:1.25rem}.text-xs{font-size:.8125rem}.font-body-link-weight{font-weight:var(--body-link-weight)}.font-bold{font-weight:700}.font-footer-link-weight{font-weight:var(--footer-link-weight)}.font-header-text-weight{font-weight:var(--header-text-weight)}.font-medium{font-weight:500}.font-nav-item-text-active-weight{font-weight:var(--nav-item-text-active-weight)}.font-nav-item-text-stack-weight{font-weight:var(--nav-item-text-stack-weight)}.font-normal{font-weight:400}.font-semibold{font-weight:600}.font-toc-heading-weight{font-weight:var(--toc-heading-weight)}.uppercase{text-transform:uppercase}.lowercase{text-transform:lowercase}.leading-10{line-height:2.5rem}.leading-8{line-height:2rem}.leading-none{line-height:1}.leading-normal{line-height:1.6}.leading-relaxed{line-height:1.75}.leading-snug{line-height:1.375}.leading-tight{line-height:1.25}.text-badge-base-text{color:var(--badge-base-text)}.text-badge-contrast-text{color:var(--badge-contrast-text)}.text-badge-danger-text{color:var(--badge-danger-text)}.text-badge-dark-text{color:var(--badge-dark-text)}.text-badge-ghost-text{color:var(--badge-ghost-text)}.text-badge-info-text{color:var(--badge-info-text)}.text-badge-light-text{color:var(--badge-light-text)}.text-badge-primary-text{color:var(--badge-primary-text)}.text-badge-secondary-text{color:var(--badge-secondary-text)}.text-badge-success-text{color:var(--badge-success-text)}.text-badge-warning-text{color:var(--badge-warning-text)}.text-base-500{color:#5694EF}.text-base-item-text{color:var(--base-item-text)}.text-base-item-text-active{color:var(--base-item-text-active)}.text-base-link{color:var(--base-link)}.text-base-text{color:var(--base-text)}.text-base-text-muted{color:var(--base-text-muted)}.text-body-link{color:var(--body-link)}.text-branding-label-text{color:var(--branding-label-text)}.text-button-base-text{color:var(--button-base-text)}.text-button-contrast-text{color:var(--button-contrast-text)}.text-button-danger-text{color:var(--button-danger-text)}.text-button-dark-text{color:var(--button-dark-text)}.text-button-ghost-text{color:var(--button-ghost-text)}.text-button-info-text{color:var(--button-info-text)}.text-button-light-text{color:var(--button-light-text)}.text-button-primary{color:var(--button-primary)}.text-button-primary-text{color:var(--button-primary-text)}.text-button-secondary-text{color:var(--button-secondary-text)}.text-button-success-text{color:var(--button-success-text)}.text-button-warning-text{color:var(--button-warning-text)}.text-callout-base{color:var(--callout-base)}.text-callout-contrast{color:var(--callout-contrast)}.text-callout-contrast-text{color:var(--callout-contrast-text)}.text-callout-danger{color:var(--callout-danger)}.text-callout-dark{color:var(--callout-dark)}.text-callout-ghost{color:var(--callout-ghost)}.text-callout-info{color:var(--callout-info)}.text-callout-light{color:var(--callout-light)}.text-callout-primary{color:var(--callout-primary)}.text-callout-question{color:var(--callout-question)}.text-callout-secondary{color:var(--callout-secondary)}.text-callout-success{color:var(--callout-success)}.text-callout-tip{color:var(--callout-tip)}.text-callout-warning{color:var(--callout-warning)}.text-danger-600{color:#BF4640}.text-danger-700{color:#A83C36}.text-danger-800{color:#802C2A}.text-dark-300{color:var(--dark-300)}.text-dark-350{color:var(--dark-350)}.text-filter-placeholder{color:var(--filter-placeholder)}.text-footer-link{color:var(--footer-link)}.text-footer-text{color:var(--footer-text)}.text-gray-300{color:var(--gray-300)}.text-gray-350{color:var(--gray-350)}.text-gray-400{color:var(--gray-400)}.text-gray-500{color:var(--gray-500)}.text-gray-600{color:var(--gray-600)}.text-gray-700{color:var(--gray-700)}.text-gray-900{color:var(--gray-900)}.text-nav-item-text{color:var(--nav-item-text)}.text-nav-item-text-active{color:var(--nav-item-text-active)}.text-nav-item-text-active-hover{color:var(--nav-item-text-active-hover)}.text-nav-item-text-stack{color:var(--nav-item-text-stack)}.text-scheme-menu-item-text{color:var(--scheme-menu-item-text)}.text-search-hint-text{color:var(--search-hint-text)}.text-search-placeholder{color:var(--search-placeholder)}.text-success-700{color:#49887A}.text-tab-text{color:var(--tab-text)}.text-tab-text-active{color:var(--tab-text-active)}.text-toc-heading{color:var(--toc-heading)}.text-toc-text{color:var(--toc-text)}.text-toc-text-active{color:var(--toc-text-active)}.text-warning-700{color:#B68D38}.text-white{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.antialiased{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.placeholder-filter-placeholder::-moz-placeholder{color:var(--filter-placeholder)}.placeholder-filter-placeholder::placeholder{color:var(--filter-placeholder)}.placeholder-gray-400::-moz-placeholder{color:var(--gray-400)}.placeholder-gray-400::placeholder{color:var(--gray-400)}.placeholder-search-placeholder::-moz-placeholder{color:var(--search-placeholder)}.placeholder-search-placeholder::placeholder{color:var(--search-placeholder)}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-30{opacity:.3}.opacity-50{opacity:.5}.shadow-2xl{--tw-shadow:0 25px 50px -12px rgba(0,0,0,.25);--tw-shadow-colored:0 25px 50px -12px var(--tw-shadow-color)}.shadow-2xl,.shadow-lg{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-lg{--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color)}.shadow-md{--tw-shadow:0 4px 6px -1px rgba(0,0,0,.1),0 2px 4px -2px rgba(0,0,0,.1);--tw-shadow-colored:0 4px 6px -1px var(--tw-shadow-color),0 2px 4px -2px var(--tw-shadow-color)}.shadow-md,.shadow-none{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000}.shadow-sm{--tw-shadow:0 1px 2px 0 rgba(0,0,0,.05);--tw-shadow-colored:0 1px 2px 0 var(--tw-shadow-color)}.shadow-sm,.shadow-xl{box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow:0 20px 25px -5px rgba(0,0,0,.1),0 8px 10px -6px rgba(0,0,0,.1);--tw-shadow-colored:0 20px 25px -5px var(--tw-shadow-color),0 8px 10px -6px var(--tw-shadow-color)}.ring-1{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow,0 0 #0000)}.ring-inset{--tw-ring-inset:inset}.ring-branding-label-border{--tw-ring-color:var(--branding-label-border)}.blur{--tw-blur:blur(8px)}.blur,.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-all{transition-duration:.15s;transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-colors{transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-opacity{transition-duration:.15s;transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1)}.transition-transform{transition-duration:.15s;transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1)}.duration-100{transition-duration:.1s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-300{transition-duration:.3s}.duration-75{transition-duration:75ms}.ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.ease-in-out{transition-timing-function:cubic-bezier(.4,0,.2,1)}.ease-linear{transition-timing-function:linear}.ease-out{transition-timing-function:cubic-bezier(0,0,.2,1)}html{font-feature-settings:"cv02","cv03","cv04","cv11"}@font-face{font-named-instance:"Regular";font-display:swap;font-family:Inter var;font-style:normal;font-weight:100 900;src:url(../fonts/Inter-roman-latin-var.woff2) format("woff2")}@font-face{font-named-instance:"Italic";font-display:swap;font-family:Inter var;font-style:italic;font-weight:100 900;src:url(../fonts/Inter-italic-latin-var.woff2) format("woff2")}.container{margin-left:auto;margin-right:auto;max-width:1800px}.skeleton,[v-cloak]{display:none}[v-cloak].skeleton{display:flex}@media (min-width:960px){.retype-mobile-menu-button{display:none!important}}.loading{overflow:hidden;position:relative}.loading:after{animation:loading 1.5s cubic-bezier(0,0,.22,1.21) infinite;background:linear-gradient(90deg,transparent,hsla(0,0%,100%,.85),transparent);content:"";display:block;height:100%;position:absolute;width:100%}@keyframes loading{0%{transform:translateX(-100%)}to{transform:translateX(100%)}}.dark{background-color:var(--dark-850)}.dark .loading:after{background:linear-gradient(90deg,transparent,hsla(0,0%,100%,.05),transparent)}.no-transitions,.no-transitions *{transition:none!important}#retype-copyright a{color:var(--footer-link)}#retype-copyright a:hover{color:var(--footer-link-hover);text-decoration-line:underline}.docs-icon{display:inline;font-size:87.5%;vertical-align:-.2em;width:1.3em}.outbound .docs-icon{font-size:75%}.btn{align-items:center;border-radius:.25rem;cursor:pointer;display:inline-flex;font-size:.875rem;font-weight:500;height:2rem;justify-content:center;line-height:1;padding-left:.75rem;padding-right:.75rem;transition-duration:.2s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:linear;-webkit-user-select:none;-moz-user-select:none;user-select:none;white-space:nowrap}.btn:active,.btn:focus{outline:2px solid transparent;outline-offset:2px}.btn-gray-outline{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity));border-color:var(--gray-400);border-width:1px;color:var(--gray-900)}.btn-gray-outline:active,.btn-gray-outline:focus,.btn-gray-outline:hover{border-color:var(--gray-500)}.btn-icon{padding-left:0;padding-right:0;width:2rem}code[class*=language-],pre[class*=language-]{color:#e2e2e2;direction:ltr;font-family:Menlo,Monaco,Consolas,Andale Mono,Ubuntu Mono,Courier New,monospace;font-size:13px;-webkit-hyphens:none;hyphens:none;line-height:1.5;-moz-tab-size:4;-o-tab-size:4;tab-size:4;text-align:left;text-shadow:none;white-space:pre;word-break:normal;word-spacing:normal}code[class*=language-] ::-moz-selection,code[class*=language-]::-moz-selection,pre[class*=language-] ::-moz-selection,pre[class*=language-]::-moz-selection{background:#75a7ca;text-shadow:none}code[class*=language-] ::selection,code[class*=language-]::selection,pre[class*=language-] ::selection,pre[class*=language-]::selection{background:#75a7ca;text-shadow:none}@media print{code[class*=language-],pre[class*=language-]{text-shadow:none}}pre[class*=language-]{background:#1e1e1e;margin:.5em 0;padding:1em}.namespace{opacity:1}.token.doctype .token.doctype-tag{color:#569cd6}.token.doctype .token.name{color:#9cdcfe}.token.comment,.token.prolog{color:#6a9955}.language-html .language-css .token.punctuation,.language-html .language-javascript .token.punctuation,.token.punctuation{color:#d4d4d4}.token.boolean,.token.constant,.token.inserted,.token.number,.token.property,.token.symbol,.token.tag,.token.unit{color:#b5cea8}.token.attr-name,.token.builtin,.token.char,.token.deleted,.token.selector,.token.string{color:#ce9178}.language-css .token.string.url{text-decoration:underline}.token.entity,.token.operator{color:#d4d4d4}.token.operator.arrow{color:#569cd6}.token.atrule{color:#ce9178}.token.atrule .token.rule{color:#c586c0}.token.atrule .token.url{color:#9cdcfe}.token.atrule .token.url .token.function{color:#dcdcaa}.token.atrule .token.url .token.punctuation{color:#9cdcfe}.token.keyword{color:#569cd6}.token.keyword.control-flow,.token.keyword.module{color:#c586c0}.token.function,.token.function .token.maybe-class-name{color:#dcdcaa}.token.regex{color:#d16969}.token.important{color:#569cd6}.token.italic{font-style:italic}.token.constant{color:#9cdcfe}.token.class-name,.token.maybe-class-name{color:#4ec9b0}.token.console,.token.interpolation,.token.parameter{color:#9cdcfe}.token.boolean,.token.punctuation.interpolation-punctuation{color:#569cd6}.token.exports .token.maybe-class-name,.token.imports .token.maybe-class-name,.token.property,.token.variable{color:#9cdcfe}.token.escape,.token.selector{color:#d7ba7d}.token.tag{color:#569cd6}.token.cdata,.token.tag .token.punctuation{color:grey}.token.attr-name{color:#9cdcfe}.token.attr-value,.token.attr-value .token.punctuation{color:#ce9178}.token.attr-value .token.punctuation.attr-equals{color:#9cdcfe}.token.entity{color:#569cd6}.token.namespace{color:#4ec9b0}code[class*=language-cs],code[class*=language-javascript],code[class*=language-jsx],code[class*=language-tsx],code[class*=language-typescript],pre[class*=language-cs],pre[class*=language-javascript],pre[class*=language-jsx],pre[class*=language-tsx],pre[class*=language-typescript]{color:#9cdcfe}code[class*=language-css],pre[class*=language-css]{color:#ce9178}code[class*=language-html],pre[class*=language-html]{color:#9cdcfe}.language-regex .token.anchor{color:#dcdcaa}.language-html .token.punctuation{color:grey}.language-cs .token.keyword-using{color:#c586c0}.language-shell .token:not(.comment){color:#e2e2e2}pre[class*=language-]>.line-highlight{margin-top:.875rem}.line-highlight{background:hsla(0,0%,100%,.1);left:0;line-height:inherit;margin-top:1rem;padding:0;pointer-events:none;position:absolute;right:0;white-space:pre;z-index:1}@media print{.line-highlight{-webkit-print-color-adjust:exact;print-color-adjust:exact}}.retype-markdown{line-height:1.75}.retype-markdown img{display:inline}.retype-markdown h1,.retype-markdown h2,.retype-markdown h3,.retype-markdown h4,.retype-markdown h5,.retype-markdown h6{color:var(--heading-text);font-weight:700;line-height:1.25;margin-left:-2rem;overflow-wrap:break-word;padding-left:2rem}.retype-markdown h1 .header-anchor-trigger,.retype-markdown h2 .header-anchor-trigger,.retype-markdown h3 .header-anchor-trigger,.retype-markdown h4 .header-anchor-trigger,.retype-markdown h5 .header-anchor-trigger,.retype-markdown h6 .header-anchor-trigger{color:var(--body-link);float:left;font-size:1.125rem;font-weight:400;margin-left:-1.5rem;margin-top:.875rem;opacity:0}.retype-markdown h1 .header-anchor-trigger:hover,.retype-markdown h2 .header-anchor-trigger:hover,.retype-markdown h3 .header-anchor-trigger:hover,.retype-markdown h4 .header-anchor-trigger:hover,.retype-markdown h5 .header-anchor-trigger:hover,.retype-markdown h6 .header-anchor-trigger:hover{color:var(--body-link-hover)!important;text-decoration-line:none!important}.retype-markdown h1:hover .header-anchor-trigger,.retype-markdown h2:hover .header-anchor-trigger,.retype-markdown h3:hover .header-anchor-trigger,.retype-markdown h4:hover .header-anchor-trigger,.retype-markdown h5:hover .header-anchor-trigger,.retype-markdown h6:hover .header-anchor-trigger{opacity:1}.retype-markdown h2 .header-anchor-trigger{margin-top:.625rem}.retype-markdown h3 .header-anchor-trigger{margin-top:.25rem}.retype-markdown h4 .header-anchor-trigger,.retype-markdown h5 .header-anchor-trigger,.retype-markdown h6 .header-anchor-trigger{margin-top:0}.retype-markdown h5 .header-anchor-trigger,.retype-markdown h6 .header-anchor-trigger{font-size:1rem}.retype-markdown h1{font-size:2.5rem;margin-bottom:2rem;padding-right:2rem;z-index:10}.retype-markdown h2{font-size:2rem;margin-bottom:1.5rem}@media print{.flex.retype-markdown h2{page-break-inside:avoid}}.retype-markdown h3{font-size:1.5rem;margin-bottom:1rem}.retype-markdown h4{font-size:1.125rem;margin-bottom:.75rem}.retype-markdown h5{font-size:1rem;margin-bottom:.5rem}.retype-markdown h6{font-size:.875rem;margin-bottom:.5rem}.retype-markdown p:not(.hidden){margin-bottom:1.5rem}@media print{.flex.retype-markdown p:not(.hidden){page-break-inside:avoid}}.retype-markdown p:not(.hidden):has(+ol),.retype-markdown p:not(.hidden):has(+ul){margin-bottom:.5rem}.retype-markdown h1~.xtype{display:block;margin-bottom:2rem;margin-top:-1.5rem}.retype-markdown a:not(.no-link):not(:is(h1 a,h2 a,h3 a,h4 a,h5 a,h6 a)){color:var(--body-link);font-weight:var(--body-link-weight)}.retype-markdown a:not(.no-link):not(:is(h1 a,h2 a,h3 a,h4 a,h5 a,h6 a)):hover{color:var(--body-link-hover);text-decoration-line:underline}.retype-markdown a:not(.no-link):not(:is(h1 a,h2 a,h3 a,h4 a,h5 a,h6 a)) code:not([class*=language-]):not(.member-signature){color:inherit}.retype-markdown h1 a:not(.no-link),.retype-markdown h2 a:not(.no-link),.retype-markdown h3 a:not(.no-link),.retype-markdown h4 a:not(.no-link),.retype-markdown h5 a:not(.no-link),.retype-markdown h6 a:not(.no-link){color:var(--body-link)}.retype-markdown h1 a:not(.no-link):hover,.retype-markdown h2 a:not(.no-link):hover,.retype-markdown h3 a:not(.no-link):hover,.retype-markdown h4 a:not(.no-link):hover,.retype-markdown h5 a:not(.no-link):hover,.retype-markdown h6 a:not(.no-link):hover{color:var(--body-link-hover);text-decoration-line:underline}.retype-markdown .link-dark{color:var(--gray-900);font-weight:600}.retype-markdown .link-dark:hover{color:var(--gray-900);text-decoration-line:underline}.retype-markdown code:not([class*=language-]):not(.member-signature),.retype-markdown kbd,.retype-markdown pre:not([class*=language-]):not(.member-signature){font-size:92.5%;font-weight:400}.retype-markdown code:not([class*=language-]):not(.member-signature){background-color:var(--gray-100);border-color:var(--gray-200);border-radius:.25rem;border-width:1px;color:var(--gray-900);line-height:1;padding:2px 5px}.retype-markdown kbd{--tw-border-opacity:0.75;border-color:var(--gray-400);border-radius:.25rem;border-width:1px;box-shadow:0 1px 0 0 #edeff4;display:inline-block;line-height:1;padding:2px 5px}.retype-markdown kbd,.retype-markdown select{--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity));color:var(--gray-900)}.retype-markdown select{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;border-color:var(--gray-300);border-radius:.5rem;border-width:1px;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow);font-size:.875rem;height:2rem;margin-bottom:1.5rem;padding:.25rem .75rem;transition-duration:.2s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:linear}@media print{.flex.retype-markdown select{page-break-inside:avoid}}.retype-markdown select:focus{border-color:var(--gray-600);outline:2px solid transparent;outline-offset:2px}.retype-markdown select{-webkit-appearance:none;-moz-appearance:none;appearance:none;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='currentColor' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");background-position:right .5rem center;background-repeat:no-repeat;background-size:1em;padding-right:2rem;transition:color .2s ease,background-color .2s ease}.retype-markdown select[multiple]{background-image:none;padding-bottom:.5rem;padding-right:.5rem;padding-top:.5rem}.retype-markdown select:disabled{background-color:var(--gray-100);border-color:var(--gray-200);color:var(--gray-500);cursor:not-allowed}.retype-markdown select.lg{font-size:1rem;height:2.5rem;padding:.5rem 2.5rem .5rem 1rem}.retype-markdown select.sm{font-size:.8125rem;height:1.5rem;padding:.125rem 1.5rem .125rem .5rem}.retype-markdown ol,.retype-markdown ul{margin-bottom:1.5rem;padding-left:2rem}@media print{.flex .retype-markdown ul,.flex.retype-markdown ol{page-break-inside:avoid}}.retype-markdown ol ol,.retype-markdown ol ul,.retype-markdown ul ol,.retype-markdown ul ul{margin-bottom:0;padding-left:2rem}.retype-markdown ol{list-style-type:decimal}.retype-markdown ol[type=A]{list-style-type:upper-alpha}.retype-markdown ol[type=a]{list-style-type:lower-alpha}.retype-markdown ol[type=I]{list-style-type:upper-roman}.retype-markdown ol[type=i]{list-style-type:lower-roman}.retype-markdown ol[type="1"]{list-style-type:decimal}.retype-markdown ul{list-style-type:disc}.retype-markdown ul ul{list-style-type:circle}.retype-markdown ul ul ul{list-style-type:square}.retype-markdown ul.contains-task-list{list-style-type:none;padding-left:9px}.retype-markdown ul.contains-task-list input{margin-left:1px;margin-right:5px;margin-top:1px;position:relative}.retype-markdown ul.contains-task-list input:after,.retype-markdown ul.contains-task-list input:before{border-radius:.125rem;display:block;height:1rem;position:absolute;width:1rem;z-index:5}.retype-markdown ul.contains-task-list input:before{background-color:var(--list-unchecked);content:"";left:-1px;top:0;z-index:5}.retype-markdown ul.contains-task-list input:checked:before{background-color:var(--list-checked)}.retype-markdown ul.contains-task-list input:checked:after{--tw-rotate:45deg;border-radius:0;border-width:0 2px 2px 0;bottom:.125rem;display:inline-block;height:.625rem;left:.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));width:.375rem;z-index:10}@media print{.shrink-0.retype-markdown ul.contains-task-list input:checked:after{flex-shrink:0;min-width:6px;print-color-adjust:exact;-webkit-print-color-adjust:exact;width:6px}}.retype-markdown ul.contains-task-list input:checked:after{content:""}.retype-markdown dl{border-collapse:separate;display:table;margin-bottom:1.5rem;width:100%}@media print{.flex.retype-markdown dl{page-break-inside:avoid}}.retype-markdown dl:after{--tw-content:"";clear:both;content:var(--tw-content);display:block}.retype-markdown dt{border-top-width:1px;clear:left;float:left;font-weight:500;padding-bottom:1rem;padding-right:1rem;padding-top:1rem;width:33.333333%}@media print{footer .retype-markdown dt{display:none}}:is(.dark .retype-markdown dt){border-top-color:var(--dark-650)}.retype-markdown dt:first-child{padding-top:1rem}.retype-markdown dd{border-top-width:1px;padding-bottom:1rem;padding-right:1rem;padding-top:1rem;width:66.666667%}@media print{footer .retype-markdown dd{display:none}}:is(.dark .retype-markdown dd){border-top-color:var(--dark-650)}.retype-markdown dd{margin-left:33.333333%}.retype-markdown dt+dt{border-top-width:0;padding-bottom:.25rem;padding-top:0}.retype-markdown dd+dd+dt,.retype-markdown dd+dt{clear:both;padding-top:1rem}.retype-markdown dl+*{clear:both}.retype-markdown ul.list-icon,.retype-markdown ul.list-icon ul{list-style-type:none;padding-left:1rem}.retype-markdown ul.list-icon li>svg.docs-icon:first-child,.retype-markdown ul.list-icon ul li>svg.docs-icon:first-child{margin-right:.25rem}.retype-markdown blockquote{background-color:var(--gray-100);border-left-width:4px;color:var(--gray-600);margin-bottom:1.5rem;padding:1rem 1rem 1rem 1.25rem}@media print{.flex.retype-markdown blockquote{page-break-inside:avoid}}.retype-markdown blockquote p:last-child{margin-bottom:0}.retype-markdown .table-wrapper{border-radius:.375rem;border-width:1px;margin-bottom:1.5rem}@media print{.flex.retype-markdown .table-wrapper{page-break-inside:avoid}}.retype-markdown table{border-collapse:separate;border-spacing:0;overflow:auto}.retype-markdown table tr td,.retype-markdown table tr th{border-bottom-width:1px;border-right-width:1px;padding:.5rem .75rem}.retype-markdown table tr td:last-child,.retype-markdown table tr th:last-child{border-right-width:0}.retype-markdown table th{color:var(--gray-900);font-weight:500}.retype-markdown table th:empty{display:none}.retype-markdown table tbody>tr:last-child td{border-bottom-width:0}.retype-markdown table.compact{font-size:.875rem;width:100%}.retype-markdown table.compact th{text-align:left}.retype-markdown table.compact tr td,.retype-markdown table.compact tr th{padding:.375rem .625rem}.retype-markdown table.comfortable{width:100%}.retype-markdown table.comfortable th{text-align:left}.retype-markdown table.comfortable tr td,.retype-markdown table.comfortable tr th{padding:1rem 1.25rem}.retype-markdown hr{border-color:var(--gray-200);margin-bottom:2rem;margin-top:2rem}.retype-markdown figure{margin-bottom:1.5rem}@media print{.flex.retype-markdown figure{page-break-inside:avoid}}.retype-markdown figure>:first-child{margin-bottom:0}.retype-markdown .caption{color:var(--gray-500);font-size:.875rem;margin-top:.5rem;text-align:center}.retype-markdown .doc-member h3{font-size:1rem;margin:0;padding:0}.retype-markdown .doc-member p{margin-bottom:1rem}.retype-markdown .doc-member :last-child{margin-bottom:0}.retype-markdown .doc-member-group>.doc-member{border-top-left-radius:.375rem;border-top-right-radius:.375rem;border-top-width:1px}@media print{footer .retype-markdown .doc-member-group>.doc-member{display:none}}.retype-markdown .doc-member-group>.doc-member:last-child{border-bottom-left-radius:.375rem;border-bottom-right-radius:.375rem}.retype-markdown .doc-member-group>.doc-member~.doc-member{border-top-left-radius:0;border-top-right-radius:0}.retype-markdown.filtered>:not(.doc-member-group){display:none}.retype-markdown .docs-columns{display:grid}.retype-markdown .docs-columns-content>:last-child{margin-bottom:0}.retype-markdown .docs-columns-code{background-color:var(--dark-850);border-color:var(--dark-550)}.retype-markdown .docs-columns-code .codeblock-wrapper{border:none!important}.retype-markdown .docs-columns-code-title{background-color:var(--dark-850);border-bottom-width:1px;border-color:var(--dark-550)}.retype-markdown code[class*=language-],.retype-markdown pre[class*=language-]{line-height:1.6}.retype-markdown pre[class*=language-]{margin:0;padding:1rem 1.25rem}.retype-markdown .codeblock-wrapper{--tw-border-opacity:1;background-color:var(--dark-850);border-color:rgb(255 255 255/var(--tw-border-opacity));border-radius:.5rem;border-width:1px;margin-bottom:1.5rem;overflow:hidden;width:100%}@media print{.flex.retype-markdown .codeblock-wrapper{page-break-inside:avoid}}.retype-markdown .codeblock.line-numbers pre{padding-left:3.75rem}.retype-markdown .codeblock .tooltip,.retype-markdown .codeblock .tooltip .arrow:before{background-color:var(--dark-500)}.retype-markdown .codeblock-title{border-bottom-width:1px;border-color:var(--dark-550);color:var(--dark-250);font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:.875rem;height:3rem;line-height:3rem;overflow:hidden;padding-left:1.25rem;padding-right:1.25rem;text-overflow:ellipsis;white-space:nowrap}.retype-markdown .codeblock-title code{--tw-text-opacity:1!important;background-color:var(--dark-500)!important;border-color:var(--dark-450)!important;border-width:1px!important;color:rgb(255 255 255/var(--tw-text-opacity))!important}.retype-markdown nav.breadcrumb{color:var(--gray-500);display:flex;font-size:.875rem;font-weight:500;margin-bottom:1rem}@media print{.retype-markdown nav.breadcrumb.mb-6{page-break-inside:avoid}}.retype-markdown nav.breadcrumb ol{align-items:center;display:flex;flex-wrap:wrap;list-style-type:none;margin:0;padding:0}@media print{.retype-markdown nav.breadcrumb ol.mb-6{page-break-inside:avoid}}.retype-markdown nav.breadcrumb ol li{align-items:center;display:flex}@media print{.retype-markdown nav.breadcrumb ol li.mb-6{page-break-inside:avoid}}.retype-markdown nav.breadcrumb ol li a{color:var(--gray-500);text-decoration-line:none;transition-duration:.2s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:linear}.retype-markdown nav.breadcrumb ol li a:hover{color:#5694EF;text-decoration-line:none}#retype-app #docs-hub-link{border-radius:.25rem;display:flex;margin-right:.5rem;padding:.125rem;transition-duration:.2s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:cubic-bezier(.4,0,1,1)}@media print{#retype-app #docs-hub-link.mb-6{page-break-inside:avoid}}#retype-app #docs-hub-link:hover{background-color:var(--gray-200)}#retype-app #docs-hub-link:focus{background-color:var(--gray-300);outline:2px solid transparent;outline-offset:2px}.dark .retype-markdown a:not(.no-link) code:not([class*=language-]):not(.member-signature){color:inherit}.dark .retype-markdown .link-dark{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.dark .retype-markdown blockquote{background-color:var(--dark-700);border-color:var(--dark-500);border-width:0 0 0 4px;color:var(--dark-300)}.dark .retype-markdown code:not([class*=language-]):not(.member-signature){--tw-text-opacity:1;background-color:var(--dark-500);border-color:var(--dark-450);border-width:1px;color:rgb(255 255 255/var(--tw-text-opacity))}.dark .retype-markdown kbd{--tw-border-opacity:0.75;--tw-text-opacity:1;background-color:var(--dark-800);border-color:var(--dark-400);border-radius:.25rem;border-width:1px;box-shadow:0 1px 0 0 #505050;color:rgb(255 255 255/var(--tw-text-opacity));display:inline-block;line-height:1;padding:2px 5px}.dark .retype-markdown .table-wrapper,.dark .retype-markdown table td,.dark .retype-markdown table th,.dark .retype-markdown table tr{border-color:var(--dark-500)}.dark .retype-markdown table th{color:var(--gray-300)}.dark .retype-markdown hr{border-color:var(--dark-600)}.dark .retype-markdown .caption{color:var(--dark-350)}.dark .retype-markdown .doc-member h3{color:var(--gray-300)}.dark .retype-markdown .doc-member-group>.doc-member{border-color:var(--dark-650)}.dark .retype-markdown .docs-columns-code,.dark .retype-markdown .docs-columns-code-title,.dark .retype-markdown pre[class*=language-]{background-color:var(--dark-800)}.dark .retype-markdown .codeblock-wrapper{background-color:var(--dark-800);border-color:var(--dark-650)}.dark .retype-markdown nav.breadcrumb{color:var(--dark-400)}.dark .retype-markdown nav.breadcrumb ol li a{color:var(--dark-400)!important}.dark .retype-markdown nav.breadcrumb ol li a:hover{color:#86A7F5!important}.dark .retype-markdown select{--tw-text-opacity:1;background-color:var(--dark-550);border-color:var(--dark-600);color:rgb(255 255 255/var(--tw-text-opacity))}.dark .retype-markdown select::-moz-placeholder{color:var(--dark-400)}.dark .retype-markdown select::placeholder{color:var(--dark-400)}.dark .retype-markdown select:focus,.dark .retype-markdown select:hover{background-color:var(--dark-450);border-color:var(--dark-450)}.dark .retype-markdown select{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%23fff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' viewBox='0 0 24 24'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E")}.dark .retype-markdown select:disabled{background-color:var(--dark-700);border-color:var(--dark-550);color:var(--dark-350)}.dark #retype-app #docs-hub-link{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.dark #retype-app #docs-hub-link:hover{background-color:var(--dark-500)}.dark #retype-app #docs-hub-link:focus{background-color:var(--dark-450)}.doc-callout h5{line-height:1.75;margin-bottom:.25rem;margin-left:0;padding:0}.doc-callout p:last-child{margin-bottom:0}.doc-callout.doc-callout-contrast a{color:#82A9F8!important}.doc-callout.doc-callout-contrast h5{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.doc-callout.doc-callout-contrast code:not([class*=language-]):not(.member-signature){--tw-text-opacity:1;background-color:var(--gray-700);border-color:var(--gray-600);color:rgb(255 255 255/var(--tw-text-opacity))}.dark .doc-callout.doc-callout-contrast a{color:#5694EF!important}.dark .doc-callout.doc-callout-contrast h5{color:var(--gray-900)}.dark .doc-callout.doc-callout-contrast code:not([class*=language-]){background-color:#f3f5f9;border-color:var(--gray-300);color:var(--gray-900)}[data-simplebar]{align-content:flex-start;align-items:flex-start;flex-direction:column;flex-wrap:wrap;justify-content:flex-start;position:relative}.simplebar-wrapper{height:inherit;max-height:inherit;max-width:inherit;overflow:hidden;width:inherit}.simplebar-mask{direction:inherit;height:auto!important;overflow:hidden;width:auto!important;z-index:0}.simplebar-mask,.simplebar-offset{bottom:0;left:0;margin:0;padding:0;position:absolute;right:0;top:0}.simplebar-offset{-webkit-overflow-scrolling:touch;box-sizing:inherit!important;direction:inherit!important;resize:none!important}.simplebar-content-wrapper{-ms-overflow-style:none;box-sizing:border-box!important;direction:inherit;display:block;height:100%;max-height:100%;max-width:100%;overflow:auto;position:relative;scrollbar-width:none;width:auto}.simplebar-content-wrapper::-webkit-scrollbar,.simplebar-hide-scrollbar::-webkit-scrollbar{display:none;height:0;width:0}.simplebar-content:after,.simplebar-content:before{content:" ";display:table}.simplebar-placeholder{max-height:100%;max-width:100%;pointer-events:none;width:100%}.simplebar-height-auto-observer-wrapper{box-sizing:inherit!important;flex-basis:0;flex-grow:inherit;flex-shrink:0;float:left;height:100%;margin:0;max-height:1px;max-width:1px;overflow:hidden;padding:0;pointer-events:none;position:relative;width:100%;z-index:-1}.simplebar-height-auto-observer{box-sizing:inherit;display:block;height:1000%;left:0;min-height:1px;min-width:1px;opacity:0;top:0;width:1000%;z-index:-1}.simplebar-height-auto-observer,.simplebar-track{overflow:hidden;pointer-events:none;position:absolute}.simplebar-track{bottom:0;right:0;z-index:1}[data-simplebar].simplebar-dragging,[data-simplebar].simplebar-dragging .simplebar-content{-webkit-touch-callout:none;pointer-events:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}[data-simplebar].simplebar-dragging .simplebar-track{pointer-events:all}.simplebar-scrollbar{left:0;min-height:10px;position:absolute;right:0}.simplebar-scrollbar:before{background:#000;border-radius:7px;content:"";opacity:0;position:absolute;transition:opacity .2s linear .5s}.simplebar-scrollbar.simplebar-visible:before{opacity:.5;transition-delay:0s;transition-duration:0s}.simplebar-track.simplebar-vertical{top:0;width:11px}.simplebar-scrollbar:before{bottom:2px;left:2px;right:2px;top:2px}.simplebar-track.simplebar-horizontal{height:11px;left:0}.simplebar-track.simplebar-horizontal .simplebar-scrollbar{bottom:0;left:0;min-height:0;min-width:10px;right:auto;top:0;width:auto}[data-simplebar-direction=rtl] .simplebar-track.simplebar-vertical{left:0;right:auto}.simplebar-dummy-scrollbar-size{-ms-overflow-style:scrollbar!important;direction:rtl;height:500px;opacity:0;overflow-x:scroll;overflow-y:hidden;position:fixed;visibility:hidden;width:500px}.simplebar-dummy-scrollbar-size>div{height:200%;margin:10px 0;width:200%}.simplebar-hide-scrollbar{-ms-overflow-style:none;left:0;overflow-y:scroll;position:fixed;scrollbar-width:none;visibility:hidden}.simplebar-scrollbar:before{--tw-bg-opacity:0.2;background:initial;background-color:var(--gray-900)}.simplebar-scrollbar.simplebar-visible:before{opacity:1}.dark .simplebar-scrollbar:before{--tw-bg-opacity:0.2;background-color:rgb(255 255 255/var(--tw-bg-opacity))}pre[class*=language-] .simplebar-content:after,pre[class*=language-] .simplebar-content:before{content:normal;display:initial}pre[class*=language-] .simplebar-scrollbar:before{--tw-bg-opacity:.3;background-color:rgb(255 255 255/var(--tw-bg-opacity))}.dark pre[class*=language-] .simplebar-scrollbar:before{--tw-bg-opacity:0.2;background-color:rgb(255 255 255/var(--tw-bg-opacity))}@media print{#retype-content-footer,#retype-header,#retype-sidebar-left,#retype-sidebar-left-toggle-button,#retype-sidebar-right,#retype-sidebar-right-toggle,#retype-tags,.codeblock-wrapper button,.docs-toc,.docs-toc-container,.header-anchor-trigger,.retype-mobile-menu-button,.retype-outbound-trigger,doc-back-to-top,doc-history,doc-search-desktop,doc-search-mobile,doc-theme-switch,doc-toolbar-member-filter-no-results,footer .border-t,header,nav.breadcrumb{display:none!important}#retype-content{margin:0;max-width:100%;padding:0;width:100%}#retype-app,.retype-markdown,body{background-color:#fff;color:#000}.retype-markdown h1,.retype-markdown h2,.retype-markdown h3,.retype-markdown h4,.retype-markdown h5,.retype-markdown h6{color:#000!important;page-break-after:avoid}.retype-markdown h2{page-break-before:always}.retype-markdown h1{font-size:3rem;text-align:center}h2,h3,h4,h5,h6,p{orphans:3;widows:3}a{color:#222;font-weight:500;text-decoration:none}a[href^=http]:after{color:#666;content:" (" attr(href) ")";font-weight:400}a[href^="#"]:after,a[href^="../"]:after,a[href^="./"]:after,a[href^="/"]:after,a[href^="javascript:"]:after,a[href^="mailto:"]:after{content:""}abbr{border-bottom:none!important;text-decoration:none!important}figure,pre,table,tbody,td,th,thead,tr{page-break-inside:avoid}table{border-collapse:collapse!important;border-radius:0!important;border-spacing:0!important;margin-bottom:16px!important;width:100%!important}table,td,th{border:1px solid #e5e5e5!important}td,th{border:1px solid #e5e5e5!important;padding:8px 12px!important;print-color-adjust:exact!important;-webkit-print-color-adjust:exact!important;text-align:left!important;vertical-align:top!important}td,th{background-color:transparent!important;color:#000!important}th{font-weight:600!important}.dark table,.light table,table{background-color:transparent!important;border:1px solid #e5e5e5!important}.codeblock-wrapper,.dark td,.dark th,.light td,.light th,code,pre,td,th{background-color:transparent!important;border:1px solid #e5e5e5!important;color:#000!important}.codeblock-wrapper,code,pre{print-color-adjust:exact!important;-webkit-print-color-adjust:exact!important}.codeblock-wrapper{border-radius:8px!important;-webkit-border-radius:8px!important;-moz-border-radius:8px!important;box-sizing:border-box!important;max-width:100%!important;overflow:visible!important;padding:16px!important;page-break-inside:avoid!important;width:100%!important}.codeblock-wrapper pre{margin:0!important;max-width:100%!important;padding:0!important}.codeblock-wrapper pre,.codeblock-wrapper pre code{word-wrap:break-word!important;background-color:transparent!important;border:none!important;border-radius:0!important;overflow:visible!important;white-space:pre-wrap!important}.codeblock-wrapper pre code,code{color:#000!important}code{background-color:transparent!important;border:1px solid #e5e5e5!important;border-radius:3px!important;padding:2px 4px!important;print-color-adjust:exact!important;-webkit-print-color-adjust:exact!important}.flex.mb-6{page-break-inside:avoid}.shrink-0.w-1\.5{flex-shrink:0!important;min-width:6px!important;print-color-adjust:exact!important;-webkit-print-color-adjust:exact!important;width:6px!important}.bg-callout-primary{background-color:#333!important}.bg-callout-secondary{background-color:#666!important}.bg-callout-success{background-color:#444!important}.bg-callout-danger{background-color:#222!important}.bg-callout-warning{background-color:#555!important}.bg-callout-info{background-color:#777!important}.bg-callout-light{background-color:#999!important}.bg-callout-dark{background-color:#111!important}.bg-callout-ghost{background-color:#888!important}.bg-callout-contrast{background-color:#000!important}.bg-callout-question{background-color:#444!important}.bg-callout-tip{background-color:#555!important}.bg-callout-base{background-color:#666!important}.doc-callout{background-color:transparent!important;border:1px solid #ddd!important;page-break-inside:avoid}.doc-callout,.doc-callout svg{print-color-adjust:exact!important;-webkit-print-color-adjust:exact!important}.doc-callout svg{color:#333!important}@page{margin:2cm}}.hover\:z-5:hover{z-index:5}.hover\:border-badge-base-border-hover:hover{border-color:var(--badge-base-border-hover)}.hover\:border-badge-contrast-border-hover:hover{border-color:var(--badge-contrast-border-hover)}.hover\:border-badge-danger-border-hover:hover{border-color:var(--badge-danger-border-hover)}.hover\:border-badge-dark-border-hover:hover{border-color:var(--badge-dark-border-hover)}.hover\:border-badge-ghost-border-hover:hover{border-color:var(--badge-ghost-border-hover)}.hover\:border-badge-info-border-hover:hover{border-color:var(--badge-info-border-hover)}.hover\:border-badge-light-border-hover:hover{border-color:var(--badge-light-border-hover)}.hover\:border-badge-primary-border-hover:hover{border-color:var(--badge-primary-border-hover)}.hover\:border-badge-secondary-border-hover:hover{border-color:var(--badge-secondary-border-hover)}.hover\:border-badge-success-border-hover:hover{border-color:var(--badge-success-border-hover)}.hover\:border-badge-warning-border-hover:hover{border-color:var(--badge-warning-border-hover)}.hover\:border-base-border-hover:hover{border-color:var(--base-border-hover)}.hover\:border-button-info-border-hover:hover{border-color:var(--button-info-border-hover)}.hover\:border-filter-border-hover:hover{border-color:var(--filter-border-hover)}.hover\:border-gray-400:hover{border-color:var(--gray-400)}.hover\:border-search-border-hover:hover{border-color:var(--search-border-hover)}.hover\:border-tab-border-hover:hover{border-color:var(--tab-border-hover)}.hover\:border-opacity-10:hover{--tw-border-opacity:0.1}.hover\:bg-badge-base-hover:hover{background-color:var(--badge-base-hover)}.hover\:bg-badge-contrast-hover:hover{background-color:var(--badge-contrast-hover)}.hover\:bg-badge-danger-hover:hover{background-color:var(--badge-danger-hover)}.hover\:bg-badge-dark-hover:hover{background-color:var(--badge-dark-hover)}.hover\:bg-badge-ghost-hover:hover{background-color:var(--badge-ghost-hover)}.hover\:bg-badge-info-hover:hover{background-color:var(--badge-info-hover)}.hover\:bg-badge-light-hover:hover{background-color:var(--badge-light-hover)}.hover\:bg-badge-primary-hover:hover{background-color:var(--badge-primary-hover)}.hover\:bg-badge-secondary-hover:hover{background-color:var(--badge-secondary-hover)}.hover\:bg-badge-success-hover:hover{background-color:var(--badge-success-hover)}.hover\:bg-badge-warning-hover:hover{background-color:var(--badge-warning-hover)}.hover\:bg-base-item-bg-active:hover{background-color:var(--base-item-bg-active)}.hover\:bg-base-item-bg-hover:hover{background-color:var(--base-item-bg-hover)}.hover\:bg-button-base-hover:hover{background-color:var(--button-base-hover)}.hover\:bg-button-contrast-hover:hover{background-color:var(--button-contrast-hover)}.hover\:bg-button-danger-hover:hover{background-color:var(--button-danger-hover)}.hover\:bg-button-dark-hover:hover{background-color:var(--button-dark-hover)}.hover\:bg-button-ghost-hover:hover{background-color:var(--button-ghost-hover)}.hover\:bg-button-info-hover:hover{background-color:var(--button-info-hover)}.hover\:bg-button-light-hover:hover{background-color:var(--button-light-hover)}.hover\:bg-button-primary-hover:hover{background-color:var(--button-primary-hover)}.hover\:bg-button-secondary-hover:hover{background-color:var(--button-secondary-hover)}.hover\:bg-button-success-hover:hover{background-color:var(--button-success-hover)}.hover\:bg-button-warning-hover:hover{background-color:var(--button-warning-hover)}.hover\:bg-gray-200:hover{background-color:var(--gray-200)}.hover\:bg-gray-300:hover{background-color:var(--gray-300)}.hover\:bg-nav-item-bg-hover:hover{background-color:var(--nav-item-bg-hover)}.hover\:bg-opacity-50:hover{--tw-bg-opacity:0.5}.hover\:text-badge-base-text-hover:hover{color:var(--badge-base-text-hover)}.hover\:text-badge-contrast-text-hover:hover{color:var(--badge-contrast-text-hover)}.hover\:text-badge-danger-text-hover:hover{color:var(--badge-danger-text-hover)}.hover\:text-badge-dark-text-hover:hover{color:var(--badge-dark-text-hover)}.hover\:text-badge-ghost-text-hover:hover{color:var(--badge-ghost-text-hover)}.hover\:text-badge-info-text-hover:hover{color:var(--badge-info-text-hover)}.hover\:text-badge-light-text-hover:hover{color:var(--badge-light-text-hover)}.hover\:text-badge-primary-text-hover:hover{color:var(--badge-primary-text-hover)}.hover\:text-badge-secondary-text-hover:hover{color:var(--badge-secondary-text-hover)}.hover\:text-badge-success-text-hover:hover{color:var(--badge-success-text-hover)}.hover\:text-badge-warning-text-hover:hover{color:var(--badge-warning-text-hover)}.hover\:text-base-500:hover{color:#5694EF}.hover\:text-base-link-hover:hover{color:var(--base-link-hover)}.hover\:text-body-link-hover:hover{color:var(--body-link-hover)}.hover\:text-button-info-text-hover:hover{color:var(--button-info-text-hover)}.hover\:text-button-primary-hover:hover{color:var(--button-primary-hover)}.hover\:text-footer-link-hover:hover{color:var(--footer-link-hover)}.hover\:text-gray-600:hover{color:var(--gray-600)}.hover\:text-gray-800:hover{color:var(--gray-800)}.hover\:text-header-text-hover:hover{color:var(--header-text-hover)}.hover\:text-nav-item-text-active-hover:hover{color:var(--nav-item-text-active-hover)}.hover\:text-tab-text-hover:hover{color:var(--tab-text-hover)}.hover\:text-toc-text-hover:hover{color:var(--toc-text-hover)}.hover\:text-white:hover{--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}.hover\:underline:hover{text-decoration-line:underline}.focus\:border-filter-border-focus:focus{border-color:var(--filter-border-focus)}.focus\:border-gray-600:focus{border-color:var(--gray-600)}.focus\:border-search-border-focus:focus{border-color:var(--search-border-focus)}.focus\:bg-gray-200:focus{background-color:var(--gray-200)}.focus\:bg-gray-300:focus{background-color:var(--gray-300)}.focus\:bg-gray-400:focus{background-color:var(--gray-400)}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.group:hover .group-hover\:visible{visibility:visible}.group:hover .group-hover\:inline-flex{display:inline-flex}.group:hover .group-hover\:text-nav-item-text-hover{color:var(--nav-item-text-hover)}.group:hover .group-hover\:opacity-100{opacity:1}:is(.dark .dark\:inline-block){display:inline-block}:is(.dark .dark\:hidden){display:none}:is(.dark .dark\:border-base-border){border-color:var(--base-border)}:is(.dark .dark\:border-dark-450){border-color:var(--dark-450)}:is(.dark .dark\:border-dark-500){border-color:var(--dark-500)}:is(.dark .dark\:border-dark-600){border-color:var(--dark-600)}:is(.dark .dark\:border-dark-700){border-color:var(--dark-700)}:is(.dark .dark\:border-dark-850){border-color:var(--dark-850)}:is(.dark .dark\:bg-danger-400){background-color:#E07D7B}:is(.dark .dark\:bg-danger-500){background-color:#D14E44}:is(.dark .dark\:bg-dark-400){background-color:var(--dark-400)}:is(.dark .dark\:bg-dark-450){background-color:var(--dark-450)}:is(.dark .dark\:bg-dark-500){background-color:var(--dark-500)}:is(.dark .dark\:bg-dark-550){background-color:var(--dark-550)}:is(.dark .dark\:bg-dark-600){background-color:var(--dark-600)}:is(.dark .dark\:bg-dark-650){background-color:var(--dark-650)}:is(.dark .dark\:bg-dark-700){background-color:var(--dark-700)}:is(.dark .dark\:bg-dark-800){background-color:var(--dark-800)}:is(.dark .dark\:bg-dark-850){background-color:var(--dark-850)}:is(.dark .dark\:bg-dark-900){background-color:var(--dark-900)}:is(.dark .dark\:bg-success-500){background-color:#5CA99A}:is(.dark .dark\:bg-warning-500){background-color:#E4B045}:is(.dark .dark\:bg-white){--tw-bg-opacity:1;background-color:rgb(255 255 255/var(--tw-bg-opacity))}:is(.dark .dark\:bg-opacity-50){--tw-bg-opacity:0.5}:is(.dark .dark\:bg-opacity-70){--tw-bg-opacity:0.7}:is(.dark .dark\:bg-opacity-80){--tw-bg-opacity:0.8}:is(.dark .dark\:px-5){padding-left:1.25rem;padding-right:1.25rem}:is(.dark .dark\:text-dark-200){color:var(--dark-200)}:is(.dark .dark\:text-dark-250){color:var(--dark-250)}:is(.dark .dark\:text-dark-300){color:var(--dark-300)}:is(.dark .dark\:text-dark-350){color:var(--dark-350)}:is(.dark .dark\:text-dark-400){color:var(--dark-400)}:is(.dark .dark\:text-dark-650){color:var(--dark-650)}:is(.dark .dark\:text-white){--tw-text-opacity:1;color:rgb(255 255 255/var(--tw-text-opacity))}:is(.dark .dark\:placeholder-dark-400)::-moz-placeholder{color:var(--dark-400)}:is(.dark .dark\:placeholder-dark-400)::placeholder{color:var(--dark-400)}:is(.dark .dark\:shadow-lg){--tw-shadow:0 10px 15px -3px rgba(0,0,0,.1),0 4px 6px -4px rgba(0,0,0,.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color),0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}:is(.dark .dark\:hover\:border-dark-450:hover){border-color:var(--dark-450)}:is(.dark .dark\:hover\:bg-dark-450:hover){background-color:var(--dark-450)}:is(.dark .dark\:hover\:bg-dark-500:hover){background-color:var(--dark-500)}:is(.dark .dark\:hover\:bg-opacity-50:hover){--tw-bg-opacity:0.5}:is(.dark .dark\:hover\:text-dark-300:hover){color:var(--dark-300)}:is(.dark .dark\:focus\:border-dark-450:focus){border-color:var(--dark-450)}:is(.dark .dark\:focus\:bg-dark-450:focus){background-color:var(--dark-450)}:is(.dark .dark\:focus\:bg-dark-750:focus){background-color:var(--dark-750)}@media (min-width:640px){.sm\:mr-1{margin-right:.25rem}.sm\:block{display:block}.sm\:inline{display:inline}.sm\:grid{display:grid}.sm\:w-1\/2{width:50%}.sm\:w-auto{width:auto}.sm\:px-16{padding-left:4rem;padding-right:4rem}.sm\:px-3{padding-left:.75rem;padding-right:.75rem}}@media (min-width:960px){.md\:sticky{position:sticky}.md\:top-20{top:5rem}.md\:z-0{z-index:0}.md\:mb-0{margin-bottom:0}.md\:mt-16{margin-top:4rem}.md\:mt-6{margin-top:1.5rem}.md\:line-clamp-2{-webkit-box-orient:vertical;-webkit-line-clamp:2;display:-webkit-box;overflow:hidden}.md\:block{display:block}.md\:inline-block{display:inline-block}.md\:flex{display:flex}.md\:hidden{display:none}.md\:h-20{height:5rem}.md\:h-screen{height:100vh}.md\:w-104{width:26rem}.md\:w-5\/12{width:41.666667%}.md\:w-75{width:18.75rem}.md\:grow{flex-grow:1}.md\:flex-row{flex-direction:row}.md\:items-center{align-items:center}.md\:justify-start{justify-content:flex-start}.md\:border-r{border-right-width:1px}.md\:border-none{border-style:none}.md\:bg-transparent{background-color:transparent}.md\:p-0{padding:0}.md\:px-16{padding-left:4rem;padding-right:4rem}.md\:px-4{padding-left:1rem;padding-right:1rem}.md\:px-6{padding-left:1.5rem;padding-right:1.5rem}.md\:px-8{padding-left:2rem;padding-right:2rem}.md\:pb-0{padding-bottom:0}.md\:pl-16{padding-left:4rem}.md\:pt-0{padding-top:0}.md\:text-2xs{font-size:.75rem}.md\:text-4xl{font-size:2.5rem}.md\:text-lg{font-size:1.125rem}.md\:text-sm{font-size:.875rem}.md\:text-xl{font-size:1.25rem}.md\:text-header-text{color:var(--header-text)}.md\:shadow-none{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}.md\:transition-transform{transition-duration:.15s;transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1)}}@media (min-width:1200px){.lg\:sticky{position:sticky}.lg\:top-20{top:5rem}.lg\:top-40{top:10rem}.lg\:z-0{z-index:0}.lg\:ml-2{margin-left:.5rem}.lg\:ml-auto{margin-left:auto}.lg\:block{display:block}.lg\:flex{display:flex}.lg\:hidden{display:none}.lg\:h-auto{height:auto}.lg\:w-64{width:16rem}.lg\:max-w-sm{max-width:24rem}.lg\:shrink-0{flex-shrink:0}.lg\:transform-none{transform:none}.lg\:flex-col{flex-direction:column}.lg\:border-l{border-left-width:1px}.lg\:border-none{border-style:none}.lg\:pt-2{padding-top:.5rem}.lg\:pt-6{padding-top:1.5rem}.lg\:shadow-none{--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow,0 0 #0000),var(--tw-ring-shadow,0 0 #0000),var(--tw-shadow)}}@media (min-width:1440px){.xl\:block{display:block}}@media print{.print\:hidden{display:none}.print\:justify-center{justify-content:center}.print\:border-none{border-style:none}}.arrow[data-v-325bee49],.arrow[data-v-325bee49]:before{height:.5rem;position:absolute;width:.5rem;z-index:-1}.arrow[data-v-325bee49]:before{--tw-rotate:45deg;background-color:var(--gray-900);content:"";transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.tooltip[data-popper-placement^=top]>.arrow[data-v-325bee49]{bottom:-4px}.tooltip[data-popper-placement^=bottom]>.arrow[data-v-325bee49]{top:-4px}.tooltip[data-popper-placement^=left]>.arrow[data-v-325bee49]{right:-4px}.tooltip[data-popper-placement^=right]>.arrow[data-v-325bee49]{left:-4px}.dark .arrow[data-v-325bee49]:before{background-color:var(--dark-500)}.collapse-content :last-child{margin-bottom:0}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:0),(-webkit-min-device-pixel-ratio:2) and (min-resolution:0.001dpcm){.docs-emoji{font-size:1.25em;line-height:1;vertical-align:-.075em}}.spinner[data-v-79806448]{border-top-color:#444e66}.dark .spinner[data-v-79806448]{border-top-color:hsla(0,0%,100%,.6)}.docs-panel-content :last-child{margin-bottom:0!important}.docs-panels>*{border-radius:0;border-width:0 0 1px;margin-bottom:-1px}.sidebar{height:calc(100vh - 5rem)}@media (max-width:959px){.sidebar{height:100vh!important;transform:translateX(-100%)}}@media (max-width:1199px){.sidebar-right[data-v-bfb85f6e]{height:100vh!important}}.tab-content>:last-child{margin-bottom:0}.scheme-menu[data-v-0271b5b0]{display:flex;flex-direction:column}.scheme-menu-item[data-v-0271b5b0]{align-items:center;display:flex;width:100%}.scheme-menu-item[data-v-0271b5b0]>:not([hidden])~:not([hidden]){--tw-space-x-reverse:0;margin-left:calc(.5rem*(1 - var(--tw-space-x-reverse)));margin-right:calc(.5rem*var(--tw-space-x-reverse))}.scheme-menu-item[data-v-0271b5b0]{background-color:var(--scheme-menu-item-bg);color:var(--scheme-menu-item-text);padding:.5rem .75rem;text-align:left;transition-duration:.15s;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-timing-function:cubic-bezier(0,0,.2,1)}.scheme-menu-item[data-v-0271b5b0]:hover{background-color:var(--scheme-menu-item-bg-hover)}.scheme-menu-item-active[data-v-0271b5b0]{background-color:var(--scheme-menu-item-bg-active);color:var(--base-item-text-active);font-weight:500}.scheme-menu-item-text[data-v-0271b5b0]{font-size:.875rem}.member-links-dropdown a[data-v-b251436a]{border-radius:.25rem;color:#5694EF;display:block;font-size:.875rem;height:2rem;line-height:1;overflow:hidden;padding:.5625rem .75rem;text-overflow:ellipsis;white-space:nowrap}.member-links-dropdown a[data-v-b251436a]:hover{background-color:var(--gray-200)}.dark .member-links-dropdown a[data-v-b251436a]{color:#5694EF}.dark .member-links-dropdown a[data-v-b251436a]:hover{background-color:var(--dark-500)} diff --git a/resources/fonts/Inter-italic-latin-var.woff2 b/resources/fonts/Inter-italic-latin-var.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..e09a2014b3e19d2ed095b27fbf20a38943627729 GIT binary patch literal 56536 zcmagEV~j9Nur)ZgZQHhO+qP}nwr$(?%rmxaoBQ7Vk}ui&XDgkYPNlm}Qk`_C>y*2^ z7!v>>z<;*A4uJF@0D><$0R@l^hy*x613H2Z0E7TER0Nzr8|XF>;L^nM;%A$u z!VUJ0?u#L<2yF}21x`DxD1Hr@jU%LXLS-OU5swXSzl!|CFIdr1!D=Qq0fI=*-KU@!Z0YcN7IQMz@Q^TE+_WbWfpETn~Mx;<_MX@b*5R;jlnFKOqZ%E zk#gI;S3d4u?xE86f;&_9?e{W|&xdQ(Q^y?kH8ay2+1vNKw{#=hC1INs&K*^@tV`0m z;i&$**H`+HX$hwKh&{xXuM#!2FZVL1y`nItm>yUURosk-aJAF>^YpX*v(CqMHqS5u z62oxBFpw~mh^AtM>Sn~oKB8n38+kJ{X1$Ei;MI5$d{~i@zgx}=fdQIsn=w>xjT|Or zIn~K3hD~PTA;f{)Jv|&h_ z3_|Z2vu+#^<{1&z8zDk#j1Z+ULX7rU+(eeUIlJMjRa@Ll(;asllAR>wA=r@R2a;-9 zI_4PX+{bD14*2+kpg19MCCLN-Zob=2he@3wS2SFRv`xEp=T1o7*u=~;SN?Ogn91g_I1{Fz5Om+xk8G+Rfvi-uv;U zd-nS6Ter8@Ik$FqrISBxF{PBX5K=-?7=~pOq38JPU-zA&)P~B;=sh!b+_A$vEr)T` zRb!|lhM3rSh>BS65c(e}P_ojM`qfRU-dMSMu6oZD)^0--dkt-h0!#=Jm9+>lmZCdM zbyEnSauMRMVq}#Kld=kCLy1COF8bM}PENFQEB)MPXQ%nyyaPCnMA_ zuw(B5q5alj>i*n&lq$lT#vVO6I%REE8pl3@a83aTxZL6-PMZw~1VRA@AP|az00$J}KFKh1f7%>< zuIKQ~`yXX%?-VG2D65RO8X-EmAywU>5MegC%V=yQA|q3fnE&_Fx5kBUb0SgznIR~T zV5sQhN>kI^HGei2@u(tflnot$tv_yByZUx9y}t;ic@7-&D~ECX`cWEf<-78I1g{+@ z>1zjqDy9Qrk`#ihziNr8XqNafafHo>{mZ~Ep2VI^;*W5+i&qk45<;?pmN!_~1dd?{ zi1mhzl&+Q3`c)6b^U(mNM?~4fR^|rD8f7nJv=D_2yVsL53bfi0$z?iE{;%v#KJj#% z16yfDq?HJQpyWyc3TsCtHb^RNYQ>nP=oN}P`{*@Z9{)GkuwUa|n-AS|Tj%sC^xm4v zo;s%{nFK`MHo(+9SC2{;UuIaLLstLapSJej7fB@`6pr_R-DjK|y_ea`<6Momyb>s! zd!EPeneUx-R+0*Z5M~qrAhB2k0-?|V0I3KJ27^&#X`04jsjlr3+vc;acSfhXBdv7Z z4Cxd7xgaF9#y(vwZOUU&EkdDUVU#J);iMb)u$?du5S(pYKUqgf#5)A_5~(`sed;&t zbij$PWv<6%-c2{KEf35g#~_2v?T!dO2y#S0rdKSi0Iiy}p4)z9QynM*z-CqhrJ<0= zngbyMu-_lo-na7Hc_y%qz50QKaT+8NTZ~Ka$rQ8>;L$~(3AI8ib^wpaSF2apq_uF5 zM9!|8r2Zy(q-wH=Z3xsw35n0A(rn!yD?p>5)fj+jq^vE_O;PoQ#FS}1DOV{hVZL%P zHp;w(0EmDiSm1I%f(bCp5tzgr%V42w0y4!ErB%*R**hT2I03~b0b#A66fy*ytrQj~ zh0Wp^hFo_!0{l1v{kV(tLEqb#-rR?ScHZA#Y5lUg_arKBdYF+7hCm2#;~<@UT3=qr|of`AMGV2lANSa|+^BOlVUhfCo{ zZZ`L5WS@?v0li=>x zU=ad^8HO;3Ll6$hLKb+Om3e2OE5Fv-0tKZwUMBl}D64f!V0_NXFE?=eFY(e#T-Oj| z7=<7lE2jOf%TJ0UVrhu8iNPq-7OeN))Z-aj4H}#`>SbBzbO<28kqD077*3^H9E~5W zy?gCTN+Lr38xcMH{y+!kF#30fH0OR=MFJ@iT`*pGGc!J*ErA4xpovDy$n=UyGMZUd zWua*z^(re?&t+=TTQ;=Uw`d4^5DO2Fvi9bIG+bpR>c_xP`*9tWPV_2 zvkgIZUxax80RR9k*OP|ZIth-R-|+u(5KL+Q_N)Z88cJ%WS6v2If>Z!y<5p-==2!az zfR7=C&j0o<9!^D&Py^;4Q8)Ji!qNKxU5z0HKolAz$5#2JnG5(nP6k<)JpgpLAOQ@? zdv4<3UnJ}4WQG9<00bb2qXYqn2%&&zp~J*e09r+)nrG7zP~D|S$PXwmGZ4WT2w~o{ ziC|!^5+@e{UpNK&c9Qy4dqaa=Fq&q)#R!Gna;k&Lh&8%9-KJ!lwy6=`WH^efsnA(sTz54x_1 z!RkGt0n+UPrT}_`W;6#2wF*3LE$dY{i}>B~t4d6Mfs1?T>iVYYgme@J8`mT2v!8@O zwsb86p4?2rZ)gqquyF0m6I~TtUs+!7NVxr~dEm-ee8`h0b*m)B($y@P5FTYFV%BLS z`;DwixqTKIGySSD9=_UqLQwT8ZXYF)l%%E8vZ~8^c>m3~^t?bAWI0RjPP4c}HwY{m zt!YCs+y)^%st>$PYwTi_p&+2@yPlo80*KedlCm87CvSzQ?w0ORu9@;w&q zLa3~K^*XOi-~GfeuGu(Uj@@~I-|nb7ujSP+YzpE@ggf6OcK-|mSH^HUuf3tMM>+@I zGAEyYO&3;!;K%vZ%+$Xy$(e}MeN10HnN8o^aNp>(^trFo>*D&l6fbHNY5{XMu?xQI zIg0u0SsOGYzy18?WY~QYvN@w!quD(s?uxZA&zod+x7)?x;tz8DWIaO>lJBKPhA^>{ zafP4YIwtcS7W>@Vg9o2tUZgONVOH#`EXy`5+c?#>`0oYMtecRsu4$d~14rd9T83@s z*nZ7W4sGA{ybG?U+M?Mo4L#XEKVD3=e$&Etwsi06{Wajgk}qriIQ(&RadVud%qdKF znx2vJOZ6?)>7={49z^_G=tYjKs|M&KN!U~4<2JzJHsInm0OK|w<1TQ)rroO6lXy{! zQj~MIyFeu}o1~H}?ZG$gO6q~N6_O1wHg`N^>vW4xhhK3#Z*qHIWDzf-5RjbC&2yCC zS90y~+M~03EsT{iOI4kyLSe1qn#Cy)Tmxyv*p$IdqbnId9r)D2Ga6tQiG`d@svYqx zrK3=;6Dp-zQD+Cj16VH6j8;Q$wRD#ZKj7I2s2Nta|K{8B+xXn4upZyI64iwb6}IJ= zkDi@+Q#^_2gVF(@m zFK)>@UUjEr?E|3*k+MRS%H|X@*v%pnizcp1ZkNQVAiU=~@n%~bp09s1=OVdpA^u4t zPp|F;zd1syp@l55LL2u=W9(2_j9V)s%lcRm)7(2-;)3@V&@)>yHkVKDRm-xLn=U#!tdW{GAbGsU+M^xm?)o$M_D7&mm> zee)VNHrDoxFJA2)0$LH@Bh^{0eQVa?79TxQ_1wbRx5)~$&25C)?9J>;HpOb8MydR( z1gzCs<_N2T{GV@PDEoUig6P@@mQmAqw6oV=K}goV;m84`2-9M&=_O#V)(^+c6{?Ld zUnu-Xm0h$?B{+V#ZGj3Jv+BL`%BeioLbRUd5~aO8`BdvqhOTxZC}e%HrP=-j%KXvIZA* zGOa%9rJD6nAW`phP&j}zs$Fkm)koUi-;V&;r*ofZ*SKDZ$i)+jx>=)gW8SK9OkvpP zki{IrCM31;T5whgDBy#85F$;};2_{Nxu!J-b4;hJw)vo(k zwSbq@AG@-GH)gKg{(W(ss9o^X_Kl`^!~bah5XPc^;q#P!OH#1;wlCscn^JSg_sk>dffs22PK`kaQls2hD5KLAiV*8i&qL@&IQ|J$uGeoR#rT zL}KWY`iFb{K2C(|<%fOeMRpf`biw4%i7cVtIw<+(lf6Kt8%gsdW z80u>+ZR-KjmZbbK`OdUbvi@^p)(p6YafFgRs7uf|ZRV^dJ!TyjT&+LLq?v{E5X%&7 zoY)sqPpMUYoQ=Q-^S+srgCaadRy@)tN9hjYT1+b4f0?Q3`pgt|Dr*N*p?h)4oo&N$ zTAgat?40adn$jXSr3E8S%J(n3Id<^dXM8AgP*0W3nU?`jOaCkyTHi9c8Hu;^%+N|{ zFSYgJA<6{UZ(dQ-*-C~&U7t;8fN7Dc6t@K0i+KW`PYMmv#qFw#*~l}@HCn4Ko(E>g zlfkbdMtX|{r~`+Zi7=I!llNLu@gPa&%Y78@ayQM zguRrzt@pfcYM^OKy|yQ;?dh>jY)dIE9*6oXQd&=WZC7yPo_J)wywDFqyJ*DD{-ae( zx39=B9jV=-O@*H#^U&Z%@L%2OAS*vgPxwLuY*$?;bvV8o%^7;Y1$MhYvE^1(0!tX!S~Hf@zt$m-WlLX#kAsH0n|lg?G_e zE)msd%}%kq_hG&+Np<9PaYb;Lujw5{i55c6W~@{KeLWm;5yRu>-NJgZBcPk<<_iel zTk5LE0lFEn?F0#FPY?bTU}qdyei|Ox-YQ#d{MOAB7iZ)0o)Qgjy&cvV<$JG7nH-LE zozv@y%or7dO;<~AOB#Kd_t6Mvxcpui4&c_CS1hxvooSiAK92bpy#FQykqQ_^W{WNn za+#y{RZd!H1ZJZ70a-;}n(&1`UZHvN9R2hW(v9N^nT!pTc!*n}?p;XQ{71NZ{;Rl zXG_@eAtIveHn$U{Ol4H5B@f1)XiDRneS%aQJEbGRvWP;yZpA%fjBj%BVu$`6Qf+b6 zRpvMRQw6IVr#U07hy$I2$|yWBwChB#ad~Sw-cKV#UwkAUJtFF(7^{{HVD@;)=Tim}y)*S#uR)C1PgDm99iaLQwtO!n410j6WFW_07HT!7c6polG}4 zKVfQkC*?Oz)V7z^+PM1rIcRbdKkp*?$lV4a0#v`4!}s#}p5u*1#CJVN$~)Cg7iDhS z1+OUKDN{P))>!iX^Vt-r0^gXZQ|Vn{EMvodF-ovCE#Eru9Fe&l=9iaG8=Z9znk(4{ zxGS%2YX;-pL4N45X#t`Ok4`o<9LX}=P5OKBolbT-xO!Jv8)6TQ=S9IqU~#=Qtf=Z5 zRaLoXzd)U{?1A)LH~3|=w8+ABzdqonrw+CBSipMn+nU^W0i7YE&7Al0O57wlVf&pt zhac72f-5Zzc1$s$9MHlj=mNnS8T?Sh9@N?;mBLprwBWO=sG_eMEkVR<-y9If=M0%p z{u}nO$E80%GHYJjSnTYTuj@%|w2KYYC7jp&B+|K(}Glb ztrKzmslyf)eC<<*K0iw1&iq-v&EpDODtdl(nw4k?14JC<#}0q++@dFX1KhJi%8)x&SSsHp!#_ zQ!|M)a!%QFhFO;Lni6(W8=(UC?xy*optw}7Q^H)A(xqJGcvIHrWjqW63NuZgR2X(3 z>~xO;rtB)FF-@8{n_YK3ua+3KWQ&JLua)Os$`2~2l$Q4ab=kwp5}L|3j=Im;>HQLqF1W84zY27BgHvf%NCRfVrQXX zMP&$!La8ifB3nibWlk(CZWANuj~n7>QHTW*Un`OJ1eWe{ftsobEN*BSAyhP<6eVh@ zn^DT@CPj1d}aVu%_uX$1e6ms44o{NrcUE4FV}UW~-HT3N|`vJFOKieya`F zqm+8e!fS;j=t5i1afS6nL~3MeYX!}Y#*s-+*GHgB5e4-V(hO1JIav?`Rxd!^cLrCkfj z2$kF2^WGqH##H|lpnHJYiNFq(pq9k zg|jp?o7fvS#x;sqOl>aD6#cZ5aNf!t8bdtl7eqg9yo8QBA7=Kh@kKhxv#8*8<#M6) zYhUMP>BJrD>BkaRF2ftw9|sCoXb8CAg+W5ppH)h;01RH5TPBLcwsl-exrKq$5l6{@ zQtq;jC}y*!qq&HP!0(vk06HxysY@8AI4e;xNh73qgi##JDI$Z+pDAWB!-lGzxP^s? zy`s2>30TCdDf(=`EpHTqxIL|?Xvz`;(V_8gwcEE;{4tj2Z=d*L&@^N*dk9rXf+ z_r%XC_3sKtLag`B4ij;TI7F+_kVR}H91oTwRd+bzu10+q4dnOth?rlg?p8w__NvRw z?V#g(${2X4cwWjf73JR#Y2EG7L+*N7_hq2@y|(Umq1 z=cE5l=wzv9Ro_zEj=av}ZJ&2HXHacL;l!_W`+~oY9c3axN{6=f9JD)Y_vi_rK&V49 z`ZH~>j4!ftx(IeWCbfNa7pc~NEPaO|DGl#XGq0$br3_fsqe-`zT2qJ<$FeSrYozNs zwl3s(TxOo>d0eEf{l=w8+A`Osz*I_>!<6A1gkakLiF}TPT-m)}8cZCf zZ7KD|wHgryB`3-7p2k8xmoZH;NqA+hjIpe69O2Y1UVE8NVQxP~nB$c+j4pjhIVS?L3Ey1t$b{(H=}2Bn8WeOoiZNJ8)GbKlyRIa_<%J%S5C@WQZ@5U zshB(RX+m_fH%iKx1zI1c?DIM%vnF@j1hdS1YC0Ql%&5%BHg$Gp)rl@_y1+iUxmpS9 z63MU#bJ@vNx)wyr3i}M-F0-=krKmt#;GedodA1v}wa$9W#C8@-9nw;pJjJKJI`YZN z{fo(OF7b+3y^dLcbk6thm|SH{OMctWBe$TP)8cp3yGR^vQ8TyCVDY!UfzW>I{dX$Q zyIG{`GUuC&ZnNc`a`X73jF$F>YkcKva9MQoLT+h0_qTHf<;Js023wOaaT47=KbN-_ zt!|;NZ$7S>l8Ka57?+uf^dbfBJ6{ZEH z8>}tcdOcRBjMd`lARQbnBILC7aSO2c>FRw$Rcq z0Y&_e-Amg7{|TA+;ZD|Rmvj2(&4yW5v)6 zgDP$-q<&j{7CEsF1i&s#DRX1CT;j?DUzza$_53WkVzhX4P~>(g1=T>?D*_U}+;2BR zi$^J@=gdY*TFgr>Y3vWkH@pZf9_giiy05qfc$<7;%s=%rPMj8x@Ll`#NvfIqZ1e$t zfC^vXXi#~IE>@kQc7~NY#vku9t{4p-Mce3(Qflk){NV^crVq4YGSZn z7Jna-Yl~dqSnT$nOuBV1EB4!uQld(I1XPhdx@$Lg?3dYyRfF%oHx*KI|>I3I_{=m5^Vq+qM@ zKL9%o5qDs-p-m=DfdG;bv&Dxk2Go2P}0Z-i0|JGp#@hhv*j zA8JO^HHND2nGF~r!R-3c7`pr#@}?b+A8_a&3K z63q}!$|nivMW!Y?ZIMxj1%bwj?{2oB9QQ%dbgbd-SC0PdLE+itMETYb{l1UrLyrK5 z8(j|(Fr{s{NMUPYwxQnAXm#vxr(kxyr6&s{c<3DJ%V=Q@>F|TgPlk7k>Ks$!>wd^G z1|?{+?iD9GaB3KCHuQ=W=H|ymW${zA~(^Pbx7tpl${io=3 z9d!CF2d-a-*t^Vb#)t}Q_jc-bM)4aqYFW`nb`sf`W>zR>CE6?3X;ZJNZqIdYa~R@F zYJMT~P2}P(*`#NP^jP&eo*zpeWTuWSOea%^7;y07oOo|XDcLEh#+oPW!nkf@tS5P% zXW}75w5(Fhdf)MSp7jY=07HwMlV>J%6viD!^jxKa6c7pkV}W5PgeF1}STEo}24ON#3=5I9fCvyr zfijywRSnf*Vo@>(L}JZyne?EOJe_D1%2aiNQ8I|3Lbf~*ksw#IZK|Nq>`L&NrKXhf ze9%fRq7@7!p`x2DT6JZz?B&e1b)Bq&H3sL~qFkcWxbI5*5rflq8mgr@t`IKe^x+~Z z!9k!VQJj`-dwb99Op5sg+A(aFI7?_!9y3otV357e$agHOA{GSXn zFgI_it++d(aB=?UB$1T*KgVRMTtBRM?l8xBCXtjv@?RyCnYr4wc0?{ti2VPv*QO4= zX6k<}T++a{GPpbSLGk+H6)$8D`@iH_O&8wmoK%~Vdqf{hJ>%sHQ@8r?EKs&M7Lh?sx;C~!x-bRhv@&(7wk%Fb>J|6Fw zs0GHx>iVCME#^&{XgYzs&sS_;IBJXjNY~2C!p7pvEQBm9wxycfPsch*@@8~3KF+f` z%xfv9!T3g%4%}{We$67&DcO#}RI}+LEcgt`V_w_Jv z-YBy#OZ>{bcnn6A6*tg^eWmzq<_PAlrO!?mD}kgZ8!@tfgj0C-zDoft+!N zt%I!YPdZD5z1F>i=}RjY?gq%mZ45~9a>s&3t}@4N+Ov-;lRXr7W&siDK@Mfvw`L)E z2&TLkeardV`QGHyR3~VAoTu8 z?cw-lxgjArm6G$F=&;X{s2J$e1`&zV%e+meV(NdjX6SFh>5oKqtsXE84_iL~En=i& zBI3y)5YOJQ+(<_omAd_yW+xuRaA4E<+qYn%!o`JuI@Hb{FclB8K>}gb8FO8-7!SRR zFk;1NWN*dbY92B8;*Y}v@<;j3r^VD-qEmKeG?Rj4CR4*7wmz0*yaT?q3HOW~hO)SIJ{TKA9 z{An%d+FXuh(>e1NEK`p&jf}6GY%e~lM+KuLbTy=tU0z3uXYv_1F%n!^M~WNiE&D)7 zXNXpu*26j$aSgHLO$HVZjzBbZXmg6cIM1oyi-0??gf=|R= z1-P;L&uIn=7f9%6wi%`CiO@<{W5*yk7WQSBz)IKFB{3UmDs?M7zyZyEB%ybtn_7pdc?-w(bgZ?m;>W=&?_Ni zeMl-clD}y83a2%iGhQ}{?&H04l}h9JhfD!ryCW-KUrRhRQI9LK^5*F$P z0lt>A8$=%SXjd5uUm^Ek^r05L+0&|VZ40uZPC$5zRg6HAy1hb#2s+>_wHmKvnbm8h z;KE$$>ykM0tyqDT!I(6ltNqiZnYFXkX7 zhN4LV6`<&w%ih++R+=#v=ylNJZo<+DZ5ySRbg-OOK8Z1i0l=$ju#2z)M8#H{k1BW* zV5h(nuq~X6k%4c&74yVzXTYobpZh&%Y?OTdEd0b};)v@1H z)ECs511@K{dCy>WSMl807IM59M{MP!&p3eh4fl0N;E$f}9%>xl!gLK2jE#Sn`8 zga2J&2HO1WxgCk3{BrlEax6w3Bja3cp4Ny{O(ZdAlrcx#(ZP_rON3yzBT5lMu*NY% z-gfUs%X^Tg4dWf#39nwiSOa^e$V7$BMb5kS^OkTXdGoaYroZh$Tf43JJ%{$}Ma2_Q zx?61X)p;9#0g-&BF$7B9Kkqs1_6Kn3V_VzKKz;(g3HWvJsM=@sQih-ZpTiXo1}l6ev-nL*h=?3}_(kumOn9-Wb_8SV>r#ry+u#WK*@Vj^O5 z`^`50fS#^%k-s%=mrq(k<{XXObAXAet{;0O~wS{ehxhFb(`6B zSieC$R#|%9->2#y1VkN0KD_}^<%-$$rDlq0ac?j2+|?1=sp@uLZR;nxDcysWWbOysFUJa$IB3(&A8czd66?k zOA4T?V<(NAINuWbhj5$N*yf)wYq6&{%k+xO-1uS?p`m(Fl5T8kb@4_Ib**nou~)&f zbN>^1-O=1<;^ixqSIzgckQ^JujE6efH@lzAb|JU1lWAz}o0tp?DBM9ZLaMzZL31Uh4k$UC$ z2u}7T)M5MUWd60@lXo9$N{zA$h-+)V!v7U_u!nBH(;0Ynzi&*=c*Pyf|Kxm`Z$8umFzQfUR*35xBJvUY+UEBF*}U<2QCm0s_TpGbOk@te1}A{ zQ*4e~UI)+-2YA1?$7Ez?_lpQ{e|V>3LPz_(kABPlm3AU71dwS5q#J1AadwWRo6uObbvLXXb+qxp>jq9=|EbsfmJm5ea!?MY7bdqhAbz#PN6xK}WQWt#s zG3@%ZQ?rYYqb@9kw^KKjqbHhTx0x(^-Juh<)MuC4!?o#IOuV-_b;iJy^pmY+>+h@w zr>xcliCWfXAV?_^q2YL0K|N?=T=L^QoJ06>N1mBAy`qI(>#{1Uo{MsB-#{2P#oPeQ zFhPG~aVqrecbP+0cA zcH-(;#f~bXl%{HP!xz=H0ey16;3)tkG*%!99IFlqC7mYcQi96G3F&g0V68G5uMMon zgks9QEXZXYYs5{9dOci{RYl3%?W$(w@@X(w*z>Lmta;n>#%l3yR-005svs>h3@)k~ z^w6uuR()_94)*wX42<5s!2WM{o*AnkW?7eF$+^5q>}5EE;dy9uY+RdUPuo{ZJAg zV0`^y$8=S&k6U|WFY%B+)@Fa1$ydxr=@$z*p>YD<=tF_8uwlBdC3#QFV7ma`rVGe{ zzCGue1AMM?@p<1&Pj=dRtG?s?+LCw1j^MtZDHrSoJg79*f~u>4 z7<$Cmcl^Z;qFk|cjIzO)(ShCunC$leG)L)v!yw4tQz9_mFdAgApR5L%tHIfsK z;n;rig*hhH4!9O;9F`U7Pi%0eSltZ`0N>+$=PSzZUe+E(?M4ddgInDdnD6&~jdk~a zKg`cvoJx`>fqQS8N0YnHS420ln{)G`+#?Fh{442AD)+v%fM?<4iLSSy^Px&Q7r5t6 zI}r?00engx2HjUIKp^}HDeNE@pTo49xpwFV2pw`HmkYSt-Kclk2^C2l(ZXf-11V{3 z`(}pA6SZsNg%x9DlbQArzw=_`Y9M!ln1_4}4-b4u`OGnG{#^w(bG-@>xF^*Ql#0?Y zEJS;f&A64gs0iLiMoXrObJBZ_0E&08wh<0R?l>v?l3N=}H(6 zw*Z3Cp9oRXs%yjgvkXG4&dd+#q2esSu*=Ang$#FDrfo287Fqp6Qd{j>TfIi0e+jwdm0&S^m(385iBG&fifbIeb6enDc<&eu9=E5R)2`86j z^S#Ni{U|4E<6A}Ld8!CiN}%coi-U+?q62?@Q<4b}0WLzs1w{nZthRYG$b*R$zH3z& zYa}M`lT2?judJ$91w#mN9bRyPW8B!S)lHD#*=$oTyQrk{$nB%xdtq18(DtA;1(~3N z$YT*bw-*OQ_hi%*odS_)RMo1SBG9I2VuI2>5P)*9X_wkF@NG}cD4gbDHKG{+mZ}v? z*7+X6-8p8hes$DR{(0w>+4FDFgmZs6!JjL>4}nH%$M2FYj(;{79nhF6)B6)SB?P$aNj{{I`?>tglq0?SVr69d$us?B`Fun6 zbtle5!YbwmAFW9yTClI$ZT~y+0J_!ibw?bQLo`3B5MVJCES$v9w@0gnczieD4Pgl=*TOQ=#EwdaHAsXF_5IfG;$IZ$LJN;2Wdcoeom|U!cPrZU z!)K`cHkxylfnFrczINw?&kAHy7w@pN1<(&k&S?v>8td59c2^I_qsHsDttWX<&!Buj z?z3zSK;RyQ5kDfLLKrLU8d@cwG{Vz%vEN>!Q{xf{%5Z+h zRoH0DADRY#f>L~zNOJrsOfU;mm@EkpQa3CL>@*C{9%{B{AfHp4!*nKlzE`$q_R7|L z?rEcTz!bUD=mL@2NEK-X-z1yj&cERx&bbeH-qYR-%AK7c0>TBBfY)^^f-Hg+9*Jp> zy|cD+z{y<@tnU{TNu0qb zUGh>?9pY)#{YCZhIrcLQG`a0ybB%k{UT`T}1FOv?4qp~(*(vy=h@%Q(0o?HLeS>_4 z1??{}xFSgA{4Pt!0PZ+#@b3=suB^)@dTYQJjDDdShAc@a5xjR2o{n{kH$RiwqaZ^ z|3Dehyp8ppC#L{t;^?%3P4%h)Yue3SmG03EUu1*s;L*v((?3wiLy9LalX0!s;Oj=A zmu`u!)m_H3oJ*fM-(qHkT&s=%86!(v{Y(`zhtwEt8;OXq}$x{IcC9drltpf z0u`UP3=u&dXP}4W#l({pLf0h9B`2A7q-;$6(iqpOw5}|<`OSy~%K##4V#`r43Il}V zs`Xf`*RJW4uqZW>@ZNJrs2v74odUF}b>q{!5nA@%Dl}XcccsObClzy}CQP)jbiYfb z+;;9wFtltG>G}5s0EKFVkOFxG>w_? zA!M)S*V34@7nQ?w-^Fhd`ZAZMYG^*QF&=I)Xtj1eFDohN8vOda+!ofL?#7-Dj;I$z zB^z5<+5mfB(Z^(9wE4w#S9Rk+a@++^LhHcq@IL@{qn1zikK~5eYAe0wA&}pSX~~^o zDY0|;=6NK#A~^YlYp~$H*DM|E_no|FYY5zbWtr{ed-GY#m4wyOHCwCQ3}LfYamzOZ z{Xp#=0P`f7+K02RLfw2ThK47KiB@O zz4F!I1kd@pF;$|`N21sfn>`+>ul_-NxG#|KTgw=WMTlZ>WIO~rIK0eAG|pX+zl5p| zVWa9Z2Qdrrdg|b5s(QR*rX13AI$9V`lE6XI8H#jo#JP))fqs-HPQ^C&iN$(z7}?y(@)q@I5p{0$2P~>nN=|hcSnZR zMEMhtuysxBDO3*k7UfS47vz}I6);NX2KX_pBwxH|EQ@*1Aoh<~7bMXchD2iaKwXOV ztEqNY!#aXi44vJ0ROkl2JBP5QY-vU{mjF90yOq=SSkSX9Ry}U*&4xL2f6G+2>7MNVw09r)iCOxi4+-xq~nec}7 zg$`HFHrP+bth8f;0c^kq&9pSEQ83wyvAvjq)$=~AIDcW?LgH6bb5=I{WS<+g`LWd+ zShU5P*w)3CiduyZF+uTTi_)x|b6p2l_a=4i^z@%8iwSKzb|5_5l7=^98p;u1hRE;d zPqUGT*fr|$3>r2l=FH%lexLkM7p;|FJHM5aypqC>lwSc zY&1S^y4)zjWNGfxEY`!d!Nltv&6v4naYO)gH-STHY~Ul7uHb@7Cy_t_u%ZQ!Y+7PD z>J*`lN2dmI<^pB7?c?rB;Mw{*)lMFDr>s$6)@n`lq`@$9p?&u233efY((r!NbG>Iv z<&O2h*k?x??GW#5-YQM$&!;>g!9Pd_HU)*vKeO zKQCfUq#c@)7**nmLJFJJa6fOzQ+7dhDM=zS9o>!cuwYAa>`6v^7;bWX{6v=`%~PZk zZMdDFe5BMaOfByv)qViFgCF$;+VmlT>Tu-!sUJO3dLvgK6_w{_k6!;FpXrlce3w6w z(j4DE>+ML8Yi38KkV>1xmY`?QO~VJj3*l8Uh`uwFy_T&lw|nSnav3!~EGpy2U@ZTI zsO1w47eg9(24&piQ?;5tPzN>ZxBEp^{CL(0z+!5VUWSCs#f1f7W0*&-uN8uQ2BPip5Vb9zBss&Qn0sT<95A%TF?SrgdOUwJ z4&LjW)XqrLwFrQ%j~J1`Fv;nyOWFDXq(3{KjKsgqzeooa*r0C7*vQyK ze`)4_m_MwGbKToOT&4`)cb)$&hVY5-F*Zi_!93ePZZWoZXdvvU`VI9_5y4~l!yaDz zwp*OU6{0dwT+7*;375xEGFrfDj)&ONwW896h)rEHS3SP@C~f_1RPG4J=9t5{wSO=q zY#!@gXQo|iy45EJfBoy?Q;sRI@sLC#sl;yt!H#=9&#p`sKl3YTf}fH1v`R^E%QXy{ zH*-OcJGbX}-@{a3d!9nWF79p|FT3y`ycftObL!_QndN(ow#!HkG9oB+K0JLE8Ev^h4fdGTkw6fX#X&XZWpA;6rzw)90TF(cR<)niEifB#& zz|AQXaiS>%XiPU1#=r4t!=vA-R_z8Ro$BTU^PKEHc9tCl+Tqcfmvb~ye|0%u*qEsiMVkrw+> zdF5N@t6re8F#_z6=bkXDoY8(VH&&OrZfll&|0*QZeRidXN0hS40t&ZycCwysI8;Ss z7s3``vl@3$M!Lj1oc;O?%>f8%fQXePeA74r|wOzv4tmVcI+NlD4A*9xkW_aJDQ|kJ z$iWV)-|_hEURWKoF=xjf*O{t;ofE*#TaSM|fFhviw1(n04zKwo_(fy6tVN{`lhlk< zbP}?t6|k6t+rFh2@YGd)hHG3it!zSRRAa`#4EcD&eE{&WjN8>|Fh& zFy}0SGU3Z>gp;1eJ@F6Q6p2w=*+yQ~7i>Sa$M(OGii(Ek4T61@7L|6huY>1-y0BH2 zKfWuArTK^^r|p%Fw?4`82e^B3#Fbq+iCOiVtqVOV_saTd_ zCz9NiS6lVUrOKSnU+!Y+ykX*PMs6oEN={;_w3yFjWwwE8&pAR@d+3S8JHfdf zh}9ACmF)Yc)eXz=bi3%XWgaXH<{KZy(-528Gwyq++M&dsSk_Ft{vNpmncFdgWVU5h z_J}VqK1tCS>?GAMR*S}+zo@n;<&DiNCUw64?LJ6{-}|aIF!N2bU})fLPRfpQx9ZJ} z-y4ifW)**y!9P{)zVn|}<&Bqk@$2rbSxmk1#nGQ`jNvzV5nYk&ZdlNvii`6-7yr10 zsfOSC3hD~S;ErRv{>0T>oIuK!yq&)tp8W(nfQ+UIfD}i{=4s^a-`7p=( z3RHVr=4<>#0nHPzkay2gQCyel!B`$|IaV+ox01fb5w_&%X`gfRa^`b&(&Qn03WQ68 z=pwMEF9P3Gq6Gwjv;f8woWKvMU<{!lYWx=>S&M2))@DyQfwvG*tFk7k6=)OzndJ3k z1ZSTbA)xeCIwER+exSIJW0_|so+s9osALE~iT~AG1Nx4J~OXH$3++6$t&1V_> z-ezB{!Y`4&)4I}x?=M5#ZuP8Iiv=ZbFlDGbgZ-`jZPntsl0PvON&@2#eYMNXmqb~K zI4&RaQC1>!SB>nJVq#C0;xLESsfWT2=vzFPy{~#6bo<}C$BVqBINN=r%-3!_8gQF# zZXucwV3bT*rmB!c>Y^0Af)uo|NTmB6N;>%i(E&5;Xu1j!^DZPqfxjK_o&|Vu_ZmXA z?Ivt>57)>@gu}7}*8h{i)|iC@12X_>WUp{JT!nQSFUv zm(#+Ihc|tr?hDpW5lx8r^`8B2eFx*g4)zu5o8OaD?x$S;d=mBJ<;z2VF&>+_nz{e^ zIO_Xt@o#n`_T{>=CaI&s+84HC=>VhTYj*+pVC87*ivE??b=CdHj1IhUqegSDOYN??diU=(Ho(-V_HDkqWGFvPUQx!~#ST6GpL`y$yKswSsmid4Rro2?Ak@$ zf(OAJXIPQ_Xug;Y(wW5n#wus8a_nqHS)2<%4@^^9Z=L792 z$%LQqdU3Ehht5xO}}vnNw=%W0F|{A7>dJ|NitHxLz8K1Mmm6Z_U& zL1iQ3DKn2!?{wqmSy6~^ym%Tr+R%XDORX_0x~-m~bFo942%pxUZ>r@segY10=$El8 zOhn9Hm9z7+uav8lN50p?Nk8`>zC;L+QWxqyA~<1t4<&oMi4aqwzfeE} z_93+9I|r~m>N8mBUwE!!rg?TAG8*chSjF++d-$dgL&;`UtVR=>z9>sgTiEB5cYf9J zC&e_SlGc^aDfP_{&-u=wk}%cdPfCO54VokK?*zb^l%DR0%#@w5m8lvT)$Z4ti~0W- zS2lc5|B#Yk8wd0$08u#m7A7?dg&^D_q7S$L7k0R_r$-$iA29T!8Gyt0A?{md;BtU< zan^%QshH}^gJoXb#GERX)PM2)3!l_-J4fD^ zMtxCfLB@w(t1V@kFi&NlbL~`0GaIG$`6im)m;byvj%ubcarQ-rAjWc-ZzzDVHA6C- zr;D#9I2F;0Com<*cuGyVv#(btF{cVk`YqH>Rm69dCe_j3P}TGda#DnDDx7IHA|q_v zh4RPRslA;DV)sl$1i9Sq?-c`3!qC$hdYM~tD}G^v8uk839QEsj_j2!iyPWweC31{R zpf6Ec?H@Mq#w4m=qYK(q&jT7xn0Tl-J@JbgSP5rwGfVS64i$#xJ~9@Rtq{yHl&C-; z!*`&#eXS*`Jtnq?N_-w%;6JjhX-i9~B2(*-sl*DXyG<@PXw?Y&`rn#q+c3W31EmsH zRJA+yd>_=Eb4I~I=-gw0Lr0|^u1hDU=cOGE4>-@M z8Bbi6Bl7b#n|@6d!Ogd(9(;|TFqLjP{2!|g?M@xKNf8HpbFUf z;6c}4h`6Ql6;pPoD0%Zr?{at&G(z?w6-)_|M{(9<`J+&}b8cW{eyKnH=+>b^b;-Cb z;gDL`%uZ>g0eb%YvA=cxCzWo%ITt{JSZBZ}2s=(xSvGm2DaBGNy20i=!}ef%Pfpdl zrk@=>mnuRfqjC?w%s&ryF%+iuI|*r~2%+cri}}Kp^oI@CU#!DY~=Fb=^qmZ_=_S zx&F&&F6vy>%xdDf>|0p@Kcl#c=c;E{Ilu+qb}YZ_ODpBb5_wHC;N3Rih`|XAZc-#^ zBDfch7w=`P?>!?wsdqPW&2lXcZ0PPId~T&Ax=fzKe54Zg8_rb%CE*5sePs^OkI<5M zFkhrHve47MFI>NEESN1{6T;Ikj{lNeb>zQhW#)U|s>QlOl2KN4!a1 zqnrrw(ytC!WUBO(KbQ@QjBN1_4*B4F($w!97n$}H(^Dq8>l+za9}p7!fpOf_GlPTX z13yV`!cLarInBmVx6nNx3ooXrM62t0bkFAgTJg!olLTw3=Mf0szA1rrkVRihUg;(> zGzy$WNiIFY4@Dp)LSL_rDi4nW0+AOq-mpXL?OKdl#<1=wj%1}gUu5?>)O*~(s{Pn29>=GDL+1|kpKeUo zkE^kL?uETl;sK9Bjm6D^QmhrWU}m#3W0N;2;6413)6RqCI|s?JqXEP2^xPFLcO^Gh z3t?hzs?C|Fq&hmLQYb~-qNHc6B}|x zt~c4l(2AU!??nPQ?LJQL?pMnab{JyhI~pF>+WA0jC~b8uX&A{4=dxI}JPEj`;3eva&8@0-RCPn_?3`T1|(FFqN!y|4Bf z&5OEH7MNx4#HxY?q*vJMFt?8SI=jT;D-aB*b9ha45)~u)fzSVtvko3z51O5BUH?-RQ$Ds57`mFO?Z@_3eO%7X^p3Z&VP2ERPSIsl zyP5a7=>zvLb*gQl3pq5Nzi%@*D%`D|6}Y`uX;Qh^{{B6`a_r%KSofk|L|kC{*j?2Q zWW07qw4YaCX`H(6f=;*0L*O6+E4V3nl{3M)X0&rXImF$Qc_mcr{=`f79adHkCgch=c14l)h53Rw;H&NucNn*ciht8~=8 zUQSQ+N-(zzS%=_+YjPrlQeJKU3;GFLZvU8S8>TUOj!Vl4@NR*hQSFYn4i4Xsj*41? zIeM@7Nyr=c4uzj>?RlU+#Hm?};vm^!To$XD2cVKbAp&c1A|Oq=U~Ng$)^T<>F?6;L z@uyk>r3J7CCAq1#Jg#Y%N6TXe@)5Eg?$jxiXwA@pXmG@hWN7Go+TWjM2~-Q+2ohS$ z!#_}84CkTqYPD1KK{tDAf|7xDiFc-DsN=VU8<5wdce5g6@?szX@_GTIF`Syx3Du6| z;Wc(CjOoq}W~FAqeA)aZb_Fbe8t>;>d=?qa<}xHTmxuAjj)ZeaeZkriyXAKaJU^(k ztF*N2?C`5=XU}`=VrtUDFMfDmklpKF5*E-6XTc+mbcTm`dliKScDCQ`BV#nW!h!)O z7j}=gf)mP*_J`zKdlht)TD-%QVf(8-E$3$X#@kvkXCO=~Sz@tLhHV{qPY(t|W}ag5 zZT(g3=CS?NJ4+cU{p4}NHG%|g%I%p~ZGlJN+t~E(7QVdpVFw@vjP^k9+0NbU9?Hd2GCP!R@l8B~;is7%IT`(q} zcd+eMOf@ifY~-*BI|`}45q-A4{WU!q8Ntd9WHs}F+XB!efjy-pcp<|lA<7aOKv@#V zNZ={)9|-xMHP?S2w*Nd;D*&(k)*<9|paB6Z_*ni+{y$q18@&R8;AMrx`aj?f$HYTX z*|nFZepbhTPFi`A@=F<_9z@w(ORu#hD|aVNl>s?P;K>&V%>Z^-5>t^p1wms6fR4o5 z_s^)tx`+~8-+z02?cZhKjP)tB_0clnj`kLQJ!M-^Ao^YVC4MdDGtfu^1%FkJ`3rtE zW_?9ov;?3efN86pb4|4y^W;JC%`jRYJPPVcEo`sjvkbN% z;n-ntOt|;>^8%*rDU_BQ7MDJf45Pz*OG5?WnD)@r%N!^fMh{|gSl3uE`U;9&-TuTc z^ZZ0Gy&ZlA$!^KaMnj6Q^Bu?(WK2WLwhw?7Br&}w_|}#9j|>T0hz53`ecJ#FCCd_{ zm*hoDfI!^Kp9%`

5NBGV;O#xmPQYY$UrtkZPT8^k4=*zy;W03Y!Jl&suqB4n;&K1fWj)Z13=#Le^&{^{+!{q&(!W5hGeH@Io>oA%n2Rlxm#n9QMQ z>P=KKD!JFtFy)2c4Hw=5!&GlQk6MK8{L7##h|uK-a?rfV`@;pkO#B3x3>LhYe0k)gqX=fhyMB~0CcyOWcXB6PK^JvqIqAdS913em#$f&qBeT^g$v z8L@E_Zxrfx-2GP||`zaDLT&dP;u3pL3Oh4=k)L zIsyveVObT(1O?Ax!6Q!~BgA$I)+_N_{=yx}6-+N*sQVpG&fOP5Np_$Co-#}es8xtq zg3zJ^y;+@!$S`DdR&21vStE-nLW7kE)2ke01!)gjc@7LNVk(gF#RF?+z%V@Il5Kn; zVM+M{wyRqD_r~U{bGIQSO9#n8uC4{wpJ_~_8MxmFh)if^kUEi3$cVyAKQS`eW7>0I z45)iVQlwpmg(u5KiV+zG)Q^|j8+^H2Jj+pR)-zCP^GmthZ2 zTy$==)&-IPck&LWvoFyRWy_m-kjTqyO*}pMctyO=ipiE~(!sy?nJCkaMW>*7A3K*(Ey4MgP!c5s8zn)& z*gthM1v_a8R{6R%N-L|CnR9Wt#pr>S%&irrdaYv0Faj~MZgo4gx^^y=wn?j5eUq9r zpITCj&QvO7T0l*DdMN}U3h7r`a4k5bFXY*?cx7Gd@eu$7h@%1U7VKd9n;rD2(Bg-o z!izJQg?(lH`mAYOJo+ba@mJ4m>_QllZ8!>$ttuDn0$$LY+f= z-Q30F!OP`7LrvO`&WG`hSJl-kJ|K>dcvRzsl#biX$ZKMV^}4P#Av3b44x*2NU6+4V zz?0hCEbjg*kI9wa76^5tg64G_S|AegJWpq}aCKdSa&4H~Ho6z}8&Vn(RBK!IrOGwM-5su(>)BAJOu%cEum zBv1Plh&>}<&tn^abaz6$Jw0r^zo?Zn*f9tH@;hg6UmJe~$?Xh+o7nq*k%!oa28aaS zGv1@$8?2h2%^)6mqatx2=>QwZaAX8|(!b~*l=gS^jfGP3Y&`u9j9mhv6cXwmR~iDl-om8 zeh5Ed6AmE|LgC`sa7hR$At|JV55lLV0Eq<@YOnjLZ`n0*(_UBO2fP?(`<>|K#9_v% zKT<0>lV1JjDuf0PI)T&R5`rK9*Qk9=1v@*Sx6H-m7Qc}xh~g$0U$2b>UI#A>;il4E zZFPhvTloKS8!8AJF zI+EOc=TmNv@gu3-()c}MUrls$-*>Fv6m|oWedv?VbLe@~LV-##c!?WFCfLjw1XM&h z+R_KHw-h{q&-|Lp0`Kj+FAE3dKf>SsQ_`$P4^!Kzd%v>%^+fF z6g@0*1)Zk54+UZYZanets~sGt6bpK8qIn8F31yvh2BXxASO)h+1VvxCPCfe02oDsoE~Mj zjIu$Y+hfUYHJ`4RL9Khzpl*Ez5wXxeHYc6uF8yr`3G6Mgqvptdj+LtYR+l-ZYQI!( zW_M+$nj_h)RF(Qi>;S|GO2zfj@}TM{@7YmDtd4TSjyfT&@*q?yXUWPtN@glTRSAxq z|6ELvF|LQTPf50X+&#_Jfca)L+-~@nI?2SQPIAvqUe)ByaDod<#|^;n!?*=4pC3nG z8_Jt&nUI`*%sRip-+2=O;YHYzEe|lzzv1Qs@P@B@@ZP%XA6#_R#+&{MfbPF}HzDdG z2JZg>!L7LJiopDb^4eUrrJ`j$I>P3xX>Nd;>!2cLO}5?8uLBMYaN_T`!SH)&PTjgK zf3J5JT{4sZ%`P>B9HX0tecORy9>EAaYIB1@y93rXo?tk+6-u7?q{aiFWjr-k6I+ zRPC<-YZOOPO|bp1%{S!t^Sx{VP=kO0Zi|)_EfXFVX9yAD??uV#$w<27<)DZg!U9TJ z;oGv{l=rdr*h%plHi zOUuw?<#f<>>Pjm3f8<-qr2h&$GrcJ%A5PnmuPt^nZJ2GALgYelG%y$G1fh4w;@?elsmFbe<$ z1h5Q3JX>tlWR*EaYi>H*m3DXx{A^z-n?tKs3{cY5PIqx;s=4(G7=1t3?9mH5`a3MI zZhEOJ#q+7!V*YVIgiy4O-<2PCXxvJ(cIi{YSXD$Aj5O=wkV zfx+6`gxZDMYfM9o1;fwc1NH#ev4~(D)?66t-U+)pKQs%=7OE;6Xqq*z!)yM58nBUJ zd=d<2T{cPvn*4jLFS0TGZzq5SG&ezWVFa7_AZ$UXu=1+33=U`PP0qrx6LUIB!$~@&m{hEIP4XRqx42fF#BoZ_0}S zoi`n>=7Py>^_{n91{`>bsCkmZu&Hq#e(OJ2J4EHxSK?4u>uq55-zeNB0S{ef+xkUe z#Q|FZG?=ObfU$^bEYvrs0QDj~YXfs@Lk>1#qVQKr zAnml8XdWZAFnxs()cUS@Fch;vL&k~%D9yRfnjW`Wg~Sjj+@>Jh+j;xGLN`w2rY3|xRXIn3YoY(cvAi*LBvVB zM~@JphYYxHB87PMG~~27fW`8O(XKuX2H!)0NfNUaEqvkl~Yg9K!7bRMdU|W8P$Ydr-%WcrWD*|h`Iu3w>}G% zKcwz*5|m4I!6#&10x@KrOWY!?H_}%CICFm&y(y}6D+$Y(aRR)>E0d5u){3yDfKg5d zhn`qnY-!FYN3_?IQMRTg@vP#+7&$0EqH!W?SpFahF<|9qMwxc}ZTCu1@;_ClkYOo{ zjQp8oI3xc{q=W*`Txt;SQiSZEM*4@GFnl5l5PeP@Pm=YN(F%+}ZvawQ&lhA^(3g{t z{KA+8g#(Z1P+IzY@klQ!J&=saH;^C)BKazE$Z#$8b3)WbVFU~EI~h3&8P|Ys$iBLu z3>b@gmOVM;f;`C@cyUlJb)_Pb6jt(XW~|ku>5pMMK5WRVHL*ei&~tlKs%g`oB%$u8 zhC!A80N#rIR~yDwgd-@`HNtji_>Z7mlhnV3Q6%cES-1wk@$#CUAnK{plnV)Uhcz2$ z%16PL*mpHI`XU^{Np(Y-3lvV&Nr3Y+5db*faru__!r5hR^`zFo0Je@HfVF4i&busO z#=JZvSD2W)5W8X9ein&wT?&23TlFp>kV7d)qSvy`rTwP=K>s)N%D40gmCAL%J+MM! zL*k|Jxi$WI9wa$f_G&9~%xavU4%$N}G_a|cjf*zZ-h1h`Lq zEB;?^ZybiVuTFqnb!uH`u4sW%?GU~SL;%8oUpvPHfZrGZL`u;@cf(Az(9`T*b#W@E zVV;=Qcys0~%=$XDrq<57wpKTc1PJ=*fd(59F2yd*)r1b7&kPUbh^!wdtD+=-($D+* zc`<*9(haq=)JC0N**g`D+yS{0ayD{oCKa@O56(vB`p}J7lQL|`k^a%R9lBLr0A^Ss5F-I|R7%pZ7^8)i8^RKd+vX64U z@_pqe%5PM#Dq$*LRWq<^SONB-nw{EBbyam6_143>hri>`uPo+`{tcZJ9v5V!VDU~h;b=aAi!idx;&59xXHVG$)9q%tNQCa<@Bz# zULHUF_D)v~jm>7%DZP8XeCJpInr#J0h9(N4|og57}q3HxUIUmPSH zjyjMW&N!TNsBvg_7;qSO5IQV7h#j^azBud?p+pQ3Pc$G}5y?b4kx66|(};Xx1+j(L zOB^N65EqH-#4X}S;y)xA5{iT)>5|MyL=u%0M2aFMlX6L=qz2Lx(pN_d$BT{&PD)Oh zPW5CIIh|ZWZY1}TZ<6nk*T`Gs&y)ic1O-PqL9wDZQ+z2b3Wvg_2q-m_cFF){oFb$w zQ^b@X&I-=Qor9groSU3`oUb|Gc7EXe*!ef-_s)O0NVyzxA-I^iymH-eH*(G+M#G#}b|+7NAp_Q_Mn z^NeS?=aiR}7uD;mSB+PzSC7|-*M!%c*Y94Ry#A(3(B|2I9~}<$ z!45_~qPos-q>K^rI1FCEx+;0s#txXk2O=aSs!}9JAF9GfJKa7MlEPgG143Do9JCq|1vnkDxUmducmP){{YJsvxOFf@*+m#%a{!vBnJW ziFif%9BD=nll2OYO6HB$2vipjgBAW3mqQo|Q;>r+o!Nry5h#g+Y(Ueulp`?b*Sodb_*|~9llaSR4Zqm{F(@SIqhjd>)qyTJaij<)O}(l%Y8&T@Ch9!$oL~l z>-q+NxH&Ir=feXtx>nAOpJLm(^9Vr>*|}fMbo-AIfSK+NBfo}DHUb5{A(x;+FVOLf z%ASrq<;+(Yj_t6!z!pZpzry;v;~ZE9hiZ(GoJe-6J|P4|RY`1v8k{e3rRcRp4L1vP z?gqFTWaO=ZlfV$FkxXttLGRG*i~7?Kc?3JtiqR5$fKQLF`ga+W{^vmoG()2wA!unX zF8J%e>x32sC=gab9GE|4lsD;6ygu1XN>`{e+y^^qY*Pu(onJ7}HwVQZZm6Mkcq?Y+89ctCqo0eS1p+17|vXu_}dCXtnTiII-&xY#e4Htt69PW zAzSOQGDD9;l3Fs?u2#YK71JJ`a-fqTl7Fkj%!Asw>w)m1RpH0^4a-T>gkGmD^aWrS z5B|R66xT;*8qrLdsY|aPu~PR&l#--w`k)+Lny==%5-S%U9_&B{DS7tNp13MC8JJqj zZ#6&WONfgV4~9jt)|k!f+i1%v>Tm?@;BU>^&#~<5p{ObF1#*PsxOPmg$LDzl!As=T z?I;~dSPA04oVd0}JjOqMx;K1b{n5p!0SqD6!pdfI-$?$^9@YH%=_0{&seq7NpwJtu z{z1-n5YXP8qSqgv2GN&qoa1ZX`gq6DH3;fAuX*F`i2z#Nw>_}W5P&$>k~ycqs$4OT z+l_01Qo|8$B(Zcg-*t3+KwYzWtoD~{t&dfsf|Rg4*7Z`_ncte zE&Brsf#kA6^1iDuvzZQ|>y!tA*Rh#bf9yI*FqJFxPz{Uk+2i$*W)NMWTf;FVW50(U z`o)sqw6CK~+Ax1)-+)RYI*H6E2KLk(LCi~KaQbwA)3{%S7CIK>8o||46-v3$1q>lE zVx$bPw`WKV)rnnu8))iO!WmgX2F^xklasqzeprT9XnNCFQiJQ=v@PFdm3EPf&SQdA zE1V+w@I-n-?lz-?o1l29WJVGi8qmoRaTIk@>0!6t9TR}?h_xe~bAfh=P5>nC_g)A2 z)R#FfILJlPO+<5ynh@9l$q|_5%Ze|3awGOu*!J7b1Jjta{20Oj9Ji=yBy35gD zBtQdU7cZs>i7b~O)xij!lwy-CtP6X4BT8 zVl5QZO&Tkl#b*CT>O5GCN~FRoPU@a!>74M9g~D7LvrRx*cI5bdyJ6$0Ja(qFb^60D zM=>fW^r{U>P>Un*e9WkMi9nNYZzBTD$VaHSP>hsiMaK*+c`+W6wsqM*DuaWYw&SzN z&G#A7=lwBv!&Q&qTPtvq(0-)0qzz9hSJzA#nNgb?H6U(l@sq=IVR{Uz1eDf@T@n>HD(7S2ad@zB-TCx5FCm0}s77arTkwq~> z069=BPyObbols*N307lGV=%CXPjJ-d0ivtva)n2%rX<+!Z2gSPx8B%}HW@XUcsK6$A}juNZ@Hm=3<@P5qbt-Tuh zD}HrwfGt1I5tGA6lagZobE?va*dGrG5X#_-FMji&hwS-f`k+8V9fC%MDlRTS=3H z3ib~^{H{_*y?vXAKLQl`Tmxa%Nl~B_EIvY$pY_&Up%M%o1`Kcua5D$Kk6$i8bE_A# zV)sEoV6@FJI&Hlc>R^ze?BSf6Dx_+*vmG3>IWPUhTiC1fn0?nE>~a&&m41Z=R9*l% z5qe_>SeX9~ud-@dy*^2MHI^GG&MF+<7lDwzsPvq%&-$H$kY`Hto?N^dftYRMcWI`6 zzGpG-Ly<*8O!*X!HoEJ&pJu85W>?j!#&Hdp&yp*-fTj z#v%qWAS94iijE2kusk=GO>vJ|mOp&8yqrY<;#ki;Z9uqj&?@yHA5JfL8R}eJz{WLi zXJjXF(t6I z_^p@W#PqsirWtYK{F_B_i3>B_IPWiG6+wZi0sg)9= zW7pa`q-Y3dN_ROt_J?Y&SPC1UB^PE47$KuBdR}CGg2D(0Si{49H5RJXTG-x%Bw$^u z@rH#|P;G*ZU9v$-RYSQet0eU64t~XefdFykn=CosP_u7Y$b&qEhO~nqf7j1AOmIz7 zA30)bBaIRAjHg;;P#DS1Ie~CP;A&FhwoWc0%w`W6g|r08&hZEU>B}Ld;&>f)(K7_K zhsgdbGe$R2Kn6@iK)Ha1l(9#PL>TysacFL6G{y~u!k%T5O`NqhXy*E5b6lzJ5Oz^p z_I(A8k$k!RqadJsC?pGX0C@U=2|*^W5#rd(AnYK7jKP%StwLar;Uev{NkE{6xc-Vz zM|2s0a>)4<^e;4V^TE_~yTER|Mrav2aNyQwvK!HPu^l_jGt*hxfSBsgxuRRl0{=7S+TrSKtXk8H<*X-o1E>H$sC7Z z*FBAeP=~iH*VS@odv(%zO{6FK+gnvBhH;b3StC>H)f6`v>!g#a zS*|`wAxSky#FtQtqA`sw$iVq48||);NpOwa)?P1YJ5l0ZK7%t zL;oN{MLC-W>bt5YUXz#Z7fZYptY4EY?VwO+hsQdt=SY5)G%I1>VJNiL2$b&6j!i|XkKRtwK<}NT(l1sJEVycvxZmaa7Yl0P#8NtA+%*e% zfinN+EMPz4A|ma?@T;SI!d^SrrL)&xcs)6Hdy>`<^TYG?WPKKe%CS?L`dq9cf$(FX zWwcF2FYqRaUml5-+V!t7si)3^hVlKFBJIKd@SB_nK1$~03E8@r1M0-Zt5;_&%|B!Q z#FePn#ZAMOqZ=WA<@_$iYu-y==qtdKGojPe`Ji3X_v%gZ)(Hu5cprS!c#Ilj)TQ7v zzg%&p?(E(zbeT1iq$Ej-PIBsyElb^ZQ1Q{OG|=5oXMX}#P`(N zRYiA%M`8g6Ym4$>d7s8v%efmP*U!FRt|oCwdf{eNz}3Za8IL~@Op+V45%ox7nh7|m4 zcrkVGjUsXyocSb_Cn?w?6@&~dDnXMN)J1FjftKTk#gc^zJdcs(me%<74UE1QE@-i_ zTRmFu^tJp*(3$bk-~%TYoexdtfta`he6&dBf`3dkS#A?bmXi3~yv^^~N? zdNN1!?qIm=p|Ue$ZyJVARS4phXeS>JgS%-EcsgVN!r{>Tyyb`;JdWz2V3t7o zRS&A*K=-y9H9Zs^Vwfo-vw}IlL$1R$f7NPN@n%3|sDw2w&Azz7QB1m^J8=XU_$ocb zX^s`gz&?~f>uNS;@uUvQS8etG);Ep)0qYQWNr1==Y%aQheP7iIro6k?BzD6v<9_3$t8mdF@->-_H8)V}{d4qA4 zy!_0iRUjv~y;!N`(r1iY_%^u5U;3VYI?90x^vvWS^9ZMj1B(wA2tXbF3~a!>n!Rp) zOa+PpGDyjo>1PV1mp)UNByU(O55rIG=hh--*J_wQGQIeS@Zkj(EUqW>3y|tCwAr}v z%q!I}Qq54hd}lO%ue{-9ofh)uN$e(F#{o2M{`No{_5&Tu2dp-W}svQ4kpsopqp3dJH>` z2NW9Cix^wa71I9tZA!H6qSQy7uBFO082o$zZQw6N^_q!v_>AUZB;u&APNrbd__Ns4dvHJU+04o z%j#mHDJhG41m$1~_w)iv2sa@T;uQBSdkbVeCja;VQE=Sb)Mz>fYQT_bDoNZLg-Y#B zQ!Co65?GCaV-nPbSmKtP#LcM53+$CzU;OfRx3_hklyyHahyXlv1b4In6he{T62g}s z3r04hnKYe6VSkuD6U$2@^<5Qudk0g`0H3SzuAF5QxSlsuWeLq>$14Ga@a175HFZC+ z3FM!LarmnYK*BVsUeFkenWKgy0TYFN;ROy;Xf^n13Db*Z4pCMB_5Gr; zAznM6bS@zJ5^7`}7GwW%P8dbg81Yqzk!>D)qG?;e%og0J!V5}Y=K&*KJxRGb4Zw}; zo}0)v0L!R@1y>iG0*rx2PTWoUV>{Us0rAg2OMNPFuG{i(hb*4>l;Rs1(2`sOlgPk~ z`S7p`3;OEK^Wz{rDk~roM!$ zAaJbF>3V4TIX@JOUZaQ*3+fREcC@Y@U5(x8KAVmBWYCFT`C#wuT@Osr%-qreiG-Ng zy305ER`EdzMfYJ4NNnwGsTnPm@vGAS!ZEf1XmMS?NZ~akStU=SyOwQF_?XXs#KQc3h$rP!|Z|`2CD$Nx{GgR6P3e;tQhh3pQkq0Q8+qQYeNXW03i`*}W<7 zbIRe8;eB=qR6M4DfeEo{(W8IYnY=JE%s+~pq;R^1pUZ+Ax&mGH;S%&lzi5C`$*5P} zZK-M#Uf3`J3XUNV5v(5^?D@_LMDNar8K24viNk3xG$6~GAo8uIyOh?mJfnnGsUv__ zknTyl5{EvM{#6|cK`f*YVO{b{Sd0}CT_^5}UYP&(6G;O0cCljVl1d_IvX z`|5Qlan@veufOPh{4RtQMS2LSy@tu1N&*u}@G&}^*1f~()M72aq)uk;(+1EH7xP;D zUQ_MIOnWqxQB%aj)8GW6*RU|#OdJjZXePbC)*ctR?4cfSk|3AL*<&^ZaKjEn89|MR zh87rA%)tryB;N}f^-?S(F^g7ox!N!xQ!n|H6W+>B3BIGM1S$?}Zn>3>+&D1oGsiHq zUUv)EdiTh5R>A9xO@$=T|KuVWU9X5H)P{Ho-=859s%1*m)RBqUQM> znid;}IeKo~TlzPSuLRa@yLn^zSMZZg5R$;6f&wx+kllVWJ48A2{kiG5liXC9j~O{T z?X7Zu|2|Di$%%%t?u6~^;`BBT=l5CHFy&8>uuH-q;gAty3(xW(isHIlH4bgMcRqCO z-#I$0CAcew>AY!c$6P2voSYa8wkK*t4OjF=xtk`N)}zEL@*(E0hX7&i$SC6#ch3jN zhd!(Sf}|HbfHfh5Q}8d)u~ss5xfpC0gabkb4zH?4Q`cOM9~VkLmh0I~xc#kICO-CJ z;$`-Jsc~vw3l3tKh}#?Re_ir1&)EybKn-EEm2qV6w6lf!)@JWh`Ul zoxQ1`*fJTkc62m@CP|7t{1KVQ7&t+`#uLy8TF8k0^c0e}vMvE)=i#*tJKS)ZbI7QW zXakSUJBUPl$7knlLtC=4QRPK9VooL_i0;otn_0-uf@ePQs3Xdfu=5E_vcnJY(>%@v zZQniZ{6r3DXGrRY}40++6p z-TWNr1Wdy2$$eXI5x!QO4@K7^kGm%`jNn9-j)gPMh}T(C{@Cj7ZQ0b*d1GtR9h|{_ z(5i`~9u!+f|0dkUl0RD@ibWBv;iC-lET3Z~Ht~320ggN3T^SYzW5#AgompDgDK_q| z&=6(4Pq+xK3h*}zcC>`zVgyY{%}n^;!X4lp!8%5vly1-l1{6$!?d zsY_>FbN(pjnj*qn%XHp*ptfWX5_*+nT~iTLtZt6)|Ih6!XCTsR9{vCsA6Btu6Oii2 zjdDCM+03exm>F&8T7EyUzkU2iTf0!g+ENRO!YaW@#(hsouZQ@Nfz#=9eO5ps$6vV3m7RYCc2GipmmqDak0>`q2S!iG zs0aJ*H=(y$AB6hrqKQT~4*CRJdMoO}OHA!Oes%@RRh+|}+p;2t=~h0G6acfjqMZOA zD$veruq!Hr19h^Gtn!$Y3(e*8_|Sr|;y$81d*wHhP$l$`NQ;_w$l+5YD0C1%aC$j(nK{t)wS6W?gU&LC0#Gy#)fd_6NeDQW!g zDbI3vyk68Xr^YHd25wCT*uhNp}OQ zbhK7$!%3kE=yut${@CT|E-8-x0@q(3Smr@60-IH>VjWe3!C z%1~&)4x22FJ^`gRVh_xj+{CuzEzekfW2Lw>kYYQM*)%NL2W`nAsgV>$&gqD;*1FI> zZ{j0C3%G;v)9@G$T^mT*xPKIT@?7$LSJ6Q~KZ8dDmq-rDJ4@IB-7ZJWIgXCQCDDJl zE?|o&8j{Nn?7_^t z$$Vy+=#$C$B&nND@#UQY-|1v)C6N=nVFKmTHyMgXMJEI;vN&ELO#|u)#8E!v&487D zG_a;VeHj`aFQ81Gqpo5rm$<5F*micFpnhqCbKyR^0qLKIN)3+V#~Ez4$J&Ze`ySoT zXzrbDx0H*m%Em_>XittvC=fkE{t%PQ%?8ea!drcj^pYc*`0^lPKO zmH?i>i5EzlMa(*et~<`q3&qf`O*3{q$m46fNJB?*V15?su(j7lUM&N5%saum-SnmD|O?t| zQWnpV3{%1|BaAY_C*VPC&m>nkwh?b|EXp9anfp}Nbb!5Ef)(F?va6wRHaE)?q}`4> zzF6ux3Lrw0>T0tTEN7%XN`Div&=Ipp5Mk%@t-*=-7G7SK+)@#p?D&{WsPtAaC>P<#8LQmE$O{{t5ony1=FPcGAibjg*r>6va5^zn z>_hpB6aQQ6zIY$SVF(!lwzSn`*V+O6FTTc6zQivB@$h12Z+STGnO+R@34$Q`{%~;- zV?wV8kig#rr3}@xXiw_^UctUpiJ=SE0tB;zH_#DZb5a?Fm~{-FC?*cU8FiOdtfZ4l zZgRI;7=Dj8<0(06We?NM4aMmZ^HF2W;^Z8#Gf*-c5B}}6#1t^gP`&pq2~Oxb4y|@$ z?`0U=g2?GGYF|XT{V^!pQB6Bsg{Q#qO~;09*=hflip?k^NtznS15cj_CdBx*Xq0gP zk}XXZt5Azgi}fN?!)q3Vb8@r!4N0{W0R*c2RVOv92}xR&6_NzucI^MYvOY@-8`2GeAXt_?W|Z8AKe@@j3iSYNrv;Bl+x!; zoxvzyMJW3BbA$S}Z~+_ms>!E!U)jRC3VK*EIOjz<-Fa5c(^WD^@7mVPPJ?0x{p0o- z;3TB_*-FKKHnG_FHk-30KuPL9E-NjUEsaeHd3+xg%|91*Qluf2o94rH55+VM>xnC+ z4`D?ldBFEm$l4}C4fMgmu`Sk-WM5xxnrVm;<|}F+QjF%@bw=)D#Ilxl?R?m{YN1KqrTC83$wR3)&L|ps`=NDmSr*G$T40(6tex|pXrVys? zzG>tUN<0lDn#*a0kG%sDc`u)Hrfol(f!yhU&tMrk%pdLK&=?TOhPKMzD~`AKTzV7E zT);rux|Y@w>Bm{q1JYSR*)o=oIy&>7^t^?WxB!&3ebrOkrn)$nj zXbgpX3$Moz4)lXeoYR+tOfNzq}hH-d*&_}h$$zIg}s(R||r|6Dl#ViPDM<}x8 zC5Q=kG}Ja$G1B7r6X+K_Tj^seR}B^jIE0Bqp9CcY+NCIfxAE`PCBMj2>!{i$i(zDr zr?`ed#mI2K_rOw={*h68Jnh4|qCU&cRf6bS86K>AnVBxGw|>jJ-5G)I_S8g}VWnI! zldITR75Ipf)pE2>H{(oUr`sscYKizJ$c3AK^@Ui#@nV}}m*DKve?0DI7VYaM+#hTj z5A#$-tohO#-`0ESHcbzPvT$?jPd7SmR|g$n?f<8j+i*=(FL=sUcx1@KKfHmMyZ_af z9?KoDEULH{+ei*)f*c=hht~w1rKk7sO%?0zlf(tN2d(`an7TY1)aiUa-QwJi@8PY8hy**G z?~Y9cfDTLZlT2`zA$)m&y%%=wnn~BxB+KS4T;dE>8J_KsM80z-zqCg;hlz{fI=x@X zd*Kc88TYCWNks&k59M!KdlXC%<+m@_JRp08L?xRtkvhJAGCcMLMKM)H+nKrn13*s8VL4?mW-Quw_O~a91tKXV)y`|?khYId5LE8`1ymdxf zjN6vsnE*pKlDsq8=S?e{!)y0D4h7{9s;?agT_$Souf~KFG+W(m9rS#O#k_tK?o{n$ zw9{g%xMw3n<2iiiV;CV+rSf zV(2{#Y=hxyI*fKUitQIWGgd4kNr_F6UBJxRhWJNmSZQFfLA&I0!^0zU3Z5<^O)nf8 z!8)s2pJh6`3;a%QJ4+Nvq!j^`e0?S?tOo>IdXoTSU;t@u<<@2i3y;%BjqHt%u09`X81NQE?8`LK6s4Omm=`!oxoAN27JR4=`XNcS{B1&iQ)a<9aSo{;r`n zb#8MvSo=#HqL}SDbH@V2Yod?x7Z@}r5odLRU9;ly;?AW*+l(W4<$K+@1oZYf3>J@f~VYrBf*6Bwu`c!HrFMs_7Ke*Y5ulF{< zN)a1=i+1?l5tYp@@jU-DqU5q-DyPWsy|znZ9v7Dt#iu*Yp4l11i%X?sP&`{59I>s2awx@vT_d*u96pJD8a za^NvOex0A1A5QR21_0XqR8R;BWYsHkr0(8*NCl<)95!c8V8>I94FLmgqokbgZ=ks&3p)wy z0JF3~I+oiAiJSbH2?xqfIfE1f17_X->D!jk6B4*o5I{LdMjaqXTB+ zypx@Z`f5$IryT`#P&bLzc?DaWGv}FsDf=3^0f)9_^F~yBXDzeW!ge-#7(Gb0rYAv9 zHb~mQ1pV()OjjBd^i2y-nV}h1#Bu3~Z7q%((1rVF=)}>5#Cq+ZeRKn80QY z`WSrpNxqDw)^<7%UVp$a`s&3Y+2$xqXBpJeE_5nkE2ht; z9Ra+tlT!VR;XQ-5h{c?qq_e3|jY_MsGdpg@#2U1GK>d~PJ0F<`tT$gYm%|$+C0&s- zcF$_d5fa`c5%b9oMNuOtti25#zJR3d*qfgfHAaZrV=Z<5N9sy zwz6tyv(dawRRg5GA2Or%jmC6FAr*5Yt()qF!}@2h;J}iVb}K+o({*c)$jh#ao^pyO zaK`xR^&Y8syIB)UoNJj+qpYVx&^7c5XkiL=ZxU1TK3%8wCF)M^<-VamL~9Qxruz(| zr)RH;{gr_lnQ$|6s^c+>*fr~?Sp42+UIIZdjBo+hNpqw{xM`GLbXNBxAk_Mpk@k!{ zg`}prp@rgL-4%byaPVM|!IFQ5nly35iO>d`yM`o*6!VTRI0(pkY}wk=23E~Fr$5R< zeBm>e1o|Qb>$U!J^)A=Mfg8CuT<0#kb6 zBp&KOyC}AtBWKL0_e=*v*DTfuBoS)zw|G8EuT3G({$N3je&P1Dw_>bQ%J;TznJ~h* zSV>%dlYNC}v3NaNOo%2YTZ@}@KvrLl5Pdx32>s`cg*Z5vq?bs)(@)Nxa*D4AeXJtN z0^(>6SsEalO3+^bMm@L9p44T-!IM+Y%z5Y@q#9b#D)tBusB>LR<1MYPz)+1*`1mkZ z8HZzyn;Y@#ElLo3_tfEDdhCjhlX7H`+>Q^XXFZzk?N^u@0g)44Ip;G-@DJX1rbaS# zpA12wE)8KuCr{vw4xz(P2MNc~V6p44a<{n1b_inwCrt>Unpk%0(S>9LtuCEx21c}O zc&cp88GC(JId3N`h(Gch#|1?T=@3Ei6wM0{qdbQitzklq)PK6jJQDq}{xV9OKKqqC!&FOpZQw{)X3w0hZ~p?TdS+?>%o8l8&KK+c^5!gVSlF ze{fK1JR7$ky4*V9F^}kfx^o`!GC@#mI@$ck(}@|;u{ASuTWNe_nx}~RmO3aX|5tz6me79{-&9ce2@W={4H znVOk-X4_F{^S`P>F&3Ywj09@BmTe)%g7~+VN7hX2`pDeS71&c^2@iR5@M`n$#y*lM z9Bx5$m)auXmkN>?%qoP>7dS@{{189O_A#fK812K2q&OtbQpPy5eZ3wiZhvKZy;!rRs)MWikY*K?hw4_9*uF+#hte^$(-~&_~fh*WXn!4AAkLTdP*K#EHN5bbHtd4nZ z{nGNVozr8_R+gQ%7x0pJlBX&5Xx(&{rEG6LRwrvl$zG>V=>s2<)p97YlrF*RBiUsk z@?apn9xmMn0)qv5r^D=I%6(yZhs&_-b{G)Qw}i4X#|hs&?aw>c6!!?2dWBNI-`jNm zaY;(eY=}W-NRq!*#}ec1$P$J8U#YJE%#77l*A|g{xtYwMu?1qPGX4%tQh)hh-Y$-L zwf6dc>L?)p*id9?g~$!oKAuXOWjbKS;#(%PaTyb@RhihStB93;Z_4`IHiVYVBgx@Or&Uh|cz zQ~Jb>8kxIseXnh_#nHJQzw`{P@4-CQ*>0)bK30Rq_@T?@{fD=V6n`Z_#G#svS9Y3f zpMMg)^2;2A8k9;9zO@Zh#T!sJ+5ZhX8G?^qxUEVTRJl5>IJ@k{3FW>ggHgDxQ`XdC zkY6e6@qPcn^pRawqxLQOu>&=c z<_w9HN7OxYG6+~;ob3?c+bDb2YJA>)Al{7i4uBUiT;M@vU8lgvA%eM(y7~AA8g?0E zu4r@n!@tImpb^*)PCr^^Lou{agNEdM%vR|9^;G`bsrP2Jy@0)O((;KLW19#qvQ<*w z`Ta`vxq~0$V#d=|jGWpv{*SxYN28@rxM{s#<0gU_&rCj{ZR(q_%8@>sxwfb`{-F2M z-TS_Ju2W_0@UU=syHq-{qj^HNmK?j+v3!`xw&Z|w1Igrqc`O0ti#W8kRf2So0SYCnK zZOH}*&;c^D*KBj8{{WJ*H=^184a$@X5;Q15`PdFOIG~EIBvF3?VF}-px$~2{5CX%;Zio%Fk(f#MaAkPdm$2jj<+a;vP%Mb0N zNSO*MN>@osrFY&SXK^BHxf1*Xy;`rz&^X?pibigv`V8jfAA;-|o-nTZ2i z{6G<@g!*^qMgpNpB=19p9rLVG<%!us6*OI&8zYzW;|o$MW@lGj%gd~5LT`MoxJhti zhXl&jFae&&mbXJsEAs7?+XgIG!jycVdOLXhfFCG~Zp18K)C0K!Eb@aHZVl`u>}^b*INqo*E;J>?*SX1JnuO-(I|gshq)#JWxLfQHk0%8+z)w zx|PxPsaGVVY$EyM=EFvdbeVmcXaR#$1Qq%+=TvOiROvTZa<4^10~M$?Gxc;F;M0k& zp^{DH;)B0Jjrs(v6}UL6vs1u?KwvxB@Iue9?f7>_GbkW~>`H_P_!I~jCQMO`;+NMN zH}FvalSM+fY|+N325Pd1)3y~lnI*&sU>3J#7)$mY6@|!1TI&ZC-6Oq5fy@Qd6&Ymr zP)MwkK@v&SDu^4DU4(F5;6l)2>B&&iP#58DJKC1;?6_ri-s|GC)y(a!Waz9QfEW=V zK0|K^@jmZJun?`VuI$D>0R+C7fVttFoj2w}Z!=lF@iVh+GJ?{r^ndR(^5`6!crpdw z!__qrq|NUeG@&srb6kxIVlpV94V;P30#zI&UYMX++1me+9h9pF;)~ z>_0>^>4xfX`#STM#OPG+e6sF{nVRx_cH&q~?;FA(>&H=##%|fY?CTvBESKrDDA6+x zC<*pEW&ujg5|a)j-?|IE|L#eYU8HKvupxIO2aF2fBBZeezd+-p0Et2d)S*EWSYBNJ zv7hv^FsQ)u11J%D){ZX+w={c7zz?|y`-_`V6q^6n1Z^ztd3G9caZ)2qnherGXax;) znaFcg;yg7j-sKwRG{QxM*q5lat~FR!qUk~vbe=fBP=yT{WFfRJZ4%YV)Ey%=vTq5Y zLQS$`ni=W&HWlba60yJM@*lkvU}u-pi866f6Qaur)sL6!{WWh#{XF6#YEa&7jZHj* zo^oPJX^K@>qJFT(=LeB7ZR6G@J4U-n^;N$a?L#%6=JSOJDw`|LAhMVKbr$uaf7Q1I zY!iYFZcKrS{n_gTs0uddMgO9`F}nuMe)TE6ZG(9O8=YZmUd%S`A&C{{9}Hc2J10?| zq!vFq4|s6IQy;e7A>cdX$^Yh+<~L0!Hn+w26D$|Lofk^7_a{boGbd#%Bh760hmkwe zeB@bSPR3Q7SIV(t(}I|%s{z)biXLt$6;=l~=$*QlEM4u(`+bTmEqvC-V)wFigdvz= zP3&`p%o;W%0?P2fXXsiH%h#73ptFk-PejI&oFJiMnJZOAq^GkXarLkfH@AzcdiZyV z?!$}&*G`YuTzXg8nDd>S%SCK#I61f+j%6Eepuo&)6+rp8@Xz)UbL|-c^AKf~9{rs& zD~rjpVZ6UG8k{kid;?cq0KLca)u5!!%#QgcO26w_XHG&AnUAP-AzL=YaE428D;UV& z;lq)0*WvV@gYrYFhA>6`=WGFCKB2eE!KfOssj?W5A{N~S>|%*oB6jH+r3o%}nl&;- z{5AyZySDB~n_Mp7W;(#>5A|(Sp(MXGSI}a^J~~2fzHI;3h5(Wn5SqFb>l6zJ~Sz?nWH*pf$(DQGtUrH#c7 z3s>ISUf`%&jPor`sI>YP!a$3vf~;9p_pE3;Pos08GmU{kQ*M>k*z=aDgbeLcR9tg^ z|Bn*VgAu8jv|&K6?M3rZIAV7R`7oKZIQ&SFutM9??)yq&w2KYe3yY==zmp42XDUQr z@3OeN7QvTc-%X%~r^aAHnurcj#*vu=k590{$xH=+-?yat3X5P;k37zB#jwvTI3Db= zBu{rmQ0bzal1L$`v?026PmqiS?+L+tYfo>VapHaZ&Z~I>z4ia1VW8-Icpd!f0t3l# zx&9>I4HWJ7dG;z7>UHdQ;(}j=rcyiR-7vW>s-Fg6END?`>An{fpsa7jccmo~iZnA0 zVQ5KtV9xn^;R7IKe8;_bVr_?r6mo^Dv%DXuDawm;q>UGX`@a$xw7dm!ahp<@#&3OE z2^PDK#-etR&9hRSxmM${G@c1uCYrv5wV^=jc~4G9%`IEGBu%!`d!bhJDboIvf`Y4F zlkaDCS8u()MyV=9TEwU0O^7<70st1LFxcxwxCZ(PNH5;a zYr30a;ro*i?QrhiN_7x>uc(U zsW8Xpo`QIwQw1+wQzLQu)xYS>$0!mQtXIuNZ+eO?TYWl4ED#ce?*F8UaMRAbVyr$P zBdOlnY*N>3(9Sx=n+$Fj&h=MocS(}R ze0dDu=tr~}%zqMik_YnHBx!>(0lqGrJAhX6ZgBSyvl>4ve{{gjk z(o!}ae((z=L0LfVCU$(C4a^0^?$`>&b}=vV&pH3z8E|@t*PabfNeurNmj`JROYxkY zkh2MIz15*I)RgB4!kTbWn{u4zUC$4gmN$D0gVHW@*bCLnr0+O(_gnosmL7A!b}YjK zMvfJ$TfmT#gM$-^`WsIp`7N@YB7v-Xf5t)g>>FgG5&B?Cc49(g;)`@oLUlQ`u+JVd z=Vxko3Qf&%NMAh4@typgqp=OWDY}%pZR5U3X;!+MnBBW4Ph7|7*Zb;CLjE=5chuR| zYf|05oN?3RIi^mN*4msgV2ikB2L_)k5;HE^5`RWZlmPNH+IKo}$g!wJZAp2L2`lSa zI=k{VyxXbvUIt9YBdlMLn(%ne*W^65yL}nfx%;vR^SgDcp6fJ#ihWfCrSMh7MakMUSXm-Rd>LxT`!f`N?^X3{erIVgwgOfKNiLaA&D>#4DrP{J3Me zQxlH6#xiTx=BI%PXd$xNj+53UM_}o;D2iiQpx#9(qW+WLQ?*{t^b>eCGU}N0jsajg zLXHI<`fr$cYFpq|T+;A3fdh%dX~w5^5AX?kFz1|qLuS{I0B~SPl69%Es7jeTpNl(Q zJSw)Ok*6XmGY}Y4&*^+eHJhBEgVJsaXc?l>{loqpwz8?Y#wW*QYrP*aUK(Zbw&(U$ zy=KA>b@r%92BuI>h3jxi$!q0yO)Jl)$K9P)m!Ead1q9P^)Dlp=-RWj#JHxi;gMb`W zSIF-Q%&m#9@}eEO9{bim+vV2t-}(4V^A5lyVT}vA=&N|!v(i4v#n$TUU4xkzA2pNq zh7cl!F?A19?on65N0sGQcU}@eO-!y-g(Dx@ zxm)_&YQi66wD{yo$x-+YPAEIGcUfz`rIy?8vg?l8VZAE>RIE>Y7WGZ9IODH+=? zmn}UcSp!W27#BNengH%MoC78N!g$_*gD>6?e<>sJAwFV~Jx9J~IVwXdmYT#WPp2rR z+qUd7%Z5^%_8XR_vZGL}_?9>0z$f?}5WHkjgR84>B=K-+`BiiMIVX{~i+AjZpaeMk zEJJ_)%X^8m)QI(r`d%il)0rKT0aTm=k?GkcF{7)`0zjWNZ(#RWyG)vtu@_d(JX#K!% z%EvZ)FCX$H@M3~~!IMH5k@mC7O;!Pm@3H+UKWC7{Dc^GmGaU3+p3jemzztWmtIRTiHIhln5m8dt%d^URF|h6j;~F8{lK{ZUT@fq31Qmjd%(-{= zl6|*oDoyxES${~D45^|k7TtQFt&4XBrhcZTA>vN`wx=%b7s z2(%%kx4pyNcaRgVtFob6R(@6#@eNZ0C0XRUXDP#tX0Q-a_u5?miw7R=V;`Sj8GqcO zSvO;R16g~(v=KPTh82Hw8^L1pSeMqG&Srsc!Bx`o-yEcgV8?8BL&tDDODNE+#>C~2 zZ&cH;>{zCgIeO`NW=Clnb+qE?gUo=I)gqbV=&O6`OB%yqIZe9{rlK2D*)ut|WwjK! zaM%)f=>)iTj)CBF;?EOzW`+96CQg1CaSU9`WK=;AWhG74c`TqhW$moDM7}^H8yIDu zTi}iAz>s(tg8Dtnm&Nbw(7vck8uA0rAQcL_* z`z3M>9aa_Pu-w@y%e$Etb$a}ApkJjs{U6{u*YifbnJM?`g`;>w&%)1a>UzeLBK&Jc z%7gFogCA*qSAiL*-(7cJ{ukO=_ZYz6e7c9;<*X`Y)jUOyddBR{QBNy1S)mz*pK~=+(iB{P3@8-H7QFioY2gmaFNd;SgtHJ@sTW6 z5!#CM!^^4+eDVaU7x>5xTB&hxt*Bi??lz;|AX&j-8VhV~+Ov*3JLgYM2g+RtJsGob z_^s3OazR#MVVYh{zeFva5rTW|~4i^IC)Rag!?cgW}kAP%JnqmjM=e{BT}QRa2n;r85Fu z?UW>G?xfZ+uUt}$HDgvu!Xk8^vs_TqAXSz_=u|GZhfg~zZ`AjRI+bI^$YcDnC zA#Z&T+^{YiU705x-=Z9ET9RTy5Qn01DLxM&V$ZBTl&y`fARL!t@WnQ2ZDH#!{gK*> zW^L6FLkpV1MVB7);=3$oV#K_^wkD5V(PR*lCt%%jlFSSOiUF|na74?+2s-PyBb2su zY5UMJlzY3irpGH>aumtdYwv>nCxGGX)Q5& z@Pxl!Md~2P%=OtOEODFT@!$ENAH9Xgp*Q2bQY65>QytmBpqm)h;lSt2C*u= z-Dey>m^Yy}_B#`~q%FS~&JD|P*=6B;&@W2@1f|h)Y9voKINpnhvF{11GpgiNM_-V zsDfLhjqEnj$y2U}oyIDU>x&O>vP_O``&SYhApw+!QNGf0Ak>Gw818a1Q>LQMF^0?z z6IORqbX`5$)JPvJav~=k0Yo*Wm8A1Nm!iutz#?MYS*MHk z{fRR?uPhLMKn8#h{mo_s&F%!n=jc(NE(N|6MwDIY-SM=``1Pbv2HzW=+!J(=dGiG- z=ux{vu3HmktFlB!Q24=4Wqqw|%QzNs+P;MA3H`yjq_9>O{K72OE}|=%^lek@oy#JR zhCFH*ZD=fOouze253oAfQX|AcN3x(LIK40|I0M9BkgbkH0h?se&@Wg7&K#0KVi9hF z}Q8V1eGoqLw0LIz z#oUtYd-0rvP*M#a>*F(;1QlIfRRniEz0Zf^$P525+D--Lk@kXg7%xw;m)yrQ9dq`j zY@|(z-s5vzu$KhjNx|CYJe7b3DXl6GiRk?J|;}neDMkqgUjIIp4m4`_5;)RfNmQbYVy))sCC23{u2++RRI*H& zgDgAo%(BJanR{yDrv|)&CExDxZH8cUptG>Djb?2v25u(-ebH^l&YjGlyH-X{EwEL3 zsGK$J0Xf;quot!J`R;&KZ)I8BSBAPA-%b*vk|b0mRCEPF=#QGTiT<_6+Zg+(X`0<6 z)(#z4?E$a~wsJ76%!YBF6bCYsN4wiO-_M57Rkf5J*?~fXKuNas~%h7d7lV(I-lW5gxjIpJgZ3~ zBqsAkN@vI_SOlrRX-00mKmq*C`uUD%!6)ocl8lJOd5i3Wx2)R_+iNgl#Jz`2bFkNn zZpRrPlEt;^F&HzSCDgyuXQyP*!rGl6&Bm$1Qj_Ya5Oe%B~nG=LZ zZ?aVyMdHaNN#IgS0*jv?Vfn7KkCG@>k>>ikd9i&WuTuv^H724(Cn@i?_B4^IJMDY-x%BG|xR<7*X_0c57F6)Br)eQ z-b5TxEr0`0RQORdicL*a78^thOANJxX``D;xb?jFy`%szU|`EMA_!Y;a4?KB(M7*d zm88Sl2%>tg)*xxYe^ZAT`#o}4)2s{>^NpsxCCNa$?}yd$pPtIcY;C5!<(W`dhn$=O zIr(x?+sv3CD={K*R-`iRDL~K+$gJRuH;k{Sg?mHQisBP@4ld`@oGbEoHBy_Zd?wtrjmep(9`R?nS`Ub-cMlAHv2NHn9Egp}mQ^U-_8&={W&!6i6 zrl>s6^(W;J@6j~ks%)+ASlNNt&4mV>|1e_Y)*?%GI+lbeU(}9swkMjVtX#BxdL0OW`Oz$_$JLK6Epe)Yjt-DY{k-*CZ5~LCslPc zf)uv+$s5ZCRg3}-4VM5UF$zt6P6X$bOYcVVmwDx?7#c)sW-&}cG=iCD;OH7_AN*=t zbCp_MYiRp*2R0lBDI2~}i6BdsNCe)Y*>DhF=#t>!rNfWp zQ8Q>%RMz*)lTvysfCk$VnVbpqsI;^1@QeeU1X4C-k)ARtR`@UPv!1q`A}83_g=2Ci z{k`pSdXyzvxB{*5)r}zuM6h;5WN~vSJV}7PCGM78=e0<`Z1#b|3b>fWm8*dFgZFh@N_Q;Njj3|N+1}C zYdyDcvf*aZOXgIyW*#LAPCZN0jYM|#mQ}Z_Bsn*@fn+2^-90E5`hE9VfUx z0&<)!_l3!V`QelpQWW8lgd$E&!qEk-jOUle6?k4?GVwIl4iZrb9Vj=|_Iz1d9Cs7G zim}4Tua#RNUUBUl^5GdgwTdf$qv8xb)^&O{Z%4trEmedia}9;v<(Zi-a}QSo0l6DS z{>Oono`Ssk)lppS0sXT-I3B8 zzrvxE!2i^4A*G+=Kpyc8z64r^{+PL8H~Rs<4*NM)2)5IpwrgoA21-QJ&U$BXwfHw2 zDdUjLq&q{=futgiWMpMtq&_qGNEHD()RvleF;he;3QDY0fdC$1fltJK#z6;wX+f{F zGGP71o7)r0QURQ(wL|YQm1t*o7#77Uz2Tq~J86mm?LMz*|Ik_LyzfM^HCC{t+gmz- zYoyUBx~GPjuza_ELX(pciP{VZ$!#Nshi!$sE?F$Jw4U%r+^t5j73E|C2`P@~-#0;RnVj9ylH$`onQalp9U*4^m zg-Z}q*i(q26s9{=RqfS&d)pPo@R^WV?-}wF{?>pxx@B`KFEA}Y`sn*Zx>Fz}7s(T? zZG�&`QQn!SYC^+?W8*JEoV#0*+R_E(SaW42okb3QrJO?D_@{t%%~%41{xwQY@Z= z3$tu+yDd~aCdO8pz`pjgkAlFueApVP!}I3p{?~w|r)sogkP(!Ilzpg9?n#&Mv!P#Dml4FF2*{?CXuP4hQR0p#+YKE97YaJiRo{I(&`G2%lA)qoXE~f{EJAlBIT{5P2|q6RIqUP;Zl2AZ=X!@?(&>t2Mcn%eNqxhu2k?6I~uA1|8d91uT(jryvJ zu@TFKP3ssnOj(p@kjkpBbvo9RgK?A*hy9+RyDOR2^81rkygJ7#P4T00eF&2&WOjHk zdZp^RV`NYx*p5+wKC<_>y$`g>(Xyr5OU0TWh~kb*R^3im8zmpz{QGxLM;pU*nL3=) ztbD5qX*VaOkfSQ5$kY=FHZ=OBgcHo30c)6^(9 zZ9kH|wx`B~KG_wVw*B|5=LT_g-lIBFR^I$k3>9pCAYLVu>6B6rJy8+lv%rd21u5PZ z@sC}1qFxNA5q*obCHEs&*x-sv-A&E!*%q+m=#;ms+agy(17!|0(v{O2-u$XNeQW(a zS5A6{pWUwe{>PQ%wmhD5JnQ|plI2GLIo#~Q!z=z#HtmOsN-FSQy2Q%T1|3eQKWt>mseRl*vHS9>x?-Sib*u|0q2R4Iz=M)7;w;>`B z=YY{oZ$f{W)b_cvN}TqI#U5I4xUJ1_Hgd~X;#LI3@y(wo6^U1P*-{|YY^vD(ZTXW|by@JsDA)5=|fg{?af}TD+rV&*Dm>EaoCF`-q@Bym)IvSfOK1!+A~MBWov%a=}JlO!gZv9ox5@DOgXo#Wdu?|8ca zCen~4mFxa|;tEkV5r>S&cFd+{MfC6O5Vl4Cd_U=H&>gOhii&q2e1*+XM=)JSRGEoS zN{_wvy0j|dxT2=OHwxJ#AF$eYj)P<8qF2BzGBW58vRGw!B?j=vJv&H>Y9iGlUZ2uZ_deg(Yk*i@|%nU!LWi9>o^4Nmr z91CNxNL!peb+wUPW<1g7!ym;dqk zXi%y_r;BBhQU$Tvn`xaQZRWP~`~8Y7^2s4PC*gJWapF6;fKVqM$O1xRRX9WEqYnsXk|7fo2(9l=Ee=>Wv<+28#seAPW2w?d#rrouFhFj|qD zVy~|IYro$L+MGwV2*6fU*L&^xv>N{_K!8k07V+gJPn9YhQ~BEp8xUYYyP#m&6<6um z?8XC8o2ckCg*PK24SYm@LQ(iD=lDtrm|sg4cg$WYrgVM6If` zrPv~Pxo=Fm`4|+93>loIa+PXi37oRI{c z7S>pTiV1s5f`ajHzQ51{Q^Ch^3FD7&Zd8bvQk`duXUIuhzkicxl^N{`t0OqR%nX?_ zZN)A&;1zI`!B0ij_m2ZhD$(IEmH`t(pw#I**GYp>{zVvSvF|J&6D!)Lmq2H-B>6k$ zh!^%3I!?Vp6GFlJXl>w#kwrZVSv=mH+3?2{l_PKVgV*%zOQZd>{*hMnuimy_{>rq2 zJ|dlnTc?2kVW;Iw><;+xoxEvH+u0CYOmCZXdH>{IW#hX73Ye_Ni!xMO)P>Ze+cU6J zH-9vza%2hen7RJEXAp)doZ2G0;eTHeN0*k4fZG|#Om(LxZ>Xg#SFzMjM3=uu0bF+< z)Zd=+HXZ>xFcBVG7DgwldELvyxa;y_RVz~9Hpn#)MJPJBAPyUX;tAFgP)8uSLQh(} zkN>xHAI+fNVa48?wmH1}lJhjC{1ZdY@w={55N7?xZZ8Ba?UB2h!I^iH-zV=UE4p00 z9%;;;&V(}`X2z27OCBekKPOMkgkJn$fOZZdfRs-Ijb3ER$LfcvD zi#I>CIswNM*mj#UHgwk&$(^O;2^k3(DaSr_y0=|TBz*Q?=3Yr@kEaQX_W%3nhC#9f zM5CyW4I>VZ>rpswsBolAqJKsE>BXj)o@E<!l!tO4*rZcQPQYV zo>4}W@AANKpW)}|3DynQjJp(Ky<-VQu5uy zb|#-r`r8<77|kkR)T{-ijgYTQVluFtHky4c&cQ!n*0n;GrE6uA(n4J8j7GS~6bd~P zXCK@(nxITaWl%`T(uFaFYDH(r4uzY{;YzlC}43c8-c zXv~dSiA=izmp_Jd24H7eFZ%CzPS%%8E9;cZ7Tt-N{bhY?JO0Rs>j!stRFu2}5-s>F zo(GpCZA&W)kOfEj=zSPqKR?goz_D#6iVo2BAl1MJZG#ZuD3x_zF_iW8js zLK;h#8yX=85|A)!8VlAUG6dM+u69mGJ34-OLGLH9;fuey{d8elbaLv+i6(s|1IzahCIjMw@2RIDYxd-{v5!LUl z${eSUA@|d(C0W#aCB6T?ee7NFBY0nQkiFHfF|R^c7gJ{o8a07%F9*}owdIGK8fYSx zjFB-NLyB%3P@L4yLH6Q8aj2&u*n`|}Gms<38tHWr)P^GswC-6b@pYdb2pE=7KvBAY zz(P_AV97fO3?*G=eDIM6o~$EonoDR<c~AB(QbCpAY3(G%Y3*n5Zg(h_}jCS&yIzpui$LW7&I+$*ZIs zmK=T55pei@J%U_d60@!azuq-)H84B{r66d3GwQZ`?np+pbQc%$ql-H?6}?dJ)LrTE zw87`+r`=C%XSb5tjjV$ye(+a^{<_b(d#o=SaN<+XjYHOzqDVYL?ewv`oD(ucGf<9O z6v-HPHZt;)UkHsN2h#P0vfkT1eqc-qR95MAZIvLQA6+!gz6P$^ITDEKh#}FOF z54;ilWJ=<4*Fp|q?&20lf)MpKKk0!2RpxE3?E2)~bmd_@mHD zG6}4DKqW$DDaQ1Q-lOA%O0#))8|X_e1hr@u=n#R5_^NW$SPD&y4|OUKQ50UJ<{6(g zl=gp%FpI=Zu=gfp6axtd(YLxar}vOPTss`wS`W!0km~hzn7-bAWG~yKqJ1s1mf6vd zI-JQtz|!xCKT2$H=5~lZgWQdk(KhaKe4qIkmiU=E5h5UUHw!(ugTykPV3;rRQN;Cn z5y4tOw2sfRf+o>BsEa+2U7IsA8h;e3OWe~YQ_WNu6!AQNfUs-Z+G7>~tgATez~Na=$L8>W&Tfv;sK8(>(@}5o2-M%-#Y7qrj6C6{dn}s%Xa0q=% zqQ)1sl-Musg@`6#2z5FQJCRBVEMthRii-=)5@1fRWQ_k@Y~b1<1GU}yPvOQA-)NJV zkaDz%%|iS~wuB8f+iMTDLJzUdO3N&@N}=beqKf9?hr$$QD6-Xg7hHB^NP9?U?S}yf z$2gZ|9O4wDfb&Q_zN%HoBjL#U3UNgJo=;k;_U%vlfO#xNAuEa z8yFD-00jTECQr@U1iP{ItgF>FPoINWh5C|B18ws=`PNI;O>AP*cztIBr`2wf;PrRj zB0CnMa)ihX`Yi%hXNq)VecDN=Nd5y*sW!bpdlik!cgvuq`&Yt(7OdOPFIM~^J|J$yZ;I)_mUN2q@-hGDg zB3?${1)gaJdNU(1(lH+sLo<2K_dvwR1DdHl?G_*1c}Tf3{N(2j3PK!#DDAQ0v(ez6IcZ2ma`497BeuJ z|2L995W>W3d9dk6AFB{XG~-j8#~5K)0wXTD2NX>1OGGf0hld=n_b&Xl^vXI-rP>A6 zNP)GlU|q!Wlva^cbWOHE8dj&*f~K{4s}IzIJK6AUuc2ef{D}_PC+3gVxUk<83;cNM zfXY-#57ihx_5&k zP|Z{*ER^D6qPSHx`&2Uvg}AHbP+G!hH4i%tvvWY$S&p(C6=<4r%anxi?HNViyWVoO zr4f=~Ow+OJH4PYJYez7a+6m(^BTO8)KO}iia6^!53r~}-k;lmiBcH($_h1~|>XU$L zS^bx@Wmra7hZap&AA!z0H-0mK<_^W$G>r^tATg_Hpq2De#KE2BMr9g<{W6zmap4C; zKU!NDl*Xg4g(m6smbq;52$0PKG2*mKpJ#OTOaZEzyKb|M!UP{x04}d$S6Ki`M1Q-{ zgjJac8@S}fnQu$uZc*^0p5SqH9Hcf2YFh-p7KVFm3jWe8sJ9uAiSCs}gZedsYOr<1 zYRo|EC@&-PLrPKRj+7%RF0(^P(Q%aA}P%E>LWemV?hW1qq!(AOrdfs{mV<56hqMV&>Ho0p6doIws^7eAg zJGcx}yZzbgm-9}Z=jk70til+a^4P+V_%P`ou-c|Xzh`VR+A(40ms}4b)_jGiap*zT zg^)~NX*`nFEF#R_tf7lnFrt3IzH#aivvs+9(jAmGl zX|YM;D9ez+j`px?pSF3~-%ev+6{jnkyyd6B6(46tUDc{gOhwLeb`QtR-u~d|0Eo9Q zo;1S?osJCgm8G#J3?pEbmQor@h76oQG@H9J94gBJ6vA9j6bkDZrB(HuaN8#G{(3>2 z@(H4A5NV){g6g$-L{;yef0%k*rq~sI8XM{jdBs(4%o1O{M;>{n-ZN`v56zS*m*qxr z@W}17O|qgf{s=^j1FcxQO@6X#vOWTi)s<#oKpIThJo~%eiYP;X;4QHEl7}Wb-s}T? z?Wof`DKOCUXuZWe@q{Gub^;A_nb>qhH}~d-JwM@Rb~eV3uWuTup+-4K_CCo@jjgy` zFS%j5oAcP)i4mx@tY2EQ(uqsSz&uT5cRz217MAM2c&^ya7JT+K=xOXiFSbH<&Pkvz dMUR`u#f_2C+E=ryKil@)?f=Q8-0I2z001p|j1&L> literal 0 HcmV?d00001 diff --git a/resources/fonts/Inter-roman-latin-var.woff2 b/resources/fonts/Inter-roman-latin-var.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..44fabcbc3c621676831967bdfd59fdb90f233a46 GIT binary patch literal 52468 zcmZ5{Q;aT5u9?aey+V?@tF zOy6E&p*oUs&Phd^#cmg5qmo~_l``#}mj`Dnj_n_$K zanU6u%1*HS$NnGc72p8F^6T8=m2#f(*-_psvE)L+GisC&J5my z-sEg*{ghbcS^hhfa|#%h)?|dN@)|LGd6|svF0@Scs&#ObY3b~_BfrlApXKGsgF6rF zG}dDD+nGXNS|jTjaZ6F*CVfY=EJ$V3XGB!G-5Kl zjULWOk3WAi-_ku?Z7#z?&u0|si|=50S30^m0*vkv*t%gKLEmt|y1O5{t|114)?{O# z^)MlWbG)eq%JFMf>Gl%&eX?QSLSY+X2OxKr;uufiH}T8 z`Q-1Ybd};r;sp4VW|-I);I8JZk5yJ(*M*8YwN~^*;|U9$rSIekFWc6}WQ~skBb*LvN?l>EzbMHT=x;pYv-?6$$=~%wTdTul(M{e&qax5z&K1 zd|g?cMJ@lm5IgKyYz#~IMyPSdojoCH>8B@0-P_OZo=xBhA#4-a_zy$nVfT7eF=tgZ zY1Gr9iZYuT3fYP_+fq`xD#r4xo=fE>irCe=)295EPc=BcMWyE(O+p&cc)?bE%Z&&vjrubgmfQAYzfwAe?E0UTgi zrQbGxIu-=m3?pqN`dldE2;!g#S*8uLjBu#32*Z6P*@ZByA`}r&710G|x(LIdbgLmx zlp65El^fY3^Yp_Y^=%9MADyd-&#EeKFGDD_LR~45E+R9<(>Jd^3PHjnlx z%;~8-LRevw>q=B{B2r;uM`TZG=t$Aq9~&9h3C#iEkk`rWxz<+(%vPd8vkq?1$;vtO zQ+00h&o(`BjcplXQQ=b3v{iJk@T3vukf60lqph7^jtD?TG8}Z61sk@CK{fIA8NRl< zsG$;wouBwMe{Mbt@X+)mCgr6|PyaZ#;oU80$uG~=S}1jYRHdA6Svn({mS!CuA%GE) zeILLZcjk%Dz7IPpt@bfnKqy;H8zRf4z}?c>{YErsf|S4G&Nv-36^eaouRew$?05@UvfoKt zFpvZ}9Pg^zdmB5>uB!~mwRTW>#6kb%PNt>%2LjPpWN{j>ePZLBtG&5Q8>?4hKIA$K zN41UnB*7u+LO3iQj2jq08N43?P8llza9Rh9V+mt>QaP!lEQMk61036+qISuNW)zKr zhUKXKT>ES#tMHdQY!>^re>gb3XB>TBZw;ged;a{sRyR9aho8^X%ivBRkyHAtj#>?g!n92^#Vyj$WBiT!9lwQMlMIOk%+1&A*nY{~swN&}1xNc2oU*@yDHgbNq^W({h9aK4-eg&ApZUEueyZ3kI9fNm)XjhFq_#jBlT?zrqe4d^*Z~=AU{&Kul{06#?Agz+d-w$o`+}0V z$P{;rjMCWZ@-FpdI+vuiN#Tm)m9+Q2Zav)2=KAcr43;$k*}D^?)^BTI^c#0P%@4rr zFhwI(v|rUyba&nyV3tH_XqifsM5+t8ac@*pKD(R}-XbKXYU5^f?mwocTEoN!t#MB?VpZ_XrIC(L^wB1fae~DN7ib0sDV&^jSAHyibgUOvqL4Ati2{vz7{Ibi%#& zE$b>sq3I1N`25xu7}Ho6pbUf+SB=N~mESl|HRJVAUI^uwAq3l*MtUaZdXGx1tq#P! zbr?EnqG631!bBO#GLACkh06v%w;=##26PXxqYVfV5iXeKvHrWHiGMf?1FNz$^&S!u z&Xv@0s{m=VgrTBD0-ak5c#q5U+;*W)QEzom*+%l0`9>zyb ztK3)3aCh0DQJ`^;ovB*UM+#K6xK9ZD5`itt%f6j0Jq}~|A4(mLfeqpx4wmNg7~M*y zWa8QT00%H_M?T5}Vf_O3eVC*#-GN8$D*Ep59CscH5>m_b7DMRQjY- zi>KK#481YDT_yb*jwfp4^02f+2uvHSOQ{+5fnsUYO^bi5|F-O+ zpSW$BweeA_RlcP8^1BEJFJ)~%`_s4aE}te+g z_f%4MU2^+olz;kMJ1OasSiMkk^DUD}4Mm=1+DKKFW!{Np zo@Lg`b(&Q^>{E)aX&G6Xwqcn()4KjA+X=08%W+3~GT>Cluuu$L$GFlgt&6=bNAPx# zFP>MQ*Aof%vc9B8-85xGaotOa!N};gOgXcM9sv^x-EI&i0+n=i*h5xXluU0a&7!EM zJ#wOXQ@GCV#|}O9UV@&C%mpzYIQPP)_;iW?bxomwOwm~ zRI@$4kINGGRIg6eVKG@Dg+d$6v+I@)_f(|o<-)@1hIIe+iPTydHV#q!0E0p!(~4Fw z9uOypMhS}}#YTnEi_?OaaXx6SBa=!G4y4k8DRjbS&QhwDXhPjxWbZCs*kZ6#4>5eF z#_(0Yj_=9P1~@+Xe9+e1hO!OFq-`t15Lu~AZZ{&U>zLSD>x?IpDKz+%$*FFT=`DX` z`Pu0BPM2(@J;g}E*&=yZOzLAGR!lA+`5UC`~X(WNYqK=y{ zvL$xiMn^pI42FG))h|~u2rUbmAz146U&dc7@R+Lev{Y=`@TzTKfzpzbW$Yz15%iB- zx+JF#o*pu}QQJ&43_%%>?qqL@8P&fe&Iewq3cp|y%E1)k*M zoV6`hGnQtma^{&Nkqj$wZ%Wi|g zAW_S5c0t0+YwHN;W_-vE>L)M0oVVg|;7AEOQAARMCI#pdA>&qc@zkriLbM<>1 zZEY~rr~Kk=Fv_E~f1i-Nq4|NgXkK&{5=O;vNZ3(5c#tiOh6k!f?`14K#N-U`wZW>+f zxW?`Bso)qV*38}+L16}H5ZewaizlD(AvA98;i`> zkUp^byd14r{`t(U4roND>_EKrJz`S%hz}S)p&K0d~rNgIQM3neM@pi{M<9dqh9qrgE zf?yy;@^#C)X>R4BNTSE|E3Zkbr>7iji0`>t1ErTl(sOCkjN#?ko~G46NDV?6d=SLt zgah6>)b=!J{{~sLV-Ihr`^CpHW4Dj3ggJbS`~{nGPe?Bjt5ubQN)+Bc{&ZH0-q99X zndCP5+2*1K^@T*JD;UKA7WW_JA#X2|wcg^d_})H^%?(>Lt{3lZjKQ z&5E6~A=aeEo10?@SHrOgfy;q~0dFUs(D!xr8fLKXhvWQ=)zx^hXkSRli#WYYt%d~1 zJ@Mi!(mP!y@xJmop2GZTZ>G$*n-Oo<8WGAao)@Y1;S%E6!hG2Z0?M~@;L!)?jvas1 zN%fD{@1>_1&!Q@u79Yn>Lfi6+H6Nk(t{CaszYWV}pO#@ShbDRTU+!Z_u)9|5aup6Y z#ok_Wp{MweZAh;Q&T&om9%2%=#nH}^PvQ7X#i^oreb^3spcu9Y|)1$?aw2TOh5vopCh z=KfwSJM#O#+&-+v4`05BOt#%?SVJ=40{9-@Tv+={@R8dYqXOzkhH2ly@r-{wYm%!V zB`^v3;Rr_BeO_>GQb*st(*F+WkF>~k=ZX$CG=YtzB+yt8oVdS(1#=>J`ra3A*PQ*D z*gh2~3>z*J@3g~Q84?J?ANP$2tA?|>hMQg~O{hRVryEMW7FhcCaGF+F$nZ)E06kxG zBD`dWZ_ZTSyga4(m|#5Hr;qpbiQFA}W`iQxWV23)G{o0Vt%acXi~S|o;pk3W@ZZ5P z`3Ah3XyI`ua!(#Gg;>|U2t|@{500;M^*tH+b-JTXThm&_tE4e5nUY6Hyh4GDV@v%s zms9#6G&Yv+hZmhAUoXnOPAY^oF6kzJDjv3!Z{ndp+8MWBE65c`)^lw^C`+^utB)zn zG)n_;nJVdYzzO*hkr->Te2fO&o-A$Z{jBCkmwr zDUs3F*4+m`Xfa$V4k1o3dLyj5UVgPSd#Z=#0&5}q+<8GF@p^o}7NXBIRuxlx9K`oE zeD0)GKu-MM1;G0z?Xjw?+8AKP#vtBux>AK)4{`?bM}iK{4n+E*3@(^!LHrcS)9O36 zQZ%~C*dsl@cgGzyYOALhVucQN5jhqrJ}|;eY5MG0a>)D8zE(9JPXbvk{omOtXTOsA zt?jMRqYUzMwdUN%94GXT%m32wK6j}wNzejnijZX-P+GP zw#+oH9py^n)!tQGvbBaz(zIW1o*Y^YRC91Svl#FmWkhoS?O1RRAJz5MU8o)fFG~$d z^d92Lmpa>U@u*?LthBqdr&+6Q_0RmV8CBEkII`P&MDf{ayV=jic0G}>e~25)-KSLe zOytdbfnZrFY&1^h_v&?oy~#+ma~pKV{#ipz*6cUel%1XYUd~7l#uL3{a(1 zEK7`mMtNb0M-Oi6iZ&G1xaIX^dNML6Gg%7t*9MF3KPn(hibYXCRaodAE{W2NG))ST zLZ>AAE|D%K0vi|9* zc5kQU4tetK-cW(fDT1|$UuIl*F?k=kXh zJ79=0oR`Cbl?)O`rlz`xX?42+e9s5@W=!Jjg3OUO!kSfs(rY21Coij$aFA>ckn+6N zmjdiENvc84cNNBO4D%Eg$dwnTjr^+nz4v-#h_NKd`hiHmgO+HmZHMe^h6;9h-h5AR7+ zeSQl+T2Oti_D`y4tx8oR$a~LI#X}-Lmw7#EyHSIq@H*SDP+zNcT+L9LMYy;puTZ$x zYMhV9!g*Xhr#ny)8;U$J#S>mWV)7V#J@GOlqN=&(X4nYE;@}gdQo3CWc^S3tV%O&} zaYVv#M)Or_*Fm~=SpC(k{e3W;qs-RiN(_mDLLqDa(GRz zOGqy;+6NCZ8-aR#Q<@9uIRD9rFpVNjv86(fq&1^)ToEm`)2VNGPS#vxPt@8OxhOny z+7zgYbjfmRo!}aApV)8j3ra2#+bJymazPf&)0y+J>;p;Sd9*z4WomvLAGTERUF3@L zcSVC28;3P$I0+FsVqgq=04jrow8xZj4k^6m1TH9ntF|hBWEv(!(anM@0!%sLZygX3l_X?)4W}p{Vj351uuL2rzW0zVU#C zI#K<${=;gyP-wx)9j4b^cFyk~Rrj2B8}s4jymj`@hp(NkChac9S2I$?E ztgxU46}8o@u%f0}6wN?DMe?(1H=JtdoE2ytFMDx0!#~ zb&p}F>?83~VWqz;@R^j)^mkX6gq8d*`*YK;-Jexk!VVipVRU5z5ubxqVk zROmgyb+-cwhgBbzBMC8WQTt=)WJAQC5Fef;4x~N;ZQJdghD9jH(H^d9y!QA&4i7yo zWjTeOJ}Z|fxGG)j#iRke#kBE{&W*Hla2FPN;hY{z{|_C(4l1s)>-3H8X7Er$p!B1E>2|iA_NRi02&Spj{%jw$;Cq{IdH7R7HD>wty-1tUT|#duo3o+vk;>rb7rmwB{P}i>>$ES3B@u&38e zFb@(?FT5aWG3dCXy9C5;CE@aTbo4dQv_TU}G#X<001`>6Y3xN36J$}V57FcH(MRbpofLZVIG~FLrcBH)>rxzZWi`4JQu#ENKd#eton|>BQ|cA+XWj6F z#s@UYcVAzBv<&g`S<>;rcGLkvv zY1aO_>yLFDO{xeT9)A5}n-XdCNu9mOzSW~&e@J!bqHugra{;q>aI_5{iL!?v>1?WA zlp1cKiH&)4b9em`)%8C7P~N~{AnBc~jYNsF0?*9TE-qpQON~?=WrWgmrVRbpW-Gsj zcTl;&zcUtBI{FfcV#RdcpvZZuwgDgQeJ(p1^UZZOzd)Edn-sU|wY#WhrL>KSRn;O7 z_L9*@L4M_$et^=zjPwLKu)aF@Yy4iS{>yip15VW-6KvjBR))v}muk{L2hUS(NzTg>8Z5&0Z_s)Xwuvr* z6kZ!la?_pMQ;|}8Cr2H>3mVB8BdWd0*_h;ov@qkR#wx|co4Ck7fcW-2g}2;A*oX{g zEm^!zNK_z{`1Y7oK;Al?*m@~aKg6E+qk|;&zX)Mx$s07GMzz9~krU1BtV;Y8sZz-@4f(=q z&8D6?zU10J&YP09D%eO`8FEfIPdlW#UMh z=AX^W^SHrQD#pb5N{I(FFz>)OwCis}0=z7+pPp+f7JVa@|F3x8#L1jwW# z_oQ%DfRwTtX-H}$Rl6hi#mo`<+y3kL9Sju0mX8uIflsjUhd|Q#yJ|_+zlQSEUvidP zA}2e94tiFcdQz5B<`yei>&+!GKYPO>v34I5 zIgP4m@~&%@vk>uo2hW0;Ic{`Grab(JrhQOJ%A=P+~^*Y8wXOa zj#Mh?za^9r*Gn7@XWH2;W7tAY=Ii#h-2nB@-?oabd(uCDpNdAg?=o_nC(XBq1qAf5 zVr(XS~oR1m%MGCCHO7{+P2)iHX(AKIeMJpwu3AkX6L&0=iaY& zU5DTNnxJ#D*tJL%rimO7jf*opP1jm)0c{%x2!&g-$jr zZ||Hvjq7`0u@#aZ+tbrAq*7}C@7+l=Z#Ks&EE!o?Nd609H8cPK38~Vi=|fUnjD&@S zC5iOEdq4n0q(swIYes79>FH_7BvmyvFo2+_D76kfQAHW*rmYSUKdao$_Qbj$QEBQG!HD`1Dd~i^ zCY+z#+&q03d`dJhk0ZN2V;@#(uRmIn7|I3b7UdJ$F82qK+#Qv5O%HUr*>j?#2SUf; zcL&W7ahOWW4UD^en|sU4aL!{ILf-0n2tF`gW~+2buaiDkuBTT2Y#D4T?!soMg25tv zf6wVcmpdKa1*PTJIfK^;OkLuRw(u;qZd>r2`@Ojl9*Q4Q`K>@5-OeF>@Yss&8MucM zCCMkThHIbV#PDk_4l<#5kf-*OT(Ikcd07+&ZR@H;sZhIl8l7tCV$QUk@}Wq7acA(w zPmiWp+*NUJd9&VaSG4+q&$l3uc4sxPVhFPJOSiUdH!}Z0X4LLecPU=%FiDH$jTo)a8&DiH_;>)b+=-o$52bJ^zD^*N1hq372V zloK3QHY^Ec-6lidC~(_m2>z|Fm{*}CO^<{+UV?*gii=0%psCQgXSa#OHU0#Kg5z4V zk&o>(z{{4FCe3v-VJgWo{@Q|r*4aNiD$C$J-380TE9HVwj{aFpv%;fHj#=yO*_e<( zipAiPOZSP7T4ExUsp(<1A^f38)5)CKPU)aBDGz-J|HFOF2-zO>3R4)Plm9ZFsfgg85=)Hle<{B?U>OYf1nscX^n;_fLDj3NUq-p+k!R!uw~(cOf} zjc?_mJ*JXK0W)VTJ<$O9K48hG@H)E3mhX41k(su&xm4@y4Cx6-^JZXhMmJX*xz3o{5cK^ado~ z54?QxC9iP-NiPtC*eo^*$q@?V;;|^sg^wQ8()(8_3$;Fo#aie|gQ*KIN}g0tZN5V$ zCJKT`LebUcAQp+qk*cUwXWXn9%Mm`U!zB-HHEfJObub5WSD;DfGfLdcofM-I6$P$H zjBLyuQCN|3C*FiP`A95fNo5Lb_}=JV5)3WeQ zjvE(AT2c(6Y!~G)T-bLLDIv*p_)+wk;e6yPTJ#FVM(NOjqT1diF4jMkkXFmKrYFkmI7>x@T{n&f-l+a~IY`jVG(>sEw=+C@tcPJ~$ZOTj z9)(ku^ZUk;2*8@AAdc5)-i&|Dz(cy))++1G6p{Zql!e1gkedigiH;{42{aOg@iO-x zl;%>ejh^wQrFI~T(YG`-v}KLZfXIV3KnF8pKuYD}MZzrM@ktu*dv!d0bEW)kXr6o* z_8`Ecnm8kVz>dFR!so2kC8i(|=0#2jNs)|olK~-v|2KzC?9pwS8VU@ba)`GN3N1;h zPLg7p5o#(Pj1cKDdgqz@pqa;l2}kg4b7tl1#>aiI^2=!PsQix7xCaD*=d_L_f#;4Iv`?X*%Sbp>0NbmtBZ+6$jRt~{vaOv$j&Md^FkGsF?=bYJpDOJDp>X8rgUHM*{a)5?SRxCIDA!oG)E|fMYS)-7psSiHw~?-y;-v402nH ziM2bg0;qn|(UC}RcYXuN>E^4_H)8G~gJ1#SfN%&jO09_)VI*p3jIv*(r7EinlQ9$H zNaWaH8le(0e61;-cxLl|9IvRnm5b&SL*dM&0>5kxvbjdl70IIBgXXV`AfRG2b!DWQnc73$rKbvjBm(hS=HS-&&_5GrH6M|yXj0%J0-`@TuCJEj-(I&qGpG)hQk?P00#B?z@tu26G)Bct*Y zy%QdI_D%*2eA6rpswcJ~+dv4PlVDIu*FA-i6*$6%f}_-wBDbGEVTt3f%h`Y6Ii6gU zCbz)(*;%|{l%g20@j>VB5oeNKKhWSY6P#vp;YqA!cH)Q~XQW*t2K1pMz2wv%bzOy| z0$eE-!btFJ!$oGRvl3VZL}vX0pw{^)cjXt*WK4iAw0G@g#RQ)Kc#!AS`L5zNG~58c z?F+aD;9{)bGeTZmxBg(UY9>JhMcfs2y_szTWtgKUxshdAt;;l96rBdPE!Qvk;l$i+ z%^%h?WDQ5Wwa@7nQib>ECygzH4|szIF@s05y?eU7UK21ILWnp)sOhfJ5-U~kHJy7XKsDXYDeIFg_#oM`aRJ@HpqyG^9%4ggJY_o55zqeM8QJ^$k{ModJl{MPoiOr!5++i451UH^>v_U+Us5T z;%g-9;k&Vnok-*y%J1T%??LCxVI0AZG_dwyPxAM-qJz2TdoZ^>^IZg;2!qc;lPgQU zkY({f-H<~V1D;6Yb%SqekosT)+5JC=MF<1uDvW(0_cBBKJa2p0;=cv2&SBr4UFL64 zT84n}_?`{Vxa7~*olAkaYHz8S`0@;AxMKeuxTigoiSO4St1B{%8V)^OYh+z&_9mq^ zFl-NMZJLm7HD2|HNZ=Y=t4|Eav{=dpq(^E^Rme)wM9gH&@C=vW;$F^w80o?m$w=9W zSE`Yf5|MbcZuJ{Pr)&1zWYc;o+&g^)cIAm3_`S5r z)(fFIZX}G%@U9UYTw5I)f{{Q1gXbSmfB)Sbo?bP-g1>DJxlE+%<-JuE*jBgLT{t)1 zNVXCYqvfuxG(CZeX!$7Iu&D|MGk0n>+lvinl}e$gy9njT5eATFc9~}D7HT9?qcQ#7 z&ZbyfV9@X3PSiC(uk7wP7i&0K=&6ZE89cf3f_8#)biv5iQOfJduW;~58&jAQ&G1I0 zKt&+F6fGRiu7Hklqs_j_4W3ot=;xBav*dr>VBm*Lg)6)VNTr2b9>{Fy}UhiJfFMu?h8~)PcK2-b2p2^w_4km zg-USlpHWmAXw}WTN^W5(8lCVPpV)HySs+!{*_c7mTibyG29R@4xloBJ0uxO?!X&)Vc(=FVW|$AIynTiH($z_1Sh{;7Z64+(Jh{GR3U_rZk0&yn-l-VFCksKXc>f&h|ck-0OUkSG*z^1#1}sXPYr!*tl1OevZ!lF8N%C%D~^} zQOrC!w-!Uqb16uM6%z ziq){kgLQ74^-W+Xbuhv;H|e>1G%Vczl%VK41uS`higIE?ld5v45vF!|=;O;nD(_Rx>FgAkRElRv7|y78pSGi^NEqCm#(LP-Q)+gscORJr-ZvQhk{fpI zgF<#4hBANtDg55M``4@B{AUcSH2NiQ5nF zsS~p}$*2?><4WGFWoigP2x}5x2z!!Q9CtZBoFe+jiKUuolo##F zX7r-yS2|yy%N1B7VVKes-I2|GVCo7?Ap#?ud@S#W z!^OE;h|#&jq*9{;z6!1cv_D+2$7DOA%wI{e@V;g``ab`Tz2iUR#Sp<#esx)MP5S|#g4ug(?(+A_qwQDGP05(WkgxI z(VhUVst(+x)Ag{Vv|J^3lwAI5dscP62Vems2b4p@3hU6D06wpI4jup#S_{#>elZGV zxdxlbD8WmWjRWV=WO>$EYVsPWO7WCa=Z;#K&!*?zHj)K2& z#uQ58dFhciG3QLBb$A_`j{6uTqwhS4v;H;8X7A~JhA`ZHX0ah*^iIl31N~TznO_q% zXOQuZbM&mB(I~5la#n56{G{jg$6T+ASFBAt2)|9Q8qFGJRKD_2C^lhNocfreg{lUzp=zw*9qnagNf1~ew@Os0Q zx%Z9XK1KMA$9|h@5XYY!?qKIL_F5QRfEUyl9!IzQz8n=lYzzc0XZuuQaf>^}Hl{6C zalc4ErcTNzAVv?q9a^Kd)-m|0DOny{^OiG(eSbiN&gTjD-UG>j(snR9oz|Wo@lUM` zE^TKXxbYoKe(JfPkW%?m@*AG!y^rbd|me(%S4 z<1u%354K8vw`8)!*8?+)o{ZB)c%(}r8ma*)c{ChJ=j5U}h?@f|R9ImDLOpZPWeU70) zI3}r8l?^D9i1(!=yi&duyjh(!s@!`nC8a*=Q_PKS%n^jrYdu;;~XyL05w zeHsXCVM^0kqOL8}CVnBZ?6iYuV7hT#iNgpdUXPKEfUE4foq%MB&h`E! z-;hI3UvU2M9}yxUShB8xmLF)k6eXzn&Aj#9k_@j=rQ@F-ZDx?DjGj{o;`8G5S9d#$ z7_$r{#9+#x%lyjXJ>J2E$31XZ4}F0|lQU_k`{@X+0)p?i<0N+29k*%6A~wa6{*@oC zG88ommYDwHsDKRWHx<$LW=f`k&3MLF-^P64sbEx*;s*69wJ@ZKedE@3wGVM4wEHRJ zzwy2|pxaAu(UvQQiOBs)s@I_{Be}lGj)K+?lkzA&A92A&3c2^K)s2Ij&pbDp^hQVZ zV>WA(`GQi0DP%h(1H_6?m;LsV*l-Q-tR}AcM5dUCIacmA6yyW?jAxRRq!CO$g&DBk zH@#99qtIGaqhSg{CO3tRkG87W*VndN%88dxvN9Z(`bivrxK8zvqDrNbDAE}q*(=^O zi=bDDmd*q-Ndyptnf2Hf3_cmjqAre09168eMMlJh%9MyTA#6kB9H8!Ro2ntXiW58o zU77CCEQ@WXj`aHEk27ML)uocj?y%1ttg^Q&sx7V-@+`c3uF%Nwr{!o9sR(R%V&0k9 zEYoaG35)BPPx7a7=cCO?EhU^+A|uC?H0lgnZ2oKg-NXW!qE?;T@Fj@pLs(QBmmJA> zlAlW`1p%XVfMMbPJrk4-X)$OKXLjKnH1u5F7bg3MR3{)G7!|V!3AA&38%Hud6Mhdc zmRCzWR7~-{h5-})KnK|oBIu1*pUKm#ZR=VbvaYUohMw>D+9g0Zr^-54tXexBM=SIz zy`ZNxppJKYB``4+ku-2a_y^M>#N}2ob^X90nHF;8jvI>t+jO*2Kt|s`HD6k}jgWyV zaW4DbJ;~|ClU5ie?xY_UKE#0kM}YBEk^8+$Jb?aGbzq0Z^t{{G&<+_yw}2u5I~KJf z!(ylakP7lqmbpE*wMBDt&+Z|t{i2pn=A9NAL;f`7SjlgVe62}um~?6Jq)4rVWx#=& z2ekk{6Zm8+)lsP1KT}pTl^bnuTU7Z(w@y=94qH#Y zOx=BJc+=@t37VWRq0|v_Y|*Y9Ivp1Tv$3RUctQJjO%+jYHE@GaBB!wRidC~_#k_QJ zrqk+L(kX47)NxNU|C)&mdbJ)3`|`ipcdV?En9CPZy7wNs0WGBU_kDI6D>qZ?yb*o# zrU0W{a~Am~aCA>Q1@D>NoT~AeuQhui8?q&>(mOrt{Qb1C5_?Mp!!%ap!2po=MLb^Z z4h;iV1vvel_n*nTkhE7S~&j@{>fc!QykcTzX6+yk+WiHX`=k7|Vs^Gs52hgs{OlYvA^fuAp&Veu`b7Gpv_z@V=wRV!*k|gdB5gcz!JV_(c?>oN`#|37cZn;kkzA2xpO=CzXC{Z6X(W zw4AUY-OlpX@VRCY=>eby|NhpC<5Vb9W@t*A+8SrsC-1W&1B7hJdqv3(1(F`}9GxmF z1n5$Mq7S7GO0^r{XX1lc(*dYw^}KOopZ3-{GX#zc84cXAzB8; zyH2W)fH}gMpfF_daw46?p!XDYSVEN@wmdX1%n04OX|fJ`)A-5WWVnGBn!hS!jTDfy z3|(|MNgj7#uOFdF!f3r##%4b8moI~}W7J_{1BB$~aC@$>0*N4QmRjld3-|9rKaw^wNcB2yACF*uSY=1v~ z08M@j3)*5dDjr{5;bNsXaVPE$+9mc-hL&V#x|3mihJ0Hl+LpD{f`tRW4|lZWl0TN| z>Ab}&wxpV*S1>@eYpkJcz1Foqj#$OMFBzbu{`zzJRPVY|>OdIu7WPxVoL`57(s0r3o9OgnZ_P;9;qBD(hzl*cNx31$oU~ygDl7 zVi&}4IY5_xpI~Ej{u<(`@8_H}`0(WNrP_6_VufZ$u?}9WSJBnv=uesDBHWT+dw*Akx-O5u%|PH`Ic`VsVLtK1#wT|>=bf^*uo<(^lV*LE>rS} z1Z(yZs&{SSv6g4E2FV%WTk?jkLR;Rh=|I;FLLsJI`f=fhx`wB7fm|9tVB&ZeXt7it zCj0NOFh2HnJ{9dc7r%R^ZBD-yeWW@?dc|e6Ff?K*xtx{ zQ;C=A#i6397LbOZ>Pje1E+)NbT?)gK#V`1>))b7H4w@uPTN8Va=yk+L1!I?scD>4| zi-|GFaViz^rl)CmZImXz<)^Q%uztuN21Vzq+Xx=HGGL5OYI z+@bnTyJfu@d1OEYc$>+qyV;yBES{r&fM(r6F;s>7q~NDpOV&gptxty8`QED9gZr(6 z5i|?yUhDL+a5nqdBQ~;Zi@+_2hga#!O8V|D?LDspG0Wd$p!e6ppDG`Fo-lq|#h+<_ z05Q(ad@nX}hEep&>TBgn^Q`6fd&YDf_GxC2S7~CH^>GQo-l~bWXtjycVnNmTZdwn9 z{-ao@s}#mF(ke06K$UJ zkCZq`UBXp6*5w1E18vqagqAdHz5LZ%VGQ%WUo|zf&#k?5oDr0DpdsTO{Lb5TQ4_y*=p&+X&XM zM`Yq7a*DaRV0itx%I6uN;D!~T8w0cbc~S$G%_>9+B8@f!EHP+^y@UBI^lLd&xL9|s zCEi?h{N`>*7lH~p)DeifKRK(eLydvR1Q-2kXh8`3_xG)a;9W!0A#D-7Y&vYk_bK{c zJJ1R(2o4GmU42vgrrTpauOPPX=2Q=VJ~sU4;hw5pKmT00$D;SsO8i~hbVBfCdV28n zoADikpuxcjWj^ZFemgHe8S44|V;*~CIEq9P+=^vOl_9-K-=gW`p(QivOhj;>SRFES zlhXdWZ!W9dE~qu$u2Ku9@<6v{{qjh`tpIjiRD53Eu)Bxeonu~T`N_d7?v3*Ho{jE} z%L<2*%l~ccfDJDei0?>Z3ZQtBJVfEMV>_@=9R6b={JorVm-aZHt zfMN|?1hs~NY#FBRyK-Fg*q?tg_VV4eFP)z(61-atba($H%zY;U^b7>4j~S>AXP*I> zCJ4~Ir-W!jSD^u9bdbO2NicFHp=2x2M?jSd5!G*Mh6SB8-Jya-q2F{b7LW_7V_;+= z7&E{g82yAD#INCDaL`4a9jXX)fZhLHgBp{{5Aj8JMM9eNLfGA(Vzr8NdpCI>ut8Ky zT3gRwtJ>}N+{>?H zW0Mt$9-MwT0}{b_-Dk`0nf>3~FBsjJN1Fsd}&k{k##95 z>0YUY6p&q?8-=dPz_E4{Ec`JRm zMO=8hG*P*?pRIAbqPS3AVw}0GmoI(<%PGBbCFuy>FP=Hbd!m+?d+0}R%}bwonhm_R z%KkzGYgd>_ozckyP>%}JFWv}<4~R4DcAnk*!jennCW87TSUHiD_KmplMg?CZnO)vR zBYzG|SflI0)B3_iBfBqld95tBh3}b|6!k@gXVe(1z6Md4>R&VGAXV`9UmCBslmC;I zm5ZioqSnO{%IZ`h7&(i@%OFAeSNcfuqvD?%-)H2)lxulnXl$l~b2*Ye3XdQ{8X|z! zo7*KBEG6BUOsGa0AQeb7l1a|u!oWcllS9qjrnC3ZKg!Gj0iv32_&*)32V`O}!og__ zw8oHYU|R%vDpeGy9-Ms_rfu2TF(mEa1)ltsKA3jDKva9Hz&Z_OoBY1G?Y0_N@nzMn zD-~HSmnP4?TVVy~C3&Guk))o43Cg`9Buj7>OMAt?XXSugwD@`SmNcO+GMZ||H=eh? z(M$fg@{?$<%qNlPm5(uo#hrUiv*#i;>gyvn%(gZOsa5$PY2+qI_p6~ft6ROlZ+E*w z!)MUL3_vKaS6OR)gwW>T;t*$Dm~>b+M_bqw)h76`jaFa3UAH*3+7kW3JG)O&dlME* z3b%SHS*-LEkq6nmp_CT-TmhKTiX0-g*?3JCJ87GfH;i)bAEN_>o%ig1^r|RoC>i0C z1GA&^cf30Gi^a{kb3)M_t(1ZHma}HE=f}3E_or91O%{_|UsbbJebCm2D|>@5q!gdRbCr4a47#>g8t_8z|~8$*FF*2FF}s z#ys#WpI`*lLf#%Y*lLr#3lJ#!qEj%ma62PVq8`kmgZGIImiI%b#auThQpv zvFWP7%Rw1e6iQnz&ZLix$ME^%vA#2-I?;wa&U>1bwoqi9;2}*Rw10OVtnez>Dx5)C zL+mzJSTo6MQD|Z9cQm$I^~$T)^5i>rRk492z#tD;NydZvwC<_R^7EkHu48$&F!o`a z4D9Zl+AP>erSIeHPcg|uw0N*eDrUba_9y3vyF8$0@Tic4!YeYyj;IErmX~Egg%Ut4509jQ8yWS6e+EJdrQk z%~!fO7ratZ4AI7+3HSOH%6I#NX&oK@I4v!zWK3hNBmBVd&3lzM^2u*XbA#4po2JU^ zXCwY9F9`a0t$KLBKTWq2*nJ``Bc}13A#k6Z<4$O+pV;FJInbg6pb69bxyQKq3u$jV zp^OywVCUzH!wh;eV3BjKdF@t}?-g>sWVF`SB$qREY>+qTmQy_C0LcM}6VPg2T|UG} zUrRq#DXUP_GOZW9t^YY@k4f3wY^WroXgu!SZd4*J`<>c+0rSWx;Vnjs7F;fI4<=m- zP8frb8|ER?K74SS#wnF6iD_&^3VI^$eEmDWh6DaxI-`wonwk>BURR*_K!H~U`3^nm z2TI-FY3mOJiv@D8A;vlF#p2RGKP@l&I{56F z8d_Gqb`flG{`G%7iaPR($MLKxgg z{_m}!hHQmb1iFPFUtD#hjqUF5JTfisJ#5hj$0m$2mA-}Cd6JoIgo>74H{NviLJzXw z{1=0!)g5PKKev2DH3AoPj9AYbb&TmV>AiS(YW%$I;o;j)vt}|m_j0q@^YZkp?Ae@@ zyRbMd@!m`hpl#gHC}V{$z`G<3132nnblbM_qB6V466qk#E=@h1K=paC=2O&F1F9Kx0gTGX?^(0ooA~uICuH{QfXOPb2+?wX}rW=^#>hy zH}h=TLABMCq=5)iT6XlcWCFFArE1N|d zf5RP@&a5wUbj8@9Ne!w`!?2}YtNUU<%C_P5WsB@uOj|vy#zsw;&{Cv9!i%Fd zUn%0qFWKK%ZL=My9Wt~XUT4pUX?N$|@$vROJI{}dne?_D`Y@17n;uHw@rKy6DSq(Y z7-Bu zi;zrk;yK_5m1(t(UbgZKqeFsDM$W~1v|o6IY4guGqWY)FDU*p+6%R8*YYv`?j=Z*y zL~i>zI*qd!)jvwtXnQ>uro^qV96vrD6@P#UI}m^!n|Q}xF`@wF9uwn!zrY|5ahlLF zL!s*avHaWp$q6zBSI#6&l>{8s{Z{BC=chREtW#h})~) z3%ml3#_$fdDWxM>UIcE?p*-Y!y00sdU_sAH7 zRJRmA#&A(wWL3R;08PGA4vn8c<)!~L3=HTAh%7e}eM<%v(WfMTSR#87WPkc3E>iLeS6}^83e+j6Dw0e1(a}=D?Fz%aL2Dy5&8{8$bD}q% zLZ(L1nvN%^H-_{pJ2%Y?5h`+zL)xz%B(Bmn~r5#$WMtN-vkH_tuext1(yhKSd zQO@BzFVz*of;$41+!4?DA(As)I(IqEn%DlP^_BL6smq zDyBfTK%w9(AYbJb2?Q8mt|JlZ9evcO9A4^la`JR)TJn^~Mw?28mX;c0*an=SNwK7W z?`QE}T>~qJcQ=gk>r_Wa8N+;oqF9No#Mj1M3?4p7cBB*unHLts8~j0E+hKN(7bcr_ zA}Dl{H4Iw|ApKbv2NSImApOSJ?K!gJIrym=_jEi*!U2691}Xuoa`KJ7^WdGmzwT4k z%G<~SfsQ*`90rA}DggaDJ0hF$8og|U(M1^3Qk~130etRAymQOp_;p3LS@!fW08vi! zDd8wrPoQ`-|HxC>TjoFv6oVSSWcJ~Zlj)K#AC@pyrF_X7U9oZvX|- zXT(eiTAV;J^puh?y#O+W0!>OdRbxX{S68JGtl^EL;MR+NkdaVqW7&DY05br)RroqX zN$(>%@@EZx-~~sMPTap3V6UM1W%7ZT!|rr%A5V6?jfFN(u>-+$Ii^w zCyUudjCZ!eVU%t0wtIi}ix=7Z;5>9??_Z3)+1*`x!Mx;0x}dX0fB9k`A8>DsU7ibH z89GVmlPyd9C16`i622sY#dctWnJO=PK0SRtJ6m8(%udW%(>Sh+3m1ozSWd)6uV!#q zRk9F32=ob#c5!;ISNQH{+2G>%)jlWfRFBn9s5rYDk{KQ&#NNi^1kpOt0`Im{zj>RZ zB&VdUzpJF~kM<9s{Ee7-9}J7n{H z!9iU(XNhw=bVx-k54oue*wPIPoAWw57aZpL5GMYu6sA~qvv*;kkI73XllgoI)-YW$ z=R7&k-mr6I7$XjJKB4Fo+z=<;z7bXwlpWOR9v(TR{R#P>^{a935U-z4v<`o#IHP9_WQ z98GplA8c>}sP!xuApG#*Jo~`J;dJKv zPHD{YP*yTA)!r-I4>6{)-jOfo`6h(gNvL(gsdQex4E&v!D<9@_Kh)PV_Vy|Vm#4I) za~nOAxFiBE0Nc!rcRD9XZ$d6fJ8G_axPH3@nW_+JL}J_{c$mQCD_M+XX(#jjNIHke zvnPaGA`BL^REU`Wc1RcA6w&P^iNW69i9z?gUCz-UUGDzY{ux6j zM=T~34zh-xm2G3lOnB+;Bvvttw}7mt<)Y+cB=Ne?Wb&07*`PIOH$(SFHkQ7rd&e;No}L7m>A5KR%vL8t}ZVN|pqh&k$3u2tYUi z=H5dX`&E!*Vk%?wgOJ;TT4Gq`-Iv??7K+INTt1nGj zxmOS6DfgT%0SlK}sX@c)bM(Zz@fkVPluS}UaVB62V2cn|+3u1~W{lJk7{g{PY*K~T zwQt1qx9IH9d+pn!IG+4s5&5(P!wfuJ{ZO!U@SB~A;%&Z@mi)f#{|1WZZCp3;4tDr$ zjo)qTx7|-))nG|SW{%(&$Lk;D<+~XzRiNPnp}q_OvrxW%4}tE1-LiKpR^PpQbqFgT zHhGwvZ}M6m5H|nz;)PIz;NJqCiGK$l3VfFBeqC^RI6nu{BGle%riaD~3BhM#s7yg( z*nIbY^HajsVBDHZDTt6@t)?}7L>h(@l39$h{)rmJ1{`+|1mg0^>haG0p>&$|e7|4|Z)GeTkZ zveS~UE-;EZShXcotP3;cggYVK!8uXQLoKN63~a=qMiq_d=_?*Il^eh=!Aj}#pqz#% zs(3IDjbP~K*HJ?`mA8m|J}_RMq13!Ox;`RJxAPJ+O3?5ksHB10#0jv)g=HKgaO-&i z#F~_pW7yck_Czb6)3H=?L9CBYQ7o7iEYZ5ZFV0PJ54`Gb&zcD3v}~j;==x^|23OU7 zzK_`JH%d<2aD9oqp=I9jc-DVZ6S_AZHMqTti=SwM^_mt3gZ0a!mzG{l)LXM#T3$i;G4>Yz(v~-Q2<% z+10`+E*IKW8UDuuN~xL~FD+~yns)$xZ8t5#JAj2Dq=p3tr$+hA)V&!W8F@Nhg0oJ~ zI!!yZIDjzi1QVT!Z~s-k;35nrllkE;xRQXx!0JG<(BH)=At*RFGuUNLDJ-sH)Q>m# zs#_Q)NM~px@^s4!$)O45H+>;QCf)e3{B`+K=btoV-=i&e-s4 zLw)zttJ-JgH)3N6K0?9$5rna4Ul=vEEhwTPDwf$X87XKc3wZ$n`5clH!`d!901=dy z0AgcVIfB$_-)StXg*`gLJ3c8z{-pXkjxK_MPAMg(f0SP0jCe3}e2FQg3^XDQU0oOE zpHlRTPfiu}G!2ItB>D#b4?iaCmpCP3J#jl%;WhtFh(j`Xwnxfj_%BkYwoc%;wj5<6sMc99ttP|1w(uMC^P?@<<9 zi5JXP-Goqo%6x?2$iMT+BUjkDylw#rzwxZ`aub!jLbT;fa-3Qj!(3_CW;PqcMlSdo z)1yX)+5EJN1^FTngNdPvP5#u6iLFd>rs?}E_eNODo6b(2w93hb~E~H?7+=7E$Fu|m6$7V28A6`N^H$S>w@TjFb`d~0MJfuu-nUm zxcjILArLd5Bkmo_aS7V(V&S>l#>PDmuru&koowN*0mq`koScF#TM8KF^-!fjq&kwd z-z<%wQd=Uzn@Obbx|X2m8X_YJ=fU6+5#f2@!hwLkhFr(Xb7M{{H)o;cjz&XRnyrgV zv_%2}{=dYVlxG^|R)O2qU_Y23C*~Y|ZXmt-0he>Hw4gNU-hFOm^#V6BCKB%5<5o-~ zvpT(imsG|3%q>XgRD;M`g|Bn!YEo0F5>VjIQd2UZtIc}4 zadChIijN`{Gt(x~Fj5w`%PP2qpa?CMp}N$RM>};JqR`+Eh&gWSnPITsO8Ew{mVYi( z!6Lz9ROC5@B2qG69u5`i^2~tVhT7tktFsPmvJ>bEK(cSCPfO9$1|3XW;mqe+w3E|n z@hvD^dYt&Y@)_y(y^;qcFJ}uBl5+O>Q58-$C9{TRQkUdQ1D9??^tf zHGlj5fDn`Y*$t~~dV?NveJ5;a_CgdNb(Ng(2ww$481Dru4Gifu#wS6<+s+yWxaCe9 zJGfS|_Tao))@Xs3n{<;i#Qe3P?Tfzi$v0RPRDuozHa@SNzgKzhueY_Q0uTEfI_P6@6UTRt!C!)t zF|pv5TZ*=Nbza$|je!yHx=y-A)ipqA z`<0+}!O|I4=;Vo@Y?>E_-D5lK3nw)etZ@8yJe}pFfvN@$2(?l<9|E?O93Orp(EJVl zd!VhHec8*of#w+HGS34*8im8`VK6Kx2od=OmH7LEvlJ3~w$aYk)L9xZJ zvgeTjz_Z3&`%`nSl4WWbHj`oBe z82`k30`$+31Sxs57dNI;`>@jDovzM?7BYZY;lDg~b_Ew@9%(>t3|U24vu+pE13 zd7^^~B|rgme&FXp*gS|34`SBVv4B~JVb&ExDi%0<7$BqXI-7tsyaVJE za5uhs*zKQF`{8Z>*Hw>4VQj%f5H-tN>j3cUWp|^=^%%(gFQ!Civf%yE{I;pxUZA@J zsJ*q@R&~-4`CFk|J}<(c6Pf>gKNNqjnm2v7{`bB!=V9*F-{y0n{4TDbBB0%d?N6kz z<9e#>oGQB>uk607vgf6hy^op7Po_%Ptq#i67*i{$y!FE4eJ@NL-cR+F0*4L0Z{ra1 z>c`5=xo}zXJR5nDmw828ofE-e!Ua^*B9|_Cp=~C9#TI!-KF7Pf$NS!cYbJP<8WP!) z0uCg$VM#txF~xJU`E$DHTLG-z{Zt4HCxrKLqdb@hs5&xcjfTG!0uupkiLsGwRKW1n z2)=iq%u2uv6+HtpDcv7A)elre)gd0!_^-fdQnlz1T>te?U}UaTaquM!V20883TEiB zOH8_$gZnZL*Lyr~oqborb4j+;5MaI3=5TWy;TDXa>R;pz0TC97B~n5em&p}MmD<$I z+``hz+Q!z--oeqy*~Qh(-NVz%o6LP9tN&jo8()rG0z#+d$&Z%yuhx|2d)bza+9Rv0 zf^2*_atR2XmM1^5y2^rVd^vIn2%VPK@;?x)RG@NbK#w|@_~)yw0z5NUjkMm;${nXi z9cu`@u6|?xqpGayE&%xMiPqQRwma^*?}3L}eO=$2JTzmvow;Q$Wanu`e&Pjns-DmX zik9~Q{A+L_GytFT#=q@NzFw~tRyehovZY+|%`&o{0E#y`%WPR8w@$$zfB^y!1CCph z<|K(NtENbE)h@Udcn%$B4kao9O8UAw#VIwfJl?tVgXZ< zcJ@?R@C%+_w-i?^N!%xXZ*`y6OI}}k$G^$|WOH>&LFbNvupkn&PQW7 zu>l(m5DRdw;gA$m1Gv2dbbX)B+E+L?gYffCg+UMKb{S zjwD5UZNP+fC6jbk?uVfnVy+Ns`v!0-ObJ6&yTcH6N6srHX;V zsK5uh$>@E|$|frh&)fkea7qf>4GXt=Gan|>-S(M?+mfJ%90jC`;cc;lm@vvTf{tNB%k9S;02Q{zRM0VyOcsj z9C?f~gv+EUW7X3k&V07)6$B?Bo^{`@m^2rJUBS>~SKSC+4fCcKMs$aRB)cHIr~>#d zt=)GTaIN^78&Qvb*=aLiKriUZg*h}_0P6?}^URTeM$ak->V}FwN$p%KG;xd$RiY14 z=yo>HW8g|l1T9@fx2fkdr;TU88hy`+kxdpbcsjHK}U)t-BM1^qSI&10}ca zV7AnvC#^c@iQFsAgj6Qk4nvY5b%j(gyc!z!f)eWPNQVgJ6uO~^wK}ulYKA5QN zjvx3=tj*aZF_21P4IxR((RCEj8P)*~E8oloEkZTBC)L=mIg&zHIUhz24U}Y@YowiE zmsBdnCMPS>WTQ^93Ip9%aBvw^JEmAs&3d&!#U0D}DY_6N4FDUkHwV!&;AZ!vs#MQO zDF%Gb_#}q{B^gg0X(!kvg-U%UCo62LEHRRv^z+RD9HCInNUG}897!RpoDU<120JI? zDMH!_c1fjDY;v;VFkmnd0Zp{O)^bl(|7R}z$KQ3n9y=fdz7VXOfOnYLm9aX1L(Z84 zgaw~W*rB^J4SDRfae)p@8!tt0I>q+R$NdPxvu5_5etq73FJw(JkM#483zFn4DhujxY2AQWqcC*%K(rQ^aFAJN!ZoK{9o-l=K2HN~bv z$%46a9-61;$Slp7^|KT~Mj_eAY-Aa-5!sErqGh2a(rVNGQM*$6oc2ZSG3{BMO*(x# zUr`9uR@7dUHOdX;k19nqqVA*KqQ2`|>w4^}_*>)uaengt)G_@`=hzR~oNe&YyvPT9&wKb4{y87vQNF|# z!HK$Hf?NgwF`qRhbH{gN}n8FJ-;3jMZfv^*2c)=J}aD)e>v5Hse zRf5o7!}D4+oro*)AqSi^hp8Qg&(cnqru zFv1mjJjN0p@iO+~L!81mrcom$wMkN z+fRG7Y1iN`Zo=32SAXzcKNn0PhxhOk9>qQJC;rAla@uBd{?3ma%W5%U36C>GkVYM2 z>_8h1VgN^Q0ud}=6{!9R9~Nzd$gqYRag@==8h5l{A9^u{Y23osc!pPmq$r~?3C-zD zVS3XLtvMa%>|{8e@BA;d9->Ac|68j;}h^% z_&j_m{w)3+{sR6=#h=38#XrU`y+wP{Jqta1JZ}?#u!G=4AQNf`vxMubszCLj{?vK3 zMaCMN98q&iVUSVgSm%ICHq(%sZpwbORiW}W1i z`*pK!-gU?P&QI~y-D72sCAvGyYyO{}`1@P$z4gPNoqSs(z*-BaAp{H%0e~P?4M9U{ zi0+@Ya}6{{PHo^wt)0TwqSPqY;;aXgV%naAhDW{dLmk0ysbgXUM5MPgCGgbjSE;CO z>L4MBRG6qLl|L$J7c@i+JIRC~1WKelkucImg3cdl94(ho-GcZf1o7G$tuyX|+thAz zRuxf4tFd?D2EtMFV48#sr7HGyy6E~?jlriF#%xGBsB9kT=5buiK6#p&wHk-(RI~-Y zP0!GfC?SI!GKhiODJF$DumXvdYRjjBoX#$H>qZCxg^D#M6rtrNe&Ui|g>P8mCm)gI zE@n+m8~x6DQ-vr5wYV7DV`DW(LX`wZ_~M3%^qSup9K{ z%nK#VvjR9&n3BbaA>ueO^%(omuE|wbxDpFR|qsJouWvn`r<(Uc_$Hupw1l z_K_XpYP`6l7PZtY1zwo!;7Uz+xCV%homZwi4K-!n_}EQ2Ec}B4Mxn)3@E6Z7XNPX5 zxgL%S8#j{~_`*m@*bf96aP3O4{L}6z^FQaUg)o+=);7eX$lk7zJapziTcMLcc=yok!r@h1|#z7@l5sL%2Rp4FcJ+q{OmSF4=JR{r0mN z@w}pgDN%r3u%}#?We!(QQ17gg8s9huuL3M|T+L=m88~U=%W2w9ix>Mg(sAMJucU#C zUm9$4BMNF|SqX^6jvk^++xXS5zxruiL?$?sV4I8nI^a{m;4~lH1N3y9HaYUuJRlpN zYbA&#t*5iZSSG&oKU^2cx-G}rs09TnxtW4nzDWH#wLqcH7WF7?}5pa4m z<804pd`6qv9@${?8NoWRV88-&<6%#*8;$*vMEODN>Gx9hUiR?SG80 z6m9Fot*tukwCy|jlo&HjJL1xtBQ2_l4&9_qXPuy*(4tru7@iK6{qd^BF+q{Ae&0ngDMYqd;6>zEkYXI7+EEXPD&lT@mecz(4qJ!>hz5^n<`*% zKzu$2*HklyYc3DEGlm&1SQXOs+LWcrs_+Oq(Wa^&EZzWWKVj^!qmvraB(sH`#4mRo zJ4sA`3Bq7IyQ$M)*H#BSp{S0du69N;-hj+Zg6I^JXaD(i4^#tk?a#F&yo8E}cp5AU zhe#(SqKLlfw`Y%_o+`{tGaHcE)VVd0Za`3fYz%l{FpM8n3OngI+_38TY2vi+yU*LM zr3bbvo}Z9;^zh0Tl`&XJP(dPQES6V)C(Qi~V1Kr`$<&j1CmUsa7=*99%O!8Ul2>d2 z6lgh<(-7|$VKlV;{XBHmDpj(EXm!nJ?zZ7$Xlnub&K@Zg?y&X2Yp%<9yqkVF%eq&V zJqudz*e^gc6v2!~Nq4lq*j@N15kHp@t3ZKA11+WNa^>(O=B6rqDNq*MR&F<%1kE=h z1Y#X8`NALpgU@2bM2)n z;9k#O_=ad0Fttf(DHHUHJ_jQ737@1M${ZW?km+$Fm=6%~wS;zu#&?Nl;}`~g+J%{AJbCJp0E$!|`>G|HUjAEzOe7kRwdle1U3chK zTVr56zScr{e(Z$m|eQA?RmH{prXBUV7{JM?Ht;}{Qj-A<&S6FWWbQ@rX8iRqPM;V?Eji2A@u| zQz&7w!8mi)YwnSK30cLEf1=X|5x*QpFT+zaYv71rK(lC63V!R(;^gMaV)&6 zGK2dplYmZe`PUFlvwnl30P;03BRO4YHQ5HTmB}mwqq#Ky1 zd>V9!vog>bFOT&MRX7A=2sV#P;CQhL0Lq}w*dt@E64HEqIBNgtPQl_<;Mm(@75zC$ zr4v3Pe3dRT-^AHyQ9XUv{zrB4cSDt$2LWd(Zss!Z_8Znb7n)r~&fz#1LQZeIL1Gh2 zr4Ocd_7%*4Rhy5QthSf=B9A*aGdXT*6`+2}L7go*xyN)!?Qay71~A`gll`!@(B&8| z6JzlLX4%<_mqn2;pIi7%#yaXrld6L zIz!p3Xljn5Mm&AjW*JpQx}rb%JXc*{2>&B!>B#+&c+L59t)A6`W3D?fld9||U}jls zxB>Wv=-@;{29S(EV2evBLVW-8(V^l@>ta_FxrC|RRCP=BECXM=F+>QIu^h_k;izj~cEN$#*gDa@G0_Nwb5p_3lm(h7N&ZdghoItRHbr zi+kmxuvI>ljxLuk@G?5%* zAj{STGjG%=q(ZD!^!{@5uj7!T_m}y&CKFJlKY;U^z_BRf-7aDgTJ~N&Z>Ba&j}ee9 zk~>LR967M4DU-?+k<^+*Cl2r@(G;K^vaE=1PtcD|sPc?4I?&4TaMY*9tm;%@Q67-q zkE(|nimGm>HBgQi!S}-gdqG21Wu~{ma-HqO2g>-9iIWV&ObsYcsc9v}=+Hqz6iT*q zg)!C?Zb_b86*8umaV1gq9{|0iP-lm)>5_JR3geNFri*0R$xu`pk)3D|^_F%RKGVl= zFn9-2M8{h5;1DLvNBk#Kt{ z+S3}GycqENQBc|{8&(3aX&kS7yXIxar4%Rv!;GMSIsrN6pQT;*)oC>5x@~=3iJpR~ zVG+|Qxs3J&5s#-f$g21qw3euF)Cpc=WxQXSf&I`mbLwN+oo#!VY814x-CRvyk*^4Y z!-;R+KkG$4Xg;YENl3gvlbYaUFU>|1;C*`U^^$1k2IRdy2HSKAW2 zDMqDw#3*X5<+{-bZ=u9uB{j%V<+4JlBE^8aPp!XzWoK$iscGw0e{W4X#oX29h2?}E{6Iq-v)zZ7WjpI45h$dxQ7Yx8 zb+$vqumTcCV~H-=%1?am-_@A}_T;E&A@_&JOS9y=A{S>#shmKv!XI@_&1`WR<;k4t zqag$y6F)^#&Kn4RorFtv3Xa$$v9(j#$z^x7SV)9kL}^m{;}Kpee@pQrUjnUUdSaI5g5S>s+m^(GCL;UJZfH z=`}6q2&8MrXoSX^u+bI)M#EM(L>-9QuJJc|GLS3bk}g*NnUYhb%NdK1G`3{tShg-3 z3k&pOrBB0W>3c0A&NAbmjHYgZt}~N9oohONcim&2yDj@6a)u1t5dF-i$<9L1P19|0 z@nieAU>NoJfJRQBti4TyKOCbT&xhbwA?>5%PJ47o6!wRhDcs;ptzf4V2$I)Ui28^u zO;@CMYD2Z05&X1MhQ?POtAN-cq+*FBWH7&m2uP za6nw7p!|H!SM$h9M%S=h7G)g-X7bedV4gsjIe?n@_^U$CAfNK8xOa!}%rr$Y5q`qw z98(wuU;qv^m^!cl(b#FcBFTKGBcJQUz|O=&H3`ZQo&>fP6!gg8UQiB^%64is<=8J7 zk2p4fdJo8&bS!z9A6$M0E5c4R4_Ydt!wqMw;0WSG#7#&vYYUhqsf8(m5cL3sE>nZI zG=P@Tg3db2fF7(hJcJHEbSQAon9%~RM~Hy5NL~(Rp>F}OPv31S_>QOnE%L4P)6#0m7JS#6JF_4r7yC2ZVil6=@nEhpPlgiusMJfJiw zYEUE&>vJF3WuU_H2W40CQ0<%z$R<57fk0TKhAggy7`7vqh@Pyxow!m58Z^K{?=lgF zGLta6Q$;KXk2T8U{T9!emshK_({A69rEASTD=q_;EH235n_C!LHf1rY0McB#uz*jhwoK`K$BO$jRbT7iqQFuW$=De+YmxvCAYR4~T05j$c**H|N@u)v z8!(e&YS7WzY6Fq@JNIWPFT7`N==4sm7tuN98->Gc%PYabPT-SaB+P!4^v_q&VHy}$ z3MsK_L1c@>cHW%L&77IGxpe!*nz;Ed=c}b-9Qvt3$O;BTr#P$ z7TQZ8Q`rknE~Q})bPl#|Lx`_}nX(y3%FvY83iMKZ zB{xb^hthY$+!IUXOF7D=x+P+Z_eLP2J#ILm4B{2rN>Hp2GE&6`pDAzX)({D4puH=C_x z$F`5;3X)h291yFPuJWJm1Thh<#F0m@_GI&zfBUaKnMe-t^J_k>Bl_PQ$bJJ~PUpWN z%gKkrZVJatpC9MdrG;&$jDin|=Jn_Yo3l-`ZPJB0__L31;%ZxT^_t-~f0ewynq)4U zos*YC@39aSqc|loQ_=464*Gf~R~~gMJ-rHV#cKG;1Rz|?V}83?pDF#F&+HgXFXw&8 zLI6u(otAL9Vl|POxx|yltuoo1#in^oA{G;!qNHi6^W^{ki z*@bEniXsegFt39v%cOFj3X+uZc|aONPPWnjZJosLk@ASBdVO_+6b=PkOKoTbkG-!k znFGl(uP{mGo6Iwy5_Mr#1I;(`Fung^?1%D$v7=dG?tm5tprZroczi26l}zP)Df~w+ zZDQyOBlz(TL^v}dJlpSzCs3gm3vT@09pzGrHujLy|F8-6#uJlTt#dd?{?_xfg_iG_ zXL#69iZ9d97{bVHkKX+tJIS&=-S0?BA!(g0Yb$V7D`KPN!~F{c*aSl5zH1^%zcI?y zhLy*>5GH-2X-Xuha?TevTQW0@r$Wm)Y%Mk&FEoDX6e8iiH&>IjAy{Sl)|Ga!8X#ID z@@0GM#G21x79L|PXsx$1#}viri}8PU!yd_PQ=SL2)Kc#uF;L_V{o*8*gj>FB{C-L* zh@7A{9%0?M=#ZcF2>p8OHZsqq@byCw3YAPxR z1<6xpxkrI*M0zx|>M{R756&rJI?3~-G@}UHpu4r?S2Y~{zwqepu+w!Zv*vOenYj8P zaC8?@%!81jQVFBuWP4QDWT*G#+*FN0usUcOQqDWW{# z-Gx1IFf9So>WyXs`K)EE(~ORjEdW7L#Xh=t7?pNjX~T>nYgs{2pHxm8FKU|9RS(0$ zFC0uKu4!NB%*UZfLjl{7a48NcE_*$`!>Iwy#*4HT3o!_wjK*y637#o1$moo0saJ}N zUe6v)E$~u(^lf#=$O=)RZZMe|xKdyt`Mma#tRUMXJg-%q;?F|>%O_=Er4+&-J|x_^ z>bceC4zI09jT?)qVsaPYflM#bkq7E&fv3*vg=4W_Lri?;b-VBv2xG zQh>J1@Kgs5P!b$_0p^wZ7c$BvSGKX0;6w^DOqKyy)fk;&F#v4_TudGrtba#=!ITY? z6})T?U8V8I=G8#b+x#=eyuLW@Q*4}96!P=+Zia-tf;|Jlj?4GbE!~~i$GTmf^)IR^ z1l_NnY2^XWeqj*!M5@TEdA*py4PmGPT9yZk;_sp6B3tWigg#lYS`RF!?FIqr5RdEd z+lK0xRW$S}W%(c1;ou+u`uD;#qcd@A!RRi-kVolpjFN{^B8aOE<%u_4UwZe$|Hj$b z+wEKHW#rRb?CMVTsb{Rt-i&g)YI zGgg1!`d;f7?F*=5<4KO7C^Toy;fOSTRN;}i3i?ItkfWC$T?Sw$Pj6g_8ptab z;?M~Mk+}BXJ#+!RsqLKZtfr&eYvnBWHg~9zp?wV}eoyQ;m3dutw1{91o_-VE2lnSzhnIN9GX^b8lOhm8jgtx zq04Q;6nG>)^vR1txa6V)8P+6fv<#ALjRTR*mLy-6F$wxd66_T`f zVOghTu+DVB#O8WThSywj-#d;_0@lLYk6uerGnSvwRZ;je5@qZH82!_Q{s2v57>;H= ziBMwMxx}c|RpyjOLz?Hi<&mp9bR4UIAy!S%A=RbRxoR3(eoiOkK6y&tz`WDI&r5?& z)k97s2Y6pV4Usd|9pLfeemr4g%Z|_Nq?+X5X{hal`q%IO>?))~PP3?TD^pfWw1lYz z_&&?b;n=UdU^FaQ!qoh&{QOESpJwQhPRux0TE`Y#*K57Wc|L~!{OrPj`g5cFiZzliI|-|CZBO{ zz(2!7x;EbS+B%-ADXZ_BkAqaU#%gm17r(3uC`N(&b}a}e&*qQ`gxx1= z8RPe;`=CxOh@R44@KwU}+A&odC<|!4=q)dzS0btp0sjL~!#9I(^n3xa zag=FVGaJtaAPt`|eI(KZlR=u9h~Y``fq^hGk&L8mb6!rm!}jlJYsuU|4R~20eOcB$ zCA20x11NdM?DN-u2xl_~%x0?eWZMDXm5kThas+~VYHmTy_~fbUTx91335>r)HTDzc z4dx9d0;9T`^Mqd?m;mD-YOyNp1z7BOx>SF1DYc~=jj_)l%}ppZppGdgUVT<`t`4=& z)=v=B*#c(pR;u&Qv?ON0Ub+M(o~c~3uu)cT;AyMLN_s2}&Q(K>yZdlTBv5o1Pxgo+ zd*orc$WVzc-P83GQDatOw+#lmC%lIKw7J?Us8LB^)W}*8-?>=Sg$%=KLT;J}zjc`B zo7x-Mp;t&w@<^4tq=iMTyQ5R&GE1aV^csB>mZiAIK zKb52ANeJSewuKSHNF$%Sxj^3QYL&TcA`!O2a;VHOiLG*8wwz4vYw)O4v`0zHOE>8g z@{aqWY{g~yez{(HsFg}`cXUmiaVLWEq_eCanyV$l5$;6j)3+P^)In)ZE?IykeLbfv z8ad@`4_|o8RJ5fNDXM}gHUjCMEN8ab49eWRK;^0%(p68h-+oZ*;^Y3hvr-rA-$C{t z+?%hqjr|8jJ26bA456Ke-m%9-lx!mfwTIUhQL}^ez=x#={YLbzvyPJh>ndqY4qo$` zay`-;R6D$E#V9dz{T<5gWJQ3VZe`E3qh9|nv4ikeR3S#mcLFhSj?Qz}~YHr9w zR_PdZP-^d#E{?@a2d+@Y30;2(%76R1FT%F{@yn~DaLFK8HKb{iAuEmIgamFM$b}=C zX)q7*jDx2?GSUHyGfa4TrIaqug>|uf7=F`Sg?4SRC~3 zg&fNaBMMB`Kr=>vV%eT8HKJ5)p)G8Mw}{jd6@N-3EpNi>np_{X2Pxm%l?*i1i)1;? z1XDJu)J51fXU4*~n4Z%dtI=U^GYj@>ERu&(W1u5RAXiadu3cZg;Dkq1_|^!HgqQaf zXMAFqFq7S%WTkCG2W^O9$6K!xd7ZxTnV*wq5OYg;s&5DTo#BN|LCOob0+MR@nC?nr z)c+`ud2wpsk`du2(5hj7o%$c#c|bmR@{*QB-hKc9Vchdp8P!Gtxjo!rxyoXQ>6;!+ ziOS-V#AmI%L>$&!3?$n7xk#6?36xbDdW#c zxcGu*Cr-G4F)@sy273eu3gRK;bOAPCdT{iIYB;mB^U@_;Jzp=jcgy4^sO?Zod3F&#GE@(f!T?} zrcZA+C(Pf3$A!bOiW`i?US!xi9cLsTGFzKyDT<1q@<1ojTdJ~xG*r=xN$W8MfGljz z@y0mrCqJg zjX?hSU%VWS+fjt8CM1T(q^LfbRM2LG99Kpx(?PD@E%pU3TRVpD`;b9J@TX^`J1mcx z2=U7LnpQ*F314Z>%Q$g8%@@T2ynZepkOYu;+>Bf+P1q*eq}sCJj-lqM{Ne$91Z^w& zZt&dwMZ%pQ?KeC6j*^4#z9>HtvE|>ORYU9R>fM{yte(t12y+YUo5(P;u(@4W^O$9c zVBI6+TRWPz=&G}k$YrptBL?ZP3Ey~s@7S=T_a9{=VRJc!bH_g1p>_?vQ^NomtHZ$n5dyolDHP9+GWNg<3R?yhn2bfU@aEkz z0yJ%7yFmLspLtxfKnD6o=Q*ywz2l$`1nj}kl3etr9{)59TcWS-nUr3b3bR9O^S446 zswaw+G4NtinSTYW01Vt zlq?dg5^`eGklkU95t*3=`Iu{-_qy+rl6MKS?7eK2z^s`_JeEr~ng?sJr-6Sge`R=D zeE;(+fPhS-lN;yk4IinmN2u8vd#EeaFg?#e=K0`_GZt))5Wa66N`fOt1VI5R*?(Wp zN=xk5!N`VC>KJu}(ZB78!SL%1iuFIBhIj+Tj#6u(q3q)h9C`ObyM94i8K+YEQCux% z8%Ig!zf@cE3A@b~vh$Y-c&XxJ|6rZ(y-{H}EwJm^MU*S@F*yV$E^z({yPhjvO(nI~ zfBI?8D$PF!@rGWl@^4|mfOb?Lk=B&vml)?MCev!>lQ6=D?ZvEE6?TGo!BiCwGs7cH z1KQL!5Zyj_Du(Mp8GPq9eGW~s50h1e;FM{ahB=q>n2nJJ8l=B2SdJkH5Fcrv`H=zr z%mdhBns(T@F15%^_EyaFDZjSl^GvGLv_%Vc582}L)D}xy_F^=$l;$m#7pH>FHJ*o< zhr~KjsD}$iJ_erS!rSC{VK1AlF}H;p23A^HToc+9of-eo>ViUr>#L9OV(IB*pBkTN zix<%G#H?s6Evc3r{+O>9yKKb(pDK9=E<_O*sw72&99b`r74?jl;IhkG4GB-ZY@g`JTHzm zp+d&=GkBuLHrjJCAyH6h{4ltb0z}6j2MzK*xby?#v%%W3B8#1ZO@IW)e&M9cX21cT zAzi}={`l#zfBhS#Jz|PG17izPVo~p%W@#KP{S|YL#*LBp2IuEuypE!%xkmPMGivO3 z)fAFv7rU$1kEnqW+tVJHKm_q(pZZK9T5IEm%0uqMHx7H~<+j%ugaDhsIPHcW?hz(k zI4hhAcr{xDZ4YZgXUADd0t$im$1kfnq4*E8j;Qyv@u_1Yz~!}Kwmk=RNit`Vkcy{! znoHZy#M;rvL!LoDLtr|iN{9fwYUhxTLV|k{*A&=y!x);r=@q?w-`g457j4I}hbSjJ zo}jfZ&MX7An9~kN8!E86<=Emk`HwkcC}@{7xw*jK+oy?QNp-?@Ny?dB>N{9_rIG*oPF7jJXBFD3wqP_E_`o{q;K z6)I+mDjh^*`f<=wgxVA&e^y<$z|7N~4MKE5DeY^|MDa zepmtJeG+x+NFxau;7BLx>#zl*59(oOpS5|V4rj|A8q%Jv9P{|Bm3B>eRf15oXkZJf_ZoZe3Yp&U0i)_XAModbUj5K1vtf|U6U&xY+H{G_og0rMWOKC$WbJYclWnlCVAk1;mGjkZ0~wA%PqQ75ij!-W zP@=mfsVE{Z^|O5OZ-k7aR*f59Vwt?PYMa6=4^iMvieY+_AW1x2!iy}uKD~i@C(S?0 zOXE@HiyM;p(lsOmPqPyrcp*cSXt$B`xP#AE(oPCT$(PT$cGe>?t#$l|I((4)=t$ZpBhK)I z-JaP1P1A!ZhGD3i2A3B!Rx$dd96fw$=x$=9=M}s97lB{Q0Pg9Sj?w@w8@XDIT<%#z zKQSE`APNMo!{R_sL{dSQiN2wAq<}k7f7+9b*z(=W2R=6imYqWg^D4T+hw)=@>oVma zFQArXPG`ssUX&6t@q`SFz&Pl#*aNu#M-5ZpS??{Tg0Ml`zWoR~wcr2|A)FByrZV+O z8x*R6WtaiA$?e=qw`^O*@2q%j*L5;SPnSP`_r-XE)cqiO;ln!*_#oN8;fSNk538Sa zcd7bMZ^^x!Z)9<<`bxoyI7$gV==Io3_1$Zpnz&2E6*DIL)CLJZjbp4|u%BpLtoel= zHp5=^U{%*w22Veh#AG=;{g@yhFh_q9UQey` zYRUHYSjNv^e?bu~Z*xA4DP=W{bu6~Y@iX>s&2*XhrC4|td7lUvGJ>oNyzighTH7@u zF!%lK-YCPcgO+`+GZqCCWtn?P!pue$?VNaPA|H9~p7gA#SP=x-3j;0#GjY_|zH-{Z zy>bLqF}A%#K6QrLmvreTpA43l96I-k;;cQzC#2)o=<9u%sye7m*&}f&LVq#X9wg=P zr|eZcEsFLn_DXL?n-_c8&c|NJ#Q;&)55)q4yl>}bmaWtZ%_j#0#xj^IIw2~@r!kLR zc`EKj1aWYu!ruKlF*fb7x@H0TS}5?ylrN?oSS3I)d_wW+8d~_dyXg;``F)1Xah2)Ec7R>qn@&q z8xJ(>)@(I_j9QI+_Ec@Y=9A4WUKCr+xc>hw%;jNr!$7K666ZIdw@_W(gH4tx@HEyA&60ZWj(V=-SR>1tLwWK;HPR<%qsUb^RdFDfF-7-vY2W&W{N@t=e?KW3pwIqPllpfXFX zSl*k7#_lWad2wVWDy-Q1IjJF!%*>Tp&MbqhhIu*GD2GdUfetyR9`K^{Mc%>Xg+Bi>bMi_9KNkFsoB$uRcSL`^9bNNM&Gi&`MCK)q7$1gfXCjQ6~N*C z^^ko!QT+%vc<%h8CYcO8$e9g6KZ=5K>j4*m6+-j#E@=x}Uuo7)(_6Bt1tc|2J2&r& ztc6*M0_ZwzNMIw{x3oAo|A5S)lPACX{Mm;tur**N(f2+*F)gIU^h8FRnVPyb)Ta$y zJI(T^=tn$du`<fk}&uAVoydn2ed;->{^qt#VK8okanl9J zC4cy8S>>Yf^cOiKWvU4^H0rGg!h0d2rNBd%Dp;5N)9SxJee;XcNtg=JQz8OYP?M?f ztB-{P_Y0IZ|vfunK_tdnO>`>(~S$7$RiXkTEe7~?&&YQHO=iv`q?xxK#k3_jo=_V717 zv+>~qdPUAUT2_wVYjY6O>~9yGpv~F}d^mkQNr9ugSCt}1oS|&M0|LT!Hui*?+?63^ z9lbVdIXr0 zOVI}_8nQue;y4SEkPbA1=B`dbs7){FJ!tr-pg`?bgRp_#8sZHB-$r1thWE>C@^57+ zrXC*m2+b`FUVEV)HK7<7*8f)Vfoi=jZ~gL=HAeTPOSkXtj|;eR4L)E#gz0hVbv==| z@8E$pr;M#6G~QWC;D}6}TI_X~7i@cXPh931aJD>JpNlD~%5D{o!gN6p5_ND~n9o7I zcj8}rsLNKkE`N|YELkSli4v(-z$vU#r5Ak~cNa*XX%zsIsdI5u-G-MfQ6Zw3r{DLA{;L}&0S zcLs)cMnkhqc|=RZaO6{Urv;*VMOZZ)91x_N40YyVs;pBY!aJ&Hj?kYH#oHXtJbF! zxjh1O%z}8WS1U}@s)_}p`#A*3SZ;>YGNCJOu*DN4CI1@VI}dOM_V54SN9&U76uIcd z)6h!KGy4$F%N<R)98}X!fe$vZUS?`f&^d937%-%N>f=pGqe;AwDi@G-?isT{Dqt|kD1ThCxH4;T z;}+(5TYbe4F;2&u-zfccS$czh2cLk@+TfJw)#FLiLh~>00W9#;wwGCUA6Z*mvTaF@ z@K@q!2Mdy5(3@2s+J}ru-2`%9AZA-VEm8MCztr-rFN#xQJr^&&|`oZWM-fV^2;hpf)@$**}S zlu!iCg2(zQ#n?GFj7=?k;%AsX-w zSM%Zt&?ChmRRmG71XpW3e}# z>RsTQO(|hTN^2?G6NOwdX)u2!+BxJUph_fKShtaJlBzgG}4+N)x! zRF(my)>>CoDgfo;Kh+LBnZ9}XOA#|Vj_BURm}1gR_t|VB&2d~>C_jttzK1lKMbs&g zD7lx~)-`)6OJp7k0#MS=fJ&4v7Bl&WHE56bxk|i!b&Qsc-T02*z95o?jnLrYAN8Ou z`7dlToXVF6uMyB~Ws1-3CJ=hq!+WlbqDwg9o=gA$m=K4XUj6%#jW+E7h(qqnfvgRL zs5>V9>1pkNZkIS|D*+SiFCbK);qo2x?V` z`{5@oSaq!-4G>hL-?-*TSRo6?`J>LM5*WAMFi)ZBE=%z&;ayx(jVWA{zD#6Q&a<8W5dt*C4WeA#jqS@k9fW*y3c;JmZn zr3SSwRTae!ZP*sZq+^=KGNSh?a9vv8kjV}Asc9*y=$Lm-^s*L%+aP@*hGfN8RAw>$ zumjgWlo)Q~EaiENU!W`}j5iwIntL79^pHAWbA~EKTuo`U&k#=15(GjLq!(7rwvHQ} zIM7}pyB-361h9fXo6Hxb=(mg1iETnl+uYB@9xa6jMDatnxl#gd5%!Gb1FqOS6ZQ~c zIIPBlXYm|!zmNN@W45?4Cx}QZg_J5`66_weML|_jOdMRmX$jqainMNwh@$F~-5yr$ z>m{%K!fZCIG2NQ7g!YIcuG2>MlL&jV>Nc|>N0x7h1pCAhyikB}{Sipy$RvN1hWHMT zT{|6j2^GLphN9aAvt5FIGbN|AadZ{DxI*QBpbH_eWVm@SEVWxi3(4pkryn9UBaZ8U zsQuUSQfI{wf_zX~B|y#4MvKY+Nx%9Y17=P?`{K1TF55j)OdqzqBS%WX!cc%(l=_SP3`A@;eOS_PJf%TQP{BXoBiVMNT_jRss}o>Wa| z?|rWw%qZ9`CAoXI0)`u+Bsp<*O(pgy8cHrw z$ly6MsDY}t#W@$KL`aFi#*xD;zWDsX-$s%@p4gArXQ{V9F@#Ey90StoY8| z1q$a9$7u~8zh67-2xve^zZ7g32V?ae=*#k@m6)x(x!zI>9a zz$9L6O*QplS7ZusM~e*xEjcSl@={7+!UJ$!B+`IeA~9+?&r{&~&`Pxwb<8QPwhZfv zS8H=T%~JY0KSxuIsQwA_;6nq;I{Jk6xaewS5zQM53Gj!Ooha0({1pcCaFbBMFg8-U zujt^~-IPpFL{q@aqudj4`qdZljZCB{Hb?IDNI%mX=p7%EzWx|ma0gQpF_K<%9nRH^DQ7hrgN#VwW{=pp*^z<$>CN!^@a zhj`Er22sZ+t3|1CCut?iS)?6f+_tMxy7XP*I`1Qu(c)$^J9(DVX-Q&?M3Btz>)$Z4 z=9XC&FD@seT9027v9jKFZXS4HvQask$*xKwQC87XQT8(b%)YflI3)l)X0DzQIC_<5 zF%g`1bK7`XZB#H@5kceq3VCWj?GSecR6gqVsD7%g@59($y~GZJ!O?Prscc#Pv06{S z3wrIoVOphY+MQp%=`8@0zah^=JIZF=#tCr&9C2 zT?lB4MCT3jE>xx@GjrWa4a~A5mmWc?2@P0X%Y2&$xeQB{opoP>}K~dx$wx`%qebNM} zUXRyACNgAqNiqOhZqc;}LwV}jN%aGT_Qbza6Iq#3+4<0%)^YYMsO8-%Q?H9xq4gQz zv=-ntxQb=cdR?kPU*mC7N|iwH?Ct5aFuj~aLcIpZ1_fo@Ha|=fNjCf^;k2^PCt!d8bW#qT8CWzv-L_xd^mz!mZzk zfC17VMepMkr9f9LS2!cQNj|a7h20c~dRk5cGWm^*DUHj6jyK9JdXlxg1x~tKoQ69^ z|CZ&`R^<2-8x^#^rEM{c{fHH-v-SOD>!D8NDd*J+J`VY&UVPn-Yauo zyx9v zsDd>Kw-mv^m#B$^g`hV9QU-UgT<(}Ze3DiD==eO4;sT|hDsD~KqhFexxeU$@w`(`0 z!xn_^9{N`{$E9tX$QV-^$`aa=qs#<6?(-*t?c$GTaerz+{F5>0wE;W_U~bF` zDSZP+F)CnQDuyg=y}S^CqP;@gI0uCNvMm;E9biT(-ZYR0_ER=xT1z4R5jlP%11|$f zP|;|}8C8rS>@_cgF%6IB^ggax)tRk7)Z?qO$@?E@`Req8&_q5?W)4(7;^@l=&yR<% z9I)-gkeSgpXb&D#ej$`;h&3o=m86HdKwG(&^OycH1xkn$d>wJ+V*DA)nd}s$q+*Rr z(irKQbc%1=VFqGf9I?rSy&zVr$Q-V0UTt#@#$9J%01QzkbX1mDO;bg-2CfK&23l#w z?g=NwAj{QStg~cuXQ?h;#mFNofckkg*YAVC4I%_tlKo`NIz8X+u*=C z43Q9_7S&d{J-zOTZD%79{w|k;93lMnE^M;bwDTV$6;FyEDk`qB)`(2vtxAB~!*_8p zN=bp8aLn))C5Vw0Kza;UaA7zMGtCR#P@EP6DqL5}*CCbJH^pr?1jd_(GEI&_0;z(h z93lBc5VK4adz!B}12f;C#FQYbzT#hao;*oQ!;(fxmIYLVk>BsXec)}6Ku)fUhg@lw zLW6LI8KGsoRndnf^ECpf8tQhDHWy|3RNF|&;E*UC=nU8`L|F+Z9JdsGNN=~)kIST( zCg9erCliy}4T$q*8J!y)W&DRvNo70_3^Jak7q5%4ZjjdQXW~pDcJ_KaRkHQMJ^_V@V^XOIl#%Aq(3Wz) zzCxeWj}~DUc%NjaX4t8#@0S0N)>u%l!q*xCWQQ3mDv}@JkZ!LR2aI6MPXxtkKA7Wc z2k^w{K_&NzA$Q+8AK;?kM7k+X*d7RmU~^vP$CrefpU?FzzbxJmmoDipsZDJk)NKjz zye{Pt;aq@^wfMQ{S?{pR-;d-GHkmAJROfl+<3j?0HK8UvtE>Ew+67z{>8O+i=uHB8 zLQsV_Bp9FuxJ&~m%rx?L%stQ;@NPwuwG9grAe>v|7RU9Pf4#{ zW~0&fEmz>q+>iDcrr!u~GuEuGxa@#Rgbx2UY(e*KR1g9wx!1_@r}U|R$=ahLxvBMh z$}CS$|FJ#ykO3KSZ!uLt-zxQC=hi55DcOSZQlB;Wg!VC}CxSatD0>D7F9`s^I;(DiVqd9=H~&2E@i2a2(>!r|uCpTI22{D&_6uIBQr#0D=g`Ymg(X2Q+@I{6!hEC_xPc5-Q_jG}Cw zOSn}%9iOr5x&2ezVb1q}xZtK4R}tsE)OWgHp>R(iDwIt-~=n(54F7ViXT>I2;7aDlbgS zb0QCiJfOq?I0Y3hkvPW(jjLgtPm;B;#9t32M6xQNwK%^UtQu0)YX*r|9_wCix?s?l zl#--fA9{>|kOz6x(P(m4Eg#x7mQlIbSmPcI+EvoDk%07?;p5)8Q$+wQ5 zKz7MASq`e9A@`M*m1QFdp|aIBD%#iQgqB5v&lhCF#>q$JedCla8)kpMY0o*L4++Q^ zm6@zGEf0$glQSM-G|Aziz=t|lX_h>MjV7^%g8-%y+ePNIGPbDO-~LW7Ay<{%KhfQPT+Qrduuce=DzBch_o*S+`H+0*xUx>mkGKSq2m$}xpPm{NTSC@F|&=Xw;h+k zA*ZN;tbARG2gN!IxEPTA-1WPA?FEHrOA9 zQ%1M1ujOqKCyCM4(8D&k)gDy}mfKg0Y0eaS^OBwxrmDW^-ad%p3zHV?}zaz9m<(T_JL22ij80^q}PKmm-6dR@x z+r^l^CIY>4flcix<3o*>x5kK9Sw^$FIj(q>yDb+?-omTD#MCg*GP$ z0|MM)4Oh=nD_F*YhrD)()&iO?YvvxZ*R^=?(Yc1z=7Z6{xOK;4eX-~~9PhZ~zWz~B_YSPB%?^~b3@m>Fvros#p61YXTakQkGy z_!sh0;G7xFxOK7LQ5y(O^Gas)C}0P>*qo3vW!%-wF&V6tq-lx!_J++;y1tyWOp2AX z0ji8Izwj4Ii6MP&e;%5c53{FS0)7n*%&A4`)th$#7W?trNe(|8ZQAjTpZ@x`il|YXheNKnV?}f$G8*qQ@zBJ0azpfFy>OB)};|O1F3cCQ~kJgp`cv#ul-lT_{EtDMXQ` z{>lreq6AnZ;WK5jNKt{JkCKSuiVk#s9w2H7$*m zIvf!;OCX11ds)T^jaAZi1W0$#l9U*i=Q_djS)YGL;zz=0z%(fcMNmZBHvN<+PHHFN zUJ?H5uDvu>Eaeu$M{e`3W@PXfZZMJPG73k|0VerPE1W^7PL35xF|(km)6x@xUVx!R zM3E*m0N_h(OKWlA$9)`u8njZ>Bb7yLs5z?ov~+NLohofo#L1f0CF`L|Cl&#Zs#kIs zVJoO_7*xyV!^uzgB8MY`ii_@`^*qo9t92#+5Cr~e9=wz0kRk{na#0u(5E6+CI4!hs zF*Db~8h^b!Dbcn|+K*M+ekt~(*+5!}A1)LGrO0td94PnsZ9-4zNgatK%c{AMGVCcV zHd5@E->MX+jf7!3ooZ{7EVbWIC)VQ}7tml&p)yfRDUiWIr#Ps;V@4>;N?-(0>&w!Q z`i8^r%K2MKj6saUA1Rkl(K)JT-)MxnhP*lJ?dpSd8)cyLm4&tNvugxO+& z5l}#E8(jp?^5mOD{?6;-hH`_$NkATHyTo-Q`E|zDx9r{BqTF!|c$2?vYcnOsS2b~8 z3~-Ji=6(u6DLF*5+hD%-lwxXGP9D(WcXGA12a;@+NkWI^;&A6X? zxOtF4i*hR6zOayPr3M|l;Ajj|Om38#(EK=ICWiE}TNGN@aQPP7&v5s+;3b7?G7MGW zj3l=$vYVWjutS**4&PO78{fitCyR19HFFDb+mcs_VSd|)a4x3<_lLC-DHJmdxwE{^ zHuQAWr1CMaZd?f1kv)b<6cK*Nmu5ip@|Jefk~B*2H&ZHbg6+@<>r& zrcLh1DtdtL3ajySnE+5vzp_-0W!Y_t^=!`gK$>vr`YCDa28y7N*d{*iZ53m5d;C_- zMps5FGL7A}ljUj=-4N~#H`o;s&7$H};LU)p6~rTkrF_?aDctdOX|ok^(k-@Moi=Nz zbfDZ~j*fcPx8Zq5PxpetAYy?((G^8`AEwl071xLG;uwFpr{a~2DR~v%ajR14)-Ebb zh6s36t!VI=JL;b4Ow*XCn1P=6osf)zuxMdj=6bdGXu(9c^!z5cw@Zi>zRw3e^c?hU zmkhzZ8p+NX-v350PU>*sav%tf_Qn=`9ep|u zcSMq!ID#o$>LP}ak`@F~O6rx^zKbY{bxhb>lZRsj~R|JRyg zY%*TAXUjBgh!};h0U=>AJXNdhG0_MQo4P92gtmNwVLrU^?Z_4aCj<>>h9ND{i;m!U zmat#Jp=Dv9GfP>vlH-aDwzt&I(zJc2zdQ|hvcrp$hGER+ywV&5Ck;^pqxu_o6ZrY7 zAsns7*&noLFZO1UGpSWIuv7|n)(VpX=GCmtrFNRGuCHe8^Ek&f4Pw545q`+|ejx5l6v)`zwzWa%$;KYdl}aE* z58>G2L=;K-;r&~n5>6=N&3Ezve`~L1`R$|G?Gj(G=`)Ofb zvti14b1f5UtpA)d!Kmn+PWL2ZdK8UGKxZgJv!ekhCs- zSo82ghoW?31VA;r$zY{JJ#z`nhB)^Pqs+EzYM93Sz!q6q52?{gmaS~>nIWh&j_cDw zU?=alwYb86K&$@MaX)W9g)^LsyQwm_0$cut`|17LLh12DK7|uh1#?;lJ#u4885mDY ze8cp2(3I>LnoI949Z%CVGi5pD6=tY2=zd0V`;s0mOW>Cd^v=gn)CS}s4{IZFu=r8A zc}nl_v%uk##n)~2-Zm>}SFS7{WX}G!yOhAzVA#HC=+;~6J$768FPpx!PdRYsoL(zB zqx0Mt4mfq#cg(GJV4Dgx&bX;blbg<{QK4L!Ia;*1qfx~Zy;9Nmmq&$0cTf|FHYir9 zp&XgDzlg7Y;%3(!;qIvX;$yeR#Vy-c;lhnudj6pv9ieZAH6mv$6T?#;9EV)f zrgIr%d5@0!wKhLjMevKKzCpc>+Xs85Ek8r%O50~E!Zx$NHJww)2x;`0F8IO&t)7HY z7ny>4X&g_qdZ@{TjLEN-K&uA(QuoRDNNeUr`#Jf!O94f=*bd=@zrK17)E4}vMj_sh zI%!Hn*3L#<-+lAYnkXVa=klbvlhC}>Zf+*=*UQik@-hzsTMAU+6ff{C^*27j$sVlf zXYWAdL+aTVw+>?%=1=||tMYiLGM@Nn#Sab-uWx-Dezmxg4~|IQq*hoX&oc{1WGp0Z zd;hyqCM!Fafz({l%IZRmPX3F0Ak@m49 zJIg)l2bY`YLBGizw5)&EDMubsjQ6gWxxc-j7g3&_wWwROLS0QcWmZ-;h+@uvEdesl zC`z(U5cbxJ%ISYdi>W+8_{EqL)r$h;)s8ybUtg}Z-?H9~+Qb1B1WexZUgswpkG@&) z;q~BDH8ebjX{x|slV~MH_?Sy?_bEH^l-lFeO}*N;5nOZ=iVS~Zavik_`ru5B40T-E zN_C@8*@k<;j11LI$L2JFNWS@K`uu`PrA^PQPyOUA0^p~QC^hSGL<*)iS&Ew?zFhE zD@))&2_@m1XXqq0A2QV|O$`?*qGub04Y^liFC-4>5G#LN{jp{y`;LbETf0}isG|lu zh*e{UU?7Ha37lu*2^J|mm^L02XHpS)#B0AVLuoptEHFp|5kLSvL+5woWO;LlK=M5P z;hwL>!F324@DZ37`de^Ahk!_ot@s@7I&G&2H~KIH8X&euQSp^im?{o`ay5nV4)`6* zguq%mNqRFOus2VqGudg{+mIc{Y|9nL)e&CVy|KS5IMZ!wrQ7B$fK0a;UQOV{c!N88Z({*Wt~nfZ+0Mz+38UI zi{x9ij>OHxTWZ#VP$aadin17DD{mF5O;XJt+Cw+ev2%URQZ3*C*7O*&UokxJuNHI6 z=l$XhPv10f8=Zp}4(vCDDo#AHk~R2q#~@!C`HdwrPB~cX;^;>#Kd)TI60Ytw%gUhxy^hwyW~OsSEhDf*GpcdYN1j++i{p8lxmpi@)yO#LQ`0k+QYUXLDD zEEn;K{wDnc2x#f2rxF@OB&C4puv7mR^3nV4sF8p?(P)2PE@NjdUI322Up##)2p@lA z3HMbMVkZvDOV=`BO*-~!9M1B=ags=0&5^pCz1#XaSv`|W$dS*dl*sqvP~X9O;2CZO_Th&(xpjl?0TTCcgtGUlRw{K>=HSb!3MHo+kw~Kl`!PyXxb(+jY{k&lA1clGv>- zu|2lox<-m~Ng1v~%1|9T5Sect$0bCYFC{yJ3Ay5u8tKM4wIoq9@n^NC+uCB2nuR$N{l2=#VpaK#Bpu;gUx~AuEQt0TT@D^WG$RcY#H! zK9u0AIe$>%W1?}?I0e7oL3d1ufqNRyc^xVBya8f`ZjHrtsTHp=NcxOtrEkGBXQ?r>-R^UR7!`#Sq4Di2a0($_hU5wR-eMAD-oMl3)UBS;~1q|0Xt5~@(kd` z`#v9Nlp5Xa#%|omU?$S<44qYqc~LC(GfN{@abCa{Y_Pp3Ui>X^Kqg{bPwz5Dm+wn& zyG!plmk;u$!3{u@l0$TFq#Fdo3EnILAd+p+S-?5CKs)H53*A(8cbiM54;%8smY;ER znravf;P{616u+c_Fz0(lkLqu?-r4c#5n3zgIOMbJqJB&Nk5;HPe02P%>F9g-hSkqn zpSR+Td3>|;t$Voh!VmLRYm@9mhOX&uWou4W6qF=>dU9Mqers8-ytS0GN}iSDA5UD& zvBNBr;&*@r=#kCV1{uCYk7#($`zevrUW?p=95NUTbet!xbH;3Pf(4sT@_X}H@|9k4 zA^(y7l;&xKkl!@P!YKD*y7<0L_1M^^#?{5PZ!^Mc9x<%f)|1J;Dm;Ff-0Zh&{+bds zt{XM41DzZ@4E|~VkYKXkp!%py!JE90Z2&*c5Mwf}D# z=?ua7Fx8NZaCZN9R!siFzV?zoFw)9@=~D?T*u#RJxEjyki@8igi!2TH3vE~(4fNL* z#x`izYu7)Q&*dXMP5l4wzllbP4*e~|fl$c0fz)B`P$7*;f@H*ogIHOU2p9(==V#~W zL;L8ToQeB2VdtS*8uz$WE_9pbD5Da6S#B0}_uc868(NN-L3yX@=3kcQ3SCZDzL^uT z>AJ8<@3yuTOL5NW4^6ONOPcX1w+Sa)@(DR`5w5{wa3z5)_XF^eMYq=1ogw;TF;O)J z0yS?u5oUrYH;7qjl4&Djs>qfQ&aQ&GvL+1WNx+*`M*HJkWF$itbl17>QJ%#*=ig6~ zOeD&rQ)1-@f%_)?AV}XEhC=$%&E2^+n8c{5yYJ-L_!)!_y3*%cPm1D#=!`~k&_2N< zZ@ki%3Z1Bvl4`po>yvZ#Towdck|&rn!0%2~&Jdh!fpcki>_k_nC5*LP&|9o@COJ@f zzX zJBvqBX^TiSatgCPKeNdJE(pdbg~FYZ>}l8u=4(uPAxTG8E8a}zEx;t5#FFd|3=U6i((oD#AhNv?RS`$~BMI0;oa=bz$B9|O@W;f#v|@oo z(G_015#bMk9!xQFLqBR#YntP>vcoYD?u!(jH!M$f^Eu*`^XnaG+yGe;XThWcD zzgTifS3c-gXJ4_by4(K5hed}^GW^?!uJ1kl_n({IIi#7(lYSg=n`fVu#LLizLh)6v zq|!`fwZc3J2+KE;?=TZ+Jcwt2+RI9#JV^q%A`Rio_AAzDKTG1z*jg|RoPOuacmH7e zOSAS_4G}{8dc@lhNpi^|y4!v6?MMd7%ISgw(mF5GdUJ0L3ISG85M}**M(EqAhF|3(n5vtAoco4aJYb{quvIlg*QMu zLG`G%_LAtz?Rg{_gxX|WK}L+MNy=K7tAS6%Iwo7g;ibc$9pG;AG~OiX_RthQ9lK7= zOpff+VZf+hDR7kXTb)kIxh{+*hJms#jPXEbdKbta=&*rd2r2qoSY%tSM)@8qjMzTi zyS@)pN;BRdH59IQ6<^ZV)(6g#O@{flZU1exF{SMkI6^B%5wO9zunSw7!D45t)?WZ9 z=q$pTt>Ca9FuZY^iGqUo=7dK4TKq+KWAEUL0d~0};$b69hMBN=uMPNzJrSw7R*tcK zB~(_j$nsWhOVR6Vi^LMYpQcOpw4k9lCe2{69S5_BcWJ|YiZn1LzQ%2$v^eY$q3p#v zwRjldy8~qWJ|$dB1e&6KIKi5eS?a{5T#+gI3Fv*UNEn@7*tQ2+&nbtVXn?kxV*GMR z`9{Ry$ApjXFjQNA)l03+E3$2>x?9C~9cqur&_Xa~&kXa^0@iIpy(Be&u|*iS6UV(s zt=J&mRj)xkI+dsgrYU)iH?LCXjHZ{z>Abf^znU0l#wVxL&GEr5v(t-j0tkT9Lp~cB ziT{tz{!9pbS*iLIsY3;&6K|7cze0B~Rc2>k!5H`*)@56rL1y+a1d_oKAa zQqnCQ>A}^qMq_$=@~9@?V%NYDE_CE#wK7S79)1X&>95C4VX%da9@YLk+wS{%M6Sj*Xc$wFhcDdd2DE` zS&1AI5oMpjJ(A{W94`mh-kU@aov_LAzzs$D(rrHt+@Dw2?`>Q-))jIqcC)vDkkxu8 zeq+bw1V@S#;7xkKbJW0&apgg-R`$8E8+Kn(ZF{2{ne;W2TGjaWAlfq;P-TCK#t zMNZHI*y=WNBvdGinXd%PG^3n6Kp$6zZlKHk5Gk%}sld=(DYc`(ii-PcYxKff^)JXN z!dx-ZB}n%}&1Dptfy`oZ;0RFomE)kv1;JpgIy7N2S;X0PxIz-pO9j}APRl3e70`23 zP~n%0M&DYDcbKMIK#HP)(3aX=sYGaT&L|dxFA~d~% zZst?2N86^TW~h{nX0KDXF=|QbX@VCZ!Tn2>+YINA&M?i=DvIs^+Y4x!v@134O;$#W zuV{>9HQ#uYV9ot^G|#uAnuq31+%&-Y1CL}{D-asEY1UC2%5ofmnXqDWI|aMpngnUU zhnX-l$|#vwy2sQ~J_Y!{R3!kq6Bux2Jot8X7}rMjkmLh08@JtB;4uOK%D9wto5apU zKZ3JZ)B<+nR~?Pu)233a!}uiM)*alJiPyhK=-e7NGBKvzFlvH`@iU`&%FrS{^C3%` z*zpOAJOQk2nBH!LFv%uq{Uv#xqxR0!uCcK(1;gimmuL z_L13F9Sxb81&5npV2@dC%{l7x>3!Q2{0ql`a!LRf0vd%th6;s&7OE8v99Tv^tOx*z zcgG<5t|A@Oq9#R;BwmUe9zlu$S>g@GI2+0IUe8R$9YeYm4cw)-sck@D)U%|#_ zou$mgxaIn5`2!ZceszMeWb=&sN@n~@@132zsiVx^*h0$IoSm8XvkKT`=hoX$?XmHR zVC998s?pi$Y9mhvR@a2`#CuWXjxLYyKcqdJ@fi)>Nd*$bFRvL&e_U5TQe(s2tmOQ} z>^n*S{VL=d3qDL_s!9R$v}Zu*w3t$F!b8qHT+AnC=`feP+KfYnwKp TQ0x~v^_`","access":[{"value":"public","label":"Public"},{"value":"protected","label":"Protected"}],"toolbarLinks":[{"id":"fields","label":"Fields"},{"id":"properties","label":"Properties"},{"id":"methods","label":"Methods"},{"id":"events","label":"Events"}],"sidebar":[{"n":"/","l":"Welcome","s":""},{"n":"quick-start","l":"Quick Start","s":""},{"n":"bindings","l":"Write C Bindings","s":""},{"n":"bindings-cpp","l":"Write C++ Bindings","s":""},{"n":"features","l":"Features","c":false,"i":[{"n":"basic","l":"Basic Features","s":""},{"n":"differences","l":"Comparison with C​Python","s":""},{"n":"debugging","l":"Debugging","s":""},{"n":"profiling","l":"Profiling","s":""},{"n":"threading","l":"Threading","s":""},{"n":"ub","l":"Undefined Behaviour","s":""}],"s":""},{"n":"c-api","l":"C-​API","c":false,"i":[{"n":"introduction","l":"Introduction","s":""},{"n":"functions","l":"Functions","s":""}],"s":""},{"n":"modules","l":"Modules","c":false,"i":[{"n":"array2d","l":"array​2​d","s":""},{"n":"base64","l":"base​64","s":""},{"n":"bisect","s":""},{"n":"cmath","s":""},{"n":"collections","s":""},{"n":"colorcvt","s":""},{"n":"cute_png","l":"cute_​png","s":""},{"n":"dataclasses","s":""},{"n":"datetime","s":""},{"n":"easing","s":""},{"n":"enum","s":""},{"n":"functools","s":""},{"n":"gc","s":""},{"n":"heapq","s":""},{"n":"importlib","s":""},{"n":"json","s":""},{"n":"libhv","s":""},{"n":"lz4","l":"lz​4","s":""},{"n":"math","s":""},{"n":"operator","s":""},{"n":"pickle","s":""},{"n":"pkpy","s":""},{"n":"random","s":""},{"n":"sys","s":""},{"n":"time","s":""},{"n":"traceback","s":""},{"n":"typing","s":""},{"n":"unicodedata","s":""},{"n":"vmath","s":""}],"s":""},{"n":"gsoc2025","l":"G​So​C 2025","c":false,"i":[{"n":"guide","l":"Application Guide","s":""},{"n":"ideas","l":"Project Ideas","s":""}]},{"n":"gsoc2024","l":"G​So​C 2024","c":false,"i":[{"n":"guide","l":"Application Guide","s":""},{"n":"ideas","l":"Project Ideas","s":""}]},{"n":"coding-style-guide","l":"Coding Style Guide","s":""},{"n":"performance","l":"Performance","s":""},{"n":"license","l":"License","s":""}],"search":{"mode":0,"minChars":2,"maxResults":20,"placeholder":"Search","hotkeys":["k"],"noResultsFoundMsg":"Sorry, no results found.","autodetect":true,"languages":[0],"preload":false},"resources":{"History_Title_Label":"History","History_ClearLink_Label":"Clear","History_NoHistory_Label":"No history items","API_AccessFilter_Label":"Access","API_ParameterSection_Label":"PARAMETERS","API_SignatureSection_Label":"SIGNATURE","API_CopyHint_Label":"Copy","API_CopyNameHint_Label":"Copy name","API_CopyLinkHint_Label":"Copy link","API_CopiedAckHint_Label":"Copied!","API_MoreOverloads_Label":"more","API_MoreDropdownItems_Label":"More","API_OptionalParameter_Label":"optional","API_DefaultParameterValue_Label":"Default value","API_InheritedFilter_Label":"Inherited","Search_Input_Placeholder":"Search","Toc_Contents_Label":"Contents","Toc_RelatedClasses_Label":"Related Classes","History_JustNowTime_Label":"just now","History_AgoTime_Label":"ago","History_YearTime_Label":"y","History_MonthTime_Label":"mo","History_DayTime_Label":"d","History_HourTime_Label":"h","History_MinuteTime_Label":"m","History_SecondTime_Label":"s","Text_Light":"Light","Text_Dark":"Dark","Text_System":"System"},"navIcons":{"mode":"all"}}; diff --git a/resources/js/lunr.js b/resources/js/lunr.js new file mode 100644 index 00000000..47da4f62 --- /dev/null +++ b/resources/js/lunr.js @@ -0,0 +1,39 @@ +/*! Retype v3.11.0 | retype.com | Copyright 2025. Retype, Inc. All rights reserved. */ + +/*! For license information please see lunr.js.LICENSE.txt */ +(()=>{var e={1336:(e,t,r)=>{var i,n;!function(){var s,o,a,u,l,c,h,d,f,p,y,m,g,x,v,w,Q,k,S,b,E,L,P,T,O,I,R,F,_,N,j=function(e){var t=new j.Builder;return t.pipeline.add(j.trimmer,j.stopWordFilter,j.stemmer),t.searchPipeline.add(j.stemmer),e.call(t,t),t.build()};j.version="2.3.9",j.utils={},j.utils.warn=(s=this,function(e){s.console&&console.warn&&console.warn(e)}),j.utils.asString=function(e){return null==e?"":e.toString()},j.utils.clone=function(e){if(null==e)return e;for(var t=Object.create(null),r=Object.keys(e),i=0;i0){var u=j.utils.clone(t)||{};u.position=[o,a],u.index=n.length,n.push(new j.Token(r.slice(o,s),u))}o=s+1}}return n},j.tokenizer.separator=/[\s\-]+/,j.Pipeline=function(){this._stack=[]},j.Pipeline.registeredFunctions=Object.create(null),j.Pipeline.registerFunction=function(e,t){t in this.registeredFunctions&&j.utils.warn("Overwriting existing registered function: "+t),e.label=t,j.Pipeline.registeredFunctions[e.label]=e},j.Pipeline.warnIfFunctionNotRegistered=function(e){e.label&&e.label in this.registeredFunctions||j.utils.warn("Function is not registered with pipeline. This may cause problems when serialising the index.\n",e)},j.Pipeline.load=function(e){var t=new j.Pipeline;return e.forEach((function(e){var r=j.Pipeline.registeredFunctions[e];if(!r)throw new Error("Cannot load unregistered function: "+e);t.add(r)})),t},j.Pipeline.prototype.add=function(){Array.prototype.slice.call(arguments).forEach((function(e){j.Pipeline.warnIfFunctionNotRegistered(e),this._stack.push(e)}),this)},j.Pipeline.prototype.after=function(e,t){j.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");r+=1,this._stack.splice(r,0,t)},j.Pipeline.prototype.before=function(e,t){j.Pipeline.warnIfFunctionNotRegistered(t);var r=this._stack.indexOf(e);if(-1==r)throw new Error("Cannot find existingFn");this._stack.splice(r,0,t)},j.Pipeline.prototype.remove=function(e){var t=this._stack.indexOf(e);-1!=t&&this._stack.splice(t,1)},j.Pipeline.prototype.run=function(e){for(var t=this._stack.length,r=0;r1&&(se&&(r=n),s!=e);)i=r-t,n=t+Math.floor(i/2),s=this.elements[2*n];return s==e||s>e?2*n:sa?l+=2:o==a&&(t+=r[u+1]*i[l+1],u+=2,l+=2);return t},j.Vector.prototype.similarity=function(e){return this.dot(e)/this.magnitude()||0},j.Vector.prototype.toArray=function(){for(var e=new Array(this.elements.length/2),t=1,r=0;t0){var s,o=n.str.charAt(0);o in n.node.edges?s=n.node.edges[o]:(s=new j.TokenSet,n.node.edges[o]=s),1==n.str.length&&(s.final=!0),i.push({node:s,editsRemaining:n.editsRemaining,str:n.str.slice(1)})}if(0!=n.editsRemaining){if("*"in n.node.edges)var a=n.node.edges["*"];else a=new j.TokenSet,n.node.edges["*"]=a;if(0==n.str.length&&(a.final=!0),i.push({node:a,editsRemaining:n.editsRemaining-1,str:n.str}),n.str.length>1&&i.push({node:n.node,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)}),1==n.str.length&&(n.node.final=!0),n.str.length>=1){if("*"in n.node.edges)var u=n.node.edges["*"];else u=new j.TokenSet,n.node.edges["*"]=u;1==n.str.length&&(u.final=!0),i.push({node:u,editsRemaining:n.editsRemaining-1,str:n.str.slice(1)})}if(n.str.length>1){var l,c=n.str.charAt(0),h=n.str.charAt(1);h in n.node.edges?l=n.node.edges[h]:(l=new j.TokenSet,n.node.edges[h]=l),1==n.str.length&&(l.final=!0),i.push({node:l,editsRemaining:n.editsRemaining-1,str:c+n.str.slice(2)})}}}return r},j.TokenSet.fromString=function(e){for(var t=new j.TokenSet,r=t,i=0,n=e.length;i=e;t--){var r=this.uncheckedNodes[t],i=r.child.toString();i in this.minimizedNodes?r.parent.edges[r.char]=this.minimizedNodes[i]:(r.child._str=i,this.minimizedNodes[i]=r.child),this.uncheckedNodes.pop()}},j.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},j.Index.prototype.search=function(e){return this.query((function(t){new j.QueryParser(e,t).parse()}))},j.Index.prototype.query=function(e){for(var t=new j.Query(this.fields),r=Object.create(null),i=Object.create(null),n=Object.create(null),s=Object.create(null),o=Object.create(null),a=0;a1?1:e},j.Builder.prototype.k1=function(e){this._k1=e},j.Builder.prototype.add=function(e,t){var r=e[this._ref],i=Object.keys(this._fields);this._documents[r]=t||{},this.documentCount+=1;for(var n=0;n=this.length)return j.QueryLexer.EOS;var e=this.str.charAt(this.pos);return this.pos+=1,e},j.QueryLexer.prototype.width=function(){return this.pos-this.start},j.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},j.QueryLexer.prototype.backup=function(){this.pos-=1},j.QueryLexer.prototype.acceptDigitRun=function(){var e,t;do{t=(e=this.next()).charCodeAt(0)}while(t>47&&t<58);e!=j.QueryLexer.EOS&&this.backup()},j.QueryLexer.prototype.more=function(){return this.pos1&&(e.backup(),e.emit(j.QueryLexer.TERM)),e.ignore(),e.more())return j.QueryLexer.lexText},j.QueryLexer.lexEditDistance=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(j.QueryLexer.EDIT_DISTANCE),j.QueryLexer.lexText},j.QueryLexer.lexBoost=function(e){return e.ignore(),e.acceptDigitRun(),e.emit(j.QueryLexer.BOOST),j.QueryLexer.lexText},j.QueryLexer.lexEOS=function(e){e.width()>0&&e.emit(j.QueryLexer.TERM)},j.QueryLexer.termSeparator=j.tokenizer.separator,j.QueryLexer.lexText=function(e){for(;;){var t=e.next();if(t==j.QueryLexer.EOS)return j.QueryLexer.lexEOS;if(92!=t.charCodeAt(0)){if(":"==t)return j.QueryLexer.lexField;if("~"==t)return e.backup(),e.width()>0&&e.emit(j.QueryLexer.TERM),j.QueryLexer.lexEditDistance;if("^"==t)return e.backup(),e.width()>0&&e.emit(j.QueryLexer.TERM),j.QueryLexer.lexBoost;if("+"==t&&1===e.width())return e.emit(j.QueryLexer.PRESENCE),j.QueryLexer.lexText;if("-"==t&&1===e.width())return e.emit(j.QueryLexer.PRESENCE),j.QueryLexer.lexText;if(t.match(j.QueryLexer.termSeparator))return j.QueryLexer.lexTerm}else e.escapeCharacter()}},j.QueryParser=function(e,t){this.lexer=new j.QueryLexer(e),this.query=t,this.currentClause={},this.lexemeIdx=0},j.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var e=j.QueryParser.parseClause;e;)e=e(this);return this.query},j.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},j.QueryParser.prototype.consumeLexeme=function(){var e=this.peekLexeme();return this.lexemeIdx+=1,e},j.QueryParser.prototype.nextClause=function(){var e=this.currentClause;this.query.clause(e),this.currentClause={}},j.QueryParser.parseClause=function(e){var t=e.peekLexeme();if(null!=t)switch(t.type){case j.QueryLexer.PRESENCE:return j.QueryParser.parsePresence;case j.QueryLexer.FIELD:return j.QueryParser.parseField;case j.QueryLexer.TERM:return j.QueryParser.parseTerm;default:var r="expected either a field or a term, found "+t.type;throw t.str.length>=1&&(r+=" with value '"+t.str+"'"),new j.QueryParseError(r,t.start,t.end)}},j.QueryParser.parsePresence=function(e){var t=e.consumeLexeme();if(null!=t){switch(t.str){case"-":e.currentClause.presence=j.Query.presence.PROHIBITED;break;case"+":e.currentClause.presence=j.Query.presence.REQUIRED;break;default:var r="unrecognised presence operator'"+t.str+"'";throw new j.QueryParseError(r,t.start,t.end)}var i=e.peekLexeme();if(null==i)throw r="expecting term or field, found nothing",new j.QueryParseError(r,t.start,t.end);switch(i.type){case j.QueryLexer.FIELD:return j.QueryParser.parseField;case j.QueryLexer.TERM:return j.QueryParser.parseTerm;default:throw r="expecting term or field, found '"+i.type+"'",new j.QueryParseError(r,i.start,i.end)}}},j.QueryParser.parseField=function(e){var t=e.consumeLexeme();if(null!=t){if(-1==e.query.allFields.indexOf(t.str)){var r=e.query.allFields.map((function(e){return"'"+e+"'"})).join(", "),i="unrecognised field '"+t.str+"', possible fields: "+r;throw new j.QueryParseError(i,t.start,t.end)}e.currentClause.fields=[t.str];var n=e.peekLexeme();if(null==n)throw i="expecting term, found nothing",new j.QueryParseError(i,t.start,t.end);if(n.type===j.QueryLexer.TERM)return j.QueryParser.parseTerm;throw i="expecting term, found '"+n.type+"'",new j.QueryParseError(i,n.start,n.end)}},j.QueryParser.parseTerm=function(e){var t=e.consumeLexeme();if(null!=t){e.currentClause.term=t.str.toLowerCase(),-1!=t.str.indexOf("*")&&(e.currentClause.usePipeline=!1);var r=e.peekLexeme();if(null!=r)switch(r.type){case j.QueryLexer.TERM:return e.nextClause(),j.QueryParser.parseTerm;case j.QueryLexer.FIELD:return e.nextClause(),j.QueryParser.parseField;case j.QueryLexer.EDIT_DISTANCE:return j.QueryParser.parseEditDistance;case j.QueryLexer.BOOST:return j.QueryParser.parseBoost;case j.QueryLexer.PRESENCE:return e.nextClause(),j.QueryParser.parsePresence;default:var i="Unexpected lexeme type '"+r.type+"'";throw new j.QueryParseError(i,r.start,r.end)}else e.nextClause()}},j.QueryParser.parseEditDistance=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="edit distance must be numeric";throw new j.QueryParseError(i,t.start,t.end)}e.currentClause.editDistance=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case j.QueryLexer.TERM:return e.nextClause(),j.QueryParser.parseTerm;case j.QueryLexer.FIELD:return e.nextClause(),j.QueryParser.parseField;case j.QueryLexer.EDIT_DISTANCE:return j.QueryParser.parseEditDistance;case j.QueryLexer.BOOST:return j.QueryParser.parseBoost;case j.QueryLexer.PRESENCE:return e.nextClause(),j.QueryParser.parsePresence;default:throw i="Unexpected lexeme type '"+n.type+"'",new j.QueryParseError(i,n.start,n.end)}else e.nextClause()}},j.QueryParser.parseBoost=function(e){var t=e.consumeLexeme();if(null!=t){var r=parseInt(t.str,10);if(isNaN(r)){var i="boost must be numeric";throw new j.QueryParseError(i,t.start,t.end)}e.currentClause.boost=r;var n=e.peekLexeme();if(null!=n)switch(n.type){case j.QueryLexer.TERM:return e.nextClause(),j.QueryParser.parseTerm;case j.QueryLexer.FIELD:return e.nextClause(),j.QueryParser.parseField;case j.QueryLexer.EDIT_DISTANCE:return j.QueryParser.parseEditDistance;case j.QueryLexer.BOOST:return j.QueryParser.parseBoost;case j.QueryLexer.PRESENCE:return e.nextClause(),j.QueryParser.parsePresence;default:throw i="Unexpected lexeme type '"+n.type+"'",new j.QueryParseError(i,n.start,n.end)}else e.nextClause()}},void 0===(n="function"==typeof(i=function(){return j})?i.call(t,r,t,e):i)||(e.exports=n)}()}},t={};function r(i){var n=t[i];if(void 0!==n)return n.exports;var s=t[i]={exports:{}};return e[i](s,s.exports,r),s.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var i in t)r.o(t,i)&&!r.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};(()=>{"use strict";r.r(i),r.d(i,{default:()=>s});var e=r(1336),t=r.n(e),n=function(){return n=Object.assign||function(e){for(var t,r=1,i=arguments.length;r=i&&(e-=i,t[e>>3]&1<<(7&e)))return this.cursor++,!0}return!1},in_grouping_b:function(t,i,s){if(this.cursor>this.limit_backward){var e=r.charCodeAt(this.cursor-1);if(e<=s&&e>=i&&(e-=i,t[e>>3]&1<<(7&e)))return this.cursor--,!0}return!1},out_grouping:function(t,i,s){if(this.cursors||e>3]&1<<(7&e)))return this.cursor++,!0}return!1},out_grouping_b:function(t,i,s){if(this.cursor>this.limit_backward){var e=r.charCodeAt(this.cursor-1);if(e>s||e>3]&1<<(7&e)))return this.cursor--,!0}return!1},eq_s:function(t,i){if(this.limit-this.cursor>1),f=0,l=o0||e==s||c)break;c=!0}}for(;;){var _=t[s];if(o>=_.s_size){if(this.cursor=n+_.s_size,!_.method)return _.result;var b=_.method();if(this.cursor=n+_.s_size,b)return _.result}if((s=_.substring_i)<0)return 0}},find_among_b:function(t,i){for(var s=0,e=i,n=this.cursor,u=this.limit_backward,o=0,h=0,c=!1;;){for(var a=s+(e-s>>1),f=0,l=o=0;m--){if(n-l==u){f=-1;break}if(f=r.charCodeAt(n-1-l)-_.s[m])break;l++}if(f<0?(e=a,h=l):(s=a,o=l),e-s<=1){if(s>0||e==s||c)break;c=!0}}for(;;){var _=t[s];if(o>=_.s_size){if(this.cursor=n-_.s_size,!_.method)return _.result;var b=_.method();if(this.cursor=n-_.s_size,b)return _.result}if((s=_.substring_i)<0)return 0}},replace_s:function(t,i,s){var e=s.length-(i-t),n=r.substring(0,t),u=r.substring(i);return r=n+s+u,this.limit+=e,this.cursor>=i?this.cursor+=e:this.cursor>t&&(this.cursor=t),e},slice_check:function(){if(this.bra<0||this.bra>this.ket||this.ket>this.limit||this.limit>r.length)throw"faulty slice operation"},slice_from:function(r){this.slice_check(),this.replace_s(this.bra,this.ket,r)},slice_del:function(){this.slice_from("")},insert:function(r,t,i){var s=this.replace_s(r,t,i);r<=this.bra&&(this.bra+=s),r<=this.ket&&(this.ket+=s)},slice_to:function(){return this.slice_check(),r.substring(this.bra,this.ket)},eq_v_b:function(r){return this.eq_s_b(r.length,r)}}}},r.trimmerSupport={generateTrimmer:function(r){var t=new RegExp("^[^"+r+"]+"),i=new RegExp("[^"+r+"]+$");return function(r){return"function"==typeof r.update?r.update(function(r){return r.replace(t,"").replace(i,"")}):r.replace(t,"").replace(i,"")}}}}});}).call({lunr: x});});window.__DOCS_LUNR__.default.init(function(x){(function(){/*! + * Lunr languages, `French` language + * https://github.com/MihaiValentin/lunr-languages + * + * Copyright 2014, Mihai Valentin + * http://www.mozilla.org/MPL/ + */ +/*! + * based on + * Snowball JavaScript Library v0.3 + * http://code.google.com/p/urim/ + * http://snowball.tartarus.org/ + * + * Copyright 2010, Oleg Mazko + * http://www.mozilla.org/MPL/ + */ + +!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");e.fr=function(){this.pipeline.reset(),this.pipeline.add(e.fr.trimmer,e.fr.stopWordFilter,e.fr.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.fr.stemmer))},e.fr.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.fr.trimmer=e.trimmerSupport.generateTrimmer(e.fr.wordCharacters),e.Pipeline.registerFunction(e.fr.trimmer,"trimmer-fr"),e.fr.stemmer=function(){var r=e.stemmerSupport.Among,s=e.stemmerSupport.SnowballProgram,i=new function(){function e(e,r,s){return!(!W.eq_s(1,e)||(W.ket=W.cursor,!W.in_grouping(F,97,251)))&&(W.slice_from(r),W.cursor=s,!0)}function i(e,r,s){return!!W.eq_s(1,e)&&(W.ket=W.cursor,W.slice_from(r),W.cursor=s,!0)}function n(){for(var r,s;;){if(r=W.cursor,W.in_grouping(F,97,251)){if(W.bra=W.cursor,s=W.cursor,e("u","U",r))continue;if(W.cursor=s,e("i","I",r))continue;if(W.cursor=s,i("y","Y",r))continue}if(W.cursor=r,W.bra=r,!e("y","Y",r)){if(W.cursor=r,W.eq_s(1,"q")&&(W.bra=W.cursor,i("u","U",r)))continue;if(W.cursor=r,r>=W.limit)return;W.cursor++}}}function t(){for(;!W.in_grouping(F,97,251);){if(W.cursor>=W.limit)return!0;W.cursor++}for(;!W.out_grouping(F,97,251);){if(W.cursor>=W.limit)return!0;W.cursor++}return!1}function u(){var e=W.cursor;if(q=W.limit,g=q,p=q,W.in_grouping(F,97,251)&&W.in_grouping(F,97,251)&&W.cursor=W.limit){W.cursor=q;break}W.cursor++}while(!W.in_grouping(F,97,251))}q=W.cursor,W.cursor=e,t()||(g=W.cursor,t()||(p=W.cursor))}function o(){for(var e,r;;){if(r=W.cursor,W.bra=r,!(e=W.find_among(h,4)))break;switch(W.ket=W.cursor,e){case 1:W.slice_from("i");break;case 2:W.slice_from("u");break;case 3:W.slice_from("y");break;case 4:if(W.cursor>=W.limit)return;W.cursor++}}}function c(){return q<=W.cursor}function a(){return g<=W.cursor}function l(){return p<=W.cursor}function w(){var e,r;if(W.ket=W.cursor,e=W.find_among_b(C,43)){switch(W.bra=W.cursor,e){case 1:if(!l())return!1;W.slice_del();break;case 2:if(!l())return!1;W.slice_del(),W.ket=W.cursor,W.eq_s_b(2,"ic")&&(W.bra=W.cursor,l()?W.slice_del():W.slice_from("iqU"));break;case 3:if(!l())return!1;W.slice_from("log");break;case 4:if(!l())return!1;W.slice_from("u");break;case 5:if(!l())return!1;W.slice_from("ent");break;case 6:if(!c())return!1;if(W.slice_del(),W.ket=W.cursor,e=W.find_among_b(z,6))switch(W.bra=W.cursor,e){case 1:l()&&(W.slice_del(),W.ket=W.cursor,W.eq_s_b(2,"at")&&(W.bra=W.cursor,l()&&W.slice_del()));break;case 2:l()?W.slice_del():a()&&W.slice_from("eux");break;case 3:l()&&W.slice_del();break;case 4:c()&&W.slice_from("i")}break;case 7:if(!l())return!1;if(W.slice_del(),W.ket=W.cursor,e=W.find_among_b(y,3))switch(W.bra=W.cursor,e){case 1:l()?W.slice_del():W.slice_from("abl");break;case 2:l()?W.slice_del():W.slice_from("iqU");break;case 3:l()&&W.slice_del()}break;case 8:if(!l())return!1;if(W.slice_del(),W.ket=W.cursor,W.eq_s_b(2,"at")&&(W.bra=W.cursor,l()&&(W.slice_del(),W.ket=W.cursor,W.eq_s_b(2,"ic")))){W.bra=W.cursor,l()?W.slice_del():W.slice_from("iqU");break}break;case 9:W.slice_from("eau");break;case 10:if(!a())return!1;W.slice_from("al");break;case 11:if(l())W.slice_del();else{if(!a())return!1;W.slice_from("eux")}break;case 12:if(!a()||!W.out_grouping_b(F,97,251))return!1;W.slice_del();break;case 13:return c()&&W.slice_from("ant"),!1;case 14:return c()&&W.slice_from("ent"),!1;case 15:return r=W.limit-W.cursor,W.in_grouping_b(F,97,251)&&c()&&(W.cursor=W.limit-r,W.slice_del()),!1}return!0}return!1}function f(){var e,r;if(W.cursor=q){if(s=W.limit_backward,W.limit_backward=q,W.ket=W.cursor,e=W.find_among_b(P,7))switch(W.bra=W.cursor,e){case 1:if(l()){if(i=W.limit-W.cursor,!W.eq_s_b(1,"s")&&(W.cursor=W.limit-i,!W.eq_s_b(1,"t")))break;W.slice_del()}break;case 2:W.slice_from("i");break;case 3:W.slice_del();break;case 4:W.eq_s_b(2,"gu")&&W.slice_del()}W.limit_backward=s}}function b(){var e=W.limit-W.cursor;W.find_among_b(U,5)&&(W.cursor=W.limit-e,W.ket=W.cursor,W.cursor>W.limit_backward&&(W.cursor--,W.bra=W.cursor,W.slice_del()))}function d(){for(var e,r=1;W.out_grouping_b(F,97,251);)r--;if(r<=0){if(W.ket=W.cursor,e=W.limit-W.cursor,!W.eq_s_b(1,"é")&&(W.cursor=W.limit-e,!W.eq_s_b(1,"è")))return;W.bra=W.cursor,W.slice_from("e")}}function k(){if(!w()&&(W.cursor=W.limit,!f()&&(W.cursor=W.limit,!m())))return W.cursor=W.limit,void _();W.cursor=W.limit,W.ket=W.cursor,W.eq_s_b(1,"Y")?(W.bra=W.cursor,W.slice_from("i")):(W.cursor=W.limit,W.eq_s_b(1,"ç")&&(W.bra=W.cursor,W.slice_from("c")))}var p,g,q,v=[new r("col",-1,-1),new r("par",-1,-1),new r("tap",-1,-1)],h=[new r("",-1,4),new r("I",0,1),new r("U",0,2),new r("Y",0,3)],z=[new r("iqU",-1,3),new r("abl",-1,3),new r("Ièr",-1,4),new r("ièr",-1,4),new r("eus",-1,2),new r("iv",-1,1)],y=[new r("ic",-1,2),new r("abil",-1,1),new r("iv",-1,3)],C=[new r("iqUe",-1,1),new r("atrice",-1,2),new r("ance",-1,1),new r("ence",-1,5),new r("logie",-1,3),new r("able",-1,1),new r("isme",-1,1),new r("euse",-1,11),new r("iste",-1,1),new r("ive",-1,8),new r("if",-1,8),new r("usion",-1,4),new r("ation",-1,2),new r("ution",-1,4),new r("ateur",-1,2),new r("iqUes",-1,1),new r("atrices",-1,2),new r("ances",-1,1),new r("ences",-1,5),new r("logies",-1,3),new r("ables",-1,1),new r("ismes",-1,1),new r("euses",-1,11),new r("istes",-1,1),new r("ives",-1,8),new r("ifs",-1,8),new r("usions",-1,4),new r("ations",-1,2),new r("utions",-1,4),new r("ateurs",-1,2),new r("ments",-1,15),new r("ements",30,6),new r("issements",31,12),new r("ités",-1,7),new r("ment",-1,15),new r("ement",34,6),new r("issement",35,12),new r("amment",34,13),new r("emment",34,14),new r("aux",-1,10),new r("eaux",39,9),new r("eux",-1,1),new r("ité",-1,7)],x=[new r("ira",-1,1),new r("ie",-1,1),new r("isse",-1,1),new r("issante",-1,1),new r("i",-1,1),new r("irai",4,1),new r("ir",-1,1),new r("iras",-1,1),new r("ies",-1,1),new r("îmes",-1,1),new r("isses",-1,1),new r("issantes",-1,1),new r("îtes",-1,1),new r("is",-1,1),new r("irais",13,1),new r("issais",13,1),new r("irions",-1,1),new r("issions",-1,1),new r("irons",-1,1),new r("issons",-1,1),new r("issants",-1,1),new r("it",-1,1),new r("irait",21,1),new r("issait",21,1),new r("issant",-1,1),new r("iraIent",-1,1),new r("issaIent",-1,1),new r("irent",-1,1),new r("issent",-1,1),new r("iront",-1,1),new r("ît",-1,1),new r("iriez",-1,1),new r("issiez",-1,1),new r("irez",-1,1),new r("issez",-1,1)],I=[new r("a",-1,3),new r("era",0,2),new r("asse",-1,3),new r("ante",-1,3),new r("ée",-1,2),new r("ai",-1,3),new r("erai",5,2),new r("er",-1,2),new r("as",-1,3),new r("eras",8,2),new r("âmes",-1,3),new r("asses",-1,3),new r("antes",-1,3),new r("âtes",-1,3),new r("ées",-1,2),new r("ais",-1,3),new r("erais",15,2),new r("ions",-1,1),new r("erions",17,2),new r("assions",17,3),new r("erons",-1,2),new r("ants",-1,3),new r("és",-1,2),new r("ait",-1,3),new r("erait",23,2),new r("ant",-1,3),new r("aIent",-1,3),new r("eraIent",26,2),new r("èrent",-1,2),new r("assent",-1,3),new r("eront",-1,2),new r("ât",-1,3),new r("ez",-1,2),new r("iez",32,2),new r("eriez",33,2),new r("assiez",33,3),new r("erez",32,2),new r("é",-1,2)],P=[new r("e",-1,3),new r("Ière",0,2),new r("ière",0,2),new r("ion",-1,1),new r("Ier",-1,2),new r("ier",-1,2),new r("ë",-1,4)],U=[new r("ell",-1,-1),new r("eill",-1,-1),new r("enn",-1,-1),new r("onn",-1,-1),new r("ett",-1,-1)],F=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,128,130,103,8,5],S=[1,65,20,0,0,0,0,0,0,0,0,0,0,0,0,0,128],W=new s;this.setCurrent=function(e){W.setCurrent(e)},this.getCurrent=function(){return W.getCurrent()},this.stem=function(){var e=W.cursor;return n(),W.cursor=e,u(),W.limit_backward=e,W.cursor=W.limit,k(),W.cursor=W.limit,b(),W.cursor=W.limit,d(),W.cursor=W.limit_backward,o(),!0}};return function(e){return"function"==typeof e.update?e.update(function(e){return i.setCurrent(e),i.stem(),i.getCurrent()}):(i.setCurrent(e),i.stem(),i.getCurrent())}}(),e.Pipeline.registerFunction(e.fr.stemmer,"stemmer-fr"),e.fr.stopWordFilter=e.generateStopWordFilter("ai aie aient aies ait as au aura aurai auraient aurais aurait auras aurez auriez aurions aurons auront aux avaient avais avait avec avez aviez avions avons ayant ayez ayons c ce ceci celà ces cet cette d dans de des du elle en es est et eu eue eues eurent eus eusse eussent eusses eussiez eussions eut eux eûmes eût eûtes furent fus fusse fussent fusses fussiez fussions fut fûmes fût fûtes ici il ils j je l la le les leur leurs lui m ma mais me mes moi mon même n ne nos notre nous on ont ou par pas pour qu que quel quelle quelles quels qui s sa sans se sera serai seraient serais serait seras serez seriez serions serons seront ses soi soient sois soit sommes son sont soyez soyons suis sur t ta te tes toi ton tu un une vos votre vous y à étaient étais était étant étiez étions été étée étées étés êtes".split(" ")),e.Pipeline.registerFunction(e.fr.stopWordFilter,"stopWordFilter-fr")}});}).call({lunr: x});});window.__DOCS_LUNR__.default.init(function(x){(function(){/*! + * Lunr languages, `Dutch` language + * https://github.com/MihaiValentin/lunr-languages + * + * Copyright 2014, Mihai Valentin + * http://www.mozilla.org/MPL/ + */ +/*! + * based on + * Snowball JavaScript Library v0.3 + * http://code.google.com/p/urim/ + * http://snowball.tartarus.org/ + * + * Copyright 2010, Oleg Mazko + * http://www.mozilla.org/MPL/ + */ + +!function(r,e){"function"==typeof define&&define.amd?define(e):"object"==typeof exports?module.exports=e():e()(r.lunr)}(this,function(){return function(r){if(void 0===r)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===r.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");r.nl=function(){this.pipeline.reset(),this.pipeline.add(r.nl.trimmer,r.nl.stopWordFilter,r.nl.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(r.nl.stemmer))},r.nl.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",r.nl.trimmer=r.trimmerSupport.generateTrimmer(r.nl.wordCharacters),r.Pipeline.registerFunction(r.nl.trimmer,"trimmer-nl"),r.nl.stemmer=function(){var e=r.stemmerSupport.Among,i=r.stemmerSupport.SnowballProgram,n=new function(){function r(){for(var r,e,i,o=C.cursor;;){if(C.bra=C.cursor,r=C.find_among(b,11))switch(C.ket=C.cursor,r){case 1:C.slice_from("a");continue;case 2:C.slice_from("e");continue;case 3:C.slice_from("i");continue;case 4:C.slice_from("o");continue;case 5:C.slice_from("u");continue;case 6:if(C.cursor>=C.limit)break;C.cursor++;continue}break}for(C.cursor=o,C.bra=o,C.eq_s(1,"y")?(C.ket=C.cursor,C.slice_from("Y")):C.cursor=o;;)if(e=C.cursor,C.in_grouping(q,97,232)){if(i=C.cursor,C.bra=i,C.eq_s(1,"i"))C.ket=C.cursor,C.in_grouping(q,97,232)&&(C.slice_from("I"),C.cursor=e);else if(C.cursor=i,C.eq_s(1,"y"))C.ket=C.cursor,C.slice_from("Y"),C.cursor=e;else if(n(e))break}else if(n(e))break}function n(r){return C.cursor=r,r>=C.limit||(C.cursor++,!1)}function o(){_=C.limit,d=_,t()||(_=C.cursor,_<3&&(_=3),t()||(d=C.cursor))}function t(){for(;!C.in_grouping(q,97,232);){if(C.cursor>=C.limit)return!0;C.cursor++}for(;!C.out_grouping(q,97,232);){if(C.cursor>=C.limit)return!0;C.cursor++}return!1}function s(){for(var r;;)if(C.bra=C.cursor,r=C.find_among(p,3))switch(C.ket=C.cursor,r){case 1:C.slice_from("y");break;case 2:C.slice_from("i");break;case 3:if(C.cursor>=C.limit)return;C.cursor++}}function u(){return _<=C.cursor}function c(){return d<=C.cursor}function a(){var r=C.limit-C.cursor;C.find_among_b(g,3)&&(C.cursor=C.limit-r,C.ket=C.cursor,C.cursor>C.limit_backward&&(C.cursor--,C.bra=C.cursor,C.slice_del()))}function l(){var r;w=!1,C.ket=C.cursor,C.eq_s_b(1,"e")&&(C.bra=C.cursor,u()&&(r=C.limit-C.cursor,C.out_grouping_b(q,97,232)&&(C.cursor=C.limit-r,C.slice_del(),w=!0,a())))}function m(){var r;u()&&(r=C.limit-C.cursor,C.out_grouping_b(q,97,232)&&(C.cursor=C.limit-r,C.eq_s_b(3,"gem")||(C.cursor=C.limit-r,C.slice_del(),a())))}function f(){var r,e,i,n,o,t,s=C.limit-C.cursor;if(C.ket=C.cursor,r=C.find_among_b(h,5))switch(C.bra=C.cursor,r){case 1:u()&&C.slice_from("heid");break;case 2:m();break;case 3:u()&&C.out_grouping_b(j,97,232)&&C.slice_del()}if(C.cursor=C.limit-s,l(),C.cursor=C.limit-s,C.ket=C.cursor,C.eq_s_b(4,"heid")&&(C.bra=C.cursor,c()&&(e=C.limit-C.cursor,C.eq_s_b(1,"c")||(C.cursor=C.limit-e,C.slice_del(),C.ket=C.cursor,C.eq_s_b(2,"en")&&(C.bra=C.cursor,m())))),C.cursor=C.limit-s,C.ket=C.cursor,r=C.find_among_b(k,6))switch(C.bra=C.cursor,r){case 1:if(c()){if(C.slice_del(),i=C.limit-C.cursor,C.ket=C.cursor,C.eq_s_b(2,"ig")&&(C.bra=C.cursor,c()&&(n=C.limit-C.cursor,!C.eq_s_b(1,"e")))){C.cursor=C.limit-n,C.slice_del();break}C.cursor=C.limit-i,a()}break;case 2:c()&&(o=C.limit-C.cursor,C.eq_s_b(1,"e")||(C.cursor=C.limit-o,C.slice_del()));break;case 3:c()&&(C.slice_del(),l());break;case 4:c()&&C.slice_del();break;case 5:c()&&w&&C.slice_del()}C.cursor=C.limit-s,C.out_grouping_b(z,73,232)&&(t=C.limit-C.cursor,C.find_among_b(v,4)&&C.out_grouping_b(q,97,232)&&(C.cursor=C.limit-t,C.ket=C.cursor,C.cursor>C.limit_backward&&(C.cursor--,C.bra=C.cursor,C.slice_del())))}var d,_,w,b=[new e("",-1,6),new e("á",0,1),new e("ä",0,1),new e("é",0,2),new e("ë",0,2),new e("í",0,3),new e("ï",0,3),new e("ó",0,4),new e("ö",0,4),new e("ú",0,5),new e("ü",0,5)],p=[new e("",-1,3),new e("I",0,2),new e("Y",0,1)],g=[new e("dd",-1,-1),new e("kk",-1,-1),new e("tt",-1,-1)],h=[new e("ene",-1,2),new e("se",-1,3),new e("en",-1,2),new e("heden",2,1),new e("s",-1,3)],k=[new e("end",-1,1),new e("ig",-1,2),new e("ing",-1,1),new e("lijk",-1,3),new e("baar",-1,4),new e("bar",-1,5)],v=[new e("aa",-1,-1),new e("ee",-1,-1),new e("oo",-1,-1),new e("uu",-1,-1)],q=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,128],z=[1,0,0,17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,128],j=[17,67,16,1,0,0,0,0,0,0,0,0,0,0,0,0,128],C=new i;this.setCurrent=function(r){C.setCurrent(r)},this.getCurrent=function(){return C.getCurrent()},this.stem=function(){var e=C.cursor;return r(),C.cursor=e,o(),C.limit_backward=e,C.cursor=C.limit,f(),C.cursor=C.limit_backward,s(),!0}};return function(r){return"function"==typeof r.update?r.update(function(r){return n.setCurrent(r),n.stem(),n.getCurrent()}):(n.setCurrent(r),n.stem(),n.getCurrent())}}(),r.Pipeline.registerFunction(r.nl.stemmer,"stemmer-nl"),r.nl.stopWordFilter=r.generateStopWordFilter(" aan al alles als altijd andere ben bij daar dan dat de der deze die dit doch doen door dus een eens en er ge geen geweest haar had heb hebben heeft hem het hier hij hoe hun iemand iets ik in is ja je kan kon kunnen maar me meer men met mij mijn moet na naar niet niets nog nu of om omdat onder ons ook op over reeds te tegen toch toen tot u uit uw van veel voor want waren was wat werd wezen wie wil worden wordt zal ze zelf zich zij zijn zo zonder zou".split(" ")),r.Pipeline.registerFunction(r.nl.stopWordFilter,"stopWordFilter-nl")}});}).call({lunr: x});});window.__DOCS_LUNR__.default.init(function(x){(function(){!function(e,t){"function"==typeof define&&define.amd?define(t):"object"==typeof exports?module.exports=t():t()(e.lunr)}(this,function(){return function(e){e.multiLanguage=function(){for(var t=Array.prototype.slice.call(arguments),i=t.join("-"),r="",n=[],s=[],p=0;p{var t={2851:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.BLANK_URL=e.relativeFirstCharacters=e.whitespaceEscapeCharsRegex=e.urlSchemeRegex=e.ctrlCharactersRegex=e.htmlCtrlEntityRegex=e.htmlEntitiesRegex=e.invalidProtocolRegex=void 0,e.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im,e.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g,e.htmlCtrlEntityRegex=/&(newline|tab);/gi,e.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,e.urlSchemeRegex=/^.+(:|:)/gim,e.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g,e.relativeFirstCharacters=[".","/"],e.BLANK_URL="about:blank"},7967:(t,e,n)=>{"use strict";e.N=void 0;var r=n(2851);function i(t){try{return decodeURIComponent(t)}catch(e){return t}}e.N=function(t){if(!t)return r.BLANK_URL;var e,n,a=i(t.trim());do{e=(a=i(a=(n=a,n.replace(r.ctrlCharactersRegex,"").replace(r.htmlEntitiesRegex,(function(t,e){return String.fromCharCode(e)}))).replace(r.htmlCtrlEntityRegex,"").replace(r.ctrlCharactersRegex,"").replace(r.whitespaceEscapeCharsRegex,"").trim())).match(r.ctrlCharactersRegex)||a.match(r.htmlEntitiesRegex)||a.match(r.htmlCtrlEntityRegex)||a.match(r.whitespaceEscapeCharsRegex)}while(e&&e.length>0);var s=a;if(!s)return r.BLANK_URL;if(function(t){return r.relativeFirstCharacters.indexOf(t[0])>-1}(s))return s;var o=s.trimStart(),l=o.match(r.urlSchemeRegex);if(!l)return s;var c=l[0].toLowerCase().trim();if(r.invalidProtocolRegex.test(c))return r.BLANK_URL;var h=o.replace(/\\/g,"/");if("mailto:"===c||c.includes("://"))return h;if("http:"===c||"https:"===c){if(!function(t){return URL.canParse(t)}(h))return r.BLANK_URL;var u=new URL(h);return u.protocol=u.protocol.toLowerCase(),u.hostname=u.hostname.toLowerCase(),u.toString()}return h}},4182:function(t,e,n){var r;r=function(t){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.i=function(t){return t},n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=7)}([function(e,n){e.exports=t},function(t,e,n){"use strict";var r=n(0).FDLayoutConstants;function i(){}for(var a in r)i[a]=r[a];i.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,i.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,i.DEFAULT_COMPONENT_SEPERATION=60,i.TILE=!0,i.TILING_PADDING_VERTICAL=10,i.TILING_PADDING_HORIZONTAL=10,i.TREE_REDUCTION_ON_INCREMENTAL=!1,t.exports=i},function(t,e,n){"use strict";var r=n(0).FDLayoutEdge;function i(t,e,n){r.call(this,t,e,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];t.exports=i},function(t,e,n){"use strict";var r=n(0).LGraph;function i(t,e,n){r.call(this,t,e,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];t.exports=i},function(t,e,n){"use strict";var r=n(0).LGraphManager;function i(t){r.call(this,t)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];t.exports=i},function(t,e,n){"use strict";var r=n(0).FDLayoutNode,i=n(0).IMath;function a(t,e,n,i){r.call(this,t,e,n,i)}for(var s in a.prototype=Object.create(r.prototype),r)a[s]=r[s];a.prototype.move=function(){var t=this.graphManager.getLayout();this.displacementX=t.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=t.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementX=t.coolingFactor*t.maxNodeDisplacement*i.sign(this.displacementX)),Math.abs(this.displacementY)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementY=t.coolingFactor*t.maxNodeDisplacement*i.sign(this.displacementY)),null==this.child||0==this.child.getNodes().length?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),t.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},a.prototype.propogateDisplacementToChildren=function(t,e){for(var n,r=this.getChild().getNodes(),i=0;i0)this.positionNodesRadially(t);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var e=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter((function(t){return e.has(t)}));this.graphManager.setAllNodesToApplyGravitation(n),this.positionNodesRandomly()}}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},v.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished){if(!(this.prunedNodesAll.length>0))return!0;this.isTreeGrowing=!0}if(this.totalIterations%c.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged()){if(!(this.prunedNodesAll.length>0))return!0;this.isTreeGrowing=!0}this.coolingCycle++,0==this.layoutQuality?this.coolingAdjuster=this.coolingCycle:1==this.layoutQuality&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-Math.pow(this.coolingCycle,Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0)if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),e=this.nodesWithGravity.filter((function(e){return t.has(e)}));this.graphManager.setAllNodesToApplyGravitation(e),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=c.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0;this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=c.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var n=!this.isTreeGrowing&&!this.isGrowthFinished,r=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(n,r),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},v.prototype.getPositionsData=function(){for(var t=this.graphManager.getAllNodes(),e={},n=0;n1)for(o=0;or&&(r=Math.floor(s.y)),a=Math.floor(s.x+l.DEFAULT_COMPONENT_SEPERATION)}this.transform(new d(h.WORLD_CENTER_X-s.x/2,h.WORLD_CENTER_Y-s.y/2))},v.radialLayout=function(t,e,n){var r=Math.max(this.maxDiagonalInTree(t),l.DEFAULT_RADIAL_SEPARATION);v.branchRadialLayout(e,null,0,359,0,r);var i=m.calculateBounds(t),a=new y;a.setDeviceOrgX(i.getMinX()),a.setDeviceOrgY(i.getMinY()),a.setWorldOrgX(n.x),a.setWorldOrgY(n.y);for(var s=0;s1;){var y=m[0];m.splice(0,1);var x=h.indexOf(y);x>=0&&h.splice(x,1),g--,u--}d=null!=e?(h.indexOf(m[0])+1)%g:0;for(var b=Math.abs(r-n)/u,w=d;p!=u;w=++w%g){var k=h[w].getOtherEnd(t);if(k!=e){var T=(n+p*b)%360,_=(T+b)%360;v.branchRadialLayout(k,t,T,_,i+a,a),p++}}},v.maxDiagonalInTree=function(t){for(var e=g.MIN_VALUE,n=0;ne&&(e=r)}return e},v.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},v.prototype.groupZeroDegreeMembers=function(){var t=this,e={};this.memberGroups={},this.idToDummyNode={};for(var n=[],r=this.graphManager.getAllNodes(),i=0;i1){var r="DummyCompound_"+n;t.memberGroups[r]=e[n];var i=e[n][0].getParent(),a=new s(t.graphManager);a.id=r,a.paddingLeft=i.paddingLeft||0,a.paddingRight=i.paddingRight||0,a.paddingBottom=i.paddingBottom||0,a.paddingTop=i.paddingTop||0,t.idToDummyNode[r]=a;var o=t.getGraphManager().add(t.newGraph(),a),l=i.getChild();l.add(a);for(var c=0;c=0;t--){var e=this.compoundOrder[t],n=e.id,r=e.paddingLeft,i=e.paddingTop;this.adjustLocations(this.tiledMemberPack[n],e.rect.x,e.rect.y,r,i)}},v.prototype.repopulateZeroDegreeMembers=function(){var t=this,e=this.tiledZeroDegreePack;Object.keys(e).forEach((function(n){var r=t.idToDummyNode[n],i=r.paddingLeft,a=r.paddingTop;t.adjustLocations(e[n],r.rect.x,r.rect.y,i,a)}))},v.prototype.getToBeTiled=function(t){var e=t.id;if(null!=this.toBeTiled[e])return this.toBeTiled[e];var n=t.getChild();if(null==n)return this.toBeTiled[e]=!1,!1;for(var r=n.getNodes(),i=0;i0)return this.toBeTiled[e]=!1,!1;if(null!=a.getChild()){if(!this.getToBeTiled(a))return this.toBeTiled[e]=!1,!1}else this.toBeTiled[a.id]=!1}return this.toBeTiled[e]=!0,!0},v.prototype.getNodeDegree=function(t){t.id;for(var e=t.getEdges(),n=0,r=0;rl&&(l=h.rect.height)}n+=l+t.verticalPadding}},v.prototype.tileCompoundMembers=function(t,e){var n=this;this.tiledMemberPack=[],Object.keys(t).forEach((function(r){var i=e[r];n.tiledMemberPack[r]=n.tileNodes(t[r],i.paddingLeft+i.paddingRight),i.rect.width=n.tiledMemberPack[r].width,i.rect.height=n.tiledMemberPack[r].height}))},v.prototype.tileNodes=function(t,e){var n={rows:[],rowWidth:[],rowHeight:[],width:0,height:e,verticalPadding:l.TILING_PADDING_VERTICAL,horizontalPadding:l.TILING_PADDING_HORIZONTAL};t.sort((function(t,e){return t.rect.width*t.rect.height>e.rect.width*e.rect.height?-1:t.rect.width*t.rect.height0&&(a+=t.horizontalPadding),t.rowWidth[n]=a,t.width0&&(s+=t.verticalPadding);var o=0;s>t.rowHeight[n]&&(o=t.rowHeight[n],t.rowHeight[n]=s,o=t.rowHeight[n]-o),t.height+=o,t.rows[n].push(e)},v.prototype.getShortestRowIndex=function(t){for(var e=-1,n=Number.MAX_VALUE,r=0;rn&&(e=r,n=t.rowWidth[r]);return e},v.prototype.canAddHorizontal=function(t,e,n){var r=this.getShortestRowIndex(t);if(r<0)return!0;var i=t.rowWidth[r];if(i+t.horizontalPadding+e<=t.width)return!0;var a,s,o=0;return t.rowHeight[r]0&&(o=n+t.verticalPadding-t.rowHeight[r]),a=t.width-i>=e+t.horizontalPadding?(t.height+o)/(i+e+t.horizontalPadding):(t.height+o)/t.width,o=n+t.verticalPadding,(s=t.widtha&&e!=n){r.splice(-1,1),t.rows[n].push(i),t.rowWidth[e]=t.rowWidth[e]-a,t.rowWidth[n]=t.rowWidth[n]+a,t.width=t.rowWidth[instance.getLongestRowIndex(t)];for(var s=Number.MIN_VALUE,o=0;os&&(s=r[o].height);e>0&&(s+=t.verticalPadding);var l=t.rowHeight[e]+t.rowHeight[n];t.rowHeight[e]=s,t.rowHeight[n]0)for(var h=i;h<=a;h++)l[0]+=this.grid[h][s-1].length+this.grid[h][s].length-1;if(a0)for(h=s;h<=o;h++)l[3]+=this.grid[i-1][h].length+this.grid[i][h].length-1;for(var u,d,p=g.MAX_VALUE,f=0;f0&&(s=n.getGraphManager().add(n.newGraph(),a),this.processChildrenList(s,u,n))}},u.prototype.stop=function(){return this.stopped=!0,this};var p=function(t){t("layout","cose-bilkent",u)};"undefined"!=typeof cytoscape&&p(cytoscape),t.exports=p}])},t.exports=r(n(4182))},4867:function(t,e,n){var r;r=function(t){return(()=>{"use strict";var e={658:t=>{t.exports=null!=Object.assign?Object.assign.bind(Object):function(t){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;r{var r=function(t,e){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return function(t,e){var n=[],r=!0,i=!1,a=void 0;try{for(var s,o=t[Symbol.iterator]();!(r=(s=o.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(t){i=!0,a=t}finally{try{!r&&o.return&&o.return()}finally{if(i)throw a}}return n}(t,e);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=n(140).layoutBase.LinkedList,a={getTopMostNodes:function(t){for(var e={},n=0;n0&&c.merge(t)}));for(var h=0;h1){c=o[0],h=c.connectedEdges().length,o.forEach((function(t){t.connectedEdges().length0&&r.set("dummy"+(r.size+1),p),g},relocateComponent:function(t,e,n){if(!n.fixedNodeConstraint){var i=Number.POSITIVE_INFINITY,a=Number.NEGATIVE_INFINITY,s=Number.POSITIVE_INFINITY,o=Number.NEGATIVE_INFINITY;if("draft"==n.quality){var l=!0,c=!1,h=void 0;try{for(var u,d=e.nodeIndexes[Symbol.iterator]();!(l=(u=d.next()).done);l=!0){var p=u.value,g=r(p,2),f=g[0],m=g[1],y=n.cy.getElementById(f);if(y){var v=y.boundingBox(),x=e.xCoords[m]-v.w/2,b=e.xCoords[m]+v.w/2,w=e.yCoords[m]-v.h/2,k=e.yCoords[m]+v.h/2;xa&&(a=b),wo&&(o=k)}}}catch(t){c=!0,h=t}finally{try{!l&&d.return&&d.return()}finally{if(c)throw h}}var T=t.x-(a+i)/2,_=t.y-(o+s)/2;e.xCoords=e.xCoords.map((function(t){return t+T})),e.yCoords=e.yCoords.map((function(t){return t+_}))}else{Object.keys(e).forEach((function(t){var n=e[t],r=n.getRect().x,l=n.getRect().x+n.getRect().width,c=n.getRect().y,h=n.getRect().y+n.getRect().height;ra&&(a=l),co&&(o=h)}));var E=t.x-(a+i)/2,S=t.y-(o+s)/2;Object.keys(e).forEach((function(t){var n=e[t];n.setCenter(n.getCenterX()+E,n.getCenterY()+S)}))}}},calcBoundingBox:function(t,e,n,r){for(var i=Number.MAX_SAFE_INTEGER,a=Number.MIN_SAFE_INTEGER,s=Number.MAX_SAFE_INTEGER,o=Number.MIN_SAFE_INTEGER,l=void 0,c=void 0,h=void 0,u=void 0,d=t.descendants().not(":parent"),p=d.length,g=0;g(l=e[r.get(f.id())]-f.width()/2)&&(i=l),a<(c=e[r.get(f.id())]+f.width()/2)&&(a=c),s>(h=n[r.get(f.id())]-f.height()/2)&&(s=h),o<(u=n[r.get(f.id())]+f.height()/2)&&(o=u)}var m={};return m.topLeftX=i,m.topLeftY=s,m.width=a-i,m.height=o-s,m},calcParentsWithoutChildren:function(t,e){var n=t.collection();return e.nodes(":parent").forEach((function(t){var e=!1;t.children().forEach((function(t){"none"!=t.css("display")&&(e=!0)})),e||n.merge(t)})),n}};t.exports=a},816:(t,e,n)=>{var r=n(548),i=n(140).CoSELayout,a=n(140).CoSENode,s=n(140).layoutBase.PointD,o=n(140).layoutBase.DimensionD,l=n(140).layoutBase.LayoutConstants,c=n(140).layoutBase.FDLayoutConstants,h=n(140).CoSEConstants;t.exports={coseLayout:function(t,e){var n=t.cy,u=t.eles,d=u.nodes(),p=u.edges(),g=void 0,f=void 0,m=void 0,y={};t.randomize&&(g=e.nodeIndexes,f=e.xCoords,m=e.yCoords);var v=function(t){return"function"==typeof t},x=function(t,e){return v(t)?t(e):t},b=r.calcParentsWithoutChildren(n,u);null!=t.nestingFactor&&(h.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=c.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=t.nestingFactor),null!=t.gravity&&(h.DEFAULT_GRAVITY_STRENGTH=c.DEFAULT_GRAVITY_STRENGTH=t.gravity),null!=t.numIter&&(h.MAX_ITERATIONS=c.MAX_ITERATIONS=t.numIter),null!=t.gravityRange&&(h.DEFAULT_GRAVITY_RANGE_FACTOR=c.DEFAULT_GRAVITY_RANGE_FACTOR=t.gravityRange),null!=t.gravityCompound&&(h.DEFAULT_COMPOUND_GRAVITY_STRENGTH=c.DEFAULT_COMPOUND_GRAVITY_STRENGTH=t.gravityCompound),null!=t.gravityRangeCompound&&(h.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=c.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=t.gravityRangeCompound),null!=t.initialEnergyOnIncremental&&(h.DEFAULT_COOLING_FACTOR_INCREMENTAL=c.DEFAULT_COOLING_FACTOR_INCREMENTAL=t.initialEnergyOnIncremental),null!=t.tilingCompareBy&&(h.TILING_COMPARE_BY=t.tilingCompareBy),"proof"==t.quality?l.QUALITY=2:l.QUALITY=0,h.NODE_DIMENSIONS_INCLUDE_LABELS=c.NODE_DIMENSIONS_INCLUDE_LABELS=l.NODE_DIMENSIONS_INCLUDE_LABELS=t.nodeDimensionsIncludeLabels,h.DEFAULT_INCREMENTAL=c.DEFAULT_INCREMENTAL=l.DEFAULT_INCREMENTAL=!t.randomize,h.ANIMATE=c.ANIMATE=l.ANIMATE=t.animate,h.TILE=t.tile,h.TILING_PADDING_VERTICAL="function"==typeof t.tilingPaddingVertical?t.tilingPaddingVertical.call():t.tilingPaddingVertical,h.TILING_PADDING_HORIZONTAL="function"==typeof t.tilingPaddingHorizontal?t.tilingPaddingHorizontal.call():t.tilingPaddingHorizontal,h.DEFAULT_INCREMENTAL=c.DEFAULT_INCREMENTAL=l.DEFAULT_INCREMENTAL=!0,h.PURE_INCREMENTAL=!t.randomize,l.DEFAULT_UNIFORM_LEAF_NODE_SIZES=t.uniformNodeDimensions,"transformed"==t.step&&(h.TRANSFORM_ON_CONSTRAINT_HANDLING=!0,h.ENFORCE_CONSTRAINTS=!1,h.APPLY_LAYOUT=!1),"enforced"==t.step&&(h.TRANSFORM_ON_CONSTRAINT_HANDLING=!1,h.ENFORCE_CONSTRAINTS=!0,h.APPLY_LAYOUT=!1),"cose"==t.step&&(h.TRANSFORM_ON_CONSTRAINT_HANDLING=!1,h.ENFORCE_CONSTRAINTS=!1,h.APPLY_LAYOUT=!0),"all"==t.step&&(t.randomize?h.TRANSFORM_ON_CONSTRAINT_HANDLING=!0:h.TRANSFORM_ON_CONSTRAINT_HANDLING=!1,h.ENFORCE_CONSTRAINTS=!0,h.APPLY_LAYOUT=!0),t.fixedNodeConstraint||t.alignmentConstraint||t.relativePlacementConstraint?h.TREE_REDUCTION_ON_INCREMENTAL=!1:h.TREE_REDUCTION_ON_INCREMENTAL=!0;var w=new i,k=w.newGraphManager();return function t(e,n,i,l){for(var c=n.length,h=0;h0&&t(i.getGraphManager().add(i.newGraph(),p),d,i,l)}}(k.addRoot(),r.getTopMostNodes(d),w,t),function(e,n,r){for(var i=0,a=0,s=0;s0?h.DEFAULT_EDGE_LENGTH=c.DEFAULT_EDGE_LENGTH=i/a:v(t.idealEdgeLength)?h.DEFAULT_EDGE_LENGTH=c.DEFAULT_EDGE_LENGTH=50:h.DEFAULT_EDGE_LENGTH=c.DEFAULT_EDGE_LENGTH=t.idealEdgeLength,h.MIN_REPULSION_DIST=c.MIN_REPULSION_DIST=c.DEFAULT_EDGE_LENGTH/10,h.DEFAULT_RADIAL_SEPARATION=c.DEFAULT_EDGE_LENGTH)}(w,k,p),function(t,e){e.fixedNodeConstraint&&(t.constraints.fixedNodeConstraint=e.fixedNodeConstraint),e.alignmentConstraint&&(t.constraints.alignmentConstraint=e.alignmentConstraint),e.relativePlacementConstraint&&(t.constraints.relativePlacementConstraint=e.relativePlacementConstraint)}(w,t),w.runLayout(),y}}},212:(t,e,n)=>{var r=function(){function t(t,e){for(var n=0;n0)if(u){var d=a.getTopMostNodes(t.eles.nodes());if((l=a.connectComponents(e,t.eles,d)).forEach((function(t){var e=t.boundingBox();c.push({x:e.x1+e.w/2,y:e.y1+e.h/2})})),t.randomize&&l.forEach((function(e){t.eles=e,r.push(s(t))})),"default"==t.quality||"proof"==t.quality){var p=e.collection();if(t.tile){var g=new Map,f=0,m={nodeIndexes:g,xCoords:[],yCoords:[]},y=[];if(l.forEach((function(t,e){0==t.edges().length&&(t.nodes().forEach((function(e,n){p.merge(t.nodes()[n]),e.isParent()||(m.nodeIndexes.set(t.nodes()[n].id(),f++),m.xCoords.push(t.nodes()[0].position().x),m.yCoords.push(t.nodes()[0].position().y))})),y.push(e))})),p.length>1){var v=p.boundingBox();c.push({x:v.x1+v.w/2,y:v.y1+v.h/2}),l.push(p),r.push(m);for(var x=y.length-1;x>=0;x--)l.splice(y[x],1),r.splice(y[x],1),c.splice(y[x],1)}}l.forEach((function(e,n){t.eles=e,i.push(o(t,r[n])),a.relocateComponent(c[n],i[n],t)}))}else l.forEach((function(e,n){a.relocateComponent(c[n],r[n],t)}));var b=new Set;if(l.length>1){var w=[],k=n.filter((function(t){return"none"==t.css("display")}));l.forEach((function(e,n){var s=void 0;if("draft"==t.quality&&(s=r[n].nodeIndexes),e.nodes().not(k).length>0){var o={edges:[],nodes:[]},l=void 0;e.nodes().not(k).forEach((function(e){if("draft"==t.quality)if(e.isParent()){var c=a.calcBoundingBox(e,r[n].xCoords,r[n].yCoords,s);o.nodes.push({x:c.topLeftX,y:c.topLeftY,width:c.width,height:c.height})}else l=s.get(e.id()),o.nodes.push({x:r[n].xCoords[l]-e.boundingbox().w/2,y:r[n].yCoords[l]-e.boundingbox().h/2,width:e.boundingbox().w,height:e.boundingbox().h});else i[n][e.id()]&&o.nodes.push({x:i[n][e.id()].getLeft(),y:i[n][e.id()].getTop(),width:i[n][e.id()].getWidth(),height:i[n][e.id()].getHeight()})})),e.edges().forEach((function(e){var l=e.source(),c=e.target();if("none"!=l.css("display")&&"none"!=c.css("display"))if("draft"==t.quality){var h=s.get(l.id()),u=s.get(c.id()),d=[],p=[];if(l.isParent()){var g=a.calcBoundingBox(l,r[n].xCoords,r[n].yCoords,s);d.push(g.topLeftX+g.width/2),d.push(g.topLeftY+g.height/2)}else d.push(r[n].xCoords[h]),d.push(r[n].yCoords[h]);if(c.isParent()){var f=a.calcBoundingBox(c,r[n].xCoords,r[n].yCoords,s);p.push(f.topLeftX+f.width/2),p.push(f.topLeftY+f.height/2)}else p.push(r[n].xCoords[u]),p.push(r[n].yCoords[u]);o.edges.push({startX:d[0],startY:d[1],endX:p[0],endY:p[1]})}else i[n][l.id()]&&i[n][c.id()]&&o.edges.push({startX:i[n][l.id()].getCenterX(),startY:i[n][l.id()].getCenterY(),endX:i[n][c.id()].getCenterX(),endY:i[n][c.id()].getCenterY()})})),o.nodes.length>0&&(w.push(o),b.add(n))}}));var T=h.packComponents(w,t.randomize).shifts;if("draft"==t.quality)r.forEach((function(t,e){var n=t.xCoords.map((function(t){return t+T[e].dx})),r=t.yCoords.map((function(t){return t+T[e].dy}));t.xCoords=n,t.yCoords=r}));else{var _=0;b.forEach((function(t){Object.keys(i[t]).forEach((function(e){var n=i[t][e];n.setCenter(n.getCenterX()+T[_].dx,n.getCenterY()+T[_].dy)})),_++}))}}}else{var E=t.eles.boundingBox();if(c.push({x:E.x1+E.w/2,y:E.y1+E.h/2}),t.randomize){var S=s(t);r.push(S)}"default"==t.quality||"proof"==t.quality?(i.push(o(t,r[0])),a.relocateComponent(c[0],i[0],t)):a.relocateComponent(c[0],r[0],t)}var C=function(e,n){if("default"==t.quality||"proof"==t.quality){"number"==typeof e&&(e=n);var a=void 0,s=void 0,o=e.data("id");return i.forEach((function(t){o in t&&(a={x:t[o].getRect().getCenterX(),y:t[o].getRect().getCenterY()},s=t[o])})),t.nodeDimensionsIncludeLabels&&(s.labelWidth&&("left"==s.labelPosHorizontal?a.x+=s.labelWidth/2:"right"==s.labelPosHorizontal&&(a.x-=s.labelWidth/2)),s.labelHeight&&("top"==s.labelPosVertical?a.y+=s.labelHeight/2:"bottom"==s.labelPosVertical&&(a.y-=s.labelHeight/2))),null==a&&(a={x:e.position("x"),y:e.position("y")}),{x:a.x,y:a.y}}var l=void 0;return r.forEach((function(t){var n=t.nodeIndexes.get(e.id());null!=n&&(l={x:t.xCoords[n],y:t.yCoords[n]})})),null==l&&(l={x:e.position("x"),y:e.position("y")}),{x:l.x,y:l.y}};if("default"==t.quality||"proof"==t.quality||t.randomize){var A=a.calcParentsWithoutChildren(e,n),L=n.filter((function(t){return"none"==t.css("display")}));t.eles=n.not(L),n.nodes().not(":parent").not(L).layoutPositions(this,t,C),A.length>0&&A.forEach((function(t){t.position(C(t))}))}else console.log("If randomize option is set to false, then quality option must be 'default' or 'proof'.")}}]),t}();t.exports=c},657:(t,e,n)=>{var r=n(548),i=n(140).layoutBase.Matrix,a=n(140).layoutBase.SVD;t.exports={spectralLayout:function(t){var e=t.cy,n=t.eles,s=n.nodes(),o=n.nodes(":parent"),l=new Map,c=new Map,h=new Map,u=[],d=[],p=[],g=[],f=[],m=[],y=[],v=[],x=void 0,b=1e8,w=1e-9,k=t.piTol,T=t.samplingType,_=t.nodeSeparation,E=void 0,S=function(t,e,n){for(var r=[],i=0,a=0,s=0,o=void 0,l=[],h=0,d=1,p=0;p=i;){s=r[i++];for(var g=u[s],y=0;yh&&(h=f[w],d=w)}return d};r.connectComponents(e,n,r.getTopMostNodes(s),l),o.forEach((function(t){r.connectComponents(e,n,r.getTopMostNodes(t.descendants().intersection(n)),l)}));for(var C=0,A=0;A0&&(r.isParent()?u[e].push(h.get(r.id())):u[e].push(r.id()))}))}));var P=function(t){var n=c.get(t),r=void 0;l.get(t).forEach((function(i){r=e.getElementById(i).isParent()?h.get(i):i,u[n].push(r),u[c.get(r)].push(t)}))},$=!0,B=!1,F=void 0;try{for(var W,z=l.keys()[Symbol.iterator]();!($=(W=z.next()).done);$=!0)P(W.value)}catch(t){B=!0,F=t}finally{try{!$&&z.return&&z.return()}finally{if(B)throw F}}var Z=void 0;if((x=c.size)>2){E=x=1)break;c=l}for(var g=0;g=1)break;c=l}for(var y=0;y{var r=n(212),i=function(t){t&&t("layout","fcose",r)};"undefined"!=typeof cytoscape&&i(cytoscape),t.exports=i},140:e=>{e.exports=t}},n={},r=function t(r){var i=n[r];if(void 0!==i)return i.exports;var a=n[r]={exports:{}};return e[r](a,a.exports,t),a.exports}(579);return r})()},t.exports=r(n(6914))},6914:function(t,e,n){var r;r=function(t){return(()=>{"use strict";var e={45:(t,e,n)=>{var r={};r.layoutBase=n(551),r.CoSEConstants=n(806),r.CoSEEdge=n(767),r.CoSEGraph=n(880),r.CoSEGraphManager=n(578),r.CoSELayout=n(765),r.CoSENode=n(991),r.ConstraintHandler=n(902),t.exports=r},806:(t,e,n)=>{var r=n(551).FDLayoutConstants;function i(){}for(var a in r)i[a]=r[a];i.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,i.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,i.DEFAULT_COMPONENT_SEPERATION=60,i.TILE=!0,i.TILING_PADDING_VERTICAL=10,i.TILING_PADDING_HORIZONTAL=10,i.TRANSFORM_ON_CONSTRAINT_HANDLING=!0,i.ENFORCE_CONSTRAINTS=!0,i.APPLY_LAYOUT=!0,i.RELAX_MOVEMENT_ON_CONSTRAINTS=!0,i.TREE_REDUCTION_ON_INCREMENTAL=!0,i.PURE_INCREMENTAL=i.DEFAULT_INCREMENTAL,t.exports=i},767:(t,e,n)=>{var r=n(551).FDLayoutEdge;function i(t,e,n){r.call(this,t,e,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];t.exports=i},880:(t,e,n)=>{var r=n(551).LGraph;function i(t,e,n){r.call(this,t,e,n)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];t.exports=i},578:(t,e,n)=>{var r=n(551).LGraphManager;function i(t){r.call(this,t)}for(var a in i.prototype=Object.create(r.prototype),r)i[a]=r[a];t.exports=i},765:(t,e,n)=>{var r=n(551).FDLayout,i=n(578),a=n(880),s=n(991),o=n(767),l=n(806),c=n(902),h=n(551).FDLayoutConstants,u=n(551).LayoutConstants,d=n(551).Point,p=n(551).PointD,g=n(551).DimensionD,f=n(551).Layout,m=n(551).Integer,y=n(551).IGeometry,v=n(551).LGraph,x=n(551).Transform,b=n(551).LinkedList;function w(){r.call(this),this.toBeTiled={},this.constraints={}}for(var k in w.prototype=Object.create(r.prototype),r)w[k]=r[k];w.prototype.newGraphManager=function(){var t=new i(this);return this.graphManager=t,t},w.prototype.newGraph=function(t){return new a(null,this.graphManager,t)},w.prototype.newNode=function(t){return new s(this.graphManager,t)},w.prototype.newEdge=function(t){return new o(null,null,t)},w.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.isSubLayout||(l.DEFAULT_EDGE_LENGTH<10?this.idealEdgeLength=10:this.idealEdgeLength=l.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=l.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.gravityConstant=h.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=h.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=h.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=h.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1)},w.prototype.initSpringEmbedder=function(){r.prototype.initSpringEmbedder.call(this),this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/h.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=.04,this.coolingAdjuster=1},w.prototype.layout=function(){return u.DEFAULT_CREATE_BENDS_AS_NEEDED&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},w.prototype.classicLayout=function(){if(this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),this.incremental)l.TREE_REDUCTION_ON_INCREMENTAL&&(this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation(),e=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter((function(t){return e.has(t)})),this.graphManager.setAllNodesToApplyGravitation(n));else{var t=this.getFlatForest();if(t.length>0)this.positionNodesRadially(t);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var e=new Set(this.getAllNodes()),n=this.nodesWithGravity.filter((function(t){return e.has(t)}));this.graphManager.setAllNodesToApplyGravitation(n),this.positionNodesRandomly()}}return Object.keys(this.constraints).length>0&&(c.handleConstraints(this),this.initConstraintVariables()),this.initSpringEmbedder(),l.APPLY_LAYOUT&&this.runSpringEmbedder(),!0},w.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished){if(!(this.prunedNodesAll.length>0))return!0;this.isTreeGrowing=!0}if(this.totalIterations%h.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged()){if(!(this.prunedNodesAll.length>0))return!0;this.isTreeGrowing=!0}this.coolingCycle++,0==this.layoutQuality?this.coolingAdjuster=this.coolingCycle:1==this.layoutQuality&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-Math.pow(this.coolingCycle,Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0)if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),e=this.nodesWithGravity.filter((function(e){return t.has(e)}));this.graphManager.setAllNodesToApplyGravitation(e),this.graphManager.updateBounds(),this.updateGrid(),l.PURE_INCREMENTAL?this.coolingFactor=h.DEFAULT_COOLING_FACTOR_INCREMENTAL/2:this.coolingFactor=h.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0;this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),l.PURE_INCREMENTAL?this.coolingFactor=h.DEFAULT_COOLING_FACTOR_INCREMENTAL/2*((100-this.afterGrowthIterations)/100):this.coolingFactor=h.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var n=!this.isTreeGrowing&&!this.isGrowthFinished,r=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(n,r),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},w.prototype.getPositionsData=function(){for(var t=this.graphManager.getAllNodes(),e={},n=0;n0&&this.updateDisplacements(),e=0;e0&&(r.fixedNodeWeight=a)}if(this.constraints.relativePlacementConstraint){var s=new Map,o=new Map;if(this.dummyToNodeForVerticalAlignment=new Map,this.dummyToNodeForHorizontalAlignment=new Map,this.fixedNodesOnHorizontal=new Set,this.fixedNodesOnVertical=new Set,this.fixedNodeSet.forEach((function(e){t.fixedNodesOnHorizontal.add(e),t.fixedNodesOnVertical.add(e)})),this.constraints.alignmentConstraint){if(this.constraints.alignmentConstraint.vertical){var c=this.constraints.alignmentConstraint.vertical;for(n=0;n=2*t.length/3;r--)e=Math.floor(Math.random()*(r+1)),n=t[r],t[r]=t[e],t[e]=n;return t},this.nodesInRelativeHorizontal=[],this.nodesInRelativeVertical=[],this.nodeToRelativeConstraintMapHorizontal=new Map,this.nodeToRelativeConstraintMapVertical=new Map,this.nodeToTempPositionMapHorizontal=new Map,this.nodeToTempPositionMapVertical=new Map,this.constraints.relativePlacementConstraint.forEach((function(e){if(e.left){var n=s.has(e.left)?s.get(e.left):e.left,r=s.has(e.right)?s.get(e.right):e.right;t.nodesInRelativeHorizontal.includes(n)||(t.nodesInRelativeHorizontal.push(n),t.nodeToRelativeConstraintMapHorizontal.set(n,[]),t.dummyToNodeForVerticalAlignment.has(n)?t.nodeToTempPositionMapHorizontal.set(n,t.idToNodeMap.get(t.dummyToNodeForVerticalAlignment.get(n)[0]).getCenterX()):t.nodeToTempPositionMapHorizontal.set(n,t.idToNodeMap.get(n).getCenterX())),t.nodesInRelativeHorizontal.includes(r)||(t.nodesInRelativeHorizontal.push(r),t.nodeToRelativeConstraintMapHorizontal.set(r,[]),t.dummyToNodeForVerticalAlignment.has(r)?t.nodeToTempPositionMapHorizontal.set(r,t.idToNodeMap.get(t.dummyToNodeForVerticalAlignment.get(r)[0]).getCenterX()):t.nodeToTempPositionMapHorizontal.set(r,t.idToNodeMap.get(r).getCenterX())),t.nodeToRelativeConstraintMapHorizontal.get(n).push({right:r,gap:e.gap}),t.nodeToRelativeConstraintMapHorizontal.get(r).push({left:n,gap:e.gap})}else{var i=o.has(e.top)?o.get(e.top):e.top,a=o.has(e.bottom)?o.get(e.bottom):e.bottom;t.nodesInRelativeVertical.includes(i)||(t.nodesInRelativeVertical.push(i),t.nodeToRelativeConstraintMapVertical.set(i,[]),t.dummyToNodeForHorizontalAlignment.has(i)?t.nodeToTempPositionMapVertical.set(i,t.idToNodeMap.get(t.dummyToNodeForHorizontalAlignment.get(i)[0]).getCenterY()):t.nodeToTempPositionMapVertical.set(i,t.idToNodeMap.get(i).getCenterY())),t.nodesInRelativeVertical.includes(a)||(t.nodesInRelativeVertical.push(a),t.nodeToRelativeConstraintMapVertical.set(a,[]),t.dummyToNodeForHorizontalAlignment.has(a)?t.nodeToTempPositionMapVertical.set(a,t.idToNodeMap.get(t.dummyToNodeForHorizontalAlignment.get(a)[0]).getCenterY()):t.nodeToTempPositionMapVertical.set(a,t.idToNodeMap.get(a).getCenterY())),t.nodeToRelativeConstraintMapVertical.get(i).push({bottom:a,gap:e.gap}),t.nodeToRelativeConstraintMapVertical.get(a).push({top:i,gap:e.gap})}}));else{var u=new Map,d=new Map;this.constraints.relativePlacementConstraint.forEach((function(t){if(t.left){var e=s.has(t.left)?s.get(t.left):t.left,n=s.has(t.right)?s.get(t.right):t.right;u.has(e)?u.get(e).push(n):u.set(e,[n]),u.has(n)?u.get(n).push(e):u.set(n,[e])}else{var r=o.has(t.top)?o.get(t.top):t.top,i=o.has(t.bottom)?o.get(t.bottom):t.bottom;d.has(r)?d.get(r).push(i):d.set(r,[i]),d.has(i)?d.get(i).push(r):d.set(i,[r])}}));var p=function(t,e){var n=[],r=[],i=new b,a=new Set,s=0;return t.forEach((function(o,l){if(!a.has(l)){n[s]=[],r[s]=!1;var c=l;for(i.push(c),a.add(c),n[s].push(c);0!=i.length;)c=i.shift(),e.has(c)&&(r[s]=!0),t.get(c).forEach((function(t){a.has(t)||(i.push(t),a.add(t),n[s].push(t))}));s++}})),{components:n,isFixed:r}},g=p(u,t.fixedNodesOnHorizontal);this.componentsOnHorizontal=g.components,this.fixedComponentsOnHorizontal=g.isFixed;var f=p(d,t.fixedNodesOnVertical);this.componentsOnVertical=f.components,this.fixedComponentsOnVertical=f.isFixed}}},w.prototype.updateDisplacements=function(){var t=this;if(this.constraints.fixedNodeConstraint&&this.constraints.fixedNodeConstraint.forEach((function(e){var n=t.idToNodeMap.get(e.nodeId);n.displacementX=0,n.displacementY=0})),this.constraints.alignmentConstraint){if(this.constraints.alignmentConstraint.vertical)for(var e=this.constraints.alignmentConstraint.vertical,n=0;n1)for(o=0;or&&(r=Math.floor(s.y)),a=Math.floor(s.x+l.DEFAULT_COMPONENT_SEPERATION)}this.transform(new p(u.WORLD_CENTER_X-s.x/2,u.WORLD_CENTER_Y-s.y/2))},w.radialLayout=function(t,e,n){var r=Math.max(this.maxDiagonalInTree(t),l.DEFAULT_RADIAL_SEPARATION);w.branchRadialLayout(e,null,0,359,0,r);var i=v.calculateBounds(t),a=new x;a.setDeviceOrgX(i.getMinX()),a.setDeviceOrgY(i.getMinY()),a.setWorldOrgX(n.x),a.setWorldOrgY(n.y);for(var s=0;s1;){var m=f[0];f.splice(0,1);var v=h.indexOf(m);v>=0&&h.splice(v,1),g--,u--}d=null!=e?(h.indexOf(f[0])+1)%g:0;for(var x=Math.abs(r-n)/u,b=d;p!=u;b=++b%g){var k=h[b].getOtherEnd(t);if(k!=e){var T=(n+p*x)%360,_=(T+x)%360;w.branchRadialLayout(k,t,T,_,i+a,a),p++}}},w.maxDiagonalInTree=function(t){for(var e=m.MIN_VALUE,n=0;ne&&(e=r)}return e},w.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},w.prototype.groupZeroDegreeMembers=function(){var t=this,e={};this.memberGroups={},this.idToDummyNode={};for(var n=[],r=this.graphManager.getAllNodes(),i=0;i1){var r="DummyCompound_"+n;t.memberGroups[r]=e[n];var i=e[n][0].getParent(),a=new s(t.graphManager);a.id=r,a.paddingLeft=i.paddingLeft||0,a.paddingRight=i.paddingRight||0,a.paddingBottom=i.paddingBottom||0,a.paddingTop=i.paddingTop||0,t.idToDummyNode[r]=a;var o=t.getGraphManager().add(t.newGraph(),a),l=i.getChild();l.add(a);for(var c=0;ci?(r.rect.x-=(r.labelWidth-i)/2,r.setWidth(r.labelWidth),r.labelMarginLeft=(r.labelWidth-i)/2):"right"==r.labelPosHorizontal&&r.setWidth(i+r.labelWidth)),r.labelHeight&&("top"==r.labelPosVertical?(r.rect.y-=r.labelHeight,r.setHeight(a+r.labelHeight),r.labelMarginTop=r.labelHeight):"center"==r.labelPosVertical&&r.labelHeight>a?(r.rect.y-=(r.labelHeight-a)/2,r.setHeight(r.labelHeight),r.labelMarginTop=(r.labelHeight-a)/2):"bottom"==r.labelPosVertical&&r.setHeight(a+r.labelHeight))}}))},w.prototype.repopulateCompounds=function(){for(var t=this.compoundOrder.length-1;t>=0;t--){var e=this.compoundOrder[t],n=e.id,r=e.paddingLeft,i=e.paddingTop,a=e.labelMarginLeft,s=e.labelMarginTop;this.adjustLocations(this.tiledMemberPack[n],e.rect.x,e.rect.y,r,i,a,s)}},w.prototype.repopulateZeroDegreeMembers=function(){var t=this,e=this.tiledZeroDegreePack;Object.keys(e).forEach((function(n){var r=t.idToDummyNode[n],i=r.paddingLeft,a=r.paddingTop,s=r.labelMarginLeft,o=r.labelMarginTop;t.adjustLocations(e[n],r.rect.x,r.rect.y,i,a,s,o)}))},w.prototype.getToBeTiled=function(t){var e=t.id;if(null!=this.toBeTiled[e])return this.toBeTiled[e];var n=t.getChild();if(null==n)return this.toBeTiled[e]=!1,!1;for(var r=n.getNodes(),i=0;i0)return this.toBeTiled[e]=!1,!1;if(null!=a.getChild()){if(!this.getToBeTiled(a))return this.toBeTiled[e]=!1,!1}else this.toBeTiled[a.id]=!1}return this.toBeTiled[e]=!0,!0},w.prototype.getNodeDegree=function(t){t.id;for(var e=t.getEdges(),n=0,r=0;rh&&(h=d.rect.height)}n+=h+t.verticalPadding}},w.prototype.tileCompoundMembers=function(t,e){var n=this;this.tiledMemberPack=[],Object.keys(t).forEach((function(r){var i=e[r];if(n.tiledMemberPack[r]=n.tileNodes(t[r],i.paddingLeft+i.paddingRight),i.rect.width=n.tiledMemberPack[r].width,i.rect.height=n.tiledMemberPack[r].height,i.setCenter(n.tiledMemberPack[r].centerX,n.tiledMemberPack[r].centerY),i.labelMarginLeft=0,i.labelMarginTop=0,l.NODE_DIMENSIONS_INCLUDE_LABELS){var a=i.rect.width,s=i.rect.height;i.labelWidth&&("left"==i.labelPosHorizontal?(i.rect.x-=i.labelWidth,i.setWidth(a+i.labelWidth),i.labelMarginLeft=i.labelWidth):"center"==i.labelPosHorizontal&&i.labelWidth>a?(i.rect.x-=(i.labelWidth-a)/2,i.setWidth(i.labelWidth),i.labelMarginLeft=(i.labelWidth-a)/2):"right"==i.labelPosHorizontal&&i.setWidth(a+i.labelWidth)),i.labelHeight&&("top"==i.labelPosVertical?(i.rect.y-=i.labelHeight,i.setHeight(s+i.labelHeight),i.labelMarginTop=i.labelHeight):"center"==i.labelPosVertical&&i.labelHeight>s?(i.rect.y-=(i.labelHeight-s)/2,i.setHeight(i.labelHeight),i.labelMarginTop=(i.labelHeight-s)/2):"bottom"==i.labelPosVertical&&i.setHeight(s+i.labelHeight))}}))},w.prototype.tileNodes=function(t,e){var n=this.tileNodesByFavoringDim(t,e,!0),r=this.tileNodesByFavoringDim(t,e,!1),i=this.getOrgRatio(n);return this.getOrgRatio(r)o&&(o=t.getWidth())}));var c,h=a/i,u=s/i,d=Math.pow(n-r,2)+4*(h+r)*(u+n)*i,p=(r-n+Math.sqrt(d))/(2*(h+r));e?(c=Math.ceil(p))==p&&c++:c=Math.floor(p);var g=c*(h+r)-r;return o>g&&(g=o),g+2*r},w.prototype.tileNodesByFavoringDim=function(t,e,n){var r=l.TILING_PADDING_VERTICAL,i=l.TILING_PADDING_HORIZONTAL,a=l.TILING_COMPARE_BY,s={rows:[],rowWidth:[],rowHeight:[],width:0,height:e,verticalPadding:r,horizontalPadding:i,centerX:0,centerY:0};a&&(s.idealRowWidth=this.calcIdealRowWidth(t,n));var o=function(t){return t.rect.width*t.rect.height},c=function(t,e){return o(e)-o(t)};t.sort((function(t,e){var n=c;return s.idealRowWidth?(n=a)(t.id,e.id):n(t,e)}));for(var h=0,u=0,d=0;d0&&(a+=t.horizontalPadding),t.rowWidth[n]=a,t.width0&&(s+=t.verticalPadding);var o=0;s>t.rowHeight[n]&&(o=t.rowHeight[n],t.rowHeight[n]=s,o=t.rowHeight[n]-o),t.height+=o,t.rows[n].push(e)},w.prototype.getShortestRowIndex=function(t){for(var e=-1,n=Number.MAX_VALUE,r=0;rn&&(e=r,n=t.rowWidth[r]);return e},w.prototype.canAddHorizontal=function(t,e,n){if(t.idealRowWidth){var r=t.rows.length-1;return t.rowWidth[r]+e+t.horizontalPadding<=t.idealRowWidth}var i=this.getShortestRowIndex(t);if(i<0)return!0;var a=t.rowWidth[i];if(a+t.horizontalPadding+e<=t.width)return!0;var s,o,l=0;return t.rowHeight[i]0&&(l=n+t.verticalPadding-t.rowHeight[i]),s=t.width-a>=e+t.horizontalPadding?(t.height+l)/(a+e+t.horizontalPadding):(t.height+l)/t.width,l=n+t.verticalPadding,(o=t.widtha&&e!=n){r.splice(-1,1),t.rows[n].push(i),t.rowWidth[e]=t.rowWidth[e]-a,t.rowWidth[n]=t.rowWidth[n]+a,t.width=t.rowWidth[instance.getLongestRowIndex(t)];for(var s=Number.MIN_VALUE,o=0;os&&(s=r[o].height);e>0&&(s+=t.verticalPadding);var l=t.rowHeight[e]+t.rowHeight[n];t.rowHeight[e]=s,t.rowHeight[n]0)for(var u=i;u<=a;u++)c[0]+=this.grid[u][s-1].length+this.grid[u][s].length-1;if(a0)for(u=s;u<=o;u++)c[3]+=this.grid[i-1][u].length+this.grid[i][u].length-1;for(var d,p,g=m.MAX_VALUE,f=0;f{var r=n(551).FDLayoutNode,i=n(551).IMath;function a(t,e,n,i){r.call(this,t,e,n,i)}for(var s in a.prototype=Object.create(r.prototype),r)a[s]=r[s];a.prototype.calculateDisplacement=function(){var t=this.graphManager.getLayout();null!=this.getChild()&&this.fixedNodeWeight?(this.displacementX+=t.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.fixedNodeWeight,this.displacementY+=t.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.fixedNodeWeight):(this.displacementX+=t.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY+=t.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren),Math.abs(this.displacementX)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementX=t.coolingFactor*t.maxNodeDisplacement*i.sign(this.displacementX)),Math.abs(this.displacementY)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementY=t.coolingFactor*t.maxNodeDisplacement*i.sign(this.displacementY)),this.child&&this.child.getNodes().length>0&&this.propogateDisplacementToChildren(this.displacementX,this.displacementY)},a.prototype.propogateDisplacementToChildren=function(t,e){for(var n,r=this.getChild().getNodes(),i=0;i{function r(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e0){var a=0;r.forEach((function(t){"horizontal"==e?(u.set(t,l.has(t)?c[l.get(t)]:i.get(t)),a+=u.get(t)):(u.set(t,l.has(t)?h[l.get(t)]:i.get(t)),a+=u.get(t))})),a/=r.length,t.forEach((function(t){n.has(t)||u.set(t,a)}))}else{var s=0;t.forEach((function(t){s+="horizontal"==e?l.has(t)?c[l.get(t)]:i.get(t):l.has(t)?h[l.get(t)]:i.get(t)})),s/=t.length,t.forEach((function(t){u.set(t,s)}))}}));for(var g=function(){var r=p.shift();t.get(r).forEach((function(t){if(u.get(t.id)s&&(s=y),xo&&(o=x)}}catch(t){p=!0,g=t}finally{try{!d&&m.return&&m.return()}finally{if(p)throw g}}var b=(r+s)/2-(a+o)/2,w=!0,k=!1,T=void 0;try{for(var _,E=t[Symbol.iterator]();!(w=(_=E.next()).done);w=!0){var S=_.value;u.set(S,u.get(S)+b)}}catch(t){k=!0,T=t}finally{try{!w&&E.return&&E.return()}finally{if(k)throw T}}}))}return u},y=function(t){var e=0,n=0,r=0,i=0;if(t.forEach((function(t){t.left?c[l.get(t.left)]-c[l.get(t.right)]>=0?e++:n++:h[l.get(t.top)]-h[l.get(t.bottom)]>=0?r++:i++})),e>n&&r>i)for(var a=0;an)for(var s=0;si)for(var o=0;o1)e.fixedNodeConstraint.forEach((function(t,e){w[e]=[t.position.x,t.position.y],k[e]=[c[l.get(t.nodeId)],h[l.get(t.nodeId)]]})),T=!0;else if(e.alignmentConstraint)!function(){var t=0;if(e.alignmentConstraint.vertical){for(var n=e.alignmentConstraint.vertical,i=function(e){var i=new Set;n[e].forEach((function(t){i.add(t)}));var a,s=new Set([].concat(r(i)).filter((function(t){return E.has(t)})));a=s.size>0?c[l.get(s.values().next().value)]:f(i).x,n[e].forEach((function(e){w[t]=[a,h[l.get(e)]],k[t]=[c[l.get(e)],h[l.get(e)]],t++}))},a=0;a0?c[l.get(a.values().next().value)]:f(n).y,s[e].forEach((function(e){w[t]=[c[l.get(e)],i],k[t]=[c[l.get(e)],h[l.get(e)]],t++}))},u=0;uL&&(L=A[N].length,M=N);if(L0){var q={x:0,y:0};e.fixedNodeConstraint.forEach((function(t,e){var n,r,i=(r={x:c[l.get(t.nodeId)],y:h[l.get(t.nodeId)]},{x:(n=t.position).x-r.x,y:n.y-r.y});q.x+=i.x,q.y+=i.y})),q.x/=e.fixedNodeConstraint.length,q.y/=e.fixedNodeConstraint.length,c.forEach((function(t,e){c[e]+=q.x})),h.forEach((function(t,e){h[e]+=q.y})),e.fixedNodeConstraint.forEach((function(t){c[l.get(t.nodeId)]=t.position.x,h[l.get(t.nodeId)]=t.position.y}))}if(e.alignmentConstraint){if(e.alignmentConstraint.vertical)for(var j=e.alignmentConstraint.vertical,H=function(t){var e=new Set;j[t].forEach((function(t){e.add(t)}));var n,i=new Set([].concat(r(e)).filter((function(t){return E.has(t)})));n=i.size>0?c[l.get(i.values().next().value)]:f(e).x,e.forEach((function(t){E.has(t)||(c[l.get(t)]=n)}))},X=0;X0?h[l.get(i.values().next().value)]:f(e).y,e.forEach((function(t){E.has(t)||(h[l.get(t)]=n)}))},J=0;J{e.exports=t}},n={},r=function t(r){var i=n[r];if(void 0!==i)return i.exports;var a=n[r]={exports:{}};return e[r](a,a.exports,t),a.exports}(45);return r})()},t.exports=r(n(3035))},3035:function(t){var e;e=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.i=function(t){return t},n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=28)}([function(t,e,n){"use strict";function r(){}r.QUALITY=1,r.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,r.DEFAULT_INCREMENTAL=!1,r.DEFAULT_ANIMATION_ON_LAYOUT=!0,r.DEFAULT_ANIMATION_DURING_LAYOUT=!1,r.DEFAULT_ANIMATION_PERIOD=50,r.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,r.DEFAULT_GRAPH_MARGIN=15,r.NODE_DIMENSIONS_INCLUDE_LABELS=!1,r.SIMPLE_NODE_SIZE=40,r.SIMPLE_NODE_HALF_SIZE=r.SIMPLE_NODE_SIZE/2,r.EMPTY_COMPOUND_NODE_SIZE=40,r.MIN_EDGE_LENGTH=1,r.WORLD_BOUNDARY=1e6,r.INITIAL_WORLD_BOUNDARY=r.WORLD_BOUNDARY/1e3,r.WORLD_CENTER_X=1200,r.WORLD_CENTER_Y=900,t.exports=r},function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(9);function s(t,e,n){r.call(this,n),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=n,this.bendpoints=[],this.source=t,this.target=e}for(var o in s.prototype=Object.create(r.prototype),r)s[o]=r[o];s.prototype.getSource=function(){return this.source},s.prototype.getTarget=function(){return this.target},s.prototype.isInterGraph=function(){return this.isInterGraph},s.prototype.getLength=function(){return this.length},s.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},s.prototype.getBendpoints=function(){return this.bendpoints},s.prototype.getLca=function(){return this.lca},s.prototype.getSourceInLca=function(){return this.sourceInLca},s.prototype.getTargetInLca=function(){return this.targetInLca},s.prototype.getOtherEnd=function(t){if(this.source===t)return this.target;if(this.target===t)return this.source;throw"Node is not incident with this edge"},s.prototype.getOtherEndInGraph=function(t,e){for(var n=this.getOtherEnd(t),r=e.getGraphManager().getRoot();;){if(n.getOwner()==e)return n;if(n.getOwner()==r)break;n=n.getOwner().getParent()}return null},s.prototype.updateLength=function(){var t=new Array(4);this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),t),this.isOverlapingSourceAndTarget||(this.lengthX=t[0]-t[2],this.lengthY=t[1]-t[3],Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},s.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},t.exports=s},function(t,e,n){"use strict";t.exports=function(t){this.vGraphObject=t}},function(t,e,n){"use strict";var r=n(2),i=n(10),a=n(13),s=n(0),o=n(16),l=n(5);function c(t,e,n,s){null==n&&null==s&&(s=e),r.call(this,s),null!=t.graphManager&&(t=t.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=s,this.edges=[],this.graphManager=t,this.rect=null!=n&&null!=e?new a(e.x,e.y,n.width,n.height):new a}for(var h in c.prototype=Object.create(r.prototype),r)c[h]=r[h];c.prototype.getEdges=function(){return this.edges},c.prototype.getChild=function(){return this.child},c.prototype.getOwner=function(){return this.owner},c.prototype.getWidth=function(){return this.rect.width},c.prototype.setWidth=function(t){this.rect.width=t},c.prototype.getHeight=function(){return this.rect.height},c.prototype.setHeight=function(t){this.rect.height=t},c.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},c.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},c.prototype.getCenter=function(){return new l(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},c.prototype.getLocation=function(){return new l(this.rect.x,this.rect.y)},c.prototype.getRect=function(){return this.rect},c.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},c.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},c.prototype.setRect=function(t,e){this.rect.x=t.x,this.rect.y=t.y,this.rect.width=e.width,this.rect.height=e.height},c.prototype.setCenter=function(t,e){this.rect.x=t-this.rect.width/2,this.rect.y=e-this.rect.height/2},c.prototype.setLocation=function(t,e){this.rect.x=t,this.rect.y=e},c.prototype.moveBy=function(t,e){this.rect.x+=t,this.rect.y+=e},c.prototype.getEdgeListToNode=function(t){var e=[],n=this;return n.edges.forEach((function(r){if(r.target==t){if(r.source!=n)throw"Incorrect edge source!";e.push(r)}})),e},c.prototype.getEdgesBetween=function(t){var e=[],n=this;return n.edges.forEach((function(r){if(r.source!=n&&r.target!=n)throw"Incorrect edge source and/or target";r.target!=t&&r.source!=t||e.push(r)})),e},c.prototype.getNeighborsList=function(){var t=new Set,e=this;return e.edges.forEach((function(n){if(n.source==e)t.add(n.target);else{if(n.target!=e)throw"Incorrect incidency!";t.add(n.source)}})),t},c.prototype.withChildren=function(){var t=new Set;if(t.add(this),null!=this.child)for(var e=this.child.getNodes(),n=0;ne?(this.rect.x-=(this.labelWidth-e)/2,this.setWidth(this.labelWidth)):"right"==this.labelPosHorizontal&&this.setWidth(e+this.labelWidth)),this.labelHeight&&("top"==this.labelPosVertical?(this.rect.y-=this.labelHeight,this.setHeight(n+this.labelHeight)):"center"==this.labelPosVertical&&this.labelHeight>n?(this.rect.y-=(this.labelHeight-n)/2,this.setHeight(this.labelHeight)):"bottom"==this.labelPosVertical&&this.setHeight(n+this.labelHeight))}}},c.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},c.prototype.transform=function(t){var e=this.rect.x;e>s.WORLD_BOUNDARY?e=s.WORLD_BOUNDARY:e<-s.WORLD_BOUNDARY&&(e=-s.WORLD_BOUNDARY);var n=this.rect.y;n>s.WORLD_BOUNDARY?n=s.WORLD_BOUNDARY:n<-s.WORLD_BOUNDARY&&(n=-s.WORLD_BOUNDARY);var r=new l(e,n),i=t.inverseTransformPoint(r);this.setLocation(i.x,i.y)},c.prototype.getLeft=function(){return this.rect.x},c.prototype.getRight=function(){return this.rect.x+this.rect.width},c.prototype.getTop=function(){return this.rect.y},c.prototype.getBottom=function(){return this.rect.y+this.rect.height},c.prototype.getParent=function(){return null==this.owner?null:this.owner.getParent()},t.exports=c},function(t,e,n){"use strict";var r=n(0);function i(){}for(var a in r)i[a]=r[a];i.MAX_ITERATIONS=2500,i.DEFAULT_EDGE_LENGTH=50,i.DEFAULT_SPRING_STRENGTH=.45,i.DEFAULT_REPULSION_STRENGTH=4500,i.DEFAULT_GRAVITY_STRENGTH=.4,i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,i.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,i.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,i.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,i.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,i.COOLING_ADAPTATION_FACTOR=.33,i.ADAPTATION_LOWER_NODE_LIMIT=1e3,i.ADAPTATION_UPPER_NODE_LIMIT=5e3,i.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,i.MAX_NODE_DISPLACEMENT=3*i.MAX_NODE_DISPLACEMENT_INCREMENTAL,i.MIN_REPULSION_DIST=i.DEFAULT_EDGE_LENGTH/10,i.CONVERGENCE_CHECK_PERIOD=100,i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,i.MIN_EDGE_LENGTH=1,i.GRID_CALCULATION_CHECK_PERIOD=10,t.exports=i},function(t,e,n){"use strict";function r(t,e){null==t&&null==e?(this.x=0,this.y=0):(this.x=t,this.y=e)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.setX=function(t){this.x=t},r.prototype.setY=function(t){this.y=t},r.prototype.getDifference=function(t){return new DimensionD(this.x-t.x,this.y-t.y)},r.prototype.getCopy=function(){return new r(this.x,this.y)},r.prototype.translate=function(t){return this.x+=t.width,this.y+=t.height,this},t.exports=r},function(t,e,n){"use strict";var r=n(2),i=n(10),a=n(0),s=n(7),o=n(3),l=n(1),c=n(13),h=n(12),u=n(11);function d(t,e,n){r.call(this,n),this.estimatedSize=i.MIN_VALUE,this.margin=a.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=t,null!=e&&e instanceof s?this.graphManager=e:null!=e&&e instanceof Layout&&(this.graphManager=e.graphManager)}for(var p in d.prototype=Object.create(r.prototype),r)d[p]=r[p];d.prototype.getNodes=function(){return this.nodes},d.prototype.getEdges=function(){return this.edges},d.prototype.getGraphManager=function(){return this.graphManager},d.prototype.getParent=function(){return this.parent},d.prototype.getLeft=function(){return this.left},d.prototype.getRight=function(){return this.right},d.prototype.getTop=function(){return this.top},d.prototype.getBottom=function(){return this.bottom},d.prototype.isConnected=function(){return this.isConnected},d.prototype.add=function(t,e,n){if(null==e&&null==n){var r=t;if(null==this.graphManager)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(r)>-1)throw"Node already in graph!";return r.owner=this,this.getNodes().push(r),r}var i=t;if(!(this.getNodes().indexOf(e)>-1&&this.getNodes().indexOf(n)>-1))throw"Source or target not in graph!";if(e.owner!=n.owner||e.owner!=this)throw"Both owners must be this graph!";return e.owner!=n.owner?null:(i.source=e,i.target=n,i.isInterGraph=!1,this.getEdges().push(i),e.edges.push(i),n!=e&&n.edges.push(i),i)},d.prototype.remove=function(t){var e=t;if(t instanceof o){if(null==e)throw"Node is null!";if(null==e.owner||e.owner!=this)throw"Owner graph is invalid!";if(null==this.graphManager)throw"Owner graph manager is invalid!";for(var n=e.edges.slice(),r=n.length,i=0;i-1&&h>-1))throw"Source and/or target doesn't know this edge!";if(a.source.edges.splice(c,1),a.target!=a.source&&a.target.edges.splice(h,1),-1==(s=a.source.owner.getEdges().indexOf(a)))throw"Not in owner's edge list!";a.source.owner.getEdges().splice(s,1)}},d.prototype.updateLeftTop=function(){for(var t,e,n,r=i.MAX_VALUE,a=i.MAX_VALUE,s=this.getNodes(),o=s.length,l=0;l(t=c.getTop())&&(r=t),a>(e=c.getLeft())&&(a=e)}return r==i.MAX_VALUE?null:(n=null!=s[0].getParent().paddingLeft?s[0].getParent().paddingLeft:this.margin,this.left=a-n,this.top=r-n,new h(this.left,this.top))},d.prototype.updateBounds=function(t){for(var e,n,r,a,s,o=i.MAX_VALUE,l=-i.MAX_VALUE,h=i.MAX_VALUE,u=-i.MAX_VALUE,d=this.nodes,p=d.length,g=0;g(e=f.getLeft())&&(o=e),l<(n=f.getRight())&&(l=n),h>(r=f.getTop())&&(h=r),u<(a=f.getBottom())&&(u=a)}var m=new c(o,h,l-o,u-h);o==i.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),s=null!=d[0].getParent().paddingLeft?d[0].getParent().paddingLeft:this.margin,this.left=m.x-s,this.right=m.x+m.width+s,this.top=m.y-s,this.bottom=m.y+m.height+s},d.calculateBounds=function(t){for(var e,n,r,a,s=i.MAX_VALUE,o=-i.MAX_VALUE,l=i.MAX_VALUE,h=-i.MAX_VALUE,u=t.length,d=0;d(e=p.getLeft())&&(s=e),o<(n=p.getRight())&&(o=n),l>(r=p.getTop())&&(l=r),h<(a=p.getBottom())&&(h=a)}return new c(s,l,o-s,h-l)},d.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},d.prototype.getEstimatedSize=function(){if(this.estimatedSize==i.MIN_VALUE)throw"assert failed";return this.estimatedSize},d.prototype.calcEstimatedSize=function(){for(var t=0,e=this.nodes,n=e.length,r=0;r=this.nodes.length){var l=0;i.forEach((function(e){e.owner==t&&l++})),l==this.nodes.length&&(this.isConnected=!0)}}else this.isConnected=!0},t.exports=d},function(t,e,n){"use strict";var r,i=n(1);function a(t){r=n(6),this.layout=t,this.graphs=[],this.edges=[]}a.prototype.addRoot=function(){var t=this.layout.newGraph(),e=this.layout.newNode(null),n=this.add(t,e);return this.setRootGraph(n),this.rootGraph},a.prototype.add=function(t,e,n,r,i){if(null==n&&null==r&&null==i){if(null==t)throw"Graph is null!";if(null==e)throw"Parent node is null!";if(this.graphs.indexOf(t)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(t),null!=t.parent)throw"Already has a parent!";if(null!=e.child)throw"Already has a child!";return t.parent=e,e.child=t,t}i=n,n=t;var a=(r=e).getOwner(),s=i.getOwner();if(null==a||a.getGraphManager()!=this)throw"Source not in this graph mgr!";if(null==s||s.getGraphManager()!=this)throw"Target not in this graph mgr!";if(a==s)return n.isInterGraph=!1,a.add(n,r,i);if(n.isInterGraph=!0,n.source=r,n.target=i,this.edges.indexOf(n)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(n),null==n.source||null==n.target)throw"Edge source and/or target is null!";if(-1!=n.source.edges.indexOf(n)||-1!=n.target.edges.indexOf(n))throw"Edge already in source and/or target incidency list!";return n.source.edges.push(n),n.target.edges.push(n),n},a.prototype.remove=function(t){if(t instanceof r){var e=t;if(e.getGraphManager()!=this)throw"Graph not in this graph mgr";if(e!=this.rootGraph&&(null==e.parent||e.parent.graphManager!=this))throw"Invalid parent node!";for(var n,a=[],s=(a=a.concat(e.getEdges())).length,o=0;o=e.getRight()?n[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight()):e.getX()<=t.getX()&&e.getRight()>=t.getRight()&&(n[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight())),t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()?n[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()):e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()&&(n[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()));var a=Math.abs((e.getCenterY()-t.getCenterY())/(e.getCenterX()-t.getCenterX()));e.getCenterY()===t.getCenterY()&&e.getCenterX()===t.getCenterX()&&(a=1);var s=a*n[0],o=n[1]/a;n[0]s)return n[0]=r,n[1]=l,n[2]=a,n[3]=x,!1;if(ia)return n[0]=o,n[1]=i,n[2]=y,n[3]=s,!1;if(ra?(n[0]=h,n[1]=u,T=!0):(n[0]=c,n[1]=l,T=!0):E===C&&(r>a?(n[0]=o,n[1]=l,T=!0):(n[0]=d,n[1]=u,T=!0)),-S===C?a>r?(n[2]=v,n[3]=x,_=!0):(n[2]=y,n[3]=m,_=!0):S===C&&(a>r?(n[2]=f,n[3]=m,_=!0):(n[2]=b,n[3]=x,_=!0)),T&&_)return!1;if(r>a?i>s?(A=this.getCardinalDirection(E,C,4),L=this.getCardinalDirection(S,C,2)):(A=this.getCardinalDirection(-E,C,3),L=this.getCardinalDirection(-S,C,1)):i>s?(A=this.getCardinalDirection(-E,C,1),L=this.getCardinalDirection(-S,C,3)):(A=this.getCardinalDirection(E,C,2),L=this.getCardinalDirection(S,C,4)),!T)switch(A){case 1:N=l,M=r+-g/C,n[0]=M,n[1]=N;break;case 2:M=d,N=i+p*C,n[0]=M,n[1]=N;break;case 3:N=u,M=r+g/C,n[0]=M,n[1]=N;break;case 4:M=h,N=i+-p*C,n[0]=M,n[1]=N}if(!_)switch(L){case 1:R=m,I=a+-k/C,n[2]=I,n[3]=R;break;case 2:I=b,R=s+w*C,n[2]=I,n[3]=R;break;case 3:R=x,I=a+k/C,n[2]=I,n[3]=R;break;case 4:I=v,R=s+-w*C,n[2]=I,n[3]=R}}return!1},i.getCardinalDirection=function(t,e,n){return t>e?n:1+n%4},i.getIntersection=function(t,e,n,i){if(null==i)return this.getIntersection2(t,e,n);var a,s,o,l,c,h,u,d=t.x,p=t.y,g=e.x,f=e.y,m=n.x,y=n.y,v=i.x,x=i.y;return 0==(u=(a=f-p)*(l=m-v)-(s=x-y)*(o=d-g))?null:new r((o*(h=v*y-m*x)-l*(c=g*p-d*f))/u,(s*c-a*h)/u)},i.angleOfVector=function(t,e,n,r){var i=void 0;return t!==n?(i=Math.atan((r-e)/(n-t)),n=0){var h=(-l+Math.sqrt(l*l-4*o*c))/(2*o),u=(-l-Math.sqrt(l*l-4*o*c))/(2*o);return h>=0&&h<=1?[h]:u>=0&&u<=1?[u]:null}return null},i.HALF_PI=.5*Math.PI,i.ONE_AND_HALF_PI=1.5*Math.PI,i.TWO_PI=2*Math.PI,i.THREE_PI=3*Math.PI,t.exports=i},function(t,e,n){"use strict";function r(){}r.sign=function(t){return t>0?1:t<0?-1:0},r.floor=function(t){return t<0?Math.ceil(t):Math.floor(t)},r.ceil=function(t){return t<0?Math.floor(t):Math.ceil(t)},t.exports=r},function(t,e,n){"use strict";function r(){}r.MAX_VALUE=2147483647,r.MIN_VALUE=-2147483648,t.exports=r},function(t,e,n){"use strict";var r=function(){function t(t,e){for(var n=0;n0&&e;){for(o.push(c[0]);o.length>0&&e;){var h=o[0];o.splice(0,1),s.add(h);var u=h.getEdges();for(a=0;a-1&&c.splice(f,1)}s=new Set,l=new Map}else t=[]}return t},d.prototype.createDummyNodesForBendpoints=function(t){for(var e=[],n=t.source,r=this.graphManager.calcLowestCommonAncestor(t.source,t.target),i=0;i0){for(var i=this.edgeToDummyNodes.get(n),a=0;a=0&&e.splice(u,1),h.getNeighborsList().forEach((function(t){if(n.indexOf(t)<0){var e=r.get(t)-1;1==e&&l.push(t),r.set(t,e)}}))}n=n.concat(l),1!=e.length&&2!=e.length||(i=!0,a=e[0])}return a},d.prototype.setGraphManager=function(t){this.graphManager=t},t.exports=d},function(t,e,n){"use strict";function r(){}r.seed=1,r.x=0,r.nextDouble=function(){return r.x=1e4*Math.sin(r.seed++),r.x-Math.floor(r.x)},t.exports=r},function(t,e,n){"use strict";var r=n(5);function i(t,e){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(t){this.lworldExtX=t},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(t){this.lworldExtY=t},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},i.prototype.transformX=function(t){var e=0,n=this.lworldExtX;return 0!=n&&(e=this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/n),e},i.prototype.transformY=function(t){var e=0,n=this.lworldExtY;return 0!=n&&(e=this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/n),e},i.prototype.inverseTransformX=function(t){var e=0,n=this.ldeviceExtX;return 0!=n&&(e=this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/n),e},i.prototype.inverseTransformY=function(t){var e=0,n=this.ldeviceExtY;return 0!=n&&(e=this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/n),e},i.prototype.inverseTransformPoint=function(t){return new r(this.inverseTransformX(t.x),this.inverseTransformY(t.y))},t.exports=i},function(t,e,n){"use strict";var r=n(15),i=n(4),a=n(0),s=n(8),o=n(9);function l(){r.call(this),this.useSmartIdealEdgeLengthCalculation=i.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.gravityConstant=i.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=i.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=i.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*i.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=i.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=i.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=i.MAX_ITERATIONS}for(var c in l.prototype=Object.create(r.prototype),r)l[c]=r[c];l.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=i.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},l.prototype.calcIdealEdgeLengths=function(){for(var t,e,n,r,s,o,l,c=this.getGraphManager().getAllEdges(),h=0;hi.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*i.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(t-i.ADAPTATION_LOWER_NODE_LIMIT)/(i.ADAPTATION_UPPER_NODE_LIMIT-i.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-i.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=i.MAX_NODE_DISPLACEMENT_INCREMENTAL):(t>i.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(i.COOLING_ADAPTATION_FACTOR,1-(t-i.ADAPTATION_LOWER_NODE_LIMIT)/(i.ADAPTATION_UPPER_NODE_LIMIT-i.ADAPTATION_LOWER_NODE_LIMIT)*(1-i.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=i.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(5*this.getAllNodes().length,this.maxIterations),this.displacementThresholdPerNode=3*i.DEFAULT_EDGE_LENGTH/100,this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},l.prototype.calcSpringForces=function(){for(var t,e=this.getAllEdges(),n=0;n0&&void 0!==arguments[0])||arguments[0],o=arguments.length>1&&void 0!==arguments[1]&&arguments[1],l=this.getAllNodes();if(this.useFRGridVariant)for(this.totalIterations%i.GRID_CALCULATION_CHECK_PERIOD==1&&s&&this.updateGrid(),a=new Set,t=0;t(l=e.getEstimatedSize()*this.gravityRangeFactor)||o>l)&&(t.gravitationForceX=-this.gravityConstant*i,t.gravitationForceY=-this.gravityConstant*a):(s>(l=e.getEstimatedSize()*this.compoundGravityRangeFactor)||o>l)&&(t.gravitationForceX=-this.gravityConstant*i*this.compoundGravityConstant,t.gravitationForceY=-this.gravityConstant*a*this.compoundGravityConstant)},l.prototype.isConverged=function(){var t,e=!1;return this.totalIterations>this.maxIterations/3&&(e=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),t=this.totalDisplacement=o.length||c>=o[0].length))for(var h=0;ht}}]),t}();t.exports=a},function(t,e,n){"use strict";function r(){}r.svd=function(t){this.U=null,this.V=null,this.s=null,this.m=0,this.n=0,this.m=t.length,this.n=t[0].length;var e=Math.min(this.m,this.n);this.s=function(t){for(var e=[];t-- >0;)e.push(0);return e}(Math.min(this.m+1,this.n)),this.U=function t(e){if(0==e.length)return 0;for(var n=[],r=0;r0;)e.push(0);return e}(this.n),s=function(t){for(var e=[];t-- >0;)e.push(0);return e}(this.m),o=Math.min(this.m-1,this.n),l=Math.max(0,Math.min(this.n-2,this.m)),c=0;c=0;L--)if(0!==this.s[L]){for(var M=L+1;M=0;$--){if(function(t,e){return t&&e}($0;){var V=void 0,q=void 0;for(V=S-2;V>=-1&&-1!==V;V--)if(Math.abs(a[V])<=G+U*(Math.abs(this.s[V])+Math.abs(this.s[V+1]))){a[V]=0;break}if(V===S-2)q=4;else{var j=void 0;for(j=S-1;j>=V&&j!==V;j--){var H=(j!==S?Math.abs(a[j]):0)+(j!==V+1?Math.abs(a[j-1]):0);if(Math.abs(this.s[j])<=G+U*H){this.s[j]=0;break}}j===V?q=3:j===S-1?q=1:(q=2,V=j)}switch(V++,q){case 1:var X=a[S-2];a[S-2]=0;for(var K=S-2;K>=V;K--){var Q=r.hypot(this.s[K],X),J=this.s[K]/Q,tt=X/Q;this.s[K]=Q,K!==V&&(X=-tt*a[K-1],a[K-1]=J*a[K-1]);for(var et=0;et=this.s[V+1]);){var St=this.s[V];if(this.s[V]=this.s[V+1],this.s[V+1]=St,VMath.abs(e)?(n=e/t,n=Math.abs(t)*Math.sqrt(1+n*n)):0!=e?(n=t/e,n=Math.abs(e)*Math.sqrt(1+n*n)):n=0,n},t.exports=r},function(t,e,n){"use strict";var r=function(){function t(t,e){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:1,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:-1,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.sequence1=e,this.sequence2=n,this.match_score=r,this.mismatch_penalty=i,this.gap_penalty=a,this.iMax=e.length+1,this.jMax=n.length+1,this.grid=new Array(this.iMax);for(var s=0;s=0;n--){var r=this.listeners[n];r.event===t&&r.callback===e&&this.listeners.splice(n,1)}},i.emit=function(t,e){for(var n=0;n=e?t:""+Array(e+1-r.length).join(n)+t},y={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+m(r,2,"0")+":"+m(i,2,"0")},m:function t(e,n){if(e.date()1)return t(s[0])}else{var o=e.name;x[o]=e,i=o}return!r&&i&&(v=i),i||!r&&v},T=function(t,e){if(w(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new E(n)},_=y;_.l=k,_.i=w,_.w=function(t,e){return T(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var E=function(){function f(t){this.$L=k(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[b]=!0}var m=f.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(_.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(p);if(r){var i=r[2]-1||0,a=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(e)}(t),this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return _},m.isValid=function(){return!(this.$d.toString()===d)},m.isSame=function(t,e){var n=T(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return T(t)68?1900:2e3)},l=function(t){return function(e){this[t]=+e}},c=[/[+-]\d\d:?(\d\d)?|Z/,function(t){(this.zone||(this.zone={})).offset=function(t){if(!t)return 0;if("Z"===t)return 0;var e=t.match(/([+-]|\d\d)/g),n=60*e[1]+(+e[2]||0);return 0===n?0:"+"===e[0]?-n:n}(t)}],h=function(t){var e=s[t];return e&&(e.indexOf?e:e.s.concat(e.f))},u=function(t,e){var n,r=s.meridiem;if(r){for(var i=1;i<=24;i+=1)if(t.indexOf(r(i,0,e))>-1){n=i>12;break}}else n=t===(e?"pm":"PM");return n},d={A:[a,function(t){this.afternoon=u(t,!1)}],a:[a,function(t){this.afternoon=u(t,!0)}],Q:[n,function(t){this.month=3*(t-1)+1}],S:[n,function(t){this.milliseconds=100*+t}],SS:[r,function(t){this.milliseconds=10*+t}],SSS:[/\d{3}/,function(t){this.milliseconds=+t}],s:[i,l("seconds")],ss:[i,l("seconds")],m:[i,l("minutes")],mm:[i,l("minutes")],H:[i,l("hours")],h:[i,l("hours")],HH:[i,l("hours")],hh:[i,l("hours")],D:[i,l("day")],DD:[r,l("day")],Do:[a,function(t){var e=s.ordinal,n=t.match(/\d+/);if(this.day=n[0],e)for(var r=1;r<=31;r+=1)e(r).replace(/\[|\]/g,"")===t&&(this.day=r)}],w:[i,l("week")],ww:[r,l("week")],M:[i,l("month")],MM:[r,l("month")],MMM:[a,function(t){var e=h("months"),n=(h("monthsShort")||e.map((function(t){return t.slice(0,3)}))).indexOf(t)+1;if(n<1)throw new Error;this.month=n%12||n}],MMMM:[a,function(t){var e=h("months").indexOf(t)+1;if(e<1)throw new Error;this.month=e%12||e}],Y:[/[+-]?\d+/,l("year")],YY:[r,function(t){this.year=o(t)}],YYYY:[/\d{4}/,l("year")],Z:c,ZZ:c};function p(n){var r,i;r=n,i=s&&s.formats;for(var a=(n=r.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(e,n,r){var a=r&&r.toUpperCase();return n||i[r]||t[r]||i[a].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(t,e,n){return e||n.slice(1)}))}))).match(e),o=a.length,l=0;l-1)return new Date(("X"===e?1e3:1)*t);var i=p(e)(t),a=i.year,s=i.month,o=i.day,l=i.hours,c=i.minutes,h=i.seconds,u=i.milliseconds,d=i.zone,g=i.week,f=new Date,m=o||(a||s?1:f.getDate()),y=a||f.getFullYear(),v=0;a&&!s||(v=s>0?s-1:f.getMonth());var x,b=l||0,w=c||0,k=h||0,T=u||0;return d?new Date(Date.UTC(y,v,m,b,w,k,T+60*d.offset*1e3)):n?new Date(Date.UTC(y,v,m,b,w,k,T)):(x=new Date(y,v,m,b,w,k,T),g&&(x=r(x).week(g).toDate()),x)}catch(t){return new Date("")}}(e,o,r,n),this.init(),u&&!0!==u&&(this.$L=this.locale(u).$L),h&&e!=this.format(o)&&(this.$d=new Date("")),s={}}else if(o instanceof Array)for(var d=o.length,g=1;g<=d;g+=1){a[1]=o[g-1];var f=n.apply(this,a);if(f.isValid()){this.$d=f.$d,this.$L=f.$L,this.init();break}g===d&&(this.$d=new Date(""))}else i.call(this,t)}}}()},9542:function(t){t.exports=function(){"use strict";var t="day";return function(e,n,r){var i=function(e){return e.add(4-e.isoWeekday(),t)},a=n.prototype;a.isoWeekYear=function(){return i(this).year()},a.isoWeek=function(e){if(!this.$utils().u(e))return this.add(7*(e-this.isoWeek()),t);var n,a,s,o=i(this),l=(n=this.isoWeekYear(),s=4-(a=(this.$u?r.utc:r)().year(n).startOf("year")).isoWeekday(),a.isoWeekday()>4&&(s+=7),a.add(s,t));return o.diff(l,"week")+1},a.isoWeekday=function(t){return this.$utils().u(t)?this.day()||7:this.day(this.day()%7?t:t-7)};var s=a.startOf;a.startOf=function(t,e){var n=this.$utils(),r=!!n.u(e)||e;return"isoweek"===n.p(t)?r?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):s.bind(this)(t,e)}}}()},2241:function(t){var e;e=function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.i=function(t){return t},n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=26)}([function(t,e,n){"use strict";function r(){}r.QUALITY=1,r.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,r.DEFAULT_INCREMENTAL=!1,r.DEFAULT_ANIMATION_ON_LAYOUT=!0,r.DEFAULT_ANIMATION_DURING_LAYOUT=!1,r.DEFAULT_ANIMATION_PERIOD=50,r.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,r.DEFAULT_GRAPH_MARGIN=15,r.NODE_DIMENSIONS_INCLUDE_LABELS=!1,r.SIMPLE_NODE_SIZE=40,r.SIMPLE_NODE_HALF_SIZE=r.SIMPLE_NODE_SIZE/2,r.EMPTY_COMPOUND_NODE_SIZE=40,r.MIN_EDGE_LENGTH=1,r.WORLD_BOUNDARY=1e6,r.INITIAL_WORLD_BOUNDARY=r.WORLD_BOUNDARY/1e3,r.WORLD_CENTER_X=1200,r.WORLD_CENTER_Y=900,t.exports=r},function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(9);function s(t,e,n){r.call(this,n),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=n,this.bendpoints=[],this.source=t,this.target=e}for(var o in s.prototype=Object.create(r.prototype),r)s[o]=r[o];s.prototype.getSource=function(){return this.source},s.prototype.getTarget=function(){return this.target},s.prototype.isInterGraph=function(){return this.isInterGraph},s.prototype.getLength=function(){return this.length},s.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},s.prototype.getBendpoints=function(){return this.bendpoints},s.prototype.getLca=function(){return this.lca},s.prototype.getSourceInLca=function(){return this.sourceInLca},s.prototype.getTargetInLca=function(){return this.targetInLca},s.prototype.getOtherEnd=function(t){if(this.source===t)return this.target;if(this.target===t)return this.source;throw"Node is not incident with this edge"},s.prototype.getOtherEndInGraph=function(t,e){for(var n=this.getOtherEnd(t),r=e.getGraphManager().getRoot();;){if(n.getOwner()==e)return n;if(n.getOwner()==r)break;n=n.getOwner().getParent()}return null},s.prototype.updateLength=function(){var t=new Array(4);this.isOverlapingSourceAndTarget=i.getIntersection(this.target.getRect(),this.source.getRect(),t),this.isOverlapingSourceAndTarget||(this.lengthX=t[0]-t[2],this.lengthY=t[1]-t[3],Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},s.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=a.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=a.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},t.exports=s},function(t,e,n){"use strict";t.exports=function(t){this.vGraphObject=t}},function(t,e,n){"use strict";var r=n(2),i=n(10),a=n(13),s=n(0),o=n(16),l=n(4);function c(t,e,n,s){null==n&&null==s&&(s=e),r.call(this,s),null!=t.graphManager&&(t=t.graphManager),this.estimatedSize=i.MIN_VALUE,this.inclusionTreeDepth=i.MAX_VALUE,this.vGraphObject=s,this.edges=[],this.graphManager=t,this.rect=null!=n&&null!=e?new a(e.x,e.y,n.width,n.height):new a}for(var h in c.prototype=Object.create(r.prototype),r)c[h]=r[h];c.prototype.getEdges=function(){return this.edges},c.prototype.getChild=function(){return this.child},c.prototype.getOwner=function(){return this.owner},c.prototype.getWidth=function(){return this.rect.width},c.prototype.setWidth=function(t){this.rect.width=t},c.prototype.getHeight=function(){return this.rect.height},c.prototype.setHeight=function(t){this.rect.height=t},c.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},c.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},c.prototype.getCenter=function(){return new l(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},c.prototype.getLocation=function(){return new l(this.rect.x,this.rect.y)},c.prototype.getRect=function(){return this.rect},c.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},c.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},c.prototype.setRect=function(t,e){this.rect.x=t.x,this.rect.y=t.y,this.rect.width=e.width,this.rect.height=e.height},c.prototype.setCenter=function(t,e){this.rect.x=t-this.rect.width/2,this.rect.y=e-this.rect.height/2},c.prototype.setLocation=function(t,e){this.rect.x=t,this.rect.y=e},c.prototype.moveBy=function(t,e){this.rect.x+=t,this.rect.y+=e},c.prototype.getEdgeListToNode=function(t){var e=[],n=this;return n.edges.forEach((function(r){if(r.target==t){if(r.source!=n)throw"Incorrect edge source!";e.push(r)}})),e},c.prototype.getEdgesBetween=function(t){var e=[],n=this;return n.edges.forEach((function(r){if(r.source!=n&&r.target!=n)throw"Incorrect edge source and/or target";r.target!=t&&r.source!=t||e.push(r)})),e},c.prototype.getNeighborsList=function(){var t=new Set,e=this;return e.edges.forEach((function(n){if(n.source==e)t.add(n.target);else{if(n.target!=e)throw"Incorrect incidency!";t.add(n.source)}})),t},c.prototype.withChildren=function(){var t=new Set;if(t.add(this),null!=this.child)for(var e=this.child.getNodes(),n=0;ne&&(this.rect.x-=(this.labelWidth-e)/2,this.setWidth(this.labelWidth)),this.labelHeight>n&&("center"==this.labelPos?this.rect.y-=(this.labelHeight-n)/2:"top"==this.labelPos&&(this.rect.y-=this.labelHeight-n),this.setHeight(this.labelHeight))}}},c.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==i.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},c.prototype.transform=function(t){var e=this.rect.x;e>s.WORLD_BOUNDARY?e=s.WORLD_BOUNDARY:e<-s.WORLD_BOUNDARY&&(e=-s.WORLD_BOUNDARY);var n=this.rect.y;n>s.WORLD_BOUNDARY?n=s.WORLD_BOUNDARY:n<-s.WORLD_BOUNDARY&&(n=-s.WORLD_BOUNDARY);var r=new l(e,n),i=t.inverseTransformPoint(r);this.setLocation(i.x,i.y)},c.prototype.getLeft=function(){return this.rect.x},c.prototype.getRight=function(){return this.rect.x+this.rect.width},c.prototype.getTop=function(){return this.rect.y},c.prototype.getBottom=function(){return this.rect.y+this.rect.height},c.prototype.getParent=function(){return null==this.owner?null:this.owner.getParent()},t.exports=c},function(t,e,n){"use strict";function r(t,e){null==t&&null==e?(this.x=0,this.y=0):(this.x=t,this.y=e)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.setX=function(t){this.x=t},r.prototype.setY=function(t){this.y=t},r.prototype.getDifference=function(t){return new DimensionD(this.x-t.x,this.y-t.y)},r.prototype.getCopy=function(){return new r(this.x,this.y)},r.prototype.translate=function(t){return this.x+=t.width,this.y+=t.height,this},t.exports=r},function(t,e,n){"use strict";var r=n(2),i=n(10),a=n(0),s=n(6),o=n(3),l=n(1),c=n(13),h=n(12),u=n(11);function d(t,e,n){r.call(this,n),this.estimatedSize=i.MIN_VALUE,this.margin=a.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=t,null!=e&&e instanceof s?this.graphManager=e:null!=e&&e instanceof Layout&&(this.graphManager=e.graphManager)}for(var p in d.prototype=Object.create(r.prototype),r)d[p]=r[p];d.prototype.getNodes=function(){return this.nodes},d.prototype.getEdges=function(){return this.edges},d.prototype.getGraphManager=function(){return this.graphManager},d.prototype.getParent=function(){return this.parent},d.prototype.getLeft=function(){return this.left},d.prototype.getRight=function(){return this.right},d.prototype.getTop=function(){return this.top},d.prototype.getBottom=function(){return this.bottom},d.prototype.isConnected=function(){return this.isConnected},d.prototype.add=function(t,e,n){if(null==e&&null==n){var r=t;if(null==this.graphManager)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(r)>-1)throw"Node already in graph!";return r.owner=this,this.getNodes().push(r),r}var i=t;if(!(this.getNodes().indexOf(e)>-1&&this.getNodes().indexOf(n)>-1))throw"Source or target not in graph!";if(e.owner!=n.owner||e.owner!=this)throw"Both owners must be this graph!";return e.owner!=n.owner?null:(i.source=e,i.target=n,i.isInterGraph=!1,this.getEdges().push(i),e.edges.push(i),n!=e&&n.edges.push(i),i)},d.prototype.remove=function(t){var e=t;if(t instanceof o){if(null==e)throw"Node is null!";if(null==e.owner||e.owner!=this)throw"Owner graph is invalid!";if(null==this.graphManager)throw"Owner graph manager is invalid!";for(var n=e.edges.slice(),r=n.length,i=0;i-1&&h>-1))throw"Source and/or target doesn't know this edge!";if(a.source.edges.splice(c,1),a.target!=a.source&&a.target.edges.splice(h,1),-1==(s=a.source.owner.getEdges().indexOf(a)))throw"Not in owner's edge list!";a.source.owner.getEdges().splice(s,1)}},d.prototype.updateLeftTop=function(){for(var t,e,n,r=i.MAX_VALUE,a=i.MAX_VALUE,s=this.getNodes(),o=s.length,l=0;l(t=c.getTop())&&(r=t),a>(e=c.getLeft())&&(a=e)}return r==i.MAX_VALUE?null:(n=null!=s[0].getParent().paddingLeft?s[0].getParent().paddingLeft:this.margin,this.left=a-n,this.top=r-n,new h(this.left,this.top))},d.prototype.updateBounds=function(t){for(var e,n,r,a,s,o=i.MAX_VALUE,l=-i.MAX_VALUE,h=i.MAX_VALUE,u=-i.MAX_VALUE,d=this.nodes,p=d.length,g=0;g(e=f.getLeft())&&(o=e),l<(n=f.getRight())&&(l=n),h>(r=f.getTop())&&(h=r),u<(a=f.getBottom())&&(u=a)}var m=new c(o,h,l-o,u-h);o==i.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),s=null!=d[0].getParent().paddingLeft?d[0].getParent().paddingLeft:this.margin,this.left=m.x-s,this.right=m.x+m.width+s,this.top=m.y-s,this.bottom=m.y+m.height+s},d.calculateBounds=function(t){for(var e,n,r,a,s=i.MAX_VALUE,o=-i.MAX_VALUE,l=i.MAX_VALUE,h=-i.MAX_VALUE,u=t.length,d=0;d(e=p.getLeft())&&(s=e),o<(n=p.getRight())&&(o=n),l>(r=p.getTop())&&(l=r),h<(a=p.getBottom())&&(h=a)}return new c(s,l,o-s,h-l)},d.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},d.prototype.getEstimatedSize=function(){if(this.estimatedSize==i.MIN_VALUE)throw"assert failed";return this.estimatedSize},d.prototype.calcEstimatedSize=function(){for(var t=0,e=this.nodes,n=e.length,r=0;r=this.nodes.length){var l=0;i.forEach((function(e){e.owner==t&&l++})),l==this.nodes.length&&(this.isConnected=!0)}}else this.isConnected=!0},t.exports=d},function(t,e,n){"use strict";var r,i=n(1);function a(t){r=n(5),this.layout=t,this.graphs=[],this.edges=[]}a.prototype.addRoot=function(){var t=this.layout.newGraph(),e=this.layout.newNode(null),n=this.add(t,e);return this.setRootGraph(n),this.rootGraph},a.prototype.add=function(t,e,n,r,i){if(null==n&&null==r&&null==i){if(null==t)throw"Graph is null!";if(null==e)throw"Parent node is null!";if(this.graphs.indexOf(t)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(t),null!=t.parent)throw"Already has a parent!";if(null!=e.child)throw"Already has a child!";return t.parent=e,e.child=t,t}i=n,n=t;var a=(r=e).getOwner(),s=i.getOwner();if(null==a||a.getGraphManager()!=this)throw"Source not in this graph mgr!";if(null==s||s.getGraphManager()!=this)throw"Target not in this graph mgr!";if(a==s)return n.isInterGraph=!1,a.add(n,r,i);if(n.isInterGraph=!0,n.source=r,n.target=i,this.edges.indexOf(n)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(n),null==n.source||null==n.target)throw"Edge source and/or target is null!";if(-1!=n.source.edges.indexOf(n)||-1!=n.target.edges.indexOf(n))throw"Edge already in source and/or target incidency list!";return n.source.edges.push(n),n.target.edges.push(n),n},a.prototype.remove=function(t){if(t instanceof r){var e=t;if(e.getGraphManager()!=this)throw"Graph not in this graph mgr";if(e!=this.rootGraph&&(null==e.parent||e.parent.graphManager!=this))throw"Invalid parent node!";for(var n,a=[],s=(a=a.concat(e.getEdges())).length,o=0;o=e.getRight()?n[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight()):e.getX()<=t.getX()&&e.getRight()>=t.getRight()&&(n[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight())),t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()?n[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()):e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()&&(n[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()));var a=Math.abs((e.getCenterY()-t.getCenterY())/(e.getCenterX()-t.getCenterX()));e.getCenterY()===t.getCenterY()&&e.getCenterX()===t.getCenterX()&&(a=1);var s=a*n[0],o=n[1]/a;n[0]s)return n[0]=r,n[1]=l,n[2]=a,n[3]=x,!1;if(ia)return n[0]=o,n[1]=i,n[2]=y,n[3]=s,!1;if(ra?(n[0]=h,n[1]=u,T=!0):(n[0]=c,n[1]=l,T=!0):E===C&&(r>a?(n[0]=o,n[1]=l,T=!0):(n[0]=d,n[1]=u,T=!0)),-S===C?a>r?(n[2]=v,n[3]=x,_=!0):(n[2]=y,n[3]=m,_=!0):S===C&&(a>r?(n[2]=f,n[3]=m,_=!0):(n[2]=b,n[3]=x,_=!0)),T&&_)return!1;if(r>a?i>s?(A=this.getCardinalDirection(E,C,4),L=this.getCardinalDirection(S,C,2)):(A=this.getCardinalDirection(-E,C,3),L=this.getCardinalDirection(-S,C,1)):i>s?(A=this.getCardinalDirection(-E,C,1),L=this.getCardinalDirection(-S,C,3)):(A=this.getCardinalDirection(E,C,2),L=this.getCardinalDirection(S,C,4)),!T)switch(A){case 1:N=l,M=r+-g/C,n[0]=M,n[1]=N;break;case 2:M=d,N=i+p*C,n[0]=M,n[1]=N;break;case 3:N=u,M=r+g/C,n[0]=M,n[1]=N;break;case 4:M=h,N=i+-p*C,n[0]=M,n[1]=N}if(!_)switch(L){case 1:R=m,I=a+-k/C,n[2]=I,n[3]=R;break;case 2:I=b,R=s+w*C,n[2]=I,n[3]=R;break;case 3:R=x,I=a+k/C,n[2]=I,n[3]=R;break;case 4:I=v,R=s+-w*C,n[2]=I,n[3]=R}}return!1},i.getCardinalDirection=function(t,e,n){return t>e?n:1+n%4},i.getIntersection=function(t,e,n,i){if(null==i)return this.getIntersection2(t,e,n);var a,s,o,l,c,h,u,d=t.x,p=t.y,g=e.x,f=e.y,m=n.x,y=n.y,v=i.x,x=i.y;return 0==(u=(a=f-p)*(l=m-v)-(s=x-y)*(o=d-g))?null:new r((o*(h=v*y-m*x)-l*(c=g*p-d*f))/u,(s*c-a*h)/u)},i.angleOfVector=function(t,e,n,r){var i=void 0;return t!==n?(i=Math.atan((r-e)/(n-t)),n0?1:t<0?-1:0},r.floor=function(t){return t<0?Math.ceil(t):Math.floor(t)},r.ceil=function(t){return t<0?Math.floor(t):Math.ceil(t)},t.exports=r},function(t,e,n){"use strict";function r(){}r.MAX_VALUE=2147483647,r.MIN_VALUE=-2147483648,t.exports=r},function(t,e,n){"use strict";var r=function(){function t(t,e){for(var n=0;n0&&e;){for(o.push(c[0]);o.length>0&&e;){var h=o[0];o.splice(0,1),s.add(h);var u=h.getEdges();for(a=0;a-1&&c.splice(f,1)}s=new Set,l=new Map}else t=[]}return t},d.prototype.createDummyNodesForBendpoints=function(t){for(var e=[],n=t.source,r=this.graphManager.calcLowestCommonAncestor(t.source,t.target),i=0;i0){for(var i=this.edgeToDummyNodes.get(n),a=0;a=0&&e.splice(u,1),h.getNeighborsList().forEach((function(t){if(n.indexOf(t)<0){var e=r.get(t)-1;1==e&&l.push(t),r.set(t,e)}}))}n=n.concat(l),1!=e.length&&2!=e.length||(i=!0,a=e[0])}return a},d.prototype.setGraphManager=function(t){this.graphManager=t},t.exports=d},function(t,e,n){"use strict";function r(){}r.seed=1,r.x=0,r.nextDouble=function(){return r.x=1e4*Math.sin(r.seed++),r.x-Math.floor(r.x)},t.exports=r},function(t,e,n){"use strict";var r=n(4);function i(t,e){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}i.prototype.getWorldOrgX=function(){return this.lworldOrgX},i.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},i.prototype.getWorldOrgY=function(){return this.lworldOrgY},i.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},i.prototype.getWorldExtX=function(){return this.lworldExtX},i.prototype.setWorldExtX=function(t){this.lworldExtX=t},i.prototype.getWorldExtY=function(){return this.lworldExtY},i.prototype.setWorldExtY=function(t){this.lworldExtY=t},i.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},i.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},i.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},i.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},i.prototype.getDeviceExtX=function(){return this.ldeviceExtX},i.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},i.prototype.getDeviceExtY=function(){return this.ldeviceExtY},i.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},i.prototype.transformX=function(t){var e=0,n=this.lworldExtX;return 0!=n&&(e=this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/n),e},i.prototype.transformY=function(t){var e=0,n=this.lworldExtY;return 0!=n&&(e=this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/n),e},i.prototype.inverseTransformX=function(t){var e=0,n=this.ldeviceExtX;return 0!=n&&(e=this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/n),e},i.prototype.inverseTransformY=function(t){var e=0,n=this.ldeviceExtY;return 0!=n&&(e=this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/n),e},i.prototype.inverseTransformPoint=function(t){return new r(this.inverseTransformX(t.x),this.inverseTransformY(t.y))},t.exports=i},function(t,e,n){"use strict";var r=n(15),i=n(7),a=n(0),s=n(8),o=n(9);function l(){r.call(this),this.useSmartIdealEdgeLengthCalculation=i.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=i.DEFAULT_EDGE_LENGTH,this.springConstant=i.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=i.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=i.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=i.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=i.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*i.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=i.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=i.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=i.MAX_ITERATIONS}for(var c in l.prototype=Object.create(r.prototype),r)l[c]=r[c];l.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=i.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},l.prototype.calcIdealEdgeLengths=function(){for(var t,e,n,r,s,o,l=this.getGraphManager().getAllEdges(),c=0;ci.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*i.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(t-i.ADAPTATION_LOWER_NODE_LIMIT)/(i.ADAPTATION_UPPER_NODE_LIMIT-i.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-i.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=i.MAX_NODE_DISPLACEMENT_INCREMENTAL):(t>i.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(i.COOLING_ADAPTATION_FACTOR,1-(t-i.ADAPTATION_LOWER_NODE_LIMIT)/(i.ADAPTATION_UPPER_NODE_LIMIT-i.ADAPTATION_LOWER_NODE_LIMIT)*(1-i.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=i.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(5*this.getAllNodes().length,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},l.prototype.calcSpringForces=function(){for(var t,e=this.getAllEdges(),n=0;n0&&void 0!==arguments[0])||arguments[0],o=arguments.length>1&&void 0!==arguments[1]&&arguments[1],l=this.getAllNodes();if(this.useFRGridVariant)for(this.totalIterations%i.GRID_CALCULATION_CHECK_PERIOD==1&&s&&this.updateGrid(),a=new Set,t=0;t(l=e.getEstimatedSize()*this.gravityRangeFactor)||o>l)&&(t.gravitationForceX=-this.gravityConstant*i,t.gravitationForceY=-this.gravityConstant*a):(s>(l=e.getEstimatedSize()*this.compoundGravityRangeFactor)||o>l)&&(t.gravitationForceX=-this.gravityConstant*i*this.compoundGravityConstant,t.gravitationForceY=-this.gravityConstant*a*this.compoundGravityConstant)},l.prototype.isConverged=function(){var t,e=!1;return this.totalIterations>this.maxIterations/3&&(e=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),t=this.totalDisplacement=o.length||c>=o[0].length))for(var h=0;ht}}]),t}();t.exports=a},function(t,e,n){"use strict";var r=function(){function t(t,e){for(var n=0;n2&&void 0!==arguments[2]?arguments[2]:1,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:-1,a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.sequence1=e,this.sequence2=n,this.match_score=r,this.mismatch_penalty=i,this.gap_penalty=a,this.iMax=e.length+1,this.jMax=n.length+1,this.grid=new Array(this.iMax);for(var s=0;s=0;n--){var r=this.listeners[n];r.event===t&&r.callback===e&&this.listeners.splice(n,1)}},i.emit=function(t,e){for(var n=0;n{"use strict";function r(t,e,n){if(t&&t.length){const[r,i]=e,a=Math.PI/180*n,s=Math.cos(a),o=Math.sin(a);for(const e of t){const[t,n]=e;e[0]=(t-r)*s-(n-i)*o+r,e[1]=(t-r)*o+(n-i)*s+i}}}function i(t,e){return t[0]===e[0]&&t[1]===e[1]}function a(t,e,n,a=1){const s=n,o=Math.max(e,.1),l=t[0]&&t[0][0]&&"number"==typeof t[0][0]?[t]:t,c=[0,0];if(s)for(const t of l)r(t,c,s);const h=function(t,e,n){const r=[];for(const e of t){const t=[...e];i(t[0],t[t.length-1])||t.push([t[0][0],t[0][1]]),t.length>2&&r.push(t)}const a=[];e=Math.max(e,.1);const s=[];for(const t of r)for(let e=0;et.ymine.ymin?1:t.xe.x?1:t.ymax===e.ymax?0:(t.ymax-e.ymax)/Math.abs(t.ymax-e.ymax))),!s.length)return a;let o=[],l=s[0].ymin,c=0;for(;o.length||s.length;){if(s.length){let t=-1;for(let e=0;el);e++)t=e;s.splice(0,t+1).forEach((t=>{o.push({s:l,edge:t})}))}if(o=o.filter((t=>!(t.edge.ymax<=l))),o.sort(((t,e)=>t.edge.x===e.edge.x?0:(t.edge.x-e.edge.x)/Math.abs(t.edge.x-e.edge.x))),(1!==n||c%e==0)&&o.length>1)for(let t=0;t=o.length)break;const n=o[t].edge,r=o[e].edge;a.push([[Math.round(n.x),l],[Math.round(r.x),l]])}l+=n,o.forEach((t=>{t.edge.x=t.edge.x+n*t.edge.islope})),c++}return a}(l,o,a);if(s){for(const t of l)r(t,c,-s);!function(t,e,n){const i=[];t.forEach((t=>i.push(...t))),r(i,e,n)}(h,c,-s)}return h}function s(t,e){var n;const r=e.hachureAngle+90;let i=e.hachureGap;i<0&&(i=4*e.strokeWidth),i=Math.round(Math.max(i,.1));let s=1;return e.roughness>=1&&((null===(n=e.randomizer)||void 0===n?void 0:n.next())||Math.random())>.7&&(s=i),a(t,i,r,s||1)}n.d(e,{Z:()=>ot});class o{constructor(t){this.helper=t}fillPolygons(t,e){return this._fillPolygons(t,e)}_fillPolygons(t,e){const n=s(t,e);return{type:"fillSketch",ops:this.renderLines(n,e)}}renderLines(t,e){const n=[];for(const r of t)n.push(...this.helper.doubleLineOps(r[0][0],r[0][1],r[1][0],r[1][1],e));return n}}function l(t){const e=t[0],n=t[1];return Math.sqrt(Math.pow(e[0]-n[0],2)+Math.pow(e[1]-n[1],2))}class c extends o{fillPolygons(t,e){let n=e.hachureGap;n<0&&(n=4*e.strokeWidth),n=Math.max(n,.1);const r=s(t,Object.assign({},e,{hachureGap:n})),i=Math.PI/180*e.hachureAngle,a=[],o=.5*n*Math.cos(i),c=.5*n*Math.sin(i);for(const[t,e]of r)l([t,e])&&a.push([[t[0]-o,t[1]+c],[...e]],[[t[0]+o,t[1]-c],[...e]]);return{type:"fillSketch",ops:this.renderLines(a,e)}}}class h extends o{fillPolygons(t,e){const n=this._fillPolygons(t,e),r=Object.assign({},e,{hachureAngle:e.hachureAngle+90}),i=this._fillPolygons(t,r);return n.ops=n.ops.concat(i.ops),n}}class u{constructor(t){this.helper=t}fillPolygons(t,e){const n=s(t,e=Object.assign({},e,{hachureAngle:0}));return this.dotsOnLines(n,e)}dotsOnLines(t,e){const n=[];let r=e.hachureGap;r<0&&(r=4*e.strokeWidth),r=Math.max(r,.1);let i=e.fillWeight;i<0&&(i=e.strokeWidth/2);const a=r/4;for(const s of t){const t=l(s),o=t/r,c=Math.ceil(o)-1,h=t-c*r,u=(s[0][0]+s[1][0])/2-r/4,d=Math.min(s[0][1],s[1][1]);for(let t=0;t{const a=l(t),s=Math.floor(a/(n+r)),o=(a+r-s*(n+r))/2;let c=t[0],h=t[1];c[0]>h[0]&&(c=t[1],h=t[0]);const u=Math.atan((h[1]-c[1])/(h[0]-c[0]));for(let t=0;t{const i=l(t),a=Math.round(i/(2*e));let s=t[0],o=t[1];s[0]>o[0]&&(s=t[1],o=t[0]);const c=Math.atan((o[1]-s[1])/(o[0]-s[0]));for(let t=0;tr%2?t+n:t+e));a.push({key:"C",data:t}),e=t[4],n=t[5];break}case"Q":a.push({key:"Q",data:[...o]}),e=o[2],n=o[3];break;case"q":{const t=o.map(((t,r)=>r%2?t+n:t+e));a.push({key:"Q",data:t}),e=t[2],n=t[3];break}case"A":a.push({key:"A",data:[...o]}),e=o[5],n=o[6];break;case"a":e+=o[5],n+=o[6],a.push({key:"A",data:[o[0],o[1],o[2],o[3],o[4],e,n]});break;case"H":a.push({key:"H",data:[...o]}),e=o[0];break;case"h":e+=o[0],a.push({key:"H",data:[e]});break;case"V":a.push({key:"V",data:[...o]}),n=o[0];break;case"v":n+=o[0],a.push({key:"V",data:[n]});break;case"S":a.push({key:"S",data:[...o]}),e=o[2],n=o[3];break;case"s":{const t=o.map(((t,r)=>r%2?t+n:t+e));a.push({key:"S",data:t}),e=t[2],n=t[3];break}case"T":a.push({key:"T",data:[...o]}),e=o[0],n=o[1];break;case"t":e+=o[0],n+=o[1],a.push({key:"T",data:[e,n]});break;case"Z":case"z":a.push({key:"Z",data:[]}),e=r,n=i}return a}function T(t){const e=[];let n="",r=0,i=0,a=0,s=0,o=0,l=0;for(const{key:c,data:h}of t){switch(c){case"M":e.push({key:"M",data:[...h]}),[r,i]=h,[a,s]=h;break;case"C":e.push({key:"C",data:[...h]}),r=h[4],i=h[5],o=h[2],l=h[3];break;case"L":e.push({key:"L",data:[...h]}),[r,i]=h;break;case"H":r=h[0],e.push({key:"L",data:[r,i]});break;case"V":i=h[0],e.push({key:"L",data:[r,i]});break;case"S":{let t=0,a=0;"C"===n||"S"===n?(t=r+(r-o),a=i+(i-l)):(t=r,a=i),e.push({key:"C",data:[t,a,...h]}),o=h[0],l=h[1],r=h[2],i=h[3];break}case"T":{const[t,a]=h;let s=0,c=0;"Q"===n||"T"===n?(s=r+(r-o),c=i+(i-l)):(s=r,c=i);const u=r+2*(s-r)/3,d=i+2*(c-i)/3,p=t+2*(s-t)/3,g=a+2*(c-a)/3;e.push({key:"C",data:[u,d,p,g,t,a]}),o=s,l=c,r=t,i=a;break}case"Q":{const[t,n,a,s]=h,c=r+2*(t-r)/3,u=i+2*(n-i)/3,d=a+2*(t-a)/3,p=s+2*(n-s)/3;e.push({key:"C",data:[c,u,d,p,a,s]}),o=t,l=n,r=a,i=s;break}case"A":{const t=Math.abs(h[0]),n=Math.abs(h[1]),a=h[2],s=h[3],o=h[4],l=h[5],c=h[6];0===t||0===n?(e.push({key:"C",data:[r,i,l,c,l,c]}),r=l,i=c):r===l&&i===c||(E(r,i,l,c,t,n,a,s,o).forEach((function(t){e.push({key:"C",data:t})})),r=l,i=c);break}case"Z":e.push({key:"Z",data:[]}),r=a,i=s}n=c}return e}function _(t,e,n){return[t*Math.cos(n)-e*Math.sin(n),t*Math.sin(n)+e*Math.cos(n)]}function E(t,e,n,r,i,a,s,o,l,c){const h=(u=s,Math.PI*u/180);var u;let d=[],p=0,g=0,f=0,m=0;if(c)[p,g,f,m]=c;else{[t,e]=_(t,e,-h),[n,r]=_(n,r,-h);const s=(t-n)/2,c=(e-r)/2;let u=s*s/(i*i)+c*c/(a*a);u>1&&(u=Math.sqrt(u),i*=u,a*=u);const d=i*i,y=a*a,v=d*y-d*c*c-y*s*s,x=d*c*c+y*s*s,b=(o===l?-1:1)*Math.sqrt(Math.abs(v/x));f=b*i*c/a+(t+n)/2,m=b*-a*s/i+(e+r)/2,p=Math.asin(parseFloat(((e-m)/a).toFixed(9))),g=Math.asin(parseFloat(((r-m)/a).toFixed(9))),tg&&(p-=2*Math.PI),!l&&g>p&&(g-=2*Math.PI)}let y=g-p;if(Math.abs(y)>120*Math.PI/180){const t=g,e=n,o=r;g=l&&g>p?p+120*Math.PI/180*1:p+120*Math.PI/180*-1,d=E(n=f+i*Math.cos(g),r=m+a*Math.sin(g),e,o,i,a,s,0,l,[g,t,f,m])}y=g-p;const v=Math.cos(p),x=Math.sin(p),b=Math.cos(g),w=Math.sin(g),k=Math.tan(y/4),T=4/3*i*k,S=4/3*a*k,C=[t,e],A=[t+T*x,e-S*v],L=[n+T*w,r-S*b],M=[n,r];if(A[0]=2*C[0]-A[0],A[1]=2*C[1]-A[1],c)return[A,L,M].concat(d);{d=[A,L,M].concat(d);const t=[];for(let e=0;e2){const i=[];for(let e=0;e2*Math.PI&&(p=0,g=2*Math.PI);const f=2*Math.PI/l.curveStepCount,m=Math.min(f/2,(g-p)/2),y=G(m,c,h,u,d,p,g,1,l);if(!l.disableMultiStroke){const t=G(m,c,h,u,d,p,g,1.5,l);y.push(...t)}return s&&(o?y.push(...W(c,h,c+u*Math.cos(p),h+d*Math.sin(p),l),...W(c,h,c+u*Math.cos(g),h+d*Math.sin(g),l)):y.push({op:"lineTo",data:[c,h]},{op:"lineTo",data:[c+u*Math.cos(p),h+d*Math.sin(p)]})),{type:"path",ops:y}}function R(t,e){const n=T(k(w(t))),r=[];let i=[0,0],a=[0,0];for(const{key:t,data:s}of n)switch(t){case"M":a=[s[0],s[1]],i=[s[0],s[1]];break;case"L":r.push(...W(a[0],a[1],s[0],s[1],e)),a=[s[0],s[1]];break;case"C":{const[t,n,i,o,l,c]=s;r.push(...V(t,n,i,o,l,c,a,e)),a=[l,c];break}case"Z":r.push(...W(a[0],a[1],i[0],i[1],e)),a=[i[0],i[1]]}return{type:"path",ops:r}}function D(t,e){const n=[];for(const r of t)if(r.length){const t=e.maxRandomnessOffset||0,i=r.length;if(i>2){n.push({op:"move",data:[r[0][0]+F(t,e),r[0][1]+F(t,e)]});for(let a=1;a500?.4:-.0016668*l+1.233334;let h=i.maxRandomnessOffset||0;h*h*100>o&&(h=l/10);const u=h/2,d=.2+.2*$(i);let p=i.bowing*i.maxRandomnessOffset*(r-e)/200,g=i.bowing*i.maxRandomnessOffset*(t-n)/200;p=F(p,i,c),g=F(g,i,c);const f=[],m=()=>F(u,i,c),y=()=>F(h,i,c),v=i.preserveVertices;return a&&(s?f.push({op:"move",data:[t+(v?0:m()),e+(v?0:m())]}):f.push({op:"move",data:[t+(v?0:F(h,i,c)),e+(v?0:F(h,i,c))]})),s?f.push({op:"bcurveTo",data:[p+t+(n-t)*d+m(),g+e+(r-e)*d+m(),p+t+2*(n-t)*d+m(),g+e+2*(r-e)*d+m(),n+(v?0:m()),r+(v?0:m())]}):f.push({op:"bcurveTo",data:[p+t+(n-t)*d+y(),g+e+(r-e)*d+y(),p+t+2*(n-t)*d+y(),g+e+2*(r-e)*d+y(),n+(v?0:y()),r+(v?0:y())]}),f}function Z(t,e,n){if(!t.length)return[];const r=[];r.push([t[0][0]+F(e,n),t[0][1]+F(e,n)]),r.push([t[0][0]+F(e,n),t[0][1]+F(e,n)]);for(let i=1;i3){const a=[],s=1-n.curveTightness;i.push({op:"move",data:[t[1][0],t[1][1]]});for(let e=1;e+21&&i.push(n)):i.push(n),i.push(t[e+3])}else{const r=.5,a=t[e+0],s=t[e+1],o=t[e+2],l=t[e+3],c=K(a,s,r),h=K(s,o,r),u=K(o,l,r),d=K(c,h,r),p=K(h,u,r),g=K(d,p,r);Q([a,c,d,g],0,n,i),Q([g,p,u,l],0,n,i)}var a,s;return i}function J(t,e){return tt(t,0,t.length,e)}function tt(t,e,n,r,i){const a=i||[],s=t[e],o=t[n-1];let l=0,c=1;for(let r=e+1;rl&&(l=e,c=r)}return Math.sqrt(l)>r?(tt(t,e,c+1,r,a),tt(t,c,n,r,a)):(a.length||a.push(s),a.push(o)),a}function et(t,e=.15,n){const r=[],i=(t.length-1)/3;for(let n=0;n0?tt(r,0,r.length,n):r}const nt="none";class rt{constructor(t){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=t||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(t){return t?Object.assign({},this.defaultOptions,t):this.defaultOptions}_d(t,e,n){return{shape:t,sets:e||[],options:n||this.defaultOptions}}line(t,e,n,r,i){const a=this._o(i);return this._d("line",[C(t,e,n,r,a)],a)}rectangle(t,e,n,r,i){const a=this._o(i),s=[],o=function(t,e,n,r,i){return function(t,e){return A(t,!0,e)}([[t,e],[t+n,e],[t+n,e+r],[t,e+r]],i)}(t,e,n,r,a);if(a.fill){const i=[[t,e],[t+n,e],[t+n,e+r],[t,e+r]];"solid"===a.fillStyle?s.push(D([i],a)):s.push(O([i],a))}return a.stroke!==nt&&s.push(o),this._d("rectangle",s,a)}ellipse(t,e,n,r,i){const a=this._o(i),s=[],o=M(n,r,a),l=N(t,e,a,o);if(a.fill)if("solid"===a.fillStyle){const n=N(t,e,a,o).opset;n.type="fillPath",s.push(n)}else s.push(O([l.estimatedPoints],a));return a.stroke!==nt&&s.push(l.opset),this._d("ellipse",s,a)}circle(t,e,n,r){const i=this.ellipse(t,e,n,n,r);return i.shape="circle",i}linearPath(t,e){const n=this._o(e);return this._d("linearPath",[A(t,!1,n)],n)}arc(t,e,n,r,i,a,s=!1,o){const l=this._o(o),c=[],h=I(t,e,n,r,i,a,s,!0,l);if(s&&l.fill)if("solid"===l.fillStyle){const s=Object.assign({},l);s.disableMultiStroke=!0;const o=I(t,e,n,r,i,a,!0,!1,s);o.type="fillPath",c.push(o)}else c.push(function(t,e,n,r,i,a,s){const o=t,l=e;let c=Math.abs(n/2),h=Math.abs(r/2);c+=F(.01*c,s),h+=F(.01*h,s);let u=i,d=a;for(;u<0;)u+=2*Math.PI,d+=2*Math.PI;d-u>2*Math.PI&&(u=0,d=2*Math.PI);const p=(d-u)/s.curveStepCount,g=[];for(let t=u;t<=d;t+=p)g.push([o+c*Math.cos(t),l+h*Math.sin(t)]);return g.push([o+c*Math.cos(d),l+h*Math.sin(d)]),g.push([o,l]),O([g],s)}(t,e,n,r,i,a,l));return l.stroke!==nt&&c.push(h),this._d("arc",c,l)}curve(t,e){const n=this._o(e),r=[],i=L(t,n);if(n.fill&&n.fill!==nt)if("solid"===n.fillStyle){const e=L(t,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:"fillPath",ops:this._mergedShape(e.ops)})}else{const e=[],i=t;if(i.length){const t="number"==typeof i[0][0]?[i]:i;for(const r of t)r.length<3?e.push(...r):3===r.length?e.push(...et(j([r[0],r[0],r[1],r[2]]),10,(1+n.roughness)/2)):e.push(...et(j(r),10,(1+n.roughness)/2))}e.length&&r.push(O([e],n))}return n.stroke!==nt&&r.push(i),this._d("curve",r,n)}polygon(t,e){const n=this._o(e),r=[],i=A(t,!0,n);return n.fill&&("solid"===n.fillStyle?r.push(D([t],n)):r.push(O([t],n))),n.stroke!==nt&&r.push(i),this._d("polygon",r,n)}path(t,e){const n=this._o(e),r=[];if(!t)return this._d("path",r,n);t=(t||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");const i=n.fill&&"transparent"!==n.fill&&n.fill!==nt,a=n.stroke!==nt,s=!!(n.simplification&&n.simplification<1),o=function(t,e,n){const r=T(k(w(t))),i=[];let a=[],s=[0,0],o=[];const l=()=>{o.length>=4&&a.push(...et(o,1)),o=[]},c=()=>{l(),a.length&&(i.push(a),a=[])};for(const{key:t,data:e}of r)switch(t){case"M":c(),s=[e[0],e[1]],a.push(s);break;case"L":l(),a.push([e[0],e[1]]);break;case"C":if(!o.length){const t=a.length?a[a.length-1]:s;o.push([t[0],t[1]])}o.push([e[0],e[1]]),o.push([e[2],e[3]]),o.push([e[4],e[5]]);break;case"Z":l(),a.push([s[0],s[1]])}if(c(),!n)return i;const h=[];for(const t of i){const e=J(t,n);e.length&&h.push(e)}return h}(t,0,s?4-4*(n.simplification||1):(1+n.roughness)/2),l=R(t,n);if(i)if("solid"===n.fillStyle)if(1===o.length){const e=R(t,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));r.push({type:"fillPath",ops:this._mergedShape(e.ops)})}else r.push(D(o,n));else r.push(O(o,n));return a&&(s?o.forEach((t=>{r.push(A(t,!1,n))})):r.push(l)),this._d("path",r,n)}opsToPath(t,e){let n="";for(const r of t.ops){const t="number"==typeof e&&e>=0?r.data.map((t=>+t.toFixed(e))):r.data;switch(r.op){case"move":n+=`M${t[0]} ${t[1]} `;break;case"bcurveTo":n+=`C${t[0]} ${t[1]}, ${t[2]} ${t[3]}, ${t[4]} ${t[5]} `;break;case"lineTo":n+=`L${t[0]} ${t[1]} `}}return n.trim()}toPaths(t){const e=t.sets||[],n=t.options||this.defaultOptions,r=[];for(const t of e){let e=null;switch(t.type){case"path":e={d:this.opsToPath(t),stroke:n.stroke,strokeWidth:n.strokeWidth,fill:nt};break;case"fillPath":e={d:this.opsToPath(t),stroke:nt,strokeWidth:0,fill:n.fill||nt};break;case"fillSketch":e=this.fillSketch(t,n)}e&&r.push(e)}return r}fillSketch(t,e){let n=e.fillWeight;return n<0&&(n=e.strokeWidth/2),{d:this.opsToPath(t),stroke:e.fill||nt,strokeWidth:n,fill:nt}}_mergedShape(t){return t.filter(((t,e)=>0===e||"move"!==t.op))}}class it{constructor(t,e){this.canvas=t,this.ctx=this.canvas.getContext("2d"),this.gen=new rt(e)}draw(t){const e=t.sets||[],n=t.options||this.getDefaultOptions(),r=this.ctx,i=t.options.fixedDecimalPlaceDigits;for(const a of e)switch(a.type){case"path":r.save(),r.strokeStyle="none"===n.stroke?"transparent":n.stroke,r.lineWidth=n.strokeWidth,n.strokeLineDash&&r.setLineDash(n.strokeLineDash),n.strokeLineDashOffset&&(r.lineDashOffset=n.strokeLineDashOffset),this._drawToContext(r,a,i),r.restore();break;case"fillPath":{r.save(),r.fillStyle=n.fill||"";const e="curve"===t.shape||"polygon"===t.shape||"path"===t.shape?"evenodd":"nonzero";this._drawToContext(r,a,i,e),r.restore();break}case"fillSketch":this.fillSketch(r,a,n)}}fillSketch(t,e,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2),t.save(),n.fillLineDash&&t.setLineDash(n.fillLineDash),n.fillLineDashOffset&&(t.lineDashOffset=n.fillLineDashOffset),t.strokeStyle=n.fill||"",t.lineWidth=r,this._drawToContext(t,e,n.fixedDecimalPlaceDigits),t.restore()}_drawToContext(t,e,n,r="nonzero"){t.beginPath();for(const r of e.ops){const e="number"==typeof n&&n>=0?r.data.map((t=>+t.toFixed(n))):r.data;switch(r.op){case"move":t.moveTo(e[0],e[1]);break;case"bcurveTo":t.bezierCurveTo(e[0],e[1],e[2],e[3],e[4],e[5]);break;case"lineTo":t.lineTo(e[0],e[1])}}"fillPath"===e.type?t.fill(r):t.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(t,e,n,r,i){const a=this.gen.line(t,e,n,r,i);return this.draw(a),a}rectangle(t,e,n,r,i){const a=this.gen.rectangle(t,e,n,r,i);return this.draw(a),a}ellipse(t,e,n,r,i){const a=this.gen.ellipse(t,e,n,r,i);return this.draw(a),a}circle(t,e,n,r){const i=this.gen.circle(t,e,n,r);return this.draw(i),i}linearPath(t,e){const n=this.gen.linearPath(t,e);return this.draw(n),n}polygon(t,e){const n=this.gen.polygon(t,e);return this.draw(n),n}arc(t,e,n,r,i,a,s=!1,o){const l=this.gen.arc(t,e,n,r,i,a,s,o);return this.draw(l),l}curve(t,e){const n=this.gen.curve(t,e);return this.draw(n),n}path(t,e){const n=this.gen.path(t,e);return this.draw(n),n}}const at="http://www.w3.org/2000/svg";class st{constructor(t,e){this.svg=t,this.gen=new rt(e)}draw(t){const e=t.sets||[],n=t.options||this.getDefaultOptions(),r=this.svg.ownerDocument||window.document,i=r.createElementNS(at,"g"),a=t.options.fixedDecimalPlaceDigits;for(const s of e){let e=null;switch(s.type){case"path":e=r.createElementNS(at,"path"),e.setAttribute("d",this.opsToPath(s,a)),e.setAttribute("stroke",n.stroke),e.setAttribute("stroke-width",n.strokeWidth+""),e.setAttribute("fill","none"),n.strokeLineDash&&e.setAttribute("stroke-dasharray",n.strokeLineDash.join(" ").trim()),n.strokeLineDashOffset&&e.setAttribute("stroke-dashoffset",`${n.strokeLineDashOffset}`);break;case"fillPath":e=r.createElementNS(at,"path"),e.setAttribute("d",this.opsToPath(s,a)),e.setAttribute("stroke","none"),e.setAttribute("stroke-width","0"),e.setAttribute("fill",n.fill||""),"curve"!==t.shape&&"polygon"!==t.shape||e.setAttribute("fill-rule","evenodd");break;case"fillSketch":e=this.fillSketch(r,s,n)}e&&i.appendChild(e)}return i}fillSketch(t,e,n){let r=n.fillWeight;r<0&&(r=n.strokeWidth/2);const i=t.createElementNS(at,"path");return i.setAttribute("d",this.opsToPath(e,n.fixedDecimalPlaceDigits)),i.setAttribute("stroke",n.fill||""),i.setAttribute("stroke-width",r+""),i.setAttribute("fill","none"),n.fillLineDash&&i.setAttribute("stroke-dasharray",n.fillLineDash.join(" ").trim()),n.fillLineDashOffset&&i.setAttribute("stroke-dashoffset",`${n.fillLineDashOffset}`),i}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(t,e){return this.gen.opsToPath(t,e)}line(t,e,n,r,i){const a=this.gen.line(t,e,n,r,i);return this.draw(a)}rectangle(t,e,n,r,i){const a=this.gen.rectangle(t,e,n,r,i);return this.draw(a)}ellipse(t,e,n,r,i){const a=this.gen.ellipse(t,e,n,r,i);return this.draw(a)}circle(t,e,n,r){const i=this.gen.circle(t,e,n,r);return this.draw(i)}linearPath(t,e){const n=this.gen.linearPath(t,e);return this.draw(n)}polygon(t,e){const n=this.gen.polygon(t,e);return this.draw(n)}arc(t,e,n,r,i,a,s=!1,o){const l=this.gen.arc(t,e,n,r,i,a,s,o);return this.draw(l)}curve(t,e){const n=this.gen.curve(t,e);return this.draw(n)}path(t,e){const n=this.gen.path(t,e);return this.draw(n)}}var ot={canvas:(t,e)=>new it(t,e),svg:(t,e)=>new st(t,e),generator:t=>new rt(t),newSeed:()=>rt.newSeed()}},8464:(t,e,n)=>{"use strict";function r(t){for(var e=[],n=1;nr})},3881:(t,e,n)=>{"use strict";e.AU=e.Ts=void 0;const r=n(147),i=n(7574),a=n(7135);var s;!function(t){t.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:a.Event.None}),t.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:a.Event.None}),t.is=function(e){const n=e;return n&&(n===t.None||n===t.Cancelled||i.boolean(n.isCancellationRequested)&&!!n.onCancellationRequested)}}(s||(e.Ts=s={}));const o=Object.freeze((function(t,e){const n=(0,r.default)().timer.setTimeout(t.bind(e),0);return{dispose(){n.dispose()}}}));class l{constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?o:(this._emitter||(this._emitter=new a.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}}e.AU=class{get token(){return this._token||(this._token=new l),this._token}cancel(){this._token?this._token.cancel():this._token=s.Cancelled}dispose(){this._token?this._token instanceof l&&this._token.dispose():this._token=s.None}}},7135:(t,e,n)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.Emitter=e.Event=void 0;const r=n(147);var i;!function(t){const e={dispose(){}};t.None=function(){return e}}(i||(e.Event=i={}));class a{add(t,e=null,n){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(t),this._contexts.push(e),Array.isArray(n)&&n.push({dispose:()=>this.remove(t,e)})}remove(t,e=null){if(!this._callbacks)return;let n=!1;for(let r=0,i=this._callbacks.length;r{this._callbacks||(this._callbacks=new a),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(t,e);const r={dispose:()=>{this._callbacks&&(this._callbacks.remove(t,e),r.dispose=s._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))}};return Array.isArray(n)&&n.push(r),r}),this._event}fire(t){this._callbacks&&this._callbacks.invoke.call(this._callbacks,t)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}}e.Emitter=s,s._noop=function(){}},7574:(t,e)=>{"use strict";function n(t){return"string"==typeof t||t instanceof String}function r(t){return Array.isArray(t)}Object.defineProperty(e,"__esModule",{value:!0}),e.stringArray=e.array=e.func=e.error=e.number=e.string=e.boolean=void 0,e.boolean=function(t){return!0===t||!1===t},e.string=n,e.number=function(t){return"number"==typeof t||t instanceof Number},e.error=function(t){return t instanceof Error},e.func=function(t){return"function"==typeof t},e.array=r,e.stringArray=function(t){return r(t)&&t.every((t=>n(t)))}},147:(t,e)=>{"use strict";let n;function r(){if(void 0===n)throw new Error("No runtime abstraction layer installed");return n}Object.defineProperty(e,"__esModule",{value:!0}),function(t){t.install=function(t){if(void 0===t)throw new Error("No runtime abstraction layer provided");n=t}}(r||(r={})),e.default=r},5055:(t,e,n)=>{"use strict";function r(t){return t.charCodeAt(0)}function i(t,e){Array.isArray(t)?t.forEach((function(t){e.push(t)})):e.push(t)}function a(t,e){if(!0===t[e])throw"duplicate flag "+e;t[e],t[e]=!0}function s(t){if(void 0===t)throw Error("Internal Error - Should never get here!");return!0}function o(){throw Error("Internal Error - Should never get here!")}function l(t){return"Character"===t.type}n.d(e,{e:()=>m,O:()=>f});const c=[];for(let t=r("0");t<=r("9");t++)c.push(t);const h=[r("_")].concat(c);for(let t=r("a");t<=r("z");t++)h.push(t);for(let t=r("A");t<=r("Z");t++)h.push(t);const u=[r(" "),r("\f"),r("\n"),r("\r"),r("\t"),r("\v"),r("\t"),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r(" "),r("\u2028"),r("\u2029"),r(" "),r(" "),r(" "),r("\ufeff")],d=/[0-9a-fA-F]/,p=/[0-9]/,g=/[1-9]/;class f{constructor(){this.idx=0,this.input="",this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(t){this.idx=t.idx,this.input=t.input,this.groupIdx=t.groupIdx}pattern(t){this.idx=0,this.input=t,this.groupIdx=0,this.consumeChar("/");const e=this.disjunction();this.consumeChar("/");const n={type:"Flags",loc:{begin:this.idx,end:t.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case"g":a(n,"global");break;case"i":a(n,"ignoreCase");break;case"m":a(n,"multiLine");break;case"u":a(n,"unicode");break;case"y":a(n,"sticky")}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:n,value:e,loc:this.loc(0)}}disjunction(){const t=[],e=this.idx;for(t.push(this.alternative());"|"===this.peekChar();)this.consumeChar("|"),t.push(this.alternative());return{type:"Disjunction",value:t,loc:this.loc(e)}}alternative(){const t=[],e=this.idx;for(;this.isTerm();)t.push(this.term());return{type:"Alternative",value:t,loc:this.loc(e)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){const t=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(t)};case"$":return{type:"EndAnchor",loc:this.loc(t)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(t)};case"B":return{type:"NonWordBoundary",loc:this.loc(t)}}throw Error("Invalid Assertion Escape");case"(":let e;switch(this.consumeChar("?"),this.popChar()){case"=":e="Lookahead";break;case"!":e="NegativeLookahead"}s(e);const n=this.disjunction();return this.consumeChar(")"),{type:e,value:n,loc:this.loc(t)}}return o()}quantifier(t=!1){let e;const n=this.idx;switch(this.popChar()){case"*":e={atLeast:0,atMost:1/0};break;case"+":e={atLeast:1,atMost:1/0};break;case"?":e={atLeast:0,atMost:1};break;case"{":const n=this.integerIncludingZero();switch(this.popChar()){case"}":e={atLeast:n,atMost:n};break;case",":let t;this.isDigit()?(t=this.integerIncludingZero(),e={atLeast:n,atMost:t}):e={atLeast:n,atMost:1/0},this.consumeChar("}")}if(!0===t&&void 0===e)return;s(e)}if(!0!==t||void 0!==e)return s(e)?("?"===this.peekChar(0)?(this.consumeChar("?"),e.greedy=!1):e.greedy=!0,e.type="Quantifier",e.loc=this.loc(n),e):void 0}atom(){let t;const e=this.idx;switch(this.peekChar()){case".":t=this.dotAll();break;case"\\":t=this.atomEscape();break;case"[":t=this.characterClass();break;case"(":t=this.group()}return void 0===t&&this.isPatternCharacter()&&(t=this.patternCharacter()),s(t)?(t.loc=this.loc(e),this.isQuantifier()&&(t.quantifier=this.quantifier()),t):o()}dotAll(){return this.consumeChar("."),{type:"Set",complement:!0,value:[r("\n"),r("\r"),r("\u2028"),r("\u2029")]}}atomEscape(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:"GroupBackReference",value:this.positiveInteger()}}characterClassEscape(){let t,e=!1;switch(this.popChar()){case"d":t=c;break;case"D":t=c,e=!0;break;case"s":t=u;break;case"S":t=u,e=!0;break;case"w":t=h;break;case"W":t=h,e=!0}return s(t)?{type:"Set",value:t,complement:e}:o()}controlEscapeAtom(){let t;switch(this.popChar()){case"f":t=r("\f");break;case"n":t=r("\n");break;case"r":t=r("\r");break;case"t":t=r("\t");break;case"v":t=r("\v")}return s(t)?{type:"Character",value:t}:o()}controlLetterEscapeAtom(){this.consumeChar("c");const t=this.popChar();if(!1===/[a-zA-Z]/.test(t))throw Error("Invalid ");return{type:"Character",value:t.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar("0"),{type:"Character",value:r("\0")}}hexEscapeSequenceAtom(){return this.consumeChar("x"),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar("u"),this.parseHexDigits(4)}identityEscapeAtom(){return{type:"Character",value:r(this.popChar())}}classPatternCharacterAtom(){switch(this.peekChar()){case"\n":case"\r":case"\u2028":case"\u2029":case"\\":case"]":throw Error("TBD");default:return{type:"Character",value:r(this.popChar())}}}characterClass(){const t=[];let e=!1;for(this.consumeChar("["),"^"===this.peekChar(0)&&(this.consumeChar("^"),e=!0);this.isClassAtom();){const e=this.classAtom();if(e.type,l(e)&&this.isRangeDash()){this.consumeChar("-");const n=this.classAtom();if(n.type,l(n)){if(n.value=this.input.length)throw Error("Unexpected end of input");this.idx++}loc(t){return{begin:t,end:this.idx}}}class m{visitChildren(t){for(const e in t){const n=t[e];t.hasOwnProperty(e)&&(void 0!==n.type?this.visit(n):Array.isArray(n)&&n.forEach((t=>{this.visit(t)}),this))}}visit(t){switch(t.type){case"Pattern":this.visitPattern(t);break;case"Flags":this.visitFlags(t);break;case"Disjunction":this.visitDisjunction(t);break;case"Alternative":this.visitAlternative(t);break;case"StartAnchor":this.visitStartAnchor(t);break;case"EndAnchor":this.visitEndAnchor(t);break;case"WordBoundary":this.visitWordBoundary(t);break;case"NonWordBoundary":this.visitNonWordBoundary(t);break;case"Lookahead":this.visitLookahead(t);break;case"NegativeLookahead":this.visitNegativeLookahead(t);break;case"Character":this.visitCharacter(t);break;case"Set":this.visitSet(t);break;case"Group":this.visitGroup(t);break;case"GroupBackReference":this.visitGroupBackReference(t);break;case"Quantifier":this.visitQuantifier(t)}this.visitChildren(t)}visitPattern(t){}visitFlags(t){}visitDisjunction(t){}visitAlternative(t){}visitStartAnchor(t){}visitEndAnchor(t){}visitWordBoundary(t){}visitNonWordBoundary(t){}visitLookahead(t){}visitNegativeLookahead(t){}visitCharacter(t){}visitSet(t){}visitGroup(t){}visitGroupBackReference(t){}visitQuantifier(t){}}},2538:(t,e,n)=>{"use strict";n.d(e,{createArchitectureServices:()=>r.i});var r=n(2478);n(806)},6389:(t,e,n)=>{"use strict";n.d(e,{z:()=>c});var r=n(806),i=n(5565),a=n(7072),s=n(3548),o=class extends r.T7{static{(0,r.eW)(this,"GitGraphTokenBuilder")}constructor(){super(["gitGraph"])}},l={parser:{TokenBuilder:(0,r.eW)((()=>new o),"TokenBuilder"),ValueConverter:(0,r.eW)((()=>new r.nr),"ValueConverter")}};function c(t=i.u){const e=(0,a.f3)((0,s.T)(t),r.GS),n=(0,a.f3)((0,s.Q)({shared:e}),r.vn,l);return e.ServiceRegistry.register(n),{shared:e,GitGraph:n}}(0,r.eW)(c,"createGitGraphServices")},5327:(t,e,n)=>{"use strict";n.d(e,{T:()=>c});var r=n(806),i=n(5565),a=n(7072),s=n(3548),o=class extends r.T7{static{(0,r.eW)(this,"RadarTokenBuilder")}constructor(){super(["radar-beta"])}},l={parser:{TokenBuilder:(0,r.eW)((()=>new o),"TokenBuilder"),ValueConverter:(0,r.eW)((()=>new r.nr),"ValueConverter")}};function c(t=i.u){const e=(0,a.f3)((0,s.T)(t),r.GS),n=(0,a.f3)((0,s.Q)({shared:e}),r.gB,l);return e.ServiceRegistry.register(n),{shared:e,Radar:n}}(0,r.eW)(c,"createRadarServices")},806:(t,e,n)=>{"use strict";n.d(e,{T7:()=>mt,kb:()=>gt,Qr:()=>ht,nr:()=>ft,vn:()=>ut,F_:()=>ot,GS:()=>st,bb:()=>lt,WH:()=>ct,gB:()=>dt,eW:()=>f});var r=n(28),i=n(3548),a=n(7072),s=n(3437),o=n(5565),l=n(6883);const c={Grammar:()=>{},LanguageMetaData:()=>({caseInsensitive:!1,fileExtensions:[".langium"],languageId:"langium"})},h={AstReflection:()=>new s.SV};function u(t){var e;const n=function(){const t=(0,a.f3)((0,i.T)(o.u),h),e=(0,a.f3)((0,i.Q)({shared:t}),c);return t.ServiceRegistry.register(e),e}(),r=n.serializer.JsonSerializer.deserialize(t);return n.shared.workspace.LangiumDocumentFactory.fromModel(r,l.o.parse(`memory://${null!==(e=r.name)&&void 0!==e?e:"grammar"}.langium`)),r}var d=n(1930),p=n(7447),g=Object.defineProperty,f=(t,e)=>g(t,"name",{value:e,configurable:!0}),m="Statement",y="Architecture";f((function(t){return q.isInstance(t,y)}),"isArchitecture");var v="Axis",x="Branch";f((function(t){return q.isInstance(t,x)}),"isBranch");var b="Checkout",w="CherryPicking",k="Commit";f((function(t){return q.isInstance(t,k)}),"isCommit");var T="Common";f((function(t){return q.isInstance(t,T)}),"isCommon");var _="Curve",E="Edge",S="Entry",C="GitGraph";f((function(t){return q.isInstance(t,C)}),"isGitGraph");var A="Group",L="Info";f((function(t){return q.isInstance(t,L)}),"isInfo");var M="Junction",N="Merge";f((function(t){return q.isInstance(t,N)}),"isMerge");var I="Option",R="Packet";f((function(t){return q.isInstance(t,R)}),"isPacket");var D="PacketBlock";f((function(t){return q.isInstance(t,D)}),"isPacketBlock");var O="Pie";f((function(t){return q.isInstance(t,O)}),"isPie");var P="PieSection";f((function(t){return q.isInstance(t,P)}),"isPieSection");var $,B,F,W,z,Z,Y="Radar",U="Service",G="Direction",V=class extends r.$v{static{f(this,"MermaidAstReflection")}getAllTypes(){return[y,v,x,b,w,k,T,_,G,E,S,C,A,L,M,N,I,R,D,O,P,Y,U,m]}computeIsSubtype(t,e){switch(t){case x:case b:case w:case k:case N:return this.isSubtype(m,e);case G:return this.isSubtype(C,e);default:return!1}}getReferenceType(t){const e=`${t.container.$type}:${t.property}`;if("Entry:axis"===e)return v;throw new Error(`${e} is not a valid reference id.`)}getTypeMetaData(t){switch(t){case y:return{name:y,properties:[{name:"accDescr"},{name:"accTitle"},{name:"edges",defaultValue:[]},{name:"groups",defaultValue:[]},{name:"junctions",defaultValue:[]},{name:"services",defaultValue:[]},{name:"title"}]};case v:return{name:v,properties:[{name:"label"},{name:"name"}]};case x:return{name:x,properties:[{name:"name"},{name:"order"}]};case b:return{name:b,properties:[{name:"branch"}]};case w:return{name:w,properties:[{name:"id"},{name:"parent"},{name:"tags",defaultValue:[]}]};case k:return{name:k,properties:[{name:"id"},{name:"message"},{name:"tags",defaultValue:[]},{name:"type"}]};case T:return{name:T,properties:[{name:"accDescr"},{name:"accTitle"},{name:"title"}]};case _:return{name:_,properties:[{name:"entries",defaultValue:[]},{name:"label"},{name:"name"}]};case E:return{name:E,properties:[{name:"lhsDir"},{name:"lhsGroup",defaultValue:!1},{name:"lhsId"},{name:"lhsInto",defaultValue:!1},{name:"rhsDir"},{name:"rhsGroup",defaultValue:!1},{name:"rhsId"},{name:"rhsInto",defaultValue:!1},{name:"title"}]};case S:return{name:S,properties:[{name:"axis"},{name:"value"}]};case C:return{name:C,properties:[{name:"accDescr"},{name:"accTitle"},{name:"statements",defaultValue:[]},{name:"title"}]};case A:return{name:A,properties:[{name:"icon"},{name:"id"},{name:"in"},{name:"title"}]};case L:return{name:L,properties:[{name:"accDescr"},{name:"accTitle"},{name:"title"}]};case M:return{name:M,properties:[{name:"id"},{name:"in"}]};case N:return{name:N,properties:[{name:"branch"},{name:"id"},{name:"tags",defaultValue:[]},{name:"type"}]};case I:return{name:I,properties:[{name:"name"},{name:"value",defaultValue:!1}]};case R:return{name:R,properties:[{name:"accDescr"},{name:"accTitle"},{name:"blocks",defaultValue:[]},{name:"title"}]};case D:return{name:D,properties:[{name:"end"},{name:"label"},{name:"start"}]};case O:return{name:O,properties:[{name:"accDescr"},{name:"accTitle"},{name:"sections",defaultValue:[]},{name:"showData",defaultValue:!1},{name:"title"}]};case P:return{name:P,properties:[{name:"label"},{name:"value"}]};case Y:return{name:Y,properties:[{name:"accDescr"},{name:"accTitle"},{name:"axes",defaultValue:[]},{name:"curves",defaultValue:[]},{name:"options",defaultValue:[]},{name:"title"}]};case U:return{name:U,properties:[{name:"icon"},{name:"iconText"},{name:"id"},{name:"in"},{name:"title"}]};case G:return{name:G,properties:[{name:"accDescr"},{name:"accTitle"},{name:"dir"},{name:"statements",defaultValue:[]},{name:"title"}]};default:return{name:t,properties:[]}}}},q=new V,j=f((()=>$??($=u('{"$type":"Grammar","isDeclared":true,"name":"Info","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Info","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"info"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"Keyword","value":"showInfo"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"*"}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"?"}]},"definesHiddenTokens":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}],"cardinality":"+"},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/"},"fragment":false}],"definesHiddenTokens":false,"hiddenTokens":[],"interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"types":[],"usedGrammars":[]}'))),"InfoGrammar"),H=f((()=>B??(B=u('{"$type":"Grammar","isDeclared":true,"name":"Packet","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Packet","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"packet-beta"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Assignment","feature":"blocks","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]},"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"+"},{"$type":"Assignment","feature":"blocks","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]},"cardinality":"+"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"*"}]}]},"definesHiddenTokens":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"PacketBlock","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"start","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"end","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}}],"cardinality":"?"},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/0|[1-9][0-9]*/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|\'[^\']*\'/"},"fragment":false,"hidden":false},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}],"cardinality":"+"},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/"},"fragment":false}],"definesHiddenTokens":false,"hiddenTokens":[],"interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"types":[],"usedGrammars":[]}'))),"PacketGrammar"),X=f((()=>F??(F=u('{"$type":"Grammar","isDeclared":true,"name":"Pie","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Pie","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"pie"},{"$type":"Assignment","feature":"showData","operator":"?=","terminal":{"$type":"Keyword","value":"showData"},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Assignment","feature":"sections","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]},"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"+"},{"$type":"Assignment","feature":"sections","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]},"cardinality":"+"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"*"}]}]},"definesHiddenTokens":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"PieSection","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}},{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"PIE_SECTION_LABEL","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]+\\"/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"PIE_SECTION_VALUE","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/(0|[1-9][0-9]*)(\\\\.[0-9]+)?/"},"fragment":false,"hidden":false},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}],"cardinality":"+"},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/"},"fragment":false}],"definesHiddenTokens":false,"hiddenTokens":[],"interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"types":[],"usedGrammars":[]}'))),"PieGrammar"),K=f((()=>W??(W=u('{"$type":"Grammar","isDeclared":true,"name":"Architecture","imports":[],"rules":[{"$type":"ParserRule","entry":true,"name":"Architecture","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[],"cardinality":"*"},{"$type":"Keyword","value":"architecture-beta"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}]},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[],"cardinality":"*"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[],"cardinality":"*"}]}]},"definesHiddenTokens":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"groups","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}},{"$type":"Assignment","feature":"services","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@6"},"arguments":[]}},{"$type":"Assignment","feature":"junctions","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@7"},"arguments":[]}},{"$type":"Assignment","feature":"edges","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@8"},"arguments":[]}}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"LeftPort","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":":"},{"$type":"Assignment","feature":"lhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"RightPort","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"rhsDir","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@9"},"arguments":[]}},{"$type":"Keyword","value":":"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"Arrow","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]},{"$type":"Assignment","feature":"lhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"cardinality":"?"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"--"},{"$type":"Group","elements":[{"$type":"Keyword","value":"-"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Keyword","value":"-"}]}]},{"$type":"Assignment","feature":"rhsInto","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Group","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"group"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Service","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"service"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"iconText","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"Assignment","feature":"icon","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"?"},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},"cardinality":"?"},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Junction","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"junction"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"in"},{"$type":"Assignment","feature":"in","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Edge","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"lhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"lhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]},{"$type":"Assignment","feature":"rhsId","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@10"},"arguments":[]}},{"$type":"Assignment","feature":"rhsGroup","operator":"?=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"ARROW_DIRECTION","definition":{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"L"}},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"R"}}]},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"T"}}]},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"B"}}]},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARCH_ID","definition":{"$type":"RegexToken","regex":"/[\\\\w]+/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARCH_TEXT_ICON","definition":{"$type":"RegexToken","regex":"/\\\\(\\"[^\\"]+\\"\\\\)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARCH_ICON","definition":{"$type":"RegexToken","regex":"/\\\\([\\\\w-:]+\\\\)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARCH_TITLE","definition":{"$type":"RegexToken","regex":"/\\\\[[\\\\w ]+\\\\]/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_GROUP","definition":{"$type":"RegexToken","regex":"/\\\\{group\\\\}/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ARROW_INTO","definition":{"$type":"RegexToken","regex":"/<|>/"},"fragment":false,"hidden":false},{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}],"cardinality":"+"},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/"},"fragment":false}],"definesHiddenTokens":false,"hiddenTokens":[],"interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"types":[],"usedGrammars":[]}'))),"ArchitectureGrammar"),Q=f((()=>z??(z=u('{"$type":"Grammar","isDeclared":true,"name":"GitGraph","interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]}],"rules":[{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"+"},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/"},"fragment":false},{"$type":"ParserRule","entry":true,"name":"GitGraph","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"Keyword","value":":"}]},{"$type":"Keyword","value":"gitGraph:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"gitGraph"},{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]},{"$type":"Keyword","value":":"}]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]},{"$type":"Assignment","feature":"statements","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}],"cardinality":"*"}]}]},"definesHiddenTokens":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Statement","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Direction","definition":{"$type":"Assignment","feature":"dir","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"LR"},{"$type":"Keyword","value":"TB"},{"$type":"Keyword","value":"BT"}]}},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Commit","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"commit"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"msg:","cardinality":"?"},{"$type":"Assignment","feature":"message","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Branch","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"branch"},{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]}},{"$type":"Group","elements":[{"$type":"Keyword","value":"order:"},{"$type":"Assignment","feature":"order","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}],"cardinality":"?"},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Merge","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"merge"},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]}},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"type:"},{"$type":"Assignment","feature":"type","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"NORMAL"},{"$type":"Keyword","value":"REVERSE"},{"$type":"Keyword","value":"HIGHLIGHT"}]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Checkout","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"checkout"},{"$type":"Keyword","value":"switch"}]},{"$type":"Assignment","feature":"branch","operator":"=","terminal":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]},{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"CherryPicking","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"cherry-pick"},{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Keyword","value":"id:"},{"$type":"Assignment","feature":"id","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"tag:"},{"$type":"Assignment","feature":"tags","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"parent:"},{"$type":"Assignment","feature":"parent","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"INT","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/[0-9]+(?=\\\\s)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/\\\\w([-\\\\./\\\\w]*[-\\\\w])?/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|\'[^\']*\'/"},"fragment":false,"hidden":false}],"definesHiddenTokens":false,"hiddenTokens":[],"imports":[],"types":[],"usedGrammars":[]}'))),"GitGraphGrammar"),J=f((()=>Z??(Z=u('{"$type":"Grammar","isDeclared":true,"name":"Radar","interfaces":[{"$type":"Interface","name":"Common","attributes":[{"$type":"TypeAttribute","name":"accDescr","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"accTitle","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}},{"$type":"TypeAttribute","name":"title","isOptional":true,"type":{"$type":"SimpleType","primitiveType":"string"}}],"superTypes":[]},{"$type":"Interface","name":"Entry","attributes":[{"$type":"TypeAttribute","name":"axis","isOptional":true,"type":{"$type":"ReferenceType","referenceType":{"$type":"SimpleType","typeRef":{"$ref":"#/rules@12"}}}},{"$type":"TypeAttribute","name":"value","type":{"$type":"SimpleType","primitiveType":"number"},"isOptional":false}],"superTypes":[]}],"rules":[{"$type":"ParserRule","fragment":true,"name":"TitleAndAccessibilities","definition":{"$type":"Group","elements":[{"$type":"Alternatives","elements":[{"$type":"Assignment","feature":"accDescr","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@3"},"arguments":[]}},{"$type":"Assignment","feature":"accTitle","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@4"},"arguments":[]}},{"$type":"Assignment","feature":"title","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@5"},"arguments":[]}}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@1"},"arguments":[]}],"cardinality":"+"},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"EOL","dataType":"string","definition":{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"+"},{"$type":"EndOfFile"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"NEWLINE","definition":{"$type":"RegexToken","regex":"/\\\\r?\\\\n/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_DESCR","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accDescr(?:[\\\\t ]*:([^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)|\\\\s*{([^}]*)})/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ACC_TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*accTitle[\\\\t ]*:(?:[^\\\\n\\\\r]*?(?=%%)|[^\\\\n\\\\r]*)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"TITLE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*title(?:[\\\\t ][^\\\\n\\\\r]*?(?=%%)|[\\\\t ][^\\\\n\\\\r]*|)/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","hidden":true,"name":"WHITESPACE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]+/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"YAML","definition":{"$type":"RegexToken","regex":"/---[\\\\t ]*\\\\r?\\\\n(?:[\\\\S\\\\s]*?\\\\r?\\\\n)?---(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"DIRECTIVE","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%{[\\\\S\\\\s]*?}%%(?:\\\\r?\\\\n|(?!\\\\S))/"},"fragment":false},{"$type":"TerminalRule","hidden":true,"name":"SINGLE_LINE_COMMENT","definition":{"$type":"RegexToken","regex":"/[\\\\t ]*%%[^\\\\n\\\\r]*/"},"fragment":false},{"$type":"ParserRule","entry":true,"name":"Radar","definition":{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":"radar-beta:"},{"$type":"Group","elements":[{"$type":"Keyword","value":"radar-beta"},{"$type":"Keyword","value":":"}]}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Alternatives","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@0"},"arguments":[]},{"$type":"Group","elements":[{"$type":"Keyword","value":"axis"},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"axes","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@12"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Keyword","value":"curve"},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"curves","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@13"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"Assignment","feature":"options","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@17"},"arguments":[]}}],"cardinality":"*"}]},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[]}],"cardinality":"*"}]},"definesHiddenTokens":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"Label","definition":{"$type":"Group","elements":[{"$type":"Keyword","value":"["},{"$type":"Assignment","feature":"label","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@22"},"arguments":[]}},{"$type":"Keyword","value":"]"}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Axis","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Curve","definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]}},{"$type":"RuleCall","rule":{"$ref":"#/rules@11"},"arguments":[],"cardinality":"?"},{"$type":"Keyword","value":"{"},{"$type":"RuleCall","rule":{"$ref":"#/rules@14"},"arguments":[]},{"$type":"Keyword","value":"}"}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","fragment":true,"name":"Entries","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@16"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"}]},{"$type":"Group","elements":[{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}},{"$type":"Group","elements":[{"$type":"Keyword","value":","},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"},{"$type":"Assignment","feature":"entries","operator":"+=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@15"},"arguments":[]}}],"cardinality":"*"},{"$type":"RuleCall","rule":{"$ref":"#/rules@2"},"arguments":[],"cardinality":"*"}]}]},"definesHiddenTokens":false,"entry":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"DetailedEntry","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Group","elements":[{"$type":"Assignment","feature":"axis","operator":"=","terminal":{"$type":"CrossReference","type":{"$ref":"#/rules@12"},"terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@21"},"arguments":[]},"deprecatedSyntax":false}},{"$type":"Keyword","value":":","cardinality":"?"},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"NumberEntry","returnType":{"$ref":"#/interfaces@1"},"definition":{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"ParserRule","name":"Option","definition":{"$type":"Alternatives","elements":[{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"showLegend"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@19"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"ticks"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"max"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"min"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@18"},"arguments":[]}}]},{"$type":"Group","elements":[{"$type":"Assignment","feature":"name","operator":"=","terminal":{"$type":"Keyword","value":"graticule"}},{"$type":"Assignment","feature":"value","operator":"=","terminal":{"$type":"RuleCall","rule":{"$ref":"#/rules@20"},"arguments":[]}}]}]},"definesHiddenTokens":false,"entry":false,"fragment":false,"hiddenTokens":[],"parameters":[],"wildcard":false},{"$type":"TerminalRule","name":"NUMBER","type":{"$type":"ReturnType","name":"number"},"definition":{"$type":"RegexToken","regex":"/(0|[1-9][0-9]*)(\\\\.[0-9]+)?/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"BOOLEAN","type":{"$type":"ReturnType","name":"boolean"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"true"}},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"false"}}]},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"GRATICULE","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"TerminalAlternatives","elements":[{"$type":"CharacterRange","left":{"$type":"Keyword","value":"circle"}},{"$type":"CharacterRange","left":{"$type":"Keyword","value":"polygon"}}]},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"ID","type":{"$type":"ReturnType","name":"string"},"definition":{"$type":"RegexToken","regex":"/[a-zA-Z_][a-zA-Z0-9\\\\-_]*/"},"fragment":false,"hidden":false},{"$type":"TerminalRule","name":"STRING","definition":{"$type":"RegexToken","regex":"/\\"[^\\"]*\\"|\'[^\']*\'/"},"fragment":false,"hidden":false}],"definesHiddenTokens":false,"hiddenTokens":[],"imports":[],"types":[],"usedGrammars":[]}'))),"RadarGrammar"),tt={languageId:"info",fileExtensions:[".mmd",".mermaid"],caseInsensitive:!1,mode:"production"},et={languageId:"packet",fileExtensions:[".mmd",".mermaid"],caseInsensitive:!1,mode:"production"},nt={languageId:"pie",fileExtensions:[".mmd",".mermaid"],caseInsensitive:!1,mode:"production"},rt={languageId:"architecture",fileExtensions:[".mmd",".mermaid"],caseInsensitive:!1,mode:"production"},it={languageId:"gitGraph",fileExtensions:[".mmd",".mermaid"],caseInsensitive:!1,mode:"production"},at={languageId:"radar",fileExtensions:[".mmd",".mermaid"],caseInsensitive:!1,mode:"production"},st={AstReflection:f((()=>new V),"AstReflection")},ot={Grammar:f((()=>j()),"Grammar"),LanguageMetaData:f((()=>tt),"LanguageMetaData"),parser:{}},lt={Grammar:f((()=>H()),"Grammar"),LanguageMetaData:f((()=>et),"LanguageMetaData"),parser:{}},ct={Grammar:f((()=>X()),"Grammar"),LanguageMetaData:f((()=>nt),"LanguageMetaData"),parser:{}},ht={Grammar:f((()=>K()),"Grammar"),LanguageMetaData:f((()=>rt),"LanguageMetaData"),parser:{}},ut={Grammar:f((()=>Q()),"Grammar"),LanguageMetaData:f((()=>it),"LanguageMetaData"),parser:{}},dt={Grammar:f((()=>J()),"Grammar"),LanguageMetaData:f((()=>at),"LanguageMetaData"),parser:{}},pt={ACC_DESCR:/accDescr(?:[\t ]*:([^\n\r]*)|\s*{([^}]*)})/,ACC_TITLE:/accTitle[\t ]*:([^\n\r]*)/,TITLE:/title([\t ][^\n\r]*|)/},gt=class extends d.t{static{f(this,"AbstractMermaidValueConverter")}runConverter(t,e,n){let r=this.runCommonConverter(t,e,n);return void 0===r&&(r=this.runCustomConverter(t,e,n)),void 0===r?super.runConverter(t,e,n):r}runCommonConverter(t,e,n){const r=pt[t.name];if(void 0===r)return;const i=r.exec(e);return null!==i?void 0!==i[1]?i[1].trim().replace(/[\t ]{2,}/gm," "):void 0!==i[2]?i[2].replace(/^\s*/gm,"").replace(/\s+$/gm,"").replace(/[\t ]{2,}/gm," ").replace(/[\n\r]{2,}/gm,"\n"):void 0:void 0}},ft=class extends gt{static{f(this,"CommonValueConverter")}runCustomConverter(t,e,n){}},mt=class extends p.P{static{f(this,"AbstractMermaidTokenBuilder")}constructor(t){super(),this.keywords=new Set(t)}buildKeywordTokens(t,e,n){const r=super.buildKeywordTokens(t,e,n);return r.forEach((t=>{this.keywords.has(t.name)&&void 0!==t.PATTERN&&(t.PATTERN=new RegExp(t.PATTERN.toString()+"(?:(?=%%)|(?!\\S))"))})),r}};(class extends mt{static{f(this,"CommonTokenBuilder")}})},2478:(t,e,n)=>{"use strict";n.d(e,{i:()=>h});var r=n(806),i=n(5565),a=n(7072),s=n(3548),o=class extends r.T7{static{(0,r.eW)(this,"ArchitectureTokenBuilder")}constructor(){super(["architecture"])}},l=class extends r.kb{static{(0,r.eW)(this,"ArchitectureValueConverter")}runCustomConverter(t,e,n){return"ARCH_ICON"===t.name?e.replace(/[()]/g,"").trim():"ARCH_TEXT_ICON"===t.name?e.replace(/["()]/g,""):"ARCH_TITLE"===t.name?e.replace(/[[\]]/g,"").trim():void 0}},c={parser:{TokenBuilder:(0,r.eW)((()=>new o),"TokenBuilder"),ValueConverter:(0,r.eW)((()=>new l),"ValueConverter")}};function h(t=i.u){const e=(0,a.f3)((0,s.T)(t),r.GS),n=(0,a.f3)((0,s.Q)({shared:e}),r.Qr,c);return e.ServiceRegistry.register(n),{shared:e,Architecture:n}}(0,r.eW)(h,"createArchitectureServices")},53:(t,e,n)=>{"use strict";n.d(e,{M:()=>c});var r=n(806),i=n(5565),a=n(7072),s=n(3548),o=class extends r.T7{static{(0,r.eW)(this,"InfoTokenBuilder")}constructor(){super(["info","showInfo"])}},l={parser:{TokenBuilder:(0,r.eW)((()=>new o),"TokenBuilder"),ValueConverter:(0,r.eW)((()=>new r.nr),"ValueConverter")}};function c(t=i.u){const e=(0,a.f3)((0,s.T)(t),r.GS),n=(0,a.f3)((0,s.Q)({shared:e}),r.F_,l);return e.ServiceRegistry.register(n),{shared:e,Info:n}}(0,r.eW)(c,"createInfoServices")},6840:(t,e,n)=>{"use strict";n.d(e,{l:()=>h});var r=n(806),i=n(5565),a=n(7072),s=n(3548),o=class extends r.T7{static{(0,r.eW)(this,"PieTokenBuilder")}constructor(){super(["pie","showData"])}},l=class extends r.kb{static{(0,r.eW)(this,"PieValueConverter")}runCustomConverter(t,e,n){if("PIE_SECTION_LABEL"===t.name)return e.replace(/"/g,"").trim()}},c={parser:{TokenBuilder:(0,r.eW)((()=>new o),"TokenBuilder"),ValueConverter:(0,r.eW)((()=>new l),"ValueConverter")}};function h(t=i.u){const e=(0,a.f3)((0,s.T)(t),r.GS),n=(0,a.f3)((0,s.Q)({shared:e}),r.WH,c);return e.ServiceRegistry.register(n),{shared:e,Pie:n}}(0,r.eW)(h,"createPieServices")},7533:(t,e,n)=>{"use strict";n.d(e,{g:()=>c});var r=n(806),i=n(5565),a=n(7072),s=n(3548),o=class extends r.T7{static{(0,r.eW)(this,"PacketTokenBuilder")}constructor(){super(["packet-beta"])}},l={parser:{TokenBuilder:(0,r.eW)((()=>new o),"TokenBuilder"),ValueConverter:(0,r.eW)((()=>new r.nr),"ValueConverter")}};function c(t=i.u){const e=(0,a.f3)((0,s.T)(t),r.GS),n=(0,a.f3)((0,s.Q)({shared:e}),r.bb,l);return e.ServiceRegistry.register(n),{shared:e,Packet:n}}(0,r.eW)(c,"createPacketServices")},5033:(t,e,n)=>{"use strict";n.d(e,{createGitGraphServices:()=>r.z});var r=n(6389);n(806)},1139:(t,e,n)=>{"use strict";n.d(e,{createInfoServices:()=>r.M});var r=n(53);n(806)},5562:(t,e,n)=>{"use strict";n.d(e,{createPacketServices:()=>r.g});var r=n(7533);n(806)},3813:(t,e,n)=>{"use strict";n.d(e,{createPieServices:()=>r.l});var r=n(6840);n(806)},6430:(t,e,n)=>{"use strict";n.d(e,{createRadarServices:()=>r.T});var r=n(5327);n(806)},2491:(t,e,n)=>{"use strict";n.d(e,{Qc:()=>s}),n(6389),n(53),n(7533),n(6840),n(2478),n(5327);var r=n(806),i={},a={info:(0,r.eW)((async()=>{const{createInfoServices:t}=await Promise.resolve().then(n.bind(n,1139)),e=t().Info.parser.LangiumParser;i.info=e}),"info"),packet:(0,r.eW)((async()=>{const{createPacketServices:t}=await Promise.resolve().then(n.bind(n,5562)),e=t().Packet.parser.LangiumParser;i.packet=e}),"packet"),pie:(0,r.eW)((async()=>{const{createPieServices:t}=await Promise.resolve().then(n.bind(n,3813)),e=t().Pie.parser.LangiumParser;i.pie=e}),"pie"),architecture:(0,r.eW)((async()=>{const{createArchitectureServices:t}=await Promise.resolve().then(n.bind(n,2538)),e=t().Architecture.parser.LangiumParser;i.architecture=e}),"architecture"),gitGraph:(0,r.eW)((async()=>{const{createGitGraphServices:t}=await Promise.resolve().then(n.bind(n,5033)),e=t().GitGraph.parser.LangiumParser;i.gitGraph=e}),"gitGraph"),radar:(0,r.eW)((async()=>{const{createRadarServices:t}=await Promise.resolve().then(n.bind(n,6430)),e=t().Radar.parser.LangiumParser;i.radar=e}),"radar")};async function s(t,e){const n=a[t];if(!n)throw new Error(`Unknown diagram type: ${t}`);i[t]||await n();const r=i[t].parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new o(r);return r.value}(0,r.eW)(s,"parse");var o=class extends Error{constructor(t){super(`Parsing failed: ${t.lexerErrors.map((t=>t.message)).join("\n")} ${t.parserErrors.map((t=>t.message)).join("\n")}`),this.result=t}static{(0,r.eW)(this,"MermaidParseError")}}},6435:(t,e,n)=>{"use strict";n.d(e,{ue:()=>Z,_o:()=>Er,sd:()=>ze,nu:()=>Cr,dV:()=>nr,hW:()=>Le,Sj:()=>D,Wx:()=>$,hI:()=>W,ej:()=>B,fK:()=>F,pT:()=>z,oI:()=>Y,ZW:()=>Se,Hs:()=>Ue,oC:()=>yn,l$:()=>Me,ol:()=>Ye});var r=n(870),i=n(4657),a=n(9697),s=n(3836),o=n(3402),l=n(2346);function c(t){function e(){}e.prototype=t;const n=new e;function r(){return typeof n.bar}return r(),r(),t}const h=function(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=Array(i);++r{e.accept(t)}))}}class D extends R{constructor(t){super([]),this.idx=1,w(this,S(t,(t=>void 0!==t)))}set definition(t){}get definition(){return void 0!==this.referencedRule?this.referencedRule.definition:[]}accept(t){t.visit(this)}}class O extends R{constructor(t){super(t.definition),this.orgText="",w(this,S(t,(t=>void 0!==t)))}}class P extends R{constructor(t){super(t.definition),this.ignoreAmbiguities=!1,w(this,S(t,(t=>void 0!==t)))}}class $ extends R{constructor(t){super(t.definition),this.idx=1,w(this,S(t,(t=>void 0!==t)))}}class B extends R{constructor(t){super(t.definition),this.idx=1,w(this,S(t,(t=>void 0!==t)))}}class F extends R{constructor(t){super(t.definition),this.idx=1,w(this,S(t,(t=>void 0!==t)))}}class W extends R{constructor(t){super(t.definition),this.idx=1,w(this,S(t,(t=>void 0!==t)))}}class z extends R{constructor(t){super(t.definition),this.idx=1,w(this,S(t,(t=>void 0!==t)))}}class Z extends R{get definition(){return this._definition}set definition(t){this._definition=t}constructor(t){super(t.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,w(this,S(t,(t=>void 0!==t)))}}class Y{constructor(t){this.idx=1,w(this,S(t,(t=>void 0!==t)))}accept(t){t.visit(this)}}function U(t){function e(t){return(0,s.Z)(t,U)}if(t instanceof D){const e={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return(0,p.Z)(t.label)&&(e.label=t.label),e}if(t instanceof P)return{type:"Alternative",definition:e(t.definition)};if(t instanceof $)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof B)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof F)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:U(new Y({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof z)return{type:"RepetitionWithSeparator",idx:t.idx,separator:U(new Y({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof W)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof Z)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof Y){const e={type:"Terminal",name:t.terminalType.name,label:(n=t.terminalType,r=n,(0,p.Z)(r.LABEL)&&""!==r.LABEL?n.LABEL:n.name),idx:t.idx};(0,p.Z)(t.label)&&(e.terminalLabel=t.label);const i=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(e.pattern=I(i)?i.source:i),e}var n,r;if(t instanceof O)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}class G{walk(t,e=[]){(0,r.Z)(t.definition,((n,r)=>{const i=d(t.definition,r+1);if(n instanceof D)this.walkProdRef(n,i,e);else if(n instanceof Y)this.walkTerminal(n,i,e);else if(n instanceof P)this.walkFlat(n,i,e);else if(n instanceof $)this.walkOption(n,i,e);else if(n instanceof B)this.walkAtLeastOne(n,i,e);else if(n instanceof F)this.walkAtLeastOneSep(n,i,e);else if(n instanceof z)this.walkManySep(n,i,e);else if(n instanceof W)this.walkMany(n,i,e);else{if(!(n instanceof Z))throw Error("non exhaustive match");this.walkOr(n,i,e)}}))}walkTerminal(t,e,n){}walkProdRef(t,e,n){}walkFlat(t,e,n){const r=e.concat(n);this.walk(t,r)}walkOption(t,e,n){const r=e.concat(n);this.walk(t,r)}walkAtLeastOne(t,e,n){const r=[new $({definition:t.definition})].concat(e,n);this.walk(t,r)}walkAtLeastOneSep(t,e,n){const r=V(t,e,n);this.walk(t,r)}walkMany(t,e,n){const r=[new $({definition:t.definition})].concat(e,n);this.walk(t,r)}walkManySep(t,e,n){const r=V(t,e,n);this.walk(t,r)}walkOr(t,e,n){const i=e.concat(n);(0,r.Z)(t.definition,(t=>{const e=new P({definition:[t]});this.walk(e,i)}))}}function V(t,e,n){return[new $({definition:[new Y({terminalType:t.separator})].concat(t.definition)})].concat(e,n)}var q=n(184);const j=function(t){return t&&t.length?(0,q.Z)(t):[]};var H=n(7961),X=n(2338),K=n(8640);const Q=function(t,e){var n;return(0,K.Z)(t,(function(t,r,i){return!(n=e(t,r,i))})),!!n};var J=n(7771),tt=n(439);const et=function(t,e,n){var r=(0,J.Z)(t)?X.Z:Q;return n&&(0,tt.Z)(t,e,n)&&(e=void 0),r(t,(0,T.Z)(e,3))};var nt=n(3152),rt=Math.max;const it=function(t,e,n,r){t=(0,y.Z)(t)?t:(0,i.Z)(t),n=n&&!r?(0,u.Z)(n):0;var a=t.length;return n<0&&(n=rt(a+n,0)),(0,p.Z)(t)?n<=a&&t.indexOf(e,n)>-1:!!a&&(0,nt.Z)(t,e,n)>-1},at=function(t,e){for(var n=-1,r=null==t?0:t.length;++nlt(t,e))):!(t instanceof D&&it(e,t))&&t instanceof R&&(t instanceof D&&e.push(t),ot(t.definition,(t=>lt(t,e)))))}function ct(t){if(t instanceof D)return"SUBRULE";if(t instanceof $)return"OPTION";if(t instanceof Z)return"OR";if(t instanceof B)return"AT_LEAST_ONE";if(t instanceof F)return"AT_LEAST_ONE_SEP";if(t instanceof z)return"MANY_SEP";if(t instanceof W)return"MANY";if(t instanceof Y)return"CONSUME";throw Error("non exhaustive match")}function ht(t){if(t instanceof D)return ht(t.referencedRule);if(t instanceof Y)return[t.terminalType];if(function(t){return t instanceof P||t instanceof $||t instanceof W||t instanceof B||t instanceof F||t instanceof z||t instanceof Y||t instanceof O}(t))return function(t){let e=[];const n=t.definition;let r,i=0,a=n.length>i,s=!0;for(;a&&s;)r=n[i],s=lt(r),e=e.concat(ht(r)),i+=1,a=n.length>i;return j(e)}(t);if(function(t){return t instanceof Z}(t))return function(t){const e=(0,s.Z)(t.definition,(t=>ht(t)));return j((0,H.Z)(e))}(t);throw Error("non exhaustive match")}const ut="_~IN~_";class dt extends G{constructor(t){super(),this.topProd=t,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(t,e,n){}walkProdRef(t,e,n){const r=(i=t.referencedRule,a=t.idx,i.name+a+ut+this.topProd.name);var i,a;const s=e.concat(n),o=ht(new P({definition:s}));this.follows[r]=o}}var pt=n(9360),gt=n(5055),ft=n(3688),mt=n(8774),yt=n(4749);const vt=function(t,e){return((0,J.Z)(t)?mt.Z:yt.Z)(t,function(t){if("function"!=typeof t)throw new TypeError("Expected a function");return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}((0,T.Z)(e,3)))};var xt=n(3234),bt=Math.max;const wt=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=null==n?0:(0,u.Z)(n);return i<0&&(i=bt(r+i,0)),(0,nt.Z)(t,e,i)};var kt=n(4283),Tt=n(9601),_t=n(5084),Et=n(9370),St=n(2783),Ct=n(9548);var At=n(5140),Lt=n(9581),Mt=n(836),Nt=(0,Lt.Z)((function(t,e){return(0,Mt.Z)(t)?function(t,e,n,r){var i=-1,a=Et.Z,s=!0,o=t.length,l=[],c=e.length;if(!o)return l;n&&(e=(0,k.Z)(e,(0,L.Z)(n))),r?(a=St.Z,s=!1):e.length>=200&&(a=Ct.Z,s=!1,e=new _t.Z(e));t:for(;++i\n\tComplement Sets cannot be automatically optimized.\n\tThis will disable the lexer's first char optimizations.\n\tSee: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#COMPLEMENT for details.`);else{let n="";e&&(n="\n\tThis will disable the lexer's first char optimizations.\n\tSee: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#REGEXP_PARSING for details."),Pt(`${Zt}\n\tFailed parsing: < ${t.toString()} >\n\tUsing the @chevrotain/regexp-to-ast library\n\tPlease open an issue at: https://github.com/chevrotain/chevrotain/issues`+n)}}return[]}function Ut(t,e,n){switch(t.type){case"Disjunction":for(let r=0;r{if("number"==typeof t)Gt(t,e,n);else{const r=t;if(!0===n)for(let t=r.from;t<=r.to;t++)Gt(t,e,n);else{for(let t=r.from;t<=r.to&&t=he){const t=r.from>=he?r.from:he,n=r.to,i=de(t),a=de(n);for(let t=i;t<=a;t++)e[t]=t}}}}));break;case"Group":Ut(s.value,e,n);break;default:throw Error("Non Exhaustive Match")}const o=void 0!==s.quantifier&&0===s.quantifier.atLeast;if("Group"===s.type&&!1===qt(s)||"Group"!==s.type&&!1===o)break}break;default:throw Error("non exhaustive match!")}return(0,i.Z)(e)}function Gt(t,e,n){const r=de(t);e[r]=r,!0===n&&function(t,e){const n=String.fromCharCode(t),r=n.toUpperCase();if(r!==n){const t=de(r.charCodeAt(0));e[t]=t}else{const t=n.toLowerCase();if(t!==n){const n=de(t.charCodeAt(0));e[n]=n}}}(t,e)}function Vt(t,e){return(0,Ot.Z)(t.value,(t=>{if("number"==typeof t)return it(e,t);{const n=t;return void 0!==(0,Ot.Z)(e,(t=>n.from<=t&&t<=n.to))}}))}function qt(t){const e=t.quantifier;return!(!e||0!==e.atLeast)||!!t.value&&((0,J.Z)(t.value)?ot(t.value,qt):qt(t.value))}class jt extends gt.e{constructor(t){super(),this.targetCharCodes=t,this.found=!1}visitChildren(t){if(!0!==this.found){switch(t.type){case"Lookahead":return void this.visitLookahead(t);case"NegativeLookahead":return void this.visitNegativeLookahead(t)}super.visitChildren(t)}}visitCharacter(t){it(this.targetCharCodes,t.value)&&(this.found=!0)}visitSet(t){t.complement?void 0===Vt(t,this.targetCharCodes)&&(this.found=!0):void 0!==Vt(t,this.targetCharCodes)&&(this.found=!0)}}function Ht(t,e){if(e instanceof RegExp){const n=Wt(e),r=new jt(t);return r.visit(n),r.found}return void 0!==(0,Ot.Z)(e,(e=>it(t,e.charCodeAt(0))))}const Xt="PATTERN",Kt="defaultMode",Qt="modes";let Jt="boolean"==typeof new RegExp("(?:)").sticky;const te=/[^\\][$]/,ee=/[^\\[][\^]|^\^/;function ne(t){const e=t.ignoreCase?"i":"";return new RegExp(`^(?:${t.source})`,e)}function re(t){const e=t.ignoreCase?"iy":"y";return new RegExp(`${t.source}`,e)}function ie(t){const e=t.PATTERN;if(I(e))return!1;if((0,xt.Z)(e))return!0;if((0,o.Z)(e,"exec"))return!0;if((0,p.Z)(e))return!1;throw Error("non exhaustive match")}function ae(t){return!(!(0,p.Z)(t)||1!==t.length)&&t.charCodeAt(0)}const se={test:function(t){const e=t.length;for(let n=this.lastIndex;n(0,p.Z)(t)?t.charCodeAt(0):t))}function ce(t,e,n){void 0===t[e]?t[e]=[n]:t[e].push(n)}const he=256;let ue=[];function de(t){return tt.CATEGORIES))));const t=It(n,e);e=e.concat(t),(0,a.Z)(t)?r=!1:n=t}return e}(t);!function(t){(0,r.Z)(t,(t=>{var e;Te(t)||(be[xe]=t,t.tokenTypeIdx=xe++),_e(t)&&!(0,J.Z)(t.CATEGORIES)&&(t.CATEGORIES=[t.CATEGORIES]),_e(t)||(t.CATEGORIES=[]),e=t,(0,o.Z)(e,"categoryMatches")||(t.categoryMatches=[]),function(t){return(0,o.Z)(t,"categoryMatchesMap")}(t)||(t.categoryMatchesMap={})}))}(e),function(t){(0,r.Z)(t,(t=>{ke([],t)}))}(e),function(t){(0,r.Z)(t,(t=>{t.categoryMatches=[],(0,r.Z)(t.categoryMatchesMap,((e,n)=>{t.categoryMatches.push(be[n].tokenTypeIdx)}))}))}(e),(0,r.Z)(e,(t=>{t.isParent=t.categoryMatches.length>0}))}function ke(t,e){(0,r.Z)(t,(t=>{e.categoryMatchesMap[t.tokenTypeIdx]=!0})),(0,r.Z)(e.CATEGORIES,(n=>{const r=t.concat(e);it(r,n)||ke(r,n)}))}function Te(t){return(0,o.Z)(t,"tokenTypeIdx")}function _e(t){return(0,o.Z)(t,"CATEGORIES")}function Ee(t){return(0,o.Z)(t,"tokenTypeIdx")}const Se={buildUnableToPopLexerModeMessage:t=>`Unable to pop Lexer Mode after encountering Token ->${t.image}<- The Mode Stack is empty`,buildUnexpectedCharactersMessage:(t,e,n,r,i)=>`unexpected character: ->${t.charAt(e)}<- at offset: ${e}, skipped ${n} characters.`};var Ce;!function(t){t[t.MISSING_PATTERN=0]="MISSING_PATTERN",t[t.INVALID_PATTERN=1]="INVALID_PATTERN",t[t.EOI_ANCHOR_FOUND=2]="EOI_ANCHOR_FOUND",t[t.UNSUPPORTED_FLAGS_FOUND=3]="UNSUPPORTED_FLAGS_FOUND",t[t.DUPLICATE_PATTERNS_FOUND=4]="DUPLICATE_PATTERNS_FOUND",t[t.INVALID_GROUP_TYPE_FOUND=5]="INVALID_GROUP_TYPE_FOUND",t[t.PUSH_MODE_DOES_NOT_EXIST=6]="PUSH_MODE_DOES_NOT_EXIST",t[t.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE=7]="MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE",t[t.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY=8]="MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY",t[t.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST=9]="MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST",t[t.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED=10]="LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED",t[t.SOI_ANCHOR_FOUND=11]="SOI_ANCHOR_FOUND",t[t.EMPTY_MATCH_PATTERN=12]="EMPTY_MATCH_PATTERN",t[t.NO_LINE_BREAKS_FLAGS=13]="NO_LINE_BREAKS_FLAGS",t[t.UNREACHABLE_PATTERN=14]="UNREACHABLE_PATTERN",t[t.IDENTIFY_TERMINATOR=15]="IDENTIFY_TERMINATOR",t[t.CUSTOM_LINE_BREAK=16]="CUSTOM_LINE_BREAK",t[t.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE=17]="MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE"}(Ce||(Ce={}));const Ae={deferDefinitionErrorsHandling:!1,positionTracking:"full",lineTerminatorsPattern:/\n|\r\n?/g,lineTerminatorCharacters:["\n","\r"],ensureOptimizations:!1,safeMode:!1,errorMessageProvider:Se,traceInitPerf:!1,skipValidations:!1,recoveryEnabled:!0};Object.freeze(Ae);class Le{constructor(t,e=Ae){if(this.lexerDefinition=t,this.lexerDefinitionErrors=[],this.lexerDefinitionWarning=[],this.patternIdxToConfig={},this.charCodeToPatternIdxToConfig={},this.modes=[],this.emptyGroups={},this.trackStartLines=!0,this.trackEndLines=!0,this.hasCustom=!1,this.canModeBeOptimized={},this.TRACE_INIT=(t,e)=>{if(!0===this.traceInitPerf){this.traceInitIndent++;const n=new Array(this.traceInitIndent+1).join("\t");this.traceInitIndent`);const{time:r,value:i}=me(e),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return e()},"boolean"==typeof e)throw Error("The second argument to the Lexer constructor is now an ILexerConfig Object.\na boolean 2nd argument is no longer supported");this.config=w({},Ae,e);const n=this.config.traceInitPerf;!0===n?(this.traceInitMaxIdent=1/0,this.traceInitPerf=!0):"number"==typeof n&&(this.traceInitMaxIdent=n,this.traceInitPerf=!0),this.traceInitIndent=-1,this.TRACE_INIT("Lexer Constructor",(()=>{let n,h=!0;this.TRACE_INIT("Lexer Config handling",(()=>{if(this.config.lineTerminatorsPattern===Ae.lineTerminatorsPattern)this.config.lineTerminatorsPattern=se;else if(this.config.lineTerminatorCharacters===Ae.lineTerminatorCharacters)throw Error("Error: Missing property on the Lexer config.\n\tFor details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#MISSING_LINE_TERM_CHARS");if(e.safeMode&&e.ensureOptimizations)throw Error('"safeMode" and "ensureOptimizations" flags are mutually exclusive.');this.trackStartLines=/full|onlyStart/i.test(this.config.positionTracking),this.trackEndLines=/full/i.test(this.config.positionTracking),(0,J.Z)(t)?n={modes:{defaultMode:(0,l.Z)(t)},defaultMode:Kt}:(h=!1,n=(0,l.Z)(t))})),!1===this.config.skipValidations&&(this.TRACE_INIT("performRuntimeChecks",(()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(function(t,e,n){const i=[];return(0,o.Z)(t,Kt)||i.push({message:"A MultiMode Lexer cannot be initialized without a <"+Kt+"> property in its definition\n",type:Ce.MULTI_MODE_LEXER_WITHOUT_DEFAULT_MODE}),(0,o.Z)(t,Qt)||i.push({message:"A MultiMode Lexer cannot be initialized without a property in its definition\n",type:Ce.MULTI_MODE_LEXER_WITHOUT_MODES_PROPERTY}),(0,o.Z)(t,Qt)&&(0,o.Z)(t,Kt)&&!(0,o.Z)(t.modes,t.defaultMode)&&i.push({message:`A MultiMode Lexer cannot be initialized with a ${Kt}: <${t.defaultMode}>which does not exist\n`,type:Ce.MULTI_MODE_LEXER_DEFAULT_MODE_VALUE_DOES_NOT_EXIST}),(0,o.Z)(t,Qt)&&(0,r.Z)(t.modes,((t,e)=>{(0,r.Z)(t,((n,a)=>{if((0,pt.Z)(n))i.push({message:`A Lexer cannot be initialized using an undefined Token Type. Mode:<${e}> at index: <${a}>\n`,type:Ce.LEXER_DEFINITION_CANNOT_CONTAIN_UNDEFINED});else if((0,o.Z)(n,"LONGER_ALT")){const a=(0,J.Z)(n.LONGER_ALT)?n.LONGER_ALT:[n.LONGER_ALT];(0,r.Z)(a,(r=>{(0,pt.Z)(r)||it(t,r)||i.push({message:`A MultiMode Lexer cannot be initialized with a longer_alt <${r.name}> on token <${n.name}> outside of mode <${e}>\n`,type:Ce.MULTI_MODE_LEXER_LONGER_ALT_NOT_IN_CURRENT_MODE})}))}}))})),i}(n,this.trackStartLines,this.config.lineTerminatorCharacters))})),this.TRACE_INIT("performWarningRuntimeChecks",(()=>{this.lexerDefinitionWarning=this.lexerDefinitionWarning.concat(function(t,e,n){const a=[];let s=!1;const l=Rt((0,H.Z)((0,i.Z)(t.modes))),c=vt(l,(t=>t[Xt]===Le.NA)),h=le(n);return e&&(0,r.Z)(c,(t=>{const e=oe(t,h);if(!1!==e){const n=function(t,e){if(e.issue===Ce.IDENTIFY_TERMINATOR)return`Warning: unable to identify line terminator usage in pattern.\n\tThe problem is in the <${t.name}> Token Type\n\t Root cause: ${e.errMsg}.\n\tFor details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#IDENTIFY_TERMINATOR`;if(e.issue===Ce.CUSTOM_LINE_BREAK)return`Warning: A Custom Token Pattern should specify the option.\n\tThe problem is in the <${t.name}> Token Type\n\tFor details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_LINE_BREAK`;throw Error("non exhaustive match")}(t,e),r={message:n,type:e.issue,tokenType:t};a.push(r)}else(0,o.Z)(t,"LINE_BREAKS")?!0===t.LINE_BREAKS&&(s=!0):Ht(h,t.PATTERN)&&(s=!0)})),e&&!s&&a.push({message:"Warning: No LINE_BREAKS Found.\n\tThis Lexer has been defined to track line and column information,\n\tBut none of the Token Types can be identified as matching a line terminator.\n\tSee https://chevrotain.io/docs/guide/resolving_lexer_errors.html#LINE_BREAKS \n\tfor details.",type:Ce.NO_LINE_BREAKS_FLAGS}),a}(n,this.trackStartLines,this.config.lineTerminatorCharacters))}))),n.modes=n.modes?n.modes:{},(0,r.Z)(n.modes,((t,e)=>{n.modes[e]=vt(t,(t=>(0,pt.Z)(t)))}));const u=(0,x.Z)(n.modes);if((0,r.Z)(n.modes,((t,n)=>{this.TRACE_INIT(`Mode: <${n}> processing`,(()=>{if(this.modes.push(n),!1===this.config.skipValidations&&this.TRACE_INIT("validatePatterns",(()=>{this.lexerDefinitionErrors=this.lexerDefinitionErrors.concat(function(t,e){let n=[];const i=function(t){const e=(0,Tt.Z)(t,(t=>!(0,o.Z)(t,Xt)));return{errors:(0,s.Z)(e,(t=>({message:"Token Type: ->"+t.name+"<- missing static 'PATTERN' property",type:Ce.MISSING_PATTERN,tokenTypes:[t]}))),valid:It(t,e)}}(t);n=n.concat(i.errors);const a=function(t){const e=(0,Tt.Z)(t,(t=>{const e=t[Xt];return!(I(e)||(0,xt.Z)(e)||(0,o.Z)(e,"exec")||(0,p.Z)(e))}));return{errors:(0,s.Z)(e,(t=>({message:"Token Type: ->"+t.name+"<- static 'PATTERN' can only be a RegExp, a Function matching the {CustomPatternMatcherFunc} type or an Object matching the {ICustomPattern} interface.",type:Ce.INVALID_PATTERN,tokenTypes:[t]}))),valid:It(t,e)}}(i.valid),l=a.valid;return n=n.concat(a.errors),n=n.concat(function(t){let e=[];const n=(0,Tt.Z)(t,(t=>I(t[Xt])));return e=e.concat(function(t){class e extends gt.e{constructor(){super(...arguments),this.found=!1}visitEndAnchor(t){this.found=!0}}const n=(0,Tt.Z)(t,(t=>{const n=t.PATTERN;try{const t=Wt(n),r=new e;return r.visit(t),r.found}catch(t){return te.test(n.source)}}));return(0,s.Z)(n,(t=>({message:"Unexpected RegExp Anchor Error:\n\tToken Type: ->"+t.name+"<- static 'PATTERN' cannot contain end of input anchor '$'\n\tSee chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS\tfor details.",type:Ce.EOI_ANCHOR_FOUND,tokenTypes:[t]})))}(n)),e=e.concat(function(t){class e extends gt.e{constructor(){super(...arguments),this.found=!1}visitStartAnchor(t){this.found=!0}}const n=(0,Tt.Z)(t,(t=>{const n=t.PATTERN;try{const t=Wt(n),r=new e;return r.visit(t),r.found}catch(t){return ee.test(n.source)}}));return(0,s.Z)(n,(t=>({message:"Unexpected RegExp Anchor Error:\n\tToken Type: ->"+t.name+"<- static 'PATTERN' cannot contain start of input anchor '^'\n\tSee https://chevrotain.io/docs/guide/resolving_lexer_errors.html#ANCHORS\tfor details.",type:Ce.SOI_ANCHOR_FOUND,tokenTypes:[t]})))}(n)),e=e.concat(function(t){const e=(0,Tt.Z)(t,(t=>{const e=t[Xt];return e instanceof RegExp&&(e.multiline||e.global)}));return(0,s.Z)(e,(t=>({message:"Token Type: ->"+t.name+"<- static 'PATTERN' may NOT contain global('g') or multiline('m')",type:Ce.UNSUPPORTED_FLAGS_FOUND,tokenTypes:[t]})))}(n)),e=e.concat(function(t){const e=[];let n=(0,s.Z)(t,(n=>(0,kt.Z)(t,((t,r)=>(n.PATTERN.source!==r.PATTERN.source||it(e,r)||r.PATTERN===Le.NA||(e.push(r),t.push(r)),t)),[])));n=Rt(n);const r=(0,Tt.Z)(n,(t=>t.length>1));return(0,s.Z)(r,(t=>{const e=(0,s.Z)(t,(t=>t.name));return{message:`The same RegExp pattern ->${Dt(t).PATTERN}<-has been used in all of the following Token Types: ${e.join(", ")} <-`,type:Ce.DUPLICATE_PATTERNS_FOUND,tokenTypes:t}}))}(n)),e=e.concat(function(t){const e=(0,Tt.Z)(t,(t=>t.PATTERN.test("")));return(0,s.Z)(e,(t=>({message:"Token Type: ->"+t.name+"<- static 'PATTERN' must not match an empty string",type:Ce.EMPTY_MATCH_PATTERN,tokenTypes:[t]})))}(n)),e}(l)),n=n.concat(function(t){const e=(0,Tt.Z)(t,(t=>{if(!(0,o.Z)(t,"GROUP"))return!1;const e=t.GROUP;return e!==Le.SKIPPED&&e!==Le.NA&&!(0,p.Z)(e)}));return(0,s.Z)(e,(t=>({message:"Token Type: ->"+t.name+"<- static 'GROUP' can only be Lexer.SKIPPED/Lexer.NA/A String",type:Ce.INVALID_GROUP_TYPE_FOUND,tokenTypes:[t]})))}(l)),n=n.concat(function(t,e){const n=(0,Tt.Z)(t,(t=>void 0!==t.PUSH_MODE&&!it(e,t.PUSH_MODE)));return(0,s.Z)(n,(t=>({message:`Token Type: ->${t.name}<- static 'PUSH_MODE' value cannot refer to a Lexer Mode ->${t.PUSH_MODE}<-which does not exist`,type:Ce.PUSH_MODE_DOES_NOT_EXIST,tokenTypes:[t]})))}(l,e)),n=n.concat(function(t){const e=[],n=(0,kt.Z)(t,((t,e,n)=>{const r=e.PATTERN;return r===Le.NA||((0,p.Z)(r)?t.push({str:r,idx:n,tokenType:e}):I(r)&&(i=r,void 0===(0,Ot.Z)([".","\\","[","]","|","^","$","(",")","?","*","+","{"],(t=>-1!==i.source.indexOf(t))))&&t.push({str:r.source,idx:n,tokenType:e})),t;var i}),[]);return(0,r.Z)(t,((t,i)=>{(0,r.Z)(n,(({str:n,idx:r,tokenType:a})=>{if(i${a.name}<- can never be matched.\nBecause it appears AFTER the Token Type ->${t.name}<-in the lexer's definition.\nSee https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNREACHABLE`;e.push({message:n,type:Ce.UNREACHABLE_PATTERN,tokenTypes:[t,a]})}}))})),e}(l)),n}(t,u))})),(0,a.Z)(this.lexerDefinitionErrors)){let i;we(t),this.TRACE_INIT("analyzeTokenTypes",(()=>{i=function(t,e){const n=(e=(0,ft.Z)(e,{useSticky:Jt,debug:!1,safeMode:!1,positionTracking:"full",lineTerminatorCharacters:["\r","\n"],tracer:(t,e)=>e()})).tracer;let i;n("initCharCodeToOptimizedIndexMap",(()=>{!function(){if((0,a.Z)(ue)){ue=new Array(65536);for(let t=0;t<65536;t++)ue[t]=t>255?255+~~(t/255):t}}()})),n("Reject Lexer.NA",(()=>{i=vt(t,(t=>t[Xt]===Le.NA))}));let l,c,h,u,d,g,f,m,y,v,x,b=!1;n("Transform Patterns",(()=>{b=!1,l=(0,s.Z)(i,(t=>{const n=t[Xt];if(I(n)){const t=n.source;return 1!==t.length||"^"===t||"$"===t||"."===t||n.ignoreCase?2!==t.length||"\\"!==t[0]||it(["d","D","s","S","t","r","n","t","0","c","b","B","f","v","w","W"],t[1])?e.useSticky?re(n):ne(n):t[1]:t}if((0,xt.Z)(n))return b=!0,{exec:n};if("object"==typeof n)return b=!0,n;if("string"==typeof n){if(1===n.length)return n;{const t=n.replace(/[\\^$.*+?()[\]{}|]/g,"\\$&"),r=new RegExp(t);return e.useSticky?re(r):ne(r)}}throw Error("non exhaustive match")}))})),n("misc mapping",(()=>{c=(0,s.Z)(i,(t=>t.tokenTypeIdx)),h=(0,s.Z)(i,(t=>{const e=t.GROUP;if(e!==Le.SKIPPED){if((0,p.Z)(e))return e;if((0,pt.Z)(e))return!1;throw Error("non exhaustive match")}})),u=(0,s.Z)(i,(t=>{const e=t.LONGER_ALT;if(e)return(0,J.Z)(e)?(0,s.Z)(e,(t=>wt(i,t))):[wt(i,e)]})),d=(0,s.Z)(i,(t=>t.PUSH_MODE)),g=(0,s.Z)(i,(t=>(0,o.Z)(t,"POP_MODE")))})),n("Line Terminator Handling",(()=>{const t=le(e.lineTerminatorCharacters);f=(0,s.Z)(i,(t=>!1)),"onlyOffset"!==e.positionTracking&&(f=(0,s.Z)(i,(e=>(0,o.Z)(e,"LINE_BREAKS")?!!e.LINE_BREAKS:!1===oe(e,t)&&Ht(t,e.PATTERN))))})),n("Misc Mapping #2",(()=>{m=(0,s.Z)(i,ie),y=(0,s.Z)(l,ae),v=(0,kt.Z)(i,((t,e)=>{const n=e.GROUP;return(0,p.Z)(n)&&n!==Le.SKIPPED&&(t[n]=[]),t}),{}),x=(0,s.Z)(l,((t,e)=>({pattern:l[e],longerAlt:u[e],canLineTerminator:f[e],isCustom:m[e],short:y[e],group:h[e],push:d[e],pop:g[e],tokenTypeIdx:c[e],tokenType:i[e]})))}));let w=!0,k=[];return e.safeMode||n("First Char Optimization",(()=>{k=(0,kt.Z)(i,((t,n,i)=>{if("string"==typeof n.PATTERN){const e=de(n.PATTERN.charCodeAt(0));ce(t,e,x[i])}else if((0,J.Z)(n.START_CHARS_HINT)){let e;(0,r.Z)(n.START_CHARS_HINT,(n=>{const r=de("string"==typeof n?n.charCodeAt(0):n);e!==r&&(e=r,ce(t,r,x[i]))}))}else if(I(n.PATTERN))if(n.PATTERN.unicode)w=!1,e.ensureOptimizations&&Pt(`${Zt}\tUnable to analyze < ${n.PATTERN.toString()} > pattern.\n\tThe regexp unicode flag is not currently supported by the regexp-to-ast library.\n\tThis will disable the lexer's first char optimizations.\n\tFor details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#UNICODE_OPTIMIZE`);else{const s=Yt(n.PATTERN,e.ensureOptimizations);(0,a.Z)(s)&&(w=!1),(0,r.Z)(s,(e=>{ce(t,e,x[i])}))}else e.ensureOptimizations&&Pt(`${Zt}\tTokenType: <${n.name}> is using a custom token pattern without providing parameter.\n\tThis will disable the lexer's first char optimizations.\n\tFor details See: https://chevrotain.io/docs/guide/resolving_lexer_errors.html#CUSTOM_OPTIMIZE`),w=!1;return t}),[])})),{emptyGroups:v,patternIdxToConfig:x,charCodeToPatternIdxToConfig:k,hasCustom:b,canBeOptimized:w}}(t,{lineTerminatorCharacters:this.config.lineTerminatorCharacters,positionTracking:e.positionTracking,ensureOptimizations:e.ensureOptimizations,safeMode:e.safeMode,tracer:this.TRACE_INIT})})),this.patternIdxToConfig[n]=i.patternIdxToConfig,this.charCodeToPatternIdxToConfig[n]=i.charCodeToPatternIdxToConfig,this.emptyGroups=w({},this.emptyGroups,i.emptyGroups),this.hasCustom=i.hasCustom||this.hasCustom,this.canModeBeOptimized[n]=i.canBeOptimized}}))})),this.defaultMode=n.defaultMode,!(0,a.Z)(this.lexerDefinitionErrors)&&!this.config.deferDefinitionErrorsHandling){const t=(0,s.Z)(this.lexerDefinitionErrors,(t=>t.message)).join("-----------------------\n");throw new Error("Errors detected in definition of Lexer:\n"+t)}(0,r.Z)(this.lexerDefinitionWarning,(t=>{$t(t.message)})),this.TRACE_INIT("Choosing sub-methods implementations",(()=>{if(Jt?(this.chopInput=pe.Z,this.match=this.matchWithTest):(this.updateLastIndex=ge.Z,this.match=this.matchWithExec),h&&(this.handleModes=ge.Z),!1===this.trackStartLines&&(this.computeNewColumn=pe.Z),!1===this.trackEndLines&&(this.updateTokenEndLineColumnLocation=ge.Z),/full/i.test(this.config.positionTracking))this.createTokenInstance=this.createFullToken;else if(/onlyStart/i.test(this.config.positionTracking))this.createTokenInstance=this.createStartOnlyToken;else{if(!/onlyOffset/i.test(this.config.positionTracking))throw Error(`Invalid config option: "${this.config.positionTracking}"`);this.createTokenInstance=this.createOffsetOnlyToken}this.hasCustom?(this.addToken=this.addTokenUsingPush,this.handlePayload=this.handlePayloadWithCustom):(this.addToken=this.addTokenUsingMemberAccess,this.handlePayload=this.handlePayloadNoCustom)})),this.TRACE_INIT("Failed Optimization Warnings",(()=>{const t=(0,kt.Z)(this.canModeBeOptimized,((t,e,n)=>(!1===e&&t.push(n),t)),[]);if(e.ensureOptimizations&&!(0,a.Z)(t))throw Error(`Lexer Modes: < ${t.join(", ")} > cannot be optimized.\n\t Disable the "ensureOptimizations" lexer config flag to silently ignore this and run the lexer in an un-optimized mode.\n\t Or inspect the console log for details on how to resolve these issues.`)})),this.TRACE_INIT("clearRegExpParserCache",(()=>{Bt={}})),this.TRACE_INIT("toFastProperties",(()=>{c(this)}))}))}tokenize(t,e=this.defaultMode){if(!(0,a.Z)(this.lexerDefinitionErrors)){const t=(0,s.Z)(this.lexerDefinitionErrors,(t=>t.message)).join("-----------------------\n");throw new Error("Unable to Tokenize because Errors detected in definition of Lexer:\n"+t)}return this.tokenizeInternal(t,e)}tokenizeInternal(t,e){let n,i,a,s,o,l,c,h,u,d,p,g,f,m,y;const v=t,b=v.length;let w=0,k=0;const T=this.hasCustom?0:Math.floor(t.length/10),_=new Array(T),E=[];let S=this.trackStartLines?1:void 0,C=this.trackStartLines?1:void 0;const A=function(t){const e={},n=(0,x.Z)(t);return(0,r.Z)(n,(n=>{const r=t[n];if(!(0,J.Z)(r))throw Error("non exhaustive match");e[n]=[]})),e}(this.emptyGroups),L=this.trackStartLines,M=this.config.lineTerminatorsPattern;let N=0,I=[],R=[];const D=[],O=[];let P;function $(){return I}function B(t){const e=de(t),n=R[e];return void 0===n?O:n}Object.freeze(O);const F=t=>{if(1===D.length&&void 0===t.tokenType.PUSH_MODE){const e=this.config.errorMessageProvider.buildUnableToPopLexerModeMessage(t);E.push({offset:t.startOffset,line:t.startLine,column:t.startColumn,length:t.image.length,message:e})}else{D.pop();const t=(0,fe.Z)(D);I=this.patternIdxToConfig[t],R=this.charCodeToPatternIdxToConfig[t],N=I.length;const e=this.canModeBeOptimized[t]&&!1===this.config.safeMode;P=R&&e?B:$}};function W(t){D.push(t),R=this.charCodeToPatternIdxToConfig[t],I=this.patternIdxToConfig[t],N=I.length,N=I.length;const e=this.canModeBeOptimized[t]&&!1===this.config.safeMode;P=R&&e?B:$}let z;W.call(this,e);const Z=this.config.recoveryEnabled;for(;wl.length){l=s,c=h,z=e;break}}}break}}if(null!==l){if(u=l.length,d=z.group,void 0!==d&&(p=z.tokenTypeIdx,g=this.createTokenInstance(l,w,p,z.tokenType,S,C,u),this.handlePayload(g,c),!1===d?k=this.addToken(_,k,g):A[d].push(g)),t=this.chopInput(t,u),w+=u,C=this.computeNewColumn(C,u),!0===L&&!0===z.canLineTerminator){let t,e,n=0;M.lastIndex=0;do{t=M.test(l),!0===t&&(e=M.lastIndex-1,n++)}while(!0===t);0!==n&&(S+=n,C=u-e,this.updateTokenEndLineColumnLocation(g,d,e,n,S,C,u))}this.handleModes(z,F,W,g)}else{const e=w,n=S,r=C;let a=!1===Z;for(;!1===a&&w`Expecting ${Ne(t)?`--\x3e ${Me(t)} <--`:`token of type --\x3e ${t.name} <--`} but found --\x3e '${e.image}' <--`,buildNotAllInputParsedMessage:({firstRedundant:t,ruleName:e})=>"Redundant input, expecting EOF but found: "+t.image,buildNoViableAltMessage({expectedPathsPerAlt:t,actual:e,previous:n,customUserDescription:r,ruleName:i}){const a="Expecting: ",o="\nbut found: '"+Dt(e).image+"'";if(r)return a+r+o;{const e=(0,kt.Z)(t,((t,e)=>t.concat(e)),[]),n=(0,s.Z)(e,(t=>`[${(0,s.Z)(t,(t=>Me(t))).join(", ")}]`));return a+`one of these possible Token sequences:\n${(0,s.Z)(n,((t,e)=>` ${e+1}. ${t}`)).join("\n")}`+o}},buildEarlyExitMessage({expectedIterationPaths:t,actual:e,customUserDescription:n,ruleName:r}){const i="Expecting: ",a="\nbut found: '"+Dt(e).image+"'";return n?i+n+a:i+`expecting at least one iteration which starts with one of these possible Token sequences::\n <${(0,s.Z)(t,(t=>`[${(0,s.Z)(t,(t=>Me(t))).join(",")}]`)).join(" ,")}>`+a}};Object.freeze(Ue);const Ge={buildRuleNotFoundError:(t,e)=>"Invalid grammar, reference to a rule which is not defined: ->"+e.nonTerminalName+"<-\ninside top level rule: ->"+t.name+"<-"},Ve={buildDuplicateFoundError(t,e){const n=t.name,r=Dt(e),i=r.idx,a=ct(r),s=(o=r)instanceof Y?o.terminalType.name:o instanceof D?o.nonTerminalName:"";var o;let l=`->${a}${i>0?i:""}<- ${s?`with argument: ->${s}<-`:""}\n appears more than once (${e.length} times) in the top level rule: ->${n}<-. \n For further details see: https://chevrotain.io/docs/FAQ.html#NUMERICAL_SUFFIXES \n `;return l=l.replace(/[ \t]+/g," "),l=l.replace(/\s\s+/g,"\n"),l},buildNamespaceConflictError:t=>`Namespace conflict found in grammar.\nThe grammar has both a Terminal(Token) and a Non-Terminal(Rule) named: <${t.name}>.\nTo resolve this make sure each Terminal and Non-Terminal names are unique\nThis is easy to accomplish by using the convention that Terminal names start with an uppercase letter\nand Non-Terminal names start with a lower case letter.`,buildAlternationPrefixAmbiguityError(t){const e=(0,s.Z)(t.prefixPath,(t=>Me(t))).join(", "),n=0===t.alternation.idx?"":t.alternation.idx;return`Ambiguous alternatives: <${t.ambiguityIndices.join(" ,")}> due to common lookahead prefix\nin inside <${t.topLevelRule.name}> Rule,\n<${e}> may appears as a prefix path in all these alternatives.\nSee: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#COMMON_PREFIX\nFor Further details.`},buildAlternationAmbiguityError(t){const e=(0,s.Z)(t.prefixPath,(t=>Me(t))).join(", "),n=0===t.alternation.idx?"":t.alternation.idx;let r=`Ambiguous Alternatives Detected: <${t.ambiguityIndices.join(" ,")}> in inside <${t.topLevelRule.name}> Rule,\n<${e}> may appears as a prefix path in all these alternatives.\n`;return r+="See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES\nFor Further details.",r},buildEmptyRepetitionError(t){let e=ct(t.repetition);return 0!==t.repetition.idx&&(e+=t.repetition.idx),`The repetition <${e}> within Rule <${t.topLevelRule.name}> can never consume any tokens.\nThis could lead to an infinite loop.`},buildTokenNameError:t=>"deprecated",buildEmptyAlternationError:t=>`Ambiguous empty alternative: <${t.emptyChoiceIdx+1}> in inside <${t.topLevelRule.name}> Rule.\nOnly the last alternative may be an empty alternative.`,buildTooManyAlternativesError:t=>`An Alternation cannot have more than 256 alternatives:\n inside <${t.topLevelRule.name}> Rule.\n has ${t.alternation.definition.length+1} alternatives.`,buildLeftRecursionError(t){const e=t.topLevelRule.name;return`Left Recursion found in grammar.\nrule: <${e}> can be invoked from itself (directly or indirectly)\nwithout consuming any Tokens. The grammar path that causes this is: \n ${e} --\x3e ${(0,s.Z)(t.leftRecursionPath,(t=>t.name)).concat([e]).join(" --\x3e ")}\n To fix this refactor your grammar to remove the left recursion.\nsee: https://en.wikipedia.org/wiki/LL_parser#Left_factoring.`},buildInvalidRuleNameError:t=>"deprecated",buildDuplicateRuleNameError(t){let e;return e=t.topLevelRule instanceof O?t.topLevelRule.name:t.topLevelRule,`Duplicate definition, rule: ->${e}<- is already defined in the grammar: ->${t.grammarName}<-`}};class qe{visit(t){const e=t;switch(e.constructor){case D:return this.visitNonTerminal(e);case P:return this.visitAlternative(e);case $:return this.visitOption(e);case B:return this.visitRepetitionMandatory(e);case F:return this.visitRepetitionMandatoryWithSeparator(e);case z:return this.visitRepetitionWithSeparator(e);case W:return this.visitRepetition(e);case Z:return this.visitAlternation(e);case Y:return this.visitTerminal(e);case O:return this.visitRule(e);default:throw Error("non exhaustive match")}}visitNonTerminal(t){}visitAlternative(t){}visitOption(t){}visitRepetition(t){}visitRepetitionMandatory(t){}visitRepetitionMandatoryWithSeparator(t){}visitRepetitionWithSeparator(t){}visitAlternation(t){}visitTerminal(t){}visitRule(t){}}class je extends qe{constructor(t,e){super(),this.nameToTopRule=t,this.errMsgProvider=e,this.errors=[]}resolveRefs(){(0,r.Z)((0,i.Z)(this.nameToTopRule),(t=>{this.currTopLevel=t,t.accept(this)}))}visitNonTerminal(t){const e=this.nameToTopRule[t.nonTerminalName];if(e)t.referencedRule=e;else{const e=this.errMsgProvider.buildRuleNotFoundError(this.currTopLevel,t);this.errors.push({message:e,type:Tr.UNRESOLVED_SUBRULE_REF,ruleName:this.currTopLevel.name,unresolvedRefName:t.nonTerminalName})}}}var He=n(6805),Xe=n(4752);const Ke=function(t,e,n,r){for(var i=-1,a=null==t?0:t.length;++i{!1===(0,a.Z)(t.definition)&&(i=o(t.definition))})),i;if(!(e instanceof Y))throw Error("non exhaustive match");n.push(e.terminalType)}}s++}return i.push({partialPath:n,suffixDef:d(t,s)}),i}function pn(t,e,n,r){const i="EXIT_NONE_TERMINAL",s=[i],o="EXIT_ALTERNATIVE";let c=!1;const h=e.length,u=h-r-1,p=[],g=[];for(g.push({idx:-1,def:t,ruleStack:[],occurrenceStack:[]});!(0,a.Z)(g);){const t=g.pop();if(t===o){c&&(0,fe.Z)(g).idx<=u&&g.pop();continue}const r=t.def,f=t.idx,m=t.ruleStack,y=t.occurrenceStack;if((0,a.Z)(r))continue;const v=r[0];if(v===i){const t={idx:f,def:d(r),ruleStack:rn(m),occurrenceStack:rn(y)};g.push(t)}else if(v instanceof Y)if(f=0;t--){const e={idx:f,def:v.definition[t].definition.concat(d(r)),ruleStack:m,occurrenceStack:y};g.push(e),g.push(o)}else if(v instanceof P)g.push({idx:f,def:v.definition.concat(d(r)),ruleStack:m,occurrenceStack:y});else{if(!(v instanceof O))throw Error("non exhaustive match");g.push(gn(v,f,m,y))}}return p}function gn(t,e,n,r){const i=(0,l.Z)(n);i.push(t.name);const a=(0,l.Z)(r);return a.push(1),{idx:e,def:t.definition,ruleStack:i,occurrenceStack:a}}var fn;function mn(t){if(t instanceof $||"Option"===t)return fn.OPTION;if(t instanceof W||"Repetition"===t)return fn.REPETITION;if(t instanceof B||"RepetitionMandatory"===t)return fn.REPETITION_MANDATORY;if(t instanceof F||"RepetitionMandatoryWithSeparator"===t)return fn.REPETITION_MANDATORY_WITH_SEPARATOR;if(t instanceof z||"RepetitionWithSeparator"===t)return fn.REPETITION_WITH_SEPARATOR;if(t instanceof Z||"Alternation"===t)return fn.ALTERNATION;throw Error("non exhaustive match")}function yn(t){const{occurrence:e,rule:n,prodType:r,maxLookahead:i}=t,a=mn(r);return a===fn.ALTERNATION?Sn(e,n,i):Cn(e,n,a,i)}function vn(t,e,n,i){const a=t.length,l=ot(t,(t=>ot(t,(t=>1===t.length))));if(e)return function(e){const r=(0,s.Z)(e,(t=>t.GATE));for(let e=0;e(0,H.Z)(t))),n=(0,kt.Z)(e,((t,e,n)=>((0,r.Z)(e,(e=>{(0,o.Z)(t,e.tokenTypeIdx)||(t[e.tokenTypeIdx]=n),(0,r.Z)(e.categoryMatches,(e=>{(0,o.Z)(t,e)||(t[e]=n)}))})),t)),{});return function(){const t=this.LA(1);return n[t.tokenTypeIdx]}}return function(){for(let e=0;e1===t.length)),s=t.length;if(i&&!n){const e=(0,H.Z)(t);if(1===e.length&&(0,a.Z)(e[0].categoryMatches)){const t=e[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===t}}{const t=(0,kt.Z)(e,((t,e,n)=>(t[e.tokenTypeIdx]=!0,(0,r.Z)(e.categoryMatches,(e=>{t[e]=!0})),t)),[]);return function(){const e=this.LA(1);return!0===t[e.tokenTypeIdx]}}}return function(){t:for(let n=0;ndn([t],1))),i=kn(n.length),o=(0,s.Z)(n,(t=>{const e={};return(0,r.Z)(t,(t=>{const n=Tn(t.partialPath);(0,r.Z)(n,(t=>{e[t]=!0}))})),e}));let l=n;for(let t=1;t<=e;t++){const n=l;l=kn(n.length);for(let s=0;s{const e=Tn(t.partialPath);(0,r.Z)(e,(t=>{o[s][t]=!0}))}))}}}}return i}function Sn(t,e,n,r){const i=new wn(t,fn.ALTERNATION,r);return e.accept(i),En(i.result,n)}function Cn(t,e,n,r){const i=new wn(t,n);e.accept(i);const a=i.result,s=new bn(e,t,n).startWalking();return En([new P({definition:a}),new P({definition:s})],r)}function An(t,e){t:for(let n=0;not(t,(t=>ot(t,(t=>(0,a.Z)(t.categoryMatches)))))))}function Mn(t){return`${ct(t)}_#_${t.idx}_#_${Nn(t)}`}function Nn(t){return t instanceof Y?t.terminalType.name:t instanceof D?t.nonTerminalName:""}class In extends qe{constructor(){super(...arguments),this.allProductions=[]}visitNonTerminal(t){this.allProductions.push(t)}visitOption(t){this.allProductions.push(t)}visitRepetitionWithSeparator(t){this.allProductions.push(t)}visitRepetitionMandatory(t){this.allProductions.push(t)}visitRepetitionMandatoryWithSeparator(t){this.allProductions.push(t)}visitRepetition(t){this.allProductions.push(t)}visitAlternation(t){this.allProductions.push(t)}visitTerminal(t){this.allProductions.push(t)}}function Rn(t,e,n,r=[]){const i=[],s=Dn(e.definition);if((0,a.Z)(s))return[];{const e=t.name;it(s,t)&&i.push({message:n.buildLeftRecursionError({topLevelRule:t,leftRecursionPath:r}),type:Tr.LEFT_RECURSION,ruleName:e});const a=It(s,r.concat([t])),o=(0,He.Z)(a,(e=>{const i=(0,l.Z)(r);return i.push(e),Rn(t,e,n,i)}));return i.concat(o)}}function Dn(t){let e=[];if((0,a.Z)(t))return e;const n=Dt(t);if(n instanceof D)e.push(n.referencedRule);else if(n instanceof P||n instanceof $||n instanceof B||n instanceof F||n instanceof z||n instanceof W)e=e.concat(Dn(n.definition));else if(n instanceof Z)e=(0,H.Z)((0,s.Z)(n.definition,(t=>Dn(t.definition))));else if(!(n instanceof Y))throw Error("non exhaustive match");const r=lt(n),i=t.length>1;if(r&&i){const n=d(t);return e.concat(Dn(n))}return e}class On extends qe{constructor(){super(...arguments),this.alternations=[]}visitAlternation(t){this.alternations.push(t)}}class Pn extends qe{constructor(){super(...arguments),this.allProductions=[]}visitRepetitionWithSeparator(t){this.allProductions.push(t)}visitRepetitionMandatory(t){this.allProductions.push(t)}visitRepetitionMandatoryWithSeparator(t){this.allProductions.push(t)}visitRepetition(t){this.allProductions.push(t)}}const $n="MismatchedTokenException",Bn="NoViableAltException",Fn="EarlyExitException",Wn="NotAllInputParsedException",zn=[$n,Bn,Fn,Wn];function Zn(t){return it(zn,t.name)}Object.freeze(zn);class Yn extends Error{constructor(t,e){super(t),this.token=e,this.resyncedTokens=[],Object.setPrototypeOf(this,new.target.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}}class Un extends Yn{constructor(t,e,n){super(t,e),this.previousToken=n,this.name=$n}}class Gn extends Yn{constructor(t,e,n){super(t,e),this.previousToken=n,this.name=Bn}}class Vn extends Yn{constructor(t,e){super(t,e),this.name=Wn}}class qn extends Yn{constructor(t,e,n){super(t,e),this.previousToken=n,this.name=Fn}}const jn={},Hn="InRuleRecoveryException";class Xn extends Error{constructor(t){super(t),this.name=Hn}}function Kn(t,e,n,r,i,a,s){const o=this.getKeyForAutomaticLookahead(r,i);let l=this.firstAfterRepMap[o];if(void 0===l){const t=this.getCurrRuleFullName();l=new a(this.getGAstProductions()[t],i).startWalking(),this.firstAfterRepMap[o]=l}let c=l.token,h=l.occurrence;const u=l.isEndOfRule;1===this.RULE_STACK.length&&u&&void 0===c&&(c=ze,h=1),void 0!==c&&void 0!==h&&this.shouldInRepetitionRecoveryBeTried(c,h,s)&&this.tryInRepetitionRecovery(t,e,n,c)}const Qn=1024,Jn=1280,tr=1536;function er(t,e,n){return n|e|t}class nr{constructor(t){var e;this.maxLookahead=null!==(e=null==t?void 0:t.maxLookahead)&&void 0!==e?e:wr.maxLookahead}validate(t){const e=this.validateNoLeftRecursion(t.rules);if((0,a.Z)(e)){const n=this.validateEmptyOrAlternatives(t.rules),r=this.validateAmbiguousAlternationAlternatives(t.rules,this.maxLookahead),i=this.validateSomeNonEmptyLookaheadPath(t.rules,this.maxLookahead);return[...e,...n,...r,...i]}return e}validateNoLeftRecursion(t){return(0,He.Z)(t,(t=>Rn(t,t,Ve)))}validateEmptyOrAlternatives(t){return(0,He.Z)(t,(t=>function(t,e){const n=new On;t.accept(n);const r=n.alternations;return(0,He.Z)(r,(n=>{const r=rn(n.definition);return(0,He.Z)(r,((r,i)=>{const s=pn([r],[],ye,1);return(0,a.Z)(s)?[{message:e.buildEmptyAlternationError({topLevelRule:t,alternation:n,emptyChoiceIdx:i}),type:Tr.NONE_LAST_EMPTY_ALT,ruleName:t.name,occurrence:n.idx,alternative:i+1}]:[]}))}))}(t,Ve)))}validateAmbiguousAlternationAlternatives(t,e){return(0,He.Z)(t,(t=>function(t,e,n){const i=new On;t.accept(i);let a=i.alternations;a=vt(a,(t=>!0===t.ignoreAmbiguities));return(0,He.Z)(a,(i=>{const a=i.idx,o=i.maxLookahead||e,l=Sn(a,t,o,i),c=function(t,e,n,i){const a=[],o=(0,kt.Z)(t,((n,i,s)=>(!0===e.definition[s].ignoreAmbiguities||(0,r.Z)(i,(i=>{const o=[s];(0,r.Z)(t,((t,n)=>{s!==n&&An(t,i)&&!0!==e.definition[n].ignoreAmbiguities&&o.push(n)})),o.length>1&&!An(a,i)&&(a.push(i),n.push({alts:o,path:i}))})),n)),[]);return(0,s.Z)(o,(t=>{const r=(0,s.Z)(t.alts,(t=>t+1));return{message:i.buildAlternationAmbiguityError({topLevelRule:n,alternation:e,ambiguityIndices:r,prefixPath:t.path}),type:Tr.AMBIGUOUS_ALTS,ruleName:n.name,occurrence:e.idx,alternatives:t.alts}}))}(l,i,t,n),h=function(t,e,n,r){const i=(0,kt.Z)(t,((t,e,n)=>{const r=(0,s.Z)(e,(t=>({idx:n,path:t})));return t.concat(r)}),[]);return Rt((0,He.Z)(i,(t=>{if(!0===e.definition[t.idx].ignoreAmbiguities)return[];const a=t.idx,o=t.path,l=(0,Tt.Z)(i,(t=>{return!0!==e.definition[t.idx].ignoreAmbiguities&&t.idx{const n=r[e];return t===n||n.categoryMatchesMap[t.tokenTypeIdx]})));var n,r}));return(0,s.Z)(l,(t=>{const i=[t.idx+1,a+1],s=0===e.idx?"":e.idx;return{message:r.buildAlternationPrefixAmbiguityError({topLevelRule:n,alternation:e,ambiguityIndices:i,prefixPath:t.path}),type:Tr.AMBIGUOUS_PREFIX_ALTS,ruleName:n.name,occurrence:s,alternatives:i}}))})))}(l,i,t,n);return c.concat(h)}))}(t,e,Ve)))}validateSomeNonEmptyLookaheadPath(t,e){return function(t,e,n){const i=[];return(0,r.Z)(t,(t=>{const s=new Pn;t.accept(s);const o=s.allProductions;(0,r.Z)(o,(r=>{const s=mn(r),o=r.maxLookahead||e,l=Cn(r.idx,t,s,o)[0];if((0,a.Z)((0,H.Z)(l))){const e=n.buildEmptyRepetitionError({topLevelRule:t,repetition:r});i.push({message:e,type:Tr.NO_NON_EMPTY_LOOKAHEAD,ruleName:t.name})}}))})),i}(t,e,Ve)}buildLookaheadForAlternation(t){return function(t,e,n,r,i,a){const s=Sn(t,e,n);return a(s,r,Ln(s)?ve:ye,i)}(t.prodOccurrence,t.rule,t.maxLookahead,t.hasPredicates,t.dynamicTokensEnabled,vn)}buildLookaheadForOptional(t){return function(t,e,n,r,i,a){const s=Cn(t,e,i,n),o=Ln(s)?ve:ye;return a(s[0],o,r)}(t.prodOccurrence,t.rule,t.maxLookahead,t.dynamicTokensEnabled,mn(t.prodType),xn)}}const rr=new class extends qe{constructor(){super(...arguments),this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}reset(){this.dslMethods={option:[],alternation:[],repetition:[],repetitionWithSeparator:[],repetitionMandatory:[],repetitionMandatoryWithSeparator:[]}}visitOption(t){this.dslMethods.option.push(t)}visitRepetitionWithSeparator(t){this.dslMethods.repetitionWithSeparator.push(t)}visitRepetitionMandatory(t){this.dslMethods.repetitionMandatory.push(t)}visitRepetitionMandatoryWithSeparator(t){this.dslMethods.repetitionMandatoryWithSeparator.push(t)}visitRepetition(t){this.dslMethods.repetition.push(t)}visitAlternation(t){this.dslMethods.alternation.push(t)}};function ir(t,e){!0===isNaN(t.startOffset)?(t.startOffset=e.startOffset,t.endOffset=e.endOffset):t.endOffset(0,xt.Z)(t.GATE)));return s.hasPredicates=l,n.definition.push(s),(0,r.Z)(a,(t=>{const e=new P({definition:[]});s.definition.push(e),(0,o.Z)(t,"IGNORE_AMBIGUITIES")?e.ignoreAmbiguities=t.IGNORE_AMBIGUITIES:(0,o.Z)(t,"GATE")&&(e.ignoreAmbiguities=!0),this.recordingProdStack.push(e),t.ALT.call(this),this.recordingProdStack.pop()})),ur}function vr(t){return 0===t?"":`${t}`}function xr(t){if(t<0||t>dr){const e=new Error(`Invalid DSL Method idx value: <${t}>\n\tIdx value must be a none negative value smaller than ${dr+1}`);throw e.KNOWN_RECORDER_ERROR=!0,e}}const br=Ze(ze,"",NaN,NaN,NaN,NaN,NaN,NaN);Object.freeze(br);const wr=Object.freeze({recoveryEnabled:!1,maxLookahead:3,dynamicTokensEnabled:!1,outputCst:!0,errorMessageProvider:Ue,nodeLocationTracking:"none",traceInitPerf:!1,skipValidations:!1}),kr=Object.freeze({recoveryValueFunc:()=>{},resyncEnabled:!0});var Tr,_r;function Er(t=void 0){return function(){return t}}!function(t){t[t.INVALID_RULE_NAME=0]="INVALID_RULE_NAME",t[t.DUPLICATE_RULE_NAME=1]="DUPLICATE_RULE_NAME",t[t.INVALID_RULE_OVERRIDE=2]="INVALID_RULE_OVERRIDE",t[t.DUPLICATE_PRODUCTIONS=3]="DUPLICATE_PRODUCTIONS",t[t.UNRESOLVED_SUBRULE_REF=4]="UNRESOLVED_SUBRULE_REF",t[t.LEFT_RECURSION=5]="LEFT_RECURSION",t[t.NONE_LAST_EMPTY_ALT=6]="NONE_LAST_EMPTY_ALT",t[t.AMBIGUOUS_ALTS=7]="AMBIGUOUS_ALTS",t[t.CONFLICT_TOKENS_RULES_NAMESPACE=8]="CONFLICT_TOKENS_RULES_NAMESPACE",t[t.INVALID_TOKEN_NAME=9]="INVALID_TOKEN_NAME",t[t.NO_NON_EMPTY_LOOKAHEAD=10]="NO_NON_EMPTY_LOOKAHEAD",t[t.AMBIGUOUS_PREFIX_ALTS=11]="AMBIGUOUS_PREFIX_ALTS",t[t.TOO_MANY_ALTS=12]="TOO_MANY_ALTS",t[t.CUSTOM_LOOKAHEAD_VALIDATION=13]="CUSTOM_LOOKAHEAD_VALIDATION"}(Tr||(Tr={}));class Sr{static performSelfAnalysis(t){throw Error("The **static** `performSelfAnalysis` method has been deprecated.\t\nUse the **instance** method with the same name instead.")}performSelfAnalysis(){this.TRACE_INIT("performSelfAnalysis",(()=>{let t;this.selfAnalysisDone=!0;const e=this.className;this.TRACE_INIT("toFastProps",(()=>{c(this)})),this.TRACE_INIT("Grammar Recording",(()=>{try{this.enableRecording(),(0,r.Z)(this.definedRulesNames,(t=>{const e=this[t].originalGrammarAction;let n;this.TRACE_INIT(`${t} Rule`,(()=>{n=this.topLevelRuleRecord(t,e)})),this.gastProductionsCache[t]=n}))}finally{this.disableRecording()}}));let n=[];if(this.TRACE_INIT("Grammar Resolving",(()=>{n=function(t){const e=(0,ft.Z)(t,{errMsgProvider:Ge}),n={};return(0,r.Z)(t.rules,(t=>{n[t.name]=t})),function(t,e){const n=new je(t,e);return n.resolveRefs(),n.errors}(n,e.errMsgProvider)}({rules:(0,i.Z)(this.gastProductionsCache)}),this.definitionErrors=this.definitionErrors.concat(n)})),this.TRACE_INIT("Grammar Validations",(()=>{if((0,a.Z)(n)&&!1===this.skipValidations){const n=(t={rules:(0,i.Z)(this.gastProductionsCache),tokenTypes:(0,i.Z)(this.tokensMap),errMsgProvider:Ve,grammarName:e},function(t,e,n,a){const o=(0,He.Z)(t,(t=>function(t,e){const n=new In;t.accept(n);const r=n.allProductions,a=tn(r,Mn),o=S(a,(t=>t.length>1));return(0,s.Z)((0,i.Z)(o),(n=>{const r=Dt(n),i=e.buildDuplicateFoundError(t,n),a=ct(r),s={message:i,type:Tr.DUPLICATE_PRODUCTIONS,ruleName:t.name,dslName:a,occurrence:r.idx},o=Nn(r);return o&&(s.parameter=o),s}))}(t,n))),l=function(t,e,n){const i=[],a=(0,s.Z)(e,(t=>t.name));return(0,r.Z)(t,(t=>{const e=t.name;if(it(a,e)){const r=n.buildNamespaceConflictError(t);i.push({message:r,type:Tr.CONFLICT_TOKENS_RULES_NAMESPACE,ruleName:e})}})),i}(t,e,n),c=(0,He.Z)(t,(t=>function(t,e){const n=new On;t.accept(n);const r=n.alternations;return(0,He.Z)(r,(n=>n.definition.length>255?[{message:e.buildTooManyAlternativesError({topLevelRule:t,alternation:n}),type:Tr.TOO_MANY_ALTS,ruleName:t.name,occurrence:n.idx}]:[]))}(t,n))),h=(0,He.Z)(t,(e=>function(t,e,n,r){const i=[],a=(0,kt.Z)(e,((e,n)=>n.name===t.name?e+1:e),0);if(a>1){const e=r.buildDuplicateRuleNameError({topLevelRule:t,grammarName:n});i.push({message:e,type:Tr.DUPLICATE_RULE_NAME,ruleName:t.name})}return i}(e,t,a,n)));return o.concat(l,c,h)}((t=(0,ft.Z)(t,{errMsgProvider:Ve})).rules,t.tokenTypes,t.errMsgProvider,t.grammarName)),a=function(t){const e=t.lookaheadStrategy.validate({rules:t.rules,tokenTypes:t.tokenTypes,grammarName:t.grammarName});return(0,s.Z)(e,(t=>Object.assign({type:Tr.CUSTOM_LOOKAHEAD_VALIDATION},t)))}({lookaheadStrategy:this.lookaheadStrategy,rules:(0,i.Z)(this.gastProductionsCache),tokenTypes:(0,i.Z)(this.tokensMap),grammarName:e});this.definitionErrors=this.definitionErrors.concat(n,a)}var t})),(0,a.Z)(this.definitionErrors)&&(this.recoveryEnabled&&this.TRACE_INIT("computeAllProdsFollows",(()=>{const t=function(t){const e={};return(0,r.Z)(t,(t=>{const n=new dt(t).startWalking();w(e,n)})),e}((0,i.Z)(this.gastProductionsCache));this.resyncFollows=t})),this.TRACE_INIT("ComputeLookaheadFunctions",(()=>{var t,e;null===(e=(t=this.lookaheadStrategy).initialize)||void 0===e||e.call(t,{rules:(0,i.Z)(this.gastProductionsCache)}),this.preComputeLookaheadFunctions((0,i.Z)(this.gastProductionsCache))}))),!Sr.DEFER_DEFINITION_ERRORS_HANDLING&&!(0,a.Z)(this.definitionErrors))throw t=(0,s.Z)(this.definitionErrors,(t=>t.message)),new Error(`Parser Definition Errors detected:\n ${t.join("\n-------------------------------\n")}`)}))}constructor(t,e){this.definitionErrors=[],this.selfAnalysisDone=!1;const n=this;if(n.initErrorHandler(e),n.initLexerAdapter(),n.initLooksAhead(e),n.initRecognizerEngine(t,e),n.initRecoverable(e),n.initTreeBuilder(e),n.initContentAssist(),n.initGastRecorder(e),n.initPerformanceTracer(e),(0,o.Z)(e,"ignoredIssues"))throw new Error("The IParserConfig property has been deprecated.\n\tPlease use the flag on the relevant DSL method instead.\n\tSee: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES\n\tFor further details.");this.skipValidations=(0,o.Z)(e,"skipValidations")?e.skipValidations:wr.skipValidations}}Sr.DEFER_DEFINITION_ERRORS_HANDLING=!1,_r=Sr,[class{initRecoverable(t){this.firstAfterRepMap={},this.resyncFollows={},this.recoveryEnabled=(0,o.Z)(t,"recoveryEnabled")?t.recoveryEnabled:wr.recoveryEnabled,this.recoveryEnabled&&(this.attemptInRepetitionRecovery=Kn)}getTokenToInsert(t){const e=Ze(t,"",NaN,NaN,NaN,NaN,NaN,NaN);return e.isInsertedInRecovery=!0,e}canTokenTypeBeInsertedInRecovery(t){return!0}canTokenTypeBeDeletedInRecovery(t){return!0}tryInRepetitionRecovery(t,e,n,r){const i=this.findReSyncTokenType(),a=this.exportLexerState(),s=[];let o=!1;const l=this.LA(1);let c=this.LA(1);const h=()=>{const t=this.LA(0),e=this.errorMessageProvider.buildMismatchTokenMessage({expected:r,actual:l,previous:t,ruleName:this.getCurrRuleFullName()}),n=new Un(e,l,this.LA(0));n.resyncedTokens=rn(s),this.SAVE_ERROR(n)};for(;!o;){if(this.tokenMatcher(c,r))return void h();if(n.call(this))return h(),void t.apply(this,e);this.tokenMatcher(c,i)?o=!0:(c=this.SKIP_TOKEN(),this.addToResyncTokens(c,s))}this.importLexerState(a)}shouldInRepetitionRecoveryBeTried(t,e,n){return!1!==n&&!this.tokenMatcher(this.LA(1),t)&&!this.isBackTracking()&&!this.canPerformInRuleRecovery(t,this.getFollowsForInRuleRecovery(t,e))}getFollowsForInRuleRecovery(t,e){const n=this.getCurrentGrammarPath(t,e);return this.getNextPossibleTokenTypes(n)}tryInRuleRecovery(t,e){if(this.canRecoverWithSingleTokenInsertion(t,e))return this.getTokenToInsert(t);if(this.canRecoverWithSingleTokenDeletion(t)){const t=this.SKIP_TOKEN();return this.consumeToken(),t}throw new Xn("sad sad panda")}canPerformInRuleRecovery(t,e){return this.canRecoverWithSingleTokenInsertion(t,e)||this.canRecoverWithSingleTokenDeletion(t)}canRecoverWithSingleTokenInsertion(t,e){if(!this.canTokenTypeBeInsertedInRecovery(t))return!1;if((0,a.Z)(e))return!1;const n=this.LA(1);return void 0!==(0,Ot.Z)(e,(t=>this.tokenMatcher(n,t)))}canRecoverWithSingleTokenDeletion(t){return!!this.canTokenTypeBeDeletedInRecovery(t)&&this.tokenMatcher(this.LA(2),t)}isInCurrentRuleReSyncSet(t){const e=this.getCurrFollowKey(),n=this.getFollowSetFromFollowKey(e);return it(n,t)}findReSyncTokenType(){const t=this.flattenFollowSet();let e=this.LA(1),n=2;for(;;){const r=(0,Ot.Z)(t,(t=>Ye(e,t)));if(void 0!==r)return r;e=this.LA(n),n++}}getCurrFollowKey(){if(1===this.RULE_STACK.length)return jn;const t=this.getLastExplicitRuleShortName(),e=this.getLastExplicitRuleOccurrenceIndex(),n=this.getPreviousExplicitRuleShortName();return{ruleName:this.shortRuleNameToFullName(t),idxInCallingRule:e,inRule:this.shortRuleNameToFullName(n)}}buildFullFollowKeyStack(){const t=this.RULE_STACK,e=this.RULE_OCCURRENCE_STACK;return(0,s.Z)(t,((n,r)=>0===r?jn:{ruleName:this.shortRuleNameToFullName(n),idxInCallingRule:e[r],inRule:this.shortRuleNameToFullName(t[r-1])}))}flattenFollowSet(){const t=(0,s.Z)(this.buildFullFollowKeyStack(),(t=>this.getFollowSetFromFollowKey(t)));return(0,H.Z)(t)}getFollowSetFromFollowKey(t){if(t===jn)return[ze];const e=t.ruleName+t.idxInCallingRule+ut+t.inRule;return this.resyncFollows[e]}addToResyncTokens(t,e){return this.tokenMatcher(t,ze)||e.push(t),e}reSyncTo(t){const e=[];let n=this.LA(1);for(;!1===this.tokenMatcher(n,t);)n=this.SKIP_TOKEN(),this.addToResyncTokens(n,e);return rn(e)}attemptInRepetitionRecovery(t,e,n,r,i,a,s){}getCurrentGrammarPath(t,e){return{ruleStack:this.getHumanReadableRuleStack(),occurrenceStack:(0,l.Z)(this.RULE_OCCURRENCE_STACK),lastTok:t,lastTokOccurrence:e}}getHumanReadableRuleStack(){return(0,s.Z)(this.RULE_STACK,(t=>this.shortRuleNameToFullName(t)))}},class{initLooksAhead(t){this.dynamicTokensEnabled=(0,o.Z)(t,"dynamicTokensEnabled")?t.dynamicTokensEnabled:wr.dynamicTokensEnabled,this.maxLookahead=(0,o.Z)(t,"maxLookahead")?t.maxLookahead:wr.maxLookahead,this.lookaheadStrategy=(0,o.Z)(t,"lookaheadStrategy")?t.lookaheadStrategy:new nr({maxLookahead:this.maxLookahead}),this.lookAheadFuncsCache=new Map}preComputeLookaheadFunctions(t){(0,r.Z)(t,(t=>{this.TRACE_INIT(`${t.name} Rule Lookahead`,(()=>{const{alternation:e,repetition:n,option:i,repetitionMandatory:a,repetitionMandatoryWithSeparator:s,repetitionWithSeparator:o}=function(t){rr.reset(),t.accept(rr);const e=rr.dslMethods;return rr.reset(),e}(t);(0,r.Z)(e,(e=>{const n=0===e.idx?"":e.idx;this.TRACE_INIT(`${ct(e)}${n}`,(()=>{const n=this.lookaheadStrategy.buildLookaheadForAlternation({prodOccurrence:e.idx,rule:t,maxLookahead:e.maxLookahead||this.maxLookahead,hasPredicates:e.hasPredicates,dynamicTokensEnabled:this.dynamicTokensEnabled}),r=er(this.fullRuleNameToShort[t.name],256,e.idx);this.setLaFuncCache(r,n)}))})),(0,r.Z)(n,(e=>{this.computeLookaheadFunc(t,e.idx,768,"Repetition",e.maxLookahead,ct(e))})),(0,r.Z)(i,(e=>{this.computeLookaheadFunc(t,e.idx,512,"Option",e.maxLookahead,ct(e))})),(0,r.Z)(a,(e=>{this.computeLookaheadFunc(t,e.idx,Qn,"RepetitionMandatory",e.maxLookahead,ct(e))})),(0,r.Z)(s,(e=>{this.computeLookaheadFunc(t,e.idx,tr,"RepetitionMandatoryWithSeparator",e.maxLookahead,ct(e))})),(0,r.Z)(o,(e=>{this.computeLookaheadFunc(t,e.idx,Jn,"RepetitionWithSeparator",e.maxLookahead,ct(e))}))}))}))}computeLookaheadFunc(t,e,n,r,i,a){this.TRACE_INIT(`${a}${0===e?"":e}`,(()=>{const a=this.lookaheadStrategy.buildLookaheadForOptional({prodOccurrence:e,rule:t,maxLookahead:i||this.maxLookahead,dynamicTokensEnabled:this.dynamicTokensEnabled,prodType:r}),s=er(this.fullRuleNameToShort[t.name],n,e);this.setLaFuncCache(s,a)}))}getKeyForAutomaticLookahead(t,e){return er(this.getLastExplicitRuleShortName(),t,e)}getLaFuncFromCache(t){return this.lookAheadFuncsCache.get(t)}setLaFuncCache(t,e){this.lookAheadFuncsCache.set(t,e)}},class{initTreeBuilder(t){if(this.CST_STACK=[],this.outputCst=t.outputCst,this.nodeLocationTracking=(0,o.Z)(t,"nodeLocationTracking")?t.nodeLocationTracking:wr.nodeLocationTracking,this.outputCst)if(/full/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=ar,this.setNodeLocationFromNode=ar,this.cstPostRule=ge.Z,this.setInitialNodeLocation=this.setInitialNodeLocationFullRecovery):(this.setNodeLocationFromToken=ge.Z,this.setNodeLocationFromNode=ge.Z,this.cstPostRule=this.cstPostRuleFull,this.setInitialNodeLocation=this.setInitialNodeLocationFullRegular);else if(/onlyOffset/i.test(this.nodeLocationTracking))this.recoveryEnabled?(this.setNodeLocationFromToken=ir,this.setNodeLocationFromNode=ir,this.cstPostRule=ge.Z,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRecovery):(this.setNodeLocationFromToken=ge.Z,this.setNodeLocationFromNode=ge.Z,this.cstPostRule=this.cstPostRuleOnlyOffset,this.setInitialNodeLocation=this.setInitialNodeLocationOnlyOffsetRegular);else{if(!/none/i.test(this.nodeLocationTracking))throw Error(`Invalid config option: "${t.nodeLocationTracking}"`);this.setNodeLocationFromToken=ge.Z,this.setNodeLocationFromNode=ge.Z,this.cstPostRule=ge.Z,this.setInitialNodeLocation=ge.Z}else this.cstInvocationStateUpdate=ge.Z,this.cstFinallyStateUpdate=ge.Z,this.cstPostTerminal=ge.Z,this.cstPostNonTerminal=ge.Z,this.cstPostRule=ge.Z}setInitialNodeLocationOnlyOffsetRecovery(t){t.location={startOffset:NaN,endOffset:NaN}}setInitialNodeLocationOnlyOffsetRegular(t){t.location={startOffset:this.LA(1).startOffset,endOffset:NaN}}setInitialNodeLocationFullRecovery(t){t.location={startOffset:NaN,startLine:NaN,startColumn:NaN,endOffset:NaN,endLine:NaN,endColumn:NaN}}setInitialNodeLocationFullRegular(t){const e=this.LA(1);t.location={startOffset:e.startOffset,startLine:e.startLine,startColumn:e.startColumn,endOffset:NaN,endLine:NaN,endColumn:NaN}}cstInvocationStateUpdate(t){const e={name:t,children:Object.create(null)};this.setInitialNodeLocation(e),this.CST_STACK.push(e)}cstFinallyStateUpdate(){this.CST_STACK.pop()}cstPostRuleFull(t){const e=this.LA(0),n=t.location;n.startOffset<=e.startOffset==1?(n.endOffset=e.endOffset,n.endLine=e.endLine,n.endColumn=e.endColumn):(n.startOffset=NaN,n.startLine=NaN,n.startColumn=NaN)}cstPostRuleOnlyOffset(t){const e=this.LA(0),n=t.location;n.startOffset<=e.startOffset==1?n.endOffset=e.endOffset:n.startOffset=NaN}cstPostTerminal(t,e){const n=this.CST_STACK[this.CST_STACK.length-1];var r,i,a;i=e,a=t,void 0===(r=n).children[a]?r.children[a]=[i]:r.children[a].push(i),this.setNodeLocationFromToken(n.location,e)}cstPostNonTerminal(t,e){const n=this.CST_STACK[this.CST_STACK.length-1];!function(t,e,n){void 0===t.children[e]?t.children[e]=[n]:t.children[e].push(n)}(n,e,t),this.setNodeLocationFromNode(n.location,t.location)}getBaseCstVisitorConstructor(){if((0,pt.Z)(this.baseCstVisitorConstructor)){const t=function(t,e){const n=function(){};or(n,t+"BaseSemantics");const r={visit:function(t,e){if((0,J.Z)(t)&&(t=t[0]),!(0,pt.Z)(t))return this[t.name](t.children,e)},validateVisitor:function(){const t=function(t,e){const n=function(t,e){const n=(0,Tt.Z)(e,(e=>!1===(0,xt.Z)(t[e]))),r=(0,s.Z)(n,(e=>({msg:`Missing visitor method: <${e}> on ${t.constructor.name} CST Visitor.`,type:cr.MISSING_METHOD,methodName:e})));return Rt(r)}(t,e);return n}(this,e);if(!(0,a.Z)(t)){const e=(0,s.Z)(t,(t=>t.msg));throw Error(`Errors Detected in CST Visitor <${this.constructor.name}>:\n\t${e.join("\n\n").replace(/\n/g,"\n\t")}`)}}};return(n.prototype=r).constructor=n,n._RULE_NAMES=e,n}(this.className,(0,x.Z)(this.gastProductionsCache));return this.baseCstVisitorConstructor=t,t}return this.baseCstVisitorConstructor}getBaseCstVisitorConstructorWithDefaults(){if((0,pt.Z)(this.baseCstVisitorWithDefaultsConstructor)){const t=function(t,e,n){const i=function(){};or(i,t+"BaseSemanticsWithDefaults");const a=Object.create(n.prototype);return(0,r.Z)(e,(t=>{a[t]=lr})),(i.prototype=a).constructor=i,i}(this.className,(0,x.Z)(this.gastProductionsCache),this.getBaseCstVisitorConstructor());return this.baseCstVisitorWithDefaultsConstructor=t,t}return this.baseCstVisitorWithDefaultsConstructor}getLastExplicitRuleShortName(){const t=this.RULE_STACK;return t[t.length-1]}getPreviousExplicitRuleShortName(){const t=this.RULE_STACK;return t[t.length-2]}getLastExplicitRuleOccurrenceIndex(){const t=this.RULE_OCCURRENCE_STACK;return t[t.length-1]}},class{initLexerAdapter(){this.tokVector=[],this.tokVectorLength=0,this.currIdx=-1}set input(t){if(!0!==this.selfAnalysisDone)throw Error("Missing invocation at the end of the Parser's constructor.");this.reset(),this.tokVector=t,this.tokVectorLength=t.length}get input(){return this.tokVector}SKIP_TOKEN(){return this.currIdx<=this.tokVector.length-2?(this.consumeToken(),this.LA(1)):br}LA(t){const e=this.currIdx+t;return e<0||this.tokVectorLength<=e?br:this.tokVector[e]}consumeToken(){this.currIdx++}exportLexerState(){return this.currIdx}importLexerState(t){this.currIdx=t}resetLexerState(){this.currIdx=-1}moveToTerminatedState(){this.currIdx=this.tokVector.length-1}getLexerPosition(){return this.exportLexerState()}},class{initRecognizerEngine(t,e){if(this.className=this.constructor.name,this.shortRuleNameToFull={},this.fullRuleNameToShort={},this.ruleShortNameIdx=256,this.tokenMatcher=ve,this.subruleIdx=0,this.definedRulesNames=[],this.tokensMap={},this.isBackTrackingStack=[],this.RULE_STACK=[],this.RULE_OCCURRENCE_STACK=[],this.gastProductionsCache={},(0,o.Z)(e,"serializedGrammar"))throw Error("The Parser's configuration can no longer contain a property.\n\tSee: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_6-0-0\n\tFor Further details.");if((0,J.Z)(t)){if((0,a.Z)(t))throw Error("A Token Vocabulary cannot be empty.\n\tNote that the first argument for the parser constructor\n\tis no longer a Token vector (since v4.0).");if("number"==typeof t[0].startOffset)throw Error("The Parser constructor no longer accepts a token vector as the first argument.\n\tSee: https://chevrotain.io/docs/changes/BREAKING_CHANGES.html#_4-0-0\n\tFor Further details.")}if((0,J.Z)(t))this.tokensMap=(0,kt.Z)(t,((t,e)=>(t[e.name]=e,t)),{});else if((0,o.Z)(t,"modes")&&ot((0,H.Z)((0,i.Z)(t.modes)),Ee)){const e=(0,H.Z)((0,i.Z)(t.modes)),n=j(e);this.tokensMap=(0,kt.Z)(n,((t,e)=>(t[e.name]=e,t)),{})}else{if(!(0,hr.Z)(t))throw new Error(" argument must be An Array of Token constructors, A dictionary of Token constructors or an IMultiModeLexerDefinition");this.tokensMap=(0,l.Z)(t)}this.tokensMap.EOF=ze;const n=(0,o.Z)(t,"modes")?(0,H.Z)((0,i.Z)(t.modes)):(0,i.Z)(t),r=ot(n,(t=>(0,a.Z)(t.categoryMatches)));this.tokenMatcher=r?ve:ye,we((0,i.Z)(this.tokensMap))}defineRule(t,e,n){if(this.selfAnalysisDone)throw Error(`Grammar rule <${t}> may not be defined after the 'performSelfAnalysis' method has been called'\nMake sure that all grammar rule definitions are done before 'performSelfAnalysis' is called.`);const r=(0,o.Z)(n,"resyncEnabled")?n.resyncEnabled:kr.resyncEnabled,i=(0,o.Z)(n,"recoveryValueFunc")?n.recoveryValueFunc:kr.recoveryValueFunc,a=this.ruleShortNameIdx<<12;let s;return this.ruleShortNameIdx++,this.shortRuleNameToFull[a]=t,this.fullRuleNameToShort[t]=a,s=!0===this.outputCst?function(...n){try{this.ruleInvocationStateUpdate(a,t,this.subruleIdx),e.apply(this,n);const r=this.CST_STACK[this.CST_STACK.length-1];return this.cstPostRule(r),r}catch(t){return this.invokeRuleCatch(t,r,i)}finally{this.ruleFinallyStateUpdate()}}:function(...n){try{return this.ruleInvocationStateUpdate(a,t,this.subruleIdx),e.apply(this,n)}catch(t){return this.invokeRuleCatch(t,r,i)}finally{this.ruleFinallyStateUpdate()}},Object.assign(s,{ruleName:t,originalGrammarAction:e})}invokeRuleCatch(t,e,n){const r=1===this.RULE_STACK.length,i=e&&!this.isBackTracking()&&this.recoveryEnabled;if(Zn(t)){const e=t;if(i){const r=this.findReSyncTokenType();if(this.isInCurrentRuleReSyncSet(r)){if(e.resyncedTokens=this.reSyncTo(r),this.outputCst){const t=this.CST_STACK[this.CST_STACK.length-1];return t.recoveredNode=!0,t}return n(t)}if(this.outputCst){const t=this.CST_STACK[this.CST_STACK.length-1];t.recoveredNode=!0,e.partialCstResult=t}throw e}if(r)return this.moveToTerminatedState(),n(t);throw e}throw t}optionInternal(t,e){const n=this.getKeyForAutomaticLookahead(512,e);return this.optionInternalLogic(t,e,n)}optionInternalLogic(t,e,n){let r,i=this.getLaFuncFromCache(n);if("function"!=typeof t){r=t.DEF;const e=t.GATE;if(void 0!==e){const t=i;i=()=>e.call(this)&&t.call(this)}}else r=t;if(!0===i.call(this))return r.call(this)}atLeastOneInternal(t,e){const n=this.getKeyForAutomaticLookahead(Qn,t);return this.atLeastOneInternalLogic(t,e,n)}atLeastOneInternalLogic(t,e,n){let r,i=this.getLaFuncFromCache(n);if("function"!=typeof e){r=e.DEF;const t=e.GATE;if(void 0!==t){const e=i;i=()=>t.call(this)&&e.call(this)}}else r=e;if(!0!==i.call(this))throw this.raiseEarlyExitException(t,fn.REPETITION_MANDATORY,e.ERR_MSG);{let t=this.doSingleRepetition(r);for(;!0===i.call(this)&&!0===t;)t=this.doSingleRepetition(r)}this.attemptInRepetitionRecovery(this.atLeastOneInternal,[t,e],i,Qn,t,hn)}atLeastOneSepFirstInternal(t,e){const n=this.getKeyForAutomaticLookahead(tr,t);this.atLeastOneSepFirstInternalLogic(t,e,n)}atLeastOneSepFirstInternalLogic(t,e,n){const r=e.DEF,i=e.SEP;if(!0!==this.getLaFuncFromCache(n).call(this))throw this.raiseEarlyExitException(t,fn.REPETITION_MANDATORY_WITH_SEPARATOR,e.ERR_MSG);{r.call(this);const e=()=>this.tokenMatcher(this.LA(1),i);for(;!0===this.tokenMatcher(this.LA(1),i);)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[t,i,e,r,un],e,tr,t,un)}}manyInternal(t,e){const n=this.getKeyForAutomaticLookahead(768,t);return this.manyInternalLogic(t,e,n)}manyInternalLogic(t,e,n){let r,i=this.getLaFuncFromCache(n);if("function"!=typeof e){r=e.DEF;const t=e.GATE;if(void 0!==t){const e=i;i=()=>t.call(this)&&e.call(this)}}else r=e;let a=!0;for(;!0===i.call(this)&&!0===a;)a=this.doSingleRepetition(r);this.attemptInRepetitionRecovery(this.manyInternal,[t,e],i,768,t,ln,a)}manySepFirstInternal(t,e){const n=this.getKeyForAutomaticLookahead(Jn,t);this.manySepFirstInternalLogic(t,e,n)}manySepFirstInternalLogic(t,e,n){const r=e.DEF,i=e.SEP;if(!0===this.getLaFuncFromCache(n).call(this)){r.call(this);const e=()=>this.tokenMatcher(this.LA(1),i);for(;!0===this.tokenMatcher(this.LA(1),i);)this.CONSUME(i),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[t,i,e,r,cn],e,Jn,t,cn)}}repetitionSepSecondInternal(t,e,n,r,i){for(;n();)this.CONSUME(e),r.call(this);this.attemptInRepetitionRecovery(this.repetitionSepSecondInternal,[t,e,n,r,i],n,tr,t,i)}doSingleRepetition(t){const e=this.getLexerPosition();return t.call(this),this.getLexerPosition()>e}orInternal(t,e){const n=this.getKeyForAutomaticLookahead(256,e),r=(0,J.Z)(t)?t:t.DEF,i=this.getLaFuncFromCache(n).call(this,r);if(void 0!==i)return r[i].ALT.call(this);this.raiseNoAltException(e,t.ERR_MSG)}ruleFinallyStateUpdate(){if(this.RULE_STACK.pop(),this.RULE_OCCURRENCE_STACK.pop(),this.cstFinallyStateUpdate(),0===this.RULE_STACK.length&&!1===this.isAtEndOfInput()){const t=this.LA(1),e=this.errorMessageProvider.buildNotAllInputParsedMessage({firstRedundant:t,ruleName:this.getCurrRuleFullName()});this.SAVE_ERROR(new Vn(e,t))}}subruleInternal(t,e,n){let r;try{const i=void 0!==n?n.ARGS:void 0;return this.subruleIdx=e,r=t.apply(this,i),this.cstPostNonTerminal(r,void 0!==n&&void 0!==n.LABEL?n.LABEL:t.ruleName),r}catch(e){throw this.subruleInternalError(e,n,t.ruleName)}}subruleInternalError(t,e,n){throw Zn(t)&&void 0!==t.partialCstResult&&(this.cstPostNonTerminal(t.partialCstResult,void 0!==e&&void 0!==e.LABEL?e.LABEL:n),delete t.partialCstResult),t}consumeInternal(t,e,n){let r;try{const e=this.LA(1);!0===this.tokenMatcher(e,t)?(this.consumeToken(),r=e):this.consumeInternalError(t,e,n)}catch(n){r=this.consumeInternalRecovery(t,e,n)}return this.cstPostTerminal(void 0!==n&&void 0!==n.LABEL?n.LABEL:t.name,r),r}consumeInternalError(t,e,n){let r;const i=this.LA(0);throw r=void 0!==n&&n.ERR_MSG?n.ERR_MSG:this.errorMessageProvider.buildMismatchTokenMessage({expected:t,actual:e,previous:i,ruleName:this.getCurrRuleFullName()}),this.SAVE_ERROR(new Un(r,e,i))}consumeInternalRecovery(t,e,n){if(!this.recoveryEnabled||"MismatchedTokenException"!==n.name||this.isBackTracking())throw n;{const r=this.getFollowsForInRuleRecovery(t,e);try{return this.tryInRuleRecovery(t,r)}catch(t){throw t.name===Hn?n:t}}}saveRecogState(){const t=this.errors,e=(0,l.Z)(this.RULE_STACK);return{errors:t,lexerState:this.exportLexerState(),RULE_STACK:e,CST_STACK:this.CST_STACK}}reloadRecogState(t){this.errors=t.errors,this.importLexerState(t.lexerState),this.RULE_STACK=t.RULE_STACK}ruleInvocationStateUpdate(t,e,n){this.RULE_OCCURRENCE_STACK.push(n),this.RULE_STACK.push(t),this.cstInvocationStateUpdate(e)}isBackTracking(){return 0!==this.isBackTrackingStack.length}getCurrRuleFullName(){const t=this.getLastExplicitRuleShortName();return this.shortRuleNameToFull[t]}shortRuleNameToFullName(t){return this.shortRuleNameToFull[t]}isAtEndOfInput(){return this.tokenMatcher(this.LA(1),ze)}reset(){this.resetLexerState(),this.subruleIdx=0,this.isBackTrackingStack=[],this.errors=[],this.RULE_STACK=[],this.CST_STACK=[],this.RULE_OCCURRENCE_STACK=[]}},class{ACTION(t){return t.call(this)}consume(t,e,n){return this.consumeInternal(e,t,n)}subrule(t,e,n){return this.subruleInternal(e,t,n)}option(t,e){return this.optionInternal(e,t)}or(t,e){return this.orInternal(e,t)}many(t,e){return this.manyInternal(t,e)}atLeastOne(t,e){return this.atLeastOneInternal(t,e)}CONSUME(t,e){return this.consumeInternal(t,0,e)}CONSUME1(t,e){return this.consumeInternal(t,1,e)}CONSUME2(t,e){return this.consumeInternal(t,2,e)}CONSUME3(t,e){return this.consumeInternal(t,3,e)}CONSUME4(t,e){return this.consumeInternal(t,4,e)}CONSUME5(t,e){return this.consumeInternal(t,5,e)}CONSUME6(t,e){return this.consumeInternal(t,6,e)}CONSUME7(t,e){return this.consumeInternal(t,7,e)}CONSUME8(t,e){return this.consumeInternal(t,8,e)}CONSUME9(t,e){return this.consumeInternal(t,9,e)}SUBRULE(t,e){return this.subruleInternal(t,0,e)}SUBRULE1(t,e){return this.subruleInternal(t,1,e)}SUBRULE2(t,e){return this.subruleInternal(t,2,e)}SUBRULE3(t,e){return this.subruleInternal(t,3,e)}SUBRULE4(t,e){return this.subruleInternal(t,4,e)}SUBRULE5(t,e){return this.subruleInternal(t,5,e)}SUBRULE6(t,e){return this.subruleInternal(t,6,e)}SUBRULE7(t,e){return this.subruleInternal(t,7,e)}SUBRULE8(t,e){return this.subruleInternal(t,8,e)}SUBRULE9(t,e){return this.subruleInternal(t,9,e)}OPTION(t){return this.optionInternal(t,0)}OPTION1(t){return this.optionInternal(t,1)}OPTION2(t){return this.optionInternal(t,2)}OPTION3(t){return this.optionInternal(t,3)}OPTION4(t){return this.optionInternal(t,4)}OPTION5(t){return this.optionInternal(t,5)}OPTION6(t){return this.optionInternal(t,6)}OPTION7(t){return this.optionInternal(t,7)}OPTION8(t){return this.optionInternal(t,8)}OPTION9(t){return this.optionInternal(t,9)}OR(t){return this.orInternal(t,0)}OR1(t){return this.orInternal(t,1)}OR2(t){return this.orInternal(t,2)}OR3(t){return this.orInternal(t,3)}OR4(t){return this.orInternal(t,4)}OR5(t){return this.orInternal(t,5)}OR6(t){return this.orInternal(t,6)}OR7(t){return this.orInternal(t,7)}OR8(t){return this.orInternal(t,8)}OR9(t){return this.orInternal(t,9)}MANY(t){this.manyInternal(0,t)}MANY1(t){this.manyInternal(1,t)}MANY2(t){this.manyInternal(2,t)}MANY3(t){this.manyInternal(3,t)}MANY4(t){this.manyInternal(4,t)}MANY5(t){this.manyInternal(5,t)}MANY6(t){this.manyInternal(6,t)}MANY7(t){this.manyInternal(7,t)}MANY8(t){this.manyInternal(8,t)}MANY9(t){this.manyInternal(9,t)}MANY_SEP(t){this.manySepFirstInternal(0,t)}MANY_SEP1(t){this.manySepFirstInternal(1,t)}MANY_SEP2(t){this.manySepFirstInternal(2,t)}MANY_SEP3(t){this.manySepFirstInternal(3,t)}MANY_SEP4(t){this.manySepFirstInternal(4,t)}MANY_SEP5(t){this.manySepFirstInternal(5,t)}MANY_SEP6(t){this.manySepFirstInternal(6,t)}MANY_SEP7(t){this.manySepFirstInternal(7,t)}MANY_SEP8(t){this.manySepFirstInternal(8,t)}MANY_SEP9(t){this.manySepFirstInternal(9,t)}AT_LEAST_ONE(t){this.atLeastOneInternal(0,t)}AT_LEAST_ONE1(t){return this.atLeastOneInternal(1,t)}AT_LEAST_ONE2(t){this.atLeastOneInternal(2,t)}AT_LEAST_ONE3(t){this.atLeastOneInternal(3,t)}AT_LEAST_ONE4(t){this.atLeastOneInternal(4,t)}AT_LEAST_ONE5(t){this.atLeastOneInternal(5,t)}AT_LEAST_ONE6(t){this.atLeastOneInternal(6,t)}AT_LEAST_ONE7(t){this.atLeastOneInternal(7,t)}AT_LEAST_ONE8(t){this.atLeastOneInternal(8,t)}AT_LEAST_ONE9(t){this.atLeastOneInternal(9,t)}AT_LEAST_ONE_SEP(t){this.atLeastOneSepFirstInternal(0,t)}AT_LEAST_ONE_SEP1(t){this.atLeastOneSepFirstInternal(1,t)}AT_LEAST_ONE_SEP2(t){this.atLeastOneSepFirstInternal(2,t)}AT_LEAST_ONE_SEP3(t){this.atLeastOneSepFirstInternal(3,t)}AT_LEAST_ONE_SEP4(t){this.atLeastOneSepFirstInternal(4,t)}AT_LEAST_ONE_SEP5(t){this.atLeastOneSepFirstInternal(5,t)}AT_LEAST_ONE_SEP6(t){this.atLeastOneSepFirstInternal(6,t)}AT_LEAST_ONE_SEP7(t){this.atLeastOneSepFirstInternal(7,t)}AT_LEAST_ONE_SEP8(t){this.atLeastOneSepFirstInternal(8,t)}AT_LEAST_ONE_SEP9(t){this.atLeastOneSepFirstInternal(9,t)}RULE(t,e,n=kr){if(it(this.definedRulesNames,t)){const e={message:Ve.buildDuplicateRuleNameError({topLevelRule:t,grammarName:this.className}),type:Tr.DUPLICATE_RULE_NAME,ruleName:t};this.definitionErrors.push(e)}this.definedRulesNames.push(t);const r=this.defineRule(t,e,n);return this[t]=r,r}OVERRIDE_RULE(t,e,n=kr){const r=function(t,e,n){const r=[];let i;return it(e,t)||(i=`Invalid rule override, rule: ->${t}<- cannot be overridden in the grammar: ->${n}<-as it is not defined in any of the super grammars `,r.push({message:i,type:Tr.INVALID_RULE_OVERRIDE,ruleName:t})),r}(t,this.definedRulesNames,this.className);this.definitionErrors=this.definitionErrors.concat(r);const i=this.defineRule(t,e,n);return this[t]=i,i}BACKTRACK(t,e){return function(){this.isBackTrackingStack.push(1);const n=this.saveRecogState();try{return t.apply(this,e),!0}catch(t){if(Zn(t))return!1;throw t}finally{this.reloadRecogState(n),this.isBackTrackingStack.pop()}}}getGAstProductions(){return this.gastProductionsCache}getSerializedGastProductions(){return t=(0,i.Z)(this.gastProductionsCache),(0,s.Z)(t,U);var t}},class{initErrorHandler(t){this._errors=[],this.errorMessageProvider=(0,o.Z)(t,"errorMessageProvider")?t.errorMessageProvider:wr.errorMessageProvider}SAVE_ERROR(t){if(Zn(t))return t.context={ruleStack:this.getHumanReadableRuleStack(),ruleOccurrenceStack:(0,l.Z)(this.RULE_OCCURRENCE_STACK)},this._errors.push(t),t;throw Error("Trying to save an Error which is not a RecognitionException")}get errors(){return(0,l.Z)(this._errors)}set errors(t){this._errors=t}raiseEarlyExitException(t,e,n){const r=this.getCurrRuleFullName(),i=Cn(t,this.getGAstProductions()[r],e,this.maxLookahead)[0],a=[];for(let t=1;t<=this.maxLookahead;t++)a.push(this.LA(t));const s=this.errorMessageProvider.buildEarlyExitMessage({expectedIterationPaths:i,actual:a,previous:this.LA(0),customUserDescription:n,ruleName:r});throw this.SAVE_ERROR(new qn(s,this.LA(1),this.LA(0)))}raiseNoAltException(t,e){const n=this.getCurrRuleFullName(),r=Sn(t,this.getGAstProductions()[n],this.maxLookahead),i=[];for(let t=1;t<=this.maxLookahead;t++)i.push(this.LA(t));const a=this.LA(0),s=this.errorMessageProvider.buildNoViableAltMessage({expectedPathsPerAlt:r,actual:i,previous:a,customUserDescription:e,ruleName:this.getCurrRuleFullName()});throw this.SAVE_ERROR(new Gn(s,this.LA(1),a))}},class{initContentAssist(){}computeContentAssist(t,e){const n=this.gastProductionsCache[t];if((0,pt.Z)(n))throw Error(`Rule ->${t}<- does not exist in this grammar.`);return pn([n],e,this.tokenMatcher,this.maxLookahead)}getNextPossibleTokenTypes(t){const e=Dt(t.ruleStack),n=this.getGAstProductions()[e];return new sn(n,t).startWalking()}},class{initGastRecorder(t){this.recordingProdStack=[],this.RECORDING_PHASE=!1}enableRecording(){this.RECORDING_PHASE=!0,this.TRACE_INIT("Enable Recording",(()=>{for(let t=0;t<10;t++){const e=t>0?t:"";this[`CONSUME${e}`]=function(e,n){return this.consumeInternalRecord(e,t,n)},this[`SUBRULE${e}`]=function(e,n){return this.subruleInternalRecord(e,t,n)},this[`OPTION${e}`]=function(e){return this.optionInternalRecord(e,t)},this[`OR${e}`]=function(e){return this.orInternalRecord(e,t)},this[`MANY${e}`]=function(e){this.manyInternalRecord(t,e)},this[`MANY_SEP${e}`]=function(e){this.manySepFirstInternalRecord(t,e)},this[`AT_LEAST_ONE${e}`]=function(e){this.atLeastOneInternalRecord(t,e)},this[`AT_LEAST_ONE_SEP${e}`]=function(e){this.atLeastOneSepFirstInternalRecord(t,e)}}this.consume=function(t,e,n){return this.consumeInternalRecord(e,t,n)},this.subrule=function(t,e,n){return this.subruleInternalRecord(e,t,n)},this.option=function(t,e){return this.optionInternalRecord(e,t)},this.or=function(t,e){return this.orInternalRecord(e,t)},this.many=function(t,e){this.manyInternalRecord(t,e)},this.atLeastOne=function(t,e){this.atLeastOneInternalRecord(t,e)},this.ACTION=this.ACTION_RECORD,this.BACKTRACK=this.BACKTRACK_RECORD,this.LA=this.LA_RECORD}))}disableRecording(){this.RECORDING_PHASE=!1,this.TRACE_INIT("Deleting Recording methods",(()=>{const t=this;for(let e=0;e<10;e++){const n=e>0?e:"";delete t[`CONSUME${n}`],delete t[`SUBRULE${n}`],delete t[`OPTION${n}`],delete t[`OR${n}`],delete t[`MANY${n}`],delete t[`MANY_SEP${n}`],delete t[`AT_LEAST_ONE${n}`],delete t[`AT_LEAST_ONE_SEP${n}`]}delete t.consume,delete t.subrule,delete t.option,delete t.or,delete t.many,delete t.atLeastOne,delete t.ACTION,delete t.BACKTRACK,delete t.LA}))}ACTION_RECORD(t){}BACKTRACK_RECORD(t,e){return()=>!0}LA_RECORD(t){return br}topLevelRuleRecord(t,e){try{const n=new O({definition:[],name:t});return n.name=t,this.recordingProdStack.push(n),e.call(this),this.recordingProdStack.pop(),n}catch(t){if(!0!==t.KNOWN_RECORDER_ERROR)try{t.message=t.message+'\n\t This error was thrown during the "grammar recording phase" For more info see:\n\thttps://chevrotain.io/docs/guide/internals.html#grammar-recording'}catch(e){throw t}throw t}}optionInternalRecord(t,e){return mr.call(this,$,t,e)}atLeastOneInternalRecord(t,e){mr.call(this,B,e,t)}atLeastOneSepFirstInternalRecord(t,e){mr.call(this,F,e,t,!0)}manyInternalRecord(t,e){mr.call(this,W,e,t)}manySepFirstInternalRecord(t,e){mr.call(this,z,e,t,!0)}orInternalRecord(t,e){return yr.call(this,t,e)}subruleInternalRecord(t,e,n){if(xr(e),!t||!1===(0,o.Z)(t,"ruleName")){const n=new Error(` argument is invalid expecting a Parser method reference but got: <${JSON.stringify(t)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}const r=(0,fe.Z)(this.recordingProdStack),i=t.ruleName,a=new D({idx:e,nonTerminalName:i,label:null==n?void 0:n.LABEL,referencedRule:void 0});return r.definition.push(a),this.outputCst?fr:ur}consumeInternalRecord(t,e,n){if(xr(e),!Te(t)){const n=new Error(` argument is invalid expecting a TokenType reference but got: <${JSON.stringify(t)}>\n inside top level rule: <${this.recordingProdStack[0].name}>`);throw n.KNOWN_RECORDER_ERROR=!0,n}const r=(0,fe.Z)(this.recordingProdStack),i=new Y({idx:e,terminalType:t,label:null==n?void 0:n.LABEL});return r.definition.push(i),gr}},class{initPerformanceTracer(t){if((0,o.Z)(t,"traceInitPerf")){const e=t.traceInitPerf,n="number"==typeof e;this.traceInitMaxIdent=n?e:1/0,this.traceInitPerf=n?e>0:e}else this.traceInitMaxIdent=0,this.traceInitPerf=wr.traceInitPerf;this.traceInitIndent=-1}TRACE_INIT(t,e){if(!0===this.traceInitPerf){this.traceInitIndent++;const n=new Array(this.traceInitIndent+1).join("\t");this.traceInitIndent`);const{time:r,value:i}=me(e),a=r>10?console.warn:console.log;return this.traceInitIndent time: ${r}ms`),this.traceInitIndent--,i}return e()}}].forEach((t=>{const e=t.prototype;Object.getOwnPropertyNames(e).forEach((n=>{if("constructor"===n)return;const r=Object.getOwnPropertyDescriptor(e,n);r&&(r.get||r.set)?Object.defineProperty(_r.prototype,n,r):_r.prototype[n]=t.prototype[n]}))}));class Cr extends Sr{constructor(t,e=wr){const n=(0,l.Z)(e);n.outputCst=!1,super(t,n)}}},1387:(t,e,n)=>{"use strict";function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,s=!0,o=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return s=t.done,t},e:function(t){o=!0,a=t},f:function(){try{s||null==n.return||n.return()}finally{if(o)throw a}}}}function o(t,e,n){return(e=h(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function l(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,a,s,o=[],l=!0,c=!1;try{if(a=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;l=!1}else for(;!(l=(r=a.call(n)).done)&&(o.push(r.value),o.length!==e);l=!0);}catch(t){c=!0,i=t}finally{try{if(!l&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(c)throw i}}return o}}(t,e)||d(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function c(t){return function(t){if(Array.isArray(t))return r(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||d(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function h(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,"string");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==typeof e?e:e+""}function u(t){return u="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},u(t)}function d(t,e){if(t){if("string"==typeof t)return r(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(t,e):void 0}}n.d(e,{Z:()=>Ju});var p="undefined"==typeof window?null:window,g=p?p.navigator:null;p&&p.document;var f,m,y,v,x,b,w,k,T,_,E,S,C,A,L,M,N,I,R,D,O,P,$,B,F,W,z,Z,Y=u(""),U=u({}),G=u((function(){})),V="undefined"==typeof HTMLElement?"undefined":u(HTMLElement),q=function(t){return t&&t.instanceString&&H(t.instanceString)?t.instanceString():null},j=function(t){return null!=t&&u(t)==Y},H=function(t){return null!=t&&u(t)===G},X=function(t){return!tt(t)&&(Array.isArray?Array.isArray(t):null!=t&&t instanceof Array)},K=function(t){return null!=t&&u(t)===U&&!X(t)&&t.constructor===Object},Q=function(t){return null!=t&&u(t)===u(1)&&!isNaN(t)},J=function(t){return"undefined"===V?void 0:null!=t&&t instanceof HTMLElement},tt=function(t){return et(t)||nt(t)},et=function(t){return"collection"===q(t)&&t._private.single},nt=function(t){return"collection"===q(t)&&!t._private.single},rt=function(t){return"core"===q(t)},it=function(t){return"stylesheet"===q(t)},at=function(t){return null==t||!(""!==t&&!t.match(/^\s+$/))},st=function(t){return function(t){return null!=t&&u(t)===U}(t)&&H(t.then)},ot=function(t,e){e||(e=function(){if(1===arguments.length)return arguments[0];if(0===arguments.length)return"undefined";for(var t=[],e=0;ee?1:0},vt=null!=Object.assign?Object.assign.bind(Object):function(t){for(var e=arguments,n=1;n255)return;e.push(Math.floor(a))}var s=r[1]||r[2]||r[3],o=r[1]&&r[2]&&r[3];if(s&&!o)return;var l=n[4];if(void 0!==l){if((l=parseFloat(l))<0||l>1)return;e.push(l)}}return e}(t)||function(t){var e,n,r,i,a,s,o,l;function c(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}var h=new RegExp("^"+ft+"$").exec(t);if(h){if((n=parseInt(h[1]))<0?n=(360- -1*n%360)%360:n>360&&(n%=360),n/=360,(r=parseFloat(h[2]))<0||r>100)return;if(r/=100,(i=parseFloat(h[3]))<0||i>100)return;if(i/=100,void 0!==(a=h[4])&&((a=parseFloat(a))<0||a>1))return;if(0===r)s=o=l=Math.round(255*i);else{var u=i<.5?i*(1+r):i+r-i*r,d=2*i-u;s=Math.round(255*c(d,u,n+1/3)),o=Math.round(255*c(d,u,n)),l=Math.round(255*c(d,u,n-1/3))}e=[s,o,l,a]}return e}(t)},bt={transparent:[0,0,0,0],aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],grey:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]},wt=function(t){for(var e=t.map,n=t.keys,r=n.length,i=0;i=s||e<0||m&&t-g>=h}function b(){var t=e();if(x(t))return w(t);d=setTimeout(b,function(t){var e=s-(t-p);return m?i(e,h-(t-g)):e}(t))}function w(t){return d=void 0,y&&l?v(t):(l=c=void 0,u)}function k(){var t=e(),n=x(t);if(l=arguments,c=this,p=t,n){if(void 0===d)return function(t){return g=t,d=setTimeout(b,s),f?v(t):u}(p);if(m)return clearTimeout(d),d=setTimeout(b,s),v(p)}return void 0===d&&(d=setTimeout(b,s)),u}return s=n(s)||0,t(o)&&(f=!!o.leading,h=(m="maxWait"in o)?r(n(o.maxWait)||0,s):h,y="trailing"in o?!!o.trailing:y),k.cancel=function(){void 0!==d&&clearTimeout(d),g=0,l=p=c=d=void 0},k.flush=function(){return void 0===d?u:w(e())},k}}()),Nt=p?p.performance:null,It=Nt&&Nt.now?function(){return Nt.now()}:function(){return Date.now()},Rt=function(){if(p){if(p.requestAnimationFrame)return function(t){p.requestAnimationFrame(t)};if(p.mozRequestAnimationFrame)return function(t){p.mozRequestAnimationFrame(t)};if(p.webkitRequestAnimationFrame)return function(t){p.webkitRequestAnimationFrame(t)};if(p.msRequestAnimationFrame)return function(t){p.msRequestAnimationFrame(t)}}return function(t){t&&setTimeout((function(){t(It())}),1e3/60)}}(),Dt=function(t){return Rt(t)},Ot=It,Pt=9261,$t=5381,Bt=function(t){for(var e,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Pt;!(e=t.next()).done;)n=65599*n+e.value|0;return n},Ft=function(t){return 65599*(arguments.length>1&&void 0!==arguments[1]?arguments[1]:Pt)+t|0},Wt=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:$t;return(e<<5)+e+t|0},zt=function(t){return 2097152*t[0]+t[1]},Zt=function(t,e){return[Ft(t[0],e[0]),Wt(t[1],e[1])]},Yt=function(t,e){var n={value:0,done:!1},r=0,i=t.length;return Bt({next:function(){return r=0;r--)t[r]===e&&t.splice(r,1)},he=function(t){t.splice(0,t.length)},ue=function(t,e,n){return n&&(e=ht(n,e)),t[e]},de=function(t,e,n,r){n&&(e=ht(n,e)),t[e]=r},pe="undefined"!=typeof Map?Map:function(){return a((function t(){i(this,t),this._obj={}}),[{key:"set",value:function(t,e){return this._obj[t]=e,this}},{key:"delete",value:function(t){return this._obj[t]=void 0,this}},{key:"clear",value:function(){this._obj={}}},{key:"has",value:function(t){return void 0!==this._obj[t]}},{key:"get",value:function(t){return this._obj[t]}}])}(),ge=function(){return a((function t(e){if(i(this,t),this._obj=Object.create(null),this.size=0,null!=e){var n;n=null!=e.instanceString&&e.instanceString()===this.instanceString()?e.toArray():e;for(var r=0;r2&&void 0!==arguments[2])||arguments[2];if(void 0!==t&&void 0!==e&&rt(t)){var r=e.group;if(null==r&&(r=e.data&&null!=e.data.source&&null!=e.data.target?"edges":"nodes"),"nodes"===r||"edges"===r){this.length=1,this[0]=this;var i=this._private={cy:t,single:!0,data:e.data||{},position:e.position||{x:0,y:0},autoWidth:void 0,autoHeight:void 0,autoPadding:void 0,compoundBoundsClean:!1,listeners:[],group:r,style:{},rstyle:{},styleCxts:[],styleKeys:{},removed:!0,selected:!!e.selected,selectable:void 0===e.selectable||!!e.selectable,locked:!!e.locked,grabbed:!1,grabbable:void 0===e.grabbable||!!e.grabbable,pannable:void 0===e.pannable?"edges"===r:!!e.pannable,active:!1,classes:new fe,animation:{current:[],queue:[]},rscratch:{},scratch:e.scratch||{},edges:[],children:[],parent:e.parent&&e.parent.isNode()?e.parent:null,traversalCache:{},backgrounding:!1,bbCache:null,bbCacheShift:{x:0,y:0},bodyBounds:null,overlayBounds:null,labelBounds:{all:null,source:null,target:null,main:null},arrowBounds:{source:null,target:null,"mid-source":null,"mid-target":null}};if(null==i.position.x&&(i.position.x=0),null==i.position.y&&(i.position.y=0),e.renderedPosition){var a=e.renderedPosition,s=t.pan(),o=t.zoom();i.position={x:(a.x-s.x)/o,y:(a.y-s.y)/o}}var l=[];X(e.classes)?l=e.classes:j(e.classes)&&(l=e.classes.split(/\s+/));for(var c=0,h=l.length;ce?1:0},c=function(t,e,i,a,s){var o;if(null==i&&(i=0),null==s&&(s=n),i<0)throw new Error("lo must be non-negative");for(null==a&&(a=t.length);in;0<=n?e++:e--)c.push(e);return c}.apply(this).reverse()).length;af;0<=f?++d:--d)m.push(a(t,r));return m},g=function(t,e,r,i){var a,s,o;for(null==i&&(i=n),a=t[r];r>e&&i(a,s=t[o=r-1>>1])<0;)t[r]=s,r=o;return t[r]=a},f=function(t,e,r){var i,a,s,o,l;for(null==r&&(r=n),a=t.length,l=e,s=t[e],i=2*e+1;i0;){var w=y.pop(),k=f(w),T=w.id();if(u[T]=k,k!==1/0)for(var _=w.neighborhood().intersect(p),E=0;E<_.length;E++){var S=_[E],C=S.id(),A=b(w,S),L=k+A.dist;L0)for(n.unshift(e);h[i];){var a=h[i];n.unshift(a.edge),n.unshift(a.node),i=(r=a.node).id()}return s.spawn(n)}}}},Ce={kruskal:function(t){t=t||function(t){return 1};for(var e=this.byGroup(),n=e.nodes,r=e.edges,i=n.length,a=new Array(i),s=n,o=function(t){for(var e=0;e0;){if(c=(l=f.pop()).id(),m.delete(c),w++,c===u){for(var k=[],T=i,_=u,E=v[_];k.unshift(T),null!=E&&k.unshift(E),null!=(T=y[_]);)E=v[_=T.id()];return{found:!0,distance:d[c],path:this.spawn(k),steps:w}}g[c]=!0;for(var S=l._private.edges,C=0;CS&&(p[E]=S,y[E]=_,v[E]=b),!i){var C=_*c+T;!i&&p[C]>S&&(p[C]=S,y[C]=T,v[C]=b)}}}for(var A=0;A1&&void 0!==arguments[1]?arguments[1]:a,r=[],i=v(t);;){if(null==i)return e.spawn();var s=y(i),l=s.edge,c=s.pred;if(r.unshift(i[0]),i.same(n)&&r.length>0)break;null!=l&&r.unshift(l),i=c}return o.spawn(r)},hasNegativeWeightCycle:g,negativeWeightCycles:f}}},De=Math.sqrt(2),Oe=function(t,e,n){0===n.length&&ee("Karger-Stein must be run on a connected (sub)graph");for(var r=n[t],i=r[1],a=r[2],s=e[i],o=e[a],l=n,c=l.length-1;c>=0;c--){var h=l[c],u=h[1],d=h[2];(e[u]===s&&e[d]===o||e[u]===o&&e[d]===s)&&l.splice(c,1)}for(var p=0;pr;){var i=Math.floor(Math.random()*e.length);e=Oe(i,t,e),n--}return e},$e={kargerStein:function(){var t=this,e=this.byGroup(),n=e.nodes,r=e.edges;r.unmergeBy((function(t){return t.isLoop()}));var i=n.length,a=r.length,s=Math.ceil(Math.pow(Math.log(i)/Math.LN2,2)),o=Math.floor(i/De);if(!(i<2)){for(var l=[],c=0;c0?1:t<0?-1:0},Ue=function(t,e){return Math.sqrt(Ge(t,e))},Ge=function(t,e){var n=e.x-t.x,r=e.y-t.y;return n*n+r*r},Ve=function(t){for(var e=t.length,n=0,r=0;r=t.x1&&t.y2>=t.y1)return{x1:t.x1,y1:t.y1,x2:t.x2,y2:t.y2,w:t.x2-t.x1,h:t.y2-t.y1};if(null!=t.w&&null!=t.h&&t.w>=0&&t.h>=0)return{x1:t.x1,y1:t.y1,x2:t.x1+t.w,y2:t.y1+t.h,w:t.w,h:t.h}}},Ke=function(t,e){t.x1=Math.min(t.x1,e.x1),t.x2=Math.max(t.x2,e.x2),t.w=t.x2-t.x1,t.y1=Math.min(t.y1,e.y1),t.y2=Math.max(t.y2,e.y2),t.h=t.y2-t.y1},Qe=function(t,e,n){t.x1=Math.min(t.x1,e),t.x2=Math.max(t.x2,e),t.w=t.x2-t.x1,t.y1=Math.min(t.y1,n),t.y2=Math.max(t.y2,n),t.h=t.y2-t.y1},Je=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return t.x1-=e,t.x2+=e,t.y1-=e,t.y2+=e,t.w=t.x2-t.x1,t.h=t.y2-t.y1,t},tn=function(t){var e,n,r,i,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[0];if(1===a.length)e=n=r=i=a[0];else if(2===a.length)e=r=a[0],i=n=a[1];else if(4===a.length){var s=l(a,4);e=s[0],n=s[1],r=s[2],i=s[3]}return t.x1-=i,t.x2+=n,t.y1-=e,t.y2+=r,t.w=t.x2-t.x1,t.h=t.y2-t.y1,t},en=function(t,e){t.x1=e.x1,t.y1=e.y1,t.x2=e.x2,t.y2=e.y2,t.w=t.x2-t.x1,t.h=t.y2-t.y1},nn=function(t,e){return!(t.x1>e.x2||e.x1>t.x2||t.x2e.y2||e.y1>t.y2)},rn=function(t,e,n){return t.x1<=e&&e<=t.x2&&t.y1<=n&&n<=t.y2},an=function(t,e,n,r,i,a,s){var o,l,c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:"auto",h="auto"===c?Tn(i,a):c,u=i/2,d=a/2,p=(h=Math.min(h,u,d))!==u,g=h!==d;if(p){var f=r-d-s;if((o=yn(t,e,n,r,n-u+h-s,f,n+u-h+s,f,!1)).length>0)return o}if(g){var m=n+u+s;if((o=yn(t,e,n,r,m,r-d+h-s,m,r+d-h+s,!1)).length>0)return o}if(p){var y=r+d+s;if((o=yn(t,e,n,r,n-u+h-s,y,n+u-h+s,y,!1)).length>0)return o}if(g){var v=n-u-s;if((o=yn(t,e,n,r,v,r-d+h-s,v,r+d-h+s,!1)).length>0)return o}var x=n-u+h,b=r-d+h;if((l=fn(t,e,n,r,x,b,h+s)).length>0&&l[0]<=x&&l[1]<=b)return[l[0],l[1]];var w=n+u-h,k=r-d+h;if((l=fn(t,e,n,r,w,k,h+s)).length>0&&l[0]>=w&&l[1]<=k)return[l[0],l[1]];var T=n+u-h,_=r+d-h;if((l=fn(t,e,n,r,T,_,h+s)).length>0&&l[0]>=T&&l[1]>=_)return[l[0],l[1]];var E=n-u+h,S=r+d-h;return(l=fn(t,e,n,r,E,S,h+s)).length>0&&l[0]<=E&&l[1]>=S?[l[0],l[1]]:[]},sn=function(t,e,n,r,i,a,s){var o=s,l=Math.min(n,i),c=Math.max(n,i),h=Math.min(r,a),u=Math.max(r,a);return l-o<=t&&t<=c+o&&h-o<=e&&e<=u+o},on=function(t,e,n,r,i,a,s,o,l){var c=Math.min(n,s,i)-l,h=Math.max(n,s,i)+l,u=Math.min(r,o,a)-l,d=Math.max(r,o,a)+l;return!(th||ed)},ln=function(t,e,n,r,i,a,s,o){var l=[];!function(t,e,n,r,i){var a,s,o,l,c,h,u,d;0===t&&(t=1e-5),o=-27*(r/=t)+(e/=t)*(9*(n/=t)-e*e*2),a=(s=(3*n-e*e)/9)*s*s+(o/=54)*o,i[1]=0,u=e/3,a>0?(c=(c=o+Math.sqrt(a))<0?-Math.pow(-c,1/3):Math.pow(c,1/3),h=(h=o-Math.sqrt(a))<0?-Math.pow(-h,1/3):Math.pow(h,1/3),i[0]=-u+c+h,u+=(c+h)/2,i[4]=i[2]=-u,u=Math.sqrt(3)*(-h+c)/2,i[3]=u,i[5]=-u):(i[5]=i[3]=0,0===a?(d=o<0?-Math.pow(-o,1/3):Math.pow(o,1/3),i[0]=2*d-u,i[4]=i[2]=-(d+u)):(l=(s=-s)*s*s,l=Math.acos(o/Math.sqrt(l)),d=2*Math.sqrt(s),i[0]=-u+d*Math.cos(l/3),i[2]=-u+d*Math.cos((l+2*Math.PI)/3),i[4]=-u+d*Math.cos((l+4*Math.PI)/3)))}(1*n*n-4*n*i+2*n*s+4*i*i-4*i*s+s*s+r*r-4*r*a+2*r*o+4*a*a-4*a*o+o*o,9*n*i-3*n*n-3*n*s-6*i*i+3*i*s+9*r*a-3*r*r-3*r*o-6*a*a+3*a*o,3*n*n-6*n*i+n*s-n*t+2*i*i+2*i*t-s*t+3*r*r-6*r*a+r*o-r*e+2*a*a+2*a*e-o*e,1*n*i-n*n+n*t-i*t+r*a-r*r+r*e-a*e,l);for(var c=[],h=0;h<6;h+=2)Math.abs(l[h+1])<1e-7&&l[h]>=0&&l[h]<=1&&c.push(l[h]);c.push(1),c.push(0);for(var u,d,p,g=-1,f=0;f=0?pl?(t-i)*(t-i)+(e-a)*(e-a):c-u},hn=function(t,e,n){for(var r,i,a,s,o=0,l=0;l=t&&t>=a||r<=t&&t<=a))continue;(t-r)/(a-r)*(s-i)+i>e&&o++}return o%2!=0},un=function(t,e,n,r,i,a,s,o,l){var c,h=new Array(n.length);null!=o[0]?(c=Math.atan(o[1]/o[0]),o[0]<0?c+=Math.PI/2:c=-c-Math.PI/2):c=o;for(var u,d=Math.cos(-c),p=Math.sin(-c),g=0;g0){var f=pn(h,-l);u=dn(f)}else u=h;return hn(t,e,u)},dn=function(t){for(var e,n,r,i,a,s,o,l,c=new Array(t.length/2),h=0;h=0&&g<=1&&m.push(g),f>=0&&f<=1&&m.push(f),0===m.length)return[];var y=m[0]*o[0]+t,v=m[0]*o[1]+e;return m.length>1?m[0]==m[1]?[y,v]:[y,v,m[1]*o[0]+t,m[1]*o[1]+e]:[y,v]},mn=function(t,e,n){return e<=t&&t<=n||n<=t&&t<=e?t:t<=e&&e<=n||n<=e&&e<=t?e:n},yn=function(t,e,n,r,i,a,s,o,l){var c=t-i,h=n-t,u=s-i,d=e-a,p=r-e,g=o-a,f=u*d-g*c,m=h*d-p*c,y=g*h-u*p;if(0!==y){var v=f/y,x=m/y,b=-.001;return b<=v&&v<=1.001&&b<=x&&x<=1.001||l?[t+v*h,e+v*p]:[]}return 0===f||0===m?mn(t,n,s)===s?[s,o]:mn(t,n,i)===i?[i,a]:mn(i,s,n)===n?[n,r]:[]:[]},vn=function(t,e,n,r,i,a,s,o){var l,c,h,u,d,p,g=[],f=new Array(n.length),m=!0;if(null==a&&(m=!1),m){for(var y=0;y0){var v=pn(f,-o);c=dn(v)}else c=f}else c=n;for(var x=0;xc&&(c=e)},u=function(t){return l[t]},d=0;d0?b.edgesTo(x)[0]:x.edgesTo(b)[0];var w=r(v);x=x.id(),c[x]>c[f]+w&&(c[x]=c[f]+w,d.nodes.indexOf(x)<0?d.push(x):d.updateItem(x),l[x]=0,n[x]=[]),c[x]==c[f]+w&&(l[x]=l[x]+l[f],n[x].push(f))}else for(var k=0;k0;){for(var S=e.pop(),C=0;C0&&s.push(n[o]);0!==s.length&&i.push(r.collection(s))}return i}(h,l,e,r);return x=function(t){for(var e=0;e5&&void 0!==arguments[5]?arguments[5]:Gn,s=r,o=0;o=2?Kn(t,e,n,0,jn,Hn):Kn(t,e,n,0,qn)},squaredEuclidean:function(t,e,n){return Kn(t,e,n,0,jn)},manhattan:function(t,e,n){return Kn(t,e,n,0,qn)},max:function(t,e,n){return Kn(t,e,n,-1/0,Xn)}};function Jn(t,e,n,r,i,a){var s;return s=H(t)?t:Qn[t]||Qn.euclidean,0===e&&H(t)?s(i,a):s(e,n,r,i,a)}Qn["squared-euclidean"]=Qn.squaredEuclidean,Qn.squaredeuclidean=Qn.squaredEuclidean;var tr=le({k:2,m:2,sensitivityThreshold:1e-4,distance:"euclidean",maxIterations:10,attributes:[],testMode:!1,testCentroids:null}),er=function(t){return tr(t)},nr=function(t,e,n,r,i){var a="kMedoids"!==i?function(t){return n[t]}:function(t){return r[t](n)},s=n,o=e;return Jn(t,r.length,a,(function(t){return r[t](e)}),s,o)},rr=function(t,e,n){for(var r=n.length,i=new Array(r),a=new Array(r),s=new Array(e),o=null,l=0;ln)return!1;return!0},lr=function(t,e,n){for(var r=0;ri&&(i=e[l][c],a=c);s[a].push(t[l])}for(var h=0;h=i.threshold||"dendrogram"===i.mode&&1===t.length)return!1;var p,g=e[s],f=e[r[s]];p="dendrogram"===i.mode?{left:g,right:f,key:g.key}:{value:g.value.concat(f.value),key:g.key},t[g.index]=p,t.splice(f.index,1),e[g.key]=p;for(var m=0;mn[f.key][y.key]&&(a=n[f.key][y.key])):"max"===i.linkage?(a=n[g.key][y.key],n[g.key][y.key]s&&(a=l,s=e[i*t+l])}a>0&&r.push(a)}for(var c=0;c1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.length,r=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],i=!(arguments.length>5&&void 0!==arguments[5])||arguments[5];arguments.length>3&&void 0!==arguments[3]&&!arguments[3]?(n0&&t.splice(0,e)):t=t.slice(e,n);for(var a=0,s=t.length-1;s>=0;s--){var o=t[s];i?isFinite(o)||(t[s]=-1/0,a++):t.splice(s,1)}r&&t.sort((function(t,e){return t-e}));var l=t.length,c=Math.floor(l/2);return l%2!=0?t[c+1+a]:(t[c-1+a]+t[c+a])/2}(t):"mean"===e?function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.length,r=0,i=0,a=e;a1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.length,r=1/0,i=e;i1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.length,r=-1/0,i=e;i=S?(C=S,S=L,A=M):L>C&&(C=L);for(var N=0;N0?1:0;T[k%c.minIterations*e+$]=B,P+=B}if(P>0&&(k>=c.minIterations-1||k==c.maxIterations-1)){for(var F=0,W=0;W0&&r.push(i);return r}(e,a,s),Y=function(t,e,n){for(var r=Er(t,e,n),i=0;il&&(o=c,l=h)}n[i]=a[o]}return Er(t,e,n)}(e,r,Z),U={},G=0;G1)}}));var l=Object.keys(e).filter((function(t){return e[t].cutVertex})).map((function(e){return t.getElementById(e)}));return{cut:t.spawn(l),components:i}},Mr=function(){var t=this,e={},n=0,r=[],i=[],a=t.spawn(t),s=function(o){if(i.push(o),e[o]={index:n,low:n++,explored:!1},t.getElementById(o).connectedEdges().intersection(t).forEach((function(t){var n=t.target().id();n!==o&&(n in e||s(n),e[n].explored||(e[o].low=Math.min(e[o].low,e[n].low)))})),e[o].index===e[o].low){for(var l=t.spawn();;){var c=i.pop();if(l.merge(t.getElementById(c)),e[c].low=e[o].index,e[c].explored=!0,c===o)break}var h=l.edgesWith(l),u=l.merge(h);r.push(u),a=a.difference(u)}};return t.forEach((function(t){if(t.isNode()){var n=t.id();n in e||s(n)}})),{cut:a,components:r}},Nr={};[ve,Se,Ce,Le,Ne,Re,$e,An,Mn,In,Dn,Un,gr,kr,Cr,{hierholzer:function(t){if(!K(t)){var e=arguments;t={root:e[0],directed:e[1]}}var n,r,i,a=Ar(t),s=a.root,o=a.directed,l=this,c=!1;s&&(i=j(s)?this.filter(s)[0].id():s[0].id());var h={},u={};o?l.forEach((function(t){var e=t.id();if(t.isNode()){var i=t.indegree(!0),a=t.outdegree(!0),s=i-a,o=a-i;1==s?n?c=!0:n=e:1==o?r?c=!0:r=e:(o>1||s>1)&&(c=!0),h[e]=[],t.outgoers().forEach((function(t){t.isEdge()&&h[e].push(t.id())}))}else u[e]=[void 0,t.target().id()]})):l.forEach((function(t){var e=t.id();t.isNode()?(t.degree(!0)%2&&(n?r?c=!0:r=e:n=e),h[e]=[],t.connectedEdges().forEach((function(t){return h[e].push(t.id())}))):u[e]=[t.source().id(),t.target().id()]}));var d={found:!1,trail:void 0};if(c)return d;if(r&&n)if(o){if(i&&r!=i)return d;i=r}else{if(i&&r!=i&&n!=i)return d;i||(i=r)}else i||(i=l[0].id());var p=function(t){for(var e,n,r,i=t,a=[t];h[i].length;)e=h[i].shift(),n=u[e][0],i!=(r=u[e][1])?(h[r]=h[r].filter((function(t){return t!=e})),i=r):o||i==n||(h[n]=h[n].filter((function(t){return t!=e})),i=n),a.unshift(e),a.unshift(i);return a},g=[],f=[];for(f=p(i);1!=f.length;)0==h[f[0]].length?(g.unshift(l.getElementById(f.shift())),g.unshift(l.getElementById(f.shift()))):f=p(f.shift()).concat(f);for(var m in g.unshift(l.getElementById(f.shift())),h)if(h[m].length)return d;return d.found=!0,d.trail=this.spawn(g,!0),d}},{hopcroftTarjanBiconnected:Lr,htbc:Lr,htb:Lr,hopcroftTarjanBiconnectedComponents:Lr},{tarjanStronglyConnected:Mr,tsc:Mr,tscc:Mr,tarjanStronglyConnectedComponents:Mr}].forEach((function(t){vt(Nr,t)}));var Ir=function(t){if(!(this instanceof Ir))return new Ir(t);this.id="Thenable/1.0.7",this.state=0,this.fulfillValue=void 0,this.rejectReason=void 0,this.onFulfilled=[],this.onRejected=[],this.proxy={then:this.then.bind(this)},"function"==typeof t&&t.call(this,this.fulfill.bind(this),this.reject.bind(this))};Ir.prototype={fulfill:function(t){return Rr(this,1,"fulfillValue",t)},reject:function(t){return Rr(this,2,"rejectReason",t)},then:function(t,e){var n=this,r=new Ir;return n.onFulfilled.push(Pr(t,r,"fulfill")),n.onRejected.push(Pr(e,r,"reject")),Dr(n),r.proxy}};var Rr=function(t,e,n,r){return 0===t.state&&(t.state=e,t[n]=r,Dr(t)),t},Dr=function(t){1===t.state?Or(t,"onFulfilled",t.fulfillValue):2===t.state&&Or(t,"onRejected",t.rejectReason)},Or=function(t,e,n){if(0!==t[e].length){var r=t[e];t[e]=[];var i=function(){for(var t=0;t0:void 0}},clearQueue:function(){return function(){var t=this,e=void 0!==t.length?t:[t];if(!(this._private.cy||this).styleEnabled())return this;for(var n=0;n-1}}(),i=function(){if(Ii)return Ni;Ii=1;var t=Ea();return Ni=function(e,n){var r=this.__data__,i=t(r,e);return i<0?(++this.size,r.push([e,n])):r[i][1]=n,this},Ni}();function a(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1&&e%1==0&&e0&&this.spawn(r).updateStyle().emit("class"),e},addClass:function(t){return this.toggleClass(t,!0)},hasClass:function(t){var e=this[0];return null!=e&&e._private.classes.has(t)},toggleClass:function(t,e){X(t)||(t=t.match(/\S+/g)||[]);for(var n=this,r=void 0===e,i=[],a=0,s=n.length;a0&&this.spawn(i).updateStyle().emit("class"),n},removeClass:function(t){return this.toggleClass(t,!1)},flashClass:function(t,e){var n=this;if(null==e)e=250;else if(0===e)return n;return n.addClass(t),setTimeout((function(){n.removeClass(t)}),e),n}};as.className=as.classNames=as.classes;var ss={metaChar:"[\\!\\\"\\#\\$\\%\\&\\'\\(\\)\\*\\+\\,\\.\\/\\:\\;\\<\\=\\>\\?\\@\\[\\]\\^\\`\\{\\|\\}\\~]",comparatorOp:"=|\\!=|>|>=|<|<=|\\$=|\\^=|\\*=",boolOp:"\\?|\\!|\\^",string:"\"(?:\\\\\"|[^\"])*\"|'(?:\\\\'|[^'])*'",number:dt,meta:"degree|indegree|outdegree",separator:"\\s*,\\s*",descendant:"\\s+",child:"\\s+>\\s+",subject:"\\$",group:"node|edge|\\*",directedEdge:"\\s+->\\s+",undirectedEdge:"\\s+<->\\s+"};ss.variable="(?:[\\w-.]|(?:\\\\"+ss.metaChar+"))+",ss.className="(?:[\\w-]|(?:\\\\"+ss.metaChar+"))+",ss.value=ss.string+"|"+ss.number,ss.id=ss.variable,function(){var t,e,n;for(t=ss.comparatorOp.split("|"),n=0;n=0||"="!==e&&(ss.comparatorOp+="|\\!"+e)}();var os=20,ls=[{selector:":selected",matches:function(t){return t.selected()}},{selector:":unselected",matches:function(t){return!t.selected()}},{selector:":selectable",matches:function(t){return t.selectable()}},{selector:":unselectable",matches:function(t){return!t.selectable()}},{selector:":locked",matches:function(t){return t.locked()}},{selector:":unlocked",matches:function(t){return!t.locked()}},{selector:":visible",matches:function(t){return t.visible()}},{selector:":hidden",matches:function(t){return!t.visible()}},{selector:":transparent",matches:function(t){return t.transparent()}},{selector:":grabbed",matches:function(t){return t.grabbed()}},{selector:":free",matches:function(t){return!t.grabbed()}},{selector:":removed",matches:function(t){return t.removed()}},{selector:":inside",matches:function(t){return!t.removed()}},{selector:":grabbable",matches:function(t){return t.grabbable()}},{selector:":ungrabbable",matches:function(t){return!t.grabbable()}},{selector:":animated",matches:function(t){return t.animated()}},{selector:":unanimated",matches:function(t){return!t.animated()}},{selector:":parent",matches:function(t){return t.isParent()}},{selector:":childless",matches:function(t){return t.isChildless()}},{selector:":child",matches:function(t){return t.isChild()}},{selector:":orphan",matches:function(t){return t.isOrphan()}},{selector:":nonorphan",matches:function(t){return t.isChild()}},{selector:":compound",matches:function(t){return t.isNode()?t.isParent():t.source().isParent()||t.target().isParent()}},{selector:":loop",matches:function(t){return t.isLoop()}},{selector:":simple",matches:function(t){return t.isSimple()}},{selector:":active",matches:function(t){return t.active()}},{selector:":inactive",matches:function(t){return!t.active()}},{selector:":backgrounding",matches:function(t){return t.backgrounding()}},{selector:":nonbackgrounding",matches:function(t){return!t.backgrounding()}}].sort((function(t,e){return function(t,e){return-1*yt(t,e)}(t.selector,e.selector)})),cs=function(){for(var t,e={},n=0;n0&&c.edgeCount>0)return re("The selector `"+t+"` is invalid because it uses both a compound selector and an edge selector"),!1;if(c.edgeCount>1)return re("The selector `"+t+"` is invalid because it uses multiple edge selectors"),!1;1===c.edgeCount&&re("The selector `"+t+"` is deprecated. Edge selectors do not take effect on changes to source and target nodes after an edge is added, for performance reasons. Use a class or data selector on edges instead, updating the class or data of an edge when your app detects a change in source or target nodes.")}return!0},toString:function(){if(null!=this.toStringCache)return this.toStringCache;for(var t=function(t){return null==t?"":t},e=function(e){return j(e)?'"'+e+'"':t(e)},n=function(t){return" "+t+" "},r=function(i,a){return i.checks.reduce((function(s,o,l){return s+(a===i&&0===l?"$":"")+function(i,a){var s=i.type,o=i.value;switch(s){case 0:var l=t(o);return l.substring(0,l.length-1);case 3:var c=i.field,h=i.operator;return"["+c+n(t(h))+e(o)+"]";case 5:var u=i.operator,d=i.field;return"["+t(u)+d+"]";case 4:return"["+i.field+"]";case 6:var p=i.operator;return"[["+i.field+n(t(p))+e(o)+"]]";case 7:return o;case 8:return"#"+o;case 9:return"."+o;case 17:case 15:return r(i.parent,a)+n(">")+r(i.child,a);case 18:case 16:return r(i.ancestor,a)+" "+r(i.descendant,a);case 19:var g=r(i.left,a),f=r(i.subject,a),m=r(i.right,a);return g+(g.length>0?" ":"")+f+m;case os:return""}}(o,a)}),"")},i="",a=0;a1&&a=0&&(e=e.replace("!",""),h=!0),e.indexOf("@")>=0&&(e=e.replace("@",""),c=!0),(s||l||c)&&(i=s||o?""+t:"",a=""+n),c&&(t=i=i.toLowerCase(),n=a=a.toLowerCase()),e){case"*=":r=i.indexOf(a)>=0;break;case"$=":r=i.indexOf(a,i.length-a.length)>=0;break;case"^=":r=0===i.indexOf(a);break;case"=":r=t===n;break;case">":u=!0,r=t>n;break;case">=":u=!0,r=t>=n;break;case"<":u=!0,r=t0;){var c=i.shift();e(c),a.add(c.id()),s&&r(i,a,c)}return t}function Ls(t,e,n){if(n.isParent())for(var r=n._private.children,i=0;i1&&void 0!==arguments[1])||arguments[1],Ls)},Cs.forEachUp=function(t){return As(this,t,!(arguments.length>1&&void 0!==arguments[1])||arguments[1],Ms)},Cs.forEachUpAndDown=function(t){return As(this,t,!(arguments.length>1&&void 0!==arguments[1])||arguments[1],Ns)},Cs.ancestors=Cs.parents,(_s=Es={data:rs.data({field:"data",bindingEvent:"data",allowBinding:!0,allowSetting:!0,settingEvent:"data",settingTriggersEvent:!0,triggerFnName:"trigger",allowGetting:!0,immutableKeys:{id:!0,source:!0,target:!0,parent:!0},updateStyle:!0}),removeData:rs.removeData({field:"data",event:"data",triggerFnName:"trigger",triggerEvent:!0,immutableKeys:{id:!0,source:!0,target:!0,parent:!0},updateStyle:!0}),scratch:rs.data({field:"scratch",bindingEvent:"scratch",allowBinding:!0,allowSetting:!0,settingEvent:"scratch",settingTriggersEvent:!0,triggerFnName:"trigger",allowGetting:!0,updateStyle:!0}),removeScratch:rs.removeData({field:"scratch",event:"scratch",triggerFnName:"trigger",triggerEvent:!0,updateStyle:!0}),rscratch:rs.data({field:"rscratch",allowBinding:!1,allowSetting:!0,settingTriggersEvent:!1,allowGetting:!0}),removeRscratch:rs.removeData({field:"rscratch",triggerEvent:!1}),id:function(){var t=this[0];if(t)return t._private.data.id}}).attr=_s.data,_s.removeAttr=_s.removeData;var Is,Rs,Ds=Es,Os={};function Ps(t){return function(e){var n=this;if(void 0===e&&(e=!0),0!==n.length&&n.isNode()&&!n.removed()){for(var r=0,i=n[0],a=i._private.edges,s=0;se})),minIndegree:$s("indegree",(function(t,e){return te})),minOutdegree:$s("outdegree",(function(t,e){return te}))}),vt(Os,{totalDegree:function(t){for(var e=0,n=this.nodes(),r=0;r0,h=c;c&&(l=l[0]);var u=h?l.position():{x:0,y:0};return i={x:o.x-u.x,y:o.y-u.y},void 0===t?i:i[t]}for(var d=0;d0,m=f;f&&(g=g[0]);var y=m?g.position():{x:0,y:0};void 0!==e?p.position(t,e+y[t]):void 0!==i&&p.position({x:i.x+y.x,y:i.y+y.y})}}else if(!a)return;return this}},Is.modelPosition=Is.point=Is.position,Is.modelPositions=Is.points=Is.positions,Is.renderedPoint=Is.renderedPosition,Is.relativePoint=Is.relativePosition;var Ws,zs,Zs=Rs;Ws=zs={},zs.renderedBoundingBox=function(t){var e=this.boundingBox(t),n=this.cy(),r=n.zoom(),i=n.pan(),a=e.x1*r+i.x,s=e.x2*r+i.x,o=e.y1*r+i.y,l=e.y2*r+i.y;return{x1:a,x2:s,y1:o,y2:l,w:s-a,h:l-o}},zs.dirtyCompoundBoundsCache=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this.cy();return e.styleEnabled()&&e.hasCompoundNodes()?(this.forEachUp((function(e){if(e.isParent()){var n=e._private;n.compoundBoundsClean=!1,n.bbCache=null,t||e.emitAndNotify("bounds")}})),this):this},zs.updateCompoundBounds=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],e=this.cy();if(!e.styleEnabled()||!e.hasCompoundNodes())return this;if(!t&&e.batching())return this;function n(t){if(t.isParent()){var e=t._private,n=t.children(),r="include"===t.pstyle("compound-sizing-wrt-labels").value,i={width:{val:t.pstyle("min-width").pfValue,left:t.pstyle("min-width-bias-left"),right:t.pstyle("min-width-bias-right")},height:{val:t.pstyle("min-height").pfValue,top:t.pstyle("min-height-bias-top"),bottom:t.pstyle("min-height-bias-bottom")}},a=n.boundingBox({includeLabels:r,includeOverlays:!1,useCache:!1}),s=e.position;0!==a.w&&0!==a.h||((a={w:t.pstyle("width").pfValue,h:t.pstyle("height").pfValue}).x1=s.x-a.w/2,a.x2=s.x+a.w/2,a.y1=s.y-a.h/2,a.y2=s.y+a.h/2);var o=i.width.left.value;"px"===i.width.left.units&&i.width.val>0&&(o=100*o/i.width.val);var l=i.width.right.value;"px"===i.width.right.units&&i.width.val>0&&(l=100*l/i.width.val);var c=i.height.top.value;"px"===i.height.top.units&&i.height.val>0&&(c=100*c/i.height.val);var h=i.height.bottom.value;"px"===i.height.bottom.units&&i.height.val>0&&(h=100*h/i.height.val);var u=y(i.width.val-a.w,o,l),d=u.biasDiff,p=u.biasComplementDiff,g=y(i.height.val-a.h,c,h),f=g.biasDiff,m=g.biasComplementDiff;e.autoPadding=function(t,e,n,r){if("%"!==n.units)return"px"===n.units?n.pfValue:0;switch(r){case"width":return t>0?n.pfValue*t:0;case"height":return e>0?n.pfValue*e:0;case"average":return t>0&&e>0?n.pfValue*(t+e)/2:0;case"min":return t>0&&e>0?t>e?n.pfValue*e:n.pfValue*t:0;case"max":return t>0&&e>0?t>e?n.pfValue*t:n.pfValue*e:0;default:return 0}}(a.w,a.h,t.pstyle("padding"),t.pstyle("padding-relative-to").value),e.autoWidth=Math.max(a.w,i.width.val),s.x=(-d+a.x1+a.x2+p)/2,e.autoHeight=Math.max(a.h,i.height.val),s.y=(-f+a.y1+a.y2+m)/2}function y(t,e,n){var r=0,i=0,a=e+n;return t>0&&a>0&&(r=e/a*t,i=n/a*t),{biasDiff:r,biasComplementDiff:i}}}for(var r=0;rt.x2?r:t.x2,t.y1=nt.y2?i:t.y2,t.w=t.x2-t.x1,t.h=t.y2-t.y1)},Gs=function(t,e){return null==e?t:Us(t,e.x1,e.y1,e.x2,e.y2)},Vs=function(t,e,n){return ue(t,e,n)},qs=function(t,e,n){if(!e.cy().headless()){var r,i,a=e._private,s=a.rstyle,o=s.arrowWidth/2;if("none"!==e.pstyle(n+"-arrow-shape").value){"source"===n?(r=s.srcX,i=s.srcY):"target"===n?(r=s.tgtX,i=s.tgtY):(r=s.midX,i=s.midY);var l=a.arrowBounds=a.arrowBounds||{},c=l[n]=l[n]||{};c.x1=r-o,c.y1=i-o,c.x2=r+o,c.y2=i+o,c.w=c.x2-c.x1,c.h=c.y2-c.y1,Je(c,1),Us(t,c.x1,c.y1,c.x2,c.y2)}}},js=function(t,e,n){if(!e.cy().headless()){var r;r=n?n+"-":"";var i=e._private,a=i.rstyle;if(e.pstyle(r+"label").strValue){var s,o,l,c,h=e.pstyle("text-halign"),u=e.pstyle("text-valign"),d=Vs(a,"labelWidth",n),p=Vs(a,"labelHeight",n),g=Vs(a,"labelX",n),f=Vs(a,"labelY",n),m=e.pstyle(r+"text-margin-x").pfValue,y=e.pstyle(r+"text-margin-y").pfValue,v=e.isEdge(),x=e.pstyle(r+"text-rotation"),b=e.pstyle("text-outline-width").pfValue,w=e.pstyle("text-border-width").pfValue/2,k=e.pstyle("text-background-padding").pfValue,T=p,_=d,E=_/2,S=T/2;if(v)s=g-E,o=g+E,l=f-S,c=f+S;else{switch(h.value){case"left":s=g-_,o=g;break;case"center":s=g-E,o=g+E;break;case"right":s=g,o=g+_}switch(u.value){case"top":l=f-T,c=f;break;case"center":l=f-S,c=f+S;break;case"bottom":l=f,c=f+T}}var C=m-Math.max(b,w)-k-2,A=m+Math.max(b,w)+k+2,L=y-Math.max(b,w)-k-2,M=y+Math.max(b,w)+k+2;s+=C,o+=A,l+=L,c+=M;var N=n||"main",I=i.labelBounds,R=I[N]=I[N]||{};R.x1=s,R.y1=l,R.x2=o,R.y2=c,R.w=o-s,R.h=c-l,R.leftPad=C,R.rightPad=A,R.topPad=L,R.botPad=M;var D=v&&"autorotate"===x.strValue,O=null!=x.pfValue&&0!==x.pfValue;if(D||O){var P=D?Vs(i.rstyle,"labelAngle",n):x.pfValue,$=Math.cos(P),B=Math.sin(P),F=(s+o)/2,W=(l+c)/2;if(!v){switch(h.value){case"left":F=o;break;case"right":F=s}switch(u.value){case"top":W=c;break;case"bottom":W=l}}var z=function(t,e){return{x:(t-=F)*$-(e-=W)*B+F,y:t*B+e*$+W}},Z=z(s,l),Y=z(s,c),U=z(o,l),G=z(o,c);s=Math.min(Z.x,Y.x,U.x,G.x),o=Math.max(Z.x,Y.x,U.x,G.x),l=Math.min(Z.y,Y.y,U.y,G.y),c=Math.max(Z.y,Y.y,U.y,G.y)}var V=N+"Rot",q=I[V]=I[V]||{};q.x1=s,q.y1=l,q.x2=o,q.y2=c,q.w=o-s,q.h=c-l,Us(t,s,l,o,c),Us(i.labelBounds.all,s,l,o,c)}return t}},Hs=function(t){var e=0,n=function(t){return(t?1:0)<0&&a>0){var s=e.pstyle("outline-offset").value,o=e.pstyle("shape").value,l=a+s,c=(t.w+2*l)/t.w,h=(t.h+2*l)/t.h,u=0;["diamond","pentagon","round-triangle"].includes(o)?(c=(t.w+2.4*l)/t.w,u=-l/3.6):["concave-hexagon","rhomboid","right-rhomboid"].includes(o)?c=(t.w+2.4*l)/t.w:"star"===o?(c=(t.w+2.8*l)/t.w,h=(t.h+2.6*l)/t.h,u=-l/3.8):"triangle"===o?(c=(t.w+2.8*l)/t.w,h=(t.h+2.4*l)/t.h,u=-l/1.4):"vee"===o&&(c=(t.w+4.4*l)/t.w,h=(t.h+3.8*l)/t.h,u=.5*-l);var d=t.h*h-t.h,p=t.w*c-t.w;if(tn(t,[Math.ceil(d/2),Math.ceil(p/2)]),0!==u){var g=(r=u,{x1:(n=t).x1+0,x2:n.x2+0,y1:n.y1+r,y2:n.y2+r,w:n.w,h:n.h});Ke(t,g)}}}}(d,t)}else if(f&&e.includeEdges)if(h&&!u){var C=t.pstyle("curve-style").strValue;if(n=Math.min(m.srcX,m.midX,m.tgtX),r=Math.max(m.srcX,m.midX,m.tgtX),i=Math.min(m.srcY,m.midY,m.tgtY),a=Math.max(m.srcY,m.midY,m.tgtY),Us(d,n-=T,i-=T,r+=T,a+=T),"haystack"===C){var A=m.haystackPts;if(A&&2===A.length){if(n=A[0].x,i=A[0].y,n>(r=A[1].x)){var L=n;n=r,r=L}if(i>(a=A[1].y)){var M=i;i=a,a=M}Us(d,n-T,i-T,r+T,a+T)}}else if("bezier"===C||"unbundled-bezier"===C||C.endsWith("segments")||C.endsWith("taxi")){var N;switch(C){case"bezier":case"unbundled-bezier":N=m.bezierPts;break;case"segments":case"taxi":case"round-segments":case"round-taxi":N=m.linePts}if(null!=N)for(var I=0;I(r=O.x)){var P=n;n=r,r=P}if((i=D.y)>(a=O.y)){var $=i;i=a,a=$}Us(d,n-=T,i-=T,r+=T,a+=T)}if(h&&e.includeEdges&&f&&(qs(d,t,"mid-source"),qs(d,t,"mid-target"),qs(d,t,"source"),qs(d,t,"target")),h&&"yes"===t.pstyle("ghost").value){var B=t.pstyle("ghost-offset-x").pfValue,F=t.pstyle("ghost-offset-y").pfValue;Us(d,d.x1+B,d.y1+F,d.x2+B,d.y2+F)}var W=p.bodyBounds=p.bodyBounds||{};en(W,d),tn(W,y),Je(W,1),h&&(n=d.x1,r=d.x2,i=d.y1,a=d.y2,Us(d,n-k,i-k,r+k,a+k));var z=p.overlayBounds=p.overlayBounds||{};en(z,d),tn(z,y),Je(z,1);var Z=p.labelBounds=p.labelBounds||{};null!=Z.all?((l=Z.all).x1=1/0,l.y1=1/0,l.x2=-1/0,l.y2=-1/0,l.w=0,l.h=0):Z.all=Xe(),h&&e.includeLabels&&(e.includeMainLabels&&js(d,t,null),f&&(e.includeSourceLabels&&js(d,t,"source"),e.includeTargetLabels&&js(d,t,"target")))}return d.x1=Ys(d.x1),d.y1=Ys(d.y1),d.x2=Ys(d.x2),d.y2=Ys(d.y2),d.w=Ys(d.x2-d.x1),d.h=Ys(d.y2-d.y1),d.w>0&&d.h>0&&x&&(tn(d,y),Je(d,1)),d}(t,Qs),r.bbCache=n,r.bbCachePosKey=Xs(t)):n=r.bbCache,!a){var s=t.isNode();n=Xe(),(e.includeNodes&&s||e.includeEdges&&!s)&&(e.includeOverlays?Gs(n,r.overlayBounds):Gs(n,r.bodyBounds)),e.includeLabels&&(e.includeMainLabels&&(!i||e.includeSourceLabels&&e.includeTargetLabels)?Gs(n,r.labelBounds.all):(e.includeMainLabels&&Gs(n,r.labelBounds.mainRot),e.includeSourceLabels&&Gs(n,r.labelBounds.sourceRot),e.includeTargetLabels&&Gs(n,r.labelBounds.targetRot))),n.w=n.x2-n.x1,n.h=n.y2-n.y1}return n},Qs={includeNodes:!0,includeEdges:!0,includeLabels:!0,includeMainLabels:!0,includeSourceLabels:!0,includeTargetLabels:!0,includeOverlays:!0,includeUnderlays:!0,includeOutlines:!0,useCache:!0},Js=Hs(Qs),to=le(Qs);zs.boundingBox=function(t){var e,n=void 0===t||void 0===t.useCache||!0===t.useCache,r=ot((function(t){var e=t._private;return null==e.bbCache||e.styleDirty||e.bbCachePosKey!==Xs(t)}),(function(t){return t.id()}));if(n&&1===this.length&&!r(this[0]))t=void 0===t?Qs:to(t),e=Ks(this[0],t);else{e=Xe();var i=to(t=t||Qs),a=this,s=a.cy().styleEnabled();this.edges().forEach(r),this.nodes().forEach(r),s&&this.recalculateRenderedStyle(n),this.updateCompoundBounds(!n);for(var o=0;o0&&void 0!==arguments[0]?arguments[0]:mo,e=arguments.length>1?arguments[1]:void 0,n=0;n=0;o--)s(o);return this},vo.removeAllListeners=function(){return this.removeListener("*")},vo.emit=vo.trigger=function(t,e,n){var r=this.listeners,i=r.length;return this.emitting++,X(e)||(e=[e]),function(t,e,n){if("event"!==q(n))if(K(n))e(t,bo(t,n));else for(var r=X(n)?n:n.split(/\s+/),i=0;i1&&!r){var i=this.length-1,a=this[i],s=a._private.data.id;this[i]=void 0,this[t]=a,n.set(s,{ele:a,index:t})}return this.length--,this},unmergeOne:function(t){t=t[0];var e=this._private,n=t._private.data.id,r=e.map.get(n);if(!r)return this;var i=r.index;return this.unmergeAt(i),this},unmerge:function(t){var e=this._private.cy;if(!t)return this;if(t&&j(t)){var n=t;t=e.mutableElements().filter(n)}for(var r=0;r=0;e--)t(this[e])&&this.unmergeAt(e);return this},map:function(t,e){for(var n=[],r=this,i=0;ir&&(r=o,n=s)}return{value:r,ele:n}},min:function(t,e){for(var n,r=1/0,i=this,a=0;a=0&&i1&&void 0!==arguments[1])||arguments[1],n=this[0],r=n.cy();if(r.styleEnabled()&&n){n._private.styleDirty&&(n._private.styleDirty=!1,r.style().apply(n));var i=n._private.style[t];return null!=i?i:e?r.style().getDefaultProperty(t):null}},numericStyle:function(t){var e=this[0];if(e.cy().styleEnabled()&&e){var n=e.pstyle(t);return void 0!==n.pfValue?n.pfValue:n.value}},numericStyleUnits:function(t){var e=this[0];if(e.cy().styleEnabled())return e?e.pstyle(t).units:void 0},renderedStyle:function(t){var e=this.cy();if(!e.styleEnabled())return this;var n=this[0];return n?e.style().getRenderedStyle(n,t):void 0},style:function(t,e){var n=this.cy();if(!n.styleEnabled())return this;var r=n.style();if(K(t)){var i=t;r.applyBypass(this,i,!1),this.emitAndNotify("style")}else if(j(t)){if(void 0===e){var a=this[0];return a?r.getStylePropertyValue(a,t):void 0}r.applyBypass(this,t,e,!1),this.emitAndNotify("style")}else if(void 0===t){var s=this[0];return s?r.getRawStyle(s):void 0}return this},removeStyle:function(t){var e=this.cy();if(!e.styleEnabled())return this;var n=e.style(),r=this;if(void 0===t)for(var i=0;i0&&e.push(h[0]),e.push(o[0])}return this.spawn(e,!0).filter(t)}),"neighborhood"),closedNeighborhood:function(t){return this.neighborhood().add(this).filter(t)},openNeighborhood:function(t){return this.neighborhood(t)}}),Go.neighbourhood=Go.neighborhood,Go.closedNeighbourhood=Go.closedNeighborhood,Go.openNeighbourhood=Go.openNeighborhood,vt(Go,{source:Ss((function(t){var e,n=this[0];return n&&(e=n._private.source||n.cy().collection()),e&&t?e.filter(t):e}),"source"),target:Ss((function(t){var e,n=this[0];return n&&(e=n._private.target||n.cy().collection()),e&&t?e.filter(t):e}),"target"),sources:Ho({attr:"source"}),targets:Ho({attr:"target"})}),vt(Go,{edgesWith:Ss(Xo(),"edgesWith"),edgesTo:Ss(Xo({thisIsSrc:!0}),"edgesTo")}),vt(Go,{connectedEdges:Ss((function(t){for(var e=[],n=0;n0);return a},component:function(){var t=this[0];return t.cy().mutableElements().components(t)[0]}}),Go.componentsOf=Go.components;var Qo=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(void 0!==t){var i=new pe,a=!1;if(e){if(e.length>0&&K(e[0])&&!et(e[0])){a=!0;for(var s=[],o=new fe,l=0,c=e.length;l0&&void 0!==arguments[0])||arguments[0],r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=this,a=i.cy(),s=a._private,o=[],l=[],c=0,h=i.length;c0){for(var D=t.length===i.length?i:new Qo(a,t),O=0;O0&&void 0!==arguments[0])||arguments[0],e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=this,r=[],i={},a=n._private.cy;function s(t){var n=i[t.id()];e&&t.removed()||n||(i[t.id()]=!0,t.isNode()?(r.push(t),function(t){for(var e=t._private.edges,n=0;n0&&(t?T.emitAndNotify("remove"):e&&T.emit("remove"));for(var _=0;_=.001?function(e,r){for(var i=0;i<4;++i){var a=d(r,t,n);if(0===a)return r;r-=(u(r,t,n)-e)/a}return r}(e,s):0===l?s:function(e,r,i){var a,s,o=0;do{(a=u(s=r+(i-r)/2,t,n)-e)>0?i=s:r=s}while(Math.abs(a)>1e-7&&++o<10);return s}(e,r,r+i)}(a),e,r)};g.getControlPoints=function(){return[{x:t,y:e},{x:n,y:r}]};var f="generateBezier("+[t,e,n,r]+")";return g.toString=function(){return f},g}var nl=function(){function t(t){return-t.tension*t.x-t.friction*t.v}function e(e,n,r){var i={x:e.x+r.dx*n,v:e.v+r.dv*n,tension:e.tension,friction:e.friction};return{dx:i.v,dv:t(i)}}function n(n,r){var i={dx:n.v,dv:t(n)},a=e(n,.5*r,i),s=e(n,.5*r,a),o=e(n,r,s),l=1/6*(i.dx+2*(a.dx+s.dx)+o.dx),c=1/6*(i.dv+2*(a.dv+s.dv)+o.dv);return n.x=n.x+l*r,n.v=n.v+c*r,n}return function t(e,r,i){var a,s,o,l={x:-1,v:0,tension:null,friction:null},c=[0],h=0,u=1e-4;for(e=parseFloat(e)||500,r=parseFloat(r)||20,i=i||null,l.tension=e,l.friction=r,s=(a=null!==i)?(h=t(e,r))/i*.016:.016;o=n(o||l,s),c.push(1+o.x),h+=16,Math.abs(o.x)>u&&Math.abs(o.v)>u;);return a?function(t){return c[t*(c.length-1)|0]}:h}}(),rl=function(t,e,n,r){var i=el(t,e,n,r);return function(t,e,n){return t+(e-t)*i(n)}},il={linear:function(t,e,n){return t+(e-t)*n},ease:rl(.25,.1,.25,1),"ease-in":rl(.42,0,1,1),"ease-out":rl(0,0,.58,1),"ease-in-out":rl(.42,0,.58,1),"ease-in-sine":rl(.47,0,.745,.715),"ease-out-sine":rl(.39,.575,.565,1),"ease-in-out-sine":rl(.445,.05,.55,.95),"ease-in-quad":rl(.55,.085,.68,.53),"ease-out-quad":rl(.25,.46,.45,.94),"ease-in-out-quad":rl(.455,.03,.515,.955),"ease-in-cubic":rl(.55,.055,.675,.19),"ease-out-cubic":rl(.215,.61,.355,1),"ease-in-out-cubic":rl(.645,.045,.355,1),"ease-in-quart":rl(.895,.03,.685,.22),"ease-out-quart":rl(.165,.84,.44,1),"ease-in-out-quart":rl(.77,0,.175,1),"ease-in-quint":rl(.755,.05,.855,.06),"ease-out-quint":rl(.23,1,.32,1),"ease-in-out-quint":rl(.86,0,.07,1),"ease-in-expo":rl(.95,.05,.795,.035),"ease-out-expo":rl(.19,1,.22,1),"ease-in-out-expo":rl(1,0,0,1),"ease-in-circ":rl(.6,.04,.98,.335),"ease-out-circ":rl(.075,.82,.165,1),"ease-in-out-circ":rl(.785,.135,.15,.86),spring:function(t,e,n){if(0===n)return il.linear;var r=nl(t,e,n);return function(t,e,n){return t+(e-t)*r(n)}},"cubic-bezier":rl};function al(t,e,n,r,i){if(1===r)return n;if(e===n)return n;var a=i(e,n,r);return null==t||((t.roundValue||t.color)&&(a=Math.round(a)),void 0!==t.min&&(a=Math.max(a,t.min)),void 0!==t.max&&(a=Math.min(a,t.max))),a}function sl(t,e){return null!=t.pfValue||null!=t.value?null==t.pfValue||null!=e&&"%"===e.type.units?t.value:t.pfValue:t}function ol(t,e,n,r,i){var a=null!=i?i.type:null;n<0?n=0:n>1&&(n=1);var s=sl(t,i),o=sl(e,i);if(Q(s)&&Q(o))return al(a,s,o,n,r);if(X(s)&&X(o)){for(var l=[],c=0;c0?("spring"===u&&d.push(s.duration),s.easingImpl=il[u].apply(null,d)):s.easingImpl=il[u]}var p,g=s.easingImpl;if(p=0===s.duration?1:(n-l)/s.duration,s.applying&&(p=s.progress),p<0?p=0:p>1&&(p=1),null==s.delay){var f=s.startPosition,m=s.position;if(m&&i&&!t.locked()){var y={};cl(f.x,m.x)&&(y.x=ol(f.x,m.x,p,g)),cl(f.y,m.y)&&(y.y=ol(f.y,m.y,p,g)),t.position(y)}var v=s.startPan,x=s.pan,b=a.pan,w=null!=x&&r;w&&(cl(v.x,x.x)&&(b.x=ol(v.x,x.x,p,g)),cl(v.y,x.y)&&(b.y=ol(v.y,x.y,p,g)),t.emit("pan"));var k=s.startZoom,T=s.zoom,_=null!=T&&r;_&&(cl(k,T)&&(a.zoom=He(a.minZoom,ol(k,T,p,g),a.maxZoom)),t.emit("zoom")),(w||_)&&t.emit("viewport");var E=s.style;if(E&&E.length>0&&i){for(var S=0;S=0;e--)(0,t[e])();t.splice(0,t.length)},h=a.length-1;h>=0;h--){var u=a[h],d=u._private;d.stopped?(a.splice(h,1),d.hooked=!1,d.playing=!1,d.started=!1,c(d.frames)):(d.playing||d.applying)&&(d.playing&&d.applying&&(d.applying=!1),d.started||hl(0,u,t),ll(e,u,t,n),d.applying&&(d.applying=!1),c(d.frames),null!=d.step&&d.step(t),u.completed()&&(a.splice(h,1),d.hooked=!1,d.playing=!1,d.started=!1,c(d.completes)),o=!0)}return n||0!==a.length||0!==s.length||r.push(e),o}for(var a=!1,s=0;s0?e.notify("draw",n):e.notify("draw")),n.unmerge(r),e.emit("step")}var dl={animate:rs.animate(),animation:rs.animation(),animated:rs.animated(),clearQueue:rs.clearQueue(),delay:rs.delay(),delayAnimation:rs.delayAnimation(),stop:rs.stop(),addToAnimationPool:function(t){this.styleEnabled()&&this._private.aniEles.merge(t)},stopAnimationLoop:function(){this._private.animationsRunning=!1},startAnimationLoop:function(){var t=this;if(t._private.animationsRunning=!0,t.styleEnabled()){var e=t.renderer();e&&e.beforeRender?e.beforeRender((function(e,n){ul(n,t)}),e.beforeRenderPriorities.animations):function e(){t._private.animationsRunning&&Dt((function(n){ul(n,t),e()}))}()}}},pl={qualifierCompare:function(t,e){return null==t||null==e?null==t&&null==e:t.sameText(e)},eventMatches:function(t,e,n){var r=e.qualifier;return null==r||t!==n.target&&et(n.target)&&r.matches(n.target)},addEventFields:function(t,e){e.cy=t,e.target=t},callbackContext:function(t,e,n){return null!=e.qualifier?n.target:t}},gl=function(t){return j(t)?new ws(t):t},fl={createEmitter:function(){var t=this._private;return t.emitter||(t.emitter=new yo(pl,this)),this},emitter:function(){return this._private.emitter},on:function(t,e,n){return this.emitter().on(t,gl(e),n),this},removeListener:function(t,e,n){return this.emitter().removeListener(t,gl(e),n),this},removeAllListeners:function(){return this.emitter().removeAllListeners(),this},one:function(t,e,n){return this.emitter().one(t,gl(e),n),this},once:function(t,e,n){return this.emitter().one(t,gl(e),n),this},emit:function(t,e){return this.emitter().emit(t,e),this},emitAndNotify:function(t,e){return this.emit(t),this.notify(t,e),this}};rs.eventAliasesOn(fl);var ml={png:function(t){return t=t||{},this._private.renderer.png(t)},jpg:function(t){var e=this._private.renderer;return(t=t||{}).bg=t.bg||"#fff",e.jpg(t)}};ml.jpeg=ml.jpg;var yl={layout:function(t){var e=this;if(null!=t)if(null!=t.name){var n,r=t.name,i=e.extension("layout",r);if(null!=i)return n=j(t.eles)?e.$(t.eles):null!=t.eles?t.eles:e.$(),new i(vt({},t,{cy:e,eles:n}));ee("No such layout `"+r+"` found. Did you forget to import it and `cytoscape.use()` it?")}else ee("A `name` must be specified to make a layout");else ee("Layout options must be specified to make a layout")}};yl.createLayout=yl.makeLayout=yl.layout;var vl={notify:function(t,e){var n=this._private;if(this.batching()){n.batchNotifications=n.batchNotifications||{};var r=n.batchNotifications[t]=n.batchNotifications[t]||this.collection();null!=e&&r.merge(e)}else if(n.notificationsEnabled){var i=this.renderer();!this.destroyed()&&i&&i.notify(t,e)}},notifications:function(t){var e=this._private;return void 0===t?e.notificationsEnabled:(e.notificationsEnabled=!!t,this)},noNotifications:function(t){this.notifications(!1),t(),this.notifications(!0)},batching:function(){return this._private.batchCount>0},startBatch:function(){var t=this._private;return null==t.batchCount&&(t.batchCount=0),0===t.batchCount&&(t.batchStyleEles=this.collection(),t.batchNotifications={}),t.batchCount++,this},endBatch:function(){var t=this._private;if(0===t.batchCount)return this;if(t.batchCount--,0===t.batchCount){t.batchStyleEles.updateStyle();var e=this.renderer();Object.keys(t.batchNotifications).forEach((function(n){var r=t.batchNotifications[n];r.empty()?e.notify(n):e.notify(n,r)}))}return this},batch:function(t){return this.startBatch(),t(),this.endBatch(),this},batchData:function(t){var e=this;return this.batch((function(){for(var n=Object.keys(t),r=0;r0;)e.removeChild(e.childNodes[0]);t._private.renderer=null,t.mutableElements().forEach((function(t){var e=t._private;e.rscratch={},e.rstyle={},e.animation.current=[],e.animation.queue=[]}))},onRender:function(t){return this.on("render",t)},offRender:function(t){return this.off("render",t)}};bl.invalidateDimensions=bl.resize;var wl={collection:function(t,e){return j(t)?this.$(t):tt(t)?t.collection():X(t)?(e||(e={}),new Qo(this,t,e.unique,e.removed)):new Qo(this)},nodes:function(t){var e=this.$((function(t){return t.isNode()}));return t?e.filter(t):e},edges:function(t){var e=this.$((function(t){return t.isEdge()}));return t?e.filter(t):e},$:function(t){var e=this._private.elements;return t?e.filter(t):e.spawnSelf()},mutableElements:function(){return this._private.elements}};wl.elements=wl.filter=wl.$;var kl={},Tl="t";kl.apply=function(t){for(var e=this,n=e._private.cy.collection(),r=0;r0;if(d||u&&p){var g=void 0;d&&p||d?g=c.properties:p&&(g=c.mappedProperties);for(var f=0;f1&&(m=1),o.color){var w=i.valueMin[0],k=i.valueMax[0],T=i.valueMin[1],_=i.valueMax[1],E=i.valueMin[2],S=i.valueMax[2],C=null==i.valueMin[3]?1:i.valueMin[3],A=null==i.valueMax[3]?1:i.valueMax[3],L=[Math.round(w+(k-w)*m),Math.round(T+(_-T)*m),Math.round(E+(S-E)*m),Math.round(C+(A-C)*m)];n={bypass:i.bypass,name:i.name,value:L,strValue:"rgb("+L[0]+", "+L[1]+", "+L[2]+")"}}else{if(!o.number)return!1;var M=i.valueMin+(i.valueMax-i.valueMin)*m;n=this.parse(i.name,M,i.bypass,d)}if(!n)return f(),!1;n.mapping=i,i=n;break;case s.data:for(var N=i.field.split("."),I=u.data,R=0;R0&&a>0){for(var o={},l=!1,c=0;c0?t.delayAnimation(s).play().promise().then(e):e()})).then((function(){return t.animation({style:o,duration:a,easing:t.pstyle("transition-timing-function").value,queue:!1}).play().promise()})).then((function(){n.removeBypasses(t,i),t.emitAndNotify("style"),r.transitioning=!1}))}else r.transitioning&&(this.removeBypasses(t,i),t.emitAndNotify("style"),r.transitioning=!1)},kl.checkTrigger=function(t,e,n,r,i,a){var s=this.properties[e],o=i(s);t.removed()||null!=o&&o(n,r,t)&&a(s)},kl.checkZOrderTrigger=function(t,e,n,r){var i=this;this.checkTrigger(t,e,n,r,(function(t){return t.triggersZOrder}),(function(){i._private.cy.notify("zorder",t)}))},kl.checkBoundsTrigger=function(t,e,n,r){this.checkTrigger(t,e,n,r,(function(t){return t.triggersBounds}),(function(e){t.dirtyCompoundBoundsCache(),t.dirtyBoundingBoxCache()}))},kl.checkConnectedEdgesBoundsTrigger=function(t,e,n,r){this.checkTrigger(t,e,n,r,(function(t){return t.triggersBoundsOfConnectedEdges}),(function(e){t.connectedEdges().forEach((function(t){t.dirtyBoundingBoxCache()}))}))},kl.checkParallelEdgesBoundsTrigger=function(t,e,n,r){this.checkTrigger(t,e,n,r,(function(t){return t.triggersBoundsOfParallelEdges}),(function(e){t.parallelEdges().forEach((function(t){t.dirtyBoundingBoxCache()}))}))},kl.checkTriggers=function(t,e,n,r){t.dirtyStyleCache(),this.checkZOrderTrigger(t,e,n,r),this.checkBoundsTrigger(t,e,n,r),this.checkConnectedEdgesBoundsTrigger(t,e,n,r),this.checkParallelEdgesBoundsTrigger(t,e,n,r)};var _l={applyBypass:function(t,e,n,r){var i=[];if("*"===e||"**"===e){if(void 0!==n)for(var a=0;ae.length?a.substr(e.length):""}function o(){n=n.length>r.length?n.substr(r.length):""}for(a=a.replace(/[/][*](\s|.)+?[*][/]/g,"");!a.match(/^\s*$/);){var l=a.match(/^\s*((?:.|\s)+?)\s*\{((?:.|\s)+?)\}/);if(!l){re("Halting stylesheet parsing: String stylesheet contains more to parse but no selector and block found in: "+a);break}e=l[0];var c=l[1];if("core"!==c&&new ws(c).invalid)re("Skipping parsing of block: Invalid selector found in string stylesheet: "+c),s();else{var h=l[2],u=!1;n=h;for(var d=[];!n.match(/^\s*$/);){var p=n.match(/^\s*(.+?)\s*:\s*(.+?)(?:\s*;|\s*$)/);if(!p){re("Skipping parsing of block: Invalid formatting of style property and value definitions found in:"+h),u=!0;break}r=p[0];var g=p[1],f=p[2];this.properties[g]?i.parse(g,f)?(d.push({name:g,val:f}),o()):(re("Skipping property: Invalid property definition in: "+r),o()):(re("Skipping property: Invalid property name in: "+r),o())}if(u){s();break}i.selector(c);for(var m=0;m=7&&"d"===e[0]&&(c=new RegExp(o.data.regex).exec(e))){if(n)return!1;var d=o.data;return{name:t,value:c,strValue:""+e,mapped:d,field:c[1],bypass:n}}if(e.length>=10&&"m"===e[0]&&(h=new RegExp(o.mapData.regex).exec(e))){if(n)return!1;if(u.multiple)return!1;var p=o.mapData;if(!u.color&&!u.number)return!1;var g=this.parse(t,h[4]);if(!g||g.mapped)return!1;var f=this.parse(t,h[5]);if(!f||f.mapped)return!1;if(g.pfValue===f.pfValue||g.strValue===f.strValue)return re("`"+t+": "+e+"` is not a valid mapper because the output range is zero; converting to `"+t+": "+g.strValue+"`"),this.parse(t,g.strValue);if(u.color){var m=g.value,y=f.value;if(!(m[0]!==y[0]||m[1]!==y[1]||m[2]!==y[2]||m[3]!==y[3]&&(null!=m[3]&&1!==m[3]||null!=y[3]&&1!==y[3])))return!1}return{name:t,value:h,strValue:""+e,mapped:p,field:h[1],fieldMin:parseFloat(h[2]),fieldMax:parseFloat(h[3]),valueMin:g.value,valueMax:f.value,bypass:n}}}if(u.multiple&&"multiple"!==r){var v;if(v=l?e.split(/\s+/):X(e)?e:[e],u.evenMultiple&&v.length%2!=0)return null;for(var x=[],b=[],w=[],k="",T=!1,_=0;_0?" ":"")+E.strValue}return u.validate&&!u.validate(x,b)?null:u.singleEnum&&T?1===x.length&&j(x[0])?{name:t,value:x[0],strValue:x[0],bypass:n}:null:{name:t,value:x,pfValue:w,strValue:k,bypass:n,units:b}}var S,C,A=function(){for(var r=0;ru.max||u.strictMax&&e===u.max))return null;var R={name:t,value:e,strValue:""+e+(L||""),units:L,bypass:n};return u.unitless||"px"!==L&&"em"!==L?R.pfValue=e:R.pfValue="px"!==L&&L?this.getEmSizeInPixels()*e:e,"ms"!==L&&"s"!==L||(R.pfValue="ms"===L?e:1e3*e),"deg"!==L&&"rad"!==L||(R.pfValue="rad"===L?e:(S=e,Math.PI*S/180)),"%"===L&&(R.pfValue=e/100),R}if(u.propList){var D=[],O=""+e;if("none"===O);else{for(var P=O.split(/\s*,\s*|\s+/),$=0;$0&&l>0&&!isNaN(n.w)&&!isNaN(n.h)&&n.w>0&&n.h>0)return{zoom:s=(s=(s=Math.min((o-2*e)/n.w,(l-2*e)/n.h))>this._private.maxZoom?this._private.maxZoom:s)=n.minZoom&&(n.maxZoom=e),this},minZoom:function(t){return void 0===t?this._private.minZoom:this.zoomRange({min:t})},maxZoom:function(t){return void 0===t?this._private.maxZoom:this.zoomRange({max:t})},getZoomedViewport:function(t){var e,n,r=this._private,i=r.pan,a=r.zoom,s=!1;if(r.zoomingEnabled||(s=!0),Q(t)?n=t:K(t)&&(n=t.level,null!=t.position?e=Be(t.position,a,i):null!=t.renderedPosition&&(e=t.renderedPosition),null==e||r.panningEnabled||(s=!0)),n=(n=n>r.maxZoom?r.maxZoom:n)e.maxZoom||!e.zoomingEnabled?a=!0:(e.zoom=o,i.push("zoom"))}if(r&&(!a||!t.cancelOnFailedZoom)&&e.panningEnabled){var l=t.pan;Q(l.x)&&(e.pan.x=l.x,s=!1),Q(l.y)&&(e.pan.y=l.y,s=!1),s||i.push("pan")}return i.length>0&&(i.push("viewport"),this.emit(i.join(" ")),this.notify("viewport")),this},center:function(t){var e=this.getCenterPan(t);return e&&(this._private.pan=e,this.emit("pan viewport"),this.notify("viewport")),this},getCenterPan:function(t,e){if(this._private.panningEnabled){if(j(t)){var n=t;t=this.mutableElements().filter(n)}else tt(t)||(t=this.mutableElements());if(0!==t.length){var r=t.boundingBox(),i=this.width(),a=this.height();return{x:(i-(e=void 0===e?this._private.zoom:e)*(r.x1+r.x2))/2,y:(a-e*(r.y1+r.y2))/2}}}},reset:function(){return this._private.panningEnabled&&this._private.zoomingEnabled?(this.viewport({pan:{x:0,y:0},zoom:1}),this):this},invalidateSize:function(){this._private.sizeCache=null},size:function(){var t,e,n=this._private,r=n.container;return n.sizeCache=n.sizeCache||(r?(t=this.window().getComputedStyle(r),e=function(e){return parseFloat(t.getPropertyValue(e))},{width:r.clientWidth-e("padding-left")-e("padding-right"),height:r.clientHeight-e("padding-top")-e("padding-bottom")}):{width:1,height:1})},width:function(){return this.size().width},height:function(){return this.size().height},extent:function(){var t=this._private.pan,e=this._private.zoom,n=this.renderedExtent(),r={x1:(n.x1-t.x)/e,x2:(n.x2-t.x)/e,y1:(n.y1-t.y)/e,y2:(n.y2-t.y)/e};return r.w=r.x2-r.x1,r.h=r.y2-r.y1,r},renderedExtent:function(){var t=this.width(),e=this.height();return{x1:0,y1:0,x2:t,y2:e,w:t,h:e}},multiClickDebounceTime:function(t){return t?(this._private.multiClickDebounceTime=t,this):this._private.multiClickDebounceTime}};Dl.centre=Dl.center,Dl.autolockNodes=Dl.autolock,Dl.autoungrabifyNodes=Dl.autoungrabify;var Ol={data:rs.data({field:"data",bindingEvent:"data",allowBinding:!0,allowSetting:!0,settingEvent:"data",settingTriggersEvent:!0,triggerFnName:"trigger",allowGetting:!0,updateStyle:!0}),removeData:rs.removeData({field:"data",event:"data",triggerFnName:"trigger",triggerEvent:!0,updateStyle:!0}),scratch:rs.data({field:"scratch",bindingEvent:"scratch",allowBinding:!0,allowSetting:!0,settingEvent:"scratch",settingTriggersEvent:!0,triggerFnName:"trigger",allowGetting:!0,updateStyle:!0}),removeScratch:rs.removeData({field:"scratch",event:"scratch",triggerFnName:"trigger",triggerEvent:!0,updateStyle:!0})};Ol.attr=Ol.data,Ol.removeAttr=Ol.removeData;var Pl=function(t){var e=this,n=(t=vt({},t)).container;n&&!J(n)&&J(n[0])&&(n=n[0]);var r=n?n._cyreg:null;(r=r||{})&&r.cy&&(r.cy.destroy(),r={});var i=r.readies=r.readies||[];n&&(n._cyreg=r),r.cy=e;var a=void 0!==p&&void 0!==n&&!t.headless,s=t;s.layout=vt({name:a?"grid":"null"},s.layout),s.renderer=vt({name:a?"canvas":"null"},s.renderer);var o=function(t,e,n){return void 0!==e?e:void 0!==n?n:t},l=this._private={container:n,ready:!1,options:s,elements:new Qo(this),listeners:[],aniEles:new Qo(this),data:s.data||{},scratch:{},layout:null,renderer:null,destroyed:!1,notificationsEnabled:!0,minZoom:1e-50,maxZoom:1e50,zoomingEnabled:o(!0,s.zoomingEnabled),userZoomingEnabled:o(!0,s.userZoomingEnabled),panningEnabled:o(!0,s.panningEnabled),userPanningEnabled:o(!0,s.userPanningEnabled),boxSelectionEnabled:o(!0,s.boxSelectionEnabled),autolock:o(!1,s.autolock,s.autolockNodes),autoungrabify:o(!1,s.autoungrabify,s.autoungrabifyNodes),autounselectify:o(!1,s.autounselectify),styleEnabled:void 0===s.styleEnabled?a:s.styleEnabled,zoom:Q(s.zoom)?s.zoom:1,pan:{x:K(s.pan)&&Q(s.pan.x)?s.pan.x:0,y:K(s.pan)&&Q(s.pan.y)?s.pan.y:0},animation:{current:[],queue:[]},hasCompoundNodes:!1,multiClickDebounceTime:o(250,s.multiClickDebounceTime)};this.createEmitter(),this.selectionType(s.selectionType),this.zoomRange({min:s.minZoom,max:s.maxZoom}),l.styleEnabled&&e.setStyle([]);var c=vt({},s,s.renderer);e.initRenderer(c),function(t,e){if(t.some(st))return Br.all(t).then(e);e(t)}([s.style,s.elements],(function(t){var n=t[0],a=t[1];l.styleEnabled&&e.style().append(n),function(t,n,r){e.notifications(!1);var i=e.mutableElements();i.length>0&&i.remove(),null!=t&&(K(t)||X(t))&&e.add(t),e.one("layoutready",(function(t){e.notifications(!0),e.emit(t),e.one("load",n),e.emitAndNotify("load")})).one("layoutstop",(function(){e.one("done",r),e.emit("done")}));var a=vt({},e._private.options.layout);a.eles=e.elements(),e.layout(a).run()}(a,(function(){e.startAnimationLoop(),l.ready=!0,H(s.ready)&&e.on("ready",s.ready);for(var t=0;t0,l=!!e.boundingBox,c=n.extent(),h=Xe(l?e.boundingBox:{x1:c.x1,y1:c.y1,w:c.w,h:c.h});if(tt(e.roots))t=e.roots;else if(X(e.roots)){for(var u=[],d=0;d0;){var L=S.shift(),M=E(L,C);if(M)L.outgoers().filter((function(t){return t.isNode()&&r.has(t)})).forEach(A);else if(null===M){re("Detected double maximal shift for node `"+L.id()+"`. Bailing maximal adjustment due to cycle. Use `options.maximal: true` only on DAGs.");break}}}var N=0;if(e.avoidOverlap)for(var I=0;I0&&v[0].length<=3?a/2:0),o=2*Math.PI/v[r].length*i;return 0===r&&1===v[0].length&&(s=1),{x:G+s*Math.cos(o),y:V+s*Math.sin(o)}}var c=v[r].length,u=Math.max(1===c?0:l?(h.w-2*e.padding-q.w)/((e.grid?K:c)-1):(h.w-2*e.padding-q.w)/((e.grid?K:c)+1),N);return{x:G+(i+1-(c+1)/2)*u,y:V+(r+1-(F+1)/2)*H}})),this};var Yl={fit:!0,padding:30,boundingBox:void 0,avoidOverlap:!0,nodeDimensionsIncludeLabels:!1,spacingFactor:void 0,radius:void 0,startAngle:1.5*Math.PI,sweep:void 0,clockwise:!0,sort:void 0,animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(t,e){return!0},ready:void 0,stop:void 0,transform:function(t,e){return e}};function Ul(t){this.options=vt({},Yl,t)}Ul.prototype.run=function(){var t=this.options,e=t,n=t.cy,r=e.eles,i=void 0!==e.counterclockwise?!e.counterclockwise:e.clockwise,a=r.nodes().not(":parent");e.sort&&(a=a.sort(e.sort));for(var s,o=Xe(e.boundingBox?e.boundingBox:{x1:0,y1:0,w:n.width(),h:n.height()}),l=o.x1+o.w/2,c=o.y1+o.h/2,h=(void 0===e.sweep?2*Math.PI-2*Math.PI/a.length:e.sweep)/Math.max(1,a.length-1),u=0,d=0;d1&&e.avoidOverlap){u*=1.75;var m=Math.cos(h)-Math.cos(0),y=Math.sin(h)-Math.sin(0),v=Math.sqrt(u*u/(m*m+y*y));s=Math.max(v,s)}return r.nodes().layoutPositions(this,e,(function(t,n){var r=e.startAngle+n*h*(i?1:-1),a=s*Math.cos(r),o=s*Math.sin(r);return{x:l+a,y:c+o}})),this};var Gl,Vl={fit:!0,padding:30,startAngle:1.5*Math.PI,sweep:void 0,clockwise:!0,equidistant:!1,minNodeSpacing:10,boundingBox:void 0,avoidOverlap:!0,nodeDimensionsIncludeLabels:!1,height:void 0,width:void 0,spacingFactor:void 0,concentric:function(t){return t.degree()},levelWidth:function(t){return t.maxDegree()/4},animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(t,e){return!0},ready:void 0,stop:void 0,transform:function(t,e){return e}};function ql(t){this.options=vt({},Vl,t)}ql.prototype.run=function(){for(var t=this.options,e=t,n=void 0!==e.counterclockwise?!e.counterclockwise:e.clockwise,r=t.cy,i=e.eles,a=i.nodes().not(":parent"),s=Xe(e.boundingBox?e.boundingBox:{x1:0,y1:0,w:r.width(),h:r.height()}),o=s.x1+s.w/2,l=s.y1+s.h/2,c=[],h=0,u=0;u0&&Math.abs(v[0].value-b.value)>=m&&(v=[],y.push(v)),v.push(b)}var w=h+e.minNodeSpacing;if(!e.avoidOverlap){var k=y.length>0&&y[0].length>1,T=(Math.min(s.w,s.h)/2-w)/(y.length+k?1:0);w=Math.min(w,T)}for(var _=0,E=0;E1&&e.avoidOverlap){var L=Math.cos(A)-Math.cos(0),M=Math.sin(A)-Math.sin(0),N=Math.sqrt(w*w/(L*L+M*M));_=Math.max(N,_)}S.r=_,_+=w}if(e.equidistant){for(var I=0,R=0,D=0;D=t.numIter||(nc(r,t),r.temperature=r.temperature*t.coolingFactor,r.temperature=t.animationThreshold&&a(),Dt(h)):(gc(r,t),o())};h()}else{for(;c;)c=s(l),l++;gc(r,t),o()}return this},Hl.prototype.stop=function(){return this.stopped=!0,this.thread&&this.thread.stop(),this.emit("layoutstop"),this},Hl.prototype.destroy=function(){return this.thread&&this.thread.stop(),this};var Xl=function(t,e,n){for(var r=n.eles.edges(),i=n.eles.nodes(),a=Xe(n.boundingBox?n.boundingBox:{x1:0,y1:0,w:t.width(),h:t.height()}),s={isCompound:t.hasCompoundNodes(),layoutNodes:[],idToIndex:{},nodeSize:i.size(),graphSet:[],indexToGraph:[],layoutEdges:[],edgeSize:r.size(),temperature:n.initialTemp,clientWidth:a.w,clientHeight:a.h,boundingBox:a},o=n.eles.components(),l={},c=0;c0)for(s.graphSet.push(w),c=0;cr.count?0:r.graph},Ql=function(t,e,n,r){var i=r.graphSet[n];if(-10)var o=(c=r.nodeOverlap*s)*i/(f=Math.sqrt(i*i+a*a)),l=c*a/f;else{var c,h=oc(t,i,a),u=oc(e,-1*i,-1*a),d=u.x-h.x,p=u.y-h.y,g=d*d+p*p,f=Math.sqrt(g);o=(c=(t.nodeRepulsion+e.nodeRepulsion)/g)*d/f,l=c*p/f}t.isLocked||(t.offsetX-=o,t.offsetY-=l),e.isLocked||(e.offsetX+=o,e.offsetY+=l)}},sc=function(t,e,n,r){if(n>0)var i=t.maxX-e.minX;else i=e.maxX-t.minX;if(r>0)var a=t.maxY-e.minY;else a=e.maxY-t.minY;return i>=0&&a>=0?Math.sqrt(i*i+a*a):0},oc=function(t,e,n){var r=t.positionX,i=t.positionY,a=t.height||1,s=t.width||1,o=n/e,l=a/s,c={};return 0===e&&0n?(c.x=r,c.y=i+a/2,c):0e&&-1*l<=o&&o<=l?(c.x=r-s/2,c.y=i-s*n/2/e,c):0=l)?(c.x=r+a*e/2/n,c.y=i+a/2,c):0>n&&(o<=-1*l||o>=l)?(c.x=r-a*e/2/n,c.y=i-a/2,c):c},lc=function(t,e){for(var n=0;n1){var g=e.gravity*u/p,f=e.gravity*d/p;h.offsetX+=g,h.offsetY+=f}}}}},hc=function(t,e){var n=[],r=0,i=-1;for(n.push.apply(n,t.graphSet[0]),i+=t.graphSet[0].length;r<=i;){var a=n[r++],s=t.idToIndex[a],o=t.layoutNodes[s],l=o.children;if(0n)var i={x:n*t/r,y:n*e/r};else i={x:t,y:e};return i},pc=function(t,e){var n=t.parentId;if(null!=n){var r=e.layoutNodes[e.idToIndex[n]],i=!1;return(null==r.maxX||t.maxX+r.padRight>r.maxX)&&(r.maxX=t.maxX+r.padRight,i=!0),(null==r.minX||t.minX-r.padLeftr.maxY)&&(r.maxY=t.maxY+r.padBottom,i=!0),(null==r.minY||t.minY-r.padTopg&&(u+=p+e.componentSpacing,h=0,d=0,p=0)}}},fc={fit:!0,padding:30,boundingBox:void 0,avoidOverlap:!0,avoidOverlapPadding:10,nodeDimensionsIncludeLabels:!1,spacingFactor:void 0,condense:!1,rows:void 0,cols:void 0,position:function(t){},sort:void 0,animate:!1,animationDuration:500,animationEasing:void 0,animateFilter:function(t,e){return!0},ready:void 0,stop:void 0,transform:function(t,e){return e}};function mc(t){this.options=vt({},fc,t)}mc.prototype.run=function(){var t=this.options,e=t,n=t.cy,r=e.eles,i=r.nodes().not(":parent");e.sort&&(i=i.sort(e.sort));var a=Xe(e.boundingBox?e.boundingBox:{x1:0,y1:0,w:n.width(),h:n.height()});if(0===a.h||0===a.w)r.nodes().layoutPositions(this,e,(function(t){return{x:a.x1,y:a.y1}}));else{var s=i.size(),o=Math.sqrt(s*a.h/a.w),l=Math.round(o),c=Math.round(a.w/a.h*o),h=function(t){if(null==t)return Math.min(l,c);Math.min(l,c)==l?l=t:c=t},u=function(t){if(null==t)return Math.max(l,c);Math.max(l,c)==l?l=t:c=t},d=e.rows,p=null!=e.cols?e.cols:e.columns;if(null!=d&&null!=p)l=d,c=p;else if(null!=d&&null==p)l=d,c=Math.ceil(s/l);else if(null==d&&null!=p)c=p,l=Math.ceil(s/c);else if(c*l>s){var g=h(),f=u();(g-1)*f>=s?h(g-1):(f-1)*g>=s&&u(f-1)}else for(;c*l=s?u(y+1):h(m+1)}var v=a.w/c,x=a.h/l;if(e.condense&&(v=0,x=0),e.avoidOverlap)for(var b=0;b=c&&(N=0,M++)},R={},D=0;D(r=cn(t,e,b[w],b[w+1],b[w+2],b[w+3])))return m(n,r),!0}else if("bezier"===a.edgeType||"multibezier"===a.edgeType||"self"===a.edgeType||"compound"===a.edgeType)for(b=a.allpts,w=0;w+5(r=ln(t,e,b[w],b[w+1],b[w+2],b[w+3],b[w+4],b[w+5])))return m(n,r),!0;v=v||i.source,x=x||i.target;var k=s.getArrowWidth(l,h),T=[{name:"source",x:a.arrowStartX,y:a.arrowStartY,angle:a.srcArrowAngle},{name:"target",x:a.arrowEndX,y:a.arrowEndY,angle:a.tgtArrowAngle},{name:"mid-source",x:a.midX,y:a.midY,angle:a.midsrcArrowAngle},{name:"mid-target",x:a.midX,y:a.midY,angle:a.midtgtArrowAngle}];for(w=0;w0&&(y(v),y(x))}function x(t,e,n){return ue(t,e,n)}function b(n,r){var i,a=n._private,s=g;i=r?r+"-":"",n.boundingBox();var o=a.labelBounds[r||"main"],l=n.pstyle(i+"label").value;if("yes"===n.pstyle("text-events").strValue&&l){var c=x(a.rscratch,"labelX",r),h=x(a.rscratch,"labelY",r),u=x(a.rscratch,"labelAngle",r),d=n.pstyle(i+"text-margin-x").pfValue,p=n.pstyle(i+"text-margin-y").pfValue,f=o.x1-s-d,y=o.x2+s-d,v=o.y1-s-p,b=o.y2+s-p;if(u){var w=Math.cos(u),k=Math.sin(u),T=function(t,e){return{x:(t-=c)*w-(e-=h)*k+c,y:t*k+e*w+h}},_=T(f,v),E=T(f,b),S=T(y,v),C=T(y,b),A=[_.x+d,_.y+p,S.x+d,S.y+p,C.x+d,C.y+p,E.x+d,E.y+p];if(hn(t,e,A))return m(n),!0}else if(rn(o,t,e))return m(n),!0}}n&&(l=l.interactive);for(var w=l.length-1;w>=0;w--){var k=l[w];k.isNode()?y(k)||b(k):v(k)||b(k)||b(k,"source")||b(k,"target")}return c},getAllInBox:function(t,e,n,r){var i,a,s=this.getCachedZSortedEles().interactive,o=2/this.cy.zoom(),l=[],c=Math.min(t,n),h=Math.max(t,n),u=Math.min(e,r),d=Math.max(e,r),p=Xe({x1:t=c,y1:e=u,x2:n=h,y2:r=d});function g(t,e,n){return ue(t,e,n)}function f(t,e){var n=t._private,r=o;t.boundingBox();var i=n.labelBounds.main,a=g(n.rscratch,"labelX",e),s=g(n.rscratch,"labelY",e),l=g(n.rscratch,"labelAngle",e),c=t.pstyle("text-margin-x").pfValue,h=t.pstyle("text-margin-y").pfValue,u=i.x1-r-c,d=i.x2+r-c,p=i.y1-r-h,f=i.y2+r-h;if(l){var m=Math.cos(l),y=Math.sin(l),v=function(t,e){return{x:(t-=a)*m-(e-=s)*y+a,y:t*y+e*m+s}};return[v(u,p),v(d,p),v(d,f),v(u,f)]}return[{x:u,y:p},{x:d,y:p},{x:d,y:f},{x:u,y:f}]}for(var m=0;m4&&void 0!==arguments[4])||arguments[4];return 0===r||0===e.radius?{cx:e.x,cy:e.y,radius:0,startX:e.x,startY:e.y,stopX:e.x,stopY:e.y,startAngle:void 0,endAngle:void 0,counterClockwise:void 0}:(function(t,e,n,r,i){var a,s;if(t!==Vc?Hc(e,t,qc):((s=qc).x=-1*(a=jc).x,s.y=-1*a.y,s.nx=-1*a.nx,s.ny=-1*a.ny,s.ang=a.ang>0?-(Math.PI-a.ang):Math.PI+a.ang),Hc(e,n,jc),Ic=qc.nx*jc.ny-qc.ny*jc.nx,Rc=qc.nx*jc.nx-qc.ny*-jc.ny,Pc=Math.asin(Math.max(-1,Math.min(1,Ic))),Math.abs(Pc)<1e-6)return Mc=e.x,Nc=e.y,void(Bc=Wc=0);Dc=1,Oc=!1,Rc<0?Pc<0?Pc=Math.PI+Pc:(Pc=Math.PI-Pc,Dc=-1,Oc=!0):Pc>0&&(Dc=-1,Oc=!0),Wc=void 0!==e.radius?e.radius:r,$c=Pc/2,zc=Math.min(qc.len/2,jc.len/2),i?(Fc=Math.abs(Math.cos($c)*Wc/Math.sin($c)))>zc?(Fc=zc,Bc=Math.abs(Fc*Math.sin($c)/Math.cos($c))):Bc=Wc:(Fc=Math.min(zc,Wc),Bc=Math.abs(Fc*Math.sin($c)/Math.cos($c))),Uc=e.x+jc.nx*Fc,Gc=e.y+jc.ny*Fc,Mc=Uc-jc.ny*Bc*Dc,Nc=Gc+jc.nx*Bc*Dc,Zc=e.x+qc.nx*Fc,Yc=e.y+qc.ny*Fc,Vc=e}(t,e,n,r,i),{cx:Mc,cy:Nc,radius:Bc,startX:Zc,startY:Yc,stopX:Uc,stopY:Gc,startAngle:qc.ang+Math.PI/2*Dc,endAngle:jc.ang-Math.PI/2*Dc,counterClockwise:Oc})}var Qc=.01,Jc=Math.sqrt(.02),th={};function eh(t){var e=[];if(null!=t){for(var n=0;n0?Math.max(t-e,0):Math.min(t+e,0)},C=S(_,k),A=S(E,T),L=!1;"auto"===m?f=Math.abs(C)>Math.abs(A)?i:r:m===l||m===o?(f=r,L=!0):m!==a&&m!==s||(f=i,L=!0);var M,N=f===r,I=N?A:C,R=N?E:_,D=Ye(R),O=!1;L&&(v||b)||!(m===o&&R<0||m===l&&R>0||m===a&&R>0||m===s&&R<0)||(I=(D*=-1)*Math.abs(I),O=!0);var P=function(t){return Math.abs(t)=Math.abs(I)},$=P(M=v?(x<0?1+x:x)*I:(x<0?I:0)+x*D),B=P(Math.abs(I)-Math.abs(M));if(!$&&!B||O)if(N){var F=c.y1+M+(g?u/2*D:0),W=c.x1,z=c.x2;n.segpts=[W,F,z,F]}else{var Z=c.x1+M+(g?h/2*D:0),Y=c.y1,U=c.y2;n.segpts=[Z,Y,Z,U]}else if(N){var G=Math.abs(R)<=u/2,V=Math.abs(_)<=d/2;if(G){var q=(c.x1+c.x2)/2,j=c.y1,H=c.y2;n.segpts=[q,j,q,H]}else if(V){var X=(c.y1+c.y2)/2,K=c.x1,Q=c.x2;n.segpts=[K,X,Q,X]}else n.segpts=[c.x1,c.y2]}else{var J=Math.abs(R)<=h/2,tt=Math.abs(E)<=p/2;if(J){var et=(c.y1+c.y2)/2,nt=c.x1,rt=c.x2;n.segpts=[nt,et,rt,et]}else if(tt){var it=(c.x1+c.x2)/2,at=c.y1,st=c.y2;n.segpts=[it,at,it,st]}else n.segpts=[c.x2,c.y1]}if(n.isRound){var ot=t.pstyle("taxi-radius").value,lt="arc-radius"===t.pstyle("radius-type").value[0];n.radii=new Array(n.segpts.length/2).fill(ot),n.isArcRadius=new Array(n.segpts.length/2).fill(lt)}},th.tryToCorrectInvalidPoints=function(t,e){var n=t._private.rscratch;if("bezier"===n.edgeType){var r=e.srcPos,i=e.tgtPos,a=e.srcW,s=e.srcH,o=e.tgtW,l=e.tgtH,c=e.srcShape,h=e.tgtShape,u=e.srcCornerRadius,d=e.tgtCornerRadius,p=e.srcRs,g=e.tgtRs,f=!Q(n.startX)||!Q(n.startY),m=!Q(n.arrowStartX)||!Q(n.arrowStartY),y=!Q(n.endX)||!Q(n.endY),v=!Q(n.arrowEndX)||!Q(n.arrowEndY),x=this.getArrowWidth(t.pstyle("width").pfValue,t.pstyle("arrow-scale").value)*this.arrowShapeWidth*3,b=Ue({x:n.ctrlpts[0],y:n.ctrlpts[1]},{x:n.startX,y:n.startY}),w=bf.poolIndex()){var m=g;g=f,f=m}var y=u.srcPos=g.position(),v=u.tgtPos=f.position(),x=u.srcW=g.outerWidth(),b=u.srcH=g.outerHeight(),k=u.tgtW=f.outerWidth(),T=u.tgtH=f.outerHeight(),_=u.srcShape=n.nodeShapes[e.getNodeShape(g)],E=u.tgtShape=n.nodeShapes[e.getNodeShape(f)],S=u.srcCornerRadius="auto"===g.pstyle("corner-radius").value?"auto":g.pstyle("corner-radius").pfValue,C=u.tgtCornerRadius="auto"===f.pstyle("corner-radius").value?"auto":f.pstyle("corner-radius").pfValue,A=u.tgtRs=f._private.rscratch,L=u.srcRs=g._private.rscratch;u.dirCounts={north:0,west:0,south:0,east:0,northwest:0,southwest:0,northeast:0,southeast:0};for(var M=0;M=Jc||(U=Math.sqrt(Math.max(Y*Y,Qc)+Math.max(Z*Z,Qc)));var G=u.vector={x:Y,y:Z},V=u.vectorNorm={x:G.x/U,y:G.y/U},q={x:-V.y,y:V.x};u.nodesOverlap=!Q(U)||E.checkPoint(P[0],P[1],0,k,T,v.x,v.y,C,A)||_.checkPoint(B[0],B[1],0,x,b,y.x,y.y,S,L),u.vectorNormInverse=q,t={nodesOverlap:u.nodesOverlap,dirCounts:u.dirCounts,calculatedIntersection:!0,hasBezier:u.hasBezier,hasUnbundled:u.hasUnbundled,eles:u.eles,srcPos:v,srcRs:A,tgtPos:y,tgtRs:L,srcW:k,srcH:T,tgtW:x,tgtH:b,srcIntn:F,tgtIntn:$,srcShape:E,tgtShape:_,posPts:{x1:z.x2,y1:z.y2,x2:z.x1,y2:z.y1},intersectionPts:{x1:W.x2,y1:W.y2,x2:W.x1,y2:W.y1},vector:{x:-G.x,y:-G.y},vectorNorm:{x:-V.x,y:-V.y},vectorNormInverse:{x:-q.x,y:-q.y}}}var j=O?t:u;I.nodesOverlap=j.nodesOverlap,I.srcIntn=j.srcIntn,I.tgtIntn=j.tgtIntn,I.isRound=R.startsWith("round"),r&&(g.isParent()||g.isChild()||f.isParent()||f.isChild())&&(g.parents().anySame(f)||f.parents().anySame(g)||g.same(f)&&g.isParent())?e.findCompoundLoopPoints(N,j,M,D):g===f?e.findLoopPoints(N,j,M,D):R.endsWith("segments")?e.findSegmentsPoints(N,j):R.endsWith("taxi")?e.findTaxiPoints(N,j):"straight"===R||!D&&u.eles.length%2==1&&M===Math.floor(u.eles.length/2)?e.findStraightEdgePoints(N):e.findBezierPoints(N,j,M,D,O),e.findEndpoints(N),e.tryToCorrectInvalidPoints(N,j),e.checkForInvalidEdgeWarning(N),e.storeAllpts(N),e.storeEdgeProjections(N),e.calculateArrowAngles(N),e.recalculateEdgeLabelProjections(N),e.calculateLabelAngles(N)}},w=0;w0){var G=c,V=Ge(G,We(e)),q=Ge(G,We(U)),j=V;q2&&Ge(G,{x:U[2],y:U[3]})0){var lt=h,ct=Ge(lt,We(e)),ht=Ge(lt,We(ot)),ut=ct;ht2&&Ge(lt,{x:ot[2],y:ot[3]})=c||v){h={cp:f,segment:y};break}}if(h)break}var x=h.cp,b=h.segment,w=(c-d)/b.length,k=b.t1-b.t0,T=o?b.t0+k*w:b.t1-k*w;T=He(0,T,1),e=je(x.p0,x.p1,x.p2,T),i=function(t,e,n,r){var i=He(0,r-.001,1),a=He(0,r+.001,1),s=je(t,e,n,i),o=je(t,e,n,a);return oh(s,o)}(x.p0,x.p1,x.p2,T);break;case"straight":case"segments":case"haystack":for(var _,E,S,C,A=0,L=r.allpts.length,M=0;M+3=c));M+=2);var N=(c-E)/_;N=He(0,N,1),e=function(t,e,n,r){var i=e.x-t.x,a=e.y-t.y,s=Ue(t,e),o=i/s,l=a/s;return n=null==n?0:n,r=null!=r?r:n*s,{x:t.x+o*r,y:t.y+l*r}}(S,C,N),i=oh(S,C)}s("labelX",n,e.x),s("labelY",n,e.y),s("labelAutoAngle",n,i)}};c("source"),c("target"),this.applyLabelDimensions(t)}},ah.applyLabelDimensions=function(t){this.applyPrefixedLabelDimensions(t),t.isEdge()&&(this.applyPrefixedLabelDimensions(t,"source"),this.applyPrefixedLabelDimensions(t,"target"))},ah.applyPrefixedLabelDimensions=function(t,e){var n=t._private,r=this.getLabelText(t,e),i=Ut(r,t._private.labelDimsKey);if(ue(n.rscratch,"prefixedLabelDimsKey",e)!==i){de(n.rscratch,"prefixedLabelDimsKey",e,i);var a=this.calculateLabelDimensions(t,r),s=t.pstyle("line-height").pfValue,o=t.pstyle("text-wrap").strValue,l=ue(n.rscratch,"labelWrapCachedLines",e)||[],c="wrap"!==o?1:Math.max(l.length,1),h=a.height/c,u=h*s,d=a.width,p=a.height+(c-1)*(s-1)*h;de(n.rstyle,"labelWidth",e,d),de(n.rscratch,"labelWidth",e,d),de(n.rstyle,"labelHeight",e,p),de(n.rscratch,"labelHeight",e,p),de(n.rscratch,"labelLineHeight",e,u)}},ah.getLabelText=function(t,e){var n=t._private,r=e?e+"-":"",i=t.pstyle(r+"label").strValue,a=t.pstyle("text-transform").value,o=function(t,r){return r?(de(n.rscratch,t,e,r),r):ue(n.rscratch,t,e)};if(!i)return"";"none"==a||("uppercase"==a?i=i.toUpperCase():"lowercase"==a&&(i=i.toLowerCase()));var l=t.pstyle("text-wrap").value;if("wrap"===l){var c=o("labelKey");if(null!=c&&o("labelWrapKey")===c)return o("labelWrapCachedText");for(var h=i.split("\n"),u=t.pstyle("text-max-width").pfValue,d="anywhere"===t.pstyle("text-overflow-wrap").value,p=[],g=/[\s\u200b]+|$/g,f=0;fu){var x,b="",w=0,k=s(m.matchAll(g));try{for(k.s();!(x=k.n()).done;){var T=x.value,_=T[0],E=m.substring(w,T.index);w=T.index+_.length;var S=0===b.length?E:b+E+_;this.calculateLabelDimensions(t,S).width<=u?b+=E+_:(b&&p.push(b),b=E+_)}}catch(t){k.e(t)}finally{k.f()}b.match(/^[\s\u200b]+$/)||p.push(b)}else p.push(m)}o("labelWrapCachedLines",p),i=o("labelWrapCachedText",p.join("\n")),o("labelWrapKey",c)}else if("ellipsis"===l){var C=t.pstyle("text-max-width").pfValue,A="",L=!1;if(this.calculateLabelDimensions(t,i).widthC);M++)A+=i[M],M===i.length-1&&(L=!0);return L||(A+="…"),A}return i},ah.getLabelJustification=function(t){var e=t.pstyle("text-justification").strValue,n=t.pstyle("text-halign").strValue;if("auto"!==e)return e;if(!t.isNode())return"center";switch(n){case"left":return"right";case"right":return"left";default:return"center"}},ah.calculateLabelDimensions=function(t,e){var n=this.cy.window().document,r=t.pstyle("font-style").strValue,i=t.pstyle("font-size").pfValue,a=t.pstyle("font-family").strValue,s=t.pstyle("font-weight").strValue,o=this.labelCalcCanvas,l=this.labelCalcCanvasContext;if(!o){o=this.labelCalcCanvas=n.createElement("canvas"),l=this.labelCalcCanvasContext=o.getContext("2d");var c=o.style;c.position="absolute",c.left="-9999px",c.top="-9999px",c.zIndex="-1",c.visibility="hidden",c.pointerEvents="none"}l.font="".concat(r," ").concat(s," ").concat(i,"px ").concat(a);for(var h=0,u=0,d=e.split("\n"),p=0;p1&&void 0!==arguments[1])||arguments[1];if(e.merge(t),n)for(var r=0;r=t.desktopTapThreshold2}var S=i(e);m&&(t.hoverData.tapholdCancelled=!0),n=!0,r(f,["mousemove","vmousemove","tapdrag"],e,{x:h[0],y:h[1]});var C=function(){t.data.bgActivePosistion=void 0,t.hoverData.selecting||s.emit({originalEvent:e,type:"boxstart",position:{x:h[0],y:h[1]}}),g[4]=1,t.hoverData.selecting=!0,t.redrawHint("select",!0),t.redraw()};if(3===t.hoverData.which){if(m){var A={originalEvent:e,type:"cxtdrag",position:{x:h[0],y:h[1]}};x?x.emit(A):s.emit(A),t.hoverData.cxtDragged=!0,t.hoverData.cxtOver&&f===t.hoverData.cxtOver||(t.hoverData.cxtOver&&t.hoverData.cxtOver.emit({originalEvent:e,type:"cxtdragout",position:{x:h[0],y:h[1]}}),t.hoverData.cxtOver=f,f&&f.emit({originalEvent:e,type:"cxtdragover",position:{x:h[0],y:h[1]}}))}}else if(t.hoverData.dragging){if(n=!0,s.panningEnabled()&&s.userPanningEnabled()){var L;if(t.hoverData.justStartedPan){var M=t.hoverData.mdownPos;L={x:(h[0]-M[0])*o,y:(h[1]-M[1])*o},t.hoverData.justStartedPan=!1}else L={x:b[0]*o,y:b[1]*o};s.panBy(L),s.emit("dragpan"),t.hoverData.dragged=!0}h=t.projectIntoViewport(e.clientX,e.clientY)}else if(1!=g[4]||null!=x&&!x.pannable()){if(x&&x.pannable()&&x.active()&&x.unactivate(),x&&x.grabbed()||f==y||(y&&r(y,["mouseout","tapdragout"],e,{x:h[0],y:h[1]}),f&&r(f,["mouseover","tapdragover"],e,{x:h[0],y:h[1]}),t.hoverData.last=f),x)if(m){if(s.boxSelectionEnabled()&&S)x&&x.grabbed()&&(u(w),x.emit("freeon"),w.emit("free"),t.dragData.didDrag&&(x.emit("dragfreeon"),w.emit("dragfree"))),C();else if(x&&x.grabbed()&&t.nodeIsDraggable(x)){var N=!t.dragData.didDrag;N&&t.redrawHint("eles",!0),t.dragData.didDrag=!0,t.hoverData.draggingEles||c(w,{inDragLayer:!0});var I={x:0,y:0};if(Q(b[0])&&Q(b[1])&&(I.x+=b[0],I.y+=b[1],N)){var R=t.hoverData.dragDelta;R&&Q(R[0])&&Q(R[1])&&(I.x+=R[0],I.y+=R[1])}t.hoverData.draggingEles=!0,w.silentShift(I).emit("position drag"),t.redrawHint("drag",!0),t.redraw()}}else!function(){var e=t.hoverData.dragDelta=t.hoverData.dragDelta||[];0===e.length?(e.push(b[0]),e.push(b[1])):(e[0]+=b[0],e[1]+=b[1])}();n=!0}else m&&(t.hoverData.dragging||!s.boxSelectionEnabled()||!S&&s.panningEnabled()&&s.userPanningEnabled()?!t.hoverData.selecting&&s.panningEnabled()&&s.userPanningEnabled()&&a(x,t.hoverData.downs)&&(t.hoverData.dragging=!0,t.hoverData.justStartedPan=!0,g[4]=0,t.data.bgActivePosistion=We(d),t.redrawHint("select",!0),t.redraw()):C(),x&&x.pannable()&&x.active()&&x.unactivate());return g[2]=h[0],g[3]=h[1],n?(e.stopPropagation&&e.stopPropagation(),e.preventDefault&&e.preventDefault(),!1):void 0}}),!1),t.registerBinding(e,"mouseup",(function(e){if((1!==t.hoverData.which||1===e.which||!t.hoverData.capture)&&t.hoverData.capture){t.hoverData.capture=!1;var a=t.cy,s=t.projectIntoViewport(e.clientX,e.clientY),o=t.selection,l=t.findNearestElement(s[0],s[1],!0,!1),c=t.dragData.possibleDragElements,h=t.hoverData.down,d=i(e);if(t.data.bgActivePosistion&&(t.redrawHint("select",!0),t.redraw()),t.hoverData.tapholdCancelled=!0,t.data.bgActivePosistion=void 0,h&&h.unactivate(),3===t.hoverData.which){var p={originalEvent:e,type:"cxttapend",position:{x:s[0],y:s[1]}};if(h?h.emit(p):a.emit(p),!t.hoverData.cxtDragged){var g={originalEvent:e,type:"cxttap",position:{x:s[0],y:s[1]}};h?h.emit(g):a.emit(g)}t.hoverData.cxtDragged=!1,t.hoverData.which=null}else if(1===t.hoverData.which){if(r(l,["mouseup","tapend","vmouseup"],e,{x:s[0],y:s[1]}),t.dragData.didDrag||t.hoverData.dragged||t.hoverData.selecting||t.hoverData.isOverThresholdDrag||(r(h,["click","tap","vclick"],e,{x:s[0],y:s[1]}),b=!1,e.timeStamp-w<=a.multiClickDebounceTime()?(x&&clearTimeout(x),b=!0,w=null,r(h,["dblclick","dbltap","vdblclick"],e,{x:s[0],y:s[1]})):(x=setTimeout((function(){b||r(h,["oneclick","onetap","voneclick"],e,{x:s[0],y:s[1]})}),a.multiClickDebounceTime()),w=e.timeStamp)),null!=h||t.dragData.didDrag||t.hoverData.selecting||t.hoverData.dragged||i(e)||(a.$(n).unselect(["tapunselect"]),c.length>0&&t.redrawHint("eles",!0),t.dragData.possibleDragElements=c=a.collection()),l!=h||t.dragData.didDrag||t.hoverData.selecting||null!=l&&l._private.selectable&&(t.hoverData.dragging||("additive"===a.selectionType()||d?l.selected()?l.unselect(["tapunselect"]):l.select(["tapselect"]):d||(a.$(n).unmerge(l).unselect(["tapunselect"]),l.select(["tapselect"]))),t.redrawHint("eles",!0)),t.hoverData.selecting){var f=a.collection(t.getAllInBox(o[0],o[1],o[2],o[3]));t.redrawHint("select",!0),f.length>0&&t.redrawHint("eles",!0),a.emit({type:"boxend",originalEvent:e,position:{x:s[0],y:s[1]}});"additive"===a.selectionType()||d||a.$(n).unmerge(f).unselect(),f.emit("box").stdFilter((function(t){return t.selectable()&&!t.selected()})).select().emit("boxselect"),t.redraw()}if(t.hoverData.dragging&&(t.hoverData.dragging=!1,t.redrawHint("select",!0),t.redrawHint("eles",!0),t.redraw()),!o[4]){t.redrawHint("drag",!0),t.redrawHint("eles",!0);var m=h&&h.grabbed();u(c),m&&(h.emit("freeon"),c.emit("free"),t.dragData.didDrag&&(h.emit("dragfreeon"),c.emit("dragfree")))}}o[4]=0,t.hoverData.down=null,t.hoverData.cxtStarted=!1,t.hoverData.draggingEles=!1,t.hoverData.selecting=!1,t.hoverData.isOverThresholdDrag=!1,t.dragData.didDrag=!1,t.hoverData.dragged=!1,t.hoverData.dragDelta=[],t.hoverData.mdownPos=null,t.hoverData.mdownGPos=null,t.hoverData.which=null}}),!1);var T,_,E,S,C,A,L,M,N,I,R,D,O,P,$=[],B=1e5,F=function(e){var n=!1,r=e.deltaY;if(null==r&&(null!=e.wheelDeltaY?r=e.wheelDeltaY/4:null!=e.wheelDelta&&(r=e.wheelDelta/4)),null==T)if($.length>=4){var i=$;if(T=function(t,e){for(var n=0;n5}if(T)for(var s=0;s5&&(r=5*Ye(r)),d=r/-250,T&&(d/=B,d*=3),d*=t.wheelSensitivity,1===e.deltaMode&&(d*=33);var p=o.zoom()*Math.pow(10,d);"gesturechange"===e.type&&(p=t.gestureStartZoom*e.scale),o.zoom({level:p,renderedPosition:{x:u[0],y:u[1]}}),o.emit("gesturechange"===e.type?"pinchzoom":"scrollzoom")}}};t.registerBinding(t.container,"wheel",F,!0),t.registerBinding(e,"scroll",(function(e){t.scrollingPage=!0,clearTimeout(t.scrollingPageTimeout),t.scrollingPageTimeout=setTimeout((function(){t.scrollingPage=!1}),250)}),!0),t.registerBinding(t.container,"gesturestart",(function(e){t.gestureStartZoom=t.cy.zoom(),t.hasTouchStarted||e.preventDefault()}),!0),t.registerBinding(t.container,"gesturechange",(function(e){t.hasTouchStarted||F(e)}),!0),t.registerBinding(t.container,"mouseout",(function(e){var n=t.projectIntoViewport(e.clientX,e.clientY);t.cy.emit({originalEvent:e,type:"mouseout",position:{x:n[0],y:n[1]}})}),!1),t.registerBinding(t.container,"mouseover",(function(e){var n=t.projectIntoViewport(e.clientX,e.clientY);t.cy.emit({originalEvent:e,type:"mouseover",position:{x:n[0],y:n[1]}})}),!1);var W,z,Z,Y,U,G,V,q=function(t,e,n,r){return Math.sqrt((n-t)*(n-t)+(r-e)*(r-e))},j=function(t,e,n,r){return(n-t)*(n-t)+(r-e)*(r-e)};if(t.registerBinding(t.container,"touchstart",W=function(e){if(t.hasTouchStarted=!0,v(e)){p(),t.touchData.capture=!0,t.data.bgActivePosistion=void 0;var n=t.cy,i=t.touchData.now,a=t.touchData.earlier;if(e.touches[0]){var s=t.projectIntoViewport(e.touches[0].clientX,e.touches[0].clientY);i[0]=s[0],i[1]=s[1]}if(e.touches[1]&&(s=t.projectIntoViewport(e.touches[1].clientX,e.touches[1].clientY),i[2]=s[0],i[3]=s[1]),e.touches[2]&&(s=t.projectIntoViewport(e.touches[2].clientX,e.touches[2].clientY),i[4]=s[0],i[5]=s[1]),e.touches[1]){t.touchData.singleTouchMoved=!0,u(t.dragData.touchDragEles);var l=t.findContainerClientCoords();I=l[0],R=l[1],D=l[2],O=l[3],_=e.touches[0].clientX-I,E=e.touches[0].clientY-R,S=e.touches[1].clientX-I,C=e.touches[1].clientY-R,P=0<=_&&_<=D&&0<=S&&S<=D&&0<=E&&E<=O&&0<=C&&C<=O;var d=n.pan(),g=n.zoom();if(A=q(_,E,S,C),L=j(_,E,S,C),N=[((M=[(_+S)/2,(E+C)/2])[0]-d.x)/g,(M[1]-d.y)/g],L<4e4&&!e.touches[2]){var f=t.findNearestElement(i[0],i[1],!0,!0),m=t.findNearestElement(i[2],i[3],!0,!0);return f&&f.isNode()?(f.activate().emit({originalEvent:e,type:"cxttapstart",position:{x:i[0],y:i[1]}}),t.touchData.start=f):m&&m.isNode()?(m.activate().emit({originalEvent:e,type:"cxttapstart",position:{x:i[0],y:i[1]}}),t.touchData.start=m):n.emit({originalEvent:e,type:"cxttapstart",position:{x:i[0],y:i[1]}}),t.touchData.start&&(t.touchData.start._private.grabbed=!1),t.touchData.cxt=!0,t.touchData.cxtDragged=!1,t.data.bgActivePosistion=void 0,void t.redraw()}}if(e.touches[2])n.boxSelectionEnabled()&&e.preventDefault();else if(e.touches[1]);else if(e.touches[0]){var y=t.findNearestElements(i[0],i[1],!0,!0),x=y[0];if(null!=x&&(x.activate(),t.touchData.start=x,t.touchData.starts=y,t.nodeIsGrabbable(x))){var b=t.dragData.touchDragEles=n.collection(),w=null;t.redrawHint("eles",!0),t.redrawHint("drag",!0),x.selected()?(w=n.$((function(e){return e.selected()&&t.nodeIsGrabbable(e)})),c(w,{addToList:b})):h(x,{addToList:b}),o(x);var k=function(t){return{originalEvent:e,type:t,position:{x:i[0],y:i[1]}}};x.emit(k("grabon")),w?w.forEach((function(t){t.emit(k("grab"))})):x.emit(k("grab"))}r(x,["touchstart","tapstart","vmousedown"],e,{x:i[0],y:i[1]}),null==x&&(t.data.bgActivePosistion={x:s[0],y:s[1]},t.redrawHint("select",!0),t.redraw()),t.touchData.singleTouchMoved=!1,t.touchData.singleTouchStartTime=+new Date,clearTimeout(t.touchData.tapholdTimeout),t.touchData.tapholdTimeout=setTimeout((function(){!1!==t.touchData.singleTouchMoved||t.pinching||t.touchData.selecting||r(t.touchData.start,["taphold"],e,{x:i[0],y:i[1]})}),t.tapholdDuration)}if(e.touches.length>=1){for(var T=t.touchData.startPosition=[null,null,null,null,null,null],$=0;$=t.touchTapThreshold2}if(n&&t.touchData.cxt){e.preventDefault();var w=e.touches[0].clientX-I,k=e.touches[0].clientY-R,T=e.touches[1].clientX-I,M=e.touches[1].clientY-R,D=j(w,k,T,M);if(D/L>=2.25||D>=22500){t.touchData.cxt=!1,t.data.bgActivePosistion=void 0,t.redrawHint("select",!0);var O={originalEvent:e,type:"cxttapend",position:{x:o[0],y:o[1]}};t.touchData.start?(t.touchData.start.unactivate().emit(O),t.touchData.start=null):s.emit(O)}}if(n&&t.touchData.cxt){O={originalEvent:e,type:"cxtdrag",position:{x:o[0],y:o[1]}},t.data.bgActivePosistion=void 0,t.redrawHint("select",!0),t.touchData.start?t.touchData.start.emit(O):s.emit(O),t.touchData.start&&(t.touchData.start._private.grabbed=!1),t.touchData.cxtDragged=!0;var $=t.findNearestElement(o[0],o[1],!0,!0);t.touchData.cxtOver&&$===t.touchData.cxtOver||(t.touchData.cxtOver&&t.touchData.cxtOver.emit({originalEvent:e,type:"cxtdragout",position:{x:o[0],y:o[1]}}),t.touchData.cxtOver=$,$&&$.emit({originalEvent:e,type:"cxtdragover",position:{x:o[0],y:o[1]}}))}else if(n&&e.touches[2]&&s.boxSelectionEnabled())e.preventDefault(),t.data.bgActivePosistion=void 0,this.lastThreeTouch=+new Date,t.touchData.selecting||s.emit({originalEvent:e,type:"boxstart",position:{x:o[0],y:o[1]}}),t.touchData.selecting=!0,t.touchData.didSelect=!0,i[4]=1,i&&0!==i.length&&void 0!==i[0]?(i[2]=(o[0]+o[2]+o[4])/3,i[3]=(o[1]+o[3]+o[5])/3):(i[0]=(o[0]+o[2]+o[4])/3,i[1]=(o[1]+o[3]+o[5])/3,i[2]=(o[0]+o[2]+o[4])/3+1,i[3]=(o[1]+o[3]+o[5])/3+1),t.redrawHint("select",!0),t.redraw();else if(n&&e.touches[1]&&!t.touchData.didSelect&&s.zoomingEnabled()&&s.panningEnabled()&&s.userZoomingEnabled()&&s.userPanningEnabled()){if(e.preventDefault(),t.data.bgActivePosistion=void 0,t.redrawHint("select",!0),tt=t.dragData.touchDragEles){t.redrawHint("drag",!0);for(var B=0;B0&&!t.hoverData.draggingEles&&!t.swipePanning&&null!=t.data.bgActivePosistion&&(t.data.bgActivePosistion=void 0,t.redrawHint("select",!0),t.redraw())}},!1),t.registerBinding(e,"touchcancel",Z=function(e){var n=t.touchData.start;t.touchData.capture=!1,n&&n.unactivate()}),t.registerBinding(e,"touchend",Y=function(e){var i=t.touchData.start;if(t.touchData.capture){0===e.touches.length&&(t.touchData.capture=!1),e.preventDefault();var a=t.selection;t.swipePanning=!1,t.hoverData.draggingEles=!1;var s,o=t.cy,l=o.zoom(),c=t.touchData.now,h=t.touchData.earlier;if(e.touches[0]){var d=t.projectIntoViewport(e.touches[0].clientX,e.touches[0].clientY);c[0]=d[0],c[1]=d[1]}if(e.touches[1]&&(d=t.projectIntoViewport(e.touches[1].clientX,e.touches[1].clientY),c[2]=d[0],c[3]=d[1]),e.touches[2]&&(d=t.projectIntoViewport(e.touches[2].clientX,e.touches[2].clientY),c[4]=d[0],c[5]=d[1]),i&&i.unactivate(),t.touchData.cxt){if(s={originalEvent:e,type:"cxttapend",position:{x:c[0],y:c[1]}},i?i.emit(s):o.emit(s),!t.touchData.cxtDragged){var p={originalEvent:e,type:"cxttap",position:{x:c[0],y:c[1]}};i?i.emit(p):o.emit(p)}return t.touchData.start&&(t.touchData.start._private.grabbed=!1),t.touchData.cxt=!1,t.touchData.start=null,void t.redraw()}if(!e.touches[2]&&o.boxSelectionEnabled()&&t.touchData.selecting){t.touchData.selecting=!1;var g=o.collection(t.getAllInBox(a[0],a[1],a[2],a[3]));a[0]=void 0,a[1]=void 0,a[2]=void 0,a[3]=void 0,a[4]=0,t.redrawHint("select",!0),o.emit({type:"boxend",originalEvent:e,position:{x:c[0],y:c[1]}}),g.emit("box").stdFilter((function(t){return t.selectable()&&!t.selected()})).select().emit("boxselect"),g.nonempty()&&t.redrawHint("eles",!0),t.redraw()}if(null!=i&&i.unactivate(),e.touches[2])t.data.bgActivePosistion=void 0,t.redrawHint("select",!0);else if(e.touches[1]);else if(e.touches[0]);else if(!e.touches[0]){t.data.bgActivePosistion=void 0,t.redrawHint("select",!0);var f=t.dragData.touchDragEles;if(null!=i){var m=i._private.grabbed;u(f),t.redrawHint("drag",!0),t.redrawHint("eles",!0),m&&(i.emit("freeon"),f.emit("free"),t.dragData.didDrag&&(i.emit("dragfreeon"),f.emit("dragfree"))),r(i,["touchend","tapend","vmouseup","tapdragout"],e,{x:c[0],y:c[1]}),i.unactivate(),t.touchData.start=null}else{var y=t.findNearestElement(c[0],c[1],!0,!0);r(y,["touchend","tapend","vmouseup","tapdragout"],e,{x:c[0],y:c[1]})}var v=t.touchData.startPosition[0]-c[0],x=v*v,b=t.touchData.startPosition[1]-c[1],w=(x+b*b)*l*l;t.touchData.singleTouchMoved||(i||o.$(":selected").unselect(["tapunselect"]),r(i,["tap","vclick"],e,{x:c[0],y:c[1]}),U=!1,e.timeStamp-V<=o.multiClickDebounceTime()?(G&&clearTimeout(G),U=!0,V=null,r(i,["dbltap","vdblclick"],e,{x:c[0],y:c[1]})):(G=setTimeout((function(){U||r(i,["onetap","voneclick"],e,{x:c[0],y:c[1]})}),o.multiClickDebounceTime()),V=e.timeStamp)),null!=i&&!t.dragData.didDrag&&i._private.selectable&&w2){for(var p=[h[0],h[1]],g=Math.pow(p[0]-t,2)+Math.pow(p[1]-e,2),f=1;f0)return f[0]}return null},p=Object.keys(u),g=0;g0?c:an(i,a,t,e,n,r,s,o)},checkPoint:function(t,e,n,r,i,a,s,o){var l=2*(o="auto"===o?Tn(r,i):o);if(un(t,e,this.points,a,s,r,i-l,[0,-1],n))return!0;if(un(t,e,this.points,a,s,r-l,i,[0,-1],n))return!0;var c=r/2+2*n,h=i/2+2*n;return!!hn(t,e,[a-c,s-h,a-c,s,a+c,s,a+c,s-h])||!!gn(t,e,l,l,a+r/2-o,s+i/2-o,n)||!!gn(t,e,l,l,a-r/2+o,s+i/2-o,n)}}},registerNodeShapes:function(){var t=this.nodeShapes={},e=this;this.generateEllipse(),this.generatePolygon("triangle",bn(3,0)),this.generateRoundPolygon("round-triangle",bn(3,0)),this.generatePolygon("rectangle",bn(4,0)),t.square=t.rectangle,this.generateRoundRectangle(),this.generateCutRectangle(),this.generateBarrel(),this.generateBottomRoundrectangle();var n=[0,1,1,0,0,-1,-1,0];this.generatePolygon("diamond",n),this.generateRoundPolygon("round-diamond",n),this.generatePolygon("pentagon",bn(5,0)),this.generateRoundPolygon("round-pentagon",bn(5,0)),this.generatePolygon("hexagon",bn(6,0)),this.generateRoundPolygon("round-hexagon",bn(6,0)),this.generatePolygon("heptagon",bn(7,0)),this.generateRoundPolygon("round-heptagon",bn(7,0)),this.generatePolygon("octagon",bn(8,0)),this.generateRoundPolygon("round-octagon",bn(8,0));var r=new Array(20),i=kn(5,0),a=kn(5,Math.PI/5),s=.5*(3-Math.sqrt(5));s*=1.57;for(var o=0;o=t.deqFastCost*f)break}else if(i){if(p>=t.deqCost*l||p>=t.deqAvgCost*o)break}else if(g>=t.deqNoDrawCost*xh)break;var m=t.deq(e,u,h);if(!(m.length>0))break;for(var y=0;y0&&(t.onDeqd(e,c),!i&&t.shouldRedraw(e,c,u,h)&&r())}),i(e))}}},wh=function(){return a((function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Qt;i(this,t),this.idsByKey=new pe,this.keyForId=new pe,this.cachesByLvl=new pe,this.lvls=[],this.getKey=e,this.doesEleInvalidateKey=n}),[{key:"getIdsFor",value:function(t){null==t&&ee("Can not get id list for null key");var e=this.idsByKey,n=this.idsByKey.get(t);return n||(n=new fe,e.set(t,n)),n}},{key:"addIdForKey",value:function(t,e){null!=t&&this.getIdsFor(t).add(e)}},{key:"deleteIdForKey",value:function(t,e){null!=t&&this.getIdsFor(t).delete(e)}},{key:"getNumberOfIdsForKey",value:function(t){return null==t?0:this.getIdsFor(t).size}},{key:"updateKeyMappingFor",value:function(t){var e=t.id(),n=this.keyForId.get(e),r=this.getKey(t);this.deleteIdForKey(n,e),this.addIdForKey(r,e),this.keyForId.set(e,r)}},{key:"deleteKeyMappingFor",value:function(t){var e=t.id(),n=this.keyForId.get(e);this.deleteIdForKey(n,e),this.keyForId.delete(e)}},{key:"keyHasChangedFor",value:function(t){var e=t.id();return this.keyForId.get(e)!==this.getKey(t)}},{key:"isInvalid",value:function(t){return this.keyHasChangedFor(t)||this.doesEleInvalidateKey(t)}},{key:"getCachesAt",value:function(t){var e=this.cachesByLvl,n=this.lvls,r=e.get(t);return r||(r=new pe,e.set(t,r),n.push(t)),r}},{key:"getCache",value:function(t,e){return this.getCachesAt(e).get(t)}},{key:"get",value:function(t,e){var n=this.getKey(t),r=this.getCache(n,e);return null!=r&&this.updateKeyMappingFor(t),r}},{key:"getForCachedKey",value:function(t,e){var n=this.keyForId.get(t.id());return this.getCache(n,e)}},{key:"hasCache",value:function(t,e){return this.getCachesAt(e).has(t)}},{key:"has",value:function(t,e){var n=this.getKey(t);return this.hasCache(n,e)}},{key:"setCache",value:function(t,e,n){n.key=t,this.getCachesAt(e).set(t,n)}},{key:"set",value:function(t,e,n){var r=this.getKey(t);this.setCache(r,e,n),this.updateKeyMappingFor(t)}},{key:"deleteCache",value:function(t,e){this.getCachesAt(e).delete(t)}},{key:"delete",value:function(t,e){var n=this.getKey(t);this.deleteCache(n,e)}},{key:"invalidateKey",value:function(t){var e=this;this.lvls.forEach((function(n){return e.deleteCache(t,n)}))}},{key:"invalidate",value:function(t){var e=t.id(),n=this.keyForId.get(e);this.deleteKeyMappingFor(t);var r=this.doesEleInvalidateKey(t);return r&&this.invalidateKey(n),r||0===this.getNumberOfIdsForKey(n)}}])}(),kh={dequeue:"dequeue",downscale:"downscale",highQuality:"highQuality"},Th=le({getKey:null,doesEleInvalidateKey:Qt,drawElement:null,getBoundingBox:null,getRotationPoint:null,getRotationOffset:null,isVisible:Kt,allowEdgeTxrCaching:!0,allowParentTxrCaching:!0}),_h=function(t,e){var n=this;n.renderer=t,n.onDequeues=[];var r=Th(e);vt(n,r),n.lookup=new wh(r.getKey,r.doesEleInvalidateKey),n.setupDequeueing()},Eh=_h.prototype;Eh.reasons=kh,Eh.getTextureQueue=function(t){var e=this;return e.eleImgCaches=e.eleImgCaches||{},e.eleImgCaches[t]=e.eleImgCaches[t]||[]},Eh.getRetiredTextureQueue=function(t){var e=this.eleImgCaches.retired=this.eleImgCaches.retired||{};return e[t]=e[t]||[]},Eh.getElementQueue=function(){return this.eleCacheQueue=this.eleCacheQueue||new _e((function(t,e){return e.reqs-t.reqs}))},Eh.getElementKeyToQueue=function(){return this.eleKeyToCacheQueue=this.eleKeyToCacheQueue||{}},Eh.getElement=function(t,e,n,r,i){var a=this,s=this.renderer,o=s.cy.zoom(),l=this.lookup;if(!e||0===e.w||0===e.h||isNaN(e.w)||isNaN(e.h)||!t.visible()||t.removed())return null;if(!a.allowEdgeTxrCaching&&t.isEdge()||!a.allowParentTxrCaching&&t.isParent())return null;if(null==r&&(r=Math.ceil(Ze(o*n))),r<-4)r=-4;else if(o>=7.99||r>3)return null;var c=Math.pow(2,r),h=e.h*c,u=e.w*c,d=s.eleTextBiggerThanMin(t,c);if(!this.isVisible(t,d))return null;var p,g=l.get(t,r);if(g&&g.invalidated&&(g.invalidated=!1,g.texture.invalidatedWidth-=g.width),g)return g;if(p=h<=25?25:h<=50?50:50*Math.ceil(h/50),h>1024||u>1024)return null;var f=a.getTextureQueue(p),m=f[f.length-2],y=function(){return a.recycleTexture(p,u)||a.addTexture(p,u)};m||(m=f[f.length-1]),m||(m=y()),m.width-m.usedWidthr;C--)E=a.getElement(t,e,n,C,kh.downscale);S()}else{var A;if(!b&&!w&&!k)for(var L=r-1;L>=-4;L--){var M=l.get(t,L);if(M){A=M;break}}if(x(A))return a.queueElement(t,r),A;m.context.translate(m.usedWidth,0),m.context.scale(c,c),this.drawElement(m.context,t,e,d,!1),m.context.scale(1/c,1/c),m.context.translate(-m.usedWidth,0)}return g={x:m.usedWidth,texture:m,level:r,scale:c,width:u,height:h,scaledLabelShown:d},m.usedWidth+=Math.ceil(u+8),m.eleCaches.push(g),l.set(t,r,g),a.checkTextureFullness(m),g},Eh.invalidateElements=function(t){for(var e=0;e=.2*t.width&&this.retireTexture(t)},Eh.checkTextureFullness=function(t){var e=this.getTextureQueue(t.height);t.usedWidth/t.width>.8&&t.fullnessChecks>=10?ce(e,t):t.fullnessChecks++},Eh.retireTexture=function(t){var e=t.height,n=this.getTextureQueue(e),r=this.lookup;ce(n,t),t.retired=!0;for(var i=t.eleCaches,a=0;a=e)return a.retired=!1,a.usedWidth=0,a.invalidatedWidth=0,a.fullnessChecks=0,he(a.eleCaches),a.context.setTransform(1,0,0,1,0,0),a.context.clearRect(0,0,a.width,a.height),ce(r,a),n.push(a),a}},Eh.queueElement=function(t,e){var n=this.getElementQueue(),r=this.getElementKeyToQueue(),i=this.getKey(t),a=r[i];if(a)a.level=Math.max(a.level,e),a.eles.merge(t),a.reqs++,n.updateItem(a);else{var s={eles:t.spawn().merge(t),level:e,reqs:1,key:i};n.push(s),r[i]=s}},Eh.dequeue=function(t){for(var e=this,n=e.getElementQueue(),r=e.getElementKeyToQueue(),i=[],a=e.lookup,s=0;s<1&&n.size()>0;s++){var o=n.pop(),l=o.key,c=o.eles[0],h=a.hasCache(c,o.level);if(r[l]=null,!h){i.push(o);var u=e.getBoundingBox(c);e.getElement(c,u,t,o.level,kh.dequeue)}}return i},Eh.removeFromQueue=function(t){var e=this.getElementQueue(),n=this.getElementKeyToQueue(),r=this.getKey(t),i=n[r];null!=i&&(1===i.eles.length?(i.reqs=Xt,e.updateItem(i),e.pop(),n[r]=null):i.eles.unmerge(t))},Eh.onDequeue=function(t){this.onDequeues.push(t)},Eh.offDequeue=function(t){ce(this.onDequeues,t)},Eh.setupDequeueing=bh({deqRedrawThreshold:100,deqCost:.15,deqAvgCost:.1,deqNoDrawCost:.9,deqFastCost:.9,deq:function(t,e,n){return t.dequeue(e,n)},onDeqd:function(t,e){for(var n=0;n=3.99||n>2)return null;r.validateLayersElesOrdering(n,t);var s,o,l=r.layersByLevel,c=Math.pow(2,n),h=l[n]=l[n]||[];if(r.levelIsComplete(n,t))return h;!function(){var e=function(e){if(r.validateLayersElesOrdering(e,t),r.levelIsComplete(e,t))return o=l[e],!0},i=function(t){if(!o)for(var r=n+t;-4<=r&&r<=2&&!e(r);r+=t);};i(1),i(-1);for(var a=h.length-1;a>=0;a--){var s=h[a];s.invalid&&ce(h,s)}}();var u=function(e){var i=(e=e||{}).after;!function(){if(!s){s=Xe();for(var e=0;e32767||o>32767)return null;if(a*o>16e6)return null;var l=r.makeLayer(s,n);if(null!=i){var u=h.indexOf(i)+1;h.splice(u,0,l)}else(void 0===e.insert||e.insert)&&h.unshift(l);return l};if(r.skipping&&!a)return null;for(var d,p,g=null,f=t.length/1,m=!a,y=0;y=f||(d=g.bb,p=v.boundingBox(),!rn(d,p.x1,p.y1)||!rn(d,p.x2,p.y2)))&&!(g=u({insert:!0,after:g})))return null;o||m?r.queueLayer(g,v):r.drawEleInLayer(g,v,n,e),g.eles.push(v),b[n]=g}}return o||(m?null:h)},Ch.getEleLevelForLayerLevel=function(t,e){return t},Ch.drawEleInLayer=function(t,e,n,r){var i=this.renderer,a=t.context,s=e.boundingBox();0!==s.w&&0!==s.h&&e.visible()&&(n=this.getEleLevelForLayerLevel(n,r),i.setImgSmoothing(a,!1),i.drawCachedElement(a,e,null,null,n,!0),i.setImgSmoothing(a,!0))},Ch.levelIsComplete=function(t,e){var n=this.layersByLevel[t];if(!n||0===n.length)return!1;for(var r=0,i=0;i0)return!1;if(a.invalid)return!1;r+=a.eles.length}return r===e.length},Ch.validateLayersElesOrdering=function(t,e){var n=this.layersByLevel[t];if(n)for(var r=0;r0){t=!0;break}}return t},Ch.invalidateElements=function(t){var e=this;0!==t.length&&(e.lastInvalidationTime=Ot(),0!==t.length&&e.haveLayers()&&e.updateElementsInLayers(t,(function(t,n,r){e.invalidateLayer(t)})))},Ch.invalidateLayer=function(t){if(this.lastInvalidationTime=Ot(),!t.invalid){var e=t.level,n=t.eles,r=this.layersByLevel[e];ce(r,t),t.elesQueue=[],t.invalid=!0,t.replacement&&(t.replacement.invalid=!0);for(var i=0;i3&&void 0!==arguments[3])||arguments[3],i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=!(arguments.length>5&&void 0!==arguments[5])||arguments[5],s=this,o=e._private.rscratch;if((!a||e.visible())&&!o.badLine&&null!=o.allpts&&!isNaN(o.allpts[0])){var l;n&&(l=n,t.translate(-l.x1,-l.y1));var c=a?e.pstyle("opacity").value:1,h=a?e.pstyle("line-opacity").value:1,u=e.pstyle("curve-style").value,d=e.pstyle("line-style").value,p=e.pstyle("width").pfValue,g=e.pstyle("line-cap").value,f=e.pstyle("line-outline-width").value,m=e.pstyle("line-outline-color").value,y=c*h,v=c*h,x=function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y;"straight-triangle"===u?(s.eleStrokeStyle(t,e,n),s.drawEdgeTrianglePath(e,t,o.allpts)):(t.lineWidth=p,t.lineCap=g,s.eleStrokeStyle(t,e,n),s.drawEdgePath(e,t,o.allpts,d),t.lineCap="butt")},b=function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:v;s.drawArrowheads(t,e,n)};if(t.lineJoin="round","yes"===e.pstyle("ghost").value){var w=e.pstyle("ghost-offset-x").pfValue,k=e.pstyle("ghost-offset-y").pfValue,T=e.pstyle("ghost-opacity").value,_=y*T;t.translate(w,k),x(_),b(_),t.translate(-w,-k)}else!function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y;t.lineWidth=p+f,t.lineCap=g,f>0?(s.colorStrokeStyle(t,m[0],m[1],m[2],n),"straight-triangle"===u?s.drawEdgeTrianglePath(e,t,o.allpts):(s.drawEdgePath(e,t,o.allpts,d),t.lineCap="butt")):t.lineCap="butt"}();i&&s.drawEdgeUnderlay(t,e),x(),b(),i&&s.drawEdgeOverlay(t,e),s.drawElementText(t,e,null,r),n&&t.translate(l.x1,l.y1)}}},Gh=function(t){if(!["overlay","underlay"].includes(t))throw new Error("Invalid state");return function(e,n){if(n.visible()){var r=n.pstyle("".concat(t,"-opacity")).value;if(0!==r){var i=this,a=i.usePaths(),s=n._private.rscratch,o=2*n.pstyle("".concat(t,"-padding")).pfValue,l=n.pstyle("".concat(t,"-color")).value;e.lineWidth=o,"self"!==s.edgeType||a?e.lineCap="round":e.lineCap="butt",i.colorStrokeStyle(e,l[0],l[1],l[2],r),i.drawEdgePath(n,e,s.allpts,"solid")}}}};Uh.drawEdgeOverlay=Gh("overlay"),Uh.drawEdgeUnderlay=Gh("underlay"),Uh.drawEdgePath=function(t,e,n,r){var i,a=t._private.rscratch,o=e,l=!1,c=this.usePaths(),h=t.pstyle("line-dash-pattern").pfValue,u=t.pstyle("line-dash-offset").pfValue;if(c){var d=n.join("$");a.pathCacheKey&&a.pathCacheKey===d?(i=e=a.pathCache,l=!0):(i=e=new Path2D,a.pathCacheKey=d,a.pathCache=i)}if(o.setLineDash)switch(r){case"dotted":o.setLineDash([1,1]);break;case"dashed":o.setLineDash(h),o.lineDashOffset=u;break;case"solid":o.setLineDash([])}if(!l&&!a.badLine)switch(e.beginPath&&e.beginPath(),e.moveTo(n[0],n[1]),a.edgeType){case"bezier":case"self":case"compound":case"multibezier":for(var p=2;p+35&&void 0!==arguments[5]?arguments[5]:5,s=arguments.length>6?arguments[6]:void 0;t.beginPath(),t.moveTo(e+a,n),t.lineTo(e+r-a,n),t.quadraticCurveTo(e+r,n,e+r,n+a),t.lineTo(e+r,n+i-a),t.quadraticCurveTo(e+r,n+i,e+r-a,n+i),t.lineTo(e+a,n+i),t.quadraticCurveTo(e,n+i,e,n+i-a),t.lineTo(e,n+a),t.quadraticCurveTo(e,n,e+a,n),t.closePath(),s?t.stroke():t.fill()}qh.eleTextBiggerThanMin=function(t,e){if(!e){var n=t.cy().zoom(),r=this.getPixelRatio(),i=Math.ceil(Ze(n*r));e=Math.pow(2,i)}return!(t.pstyle("font-size").pfValue*e5&&void 0!==arguments[5])||arguments[5],s=this;if(null==r){if(a&&!s.eleTextBiggerThanMin(e))return}else if(!1===r)return;if(e.isNode()){var o=e.pstyle("label");if(!o||!o.value)return;var l=s.getLabelJustification(e);t.textAlign=l,t.textBaseline="bottom"}else{var c=e.element()._private.rscratch.badLine,h=e.pstyle("label"),u=e.pstyle("source-label"),d=e.pstyle("target-label");if(c||(!h||!h.value)&&(!u||!u.value)&&(!d||!d.value))return;t.textAlign="center",t.textBaseline="bottom"}var p,g=!n;n&&(p=n,t.translate(-p.x1,-p.y1)),null==i?(s.drawText(t,e,null,g,a),e.isEdge()&&(s.drawText(t,e,"source",g,a),s.drawText(t,e,"target",g,a))):s.drawText(t,e,i,g,a),n&&t.translate(p.x1,p.y1)},qh.getFontCache=function(t){var e;this.fontCaches=this.fontCaches||[];for(var n=0;n2&&void 0!==arguments[2])||arguments[2],r=e.pstyle("font-style").strValue,i=e.pstyle("font-size").pfValue+"px",a=e.pstyle("font-family").strValue,s=e.pstyle("font-weight").strValue,o=n?e.effectiveOpacity()*e.pstyle("text-opacity").value:1,l=e.pstyle("text-outline-opacity").value*o,c=e.pstyle("color").value,h=e.pstyle("text-outline-color").value;t.font=r+" "+s+" "+i+" "+a,t.lineJoin="round",this.colorFillStyle(t,c[0],c[1],c[2],o),this.colorStrokeStyle(t,h[0],h[1],h[2],l)},qh.getTextAngle=function(t,e){var n,r=t._private.rscratch,i=e?e+"-":"",a=t.pstyle(i+"text-rotation");if("autorotate"===a.strValue){var s=ue(r,"labelAngle",e);n=t.isEdge()?s:0}else n="none"===a.strValue?0:a.pfValue;return n},qh.drawText=function(t,e,n){var r=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=e._private.rscratch,s=i?e.effectiveOpacity():1;if(!i||0!==s&&0!==e.pstyle("text-opacity").value){"main"===n&&(n=null);var o,l,c=ue(a,"labelX",n),h=ue(a,"labelY",n),u=this.getLabelText(e,n);if(null!=u&&""!==u&&!isNaN(c)&&!isNaN(h)){this.setupTextStyle(t,e,i);var d,p=n?n+"-":"",g=ue(a,"labelWidth",n),f=ue(a,"labelHeight",n),m=e.pstyle(p+"text-margin-x").pfValue,y=e.pstyle(p+"text-margin-y").pfValue,v=e.isEdge(),x=e.pstyle("text-halign").value,b=e.pstyle("text-valign").value;switch(v&&(x="center",b="center"),c+=m,h+=y,0!==(d=r?this.getTextAngle(e,n):0)&&(o=c,l=h,t.translate(o,l),t.rotate(d),c=0,h=0),b){case"top":break;case"center":h+=f/2;break;case"bottom":h+=f}var w=e.pstyle("text-background-opacity").value,k=e.pstyle("text-border-opacity").value,T=e.pstyle("text-border-width").pfValue,_=e.pstyle("text-background-padding").pfValue,E=0===e.pstyle("text-background-shape").strValue.indexOf("round");if(w>0||T>0&&k>0){var S=c-_;switch(x){case"left":S-=g;break;case"center":S-=g/2}var C=h-f-_,A=g+2*_,L=f+2*_;if(w>0){var M=t.fillStyle,N=e.pstyle("text-background-color").value;t.fillStyle="rgba("+N[0]+","+N[1]+","+N[2]+","+w*s+")",E?jh(t,S,C,A,L,2):t.fillRect(S,C,A,L),t.fillStyle=M}if(T>0&&k>0){var I=t.strokeStyle,R=t.lineWidth,D=e.pstyle("text-border-color").value,O=e.pstyle("text-border-style").value;if(t.strokeStyle="rgba("+D[0]+","+D[1]+","+D[2]+","+k*s+")",t.lineWidth=T,t.setLineDash)switch(O){case"dotted":t.setLineDash([1,1]);break;case"dashed":t.setLineDash([4,2]);break;case"double":t.lineWidth=T/4,t.setLineDash([]);break;case"solid":t.setLineDash([])}if(E?jh(t,S,C,A,L,2,"stroke"):t.strokeRect(S,C,A,L),"double"===O){var P=T/2;E?jh(t,S+P,C+P,A-2*P,L-2*P,2,"stroke"):t.strokeRect(S+P,C+P,A-2*P,L-2*P)}t.setLineDash&&t.setLineDash([]),t.lineWidth=R,t.strokeStyle=I}}var $=2*e.pstyle("text-outline-width").pfValue;if($>0&&(t.lineWidth=$),"wrap"===e.pstyle("text-wrap").value){var B=ue(a,"labelWrapCachedLines",n),F=ue(a,"labelLineHeight",n),W=g/2,z=this.getLabelJustification(e);switch("auto"===z||("left"===x?"left"===z?c+=-g:"center"===z&&(c+=-W):"center"===x?"left"===z?c+=-W:"right"===z&&(c+=W):"right"===x&&("center"===z?c+=W:"right"===z&&(c+=g))),b){case"top":case"center":case"bottom":h-=(B.length-1)*F}for(var Z=0;Z0&&t.strokeText(B[Z],c,h),t.fillText(B[Z],c,h),h+=F}else $>0&&t.strokeText(u,c,h),t.fillText(u,c,h);0!==d&&(t.rotate(-d),t.translate(-o,-l))}}};var Hh={drawNode:function(t,e,n){var r,i,a=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],s=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],o=!(arguments.length>5&&void 0!==arguments[5])||arguments[5],l=this,c=e._private,h=c.rscratch,u=e.position();if(Q(u.x)&&Q(u.y)&&(!o||e.visible())){var d,p,g=o?e.effectiveOpacity():1,f=l.usePaths(),m=!1,y=e.padding();r=e.width()+2*y,i=e.height()+2*y,n&&(p=n,t.translate(-p.x1,-p.y1));for(var v=e.pstyle("background-image").value,x=new Array(v.length),b=new Array(v.length),w=0,k=0;k0&&void 0!==arguments[0]?arguments[0]:C;l.eleFillStyle(t,e,n)},Y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O;l.colorStrokeStyle(t,A[0],A[1],A[2],e)},U=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:F;l.colorStrokeStyle(t,$[0],$[1],$[2],e)},G=function(t,e,n,r){var i,a=l.nodePathCache=l.nodePathCache||[],s=Gt("polygon"===n?n+","+r.join(","):n,""+e,""+t,""+z),o=a[s],c=!1;return null!=o?(i=o,c=!0,h.pathCache=i):(i=new Path2D,a[s]=h.pathCache=i),{path:i,cacheHit:c}},V=e.pstyle("shape").strValue,q=e.pstyle("shape-polygon-points").pfValue;if(f){t.translate(u.x,u.y);var j=G(r,i,V,q);d=j.path,m=j.cacheHit}var H=function(){if(!m){var n=u;f&&(n={x:0,y:0}),l.nodeShapes[l.getNodeShape(e)].draw(d||t,n.x,n.y,r,i,z,h)}f?t.fill(d):t.fill()},X=function(){for(var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g,r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],i=c.backgrounding,a=0,s=0;s0&&void 0!==arguments[0]&&arguments[0],a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g;l.hasPie(e)&&(l.drawPie(t,e,a),n&&(f||l.nodeShapes[l.getNodeShape(e)].draw(t,u.x,u.y,r,i,z,h)))},J=function(){var n=arguments.length>0&&void 0!==arguments[0]&&arguments[0],a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g;l.hasStripe(e)&&(t.save(),f?t.clip(h.pathCache):(l.nodeShapes[l.getNodeShape(e)].draw(t,u.x,u.y,r,i,z,h),t.clip()),l.drawStripe(t,e,a),t.restore(),n&&(f||l.nodeShapes[l.getNodeShape(e)].draw(t,u.x,u.y,r,i,z,h)))},tt=function(){var e=(E>0?E:-E)*(arguments.length>0&&void 0!==arguments[0]?arguments[0]:g),n=E>0?0:255;0!==E&&(l.colorFillStyle(t,n,n,n,e),f?t.fill(d):t.fill())},et=function(){if(S>0){if(t.lineWidth=S,t.lineCap=N,t.lineJoin=M,t.setLineDash)switch(L){case"dotted":t.setLineDash([1,1]);break;case"dashed":t.setLineDash(R),t.lineDashOffset=D;break;case"solid":case"double":t.setLineDash([])}if("center"!==I){if(t.save(),t.lineWidth*=2,"inside"===I)f?t.clip(d):t.clip();else{var e=new Path2D;e.rect(-r/2-S,-i/2-S,r+2*S,i+2*S),e.addPath(d),t.clip(e,"evenodd")}f?t.stroke(d):t.stroke(),t.restore()}else f?t.stroke(d):t.stroke();if("double"===L){t.lineWidth=S/3;var n=t.globalCompositeOperation;t.globalCompositeOperation="destination-out",f?t.stroke(d):t.stroke(),t.globalCompositeOperation=n}t.setLineDash&&t.setLineDash([])}},nt=function(){if(P>0){if(t.lineWidth=P,t.lineCap="butt",t.setLineDash)switch(B){case"dotted":t.setLineDash([1,1]);break;case"dashed":t.setLineDash([4,2]);break;case"solid":case"double":t.setLineDash([])}var n=u;f&&(n={x:0,y:0});var a=l.getNodeShape(e),s=S;"inside"===I&&(s=0),"outside"===I&&(s*=2);var o,c=(r+s+(P+W))/r,h=(i+s+(P+W))/i,d=r*c,p=i*h,g=l.nodeShapes[a].points;if(f&&(o=G(d,p,a,g).path),"ellipse"===a)l.drawEllipsePath(o||t,n.x,n.y,d,p);else if(["round-diamond","round-heptagon","round-hexagon","round-octagon","round-pentagon","round-polygon","round-triangle","round-tag"].includes(a)){var m=0,y=0,v=0;"round-diamond"===a?m=1.4*(s+W+P):"round-heptagon"===a?(m=1.075*(s+W+P),v=-(s/2+W+P)/35):"round-hexagon"===a?m=1.12*(s+W+P):"round-pentagon"===a?(m=1.13*(s+W+P),v=-(s/2+W+P)/15):"round-tag"===a?(m=1.12*(s+W+P),y=.07*(s/2+P+W)):"round-triangle"===a&&(m=(s+W+P)*(Math.PI/2),v=-(s+W/2+P)/Math.PI),0!==m&&(d=r*(c=(r+m)/r),["round-hexagon","round-tag"].includes(a)||(p=i*(h=(i+m)/i)));for(var x=d/2,b=p/2,w=(z="auto"===z?_n(d,p):z)+(s+P+W)/2,k=new Array(g.length/2),T=new Array(g.length/2),_=0;_0){if(r=r||n.position(),null==i||null==a){var u=n.padding();i=n.width()+2*u,a=n.height()+2*u}this.colorFillStyle(e,l[0],l[1],l[2],o),this.nodeShapes[c].draw(e,r.x,r.y,i+2*s,a+2*s,h),e.fill()}}}};Hh.drawNodeOverlay=Xh("overlay"),Hh.drawNodeUnderlay=Xh("underlay"),Hh.hasPie=function(t){return(t=t[0])._private.hasPie},Hh.hasStripe=function(t){return(t=t[0])._private.hasStripe},Hh.drawPie=function(t,e,n,r){e=e[0],r=r||e.position();var i,a=e.cy().style(),s=e.pstyle("pie-size"),o=e.pstyle("pie-hole"),l=e.pstyle("pie-start-angle").pfValue,c=r.x,h=r.y,u=e.width(),d=e.height(),p=Math.min(u,d)/2,g=0;if(this.usePaths()&&(c=0,h=0),"%"===s.units?p*=s.pfValue:void 0!==s.pfValue&&(p=s.pfValue/2),"%"===o.units?i=p*o.pfValue:void 0!==o.pfValue&&(i=o.pfValue/2),!(i>=p))for(var f=1;f<=a.pieBackgroundN;f++){var m=e.pstyle("pie-"+f+"-background-size").value,y=e.pstyle("pie-"+f+"-background-color").value,v=e.pstyle("pie-"+f+"-background-opacity").value*n,x=m/100;x+g>1&&(x=1-g);var b=1.5*Math.PI+2*Math.PI*g,w=(b+=l)+2*Math.PI*x;0===m||g>=1||g+x>1||(0===i?(t.beginPath(),t.moveTo(c,h),t.arc(c,h,p,b,w),t.closePath()):(t.beginPath(),t.arc(c,h,p,b,w),t.arc(c,h,i,w,b,!0),t.closePath()),this.colorFillStyle(t,y[0],y[1],y[2],v),t.fill(),g+=x)}},Hh.drawStripe=function(t,e,n,r){e=e[0],r=r||e.position();var i=e.cy().style(),a=r.x,s=r.y,o=e.width(),l=e.height(),c=0,h=this.usePaths();t.save();var u=e.pstyle("stripe-direction").value,d=e.pstyle("stripe-size");switch(u){case"vertical":break;case"righward":t.rotate(-Math.PI/2)}var p=o,g=l;"%"===d.units?(p*=d.pfValue,g*=d.pfValue):void 0!==d.pfValue&&(p=d.pfValue,g=d.pfValue),h&&(a=0,s=0),s-=p/2,a-=g/2;for(var f=1;f<=i.stripeBackgroundN;f++){var m=e.pstyle("stripe-"+f+"-background-size").value,y=e.pstyle("stripe-"+f+"-background-color").value,v=e.pstyle("stripe-"+f+"-background-opacity").value*n,x=m/100;x+c>1&&(x=1-c),0===m||c>=1||c+x>1||(t.beginPath(),t.rect(a,s+g*c,p,g*x),t.closePath(),this.colorFillStyle(t,y[0],y[1],y[2],v),t.fill(),c+=x)}t.restore()};var Kh,Qh={};function Jh(t,e,n){var r=t.createShader(e);if(t.shaderSource(r,n),t.compileShader(r),!t.getShaderParameter(r,t.COMPILE_STATUS))throw new Error(t.getShaderInfoLog(r));return r}function tu(t,e,n){void 0===n&&(n=e);var r=t.makeOffscreenCanvas(e,n),i=r.context=r.getContext("2d");return r.clear=function(){return i.clearRect(0,0,r.width,r.height)},r.clear(),r}function eu(t){var e=t.pixelRatio,n=t.cy.zoom(),r=t.cy.pan();return{zoom:n*e,pan:{x:r.x*e,y:r.y*e}}}function nu(t){return"solid"===t.pstyle("background-fill").value&&"none"===t.pstyle("background-image").strValue&&(0===t.pstyle("border-width").value||0===t.pstyle("border-opacity").value||"solid"===t.pstyle("border-style").value)}function ru(t,e){if(t.length!==e.length)return!1;for(var n=0;n>0&255)/255,n[1]=(t>>8&255)/255,n[2]=(t>>16&255)/255,n[3]=(t>>24&255)/255,n}function su(t,e){switch(e){case"float":return[1,t.FLOAT,4];case"vec2":return[2,t.FLOAT,4];case"vec3":return[3,t.FLOAT,4];case"vec4":return[4,t.FLOAT,4];case"int":return[1,t.INT,4];case"ivec2":return[2,t.INT,4]}}function ou(t,e,n){switch(e){case t.FLOAT:return new Float32Array(n);case t.INT:return new Int32Array(n)}}function lu(t,e,n,r,i,a){switch(e){case t.FLOAT:return new Float32Array(n.buffer,a*r,i);case t.INT:return new Int32Array(n.buffer,a*r,i)}}function cu(t,e,n,r){var i=l(su(t,n),3),a=i[0],s=i[1],o=i[2],c=ou(t,s,e*a),h=a*o,u=t.createBuffer();t.bindBuffer(t.ARRAY_BUFFER,u),t.bufferData(t.ARRAY_BUFFER,e*h,t.DYNAMIC_DRAW),t.enableVertexAttribArray(r),s===t.FLOAT?t.vertexAttribPointer(r,a,s,!1,h,0):s===t.INT&&t.vertexAttribIPointer(r,a,s,h,0),t.vertexAttribDivisor(r,1),t.bindBuffer(t.ARRAY_BUFFER,null);for(var d=new Array(e),p=0;pe.minMbLowQualFrames&&(e.motionBlurPxRatio=e.mbPxRBlurry)),e.clearingMotionBlur&&(e.motionBlurPxRatio=1),e.textureDrawLastFrame&&!u&&(h[e.NODE]=!0,h[e.SELECT_BOX]=!0);var v=n.style(),x=n.zoom(),b=void 0!==s?s:x,w=n.pan(),k={x:w.x,y:w.y},T={zoom:x,pan:{x:w.x,y:w.y}},_=e.prevViewport;void 0===_||T.zoom!==_.zoom||T.pan.x!==_.pan.x||T.pan.y!==_.pan.y||f&&!g||(e.motionBlurPxRatio=1),o&&(k=o),b*=l,k.x*=l,k.y*=l;var E=e.getCachedZSortedEles();function S(t,n,r,i,a){var s=t.globalCompositeOperation;t.globalCompositeOperation="destination-out",e.colorFillStyle(t,255,255,255,e.motionBlurTransparency),t.fillRect(n,r,i,a),t.globalCompositeOperation=s}function C(t,n){var a,l,h,u;e.clearingMotionBlur||t!==c.bufferContexts[e.MOTIONBLUR_BUFFER_NODE]&&t!==c.bufferContexts[e.MOTIONBLUR_BUFFER_DRAG]?(a=k,l=b,h=e.canvasWidth,u=e.canvasHeight):(a={x:w.x*p,y:w.y*p},l=x*p,h=e.canvasWidth*p,u=e.canvasHeight*p),t.setTransform(1,0,0,1,0,0),"motionBlur"===n?S(t,0,0,h,u):r||void 0!==n&&!n||t.clearRect(0,0,h,u),i||(t.translate(a.x,a.y),t.scale(l,l)),o&&t.translate(o.x,o.y),s&&t.scale(s,s)}if(u||(e.textureDrawLastFrame=!1),u){if(e.textureDrawLastFrame=!0,!e.textureCache){e.textureCache={},e.textureCache.bb=n.mutableElements().boundingBox(),e.textureCache.texture=e.data.bufferCanvases[e.TEXTURE_BUFFER];var A=e.data.bufferContexts[e.TEXTURE_BUFFER];A.setTransform(1,0,0,1,0,0),A.clearRect(0,0,e.canvasWidth*e.textureMult,e.canvasHeight*e.textureMult),e.render({forcedContext:A,drawOnlyNodeLayer:!0,forcedPxRatio:l*e.textureMult}),(T=e.textureCache.viewport={zoom:n.zoom(),pan:n.pan(),width:e.canvasWidth,height:e.canvasHeight}).mpan={x:(0-T.pan.x)/T.zoom,y:(0-T.pan.y)/T.zoom}}h[e.DRAG]=!1,h[e.NODE]=!1;var L=c.contexts[e.NODE],M=e.textureCache.texture;T=e.textureCache.viewport,L.setTransform(1,0,0,1,0,0),d?S(L,0,0,T.width,T.height):L.clearRect(0,0,T.width,T.height);var N=v.core("outside-texture-bg-color").value,I=v.core("outside-texture-bg-opacity").value;e.colorFillStyle(L,N[0],N[1],N[2],I),L.fillRect(0,0,T.width,T.height),x=n.zoom(),C(L,!1),L.clearRect(T.mpan.x,T.mpan.y,T.width/T.zoom/l,T.height/T.zoom/l),L.drawImage(M,T.mpan.x,T.mpan.y,T.width/T.zoom/l,T.height/T.zoom/l)}else e.textureOnViewport&&!r&&(e.textureCache=null);var R=n.extent(),D=e.pinching||e.hoverData.dragging||e.swipePanning||e.data.wheelZooming||e.hoverData.draggingEles||e.cy.animated(),O=e.hideEdgesOnViewport&&D,P=[];if(P[e.NODE]=!h[e.NODE]&&d&&!e.clearedForMotionBlur[e.NODE]||e.clearingMotionBlur,P[e.NODE]&&(e.clearedForMotionBlur[e.NODE]=!0),P[e.DRAG]=!h[e.DRAG]&&d&&!e.clearedForMotionBlur[e.DRAG]||e.clearingMotionBlur,P[e.DRAG]&&(e.clearedForMotionBlur[e.DRAG]=!0),h[e.NODE]||i||a||P[e.NODE]){var $=d&&!P[e.NODE]&&1!==p;C(L=r||($?e.data.bufferContexts[e.MOTIONBLUR_BUFFER_NODE]:c.contexts[e.NODE]),d&&!$?"motionBlur":void 0),O?e.drawCachedNodes(L,E.nondrag,l,R):e.drawLayeredElements(L,E.nondrag,l,R),e.debug&&e.drawDebugPoints(L,E.nondrag),i||d||(h[e.NODE]=!1)}if(!a&&(h[e.DRAG]||i||P[e.DRAG])&&($=d&&!P[e.DRAG]&&1!==p,C(L=r||($?e.data.bufferContexts[e.MOTIONBLUR_BUFFER_DRAG]:c.contexts[e.DRAG]),d&&!$?"motionBlur":void 0),O?e.drawCachedNodes(L,E.drag,l,R):e.drawCachedElements(L,E.drag,l,R),e.debug&&e.drawDebugPoints(L,E.drag),i||d||(h[e.DRAG]=!1)),this.drawSelectionRectangle(t,C),d&&1!==p){var B=c.contexts[e.NODE],F=e.data.bufferCanvases[e.MOTIONBLUR_BUFFER_NODE],W=c.contexts[e.DRAG],z=e.data.bufferCanvases[e.MOTIONBLUR_BUFFER_DRAG],Z=function(t,n,r){t.setTransform(1,0,0,1,0,0),r||!y?t.clearRect(0,0,e.canvasWidth,e.canvasHeight):S(t,0,0,e.canvasWidth,e.canvasHeight);var i=p;t.drawImage(n,0,0,e.canvasWidth*i,e.canvasHeight*i,0,0,e.canvasWidth,e.canvasHeight)};(h[e.NODE]||P[e.NODE])&&(Z(B,F,P[e.NODE]),h[e.NODE]=!1),(h[e.DRAG]||P[e.DRAG])&&(Z(W,z,P[e.DRAG]),h[e.DRAG]=!1)}e.prevViewport=T,e.clearingMotionBlur&&(e.clearingMotionBlur=!1,e.motionBlurCleared=!0,e.motionBlur=!0),d&&(e.motionBlurTimeout=setTimeout((function(){e.motionBlurTimeout=null,e.clearedForMotionBlur[e.NODE]=!1,e.clearedForMotionBlur[e.DRAG]=!1,e.motionBlur=!1,e.clearingMotionBlur=!u,e.mbFrames=0,h[e.NODE]=!0,h[e.DRAG]=!0,e.redraw()}),100)),r||n.emit("render")},Qh.drawSelectionRectangle=function(t,e){var n=this,r=n.cy,i=n.data,a=r.style(),s=t.drawOnlyNodeLayer,o=t.drawAllLayers,l=i.canvasNeedsRedraw,c=t.forcedContext;if(n.showFps||!s&&l[n.SELECT_BOX]&&!o){var h=c||i.contexts[n.SELECT_BOX];if(e(h),1==n.selection[4]&&(n.hoverData.selecting||n.touchData.selecting)){var u=n.cy.zoom(),d=a.core("selection-box-border-width").value/u;h.lineWidth=d,h.fillStyle="rgba("+a.core("selection-box-color").value[0]+","+a.core("selection-box-color").value[1]+","+a.core("selection-box-color").value[2]+","+a.core("selection-box-opacity").value+")",h.fillRect(n.selection[0],n.selection[1],n.selection[2]-n.selection[0],n.selection[3]-n.selection[1]),d>0&&(h.strokeStyle="rgba("+a.core("selection-box-border-color").value[0]+","+a.core("selection-box-border-color").value[1]+","+a.core("selection-box-border-color").value[2]+","+a.core("selection-box-opacity").value+")",h.strokeRect(n.selection[0],n.selection[1],n.selection[2]-n.selection[0],n.selection[3]-n.selection[1]))}if(i.bgActivePosistion&&!n.hoverData.selecting){u=n.cy.zoom();var p=i.bgActivePosistion;h.fillStyle="rgba("+a.core("active-bg-color").value[0]+","+a.core("active-bg-color").value[1]+","+a.core("active-bg-color").value[2]+","+a.core("active-bg-opacity").value+")",h.beginPath(),h.arc(p.x,p.y,a.core("active-bg-size").pfValue/u,0,2*Math.PI),h.fill()}var g=n.lastRedrawTime;if(n.showFps&&g){g=Math.round(g);var f=Math.round(1e3/g),m="1 frame = "+g+" ms = "+f+" fps";if(h.setTransform(1,0,0,1,0,0),h.fillStyle="rgba(255, 0, 0, 0.75)",h.strokeStyle="rgba(255, 0, 0, 0.75)",h.font="30px Arial",!Kh){var y=h.measureText(m);Kh=y.actualBoundingBoxAscent}h.fillText(m,0,Kh),h.strokeRect(0,Kh+10,250,20),h.fillRect(0,Kh+10,250*Math.min(f/60,1),20)}o||(l[n.SELECT_BOX]=!1)}};var hu="undefined"!=typeof Float32Array?Float32Array:Array;function uu(){var t=new hu(9);return hu!=Float32Array&&(t[1]=0,t[2]=0,t[3]=0,t[5]=0,t[6]=0,t[7]=0),t[0]=1,t[4]=1,t[8]=1,t}function du(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}function pu(t,e,n){var r=e[0],i=e[1],a=e[2],s=e[3],o=e[4],l=e[5],c=e[6],h=e[7],u=e[8],d=n[0],p=n[1];return t[0]=r,t[1]=i,t[2]=a,t[3]=s,t[4]=o,t[5]=l,t[6]=d*r+p*s+c,t[7]=d*i+p*o+h,t[8]=d*a+p*l+u,t}function gu(t,e,n){var r=e[0],i=e[1],a=e[2],s=e[3],o=e[4],l=e[5],c=e[6],h=e[7],u=e[8],d=Math.sin(n),p=Math.cos(n);return t[0]=p*r+d*s,t[1]=p*i+d*o,t[2]=p*a+d*l,t[3]=p*s-d*r,t[4]=p*o-d*i,t[5]=p*l-d*a,t[6]=c,t[7]=h,t[8]=u,t}function fu(t,e,n){var r=n[0],i=n[1];return t[0]=r*e[0],t[1]=r*e[1],t[2]=r*e[2],t[3]=i*e[3],t[4]=i*e[4],t[5]=i*e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t}Math.hypot||(Math.hypot=function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)});var mu=function(){return a((function t(e,n,r,a){i(this,t),this.debugID=Math.floor(1e4*Math.random()),this.r=e,this.texSize=n,this.texRows=r,this.texHeight=Math.floor(n/r),this.enableWrapping=!0,this.locked=!1,this.texture=null,this.needsBuffer=!0,this.freePointer={x:0,row:0},this.keyToLocation=new Map,this.canvas=a(e,n,n),this.scratch=a(e,n,this.texHeight,"scratch")}),[{key:"lock",value:function(){this.locked=!0}},{key:"getKeys",value:function(){return new Set(this.keyToLocation.keys())}},{key:"getScale",value:function(t){var e=t.w,n=t.h,r=this.texHeight,i=this.texSize,a=r/n,s=e*a,o=n*a;return s>i&&(s=e*(a=i/e),o=n*a),{scale:a,texW:s,texH:o}}},{key:"draw",value:function(t,e,n){var r=this;if(this.locked)throw new Error("can't draw, atlas is locked");var i=this.texSize,a=this.texRows,s=this.texHeight,o=this.getScale(e),l=o.scale,c=o.texW,h=o.texH,u=function(t,r){if(n&&r){var i=r.context,a=t.x,o=t.row,c=a,h=s*o;i.save(),i.translate(c,h),i.scale(l,l),n(i,e),i.restore()}},d=[null,null],p=function(){u(r.freePointer,r.canvas),d[0]={x:r.freePointer.x,y:r.freePointer.row*s,w:c,h},d[1]={x:r.freePointer.x+c,y:r.freePointer.row*s,w:0,h},r.freePointer.x+=c,r.freePointer.x==i&&(r.freePointer.x=0,r.freePointer.row++)},g=function(){r.freePointer.x=0,r.freePointer.row++};if(this.freePointer.x+c<=i)p();else{if(this.freePointer.row>=a-1)return!1;this.freePointer.x===i?(g(),p()):this.enableWrapping?function(){var t=r.scratch,e=r.canvas;t.clear(),u({x:0,row:0},t);var n=i-r.freePointer.x,a=c-n,o=s,l=r.freePointer.x,p=r.freePointer.row*s,g=n;e.context.drawImage(t,0,0,g,o,l,p,g,o),d[0]={x:l,y:p,w:g,h};var f=n,m=(r.freePointer.row+1)*s,y=a;e&&e.context.drawImage(t,f,0,y,o,0,m,y,o),d[1]={x:0,y:m,w:y,h},r.freePointer.x=a,r.freePointer.row++}():(g(),p())}return this.keyToLocation.set(t,d),this.needsBuffer=!0,d}},{key:"getOffsets",value:function(t){return this.keyToLocation.get(t)}},{key:"isEmpty",value:function(){return 0===this.freePointer.x&&0===this.freePointer.row}},{key:"canFit",value:function(t){if(this.locked)return!1;var e=this.texSize,n=this.texRows,r=this.getScale(t).texW;return!(this.freePointer.x+r>e)||this.freePointer.row1&&void 0!==arguments[1]?arguments[1]:{},i=r.forceRedraw,a=void 0!==i&&i,o=r.filterEle,l=void 0===o?function(){return!0}:o,c=r.filterType,h=void 0===c?function(){return!0}:c,u=!1,d=!1,p=s(t);try{for(p.s();!(e=p.n()).done;){var g=e.value;if(l(g)){var f,m=s(this.renderTypes.values());try{var y=function(){var t=f.value,e=t.type;if(h(e)){var r=n.collections.get(t.collection),i=t.getKey(g),s=Array.isArray(i)?i:[i];if(a)s.forEach((function(t){return r.markKeyForGC(t)})),d=!0;else{var o=t.getID?t.getID(g):g.id(),l=n._key(e,o),c=n.typeAndIdToKey.get(l);void 0===c||ru(s,c)||(u=!0,n.typeAndIdToKey.delete(l),c.forEach((function(t){return r.markKeyForGC(t)})))}}};for(m.s();!(f=m.n()).done;)y()}catch(t){m.e(t)}finally{m.f()}}}}catch(t){p.e(t)}finally{p.f()}return d&&(this.gc(),u=!1),u}},{key:"gc",value:function(){var t,e=s(this.collections.values());try{for(e.s();!(t=e.n()).done;)t.value.gc()}catch(t){e.e(t)}finally{e.f()}}},{key:"getOrCreateAtlas",value:function(t,e,n,r){var i=this.renderTypes.get(e),a=this.collections.get(i.collection),s=!1,o=a.draw(r,n,(function(e){i.drawClipped?(e.save(),e.beginPath(),e.rect(0,0,n.w,n.h),e.clip(),i.drawElement(e,t,n,!0,!0),e.restore()):i.drawElement(e,t,n,!0,!0),s=!0}));if(s){var l=i.getID?i.getID(t):t.id(),c=this._key(e,l);this.typeAndIdToKey.has(c)?this.typeAndIdToKey.get(c).push(r):this.typeAndIdToKey.set(c,[r])}return o}},{key:"getAtlasInfo",value:function(t,e){var n=this,r=this.renderTypes.get(e),i=r.getKey(t);return(Array.isArray(i)?i:[i]).map((function(i){var a=r.getBoundingBox(t,i),s=n.getOrCreateAtlas(t,e,a,i),o=l(s.getOffsets(i),2),c=o[0];return{atlas:s,tex:c,tex1:c,tex2:o[1],bb:a}}))}},{key:"getDebugInfo",value:function(){var t,e=[],n=s(this.collections);try{for(n.s();!(t=n.n()).done;){var r=l(t.value,2),i=r[0],a=r[1].getCounts(),o=a.keyCount,c=a.atlasCount;e.push({type:i,keyCount:o,atlasCount:c})}}catch(t){n.e(t)}finally{n.f()}return e}}])}(),xu=function(){return a((function t(e){i(this,t),this.globalOptions=e,this.atlasSize=e.webglTexSize,this.maxAtlasesPerBatch=e.webglTexPerBatch,this.batchAtlases=[]}),[{key:"getMaxAtlasesPerBatch",value:function(){return this.maxAtlasesPerBatch}},{key:"getAtlasSize",value:function(){return this.atlasSize}},{key:"getIndexArray",value:function(){return Array.from({length:this.maxAtlasesPerBatch},(function(t,e){return e}))}},{key:"startBatch",value:function(){this.batchAtlases=[]}},{key:"getAtlasCount",value:function(){return this.batchAtlases.length}},{key:"getAtlases",value:function(){return this.batchAtlases}},{key:"canAddToCurrentBatch",value:function(t){return this.batchAtlases.length!==this.maxAtlasesPerBatch||this.batchAtlases.includes(t)}},{key:"getAtlasIndexForBatch",value:function(t){var e=this.batchAtlases.indexOf(t);if(e<0){if(this.batchAtlases.length===this.maxAtlasesPerBatch)throw new Error("cannot add more atlases to batch");this.batchAtlases.push(t),e=this.batchAtlases.length-1}return e}}])}(),bu={SCREEN:{name:"screen",screen:!0},PICKING:{name:"picking",picking:!0}},wu=function(){return a((function t(e,n,r){i(this,t),this.r=e,this.gl=n,this.maxInstances=r.webglBatchSize,this.atlasSize=r.webglTexSize,this.bgColor=r.bgColor,this.debug=r.webglDebug,this.batchDebugInfo=[],r.enableWrapping=!0,r.createTextureCanvas=tu,this.atlasManager=new vu(e,r),this.batchManager=new xu(r),this.simpleShapeOptions=new Map,this.program=this._createShaderProgram(bu.SCREEN),this.pickingProgram=this._createShaderProgram(bu.PICKING),this.vao=this._createVAO()}),[{key:"addAtlasCollection",value:function(t,e){this.atlasManager.addAtlasCollection(t,e)}},{key:"addTextureAtlasRenderType",value:function(t,e){this.atlasManager.addRenderType(t,e)}},{key:"addSimpleShapeRenderType",value:function(t,e){this.simpleShapeOptions.set(t,e)}},{key:"invalidate",value:function(t){var e=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).type,n=this.atlasManager;return e?n.invalidate(t,{filterType:function(t){return t===e},forceRedraw:!0}):n.invalidate(t)}},{key:"gc",value:function(){this.atlasManager.gc()}},{key:"_createShaderProgram",value:function(t){var e=this.gl,n="#version 300 es\n precision highp float;\n\n uniform mat3 uPanZoomMatrix;\n uniform int uAtlasSize;\n \n // instanced\n in vec2 aPosition; // a vertex from the unit square\n \n in mat3 aTransform; // used to transform verticies, eg into a bounding box\n in int aVertType; // the type of thing we are rendering\n\n // the z-index that is output when using picking mode\n in vec4 aIndex;\n \n // For textures\n in int aAtlasId; // which shader unit/atlas to use\n in vec4 aTex; // x/y/w/h of texture in atlas\n\n // for edges\n in vec4 aPointAPointB;\n in vec4 aPointCPointD;\n in vec2 aLineWidth; // also used for node border width\n\n // simple shapes\n in vec4 aCornerRadius; // for round-rectangle [top-right, bottom-right, top-left, bottom-left]\n in vec4 aColor; // also used for edges\n in vec4 aBorderColor; // aLineWidth is used for border width\n\n // output values passed to the fragment shader\n out vec2 vTexCoord;\n out vec4 vColor;\n out vec2 vPosition;\n // flat values are not interpolated\n flat out int vAtlasId; \n flat out int vVertType;\n flat out vec2 vTopRight;\n flat out vec2 vBotLeft;\n flat out vec4 vCornerRadius;\n flat out vec4 vBorderColor;\n flat out vec2 vBorderWidth;\n flat out vec4 vIndex;\n \n void main(void) {\n int vid = gl_VertexID;\n vec2 position = aPosition; // TODO make this a vec3, simplifies some code below\n\n if(aVertType == ".concat(0,") {\n float texX = aTex.x; // texture coordinates\n float texY = aTex.y;\n float texW = aTex.z;\n float texH = aTex.w;\n\n if(vid == 1 || vid == 2 || vid == 4) {\n texX += texW;\n }\n if(vid == 2 || vid == 4 || vid == 5) {\n texY += texH;\n }\n\n float d = float(uAtlasSize);\n vTexCoord = vec2(texX / d, texY / d); // tex coords must be between 0 and 1\n\n gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0);\n }\n else if(aVertType == ").concat(4," || aVertType == ").concat(7," \n || aVertType == ").concat(5," || aVertType == ").concat(6,") { // simple shapes\n\n // the bounding box is needed by the fragment shader\n vBotLeft = (aTransform * vec3(0, 0, 1)).xy; // flat\n vTopRight = (aTransform * vec3(1, 1, 1)).xy; // flat\n vPosition = (aTransform * vec3(position, 1)).xy; // will be interpolated\n\n // calculations are done in the fragment shader, just pass these along\n vColor = aColor;\n vCornerRadius = aCornerRadius;\n vBorderColor = aBorderColor;\n vBorderWidth = aLineWidth;\n\n gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0);\n }\n else if(aVertType == ").concat(1,") {\n vec2 source = aPointAPointB.xy;\n vec2 target = aPointAPointB.zw;\n\n // adjust the geometry so that the line is centered on the edge\n position.y = position.y - 0.5;\n\n // stretch the unit square into a long skinny rectangle\n vec2 xBasis = target - source;\n vec2 yBasis = normalize(vec2(-xBasis.y, xBasis.x));\n vec2 point = source + xBasis * position.x + yBasis * aLineWidth[0] * position.y;\n\n gl_Position = vec4(uPanZoomMatrix * vec3(point, 1.0), 1.0);\n vColor = aColor;\n } \n else if(aVertType == ").concat(2,") {\n vec2 pointA = aPointAPointB.xy;\n vec2 pointB = aPointAPointB.zw;\n vec2 pointC = aPointCPointD.xy;\n vec2 pointD = aPointCPointD.zw;\n\n // adjust the geometry so that the line is centered on the edge\n position.y = position.y - 0.5;\n\n vec2 p0, p1, p2, pos;\n if(position.x == 0.0) { // The left side of the unit square\n p0 = pointA;\n p1 = pointB;\n p2 = pointC;\n pos = position;\n } else { // The right side of the unit square, use same approach but flip the geometry upside down\n p0 = pointD;\n p1 = pointC;\n p2 = pointB;\n pos = vec2(0.0, -position.y);\n }\n\n vec2 p01 = p1 - p0;\n vec2 p12 = p2 - p1;\n vec2 p21 = p1 - p2;\n\n // Find the normal vector.\n vec2 tangent = normalize(normalize(p12) + normalize(p01));\n vec2 normal = vec2(-tangent.y, tangent.x);\n\n // Find the vector perpendicular to p0 -> p1.\n vec2 p01Norm = normalize(vec2(-p01.y, p01.x));\n\n // Determine the bend direction.\n float sigma = sign(dot(p01 + p21, normal));\n float width = aLineWidth[0];\n\n if(sign(pos.y) == -sigma) {\n // This is an intersecting vertex. Adjust the position so that there's no overlap.\n vec2 point = 0.5 * width * normal * -sigma / dot(normal, p01Norm);\n gl_Position = vec4(uPanZoomMatrix * vec3(p1 + point, 1.0), 1.0);\n } else {\n // This is a non-intersecting vertex. Treat it like a mitre join.\n vec2 point = 0.5 * width * normal * sigma * dot(normal, p01Norm);\n gl_Position = vec4(uPanZoomMatrix * vec3(p1 + point, 1.0), 1.0);\n }\n\n vColor = aColor;\n } \n else if(aVertType == ").concat(3," && vid < 3) {\n // massage the first triangle into an edge arrow\n if(vid == 0)\n position = vec2(-0.15, -0.3);\n if(vid == 1)\n position = vec2( 0.0, 0.0);\n if(vid == 2)\n position = vec2( 0.15, -0.3);\n\n gl_Position = vec4(uPanZoomMatrix * aTransform * vec3(position, 1.0), 1.0);\n vColor = aColor;\n }\n else {\n gl_Position = vec4(2.0, 0.0, 0.0, 1.0); // discard vertex by putting it outside webgl clip space\n }\n\n vAtlasId = aAtlasId;\n vVertType = aVertType;\n vIndex = aIndex;\n }\n "),r=this.batchManager.getIndexArray(),i="#version 300 es\n precision highp float;\n\n // declare texture unit for each texture atlas in the batch\n ".concat(r.map((function(t){return"uniform sampler2D uTexture".concat(t,";")})).join("\n\t"),"\n\n uniform vec4 uBGColor;\n uniform float uZoom;\n\n in vec2 vTexCoord;\n in vec4 vColor;\n in vec2 vPosition; // model coordinates\n\n flat in int vAtlasId;\n flat in vec4 vIndex;\n flat in int vVertType;\n flat in vec2 vTopRight;\n flat in vec2 vBotLeft;\n flat in vec4 vCornerRadius;\n flat in vec4 vBorderColor;\n flat in vec2 vBorderWidth;\n\n out vec4 outColor;\n\n ").concat("\n float circleSD(vec2 p, float r) {\n return distance(vec2(0), p) - r; // signed distance\n }\n","\n ").concat("\n float rectangleSD(vec2 p, vec2 b) {\n vec2 d = abs(p)-b;\n return distance(vec2(0),max(d,0.0)) + min(max(d.x,d.y),0.0);\n }\n","\n ").concat("\n float roundRectangleSD(vec2 p, vec2 b, vec4 cr) {\n cr.xy = (p.x > 0.0) ? cr.xy : cr.zw;\n cr.x = (p.y > 0.0) ? cr.x : cr.y;\n vec2 q = abs(p) - b + cr.x;\n return min(max(q.x, q.y), 0.0) + distance(vec2(0), max(q, 0.0)) - cr.x;\n }\n","\n ").concat("\n float ellipseSD(vec2 p, vec2 ab) {\n p = abs( p ); // symmetry\n\n // find root with Newton solver\n vec2 q = ab*(p-ab);\n float w = (q.x1.0) ? d : -d;\n }\n","\n\n vec4 blend(vec4 top, vec4 bot) { // blend colors with premultiplied alpha\n return vec4( \n top.rgb + (bot.rgb * (1.0 - top.a)),\n top.a + (bot.a * (1.0 - top.a)) \n );\n }\n\n vec4 distInterp(vec4 cA, vec4 cB, float d) { // interpolate color using Signed Distance\n // scale to the zoom level so that borders don't look blurry when zoomed in\n // note 1.5 is an aribitrary value chosen because it looks good\n return mix(cA, cB, 1.0 - smoothstep(0.0, 1.5 / uZoom, abs(d))); \n }\n\n void main(void) {\n if(vVertType == ").concat(0,") {\n // look up the texel from the texture unit\n ").concat(r.map((function(t){return"if(vAtlasId == ".concat(t,") outColor = texture(uTexture").concat(t,", vTexCoord);")})).join("\n\telse "),"\n } \n else if(vVertType == ").concat(3,") {\n // mimics how canvas renderer uses context.globalCompositeOperation = 'destination-out';\n outColor = blend(vColor, uBGColor);\n outColor.a = 1.0; // make opaque, masks out line under arrow\n }\n else if(vVertType == ").concat(4," && vBorderWidth == vec2(0.0)) { // simple rectangle with no border\n outColor = vColor; // unit square is already transformed to the rectangle, nothing else needs to be done\n }\n else if(vVertType == ").concat(4," || vVertType == ").concat(7," \n || vVertType == ").concat(5," || vVertType == ").concat(6,") { // use SDF\n\n float outerBorder = vBorderWidth[0];\n float innerBorder = vBorderWidth[1];\n float borderPadding = outerBorder * 2.0;\n float w = vTopRight.x - vBotLeft.x - borderPadding;\n float h = vTopRight.y - vBotLeft.y - borderPadding;\n vec2 b = vec2(w/2.0, h/2.0); // half width, half height\n vec2 p = vPosition - vec2(vTopRight.x - b[0] - outerBorder, vTopRight.y - b[1] - outerBorder); // translate to center\n\n float d; // signed distance\n if(vVertType == ").concat(4,") {\n d = rectangleSD(p, b);\n } else if(vVertType == ").concat(7," && w == h) {\n d = circleSD(p, b.x); // faster than ellipse\n } else if(vVertType == ").concat(7,") {\n d = ellipseSD(p, b);\n } else {\n d = roundRectangleSD(p, b, vCornerRadius.wzyx);\n }\n\n // use the distance to interpolate a color to smooth the edges of the shape, doesn't need multisampling\n // we must smooth colors inwards, because we can't change pixels outside the shape's bounding box\n if(d > 0.0) {\n if(d > outerBorder) {\n discard;\n } else {\n outColor = distInterp(vBorderColor, vec4(0), d - outerBorder);\n }\n } else {\n if(d > innerBorder) {\n vec4 outerColor = outerBorder == 0.0 ? vec4(0) : vBorderColor;\n vec4 innerBorderColor = blend(vBorderColor, vColor);\n outColor = distInterp(innerBorderColor, outerColor, d);\n } \n else {\n vec4 outerColor;\n if(innerBorder == 0.0 && outerBorder == 0.0) {\n outerColor = vec4(0);\n } else if(innerBorder == 0.0) {\n outerColor = vBorderColor;\n } else {\n outerColor = blend(vBorderColor, vColor);\n }\n outColor = distInterp(vColor, outerColor, d - innerBorder);\n }\n }\n }\n else {\n outColor = vColor;\n }\n\n ").concat(t.picking?"if(outColor.a == 0.0) discard;\n else outColor = vIndex;":"","\n }\n "),a=function(t,e,n){var r=Jh(t,t.VERTEX_SHADER,e),i=Jh(t,t.FRAGMENT_SHADER,n),a=t.createProgram();if(t.attachShader(a,r),t.attachShader(a,i),t.linkProgram(a),!t.getProgramParameter(a,t.LINK_STATUS))throw new Error("Could not initialize shaders");return a}(e,n,i);a.aPosition=e.getAttribLocation(a,"aPosition"),a.aIndex=e.getAttribLocation(a,"aIndex"),a.aVertType=e.getAttribLocation(a,"aVertType"),a.aTransform=e.getAttribLocation(a,"aTransform"),a.aAtlasId=e.getAttribLocation(a,"aAtlasId"),a.aTex=e.getAttribLocation(a,"aTex"),a.aPointAPointB=e.getAttribLocation(a,"aPointAPointB"),a.aPointCPointD=e.getAttribLocation(a,"aPointCPointD"),a.aLineWidth=e.getAttribLocation(a,"aLineWidth"),a.aColor=e.getAttribLocation(a,"aColor"),a.aCornerRadius=e.getAttribLocation(a,"aCornerRadius"),a.aBorderColor=e.getAttribLocation(a,"aBorderColor"),a.uPanZoomMatrix=e.getUniformLocation(a,"uPanZoomMatrix"),a.uAtlasSize=e.getUniformLocation(a,"uAtlasSize"),a.uBGColor=e.getUniformLocation(a,"uBGColor"),a.uZoom=e.getUniformLocation(a,"uZoom"),a.uTextures=[];for(var s=0;s1&&void 0!==arguments[1]?arguments[1]:bu.SCREEN;this.panZoomMatrix=t,this.renderTarget=e,this.batchDebugInfo=[],this.wrappedCount=0,this.simpleCount=0,this.startBatch()}},{key:"startBatch",value:function(){this.instanceCount=0,this.batchManager.startBatch()}},{key:"endFrame",value:function(){this.endBatch()}},{key:"_isVisible",value:function(t,e){return!!t.visible()&&(!e||!e.isVisible||e.isVisible(t))}},{key:"drawTexture",value:function(t,e,n){var r=this.atlasManager,i=this.batchManager,a=r.getRenderTypeOpts(n);if(this._isVisible(t,a)){if(this.renderTarget.picking&&a.getTexPickingMode){var o=a.getTexPickingMode(t);if(1===o)return;if(2==o)return void this.drawPickingRectangle(t,e,n)}var c,h=s(r.getAtlasInfo(t,n));try{for(h.s();!(c=h.n()).done;){var u=c.value,d=u.atlas,p=u.tex1,g=u.tex2;i.canAddToCurrentBatch(d)||this.endBatch();for(var f=i.getAtlasIndexForBatch(d),m=0,y=[[p,!0],[g,!1]];m=this.maxInstances&&this.endBatch()}}}}catch(t){h.e(t)}finally{h.f()}}}},{key:"setTransformMatrix",value:function(t,e,n,r){var i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=0;if(n.shapeProps&&n.shapeProps.padding&&(a=t.pstyle(n.shapeProps.padding).pfValue),r){var s=r.bb,o=r.tex1,l=r.tex2,c=o.w/(o.w+l.w);i||(c=1-c);var h=this._getAdjustedBB(s,a,i,c);this._applyTransformMatrix(e,h,n,t)}else{var u=n.getBoundingBox(t),d=this._getAdjustedBB(u,a,!0,1);this._applyTransformMatrix(e,d,n,t)}}},{key:"_applyTransformMatrix",value:function(t,e,n,r){var i,a;du(t);var s=n.getRotation?n.getRotation(r):0;if(0!==s){var o=n.getRotationPoint(r);pu(t,t,[o.x,o.y]),gu(t,t,s);var l=n.getRotationOffset(r);i=l.x+(e.xOffset||0),a=l.y+(e.yOffset||0)}else i=e.x1,a=e.y1;pu(t,t,[i,a]),fu(t,t,[e.w,e.h])}},{key:"_getAdjustedBB",value:function(t,e,n,r){var i=t.x1,a=t.y1,s=t.w,o=t.h;e&&(i-=e,a-=e,s+=2*e,o+=2*e);var l=0,c=s*r;return n&&r<1?s=c:!n&&r<1&&(i+=l=s-c,s=c),{x1:i,y1:a,w:s,h:o,xOffset:l,yOffset:t.yOffset}}},{key:"drawPickingRectangle",value:function(t,e,n){var r=this.atlasManager.getRenderTypeOpts(n),i=this.instanceCount;this.vertTypeBuffer.getView(i)[0]=4,au(e,this.indexBuffer.getView(i)),iu([0,0,0],1,this.colorBuffer.getView(i));var a=this.transformBuffer.getMatrixView(i);this.setTransformMatrix(t,a,r),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}},{key:"drawNode",value:function(t,e,n){var r=this.simpleShapeOptions.get(n);if(this._isVisible(t,r)){var i=r.shapeProps,a=this._getVertTypeForShape(t,i.shape);if(void 0===a||r.isSimple&&!r.isSimple(t))this.drawTexture(t,e,n);else{var s=this.instanceCount;if(this.vertTypeBuffer.getView(s)[0]=a,5===a||6===a){var o=r.getBoundingBox(t),l=this._getCornerRadius(t,i.radius,o),c=this.cornerRadiusBuffer.getView(s);c[0]=l,c[1]=l,c[2]=l,c[3]=l,6===a&&(c[0]=0,c[2]=0)}au(e,this.indexBuffer.getView(s)),iu(t.pstyle(i.color).value,t.pstyle(i.opacity).value,this.colorBuffer.getView(s));var h=this.lineWidthBuffer.getView(s);if(h[0]=0,h[1]=0,i.border){var u=t.pstyle("border-width").value;if(u>0){iu(t.pstyle("border-color").value,t.pstyle("border-opacity").value,this.borderColorBuffer.getView(s));var d=t.pstyle("border-position").value;if("inside"===d)h[0]=0,h[1]=-u;else if("outside"===d)h[0]=u,h[1]=0;else{var p=u/2;h[0]=p,h[1]=-p}}}var g=this.transformBuffer.getMatrixView(s);this.setTransformMatrix(t,g,r),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}},{key:"_getVertTypeForShape",value:function(t,e){switch(t.pstyle(e).value){case"rectangle":return 4;case"ellipse":return 7;case"roundrectangle":case"round-rectangle":return 5;case"bottom-round-rectangle":return 6;default:return}}},{key:"_getCornerRadius",value:function(t,e,n){var r=n.w,i=n.h;if("auto"===t.pstyle(e).value)return Tn(r,i);var a=t.pstyle(e).pfValue,s=r/2,o=i/2;return Math.min(a,o,s)}},{key:"drawEdgeArrow",value:function(t,e,n){if(t.visible()){var r,i,a,s=t._private.rscratch;if(!("source"===n?(r=s.arrowStartX,i=s.arrowStartY,a=s.srcArrowAngle):(r=s.arrowEndX,i=s.arrowEndY,a=s.tgtArrowAngle),isNaN(r)||null==r||isNaN(i)||null==i||isNaN(a)||null==a||"none"===t.pstyle(n+"-arrow-shape").value)){var o=t.pstyle(n+"-arrow-color").value,l=t.pstyle("opacity").value*t.pstyle("line-opacity").value,c=t.pstyle("width").pfValue,h=t.pstyle("arrow-scale").value,u=this.r.getArrowWidth(c,h),d=this.instanceCount,p=this.transformBuffer.getMatrixView(d);du(p),pu(p,p,[r,i]),fu(p,p,[u,u]),gu(p,p,a),this.vertTypeBuffer.getView(d)[0]=3,au(e,this.indexBuffer.getView(d)),iu(o,l,this.colorBuffer.getView(d)),this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}},{key:"drawEdgeLine",value:function(t,e){if(t.visible()){var n=this._getEdgePoints(t);if(n){var r=t.pstyle("opacity").value,i=t.pstyle("line-opacity").value,a=t.pstyle("width").pfValue,s=t.pstyle("line-color").value,o=r*i;if(n.length/2+this.instanceCount>this.maxInstances&&this.endBatch(),4==n.length){var l=this.instanceCount;this.vertTypeBuffer.getView(l)[0]=1,au(e,this.indexBuffer.getView(l)),iu(s,o,this.colorBuffer.getView(l)),this.lineWidthBuffer.getView(l)[0]=a;var c=this.pointAPointBBuffer.getView(l);c[0]=n[0],c[1]=n[1],c[2]=n[2],c[3]=n[3],this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}else for(var h=0;h=this.maxInstances&&this.endBatch()}}}}},{key:"_getEdgePoints",value:function(t){var e=t._private.rscratch;if(!e.badLine&&null!=e.allpts&&!isNaN(e.allpts[0])){var n=e.allpts;if(4==n.length)return n;var r=this._getNumSegments(t);return this._getCurveSegmentPoints(n,r)}}},{key:"_getNumSegments",value:function(t){return Math.min(Math.max(15,5),this.maxInstances)}},{key:"_getCurveSegmentPoints",value:function(t,e){if(4==t.length)return t;for(var n=Array(2*(e+1)),r=0;r<=e;r++)if(0==r)n[0]=t[0],n[1]=t[1];else if(r==e)n[2*r]=t[t.length-2],n[2*r+1]=t[t.length-1];else{var i=r/e;this._setCurvePoint(t,i,n,2*r)}return n}},{key:"_setCurvePoint",value:function(t,e,n,r){if(!(t.length<=2)){for(var i=Array(t.length-2),a=0;a0}},c=function(t){return"yes"===t.pstyle("text-events").strValue?2:1},h=function(t){var e=t.position(),n=e.x,r=e.y,i=t.outerWidth(),a=t.outerHeight();return{w:i,h:a,x1:n-i/2,y1:r-a/2}};n.drawing.addAtlasCollection("node",{texRows:t.webglTexRowsNodes}),n.drawing.addAtlasCollection("label",{texRows:t.webglTexRows}),n.drawing.addTextureAtlasRenderType("node-body",{collection:"node",getKey:e.getStyleKey,getBoundingBox:e.getElementBox,drawElement:e.drawElement}),n.drawing.addSimpleShapeRenderType("node-body",{getBoundingBox:h,isSimple:nu,shapeProps:{shape:"shape",color:"background-color",opacity:"background-opacity",radius:"corner-radius",border:!0}}),n.drawing.addSimpleShapeRenderType("node-overlay",{getBoundingBox:h,isVisible:o("overlay"),shapeProps:{shape:"overlay-shape",color:"overlay-color",opacity:"overlay-opacity",padding:"overlay-padding",radius:"overlay-corner-radius"}}),n.drawing.addSimpleShapeRenderType("node-underlay",{getBoundingBox:h,isVisible:o("underlay"),shapeProps:{shape:"underlay-shape",color:"underlay-color",opacity:"underlay-opacity",padding:"underlay-padding",radius:"underlay-corner-radius"}}),n.drawing.addTextureAtlasRenderType("label",{collection:"label",getTexPickingMode:c,getKey:_u(e.getLabelKey,null),getBoundingBox:Eu(e.getLabelBox,null),drawClipped:!0,drawElement:e.drawLabel,getRotation:i(null),getRotationPoint:e.getLabelRotationPoint,getRotationOffset:e.getLabelRotationOffset,isVisible:a("label")}),n.drawing.addTextureAtlasRenderType("edge-source-label",{collection:"label",getTexPickingMode:c,getKey:_u(e.getSourceLabelKey,"source"),getBoundingBox:Eu(e.getSourceLabelBox,"source"),drawClipped:!0,drawElement:e.drawSourceLabel,getRotation:i("source"),getRotationPoint:e.getSourceLabelRotationPoint,getRotationOffset:e.getSourceLabelRotationOffset,isVisible:a("source-label")}),n.drawing.addTextureAtlasRenderType("edge-target-label",{collection:"label",getTexPickingMode:c,getKey:_u(e.getTargetLabelKey,"target"),getBoundingBox:Eu(e.getTargetLabelBox,"target"),drawClipped:!0,drawElement:e.drawTargetLabel,getRotation:i("target"),getRotationPoint:e.getTargetLabelRotationPoint,getRotationOffset:e.getTargetLabelRotationOffset,isVisible:a("target-label")});var u=Mt((function(){console.log("garbage collect flag set"),n.data.gc=!0}),1e4);n.onUpdateEleCalcs((function(t,e){var r=!1;e&&e.length>0&&(r|=n.drawing.invalidate(e)),r&&u()})),function(t){var e=t.render;t.render=function(n){n=n||{};var r=t.cy;t.webgl&&(r.zoom()>7.99?(function(t){var e=t.data.contexts[t.WEBGL];e.clear(e.COLOR_BUFFER_BIT|e.DEPTH_BUFFER_BIT)}(t),e.call(t,n)):(function(t){var e=function(e){e.save(),e.setTransform(1,0,0,1,0,0),e.clearRect(0,0,t.canvasWidth,t.canvasHeight),e.restore()};e(t.data.contexts[t.NODE]),e(t.data.contexts[t.DRAG])}(t),Au(t,n,bu.SCREEN)))};var n=t.matchCanvasSize;t.matchCanvasSize=function(e){n.call(t,e),t.pickingFrameBuffer.setFramebufferAttachmentSizes(t.canvasWidth,t.canvasHeight),t.pickingFrameBuffer.needsDraw=!0},t.findNearestElements=function(e,n,r,i){return function(t,e,n){var r,i,a,o=function(t,e,n,r,i){var a,s,o=eu(t),c=function(t,e,n,r,i){var a=r*n+e.x,s=i*n+e.y;return[a,s=Math.round(t.canvasHeight-s)]}(t,o.pan,o.zoom,e,n),h=l(c,2);if(a=h[0]-3,s=h[1]-3,6,0==6)return[];var u=t.data.contexts[t.WEBGL];u.bindFramebuffer(u.FRAMEBUFFER,t.pickingFrameBuffer),t.pickingFrameBuffer.needsDraw&&(u.viewport(0,0,u.canvas.width,u.canvas.height),Au(t,null,bu.PICKING),t.pickingFrameBuffer.needsDraw=!1);var d,p=new Uint8Array(144);u.readPixels(a,s,6,6,u.RGBA,u.UNSIGNED_BYTE,p),u.bindFramebuffer(u.FRAMEBUFFER,null);for(var g=new Set,f=0;f<36;f++){var m=(d=p.slice(4*f,4*f+4))[0]+(d[1]<<8)+(d[2]<<16)+(d[3]<<24)-1;m>=0&&g.add(m)}return g}(t,e,n),c=t.getCachedZSortedEles(),h=s(o);try{for(h.s();!(a=h.n()).done;){var u=c[a.value];if(!r&&u.isNode()&&(r=u),!i&&u.isEdge()&&(i=u),r&&i)break}}catch(t){h.e(t)}finally{h.f()}return[r,i].filter(Boolean)}(t,e,n)};var r=t.invalidateCachedZSortedEles;t.invalidateCachedZSortedEles=function(){r.call(t),t.pickingFrameBuffer.needsDraw=!0};var i=t.notify;t.notify=function(e,n){i.call(t,e,n),"viewport"===e||"bounds"===e?t.pickingFrameBuffer.needsDraw=!0:"background"===e&&t.drawing.invalidate(n,{type:"node-body"})}}(n)};var _u=function(t,e){return function(n){var r=t(n),i=Tu(n,e);return i.length>1?i.map((function(t,e){return"".concat(r,"_").concat(e)})):r}},Eu=function(t,e){return function(n,r){var i=t(n);if("string"==typeof r){var a=r.indexOf("_");if(a>0){var s=Number(r.substring(a+1)),o=Tu(n,e),l=i.h/o.length,c=l*s,h=i.y1+c;return{x1:i.x1,w:i.w,y1:h,h:l,yOffset:c}}}return i}};function Su(t,e){var n=t.canvasWidth,r=t.canvasHeight,i=eu(t),a=i.pan,s=i.zoom;e.setTransform(1,0,0,1,0,0),e.clearRect(0,0,n,r),e.translate(a.x,a.y),e.scale(s,s)}function Cu(t,e,n){var r=t.drawing;e+=1,n.isNode()?(r.drawNode(n,e,"node-underlay"),r.drawNode(n,e,"node-body"),r.drawTexture(n,e,"label"),r.drawNode(n,e,"node-overlay")):(r.drawEdgeLine(n,e),r.drawEdgeArrow(n,e,"source"),r.drawEdgeArrow(n,e,"target"),r.drawTexture(n,e,"label"),r.drawTexture(n,e,"edge-source-label"),r.drawTexture(n,e,"edge-target-label"))}function Au(t,e,n){var r;t.webglDebug&&(r=performance.now());var i=t.drawing,a=0;if(n.screen&&t.data.canvasNeedsRedraw[t.SELECT_BOX]&&function(t,e){t.drawSelectionRectangle(e,(function(e){return Su(t,e)}))}(t,e),t.data.canvasNeedsRedraw[t.NODE]||n.picking){var o=t.data.contexts[t.WEBGL];n.screen?(o.clearColor(0,0,0,0),o.enable(o.BLEND),o.blendFunc(o.ONE,o.ONE_MINUS_SRC_ALPHA)):o.disable(o.BLEND),o.clear(o.COLOR_BUFFER_BIT|o.DEPTH_BUFFER_BIT),o.viewport(0,0,o.canvas.width,o.canvas.height);var l=function(t){var e=t.canvasWidth,n=t.canvasHeight,r=eu(t),i=r.pan,a=r.zoom,s=uu();pu(s,s,[i.x,i.y]),fu(s,s,[a,a]);var o=uu();!function(t,e,n){t[0]=2/e,t[1]=0,t[2]=0,t[3]=0,t[4]=-2/n,t[5]=0,t[6]=-1,t[7]=1,t[8]=1}(o,e,n);var l,c,h,u,d,p,g,f,m,y,v,x,b,w,k,T,_,E,S,C,A,L=uu();return l=L,h=s,u=(c=o)[0],d=c[1],p=c[2],g=c[3],f=c[4],m=c[5],y=c[6],v=c[7],x=c[8],b=h[0],w=h[1],k=h[2],T=h[3],_=h[4],E=h[5],S=h[6],C=h[7],A=h[8],l[0]=b*u+w*g+k*y,l[1]=b*d+w*f+k*v,l[2]=b*p+w*m+k*x,l[3]=T*u+_*g+E*y,l[4]=T*d+_*f+E*v,l[5]=T*p+_*m+E*x,l[6]=S*u+C*g+A*y,l[7]=S*d+C*f+A*v,l[8]=S*p+C*m+A*x,L}(t),c=t.getCachedZSortedEles();if(a=c.length,i.startFrame(l,n),n.screen){for(var h=0;h0&&a>0){d.clearRect(0,0,i,a),d.globalCompositeOperation="source-over";var p=this.getCachedZSortedEles();if(t.full)d.translate(-n.x1*l,-n.y1*l),d.scale(l,l),this.drawElements(d,p),d.scale(1/l,1/l),d.translate(n.x1*l,n.y1*l);else{var g=e.pan(),f={x:g.x*l,y:g.y*l};l*=e.zoom(),d.translate(f.x,f.y),d.scale(l,l),this.drawElements(d,p),d.scale(1/l,1/l),d.translate(-f.x,-f.y)}t.bg&&(d.globalCompositeOperation="destination-over",d.fillStyle=t.bg,d.rect(0,0,i,a),d.fill())}return u},Pu.png=function(t){return Bu(t,this.bufferCanvasImage(t),"image/png")},Pu.jpg=function(t){return Bu(t,this.bufferCanvasImage(t),"image/jpeg")};var Fu=zu,Wu=zu.prototype;function zu(t){var e=this,n=e.cy.window().document;t.webgl&&(Wu.CANVAS_LAYERS=e.CANVAS_LAYERS=4,console.log("webgl rendering enabled")),e.data={canvases:new Array(Wu.CANVAS_LAYERS),contexts:new Array(Wu.CANVAS_LAYERS),canvasNeedsRedraw:new Array(Wu.CANVAS_LAYERS),bufferCanvases:new Array(Wu.BUFFER_COUNT),bufferContexts:new Array(Wu.CANVAS_LAYERS)};var r="-webkit-tap-highlight-color",i="rgba(0,0,0,0)";e.data.canvasContainer=n.createElement("div");var a=e.data.canvasContainer.style;e.data.canvasContainer.style[r]=i,a.position="relative",a.zIndex="0",a.overflow="hidden";var s=t.cy.container();s.appendChild(e.data.canvasContainer),s.style[r]=i;var o={"-webkit-user-select":"none","-moz-user-select":"-moz-none","user-select":"none","-webkit-tap-highlight-color":"rgba(0,0,0,0)","outline-style":"none"};g&&g.userAgent.match(/msie|trident|edge/i)&&(o["-ms-touch-action"]="none",o["touch-action"]="none");for(var l=0;l{"use strict";function r(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n=i)&&(n=i)}return n}function i(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n>e||void 0===n&&e>=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}function a(t){return t}n.d(e,{Nb1:()=>Zs,LLu:()=>v,F5q:()=>y,$0Z:()=>eo,Dts:()=>ro,WQY:()=>ao,qpX:()=>oo,u93:()=>lo,tFB:()=>ho,YY7:()=>go,OvA:()=>mo,dCK:()=>vo,zgE:()=>wo,fGX:()=>To,$m7:()=>Eo,c_6:()=>Gs,fxm:()=>Co,FdL:()=>Oo,ak_:()=>Po,SxZ:()=>Fo,eA_:()=>zo,jsv:()=>Yo,iJ:()=>Zo,JHv:()=>nr,jvg:()=>js,Fp7:()=>r,VV$:()=>i,ve8:()=>Ks,tiA:()=>cr,BYU:()=>Qr,PKp:()=>lr,Xf:()=>ps,K2I:()=>gs,Ys:()=>fs,rr1:()=>gi,i$Z:()=>Vi,y2j:()=>Ti,WQD:()=>di,U8T:()=>li,Z_i:()=>hi,Ox9:()=>xi,F0B:()=>Ri,LqH:()=>_i,S1K:()=>ci,Zyz:()=>vi,Igq:()=>ki,YDX:()=>bi,EFj:()=>wi});var s=1,o=2,l=3,c=4,h=1e-6;function u(t){return"translate("+t+",0)"}function d(t){return"translate(0,"+t+")"}function p(t){return e=>+t(e)}function g(t,e){return e=Math.max(0,t.bandwidth()-2*e)/2,t.round()&&(e=Math.round(e)),n=>+t(n)+e}function f(){return!this.__axis}function m(t,e){var n=[],r=null,i=null,m=6,y=6,v=3,x="undefined"!=typeof window&&window.devicePixelRatio>1?0:.5,b=t===s||t===c?-1:1,w=t===c||t===o?"x":"y",k=t===s||t===l?u:d;function T(u){var d=null==r?e.ticks?e.ticks.apply(e,n):e.domain():r,T=null==i?e.tickFormat?e.tickFormat.apply(e,n):a:i,_=Math.max(m,0)+v,E=e.range(),S=+E[0]+x,C=+E[E.length-1]+x,A=(e.bandwidth?g:p)(e.copy(),x),L=u.selection?u.selection():u,M=L.selectAll(".domain").data([null]),N=L.selectAll(".tick").data(d,e).order(),I=N.exit(),R=N.enter().append("g").attr("class","tick"),D=N.select("line"),O=N.select("text");M=M.merge(M.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),N=N.merge(R),D=D.merge(R.append("line").attr("stroke","currentColor").attr(w+"2",b*m)),O=O.merge(R.append("text").attr("fill","currentColor").attr(w,b*_).attr("dy",t===s?"0em":t===l?"0.71em":"0.32em")),u!==L&&(M=M.transition(u),N=N.transition(u),D=D.transition(u),O=O.transition(u),I=I.transition(u).attr("opacity",h).attr("transform",(function(t){return isFinite(t=A(t))?k(t+x):this.getAttribute("transform")})),R.attr("opacity",h).attr("transform",(function(t){var e=this.parentNode.__axis;return k((e&&isFinite(e=e(t))?e:A(t))+x)}))),I.remove(),M.attr("d",t===c||t===o?y?"M"+b*y+","+S+"H"+x+"V"+C+"H"+b*y:"M"+x+","+S+"V"+C:y?"M"+S+","+b*y+"V"+x+"H"+C+"V"+b*y:"M"+S+","+x+"H"+C),N.attr("opacity",1).attr("transform",(function(t){return k(A(t)+x)})),D.attr(w+"2",b*m),O.attr(w,b*_).text(T),L.filter(f).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===o?"start":t===c?"end":"middle"),L.each((function(){this.__axis=A}))}return T.scale=function(t){return arguments.length?(e=t,T):e},T.ticks=function(){return n=Array.from(arguments),T},T.tickArguments=function(t){return arguments.length?(n=null==t?[]:Array.from(t),T):n.slice()},T.tickValues=function(t){return arguments.length?(r=null==t?null:Array.from(t),T):r&&r.slice()},T.tickFormat=function(t){return arguments.length?(i=t,T):i},T.tickSize=function(t){return arguments.length?(m=y=+t,T):m},T.tickSizeInner=function(t){return arguments.length?(m=+t,T):m},T.tickSizeOuter=function(t){return arguments.length?(y=+t,T):y},T.tickPadding=function(t){return arguments.length?(v=+t,T):v},T.offset=function(t){return arguments.length?(x=+t,T):x},T}function y(t){return m(s,t)}function v(t){return m(l,t)}function x(){}function b(t){return null==t?x:function(){return this.querySelector(t)}}function w(){return[]}function k(t){return null==t?w:function(){return this.querySelectorAll(t)}}function T(t){return function(){return this.matches(t)}}function _(t){return function(e){return e.matches(t)}}var E=Array.prototype.find;function S(){return this.firstElementChild}var C=Array.prototype.filter;function A(){return Array.from(this.children)}function L(t){return new Array(t.length)}function M(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}function N(t,e,n,r,i,a){for(var s,o=0,l=e.length,c=a.length;oe?1:t>=e?0:NaN}M.prototype={constructor:M,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}};var P="http://www.w3.org/1999/xhtml";const $={svg:"http://www.w3.org/2000/svg",xhtml:P,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function B(t){var e=t+="",n=e.indexOf(":");return n>=0&&"xmlns"!==(e=t.slice(0,n))&&(t=t.slice(n+1)),$.hasOwnProperty(e)?{space:$[e],local:t}:t}function F(t){return function(){this.removeAttribute(t)}}function W(t){return function(){this.removeAttributeNS(t.space,t.local)}}function z(t,e){return function(){this.setAttribute(t,e)}}function Z(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function Y(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttribute(t):this.setAttribute(t,n)}}function U(t,e){return function(){var n=e.apply(this,arguments);null==n?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,n)}}function G(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}function V(t){return function(){this.style.removeProperty(t)}}function q(t,e,n){return function(){this.style.setProperty(t,e,n)}}function j(t,e,n){return function(){var r=e.apply(this,arguments);null==r?this.style.removeProperty(t):this.style.setProperty(t,r,n)}}function H(t,e){return t.style.getPropertyValue(e)||G(t).getComputedStyle(t,null).getPropertyValue(e)}function X(t){return function(){delete this[t]}}function K(t,e){return function(){this[t]=e}}function Q(t,e){return function(){var n=e.apply(this,arguments);null==n?delete this[t]:this[t]=n}}function J(t){return t.trim().split(/^|\s+/)}function tt(t){return t.classList||new et(t)}function et(t){this._node=t,this._names=J(t.getAttribute("class")||"")}function nt(t,e){for(var n=tt(t),r=-1,i=e.length;++r=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}};var Ct=[null];function At(t,e){this._groups=t,this._parents=e}function Lt(){return new At([[document.documentElement]],Ct)}At.prototype=Lt.prototype={constructor:At,select:function(t){"function"!=typeof t&&(t=b(t));for(var e=this._groups,n=e.length,r=new Array(n),i=0;i=w&&(w=b+1);!(x=y[w])&&++w=0;)(r=i[a])&&(s&&4^r.compareDocumentPosition(s)&&s.parentNode.insertBefore(r,s),s=r);return this},sort:function(t){function e(e,n){return e&&n?t(e.__data__,n.__data__):!e-!n}t||(t=O);for(var n=this._groups,r=n.length,i=new Array(r),a=0;a1?this.each((null==e?V:"function"==typeof e?j:q)(t,e,null==n?"":n)):H(this.node(),t)},property:function(t,e){return arguments.length>1?this.each((null==e?X:"function"==typeof e?Q:K)(t,e)):this.node()[t]},classed:function(t,e){var n=J(t+"");if(arguments.length<2){for(var r=tt(this.node()),i=-1,a=n.length;++i=0&&(e=t.slice(n+1),t=t.slice(0,n)),{type:t,name:e}}))}(t+""),s=a.length;if(!(arguments.length<2)){for(o=e?Tt:kt,r=0;r{}};function It(){for(var t,e=0,n=arguments.length,r={};e=0&&(e=t.slice(n+1),t=t.slice(0,n)),t&&!r.hasOwnProperty(t))throw new Error("unknown type: "+t);return{type:t,name:e}}))),s=-1,o=a.length;if(!(arguments.length<2)){if(null!=e&&"function"!=typeof e)throw new Error("invalid callback: "+e);for(;++s0)for(var n,r,i=new Array(n),a=0;a=0&&e._call.call(void 0,t),e=e._next;--Ft}()}finally{Ft=0,function(){for(var t,e,n=$t,r=1/0;n;)n._call?(r>n._time&&(r=n._time),t=n,n=n._next):(e=n._next,n._next=null,n=t?t._next=e:$t=e);Bt=t,te(r)}(),Ut=0}}function Jt(){var t=Vt.now(),e=t-Yt;e>Zt&&(Gt-=e,Yt=t)}function te(t){Ft||(Wt&&(Wt=clearTimeout(Wt)),t-Ut>24?(t<1/0&&(Wt=setTimeout(Qt,t-Vt.now()-Gt)),zt&&(zt=clearInterval(zt))):(zt||(Yt=Vt.now(),zt=setInterval(Jt,Zt)),Ft=1,qt(Qt)))}function ee(t,e,n){var r=new Xt;return e=null==e?0:+e,r.restart((n=>{r.stop(),t(n+e)}),e,n),r}Xt.prototype=Kt.prototype={constructor:Xt,restart:function(t,e,n){if("function"!=typeof t)throw new TypeError("callback is not a function");n=(null==n?jt():+n)+(null==e?0:+e),this._next||Bt===this||(Bt?Bt._next=this:$t=this,Bt=this),this._call=t,this._time=n,te()},stop:function(){this._call&&(this._call=null,this._time=1/0,te())}};var ne=Pt("start","end","cancel","interrupt"),re=[],ie=0,ae=3;function se(t,e,n,r,i,a){var s=t.__transition;if(s){if(n in s)return}else t.__transition={};!function(t,e,n){var r,i=t.__transition;function a(l){var c,h,u,d;if(1!==n.state)return o();for(c in i)if((d=i[c]).name===n.name){if(d.state===ae)return ee(a);4===d.state?(d.state=6,d.timer.stop(),d.on.call("interrupt",t,t.__data__,d.index,d.group),delete i[c]):+cie)throw new Error("too late; already scheduled");return n}function le(t,e){var n=ce(t,e);if(n.state>ae)throw new Error("too late; already running");return n}function ce(t,e){var n=t.__transition;if(!n||!(n=n[e]))throw new Error("transition not found");return n}function he(t,e){return t=+t,e=+e,function(n){return t*(1-n)+e*n}}var ue,de=180/Math.PI,pe={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function ge(t,e,n,r,i,a){var s,o,l;return(s=Math.sqrt(t*t+e*e))&&(t/=s,e/=s),(l=t*n+e*r)&&(n-=t*l,r-=e*l),(o=Math.sqrt(n*n+r*r))&&(n/=o,r/=o,l/=o),t*r180?e+=360:e-t>180&&(t+=360),a.push({i:n.push(i(n)+"rotate(",null,r)-2,x:he(t,e)})):e&&n.push(i(n)+"rotate("+e+r)}(a.rotate,s.rotate,o,l),function(t,e,n,a){t!==e?a.push({i:n.push(i(n)+"skewX(",null,r)-2,x:he(t,e)}):e&&n.push(i(n)+"skewX("+e+r)}(a.skewX,s.skewX,o,l),function(t,e,n,r,a,s){if(t!==n||e!==r){var o=a.push(i(a)+"scale(",null,",",null,")");s.push({i:o-4,x:he(t,n)},{i:o-2,x:he(e,r)})}else 1===n&&1===r||a.push(i(a)+"scale("+n+","+r+")")}(a.scaleX,a.scaleY,s.scaleX,s.scaleY,o,l),a=s=null,function(t){for(var e,n=-1,r=l.length;++n>8&15|e>>4&240,e>>4&15|240&e,(15&e)<<4|15&e,1):8===n?ze(e>>24&255,e>>16&255,e>>8&255,(255&e)/255):4===n?ze(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|240&e,((15&e)<<4|15&e)/255):null):(e=Me.exec(t))?new Ue(e[1],e[2],e[3],1):(e=Ne.exec(t))?new Ue(255*e[1]/100,255*e[2]/100,255*e[3]/100,1):(e=Ie.exec(t))?ze(e[1],e[2],e[3],e[4]):(e=Re.exec(t))?ze(255*e[1]/100,255*e[2]/100,255*e[3]/100,e[4]):(e=De.exec(t))?Xe(e[1],e[2]/100,e[3]/100,1):(e=Oe.exec(t))?Xe(e[1],e[2]/100,e[3]/100,e[4]):Pe.hasOwnProperty(t)?We(Pe[t]):"transparent"===t?new Ue(NaN,NaN,NaN,0):null}function We(t){return new Ue(t>>16&255,t>>8&255,255&t,1)}function ze(t,e,n,r){return r<=0&&(t=e=n=NaN),new Ue(t,e,n,r)}function Ze(t){return t instanceof Te||(t=Fe(t)),t?new Ue((t=t.rgb()).r,t.g,t.b,t.opacity):new Ue}function Ye(t,e,n,r){return 1===arguments.length?Ze(t):new Ue(t,e,n,null==r?1:r)}function Ue(t,e,n,r){this.r=+t,this.g=+e,this.b=+n,this.opacity=+r}function Ge(){return`#${He(this.r)}${He(this.g)}${He(this.b)}`}function Ve(){const t=qe(this.opacity);return`${1===t?"rgb(":"rgba("}${je(this.r)}, ${je(this.g)}, ${je(this.b)}${1===t?")":`, ${t})`}`}function qe(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function je(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function He(t){return((t=je(t))<16?"0":"")+t.toString(16)}function Xe(t,e,n,r){return r<=0?t=e=n=NaN:n<=0||n>=1?t=e=NaN:e<=0&&(t=NaN),new Qe(t,e,n,r)}function Ke(t){if(t instanceof Qe)return new Qe(t.h,t.s,t.l,t.opacity);if(t instanceof Te||(t=Fe(t)),!t)return new Qe;if(t instanceof Qe)return t;var e=(t=t.rgb()).r/255,n=t.g/255,r=t.b/255,i=Math.min(e,n,r),a=Math.max(e,n,r),s=NaN,o=a-i,l=(a+i)/2;return o?(s=e===a?(n-r)/o+6*(n0&&l<1?0:s,new Qe(s,o,l,t.opacity)}function Qe(t,e,n,r){this.h=+t,this.s=+e,this.l=+n,this.opacity=+r}function Je(t){return(t=(t||0)%360)<0?t+360:t}function tn(t){return Math.max(0,Math.min(1,t||0))}function en(t,e,n){return 255*(t<60?e+(n-e)*t/60:t<180?n:t<240?e+(n-e)*(240-t)/60:e)}function nn(t,e,n,r,i){var a=t*t,s=a*t;return((1-3*t+3*a-s)*e+(4-6*a+3*s)*n+(1+3*t+3*a-3*s)*r+s*i)/6}we(Te,Fe,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:$e,formatHex:$e,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return Ke(this).formatHsl()},formatRgb:Be,toString:Be}),we(Ue,Ye,ke(Te,{brighter(t){return t=null==t?Ee:Math.pow(Ee,t),new Ue(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=null==t?_e:Math.pow(_e,t),new Ue(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new Ue(je(this.r),je(this.g),je(this.b),qe(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Ge,formatHex:Ge,formatHex8:function(){return`#${He(this.r)}${He(this.g)}${He(this.b)}${He(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:Ve,toString:Ve})),we(Qe,(function(t,e,n,r){return 1===arguments.length?Ke(t):new Qe(t,e,n,null==r?1:r)}),ke(Te,{brighter(t){return t=null==t?Ee:Math.pow(Ee,t),new Qe(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=null==t?_e:Math.pow(_e,t),new Qe(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+360*(this.h<0),e=isNaN(t)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*e,i=2*n-r;return new Ue(en(t>=240?t-240:t+120,i,r),en(t,i,r),en(t<120?t+240:t-120,i,r),this.opacity)},clamp(){return new Qe(Je(this.h),tn(this.s),tn(this.l),qe(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const t=qe(this.opacity);return`${1===t?"hsl(":"hsla("}${Je(this.h)}, ${100*tn(this.s)}%, ${100*tn(this.l)}%${1===t?")":`, ${t})`}`}}));const rn=t=>()=>t;function an(t,e){return function(n){return t+n*e}}function sn(t,e){var n=e-t;return n?an(t,n):rn(isNaN(t)?e:t)}const on=function t(e){var n=function(t){return 1==(t=+t)?sn:function(e,n){return n-e?function(t,e,n){return t=Math.pow(t,n),e=Math.pow(e,n)-t,n=1/n,function(r){return Math.pow(t+r*e,n)}}(e,n,t):rn(isNaN(e)?n:e)}}(e);function r(t,e){var r=n((t=Ye(t)).r,(e=Ye(e)).r),i=n(t.g,e.g),a=n(t.b,e.b),s=sn(t.opacity,e.opacity);return function(e){return t.r=r(e),t.g=i(e),t.b=a(e),t.opacity=s(e),t+""}}return r.gamma=t,r}(1);function ln(t){return function(e){var n,r,i=e.length,a=new Array(i),s=new Array(i),o=new Array(i);for(n=0;n=1?(n=1,e-1):Math.floor(n*e),i=t[r],a=t[r+1],s=r>0?t[r-1]:2*i-a,o=ra&&(i=e.slice(a,i),o[s]?o[s]+=i:o[++s]=i),(n=n[0])===(r=r[0])?o[s]?o[s]+=r:o[++s]=r:(o[++s]=null,l.push({i:s,x:he(n,r)})),a=hn.lastIndex;return a=0&&(t=t.slice(0,e)),!t||"start"===t}))}(e)?oe:le;return function(){var s=a(this,t),o=s.on;o!==r&&(i=(r=o).copy()).on(e,n),s.on=i}}(n,t,e))},attr:function(t,e){var n=B(t),r="transform"===n?ye:dn;return this.attrTween(t,"function"==typeof e?(n.local?vn:yn)(n,r,be(this,"attr."+t,e)):null==e?(n.local?gn:pn)(n):(n.local?mn:fn)(n,r,e))},attrTween:function(t,e){var n="attr."+t;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(null==e)return this.tween(n,null);if("function"!=typeof e)throw new Error;var r=B(t);return this.tween(n,(r.local?xn:bn)(r,e))},style:function(t,e,n){var r="transform"==(t+="")?me:dn;return null==e?this.styleTween(t,function(t,e){var n,r,i;return function(){var a=H(this,t),s=(this.style.removeProperty(t),H(this,t));return a===s?null:a===n&&s===r?i:i=e(n=a,r=s)}}(t,r)).on("end.style."+t,Sn(t)):"function"==typeof e?this.styleTween(t,function(t,e,n){var r,i,a;return function(){var s=H(this,t),o=n(this),l=o+"";return null==o&&(this.style.removeProperty(t),l=o=H(this,t)),s===l?null:s===r&&l===i?a:(i=l,a=e(r=s,o))}}(t,r,be(this,"style."+t,e))).each(function(t,e){var n,r,i,a,s="style."+e,o="end."+s;return function(){var l=le(this,t),c=l.on,h=null==l.value[s]?a||(a=Sn(e)):void 0;c===n&&i===h||(r=(n=c).copy()).on(o,i=h),l.on=r}}(this._id,t)):this.styleTween(t,function(t,e,n){var r,i,a=n+"";return function(){var s=H(this,t);return s===a?null:s===r?i:i=e(r=s,n)}}(t,r,e),n).on("end.style."+t,null)},styleTween:function(t,e,n){var r="style."+(t+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==e)return this.tween(r,null);if("function"!=typeof e)throw new Error;return this.tween(r,function(t,e,n){var r,i;function a(){var a=e.apply(this,arguments);return a!==i&&(r=(i=a)&&function(t,e,n){return function(r){this.style.setProperty(t,e.call(this,r),n)}}(t,a,n)),r}return a._value=e,a}(t,e,null==n?"":n))},text:function(t){return this.tween("text","function"==typeof t?function(t){return function(){var e=t(this);this.textContent=null==e?"":e}}(be(this,"text",t)):function(t){return function(){this.textContent=t}}(null==t?"":t+""))},textTween:function(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(null==t)return this.tween(e,null);if("function"!=typeof t)throw new Error;return this.tween(e,function(t){var e,n;function r(){var r=t.apply(this,arguments);return r!==n&&(e=(n=r)&&function(t){return function(e){this.textContent=t.call(this,e)}}(r)),e}return r._value=t,r}(t))},remove:function(){return this.on("end.remove",function(t){return function(){var e=this.parentNode;for(var n in this.__transition)if(+n!==t)return;e&&e.removeChild(this)}}(this._id))},tween:function(t,e){var n=this._id;if(t+="",arguments.length<2){for(var r,i=ce(this.node(),n).tween,a=0,s=i.length;a2&&n.state<5,n.state=6,n.timer.stop(),n.on.call(r?"interrupt":"cancel",t,t.__data__,n.index,n.group),delete a[i]):s=!1;s&&delete t.__transition}}(this,t)}))},Mt.prototype.transition=function(t){var e,n;t instanceof An?(e=t._id,t=t._name):(e=Ln(),(n=Nn).time=jt(),t=null==t?null:t+"");for(var r=this._groups,i=r.length,a=0;aGn?Math.pow(t,1/3):t/Un+Zn}function Hn(t){return t>Yn?t*t*t:Un*(t-Zn)}function Xn(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function Kn(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Qn(t,e,n,r){return 1===arguments.length?function(t){if(t instanceof Jn)return new Jn(t.h,t.c,t.l,t.opacity);if(t instanceof qn||(t=Vn(t)),0===t.a&&0===t.b)return new Jn(NaN,0180||n<-180?n-360*Math.round(n/360):n):rn(isNaN(t)?e:t)}));function rr(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t)}return this}er(sn);class ir extends Map{constructor(t,e=sr){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:e}}),null!=t)for(const[e,n]of t)this.set(e,n)}get(t){return super.get(ar(this,t))}has(t){return super.has(ar(this,t))}set(t,e){return super.set(function({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):(t.set(r,n),n)}(this,t),e)}delete(t){return super.delete(function({_intern:t,_key:e},n){const r=e(n);return t.has(r)&&(n=t.get(r),t.delete(r)),n}(this,t))}}function ar({_intern:t,_key:e},n){const r=e(n);return t.has(r)?t.get(r):n}function sr(t){return null!==t&&"object"==typeof t?t.valueOf():t}const or=Symbol("implicit");function lr(){var t=new ir,e=[],n=[],r=or;function i(i){let a=t.get(i);if(void 0===a){if(r!==or)return r;t.set(i,a=e.push(i)-1)}return n[a%n.length]}return i.domain=function(n){if(!arguments.length)return e.slice();e=[],t=new ir;for(const r of n)t.has(r)||t.set(r,e.push(r)-1);return i},i.range=function(t){return arguments.length?(n=Array.from(t),i):n.slice()},i.unknown=function(t){return arguments.length?(r=t,i):r},i.copy=function(){return lr(e,n).unknown(r)},rr.apply(i,arguments),i}function cr(){var t,e,n=lr().unknown(void 0),r=n.domain,i=n.range,a=0,s=1,o=!1,l=0,c=0,h=.5;function u(){var n=r().length,u=s=hr?10:a>=ur?5:a>=dr?2:1;let o,l,c;return i<0?(c=Math.pow(10,-i)/s,o=Math.round(t*c),l=Math.round(e*c),o/ce&&--l,c=-c):(c=Math.pow(10,i)*s,o=Math.round(t/c),l=Math.round(e/c),o*ce&&--l),le?1:t>=e?0:NaN}function yr(t,e){return null==t||null==e?NaN:et?1:e>=t?0:NaN}function vr(t){let e,n,r;function i(t,r,i=0,a=t.length){if(i>>1;n(t[e],r)<0?i=e+1:a=e}while(imr(t(e),n),r=(e,n)=>t(e)-n):(e=t===mr||t===yr?t:xr,n=t,r=t),{left:i,center:function(t,e,n=0,a=t.length){const s=i(t,e,n,a-1);return s>n&&r(t[s-1],e)>-r(t[s],e)?s-1:s},right:function(t,r,i=0,a=t.length){if(i>>1;n(t[e],r)<=0?i=e+1:a=e}while(ie&&(n=t,t=e,e=n),c=function(n){return Math.max(t,Math.min(e,n))}),r=l>2?Dr:Rr,i=a=null,u}function u(e){return null==e||isNaN(e=+e)?n:(i||(i=r(s.map(t),o,l)))(t(c(e)))}return u.invert=function(n){return c(e((a||(a=r(o,s.map(t),he)))(n)))},u.domain=function(t){return arguments.length?(s=Array.from(t,Lr),h()):s.slice()},u.range=function(t){return arguments.length?(o=Array.from(t),h()):o.slice()},u.rangeRound=function(t){return o=Array.from(t),l=Ar,h()},u.clamp=function(t){return arguments.length?(c=!!t||Nr,h()):c!==Nr},u.interpolate=function(t){return arguments.length?(l=t,h()):l},u.unknown=function(t){return arguments.length?(n=t,u):n},function(n,r){return t=n,e=r,h()}}()(Nr,Nr)}var $r,Br=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Fr(t){if(!(e=Br.exec(t)))throw new Error("invalid format: "+t);var e;return new Wr({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function Wr(t){this.fill=void 0===t.fill?" ":t.fill+"",this.align=void 0===t.align?">":t.align+"",this.sign=void 0===t.sign?"-":t.sign+"",this.symbol=void 0===t.symbol?"":t.symbol+"",this.zero=!!t.zero,this.width=void 0===t.width?void 0:+t.width,this.comma=!!t.comma,this.precision=void 0===t.precision?void 0:+t.precision,this.trim=!!t.trim,this.type=void 0===t.type?"":t.type+""}function zr(t,e){if((n=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var n,r=t.slice(0,n);return[r.length>1?r[0]+r.slice(2):r,+t.slice(n+1)]}function Zr(t){return(t=zr(Math.abs(t)))?t[1]:NaN}function Yr(t,e){var n=zr(t,e);if(!n)return t+"";var r=n[0],i=n[1];return i<0?"0."+new Array(-i).join("0")+r:r.length>i+1?r.slice(0,i+1)+"."+r.slice(i+1):r+new Array(i-r.length+2).join("0")}Fr.prototype=Wr.prototype,Wr.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type};const Ur={"%":(t,e)=>(100*t).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:function(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)},e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>Yr(100*t,e),r:Yr,s:function(t,e){var n=zr(t,e);if(!n)return t+"";var r=n[0],i=n[1],a=i-($r=3*Math.max(-8,Math.min(8,Math.floor(i/3))))+1,s=r.length;return a===s?r:a>s?r+new Array(a-s+1).join("0"):a>0?r.slice(0,a)+"."+r.slice(a):"0."+new Array(1-a).join("0")+zr(t,Math.max(0,e+a-1))[0]},X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)};function Gr(t){return t}var Vr,qr,jr,Hr=Array.prototype.map,Xr=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Kr(t){var e=t.domain;return t.ticks=function(t){var n=e();return function(t,e,n){if(!((n=+n)>0))return[];if((t=+t)==(e=+e))return[t];const r=e=i))return[];const o=a-i+1,l=new Array(o);if(r)if(s<0)for(let t=0;t0;){if((i=gr(l,c,n))===r)return a[s]=l,a[o]=c,e(a);if(i>0)l=Math.floor(l/i)*i,c=Math.ceil(c/i)*i;else{if(!(i<0))break;l=Math.ceil(l*i)/i,c=Math.floor(c*i)/i}r=i}return t},t}function Qr(){var t=Pr();return t.copy=function(){return Or(t,Qr())},rr.apply(t,arguments),Kr(t)}Vr=function(t){var e,n,r=void 0===t.grouping||void 0===t.thousands?Gr:(e=Hr.call(t.grouping,Number),n=t.thousands+"",function(t,r){for(var i=t.length,a=[],s=0,o=e[0],l=0;i>0&&o>0&&(l+o+1>r&&(o=Math.max(1,r-l)),a.push(t.substring(i-=o,i+o)),!((l+=o+1)>r));)o=e[s=(s+1)%e.length];return a.reverse().join(n)}),i=void 0===t.currency?"":t.currency[0]+"",a=void 0===t.currency?"":t.currency[1]+"",s=void 0===t.decimal?".":t.decimal+"",o=void 0===t.numerals?Gr:function(t){return function(e){return e.replace(/[0-9]/g,(function(e){return t[+e]}))}}(Hr.call(t.numerals,String)),l=void 0===t.percent?"%":t.percent+"",c=void 0===t.minus?"−":t.minus+"",h=void 0===t.nan?"NaN":t.nan+"";function u(t){var e=(t=Fr(t)).fill,n=t.align,u=t.sign,d=t.symbol,p=t.zero,g=t.width,f=t.comma,m=t.precision,y=t.trim,v=t.type;"n"===v?(f=!0,v="g"):Ur[v]||(void 0===m&&(m=12),y=!0,v="g"),(p||"0"===e&&"="===n)&&(p=!0,e="0",n="=");var x="$"===d?i:"#"===d&&/[boxX]/.test(v)?"0"+v.toLowerCase():"",b="$"===d?a:/[%p]/.test(v)?l:"",w=Ur[v],k=/[defgprs%]/.test(v);function T(t){var i,a,l,d=x,T=b;if("c"===v)T=w(t)+T,t="";else{var _=(t=+t)<0||1/t<0;if(t=isNaN(t)?h:w(Math.abs(t),m),y&&(t=function(t){t:for(var e,n=t.length,r=1,i=-1;r0&&(i=0)}return i>0?t.slice(0,i)+t.slice(e+1):t}(t)),_&&0==+t&&"+"!==u&&(_=!1),d=(_?"("===u?u:c:"-"===u||"("===u?"":u)+d,T=("s"===v?Xr[8+$r/3]:"")+T+(_&&"("===u?")":""),k)for(i=-1,a=t.length;++i(l=t.charCodeAt(i))||l>57){T=(46===l?s+t.slice(i+1):t.slice(i))+T,t=t.slice(0,i);break}}f&&!p&&(t=r(t,1/0));var E=d.length+t.length+T.length,S=E>1)+d+t+T+S.slice(E);break;default:t=S+d+t+T}return o(t)}return m=void 0===m?6:/[gprs]/.test(v)?Math.max(1,Math.min(21,m)):Math.max(0,Math.min(20,m)),T.toString=function(){return t+""},T}return{format:u,formatPrefix:function(t,e){var n=u(((t=Fr(t)).type="f",t)),r=3*Math.max(-8,Math.min(8,Math.floor(Zr(e)/3))),i=Math.pow(10,-r),a=Xr[8+r/3];return function(t){return n(i*t)+a}}}}({thousands:",",grouping:[3],currency:["$",""]}),qr=Vr.format,jr=Vr.formatPrefix;const Jr=1e3,ti=6e4,ei=36e5,ni=864e5,ri=6048e5,ii=31536e6,ai=new Date,si=new Date;function oi(t,e,n,r){function i(e){return t(e=0===arguments.length?new Date:new Date(+e)),e}return i.floor=e=>(t(e=new Date(+e)),e),i.ceil=n=>(t(n=new Date(n-1)),e(n,1),t(n),n),i.round=t=>{const e=i(t),n=i.ceil(t);return t-e(e(t=new Date(+t),null==n?1:Math.floor(n)),t),i.range=(n,r,a)=>{const s=[];if(n=i.ceil(n),a=null==a?1:Math.floor(a),!(n0))return s;let o;do{s.push(o=new Date(+n)),e(n,a),t(n)}while(ooi((e=>{if(e>=e)for(;t(e),!n(e);)e.setTime(e-1)}),((t,r)=>{if(t>=t)if(r<0)for(;++r<=0;)for(;e(t,-1),!n(t););else for(;--r>=0;)for(;e(t,1),!n(t););})),n&&(i.count=(e,r)=>(ai.setTime(+e),si.setTime(+r),t(ai),t(si),Math.floor(n(ai,si))),i.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?i.filter(r?e=>r(e)%t==0:e=>i.count(0,e)%t==0):i:null)),i}const li=oi((()=>{}),((t,e)=>{t.setTime(+t+e)}),((t,e)=>e-t));li.every=t=>(t=Math.floor(t),isFinite(t)&&t>0?t>1?oi((e=>{e.setTime(Math.floor(e/t)*t)}),((e,n)=>{e.setTime(+e+n*t)}),((e,n)=>(n-e)/t)):li:null),li.range;const ci=oi((t=>{t.setTime(t-t.getMilliseconds())}),((t,e)=>{t.setTime(+t+e*Jr)}),((t,e)=>(e-t)/Jr),(t=>t.getUTCSeconds())),hi=(ci.range,oi((t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Jr)}),((t,e)=>{t.setTime(+t+e*ti)}),((t,e)=>(e-t)/ti),(t=>t.getMinutes()))),ui=(hi.range,oi((t=>{t.setUTCSeconds(0,0)}),((t,e)=>{t.setTime(+t+e*ti)}),((t,e)=>(e-t)/ti),(t=>t.getUTCMinutes()))),di=(ui.range,oi((t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*Jr-t.getMinutes()*ti)}),((t,e)=>{t.setTime(+t+e*ei)}),((t,e)=>(e-t)/ei),(t=>t.getHours()))),pi=(di.range,oi((t=>{t.setUTCMinutes(0,0,0)}),((t,e)=>{t.setTime(+t+e*ei)}),((t,e)=>(e-t)/ei),(t=>t.getUTCHours()))),gi=(pi.range,oi((t=>t.setHours(0,0,0,0)),((t,e)=>t.setDate(t.getDate()+e)),((t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*ti)/ni),(t=>t.getDate()-1))),fi=(gi.range,oi((t=>{t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+e)}),((t,e)=>(e-t)/ni),(t=>t.getUTCDate()-1))),mi=(fi.range,oi((t=>{t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+e)}),((t,e)=>(e-t)/ni),(t=>Math.floor(t/ni))));function yi(t){return oi((e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)}),((t,e)=>{t.setDate(t.getDate()+7*e)}),((t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*ti)/ri))}mi.range;const vi=yi(0),xi=yi(1),bi=yi(2),wi=yi(3),ki=yi(4),Ti=yi(5),_i=yi(6);function Ei(t){return oi((e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCDate(t.getUTCDate()+7*e)}),((t,e)=>(e-t)/ri))}vi.range,xi.range,bi.range,wi.range,ki.range,Ti.range,_i.range;const Si=Ei(0),Ci=Ei(1),Ai=Ei(2),Li=Ei(3),Mi=Ei(4),Ni=Ei(5),Ii=Ei(6),Ri=(Si.range,Ci.range,Ai.range,Li.range,Mi.range,Ni.range,Ii.range,oi((t=>{t.setDate(1),t.setHours(0,0,0,0)}),((t,e)=>{t.setMonth(t.getMonth()+e)}),((t,e)=>e.getMonth()-t.getMonth()+12*(e.getFullYear()-t.getFullYear())),(t=>t.getMonth()))),Di=(Ri.range,oi((t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)}),((t,e)=>e.getUTCMonth()-t.getUTCMonth()+12*(e.getUTCFullYear()-t.getUTCFullYear())),(t=>t.getUTCMonth()))),Oi=(Di.range,oi((t=>{t.setMonth(0,1),t.setHours(0,0,0,0)}),((t,e)=>{t.setFullYear(t.getFullYear()+e)}),((t,e)=>e.getFullYear()-t.getFullYear()),(t=>t.getFullYear())));Oi.every=t=>isFinite(t=Math.floor(t))&&t>0?oi((e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)}),((e,n)=>{e.setFullYear(e.getFullYear()+n*t)})):null,Oi.range;const Pi=oi((t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)}),((t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)}),((t,e)=>e.getUTCFullYear()-t.getUTCFullYear()),(t=>t.getUTCFullYear()));function $i(t,e,n,r,i,a){const s=[[ci,1,Jr],[ci,5,5e3],[ci,15,15e3],[ci,30,3e4],[a,1,ti],[a,5,3e5],[a,15,9e5],[a,30,18e5],[i,1,ei],[i,3,108e5],[i,6,216e5],[i,12,432e5],[r,1,ni],[r,2,1728e5],[n,1,ri],[e,1,2592e6],[e,3,7776e6],[t,1,ii]];function o(e,n,r){const i=Math.abs(n-e)/r,a=vr((([,,t])=>t)).right(s,i);if(a===s.length)return t.every(fr(e/ii,n/ii,r));if(0===a)return li.every(Math.max(fr(e,n,r),1));const[o,l]=s[i/s[a-1][2]isFinite(t=Math.floor(t))&&t>0?oi((e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)}),((e,n)=>{e.setUTCFullYear(e.getUTCFullYear()+n*t)})):null,Pi.range;const[Bi,Fi]=$i(Pi,Di,Si,mi,pi,ui),[Wi,zi]=$i(Oi,Ri,vi,gi,di,hi);function Zi(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function Yi(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function Ui(t,e,n){return{y:t,m:e,d:n,H:0,M:0,S:0,L:0}}var Gi,Vi,qi={"-":"",_:" ",0:"0"},ji=/^\s*\d+/,Hi=/^%/,Xi=/[\\^$*+?|[\]().{}]/g;function Ki(t,e,n){var r=t<0?"-":"",i=(r?-t:t)+"",a=i.length;return r+(a[t.toLowerCase(),e])))}function ea(t,e,n){var r=ji.exec(e.slice(n,n+1));return r?(t.w=+r[0],n+r[0].length):-1}function na(t,e,n){var r=ji.exec(e.slice(n,n+1));return r?(t.u=+r[0],n+r[0].length):-1}function ra(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.U=+r[0],n+r[0].length):-1}function ia(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.V=+r[0],n+r[0].length):-1}function aa(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.W=+r[0],n+r[0].length):-1}function sa(t,e,n){var r=ji.exec(e.slice(n,n+4));return r?(t.y=+r[0],n+r[0].length):-1}function oa(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.y=+r[0]+(+r[0]>68?1900:2e3),n+r[0].length):-1}function la(t,e,n){var r=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(n,n+6));return r?(t.Z=r[1]?0:-(r[2]+(r[3]||"00")),n+r[0].length):-1}function ca(t,e,n){var r=ji.exec(e.slice(n,n+1));return r?(t.q=3*r[0]-3,n+r[0].length):-1}function ha(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.m=r[0]-1,n+r[0].length):-1}function ua(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.d=+r[0],n+r[0].length):-1}function da(t,e,n){var r=ji.exec(e.slice(n,n+3));return r?(t.m=0,t.d=+r[0],n+r[0].length):-1}function pa(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.H=+r[0],n+r[0].length):-1}function ga(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.M=+r[0],n+r[0].length):-1}function fa(t,e,n){var r=ji.exec(e.slice(n,n+2));return r?(t.S=+r[0],n+r[0].length):-1}function ma(t,e,n){var r=ji.exec(e.slice(n,n+3));return r?(t.L=+r[0],n+r[0].length):-1}function ya(t,e,n){var r=ji.exec(e.slice(n,n+6));return r?(t.L=Math.floor(r[0]/1e3),n+r[0].length):-1}function va(t,e,n){var r=Hi.exec(e.slice(n,n+1));return r?n+r[0].length:-1}function xa(t,e,n){var r=ji.exec(e.slice(n));return r?(t.Q=+r[0],n+r[0].length):-1}function ba(t,e,n){var r=ji.exec(e.slice(n));return r?(t.s=+r[0],n+r[0].length):-1}function wa(t,e){return Ki(t.getDate(),e,2)}function ka(t,e){return Ki(t.getHours(),e,2)}function Ta(t,e){return Ki(t.getHours()%12||12,e,2)}function _a(t,e){return Ki(1+gi.count(Oi(t),t),e,3)}function Ea(t,e){return Ki(t.getMilliseconds(),e,3)}function Sa(t,e){return Ea(t,e)+"000"}function Ca(t,e){return Ki(t.getMonth()+1,e,2)}function Aa(t,e){return Ki(t.getMinutes(),e,2)}function La(t,e){return Ki(t.getSeconds(),e,2)}function Ma(t){var e=t.getDay();return 0===e?7:e}function Na(t,e){return Ki(vi.count(Oi(t)-1,t),e,2)}function Ia(t){var e=t.getDay();return e>=4||0===e?ki(t):ki.ceil(t)}function Ra(t,e){return t=Ia(t),Ki(ki.count(Oi(t),t)+(4===Oi(t).getDay()),e,2)}function Da(t){return t.getDay()}function Oa(t,e){return Ki(xi.count(Oi(t)-1,t),e,2)}function Pa(t,e){return Ki(t.getFullYear()%100,e,2)}function $a(t,e){return Ki((t=Ia(t)).getFullYear()%100,e,2)}function Ba(t,e){return Ki(t.getFullYear()%1e4,e,4)}function Fa(t,e){var n=t.getDay();return Ki((t=n>=4||0===n?ki(t):ki.ceil(t)).getFullYear()%1e4,e,4)}function Wa(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+Ki(e/60|0,"0",2)+Ki(e%60,"0",2)}function za(t,e){return Ki(t.getUTCDate(),e,2)}function Za(t,e){return Ki(t.getUTCHours(),e,2)}function Ya(t,e){return Ki(t.getUTCHours()%12||12,e,2)}function Ua(t,e){return Ki(1+fi.count(Pi(t),t),e,3)}function Ga(t,e){return Ki(t.getUTCMilliseconds(),e,3)}function Va(t,e){return Ga(t,e)+"000"}function qa(t,e){return Ki(t.getUTCMonth()+1,e,2)}function ja(t,e){return Ki(t.getUTCMinutes(),e,2)}function Ha(t,e){return Ki(t.getUTCSeconds(),e,2)}function Xa(t){var e=t.getUTCDay();return 0===e?7:e}function Ka(t,e){return Ki(Si.count(Pi(t)-1,t),e,2)}function Qa(t){var e=t.getUTCDay();return e>=4||0===e?Mi(t):Mi.ceil(t)}function Ja(t,e){return t=Qa(t),Ki(Mi.count(Pi(t),t)+(4===Pi(t).getUTCDay()),e,2)}function ts(t){return t.getUTCDay()}function es(t,e){return Ki(Ci.count(Pi(t)-1,t),e,2)}function ns(t,e){return Ki(t.getUTCFullYear()%100,e,2)}function rs(t,e){return Ki((t=Qa(t)).getUTCFullYear()%100,e,2)}function is(t,e){return Ki(t.getUTCFullYear()%1e4,e,4)}function as(t,e){var n=t.getUTCDay();return Ki((t=n>=4||0===n?Mi(t):Mi.ceil(t)).getUTCFullYear()%1e4,e,4)}function ss(){return"+0000"}function os(){return"%"}function ls(t){return+t}function cs(t){return Math.floor(+t/1e3)}function hs(t){return new Date(t)}function us(t){return t instanceof Date?+t:+new Date(+t)}function ds(t,e,n,r,i,a,s,o,l,c){var h=Pr(),u=h.invert,d=h.domain,p=c(".%L"),g=c(":%S"),f=c("%I:%M"),m=c("%I %p"),y=c("%a %d"),v=c("%b %d"),x=c("%B"),b=c("%Y");function w(t){return(l(t)=12)]},q:function(t){return 1+~~(t.getMonth()/3)},Q:ls,s:cs,S:La,u:Ma,U:Na,V:Ra,w:Da,W:Oa,x:null,X:null,y:Pa,Y:Ba,Z:Wa,"%":os},b={a:function(t){return s[t.getUTCDay()]},A:function(t){return a[t.getUTCDay()]},b:function(t){return l[t.getUTCMonth()]},B:function(t){return o[t.getUTCMonth()]},c:null,d:za,e:za,f:Va,g:rs,G:as,H:Za,I:Ya,j:Ua,L:Ga,m:qa,M:ja,p:function(t){return i[+(t.getUTCHours()>=12)]},q:function(t){return 1+~~(t.getUTCMonth()/3)},Q:ls,s:cs,S:Ha,u:Xa,U:Ka,V:Ja,w:ts,W:es,x:null,X:null,y:ns,Y:is,Z:ss,"%":os},w={a:function(t,e,n){var r=p.exec(e.slice(n));return r?(t.w=g.get(r[0].toLowerCase()),n+r[0].length):-1},A:function(t,e,n){var r=u.exec(e.slice(n));return r?(t.w=d.get(r[0].toLowerCase()),n+r[0].length):-1},b:function(t,e,n){var r=y.exec(e.slice(n));return r?(t.m=v.get(r[0].toLowerCase()),n+r[0].length):-1},B:function(t,e,n){var r=f.exec(e.slice(n));return r?(t.m=m.get(r[0].toLowerCase()),n+r[0].length):-1},c:function(t,n,r){return _(t,e,n,r)},d:ua,e:ua,f:ya,g:oa,G:sa,H:pa,I:pa,j:da,L:ma,m:ha,M:ga,p:function(t,e,n){var r=c.exec(e.slice(n));return r?(t.p=h.get(r[0].toLowerCase()),n+r[0].length):-1},q:ca,Q:xa,s:ba,S:fa,u:na,U:ra,V:ia,w:ea,W:aa,x:function(t,e,r){return _(t,n,e,r)},X:function(t,e,n){return _(t,r,e,n)},y:oa,Y:sa,Z:la,"%":va};function k(t,e){return function(n){var r,i,a,s=[],o=-1,l=0,c=t.length;for(n instanceof Date||(n=new Date(+n));++o53)return null;"w"in a||(a.w=1),"Z"in a?(i=(r=Yi(Ui(a.y,0,1))).getUTCDay(),r=i>4||0===i?Ci.ceil(r):Ci(r),r=fi.offset(r,7*(a.V-1)),a.y=r.getUTCFullYear(),a.m=r.getUTCMonth(),a.d=r.getUTCDate()+(a.w+6)%7):(i=(r=Zi(Ui(a.y,0,1))).getDay(),r=i>4||0===i?xi.ceil(r):xi(r),r=gi.offset(r,7*(a.V-1)),a.y=r.getFullYear(),a.m=r.getMonth(),a.d=r.getDate()+(a.w+6)%7)}else("W"in a||"U"in a)&&("w"in a||(a.w="u"in a?a.u%7:"W"in a?1:0),i="Z"in a?Yi(Ui(a.y,0,1)).getUTCDay():Zi(Ui(a.y,0,1)).getDay(),a.m=0,a.d="W"in a?(a.w+6)%7+7*a.W-(i+5)%7:a.w+7*a.U-(i+6)%7);return"Z"in a?(a.H+=a.Z/100|0,a.M+=a.Z%100,Yi(a)):Zi(a)}}function _(t,e,n,r){for(var i,a,s=0,o=e.length,l=n.length;s=l)return-1;if(37===(i=e.charCodeAt(s++))){if(i=e.charAt(s++),!(a=w[i in qi?e.charAt(s++):i])||(r=a(t,n,r))<0)return-1}else if(i!=n.charCodeAt(r++))return-1}return r}return x.x=k(n,x),x.X=k(r,x),x.c=k(e,x),b.x=k(n,b),b.X=k(r,b),b.c=k(e,b),{format:function(t){var e=k(t+="",x);return e.toString=function(){return t},e},parse:function(t){var e=T(t+="",!1);return e.toString=function(){return t},e},utcFormat:function(t){var e=k(t+="",b);return e.toString=function(){return t},e},utcParse:function(t){var e=T(t+="",!0);return e.toString=function(){return t},e}}}({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}),Vi=Gi.format,Gi.parse,Gi.utcFormat,Gi.utcParse;const gs=function(t){for(var e=new Array(10),n=0;n<10;)e[n]="#"+t.slice(6*n,6*++n);return e}("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab");function fs(t){return"string"==typeof t?new At([[document.querySelector(t)]],[document.documentElement]):new At([[t]],Ct)}function ms(t){return function(){return t}}const ys=Math.abs,vs=Math.atan2,xs=Math.cos,bs=Math.max,ws=Math.min,ks=Math.sin,Ts=Math.sqrt,_s=1e-12,Es=Math.PI,Ss=Es/2,Cs=2*Es;function As(t){return t>=1?Ss:t<=-1?-Ss:Math.asin(t)}const Ls=Math.PI,Ms=2*Ls,Ns=1e-6,Is=Ms-Ns;function Rs(t){this._+=t[0];for(let e=1,n=t.length;e=0))throw new Error(`invalid digits: ${t}`);if(e>15)return Rs;const n=10**e;return function(t){this._+=t[0];for(let e=1,r=t.length;eNs)if(Math.abs(h*o-l*c)>Ns&&i){let d=n-a,p=r-s,g=o*o+l*l,f=d*d+p*p,m=Math.sqrt(g),y=Math.sqrt(u),v=i*Math.tan((Ls-Math.acos((g+u-f)/(2*m*y)))/2),x=v/y,b=v/m;Math.abs(x-1)>Ns&&this._append`L${t+x*c},${e+x*h}`,this._append`A${i},${i},0,0,${+(h*d>c*p)},${this._x1=t+b*o},${this._y1=e+b*l}`}else this._append`L${this._x1=t},${this._y1=e}`}arc(t,e,n,r,i,a){if(t=+t,e=+e,a=!!a,(n=+n)<0)throw new Error(`negative radius: ${n}`);let s=n*Math.cos(r),o=n*Math.sin(r),l=t+s,c=e+o,h=1^a,u=a?r-i:i-r;null===this._x1?this._append`M${l},${c}`:(Math.abs(this._x1-l)>Ns||Math.abs(this._y1-c)>Ns)&&this._append`L${l},${c}`,n&&(u<0&&(u=u%Ms+Ms),u>Is?this._append`A${n},${n},0,1,${h},${t-s},${e-o}A${n},${n},0,1,${h},${this._x1=l},${this._y1=c}`:u>Ns&&this._append`A${n},${n},0,${+(u>=Ls)},${h},${this._x1=t+n*Math.cos(i)},${this._y1=e+n*Math.sin(i)}`)}rect(t,e,n,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+e}h${n=+n}v${+r}h${-n}Z`}toString(){return this._}}function Os(t){let e=3;return t.digits=function(n){if(!arguments.length)return e;if(null==n)e=null;else{const t=Math.floor(n);if(!(t>=0))throw new RangeError(`invalid digits: ${n}`);e=t}return t},()=>new Ds(e)}function Ps(t){return t.innerRadius}function $s(t){return t.outerRadius}function Bs(t){return t.startAngle}function Fs(t){return t.endAngle}function Ws(t){return t&&t.padAngle}function zs(t,e,n,r,i,a,s){var o=t-n,l=e-r,c=(s?a:-a)/Ts(o*o+l*l),h=c*l,u=-c*o,d=t+h,p=e+u,g=n+h,f=r+u,m=(d+g)/2,y=(p+f)/2,v=g-d,x=f-p,b=v*v+x*x,w=i-a,k=d*f-g*p,T=(x<0?-1:1)*Ts(bs(0,w*w*b-k*k)),_=(k*x-v*T)/b,E=(-k*v-x*T)/b,S=(k*x+v*T)/b,C=(-k*v+x*T)/b,A=_-m,L=E-y,M=S-m,N=C-y;return A*A+L*L>M*M+N*N&&(_=S,E=C),{cx:_,cy:E,x01:-h,y01:-u,x11:_*(i/w-1),y11:E*(i/w-1)}}function Zs(){var t=Ps,e=$s,n=ms(0),r=null,i=Bs,a=Fs,s=Ws,o=null,l=Os(c);function c(){var c,h,u,d=+t.apply(this,arguments),p=+e.apply(this,arguments),g=i.apply(this,arguments)-Ss,f=a.apply(this,arguments)-Ss,m=ys(f-g),y=f>g;if(o||(o=c=l()),p_s)if(m>Cs-_s)o.moveTo(p*xs(g),p*ks(g)),o.arc(0,0,p,g,f,!y),d>_s&&(o.moveTo(d*xs(f),d*ks(f)),o.arc(0,0,d,f,g,y));else{var v,x,b=g,w=f,k=g,T=f,_=m,E=m,S=s.apply(this,arguments)/2,C=S>_s&&(r?+r.apply(this,arguments):Ts(d*d+p*p)),A=ws(ys(p-d)/2,+n.apply(this,arguments)),L=A,M=A;if(C>_s){var N=As(C/d*ks(S)),I=As(C/p*ks(S));(_-=2*N)>_s?(k+=N*=y?1:-1,T-=N):(_=0,k=T=(g+f)/2),(E-=2*I)>_s?(b+=I*=y?1:-1,w-=I):(E=0,b=w=(g+f)/2)}var R=p*xs(b),D=p*ks(b),O=d*xs(T),P=d*ks(T);if(A>_s){var $,B=p*xs(w),F=p*ks(w),W=d*xs(k),z=d*ks(k);if(m1?0:u<-1?Es:Math.acos(u))/2),q=Ts($[0]*$[0]+$[1]*$[1]);L=ws(A,(d-q)/(V-1)),M=ws(A,(p-q)/(V+1))}else L=M=0}E>_s?M>_s?(v=zs(W,z,R,D,p,M,y),x=zs(B,F,O,P,p,M,y),o.moveTo(v.cx+v.x01,v.cy+v.y01),M_s&&_>_s?L>_s?(v=zs(O,P,B,F,d,-L,y),x=zs(R,D,W,z,d,-L,y),o.lineTo(v.cx+v.x01,v.cy+v.y01),Lt?1:e>=t?0:NaN}function Xs(t){return t}function Ks(){var t=Xs,e=Hs,n=null,r=ms(0),i=ms(Cs),a=ms(0);function s(s){var o,l,c,h,u,d=(s=Ys(s)).length,p=0,g=new Array(d),f=new Array(d),m=+r.apply(this,arguments),y=Math.min(Cs,Math.max(-Cs,i.apply(this,arguments)-m)),v=Math.min(Math.abs(y)/d,a.apply(this,arguments)),x=v*(y<0?-1:1);for(o=0;o0&&(p+=u);for(null!=e?g.sort((function(t,n){return e(f[t],f[n])})):null!=n&&g.sort((function(t,e){return n(s[t],s[e])})),o=0,c=p?(y-d*x)/p:0;o0?u*c:0)+x,f[l]={data:s[l],index:o,value:u,startAngle:m,endAngle:h,padAngle:v};return f}return s.value=function(e){return arguments.length?(t="function"==typeof e?e:ms(+e),s):t},s.sortValues=function(t){return arguments.length?(e=t,n=null,s):e},s.sort=function(t){return arguments.length?(n=t,e=null,s):n},s.startAngle=function(t){return arguments.length?(r="function"==typeof t?t:ms(+t),s):r},s.endAngle=function(t){return arguments.length?(i="function"==typeof t?t:ms(+t),s):i},s.padAngle=function(t){return arguments.length?(a="function"==typeof t?t:ms(+t),s):a},s}function Qs(){}function Js(t,e,n){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+n)/6)}function to(t){this._context=t}function eo(t){return new to(t)}function no(t){this._context=t}function ro(t){return new no(t)}function io(t){this._context=t}function ao(t){return new io(t)}Ds.prototype,Array.prototype.slice,Us.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e)}}},to.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Js(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Js(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},no.prototype={areaStart:Qs,areaEnd:Qs,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x2,this._y2),this._context.closePath();break;case 2:this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break;case 3:this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:Js(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}},io.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(n,r):this._context.moveTo(n,r);break;case 3:this._point=4;default:Js(this,t,e)}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};class so{constructor(t,e){this._context=t,this._x=e}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line}point(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,e,t,e):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+e)/2,t,this._y0,t,e)}this._x0=t,this._y0=e}}function oo(t){return new so(t,!0)}function lo(t){return new so(t,!1)}function co(t,e){this._basis=new to(t),this._beta=e}co.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,n=t.length-1;if(n>0)for(var r,i=t[0],a=e[0],s=t[n]-i,o=e[n]-a,l=-1;++l<=n;)r=l/n,this._basis.point(this._beta*t[l]+(1-this._beta)*(i+r*s),this._beta*e[l]+(1-this._beta)*(a+r*o));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};const ho=function t(e){function n(t){return 1===e?new to(t):new co(t,e)}return n.beta=function(e){return t(+e)},n}(.85);function uo(t,e,n){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-n),t._x2,t._y2)}function po(t,e){this._context=t,this._k=(1-e)/6}po.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:uo(this,this._x1,this._y1)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:uo(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const go=function t(e){function n(t){return new po(t,e)}return n.tension=function(e){return t(+e)},n}(0);function fo(t,e){this._context=t,this._k=(1-e)/6}fo.prototype={areaStart:Qs,areaEnd:Qs,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:uo(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const mo=function t(e){function n(t){return new fo(t,e)}return n.tension=function(e){return t(+e)},n}(0);function yo(t,e){this._context=t,this._k=(1-e)/6}yo.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:uo(this,t,e)}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const vo=function t(e){function n(t){return new yo(t,e)}return n.tension=function(e){return t(+e)},n}(0);function xo(t,e,n){var r=t._x1,i=t._y1,a=t._x2,s=t._y2;if(t._l01_a>_s){var o=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,l=3*t._l01_a*(t._l01_a+t._l12_a);r=(r*o-t._x0*t._l12_2a+t._x2*t._l01_2a)/l,i=(i*o-t._y0*t._l12_2a+t._y2*t._l01_2a)/l}if(t._l23_a>_s){var c=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,h=3*t._l23_a*(t._l23_a+t._l12_a);a=(a*c+t._x1*t._l23_2a-e*t._l12_2a)/h,s=(s*c+t._y1*t._l23_2a-n*t._l12_2a)/h}t._context.bezierCurveTo(r,i,a,s,t._x2,t._y2)}function bo(t,e){this._context=t,this._alpha=e}bo.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2)}(this._line||0!==this._line&&1===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:xo(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const wo=function t(e){function n(t){return e?new bo(t,e):new po(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function ko(t,e){this._context=t,this._alpha=e}ko.prototype={areaStart:Qs,areaEnd:Qs,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:this._context.moveTo(this._x3,this._y3),this._context.closePath();break;case 2:this._context.lineTo(this._x3,this._y3),this._context.closePath();break;case 3:this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5)}},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:xo(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const To=function t(e){function n(t){return e?new ko(t,e):new fo(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function _o(t,e){this._context=t,this._alpha=e}_o.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||0!==this._line&&3===this._point)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var n=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+r*r,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:xo(this,t,e)}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};const Eo=function t(e){function n(t){return e?new _o(t,e):new yo(t,0)}return n.alpha=function(e){return t(+e)},n}(.5);function So(t){this._context=t}function Co(t){return new So(t)}function Ao(t){return t<0?-1:1}function Lo(t,e,n){var r=t._x1-t._x0,i=e-t._x1,a=(t._y1-t._y0)/(r||i<0&&-0),s=(n-t._y1)/(i||r<0&&-0),o=(a*i+s*r)/(r+i);return(Ao(a)+Ao(s))*Math.min(Math.abs(a),Math.abs(s),.5*Math.abs(o))||0}function Mo(t,e){var n=t._x1-t._x0;return n?(3*(t._y1-t._y0)/n-e)/2:e}function No(t,e,n){var r=t._x0,i=t._y0,a=t._x1,s=t._y1,o=(a-r)/3;t._context.bezierCurveTo(r+o,i+o*e,a-o,s-o*n,a,s)}function Io(t){this._context=t}function Ro(t){this._context=new Do(t)}function Do(t){this._context=t}function Oo(t){return new Io(t)}function Po(t){return new Ro(t)}function $o(t){this._context=t}function Bo(t){var e,n,r=t.length-1,i=new Array(r),a=new Array(r),s=new Array(r);for(i[0]=0,a[0]=2,s[0]=t[0]+2*t[1],e=1;e=0;--e)i[e]=(s[e]-i[e+1])/a[e];for(a[r-1]=(t[r]+i[r-1])/2,e=0;e=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var n=this._x*(1-this._t)+t*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,e)}}this._x=t,this._y=e}},Uo.prototype={constructor:Uo,scale:function(t){return 1===t?this:new Uo(this.k*t,this.x,this.y)},translate:function(t,e){return 0===t&0===e?this:new Uo(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}},new Uo(1,0,0),Uo.prototype},4840:(t,e,n)=>{"use strict";n.d(e,{bK:()=>ve});var r=n(870),i=n(2402),a=0;const s=function(t){var e=++a;return(0,i.Z)(t)+e};var o=n(2002),l=n(7961),c=n(3836),h=Math.ceil,u=Math.max;var d=n(439),p=n(6770);const g=function(t,e,n){return n&&"number"!=typeof n&&(0,d.Z)(t,e,n)&&(e=n=void 0),t=(0,p.Z)(t),void 0===e?(e=t,t=0):e=(0,p.Z)(e),function(t,e,n,r){for(var i=-1,a=u(h((e-t)/(n||1)),0),s=Array(a);a--;)s[r?a:++i]=t,t+=n;return s}(t,e,n=void 0===n?t0;--o)if(r=e[o].dequeue()){i=i.concat(b(t,e,n,r,!0));break}}return i}(n.graph,n.buckets,n.zeroIdx);return l.Z(c.Z(i,(function(e){return t.outEdges(e.v,e.w)})))}(t,function(t){return function(e){return t.edge(e).weight}}(t)):function(t){var e=[],n={},i={};return r.Z(t.nodes(),(function a(s){Object.prototype.hasOwnProperty.call(i,s)||(i[s]=!0,n[s]=!0,r.Z(t.outEdges(s),(function(t){Object.prototype.hasOwnProperty.call(n,t.w)?e.push(t):a(t.w)})),delete n[s])})),e}(t);r.Z(e,(function(e){var n=t.edge(e);t.removeEdge(e),n.forwardName=e.name,n.reversed=!0,t.setEdge(e.w,e.v,n,s("rev"))}))}var T=n(7103),_=n(7993),E=n(1910);var S=n(3948),C=n(3626);const A=(L=function(t,e){return null==t?{}:function(t,e){return(0,_.Z)(t,e,(function(e,n){return(0,E.Z)(t,n)}))}(t,e)},(0,C.Z)((0,S.Z)(L,void 0,l.Z),L+""));var L,M=n(3688),N=n(8e3);const I=function(t,e){return t>e};var R=n(9203);const D=function(t){return t&&t.length?(0,N.Z)(t,R.Z,I):void 0};var O=n(935),P=n(4752),$=n(2693),B=n(506);const F=function(t,e){var n={};return e=(0,B.Z)(e,3),(0,$.Z)(t,(function(t,r,i){(0,P.Z)(n,r,e(t,r,i))})),n};var W=n(9360),z=n(3729),Z=n(3402),Y=n(6092);const U=function(){return Y.Z.Date.now()};function G(t,e,n,r){var i;do{i=s(r)}while(t.hasNode(i));return n.dummy=e,t.setNode(i,n),i}function V(t){var e=new f.k({multigraph:t.isMultigraph()}).setGraph(t.graph());return r.Z(t.nodes(),(function(n){t.children(n).length||e.setNode(n,t.node(n))})),r.Z(t.edges(),(function(n){e.setEdge(n,t.edge(n))})),e}function q(t,e){var n,r,i=t.x,a=t.y,s=e.x-i,o=e.y-a,l=t.width/2,c=t.height/2;if(!s&&!o)throw new Error("Not possible to find intersection inside of the rectangle");return Math.abs(o)*l>Math.abs(s)*c?(o<0&&(c=-c),n=c*s/o,r=c):(s<0&&(l=-l),n=l,r=l*o/s),{x:i+n,y:a+r}}function j(t){var e=c.Z(g(X(t)+1),(function(){return[]}));return r.Z(t.nodes(),(function(n){var r=t.node(n),i=r.rank;W.Z(i)||(e[i][r.order]=n)})),e}function H(t,e,n,r){var i={width:0,height:0};return arguments.length>=4&&(i.rank=n,i.order=r),G(t,"border",i,e)}function X(t){return D(c.Z(t.nodes(),(function(e){var n=t.node(e).rank;if(!W.Z(n))return n})))}function K(t,e){var n=U();try{return e()}finally{console.log(t+" time: "+(U()-n)+"ms")}}function Q(t,e){return e()}function J(t,e,n,r,i,a){var s={width:0,height:0,rank:a,borderType:e},o=i[e][a-1],l=G(t,"border",s,n);i[e][a]=l,t.setParent(l,r),o&&t.setEdge(o,l,{weight:1})}function tt(t){r.Z(t.nodes(),(function(e){et(t.node(e))})),r.Z(t.edges(),(function(e){et(t.edge(e))}))}function et(t){var e=t.width;t.width=t.height,t.height=e}function nt(t){t.y=-t.y}function rt(t){var e=t.x;t.x=t.y,t.y=e}var it=n(676);const at=function(t,e){return t&&t.length?(0,N.Z)(t,(0,B.Z)(e,2),it.Z):void 0};function st(t){var e={};r.Z(t.sources(),(function n(r){var i=t.node(r);if(Object.prototype.hasOwnProperty.call(e,r))return i.rank;e[r]=!0;var a=z.Z(c.Z(t.outEdges(r),(function(e){return n(e.w)-t.edge(e).minlen})));return a!==Number.POSITIVE_INFINITY&&null!=a||(a=0),i.rank=a}))}function ot(t,e){return t.node(e.w).rank-t.node(e.v).rank-t.edge(e).minlen}function lt(t){var e,n,r=new f.k({directed:!1}),i=t.nodes()[0],a=t.nodeCount();for(r.setNode(i,{});ct(r,t)s.lim&&(o=s,l=!0);var c=pt.Z(e.edges(),(function(e){return l===Pt(0,t.node(e.v),o)&&l!==Pt(0,t.node(e.w),o)}));return at(c,(function(t){return ot(e,t)}))}function Ot(t,e,n,i){var a=n.v,s=n.w;t.removeEdge(a,s),t.setEdge(i.v,i.w,{}),Nt(t),Lt(t,e),function(t,e){var n=dt.Z(t.nodes(),(function(t){return!e.node(t).parent})),i=function(t,e){return St(t,e,"pre")}(t,n);i=i.slice(1),r.Z(i,(function(n){var r=t.node(n).parent,i=e.edge(n,r),a=!1;i||(i=e.edge(r,n),a=!0),e.node(n).rank=e.node(r).rank+(a?i.minlen:-i.minlen)}))}(t,e)}function Pt(t,e,n){return n.low<=e.lim&&e.lim<=n.lim}function $t(t){switch(t.graph().ranker){case"network-simplex":default:!function(t){At(t)}(t);break;case"tight-tree":!function(t){st(t),lt(t)}(t);break;case"longest-path":Bt(t)}}n(7556),At.initLowLimValues=Nt,At.initCutValues=Lt,At.calcCutValue=Mt,At.leaveEdge=Rt,At.enterEdge=Dt,At.exchangeEdges=Ot;var Bt=st;var Ft=n(4657),Wt=n(4283);function zt(t){var e=G(t,"root",{},"_root"),n=function(t){var e={};function n(i,a){var s=t.children(i);s&&s.length&&r.Z(s,(function(t){n(t,a+1)})),e[i]=a}return r.Z(t.children(),(function(t){n(t,1)})),e}(t),i=D(Ft.Z(n))-1,a=2*i+1;t.graph().nestingRoot=e,r.Z(t.edges(),(function(e){t.edge(e).minlen*=a}));var s=function(t){return Wt.Z(t.edges(),(function(e,n){return e+t.edge(n).weight}),0)}(t)+1;r.Z(t.children(),(function(r){Zt(t,e,a,s,i,n,r)})),t.graph().nodeRankFactor=a}function Zt(t,e,n,i,a,s,o){var l=t.children(o);if(l.length){var c=H(t,"_bt"),h=H(t,"_bb"),u=t.node(o);t.setParent(c,o),u.borderTop=c,t.setParent(h,o),u.borderBottom=h,r.Z(l,(function(r){Zt(t,e,n,i,a,s,r);var l=t.node(r),u=l.borderTop?l.borderTop:r,d=l.borderBottom?l.borderBottom:r,p=l.borderTop?i:2*i,g=u!==d?1:a-s[o]+1;t.setEdge(c,u,{weight:p,minlen:g,nestingEdge:!0}),t.setEdge(d,h,{weight:p,minlen:g,nestingEdge:!0})})),t.parent(o)||t.setEdge(e,c,{weight:0,minlen:a+s[o]})}else o!==e&&t.setEdge(e,o,{weight:0,minlen:n})}var Yt=n(9943);const Ut=function(t){return(0,Yt.Z)(t,5)};var Gt=n(2954);const Vt=function(t,e){return function(t,e,n){for(var r=-1,i=t.length,a=e.length,s={};++re||a&&s&&l&&!o&&!c||r&&s&&l||!n&&l||!i)return 1;if(!r&&!a&&!c&&t=o?l:l*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}))},ee=(0,n(9581).Z)((function(t,e){if(null==t)return[];var n=e.length;return n>1&&(0,d.Z)(t,e[0],e[1])?e=[]:n>2&&(0,d.Z)(e[0],e[1],e[2])&&(e=[e[0]]),te(t,(0,qt.Z)(e,1),[])}));function ne(t,e){for(var n=0,r=1;r0;)e%2&&(n+=h[e+1]),h[e=e-1>>1]+=t.weight;u+=t.weight*n}))),u}function ie(t,e){var n,i=function(t,e){var n={lhs:[],rhs:[]};return r.Z(t,(function(t){var e;e=t,Object.prototype.hasOwnProperty.call(e,"barycenter")?n.lhs.push(t):n.rhs.push(t)})),n}(t),a=i.lhs,s=ee(i.rhs,(function(t){return-t.i})),o=[],c=0,h=0,u=0;a.sort((n=!!e,function(t,e){return t.barycentere.barycenter?1:n?e.i-t.i:t.i-e.i})),u=ae(o,s,u),r.Z(a,(function(t){u+=t.vs.length,o.push(t.vs),c+=t.barycenter*t.weight,h+=t.weight,u=ae(o,s,u)}));var d={vs:l.Z(o)};return h&&(d.barycenter=c/h,d.weight=h),d}function ae(t,e,n){for(var r;e.length&&(r=O.Z(e)).i<=n;)e.pop(),t.push(r.vs),n++;return n}function se(t,e,n,i){var a=t.children(e),s=t.node(e),o=s?s.borderLeft:void 0,h=s?s.borderRight:void 0,u={};o&&(a=pt.Z(a,(function(t){return t!==o&&t!==h})));var d=function(t,e){return c.Z(e,(function(e){var n=t.inEdges(e);if(n.length){var r=Wt.Z(n,(function(e,n){var r=t.edge(n),i=t.node(n.v);return{sum:e.sum+r.weight*i.order,weight:e.weight+r.weight}}),{sum:0,weight:0});return{v:e,barycenter:r.sum/r.weight,weight:r.weight}}return{v:e}}))}(t,a);r.Z(d,(function(e){if(t.children(e.v).length){var r=se(t,e.v,n,i);u[e.v]=r,Object.prototype.hasOwnProperty.call(r,"barycenter")&&(a=e,s=r,W.Z(a.barycenter)?(a.barycenter=s.barycenter,a.weight=s.weight):(a.barycenter=(a.barycenter*a.weight+s.barycenter*s.weight)/(a.weight+s.weight),a.weight+=s.weight))}var a,s}));var p=function(t,e){var n={};return r.Z(t,(function(t,e){var r=n[t.v]={indegree:0,in:[],out:[],vs:[t.v],i:e};W.Z(t.barycenter)||(r.barycenter=t.barycenter,r.weight=t.weight)})),r.Z(e.edges(),(function(t){var e=n[t.v],r=n[t.w];W.Z(e)||W.Z(r)||(r.indegree++,e.out.push(n[t.w]))})),function(t){var e=[];function n(t){return function(e){var n,r,i,a;e.merged||(W.Z(e.barycenter)||W.Z(t.barycenter)||e.barycenter>=t.barycenter)&&(r=e,i=0,a=0,(n=t).weight&&(i+=n.barycenter*n.weight,a+=n.weight),r.weight&&(i+=r.barycenter*r.weight,a+=r.weight),n.vs=r.vs.concat(n.vs),n.barycenter=i/a,n.weight=a,n.i=Math.min(r.i,n.i),r.merged=!0)}}function i(e){return function(n){n.in.push(e),0==--n.indegree&&t.push(n)}}for(;t.length;){var a=t.pop();e.push(a),r.Z(a.in.reverse(),n(a)),r.Z(a.out,i(a))}return c.Z(pt.Z(e,(function(t){return!t.merged})),(function(t){return A(t,["vs","i","barycenter","weight"])}))}(pt.Z(n,(function(t){return!t.indegree})))}(d,n);!function(t,e){r.Z(t,(function(t){t.vs=l.Z(t.vs.map((function(t){return e[t]?e[t].vs:t})))}))}(p,u);var g=ie(p,i);if(o&&(g.vs=l.Z([o,g.vs,h]),t.predecessors(o).length)){var f=t.node(t.predecessors(o)[0]),m=t.node(t.predecessors(h)[0]);Object.prototype.hasOwnProperty.call(g,"barycenter")||(g.barycenter=0,g.weight=0),g.barycenter=(g.barycenter*g.weight+f.order+m.order)/(g.weight+2),g.weight+=2}return g}function oe(t,e,n){return c.Z(e,(function(e){return function(t,e,n){var i=function(t){for(var e;t.hasNode(e=s("_root")););return e}(t),a=new f.k({compound:!0}).setGraph({root:i}).setDefaultNodeLabel((function(e){return t.node(e)}));return r.Z(t.nodes(),(function(s){var o=t.node(s),l=t.parent(s);(o.rank===e||o.minRank<=e&&e<=o.maxRank)&&(a.setNode(s),a.setParent(s,l||i),r.Z(t[n](s),(function(e){var n=e.v===s?e.w:e.v,r=a.edge(n,s),i=W.Z(r)?0:r.weight;a.setEdge(n,s,{weight:t.edge(e).weight+i})})),Object.prototype.hasOwnProperty.call(o,"minRank")&&a.setNode(s,{borderLeft:o.borderLeft[e],borderRight:o.borderRight[e]}))})),a}(t,e,n)}))}function le(t,e){var n=new f.k;r.Z(t,(function(t){var i=t.graph().root,a=se(t,i,n,e);r.Z(a.vs,(function(e,n){t.node(e).order=n})),function(t,e,n){var i,a={};r.Z(n,(function(n){for(var r,s,o=t.parent(n);o;){if((r=t.parent(o))?(s=a[r],a[r]=o):(s=i,i=o),s&&s!==o)return void e.setEdge(s,o);o=r}}))}(t,n,a.vs)}))}function ce(t,e){r.Z(e,(function(e){r.Z(e,(function(e,n){t.node(e).order=n}))}))}var he=n(8882);const ue=function(t,e){return t&&(0,$.Z)(t,(0,he.Z)(e))};var de=n(5381),pe=n(7590);const ge=function(t,e){return null==t?t:(0,de.Z)(t,(0,he.Z)(e),pe.Z)};function fe(t,e,n){if(e>n){var r=e;e=n,n=r}var i=t[e];i||(t[e]=i={}),i[n]=!0}function me(t,e,n){if(e>n){var r=e;e=n,n=r}return!!t[e]&&Object.prototype.hasOwnProperty.call(t[e],n)}function ye(t){var e,n=j(t),i=T.Z(function(t,e){var n={};return Wt.Z(e,(function(e,i){var a=0,s=0,o=e.length,l=O.Z(i);return r.Z(i,(function(e,c){var h=function(t,e){if(t.node(e).dummy)return dt.Z(t.predecessors(e),(function(e){return t.node(e).dummy}))}(t,e),u=h?t.node(h).order:o;(h||e===l)&&(r.Z(i.slice(s,c+1),(function(e){r.Z(t.predecessors(e),(function(r){var i=t.node(r),s=i.order;!(so)&&fe(n,e,l)}))}))}return Wt.Z(e,(function(e,n){var a,s=-1,o=0;return r.Z(n,(function(r,l){if("border"===t.node(r).dummy){var c=t.predecessors(r);c.length&&(a=t.node(c[0]).order,i(n,o,l,s,a),o=l,s=a)}i(n,o,n.length,a,e.length)})),n})),n}(t,n)),a={};r.Z(["u","d"],(function(s){e="u"===s?n:Ft.Z(n).reverse(),r.Z(["l","r"],(function(n){"r"===n&&(e=c.Z(e,(function(t){return Ft.Z(t).reverse()})));var o=("u"===s?t.predecessors:t.successors).bind(t),l=function(t,e,n,i){var a={},s={},o={};return r.Z(e,(function(t){r.Z(t,(function(t,e){a[t]=t,s[t]=t,o[t]=e}))})),r.Z(e,(function(t){var e=-1;r.Z(t,(function(t){var r=i(t);if(r.length){r=ee(r,(function(t){return o[t]}));for(var l=(r.length-1)/2,c=Math.floor(l),h=Math.ceil(l);c<=h;++c){var u=r[c];s[t]===t&&e{var e=n(" buildLayoutGraph",(()=>function(t){var e=new f.k({multigraph:!0,compound:!0}),n=Ae(t.graph());return e.setGraph(T.Z({},be,Ce(n,xe),A(n,we))),r.Z(t.nodes(),(function(n){var r=Ae(t.node(n));e.setNode(n,M.Z(Ce(r,ke),Te)),e.setParent(n,t.parent(n))})),r.Z(t.edges(),(function(n){var r=Ae(t.edge(n));e.setEdge(n,T.Z({},Ee,Ce(r,_e),A(r,Se)))})),e}(t)));n(" runLayout",(()=>function(t,e){e(" makeSpaceForEdgeLabels",(()=>function(t){var e=t.graph();e.ranksep/=2,r.Z(t.edges(),(function(n){var r=t.edge(n);r.minlen*=2,"c"!==r.labelpos.toLowerCase()&&("TB"===e.rankdir||"BT"===e.rankdir?r.width+=r.labeloffset:r.height+=r.labeloffset)}))}(t))),e(" removeSelfEdges",(()=>function(t){r.Z(t.edges(),(function(e){if(e.v===e.w){var n=t.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e,label:t.edge(e)}),t.removeEdge(e)}}))}(t))),e(" acyclic",(()=>k(t))),e(" nestingGraph.run",(()=>zt(t))),e(" rank",(()=>$t(V(t)))),e(" injectEdgeLabelProxies",(()=>function(t){r.Z(t.edges(),(function(e){var n=t.edge(e);if(n.width&&n.height){var r=t.node(e.v),i={rank:(t.node(e.w).rank-r.rank)/2+r.rank,e};G(t,"edge-proxy",i,"_ep")}}))}(t))),e(" removeEmptyRanks",(()=>function(t){var e=z.Z(c.Z(t.nodes(),(function(e){return t.node(e).rank}))),n=[];r.Z(t.nodes(),(function(r){var i=t.node(r).rank-e;n[i]||(n[i]=[]),n[i].push(r)}));var i=0,a=t.graph().nodeRankFactor;r.Z(n,(function(e,n){W.Z(e)&&n%a!=0?--i:i&&r.Z(e,(function(e){t.node(e).rank+=i}))}))}(t))),e(" nestingGraph.cleanup",(()=>function(t){var e=t.graph();t.removeNode(e.nestingRoot),delete e.nestingRoot,r.Z(t.edges(),(function(e){t.edge(e).nestingEdge&&t.removeEdge(e)}))}(t))),e(" normalizeRanks",(()=>function(t){var e=z.Z(c.Z(t.nodes(),(function(e){return t.node(e).rank})));r.Z(t.nodes(),(function(n){var r=t.node(n);Z.Z(r,"rank")&&(r.rank-=e)}))}(t))),e(" assignRankMinMax",(()=>function(t){var e=0;r.Z(t.nodes(),(function(n){var r=t.node(n);r.borderTop&&(r.minRank=t.node(r.borderTop).rank,r.maxRank=t.node(r.borderBottom).rank,e=D(e,r.maxRank))})),t.graph().maxRank=e}(t))),e(" removeEdgeLabelProxies",(()=>function(t){r.Z(t.nodes(),(function(e){var n=t.node(e);"edge-proxy"===n.dummy&&(t.edge(n.e).labelRank=n.rank,t.removeNode(e))}))}(t))),e(" normalize.run",(()=>function(t){t.graph().dummyChains=[],r.Z(t.edges(),(function(e){!function(t,e){var n=e.v,r=t.node(n).rank,i=e.w,a=t.node(i).rank,s=e.name,o=t.edge(e),l=o.labelRank;if(a!==r+1){t.removeEdge(e);var c,h,u=void 0;for(h=0,++r;rfunction(t){var e=function(t){var e={},n=0;return r.Z(t.children(),(function i(a){var s=n;r.Z(t.children(a),i),e[a]={low:s,lim:n++}})),e}(t);r.Z(t.graph().dummyChains,(function(n){for(var r=t.node(n),i=r.edgeObj,a=function(t,e,n,r){var i,a,s=[],o=[],l=Math.min(e[n].low,e[r].low),c=Math.max(e[n].lim,e[r].lim);i=n;do{i=t.parent(i),s.push(i)}while(i&&(e[i].low>l||c>e[i].lim));for(a=i,i=r;(i=t.parent(i))!==a;)o.push(i);return{path:s.concat(o.reverse()),lca:a}}(t,e,i.v,i.w),s=a.path,o=a.lca,l=0,c=s[l],h=!0;n!==i.w;){if(r=t.node(n),h){for(;(c=s[l])!==o&&t.node(c).maxRankfunction(t){r.Z(t.children(),(function e(n){var i=t.children(n),a=t.node(n);if(i.length&&r.Z(i,e),Object.prototype.hasOwnProperty.call(a,"minRank")){a.borderLeft=[],a.borderRight=[];for(var s=a.minRank,o=a.maxRank+1;sfunction(t){var e=X(t),n=oe(t,g(1,e+1),"inEdges"),i=oe(t,g(e-1,-1,-1),"outEdges"),a=function(t){var e={},n=pt.Z(t.nodes(),(function(e){return!t.children(e).length})),i=D(c.Z(n,(function(e){return t.node(e).rank}))),a=c.Z(g(i+1),(function(){return[]})),s=ee(n,(function(e){return t.node(e).rank}));return r.Z(s,(function n(i){if(!Z.Z(e,i)){e[i]=!0;var s=t.node(i);a[s.rank].push(i),r.Z(t.successors(i),n)}})),a}(t);ce(t,a);for(var s,o=Number.POSITIVE_INFINITY,l=0,h=0;h<4;++l,++h){le(l%2?n:i,l%4>=2);var u=ne(t,a=j(t));ufunction(t){var e=j(t);r.Z(e,(function(e){var n=0;r.Z(e,(function(e,i){var a=t.node(e);a.order=i+n,r.Z(a.selfEdges,(function(e){G(t,"selfedge",{width:e.label.width,height:e.label.height,rank:a.rank,order:i+ ++n,e:e.e,label:e.label},"_se")})),delete a.selfEdges}))}))}(t))),e(" adjustCoordinateSystem",(()=>function(t){var e=t.graph().rankdir.toLowerCase();"lr"!==e&&"rl"!==e||tt(t)}(t))),e(" position",(()=>function(t){(function(t){var e=j(t),n=t.graph().ranksep,i=0;r.Z(e,(function(e){var a=D(c.Z(e,(function(e){return t.node(e).height})));r.Z(e,(function(e){t.node(e).y=i+a/2})),i+=a+n}))})(t=V(t)),ue(ye(t),(function(e,n){t.node(n).x=e}))}(t))),e(" positionSelfEdges",(()=>function(t){r.Z(t.nodes(),(function(e){var n=t.node(e);if("selfedge"===n.dummy){var r=t.node(n.e.v),i=r.x+r.width/2,a=r.y,s=n.x-i,o=r.height/2;t.setEdge(n.e,n.label),t.removeNode(e),n.label.points=[{x:i+2*s/3,y:a-o},{x:i+5*s/6,y:a-o},{x:i+s,y:a},{x:i+5*s/6,y:a+o},{x:i+2*s/3,y:a+o}],n.label.x=n.x,n.label.y=n.y}}))}(t))),e(" removeBorderNodes",(()=>function(t){r.Z(t.nodes(),(function(e){if(t.children(e).length){var n=t.node(e),r=t.node(n.borderTop),i=t.node(n.borderBottom),a=t.node(O.Z(n.borderLeft)),s=t.node(O.Z(n.borderRight));n.width=Math.abs(s.x-a.x),n.height=Math.abs(i.y-r.y),n.x=a.x+n.width/2,n.y=r.y+n.height/2}})),r.Z(t.nodes(),(function(e){"border"===t.node(e).dummy&&t.removeNode(e)}))}(t))),e(" normalize.undo",(()=>function(t){r.Z(t.graph().dummyChains,(function(e){var n,r=t.node(e),i=r.edgeLabel;for(t.setEdge(r.edgeObj,i);r.dummy;)n=t.successors(e)[0],t.removeNode(e),i.points.push({x:r.x,y:r.y}),"edge-label"===r.dummy&&(i.x=r.x,i.y=r.y,i.width=r.width,i.height=r.height),e=n,r=t.node(e)}))}(t))),e(" fixupEdgeLabelCoords",(()=>function(t){r.Z(t.edges(),(function(e){var n=t.edge(e);if(Object.prototype.hasOwnProperty.call(n,"x"))switch("l"!==n.labelpos&&"r"!==n.labelpos||(n.width-=n.labeloffset),n.labelpos){case"l":n.x-=n.width/2+n.labeloffset;break;case"r":n.x+=n.width/2+n.labeloffset}}))}(t))),e(" undoCoordinateSystem",(()=>function(t){var e=t.graph().rankdir.toLowerCase();"bt"!==e&&"rl"!==e||function(t){r.Z(t.nodes(),(function(e){nt(t.node(e))})),r.Z(t.edges(),(function(e){var n=t.edge(e);r.Z(n.points,nt),Object.prototype.hasOwnProperty.call(n,"y")&&nt(n)}))}(t),"lr"!==e&&"rl"!==e||(function(t){r.Z(t.nodes(),(function(e){rt(t.node(e))})),r.Z(t.edges(),(function(e){var n=t.edge(e);r.Z(n.points,rt),Object.prototype.hasOwnProperty.call(n,"x")&&rt(n)}))}(t),tt(t))}(t))),e(" translateGraph",(()=>function(t){var e=Number.POSITIVE_INFINITY,n=0,i=Number.POSITIVE_INFINITY,a=0,s=t.graph(),o=s.marginx||0,l=s.marginy||0;function c(t){var r=t.x,s=t.y,o=t.width,l=t.height;e=Math.min(e,r-o/2),n=Math.max(n,r+o/2),i=Math.min(i,s-l/2),a=Math.max(a,s+l/2)}r.Z(t.nodes(),(function(e){c(t.node(e))})),r.Z(t.edges(),(function(e){var n=t.edge(e);Object.prototype.hasOwnProperty.call(n,"x")&&c(n)})),e-=o,i-=l,r.Z(t.nodes(),(function(n){var r=t.node(n);r.x-=e,r.y-=i})),r.Z(t.edges(),(function(n){var a=t.edge(n);r.Z(a.points,(function(t){t.x-=e,t.y-=i})),Object.prototype.hasOwnProperty.call(a,"x")&&(a.x-=e),Object.prototype.hasOwnProperty.call(a,"y")&&(a.y-=i)})),s.width=n-e+o,s.height=a-i+l}(t))),e(" assignNodeIntersects",(()=>function(t){r.Z(t.edges(),(function(e){var n,r,i=t.edge(e),a=t.node(e.v),s=t.node(e.w);i.points?(n=i.points[0],r=i.points[i.points.length-1]):(i.points=[],n=s,r=a),i.points.unshift(q(a,n)),i.points.push(q(s,r))}))}(t))),e(" reversePoints",(()=>function(t){r.Z(t.edges(),(function(e){var n=t.edge(e);n.reversed&&n.points.reverse()}))}(t))),e(" acyclic.undo",(()=>function(t){r.Z(t.edges(),(function(e){var n=t.edge(e);if(n.reversed){t.removeEdge(e);var r=n.forwardName;delete n.reversed,delete n.forwardName,t.setEdge(e.w,e.v,n,r)}}))}(t)))}(e,n))),n(" updateInputGraph",(()=>function(t,e){r.Z(t.nodes(),(function(n){var r=t.node(n),i=e.node(n);r&&(r.x=i.x,r.y=i.y,e.children(n).length&&(r.width=i.width,r.height=i.height))})),r.Z(t.edges(),(function(n){var r=t.edge(n),i=e.edge(n);r.points=i.points,Object.prototype.hasOwnProperty.call(i,"x")&&(r.x=i.x,r.y=i.y)})),t.graph().width=e.graph().width,t.graph().height=e.graph().height}(t,e)))}))}var xe=["nodesep","edgesep","ranksep","marginx","marginy"],be={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},we=["acyclicer","ranker","rankdir","align"],ke=["width","height"],Te={width:0,height:0},_e=["minlen","weight","width","height","labeloffset"],Ee={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},Se=["labelpos"];function Ce(t,e){return F(A(t,e),Number)}function Ae(t){var e={};return r.Z(t,(function(t,n){e[n.toLowerCase()]=t})),e}},7556:(t,e,n)=>{"use strict";n.d(e,{k:()=>b});var r=n(2002),i=n(3234),a=n(7179),s=n(9601),o=n(9697),l=n(870),c=n(9360),h=n(5140),u=n(9581),d=n(184),p=n(836);const g=(0,u.Z)((function(t){return(0,d.Z)((0,h.Z)(t,1,p.Z,!0))}));var f=n(4657),m=n(4283),y="\0",v="\0",x="";class b{constructor(t={}){this._isDirected=!Object.prototype.hasOwnProperty.call(t,"directed")||t.directed,this._isMultigraph=!!Object.prototype.hasOwnProperty.call(t,"multigraph")&&t.multigraph,this._isCompound=!!Object.prototype.hasOwnProperty.call(t,"compound")&&t.compound,this._label=void 0,this._defaultNodeLabelFn=r.Z(void 0),this._defaultEdgeLabelFn=r.Z(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[v]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(t){return this._label=t,this}graph(){return this._label}setDefaultNodeLabel(t){return i.Z(t)||(t=r.Z(t)),this._defaultNodeLabelFn=t,this}nodeCount(){return this._nodeCount}nodes(){return a.Z(this._nodes)}sources(){var t=this;return s.Z(this.nodes(),(function(e){return o.Z(t._in[e])}))}sinks(){var t=this;return s.Z(this.nodes(),(function(e){return o.Z(t._out[e])}))}setNodes(t,e){var n=arguments,r=this;return l.Z(t,(function(t){n.length>1?r.setNode(t,e):r.setNode(t)})),this}setNode(t,e){return Object.prototype.hasOwnProperty.call(this._nodes,t)?(arguments.length>1&&(this._nodes[t]=e),this):(this._nodes[t]=arguments.length>1?e:this._defaultNodeLabelFn(t),this._isCompound&&(this._parent[t]=v,this._children[t]={},this._children[v][t]=!0),this._in[t]={},this._preds[t]={},this._out[t]={},this._sucs[t]={},++this._nodeCount,this)}node(t){return this._nodes[t]}hasNode(t){return Object.prototype.hasOwnProperty.call(this._nodes,t)}removeNode(t){if(Object.prototype.hasOwnProperty.call(this._nodes,t)){var e=t=>this.removeEdge(this._edgeObjs[t]);delete this._nodes[t],this._isCompound&&(this._removeFromParentsChildList(t),delete this._parent[t],l.Z(this.children(t),(t=>{this.setParent(t)})),delete this._children[t]),l.Z(a.Z(this._in[t]),e),delete this._in[t],delete this._preds[t],l.Z(a.Z(this._out[t]),e),delete this._out[t],delete this._sucs[t],--this._nodeCount}return this}setParent(t,e){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(c.Z(e))e=v;else{for(var n=e+="";!c.Z(n);n=this.parent(n))if(n===t)throw new Error("Setting "+e+" as parent of "+t+" would create a cycle");this.setNode(e)}return this.setNode(t),this._removeFromParentsChildList(t),this._parent[t]=e,this._children[e][t]=!0,this}_removeFromParentsChildList(t){delete this._children[this._parent[t]][t]}parent(t){if(this._isCompound){var e=this._parent[t];if(e!==v)return e}}children(t){if(c.Z(t)&&(t=v),this._isCompound){var e=this._children[t];if(e)return a.Z(e)}else{if(t===v)return this.nodes();if(this.hasNode(t))return[]}}predecessors(t){var e=this._preds[t];if(e)return a.Z(e)}successors(t){var e=this._sucs[t];if(e)return a.Z(e)}neighbors(t){var e=this.predecessors(t);if(e)return g(e,this.successors(t))}isLeaf(t){return 0===(this.isDirected()?this.successors(t):this.neighbors(t)).length}filterNodes(t){var e=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});e.setGraph(this.graph());var n=this;l.Z(this._nodes,(function(n,r){t(r)&&e.setNode(r,n)})),l.Z(this._edgeObjs,(function(t){e.hasNode(t.v)&&e.hasNode(t.w)&&e.setEdge(t,n.edge(t))}));var r={};function i(t){var a=n.parent(t);return void 0===a||e.hasNode(a)?(r[t]=a,a):a in r?r[a]:i(a)}return this._isCompound&&l.Z(e.nodes(),(function(t){e.setParent(t,i(t))})),e}setDefaultEdgeLabel(t){return i.Z(t)||(t=r.Z(t)),this._defaultEdgeLabelFn=t,this}edgeCount(){return this._edgeCount}edges(){return f.Z(this._edgeObjs)}setPath(t,e){var n=this,r=arguments;return m.Z(t,(function(t,i){return r.length>1?n.setEdge(t,i,e):n.setEdge(t,i),i})),this}setEdge(){var t,e,n,r,i=!1,a=arguments[0];"object"==typeof a&&null!==a&&"v"in a?(t=a.v,e=a.w,n=a.name,2===arguments.length&&(r=arguments[1],i=!0)):(t=a,e=arguments[1],n=arguments[3],arguments.length>2&&(r=arguments[2],i=!0)),t=""+t,e=""+e,c.Z(n)||(n=""+n);var s=T(this._isDirected,t,e,n);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,s))return i&&(this._edgeLabels[s]=r),this;if(!c.Z(n)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(t),this.setNode(e),this._edgeLabels[s]=i?r:this._defaultEdgeLabelFn(t,e,n);var o=function(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var s=i;i=a,a=s}var o={v:i,w:a};return r&&(o.name=r),o}(this._isDirected,t,e,n);return t=o.v,e=o.w,Object.freeze(o),this._edgeObjs[s]=o,w(this._preds[e],t),w(this._sucs[t],e),this._in[e][s]=o,this._out[t][s]=o,this._edgeCount++,this}edge(t,e,n){var r=1===arguments.length?_(this._isDirected,arguments[0]):T(this._isDirected,t,e,n);return this._edgeLabels[r]}hasEdge(t,e,n){var r=1===arguments.length?_(this._isDirected,arguments[0]):T(this._isDirected,t,e,n);return Object.prototype.hasOwnProperty.call(this._edgeLabels,r)}removeEdge(t,e,n){var r=1===arguments.length?_(this._isDirected,arguments[0]):T(this._isDirected,t,e,n),i=this._edgeObjs[r];return i&&(t=i.v,e=i.w,delete this._edgeLabels[r],delete this._edgeObjs[r],k(this._preds[e],t),k(this._sucs[t],e),delete this._in[e][r],delete this._out[t][r],this._edgeCount--),this}inEdges(t,e){var n=this._in[t];if(n){var r=f.Z(n);return e?s.Z(r,(function(t){return t.v===e})):r}}outEdges(t,e){var n=this._out[t];if(n){var r=f.Z(n);return e?s.Z(r,(function(t){return t.w===e})):r}}nodeEdges(t,e){var n=this.inEdges(t,e);if(n)return n.concat(this.outEdges(t,e))}}function w(t,e){t[e]?t[e]++:t[e]=1}function k(t,e){--t[e]||delete t[e]}function T(t,e,n,r){var i=""+e,a=""+n;if(!t&&i>a){var s=i;i=a,a=s}return i+x+a+x+(c.Z(r)?y:r)}function _(t,e){return T(t,e.v,e.w,e.name)}b.prototype._nodeCount=0,b.prototype._edgeCount=0},5625:(t,e,n)=>{"use strict";n.d(e,{k:()=>r.k});var r=n(7556)},2424:(t,e,n)=>{"use strict";n.d(e,{Z:()=>nt});const{entries:r,setPrototypeOf:i,isFrozen:a,getPrototypeOf:s,getOwnPropertyDescriptor:o}=Object;let{freeze:l,seal:c,create:h}=Object,{apply:u,construct:d}="undefined"!=typeof Reflect&&Reflect;l||(l=function(t){return t}),c||(c=function(t){return t}),u||(u=function(t,e,n){return t.apply(e,n)}),d||(d=function(t,e){return new t(...e)});const p=A(Array.prototype.forEach),g=A(Array.prototype.lastIndexOf),f=A(Array.prototype.pop),m=A(Array.prototype.push),y=A(Array.prototype.splice),v=A(String.prototype.toLowerCase),x=A(String.prototype.toString),b=A(String.prototype.match),w=A(String.prototype.replace),k=A(String.prototype.indexOf),T=A(String.prototype.trim),_=A(Object.prototype.hasOwnProperty),E=A(RegExp.prototype.test),S=(C=TypeError,function(){for(var t=arguments.length,e=new Array(t),n=0;n1?n-1:0),i=1;i2&&void 0!==arguments[2]?arguments[2]:v;i&&i(t,null);let r=e.length;for(;r--;){let i=e[r];if("string"==typeof i){const t=n(i);t!==i&&(a(e)||(e[r]=t),i=t)}t[i]=!0}return t}function M(t){for(let e=0;e/gm),V=c(/\$\{[\w\W]*/gm),q=c(/^data-[\-\w.\u00B7-\uFFFF]+$/),j=c(/^aria-[\-\w]+$/),H=c(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),X=c(/^(?:\w+script|data):/i),K=c(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Q=c(/^html$/i),J=c(/^[a-z][.\w]*(-[.\w]+)+$/i);var tt=Object.freeze({__proto__:null,ARIA_ATTR:j,ATTR_WHITESPACE:K,CUSTOM_ELEMENT:J,DATA_ATTR:q,DOCTYPE_NAME:Q,ERB_EXPR:G,IS_ALLOWED_URI:H,IS_SCRIPT_OR_DATA:X,MUSTACHE_EXPR:U,TMPLIT_EXPR:V});const et=function(){return"undefined"==typeof window?null:window};var nt=function t(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:et();const n=e=>t(e);if(n.version="3.2.5",n.removed=[],!e||!e.document||9!==e.document.nodeType||!e.Element)return n.isSupported=!1,n;let{document:i}=e;const a=i,s=a.currentScript,{DocumentFragment:o,HTMLTemplateElement:c,Node:u,Element:d,NodeFilter:C,NamedNodeMap:A=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:M,DOMParser:U,trustedTypes:G}=e,V=d.prototype,q=I(V,"cloneNode"),j=I(V,"remove"),X=I(V,"nextSibling"),K=I(V,"childNodes"),J=I(V,"parentNode");if("function"==typeof c){const t=i.createElement("template");t.content&&t.content.ownerDocument&&(i=t.content.ownerDocument)}let nt,rt="";const{implementation:it,createNodeIterator:at,createDocumentFragment:st,getElementsByTagName:ot}=i,{importNode:lt}=a;let ct={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]};n.isSupported="function"==typeof r&&"function"==typeof J&&it&&void 0!==it.createHTMLDocument;const{MUSTACHE_EXPR:ht,ERB_EXPR:ut,TMPLIT_EXPR:dt,DATA_ATTR:pt,ARIA_ATTR:gt,IS_SCRIPT_OR_DATA:ft,ATTR_WHITESPACE:mt,CUSTOM_ELEMENT:yt}=tt;let{IS_ALLOWED_URI:vt}=tt,xt=null;const bt=L({},[...R,...D,...O,...$,...F]);let wt=null;const kt=L({},[...W,...z,...Z,...Y]);let Tt=Object.seal(h(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),_t=null,Et=null,St=!0,Ct=!0,At=!1,Lt=!0,Mt=!1,Nt=!0,It=!1,Rt=!1,Dt=!1,Ot=!1,Pt=!1,$t=!1,Bt=!0,Ft=!1,Wt=!0,zt=!1,Zt={},Yt=null;const Ut=L({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let Gt=null;const Vt=L({},["audio","video","img","source","image","track"]);let qt=null;const jt=L({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Ht="http://www.w3.org/1998/Math/MathML",Xt="http://www.w3.org/2000/svg",Kt="http://www.w3.org/1999/xhtml";let Qt=Kt,Jt=!1,te=null;const ee=L({},[Ht,Xt,Kt],x);let ne=L({},["mi","mo","mn","ms","mtext"]),re=L({},["annotation-xml"]);const ie=L({},["title","style","font","a","script"]);let ae=null;const se=["application/xhtml+xml","text/html"];let oe=null,le=null;const ce=i.createElement("form"),he=function(t){return t instanceof RegExp||t instanceof Function},ue=function(){let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(!le||le!==t){if(t&&"object"==typeof t||(t={}),t=N(t),ae=-1===se.indexOf(t.PARSER_MEDIA_TYPE)?"text/html":t.PARSER_MEDIA_TYPE,oe="application/xhtml+xml"===ae?x:v,xt=_(t,"ALLOWED_TAGS")?L({},t.ALLOWED_TAGS,oe):bt,wt=_(t,"ALLOWED_ATTR")?L({},t.ALLOWED_ATTR,oe):kt,te=_(t,"ALLOWED_NAMESPACES")?L({},t.ALLOWED_NAMESPACES,x):ee,qt=_(t,"ADD_URI_SAFE_ATTR")?L(N(jt),t.ADD_URI_SAFE_ATTR,oe):jt,Gt=_(t,"ADD_DATA_URI_TAGS")?L(N(Vt),t.ADD_DATA_URI_TAGS,oe):Vt,Yt=_(t,"FORBID_CONTENTS")?L({},t.FORBID_CONTENTS,oe):Ut,_t=_(t,"FORBID_TAGS")?L({},t.FORBID_TAGS,oe):{},Et=_(t,"FORBID_ATTR")?L({},t.FORBID_ATTR,oe):{},Zt=!!_(t,"USE_PROFILES")&&t.USE_PROFILES,St=!1!==t.ALLOW_ARIA_ATTR,Ct=!1!==t.ALLOW_DATA_ATTR,At=t.ALLOW_UNKNOWN_PROTOCOLS||!1,Lt=!1!==t.ALLOW_SELF_CLOSE_IN_ATTR,Mt=t.SAFE_FOR_TEMPLATES||!1,Nt=!1!==t.SAFE_FOR_XML,It=t.WHOLE_DOCUMENT||!1,Ot=t.RETURN_DOM||!1,Pt=t.RETURN_DOM_FRAGMENT||!1,$t=t.RETURN_TRUSTED_TYPE||!1,Dt=t.FORCE_BODY||!1,Bt=!1!==t.SANITIZE_DOM,Ft=t.SANITIZE_NAMED_PROPS||!1,Wt=!1!==t.KEEP_CONTENT,zt=t.IN_PLACE||!1,vt=t.ALLOWED_URI_REGEXP||H,Qt=t.NAMESPACE||Kt,ne=t.MATHML_TEXT_INTEGRATION_POINTS||ne,re=t.HTML_INTEGRATION_POINTS||re,Tt=t.CUSTOM_ELEMENT_HANDLING||{},t.CUSTOM_ELEMENT_HANDLING&&he(t.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Tt.tagNameCheck=t.CUSTOM_ELEMENT_HANDLING.tagNameCheck),t.CUSTOM_ELEMENT_HANDLING&&he(t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Tt.attributeNameCheck=t.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),t.CUSTOM_ELEMENT_HANDLING&&"boolean"==typeof t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements&&(Tt.allowCustomizedBuiltInElements=t.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Mt&&(Ct=!1),Pt&&(Ot=!0),Zt&&(xt=L({},F),wt=[],!0===Zt.html&&(L(xt,R),L(wt,W)),!0===Zt.svg&&(L(xt,D),L(wt,z),L(wt,Y)),!0===Zt.svgFilters&&(L(xt,O),L(wt,z),L(wt,Y)),!0===Zt.mathMl&&(L(xt,$),L(wt,Z),L(wt,Y))),t.ADD_TAGS&&(xt===bt&&(xt=N(xt)),L(xt,t.ADD_TAGS,oe)),t.ADD_ATTR&&(wt===kt&&(wt=N(wt)),L(wt,t.ADD_ATTR,oe)),t.ADD_URI_SAFE_ATTR&&L(qt,t.ADD_URI_SAFE_ATTR,oe),t.FORBID_CONTENTS&&(Yt===Ut&&(Yt=N(Yt)),L(Yt,t.FORBID_CONTENTS,oe)),Wt&&(xt["#text"]=!0),It&&L(xt,["html","head","body"]),xt.table&&(L(xt,["tbody"]),delete _t.tbody),t.TRUSTED_TYPES_POLICY){if("function"!=typeof t.TRUSTED_TYPES_POLICY.createHTML)throw S('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if("function"!=typeof t.TRUSTED_TYPES_POLICY.createScriptURL)throw S('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');nt=t.TRUSTED_TYPES_POLICY,rt=nt.createHTML("")}else void 0===nt&&(nt=function(t,e){if("object"!=typeof t||"function"!=typeof t.createPolicy)return null;let n=null;const r="data-tt-policy-suffix";e&&e.hasAttribute(r)&&(n=e.getAttribute(r));const i="dompurify"+(n?"#"+n:"");try{return t.createPolicy(i,{createHTML:t=>t,createScriptURL:t=>t})}catch(t){return console.warn("TrustedTypes policy "+i+" could not be created."),null}}(G,s)),null!==nt&&"string"==typeof rt&&(rt=nt.createHTML(""));l&&l(t),le=t}},de=L({},[...D,...O,...P]),pe=L({},[...$,...B]),ge=function(t){m(n.removed,{element:t});try{J(t).removeChild(t)}catch(e){j(t)}},fe=function(t,e){try{m(n.removed,{attribute:e.getAttributeNode(t),from:e})}catch(t){m(n.removed,{attribute:null,from:e})}if(e.removeAttribute(t),"is"===t)if(Ot||Pt)try{ge(e)}catch(t){}else try{e.setAttribute(t,"")}catch(t){}},me=function(t){let e=null,n=null;if(Dt)t=""+t;else{const e=b(t,/^[\r\n\t ]+/);n=e&&e[0]}"application/xhtml+xml"===ae&&Qt===Kt&&(t=''+t+"");const r=nt?nt.createHTML(t):t;if(Qt===Kt)try{e=(new U).parseFromString(r,ae)}catch(t){}if(!e||!e.documentElement){e=it.createDocument(Qt,"template",null);try{e.documentElement.innerHTML=Jt?rt:r}catch(t){}}const a=e.body||e.documentElement;return t&&n&&a.insertBefore(i.createTextNode(n),a.childNodes[0]||null),Qt===Kt?ot.call(e,It?"html":"body")[0]:It?e.documentElement:a},ye=function(t){return at.call(t.ownerDocument||t,t,C.SHOW_ELEMENT|C.SHOW_COMMENT|C.SHOW_TEXT|C.SHOW_PROCESSING_INSTRUCTION|C.SHOW_CDATA_SECTION,null)},ve=function(t){return t instanceof M&&("string"!=typeof t.nodeName||"string"!=typeof t.textContent||"function"!=typeof t.removeChild||!(t.attributes instanceof A)||"function"!=typeof t.removeAttribute||"function"!=typeof t.setAttribute||"string"!=typeof t.namespaceURI||"function"!=typeof t.insertBefore||"function"!=typeof t.hasChildNodes)},xe=function(t){return"function"==typeof u&&t instanceof u};function be(t,e,r){p(t,(t=>{t.call(n,e,r,le)}))}const we=function(t){let e=null;if(be(ct.beforeSanitizeElements,t,null),ve(t))return ge(t),!0;const r=oe(t.nodeName);if(be(ct.uponSanitizeElement,t,{tagName:r,allowedTags:xt}),t.hasChildNodes()&&!xe(t.firstElementChild)&&E(/<[/\w!]/g,t.innerHTML)&&E(/<[/\w!]/g,t.textContent))return ge(t),!0;if(7===t.nodeType)return ge(t),!0;if(Nt&&8===t.nodeType&&E(/<[/\w]/g,t.data))return ge(t),!0;if(!xt[r]||_t[r]){if(!_t[r]&&Te(r)){if(Tt.tagNameCheck instanceof RegExp&&E(Tt.tagNameCheck,r))return!1;if(Tt.tagNameCheck instanceof Function&&Tt.tagNameCheck(r))return!1}if(Wt&&!Yt[r]){const e=J(t)||t.parentNode,n=K(t)||t.childNodes;if(n&&e)for(let r=n.length-1;r>=0;--r){const i=q(n[r],!0);i.__removalCount=(t.__removalCount||0)+1,e.insertBefore(i,X(t))}}return ge(t),!0}return t instanceof d&&!function(t){let e=J(t);e&&e.tagName||(e={namespaceURI:Qt,tagName:"template"});const n=v(t.tagName),r=v(e.tagName);return!!te[t.namespaceURI]&&(t.namespaceURI===Xt?e.namespaceURI===Kt?"svg"===n:e.namespaceURI===Ht?"svg"===n&&("annotation-xml"===r||ne[r]):Boolean(de[n]):t.namespaceURI===Ht?e.namespaceURI===Kt?"math"===n:e.namespaceURI===Xt?"math"===n&&re[r]:Boolean(pe[n]):t.namespaceURI===Kt?!(e.namespaceURI===Xt&&!re[r])&&!(e.namespaceURI===Ht&&!ne[r])&&!pe[n]&&(ie[n]||!de[n]):!("application/xhtml+xml"!==ae||!te[t.namespaceURI]))}(t)?(ge(t),!0):"noscript"!==r&&"noembed"!==r&&"noframes"!==r||!E(/<\/no(script|embed|frames)/i,t.innerHTML)?(Mt&&3===t.nodeType&&(e=t.textContent,p([ht,ut,dt],(t=>{e=w(e,t," ")})),t.textContent!==e&&(m(n.removed,{element:t.cloneNode()}),t.textContent=e)),be(ct.afterSanitizeElements,t,null),!1):(ge(t),!0)},ke=function(t,e,n){if(Bt&&("id"===e||"name"===e)&&(n in i||n in ce))return!1;if(Ct&&!Et[e]&&E(pt,e));else if(St&&E(gt,e));else if(!wt[e]||Et[e]){if(!(Te(t)&&(Tt.tagNameCheck instanceof RegExp&&E(Tt.tagNameCheck,t)||Tt.tagNameCheck instanceof Function&&Tt.tagNameCheck(t))&&(Tt.attributeNameCheck instanceof RegExp&&E(Tt.attributeNameCheck,e)||Tt.attributeNameCheck instanceof Function&&Tt.attributeNameCheck(e))||"is"===e&&Tt.allowCustomizedBuiltInElements&&(Tt.tagNameCheck instanceof RegExp&&E(Tt.tagNameCheck,n)||Tt.tagNameCheck instanceof Function&&Tt.tagNameCheck(n))))return!1}else if(qt[e]);else if(E(vt,w(n,mt,"")));else if("src"!==e&&"xlink:href"!==e&&"href"!==e||"script"===t||0!==k(n,"data:")||!Gt[t])if(At&&!E(ft,w(n,mt,"")));else if(n)return!1;return!0},Te=function(t){return"annotation-xml"!==t&&b(t,yt)},_e=function(t){be(ct.beforeSanitizeAttributes,t,null);const{attributes:e}=t;if(!e||ve(t))return;const r={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:wt,forceKeepAttr:void 0};let i=e.length;for(;i--;){const a=e[i],{name:s,namespaceURI:o,value:l}=a,c=oe(s);let h="value"===s?l:T(l);if(r.attrName=c,r.attrValue=h,r.keepAttr=!0,r.forceKeepAttr=void 0,be(ct.uponSanitizeAttribute,t,r),h=r.attrValue,!Ft||"id"!==c&&"name"!==c||(fe(s,t),h="user-content-"+h),Nt&&E(/((--!?|])>)|<\/(style|title)/i,h)){fe(s,t);continue}if(r.forceKeepAttr)continue;if(fe(s,t),!r.keepAttr)continue;if(!Lt&&E(/\/>/i,h)){fe(s,t);continue}Mt&&p([ht,ut,dt],(t=>{h=w(h,t," ")}));const u=oe(t.nodeName);if(ke(u,c,h)){if(nt&&"object"==typeof G&&"function"==typeof G.getAttributeType)if(o);else switch(G.getAttributeType(u,c)){case"TrustedHTML":h=nt.createHTML(h);break;case"TrustedScriptURL":h=nt.createScriptURL(h)}try{o?t.setAttributeNS(o,s,h):t.setAttribute(s,h),ve(t)?ge(t):f(n.removed)}catch(t){}}}be(ct.afterSanitizeAttributes,t,null)},Ee=function t(e){let n=null;const r=ye(e);for(be(ct.beforeSanitizeShadowDOM,e,null);n=r.nextNode();)be(ct.uponSanitizeShadowNode,n,null),we(n),_e(n),n.content instanceof o&&t(n.content);be(ct.afterSanitizeShadowDOM,e,null)};return n.sanitize=function(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=null,i=null,s=null,l=null;if(Jt=!t,Jt&&(t="\x3c!--\x3e"),"string"!=typeof t&&!xe(t)){if("function"!=typeof t.toString)throw S("toString is not a function");if("string"!=typeof(t=t.toString()))throw S("dirty is not a string, aborting")}if(!n.isSupported)return t;if(Rt||ue(e),n.removed=[],"string"==typeof t&&(zt=!1),zt){if(t.nodeName){const e=oe(t.nodeName);if(!xt[e]||_t[e])throw S("root node is forbidden and cannot be sanitized in-place")}}else if(t instanceof u)r=me("\x3c!----\x3e"),i=r.ownerDocument.importNode(t,!0),1===i.nodeType&&"BODY"===i.nodeName||"HTML"===i.nodeName?r=i:r.appendChild(i);else{if(!Ot&&!Mt&&!It&&-1===t.indexOf("<"))return nt&&$t?nt.createHTML(t):t;if(r=me(t),!r)return Ot?null:$t?rt:""}r&&Dt&&ge(r.firstChild);const c=ye(zt?t:r);for(;s=c.nextNode();)we(s),_e(s),s.content instanceof o&&Ee(s.content);if(zt)return t;if(Ot){if(Pt)for(l=st.call(r.ownerDocument);r.firstChild;)l.appendChild(r.firstChild);else l=r;return(wt.shadowroot||wt.shadowrootmode)&&(l=lt.call(a,l,!0)),l}let h=It?r.outerHTML:r.innerHTML;return It&&xt["!doctype"]&&r.ownerDocument&&r.ownerDocument.doctype&&r.ownerDocument.doctype.name&&E(Q,r.ownerDocument.doctype.name)&&(h="\n"+h),Mt&&p([ht,ut,dt],(t=>{h=w(h,t," ")})),nt&&$t?nt.createHTML(h):h},n.setConfig=function(){ue(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}),Rt=!0},n.clearConfig=function(){le=null,Rt=!1},n.isValidAttribute=function(t,e,n){le||ue({});const r=oe(t),i=oe(e);return ke(r,i,n)},n.addHook=function(t,e){"function"==typeof e&&m(ct[t],e)},n.removeHook=function(t,e){if(void 0!==e){const n=g(ct[t],e);return-1===n?void 0:y(ct[t],n,1)[0]}return f(ct[t])},n.removeHooks=function(t){ct[t]=[]},n.removeAllHooks=function(){ct={afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}},n}()},4549:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(5971),i=n(2142);const a=new class{constructor(t,e){this.color=e,this.changed=!1,this.data=t,this.type=new class{constructor(){this.type=i.w.ALL}get(){return this.type}set(t){if(this.type&&this.type!==t)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=t}reset(){this.type=i.w.ALL}is(t){return this.type===t}}}set(t,e){return this.color=e,this.changed=!1,this.data=t,this.type.type=i.w.ALL,this}_ensureHSL(){const t=this.data,{h:e,s:n,l:i}=t;void 0===e&&(t.h=r.Z.channel.rgb2hsl(t,"h")),void 0===n&&(t.s=r.Z.channel.rgb2hsl(t,"s")),void 0===i&&(t.l=r.Z.channel.rgb2hsl(t,"l"))}_ensureRGB(){const t=this.data,{r:e,g:n,b:i}=t;void 0===e&&(t.r=r.Z.channel.hsl2rgb(t,"r")),void 0===n&&(t.g=r.Z.channel.hsl2rgb(t,"g")),void 0===i&&(t.b=r.Z.channel.hsl2rgb(t,"b"))}get r(){const t=this.data,e=t.r;return this.type.is(i.w.HSL)||void 0===e?(this._ensureHSL(),r.Z.channel.hsl2rgb(t,"r")):e}get g(){const t=this.data,e=t.g;return this.type.is(i.w.HSL)||void 0===e?(this._ensureHSL(),r.Z.channel.hsl2rgb(t,"g")):e}get b(){const t=this.data,e=t.b;return this.type.is(i.w.HSL)||void 0===e?(this._ensureHSL(),r.Z.channel.hsl2rgb(t,"b")):e}get h(){const t=this.data,e=t.h;return this.type.is(i.w.RGB)||void 0===e?(this._ensureRGB(),r.Z.channel.rgb2hsl(t,"h")):e}get s(){const t=this.data,e=t.s;return this.type.is(i.w.RGB)||void 0===e?(this._ensureRGB(),r.Z.channel.rgb2hsl(t,"s")):e}get l(){const t=this.data,e=t.l;return this.type.is(i.w.RGB)||void 0===e?(this._ensureRGB(),r.Z.channel.rgb2hsl(t,"l")):e}get a(){return this.data.a}set r(t){this.type.set(i.w.RGB),this.changed=!0,this.data.r=t}set g(t){this.type.set(i.w.RGB),this.changed=!0,this.data.g=t}set b(t){this.type.set(i.w.RGB),this.changed=!0,this.data.b=t}set h(t){this.type.set(i.w.HSL),this.changed=!0,this.data.h=t}set s(t){this.type.set(i.w.HSL),this.changed=!0,this.data.s=t}set l(t){this.type.set(i.w.HSL),this.changed=!0,this.data.l=t}set a(t){this.changed=!0,this.data.a=t}}({r:0,g:0,b:0,a:0},"transparent")},1767:(t,e,n)=>{"use strict";n.d(e,{Z:()=>f});var r=n(4549),i=n(2142);const a={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:t=>{if(35!==t.charCodeAt(0))return;const e=t.match(a.re);if(!e)return;const n=e[1],i=parseInt(n,16),s=n.length,o=s%4==0,l=s>4,c=l?1:17,h=l?8:4,u=o?0:-1,d=l?255:15;return r.Z.set({r:(i>>h*(u+3)&d)*c,g:(i>>h*(u+2)&d)*c,b:(i>>h*(u+1)&d)*c,a:o?(i&d)*c/255:1},t)},stringify:t=>{const{r:e,g:n,b:r,a}=t;return a<1?`#${i.Q[Math.round(e)]}${i.Q[Math.round(n)]}${i.Q[Math.round(r)]}${i.Q[Math.round(255*a)]}`:`#${i.Q[Math.round(e)]}${i.Q[Math.round(n)]}${i.Q[Math.round(r)]}`}},s=a;var o=n(5971);const l={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:t=>{const e=t.match(l.hueRe);if(e){const[,t,n]=e;switch(n){case"grad":return o.Z.channel.clamp.h(.9*parseFloat(t));case"rad":return o.Z.channel.clamp.h(180*parseFloat(t)/Math.PI);case"turn":return o.Z.channel.clamp.h(360*parseFloat(t))}}return o.Z.channel.clamp.h(parseFloat(t))},parse:t=>{const e=t.charCodeAt(0);if(104!==e&&72!==e)return;const n=t.match(l.re);if(!n)return;const[,i,a,s,c,h]=n;return r.Z.set({h:l._hue2deg(i),s:o.Z.channel.clamp.s(parseFloat(a)),l:o.Z.channel.clamp.l(parseFloat(s)),a:c?o.Z.channel.clamp.a(h?parseFloat(c)/100:parseFloat(c)):1},t)},stringify:t=>{const{h:e,s:n,l:r,a:i}=t;return i<1?`hsla(${o.Z.lang.round(e)}, ${o.Z.lang.round(n)}%, ${o.Z.lang.round(r)}%, ${i})`:`hsl(${o.Z.lang.round(e)}, ${o.Z.lang.round(n)}%, ${o.Z.lang.round(r)}%)`}},c=l,h={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:t=>{t=t.toLowerCase();const e=h.colors[t];if(e)return s.parse(e)},stringify:t=>{const e=s.stringify(t);for(const t in h.colors)if(h.colors[t]===e)return t}},u=h,d={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:t=>{const e=t.charCodeAt(0);if(114!==e&&82!==e)return;const n=t.match(d.re);if(!n)return;const[,i,a,s,l,c,h,u,p]=n;return r.Z.set({r:o.Z.channel.clamp.r(a?2.55*parseFloat(i):parseFloat(i)),g:o.Z.channel.clamp.g(l?2.55*parseFloat(s):parseFloat(s)),b:o.Z.channel.clamp.b(h?2.55*parseFloat(c):parseFloat(c)),a:u?o.Z.channel.clamp.a(p?parseFloat(u)/100:parseFloat(u)):1},t)},stringify:t=>{const{r:e,g:n,b:r,a:i}=t;return i<1?`rgba(${o.Z.lang.round(e)}, ${o.Z.lang.round(n)}, ${o.Z.lang.round(r)}, ${o.Z.lang.round(i)})`:`rgb(${o.Z.lang.round(e)}, ${o.Z.lang.round(n)}, ${o.Z.lang.round(r)})`}},p=d,g={format:{keyword:h,hex:s,rgb:d,rgba:d,hsl:l,hsla:l},parse:t=>{if("string"!=typeof t)return t;const e=s.parse(t)||p.parse(t)||c.parse(t)||u.parse(t);if(e)return e;throw new Error(`Unsupported color format: "${t}"`)},stringify:t=>!t.changed&&t.color?t.color:t.type.is(i.w.HSL)||void 0===t.data.r?c.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?p.stringify(t):s.stringify(t)},f=g},2142:(t,e,n)=>{"use strict";n.d(e,{Q:()=>i,w:()=>a});var r=n(5971);const i={};for(let t=0;t<=255;t++)i[t]=r.Z.unit.dec2hex(t);const a={ALL:0,RGB:1,HSL:2}},6174:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(5971),i=n(1767);const a=(t,e,n)=>{const a=i.Z.parse(t),s=a[e],o=r.Z.channel.clamp[e](s+n);return s!==o&&(a[e]=o),i.Z.stringify(a)}},3438:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(5971),i=n(1767);const a=(t,e)=>{const n=i.Z.parse(t);for(const t in e)n[t]=r.Z.channel.clamp[t](e[t]);return i.Z.stringify(n)}},9792:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(5971),i=n(1767);const a=(t,e)=>r.Z.lang.round(i.Z.parse(t)[e])},7201:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(6174);const i=(t,e)=>(0,r.Z)(t,"l",-e)},6500:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=n(5971),i=n(1767);const a=t=>(t=>{const{r:e,g:n,b:a}=i.Z.parse(t),s=.2126*r.Z.channel.toLinear(e)+.7152*r.Z.channel.toLinear(n)+.0722*r.Z.channel.toLinear(a);return r.Z.lang.round(s)})(t)>=.5,s=t=>!a(t)},2281:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(6174);const i=(t,e)=>(0,r.Z)(t,"l",e)},1117:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(5971),i=n(4549),a=n(1767),s=n(3438);const o=(t,e,n=0,o=1)=>{if("number"!=typeof t)return(0,s.Z)(t,{a:e});const l=i.Z.set({r:r.Z.channel.clamp.r(t),g:r.Z.channel.clamp.g(e),b:r.Z.channel.clamp.b(n),a:r.Z.channel.clamp.a(o)});return a.Z.stringify(l)}},5971:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});const r={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:t=>t>=255?255:t<0?0:t,g:t=>t>=255?255:t<0?0:t,b:t=>t>=255?255:t<0?0:t,h:t=>t%360,s:t=>t>=100?100:t<0?0:t,l:t=>t>=100?100:t<0?0:t,a:t=>t>=1?1:t<0?0:t},toLinear:t=>{const e=t/255;return t>.03928?Math.pow((e+.055)/1.055,2.4):e/12.92},hue2rgb:(t,e,n)=>(n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t),hsl2rgb:({h:t,s:e,l:n},i)=>{if(!e)return 2.55*n;t/=360,e/=100;const a=(n/=100)<.5?n*(1+e):n+e-n*e,s=2*n-a;switch(i){case"r":return 255*r.hue2rgb(s,a,t+1/3);case"g":return 255*r.hue2rgb(s,a,t);case"b":return 255*r.hue2rgb(s,a,t-1/3)}},rgb2hsl:({r:t,g:e,b:n},r)=>{t/=255,e/=255,n/=255;const i=Math.max(t,e,n),a=Math.min(t,e,n),s=(i+a)/2;if("l"===r)return 100*s;if(i===a)return 0;const o=i-a;if("s"===r)return 100*(s>.5?o/(2-i-a):o/(i+a));switch(i){case t:return 60*((e-n)/o+(ee>n?Math.min(e,Math.max(n,t)):Math.min(n,Math.max(e,t)),round:t=>Math.round(1e10*t)/1e10},unit:{dec2hex:t=>{const e=Math.round(t).toString(16);return e.length>1?e:`0${e}`}}}},3548:(t,e,n)=>{"use strict";n.d(e,{Q:()=>Zr,T:()=>Yr});var r=n(2855),i=n(6097),a=n(2925),s=n(3437),o=n(6435),l=n(3836),c=n(9601);function h(t,e,n){return`${t.name}_${e}_${n}`}const u=1,d=4,p=5,g=7,f=8,m=9,y=10,v=11,x=12;class b{constructor(t){this.target=t}isEpsilon(){return!1}}class w extends b{constructor(t,e){super(t),this.tokenType=e}}class k extends b{constructor(t){super(t)}isEpsilon(){return!0}}class T extends b{constructor(t,e,n){super(t),this.rule=e,this.followState=n}isEpsilon(){return!0}}function _(t,e,n){return n instanceof o.oI?M(t,e,n.terminalType,n):n instanceof o.Sj?function(t,e,n){const r=n.referencedRule,i=t.ruleToStartState.get(r),a=R(t,e,n,{type:u}),s=R(t,e,n,{type:u});return D(a,new T(i,r,s)),{left:a,right:s}}(t,e,n):n instanceof o.ue?function(t,e,n){const r=R(t,e,n,{type:u});A(t,r);const i=(0,l.Z)(n.definition,(n=>_(t,e,n)));return L(t,e,r,n,...i)}(t,e,n):n instanceof o.Wx?function(t,e,n){const r=R(t,e,n,{type:u});A(t,r);return function(t,e,n,r){const i=r.left;return I(i,r.right),t.decisionMap[h(e,"Option",n.idx)]=i,r}(t,e,n,L(t,e,r,n,E(t,e,n)))}(t,e,n):n instanceof o.hI?function(t,e,n){const r=R(t,e,n,{type:p});A(t,r);return C(t,e,n,L(t,e,r,n,E(t,e,n)))}(t,e,n):n instanceof o.pT?function(t,e,n){const r=R(t,e,n,{type:p});A(t,r);return C(t,e,n,L(t,e,r,n,E(t,e,n)),M(t,e,n.separator,n))}(t,e,n):n instanceof o.ej?function(t,e,n){const r=R(t,e,n,{type:d});A(t,r);return S(t,e,n,L(t,e,r,n,E(t,e,n)))}(t,e,n):n instanceof o.fK?function(t,e,n){const r=R(t,e,n,{type:d});A(t,r);return S(t,e,n,L(t,e,r,n,E(t,e,n)),M(t,e,n.separator,n))}(t,e,n):E(t,e,n)}function E(t,e,n){const r=(0,c.Z)((0,l.Z)(n.definition,(n=>_(t,e,n))),(t=>void 0!==t));return 1===r.length?r[0]:0===r.length?void 0:function(t,e){const n=e.length;for(let r=0;rt.alt))}get key(){let t="";for(const e in this.map)t+=e+":";return t}}function B(t,e=!0){return`${e?`a${t.alt}`:""}s${t.state.stateNumber}:${t.stack.map((t=>t.stateNumber.toString())).join("_")}`}var F=n(3729),W=n(6805),z=n(506),Z=n(184);const Y=function(t,e){return t&&t.length?(0,Z.Z)(t,(0,z.Z)(e,2)):[]};var U=n(7961),G=n(870),V=n(9697),q=n(4283);function j(t,e){const n={};return r=>{const i=r.toString();let a=n[i];return void 0!==a||(a={atnStartState:t,decision:e,states:{}},n[i]=a),a}}class H{constructor(){this.predicates=[]}is(t){return t>=this.predicates.length||this.predicates[t]}set(t,e){this.predicates[t]=e}toString(){let t="";const e=this.predicates.length;for(let n=0;nconsole.log(t)}initialize(t){this.atn=function(t){const e={decisionMap:{},decisionStates:[],ruleToStartState:new Map,ruleToStopState:new Map,states:[]};!function(t,e){const n=e.length;for(let r=0;r(0,l.Z)(t,(t=>t[0]))));if(Q(d,!1)&&!i){const t=(0,q.Z)(d,((t,e,n)=>((0,G.Z)(e,(e=>{e&&(t[e.tokenTypeIdx]=n,(0,G.Z)(e.categoryMatches,(e=>{t[e]=n})))})),t)),{});return r?function(e){var n;const r=this.LA(1),i=t[r.tokenTypeIdx];if(void 0!==e&&void 0!==i){const t=null===(n=e[i])||void 0===n?void 0:n.GATE;if(void 0!==t&&!1===t.call(this))return}return i}:function(){const e=this.LA(1);return t[e.tokenTypeIdx]}}return r?function(t){const e=new H,n=void 0===t?0:t.length;for(let r=0;r(0,l.Z)(t,(t=>t[0]))));if(Q(d)&&d[0][0]&&!i){const t=d[0],e=(0,U.Z)(t);if(1===e.length&&(0,V.Z)(e[0].categoryMatches)){const t=e[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===t}}{const t=(0,q.Z)(e,((t,e)=>(void 0!==e&&(t[e.tokenTypeIdx]=!0,(0,G.Z)(e.categoryMatches,(e=>{t[e]=!0}))),t)),{});return function(){const e=this.LA(1);return!0===t[e.tokenTypeIdx]}}}return function(){const t=J.call(this,a,u,X,s);return"object"!=typeof t&&0===t}}}function Q(t,e=!0){const n=new Set;for(const r of t){const t=new Set;for(const i of r){if(void 0===i){if(e)break;return!1}const r=[i.tokenTypeIdx].concat(i.categoryMatches);for(const e of r)if(n.has(e)){if(!t.has(e))return!1}else n.add(e),t.add(e)}}return!0}function J(t,e,n,r){const i=t[e](n);let a=i.start;return void 0===a&&(a=ot(i,at(function(t){const e=new $,n=t.transitions.length;for(let r=0;r0&&!function(t){for(const e of t.elements)if(e.state.type===g)return!0;return!1}(a))for(const t of i)a.add(t);return a}(e.configs,n,i);if(0===s.size)return st(t,e,n,P),P;let o=at(s);const l=function(t,e){let n;for(const r of t.elements)if(!0===e.is(r.alt))if(void 0===n)n=r.alt;else if(n!==r.alt)return;return n}(s,i);if(void 0!==l)o.isAcceptState=!0,o.prediction=l,o.configs.uniqueAlt=l;else if(function(t){if(function(t){for(const e of t.elements)if(e.state.type!==g)return!1;return!0}(t))return!0;const e=function(t){const e=new Map;for(const n of t){const t=B(n,!1);let r=e.get(t);void 0===r&&(r={},e.set(t,r)),r[n.alt]=!0}return e}(t.elements);return function(t){for(const e of Array.from(t.values()))if(Object.keys(e).length>1)return!0;return!1}(e)&&!function(t){for(const e of Array.from(t.values()))if(1===Object.keys(e).length)return!0;return!1}(e)}(s)){const e=(0,F.Z)(s.alts);o.isAcceptState=!0,o.prediction=e,o.configs.uniqueAlt=e,nt.apply(this,[t,r,s.alts,a])}return o=st(t,e,n,o),o}function nt(t,e,n,r){const i=[];for(let t=1;t<=e;t++)i.push(this.LA(t).tokenType);const a=t.atnStartState;r(function(t){const e=(0,l.Z)(t.prefixPath,(t=>(0,o.l$)(t))).join(", "),n=0===t.production.idx?"":t.production.idx;let r=`Ambiguous Alternatives Detected: <${t.ambiguityIndices.join(", ")}> in <${function(t){if(t instanceof o.Sj)return"SUBRULE";if(t instanceof o.Wx)return"OPTION";if(t instanceof o.ue)return"OR";if(t instanceof o.ej)return"AT_LEAST_ONE";if(t instanceof o.fK)return"AT_LEAST_ONE_SEP";if(t instanceof o.pT)return"MANY_SEP";if(t instanceof o.hI)return"MANY";if(t instanceof o.oI)return"CONSUME";throw Error("non exhaustive match")}(t.production)}${n}> inside <${t.topLevelRule.name}> Rule,\n<${e}> may appears as a prefix path in all these alternatives.\n`;return r+="See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES\nFor Further details.",r}({topLevelRule:a.rule,ambiguityIndices:n,production:a.production,prefixPath:i}))}function rt(t,e,n){const r=(0,W.Z)(e.configs.elements,(t=>t.state.transitions));return{actualToken:n,possibleTokenTypes:Y(r.filter((t=>t instanceof w)).map((t=>t.tokenType)),(t=>t.tokenTypeIdx)),tokenPath:t}}function it(t,e){if(t instanceof w&&(0,o.ol)(e,t.tokenType))return t.target}function at(t){return{configs:t,edges:{},isAcceptState:!1,prediction:-1}}function st(t,e,n,r){return r=ot(t,r),e.edges[n.tokenTypeIdx]=r,r}function ot(t,e){if(e===P)return e;const n=e.configs.key,r=t.states[n];return void 0!==r?r:(e.configs.finalize(),t.states[n]=e,e)}function lt(t,e){const n=t.state;if(n.type===g){if(t.stack.length>0){const n=[...t.stack];lt({state:n.pop(),alt:t.alt,stack:n},e)}else e.add(t);return}n.epsilonOnlyTransitions||e.add(t);const r=n.transitions.length;for(let i=0;i0&&(r.arguments=n),r},t.is=function(t){let e=t;return Oe.defined(e)&&Oe.string(e.title)&&Oe.string(e.command)}}(At||(At={})),function(t){t.replace=function(t,e){return{range:t,newText:e}},t.insert=function(t,e){return{range:{start:t,end:t},newText:e}},t.del=function(t){return{range:t,newText:""}},t.is=function(t){const e=t;return Oe.objectLiteral(e)&&Oe.string(e.newText)&&ft.is(e.range)}}(Lt||(Lt={})),function(t){t.create=function(t,e,n){const r={label:t};return void 0!==e&&(r.needsConfirmation=e),void 0!==n&&(r.description=n),r},t.is=function(t){const e=t;return Oe.objectLiteral(e)&&Oe.string(e.label)&&(Oe.boolean(e.needsConfirmation)||void 0===e.needsConfirmation)&&(Oe.string(e.description)||void 0===e.description)}}(Mt||(Mt={})),function(t){t.is=function(t){const e=t;return Oe.string(e)}}(Nt||(Nt={})),function(t){t.replace=function(t,e,n){return{range:t,newText:e,annotationId:n}},t.insert=function(t,e,n){return{range:{start:t,end:t},newText:e,annotationId:n}},t.del=function(t,e){return{range:t,newText:"",annotationId:e}},t.is=function(t){const e=t;return Lt.is(e)&&(Mt.is(e.annotationId)||Nt.is(e.annotationId))}}(It||(It={})),function(t){t.create=function(t,e){return{textDocument:t,edits:e}},t.is=function(t){let e=t;return Oe.defined(e)&&Wt.is(e.textDocument)&&Array.isArray(e.edits)}}(Rt||(Rt={})),function(t){t.create=function(t,e,n){let r={kind:"create",uri:t};return void 0===e||void 0===e.overwrite&&void 0===e.ignoreIfExists||(r.options=e),void 0!==n&&(r.annotationId=n),r},t.is=function(t){let e=t;return e&&"create"===e.kind&&Oe.string(e.uri)&&(void 0===e.options||(void 0===e.options.overwrite||Oe.boolean(e.options.overwrite))&&(void 0===e.options.ignoreIfExists||Oe.boolean(e.options.ignoreIfExists)))&&(void 0===e.annotationId||Nt.is(e.annotationId))}}(Dt||(Dt={})),function(t){t.create=function(t,e,n,r){let i={kind:"rename",oldUri:t,newUri:e};return void 0===n||void 0===n.overwrite&&void 0===n.ignoreIfExists||(i.options=n),void 0!==r&&(i.annotationId=r),i},t.is=function(t){let e=t;return e&&"rename"===e.kind&&Oe.string(e.oldUri)&&Oe.string(e.newUri)&&(void 0===e.options||(void 0===e.options.overwrite||Oe.boolean(e.options.overwrite))&&(void 0===e.options.ignoreIfExists||Oe.boolean(e.options.ignoreIfExists)))&&(void 0===e.annotationId||Nt.is(e.annotationId))}}(Ot||(Ot={})),function(t){t.create=function(t,e,n){let r={kind:"delete",uri:t};return void 0===e||void 0===e.recursive&&void 0===e.ignoreIfNotExists||(r.options=e),void 0!==n&&(r.annotationId=n),r},t.is=function(t){let e=t;return e&&"delete"===e.kind&&Oe.string(e.uri)&&(void 0===e.options||(void 0===e.options.recursive||Oe.boolean(e.options.recursive))&&(void 0===e.options.ignoreIfNotExists||Oe.boolean(e.options.ignoreIfNotExists)))&&(void 0===e.annotationId||Nt.is(e.annotationId))}}(Pt||(Pt={})),function(t){t.is=function(t){let e=t;return e&&(void 0!==e.changes||void 0!==e.documentChanges)&&(void 0===e.documentChanges||e.documentChanges.every((t=>Oe.string(t.kind)?Dt.is(t)||Ot.is(t)||Pt.is(t):Rt.is(t))))}}($t||($t={})),function(t){t.create=function(t){return{uri:t}},t.is=function(t){let e=t;return Oe.defined(e)&&Oe.string(e.uri)}}(Bt||(Bt={})),function(t){t.create=function(t,e){return{uri:t,version:e}},t.is=function(t){let e=t;return Oe.defined(e)&&Oe.string(e.uri)&&Oe.integer(e.version)}}(Ft||(Ft={})),function(t){t.create=function(t,e){return{uri:t,version:e}},t.is=function(t){let e=t;return Oe.defined(e)&&Oe.string(e.uri)&&(null===e.version||Oe.integer(e.version))}}(Wt||(Wt={})),function(t){t.create=function(t,e,n,r){return{uri:t,languageId:e,version:n,text:r}},t.is=function(t){let e=t;return Oe.defined(e)&&Oe.string(e.uri)&&Oe.string(e.languageId)&&Oe.integer(e.version)&&Oe.string(e.text)}}(zt||(zt={})),function(t){t.PlainText="plaintext",t.Markdown="markdown",t.is=function(e){const n=e;return n===t.PlainText||n===t.Markdown}}(Zt||(Zt={})),function(t){t.is=function(t){const e=t;return Oe.objectLiteral(t)&&Zt.is(e.kind)&&Oe.string(e.value)}}(Yt||(Yt={})),function(t){t.Text=1,t.Method=2,t.Function=3,t.Constructor=4,t.Field=5,t.Variable=6,t.Class=7,t.Interface=8,t.Module=9,t.Property=10,t.Unit=11,t.Value=12,t.Enum=13,t.Keyword=14,t.Snippet=15,t.Color=16,t.File=17,t.Reference=18,t.Folder=19,t.EnumMember=20,t.Constant=21,t.Struct=22,t.Event=23,t.Operator=24,t.TypeParameter=25}(Ut||(Ut={})),function(t){t.PlainText=1,t.Snippet=2}(Gt||(Gt={})),function(t){t.Deprecated=1}(Vt||(Vt={})),function(t){t.create=function(t,e,n){return{newText:t,insert:e,replace:n}},t.is=function(t){const e=t;return e&&Oe.string(e.newText)&&ft.is(e.insert)&&ft.is(e.replace)}}(qt||(qt={})),function(t){t.asIs=1,t.adjustIndentation=2}(jt||(jt={})),function(t){t.is=function(t){const e=t;return e&&(Oe.string(e.detail)||void 0===e.detail)&&(Oe.string(e.description)||void 0===e.description)}}(Ht||(Ht={})),function(t){t.create=function(t){return{label:t}}}(Xt||(Xt={})),function(t){t.create=function(t,e){return{items:t||[],isIncomplete:!!e}}}(Kt||(Kt={})),function(t){t.fromPlainText=function(t){return t.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")},t.is=function(t){const e=t;return Oe.string(e)||Oe.objectLiteral(e)&&Oe.string(e.language)&&Oe.string(e.value)}}(Qt||(Qt={})),function(t){t.is=function(t){let e=t;return!!e&&Oe.objectLiteral(e)&&(Yt.is(e.contents)||Qt.is(e.contents)||Oe.typedArray(e.contents,Qt.is))&&(void 0===t.range||ft.is(t.range))}}(Jt||(Jt={})),function(t){t.create=function(t,e){return e?{label:t,documentation:e}:{label:t}}}(te||(te={})),function(t){t.create=function(t,e,...n){let r={label:t};return Oe.defined(e)&&(r.documentation=e),Oe.defined(n)?r.parameters=n:r.parameters=[],r}}(ee||(ee={})),function(t){t.Text=1,t.Read=2,t.Write=3}(ne||(ne={})),function(t){t.create=function(t,e){let n={range:t};return Oe.number(e)&&(n.kind=e),n}}(re||(re={})),function(t){t.File=1,t.Module=2,t.Namespace=3,t.Package=4,t.Class=5,t.Method=6,t.Property=7,t.Field=8,t.Constructor=9,t.Enum=10,t.Interface=11,t.Function=12,t.Variable=13,t.Constant=14,t.String=15,t.Number=16,t.Boolean=17,t.Array=18,t.Object=19,t.Key=20,t.Null=21,t.EnumMember=22,t.Struct=23,t.Event=24,t.Operator=25,t.TypeParameter=26}(ie||(ie={})),function(t){t.Deprecated=1}(ae||(ae={})),function(t){t.create=function(t,e,n,r,i){let a={name:t,kind:e,location:{uri:r,range:n}};return i&&(a.containerName=i),a}}(se||(se={})),function(t){t.create=function(t,e,n,r){return void 0!==r?{name:t,kind:e,location:{uri:n,range:r}}:{name:t,kind:e,location:{uri:n}}}}(oe||(oe={})),function(t){t.create=function(t,e,n,r,i,a){let s={name:t,detail:e,kind:n,range:r,selectionRange:i};return void 0!==a&&(s.children=a),s},t.is=function(t){let e=t;return e&&Oe.string(e.name)&&Oe.number(e.kind)&&ft.is(e.range)&&ft.is(e.selectionRange)&&(void 0===e.detail||Oe.string(e.detail))&&(void 0===e.deprecated||Oe.boolean(e.deprecated))&&(void 0===e.children||Array.isArray(e.children))&&(void 0===e.tags||Array.isArray(e.tags))}}(le||(le={})),function(t){t.Empty="",t.QuickFix="quickfix",t.Refactor="refactor",t.RefactorExtract="refactor.extract",t.RefactorInline="refactor.inline",t.RefactorRewrite="refactor.rewrite",t.Source="source",t.SourceOrganizeImports="source.organizeImports",t.SourceFixAll="source.fixAll"}(ce||(ce={})),function(t){t.Invoked=1,t.Automatic=2}(he||(he={})),function(t){t.create=function(t,e,n){let r={diagnostics:t};return null!=e&&(r.only=e),null!=n&&(r.triggerKind=n),r},t.is=function(t){let e=t;return Oe.defined(e)&&Oe.typedArray(e.diagnostics,Ct.is)&&(void 0===e.only||Oe.typedArray(e.only,Oe.string))&&(void 0===e.triggerKind||e.triggerKind===he.Invoked||e.triggerKind===he.Automatic)}}(ue||(ue={})),function(t){t.create=function(t,e,n){let r={title:t},i=!0;return"string"==typeof e?(i=!1,r.kind=e):At.is(e)?r.command=e:r.edit=e,i&&void 0!==n&&(r.kind=n),r},t.is=function(t){let e=t;return e&&Oe.string(e.title)&&(void 0===e.diagnostics||Oe.typedArray(e.diagnostics,Ct.is))&&(void 0===e.kind||Oe.string(e.kind))&&(void 0!==e.edit||void 0!==e.command)&&(void 0===e.command||At.is(e.command))&&(void 0===e.isPreferred||Oe.boolean(e.isPreferred))&&(void 0===e.edit||$t.is(e.edit))}}(de||(de={})),function(t){t.create=function(t,e){let n={range:t};return Oe.defined(e)&&(n.data=e),n},t.is=function(t){let e=t;return Oe.defined(e)&&ft.is(e.range)&&(Oe.undefined(e.command)||At.is(e.command))}}(pe||(pe={})),function(t){t.create=function(t,e){return{tabSize:t,insertSpaces:e}},t.is=function(t){let e=t;return Oe.defined(e)&&Oe.uinteger(e.tabSize)&&Oe.boolean(e.insertSpaces)}}(ge||(ge={})),function(t){t.create=function(t,e,n){return{range:t,target:e,data:n}},t.is=function(t){let e=t;return Oe.defined(e)&&ft.is(e.range)&&(Oe.undefined(e.target)||Oe.string(e.target))}}(fe||(fe={})),function(t){t.create=function(t,e){return{range:t,parent:e}},t.is=function(e){let n=e;return Oe.objectLiteral(n)&&ft.is(n.range)&&(void 0===n.parent||t.is(n.parent))}}(me||(me={})),function(t){t.namespace="namespace",t.type="type",t.class="class",t.enum="enum",t.interface="interface",t.struct="struct",t.typeParameter="typeParameter",t.parameter="parameter",t.variable="variable",t.property="property",t.enumMember="enumMember",t.event="event",t.function="function",t.method="method",t.macro="macro",t.keyword="keyword",t.modifier="modifier",t.comment="comment",t.string="string",t.number="number",t.regexp="regexp",t.operator="operator",t.decorator="decorator"}(ye||(ye={})),function(t){t.declaration="declaration",t.definition="definition",t.readonly="readonly",t.static="static",t.deprecated="deprecated",t.abstract="abstract",t.async="async",t.modification="modification",t.documentation="documentation",t.defaultLibrary="defaultLibrary"}(ve||(ve={})),function(t){t.is=function(t){const e=t;return Oe.objectLiteral(e)&&(void 0===e.resultId||"string"==typeof e.resultId)&&Array.isArray(e.data)&&(0===e.data.length||"number"==typeof e.data[0])}}(xe||(xe={})),function(t){t.create=function(t,e){return{range:t,text:e}},t.is=function(t){const e=t;return null!=e&&ft.is(e.range)&&Oe.string(e.text)}}(be||(be={})),function(t){t.create=function(t,e,n){return{range:t,variableName:e,caseSensitiveLookup:n}},t.is=function(t){const e=t;return null!=e&&ft.is(e.range)&&Oe.boolean(e.caseSensitiveLookup)&&(Oe.string(e.variableName)||void 0===e.variableName)}}(we||(we={})),function(t){t.create=function(t,e){return{range:t,expression:e}},t.is=function(t){const e=t;return null!=e&&ft.is(e.range)&&(Oe.string(e.expression)||void 0===e.expression)}}(ke||(ke={})),function(t){t.create=function(t,e){return{frameId:t,stoppedLocation:e}},t.is=function(t){const e=t;return Oe.defined(e)&&ft.is(t.stoppedLocation)}}(Te||(Te={})),function(t){t.Type=1,t.Parameter=2,t.is=function(t){return 1===t||2===t}}(_e||(_e={})),function(t){t.create=function(t){return{value:t}},t.is=function(t){const e=t;return Oe.objectLiteral(e)&&(void 0===e.tooltip||Oe.string(e.tooltip)||Yt.is(e.tooltip))&&(void 0===e.location||mt.is(e.location))&&(void 0===e.command||At.is(e.command))}}(Ee||(Ee={})),function(t){t.create=function(t,e,n){const r={position:t,label:e};return void 0!==n&&(r.kind=n),r},t.is=function(t){const e=t;return Oe.objectLiteral(e)&>.is(e.position)&&(Oe.string(e.label)||Oe.typedArray(e.label,Ee.is))&&(void 0===e.kind||_e.is(e.kind))&&void 0===e.textEdits||Oe.typedArray(e.textEdits,Lt.is)&&(void 0===e.tooltip||Oe.string(e.tooltip)||Yt.is(e.tooltip))&&(void 0===e.paddingLeft||Oe.boolean(e.paddingLeft))&&(void 0===e.paddingRight||Oe.boolean(e.paddingRight))}}(Se||(Se={})),function(t){t.createSnippet=function(t){return{kind:"snippet",value:t}}}(Ce||(Ce={})),function(t){t.create=function(t,e,n,r){return{insertText:t,filterText:e,range:n,command:r}}}(Ae||(Ae={})),function(t){t.create=function(t){return{items:t}}}(Le||(Le={})),function(t){t.Invoked=0,t.Automatic=1}(Me||(Me={})),function(t){t.create=function(t,e){return{range:t,text:e}}}(Ne||(Ne={})),function(t){t.create=function(t,e){return{triggerKind:t,selectedCompletionInfo:e}}}(Ie||(Ie={})),function(t){t.is=function(t){const e=t;return Oe.objectLiteral(e)&&ut.is(e.uri)&&Oe.string(e.name)}}(Re||(Re={})),function(t){function e(t,n){if(t.length<=1)return t;const r=t.length/2|0,i=t.slice(0,r),a=t.slice(r);e(i,n),e(a,n);let s=0,o=0,l=0;for(;s{let n=t.range.start.line-e.range.start.line;return 0===n?t.range.start.character-e.range.start.character:n})),a=r.length;for(let e=i.length-1;e>=0;e--){let n=i[e],s=t.offsetAt(n.range.start),o=t.offsetAt(n.range.end);if(!(o<=a))throw new Error("Overlapping edit");r=r.substring(0,s)+n.newText+r.substring(o,r.length),a=s}return r}}(De||(De={}));class $e{constructor(t,e,n,r){this._uri=t,this._languageId=e,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(t){if(t){let e=this.offsetAt(t.start),n=this.offsetAt(t.end);return this._content.substring(e,n)}return this._content}update(t,e){this._content=t.text,this._version=e,this._lineOffsets=void 0}getLineOffsets(){if(void 0===this._lineOffsets){let t=[],e=this._content,n=!0;for(let r=0;r0&&t.push(e.length),this._lineOffsets=t}return this._lineOffsets}positionAt(t){t=Math.max(Math.min(t,this._content.length),0);let e=this.getLineOffsets(),n=0,r=e.length;if(0===r)return gt.create(0,t);for(;nt?r=i:n=i+1}let i=n-1;return gt.create(i,t-e[i])}offsetAt(t){let e=this.getLineOffsets();if(t.line>=e.length)return this._content.length;if(t.line<0)return 0;let n=e[t.line],r=t.line+1=0&&e.content.splice(n,1)}}addHiddenNodes(t){const e=[];for(const n of t){const t=new We(n.startOffset,n.image.length,(0,r.sp)(n),n.tokenType,!0);t.root=this.rootNode,e.push(t)}let n=this.current,i=!1;if(n.content.length>0)n.content.push(...e);else{for(;n.container;){const t=n.container.content.indexOf(n);if(t>0){n.container.content.splice(t,0,...e),i=!0;break}n=n.container}i||this.rootNode.content.unshift(...e)}}construct(t){const e=this.current;"string"==typeof t.$type&&(this.current.astNode=t),t.$cstNode=e;const n=this.nodeStack.pop();0===(null==n?void 0:n.content.length)&&this.removeNode(n)}}class Fe{get parent(){return this.container}get feature(){return this.grammarSource}get hidden(){return!1}get astNode(){var t,e;const n="string"==typeof(null===(t=this._astNode)||void 0===t?void 0:t.$type)?this._astNode:null===(e=this.container)||void 0===e?void 0:e.astNode;if(!n)throw new Error("This node has no associated AST element");return n}set astNode(t){this._astNode=t}get element(){return this.astNode}get text(){return this.root.fullText.substring(this.offset,this.end)}}class We extends Fe{get offset(){return this._offset}get length(){return this._length}get end(){return this._offset+this._length}get hidden(){return this._hidden}get tokenType(){return this._tokenType}get range(){return this._range}constructor(t,e,n,r,i=!1){super(),this._hidden=i,this._offset=t,this._tokenType=r,this._length=e,this._range=n}}class ze extends Fe{constructor(){super(...arguments),this.content=new Ze(this)}get children(){return this.content}get offset(){var t,e;return null!==(e=null===(t=this.firstNonHiddenNode)||void 0===t?void 0:t.offset)&&void 0!==e?e:0}get length(){return this.end-this.offset}get end(){var t,e;return null!==(e=null===(t=this.lastNonHiddenNode)||void 0===t?void 0:t.end)&&void 0!==e?e:0}get range(){const t=this.firstNonHiddenNode,e=this.lastNonHiddenNode;if(t&&e){if(void 0===this._rangeCache){const{range:n}=t,{range:r}=e;this._rangeCache={start:n.start,end:r.end.line=0;t--){const e=this.content[t];if(!e.hidden)return e}return this.content[this.content.length-1]}}class Ze extends Array{constructor(t){super(),this.parent=t,Object.setPrototypeOf(this,Ze.prototype)}push(...t){return this.addParents(t),super.push(...t)}unshift(...t){return this.addParents(t),super.unshift(...t)}splice(t,e,...n){return this.addParents(n),super.splice(t,e,...n)}addParents(t){for(const e of t)e.container=this.parent}}class Ye extends ze{get text(){return this._text.substring(this.offset,this.end)}get fullText(){return this._text}constructor(t){super(),this._text="",this._text=null!=t?t:""}}const Ue=Symbol("Datatype");function Ge(t){return t.$type===Ue}const Ve=t=>t.endsWith("​")?t:t+"​";class qe{constructor(t){this._unorderedGroups=new Map,this.allRules=new Map,this.lexer=t.parser.Lexer;const e=this.lexer.definition,n="production"===t.LanguageMetaData.mode;this.wrapper=new Je(e,Object.assign(Object.assign({},t.parser.ParserConfig),{skipValidations:n,errorMessageProvider:t.parser.ParserErrorMessageProvider}))}alternatives(t,e){this.wrapper.wrapOr(t,e)}optional(t,e){this.wrapper.wrapOption(t,e)}many(t,e){this.wrapper.wrapMany(t,e)}atLeastOne(t,e){this.wrapper.wrapAtLeastOne(t,e)}getRule(t){return this.allRules.get(t)}isRecording(){return this.wrapper.IS_RECORDING}get unorderedGroups(){return this._unorderedGroups}getRuleStack(){return this.wrapper.RULE_STACK}finalize(){this.wrapper.wrapSelfAnalysis()}}class je extends qe{get current(){return this.stack[this.stack.length-1]}constructor(t){super(t),this.nodeBuilder=new Be,this.stack=[],this.assignmentMap=new Map,this.linker=t.references.Linker,this.converter=t.parser.ValueConverter,this.astReflection=t.shared.AstReflection}rule(t,e){const n=this.computeRuleType(t),r=this.wrapper.DEFINE_RULE(Ve(t.name),this.startImplementation(n,e).bind(this));return this.allRules.set(t.name,r),t.entry&&(this.mainRule=r),r}computeRuleType(t){if(!t.fragment){if((0,i.UP)(t))return Ue;{const e=(0,i.$G)(t);return null!=e?e:t.name}}}parse(t,e={}){this.nodeBuilder.buildRootNode(t);const n=this.lexerResult=this.lexer.tokenize(t);this.wrapper.input=n.tokens;const r=e.rule?this.allRules.get(e.rule):this.mainRule;if(!r)throw new Error(e.rule?`No rule found with name '${e.rule}'`:"No main rule available.");const i=r.call(this.wrapper,{});return this.nodeBuilder.addHiddenNodes(n.hidden),this.unorderedGroups.clear(),this.lexerResult=void 0,{value:i,lexerErrors:n.errors,lexerReport:n.report,parserErrors:this.wrapper.errors}}startImplementation(t,e){return n=>{const r=!this.isRecording()&&void 0!==t;if(r){const e={$type:t};this.stack.push(e),t===Ue&&(e.value="")}let i;try{i=e(n)}catch(t){i=void 0}return void 0===i&&r&&(i=this.construct()),i}}extractHiddenTokens(t){const e=this.lexerResult.hidden;if(!e.length)return[];const n=t.startOffset;for(let t=0;tn)return e.splice(0,t);return e.splice(0,e.length)}consume(t,e,n){const r=this.wrapper.wrapConsume(t,e);if(!this.isRecording()&&this.isValidToken(r)){const t=this.extractHiddenTokens(r);this.nodeBuilder.addHiddenNodes(t);const e=this.nodeBuilder.buildLeafNode(r,n),{assignment:i,isCrossRef:a}=this.getAssignment(n),o=this.current;if(i){const t=(0,s.p1)(n)?r.image:this.converter.convert(r.image,e);this.assign(i.operator,i.feature,t,e,a)}else if(Ge(o)){let t=r.image;(0,s.p1)(n)||(t=this.converter.convert(t,e).toString()),o.value+=t}}}isValidToken(t){return!t.isInsertedInRecovery&&!isNaN(t.startOffset)&&"number"==typeof t.endOffset&&!isNaN(t.endOffset)}subrule(t,e,n,r,i){let a;this.isRecording()||n||(a=this.nodeBuilder.buildCompositeNode(r));const s=this.wrapper.wrapSubrule(t,e,i);!this.isRecording()&&a&&a.length>0&&this.performSubruleAssignment(s,r,a)}performSubruleAssignment(t,e,n){const{assignment:r,isCrossRef:i}=this.getAssignment(e);if(r)this.assign(r.operator,r.feature,t,n,i);else if(!r){const e=this.current;if(Ge(e))e.value+=t.toString();else if("object"==typeof t&&t){const n=this.assignWithoutOverride(t,e);this.stack.pop(),this.stack.push(n)}}}action(t,e){if(!this.isRecording()){let n=this.current;if(e.feature&&e.operator){n=this.construct(),this.nodeBuilder.removeNode(n.$cstNode),this.nodeBuilder.buildCompositeNode(e).content.push(n.$cstNode);const r={$type:t};this.stack.push(r),this.assign(e.operator,e.feature,n,n.$cstNode,!1)}else n.$type=t}}construct(){if(this.isRecording())return;const t=this.current;return(0,Pe.b2)(t),this.nodeBuilder.construct(t),this.stack.pop(),Ge(t)?this.converter.convert(t.value,t.$cstNode):((0,Pe.a1)(this.astReflection,t),t)}getAssignment(t){if(!this.assignmentMap.has(t)){const e=(0,Pe.V_)(t,s.B7);this.assignmentMap.set(t,{assignment:e,isCrossRef:!!e&&(0,s.Ki)(e.terminal)})}return this.assignmentMap.get(t)}assign(t,e,n,r,i){const a=this.current;let s;switch(s=i&&"string"==typeof n?this.linker.buildReference(a,e,r,n):n,t){case"=":a[e]=s;break;case"?=":a[e]=!0;break;case"+=":Array.isArray(a[e])||(a[e]=[]),a[e].push(s)}}assignWithoutOverride(t,e){for(const[n,r]of Object.entries(e)){const e=t[n];void 0===e?t[n]=r:Array.isArray(e)&&Array.isArray(r)&&(r.push(...e),t[n]=r)}const n=t.$cstNode;return n&&(n.astNode=void 0,t.$cstNode=void 0),t}get definitionErrors(){return this.wrapper.definitionErrors}}class He{buildMismatchTokenMessage(t){return o.Hs.buildMismatchTokenMessage(t)}buildNotAllInputParsedMessage(t){return o.Hs.buildNotAllInputParsedMessage(t)}buildNoViableAltMessage(t){return o.Hs.buildNoViableAltMessage(t)}buildEarlyExitMessage(t){return o.Hs.buildEarlyExitMessage(t)}}class Xe extends He{buildMismatchTokenMessage({expected:t,actual:e}){return`Expecting ${t.LABEL?"`"+t.LABEL+"`":t.name.endsWith(":KW")?`keyword '${t.name.substring(0,t.name.length-3)}'`:`token of type '${t.name}'`} but found \`${e.image}\`.`}buildNotAllInputParsedMessage({firstRedundant:t}){return`Expecting end of file but found \`${t.image}\`.`}}class Ke extends qe{constructor(){super(...arguments),this.tokens=[],this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}action(){}construct(){}parse(t){this.resetState();const e=this.lexer.tokenize(t,{mode:"partial"});return this.tokens=e.tokens,this.wrapper.input=[...this.tokens],this.mainRule.call(this.wrapper,{}),this.unorderedGroups.clear(),{tokens:this.tokens,elementStack:[...this.lastElementStack],tokenIndex:this.nextTokenIndex}}rule(t,e){const n=this.wrapper.DEFINE_RULE(Ve(t.name),this.startImplementation(e).bind(this));return this.allRules.set(t.name,n),t.entry&&(this.mainRule=n),n}resetState(){this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}startImplementation(t){return e=>{const n=this.keepStackSize();try{t(e)}finally{this.resetStackSize(n)}}}removeUnexpectedElements(){this.elementStack.splice(this.stackSize)}keepStackSize(){const t=this.elementStack.length;return this.stackSize=t,t}resetStackSize(t){this.removeUnexpectedElements(),this.stackSize=t}consume(t,e,n){this.wrapper.wrapConsume(t,e),this.isRecording()||(this.lastElementStack=[...this.elementStack,n],this.nextTokenIndex=this.currIdx+1)}subrule(t,e,n,r,i){this.before(r),this.wrapper.wrapSubrule(t,e,i),this.after(r)}before(t){this.isRecording()||this.elementStack.push(t)}after(t){if(!this.isRecording()){const e=this.elementStack.lastIndexOf(t);e>=0&&this.elementStack.splice(e)}}get currIdx(){return this.wrapper.currIdx}}const Qe={recoveryEnabled:!0,nodeLocationTracking:"full",skipValidations:!0,errorMessageProvider:new Xe};class Je extends o.nu{constructor(t,e){const n=e&&"maxLookahead"in e;super(t,Object.assign(Object.assign(Object.assign({},Qe),{lookaheadStrategy:n?new o.dV({maxLookahead:e.maxLookahead}):new K({logging:e.skipValidations?()=>{}:void 0})}),e))}get IS_RECORDING(){return this.RECORDING_PHASE}DEFINE_RULE(t,e){return this.RULE(t,e)}wrapSelfAnalysis(){this.performSelfAnalysis()}wrapConsume(t,e){return this.consume(t,e)}wrapSubrule(t,e,n){return this.subrule(t,e,{ARGS:[n]})}wrapOr(t,e){this.or(t,e)}wrapOption(t,e){this.option(t,e)}wrapMany(t,e){this.many(t,e)}wrapAtLeastOne(t,e){this.atLeastOne(t,e)}}var tn=n(9267),en=n(1412);function nn(t,e,n){return function(t,e){const n=(0,i.VD)(e,!1),r=(0,en.Vw)(e.rules).filter(s.F9).filter((t=>n.has(t)));for(const e of r){const n=Object.assign(Object.assign({},t),{consume:1,optional:1,subrule:1,many:1,or:1});t.parser.rule(e,rn(n,e.definition))}}({parser:e,tokens:n,ruleNames:new Map},t),e}function rn(t,e,n=!1){let r;if((0,s.p1)(e))r=function(t,e){const n=t.consume++,r=t.tokens[e.value];if(!r)throw new Error("Could not find token for keyword: "+e.value);return()=>t.parser.consume(n,r,e)}(t,e);else if((0,s.LG)(e))r=function(t,e){const n=(0,i.z$)(e);return()=>t.parser.action(n,e)}(t,e);else if((0,s.B7)(e))r=rn(t,e.terminal);else if((0,s.Ki)(e))r=on(t,e);else if((0,s.t3)(e))r=function(t,e){const n=e.rule.ref;if((0,s.F9)(n)){const r=t.subrule++,i=n.fragment,a=e.arguments.length>0?function(t,e){const n=e.map((t=>an(t.value)));return e=>{const r={};for(let i=0;i({});return s=>t.parser.subrule(r,cn(t,n),i,e,a(s))}if((0,s.MS)(n)){const r=t.consume++,i=hn(t,n.name);return()=>t.parser.consume(r,i,e)}if(!n)throw new tn.h(e.$cstNode,`Undefined rule: ${e.rule.$refText}`);(0,tn.U)(n)}(t,e);else if((0,s.MZ)(e))r=function(t,e){if(1===e.elements.length)return rn(t,e.elements[0]);{const n=[];for(const r of e.elements){const e={ALT:rn(t,r,!0)},i=sn(r);i&&(e.GATE=an(i)),n.push(e)}const r=t.or++;return e=>t.parser.alternatives(r,n.map((t=>{const n={ALT:()=>t.ALT(e)},r=t.GATE;return r&&(n.GATE=()=>r(e)),n})))}}(t,e);else if((0,s.W1)(e))r=function(t,e){if(1===e.elements.length)return rn(t,e.elements[0]);const n=[];for(const r of e.elements){const e={ALT:rn(t,r,!0)},i=sn(r);i&&(e.GATE=an(i)),n.push(e)}const r=t.or++,i=(t,e)=>`uGroup_${t}_${e.getRuleStack().join("-")}`,a=ln(t,sn(e),(e=>t.parser.alternatives(r,n.map(((n,a)=>{const s={ALT:()=>!0},o=t.parser;s.ALT=()=>{if(n.ALT(e),!o.isRecording()){const t=i(r,o);o.unorderedGroups.get(t)||o.unorderedGroups.set(t,[]);const e=o.unorderedGroups.get(t);void 0===(null==e?void 0:e[a])&&(e[a]=!0)}};const l=n.GATE;return s.GATE=l?()=>l(e):()=>{const t=o.unorderedGroups.get(i(r,o));return!(null==t?void 0:t[a])},s})))),"*");return e=>{a(e),t.parser.isRecording()||t.parser.unorderedGroups.delete(i(r,t.parser))}}(t,e);else if((0,s.ty)(e))r=function(t,e){const n=e.elements.map((e=>rn(t,e)));return t=>n.forEach((e=>e(t)))}(t,e);else{if(!(0,s.rT)(e))throw new tn.h(e.$cstNode,`Unexpected element type: ${e.$type}`);{const n=t.consume++;r=()=>t.parser.consume(n,o.sd,e)}}return ln(t,n?void 0:sn(e),r,e.cardinality)}function an(t){if((0,s.F8)(t)){const e=an(t.left),n=an(t.right);return t=>e(t)||n(t)}if((0,s.TB)(t)){const e=an(t.left),n=an(t.right);return t=>e(t)&&n(t)}if((0,s.Ii)(t)){const e=an(t.value);return t=>!e(t)}if((0,s.yW)(t)){const e=t.parameter.ref.name;return t=>void 0!==t&&!0===t[e]}if((0,s.L)(t)){const e=Boolean(t.true);return()=>e}(0,tn.U)(t)}function sn(t){if((0,s.ty)(t))return t.guardCondition}function on(t,e,n=e.terminal){if(n){if((0,s.t3)(n)&&(0,s.F9)(n.rule.ref)){const r=n.rule.ref,i=t.subrule++;return n=>t.parser.subrule(i,cn(t,r),!1,e,n)}if((0,s.t3)(n)&&(0,s.MS)(n.rule.ref)){const r=t.consume++,i=hn(t,n.rule.ref.name);return()=>t.parser.consume(r,i,e)}if((0,s.p1)(n)){const r=t.consume++,i=hn(t,n.value);return()=>t.parser.consume(r,i,e)}throw new Error("Could not build cross reference parser")}{if(!e.type.ref)throw new Error("Could not resolve reference to type: "+e.type.$refText);const n=(0,i.ib)(e.type.ref),r=null==n?void 0:n.terminal;if(!r)throw new Error("Could not find name assignment for type: "+(0,i.z$)(e.type.ref));return on(t,e,r)}}function ln(t,e,n,r){const i=e&&an(e);if(!r){if(i){const e=t.or++;return r=>t.parser.alternatives(e,[{ALT:()=>n(r),GATE:()=>i(r)},{ALT:(0,o._o)(),GATE:()=>!i(r)}])}return n}if("*"===r){const e=t.many++;return r=>t.parser.many(e,{DEF:()=>n(r),GATE:i?()=>i(r):void 0})}if("+"===r){const e=t.many++;if(i){const r=t.or++;return a=>t.parser.alternatives(r,[{ALT:()=>t.parser.atLeastOne(e,{DEF:()=>n(a)}),GATE:()=>i(a)},{ALT:(0,o._o)(),GATE:()=>!i(a)}])}return r=>t.parser.atLeastOne(e,{DEF:()=>n(r)})}if("?"===r){const e=t.optional++;return r=>t.parser.optional(e,{DEF:()=>n(r),GATE:i?()=>i(r):void 0})}(0,tn.U)(r)}function cn(t,e){const n=function(t,e){if((0,s.F9)(e))return e.name;if(t.ruleNames.has(e))return t.ruleNames.get(e);{let n=e,r=n.$container,i=e.$type;for(;!(0,s.F9)(r);)((0,s.ty)(r)||(0,s.MZ)(r)||(0,s.W1)(r))&&(i=r.elements.indexOf(n).toString()+":"+i),n=r,r=r.$container;return i=r.name+":"+i,t.ruleNames.set(e,i),i}}(t,e),r=t.parser.getRule(n);if(!r)throw new Error(`Rule "${n}" not found."`);return r}function hn(t,e){const n=t.tokens[e];if(!n)throw new Error(`Token "${e}" not found."`);return n}var un=n(7447),dn=n(1930),pn=n(3881),gn=n(28);let fn=0;const mn=Symbol("OperationCancelled");function yn(t){return t===mn}async function vn(t){if(t===pn.Ts.None)return;const e=performance.now();if(e-fn>=10&&(fn=e,await new Promise((t=>{"undefined"==typeof setImmediate?setTimeout(t,0):setImmediate(t)})),fn=performance.now()),t.isCancellationRequested)throw mn}class xn{constructor(){this.promise=new Promise(((t,e)=>{this.resolve=e=>(t(e),this),this.reject=t=>(e(t),this)}))}}class bn{constructor(t,e,n,r){this._uri=t,this._languageId=e,this._version=n,this._content=r,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(t){if(t){const e=this.offsetAt(t.start),n=this.offsetAt(t.end);return this._content.substring(e,n)}return this._content}update(t,e){for(const e of t)if(bn.isIncremental(e)){const t=En(e.range),n=this.offsetAt(t.start),r=this.offsetAt(t.end);this._content=this._content.substring(0,n)+e.text+this._content.substring(r,this._content.length);const i=Math.max(t.start.line,0),a=Math.max(t.end.line,0);let s=this._lineOffsets;const o=Tn(e.text,!1,n);if(a-i===o.length)for(let t=0,e=o.length;tt?r=i:n=i+1}const i=n-1;return{line:i,character:(t=this.ensureBeforeEOL(t,e[i]))-e[i]}}offsetAt(t){const e=this.getLineOffsets();if(t.line>=e.length)return this._content.length;if(t.line<0)return 0;const n=e[t.line];if(t.character<=0)return n;const r=t.line+1e&&_n(this._content.charCodeAt(t-1));)t--;return t}get lineCount(){return this.getLineOffsets().length}static isIncremental(t){const e=t;return null!=e&&"string"==typeof e.text&&void 0!==e.range&&(void 0===e.rangeLength||"number"==typeof e.rangeLength)}static isFull(t){const e=t;return null!=e&&"string"==typeof e.text&&void 0===e.range&&void 0===e.rangeLength}}var wn;function kn(t,e){if(t.length<=1)return t;const n=t.length/2|0,r=t.slice(0,n),i=t.slice(n);kn(r,e),kn(i,e);let a=0,s=0,o=0;for(;an.line||e.line===n.line&&e.character>n.character?{start:n,end:e}:t}function Sn(t){const e=En(t.range);return e!==t.range?{newText:t.newText,range:e}:t}!function(t){t.create=function(t,e,n,r){return new bn(t,e,n,r)},t.update=function(t,e,n){if(t instanceof bn)return t.update(e,n),t;throw new Error("TextDocument.update: document must be created by TextDocument.create")},t.applyEdits=function(t,e){const n=t.getText(),r=kn(e.map(Sn),((t,e)=>{const n=t.range.start.line-e.range.start.line;return 0===n?t.range.start.character-e.range.start.character:n}));let i=0;const a=[];for(const e of r){const r=t.offsetAt(e.range.start);if(ri&&a.push(n.substring(i,r)),e.newText.length&&a.push(e.newText),i=t.offsetAt(e.range.end)}return a.push(n.substr(i)),a.join("")}}(wn||(wn={}));var Cn,An=n(6883);!function(t){t[t.Changed=0]="Changed",t[t.Parsed=1]="Parsed",t[t.IndexedContent=2]="IndexedContent",t[t.ComputedScopes=3]="ComputedScopes",t[t.Linked=4]="Linked",t[t.IndexedReferences=5]="IndexedReferences",t[t.Validated=6]="Validated"}(Cn||(Cn={}));class Ln{constructor(t){this.serviceRegistry=t.ServiceRegistry,this.textDocuments=t.workspace.TextDocuments,this.fileSystemProvider=t.workspace.FileSystemProvider}async fromUri(t,e=pn.Ts.None){const n=await this.fileSystemProvider.readFile(t);return this.createAsync(t,n,e)}fromTextDocument(t,e,n){return e=null!=e?e:An.o.parse(t.uri),pn.Ts.is(n)?this.createAsync(e,t,n):this.create(e,t,n)}fromString(t,e,n){return pn.Ts.is(n)?this.createAsync(e,t,n):this.create(e,t,n)}fromModel(t,e){return this.create(e,{$model:t})}create(t,e,n){if("string"==typeof e){const r=this.parse(t,e,n);return this.createLangiumDocument(r,t,void 0,e)}if("$model"in e){const n={value:e.$model,parserErrors:[],lexerErrors:[]};return this.createLangiumDocument(n,t)}{const r=this.parse(t,e.getText(),n);return this.createLangiumDocument(r,t,e)}}async createAsync(t,e,n){if("string"==typeof e){const r=await this.parseAsync(t,e,n);return this.createLangiumDocument(r,t,void 0,e)}{const r=await this.parseAsync(t,e.getText(),n);return this.createLangiumDocument(r,t,e)}}createLangiumDocument(t,e,n,r){let i;if(n)i={parseResult:t,uri:e,state:Cn.Parsed,references:[],textDocument:n};else{const n=this.createTextDocumentGetter(e,r);i={parseResult:t,uri:e,state:Cn.Parsed,references:[],get textDocument(){return n()}}}return t.value.$document=i,i}async update(t,e){var n,r;const i=null===(n=t.parseResult.value.$cstNode)||void 0===n?void 0:n.root.fullText,a=null===(r=this.textDocuments)||void 0===r?void 0:r.get(t.uri.toString()),s=a?a.getText():await this.fileSystemProvider.readFile(t.uri);if(a)Object.defineProperty(t,"textDocument",{value:a});else{const e=this.createTextDocumentGetter(t.uri,s);Object.defineProperty(t,"textDocument",{get:e})}return i!==s&&(t.parseResult=await this.parseAsync(t.uri,s,e),t.parseResult.value.$document=t),t.state=Cn.Parsed,t}parse(t,e,n){return this.serviceRegistry.getServices(t).parser.LangiumParser.parse(e,n)}parseAsync(t,e,n){return this.serviceRegistry.getServices(t).parser.AsyncParser.parse(e,n)}createTextDocumentGetter(t,e){const n=this.serviceRegistry;let r;return()=>null!=r?r:r=wn.create(t.toString(),n.getServices(t).LanguageMetaData.languageId,0,null!=e?e:"")}}class Mn{constructor(t){this.documentMap=new Map,this.langiumDocumentFactory=t.workspace.LangiumDocumentFactory,this.serviceRegistry=t.ServiceRegistry}get all(){return(0,en.Vw)(this.documentMap.values())}addDocument(t){const e=t.uri.toString();if(this.documentMap.has(e))throw new Error(`A document with the URI '${e}' is already present.`);this.documentMap.set(e,t)}getDocument(t){const e=t.toString();return this.documentMap.get(e)}async getOrCreateDocument(t,e){let n=this.getDocument(t);return n||(n=await this.langiumDocumentFactory.fromUri(t,e),this.addDocument(n),n)}createDocument(t,e,n){if(n)return this.langiumDocumentFactory.fromString(e,t,n).then((t=>(this.addDocument(t),t)));{const n=this.langiumDocumentFactory.fromString(e,t);return this.addDocument(n),n}}hasDocument(t){return this.documentMap.has(t.toString())}invalidateDocument(t){const e=t.toString(),n=this.documentMap.get(e);return n&&(this.serviceRegistry.getServices(t).references.Linker.unlink(n),n.state=Cn.Changed,n.precomputedScopes=void 0,n.diagnostics=void 0),n}deleteDocument(t){const e=t.toString(),n=this.documentMap.get(e);return n&&(n.state=Cn.Changed,this.documentMap.delete(e)),n}}const Nn=Symbol("ref_resolving");class In{constructor(t){this.reflection=t.shared.AstReflection,this.langiumDocuments=()=>t.shared.workspace.LangiumDocuments,this.scopeProvider=t.references.ScopeProvider,this.astNodeLocator=t.workspace.AstNodeLocator}async link(t,e=pn.Ts.None){for(const n of(0,Pe.Zc)(t.parseResult.value))await vn(e),(0,Pe.fy)(n).forEach((e=>this.doLink(e,t)))}doLink(t,e){var n;const r=t.reference;if(void 0===r._ref){r._ref=Nn;try{const e=this.getCandidate(t);if((0,gn.et)(e))r._ref=e;else if(r._nodeDescription=e,this.langiumDocuments().hasDocument(e.documentUri)){const n=this.loadAstNode(e);r._ref=null!=n?n:this.createLinkingError(t,e)}else r._ref=void 0}catch(e){console.error(`An error occurred while resolving reference to '${r.$refText}':`,e);const i=null!==(n=e.message)&&void 0!==n?n:String(e);r._ref=Object.assign(Object.assign({},t),{message:`An error occurred while resolving reference to '${r.$refText}': ${i}`})}e.references.push(r)}}unlink(t){for(const e of t.references)delete e._ref,delete e._nodeDescription;t.references=[]}getCandidate(t){const e=this.scopeProvider.getScope(t).getElement(t.reference.$refText);return null!=e?e:this.createLinkingError(t)}buildReference(t,e,n,r){const i=this,a={$refNode:n,$refText:r,get ref(){var n;if((0,gn.xA)(this._ref))return this._ref;if((0,gn.SI)(this._nodeDescription)){const n=i.loadAstNode(this._nodeDescription);this._ref=null!=n?n:i.createLinkingError({reference:a,container:t,property:e},this._nodeDescription)}else if(void 0===this._ref){this._ref=Nn;const r=(0,Pe.E$)(t).$document,s=i.getLinkedNode({reference:a,container:t,property:e});if(s.error&&r&&r.statet.length>0)),a=r.split("/").filter((t=>t.length>0));let s=0;for(;s=t.end)return e.ref}if(n){const e=this.nameProvider.getNameNode(n);if(e&&(e===t||(0,r.OB)(t,e)))return n}}}findDeclarationNode(t){const e=this.findDeclaration(t);if(null==e?void 0:e.$cstNode){const t=this.nameProvider.getNameNode(e);return null!=t?t:e.$cstNode}}findReferences(t,e){const n=[];if(e.includeDeclaration){const e=this.getReferenceToSelf(t);e&&n.push(e)}let r=this.index.findAllReferences(t,this.nodeLocator.getAstNodePath(t));return e.documentUri&&(r=r.filter((t=>Dn.equals(t.sourceUri,e.documentUri)))),n.push(...r),(0,en.Vw)(n)}getReferenceToSelf(t){const e=this.nameProvider.getNameNode(t);if(e){const n=(0,Pe.Me)(t),i=this.nodeLocator.getAstNodePath(t);return{sourceUri:n.uri,sourcePath:i,targetUri:n.uri,targetPath:i,segment:(0,r.yn)(e),local:!0}}}}class Bn{constructor(t){if(this.map=new Map,t)for(const[e,n]of t)this.add(e,n)}get size(){return en.IH.sum((0,en.Vw)(this.map.values()).map((t=>t.length)))}clear(){this.map.clear()}delete(t,e){if(void 0===e)return this.map.delete(t);{const n=this.map.get(t);if(n){const r=n.indexOf(e);if(r>=0)return 1===n.length?this.map.delete(t):n.splice(r,1),!0}return!1}}get(t){var e;return null!==(e=this.map.get(t))&&void 0!==e?e:[]}has(t,e){if(void 0===e)return this.map.has(t);{const n=this.map.get(t);return!!n&&n.indexOf(e)>=0}}add(t,e){return this.map.has(t)?this.map.get(t).push(e):this.map.set(t,[e]),this}addAll(t,e){return this.map.has(t)?this.map.get(t).push(...e):this.map.set(t,Array.from(e)),this}forEach(t){this.map.forEach(((e,n)=>e.forEach((e=>t(e,n,this)))))}[Symbol.iterator](){return this.entries().iterator()}entries(){return(0,en.Vw)(this.map.entries()).flatMap((([t,e])=>e.map((e=>[t,e]))))}keys(){return(0,en.Vw)(this.map.keys())}values(){return(0,en.Vw)(this.map.values()).flat()}entriesGroupedByKey(){return(0,en.Vw)(this.map.entries())}}class Fn{get size(){return this.map.size}constructor(t){if(this.map=new Map,this.inverse=new Map,t)for(const[e,n]of t)this.set(e,n)}clear(){this.map.clear(),this.inverse.clear()}set(t,e){return this.map.set(t,e),this.inverse.set(e,t),this}get(t){return this.map.get(t)}getKey(t){return this.inverse.get(t)}delete(t){const e=this.map.get(t);return void 0!==e&&(this.map.delete(t),this.inverse.delete(e),!0)}}class Wn{constructor(t){this.nameProvider=t.references.NameProvider,this.descriptions=t.workspace.AstNodeDescriptionProvider}async computeExports(t,e=pn.Ts.None){return this.computeExportsForNode(t.parseResult.value,t,void 0,e)}async computeExportsForNode(t,e,n=Pe.sx,r=pn.Ts.None){const i=[];this.exportNode(t,i,e);for(const a of n(t))await vn(r),this.exportNode(a,i,e);return i}exportNode(t,e,n){const r=this.nameProvider.getName(t);r&&e.push(this.descriptions.createDescription(t,r,n))}async computeLocalScopes(t,e=pn.Ts.None){const n=t.parseResult.value,r=new Bn;for(const i of(0,Pe.VY)(n))await vn(e),this.processNode(i,t,r);return r}processNode(t,e,n){const r=t.$container;if(r){const i=this.nameProvider.getName(t);i&&n.add(r,this.descriptions.createDescription(t,i,e))}}}class zn{constructor(t,e,n){var r;this.elements=t,this.outerScope=e,this.caseInsensitive=null!==(r=null==n?void 0:n.caseInsensitive)&&void 0!==r&&r}getAllElements(){return this.outerScope?this.elements.concat(this.outerScope.getAllElements()):this.elements}getElement(t){return(this.caseInsensitive?this.elements.find((e=>e.name.toLowerCase()===t.toLowerCase())):this.elements.find((e=>e.name===t)))||(this.outerScope?this.outerScope.getElement(t):void 0)}}class Zn{constructor(t,e,n){var r;this.elements=new Map,this.caseInsensitive=null!==(r=null==n?void 0:n.caseInsensitive)&&void 0!==r&&r;for(const e of t){const t=this.caseInsensitive?e.name.toLowerCase():e.name;this.elements.set(t,e)}this.outerScope=e}getElement(t){const e=this.caseInsensitive?t.toLowerCase():t;return this.elements.get(e)||(this.outerScope?this.outerScope.getElement(t):void 0)}getAllElements(){let t=(0,en.Vw)(this.elements.values());return this.outerScope&&(t=t.concat(this.outerScope.getAllElements())),t}}class Yn{constructor(){this.toDispose=[],this.isDisposed=!1}onDispose(t){this.toDispose.push(t)}dispose(){this.throwIfDisposed(),this.clear(),this.isDisposed=!0,this.toDispose.forEach((t=>t.dispose()))}throwIfDisposed(){if(this.isDisposed)throw new Error("This cache has already been disposed")}}class Un extends Yn{constructor(){super(...arguments),this.cache=new Map}has(t){return this.throwIfDisposed(),this.cache.has(t)}set(t,e){this.throwIfDisposed(),this.cache.set(t,e)}get(t,e){if(this.throwIfDisposed(),this.cache.has(t))return this.cache.get(t);if(e){const n=e();return this.cache.set(t,n),n}}delete(t){return this.throwIfDisposed(),this.cache.delete(t)}clear(){this.throwIfDisposed(),this.cache.clear()}}class Gn extends Yn{constructor(t){super(),this.cache=new Map,this.converter=null!=t?t:t=>t}has(t,e){return this.throwIfDisposed(),this.cacheForContext(t).has(e)}set(t,e,n){this.throwIfDisposed(),this.cacheForContext(t).set(e,n)}get(t,e,n){this.throwIfDisposed();const r=this.cacheForContext(t);if(r.has(e))return r.get(e);if(n){const t=n();return r.set(e,t),t}}delete(t,e){return this.throwIfDisposed(),this.cacheForContext(t).delete(e)}clear(t){if(this.throwIfDisposed(),t){const e=this.converter(t);this.cache.delete(e)}else this.cache.clear()}cacheForContext(t){const e=this.converter(t);let n=this.cache.get(e);return n||(n=new Map,this.cache.set(e,n)),n}}class Vn extends Un{constructor(t,e){super(),e?(this.toDispose.push(t.workspace.DocumentBuilder.onBuildPhase(e,(()=>{this.clear()}))),this.toDispose.push(t.workspace.DocumentBuilder.onUpdate(((t,e)=>{e.length>0&&this.clear()})))):this.toDispose.push(t.workspace.DocumentBuilder.onUpdate((()=>{this.clear()})))}}class qn{constructor(t){this.reflection=t.shared.AstReflection,this.nameProvider=t.references.NameProvider,this.descriptions=t.workspace.AstNodeDescriptionProvider,this.indexManager=t.shared.workspace.IndexManager,this.globalScopeCache=new Vn(t.shared)}getScope(t){const e=[],n=this.reflection.getReferenceType(t),r=(0,Pe.Me)(t.container).precomputedScopes;if(r){let i=t.container;do{const t=r.get(i);t.length>0&&e.push((0,en.Vw)(t).filter((t=>this.reflection.isSubtype(t.type,n)))),i=i.$container}while(i)}let i=this.getGlobalScope(n,t);for(let t=e.length-1;t>=0;t--)i=this.createScope(e[t],i);return i}createScope(t,e,n){return new zn((0,en.Vw)(t),e,n)}createScopeForNodes(t,e,n){const r=(0,en.Vw)(t).map((t=>{const e=this.nameProvider.getName(t);if(e)return this.descriptions.createDescription(t,e)})).nonNullable();return new zn(r,e,n)}getGlobalScope(t,e){return this.globalScopeCache.get(t,(()=>new Zn(this.indexManager.allElements(t))))}}function jn(t){return"object"==typeof t&&!!t&&("$ref"in t||"$error"in t)}class Hn{constructor(t){this.ignoreProperties=new Set(["$container","$containerProperty","$containerIndex","$document","$cstNode"]),this.langiumDocuments=t.shared.workspace.LangiumDocuments,this.astNodeLocator=t.workspace.AstNodeLocator,this.nameProvider=t.references.NameProvider,this.commentProvider=t.documentation.CommentProvider}serialize(t,e){const n=null!=e?e:{},r=null==e?void 0:e.replacer,i=(t,e)=>this.replacer(t,e,n),a=r?(t,e)=>r(t,e,i):i;try{return this.currentDocument=(0,Pe.Me)(t),JSON.stringify(t,a,null==e?void 0:e.space)}finally{this.currentDocument=void 0}}deserialize(t,e){const n=null!=e?e:{},r=JSON.parse(t);return this.linkNode(r,r,n),r}replacer(t,e,{refText:n,sourceText:r,textRegions:i,comments:a,uriConverter:s}){var o,l,c,h;if(!this.ignoreProperties.has(t)){if((0,gn.Yk)(e)){const t=e.ref,r=n?e.$refText:void 0;if(t){const n=(0,Pe.Me)(t);let i="";return this.currentDocument&&this.currentDocument!==n&&(i=s?s(n.uri,e):n.uri.toString()),{$ref:`${i}#${this.astNodeLocator.getAstNodePath(t)}`,$refText:r}}return{$error:null!==(l=null===(o=e.error)||void 0===o?void 0:o.message)&&void 0!==l?l:"Could not resolve reference",$refText:r}}if((0,gn.xA)(e)){let n;if(i&&(n=this.addAstNodeRegionWithAssignmentsTo(Object.assign({},e)),t&&!e.$document||!(null==n?void 0:n.$textRegion)||(n.$textRegion.documentURI=null===(c=this.currentDocument)||void 0===c?void 0:c.uri.toString())),r&&!t&&(null!=n||(n=Object.assign({},e)),n.$sourceText=null===(h=e.$cstNode)||void 0===h?void 0:h.text),a){null!=n||(n=Object.assign({},e));const t=this.commentProvider.getComment(e);t&&(n.$comment=t.replace(/\r/g,""))}return null!=n?n:e}return e}}addAstNodeRegionWithAssignmentsTo(t){const e=t=>({offset:t.offset,end:t.end,length:t.length,range:t.range});if(t.$cstNode){const n=(t.$textRegion=e(t.$cstNode)).assignments={};return Object.keys(t).filter((t=>!t.startsWith("$"))).forEach((r=>{const a=(0,i.EL)(t.$cstNode,r).map(e);0!==a.length&&(n[r]=a)})),t}}linkNode(t,e,n,r,i,a){for(const[r,i]of Object.entries(t))if(Array.isArray(i))for(let a=0;a{await this.handleException((()=>t.call(e,n,r,i)),"An error occurred during validation",r,n)}}async handleException(t,e,n,r){try{await t()}catch(t){if(yn(t))throw t;console.error(`${e}:`,t),t instanceof Error&&t.stack&&console.error(t.stack),n("error",`${e}: ${t instanceof Error?t.message:String(t)}`,{node:r})}}addEntry(t,e){if("AstNode"!==t)for(const n of this.reflection.getAllSubTypes(t))this.entries.add(n,e);else this.entries.add("AstNode",e)}getChecks(t,e){let n=(0,en.Vw)(this.entries.get(t)).concat(this.entries.get("AstNode"));return e&&(n=n.filter((t=>e.includes(t.category)))),n.map((t=>t.check))}registerBeforeDocument(t,e=this){this.entriesBefore.push(this.wrapPreparationException(t,"An error occurred during set-up of the validation",e))}registerAfterDocument(t,e=this){this.entriesAfter.push(this.wrapPreparationException(t,"An error occurred during tear-down of the validation",e))}wrapPreparationException(t,e,n){return async(r,i,a,s)=>{await this.handleException((()=>t.call(n,r,i,a,s)),e,i,r)}}get checksBefore(){return this.entriesBefore}get checksAfter(){return this.entriesAfter}}class Jn{constructor(t){this.validationRegistry=t.validation.ValidationRegistry,this.metadata=t.LanguageMetaData}async validateDocument(t,e={},n=pn.Ts.None){const r=t.parseResult,i=[];if(await vn(n),!e.categories||e.categories.includes("built-in")){if(this.processLexingErrors(r,i,e),e.stopAfterLexingErrors&&i.some((t=>{var e;return(null===(e=t.data)||void 0===e?void 0:e.code)===Pn.LexingError})))return i;if(this.processParsingErrors(r,i,e),e.stopAfterParsingErrors&&i.some((t=>{var e;return(null===(e=t.data)||void 0===e?void 0:e.code)===Pn.ParsingError})))return i;if(this.processLinkingErrors(t,i,e),e.stopAfterLinkingErrors&&i.some((t=>{var e;return(null===(e=t.data)||void 0===e?void 0:e.code)===Pn.LinkingError})))return i}try{i.push(...await this.validateAst(r.value,e,n))}catch(t){if(yn(t))throw t;console.error("An error occurred during validation:",t)}return await vn(n),i}processLexingErrors(t,e,n){var r,i,a;const s=[...t.lexerErrors,...null!==(i=null===(r=t.lexerReport)||void 0===r?void 0:r.diagnostics)&&void 0!==i?i:[]];for(const t of s){const n=null!==(a=t.severity)&&void 0!==a?a:"error",r={severity:er(n),range:{start:{line:t.line-1,character:t.column-1},end:{line:t.line-1,character:t.column+t.length-1}},message:t.message,data:nr(n),source:this.getSource()};e.push(r)}}processParsingErrors(t,e,n){for(const n of t.parserErrors){let t;if(isNaN(n.token.startOffset)){if("previousToken"in n){const e=n.previousToken;if(isNaN(e.startOffset)){const e={line:0,character:0};t={start:e,end:e}}else{const n={line:e.endLine-1,character:e.endColumn};t={start:n,end:n}}}}else t=(0,r.sp)(n.token);if(t){const r={severity:er("error"),range:t,message:n.message,data:Kn(Pn.ParsingError),source:this.getSource()};e.push(r)}}}processLinkingErrors(t,e,n){for(const n of t.references){const t=n.error;if(t){const n={node:t.container,property:t.property,index:t.index,data:{code:Pn.LinkingError,containerType:t.container.$type,property:t.property,refText:t.reference.$refText}};e.push(this.toDiagnostic("error",t.message,n))}}}async validateAst(t,e,n=pn.Ts.None){const r=[],i=(t,e,n)=>{r.push(this.toDiagnostic(t,e,n))};return await this.validateAstBefore(t,e,i,n),await this.validateAstNodes(t,e,i,n),await this.validateAstAfter(t,e,i,n),r}async validateAstBefore(t,e,n,r=pn.Ts.None){var i;const a=this.validationRegistry.checksBefore;for(const s of a)await vn(r),await s(t,n,null!==(i=e.categories)&&void 0!==i?i:[],r)}async validateAstNodes(t,e,n,r=pn.Ts.None){await Promise.all((0,Pe.Zc)(t).map((async t=>{await vn(r);const i=this.validationRegistry.getChecks(t.$type,e.categories);for(const e of i)await e(t,n,r)})))}async validateAstAfter(t,e,n,r=pn.Ts.None){var i;const a=this.validationRegistry.checksAfter;for(const s of a)await vn(r),await s(t,n,null!==(i=e.categories)&&void 0!==i?i:[],r)}toDiagnostic(t,e,n){return{message:e,range:tr(n),severity:er(t),code:n.code,codeDescription:n.codeDescription,tags:n.tags,relatedInformation:n.relatedInformation,data:n.data,source:this.getSource()}}getSource(){return this.metadata.languageId}}function tr(t){if(t.range)return t.range;let e;return"string"==typeof t.property?e=(0,i.vb)(t.node.$cstNode,t.property,t.index):"string"==typeof t.keyword&&(e=(0,i.lA)(t.node.$cstNode,t.keyword,t.index)),null!=e||(e=t.node.$cstNode),e?e.range:{start:{line:0,character:0},end:{line:0,character:0}}}function er(t){switch(t){case"error":return 1;case"warning":return 2;case"info":return 3;case"hint":return 4;default:throw new Error("Invalid diagnostic severity: "+t)}}function nr(t){switch(t){case"error":return Kn(Pn.LexingError);case"warning":return Kn(Pn.LexingWarning);case"info":return Kn(Pn.LexingInfo);case"hint":return Kn(Pn.LexingHint);default:throw new Error("Invalid diagnostic severity: "+t)}}!function(t){t.LexingError="lexing-error",t.LexingWarning="lexing-warning",t.LexingInfo="lexing-info",t.LexingHint="lexing-hint",t.ParsingError="parsing-error",t.LinkingError="linking-error"}(Pn||(Pn={}));class rr{constructor(t){this.astNodeLocator=t.workspace.AstNodeLocator,this.nameProvider=t.references.NameProvider}createDescription(t,e,n){const i=null!=n?n:(0,Pe.Me)(t);null!=e||(e=this.nameProvider.getName(t));const a=this.astNodeLocator.getAstNodePath(t);if(!e)throw new Error(`Node at path ${a} has no name.`);let s;const o=()=>{var e;return null!=s?s:s=(0,r.yn)(null!==(e=this.nameProvider.getNameNode(t))&&void 0!==e?e:t.$cstNode)};return{node:t,name:e,get nameSegment(){return o()},selectionSegment:(0,r.yn)(t.$cstNode),type:t.$type,documentUri:i.uri,path:a}}}class ir{constructor(t){this.nodeLocator=t.workspace.AstNodeLocator}async createDescriptions(t,e=pn.Ts.None){const n=[],r=t.parseResult.value;for(const t of(0,Pe.Zc)(r))await vn(e),(0,Pe.fy)(t).filter((t=>!(0,gn.et)(t))).forEach((t=>{const e=this.createDescription(t);e&&n.push(e)}));return n}createDescription(t){const e=t.reference.$nodeDescription,n=t.reference.$refNode;if(!e||!n)return;const i=(0,Pe.Me)(t.container).uri;return{sourceUri:i,sourcePath:this.nodeLocator.getAstNodePath(t.container),targetUri:e.documentUri,targetPath:e.path,segment:(0,r.yn)(n),local:Dn.equals(e.documentUri,i)}}}class ar{constructor(){this.segmentSeparator="/",this.indexSeparator="@"}getAstNodePath(t){if(t.$container){const e=this.getAstNodePath(t.$container),n=this.getPathSegment(t);return e+this.segmentSeparator+n}return""}getPathSegment({$containerProperty:t,$containerIndex:e}){if(!t)throw new Error("Missing '$containerProperty' in AST node.");return void 0!==e?t+this.indexSeparator+e:t}getAstNode(t,e){return e.split(this.segmentSeparator).reduce(((t,e)=>{if(!t||0===e.length)return t;const n=e.indexOf(this.indexSeparator);if(n>0){const r=e.substring(0,n),i=parseInt(e.substring(n+1)),a=t[r];return null==a?void 0:a[i]}return t[e]}),t)}}var sr,or=n(7135);class lr{constructor(t){this._ready=new xn,this.settings={},this.workspaceConfig=!1,this.onConfigurationSectionUpdateEmitter=new or.Emitter,this.serviceRegistry=t.ServiceRegistry}get ready(){return this._ready.promise}initialize(t){var e,n;this.workspaceConfig=null!==(n=null===(e=t.capabilities.workspace)||void 0===e?void 0:e.configuration)&&void 0!==n&&n}async initialized(t){if(this.workspaceConfig){if(t.register){const e=this.serviceRegistry.all;t.register({section:e.map((t=>this.toSectionName(t.LanguageMetaData.languageId)))})}if(t.fetchConfiguration){const e=this.serviceRegistry.all.map((t=>({section:this.toSectionName(t.LanguageMetaData.languageId)}))),n=await t.fetchConfiguration(e);e.forEach(((t,e)=>{this.updateSectionConfiguration(t.section,n[e])}))}}this._ready.resolve()}updateConfiguration(t){t.settings&&Object.keys(t.settings).forEach((e=>{const n=t.settings[e];this.updateSectionConfiguration(e,n),this.onConfigurationSectionUpdateEmitter.fire({section:e,configuration:n})}))}updateSectionConfiguration(t,e){this.settings[t]=e}async getConfiguration(t,e){await this.ready;const n=this.toSectionName(t);if(this.settings[n])return this.settings[n][e]}toSectionName(t){return`${t}`}get onConfigurationSectionUpdate(){return this.onConfigurationSectionUpdateEmitter.event}}!function(t){t.create=function(t){return{dispose:async()=>await t()}}}(sr||(sr={}));class cr{constructor(t){this.updateBuildOptions={validation:{categories:["built-in","fast"]}},this.updateListeners=[],this.buildPhaseListeners=new Bn,this.documentPhaseListeners=new Bn,this.buildState=new Map,this.documentBuildWaiters=new Map,this.currentState=Cn.Changed,this.langiumDocuments=t.workspace.LangiumDocuments,this.langiumDocumentFactory=t.workspace.LangiumDocumentFactory,this.textDocuments=t.workspace.TextDocuments,this.indexManager=t.workspace.IndexManager,this.serviceRegistry=t.ServiceRegistry}async build(t,e={},n=pn.Ts.None){var r,i;for(const n of t){const t=n.uri.toString();if(n.state===Cn.Validated){if("boolean"==typeof e.validation&&e.validation)n.state=Cn.IndexedReferences,n.diagnostics=void 0,this.buildState.delete(t);else if("object"==typeof e.validation){const a=this.buildState.get(t),s=null===(r=null==a?void 0:a.result)||void 0===r?void 0:r.validationChecks;if(s){const r=(null!==(i=e.validation.categories)&&void 0!==i?i:On.all).filter((t=>!s.includes(t)));r.length>0&&(this.buildState.set(t,{completed:!1,options:{validation:Object.assign(Object.assign({},e.validation),{categories:r})},result:a.result}),n.state=Cn.IndexedReferences)}}}else this.buildState.delete(t)}this.currentState=Cn.Changed,await this.emitUpdate(t.map((t=>t.uri)),[]),await this.buildDocuments(t,e,n)}async update(t,e,n=pn.Ts.None){this.currentState=Cn.Changed;for(const t of e)this.langiumDocuments.deleteDocument(t),this.buildState.delete(t.toString()),this.indexManager.remove(t);for(const e of t){if(!this.langiumDocuments.invalidateDocument(e)){const t=this.langiumDocumentFactory.fromModel({$type:"INVALID"},e);t.state=Cn.Changed,this.langiumDocuments.addDocument(t)}this.buildState.delete(e.toString())}const r=(0,en.Vw)(t).concat(e).map((t=>t.toString())).toSet();this.langiumDocuments.all.filter((t=>!r.has(t.uri.toString())&&this.shouldRelink(t,r))).forEach((t=>{this.serviceRegistry.getServices(t.uri).references.Linker.unlink(t),t.state=Math.min(t.state,Cn.ComputedScopes),t.diagnostics=void 0})),await this.emitUpdate(t,e),await vn(n);const i=this.sortDocuments(this.langiumDocuments.all.filter((t=>{var e;return t.staten(t,e))))}sortDocuments(t){let e=0,n=t.length-1;for(;e=0&&!this.hasTextDocument(t[n]);)n--;evoid 0!==t.error))||this.indexManager.isAffected(t,e)}onUpdate(t){return this.updateListeners.push(t),sr.create((()=>{const e=this.updateListeners.indexOf(t);e>=0&&this.updateListeners.splice(e,1)}))}async buildDocuments(t,e,n){this.prepareBuild(t,e),await this.runCancelable(t,Cn.Parsed,n,(t=>this.langiumDocumentFactory.update(t,n))),await this.runCancelable(t,Cn.IndexedContent,n,(t=>this.indexManager.updateContent(t,n))),await this.runCancelable(t,Cn.ComputedScopes,n,(async t=>{const e=this.serviceRegistry.getServices(t.uri).references.ScopeComputation;t.precomputedScopes=await e.computeLocalScopes(t,n)})),await this.runCancelable(t,Cn.Linked,n,(t=>this.serviceRegistry.getServices(t.uri).references.Linker.link(t,n))),await this.runCancelable(t,Cn.IndexedReferences,n,(t=>this.indexManager.updateReferences(t,n)));const r=t.filter((t=>this.shouldValidate(t)));await this.runCancelable(r,Cn.Validated,n,(t=>this.validate(t,n)));for(const e of t){const t=this.buildState.get(e.uri.toString());t&&(t.completed=!0)}}prepareBuild(t,e){for(const n of t){const t=n.uri.toString(),r=this.buildState.get(t);r&&!r.completed||this.buildState.set(t,{completed:!1,options:e,result:null==r?void 0:r.result})}}async runCancelable(t,e,n,r){const i=t.filter((t=>t.statet.state===e));await this.notifyBuildPhase(a,e,n),this.currentState=e}onBuildPhase(t,e){return this.buildPhaseListeners.add(t,e),sr.create((()=>{this.buildPhaseListeners.delete(t,e)}))}onDocumentPhase(t,e){return this.documentPhaseListeners.add(t,e),sr.create((()=>{this.documentPhaseListeners.delete(t,e)}))}waitUntil(t,e,n){let r;if(e&&"path"in e?r=e:n=e,null!=n||(n=pn.Ts.None),r){const e=this.langiumDocuments.getDocument(r);if(e&&e.state>t)return Promise.resolve(r)}return this.currentState>=t?Promise.resolve(void 0):n.isCancellationRequested?Promise.reject(mn):new Promise(((e,i)=>{const a=this.onBuildPhase(t,(()=>{if(a.dispose(),s.dispose(),r){const t=this.langiumDocuments.getDocument(r);e(null==t?void 0:t.uri)}else e(void 0)})),s=n.onCancellationRequested((()=>{a.dispose(),s.dispose(),i(mn)}))}))}async notifyDocumentPhase(t,e,n){const r=this.documentPhaseListeners.get(e).slice();for(const e of r)try{await e(t,n)}catch(t){if(!yn(t))throw t}}async notifyBuildPhase(t,e,n){if(0===t.length)return;const r=this.buildPhaseListeners.get(e).slice();for(const e of r)await vn(n),await e(t,n)}shouldValidate(t){return Boolean(this.getBuildOptions(t).validation)}async validate(t,e){var n,r;const i=this.serviceRegistry.getServices(t.uri).validation.DocumentValidator,a=this.getBuildOptions(t).validation,s="object"==typeof a?a:void 0,o=await i.validateDocument(t,s,e);t.diagnostics?t.diagnostics.push(...o):t.diagnostics=o;const l=this.buildState.get(t.uri.toString());if(l){null!==(n=l.result)&&void 0!==n||(l.result={});const t=null!==(r=null==s?void 0:s.categories)&&void 0!==r?r:On.all;l.result.validationChecks?l.result.validationChecks.push(...t):l.result.validationChecks=[...t]}}getBuildOptions(t){var e,n;return null!==(n=null===(e=this.buildState.get(t.uri.toString()))||void 0===e?void 0:e.options)&&void 0!==n?n:{}}}class hr{constructor(t){this.symbolIndex=new Map,this.symbolByTypeIndex=new Gn,this.referenceIndex=new Map,this.documents=t.workspace.LangiumDocuments,this.serviceRegistry=t.ServiceRegistry,this.astReflection=t.AstReflection}findAllReferences(t,e){const n=(0,Pe.Me)(t).uri,r=[];return this.referenceIndex.forEach((t=>{t.forEach((t=>{Dn.equals(t.targetUri,n)&&t.targetPath===e&&r.push(t)}))})),(0,en.Vw)(r)}allElements(t,e){let n=(0,en.Vw)(this.symbolIndex.keys());return e&&(n=n.filter((t=>!e||e.has(t)))),n.map((e=>this.getFileDescriptions(e,t))).flat()}getFileDescriptions(t,e){var n;if(!e)return null!==(n=this.symbolIndex.get(t))&&void 0!==n?n:[];const r=this.symbolByTypeIndex.get(t,e,(()=>{var n;return(null!==(n=this.symbolIndex.get(t))&&void 0!==n?n:[]).filter((t=>this.astReflection.isSubtype(t.type,e)))}));return r}remove(t){const e=t.toString();this.symbolIndex.delete(e),this.symbolByTypeIndex.clear(e),this.referenceIndex.delete(e)}async updateContent(t,e=pn.Ts.None){const n=this.serviceRegistry.getServices(t.uri),r=await n.references.ScopeComputation.computeExports(t,e),i=t.uri.toString();this.symbolIndex.set(i,r),this.symbolByTypeIndex.clear(i)}async updateReferences(t,e=pn.Ts.None){const n=this.serviceRegistry.getServices(t.uri),r=await n.workspace.ReferenceDescriptionProvider.createDescriptions(t,e);this.referenceIndex.set(t.uri.toString(),r)}isAffected(t,e){const n=this.referenceIndex.get(t.uri.toString());return!!n&&n.some((t=>!t.local&&e.has(t.targetUri.toString())))}}class ur{constructor(t){this.initialBuildOptions={},this._ready=new xn,this.serviceRegistry=t.ServiceRegistry,this.langiumDocuments=t.workspace.LangiumDocuments,this.documentBuilder=t.workspace.DocumentBuilder,this.fileSystemProvider=t.workspace.FileSystemProvider,this.mutex=t.workspace.WorkspaceLock}get ready(){return this._ready.promise}get workspaceFolders(){return this.folders}initialize(t){var e;this.folders=null!==(e=t.workspaceFolders)&&void 0!==e?e:void 0}initialized(t){return this.mutex.write((t=>{var e;return this.initializeWorkspace(null!==(e=this.folders)&&void 0!==e?e:[],t)}))}async initializeWorkspace(t,e=pn.Ts.None){const n=await this.performStartup(t);await vn(e),await this.documentBuilder.build(n,this.initialBuildOptions,e)}async performStartup(t){const e=this.serviceRegistry.all.flatMap((t=>t.LanguageMetaData.fileExtensions)),n=[],r=t=>{n.push(t),this.langiumDocuments.hasDocument(t.uri)||this.langiumDocuments.addDocument(t)};return await this.loadAdditionalDocuments(t,r),await Promise.all(t.map((t=>[t,this.getRootFolder(t)])).map((async t=>this.traverseFolder(...t,e,r)))),this._ready.resolve(),n}loadAdditionalDocuments(t,e){return Promise.resolve()}getRootFolder(t){return An.o.parse(t.uri)}async traverseFolder(t,e,n,r){const i=await this.fileSystemProvider.readDirectory(e);await Promise.all(i.map((async e=>{if(this.includeEntry(t,e,n))if(e.isDirectory)await this.traverseFolder(t,e.uri,n,r);else if(e.isFile){const t=await this.langiumDocuments.getOrCreateDocument(e.uri);r(t)}})))}includeEntry(t,e,n){const r=Dn.basename(e.uri);if(r.startsWith("."))return!1;if(e.isDirectory)return"node_modules"!==r&&"out"!==r;if(e.isFile){const t=Dn.extname(e.uri);return n.includes(t)}return!1}}class dr{buildUnexpectedCharactersMessage(t,e,n,r,i){return o.ZW.buildUnexpectedCharactersMessage(t,e,n,r,i)}buildUnableToPopLexerModeMessage(t){return o.ZW.buildUnableToPopLexerModeMessage(t)}}const pr={mode:"full"};class gr{constructor(t){this.errorMessageProvider=t.parser.LexerErrorMessageProvider,this.tokenBuilder=t.parser.TokenBuilder;const e=this.tokenBuilder.buildTokens(t.Grammar,{caseInsensitive:t.LanguageMetaData.caseInsensitive});this.tokenTypes=this.toTokenTypeDictionary(e);const n=mr(e)?Object.values(e):e,r="production"===t.LanguageMetaData.mode;this.chevrotainLexer=new o.hW(n,{positionTracking:"full",skipValidations:r,errorMessageProvider:this.errorMessageProvider})}get definition(){return this.tokenTypes}tokenize(t,e=pr){var n,r,i;const a=this.chevrotainLexer.tokenize(t);return{tokens:a.tokens,errors:a.errors,hidden:null!==(n=a.groups.hidden)&&void 0!==n?n:[],report:null===(i=(r=this.tokenBuilder).flushLexingReport)||void 0===i?void 0:i.call(r,t)}}toTokenTypeDictionary(t){if(mr(t))return t;const e=fr(t)?Object.values(t.modes).flat():t,n={};return e.forEach((t=>n[t.name]=t)),n}}function fr(t){return t&&"modes"in t&&"defaultMode"in t}function mr(t){return!function(t){return Array.isArray(t)&&(0===t.length||"name"in t[0])}(t)&&!fr(t)}function yr(t){let e="";return e="string"==typeof t?t:t.text,e.split(a.K0)}const vr=/\s*(@([\p{L}][\p{L}\p{N}]*)?)/uy,xr=/\{(@[\p{L}][\p{L}\p{N}]*)(\s*)([^\r\n}]+)?\}/gu;function br(t,e,n,r){const i=[];if(0===t.length){const t=gt.create(n,r),a=gt.create(n,r+e.length);i.push({type:"text",content:e,range:ft.create(t,a)})}else{let a=0;for(const s of t){const t=s.index,o=e.substring(a,t);o.length>0&&i.push({type:"text",content:e.substring(a,t),range:ft.create(gt.create(n,a+r),gt.create(n,t+r))});let l=o.length+1;const c=s[1];if(i.push({type:"inline-tag",content:c,range:ft.create(gt.create(n,a+l+r),gt.create(n,a+l+c.length+r))}),l+=c.length,4===s.length){l+=s[2].length;const t=s[3];i.push({type:"text",content:t,range:ft.create(gt.create(n,a+l+r),gt.create(n,a+l+t.length+r))})}else i.push({type:"text",content:"",range:ft.create(gt.create(n,a+l+r),gt.create(n,a+l+r))});a=t+s[0].length}const s=e.substring(a);s.length>0&&i.push({type:"text",content:s,range:ft.create(gt.create(n,a+r),gt.create(n,a+r+s.length))})}return i}const wr=/\S/,kr=/\s*$/;function Tr(t,e){const n=t.substring(e).match(wr);return n?e+n.index:t.length}function _r(t){const e=t.match(kr);if(e&&"number"==typeof e.index)return e.index}function Er(t,e){const n=t.tokens[t.index];return"tag"===n.type?Ar(t,!1):"text"===n.type||"inline-tag"===n.type?Sr(t):(function(t,e){if(e){const n=new Or("",t.range);"inlines"in e?e.inlines.push(n):e.content.inlines.push(n)}}(n,e),void t.index++)}function Sr(t){let e=t.tokens[t.index];const n=e;let r=e;const i=[];for(;e&&"break"!==e.type&&"tag"!==e.type;)i.push(Cr(t)),r=e,e=t.tokens[t.index];return new Dr(i,ft.create(n.range.start,r.range.end))}function Cr(t){return"inline-tag"===t.tokens[t.index].type?Ar(t,!0):Lr(t)}function Ar(t,e){const n=t.tokens[t.index++],r=n.content.substring(1),i=t.tokens[t.index];if("text"===(null==i?void 0:i.type)){if(e){const i=Lr(t);return new Rr(r,new Dr([i],i.range),e,ft.create(n.range.start,i.range.end))}{const i=Sr(t);return new Rr(r,i,e,ft.create(n.range.start,i.range.end))}}{const t=n.range;return new Rr(r,new Dr([],t),e,t)}}function Lr(t){const e=t.tokens[t.index++];return new Or(e.content,e.range)}function Mr(t){if(!t)return Mr({start:"/**",end:"*/",line:"*"});const{start:e,end:n,line:r}=t;return{start:Nr(e,!0),end:Nr(n,!1),line:Nr(r,!0)}}function Nr(t,e){if("string"==typeof t||"object"==typeof t){const n="string"==typeof t?(0,a.hr)(t):t.source;return e?new RegExp(`^\\s*${n}`):new RegExp(`\\s*${n}\\s*$`)}return t}class Ir{constructor(t,e){this.elements=t,this.range=e}getTag(t){return this.getAllTags().find((e=>e.name===t))}getTags(t){return this.getAllTags().filter((e=>e.name===t))}getAllTags(){return this.elements.filter((t=>"name"in t))}toString(){let t="";for(const e of this.elements)if(0===t.length)t=e.toString();else{const n=e.toString();t+=Pr(t)+n}return t.trim()}toMarkdown(t){let e="";for(const n of this.elements)if(0===e.length)e=n.toMarkdown(t);else{const r=n.toMarkdown(t);e+=Pr(e)+r}return e.trim()}}class Rr{constructor(t,e,n,r){this.name=t,this.content=e,this.inline=n,this.range=r}toString(){let t=`@${this.name}`;const e=this.content.toString();return 1===this.content.inlines.length?t=`${t} ${e}`:this.content.inlines.length>1&&(t=`${t}\n${e}`),this.inline?`{${t}}`:t}toMarkdown(t){var e,n;return null!==(n=null===(e=null==t?void 0:t.renderTag)||void 0===e?void 0:e.call(t,this))&&void 0!==n?n:this.toMarkdownDefault(t)}toMarkdownDefault(t){const e=this.content.toMarkdown(t);if(this.inline){const n=function(t,e,n){var r,i;if("linkplain"===t||"linkcode"===t||"link"===t){const a=e.indexOf(" ");let s=e;if(a>0){const t=Tr(e,a);s=e.substring(t),e=e.substring(0,a)}("linkcode"===t||"link"===t&&"code"===n.link)&&(s=`\`${s}\``);const o=null!==(i=null===(r=n.renderLink)||void 0===r?void 0:r.call(n,e,s))&&void 0!==i?i:function(t,e){try{return An.o.parse(t,!0),`[${e}](${t})`}catch(e){return t}}(e,s);return o}}(this.name,e,null!=t?t:{});if("string"==typeof n)return n}let n="";"italic"===(null==t?void 0:t.tag)||void 0===(null==t?void 0:t.tag)?n="*":"bold"===(null==t?void 0:t.tag)?n="**":"bold-italic"===(null==t?void 0:t.tag)&&(n="***");let r=`${n}@${this.name}${n}`;return 1===this.content.inlines.length?r=`${r} — ${e}`:this.content.inlines.length>1&&(r=`${r}\n${e}`),this.inline?`{${r}}`:r}}class Dr{constructor(t,e){this.inlines=t,this.range=e}toString(){let t="";for(let e=0;en.range.start.line&&(t+="\n")}return t}toMarkdown(t){let e="";for(let n=0;nr.range.start.line&&(e+="\n")}return e}}class Or{constructor(t,e){this.text=t,this.range=e}toString(){return this.text}toMarkdown(){return this.text}}function Pr(t){return t.endsWith("\n")?"\n":"\n\n"}class $r{constructor(t){this.indexManager=t.shared.workspace.IndexManager,this.commentProvider=t.documentation.CommentProvider}getDocumentation(t){const e=this.commentProvider.getComment(t);if(e&&function(t,e){const n=Mr(void 0),r=yr(t);if(0===r.length)return!1;const i=r[0],a=r[r.length-1],s=n.start,o=n.end;return Boolean(null==s?void 0:s.exec(i))&&Boolean(null==o?void 0:o.exec(a))}(e))return function(t,e,n){let r,i;"string"==typeof t?(i=e,r=n):(i=t.range.start,r=e),i||(i=gt.create(0,0));const a=function(t){var e,n,r;const i=[];let a=t.position.line,s=t.position.character;for(let o=0;o=h.length){if(i.length>0){const t=gt.create(a,s);i.push({type:"break",content:"",range:ft.create(t,t)})}}else{vr.lastIndex=u;const t=vr.exec(h);if(t){const e=t[0],n=t[1],r=gt.create(a,s+u),o=gt.create(a,s+u+e.length);i.push({type:"tag",content:n,range:ft.create(r,o)}),u+=e.length,u=Tr(h,u)}if(u0&&"break"===i[i.length-1].type?i.slice(0,-1):i}({lines:yr(t),position:i,options:Mr(r)});return function(t){var e,n,r,i;const a=gt.create(t.position.line,t.position.character);if(0===t.tokens.length)return new Ir([],ft.create(a,a));const s=[];for(;t.indexthis.documentationLinkRenderer(t,e,n),renderTag:e=>this.documentationTagRenderer(t,e)})}documentationLinkRenderer(t,e,n){var r;const i=null!==(r=this.findNameInPrecomputedScopes(t,e))&&void 0!==r?r:this.findNameInGlobalScope(t,e);if(i&&i.nameSegment){const t=i.nameSegment.range.start.line+1,e=i.nameSegment.range.start.character+1;return`[${n}](${i.documentUri.with({fragment:`L${t},${e}`}).toString()})`}}documentationTagRenderer(t,e){}findNameInPrecomputedScopes(t,e){const n=(0,Pe.Me)(t).precomputedScopes;if(!n)return;let r=t;do{const t=n.get(r).find((t=>t.name===e));if(t)return t;r=r.$container}while(r)}findNameInGlobalScope(t,e){return this.indexManager.allElements().find((t=>t.name===e))}}class Br{constructor(t){this.grammarConfig=()=>t.parser.GrammarConfig}getComment(t){var e;return function(t){return"string"==typeof t.$comment}(t)?t.$comment:null===(e=(0,r.LK)(t.$cstNode,this.grammarConfig().multilineCommentRules))||void 0===e?void 0:e.text}}class Fr{constructor(t){this.syncParser=t.parser.LangiumParser}parse(t,e){return Promise.resolve(this.syncParser.parse(t))}}class Wr{constructor(){this.previousTokenSource=new pn.AU,this.writeQueue=[],this.readQueue=[],this.done=!0}write(t){this.cancelWrite();const e=(fn=performance.now(),new pn.AU);return this.previousTokenSource=e,this.enqueue(this.writeQueue,t,e.token)}read(t){return this.enqueue(this.readQueue,t)}enqueue(t,e,n=pn.Ts.None){const r=new xn,i={action:e,deferred:r,cancellationToken:n};return t.push(i),this.performNextOperation(),r.promise}async performNextOperation(){if(!this.done)return;const t=[];if(this.writeQueue.length>0)t.push(this.writeQueue.shift());else{if(!(this.readQueue.length>0))return;t.push(...this.readQueue.splice(0,this.readQueue.length))}this.done=!1,await Promise.all(t.map((async({action:t,deferred:e,cancellationToken:n})=>{try{const r=await Promise.resolve().then((()=>t(n)));e.resolve(r)}catch(t){yn(t)?e.resolve(void 0):e.reject(t)}}))),this.done=!0,this.performNextOperation()}cancelWrite(){this.previousTokenSource.cancel()}}class zr{constructor(t){this.grammarElementIdMap=new Fn,this.tokenTypeIdMap=new Fn,this.grammar=t.Grammar,this.lexer=t.parser.Lexer,this.linker=t.references.Linker}dehydrate(t){return{lexerErrors:t.lexerErrors,lexerReport:t.lexerReport?this.dehydrateLexerReport(t.lexerReport):void 0,parserErrors:t.parserErrors.map((t=>Object.assign(Object.assign({},t),{message:t.message}))),value:this.dehydrateAstNode(t.value,this.createDehyrationContext(t.value))}}dehydrateLexerReport(t){return t}createDehyrationContext(t){const e=new Map,n=new Map;for(const n of(0,Pe.Zc)(t))e.set(n,{});if(t.$cstNode)for(const e of(0,r._t)(t.$cstNode))n.set(e,{});return{astNodes:e,cstNodes:n}}dehydrateAstNode(t,e){const n=e.astNodes.get(t);n.$type=t.$type,n.$containerIndex=t.$containerIndex,n.$containerProperty=t.$containerProperty,void 0!==t.$cstNode&&(n.$cstNode=this.dehydrateCstNode(t.$cstNode,e));for(const[r,i]of Object.entries(t))if(!r.startsWith("$"))if(Array.isArray(i)){const t=[];n[r]=t;for(const n of i)(0,gn.xA)(n)?t.push(this.dehydrateAstNode(n,e)):(0,gn.Yk)(n)?t.push(this.dehydrateReference(n,e)):t.push(n)}else(0,gn.xA)(i)?n[r]=this.dehydrateAstNode(i,e):(0,gn.Yk)(i)?n[r]=this.dehydrateReference(i,e):void 0!==i&&(n[r]=i);return n}dehydrateReference(t,e){const n={};return n.$refText=t.$refText,t.$refNode&&(n.$refNode=e.cstNodes.get(t.$refNode)),n}dehydrateCstNode(t,e){const n=e.cstNodes.get(t);return(0,gn.U8)(t)?n.fullText=t.fullText:n.grammarSource=this.getGrammarElementId(t.grammarSource),n.hidden=t.hidden,n.astNode=e.astNodes.get(t.astNode),(0,gn.al)(t)?n.content=t.content.map((t=>this.dehydrateCstNode(t,e))):(0,gn.dm)(t)&&(n.tokenType=t.tokenType.name,n.offset=t.offset,n.length=t.length,n.startLine=t.range.start.line,n.startColumn=t.range.start.character,n.endLine=t.range.end.line,n.endColumn=t.range.end.character),n}hydrate(t){const e=t.value,n=this.createHydrationContext(e);return"$cstNode"in e&&this.hydrateCstNode(e.$cstNode,n),{lexerErrors:t.lexerErrors,lexerReport:t.lexerReport,parserErrors:t.parserErrors,value:this.hydrateAstNode(e,n)}}createHydrationContext(t){const e=new Map,n=new Map;for(const n of(0,Pe.Zc)(t))e.set(n,{});let i;if(t.$cstNode)for(const e of(0,r._t)(t.$cstNode)){let t;"fullText"in e?(t=new Ye(e.fullText),i=t):"content"in e?t=new ze:"tokenType"in e&&(t=this.hydrateCstLeafNode(e)),t&&(n.set(e,t),t.root=i)}return{astNodes:e,cstNodes:n}}hydrateAstNode(t,e){const n=e.astNodes.get(t);n.$type=t.$type,n.$containerIndex=t.$containerIndex,n.$containerProperty=t.$containerProperty,t.$cstNode&&(n.$cstNode=e.cstNodes.get(t.$cstNode));for(const[r,i]of Object.entries(t))if(!r.startsWith("$"))if(Array.isArray(i)){const t=[];n[r]=t;for(const a of i)(0,gn.xA)(a)?t.push(this.setParent(this.hydrateAstNode(a,e),n)):(0,gn.Yk)(a)?t.push(this.hydrateReference(a,n,r,e)):t.push(a)}else(0,gn.xA)(i)?n[r]=this.setParent(this.hydrateAstNode(i,e),n):(0,gn.Yk)(i)?n[r]=this.hydrateReference(i,n,r,e):void 0!==i&&(n[r]=i);return n}setParent(t,e){return t.$container=e,t}hydrateReference(t,e,n,r){return this.linker.buildReference(e,n,r.cstNodes.get(t.$refNode),t.$refText)}hydrateCstNode(t,e,n=0){const r=e.cstNodes.get(t);if("number"==typeof t.grammarSource&&(r.grammarSource=this.getGrammarElement(t.grammarSource)),r.astNode=e.astNodes.get(t.astNode),(0,gn.al)(r))for(const i of t.content){const t=this.hydrateCstNode(i,e,n++);r.content.push(t)}return r}hydrateCstLeafNode(t){const e=this.getTokenType(t.tokenType),n=t.offset,r=t.length,i=t.startLine,a=t.startColumn,s=t.endLine,o=t.endColumn,l=t.hidden;return new We(n,r,{start:{line:i,character:a},end:{line:s,character:o}},e,l)}getTokenType(t){return this.lexer.definition[t]}getGrammarElementId(t){if(t)return 0===this.grammarElementIdMap.size&&this.createGrammarElementIdMap(),this.grammarElementIdMap.get(t)}getGrammarElement(t){return 0===this.grammarElementIdMap.size&&this.createGrammarElementIdMap(),this.grammarElementIdMap.getKey(t)}createGrammarElementIdMap(){let t=0;for(const e of(0,Pe.Zc)(this.grammar))(0,s.zJ)(e)&&this.grammarElementIdMap.set(e,t++)}}function Zr(t){return{documentation:{CommentProvider:t=>new Br(t),DocumentationProvider:t=>new $r(t)},parser:{AsyncParser:t=>new Fr(t),GrammarConfig:t=>function(t){const e=[],n=t.Grammar;for(const t of n.rules)(0,s.MS)(t)&&(0,i.md)(t)&&(0,a.Rn)((0,i.s1)(t))&&e.push(t.name);return{multilineCommentRules:e,nameRegexp:r.uz}}(t),LangiumParser:t=>function(t){const e=function(t){const e=t.Grammar,n=t.parser.Lexer;return nn(e,new je(t),n.definition)}(t);return e.finalize(),e}(t),CompletionParser:t=>function(t){const e=t.Grammar,n=t.parser.Lexer,r=new Ke(t);return nn(e,r,n.definition),r.finalize(),r}(t),ValueConverter:()=>new dn.t,TokenBuilder:()=>new un.P,Lexer:t=>new gr(t),ParserErrorMessageProvider:()=>new Xe,LexerErrorMessageProvider:()=>new dr},workspace:{AstNodeLocator:()=>new ar,AstNodeDescriptionProvider:t=>new rr(t),ReferenceDescriptionProvider:t=>new ir(t)},references:{Linker:t=>new In(t),NameProvider:()=>new Rn,ScopeProvider:t=>new qn(t),ScopeComputation:t=>new Wn(t),References:t=>new $n(t)},serializer:{Hydrator:t=>new zr(t),JsonSerializer:t=>new Hn(t)},validation:{DocumentValidator:t=>new Jn(t),ValidationRegistry:t=>new Qn(t)},shared:()=>t.shared}}function Yr(t){return{ServiceRegistry:t=>new Xn(t),workspace:{LangiumDocuments:t=>new Mn(t),LangiumDocumentFactory:t=>new Ln(t),DocumentBuilder:t=>new cr(t),IndexManager:t=>new hr(t),WorkspaceManager:t=>new ur(t),FileSystemProvider:e=>t.fileSystemProvider(e),WorkspaceLock:()=>new Wr,ConfigurationProvider:t=>new lr(t)}}}},7072:(t,e,n)=>{"use strict";var r;function i(t,e,n,r,i,a,o,l,h){return s([t,e,n,r,i,a,o,l,h].reduce(c,{}))}n.d(e,{f3:()=>i}),function(t){t.merge=(t,e)=>c(c({},t),e)}(r||(r={}));const a=Symbol("isProxy");function s(t,e){const n=new Proxy({},{deleteProperty:()=>!1,set:()=>{throw new Error("Cannot set property on injected service container")},get:(r,i)=>i===a||l(r,i,t,e||n),getOwnPropertyDescriptor:(r,i)=>(l(r,i,t,e||n),Object.getOwnPropertyDescriptor(r,i)),has:(e,n)=>n in t,ownKeys:()=>[...Object.getOwnPropertyNames(t)]});return n}const o=Symbol();function l(t,e,n,r){if(e in t){if(t[e]instanceof Error)throw new Error("Construction failure. Please make sure that your dependencies are constructable.",{cause:t[e]});if(t[e]===o)throw new Error('Cycle detected. Please make "'+String(e)+'" lazy. Visit https://langium.org/docs/reference/configuration-services/#resolving-cyclic-dependencies');return t[e]}if(e in n){const i=n[e];t[e]=o;try{t[e]="function"==typeof i?i(r):s(i,r)}catch(n){throw t[e]=n instanceof Error?n:void 0,n}return t[e]}}function c(t,e){if(e)for(const[n,r]of Object.entries(e))if(void 0!==r){const e=t[n];t[n]=null!==e&&null!==r&&"object"==typeof e&&"object"==typeof r?c(e,r):r}return t}},3437:(t,e,n)=>{"use strict";n.d(e,{B7:()=>K,Bf:()=>J,Bi:()=>ct,F8:()=>v,F9:()=>R,Ii:()=>C,Iy:()=>B,Ki:()=>et,L:()=>g,LG:()=>q,MS:()=>z,MZ:()=>H,Mp:()=>P,OG:()=>Tt,P9:()=>Y,QV:()=>_,SV:()=>St,S_:()=>k,Sg:()=>ut,TB:()=>m,V7:()=>ft,W1:()=>wt,X9:()=>yt,gf:()=>xt,p1:()=>ot,qm:()=>Et,rT:()=>rt,t3:()=>pt,ty:()=>at,yW:()=>N,zJ:()=>h});var r=n(28);const i="AbstractRule",a="AbstractType",s="Condition",o="TypeDefinition",l="ValueLiteral",c="AbstractElement";function h(t){return Ct.isInstance(t,c)}const u="ArrayLiteral",d="ArrayType",p="BooleanLiteral";function g(t){return Ct.isInstance(t,p)}const f="Conjunction";function m(t){return Ct.isInstance(t,f)}const y="Disjunction";function v(t){return Ct.isInstance(t,y)}const x="Grammar",b="GrammarImport",w="InferredType";function k(t){return Ct.isInstance(t,w)}const T="Interface";function _(t){return Ct.isInstance(t,T)}const E="NamedArgument",S="Negation";function C(t){return Ct.isInstance(t,S)}const A="NumberLiteral",L="Parameter",M="ParameterReference";function N(t){return Ct.isInstance(t,M)}const I="ParserRule";function R(t){return Ct.isInstance(t,I)}const D="ReferenceType",O="ReturnType";function P(t){return Ct.isInstance(t,O)}const $="SimpleType";function B(t){return Ct.isInstance(t,$)}const F="StringLiteral",W="TerminalRule";function z(t){return Ct.isInstance(t,W)}const Z="Type";function Y(t){return Ct.isInstance(t,Z)}const U="TypeAttribute",G="UnionType",V="Action";function q(t){return Ct.isInstance(t,V)}const j="Alternatives";function H(t){return Ct.isInstance(t,j)}const X="Assignment";function K(t){return Ct.isInstance(t,X)}const Q="CharacterRange";function J(t){return Ct.isInstance(t,Q)}const tt="CrossReference";function et(t){return Ct.isInstance(t,tt)}const nt="EndOfFile";function rt(t){return Ct.isInstance(t,nt)}const it="Group";function at(t){return Ct.isInstance(t,it)}const st="Keyword";function ot(t){return Ct.isInstance(t,st)}const lt="NegatedToken";function ct(t){return Ct.isInstance(t,lt)}const ht="RegexToken";function ut(t){return Ct.isInstance(t,ht)}const dt="RuleCall";function pt(t){return Ct.isInstance(t,dt)}const gt="TerminalAlternatives";function ft(t){return Ct.isInstance(t,gt)}const mt="TerminalGroup";function yt(t){return Ct.isInstance(t,mt)}const vt="TerminalRuleCall";function xt(t){return Ct.isInstance(t,vt)}const bt="UnorderedGroup";function wt(t){return Ct.isInstance(t,bt)}const kt="UntilToken";function Tt(t){return Ct.isInstance(t,kt)}const _t="Wildcard";function Et(t){return Ct.isInstance(t,_t)}class St extends r.$v{getAllTypes(){return[c,i,a,V,j,u,d,X,p,Q,s,f,tt,y,nt,x,b,it,w,T,st,E,lt,S,A,L,M,I,D,ht,O,dt,$,F,gt,mt,W,vt,Z,U,o,G,bt,kt,l,_t]}computeIsSubtype(t,e){switch(t){case V:case j:case X:case Q:case tt:case nt:case it:case st:case lt:case ht:case dt:case gt:case mt:case vt:case bt:case kt:case _t:return this.isSubtype(c,e);case u:case A:case F:return this.isSubtype(l,e);case d:case D:case $:case G:return this.isSubtype(o,e);case p:return this.isSubtype(s,e)||this.isSubtype(l,e);case f:case y:case S:case M:return this.isSubtype(s,e);case w:case T:case Z:return this.isSubtype(a,e);case I:return this.isSubtype(i,e)||this.isSubtype(a,e);case W:return this.isSubtype(i,e);default:return!1}}getReferenceType(t){const e=`${t.container.$type}:${t.property}`;switch(e){case"Action:type":case"CrossReference:type":case"Interface:superTypes":case"ParserRule:returnType":case"SimpleType:typeRef":return a;case"Grammar:hiddenTokens":case"ParserRule:hiddenTokens":case"RuleCall:rule":return i;case"Grammar:usedGrammars":return x;case"NamedArgument:parameter":case"ParameterReference:parameter":return L;case"TerminalRuleCall:rule":return W;default:throw new Error(`${e} is not a valid reference id.`)}}getTypeMetaData(t){switch(t){case c:return{name:c,properties:[{name:"cardinality"},{name:"lookahead"}]};case u:return{name:u,properties:[{name:"elements",defaultValue:[]}]};case d:return{name:d,properties:[{name:"elementType"}]};case p:return{name:p,properties:[{name:"true",defaultValue:!1}]};case f:return{name:f,properties:[{name:"left"},{name:"right"}]};case y:return{name:y,properties:[{name:"left"},{name:"right"}]};case x:return{name:x,properties:[{name:"definesHiddenTokens",defaultValue:!1},{name:"hiddenTokens",defaultValue:[]},{name:"imports",defaultValue:[]},{name:"interfaces",defaultValue:[]},{name:"isDeclared",defaultValue:!1},{name:"name"},{name:"rules",defaultValue:[]},{name:"types",defaultValue:[]},{name:"usedGrammars",defaultValue:[]}]};case b:return{name:b,properties:[{name:"path"}]};case w:return{name:w,properties:[{name:"name"}]};case T:return{name:T,properties:[{name:"attributes",defaultValue:[]},{name:"name"},{name:"superTypes",defaultValue:[]}]};case E:return{name:E,properties:[{name:"calledByName",defaultValue:!1},{name:"parameter"},{name:"value"}]};case S:return{name:S,properties:[{name:"value"}]};case A:return{name:A,properties:[{name:"value"}]};case L:return{name:L,properties:[{name:"name"}]};case M:return{name:M,properties:[{name:"parameter"}]};case I:return{name:I,properties:[{name:"dataType"},{name:"definesHiddenTokens",defaultValue:!1},{name:"definition"},{name:"entry",defaultValue:!1},{name:"fragment",defaultValue:!1},{name:"hiddenTokens",defaultValue:[]},{name:"inferredType"},{name:"name"},{name:"parameters",defaultValue:[]},{name:"returnType"},{name:"wildcard",defaultValue:!1}]};case D:return{name:D,properties:[{name:"referenceType"}]};case O:return{name:O,properties:[{name:"name"}]};case $:return{name:$,properties:[{name:"primitiveType"},{name:"stringType"},{name:"typeRef"}]};case F:return{name:F,properties:[{name:"value"}]};case W:return{name:W,properties:[{name:"definition"},{name:"fragment",defaultValue:!1},{name:"hidden",defaultValue:!1},{name:"name"},{name:"type"}]};case Z:return{name:Z,properties:[{name:"name"},{name:"type"}]};case U:return{name:U,properties:[{name:"defaultValue"},{name:"isOptional",defaultValue:!1},{name:"name"},{name:"type"}]};case G:return{name:G,properties:[{name:"types",defaultValue:[]}]};case V:return{name:V,properties:[{name:"cardinality"},{name:"feature"},{name:"inferredType"},{name:"lookahead"},{name:"operator"},{name:"type"}]};case j:return{name:j,properties:[{name:"cardinality"},{name:"elements",defaultValue:[]},{name:"lookahead"}]};case X:return{name:X,properties:[{name:"cardinality"},{name:"feature"},{name:"lookahead"},{name:"operator"},{name:"terminal"}]};case Q:return{name:Q,properties:[{name:"cardinality"},{name:"left"},{name:"lookahead"},{name:"right"}]};case tt:return{name:tt,properties:[{name:"cardinality"},{name:"deprecatedSyntax",defaultValue:!1},{name:"lookahead"},{name:"terminal"},{name:"type"}]};case nt:return{name:nt,properties:[{name:"cardinality"},{name:"lookahead"}]};case it:return{name:it,properties:[{name:"cardinality"},{name:"elements",defaultValue:[]},{name:"guardCondition"},{name:"lookahead"}]};case st:return{name:st,properties:[{name:"cardinality"},{name:"lookahead"},{name:"value"}]};case lt:return{name:lt,properties:[{name:"cardinality"},{name:"lookahead"},{name:"terminal"}]};case ht:return{name:ht,properties:[{name:"cardinality"},{name:"lookahead"},{name:"regex"}]};case dt:return{name:dt,properties:[{name:"arguments",defaultValue:[]},{name:"cardinality"},{name:"lookahead"},{name:"rule"}]};case gt:return{name:gt,properties:[{name:"cardinality"},{name:"elements",defaultValue:[]},{name:"lookahead"}]};case mt:return{name:mt,properties:[{name:"cardinality"},{name:"elements",defaultValue:[]},{name:"lookahead"}]};case vt:return{name:vt,properties:[{name:"cardinality"},{name:"lookahead"},{name:"rule"}]};case bt:return{name:bt,properties:[{name:"cardinality"},{name:"elements",defaultValue:[]},{name:"lookahead"}]};case kt:return{name:kt,properties:[{name:"cardinality"},{name:"lookahead"},{name:"terminal"}]};case _t:return{name:_t,properties:[{name:"cardinality"},{name:"lookahead"}]};default:return{name:t,properties:[]}}}}const Ct=new St},7447:(t,e,n)=>{"use strict";n.d(e,{P:()=>c});var r=n(6435),i=n(3437),a=n(6747),s=n(6097),o=n(2925),l=n(1412);class c{constructor(){this.diagnostics=[]}buildTokens(t,e){const n=(0,l.Vw)((0,s.VD)(t,!1)),r=this.buildTerminalTokens(n),i=this.buildKeywordTokens(n,r,e);return r.forEach((t=>{const e=t.PATTERN;"object"==typeof e&&e&&"test"in e&&(0,o.cb)(e)?i.unshift(t):i.push(t)})),i}flushLexingReport(t){return{diagnostics:this.popDiagnostics()}}popDiagnostics(){const t=[...this.diagnostics];return this.diagnostics=[],t}buildTerminalTokens(t){return t.filter(i.MS).filter((t=>!t.fragment)).map((t=>this.buildTerminalToken(t))).toArray()}buildTerminalToken(t){const e=(0,s.s1)(t),n=this.requiresCustomPattern(e)?this.regexPatternFunction(e):e,i={name:t.name,PATTERN:n};return"function"==typeof n&&(i.LINE_BREAKS=!0),t.hidden&&(i.GROUP=(0,o.cb)(e)?r.hW.SKIPPED:"hidden"),i}requiresCustomPattern(t){return!!(t.flags.includes("u")||t.flags.includes("s")||t.source.includes("?<=")||t.source.includes("?(e.lastIndex=n,e.exec(t))}buildKeywordTokens(t,e,n){return t.filter(i.F9).flatMap((t=>(0,a.VY)(t).filter(i.p1))).distinct((t=>t.value)).toArray().sort(((t,e)=>e.value.length-t.value.length)).map((t=>this.buildKeywordToken(t,e,Boolean(null==n?void 0:n.caseInsensitive))))}buildKeywordToken(t,e,n){const r=this.buildKeywordPattern(t,n),i={name:t.value,PATTERN:r,LONGER_ALT:this.findLongerAlt(t,e)};return"function"==typeof r&&(i.LINE_BREAKS=!0),i}buildKeywordPattern(t,e){return e?new RegExp((0,o.cp)(t.value)):t.value}findLongerAlt(t,e){return e.reduce(((e,n)=>{const r=null==n?void 0:n.PATTERN;return(null==r?void 0:r.source)&&(0,o.XC)("^"+r.source+"$",t.value)&&e.push(n),e}),[])}}},1930:(t,e,n)=>{"use strict";n.d(e,{t:()=>s});var r,i=n(3437),a=n(6097);class s{convert(t,e){let n=e.grammarSource;if((0,i.Ki)(n)&&(n=(0,a.eN)(n)),(0,i.t3)(n)){const r=n.rule.ref;if(!r)throw new Error("This cst node was not parsed by a rule.");return this.runConverter(r,t,e)}return t}runConverter(t,e,n){var i;switch(t.name.toUpperCase()){case"INT":return r.convertInt(e);case"STRING":return r.convertString(e);case"ID":return r.convertID(e)}switch(null===(i=(0,a.mJ)(t))||void 0===i?void 0:i.toLowerCase()){case"number":return r.convertNumber(e);case"boolean":return r.convertBoolean(e);case"bigint":return r.convertBigint(e);case"date":return r.convertDate(e);default:return e}}}!function(t){function e(t){switch(t){case"b":return"\b";case"f":return"\f";case"n":return"\n";case"r":return"\r";case"t":return"\t";case"v":return"\v";case"0":return"\0";default:return t}}t.convertString=function(t){let n="";for(let r=1;r{"use strict";function r(t){return"object"==typeof t&&null!==t&&"string"==typeof t.$type}function i(t){return"object"==typeof t&&null!==t&&"string"==typeof t.$refText}function a(t){return"object"==typeof t&&null!==t&&"string"==typeof t.name&&"string"==typeof t.type&&"string"==typeof t.path}function s(t){return"object"==typeof t&&null!==t&&r(t.container)&&i(t.reference)&&"string"==typeof t.message}n.d(e,{$v:()=>o,SI:()=>a,U8:()=>h,Yk:()=>i,al:()=>l,dm:()=>c,et:()=>s,xA:()=>r});class o{constructor(){this.subtypes={},this.allSubtypes={}}isInstance(t,e){return r(t)&&this.isSubtype(t.$type,e)}isSubtype(t,e){if(t===e)return!0;let n=this.subtypes[t];n||(n=this.subtypes[t]={});const r=n[e];if(void 0!==r)return r;{const r=this.computeIsSubtype(t,e);return n[e]=r,r}}getAllSubTypes(t){const e=this.allSubtypes[t];if(e)return e;{const e=this.getAllTypes(),n=[];for(const r of e)this.isSubtype(r,t)&&n.push(r);return this.allSubtypes[t]=n,n}}}function l(t){return"object"==typeof t&&null!==t&&Array.isArray(t.content)}function c(t){return"object"==typeof t&&null!==t&&"object"==typeof t.tokenType}function h(t){return l(t)&&"string"==typeof t.fullText}},6747:(t,e,n)=>{"use strict";n.d(e,{E$:()=>c,Me:()=>l,VY:()=>u,V_:()=>o,Zc:()=>d,a1:()=>f,b2:()=>s,fy:()=>g,sx:()=>h});var r=n(28),i=n(1412),a=n(2855);function s(t){for(const[e,n]of Object.entries(t))e.startsWith("$")||(Array.isArray(n)?n.forEach(((n,i)=>{(0,r.xA)(n)&&(n.$container=t,n.$containerProperty=e,n.$containerIndex=i)})):(0,r.xA)(n)&&(n.$container=t,n.$containerProperty=e))}function o(t,e){let n=t;for(;n;){if(e(n))return n;n=n.$container}}function l(t){const e=c(t).$document;if(!e)throw new Error("AST node has no document.");return e}function c(t){for(;t.$container;)t=t.$container;return t}function h(t,e){if(!t)throw new Error("Node must be an AstNode.");const n=null==e?void 0:e.range;return new i.i((()=>({keys:Object.keys(t),keyIndex:0,arrayIndex:0})),(e=>{for(;e.keyIndexh(t,e)))}function d(t,e){if(!t)throw new Error("Root node must be an AstNode.");return(null==e?void 0:e.range)&&!p(t,e.range)?new i.i8(t,(()=>[])):new i.i8(t,(t=>h(t,e)),{includeRoot:!0})}function p(t,e){var n;if(!e)return!0;const r=null===(n=t.$cstNode)||void 0===n?void 0:n.range;return!!r&&(0,a.Z2)(r,e)}function g(t){return new i.i((()=>({keys:Object.keys(t),keyIndex:0,arrayIndex:0})),(e=>{for(;e.keyIndex{"use strict";n.d(e,{LK:()=>d,OB:()=>o,Z2:()=>h,_t:()=>s,sp:()=>l,uz:()=>u,yn:()=>c});var r,i=n(28),a=n(1412);function s(t){return new a.i8(t,(t=>(0,i.al)(t)?t.content:[]),{includeRoot:!0})}function o(t,e){for(;t.container;)if((t=t.container)===e)return!0;return!1}function l(t){return{start:{character:t.startColumn-1,line:t.startLine-1},end:{character:t.endColumn,line:t.endLine-1}}}function c(t){if(!t)return;const{offset:e,end:n,range:r}=t;return{range:r,offset:e,end:n,length:n-e}}function h(t,e){const n=function(t,e){if(t.end.linee.end.line||t.start.line===e.end.line&&t.start.character>=e.end.character)return r.After;const n=t.start.line>e.start.line||t.start.line===e.start.line&&t.start.character>=e.start.character,i=t.end.liner.After}!function(t){t[t.Before=0]="Before",t[t.After=1]="After",t[t.OverlapFront=2]="OverlapFront",t[t.OverlapBack=3]="OverlapBack",t[t.Inside=4]="Inside",t[t.Outside=5]="Outside"}(r||(r={}));const u=/^[\w\p{L}]$/u;function d(t,e){if(t){const n=function(t,e=!0){for(;t.container;){const n=t.container;let r=n.content.indexOf(t);for(;r>0;){r--;const t=n.content[r];if(e||!t.hidden)return t}t=n}}(t,!0);if(n&&p(n,e))return n;if((0,i.U8)(t))for(let n=t.content.findIndex((t=>!t.hidden))-1;n>=0;n--){const r=t.content[n];if(p(r,e))return r}}}function p(t,e){return(0,i.dm)(t)&&e.includes(t.tokenType.name)}},9267:(t,e,n)=>{"use strict";n.d(e,{U:()=>i,h:()=>r});class r extends Error{constructor(t,e){super(t?`${e} at ${t.range.start.line}:${t.range.start.character}`:e)}}function i(t){throw new Error("Error! The input value was not handled.")}},6097:(t,e,n)=>{"use strict";n.d(e,{$G:()=>k,EL:()=>p,UP:()=>b,VD:()=>c,eN:()=>u,h7:()=>y,ib:()=>v,lA:()=>m,mJ:()=>_,md:()=>d,s1:()=>E,vb:()=>g,z$:()=>T});var r=n(9267),i=n(3437),a=n(28),s=n(6747),o=n(2855),l=n(2925);function c(t,e){const n=new Set,r=function(t){return t.rules.find((t=>i.F9(t)&&t.entry))}(t);if(!r)return new Set(t.rules);const a=[r].concat(function(t){return t.rules.filter((t=>i.MS(t)&&t.hidden))}(t));for(const t of a)h(t,n,e);const s=new Set;for(const e of t.rules)(n.has(e.name)||i.MS(e)&&e.hidden)&&s.add(e);return s}function h(t,e,n){e.add(t.name),(0,s.VY)(t).forEach((t=>{if(i.t3(t)||n&&i.gf(t)){const r=t.rule.ref;r&&!e.has(r.name)&&h(r,e,n)}}))}function u(t){if(t.terminal)return t.terminal;if(t.type.ref){const e=v(t.type.ref);return null==e?void 0:e.terminal}}function d(t){return t.hidden&&!(0,l.cb)(E(t))}function p(t,e){return t&&e?f(t,e,t.astNode,!0):[]}function g(t,e,n){if(!t||!e)return;const r=f(t,e,t.astNode,!0);return 0!==r.length?r[n=void 0!==n?Math.max(0,Math.min(n,r.length-1)):0]:void 0}function f(t,e,n,r){if(!r){const n=(0,s.V_)(t.grammarSource,i.B7);if(n&&n.feature===e)return[t]}return(0,a.al)(t)&&t.astNode===n?t.content.flatMap((t=>f(t,e,n,!1))):[]}function m(t,e,n){if(!t)return;const r=function(t,e,n){if(t.astNode!==n)return[];if(i.p1(t.grammarSource)&&t.grammarSource.value===e)return[t];const r=(0,o._t)(t).iterator();let a;const s=[];do{if(a=r.next(),!a.done){const t=a.value;t.astNode===n?i.p1(t.grammarSource)&&t.grammarSource.value===e&&s.push(t):r.prune()}}while(!a.done);return s}(t,e,null==t?void 0:t.astNode);return 0!==r.length?r[n=void 0!==n?Math.max(0,Math.min(n,r.length-1)):0]:void 0}function y(t){var e;const n=t.astNode;for(;n===(null===(e=t.container)||void 0===e?void 0:e.astNode);){const e=(0,s.V_)(t.grammarSource,i.B7);if(e)return e;t=t.container}}function v(t){let e=t;return i.S_(e)&&(i.LG(e.$container)?e=e.$container.$container:i.F9(e.$container)?e=e.$container:(0,r.U)(e.$container)),x(t,e,new Map)}function x(t,e,n){var r;function a(e,r){let a;return(0,s.V_)(e,i.B7)||(a=x(r,r,n)),n.set(t,a),a}if(n.has(t))return n.get(t);n.set(t,void 0);for(const o of(0,s.VY)(e)){if(i.B7(o)&&"name"===o.feature.toLowerCase())return n.set(t,o),o;if(i.t3(o)&&i.F9(o.rule.ref))return a(o,o.rule.ref);if(i.Iy(o)&&(null===(r=o.typeRef)||void 0===r?void 0:r.ref))return a(o,o.typeRef.ref)}}function b(t){return w(t,new Set)}function w(t,e){if(e.has(t))return!0;e.add(t);for(const n of(0,s.VY)(t))if(i.t3(n)){if(!n.rule.ref)return!1;if(i.F9(n.rule.ref)&&!w(n.rule.ref,e))return!1}else{if(i.B7(n))return!1;if(i.LG(n))return!1}return Boolean(t.definition)}function k(t){if(t.inferredType)return t.inferredType.name;if(t.dataType)return t.dataType;if(t.returnType){const e=t.returnType.ref;if(e){if(i.F9(e))return e.name;if(i.QV(e)||i.P9(e))return e.name}}}function T(t){var e;if(i.F9(t))return b(t)?t.name:null!==(e=k(t))&&void 0!==e?e:t.name;if(i.QV(t)||i.P9(t)||i.Mp(t))return t.name;if(i.LG(t)){const e=function(t){var e;return t.inferredType?t.inferredType.name:(null===(e=t.type)||void 0===e?void 0:e.ref)?T(t.type.ref):void 0}(t);if(e)return e}else if(i.S_(t))return t.name;throw new Error("Cannot get name of Unknown Type")}function _(t){var e,n,r;return i.MS(t)?null!==(n=null===(e=t.type)||void 0===e?void 0:e.name)&&void 0!==n?n:"string":null!==(r=k(t))&&void 0!==r?r:t.name}function E(t){const e={s:!1,i:!1,u:!1},n=C(t.definition,e),r=Object.entries(e).filter((([,t])=>t)).map((([t])=>t)).join("");return new RegExp(n,r)}const S=/[\s\S]/.source;function C(t,e){if(i.V7(t))return L((o=t).elements.map((t=>C(t))).join("|"),{cardinality:o.cardinality,lookahead:o.lookahead});if(i.X9(t))return L((s=t).elements.map((t=>C(t))).join(""),{cardinality:s.cardinality,lookahead:s.lookahead});if(i.Bf(t))return(n=t).right?L(`[${A(n.left)}-${A(n.right)}]`,{cardinality:n.cardinality,lookahead:n.lookahead,wrap:!1}):L(A(n.left),{cardinality:n.cardinality,lookahead:n.lookahead,wrap:!1});var n,r,a,s,o;if(i.gf(t)){const e=t.rule.ref;if(!e)throw new Error("Missing rule reference.");return L(C(e.definition),{cardinality:t.cardinality,lookahead:t.lookahead})}if(i.Bi(t))return L(`(?!${C((a=t).terminal)})${S}*?`,{cardinality:a.cardinality,lookahead:a.lookahead});if(i.OG(t))return L(`${S}*?${C((r=t).terminal)}`,{cardinality:r.cardinality,lookahead:r.lookahead});if(i.Sg(t)){const n=t.regex.lastIndexOf("/"),r=t.regex.substring(1,n),i=t.regex.substring(n+1);return e&&(e.i=i.includes("i"),e.s=i.includes("s"),e.u=i.includes("u")),L(r,{cardinality:t.cardinality,lookahead:t.lookahead,wrap:!1})}if(i.qm(t))return L(S,{cardinality:t.cardinality,lookahead:t.lookahead});throw new Error(`Invalid terminal element: ${null==t?void 0:t.$type}`)}function A(t){return(0,l.hr)(t.value)}function L(t,e){var n;return(!1!==e.wrap||e.lookahead)&&(t=`(${null!==(n=e.lookahead)&&void 0!==n?n:""}${t})`),e.cardinality?`${t}${e.cardinality}`:t}},2925:(t,e,n)=>{"use strict";n.d(e,{K0:()=>i,Rn:()=>l,XC:()=>p,cb:()=>h,cp:()=>d,hr:()=>u});var r=n(5055);const i=/\r?\n/gm,a=new r.O;class s extends r.e{constructor(){super(...arguments),this.isStarting=!0,this.endRegexpStack=[],this.multiline=!1}get endRegex(){return this.endRegexpStack.join("")}reset(t){this.multiline=!1,this.regex=t,this.startRegexp="",this.isStarting=!0,this.endRegexpStack=[]}visitGroup(t){t.quantifier&&(this.isStarting=!1,this.endRegexpStack=[])}visitCharacter(t){const e=String.fromCharCode(t.value);if(this.multiline||"\n"!==e||(this.multiline=!0),t.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{const t=u(e);this.endRegexpStack.push(t),this.isStarting&&(this.startRegexp+=t)}}visitSet(t){if(!this.multiline){const e=this.regex.substring(t.loc.begin,t.loc.end),n=new RegExp(e);this.multiline=Boolean("\n".match(n))}if(t.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{const e=this.regex.substring(t.loc.begin,t.loc.end);this.endRegexpStack.push(e),this.isStarting&&(this.startRegexp+=e)}}visitChildren(t){"Group"===t.type&&t.quantifier||super.visitChildren(t)}}const o=new s;function l(t){try{return"string"==typeof t&&(t=new RegExp(t)),t=t.toString(),o.reset(t),o.visit(a.pattern(t)),o.multiline}catch(t){return!1}}const c="\f\n\r\t\v              \u2028\u2029   \ufeff".split("");function h(t){const e="string"==typeof t?new RegExp(t):t;return c.some((t=>e.test(t)))}function u(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function d(t){return Array.prototype.map.call(t,(t=>/\w/.test(t)?`[${t.toLowerCase()}${t.toUpperCase()}]`:u(t))).join("")}function p(t,e){const n=function(t){"string"==typeof t&&(t=new RegExp(t));const e=t,n=t.source;let r=0;return new RegExp(function t(){let i,a="";function s(t){a+=n.substr(r,t),r+=t}function o(t){a+="(?:"+n.substr(r,t)+"|$)",r+=t}for(;r",r)-r+1);break;default:o(2)}break;case"[":i=/\[(?:\\.|.)*?\]/g,i.lastIndex=r,i=i.exec(n)||[],o(i[0].length);break;case"|":case"^":case"$":case"*":case"+":case"?":s(1);break;case"{":i=/\{\d+,?\d*\}/g,i.lastIndex=r,i=i.exec(n),i?s(i[0].length):o(1);break;case"(":if("?"===n[r+1])switch(n[r+2]){case":":a+="(?:",r+=3,a+=t()+"|$)";break;case"=":a+="(?=",r+=3,a+=t()+")";break;case"!":i=r,r+=3,t(),a+=n.substr(i,r-i);break;case"<":switch(n[r+3]){case"=":case"!":i=r,r+=4,t(),a+=n.substr(i,r-i);break;default:s(n.indexOf(">",r)-r+1),a+=t()+"|$)"}}else s(1),a+=t()+"|$)";break;case")":return++r,a;default:o(1)}return a}(),t.flags)}(t),r=e.match(n);return!!r&&r[0].length>0}},1412:(t,e,n)=>{"use strict";n.d(e,{Cl:()=>a,IH:()=>c,Ry:()=>s,Vw:()=>o,i:()=>r,i8:()=>l});class r{constructor(t,e){this.startFn=t,this.nextFn=e}iterator(){const t={state:this.startFn(),next:()=>this.nextFn(t.state),[Symbol.iterator]:()=>t};return t}[Symbol.iterator](){return this.iterator()}isEmpty(){const t=this.iterator();return Boolean(t.next().done)}count(){const t=this.iterator();let e=0,n=t.next();for(;!n.done;)e++,n=t.next();return e}toArray(){const t=[],e=this.iterator();let n;do{n=e.next(),void 0!==n.value&&t.push(n.value)}while(!n.done);return t}toSet(){return new Set(this)}toMap(t,e){const n=this.map((n=>[t?t(n):n,e?e(n):n]));return new Map(n)}toString(){return this.join()}concat(t){return new r((()=>({first:this.startFn(),firstDone:!1,iterator:t[Symbol.iterator]()})),(t=>{let e;if(!t.firstDone){do{if(e=this.nextFn(t.first),!e.done)return e}while(!e.done);t.firstDone=!0}do{if(e=t.iterator.next(),!e.done)return e}while(!e.done);return s}))}join(t=","){const e=this.iterator();let n,r="",i=!1;do{n=e.next(),n.done||(i&&(r+=t),r+="string"==typeof(a=n.value)?a:void 0===a?"undefined":"function"==typeof a.toString?a.toString():Object.prototype.toString.call(a)),i=!0}while(!n.done);var a;return r}indexOf(t,e=0){const n=this.iterator();let r=0,i=n.next();for(;!i.done;){if(r>=e&&i.value===t)return r;i=n.next(),r++}return-1}every(t){const e=this.iterator();let n=e.next();for(;!n.done;){if(!t(n.value))return!1;n=e.next()}return!0}some(t){const e=this.iterator();let n=e.next();for(;!n.done;){if(t(n.value))return!0;n=e.next()}return!1}forEach(t){const e=this.iterator();let n=0,r=e.next();for(;!r.done;)t(r.value,n),r=e.next(),n++}map(t){return new r(this.startFn,(e=>{const{done:n,value:r}=this.nextFn(e);return n?s:{done:!1,value:t(r)}}))}filter(t){return new r(this.startFn,(e=>{let n;do{if(n=this.nextFn(e),!n.done&&t(n.value))return n}while(!n.done);return s}))}nonNullable(){return this.filter((t=>null!=t))}reduce(t,e){const n=this.iterator();let r=e,i=n.next();for(;!i.done;)r=void 0===r?i.value:t(r,i.value),i=n.next();return r}reduceRight(t,e){return this.recursiveReduce(this.iterator(),t,e)}recursiveReduce(t,e,n){const r=t.next();if(r.done)return n;const i=this.recursiveReduce(t,e,n);return void 0===i?r.value:e(i,r.value)}find(t){const e=this.iterator();let n=e.next();for(;!n.done;){if(t(n.value))return n.value;n=e.next()}}findIndex(t){const e=this.iterator();let n=0,r=e.next();for(;!r.done;){if(t(r.value))return n;r=e.next(),n++}return-1}includes(t){const e=this.iterator();let n=e.next();for(;!n.done;){if(n.value===t)return!0;n=e.next()}return!1}flatMap(t){return new r((()=>({this:this.startFn()})),(e=>{do{if(e.iterator){const t=e.iterator.next();if(!t.done)return t;e.iterator=void 0}const{done:n,value:r}=this.nextFn(e.this);if(!n){const n=t(r);if(!i(n))return{done:!1,value:n};e.iterator=n[Symbol.iterator]()}}while(e.iterator);return s}))}flat(t){if(void 0===t&&(t=1),t<=0)return this;const e=t>1?this.flat(t-1):this;return new r((()=>({this:e.startFn()})),(t=>{do{if(t.iterator){const e=t.iterator.next();if(!e.done)return e;t.iterator=void 0}const{done:n,value:r}=e.nextFn(t.this);if(!n){if(!i(r))return{done:!1,value:r};t.iterator=r[Symbol.iterator]()}}while(t.iterator);return s}))}head(){const t=this.iterator().next();if(!t.done)return t.value}tail(t=1){return new r((()=>{const e=this.startFn();for(let n=0;n({size:0,state:this.startFn()})),(e=>(e.size++,e.size>t?s:this.nextFn(e.state))))}distinct(t){return new r((()=>({set:new Set,internalState:this.startFn()})),(e=>{let n;do{if(n=this.nextFn(e.internalState),!n.done){const r=t?t(n.value):n.value;if(!e.set.has(r))return e.set.add(r),n}}while(!n.done);return s}))}exclude(t,e){const n=new Set;for(const r of t){const t=e?e(r):r;n.add(t)}return this.filter((t=>{const r=e?e(t):t;return!n.has(r)}))}}function i(t){return!!t&&"function"==typeof t[Symbol.iterator]}const a=new r((()=>{}),(()=>s)),s=Object.freeze({done:!0,value:void 0});function o(...t){if(1===t.length){const e=t[0];if(e instanceof r)return e;if(i(e))return new r((()=>e[Symbol.iterator]()),(t=>t.next()));if("number"==typeof e.length)return new r((()=>({index:0})),(t=>t.index1?new r((()=>({collIndex:0,arrIndex:0})),(e=>{do{if(e.iterator){const t=e.iterator.next();if(!t.done)return t;e.iterator=void 0}if(e.array){if(e.arrIndex({iterators:(null==n?void 0:n.includeRoot)?[[t][Symbol.iterator]()]:[e(t)[Symbol.iterator]()],pruned:!1})),(t=>{for(t.pruned&&(t.iterators.pop(),t.pruned=!1);t.iterators.length>0;){const n=t.iterators[t.iterators.length-1].next();if(!n.done)return t.iterators.push(e(n.value)[Symbol.iterator]()),n;t.iterators.pop()}return s}))}iterator(){const t={state:this.startFn(),next:()=>this.nextFn(t.state),prune:()=>{t.state.pruned=!0},[Symbol.iterator]:()=>t};return t}}var c;!function(t){t.sum=function(t){return t.reduce(((t,e)=>t+e),0)},t.product=function(t){return t.reduce(((t,e)=>t*e),0)},t.min=function(t){return t.reduce(((t,e)=>Math.min(t,e)))},t.max=function(t){return t.reduce(((t,e)=>Math.max(t,e)))}}(c||(c={}))},5565:(t,e,n)=>{"use strict";n.d(e,{u:()=>i});class r{readFile(){throw new Error("No file system is available.")}async readDirectory(){return[]}}const i={fileSystemProvider:()=>new r}},2536:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(9651);const i=function(t,e){for(var n=t.length;n--;)if((0,r.Z)(t[n][0],e))return n;return-1};var a=Array.prototype.splice;function s(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1},s.prototype.set=function(t,e){var n=this.__data__,r=i(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};const o=s},6183:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(2119),i=n(6092);const a=(0,r.Z)(i.Z,"Map")},520:(t,e,n)=>{"use strict";n.d(e,{Z:()=>d});const r=(0,n(2119).Z)(Object,"create");var i=Object.prototype.hasOwnProperty;var a=Object.prototype.hasOwnProperty;function s(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e{"use strict";n.d(e,{Z:()=>a});var r=n(2119),i=n(6092);const a=(0,r.Z)(i.Z,"Set")},5084:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(520);function i(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new r.Z;++e{"use strict";n.d(e,{Z:()=>o});var r=n(2536);var i=n(6183),a=n(520);function s(t){var e=this.__data__=new r.Z(t);this.size=e.size}s.prototype.clear=function(){this.__data__=new r.Z,this.size=0},s.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},s.prototype.get=function(t){return this.__data__.get(t)},s.prototype.has=function(t){return this.__data__.has(t)},s.prototype.set=function(t,e){var n=this.__data__;if(n instanceof r.Z){var s=n.__data__;if(!i.Z||s.length<199)return s.push([t,e]),this.size=++n.size,this;n=this.__data__=new a.Z(s)}return n.set(t,e),this.size=n.size,this};const o=s},7685:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=n(6092).Z.Symbol},4073:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=n(6092).Z.Uint8Array},6579:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){for(var n=-1,r=null==t?0:t.length;++n{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){for(var n=-1,r=null==t?0:t.length,i=0,a=[];++n{"use strict";n.d(e,{Z:()=>i});var r=n(3152);const i=function(t,e){return!(null==t||!t.length)&&(0,r.Z)(t,e,0)>-1}},2783:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t,e,n){for(var r=-1,i=null==t?0:t.length;++r{"use strict";n.d(e,{Z:()=>c});var r=n(4732),i=n(7771),a=n(6706),s=n(6009),o=n(7212),l=Object.prototype.hasOwnProperty;const c=function(t,e){var n=(0,i.Z)(t),c=!n&&(0,r.Z)(t),h=!n&&!c&&(0,a.Z)(t),u=!n&&!c&&!h&&(0,o.Z)(t),d=n||c||h||u,p=d?function(t,e){for(var n=-1,r=Array(t);++n{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){for(var n=-1,r=e.length,i=t.length;++n{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){for(var n=-1,r=null==t?0:t.length;++n{"use strict";n.d(e,{Z:()=>s});var r=n(4752),i=n(9651),a=Object.prototype.hasOwnProperty;const s=function(t,e,n){var s=t[e];a.call(t,e)&&(0,i.Z)(s,n)&&(void 0!==n||e in t)||(0,r.Z)(t,e,n)}},4752:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(7904);const i=function(t,e,n){"__proto__"==e&&r.Z?(0,r.Z)(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}},9943:(t,e,n)=>{"use strict";n.d(e,{Z:()=>F});var r=n(5365),i=n(6579),a=n(2954),s=n(1899),o=n(7179);var l=n(7590);var c=n(1050),h=n(7215),u=n(5695);var d=n(7502);var p=n(1808),g=n(4403),f=n(6155),m=Object.prototype.hasOwnProperty;var y=n(1884);var v=/\w*$/;var x=n(7685),b=x.Z?x.Z.prototype:void 0,w=b?b.valueOf:void 0;var k=n(2701);const T=function(t,e,n){var r,i,a,s=t.constructor;switch(e){case"[object ArrayBuffer]":return(0,y.Z)(t);case"[object Boolean]":case"[object Date]":return new s(+t);case"[object DataView]":return function(t,e){var n=e?(0,y.Z)(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return(0,k.Z)(t,n);case"[object Map]":case"[object Set]":return new s;case"[object Number]":case"[object String]":return new s(t);case"[object RegExp]":return(a=new(i=t).constructor(i.source,v.exec(i))).lastIndex=i.lastIndex,a;case"[object Symbol]":return r=t,w?Object(w.call(r)):{}}};var _=n(5418),E=n(7771),S=n(6706),C=n(8533);var A=n(1162),L=n(8351),M=L.Z&&L.Z.isMap;const N=M?(0,A.Z)(M):function(t){return(0,C.Z)(t)&&"[object Map]"==(0,f.Z)(t)};var I=n(7226);var R=L.Z&&L.Z.isSet;const D=R?(0,A.Z)(R):function(t){return(0,C.Z)(t)&&"[object Set]"==(0,f.Z)(t)};var O="[object Arguments]",P="[object Function]",$="[object Object]",B={};B[O]=B["[object Array]"]=B["[object ArrayBuffer]"]=B["[object DataView]"]=B["[object Boolean]"]=B["[object Date]"]=B["[object Float32Array]"]=B["[object Float64Array]"]=B["[object Int8Array]"]=B["[object Int16Array]"]=B["[object Int32Array]"]=B["[object Map]"]=B["[object Number]"]=B[$]=B["[object RegExp]"]=B["[object Set]"]=B["[object String]"]=B["[object Symbol]"]=B["[object Uint8Array]"]=B["[object Uint8ClampedArray]"]=B["[object Uint16Array]"]=B["[object Uint32Array]"]=!0,B["[object Error]"]=B[P]=B["[object WeakMap]"]=!1;const F=function t(e,n,y,v,x,b){var w,k=1&n,C=2&n,A=4&n;if(y&&(w=x?y(e,v,x,b):y(e)),void 0!==w)return w;if(!(0,I.Z)(e))return e;var L=(0,E.Z)(e);if(L){if(w=function(t){var e=t.length,n=new t.constructor(e);return e&&"string"==typeof t[0]&&m.call(t,"index")&&(n.index=t.index,n.input=t.input),n}(e),!k)return(0,h.Z)(e,w)}else{var M=(0,f.Z)(e),R=M==P||"[object GeneratorFunction]"==M;if((0,S.Z)(e))return(0,c.Z)(e,k);if(M==$||M==O||R&&!x){if(w=C||R?{}:(0,_.Z)(e),!k)return C?function(t,e){return(0,s.Z)(t,(0,d.Z)(t),e)}(e,function(t,e){return t&&(0,s.Z)(e,(0,l.Z)(e),t)}(w,e)):function(t,e){return(0,s.Z)(t,(0,u.Z)(t),e)}(e,function(t,e){return t&&(0,s.Z)(e,(0,o.Z)(e),t)}(w,e))}else{if(!B[M])return x?e:{};w=T(e,M,k)}}b||(b=new r.Z);var F=b.get(e);if(F)return F;b.set(e,w),D(e)?e.forEach((function(r){w.add(t(r,n,y,r,e,b))})):N(e)&&e.forEach((function(r,i){w.set(i,t(r,n,y,i,e,b))}));var W=A?C?g.Z:p.Z:C?l.Z:o.Z,z=L?void 0:W(e);return(0,i.Z)(z||e,(function(r,i){z&&(r=e[i=r]),(0,a.Z)(w,i,t(r,n,y,i,e,b))})),w}},8640:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(2693),i=n(585);const a=(s=r.Z,function(t,e){if(null==t)return t;if(!(0,i.Z)(t))return s(t,e);for(var n=t.length,r=-1,a=Object(t);++r{"use strict";n.d(e,{Z:()=>i});var r=n(2714);const i=function(t,e,n){for(var i=-1,a=t.length;++i{"use strict";n.d(e,{Z:()=>i});var r=n(8640);const i=function(t,e){var n=[];return(0,r.Z)(t,(function(t,r,i){e(t,r,i)&&n.push(t)})),n}},1692:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t,e,n,r){for(var i=t.length,a=n+(r?1:-1);r?a--:++a{"use strict";n.d(e,{Z:()=>c});var r=n(8694),i=n(7685),a=n(4732),s=n(7771),o=i.Z?i.Z.isConcatSpreadable:void 0;const l=function(t){return(0,s.Z)(t)||(0,a.Z)(t)||!!(o&&t&&t[o])},c=function t(e,n,i,a,s){var o=-1,c=e.length;for(i||(i=l),s||(s=[]);++o0&&i(h)?n>1?t(h,n-1,i,a,s):(0,r.Z)(s,h):a||(s[s.length]=h)}return s}},5381:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t,e,n){for(var r=-1,i=Object(t),a=n(t),s=a.length;s--;){var o=a[++r];if(!1===e(i[o],o,i))break}return t}},2693:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(5381),i=n(7179);const a=function(t,e){return t&&(0,r.Z)(t,e,i.Z)}},3317:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(1036),i=n(2656);const a=function(t,e){for(var n=0,a=(e=(0,r.Z)(e,t)).length;null!=t&&n{"use strict";n.d(e,{Z:()=>a});var r=n(8694),i=n(7771);const a=function(t,e,n){var a=e(t);return(0,i.Z)(t)?a:(0,r.Z)(a,n(t))}},4492:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(7685),i=n(9432),a=n(699),s=r.Z?r.Z.toStringTag:void 0;const o=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":s&&s in Object(t)?(0,i.Z)(t):(0,a.Z)(t)}},3152:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(1692);const i=function(t){return t!=t},a=function(t,e,n){return e==e?function(t,e,n){for(var r=n-1,i=t.length;++r{"use strict";n.d(e,{Z:()=>z});var r=n(5365),i=n(5084),a=n(2338),s=n(9548);const o=function(t,e,n,r,o,l){var c=1&n,h=t.length,u=e.length;if(h!=u&&!(c&&u>h))return!1;var d=l.get(t),p=l.get(e);if(d&&p)return d==e&&p==t;var g=-1,f=!0,m=2&n?new i.Z:void 0;for(l.set(t,e),l.set(e,t);++g{"use strict";n.d(e,{Z:()=>s});var r=n(2764);const i=(0,n(1851).Z)(Object.keys,Object);var a=Object.prototype.hasOwnProperty;const s=function(t){if(!(0,r.Z)(t))return i(t);var e=[];for(var n in Object(t))a.call(t,n)&&"constructor"!=n&&e.push(n);return e}},676:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){return t{"use strict";n.d(e,{Z:()=>a});var r=n(8640),i=n(585);const a=function(t,e){var n=-1,a=(0,i.Z)(t)?Array(t.length):[];return(0,r.Z)(t,(function(t,r,i){a[++n]=e(t,r,i)})),a}},7993:(t,e,n)=>{"use strict";n.d(e,{Z:()=>h});var r=n(3317),i=n(2954),a=n(1036),s=n(6009),o=n(7226),l=n(2656);const c=function(t,e,n,r){if(!(0,o.Z)(t))return t;for(var c=-1,h=(e=(0,a.Z)(e,t)).length,u=h-1,d=t;null!=d&&++c{"use strict";n.d(e,{Z:()=>r});const r=function(t){return function(e){return null==e?void 0:e[t]}}},9581:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=n(9203),i=n(3948),a=n(3626);const s=function(t,e){return(0,a.Z)((0,i.Z)(t,e,r.Z),t+"")}},1162:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){return function(e){return t(e)}}},184:(t,e,n)=>{"use strict";n.d(e,{Z:()=>u});var r=n(5084),i=n(9370),a=n(2783),s=n(9548),o=n(3203),l=n(2054),c=n(6545);const h=o.Z&&1/(0,c.Z)(new o.Z([,-0]))[1]==1/0?function(t){return new o.Z(t)}:l.Z,u=function(t,e,n){var o=-1,l=i.Z,u=t.length,d=!0,p=[],g=p;if(n)d=!1,l=a.Z;else if(u>=200){var f=e?null:h(t);if(f)return(0,c.Z)(f);d=!1,l=s.Z,g=new r.Z}else g=e?[]:p;t:for(;++o{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){return t.has(e)}},8882:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(9203);const i=function(t){return"function"==typeof t?t:r.Z}},1036:(t,e,n)=>{"use strict";n.d(e,{Z:()=>d});var r=n(7771),i=n(9365),a=n(2454),s=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g;const l=(c=(0,a.Z)((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(s,(function(t,n,r,i){e.push(r?i.replace(o,"$1"):n||t)})),e}),(function(t){return 500===h.size&&h.clear(),t})),h=c.cache,c);var c,h,u=n(2402);const d=function(t,e){return(0,r.Z)(t)?t:(0,i.Z)(t,e)?[t]:l((0,u.Z)(t))}},1884:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(4073);const i=function(t){var e=new t.constructor(t.byteLength);return new r.Z(e).set(new r.Z(t)),e}},1050:(t,e,n)=>{"use strict";n.d(e,{Z:()=>l});var r=n(6092),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,a=i&&"object"==typeof module&&module&&!module.nodeType&&module,s=a&&a.exports===i?r.Z.Buffer:void 0,o=s?s.allocUnsafe:void 0;const l=function(t,e){if(e)return t.slice();var n=t.length,r=o?o(n):new t.constructor(n);return t.copy(r),r}},2701:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(1884);const i=function(t,e){var n=e?(0,r.Z)(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}},7215:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n{"use strict";n.d(e,{Z:()=>a});var r=n(2954),i=n(4752);const a=function(t,e,n,a){var s=!n;n||(n={});for(var o=-1,l=e.length;++o{"use strict";n.d(e,{Z:()=>a});var r=n(9581),i=n(439);const a=function(t){return(0,r.Z)((function(e,n){var r=-1,a=n.length,s=a>1?n[a-1]:void 0,o=a>2?n[2]:void 0;for(s=t.length>3&&"function"==typeof s?(a--,s):void 0,o&&(0,i.Z)(n[0],n[1],o)&&(s=a<3?void 0:s,a=1),e=Object(e);++r{"use strict";n.d(e,{Z:()=>i});var r=n(2119);const i=function(){try{var t=(0,r.Z)(Object,"defineProperty");return t({},"",{}),t}catch(t){}}()},3413:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r="object"==typeof global&&global&&global.Object===Object&&global},1808:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=n(3327),i=n(5695),a=n(7179);const s=function(t){return(0,r.Z)(t,a.Z,i.Z)}},4403:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=n(3327),i=n(7502),a=n(7590);const s=function(t){return(0,r.Z)(t,a.Z,i.Z)}},2119:(t,e,n)=>{"use strict";n.d(e,{Z:()=>m});var r=n(3234);const i=n(6092).Z["__core-js_shared__"];var a,s=(a=/[^.]+$/.exec(i&&i.keys&&i.keys.IE_PROTO||""))?"Symbol(src)_1."+a:"";var o=n(7226),l=n(19),c=/^\[object .+?Constructor\]$/,h=Function.prototype,u=Object.prototype,d=h.toString,p=u.hasOwnProperty,g=RegExp("^"+d.call(p).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");const f=function(t){return!(!(0,o.Z)(t)||(e=t,s&&s in e))&&((0,r.Z)(t)?g:c).test((0,l.Z)(t));var e},m=function(t,e){var n=function(t,e){return null==t?void 0:t[e]}(t,e);return f(n)?n:void 0}},2513:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=(0,n(1851).Z)(Object.getPrototypeOf,Object)},9432:(t,e,n)=>{"use strict";n.d(e,{Z:()=>l});var r=n(7685),i=Object.prototype,a=i.hasOwnProperty,s=i.toString,o=r.Z?r.Z.toStringTag:void 0;const l=function(t){var e=a.call(t,o),n=t[o];try{t[o]=void 0;var r=!0}catch(t){}var i=s.call(t);return r&&(e?t[o]=n:delete t[o]),i}},5695:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(8774),i=n(532),a=Object.prototype.propertyIsEnumerable,s=Object.getOwnPropertySymbols;const o=s?function(t){return null==t?[]:(t=Object(t),(0,r.Z)(s(t),(function(e){return a.call(t,e)})))}:i.Z},7502:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(8694),i=n(2513),a=n(5695),s=n(532);const o=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)(0,r.Z)(e,(0,a.Z)(t)),t=(0,i.Z)(t);return e}:s.Z},6155:(t,e,n)=>{"use strict";n.d(e,{Z:()=>T});var r=n(2119),i=n(6092);const a=(0,r.Z)(i.Z,"DataView");var s=n(6183);const o=(0,r.Z)(i.Z,"Promise");var l=n(3203);const c=(0,r.Z)(i.Z,"WeakMap");var h=n(4492),u=n(19),d="[object Map]",p="[object Promise]",g="[object Set]",f="[object WeakMap]",m="[object DataView]",y=(0,u.Z)(a),v=(0,u.Z)(s.Z),x=(0,u.Z)(o),b=(0,u.Z)(l.Z),w=(0,u.Z)(c),k=h.Z;(a&&k(new a(new ArrayBuffer(1)))!=m||s.Z&&k(new s.Z)!=d||o&&k(o.resolve())!=p||l.Z&&k(new l.Z)!=g||c&&k(new c)!=f)&&(k=function(t){var e=(0,h.Z)(t),n="[object Object]"==e?t.constructor:void 0,r=n?(0,u.Z)(n):"";if(r)switch(r){case y:return m;case v:return d;case x:return p;case b:return g;case w:return f}return e});const T=k},5196:(t,e,n)=>{"use strict";n.d(e,{Z:()=>c});var r=n(1036),i=n(4732),a=n(7771),s=n(6009),o=n(1656),l=n(2656);const c=function(t,e,n){for(var c=-1,h=(e=(0,r.Z)(e,t)).length,u=!1;++c{"use strict";n.d(e,{Z:()=>l});var r=n(7226),i=Object.create;const a=function(){function t(){}return function(e){if(!(0,r.Z)(e))return{};if(i)return i(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();var s=n(2513),o=n(2764);const l=function(t){return"function"!=typeof t.constructor||(0,o.Z)(t)?{}:a((0,s.Z)(t))}},6009:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=/^(?:0|[1-9]\d*)$/;const i=function(t,e){var n=typeof t;return!!(e=null==e?9007199254740991:e)&&("number"==n||"symbol"!=n&&r.test(t))&&t>-1&&t%1==0&&t{"use strict";n.d(e,{Z:()=>o});var r=n(9651),i=n(585),a=n(6009),s=n(7226);const o=function(t,e,n){if(!(0,s.Z)(n))return!1;var o=typeof e;return!!("number"==o?(0,i.Z)(n)&&(0,a.Z)(e,n.length):"string"==o&&e in n)&&(0,r.Z)(n[e],t)}},9365:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(7771),i=n(2714),a=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,s=/^\w*$/;const o=function(t,e){if((0,r.Z)(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!(0,i.Z)(t))||s.test(t)||!a.test(t)||null!=e&&t in Object(e)}},2764:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=Object.prototype;const i=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||r)}},8351:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(3413),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,a=i&&"object"==typeof module&&module&&!module.nodeType&&module,s=a&&a.exports===i&&r.Z.process;const o=function(){try{return a&&a.require&&a.require("util").types||s&&s.binding&&s.binding("util")}catch(t){}}()},699:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=Object.prototype.toString;const i=function(t){return r.call(t)}},1851:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){return function(n){return t(e(n))}}},3948:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=Math.max;const i=function(t,e,n){return e=r(void 0===e?t.length-1:e,0),function(){for(var i=arguments,a=-1,s=r(i.length-e,0),o=Array(s);++a{"use strict";n.d(e,{Z:()=>a});var r=n(3413),i="object"==typeof self&&self&&self.Object===Object&&self;const a=r.Z||i||Function("return this")()},6545:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}},3626:(t,e,n)=>{"use strict";n.d(e,{Z:()=>l});var r=n(2002),i=n(7904),a=n(9203);const s=i.Z?function(t,e){return(0,i.Z)(t,"toString",{configurable:!0,enumerable:!1,value:(0,r.Z)(e),writable:!0})}:a.Z;var o=Date.now;const l=(c=s,h=0,u=0,function(){var t=o(),e=16-(t-u);if(u=t,e>0){if(++h>=800)return arguments[0]}else h=0;return c.apply(void 0,arguments)});var c,h,u},2656:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(2714);const i=function(t){if("string"==typeof t||(0,r.Z)(t))return t;var e=t+"";return"0"==e&&1/t==-1/0?"-0":e}},19:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=Function.prototype.toString;const i=function(t){if(null!=t){try{return r.call(t)}catch(t){}try{return t+""}catch(t){}}return""}},2346:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(9943);const i=function(t){return(0,r.Z)(t,4)}},2002:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){return function(){return t}}},3688:(t,e,n)=>{"use strict";n.d(e,{Z:()=>c});var r=n(9581),i=n(9651),a=n(439),s=n(7590),o=Object.prototype,l=o.hasOwnProperty;const c=(0,r.Z)((function(t,e){t=Object(t);var n=-1,r=e.length,c=r>2?e[2]:void 0;for(c&&(0,a.Z)(e[0],e[1],c)&&(r=1);++n{"use strict";n.d(e,{Z:()=>r});const r=function(t,e){return t===e||t!=t&&e!=e}},9601:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(8774),i=n(4749),a=n(506),s=n(7771);const o=function(t,e){return((0,s.Z)(t)?r.Z:i.Z)(t,(0,a.Z)(e,3))}},6026:(t,e,n)=>{"use strict";n.d(e,{Z:()=>c});var r=n(506),i=n(585),a=n(7179);var s=n(1692),o=n(4930),l=Math.max;const c=(h=function(t,e,n){var i=null==t?0:t.length;if(!i)return-1;var a=null==n?0:(0,o.Z)(n);return a<0&&(a=l(i+a,0)),(0,s.Z)(t,(0,r.Z)(e,3),a)},function(t,e,n){var s=Object(t);if(!(0,i.Z)(t)){var o=(0,r.Z)(e,3);t=(0,a.Z)(t),e=function(t){return o(s[t],t,s)}}var l=h(t,e,n);return l>-1?s[o?t[l]:l]:void 0});var h},6805:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(5140),i=n(3836);const a=function(t,e){return(0,r.Z)((0,i.Z)(t,e),1)}},7961:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(5140);const i=function(t){return null!=t&&t.length?(0,r.Z)(t,1):[]}},870:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(6579),i=n(8640),a=n(8882),s=n(7771);const o=function(t,e){return((0,s.Z)(t)?r.Z:i.Z)(t,(0,a.Z)(e))}},3402:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=Object.prototype.hasOwnProperty;const i=function(t,e){return null!=t&&r.call(t,e)};var a=n(5196);const s=function(t,e){return null!=t&&(0,a.Z)(t,e,i)}},1910:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});const r=function(t,e){return null!=t&&e in Object(t)};var i=n(5196);const a=function(t,e){return null!=t&&(0,i.Z)(t,e,r)}},9203:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){return t}},4732:(t,e,n)=>{"use strict";n.d(e,{Z:()=>c});var r=n(4492),i=n(8533);const a=function(t){return(0,i.Z)(t)&&"[object Arguments]"==(0,r.Z)(t)};var s=Object.prototype,o=s.hasOwnProperty,l=s.propertyIsEnumerable;const c=a(function(){return arguments}())?a:function(t){return(0,i.Z)(t)&&o.call(t,"callee")&&!l.call(t,"callee")}},7771:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=Array.isArray},585:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(3234),i=n(1656);const a=function(t){return null!=t&&(0,i.Z)(t.length)&&!(0,r.Z)(t)}},836:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(585),i=n(8533);const a=function(t){return(0,i.Z)(t)&&(0,r.Z)(t)}},6706:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(6092);var i="object"==typeof exports&&exports&&!exports.nodeType&&exports,a=i&&"object"==typeof module&&module&&!module.nodeType&&module,s=a&&a.exports===i?r.Z.Buffer:void 0;const o=(s?s.isBuffer:void 0)||function(){return!1}},9697:(t,e,n)=>{"use strict";n.d(e,{Z:()=>d});var r=n(8448),i=n(6155),a=n(4732),s=n(7771),o=n(585),l=n(6706),c=n(2764),h=n(7212),u=Object.prototype.hasOwnProperty;const d=function(t){if(null==t)return!0;if((0,o.Z)(t)&&((0,s.Z)(t)||"string"==typeof t||"function"==typeof t.splice||(0,l.Z)(t)||(0,h.Z)(t)||(0,a.Z)(t)))return!t.length;var e=(0,i.Z)(t);if("[object Map]"==e||"[object Set]"==e)return!t.size;if((0,c.Z)(t))return!(0,r.Z)(t).length;for(var n in t)if(u.call(t,n))return!1;return!0}},3234:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(4492),i=n(7226);const a=function(t){if(!(0,i.Z)(t))return!1;var e=(0,r.Z)(t);return"[object Function]"==e||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e}},1656:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=9007199254740991}},7226:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}},8533:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){return null!=t&&"object"==typeof t}},6378:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=n(4492),i=n(7771),a=n(8533);const s=function(t){return"string"==typeof t||!(0,i.Z)(t)&&(0,a.Z)(t)&&"[object String]"==(0,r.Z)(t)}},2714:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(4492),i=n(8533);const a=function(t){return"symbol"==typeof t||(0,i.Z)(t)&&"[object Symbol]"==(0,r.Z)(t)}},7212:(t,e,n)=>{"use strict";n.d(e,{Z:()=>h});var r=n(4492),i=n(1656),a=n(8533),s={};s["[object Float32Array]"]=s["[object Float64Array]"]=s["[object Int8Array]"]=s["[object Int16Array]"]=s["[object Int32Array]"]=s["[object Uint8Array]"]=s["[object Uint8ClampedArray]"]=s["[object Uint16Array]"]=s["[object Uint32Array]"]=!0,s["[object Arguments]"]=s["[object Array]"]=s["[object ArrayBuffer]"]=s["[object Boolean]"]=s["[object DataView]"]=s["[object Date]"]=s["[object Error]"]=s["[object Function]"]=s["[object Map]"]=s["[object Number]"]=s["[object Object]"]=s["[object RegExp]"]=s["[object Set]"]=s["[object String]"]=s["[object WeakMap]"]=!1;var o=n(1162),l=n(8351),c=l.Z&&l.Z.isTypedArray;const h=c?(0,o.Z)(c):function(t){return(0,a.Z)(t)&&(0,i.Z)(t.length)&&!!s[(0,r.Z)(t)]}},9360:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){return void 0===t}},7179:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=n(9001),i=n(8448),a=n(585);const s=function(t){return(0,a.Z)(t)?(0,r.Z)(t):(0,i.Z)(t)}},7590:(t,e,n)=>{"use strict";n.d(e,{Z:()=>c});var r=n(9001),i=n(7226),a=n(2764);var s=Object.prototype.hasOwnProperty;const o=function(t){if(!(0,i.Z)(t))return function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}(t);var e=(0,a.Z)(t),n=[];for(var r in t)("constructor"!=r||!e&&s.call(t,r))&&n.push(r);return n};var l=n(585);const c=function(t){return(0,l.Z)(t)?(0,r.Z)(t,!0):o(t)}},935:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(t){var e=null==t?0:t.length;return e?t[e-1]:void 0}},3836:(t,e,n)=>{"use strict";n.d(e,{Z:()=>o});var r=n(7679),i=n(506),a=n(1018),s=n(7771);const o=function(t,e){return((0,s.Z)(t)?r.Z:a.Z)(t,(0,i.Z)(e,3))}},2454:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(520);function i(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var s=t.apply(this,r);return n.cache=a.set(i,s)||a,s};return n.cache=new(i.Cache||r.Z),n}i.Cache=r.Z;const a=i},7103:(t,e,n)=>{"use strict";n.d(e,{Z:()=>I});var r=n(5365),i=n(4752),a=n(9651);const s=function(t,e,n){(void 0!==n&&!(0,a.Z)(t[e],n)||void 0===n&&!(e in t))&&(0,i.Z)(t,e,n)};var o=n(5381),l=n(1050),c=n(2701),h=n(7215),u=n(5418),d=n(4732),p=n(7771),g=n(836),f=n(6706),m=n(3234),y=n(7226),v=n(4492),x=n(2513),b=n(8533),w=Function.prototype,k=Object.prototype,T=w.toString,_=k.hasOwnProperty,E=T.call(Object);var S=n(7212);const C=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]};var A=n(1899),L=n(7590);const M=function(t,e,n,r,i,a,o){var w,k=C(t,n),M=C(e,n),N=o.get(M);if(N)s(t,n,N);else{var I=a?a(k,M,n+"",t,e,o):void 0,R=void 0===I;if(R){var D=(0,p.Z)(M),O=!D&&(0,f.Z)(M),P=!D&&!O&&(0,S.Z)(M);I=M,D||O||P?(0,p.Z)(k)?I=k:(0,g.Z)(k)?I=(0,h.Z)(k):O?(R=!1,I=(0,l.Z)(M,!0)):P?(R=!1,I=(0,c.Z)(M,!0)):I=[]:function(t){if(!(0,b.Z)(t)||"[object Object]"!=(0,v.Z)(t))return!1;var e=(0,x.Z)(t);if(null===e)return!0;var n=_.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&T.call(n)==E}(M)||(0,d.Z)(M)?(I=k,(0,d.Z)(k)?(w=k,I=(0,A.Z)(w,(0,L.Z)(w))):(0,y.Z)(k)&&!(0,m.Z)(k)||(I=(0,u.Z)(M))):R=!1}R&&(o.set(M,I),i(I,M,r,a,o),o.delete(M)),s(t,n,I)}},N=function t(e,n,i,a,l){e!==n&&(0,o.Z)(n,(function(o,c){if(l||(l=new r.Z),(0,y.Z)(o))M(e,n,c,i,t,a,l);else{var h=a?a(C(e,c),o,c+"",e,n,l):void 0;void 0===h&&(h=o),s(e,c,h)}}),L.Z)},I=(0,n(9268).Z)((function(t,e,n){N(t,e,n)}))},3729:(t,e,n)=>{"use strict";n.d(e,{Z:()=>s});var r=n(8e3),i=n(676),a=n(9203);const s=function(t){return t&&t.length?(0,r.Z)(t,a.Z,i.Z):void 0}},2054:(t,e,n)=>{"use strict";n.d(e,{Z:()=>r});const r=function(){}},4283:(t,e,n)=>{"use strict";n.d(e,{Z:()=>l});const r=function(t,e,n,r){var i=-1,a=null==t?0:t.length;for(r&&a&&(n=t[++i]);++i{"use strict";n.d(e,{Z:()=>r});const r=function(){return[]}},6770:(t,e,n)=>{"use strict";n.d(e,{Z:()=>d});var r=/\s/;var i=/^\s+/;const a=function(t){return t?t.slice(0,function(t){for(var e=t.length;e--&&r.test(t.charAt(e)););return e}(t)+1).replace(i,""):t};var s=n(7226),o=n(2714),l=/^[-+]0x[0-9a-f]+$/i,c=/^0b[01]+$/i,h=/^0o[0-7]+$/i,u=parseInt;const d=function(t){return t?Infinity===(t=function(t){if("number"==typeof t)return t;if((0,o.Z)(t))return NaN;if((0,s.Z)(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=(0,s.Z)(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=a(t);var n=c.test(t);return n||h.test(t)?u(t.slice(2),n?2:8):l.test(t)?NaN:+t}(t))||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}},4930:(t,e,n)=>{"use strict";n.d(e,{Z:()=>i});var r=n(6770);const i=function(t){var e=(0,r.Z)(t),n=e%1;return e==e?n?e-n:e:0}},2402:(t,e,n)=>{"use strict";n.d(e,{Z:()=>h});var r=n(7685),i=n(7679),a=n(7771),s=n(2714),o=r.Z?r.Z.prototype:void 0,l=o?o.toString:void 0;const c=function t(e){if("string"==typeof e)return e;if((0,a.Z)(e))return(0,i.Z)(e,t)+"";if((0,s.Z)(e))return l?l.call(e):"";var n=e+"";return"0"==n&&1/e==-1/0?"-0":n},h=function(t){return null==t?"":c(t)}},4657:(t,e,n)=>{"use strict";n.d(e,{Z:()=>a});var r=n(7679);var i=n(7179);const a=function(t){return null==t?[]:function(t,e){return(0,r.Z)(e,(function(e){return t[e]}))}(t,(0,i.Z)(t))}},8545:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>dt});var r=n(6241),i=n(214),a=n(1957),s=n(7207),o=(n(7946),n(5430)),l=n(4082),c=n(2491),h=n(1387),u=n(4867),d=n(3108),p={L:"left",R:"right",T:"top",B:"bottom"},g={L:(0,l.eW)((t=>`${t},${t/2} 0,${t} 0,0`),"L"),R:(0,l.eW)((t=>`0,${t/2} ${t},0 ${t},${t}`),"R"),T:(0,l.eW)((t=>`0,0 ${t},0 ${t/2},${t}`),"T"),B:(0,l.eW)((t=>`${t/2},0 ${t},${t} 0,${t}`),"B")},f={L:(0,l.eW)(((t,e)=>t-e+2),"L"),R:(0,l.eW)(((t,e)=>t-2),"R"),T:(0,l.eW)(((t,e)=>t-e+2),"T"),B:(0,l.eW)(((t,e)=>t-2),"B")},m=(0,l.eW)((function(t){return v(t)?"L"===t?"R":"L":"T"===t?"B":"T"}),"getOppositeArchitectureDirection"),y=(0,l.eW)((function(t){return"L"===t||"R"===t||"T"===t||"B"===t}),"isArchitectureDirection"),v=(0,l.eW)((function(t){return"L"===t||"R"===t}),"isArchitectureDirectionX"),x=(0,l.eW)((function(t){return"T"===t||"B"===t}),"isArchitectureDirectionY"),b=(0,l.eW)((function(t,e){const n=v(t)&&x(e),r=x(t)&&v(e);return n||r}),"isArchitectureDirectionXY"),w=(0,l.eW)((function(t){const e=t[0],n=t[1],r=v(e)&&x(n),i=x(e)&&v(n);return r||i}),"isArchitecturePairXY"),k=(0,l.eW)((function(t){return"LL"!==t&&"RR"!==t&&"TT"!==t&&"BB"!==t}),"isValidArchitectureDirectionPair"),T=(0,l.eW)((function(t,e){const n=`${t}${e}`;return k(n)?n:void 0}),"getArchitectureDirectionPair"),_=(0,l.eW)((function([t,e],n){const r=n[0],i=n[1];return v(r)?x(i)?[t+("L"===r?-1:1),e+("T"===i?1:-1)]:[t+("L"===r?-1:1),e]:v(i)?[t+("L"===i?1:-1),e+("T"===r?1:-1)]:[t,e+("T"===r?1:-1)]}),"shiftPositionByArchitectureDirectionPair"),E=(0,l.eW)((function(t){return"LT"===t||"TL"===t?[1,1]:"BL"===t||"LB"===t?[1,-1]:"BR"===t||"RB"===t?[-1,-1]:[-1,1]}),"getArchitectureDirectionXYFactors"),S=(0,l.eW)((function(t,e){return b(t,e)?"bend":v(t)?"horizontal":"vertical"}),"getArchitectureDirectionAlignment"),C=(0,l.eW)((function(t){return"service"===t.type}),"isArchitectureService"),A=(0,l.eW)((function(t){return"junction"===t.type}),"isArchitectureJunction"),L=(0,l.eW)((t=>t.data()),"edgeData"),M=(0,l.eW)((t=>t.data()),"nodeData"),N=l.vZ.architecture,I=new s.A((()=>({nodes:{},groups:{},edges:[],registeredIds:{},config:N,dataStructures:void 0,elements:{}}))),R=(0,l.eW)((()=>{I.reset(),(0,l.ZH)()}),"clear"),D=(0,l.eW)((function({id:t,icon:e,in:n,title:r,iconText:i}){if(void 0!==I.records.registeredIds[t])throw new Error(`The service id [${t}] is already in use by another ${I.records.registeredIds[t]}`);if(void 0!==n){if(t===n)throw new Error(`The service [${t}] cannot be placed within itself`);if(void 0===I.records.registeredIds[n])throw new Error(`The service [${t}]'s parent does not exist. Please make sure the parent is created before this service`);if("node"===I.records.registeredIds[n])throw new Error(`The service [${t}]'s parent is not a group`)}I.records.registeredIds[t]="node",I.records.nodes[t]={id:t,type:"service",icon:e,iconText:i,title:r,edges:[],in:n}}),"addService"),O=(0,l.eW)((()=>Object.values(I.records.nodes).filter(C)),"getServices"),P=(0,l.eW)((function({id:t,in:e}){I.records.registeredIds[t]="node",I.records.nodes[t]={id:t,type:"junction",edges:[],in:e}}),"addJunction"),$=(0,l.eW)((()=>Object.values(I.records.nodes).filter(A)),"getJunctions"),B=(0,l.eW)((()=>Object.values(I.records.nodes)),"getNodes"),F=(0,l.eW)((t=>I.records.nodes[t]),"getNode"),W=(0,l.eW)((function({id:t,icon:e,in:n,title:r}){if(void 0!==I.records.registeredIds[t])throw new Error(`The group id [${t}] is already in use by another ${I.records.registeredIds[t]}`);if(void 0!==n){if(t===n)throw new Error(`The group [${t}] cannot be placed within itself`);if(void 0===I.records.registeredIds[n])throw new Error(`The group [${t}]'s parent does not exist. Please make sure the parent is created before this group`);if("node"===I.records.registeredIds[n])throw new Error(`The group [${t}]'s parent is not a group`)}I.records.registeredIds[t]="group",I.records.groups[t]={id:t,icon:e,title:r,in:n}}),"addGroup"),z=(0,l.eW)((()=>Object.values(I.records.groups)),"getGroups"),Z=(0,l.eW)((function({lhsId:t,rhsId:e,lhsDir:n,rhsDir:r,lhsInto:i,rhsInto:a,lhsGroup:s,rhsGroup:o,title:l}){if(!y(n))throw new Error(`Invalid direction given for left hand side of edge ${t}--${e}. Expected (L,R,T,B) got ${n}`);if(!y(r))throw new Error(`Invalid direction given for right hand side of edge ${t}--${e}. Expected (L,R,T,B) got ${r}`);if(void 0===I.records.nodes[t]&&void 0===I.records.groups[t])throw new Error(`The left-hand id [${t}] does not yet exist. Please create the service/group before declaring an edge to it.`);if(void 0===I.records.nodes[e]&&void 0===I.records.groups[t])throw new Error(`The right-hand id [${e}] does not yet exist. Please create the service/group before declaring an edge to it.`);const c=I.records.nodes[t].in,h=I.records.nodes[e].in;if(s&&c&&h&&c==h)throw new Error(`The left-hand id [${t}] is modified to traverse the group boundary, but the edge does not pass through two groups.`);if(o&&c&&h&&c==h)throw new Error(`The right-hand id [${e}] is modified to traverse the group boundary, but the edge does not pass through two groups.`);const u={lhsId:t,lhsDir:n,lhsInto:i,lhsGroup:s,rhsId:e,rhsDir:r,rhsInto:a,rhsGroup:o,title:l};I.records.edges.push(u),I.records.nodes[t]&&I.records.nodes[e]&&(I.records.nodes[t].edges.push(I.records.edges[I.records.edges.length-1]),I.records.nodes[e].edges.push(I.records.edges[I.records.edges.length-1]))}),"addEdge"),Y=(0,l.eW)((()=>I.records.edges),"getEdges"),U=(0,l.eW)((()=>{if(void 0===I.records.dataStructures){const t={},e=Object.entries(I.records.nodes).reduce(((e,[n,r])=>(e[n]=r.edges.reduce(((e,r)=>{const i=F(r.lhsId)?.in,a=F(r.rhsId)?.in;if(i&&a&&i!==a){const e=S(r.lhsDir,r.rhsDir);"bend"!==e&&(t[i]??={},t[i][a]=e,t[a]??={},t[a][i]=e)}if(r.lhsId===n){const t=T(r.lhsDir,r.rhsDir);t&&(e[t]=r.rhsId)}else{const t=T(r.rhsDir,r.lhsDir);t&&(e[t]=r.lhsId)}return e}),{}),e)),{}),n=Object.keys(e)[0],r={[n]:1},i=Object.keys(e).reduce(((t,e)=>e===n?t:{...t,[e]:1}),{}),a=(0,l.eW)((t=>{const n={[t]:[0,0]},a=[t];for(;a.length>0;){const t=a.shift();if(t){r[t]=1,delete i[t];const s=e[t],[o,l]=n[t];Object.entries(s).forEach((([t,e])=>{r[e]||(n[e]=_([o,l],t),a.push(e))}))}}return n}),"BFS"),s=[a(n)];for(;Object.keys(i).length>0;)s.push(a(Object.keys(i)[0]));I.records.dataStructures={adjList:e,spatialMaps:s,groupAlignments:t}}return I.records.dataStructures}),"getDataStructures"),G=(0,l.eW)(((t,e)=>{I.records.elements[t]=e}),"setElementForId"),V=(0,l.eW)((t=>I.records.elements[t]),"getElementById"),q={clear:R,setDiagramTitle:l.g2,getDiagramTitle:l.Kr,setAccTitle:l.GN,getAccTitle:l.eu,setAccDescription:l.U$,getAccDescription:l.Mx,addService:D,getServices:O,addJunction:P,getJunctions:$,getNodes:B,getNode:F,addGroup:W,getGroups:z,addEdge:Z,getEdges:Y,setElementForId:G,getElementById:V,getDataStructures:U};function j(t){const e=(0,l.nV)().architecture;return e?.[t]?e[t]:N[t]}(0,l.eW)(j,"getConfigField");var H=(0,l.eW)(((t,e)=>{(0,a.A)(t,e),t.groups.map(e.addGroup),t.services.map((t=>e.addService({...t,type:"service"}))),t.junctions.map((t=>e.addJunction({...t,type:"junction"}))),t.edges.map(e.addEdge)}),"populateDb"),X={parse:(0,l.eW)((async t=>{const e=await(0,c.Qc)("architecture",t);l.cM.debug(e),H(e,q)}),"parse")},K=(0,l.eW)((t=>`\n .edge {\n stroke-width: ${t.archEdgeWidth};\n stroke: ${t.archEdgeColor};\n fill: none;\n }\n\n .arrow {\n fill: ${t.archEdgeArrowColor};\n }\n\n .node-bkg {\n fill: none;\n stroke: ${t.archGroupBorderColor};\n stroke-width: ${t.archGroupBorderWidth};\n stroke-dasharray: 8;\n }\n .node-icon-text {\n display: flex; \n align-items: center;\n }\n \n .node-icon-text > div {\n color: #fff;\n margin: 1px;\n height: fit-content;\n text-align: center;\n overflow: hidden;\n display: -webkit-box;\n -webkit-box-orient: vertical;\n }\n`),"getStyles"),Q=(0,l.eW)((t=>`${t}`),"wrapIcon"),J={prefix:"mermaid-architecture",height:80,width:80,icons:{database:{body:Q('')},server:{body:Q('')},disk:{body:Q('')},internet:{body:Q('')},cloud:{body:Q('')},unknown:r.cN,blank:{body:Q("")}}},tt=(0,l.eW)((async function(t,e){const n=j("padding"),r=j("iconSize"),a=r/2,s=r/6,o=s/2;await Promise.all(e.edges().map((async e=>{const{source:r,sourceDir:c,sourceArrow:h,sourceGroup:u,target:d,targetDir:p,targetArrow:m,targetGroup:y,label:k}=L(e);let{x:_,y:S}=e[0].sourceEndpoint();const{x:C,y:A}=e[0].midpoint();let{x:M,y:N}=e[0].targetEndpoint();const I=n+4;if(u&&(v(c)?_+="L"===c?-I:I:S+="T"===c?-I:I+18),y&&(v(p)?M+="L"===p?-I:I:N+="T"===p?-I:I+18),u||"junction"!==q.getNode(r)?.type||(v(c)?_+="L"===c?a:-a:S+="T"===c?a:-a),y||"junction"!==q.getNode(d)?.type||(v(p)?M+="L"===p?a:-a:N+="T"===p?a:-a),e[0]._private.rscratch){const e=t.insert("g");if(e.insert("path").attr("d",`M ${_},${S} L ${C},${A} L${M},${N} `).attr("class","edge"),h){const t=v(c)?f[c](_,s):_-o,n=x(c)?f[c](S,s):S-o;e.insert("polygon").attr("points",g[c](s)).attr("transform",`translate(${t},${n})`).attr("class","arrow")}if(m){const t=v(p)?f[p](M,s):M-o,n=x(p)?f[p](N,s):N-o;e.insert("polygon").attr("points",g[p](s)).attr("transform",`translate(${t},${n})`).attr("class","arrow")}if(k){const t=b(c,p)?"XY":v(c)?"X":"Y";let n=0;n="X"===t?Math.abs(_-M):"Y"===t?Math.abs(S-N)/1.5:Math.abs(_-M)/2;const r=e.append("g");if(await(0,i.rw)(r,k,{useHtmlLabels:!1,width:n,classes:"architecture-service-label"},(0,l.nV)()),r.attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","middle").attr("text-anchor","middle"),"X"===t)r.attr("transform","translate("+C+", "+A+")");else if("Y"===t)r.attr("transform","translate("+C+", "+A+") rotate(-90)");else if("XY"===t){const t=T(c,p);if(t&&w(t)){const e=r.node().getBoundingClientRect(),[n,i]=E(t);r.attr("dominant-baseline","auto").attr("transform",`rotate(${-1*n*i*45})`);const a=r.node().getBoundingClientRect();r.attr("transform",`\n translate(${C}, ${A-e.height/2})\n translate(${n*a.width/2}, ${i*a.height/2})\n rotate(${-1*n*i*45}, 0, ${e.height/2})\n `)}}}}})))}),"drawEdges"),et=(0,l.eW)((async function(t,e){const n=.75*j("padding"),a=j("fontSize"),s=j("iconSize")/2;await Promise.all(e.nodes().map((async e=>{const o=M(e);if("group"===o.type){const{h:c,w:h,x1:u,y1:d}=e.boundingBox();t.append("rect").attr("x",u+s).attr("y",d+s).attr("width",h).attr("height",c).attr("class","node-bkg");const p=t.append("g");let g=u,f=d;if(o.icon){const t=p.append("g");t.html(`${await(0,r.s4)(o.icon,{height:n,width:n,fallbackPrefix:J.prefix})}`),t.attr("transform","translate("+(g+s+1)+", "+(f+s+1)+")"),g+=n,f+=a/2-1-2}if(o.label){const t=p.append("g");await(0,i.rw)(t,o.label,{useHtmlLabels:!1,width:h,classes:"architecture-service-label"},(0,l.nV)()),t.attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","start").attr("text-anchor","start"),t.attr("transform","translate("+(g+s+4)+", "+(f+s+2)+")")}}})))}),"drawGroups"),nt=(0,l.eW)((async function(t,e,n){for(const a of n){const n=e.append("g"),s=j("iconSize");if(a.title){const t=n.append("g");await(0,i.rw)(t,a.title,{useHtmlLabels:!1,width:1.5*s,classes:"architecture-service-label"},(0,l.nV)()),t.attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","middle").attr("text-anchor","middle"),t.attr("transform","translate("+s/2+", "+s+")")}const o=n.append("g");if(a.icon)o.html(`${await(0,r.s4)(a.icon,{height:s,width:s,fallbackPrefix:J.prefix})}`);else if(a.iconText){o.html(`${await(0,r.s4)("blank",{height:s,width:s,fallbackPrefix:J.prefix})}`);const t=o.append("g").append("foreignObject").attr("width",s).attr("height",s).append("div").attr("class","node-icon-text").attr("style",`height: ${s}px;`).append("div").html(a.iconText),e=parseInt(window.getComputedStyle(t.node(),null).getPropertyValue("font-size").replace(/\D/g,""))??16;t.attr("style",`-webkit-line-clamp: ${Math.floor((s-2)/e)};`)}else o.append("path").attr("class","node-bkg").attr("id","node-"+a.id).attr("d",`M0 ${s} v${-s} q0,-5 5,-5 h${s} q5,0 5,5 v${s} H0 Z`);n.attr("class","architecture-service");const{width:c,height:h}=n._groups[0][0].getBBox();a.width=c,a.height=h,t.setElementForId(a.id,n)}return 0}),"drawServices"),rt=(0,l.eW)((function(t,e,n){n.forEach((n=>{const r=e.append("g"),i=j("iconSize");r.append("g").append("rect").attr("id","node-"+n.id).attr("fill-opacity","0").attr("width",i).attr("height",i),r.attr("class","architecture-junction");const{width:a,height:s}=r._groups[0][0].getBBox();r.width=a,r.height=s,t.setElementForId(n.id,r)}))}),"drawJunctions");function it(t,e){t.forEach((t=>{e.add({group:"nodes",data:{type:"service",id:t.id,icon:t.icon,label:t.title,parent:t.in,width:j("iconSize"),height:j("iconSize")},classes:"node-service"})}))}function at(t,e){t.forEach((t=>{e.add({group:"nodes",data:{type:"junction",id:t.id,parent:t.in,width:j("iconSize"),height:j("iconSize")},classes:"node-junction"})}))}function st(t,e){e.nodes().map((e=>{const n=M(e);"group"!==n.type&&(n.x=e.position().x,n.y=e.position().y,t.getElementById(n.id).attr("transform","translate("+(n.x||0)+","+(n.y||0)+")"))}))}function ot(t,e){t.forEach((t=>{e.add({group:"nodes",data:{type:"group",id:t.id,icon:t.icon,label:t.title,parent:t.in},classes:"node-group"})}))}function lt(t,e){t.forEach((t=>{const{lhsId:n,rhsId:r,lhsInto:i,lhsGroup:a,rhsInto:s,lhsDir:o,rhsDir:l,rhsGroup:c,title:h}=t,u=b(t.lhsDir,t.rhsDir)?"segments":"straight",d={id:`${n}-${r}`,label:h,source:n,sourceDir:o,sourceArrow:i,sourceGroup:a,sourceEndpoint:"L"===o?"0 50%":"R"===o?"100% 50%":"T"===o?"50% 0":"50% 100%",target:r,targetDir:l,targetArrow:s,targetGroup:c,targetEndpoint:"L"===l?"0 50%":"R"===l?"100% 50%":"T"===l?"50% 0":"50% 100%"};e.add({group:"edges",data:d,classes:u})}))}function ct(t,e,n){const r=(0,l.eW)(((t,e)=>Object.entries(t).reduce(((t,[r,i])=>{let a=0;const s=Object.entries(i);if(1===s.length)return t[r]=s[0][1],t;for(let i=0;i{const n={},i={};return Object.entries(e).forEach((([e,[r,a]])=>{const s=t.getNode(e)?.in??"default";n[a]??={},n[a][s]??=[],n[a][s].push(e),i[r]??={},i[r][s]??=[],i[r][s].push(e)})),{horiz:Object.values(r(n,"horizontal")).filter((t=>t.length>1)),vert:Object.values(r(i,"vertical")).filter((t=>t.length>1))}})),[a,s]=i.reduce((([t,e],{horiz:n,vert:r})=>[[...t,...n],[...e,...r]]),[[],[]]);return{horizontal:a,vertical:s}}function ht(t){const e=[],n=(0,l.eW)((t=>`${t[0]},${t[1]}`),"posToStr"),r=(0,l.eW)((t=>t.split(",").map((t=>parseInt(t)))),"strToPos");return t.forEach((t=>{const i=Object.fromEntries(Object.entries(t).map((([t,e])=>[n(e),t]))),a=[n([0,0])],s={},o={L:[-1,0],R:[1,0],T:[0,1],B:[0,-1]};for(;a.length>0;){const t=a.shift();if(t){s[t]=1;const l=i[t];if(l){const c=r(t);Object.entries(o).forEach((([t,r])=>{const o=n([c[0]+r[0],c[1]+r[1]]),h=i[o];h&&!s[o]&&(a.push(o),e.push({[p[t]]:h,[p[m(t)]]:l,gap:1.5*j("iconSize")}))}))}}}})),e}function ut(t,e,n,r,i,{spatialMaps:a,groupAlignments:s}){return new Promise((o=>{const c=(0,d.Ys)("body").append("div").attr("id","cy").attr("style","display:none"),u=(0,h.Z)({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"straight",label:"data(label)","source-endpoint":"data(sourceEndpoint)","target-endpoint":"data(targetEndpoint)"}},{selector:"edge.segments",style:{"curve-style":"segments","segment-weights":"0","segment-distances":[.5],"edge-distances":"endpoints","source-endpoint":"data(sourceEndpoint)","target-endpoint":"data(targetEndpoint)"}},{selector:"node",style:{"compound-sizing-wrt-labels":"include"}},{selector:"node[label]",style:{"text-valign":"bottom","text-halign":"center","font-size":`${j("fontSize")}px`}},{selector:".node-service",style:{label:"data(label)",width:"data(width)",height:"data(height)"}},{selector:".node-junction",style:{width:"data(width)",height:"data(height)"}},{selector:".node-group",style:{padding:`${j("padding")}px`}}]});c.remove(),ot(n,u),it(t,u),at(e,u),lt(r,u);const p=ct(i,a,s),g=ht(a),f=u.layout({name:"fcose",quality:"proof",styleEnabled:!1,animate:!1,nodeDimensionsIncludeLabels:!1,idealEdgeLength(t){const[e,n]=t.connectedNodes(),{parent:r}=M(e),{parent:i}=M(n);return r===i?1.5*j("iconSize"):.5*j("iconSize")},edgeElasticity(t){const[e,n]=t.connectedNodes(),{parent:r}=M(e),{parent:i}=M(n);return r===i?.45:.001},alignmentConstraint:p,relativePlacementConstraint:g});f.one("layoutstop",(()=>{function t(t,e,n,r){let i,a;const{x:s,y:o}=t,{x:l,y:c}=e;a=(r-o+(s-n)*(o-c)/(s-l))/Math.sqrt(1+Math.pow((o-c)/(s-l),2)),i=Math.sqrt(Math.pow(r-o,2)+Math.pow(n-s,2)-Math.pow(a,2)),i/=Math.sqrt(Math.pow(l-s,2)+Math.pow(c-o,2));let h=(l-s)*(r-o)-(c-o)*(n-s);switch(!0){case h>=0:h=1;break;case h<0:h=-1}let u=(l-s)*(n-s)+(c-o)*(r-o);switch(!0){case u>=0:u=1;break;case u<0:u=-1}return a=Math.abs(a)*h,i*=u,{distances:a,weights:i}}(0,l.eW)(t,"getSegmentWeights"),u.startBatch();for(const e of Object.values(u.edges()))if(e.data?.()){const{x:n,y:r}=e.source().position(),{x:i,y:a}=e.target().position();if(n!==i&&r!==a){const n=e.sourceEndpoint(),r=e.targetEndpoint(),{sourceDir:i}=L(e),[a,s]=x(i)?[n.x,r.y]:[r.x,n.y],{weights:o,distances:l}=t(n,r,a,s);e.style("segment-distances",l),e.style("segment-weights",o)}}u.endBatch(),f.run()})),f.run(),u.ready((t=>{l.cM.info("Ready",t),o(u)}))}))}(0,r.ef)([{name:J.prefix,icons:J}]),h.Z.use(u),(0,l.eW)(it,"addServices"),(0,l.eW)(at,"addJunctions"),(0,l.eW)(st,"positionNodes"),(0,l.eW)(ot,"addGroups"),(0,l.eW)(lt,"addEdges"),(0,l.eW)(ct,"getAlignments"),(0,l.eW)(ht,"getRelativeConstraints"),(0,l.eW)(ut,"layoutArchitecture");var dt={parser:X,db:q,renderer:{draw:(0,l.eW)((async(t,e,n,r)=>{const i=r.db,a=i.getServices(),s=i.getJunctions(),c=i.getGroups(),h=i.getEdges(),u=i.getDataStructures(),d=(0,o.P)(e),p=d.append("g");p.attr("class","architecture-edges");const g=d.append("g");g.attr("class","architecture-services");const f=d.append("g");f.attr("class","architecture-groups"),await nt(i,g,a),rt(i,g,s);const m=await ut(a,s,c,h,i,u);await tt(p,m),await et(f,m),st(i,m),(0,l.j7)(void 0,d,j("padding"),j("useMaxWidth"))}),"draw")},styles:K}},7724:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>ve});var r=n(5179),i=n(1426),a=n(214),s=n(7946),o=n(4082),l=n(2346),c=n(9792),h=n(1117),u=n(3108),d=n(5625),p=function(){var t=(0,o.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,7],n=[1,13],r=[1,14],i=[1,15],a=[1,19],s=[1,16],l=[1,17],c=[1,18],h=[8,30],u=[8,21,28,29,30,31,32,40,44,47],d=[1,23],p=[1,24],g=[8,15,16,21,28,29,30,31,32,40,44,47],f=[8,15,16,21,27,28,29,30,31,32,40,44,47],m=[1,49],y={trace:(0,o.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,block:31,NODE_ID:32,nodeShapeNLabel:33,dirList:34,DIR:35,NODE_DSTART:36,NODE_DEND:37,BLOCK_ARROW_START:38,BLOCK_ARROW_END:39,classDef:40,CLASSDEF_ID:41,CLASSDEF_STYLEOPTS:42,DEFAULT:43,class:44,CLASSENTITY_IDS:45,STYLECLASS:46,style:47,STYLE_ENTITY_IDS:48,STYLE_DEFINITION_DATA:49,$accept:0,$end:1},terminals_:{2:"error",4:"SPACELINE",5:"NL",7:"SPACE",8:"EOF",10:"BLOCK_DIAGRAM_KEY",15:"LINK",16:"START_LINK",17:"LINK_LABEL",18:"STR",21:"SPACE_BLOCK",27:"SIZE",28:"COLUMNS",29:"id-block",30:"end",31:"block",32:"NODE_ID",35:"DIR",36:"NODE_DSTART",37:"NODE_DEND",38:"BLOCK_ARROW_START",39:"BLOCK_ARROW_END",40:"classDef",41:"CLASSDEF_ID",42:"CLASSDEF_STYLEOPTS",43:"DEFAULT",44:"class",45:"CLASSENTITY_IDS",46:"STYLECLASS",47:"style",48:"STYLE_ENTITY_IDS",49:"STYLE_DEFINITION_DATA"},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[34,1],[34,2],[33,3],[33,4],[23,3],[23,3],[24,3],[25,3]],performAction:(0,o.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 4:r.getLogger().debug("Rule: separator (NL) ");break;case 5:r.getLogger().debug("Rule: separator (Space) ");break;case 6:r.getLogger().debug("Rule: separator (EOF) ");break;case 7:r.getLogger().debug("Rule: hierarchy: ",a[o-1]),r.setHierarchy(a[o-1]);break;case 8:r.getLogger().debug("Stop NL ");break;case 9:r.getLogger().debug("Stop EOF ");break;case 10:r.getLogger().debug("Stop NL2 ");break;case 11:r.getLogger().debug("Stop EOF2 ");break;case 12:r.getLogger().debug("Rule: statement: ",a[o]),"number"==typeof a[o].length?this.$=a[o]:this.$=[a[o]];break;case 13:r.getLogger().debug("Rule: statement #2: ",a[o-1]),this.$=[a[o-1]].concat(a[o]);break;case 14:r.getLogger().debug("Rule: link: ",a[o],t),this.$={edgeTypeStr:a[o],label:""};break;case 15:r.getLogger().debug("Rule: LABEL link: ",a[o-3],a[o-1],a[o]),this.$={edgeTypeStr:a[o],label:a[o-1]};break;case 18:const e=parseInt(a[o]),n=r.generateId();this.$={id:n,type:"space",label:"",width:e,children:[]};break;case 23:r.getLogger().debug("Rule: (nodeStatement link node) ",a[o-2],a[o-1],a[o]," typestr: ",a[o-1].edgeTypeStr);const i=r.edgeStrToEdgeData(a[o-1].edgeTypeStr);this.$=[{id:a[o-2].id,label:a[o-2].label,type:a[o-2].type,directions:a[o-2].directions},{id:a[o-2].id+"-"+a[o].id,start:a[o-2].id,end:a[o].id,label:a[o-1].label,type:"edge",directions:a[o].directions,arrowTypeEnd:i,arrowTypeStart:"arrow_open"},{id:a[o].id,label:a[o].label,type:r.typeStr2Type(a[o].typeStr),directions:a[o].directions}];break;case 24:r.getLogger().debug("Rule: nodeStatement (abc88 node size) ",a[o-1],a[o]),this.$={id:a[o-1].id,label:a[o-1].label,type:r.typeStr2Type(a[o-1].typeStr),directions:a[o-1].directions,widthInColumns:parseInt(a[o],10)};break;case 25:r.getLogger().debug("Rule: nodeStatement (node) ",a[o]),this.$={id:a[o].id,label:a[o].label,type:r.typeStr2Type(a[o].typeStr),directions:a[o].directions,widthInColumns:1};break;case 26:r.getLogger().debug("APA123",this?this:"na"),r.getLogger().debug("COLUMNS: ",a[o]),this.$={type:"column-setting",columns:"auto"===a[o]?-1:parseInt(a[o])};break;case 27:r.getLogger().debug("Rule: id-block statement : ",a[o-2],a[o-1]),r.generateId(),this.$={...a[o-2],type:"composite",children:a[o-1]};break;case 28:r.getLogger().debug("Rule: blockStatement : ",a[o-2],a[o-1],a[o]);const s=r.generateId();this.$={id:s,type:"composite",label:"",children:a[o-1]};break;case 29:r.getLogger().debug("Rule: node (NODE_ID separator): ",a[o]),this.$={id:a[o]};break;case 30:r.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",a[o-1],a[o]),this.$={id:a[o-1],label:a[o].label,typeStr:a[o].typeStr,directions:a[o].directions};break;case 31:r.getLogger().debug("Rule: dirList: ",a[o]),this.$=[a[o]];break;case 32:r.getLogger().debug("Rule: dirList: ",a[o-1],a[o]),this.$=[a[o-1]].concat(a[o]);break;case 33:r.getLogger().debug("Rule: nodeShapeNLabel: ",a[o-2],a[o-1],a[o]),this.$={typeStr:a[o-2]+a[o],label:a[o-1]};break;case 34:r.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",a[o-3],a[o-2]," #3:",a[o-1],a[o]),this.$={typeStr:a[o-3]+a[o],label:a[o-2],directions:a[o-1]};break;case 35:case 36:this.$={type:"classDef",id:a[o-1].trim(),css:a[o].trim()};break;case 37:this.$={type:"applyClass",id:a[o-1].trim(),styleClass:a[o].trim()};break;case 38:this.$={type:"applyStyles",id:a[o-1].trim(),stylesStr:a[o].trim()}}}),"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{11:3,13:4,19:5,20:6,21:e,22:8,23:9,24:10,25:11,26:12,28:n,29:r,31:i,32:a,40:s,44:l,47:c},{8:[1,20]},t(h,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,21:e,28:n,29:r,31:i,32:a,40:s,44:l,47:c}),t(u,[2,16],{14:22,15:d,16:p}),t(u,[2,17]),t(u,[2,18]),t(u,[2,19]),t(u,[2,20]),t(u,[2,21]),t(u,[2,22]),t(g,[2,25],{27:[1,25]}),t(u,[2,26]),{19:26,26:12,32:a},{11:27,13:4,19:5,20:6,21:e,22:8,23:9,24:10,25:11,26:12,28:n,29:r,31:i,32:a,40:s,44:l,47:c},{41:[1,28],43:[1,29]},{45:[1,30]},{48:[1,31]},t(f,[2,29],{33:32,36:[1,33],38:[1,34]}),{1:[2,7]},t(h,[2,13]),{26:35,32:a},{32:[2,14]},{17:[1,36]},t(g,[2,24]),{11:37,13:4,14:22,15:d,16:p,19:5,20:6,21:e,22:8,23:9,24:10,25:11,26:12,28:n,29:r,31:i,32:a,40:s,44:l,47:c},{30:[1,38]},{42:[1,39]},{42:[1,40]},{46:[1,41]},{49:[1,42]},t(f,[2,30]),{18:[1,43]},{18:[1,44]},t(g,[2,23]),{18:[1,45]},{30:[1,46]},t(u,[2,28]),t(u,[2,35]),t(u,[2,36]),t(u,[2,37]),t(u,[2,38]),{37:[1,47]},{34:48,35:m},{15:[1,50]},t(u,[2,27]),t(f,[2,33]),{39:[1,51]},{34:52,35:m,39:[2,31]},{32:[2,15]},t(f,[2,34]),{39:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:(0,o.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,o.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],s=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,o.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,o.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=s[w]&&s[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],s[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=s[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},v=function(){return{EOF:1,parseError:(0,o.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,o.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,o.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,o.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,o.eW)((function(){return this._more=!0,this}),"more"),reject:(0,o.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,o.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,o.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,o.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,o.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,o.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,o.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,o.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,o.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,o.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,o.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,o.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,o.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,o.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{},performAction:(0,o.eW)((function(t,e,n,r){switch(n){case 0:return 10;case 1:return t.getLogger().debug("Found space-block"),31;case 2:return t.getLogger().debug("Found nl-block"),31;case 3:return t.getLogger().debug("Found space-block"),29;case 4:t.getLogger().debug(".",e.yytext);break;case 5:t.getLogger().debug("_",e.yytext);break;case 6:return 5;case 7:return e.yytext=-1,28;case 8:return e.yytext=e.yytext.replace(/columns\s+/,""),t.getLogger().debug("COLUMNS (LEX)",e.yytext),28;case 9:case 77:case 78:case 100:this.pushState("md_string");break;case 10:return"MD_STR";case 11:case 35:case 80:this.popState();break;case 12:this.pushState("string");break;case 13:t.getLogger().debug("LEX: POPPING STR:",e.yytext),this.popState();break;case 14:return t.getLogger().debug("LEX: STR end:",e.yytext),"STR";case 15:return e.yytext=e.yytext.replace(/space\:/,""),t.getLogger().debug("SPACE NUM (LEX)",e.yytext),21;case 16:return e.yytext="1",t.getLogger().debug("COLUMNS (LEX)",e.yytext),21;case 17:return 43;case 18:return"LINKSTYLE";case 19:return"INTERPOLATE";case 20:return this.pushState("CLASSDEF"),40;case 21:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 22:return this.popState(),this.pushState("CLASSDEFID"),41;case 23:return this.popState(),42;case 24:return this.pushState("CLASS"),44;case 25:return this.popState(),this.pushState("CLASS_STYLE"),45;case 26:return this.popState(),46;case 27:return this.pushState("STYLE_STMNT"),47;case 28:return this.popState(),this.pushState("STYLE_DEFINITION"),48;case 29:return this.popState(),49;case 30:return this.pushState("acc_title"),"acc_title";case 31:return this.popState(),"acc_title_value";case 32:return this.pushState("acc_descr"),"acc_descr";case 33:return this.popState(),"acc_descr_value";case 34:this.pushState("acc_descr_multiline");break;case 36:return"acc_descr_multiline_value";case 37:return 30;case 38:case 39:case 41:case 42:case 45:return this.popState(),t.getLogger().debug("Lex: (("),"NODE_DEND";case 40:return this.popState(),t.getLogger().debug("Lex: ))"),"NODE_DEND";case 43:return this.popState(),t.getLogger().debug("Lex: (-"),"NODE_DEND";case 44:return this.popState(),t.getLogger().debug("Lex: -)"),"NODE_DEND";case 46:return this.popState(),t.getLogger().debug("Lex: ]]"),"NODE_DEND";case 47:return this.popState(),t.getLogger().debug("Lex: ("),"NODE_DEND";case 48:return this.popState(),t.getLogger().debug("Lex: ])"),"NODE_DEND";case 49:case 50:return this.popState(),t.getLogger().debug("Lex: /]"),"NODE_DEND";case 51:return this.popState(),t.getLogger().debug("Lex: )]"),"NODE_DEND";case 52:return this.popState(),t.getLogger().debug("Lex: )"),"NODE_DEND";case 53:return this.popState(),t.getLogger().debug("Lex: ]>"),"NODE_DEND";case 54:return this.popState(),t.getLogger().debug("Lex: ]"),"NODE_DEND";case 55:return t.getLogger().debug("Lexa: -)"),this.pushState("NODE"),36;case 56:return t.getLogger().debug("Lexa: (-"),this.pushState("NODE"),36;case 57:return t.getLogger().debug("Lexa: ))"),this.pushState("NODE"),36;case 58:case 60:case 61:case 62:case 65:return t.getLogger().debug("Lexa: )"),this.pushState("NODE"),36;case 59:return t.getLogger().debug("Lex: ((("),this.pushState("NODE"),36;case 63:return t.getLogger().debug("Lexc: >"),this.pushState("NODE"),36;case 64:return t.getLogger().debug("Lexa: (["),this.pushState("NODE"),36;case 66:case 67:case 68:case 69:case 70:case 71:case 72:return this.pushState("NODE"),36;case 73:return t.getLogger().debug("Lexa: ["),this.pushState("NODE"),36;case 74:return this.pushState("BLOCK_ARROW"),t.getLogger().debug("LEX ARR START"),38;case 75:return t.getLogger().debug("Lex: NODE_ID",e.yytext),32;case 76:return t.getLogger().debug("Lex: EOF",e.yytext),8;case 79:return"NODE_DESCR";case 81:t.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 82:t.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 83:return t.getLogger().debug("LEX: NODE_DESCR:",e.yytext),"NODE_DESCR";case 84:t.getLogger().debug("LEX POPPING"),this.popState();break;case 85:t.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 86:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (right): dir:",e.yytext),"DIR";case 87:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (left):",e.yytext),"DIR";case 88:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (x):",e.yytext),"DIR";case 89:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (y):",e.yytext),"DIR";case 90:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (up):",e.yytext),"DIR";case 91:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (down):",e.yytext),"DIR";case 92:return e.yytext="]>",t.getLogger().debug("Lex (ARROW_DIR end):",e.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 93:return t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 94:case 95:case 96:return t.getLogger().debug("Lex: LINK",e.yytext),15;case 97:case 98:case 99:return t.getLogger().debug("Lex: START_LINK",e.yytext),this.pushState("LLABEL"),16;case 101:return t.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 102:return this.popState(),t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 103:case 104:return this.popState(),t.getLogger().debug("Lex: LINK",e.yytext),15;case 105:return t.getLogger().debug("Lex: COLON",e.yytext),e.yytext=e.yytext.slice(1),27}}),"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block\s+)/,/^(?:block\n+)/,/^(?:block:)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[29],inclusive:!1},STYLE_STMNT:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[23],inclusive:!1},CLASSDEF:{rules:[21,22],inclusive:!1},CLASS_STYLE:{rules:[26],inclusive:!1},CLASS:{rules:[25],inclusive:!1},LLABEL:{rules:[100,101,102,103,104],inclusive:!1},ARROW_DIR:{rules:[86,87,88,89,90,91,92],inclusive:!1},BLOCK_ARROW:{rules:[77,82,85],inclusive:!1},NODE:{rules:[38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,78,81],inclusive:!1},md_string:{rules:[10,11,79,80],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[13,14,83,84],inclusive:!1},acc_descr_multiline:{rules:[35,36],inclusive:!1},acc_descr:{rules:[33],inclusive:!1},acc_title:{rules:[31],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,12,15,16,17,18,19,20,24,27,30,32,34,37,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,93,94,95,96,97,98,99,105],inclusive:!0}}}}();function x(){this.yy={}}return y.lexer=v,(0,o.eW)(x,"Parser"),x.prototype=y,y.Parser=x,new x}();p.parser=p;var g=p,f=new Map,m=[],y=new Map,v="color",x="fill",b=(0,o.nV)(),w=new Map,k=(0,o.eW)((t=>o.SY.sanitizeText(t,b)),"sanitizeText"),T=(0,o.eW)((function(t,e=""){let n=w.get(t);n||(n={id:t,styles:[],textStyles:[]},w.set(t,n)),null!=e&&e.split(",").forEach((t=>{const e=t.replace(/([^;]*);/,"$1").trim();if(RegExp(v).exec(t)){const t=e.replace(x,"bgFill").replace(v,x);n.textStyles.push(t)}n.styles.push(e)}))}),"addStyleClass"),_=(0,o.eW)((function(t,e=""){const n=f.get(t);null!=e&&(n.styles=e.split(","))}),"addStyle2Node"),E=(0,o.eW)((function(t,e){t.split(",").forEach((function(t){let n=f.get(t);if(void 0===n){const e=t.trim();n={id:e,type:"na",children:[]},f.set(e,n)}n.classes||(n.classes=[]),n.classes.push(e)}))}),"setCssClass"),S=(0,o.eW)(((t,e)=>{const n=t.flat(),r=[];for(const t of n)if(t.label&&(t.label=k(t.label)),"classDef"!==t.type)if("applyClass"!==t.type)if("applyStyles"!==t.type)if("column-setting"===t.type)e.columns=t.columns??-1;else if("edge"===t.type){const e=(y.get(t.id)??0)+1;y.set(t.id,e),t.id=e+"-"+t.id,m.push(t)}else{t.label||("composite"===t.type?t.label="":t.label=t.id);const e=f.get(t.id);if(void 0===e?f.set(t.id,t):("na"!==t.type&&(e.type=t.type),t.label!==t.id&&(e.label=t.label)),t.children&&S(t.children,t),"space"===t.type){const e=t.width??1;for(let n=0;n{o.cM.debug("Clear called"),(0,o.ZH)(),A={id:"root",type:"composite",children:[],columns:-1},f=new Map([["root",A]]),C=[],w=new Map,m=[],y=new Map}),"clear");function M(t){switch(o.cM.debug("typeStr2Type",t),t){case"[]":return"square";case"()":return o.cM.debug("we have a round"),"round";case"(())":return"circle";case">]":return"rect_left_inv_arrow";case"{}":return"diamond";case"{{}}":return"hexagon";case"([])":return"stadium";case"[[]]":return"subroutine";case"[()]":return"cylinder";case"((()))":return"doublecircle";case"[//]":return"lean_right";case"[\\\\]":return"lean_left";case"[/\\]":return"trapezoid";case"[\\/]":return"inv_trapezoid";case"<[]>":return"block_arrow";default:return"na"}}function N(t){return o.cM.debug("typeStr2Type",t),"=="===t?"thick":"normal"}function I(t){switch(t.trim()){case"--x":return"arrow_cross";case"--o":return"arrow_circle";default:return"arrow_point"}}(0,o.eW)(M,"typeStr2Type"),(0,o.eW)(N,"edgeTypeStr2Type"),(0,o.eW)(I,"edgeStrToEdgeData");var R=0,D=(0,o.eW)((()=>(R++,"id-"+Math.random().toString(36).substr(2,12)+"-"+R)),"generateId"),O=(0,o.eW)((t=>{A.children=t,S(t,A),C=A.children}),"setHierarchy"),P=(0,o.eW)((t=>{const e=f.get(t);return e?e.columns?e.columns:e.children?e.children.length:-1:-1}),"getColumns"),$=(0,o.eW)((()=>[...f.values()]),"getBlocksFlat"),B=(0,o.eW)((()=>C||[]),"getBlocks"),F=(0,o.eW)((()=>m),"getEdges"),W=(0,o.eW)((t=>f.get(t)),"getBlock"),z=(0,o.eW)((t=>{f.set(t.id,t)}),"setBlock"),Z=(0,o.eW)((()=>console),"getLogger"),Y=(0,o.eW)((function(){return w}),"getClasses"),U={getConfig:(0,o.eW)((()=>(0,o.iE)().block),"getConfig"),typeStr2Type:M,edgeTypeStr2Type:N,edgeStrToEdgeData:I,getLogger:Z,getBlocksFlat:$,getBlocks:B,getEdges:F,setHierarchy:O,getBlock:W,setBlock:z,getColumns:P,getClasses:Y,clear:L,generateId:D},G=(0,o.eW)(((t,e)=>{const n=c.Z,r=n(t,"r"),i=n(t,"g"),a=n(t,"b");return h.Z(r,i,a,e)}),"fade"),V=(0,o.eW)((t=>`.label {\n font-family: ${t.fontFamily};\n color: ${t.nodeTextColor||t.textColor};\n }\n .cluster-label text {\n fill: ${t.titleColor};\n }\n .cluster-label span,p {\n color: ${t.titleColor};\n }\n\n\n\n .label text,span,p {\n fill: ${t.nodeTextColor||t.textColor};\n color: ${t.nodeTextColor||t.textColor};\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n stroke-width: 1px;\n }\n .flowchart-label text {\n text-anchor: middle;\n }\n // .flowchart-label .text-outer-tspan {\n // text-anchor: middle;\n // }\n // .flowchart-label .text-inner-tspan {\n // text-anchor: start;\n // }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ${t.arrowheadColor};\n }\n\n .edgePath .path {\n stroke: ${t.lineColor};\n stroke-width: 2.0px;\n }\n\n .flowchart-link {\n stroke: ${t.lineColor};\n fill: none;\n }\n\n .edgeLabel {\n background-color: ${t.edgeLabelBackground};\n rect {\n opacity: 0.5;\n background-color: ${t.edgeLabelBackground};\n fill: ${t.edgeLabelBackground};\n }\n text-align: center;\n }\n\n /* For html labels only */\n .labelBkg {\n background-color: ${G(t.edgeLabelBackground,.5)};\n // background-color:\n }\n\n .node .cluster {\n // fill: ${G(t.mainBkg,.5)};\n fill: ${G(t.clusterBkg,.5)};\n stroke: ${G(t.clusterBorder,.2)};\n box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;\n stroke-width: 1px;\n }\n\n .cluster text {\n fill: ${t.titleColor};\n }\n\n .cluster span,p {\n color: ${t.titleColor};\n }\n /* .cluster div {\n color: ${t.titleColor};\n } */\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ${t.fontFamily};\n font-size: 12px;\n background: ${t.tertiaryColor};\n border: 1px solid ${t.border2};\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .flowchartTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${t.textColor};\n }\n`),"getStyles"),q=(0,o.eW)(((t,e,n,r)=>{e.forEach((e=>{j[e](t,n,r)}))}),"insertMarkers"),j={extension:(0,o.eW)(((t,e,n)=>{o.cM.trace("Making markers for ",n),t.append("defs").append("marker").attr("id",n+"_"+e+"-extensionStart").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")}),"extension"),composition:(0,o.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-compositionStart").attr("class","marker composition "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")}),"composition"),aggregation:(0,o.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")}),"aggregation"),dependency:(0,o.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")}),"dependency"),lollipop:(0,o.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-lollipopStart").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),t.append("defs").append("marker").attr("id",n+"_"+e+"-lollipopEnd").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)}),"lollipop"),point:(0,o.eW)(((t,e,n)=>{t.append("marker").attr("id",n+"_"+e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",6).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",n+"_"+e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")}),"point"),circle:(0,o.eW)(((t,e,n)=>{t.append("marker").attr("id",n+"_"+e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",n+"_"+e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")}),"circle"),cross:(0,o.eW)(((t,e,n)=>{t.append("marker").attr("id",n+"_"+e+"-crossEnd").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),t.append("marker").attr("id",n+"_"+e+"-crossStart").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")}),"cross"),barb:(0,o.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")}),"barb")},H=q,X=(0,o.nV)()?.block?.padding??8;function K(t,e){if(0===t||!Number.isInteger(t))throw new Error("Columns must be an integer !== 0.");if(e<0||!Number.isInteger(e))throw new Error("Position must be a non-negative integer."+e);return t<0?{px:e,py:0}:1===t?{px:0,py:e}:{px:e%t,py:Math.floor(e/t)}}(0,o.eW)(K,"calculateBlockPosition");var Q=(0,o.eW)((t=>{let e=0,n=0;for(const r of t.children){const{width:i,height:a,x:s,y:l}=r.size??{width:0,height:0,x:0,y:0};o.cM.debug("getMaxChildSize abc95 child:",r.id,"width:",i,"height:",a,"x:",s,"y:",l,r.type),"space"!==r.type&&(i>e&&(e=i/(t.widthInColumns??1)),a>n&&(n=a))}return{width:e,height:n}}),"getMaxChildSize");function J(t,e,n=0,r=0){o.cM.debug("setBlockSizes abc95 (start)",t.id,t?.size?.x,"block width =",t?.size,"sieblingWidth",n),t?.size?.width||(t.size={width:n,height:r,x:0,y:0});let i=0,a=0;if(t.children?.length>0){for(const n of t.children)J(n,e);const s=Q(t);i=s.width,a=s.height,o.cM.debug("setBlockSizes abc95 maxWidth of",t.id,":s children is ",i,a);for(const e of t.children)e.size&&(o.cM.debug(`abc95 Setting size of children of ${t.id} id=${e.id} ${i} ${a} ${JSON.stringify(e.size)}`),e.size.width=i*(e.widthInColumns??1)+X*((e.widthInColumns??1)-1),e.size.height=a,e.size.x=0,e.size.y=0,o.cM.debug(`abc95 updating size of ${t.id} children child:${e.id} maxWidth:${i} maxHeight:${a}`));for(const n of t.children)J(n,e,i,a);const l=t.columns??-1;let c=0;for(const e of t.children)c+=e.widthInColumns??1;let h=t.children.length;l>0&&l0?Math.min(t.children.length,l):t.children.length;if(e>0){const n=(d-e*X-X)/e;o.cM.debug("abc95 (growing to fit) width",t.id,d,t.size?.width,n);for(const e of t.children)e.size&&(e.size.width=n)}}t.size={width:d,height:p,x:0,y:0}}o.cM.debug("setBlockSizes abc94 (done)",t.id,t?.size?.x,t?.size?.width,t?.size?.y,t?.size?.height)}function tt(t,e){o.cM.debug(`abc85 layout blocks (=>layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`);const n=t.columns??-1;if(o.cM.debug("layoutBlocks columns abc95",t.id,"=>",n,t),t.children&&t.children.length>0){const r=t?.children[0]?.size?.width??0,i=t.children.length*r+(t.children.length-1)*X;o.cM.debug("widthOfChildren 88",i,"posX");let a=0;o.cM.debug("abc91 block?.size?.x",t.id,t?.size?.x);let s=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-X,l=0;for(const r of t.children){const i=t;if(!r.size)continue;const{width:c,height:h}=r.size,{px:u,py:d}=K(n,a);if(d!=l&&(l=d,s=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-X,o.cM.debug("New row in layout for block",t.id," and child ",r.id,l)),o.cM.debug(`abc89 layout blocks (child) id: ${r.id} Pos: ${a} (px, py) ${u},${d} (${i?.size?.x},${i?.size?.y}) parent: ${i.id} width: ${c}${X}`),i.size){const t=c/2;r.size.x=s+X+t,o.cM.debug(`abc91 layout blocks (calc) px, pyid:${r.id} startingPos=X${s} new startingPosX${r.size.x} ${t} padding=${X} width=${c} halfWidth=${t} => x:${r.size.x} y:${r.size.y} ${r.widthInColumns} (width * (child?.w || 1)) / 2 ${c*(r?.widthInColumns??1)/2}`),s=r.size.x+t,r.size.y=i.size.y-i.size.height/2+d*(h+X)+h/2+X,o.cM.debug(`abc88 layout blocks (calc) px, pyid:${r.id}startingPosX${s}${X}${t}=>x:${r.size.x}y:${r.size.y}${r.widthInColumns}(width * (child?.w || 1)) / 2${c*(r?.widthInColumns??1)/2}`)}r.children&&tt(r,e),a+=r?.widthInColumns??1,o.cM.debug("abc88 columnsPos",r,a)}}o.cM.debug(`layout blocks (<==layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`)}function et(t,{minX:e,minY:n,maxX:r,maxY:i}={minX:0,minY:0,maxX:0,maxY:0}){if(t.size&&"root"!==t.id){const{x:a,y:s,width:o,height:l}=t.size;a-o/2r&&(r=a+o/2),s+l/2>i&&(i=s+l/2)}if(t.children)for(const a of t.children)({minX:e,minY:n,maxX:r,maxY:i}=et(a,{minX:e,minY:n,maxX:r,maxY:i}));return{minX:e,minY:n,maxX:r,maxY:i}}function nt(t){const e=t.getBlock("root");if(!e)return;J(e,t,0,0),tt(e,t),o.cM.debug("getBlocks",JSON.stringify(e,null,2));const{minX:n,minY:r,maxX:i,maxY:a}=et(e);return{x:n,y:r,width:i-n,height:a-r}}function rt(t,e){e&&t.attr("style",e)}function it(t){const e=(0,u.Ys)(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),n=e.append("xhtml:div"),r=t.label,i=t.isNode?"nodeLabel":"edgeLabel",a=n.append("span");return a.html(r),rt(a,t.labelStyle),a.attr("class",i),rt(n,t.labelStyle),n.style("display","inline-block"),n.style("white-space","nowrap"),n.attr("xmlns","http://www.w3.org/1999/xhtml"),e.node()}(0,o.eW)(J,"setBlockSizes"),(0,o.eW)(tt,"layoutBlocks"),(0,o.eW)(et,"findBounds"),(0,o.eW)(nt,"layout"),(0,o.eW)(rt,"applyStyle"),(0,o.eW)(it,"addHtmlLabel");var at=(0,o.eW)(((t,e,n,r)=>{let i=t||"";if("object"==typeof i&&(i=i[0]),(0,o.ku)((0,o.nV)().flowchart.htmlLabels))return i=i.replace(/\\n|\n/g,"
"),o.cM.debug("vertexText"+i),it({isNode:r,label:(0,a.EY)((0,s.SH)(i)),labelStyle:e.replace("fill:","color:")});{const t=document.createElementNS("http://www.w3.org/2000/svg","text");t.setAttribute("style",e.replace("color:","fill:"));let r=[];r="string"==typeof i?i.split(/\\n|\n|/gi):Array.isArray(i)?i:[];for(const e of r){const r=document.createElementNS("http://www.w3.org/2000/svg","tspan");r.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.setAttribute("dy","1em"),r.setAttribute("x","0"),n?r.setAttribute("class","title-row"):r.setAttribute("class","row"),r.textContent=e.trim(),t.appendChild(r)}return t}}),"createLabel"),st=(0,o.eW)(((t,e,n,r,i)=>{e.arrowTypeStart&<(t,"start",e.arrowTypeStart,n,r,i),e.arrowTypeEnd&<(t,"end",e.arrowTypeEnd,n,r,i)}),"addEdgeMarkers"),ot={arrow_cross:"cross",arrow_point:"point",arrow_barb:"barb",arrow_circle:"circle",aggregation:"aggregation",extension:"extension",composition:"composition",dependency:"dependency",lollipop:"lollipop"},lt=(0,o.eW)(((t,e,n,r,i,a)=>{const s=ot[n];if(!s)return void o.cM.warn(`Unknown arrow type: ${n}`);const l="start"===e?"Start":"End";t.attr(`marker-${e}`,`url(${r}#${i}_${a}-${s}${l})`)}),"addEdgeMarker"),ct={},ht={},ut=(0,o.eW)(((t,e)=>{const n=(0,o.nV)(),r=(0,o.ku)(n.flowchart.htmlLabels),i="markdown"===e.labelType?(0,a.rw)(t,e.label,{style:e.labelStyle,useHtmlLabels:r,addSvgBackground:!0},n):at(e.label,e.labelStyle),s=t.insert("g").attr("class","edgeLabel"),l=s.insert("g").attr("class","label");l.node().appendChild(i);let c,h=i.getBBox();if(r){const t=i.children[0],e=(0,u.Ys)(i);h=t.getBoundingClientRect(),e.attr("width",h.width),e.attr("height",h.height)}if(l.attr("transform","translate("+-h.width/2+", "+-h.height/2+")"),ct[e.id]=s,e.width=h.width,e.height=h.height,e.startLabelLeft){const n=at(e.startLabelLeft,e.labelStyle),r=t.insert("g").attr("class","edgeTerminals"),i=r.insert("g").attr("class","inner");c=i.node().appendChild(n);const a=n.getBBox();i.attr("transform","translate("+-a.width/2+", "+-a.height/2+")"),ht[e.id]||(ht[e.id]={}),ht[e.id].startLeft=r,dt(c,e.startLabelLeft)}if(e.startLabelRight){const n=at(e.startLabelRight,e.labelStyle),r=t.insert("g").attr("class","edgeTerminals"),i=r.insert("g").attr("class","inner");c=r.node().appendChild(n),i.node().appendChild(n);const a=n.getBBox();i.attr("transform","translate("+-a.width/2+", "+-a.height/2+")"),ht[e.id]||(ht[e.id]={}),ht[e.id].startRight=r,dt(c,e.startLabelRight)}if(e.endLabelLeft){const n=at(e.endLabelLeft,e.labelStyle),r=t.insert("g").attr("class","edgeTerminals"),i=r.insert("g").attr("class","inner");c=i.node().appendChild(n);const a=n.getBBox();i.attr("transform","translate("+-a.width/2+", "+-a.height/2+")"),r.node().appendChild(n),ht[e.id]||(ht[e.id]={}),ht[e.id].endLeft=r,dt(c,e.endLabelLeft)}if(e.endLabelRight){const n=at(e.endLabelRight,e.labelStyle),r=t.insert("g").attr("class","edgeTerminals"),i=r.insert("g").attr("class","inner");c=i.node().appendChild(n);const a=n.getBBox();i.attr("transform","translate("+-a.width/2+", "+-a.height/2+")"),r.node().appendChild(n),ht[e.id]||(ht[e.id]={}),ht[e.id].endRight=r,dt(c,e.endLabelRight)}return i}),"insertEdgeLabel");function dt(t,e){(0,o.nV)().flowchart.htmlLabels&&t&&(t.style.width=9*e.length+"px",t.style.height="12px")}(0,o.eW)(dt,"setTerminalWidth");var pt=(0,o.eW)(((t,e)=>{o.cM.debug("Moving label abc88 ",t.id,t.label,ct[t.id],e);let n=e.updatedPath?e.updatedPath:e.originalPath;const r=(0,o.nV)(),{subGraphTitleTotalMargin:a}=(0,i.L)(r);if(t.label){const r=ct[t.id];let i=t.x,l=t.y;if(n){const r=s.w8.calcLabelPosition(n);o.cM.debug("Moving label "+t.label+" from (",i,",",l,") to (",r.x,",",r.y,") abc88"),e.updatedPath&&(i=r.x,l=r.y)}r.attr("transform",`translate(${i}, ${l+a/2})`)}if(t.startLabelLeft){const e=ht[t.id].startLeft;let r=t.x,i=t.y;if(n){const e=s.w8.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_left",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}if(t.startLabelRight){const e=ht[t.id].startRight;let r=t.x,i=t.y;if(n){const e=s.w8.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_right",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}if(t.endLabelLeft){const e=ht[t.id].endLeft;let r=t.x,i=t.y;if(n){const e=s.w8.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_left",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}if(t.endLabelRight){const e=ht[t.id].endRight;let r=t.x,i=t.y;if(n){const e=s.w8.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_right",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}}),"positionEdgeLabel"),gt=(0,o.eW)(((t,e)=>{const n=t.x,r=t.y,i=Math.abs(e.x-n),a=Math.abs(e.y-r),s=t.width/2,o=t.height/2;return i>=s||a>=o}),"outsideNode"),ft=(0,o.eW)(((t,e,n)=>{o.cM.debug(`intersection calc abc89:\n outsidePoint: ${JSON.stringify(e)}\n insidePoint : ${JSON.stringify(n)}\n node : x:${t.x} y:${t.y} w:${t.width} h:${t.height}`);const r=t.x,i=t.y,a=Math.abs(r-n.x),s=t.width/2;let l=n.xMath.abs(r-e.x)*c){let t=n.y{o.cM.debug("abc88 cutPathAtIntersect",t,e);let n=[],r=t[0],i=!1;return t.forEach((t=>{if(gt(e,t)||i)r=t,i||n.push(t);else{const a=ft(e,r,t);let s=!1;n.forEach((t=>{s=s||t.x===a.x&&t.y===a.y})),n.some((t=>t.x===a.x&&t.y===a.y))||n.push(a),i=!0}})),n}),"cutPathAtIntersect"),yt=(0,o.eW)((function(t,e,n,i,a,s,l){let c=n.points;o.cM.debug("abc88 InsertEdge: edge=",n,"e=",e);let h=!1;const d=s.node(e.v);var p=s.node(e.w);p?.intersect&&d?.intersect&&(c=c.slice(1,n.points.length-1),c.unshift(d.intersect(c[0])),c.push(p.intersect(c[c.length-1]))),n.toCluster&&(o.cM.debug("to cluster abc88",i[n.toCluster]),c=mt(n.points,i[n.toCluster].node),h=!0),n.fromCluster&&(o.cM.debug("from cluster abc88",i[n.fromCluster]),c=mt(c.reverse(),i[n.fromCluster].node).reverse(),h=!0);const g=c.filter((t=>!Number.isNaN(t.y)));let f=u.$0Z;!n.curve||"graph"!==a&&"flowchart"!==a||(f=n.curve);const{x:m,y}=(0,r.o)(n),v=(0,u.jvg)().x(m).y(y).curve(f);let x;switch(n.thickness){case"normal":x="edge-thickness-normal";break;case"thick":case"invisible":x="edge-thickness-thick";break;default:x=""}switch(n.pattern){case"solid":x+=" edge-pattern-solid";break;case"dotted":x+=" edge-pattern-dotted";break;case"dashed":x+=" edge-pattern-dashed"}const b=t.append("path").attr("d",v(g)).attr("id",n.id).attr("class"," "+x+(n.classes?" "+n.classes:"")).attr("style",n.style);let w="";((0,o.nV)().flowchart.arrowMarkerAbsolute||(0,o.nV)().state.arrowMarkerAbsolute)&&(w=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,w=w.replace(/\(/g,"\\("),w=w.replace(/\)/g,"\\)")),st(b,n,w,l,a);let k={};return h&&(k.updatedPath=c),k.originalPath=n.points,k}),"insertEdge"),vt=(0,o.eW)((t=>{const e=new Set;for(const n of t)switch(n){case"x":e.add("right"),e.add("left");break;case"y":e.add("up"),e.add("down");break;default:e.add(n)}return e}),"expandAndDeduplicateDirections"),xt=(0,o.eW)(((t,e,n)=>{const r=vt(t),i=e.height+2*n.padding,a=i/2,s=e.width+2*a+n.padding,o=n.padding/2;return r.has("right")&&r.has("left")&&r.has("up")&&r.has("down")?[{x:0,y:0},{x:a,y:0},{x:s/2,y:2*o},{x:s-a,y:0},{x:s,y:0},{x:s,y:-i/3},{x:s+2*o,y:-i/2},{x:s,y:-2*i/3},{x:s,y:-i},{x:s-a,y:-i},{x:s/2,y:-i-2*o},{x:a,y:-i},{x:0,y:-i},{x:0,y:-2*i/3},{x:-2*o,y:-i/2},{x:0,y:-i/3}]:r.has("right")&&r.has("left")&&r.has("up")?[{x:a,y:0},{x:s-a,y:0},{x:s,y:-i/2},{x:s-a,y:-i},{x:a,y:-i},{x:0,y:-i/2}]:r.has("right")&&r.has("left")&&r.has("down")?[{x:0,y:0},{x:a,y:-i},{x:s-a,y:-i},{x:s,y:0}]:r.has("right")&&r.has("up")&&r.has("down")?[{x:0,y:0},{x:s,y:-a},{x:s,y:-i+a},{x:0,y:-i}]:r.has("left")&&r.has("up")&&r.has("down")?[{x:s,y:0},{x:0,y:-a},{x:0,y:-i+a},{x:s,y:-i}]:r.has("right")&&r.has("left")?[{x:a,y:0},{x:a,y:-o},{x:s-a,y:-o},{x:s-a,y:0},{x:s,y:-i/2},{x:s-a,y:-i},{x:s-a,y:-i+o},{x:a,y:-i+o},{x:a,y:-i},{x:0,y:-i/2}]:r.has("up")&&r.has("down")?[{x:s/2,y:0},{x:0,y:-o},{x:a,y:-o},{x:a,y:-i+o},{x:0,y:-i+o},{x:s/2,y:-i},{x:s,y:-i+o},{x:s-a,y:-i+o},{x:s-a,y:-o},{x:s,y:-o}]:r.has("right")&&r.has("up")?[{x:0,y:0},{x:s,y:-a},{x:0,y:-i}]:r.has("right")&&r.has("down")?[{x:0,y:0},{x:s,y:0},{x:0,y:-i}]:r.has("left")&&r.has("up")?[{x:s,y:0},{x:0,y:-a},{x:s,y:-i}]:r.has("left")&&r.has("down")?[{x:s,y:0},{x:0,y:0},{x:s,y:-i}]:r.has("right")?[{x:a,y:-o},{x:a,y:-o},{x:s-a,y:-o},{x:s-a,y:0},{x:s,y:-i/2},{x:s-a,y:-i},{x:s-a,y:-i+o},{x:a,y:-i+o},{x:a,y:-i+o}]:r.has("left")?[{x:a,y:0},{x:a,y:-o},{x:s-a,y:-o},{x:s-a,y:-i+o},{x:a,y:-i+o},{x:a,y:-i},{x:0,y:-i/2}]:r.has("up")?[{x:a,y:-o},{x:a,y:-i+o},{x:0,y:-i+o},{x:s/2,y:-i},{x:s,y:-i+o},{x:s-a,y:-i+o},{x:s-a,y:-o}]:r.has("down")?[{x:s/2,y:0},{x:0,y:-o},{x:a,y:-o},{x:a,y:-i+o},{x:s-a,y:-i+o},{x:s-a,y:-o},{x:s,y:-o}]:[{x:0,y:0}]}),"getArrowPoints");function bt(t,e){return t.intersect(e)}(0,o.eW)(bt,"intersectNode");var wt=bt;function kt(t,e,n,r){var i=t.x,a=t.y,s=i-r.x,o=a-r.y,l=Math.sqrt(e*e*o*o+n*n*s*s),c=Math.abs(e*n*s/l);r.x0}(0,o.eW)(St,"intersectLine"),(0,o.eW)(Ct,"sameSign");var At=St,Lt=Mt;function Mt(t,e,n){var r=t.x,i=t.y,a=[],s=Number.POSITIVE_INFINITY,o=Number.POSITIVE_INFINITY;"function"==typeof e.forEach?e.forEach((function(t){s=Math.min(s,t.x),o=Math.min(o,t.y)})):(s=Math.min(s,e.x),o=Math.min(o,e.y));for(var l=r-t.width/2-s,c=i-t.height/2-o,h=0;h1&&a.sort((function(t,e){var r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),s=e.x-n.x,o=e.y-n.y,l=Math.sqrt(s*s+o*o);return a{var n,r,i=t.x,a=t.y,s=e.x-i,o=e.y-a,l=t.width/2,c=t.height/2;return Math.abs(o)*l>Math.abs(s)*c?(o<0&&(c=-c),n=0===o?0:c*s/o,r=c):(s<0&&(l=-l),n=l,r=0===s?0:l*o/s),{x:i+n,y:a+r}}),"intersectRect")},It=(0,o.eW)((async(t,e,n,r)=>{const i=(0,o.nV)();let l;const c=e.useHtmlLabels||(0,o.ku)(i.flowchart.htmlLabels);l=n||"node default";const h=t.insert("g").attr("class",l).attr("id",e.domId||e.id),d=h.insert("g").attr("class","label").attr("style",e.labelStyle);let p;p=void 0===e.labelText?"":"string"==typeof e.labelText?e.labelText:e.labelText[0];const g=d.node();let f;f="markdown"===e.labelType?(0,a.rw)(d,(0,o.oO)((0,s.SH)(p),i),{useHtmlLabels:c,width:e.width||i.flowchart.wrappingWidth,classes:"markdown-node-label"},i):g.appendChild(at((0,o.oO)((0,s.SH)(p),i),e.labelStyle,!1,r));let m=f.getBBox();const y=e.padding/2;if((0,o.ku)(i.flowchart.htmlLabels)){const t=f.children[0],e=(0,u.Ys)(f),n=t.getElementsByTagName("img");if(n){const t=""===p.replace(/]*>/g,"").trim();await Promise.all([...n].map((e=>new Promise((n=>{function r(){if(e.style.display="flex",e.style.flexDirection="column",t){const t=i.fontSize?i.fontSize:window.getComputedStyle(document.body).fontSize,n=5,r=parseInt(t,10)*n+"px";e.style.minWidth=r,e.style.maxWidth=r}else e.style.width="100%";n(e)}(0,o.eW)(r,"setupImage"),setTimeout((()=>{e.complete&&r()})),e.addEventListener("error",r),e.addEventListener("load",r)})))))}m=t.getBoundingClientRect(),e.attr("width",m.width),e.attr("height",m.height)}return c?d.attr("transform","translate("+-m.width/2+", "+-m.height/2+")"):d.attr("transform","translate(0, "+-m.height/2+")"),e.centerLabel&&d.attr("transform","translate("+-m.width/2+", "+-m.height/2+")"),d.insert("rect",":first-child"),{shapeSvg:h,bbox:m,halfPadding:y,label:d}}),"labelHelper"),Rt=(0,o.eW)(((t,e)=>{const n=e.node().getBBox();t.width=n.width,t.height=n.height}),"updateNodeBounds");function Dt(t,e,n,r){return t.insert("polygon",":first-child").attr("points",r.map((function(t){return t.x+","+t.y})).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+n/2+")")}(0,o.eW)(Dt,"insertPolygonShape");var Ot=(0,o.eW)((async(t,e)=>{e.useHtmlLabels||(0,o.nV)().flowchart.htmlLabels||(e.centerLabel=!0);const{shapeSvg:n,bbox:r,halfPadding:i}=await It(t,e,"node "+e.classes,!0);o.cM.info("Classes = ",e.classes);const a=n.insert("rect",":first-child");return a.attr("rx",e.rx).attr("ry",e.ry).attr("x",-r.width/2-i).attr("y",-r.height/2-i).attr("width",r.width+e.padding).attr("height",r.height+e.padding),Rt(e,a),e.intersect=function(t){return Nt.rect(e,t)},n}),"note"),Pt=(0,o.eW)((t=>t?" "+t:""),"formatClass"),$t=(0,o.eW)(((t,e)=>`${e||"node default"}${Pt(t.classes)} ${Pt(t.class)}`),"getClassesFromNode"),Bt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding+(r.height+e.padding),a=[{x:i/2,y:0},{x:i,y:-i/2},{x:i/2,y:-i},{x:0,y:-i/2}];o.cM.info("Question main (Circle)");const s=Dt(n,i,i,a);return s.attr("style",e.style),Rt(e,s),e.intersect=function(t){return o.cM.warn("Intersect called"),Nt.polygon(e,a,t)},n}),"question"),Ft=(0,o.eW)(((t,e)=>{const n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id);return n.insert("polygon",":first-child").attr("points",[{x:0,y:14},{x:14,y:0},{x:0,y:-14},{x:-14,y:0}].map((function(t){return t.x+","+t.y})).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),e.width=28,e.height=28,e.intersect=function(t){return Nt.circle(e,14,t)},n}),"choice"),Wt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.height+e.padding,a=i/4,s=r.width+2*a+e.padding,o=[{x:a,y:0},{x:s-a,y:0},{x:s,y:-i/2},{x:s-a,y:-i},{x:a,y:-i},{x:0,y:-i/2}],l=Dt(n,s,i,o);return l.attr("style",e.style),Rt(e,l),e.intersect=function(t){return Nt.polygon(e,o,t)},n}),"hexagon"),zt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,void 0,!0),i=r.height+2*e.padding,a=i/2,s=r.width+2*a+e.padding,o=xt(e.directions,r,e),l=Dt(n,s,i,o);return l.attr("style",e.style),Rt(e,l),e.intersect=function(t){return Nt.polygon(e,o,t)},n}),"block_arrow"),Zt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding,a=r.height+e.padding,s=[{x:-a/2,y:0},{x:i,y:0},{x:i,y:-a},{x:-a/2,y:-a},{x:0,y:-a/2}];return Dt(n,i,a,s).attr("style",e.style),e.width=i+a,e.height=a,e.intersect=function(t){return Nt.polygon(e,s,t)},n}),"rect_left_inv_arrow"),Yt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e),!0),i=r.width+e.padding,a=r.height+e.padding,s=[{x:-2*a/6,y:0},{x:i-a/6,y:0},{x:i+2*a/6,y:-a},{x:a/6,y:-a}],o=Dt(n,i,a,s);return o.attr("style",e.style),Rt(e,o),e.intersect=function(t){return Nt.polygon(e,s,t)},n}),"lean_right"),Ut=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding,a=r.height+e.padding,s=[{x:2*a/6,y:0},{x:i+a/6,y:0},{x:i-2*a/6,y:-a},{x:-a/6,y:-a}],o=Dt(n,i,a,s);return o.attr("style",e.style),Rt(e,o),e.intersect=function(t){return Nt.polygon(e,s,t)},n}),"lean_left"),Gt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding,a=r.height+e.padding,s=[{x:-2*a/6,y:0},{x:i+2*a/6,y:0},{x:i-a/6,y:-a},{x:a/6,y:-a}],o=Dt(n,i,a,s);return o.attr("style",e.style),Rt(e,o),e.intersect=function(t){return Nt.polygon(e,s,t)},n}),"trapezoid"),Vt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding,a=r.height+e.padding,s=[{x:a/6,y:0},{x:i-a/6,y:0},{x:i+2*a/6,y:-a},{x:-2*a/6,y:-a}],o=Dt(n,i,a,s);return o.attr("style",e.style),Rt(e,o),e.intersect=function(t){return Nt.polygon(e,s,t)},n}),"inv_trapezoid"),qt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding,a=r.height+e.padding,s=[{x:0,y:0},{x:i+a/2,y:0},{x:i,y:-a/2},{x:i+a/2,y:-a},{x:0,y:-a}],o=Dt(n,i,a,s);return o.attr("style",e.style),Rt(e,o),e.intersect=function(t){return Nt.polygon(e,s,t)},n}),"rect_right_inv_arrow"),jt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding,a=i/2,s=a/(2.5+i/50),o=r.height+s+e.padding,l="M 0,"+s+" a "+a+","+s+" 0,0,0 "+i+" 0 a "+a+","+s+" 0,0,0 "+-i+" 0 l 0,"+o+" a "+a+","+s+" 0,0,0 "+i+" 0 l 0,"+-o,c=n.attr("label-offset-y",s).insert("path",":first-child").attr("style",e.style).attr("d",l).attr("transform","translate("+-i/2+","+-(o/2+s)+")");return Rt(e,c),e.intersect=function(t){const n=Nt.rect(e,t),r=n.x-e.x;if(0!=a&&(Math.abs(r)e.height/2-s)){let i=s*s*(1-r*r/(a*a));0!=i&&(i=Math.sqrt(i)),i=s-i,t.y-e.y>0&&(i=-i),n.y+=i}return n},n}),"cylinder"),Ht=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r,halfPadding:i}=await It(t,e,"node "+e.classes+" "+e.class,!0),a=n.insert("rect",":first-child"),s=e.positioned?e.width:r.width+e.padding,l=e.positioned?e.height:r.height+e.padding,c=e.positioned?-s/2:-r.width/2-i,h=e.positioned?-l/2:-r.height/2-i;if(a.attr("class","basic label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",c).attr("y",h).attr("width",s).attr("height",l),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(Qt(a,e.props.borders,s,l),t.delete("borders")),t.forEach((t=>{o.cM.warn(`Unknown node property ${t}`)}))}return Rt(e,a),e.intersect=function(t){return Nt.rect(e,t)},n}),"rect"),Xt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r,halfPadding:i}=await It(t,e,"node "+e.classes,!0),a=n.insert("rect",":first-child"),s=e.positioned?e.width:r.width+e.padding,l=e.positioned?e.height:r.height+e.padding,c=e.positioned?-s/2:-r.width/2-i,h=e.positioned?-l/2:-r.height/2-i;if(a.attr("class","basic cluster composite label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",c).attr("y",h).attr("width",s).attr("height",l),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(Qt(a,e.props.borders,s,l),t.delete("borders")),t.forEach((t=>{o.cM.warn(`Unknown node property ${t}`)}))}return Rt(e,a),e.intersect=function(t){return Nt.rect(e,t)},n}),"composite"),Kt=(0,o.eW)((async(t,e)=>{const{shapeSvg:n}=await It(t,e,"label",!0);o.cM.trace("Classes = ",e.class);const r=n.insert("rect",":first-child");if(r.attr("width",0).attr("height",0),n.attr("class","label edgeLabel"),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(Qt(r,e.props.borders,0,0),t.delete("borders")),t.forEach((t=>{o.cM.warn(`Unknown node property ${t}`)}))}return Rt(e,r),e.intersect=function(t){return Nt.rect(e,t)},n}),"labelRect");function Qt(t,e,n,r){const i=[],a=(0,o.eW)((t=>{i.push(t,0)}),"addBorder"),s=(0,o.eW)((t=>{i.push(0,t)}),"skipBorder");e.includes("t")?(o.cM.debug("add top border"),a(n)):s(n),e.includes("r")?(o.cM.debug("add right border"),a(r)):s(r),e.includes("b")?(o.cM.debug("add bottom border"),a(n)):s(n),e.includes("l")?(o.cM.debug("add left border"),a(r)):s(r),t.attr("stroke-dasharray",i.join(" "))}(0,o.eW)(Qt,"applyNodePropertyBorders");var Jt=(0,o.eW)(((t,e)=>{let n;n=e.classes?"node "+e.classes:"node default";const r=t.insert("g").attr("class",n).attr("id",e.domId||e.id),i=r.insert("rect",":first-child"),a=r.insert("line"),s=r.insert("g").attr("class","label"),l=e.labelText.flat?e.labelText.flat():e.labelText;let c="";c="object"==typeof l?l[0]:l,o.cM.info("Label text abc79",c,l,"object"==typeof l);const h=s.node().appendChild(at(c,e.labelStyle,!0,!0));let d={width:0,height:0};if((0,o.ku)((0,o.nV)().flowchart.htmlLabels)){const t=h.children[0],e=(0,u.Ys)(h);d=t.getBoundingClientRect(),e.attr("width",d.width),e.attr("height",d.height)}o.cM.info("Text 2",l);const p=l.slice(1,l.length);let g=h.getBBox();const f=s.node().appendChild(at(p.join?p.join("
"):p,e.labelStyle,!0,!0));if((0,o.ku)((0,o.nV)().flowchart.htmlLabels)){const t=f.children[0],e=(0,u.Ys)(f);d=t.getBoundingClientRect(),e.attr("width",d.width),e.attr("height",d.height)}const m=e.padding/2;return(0,u.Ys)(f).attr("transform","translate( "+(d.width>g.width?0:(g.width-d.width)/2)+", "+(g.height+m+5)+")"),(0,u.Ys)(h).attr("transform","translate( "+(d.width{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.height+e.padding,a=r.width+i/4+e.padding,s=n.insert("rect",":first-child").attr("style",e.style).attr("rx",i/2).attr("ry",i/2).attr("x",-a/2).attr("y",-i/2).attr("width",a).attr("height",i);return Rt(e,s),e.intersect=function(t){return Nt.rect(e,t)},n}),"stadium"),ee=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r,halfPadding:i}=await It(t,e,$t(e,void 0),!0),a=n.insert("circle",":first-child");return a.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",r.width/2+i).attr("width",r.width+e.padding).attr("height",r.height+e.padding),o.cM.info("Circle main"),Rt(e,a),e.intersect=function(t){return o.cM.info("Circle intersect",e,r.width/2+i,t),Nt.circle(e,r.width/2+i,t)},n}),"circle"),ne=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r,halfPadding:i}=await It(t,e,$t(e,void 0),!0),a=n.insert("g",":first-child"),s=a.insert("circle"),l=a.insert("circle");return a.attr("class",e.class),s.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",r.width/2+i+5).attr("width",r.width+e.padding+10).attr("height",r.height+e.padding+10),l.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",r.width/2+i).attr("width",r.width+e.padding).attr("height",r.height+e.padding),o.cM.info("DoubleCircle main"),Rt(e,s),e.intersect=function(t){return o.cM.info("DoubleCircle intersect",e,r.width/2+i+5,t),Nt.circle(e,r.width/2+i+5,t)},n}),"doublecircle"),re=(0,o.eW)((async(t,e)=>{const{shapeSvg:n,bbox:r}=await It(t,e,$t(e,void 0),!0),i=r.width+e.padding,a=r.height+e.padding,s=[{x:0,y:0},{x:i,y:0},{x:i,y:-a},{x:0,y:-a},{x:0,y:0},{x:-8,y:0},{x:i+8,y:0},{x:i+8,y:-a},{x:-8,y:-a},{x:-8,y:0}],o=Dt(n,i,a,s);return o.attr("style",e.style),Rt(e,o),e.intersect=function(t){return Nt.polygon(e,s,t)},n}),"subroutine"),ie=(0,o.eW)(((t,e)=>{const n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),r=n.insert("circle",":first-child");return r.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),Rt(e,r),e.intersect=function(t){return Nt.circle(e,7,t)},n}),"start"),ae=(0,o.eW)(((t,e,n)=>{const r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id);let i=70,a=10;"LR"===n&&(i=10,a=70);const s=r.append("rect").attr("x",-1*i/2).attr("y",-1*a/2).attr("width",i).attr("height",a).attr("class","fork-join");return Rt(e,s),e.height=e.height+e.padding/2,e.width=e.width+e.padding/2,e.intersect=function(t){return Nt.rect(e,t)},r}),"forkJoin"),se={rhombus:Bt,composite:Xt,question:Bt,rect:Ht,labelRect:Kt,rectWithTitle:Jt,choice:Ft,circle:ee,doublecircle:ne,stadium:te,hexagon:Wt,block_arrow:zt,rect_left_inv_arrow:Zt,lean_right:Yt,lean_left:Ut,trapezoid:Gt,inv_trapezoid:Vt,rect_right_inv_arrow:qt,cylinder:jt,start:ie,end:(0,o.eW)(((t,e)=>{const n=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),r=n.insert("circle",":first-child"),i=n.insert("circle",":first-child");return i.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),r.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),Rt(e,i),e.intersect=function(t){return Nt.circle(e,7,t)},n}),"end"),note:Ot,subroutine:re,fork:ae,join:ae,class_box:(0,o.eW)(((t,e)=>{const n=e.padding/2;let r;r=e.classes?"node "+e.classes:"node default";const i=t.insert("g").attr("class",r).attr("id",e.domId||e.id),a=i.insert("rect",":first-child"),s=i.insert("line"),l=i.insert("line");let c=0,h=4;const d=i.insert("g").attr("class","label");let p=0;const g=e.classData.annotations?.[0],f=e.classData.annotations[0]?"«"+e.classData.annotations[0]+"»":"",m=d.node().appendChild(at(f,e.labelStyle,!0,!0));let y=m.getBBox();if((0,o.ku)((0,o.nV)().flowchart.htmlLabels)){const t=m.children[0],e=(0,u.Ys)(m);y=t.getBoundingClientRect(),e.attr("width",y.width),e.attr("height",y.height)}e.classData.annotations[0]&&(h+=y.height+4,c+=y.width);let v=e.classData.label;void 0!==e.classData.type&&""!==e.classData.type&&((0,o.nV)().flowchart.htmlLabels?v+="<"+e.classData.type+">":v+="<"+e.classData.type+">");const x=d.node().appendChild(at(v,e.labelStyle,!0,!0));(0,u.Ys)(x).attr("class","classTitle");let b=x.getBBox();if((0,o.ku)((0,o.nV)().flowchart.htmlLabels)){const t=x.children[0],e=(0,u.Ys)(x);b=t.getBoundingClientRect(),e.attr("width",b.width),e.attr("height",b.height)}h+=b.height+4,b.width>c&&(c=b.width);const w=[];e.classData.members.forEach((t=>{const n=t.getDisplayDetails();let r=n.displayText;(0,o.nV)().flowchart.htmlLabels&&(r=r.replace(//g,">"));const i=d.node().appendChild(at(r,n.cssStyle?n.cssStyle:e.labelStyle,!0,!0));let a=i.getBBox();if((0,o.ku)((0,o.nV)().flowchart.htmlLabels)){const t=i.children[0],e=(0,u.Ys)(i);a=t.getBoundingClientRect(),e.attr("width",a.width),e.attr("height",a.height)}a.width>c&&(c=a.width),h+=a.height+4,w.push(i)})),h+=8;const k=[];if(e.classData.methods.forEach((t=>{const n=t.getDisplayDetails();let r=n.displayText;(0,o.nV)().flowchart.htmlLabels&&(r=r.replace(//g,">"));const i=d.node().appendChild(at(r,n.cssStyle?n.cssStyle:e.labelStyle,!0,!0));let a=i.getBBox();if((0,o.ku)((0,o.nV)().flowchart.htmlLabels)){const t=i.children[0],e=(0,u.Ys)(i);a=t.getBoundingClientRect(),e.attr("width",a.width),e.attr("height",a.height)}a.width>c&&(c=a.width),h+=a.height+4,k.push(i)})),h+=8,g){let t=(c-y.width)/2;(0,u.Ys)(m).attr("transform","translate( "+(-1*c/2+t)+", "+-1*h/2+")"),p=y.height+4}let T=(c-b.width)/2;return(0,u.Ys)(x).attr("transform","translate( "+(-1*c/2+T)+", "+(-1*h/2+p)+")"),p+=b.height+4,s.attr("class","divider").attr("x1",-c/2-n).attr("x2",c/2+n).attr("y1",-h/2-n+8+p).attr("y2",-h/2-n+8+p),p+=8,w.forEach((t=>{(0,u.Ys)(t).attr("transform","translate( "+-c/2+", "+(-1*h/2+p+4)+")");const e=t?.getBBox();p+=(e?.height??0)+4})),p+=8,l.attr("class","divider").attr("x1",-c/2-n).attr("x2",c/2+n).attr("y1",-h/2-n+8+p).attr("y2",-h/2-n+8+p),p+=8,k.forEach((t=>{(0,u.Ys)(t).attr("transform","translate( "+-c/2+", "+(-1*h/2+p)+")");const e=t?.getBBox();p+=(e?.height??0)+4})),a.attr("style",e.style).attr("class","outer title-state").attr("x",-c/2-n).attr("y",-h/2-n).attr("width",c+e.padding).attr("height",h+e.padding),Rt(e,a),e.intersect=function(t){return Nt.rect(e,t)},i}),"class_box")},oe={},le=(0,o.eW)((async(t,e,n)=>{let r,i;if(e.link){let a;"sandbox"===(0,o.nV)().securityLevel?a="_top":e.linkTarget&&(a=e.linkTarget||"_blank"),r=t.insert("svg:a").attr("xlink:href",e.link).attr("target",a),i=await se[e.shape](r,e,n)}else i=await se[e.shape](t,e,n),r=i;return e.tooltip&&i.attr("title",e.tooltip),e.class&&i.attr("class","node default "+e.class),oe[e.id]=r,e.haveCallback&&oe[e.id].attr("class",oe[e.id].attr("class")+" clickable"),r}),"insertNode"),ce=(0,o.eW)((t=>{const e=oe[t.id];o.cM.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");const n=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+n-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),n}),"positionNode");function he(t,e,n=!1){const r=t;let i="default";(r?.classes?.length||0)>0&&(i=(r?.classes??[]).join(" ")),i+=" flowchart-label";let a,l=0,c="";switch(r.type){case"round":l=5,c="rect";break;case"composite":l=0,c="composite",a=0;break;case"square":case"group":default:c="rect";break;case"diamond":c="question";break;case"hexagon":c="hexagon";break;case"block_arrow":c="block_arrow";break;case"odd":case"rect_left_inv_arrow":c="rect_left_inv_arrow";break;case"lean_right":c="lean_right";break;case"lean_left":c="lean_left";break;case"trapezoid":c="trapezoid";break;case"inv_trapezoid":c="inv_trapezoid";break;case"circle":c="circle";break;case"ellipse":c="ellipse";break;case"stadium":c="stadium";break;case"subroutine":c="subroutine";break;case"cylinder":c="cylinder";break;case"doublecircle":c="doublecircle"}const h=(0,s.be)(r?.styles??[]),u=r.label,d=r.size??{width:0,height:0,x:0,y:0};return{labelStyle:h.labelStyle,shape:c,labelText:u,rx:l,ry:l,class:i,style:h.style,id:r.id,directions:r.directions,width:d.width,height:d.height,x:d.x,y:d.y,positioned:n,intersect:void 0,type:r.type,padding:a??(0,o.iE)()?.block?.padding??0}}async function ue(t,e,n){const r=he(e,0,!1);if("group"===r.type)return;const i=(0,o.iE)(),a=await le(t,r,{config:i}),s=a.node().getBBox(),l=n.getBlock(r.id);l.size={width:s.width,height:s.height,x:0,y:0,node:a},n.setBlock(l),a.remove()}async function de(t,e,n){const r=he(e,0,!0);if("space"!==n.getBlock(r.id).type){const n=(0,o.iE)();await le(t,r,{config:n}),e.intersect=r?.intersect,ce(r)}}async function pe(t,e,n,r){for(const i of e)await r(t,i,n),i.children&&await pe(t,i.children,n,r)}async function ge(t,e,n){await pe(t,e,n,ue)}async function fe(t,e,n){await pe(t,e,n,de)}async function me(t,e,n,r,i){const a=new d.k({multigraph:!0,compound:!0});a.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8});for(const t of n)t.size&&a.setNode(t.id,{width:t.size.width,height:t.size.height,intersect:t.intersect});for(const n of e)if(n.start&&n.end){const e=r.getBlock(n.start),s=r.getBlock(n.end);if(e?.size&&s?.size){const r=e.size,o=s.size,l=[{x:r.x,y:r.y},{x:r.x+(o.x-r.x)/2,y:r.y+(o.y-r.y)/2},{x:o.x,y:o.y}];yt(t,{v:n.start,w:n.end,name:n.id},{...n,arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:l,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"},void 0,"block",a,i),n.label&&(await ut(t,{...n,label:n.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:l,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"}),pt({...n,x:l[1].x,y:l[1].y},{originalPath:l}))}}}(0,o.eW)(he,"getNodeFromBlock"),(0,o.eW)(ue,"calculateBlockSize"),(0,o.eW)(de,"insertBlockPositioned"),(0,o.eW)(pe,"performOperations"),(0,o.eW)(ge,"calculateBlockSizes"),(0,o.eW)(fe,"insertBlocks"),(0,o.eW)(me,"insertEdges");var ye=(0,o.eW)((function(t,e){return e.db.getClasses()}),"getClasses"),ve={parser:g,db:U,renderer:{draw:(0,o.eW)((async function(t,e,n,r){const{securityLevel:i,block:a}=(0,o.iE)(),s=r.db;let l;"sandbox"===i&&(l=(0,u.Ys)("#i"+e));const c="sandbox"===i?(0,u.Ys)(l.nodes()[0].contentDocument.body):(0,u.Ys)("body"),h="sandbox"===i?c.select(`[id="${e}"]`):(0,u.Ys)(`[id="${e}"]`);H(h,["point","circle","cross"],r.type,e);const d=s.getBlocks(),p=s.getBlocksFlat(),g=s.getEdges(),f=h.insert("g").attr("class","block");await ge(f,d,s);const m=nt(s);if(await fe(f,d,s),await me(f,g,p,s,e),m){const t=m,e=Math.max(1,Math.round(t.width/t.height*.125)),n=t.height+e+10,r=t.width+10,{useMaxWidth:i}=a;(0,o.v2)(h,n,r,!!i),o.cM.debug("Here Bounds",m,t),h.attr("viewBox",`${t.x-5} ${t.y-5} ${t.width+10} ${t.height+10}`)}}),"draw"),getClasses:ye},styles:V}},8931:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>It});var r=n(279),i=n(7946),a=n(4082),s=n(3108),o=n(7967),l=function(){var t=(0,a.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,24],n=[1,25],r=[1,26],i=[1,27],s=[1,28],o=[1,63],l=[1,64],h=[1,65],u=[1,66],d=[1,67],p=[1,68],g=[1,69],f=[1,29],m=[1,30],y=[1,31],v=[1,32],x=[1,33],b=[1,34],w=[1,35],k=[1,36],T=[1,37],_=[1,38],E=[1,39],S=[1,40],C=[1,41],A=[1,42],L=[1,43],M=[1,44],N=[1,45],I=[1,46],R=[1,47],D=[1,48],O=[1,50],P=[1,51],$=[1,52],B=[1,53],F=[1,54],W=[1,55],z=[1,56],Z=[1,57],Y=[1,58],U=[1,59],G=[1,60],V=[14,42],q=[14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],j=[12,14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],H=[1,82],X=[1,83],K=[1,84],Q=[1,85],J=[12,14,42],tt=[12,14,33,42],et=[12,14,33,42,76,77,79,80],nt=[12,33],rt=[34,36,37,38,39,40,41,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],it={trace:(0,a.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,direction:5,direction_tb:6,direction_bt:7,direction_rl:8,direction_lr:9,graphConfig:10,C4_CONTEXT:11,NEWLINE:12,statements:13,EOF:14,C4_CONTAINER:15,C4_COMPONENT:16,C4_DYNAMIC:17,C4_DEPLOYMENT:18,otherStatements:19,diagramStatements:20,otherStatement:21,title:22,accDescription:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,boundaryStatement:29,boundaryStartStatement:30,boundaryStopStatement:31,boundaryStart:32,LBRACE:33,ENTERPRISE_BOUNDARY:34,attributes:35,SYSTEM_BOUNDARY:36,BOUNDARY:37,CONTAINER_BOUNDARY:38,NODE:39,NODE_L:40,NODE_R:41,RBRACE:42,diagramStatement:43,PERSON:44,PERSON_EXT:45,SYSTEM:46,SYSTEM_DB:47,SYSTEM_QUEUE:48,SYSTEM_EXT:49,SYSTEM_EXT_DB:50,SYSTEM_EXT_QUEUE:51,CONTAINER:52,CONTAINER_DB:53,CONTAINER_QUEUE:54,CONTAINER_EXT:55,CONTAINER_EXT_DB:56,CONTAINER_EXT_QUEUE:57,COMPONENT:58,COMPONENT_DB:59,COMPONENT_QUEUE:60,COMPONENT_EXT:61,COMPONENT_EXT_DB:62,COMPONENT_EXT_QUEUE:63,REL:64,BIREL:65,REL_U:66,REL_D:67,REL_L:68,REL_R:69,REL_B:70,REL_INDEX:71,UPDATE_EL_STYLE:72,UPDATE_REL_STYLE:73,UPDATE_LAYOUT_CONFIG:74,attribute:75,STR:76,STR_KEY:77,STR_VALUE:78,ATTRIBUTE:79,ATTRIBUTE_EMPTY:80,$accept:0,$end:1},terminals_:{2:"error",6:"direction_tb",7:"direction_bt",8:"direction_rl",9:"direction_lr",11:"C4_CONTEXT",12:"NEWLINE",14:"EOF",15:"C4_CONTAINER",16:"C4_COMPONENT",17:"C4_DYNAMIC",18:"C4_DEPLOYMENT",22:"title",23:"accDescription",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"LBRACE",34:"ENTERPRISE_BOUNDARY",36:"SYSTEM_BOUNDARY",37:"BOUNDARY",38:"CONTAINER_BOUNDARY",39:"NODE",40:"NODE_L",41:"NODE_R",42:"RBRACE",44:"PERSON",45:"PERSON_EXT",46:"SYSTEM",47:"SYSTEM_DB",48:"SYSTEM_QUEUE",49:"SYSTEM_EXT",50:"SYSTEM_EXT_DB",51:"SYSTEM_EXT_QUEUE",52:"CONTAINER",53:"CONTAINER_DB",54:"CONTAINER_QUEUE",55:"CONTAINER_EXT",56:"CONTAINER_EXT_DB",57:"CONTAINER_EXT_QUEUE",58:"COMPONENT",59:"COMPONENT_DB",60:"COMPONENT_QUEUE",61:"COMPONENT_EXT",62:"COMPONENT_EXT_DB",63:"COMPONENT_EXT_QUEUE",64:"REL",65:"BIREL",66:"REL_U",67:"REL_D",68:"REL_L",69:"REL_R",70:"REL_B",71:"REL_INDEX",72:"UPDATE_EL_STYLE",73:"UPDATE_REL_STYLE",74:"UPDATE_LAYOUT_CONFIG",76:"STR",77:"STR_KEY",78:"STR_VALUE",79:"ATTRIBUTE",80:"ATTRIBUTE_EMPTY"},productions_:[0,[3,1],[3,1],[5,1],[5,1],[5,1],[5,1],[4,1],[10,4],[10,4],[10,4],[10,4],[10,4],[13,1],[13,1],[13,2],[19,1],[19,2],[19,3],[21,1],[21,1],[21,2],[21,2],[21,1],[29,3],[30,3],[30,3],[30,4],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[31,1],[20,1],[20,2],[20,3],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,1],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[35,1],[35,2],[75,1],[75,2],[75,1],[75,1]],performAction:(0,a.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 3:r.setDirection("TB");break;case 4:r.setDirection("BT");break;case 5:r.setDirection("RL");break;case 6:r.setDirection("LR");break;case 8:case 9:case 10:case 11:case 12:r.setC4Type(a[o-3]);break;case 19:r.setTitle(a[o].substring(6)),this.$=a[o].substring(6);break;case 20:r.setAccDescription(a[o].substring(15)),this.$=a[o].substring(15);break;case 21:this.$=a[o].trim(),r.setTitle(this.$);break;case 22:case 23:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 28:a[o].splice(2,0,"ENTERPRISE"),r.addPersonOrSystemBoundary(...a[o]),this.$=a[o];break;case 29:a[o].splice(2,0,"SYSTEM"),r.addPersonOrSystemBoundary(...a[o]),this.$=a[o];break;case 30:r.addPersonOrSystemBoundary(...a[o]),this.$=a[o];break;case 31:a[o].splice(2,0,"CONTAINER"),r.addContainerBoundary(...a[o]),this.$=a[o];break;case 32:r.addDeploymentNode("node",...a[o]),this.$=a[o];break;case 33:r.addDeploymentNode("nodeL",...a[o]),this.$=a[o];break;case 34:r.addDeploymentNode("nodeR",...a[o]),this.$=a[o];break;case 35:r.popBoundaryParseStack();break;case 39:r.addPersonOrSystem("person",...a[o]),this.$=a[o];break;case 40:r.addPersonOrSystem("external_person",...a[o]),this.$=a[o];break;case 41:r.addPersonOrSystem("system",...a[o]),this.$=a[o];break;case 42:r.addPersonOrSystem("system_db",...a[o]),this.$=a[o];break;case 43:r.addPersonOrSystem("system_queue",...a[o]),this.$=a[o];break;case 44:r.addPersonOrSystem("external_system",...a[o]),this.$=a[o];break;case 45:r.addPersonOrSystem("external_system_db",...a[o]),this.$=a[o];break;case 46:r.addPersonOrSystem("external_system_queue",...a[o]),this.$=a[o];break;case 47:r.addContainer("container",...a[o]),this.$=a[o];break;case 48:r.addContainer("container_db",...a[o]),this.$=a[o];break;case 49:r.addContainer("container_queue",...a[o]),this.$=a[o];break;case 50:r.addContainer("external_container",...a[o]),this.$=a[o];break;case 51:r.addContainer("external_container_db",...a[o]),this.$=a[o];break;case 52:r.addContainer("external_container_queue",...a[o]),this.$=a[o];break;case 53:r.addComponent("component",...a[o]),this.$=a[o];break;case 54:r.addComponent("component_db",...a[o]),this.$=a[o];break;case 55:r.addComponent("component_queue",...a[o]),this.$=a[o];break;case 56:r.addComponent("external_component",...a[o]),this.$=a[o];break;case 57:r.addComponent("external_component_db",...a[o]),this.$=a[o];break;case 58:r.addComponent("external_component_queue",...a[o]),this.$=a[o];break;case 60:r.addRel("rel",...a[o]),this.$=a[o];break;case 61:r.addRel("birel",...a[o]),this.$=a[o];break;case 62:r.addRel("rel_u",...a[o]),this.$=a[o];break;case 63:r.addRel("rel_d",...a[o]),this.$=a[o];break;case 64:r.addRel("rel_l",...a[o]),this.$=a[o];break;case 65:r.addRel("rel_r",...a[o]),this.$=a[o];break;case 66:r.addRel("rel_b",...a[o]),this.$=a[o];break;case 67:a[o].splice(0,1),r.addRel("rel",...a[o]),this.$=a[o];break;case 68:r.updateElStyle("update_el_style",...a[o]),this.$=a[o];break;case 69:r.updateRelStyle("update_rel_style",...a[o]),this.$=a[o];break;case 70:r.updateLayoutConfig("update_layout_config",...a[o]),this.$=a[o];break;case 71:this.$=[a[o]];break;case 72:a[o].unshift(a[o-1]),this.$=a[o];break;case 73:case 75:this.$=a[o].trim();break;case 74:let t={};t[a[o-1].trim()]=a[o].trim(),this.$=t;break;case 76:this.$=""}}),"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],7:[1,6],8:[1,7],9:[1,8],10:4,11:[1,9],15:[1,10],16:[1,11],17:[1,12],18:[1,13]},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,7]},{1:[2,3]},{1:[2,4]},{1:[2,5]},{1:[2,6]},{12:[1,14]},{12:[1,15]},{12:[1,16]},{12:[1,17]},{12:[1,18]},{13:19,19:20,20:21,21:22,22:e,23:n,24:r,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:u,39:d,40:p,41:g,43:23,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G},{13:70,19:20,20:21,21:22,22:e,23:n,24:r,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:u,39:d,40:p,41:g,43:23,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G},{13:71,19:20,20:21,21:22,22:e,23:n,24:r,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:u,39:d,40:p,41:g,43:23,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G},{13:72,19:20,20:21,21:22,22:e,23:n,24:r,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:u,39:d,40:p,41:g,43:23,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G},{13:73,19:20,20:21,21:22,22:e,23:n,24:r,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:u,39:d,40:p,41:g,43:23,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G},{14:[1,74]},t(V,[2,13],{43:23,29:49,30:61,32:62,20:75,34:o,36:l,37:h,38:u,39:d,40:p,41:g,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G}),t(V,[2,14]),t(q,[2,16],{12:[1,76]}),t(V,[2,36],{12:[1,77]}),t(j,[2,19]),t(j,[2,20]),{25:[1,78]},{27:[1,79]},t(j,[2,23]),{35:80,75:81,76:H,77:X,79:K,80:Q},{35:86,75:81,76:H,77:X,79:K,80:Q},{35:87,75:81,76:H,77:X,79:K,80:Q},{35:88,75:81,76:H,77:X,79:K,80:Q},{35:89,75:81,76:H,77:X,79:K,80:Q},{35:90,75:81,76:H,77:X,79:K,80:Q},{35:91,75:81,76:H,77:X,79:K,80:Q},{35:92,75:81,76:H,77:X,79:K,80:Q},{35:93,75:81,76:H,77:X,79:K,80:Q},{35:94,75:81,76:H,77:X,79:K,80:Q},{35:95,75:81,76:H,77:X,79:K,80:Q},{35:96,75:81,76:H,77:X,79:K,80:Q},{35:97,75:81,76:H,77:X,79:K,80:Q},{35:98,75:81,76:H,77:X,79:K,80:Q},{35:99,75:81,76:H,77:X,79:K,80:Q},{35:100,75:81,76:H,77:X,79:K,80:Q},{35:101,75:81,76:H,77:X,79:K,80:Q},{35:102,75:81,76:H,77:X,79:K,80:Q},{35:103,75:81,76:H,77:X,79:K,80:Q},{35:104,75:81,76:H,77:X,79:K,80:Q},t(J,[2,59]),{35:105,75:81,76:H,77:X,79:K,80:Q},{35:106,75:81,76:H,77:X,79:K,80:Q},{35:107,75:81,76:H,77:X,79:K,80:Q},{35:108,75:81,76:H,77:X,79:K,80:Q},{35:109,75:81,76:H,77:X,79:K,80:Q},{35:110,75:81,76:H,77:X,79:K,80:Q},{35:111,75:81,76:H,77:X,79:K,80:Q},{35:112,75:81,76:H,77:X,79:K,80:Q},{35:113,75:81,76:H,77:X,79:K,80:Q},{35:114,75:81,76:H,77:X,79:K,80:Q},{35:115,75:81,76:H,77:X,79:K,80:Q},{20:116,29:49,30:61,32:62,34:o,36:l,37:h,38:u,39:d,40:p,41:g,43:23,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G},{12:[1,118],33:[1,117]},{35:119,75:81,76:H,77:X,79:K,80:Q},{35:120,75:81,76:H,77:X,79:K,80:Q},{35:121,75:81,76:H,77:X,79:K,80:Q},{35:122,75:81,76:H,77:X,79:K,80:Q},{35:123,75:81,76:H,77:X,79:K,80:Q},{35:124,75:81,76:H,77:X,79:K,80:Q},{35:125,75:81,76:H,77:X,79:K,80:Q},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},t(V,[2,15]),t(q,[2,17],{21:22,19:130,22:e,23:n,24:r,26:i,28:s}),t(V,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:e,23:n,24:r,26:i,28:s,34:o,36:l,37:h,38:u,39:d,40:p,41:g,44:f,45:m,46:y,47:v,48:x,49:b,50:w,51:k,52:T,53:_,54:E,55:S,56:C,57:A,58:L,59:M,60:N,61:I,62:R,63:D,64:O,65:P,66:$,67:B,68:F,69:W,70:z,71:Z,72:Y,73:U,74:G}),t(j,[2,21]),t(j,[2,22]),t(J,[2,39]),t(tt,[2,71],{75:81,35:132,76:H,77:X,79:K,80:Q}),t(et,[2,73]),{78:[1,133]},t(et,[2,75]),t(et,[2,76]),t(J,[2,40]),t(J,[2,41]),t(J,[2,42]),t(J,[2,43]),t(J,[2,44]),t(J,[2,45]),t(J,[2,46]),t(J,[2,47]),t(J,[2,48]),t(J,[2,49]),t(J,[2,50]),t(J,[2,51]),t(J,[2,52]),t(J,[2,53]),t(J,[2,54]),t(J,[2,55]),t(J,[2,56]),t(J,[2,57]),t(J,[2,58]),t(J,[2,60]),t(J,[2,61]),t(J,[2,62]),t(J,[2,63]),t(J,[2,64]),t(J,[2,65]),t(J,[2,66]),t(J,[2,67]),t(J,[2,68]),t(J,[2,69]),t(J,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},t(nt,[2,28]),t(nt,[2,29]),t(nt,[2,30]),t(nt,[2,31]),t(nt,[2,32]),t(nt,[2,33]),t(nt,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},t(q,[2,18]),t(V,[2,38]),t(tt,[2,72]),t(et,[2,74]),t(J,[2,24]),t(J,[2,35]),t(rt,[2,25]),t(rt,[2,26],{12:[1,138]}),t(rt,[2,27])],defaultActions:{2:[2,1],3:[2,2],4:[2,7],5:[2,3],6:[2,4],7:[2,5],8:[2,6],74:[2,8],126:[2,9],127:[2,10],128:[2,11],129:[2,12]},parseError:(0,a.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,a.eW)((function(t){var e=this,n=[0],r=[],i=[null],s=[],o=this.table,l="",c=0,h=0,u=0,d=s.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;s.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,a.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,s.length=s.length-t}),"popStack"),(0,a.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),s.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:s[s.length-(E||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(E||1)].first_column,last_column:s[s.length-1].last_column},y&&(A._$.range=[s[s.length-(E||1)].range[0],s[s.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,s].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),s=s.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),s.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},at=function(){return{EOF:1,parseError:(0,a.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,a.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,a.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,a.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,a.eW)((function(){return this._more=!0,this}),"more"),reject:(0,a.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,a.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,a.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,a.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,a.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,a.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,a.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,a.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,a.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,a.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,a.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,a.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,a.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,a.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{},performAction:(0,a.eW)((function(t,e,n,r){switch(n){case 0:return 6;case 1:return 7;case 2:return 8;case 3:return 9;case 4:return 22;case 5:return 23;case 6:return this.begin("acc_title"),24;case 7:return this.popState(),"acc_title_value";case 8:return this.begin("acc_descr"),26;case 9:return this.popState(),"acc_descr_value";case 10:this.begin("acc_descr_multiline");break;case 11:case 73:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:case 16:case 70:break;case 14:c;break;case 15:return 12;case 17:return 11;case 18:return 15;case 19:return 16;case 20:return 17;case 21:return 18;case 22:return this.begin("person_ext"),45;case 23:return this.begin("person"),44;case 24:return this.begin("system_ext_queue"),51;case 25:return this.begin("system_ext_db"),50;case 26:return this.begin("system_ext"),49;case 27:return this.begin("system_queue"),48;case 28:return this.begin("system_db"),47;case 29:return this.begin("system"),46;case 30:return this.begin("boundary"),37;case 31:return this.begin("enterprise_boundary"),34;case 32:return this.begin("system_boundary"),36;case 33:return this.begin("container_ext_queue"),57;case 34:return this.begin("container_ext_db"),56;case 35:return this.begin("container_ext"),55;case 36:return this.begin("container_queue"),54;case 37:return this.begin("container_db"),53;case 38:return this.begin("container"),52;case 39:return this.begin("container_boundary"),38;case 40:return this.begin("component_ext_queue"),63;case 41:return this.begin("component_ext_db"),62;case 42:return this.begin("component_ext"),61;case 43:return this.begin("component_queue"),60;case 44:return this.begin("component_db"),59;case 45:return this.begin("component"),58;case 46:case 47:return this.begin("node"),39;case 48:return this.begin("node_l"),40;case 49:return this.begin("node_r"),41;case 50:return this.begin("rel"),64;case 51:return this.begin("birel"),65;case 52:case 53:return this.begin("rel_u"),66;case 54:case 55:return this.begin("rel_d"),67;case 56:case 57:return this.begin("rel_l"),68;case 58:case 59:return this.begin("rel_r"),69;case 60:return this.begin("rel_b"),70;case 61:return this.begin("rel_index"),71;case 62:return this.begin("update_el_style"),72;case 63:return this.begin("update_rel_style"),73;case 64:return this.begin("update_layout_config"),74;case 65:return"EOF_IN_STRUCT";case 66:return this.begin("attribute"),"ATTRIBUTE_EMPTY";case 67:this.begin("attribute");break;case 68:case 79:this.popState(),this.popState();break;case 69:case 71:return 80;case 72:this.begin("string");break;case 74:case 80:return"STR";case 75:this.begin("string_kv");break;case 76:return this.begin("string_kv_key"),"STR_KEY";case 77:this.popState(),this.begin("string_kv_value");break;case 78:return"STR_VALUE";case 81:return"LBRACE";case 82:return"RBRACE";case 83:return"SPACE";case 84:return"EOL";case 85:return 14}}),"anonymous"),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:title\s[^#\n;]+)/,/^(?:accDescription\s[^#\n;]+)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:C4Context\b)/,/^(?:C4Container\b)/,/^(?:C4Component\b)/,/^(?:C4Dynamic\b)/,/^(?:C4Deployment\b)/,/^(?:Person_Ext\b)/,/^(?:Person\b)/,/^(?:SystemQueue_Ext\b)/,/^(?:SystemDb_Ext\b)/,/^(?:System_Ext\b)/,/^(?:SystemQueue\b)/,/^(?:SystemDb\b)/,/^(?:System\b)/,/^(?:Boundary\b)/,/^(?:Enterprise_Boundary\b)/,/^(?:System_Boundary\b)/,/^(?:ContainerQueue_Ext\b)/,/^(?:ContainerDb_Ext\b)/,/^(?:Container_Ext\b)/,/^(?:ContainerQueue\b)/,/^(?:ContainerDb\b)/,/^(?:Container\b)/,/^(?:Container_Boundary\b)/,/^(?:ComponentQueue_Ext\b)/,/^(?:ComponentDb_Ext\b)/,/^(?:Component_Ext\b)/,/^(?:ComponentQueue\b)/,/^(?:ComponentDb\b)/,/^(?:Component\b)/,/^(?:Deployment_Node\b)/,/^(?:Node\b)/,/^(?:Node_L\b)/,/^(?:Node_R\b)/,/^(?:Rel\b)/,/^(?:BiRel\b)/,/^(?:Rel_Up\b)/,/^(?:Rel_U\b)/,/^(?:Rel_Down\b)/,/^(?:Rel_D\b)/,/^(?:Rel_Left\b)/,/^(?:Rel_L\b)/,/^(?:Rel_Right\b)/,/^(?:Rel_R\b)/,/^(?:Rel_Back\b)/,/^(?:RelIndex\b)/,/^(?:UpdateElementStyle\b)/,/^(?:UpdateRelStyle\b)/,/^(?:UpdateLayoutConfig\b)/,/^(?:$)/,/^(?:[(][ ]*[,])/,/^(?:[(])/,/^(?:[)])/,/^(?:,,)/,/^(?:,)/,/^(?:[ ]*["]["])/,/^(?:[ ]*["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:[ ]*[\$])/,/^(?:[^=]*)/,/^(?:[=][ ]*["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:[^,]+)/,/^(?:\{)/,/^(?:\})/,/^(?:[\s]+)/,/^(?:[\n\r]+)/,/^(?:$)/],conditions:{acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},string_kv_value:{rules:[78,79],inclusive:!1},string_kv_key:{rules:[77],inclusive:!1},string_kv:{rules:[76],inclusive:!1},string:{rules:[73,74],inclusive:!1},attribute:{rules:[68,69,70,71,72,75,80],inclusive:!1},update_layout_config:{rules:[65,66,67,68],inclusive:!1},update_rel_style:{rules:[65,66,67,68],inclusive:!1},update_el_style:{rules:[65,66,67,68],inclusive:!1},rel_b:{rules:[65,66,67,68],inclusive:!1},rel_r:{rules:[65,66,67,68],inclusive:!1},rel_l:{rules:[65,66,67,68],inclusive:!1},rel_d:{rules:[65,66,67,68],inclusive:!1},rel_u:{rules:[65,66,67,68],inclusive:!1},rel_bi:{rules:[],inclusive:!1},rel:{rules:[65,66,67,68],inclusive:!1},node_r:{rules:[65,66,67,68],inclusive:!1},node_l:{rules:[65,66,67,68],inclusive:!1},node:{rules:[65,66,67,68],inclusive:!1},index:{rules:[],inclusive:!1},rel_index:{rules:[65,66,67,68],inclusive:!1},component_ext_queue:{rules:[],inclusive:!1},component_ext_db:{rules:[65,66,67,68],inclusive:!1},component_ext:{rules:[65,66,67,68],inclusive:!1},component_queue:{rules:[65,66,67,68],inclusive:!1},component_db:{rules:[65,66,67,68],inclusive:!1},component:{rules:[65,66,67,68],inclusive:!1},container_boundary:{rules:[65,66,67,68],inclusive:!1},container_ext_queue:{rules:[65,66,67,68],inclusive:!1},container_ext_db:{rules:[65,66,67,68],inclusive:!1},container_ext:{rules:[65,66,67,68],inclusive:!1},container_queue:{rules:[65,66,67,68],inclusive:!1},container_db:{rules:[65,66,67,68],inclusive:!1},container:{rules:[65,66,67,68],inclusive:!1},birel:{rules:[65,66,67,68],inclusive:!1},system_boundary:{rules:[65,66,67,68],inclusive:!1},enterprise_boundary:{rules:[65,66,67,68],inclusive:!1},boundary:{rules:[65,66,67,68],inclusive:!1},system_ext_queue:{rules:[65,66,67,68],inclusive:!1},system_ext_db:{rules:[65,66,67,68],inclusive:!1},system_ext:{rules:[65,66,67,68],inclusive:!1},system_queue:{rules:[65,66,67,68],inclusive:!1},system_db:{rules:[65,66,67,68],inclusive:!1},system:{rules:[65,66,67,68],inclusive:!1},person_ext:{rules:[65,66,67,68],inclusive:!1},person:{rules:[65,66,67,68],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,82,83,84,85],inclusive:!0}}}}();function st(){this.yy={}}return it.lexer=at,(0,a.eW)(st,"Parser"),st.prototype=it,it.Parser=st,new st}();l.parser=l;var h,u=l,d=[],p=[""],g="global",f="",m=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],y=[],v="",x=!1,b=4,w=2,k=(0,a.eW)((function(){return h}),"getC4Type"),T=(0,a.eW)((function(t){let e=(0,a.oO)(t,(0,a.nV)());h=e}),"setC4Type"),_=(0,a.eW)((function(t,e,n,r,i,a,s,o,l){if(null==t||null==e||null==n||null==r)return;let c={};const h=y.find((t=>t.from===e&&t.to===n));if(h?c=h:y.push(c),c.type=t,c.from=e,c.to=n,c.label={text:r},null==i)c.techn={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];c[t]={text:e}}else c.techn={text:i};if(null==a)c.descr={text:""};else if("object"==typeof a){let[t,e]=Object.entries(a)[0];c[t]={text:e}}else c.descr={text:a};if("object"==typeof s){let[t,e]=Object.entries(s)[0];c[t]=e}else c.sprite=s;if("object"==typeof o){let[t,e]=Object.entries(o)[0];c[t]=e}else c.tags=o;if("object"==typeof l){let[t,e]=Object.entries(l)[0];c[t]=e}else c.link=l;c.wrap=q()}),"addRel"),E=(0,a.eW)((function(t,e,n,r,i,a,s){if(null===e||null===n)return;let o={};const l=d.find((t=>t.alias===e));if(l&&e===l.alias?o=l:(o.alias=e,d.push(o)),o.label=null==n?{text:""}:{text:n},null==r)o.descr={text:""};else if("object"==typeof r){let[t,e]=Object.entries(r)[0];o[t]={text:e}}else o.descr={text:r};if("object"==typeof i){let[t,e]=Object.entries(i)[0];o[t]=e}else o.sprite=i;if("object"==typeof a){let[t,e]=Object.entries(a)[0];o[t]=e}else o.tags=a;if("object"==typeof s){let[t,e]=Object.entries(s)[0];o[t]=e}else o.link=s;o.typeC4Shape={text:t},o.parentBoundary=g,o.wrap=q()}),"addPersonOrSystem"),S=(0,a.eW)((function(t,e,n,r,i,a,s,o){if(null===e||null===n)return;let l={};const c=d.find((t=>t.alias===e));if(c&&e===c.alias?l=c:(l.alias=e,d.push(l)),l.label=null==n?{text:""}:{text:n},null==r)l.techn={text:""};else if("object"==typeof r){let[t,e]=Object.entries(r)[0];l[t]={text:e}}else l.techn={text:r};if(null==i)l.descr={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];l[t]={text:e}}else l.descr={text:i};if("object"==typeof a){let[t,e]=Object.entries(a)[0];l[t]=e}else l.sprite=a;if("object"==typeof s){let[t,e]=Object.entries(s)[0];l[t]=e}else l.tags=s;if("object"==typeof o){let[t,e]=Object.entries(o)[0];l[t]=e}else l.link=o;l.wrap=q(),l.typeC4Shape={text:t},l.parentBoundary=g}),"addContainer"),C=(0,a.eW)((function(t,e,n,r,i,a,s,o){if(null===e||null===n)return;let l={};const c=d.find((t=>t.alias===e));if(c&&e===c.alias?l=c:(l.alias=e,d.push(l)),l.label=null==n?{text:""}:{text:n},null==r)l.techn={text:""};else if("object"==typeof r){let[t,e]=Object.entries(r)[0];l[t]={text:e}}else l.techn={text:r};if(null==i)l.descr={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];l[t]={text:e}}else l.descr={text:i};if("object"==typeof a){let[t,e]=Object.entries(a)[0];l[t]=e}else l.sprite=a;if("object"==typeof s){let[t,e]=Object.entries(s)[0];l[t]=e}else l.tags=s;if("object"==typeof o){let[t,e]=Object.entries(o)[0];l[t]=e}else l.link=o;l.wrap=q(),l.typeC4Shape={text:t},l.parentBoundary=g}),"addComponent"),A=(0,a.eW)((function(t,e,n,r,i){if(null===t||null===e)return;let a={};const s=m.find((e=>e.alias===t));if(s&&t===s.alias?a=s:(a.alias=t,m.push(a)),a.label=null==e?{text:""}:{text:e},null==n)a.type={text:"system"};else if("object"==typeof n){let[t,e]=Object.entries(n)[0];a[t]={text:e}}else a.type={text:n};if("object"==typeof r){let[t,e]=Object.entries(r)[0];a[t]=e}else a.tags=r;if("object"==typeof i){let[t,e]=Object.entries(i)[0];a[t]=e}else a.link=i;a.parentBoundary=g,a.wrap=q(),f=g,g=t,p.push(f)}),"addPersonOrSystemBoundary"),L=(0,a.eW)((function(t,e,n,r,i){if(null===t||null===e)return;let a={};const s=m.find((e=>e.alias===t));if(s&&t===s.alias?a=s:(a.alias=t,m.push(a)),a.label=null==e?{text:""}:{text:e},null==n)a.type={text:"container"};else if("object"==typeof n){let[t,e]=Object.entries(n)[0];a[t]={text:e}}else a.type={text:n};if("object"==typeof r){let[t,e]=Object.entries(r)[0];a[t]=e}else a.tags=r;if("object"==typeof i){let[t,e]=Object.entries(i)[0];a[t]=e}else a.link=i;a.parentBoundary=g,a.wrap=q(),f=g,g=t,p.push(f)}),"addContainerBoundary"),M=(0,a.eW)((function(t,e,n,r,i,a,s,o){if(null===e||null===n)return;let l={};const c=m.find((t=>t.alias===e));if(c&&e===c.alias?l=c:(l.alias=e,m.push(l)),l.label=null==n?{text:""}:{text:n},null==r)l.type={text:"node"};else if("object"==typeof r){let[t,e]=Object.entries(r)[0];l[t]={text:e}}else l.type={text:r};if(null==i)l.descr={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];l[t]={text:e}}else l.descr={text:i};if("object"==typeof s){let[t,e]=Object.entries(s)[0];l[t]=e}else l.tags=s;if("object"==typeof o){let[t,e]=Object.entries(o)[0];l[t]=e}else l.link=o;l.nodeType=t,l.parentBoundary=g,l.wrap=q(),f=g,g=e,p.push(f)}),"addDeploymentNode"),N=(0,a.eW)((function(){g=f,p.pop(),f=p.pop(),p.push(f)}),"popBoundaryParseStack"),I=(0,a.eW)((function(t,e,n,r,i,a,s,o,l,c,h){let u=d.find((t=>t.alias===e));if(void 0!==u||(u=m.find((t=>t.alias===e)),void 0!==u)){if(null!=n)if("object"==typeof n){let[t,e]=Object.entries(n)[0];u[t]=e}else u.bgColor=n;if(null!=r)if("object"==typeof r){let[t,e]=Object.entries(r)[0];u[t]=e}else u.fontColor=r;if(null!=i)if("object"==typeof i){let[t,e]=Object.entries(i)[0];u[t]=e}else u.borderColor=i;if(null!=a)if("object"==typeof a){let[t,e]=Object.entries(a)[0];u[t]=e}else u.shadowing=a;if(null!=s)if("object"==typeof s){let[t,e]=Object.entries(s)[0];u[t]=e}else u.shape=s;if(null!=o)if("object"==typeof o){let[t,e]=Object.entries(o)[0];u[t]=e}else u.sprite=o;if(null!=l)if("object"==typeof l){let[t,e]=Object.entries(l)[0];u[t]=e}else u.techn=l;if(null!=c)if("object"==typeof c){let[t,e]=Object.entries(c)[0];u[t]=e}else u.legendText=c;if(null!=h)if("object"==typeof h){let[t,e]=Object.entries(h)[0];u[t]=e}else u.legendSprite=h}}),"updateElStyle"),R=(0,a.eW)((function(t,e,n,r,i,a,s){const o=y.find((t=>t.from===e&&t.to===n));if(void 0!==o){if(null!=r)if("object"==typeof r){let[t,e]=Object.entries(r)[0];o[t]=e}else o.textColor=r;if(null!=i)if("object"==typeof i){let[t,e]=Object.entries(i)[0];o[t]=e}else o.lineColor=i;if(null!=a)if("object"==typeof a){let[t,e]=Object.entries(a)[0];o[t]=parseInt(e)}else o.offsetX=parseInt(a);if(null!=s)if("object"==typeof s){let[t,e]=Object.entries(s)[0];o[t]=parseInt(e)}else o.offsetY=parseInt(s)}}),"updateRelStyle"),D=(0,a.eW)((function(t,e,n){let r=b,i=w;if("object"==typeof e){const t=Object.values(e)[0];r=parseInt(t)}else r=parseInt(e);if("object"==typeof n){const t=Object.values(n)[0];i=parseInt(t)}else i=parseInt(n);r>=1&&(b=r),i>=1&&(w=i)}),"updateLayoutConfig"),O=(0,a.eW)((function(){return b}),"getC4ShapeInRow"),P=(0,a.eW)((function(){return w}),"getC4BoundaryInRow"),$=(0,a.eW)((function(){return g}),"getCurrentBoundaryParse"),B=(0,a.eW)((function(){return f}),"getParentBoundaryParse"),F=(0,a.eW)((function(t){return null==t?d:d.filter((e=>e.parentBoundary===t))}),"getC4ShapeArray"),W=(0,a.eW)((function(t){return d.find((e=>e.alias===t))}),"getC4Shape"),z=(0,a.eW)((function(t){return Object.keys(F(t))}),"getC4ShapeKeys"),Z=(0,a.eW)((function(t){return null==t?m:m.filter((e=>e.parentBoundary===t))}),"getBoundaries"),Y=Z,U=(0,a.eW)((function(){return y}),"getRels"),G=(0,a.eW)((function(){return v}),"getTitle"),V=(0,a.eW)((function(t){x=t}),"setWrap"),q=(0,a.eW)((function(){return x}),"autoWrap"),j=(0,a.eW)((function(){d=[],m=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],f="",g="global",p=[""],y=[],p=[""],v="",x=!1,b=4,w=2}),"clear"),H=(0,a.eW)((function(t){let e=(0,a.oO)(t,(0,a.nV)());v=e}),"setTitle"),X={addPersonOrSystem:E,addPersonOrSystemBoundary:A,addContainer:S,addContainerBoundary:L,addComponent:C,addDeploymentNode:M,popBoundaryParseStack:N,addRel:_,updateElStyle:I,updateRelStyle:R,updateLayoutConfig:D,autoWrap:q,setWrap:V,getC4ShapeArray:F,getC4Shape:W,getC4ShapeKeys:z,getBoundaries:Z,getBoundarys:Y,getCurrentBoundaryParse:$,getParentBoundaryParse:B,getRels:U,getTitle:G,getC4Type:k,getC4ShapeInRow:O,getC4BoundaryInRow:P,setAccTitle:a.GN,getAccTitle:a.eu,getAccDescription:a.Mx,setAccDescription:a.U$,getConfig:(0,a.eW)((()=>(0,a.nV)().c4),"getConfig"),clear:j,LINETYPE:{SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25},ARROWTYPE:{FILLED:0,OPEN:1},PLACEMENT:{LEFTOF:0,RIGHTOF:1,OVER:2},setTitle:H,setC4Type:T},K=(0,a.eW)((function(t,e){return(0,r.Mu)(t,e)}),"drawRect"),Q=(0,a.eW)((function(t,e,n,r,i,a){const s=t.append("image");s.attr("width",e),s.attr("height",n),s.attr("x",r),s.attr("y",i);let l=a.startsWith("data:image/png;base64")?a:(0,o.N)(a);s.attr("xlink:href",l)}),"drawImage"),J=(0,a.eW)(((t,e,n)=>{const r=t.append("g");let i=0;for(let t of e){let e=t.textColor?t.textColor:"#444444",a=t.lineColor?t.lineColor:"#444444",s=t.offsetX?parseInt(t.offsetX):0,o=t.offsetY?parseInt(t.offsetY):0,l="";if(0===i){let e=r.append("line");e.attr("x1",t.startPoint.x),e.attr("y1",t.startPoint.y),e.attr("x2",t.endPoint.x),e.attr("y2",t.endPoint.y),e.attr("stroke-width","1"),e.attr("stroke",a),e.style("fill","none"),"rel_b"!==t.type&&e.attr("marker-end","url("+l+"#arrowhead)"),"birel"!==t.type&&"rel_b"!==t.type||e.attr("marker-start","url("+l+"#arrowend)"),i=-1}else{let e=r.append("path");e.attr("fill","none").attr("stroke-width","1").attr("stroke",a).attr("d","Mstartx,starty Qcontrolx,controly stopx,stopy ".replaceAll("startx",t.startPoint.x).replaceAll("starty",t.startPoint.y).replaceAll("controlx",t.startPoint.x+(t.endPoint.x-t.startPoint.x)/2-(t.endPoint.x-t.startPoint.x)/4).replaceAll("controly",t.startPoint.y+(t.endPoint.y-t.startPoint.y)/2).replaceAll("stopx",t.endPoint.x).replaceAll("stopy",t.endPoint.y)),"rel_b"!==t.type&&e.attr("marker-end","url("+l+"#arrowhead)"),"birel"!==t.type&&"rel_b"!==t.type||e.attr("marker-start","url("+l+"#arrowend)")}let c=n.messageFont();ut(n)(t.label.text,r,Math.min(t.startPoint.x,t.endPoint.x)+Math.abs(t.endPoint.x-t.startPoint.x)/2+s,Math.min(t.startPoint.y,t.endPoint.y)+Math.abs(t.endPoint.y-t.startPoint.y)/2+o,t.label.width,t.label.height,{fill:e},c),t.techn&&""!==t.techn.text&&(c=n.messageFont(),ut(n)("["+t.techn.text+"]",r,Math.min(t.startPoint.x,t.endPoint.x)+Math.abs(t.endPoint.x-t.startPoint.x)/2+s,Math.min(t.startPoint.y,t.endPoint.y)+Math.abs(t.endPoint.y-t.startPoint.y)/2+n.messageFontSize+5+o,Math.max(t.label.width,t.techn.width),t.techn.height,{fill:e,"font-style":"italic"},c))}}),"drawRels"),tt=(0,a.eW)((function(t,e,n){const r=t.append("g");let i=e.bgColor?e.bgColor:"none",a=e.borderColor?e.borderColor:"#444444",s=e.fontColor?e.fontColor:"black",o={"stroke-width":1,"stroke-dasharray":"7.0,7.0"};e.nodeType&&(o={"stroke-width":1});let l={x:e.x,y:e.y,fill:i,stroke:a,width:e.width,height:e.height,rx:2.5,ry:2.5,attrs:o};K(r,l);let c=n.boundaryFont();c.fontWeight="bold",c.fontSize=c.fontSize+2,c.fontColor=s,ut(n)(e.label.text,r,e.x,e.y+e.label.Y,e.width,e.height,{fill:"#444444"},c),e.type&&""!==e.type.text&&(c=n.boundaryFont(),c.fontColor=s,ut(n)(e.type.text,r,e.x,e.y+e.type.Y,e.width,e.height,{fill:"#444444"},c)),e.descr&&""!==e.descr.text&&(c=n.boundaryFont(),c.fontSize=c.fontSize-2,c.fontColor=s,ut(n)(e.descr.text,r,e.x,e.y+e.descr.Y,e.width,e.height,{fill:"#444444"},c))}),"drawBoundary"),et=(0,a.eW)((function(t,e,n){let i=e.bgColor?e.bgColor:n[e.typeC4Shape.text+"_bg_color"],a=e.borderColor?e.borderColor:n[e.typeC4Shape.text+"_border_color"],s=e.fontColor?e.fontColor:"#FFFFFF",o="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=";switch(e.typeC4Shape.text){case"person":o="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=";break;case"external_person":o="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAAB6ElEQVR4Xu2YLY+EMBCG9+dWr0aj0Wg0Go1Go0+j8Xdv2uTCvv1gpt0ebHKPuhDaeW4605Z9mJvx4AdXUyTUdd08z+u6flmWZRnHsWkafk9DptAwDPu+f0eAYtu2PEaGWuj5fCIZrBAC2eLBAnRCsEkkxmeaJp7iDJ2QMDdHsLg8SxKFEJaAo8lAXnmuOFIhTMpxxKATebo4UiFknuNo4OniSIXQyRxEA3YsnjGCVEjVXD7yLUAqxBGUyPv/Y4W2beMgGuS7kVQIBycH0fD+oi5pezQETxdHKmQKGk1eQEYldK+jw5GxPfZ9z7Mk0Qnhf1W1m3w//EUn5BDmSZsbR44QQLBEqrBHqOrmSKaQAxdnLArCrxZcM7A7ZKs4ioRq8LFC+NpC3WCBJsvpVw5edm9iEXFuyNfxXAgSwfrFQ1c0iNda8AdejvUgnktOtJQQxmcfFzGglc5WVCj7oDgFqU18boeFSs52CUh8LE8BIVQDT1ABrB0HtgSEYlX5doJnCwv9TXocKCaKbnwhdDKPq4lf3SwU3HLq4V/+WYhHVMa/3b4IlfyikAduCkcBc7mQ3/z/Qq/cTuikhkzB12Ae/mcJC9U+Vo8Ej1gWAtgbeGgFsAMHr50BIWOLCbezvhpBFUdY6EJuJ/QDW0XoMX60zZ0AAAAASUVORK5CYII="}const l=t.append("g");l.attr("class","person-man");const c=(0,r.kc)();switch(e.typeC4Shape.text){case"person":case"external_person":case"system":case"external_system":case"container":case"external_container":case"component":case"external_component":c.x=e.x,c.y=e.y,c.fill=i,c.width=e.width,c.height=e.height,c.stroke=a,c.rx=2.5,c.ry=2.5,c.attrs={"stroke-width":.5},K(l,c);break;case"system_db":case"external_system_db":case"container_db":case"external_container_db":case"component_db":case"external_component_db":l.append("path").attr("fill",i).attr("stroke-width","0.5").attr("stroke",a).attr("d","Mstartx,startyc0,-10 half,-10 half,-10c0,0 half,0 half,10l0,heightc0,10 -half,10 -half,10c0,0 -half,0 -half,-10l0,-height".replaceAll("startx",e.x).replaceAll("starty",e.y).replaceAll("half",e.width/2).replaceAll("height",e.height)),l.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",a).attr("d","Mstartx,startyc0,10 half,10 half,10c0,0 half,0 half,-10".replaceAll("startx",e.x).replaceAll("starty",e.y).replaceAll("half",e.width/2));break;case"system_queue":case"external_system_queue":case"container_queue":case"external_container_queue":case"component_queue":case"external_component_queue":l.append("path").attr("fill",i).attr("stroke-width","0.5").attr("stroke",a).attr("d","Mstartx,startylwidth,0c5,0 5,half 5,halfc0,0 0,half -5,halfl-width,0c-5,0 -5,-half -5,-halfc0,0 0,-half 5,-half".replaceAll("startx",e.x).replaceAll("starty",e.y).replaceAll("width",e.width).replaceAll("half",e.height/2)),l.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",a).attr("d","Mstartx,startyc-5,0 -5,half -5,halfc0,half 5,half 5,half".replaceAll("startx",e.x+e.width).replaceAll("starty",e.y).replaceAll("half",e.height/2))}let h=ht(n,e.typeC4Shape.text);switch(l.append("text").attr("fill",s).attr("font-family",h.fontFamily).attr("font-size",h.fontSize-2).attr("font-style","italic").attr("lengthAdjust","spacing").attr("textLength",e.typeC4Shape.width).attr("x",e.x+e.width/2-e.typeC4Shape.width/2).attr("y",e.y+e.typeC4Shape.Y).text("<<"+e.typeC4Shape.text+">>"),e.typeC4Shape.text){case"person":case"external_person":Q(l,48,48,e.x+e.width/2-24,e.y+e.image.Y,o)}let u=n[e.typeC4Shape.text+"Font"]();return u.fontWeight="bold",u.fontSize=u.fontSize+2,u.fontColor=s,ut(n)(e.label.text,l,e.x,e.y+e.label.Y,e.width,e.height,{fill:s},u),u=n[e.typeC4Shape.text+"Font"](),u.fontColor=s,e.techn&&""!==e.techn?.text?ut(n)(e.techn.text,l,e.x,e.y+e.techn.Y,e.width,e.height,{fill:s,"font-style":"italic"},u):e.type&&""!==e.type.text&&ut(n)(e.type.text,l,e.x,e.y+e.type.Y,e.width,e.height,{fill:s,"font-style":"italic"},u),e.descr&&""!==e.descr.text&&(u=n.personFont(),u.fontColor=s,ut(n)(e.descr.text,l,e.x,e.y+e.descr.Y,e.width,e.height,{fill:s},u)),e.height}),"drawC4Shape"),nt=(0,a.eW)((function(t){t.append("defs").append("symbol").attr("id","database").attr("fill-rule","evenodd").attr("clip-rule","evenodd").append("path").attr("transform","scale(.5)").attr("d","M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z")}),"insertDatabaseIcon"),rt=(0,a.eW)((function(t){t.append("defs").append("symbol").attr("id","computer").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z")}),"insertComputerIcon"),it=(0,a.eW)((function(t){t.append("defs").append("symbol").attr("id","clock").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z")}),"insertClockIcon"),at=(0,a.eW)((function(t){t.append("defs").append("marker").attr("id","arrowhead").attr("refX",9).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z")}),"insertArrowHead"),st=(0,a.eW)((function(t){t.append("defs").append("marker").attr("id","arrowend").attr("refX",1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 10 0 L 0 5 L 10 10 z")}),"insertArrowEnd"),ot=(0,a.eW)((function(t){t.append("defs").append("marker").attr("id","filled-head").attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")}),"insertArrowFilledHead"),lt=(0,a.eW)((function(t){t.append("defs").append("marker").attr("id","sequencenumber").attr("refX",15).attr("refY",15).attr("markerWidth",60).attr("markerHeight",40).attr("orient","auto").append("circle").attr("cx",15).attr("cy",15).attr("r",6)}),"insertDynamicNumber"),ct=(0,a.eW)((function(t){const e=t.append("defs").append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);e.append("path").attr("fill","black").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 9,2 V 6 L16,4 Z"),e.append("path").attr("fill","none").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 0,1 L 6,7 M 6,1 L 0,7")}),"insertArrowCrossHead"),ht=(0,a.eW)(((t,e)=>({fontFamily:t[e+"FontFamily"],fontSize:t[e+"FontSize"],fontWeight:t[e+"FontWeight"]})),"getC4ShapeFont"),ut=function(){function t(t,e,n,i,a,s,o){r(e.append("text").attr("x",n+a/2).attr("y",i+s/2+5).style("text-anchor","middle").text(t),o)}function e(t,e,n,i,s,o,l,c){const{fontSize:h,fontFamily:u,fontWeight:d}=c,p=t.split(a.SY.lineBreakRegex);for(let t=0;t=this.data.widthLimit||n>=this.data.widthLimit||this.nextData.cnt>ft)&&(e=this.nextData.startx+t.margin+yt.nextLinePaddingX,r=this.nextData.stopy+2*t.margin,this.nextData.stopx=n=e+t.width,this.nextData.starty=this.nextData.stopy,this.nextData.stopy=i=r+t.height,this.nextData.cnt=1),t.x=e,t.y=r,this.updateVal(this.data,"startx",e,Math.min),this.updateVal(this.data,"starty",r,Math.min),this.updateVal(this.data,"stopx",n,Math.max),this.updateVal(this.data,"stopy",i,Math.max),this.updateVal(this.nextData,"startx",e,Math.min),this.updateVal(this.nextData,"starty",r,Math.min),this.updateVal(this.nextData,"stopx",n,Math.max),this.updateVal(this.nextData,"stopy",i,Math.max)}init(t){this.name="",this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,widthLimit:void 0},this.nextData={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,cnt:0},xt(t.db.getConfig())}bumpLastMargin(t){this.data.stopx+=t,this.data.stopy+=t}},xt=(0,a.eW)((function(t){(0,a.Yc)(yt,t),t.fontFamily&&(yt.personFontFamily=yt.systemFontFamily=yt.messageFontFamily=t.fontFamily),t.fontSize&&(yt.personFontSize=yt.systemFontSize=yt.messageFontSize=t.fontSize),t.fontWeight&&(yt.personFontWeight=yt.systemFontWeight=yt.messageFontWeight=t.fontWeight)}),"setConf"),bt=(0,a.eW)(((t,e)=>({fontFamily:t[e+"FontFamily"],fontSize:t[e+"FontSize"],fontWeight:t[e+"FontWeight"]})),"c4ShapeFont"),wt=(0,a.eW)((t=>({fontFamily:t.boundaryFontFamily,fontSize:t.boundaryFontSize,fontWeight:t.boundaryFontWeight})),"boundaryFont"),kt=(0,a.eW)((t=>({fontFamily:t.messageFontFamily,fontSize:t.messageFontSize,fontWeight:t.messageFontWeight})),"messageFont");function Tt(t,e,n,r,s){if(!e[t].width)if(n)e[t].text=(0,i.X4)(e[t].text,s,r),e[t].textLines=e[t].text.split(a.SY.lineBreakRegex).length,e[t].width=s,e[t].height=(0,i.XD)(e[t].text,r);else{let n=e[t].text.split(a.SY.lineBreakRegex);e[t].textLines=n.length;let s=0;e[t].height=0,e[t].width=0;for(const a of n)e[t].width=Math.max((0,i.Cq)(a,r),e[t].width),s=(0,i.XD)(a,r),e[t].height=e[t].height+s}}(0,a.eW)(Tt,"calcC4ShapeTextWH");var _t=(0,a.eW)((function(t,e,n){e.x=n.data.startx,e.y=n.data.starty,e.width=n.data.stopx-n.data.startx,e.height=n.data.stopy-n.data.starty,e.label.y=yt.c4ShapeMargin-35;let r=e.wrap&&yt.wrap,a=wt(yt);a.fontSize=a.fontSize+2,a.fontWeight="bold",Tt("label",e,r,a,(0,i.Cq)(e.label.text,a)),dt.drawBoundary(t,e,yt)}),"drawBoundary"),Et=(0,a.eW)((function(t,e,n,r){let a=0;for(const s of r){a=0;const r=n[s];let o=bt(yt,r.typeC4Shape.text);switch(o.fontSize=o.fontSize-2,r.typeC4Shape.width=(0,i.Cq)("«"+r.typeC4Shape.text+"»",o),r.typeC4Shape.height=o.fontSize+2,r.typeC4Shape.Y=yt.c4ShapePadding,a=r.typeC4Shape.Y+r.typeC4Shape.height-4,r.image={width:0,height:0,Y:0},r.typeC4Shape.text){case"person":case"external_person":r.image.width=48,r.image.height=48,r.image.Y=a,a=r.image.Y+r.image.height}r.sprite&&(r.image.width=48,r.image.height=48,r.image.Y=a,a=r.image.Y+r.image.height);let l=r.wrap&&yt.wrap,c=yt.width-2*yt.c4ShapePadding,h=bt(yt,r.typeC4Shape.text);h.fontSize=h.fontSize+2,h.fontWeight="bold",Tt("label",r,l,h,c),r.label.Y=a+8,a=r.label.Y+r.label.height,r.type&&""!==r.type.text?(r.type.text="["+r.type.text+"]",Tt("type",r,l,bt(yt,r.typeC4Shape.text),c),r.type.Y=a+5,a=r.type.Y+r.type.height):r.techn&&""!==r.techn.text&&(r.techn.text="["+r.techn.text+"]",Tt("techn",r,l,bt(yt,r.techn.text),c),r.techn.Y=a+5,a=r.techn.Y+r.techn.height);let u=a,d=r.label.width;r.descr&&""!==r.descr.text&&(Tt("descr",r,l,bt(yt,r.typeC4Shape.text),c),r.descr.Y=a+20,a=r.descr.Y+r.descr.height,d=Math.max(r.label.width,r.descr.width),u=a-5*r.descr.textLines),d+=yt.c4ShapePadding,r.width=Math.max(r.width||yt.width,d,yt.width),r.height=Math.max(r.height||yt.height,u,yt.height),r.margin=r.margin||yt.c4ShapeMargin,t.insert(r),dt.drawC4Shape(e,r,yt)}t.bumpLastMargin(yt.c4ShapeMargin)}),"drawC4ShapeArray"),St=class{static{(0,a.eW)(this,"Point")}constructor(t,e){this.x=t,this.y=e}},Ct=(0,a.eW)((function(t,e){let n=t.x,r=t.y,i=e.x,a=e.y,s=n+t.width/2,o=r+t.height/2,l=Math.abs(n-i),c=Math.abs(r-a),h=c/l,u=t.height/t.width,d=null;return r==a&&ni?d=new St(n,o):n==i&&ra&&(d=new St(s,r)),n>i&&r=h?new St(n,o+h*t.width/2):new St(s-l/c*t.height/2,r+t.height):n=h?new St(n+t.width,o+h*t.width/2):new St(s+l/c*t.height/2,r+t.height):na?d=u>=h?new St(n+t.width,o-h*t.width/2):new St(s+t.height/2*l/c,r):n>i&&r>a&&(d=u>=h?new St(n,o-t.width/2*h):new St(s-t.height/2*l/c,r)),d}),"getIntersectPoint"),At=(0,a.eW)((function(t,e){let n={x:0,y:0};n.x=e.x+e.width/2,n.y=e.y+e.height/2;let r=Ct(t,n);return n.x=t.x+t.width/2,n.y=t.y+t.height/2,{startPoint:r,endPoint:Ct(e,n)}}),"getIntersectPoints"),Lt=(0,a.eW)((function(t,e,n,r){let a=0;for(let t of e){a+=1;let e=t.wrap&&yt.wrap,s=kt(yt);"C4Dynamic"===r.db.getC4Type()&&(t.label.text=a+": "+t.label.text);let o=(0,i.Cq)(t.label.text,s);Tt("label",t,e,s,o),t.techn&&""!==t.techn.text&&(o=(0,i.Cq)(t.techn.text,s),Tt("techn",t,e,s,o)),t.descr&&""!==t.descr.text&&(o=(0,i.Cq)(t.descr.text,s),Tt("descr",t,e,s,o));let l=n(t.from),c=n(t.to),h=At(l,c);t.startPoint=h.startPoint,t.endPoint=h.endPoint}dt.drawRels(t,e,yt)}),"drawRels");function Mt(t,e,n,r,i){let a=new vt(i);a.data.widthLimit=n.data.widthLimit/Math.min(mt,r.length);for(let[s,o]of r.entries()){let r=0;o.image={width:0,height:0,Y:0},o.sprite&&(o.image.width=48,o.image.height=48,o.image.Y=r,r=o.image.Y+o.image.height);let l=o.wrap&&yt.wrap,c=wt(yt);if(c.fontSize=c.fontSize+2,c.fontWeight="bold",Tt("label",o,l,c,a.data.widthLimit),o.label.Y=r+8,r=o.label.Y+o.label.height,o.type&&""!==o.type.text&&(o.type.text="["+o.type.text+"]",Tt("type",o,l,wt(yt),a.data.widthLimit),o.type.Y=r+5,r=o.type.Y+o.type.height),o.descr&&""!==o.descr.text){let t=wt(yt);t.fontSize=t.fontSize-2,Tt("descr",o,l,t,a.data.widthLimit),o.descr.Y=r+20,r=o.descr.Y+o.descr.height}if(0==s||s%mt==0){let t=n.data.startx+yt.diagramMarginX,e=n.data.stopy+yt.diagramMarginY+r;a.setData(t,t,e,e)}else{let t=a.data.stopx!==a.data.startx?a.data.stopx+yt.diagramMarginX:a.data.startx,e=a.data.starty;a.setData(t,t,e,e)}a.name=o.alias;let h=i.db.getC4ShapeArray(o.alias),u=i.db.getC4ShapeKeys(o.alias);u.length>0&&Et(a,t,h,u),e=o.alias;let d=i.db.getBoundarys(e);d.length>0&&Mt(t,e,a,d,i),"global"!==o.alias&&_t(t,o,a),n.data.stopy=Math.max(a.data.stopy+yt.c4ShapeMargin,n.data.stopy),n.data.stopx=Math.max(a.data.stopx+yt.c4ShapeMargin,n.data.stopx),pt=Math.max(pt,n.data.stopx),gt=Math.max(gt,n.data.stopy)}}(0,a.eW)(Mt,"drawInsideBoundary");var Nt={drawPersonOrSystemArray:Et,drawBoundary:_t,setConf:xt,draw:(0,a.eW)((function(t,e,n,r){yt=(0,a.nV)().c4;const i=(0,a.nV)().securityLevel;let o;"sandbox"===i&&(o=(0,s.Ys)("#i"+e));const l="sandbox"===i?(0,s.Ys)(o.nodes()[0].contentDocument.body):(0,s.Ys)("body");let c=r.db;r.db.setWrap(yt.wrap),ft=c.getC4ShapeInRow(),mt=c.getC4BoundaryInRow(),a.cM.debug(`C:${JSON.stringify(yt,null,2)}`);const h="sandbox"===i?l.select(`[id="${e}"]`):(0,s.Ys)(`[id="${e}"]`);dt.insertComputerIcon(h),dt.insertDatabaseIcon(h),dt.insertClockIcon(h);let u=new vt(r);u.setData(yt.diagramMarginX,yt.diagramMarginX,yt.diagramMarginY,yt.diagramMarginY),u.data.widthLimit=screen.availWidth,pt=yt.diagramMarginX,gt=yt.diagramMarginY;const d=r.db.getTitle();Mt(h,"",u,r.db.getBoundarys(""),r),dt.insertArrowHead(h),dt.insertArrowEnd(h),dt.insertArrowCrossHead(h),dt.insertArrowFilledHead(h),Lt(h,r.db.getRels(),r.db.getC4Shape,r),u.data.stopx=pt,u.data.stopy=gt;const p=u.data;let g=p.stopy-p.starty+2*yt.diagramMarginY;const f=p.stopx-p.startx+2*yt.diagramMarginX;d&&h.append("text").text(d).attr("x",(p.stopx-p.startx)/2-4*yt.diagramMarginX).attr("y",p.starty+yt.diagramMarginY),(0,a.v2)(h,g,f,yt.useMaxWidth);const m=d?60:0;h.attr("viewBox",p.startx-yt.diagramMarginX+" -"+(yt.diagramMarginY+m)+" "+f+" "+(g+m)),a.cM.debug("models:",p)}),"draw")},It={parser:u,db:X,renderer:Nt,styles:(0,a.eW)((t=>`.person {\n stroke: ${t.personBorder};\n fill: ${t.personBkg};\n }\n`),"getStyles"),init:(0,a.eW)((({c4:t,wrap:e})=>{Nt.setConf(t),X.setWrap(e)}),"init")}},1957:(t,e,n)=>{"use strict";function r(t,e){t.accDescr&&e.setAccDescription?.(t.accDescr),t.accTitle&&e.setAccTitle?.(t.accTitle),t.title&&e.setDiagramTitle?.(t.title)}n.d(e,{A:()=>r}),(0,n(4082).eW)(r,"populateCommonDb")},2926:(t,e,n)=>{"use strict";n.d(e,{X:()=>r});var r={name:"mermaid",version:"11.6.0",description:"Markdown-ish syntax for generating flowcharts, mindmaps, sequence diagrams, class diagrams, gantt charts, git graphs and more.",type:"module",module:"./dist/mermaid.core.mjs",types:"./dist/mermaid.d.ts",exports:{".":{types:"./dist/mermaid.d.ts",import:"./dist/mermaid.core.mjs",default:"./dist/mermaid.core.mjs"},"./*":"./*"},keywords:["diagram","markdown","flowchart","sequence diagram","gantt","class diagram","git graph","mindmap","packet diagram","c4 diagram","er diagram","pie chart","pie diagram","quadrant chart","requirement diagram","graph"],scripts:{clean:"rimraf dist",dev:"pnpm -w dev","docs:code":"typedoc src/defaultConfig.ts src/config.ts src/mermaid.ts && prettier --write ./src/docs/config/setup","docs:build":"rimraf ../../docs && pnpm docs:code && pnpm docs:spellcheck && tsx scripts/docs.cli.mts","docs:verify":"pnpm docs:code && pnpm docs:spellcheck && tsx scripts/docs.cli.mts --verify","docs:pre:vitepress":"pnpm --filter ./src/docs prefetch && rimraf src/vitepress && pnpm docs:code && tsx scripts/docs.cli.mts --vitepress && pnpm --filter ./src/vitepress install --no-frozen-lockfile --ignore-scripts","docs:build:vitepress":"pnpm docs:pre:vitepress && (cd src/vitepress && pnpm run build) && cpy --flat src/docs/landing/ ./src/vitepress/.vitepress/dist/landing","docs:dev":'pnpm docs:pre:vitepress && concurrently "pnpm --filter ./src/vitepress dev" "tsx scripts/docs.cli.mts --watch --vitepress"',"docs:dev:docker":'pnpm docs:pre:vitepress && concurrently "pnpm --filter ./src/vitepress dev:docker" "tsx scripts/docs.cli.mts --watch --vitepress"',"docs:serve":"pnpm docs:build:vitepress && vitepress serve src/vitepress","docs:spellcheck":'cspell "src/docs/**/*.md"',"docs:release-version":"tsx scripts/update-release-version.mts","docs:verify-version":"tsx scripts/update-release-version.mts --verify","types:build-config":"tsx scripts/create-types-from-json-schema.mts","types:verify-config":"tsx scripts/create-types-from-json-schema.mts --verify",checkCircle:"npx madge --circular ./src",prepublishOnly:"pnpm docs:verify-version"},repository:{type:"git",url:"https://github.com/mermaid-js/mermaid"},author:"Knut Sveidqvist",license:"MIT",standard:{ignore:["**/parser/*.js","dist/**/*.js","cypress/**/*.js"],globals:["page"]},dependencies:{"@braintree/sanitize-url":"^7.0.4","@iconify/utils":"^2.1.33","@mermaid-js/parser":"workspace:^","@types/d3":"^7.4.3",cytoscape:"^3.29.3","cytoscape-cose-bilkent":"^4.1.0","cytoscape-fcose":"^2.2.0",d3:"^7.9.0","d3-sankey":"^0.12.3","dagre-d3-es":"7.0.11",dayjs:"^1.11.13",dompurify:"^3.2.4",katex:"^0.16.9",khroma:"^2.1.0","lodash-es":"^4.17.21",marked:"^15.0.7",roughjs:"^4.6.6",stylis:"^4.3.6","ts-dedent":"^2.2.0",uuid:"^11.1.0"},devDependencies:{"@adobe/jsonschema2md":"^8.0.2","@iconify/types":"^2.0.0","@types/cytoscape":"^3.21.9","@types/cytoscape-fcose":"^2.2.4","@types/d3-sankey":"^0.12.4","@types/d3-scale":"^4.0.9","@types/d3-scale-chromatic":"^3.1.0","@types/d3-selection":"^3.0.11","@types/d3-shape":"^3.1.7","@types/jsdom":"^21.1.7","@types/katex":"^0.16.7","@types/lodash-es":"^4.17.12","@types/micromatch":"^4.0.9","@types/stylis":"^4.2.7","@types/uuid":"^10.0.0",ajv:"^8.17.1",chokidar:"^4.0.3",concurrently:"^9.1.2","csstree-validator":"^4.0.1",globby:"^14.0.2",jison:"^0.4.18","js-base64":"^3.7.7",jsdom:"^26.0.0","json-schema-to-typescript":"^15.0.4",micromatch:"^4.0.8","path-browserify":"^1.0.1",prettier:"^3.5.2",remark:"^15.0.1","remark-frontmatter":"^5.0.0","remark-gfm":"^4.0.1",rimraf:"^6.0.1","start-server-and-test":"^2.0.10","type-fest":"^4.35.0",typedoc:"^0.27.8","typedoc-plugin-markdown":"^4.4.2",typescript:"~5.7.3","unist-util-flatmap":"^1.0.0","unist-util-visit":"^5.0.0",vitepress:"^1.0.2","vitepress-plugin-search":"1.0.4-alpha.22"},files:["dist/","README.md"],publishConfig:{access:"public"}}},9241:(t,e,n)=>{"use strict";n.d(e,{A:()=>Fn,z:()=>Wn});var r=n(4082);function i(t){return null==t}function a(t){return"object"==typeof t&&null!==t}function s(t){return Array.isArray(t)?t:i(t)?[]:[t]}function o(t,e){var n,r,i,a;if(e)for(n=0,r=(a=Object.keys(e)).length;no&&(e=r-o+(a=" ... ").length),n-r>o&&(n=r+o-(s=" ...").length),{str:a+t.slice(e,n).replace(/\t/g,"→")+s,pos:r-e+a.length}}function f(t,e){return h.repeat(" ",e-t.length)+t}function m(t,e){if(e=Object.create(e||null),!t.buffer)return null;e.maxLength||(e.maxLength=79),"number"!=typeof e.indent&&(e.indent=1),"number"!=typeof e.linesBefore&&(e.linesBefore=3),"number"!=typeof e.linesAfter&&(e.linesAfter=2);for(var n,r=/\r?\n|\r|\0/g,i=[0],a=[],s=-1;n=r.exec(t.buffer);)a.push(n.index),i.push(n.index+n[0].length),t.position<=n.index&&s<0&&(s=i.length-2);s<0&&(s=i.length-1);var o,l,c="",u=Math.min(t.line+e.linesAfter,a.length).toString().length,d=e.maxLength-(e.indent+u+3);for(o=1;o<=e.linesBefore&&!(s-o<0);o++)l=g(t.buffer,i[s-o],a[s-o],t.position-(i[s]-i[s-o]),d),c=h.repeat(" ",e.indent)+f((t.line-o+1).toString(),u)+" | "+l.str+"\n"+c;for(l=g(t.buffer,i[s],a[s],t.position,d),c+=h.repeat(" ",e.indent)+f((t.line+1).toString(),u)+" | "+l.str+"\n",c+=h.repeat("-",e.indent+u+3+l.pos)+"^\n",o=1;o<=e.linesAfter&&!(s+o>=a.length);o++)l=g(t.buffer,i[s+o],a[s+o],t.position-(i[s]-i[s+o]),d),c+=h.repeat(" ",e.indent)+f((t.line+o+1).toString(),u)+" | "+l.str+"\n";return c.replace(/\n$/,"")}(0,r.eW)(g,"getLine"),(0,r.eW)(f,"padStart"),(0,r.eW)(m,"makeSnippet");var y=m,v=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],x=["scalar","sequence","mapping"];function b(t){var e={};return null!==t&&Object.keys(t).forEach((function(n){t[n].forEach((function(t){e[String(t)]=n}))})),e}function w(t,e){if(e=e||{},Object.keys(e).forEach((function(e){if(-1===v.indexOf(e))throw new p('Unknown option "'+e+'" is met in definition of "'+t+'" YAML type.')})),this.options=e,this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(t){return t},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.representName=e.representName||null,this.defaultStyle=e.defaultStyle||null,this.multi=e.multi||!1,this.styleAliases=b(e.styleAliases||null),-1===x.indexOf(this.kind))throw new p('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}(0,r.eW)(b,"compileStyleAliases"),(0,r.eW)(w,"Type$1");var k=w;function T(t,e){var n=[];return t[e].forEach((function(t){var e=n.length;n.forEach((function(n,r){n.tag===t.tag&&n.kind===t.kind&&n.multi===t.multi&&(e=r)})),n[e]=t})),n}function _(){var t,e,n={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}};function i(t){t.multi?(n.multi[t.kind].push(t),n.multi.fallback.push(t)):n[t.kind][t.tag]=n.fallback[t.tag]=t}for((0,r.eW)(i,"collectType"),t=0,e=arguments.length;t=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)}),"binary"),octal:(0,r.eW)((function(t){return t>=0?"0o"+t.toString(8):"-0o"+t.toString(8).slice(1)}),"octal"),decimal:(0,r.eW)((function(t){return t.toString(10)}),"decimal"),hexadecimal:(0,r.eW)((function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)}),"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Z=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Y(t){return null!==t&&!(!Z.test(t)||"_"===t[t.length-1])}function U(t){var e,n;return n="-"===(e=t.replace(/_/g,"").toLowerCase())[0]?-1:1,"+-".indexOf(e[0])>=0&&(e=e.slice(1)),".inf"===e?1===n?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:".nan"===e?NaN:n*parseFloat(e,10)}(0,r.eW)(Y,"resolveYamlFloat"),(0,r.eW)(U,"constructYamlFloat");var G=/^[-+]?[0-9]+e/;function V(t,e){var n;if(isNaN(t))switch(e){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===t)switch(e){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===t)switch(e){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(h.isNegativeZero(t))return"-0.0";return n=t.toString(10),G.test(n)?n.replace("e",".e"):n}function q(t){return"[object Number]"===Object.prototype.toString.call(t)&&(t%1!=0||h.isNegativeZero(t))}(0,r.eW)(V,"representYamlFloat"),(0,r.eW)(q,"isFloat");var j=new k("tag:yaml.org,2002:float",{kind:"scalar",resolve:Y,construct:U,predicate:q,represent:V,defaultStyle:"lowercase"}),H=S.extend({implicit:[M,D,z,j]}),X=H,K=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Q=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function J(t){return null!==t&&(null!==K.exec(t)||null!==Q.exec(t))}function tt(t){var e,n,r,i,a,s,o,l,c=0,h=null;if(null===(e=K.exec(t))&&(e=Q.exec(t)),null===e)throw new Error("Date resolve error");if(n=+e[1],r=+e[2]-1,i=+e[3],!e[4])return new Date(Date.UTC(n,r,i));if(a=+e[4],s=+e[5],o=+e[6],e[7]){for(c=e[7].slice(0,3);c.length<3;)c+="0";c=+c}return e[9]&&(h=6e4*(60*+e[10]+ +(e[11]||0)),"-"===e[9]&&(h=-h)),l=new Date(Date.UTC(n,r,i,a,s,o,c)),h&&l.setTime(l.getTime()-h),l}function et(t){return t.toISOString()}(0,r.eW)(J,"resolveYamlTimestamp"),(0,r.eW)(tt,"constructYamlTimestamp"),(0,r.eW)(et,"representYamlTimestamp");var nt=new k("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:J,construct:tt,instanceOf:Date,represent:et});function rt(t){return"<<"===t||null===t}(0,r.eW)(rt,"resolveYamlMerge");var it=new k("tag:yaml.org,2002:merge",{kind:"scalar",resolve:rt}),at="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=\n\r";function st(t){if(null===t)return!1;var e,n,r=0,i=t.length,a=at;for(n=0;n64)){if(e<0)return!1;r+=6}return r%8==0}function ot(t){var e,n,r=t.replace(/[\r\n=]/g,""),i=r.length,a=at,s=0,o=[];for(e=0;e>16&255),o.push(s>>8&255),o.push(255&s)),s=s<<6|a.indexOf(r.charAt(e));return 0==(n=i%4*6)?(o.push(s>>16&255),o.push(s>>8&255),o.push(255&s)):18===n?(o.push(s>>10&255),o.push(s>>2&255)):12===n&&o.push(s>>4&255),new Uint8Array(o)}function lt(t){var e,n,r="",i=0,a=t.length,s=at;for(e=0;e>18&63],r+=s[i>>12&63],r+=s[i>>6&63],r+=s[63&i]),i=(i<<8)+t[e];return 0==(n=a%3)?(r+=s[i>>18&63],r+=s[i>>12&63],r+=s[i>>6&63],r+=s[63&i]):2===n?(r+=s[i>>10&63],r+=s[i>>4&63],r+=s[i<<2&63],r+=s[64]):1===n&&(r+=s[i>>2&63],r+=s[i<<4&63],r+=s[64],r+=s[64]),r}function ct(t){return"[object Uint8Array]"===Object.prototype.toString.call(t)}(0,r.eW)(st,"resolveYamlBinary"),(0,r.eW)(ot,"constructYamlBinary"),(0,r.eW)(lt,"representYamlBinary"),(0,r.eW)(ct,"isBinary");var ht=new k("tag:yaml.org,2002:binary",{kind:"scalar",resolve:st,construct:ot,predicate:ct,represent:lt}),ut=Object.prototype.hasOwnProperty,dt=Object.prototype.toString;function pt(t){if(null===t)return!0;var e,n,r,i,a,s=[],o=t;for(e=0,n=o.length;e>10),56320+(t-65536&1023))}(0,r.eW)(Bt,"_class"),(0,r.eW)(Ft,"is_EOL"),(0,r.eW)(Wt,"is_WHITE_SPACE"),(0,r.eW)(zt,"is_WS_OR_EOL"),(0,r.eW)(Zt,"is_FLOW_INDICATOR"),(0,r.eW)(Yt,"fromHexCode"),(0,r.eW)(Ut,"escapedHexLen"),(0,r.eW)(Gt,"fromDecimalCode"),(0,r.eW)(Vt,"simpleEscapeSequence"),(0,r.eW)(qt,"charFromCodepoint");var jt,Ht=new Array(256),Xt=new Array(256);for(jt=0;jt<256;jt++)Ht[jt]=Vt(jt)?1:0,Xt[jt]=Vt(jt);function Kt(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||_t,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function Qt(t,e){var n={name:t.filename,buffer:t.input.slice(0,-1),position:t.position,line:t.line,column:t.position-t.lineStart};return n.snippet=y(n),new p(e,n)}function Jt(t,e){throw Qt(t,e)}function te(t,e){t.onWarning&&t.onWarning.call(null,Qt(t,e))}(0,r.eW)(Kt,"State$1"),(0,r.eW)(Qt,"generateError"),(0,r.eW)(Jt,"throwError"),(0,r.eW)(te,"throwWarning");var ee={YAML:(0,r.eW)((function(t,e,n){var r,i,a;null!==t.version&&Jt(t,"duplication of %YAML directive"),1!==n.length&&Jt(t,"YAML directive accepts exactly one argument"),null===(r=/^([0-9]+)\.([0-9]+)$/.exec(n[0]))&&Jt(t,"ill-formed argument of the YAML directive"),i=parseInt(r[1],10),a=parseInt(r[2],10),1!==i&&Jt(t,"unacceptable YAML version of the document"),t.version=n[0],t.checkLineBreaks=a<2,1!==a&&2!==a&&te(t,"unsupported YAML version of the document")}),"handleYamlDirective"),TAG:(0,r.eW)((function(t,e,n){var r,i;2!==n.length&&Jt(t,"TAG directive accepts exactly two arguments"),r=n[0],i=n[1],Pt.test(r)||Jt(t,"ill-formed tag handle (first argument) of the TAG directive"),Et.call(t.tagMap,r)&&Jt(t,'there is a previously declared suffix for "'+r+'" tag handle'),$t.test(i)||Jt(t,"ill-formed tag prefix (second argument) of the TAG directive");try{i=decodeURIComponent(i)}catch(e){Jt(t,"tag prefix is malformed: "+i)}t.tagMap[r]=i}),"handleTagDirective")};function ne(t,e,n,r){var i,a,s,o;if(e1&&(t.result+=h.repeat("\n",e-1))}function ce(t,e,n){var r,i,a,s,o,l,c,h,u=t.kind,d=t.result;if(zt(h=t.input.charCodeAt(t.position))||Zt(h)||35===h||38===h||42===h||33===h||124===h||62===h||39===h||34===h||37===h||64===h||96===h)return!1;if((63===h||45===h)&&(zt(r=t.input.charCodeAt(t.position+1))||n&&Zt(r)))return!1;for(t.kind="scalar",t.result="",i=a=t.position,s=!1;0!==h;){if(58===h){if(zt(r=t.input.charCodeAt(t.position+1))||n&&Zt(r))break}else if(35===h){if(zt(t.input.charCodeAt(t.position-1)))break}else{if(t.position===t.lineStart&&oe(t)||n&&Zt(h))break;if(Ft(h)){if(o=t.line,l=t.lineStart,c=t.lineIndent,se(t,!1,-1),t.lineIndent>=e){s=!0,h=t.input.charCodeAt(t.position);continue}t.position=a,t.line=o,t.lineStart=l,t.lineIndent=c;break}}s&&(ne(t,i,a,!1),le(t,t.line-o),i=a=t.position,s=!1),Wt(h)||(a=t.position+1),h=t.input.charCodeAt(++t.position)}return ne(t,i,a,!1),!!t.result||(t.kind=u,t.result=d,!1)}function he(t,e){var n,r,i;if(39!==(n=t.input.charCodeAt(t.position)))return!1;for(t.kind="scalar",t.result="",t.position++,r=i=t.position;0!==(n=t.input.charCodeAt(t.position));)if(39===n){if(ne(t,r,t.position,!0),39!==(n=t.input.charCodeAt(++t.position)))return!0;r=t.position,t.position++,i=t.position}else Ft(n)?(ne(t,r,i,!0),le(t,se(t,!1,e)),r=i=t.position):t.position===t.lineStart&&oe(t)?Jt(t,"unexpected end of the document within a single quoted scalar"):(t.position++,i=t.position);Jt(t,"unexpected end of the stream within a single quoted scalar")}function ue(t,e){var n,r,i,a,s,o;if(34!==(o=t.input.charCodeAt(t.position)))return!1;for(t.kind="scalar",t.result="",t.position++,n=r=t.position;0!==(o=t.input.charCodeAt(t.position));){if(34===o)return ne(t,n,t.position,!0),t.position++,!0;if(92===o){if(ne(t,n,t.position,!0),Ft(o=t.input.charCodeAt(++t.position)))se(t,!1,e);else if(o<256&&Ht[o])t.result+=Xt[o],t.position++;else if((s=Ut(o))>0){for(i=s,a=0;i>0;i--)(s=Yt(o=t.input.charCodeAt(++t.position)))>=0?a=(a<<4)+s:Jt(t,"expected hexadecimal character");t.result+=qt(a),t.position++}else Jt(t,"unknown escape sequence");n=r=t.position}else Ft(o)?(ne(t,n,r,!0),le(t,se(t,!1,e)),n=r=t.position):t.position===t.lineStart&&oe(t)?Jt(t,"unexpected end of the document within a double quoted scalar"):(t.position++,r=t.position)}Jt(t,"unexpected end of the stream within a double quoted scalar")}function de(t,e){var n,r,i,a,s,o,l,c,h,u,d,p,g=!0,f=t.tag,m=t.anchor,y=Object.create(null);if(91===(p=t.input.charCodeAt(t.position)))s=93,c=!1,a=[];else{if(123!==p)return!1;s=125,c=!0,a={}}for(null!==t.anchor&&(t.anchorMap[t.anchor]=a),p=t.input.charCodeAt(++t.position);0!==p;){if(se(t,!0,e),(p=t.input.charCodeAt(t.position))===s)return t.position++,t.tag=f,t.anchor=m,t.kind=c?"mapping":"sequence",t.result=a,!0;g?44===p&&Jt(t,"expected the node content, but found ','"):Jt(t,"missed comma between flow collection entries"),d=null,o=l=!1,63===p&&zt(t.input.charCodeAt(t.position+1))&&(o=l=!0,t.position++,se(t,!0,e)),n=t.line,r=t.lineStart,i=t.position,xe(t,e,St,!1,!0),u=t.tag,h=t.result,se(t,!0,e),p=t.input.charCodeAt(t.position),!l&&t.line!==n||58!==p||(o=!0,p=t.input.charCodeAt(++t.position),se(t,!0,e),xe(t,e,St,!1,!0),d=t.result),c?ie(t,a,y,u,h,d,n,r,i):o?a.push(ie(t,null,y,u,h,d,n,r,i)):a.push(h),se(t,!0,e),44===(p=t.input.charCodeAt(t.position))?(g=!0,p=t.input.charCodeAt(++t.position)):g=!1}Jt(t,"unexpected end of the stream within a flow collection")}function pe(t,e){var n,r,i,a,s=Mt,o=!1,l=!1,c=e,u=0,d=!1;if(124===(a=t.input.charCodeAt(t.position)))r=!1;else{if(62!==a)return!1;r=!0}for(t.kind="scalar",t.result="";0!==a;)if(43===(a=t.input.charCodeAt(++t.position))||45===a)Mt===s?s=43===a?It:Nt:Jt(t,"repeat of a chomping mode identifier");else{if(!((i=Gt(a))>=0))break;0===i?Jt(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):l?Jt(t,"repeat of an indentation width identifier"):(c=e+i-1,l=!0)}if(Wt(a)){do{a=t.input.charCodeAt(++t.position)}while(Wt(a));if(35===a)do{a=t.input.charCodeAt(++t.position)}while(!Ft(a)&&0!==a)}for(;0!==a;){for(ae(t),t.lineIndent=0,a=t.input.charCodeAt(t.position);(!l||t.lineIndentc&&(c=t.lineIndent),Ft(a))u++;else{if(t.lineIndente)&&0!==r)Jt(t,"bad indentation of a sequence entry");else if(t.lineIndente)&&(y&&(s=t.line,o=t.lineStart,l=t.position),xe(t,e,Lt,!0,i)&&(y?f=t.result:m=t.result),y||(ie(t,d,p,g,f,m,s,o,l),g=f=m=null),se(t,!0,-1),c=t.input.charCodeAt(t.position)),(t.line===a||t.lineIndent>e)&&0!==c)Jt(t,"bad indentation of a mapping entry");else if(t.lineIndente?g=1:t.lineIndent===e?g=0:t.lineIndente?g=1:t.lineIndent===e?g=0:t.lineIndent tag; it should be "scalar", not "'+t.kind+'"'),l=0,c=t.implicitTypes.length;l"),null!==t.result&&u.kind!==t.kind&&Jt(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+u.kind+'", not "'+t.kind+'"'),u.resolve(t.result,t.tag)?(t.result=u.construct(t.result,t.tag),null!==t.anchor&&(t.anchorMap[t.anchor]=t.result)):Jt(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return null!==t.listener&&t.listener("close",t),null!==t.tag||null!==t.anchor||m}function be(t){var e,n,r,i,a=t.position,s=!1;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap=Object.create(null),t.anchorMap=Object.create(null);0!==(i=t.input.charCodeAt(t.position))&&(se(t,!0,-1),i=t.input.charCodeAt(t.position),!(t.lineIndent>0||37!==i));){for(s=!0,i=t.input.charCodeAt(++t.position),e=t.position;0!==i&&!zt(i);)i=t.input.charCodeAt(++t.position);for(r=[],(n=t.input.slice(e,t.position)).length<1&&Jt(t,"directive name must not be less than one character in length");0!==i;){for(;Wt(i);)i=t.input.charCodeAt(++t.position);if(35===i){do{i=t.input.charCodeAt(++t.position)}while(0!==i&&!Ft(i));break}if(Ft(i))break;for(e=t.position;0!==i&&!zt(i);)i=t.input.charCodeAt(++t.position);r.push(t.input.slice(e,t.position))}0!==i&&ae(t),Et.call(ee,n)?ee[n](t,n,r):te(t,'unknown document directive "'+n+'"')}se(t,!0,-1),0===t.lineIndent&&45===t.input.charCodeAt(t.position)&&45===t.input.charCodeAt(t.position+1)&&45===t.input.charCodeAt(t.position+2)?(t.position+=3,se(t,!0,-1)):s&&Jt(t,"directives end mark is expected"),xe(t,t.lineIndent-1,Lt,!1,!0),se(t,!0,-1),t.checkLineBreaks&&Dt.test(t.input.slice(a,t.position))&&te(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&oe(t)?46===t.input.charCodeAt(t.position)&&(t.position+=3,se(t,!0,-1)):t.position=55296&&r<=56319&&e+1=56320&&n<=57343?1024*(r-55296)+n-56320+65536:r}function yn(t){return/^\n* /.test(t)}(0,r.eW)(sn,"State"),(0,r.eW)(on,"indentString"),(0,r.eW)(ln,"generateNextLine"),(0,r.eW)(cn,"testImplicitResolving"),(0,r.eW)(hn,"isWhitespace"),(0,r.eW)(un,"isPrintable"),(0,r.eW)(dn,"isNsCharOrWhitespace"),(0,r.eW)(pn,"isPlainSafe"),(0,r.eW)(gn,"isPlainSafeFirst"),(0,r.eW)(fn,"isPlainSafeLast"),(0,r.eW)(mn,"codePointAt"),(0,r.eW)(yn,"needIndentIndicator");var vn=1,xn=2,bn=3,wn=4,kn=5;function Tn(t,e,n,r,i,a,s,o){var l,c=0,h=null,u=!1,d=!1,p=-1!==r,g=-1,f=gn(mn(t,0))&&fn(mn(t,t.length-1));if(e||s)for(l=0;l=65536?l+=2:l++){if(!un(c=mn(t,l)))return kn;f=f&&pn(c,h,o),h=c}else{for(l=0;l=65536?l+=2:l++){if((c=mn(t,l))===Le)u=!0,p&&(d=d||l-g-1>r&&" "!==t[g+1],g=l);else if(!un(c))return kn;f=f&&pn(c,h,o),h=c}d=d||p&&l-g-1>r&&" "!==t[g+1]}return u||d?n>9&&yn(t)?kn:s?a===an?kn:xn:d?wn:bn:!f||s||i(t)?a===an?kn:xn:vn}function _n(t,e,n,i,a){t.dump=function(){if(0===e.length)return t.quotingType===an?'""':"''";if(!t.noCompatMode&&(-1!==Je.indexOf(e)||tn.test(e)))return t.quotingType===an?'"'+e+'"':"'"+e+"'";var s=t.indent*Math.max(1,n),o=-1===t.lineWidth?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-s),l=i||t.flowLevel>-1&&n>=t.flowLevel;function c(e){return cn(t,e)}switch((0,r.eW)(c,"testAmbiguity"),Tn(e,l,t.indent,o,c,t.quotingType,t.forceQuotes&&!i,a)){case vn:return e;case xn:return"'"+e.replace(/'/g,"''")+"'";case bn:return"|"+En(e,t.indent)+Sn(on(e,s));case wn:return">"+En(e,t.indent)+Sn(on(Cn(e,o),s));case kn:return'"'+Ln(e)+'"';default:throw new p("impossible error: invalid scalar style")}}()}function En(t,e){var n=yn(t)?String(e):"",r="\n"===t[t.length-1];return n+(!r||"\n"!==t[t.length-2]&&"\n"!==t?r?"":"-":"+")+"\n"}function Sn(t){return"\n"===t[t.length-1]?t.slice(0,-1):t}function Cn(t,e){for(var n,r,i,a=/(\n+)([^\n]*)/g,s=(n=-1!==(n=t.indexOf("\n"))?n:t.length,a.lastIndex=n,An(t.slice(0,n),e)),o="\n"===t[0]||" "===t[0];i=a.exec(t);){var l=i[1],c=i[2];r=" "===c[0],s+=l+(o||r||""===c?"":"\n")+An(c,e),o=r}return s}function An(t,e){if(""===t||" "===t[0])return t;for(var n,r,i=/ [^ ]/g,a=0,s=0,o=0,l="";n=i.exec(t);)(o=n.index)-a>e&&(r=s>a?s:o,l+="\n"+t.slice(a,r),a=r+1),s=o;return l+="\n",t.length-a>e&&s>a?l+=t.slice(a,s)+"\n"+t.slice(s+1):l+=t.slice(a),l.slice(1)}function Ln(t){for(var e,n="",r=0,i=0;i=65536?i+=2:i++)r=mn(t,i),!(e=Qe[r])&&un(r)?(n+=t[i],r>=65536&&(n+=t[i+1])):n+=e||nn(r);return n}function Mn(t,e,n){var r,i,a,s="",o=t.tag;for(r=0,i=n.length;r1024&&(o+="? "),o+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),On(t,e,s,!1,!1)&&(l+=o+=t.dump));t.tag=c,t.dump="{"+l+"}"}function Rn(t,e,n,r){var i,a,s,o,l,c,h="",u=t.tag,d=Object.keys(n);if(!0===t.sortKeys)d.sort();else if("function"==typeof t.sortKeys)d.sort(t.sortKeys);else if(t.sortKeys)throw new p("sortKeys must be a boolean or a function");for(i=0,a=d.length;i1024)&&(t.dump&&Le===t.dump.charCodeAt(0)?c+="?":c+="? "),c+=t.dump,l&&(c+=ln(t,e)),On(t,e+1,o,!0,l)&&(t.dump&&Le===t.dump.charCodeAt(0)?c+=":":c+=": ",h+=c+=t.dump));t.tag=u,t.dump=h||"{}"}function Dn(t,e,n){var r,i,a,s,o,l;for(a=0,s=(i=n?t.explicitTypes:t.implicitTypes).length;a tag resolver accepts not "'+l+'" style');r=o.represent[l](e,l)}t.dump=r}return!0}return!1}function On(t,e,n,r,i,a,s){t.tag=null,t.dump=n,Dn(t,n,!1)||Dn(t,n,!0);var o,l=Ee.call(t.dump),c=r;r&&(r=t.flowLevel<0||t.flowLevel>e);var h,u,d="[object Object]"===l||"[object Array]"===l;if(d&&(u=-1!==(h=t.duplicates.indexOf(n))),(null!==t.tag&&"?"!==t.tag||u||2!==t.indent&&e>0)&&(i=!1),u&&t.usedDuplicates[h])t.dump="*ref_"+h;else{if(d&&u&&!t.usedDuplicates[h]&&(t.usedDuplicates[h]=!0),"[object Object]"===l)r&&0!==Object.keys(t.dump).length?(Rn(t,e,t.dump,i),u&&(t.dump="&ref_"+h+t.dump)):(In(t,e,t.dump),u&&(t.dump="&ref_"+h+" "+t.dump));else if("[object Array]"===l)r&&0!==t.dump.length?(t.noArrayIndent&&!s&&e>0?Nn(t,e-1,t.dump,i):Nn(t,e,t.dump,i),u&&(t.dump="&ref_"+h+t.dump)):(Mn(t,e,t.dump),u&&(t.dump="&ref_"+h+" "+t.dump));else{if("[object String]"!==l){if("[object Undefined]"===l)return!1;if(t.skipInvalid)return!1;throw new p("unacceptable kind of an object to dump "+l)}"?"!==t.tag&&_n(t,t.dump,e,a,c)}null!==t.tag&&"?"!==t.tag&&(o=encodeURI("!"===t.tag[0]?t.tag.slice(1):t.tag).replace(/!/g,"%21"),o="!"===t.tag[0]?"!"+o:"tag:yaml.org,2002:"===o.slice(0,18)?"!!"+o.slice(18):"!<"+o+">",t.dump=o+" "+t.dump)}return!0}function Pn(t,e){var n,r,i=[],a=[];for($n(t,i,a),n=0,r=a.length;n{"use strict";n.d(e,{P:()=>a});var r=n(4082),i=n(3108),a=(0,r.eW)((t=>{const{securityLevel:e}=(0,r.nV)();let n=(0,i.Ys)("body");if("sandbox"===e){const e=(0,i.Ys)(`#i${t}`),r=e.node()?.contentDocument??document;n=(0,i.Ys)(r.body)}return n.select(`#${t}`)}),"selectSvgElement")},762:(t,e,n)=>{"use strict";n.d(e,{Ee:()=>m,P0:()=>c,b0:()=>v,dR:()=>f});var r=n(907),i=n(8337),a=n(7946),s=n(4082),o=n(3108),l=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,18],n=[1,19],r=[1,20],i=[1,41],a=[1,42],o=[1,26],l=[1,24],c=[1,25],h=[1,32],u=[1,33],d=[1,34],p=[1,45],g=[1,35],f=[1,36],m=[1,37],y=[1,38],v=[1,27],x=[1,28],b=[1,29],w=[1,30],k=[1,31],T=[1,44],_=[1,46],E=[1,43],S=[1,47],C=[1,9],A=[1,8,9],L=[1,58],M=[1,59],N=[1,60],I=[1,61],R=[1,62],D=[1,63],O=[1,64],P=[1,8,9,41],$=[1,76],B=[1,8,9,12,13,22,39,41,44,66,67,68,69,70,71,72,77,79],F=[1,8,9,12,13,17,20,22,39,41,44,48,58,66,67,68,69,70,71,72,77,79,84,99,101,102],W=[13,58,84,99,101,102],z=[13,58,71,72,84,99,101,102],Z=[13,58,66,67,68,69,70,84,99,101,102],Y=[1,98],U=[1,115],G=[1,107],V=[1,113],q=[1,108],j=[1,109],H=[1,110],X=[1,111],K=[1,112],Q=[1,114],J=[22,58,59,80,84,85,86,87,88,89],tt=[1,8,9,39,41,44],et=[1,8,9,22],nt=[1,143],rt=[1,8,9,59],it=[1,8,9,22,58,59,80,84,85,86,87,88,89],at={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,statements:5,graphConfig:6,CLASS_DIAGRAM:7,NEWLINE:8,EOF:9,statement:10,classLabel:11,SQS:12,STR:13,SQE:14,namespaceName:15,alphaNumToken:16,DOT:17,className:18,classLiteralName:19,GENERICTYPE:20,relationStatement:21,LABEL:22,namespaceStatement:23,classStatement:24,memberStatement:25,annotationStatement:26,clickStatement:27,styleStatement:28,cssClassStatement:29,noteStatement:30,classDefStatement:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,namespaceIdentifier:38,STRUCT_START:39,classStatements:40,STRUCT_STOP:41,NAMESPACE:42,classIdentifier:43,STYLE_SEPARATOR:44,members:45,CLASS:46,ANNOTATION_START:47,ANNOTATION_END:48,MEMBER:49,SEPARATOR:50,relation:51,NOTE_FOR:52,noteText:53,NOTE:54,CLASSDEF:55,classList:56,stylesOpt:57,ALPHA:58,COMMA:59,direction_tb:60,direction_bt:61,direction_rl:62,direction_lr:63,relationType:64,lineType:65,AGGREGATION:66,EXTENSION:67,COMPOSITION:68,DEPENDENCY:69,LOLLIPOP:70,LINE:71,DOTTED_LINE:72,CALLBACK:73,LINK:74,LINK_TARGET:75,CLICK:76,CALLBACK_NAME:77,CALLBACK_ARGS:78,HREF:79,STYLE:80,CSSCLASS:81,style:82,styleComponent:83,NUM:84,COLON:85,UNIT:86,SPACE:87,BRKT:88,PCT:89,commentToken:90,textToken:91,graphCodeTokens:92,textNoTagsToken:93,TAGSTART:94,TAGEND:95,"==":96,"--":97,DEFAULT:98,MINUS:99,keywords:100,UNICODE_TEXT:101,BQUOTE_STR:102,$accept:0,$end:1},terminals_:{2:"error",7:"CLASS_DIAGRAM",8:"NEWLINE",9:"EOF",12:"SQS",13:"STR",14:"SQE",17:"DOT",20:"GENERICTYPE",22:"LABEL",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",39:"STRUCT_START",41:"STRUCT_STOP",42:"NAMESPACE",44:"STYLE_SEPARATOR",46:"CLASS",47:"ANNOTATION_START",48:"ANNOTATION_END",49:"MEMBER",50:"SEPARATOR",52:"NOTE_FOR",54:"NOTE",55:"CLASSDEF",58:"ALPHA",59:"COMMA",60:"direction_tb",61:"direction_bt",62:"direction_rl",63:"direction_lr",66:"AGGREGATION",67:"EXTENSION",68:"COMPOSITION",69:"DEPENDENCY",70:"LOLLIPOP",71:"LINE",72:"DOTTED_LINE",73:"CALLBACK",74:"LINK",75:"LINK_TARGET",76:"CLICK",77:"CALLBACK_NAME",78:"CALLBACK_ARGS",79:"HREF",80:"STYLE",81:"CSSCLASS",84:"NUM",85:"COLON",86:"UNIT",87:"SPACE",88:"BRKT",89:"PCT",92:"graphCodeTokens",94:"TAGSTART",95:"TAGEND",96:"==",97:"--",98:"DEFAULT",99:"MINUS",100:"keywords",101:"UNICODE_TEXT",102:"BQUOTE_STR"},productions_:[0,[3,1],[3,1],[4,1],[6,4],[5,1],[5,2],[5,3],[11,3],[15,1],[15,3],[15,2],[18,1],[18,3],[18,1],[18,2],[18,2],[18,2],[10,1],[10,2],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,2],[10,1],[23,4],[23,5],[38,2],[40,1],[40,2],[40,3],[24,1],[24,3],[24,4],[24,6],[43,2],[43,3],[26,4],[45,1],[45,2],[25,1],[25,2],[25,1],[25,1],[21,3],[21,4],[21,4],[21,5],[30,3],[30,2],[31,3],[56,1],[56,3],[32,1],[32,1],[32,1],[32,1],[51,3],[51,2],[51,2],[51,1],[64,1],[64,1],[64,1],[64,1],[64,1],[65,1],[65,1],[27,3],[27,4],[27,3],[27,4],[27,4],[27,5],[27,3],[27,4],[27,4],[27,5],[27,4],[27,5],[27,5],[27,6],[28,3],[29,3],[57,1],[57,3],[82,1],[82,2],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[90,1],[90,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[93,1],[93,1],[93,1],[93,1],[16,1],[16,1],[16,1],[16,1],[19,1],[53,1]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 8:this.$=a[o-1];break;case 9:case 12:case 14:this.$=a[o];break;case 10:case 13:this.$=a[o-2]+"."+a[o];break;case 11:case 15:case 95:this.$=a[o-1]+a[o];break;case 16:case 17:this.$=a[o-1]+"~"+a[o]+"~";break;case 18:r.addRelation(a[o]);break;case 19:a[o-1].title=r.cleanupLabel(a[o]),r.addRelation(a[o-1]);break;case 30:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 31:case 32:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 33:r.addClassesToNamespace(a[o-3],a[o-1]);break;case 34:r.addClassesToNamespace(a[o-4],a[o-1]);break;case 35:this.$=a[o],r.addNamespace(a[o]);break;case 36:case 46:case 59:case 92:this.$=[a[o]];break;case 37:this.$=[a[o-1]];break;case 38:a[o].unshift(a[o-2]),this.$=a[o];break;case 40:r.setCssClass(a[o-2],a[o]);break;case 41:r.addMembers(a[o-3],a[o-1]);break;case 42:r.setCssClass(a[o-5],a[o-3]),r.addMembers(a[o-5],a[o-1]);break;case 43:this.$=a[o],r.addClass(a[o]);break;case 44:this.$=a[o-1],r.addClass(a[o-1]),r.setClassLabel(a[o-1],a[o]);break;case 45:r.addAnnotation(a[o],a[o-2]);break;case 47:a[o].push(a[o-1]),this.$=a[o];break;case 48:case 50:case 51:break;case 49:r.addMember(a[o-1],r.cleanupLabel(a[o]));break;case 52:this.$={id1:a[o-2],id2:a[o],relation:a[o-1],relationTitle1:"none",relationTitle2:"none"};break;case 53:this.$={id1:a[o-3],id2:a[o],relation:a[o-1],relationTitle1:a[o-2],relationTitle2:"none"};break;case 54:this.$={id1:a[o-3],id2:a[o],relation:a[o-2],relationTitle1:"none",relationTitle2:a[o-1]};break;case 55:this.$={id1:a[o-4],id2:a[o],relation:a[o-2],relationTitle1:a[o-3],relationTitle2:a[o-1]};break;case 56:r.addNote(a[o],a[o-1]);break;case 57:r.addNote(a[o]);break;case 58:this.$=a[o-2],r.defineClass(a[o-1],a[o]);break;case 60:this.$=a[o-2].concat([a[o]]);break;case 61:r.setDirection("TB");break;case 62:r.setDirection("BT");break;case 63:r.setDirection("RL");break;case 64:r.setDirection("LR");break;case 65:this.$={type1:a[o-2],type2:a[o],lineType:a[o-1]};break;case 66:this.$={type1:"none",type2:a[o],lineType:a[o-1]};break;case 67:this.$={type1:a[o-1],type2:"none",lineType:a[o]};break;case 68:this.$={type1:"none",type2:"none",lineType:a[o]};break;case 69:this.$=r.relationType.AGGREGATION;break;case 70:this.$=r.relationType.EXTENSION;break;case 71:this.$=r.relationType.COMPOSITION;break;case 72:this.$=r.relationType.DEPENDENCY;break;case 73:this.$=r.relationType.LOLLIPOP;break;case 74:this.$=r.lineType.LINE;break;case 75:this.$=r.lineType.DOTTED_LINE;break;case 76:case 82:this.$=a[o-2],r.setClickEvent(a[o-1],a[o]);break;case 77:case 83:this.$=a[o-3],r.setClickEvent(a[o-2],a[o-1]),r.setTooltip(a[o-2],a[o]);break;case 78:this.$=a[o-2],r.setLink(a[o-1],a[o]);break;case 79:this.$=a[o-3],r.setLink(a[o-2],a[o-1],a[o]);break;case 80:this.$=a[o-3],r.setLink(a[o-2],a[o-1]),r.setTooltip(a[o-2],a[o]);break;case 81:this.$=a[o-4],r.setLink(a[o-3],a[o-2],a[o]),r.setTooltip(a[o-3],a[o-1]);break;case 84:this.$=a[o-3],r.setClickEvent(a[o-2],a[o-1],a[o]);break;case 85:this.$=a[o-4],r.setClickEvent(a[o-3],a[o-2],a[o-1]),r.setTooltip(a[o-3],a[o]);break;case 86:this.$=a[o-3],r.setLink(a[o-2],a[o]);break;case 87:this.$=a[o-4],r.setLink(a[o-3],a[o-1],a[o]);break;case 88:this.$=a[o-4],r.setLink(a[o-3],a[o-1]),r.setTooltip(a[o-3],a[o]);break;case 89:this.$=a[o-5],r.setLink(a[o-4],a[o-2],a[o]),r.setTooltip(a[o-4],a[o-1]);break;case 90:this.$=a[o-2],r.setCssStyle(a[o-1],a[o]);break;case 91:r.setCssClass(a[o-1],a[o]);break;case 93:a[o-2].push(a[o]),this.$=a[o-2]}}),"anonymous"),table:[{3:1,4:2,5:3,6:4,7:[1,6],10:5,16:39,18:21,19:40,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:e,35:n,37:r,38:22,42:i,43:23,46:a,47:o,49:l,50:c,52:h,54:u,55:d,58:p,60:g,61:f,62:m,63:y,73:v,74:x,76:b,80:w,81:k,84:T,99:_,101:E,102:S},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},t(C,[2,5],{8:[1,48]}),{8:[1,49]},t(A,[2,18],{22:[1,50]}),t(A,[2,20]),t(A,[2,21]),t(A,[2,22]),t(A,[2,23]),t(A,[2,24]),t(A,[2,25]),t(A,[2,26]),t(A,[2,27]),t(A,[2,28]),t(A,[2,29]),{34:[1,51]},{36:[1,52]},t(A,[2,32]),t(A,[2,48],{51:53,64:56,65:57,13:[1,54],22:[1,55],66:L,67:M,68:N,69:I,70:R,71:D,72:O}),{39:[1,65]},t(P,[2,39],{39:[1,67],44:[1,66]}),t(A,[2,50]),t(A,[2,51]),{16:68,58:p,84:T,99:_,101:E},{16:39,18:69,19:40,58:p,84:T,99:_,101:E,102:S},{16:39,18:70,19:40,58:p,84:T,99:_,101:E,102:S},{16:39,18:71,19:40,58:p,84:T,99:_,101:E,102:S},{58:[1,72]},{13:[1,73]},{16:39,18:74,19:40,58:p,84:T,99:_,101:E,102:S},{13:$,53:75},{56:77,58:[1,78]},t(A,[2,61]),t(A,[2,62]),t(A,[2,63]),t(A,[2,64]),t(B,[2,12],{16:39,19:40,18:80,17:[1,79],20:[1,81],58:p,84:T,99:_,101:E,102:S}),t(B,[2,14],{20:[1,82]}),{15:83,16:84,58:p,84:T,99:_,101:E},{16:39,18:85,19:40,58:p,84:T,99:_,101:E,102:S},t(F,[2,118]),t(F,[2,119]),t(F,[2,120]),t(F,[2,121]),t([1,8,9,12,13,20,22,39,41,44,66,67,68,69,70,71,72,77,79],[2,122]),t(C,[2,6],{10:5,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,18:21,38:22,43:23,16:39,19:40,5:86,33:e,35:n,37:r,42:i,46:a,47:o,49:l,50:c,52:h,54:u,55:d,58:p,60:g,61:f,62:m,63:y,73:v,74:x,76:b,80:w,81:k,84:T,99:_,101:E,102:S}),{5:87,10:5,16:39,18:21,19:40,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:e,35:n,37:r,38:22,42:i,43:23,46:a,47:o,49:l,50:c,52:h,54:u,55:d,58:p,60:g,61:f,62:m,63:y,73:v,74:x,76:b,80:w,81:k,84:T,99:_,101:E,102:S},t(A,[2,19]),t(A,[2,30]),t(A,[2,31]),{13:[1,89],16:39,18:88,19:40,58:p,84:T,99:_,101:E,102:S},{51:90,64:56,65:57,66:L,67:M,68:N,69:I,70:R,71:D,72:O},t(A,[2,49]),{65:91,71:D,72:O},t(W,[2,68],{64:92,66:L,67:M,68:N,69:I,70:R}),t(z,[2,69]),t(z,[2,70]),t(z,[2,71]),t(z,[2,72]),t(z,[2,73]),t(Z,[2,74]),t(Z,[2,75]),{8:[1,94],24:95,40:93,43:23,46:a},{16:96,58:p,84:T,99:_,101:E},{45:97,49:Y},{48:[1,99]},{13:[1,100]},{13:[1,101]},{77:[1,102],79:[1,103]},{22:U,57:104,58:G,80:V,82:105,83:106,84:q,85:j,86:H,87:X,88:K,89:Q},{58:[1,116]},{13:$,53:117},t(A,[2,57]),t(A,[2,123]),{22:U,57:118,58:G,59:[1,119],80:V,82:105,83:106,84:q,85:j,86:H,87:X,88:K,89:Q},t(J,[2,59]),{16:39,18:120,19:40,58:p,84:T,99:_,101:E,102:S},t(B,[2,15]),t(B,[2,16]),t(B,[2,17]),{39:[2,35]},{15:122,16:84,17:[1,121],39:[2,9],58:p,84:T,99:_,101:E},t(tt,[2,43],{11:123,12:[1,124]}),t(C,[2,7]),{9:[1,125]},t(et,[2,52]),{16:39,18:126,19:40,58:p,84:T,99:_,101:E,102:S},{13:[1,128],16:39,18:127,19:40,58:p,84:T,99:_,101:E,102:S},t(W,[2,67],{64:129,66:L,67:M,68:N,69:I,70:R}),t(W,[2,66]),{41:[1,130]},{24:95,40:131,43:23,46:a},{8:[1,132],41:[2,36]},t(P,[2,40],{39:[1,133]}),{41:[1,134]},{41:[2,46],45:135,49:Y},{16:39,18:136,19:40,58:p,84:T,99:_,101:E,102:S},t(A,[2,76],{13:[1,137]}),t(A,[2,78],{13:[1,139],75:[1,138]}),t(A,[2,82],{13:[1,140],78:[1,141]}),{13:[1,142]},t(A,[2,90],{59:nt}),t(rt,[2,92],{83:144,22:U,58:G,80:V,84:q,85:j,86:H,87:X,88:K,89:Q}),t(it,[2,94]),t(it,[2,96]),t(it,[2,97]),t(it,[2,98]),t(it,[2,99]),t(it,[2,100]),t(it,[2,101]),t(it,[2,102]),t(it,[2,103]),t(it,[2,104]),t(A,[2,91]),t(A,[2,56]),t(A,[2,58],{59:nt}),{58:[1,145]},t(B,[2,13]),{15:146,16:84,58:p,84:T,99:_,101:E},{39:[2,11]},t(tt,[2,44]),{13:[1,147]},{1:[2,4]},t(et,[2,54]),t(et,[2,53]),{16:39,18:148,19:40,58:p,84:T,99:_,101:E,102:S},t(W,[2,65]),t(A,[2,33]),{41:[1,149]},{24:95,40:150,41:[2,37],43:23,46:a},{45:151,49:Y},t(P,[2,41]),{41:[2,47]},t(A,[2,45]),t(A,[2,77]),t(A,[2,79]),t(A,[2,80],{75:[1,152]}),t(A,[2,83]),t(A,[2,84],{13:[1,153]}),t(A,[2,86],{13:[1,155],75:[1,154]}),{22:U,58:G,80:V,82:156,83:106,84:q,85:j,86:H,87:X,88:K,89:Q},t(it,[2,95]),t(J,[2,60]),{39:[2,10]},{14:[1,157]},t(et,[2,55]),t(A,[2,34]),{41:[2,38]},{41:[1,158]},t(A,[2,81]),t(A,[2,85]),t(A,[2,87]),t(A,[2,88],{75:[1,159]}),t(rt,[2,93],{83:144,22:U,58:G,80:V,84:q,85:j,86:H,87:X,88:K,89:Q}),t(tt,[2,8]),t(P,[2,42]),t(A,[2,89])],defaultActions:{2:[2,1],3:[2,2],4:[2,3],83:[2,35],122:[2,11],125:[2,4],135:[2,47],146:[2,10],150:[2,38]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},st=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:return 60;case 1:return 61;case 2:return 62;case 3:return 63;case 4:case 5:case 14:case 31:case 36:case 40:case 47:break;case 6:return this.begin("acc_title"),33;case 7:return this.popState(),"acc_title_value";case 8:return this.begin("acc_descr"),35;case 9:return this.popState(),"acc_descr_value";case 10:this.begin("acc_descr_multiline");break;case 11:case 19:case 22:case 24:case 58:case 61:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:case 35:return 8;case 15:case 16:return 7;case 17:case 37:case 45:return"EDGE_STATE";case 18:this.begin("callback_name");break;case 20:this.popState(),this.begin("callback_args");break;case 21:return 77;case 23:return 78;case 25:return"STR";case 26:this.begin("string");break;case 27:return 80;case 28:return 55;case 29:return this.begin("namespace"),42;case 30:case 39:return this.popState(),8;case 32:return this.begin("namespace-body"),39;case 33:case 43:return this.popState(),41;case 34:case 44:return"EOF_IN_STRUCT";case 38:return this.begin("class"),46;case 41:return this.popState(),this.popState(),41;case 42:return this.begin("class-body"),39;case 46:return"OPEN_IN_STRUCT";case 48:return"MEMBER";case 49:return 81;case 50:return 73;case 51:return 74;case 52:return 76;case 53:return 52;case 54:return 54;case 55:return 47;case 56:return 48;case 57:return 79;case 59:return"GENERICTYPE";case 60:this.begin("generic");break;case 62:return"BQUOTE_STR";case 63:this.begin("bqstring");break;case 64:case 65:case 66:case 67:return 75;case 68:case 69:return 67;case 70:case 71:return 69;case 72:return 68;case 73:return 66;case 74:return 70;case 75:return 71;case 76:return 72;case 77:return 22;case 78:return 44;case 79:return 99;case 80:return 17;case 81:return"PLUS";case 82:return 85;case 83:return 59;case 84:case 85:return 88;case 86:return 89;case 87:case 88:return"EQUALS";case 89:return 58;case 90:return 12;case 91:return 14;case 92:return"PUNCTUATION";case 93:return 84;case 94:return 101;case 95:case 96:return 87;case 97:return 9}}),"anonymous"),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:classDiagram-v2\b)/,/^(?:classDiagram\b)/,/^(?:\[\*\])/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:["])/,/^(?:[^"]*)/,/^(?:["])/,/^(?:style\b)/,/^(?:classDef\b)/,/^(?:namespace\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[{])/,/^(?:[}])/,/^(?:$)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:\[\*\])/,/^(?:class\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[}])/,/^(?:[{])/,/^(?:[}])/,/^(?:$)/,/^(?:\[\*\])/,/^(?:[{])/,/^(?:[\n])/,/^(?:[^{}\n]*)/,/^(?:cssClass\b)/,/^(?:callback\b)/,/^(?:link\b)/,/^(?:click\b)/,/^(?:note for\b)/,/^(?:note\b)/,/^(?:<<)/,/^(?:>>)/,/^(?:href\b)/,/^(?:[~])/,/^(?:[^~]*)/,/^(?:~)/,/^(?:[`])/,/^(?:[^`]+)/,/^(?:[`])/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:\s*\(\))/,/^(?:--)/,/^(?:\.\.)/,/^(?::{1}[^:\n;]+)/,/^(?::{3})/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?::)/,/^(?:,)/,/^(?:#)/,/^(?:#)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:\w+)/,/^(?:\[)/,/^(?:\])/,/^(?:[!"#$%&'*+,-.`?\\/])/,/^(?:[0-9]+)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\s)/,/^(?:\s)/,/^(?:$)/],conditions:{"namespace-body":{rules:[26,33,34,35,36,37,38,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},namespace:{rules:[26,29,30,31,32,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},"class-body":{rules:[26,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},class:{rules:[26,39,40,41,42,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},acc_descr_multiline:{rules:[11,12,26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},acc_descr:{rules:[9,26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},acc_title:{rules:[7,26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},callback_args:{rules:[22,23,26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},callback_name:{rules:[19,20,21,26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},href:{rules:[26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},struct:{rules:[26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},generic:{rules:[26,49,50,51,52,53,54,55,56,57,58,59,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},bqstring:{rules:[26,49,50,51,52,53,54,55,56,57,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},string:{rules:[24,25,26,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,86,87,88,89,90,91,92,93,94,95,97],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,26,27,28,29,38,49,50,51,52,53,54,55,56,57,60,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97],inclusive:!0}}}}();function ot(){this.yy={}}return at.lexer=st,(0,s.eW)(ot,"Parser"),ot.prototype=at,at.Parser=ot,new ot}();l.parser=l;var c=l,h=["#","+","~","-",""],u=class{static{(0,s.eW)(this,"ClassMember")}constructor(t,e){this.memberType=e,this.visibility="",this.classifier="",this.text="";const n=(0,s.oO)(t,(0,s.nV)());this.parseMember(n)}getDisplayDetails(){let t=this.visibility+(0,s.UO)(this.id);return"method"===this.memberType&&(t+=`(${(0,s.UO)(this.parameters.trim())})`,this.returnType&&(t+=" : "+(0,s.UO)(this.returnType))),t=t.trim(),{displayText:t,cssStyle:this.parseClassifier()}}parseMember(t){let e="";if("method"===this.memberType){const n=/([#+~-])?(.+)\((.*)\)([\s$*])?(.*)([$*])?/.exec(t);if(n){const t=n[1]?n[1].trim():"";if(h.includes(t)&&(this.visibility=t),this.id=n[2],this.parameters=n[3]?n[3].trim():"",e=n[4]?n[4].trim():"",this.returnType=n[5]?n[5].trim():"",""===e){const t=this.returnType.substring(this.returnType.length-1);/[$*]/.exec(t)&&(e=t,this.returnType=this.returnType.substring(0,this.returnType.length-1))}}}else{const n=t.length,r=t.substring(0,1),i=t.substring(n-1);h.includes(r)&&(this.visibility=r),/[$*]/.exec(i)&&(e=i),this.id=t.substring(""===this.visibility?0:1,""===e?n:n-1)}this.classifier=e,this.id=this.id.startsWith(" ")?" "+this.id.trim():this.id.trim();const n=`${this.visibility?"\\"+this.visibility:""}${(0,s.UO)(this.id)}${"method"===this.memberType?`(${(0,s.UO)(this.parameters)})${this.returnType?" : "+(0,s.UO)(this.returnType):""}`:""}`;this.text=n.replaceAll("<","<").replaceAll(">",">"),this.text.startsWith("\\<")&&(this.text=this.text.replace("\\<","~"))}parseClassifier(){switch(this.classifier){case"*":return"font-style:italic;";case"$":return"text-decoration:underline;";default:return""}}},d="classId-",p=0,g=(0,s.eW)((t=>s.SY.sanitizeText(t,(0,s.nV)())),"sanitizeText"),f=class{constructor(){this.relations=[],this.classes=new Map,this.styleClasses=new Map,this.notes=[],this.interfaces=[],this.namespaces=new Map,this.namespaceCounter=0,this.functions=[],this.lineType={LINE:0,DOTTED_LINE:1},this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3,LOLLIPOP:4},this.setupToolTips=(0,s.eW)((t=>{let e=(0,o.Ys)(".mermaidTooltip");null===(e._groups||e)[0][0]&&(e=(0,o.Ys)("body").append("div").attr("class","mermaidTooltip").style("opacity",0)),(0,o.Ys)(t).select("svg").selectAll("g.node").on("mouseover",(t=>{const n=(0,o.Ys)(t.currentTarget);if(null===n.attr("title"))return;const r=this.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.text(n.attr("title")).style("left",window.scrollX+r.left+(r.right-r.left)/2+"px").style("top",window.scrollY+r.top-14+document.body.scrollTop+"px"),e.html(e.html().replace(/<br\/>/g,"
")),n.classed("hover",!0)})).on("mouseout",(t=>{e.transition().duration(500).style("opacity",0),(0,o.Ys)(t.currentTarget).classed("hover",!1)}))}),"setupToolTips"),this.direction="TB",this.setAccTitle=s.GN,this.getAccTitle=s.eu,this.setAccDescription=s.U$,this.getAccDescription=s.Mx,this.setDiagramTitle=s.g2,this.getDiagramTitle=s.Kr,this.getConfig=(0,s.eW)((()=>(0,s.nV)().class),"getConfig"),this.functions.push(this.setupToolTips.bind(this)),this.clear(),this.addRelation=this.addRelation.bind(this),this.addClassesToNamespace=this.addClassesToNamespace.bind(this),this.addNamespace=this.addNamespace.bind(this),this.setCssClass=this.setCssClass.bind(this),this.addMembers=this.addMembers.bind(this),this.addClass=this.addClass.bind(this),this.setClassLabel=this.setClassLabel.bind(this),this.addAnnotation=this.addAnnotation.bind(this),this.addMember=this.addMember.bind(this),this.cleanupLabel=this.cleanupLabel.bind(this),this.addNote=this.addNote.bind(this),this.defineClass=this.defineClass.bind(this),this.setDirection=this.setDirection.bind(this),this.setLink=this.setLink.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.clear=this.clear.bind(this),this.setTooltip=this.setTooltip.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setCssStyle=this.setCssStyle.bind(this)}static{(0,s.eW)(this,"ClassDB")}splitClassNameAndType(t){const e=s.SY.sanitizeText(t,(0,s.nV)());let n="",r=e;if(e.indexOf("~")>0){const t=e.split("~");r=g(t[0]),n=g(t[1])}return{className:r,type:n}}setClassLabel(t,e){const n=s.SY.sanitizeText(t,(0,s.nV)());e&&(e=g(e));const{className:r}=this.splitClassNameAndType(n);this.classes.get(r).label=e,this.classes.get(r).text=`${e}${this.classes.get(r).type?`<${this.classes.get(r).type}>`:""}`}addClass(t){const e=s.SY.sanitizeText(t,(0,s.nV)()),{className:n,type:r}=this.splitClassNameAndType(e);if(this.classes.has(n))return;const i=s.SY.sanitizeText(n,(0,s.nV)());this.classes.set(i,{id:i,type:r,label:i,text:`${i}${r?`<${r}>`:""}`,shape:"classBox",cssClasses:"default",methods:[],members:[],annotations:[],styles:[],domId:d+i+"-"+p}),p++}addInterface(t,e){const n={id:`interface${this.interfaces.length}`,label:t,classId:e};this.interfaces.push(n)}lookUpDomId(t){const e=s.SY.sanitizeText(t,(0,s.nV)());if(this.classes.has(e))return this.classes.get(e).domId;throw new Error("Class not found: "+e)}clear(){this.relations=[],this.classes=new Map,this.notes=[],this.interfaces=[],this.functions=[],this.functions.push(this.setupToolTips.bind(this)),this.namespaces=new Map,this.namespaceCounter=0,this.direction="TB",(0,s.ZH)()}getClass(t){return this.classes.get(t)}getClasses(){return this.classes}getRelations(){return this.relations}getNotes(){return this.notes}addRelation(t){s.cM.debug("Adding relation: "+JSON.stringify(t));const e=[this.relationType.LOLLIPOP,this.relationType.AGGREGATION,this.relationType.COMPOSITION,this.relationType.DEPENDENCY,this.relationType.EXTENSION];t.relation.type1!==this.relationType.LOLLIPOP||e.includes(t.relation.type2)?t.relation.type2!==this.relationType.LOLLIPOP||e.includes(t.relation.type1)?(this.addClass(t.id1),this.addClass(t.id2)):(this.addClass(t.id1),this.addInterface(t.id2,t.id1),t.id2="interface"+(this.interfaces.length-1)):(this.addClass(t.id2),this.addInterface(t.id1,t.id2),t.id1="interface"+(this.interfaces.length-1)),t.id1=this.splitClassNameAndType(t.id1).className,t.id2=this.splitClassNameAndType(t.id2).className,t.relationTitle1=s.SY.sanitizeText(t.relationTitle1.trim(),(0,s.nV)()),t.relationTitle2=s.SY.sanitizeText(t.relationTitle2.trim(),(0,s.nV)()),this.relations.push(t)}addAnnotation(t,e){const n=this.splitClassNameAndType(t).className;this.classes.get(n).annotations.push(e)}addMember(t,e){this.addClass(t);const n=this.splitClassNameAndType(t).className,r=this.classes.get(n);if("string"==typeof e){const t=e.trim();t.startsWith("<<")&&t.endsWith(">>")?r.annotations.push(g(t.substring(2,t.length-2))):t.indexOf(")")>0?r.methods.push(new u(t,"method")):t&&r.members.push(new u(t,"attribute"))}}addMembers(t,e){Array.isArray(e)&&(e.reverse(),e.forEach((e=>this.addMember(t,e))))}addNote(t,e){const n={id:`note${this.notes.length}`,class:e,text:t};this.notes.push(n)}cleanupLabel(t){return t.startsWith(":")&&(t=t.substring(1)),g(t.trim())}setCssClass(t,e){t.split(",").forEach((t=>{let n=t;/\d/.exec(t[0])&&(n=d+n);const r=this.classes.get(n);r&&(r.cssClasses+=" "+e)}))}defineClass(t,e){for(const n of t){let t=this.styleClasses.get(n);void 0===t&&(t={id:n,styles:[],textStyles:[]},this.styleClasses.set(n,t)),e&&e.forEach((e=>{if(/color/.exec(e)){const n=e.replace("fill","bgFill");t.textStyles.push(n)}t.styles.push(e)})),this.classes.forEach((t=>{t.cssClasses.includes(n)&&t.styles.push(...e.flatMap((t=>t.split(","))))}))}}setTooltip(t,e){t.split(",").forEach((t=>{void 0!==e&&(this.classes.get(t).tooltip=g(e))}))}getTooltip(t,e){return e&&this.namespaces.has(e)?this.namespaces.get(e).classes.get(t).tooltip:this.classes.get(t).tooltip}setLink(t,e,n){const r=(0,s.nV)();t.split(",").forEach((t=>{let i=t;/\d/.exec(t[0])&&(i=d+i);const s=this.classes.get(i);s&&(s.link=a.w8.formatUrl(e,r),"sandbox"===r.securityLevel?s.linkTarget="_top":s.linkTarget="string"==typeof n?g(n):"_blank")})),this.setCssClass(t,"clickable")}setClickEvent(t,e,n){t.split(",").forEach((t=>{this.setClickFunc(t,e,n),this.classes.get(t).haveCallback=!0})),this.setCssClass(t,"clickable")}setClickFunc(t,e,n){const r=s.SY.sanitizeText(t,(0,s.nV)());if("loose"!==(0,s.nV)().securityLevel)return;if(void 0===e)return;const i=r;if(this.classes.has(i)){const t=this.lookUpDomId(i);let r=[];if("string"==typeof n){r=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let t=0;t{const n=document.querySelector(`[id="${t}"]`);null!==n&&n.addEventListener("click",(()=>{a.w8.runFunc(e,...r)}),!1)}))}}bindFunctions(t){this.functions.forEach((e=>{e(t)}))}getDirection(){return this.direction}setDirection(t){this.direction=t}addNamespace(t){this.namespaces.has(t)||(this.namespaces.set(t,{id:t,classes:new Map,children:{},domId:d+t+"-"+this.namespaceCounter}),this.namespaceCounter++)}getNamespace(t){return this.namespaces.get(t)}getNamespaces(){return this.namespaces}addClassesToNamespace(t,e){if(this.namespaces.has(t))for(const n of e){const{className:e}=this.splitClassNameAndType(n);this.classes.get(e).parent=t,this.namespaces.get(t).classes.set(e,this.classes.get(e))}}setCssStyle(t,e){const n=this.classes.get(t);if(e&&n)for(const t of e)t.includes(",")?n.styles.push(...t.split(",")):n.styles.push(t)}getArrowMarker(t){let e;switch(t){case 0:e="aggregation";break;case 1:e="extension";break;case 2:e="composition";break;case 3:e="dependency";break;case 4:e="lollipop";break;default:e="none"}return e}getData(){const t=[],e=[],n=(0,s.nV)();for(const e of this.namespaces.keys()){const r=this.namespaces.get(e);if(r){const e={id:r.id,label:r.id,isGroup:!0,padding:n.class.padding??16,shape:"rect",cssStyles:["fill: none","stroke: black"],look:n.look};t.push(e)}}for(const e of this.classes.keys()){const r=this.classes.get(e);if(r){const e=r;e.parentId=r.parent,e.look=n.look,t.push(e)}}let r=0;for(const i of this.notes){r++;const a={id:i.id,label:i.text,isGroup:!1,shape:"note",padding:n.class.padding??6,cssStyles:["text-align: left","white-space: nowrap",`fill: ${n.themeVariables.noteBkgColor}`,`stroke: ${n.themeVariables.noteBorderColor}`],look:n.look};t.push(a);const s=this.classes.get(i.class)?.id??"";if(s){const t={id:`edgeNote${r}`,start:i.id,end:s,type:"normal",thickness:"normal",classes:"relation",arrowTypeStart:"none",arrowTypeEnd:"none",arrowheadStyle:"",labelStyle:[""],style:["fill: none"],pattern:"dotted",look:n.look};e.push(t)}}for(const e of this.interfaces){const r={id:e.id,label:e.label,isGroup:!1,shape:"rect",cssStyles:["opacity: 0;"],look:n.look};t.push(r)}r=0;for(const t of this.relations){r++;const i={id:(0,a.Ln)(t.id1,t.id2,{prefix:"id",counter:r}),start:t.id1,end:t.id2,type:"normal",label:t.title,labelpos:"c",thickness:"normal",classes:"relation",arrowTypeStart:this.getArrowMarker(t.relation.type1),arrowTypeEnd:this.getArrowMarker(t.relation.type2),startLabelRight:"none"===t.relationTitle1?"":t.relationTitle1,endLabelLeft:"none"===t.relationTitle2?"":t.relationTitle2,arrowheadStyle:"",labelStyle:["display: inline-block"],style:t.style||"",pattern:1==t.relation.lineType?"dashed":"solid",look:n.look};e.push(i)}return{nodes:t,edges:e,other:{},config:n,direction:this.getDirection()}}},m=(0,s.eW)((t=>`g.classGroup text {\n fill: ${t.nodeBorder||t.classText};\n stroke: none;\n font-family: ${t.fontFamily};\n font-size: 10px;\n\n .title {\n font-weight: bolder;\n }\n\n}\n\n.nodeLabel, .edgeLabel {\n color: ${t.classText};\n}\n.edgeLabel .label rect {\n fill: ${t.mainBkg};\n}\n.label text {\n fill: ${t.classText};\n}\n\n.labelBkg {\n background: ${t.mainBkg};\n}\n.edgeLabel .label span {\n background: ${t.mainBkg};\n}\n\n.classTitle {\n font-weight: bolder;\n}\n.node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n stroke-width: 1px;\n }\n\n\n.divider {\n stroke: ${t.nodeBorder};\n stroke-width: 1;\n}\n\ng.clickable {\n cursor: pointer;\n}\n\ng.classGroup rect {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n}\n\ng.classGroup line {\n stroke: ${t.nodeBorder};\n stroke-width: 1;\n}\n\n.classLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ${t.mainBkg};\n opacity: 0.5;\n}\n\n.classLabel .label {\n fill: ${t.nodeBorder};\n font-size: 10px;\n}\n\n.relation {\n stroke: ${t.lineColor};\n stroke-width: 1;\n fill: none;\n}\n\n.dashed-line{\n stroke-dasharray: 3;\n}\n\n.dotted-line{\n stroke-dasharray: 1 2;\n}\n\n#compositionStart, .composition {\n fill: ${t.lineColor} !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#compositionEnd, .composition {\n fill: ${t.lineColor} !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ${t.lineColor} !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#dependencyStart, .dependency {\n fill: ${t.lineColor} !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#extensionStart, .extension {\n fill: transparent !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#extensionEnd, .extension {\n fill: transparent !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#aggregationStart, .aggregation {\n fill: transparent !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#aggregationEnd, .aggregation {\n fill: transparent !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#lollipopStart, .lollipop {\n fill: ${t.mainBkg} !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n#lollipopEnd, .lollipop {\n fill: ${t.mainBkg} !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n}\n\n.edgeTerminals {\n font-size: 11px;\n line-height: initial;\n}\n\n.classTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${t.textColor};\n}\n`),"getStyles"),y=(0,s.eW)(((t,e="TB")=>{if(!t.doc)return e;let n=e;for(const e of t.doc)"dir"===e.stmt&&(n=e.value);return n}),"getDir"),v={getClasses:(0,s.eW)((function(t,e){return e.db.getClasses()}),"getClasses"),draw:(0,s.eW)((async function(t,e,n,o){s.cM.info("REF0:"),s.cM.info("Drawing class diagram (v3)",e);const{securityLevel:l,state:c,layout:h}=(0,s.nV)(),u=o.db.getData(),d=(0,r.q)(e,l);u.type=o.type,u.layoutAlgorithm=(0,i._b)(h),u.nodeSpacing=c?.nodeSpacing||50,u.rankSpacing=c?.rankSpacing||50,u.markers=["aggregation","extension","composition","dependency","lollipop"],u.diagramId=e,await(0,i.sY)(u,d),a.w8.insertTitle(d,"classDiagramTitleText",c?.titleTopMargin??25,o.db.getDiagramTitle()),(0,r.j)(d,8,"classDiagram",c?.useMaxWidth??!0)}),"draw"),getDir:y}},9836:(t,e,n)=>{"use strict";n.d(e,{Ee:()=>tt,J8:()=>l,_$:()=>D,oI:()=>J});var r=n(907),i=n(8337),a=n(7946),s=n(4082),o=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,2],n=[1,3],r=[1,4],i=[2,4],a=[1,9],o=[1,11],l=[1,16],c=[1,17],h=[1,18],u=[1,19],d=[1,32],p=[1,20],g=[1,21],f=[1,22],m=[1,23],y=[1,24],v=[1,26],x=[1,27],b=[1,28],w=[1,29],k=[1,30],T=[1,31],_=[1,34],E=[1,35],S=[1,36],C=[1,37],A=[1,33],L=[1,4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,42,45,48,49,50,51,54],M=[1,4,5,14,15,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,42,45,48,49,50,51,54],N=[4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,42,45,48,49,50,51,54],I={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,styleStatement:11,cssClassStatement:12,idStatement:13,DESCR:14,"--\x3e":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,classDef:38,CLASSDEF_ID:39,CLASSDEF_STYLEOPTS:40,DEFAULT:41,style:42,STYLE_IDS:43,STYLEDEF_STYLEOPTS:44,class:45,CLASSENTITY_IDS:46,STYLECLASS:47,direction_tb:48,direction_bt:49,direction_rl:50,direction_lr:51,eol:52,";":53,EDGE_STATE:54,STYLE_SEPARATOR:55,left_of:56,right_of:57,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",6:"SD",14:"DESCR",15:"--\x3e",16:"HIDE_EMPTY",17:"scale",18:"WIDTH",19:"COMPOSIT_STATE",20:"STRUCT_START",21:"STRUCT_STOP",22:"STATE_DESCR",23:"AS",24:"ID",25:"FORK",26:"JOIN",27:"CHOICE",28:"CONCURRENT",29:"note",31:"NOTE_TEXT",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",38:"classDef",39:"CLASSDEF_ID",40:"CLASSDEF_STYLEOPTS",41:"DEFAULT",42:"style",43:"STYLE_IDS",44:"STYLEDEF_STYLEOPTS",45:"class",46:"CLASSENTITY_IDS",47:"STYLECLASS",48:"direction_tb",49:"direction_bt",50:"direction_rl",51:"direction_lr",53:";",54:"EDGE_STATE",55:"STYLE_SEPARATOR",56:"left_of",57:"right_of"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[52,1],[52,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 3:return r.setRootDoc(a[o]),a[o];case 4:this.$=[];break;case 5:"nl"!=a[o]&&(a[o-1].push(a[o]),this.$=a[o-1]);break;case 6:case 7:case 12:this.$=a[o];break;case 8:this.$="nl";break;case 13:const t=a[o-1];t.description=r.trimColon(a[o]),this.$=t;break;case 14:this.$={stmt:"relation",state1:a[o-2],state2:a[o]};break;case 15:const e=r.trimColon(a[o]);this.$={stmt:"relation",state1:a[o-3],state2:a[o-1],description:e};break;case 19:this.$={stmt:"state",id:a[o-3],type:"default",description:"",doc:a[o-1]};break;case 20:var l=a[o],c=a[o-2].trim();if(a[o].match(":")){var h=a[o].split(":");l=h[0],c=[c,h[1]]}this.$={stmt:"state",id:l,type:"default",description:c};break;case 21:this.$={stmt:"state",id:a[o-3],type:"default",description:a[o-5],doc:a[o-1]};break;case 22:this.$={stmt:"state",id:a[o],type:"fork"};break;case 23:this.$={stmt:"state",id:a[o],type:"join"};break;case 24:this.$={stmt:"state",id:a[o],type:"choice"};break;case 25:this.$={stmt:"state",id:r.getDividerId(),type:"divider"};break;case 26:this.$={stmt:"state",id:a[o-1].trim(),note:{position:a[o-2].trim(),text:a[o].trim()}};break;case 29:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 30:case 31:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 32:case 33:this.$={stmt:"classDef",id:a[o-1].trim(),classes:a[o].trim()};break;case 34:this.$={stmt:"style",id:a[o-1].trim(),styleClass:a[o].trim()};break;case 35:this.$={stmt:"applyClass",id:a[o-1].trim(),styleClass:a[o].trim()};break;case 36:r.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 37:r.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 38:r.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 39:r.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 42:case 43:this.$={stmt:"state",id:a[o].trim(),type:"default",description:""};break;case 44:case 45:this.$={stmt:"state",id:a[o-2].trim(),classes:[a[o].trim()],type:"default",description:""}}}),"anonymous"),table:[{3:1,4:e,5:n,6:r},{1:[3]},{3:5,4:e,5:n,6:r},{3:6,4:e,5:n,6:r},t([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,42,45,48,49,50,51,54],i,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:a,5:o,8:8,9:10,10:12,11:13,12:14,13:15,16:l,17:c,19:h,22:u,24:d,25:p,26:g,27:f,28:m,29:y,32:25,33:v,35:x,37:b,38:w,42:k,45:T,48:_,49:E,50:S,51:C,54:A},t(L,[2,5]),{9:38,10:12,11:13,12:14,13:15,16:l,17:c,19:h,22:u,24:d,25:p,26:g,27:f,28:m,29:y,32:25,33:v,35:x,37:b,38:w,42:k,45:T,48:_,49:E,50:S,51:C,54:A},t(L,[2,7]),t(L,[2,8]),t(L,[2,9]),t(L,[2,10]),t(L,[2,11]),t(L,[2,12],{14:[1,39],15:[1,40]}),t(L,[2,16]),{18:[1,41]},t(L,[2,18],{20:[1,42]}),{23:[1,43]},t(L,[2,22]),t(L,[2,23]),t(L,[2,24]),t(L,[2,25]),{30:44,31:[1,45],56:[1,46],57:[1,47]},t(L,[2,28]),{34:[1,48]},{36:[1,49]},t(L,[2,31]),{39:[1,50],41:[1,51]},{43:[1,52]},{46:[1,53]},t(M,[2,42],{55:[1,54]}),t(M,[2,43],{55:[1,55]}),t(L,[2,36]),t(L,[2,37]),t(L,[2,38]),t(L,[2,39]),t(L,[2,6]),t(L,[2,13]),{13:56,24:d,54:A},t(L,[2,17]),t(N,i,{7:57}),{24:[1,58]},{24:[1,59]},{23:[1,60]},{24:[2,46]},{24:[2,47]},t(L,[2,29]),t(L,[2,30]),{40:[1,61]},{40:[1,62]},{44:[1,63]},{47:[1,64]},{24:[1,65]},{24:[1,66]},t(L,[2,14],{14:[1,67]}),{4:a,5:o,8:8,9:10,10:12,11:13,12:14,13:15,16:l,17:c,19:h,21:[1,68],22:u,24:d,25:p,26:g,27:f,28:m,29:y,32:25,33:v,35:x,37:b,38:w,42:k,45:T,48:_,49:E,50:S,51:C,54:A},t(L,[2,20],{20:[1,69]}),{31:[1,70]},{24:[1,71]},t(L,[2,32]),t(L,[2,33]),t(L,[2,34]),t(L,[2,35]),t(M,[2,44]),t(M,[2,45]),t(L,[2,15]),t(L,[2,19]),t(N,i,{7:72}),t(L,[2,26]),t(L,[2,27]),{4:a,5:o,8:8,9:10,10:12,11:13,12:14,13:15,16:l,17:c,19:h,21:[1,73],22:u,24:d,25:p,26:g,27:f,28:m,29:y,32:25,33:v,35:x,37:b,38:w,42:k,45:T,48:_,49:E,50:S,51:C,54:A},t(L,[2,21])],defaultActions:{5:[2,1],6:[2,2],46:[2,46],47:[2,47]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},R=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:return 41;case 1:case 42:return 48;case 2:case 43:return 49;case 3:case 44:return 50;case 4:case 45:return 51;case 5:case 6:case 8:case 9:case 10:case 11:case 54:case 56:case 62:break;case 7:case 77:return 5;case 12:case 32:return this.pushState("SCALE"),17;case 13:case 33:return 18;case 14:case 20:case 34:case 49:case 52:this.popState();break;case 15:return this.begin("acc_title"),33;case 16:return this.popState(),"acc_title_value";case 17:return this.begin("acc_descr"),35;case 18:return this.popState(),"acc_descr_value";case 19:this.begin("acc_descr_multiline");break;case 21:return"acc_descr_multiline_value";case 22:return this.pushState("CLASSDEF"),38;case 23:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 24:return this.popState(),this.pushState("CLASSDEFID"),39;case 25:return this.popState(),40;case 26:return this.pushState("CLASS"),45;case 27:return this.popState(),this.pushState("CLASS_STYLE"),46;case 28:return this.popState(),47;case 29:return this.pushState("STYLE"),42;case 30:return this.popState(),this.pushState("STYLEDEF_STYLES"),43;case 31:return this.popState(),44;case 35:this.pushState("STATE");break;case 36:case 39:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),25;case 37:case 40:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),26;case 38:case 41:return this.popState(),e.yytext=e.yytext.slice(0,-10).trim(),27;case 46:this.pushState("STATE_STRING");break;case 47:return this.pushState("STATE_ID"),"AS";case 48:case 64:return this.popState(),"ID";case 50:return"STATE_DESCR";case 51:return 19;case 53:return this.popState(),this.pushState("struct"),20;case 55:return this.popState(),21;case 57:return this.begin("NOTE"),29;case 58:return this.popState(),this.pushState("NOTE_ID"),56;case 59:return this.popState(),this.pushState("NOTE_ID"),57;case 60:this.popState(),this.pushState("FLOATING_NOTE");break;case 61:return this.popState(),this.pushState("FLOATING_NOTE_ID"),"AS";case 63:return"NOTE_TEXT";case 65:return this.popState(),this.pushState("NOTE_TEXT"),24;case 66:return this.popState(),e.yytext=e.yytext.substr(2).trim(),31;case 67:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),31;case 68:case 69:return 6;case 70:return 16;case 71:return 54;case 72:return 24;case 73:return e.yytext=e.yytext.trim(),14;case 74:return 15;case 75:return 28;case 76:return 55;case 78:return"INVALID"}}),"anonymous"),rules:[/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<>)/i,/^(?:.*<>)/i,/^(?:.*<>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[9,10],inclusive:!1},struct:{rules:[9,10,22,26,29,35,42,43,44,45,54,55,56,57,71,72,73,74,75],inclusive:!1},FLOATING_NOTE_ID:{rules:[64],inclusive:!1},FLOATING_NOTE:{rules:[61,62,63],inclusive:!1},NOTE_TEXT:{rules:[66,67],inclusive:!1},NOTE_ID:{rules:[65],inclusive:!1},NOTE:{rules:[58,59,60],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[31],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[30],inclusive:!1},CLASS_STYLE:{rules:[28],inclusive:!1},CLASS:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[25],inclusive:!1},CLASSDEF:{rules:[23,24],inclusive:!1},acc_descr_multiline:{rules:[20,21],inclusive:!1},acc_descr:{rules:[18],inclusive:!1},acc_title:{rules:[16],inclusive:!1},SCALE:{rules:[13,14,33,34],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[48],inclusive:!1},STATE_STRING:{rules:[49,50],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[9,10,36,37,38,39,40,41,46,47,51,52,53],inclusive:!1},ID:{rules:[9,10],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,10,11,12,15,17,19,22,26,29,32,35,53,57,68,69,70,71,72,73,74,76,77,78],inclusive:!0}}}}();function D(){this.yy={}}return I.lexer=R,(0,s.eW)(D,"Parser"),D.prototype=I,I.Parser=D,new D}();o.parser=o;var l=o,c="state",h="relation",u="default",d="divider",p="fill:none",g="fill: #333",f="text",m="normal",y="rect",v="rectWithTitle",x="divider",b="roundedWithTitle",w="statediagram",k=`${w}-state`,T="transition",_=`${T} note-edge`,E=`${w}-note`,S=`${w}-cluster`,C=`${w}-cluster-alt`,A="parent",L="note",M="----",N=`${M}${L}`,I=`${M}${A}`,R=(0,s.eW)(((t,e="TB")=>{if(!t.doc)return e;let n=e;for(const e of t.doc)"dir"===e.stmt&&(n=e.value);return n}),"getDir"),D={getClasses:(0,s.eW)((function(t,e){return e.db.getClasses()}),"getClasses"),draw:(0,s.eW)((async function(t,e,n,o){s.cM.info("REF0:"),s.cM.info("Drawing state diagram (v2)",e);const{securityLevel:l,state:c,layout:h}=(0,s.nV)();o.db.extract(o.db.getRootDocV2());const u=o.db.getData(),d=(0,r.q)(e,l);u.type=o.type,u.layoutAlgorithm=h,u.nodeSpacing=c?.nodeSpacing||50,u.rankSpacing=c?.rankSpacing||50,u.markers=["barb"],u.diagramId=e,await(0,i.sY)(u,d),a.w8.insertTitle(d,"statediagramTitleText",c?.titleTopMargin??25,o.db.getDiagramTitle()),(0,r.j)(d,8,w,c?.useMaxWidth??!0)}),"draw"),getDir:R},O=new Map,P=0;function $(t="",e=0,n="",r=M){return`state-${t}${null!==n&&n.length>0?`${r}${n}`:""}-${e}`}(0,s.eW)($,"stateDomId");var B=(0,s.eW)(((t,e,n,r,i,a,o,l)=>{s.cM.trace("items",e),e.forEach((e=>{switch(e.stmt){case c:case u:Y(t,e,n,r,i,a,o,l);break;case h:{Y(t,e.state1,n,r,i,a,o,l),Y(t,e.state2,n,r,i,a,o,l);const c={id:"edge"+P,start:e.state1.id,end:e.state2.id,arrowhead:"normal",arrowTypeEnd:"arrow_barb",style:p,labelStyle:"",label:s.SY.sanitizeText(e.description,(0,s.nV)()),arrowheadStyle:g,labelpos:"c",labelType:f,thickness:m,classes:T,look:o};i.push(c),P++}}}))}),"setupDoc"),F=(0,s.eW)(((t,e="TB")=>{let n=e;if(t.doc)for(const e of t.doc)"dir"===e.stmt&&(n=e.value);return n}),"getDir");function W(t,e,n){if(!e.id||""===e.id||""===e.id)return;e.cssClasses&&(Array.isArray(e.cssCompiledStyles)||(e.cssCompiledStyles=[]),e.cssClasses.split(" ").forEach((t=>{if(n.get(t)){const r=n.get(t);e.cssCompiledStyles=[...e.cssCompiledStyles,...r.styles]}})));const r=t.find((t=>t.id===e.id));r?Object.assign(r,e):t.push(e)}function z(t){return t?.classes?.join(" ")??""}function Z(t){return t?.styles??[]}(0,s.eW)(W,"insertOrUpdateNode"),(0,s.eW)(z,"getClassesFromDbInfo"),(0,s.eW)(Z,"getStylesFromDbInfo");var Y=(0,s.eW)(((t,e,n,r,i,a,o,l)=>{const c=e.id,h=n.get(c),w=z(h),T=Z(h);if(s.cM.info("dataFetcher parsedItem",e,h,T),"root"!==c){let n=y;!0===e.start?n="stateStart":!1===e.start&&(n="stateEnd"),e.type!==u&&(n=e.type),O.get(c)||O.set(c,{id:c,shape:n,description:s.SY.sanitizeText(c,(0,s.nV)()),cssClasses:`${w} ${k}`,cssStyles:T});const h=O.get(c);e.description&&(Array.isArray(h.description)?(h.shape=v,h.description.push(e.description)):h.description?.length>0?(h.shape=v,h.description===c?h.description=[e.description]:h.description=[h.description,e.description]):(h.shape=y,h.description=e.description),h.description=s.SY.sanitizeTextOrArray(h.description,(0,s.nV)())),1===h.description?.length&&h.shape===v&&("group"===h.type?h.shape=b:h.shape=y),!h.type&&e.doc&&(s.cM.info("Setting cluster for XCX",c,F(e)),h.type="group",h.isGroup=!0,h.dir=F(e),h.shape=e.type===d?x:b,h.cssClasses=`${h.cssClasses} ${S} ${a?C:""}`);const M={labelStyle:"",shape:h.shape,label:h.description,cssClasses:h.cssClasses,cssCompiledStyles:[],cssStyles:h.cssStyles,id:c,dir:h.dir,domId:$(c,P),type:h.type,isGroup:"group"===h.type,padding:8,rx:10,ry:10,look:o};if(M.shape===x&&(M.label=""),t&&"root"!==t.id&&(s.cM.trace("Setting node ",c," to be child of its parent ",t.id),M.parentId=t.id),M.centerLabel=!0,e.note){const t={labelStyle:"",shape:"note",label:e.note.text,cssClasses:E,cssStyles:[],cssCompilesStyles:[],id:c+N+"-"+P,domId:$(c,P,L),type:h.type,isGroup:"group"===h.type,padding:(0,s.nV)().flowchart.padding,look:o,position:e.note.position},n=c+I,a={labelStyle:"",shape:"noteGroup",label:e.note.text,cssClasses:h.cssClasses,cssStyles:[],id:c+I,domId:$(c,P,A),type:"group",isGroup:!0,padding:16,look:o,position:e.note.position};P++,a.id=n,t.parentId=n,W(r,a,l),W(r,t,l),W(r,M,l);let u=c,d=t.id;"left of"===e.note.position&&(u=t.id,d=c),i.push({id:u+"-"+d,start:u,end:d,arrowhead:"none",arrowTypeEnd:"",style:p,labelStyle:"",classes:_,arrowheadStyle:g,labelpos:"c",labelType:f,thickness:m,look:o})}else W(r,M,l)}e.doc&&(s.cM.trace("Adding nodes children "),B(e,e.doc,n,r,i,!a,o,l))}),"dataFetcher"),U=(0,s.eW)((()=>{O.clear(),P=0}),"reset"),G="[*]",V="start",q=G,j="color",H="fill";function X(){return new Map}(0,s.eW)(X,"newClassesList");var K=(0,s.eW)((()=>({relations:[],states:new Map,documents:{}})),"newDoc"),Q=(0,s.eW)((t=>JSON.parse(JSON.stringify(t))),"clone"),J=class{static{(0,s.eW)(this,"StateDB")}constructor(t){this.clear(),this.version=t,this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this)}version;nodes=[];edges=[];rootDoc=[];classes=X();documents={root:K()};currentDocument=this.documents.root;startEndCount=0;dividerCnt=0;static relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3};setRootDoc(t){s.cM.info("Setting root doc",t),this.rootDoc=t,1===this.version?this.extract(t):this.extract(this.getRootDocV2())}getRootDoc(){return this.rootDoc}docTranslator(t,e,n){if(e.stmt===h)this.docTranslator(t,e.state1,!0),this.docTranslator(t,e.state2,!1);else if(e.stmt===c&&("[*]"===e.id?(e.id=n?t.id+"_start":t.id+"_end",e.start=n):e.id=e.id.trim()),e.doc){const t=[];let n,r=[];for(n=0;n0&&r.length>0){const n={stmt:c,id:(0,a.Ox)(),type:"divider",doc:Q(r)};t.push(Q(n)),e.doc=t}e.doc.forEach((t=>this.docTranslator(e,t,!0)))}}getRootDocV2(){return this.docTranslator({id:"root"},{id:"root",doc:this.rootDoc},!0),{id:"root",doc:this.rootDoc}}extract(t){let e;e=t.doc?t.doc:t,s.cM.info(e),this.clear(!0),s.cM.info("Extract initial document:",e),e.forEach((t=>{switch(s.cM.warn("Statement",t.stmt),t.stmt){case c:this.addState(t.id.trim(),t.type,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles);break;case h:this.addRelation(t.state1,t.state2,t.description);break;case"classDef":this.addStyleClass(t.id.trim(),t.classes);break;case"style":{const e=t.id.trim().split(","),n=t.styleClass.split(",");e.forEach((t=>{let e=this.getState(t);if(void 0===e){const n=t.trim();this.addState(n),e=this.getState(n)}e.styles=n.map((t=>t.replace(/;/g,"")?.trim()))}))}break;case"applyClass":this.setCssClass(t.id.trim(),t.styleClass)}}));const n=this.getStates(),r=(0,s.nV)().look;U(),Y(void 0,this.getRootDocV2(),n,this.nodes,this.edges,!0,r,this.classes),this.nodes.forEach((t=>{if(Array.isArray(t.label)){if(t.description=t.label.slice(1),t.isGroup&&t.description.length>0)throw new Error("Group nodes can only have label. Remove the additional description for node ["+t.id+"]");t.label=t.label[0]}}))}addState(t,e=u,n=null,r=null,i=null,a=null,o=null,l=null){const c=t?.trim();if(this.currentDocument.states.has(c)?(this.currentDocument.states.get(c).doc||(this.currentDocument.states.get(c).doc=n),this.currentDocument.states.get(c).type||(this.currentDocument.states.get(c).type=e)):(s.cM.info("Adding state ",c,r),this.currentDocument.states.set(c,{id:c,descriptions:[],type:e,doc:n,note:i,classes:[],styles:[],textStyles:[]})),r&&(s.cM.info("Setting state description",c,r),"string"==typeof r&&this.addDescription(c,r.trim()),"object"==typeof r&&r.forEach((t=>this.addDescription(c,t.trim())))),i){const t=this.currentDocument.states.get(c);t.note=i,t.note.text=s.SY.sanitizeText(t.note.text,(0,s.nV)())}a&&(s.cM.info("Setting state classes",c,a),("string"==typeof a?[a]:a).forEach((t=>this.setCssClass(c,t.trim())))),o&&(s.cM.info("Setting state styles",c,o),("string"==typeof o?[o]:o).forEach((t=>this.setStyle(c,t.trim())))),l&&(s.cM.info("Setting state styles",c,o),("string"==typeof l?[l]:l).forEach((t=>this.setTextStyle(c,t.trim()))))}clear(t){this.nodes=[],this.edges=[],this.documents={root:K()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=X(),t||(0,s.ZH)()}getState(t){return this.currentDocument.states.get(t)}getStates(){return this.currentDocument.states}logDocuments(){s.cM.info("Documents = ",this.documents)}getRelations(){return this.currentDocument.relations}startIdIfNeeded(t=""){let e=t;return t===G&&(this.startEndCount++,e=`${V}${this.startEndCount}`),e}startTypeIfNeeded(t="",e=u){return t===G?V:e}endIdIfNeeded(t=""){let e=t;return t===q&&(this.startEndCount++,e=`end${this.startEndCount}`),e}endTypeIfNeeded(t="",e=u){return t===q?"end":e}addRelationObjs(t,e,n){let r=this.startIdIfNeeded(t.id.trim()),i=this.startTypeIfNeeded(t.id.trim(),t.type),a=this.startIdIfNeeded(e.id.trim()),o=this.startTypeIfNeeded(e.id.trim(),e.type);this.addState(r,i,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles),this.addState(a,o,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.currentDocument.relations.push({id1:r,id2:a,relationTitle:s.SY.sanitizeText(n,(0,s.nV)())})}addRelation(t,e,n){if("object"==typeof t)this.addRelationObjs(t,e,n);else{const r=this.startIdIfNeeded(t.trim()),i=this.startTypeIfNeeded(t),a=this.endIdIfNeeded(e.trim()),o=this.endTypeIfNeeded(e);this.addState(r,i),this.addState(a,o),this.currentDocument.relations.push({id1:r,id2:a,title:s.SY.sanitizeText(n,(0,s.nV)())})}}addDescription(t,e){const n=this.currentDocument.states.get(t),r=e.startsWith(":")?e.replace(":","").trim():e;n.descriptions.push(s.SY.sanitizeText(r,(0,s.nV)()))}cleanupLabel(t){return":"===t.substring(0,1)?t.substr(2).trim():t.trim()}getDividerId(){return this.dividerCnt++,"divider-id-"+this.dividerCnt}addStyleClass(t,e=""){this.classes.has(t)||this.classes.set(t,{id:t,styles:[],textStyles:[]});const n=this.classes.get(t);null!=e&&e.split(",").forEach((t=>{const e=t.replace(/([^;]*);/,"$1").trim();if(RegExp(j).exec(t)){const t=e.replace(H,"bgFill").replace(j,H);n.textStyles.push(t)}n.styles.push(e)}))}getClasses(){return this.classes}setCssClass(t,e){t.split(",").forEach((t=>{let n=this.getState(t);if(void 0===n){const e=t.trim();this.addState(e),n=this.getState(e)}n.classes.push(e)}))}setStyle(t,e){const n=this.getState(t);void 0!==n&&n.styles.push(e)}setTextStyle(t,e){const n=this.getState(t);void 0!==n&&n.textStyles.push(e)}getDirectionStatement(){return this.rootDoc.find((t=>"dir"===t.stmt))}getDirection(){return this.getDirectionStatement()?.value??"TB"}setDirection(t){const e=this.getDirectionStatement();e?e.value=t:this.rootDoc.unshift({stmt:"dir",value:t})}trimColon(t){return t&&":"===t[0]?t.substr(1).trim():t.trim()}getData(){const t=(0,s.nV)();return{nodes:this.nodes,edges:this.edges,other:{},config:t,direction:R(this.getRootDocV2())}}getConfig(){return(0,s.nV)().state}getAccTitle=s.eu;setAccTitle=s.GN;getAccDescription=s.Mx;setAccDescription=s.U$;setDiagramTitle=s.g2;getDiagramTitle=s.Kr},tt=(0,s.eW)((t=>`\ndefs #statediagram-barbEnd {\n fill: ${t.transitionColor};\n stroke: ${t.transitionColor};\n }\ng.stateGroup text {\n fill: ${t.nodeBorder};\n stroke: none;\n font-size: 10px;\n}\ng.stateGroup text {\n fill: ${t.textColor};\n stroke: none;\n font-size: 10px;\n\n}\ng.stateGroup .state-title {\n font-weight: bolder;\n fill: ${t.stateLabelColor};\n}\n\ng.stateGroup rect {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n}\n\ng.stateGroup line {\n stroke: ${t.lineColor};\n stroke-width: 1;\n}\n\n.transition {\n stroke: ${t.transitionColor};\n stroke-width: 1;\n fill: none;\n}\n\n.stateGroup .composit {\n fill: ${t.background};\n border-bottom: 1px\n}\n\n.stateGroup .alt-composit {\n fill: #e0e0e0;\n border-bottom: 1px\n}\n\n.state-note {\n stroke: ${t.noteBorderColor};\n fill: ${t.noteBkgColor};\n\n text {\n fill: ${t.noteTextColor};\n stroke: none;\n font-size: 10px;\n }\n}\n\n.stateLabel .box {\n stroke: none;\n stroke-width: 0;\n fill: ${t.mainBkg};\n opacity: 0.5;\n}\n\n.edgeLabel .label rect {\n fill: ${t.labelBackgroundColor};\n opacity: 0.5;\n}\n.edgeLabel {\n background-color: ${t.edgeLabelBackground};\n p {\n background-color: ${t.edgeLabelBackground};\n }\n rect {\n opacity: 0.5;\n background-color: ${t.edgeLabelBackground};\n fill: ${t.edgeLabelBackground};\n }\n text-align: center;\n}\n.edgeLabel .label text {\n fill: ${t.transitionLabelColor||t.tertiaryTextColor};\n}\n.label div .edgeLabel {\n color: ${t.transitionLabelColor||t.tertiaryTextColor};\n}\n\n.stateLabel text {\n fill: ${t.stateLabelColor};\n font-size: 10px;\n font-weight: bold;\n}\n\n.node circle.state-start {\n fill: ${t.specialStateColor};\n stroke: ${t.specialStateColor};\n}\n\n.node .fork-join {\n fill: ${t.specialStateColor};\n stroke: ${t.specialStateColor};\n}\n\n.node circle.state-end {\n fill: ${t.innerEndBackground};\n stroke: ${t.background};\n stroke-width: 1.5\n}\n.end-state-inner {\n fill: ${t.compositeBackground||t.background};\n // stroke: ${t.background};\n stroke-width: 1.5\n}\n\n.node rect {\n fill: ${t.stateBkg||t.mainBkg};\n stroke: ${t.stateBorder||t.nodeBorder};\n stroke-width: 1px;\n}\n.node polygon {\n fill: ${t.mainBkg};\n stroke: ${t.stateBorder||t.nodeBorder};;\n stroke-width: 1px;\n}\n#statediagram-barbEnd {\n fill: ${t.lineColor};\n}\n\n.statediagram-cluster rect {\n fill: ${t.compositeTitleBackground};\n stroke: ${t.stateBorder||t.nodeBorder};\n stroke-width: 1px;\n}\n\n.cluster-label, .nodeLabel {\n color: ${t.stateLabelColor};\n // line-height: 1;\n}\n\n.statediagram-cluster rect.outer {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state .divider {\n stroke: ${t.stateBorder||t.nodeBorder};\n}\n\n.statediagram-state .title-state {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-cluster.statediagram-cluster .inner {\n fill: ${t.compositeBackground||t.background};\n}\n.statediagram-cluster.statediagram-cluster-alt .inner {\n fill: ${t.altBackground?t.altBackground:"#efefef"};\n}\n\n.statediagram-cluster .inner {\n rx:0;\n ry:0;\n}\n\n.statediagram-state rect.basic {\n rx: 5px;\n ry: 5px;\n}\n.statediagram-state rect.divider {\n stroke-dasharray: 10,10;\n fill: ${t.altBackground?t.altBackground:"#efefef"};\n}\n\n.note-edge {\n stroke-dasharray: 5;\n}\n\n.statediagram-note rect {\n fill: ${t.noteBkgColor};\n stroke: ${t.noteBorderColor};\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n.statediagram-note rect {\n fill: ${t.noteBkgColor};\n stroke: ${t.noteBorderColor};\n stroke-width: 1px;\n rx: 0;\n ry: 0;\n}\n\n.statediagram-note text {\n fill: ${t.noteTextColor};\n}\n\n.statediagram-note .nodeLabel {\n color: ${t.noteTextColor};\n}\n.statediagram .edgeLabel {\n color: red; // ${t.noteTextColor};\n}\n\n#dependencyStart, #dependencyEnd {\n fill: ${t.lineColor};\n stroke: ${t.lineColor};\n stroke-width: 1;\n}\n\n.statediagramTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${t.textColor};\n}\n`),"getStyles")},214:(t,e,n)=>{"use strict";n.d(e,{QA:()=>Lt,rw:()=>Rt,EY:()=>It});var r=n(7946),i=n(4082),a=n(3108);let s={async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null};function o(t){s=t}const l={exec:()=>null};function c(t,e=""){let n="string"==typeof t?t:t.source;const r={replace:(t,e)=>{let i="string"==typeof e?e:e.source;return i=i.replace(h.caret,"$1"),n=n.replace(t,i),r},getRegex:()=>new RegExp(n,e)};return r}const h={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[\t ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ \t][^\\n]*)?(?:\\n|$))`),hrRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}#`),htmlBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}<(?:[a-z].*>|!--)`,"i")},u=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,d=/(?:[*+-]|\d{1,9}[.)])/,p=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,g=c(p).replace(/bull/g,d).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),f=c(p).replace(/bull/g,d).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),m=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,y=/(?!\s*\])(?:\\.|[^\[\]\\])+/,v=c(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",y).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),x=c(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,d).getRegex(),b="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",w=/|$))/,k=c("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ \t]*)+\\n|$))","i").replace("comment",w).replace("tag",b).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),T=c(m).replace("hr",u).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",b).getRegex(),_={blockquote:c(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",T).getRegex(),code:/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,def:v,fences:/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,heading:/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,hr:u,html:k,lheading:g,list:x,newline:/^(?:[ \t]*(?:\n|$))+/,paragraph:T,table:l,text:/^[^\n]+/},E=c("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",u).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3}\t)[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",b).getRegex(),S={..._,lheading:f,table:E,paragraph:c(m).replace("hr",u).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",E).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",b).getRegex()},C={..._,html:c("^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))").replace("comment",w).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:l,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:c(m).replace("hr",u).replace("heading"," *#{1,6} *[^\n]").replace("lheading",g).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},A=/^( {2,}|\\)\n(?!\s*$)/,L=/[\p{P}\p{S}]/u,M=/[\s\p{P}\p{S}]/u,N=/[^\s\p{P}\p{S}]/u,I=c(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,M).getRegex(),R=/(?!~)[\p{P}\p{S}]/u,D=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,O=c(D,"u").replace(/punct/g,L).getRegex(),P=c(D,"u").replace(/punct/g,R).getRegex(),$="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",B=c($,"gu").replace(/notPunctSpace/g,N).replace(/punctSpace/g,M).replace(/punct/g,L).getRegex(),F=c($,"gu").replace(/notPunctSpace/g,/(?:[^\s\p{P}\p{S}]|~)/u).replace(/punctSpace/g,/(?!~)[\s\p{P}\p{S}]/u).replace(/punct/g,R).getRegex(),W=c("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,N).replace(/punctSpace/g,M).replace(/punct/g,L).getRegex(),z=c(/\\(punct)/,"gu").replace(/punct/g,L).getRegex(),Z=c(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),Y=c(w).replace("(?:--\x3e|$)","--\x3e").getRegex(),U=c("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",Y).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),G=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,V=c(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",G).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),q=c(/^!?\[(label)\]\[(ref)\]/).replace("label",G).replace("ref",y).getRegex(),j=c(/^!?\[(ref)\](?:\[\])?/).replace("ref",y).getRegex(),H={_backpedal:l,anyPunctuation:z,autolink:Z,blockSkip:/\[[^[\]]*?\]\((?:\\.|[^\\\(\)]|\((?:\\.|[^\\\(\)])*\))*\)|`[^`]*?`|<[^<>]*?>/g,br:A,code:/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,del:l,emStrongLDelim:O,emStrongRDelimAst:B,emStrongRDelimUnd:W,escape:/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,link:V,nolink:j,punctuation:I,reflink:q,reflinkSearch:c("reflink|nolink(?!\\()","g").replace("reflink",q).replace("nolink",j).getRegex(),tag:U,text:/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\":">",'"':""","'":"'"},nt=t=>et[t];function rt(t,e){if(e){if(h.escapeTest.test(t))return t.replace(h.escapeReplace,nt)}else if(h.escapeTestNoEncode.test(t))return t.replace(h.escapeReplaceNoEncode,nt);return t}function it(t){try{t=encodeURI(t).replace(h.percentDecode,"%")}catch{return null}return t}function at(t,e){const n=t.replace(h.findPipe,((t,e,n)=>{let r=!1,i=e;for(;--i>=0&&"\\"===n[i];)r=!r;return r?"|":" |"})).split(h.splitPipe);let r=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),e)if(n.length>e)n.splice(e);else for(;n.length0)return{type:"space",raw:e[0]}}code(t){const e=this.rules.block.code.exec(t);if(e){const t=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?t:st(t,"\n")}}}fences(t){const e=this.rules.block.fences.exec(t);if(e){const t=e[0],n=function(t,e,n){const r=t.match(n.other.indentCodeCompensation);if(null===r)return e;const i=r[1];return e.split("\n").map((t=>{const e=t.match(n.other.beginningSpace);if(null===e)return t;const[r]=e;return r.length>=i.length?t.slice(i.length):t})).join("\n")}(t,e[3]||"",this.rules);return{type:"code",raw:t,lang:e[2]?e[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):e[2],text:n}}}heading(t){const e=this.rules.block.heading.exec(t);if(e){let t=e[2].trim();if(this.rules.other.endingHash.test(t)){const e=st(t,"#");this.options.pedantic?t=e.trim():e&&!this.rules.other.endingSpaceChar.test(e)||(t=e.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:t,tokens:this.lexer.inline(t)}}}hr(t){const e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:st(e[0],"\n")}}blockquote(t){const e=this.rules.block.blockquote.exec(t);if(e){let t=st(e[0],"\n").split("\n"),n="",r="";const i=[];for(;t.length>0;){let e=!1;const a=[];let s;for(s=0;s1,i={type:"list",raw:"",ordered:r,start:r?+n.slice(0,-1):"",loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:"[*+-]");const a=this.rules.other.listItemRegex(n);let s=!1;for(;t;){let n=!1,r="",o="";if(!(e=a.exec(t)))break;if(this.rules.block.hr.test(t))break;r=e[0],t=t.substring(r.length);let l=e[2].split("\n",1)[0].replace(this.rules.other.listReplaceTabs,(t=>" ".repeat(3*t.length))),c=t.split("\n",1)[0],h=!l.trim(),u=0;if(this.options.pedantic?(u=2,o=l.trimStart()):h?u=e[1].length+1:(u=e[2].search(this.rules.other.nonSpaceChar),u=u>4?1:u,o=l.slice(u),u+=e[1].length),h&&this.rules.other.blankLine.test(c)&&(r+=c+"\n",t=t.substring(c.length+1),n=!0),!n){const e=this.rules.other.nextBulletRegex(u),n=this.rules.other.hrRegex(u),i=this.rules.other.fencesBeginRegex(u),a=this.rules.other.headingBeginRegex(u),s=this.rules.other.htmlBeginRegex(u);for(;t;){const d=t.split("\n",1)[0];let p;if(c=d,this.options.pedantic?(c=c.replace(this.rules.other.listReplaceNesting," "),p=c):p=c.replace(this.rules.other.tabCharGlobal," "),i.test(c))break;if(a.test(c))break;if(s.test(c))break;if(e.test(c))break;if(n.test(c))break;if(p.search(this.rules.other.nonSpaceChar)>=u||!c.trim())o+="\n"+p.slice(u);else{if(h)break;if(l.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4)break;if(i.test(l))break;if(a.test(l))break;if(n.test(l))break;o+="\n"+c}h||c.trim()||(h=!0),r+=d+"\n",t=t.substring(d.length+1),l=p.slice(u)}}i.loose||(s?i.loose=!0:this.rules.other.doubleBlankLine.test(r)&&(s=!0));let d,p=null;this.options.gfm&&(p=this.rules.other.listIsTask.exec(o),p&&(d="[ ] "!==p[0],o=o.replace(this.rules.other.listReplaceTask,""))),i.items.push({type:"list_item",raw:r,task:!!p,checked:d,loose:!1,text:o,tokens:[]}),i.raw+=r}const o=i.items.at(-1);if(!o)return;o.raw=o.raw.trimEnd(),o.text=o.text.trimEnd(),i.raw=i.raw.trimEnd();for(let t=0;t"space"===t.type)),n=e.length>0&&e.some((t=>this.rules.other.anyLine.test(t.raw)));i.loose=n}if(i.loose)for(let t=0;t({text:t,tokens:this.lexer.inline(t),header:!1,align:a.align[e]}))));return a}}lheading(t){const e=this.rules.block.lheading.exec(t);if(e)return{type:"heading",raw:e[0],depth:"="===e[2].charAt(0)?1:2,text:e[1],tokens:this.lexer.inline(e[1])}}paragraph(t){const e=this.rules.block.paragraph.exec(t);if(e){const t="\n"===e[1].charAt(e[1].length-1)?e[1].slice(0,-1):e[1];return{type:"paragraph",raw:e[0],text:t,tokens:this.lexer.inline(t)}}}text(t){const e=this.rules.block.text.exec(t);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(t){const e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:e[1]}}tag(t){const e=this.rules.inline.tag.exec(t);if(e)return!this.lexer.state.inLink&&this.rules.other.startATag.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(t){const e=this.rules.inline.link.exec(t);if(e){const t=e[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(t)){if(!this.rules.other.endAngleBracket.test(t))return;const e=st(t.slice(0,-1),"\\");if((t.length-e.length)%2==0)return}else{const t=function(t,e){if(-1===t.indexOf(e[1]))return-1;let n=0;for(let r=0;r0?-2:-1}(e[2],"()");if(-2===t)return;if(t>-1){const n=(0===e[0].indexOf("!")?5:4)+e[1].length+t;e[2]=e[2].substring(0,t),e[0]=e[0].substring(0,n).trim(),e[3]=""}}let n=e[2],r="";if(this.options.pedantic){const t=this.rules.other.pedanticHrefTitle.exec(n);t&&(n=t[1],r=t[3])}else r=e[3]?e[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(n=this.options.pedantic&&!this.rules.other.endAngleBracket.test(t)?n.slice(1):n.slice(1,-1)),ot(e,{href:n?n.replace(this.rules.inline.anyPunctuation,"$1"):n,title:r?r.replace(this.rules.inline.anyPunctuation,"$1"):r},e[0],this.lexer,this.rules)}}reflink(t,e){let n;if((n=this.rules.inline.reflink.exec(t))||(n=this.rules.inline.nolink.exec(t))){const t=e[(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal," ").toLowerCase()];if(!t){const t=n[0].charAt(0);return{type:"text",raw:t,text:t}}return ot(n,t,n[0],this.lexer,this.rules)}}emStrong(t,e,n=""){let r=this.rules.inline.emStrongLDelim.exec(t);if(r&&(!r[3]||!n.match(this.rules.other.unicodeAlphaNumeric))&&(!r[1]&&!r[2]||!n||this.rules.inline.punctuation.exec(n))){const n=[...r[0]].length-1;let i,a,s=n,o=0;const l="*"===r[0][0]?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(l.lastIndex=0,e=e.slice(-1*t.length+n);null!=(r=l.exec(e));){if(i=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!i)continue;if(a=[...i].length,r[3]||r[4]){s+=a;continue}if((r[5]||r[6])&&n%3&&!((n+a)%3)){o+=a;continue}if(s-=a,s>0)continue;a=Math.min(a,a+s+o);const e=[...r[0]][0].length,l=t.slice(0,n+r.index+e+a);if(Math.min(n,a)%2){const t=l.slice(1,-1);return{type:"em",raw:l,text:t,tokens:this.lexer.inlineTokens(t)}}const c=l.slice(2,-2);return{type:"strong",raw:l,text:c,tokens:this.lexer.inlineTokens(c)}}}}codespan(t){const e=this.rules.inline.code.exec(t);if(e){let t=e[2].replace(this.rules.other.newLineCharGlobal," ");const n=this.rules.other.nonSpaceChar.test(t),r=this.rules.other.startingSpaceChar.test(t)&&this.rules.other.endingSpaceChar.test(t);return n&&r&&(t=t.substring(1,t.length-1)),{type:"codespan",raw:e[0],text:t}}}br(t){const e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}}del(t){const e=this.rules.inline.del.exec(t);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(t){const e=this.rules.inline.autolink.exec(t);if(e){let t,n;return"@"===e[2]?(t=e[1],n="mailto:"+t):(t=e[1],n=t),{type:"link",raw:e[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}url(t){let e;if(e=this.rules.inline.url.exec(t)){let t,n;if("@"===e[2])t=e[0],n="mailto:"+t;else{let r;do{r=e[0],e[0]=this.rules.inline._backpedal.exec(e[0])?.[0]??""}while(r!==e[0]);t=e[0],n="www."===e[1]?"http://"+e[0]:e[0]}return{type:"link",raw:e[0],text:t,href:n,tokens:[{type:"text",raw:t,text:t}]}}}inlineText(t){const e=this.rules.inline.text.exec(t);if(e){const t=this.lexer.state.inRawBlock;return{type:"text",raw:e[0],text:e[0],escaped:t}}}}class ct{tokens;options;state;tokenizer;inlineQueue;constructor(t){this.tokens=[],this.tokens.links=Object.create(null),this.options=t||s,this.options.tokenizer=this.options.tokenizer||new lt,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};const e={other:h,block:J.normal,inline:tt.normal};this.options.pedantic?(e.block=J.pedantic,e.inline=tt.pedantic):this.options.gfm&&(e.block=J.gfm,this.options.breaks?e.inline=tt.breaks:e.inline=tt.gfm),this.tokenizer.rules=e}static get rules(){return{block:J,inline:tt}}static lex(t,e){return new ct(e).lex(t)}static lexInline(t,e){return new ct(e).inlineTokens(t)}lex(t){t=t.replace(h.carriageReturn,"\n"),this.blockTokens(t,this.tokens);for(let t=0;t!!(r=n.call({lexer:this},t,e))&&(t=t.substring(r.raw.length),e.push(r),!0))))continue;if(r=this.tokenizer.space(t)){t=t.substring(r.raw.length);const n=e.at(-1);1===r.raw.length&&void 0!==n?n.raw+="\n":e.push(r);continue}if(r=this.tokenizer.code(t)){t=t.substring(r.raw.length);const n=e.at(-1);"paragraph"===n?.type||"text"===n?.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.text,this.inlineQueue.at(-1).src=n.text):e.push(r);continue}if(r=this.tokenizer.fences(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.heading(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.hr(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.blockquote(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.list(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.html(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.def(t)){t=t.substring(r.raw.length);const n=e.at(-1);"paragraph"===n?.type||"text"===n?.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.raw,this.inlineQueue.at(-1).src=n.text):this.tokens.links[r.tag]||(this.tokens.links[r.tag]={href:r.href,title:r.title});continue}if(r=this.tokenizer.table(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.lheading(t)){t=t.substring(r.raw.length),e.push(r);continue}let i=t;if(this.options.extensions?.startBlock){let e=1/0;const n=t.slice(1);let r;this.options.extensions.startBlock.forEach((t=>{r=t.call({lexer:this},n),"number"==typeof r&&r>=0&&(e=Math.min(e,r))})),e<1/0&&e>=0&&(i=t.substring(0,e+1))}if(this.state.top&&(r=this.tokenizer.paragraph(i))){const a=e.at(-1);n&&"paragraph"===a?.type?(a.raw+="\n"+r.raw,a.text+="\n"+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=a.text):e.push(r),n=i.length!==t.length,t=t.substring(r.raw.length)}else if(r=this.tokenizer.text(t)){t=t.substring(r.raw.length);const n=e.at(-1);"text"===n?.type?(n.raw+="\n"+r.raw,n.text+="\n"+r.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=n.text):e.push(r)}else if(t){const e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}return this.state.top=!0,e}inline(t,e=[]){return this.inlineQueue.push({src:t,tokens:e}),e}inlineTokens(t,e=[]){let n=t,r=null;if(this.tokens.links){const t=Object.keys(this.tokens.links);if(t.length>0)for(;null!=(r=this.tokenizer.rules.inline.reflinkSearch.exec(n));)t.includes(r[0].slice(r[0].lastIndexOf("[")+1,-1))&&(n=n.slice(0,r.index)+"["+"a".repeat(r[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;null!=(r=this.tokenizer.rules.inline.anyPunctuation.exec(n));)n=n.slice(0,r.index)+"++"+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;null!=(r=this.tokenizer.rules.inline.blockSkip.exec(n));)n=n.slice(0,r.index)+"["+"a".repeat(r[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);let i=!1,a="";for(;t;){let r;if(i||(a=""),i=!1,this.options.extensions?.inline?.some((n=>!!(r=n.call({lexer:this},t,e))&&(t=t.substring(r.raw.length),e.push(r),!0))))continue;if(r=this.tokenizer.escape(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.tag(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.link(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(r.raw.length);const n=e.at(-1);"text"===r.type&&"text"===n?.type?(n.raw+=r.raw,n.text+=r.text):e.push(r);continue}if(r=this.tokenizer.emStrong(t,n,a)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.codespan(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.br(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.del(t)){t=t.substring(r.raw.length),e.push(r);continue}if(r=this.tokenizer.autolink(t)){t=t.substring(r.raw.length),e.push(r);continue}if(!this.state.inLink&&(r=this.tokenizer.url(t))){t=t.substring(r.raw.length),e.push(r);continue}let s=t;if(this.options.extensions?.startInline){let e=1/0;const n=t.slice(1);let r;this.options.extensions.startInline.forEach((t=>{r=t.call({lexer:this},n),"number"==typeof r&&r>=0&&(e=Math.min(e,r))})),e<1/0&&e>=0&&(s=t.substring(0,e+1))}if(r=this.tokenizer.inlineText(s)){t=t.substring(r.raw.length),"_"!==r.raw.slice(-1)&&(a=r.raw.slice(-1)),i=!0;const n=e.at(-1);"text"===n?.type?(n.raw+=r.raw,n.text+=r.text):e.push(r)}else if(t){const e="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent){console.error(e);break}throw new Error(e)}}return e}}class ht{options;parser;constructor(t){this.options=t||s}space(t){return""}code({text:t,lang:e,escaped:n}){const r=(e||"").match(h.notSpaceStart)?.[0],i=t.replace(h.endingNewline,"")+"\n";return r?'

'+(n?i:rt(i,!0))+"
\n":"
"+(n?i:rt(i,!0))+"
\n"}blockquote({tokens:t}){return`
\n${this.parser.parse(t)}
\n`}html({text:t}){return t}heading({tokens:t,depth:e}){return`${this.parser.parseInline(t)}\n`}hr(t){return"
\n"}list(t){const e=t.ordered,n=t.start;let r="";for(let e=0;e\n"+r+"\n"}listitem(t){let e="";if(t.task){const n=this.checkbox({checked:!!t.checked});t.loose?"paragraph"===t.tokens[0]?.type?(t.tokens[0].text=n+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&"text"===t.tokens[0].tokens[0].type&&(t.tokens[0].tokens[0].text=n+" "+rt(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:n+" ",text:n+" ",escaped:!0}):e+=n+" "}return e+=this.parser.parse(t.tokens,!!t.loose),`
  • ${e}
  • \n`}checkbox({checked:t}){return"'}paragraph({tokens:t}){return`

    ${this.parser.parseInline(t)}

    \n`}table(t){let e="",n="";for(let e=0;e${r}`),"\n\n"+e+"\n"+r+"
    \n"}tablerow({text:t}){return`\n${t}\n`}tablecell(t){const e=this.parser.parseInline(t.tokens),n=t.header?"th":"td";return(t.align?`<${n} align="${t.align}">`:`<${n}>`)+e+`\n`}strong({tokens:t}){return`${this.parser.parseInline(t)}`}em({tokens:t}){return`${this.parser.parseInline(t)}`}codespan({text:t}){return`${rt(t,!0)}`}br(t){return"
    "}del({tokens:t}){return`${this.parser.parseInline(t)}`}link({href:t,title:e,tokens:n}){const r=this.parser.parseInline(n),i=it(t);if(null===i)return r;let a='
    ",a}image({href:t,title:e,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));const i=it(t);if(null===i)return rt(n);let a=`${n}{const i=t[r].flat(1/0);n=n.concat(this.walkTokens(i,e))})):t.tokens&&(n=n.concat(this.walkTokens(t.tokens,e)))}}return n}use(...t){const e=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach((t=>{const n={...t};if(n.async=this.defaults.async||n.async||!1,t.extensions&&(t.extensions.forEach((t=>{if(!t.name)throw new Error("extension name required");if("renderer"in t){const n=e.renderers[t.name];e.renderers[t.name]=n?function(...e){let r=t.renderer.apply(this,e);return!1===r&&(r=n.apply(this,e)),r}:t.renderer}if("tokenizer"in t){if(!t.level||"block"!==t.level&&"inline"!==t.level)throw new Error("extension level must be 'block' or 'inline'");const n=e[t.level];n?n.unshift(t.tokenizer):e[t.level]=[t.tokenizer],t.start&&("block"===t.level?e.startBlock?e.startBlock.push(t.start):e.startBlock=[t.start]:"inline"===t.level&&(e.startInline?e.startInline.push(t.start):e.startInline=[t.start]))}"childTokens"in t&&t.childTokens&&(e.childTokens[t.name]=t.childTokens)})),n.extensions=e),t.renderer){const e=this.defaults.renderer||new ht(this.defaults);for(const n in t.renderer){if(!(n in e))throw new Error(`renderer '${n}' does not exist`);if(["options","parser"].includes(n))continue;const r=n,i=t.renderer[r],a=e[r];e[r]=(...t)=>{let n=i.apply(e,t);return!1===n&&(n=a.apply(e,t)),n||""}}n.renderer=e}if(t.tokenizer){const e=this.defaults.tokenizer||new lt(this.defaults);for(const n in t.tokenizer){if(!(n in e))throw new Error(`tokenizer '${n}' does not exist`);if(["options","rules","lexer"].includes(n))continue;const r=n,i=t.tokenizer[r],a=e[r];e[r]=(...t)=>{let n=i.apply(e,t);return!1===n&&(n=a.apply(e,t)),n}}n.tokenizer=e}if(t.hooks){const e=this.defaults.hooks||new pt;for(const n in t.hooks){if(!(n in e))throw new Error(`hook '${n}' does not exist`);if(["options","block"].includes(n))continue;const r=n,i=t.hooks[r],a=e[r];pt.passThroughHooks.has(n)?e[r]=t=>{if(this.defaults.async)return Promise.resolve(i.call(e,t)).then((t=>a.call(e,t)));const n=i.call(e,t);return a.call(e,n)}:e[r]=(...t)=>{let n=i.apply(e,t);return!1===n&&(n=a.apply(e,t)),n}}n.hooks=e}if(t.walkTokens){const e=this.defaults.walkTokens,r=t.walkTokens;n.walkTokens=function(t){let n=[];return n.push(r.call(this,t)),e&&(n=n.concat(e.call(this,t))),n}}this.defaults={...this.defaults,...n}})),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return ct.lex(t,e??this.defaults)}parser(t,e){return dt.parse(t,e??this.defaults)}parseMarkdown(t){return(e,n)=>{const r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(!0===this.defaults.async&&!1===r.async)return a(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(null==e)return a(new Error("marked(): input parameter is undefined or null"));if("string"!=typeof e)return a(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));i.hooks&&(i.hooks.options=i,i.hooks.block=t);const s=i.hooks?i.hooks.provideLexer():t?ct.lex:ct.lexInline,o=i.hooks?i.hooks.provideParser():t?dt.parse:dt.parseInline;if(i.async)return Promise.resolve(i.hooks?i.hooks.preprocess(e):e).then((t=>s(t,i))).then((t=>i.hooks?i.hooks.processAllTokens(t):t)).then((t=>i.walkTokens?Promise.all(this.walkTokens(t,i.walkTokens)).then((()=>t)):t)).then((t=>o(t,i))).then((t=>i.hooks?i.hooks.postprocess(t):t)).catch(a);try{i.hooks&&(e=i.hooks.preprocess(e));let t=s(e,i);i.hooks&&(t=i.hooks.processAllTokens(t)),i.walkTokens&&this.walkTokens(t,i.walkTokens);let n=o(t,i);return i.hooks&&(n=i.hooks.postprocess(n)),n}catch(t){return a(t)}}}onError(t,e){return n=>{if(n.message+="\nPlease report this to https://github.com/markedjs/marked.",t){const t="

    An error occurred:

    "+rt(n.message+"",!0)+"
    ";return e?Promise.resolve(t):t}if(e)return Promise.reject(n);throw n}}};function ft(t,e){return gt.parse(t,e)}ft.options=ft.setOptions=function(t){return gt.setOptions(t),ft.defaults=gt.defaults,o(ft.defaults),ft},ft.getDefaults=function(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}},ft.defaults=s,ft.use=function(...t){return gt.use(...t),ft.defaults=gt.defaults,o(ft.defaults),ft},ft.walkTokens=function(t,e){return gt.walkTokens(t,e)},ft.parseInline=gt.parseInline,ft.Parser=dt,ft.parser=dt.parse,ft.Renderer=ht,ft.TextRenderer=ut,ft.Lexer=ct,ft.lexer=ct.lex,ft.Tokenizer=lt,ft.Hooks=pt,ft.parse=ft,ft.options,ft.setOptions,ft.use,ft.walkTokens,ft.parseInline,dt.parse,ct.lex;var mt=n(8464);function yt(t,{markdownAutoWrap:e}){const n=t.replace(//g,"\n").replace(/\n{2,}/g,"\n"),r=(0,mt.Z)(n);return!1===e?r.replace(/ /g," "):r}function vt(t,e={}){const n=yt(t,e),r=ft.lexer(n),a=[[]];let s=0;function o(t,e="normal"){"text"===t.type?t.text.split("\n").forEach(((t,n)=>{0!==n&&(s++,a.push([])),t.split(" ").forEach((t=>{(t=t.replace(/'/g,"'"))&&a[s].push({content:t,type:e})}))})):"strong"===t.type||"em"===t.type?t.tokens.forEach((e=>{o(e,t.type)})):"html"===t.type&&a[s].push({content:t.text,type:"normal"})}return(0,i.eW)(o,"processNode"),r.forEach((t=>{"paragraph"===t.type?t.tokens?.forEach((t=>{o(t)})):"html"===t.type&&a[s].push({content:t.text,type:"normal"})})),a}function xt(t,{markdownAutoWrap:e}={}){const n=ft.lexer(t);function r(t){return"text"===t.type?!1===e?t.text.replace(/\n */g,"
    ").replace(/ /g," "):t.text.replace(/\n */g,"
    "):"strong"===t.type?`${t.tokens?.map(r).join("")}`:"em"===t.type?`${t.tokens?.map(r).join("")}`:"paragraph"===t.type?`

    ${t.tokens?.map(r).join("")}

    `:"space"===t.type?"":"html"===t.type?`${t.text}`:"escape"===t.type?t.text:`Unsupported markdown: ${t.type}`}return(0,i.eW)(r,"output"),n.map(r).join("")}function bt(t){return Intl.Segmenter?[...(new Intl.Segmenter).segment(t)].map((t=>t.segment)):[...t]}function wt(t,e){return kt(t,[],bt(e.content),e.type)}function kt(t,e,n,r){if(0===n.length)return[{content:e.join(""),type:r},{content:"",type:r}];const[i,...a]=n,s=[...e,i];return t([{content:s.join(""),type:r}])?kt(t,s,a,r):(0===e.length&&i&&(e.push(i),n.shift()),[{content:e.join(""),type:r},{content:n.join(""),type:r}])}function Tt(t,e){if(t.some((({content:t})=>t.includes("\n"))))throw new Error("splitLineToFitWidth does not support newlines in the line");return _t(t,e)}function _t(t,e,n=[],r=[]){if(0===t.length)return r.length>0&&n.push(r),n.length>0?n:[];let i="";" "===t[0].content&&(i=" ",t.shift());const a=t.shift()??{content:" ",type:"normal"},s=[...r];if(""!==i&&s.push({content:i,type:"normal"}),s.push(a),e(s))return _t(t,e,n,s);if(r.length>0)n.push(r),t.unshift(a);else if(a.content){const[r,i]=wt(e,a);n.push([r]),i.content&&t.unshift(i)}return _t(t,e,n)}function Et(t,e){e&&t.attr("style",e)}async function St(t,e,n,r,a=!1){const s=t.append("foreignObject");s.attr("width",10*n+"px"),s.attr("height",10*n+"px");const o=s.append("xhtml:div");let l=e.label;e.label&&(0,i.l0)(e.label)&&(l=await(0,i.uT)(e.label.replace(i.SY.lineBreakRegex,"\n"),(0,i.nV)()));const c=e.isNode?"nodeLabel":"edgeLabel",h=o.append("span");h.html(l),Et(h,e.labelStyle),h.attr("class",`${c} ${r}`),Et(o,e.labelStyle),o.style("display","table-cell"),o.style("white-space","nowrap"),o.style("line-height","1.5"),o.style("max-width",n+"px"),o.style("text-align","center"),o.attr("xmlns","http://www.w3.org/1999/xhtml"),a&&o.attr("class","labelBkg");let u=o.node().getBoundingClientRect();return u.width===n&&(o.style("display","table"),o.style("white-space","break-spaces"),o.style("width",n+"px"),u=o.node().getBoundingClientRect()),s.node()}function Ct(t,e,n){return t.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",e*n-.1+"em").attr("dy",n+"em")}function At(t,e,n){const r=t.append("text"),i=Ct(r,1,e);Nt(i,n);const a=i.node().getComputedTextLength();return r.remove(),a}function Lt(t,e,n){const r=t.append("text"),i=Ct(r,1,e);Nt(i,[{content:n,type:"normal"}]);const a=i.node()?.getBoundingClientRect();return a&&r.remove(),a}function Mt(t,e,n,r=!1){const a=e.append("g"),s=a.insert("rect").attr("class","background").attr("style","stroke: none"),o=a.append("text").attr("y","-10.1");let l=0;for(const e of n){const n=(0,i.eW)((e=>At(a,1.1,e)<=t),"checkWidth"),r=n(e)?[e]:Tt(e,n);for(const t of r)Nt(Ct(o,l,1.1),t),l++}if(r){const t=o.node().getBBox(),e=2;return s.attr("x",t.x-e).attr("y",t.y-e).attr("width",t.width+2*e).attr("height",t.height+2*e),a.node()}return o.node()}function Nt(t,e){t.text(""),e.forEach(((e,n)=>{const r=t.append("tspan").attr("font-style","em"===e.type?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight","strong"===e.type?"bold":"normal");0===n?r.text(e.content):r.text(" "+e.content)}))}function It(t){return t.replace(/fa[bklrs]?:fa-[\w-]+/g,(t=>``))}(0,i.eW)(yt,"preprocessMarkdown"),(0,i.eW)(vt,"markdownToLines"),(0,i.eW)(xt,"markdownToHTML"),(0,i.eW)(bt,"splitTextToChars"),(0,i.eW)(wt,"splitWordToFitWidth"),(0,i.eW)(kt,"splitWordToFitWidthRecursion"),(0,i.eW)(Tt,"splitLineToFitWidth"),(0,i.eW)(_t,"splitLineToFitWidthRecursion"),(0,i.eW)(Et,"applyStyle"),(0,i.eW)(St,"addHtmlSpan"),(0,i.eW)(Ct,"createTspan"),(0,i.eW)(At,"computeWidthOfText"),(0,i.eW)(Lt,"computeDimensionOfText"),(0,i.eW)(Mt,"createFormattedText"),(0,i.eW)(Nt,"updateTextContentAndStyles"),(0,i.eW)(It,"replaceIconSubstring");var Rt=(0,i.eW)((async(t,e="",{style:n="",isTitle:s=!1,classes:o="",useHtmlLabels:l=!0,isNode:c=!0,width:h=200,addSvgBackground:u=!1}={},d)=>{if(i.cM.debug("XYZ createText",e,n,s,o,l,c,"addSvgBackground: ",u),l){const a=xt(e,d),s=It((0,r.SH)(a)),l=e.replace(/\\\\/g,"\\"),p={isNode:c,label:(0,i.l0)(e)?l:s,labelStyle:n.replace("fill:","color:")};return await St(t,p,h,o,u)}{const r=Mt(h,t,vt(e.replace(//g,"
    ").replace("
    ","
    "),d),!!e&&u);if(c){/stroke:/.exec(n)&&(n=n.replace("stroke:","lineColor:"));const t=n.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");(0,a.Ys)(r).attr("style",t)}else{const t=n.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");(0,a.Ys)(r).select("rect").attr("style",t.replace(/background:/g,"fill:"));const e=n.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");(0,a.Ys)(r).select("text").attr("style",e)}return r}}),"createText")},279:(t,e,n)=>{"use strict";n.d(e,{AD:()=>u,AE:()=>l,Mu:()=>a,O:()=>s,kc:()=>h,rB:()=>c,yU:()=>o});var r=n(4082),i=n(7967),a=(0,r.eW)(((t,e)=>{const n=t.append("rect");if(n.attr("x",e.x),n.attr("y",e.y),n.attr("fill",e.fill),n.attr("stroke",e.stroke),n.attr("width",e.width),n.attr("height",e.height),e.name&&n.attr("name",e.name),e.rx&&n.attr("rx",e.rx),e.ry&&n.attr("ry",e.ry),void 0!==e.attrs)for(const t in e.attrs)n.attr(t,e.attrs[t]);return e.class&&n.attr("class",e.class),n}),"drawRect"),s=(0,r.eW)(((t,e)=>{const n={x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,stroke:e.stroke,class:"rect"};a(t,n).lower()}),"drawBackgroundRect"),o=(0,r.eW)(((t,e)=>{const n=e.text.replace(r.Vw," "),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.attr("class","legend"),i.style("text-anchor",e.anchor),e.class&&i.attr("class",e.class);const a=i.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(n),i}),"drawText"),l=(0,r.eW)(((t,e,n,r)=>{const a=t.append("image");a.attr("x",e),a.attr("y",n);const s=(0,i.N)(r);a.attr("xlink:href",s)}),"drawImage"),c=(0,r.eW)(((t,e,n,r)=>{const a=t.append("use");a.attr("x",e),a.attr("y",n);const s=(0,i.N)(r);a.attr("xlink:href",`#${s}`)}),"drawEmbeddedImage"),h=(0,r.eW)((()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0})),"getNoteRect"),u=(0,r.eW)((()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0})),"getTextObj")},6241:(t,e,n)=>{"use strict";n.d(e,{s4:()=>_,ef:()=>k,cN:()=>x});var r=n(4082);const i=(t,e)=>!!t&&!(!(e&&""===t.prefix||t.prefix)||!t.name),a=Object.freeze({left:0,top:0,width:16,height:16}),s=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),o=Object.freeze({...a,...s}),l=Object.freeze({...o,body:"",hidden:!1});function c(t,e){const n=function(t,e){const n={};!t.hFlip!=!e.hFlip&&(n.hFlip=!0),!t.vFlip!=!e.vFlip&&(n.vFlip=!0);const r=((t.rotate||0)+(e.rotate||0))%4;return r&&(n.rotate=r),n}(t,e);for(const r in l)r in s?r in t&&!(r in n)&&(n[r]=s[r]):r in e?n[r]=e[r]:r in t&&(n[r]=t[r]);return n}function h(t,e,n){const r=t.icons,i=t.aliases||Object.create(null);let a={};function s(t){a=c(r[t]||i[t],a)}return s(e),n.forEach(s),c(t,a)}const u=Object.freeze({width:null,height:null}),d=Object.freeze({...u,...s}),p=/(-?[0-9.]*[0-9]+[0-9.]*)/g,g=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function f(t,e,n){if(1===e)return t;if(n=n||100,"number"==typeof t)return Math.ceil(t*e*n)/n;if("string"!=typeof t)return t;const r=t.split(p);if(null===r||!r.length)return t;const i=[];let a=r.shift(),s=g.test(a);for(;;){if(s){const t=parseFloat(a);isNaN(t)?i.push(a):i.push(Math.ceil(t*e*n)/n)}else i.push(a);if(a=r.shift(),void 0===a)return i.join("");s=!s}}const m=/\sid="(\S+)"/g,y="IconifyId"+Date.now().toString(16)+(16777216*Math.random()|0).toString(16);let v=0;var x={body:'?',height:80,width:80},b=new Map,w=new Map,k=(0,r.eW)((t=>{for(const e of t){if(!e.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(r.cM.debug("Registering icon pack:",e.name),"loader"in e)w.set(e.name,e.loader);else{if(!("icons"in e))throw r.cM.error("Invalid icon loader:",e),new Error('Invalid icon loader. Must have either "icons" or "loader" property.');b.set(e.name,e.icons)}}}),"registerIconPacks"),T=(0,r.eW)((async(t,e)=>{const n=((t,e,n,r="")=>{const a=t.split(":");if("@"===t.slice(0,1)){if(a.length<2||a.length>3)return null;r=a.shift().slice(1)}if(a.length>3||!a.length)return null;if(a.length>1){const t=a.pop(),n=a.pop(),s={provider:a.length>0?a[0]:r,prefix:n,name:t};return e&&!i(s)?null:s}const s=a[0],o=s.split("-");if(o.length>1){const t={provider:r,prefix:o.shift(),name:o.join("-")};return e&&!i(t)?null:t}if(n&&""===r){const t={provider:r,prefix:"",name:s};return e&&!i(t,n)?null:t}return null})(t,!0,void 0!==e);if(!n)throw new Error(`Invalid icon name: ${t}`);const a=n.prefix||e;if(!a)throw new Error(`Icon name must contain a prefix: ${t}`);let s=b.get(a);if(!s){const t=w.get(a);if(!t)throw new Error(`Icon set not found: ${n.prefix}`);try{s={...await t(),prefix:a},b.set(a,s)}catch(t){throw r.cM.error(t),new Error(`Failed to load icon set: ${n.prefix}`)}}const o=function(t,e){if(t.icons[e])return h(t,e,[]);const n=function(t,e){const n=t.icons,r=t.aliases||Object.create(null),i=Object.create(null);return(e||Object.keys(n).concat(Object.keys(r))).forEach((function t(e){if(n[e])return i[e]=[];if(!(e in i)){i[e]=null;const n=r[e]&&r[e].parent,a=n&&t(n);a&&(i[e]=[n].concat(a))}return i[e]})),i}(t,[e])[e];return n?h(t,e,n):null}(s,n.name);if(!o)throw new Error(`Icon not found: ${t}`);return o}),"getRegisteredIconData"),_=(0,r.eW)((async(t,e)=>{let n;try{n=await T(t,e?.fallbackPrefix)}catch(t){r.cM.error(t),n=x}const i=function(t,e){const n={...o,...t},r={...d,...e},i={left:n.left,top:n.top,width:n.width,height:n.height};let a=n.body;[n,r].forEach((t=>{const e=[],n=t.hFlip,r=t.vFlip;let s,o=t.rotate;switch(n?r?o+=2:(e.push("translate("+(i.width+i.left).toString()+" "+(0-i.top).toString()+")"),e.push("scale(-1 1)"),i.top=i.left=0):r&&(e.push("translate("+(0-i.left).toString()+" "+(i.height+i.top).toString()+")"),e.push("scale(1 -1)"),i.top=i.left=0),o<0&&(o-=4*Math.floor(o/4)),o%=4,o){case 1:s=i.height/2+i.top,e.unshift("rotate(90 "+s.toString()+" "+s.toString()+")");break;case 2:e.unshift("rotate(180 "+(i.width/2+i.left).toString()+" "+(i.height/2+i.top).toString()+")");break;case 3:s=i.width/2+i.left,e.unshift("rotate(-90 "+s.toString()+" "+s.toString()+")")}o%2==1&&(i.left!==i.top&&(s=i.left,i.left=i.top,i.top=s),i.width!==i.height&&(s=i.width,i.width=i.height,i.height=s)),e.length&&(a=function(t,e,n){const r=function(t,e="defs"){let n="";const r=t.indexOf("<"+e);for(;r>=0;){const i=t.indexOf(">",r),a=t.indexOf("",a);if(-1===s)break;n+=t.slice(i+1,a).trim(),t=t.slice(0,r).trim()+t.slice(s+1)}return{defs:n,content:t}}(t);return i=r.defs,a=e+r.content+"",i?""+i+""+a:a;var i,a}(a,''))}));const s=r.width,l=r.height,c=i.width,h=i.height;let u,p;null===s?(p=null===l?"1em":"auto"===l?h:l,u=f(p,c/h)):(u="auto"===s?c:s,p=null===l?f(u,h/c):"auto"===l?h:l);const g={},m=(t,e)=>{(t=>"unset"===t||"undefined"===t||"none"===t)(e)||(g[t]=e.toString())};m("width",u),m("height",p);const y=[i.left,i.top,c,h];return g.viewBox=y.join(" "),{attributes:g,viewBox:y,body:a}}(n,e);return function(t,e){let n=-1===t.indexOf("xlink:")?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const t in e)n+=" "+t+'="'+e[t]+'"';return'"+t+""}(function(t,e=y){const n=[];let r;for(;r=m.exec(t);)n.push(r[1]);if(!n.length)return t;const i="suffix"+(16777216*Math.random()|Date.now()).toString(16);return n.forEach((n=>{const r="function"==typeof e?e(n):e+(v++).toString(),a=n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");t=t.replace(new RegExp('([#;"])('+a+')([")]|\\.[a-z])',"g"),"$1"+r+i+"$3")})),t=t.replace(new RegExp(i,"g"),"")}(i.body),i.attributes)}),"getIconSVG")},3583:(t,e,n)=>{"use strict";n.d(e,{C1:()=>h,Fh:()=>E,Lf:()=>Se,XO:()=>b,Yn:()=>Ce,ZH:()=>O,aH:()=>Le,dW:()=>_e,gU:()=>Ae,jr:()=>d,us:()=>D});var r=n(1426),i=n(6241),a=n(214),s=n(7946),o=n(4082),l=n(3108),c=n(4247),h=(0,o.eW)((async(t,e,n)=>{let r;const i=e.useHtmlLabels||(0,o.ku)((0,o.nV)()?.htmlLabels);r=n||"node default";const c=t.insert("g").attr("class",r).attr("id",e.domId||e.id),h=c.insert("g").attr("class","label").attr("style",(0,s.R7)(e.labelStyle));let u;u=void 0===e.label?"":"string"==typeof e.label?e.label:e.label[0];const d=await(0,a.rw)(h,(0,o.oO)((0,s.SH)(u),(0,o.nV)()),{useHtmlLabels:i,width:e.width||(0,o.nV)().flowchart?.wrappingWidth,cssClasses:"markdown-node-label",style:e.labelStyle,addSvgBackground:!!e.icon||!!e.img});let p=d.getBBox();const g=(e?.padding??0)/2;if(i){const t=d.children[0],e=(0,l.Ys)(d),n=t.getElementsByTagName("img");if(n){const t=""===u.replace(/]*>/g,"").trim();await Promise.all([...n].map((e=>new Promise((n=>{function r(){if(e.style.display="flex",e.style.flexDirection="column",t){const t=(0,o.nV)().fontSize?(0,o.nV)().fontSize:window.getComputedStyle(document.body).fontSize,n=5,[r=o.vZ.fontSize]=(0,s.VG)(t),i=r*n+"px";e.style.minWidth=i,e.style.maxWidth=i}else e.style.width="100%";n(e)}(0,o.eW)(r,"setupImage"),setTimeout((()=>{e.complete&&r()})),e.addEventListener("error",r),e.addEventListener("load",r)})))))}p=t.getBoundingClientRect(),e.attr("width",p.width),e.attr("height",p.height)}return i?h.attr("transform","translate("+-p.width/2+", "+-p.height/2+")"):h.attr("transform","translate(0, "+-p.height/2+")"),e.centerLabel&&h.attr("transform","translate("+-p.width/2+", "+-p.height/2+")"),h.insert("rect",":first-child"),{shapeSvg:c,bbox:p,halfPadding:g,label:h}}),"labelHelper"),u=(0,o.eW)((async(t,e,n)=>{const r=n.useHtmlLabels||(0,o.ku)((0,o.nV)()?.flowchart?.htmlLabels),i=t.insert("g").attr("class","label").attr("style",n.labelStyle||""),c=await(0,a.rw)(i,(0,o.oO)((0,s.SH)(e),(0,o.nV)()),{useHtmlLabels:r,width:n.width||(0,o.nV)()?.flowchart?.wrappingWidth,style:n.labelStyle,addSvgBackground:!!n.icon||!!n.img});let h=c.getBBox();const u=n.padding/2;if((0,o.ku)((0,o.nV)()?.flowchart?.htmlLabels)){const t=c.children[0],e=(0,l.Ys)(c);h=t.getBoundingClientRect(),e.attr("width",h.width),e.attr("height",h.height)}return r?i.attr("transform","translate("+-h.width/2+", "+-h.height/2+")"):i.attr("transform","translate(0, "+-h.height/2+")"),n.centerLabel&&i.attr("transform","translate("+-h.width/2+", "+-h.height/2+")"),i.insert("rect",":first-child"),{shapeSvg:t,bbox:h,halfPadding:u,label:i}}),"insertLabel"),d=(0,o.eW)(((t,e)=>{const n=e.node().getBBox();t.width=n.width,t.height=n.height}),"updateNodeBounds"),p=(0,o.eW)(((t,e)=>("handDrawn"===t.look?"rough-node":"node")+" "+t.cssClasses+" "+(e||"")),"getNodeClasses");function g(t){const e=t.map(((t,e)=>`${0===e?"M":"L"}${t.x},${t.y}`));return e.push("Z"),e.join(" ")}function f(t,e,n,r,i,a){const s=[],o=n-t,l=r-e,c=o/a,h=2*Math.PI/c,u=e+l/2;for(let e=0;e<=50;e++){const n=t+e/50*o,r=u+i*Math.sin(h*(n-t));s.push({x:n,y:r})}return s}function m(t,e,n,r,i,a){const s=[],o=i*Math.PI/180,l=(a*Math.PI/180-o)/(r-1);for(let i=0;i{var n,r,i=t.x,a=t.y,s=e.x-i,o=e.y-a,l=t.width/2,c=t.height/2;return Math.abs(o)*l>Math.abs(s)*c?(o<0&&(c=-c),n=0===o?0:c*s/o,r=c):(s<0&&(l=-l),n=l,r=0===s?0:l*o/s),{x:i+n,y:a+r}}),"intersectRect");function v(t,e){e&&t.attr("style",e)}async function x(t){const e=(0,l.Ys)(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),n=e.append("xhtml:div");let r=t.label;t.label&&(0,o.l0)(t.label)&&(r=await(0,o.uT)(t.label.replace(o.SY.lineBreakRegex,"\n"),(0,o.nV)()));const i=t.isNode?"nodeLabel":"edgeLabel";return n.html('"+r+""),v(n,t.labelStyle),n.style("display","inline-block"),n.style("padding-right","1px"),n.style("white-space","nowrap"),n.attr("xmlns","http://www.w3.org/1999/xhtml"),e.node()}(0,o.eW)(v,"applyStyle"),(0,o.eW)(x,"addHtmlLabel");var b=(0,o.eW)((async(t,e,n,r)=>{let i=t||"";if("object"==typeof i&&(i=i[0]),(0,o.ku)((0,o.nV)().flowchart.htmlLabels)){i=i.replace(/\\n|\n/g,"
    "),o.cM.info("vertexText"+i);const t={isNode:r,label:(0,s.SH)(i).replace(/fa[blrs]?:fa-[\w-]+/g,(t=>``)),labelStyle:e?e.replace("fill:","color:"):e};return await x(t)}{const t=document.createElementNS("http://www.w3.org/2000/svg","text");t.setAttribute("style",e.replace("color:","fill:"));let r=[];r="string"==typeof i?i.split(/\\n|\n|/gi):Array.isArray(i)?i:[];for(const e of r){const r=document.createElementNS("http://www.w3.org/2000/svg","tspan");r.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.setAttribute("dy","1em"),r.setAttribute("x","0"),n?r.setAttribute("class","title-row"):r.setAttribute("class","row"),r.textContent=e.trim(),t.appendChild(r)}return t}}),"createLabel"),w=(0,o.eW)(((t,e,n,r,i)=>["M",t+i,e,"H",t+n-i,"A",i,i,0,0,1,t+n,e+i,"V",e+r-i,"A",i,i,0,0,1,t+n-i,e+r,"H",t+i,"A",i,i,0,0,1,t,e+r-i,"V",e+i,"A",i,i,0,0,1,t+i,e,"Z"].join(" ")),"createRoundedRectPathD"),k=(0,o.eW)((t=>{const{handDrawnSeed:e}=(0,o.nV)();return{fill:t,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:t,seed:e}}),"solidStateFill"),T=(0,o.eW)((t=>{const e=_([...t.cssCompiledStyles||[],...t.cssStyles||[]]);return{stylesMap:e,stylesArray:[...e]}}),"compileStyles"),_=(0,o.eW)((t=>{const e=new Map;return t.forEach((t=>{const[n,r]=t.split(":");e.set(n.trim(),r?.trim())})),e}),"styles2Map"),E=(0,o.eW)((t=>"color"===t||"font-size"===t||"font-family"===t||"font-weight"===t||"font-style"===t||"text-decoration"===t||"text-align"===t||"text-transform"===t||"line-height"===t||"letter-spacing"===t||"word-spacing"===t||"text-shadow"===t||"text-overflow"===t||"white-space"===t||"word-wrap"===t||"word-break"===t||"overflow-wrap"===t||"hyphens"===t),"isLabelStyle"),S=(0,o.eW)((t=>{const{stylesArray:e}=T(t),n=[],r=[],i=[],a=[];return e.forEach((t=>{const e=t[0];E(e)?n.push(t.join(":")+" !important"):(r.push(t.join(":")+" !important"),e.includes("stroke")&&i.push(t.join(":")+" !important"),"fill"===e&&a.push(t.join(":")+" !important"))})),{labelStyles:n.join(";"),nodeStyles:r.join(";"),stylesArray:e,borderStyles:i,backgroundStyles:a}}),"styles2String"),C=(0,o.eW)(((t,e)=>{const{themeVariables:n,handDrawnSeed:r}=(0,o.nV)(),{nodeBorder:i,mainBkg:a}=n,{stylesMap:s}=T(t);return Object.assign({roughness:.7,fill:s.get("fill")||a,fillStyle:"hachure",fillWeight:4,hachureGap:5.2,stroke:s.get("stroke")||i,seed:r,strokeWidth:s.get("stroke-width")?.replace("px","")||1.3,fillLineDash:[0,0]},e)}),"userNodeOverrides"),A=(0,o.eW)((async(t,e)=>{o.cM.info("Creating subgraph rect for ",e.id,e);const n=(0,o.nV)(),{themeVariables:i,handDrawnSeed:s}=n,{clusterBkg:h,clusterBorder:u}=i,{labelStyles:d,nodeStyles:p,borderStyles:g,backgroundStyles:f}=S(e),m=t.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.id).attr("data-look",e.look),v=(0,o.ku)(n.flowchart.htmlLabels),x=m.insert("g").attr("class","cluster-label "),b=await(0,a.rw)(x,e.label,{style:e.labelStyle,useHtmlLabels:v,isNode:!0});let k=b.getBBox();if((0,o.ku)(n.flowchart.htmlLabels)){const t=b.children[0],e=(0,l.Ys)(b);k=t.getBoundingClientRect(),e.attr("width",k.width),e.attr("height",k.height)}const T=e.width<=k.width+e.padding?k.width+e.padding:e.width;e.width<=k.width+e.padding?e.diff=(T-e.width)/2-e.padding:e.diff=-e.padding;const _=e.height,E=e.x-T/2,A=e.y-_/2;let L;if(o.cM.trace("Data ",e,JSON.stringify(e)),"handDrawn"===e.look){const t=c.Z.svg(m),n=C(e,{roughness:.7,fill:h,stroke:u,fillWeight:3,seed:s}),r=t.path(w(E,A,T,_,0),n);L=m.insert((()=>(o.cM.debug("Rough node insert CXC",r),r)),":first-child"),L.select("path:nth-child(2)").attr("style",g.join(";")),L.select("path").attr("style",f.join(";").replace("fill","stroke"))}else L=m.insert("rect",":first-child"),L.attr("style",p).attr("rx",e.rx).attr("ry",e.ry).attr("x",E).attr("y",A).attr("width",T).attr("height",_);const{subGraphTitleTopMargin:M}=(0,r.L)(n);if(x.attr("transform",`translate(${e.x-k.width/2}, ${e.y-e.height/2+M})`),d){const t=x.select("span");t&&t.attr("style",d)}const N=L.node().getBBox();return e.offsetX=0,e.width=N.width,e.height=N.height,e.offsetY=k.height-e.padding/2,e.intersect=function(t){return y(e,t)},{cluster:m,labelBBox:k}}),"rect"),L=(0,o.eW)(((t,e)=>{const n=t.insert("g").attr("class","note-cluster").attr("id",e.id),r=n.insert("rect",":first-child"),i=0*e.padding,a=i/2;r.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-a).attr("y",e.y-e.height/2-a).attr("width",e.width+i).attr("height",e.height+i).attr("fill","none");const s=r.node().getBBox();return e.width=s.width,e.height=s.height,e.intersect=function(t){return y(e,t)},{cluster:n,labelBBox:{width:0,height:0}}}),"noteGroup"),M=(0,o.eW)((async(t,e)=>{const n=(0,o.nV)(),{themeVariables:r,handDrawnSeed:i}=n,{altBackground:a,compositeBackground:s,compositeTitleBackground:h,nodeBorder:u}=r,d=t.insert("g").attr("class",e.cssClasses).attr("id",e.id).attr("data-id",e.id).attr("data-look",e.look),p=d.insert("g",":first-child"),g=d.insert("g").attr("class","cluster-label");let f=d.append("rect");const m=g.node().appendChild(await b(e.label,e.labelStyle,void 0,!0));let v=m.getBBox();if((0,o.ku)(n.flowchart.htmlLabels)){const t=m.children[0],e=(0,l.Ys)(m);v=t.getBoundingClientRect(),e.attr("width",v.width),e.attr("height",v.height)}const x=0*e.padding,k=x/2,T=(e.width<=v.width+e.padding?v.width+e.padding:e.width)+x;e.width<=v.width+e.padding?e.diff=(T-e.width)/2-e.padding:e.diff=-e.padding;const _=e.height+x,E=e.height+x-v.height-6,S=e.x-T/2,C=e.y-_/2;e.width=T;const A=e.y-e.height/2-k+v.height+2;let L;if("handDrawn"===e.look){const t=e.cssClasses.includes("statediagram-cluster-alt"),n=c.Z.svg(d),r=e.rx||e.ry?n.path(w(S,C,T,_,10),{roughness:.7,fill:h,fillStyle:"solid",stroke:u,seed:i}):n.rectangle(S,C,T,_,{seed:i});L=d.insert((()=>r),":first-child");const o=n.rectangle(S,A,T,E,{fill:t?a:s,fillStyle:t?"hachure":"solid",stroke:u,seed:i});L=d.insert((()=>r),":first-child"),f=d.insert((()=>o))}else{L=p.insert("rect",":first-child");const t="outer";L.attr("class",t).attr("x",S).attr("y",C).attr("width",T).attr("height",_).attr("data-look",e.look),f.attr("class","inner").attr("x",S).attr("y",A).attr("width",T).attr("height",E)}g.attr("transform",`translate(${e.x-v.width/2}, ${C+1-((0,o.ku)(n.flowchart.htmlLabels)?0:3)})`);const M=L.node().getBBox();return e.height=M.height,e.offsetX=0,e.offsetY=v.height-e.padding/2,e.labelBBox=v,e.intersect=function(t){return y(e,t)},{cluster:d,labelBBox:v}}),"roundedWithTitle"),N=(0,o.eW)((async(t,e)=>{o.cM.info("Creating subgraph rect for ",e.id,e);const n=(0,o.nV)(),{themeVariables:i,handDrawnSeed:s}=n,{clusterBkg:h,clusterBorder:u}=i,{labelStyles:d,nodeStyles:p,borderStyles:g,backgroundStyles:f}=S(e),m=t.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.id).attr("data-look",e.look),v=(0,o.ku)(n.flowchart.htmlLabels),x=m.insert("g").attr("class","cluster-label "),b=await(0,a.rw)(x,e.label,{style:e.labelStyle,useHtmlLabels:v,isNode:!0,width:e.width});let k=b.getBBox();if((0,o.ku)(n.flowchart.htmlLabels)){const t=b.children[0],e=(0,l.Ys)(b);k=t.getBoundingClientRect(),e.attr("width",k.width),e.attr("height",k.height)}const T=e.width<=k.width+e.padding?k.width+e.padding:e.width;e.width<=k.width+e.padding?e.diff=(T-e.width)/2-e.padding:e.diff=-e.padding;const _=e.height,E=e.x-T/2,A=e.y-_/2;let L;if(o.cM.trace("Data ",e,JSON.stringify(e)),"handDrawn"===e.look){const t=c.Z.svg(m),n=C(e,{roughness:.7,fill:h,stroke:u,fillWeight:4,seed:s}),r=t.path(w(E,A,T,_,e.rx),n);L=m.insert((()=>(o.cM.debug("Rough node insert CXC",r),r)),":first-child"),L.select("path:nth-child(2)").attr("style",g.join(";")),L.select("path").attr("style",f.join(";").replace("fill","stroke"))}else L=m.insert("rect",":first-child"),L.attr("style",p).attr("rx",e.rx).attr("ry",e.ry).attr("x",E).attr("y",A).attr("width",T).attr("height",_);const{subGraphTitleTopMargin:M}=(0,r.L)(n);if(x.attr("transform",`translate(${e.x-k.width/2}, ${e.y-e.height/2+M})`),d){const t=x.select("span");t&&t.attr("style",d)}const N=L.node().getBBox();return e.offsetX=0,e.width=N.width,e.height=N.height,e.offsetY=k.height-e.padding/2,e.intersect=function(t){return y(e,t)},{cluster:m,labelBBox:k}}),"kanbanSection"),I={rect:A,squareRect:A,roundedWithTitle:M,noteGroup:L,divider:(0,o.eW)(((t,e)=>{const n=(0,o.nV)(),{themeVariables:r,handDrawnSeed:i}=n,{nodeBorder:a}=r,s=t.insert("g").attr("class",e.cssClasses).attr("id",e.id).attr("data-look",e.look),l=s.insert("g",":first-child"),h=0*e.padding,u=e.width+h;e.diff=-e.padding;const d=e.height+h,p=e.x-u/2,g=e.y-d/2;let f;if(e.width=u,"handDrawn"===e.look){const t=c.Z.svg(s).rectangle(p,g,u,d,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:a,seed:i});f=s.insert((()=>t),":first-child")}else{f=l.insert("rect",":first-child");const t="divider";f.attr("class",t).attr("x",p).attr("y",g).attr("width",u).attr("height",d).attr("data-look",e.look)}const m=f.node().getBBox();return e.height=m.height,e.offsetX=0,e.offsetY=0,e.intersect=function(t){return y(e,t)},{cluster:s,labelBBox:{}}}),"divider"),kanbanSection:N},R=new Map,D=(0,o.eW)((async(t,e)=>{const n=e.shape||"rect",r=await I[n](t,e);return R.set(e.id,r),r}),"insertCluster"),O=(0,o.eW)((()=>{R=new Map}),"clear");function P(t,e){return t.intersect(e)}(0,o.eW)(P,"intersectNode");var $=P;function B(t,e,n,r){var i=t.x,a=t.y,s=i-r.x,o=a-r.y,l=Math.sqrt(e*e*o*o+n*n*s*s),c=Math.abs(e*n*s/l);r.x0}(0,o.eW)(Z,"intersectLine"),(0,o.eW)(Y,"sameSign");var U=Z;function G(t,e,n){let r=t.x,i=t.y,a=[],s=Number.POSITIVE_INFINITY,o=Number.POSITIVE_INFINITY;"function"==typeof e.forEach?e.forEach((function(t){s=Math.min(s,t.x),o=Math.min(o,t.y)})):(s=Math.min(s,e.x),o=Math.min(o,e.y));let l=r-t.width/2-s,c=i-t.height/2-o;for(let r=0;r1&&a.sort((function(t,e){let r=t.x-n.x,i=t.y-n.y,a=Math.sqrt(r*r+i*i),s=e.x-n.x,o=e.y-n.y,l=Math.sqrt(s*s+o*o);return ag),":first-child");return f.attr("class","anchor").attr("style",(0,s.R7)(l)),d(e,f),e.intersect=function(t){return o.cM.info("Circle intersect",e,1,t),V.circle(e,1,t)},a}function j(t,e,n,r,i,a,s){const o=(t+n)/2,l=(e+r)/2,c=Math.atan2(r-e,n-t),h=(n-t)/2/i,u=(r-e)/2/a,d=Math.sqrt(h**2+u**2);if(d>1)throw new Error("The given radii are too small to create an arc between the points.");const p=Math.sqrt(1-d**2),g=o+p*a*Math.sin(c)*(s?-1:1),f=l-p*i*Math.cos(c)*(s?-1:1),m=Math.atan2((e-f)/a,(t-g)/i);let y=Math.atan2((r-f)/a,(n-g)/i)-m;s&&y<0&&(y+=2*Math.PI),!s&&y>0&&(y-=2*Math.PI);const v=[];for(let t=0;t<20;t++){const e=m+t/19*y,n=g+i*Math.cos(e),r=f+a*Math.sin(e);v.push({x:n,y:r})}return v}async function H(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=a.width+e.padding+20,o=a.height+e.padding,l=o/2,u=l/(2.5+o/50),{cssStyles:f}=e,m=[{x:s/2,y:-o/2},{x:-s/2,y:-o/2},...j(-s/2,-o/2,-s/2,o/2,u,l,!1),{x:s/2,y:o/2},...j(s/2,o/2,s/2,-o/2,u,l,!0)],y=c.Z.svg(i),v=C(e,{});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=g(m),b=y.path(x,v),w=i.insert((()=>b),":first-child");return w.attr("class","basic label-container"),f&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",f),r&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",r),w.attr("transform",`translate(${u/2}, 0)`),d(e,w),e.intersect=function(t){return V.polygon(e,m,t)},i}function X(t,e,n,r){return t.insert("polygon",":first-child").attr("points",r.map((function(t){return t.x+","+t.y})).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+n/2+")")}async function K(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=a.height+e.padding,o=a.width+e.padding+12,l=-s,u=[{x:12,y:l},{x:o,y:l},{x:o,y:0},{x:0,y:0},{x:0,y:l+12},{x:12,y:l}];let f;const{cssStyles:m}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=g(u),a=t.path(r,n);f=i.insert((()=>a),":first-child").attr("transform",`translate(${-o/2}, ${s/2})`),m&&f.attr("style",m)}else f=X(i,o,s,u);return r&&f.attr("style",r),d(e,f),e.intersect=function(t){return V.polygon(e,u,t)},i}function Q(t,e){const{nodeStyles:n}=S(e);e.label="";const r=t.insert("g").attr("class",p(e)).attr("id",e.domId??e.id),{cssStyles:i}=e,a=Math.max(28,e.width??0),s=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],o=c.Z.svg(r),l=C(e,{});"handDrawn"!==e.look&&(l.roughness=0,l.fillStyle="solid");const h=g(s),u=o.path(h,l),d=r.insert((()=>u),":first-child");return i&&"handDrawn"!==e.look&&d.selectAll("path").attr("style",i),n&&"handDrawn"!==e.look&&d.selectAll("path").attr("style",n),e.width=28,e.height=28,e.intersect=function(t){return V.polygon(e,s,t)},r}async function J(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,halfPadding:l}=await h(t,e,p(e)),u=a.width/2+l;let g;const{cssStyles:f}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=t.circle(0,0,2*u,n);g=i.insert((()=>r),":first-child"),g.attr("class","basic label-container").attr("style",(0,s.R7)(f))}else g=i.insert("circle",":first-child").attr("class","basic label-container").attr("style",r).attr("r",u).attr("cx",0).attr("cy",0);return d(e,g),e.intersect=function(t){return o.cM.info("Circle intersect",e,u,t),V.circle(e,u,t)},i}function tt(t){const e=Math.cos(Math.PI/4),n=Math.sin(Math.PI/4),r=2*t;return`M ${-r/2*e},${r/2*n} L ${r/2*e},${-r/2*n}\n M ${r/2*e},${r/2*n} L ${-r/2*e},${-r/2*n}`}function et(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n,e.label="";const i=t.insert("g").attr("class",p(e)).attr("id",e.domId??e.id),a=Math.max(30,e?.width??0),{cssStyles:s}=e,l=c.Z.svg(i),h=C(e,{});"handDrawn"!==e.look&&(h.roughness=0,h.fillStyle="solid");const u=l.circle(0,0,2*a,h),g=tt(a),f=l.path(g,h),m=i.insert((()=>u),":first-child");return m.insert((()=>f)),s&&"handDrawn"!==e.look&&m.selectAll("path").attr("style",s),r&&"handDrawn"!==e.look&&m.selectAll("path").attr("style",r),d(e,m),e.intersect=function(t){return o.cM.info("crossedCircle intersect",e,{radius:a,point:t}),V.circle(e,a,t)},i}function nt(t,e,n,r=100,i=0,a=180){const s=[],o=i*Math.PI/180,l=(a*Math.PI/180-o)/(r-1);for(let i=0;iT),":first-child").attr("stroke-opacity",0),_.insert((()=>w),":first-child"),_.attr("class","text"),f&&"handDrawn"!==e.look&&_.selectAll("path").attr("style",f),r&&"handDrawn"!==e.look&&_.selectAll("path").attr("style",r),_.attr("transform",`translate(${u}, 0)`),s.attr("transform",`translate(${-o/2+u-(a.x-(a.left??0))},${-l/2+(e.padding??0)/2-(a.y-(a.top??0))})`),d(e,_),e.intersect=function(t){return V.polygon(e,y,t)},i}function it(t,e,n,r=100,i=0,a=180){const s=[],o=i*Math.PI/180,l=(a*Math.PI/180-o)/(r-1);for(let i=0;iT),":first-child").attr("stroke-opacity",0),_.insert((()=>w),":first-child"),_.attr("class","text"),f&&"handDrawn"!==e.look&&_.selectAll("path").attr("style",f),r&&"handDrawn"!==e.look&&_.selectAll("path").attr("style",r),_.attr("transform",`translate(${-u}, 0)`),s.attr("transform",`translate(${-o/2+(e.padding??0)/2-(a.x-(a.left??0))},${-l/2+(e.padding??0)/2-(a.y-(a.top??0))})`),d(e,_),e.intersect=function(t){return V.polygon(e,y,t)},i}function st(t,e,n,r=100,i=0,a=180){const s=[],o=i*Math.PI/180,l=(a*Math.PI/180-o)/(r-1);for(let i=0;iA),":first-child").attr("stroke-opacity",0),L.insert((()=>k),":first-child"),L.insert((()=>_),":first-child"),L.attr("class","text"),f&&"handDrawn"!==e.look&&L.selectAll("path").attr("style",f),r&&"handDrawn"!==e.look&&L.selectAll("path").attr("style",r),L.attr("transform",`translate(${u-u/4}, 0)`),s.attr("transform",`translate(${-o/2+(e.padding??0)/2-(a.x-(a.left??0))},${-l/2+(e.padding??0)/2-(a.y-(a.top??0))})`),d(e,L),e.intersect=function(t){return V.polygon(e,v,t)},i}async function lt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(80,1.25*(a.width+2*(e.padding??0)),e?.width??0),o=Math.max(20,a.height+2*(e.padding??0),e?.height??0),l=o/2,{cssStyles:u}=e,f=c.Z.svg(i),y=C(e,{});"handDrawn"!==e.look&&(y.roughness=0,y.fillStyle="solid");const v=s-l,x=o/4,b=[{x:v,y:0},{x,y:0},{x:0,y:o/2},{x,y:o},{x:v,y:o},...m(-v,-o/2,l,50,270,90)],w=g(b),k=f.path(w,y),T=i.insert((()=>k),":first-child");return T.attr("class","basic label-container"),u&&"handDrawn"!==e.look&&T.selectChildren("path").attr("style",u),r&&"handDrawn"!==e.look&&T.selectChildren("path").attr("style",r),T.attr("transform",`translate(${-s/2}, ${-o/2})`),d(e,T),e.intersect=function(t){return V.polygon(e,b,t)},i}(0,o.eW)(q,"anchor"),(0,o.eW)(j,"generateArcPoints"),(0,o.eW)(H,"bowTieRect"),(0,o.eW)(X,"insertPolygonShape"),(0,o.eW)(K,"card"),(0,o.eW)(Q,"choice"),(0,o.eW)(J,"circle"),(0,o.eW)(tt,"createLine"),(0,o.eW)(et,"crossedCircle"),(0,o.eW)(nt,"generateCirclePoints"),(0,o.eW)(rt,"curlyBraceLeft"),(0,o.eW)(it,"generateCirclePoints"),(0,o.eW)(at,"curlyBraceRight"),(0,o.eW)(st,"generateCirclePoints"),(0,o.eW)(ot,"curlyBraces"),(0,o.eW)(lt,"curvedTrapezoid");var ct=(0,o.eW)(((t,e,n,r,i,a)=>[`M${t},${e+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,"l0,"+-r].join(" ")),"createCylinderPathD"),ht=(0,o.eW)(((t,e,n,r,i,a)=>[`M${t},${e+a}`,`M${t+n},${e+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,"l0,"+-r].join(" ")),"createOuterCylinderPathD"),ut=(0,o.eW)(((t,e,n,r,i,a)=>[`M${t-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(" ")),"createInnerCylinderPathD");async function dt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:o}=await h(t,e,p(e)),l=Math.max(a.width+e.padding,e.width??0),u=l/2,g=u/(2.5+l/50),f=Math.max(a.height+g+e.padding,e.height??0);let m;const{cssStyles:y}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=ht(0,0,l,f,u,g),r=ut(0,g,l,f,u,g),a=t.path(n,C(e,{})),s=t.path(r,C(e,{fill:"none"}));m=i.insert((()=>s),":first-child"),m=i.insert((()=>a),":first-child"),m.attr("class","basic label-container"),y&&m.attr("style",y)}else{const t=ct(0,0,l,f,u,g);m=i.insert("path",":first-child").attr("d",t).attr("class","basic label-container").attr("style",(0,s.R7)(y)).attr("style",r)}return m.attr("label-offset-y",g),m.attr("transform",`translate(${-l/2}, ${-(f/2+g)})`),d(e,m),o.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${-a.height/2+(e.padding??0)/1.5-(a.y-(a.top??0))})`),e.intersect=function(t){const n=V.rect(e,t),r=n.x-(e.x??0);if(0!=u&&(Math.abs(r)<(e.width??0)/2||Math.abs(r)==(e.width??0)/2&&Math.abs(n.y-(e.y??0))>(e.height??0)/2-g)){let i=g*g*(1-r*r/(u*u));i>0&&(i=Math.sqrt(i)),i=g-i,t.y-(e.y??0)>0&&(i=-i),n.y+=i}return n},i}async function pt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=a.width+e.padding,l=a.height+e.padding,u=.2*l,g=-o/2,f=-l/2-u/2,{cssStyles:m}=e,y=c.Z.svg(i),v=C(e,{});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=[{x:g,y:f+u},{x:-g,y:f+u},{x:-g,y:-f},{x:g,y:-f},{x:g,y:f},{x:-g,y:f},{x:-g,y:f+u}],b=y.polygon(x.map((t=>[t.x,t.y])),v),w=i.insert((()=>b),":first-child");return w.attr("class","basic label-container"),m&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",m),r&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",r),s.attr("transform",`translate(${g+(e.padding??0)/2-(a.x-(a.left??0))}, ${f+u+(e.padding??0)/2-(a.y-(a.top??0))})`),d(e,w),e.intersect=function(t){return V.rect(e,t)},i}async function gt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,halfPadding:l}=await h(t,e,p(e)),u=a.width/2+l+5,g=a.width/2+l;let f;const{cssStyles:m}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{roughness:.2,strokeWidth:2.5}),r=C(e,{roughness:.2,strokeWidth:1.5}),a=t.circle(0,0,2*u,n),o=t.circle(0,0,2*g,r);f=i.insert("g",":first-child"),f.attr("class",(0,s.R7)(e.cssClasses)).attr("style",(0,s.R7)(m)),f.node()?.appendChild(a),f.node()?.appendChild(o)}else{f=i.insert("g",":first-child");const t=f.insert("circle",":first-child"),e=f.insert("circle");f.attr("class","basic label-container").attr("style",r),t.attr("class","outer-circle").attr("style",r).attr("r",u).attr("cx",0).attr("cy",0),e.attr("class","inner-circle").attr("style",r).attr("r",g).attr("cx",0).attr("cy",0)}return d(e,f),e.intersect=function(t){return o.cM.info("DoubleCircle intersect",e,u,t),V.circle(e,u,t)},i}function ft(t,e,{config:{themeVariables:n}}){const{labelStyles:r,nodeStyles:i}=S(e);e.label="",e.labelStyle=r;const a=t.insert("g").attr("class",p(e)).attr("id",e.domId??e.id),{cssStyles:s}=e,l=c.Z.svg(a),{nodeBorder:h}=n,u=C(e,{fillStyle:"solid"});"handDrawn"!==e.look&&(u.roughness=0);const g=l.circle(0,0,14,u),f=a.insert((()=>g),":first-child");return f.selectAll("path").attr("style",`fill: ${h} !important;`),s&&s.length>0&&"handDrawn"!==e.look&&f.selectAll("path").attr("style",s),i&&"handDrawn"!==e.look&&f.selectAll("path").attr("style",i),d(e,f),e.intersect=function(t){return o.cM.info("filledCircle intersect",e,{radius:7,point:t}),V.circle(e,7,t)},a}async function mt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),l=a.width+(e.padding??0),u=l+a.height,f=l+a.height,m=[{x:0,y:-u},{x:f,y:-u},{x:f/2,y:0}],{cssStyles:y}=e,v=c.Z.svg(i),x=C(e,{});"handDrawn"!==e.look&&(x.roughness=0,x.fillStyle="solid");const b=g(m),w=v.path(b,x),k=i.insert((()=>w),":first-child").attr("transform",`translate(${-u/2}, ${u/2})`);return y&&"handDrawn"!==e.look&&k.selectChildren("path").attr("style",y),r&&"handDrawn"!==e.look&&k.selectChildren("path").attr("style",r),e.width=l,e.height=u,d(e,k),s.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${-u/2+(e.padding??0)/2+(a.y-(a.top??0))})`),e.intersect=function(t){return o.cM.info("Triangle intersect",e,m,t),V.polygon(e,m,t)},i}function yt(t,e,{dir:n,config:{state:r,themeVariables:i}}){const{nodeStyles:a}=S(e);e.label="";const s=t.insert("g").attr("class",p(e)).attr("id",e.domId??e.id),{cssStyles:o}=e;let l=Math.max(70,e?.width??0),h=Math.max(10,e?.height??0);"LR"===n&&(l=Math.max(10,e?.width??0),h=Math.max(70,e?.height??0));const u=-1*l/2,g=-1*h/2,f=c.Z.svg(s),m=C(e,{stroke:i.lineColor,fill:i.lineColor});"handDrawn"!==e.look&&(m.roughness=0,m.fillStyle="solid");const y=f.rectangle(u,g,l,h,m),v=s.insert((()=>y),":first-child");o&&"handDrawn"!==e.look&&v.selectAll("path").attr("style",o),a&&"handDrawn"!==e.look&&v.selectAll("path").attr("style",a),d(e,v);const x=r?.padding??0;return e.width&&e.height&&(e.width+=x/2||0,e.height+=x/2||0),e.intersect=function(t){return V.rect(e,t)},s}async function vt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(80,a.width+2*(e.padding??0),e?.width??0),l=Math.max(50,a.height+2*(e.padding??0),e?.height??0),u=l/2,{cssStyles:f}=e,y=c.Z.svg(i),v=C(e,{});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=[{x:-s/2,y:-l/2},{x:s/2-u,y:-l/2},...m(-s/2+u,0,u,50,90,270),{x:s/2-u,y:l/2},{x:-s/2,y:l/2}],b=g(x),w=y.path(b,v),k=i.insert((()=>w),":first-child");return k.attr("class","basic label-container"),f&&"handDrawn"!==e.look&&k.selectChildren("path").attr("style",f),r&&"handDrawn"!==e.look&&k.selectChildren("path").attr("style",r),d(e,k),e.intersect=function(t){return o.cM.info("Pill intersect",e,{radius:u,point:t}),V.polygon(e,x,t)},i}(0,o.eW)(dt,"cylinder"),(0,o.eW)(pt,"dividedRectangle"),(0,o.eW)(gt,"doublecircle"),(0,o.eW)(ft,"filledCircle"),(0,o.eW)(mt,"flippedTriangle"),(0,o.eW)(yt,"forkJoin"),(0,o.eW)(vt,"halfRoundedRectangle");var xt=(0,o.eW)(((t,e,n,r,i)=>[`M${t+i},${e}`,`L${t+n-i},${e}`,`L${t+n},${e-r/2}`,`L${t+n-i},${e-r}`,`L${t+i},${e-r}`,`L${t},${e-r/2}`,"Z"].join(" ")),"createHexagonPathD");async function bt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=a.height+e.padding,o=s/4,l=a.width+2*o+e.padding,u=[{x:o,y:0},{x:l-o,y:0},{x:l,y:-s/2},{x:l-o,y:-s},{x:o,y:-s},{x:0,y:-s/2}];let g;const{cssStyles:f}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=xt(0,0,l,s,o),a=t.path(r,n);g=i.insert((()=>a),":first-child").attr("transform",`translate(${-l/2}, ${s/2})`),f&&g.attr("style",f)}else g=X(i,l,s,u);return r&&g.attr("style",r),e.width=l,e.height=s,d(e,g),e.intersect=function(t){return V.polygon(e,u,t)},i}async function wt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.label="",e.labelStyle=n;const{shapeSvg:i}=await h(t,e,p(e)),a=Math.max(30,e?.width??0),s=Math.max(30,e?.height??0),{cssStyles:l}=e,u=c.Z.svg(i),f=C(e,{});"handDrawn"!==e.look&&(f.roughness=0,f.fillStyle="solid");const m=[{x:0,y:0},{x:a,y:0},{x:0,y:s},{x:a,y:s}],y=g(m),v=u.path(y,f),x=i.insert((()=>v),":first-child");return x.attr("class","basic label-container"),l&&"handDrawn"!==e.look&&x.selectChildren("path").attr("style",l),r&&"handDrawn"!==e.look&&x.selectChildren("path").attr("style",r),x.attr("transform",`translate(${-a/2}, ${-s/2})`),d(e,x),e.intersect=function(t){return o.cM.info("Pill intersect",e,{points:m}),V.polygon(e,m,t)},i}async function kt(t,e,{config:{themeVariables:n,flowchart:r}}){const{labelStyles:a}=S(e);e.labelStyle=a;const s=e.assetHeight??48,l=e.assetWidth??48,u=Math.max(s,l),p=r?.wrappingWidth;e.width=Math.max(u,p??0);const{shapeSvg:g,bbox:f,label:m}=await h(t,e,"icon-shape default"),y="t"===e.pos,v=u,x=u,{nodeBorder:b}=n,{stylesMap:w}=T(e),k=-x/2,_=-v/2,E=e.label?8:0,A=c.Z.svg(g),L=C(e,{stroke:"none",fill:"none"});"handDrawn"!==e.look&&(L.roughness=0,L.fillStyle="solid");const M=A.rectangle(k,_,x,v,L),N=Math.max(x,f.width),I=v+f.height+E,R=A.rectangle(-N/2,-I/2,N,I,{...L,fill:"transparent",stroke:"none"}),D=g.insert((()=>M),":first-child"),O=g.insert((()=>R));if(e.icon){const t=g.append("g");t.html(`${await(0,i.s4)(e.icon,{height:u,width:u,fallbackPrefix:""})}`);const n=t.node().getBBox(),r=n.width,a=n.height,s=n.x,o=n.y;t.attr("transform",`translate(${-r/2-s},${y?f.height/2+E/2-a/2-o:-f.height/2-E/2-a/2-o})`),t.attr("style",`color: ${w.get("stroke")??b};`)}return m.attr("transform",`translate(${-f.width/2-(f.x-(f.left??0))},${y?-I/2:I/2-f.height})`),D.attr("transform",`translate(0,${y?f.height/2+E/2:-f.height/2-E/2})`),d(e,O),e.intersect=function(t){if(o.cM.info("iconSquare intersect",e,t),!e.label)return V.rect(e,t);const n=e.x??0,r=e.y??0,i=e.height??0;let a=[];return a=y?[{x:n-f.width/2,y:r-i/2},{x:n+f.width/2,y:r-i/2},{x:n+f.width/2,y:r-i/2+f.height+E},{x:n+x/2,y:r-i/2+f.height+E},{x:n+x/2,y:r+i/2},{x:n-x/2,y:r+i/2},{x:n-x/2,y:r-i/2+f.height+E},{x:n-f.width/2,y:r-i/2+f.height+E}]:[{x:n-x/2,y:r-i/2},{x:n+x/2,y:r-i/2},{x:n+x/2,y:r-i/2+v},{x:n+f.width/2,y:r-i/2+v},{x:n+f.width/2/2,y:r+i/2},{x:n-f.width/2,y:r+i/2},{x:n-f.width/2,y:r-i/2+v},{x:n-x/2,y:r-i/2+v}],V.polygon(e,a,t)},g}async function Tt(t,e,{config:{themeVariables:n,flowchart:r}}){const{labelStyles:a}=S(e);e.labelStyle=a;const s=e.assetHeight??48,l=e.assetWidth??48,u=Math.max(s,l),p=r?.wrappingWidth;e.width=Math.max(u,p??0);const{shapeSvg:g,bbox:f,label:m}=await h(t,e,"icon-shape default"),y=e.label?8:0,v="t"===e.pos,{nodeBorder:x,mainBkg:b}=n,{stylesMap:w}=T(e),k=c.Z.svg(g),_=C(e,{});"handDrawn"!==e.look&&(_.roughness=0,_.fillStyle="solid");const E=w.get("fill");_.stroke=E??b;const A=g.append("g");e.icon&&A.html(`${await(0,i.s4)(e.icon,{height:u,width:u,fallbackPrefix:""})}`);const L=A.node().getBBox(),M=L.width,N=L.height,I=L.x,R=L.y,D=Math.max(M,N)*Math.SQRT2+40,O=k.circle(0,0,D,_),P=Math.max(D,f.width),$=D+f.height+y,B=k.rectangle(-P/2,-$/2,P,$,{..._,fill:"transparent",stroke:"none"}),F=g.insert((()=>O),":first-child"),W=g.insert((()=>B));return A.attr("transform",`translate(${-M/2-I},${v?f.height/2+y/2-N/2-R:-f.height/2-y/2-N/2-R})`),A.attr("style",`color: ${w.get("stroke")??x};`),m.attr("transform",`translate(${-f.width/2-(f.x-(f.left??0))},${v?-$/2:$/2-f.height})`),F.attr("transform",`translate(0,${v?f.height/2+y/2:-f.height/2-y/2})`),d(e,W),e.intersect=function(t){return o.cM.info("iconSquare intersect",e,t),V.rect(e,t)},g}async function _t(t,e,{config:{themeVariables:n,flowchart:r}}){const{labelStyles:a}=S(e);e.labelStyle=a;const s=e.assetHeight??48,l=e.assetWidth??48,u=Math.max(s,l),p=r?.wrappingWidth;e.width=Math.max(u,p??0);const{shapeSvg:g,bbox:f,halfPadding:m,label:y}=await h(t,e,"icon-shape default"),v="t"===e.pos,x=u+2*m,b=u+2*m,{nodeBorder:k,mainBkg:_}=n,{stylesMap:E}=T(e),A=-b/2,L=-x/2,M=e.label?8:0,N=c.Z.svg(g),I=C(e,{});"handDrawn"!==e.look&&(I.roughness=0,I.fillStyle="solid");const R=E.get("fill");I.stroke=R??_;const D=N.path(w(A,L,b,x,5),I),O=Math.max(b,f.width),P=x+f.height+M,$=N.rectangle(-O/2,-P/2,O,P,{...I,fill:"transparent",stroke:"none"}),B=g.insert((()=>D),":first-child").attr("class","icon-shape2"),F=g.insert((()=>$));if(e.icon){const t=g.append("g");t.html(`${await(0,i.s4)(e.icon,{height:u,width:u,fallbackPrefix:""})}`);const n=t.node().getBBox(),r=n.width,a=n.height,s=n.x,o=n.y;t.attr("transform",`translate(${-r/2-s},${v?f.height/2+M/2-a/2-o:-f.height/2-M/2-a/2-o})`),t.attr("style",`color: ${E.get("stroke")??k};`)}return y.attr("transform",`translate(${-f.width/2-(f.x-(f.left??0))},${v?-P/2:P/2-f.height})`),B.attr("transform",`translate(0,${v?f.height/2+M/2:-f.height/2-M/2})`),d(e,F),e.intersect=function(t){if(o.cM.info("iconSquare intersect",e,t),!e.label)return V.rect(e,t);const n=e.x??0,r=e.y??0,i=e.height??0;let a=[];return a=v?[{x:n-f.width/2,y:r-i/2},{x:n+f.width/2,y:r-i/2},{x:n+f.width/2,y:r-i/2+f.height+M},{x:n+b/2,y:r-i/2+f.height+M},{x:n+b/2,y:r+i/2},{x:n-b/2,y:r+i/2},{x:n-b/2,y:r-i/2+f.height+M},{x:n-f.width/2,y:r-i/2+f.height+M}]:[{x:n-b/2,y:r-i/2},{x:n+b/2,y:r-i/2},{x:n+b/2,y:r-i/2+x},{x:n+f.width/2,y:r-i/2+x},{x:n+f.width/2/2,y:r+i/2},{x:n-f.width/2,y:r+i/2},{x:n-f.width/2,y:r-i/2+x},{x:n-b/2,y:r-i/2+x}],V.polygon(e,a,t)},g}async function Et(t,e,{config:{themeVariables:n,flowchart:r}}){const{labelStyles:a}=S(e);e.labelStyle=a;const s=e.assetHeight??48,l=e.assetWidth??48,u=Math.max(s,l),p=r?.wrappingWidth;e.width=Math.max(u,p??0);const{shapeSvg:g,bbox:f,halfPadding:m,label:y}=await h(t,e,"icon-shape default"),v="t"===e.pos,x=u+2*m,b=u+2*m,{nodeBorder:k,mainBkg:_}=n,{stylesMap:E}=T(e),A=-b/2,L=-x/2,M=e.label?8:0,N=c.Z.svg(g),I=C(e,{});"handDrawn"!==e.look&&(I.roughness=0,I.fillStyle="solid");const R=E.get("fill");I.stroke=R??_;const D=N.path(w(A,L,b,x,.1),I),O=Math.max(b,f.width),P=x+f.height+M,$=N.rectangle(-O/2,-P/2,O,P,{...I,fill:"transparent",stroke:"none"}),B=g.insert((()=>D),":first-child"),F=g.insert((()=>$));if(e.icon){const t=g.append("g");t.html(`${await(0,i.s4)(e.icon,{height:u,width:u,fallbackPrefix:""})}`);const n=t.node().getBBox(),r=n.width,a=n.height,s=n.x,o=n.y;t.attr("transform",`translate(${-r/2-s},${v?f.height/2+M/2-a/2-o:-f.height/2-M/2-a/2-o})`),t.attr("style",`color: ${E.get("stroke")??k};`)}return y.attr("transform",`translate(${-f.width/2-(f.x-(f.left??0))},${v?-P/2:P/2-f.height})`),B.attr("transform",`translate(0,${v?f.height/2+M/2:-f.height/2-M/2})`),d(e,F),e.intersect=function(t){if(o.cM.info("iconSquare intersect",e,t),!e.label)return V.rect(e,t);const n=e.x??0,r=e.y??0,i=e.height??0;let a=[];return a=v?[{x:n-f.width/2,y:r-i/2},{x:n+f.width/2,y:r-i/2},{x:n+f.width/2,y:r-i/2+f.height+M},{x:n+b/2,y:r-i/2+f.height+M},{x:n+b/2,y:r+i/2},{x:n-b/2,y:r+i/2},{x:n-b/2,y:r-i/2+f.height+M},{x:n-f.width/2,y:r-i/2+f.height+M}]:[{x:n-b/2,y:r-i/2},{x:n+b/2,y:r-i/2},{x:n+b/2,y:r-i/2+x},{x:n+f.width/2,y:r-i/2+x},{x:n+f.width/2/2,y:r+i/2},{x:n-f.width/2,y:r+i/2},{x:n-f.width/2,y:r-i/2+x},{x:n-b/2,y:r-i/2+x}],V.polygon(e,a,t)},g}async function St(t,e,{config:{flowchart:n}}){const r=new Image;r.src=e?.img??"",await r.decode();const i=Number(r.naturalWidth.toString().replace("px","")),a=Number(r.naturalHeight.toString().replace("px",""));e.imageAspectRatio=i/a;const{labelStyles:s}=S(e);e.labelStyle=s;const l=n?.wrappingWidth;e.defaultWidth=n?.wrappingWidth;const u=Math.max(e.label?l??0:0,e?.assetWidth??i),p="on"===e.constraint&&e?.assetHeight?e.assetHeight*e.imageAspectRatio:u,g="on"===e.constraint?p/e.imageAspectRatio:e?.assetHeight??a;e.width=Math.max(p,l??0);const{shapeSvg:f,bbox:m,label:y}=await h(t,e,"image-shape default"),v="t"===e.pos,x=-p/2,b=-g/2,w=e.label?8:0,k=c.Z.svg(f),T=C(e,{});"handDrawn"!==e.look&&(T.roughness=0,T.fillStyle="solid");const _=k.rectangle(x,b,p,g,T),E=Math.max(p,m.width),A=g+m.height+w,L=k.rectangle(-E/2,-A/2,E,A,{...T,fill:"none",stroke:"none"}),M=f.insert((()=>_),":first-child"),N=f.insert((()=>L));if(e.img){const t=f.append("image");t.attr("href",e.img),t.attr("width",p),t.attr("height",g),t.attr("preserveAspectRatio","none"),t.attr("transform",`translate(${-p/2},${v?A/2-g:-A/2})`)}return y.attr("transform",`translate(${-m.width/2-(m.x-(m.left??0))},${v?-g/2-m.height/2-w/2:g/2-m.height/2+w/2})`),M.attr("transform",`translate(0,${v?m.height/2+w/2:-m.height/2-w/2})`),d(e,N),e.intersect=function(t){if(o.cM.info("iconSquare intersect",e,t),!e.label)return V.rect(e,t);const n=e.x??0,r=e.y??0,i=e.height??0;let a=[];return a=v?[{x:n-m.width/2,y:r-i/2},{x:n+m.width/2,y:r-i/2},{x:n+m.width/2,y:r-i/2+m.height+w},{x:n+p/2,y:r-i/2+m.height+w},{x:n+p/2,y:r+i/2},{x:n-p/2,y:r+i/2},{x:n-p/2,y:r-i/2+m.height+w},{x:n-m.width/2,y:r-i/2+m.height+w}]:[{x:n-p/2,y:r-i/2},{x:n+p/2,y:r-i/2},{x:n+p/2,y:r-i/2+g},{x:n+m.width/2,y:r-i/2+g},{x:n+m.width/2/2,y:r+i/2},{x:n-m.width/2,y:r+i/2},{x:n-m.width/2,y:r-i/2+g},{x:n-p/2,y:r-i/2+g}],V.polygon(e,a,t)},f}async function Ct(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(a.width+2*(e.padding??0),e?.width??0),o=Math.max(a.height+2*(e.padding??0),e?.height??0),l=[{x:0,y:0},{x:s,y:0},{x:s+3*o/6,y:-o},{x:-3*o/6,y:-o}];let u;const{cssStyles:f}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=g(l),a=t.path(r,n);u=i.insert((()=>a),":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),f&&u.attr("style",f)}else u=X(i,s,o,l);return r&&u.attr("style",r),e.width=s,e.height=o,d(e,u),e.intersect=function(t){return V.polygon(e,l,t)},i}async function At(t,e,n){const{labelStyles:r,nodeStyles:i}=S(e);e.labelStyle=r;const{shapeSvg:a,bbox:o}=await h(t,e,p(e)),l=Math.max(o.width+2*n.labelPaddingX,e?.width||0),u=Math.max(o.height+2*n.labelPaddingY,e?.height||0),g=-l/2,f=-u/2;let m,{rx:y,ry:v}=e;const{cssStyles:x}=e;if(n?.rx&&n.ry&&(y=n.rx,v=n.ry),"handDrawn"===e.look){const t=c.Z.svg(a),n=C(e,{}),r=y||v?t.path(w(g,f,l,u,y||0),n):t.rectangle(g,f,l,u,n);m=a.insert((()=>r),":first-child"),m.attr("class","basic label-container").attr("style",(0,s.R7)(x))}else m=a.insert("rect",":first-child"),m.attr("class","basic label-container").attr("style",i).attr("rx",(0,s.R7)(y)).attr("ry",(0,s.R7)(v)).attr("x",g).attr("y",f).attr("width",l).attr("height",u);return d(e,m),e.intersect=function(t){return V.rect(e,t)},a}async function Lt(t,e){const{shapeSvg:n,bbox:r,label:i}=await h(t,e,"label"),a=n.insert("rect",":first-child");return a.attr("width",.1).attr("height",.1),n.attr("class","label edgeLabel"),i.attr("transform",`translate(${-r.width/2-(r.x-(r.left??0))}, ${-r.height/2-(r.y-(r.top??0))})`),d(e,a),e.intersect=function(t){return V.rect(e,t)},n}async function Mt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(a.width+(e.padding??0),e?.width??0),o=Math.max(a.height+(e.padding??0),e?.height??0),l=[{x:0,y:0},{x:s+3*o/6,y:0},{x:s,y:-o},{x:-3*o/6,y:-o}];let u;const{cssStyles:f}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=g(l),a=t.path(r,n);u=i.insert((()=>a),":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),f&&u.attr("style",f)}else u=X(i,s,o,l);return r&&u.attr("style",r),e.width=s,e.height=o,d(e,u),e.intersect=function(t){return V.polygon(e,l,t)},i}async function Nt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(a.width+(e.padding??0),e?.width??0),o=Math.max(a.height+(e.padding??0),e?.height??0),l=[{x:-3*o/6,y:0},{x:s,y:0},{x:s+3*o/6,y:-o},{x:0,y:-o}];let u;const{cssStyles:f}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=g(l),a=t.path(r,n);u=i.insert((()=>a),":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),f&&u.attr("style",f)}else u=X(i,s,o,l);return r&&u.attr("style",r),e.width=s,e.height=o,d(e,u),e.intersect=function(t){return V.polygon(e,l,t)},i}function It(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.label="",e.labelStyle=n;const i=t.insert("g").attr("class",p(e)).attr("id",e.domId??e.id),{cssStyles:a}=e,s=Math.max(35,e?.width??0),l=Math.max(35,e?.height??0),h=[{x:s,y:0},{x:0,y:l+3.5},{x:s-14,y:l+3.5},{x:0,y:2*l},{x:s,y:l-3.5},{x:14,y:l-3.5}],u=c.Z.svg(i),f=C(e,{});"handDrawn"!==e.look&&(f.roughness=0,f.fillStyle="solid");const m=g(h),y=u.path(m,f),v=i.insert((()=>y),":first-child");return a&&"handDrawn"!==e.look&&v.selectAll("path").attr("style",a),r&&"handDrawn"!==e.look&&v.selectAll("path").attr("style",r),v.attr("transform",`translate(-${s/2},${-l})`),d(e,v),e.intersect=function(t){return o.cM.info("lightningBolt intersect",e,t),V.polygon(e,h,t)},i}(0,o.eW)(bt,"hexagon"),(0,o.eW)(wt,"hourglass"),(0,o.eW)(kt,"icon"),(0,o.eW)(Tt,"iconCircle"),(0,o.eW)(_t,"iconRounded"),(0,o.eW)(Et,"iconSquare"),(0,o.eW)(St,"imageSquare"),(0,o.eW)(Ct,"inv_trapezoid"),(0,o.eW)(At,"drawRect"),(0,o.eW)(Lt,"labelRect"),(0,o.eW)(Mt,"lean_left"),(0,o.eW)(Nt,"lean_right"),(0,o.eW)(It,"lightningBolt");var Rt=(0,o.eW)(((t,e,n,r,i,a,s)=>[`M${t},${e+a}`,`a${i},${a} 0,0,0 ${n},0`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,"l0,"+-r,`M${t},${e+a+s}`,`a${i},${a} 0,0,0 ${n},0`].join(" ")),"createCylinderPathD"),Dt=(0,o.eW)(((t,e,n,r,i,a,s)=>[`M${t},${e+a}`,`M${t+n},${e+a}`,`a${i},${a} 0,0,0 ${-n},0`,`l0,${r}`,`a${i},${a} 0,0,0 ${n},0`,"l0,"+-r,`M${t},${e+a+s}`,`a${i},${a} 0,0,0 ${n},0`].join(" ")),"createOuterCylinderPathD"),Ot=(0,o.eW)(((t,e,n,r,i,a)=>[`M${t-n/2},${-r/2}`,`a${i},${a} 0,0,0 ${n},0`].join(" ")),"createInnerCylinderPathD");async function Pt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:o}=await h(t,e,p(e)),l=Math.max(a.width+(e.padding??0),e.width??0),u=l/2,g=u/(2.5+l/50),f=Math.max(a.height+g+(e.padding??0),e.height??0),m=.1*f;let y;const{cssStyles:v}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=Dt(0,0,l,f,u,g,m),r=Ot(0,g,l,f,u,g),a=C(e,{}),s=t.path(n,a),o=t.path(r,a);i.insert((()=>o),":first-child").attr("class","line"),y=i.insert((()=>s),":first-child"),y.attr("class","basic label-container"),v&&y.attr("style",v)}else{const t=Rt(0,0,l,f,u,g,m);y=i.insert("path",":first-child").attr("d",t).attr("class","basic label-container").attr("style",(0,s.R7)(v)).attr("style",r)}return y.attr("label-offset-y",g),y.attr("transform",`translate(${-l/2}, ${-(f/2+g)})`),d(e,y),o.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${-a.height/2+g-(a.y-(a.top??0))})`),e.intersect=function(t){const n=V.rect(e,t),r=n.x-(e.x??0);if(0!=u&&(Math.abs(r)<(e.width??0)/2||Math.abs(r)==(e.width??0)/2&&Math.abs(n.y-(e.y??0))>(e.height??0)/2-g)){let i=g*g*(1-r*r/(u*u));i>0&&(i=Math.sqrt(i)),i=g-i,t.y-(e.y??0)>0&&(i=-i),n.y+=i}return n},i}async function $t(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=Math.max(a.width+2*(e.padding??0),e?.width??0),l=Math.max(a.height+2*(e.padding??0),e?.height??0),u=l/4,g=l+u,{cssStyles:m}=e,y=c.Z.svg(i),v=C(e,{});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=[{x:-o/2-o/2*.1,y:-g/2},{x:-o/2-o/2*.1,y:g/2},...f(-o/2-o/2*.1,g/2,o/2+o/2*.1,g/2,u,.8),{x:o/2+o/2*.1,y:-g/2},{x:-o/2-o/2*.1,y:-g/2},{x:-o/2,y:-g/2},{x:-o/2,y:g/2*1.1},{x:-o/2,y:-g/2}],b=y.polygon(x.map((t=>[t.x,t.y])),v),w=i.insert((()=>b),":first-child");return w.attr("class","basic label-container"),m&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",m),r&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",r),w.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-o/2+(e.padding??0)+o/2*.1/2-(a.x-(a.left??0))},${-l/2+(e.padding??0)-u/2-(a.y-(a.top??0))})`),d(e,w),e.intersect=function(t){return V.polygon(e,x,t)},i}async function Bt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=Math.max(a.width+2*(e.padding??0),e?.width??0),l=Math.max(a.height+2*(e.padding??0),e?.height??0),u=-o/2,f=-l/2,{cssStyles:m}=e,y=c.Z.svg(i),v=C(e,{}),x=[{x:u-5,y:f+5},{x:u-5,y:f+l+5},{x:u+o-5,y:f+l+5},{x:u+o-5,y:f+l},{x:u+o,y:f+l},{x:u+o,y:f+l-5},{x:u+o+5,y:f+l-5},{x:u+o+5,y:f-5},{x:u+5,y:f-5},{x:u+5,y:f},{x:u,y:f},{x:u,y:f+5}],b=[{x:u,y:f+5},{x:u+o-5,y:f+5},{x:u+o-5,y:f+l},{x:u+o,y:f+l},{x:u+o,y:f},{x:u,y:f}];"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const w=g(x),k=y.path(w,v),T=g(b),_=y.path(T,{...v,fill:"none"}),E=i.insert((()=>_),":first-child");return E.insert((()=>k),":first-child"),E.attr("class","basic label-container"),m&&"handDrawn"!==e.look&&E.selectAll("path").attr("style",m),r&&"handDrawn"!==e.look&&E.selectAll("path").attr("style",r),s.attr("transform",`translate(${-a.width/2-5-(a.x-(a.left??0))}, ${-a.height/2+5-(a.y-(a.top??0))})`),d(e,E),e.intersect=function(t){return V.polygon(e,x,t)},i}async function Ft(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=Math.max(a.width+2*(e.padding??0),e?.width??0),l=Math.max(a.height+2*(e.padding??0),e?.height??0),u=l/4,m=l+u,y=-o/2,v=-m/2,{cssStyles:x}=e,b=f(y-5,v+m+5,y+o-5,v+m+5,u,.8),w=b?.[b.length-1],k=[{x:y-5,y:v+5},{x:y-5,y:v+m+5},...b,{x:y+o-5,y:w.y-5},{x:y+o,y:w.y-5},{x:y+o,y:w.y-10},{x:y+o+5,y:w.y-10},{x:y+o+5,y:v-5},{x:y+5,y:v-5},{x:y+5,y:v},{x:y,y:v},{x:y,y:v+5}],T=[{x:y,y:v+5},{x:y+o-5,y:v+5},{x:y+o-5,y:w.y-5},{x:y+o,y:w.y-5},{x:y+o,y:v},{x:y,y:v}],_=c.Z.svg(i),E=C(e,{});"handDrawn"!==e.look&&(E.roughness=0,E.fillStyle="solid");const A=g(k),L=_.path(A,E),M=g(T),N=_.path(M,E),I=i.insert((()=>L),":first-child");return I.insert((()=>N)),I.attr("class","basic label-container"),x&&"handDrawn"!==e.look&&I.selectAll("path").attr("style",x),r&&"handDrawn"!==e.look&&I.selectAll("path").attr("style",r),I.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-a.width/2-5-(a.x-(a.left??0))}, ${-a.height/2+5-u/2-(a.y-(a.top??0))})`),d(e,I),e.intersect=function(t){return V.polygon(e,k,t)},i}async function Wt(t,e,{config:{themeVariables:n}}){const{labelStyles:r,nodeStyles:i}=S(e);e.labelStyle=r,e.useHtmlLabels||!1!==(0,o.iE)().flowchart?.htmlLabels||(e.centerLabel=!0);const{shapeSvg:a,bbox:s}=await h(t,e,p(e)),l=Math.max(s.width+2*(e.padding??0),e?.width??0),u=Math.max(s.height+2*(e.padding??0),e?.height??0),g=-l/2,f=-u/2,{cssStyles:m}=e,y=c.Z.svg(a),v=C(e,{fill:n.noteBkgColor,stroke:n.noteBorderColor});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=y.rectangle(g,f,l,u,v),b=a.insert((()=>x),":first-child");return b.attr("class","basic label-container"),m&&"handDrawn"!==e.look&&b.selectAll("path").attr("style",m),i&&"handDrawn"!==e.look&&b.selectAll("path").attr("style",i),d(e,b),e.intersect=function(t){return V.rect(e,t)},a}(0,o.eW)(Pt,"linedCylinder"),(0,o.eW)($t,"linedWaveEdgedRect"),(0,o.eW)(Bt,"multiRect"),(0,o.eW)(Ft,"multiWaveEdgedRectangle"),(0,o.eW)(Wt,"note");var zt=(0,o.eW)(((t,e,n)=>[`M${t+n/2},${e}`,`L${t+n},${e-n/2}`,`L${t+n/2},${e-n}`,`L${t},${e-n/2}`,"Z"].join(" ")),"createDecisionBoxPathD");async function Zt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=a.width+e.padding+(a.height+e.padding),l=[{x:s/2,y:0},{x:s,y:-s/2},{x:s/2,y:-s},{x:0,y:-s/2}];let u;const{cssStyles:g}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=zt(0,0,s),a=t.path(r,n);u=i.insert((()=>a),":first-child").attr("transform",`translate(${-s/2}, ${s/2})`),g&&u.attr("style",g)}else u=X(i,s,s,l);return r&&u.attr("style",r),d(e,u),e.intersect=function(t){return o.cM.debug("APA12 Intersect called SPLIT\npoint:",t,"\nnode:\n",e,"\nres:",V.polygon(e,l,t)),V.polygon(e,l,t)},i}async function Yt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=-Math.max(a.width+(e.padding??0),e?.width??0)/2,l=-Math.max(a.height+(e.padding??0),e?.height??0)/2,u=l/2,f=[{x:o+u,y:l},{x:o,y:0},{x:o+u,y:-l},{x:-o,y:-l},{x:-o,y:l}],{cssStyles:m}=e,y=c.Z.svg(i),v=C(e,{});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=g(f),b=y.path(x,v),w=i.insert((()=>b),":first-child");return w.attr("class","basic label-container"),m&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",m),r&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",r),w.attr("transform",`translate(${-u/2},0)`),s.attr("transform",`translate(${-u/2-a.width/2-(a.x-(a.left??0))}, ${-a.height/2-(a.y-(a.top??0))})`),d(e,w),e.intersect=function(t){return V.polygon(e,f,t)},i}async function Ut(t,e){const{labelStyles:n,nodeStyles:r}=S(e);let i;e.labelStyle=n,i=e.cssClasses?"node "+e.cssClasses:"node default";const a=t.insert("g").attr("class",i).attr("id",e.domId||e.id),s=a.insert("g"),h=a.insert("g").attr("class","label").attr("style",r),u=e.description,p=e.label,g=h.node().appendChild(await b(p,e.labelStyle,!0,!0));let f={width:0,height:0};if((0,o.ku)((0,o.nV)()?.flowchart?.htmlLabels)){const t=g.children[0],e=(0,l.Ys)(g);f=t.getBoundingClientRect(),e.attr("width",f.width),e.attr("height",f.height)}o.cM.info("Text 2",u);const m=u||[],y=g.getBBox(),v=h.node().appendChild(await b(m.join?m.join("
    "):m,e.labelStyle,!0,!0)),x=v.children[0],k=(0,l.Ys)(v);f=x.getBoundingClientRect(),k.attr("width",f.width),k.attr("height",f.height);const T=(e.padding||0)/2;(0,l.Ys)(v).attr("transform","translate( "+(f.width>y.width?0:(y.width-f.width)/2)+", "+(y.height+T+5)+")"),(0,l.Ys)(g).attr("transform","translate( "+(f.width(o.cM.debug("Rough node insert CXC",r),i)),":first-child"),M=a.insert((()=>(o.cM.debug("Rough node insert CXC",r),r)),":first-child")}else M=s.insert("rect",":first-child"),N=s.insert("line"),M.attr("class","outer title-state").attr("style",r).attr("x",-f.width/2-T).attr("y",-f.height/2-T).attr("width",f.width+(e.padding||0)).attr("height",f.height+(e.padding||0)),N.attr("class","divider").attr("x1",-f.width/2-T).attr("x2",f.width/2+T).attr("y1",-f.height/2-T+y.height+T).attr("y2",-f.height/2-T+y.height+T);return d(e,M),e.intersect=function(t){return V.rect(e,t)},a}async function Gt(t,e){return At(t,e,{rx:5,ry:5,classes:"",labelPaddingX:1*(e?.padding||0),labelPaddingY:1*(e?.padding||0)})}async function Vt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:o}=await h(t,e,p(e)),l=e?.padding??0,u=Math.max(a.width+2*(e.padding??0),e?.width??0),g=Math.max(a.height+2*(e.padding??0),e?.height??0),f=-a.width/2-l,m=-a.height/2-l,{cssStyles:y}=e,v=c.Z.svg(i),x=C(e,{});"handDrawn"!==e.look&&(x.roughness=0,x.fillStyle="solid");const b=[{x:f,y:m},{x:f+u+8,y:m},{x:f+u+8,y:m+g},{x:f-8,y:m+g},{x:f-8,y:m},{x:f,y:m},{x:f,y:m+g}],w=v.polygon(b.map((t=>[t.x,t.y])),x),k=i.insert((()=>w),":first-child");return k.attr("class","basic label-container").attr("style",(0,s.R7)(y)),r&&"handDrawn"!==e.look&&k.selectAll("path").attr("style",r),y&&"handDrawn"!==e.look&&k.selectAll("path").attr("style",r),o.attr("transform",`translate(${-u/2+4+(e.padding??0)-(a.x-(a.left??0))},${-g/2+(e.padding??0)-(a.y-(a.top??0))})`),d(e,k),e.intersect=function(t){return V.rect(e,t)},i}async function qt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=Math.max(a.width+2*(e.padding??0),e?.width??0),l=Math.max(a.height+2*(e.padding??0),e?.height??0),u=-o/2,f=-l/2,{cssStyles:m}=e,y=c.Z.svg(i),v=C(e,{});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=[{x:u,y:f},{x:u,y:f+l},{x:u+o,y:f+l},{x:u+o,y:f-l/2}],b=g(x),w=y.path(b,v),k=i.insert((()=>w),":first-child");return k.attr("class","basic label-container"),m&&"handDrawn"!==e.look&&k.selectChildren("path").attr("style",m),r&&"handDrawn"!==e.look&&k.selectChildren("path").attr("style",r),k.attr("transform",`translate(0, ${l/4})`),s.attr("transform",`translate(${-o/2+(e.padding??0)-(a.x-(a.left??0))}, ${-l/4+(e.padding??0)-(a.y-(a.top??0))})`),d(e,k),e.intersect=function(t){return V.polygon(e,x,t)},i}async function jt(t,e){return At(t,e,{rx:0,ry:0,classes:"",labelPaddingX:2*(e?.padding||0),labelPaddingY:1*(e?.padding||0)})}async function Ht(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),o=a.height+e.padding,l=a.width+o/4+e.padding;let u;const{cssStyles:g}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=w(-l/2,-o/2,l,o,o/2),a=t.path(r,n);u=i.insert((()=>a),":first-child"),u.attr("class","basic label-container").attr("style",(0,s.R7)(g))}else u=i.insert("rect",":first-child"),u.attr("class","basic label-container").attr("style",r).attr("rx",o/2).attr("ry",o/2).attr("x",-l/2).attr("y",-o/2).attr("width",l).attr("height",o);return d(e,u),e.intersect=function(t){return V.rect(e,t)},i}async function Xt(t,e){return At(t,e,{rx:5,ry:5,classes:"flowchart-node"})}function Kt(t,e,{config:{themeVariables:n}}){const{labelStyles:r,nodeStyles:i}=S(e);e.labelStyle=r;const{cssStyles:a}=e,{lineColor:s,stateBorder:o,nodeBorder:l}=n,h=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),u=c.Z.svg(h),p=C(e,{});"handDrawn"!==e.look&&(p.roughness=0,p.fillStyle="solid");const g=u.circle(0,0,14,{...p,stroke:s,strokeWidth:2}),f=o??l,m=u.circle(0,0,5,{...p,fill:f,stroke:f,strokeWidth:2,fillStyle:"solid"}),y=h.insert((()=>g),":first-child");return y.insert((()=>m)),a&&y.selectAll("path").attr("style",a),i&&y.selectAll("path").attr("style",i),d(e,y),e.intersect=function(t){return V.circle(e,7,t)},h}function Qt(t,e,{config:{themeVariables:n}}){const{lineColor:r}=n,i=t.insert("g").attr("class","node default").attr("id",e.domId||e.id);let a;if("handDrawn"===e.look){const t=c.Z.svg(i).circle(0,0,14,k(r));a=i.insert((()=>t)),a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14)}else a=i.insert("circle",":first-child"),a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14);return d(e,a),e.intersect=function(t){return V.circle(e,7,t)},i}async function Jt(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),o=(e?.padding||0)/2,l=a.width+e.padding,u=a.height+e.padding,g=-a.width/2-o,f=-a.height/2-o,m=[{x:0,y:0},{x:l,y:0},{x:l,y:-u},{x:0,y:-u},{x:0,y:0},{x:-8,y:0},{x:l+8,y:0},{x:l+8,y:-u},{x:-8,y:-u},{x:-8,y:0}];if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=t.rectangle(g-8,f,l+16,u,n),a=t.line(g,f,g,f+u,n),o=t.line(g+l,f,g+l,f+u,n);i.insert((()=>a),":first-child"),i.insert((()=>o),":first-child");const h=i.insert((()=>r),":first-child"),{cssStyles:p}=e;h.attr("class","basic label-container").attr("style",(0,s.R7)(p)),d(e,h)}else{const t=X(i,l,u,m);r&&t.attr("style",r),d(e,t)}return e.intersect=function(t){return V.polygon(e,m,t)},i}async function te(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(a.width+2*(e.padding??0),e?.width??0),o=Math.max(a.height+2*(e.padding??0),e?.height??0),l=-s/2,u=-o/2,f=.2*o,m=.2*o,{cssStyles:y}=e,v=c.Z.svg(i),x=C(e,{}),b=[{x:l-f/2,y:u},{x:l+s+f/2,y:u},{x:l+s+f/2,y:u+o},{x:l-f/2,y:u+o}],w=[{x:l+s-f/2,y:u+o},{x:l+s+f/2,y:u+o},{x:l+s+f/2,y:u+o-m}];"handDrawn"!==e.look&&(x.roughness=0,x.fillStyle="solid");const k=g(b),T=v.path(k,x),_=g(w),E=v.path(_,{...x,fillStyle:"solid"}),A=i.insert((()=>E),":first-child");return A.insert((()=>T),":first-child"),A.attr("class","basic label-container"),y&&"handDrawn"!==e.look&&A.selectAll("path").attr("style",y),r&&"handDrawn"!==e.look&&A.selectAll("path").attr("style",r),d(e,A),e.intersect=function(t){return V.polygon(e,b,t)},i}async function ee(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=Math.max(a.width+2*(e.padding??0),e?.width??0),l=Math.max(a.height+2*(e.padding??0),e?.height??0),u=l/4,m=.2*o,y=.2*l,v=l+u,{cssStyles:x}=e,b=c.Z.svg(i),w=C(e,{});"handDrawn"!==e.look&&(w.roughness=0,w.fillStyle="solid");const k=[{x:-o/2-o/2*.1,y:v/2},...f(-o/2-o/2*.1,v/2,o/2+o/2*.1,v/2,u,.8),{x:o/2+o/2*.1,y:-v/2},{x:-o/2-o/2*.1,y:-v/2}],T=-o/2+o/2*.1,_=-v/2-.4*y,E=[{x:T+o-m,y:1.4*(_+l)},{x:T+o,y:_+l-y},{x:T+o,y:.9*(_+l)},...f(T+o,1.3*(_+l),T+o-m,1.5*(_+l),.03*-l,.5)],A=g(k),L=b.path(A,w),M=g(E),N=b.path(M,{...w,fillStyle:"solid"}),I=i.insert((()=>N),":first-child");return I.insert((()=>L),":first-child"),I.attr("class","basic label-container"),x&&"handDrawn"!==e.look&&I.selectAll("path").attr("style",x),r&&"handDrawn"!==e.look&&I.selectAll("path").attr("style",r),I.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-o/2+(e.padding??0)-(a.x-(a.left??0))},${-l/2+(e.padding??0)-u/2-(a.y-(a.top??0))})`),d(e,I),e.intersect=function(t){return V.polygon(e,k,t)},i}async function ne(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(a.width+e.padding,e?.width||0),o=Math.max(a.height+e.padding,e?.height||0),l=-s/2,c=-o/2,u=i.insert("rect",":first-child");return u.attr("class","text").attr("style",r).attr("rx",0).attr("ry",0).attr("x",l).attr("y",c).attr("width",s).attr("height",o),d(e,u),e.intersect=function(t){return V.rect(e,t)},i}(0,o.eW)(Zt,"question"),(0,o.eW)(Yt,"rect_left_inv_arrow"),(0,o.eW)(Ut,"rectWithTitle"),(0,o.eW)(Gt,"roundedRect"),(0,o.eW)(Vt,"shadedProcess"),(0,o.eW)(qt,"slopedRect"),(0,o.eW)(jt,"squareRect"),(0,o.eW)(Ht,"stadium"),(0,o.eW)(Xt,"state"),(0,o.eW)(Kt,"stateEnd"),(0,o.eW)(Qt,"stateStart"),(0,o.eW)(Jt,"subroutine"),(0,o.eW)(te,"taggedRect"),(0,o.eW)(ee,"taggedWaveEdgedRectangle"),(0,o.eW)(ne,"text");var re=(0,o.eW)(((t,e,n,r,i,a)=>`M${t},${e}\n a${i},${a} 0,0,1 0,${-r}\n l${n},0\n a${i},${a} 0,0,1 0,${r}\n M${n},${-r}\n a${i},${a} 0,0,0 0,${r}\n l${-n},0`),"createCylinderPathD"),ie=(0,o.eW)(((t,e,n,r,i,a)=>[`M${t},${e}`,`M${t+n},${e}`,`a${i},${a} 0,0,0 0,${-r}`,`l${-n},0`,`a${i},${a} 0,0,0 0,${r}`,`l${n},0`].join(" ")),"createOuterCylinderPathD"),ae=(0,o.eW)(((t,e,n,r,i,a)=>[`M${t+n/2},${-r/2}`,`a${i},${a} 0,0,0 0,${r}`].join(" ")),"createInnerCylinderPathD");async function se(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:o,halfPadding:l}=await h(t,e,p(e)),u="neo"===e.look?2*l:l,g=a.height+u,f=g/2,m=f/(2.5+g/50),y=a.width+m+u,{cssStyles:v}=e;let x;if("handDrawn"===e.look){const t=c.Z.svg(i),n=ie(0,0,y,g,m,f),r=ae(0,0,y,g,m,f),a=t.path(n,C(e,{})),s=t.path(r,C(e,{fill:"none"}));x=i.insert((()=>s),":first-child"),x=i.insert((()=>a),":first-child"),x.attr("class","basic label-container"),v&&x.attr("style",v)}else{const t=re(0,0,y,g,m,f);x=i.insert("path",":first-child").attr("d",t).attr("class","basic label-container").attr("style",(0,s.R7)(v)).attr("style",r),x.attr("class","basic label-container"),v&&x.selectAll("path").attr("style",v),r&&x.selectAll("path").attr("style",r)}return x.attr("label-offset-x",m),x.attr("transform",`translate(${-y/2}, ${g/2} )`),o.attr("transform",`translate(${-a.width/2-m-(a.x-(a.left??0))}, ${-a.height/2-(a.y-(a.top??0))})`),d(e,x),e.intersect=function(t){const n=V.rect(e,t),r=n.y-(e.y??0);if(0!=f&&(Math.abs(r)<(e.height??0)/2||Math.abs(r)==(e.height??0)/2&&Math.abs(n.x-(e.x??0))>(e.width??0)/2-m)){let i=m*m*(1-r*r/(f*f));0!=i&&(i=Math.sqrt(Math.abs(i))),i=m-i,t.x-(e.x??0)>0&&(i=-i),n.x+=i}return n},i}async function oe(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=a.width+e.padding,o=a.height+e.padding,l=[{x:-3*o/6,y:0},{x:s+3*o/6,y:0},{x:s,y:-o},{x:0,y:-o}];let u;const{cssStyles:f}=e;if("handDrawn"===e.look){const t=c.Z.svg(i),n=C(e,{}),r=g(l),a=t.path(r,n);u=i.insert((()=>a),":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),f&&u.attr("style",f)}else u=X(i,s,o,l);return r&&u.attr("style",r),e.width=s,e.height=o,d(e,u),e.intersect=function(t){return V.polygon(e,l,t)},i}async function le(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(60,a.width+2*(e.padding??0),e?.width??0),o=Math.max(20,a.height+2*(e.padding??0),e?.height??0),{cssStyles:l}=e,u=c.Z.svg(i),f=C(e,{});"handDrawn"!==e.look&&(f.roughness=0,f.fillStyle="solid");const m=[{x:-s/2*.8,y:-o/2},{x:s/2*.8,y:-o/2},{x:s/2,y:-o/2*.6},{x:s/2,y:o/2},{x:-s/2,y:o/2},{x:-s/2,y:-o/2*.6}],y=g(m),v=u.path(y,f),x=i.insert((()=>v),":first-child");return x.attr("class","basic label-container"),l&&"handDrawn"!==e.look&&x.selectChildren("path").attr("style",l),r&&"handDrawn"!==e.look&&x.selectChildren("path").attr("style",r),d(e,x),e.intersect=function(t){return V.polygon(e,m,t)},i}async function ce(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),l=(0,o.ku)((0,o.nV)().flowchart?.htmlLabels),u=a.width+(e.padding??0),f=u+a.height,m=u+a.height,y=[{x:0,y:0},{x:m,y:0},{x:m/2,y:-f}],{cssStyles:v}=e,x=c.Z.svg(i),b=C(e,{});"handDrawn"!==e.look&&(b.roughness=0,b.fillStyle="solid");const w=g(y),k=x.path(w,b),T=i.insert((()=>k),":first-child").attr("transform",`translate(${-f/2}, ${f/2})`);return v&&"handDrawn"!==e.look&&T.selectChildren("path").attr("style",v),r&&"handDrawn"!==e.look&&T.selectChildren("path").attr("style",r),e.width=u,e.height=f,d(e,T),s.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${f/2-(a.height+(e.padding??0)/(l?2:1)-(a.y-(a.top??0)))})`),e.intersect=function(t){return o.cM.info("Triangle intersect",e,y,t),V.polygon(e,y,t)},i}async function he(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=Math.max(a.width+2*(e.padding??0),e?.width??0),l=Math.max(a.height+2*(e.padding??0),e?.height??0),u=l/8,m=l+u,{cssStyles:y}=e,v=70-o,x=v>0?v/2:0,b=c.Z.svg(i),w=C(e,{});"handDrawn"!==e.look&&(w.roughness=0,w.fillStyle="solid");const k=[{x:-o/2-x,y:m/2},...f(-o/2-x,m/2,o/2+x,m/2,u,.8),{x:o/2+x,y:-m/2},{x:-o/2-x,y:-m/2}],T=g(k),_=b.path(T,w),E=i.insert((()=>_),":first-child");return E.attr("class","basic label-container"),y&&"handDrawn"!==e.look&&E.selectAll("path").attr("style",y),r&&"handDrawn"!==e.look&&E.selectAll("path").attr("style",r),E.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-o/2+(e.padding??0)-(a.x-(a.left??0))},${-l/2+(e.padding??0)-u-(a.y-(a.top??0))})`),d(e,E),e.intersect=function(t){return V.polygon(e,k,t)},i}async function ue(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a}=await h(t,e,p(e)),s=Math.max(a.width+2*(e.padding??0),e?.width??0),o=Math.max(a.height+2*(e.padding??0),e?.height??0),l=s/o;let u=s,m=o;u>m*l?m=u/l:u=m*l,u=Math.max(u,100),m=Math.max(m,50);const y=Math.min(.2*m,m/4),v=m+2*y,{cssStyles:x}=e,b=c.Z.svg(i),w=C(e,{});"handDrawn"!==e.look&&(w.roughness=0,w.fillStyle="solid");const k=[{x:-u/2,y:v/2},...f(-u/2,v/2,u/2,v/2,y,1),{x:u/2,y:-v/2},...f(u/2,-v/2,-u/2,-v/2,y,-1)],T=g(k),_=b.path(T,w),E=i.insert((()=>_),":first-child");return E.attr("class","basic label-container"),x&&"handDrawn"!==e.look&&E.selectAll("path").attr("style",x),r&&"handDrawn"!==e.look&&E.selectAll("path").attr("style",r),d(e,E),e.intersect=function(t){return V.polygon(e,k,t)},i}async function de(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const{shapeSvg:i,bbox:a,label:s}=await h(t,e,p(e)),o=Math.max(a.width+2*(e.padding??0),e?.width??0),l=Math.max(a.height+2*(e.padding??0),e?.height??0),u=-o/2,g=-l/2,{cssStyles:f}=e,m=c.Z.svg(i),y=C(e,{}),v=[{x:u-5,y:g-5},{x:u-5,y:g+l},{x:u+o,y:g+l},{x:u+o,y:g-5}],x=`M${u-5},${g-5} L${u+o},${g-5} L${u+o},${g+l} L${u-5},${g+l} L${u-5},${g-5}\n M${u-5},${g} L${u+o},${g}\n M${u},${g-5} L${u},${g+l}`;"handDrawn"!==e.look&&(y.roughness=0,y.fillStyle="solid");const b=m.path(x,y),w=i.insert((()=>b),":first-child");return w.attr("transform","translate(2.5, 2.5)"),w.attr("class","basic label-container"),f&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",f),r&&"handDrawn"!==e.look&&w.selectAll("path").attr("style",r),s.attr("transform",`translate(${-a.width/2+2.5-(a.x-(a.left??0))}, ${-a.height/2+2.5-(a.y-(a.top??0))})`),d(e,w),e.intersect=function(t){return V.polygon(e,v,t)},i}async function pe(t,e){const n=e;if(n.alias&&(e.label=n.alias),"handDrawn"===e.look){const{themeVariables:n}=(0,o.iE)(),{background:r}=n,i={...e,id:e.id+"-background",look:"default",cssStyles:["stroke: none",`fill: ${r}`]};await pe(t,i)}const r=(0,o.iE)();e.useHtmlLabels=r.htmlLabels;let i=r.er?.diagramPadding??10,a=r.er?.entityPadding??6;const{cssStyles:h}=e,{labelStyles:u}=S(e);if(0===n.attributes.length&&e.label){const n={rx:0,ry:0,labelPaddingX:i,labelPaddingY:1.5*i,classes:""};(0,s.Cq)(e.label,r)+2*n.labelPaddingX0){const t=m.width+2*i-(x+b+w+k);x+=t/E,b+=t/E,w>0&&(w+=t/E),k>0&&(k+=t/E)}const L=x+b+w+k,M=c.Z.svg(f),N=C(e,{});"handDrawn"!==e.look&&(N.roughness=0,N.fillStyle="solid");const I=Math.max(A.width+2*i,e?.width||0,L),R=Math.max(A.height+(v[0]||y)+a,e?.height||0),D=-I/2,O=-R/2;f.selectAll("g:not(:first-child)").each(((t,e,n)=>{const r=(0,l.Ys)(n[e]),s=r.attr("transform");let o=0,c=0;if(s){const t=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(s);t&&(o=parseFloat(t[1]),c=parseFloat(t[2]),r.attr("class").includes("attribute-name")?o+=x:r.attr("class").includes("attribute-keys")?o+=x+b:r.attr("class").includes("attribute-comment")&&(o+=x+b+w))}r.attr("transform",`translate(${D+i/2+o}, ${c+O+m.height+a/2})`)})),f.select(".name").attr("transform","translate("+-m.width/2+", "+(O+a/2)+")");const P=M.rectangle(D,O,I,R,N),$=f.insert((()=>P),":first-child").attr("style",h.join("")),{themeVariables:B}=(0,o.iE)(),{rowEven:F,rowOdd:W,nodeBorder:z}=B;v.push(0);for(const[t,e]of v.entries()){if(0===t&&v.length>1)continue;const n=t%2==0&&0!==e,r=M.rectangle(D,m.height+O+e,I,m.height,{...N,fill:n?F:W,stroke:z});f.insert((()=>r),"g.label").attr("style",h.join("")).attr("class","row-rect-"+(t%2==0?"even":"odd"))}let Z=M.line(D,m.height+O,I+D,m.height+O,N);f.insert((()=>Z)).attr("class","divider"),Z=M.line(x+D,m.height+O,x+D,R+O,N),f.insert((()=>Z)).attr("class","divider"),T&&(Z=M.line(x+b+D,m.height+O,x+b+D,R+O,N),f.insert((()=>Z)).attr("class","divider")),_&&(Z=M.line(x+b+w+D,m.height+O,x+b+w+D,R+O,N),f.insert((()=>Z)).attr("class","divider"));for(const t of v)Z=M.line(D,m.height+O+t,I+D,m.height+O+t,N),f.insert((()=>Z)).attr("class","divider");return d(e,$),e.intersect=function(t){return V.rect(e,t)},f}async function ge(t,e,n,r=0,i=0,c=[],h=""){const u=t.insert("g").attr("class",`label ${c.join(" ")}`).attr("transform",`translate(${r}, ${i})`).attr("style",h);e!==(0,o.UO)(e)&&(e=(e=(0,o.UO)(e)).replaceAll("<","<").replaceAll(">",">"));const d=u.node().appendChild(await(0,a.rw)(u,e,{width:(0,s.Cq)(e,n)+100,style:h,useHtmlLabels:n.htmlLabels},n));if(e.includes("<")||e.includes(">")){let t=d.children[0];for(t.textContent=t.textContent.replaceAll("<","<").replaceAll(">",">");t.childNodes[0];)t=t.childNodes[0],t.textContent=t.textContent.replaceAll("<","<").replaceAll(">",">")}let p=d.getBBox();if((0,o.ku)(n.htmlLabels)){const t=d.children[0];t.style.textAlign="start";const e=(0,l.Ys)(d);p=t.getBoundingClientRect(),e.attr("width",p.width),e.attr("height",p.height)}return p}async function fe(t,e,n,r,i=n.class.padding??12){const a=r?0:3,s=t.insert("g").attr("class",p(e)).attr("id",e.domId||e.id);let o=null,l=null,c=null,h=null,u=0,d=0,g=0;if(o=s.insert("g").attr("class","annotation-group text"),e.annotations.length>0){const t=e.annotations[0];await me(o,{text:`«${t}»`},0),u=o.node().getBBox().height}l=s.insert("g").attr("class","label-group text"),await me(l,e,0,["font-weight: bolder"]);const f=l.node().getBBox();d=f.height,c=s.insert("g").attr("class","members-group text");let m=0;for(const t of e.members)m+=await me(c,t,m,[t.parseClassifier()])+a;g=c.node().getBBox().height,g<=0&&(g=i/2),h=s.insert("g").attr("class","methods-group text");let y=0;for(const t of e.methods)y+=await me(h,t,y,[t.parseClassifier()])+a;let v=s.node().getBBox();if(null!==o){const t=o.node().getBBox();o.attr("transform",`translate(${-t.width/2})`)}return l.attr("transform",`translate(${-f.width/2}, ${u})`),v=s.node().getBBox(),c.attr("transform",`translate(0, ${u+d+2*i})`),v=s.node().getBBox(),h.attr("transform",`translate(0, ${u+d+(g?g+4*i:2*i)})`),v=s.node().getBBox(),{shapeSvg:s,bbox:v}}async function me(t,e,n,r=[]){const i=t.insert("g").attr("class","label").attr("style",r.join("; ")),c=(0,o.iE)();let h="useHtmlLabels"in e?e.useHtmlLabels:(0,o.ku)(c.htmlLabels)??!0,u="";u="text"in e?e.text:e.label,!h&&u.startsWith("\\")&&(u=u.substring(1)),(0,o.l0)(u)&&(h=!0);const d=await(0,a.rw)(i,(0,o.uX)((0,s.SH)(u)),{width:(0,s.Cq)(u,c)+50,classes:"markdown-node-label",useHtmlLabels:h},c);let p,g=1;if(h){const t=d.children[0],e=(0,l.Ys)(d);g=t.innerHTML.split("
    ").length,t.innerHTML.includes("")&&(g+=t.innerHTML.split("").length-1);const n=t.getElementsByTagName("img");if(n){const t=""===u.replace(/]*>/g,"").trim();await Promise.all([...n].map((e=>new Promise((n=>{function r(){if(e.style.display="flex",e.style.flexDirection="column",t){const t=c.fontSize?.toString()??window.getComputedStyle(document.body).fontSize,n=5,r=parseInt(t,10)*n+"px";e.style.minWidth=r,e.style.maxWidth=r}else e.style.width="100%";n(e)}(0,o.eW)(r,"setupImage"),setTimeout((()=>{e.complete&&r()})),e.addEventListener("error",r),e.addEventListener("load",r)})))))}p=t.getBoundingClientRect(),e.attr("width",p.width),e.attr("height",p.height)}else{r.includes("font-weight: bolder")&&(0,l.Ys)(d).selectAll("tspan").attr("font-weight",""),g=d.children.length;const t=d.children[0];(""===d.textContent||d.textContent.includes(">"))&&(t.textContent=u[0]+u.substring(1).replaceAll(">",">").replaceAll("<","<").trim()," "===u[1]&&(t.textContent=t.textContent[0]+" "+t.textContent.substring(1))),"undefined"===t.textContent&&(t.textContent=""),p=d.getBBox()}return i.attr("transform","translate(0,"+(-p.height/(2*g)+n)+")"),p.height}async function ye(t,e){const n=(0,o.nV)(),r=n.class.padding??12,i=r,a=e.useHtmlLabels??(0,o.ku)(n.htmlLabels)??!0,s=e;s.annotations=s.annotations??[],s.members=s.members??[],s.methods=s.methods??[];const{shapeSvg:h,bbox:u}=await fe(t,e,n,a,i),{labelStyles:p,nodeStyles:g}=S(e);e.labelStyle=p,e.cssStyles=s.styles||"";const f=s.styles?.join(";")||g||"";e.cssStyles||(e.cssStyles=f.replaceAll("!important","").split(";"));const m=0===s.members.length&&0===s.methods.length&&!n.class?.hideEmptyMembersBox,y=c.Z.svg(h),v=C(e,{});"handDrawn"!==e.look&&(v.roughness=0,v.fillStyle="solid");const x=u.width;let b=u.height;0===s.members.length&&0===s.methods.length?b+=i:s.members.length>0&&0===s.methods.length&&(b+=2*i);const w=-x/2,k=-b/2,T=y.rectangle(w-r,k-r-(m?r:0===s.members.length&&0===s.methods.length?-r/2:0),x+2*r,b+2*r+(m?2*r:0===s.members.length&&0===s.methods.length?-r:0),v),_=h.insert((()=>T),":first-child");_.attr("class","basic label-container");const E=_.node().getBBox();h.selectAll(".text").each(((t,e,n)=>{const i=(0,l.Ys)(n[e]),o=i.attr("transform");let c=0;if(o){const t=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(o);t&&(c=parseFloat(t[2]))}let u=c+k+r-(m?r:0===s.members.length&&0===s.methods.length?-r/2:0);a||(u-=4);let d=w;(i.attr("class").includes("label-group")||i.attr("class").includes("annotation-group"))&&(d=-i.node()?.getBBox().width/2||0,h.selectAll("text").each((function(t,e,n){"middle"===window.getComputedStyle(n[e]).textAnchor&&(d=0)}))),i.attr("transform",`translate(${d}, ${u})`)}));const A=h.select(".annotation-group").node().getBBox().height-(m?r/2:0)||0,L=h.select(".label-group").node().getBBox().height-(m?r/2:0)||0,M=h.select(".members-group").node().getBBox().height-(m?r/2:0)||0;if(s.members.length>0||s.methods.length>0||m){const t=y.line(E.x,A+L+k+r,E.x+E.width,A+L+k+r,v);h.insert((()=>t)).attr("class","divider").attr("style",f)}if(m||s.members.length>0||s.methods.length>0){const t=y.line(E.x,A+L+M+k+2*i+r,E.x+E.width,A+L+M+k+r+2*i,v);h.insert((()=>t)).attr("class","divider").attr("style",f)}if("handDrawn"!==s.look&&h.selectAll("path").attr("style",f),_.select(":nth-child(2)").attr("style",f),h.selectAll(".divider").select("path").attr("style",f),e.labelStyle?h.selectAll("span").attr("style",e.labelStyle):h.selectAll("span").attr("style",f),!a){const t=RegExp(/color\s*:\s*([^;]*)/),e=t.exec(f);if(e){const t=e[0].replace("color","fill");h.selectAll("tspan").attr("style",t)}else if(p){const e=t.exec(p);if(e){const t=e[0].replace("color","fill");h.selectAll("tspan").attr("style",t)}}}return d(e,_),e.intersect=function(t){return V.rect(e,t)},h}async function ve(t,e){const{labelStyles:n,nodeStyles:r}=S(e);e.labelStyle=n;const i=e,a=e,s="verifyMethod"in e,o=p(e),h=t.insert("g").attr("class",o).attr("id",e.domId??e.id);let u;u=s?await xe(h,`<<${i.type}>>`,0,e.labelStyle):await xe(h,"<<Element>>",0,e.labelStyle);let g=u;const f=await xe(h,i.name,g,e.labelStyle+"; font-weight: bold;");g+=f+20,s?(g+=await xe(h,i.requirementId?`Id: ${i.requirementId}`:"",g,e.labelStyle),g+=await xe(h,i.text?`Text: ${i.text}`:"",g,e.labelStyle),g+=await xe(h,i.risk?`Risk: ${i.risk}`:"",g,e.labelStyle),await xe(h,i.verifyMethod?`Verification: ${i.verifyMethod}`:"",g,e.labelStyle)):(g+=await xe(h,a.type?`Type: ${a.type}`:"",g,e.labelStyle),await xe(h,a.docRef?`Doc Ref: ${a.docRef}`:"",g,e.labelStyle));const m=(h.node()?.getBBox().width??200)+20,y=(h.node()?.getBBox().height??200)+20,v=-m/2,x=-y/2,b=c.Z.svg(h),w=C(e,{});"handDrawn"!==e.look&&(w.roughness=0,w.fillStyle="solid");const k=b.rectangle(v,x,m,y,w),T=h.insert((()=>k),":first-child");if(T.attr("class","basic label-container").attr("style",r),h.selectAll(".label").each(((t,e,n)=>{const r=(0,l.Ys)(n[e]),i=r.attr("transform");let a=0,s=0;if(i){const t=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(i);t&&(a=parseFloat(t[1]),s=parseFloat(t[2]))}const o=s-y/2;let c=v+10;0!==e&&1!==e||(c=a),r.attr("transform",`translate(${c}, ${o+20})`)})),g>u+f+20){const t=b.line(v,x+u+f+20,v+m,x+u+f+20,w);h.insert((()=>t)).attr("style",r)}return d(e,T),e.intersect=function(t){return V.rect(e,t)},h}async function xe(t,e,n,r=""){if(""===e)return 0;const i=t.insert("g").attr("class","label").attr("style",r),c=(0,o.nV)(),h=c.htmlLabels??!0,u=await(0,a.rw)(i,(0,o.uX)((0,s.SH)(e)),{width:(0,s.Cq)(e,c)+50,classes:"markdown-node-label",useHtmlLabels:h,style:r},c);let d;if(h){const t=u.children[0],e=(0,l.Ys)(u);d=t.getBoundingClientRect(),e.attr("width",d.width),e.attr("height",d.height)}else{const t=u.children[0];for(const e of t.children)e.textContent=e.textContent.replaceAll(">",">").replaceAll("<","<"),r&&e.setAttribute("style",r);d=u.getBBox(),d.height+=6}return i.attr("transform",`translate(${-d.width/2},${-d.height/2+n})`),d.height}(0,o.eW)(se,"tiltedCylinder"),(0,o.eW)(oe,"trapezoid"),(0,o.eW)(le,"trapezoidalPentagon"),(0,o.eW)(ce,"triangle"),(0,o.eW)(he,"waveEdgedRectangle"),(0,o.eW)(ue,"waveRectangle"),(0,o.eW)(de,"windowPane"),(0,o.eW)(pe,"erBox"),(0,o.eW)(ge,"addText"),(0,o.eW)(fe,"textHelper"),(0,o.eW)(me,"addText"),(0,o.eW)(ye,"classBox"),(0,o.eW)(ve,"requirementBox"),(0,o.eW)(xe,"addText");var be=(0,o.eW)((t=>{switch(t){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}}),"colorFromPriority");async function we(t,e,{config:n}){const{labelStyles:r,nodeStyles:i}=S(e);e.labelStyle=r||"";const a=e.width;e.width=(e.width??200)-10;const{shapeSvg:s,bbox:o,label:l}=await h(t,e,p(e)),g=e.padding||10;let f,m="";"ticket"in e&&e.ticket&&n?.kanban?.ticketBaseUrl&&(m=n?.kanban?.ticketBaseUrl.replace("#TICKET#",e.ticket),f=s.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",m).attr("target","_blank"));const y={useHtmlLabels:e.useHtmlLabels,labelStyle:e.labelStyle||"",width:e.width,img:e.img,padding:e.padding||8,centerLabel:!1};let v,x;({label:v,bbox:x}=f?await u(f,"ticket"in e&&e.ticket||"",y):await u(s,"ticket"in e&&e.ticket||"",y));const{label:b,bbox:k}=await u(s,"assigned"in e&&e.assigned||"",y);e.width=a;const T=e?.width||0,_=Math.max(x.height,k.height)/2,E=Math.max(o.height+20,e?.height||0)+_,A=-T/2,L=-E/2;let M;l.attr("transform","translate("+(g-T/2)+", "+(-_-o.height/2)+")"),v.attr("transform","translate("+(g-T/2)+", "+(-_+o.height/2)+")"),b.attr("transform","translate("+(g+T/2-k.width-20)+", "+(-_+o.height/2)+")");const{rx:N,ry:I}=e,{cssStyles:R}=e;if("handDrawn"===e.look){const t=c.Z.svg(s),n=C(e,{}),r=N||I?t.path(w(A,L,T,E,N||0),n):t.rectangle(A,L,T,E,n);M=s.insert((()=>r),":first-child"),M.attr("class","basic label-container").attr("style",R||null)}else{M=s.insert("rect",":first-child"),M.attr("class","basic label-container __APA__").attr("style",i).attr("rx",N??5).attr("ry",I??5).attr("x",A).attr("y",L).attr("width",T).attr("height",E);const t="priority"in e&&e.priority;if(t){const e=s.append("line"),n=A+2,r=L+Math.floor((N??0)/2),i=L+E-Math.floor((N??0)/2);e.attr("x1",n).attr("y1",r).attr("x2",n).attr("y2",i).attr("stroke-width","4").attr("stroke",be(t))}}return d(e,M),e.height=E,e.intersect=function(t){return V.rect(e,t)},s}(0,o.eW)(we,"kanbanItem");var ke=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:jt},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:Gt},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:Ht},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:Jt},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:dt},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:J},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:Zt},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:bt},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:Nt},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:Mt},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:oe},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:Ct},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:gt},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:ne},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:K},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:Vt},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:Qt},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:Kt},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:yt},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:wt},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:rt},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:at},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:ot},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:It},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:he},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:vt},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:se},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:Pt},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:lt},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:pt},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:ce},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:de},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:ft},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:le},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:mt},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:qt},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:Ft},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:Bt},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:H},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:et},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:ee},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:te},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:ue},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:Yt},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:$t}],Te=(0,o.eW)((()=>{const t={state:Xt,choice:Q,note:Wt,rectWithTitle:Ut,labelRect:Lt,iconSquare:Et,iconCircle:Tt,icon:kt,iconRounded:_t,imageSquare:St,anchor:q,kanbanItem:we,classBox:ye,erBox:pe,requirementBox:ve},e=[...Object.entries(t),...ke.flatMap((t=>[t.shortName,..."aliases"in t?t.aliases:[],..."internalAliases"in t?t.internalAliases:[]].map((e=>[e,t.handler]))))];return Object.fromEntries(e)}),"generateShapeMap")();function _e(t){return t in Te}(0,o.eW)(_e,"isValidShape");var Ee=new Map;async function Se(t,e,n){let r,i;"rect"===e.shape&&(e.rx&&e.ry?e.shape="roundedRect":e.shape="squareRect");const a=e.shape?Te[e.shape]:void 0;if(!a)throw new Error(`No such shape: ${e.shape}. Please check your syntax.`);if(e.link){let s;"sandbox"===n.config.securityLevel?s="_top":e.linkTarget&&(s=e.linkTarget||"_blank"),r=t.insert("svg:a").attr("xlink:href",e.link).attr("target",s??null),i=await a(r,e,n)}else i=await a(t,e,n),r=i;return e.tooltip&&i.attr("title",e.tooltip),Ee.set(e.id,r),e.haveCallback&&r.attr("class",r.attr("class")+" clickable"),r}(0,o.eW)(Se,"insertNode");var Ce=(0,o.eW)(((t,e)=>{Ee.set(e.id,t)}),"setNodeElem"),Ae=(0,o.eW)((()=>{Ee.clear()}),"clear"),Le=(0,o.eW)((t=>{const e=Ee.get(t.id);o.cM.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");const n=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+n-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),n}),"positionNode")},1566:(t,e,n)=>{"use strict";n.d(e,{DQ:()=>M,I_:()=>v,Jj:()=>b,QP:()=>C,ZH:()=>m});var r=n(5179),i=n(3583),a=n(1426),s=n(214),o=n(7946),l=n(4082),c=n(3108),h=n(4247),u=(0,l.eW)(((t,e,n,r,i,a)=>{e.arrowTypeStart&&p(t,"start",e.arrowTypeStart,n,r,i,a),e.arrowTypeEnd&&p(t,"end",e.arrowTypeEnd,n,r,i,a)}),"addEdgeMarkers"),d={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},p=(0,l.eW)(((t,e,n,r,i,a,s)=>{const o=d[n];if(!o)return void l.cM.warn(`Unknown arrow type: ${n}`);const c=`${i}_${a}-${o.type}${"start"===e?"Start":"End"}`;if(s&&""!==s.trim()){const n=`${c}_${s.replace(/[^\dA-Za-z]/g,"_")}`;if(!document.getElementById(n)){const t=document.getElementById(c);if(t){const e=t.cloneNode(!0);e.id=n,e.querySelectorAll("path, circle, line").forEach((t=>{t.setAttribute("stroke",s),o.fill&&t.setAttribute("fill",s)})),t.parentNode?.appendChild(e)}}t.attr(`marker-${e}`,`url(${r}#${n})`)}else t.attr(`marker-${e}`,`url(${r}#${c})`)}),"addEdgeMarker"),g=new Map,f=new Map,m=(0,l.eW)((()=>{g.clear(),f.clear()}),"clear"),y=(0,l.eW)((t=>t?t.reduce(((t,e)=>t+";"+e),""):""),"getLabelStyles"),v=(0,l.eW)((async(t,e)=>{let n=(0,l.ku)((0,l.nV)().flowchart.htmlLabels);const r=await(0,s.rw)(t,e.label,{style:y(e.labelStyle),useHtmlLabels:n,addSvgBackground:!0,isNode:!1});l.cM.info("abc82",e,e.labelType);const a=t.insert("g").attr("class","edgeLabel"),o=a.insert("g").attr("class","label");o.node().appendChild(r);let h,u=r.getBBox();if(n){const t=r.children[0],e=(0,c.Ys)(r);u=t.getBoundingClientRect(),e.attr("width",u.width),e.attr("height",u.height)}if(o.attr("transform","translate("+-u.width/2+", "+-u.height/2+")"),g.set(e.id,a),e.width=u.width,e.height=u.height,e.startLabelLeft){const n=await(0,i.XO)(e.startLabelLeft,y(e.labelStyle)),r=t.insert("g").attr("class","edgeTerminals"),a=r.insert("g").attr("class","inner");h=a.node().appendChild(n);const s=n.getBBox();a.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),f.get(e.id)||f.set(e.id,{}),f.get(e.id).startLeft=r,x(h,e.startLabelLeft)}if(e.startLabelRight){const n=await(0,i.XO)(e.startLabelRight,y(e.labelStyle)),r=t.insert("g").attr("class","edgeTerminals"),a=r.insert("g").attr("class","inner");h=r.node().appendChild(n),a.node().appendChild(n);const s=n.getBBox();a.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),f.get(e.id)||f.set(e.id,{}),f.get(e.id).startRight=r,x(h,e.startLabelRight)}if(e.endLabelLeft){const n=await(0,i.XO)(e.endLabelLeft,y(e.labelStyle)),r=t.insert("g").attr("class","edgeTerminals"),a=r.insert("g").attr("class","inner");h=a.node().appendChild(n);const s=n.getBBox();a.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),r.node().appendChild(n),f.get(e.id)||f.set(e.id,{}),f.get(e.id).endLeft=r,x(h,e.endLabelLeft)}if(e.endLabelRight){const n=await(0,i.XO)(e.endLabelRight,y(e.labelStyle)),r=t.insert("g").attr("class","edgeTerminals"),a=r.insert("g").attr("class","inner");h=a.node().appendChild(n);const s=n.getBBox();a.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),r.node().appendChild(n),f.get(e.id)||f.set(e.id,{}),f.get(e.id).endRight=r,x(h,e.endLabelRight)}return r}),"insertEdgeLabel");function x(t,e){(0,l.nV)().flowchart.htmlLabels&&t&&(t.style.width=9*e.length+"px",t.style.height="12px")}(0,l.eW)(x,"setTerminalWidth");var b=(0,l.eW)(((t,e)=>{l.cM.debug("Moving label abc88 ",t.id,t.label,g.get(t.id),e);let n=e.updatedPath?e.updatedPath:e.originalPath;const r=(0,l.nV)(),{subGraphTitleTotalMargin:i}=(0,a.L)(r);if(t.label){const r=g.get(t.id);let a=t.x,s=t.y;if(n){const r=o.w8.calcLabelPosition(n);l.cM.debug("Moving label "+t.label+" from (",a,",",s,") to (",r.x,",",r.y,") abc88"),e.updatedPath&&(a=r.x,s=r.y)}r.attr("transform",`translate(${a}, ${s+i/2})`)}if(t.startLabelLeft){const e=f.get(t.id).startLeft;let r=t.x,i=t.y;if(n){const e=o.w8.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_left",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}if(t.startLabelRight){const e=f.get(t.id).startRight;let r=t.x,i=t.y;if(n){const e=o.w8.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_right",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}if(t.endLabelLeft){const e=f.get(t.id).endLeft;let r=t.x,i=t.y;if(n){const e=o.w8.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_left",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}if(t.endLabelRight){const e=f.get(t.id).endRight;let r=t.x,i=t.y;if(n){const e=o.w8.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_right",n);r=e.x,i=e.y}e.attr("transform",`translate(${r}, ${i})`)}}),"positionEdgeLabel"),w=(0,l.eW)(((t,e)=>{const n=t.x,r=t.y,i=Math.abs(e.x-n),a=Math.abs(e.y-r),s=t.width/2,o=t.height/2;return i>=s||a>=o}),"outsideNode"),k=(0,l.eW)(((t,e,n)=>{l.cM.debug(`intersection calc abc89:\n outsidePoint: ${JSON.stringify(e)}\n insidePoint : ${JSON.stringify(n)}\n node : x:${t.x} y:${t.y} w:${t.width} h:${t.height}`);const r=t.x,i=t.y,a=Math.abs(r-n.x),s=t.width/2;let o=n.xMath.abs(r-e.x)*c){let t=n.y{l.cM.warn("abc88 cutPathAtIntersect",t,e);let n=[],r=t[0],i=!1;return t.forEach((t=>{if(l.cM.info("abc88 checking point",t,e),w(e,t)||i)l.cM.warn("abc88 outside",t,r),r=t,i||n.push(t);else{const a=k(e,r,t);l.cM.debug("abc88 inside",t,r,a),l.cM.debug("abc88 intersection",a,e);let s=!1;n.forEach((t=>{s=s||t.x===a.x&&t.y===a.y})),n.some((t=>t.x===a.x&&t.y===a.y))?l.cM.warn("abc88 no intersect",a,n):n.push(a),i=!0}})),l.cM.debug("returning points",n),n}),"cutPathAtIntersect");function _(t){const e=[],n=[];for(let r=1;r5&&Math.abs(a.y-i.y)>5||i.y===a.y&&a.x===s.x&&Math.abs(a.x-i.x)>5&&Math.abs(a.y-s.y)>5)&&(e.push(a),n.push(r))}return{cornerPoints:e,cornerPointPositions:n}}(0,l.eW)(_,"extractCornerPoints");var E=(0,l.eW)((function(t,e,n){const r=e.x-t.x,i=e.y-t.y,a=n/Math.sqrt(r*r+i*i);return{x:e.x-a*r,y:e.y-a*i}}),"findAdjacentPoint"),S=(0,l.eW)((function(t){const{cornerPointPositions:e}=_(t),n=[];for(let r=0;r10&&Math.abs(i.y-e.y)>=10){l.cM.debug("Corner point fixing",Math.abs(i.x-e.x),Math.abs(i.y-e.y));const t=5;d=a.x===s.x?{x:c<0?s.x-t+u:s.x+t-u,y:h<0?s.y-u:s.y+u}:{x:c<0?s.x-u:s.x+u,y:h<0?s.y-t+u:s.y+t-u}}else l.cM.debug("Corner point skipping fixing",Math.abs(i.x-e.x),Math.abs(i.y-e.y));n.push(d,o)}else n.push(t[r]);return n}),"fixCorners"),C=(0,l.eW)((function(t,e,n,a,s,o,d){const{handDrawnSeed:p}=(0,l.nV)();let g=e.points,f=!1;const m=s;var y=o;const v=[];for(const t in e.cssCompiledStyles)(0,i.Fh)(t)||v.push(e.cssCompiledStyles[t]);y.intersect&&m.intersect&&(g=g.slice(1,e.points.length-1),g.unshift(m.intersect(g[0])),l.cM.debug("Last point APA12",e.start,"--\x3e",e.end,g[g.length-1],y,y.intersect(g[g.length-1])),g.push(y.intersect(g[g.length-1]))),e.toCluster&&(l.cM.info("to cluster abc88",n.get(e.toCluster)),g=T(e.points,n.get(e.toCluster).node),f=!0),e.fromCluster&&(l.cM.debug("from cluster abc88",n.get(e.fromCluster),JSON.stringify(g,null,2)),g=T(g.reverse(),n.get(e.fromCluster).node).reverse(),f=!0);let x=g.filter((t=>!Number.isNaN(t.y)));x=S(x);let b=c.$0Z;switch(b=c.c_6,e.curve){case"linear":b=c.c_6;break;case"basis":default:b=c.$0Z;break;case"cardinal":b=c.YY7;break;case"bumpX":b=c.qpX;break;case"bumpY":b=c.u93;break;case"catmullRom":b=c.zgE;break;case"monotoneX":b=c.FdL;break;case"monotoneY":b=c.ak_;break;case"natural":b=c.SxZ;break;case"step":b=c.eA_;break;case"stepAfter":b=c.jsv;break;case"stepBefore":b=c.iJ}const{x:w,y:k}=(0,r.o)(e),_=(0,c.jvg)().x(w).y(k).curve(b);let E,C;switch(e.thickness){case"normal":default:E="edge-thickness-normal";break;case"thick":E="edge-thickness-thick";break;case"invisible":E="edge-thickness-invisible"}switch(e.pattern){case"solid":default:E+=" edge-pattern-solid";break;case"dotted":E+=" edge-pattern-dotted";break;case"dashed":E+=" edge-pattern-dashed"}let A=_(x);const L=Array.isArray(e.style)?e.style:[e.style];let M=L.find((t=>t?.startsWith("stroke:")));if("handDrawn"===e.look){const n=h.Z.svg(t);Object.assign([],x);const r=n.path(A,{roughness:.3,seed:p});E+=" transition",C=(0,c.Ys)(r).select("path").attr("id",e.id).attr("class"," "+E+(e.classes?" "+e.classes:"")).attr("style",L?L.reduce(((t,e)=>t+";"+e),""):"");let i=C.attr("d");C.attr("d",i),t.node().appendChild(C.node())}else{const n=v.join(";"),r=L?L.reduce(((t,e)=>t+e+";"),""):"";let i="";e.animate&&(i=" edge-animation-fast"),e.animation&&(i=" edge-animation-"+e.animation);const a=n?n+";"+r+";":r;C=t.append("path").attr("d",A).attr("id",e.id).attr("class"," "+E+(e.classes?" "+e.classes:"")+(i??"")).attr("style",a),M=a.match(/stroke:([^;]+)/)?.[1]}let N="";((0,l.nV)().flowchart.arrowMarkerAbsolute||(0,l.nV)().state.arrowMarkerAbsolute)&&(N=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,N=N.replace(/\(/g,"\\(").replace(/\)/g,"\\)")),l.cM.info("arrowTypeStart",e.arrowTypeStart),l.cM.info("arrowTypeEnd",e.arrowTypeEnd),u(C,e,N,d,a,M);let I={};return f&&(I.updatedPath=g),I.originalPath=e.points,I}),"insertEdge"),A=(0,l.eW)(((t,e,n,r)=>{e.forEach((e=>{L[e](t,n,r)}))}),"insertMarkers"),L={extension:(0,l.eW)(((t,e,n)=>{l.cM.trace("Making markers for ",n),t.append("defs").append("marker").attr("id",n+"_"+e+"-extensionStart").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")}),"extension"),composition:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-compositionStart").attr("class","marker composition "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")}),"composition"),aggregation:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")}),"aggregation"),dependency:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",n+"_"+e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")}),"dependency"),lollipop:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-lollipopStart").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),t.append("defs").append("marker").attr("id",n+"_"+e+"-lollipopEnd").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)}),"lollipop"),point:(0,l.eW)(((t,e,n)=>{t.append("marker").attr("id",n+"_"+e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",n+"_"+e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")}),"point"),circle:(0,l.eW)(((t,e,n)=>{t.append("marker").attr("id",n+"_"+e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",n+"_"+e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")}),"circle"),cross:(0,l.eW)(((t,e,n)=>{t.append("marker").attr("id",n+"_"+e+"-crossEnd").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),t.append("marker").attr("id",n+"_"+e+"-crossStart").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")}),"cross"),barb:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")}),"barb"),only_one:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-onlyOneStart").attr("class","marker onlyOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),t.append("defs").append("marker").attr("id",n+"_"+e+"-onlyOneEnd").attr("class","marker onlyOne "+e).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")}),"only_one"),zero_or_one:(0,l.eW)(((t,e,n)=>{const r=t.append("defs").append("marker").attr("id",n+"_"+e+"-zeroOrOneStart").attr("class","marker zeroOrOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");r.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),r.append("path").attr("d","M9,0 L9,18");const i=t.append("defs").append("marker").attr("id",n+"_"+e+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+e).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),i.append("path").attr("d","M21,0 L21,18")}),"zero_or_one"),one_or_more:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-oneOrMoreStart").attr("class","marker oneOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),t.append("defs").append("marker").attr("id",n+"_"+e+"-oneOrMoreEnd").attr("class","marker oneOrMore "+e).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")}),"one_or_more"),zero_or_more:(0,l.eW)(((t,e,n)=>{const r=t.append("defs").append("marker").attr("id",n+"_"+e+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");r.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),r.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");const i=t.append("defs").append("marker").attr("id",n+"_"+e+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+e).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),i.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")}),"zero_or_more"),requirement_arrow:(0,l.eW)(((t,e,n)=>{t.append("defs").append("marker").attr("id",n+"_"+e+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d","M0,0\n L20,10\n M20,10\n L0,20")}),"requirement_arrow"),requirement_contains:(0,l.eW)(((t,e,n)=>{const r=t.append("defs").append("marker").attr("id",n+"_"+e+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");r.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),r.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),r.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)}),"requirement_contains")},M=A},1426:(t,e,n)=>{"use strict";n.d(e,{L:()=>r});var r=(0,n(4082).eW)((({flowchart:t})=>{const e=t?.subGraphTitleMargin?.top??0,n=t?.subGraphTitleMargin?.bottom??0;return{subGraphTitleTopMargin:e,subGraphTitleBottomMargin:n,subGraphTitleTotalMargin:e+n}}),"getSubGraphTitleMargins")},7946:(t,e,n)=>{"use strict";n.d(e,{$m:()=>l,Cq:()=>O,Ln:()=>q,MX:()=>L,Ox:()=>C,R7:()=>j,Rb:()=>Y,SH:()=>V,VG:()=>Z,Vy:()=>G,X4:()=>I,XD:()=>D,bZ:()=>W,be:()=>E,le:()=>f,tf:()=>p,w8:()=>U});var r=n(4082),i=n(7967),a=n(3108),s=n(2454),o=n(7103),l="​",c={curveBasis:a.$0Z,curveBasisClosed:a.Dts,curveBasisOpen:a.WQY,curveBumpX:a.qpX,curveBumpY:a.u93,curveBundle:a.tFB,curveCardinalClosed:a.OvA,curveCardinalOpen:a.dCK,curveCardinal:a.YY7,curveCatmullRomClosed:a.fGX,curveCatmullRomOpen:a.$m7,curveCatmullRom:a.zgE,curveLinear:a.c_6,curveLinearClosed:a.fxm,curveMonotoneX:a.FdL,curveMonotoneY:a.ak_,curveNatural:a.SxZ,curveStep:a.eA_,curveStepAfter:a.jsv,curveStepBefore:a.iJ},h=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,u=(0,r.eW)((function(t,e){const n=d(t,/(?:init\b)|(?:initialize\b)/);let i={};if(Array.isArray(n)){const t=n.map((t=>t.args));(0,r.NM)(t),i=(0,r.Yc)(i,[...t])}else i=n.args;if(!i)return;let a=(0,r.Vg)(t,e);const s="config";return void 0!==i[s]&&("flowchart-v2"===a&&(a="flowchart"),i[a]=i[s],delete i[s]),i}),"detectInit"),d=(0,r.eW)((function(t,e=null){try{const n=new RegExp(`[%]{2}(?![{]${h.source})(?=[}][%]{2}).*\n`,"ig");let i;t=t.trim().replace(n,"").replace(/'/gm,'"'),r.cM.debug(`Detecting diagram directive${null!==e?" type:"+e:""} based on the text:${t}`);const a=[];for(;null!==(i=r.Zn.exec(t));)if(i.index===r.Zn.lastIndex&&r.Zn.lastIndex++,i&&!e||e&&i[1]?.match(e)||e&&i[2]?.match(e)){const t=i[1]?i[1]:i[2],e=i[3]?i[3].trim():i[4]?JSON.parse(i[4].trim()):null;a.push({type:t,args:e})}return 0===a.length?{type:t,args:null}:1===a.length?a[0]:a}catch(n){return r.cM.error(`ERROR: ${n.message} - Unable to parse directive type: '${e}' based on the text: '${t}'`),{type:void 0,args:null}}}),"detectDirective"),p=(0,r.eW)((function(t){return t.replace(r.Zn,"")}),"removeDirectives"),g=(0,r.eW)((function(t,e){for(const[n,r]of e.entries())if(r.match(t))return n;return-1}),"isSubstringInArray");function f(t,e){if(!t)return e;const n=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return c[n]??e}function m(t,e){const n=t.trim();if(n)return"loose"!==e.securityLevel?(0,i.N)(n):n}(0,r.eW)(f,"interpolateToCurve"),(0,r.eW)(m,"formatUrl");var y=(0,r.eW)(((t,...e)=>{const n=t.split("."),i=n.length-1,a=n[i];let s=window;for(let e=0;e{n+=v(t,e),e=t})),k(t,n/2)}function b(t){return 1===t.length?t[0]:x(t)}(0,r.eW)(v,"distance"),(0,r.eW)(x,"traverseEdge"),(0,r.eW)(b,"calcLabelPosition");var w=(0,r.eW)(((t,e=2)=>{const n=Math.pow(10,e);return Math.round(t*n)/n}),"roundNumber"),k=(0,r.eW)(((t,e)=>{let n,r=e;for(const e of t){if(n){const t=v(e,n);if(0===t)return n;if(t=1)return{x:e.x,y:e.y};if(i>0&&i<1)return{x:w((1-i)*n.x+i*e.x,5),y:w((1-i)*n.y+i*e.y,5)}}}n=e}throw new Error("Could not find a suitable point for the given distance")}),"calculatePoint"),T=(0,r.eW)(((t,e,n)=>{r.cM.info(`our points ${JSON.stringify(e)}`),e[0]!==n&&(e=e.reverse());const i=k(e,25),a=t?10:5,s=Math.atan2(e[0].y-i.y,e[0].x-i.x),o={x:0,y:0};return o.x=Math.sin(s)*a+(e[0].x+i.x)/2,o.y=-Math.cos(s)*a+(e[0].y+i.y)/2,o}),"calcCardinalityPosition");function _(t,e,n){const i=structuredClone(n);r.cM.info("our points",i),"start_left"!==e&&"start_right"!==e&&i.reverse();const a=k(i,25+t),s=10+.5*t,o=Math.atan2(i[0].y-a.y,i[0].x-a.x),l={x:0,y:0};return"start_left"===e?(l.x=Math.sin(o+Math.PI)*s+(i[0].x+a.x)/2,l.y=-Math.cos(o+Math.PI)*s+(i[0].y+a.y)/2):"end_right"===e?(l.x=Math.sin(o-Math.PI)*s+(i[0].x+a.x)/2-5,l.y=-Math.cos(o-Math.PI)*s+(i[0].y+a.y)/2-5):"end_left"===e?(l.x=Math.sin(o)*s+(i[0].x+a.x)/2-5,l.y=-Math.cos(o)*s+(i[0].y+a.y)/2-5):(l.x=Math.sin(o)*s+(i[0].x+a.x)/2,l.y=-Math.cos(o)*s+(i[0].y+a.y)/2),l}function E(t){let e="",n="";for(const r of t)void 0!==r&&(r.startsWith("color:")||r.startsWith("text-align:")?n=n+r+";":e=e+r+";");return{style:e,labelStyle:n}}(0,r.eW)(_,"calcTerminalLabelPosition"),(0,r.eW)(E,"getStylesFromArray");var S=0,C=(0,r.eW)((()=>(S++,"id-"+Math.random().toString(36).substr(2,12)+"-"+S)),"generateId");function A(t){let e="";for(let n=0;nA(t.length)),"random"),M=(0,r.eW)((function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}}),"getTextObj"),N=(0,r.eW)((function(t,e){const n=e.text.replace(r.SY.lineBreakRegex," "),[,i]=Z(e.fontSize),a=t.append("text");a.attr("x",e.x),a.attr("y",e.y),a.style("text-anchor",e.anchor),a.style("font-family",e.fontFamily),a.style("font-size",i),a.style("font-weight",e.fontWeight),a.attr("fill",e.fill),void 0!==e.class&&a.attr("class",e.class);const s=a.append("tspan");return s.attr("x",e.x+2*e.textMargin),s.attr("fill",e.fill),s.text(n),a}),"drawSimpleText"),I=(0,s.Z)(((t,e,n)=>{if(!t)return t;if(n=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"
    "},n),r.SY.lineBreakRegex.test(t))return t;const i=t.split(" ").filter(Boolean),a=[];let s="";return i.forEach(((t,r)=>{const o=O(`${t} `,n),l=O(s,n);if(o>e){const{hyphenatedStrings:r,remainingWord:i}=R(t,e,"-",n);a.push(s,...r),s=i}else l+o>=e?(a.push(s),s=t):s=[s,t].filter(Boolean).join(" ");r+1===i.length&&a.push(s)})),a.filter((t=>""!==t)).join(n.joinWith)}),((t,e,n)=>`${t}${e}${n.fontSize}${n.fontWeight}${n.fontFamily}${n.joinWith}`)),R=(0,s.Z)(((t,e,n="-",r)=>{r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},r);const i=[...t],a=[];let s="";return i.forEach(((t,o)=>{const l=`${s}${t}`;if(O(l,r)>=e){const t=o+1,e=i.length===t,r=`${l}${n}`;a.push(e?l:r),s=""}else s=l})),{hyphenatedStrings:a,remainingWord:s}}),((t,e,n="-",r)=>`${t}${e}${n}${r.fontSize}${r.fontWeight}${r.fontFamily}`));function D(t,e){return $(t,e).height}function O(t,e){return $(t,e).width}(0,r.eW)(D,"calculateTextHeight"),(0,r.eW)(O,"calculateTextWidth");var P,$=(0,s.Z)(((t,e)=>{const{fontSize:n=12,fontFamily:i="Arial",fontWeight:s=400}=e;if(!t)return{width:0,height:0};const[,o]=Z(n),c=["sans-serif",i],h=t.split(r.SY.lineBreakRegex),u=[],d=(0,a.Ys)("body");if(!d.remove)return{width:0,height:0,lineHeight:0};const p=d.append("svg");for(const t of c){let e=0;const n={width:0,height:0,lineHeight:0};for(const r of h){const i=M();i.text=r||l;const a=N(p,i).style("font-size",o).style("font-weight",s).style("font-family",t),c=(a._groups||a)[0][0].getBBox();if(0===c.width&&0===c.height)throw new Error("svg element not in render tree");n.width=Math.round(Math.max(n.width,c.width)),e=Math.round(c.height),n.height+=e,n.lineHeight=Math.round(Math.max(n.lineHeight,e))}u.push(n)}return p.remove(),u[isNaN(u[1].height)||isNaN(u[1].width)||isNaN(u[1].lineHeight)||u[0].height>u[1].height&&u[0].width>u[1].width&&u[0].lineHeight>u[1].lineHeight?0:1]}),((t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`)),B=class{constructor(t=!1,e){this.count=0,this.count=e?e.length:0,this.next=t?()=>this.count++:()=>Date.now()}static{(0,r.eW)(this,"InitIDGenerator")}},F=(0,r.eW)((function(t){return P=P||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),P.innerHTML=t,unescape(P.textContent)}),"entityDecode");function W(t){return"str"in t}(0,r.eW)(W,"isDetailedError");var z=(0,r.eW)(((t,e,n,r)=>{if(!r)return;const i=t.node()?.getBBox();i&&t.append("text").text(r).attr("text-anchor","middle").attr("x",i.x+i.width/2).attr("y",-n).attr("class",e)}),"insertTitle"),Z=(0,r.eW)((t=>{if("number"==typeof t)return[t,t+"px"];const e=parseInt(t??"",10);return Number.isNaN(e)?[void 0,void 0]:t===String(e)?[e,t+"px"]:[e,t]}),"parseFontSize");function Y(t,e){return(0,o.Z)({},t,e)}(0,r.eW)(Y,"cleanAndMerge");var U={assignWithDepth:r.Yc,wrapLabel:I,calculateTextHeight:D,calculateTextWidth:O,calculateTextDimensions:$,cleanAndMerge:Y,detectInit:u,detectDirective:d,isSubstringInArray:g,interpolateToCurve:f,calcLabelPosition:b,calcCardinalityPosition:T,calcTerminalLabelPosition:_,formatUrl:m,getStylesFromArray:E,generateId:C,random:L,runFunc:y,entityDecode:F,insertTitle:z,parseFontSize:Z,InitIDGenerator:B},G=(0,r.eW)((function(t){let e=t;return e=e.replace(/style.*:\S*#.*;/g,(function(t){return t.substring(0,t.length-1)})),e=e.replace(/classDef.*:\S*#.*;/g,(function(t){return t.substring(0,t.length-1)})),e=e.replace(/#\w+;/g,(function(t){const e=t.substring(1,t.length-1);return/^\+?\d+$/.test(e)?"fl°°"+e+"¶ß":"fl°"+e+"¶ß"})),e}),"encodeEntities"),V=(0,r.eW)((function(t){return t.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")}),"decodeEntities"),q=(0,r.eW)(((t,e,{counter:n=0,prefix:r,suffix:i},a)=>a||`${r?`${r}_`:""}${t}_${e}_${n}${i?`_${i}`:""}`),"getEdgeId");function j(t){return t??null}(0,r.eW)(j,"handleUndefinedAttr")},907:(t,e,n)=>{"use strict";n.d(e,{j:()=>s,q:()=>a});var r=n(4082),i=n(3108),a=(0,r.eW)(((t,e)=>{let n;return"sandbox"===e&&(n=(0,i.Ys)("#i"+t)),("sandbox"===e?(0,i.Ys)(n.nodes()[0].contentDocument.body):(0,i.Ys)("body")).select(`[id="${t}"]`)}),"getDiagramElement"),s=(0,r.eW)(((t,e,n,i)=>{t.attr("class",n);const{width:a,height:s,x:c,y:h}=o(t,e);(0,r.v2)(t,s,a,i);const u=l(c,h,a,s,e);t.attr("viewBox",u),r.cM.debug(`viewBox configured: ${u} with padding: ${e}`)}),"setupViewPortForSVG"),o=(0,r.eW)(((t,e)=>{const n=t.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:n.width+2*e,height:n.height+2*e,x:n.x,y:n.y}}),"calculateDimensionsWithPadding"),l=(0,r.eW)(((t,e,n,r,i)=>`${t-i} ${e-i} ${n} ${r}`),"createViewBox")},8337:(t,e,n)=>{"use strict";n.d(e,{_b:()=>u,jM:()=>c,sY:()=>h});var r=n(1566),i=n(3583),a=n(7946),s=n(4082),o={common:s.SY,getConfig:s.iE,insertCluster:i.us,insertEdge:r.QP,insertEdgeLabel:r.I_,insertMarkers:r.DQ,insertNode:i.Lf,interpolateToCurve:a.le,labelHelper:i.C1,log:s.cM,positionEdgeLabel:r.Jj},l={},c=(0,s.eW)((t=>{for(const e of t)l[e.name]=e}),"registerLayoutLoaders");(0,s.eW)((()=>{c([{name:"dagre",loader:(0,s.eW)((async()=>await Promise.resolve().then(n.bind(n,5255))),"loader")}])}),"registerDefaultLayoutLoaders")();var h=(0,s.eW)((async(t,e)=>{if(!(t.layoutAlgorithm in l))throw new Error(`Unknown layout algorithm: ${t.layoutAlgorithm}`);const n=l[t.layoutAlgorithm];return(await n.loader()).render(t,e,o,{algorithm:n.algorithm})}),"render"),u=(0,s.eW)(((t="",{fallback:e="dagre"}={})=>{if(t in l)return t;if(e in l)return s.cM.warn(`Layout algorithm ${t} is not registered. Using ${e} as fallback.`),e;throw new Error(`Both layout algorithms ${t} and ${e} are not registered.`)}),"getRegisteredLayoutAlgorithm")},5179:(t,e,n)=>{"use strict";n.d(e,{o:()=>o});var r=n(4082),i={aggregation:18,extension:18,composition:18,dependency:6,lollipop:13.5,arrow_point:4};function a(t,e){if(void 0===t||void 0===e)return{angle:0,deltaX:0,deltaY:0};t=s(t),e=s(e);const[n,r]=[t.x,t.y],[i,a]=[e.x,e.y],o=i-n,l=a-r;return{angle:Math.atan(l/o),deltaX:o,deltaY:l}}(0,r.eW)(a,"calculateDeltaAndAngle");var s=(0,r.eW)((t=>Array.isArray(t)?{x:t[0],y:t[1]}:t),"pointTransformer"),o=(0,r.eW)((t=>({x:(0,r.eW)((function(e,n,r){let o=0;const l=s(r[0]).x=0?1:-1)}else if(n===r.length-1&&Object.hasOwn(i,t.arrowTypeEnd)){const{angle:e,deltaX:n}=a(r[r.length-1],r[r.length-2]);o=i[t.arrowTypeEnd]*Math.cos(e)*(n>=0?1:-1)}const c=Math.abs(s(e).x-s(r[r.length-1]).x),h=Math.abs(s(e).y-s(r[r.length-1]).y),u=Math.abs(s(e).x-s(r[0]).x),d=Math.abs(s(e).y-s(r[0]).y),p=i[t.arrowTypeStart],g=i[t.arrowTypeEnd];if(c0&&h0&&d=0?1:-1)}else if(n===r.length-1&&Object.hasOwn(i,t.arrowTypeEnd)){const{angle:e,deltaY:n}=a(r[r.length-1],r[r.length-2]);o=i[t.arrowTypeEnd]*Math.abs(Math.sin(e))*(n>=0?1:-1)}const c=Math.abs(s(e).y-s(r[r.length-1]).y),h=Math.abs(s(e).x-s(r[r.length-1]).x),u=Math.abs(s(e).y-s(r[0]).y),d=Math.abs(s(e).x-s(r[0]).x),p=i[t.arrowTypeStart],g=i[t.arrowTypeEnd];if(c0&&h0&&d{"use strict";n.d(e,{A:()=>i});var r=n(4082),i=class{constructor(t){this.init=t,this.records=this.init()}static{(0,r.eW)(this,"ImperativeState")}reset(){this.records=this.init()}}},4082:(t,e,n)=>{"use strict";n.d(e,{cj:()=>_,r2:()=>m,eW:()=>f,XV:()=>ht,Yc:()=>N,nH:()=>Ft,ZH:()=>ee,LJ:()=>Xt,SY:()=>zt,v2:()=>Ut,u_:()=>Q,Fy:()=>de,vZ:()=>H,Vg:()=>S,Bf:()=>E,Zn:()=>k,ku:()=>Lt,M6:()=>w,Mx:()=>ae,eu:()=>re,iE:()=>lt,nV:()=>he,_7:()=>ve,cq:()=>L,Kr:()=>oe,ZD:()=>st,xN:()=>W,l0:()=>Bt,Vw:()=>mt,cM:()=>v,UO:()=>It,Cq:()=>ye,KO:()=>C,uT:()=>Wt,mc:()=>ut,NM:()=>X,oO:()=>kt,uX:()=>pe,dY:()=>it,U$:()=>ie,GN:()=>ne,v6:()=>ot,Y4:()=>ue,g2:()=>se,Ub:()=>x,Yn:()=>rt,j7:()=>Gt,Rw:()=>ge,Ee:()=>Ht,_j:()=>U,Tb:()=>at});var r=n(7484),i=n(1767),a=n(3438);const s=(t,e)=>{const n=i.Z.parse(t),r={};for(const t in e)e[t]&&(r[t]=n[t]+e[t]);return(0,a.Z)(t,r)};var o=n(1117);const l=(t,e=100)=>{const n=i.Z.parse(t);return n.r=255-n.r,n.g=255-n.g,n.b=255-n.b,((t,e,n=50)=>{const{r,g:a,b:s,a:l}=i.Z.parse(t),{r:c,g:h,b:u,a:d}=i.Z.parse(e),p=n/100,g=2*p-1,f=l-d,m=((g*f==-1?g:(g+f)/(1+g*f))+1)/2,y=1-m,v=r*m+c*y,x=a*m+h*y,b=s*m+u*y,w=l*p+d*(1-p);return(0,o.Z)(v,x,b,w)})(n,t,e)};var c,h=n(7201),u=n(2281),d=n(6500),p=n(2424),g=Object.defineProperty,f=(t,e)=>g(t,"name",{value:e,configurable:!0}),m=(t,e)=>{for(var n in e)g(t,n,{get:e[n],enumerable:!0})},y={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},v={trace:f(((...t)=>{}),"trace"),debug:f(((...t)=>{}),"debug"),info:f(((...t)=>{}),"info"),warn:f(((...t)=>{}),"warn"),error:f(((...t)=>{}),"error"),fatal:f(((...t)=>{}),"fatal")},x=f((function(t="fatal"){let e=y.fatal;"string"==typeof t?t.toLowerCase()in y&&(e=y[t]):"number"==typeof t&&(e=t),v.trace=()=>{},v.debug=()=>{},v.info=()=>{},v.warn=()=>{},v.error=()=>{},v.fatal=()=>{},e<=y.fatal&&(v.fatal=console.error?console.error.bind(console,b("FATAL"),"color: orange"):console.log.bind(console,"",b("FATAL"))),e<=y.error&&(v.error=console.error?console.error.bind(console,b("ERROR"),"color: orange"):console.log.bind(console,"",b("ERROR"))),e<=y.warn&&(v.warn=console.warn?console.warn.bind(console,b("WARN"),"color: orange"):console.log.bind(console,"",b("WARN"))),e<=y.info&&(v.info=console.info?console.info.bind(console,b("INFO"),"color: lightblue"):console.log.bind(console,"",b("INFO"))),e<=y.debug&&(v.debug=console.debug?console.debug.bind(console,b("DEBUG"),"color: lightgreen"):console.log.bind(console,"",b("DEBUG"))),e<=y.trace&&(v.trace=console.debug?console.debug.bind(console,b("TRACE"),"color: lightgreen"):console.log.bind(console,"",b("TRACE")))}),"setLogLevel"),b=f((t=>`%c${r().format("ss.SSS")} : ${t} : `),"format"),w=/^-{3}\s*[\n\r](.*?)[\n\r]-{3}\s*[\n\r]+/s,k=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,T=/\s*%%.*\n/gm,_=class extends Error{static{f(this,"UnknownDiagramError")}constructor(t){super(t),this.name="UnknownDiagramError"}},E={},S=f((function(t,e){t=t.replace(w,"").replace(k,"").replace(T,"\n");for(const[n,{detector:r}]of Object.entries(E))if(r(t,e))return n;throw new _(`No diagram type detected matching given configuration for text: ${t}`)}),"detectType"),C=f(((...t)=>{for(const{id:e,detector:n,loader:r}of t)A(e,n,r)}),"registerLazyLoadedDiagrams"),A=f(((t,e,n)=>{E[t]&&v.warn(`Detector with key ${t} already exists. Overwriting.`),E[t]={detector:e,loader:n},v.debug(`Detector with key ${t} added${n?" with loader":""}`)}),"addDetector"),L=f((t=>E[t].loader),"getDiagramLoader"),M=f(((t,e,{depth:n=2,clobber:r=!1}={})=>{const i={depth:n,clobber:r};return Array.isArray(e)&&!Array.isArray(t)?(e.forEach((e=>M(t,e,i))),t):Array.isArray(e)&&Array.isArray(t)?(e.forEach((e=>{t.includes(e)||t.push(e)})),t):void 0===t||n<=0?null!=t&&"object"==typeof t&&"object"==typeof e?Object.assign(t,e):e:(void 0!==e&&"object"==typeof t&&"object"==typeof e&&Object.keys(e).forEach((i=>{"object"!=typeof e[i]||void 0!==t[i]&&"object"!=typeof t[i]?(r||"object"!=typeof t[i]&&"object"!=typeof e[i])&&(t[i]=e[i]):(void 0===t[i]&&(t[i]=Array.isArray(e[i])?[]:{}),t[i]=M(t[i],e[i],{depth:n-1,clobber:r}))})),t)}),"assignWithDepth"),N=M,I="#ffffff",R="#f2f2f2",D=f(((t,e)=>s(t,e?{s:-40,l:10}:{s:-40,l:-10})),"mkBorder"),O=class{static{f(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||s(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||s(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||D(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||D(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||D(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||D(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||l(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||l(this.tertiaryColor),this.lineColor=this.lineColor||l(this.background),this.arrowheadColor=this.arrowheadColor||l(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?(0,h.Z)(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||(0,h.Z)(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||l(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||(0,u.Z)(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||(0,h.Z)(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||(0,h.Z)(this.mainBkg,10)):(this.rowOdd=this.rowOdd||(0,u.Z)(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||(0,u.Z)(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||s(this.primaryColor,{h:30}),this.cScale4=this.cScale4||s(this.primaryColor,{h:60}),this.cScale5=this.cScale5||s(this.primaryColor,{h:90}),this.cScale6=this.cScale6||s(this.primaryColor,{h:120}),this.cScale7=this.cScale7||s(this.primaryColor,{h:150}),this.cScale8=this.cScale8||s(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||s(this.primaryColor,{h:270}),this.cScale10=this.cScale10||s(this.primaryColor,{h:300}),this.cScale11=this.cScale11||s(this.primaryColor,{h:330}),this.darkMode)for(let t=0;t{this[e]=t[e]})),this.updateColors(),e.forEach((e=>{this[e]=t[e]}))}},P=f((t=>{const e=new O;return e.calculate(t),e}),"getThemeVariables"),$=class{static{f(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=(0,u.Z)(this.primaryColor,16),this.tertiaryColor=s(this.primaryColor,{h:-160}),this.primaryBorderColor=l(this.background),this.secondaryBorderColor=D(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=D(this.tertiaryColor,this.darkMode),this.primaryTextColor=l(this.primaryColor),this.secondaryTextColor=l(this.secondaryColor),this.tertiaryTextColor=l(this.tertiaryColor),this.lineColor=l(this.background),this.textColor=l(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=(0,u.Z)(l("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=(0,o.Z)(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.sectionBkgColor=(0,h.Z)("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=(0,h.Z)(this.sectionBkgColor,10),this.taskBorderColor=(0,o.Z)(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=(0,o.Z)(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||(0,u.Z)(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||(0,h.Z)(this.mainBkg,10),this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){this.secondBkg=(0,u.Z)(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=(0,u.Z)(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=(0,u.Z)(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=this.darkTextColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=s(this.primaryColor,{h:64}),this.fillType3=s(this.secondaryColor,{h:64}),this.fillType4=s(this.primaryColor,{h:-64}),this.fillType5=s(this.secondaryColor,{h:-64}),this.fillType6=s(this.primaryColor,{h:128}),this.fillType7=s(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||s(this.primaryColor,{h:30}),this.cScale4=this.cScale4||s(this.primaryColor,{h:60}),this.cScale5=this.cScale5||s(this.primaryColor,{h:90}),this.cScale6=this.cScale6||s(this.primaryColor,{h:120}),this.cScale7=this.cScale7||s(this.primaryColor,{h:150}),this.cScale8=this.cScale8||s(this.primaryColor,{h:210}),this.cScale9=this.cScale9||s(this.primaryColor,{h:270}),this.cScale10=this.cScale10||s(this.primaryColor,{h:300}),this.cScale11=this.cScale11||s(this.primaryColor,{h:330});for(let t=0;t{this[e]=t[e]})),this.updateColors(),e.forEach((e=>{this[e]=t[e]}))}},B=f((t=>{const e=new $;return e.calculate(t),e}),"getThemeVariables"),F=class{static{f(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=s(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=s(this.primaryColor,{h:-160}),this.primaryBorderColor=D(this.primaryColor,this.darkMode),this.secondaryBorderColor=D(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=D(this.tertiaryColor,this.darkMode),this.primaryTextColor=l(this.primaryColor),this.secondaryTextColor=l(this.secondaryColor),this.tertiaryTextColor=l(this.tertiaryColor),this.lineColor=l(this.background),this.textColor=l(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.sectionBkgColor=(0,o.Z)(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd="calculated",this.rowEven="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||s(this.primaryColor,{h:30}),this.cScale4=this.cScale4||s(this.primaryColor,{h:60}),this.cScale5=this.cScale5||s(this.primaryColor,{h:90}),this.cScale6=this.cScale6||s(this.primaryColor,{h:120}),this.cScale7=this.cScale7||s(this.primaryColor,{h:150}),this.cScale8=this.cScale8||s(this.primaryColor,{h:210}),this.cScale9=this.cScale9||s(this.primaryColor,{h:270}),this.cScale10=this.cScale10||s(this.primaryColor,{h:300}),this.cScale11=this.cScale11||s(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||(0,h.Z)(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||(0,h.Z)(this.tertiaryColor,40);for(let t=0;t{"calculated"===this[t]&&(this[t]=void 0)})),"object"!=typeof t)return void this.updateColors();const e=Object.keys(t);e.forEach((e=>{this[e]=t[e]})),this.updateColors(),e.forEach((e=>{this[e]=t[e]}))}},W=f((t=>{const e=new F;return e.calculate(t),e}),"getThemeVariables"),z=class{static{f(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=(0,u.Z)("#cde498",10),this.primaryBorderColor=D(this.primaryColor,this.darkMode),this.secondaryBorderColor=D(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=D(this.tertiaryColor,this.darkMode),this.primaryTextColor=l(this.primaryColor),this.secondaryTextColor=l(this.secondaryColor),this.tertiaryTextColor=l(this.primaryColor),this.lineColor=l(this.background),this.textColor=l(this.background),this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.actorBorder=(0,h.Z)(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||s(this.primaryColor,{h:30}),this.cScale4=this.cScale4||s(this.primaryColor,{h:60}),this.cScale5=this.cScale5||s(this.primaryColor,{h:90}),this.cScale6=this.cScale6||s(this.primaryColor,{h:120}),this.cScale7=this.cScale7||s(this.primaryColor,{h:150}),this.cScale8=this.cScale8||s(this.primaryColor,{h:210}),this.cScale9=this.cScale9||s(this.primaryColor,{h:270}),this.cScale10=this.cScale10||s(this.primaryColor,{h:300}),this.cScale11=this.cScale11||s(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||(0,h.Z)(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||(0,h.Z)(this.tertiaryColor,40);for(let t=0;t{this[e]=t[e]})),this.updateColors(),e.forEach((e=>{this[e]=t[e]}))}},Z=f((t=>{const e=new z;return e.calculate(t),e}),"getThemeVariables"),Y=class{static{f(this,"Theme")}constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=(0,u.Z)(this.contrast,55),this.background="#ffffff",this.tertiaryColor=s(this.primaryColor,{h:-160}),this.primaryBorderColor=D(this.primaryColor,this.darkMode),this.secondaryBorderColor=D(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=D(this.tertiaryColor,this.darkMode),this.primaryTextColor=l(this.primaryColor),this.secondaryTextColor=l(this.secondaryColor),this.tertiaryTextColor=l(this.tertiaryColor),this.lineColor=l(this.background),this.textColor=l(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||(0,u.Z)(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||"#f4f4f4",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.secondBkg=(0,u.Z)(this.contrast,55),this.border2=this.contrast,this.actorBorder=(0,u.Z)(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let t=0;t{this[e]=t[e]})),this.updateColors(),e.forEach((e=>{this[e]=t[e]}))}},U={base:{getThemeVariables:P},dark:{getThemeVariables:B},default:{getThemeVariables:W},forest:{getThemeVariables:Z},neutral:{getThemeVariables:f((t=>{const e=new Y;return e.calculate(t),e}),"getThemeVariables")}},G={flowchart:{useMaxWidth:!0,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,defaultRenderer:"dagre-wrapper",wrappingWidth:200},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"]},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!1,hideEmptyMembersBox:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:.75},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showTitle:!0,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},theme:"default",look:"classic",handDrawnSeed:0,layout:"dagre",maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},V={...G,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:"BRANDES_KOEPF"},themeCSS:void 0,themeVariables:U.default.getThemeVariables(),sequence:{...G.sequence,messageFont:f((function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}}),"messageFont"),noteFont:f((function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}}),"noteFont"),actorFont:f((function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}}),"actorFont")},class:{hideEmptyMembersBox:!1},gantt:{...G.gantt,tickInterval:void 0,useWidth:void 0},c4:{...G.c4,useWidth:void 0,personFont:f((function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}}),"personFont"),external_personFont:f((function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}}),"external_personFont"),systemFont:f((function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}}),"systemFont"),external_systemFont:f((function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}}),"external_systemFont"),system_dbFont:f((function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}}),"system_dbFont"),external_system_dbFont:f((function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}}),"external_system_dbFont"),system_queueFont:f((function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}}),"system_queueFont"),external_system_queueFont:f((function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}}),"external_system_queueFont"),containerFont:f((function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}}),"containerFont"),external_containerFont:f((function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}}),"external_containerFont"),container_dbFont:f((function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}}),"container_dbFont"),external_container_dbFont:f((function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}}),"external_container_dbFont"),container_queueFont:f((function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}}),"container_queueFont"),external_container_queueFont:f((function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}}),"external_container_queueFont"),componentFont:f((function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}}),"componentFont"),external_componentFont:f((function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}}),"external_componentFont"),component_dbFont:f((function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}}),"component_dbFont"),external_component_dbFont:f((function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}}),"external_component_dbFont"),component_queueFont:f((function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}}),"component_queueFont"),external_component_queueFont:f((function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}}),"external_component_queueFont"),boundaryFont:f((function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}}),"boundaryFont"),messageFont:f((function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}}),"messageFont")},pie:{...G.pie,useWidth:984},xyChart:{...G.xyChart,useWidth:void 0},requirement:{...G.requirement,useWidth:void 0},packet:{...G.packet},radar:{...G.radar}},q=f(((t,e="")=>Object.keys(t).reduce(((n,r)=>Array.isArray(t[r])?n:"object"==typeof t[r]&&null!==t[r]?[...n,e+r,...q(t[r],"")]:[...n,e+r]),[])),"keyify"),j=new Set(q(V,"")),H=V,X=f((t=>{if(v.debug("sanitizeDirective called with",t),"object"==typeof t&&null!=t)if(Array.isArray(t))t.forEach((t=>X(t)));else{for(const e of Object.keys(t)){if(v.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!j.has(e)||null==t[e]){v.debug("sanitize deleting key: ",e),delete t[e];continue}if("object"==typeof t[e]){v.debug("sanitizing object",e),X(t[e]);continue}const n=["themeCSS","fontFamily","altFontFamily"];for(const r of n)e.includes(r)&&(v.debug("sanitizing css option",e),t[e]=K(t[e]))}if(t.themeVariables)for(const e of Object.keys(t.themeVariables)){const n=t.themeVariables[e];n?.match&&!n.match(/^[\d "#%(),.;A-Za-z]+$/)&&(t.themeVariables[e]="")}v.debug("After sanitization",t)}}),"sanitizeDirective"),K=f((t=>{let e=0,n=0;for(const r of t){if(e{let n=N({},t),r={};for(const t of e)ct(t),r=N(r,t);if(n=N(n,r),r.theme&&r.theme in U){const t=N({},c),e=N(t.themeVariables||{},r.themeVariables);n.theme&&n.theme in U&&(n.themeVariables=U[n.theme].getThemeVariables(e))}return ft(et=n),et}),"updateCurrentConfig"),rt=f((t=>(J=N({},Q),J=N(J,t),t.theme&&U[t.theme]&&(J.themeVariables=U[t.theme].getThemeVariables(t.themeVariables)),nt(J,tt),J)),"setSiteConfig"),it=f((t=>{c=N({},t)}),"saveConfigFromInitialize"),at=f((t=>(J=N(J,t),nt(J,tt),J)),"updateSiteConfig"),st=f((()=>N({},J)),"getSiteConfig"),ot=f((t=>(ft(t),N(et,t),lt())),"setConfig"),lt=f((()=>N({},et)),"getConfig"),ct=f((t=>{t&&(["secure",...J.secure??[]].forEach((e=>{Object.hasOwn(t,e)&&(v.debug(`Denied attempt to modify a secure key ${e}`,t[e]),delete t[e])})),Object.keys(t).forEach((e=>{e.startsWith("__")&&delete t[e]})),Object.keys(t).forEach((e=>{"string"==typeof t[e]&&(t[e].includes("<")||t[e].includes(">")||t[e].includes("url(data:"))&&delete t[e],"object"==typeof t[e]&&ct(t[e])})))}),"sanitize"),ht=f((t=>{X(t),t.fontFamily&&!t.themeVariables?.fontFamily&&(t.themeVariables={...t.themeVariables,fontFamily:t.fontFamily}),tt.push(t),nt(J,tt)}),"addDirective"),ut=f(((t=J)=>{nt(t,tt=[])}),"reset"),dt={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},pt={},gt=f((t=>{pt[t]||(v.warn(dt[t]),pt[t]=!0)}),"issueWarning"),ft=f((t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&>("LAZY_LOAD_DEPRECATED")}),"checkConfig"),mt=//gi,yt=f((t=>t?Ct(t).replace(/\\n/g,"#br#").split("#br#"):[""]),"getRows"),vt=(()=>{let t=!1;return()=>{t||(xt(),t=!0)}})();function xt(){const t="data-temp-href-target";p.Z.addHook("beforeSanitizeAttributes",(e=>{e instanceof Element&&"A"===e.tagName&&e.hasAttribute("target")&&e.setAttribute(t,e.getAttribute("target")??"")})),p.Z.addHook("afterSanitizeAttributes",(e=>{e instanceof Element&&"A"===e.tagName&&e.hasAttribute(t)&&(e.setAttribute("target",e.getAttribute(t)??""),e.removeAttribute(t),"_blank"===e.getAttribute("target")&&e.setAttribute("rel","noopener"))}))}f(xt,"setupDompurifyHooks");var bt=f((t=>(vt(),p.Z.sanitize(t))),"removeScript"),wt=f(((t,e)=>{if(!1!==e.flowchart?.htmlLabels){const n=e.securityLevel;"antiscript"===n||"strict"===n?t=bt(t):"loose"!==n&&(t=(t=(t=Ct(t)).replace(//g,">")).replace(/=/g,"="),t=St(t))}return t}),"sanitizeMore"),kt=f(((t,e)=>t?t=e.dompurifyConfig?p.Z.sanitize(wt(t,e),e.dompurifyConfig).toString():p.Z.sanitize(wt(t,e),{FORBID_TAGS:["style"]}).toString():t),"sanitizeText"),Tt=f(((t,e)=>"string"==typeof t?kt(t,e):t.flat().map((t=>kt(t,e)))),"sanitizeTextOrArray"),_t=f((t=>mt.test(t)),"hasBreaks"),Et=f((t=>t.split(mt)),"splitBreaks"),St=f((t=>t.replace(/#br#/g,"
    ")),"placeholderToBreak"),Ct=f((t=>t.replace(mt,"#br#")),"breakToPlaceholder"),At=f((t=>{let e="";return t&&(e=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,e=e.replaceAll(/\(/g,"\\("),e=e.replaceAll(/\)/g,"\\)")),e}),"getUrl"),Lt=f((t=>!1!==t&&!["false","null","0"].includes(String(t).trim().toLowerCase())),"evaluate"),Mt=f((function(...t){const e=t.filter((t=>!isNaN(t)));return Math.max(...e)}),"getMax"),Nt=f((function(...t){const e=t.filter((t=>!isNaN(t)));return Math.min(...e)}),"getMin"),It=f((function(t){const e=t.split(/(,)/),n=[];for(let t=0;t0&&t+1Math.max(0,t.split(e).length-1)),"countOccurrence"),Dt=f(((t,e)=>{const n=Rt(t,"~"),r=Rt(e,"~");return 1===n&&1===r}),"shouldCombineSets"),Ot=f((t=>{const e=Rt(t,"~");let n=!1;if(e<=1)return t;e%2!=0&&t.startsWith("~")&&(t=t.substring(1),n=!0);const r=[...t];let i=r.indexOf("~"),a=r.lastIndexOf("~");for(;-1!==i&&-1!==a&&i!==a;)r[i]="<",r[a]=">",i=r.indexOf("~"),a=r.lastIndexOf("~");return n&&r.unshift("~"),r.join("")}),"processSet"),Pt=f((()=>void 0!==window.MathMLElement),"isMathMLSupported"),$t=/\$\$(.*)\$\$/g,Bt=f((t=>(t.match($t)?.length??0)>0),"hasKatex"),Ft=f((async(t,e)=>{t=await Wt(t,e);const n=document.createElement("div");n.innerHTML=t,n.id="katex-temp",n.style.visibility="hidden",n.style.position="absolute",n.style.top="0";const r=document.querySelector("body");r?.insertAdjacentElement("beforeend",n);const i={width:n.clientWidth,height:n.clientHeight};return n.remove(),i}),"calculateMathMLDimensions"),Wt=f((async(t,e)=>{if(!Bt(t))return t;if(!(Pt()||e.legacyMathML||e.forceLegacyMathML))return t.replace($t,"MathML is unsupported in this environment.");const{default:r}=await Promise.resolve().then(n.bind(n,4433)),i=e.forceLegacyMathML||!Pt()&&e.legacyMathML?"htmlAndMathml":"mathml";return t.split(mt).map((t=>Bt(t)?`
    ${t}
    `:`
    ${t}
    `)).join("").replace($t,((t,e)=>r.renderToString(e,{throwOnError:!0,displayMode:!0,output:i}).replace(/\n/g," ").replace(//g,"")))}),"renderKatex"),zt={getRows:yt,sanitizeText:kt,sanitizeTextOrArray:Tt,hasBreaks:_t,splitBreaks:Et,lineBreakRegex:mt,removeScript:bt,getUrl:At,evaluate:Lt,getMax:Mt,getMin:Nt},Zt=f((function(t,e){for(let n of e)t.attr(n[0],n[1])}),"d3Attrs"),Yt=f((function(t,e,n){let r=new Map;return n?(r.set("width","100%"),r.set("style",`max-width: ${e}px;`)):(r.set("height",t),r.set("width",e)),r}),"calculateSvgSizeAttrs"),Ut=f((function(t,e,n,r){const i=Yt(e,n,r);Zt(t,i)}),"configureSvgSize"),Gt=f((function(t,e,n,r){const i=e.node().getBBox(),a=i.width,s=i.height;v.info(`SVG bounds: ${a}x${s}`,i);let o=0,l=0;v.info(`Graph bounds: ${o}x${l}`,t),o=a+2*n,l=s+2*n,v.info(`Calculated bounds: ${o}x${l}`),Ut(e,l,o,r);const c=`${i.x-n} ${i.y-n} ${i.width+2*n} ${i.height+2*n}`;e.attr("viewBox",c)}),"setupGraphViewbox"),Vt={},qt=f(((t,e,n)=>{let r="";return t in Vt&&Vt[t]?r=Vt[t](n):v.warn(`No theme found for ${t}`),` & {\n font-family: ${n.fontFamily};\n font-size: ${n.fontSize};\n fill: ${n.textColor}\n }\n @keyframes edge-animation-frame {\n from {\n stroke-dashoffset: 0;\n }\n }\n @keyframes dash {\n to {\n stroke-dashoffset: 0;\n }\n }\n & .edge-animation-slow {\n stroke-dasharray: 9,5 !important;\n stroke-dashoffset: 900;\n animation: dash 50s linear infinite;\n stroke-linecap: round;\n }\n & .edge-animation-fast {\n stroke-dasharray: 9,5 !important;\n stroke-dashoffset: 900;\n animation: dash 20s linear infinite;\n stroke-linecap: round;\n }\n /* Classes common for multiple diagrams */\n\n & .error-icon {\n fill: ${n.errorBkgColor};\n }\n & .error-text {\n fill: ${n.errorTextColor};\n stroke: ${n.errorTextColor};\n }\n\n & .edge-thickness-normal {\n stroke-width: 1px;\n }\n & .edge-thickness-thick {\n stroke-width: 3.5px\n }\n & .edge-pattern-solid {\n stroke-dasharray: 0;\n }\n & .edge-thickness-invisible {\n stroke-width: 0;\n fill: none;\n }\n & .edge-pattern-dashed{\n stroke-dasharray: 3;\n }\n .edge-pattern-dotted {\n stroke-dasharray: 2;\n }\n\n & .marker {\n fill: ${n.lineColor};\n stroke: ${n.lineColor};\n }\n & .marker.cross {\n stroke: ${n.lineColor};\n }\n\n & svg {\n font-family: ${n.fontFamily};\n font-size: ${n.fontSize};\n }\n & p {\n margin: 0\n }\n\n ${r}\n\n ${e}\n`}),"getStyles"),jt=f(((t,e)=>{void 0!==e&&(Vt[t]=e)}),"addStylesForDiagram"),Ht=qt,Xt={};m(Xt,{clear:()=>ee,getAccDescription:()=>ae,getAccTitle:()=>re,getDiagramTitle:()=>oe,setAccDescription:()=>ie,setAccTitle:()=>ne,setDiagramTitle:()=>se});var Kt="",Qt="",Jt="",te=f((t=>kt(t,lt())),"sanitizeText"),ee=f((()=>{Kt="",Jt="",Qt=""}),"clear"),ne=f((t=>{Kt=te(t).replace(/^\s+/g,"")}),"setAccTitle"),re=f((()=>Kt),"getAccTitle"),ie=f((t=>{Jt=te(t).replace(/\n\s+/g,"\n")}),"setAccDescription"),ae=f((()=>Jt),"getAccDescription"),se=f((t=>{Qt=te(t)}),"setDiagramTitle"),oe=f((()=>Qt),"getDiagramTitle"),le=v,ce=x,he=lt,ue=ot,de=Q,pe=f((t=>kt(t,he())),"sanitizeText"),ge=Gt,fe=f((()=>Xt),"getCommonDb"),me={},ye=f(((t,e,n)=>{me[t]&&le.warn(`Diagram with id ${t} already registered. Overwriting.`),me[t]=e,n&&A(t,n),jt(t,e.styles),e.injectUtils?.(le,ce,he,pe,ge,fe(),(()=>{}))}),"registerDiagram"),ve=f((t=>{if(t in me)return me[t];throw new xe(t)}),"getDiagram"),xe=class extends Error{static{f(this,"DiagramNotFoundError")}constructor(t){super(`Diagram ${t} not found.`)}}},5635:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>a});var r=n(762),i=(n(907),n(8337),n(1566),n(5179),n(3583),n(1426),n(6241),n(214),n(7946),n(4082)),a={parser:r.P0,get db(){return new r.dR},renderer:r.b0,styles:r.Ee,init:(0,i.eW)((t=>{t.class||(t.class={}),t.class.arrowMarkerAbsolute=t.arrowMarkerAbsolute}),"init")}},9876:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>a});var r=n(762),i=(n(907),n(8337),n(1566),n(5179),n(3583),n(1426),n(6241),n(214),n(7946),n(4082)),a={parser:r.P0,get db(){return new r.dR},renderer:r.b0,styles:r.Ee,init:(0,i.eW)((t=>{t.class||(t.class={}),t.class.arrowMarkerAbsolute=t.arrowMarkerAbsolute}),"init")}},5255:(t,e,n)=>{"use strict";n.r(e),n.d(e,{render:()=>N});var r=n(1566),i=(n(5179),n(3583)),a=n(1426),s=(n(6241),n(214),n(7946),n(4082)),o=n(4840),l=n(9360),c=n(2346),h=n(3836);function u(t){var e={options:{directed:t.isDirected(),multigraph:t.isMultigraph(),compound:t.isCompound()},nodes:d(t),edges:p(t)};return l.Z(t.graph())||(e.value=c.Z(t.graph())),e}function d(t){return h.Z(t.nodes(),(function(e){var n=t.node(e),r=t.parent(e),i={v:e};return l.Z(n)||(i.value=n),l.Z(r)||(i.parent=r),i}))}function p(t){return h.Z(t.edges(),(function(e){var n=t.edge(e),r={v:e.v,w:e.w};return l.Z(e.name)||(r.name=e.name),l.Z(n)||(r.value=n),r}))}n(7556);var g=n(5625),f=new Map,m=new Map,y=new Map,v=(0,s.eW)((()=>{m.clear(),y.clear(),f.clear()}),"clear"),x=(0,s.eW)(((t,e)=>{const n=m.get(e)||[];return s.cM.trace("In isDescendant",e," ",t," = ",n.includes(t)),n.includes(t)}),"isDescendant"),b=(0,s.eW)(((t,e)=>{const n=m.get(e)||[];return s.cM.info("Descendants of ",e," is ",n),s.cM.info("Edge is ",t),t.v!==e&&t.w!==e&&(n?n.includes(t.v)||x(t.v,e)||x(t.w,e)||n.includes(t.w):(s.cM.debug("Tilt, ",e,",not in descendants"),!1))}),"edgeInCluster"),w=(0,s.eW)(((t,e,n,r)=>{s.cM.warn("Copying children of ",t,"root",r,"data",e.node(t),r);const i=e.children(t)||[];t!==r&&i.push(t),s.cM.warn("Copying (nodes) clusterId",t,"nodes",i),i.forEach((i=>{if(e.children(i).length>0)w(i,e,n,r);else{const a=e.node(i);s.cM.info("cp ",i," to ",r," with parent ",t),n.setNode(i,a),r!==e.parent(i)&&(s.cM.warn("Setting parent",i,e.parent(i)),n.setParent(i,e.parent(i))),t!==r&&i!==t?(s.cM.debug("Setting parent",i,t),n.setParent(i,t)):(s.cM.info("In copy ",t,"root",r,"data",e.node(t),r),s.cM.debug("Not Setting parent for node=",i,"cluster!==rootId",t!==r,"node!==clusterId",i!==t));const o=e.edges(i);s.cM.debug("Copying Edges",o),o.forEach((i=>{s.cM.info("Edge",i);const a=e.edge(i.v,i.w,i.name);s.cM.info("Edge data",a,r);try{b(i,r)?(s.cM.info("Copying as ",i.v,i.w,a,i.name),n.setEdge(i.v,i.w,a,i.name),s.cM.info("newGraph edges ",n.edges(),n.edge(n.edges()[0]))):s.cM.info("Skipping copy of edge ",i.v,"--\x3e",i.w," rootId: ",r," clusterId:",t)}catch(t){s.cM.error(t)}}))}s.cM.debug("Removing node",i),e.removeNode(i)}))}),"copy"),k=(0,s.eW)(((t,e)=>{const n=e.children(t);let r=[...n];for(const i of n)y.set(i,t),r=[...r,...k(i,e)];return r}),"extractDescendants"),T=(0,s.eW)(((t,e,n)=>{const r=t.edges().filter((t=>t.v===e||t.w===e)),i=t.edges().filter((t=>t.v===n||t.w===n)),a=r.map((t=>({v:t.v===e?n:t.v,w:t.w===e?e:t.w}))),s=i.map((t=>({v:t.v,w:t.w})));return a.filter((t=>s.some((e=>t.v===e.v&&t.w===e.w))))}),"findCommonEdges"),_=(0,s.eW)(((t,e,n)=>{const r=e.children(t);if(s.cM.trace("Searching children of id ",t,r),r.length<1)return t;let i;for(const t of r){const r=_(t,e,n),a=T(e,n,r);if(r){if(!(a.length>0))return r;i=r}}return i}),"findNonClusterChild"),E=(0,s.eW)((t=>f.has(t)&&f.get(t).externalConnections&&f.has(t)?f.get(t).id:t),"getAnchorId"),S=(0,s.eW)(((t,e)=>{if(!t||e>10)s.cM.debug("Opting out, no graph ");else{s.cM.debug("Opting in, graph "),t.nodes().forEach((function(e){t.children(e).length>0&&(s.cM.warn("Cluster identified",e," Replacement id in edges: ",_(e,t,e)),m.set(e,k(e,t)),f.set(e,{id:_(e,t,e),clusterData:t.node(e)}))})),t.nodes().forEach((function(e){const n=t.children(e),r=t.edges();n.length>0?(s.cM.debug("Cluster identified",e,m),r.forEach((t=>{x(t.v,e)^x(t.w,e)&&(s.cM.warn("Edge: ",t," leaves cluster ",e),s.cM.warn("Descendants of XXX ",e,": ",m.get(e)),f.get(e).externalConnections=!0)}))):s.cM.debug("Not a cluster ",e,m)}));for(let e of f.keys()){const n=f.get(e).id,r=t.parent(n);r!==e&&f.has(r)&&!f.get(r).externalConnections&&(f.get(e).id=r)}t.edges().forEach((function(e){const n=t.edge(e);s.cM.warn("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(e)),s.cM.warn("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(t.edge(e)));let r=e.v,i=e.w;if(s.cM.warn("Fix XXX",f,"ids:",e.v,e.w,"Translating: ",f.get(e.v)," --- ",f.get(e.w)),f.get(e.v)||f.get(e.w)){if(s.cM.warn("Fixing and trying - removing XXX",e.v,e.w,e.name),r=E(e.v),i=E(e.w),t.removeEdge(e.v,e.w,e.name),r!==e.v){const i=t.parent(r);f.get(i).externalConnections=!0,n.fromCluster=e.v}if(i!==e.w){const r=t.parent(i);f.get(r).externalConnections=!0,n.toCluster=e.w}s.cM.warn("Fix Replacing with XXX",r,i,e.name),t.setEdge(r,i,n,e.name)}})),s.cM.warn("Adjusted Graph",u(t)),C(t,0),s.cM.trace(f)}}),"adjustClustersAndEdges"),C=(0,s.eW)(((t,e)=>{if(s.cM.warn("extractor - ",e,u(t),t.children("D")),e>10)return void s.cM.error("Bailing out");let n=t.nodes(),r=!1;for(const e of n){const n=t.children(e);r=r||n.length>0}if(r){s.cM.debug("Nodes = ",n,e);for(const r of n)if(s.cM.debug("Extracting node",r,f,f.has(r)&&!f.get(r).externalConnections,!t.parent(r),t.node(r),t.children("D")," Depth ",e),f.has(r))if(!f.get(r).externalConnections&&t.children(r)&&t.children(r).length>0){s.cM.warn("Cluster without external connections, without a parent and with children",r,e);let n="TB"===t.graph().rankdir?"LR":"TB";f.get(r)?.clusterData?.dir&&(n=f.get(r).clusterData.dir,s.cM.warn("Fixing dir",f.get(r).clusterData.dir,n));const i=new g.k({multigraph:!0,compound:!0}).setGraph({rankdir:n,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}}));s.cM.warn("Old graph before copy",u(t)),w(r,t,i,r),t.setNode(r,{clusterNode:!0,id:r,clusterData:f.get(r).clusterData,label:f.get(r).label,graph:i}),s.cM.warn("New graph after copy node: (",r,")",u(i)),s.cM.debug("Old graph after copy",u(t))}else s.cM.warn("Cluster ** ",r," **not meeting the criteria !externalConnections:",!f.get(r).externalConnections," no parent: ",!t.parent(r)," children ",t.children(r)&&t.children(r).length>0,t.children("D"),e),s.cM.debug(f);else s.cM.debug("Not a cluster",r,e);n=t.nodes(),s.cM.warn("New list of nodes",n);for(const r of n){const n=t.node(r);s.cM.warn(" Now next level",r,n),n?.clusterNode&&C(n.graph,e+1)}}else s.cM.debug("Done, no node has children",t.nodes())}),"extractor"),A=(0,s.eW)(((t,e)=>{if(0===e.length)return[];let n=Object.assign([],e);return e.forEach((e=>{const r=t.children(e),i=A(t,r);n=[...n,...i]})),n}),"sorter"),L=(0,s.eW)((t=>A(t,t.children())),"sortNodesByHierarchy"),M=(0,s.eW)((async(t,e,n,l,c,h)=>{s.cM.warn("Graph in recursive render:XAX",u(e),c);const d=e.graph().rankdir;s.cM.trace("Dir in recursive render - dir:",d);const p=t.insert("g").attr("class","root");e.nodes()?s.cM.info("Recursive render XXX",e.nodes()):s.cM.info("No nodes found for",e),e.edges().length>0&&s.cM.info("Recursive edges",e.edge(e.edges()[0]));const g=p.insert("g").attr("class","clusters"),m=p.insert("g").attr("class","edgePaths"),y=p.insert("g").attr("class","edgeLabels"),v=p.insert("g").attr("class","nodes");await Promise.all(e.nodes().map((async function(t){const r=e.node(t);if(void 0!==c){const n=JSON.parse(JSON.stringify(c.clusterData));s.cM.trace("Setting data for parent cluster XXX\n Node.id = ",t,"\n data=",n.height,"\nParent cluster",c.height),e.setNode(c.id,n),e.parent(t)||(s.cM.trace("Setting parent",t,c.id),e.setParent(t,c.id,n))}if(s.cM.info("(Insert) Node XXX"+t+": "+JSON.stringify(e.node(t))),r?.clusterNode){s.cM.info("Cluster identified XBX",t,r.width,e.node(t));const{ranksep:a,nodesep:o}=e.graph();r.graph.setGraph({...r.graph.graph(),ranksep:a+25,nodesep:o});const c=await M(v,r.graph,n,l,e.node(t),h),u=c.elem;(0,i.jr)(r,u),r.diff=c.diff||0,s.cM.info("New compound node after recursive render XAX",t,"width",r.width,"height",r.height),(0,i.Yn)(u,r)}else e.children(t).length>0?(s.cM.trace("Cluster - the non recursive path XBX",t,r.id,r,r.width,"Graph:",e),s.cM.trace(_(r.id,e)),f.set(r.id,{id:_(r.id,e),node:r})):(s.cM.trace("Node - the non recursive path XAX",t,v,e.node(t),d),await(0,i.Lf)(v,e.node(t),{config:h,dir:d}))})));const x=(0,s.eW)((async()=>{const t=e.edges().map((async function(t){const n=e.edge(t.v,t.w,t.name);s.cM.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(t)),s.cM.info("Edge "+t.v+" -> "+t.w+": ",t," ",JSON.stringify(e.edge(t))),s.cM.info("Fix",f,"ids:",t.v,t.w,"Translating: ",f.get(t.v),f.get(t.w)),await(0,r.I_)(y,n)}));await Promise.all(t)}),"processEdges");await x(),s.cM.info("Graph before layout:",JSON.stringify(u(e))),s.cM.info("############################################# XXX"),s.cM.info("### Layout ### XXX"),s.cM.info("############################################# XXX"),(0,o.bK)(e),s.cM.info("Graph after layout:",JSON.stringify(u(e)));let b=0,{subGraphTitleTotalMargin:w}=(0,a.L)(h);return await Promise.all(L(e).map((async function(t){const n=e.node(t);if(s.cM.info("Position XBX => "+t+": ("+n.x,","+n.y,") width: ",n.width," height: ",n.height),n?.clusterNode)n.y+=w,s.cM.info("A tainted cluster node XBX1",t,n.id,n.width,n.height,n.x,n.y,e.parent(t)),f.get(n.id).node=n,(0,i.aH)(n);else if(e.children(t).length>0){s.cM.info("A pure cluster node XBX1",t,n.id,n.x,n.y,n.width,n.height,e.parent(t)),n.height+=w,e.node(n.parentId);const r=n?.padding/2||0,a=n?.labelBBox?.height||0,o=a-r||0;s.cM.debug("OffsetY",o,"labelHeight",a,"halfPadding",r),await(0,i.us)(g,n),f.get(n.id).node=n}else{const t=e.node(n.parentId);n.y+=w/2,s.cM.info("A regular node XBX1 - using the padding",n.id,"parent",n.parentId,n.width,n.height,n.x,n.y,"offsetY",n.offsetY,"parent",t,t?.offsetY,n),(0,i.aH)(n)}}))),e.edges().forEach((function(t){const i=e.edge(t);s.cM.info("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(i),i),i.points.forEach((t=>t.y+=w/2));const a=e.node(t.v);var o=e.node(t.w);const c=(0,r.QP)(m,i,f,n,a,o,l);(0,r.Jj)(i,c)})),e.nodes().forEach((function(t){const n=e.node(t);s.cM.info(t,n.type,n.diff),n.isGroup&&(b=n.diff)})),s.cM.warn("Returning from recursive render XAX",p,b),{elem:p,diff:b}}),"recursiveRender"),N=(0,s.eW)((async(t,e)=>{const n=new g.k({multigraph:!0,compound:!0}).setGraph({rankdir:t.direction,nodesep:t.config?.nodeSpacing||t.config?.flowchart?.nodeSpacing||t.nodeSpacing,ranksep:t.config?.rankSpacing||t.config?.flowchart?.rankSpacing||t.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel((function(){return{}})),a=e.select("g");(0,r.DQ)(a,t.markers,t.type,t.diagramId),(0,i.gU)(),(0,r.ZH)(),(0,i.ZH)(),v(),t.nodes.forEach((t=>{n.setNode(t.id,{...t}),t.parentId&&n.setParent(t.id,t.parentId)})),s.cM.debug("Edges:",t.edges),t.edges.forEach((t=>{if(t.start===t.end){const e=t.start,r=e+"---"+e+"---1",i=e+"---"+e+"---2",a=n.node(e);n.setNode(r,{domId:r,id:r,parentId:a.parentId,labelStyle:"",label:"",padding:0,shape:"labelRect",style:"",width:10,height:10}),n.setParent(r,a.parentId),n.setNode(i,{domId:i,id:i,parentId:a.parentId,labelStyle:"",padding:0,shape:"labelRect",label:"",style:"",width:10,height:10}),n.setParent(i,a.parentId);const s=structuredClone(t),o=structuredClone(t),l=structuredClone(t);s.label="",s.arrowTypeEnd="none",s.id=e+"-cyclic-special-1",o.arrowTypeStart="none",o.arrowTypeEnd="none",o.id=e+"-cyclic-special-mid",l.label="",a.isGroup&&(s.fromCluster=e,l.toCluster=e),l.id=e+"-cyclic-special-2",l.arrowTypeStart="none",n.setEdge(e,r,s,e+"-cyclic-special-0"),n.setEdge(r,i,o,e+"-cyclic-special-1"),n.setEdge(i,e,l,e+"-cyc{"use strict";n.d(e,{diagram:()=>R});var r=n(1957),i=n(7946),a=n(5430),s=n(4082),o=n(2491),l={showLegend:!0,ticks:5,max:null,min:0,graticule:"circle"},c={axes:[],curves:[],options:l},h=structuredClone(c),u=s.vZ.radar,d=(0,s.eW)((()=>(0,i.Rb)({...u,...(0,s.iE)().radar})),"getConfig"),p=(0,s.eW)((()=>h.axes),"getAxes"),g=(0,s.eW)((()=>h.curves),"getCurves"),f=(0,s.eW)((()=>h.options),"getOptions"),m=(0,s.eW)((t=>{h.axes=t.map((t=>({name:t.name,label:t.label??t.name})))}),"setAxes"),y=(0,s.eW)((t=>{h.curves=t.map((t=>({name:t.name,label:t.label??t.name,entries:v(t.entries)})))}),"setCurves"),v=(0,s.eW)((t=>{if(null==t[0].axis)return t.map((t=>t.value));const e=p();if(0===e.length)throw new Error("Axes must be populated before curves for reference entries");return e.map((e=>{const n=t.find((t=>t.axis?.$refText===e.name));if(void 0===n)throw new Error("Missing entry for axis "+e.label);return n.value}))}),"computeCurveEntries"),x={getAxes:p,getCurves:g,getOptions:f,setAxes:m,setCurves:y,setOptions:(0,s.eW)((t=>{const e=t.reduce(((t,e)=>(t[e.name]=e,t)),{});h.options={showLegend:e.showLegend?.value??l.showLegend,ticks:e.ticks?.value??l.ticks,max:e.max?.value??l.max,min:e.min?.value??l.min,graticule:e.graticule?.value??l.graticule}}),"setOptions"),getConfig:d,clear:(0,s.eW)((()=>{(0,s.ZH)(),h=structuredClone(c)}),"clear"),setAccTitle:s.GN,getAccTitle:s.eu,setDiagramTitle:s.g2,getDiagramTitle:s.Kr,getAccDescription:s.Mx,setAccDescription:s.U$},b=(0,s.eW)((t=>{(0,r.A)(t,x);const{axes:e,curves:n,options:i}=t;x.setAxes(e),x.setCurves(n),x.setOptions(i)}),"populate"),w={parse:(0,s.eW)((async t=>{const e=await(0,o.Qc)("radar",t);s.cM.debug(e),b(e)}),"parse")},k=(0,s.eW)(((t,e,n,r)=>{const i=r.db,s=i.getAxes(),o=i.getCurves(),l=i.getOptions(),c=i.getConfig(),h=i.getDiagramTitle(),u=(0,a.P)(e),d=T(u,c),p=l.max??Math.max(...o.map((t=>Math.max(...t.entries)))),g=l.min,f=Math.min(c.width,c.height)/2;_(d,s,f,l.ticks,l.graticule),E(d,s,f,c),S(d,s,o,g,p,l.graticule,c),L(d,o,l.showLegend,c),d.append("text").attr("class","radarTitle").text(h).attr("x",0).attr("y",-c.height/2-c.marginTop)}),"draw"),T=(0,s.eW)(((t,e)=>{const n=e.width+e.marginLeft+e.marginRight,r=e.height+e.marginTop+e.marginBottom,i=e.marginLeft+e.width/2,a=e.marginTop+e.height/2;return t.attr("viewbox",`0 0 ${n} ${r}`).attr("width",n).attr("height",r),t.append("g").attr("transform",`translate(${i}, ${a})`)}),"drawFrame"),_=(0,s.eW)(((t,e,n,r,i)=>{if("circle"===i)for(let e=0;e{const n=2*e*Math.PI/i-Math.PI/2;return`${s*Math.cos(n)},${s*Math.sin(n)}`})).join(" ");t.append("polygon").attr("points",o).attr("class","radarGraticule")}}}),"drawGraticule"),E=(0,s.eW)(((t,e,n,r)=>{const i=e.length;for(let a=0;a{if(e.entries.length!==o)return;const c=e.entries.map(((t,e)=>{const n=2*Math.PI*e/o-Math.PI/2,a=C(t,r,i,l);return{x:a*Math.cos(n),y:a*Math.sin(n)}}));"circle"===a?t.append("path").attr("d",A(c,s.curveTension)).attr("class",`radarCurve-${n}`):"polygon"===a&&t.append("polygon").attr("points",c.map((t=>`${t.x},${t.y}`)).join(" ")).attr("class",`radarCurve-${n}`)}))}function C(t,e,n,r){return r*(Math.min(Math.max(t,e),n)-e)/(n-e)}function A(t,e){const n=t.length;let r=`M${t[0].x},${t[0].y}`;for(let i=0;i{const r=t.append("g").attr("transform",`translate(${i}, ${a+20*n})`);r.append("rect").attr("width",12).attr("height",12).attr("class",`radarLegendBox-${n}`),r.append("text").attr("x",16).attr("y",0).attr("class","radarLegendText").text(e.label)}))}(0,s.eW)(S,"drawCurves"),(0,s.eW)(C,"relativeRadius"),(0,s.eW)(A,"closedRoundCurve"),(0,s.eW)(L,"drawLegend");var M={draw:k},N=(0,s.eW)(((t,e)=>{let n="";for(let r=0;r{const e=(0,s.xN)(),n=(0,s.iE)(),r=(0,i.Rb)(e,n.themeVariables);return{themeVariables:r,radarOptions:(0,i.Rb)(r.radar,t)}}),"buildRadarStyleOptions"),R={parser:w,db:x,renderer:M,styles:(0,s.eW)((({radar:t}={})=>{const{themeVariables:e,radarOptions:n}=I(t);return`\n\t.radarTitle {\n\t\tfont-size: ${e.fontSize};\n\t\tcolor: ${e.titleColor};\n\t\tdominant-baseline: hanging;\n\t\ttext-anchor: middle;\n\t}\n\t.radarAxisLine {\n\t\tstroke: ${n.axisColor};\n\t\tstroke-width: ${n.axisStrokeWidth};\n\t}\n\t.radarAxisLabel {\n\t\tdominant-baseline: middle;\n\t\ttext-anchor: middle;\n\t\tfont-size: ${n.axisLabelFontSize}px;\n\t\tcolor: ${n.axisColor};\n\t}\n\t.radarGraticule {\n\t\tfill: ${n.graticuleColor};\n\t\tfill-opacity: ${n.graticuleOpacity};\n\t\tstroke: ${n.graticuleColor};\n\t\tstroke-width: ${n.graticuleStrokeWidth};\n\t}\n\t.radarLegendText {\n\t\ttext-anchor: start;\n\t\tfont-size: ${n.legendFontSize}px;\n\t\tdominant-baseline: hanging;\n\t}\n\t${N(e,n)}\n\t`}),"styles")}},4628:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>b});var r=n(1957),i=n(7946),a=n(5430),s=n(4082),o=n(2491),l={packet:[]},c=structuredClone(l),h=s.vZ.packet,u=(0,s.eW)((()=>{const t=(0,i.Rb)({...h,...(0,s.iE)().packet});return t.showBits&&(t.paddingY+=10),t}),"getConfig"),d=(0,s.eW)((()=>c.packet),"getPacket"),p={pushWord:(0,s.eW)((t=>{t.length>0&&c.packet.push(t)}),"pushWord"),getPacket:d,getConfig:u,clear:(0,s.eW)((()=>{(0,s.ZH)(),c=structuredClone(l)}),"clear"),setAccTitle:s.GN,getAccTitle:s.eu,setDiagramTitle:s.g2,getDiagramTitle:s.Kr,getAccDescription:s.Mx,setAccDescription:s.U$},g=(0,s.eW)((t=>{(0,r.A)(t,p);let e=-1,n=[],i=1;const{bitsPerRow:a}=p.getConfig();for(let{start:r,end:o,label:l}of t.blocks){if(o&&o{if(void 0===t.end&&(t.end=t.start),t.start>t.end)throw new Error(`Block start ${t.start} is greater than block end ${t.end}.`);return t.end+1<=e*n?[t,void 0]:[{start:t.start,end:e*n-1,label:t.label},{start:e*n,end:t.end,label:t.label}]}),"getNextFittingBlock"),m={parse:(0,s.eW)((async t=>{const e=await(0,o.Qc)("packet",t);s.cM.debug(e),g(e)}),"parse")},y=(0,s.eW)(((t,e,n,r)=>{const i=r.db,o=i.getConfig(),{rowHeight:l,paddingY:c,bitWidth:h,bitsPerRow:u}=o,d=i.getPacket(),p=i.getDiagramTitle(),g=l+c,f=g*(d.length+1)-(p?0:l),m=h*u+2,y=(0,a.P)(e);y.attr("viewbox",`0 0 ${m} ${f}`),(0,s.v2)(y,f,m,o.useMaxWidth);for(const[t,e]of d.entries())v(y,e,t,o);y.append("text").text(p).attr("x",m/2).attr("y",f-g/2).attr("dominant-baseline","middle").attr("text-anchor","middle").attr("class","packetTitle")}),"draw"),v=(0,s.eW)(((t,e,n,{rowHeight:r,paddingX:i,paddingY:a,bitWidth:s,bitsPerRow:o,showBits:l})=>{const c=t.append("g"),h=n*(r+a)+a;for(const t of e){const e=t.start%o*s+1,n=(t.end-t.start+1)*s-i;if(c.append("rect").attr("x",e).attr("y",h).attr("width",n).attr("height",r).attr("class","packetBlock"),c.append("text").attr("x",e+n/2).attr("y",h+r/2).attr("class","packetLabel").attr("dominant-baseline","middle").attr("text-anchor","middle").text(t.label),!l)continue;const a=t.end===t.start,u=h-2;c.append("text").attr("x",e+(a?n/2:0)).attr("y",u).attr("class","packetByte start").attr("dominant-baseline","auto").attr("text-anchor",a?"middle":"start").text(t.start),a||c.append("text").attr("x",e+n).attr("y",u).attr("class","packetByte end").attr("dominant-baseline","auto").attr("text-anchor","end").text(t.end)}}),"drawWord"),x={byteFontSize:"10px",startByteColor:"black",endByteColor:"black",labelColor:"black",labelFontSize:"12px",titleColor:"black",titleFontSize:"14px",blockStrokeColor:"black",blockStrokeWidth:"1",blockFillColor:"#efefef"},b={parser:m,db:p,renderer:{draw:y},styles:(0,s.eW)((({packet:t}={})=>{const e=(0,i.Rb)(x,t);return`\n\t.packetByte {\n\t\tfont-size: ${e.byteFontSize};\n\t}\n\t.packetByte.start {\n\t\tfill: ${e.startByteColor};\n\t}\n\t.packetByte.end {\n\t\tfill: ${e.endByteColor};\n\t}\n\t.packetLabel {\n\t\tfill: ${e.labelColor};\n\t\tfont-size: ${e.labelFontSize};\n\t}\n\t.packetTitle {\n\t\tfill: ${e.titleColor};\n\t\tfont-size: ${e.titleFontSize};\n\t}\n\t.packetBlock {\n\t\tstroke: ${e.blockStrokeColor};\n\t\tstroke-width: ${e.blockStrokeWidth};\n\t\tfill: ${e.blockFillColor};\n\t}\n\t`}),"styles")}},9640:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>m});var r=n(907),i=n(8337),a=(n(1566),n(5179),n(3583),n(1426),n(6241),n(214),n(7946)),s=n(4082),o=n(3108),l=n(9792),c=n(1117),h=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[6,8,10,22,24,26,28,33,34,35,36,37,40,43,44,50],n=[1,10],r=[1,11],i=[1,12],a=[1,13],o=[1,20],l=[1,21],c=[1,22],h=[1,23],u=[1,24],d=[1,19],p=[1,25],g=[1,26],f=[1,18],m=[1,33],y=[1,34],v=[1,35],x=[1,36],b=[1,37],w=[6,8,10,13,15,17,20,21,22,24,26,28,33,34,35,36,37,40,43,44,50,63,64,65,66,67],k=[1,42],T=[1,43],_=[1,52],E=[40,50,68,69],S=[1,63],C=[1,61],A=[1,58],L=[1,62],M=[1,64],N=[6,8,10,13,17,22,24,26,28,33,34,35,36,37,40,41,42,43,44,48,49,50,63,64,65,66,67],I=[63,64,65,66,67],R=[1,81],D=[1,80],O=[1,78],P=[1,79],$=[6,10,42,47],B=[6,10,13,41,42,47,48,49],F=[1,89],W=[1,88],z=[1,87],Z=[19,56],Y=[1,98],U=[1,97],G=[19,56,58,60],V={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,entityName:11,relSpec:12,COLON:13,role:14,STYLE_SEPARATOR:15,idList:16,BLOCK_START:17,attributes:18,BLOCK_STOP:19,SQS:20,SQE:21,title:22,title_value:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,direction:29,classDefStatement:30,classStatement:31,styleStatement:32,direction_tb:33,direction_bt:34,direction_rl:35,direction_lr:36,CLASSDEF:37,stylesOpt:38,separator:39,UNICODE_TEXT:40,STYLE_TEXT:41,COMMA:42,CLASS:43,STYLE:44,style:45,styleComponent:46,SEMI:47,NUM:48,BRKT:49,ENTITY_NAME:50,attribute:51,attributeType:52,attributeName:53,attributeKeyTypeList:54,attributeComment:55,ATTRIBUTE_WORD:56,attributeKeyType:57,",":58,ATTRIBUTE_KEY:59,COMMENT:60,cardinality:61,relType:62,ZERO_OR_ONE:63,ZERO_OR_MORE:64,ONE_OR_MORE:65,ONLY_ONE:66,MD_PARENT:67,NON_IDENTIFYING:68,IDENTIFYING:69,WORD:70,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",8:"SPACE",10:"NEWLINE",13:"COLON",15:"STYLE_SEPARATOR",17:"BLOCK_START",19:"BLOCK_STOP",20:"SQS",21:"SQE",22:"title",23:"title_value",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"direction_tb",34:"direction_bt",35:"direction_rl",36:"direction_lr",37:"CLASSDEF",40:"UNICODE_TEXT",41:"STYLE_TEXT",42:"COMMA",43:"CLASS",44:"STYLE",47:"SEMI",48:"NUM",49:"BRKT",50:"ENTITY_NAME",56:"ATTRIBUTE_WORD",58:",",59:"ATTRIBUTE_KEY",60:"COMMENT",63:"ZERO_OR_ONE",64:"ZERO_OR_MORE",65:"ONE_OR_MORE",66:"ONLY_ONE",67:"MD_PARENT",68:"NON_IDENTIFYING",69:"IDENTIFYING",70:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,5],[9,9],[9,7],[9,7],[9,4],[9,6],[9,3],[9,5],[9,1],[9,3],[9,7],[9,9],[9,6],[9,8],[9,4],[9,6],[9,2],[9,2],[9,2],[9,1],[9,1],[9,1],[9,1],[9,1],[29,1],[29,1],[29,1],[29,1],[30,4],[16,1],[16,1],[16,3],[16,3],[31,3],[32,4],[38,1],[38,3],[45,1],[45,2],[39,1],[39,1],[39,1],[46,1],[46,1],[46,1],[46,1],[11,1],[11,1],[18,1],[18,2],[51,2],[51,3],[51,3],[51,4],[52,1],[53,1],[54,1],[54,3],[57,1],[55,1],[12,3],[61,1],[61,1],[61,1],[61,1],[61,1],[62,1],[62,1],[14,1],[14,1],[14,1]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 1:break;case 2:case 6:case 7:this.$=[];break;case 3:a[o-1].push(a[o]),this.$=a[o-1];break;case 4:case 5:case 55:case 78:case 62:case 63:case 66:this.$=a[o];break;case 8:r.addEntity(a[o-4]),r.addEntity(a[o-2]),r.addRelationship(a[o-4],a[o],a[o-2],a[o-3]);break;case 9:r.addEntity(a[o-8]),r.addEntity(a[o-4]),r.addRelationship(a[o-8],a[o],a[o-4],a[o-5]),r.setClass([a[o-8]],a[o-6]),r.setClass([a[o-4]],a[o-2]);break;case 10:r.addEntity(a[o-6]),r.addEntity(a[o-2]),r.addRelationship(a[o-6],a[o],a[o-2],a[o-3]),r.setClass([a[o-6]],a[o-4]);break;case 11:r.addEntity(a[o-6]),r.addEntity(a[o-4]),r.addRelationship(a[o-6],a[o],a[o-4],a[o-5]),r.setClass([a[o-4]],a[o-2]);break;case 12:r.addEntity(a[o-3]),r.addAttributes(a[o-3],a[o-1]);break;case 13:r.addEntity(a[o-5]),r.addAttributes(a[o-5],a[o-1]),r.setClass([a[o-5]],a[o-3]);break;case 14:r.addEntity(a[o-2]);break;case 15:r.addEntity(a[o-4]),r.setClass([a[o-4]],a[o-2]);break;case 16:r.addEntity(a[o]);break;case 17:r.addEntity(a[o-2]),r.setClass([a[o-2]],a[o]);break;case 18:r.addEntity(a[o-6],a[o-4]),r.addAttributes(a[o-6],a[o-1]);break;case 19:r.addEntity(a[o-8],a[o-6]),r.addAttributes(a[o-8],a[o-1]),r.setClass([a[o-8]],a[o-3]);break;case 20:r.addEntity(a[o-5],a[o-3]);break;case 21:r.addEntity(a[o-7],a[o-5]),r.setClass([a[o-7]],a[o-2]);break;case 22:r.addEntity(a[o-3],a[o-1]);break;case 23:r.addEntity(a[o-5],a[o-3]),r.setClass([a[o-5]],a[o]);break;case 24:case 25:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 26:case 27:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 32:r.setDirection("TB");break;case 33:r.setDirection("BT");break;case 34:r.setDirection("RL");break;case 35:r.setDirection("LR");break;case 36:this.$=a[o-3],r.addClass(a[o-2],a[o-1]);break;case 37:case 38:case 56:case 64:case 43:this.$=[a[o]];break;case 39:case 40:this.$=a[o-2].concat([a[o]]);break;case 41:this.$=a[o-2],r.setClass(a[o-1],a[o]);break;case 42:this.$=a[o-3],r.addCssStyles(a[o-2],a[o-1]);break;case 44:case 65:a[o-2].push(a[o]),this.$=a[o-2];break;case 46:this.$=a[o-1]+a[o];break;case 54:case 76:case 77:case 67:this.$=a[o].replace(/"/g,"");break;case 57:a[o].push(a[o-1]),this.$=a[o];break;case 58:this.$={type:a[o-1],name:a[o]};break;case 59:this.$={type:a[o-2],name:a[o-1],keys:a[o]};break;case 60:this.$={type:a[o-2],name:a[o-1],comment:a[o]};break;case 61:this.$={type:a[o-3],name:a[o-2],keys:a[o-1],comment:a[o]};break;case 68:this.$={cardA:a[o],relType:a[o-1],cardB:a[o-2]};break;case 69:this.$=r.Cardinality.ZERO_OR_ONE;break;case 70:this.$=r.Cardinality.ZERO_OR_MORE;break;case 71:this.$=r.Cardinality.ONE_OR_MORE;break;case 72:this.$=r.Cardinality.ONLY_ONE;break;case 73:this.$=r.Cardinality.MD_PARENT;break;case 74:this.$=r.Identification.NON_IDENTIFYING;break;case 75:this.$=r.Identification.IDENTIFYING}}),"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:9,22:n,24:r,26:i,28:a,29:14,30:15,31:16,32:17,33:o,34:l,35:c,36:h,37:u,40:d,43:p,44:g,50:f},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:27,11:9,22:n,24:r,26:i,28:a,29:14,30:15,31:16,32:17,33:o,34:l,35:c,36:h,37:u,40:d,43:p,44:g,50:f},t(e,[2,5]),t(e,[2,6]),t(e,[2,16],{12:28,61:32,15:[1,29],17:[1,30],20:[1,31],63:m,64:y,65:v,66:x,67:b}),{23:[1,38]},{25:[1,39]},{27:[1,40]},t(e,[2,27]),t(e,[2,28]),t(e,[2,29]),t(e,[2,30]),t(e,[2,31]),t(w,[2,54]),t(w,[2,55]),t(e,[2,32]),t(e,[2,33]),t(e,[2,34]),t(e,[2,35]),{16:41,40:k,41:T},{16:44,40:k,41:T},{16:45,40:k,41:T},t(e,[2,4]),{11:46,40:d,50:f},{16:47,40:k,41:T},{18:48,19:[1,49],51:50,52:51,56:_},{11:53,40:d,50:f},{62:54,68:[1,55],69:[1,56]},t(E,[2,69]),t(E,[2,70]),t(E,[2,71]),t(E,[2,72]),t(E,[2,73]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),{13:S,38:57,41:C,42:A,45:59,46:60,48:L,49:M},t(N,[2,37]),t(N,[2,38]),{16:65,40:k,41:T,42:A},{13:S,38:66,41:C,42:A,45:59,46:60,48:L,49:M},{13:[1,67],15:[1,68]},t(e,[2,17],{61:32,12:69,17:[1,70],42:A,63:m,64:y,65:v,66:x,67:b}),{19:[1,71]},t(e,[2,14]),{18:72,19:[2,56],51:50,52:51,56:_},{53:73,56:[1,74]},{56:[2,62]},{21:[1,75]},{61:76,63:m,64:y,65:v,66:x,67:b},t(I,[2,74]),t(I,[2,75]),{6:R,10:D,39:77,42:O,47:P},{40:[1,82],41:[1,83]},t($,[2,43],{46:84,13:S,41:C,48:L,49:M}),t(B,[2,45]),t(B,[2,50]),t(B,[2,51]),t(B,[2,52]),t(B,[2,53]),t(e,[2,41],{42:A}),{6:R,10:D,39:85,42:O,47:P},{14:86,40:F,50:W,70:z},{16:90,40:k,41:T},{11:91,40:d,50:f},{18:92,19:[1,93],51:50,52:51,56:_},t(e,[2,12]),{19:[2,57]},t(Z,[2,58],{54:94,55:95,57:96,59:Y,60:U}),t([19,56,59,60],[2,63]),t(e,[2,22],{15:[1,100],17:[1,99]}),t([40,50],[2,68]),t(e,[2,36]),{13:S,41:C,45:101,46:60,48:L,49:M},t(e,[2,47]),t(e,[2,48]),t(e,[2,49]),t(N,[2,39]),t(N,[2,40]),t(B,[2,46]),t(e,[2,42]),t(e,[2,8]),t(e,[2,76]),t(e,[2,77]),t(e,[2,78]),{13:[1,102],42:A},{13:[1,104],15:[1,103]},{19:[1,105]},t(e,[2,15]),t(Z,[2,59],{55:106,58:[1,107],60:U}),t(Z,[2,60]),t(G,[2,64]),t(Z,[2,67]),t(G,[2,66]),{18:108,19:[1,109],51:50,52:51,56:_},{16:110,40:k,41:T},t($,[2,44],{46:84,13:S,41:C,48:L,49:M}),{14:111,40:F,50:W,70:z},{16:112,40:k,41:T},{14:113,40:F,50:W,70:z},t(e,[2,13]),t(Z,[2,61]),{57:114,59:Y},{19:[1,115]},t(e,[2,20]),t(e,[2,23],{17:[1,116],42:A}),t(e,[2,11]),{13:[1,117],42:A},t(e,[2,10]),t(G,[2,65]),t(e,[2,18]),{18:118,19:[1,119],51:50,52:51,56:_},{14:120,40:F,50:W,70:z},{19:[1,121]},t(e,[2,21]),t(e,[2,9]),t(e,[2,19])],defaultActions:{52:[2,62],72:[2,57]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},q=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:return this.begin("acc_title"),24;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),26;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return 33;case 8:return 34;case 9:return 35;case 10:return 36;case 11:return 10;case 12:case 23:case 28:case 35:break;case 13:return 8;case 14:return 50;case 15:return 70;case 16:return 4;case 17:return this.begin("block"),17;case 18:case 19:case 38:return 49;case 20:case 37:return 42;case 21:return 15;case 22:case 36:return 13;case 24:return 59;case 25:case 26:return 56;case 27:return 60;case 29:return this.popState(),19;case 30:case 73:return e.yytext[0];case 31:return 20;case 32:return 21;case 33:return this.begin("style"),44;case 34:return this.popState(),10;case 39:return this.begin("style"),37;case 40:return 43;case 41:case 45:case 46:case 59:return 63;case 42:case 43:case 44:case 52:case 54:case 61:return 65;case 47:case 48:case 49:case 50:case 51:case 53:case 60:return 64;case 55:case 56:case 57:case 58:return 66;case 62:return 67;case 63:case 66:case 67:case 68:return 68;case 64:case 65:return 69;case 69:return 41;case 70:return 47;case 71:return 40;case 72:return 48;case 74:return 6}}),"anonymous"),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:[\s]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\u00C0-\uFFFF\*]*))/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:1\b)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:\s*u\b)/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:[0-9])/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[34,35,36,37,38,69,70],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block:{rules:[23,24,25,26,27,28,29,30],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,31,32,33,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,71,72,73,74],inclusive:!0}}}}();function j(){this.yy={}}return V.lexer=q,(0,s.eW)(j,"Parser"),j.prototype=V,V.Parser=j,new j}();h.parser=h;var u=h,d=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.direction="TB",this.Cardinality={ZERO_OR_ONE:"ZERO_OR_ONE",ZERO_OR_MORE:"ZERO_OR_MORE",ONE_OR_MORE:"ONE_OR_MORE",ONLY_ONE:"ONLY_ONE",MD_PARENT:"MD_PARENT"},this.Identification={NON_IDENTIFYING:"NON_IDENTIFYING",IDENTIFYING:"IDENTIFYING"},this.setAccTitle=s.GN,this.getAccTitle=s.eu,this.setAccDescription=s.U$,this.getAccDescription=s.Mx,this.setDiagramTitle=s.g2,this.getDiagramTitle=s.Kr,this.getConfig=(0,s.eW)((()=>(0,s.nV)().er),"getConfig"),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{(0,s.eW)(this,"ErDB")}addEntity(t,e=""){return this.entities.has(t)?!this.entities.get(t)?.alias&&e&&(this.entities.get(t).alias=e,s.cM.info(`Add alias '${e}' to entity '${t}'`)):(this.entities.set(t,{id:`entity-${t}-${this.entities.size}`,label:t,attributes:[],alias:e,shape:"erBox",look:(0,s.nV)().look??"default",cssClasses:"default",cssStyles:[]}),s.cM.info("Added new entity :",t)),this.entities.get(t)}getEntity(t){return this.entities.get(t)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(t,e){const n=this.addEntity(t);let r;for(r=e.length-1;r>=0;r--)e[r].keys||(e[r].keys=[]),e[r].comment||(e[r].comment=""),n.attributes.push(e[r]),s.cM.debug("Added attribute ",e[r].name)}addRelationship(t,e,n,r){const i=this.entities.get(t),a=this.entities.get(n);if(!i||!a)return;const o={entityA:i.id,roleA:e,entityB:a.id,relSpec:r};this.relationships.push(o),s.cM.debug("Added new relationship :",o)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(t){this.direction=t}getCompiledStyles(t){let e=[];for(const n of t){const t=this.classes.get(n);t?.styles&&(e=[...e,...t.styles??[]].map((t=>t.trim()))),t?.textStyles&&(e=[...e,...t.textStyles??[]].map((t=>t.trim())))}return e}addCssStyles(t,e){for(const n of t){const t=this.entities.get(n);if(!e||!t)return;for(const n of e)t.cssStyles.push(n)}}addClass(t,e){t.forEach((t=>{let n=this.classes.get(t);void 0===n&&(n={id:t,styles:[],textStyles:[]},this.classes.set(t,n)),e&&e.forEach((function(t){if(/color/.exec(t)){const e=t.replace("fill","bgFill");n.textStyles.push(e)}n.styles.push(t)}))}))}setClass(t,e){for(const n of t){const t=this.entities.get(n);if(t)for(const n of e)t.cssClasses+=" "+n}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],(0,s.ZH)()}getData(){const t=[],e=[],n=(0,s.nV)();for(const e of this.entities.keys()){const n=this.entities.get(e);n&&(n.cssCompiledStyles=this.getCompiledStyles(n.cssClasses.split(" ")),t.push(n))}let r=0;for(const t of this.relationships){const i={id:(0,a.Ln)(t.entityA,t.entityB,{prefix:"id",counter:r++}),type:"normal",curve:"basis",start:t.entityA,end:t.entityB,label:t.roleA,labelpos:"c",thickness:"normal",classes:"relationshipLine",arrowTypeStart:t.relSpec.cardB.toLowerCase(),arrowTypeEnd:t.relSpec.cardA.toLowerCase(),pattern:"IDENTIFYING"==t.relSpec.relType?"solid":"dashed",look:n.look};e.push(i)}return{nodes:t,edges:e,other:{},config:n,direction:"TB"}}},p={};(0,s.r2)(p,{draw:()=>g});var g=(0,s.eW)((async function(t,e,n,l){s.cM.info("REF0:"),s.cM.info("Drawing er diagram (unified)",e);const{securityLevel:c,er:h,layout:u}=(0,s.nV)(),d=l.db.getData(),p=(0,r.q)(e,c);d.type=l.type,d.layoutAlgorithm=(0,i._b)(u),d.config.flowchart.nodeSpacing=h?.nodeSpacing||140,d.config.flowchart.rankSpacing=h?.rankSpacing||80,d.direction=l.db.getDirection(),d.markers=["only_one","zero_or_one","one_or_more","zero_or_more"],d.diagramId=e,await(0,i.sY)(d,p),"elk"===d.layoutAlgorithm&&p.select(".edges").lower();const g=p.selectAll('[id*="-background"]');Array.from(g).length>0&&g.each((function(){const t=(0,o.Ys)(this),e=t.attr("id").replace("-background",""),n=p.select(`#${CSS.escape(e)}`);if(!n.empty()){const e=n.attr("transform");t.attr("transform",e)}})),a.w8.insertTitle(p,"erDiagramTitleText",h?.titleTopMargin??25,l.db.getDiagramTitle()),(0,r.j)(p,8,"erDiagram",h?.useMaxWidth??!0)}),"draw"),f=(0,s.eW)(((t,e)=>{const n=l.Z,r=n(t,"r"),i=n(t,"g"),a=n(t,"b");return c.Z(r,i,a,e)}),"fade"),m={parser:u,get db(){return new d},renderer:p,styles:(0,s.eW)((t=>`\n .entityBox {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n }\n\n .relationshipLabelBox {\n fill: ${t.tertiaryColor};\n opacity: 0.7;\n background-color: ${t.tertiaryColor};\n rect {\n opacity: 0.5;\n }\n }\n\n .labelBkg {\n background-color: ${f(t.tertiaryColor,.5)};\n }\n\n .edgeLabel .label {\n fill: ${t.nodeBorder};\n font-size: 14px;\n }\n\n .label {\n font-family: ${t.fontFamily};\n color: ${t.nodeTextColor||t.textColor};\n }\n\n .edge-pattern-dashed {\n stroke-dasharray: 8,8;\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon\n {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n stroke-width: 1px;\n }\n\n .relationshipLine {\n stroke: ${t.lineColor};\n stroke-width: 1;\n fill: none;\n }\n\n .marker {\n fill: none !important;\n stroke: ${t.lineColor} !important;\n stroke-width: 1;\n }\n`),"getStyles")}},9389:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>x});var r=n(9241),i=n(907),a=n(8337),s=(n(1566),n(5179),n(3583)),o=(n(1426),n(6241),n(214),n(7946)),l=n(4082),c=n(3108),h=n(9792),u=n(1117),d=class{constructor(){this.vertexCounter=0,this.config=(0,l.nV)(),this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.funs=[],this.setAccTitle=l.GN,this.setAccDescription=l.U$,this.setDiagramTitle=l.g2,this.getAccTitle=l.eu,this.getAccDescription=l.Mx,this.getDiagramTitle=l.Kr,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen("gen-2")}static{(0,l.eW)(this,"FlowDB")}sanitizeText(t){return l.SY.sanitizeText(t,this.config)}lookUpDomId(t){for(const e of this.vertices.values())if(e.id===t)return e.domId;return t}addVertex(t,e,n,i,a,o,c={},h){if(!t||0===t.trim().length)return;let u;if(void 0!==h){let t;t=h.includes("\n")?h+"\n":"{\n"+h+"\n}",u=(0,r.z)(t,{schema:r.A})}const d=this.edges.find((e=>e.id===t));if(d){const t=u;return void 0!==t?.animate&&(d.animate=t.animate),void(void 0!==t?.animation&&(d.animation=t.animation))}let p,g=this.vertices.get(t);if(void 0===g&&(g={id:t,labelType:"text",domId:"flowchart-"+t+"-"+this.vertexCounter,styles:[],classes:[]},this.vertices.set(t,g)),this.vertexCounter++,void 0!==e?(this.config=(0,l.nV)(),p=this.sanitizeText(e.text.trim()),g.labelType=e.type,p.startsWith('"')&&p.endsWith('"')&&(p=p.substring(1,p.length-1)),g.text=p):void 0===g.text&&(g.text=t),void 0!==n&&(g.type=n),null!=i&&i.forEach((t=>{g.styles.push(t)})),null!=a&&a.forEach((t=>{g.classes.push(t)})),void 0!==o&&(g.dir=o),void 0===g.props?g.props=c:void 0!==c&&Object.assign(g.props,c),void 0!==u){if(u.shape){if(u.shape!==u.shape.toLowerCase()||u.shape.includes("_"))throw new Error(`No such shape: ${u.shape}. Shape names should be lowercase.`);if(!(0,s.dW)(u.shape))throw new Error(`No such shape: ${u.shape}.`);g.type=u?.shape}u?.label&&(g.text=u?.label),u?.icon&&(g.icon=u?.icon,u.label?.trim()||g.text!==t||(g.text="")),u?.form&&(g.form=u?.form),u?.pos&&(g.pos=u?.pos),u?.img&&(g.img=u?.img,u.label?.trim()||g.text!==t||(g.text="")),u?.constraint&&(g.constraint=u.constraint),u.w&&(g.assetWidth=Number(u.w)),u.h&&(g.assetHeight=Number(u.h))}}addSingleLink(t,e,n,r){const i={start:t,end:e,type:void 0,text:"",labelType:"text",classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};l.cM.info("abc78 Got edge...",i);const a=n.text;if(void 0!==a&&(i.text=this.sanitizeText(a.text.trim()),i.text.startsWith('"')&&i.text.endsWith('"')&&(i.text=i.text.substring(1,i.text.length-1)),i.labelType=a.type),void 0!==n&&(i.type=n.type,i.stroke=n.stroke,i.length=n.length>10?10:n.length),r&&!this.edges.some((t=>t.id===r)))i.id=r,i.isUserDefinedId=!0;else{const t=this.edges.filter((t=>t.start===i.start&&t.end===i.end));0===t.length?i.id=(0,o.Ln)(i.start,i.end,{counter:0,prefix:"L"}):i.id=(0,o.Ln)(i.start,i.end,{counter:t.length+1,prefix:"L"})}if(!(this.edges.length<(this.config.maxEdges??500)))throw new Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}.\n\nInitialize mermaid with maxEdges set to a higher number to allow more edges.\nYou cannot set this config via configuration inside the diagram as it is a secure config.\nYou have to call mermaid.initialize.`);l.cM.info("Pushing edge..."),this.edges.push(i)}isLinkData(t){return null!==t&&"object"==typeof t&&"id"in t&&"string"==typeof t.id}addLink(t,e,n){const r=this.isLinkData(n)?n.id.replace("@",""):void 0;l.cM.info("addLink",t,e,r);for(const i of t)for(const a of e){const s=i===t[t.length-1],o=a===e[0];s&&o?this.addSingleLink(i,a,n,r):this.addSingleLink(i,a,n,void 0)}}updateLinkInterpolate(t,e){t.forEach((t=>{"default"===t?this.edges.defaultInterpolate=e:this.edges[t].interpolate=e}))}updateLink(t,e){t.forEach((t=>{if("number"==typeof t&&t>=this.edges.length)throw new Error(`The index ${t} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);"default"===t?this.edges.defaultStyle=e:(this.edges[t].style=e,(this.edges[t]?.style?.length??0)>0&&!this.edges[t]?.style?.some((t=>t?.startsWith("fill")))&&this.edges[t]?.style?.push("fill:none"))}))}addClass(t,e){const n=e.join().replace(/\\,/g,"§§§").replace(/,/g,";").replace(/§§§/g,",").split(";");t.split(",").forEach((t=>{let e=this.classes.get(t);void 0===e&&(e={id:t,styles:[],textStyles:[]},this.classes.set(t,e)),null!=n&&n.forEach((t=>{if(/color/.exec(t)){const n=t.replace("fill","bgFill");e.textStyles.push(n)}e.styles.push(t)}))}))}setDirection(t){this.direction=t,/.*/.exec(this.direction)&&(this.direction="LR"),/.*v/.exec(this.direction)&&(this.direction="TB"),"TD"===this.direction&&(this.direction="TB")}setClass(t,e){for(const n of t.split(",")){const t=this.vertices.get(n);t&&t.classes.push(e);const r=this.edges.find((t=>t.id===n));r&&r.classes.push(e);const i=this.subGraphLookup.get(n);i&&i.classes.push(e)}}setTooltip(t,e){if(void 0!==e){e=this.sanitizeText(e);for(const n of t.split(","))this.tooltips.set("gen-1"===this.version?this.lookUpDomId(n):n,e)}}setClickFun(t,e,n){const r=this.lookUpDomId(t);if("loose"!==(0,l.nV)().securityLevel)return;if(void 0===e)return;let i=[];if("string"==typeof n){i=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let t=0;t{const t=document.querySelector(`[id="${r}"]`);null!==t&&t.addEventListener("click",(()=>{o.w8.runFunc(e,...i)}),!1)})))}setLink(t,e,n){t.split(",").forEach((t=>{const r=this.vertices.get(t);void 0!==r&&(r.link=o.w8.formatUrl(e,this.config),r.linkTarget=n)})),this.setClass(t,"clickable")}getTooltip(t){return this.tooltips.get(t)}setClickEvent(t,e,n){t.split(",").forEach((t=>{this.setClickFun(t,e,n)})),this.setClass(t,"clickable")}bindFunctions(t){this.funs.forEach((e=>{e(t)}))}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}getClasses(){return this.classes}setupToolTips(t){let e=(0,c.Ys)(".mermaidTooltip");null===(e._groups||e)[0][0]&&(e=(0,c.Ys)("body").append("div").attr("class","mermaidTooltip").style("opacity",0)),(0,c.Ys)(t).select("svg").selectAll("g.node").on("mouseover",(t=>{const n=(0,c.Ys)(t.currentTarget);if(null===n.attr("title"))return;const r=t.currentTarget?.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.text(n.attr("title")).style("left",window.scrollX+r.left+(r.right-r.left)/2+"px").style("top",window.scrollY+r.bottom+"px"),e.html(e.html().replace(/<br\/>/g,"
    ")),n.classed("hover",!0)})).on("mouseout",(t=>{e.transition().duration(500).style("opacity",0),(0,c.Ys)(t.currentTarget).classed("hover",!1)}))}clear(t="gen-2"){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=t,this.config=(0,l.nV)(),(0,l.ZH)()}setGen(t){this.version=t||"gen-2"}defaultStyle(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"}addSubGraph(t,e,n){let r=t.text.trim(),i=n.text;t===n&&/\s/.exec(n.text)&&(r=void 0);const a=(0,l.eW)((t=>{const e={boolean:{},number:{},string:{}},n=[];let r;return{nodeList:t.filter((function(t){const i=typeof t;return t.stmt&&"dir"===t.stmt?(r=t.value,!1):""!==t.trim()&&(i in e?!e[i].hasOwnProperty(t)&&(e[i][t]=!0):!n.includes(t)&&n.push(t))})),dir:r}}),"uniq"),{nodeList:s,dir:o}=a(e.flat());if("gen-1"===this.version)for(let t=0;t2e3)return{result:!1,count:0};if(this.posCrossRef[this.secCount]=e,this.subGraphs[e].id===t)return{result:!0,count:0};let r=0,i=1;for(;r=0){const n=this.indexNodes2(t,e);if(n.result)return{result:!0,count:i+n.count};i+=n.count}r+=1}return{result:!1,count:i}}getDepthFirstPos(t){return this.posCrossRef[t]}indexNodes(){this.secCount=-1,this.subGraphs.length>0&&this.indexNodes2("none",this.subGraphs.length-1)}getSubGraphs(){return this.subGraphs}firstGraph(){return!!this.firstGraphFlag&&(this.firstGraphFlag=!1,!0)}destructStartLink(t){let e=t.trim(),n="arrow_open";switch(e[0]){case"<":n="arrow_point",e=e.slice(1);break;case"x":n="arrow_cross",e=e.slice(1);break;case"o":n="arrow_circle",e=e.slice(1)}let r="normal";return e.includes("=")&&(r="thick"),e.includes(".")&&(r="dotted"),{type:n,stroke:r}}countChar(t,e){const n=e.length;let r=0;for(let i=0;i":r="arrow_point",e.startsWith("<")&&(r="double_"+r,n=n.slice(1));break;case"o":r="arrow_circle",e.startsWith("o")&&(r="double_"+r,n=n.slice(1))}let i="normal",a=n.length-1;n.startsWith("=")&&(i="thick"),n.startsWith("~")&&(i="invisible");const s=this.countChar(".",n);return s&&(i="dotted",a=s),{type:r,stroke:i,length:a}}destructLink(t,e){const n=this.destructEndLink(t);let r;if(e){if(r=this.destructStartLink(e),r.stroke!==n.stroke)return{type:"INVALID",stroke:"INVALID"};if("arrow_open"===r.type)r.type=n.type;else{if(r.type!==n.type)return{type:"INVALID",stroke:"INVALID"};r.type="double_"+r.type}return"double_arrow"===r.type&&(r.type="double_arrow_point"),r.length=n.length,r}return n}exists(t,e){for(const n of t)if(n.nodes.includes(e))return!0;return!1}makeUniq(t,e){const n=[];return t.nodes.forEach(((r,i)=>{this.exists(e,r)||n.push(t.nodes[i])})),{nodes:n}}getTypeFromVertex(t){if(t.img)return"imageSquare";if(t.icon)return"circle"===t.form?"iconCircle":"square"===t.form?"iconSquare":"rounded"===t.form?"iconRounded":"icon";switch(t.type){case"square":case void 0:return"squareRect";case"round":return"roundedRect";case"ellipse":return"ellipse";default:return t.type}}findNode(t,e){return t.find((t=>t.id===e))}destructEdgeType(t){let e="none",n="arrow_point";switch(t){case"arrow_point":case"arrow_circle":case"arrow_cross":n=t;break;case"double_arrow_point":case"double_arrow_circle":case"double_arrow_cross":e=t.replace("double_",""),n=e}return{arrowTypeStart:e,arrowTypeEnd:n}}addNodeFromVertex(t,e,n,r,i,a){const s=n.get(t.id),o=r.get(t.id)??!1,l=this.findNode(e,t.id);if(l)l.cssStyles=t.styles,l.cssCompiledStyles=this.getCompiledStyles(t.classes),l.cssClasses=t.classes.join(" ");else{const n={id:t.id,label:t.text,labelStyle:"",parentId:s,padding:i.flowchart?.padding||8,cssStyles:t.styles,cssCompiledStyles:this.getCompiledStyles(["default","node",...t.classes]),cssClasses:"default "+t.classes.join(" "),dir:t.dir,domId:t.domId,look:a,link:t.link,linkTarget:t.linkTarget,tooltip:this.getTooltip(t.id),icon:t.icon,pos:t.pos,img:t.img,assetWidth:t.assetWidth,assetHeight:t.assetHeight,constraint:t.constraint};o?e.push({...n,isGroup:!0,shape:"rect"}):e.push({...n,isGroup:!1,shape:this.getTypeFromVertex(t)})}}getCompiledStyles(t){let e=[];for(const n of t){const t=this.classes.get(n);t?.styles&&(e=[...e,...t.styles??[]].map((t=>t.trim()))),t?.textStyles&&(e=[...e,...t.textStyles??[]].map((t=>t.trim())))}return e}getData(){const t=(0,l.nV)(),e=[],n=[],r=this.getSubGraphs(),i=new Map,a=new Map;for(let t=r.length-1;t>=0;t--){const e=r[t];e.nodes.length>0&&a.set(e.id,!0);for(const t of e.nodes)i.set(t,e.id)}for(let n=r.length-1;n>=0;n--){const a=r[n];e.push({id:a.id,label:a.title,labelStyle:"",parentId:i.get(a.id),padding:8,cssCompiledStyles:this.getCompiledStyles(a.classes),cssClasses:a.classes.join(" "),shape:"rect",dir:a.dir,isGroup:!0,look:t.look})}this.getVertices().forEach((n=>{this.addNodeFromVertex(n,e,i,a,t,t.look||"classic")}));const s=this.getEdges();return s.forEach(((e,r)=>{const{arrowTypeStart:i,arrowTypeEnd:a}=this.destructEdgeType(e.type),l=[...s.defaultStyle??[]];e.style&&l.push(...e.style);const c={id:(0,o.Ln)(e.start,e.end,{counter:r,prefix:"L"},e.id),isUserDefinedId:e.isUserDefinedId,start:e.start,end:e.end,type:e.type??"normal",label:e.text,labelpos:"c",thickness:e.stroke,minlen:e.length,classes:"invisible"===e?.stroke?"":"edge-thickness-normal edge-pattern-solid flowchart-link",arrowTypeStart:"invisible"===e?.stroke||"arrow_open"===e?.type?"none":i,arrowTypeEnd:"invisible"===e?.stroke||"arrow_open"===e?.type?"none":a,arrowheadStyle:"fill: #333",cssCompiledStyles:this.getCompiledStyles(e.classes),labelStyle:l,style:l,pattern:e.stroke,look:t.look,animate:e.animate,animation:e.animation,curve:e.interpolate||this.edges.defaultInterpolate||t.flowchart?.curve};n.push(c)})),{nodes:e,edges:n,other:{},config:t}}defaultConfig(){return l.Fy.flowchart}},p={getClasses:(0,l.eW)((function(t,e){return e.db.getClasses()}),"getClasses"),draw:(0,l.eW)((async function(t,e,n,r){l.cM.info("REF0:"),l.cM.info("Drawing state diagram (v2)",e);const{securityLevel:s,flowchart:h,layout:u}=(0,l.nV)();let d;"sandbox"===s&&(d=(0,c.Ys)("#i"+e));const p="sandbox"===s?d.nodes()[0].contentDocument:document;l.cM.debug("Before getData: ");const g=r.db.getData();l.cM.debug("Data: ",g);const f=(0,i.q)(e,s),m=r.db.getDirection();g.type=r.type,g.layoutAlgorithm=(0,a._b)(u),"dagre"===g.layoutAlgorithm&&"elk"===u&&l.cM.warn("flowchart-elk was moved to an external package in Mermaid v11. Please refer [release notes](https://github.com/mermaid-js/mermaid/releases/tag/v11.0.0) for more details. This diagram will be rendered using `dagre` layout as a fallback."),g.direction=m,g.nodeSpacing=h?.nodeSpacing||50,g.rankSpacing=h?.rankSpacing||50,g.markers=["point","circle","cross"],g.diagramId=e,l.cM.debug("REF1:",g),await(0,a.sY)(g,f);const y=g.config.flowchart?.diagramPadding??8;o.w8.insertTitle(f,"flowchartTitleText",h?.titleTopMargin||0,r.db.getDiagramTitle()),(0,i.j)(f,y,"flowchart",h?.useMaxWidth||!1);for(const t of g.nodes){const n=(0,c.Ys)(`#${e} [id="${t.id}"]`);if(!n||!t.link)continue;const r=p.createElementNS("http://www.w3.org/2000/svg","a");r.setAttributeNS("http://www.w3.org/2000/svg","class",t.cssClasses),r.setAttributeNS("http://www.w3.org/2000/svg","rel","noopener"),"sandbox"===s?r.setAttributeNS("http://www.w3.org/2000/svg","target","_top"):t.linkTarget&&r.setAttributeNS("http://www.w3.org/2000/svg","target",t.linkTarget);const i=n.insert((function(){return r}),":first-child"),a=n.select(".label-container");a&&i.append((function(){return a.node()}));const o=n.select(".label");o&&i.append((function(){return o.node()}))}}),"draw")},g=function(){var t=(0,l.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,4],n=[1,3],r=[1,5],i=[1,8,9,10,11,27,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124],a=[2,2],s=[1,13],o=[1,14],c=[1,15],h=[1,16],u=[1,23],d=[1,25],p=[1,26],g=[1,27],f=[1,49],m=[1,48],y=[1,29],v=[1,30],x=[1,31],b=[1,32],w=[1,33],k=[1,44],T=[1,46],_=[1,42],E=[1,47],S=[1,43],C=[1,50],A=[1,45],L=[1,51],M=[1,52],N=[1,34],I=[1,35],R=[1,36],D=[1,37],O=[1,57],P=[1,8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124],$=[1,61],B=[1,60],F=[1,62],W=[8,9,11,75,77,78],z=[1,78],Z=[1,91],Y=[1,96],U=[1,95],G=[1,92],V=[1,88],q=[1,94],j=[1,90],H=[1,97],X=[1,93],K=[1,98],Q=[1,89],J=[8,9,10,11,40,75,77,78],tt=[8,9,10,11,40,46,75,77,78],et=[8,9,10,11,29,40,44,46,48,50,52,54,56,58,60,63,65,67,68,70,75,77,78,89,102,105,106,109,111,114,115,116],nt=[8,9,11,44,60,75,77,78,89,102,105,106,109,111,114,115,116],rt=[44,60,89,102,105,106,109,111,114,115,116],it=[1,121],at=[1,122],st=[1,124],ot=[1,123],lt=[44,60,62,74,89,102,105,106,109,111,114,115,116],ct=[1,133],ht=[1,147],ut=[1,148],dt=[1,149],pt=[1,150],gt=[1,135],ft=[1,137],mt=[1,141],yt=[1,142],vt=[1,143],xt=[1,144],bt=[1,145],wt=[1,146],kt=[1,151],Tt=[1,152],_t=[1,131],Et=[1,132],St=[1,139],Ct=[1,134],At=[1,138],Lt=[1,136],Mt=[8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124],Nt=[1,154],It=[1,156],Rt=[8,9,11],Dt=[8,9,10,11,14,44,60,89,105,106,109,111,114,115,116],Ot=[1,176],Pt=[1,172],$t=[1,173],Bt=[1,177],Ft=[1,174],Wt=[1,175],zt=[77,116,119],Zt=[8,9,10,11,12,14,27,29,32,44,60,75,84,85,86,87,88,89,90,105,109,111,114,115,116],Yt=[10,106],Ut=[31,49,51,53,55,57,62,64,66,67,69,71,116,117,118],Gt=[1,247],Vt=[1,245],qt=[1,249],jt=[1,243],Ht=[1,244],Xt=[1,246],Kt=[1,248],Qt=[1,250],Jt=[1,268],te=[8,9,11,106],ee=[8,9,10,11,60,84,105,106,109,110,111,112],ne={trace:(0,l.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,SEMI:8,NEWLINE:9,SPACE:10,EOF:11,GRAPH:12,NODIR:13,DIR:14,FirstStmtSeparator:15,ending:16,endToken:17,spaceList:18,spaceListNewline:19,vertexStatement:20,separator:21,styleStatement:22,linkStyleStatement:23,classDefStatement:24,classStatement:25,clickStatement:26,subgraph:27,textNoTags:28,SQS:29,text:30,SQE:31,end:32,direction:33,acc_title:34,acc_title_value:35,acc_descr:36,acc_descr_value:37,acc_descr_multiline_value:38,shapeData:39,SHAPE_DATA:40,link:41,node:42,styledVertex:43,AMP:44,vertex:45,STYLE_SEPARATOR:46,idString:47,DOUBLECIRCLESTART:48,DOUBLECIRCLEEND:49,PS:50,PE:51,"(-":52,"-)":53,STADIUMSTART:54,STADIUMEND:55,SUBROUTINESTART:56,SUBROUTINEEND:57,VERTEX_WITH_PROPS_START:58,"NODE_STRING[field]":59,COLON:60,"NODE_STRING[value]":61,PIPE:62,CYLINDERSTART:63,CYLINDEREND:64,DIAMOND_START:65,DIAMOND_STOP:66,TAGEND:67,TRAPSTART:68,TRAPEND:69,INVTRAPSTART:70,INVTRAPEND:71,linkStatement:72,arrowText:73,TESTSTR:74,START_LINK:75,edgeText:76,LINK:77,LINK_ID:78,edgeTextToken:79,STR:80,MD_STR:81,textToken:82,keywords:83,STYLE:84,LINKSTYLE:85,CLASSDEF:86,CLASS:87,CLICK:88,DOWN:89,UP:90,textNoTagsToken:91,stylesOpt:92,"idString[vertex]":93,"idString[class]":94,CALLBACKNAME:95,CALLBACKARGS:96,HREF:97,LINK_TARGET:98,"STR[link]":99,"STR[tooltip]":100,alphaNum:101,DEFAULT:102,numList:103,INTERPOLATE:104,NUM:105,COMMA:106,style:107,styleComponent:108,NODE_STRING:109,UNIT:110,BRKT:111,PCT:112,idStringToken:113,MINUS:114,MULT:115,UNICODE_TEXT:116,TEXT:117,TAGSTART:118,EDGE_TEXT:119,alphaNumToken:120,direction_tb:121,direction_bt:122,direction_rl:123,direction_lr:124,$accept:0,$end:1},terminals_:{2:"error",8:"SEMI",9:"NEWLINE",10:"SPACE",11:"EOF",12:"GRAPH",13:"NODIR",14:"DIR",27:"subgraph",29:"SQS",31:"SQE",32:"end",34:"acc_title",35:"acc_title_value",36:"acc_descr",37:"acc_descr_value",38:"acc_descr_multiline_value",40:"SHAPE_DATA",44:"AMP",46:"STYLE_SEPARATOR",48:"DOUBLECIRCLESTART",49:"DOUBLECIRCLEEND",50:"PS",51:"PE",52:"(-",53:"-)",54:"STADIUMSTART",55:"STADIUMEND",56:"SUBROUTINESTART",57:"SUBROUTINEEND",58:"VERTEX_WITH_PROPS_START",59:"NODE_STRING[field]",60:"COLON",61:"NODE_STRING[value]",62:"PIPE",63:"CYLINDERSTART",64:"CYLINDEREND",65:"DIAMOND_START",66:"DIAMOND_STOP",67:"TAGEND",68:"TRAPSTART",69:"TRAPEND",70:"INVTRAPSTART",71:"INVTRAPEND",74:"TESTSTR",75:"START_LINK",77:"LINK",78:"LINK_ID",80:"STR",81:"MD_STR",84:"STYLE",85:"LINKSTYLE",86:"CLASSDEF",87:"CLASS",88:"CLICK",89:"DOWN",90:"UP",93:"idString[vertex]",94:"idString[class]",95:"CALLBACKNAME",96:"CALLBACKARGS",97:"HREF",98:"LINK_TARGET",99:"STR[link]",100:"STR[tooltip]",102:"DEFAULT",104:"INTERPOLATE",105:"NUM",106:"COMMA",109:"NODE_STRING",110:"UNIT",111:"BRKT",112:"PCT",114:"MINUS",115:"MULT",116:"UNICODE_TEXT",117:"TEXT",118:"TAGSTART",119:"EDGE_TEXT",121:"direction_tb",122:"direction_bt",123:"direction_rl",124:"direction_lr"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,3],[16,2],[16,1],[17,1],[17,1],[17,1],[15,1],[15,1],[15,2],[19,2],[19,2],[19,1],[19,1],[18,2],[18,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,6],[7,4],[7,1],[7,2],[7,2],[7,1],[21,1],[21,1],[21,1],[39,2],[39,1],[20,4],[20,3],[20,4],[20,2],[20,2],[20,1],[42,1],[42,6],[42,5],[43,1],[43,3],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,8],[45,4],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,4],[45,4],[45,1],[41,2],[41,3],[41,3],[41,1],[41,3],[41,4],[76,1],[76,2],[76,1],[76,1],[72,1],[72,2],[73,3],[30,1],[30,2],[30,1],[30,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[28,1],[28,2],[28,1],[28,1],[24,5],[25,5],[26,2],[26,4],[26,3],[26,5],[26,3],[26,5],[26,5],[26,7],[26,2],[26,4],[26,2],[26,4],[26,4],[26,6],[22,5],[23,5],[23,5],[23,9],[23,9],[23,7],[23,7],[103,1],[103,3],[92,1],[92,3],[107,1],[107,2],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[82,1],[82,1],[82,1],[82,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[79,1],[79,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[47,1],[47,2],[101,1],[101,2],[33,1],[33,1],[33,1],[33,1]],performAction:(0,l.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 2:case 28:case 29:case 30:case 31:case 32:this.$=[];break;case 3:(!Array.isArray(a[o])||a[o].length>0)&&a[o-1].push(a[o]),this.$=a[o-1];break;case 4:case 183:case 44:case 54:case 76:case 181:this.$=a[o];break;case 11:r.setDirection("TB"),this.$="TB";break;case 12:r.setDirection(a[o-1]),this.$=a[o-1];break;case 27:this.$=a[o-1].nodes;break;case 33:this.$=r.addSubGraph(a[o-6],a[o-1],a[o-4]);break;case 34:this.$=r.addSubGraph(a[o-3],a[o-1],a[o-3]);break;case 35:this.$=r.addSubGraph(void 0,a[o-1],void 0);break;case 37:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 38:case 39:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 43:case 133:this.$=a[o-1]+a[o];break;case 45:r.addVertex(a[o-1][a[o-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[o]),r.addLink(a[o-3].stmt,a[o-1],a[o-2]),this.$={stmt:a[o-1],nodes:a[o-1].concat(a[o-3].nodes)};break;case 46:r.addLink(a[o-2].stmt,a[o],a[o-1]),this.$={stmt:a[o],nodes:a[o].concat(a[o-2].nodes)};break;case 47:r.addLink(a[o-3].stmt,a[o-1],a[o-2]),this.$={stmt:a[o-1],nodes:a[o-1].concat(a[o-3].nodes)};break;case 48:this.$={stmt:a[o-1],nodes:a[o-1]};break;case 49:r.addVertex(a[o-1][a[o-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[o]),this.$={stmt:a[o-1],nodes:a[o-1],shapeData:a[o]};break;case 50:this.$={stmt:a[o],nodes:a[o]};break;case 51:case 128:case 130:this.$=[a[o]];break;case 52:r.addVertex(a[o-5][a[o-5].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[o-4]),this.$=a[o-5].concat(a[o]);break;case 53:this.$=a[o-4].concat(a[o]);break;case 55:this.$=a[o-2],r.setClass(a[o-2],a[o]);break;case 56:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"square");break;case 57:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"doublecircle");break;case 58:this.$=a[o-5],r.addVertex(a[o-5],a[o-2],"circle");break;case 59:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"ellipse");break;case 60:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"stadium");break;case 61:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"subroutine");break;case 62:this.$=a[o-7],r.addVertex(a[o-7],a[o-1],"rect",void 0,void 0,void 0,Object.fromEntries([[a[o-5],a[o-3]]]));break;case 63:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"cylinder");break;case 64:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"round");break;case 65:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"diamond");break;case 66:this.$=a[o-5],r.addVertex(a[o-5],a[o-2],"hexagon");break;case 67:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"odd");break;case 68:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"trapezoid");break;case 69:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"inv_trapezoid");break;case 70:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"lean_right");break;case 71:this.$=a[o-3],r.addVertex(a[o-3],a[o-1],"lean_left");break;case 72:this.$=a[o],r.addVertex(a[o]);break;case 73:a[o-1].text=a[o],this.$=a[o-1];break;case 74:case 75:a[o-2].text=a[o-1],this.$=a[o-2];break;case 77:var l=r.destructLink(a[o],a[o-2]);this.$={type:l.type,stroke:l.stroke,length:l.length,text:a[o-1]};break;case 78:l=r.destructLink(a[o],a[o-2]),this.$={type:l.type,stroke:l.stroke,length:l.length,text:a[o-1],id:a[o-3]};break;case 79:case 86:case 101:case 103:this.$={text:a[o],type:"text"};break;case 80:case 87:case 102:this.$={text:a[o-1].text+""+a[o],type:a[o-1].type};break;case 81:case 88:this.$={text:a[o],type:"string"};break;case 82:case 89:case 104:this.$={text:a[o],type:"markdown"};break;case 83:l=r.destructLink(a[o]),this.$={type:l.type,stroke:l.stroke,length:l.length};break;case 84:l=r.destructLink(a[o]),this.$={type:l.type,stroke:l.stroke,length:l.length,id:a[o-1]};break;case 85:this.$=a[o-1];break;case 105:this.$=a[o-4],r.addClass(a[o-2],a[o]);break;case 106:this.$=a[o-4],r.setClass(a[o-2],a[o]);break;case 107:case 115:this.$=a[o-1],r.setClickEvent(a[o-1],a[o]);break;case 108:case 116:this.$=a[o-3],r.setClickEvent(a[o-3],a[o-2]),r.setTooltip(a[o-3],a[o]);break;case 109:this.$=a[o-2],r.setClickEvent(a[o-2],a[o-1],a[o]);break;case 110:this.$=a[o-4],r.setClickEvent(a[o-4],a[o-3],a[o-2]),r.setTooltip(a[o-4],a[o]);break;case 111:this.$=a[o-2],r.setLink(a[o-2],a[o]);break;case 112:this.$=a[o-4],r.setLink(a[o-4],a[o-2]),r.setTooltip(a[o-4],a[o]);break;case 113:this.$=a[o-4],r.setLink(a[o-4],a[o-2],a[o]);break;case 114:this.$=a[o-6],r.setLink(a[o-6],a[o-4],a[o]),r.setTooltip(a[o-6],a[o-2]);break;case 117:this.$=a[o-1],r.setLink(a[o-1],a[o]);break;case 118:this.$=a[o-3],r.setLink(a[o-3],a[o-2]),r.setTooltip(a[o-3],a[o]);break;case 119:this.$=a[o-3],r.setLink(a[o-3],a[o-2],a[o]);break;case 120:this.$=a[o-5],r.setLink(a[o-5],a[o-4],a[o]),r.setTooltip(a[o-5],a[o-2]);break;case 121:this.$=a[o-4],r.addVertex(a[o-2],void 0,void 0,a[o]);break;case 122:this.$=a[o-4],r.updateLink([a[o-2]],a[o]);break;case 123:this.$=a[o-4],r.updateLink(a[o-2],a[o]);break;case 124:this.$=a[o-8],r.updateLinkInterpolate([a[o-6]],a[o-2]),r.updateLink([a[o-6]],a[o]);break;case 125:this.$=a[o-8],r.updateLinkInterpolate(a[o-6],a[o-2]),r.updateLink(a[o-6],a[o]);break;case 126:this.$=a[o-6],r.updateLinkInterpolate([a[o-4]],a[o]);break;case 127:this.$=a[o-6],r.updateLinkInterpolate(a[o-4],a[o]);break;case 129:case 131:a[o-2].push(a[o]),this.$=a[o-2];break;case 182:case 184:this.$=a[o-1]+""+a[o];break;case 185:this.$={stmt:"dir",value:"TB"};break;case 186:this.$={stmt:"dir",value:"BT"};break;case 187:this.$={stmt:"dir",value:"RL"};break;case 188:this.$={stmt:"dir",value:"LR"}}}),"anonymous"),table:[{3:1,4:2,9:e,10:n,12:r},{1:[3]},t(i,a,{5:6}),{4:7,9:e,10:n,12:r},{4:8,9:e,10:n,12:r},{13:[1,9],14:[1,10]},{1:[2,1],6:11,7:12,8:s,9:o,10:c,11:h,20:17,22:18,23:19,24:20,25:21,26:22,27:u,33:24,34:d,36:p,38:g,42:28,43:38,44:f,45:39,47:40,60:m,84:y,85:v,86:x,87:b,88:w,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M,121:N,122:I,123:R,124:D},t(i,[2,9]),t(i,[2,10]),t(i,[2,11]),{8:[1,54],9:[1,55],10:O,15:53,18:56},t(P,[2,3]),t(P,[2,4]),t(P,[2,5]),t(P,[2,6]),t(P,[2,7]),t(P,[2,8]),{8:$,9:B,11:F,21:58,41:59,72:63,75:[1,64],77:[1,66],78:[1,65]},{8:$,9:B,11:F,21:67},{8:$,9:B,11:F,21:68},{8:$,9:B,11:F,21:69},{8:$,9:B,11:F,21:70},{8:$,9:B,11:F,21:71},{8:$,9:B,10:[1,72],11:F,21:73},t(P,[2,36]),{35:[1,74]},{37:[1,75]},t(P,[2,39]),t(W,[2,50],{18:76,39:77,10:O,40:z}),{10:[1,79]},{10:[1,80]},{10:[1,81]},{10:[1,82]},{14:Z,44:Y,60:U,80:[1,86],89:G,95:[1,83],97:[1,84],101:85,105:V,106:q,109:j,111:H,114:X,115:K,116:Q,120:87},t(P,[2,185]),t(P,[2,186]),t(P,[2,187]),t(P,[2,188]),t(J,[2,51]),t(J,[2,54],{46:[1,99]}),t(tt,[2,72],{113:112,29:[1,100],44:f,48:[1,101],50:[1,102],52:[1,103],54:[1,104],56:[1,105],58:[1,106],60:m,63:[1,107],65:[1,108],67:[1,109],68:[1,110],70:[1,111],89:k,102:T,105:_,106:E,109:S,111:C,114:A,115:L,116:M}),t(et,[2,181]),t(et,[2,142]),t(et,[2,143]),t(et,[2,144]),t(et,[2,145]),t(et,[2,146]),t(et,[2,147]),t(et,[2,148]),t(et,[2,149]),t(et,[2,150]),t(et,[2,151]),t(et,[2,152]),t(i,[2,12]),t(i,[2,18]),t(i,[2,19]),{9:[1,113]},t(nt,[2,26],{18:114,10:O}),t(P,[2,27]),{42:115,43:38,44:f,45:39,47:40,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},t(P,[2,40]),t(P,[2,41]),t(P,[2,42]),t(rt,[2,76],{73:116,62:[1,118],74:[1,117]}),{76:119,79:120,80:it,81:at,116:st,119:ot},{75:[1,125],77:[1,126]},t(lt,[2,83]),t(P,[2,28]),t(P,[2,29]),t(P,[2,30]),t(P,[2,31]),t(P,[2,32]),{10:ct,12:ht,14:ut,27:dt,28:127,32:pt,44:gt,60:ft,75:mt,80:[1,129],81:[1,130],83:140,84:yt,85:vt,86:xt,87:bt,88:wt,89:kt,90:Tt,91:128,105:_t,109:Et,111:St,114:Ct,115:At,116:Lt},t(Mt,a,{5:153}),t(P,[2,37]),t(P,[2,38]),t(W,[2,48],{44:Nt}),t(W,[2,49],{18:155,10:O,40:It}),t(J,[2,44]),{44:f,47:157,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},{102:[1,158],103:159,105:[1,160]},{44:f,47:161,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},{44:f,47:162,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},t(Rt,[2,107],{10:[1,163],96:[1,164]}),{80:[1,165]},t(Rt,[2,115],{120:167,10:[1,166],14:Z,44:Y,60:U,89:G,105:V,106:q,109:j,111:H,114:X,115:K,116:Q}),t(Rt,[2,117],{10:[1,168]}),t(Dt,[2,183]),t(Dt,[2,170]),t(Dt,[2,171]),t(Dt,[2,172]),t(Dt,[2,173]),t(Dt,[2,174]),t(Dt,[2,175]),t(Dt,[2,176]),t(Dt,[2,177]),t(Dt,[2,178]),t(Dt,[2,179]),t(Dt,[2,180]),{44:f,47:169,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},{30:170,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:178,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:180,50:[1,179],67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:181,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:182,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:183,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{109:[1,184]},{30:185,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:186,65:[1,187],67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:188,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:189,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{30:190,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},t(et,[2,182]),t(i,[2,20]),t(nt,[2,25]),t(W,[2,46],{39:191,18:192,10:O,40:z}),t(rt,[2,73],{10:[1,193]}),{10:[1,194]},{30:195,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{77:[1,196],79:197,116:st,119:ot},t(zt,[2,79]),t(zt,[2,81]),t(zt,[2,82]),t(zt,[2,168]),t(zt,[2,169]),{76:198,79:120,80:it,81:at,116:st,119:ot},t(lt,[2,84]),{8:$,9:B,10:ct,11:F,12:ht,14:ut,21:200,27:dt,29:[1,199],32:pt,44:gt,60:ft,75:mt,83:140,84:yt,85:vt,86:xt,87:bt,88:wt,89:kt,90:Tt,91:201,105:_t,109:Et,111:St,114:Ct,115:At,116:Lt},t(Zt,[2,101]),t(Zt,[2,103]),t(Zt,[2,104]),t(Zt,[2,157]),t(Zt,[2,158]),t(Zt,[2,159]),t(Zt,[2,160]),t(Zt,[2,161]),t(Zt,[2,162]),t(Zt,[2,163]),t(Zt,[2,164]),t(Zt,[2,165]),t(Zt,[2,166]),t(Zt,[2,167]),t(Zt,[2,90]),t(Zt,[2,91]),t(Zt,[2,92]),t(Zt,[2,93]),t(Zt,[2,94]),t(Zt,[2,95]),t(Zt,[2,96]),t(Zt,[2,97]),t(Zt,[2,98]),t(Zt,[2,99]),t(Zt,[2,100]),{6:11,7:12,8:s,9:o,10:c,11:h,20:17,22:18,23:19,24:20,25:21,26:22,27:u,32:[1,202],33:24,34:d,36:p,38:g,42:28,43:38,44:f,45:39,47:40,60:m,84:y,85:v,86:x,87:b,88:w,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M,121:N,122:I,123:R,124:D},{10:O,18:203},{44:[1,204]},t(J,[2,43]),{10:[1,205],44:f,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:112,114:A,115:L,116:M},{10:[1,206]},{10:[1,207],106:[1,208]},t(Yt,[2,128]),{10:[1,209],44:f,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:112,114:A,115:L,116:M},{10:[1,210],44:f,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:112,114:A,115:L,116:M},{80:[1,211]},t(Rt,[2,109],{10:[1,212]}),t(Rt,[2,111],{10:[1,213]}),{80:[1,214]},t(Dt,[2,184]),{80:[1,215],98:[1,216]},t(J,[2,55],{113:112,44:f,60:m,89:k,102:T,105:_,106:E,109:S,111:C,114:A,115:L,116:M}),{31:[1,217],67:Ot,82:218,116:Bt,117:Ft,118:Wt},t(Ut,[2,86]),t(Ut,[2,88]),t(Ut,[2,89]),t(Ut,[2,153]),t(Ut,[2,154]),t(Ut,[2,155]),t(Ut,[2,156]),{49:[1,219],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{30:220,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{51:[1,221],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{53:[1,222],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{55:[1,223],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{57:[1,224],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{60:[1,225]},{64:[1,226],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{66:[1,227],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{30:228,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},{31:[1,229],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{67:Ot,69:[1,230],71:[1,231],82:218,116:Bt,117:Ft,118:Wt},{67:Ot,69:[1,233],71:[1,232],82:218,116:Bt,117:Ft,118:Wt},t(W,[2,45],{18:155,10:O,40:It}),t(W,[2,47],{44:Nt}),t(rt,[2,75]),t(rt,[2,74]),{62:[1,234],67:Ot,82:218,116:Bt,117:Ft,118:Wt},t(rt,[2,77]),t(zt,[2,80]),{77:[1,235],79:197,116:st,119:ot},{30:236,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},t(Mt,a,{5:237}),t(Zt,[2,102]),t(P,[2,35]),{43:238,44:f,45:39,47:40,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},{10:O,18:239},{10:Gt,60:Vt,84:qt,92:240,105:jt,107:241,108:242,109:Ht,110:Xt,111:Kt,112:Qt},{10:Gt,60:Vt,84:qt,92:251,104:[1,252],105:jt,107:241,108:242,109:Ht,110:Xt,111:Kt,112:Qt},{10:Gt,60:Vt,84:qt,92:253,104:[1,254],105:jt,107:241,108:242,109:Ht,110:Xt,111:Kt,112:Qt},{105:[1,255]},{10:Gt,60:Vt,84:qt,92:256,105:jt,107:241,108:242,109:Ht,110:Xt,111:Kt,112:Qt},{44:f,47:257,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},t(Rt,[2,108]),{80:[1,258]},{80:[1,259],98:[1,260]},t(Rt,[2,116]),t(Rt,[2,118],{10:[1,261]}),t(Rt,[2,119]),t(tt,[2,56]),t(Ut,[2,87]),t(tt,[2,57]),{51:[1,262],67:Ot,82:218,116:Bt,117:Ft,118:Wt},t(tt,[2,64]),t(tt,[2,59]),t(tt,[2,60]),t(tt,[2,61]),{109:[1,263]},t(tt,[2,63]),t(tt,[2,65]),{66:[1,264],67:Ot,82:218,116:Bt,117:Ft,118:Wt},t(tt,[2,67]),t(tt,[2,68]),t(tt,[2,70]),t(tt,[2,69]),t(tt,[2,71]),t([10,44,60,89,102,105,106,109,111,114,115,116],[2,85]),t(rt,[2,78]),{31:[1,265],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{6:11,7:12,8:s,9:o,10:c,11:h,20:17,22:18,23:19,24:20,25:21,26:22,27:u,32:[1,266],33:24,34:d,36:p,38:g,42:28,43:38,44:f,45:39,47:40,60:m,84:y,85:v,86:x,87:b,88:w,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M,121:N,122:I,123:R,124:D},t(J,[2,53]),{43:267,44:f,45:39,47:40,60:m,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M},t(Rt,[2,121],{106:Jt}),t(te,[2,130],{108:269,10:Gt,60:Vt,84:qt,105:jt,109:Ht,110:Xt,111:Kt,112:Qt}),t(ee,[2,132]),t(ee,[2,134]),t(ee,[2,135]),t(ee,[2,136]),t(ee,[2,137]),t(ee,[2,138]),t(ee,[2,139]),t(ee,[2,140]),t(ee,[2,141]),t(Rt,[2,122],{106:Jt}),{10:[1,270]},t(Rt,[2,123],{106:Jt}),{10:[1,271]},t(Yt,[2,129]),t(Rt,[2,105],{106:Jt}),t(Rt,[2,106],{113:112,44:f,60:m,89:k,102:T,105:_,106:E,109:S,111:C,114:A,115:L,116:M}),t(Rt,[2,110]),t(Rt,[2,112],{10:[1,272]}),t(Rt,[2,113]),{98:[1,273]},{51:[1,274]},{62:[1,275]},{66:[1,276]},{8:$,9:B,11:F,21:277},t(P,[2,34]),t(J,[2,52]),{10:Gt,60:Vt,84:qt,105:jt,107:278,108:242,109:Ht,110:Xt,111:Kt,112:Qt},t(ee,[2,133]),{14:Z,44:Y,60:U,89:G,101:279,105:V,106:q,109:j,111:H,114:X,115:K,116:Q,120:87},{14:Z,44:Y,60:U,89:G,101:280,105:V,106:q,109:j,111:H,114:X,115:K,116:Q,120:87},{98:[1,281]},t(Rt,[2,120]),t(tt,[2,58]),{30:282,67:Ot,80:Pt,81:$t,82:171,116:Bt,117:Ft,118:Wt},t(tt,[2,66]),t(Mt,a,{5:283}),t(te,[2,131],{108:269,10:Gt,60:Vt,84:qt,105:jt,109:Ht,110:Xt,111:Kt,112:Qt}),t(Rt,[2,126],{120:167,10:[1,284],14:Z,44:Y,60:U,89:G,105:V,106:q,109:j,111:H,114:X,115:K,116:Q}),t(Rt,[2,127],{120:167,10:[1,285],14:Z,44:Y,60:U,89:G,105:V,106:q,109:j,111:H,114:X,115:K,116:Q}),t(Rt,[2,114]),{31:[1,286],67:Ot,82:218,116:Bt,117:Ft,118:Wt},{6:11,7:12,8:s,9:o,10:c,11:h,20:17,22:18,23:19,24:20,25:21,26:22,27:u,32:[1,287],33:24,34:d,36:p,38:g,42:28,43:38,44:f,45:39,47:40,60:m,84:y,85:v,86:x,87:b,88:w,89:k,102:T,105:_,106:E,109:S,111:C,113:41,114:A,115:L,116:M,121:N,122:I,123:R,124:D},{10:Gt,60:Vt,84:qt,92:288,105:jt,107:241,108:242,109:Ht,110:Xt,111:Kt,112:Qt},{10:Gt,60:Vt,84:qt,92:289,105:jt,107:241,108:242,109:Ht,110:Xt,111:Kt,112:Qt},t(tt,[2,62]),t(P,[2,33]),t(Rt,[2,124],{106:Jt}),t(Rt,[2,125],{106:Jt})],defaultActions:{},parseError:(0,l.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,l.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],s=this.table,o="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,l.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,l.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=s[w]&&s[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],s[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,o=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[o,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=s[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},re=function(){return{EOF:1,parseError:(0,l.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,l.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,l.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,l.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,l.eW)((function(){return this._more=!0,this}),"more"),reject:(0,l.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,l.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,l.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,l.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,l.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,l.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,l.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,l.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,l.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,l.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,l.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,l.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,l.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,l.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{},performAction:(0,l.eW)((function(t,e,n,r){switch(n){case 0:return this.begin("acc_title"),34;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),36;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:case 12:case 14:case 17:case 20:case 23:case 33:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return this.pushState("shapeData"),e.yytext="",40;case 8:return this.pushState("shapeDataStr"),40;case 9:return this.popState(),40;case 10:const n=/\n\s*/g;return e.yytext=e.yytext.replace(n,"
    "),40;case 11:return 40;case 13:this.begin("callbackname");break;case 15:this.popState(),this.begin("callbackargs");break;case 16:return 95;case 18:return 96;case 19:return"MD_STR";case 21:this.begin("md_string");break;case 22:return"STR";case 24:this.pushState("string");break;case 25:return 84;case 26:return 102;case 27:return 85;case 28:return 104;case 29:return 86;case 30:return 87;case 31:return 97;case 32:this.begin("click");break;case 34:return 88;case 35:case 36:case 37:return t.lex.firstGraph()&&this.begin("dir"),12;case 38:return 27;case 39:return 32;case 40:case 41:case 42:case 43:return 98;case 44:return this.popState(),13;case 45:case 46:case 47:case 48:case 49:case 50:case 51:case 52:case 53:case 54:return this.popState(),14;case 55:return 121;case 56:return 122;case 57:return 123;case 58:return 124;case 59:return 78;case 60:return 105;case 61:case 102:return 111;case 62:return 46;case 63:return 60;case 64:case 103:return 44;case 65:return 8;case 66:return 106;case 67:case 101:return 115;case 68:case 71:case 74:return this.popState(),77;case 69:return this.pushState("edgeText"),75;case 70:case 73:case 76:return 119;case 72:return this.pushState("thickEdgeText"),75;case 75:return this.pushState("dottedEdgeText"),75;case 77:return 77;case 78:return this.popState(),53;case 79:case 115:return"TEXT";case 80:return this.pushState("ellipseText"),52;case 81:return this.popState(),55;case 82:return this.pushState("text"),54;case 83:return this.popState(),57;case 84:return this.pushState("text"),56;case 85:return 58;case 86:return this.pushState("text"),67;case 87:return this.popState(),64;case 88:return this.pushState("text"),63;case 89:return this.popState(),49;case 90:return this.pushState("text"),48;case 91:return this.popState(),69;case 92:return this.popState(),71;case 93:return 117;case 94:return this.pushState("trapText"),68;case 95:return this.pushState("trapText"),70;case 96:return 118;case 97:return 67;case 98:return 90;case 99:return"SEP";case 100:return 89;case 104:return 109;case 105:return 114;case 106:return 116;case 107:return this.popState(),62;case 108:return this.pushState("text"),62;case 109:return this.popState(),51;case 110:return this.pushState("text"),50;case 111:return this.popState(),31;case 112:return this.pushState("text"),29;case 113:return this.popState(),66;case 114:return this.pushState("text"),65;case 116:return"QUOTE";case 117:return 9;case 118:return 10;case 119:return 11}}),"anonymous"),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:flowchart-elk\b)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:[^\s\"]+@(?=[^\{\"]))/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:[^=]|=(?!))/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:[^\.]|\.(?!))/,/^(?:\s*~~[\~]+\s*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|[^\\\[\]\(\)\{\}\/]+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:[^\[\]\(\)\{\}\|\"]+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},shapeData:{rules:[8,11,12,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},callbackargs:{rules:[17,18,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},callbackname:{rules:[14,15,16,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},href:{rules:[21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},click:{rules:[21,24,33,34,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},dottedEdgeText:{rules:[21,24,74,76,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},thickEdgeText:{rules:[21,24,71,73,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},edgeText:{rules:[21,24,68,70,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},trapText:{rules:[21,24,77,80,82,84,88,90,91,92,93,94,95,108,110,112,114],inclusive:!1},ellipseText:{rules:[21,24,77,78,79,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},text:{rules:[21,24,77,80,81,82,83,84,87,88,89,90,94,95,107,108,109,110,111,112,113,114,115],inclusive:!1},vertex:{rules:[21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},dir:{rules:[21,24,44,45,46,47,48,49,50,51,52,53,54,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},acc_descr:{rules:[3,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},acc_title:{rules:[1,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},md_string:{rules:[19,20,21,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},string:{rules:[21,22,23,24,77,80,82,84,88,90,94,95,108,110,112,114],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,71,72,74,75,77,80,82,84,85,86,88,90,94,95,96,97,98,99,100,101,102,103,104,105,106,108,110,112,114,116,117,118,119],inclusive:!0}}}}();function ie(){this.yy={}}return ne.lexer=re,(0,l.eW)(ie,"Parser"),ie.prototype=ne,ne.Parser=ie,new ie}();g.parser=g;var f=g,m=Object.assign({},f);m.parse=t=>{const e=t.replace(/}\s*\n/g,"}\n");return f.parse(e)};var y=m,v=(0,l.eW)(((t,e)=>{const n=h.Z,r=n(t,"r"),i=n(t,"g"),a=n(t,"b");return u.Z(r,i,a,e)}),"fade"),x={parser:y,get db(){return new d},renderer:p,styles:(0,l.eW)((t=>`.label {\n font-family: ${t.fontFamily};\n color: ${t.nodeTextColor||t.textColor};\n }\n .cluster-label text {\n fill: ${t.titleColor};\n }\n .cluster-label span {\n color: ${t.titleColor};\n }\n .cluster-label span p {\n background-color: transparent;\n }\n\n .label text,span {\n fill: ${t.nodeTextColor||t.textColor};\n color: ${t.nodeTextColor||t.textColor};\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n stroke-width: 1px;\n }\n .rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label {\n text-anchor: middle;\n }\n // .flowchart-label .text-outer-tspan {\n // text-anchor: middle;\n // }\n // .flowchart-label .text-inner-tspan {\n // text-anchor: start;\n // }\n\n .node .katex path {\n fill: #000;\n stroke: #000;\n stroke-width: 1px;\n }\n\n .rough-node .label,.node .label, .image-shape .label, .icon-shape .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n\n .root .anchor path {\n fill: ${t.lineColor} !important;\n stroke-width: 0;\n stroke: ${t.lineColor};\n }\n\n .arrowheadPath {\n fill: ${t.arrowheadColor};\n }\n\n .edgePath .path {\n stroke: ${t.lineColor};\n stroke-width: 2.0px;\n }\n\n .flowchart-link {\n stroke: ${t.lineColor};\n fill: none;\n }\n\n .edgeLabel {\n background-color: ${t.edgeLabelBackground};\n p {\n background-color: ${t.edgeLabelBackground};\n }\n rect {\n opacity: 0.5;\n background-color: ${t.edgeLabelBackground};\n fill: ${t.edgeLabelBackground};\n }\n text-align: center;\n }\n\n /* For html labels only */\n .labelBkg {\n background-color: ${v(t.edgeLabelBackground,.5)};\n // background-color:\n }\n\n .cluster rect {\n fill: ${t.clusterBkg};\n stroke: ${t.clusterBorder};\n stroke-width: 1px;\n }\n\n .cluster text {\n fill: ${t.titleColor};\n }\n\n .cluster span {\n color: ${t.titleColor};\n }\n /* .cluster div {\n color: ${t.titleColor};\n } */\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ${t.fontFamily};\n font-size: 12px;\n background: ${t.tertiaryColor};\n border: 1px solid ${t.border2};\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .flowchartTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${t.textColor};\n }\n\n rect.text {\n fill: none;\n stroke-width: 0;\n }\n\n .icon-shape, .image-shape {\n background-color: ${t.edgeLabelBackground};\n p {\n background-color: ${t.edgeLabelBackground};\n padding: 2px;\n }\n rect {\n opacity: 0.5;\n background-color: ${t.edgeLabelBackground};\n fill: ${t.edgeLabelBackground};\n }\n text-align: center;\n }\n`),"getStyles"),init:(0,l.eW)((t=>{t.flowchart||(t.flowchart={}),t.layout&&(0,l.Y4)({layout:t.layout}),t.flowchart.arrowMarkerAbsolute=t.arrowMarkerAbsolute,(0,l.Y4)({flowchart:{arrowMarkerAbsolute:t.arrowMarkerAbsolute}})}),"init")}},4748:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>Dt});var r=n(7946),i=n(4082),a=n(7967),s=n(7484),o=n(9542),l=n(285),c=n(8734),h=n(3108),u=function(){var t=(0,i.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],n=[1,26],r=[1,27],a=[1,28],s=[1,29],o=[1,30],l=[1,31],c=[1,32],h=[1,33],u=[1,34],d=[1,9],p=[1,10],g=[1,11],f=[1,12],m=[1,13],y=[1,14],v=[1,15],x=[1,16],b=[1,19],w=[1,20],k=[1,21],T=[1,22],_=[1,23],E=[1,25],S=[1,35],C={trace:(0,i.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:"error",4:"gantt",6:"EOF",8:"SPACE",10:"NL",12:"weekday_monday",13:"weekday_tuesday",14:"weekday_wednesday",15:"weekday_thursday",16:"weekday_friday",17:"weekday_saturday",18:"weekday_sunday",20:"weekend_friday",21:"weekend_saturday",22:"dateFormat",23:"inclusiveEndDates",24:"topAxis",25:"axisFormat",26:"tickInterval",27:"excludes",28:"includes",29:"todayMarker",30:"title",31:"acc_title",32:"acc_title_value",33:"acc_descr",34:"acc_descr_value",35:"acc_descr_multiline_value",36:"section",38:"taskTxt",39:"taskData",40:"click",41:"callbackname",42:"callbackargs",43:"href"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:(0,i.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 1:return a[o-1];case 2:case 6:case 7:this.$=[];break;case 3:a[o-1].push(a[o]),this.$=a[o-1];break;case 4:case 5:this.$=a[o];break;case 8:r.setWeekday("monday");break;case 9:r.setWeekday("tuesday");break;case 10:r.setWeekday("wednesday");break;case 11:r.setWeekday("thursday");break;case 12:r.setWeekday("friday");break;case 13:r.setWeekday("saturday");break;case 14:r.setWeekday("sunday");break;case 15:r.setWeekend("friday");break;case 16:r.setWeekend("saturday");break;case 17:r.setDateFormat(a[o].substr(11)),this.$=a[o].substr(11);break;case 18:r.enableInclusiveEndDates(),this.$=a[o].substr(18);break;case 19:r.TopAxis(),this.$=a[o].substr(8);break;case 20:r.setAxisFormat(a[o].substr(11)),this.$=a[o].substr(11);break;case 21:r.setTickInterval(a[o].substr(13)),this.$=a[o].substr(13);break;case 22:r.setExcludes(a[o].substr(9)),this.$=a[o].substr(9);break;case 23:r.setIncludes(a[o].substr(9)),this.$=a[o].substr(9);break;case 24:r.setTodayMarker(a[o].substr(12)),this.$=a[o].substr(12);break;case 27:r.setDiagramTitle(a[o].substr(6)),this.$=a[o].substr(6);break;case 28:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 29:case 30:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 31:r.addSection(a[o].substr(8)),this.$=a[o].substr(8);break;case 33:r.addTask(a[o-1],a[o]),this.$="task";break;case 34:this.$=a[o-1],r.setClickEvent(a[o-1],a[o],null);break;case 35:this.$=a[o-2],r.setClickEvent(a[o-2],a[o-1],a[o]);break;case 36:this.$=a[o-2],r.setClickEvent(a[o-2],a[o-1],null),r.setLink(a[o-2],a[o]);break;case 37:this.$=a[o-3],r.setClickEvent(a[o-3],a[o-2],a[o-1]),r.setLink(a[o-3],a[o]);break;case 38:this.$=a[o-2],r.setClickEvent(a[o-2],a[o],null),r.setLink(a[o-2],a[o-1]);break;case 39:this.$=a[o-3],r.setClickEvent(a[o-3],a[o-1],a[o]),r.setLink(a[o-3],a[o-2]);break;case 40:this.$=a[o-1],r.setLink(a[o-1],a[o]);break;case 41:case 47:this.$=a[o-1]+" "+a[o];break;case 42:case 43:case 45:this.$=a[o-2]+" "+a[o-1]+" "+a[o];break;case 44:case 46:this.$=a[o-3]+" "+a[o-2]+" "+a[o-1]+" "+a[o]}}),"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:n,13:r,14:a,15:s,16:o,17:l,18:c,19:18,20:h,21:u,22:d,23:p,24:g,25:f,26:m,27:y,28:v,29:x,30:b,31:w,33:k,35:T,36:_,37:24,38:E,40:S},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:36,11:17,12:n,13:r,14:a,15:s,16:o,17:l,18:c,19:18,20:h,21:u,22:d,23:p,24:g,25:f,26:m,27:y,28:v,29:x,30:b,31:w,33:k,35:T,36:_,37:24,38:E,40:S},t(e,[2,5]),t(e,[2,6]),t(e,[2,17]),t(e,[2,18]),t(e,[2,19]),t(e,[2,20]),t(e,[2,21]),t(e,[2,22]),t(e,[2,23]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),t(e,[2,27]),{32:[1,37]},{34:[1,38]},t(e,[2,30]),t(e,[2,31]),t(e,[2,32]),{39:[1,39]},t(e,[2,8]),t(e,[2,9]),t(e,[2,10]),t(e,[2,11]),t(e,[2,12]),t(e,[2,13]),t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),{41:[1,40],43:[1,41]},t(e,[2,4]),t(e,[2,28]),t(e,[2,29]),t(e,[2,33]),t(e,[2,34],{42:[1,42],43:[1,43]}),t(e,[2,40],{41:[1,44]}),t(e,[2,35],{43:[1,45]}),t(e,[2,36]),t(e,[2,38],{42:[1,46]}),t(e,[2,37]),t(e,[2,39])],defaultActions:{},parseError:(0,i.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,i.eW)((function(t){var e=this,n=[0],r=[],a=[null],s=[],o=this.table,l="",c=0,h=0,u=0,d=s.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;s.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,i.eW)((function(t){n.length=n.length-2*t,a.length=a.length-t,s.length=s.length-t}),"popStack"),(0,i.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),a.push(p.yytext),s.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=a[a.length-E],A._$={first_line:s[s.length-(E||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(E||1)].first_column,last_column:s[s.length-1].last_column},y&&(A._$.range=[s[s.length-(E||1)].range[0],s[s.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],a,s].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),a=a.slice(0,-1*E),s=s.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),a.push(A.$),s.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},A=function(){return{EOF:1,parseError:(0,i.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,i.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,i.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,i.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,i.eW)((function(){return this._more=!0,this}),"more"),reject:(0,i.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,i.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,i.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,i.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,i.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,i.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,i.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,i.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,i.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,i.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,i.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,i.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,i.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,i.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,i.eW)((function(t,e,n,r){switch(n){case 0:return this.begin("open_directive"),"open_directive";case 1:return this.begin("acc_title"),31;case 2:return this.popState(),"acc_title_value";case 3:return this.begin("acc_descr"),33;case 4:return this.popState(),"acc_descr_value";case 5:this.begin("acc_descr_multiline");break;case 6:case 15:case 18:case 21:case 24:this.popState();break;case 7:return"acc_descr_multiline_value";case 8:case 9:case 10:case 12:case 13:break;case 11:return 10;case 14:this.begin("href");break;case 16:return 43;case 17:this.begin("callbackname");break;case 19:this.popState(),this.begin("callbackargs");break;case 20:return 41;case 22:return 42;case 23:this.begin("click");break;case 25:return 40;case 26:return 4;case 27:return 22;case 28:return 23;case 29:return 24;case 30:return 25;case 31:return 26;case 32:return 28;case 33:return 27;case 34:return 29;case 35:return 12;case 36:return 13;case 37:return 14;case 38:return 15;case 39:return 16;case 40:return 17;case 41:return 18;case 42:return 20;case 43:return 21;case 44:return"date";case 45:return 30;case 46:return"accDescription";case 47:return 36;case 48:return 38;case 49:return 39;case 50:return":";case 51:return 6;case 52:return"INVALID"}}),"anonymous"),rules:[/^(?:%%\{)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:%%(?!\{)*[^\n]*)/i,/^(?:[^\}]%%*[^\n]*)/i,/^(?:%%*[^\n]*[\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:%[^\n]*)/i,/^(?:href[\s]+["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:call[\s]+)/i,/^(?:\([\s]*\))/i,/^(?:\()/i,/^(?:[^(]*)/i,/^(?:\))/i,/^(?:[^)]*)/i,/^(?:click[\s]+)/i,/^(?:[\s\n])/i,/^(?:[^\s\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\s[^#\n;]+)/i,/^(?:inclusiveEndDates\b)/i,/^(?:topAxis\b)/i,/^(?:axisFormat\s[^#\n;]+)/i,/^(?:tickInterval\s[^#\n;]+)/i,/^(?:includes\s[^#\n;]+)/i,/^(?:excludes\s[^#\n;]+)/i,/^(?:todayMarker\s[^\n;]+)/i,/^(?:weekday\s+monday\b)/i,/^(?:weekday\s+tuesday\b)/i,/^(?:weekday\s+wednesday\b)/i,/^(?:weekday\s+thursday\b)/i,/^(?:weekday\s+friday\b)/i,/^(?:weekday\s+saturday\b)/i,/^(?:weekday\s+sunday\b)/i,/^(?:weekend\s+friday\b)/i,/^(?:weekend\s+saturday\b)/i,/^(?:\d\d\d\d-\d\d-\d\d\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accDescription\s[^#\n;]+)/i,/^(?:section\s[^\n]+)/i,/^(?:[^:\n]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[6,7],inclusive:!1},acc_descr:{rules:[4],inclusive:!1},acc_title:{rules:[2],inclusive:!1},callbackargs:{rules:[21,22],inclusive:!1},callbackname:{rules:[18,19,20],inclusive:!1},href:{rules:[15,16],inclusive:!1},click:{rules:[24,25],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,17,23,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}}}();function L(){this.yy={}}return C.lexer=A,(0,i.eW)(L,"Parser"),L.prototype=C,C.Parser=L,new L}();u.parser=u;var d=u;s.extend(o),s.extend(l),s.extend(c);var p,g,f={friday:5,saturday:6},m="",y="",v=void 0,x="",b=[],w=[],k=new Map,T=[],_=[],E="",S="",C=["active","done","crit","milestone"],A=[],L=!1,M=!1,N="sunday",I="saturday",R=0,D=(0,i.eW)((function(){T=[],_=[],E="",A=[],dt=0,p=void 0,g=void 0,mt=[],m="",y="",S="",v=void 0,x="",b=[],w=[],L=!1,M=!1,R=0,k=new Map,(0,i.ZH)(),N="sunday",I="saturday"}),"clear"),O=(0,i.eW)((function(t){y=t}),"setAxisFormat"),P=(0,i.eW)((function(){return y}),"getAxisFormat"),$=(0,i.eW)((function(t){v=t}),"setTickInterval"),B=(0,i.eW)((function(){return v}),"getTickInterval"),F=(0,i.eW)((function(t){x=t}),"setTodayMarker"),W=(0,i.eW)((function(){return x}),"getTodayMarker"),z=(0,i.eW)((function(t){m=t}),"setDateFormat"),Z=(0,i.eW)((function(){L=!0}),"enableInclusiveEndDates"),Y=(0,i.eW)((function(){return L}),"endDatesAreInclusive"),U=(0,i.eW)((function(){M=!0}),"enableTopAxis"),G=(0,i.eW)((function(){return M}),"topAxisEnabled"),V=(0,i.eW)((function(t){S=t}),"setDisplayMode"),q=(0,i.eW)((function(){return S}),"getDisplayMode"),j=(0,i.eW)((function(){return m}),"getDateFormat"),H=(0,i.eW)((function(t){b=t.toLowerCase().split(/[\s,]+/)}),"setIncludes"),X=(0,i.eW)((function(){return b}),"getIncludes"),K=(0,i.eW)((function(t){w=t.toLowerCase().split(/[\s,]+/)}),"setExcludes"),Q=(0,i.eW)((function(){return w}),"getExcludes"),J=(0,i.eW)((function(){return k}),"getLinks"),tt=(0,i.eW)((function(t){E=t,T.push(t)}),"addSection"),et=(0,i.eW)((function(){return T}),"getSections"),nt=(0,i.eW)((function(){let t=wt(),e=0;for(;!t&&e<10;)t=wt(),e++;return _=mt}),"getTasks"),rt=(0,i.eW)((function(t,e,n,r){return!r.includes(t.format(e.trim()))&&(!(!n.includes("weekends")||t.isoWeekday()!==f[I]&&t.isoWeekday()!==f[I]+1)||!!n.includes(t.format("dddd").toLowerCase())||n.includes(t.format(e.trim())))}),"isInvalidDate"),it=(0,i.eW)((function(t){N=t}),"setWeekday"),at=(0,i.eW)((function(){return N}),"getWeekday"),st=(0,i.eW)((function(t){I=t}),"setWeekend"),ot=(0,i.eW)((function(t,e,n,r){if(!n.length||t.manualEndTime)return;let i,a;i=t.startTime instanceof Date?s(t.startTime):s(t.startTime,e,!0),i=i.add(1,"d"),a=t.endTime instanceof Date?s(t.endTime):s(t.endTime,e,!0);const[o,l]=lt(i,a,e,n,r);t.endTime=o.toDate(),t.renderEndTime=l}),"checkTaskDates"),lt=(0,i.eW)((function(t,e,n,r,i){let a=!1,s=null;for(;t<=e;)a||(s=e.toDate()),a=rt(t,n,r,i),a&&(e=e.add(1,"d")),t=t.add(1,"d");return[e,s]}),"fixTaskDates"),ct=(0,i.eW)((function(t,e,n){n=n.trim();const r=/^after\s+(?[\d\w- ]+)/.exec(n);if(null!==r){let t=null;for(const e of r.groups.ids.split(" ")){let n=xt(e);void 0!==n&&(!t||n.endTime>t.endTime)&&(t=n)}if(t)return t.endTime;const e=new Date;return e.setHours(0,0,0,0),e}let a=s(n,e.trim(),!0);if(a.isValid())return a.toDate();{i.cM.debug("Invalid date:"+n),i.cM.debug("With date format:"+e.trim());const t=new Date(n);if(void 0===t||isNaN(t.getTime())||t.getFullYear()<-1e4||t.getFullYear()>1e4)throw new Error("Invalid date:"+n);return t}}),"getStartDate"),ht=(0,i.eW)((function(t){const e=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(t.trim());return null!==e?[Number.parseFloat(e[1]),e[2]]:[NaN,"ms"]}),"parseDuration"),ut=(0,i.eW)((function(t,e,n,r=!1){n=n.trim();const i=/^until\s+(?[\d\w- ]+)/.exec(n);if(null!==i){let t=null;for(const e of i.groups.ids.split(" ")){let n=xt(e);void 0!==n&&(!t||n.startTime{window.open(n,"_self")})),k.set(t,n))})),Tt(t,"clickable")}),"setLink"),Tt=(0,i.eW)((function(t,e){t.split(",").forEach((function(t){let n=xt(t);void 0!==n&&n.classes.push(e)}))}),"setClass"),_t=(0,i.eW)((function(t,e,n){if("loose"!==(0,i.nV)().securityLevel)return;if(void 0===e)return;let a=[];if("string"==typeof n){a=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let t=0;t{r.w8.runFunc(e,...a)}))}),"setClickFun"),Et=(0,i.eW)((function(t,e){A.push((function(){const n=document.querySelector(`[id="${t}"]`);null!==n&&n.addEventListener("click",(function(){e()}))}),(function(){const n=document.querySelector(`[id="${t}-text"]`);null!==n&&n.addEventListener("click",(function(){e()}))}))}),"pushFun"),St=(0,i.eW)((function(t,e,n){t.split(",").forEach((function(t){_t(t,e,n)})),Tt(t,"clickable")}),"setClickEvent"),Ct=(0,i.eW)((function(t){A.forEach((function(e){e(t)}))}),"bindFunctions"),At={getConfig:(0,i.eW)((()=>(0,i.nV)().gantt),"getConfig"),clear:D,setDateFormat:z,getDateFormat:j,enableInclusiveEndDates:Z,endDatesAreInclusive:Y,enableTopAxis:U,topAxisEnabled:G,setAxisFormat:O,getAxisFormat:P,setTickInterval:$,getTickInterval:B,setTodayMarker:F,getTodayMarker:W,setAccTitle:i.GN,getAccTitle:i.eu,setDiagramTitle:i.g2,getDiagramTitle:i.Kr,setDisplayMode:V,getDisplayMode:q,setAccDescription:i.U$,getAccDescription:i.Mx,addSection:tt,getSections:et,getTasks:nt,addTask:vt,findTaskById:xt,addTaskOrg:bt,setIncludes:H,getIncludes:X,setExcludes:K,getExcludes:Q,setClickEvent:St,setLink:kt,getLinks:J,bindFunctions:Ct,parseDuration:ht,isInvalidDate:rt,setWeekday:it,getWeekday:at,setWeekend:st};function Lt(t,e,n){let r=!0;for(;r;)r=!1,n.forEach((function(n){const i=new RegExp("^\\s*"+n+"\\s*$");t[0].match(i)&&(e[n]=!0,t.shift(1),r=!0)}))}(0,i.eW)(Lt,"getTaskTags");var Mt,Nt=(0,i.eW)((function(){i.cM.debug("Something is calling, setConf, remove the call")}),"setConf"),It={monday:h.Ox9,tuesday:h.YDX,wednesday:h.EFj,thursday:h.Igq,friday:h.y2j,saturday:h.LqH,sunday:h.Zyz},Rt=(0,i.eW)(((t,e)=>{let n=[...t].map((()=>-1/0)),r=[...t].sort(((t,e)=>t.startTime-e.startTime||t.order-e.order)),i=0;for(const t of r)for(let r=0;r=n[r]){n[r]=t.endTime,t.order=r+e,r>i&&(i=r);break}return i}),"getMaxIntersections"),Dt={parser:d,db:At,renderer:{setConf:Nt,draw:(0,i.eW)((function(t,e,n,r){const a=(0,i.nV)().gantt,o=(0,i.nV)().securityLevel;let l;"sandbox"===o&&(l=(0,h.Ys)("#i"+e));const c="sandbox"===o?(0,h.Ys)(l.nodes()[0].contentDocument.body):(0,h.Ys)("body"),u="sandbox"===o?l.nodes()[0].contentDocument:document,d=u.getElementById(e);void 0===(Mt=d.parentElement.offsetWidth)&&(Mt=1200),void 0!==a.useWidth&&(Mt=a.useWidth);const p=r.db.getTasks();let g=[];for(const t of p)g.push(t.type);g=S(g);const f={};let m=2*a.topPadding;if("compact"===r.db.getDisplayMode()||"compact"===a.displayMode){const t={};for(const e of p)void 0===t[e.section]?t[e.section]=[e]:t[e.section].push(e);let e=0;for(const n of Object.keys(t)){const r=Rt(t[n],e)+1;e+=r,m+=r*(a.barHeight+a.barGap),f[n]=r}}else{m+=p.length*(a.barHeight+a.barGap);for(const t of g)f[t]=p.filter((e=>e.type===t)).length}d.setAttribute("viewBox","0 0 "+Mt+" "+m);const y=c.select(`[id="${e}"]`),v=(0,h.Xf)().domain([(0,h.VV$)(p,(function(t){return t.startTime})),(0,h.Fp7)(p,(function(t){return t.endTime}))]).rangeRound([0,Mt-a.leftPadding-a.rightPadding]);function x(t,e){const n=t.startTime,r=e.startTime;let i=0;return n>r?i=1:nt.order)))].map((e=>t.find((t=>t.order===e))));y.append("g").selectAll("rect").data(d).enter().append("rect").attr("x",0).attr("y",(function(t,e){return t.order*n+s-2})).attr("width",(function(){return u-a.rightPadding/2})).attr("height",n).attr("class",(function(t){for(const[e,n]of g.entries())if(t.type===n)return"section section"+e%a.numberSectionStyles;return"section section0"}));const p=y.append("g").selectAll("rect").data(t).enter(),f=r.db.getLinks();if(p.append("rect").attr("id",(function(t){return t.id})).attr("rx",3).attr("ry",3).attr("x",(function(t){return t.milestone?v(t.startTime)+o+.5*(v(t.endTime)-v(t.startTime))-.5*l:v(t.startTime)+o})).attr("y",(function(t,e){return t.order*n+s})).attr("width",(function(t){return t.milestone?l:v(t.renderEndTime||t.endTime)-v(t.startTime)})).attr("height",l).attr("transform-origin",(function(t,e){return e=t.order,(v(t.startTime)+o+.5*(v(t.endTime)-v(t.startTime))).toString()+"px "+(e*n+s+.5*l).toString()+"px"})).attr("class",(function(t){let e="";t.classes.length>0&&(e=t.classes.join(" "));let n=0;for(const[e,r]of g.entries())t.type===r&&(n=e%a.numberSectionStyles);let r="";return t.active?t.crit?r+=" activeCrit":r=" active":t.done?r=t.crit?" doneCrit":" done":t.crit&&(r+=" crit"),0===r.length&&(r=" task"),t.milestone&&(r=" milestone "+r),r+=n,r+=" "+e,"task"+r})),p.append("text").attr("id",(function(t){return t.id+"-text"})).text((function(t){return t.task})).attr("font-size",a.fontSize).attr("x",(function(t){let e=v(t.startTime),n=v(t.renderEndTime||t.endTime);t.milestone&&(e+=.5*(v(t.endTime)-v(t.startTime))-.5*l),t.milestone&&(n=e+l);const r=this.getBBox().width;return r>n-e?n+r+1.5*a.leftPadding>u?e+o-5:n+o+5:(n-e)/2+e+o})).attr("y",(function(t,e){return t.order*n+a.barHeight/2+(a.fontSize/2-2)+s})).attr("text-height",l).attr("class",(function(t){const e=v(t.startTime);let n=v(t.endTime);t.milestone&&(n=e+l);const r=this.getBBox().width;let i="";t.classes.length>0&&(i=t.classes.join(" "));let s=0;for(const[e,n]of g.entries())t.type===n&&(s=e%a.numberSectionStyles);let o="";return t.active&&(o=t.crit?"activeCritText"+s:"activeText"+s),t.done?o=t.crit?o+" doneCritText"+s:o+" doneText"+s:t.crit&&(o=o+" critText"+s),t.milestone&&(o+=" milestoneText"),r>n-e?n+r+1.5*a.leftPadding>u?i+" taskTextOutsideLeft taskTextOutside"+s+" "+o:i+" taskTextOutsideRight taskTextOutside"+s+" "+o+" width-"+r:i+" taskText taskText"+s+" "+o+" width-"+r})),"sandbox"===(0,i.nV)().securityLevel){let t;t=(0,h.Ys)("#i"+e);const n=t.nodes()[0].contentDocument;p.filter((function(t){return f.has(t.id)})).each((function(t){var e=n.querySelector("#"+t.id),r=n.querySelector("#"+t.id+"-text");const i=e.parentNode;var a=n.createElement("a");a.setAttribute("xlink:href",f.get(t.id)),a.setAttribute("target","_top"),i.appendChild(a),a.appendChild(e),a.appendChild(r)}))}}function k(t,e,n,o,l,c,h,u){if(0===h.length&&0===u.length)return;let d,p;for(const{startTime:t,endTime:e}of c)(void 0===d||tp)&&(p=e);if(!d||!p)return;if(s(p).diff(s(d),"year")>5)return void i.cM.warn("The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days.");const g=r.db.getDateFormat(),f=[];let m=null,x=s(d);for(;x.valueOf()<=p;)r.db.isInvalidDate(x,g,h,u)?m?m.end=x:m={start:x,end:x}:m&&(f.push(m),m=null),x=x.add(1,"d");y.append("g").selectAll("rect").data(f).enter().append("rect").attr("id",(function(t){return"exclude-"+t.start.format("YYYY-MM-DD")})).attr("x",(function(t){return v(t.start)+n})).attr("y",a.gridLineStartPadding).attr("width",(function(t){const e=t.end.add(1,"day");return v(e)-v(t.start)})).attr("height",l-e-a.gridLineStartPadding).attr("transform-origin",(function(e,r){return(v(e.start)+n+.5*(v(e.end)-v(e.start))).toString()+"px "+(r*t+.5*l).toString()+"px"})).attr("class","exclude-range")}function T(t,e,n,i){let s=(0,h.LLu)(v).tickSize(-i+e+a.gridLineStartPadding).tickFormat((0,h.i$Z)(r.db.getAxisFormat()||a.axisFormat||"%Y-%m-%d"));const o=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(r.db.getTickInterval()||a.tickInterval);if(null!==o){const t=o[1],e=o[2],n=r.db.getWeekday()||a.weekday;switch(e){case"millisecond":s.ticks(h.U8T.every(t));break;case"second":s.ticks(h.S1K.every(t));break;case"minute":s.ticks(h.Z_i.every(t));break;case"hour":s.ticks(h.WQD.every(t));break;case"day":s.ticks(h.rr1.every(t));break;case"week":s.ticks(It[n].every(t));break;case"month":s.ticks(h.F0B.every(t))}}if(y.append("g").attr("class","grid").attr("transform","translate("+t+", "+(i-50)+")").call(s).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),r.db.topAxisEnabled()||a.topAxis){let n=(0,h.F5q)(v).tickSize(-i+e+a.gridLineStartPadding).tickFormat((0,h.i$Z)(r.db.getAxisFormat()||a.axisFormat||"%Y-%m-%d"));if(null!==o){const t=o[1],e=o[2],i=r.db.getWeekday()||a.weekday;switch(e){case"millisecond":n.ticks(h.U8T.every(t));break;case"second":n.ticks(h.S1K.every(t));break;case"minute":n.ticks(h.Z_i.every(t));break;case"hour":n.ticks(h.WQD.every(t));break;case"day":n.ticks(h.rr1.every(t));break;case"week":n.ticks(It[i].every(t));break;case"month":n.ticks(h.F0B.every(t))}}y.append("g").attr("class","grid").attr("transform","translate("+t+", "+e+")").call(n).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}function _(t,e){let n=0;const r=Object.keys(f).map((t=>[t,f[t]]));y.append("g").selectAll("text").data(r).enter().append((function(t){const e=t[0].split(i.SY.lineBreakRegex),n=-(e.length-1)/2,r=u.createElementNS("http://www.w3.org/2000/svg","text");r.setAttribute("dy",n+"em");for(const[t,n]of e.entries()){const e=u.createElementNS("http://www.w3.org/2000/svg","tspan");e.setAttribute("alignment-baseline","central"),e.setAttribute("x","10"),t>0&&e.setAttribute("dy","1em"),e.textContent=n,r.appendChild(e)}return r})).attr("x",10).attr("y",(function(i,a){if(!(a>0))return i[1]*t/2+e;for(let s=0;s`\n .mermaid-main-font {\n font-family: ${t.fontFamily};\n }\n\n .exclude-range {\n fill: ${t.excludeBkgColor};\n }\n\n .section {\n stroke: none;\n opacity: 0.2;\n }\n\n .section0 {\n fill: ${t.sectionBkgColor};\n }\n\n .section2 {\n fill: ${t.sectionBkgColor2};\n }\n\n .section1,\n .section3 {\n fill: ${t.altSectionBkgColor};\n opacity: 0.2;\n }\n\n .sectionTitle0 {\n fill: ${t.titleColor};\n }\n\n .sectionTitle1 {\n fill: ${t.titleColor};\n }\n\n .sectionTitle2 {\n fill: ${t.titleColor};\n }\n\n .sectionTitle3 {\n fill: ${t.titleColor};\n }\n\n .sectionTitle {\n text-anchor: start;\n font-family: ${t.fontFamily};\n }\n\n\n /* Grid and axis */\n\n .grid .tick {\n stroke: ${t.gridColor};\n opacity: 0.8;\n shape-rendering: crispEdges;\n }\n\n .grid .tick text {\n font-family: ${t.fontFamily};\n fill: ${t.textColor};\n }\n\n .grid path {\n stroke-width: 0;\n }\n\n\n /* Today line */\n\n .today {\n fill: none;\n stroke: ${t.todayLineColor};\n stroke-width: 2px;\n }\n\n\n /* Task styling */\n\n /* Default task */\n\n .task {\n stroke-width: 2;\n }\n\n .taskText {\n text-anchor: middle;\n font-family: ${t.fontFamily};\n }\n\n .taskTextOutsideRight {\n fill: ${t.taskTextDarkColor};\n text-anchor: start;\n font-family: ${t.fontFamily};\n }\n\n .taskTextOutsideLeft {\n fill: ${t.taskTextDarkColor};\n text-anchor: end;\n }\n\n\n /* Special case clickable */\n\n .task.clickable {\n cursor: pointer;\n }\n\n .taskText.clickable {\n cursor: pointer;\n fill: ${t.taskTextClickableColor} !important;\n font-weight: bold;\n }\n\n .taskTextOutsideLeft.clickable {\n cursor: pointer;\n fill: ${t.taskTextClickableColor} !important;\n font-weight: bold;\n }\n\n .taskTextOutsideRight.clickable {\n cursor: pointer;\n fill: ${t.taskTextClickableColor} !important;\n font-weight: bold;\n }\n\n\n /* Specific task settings for the sections*/\n\n .taskText0,\n .taskText1,\n .taskText2,\n .taskText3 {\n fill: ${t.taskTextColor};\n }\n\n .task0,\n .task1,\n .task2,\n .task3 {\n fill: ${t.taskBkgColor};\n stroke: ${t.taskBorderColor};\n }\n\n .taskTextOutside0,\n .taskTextOutside2\n {\n fill: ${t.taskTextOutsideColor};\n }\n\n .taskTextOutside1,\n .taskTextOutside3 {\n fill: ${t.taskTextOutsideColor};\n }\n\n\n /* Active task */\n\n .active0,\n .active1,\n .active2,\n .active3 {\n fill: ${t.activeTaskBkgColor};\n stroke: ${t.activeTaskBorderColor};\n }\n\n .activeText0,\n .activeText1,\n .activeText2,\n .activeText3 {\n fill: ${t.taskTextDarkColor} !important;\n }\n\n\n /* Completed task */\n\n .done0,\n .done1,\n .done2,\n .done3 {\n stroke: ${t.doneTaskBorderColor};\n fill: ${t.doneTaskBkgColor};\n stroke-width: 2;\n }\n\n .doneText0,\n .doneText1,\n .doneText2,\n .doneText3 {\n fill: ${t.taskTextDarkColor} !important;\n }\n\n\n /* Tasks on the critical line */\n\n .crit0,\n .crit1,\n .crit2,\n .crit3 {\n stroke: ${t.critBorderColor};\n fill: ${t.critBkgColor};\n stroke-width: 2;\n }\n\n .activeCrit0,\n .activeCrit1,\n .activeCrit2,\n .activeCrit3 {\n stroke: ${t.critBorderColor};\n fill: ${t.activeTaskBkgColor};\n stroke-width: 2;\n }\n\n .doneCrit0,\n .doneCrit1,\n .doneCrit2,\n .doneCrit3 {\n stroke: ${t.critBorderColor};\n fill: ${t.doneTaskBkgColor};\n stroke-width: 2;\n cursor: pointer;\n shape-rendering: crispEdges;\n }\n\n .milestone {\n transform: rotate(45deg) scale(0.8,0.8);\n }\n\n .milestoneText {\n font-style: italic;\n }\n .doneCritText0,\n .doneCritText1,\n .doneCritText2,\n .doneCritText3 {\n fill: ${t.taskTextDarkColor} !important;\n }\n\n .activeCritText0,\n .activeCritText1,\n .activeCritText2,\n .activeCritText3 {\n fill: ${t.taskTextDarkColor} !important;\n }\n\n .titleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${t.titleColor||t.textColor};\n font-family: ${t.fontFamily};\n }\n`),"getStyles")}},4290:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>vt});var r=n(1957),i=n(7207),a=n(7946),s=n(4082),o=n(2491),l=n(3108),c={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},h=s.vZ.gitGraph,u=(0,s.eW)((()=>(0,a.Rb)({...h,...(0,s.iE)().gitGraph})),"getConfig"),d=new i.A((()=>{const t=u(),e=t.mainBranchName,n=t.mainBranchOrder;return{mainBranchName:e,commits:new Map,head:null,branchConfig:new Map([[e,{name:e,order:n}]]),branches:new Map([[e,null]]),currBranch:e,direction:"LR",seq:0,options:{}}}));function p(){return(0,a.MX)({length:7})}function g(t,e){const n=Object.create(null);return t.reduce(((t,r)=>{const i=e(r);return n[i]||(n[i]=!0,t.push(r)),t}),[])}(0,s.eW)(p,"getID"),(0,s.eW)(g,"uniqBy");var f=(0,s.eW)((function(t){d.records.direction=t}),"setDirection"),m=(0,s.eW)((function(t){s.cM.debug("options str",t),t=t?.trim(),t=t||"{}";try{d.records.options=JSON.parse(t)}catch(t){s.cM.error("error while parsing gitGraph options",t.message)}}),"setOptions"),y=(0,s.eW)((function(){return d.records.options}),"getOptions"),v=(0,s.eW)((function(t){let e=t.msg,n=t.id;const r=t.type;let i=t.tags;s.cM.info("commit",e,n,r,i),s.cM.debug("Entering commit:",e,n,r,i);const a=u();n=s.SY.sanitizeText(n,a),e=s.SY.sanitizeText(e,a),i=i?.map((t=>s.SY.sanitizeText(t,a)));const o={id:n||d.records.seq+"-"+p(),message:e,seq:d.records.seq++,type:r??c.NORMAL,tags:i??[],parents:null==d.records.head?[]:[d.records.head.id],branch:d.records.currBranch};d.records.head=o,s.cM.info("main branch",a.mainBranchName),d.records.commits.set(o.id,o),d.records.branches.set(d.records.currBranch,o.id),s.cM.debug("in pushCommit "+o.id)}),"commit"),x=(0,s.eW)((function(t){let e=t.name;const n=t.order;if(e=s.SY.sanitizeText(e,u()),d.records.branches.has(e))throw new Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${e}")`);d.records.branches.set(e,null!=d.records.head?d.records.head.id:null),d.records.branchConfig.set(e,{name:e,order:n}),k(e),s.cM.debug("in createBranch")}),"branch"),b=(0,s.eW)((t=>{let e=t.branch,n=t.id;const r=t.type,i=t.tags,a=u();e=s.SY.sanitizeText(e,a),n&&(n=s.SY.sanitizeText(n,a));const o=d.records.branches.get(d.records.currBranch),l=d.records.branches.get(e),h=o?d.records.commits.get(o):void 0,g=l?d.records.commits.get(l):void 0;if(h&&g&&h.branch===e)throw new Error(`Cannot merge branch '${e}' into itself.`);if(d.records.currBranch===e){const t=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},t}if(void 0===h||!h){const t=new Error(`Incorrect usage of "merge". Current branch (${d.records.currBranch})has no commits`);throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["commit"]},t}if(!d.records.branches.has(e)){const t=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") does not exist");throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:[`branch ${e}`]},t}if(void 0===g||!g){const t=new Error('Incorrect usage of "merge". Branch to be merged ('+e+") has no commits");throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:['"commit"']},t}if(h===g){const t=new Error('Incorrect usage of "merge". Both branches have same head');throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},t}if(n&&d.records.commits.has(n)){const t=new Error('Incorrect usage of "merge". Commit with id:'+n+" already exists, use different custom Id");throw t.hash={text:`merge ${e} ${n} ${r} ${i?.join(" ")}`,token:`merge ${e} ${n} ${r} ${i?.join(" ")}`,expected:[`merge ${e} ${n}_UNIQUE ${r} ${i?.join(" ")}`]},t}const f=l||"",m={id:n||`${d.records.seq}-${p()}`,message:`merged branch ${e} into ${d.records.currBranch}`,seq:d.records.seq++,parents:null==d.records.head?[]:[d.records.head.id,f],branch:d.records.currBranch,type:c.MERGE,customType:r,customId:!!n,tags:i??[]};d.records.head=m,d.records.commits.set(m.id,m),d.records.branches.set(d.records.currBranch,m.id),s.cM.debug(d.records.branches),s.cM.debug("in mergeBranch")}),"merge"),w=(0,s.eW)((function(t){let e=t.id,n=t.targetId,r=t.tags,i=t.parent;s.cM.debug("Entering cherryPick:",e,n,r);const a=u();if(e=s.SY.sanitizeText(e,a),n=s.SY.sanitizeText(n,a),r=r?.map((t=>s.SY.sanitizeText(t,a))),i=s.SY.sanitizeText(i,a),!e||!d.records.commits.has(e)){const t=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw t.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},t}const o=d.records.commits.get(e);if(void 0===o||!o)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(i&&(!Array.isArray(o.parents)||!o.parents.includes(i)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const l=o.branch;if(o.type===c.MERGE&&!i)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!n||!d.records.commits.has(n)){if(l===d.records.currBranch){const t=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw t.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},t}const t=d.records.branches.get(d.records.currBranch);if(void 0===t||!t){const t=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw t.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},t}const a=d.records.commits.get(t);if(void 0===a||!a){const t=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw t.hash={text:`cherryPick ${e} ${n}`,token:`cherryPick ${e} ${n}`,expected:["cherry-pick abc"]},t}const h={id:d.records.seq+"-"+p(),message:`cherry-picked ${o?.message} into ${d.records.currBranch}`,seq:d.records.seq++,parents:null==d.records.head?[]:[d.records.head.id,o.id],branch:d.records.currBranch,type:c.CHERRY_PICK,tags:r?r.filter(Boolean):[`cherry-pick:${o.id}${o.type===c.MERGE?`|parent:${i}`:""}`]};d.records.head=h,d.records.commits.set(h.id,h),d.records.branches.set(d.records.currBranch,h.id),s.cM.debug(d.records.branches),s.cM.debug("in cherryPick")}}),"cherryPick"),k=(0,s.eW)((function(t){if(t=s.SY.sanitizeText(t,u()),!d.records.branches.has(t)){const e=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${t}")`);throw e.hash={text:`checkout ${t}`,token:`checkout ${t}`,expected:[`branch ${t}`]},e}{d.records.currBranch=t;const e=d.records.branches.get(d.records.currBranch);d.records.head=void 0!==e&&e?d.records.commits.get(e)??null:null}}),"checkout");function T(t,e,n){const r=t.indexOf(e);-1===r?t.push(n):t.splice(r,1,n)}function _(t){const e=t.reduce(((t,e)=>t.seq>e.seq?t:e),t[0]);let n="";t.forEach((function(t){n+=t===e?"\t*":"\t|"}));const r=[n,e.id,e.seq];for(const t in d.records.branches)d.records.branches.get(t)===e.id&&r.push(t);if(s.cM.debug(r.join(" ")),e.parents&&2==e.parents.length&&e.parents[0]&&e.parents[1]){const n=d.records.commits.get(e.parents[0]);T(t,e,n),e.parents[1]&&t.push(d.records.commits.get(e.parents[1]))}else{if(0==e.parents.length)return;if(e.parents[0]){const n=d.records.commits.get(e.parents[0]);T(t,e,n)}}_(t=g(t,(t=>t.id)))}(0,s.eW)(T,"upsert"),(0,s.eW)(_,"prettyPrintCommitHistory");var E=(0,s.eW)((function(){s.cM.debug(d.records.commits),_([M()[0]])}),"prettyPrint"),S=(0,s.eW)((function(){d.reset(),(0,s.ZH)()}),"clear"),C=(0,s.eW)((function(){return[...d.records.branchConfig.values()].map(((t,e)=>null!==t.order&&void 0!==t.order?t:{...t,order:parseFloat(`0.${e}`)})).sort(((t,e)=>(t.order??0)-(e.order??0))).map((({name:t})=>({name:t})))}),"getBranchesAsObjArray"),A=(0,s.eW)((function(){return d.records.branches}),"getBranches"),L=(0,s.eW)((function(){return d.records.commits}),"getCommits"),M=(0,s.eW)((function(){const t=[...d.records.commits.values()];return t.forEach((function(t){s.cM.debug(t.id)})),t.sort(((t,e)=>t.seq-e.seq)),t}),"getCommitsArray"),N={commitType:c,getConfig:u,setDirection:f,setOptions:m,getOptions:y,commit:v,branch:x,merge:b,cherryPick:w,checkout:k,prettyPrint:E,clear:S,getBranchesAsObjArray:C,getBranches:A,getCommits:L,getCommitsArray:M,getCurrentBranch:(0,s.eW)((function(){return d.records.currBranch}),"getCurrentBranch"),getDirection:(0,s.eW)((function(){return d.records.direction}),"getDirection"),getHead:(0,s.eW)((function(){return d.records.head}),"getHead"),setAccTitle:s.GN,getAccTitle:s.eu,getAccDescription:s.Mx,setAccDescription:s.U$,setDiagramTitle:s.g2,getDiagramTitle:s.Kr},I=(0,s.eW)(((t,e)=>{(0,r.A)(t,e),t.dir&&e.setDirection(t.dir);for(const n of t.statements)R(n,e)}),"populate"),R=(0,s.eW)(((t,e)=>{const n={Commit:(0,s.eW)((t=>e.commit(D(t))),"Commit"),Branch:(0,s.eW)((t=>e.branch(O(t))),"Branch"),Merge:(0,s.eW)((t=>e.merge(P(t))),"Merge"),Checkout:(0,s.eW)((t=>e.checkout($(t))),"Checkout"),CherryPicking:(0,s.eW)((t=>e.cherryPick(B(t))),"CherryPicking")}[t.$type];n?n(t):s.cM.error(`Unknown statement type: ${t.$type}`)}),"parseStatement"),D=(0,s.eW)((t=>({id:t.id,msg:t.message??"",type:void 0!==t.type?c[t.type]:c.NORMAL,tags:t.tags??void 0})),"parseCommit"),O=(0,s.eW)((t=>({name:t.name,order:t.order??0})),"parseBranch"),P=(0,s.eW)((t=>({branch:t.branch,id:t.id??"",type:void 0!==t.type?c[t.type]:void 0,tags:t.tags??void 0})),"parseMerge"),$=(0,s.eW)((t=>t.branch),"parseCheckout"),B=(0,s.eW)((t=>({id:t.id,targetId:"",tags:0===t.tags?.length?void 0:t.tags,parent:t.parent})),"parseCherryPicking"),F={parse:(0,s.eW)((async t=>{const e=await(0,o.Qc)("gitGraph",t);s.cM.debug(e),I(e,N)}),"parse")},W=(0,s.nV)(),z=W?.gitGraph,Z=10,Y=40,U=new Map,G=new Map,V=new Map,q=[],j=0,H="LR",X=(0,s.eW)((()=>{U.clear(),G.clear(),V.clear(),j=0,q=[],H="LR"}),"clear"),K=(0,s.eW)((t=>{const e=document.createElementNS("http://www.w3.org/2000/svg","text");return("string"==typeof t?t.split(/\\n|\n|/gi):t).forEach((t=>{const n=document.createElementNS("http://www.w3.org/2000/svg","tspan");n.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),n.setAttribute("dy","1em"),n.setAttribute("x","0"),n.setAttribute("class","row"),n.textContent=t.trim(),e.appendChild(n)})),e}),"drawText"),Q=(0,s.eW)((t=>{let e,n,r;return"BT"===H?(n=(0,s.eW)(((t,e)=>t<=e),"comparisonFunc"),r=1/0):(n=(0,s.eW)(((t,e)=>t>=e),"comparisonFunc"),r=0),t.forEach((t=>{const i="TB"===H||"BT"==H?G.get(t)?.y:G.get(t)?.x;void 0!==i&&n(i,r)&&(e=t,r=i)})),e}),"findClosestParent"),J=(0,s.eW)((t=>{let e="",n=1/0;return t.forEach((t=>{const r=G.get(t).y;r<=n&&(e=t,n=r)})),e||void 0}),"findClosestParentBT"),tt=(0,s.eW)(((t,e,n)=>{let r=n,i=n;const a=[];t.forEach((t=>{const n=e.get(t);if(!n)throw new Error(`Commit not found for key ${t}`);n.parents.length?(r=nt(n),i=Math.max(r,i)):a.push(n),rt(n,r)})),r=i,a.forEach((t=>{it(t,r,n)})),t.forEach((t=>{const n=e.get(t);if(n?.parents.length){const t=J(n.parents);r=G.get(t).y-Y,r<=i&&(i=r);const e=U.get(n.branch).pos,a=r-Z;G.set(n.id,{x:e,y:a})}}))}),"setParallelBTPos"),et=(0,s.eW)((t=>{const e=Q(t.parents.filter((t=>null!==t)));if(!e)throw new Error(`Closest parent not found for commit ${t.id}`);const n=G.get(e)?.y;if(void 0===n)throw new Error(`Closest parent position not found for commit ${t.id}`);return n}),"findClosestParentPos"),nt=(0,s.eW)((t=>et(t)+Y),"calculateCommitPosition"),rt=(0,s.eW)(((t,e)=>{const n=U.get(t.branch);if(!n)throw new Error(`Branch not found for commit ${t.id}`);const r=n.pos,i=e+Z;return G.set(t.id,{x:r,y:i}),{x:r,y:i}}),"setCommitPosition"),it=(0,s.eW)(((t,e,n)=>{const r=U.get(t.branch);if(!r)throw new Error(`Branch not found for commit ${t.id}`);const i=e+n,a=r.pos;G.set(t.id,{x:a,y:i})}),"setRootPosition"),at=(0,s.eW)(((t,e,n,r,i,a)=>{if(a===c.HIGHLIGHT)t.append("rect").attr("x",n.x-10).attr("y",n.y-10).attr("width",20).attr("height",20).attr("class",`commit ${e.id} commit-highlight${i%8} ${r}-outer`),t.append("rect").attr("x",n.x-6).attr("y",n.y-6).attr("width",12).attr("height",12).attr("class",`commit ${e.id} commit${i%8} ${r}-inner`);else if(a===c.CHERRY_PICK)t.append("circle").attr("cx",n.x).attr("cy",n.y).attr("r",10).attr("class",`commit ${e.id} ${r}`),t.append("circle").attr("cx",n.x-3).attr("cy",n.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${e.id} ${r}`),t.append("circle").attr("cx",n.x+3).attr("cy",n.y+2).attr("r",2.75).attr("fill","#fff").attr("class",`commit ${e.id} ${r}`),t.append("line").attr("x1",n.x+3).attr("y1",n.y+1).attr("x2",n.x).attr("y2",n.y-5).attr("stroke","#fff").attr("class",`commit ${e.id} ${r}`),t.append("line").attr("x1",n.x-3).attr("y1",n.y+1).attr("x2",n.x).attr("y2",n.y-5).attr("stroke","#fff").attr("class",`commit ${e.id} ${r}`);else{const s=t.append("circle");if(s.attr("cx",n.x),s.attr("cy",n.y),s.attr("r",e.type===c.MERGE?9:10),s.attr("class",`commit ${e.id} commit${i%8}`),a===c.MERGE){const a=t.append("circle");a.attr("cx",n.x),a.attr("cy",n.y),a.attr("r",6),a.attr("class",`commit ${r} ${e.id} commit${i%8}`)}a===c.REVERSE&&t.append("path").attr("d",`M ${n.x-5},${n.y-5}L${n.x+5},${n.y+5}M${n.x-5},${n.y+5}L${n.x+5},${n.y-5}`).attr("class",`commit ${r} ${e.id} commit${i%8}`)}}),"drawCommitBullet"),st=(0,s.eW)(((t,e,n,r)=>{if(e.type!==c.CHERRY_PICK&&(e.customId&&e.type===c.MERGE||e.type!==c.MERGE)&&z?.showCommitLabel){const i=t.append("g"),a=i.insert("rect").attr("class","commit-label-bkg"),s=i.append("text").attr("x",r).attr("y",n.y+25).attr("class","commit-label").text(e.id),o=s.node()?.getBBox();if(o&&(a.attr("x",n.posWithOffset-o.width/2-2).attr("y",n.y+13.5).attr("width",o.width+4).attr("height",o.height+4),"TB"===H||"BT"===H?(a.attr("x",n.x-(o.width+16+5)).attr("y",n.y-12),s.attr("x",n.x-(o.width+16)).attr("y",n.y+o.height-12)):s.attr("x",n.posWithOffset-o.width/2),z.rotateCommitLabel))if("TB"===H||"BT"===H)s.attr("transform","rotate(-45, "+n.x+", "+n.y+")"),a.attr("transform","rotate(-45, "+n.x+", "+n.y+")");else{const t=-7.5-(o.width+10)/25*9.5,e=10+o.width/25*8.5;i.attr("transform","translate("+t+", "+e+") rotate(-45, "+r+", "+n.y+")")}}}),"drawCommitLabel"),ot=(0,s.eW)(((t,e,n,r)=>{if(e.tags.length>0){let i=0,a=0,s=0;const o=[];for(const r of e.tags.reverse()){const e=t.insert("polygon"),l=t.append("circle"),c=t.append("text").attr("y",n.y-16-i).attr("class","tag-label").text(r),h=c.node()?.getBBox();if(!h)throw new Error("Tag bbox not found");a=Math.max(a,h.width),s=Math.max(s,h.height),c.attr("x",n.posWithOffset-h.width/2),o.push({tag:c,hole:l,rect:e,yOffset:i}),i+=20}for(const{tag:t,hole:e,rect:i,yOffset:l}of o){const o=s/2,c=n.y-19.2-l;if(i.attr("class","tag-label-bkg").attr("points",`\n ${r-a/2-2},${c+2} \n ${r-a/2-2},${c-2}\n ${n.posWithOffset-a/2-4},${c-o-2}\n ${n.posWithOffset+a/2+4},${c-o-2}\n ${n.posWithOffset+a/2+4},${c+o+2}\n ${n.posWithOffset-a/2-4},${c+o+2}`),e.attr("cy",c).attr("cx",r-a/2+2).attr("r",1.5).attr("class","tag-hole"),"TB"===H||"BT"===H){const s=r+l;i.attr("class","tag-label-bkg").attr("points",`\n ${n.x},${s+2}\n ${n.x},${s-2}\n ${n.x+Z},${s-o-2}\n ${n.x+Z+a+4},${s-o-2}\n ${n.x+Z+a+4},${s+o+2}\n ${n.x+Z},${s+o+2}`).attr("transform","translate(12,12) rotate(45, "+n.x+","+r+")"),e.attr("cx",n.x+2).attr("cy",s).attr("transform","translate(12,12) rotate(45, "+n.x+","+r+")"),t.attr("x",n.x+5).attr("y",s+3).attr("transform","translate(14,14) rotate(45, "+n.x+","+r+")")}}}}),"drawCommitTags"),lt=(0,s.eW)((t=>{switch(t.customType??t.type){case c.NORMAL:return"commit-normal";case c.REVERSE:return"commit-reverse";case c.HIGHLIGHT:return"commit-highlight";case c.MERGE:return"commit-merge";case c.CHERRY_PICK:return"commit-cherry-pick";default:return"commit-normal"}}),"getCommitClassType"),ct=(0,s.eW)(((t,e,n,r)=>{const i={x:0,y:0};if(!(t.parents.length>0))return"TB"===e?30:"BT"===e?(r.get(t.id)??i).y-Y:0;{const n=Q(t.parents);if(n){const a=r.get(n)??i;return"TB"===e?a.y+Y:"BT"===e?(r.get(t.id)??i).y-Y:a.x+Y}}return 0}),"calculatePosition"),ht=(0,s.eW)(((t,e,n)=>{const r="BT"===H&&n?e:e+Z,i="TB"===H||"BT"===H?r:U.get(t.branch)?.pos,a="TB"===H||"BT"===H?U.get(t.branch)?.pos:r;if(void 0===a||void 0===i)throw new Error(`Position were undefined for commit ${t.id}`);return{x:a,y:i,posWithOffset:r}}),"getCommitPosition"),ut=(0,s.eW)(((t,e,n)=>{if(!z)throw new Error("GitGraph config not found");const r=t.append("g").attr("class","commit-bullets"),i=t.append("g").attr("class","commit-labels");let a="TB"===H||"BT"===H?30:0;const o=[...e.keys()],l=z?.parallelCommits??!1,c=(0,s.eW)(((t,n)=>{const r=e.get(t)?.seq,i=e.get(n)?.seq;return void 0!==r&&void 0!==i?r-i:0}),"sortKeys");let h=o.sort(c);"BT"===H&&(l&&tt(h,e,a),h=h.reverse()),h.forEach((t=>{const s=e.get(t);if(!s)throw new Error(`Commit not found for key ${t}`);l&&(a=ct(s,H,a,G));const o=ht(s,a,l);if(n){const t=lt(s),e=s.customType??s.type,n=U.get(s.branch)?.index??0;at(r,s,o,t,n,e),st(i,s,o,a),ot(i,s,o,a)}"TB"===H||"BT"===H?G.set(s.id,{x:o.x,y:o.posWithOffset}):G.set(s.id,{x:o.posWithOffset,y:o.y}),a="BT"===H&&l?a+Y:a+Y+Z,a>j&&(j=a)}))}),"drawCommits"),dt=(0,s.eW)(((t,e,n,r,i)=>{const a=("TB"===H||"BT"===H?n.xt.branch===a),"isOnBranchToGetCurve"),l=(0,s.eW)((n=>n.seq>t.seq&&n.seql(t)&&o(t)))}),"shouldRerouteArrow"),pt=(0,s.eW)(((t,e,n=0)=>{const r=t+Math.abs(t-e)/2;if(n>5)return r;if(q.every((t=>Math.abs(t-r)>=10)))return q.push(r),r;const i=Math.abs(t-e);return pt(t,e-i/5,n+1)}),"findLane"),gt=(0,s.eW)(((t,e,n,r)=>{const i=G.get(e.id),a=G.get(n.id);if(void 0===i||void 0===a)throw new Error(`Commit positions not found for commits ${e.id} and ${n.id}`);const s=dt(e,n,i,a,r);let o,l="",h="",u=0,d=0,p=U.get(n.branch)?.index;if(n.type===c.MERGE&&e.id!==n.parents[0]&&(p=U.get(e.branch)?.index),s){l="A 10 10, 0, 0, 0,",h="A 10 10, 0, 0, 1,",u=10,d=10;const t=i.ya.x&&(l="A 20 20, 0, 0, 0,",h="A 20 20, 0, 0, 1,",u=20,d=20,o=n.type===c.MERGE&&e.id!==n.parents[0]?`M ${i.x} ${i.y} L ${i.x} ${a.y-u} ${h} ${i.x-d} ${a.y} L ${a.x} ${a.y}`:`M ${i.x} ${i.y} L ${a.x+u} ${i.y} ${l} ${a.x} ${i.y+d} L ${a.x} ${a.y}`),i.x===a.x&&(o=`M ${i.x} ${i.y} L ${a.x} ${a.y}`)):"BT"===H?(i.xa.x&&(l="A 20 20, 0, 0, 0,",h="A 20 20, 0, 0, 1,",u=20,d=20,o=n.type===c.MERGE&&e.id!==n.parents[0]?`M ${i.x} ${i.y} L ${i.x} ${a.y+u} ${l} ${i.x-d} ${a.y} L ${a.x} ${a.y}`:`M ${i.x} ${i.y} L ${a.x-u} ${i.y} ${l} ${a.x} ${i.y-d} L ${a.x} ${a.y}`),i.x===a.x&&(o=`M ${i.x} ${i.y} L ${a.x} ${a.y}`)):(i.ya.y&&(o=n.type===c.MERGE&&e.id!==n.parents[0]?`M ${i.x} ${i.y} L ${a.x-u} ${i.y} ${l} ${a.x} ${i.y-d} L ${a.x} ${a.y}`:`M ${i.x} ${i.y} L ${i.x} ${a.y+u} ${h} ${i.x+d} ${a.y} L ${a.x} ${a.y}`),i.y===a.y&&(o=`M ${i.x} ${i.y} L ${a.x} ${a.y}`));if(void 0===o)throw new Error("Line definition not found");t.append("path").attr("d",o).attr("class","arrow arrow"+p%8)}),"drawArrow"),ft=(0,s.eW)(((t,e)=>{const n=t.append("g").attr("class","commit-arrows");[...e.keys()].forEach((t=>{const r=e.get(t);r.parents&&r.parents.length>0&&r.parents.forEach((t=>{gt(n,e.get(t),r,e)}))}))}),"drawArrows"),mt=(0,s.eW)(((t,e)=>{const n=t.append("g");e.forEach(((t,e)=>{const r=e%8,i=U.get(t.name)?.pos;if(void 0===i)throw new Error(`Position not found for branch ${t.name}`);const a=n.append("line");a.attr("x1",0),a.attr("y1",i),a.attr("x2",j),a.attr("y2",i),a.attr("class","branch branch"+r),"TB"===H?(a.attr("y1",30),a.attr("x1",i),a.attr("y2",j),a.attr("x2",i)):"BT"===H&&(a.attr("y1",j),a.attr("x1",i),a.attr("y2",30),a.attr("x2",i)),q.push(i);const s=t.name,o=K(s),l=n.insert("rect"),c=n.insert("g").attr("class","branchLabel").insert("g").attr("class","label branch-label"+r);c.node().appendChild(o);const h=o.getBBox();l.attr("class","branchLabelBkg label"+r).attr("rx",4).attr("ry",4).attr("x",-h.width-4-(!0===z?.rotateCommitLabel?30:0)).attr("y",-h.height/2+8).attr("width",h.width+18).attr("height",h.height+4),c.attr("transform","translate("+(-h.width-14-(!0===z?.rotateCommitLabel?30:0))+", "+(i-h.height/2-1)+")"),"TB"===H?(l.attr("x",i-h.width/2-10).attr("y",0),c.attr("transform","translate("+(i-h.width/2-5)+", 0)")):"BT"===H?(l.attr("x",i-h.width/2-10).attr("y",j),c.attr("transform","translate("+(i-h.width/2-5)+", "+j+")")):l.attr("transform","translate(-19, "+(i-h.height/2)+")")}))}),"drawBranches"),yt=(0,s.eW)((function(t,e,n,r,i){return U.set(t,{pos:e,index:n}),e+(50+(i?40:0)+("TB"===H||"BT"===H?r.width/2:0))}),"setBranchPosition"),vt={parser:F,db:N,renderer:{draw:(0,s.eW)((function(t,e,n,r){if(X(),s.cM.debug("in gitgraph renderer",t+"\n","id:",e,n),!z)throw new Error("GitGraph config not found");const i=z.rotateCommitLabel??!1,o=r.db;V=o.getCommits();const c=o.getBranchesAsObjArray();H=o.getDirection();const h=(0,l.Ys)(`[id="${e}"]`);let u=0;c.forEach(((t,e)=>{const n=K(t.name),r=h.append("g"),a=r.insert("g").attr("class","branchLabel"),s=a.insert("g").attr("class","label branch-label");s.node()?.appendChild(n);const o=n.getBBox();u=yt(t.name,u,e,o,i),s.remove(),a.remove(),r.remove()})),ut(h,V,!1),z.showBranches&&mt(h,c),ft(h,V),ut(h,V,!0),a.w8.insertTitle(h,"gitTitleText",z.titleTopMargin??0,o.getDiagramTitle()),(0,s.Rw)(void 0,h,z.diagramPadding,z.useMaxWidth)}),"draw")},styles:(0,s.eW)((t=>`\n .commit-id,\n .commit-msg,\n .branch-label {\n fill: lightgrey;\n color: lightgrey;\n font-family: 'trebuchet ms', verdana, arial, sans-serif;\n font-family: var(--mermaid-font-family);\n }\n ${[0,1,2,3,4,5,6,7].map((e=>`\n .branch-label${e} { fill: ${t["gitBranchLabel"+e]}; }\n .commit${e} { stroke: ${t["git"+e]}; fill: ${t["git"+e]}; }\n .commit-highlight${e} { stroke: ${t["gitInv"+e]}; fill: ${t["gitInv"+e]}; }\n .label${e} { fill: ${t["git"+e]}; }\n .arrow${e} { stroke: ${t["git"+e]}; }\n `)).join("\n")}\n\n .branch {\n stroke-width: 1;\n stroke: ${t.lineColor};\n stroke-dasharray: 2;\n }\n .commit-label { font-size: ${t.commitLabelFontSize}; fill: ${t.commitLabelColor};}\n .commit-label-bkg { font-size: ${t.commitLabelFontSize}; fill: ${t.commitLabelBackground}; opacity: 0.5; }\n .tag-label { font-size: ${t.tagLabelFontSize}; fill: ${t.tagLabelColor};}\n .tag-label-bkg { fill: ${t.tagLabelBackground}; stroke: ${t.tagLabelBorder}; }\n .tag-hole { fill: ${t.textColor}; }\n\n .commit-merge {\n stroke: ${t.primaryColor};\n fill: ${t.primaryColor};\n }\n .commit-reverse {\n stroke: ${t.primaryColor};\n fill: ${t.primaryColor};\n stroke-width: 3;\n }\n .commit-highlight-outer {\n }\n .commit-highlight-inner {\n stroke: ${t.primaryColor};\n fill: ${t.primaryColor};\n }\n\n .arrow { stroke-width: 8; stroke-linecap: round; fill: none}\n .gitTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${t.textColor};\n }\n`),"getStyles")}},3997:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>c});var r=n(2926),i=n(5430),a=n(4082),s=n(2491),o={parse:(0,a.eW)((async t=>{const e=await(0,s.Qc)("info",t);a.cM.debug(e)}),"parse")},l={version:r.X.version},c={parser:o,db:{getVersion:(0,a.eW)((()=>l.version),"getVersion")},renderer:{draw:(0,a.eW)(((t,e,n)=>{a.cM.debug("rendering info diagram\n"+t);const r=(0,i.P)(e);(0,a.v2)(r,100,400,!0),r.append("g").append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size",32).style("text-anchor","middle").text(`v${n}`)}),"draw")}}},8891:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>G});var r=n(279),i=n(4082),a=n(3108),s=function(){var t=(0,i.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[6,8,10,11,12,14,16,17,18],n=[1,9],r=[1,10],a=[1,11],s=[1,12],o=[1,13],l=[1,14],c={trace:(0,i.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,journey:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,title:11,acc_title:12,acc_title_value:13,acc_descr:14,acc_descr_value:15,acc_descr_multiline_value:16,section:17,taskName:18,taskData:19,$accept:0,$end:1},terminals_:{2:"error",4:"journey",6:"EOF",8:"SPACE",10:"NEWLINE",11:"title",12:"acc_title",13:"acc_title_value",14:"acc_descr",15:"acc_descr_value",16:"acc_descr_multiline_value",17:"section",18:"taskName",19:"taskData"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,2]],performAction:(0,i.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 1:return a[o-1];case 2:case 6:case 7:this.$=[];break;case 3:a[o-1].push(a[o]),this.$=a[o-1];break;case 4:case 5:this.$=a[o];break;case 8:r.setDiagramTitle(a[o].substr(6)),this.$=a[o].substr(6);break;case 9:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 10:case 11:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 12:r.addSection(a[o].substr(8)),this.$=a[o].substr(8);break;case 13:r.addTask(a[o-1],a[o]),this.$="task"}}),"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:n,12:r,14:a,16:s,17:o,18:l},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:15,11:n,12:r,14:a,16:s,17:o,18:l},t(e,[2,5]),t(e,[2,6]),t(e,[2,8]),{13:[1,16]},{15:[1,17]},t(e,[2,11]),t(e,[2,12]),{19:[1,18]},t(e,[2,4]),t(e,[2,9]),t(e,[2,10]),t(e,[2,13])],defaultActions:{},parseError:(0,i.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,i.eW)((function(t){var e=this,n=[0],r=[],a=[null],s=[],o=this.table,l="",c=0,h=0,u=0,d=s.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;s.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,i.eW)((function(t){n.length=n.length-2*t,a.length=a.length-t,s.length=s.length-t}),"popStack"),(0,i.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),a.push(p.yytext),s.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=a[a.length-E],A._$={first_line:s[s.length-(E||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(E||1)].first_column,last_column:s[s.length-1].last_column},y&&(A._$.range=[s[s.length-(E||1)].range[0],s[s.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],a,s].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),a=a.slice(0,-1*E),s=s.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),a.push(A.$),s.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},h=function(){return{EOF:1,parseError:(0,i.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,i.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,i.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,i.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,i.eW)((function(){return this._more=!0,this}),"more"),reject:(0,i.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,i.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,i.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,i.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,i.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,i.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,i.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,i.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,i.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,i.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,i.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,i.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,i.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,i.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,i.eW)((function(t,e,n,r){switch(n){case 0:case 1:case 3:case 4:break;case 2:return 10;case 5:return 4;case 6:return 11;case 7:return this.begin("acc_title"),12;case 8:return this.popState(),"acc_title_value";case 9:return this.begin("acc_descr"),14;case 10:return this.popState(),"acc_descr_value";case 11:this.begin("acc_descr_multiline");break;case 12:this.popState();break;case 13:return"acc_descr_multiline_value";case 14:return 17;case 15:return 18;case 16:return 19;case 17:return":";case 18:return 6;case 19:return"INVALID"}}),"anonymous"),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:journey\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^#:\n;]+)/i,/^(?:[^#:\n;]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,9,11,14,15,16,17,18,19],inclusive:!0}}}}();function u(){this.yy={}}return c.lexer=h,(0,i.eW)(u,"Parser"),u.prototype=c,c.Parser=u,new u}();s.parser=s;var o=s,l="",c=[],h=[],u=[],d=(0,i.eW)((function(){c.length=0,h.length=0,l="",u.length=0,(0,i.ZH)()}),"clear"),p=(0,i.eW)((function(t){l=t,c.push(t)}),"addSection"),g=(0,i.eW)((function(){return c}),"getSections"),f=(0,i.eW)((function(){let t=x(),e=0;for(;!t&&e<100;)t=x(),e++;return h.push(...u),h}),"getTasks"),m=(0,i.eW)((function(){const t=[];return h.forEach((e=>{e.people&&t.push(...e.people)})),[...new Set(t)].sort()}),"updateActors"),y=(0,i.eW)((function(t,e){const n=e.substr(1).split(":");let r=0,i=[];1===n.length?(r=Number(n[0]),i=[]):(r=Number(n[0]),i=n[1].split(","));const a=i.map((t=>t.trim())),s={section:l,type:l,people:a,task:t,score:r};u.push(s)}),"addTask"),v=(0,i.eW)((function(t){const e={section:l,type:l,description:t,task:t,classes:[]};h.push(e)}),"addTaskOrg"),x=(0,i.eW)((function(){const t=(0,i.eW)((function(t){return u[t].processed}),"compileTask");let e=!0;for(const[n,r]of u.entries())t(n),e=e&&r.processed;return e}),"compileTasks"),b=(0,i.eW)((function(){return m()}),"getActors"),w={getConfig:(0,i.eW)((()=>(0,i.nV)().journey),"getConfig"),clear:d,setDiagramTitle:i.g2,getDiagramTitle:i.Kr,setAccTitle:i.GN,getAccTitle:i.eu,setAccDescription:i.U$,getAccDescription:i.Mx,addSection:p,getSections:g,getTasks:f,addTask:y,addTaskOrg:v,getActors:b},k=(0,i.eW)((t=>`.label {\n font-family: ${t.fontFamily};\n color: ${t.textColor};\n }\n .mouth {\n stroke: #666;\n }\n\n line {\n stroke: ${t.textColor}\n }\n\n .legend {\n fill: ${t.textColor};\n font-family: ${t.fontFamily};\n }\n\n .label text {\n fill: #333;\n }\n .label {\n color: ${t.textColor}\n }\n\n .face {\n ${t.faceColor?`fill: ${t.faceColor}`:"fill: #FFF8DC"};\n stroke: #999;\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n stroke-width: 1px;\n }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ${t.arrowheadColor};\n }\n\n .edgePath .path {\n stroke: ${t.lineColor};\n stroke-width: 1.5px;\n }\n\n .flowchart-link {\n stroke: ${t.lineColor};\n fill: none;\n }\n\n .edgeLabel {\n background-color: ${t.edgeLabelBackground};\n rect {\n opacity: 0.5;\n }\n text-align: center;\n }\n\n .cluster rect {\n }\n\n .cluster text {\n fill: ${t.titleColor};\n }\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ${t.fontFamily};\n font-size: 12px;\n background: ${t.tertiaryColor};\n border: 1px solid ${t.border2};\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .task-type-0, .section-type-0 {\n ${t.fillType0?`fill: ${t.fillType0}`:""};\n }\n .task-type-1, .section-type-1 {\n ${t.fillType0?`fill: ${t.fillType1}`:""};\n }\n .task-type-2, .section-type-2 {\n ${t.fillType0?`fill: ${t.fillType2}`:""};\n }\n .task-type-3, .section-type-3 {\n ${t.fillType0?`fill: ${t.fillType3}`:""};\n }\n .task-type-4, .section-type-4 {\n ${t.fillType0?`fill: ${t.fillType4}`:""};\n }\n .task-type-5, .section-type-5 {\n ${t.fillType0?`fill: ${t.fillType5}`:""};\n }\n .task-type-6, .section-type-6 {\n ${t.fillType0?`fill: ${t.fillType6}`:""};\n }\n .task-type-7, .section-type-7 {\n ${t.fillType0?`fill: ${t.fillType7}`:""};\n }\n\n .actor-0 {\n ${t.actor0?`fill: ${t.actor0}`:""};\n }\n .actor-1 {\n ${t.actor1?`fill: ${t.actor1}`:""};\n }\n .actor-2 {\n ${t.actor2?`fill: ${t.actor2}`:""};\n }\n .actor-3 {\n ${t.actor3?`fill: ${t.actor3}`:""};\n }\n .actor-4 {\n ${t.actor4?`fill: ${t.actor4}`:""};\n }\n .actor-5 {\n ${t.actor5?`fill: ${t.actor5}`:""};\n }\n`),"getStyles"),T=(0,i.eW)((function(t,e){return(0,r.Mu)(t,e)}),"drawRect"),_=(0,i.eW)((function(t,e){const n=t.append("circle").attr("cx",e.cx).attr("cy",e.cy).attr("class","face").attr("r",15).attr("stroke-width",2).attr("overflow","visible"),r=t.append("g");function s(t){const n=(0,a.Nb1)().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",n).attr("transform","translate("+e.cx+","+(e.cy+2)+")")}function o(t){const n=(0,a.Nb1)().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",n).attr("transform","translate("+e.cx+","+(e.cy+7)+")")}function l(t){t.append("line").attr("class","mouth").attr("stroke",2).attr("x1",e.cx-5).attr("y1",e.cy+7).attr("x2",e.cx+5).attr("y2",e.cy+7).attr("class","mouth").attr("stroke-width","1px").attr("stroke","#666")}return r.append("circle").attr("cx",e.cx-5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),r.append("circle").attr("cx",e.cx+5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),(0,i.eW)(s,"smile"),(0,i.eW)(o,"sad"),(0,i.eW)(l,"ambivalent"),e.score>3?s(r):e.score<3?o(r):l(r),n}),"drawFace"),E=(0,i.eW)((function(t,e){const n=t.append("circle");return n.attr("cx",e.cx),n.attr("cy",e.cy),n.attr("class","actor-"+e.pos),n.attr("fill",e.fill),n.attr("stroke",e.stroke),n.attr("r",e.r),void 0!==n.class&&n.attr("class",n.class),void 0!==e.title&&n.append("title").text(e.title),n}),"drawCircle"),S=(0,i.eW)((function(t,e){return(0,r.yU)(t,e)}),"drawText"),C=(0,i.eW)((function(t,e){function n(t,e,n,r,i){return t+","+e+" "+(t+n)+","+e+" "+(t+n)+","+(e+r-i)+" "+(t+n-1.2*i)+","+(e+r)+" "+t+","+(e+r)}(0,i.eW)(n,"genPoints");const r=t.append("polygon");r.attr("points",n(e.x,e.y,50,20,7)),r.attr("class","labelBox"),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,S(t,e)}),"drawLabel"),A=(0,i.eW)((function(t,e,n){const i=t.append("g"),a=(0,r.kc)();a.x=e.x,a.y=e.y,a.fill=e.fill,a.width=n.width*e.taskCount+n.diagramMarginX*(e.taskCount-1),a.height=n.height,a.class="journey-section section-type-"+e.num,a.rx=3,a.ry=3,T(i,a),I(n)(e.text,i,a.x,a.y,a.width,a.height,{class:"journey-section section-type-"+e.num},n,e.colour)}),"drawSection"),L=-1,M=(0,i.eW)((function(t,e,n){const i=e.x+n.width/2,a=t.append("g");L++,a.append("line").attr("id","task"+L).attr("x1",i).attr("y1",e.y).attr("x2",i).attr("y2",450).attr("class","task-line").attr("stroke-width","1px").attr("stroke-dasharray","4 2").attr("stroke","#666"),_(a,{cx:i,cy:300+30*(5-e.score),score:e.score});const s=(0,r.kc)();s.x=e.x,s.y=e.y,s.fill=e.fill,s.width=n.width,s.height=n.height,s.class="task task-type-"+e.num,s.rx=3,s.ry=3,T(a,s);let o=e.x+14;e.people.forEach((t=>{const n=e.actors[t].color,r={cx:o,cy:e.y,r:7,fill:n,stroke:"#000",title:t,pos:e.actors[t].position};E(a,r),o+=10})),I(n)(e.task,a,s.x,s.y,s.width,s.height,{class:"task"},n,e.colour)}),"drawTask"),N=(0,i.eW)((function(t,e){(0,r.O)(t,e)}),"drawBackgroundRect"),I=function(){function t(t,e,n,i,a,s,o,l){r(e.append("text").attr("x",n+a/2).attr("y",i+s/2+5).style("font-color",l).style("text-anchor","middle").text(t),o)}function e(t,e,n,i,a,s,o,l,c){const{taskFontSize:h,taskFontFamily:u}=l,d=t.split(//gi);for(let t=0;t{const i=O[r].color,a={cx:20,cy:n,r:7,fill:i,stroke:"#000",pos:O[r].position};R.drawCircle(t,a);const s={x:40,y:n+7,fill:"#666",text:r,textMargin:5|e.boxTextMargin};R.drawText(t,s),n+=20}))}(0,i.eW)(P,"drawActorLegend");var $=(0,i.nV)().journey,B=$.leftMargin,F=(0,i.eW)((function(t,e,n,r){const s=(0,i.nV)().journey,o=(0,i.nV)().securityLevel;let l;"sandbox"===o&&(l=(0,a.Ys)("#i"+e));const c="sandbox"===o?(0,a.Ys)(l.nodes()[0].contentDocument.body):(0,a.Ys)("body");W.init();const h=c.select("#"+e);R.initGraphics(h);const u=r.db.getTasks(),d=r.db.getDiagramTitle(),p=r.db.getActors();for(const t in O)delete O[t];let g=0;p.forEach((t=>{O[t]={color:s.actorColours[g%s.actorColours.length],position:g},g++})),P(h),W.insert(0,0,B,50*Object.keys(O).length),Y(h,u,0);const f=W.getBounds();d&&h.append("text").text(d).attr("x",B).attr("font-size","4ex").attr("font-weight","bold").attr("y",25);const m=f.stopy-f.starty+2*s.diagramMarginY,y=B+f.stopx+2*s.diagramMarginX;(0,i.v2)(h,m,y,s.useMaxWidth),h.append("line").attr("x1",B).attr("y1",4*s.height).attr("x2",y-B-4).attr("y2",4*s.height).attr("stroke-width",4).attr("stroke","black").attr("marker-end","url(#arrowhead)");const v=d?70:0;h.attr("viewBox",`${f.startx} -25 ${y} ${m+v}`),h.attr("preserveAspectRatio","xMinYMin meet"),h.attr("height",m+v+25)}),"draw"),W={data:{startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},verticalPos:0,sequenceItems:[],init:(0,i.eW)((function(){this.sequenceItems=[],this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0}),"init"),updateVal:(0,i.eW)((function(t,e,n,r){void 0===t[e]?t[e]=n:t[e]=r(n,t[e])}),"updateVal"),updateBounds:(0,i.eW)((function(t,e,n,r){const a=(0,i.nV)().journey,s=this;let o=0;function l(l){return(0,i.eW)((function(i){o++;const c=s.sequenceItems.length-o+1;s.updateVal(i,"starty",e-c*a.boxMargin,Math.min),s.updateVal(i,"stopy",r+c*a.boxMargin,Math.max),s.updateVal(W.data,"startx",t-c*a.boxMargin,Math.min),s.updateVal(W.data,"stopx",n+c*a.boxMargin,Math.max),"activation"!==l&&(s.updateVal(i,"startx",t-c*a.boxMargin,Math.min),s.updateVal(i,"stopx",n+c*a.boxMargin,Math.max),s.updateVal(W.data,"starty",e-c*a.boxMargin,Math.min),s.updateVal(W.data,"stopy",r+c*a.boxMargin,Math.max))}),"updateItemBounds")}(0,i.eW)(l,"updateFn"),this.sequenceItems.forEach(l())}),"updateBounds"),insert:(0,i.eW)((function(t,e,n,r){const i=Math.min(t,n),a=Math.max(t,n),s=Math.min(e,r),o=Math.max(e,r);this.updateVal(W.data,"startx",i,Math.min),this.updateVal(W.data,"starty",s,Math.min),this.updateVal(W.data,"stopx",a,Math.max),this.updateVal(W.data,"stopy",o,Math.max),this.updateBounds(i,s,a,o)}),"insert"),bumpVerticalPos:(0,i.eW)((function(t){this.verticalPos=this.verticalPos+t,this.data.stopy=this.verticalPos}),"bumpVerticalPos"),getVerticalPos:(0,i.eW)((function(){return this.verticalPos}),"getVerticalPos"),getBounds:(0,i.eW)((function(){return this.data}),"getBounds")},z=$.sectionFills,Z=$.sectionColours,Y=(0,i.eW)((function(t,e,n){const r=(0,i.nV)().journey;let a="";const s=n+(2*r.height+r.diagramMarginY);let o=0,l="#CCC",c="black",h=0;for(const[n,i]of e.entries()){if(a!==i.section){l=z[o%z.length],h=o%z.length,c=Z[o%Z.length];let s=0;const u=i.section;for(let t=n;t(O[e]&&(t[e]=O[e]),t)),{});i.x=n*r.taskMargin+n*r.width+B,i.y=s,i.width=r.diagramMarginX,i.height=r.diagramMarginY,i.colour=c,i.fill=l,i.num=h,i.actors=u,R.drawTask(t,i,r),W.insert(i.x,i.y,i.x+i.width+r.taskMargin,450)}}),"drawTasks"),U={setConf:D,draw:F},G={parser:o,db:w,renderer:U,styles:k,init:(0,i.eW)((t=>{U.setConf(t.journey),w.clear()}),"init")}},7744:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>E});var r=n(9241),i=n(3583),a=(n(1426),n(6241),n(214),n(7946),n(5430)),s=n(4082),o=n(6500),l=n(2281),c=n(7201),h=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,4],n=[1,13],r=[1,12],i=[1,15],a=[1,16],o=[1,20],l=[1,19],c=[6,7,8],h=[1,26],u=[1,24],d=[1,25],p=[6,7,11],g=[1,31],f=[6,7,11,24],m=[1,6,13,16,17,20,23],y=[1,35],v=[1,36],x=[1,6,7,11,13,16,17,20,23],b=[1,38],w={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"KANBAN",11:"EOF",13:"SPACELIST",16:"ICON",17:"CLASS",20:"NODE_DSTART",21:"NODE_DESCR",22:"NODE_DEND",23:"NODE_ID",24:"SHAPE_DATA"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 6:case 7:return r;case 8:r.getLogger().trace("Stop NL ");break;case 9:r.getLogger().trace("Stop EOF ");break;case 11:r.getLogger().trace("Stop NL2 ");break;case 12:r.getLogger().trace("Stop EOF2 ");break;case 15:r.getLogger().info("Node: ",a[o-1].id),r.addNode(a[o-2].length,a[o-1].id,a[o-1].descr,a[o-1].type,a[o]);break;case 16:r.getLogger().info("Node: ",a[o].id),r.addNode(a[o-1].length,a[o].id,a[o].descr,a[o].type);break;case 17:r.getLogger().trace("Icon: ",a[o]),r.decorateNode({icon:a[o]});break;case 18:case 23:r.decorateNode({class:a[o]});break;case 19:r.getLogger().trace("SPACELIST");break;case 20:r.getLogger().trace("Node: ",a[o-1].id),r.addNode(0,a[o-1].id,a[o-1].descr,a[o-1].type,a[o]);break;case 21:r.getLogger().trace("Node: ",a[o].id),r.addNode(0,a[o].id,a[o].descr,a[o].type);break;case 22:r.decorateNode({icon:a[o]});break;case 27:r.getLogger().trace("node found ..",a[o-2]),this.$={id:a[o-1],descr:a[o-1],type:r.getType(a[o-2],a[o])};break;case 28:this.$={id:a[o],descr:a[o],type:0};break;case 29:r.getLogger().trace("node found ..",a[o-3]),this.$={id:a[o-3],descr:a[o-1],type:r.getType(a[o-2],a[o])};break;case 30:this.$=a[o-1]+a[o];break;case 31:this.$=a[o]}}),"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:e},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:e},{6:n,7:[1,10],9:9,12:11,13:r,14:14,16:i,17:a,18:17,19:18,20:o,23:l},t(c,[2,3]),{1:[2,2]},t(c,[2,4]),t(c,[2,5]),{1:[2,6],6:n,12:21,13:r,14:14,16:i,17:a,18:17,19:18,20:o,23:l},{6:n,9:22,12:11,13:r,14:14,16:i,17:a,18:17,19:18,20:o,23:l},{6:h,7:u,10:23,11:d},t(p,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:o,23:l}),t(p,[2,19]),t(p,[2,21],{15:30,24:g}),t(p,[2,22]),t(p,[2,23]),t(f,[2,25]),t(f,[2,26]),t(f,[2,28],{20:[1,32]}),{21:[1,33]},{6:h,7:u,10:34,11:d},{1:[2,7],6:n,12:21,13:r,14:14,16:i,17:a,18:17,19:18,20:o,23:l},t(m,[2,14],{7:y,11:v}),t(x,[2,8]),t(x,[2,9]),t(x,[2,10]),t(p,[2,16],{15:37,24:g}),t(p,[2,17]),t(p,[2,18]),t(p,[2,20],{24:b}),t(f,[2,31]),{21:[1,39]},{22:[1,40]},t(m,[2,13],{7:y,11:v}),t(x,[2,11]),t(x,[2,12]),t(p,[2,15],{24:b}),t(f,[2,30]),{22:[1,41]},t(f,[2,27]),t(f,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},k=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:return this.pushState("shapeData"),e.yytext="",24;case 1:return this.pushState("shapeDataStr"),24;case 2:return this.popState(),24;case 3:const n=/\n\s*/g;return e.yytext=e.yytext.replace(n,"
    "),24;case 4:return 24;case 5:case 10:case 29:case 32:this.popState();break;case 6:return t.getLogger().trace("Found comment",e.yytext),6;case 7:return 8;case 8:this.begin("CLASS");break;case 9:return this.popState(),17;case 11:t.getLogger().trace("Begin icon"),this.begin("ICON");break;case 12:return t.getLogger().trace("SPACELINE"),6;case 13:return 7;case 14:return 16;case 15:t.getLogger().trace("end icon"),this.popState();break;case 16:return t.getLogger().trace("Exploding node"),this.begin("NODE"),20;case 17:return t.getLogger().trace("Cloud"),this.begin("NODE"),20;case 18:return t.getLogger().trace("Explosion Bang"),this.begin("NODE"),20;case 19:return t.getLogger().trace("Cloud Bang"),this.begin("NODE"),20;case 20:case 21:case 22:case 23:return this.begin("NODE"),20;case 24:return 13;case 25:return 23;case 26:return 11;case 27:this.begin("NSTR2");break;case 28:return"NODE_DESCR";case 30:t.getLogger().trace("Starting NSTR"),this.begin("NSTR");break;case 31:return t.getLogger().trace("description:",e.yytext),"NODE_DESCR";case 33:return this.popState(),t.getLogger().trace("node end ))"),"NODE_DEND";case 34:return this.popState(),t.getLogger().trace("node end )"),"NODE_DEND";case 35:return this.popState(),t.getLogger().trace("node end ...",e.yytext),"NODE_DEND";case 36:case 39:case 40:return this.popState(),t.getLogger().trace("node end (("),"NODE_DEND";case 37:case 38:return this.popState(),t.getLogger().trace("node end (-"),"NODE_DEND";case 41:case 42:return t.getLogger().trace("Long description:",e.yytext),21}}),"anonymous"),rules:[/^(?:@\{)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^\"]+)/i,/^(?:[^}^"]+)/i,/^(?:\})/i,/^(?:\s*%%.*)/i,/^(?:kanban\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}@]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{shapeDataEndBracket:{rules:[],inclusive:!1},shapeDataStr:{rules:[2,3],inclusive:!1},shapeData:{rules:[1,4,5],inclusive:!1},CLASS:{rules:[9,10],inclusive:!1},ICON:{rules:[14,15],inclusive:!1},NSTR2:{rules:[28,29],inclusive:!1},NSTR:{rules:[31,32],inclusive:!1},NODE:{rules:[27,30,33,34,35,36,37,38,39,40,41,42],inclusive:!1},INITIAL:{rules:[0,6,7,8,11,12,13,16,17,18,19,20,21,22,23,24,25,26],inclusive:!0}}}}();function T(){this.yy={}}return w.lexer=k,(0,s.eW)(T,"Parser"),T.prototype=w,w.Parser=T,new T}();h.parser=h;var u=h,d=[],p=[],g=0,f={},m=(0,s.eW)((()=>{d=[],p=[],g=0,f={}}),"clear"),y=(0,s.eW)((t=>{if(0===d.length)return null;const e=d[0].level;let n=null;for(let t=d.length-1;t>=0;t--)if(d[t].level!==e||n||(n=d[t]),d[t].levelt.parentId===r.id));for(const e of i){const i={id:e.id,parentId:r.id,label:(0,s.oO)(e.label??"",n),isGroup:!1,ticket:e?.ticket,priority:e?.priority,assigned:e?.assigned,icon:e?.icon,shape:"kanbanItem",level:e.level,rx:5,ry:5,cssStyles:["text-align: left"]};t.push(i)}}return{nodes:t,edges:[],other:{},config:(0,s.nV)()}}),"getData"),b=(0,s.eW)(((t,e,n,i,a)=>{const o=(0,s.nV)();let l=o.mindmap?.padding??s.vZ.mindmap.padding;switch(i){case w.ROUNDED_RECT:case w.RECT:case w.HEXAGON:l*=2}const c={id:(0,s.oO)(e,o)||"kbn"+g++,level:t,label:(0,s.oO)(n,o),width:o.mindmap?.maxNodeWidth??s.vZ.mindmap.maxNodeWidth,padding:l,isGroup:!1};if(void 0!==a){let t;t=a.includes("\n")?a+"\n":"{\n"+a+"\n}";const e=(0,r.z)(t,{schema:r.A});if(e.shape&&(e.shape!==e.shape.toLowerCase()||e.shape.includes("_")))throw new Error(`No such shape: ${e.shape}. Shape names should be lowercase.`);e?.shape&&"kanbanItem"===e.shape&&(c.shape=e?.shape),e?.label&&(c.label=e?.label),e?.icon&&(c.icon=e?.icon.toString()),e?.assigned&&(c.assigned=e?.assigned.toString()),e?.ticket&&(c.ticket=e?.ticket.toString()),e?.priority&&(c.priority=e?.priority)}const h=y(t);h?c.parentId=h.id||"kbn"+g++:p.push(c),d.push(c)}),"addNode"),w={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},k={clear:m,addNode:b,getSections:v,getData:x,nodeType:w,getType:(0,s.eW)(((t,e)=>{switch(s.cM.debug("In get type",t,e),t){case"[":return w.RECT;case"(":return")"===e?w.ROUNDED_RECT:w.CLOUD;case"((":return w.CIRCLE;case")":return w.CLOUD;case"))":return w.BANG;case"{{":return w.HEXAGON;default:return w.DEFAULT}}),"getType"),setElementForId:(0,s.eW)(((t,e)=>{f[t]=e}),"setElementForId"),decorateNode:(0,s.eW)((t=>{if(!t)return;const e=(0,s.nV)(),n=d[d.length-1];t.icon&&(n.icon=(0,s.oO)(t.icon,e)),t.class&&(n.cssClasses=(0,s.oO)(t.class,e))}),"decorateNode"),type2Str:(0,s.eW)((t=>{switch(t){case w.DEFAULT:return"no-border";case w.RECT:return"rect";case w.ROUNDED_RECT:return"rounded-rect";case w.CIRCLE:return"circle";case w.CLOUD:return"cloud";case w.BANG:return"bang";case w.HEXAGON:return"hexgon";default:return"no-border"}}),"type2Str"),getLogger:(0,s.eW)((()=>s.cM),"getLogger"),getElementById:(0,s.eW)((t=>f[t]),"getElementById")},T={draw:(0,s.eW)((async(t,e,n,r)=>{s.cM.debug("Rendering kanban diagram\n"+t);const o=r.db.getData(),l=(0,s.nV)();l.htmlLabels=!1;const c=(0,a.P)(e),h=c.append("g");h.attr("class","sections");const u=c.append("g");u.attr("class","items");const d=o.nodes.filter((t=>t.isGroup));let p=0;const g=[];let f=25;for(const t of d){const e=l?.kanban?.sectionWidth||200;p+=1,t.x=e*p+10*(p-1)/2,t.width=e,t.y=0,t.height=3*e,t.rx=5,t.ry=5,t.cssClasses=t.cssClasses+" section-"+p;const n=await(0,i.us)(h,t);f=Math.max(f,n?.labelBBox?.height),g.push(n)}let m=0;for(const t of d){const e=g[m];m+=1;const n=l?.kanban?.sectionWidth||200,r=3*-n/2+f;let a=r;const s=o.nodes.filter((e=>e.parentId===t.id));for(const e of s){if(e.isGroup)throw new Error("Groups within groups are not allowed in Kanban diagrams");e.x=t.x,e.width=n-15;const r=(await(0,i.Lf)(u,e,{config:l})).node().getBBox();e.y=a+r.height/2,await(0,i.aH)(e),a=e.y+r.height/2+5}const c=e.cluster.select("rect"),h=Math.max(a-r+30,50)+(f-25);c.attr("height",h)}(0,s.j7)(void 0,c,l.mindmap?.padding??s.vZ.kanban.padding,l.mindmap?.useMaxWidth??s.vZ.kanban.useMaxWidth)}),"draw")},_=(0,s.eW)((t=>{let e="";for(let e=0;et.darkMode?(0,c.Z)(e,n):(0,l.Z)(e,n)),"adjuster");for(let r=0;r`\n .edge {\n stroke-width: 3;\n }\n ${_(t)}\n .section-root rect, .section-root path, .section-root circle, .section-root polygon {\n fill: ${t.git0};\n }\n .section-root text {\n fill: ${t.gitBranchLabel0};\n }\n .icon-container {\n height:100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n .edge {\n fill: none;\n }\n .cluster-label, .label {\n color: ${t.textColor};\n fill: ${t.textColor};\n }\n .kanban-label {\n dy: 1em;\n alignment-baseline: middle;\n text-anchor: middle;\n dominant-baseline: middle;\n text-align: center;\n }\n`),"getStyles")}},9002:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>z});var r=n(214),i=n(7946),a=n(5430),s=n(4082),o=n(1387),l=n(4607),c=n(3108),h=n(6500),u=n(2281),d=n(7201),p=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,4],n=[1,13],r=[1,12],i=[1,15],a=[1,16],o=[1,20],l=[1,19],c=[6,7,8],h=[1,26],u=[1,24],d=[1,25],p=[6,7,11],g=[1,6,13,15,16,19,22],f=[1,33],m=[1,34],y=[1,6,7,11,13,15,16,19,22],v={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,MINDMAP:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,ICON:15,CLASS:16,nodeWithId:17,nodeWithoutId:18,NODE_DSTART:19,NODE_DESCR:20,NODE_DEND:21,NODE_ID:22,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"MINDMAP",11:"EOF",13:"SPACELIST",15:"ICON",16:"CLASS",19:"NODE_DSTART",20:"NODE_DESCR",21:"NODE_DEND",22:"NODE_ID"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[18,3],[17,1],[17,4]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 6:case 7:return r;case 8:r.getLogger().trace("Stop NL ");break;case 9:r.getLogger().trace("Stop EOF ");break;case 11:r.getLogger().trace("Stop NL2 ");break;case 12:r.getLogger().trace("Stop EOF2 ");break;case 15:r.getLogger().info("Node: ",a[o].id),r.addNode(a[o-1].length,a[o].id,a[o].descr,a[o].type);break;case 16:r.getLogger().trace("Icon: ",a[o]),r.decorateNode({icon:a[o]});break;case 17:case 21:r.decorateNode({class:a[o]});break;case 18:r.getLogger().trace("SPACELIST");break;case 19:r.getLogger().trace("Node: ",a[o].id),r.addNode(0,a[o].id,a[o].descr,a[o].type);break;case 20:r.decorateNode({icon:a[o]});break;case 25:r.getLogger().trace("node found ..",a[o-2]),this.$={id:a[o-1],descr:a[o-1],type:r.getType(a[o-2],a[o])};break;case 26:this.$={id:a[o],descr:a[o],type:r.nodeType.DEFAULT};break;case 27:r.getLogger().trace("node found ..",a[o-3]),this.$={id:a[o-3],descr:a[o-1],type:r.getType(a[o-2],a[o])}}}),"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:e},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:e},{6:n,7:[1,10],9:9,12:11,13:r,14:14,15:i,16:a,17:17,18:18,19:o,22:l},t(c,[2,3]),{1:[2,2]},t(c,[2,4]),t(c,[2,5]),{1:[2,6],6:n,12:21,13:r,14:14,15:i,16:a,17:17,18:18,19:o,22:l},{6:n,9:22,12:11,13:r,14:14,15:i,16:a,17:17,18:18,19:o,22:l},{6:h,7:u,10:23,11:d},t(p,[2,22],{17:17,18:18,14:27,15:[1,28],16:[1,29],19:o,22:l}),t(p,[2,18]),t(p,[2,19]),t(p,[2,20]),t(p,[2,21]),t(p,[2,23]),t(p,[2,24]),t(p,[2,26],{19:[1,30]}),{20:[1,31]},{6:h,7:u,10:32,11:d},{1:[2,7],6:n,12:21,13:r,14:14,15:i,16:a,17:17,18:18,19:o,22:l},t(g,[2,14],{7:f,11:m}),t(y,[2,8]),t(y,[2,9]),t(y,[2,10]),t(p,[2,15]),t(p,[2,16]),t(p,[2,17]),{20:[1,35]},{21:[1,36]},t(g,[2,13],{7:f,11:m}),t(y,[2,11]),t(y,[2,12]),{21:[1,37]},t(p,[2,25]),t(p,[2,27])],defaultActions:{2:[2,1],6:[2,2]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},x=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:return t.getLogger().trace("Found comment",e.yytext),6;case 1:return 8;case 2:this.begin("CLASS");break;case 3:return this.popState(),16;case 4:case 23:case 26:this.popState();break;case 5:t.getLogger().trace("Begin icon"),this.begin("ICON");break;case 6:return t.getLogger().trace("SPACELINE"),6;case 7:return 7;case 8:return 15;case 9:t.getLogger().trace("end icon"),this.popState();break;case 10:return t.getLogger().trace("Exploding node"),this.begin("NODE"),19;case 11:return t.getLogger().trace("Cloud"),this.begin("NODE"),19;case 12:return t.getLogger().trace("Explosion Bang"),this.begin("NODE"),19;case 13:return t.getLogger().trace("Cloud Bang"),this.begin("NODE"),19;case 14:case 15:case 16:case 17:return this.begin("NODE"),19;case 18:return 13;case 19:return 22;case 20:return 11;case 21:this.begin("NSTR2");break;case 22:return"NODE_DESCR";case 24:t.getLogger().trace("Starting NSTR"),this.begin("NSTR");break;case 25:return t.getLogger().trace("description:",e.yytext),"NODE_DESCR";case 27:return this.popState(),t.getLogger().trace("node end ))"),"NODE_DEND";case 28:return this.popState(),t.getLogger().trace("node end )"),"NODE_DEND";case 29:return this.popState(),t.getLogger().trace("node end ...",e.yytext),"NODE_DEND";case 30:case 33:case 34:return this.popState(),t.getLogger().trace("node end (("),"NODE_DEND";case 31:case 32:return this.popState(),t.getLogger().trace("node end (-"),"NODE_DEND";case 35:case 36:return t.getLogger().trace("Long description:",e.yytext),20}}),"anonymous"),rules:[/^(?:\s*%%.*)/i,/^(?:mindmap\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{CLASS:{rules:[3,4],inclusive:!1},ICON:{rules:[8,9],inclusive:!1},NSTR2:{rules:[22,23],inclusive:!1},NSTR:{rules:[25,26],inclusive:!1},NODE:{rules:[21,24,27,28,29,30,31,32,33,34,35,36],inclusive:!1},INITIAL:{rules:[0,1,2,5,6,7,10,11,12,13,14,15,16,17,18,19,20],inclusive:!0}}}}();function b(){this.yy={}}return v.lexer=x,(0,s.eW)(b,"Parser"),b.prototype=v,v.Parser=b,new b}();p.parser=p;var g=p,f=[],m=0,y={},v=(0,s.eW)((()=>{f=[],m=0,y={}}),"clear"),x=(0,s.eW)((function(t){for(let e=f.length-1;e>=0;e--)if(f[e].levelf.length>0?f[0]:null),"getMindmap"),w=(0,s.eW)(((t,e,n,r)=>{s.cM.info("addNode",t,e,n,r);const i=(0,s.nV)();let a=i.mindmap?.padding??s.vZ.mindmap.padding;switch(r){case k.ROUNDED_RECT:case k.RECT:case k.HEXAGON:a*=2}const o={id:m++,nodeId:(0,s.oO)(e,i),level:t,descr:(0,s.oO)(n,i),type:r,children:[],width:i.mindmap?.maxNodeWidth??s.vZ.mindmap.maxNodeWidth,padding:a},l=x(t);if(l)l.children.push(o),f.push(o);else{if(0!==f.length)throw new Error('There can be only one root. No parent could be found for ("'+o.descr+'")');f.push(o)}}),"addNode"),k={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},T={clear:v,addNode:w,getMindmap:b,nodeType:k,getType:(0,s.eW)(((t,e)=>{switch(s.cM.debug("In get type",t,e),t){case"[":return k.RECT;case"(":return")"===e?k.ROUNDED_RECT:k.CLOUD;case"((":return k.CIRCLE;case")":return k.CLOUD;case"))":return k.BANG;case"{{":return k.HEXAGON;default:return k.DEFAULT}}),"getType"),setElementForId:(0,s.eW)(((t,e)=>{y[t]=e}),"setElementForId"),decorateNode:(0,s.eW)((t=>{if(!t)return;const e=(0,s.nV)(),n=f[f.length-1];t.icon&&(n.icon=(0,s.oO)(t.icon,e)),t.class&&(n.class=(0,s.oO)(t.class,e))}),"decorateNode"),type2Str:(0,s.eW)((t=>{switch(t){case k.DEFAULT:return"no-border";case k.RECT:return"rect";case k.ROUNDED_RECT:return"rounded-rect";case k.CIRCLE:return"circle";case k.CLOUD:return"cloud";case k.BANG:return"bang";case k.HEXAGON:return"hexgon";default:return"no-border"}}),"type2Str"),getLogger:(0,s.eW)((()=>s.cM),"getLogger"),getElementById:(0,s.eW)((t=>y[t]),"getElementById")},_=(0,s.eW)((function(t,e,n,r){e.append("path").attr("id","node-"+n.id).attr("class","node-bkg node-"+t.type2Str(n.type)).attr("d",`M0 ${n.height-5} v${10-n.height} q0,-5 5,-5 h${n.width-10} q5,0 5,5 v${n.height-5} H0 Z`),e.append("line").attr("class","node-line-"+r).attr("x1",0).attr("y1",n.height).attr("x2",n.width).attr("y2",n.height)}),"defaultBkg"),E=(0,s.eW)((function(t,e,n){e.append("rect").attr("id","node-"+n.id).attr("class","node-bkg node-"+t.type2Str(n.type)).attr("height",n.height).attr("width",n.width)}),"rectBkg"),S=(0,s.eW)((function(t,e,n){const r=n.width,i=n.height,a=.15*r,s=.25*r,o=.35*r,l=.2*r;e.append("path").attr("id","node-"+n.id).attr("class","node-bkg node-"+t.type2Str(n.type)).attr("d",`M0 0 a${a},${a} 0 0,1 ${.25*r},${-1*r*.1}\n a${o},${o} 1 0,1 ${.4*r},${-1*r*.1}\n a${s},${s} 1 0,1 ${.35*r},${1*r*.2}\n\n a${a},${a} 1 0,1 ${.15*r},${1*i*.35}\n a${l},${l} 1 0,1 ${-1*r*.15},${1*i*.65}\n\n a${s},${a} 1 0,1 ${-1*r*.25},${.15*r}\n a${o},${o} 1 0,1 ${-1*r*.5},0\n a${a},${a} 1 0,1 ${-1*r*.25},${-1*r*.15}\n\n a${a},${a} 1 0,1 ${-1*r*.1},${-1*i*.35}\n a${l},${l} 1 0,1 ${.1*r},${-1*i*.65}\n\n H0 V0 Z`)}),"cloudBkg"),C=(0,s.eW)((function(t,e,n){const r=n.width,i=n.height,a=.15*r;e.append("path").attr("id","node-"+n.id).attr("class","node-bkg node-"+t.type2Str(n.type)).attr("d",`M0 0 a${a},${a} 1 0,0 ${.25*r},${-1*i*.1}\n a${a},${a} 1 0,0 ${.25*r},0\n a${a},${a} 1 0,0 ${.25*r},0\n a${a},${a} 1 0,0 ${.25*r},${1*i*.1}\n\n a${a},${a} 1 0,0 ${.15*r},${1*i*.33}\n a${.8*a},${.8*a} 1 0,0 0,${1*i*.34}\n a${a},${a} 1 0,0 ${-1*r*.15},${1*i*.33}\n\n a${a},${a} 1 0,0 ${-1*r*.25},${.15*i}\n a${a},${a} 1 0,0 ${-1*r*.25},0\n a${a},${a} 1 0,0 ${-1*r*.25},0\n a${a},${a} 1 0,0 ${-1*r*.25},${-1*i*.15}\n\n a${a},${a} 1 0,0 ${-1*r*.1},${-1*i*.33}\n a${.8*a},${.8*a} 1 0,0 0,${-1*i*.34}\n a${a},${a} 1 0,0 ${.1*r},${-1*i*.33}\n\n H0 V0 Z`)}),"bangBkg"),A=(0,s.eW)((function(t,e,n){e.append("circle").attr("id","node-"+n.id).attr("class","node-bkg node-"+t.type2Str(n.type)).attr("r",n.width/2)}),"circleBkg");function L(t,e,n,r,i){return t.insert("polygon",":first-child").attr("points",r.map((function(t){return t.x+","+t.y})).join(" ")).attr("transform","translate("+(i.width-e)/2+", "+n+")")}(0,s.eW)(L,"insertPolygonShape");var M=(0,s.eW)((function(t,e,n){const r=n.height,i=r/4,a=n.width-n.padding+2*i;L(e,a,r,[{x:i,y:0},{x:a-i,y:0},{x:a,y:-r/2},{x:a-i,y:-r},{x:i,y:-r},{x:0,y:-r/2}],n)}),"hexagonBkg"),N=(0,s.eW)((function(t,e,n){e.append("rect").attr("id","node-"+n.id).attr("class","node-bkg node-"+t.type2Str(n.type)).attr("height",n.height).attr("rx",n.padding).attr("ry",n.padding).attr("width",n.width)}),"roundedRectBkg"),I=(0,s.eW)((async function(t,e,n,a,s){const o=s.htmlLabels,l=a%11,c=e.append("g");n.section=l;let h="section-"+l;l<0&&(h+=" section-root"),c.attr("class",(n.class?n.class+" ":"")+"mindmap-node "+h);const u=c.append("g"),d=c.append("g"),p=n.descr.replace(/()/g,"\n");await(0,r.rw)(d,p,{useHtmlLabels:o,width:n.width,classes:"mindmap-node-label"},s),o||d.attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","middle").attr("text-anchor","middle");const g=d.node().getBBox(),[f]=(0,i.VG)(s.fontSize);if(n.height=g.height+1.1*f*.5+n.padding,n.width=g.width+2*n.padding,n.icon)if(n.type===t.nodeType.CIRCLE)n.height+=50,n.width+=50,c.append("foreignObject").attr("height","50px").attr("width",n.width).attr("style","text-align: center;").append("div").attr("class","icon-container").append("i").attr("class","node-icon-"+l+" "+n.icon),d.attr("transform","translate("+n.width/2+", "+(n.height/2-1.5*n.padding)+")");else{n.width+=50;const t=n.height;n.height=Math.max(t,60);const e=Math.abs(n.height-t);c.append("foreignObject").attr("width","60px").attr("height",n.height).attr("style","text-align: center;margin-top:"+e/2+"px;").append("div").attr("class","icon-container").append("i").attr("class","node-icon-"+l+" "+n.icon),d.attr("transform","translate("+(25+n.width/2)+", "+(e/2+n.padding/2)+")")}else if(o){const t=(n.width-g.width)/2,e=(n.height-g.height)/2;d.attr("transform","translate("+t+", "+e+")")}else{const t=n.width/2,e=n.padding/2;d.attr("transform","translate("+t+", "+e+")")}switch(n.type){case t.nodeType.DEFAULT:_(t,u,n,l);break;case t.nodeType.ROUNDED_RECT:N(t,u,n,l);break;case t.nodeType.RECT:E(t,u,n,l);break;case t.nodeType.CIRCLE:u.attr("transform","translate("+n.width/2+", "+ +n.height/2+")"),A(t,u,n,l);break;case t.nodeType.CLOUD:S(t,u,n,l);break;case t.nodeType.BANG:C(t,u,n,l);break;case t.nodeType.HEXAGON:M(t,u,n,l)}return t.setElementForId(n.id,c),n.height}),"drawNode"),R=(0,s.eW)((function(t,e){const n=t.getElementById(e.id),r=e.x||0,i=e.y||0;n.attr("transform","translate("+r+","+i+")")}),"positionNode");async function D(t,e,n,r,i){await I(t,e,n,r,i),n.children&&await Promise.all(n.children.map(((n,a)=>D(t,e,n,r<0?a:r,i))))}function O(t,e){e.edges().map(((e,n)=>{const r=e.data();if(e[0]._private.bodyBounds){const i=e[0]._private.rscratch;s.cM.trace("Edge: ",n,r),t.insert("path").attr("d",`M ${i.startX},${i.startY} L ${i.midX},${i.midY} L${i.endX},${i.endY} `).attr("class","edge section-edge-"+r.section+" edge-depth-"+r.depth)}}))}function P(t,e,n,r){e.add({group:"nodes",data:{id:t.id.toString(),labelText:t.descr,height:t.height,width:t.width,level:r,nodeId:t.id,padding:t.padding,type:t.type},position:{x:t.x,y:t.y}}),t.children&&t.children.forEach((i=>{P(i,e,n,r+1),e.add({group:"edges",data:{id:`${t.id}_${i.id}`,source:t.id,target:i.id,depth:r,section:i.section}})}))}function $(t,e){return new Promise((n=>{const r=(0,c.Ys)("body").append("div").attr("id","cy").attr("style","display:none"),i=(0,o.Z)({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"bezier"}}]});r.remove(),P(t,i,e,0),i.nodes().forEach((function(t){t.layoutDimensions=()=>{const e=t.data();return{w:e.width,h:e.height}}})),i.layout({name:"cose-bilkent",quality:"proof",styleEnabled:!1,animate:!1}).run(),i.ready((t=>{s.cM.info("Ready",t),n(i)}))}))}function B(t,e){e.nodes().map(((e,n)=>{const r=e.data();r.x=e.position().x,r.y=e.position().y,R(t,r);const i=t.getElementById(r.nodeId);s.cM.info("Id:",n,"Position: (",e.position().x,", ",e.position().y,")",r),i.attr("transform",`translate(${e.position().x-r.width/2}, ${e.position().y-r.height/2})`),i.attr("attr",`apa-${n})`)}))}o.Z.use(l),(0,s.eW)(D,"drawNodes"),(0,s.eW)(O,"drawEdges"),(0,s.eW)(P,"addNodes"),(0,s.eW)($,"layoutMindmap"),(0,s.eW)(B,"positionNodes");var F={draw:(0,s.eW)((async(t,e,n,r)=>{s.cM.debug("Rendering mindmap diagram\n"+t);const i=r.db,o=i.getMindmap();if(!o)return;const l=(0,s.nV)();l.htmlLabels=!1;const c=(0,a.P)(e),h=c.append("g");h.attr("class","mindmap-edges");const u=c.append("g");u.attr("class","mindmap-nodes"),await D(i,u,o,-1,l);const d=await $(o,l);O(h,d),B(i,d),(0,s.j7)(void 0,c,l.mindmap?.padding??s.vZ.mindmap.padding,l.mindmap?.useMaxWidth??s.vZ.mindmap.useMaxWidth)}),"draw")},W=(0,s.eW)((t=>{let e="";for(let e=0;e`\n .edge {\n stroke-width: 3;\n }\n ${W(t)}\n .section-root rect, .section-root path, .section-root circle, .section-root polygon {\n fill: ${t.git0};\n }\n .section-root text {\n fill: ${t.gitBranchLabel0};\n }\n .icon-container {\n height:100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n .edge {\n fill: none;\n }\n .mindmap-node-label {\n dy: 1em;\n alignment-baseline: middle;\n text-anchor: middle;\n dominant-baseline: middle;\n text-align: center;\n }\n`),"getStyles")}},8661:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>E});var r=n(1957),i=n(7946),a=n(5430),s=n(4082),o=n(2491),l=n(3108),c=s.vZ.pie,h={sections:new Map,showData:!1,config:c},u=h.sections,d=h.showData,p=structuredClone(c),g=(0,s.eW)((()=>structuredClone(p)),"getConfig"),f=(0,s.eW)((()=>{u=new Map,d=h.showData,(0,s.ZH)()}),"clear"),m=(0,s.eW)((({label:t,value:e})=>{u.has(t)||(u.set(t,e),s.cM.debug(`added new section: ${t}, with value: ${e}`))}),"addSection"),y=(0,s.eW)((()=>u),"getSections"),v=(0,s.eW)((t=>{d=t}),"setShowData"),x=(0,s.eW)((()=>d),"getShowData"),b={getConfig:g,clear:f,setDiagramTitle:s.g2,getDiagramTitle:s.Kr,setAccTitle:s.GN,getAccTitle:s.eu,setAccDescription:s.U$,getAccDescription:s.Mx,addSection:m,getSections:y,setShowData:v,getShowData:x},w=(0,s.eW)(((t,e)=>{(0,r.A)(t,e),e.setShowData(t.showData),t.sections.map(e.addSection)}),"populateDb"),k={parse:(0,s.eW)((async t=>{const e=await(0,o.Qc)("pie",t);s.cM.debug(e),w(e,b)}),"parse")},T=(0,s.eW)((t=>`\n .pieCircle{\n stroke: ${t.pieStrokeColor};\n stroke-width : ${t.pieStrokeWidth};\n opacity : ${t.pieOpacity};\n }\n .pieOuterCircle{\n stroke: ${t.pieOuterStrokeColor};\n stroke-width: ${t.pieOuterStrokeWidth};\n fill: none;\n }\n .pieTitleText {\n text-anchor: middle;\n font-size: ${t.pieTitleTextSize};\n fill: ${t.pieTitleTextColor};\n font-family: ${t.fontFamily};\n }\n .slice {\n font-family: ${t.fontFamily};\n fill: ${t.pieSectionTextColor};\n font-size:${t.pieSectionTextSize};\n // fill: white;\n }\n .legend text {\n fill: ${t.pieLegendTextColor};\n font-family: ${t.fontFamily};\n font-size: ${t.pieLegendTextSize};\n }\n`),"getStyles"),_=(0,s.eW)((t=>{const e=[...t.entries()].map((t=>({label:t[0],value:t[1]}))).sort(((t,e)=>e.value-t.value));return(0,l.ve8)().value((t=>t.value))(e)}),"createPieArcs"),E={parser:k,db:b,renderer:{draw:(0,s.eW)(((t,e,n,r)=>{s.cM.debug("rendering pie chart\n"+t);const o=r.db,c=(0,s.nV)(),h=(0,i.Rb)(o.getConfig(),c.pie),u=(0,a.P)(e),d=u.append("g");d.attr("transform","translate(225,225)");const{themeVariables:p}=c;let[g]=(0,i.VG)(p.pieOuterStrokeWidth);g??=2;const f=h.textPosition,m=Math.min(450,450)/2-40,y=(0,l.Nb1)().innerRadius(0).outerRadius(m),v=(0,l.Nb1)().innerRadius(m*f).outerRadius(m*f);d.append("circle").attr("cx",0).attr("cy",0).attr("r",m+g/2).attr("class","pieOuterCircle");const x=o.getSections(),b=_(x),w=[p.pie1,p.pie2,p.pie3,p.pie4,p.pie5,p.pie6,p.pie7,p.pie8,p.pie9,p.pie10,p.pie11,p.pie12],k=(0,l.PKp)(w);d.selectAll("mySlices").data(b).enter().append("path").attr("d",y).attr("fill",(t=>k(t.data.label))).attr("class","pieCircle");let T=0;x.forEach((t=>{T+=t})),d.selectAll("mySlices").data(b).enter().append("text").text((t=>(t.data.value/T*100).toFixed(0)+"%")).attr("transform",(t=>"translate("+v.centroid(t)+")")).style("text-anchor","middle").attr("class","slice"),d.append("text").text(o.getDiagramTitle()).attr("x",0).attr("y",-200).attr("class","pieTitleText");const E=d.selectAll(".legend").data(k.domain()).enter().append("g").attr("class","legend").attr("transform",((t,e)=>"translate(216,"+(22*e-22*k.domain().length/2)+")"));E.append("rect").attr("width",18).attr("height",18).style("fill",k).style("stroke",k),E.data(b).append("text").attr("x",22).attr("y",14).text((t=>{const{label:e,value:n}=t.data;return o.getShowData()?`${e} [${n}]`:e}));const S=512+Math.max(...E.selectAll("text").nodes().map((t=>t?.getBoundingClientRect().width??0)));u.attr("viewBox",`0 0 ${S} 450`),(0,s.v2)(u,450,S,h.useMaxWidth)}),"draw")},styles:T}},3661:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>M});var r=n(4082),i=n(3108),a=function(){var t=(0,r.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,3],n=[1,4],i=[1,5],a=[1,6],s=[1,7],o=[1,4,5,10,12,13,14,18,25,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],l=[1,4,5,10,12,13,14,18,25,28,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],c=[55,56,57],h=[2,36],u=[1,37],d=[1,36],p=[1,38],g=[1,35],f=[1,43],m=[1,41],y=[1,14],v=[1,23],x=[1,18],b=[1,19],w=[1,20],k=[1,21],T=[1,22],_=[1,24],E=[1,25],S=[1,26],C=[1,27],A=[1,28],L=[1,29],M=[1,32],N=[1,33],I=[1,34],R=[1,39],D=[1,40],O=[1,42],P=[1,44],$=[1,62],B=[1,61],F=[4,5,8,10,12,13,14,18,44,47,49,55,56,57,63,64,65,66,67],W=[1,65],z=[1,66],Z=[1,67],Y=[1,68],U=[1,69],G=[1,70],V=[1,71],q=[1,72],j=[1,73],H=[1,74],X=[1,75],K=[1,76],Q=[4,5,6,7,8,9,10,11,12,13,14,15,18],J=[1,90],tt=[1,91],et=[1,92],nt=[1,99],rt=[1,93],it=[1,96],at=[1,94],st=[1,95],ot=[1,97],lt=[1,98],ct=[1,102],ht=[10,55,56,57],ut=[4,5,6,8,10,11,13,17,18,19,20,55,56,57],dt={trace:(0,r.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,idStringToken:3,ALPHA:4,NUM:5,NODE_STRING:6,DOWN:7,MINUS:8,DEFAULT:9,COMMA:10,COLON:11,AMP:12,BRKT:13,MULT:14,UNICODE_TEXT:15,styleComponent:16,UNIT:17,SPACE:18,STYLE:19,PCT:20,idString:21,style:22,stylesOpt:23,classDefStatement:24,CLASSDEF:25,start:26,eol:27,QUADRANT:28,document:29,line:30,statement:31,axisDetails:32,quadrantDetails:33,points:34,title:35,title_value:36,acc_title:37,acc_title_value:38,acc_descr:39,acc_descr_value:40,acc_descr_multiline_value:41,section:42,text:43,point_start:44,point_x:45,point_y:46,class_name:47,"X-AXIS":48,"AXIS-TEXT-DELIMITER":49,"Y-AXIS":50,QUADRANT_1:51,QUADRANT_2:52,QUADRANT_3:53,QUADRANT_4:54,NEWLINE:55,SEMI:56,EOF:57,alphaNumToken:58,textNoTagsToken:59,STR:60,MD_STR:61,alphaNum:62,PUNCTUATION:63,PLUS:64,EQUALS:65,DOT:66,UNDERSCORE:67,$accept:0,$end:1},terminals_:{2:"error",4:"ALPHA",5:"NUM",6:"NODE_STRING",7:"DOWN",8:"MINUS",9:"DEFAULT",10:"COMMA",11:"COLON",12:"AMP",13:"BRKT",14:"MULT",15:"UNICODE_TEXT",17:"UNIT",18:"SPACE",19:"STYLE",20:"PCT",25:"CLASSDEF",28:"QUADRANT",35:"title",36:"title_value",37:"acc_title",38:"acc_title_value",39:"acc_descr",40:"acc_descr_value",41:"acc_descr_multiline_value",42:"section",44:"point_start",45:"point_x",46:"point_y",47:"class_name",48:"X-AXIS",49:"AXIS-TEXT-DELIMITER",50:"Y-AXIS",51:"QUADRANT_1",52:"QUADRANT_2",53:"QUADRANT_3",54:"QUADRANT_4",55:"NEWLINE",56:"SEMI",57:"EOF",60:"STR",61:"MD_STR",63:"PUNCTUATION",64:"PLUS",65:"EQUALS",66:"DOT",67:"UNDERSCORE"},productions_:[0,[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[21,1],[21,2],[22,1],[22,2],[23,1],[23,3],[24,5],[26,2],[26,2],[26,2],[29,0],[29,2],[30,2],[31,0],[31,1],[31,2],[31,1],[31,1],[31,1],[31,2],[31,2],[31,2],[31,1],[31,1],[34,4],[34,5],[34,5],[34,6],[32,4],[32,3],[32,2],[32,4],[32,3],[32,2],[33,2],[33,2],[33,2],[33,2],[27,1],[27,1],[27,1],[43,1],[43,2],[43,1],[43,1],[62,1],[62,2],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[59,1],[59,1],[59,1]],performAction:(0,r.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 23:case 68:this.$=a[o];break;case 24:case 69:this.$=a[o-1]+""+a[o];break;case 26:this.$=a[o-1]+a[o];break;case 27:this.$=[a[o].trim()];break;case 28:a[o-2].push(a[o].trim()),this.$=a[o-2];break;case 29:this.$=a[o-4],r.addClass(a[o-2],a[o]);break;case 37:this.$=[];break;case 42:this.$=a[o].trim(),r.setDiagramTitle(this.$);break;case 43:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 44:case 45:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 46:r.addSection(a[o].substr(8)),this.$=a[o].substr(8);break;case 47:r.addPoint(a[o-3],"",a[o-1],a[o],[]);break;case 48:r.addPoint(a[o-4],a[o-3],a[o-1],a[o],[]);break;case 49:r.addPoint(a[o-4],"",a[o-2],a[o-1],a[o]);break;case 50:r.addPoint(a[o-5],a[o-4],a[o-2],a[o-1],a[o]);break;case 51:r.setXAxisLeftText(a[o-2]),r.setXAxisRightText(a[o]);break;case 52:a[o-1].text+=" ⟶ ",r.setXAxisLeftText(a[o-1]);break;case 53:r.setXAxisLeftText(a[o]);break;case 54:r.setYAxisBottomText(a[o-2]),r.setYAxisTopText(a[o]);break;case 55:a[o-1].text+=" ⟶ ",r.setYAxisBottomText(a[o-1]);break;case 56:r.setYAxisBottomText(a[o]);break;case 57:r.setQuadrant1Text(a[o]);break;case 58:r.setQuadrant2Text(a[o]);break;case 59:r.setQuadrant3Text(a[o]);break;case 60:r.setQuadrant4Text(a[o]);break;case 64:case 66:this.$={text:a[o],type:"text"};break;case 65:this.$={text:a[o-1].text+""+a[o],type:a[o-1].type};break;case 67:this.$={text:a[o],type:"markdown"}}}),"anonymous"),table:[{18:e,26:1,27:2,28:n,55:i,56:a,57:s},{1:[3]},{18:e,26:8,27:2,28:n,55:i,56:a,57:s},{18:e,26:9,27:2,28:n,55:i,56:a,57:s},t(o,[2,33],{29:10}),t(l,[2,61]),t(l,[2,62]),t(l,[2,63]),{1:[2,30]},{1:[2,31]},t(c,h,{30:11,31:12,24:13,32:15,33:16,34:17,43:30,58:31,1:[2,32],4:u,5:d,10:p,12:g,13:f,14:m,18:y,25:v,35:x,37:b,39:w,41:k,42:T,48:_,50:E,51:S,52:C,53:A,54:L,60:M,61:N,63:I,64:R,65:D,66:O,67:P}),t(o,[2,34]),{27:45,55:i,56:a,57:s},t(c,[2,37]),t(c,h,{24:13,32:15,33:16,34:17,43:30,58:31,31:46,4:u,5:d,10:p,12:g,13:f,14:m,18:y,25:v,35:x,37:b,39:w,41:k,42:T,48:_,50:E,51:S,52:C,53:A,54:L,60:M,61:N,63:I,64:R,65:D,66:O,67:P}),t(c,[2,39]),t(c,[2,40]),t(c,[2,41]),{36:[1,47]},{38:[1,48]},{40:[1,49]},t(c,[2,45]),t(c,[2,46]),{18:[1,50]},{4:u,5:d,10:p,12:g,13:f,14:m,43:51,58:31,60:M,61:N,63:I,64:R,65:D,66:O,67:P},{4:u,5:d,10:p,12:g,13:f,14:m,43:52,58:31,60:M,61:N,63:I,64:R,65:D,66:O,67:P},{4:u,5:d,10:p,12:g,13:f,14:m,43:53,58:31,60:M,61:N,63:I,64:R,65:D,66:O,67:P},{4:u,5:d,10:p,12:g,13:f,14:m,43:54,58:31,60:M,61:N,63:I,64:R,65:D,66:O,67:P},{4:u,5:d,10:p,12:g,13:f,14:m,43:55,58:31,60:M,61:N,63:I,64:R,65:D,66:O,67:P},{4:u,5:d,10:p,12:g,13:f,14:m,43:56,58:31,60:M,61:N,63:I,64:R,65:D,66:O,67:P},{4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,44:[1,57],47:[1,58],58:60,59:59,63:I,64:R,65:D,66:O,67:P},t(F,[2,64]),t(F,[2,66]),t(F,[2,67]),t(F,[2,70]),t(F,[2,71]),t(F,[2,72]),t(F,[2,73]),t(F,[2,74]),t(F,[2,75]),t(F,[2,76]),t(F,[2,77]),t(F,[2,78]),t(F,[2,79]),t(F,[2,80]),t(o,[2,35]),t(c,[2,38]),t(c,[2,42]),t(c,[2,43]),t(c,[2,44]),{3:64,4:W,5:z,6:Z,7:Y,8:U,9:G,10:V,11:q,12:j,13:H,14:X,15:K,21:63},t(c,[2,53],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,49:[1,77],63:I,64:R,65:D,66:O,67:P}),t(c,[2,56],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,49:[1,78],63:I,64:R,65:D,66:O,67:P}),t(c,[2,57],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,63:I,64:R,65:D,66:O,67:P}),t(c,[2,58],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,63:I,64:R,65:D,66:O,67:P}),t(c,[2,59],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,63:I,64:R,65:D,66:O,67:P}),t(c,[2,60],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,63:I,64:R,65:D,66:O,67:P}),{45:[1,79]},{44:[1,80]},t(F,[2,65]),t(F,[2,81]),t(F,[2,82]),t(F,[2,83]),{3:82,4:W,5:z,6:Z,7:Y,8:U,9:G,10:V,11:q,12:j,13:H,14:X,15:K,18:[1,81]},t(Q,[2,23]),t(Q,[2,1]),t(Q,[2,2]),t(Q,[2,3]),t(Q,[2,4]),t(Q,[2,5]),t(Q,[2,6]),t(Q,[2,7]),t(Q,[2,8]),t(Q,[2,9]),t(Q,[2,10]),t(Q,[2,11]),t(Q,[2,12]),t(c,[2,52],{58:31,43:83,4:u,5:d,10:p,12:g,13:f,14:m,60:M,61:N,63:I,64:R,65:D,66:O,67:P}),t(c,[2,55],{58:31,43:84,4:u,5:d,10:p,12:g,13:f,14:m,60:M,61:N,63:I,64:R,65:D,66:O,67:P}),{46:[1,85]},{45:[1,86]},{4:J,5:tt,6:et,8:nt,11:rt,13:it,16:89,17:at,18:st,19:ot,20:lt,22:88,23:87},t(Q,[2,24]),t(c,[2,51],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,63:I,64:R,65:D,66:O,67:P}),t(c,[2,54],{59:59,58:60,4:u,5:d,8:$,10:p,12:g,13:f,14:m,18:B,63:I,64:R,65:D,66:O,67:P}),t(c,[2,47],{22:88,16:89,23:100,4:J,5:tt,6:et,8:nt,11:rt,13:it,17:at,18:st,19:ot,20:lt}),{46:[1,101]},t(c,[2,29],{10:ct}),t(ht,[2,27],{16:103,4:J,5:tt,6:et,8:nt,11:rt,13:it,17:at,18:st,19:ot,20:lt}),t(ut,[2,25]),t(ut,[2,13]),t(ut,[2,14]),t(ut,[2,15]),t(ut,[2,16]),t(ut,[2,17]),t(ut,[2,18]),t(ut,[2,19]),t(ut,[2,20]),t(ut,[2,21]),t(ut,[2,22]),t(c,[2,49],{10:ct}),t(c,[2,48],{22:88,16:89,23:104,4:J,5:tt,6:et,8:nt,11:rt,13:it,17:at,18:st,19:ot,20:lt}),{4:J,5:tt,6:et,8:nt,11:rt,13:it,16:89,17:at,18:st,19:ot,20:lt,22:105},t(ut,[2,26]),t(c,[2,50],{10:ct}),t(ht,[2,28],{16:103,4:J,5:tt,6:et,8:nt,11:rt,13:it,17:at,18:st,19:ot,20:lt})],defaultActions:{8:[2,30],9:[2,31]},parseError:(0,r.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,r.eW)((function(t){var e=this,n=[0],i=[],a=[null],s=[],o=this.table,l="",c=0,h=0,u=0,d=s.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;s.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=i.pop()||p.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,r.eW)((function(t){n.length=n.length-2*t,a.length=a.length-t,s.length=s.length-t}),"popStack"),(0,r.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),a.push(p.yytext),s.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=a[a.length-E],A._$={first_line:s[s.length-(E||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(E||1)].first_column,last_column:s[s.length-1].last_column},y&&(A._$.range=[s[s.length-(E||1)].range[0],s[s.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],a,s].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),a=a.slice(0,-1*E),s=s.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),a.push(A.$),s.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},pt=function(){return{EOF:1,parseError:(0,r.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,r.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,r.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,r.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,r.eW)((function(){return this._more=!0,this}),"more"),reject:(0,r.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,r.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,r.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,r.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,r.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,r.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,r.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,r.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,r.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,r.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,r.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,r.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,r.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,r.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,r.eW)((function(t,e,n,r){switch(n){case 0:case 1:case 3:break;case 2:return 55;case 4:return this.begin("title"),35;case 5:return this.popState(),"title_value";case 6:return this.begin("acc_title"),37;case 7:return this.popState(),"acc_title_value";case 8:return this.begin("acc_descr"),39;case 9:return this.popState(),"acc_descr_value";case 10:this.begin("acc_descr_multiline");break;case 11:case 23:case 25:case 31:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:return 48;case 14:return 50;case 15:return 49;case 16:return 51;case 17:return 52;case 18:return 53;case 19:return 54;case 20:return 25;case 21:this.begin("md_string");break;case 22:return"MD_STR";case 24:this.begin("string");break;case 26:return"STR";case 27:this.begin("class_name");break;case 28:return this.popState(),47;case 29:return this.begin("point_start"),44;case 30:return this.begin("point_x"),45;case 32:this.popState(),this.begin("point_y");break;case 33:return this.popState(),46;case 34:return 28;case 35:return 4;case 36:return 11;case 37:return 64;case 38:return 10;case 39:case 40:return 65;case 41:return 14;case 42:return 13;case 43:return 67;case 44:return 66;case 45:return 12;case 46:return 8;case 47:return 5;case 48:return 18;case 49:return 56;case 50:return 63;case 51:return 57}}),"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?: *x-axis *)/i,/^(?: *y-axis *)/i,/^(?: *--+> *)/i,/^(?: *quadrant-1 *)/i,/^(?: *quadrant-2 *)/i,/^(?: *quadrant-3 *)/i,/^(?: *quadrant-4 *)/i,/^(?:classDef\b)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?::::)/i,/^(?:^\w+)/i,/^(?:\s*:\s*\[\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?:\s*\] *)/i,/^(?:\s*,\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?: *quadrantChart *)/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s)/i,/^(?:;)/i,/^(?:[!"#$%&'*+,-.`?\\_/])/i,/^(?:$)/i],conditions:{class_name:{rules:[28],inclusive:!1},point_y:{rules:[33],inclusive:!1},point_x:{rules:[32],inclusive:!1},point_start:{rules:[30,31],inclusive:!1},acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},title:{rules:[5],inclusive:!1},md_string:{rules:[22,23],inclusive:!1},string:{rules:[25,26],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,6,8,10,13,14,15,16,17,18,19,20,21,24,27,29,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51],inclusive:!0}}}}();function gt(){this.yy={}}return dt.lexer=pt,(0,r.eW)(gt,"Parser"),gt.prototype=dt,dt.Parser=gt,new gt}();a.parser=a;var s=a,o=(0,r.xN)(),l=class{constructor(){this.classes=new Map,this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData()}static{(0,r.eW)(this,"QuadrantBuilder")}getDefaultData(){return{titleText:"",quadrant1Text:"",quadrant2Text:"",quadrant3Text:"",quadrant4Text:"",xAxisLeftText:"",xAxisRightText:"",yAxisBottomText:"",yAxisTopText:"",points:[]}}getDefaultConfig(){return{showXAxis:!0,showYAxis:!0,showTitle:!0,chartHeight:r.vZ.quadrantChart?.chartWidth||500,chartWidth:r.vZ.quadrantChart?.chartHeight||500,titlePadding:r.vZ.quadrantChart?.titlePadding||10,titleFontSize:r.vZ.quadrantChart?.titleFontSize||20,quadrantPadding:r.vZ.quadrantChart?.quadrantPadding||5,xAxisLabelPadding:r.vZ.quadrantChart?.xAxisLabelPadding||5,yAxisLabelPadding:r.vZ.quadrantChart?.yAxisLabelPadding||5,xAxisLabelFontSize:r.vZ.quadrantChart?.xAxisLabelFontSize||16,yAxisLabelFontSize:r.vZ.quadrantChart?.yAxisLabelFontSize||16,quadrantLabelFontSize:r.vZ.quadrantChart?.quadrantLabelFontSize||16,quadrantTextTopPadding:r.vZ.quadrantChart?.quadrantTextTopPadding||5,pointTextPadding:r.vZ.quadrantChart?.pointTextPadding||5,pointLabelFontSize:r.vZ.quadrantChart?.pointLabelFontSize||12,pointRadius:r.vZ.quadrantChart?.pointRadius||5,xAxisPosition:r.vZ.quadrantChart?.xAxisPosition||"top",yAxisPosition:r.vZ.quadrantChart?.yAxisPosition||"left",quadrantInternalBorderStrokeWidth:r.vZ.quadrantChart?.quadrantInternalBorderStrokeWidth||1,quadrantExternalBorderStrokeWidth:r.vZ.quadrantChart?.quadrantExternalBorderStrokeWidth||2}}getDefaultThemeConfig(){return{quadrant1Fill:o.quadrant1Fill,quadrant2Fill:o.quadrant2Fill,quadrant3Fill:o.quadrant3Fill,quadrant4Fill:o.quadrant4Fill,quadrant1TextFill:o.quadrant1TextFill,quadrant2TextFill:o.quadrant2TextFill,quadrant3TextFill:o.quadrant3TextFill,quadrant4TextFill:o.quadrant4TextFill,quadrantPointFill:o.quadrantPointFill,quadrantPointTextFill:o.quadrantPointTextFill,quadrantXAxisTextFill:o.quadrantXAxisTextFill,quadrantYAxisTextFill:o.quadrantYAxisTextFill,quadrantTitleFill:o.quadrantTitleFill,quadrantInternalBorderStrokeFill:o.quadrantInternalBorderStrokeFill,quadrantExternalBorderStrokeFill:o.quadrantExternalBorderStrokeFill}}clear(){this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData(),this.classes=new Map,r.cM.info("clear called")}setData(t){this.data={...this.data,...t}}addPoints(t){this.data.points=[...t,...this.data.points]}addClass(t,e){this.classes.set(t,e)}setConfig(t){r.cM.trace("setConfig called with: ",t),this.config={...this.config,...t}}setThemeConfig(t){r.cM.trace("setThemeConfig called with: ",t),this.themeConfig={...this.themeConfig,...t}}calculateSpace(t,e,n,r){const i=2*this.config.xAxisLabelPadding+this.config.xAxisLabelFontSize,a={top:"top"===t&&e?i:0,bottom:"bottom"===t&&e?i:0},s=2*this.config.yAxisLabelPadding+this.config.yAxisLabelFontSize,o={left:"left"===this.config.yAxisPosition&&n?s:0,right:"right"===this.config.yAxisPosition&&n?s:0},l=this.config.titleFontSize+2*this.config.titlePadding,c={top:r?l:0},h=this.config.quadrantPadding+o.left,u=this.config.quadrantPadding+a.top+c.top,d=this.config.chartWidth-2*this.config.quadrantPadding-o.left-o.right,p=this.config.chartHeight-2*this.config.quadrantPadding-a.top-a.bottom-c.top;return{xAxisSpace:a,yAxisSpace:o,titleSpace:c,quadrantSpace:{quadrantLeft:h,quadrantTop:u,quadrantWidth:d,quadrantHalfWidth:d/2,quadrantHeight:p,quadrantHalfHeight:p/2}}}getAxisLabels(t,e,n,r){const{quadrantSpace:i,titleSpace:a}=r,{quadrantHalfHeight:s,quadrantHeight:o,quadrantLeft:l,quadrantHalfWidth:c,quadrantTop:h,quadrantWidth:u}=i,d=Boolean(this.data.xAxisRightText),p=Boolean(this.data.yAxisTopText),g=[];return this.data.xAxisLeftText&&e&&g.push({text:this.data.xAxisLeftText,fill:this.themeConfig.quadrantXAxisTextFill,x:l+(d?c/2:0),y:"top"===t?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+h+o+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:d?"center":"left",horizontalPos:"top",rotation:0}),this.data.xAxisRightText&&e&&g.push({text:this.data.xAxisRightText,fill:this.themeConfig.quadrantXAxisTextFill,x:l+c+(d?c/2:0),y:"top"===t?this.config.xAxisLabelPadding+a.top:this.config.xAxisLabelPadding+h+o+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:d?"center":"left",horizontalPos:"top",rotation:0}),this.data.yAxisBottomText&&n&&g.push({text:this.data.yAxisBottomText,fill:this.themeConfig.quadrantYAxisTextFill,x:"left"===this.config.yAxisPosition?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+l+u+this.config.quadrantPadding,y:h+o-(p?s/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?"center":"left",horizontalPos:"top",rotation:-90}),this.data.yAxisTopText&&n&&g.push({text:this.data.yAxisTopText,fill:this.themeConfig.quadrantYAxisTextFill,x:"left"===this.config.yAxisPosition?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+l+u+this.config.quadrantPadding,y:h+s-(p?s/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:p?"center":"left",horizontalPos:"top",rotation:-90}),g}getQuadrants(t){const{quadrantSpace:e}=t,{quadrantHalfHeight:n,quadrantLeft:r,quadrantHalfWidth:i,quadrantTop:a}=e,s=[{text:{text:this.data.quadrant1Text,fill:this.themeConfig.quadrant1TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:r+i,y:a,width:i,height:n,fill:this.themeConfig.quadrant1Fill},{text:{text:this.data.quadrant2Text,fill:this.themeConfig.quadrant2TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:r,y:a,width:i,height:n,fill:this.themeConfig.quadrant2Fill},{text:{text:this.data.quadrant3Text,fill:this.themeConfig.quadrant3TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:r,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant3Fill},{text:{text:this.data.quadrant4Text,fill:this.themeConfig.quadrant4TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:r+i,y:a+n,width:i,height:n,fill:this.themeConfig.quadrant4Fill}];for(const t of s)t.text.x=t.x+t.width/2,0===this.data.points.length?(t.text.y=t.y+t.height/2,t.text.horizontalPos="middle"):(t.text.y=t.y+this.config.quadrantTextTopPadding,t.text.horizontalPos="top");return s}getQuadrantPoints(t){const{quadrantSpace:e}=t,{quadrantHeight:n,quadrantLeft:r,quadrantTop:a,quadrantWidth:s}=e,o=(0,i.BYU)().domain([0,1]).range([r,s+r]),l=(0,i.BYU)().domain([0,1]).range([n+a,a]);return this.data.points.map((t=>{const e=this.classes.get(t.className);return e&&(t={...e,...t}),{x:o(t.x),y:l(t.y),fill:t.color??this.themeConfig.quadrantPointFill,radius:t.radius??this.config.pointRadius,text:{text:t.text,fill:this.themeConfig.quadrantPointTextFill,x:o(t.x),y:l(t.y)+this.config.pointTextPadding,verticalPos:"center",horizontalPos:"top",fontSize:this.config.pointLabelFontSize,rotation:0},strokeColor:t.strokeColor??this.themeConfig.quadrantPointFill,strokeWidth:t.strokeWidth??"0px"}}))}getBorders(t){const e=this.config.quadrantExternalBorderStrokeWidth/2,{quadrantSpace:n}=t,{quadrantHalfHeight:r,quadrantHeight:i,quadrantLeft:a,quadrantHalfWidth:s,quadrantTop:o,quadrantWidth:l}=n;return[{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-e,y1:o,x2:a+l+e,y2:o},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a+l,y1:o+e,x2:a+l,y2:o+i-e},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a-e,y1:o+i,x2:a+l+e,y2:o+i},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:a,y1:o+e,x2:a,y2:o+i-e},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+s,y1:o+e,x2:a+s,y2:o+i-e},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:a+e,y1:o+r,x2:a+l-e,y2:o+r}]}getTitle(t){if(t)return{text:this.data.titleText,fill:this.themeConfig.quadrantTitleFill,fontSize:this.config.titleFontSize,horizontalPos:"top",verticalPos:"center",rotation:0,y:this.config.titlePadding,x:this.config.chartWidth/2}}build(){const t=this.config.showXAxis&&!(!this.data.xAxisLeftText&&!this.data.xAxisRightText),e=this.config.showYAxis&&!(!this.data.yAxisTopText&&!this.data.yAxisBottomText),n=this.config.showTitle&&!!this.data.titleText,r=this.data.points.length>0?"bottom":this.config.xAxisPosition,i=this.calculateSpace(r,t,e,n);return{points:this.getQuadrantPoints(i),quadrants:this.getQuadrants(i),axisLabels:this.getAxisLabels(r,t,e,i),borderLines:this.getBorders(i),title:this.getTitle(n)}}},c=class extends Error{static{(0,r.eW)(this,"InvalidStyleError")}constructor(t,e,n){super(`value for ${t} ${e} is invalid, please use a valid ${n}`),this.name="InvalidStyleError"}};function h(t){return!/^#?([\dA-Fa-f]{6}|[\dA-Fa-f]{3})$/.test(t)}function u(t){return!/^\d+$/.test(t)}function d(t){return!/^\d+px$/.test(t)}(0,r.eW)(h,"validateHexCode"),(0,r.eW)(u,"validateNumber"),(0,r.eW)(d,"validateSizeInPixels");var p=(0,r.nV)();function g(t){return(0,r.oO)(t.trim(),p)}(0,r.eW)(g,"textSanitizer");var f=new l;function m(t){f.setData({quadrant1Text:g(t.text)})}function y(t){f.setData({quadrant2Text:g(t.text)})}function v(t){f.setData({quadrant3Text:g(t.text)})}function x(t){f.setData({quadrant4Text:g(t.text)})}function b(t){f.setData({xAxisLeftText:g(t.text)})}function w(t){f.setData({xAxisRightText:g(t.text)})}function k(t){f.setData({yAxisTopText:g(t.text)})}function T(t){f.setData({yAxisBottomText:g(t.text)})}function _(t){const e={};for(const n of t){const[t,r]=n.trim().split(/\s*:\s*/);if("radius"===t){if(u(r))throw new c(t,r,"number");e.radius=parseInt(r)}else if("color"===t){if(h(r))throw new c(t,r,"hex code");e.color=r}else if("stroke-color"===t){if(h(r))throw new c(t,r,"hex code");e.strokeColor=r}else{if("stroke-width"!==t)throw new Error(`style named ${t} is not supported.`);if(d(r))throw new c(t,r,"number of pixels (eg. 10px)");e.strokeWidth=r}}return e}function E(t,e,n,r,i){const a=_(i);f.addPoints([{x:n,y:r,text:g(t.text),className:e,...a}])}function S(t,e){f.addClass(t,_(e))}function C(t){f.setConfig({chartWidth:t})}function A(t){f.setConfig({chartHeight:t})}function L(){const t=(0,r.nV)(),{themeVariables:e,quadrantChart:n}=t;return n&&f.setConfig(n),f.setThemeConfig({quadrant1Fill:e.quadrant1Fill,quadrant2Fill:e.quadrant2Fill,quadrant3Fill:e.quadrant3Fill,quadrant4Fill:e.quadrant4Fill,quadrant1TextFill:e.quadrant1TextFill,quadrant2TextFill:e.quadrant2TextFill,quadrant3TextFill:e.quadrant3TextFill,quadrant4TextFill:e.quadrant4TextFill,quadrantPointFill:e.quadrantPointFill,quadrantPointTextFill:e.quadrantPointTextFill,quadrantXAxisTextFill:e.quadrantXAxisTextFill,quadrantYAxisTextFill:e.quadrantYAxisTextFill,quadrantExternalBorderStrokeFill:e.quadrantExternalBorderStrokeFill,quadrantInternalBorderStrokeFill:e.quadrantInternalBorderStrokeFill,quadrantTitleFill:e.quadrantTitleFill}),f.setData({titleText:(0,r.Kr)()}),f.build()}(0,r.eW)(m,"setQuadrant1Text"),(0,r.eW)(y,"setQuadrant2Text"),(0,r.eW)(v,"setQuadrant3Text"),(0,r.eW)(x,"setQuadrant4Text"),(0,r.eW)(b,"setXAxisLeftText"),(0,r.eW)(w,"setXAxisRightText"),(0,r.eW)(k,"setYAxisTopText"),(0,r.eW)(T,"setYAxisBottomText"),(0,r.eW)(_,"parseStyles"),(0,r.eW)(E,"addPoint"),(0,r.eW)(S,"addClass"),(0,r.eW)(C,"setWidth"),(0,r.eW)(A,"setHeight"),(0,r.eW)(L,"getQuadrantData");var M={parser:s,db:{setWidth:C,setHeight:A,setQuadrant1Text:m,setQuadrant2Text:y,setQuadrant3Text:v,setQuadrant4Text:x,setXAxisLeftText:b,setXAxisRightText:w,setYAxisTopText:k,setYAxisBottomText:T,parseStyles:_,addPoint:E,addClass:S,getQuadrantData:L,clear:(0,r.eW)((function(){f.clear(),(0,r.ZH)()}),"clear"),setAccTitle:r.GN,getAccTitle:r.eu,setDiagramTitle:r.g2,getDiagramTitle:r.Kr,getAccDescription:r.Mx,setAccDescription:r.U$},renderer:{draw:(0,r.eW)(((t,e,n,a)=>{function s(t){return"top"===t?"hanging":"middle"}function o(t){return"left"===t?"start":"middle"}function l(t){return`translate(${t.x}, ${t.y}) rotate(${t.rotation||0})`}(0,r.eW)(s,"getDominantBaseLine"),(0,r.eW)(o,"getTextAnchor"),(0,r.eW)(l,"getTransformation");const c=(0,r.nV)();r.cM.debug("Rendering quadrant chart\n"+t);const h=c.securityLevel;let u;"sandbox"===h&&(u=(0,i.Ys)("#i"+e));const d=("sandbox"===h?(0,i.Ys)(u.nodes()[0].contentDocument.body):(0,i.Ys)("body")).select(`[id="${e}"]`),p=d.append("g").attr("class","main"),g=c.quadrantChart?.chartWidth??500,f=c.quadrantChart?.chartHeight??500;(0,r.v2)(d,f,g,c.quadrantChart?.useMaxWidth??!0),d.attr("viewBox","0 0 "+g+" "+f),a.db.setHeight(f),a.db.setWidth(g);const m=a.db.getQuadrantData(),y=p.append("g").attr("class","quadrants"),v=p.append("g").attr("class","border"),x=p.append("g").attr("class","data-points"),b=p.append("g").attr("class","labels"),w=p.append("g").attr("class","title");m.title&&w.append("text").attr("x",0).attr("y",0).attr("fill",m.title.fill).attr("font-size",m.title.fontSize).attr("dominant-baseline",s(m.title.horizontalPos)).attr("text-anchor",o(m.title.verticalPos)).attr("transform",l(m.title)).text(m.title.text),m.borderLines&&v.selectAll("line").data(m.borderLines).enter().append("line").attr("x1",(t=>t.x1)).attr("y1",(t=>t.y1)).attr("x2",(t=>t.x2)).attr("y2",(t=>t.y2)).style("stroke",(t=>t.strokeFill)).style("stroke-width",(t=>t.strokeWidth));const k=y.selectAll("g.quadrant").data(m.quadrants).enter().append("g").attr("class","quadrant");k.append("rect").attr("x",(t=>t.x)).attr("y",(t=>t.y)).attr("width",(t=>t.width)).attr("height",(t=>t.height)).attr("fill",(t=>t.fill)),k.append("text").attr("x",0).attr("y",0).attr("fill",(t=>t.text.fill)).attr("font-size",(t=>t.text.fontSize)).attr("dominant-baseline",(t=>s(t.text.horizontalPos))).attr("text-anchor",(t=>o(t.text.verticalPos))).attr("transform",(t=>l(t.text))).text((t=>t.text.text)),b.selectAll("g.label").data(m.axisLabels).enter().append("g").attr("class","label").append("text").attr("x",0).attr("y",0).text((t=>t.text)).attr("fill",(t=>t.fill)).attr("font-size",(t=>t.fontSize)).attr("dominant-baseline",(t=>s(t.horizontalPos))).attr("text-anchor",(t=>o(t.verticalPos))).attr("transform",(t=>l(t)));const T=x.selectAll("g.data-point").data(m.points).enter().append("g").attr("class","data-point");T.append("circle").attr("cx",(t=>t.x)).attr("cy",(t=>t.y)).attr("r",(t=>t.radius)).attr("fill",(t=>t.fill)).attr("stroke",(t=>t.strokeColor)).attr("stroke-width",(t=>t.strokeWidth)),T.append("text").attr("x",0).attr("y",0).text((t=>t.text.text)).attr("fill",(t=>t.text.fill)).attr("font-size",(t=>t.text.fontSize)).attr("dominant-baseline",(t=>s(t.text.horizontalPos))).attr("text-anchor",(t=>o(t.text.verticalPos))).attr("transform",(t=>l(t.text)))}),"draw")},styles:(0,r.eW)((()=>""),"styles")}},9816:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>p});var r=n(907),i=n(8337),a=(n(1566),n(5179),n(3583),n(1426),n(6241),n(214),n(7946)),s=n(4082),o=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,3],n=[1,4],r=[1,5],i=[1,6],a=[5,6,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],o=[1,22],l=[2,7],c=[1,26],h=[1,27],u=[1,28],d=[1,29],p=[1,33],g=[1,34],f=[1,35],m=[1,36],y=[1,37],v=[1,38],x=[1,24],b=[1,31],w=[1,32],k=[1,30],T=[1,39],_=[1,40],E=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],S=[1,61],C=[89,90],A=[5,8,9,11,13,21,22,23,24,27,29,41,42,43,44,45,46,54,61,63,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],L=[27,29],M=[1,70],N=[1,71],I=[1,72],R=[1,73],D=[1,74],O=[1,75],P=[1,76],$=[1,83],B=[1,80],F=[1,84],W=[1,85],z=[1,86],Z=[1,87],Y=[1,88],U=[1,89],G=[1,90],V=[1,91],q=[1,92],j=[5,8,9,11,13,21,22,23,24,27,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],H=[63,64],X=[1,101],K=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,76,77,89,90],Q=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],J=[1,110],tt=[1,106],et=[1,107],nt=[1,108],rt=[1,109],it=[1,111],at=[1,116],st=[1,117],ot=[1,114],lt=[1,115],ct={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,directive:4,NEWLINE:5,RD:6,diagram:7,EOF:8,acc_title:9,acc_title_value:10,acc_descr:11,acc_descr_value:12,acc_descr_multiline_value:13,requirementDef:14,elementDef:15,relationshipDef:16,direction:17,styleStatement:18,classDefStatement:19,classStatement:20,direction_tb:21,direction_bt:22,direction_rl:23,direction_lr:24,requirementType:25,requirementName:26,STRUCT_START:27,requirementBody:28,STYLE_SEPARATOR:29,idList:30,ID:31,COLONSEP:32,id:33,TEXT:34,text:35,RISK:36,riskLevel:37,VERIFYMTHD:38,verifyType:39,STRUCT_STOP:40,REQUIREMENT:41,FUNCTIONAL_REQUIREMENT:42,INTERFACE_REQUIREMENT:43,PERFORMANCE_REQUIREMENT:44,PHYSICAL_REQUIREMENT:45,DESIGN_CONSTRAINT:46,LOW_RISK:47,MED_RISK:48,HIGH_RISK:49,VERIFY_ANALYSIS:50,VERIFY_DEMONSTRATION:51,VERIFY_INSPECTION:52,VERIFY_TEST:53,ELEMENT:54,elementName:55,elementBody:56,TYPE:57,type:58,DOCREF:59,ref:60,END_ARROW_L:61,relationship:62,LINE:63,END_ARROW_R:64,CONTAINS:65,COPIES:66,DERIVES:67,SATISFIES:68,VERIFIES:69,REFINES:70,TRACES:71,CLASSDEF:72,stylesOpt:73,CLASS:74,ALPHA:75,COMMA:76,STYLE:77,style:78,styleComponent:79,NUM:80,COLON:81,UNIT:82,SPACE:83,BRKT:84,PCT:85,MINUS:86,LABEL:87,SEMICOLON:88,unqString:89,qString:90,$accept:0,$end:1},terminals_:{2:"error",5:"NEWLINE",6:"RD",8:"EOF",9:"acc_title",10:"acc_title_value",11:"acc_descr",12:"acc_descr_value",13:"acc_descr_multiline_value",21:"direction_tb",22:"direction_bt",23:"direction_rl",24:"direction_lr",27:"STRUCT_START",29:"STYLE_SEPARATOR",31:"ID",32:"COLONSEP",34:"TEXT",36:"RISK",38:"VERIFYMTHD",40:"STRUCT_STOP",41:"REQUIREMENT",42:"FUNCTIONAL_REQUIREMENT",43:"INTERFACE_REQUIREMENT",44:"PERFORMANCE_REQUIREMENT",45:"PHYSICAL_REQUIREMENT",46:"DESIGN_CONSTRAINT",47:"LOW_RISK",48:"MED_RISK",49:"HIGH_RISK",50:"VERIFY_ANALYSIS",51:"VERIFY_DEMONSTRATION",52:"VERIFY_INSPECTION",53:"VERIFY_TEST",54:"ELEMENT",57:"TYPE",59:"DOCREF",61:"END_ARROW_L",63:"LINE",64:"END_ARROW_R",65:"CONTAINS",66:"COPIES",67:"DERIVES",68:"SATISFIES",69:"VERIFIES",70:"REFINES",71:"TRACES",72:"CLASSDEF",74:"CLASS",75:"ALPHA",76:"COMMA",77:"STYLE",80:"NUM",81:"COLON",82:"UNIT",83:"SPACE",84:"BRKT",85:"PCT",86:"MINUS",87:"LABEL",88:"SEMICOLON",89:"unqString",90:"qString"},productions_:[0,[3,3],[3,2],[3,4],[4,2],[4,2],[4,1],[7,0],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[17,1],[17,1],[17,1],[17,1],[14,5],[14,7],[28,5],[28,5],[28,5],[28,5],[28,2],[28,1],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[37,1],[37,1],[37,1],[39,1],[39,1],[39,1],[39,1],[15,5],[15,7],[56,5],[56,5],[56,2],[56,1],[16,5],[16,5],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[19,3],[20,3],[20,3],[30,1],[30,3],[30,1],[30,3],[18,3],[73,1],[73,3],[78,1],[78,2],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[26,1],[26,1],[33,1],[33,1],[35,1],[35,1],[55,1],[55,1],[58,1],[58,1],[60,1],[60,1]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 4:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 5:case 6:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 7:this.$=[];break;case 17:r.setDirection("TB");break;case 18:r.setDirection("BT");break;case 19:r.setDirection("RL");break;case 20:r.setDirection("LR");break;case 21:r.addRequirement(a[o-3],a[o-4]);break;case 22:r.addRequirement(a[o-5],a[o-6]),r.setClass([a[o-5]],a[o-3]);break;case 23:r.setNewReqId(a[o-2]);break;case 24:r.setNewReqText(a[o-2]);break;case 25:r.setNewReqRisk(a[o-2]);break;case 26:r.setNewReqVerifyMethod(a[o-2]);break;case 29:this.$=r.RequirementType.REQUIREMENT;break;case 30:this.$=r.RequirementType.FUNCTIONAL_REQUIREMENT;break;case 31:this.$=r.RequirementType.INTERFACE_REQUIREMENT;break;case 32:this.$=r.RequirementType.PERFORMANCE_REQUIREMENT;break;case 33:this.$=r.RequirementType.PHYSICAL_REQUIREMENT;break;case 34:this.$=r.RequirementType.DESIGN_CONSTRAINT;break;case 35:this.$=r.RiskLevel.LOW_RISK;break;case 36:this.$=r.RiskLevel.MED_RISK;break;case 37:this.$=r.RiskLevel.HIGH_RISK;break;case 38:this.$=r.VerifyType.VERIFY_ANALYSIS;break;case 39:this.$=r.VerifyType.VERIFY_DEMONSTRATION;break;case 40:this.$=r.VerifyType.VERIFY_INSPECTION;break;case 41:this.$=r.VerifyType.VERIFY_TEST;break;case 42:r.addElement(a[o-3]);break;case 43:r.addElement(a[o-5]),r.setClass([a[o-5]],a[o-3]);break;case 44:r.setNewElementType(a[o-2]);break;case 45:r.setNewElementDocRef(a[o-2]);break;case 48:r.addRelationship(a[o-2],a[o],a[o-4]);break;case 49:r.addRelationship(a[o-2],a[o-4],a[o]);break;case 50:this.$=r.Relationships.CONTAINS;break;case 51:this.$=r.Relationships.COPIES;break;case 52:this.$=r.Relationships.DERIVES;break;case 53:this.$=r.Relationships.SATISFIES;break;case 54:this.$=r.Relationships.VERIFIES;break;case 55:this.$=r.Relationships.REFINES;break;case 56:this.$=r.Relationships.TRACES;break;case 57:this.$=a[o-2],r.defineClass(a[o-1],a[o]);break;case 58:r.setClass(a[o-1],a[o]);break;case 59:r.setClass([a[o-2]],a[o]);break;case 60:case 62:case 65:this.$=[a[o]];break;case 61:case 63:this.$=a[o-2].concat([a[o]]);break;case 64:this.$=a[o-2],r.setCssStyle(a[o-1],a[o]);break;case 66:a[o-2].push(a[o]),this.$=a[o-2];break;case 68:this.$=a[o-1]+a[o]}}),"anonymous"),table:[{3:1,4:2,6:e,9:n,11:r,13:i},{1:[3]},{3:8,4:2,5:[1,7],6:e,9:n,11:r,13:i},{5:[1,9]},{10:[1,10]},{12:[1,11]},t(a,[2,6]),{3:12,4:2,6:e,9:n,11:r,13:i},{1:[2,2]},{4:17,5:o,7:13,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},t(a,[2,4]),t(a,[2,5]),{1:[2,1]},{8:[1,41]},{4:17,5:o,7:42,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:43,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:44,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:45,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:46,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:47,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:48,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:49,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{4:17,5:o,7:50,8:l,9:n,11:r,13:i,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:d,25:23,33:25,41:p,42:g,43:f,44:m,45:y,46:v,54:x,72:b,74:w,77:k,89:T,90:_},{26:51,89:[1,52],90:[1,53]},{55:54,89:[1,55],90:[1,56]},{29:[1,59],61:[1,57],63:[1,58]},t(E,[2,17]),t(E,[2,18]),t(E,[2,19]),t(E,[2,20]),{30:60,33:62,75:S,89:T,90:_},{30:63,33:62,75:S,89:T,90:_},{30:64,33:62,75:S,89:T,90:_},t(C,[2,29]),t(C,[2,30]),t(C,[2,31]),t(C,[2,32]),t(C,[2,33]),t(C,[2,34]),t(A,[2,81]),t(A,[2,82]),{1:[2,3]},{8:[2,8]},{8:[2,9]},{8:[2,10]},{8:[2,11]},{8:[2,12]},{8:[2,13]},{8:[2,14]},{8:[2,15]},{8:[2,16]},{27:[1,65],29:[1,66]},t(L,[2,79]),t(L,[2,80]),{27:[1,67],29:[1,68]},t(L,[2,85]),t(L,[2,86]),{62:69,65:M,66:N,67:I,68:R,69:D,70:O,71:P},{62:77,65:M,66:N,67:I,68:R,69:D,70:O,71:P},{30:78,33:62,75:S,89:T,90:_},{73:79,75:$,76:B,78:81,79:82,80:F,81:W,82:z,83:Z,84:Y,85:U,86:G,87:V,88:q},t(j,[2,60]),t(j,[2,62]),{73:93,75:$,76:B,78:81,79:82,80:F,81:W,82:z,83:Z,84:Y,85:U,86:G,87:V,88:q},{30:94,33:62,75:S,76:B,89:T,90:_},{5:[1,95]},{30:96,33:62,75:S,89:T,90:_},{5:[1,97]},{30:98,33:62,75:S,89:T,90:_},{63:[1,99]},t(H,[2,50]),t(H,[2,51]),t(H,[2,52]),t(H,[2,53]),t(H,[2,54]),t(H,[2,55]),t(H,[2,56]),{64:[1,100]},t(E,[2,59],{76:B}),t(E,[2,64],{76:X}),{33:103,75:[1,102],89:T,90:_},t(K,[2,65],{79:104,75:$,80:F,81:W,82:z,83:Z,84:Y,85:U,86:G,87:V,88:q}),t(Q,[2,67]),t(Q,[2,69]),t(Q,[2,70]),t(Q,[2,71]),t(Q,[2,72]),t(Q,[2,73]),t(Q,[2,74]),t(Q,[2,75]),t(Q,[2,76]),t(Q,[2,77]),t(Q,[2,78]),t(E,[2,57],{76:X}),t(E,[2,58],{76:B}),{5:J,28:105,31:tt,34:et,36:nt,38:rt,40:it},{27:[1,112],76:B},{5:at,40:st,56:113,57:ot,59:lt},{27:[1,118],76:B},{33:119,89:T,90:_},{33:120,89:T,90:_},{75:$,78:121,79:82,80:F,81:W,82:z,83:Z,84:Y,85:U,86:G,87:V,88:q},t(j,[2,61]),t(j,[2,63]),t(Q,[2,68]),t(E,[2,21]),{32:[1,122]},{32:[1,123]},{32:[1,124]},{32:[1,125]},{5:J,28:126,31:tt,34:et,36:nt,38:rt,40:it},t(E,[2,28]),{5:[1,127]},t(E,[2,42]),{32:[1,128]},{32:[1,129]},{5:at,40:st,56:130,57:ot,59:lt},t(E,[2,47]),{5:[1,131]},t(E,[2,48]),t(E,[2,49]),t(K,[2,66],{79:104,75:$,80:F,81:W,82:z,83:Z,84:Y,85:U,86:G,87:V,88:q}),{33:132,89:T,90:_},{35:133,89:[1,134],90:[1,135]},{37:136,47:[1,137],48:[1,138],49:[1,139]},{39:140,50:[1,141],51:[1,142],52:[1,143],53:[1,144]},t(E,[2,27]),{5:J,28:145,31:tt,34:et,36:nt,38:rt,40:it},{58:146,89:[1,147],90:[1,148]},{60:149,89:[1,150],90:[1,151]},t(E,[2,46]),{5:at,40:st,56:152,57:ot,59:lt},{5:[1,153]},{5:[1,154]},{5:[2,83]},{5:[2,84]},{5:[1,155]},{5:[2,35]},{5:[2,36]},{5:[2,37]},{5:[1,156]},{5:[2,38]},{5:[2,39]},{5:[2,40]},{5:[2,41]},t(E,[2,22]),{5:[1,157]},{5:[2,87]},{5:[2,88]},{5:[1,158]},{5:[2,89]},{5:[2,90]},t(E,[2,43]),{5:J,28:159,31:tt,34:et,36:nt,38:rt,40:it},{5:J,28:160,31:tt,34:et,36:nt,38:rt,40:it},{5:J,28:161,31:tt,34:et,36:nt,38:rt,40:it},{5:J,28:162,31:tt,34:et,36:nt,38:rt,40:it},{5:at,40:st,56:163,57:ot,59:lt},{5:at,40:st,56:164,57:ot,59:lt},t(E,[2,23]),t(E,[2,24]),t(E,[2,25]),t(E,[2,26]),t(E,[2,44]),t(E,[2,45])],defaultActions:{8:[2,2],12:[2,1],41:[2,3],42:[2,8],43:[2,9],44:[2,10],45:[2,11],46:[2,12],47:[2,13],48:[2,14],49:[2,15],50:[2,16],134:[2,83],135:[2,84],137:[2,35],138:[2,36],139:[2,37],141:[2,38],142:[2,39],143:[2,40],144:[2,41],147:[2,87],148:[2,88],150:[2,89],151:[2,90]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},ht=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:return"title";case 1:return this.begin("acc_title"),9;case 2:return this.popState(),"acc_title_value";case 3:return this.begin("acc_descr"),11;case 4:return this.popState(),"acc_descr_value";case 5:this.begin("acc_descr_multiline");break;case 6:case 58:case 65:this.popState();break;case 7:return"acc_descr_multiline_value";case 8:return 21;case 9:return 22;case 10:return 23;case 11:return 24;case 12:return 5;case 13:case 14:case 15:case 56:break;case 16:return 8;case 17:return 6;case 18:return 27;case 19:return 40;case 20:return 29;case 21:return 32;case 22:return 31;case 23:return 34;case 24:return 36;case 25:return 38;case 26:return 41;case 27:return 42;case 28:return 43;case 29:return 44;case 30:return 45;case 31:return 46;case 32:return 47;case 33:return 48;case 34:return 49;case 35:return 50;case 36:return 51;case 37:return 52;case 38:return 53;case 39:return 54;case 40:return 65;case 41:return 66;case 42:return 67;case 43:return 68;case 44:return 69;case 45:return 70;case 46:return 71;case 47:return 57;case 48:return 59;case 49:return this.begin("style"),77;case 50:case 68:return 75;case 51:return 81;case 52:return 88;case 53:return"PERCENT";case 54:return 86;case 55:return 84;case 57:case 64:this.begin("string");break;case 59:return this.begin("style"),72;case 60:return this.begin("style"),74;case 61:return 61;case 62:return 64;case 63:return 63;case 66:return"qString";case 67:return e.yytext=e.yytext.trim(),89;case 69:return 80;case 70:return 76}}),"anonymous"),rules:[/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:$)/i,/^(?:requirementDiagram\b)/i,/^(?:\{)/i,/^(?:\})/i,/^(?::{3})/i,/^(?::)/i,/^(?:id\b)/i,/^(?:text\b)/i,/^(?:risk\b)/i,/^(?:verifyMethod\b)/i,/^(?:requirement\b)/i,/^(?:functionalRequirement\b)/i,/^(?:interfaceRequirement\b)/i,/^(?:performanceRequirement\b)/i,/^(?:physicalRequirement\b)/i,/^(?:designConstraint\b)/i,/^(?:low\b)/i,/^(?:medium\b)/i,/^(?:high\b)/i,/^(?:analysis\b)/i,/^(?:demonstration\b)/i,/^(?:inspection\b)/i,/^(?:test\b)/i,/^(?:element\b)/i,/^(?:contains\b)/i,/^(?:copies\b)/i,/^(?:derives\b)/i,/^(?:satisfies\b)/i,/^(?:verifies\b)/i,/^(?:refines\b)/i,/^(?:traces\b)/i,/^(?:type\b)/i,/^(?:docref\b)/i,/^(?:style\b)/i,/^(?:\w+)/i,/^(?::)/i,/^(?:;)/i,/^(?:%)/i,/^(?:-)/i,/^(?:#)/i,/^(?: )/i,/^(?:["])/i,/^(?:\n)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:<-)/i,/^(?:->)/i,/^(?:-)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[\w][^:,\r\n\{\<\>\-\=]*)/i,/^(?:\w+)/i,/^(?:[0-9]+)/i,/^(?:,)/i],conditions:{acc_descr_multiline:{rules:[6,7,68,69,70],inclusive:!1},acc_descr:{rules:[4,68,69,70],inclusive:!1},acc_title:{rules:[2,68,69,70],inclusive:!1},style:{rules:[50,51,52,53,54,55,56,57,58,68,69,70],inclusive:!1},unqString:{rules:[68,69,70],inclusive:!1},token:{rules:[68,69,70],inclusive:!1},string:{rules:[65,66,68,69,70],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,59,60,61,62,63,64,67,68,69,70],inclusive:!0}}}}();function ut(){this.yy={}}return ct.lexer=ht,(0,s.eW)(ut,"Parser"),ut.prototype=ct,ct.Parser=ut,new ut}();o.parser=o;var l=o,c=class{constructor(){this.relations=[],this.latestRequirement=this.getInitialRequirement(),this.requirements=new Map,this.latestElement=this.getInitialElement(),this.elements=new Map,this.classes=new Map,this.direction="TB",this.RequirementType={REQUIREMENT:"Requirement",FUNCTIONAL_REQUIREMENT:"Functional Requirement",INTERFACE_REQUIREMENT:"Interface Requirement",PERFORMANCE_REQUIREMENT:"Performance Requirement",PHYSICAL_REQUIREMENT:"Physical Requirement",DESIGN_CONSTRAINT:"Design Constraint"},this.RiskLevel={LOW_RISK:"Low",MED_RISK:"Medium",HIGH_RISK:"High"},this.VerifyType={VERIFY_ANALYSIS:"Analysis",VERIFY_DEMONSTRATION:"Demonstration",VERIFY_INSPECTION:"Inspection",VERIFY_TEST:"Test"},this.Relationships={CONTAINS:"contains",COPIES:"copies",DERIVES:"derives",SATISFIES:"satisfies",VERIFIES:"verifies",REFINES:"refines",TRACES:"traces"},this.setAccTitle=s.GN,this.getAccTitle=s.eu,this.setAccDescription=s.U$,this.getAccDescription=s.Mx,this.setDiagramTitle=s.g2,this.getDiagramTitle=s.Kr,this.getConfig=(0,s.eW)((()=>(0,s.nV)().requirement),"getConfig"),this.clear(),this.setDirection=this.setDirection.bind(this),this.addRequirement=this.addRequirement.bind(this),this.setNewReqId=this.setNewReqId.bind(this),this.setNewReqRisk=this.setNewReqRisk.bind(this),this.setNewReqText=this.setNewReqText.bind(this),this.setNewReqVerifyMethod=this.setNewReqVerifyMethod.bind(this),this.addElement=this.addElement.bind(this),this.setNewElementType=this.setNewElementType.bind(this),this.setNewElementDocRef=this.setNewElementDocRef.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setCssStyle=this.setCssStyle.bind(this),this.setClass=this.setClass.bind(this),this.defineClass=this.defineClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{(0,s.eW)(this,"RequirementDB")}getDirection(){return this.direction}setDirection(t){this.direction=t}resetLatestRequirement(){this.latestRequirement=this.getInitialRequirement()}resetLatestElement(){this.latestElement=this.getInitialElement()}getInitialRequirement(){return{requirementId:"",text:"",risk:"",verifyMethod:"",name:"",type:"",cssStyles:[],classes:["default"]}}getInitialElement(){return{name:"",type:"",docRef:"",cssStyles:[],classes:["default"]}}addRequirement(t,e){return this.requirements.has(t)||this.requirements.set(t,{name:t,type:e,requirementId:this.latestRequirement.requirementId,text:this.latestRequirement.text,risk:this.latestRequirement.risk,verifyMethod:this.latestRequirement.verifyMethod,cssStyles:[],classes:["default"]}),this.resetLatestRequirement(),this.requirements.get(t)}getRequirements(){return this.requirements}setNewReqId(t){void 0!==this.latestRequirement&&(this.latestRequirement.requirementId=t)}setNewReqText(t){void 0!==this.latestRequirement&&(this.latestRequirement.text=t)}setNewReqRisk(t){void 0!==this.latestRequirement&&(this.latestRequirement.risk=t)}setNewReqVerifyMethod(t){void 0!==this.latestRequirement&&(this.latestRequirement.verifyMethod=t)}addElement(t){return this.elements.has(t)||(this.elements.set(t,{name:t,type:this.latestElement.type,docRef:this.latestElement.docRef,cssStyles:[],classes:["default"]}),s.cM.info("Added new element: ",t)),this.resetLatestElement(),this.elements.get(t)}getElements(){return this.elements}setNewElementType(t){void 0!==this.latestElement&&(this.latestElement.type=t)}setNewElementDocRef(t){void 0!==this.latestElement&&(this.latestElement.docRef=t)}addRelationship(t,e,n){this.relations.push({type:t,src:e,dst:n})}getRelationships(){return this.relations}clear(){this.relations=[],this.resetLatestRequirement(),this.requirements=new Map,this.resetLatestElement(),this.elements=new Map,this.classes=new Map,(0,s.ZH)()}setCssStyle(t,e){for(const n of t){const t=this.requirements.get(n)??this.elements.get(n);if(!e||!t)return;for(const n of e)n.includes(",")?t.cssStyles.push(...n.split(",")):t.cssStyles.push(n)}}setClass(t,e){for(const n of t){const t=this.requirements.get(n)??this.elements.get(n);if(t)for(const n of e){t.classes.push(n);const e=this.classes.get(n)?.styles;e&&t.cssStyles.push(...e)}}}defineClass(t,e){for(const n of t){let t=this.classes.get(n);void 0===t&&(t={id:n,styles:[],textStyles:[]},this.classes.set(n,t)),e&&e.forEach((function(e){if(/color/.exec(e)){const n=e.replace("fill","bgFill");t.textStyles.push(n)}t.styles.push(e)})),this.requirements.forEach((t=>{t.classes.includes(n)&&t.cssStyles.push(...e.flatMap((t=>t.split(","))))})),this.elements.forEach((t=>{t.classes.includes(n)&&t.cssStyles.push(...e.flatMap((t=>t.split(","))))}))}}getClasses(){return this.classes}getData(){const t=(0,s.nV)(),e=[],n=[];for(const n of this.requirements.values()){const r=n;r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(" "),r.shape="requirementBox",r.look=t.look,e.push(r)}for(const n of this.elements.values()){const r=n;r.shape="requirementBox",r.look=t.look,r.id=n.name,r.cssStyles=n.cssStyles,r.cssClasses=n.classes.join(" "),e.push(r)}for(const e of this.relations){let r=0;const i=e.type===this.Relationships.CONTAINS,a={id:`${e.src}-${e.dst}-${r}`,start:this.requirements.get(e.src)?.name??this.elements.get(e.src)?.name,end:this.requirements.get(e.dst)?.name??this.elements.get(e.dst)?.name,label:`<<${e.type}>>`,classes:"relationshipLine",style:["fill:none",i?"":"stroke-dasharray: 10,7"],labelpos:"c",thickness:"normal",type:"normal",pattern:i?"normal":"dashed",arrowTypeStart:i?"requirement_contains":"",arrowTypeEnd:i?"":"requirement_arrow",look:t.look};n.push(a),r++}return{nodes:e,edges:n,other:{},config:t,direction:this.getDirection()}}},h=(0,s.eW)((t=>`\n\n marker {\n fill: ${t.relationColor};\n stroke: ${t.relationColor};\n }\n\n marker.cross {\n stroke: ${t.lineColor};\n }\n\n svg {\n font-family: ${t.fontFamily};\n font-size: ${t.fontSize};\n }\n\n .reqBox {\n fill: ${t.requirementBackground};\n fill-opacity: 1.0;\n stroke: ${t.requirementBorderColor};\n stroke-width: ${t.requirementBorderSize};\n }\n \n .reqTitle, .reqLabel{\n fill: ${t.requirementTextColor};\n }\n .reqLabelBox {\n fill: ${t.relationLabelBackground};\n fill-opacity: 1.0;\n }\n\n .req-title-line {\n stroke: ${t.requirementBorderColor};\n stroke-width: ${t.requirementBorderSize};\n }\n .relationshipLine {\n stroke: ${t.relationColor};\n stroke-width: 1;\n }\n .relationshipLabel {\n fill: ${t.relationLabelColor};\n }\n .divider {\n stroke: ${t.nodeBorder};\n stroke-width: 1;\n }\n .label {\n font-family: ${t.fontFamily};\n color: ${t.nodeTextColor||t.textColor};\n }\n .label text,span {\n fill: ${t.nodeTextColor||t.textColor};\n color: ${t.nodeTextColor||t.textColor};\n }\n .labelBkg {\n background-color: ${t.edgeLabelBackground};\n }\n\n`),"getStyles"),u={};(0,s.r2)(u,{draw:()=>d});var d=(0,s.eW)((async function(t,e,n,o){s.cM.info("REF0:"),s.cM.info("Drawing requirement diagram (unified)",e);const{securityLevel:l,state:c,layout:h}=(0,s.nV)(),u=o.db.getData(),d=(0,r.q)(e,l);u.type=o.type,u.layoutAlgorithm=(0,i._b)(h),u.nodeSpacing=c?.nodeSpacing??50,u.rankSpacing=c?.rankSpacing??50,u.markers=["requirement_contains","requirement_arrow"],u.diagramId=e,await(0,i.sY)(u,d),a.w8.insertTitle(d,"requirementDiagramTitleText",c?.titleTopMargin??25,o.db.getDiagramTitle()),(0,r.j)(d,8,"requirementDiagram",c?.useMaxWidth??!0)}),"draw"),p={parser:l,get db(){return new c},renderer:u,styles:h}},7096:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>it});var r=n(4082),i=n(3108);function a(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n>e||void 0===n&&e>=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n>i||void 0===n&&i>=i)&&(n=i)}return n}function s(t){return t.target.depth}function o(t,e){return t.sourceLinks.length?t.depth:e-1}function l(t,e){let n=0;if(void 0===e)for(let e of t)(e=+e)&&(n+=e);else{let r=-1;for(let i of t)(i=+e(i,++r,t))&&(n+=i)}return n}function c(t,e){let n;if(void 0===e)for(const e of t)null!=e&&(n=e)&&(n=e);else{let r=-1;for(let i of t)null!=(i=e(i,++r,t))&&(n=i)&&(n=i)}return n}function h(t){return function(){return t}}function u(t,e){return p(t.source,e.source)||t.index-e.index}function d(t,e){return p(t.target,e.target)||t.index-e.index}function p(t,e){return t.y0-e.y0}function g(t){return t.value}function f(t){return t.index}function m(t){return t.nodes}function y(t){return t.links}function v(t,e){const n=t.get(e);if(!n)throw new Error("missing: "+e);return n}function x({nodes:t}){for(const e of t){let t=e.y0,n=t;for(const n of e.sourceLinks)n.y0=t+n.width/2,t+=n.width;for(const t of e.targetLinks)t.y1=n+t.width/2,n+=t.width}}var b=Math.PI,w=2*b,k=1e-6,T=w-k;function _(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function E(){return new _}_.prototype=E.prototype={constructor:_,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,r){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+r)},bezierCurveTo:function(t,e,n,r,i,a){this._+="C"+ +t+","+ +e+","+ +n+","+ +r+","+(this._x1=+i)+","+(this._y1=+a)},arcTo:function(t,e,n,r,i){t=+t,e=+e,n=+n,r=+r,i=+i;var a=this._x1,s=this._y1,o=n-t,l=r-e,c=a-t,h=s-e,u=c*c+h*h;if(i<0)throw new Error("negative radius: "+i);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(u>k)if(Math.abs(h*o-l*c)>k&&i){var d=n-a,p=r-s,g=o*o+l*l,f=d*d+p*p,m=Math.sqrt(g),y=Math.sqrt(u),v=i*Math.tan((b-Math.acos((g+u-f)/(2*m*y)))/2),x=v/y,w=v/m;Math.abs(x-1)>k&&(this._+="L"+(t+x*c)+","+(e+x*h)),this._+="A"+i+","+i+",0,0,"+ +(h*d>c*p)+","+(this._x1=t+w*o)+","+(this._y1=e+w*l)}else this._+="L"+(this._x1=t)+","+(this._y1=e)},arc:function(t,e,n,r,i,a){t=+t,e=+e,a=!!a;var s=(n=+n)*Math.cos(r),o=n*Math.sin(r),l=t+s,c=e+o,h=1^a,u=a?r-i:i-r;if(n<0)throw new Error("negative radius: "+n);null===this._x1?this._+="M"+l+","+c:(Math.abs(this._x1-l)>k||Math.abs(this._y1-c)>k)&&(this._+="L"+l+","+c),n&&(u<0&&(u=u%w+w),u>T?this._+="A"+n+","+n+",0,1,"+h+","+(t-s)+","+(e-o)+"A"+n+","+n+",0,1,"+h+","+(this._x1=l)+","+(this._y1=c):u>k&&(this._+="A"+n+","+n+",0,"+ +(u>=b)+","+h+","+(this._x1=t+n*Math.cos(i))+","+(this._y1=e+n*Math.sin(i))))},rect:function(t,e,n,r){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +r+"h"+-n+"Z"},toString:function(){return this._}};const S=E;var C=Array.prototype.slice;function A(t){return function(){return t}}function L(t){return t[0]}function M(t){return t[1]}function N(t){return t.source}function I(t){return t.target}function R(t,e,n,r,i){t.moveTo(e,n),t.bezierCurveTo(e=(e+r)/2,n,e,i,r,i)}function D(t){return[t.source.x1,t.y0]}function O(t){return[t.target.x0,t.y1]}function P(){return function(t){var e=N,n=I,r=L,i=M,a=null;function s(){var s,o=C.call(arguments),l=e.apply(this,o),c=n.apply(this,o);if(a||(a=s=S()),t(a,+r.apply(this,(o[0]=l,o)),+i.apply(this,o),+r.apply(this,(o[0]=c,o)),+i.apply(this,o)),s)return a=null,s+""||null}return s.source=function(t){return arguments.length?(e=t,s):e},s.target=function(t){return arguments.length?(n=t,s):n},s.x=function(t){return arguments.length?(r="function"==typeof t?t:A(+t),s):r},s.y=function(t){return arguments.length?(i="function"==typeof t?t:A(+t),s):i},s.context=function(t){return arguments.length?(a=null==t?null:t,s):a},s}(R).source(D).target(O)}var $=function(){var t=(0,r.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,9],n=[1,10],i=[1,5,10,12],a={trace:(0,r.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,SANKEY:4,NEWLINE:5,csv:6,opt_eof:7,record:8,csv_tail:9,EOF:10,"field[source]":11,COMMA:12,"field[target]":13,"field[value]":14,field:15,escaped:16,non_escaped:17,DQUOTE:18,ESCAPED_TEXT:19,NON_ESCAPED_TEXT:20,$accept:0,$end:1},terminals_:{2:"error",4:"SANKEY",5:"NEWLINE",10:"EOF",11:"field[source]",12:"COMMA",13:"field[target]",14:"field[value]",18:"DQUOTE",19:"ESCAPED_TEXT",20:"NON_ESCAPED_TEXT"},productions_:[0,[3,4],[6,2],[9,2],[9,0],[7,1],[7,0],[8,5],[15,1],[15,1],[16,3],[17,1]],performAction:(0,r.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 7:const t=r.findOrCreateNode(a[o-4].trim().replaceAll('""','"')),e=r.findOrCreateNode(a[o-2].trim().replaceAll('""','"')),n=parseFloat(a[o].trim());r.addLink(t,e,n);break;case 8:case 9:case 11:this.$=a[o];break;case 10:this.$=a[o-1]}}),"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},{5:[1,3]},{6:4,8:5,15:6,16:7,17:8,18:e,20:n},{1:[2,6],7:11,10:[1,12]},t(n,[2,4],{9:13,5:[1,14]}),{12:[1,15]},t(i,[2,8]),t(i,[2,9]),{19:[1,16]},t(i,[2,11]),{1:[2,1]},{1:[2,5]},t(n,[2,2]),{6:17,8:5,15:6,16:7,17:8,18:e,20:n},{15:18,16:7,17:8,18:e,20:n},{18:[1,19]},t(n,[2,3]),{12:[1,20]},t(i,[2,10]),{15:21,16:7,17:8,18:e,20:n},t([1,5,10],[2,7])],defaultActions:{11:[2,1],12:[2,5]},parseError:(0,r.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,r.eW)((function(t){var e=this,n=[0],i=[],a=[null],s=[],o=this.table,l="",c=0,h=0,u=0,d=s.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;s.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=i.pop()||p.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,r.eW)((function(t){n.length=n.length-2*t,a.length=a.length-t,s.length=s.length-t}),"popStack"),(0,r.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),a.push(p.yytext),s.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=a[a.length-E],A._$={first_line:s[s.length-(E||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(E||1)].first_column,last_column:s[s.length-1].last_column},y&&(A._$.range=[s[s.length-(E||1)].range[0],s[s.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],a,s].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),a=a.slice(0,-1*E),s=s.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),a.push(A.$),s.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},s=function(){return{EOF:1,parseError:(0,r.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,r.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,r.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,r.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,r.eW)((function(){return this._more=!0,this}),"more"),reject:(0,r.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,r.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,r.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,r.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,r.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,r.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,r.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,r.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,r.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,r.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,r.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,r.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,r.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,r.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,r.eW)((function(t,e,n,r){switch(n){case 0:return this.pushState("csv"),4;case 1:return 10;case 2:return 5;case 3:return 12;case 4:return this.pushState("escaped_text"),18;case 5:return 20;case 6:return this.popState("escaped_text"),18;case 7:return 19}}),"anonymous"),rules:[/^(?:sankey-beta\b)/i,/^(?:$)/i,/^(?:((\u000D\u000A)|(\u000A)))/i,/^(?:(\u002C))/i,/^(?:(\u0022))/i,/^(?:([\u0020-\u0021\u0023-\u002B\u002D-\u007E])*)/i,/^(?:(\u0022)(?!(\u0022)))/i,/^(?:(([\u0020-\u0021\u0023-\u002B\u002D-\u007E])|(\u002C)|(\u000D)|(\u000A)|(\u0022)(\u0022))*)/i],conditions:{csv:{rules:[1,2,3,4,5,6,7],inclusive:!1},escaped_text:{rules:[6,7],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7],inclusive:!0}}}}();function o(){this.yy={}}return a.lexer=s,(0,r.eW)(o,"Parser"),o.prototype=a,a.Parser=o,new o}();$.parser=$;var B=$,F=[],W=[],z=new Map,Z=(0,r.eW)((()=>{F=[],W=[],z=new Map,(0,r.ZH)()}),"clear"),Y=class{constructor(t,e,n=0){this.source=t,this.target=e,this.value=n}static{(0,r.eW)(this,"SankeyLink")}},U=(0,r.eW)(((t,e,n)=>{F.push(new Y(t,e,n))}),"addLink"),G=class{constructor(t){this.ID=t}static{(0,r.eW)(this,"SankeyNode")}},V=(0,r.eW)((t=>{t=r.SY.sanitizeText(t,(0,r.nV)());let e=z.get(t);return void 0===e&&(e=new G(t),z.set(t,e),W.push(e)),e}),"findOrCreateNode"),q=(0,r.eW)((()=>W),"getNodes"),j=(0,r.eW)((()=>F),"getLinks"),H=(0,r.eW)((()=>({nodes:W.map((t=>({id:t.ID}))),links:F.map((t=>({source:t.source.ID,target:t.target.ID,value:t.value})))})),"getGraph"),X={nodesMap:z,getConfig:(0,r.eW)((()=>(0,r.nV)().sankey),"getConfig"),getNodes:q,getLinks:j,getGraph:H,addLink:U,findOrCreateNode:V,getAccTitle:r.eu,setAccTitle:r.GN,getAccDescription:r.Mx,setAccDescription:r.U$,getDiagramTitle:r.Kr,setDiagramTitle:r.g2,clear:Z},K=class t{static{(0,r.eW)(this,"Uid")}static{this.count=0}static next(e){return new t(e+ ++t.count)}constructor(t){this.id=t,this.href=`#${t}`}toString(){return"url("+this.href+")"}},Q={left:function(t){return t.depth},right:function(t,e){return e-1-t.height},center:function(t){return t.targetLinks.length?t.depth:t.sourceLinks.length?a(t.sourceLinks,s)-1:0},justify:o},J=(0,r.eW)((function(t,e,n,s){const{securityLevel:b,sankey:w}=(0,r.nV)(),k=r.Fy.sankey;let T;"sandbox"===b&&(T=(0,i.Ys)("#i"+e));const _="sandbox"===b?(0,i.Ys)(T.nodes()[0].contentDocument.body):(0,i.Ys)("body"),E="sandbox"===b?_.select(`[id="${e}"]`):(0,i.Ys)(`[id="${e}"]`),S=w?.width??k.width,C=w?.height??k.width,A=w?.useMaxWidth??k.useMaxWidth,L=w?.nodeAlignment??k.nodeAlignment,M=w?.prefix??k.prefix,N=w?.suffix??k.suffix,I=w?.showValues??k.showValues,R=s.db.getGraph(),D=Q[L];(function(){let t,e,n,r=0,i=0,s=1,b=1,w=24,k=8,T=f,_=o,E=m,S=y,C=6;function A(){const o={nodes:E.apply(null,arguments),links:S.apply(null,arguments)};return function({nodes:t,links:e}){for(const[e,n]of t.entries())n.index=e,n.sourceLinks=[],n.targetLinks=[];const r=new Map(t.map(((e,n)=>[T(e,n,t),e])));for(const[t,n]of e.entries()){n.index=t;let{source:e,target:i}=n;"object"!=typeof e&&(e=n.source=v(r,e)),"object"!=typeof i&&(i=n.target=v(r,i)),e.sourceLinks.push(n),i.targetLinks.push(n)}if(null!=n)for(const{sourceLinks:e,targetLinks:r}of t)e.sort(n),r.sort(n)}(o),function({nodes:t}){for(const e of t)e.value=void 0===e.fixedValue?Math.max(l(e.sourceLinks,g),l(e.targetLinks,g)):e.fixedValue}(o),function({nodes:t}){const e=t.length;let n=new Set(t),r=new Set,i=0;for(;n.size;){for(const t of n){t.depth=i;for(const{target:e}of t.sourceLinks)r.add(e)}if(++i>e)throw new Error("circular link");n=r,r=new Set}}(o),function({nodes:t}){const e=t.length;let n=new Set(t),r=new Set,i=0;for(;n.size;){for(const t of n){t.height=i;for(const{source:e}of t.targetLinks)r.add(e)}if(++i>e)throw new Error("circular link");n=r,r=new Set}}(o),function(n){const o=function({nodes:t}){const n=c(t,(t=>t.depth))+1,i=(s-r-w)/(n-1),a=new Array(n);for(const e of t){const t=Math.max(0,Math.min(n-1,Math.floor(_.call(null,e,n))));e.layer=t,e.x0=r+t*i,e.x1=e.x0+w,a[t]?a[t].push(e):a[t]=[e]}if(e)for(const t of a)t.sort(e);return a}(n);t=Math.min(k,(b-i)/(c(o,(t=>t.length))-1)),function(e){const n=a(e,(e=>(b-i-(e.length-1)*t)/l(e,g)));for(const r of e){let e=i;for(const i of r){i.y0=e,i.y1=e+i.value*n,e=i.y1+t;for(const t of i.sourceLinks)t.width=t.value*n}e=(b-e+t)/(r.length+1);for(let t=0;t0))continue;let i=(e/r-t.y0)*n;t.y0+=i,t.y1+=i,D(t)}void 0===e&&a.sort(p),N(a,r)}}function M(t,n,r){for(let i=t.length-2;i>=0;--i){const a=t[i];for(const t of a){let e=0,r=0;for(const{target:n,value:i}of t.sourceLinks){let a=i*(n.layer-t.layer);e+=$(t,n)*a,r+=a}if(!(r>0))continue;let i=(e/r-t.y0)*n;t.y0+=i,t.y1+=i,D(t)}void 0===e&&a.sort(p),N(a,r)}}function N(e,n){const r=e.length>>1,a=e[r];R(e,a.y0-t,r-1,n),I(e,a.y1+t,r+1,n),R(e,b,e.length-1,n),I(e,i,0,n)}function I(e,n,r,i){for(;r1e-6&&(a.y0+=s,a.y1+=s),n=a.y1+t}}function R(e,n,r,i){for(;r>=0;--r){const a=e[r],s=(a.y1-n)*i;s>1e-6&&(a.y0-=s,a.y1-=s),n=a.y0-t}}function D({sourceLinks:t,targetLinks:e}){if(void 0===n){for(const{source:{sourceLinks:t}}of e)t.sort(d);for(const{target:{targetLinks:e}}of t)e.sort(u)}}function O(t){if(void 0===n)for(const{sourceLinks:e,targetLinks:n}of t)e.sort(d),n.sort(u)}function P(e,n){let r=e.y0-(e.sourceLinks.length-1)*t/2;for(const{target:i,width:a}of e.sourceLinks){if(i===n)break;r+=a+t}for(const{source:t,width:i}of n.targetLinks){if(t===e)break;r-=i}return r}function $(e,n){let r=n.y0-(n.targetLinks.length-1)*t/2;for(const{source:i,width:a}of n.targetLinks){if(i===e)break;r+=a+t}for(const{target:t,width:i}of e.sourceLinks){if(t===n)break;r-=i}return r}return A.update=function(t){return x(t),t},A.nodeId=function(t){return arguments.length?(T="function"==typeof t?t:h(t),A):T},A.nodeAlign=function(t){return arguments.length?(_="function"==typeof t?t:h(t),A):_},A.nodeSort=function(t){return arguments.length?(e=t,A):e},A.nodeWidth=function(t){return arguments.length?(w=+t,A):w},A.nodePadding=function(e){return arguments.length?(k=t=+e,A):k},A.nodes=function(t){return arguments.length?(E="function"==typeof t?t:h(t),A):E},A.links=function(t){return arguments.length?(S="function"==typeof t?t:h(t),A):S},A.linkSort=function(t){return arguments.length?(n=t,A):n},A.size=function(t){return arguments.length?(r=i=0,s=+t[0],b=+t[1],A):[s-r,b-i]},A.extent=function(t){return arguments.length?(r=+t[0][0],s=+t[1][0],i=+t[0][1],b=+t[1][1],A):[[r,i],[s,b]]},A.iterations=function(t){return arguments.length?(C=+t,A):C},A})().nodeId((t=>t.id)).nodeWidth(10).nodePadding(10+(I?15:0)).nodeAlign(D).extent([[0,0],[S,C]])(R);const O=(0,i.PKp)(i.K2I);E.append("g").attr("class","nodes").selectAll(".node").data(R.nodes).join("g").attr("class","node").attr("id",(t=>(t.uid=K.next("node-")).id)).attr("transform",(function(t){return"translate("+t.x0+","+t.y0+")"})).attr("x",(t=>t.x0)).attr("y",(t=>t.y0)).append("rect").attr("height",(t=>t.y1-t.y0)).attr("width",(t=>t.x1-t.x0)).attr("fill",(t=>O(t.id)));const $=(0,r.eW)((({id:t,value:e})=>I?`${t}\n${M}${Math.round(100*e)/100}${N}`:t),"getText");E.append("g").attr("class","node-labels").attr("font-size",14).selectAll("text").data(R.nodes).join("text").attr("x",(t=>t.x0(t.y1+t.y0)/2)).attr("dy",(I?"0":"0.35")+"em").attr("text-anchor",(t=>t.x0(t.uid=K.next("linearGradient-")).id)).attr("gradientUnits","userSpaceOnUse").attr("x1",(t=>t.source.x1)).attr("x2",(t=>t.target.x0));t.append("stop").attr("offset","0%").attr("stop-color",(t=>O(t.source.id))),t.append("stop").attr("offset","100%").attr("stop-color",(t=>O(t.target.id)))}let W;switch(F){case"gradient":W=(0,r.eW)((t=>t.uid),"coloring");break;case"source":W=(0,r.eW)((t=>O(t.source.id)),"coloring");break;case"target":W=(0,r.eW)((t=>O(t.target.id)),"coloring");break;default:W=F}B.append("path").attr("d",P()).attr("stroke",W).attr("stroke-width",(t=>Math.max(1,t.width))),(0,r.j7)(void 0,E,0,A)}),"draw"),tt={draw:J},et=(0,r.eW)((t=>t.replaceAll(/^[^\S\n\r]+|[^\S\n\r]+$/g,"").replaceAll(/([\n\r])+/g,"\n").trim()),"prepareTextForParsing"),nt=(0,r.eW)((t=>`.label {\n font-family: ${t.fontFamily};\n }`),"getStyles"),rt=B.parse.bind(B);B.parse=t=>rt(et(t));var it={styles:nt,parser:B,db:X,renderer:tt}},4438:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>mt});var r=n(279),i=n(7207),a=n(7946),s=n(4082),o=n(3108),l=n(7967),c=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,2],n=[1,3],r=[1,4],i=[2,4],a=[1,9],o=[1,11],l=[1,13],c=[1,14],h=[1,16],u=[1,17],d=[1,18],p=[1,24],g=[1,25],f=[1,26],m=[1,27],y=[1,28],v=[1,29],x=[1,30],b=[1,31],w=[1,32],k=[1,33],T=[1,34],_=[1,35],E=[1,36],S=[1,37],C=[1,38],A=[1,39],L=[1,41],M=[1,42],N=[1,43],I=[1,44],R=[1,45],D=[1,46],O=[1,4,5,13,14,16,18,21,23,29,30,31,33,35,36,37,38,39,41,43,44,46,47,48,49,50,52,53,54,59,60,61,62,70],P=[4,5,16,50,52,53],$=[4,5,13,14,16,18,21,23,29,30,31,33,35,36,37,38,39,41,43,44,46,50,52,53,54,59,60,61,62,70],B=[4,5,13,14,16,18,21,23,29,30,31,33,35,36,37,38,39,41,43,44,46,49,50,52,53,54,59,60,61,62,70],F=[4,5,13,14,16,18,21,23,29,30,31,33,35,36,37,38,39,41,43,44,46,48,50,52,53,54,59,60,61,62,70],W=[4,5,13,14,16,18,21,23,29,30,31,33,35,36,37,38,39,41,43,44,46,47,50,52,53,54,59,60,61,62,70],z=[68,69,70],Z=[1,122],Y={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,SPACE:4,NEWLINE:5,SD:6,document:7,line:8,statement:9,box_section:10,box_line:11,participant_statement:12,create:13,box:14,restOfLine:15,end:16,signal:17,autonumber:18,NUM:19,off:20,activate:21,actor:22,deactivate:23,note_statement:24,links_statement:25,link_statement:26,properties_statement:27,details_statement:28,title:29,legacy_title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,loop:36,rect:37,opt:38,alt:39,else_sections:40,par:41,par_sections:42,par_over:43,critical:44,option_sections:45,break:46,option:47,and:48,else:49,participant:50,AS:51,participant_actor:52,destroy:53,note:54,placement:55,text2:56,over:57,actor_pair:58,links:59,link:60,properties:61,details:62,spaceList:63,",":64,left_of:65,right_of:66,signaltype:67,"+":68,"-":69,ACTOR:70,SOLID_OPEN_ARROW:71,DOTTED_OPEN_ARROW:72,SOLID_ARROW:73,BIDIRECTIONAL_SOLID_ARROW:74,DOTTED_ARROW:75,BIDIRECTIONAL_DOTTED_ARROW:76,SOLID_CROSS:77,DOTTED_CROSS:78,SOLID_POINT:79,DOTTED_POINT:80,TXT:81,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NEWLINE",6:"SD",13:"create",14:"box",15:"restOfLine",16:"end",18:"autonumber",19:"NUM",20:"off",21:"activate",23:"deactivate",29:"title",30:"legacy_title",31:"acc_title",32:"acc_title_value",33:"acc_descr",34:"acc_descr_value",35:"acc_descr_multiline_value",36:"loop",37:"rect",38:"opt",39:"alt",41:"par",43:"par_over",44:"critical",46:"break",47:"option",48:"and",49:"else",50:"participant",51:"AS",52:"participant_actor",53:"destroy",54:"note",57:"over",59:"links",60:"link",61:"properties",62:"details",64:",",65:"left_of",66:"right_of",68:"+",69:"-",70:"ACTOR",71:"SOLID_OPEN_ARROW",72:"DOTTED_OPEN_ARROW",73:"SOLID_ARROW",74:"BIDIRECTIONAL_SOLID_ARROW",75:"DOTTED_ARROW",76:"BIDIRECTIONAL_DOTTED_ARROW",77:"SOLID_CROSS",78:"DOTTED_CROSS",79:"SOLID_POINT",80:"DOTTED_POINT",81:"TXT"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[10,0],[10,2],[11,2],[11,1],[11,1],[9,1],[9,2],[9,4],[9,2],[9,4],[9,3],[9,3],[9,2],[9,3],[9,3],[9,2],[9,2],[9,2],[9,2],[9,2],[9,1],[9,1],[9,2],[9,2],[9,1],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[9,4],[45,1],[45,4],[42,1],[42,4],[40,1],[40,4],[12,5],[12,3],[12,5],[12,3],[12,3],[24,4],[24,4],[25,3],[26,3],[27,3],[28,3],[63,2],[63,1],[58,3],[58,1],[55,1],[55,1],[17,5],[17,5],[17,4],[22,1],[67,1],[67,1],[67,1],[67,1],[67,1],[67,1],[67,1],[67,1],[67,1],[67,1],[56,1]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 3:return r.apply(a[o]),a[o];case 4:case 9:case 8:case 13:this.$=[];break;case 5:case 10:a[o-1].push(a[o]),this.$=a[o-1];break;case 6:case 7:case 11:case 12:case 62:this.$=a[o];break;case 15:a[o].type="createParticipant",this.$=a[o];break;case 16:a[o-1].unshift({type:"boxStart",boxData:r.parseBoxData(a[o-2])}),a[o-1].push({type:"boxEnd",boxText:a[o-2]}),this.$=a[o-1];break;case 18:this.$={type:"sequenceIndex",sequenceIndex:Number(a[o-2]),sequenceIndexStep:Number(a[o-1]),sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 19:this.$={type:"sequenceIndex",sequenceIndex:Number(a[o-1]),sequenceIndexStep:1,sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 20:this.$={type:"sequenceIndex",sequenceVisible:!1,signalType:r.LINETYPE.AUTONUMBER};break;case 21:this.$={type:"sequenceIndex",sequenceVisible:!0,signalType:r.LINETYPE.AUTONUMBER};break;case 22:this.$={type:"activeStart",signalType:r.LINETYPE.ACTIVE_START,actor:a[o-1].actor};break;case 23:this.$={type:"activeEnd",signalType:r.LINETYPE.ACTIVE_END,actor:a[o-1].actor};break;case 29:r.setDiagramTitle(a[o].substring(6)),this.$=a[o].substring(6);break;case 30:r.setDiagramTitle(a[o].substring(7)),this.$=a[o].substring(7);break;case 31:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 32:case 33:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 34:a[o-1].unshift({type:"loopStart",loopText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.LOOP_START}),a[o-1].push({type:"loopEnd",loopText:a[o-2],signalType:r.LINETYPE.LOOP_END}),this.$=a[o-1];break;case 35:a[o-1].unshift({type:"rectStart",color:r.parseMessage(a[o-2]),signalType:r.LINETYPE.RECT_START}),a[o-1].push({type:"rectEnd",color:r.parseMessage(a[o-2]),signalType:r.LINETYPE.RECT_END}),this.$=a[o-1];break;case 36:a[o-1].unshift({type:"optStart",optText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.OPT_START}),a[o-1].push({type:"optEnd",optText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.OPT_END}),this.$=a[o-1];break;case 37:a[o-1].unshift({type:"altStart",altText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.ALT_START}),a[o-1].push({type:"altEnd",signalType:r.LINETYPE.ALT_END}),this.$=a[o-1];break;case 38:a[o-1].unshift({type:"parStart",parText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.PAR_START}),a[o-1].push({type:"parEnd",signalType:r.LINETYPE.PAR_END}),this.$=a[o-1];break;case 39:a[o-1].unshift({type:"parStart",parText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.PAR_OVER_START}),a[o-1].push({type:"parEnd",signalType:r.LINETYPE.PAR_END}),this.$=a[o-1];break;case 40:a[o-1].unshift({type:"criticalStart",criticalText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.CRITICAL_START}),a[o-1].push({type:"criticalEnd",signalType:r.LINETYPE.CRITICAL_END}),this.$=a[o-1];break;case 41:a[o-1].unshift({type:"breakStart",breakText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.BREAK_START}),a[o-1].push({type:"breakEnd",optText:r.parseMessage(a[o-2]),signalType:r.LINETYPE.BREAK_END}),this.$=a[o-1];break;case 43:this.$=a[o-3].concat([{type:"option",optionText:r.parseMessage(a[o-1]),signalType:r.LINETYPE.CRITICAL_OPTION},a[o]]);break;case 45:this.$=a[o-3].concat([{type:"and",parText:r.parseMessage(a[o-1]),signalType:r.LINETYPE.PAR_AND},a[o]]);break;case 47:this.$=a[o-3].concat([{type:"else",altText:r.parseMessage(a[o-1]),signalType:r.LINETYPE.ALT_ELSE},a[o]]);break;case 48:a[o-3].draw="participant",a[o-3].type="addParticipant",a[o-3].description=r.parseMessage(a[o-1]),this.$=a[o-3];break;case 49:a[o-1].draw="participant",a[o-1].type="addParticipant",this.$=a[o-1];break;case 50:a[o-3].draw="actor",a[o-3].type="addParticipant",a[o-3].description=r.parseMessage(a[o-1]),this.$=a[o-3];break;case 51:a[o-1].draw="actor",a[o-1].type="addParticipant",this.$=a[o-1];break;case 52:a[o-1].type="destroyParticipant",this.$=a[o-1];break;case 53:this.$=[a[o-1],{type:"addNote",placement:a[o-2],actor:a[o-1].actor,text:a[o]}];break;case 54:a[o-2]=[].concat(a[o-1],a[o-1]).slice(0,2),a[o-2][0]=a[o-2][0].actor,a[o-2][1]=a[o-2][1].actor,this.$=[a[o-1],{type:"addNote",placement:r.PLACEMENT.OVER,actor:a[o-2].slice(0,2),text:a[o]}];break;case 55:this.$=[a[o-1],{type:"addLinks",actor:a[o-1].actor,text:a[o]}];break;case 56:this.$=[a[o-1],{type:"addALink",actor:a[o-1].actor,text:a[o]}];break;case 57:this.$=[a[o-1],{type:"addProperties",actor:a[o-1].actor,text:a[o]}];break;case 58:this.$=[a[o-1],{type:"addDetails",actor:a[o-1].actor,text:a[o]}];break;case 61:this.$=[a[o-2],a[o]];break;case 63:this.$=r.PLACEMENT.LEFTOF;break;case 64:this.$=r.PLACEMENT.RIGHTOF;break;case 65:this.$=[a[o-4],a[o-1],{type:"addMessage",from:a[o-4].actor,to:a[o-1].actor,signalType:a[o-3],msg:a[o],activate:!0},{type:"activeStart",signalType:r.LINETYPE.ACTIVE_START,actor:a[o-1].actor}];break;case 66:this.$=[a[o-4],a[o-1],{type:"addMessage",from:a[o-4].actor,to:a[o-1].actor,signalType:a[o-3],msg:a[o]},{type:"activeEnd",signalType:r.LINETYPE.ACTIVE_END,actor:a[o-4].actor}];break;case 67:this.$=[a[o-3],a[o-1],{type:"addMessage",from:a[o-3].actor,to:a[o-1].actor,signalType:a[o-2],msg:a[o]}];break;case 68:this.$={type:"addParticipant",actor:a[o]};break;case 69:this.$=r.LINETYPE.SOLID_OPEN;break;case 70:this.$=r.LINETYPE.DOTTED_OPEN;break;case 71:this.$=r.LINETYPE.SOLID;break;case 72:this.$=r.LINETYPE.BIDIRECTIONAL_SOLID;break;case 73:this.$=r.LINETYPE.DOTTED;break;case 74:this.$=r.LINETYPE.BIDIRECTIONAL_DOTTED;break;case 75:this.$=r.LINETYPE.SOLID_CROSS;break;case 76:this.$=r.LINETYPE.DOTTED_CROSS;break;case 77:this.$=r.LINETYPE.SOLID_POINT;break;case 78:this.$=r.LINETYPE.DOTTED_POINT;break;case 79:this.$=r.parseMessage(a[o].trim().substring(1))}}),"anonymous"),table:[{3:1,4:e,5:n,6:r},{1:[3]},{3:5,4:e,5:n,6:r},{3:6,4:e,5:n,6:r},t([1,4,5,13,14,18,21,23,29,30,31,33,35,36,37,38,39,41,43,44,46,50,52,53,54,59,60,61,62,70],i,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:a,5:o,8:8,9:10,12:12,13:l,14:c,17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},t(O,[2,5]),{9:47,12:12,13:l,14:c,17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},t(O,[2,7]),t(O,[2,8]),t(O,[2,14]),{12:48,50:S,52:C,53:A},{15:[1,49]},{5:[1,50]},{5:[1,53],19:[1,51],20:[1,52]},{22:54,70:D},{22:55,70:D},{5:[1,56]},{5:[1,57]},{5:[1,58]},{5:[1,59]},{5:[1,60]},t(O,[2,29]),t(O,[2,30]),{32:[1,61]},{34:[1,62]},t(O,[2,33]),{15:[1,63]},{15:[1,64]},{15:[1,65]},{15:[1,66]},{15:[1,67]},{15:[1,68]},{15:[1,69]},{15:[1,70]},{22:71,70:D},{22:72,70:D},{22:73,70:D},{67:74,71:[1,75],72:[1,76],73:[1,77],74:[1,78],75:[1,79],76:[1,80],77:[1,81],78:[1,82],79:[1,83],80:[1,84]},{55:85,57:[1,86],65:[1,87],66:[1,88]},{22:89,70:D},{22:90,70:D},{22:91,70:D},{22:92,70:D},t([5,51,64,71,72,73,74,75,76,77,78,79,80,81],[2,68]),t(O,[2,6]),t(O,[2,15]),t(P,[2,9],{10:93}),t(O,[2,17]),{5:[1,95],19:[1,94]},{5:[1,96]},t(O,[2,21]),{5:[1,97]},{5:[1,98]},t(O,[2,24]),t(O,[2,25]),t(O,[2,26]),t(O,[2,27]),t(O,[2,28]),t(O,[2,31]),t(O,[2,32]),t($,i,{7:99}),t($,i,{7:100}),t($,i,{7:101}),t(B,i,{40:102,7:103}),t(F,i,{42:104,7:105}),t(F,i,{7:105,42:106}),t(W,i,{45:107,7:108}),t($,i,{7:109}),{5:[1,111],51:[1,110]},{5:[1,113],51:[1,112]},{5:[1,114]},{22:117,68:[1,115],69:[1,116],70:D},t(z,[2,69]),t(z,[2,70]),t(z,[2,71]),t(z,[2,72]),t(z,[2,73]),t(z,[2,74]),t(z,[2,75]),t(z,[2,76]),t(z,[2,77]),t(z,[2,78]),{22:118,70:D},{22:120,58:119,70:D},{70:[2,63]},{70:[2,64]},{56:121,81:Z},{56:123,81:Z},{56:124,81:Z},{56:125,81:Z},{4:[1,128],5:[1,130],11:127,12:129,16:[1,126],50:S,52:C,53:A},{5:[1,131]},t(O,[2,19]),t(O,[2,20]),t(O,[2,22]),t(O,[2,23]),{4:a,5:o,8:8,9:10,12:12,13:l,14:c,16:[1,132],17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},{4:a,5:o,8:8,9:10,12:12,13:l,14:c,16:[1,133],17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},{4:a,5:o,8:8,9:10,12:12,13:l,14:c,16:[1,134],17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},{16:[1,135]},{4:a,5:o,8:8,9:10,12:12,13:l,14:c,16:[2,46],17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,49:[1,136],50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},{16:[1,137]},{4:a,5:o,8:8,9:10,12:12,13:l,14:c,16:[2,44],17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,48:[1,138],50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},{16:[1,139]},{16:[1,140]},{4:a,5:o,8:8,9:10,12:12,13:l,14:c,16:[2,42],17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,47:[1,141],50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},{4:a,5:o,8:8,9:10,12:12,13:l,14:c,16:[1,142],17:15,18:h,21:u,22:40,23:d,24:19,25:20,26:21,27:22,28:23,29:p,30:g,31:f,33:m,35:y,36:v,37:x,38:b,39:w,41:k,43:T,44:_,46:E,50:S,52:C,53:A,54:L,59:M,60:N,61:I,62:R,70:D},{15:[1,143]},t(O,[2,49]),{15:[1,144]},t(O,[2,51]),t(O,[2,52]),{22:145,70:D},{22:146,70:D},{56:147,81:Z},{56:148,81:Z},{56:149,81:Z},{64:[1,150],81:[2,62]},{5:[2,55]},{5:[2,79]},{5:[2,56]},{5:[2,57]},{5:[2,58]},t(O,[2,16]),t(P,[2,10]),{12:151,50:S,52:C,53:A},t(P,[2,12]),t(P,[2,13]),t(O,[2,18]),t(O,[2,34]),t(O,[2,35]),t(O,[2,36]),t(O,[2,37]),{15:[1,152]},t(O,[2,38]),{15:[1,153]},t(O,[2,39]),t(O,[2,40]),{15:[1,154]},t(O,[2,41]),{5:[1,155]},{5:[1,156]},{56:157,81:Z},{56:158,81:Z},{5:[2,67]},{5:[2,53]},{5:[2,54]},{22:159,70:D},t(P,[2,11]),t(B,i,{7:103,40:160}),t(F,i,{7:105,42:161}),t(W,i,{7:108,45:162}),t(O,[2,48]),t(O,[2,50]),{5:[2,65]},{5:[2,66]},{81:[2,61]},{16:[2,47]},{16:[2,45]},{16:[2,43]}],defaultActions:{5:[2,1],6:[2,2],87:[2,63],88:[2,64],121:[2,55],122:[2,79],123:[2,56],124:[2,57],125:[2,58],147:[2,67],148:[2,53],149:[2,54],157:[2,65],158:[2,66],159:[2,61],160:[2,47],161:[2,45],162:[2,43]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},U=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:case 51:case 66:return 5;case 1:case 2:case 3:case 4:case 5:break;case 6:return 19;case 7:return this.begin("LINE"),14;case 8:return this.begin("ID"),50;case 9:return this.begin("ID"),52;case 10:return 13;case 11:return this.begin("ID"),53;case 12:return e.yytext=e.yytext.trim(),this.begin("ALIAS"),70;case 13:return this.popState(),this.popState(),this.begin("LINE"),51;case 14:return this.popState(),this.popState(),5;case 15:return this.begin("LINE"),36;case 16:return this.begin("LINE"),37;case 17:return this.begin("LINE"),38;case 18:return this.begin("LINE"),39;case 19:return this.begin("LINE"),49;case 20:return this.begin("LINE"),41;case 21:return this.begin("LINE"),43;case 22:return this.begin("LINE"),48;case 23:return this.begin("LINE"),44;case 24:return this.begin("LINE"),47;case 25:return this.begin("LINE"),46;case 26:return this.popState(),15;case 27:return 16;case 28:return 65;case 29:return 66;case 30:return 59;case 31:return 60;case 32:return 61;case 33:return 62;case 34:return 57;case 35:return 54;case 36:return this.begin("ID"),21;case 37:return this.begin("ID"),23;case 38:return 29;case 39:return 30;case 40:return this.begin("acc_title"),31;case 41:return this.popState(),"acc_title_value";case 42:return this.begin("acc_descr"),33;case 43:return this.popState(),"acc_descr_value";case 44:this.begin("acc_descr_multiline");break;case 45:this.popState();break;case 46:return"acc_descr_multiline_value";case 47:return 6;case 48:return 18;case 49:return 20;case 50:return 64;case 52:return e.yytext=e.yytext.trim(),70;case 53:return 73;case 54:return 74;case 55:return 75;case 56:return 76;case 57:return 71;case 58:return 72;case 59:return 77;case 60:return 78;case 61:return 79;case 62:return 80;case 63:return 81;case 64:return 68;case 65:return 69;case 67:return"INVALID"}}),"anonymous"),rules:[/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[0-9]+(?=[ \n]+))/i,/^(?:box\b)/i,/^(?:participant\b)/i,/^(?:actor\b)/i,/^(?:create\b)/i,/^(?:destroy\b)/i,/^(?:[^\<->\->:\n,;]+?([\-]*[^\<->\->:\n,;]+?)*?(?=((?!\n)\s)+as(?!\n)\s|[#\n;]|$))/i,/^(?:as\b)/i,/^(?:(?:))/i,/^(?:loop\b)/i,/^(?:rect\b)/i,/^(?:opt\b)/i,/^(?:alt\b)/i,/^(?:else\b)/i,/^(?:par\b)/i,/^(?:par_over\b)/i,/^(?:and\b)/i,/^(?:critical\b)/i,/^(?:option\b)/i,/^(?:break\b)/i,/^(?:(?:[:]?(?:no)?wrap)?[^#\n;]*)/i,/^(?:end\b)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:links\b)/i,/^(?:link\b)/i,/^(?:properties\b)/i,/^(?:details\b)/i,/^(?:over\b)/i,/^(?:note\b)/i,/^(?:activate\b)/i,/^(?:deactivate\b)/i,/^(?:title\s[^#\n;]+)/i,/^(?:title:\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:sequenceDiagram\b)/i,/^(?:autonumber\b)/i,/^(?:off\b)/i,/^(?:,)/i,/^(?:;)/i,/^(?:[^\+\<->\->:\n,;]+((?!(-x|--x|-\)|--\)))[\-]*[^\+\<->\->:\n,;]+)*)/i,/^(?:->>)/i,/^(?:<<->>)/i,/^(?:-->>)/i,/^(?:<<-->>)/i,/^(?:->)/i,/^(?:-->)/i,/^(?:-[x])/i,/^(?:--[x])/i,/^(?:-[\)])/i,/^(?:--[\)])/i,/^(?::(?:(?:no)?wrap)?[^#\n;]+)/i,/^(?:\+)/i,/^(?:-)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[45,46],inclusive:!1},acc_descr:{rules:[43],inclusive:!1},acc_title:{rules:[41],inclusive:!1},ID:{rules:[2,3,12],inclusive:!1},ALIAS:{rules:[2,3,13,14],inclusive:!1},LINE:{rules:[2,3,26],inclusive:!1},INITIAL:{rules:[0,1,3,4,5,6,7,8,9,10,11,15,16,17,18,19,20,21,22,23,24,25,27,28,29,30,31,32,33,34,35,36,37,38,39,40,42,44,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67],inclusive:!0}}}}();function G(){this.yy={}}return Y.lexer=U,(0,s.eW)(G,"Parser"),G.prototype=Y,Y.Parser=G,new G}();c.parser=c;var h=c,u={SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25,AUTONUMBER:26,CRITICAL_START:27,CRITICAL_OPTION:28,CRITICAL_END:29,BREAK_START:30,BREAK_END:31,PAR_OVER_START:32,BIDIRECTIONAL_SOLID:33,BIDIRECTIONAL_DOTTED:34},d={FILLED:0,OPEN:1},p={LEFTOF:0,RIGHTOF:1,OVER:2},g=class{constructor(){this.state=new i.A((()=>({prevActor:void 0,actors:new Map,createdActors:new Map,destroyedActors:new Map,boxes:[],messages:[],notes:[],sequenceNumbersEnabled:!1,wrapEnabled:void 0,currentBox:void 0,lastCreated:void 0,lastDestroyed:void 0}))),this.setAccTitle=s.GN,this.setAccDescription=s.U$,this.setDiagramTitle=s.g2,this.getAccTitle=s.eu,this.getAccDescription=s.Mx,this.getDiagramTitle=s.Kr,this.apply=this.apply.bind(this),this.parseBoxData=this.parseBoxData.bind(this),this.parseMessage=this.parseMessage.bind(this),this.clear(),this.setWrap((0,s.nV)().wrap),this.LINETYPE=u,this.ARROWTYPE=d,this.PLACEMENT=p}static{(0,s.eW)(this,"SequenceDB")}addBox(t){this.state.records.boxes.push({name:t.text,wrap:t.wrap??this.autoWrap(),fill:t.color,actorKeys:[]}),this.state.records.currentBox=this.state.records.boxes.slice(-1)[0]}addActor(t,e,n,r){let i=this.state.records.currentBox;const a=this.state.records.actors.get(t);if(a){if(this.state.records.currentBox&&a.box&&this.state.records.currentBox!==a.box)throw new Error(`A same participant should only be defined in one Box: ${a.name} can't be in '${a.box.name}' and in '${this.state.records.currentBox.name}' at the same time.`);if(i=a.box?a.box:this.state.records.currentBox,a.box=i,a&&e===a.name&&null==n)return}if(null==n?.text&&(n={text:e,type:r}),null!=r&&null!=n.text||(n={text:e,type:r}),this.state.records.actors.set(t,{box:i,name:e,description:n.text,wrap:n.wrap??this.autoWrap(),prevActor:this.state.records.prevActor,links:{},properties:{},actorCnt:null,rectData:null,type:r??"participant"}),this.state.records.prevActor){const e=this.state.records.actors.get(this.state.records.prevActor);e&&(e.nextActor=t)}this.state.records.currentBox&&this.state.records.currentBox.actorKeys.push(t),this.state.records.prevActor=t}activationCount(t){let e,n=0;if(!t)return 0;for(e=0;e>-",token:"->>-",line:"1",loc:{first_line:1,last_line:1,first_column:1,last_column:1},expected:["'ACTIVE_PARTICIPANT'"]},e}return this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:t,to:e,message:n?.text??"",wrap:n?.wrap??this.autoWrap(),type:r,activate:i}),!0}hasAtLeastOneBox(){return this.state.records.boxes.length>0}hasAtLeastOneBoxWithTitle(){return this.state.records.boxes.some((t=>t.name))}getMessages(){return this.state.records.messages}getBoxes(){return this.state.records.boxes}getActors(){return this.state.records.actors}getCreatedActors(){return this.state.records.createdActors}getDestroyedActors(){return this.state.records.destroyedActors}getActor(t){return this.state.records.actors.get(t)}getActorKeys(){return[...this.state.records.actors.keys()]}enableSequenceNumbers(){this.state.records.sequenceNumbersEnabled=!0}disableSequenceNumbers(){this.state.records.sequenceNumbersEnabled=!1}showSequenceNumbers(){return this.state.records.sequenceNumbersEnabled}setWrap(t){this.state.records.wrapEnabled=t}extractWrap(t){if(void 0===t)return{};t=t.trim();const e=null!==/^:?wrap:/.exec(t)||null===/^:?nowrap:/.exec(t)&&void 0;return{cleanedText:(void 0===e?t:t.replace(/^:?(?:no)?wrap:/,"")).trim(),wrap:e}}autoWrap(){return void 0!==this.state.records.wrapEnabled?this.state.records.wrapEnabled:(0,s.nV)().sequence?.wrap??!1}clear(){this.state.reset(),(0,s.ZH)()}parseMessage(t){const e=t.trim(),{wrap:n,cleanedText:r}=this.extractWrap(e),i={text:r,wrap:n};return s.cM.debug(`parseMessage: ${JSON.stringify(i)}`),i}parseBoxData(t){const e=/^((?:rgba?|hsla?)\s*\(.*\)|\w*)(.*)$/.exec(t);let n=e?.[1]?e[1].trim():"transparent",r=e?.[2]?e[2].trim():void 0;if(window?.CSS)window.CSS.supports("color",n)||(n="transparent",r=t.trim());else{const e=(new Option).style;e.color=n,e.color!==n&&(n="transparent",r=t.trim())}const{wrap:i,cleanedText:a}=this.extractWrap(r);return{text:a?(0,s.oO)(a,(0,s.nV)()):void 0,color:n,wrap:i}}addNote(t,e,n){const r={actor:t,placement:e,message:n.text,wrap:n.wrap??this.autoWrap()},i=[].concat(t,t);this.state.records.notes.push(r),this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:i[0],to:i[1],message:n.text,wrap:n.wrap??this.autoWrap(),type:this.LINETYPE.NOTE,placement:e})}addLinks(t,e){const n=this.getActor(t);try{let t=(0,s.oO)(e.text,(0,s.nV)());t=t.replace(/=/g,"="),t=t.replace(/&/g,"&");const r=JSON.parse(t);this.insertLinks(n,r)}catch(t){s.cM.error("error while parsing actor link text",t)}}addALink(t,e){const n=this.getActor(t);try{const t={};let r=(0,s.oO)(e.text,(0,s.nV)());const i=r.indexOf("@");r=r.replace(/=/g,"="),r=r.replace(/&/g,"&");const a=r.slice(0,i-1).trim(),o=r.slice(i+1).trim();t[a]=o,this.insertLinks(n,t)}catch(t){s.cM.error("error while parsing actor link text",t)}}insertLinks(t,e){if(null==t.links)t.links=e;else for(const n in e)t.links[n]=e[n]}addProperties(t,e){const n=this.getActor(t);try{const t=(0,s.oO)(e.text,(0,s.nV)()),r=JSON.parse(t);this.insertProperties(n,r)}catch(t){s.cM.error("error while parsing actor properties text",t)}}insertProperties(t,e){if(null==t.properties)t.properties=e;else for(const n in e)t.properties[n]=e[n]}boxEnd(){this.state.records.currentBox=void 0}addDetails(t,e){const n=this.getActor(t),r=document.getElementById(e.text);try{const t=r.innerHTML,e=JSON.parse(t);e.properties&&this.insertProperties(n,e.properties),e.links&&this.insertLinks(n,e.links)}catch(t){s.cM.error("error while parsing actor details text",t)}}getActorProperty(t,e){if(void 0!==t?.properties)return t.properties[e]}apply(t){if(Array.isArray(t))t.forEach((t=>{this.apply(t)}));else switch(t.type){case"sequenceIndex":this.state.records.messages.push({id:this.state.records.messages.length.toString(),from:void 0,to:void 0,message:{start:t.sequenceIndex,step:t.sequenceIndexStep,visible:t.sequenceVisible},wrap:!1,type:t.signalType});break;case"addParticipant":this.addActor(t.actor,t.actor,t.description,t.draw);break;case"createParticipant":if(this.state.records.actors.has(t.actor))throw new Error("It is not possible to have actors with the same id, even if one is destroyed before the next is created. Use 'AS' aliases to simulate the behavior");this.state.records.lastCreated=t.actor,this.addActor(t.actor,t.actor,t.description,t.draw),this.state.records.createdActors.set(t.actor,this.state.records.messages.length);break;case"destroyParticipant":this.state.records.lastDestroyed=t.actor,this.state.records.destroyedActors.set(t.actor,this.state.records.messages.length);break;case"activeStart":case"activeEnd":this.addSignal(t.actor,void 0,void 0,t.signalType);break;case"addNote":this.addNote(t.actor,t.placement,t.text);break;case"addLinks":this.addLinks(t.actor,t.text);break;case"addALink":this.addALink(t.actor,t.text);break;case"addProperties":this.addProperties(t.actor,t.text);break;case"addDetails":this.addDetails(t.actor,t.text);break;case"addMessage":if(this.state.records.lastCreated){if(t.to!==this.state.records.lastCreated)throw new Error("The created participant "+this.state.records.lastCreated.name+" does not have an associated creating message after its declaration. Please check the sequence diagram.");this.state.records.lastCreated=void 0}else if(this.state.records.lastDestroyed){if(t.to!==this.state.records.lastDestroyed&&t.from!==this.state.records.lastDestroyed)throw new Error("The destroyed participant "+this.state.records.lastDestroyed.name+" does not have an associated destroying message after its declaration. Please check the sequence diagram.");this.state.records.lastDestroyed=void 0}this.addSignal(t.from,t.to,t.msg,t.signalType,t.activate);break;case"boxStart":this.addBox(t.boxData);break;case"boxEnd":this.boxEnd();break;case"loopStart":this.addSignal(void 0,void 0,t.loopText,t.signalType);break;case"loopEnd":case"rectEnd":case"optEnd":case"altEnd":case"parEnd":case"criticalEnd":case"breakEnd":this.addSignal(void 0,void 0,void 0,t.signalType);break;case"rectStart":this.addSignal(void 0,void 0,t.color,t.signalType);break;case"optStart":this.addSignal(void 0,void 0,t.optText,t.signalType);break;case"altStart":case"else":this.addSignal(void 0,void 0,t.altText,t.signalType);break;case"setAccTitle":(0,s.GN)(t.text);break;case"parStart":case"and":this.addSignal(void 0,void 0,t.parText,t.signalType);break;case"criticalStart":this.addSignal(void 0,void 0,t.criticalText,t.signalType);break;case"option":this.addSignal(void 0,void 0,t.optionText,t.signalType);break;case"breakStart":this.addSignal(void 0,void 0,t.breakText,t.signalType)}}getConfig(){return(0,s.nV)().sequence}},f=(0,s.eW)((t=>`.actor {\n stroke: ${t.actorBorder};\n fill: ${t.actorBkg};\n }\n\n text.actor > tspan {\n fill: ${t.actorTextColor};\n stroke: none;\n }\n\n .actor-line {\n stroke: ${t.actorLineColor};\n }\n\n .messageLine0 {\n stroke-width: 1.5;\n stroke-dasharray: none;\n stroke: ${t.signalColor};\n }\n\n .messageLine1 {\n stroke-width: 1.5;\n stroke-dasharray: 2, 2;\n stroke: ${t.signalColor};\n }\n\n #arrowhead path {\n fill: ${t.signalColor};\n stroke: ${t.signalColor};\n }\n\n .sequenceNumber {\n fill: ${t.sequenceNumberColor};\n }\n\n #sequencenumber {\n fill: ${t.signalColor};\n }\n\n #crosshead path {\n fill: ${t.signalColor};\n stroke: ${t.signalColor};\n }\n\n .messageText {\n fill: ${t.signalTextColor};\n stroke: none;\n }\n\n .labelBox {\n stroke: ${t.labelBoxBorderColor};\n fill: ${t.labelBoxBkgColor};\n }\n\n .labelText, .labelText > tspan {\n fill: ${t.labelTextColor};\n stroke: none;\n }\n\n .loopText, .loopText > tspan {\n fill: ${t.loopTextColor};\n stroke: none;\n }\n\n .loopLine {\n stroke-width: 2px;\n stroke-dasharray: 2, 2;\n stroke: ${t.labelBoxBorderColor};\n fill: ${t.labelBoxBorderColor};\n }\n\n .note {\n //stroke: #decc93;\n stroke: ${t.noteBorderColor};\n fill: ${t.noteBkgColor};\n }\n\n .noteText, .noteText > tspan {\n fill: ${t.noteTextColor};\n stroke: none;\n }\n\n .activation0 {\n fill: ${t.activationBkgColor};\n stroke: ${t.activationBorderColor};\n }\n\n .activation1 {\n fill: ${t.activationBkgColor};\n stroke: ${t.activationBorderColor};\n }\n\n .activation2 {\n fill: ${t.activationBkgColor};\n stroke: ${t.activationBorderColor};\n }\n\n .actorPopupMenu {\n position: absolute;\n }\n\n .actorPopupMenuPanel {\n position: absolute;\n fill: ${t.actorBkg};\n box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);\n filter: drop-shadow(3px 5px 2px rgb(0 0 0 / 0.4));\n}\n .actor-man line {\n stroke: ${t.actorBorder};\n fill: ${t.actorBkg};\n }\n .actor-man circle, line {\n stroke: ${t.actorBorder};\n fill: ${t.actorBkg};\n stroke-width: 2px;\n }\n`),"getStyles"),m="actor-top",y="actor-bottom",v="actor-man",x=(0,s.eW)((function(t,e){return(0,r.Mu)(t,e)}),"drawRect"),b=(0,s.eW)((function(t,e,n,r,i){if(void 0===e.links||null===e.links||0===Object.keys(e.links).length)return{height:0,width:0};const a=e.links,s=e.actorCnt,o=e.rectData;var c="none";i&&(c="block !important");const h=t.append("g");h.attr("id","actor"+s+"_popup"),h.attr("class","actorPopupMenu"),h.attr("display",c);var u="";void 0!==o.class&&(u=" "+o.class);let d=o.width>n?o.width:n;const p=h.append("rect");if(p.attr("class","actorPopupMenuPanel"+u),p.attr("x",o.x),p.attr("y",o.height),p.attr("fill",o.fill),p.attr("stroke",o.stroke),p.attr("width",d),p.attr("height",o.height),p.attr("rx",o.rx),p.attr("ry",o.ry),null!=a){var g=20;for(let t in a){var f=h.append("a"),m=(0,l.N)(a[t]);f.attr("xlink:href",m),f.attr("target","_blank"),G(r)(t,f,o.x+10,o.height+g,d,20,{class:"actor"},r),g+=30}}return p.attr("height",g),{height:o.height+g,width:d}}),"drawPopup"),w=(0,s.eW)((function(t){return"var pu = document.getElementById('"+t+"'); if (pu != null) { pu.style.display = pu.style.display == 'block' ? 'none' : 'block'; }"}),"popupMenuToggle"),k=(0,s.eW)((async function(t,e,n=null){let r=t.append("foreignObject");const i=await(0,s.uT)(e.text,(0,s.iE)()),a=r.append("xhtml:div").attr("style","width: fit-content;").attr("xmlns","http://www.w3.org/1999/xhtml").html(i).node().getBoundingClientRect();if(r.attr("height",Math.round(a.height)).attr("width",Math.round(a.width)),"noteText"===e.class){const n=t.node().firstChild;n.setAttribute("height",a.height+2*e.textMargin);const i=n.getBBox();r.attr("x",Math.round(i.x+i.width/2-a.width/2)).attr("y",Math.round(i.y+i.height/2-a.height/2))}else if(n){let{startx:t,stopx:i,starty:s}=n;if(t>i){const e=t;t=i,i=e}r.attr("x",Math.round(t+Math.abs(t-i)/2-a.width/2)),"loopText"===e.class?r.attr("y",Math.round(s)):r.attr("y",Math.round(s-a.height))}return[r]}),"drawKatex"),T=(0,s.eW)((function(t,e){let n=0,r=0;const i=e.text.split(s.SY.lineBreakRegex),[o,l]=(0,a.VG)(e.fontSize);let c=[],h=0,u=(0,s.eW)((()=>e.y),"yfunc");if(void 0!==e.valign&&void 0!==e.textMargin&&e.textMargin>0)switch(e.valign){case"top":case"start":u=(0,s.eW)((()=>Math.round(e.y+e.textMargin)),"yfunc");break;case"middle":case"center":u=(0,s.eW)((()=>Math.round(e.y+(n+r+e.textMargin)/2)),"yfunc");break;case"bottom":case"end":u=(0,s.eW)((()=>Math.round(e.y+(n+r+2*e.textMargin)-e.textMargin)),"yfunc")}if(void 0!==e.anchor&&void 0!==e.textMargin&&void 0!==e.width)switch(e.anchor){case"left":case"start":e.x=Math.round(e.x+e.textMargin),e.anchor="start",e.dominantBaseline="middle",e.alignmentBaseline="middle";break;case"middle":case"center":e.x=Math.round(e.x+e.width/2),e.anchor="middle",e.dominantBaseline="middle",e.alignmentBaseline="middle";break;case"right":case"end":e.x=Math.round(e.x+e.width-e.textMargin),e.anchor="end",e.dominantBaseline="middle",e.alignmentBaseline="middle"}for(let[s,d]of i.entries()){void 0!==e.textMargin&&0===e.textMargin&&void 0!==o&&(h=s*o);const i=t.append("text");i.attr("x",e.x),i.attr("y",u()),void 0!==e.anchor&&i.attr("text-anchor",e.anchor).attr("dominant-baseline",e.dominantBaseline).attr("alignment-baseline",e.alignmentBaseline),void 0!==e.fontFamily&&i.style("font-family",e.fontFamily),void 0!==l&&i.style("font-size",l),void 0!==e.fontWeight&&i.style("font-weight",e.fontWeight),void 0!==e.fill&&i.attr("fill",e.fill),void 0!==e.class&&i.attr("class",e.class),void 0!==e.dy?i.attr("dy",e.dy):0!==h&&i.attr("dy",h);const p=d||a.$m;if(e.tspan){const t=i.append("tspan");t.attr("x",e.x),void 0!==e.fill&&t.attr("fill",e.fill),t.text(p)}else i.text(p);void 0!==e.valign&&void 0!==e.textMargin&&e.textMargin>0&&(r+=(i._groups||i)[0][0].getBBox().height,n=r),c.push(i)}return c}),"drawText"),_=(0,s.eW)((function(t,e){function n(t,e,n,r,i){return t+","+e+" "+(t+n)+","+e+" "+(t+n)+","+(e+r-i)+" "+(t+n-1.2*i)+","+(e+r)+" "+t+","+(e+r)}(0,s.eW)(n,"genPoints");const r=t.append("polygon");return r.attr("points",n(e.x,e.y,e.width,e.height,7)),r.attr("class","labelBox"),e.y=e.y+e.height/2,T(t,e),r}),"drawLabel"),E=-1,S=(0,s.eW)(((t,e,n,r)=>{t.select&&n.forEach((n=>{const i=e.get(n),a=t.select("#actor"+i.actorCnt);!r.mirrorActors&&i.stopy?a.attr("y2",i.stopy+i.height/2):r.mirrorActors&&a.attr("y2",i.stopy)}))}),"fixLifeLineHeights"),C=(0,s.eW)((function(t,e,n,i){const a=i?e.stopy:e.starty,o=e.x+e.width/2,l=a+e.height,c=t.append("g").lower();var h=c;i||(E++,Object.keys(e.links||{}).length&&!n.forceMenus&&h.attr("onclick",w(`actor${E}_popup`)).attr("cursor","pointer"),h.append("line").attr("id","actor"+E).attr("x1",o).attr("y1",l).attr("x2",o).attr("y2",2e3).attr("class","actor-line 200").attr("stroke-width","0.5px").attr("stroke","#999").attr("name",e.name),h=c.append("g"),e.actorCnt=E,null!=e.links&&h.attr("id","root-"+E));const u=(0,r.kc)();var d="actor";e.properties?.class?d=e.properties.class:u.fill="#eaeaea",d+=i?` ${y}`:` ${m}`,u.x=e.x,u.y=a,u.width=e.width,u.height=e.height,u.class=d,u.rx=3,u.ry=3,u.name=e.name;const p=x(h,u);if(e.rectData=u,e.properties?.icon){const t=e.properties.icon.trim();"@"===t.charAt(0)?(0,r.rB)(h,u.x+u.width-20,u.y+10,t.substr(1)):(0,r.AE)(h,u.x+u.width-20,u.y+10,t)}U(n,(0,s.l0)(e.description))(e.description,h,u.x,u.y,u.width,u.height,{class:"actor actor-box"},n);let g=e.height;if(p.node){const t=p.node().getBBox();e.height=t.height,g=t.height}return g}),"drawActorTypeParticipant"),A=(0,s.eW)((function(t,e,n,i){const a=i?e.stopy:e.starty,o=e.x+e.width/2,l=a+80,c=t.append("g").lower();i||(E++,c.append("line").attr("id","actor"+E).attr("x1",o).attr("y1",l).attr("x2",o).attr("y2",2e3).attr("class","actor-line 200").attr("stroke-width","0.5px").attr("stroke","#999").attr("name",e.name),e.actorCnt=E);const h=t.append("g");let u=v;u+=i?` ${y}`:` ${m}`,h.attr("class",u),h.attr("name",e.name);const d=(0,r.kc)();d.x=e.x,d.y=a,d.fill="#eaeaea",d.width=e.width,d.height=e.height,d.class="actor",d.rx=3,d.ry=3,h.append("line").attr("id","actor-man-torso"+E).attr("x1",o).attr("y1",a+25).attr("x2",o).attr("y2",a+45),h.append("line").attr("id","actor-man-arms"+E).attr("x1",o-18).attr("y1",a+33).attr("x2",o+18).attr("y2",a+33),h.append("line").attr("x1",o-18).attr("y1",a+60).attr("x2",o).attr("y2",a+45),h.append("line").attr("x1",o).attr("y1",a+45).attr("x2",o+18-2).attr("y2",a+60);const p=h.append("circle");p.attr("cx",e.x+e.width/2),p.attr("cy",a+10),p.attr("r",15),p.attr("width",e.width),p.attr("height",e.height);const g=h.node().getBBox();return e.height=g.height,U(n,(0,s.l0)(e.description))(e.description,h,d.x,d.y+35,d.width,d.height,{class:`actor ${v}`},n),e.height}),"drawActorTypeActor"),L=(0,s.eW)((async function(t,e,n,r){switch(e.type){case"actor":return await A(t,e,n,r);case"participant":return await C(t,e,n,r)}}),"drawActor"),M=(0,s.eW)((function(t,e,n){const r=t.append("g");D(r,e),e.name&&U(n)(e.name,r,e.x,e.y+(e.textMaxHeight||0)/2,e.width,0,{class:"text"},n),r.lower()}),"drawBox"),N=(0,s.eW)((function(t){return t.append("g")}),"anchorElement"),I=(0,s.eW)((function(t,e,n,i,a){const s=(0,r.kc)(),o=e.anchored;s.x=e.startx,s.y=e.starty,s.class="activation"+a%3,s.width=e.stopx-e.startx,s.height=n-e.starty,x(o,s)}),"drawActivation"),R=(0,s.eW)((async function(t,e,n,i){const{boxMargin:a,boxTextMargin:o,labelBoxHeight:l,labelBoxWidth:c,messageFontFamily:h,messageFontSize:u,messageFontWeight:d}=i,p=t.append("g"),g=(0,s.eW)((function(t,e,n,r){return p.append("line").attr("x1",t).attr("y1",e).attr("x2",n).attr("y2",r).attr("class","loopLine")}),"drawLoopLine");g(e.startx,e.starty,e.stopx,e.starty),g(e.stopx,e.starty,e.stopx,e.stopy),g(e.startx,e.stopy,e.stopx,e.stopy),g(e.startx,e.starty,e.startx,e.stopy),void 0!==e.sections&&e.sections.forEach((function(t){g(e.startx,t.y,e.stopx,t.y).style("stroke-dasharray","3, 3")}));let f=(0,r.AD)();f.text=n,f.x=e.startx,f.y=e.starty,f.fontFamily=h,f.fontSize=u,f.fontWeight=d,f.anchor="middle",f.valign="middle",f.tspan=!1,f.width=c||50,f.height=l||20,f.textMargin=o,f.class="labelText",_(p,f),f=Z(),f.text=e.title,f.x=e.startx+c/2+(e.stopx-e.startx)/2,f.y=e.starty+a+o,f.anchor="middle",f.valign="middle",f.textMargin=o,f.class="loopText",f.fontFamily=h,f.fontSize=u,f.fontWeight=d,f.wrap=!0;let m=(0,s.l0)(f.text)?await k(p,f,e):T(p,f);if(void 0!==e.sectionTitles)for(const[t,n]of Object.entries(e.sectionTitles))if(n.message){f.text=n.message,f.x=e.startx+(e.stopx-e.startx)/2,f.y=e.sections[t].y+a+o,f.class="loopText",f.anchor="middle",f.valign="middle",f.tspan=!1,f.fontFamily=h,f.fontSize=u,f.fontWeight=d,f.wrap=e.wrap,(0,s.l0)(f.text)?(e.starty=e.sections[t].y,await k(p,f,e)):T(p,f);let r=Math.round(m.map((t=>(t._groups||t)[0][0].getBBox().height)).reduce(((t,e)=>t+e)));e.sections[t].height+=r-(a+o)}return e.height=Math.round(e.stopy-e.starty),p}),"drawLoop"),D=(0,s.eW)((function(t,e){(0,r.O)(t,e)}),"drawBackgroundRect"),O=(0,s.eW)((function(t){t.append("defs").append("symbol").attr("id","database").attr("fill-rule","evenodd").attr("clip-rule","evenodd").append("path").attr("transform","scale(.5)").attr("d","M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z")}),"insertDatabaseIcon"),P=(0,s.eW)((function(t){t.append("defs").append("symbol").attr("id","computer").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z")}),"insertComputerIcon"),$=(0,s.eW)((function(t){t.append("defs").append("symbol").attr("id","clock").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z")}),"insertClockIcon"),B=(0,s.eW)((function(t){t.append("defs").append("marker").attr("id","arrowhead").attr("refX",7.9).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto-start-reverse").append("path").attr("d","M -1 0 L 10 5 L 0 10 z")}),"insertArrowHead"),F=(0,s.eW)((function(t){t.append("defs").append("marker").attr("id","filled-head").attr("refX",15.5).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")}),"insertArrowFilledHead"),W=(0,s.eW)((function(t){t.append("defs").append("marker").attr("id","sequencenumber").attr("refX",15).attr("refY",15).attr("markerWidth",60).attr("markerHeight",40).attr("orient","auto").append("circle").attr("cx",15).attr("cy",15).attr("r",6)}),"insertSequenceNumber"),z=(0,s.eW)((function(t){t.append("defs").append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",4).attr("refY",4.5).append("path").attr("fill","none").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1pt").attr("d","M 1,2 L 6,7 M 6,2 L 1,7")}),"insertArrowCrossHead"),Z=(0,s.eW)((function(){return{x:0,y:0,fill:void 0,anchor:void 0,style:"#666",width:void 0,height:void 0,textMargin:0,rx:0,ry:0,tspan:!0,valign:void 0}}),"getTextObj"),Y=(0,s.eW)((function(){return{x:0,y:0,fill:"#EDF2AE",stroke:"#666",width:100,anchor:"start",height:100,rx:0,ry:0}}),"getNoteRect"),U=function(){function t(t,e,n,r,a,s,o){i(e.append("text").attr("x",n+a/2).attr("y",r+s/2+5).style("text-anchor","middle").text(t),o)}function e(t,e,n,r,o,l,c,h){const{actorFontSize:u,actorFontFamily:d,actorFontWeight:p}=h,[g,f]=(0,a.VG)(u),m=t.split(s.SY.lineBreakRegex);for(let t=0;tt.height||0)))+(0===this.loops.length?0:this.loops.map((t=>t.height||0)).reduce(((t,e)=>t+e)))+(0===this.messages.length?0:this.messages.map((t=>t.height||0)).reduce(((t,e)=>t+e)))+(0===this.notes.length?0:this.notes.map((t=>t.height||0)).reduce(((t,e)=>t+e)))}),"getHeight"),clear:(0,s.eW)((function(){this.actors=[],this.boxes=[],this.loops=[],this.messages=[],this.notes=[]}),"clear"),addBox:(0,s.eW)((function(t){this.boxes.push(t)}),"addBox"),addActor:(0,s.eW)((function(t){this.actors.push(t)}),"addActor"),addLoop:(0,s.eW)((function(t){this.loops.push(t)}),"addLoop"),addMessage:(0,s.eW)((function(t){this.messages.push(t)}),"addMessage"),addNote:(0,s.eW)((function(t){this.notes.push(t)}),"addNote"),lastActor:(0,s.eW)((function(){return this.actors[this.actors.length-1]}),"lastActor"),lastLoop:(0,s.eW)((function(){return this.loops[this.loops.length-1]}),"lastLoop"),lastMessage:(0,s.eW)((function(){return this.messages[this.messages.length-1]}),"lastMessage"),lastNote:(0,s.eW)((function(){return this.notes[this.notes.length-1]}),"lastNote"),actors:[],boxes:[],loops:[],messages:[],notes:[]},init:(0,s.eW)((function(){this.sequenceItems=[],this.activations=[],this.models.clear(),this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0},this.verticalPos=0,it((0,s.nV)())}),"init"),updateVal:(0,s.eW)((function(t,e,n,r){void 0===t[e]?t[e]=n:t[e]=r(n,t[e])}),"updateVal"),updateBounds:(0,s.eW)((function(t,e,n,r){const i=this;let a=0;function o(o){return(0,s.eW)((function(s){a++;const l=i.sequenceItems.length-a+1;i.updateVal(s,"starty",e-l*q.boxMargin,Math.min),i.updateVal(s,"stopy",r+l*q.boxMargin,Math.max),i.updateVal(j.data,"startx",t-l*q.boxMargin,Math.min),i.updateVal(j.data,"stopx",n+l*q.boxMargin,Math.max),"activation"!==o&&(i.updateVal(s,"startx",t-l*q.boxMargin,Math.min),i.updateVal(s,"stopx",n+l*q.boxMargin,Math.max),i.updateVal(j.data,"starty",e-l*q.boxMargin,Math.min),i.updateVal(j.data,"stopy",r+l*q.boxMargin,Math.max))}),"updateItemBounds")}(0,s.eW)(o,"updateFn"),this.sequenceItems.forEach(o()),this.activations.forEach(o("activation"))}),"updateBounds"),insert:(0,s.eW)((function(t,e,n,r){const i=s.SY.getMin(t,n),a=s.SY.getMax(t,n),o=s.SY.getMin(e,r),l=s.SY.getMax(e,r);this.updateVal(j.data,"startx",i,Math.min),this.updateVal(j.data,"starty",o,Math.min),this.updateVal(j.data,"stopx",a,Math.max),this.updateVal(j.data,"stopy",l,Math.max),this.updateBounds(i,o,a,l)}),"insert"),newActivation:(0,s.eW)((function(t,e,n){const r=n.get(t.from),i=at(t.from).length||0,a=r.x+r.width/2+(i-1)*q.activationWidth/2;this.activations.push({startx:a,starty:this.verticalPos+2,stopx:a+q.activationWidth,stopy:void 0,actor:t.from,anchored:V.anchorElement(e)})}),"newActivation"),endActivation:(0,s.eW)((function(t){const e=this.activations.map((function(t){return t.actor})).lastIndexOf(t.from);return this.activations.splice(e,1)[0]}),"endActivation"),createLoop:(0,s.eW)((function(t={message:void 0,wrap:!1,width:void 0},e){return{startx:void 0,starty:this.verticalPos,stopx:void 0,stopy:void 0,title:t.message,wrap:t.wrap,width:t.width,height:0,fill:e}}),"createLoop"),newLoop:(0,s.eW)((function(t={message:void 0,wrap:!1,width:void 0},e){this.sequenceItems.push(this.createLoop(t,e))}),"newLoop"),endLoop:(0,s.eW)((function(){return this.sequenceItems.pop()}),"endLoop"),isLoopOverlap:(0,s.eW)((function(){return!!this.sequenceItems.length&&this.sequenceItems[this.sequenceItems.length-1].overlap}),"isLoopOverlap"),addSectionToLoop:(0,s.eW)((function(t){const e=this.sequenceItems.pop();e.sections=e.sections||[],e.sectionTitles=e.sectionTitles||[],e.sections.push({y:j.getVerticalPos(),height:0}),e.sectionTitles.push(t),this.sequenceItems.push(e)}),"addSectionToLoop"),saveVerticalPos:(0,s.eW)((function(){this.isLoopOverlap()&&(this.savedVerticalPos=this.verticalPos)}),"saveVerticalPos"),resetVerticalPos:(0,s.eW)((function(){this.isLoopOverlap()&&(this.verticalPos=this.savedVerticalPos)}),"resetVerticalPos"),bumpVerticalPos:(0,s.eW)((function(t){this.verticalPos=this.verticalPos+t,this.data.stopy=s.SY.getMax(this.data.stopy,this.verticalPos)}),"bumpVerticalPos"),getVerticalPos:(0,s.eW)((function(){return this.verticalPos}),"getVerticalPos"),getBounds:(0,s.eW)((function(){return{bounds:this.data,models:this.models}}),"getBounds")},H=(0,s.eW)((async function(t,e){j.bumpVerticalPos(q.boxMargin),e.height=q.boxMargin,e.starty=j.getVerticalPos();const n=(0,r.kc)();n.x=e.startx,n.y=e.starty,n.width=e.width||q.width,n.class="note";const i=t.append("g"),a=V.drawRect(i,n),o=(0,r.AD)();o.x=e.startx,o.y=e.starty,o.width=n.width,o.dy="1em",o.text=e.message,o.class="noteText",o.fontFamily=q.noteFontFamily,o.fontSize=q.noteFontSize,o.fontWeight=q.noteFontWeight,o.anchor=q.noteAlign,o.textMargin=q.noteMargin,o.valign="center";const l=(0,s.l0)(o.text)?await k(i,o):T(i,o),c=Math.round(l.map((t=>(t._groups||t)[0][0].getBBox().height)).reduce(((t,e)=>t+e)));a.attr("height",c+2*q.noteMargin),e.height+=c+2*q.noteMargin,j.bumpVerticalPos(c+2*q.noteMargin),e.stopy=e.starty+c+2*q.noteMargin,e.stopx=e.startx+n.width,j.insert(e.startx,e.starty,e.stopx,e.stopy),j.models.addNote(e)}),"drawNote"),X=(0,s.eW)((t=>({fontFamily:t.messageFontFamily,fontSize:t.messageFontSize,fontWeight:t.messageFontWeight})),"messageFont"),K=(0,s.eW)((t=>({fontFamily:t.noteFontFamily,fontSize:t.noteFontSize,fontWeight:t.noteFontWeight})),"noteFont"),Q=(0,s.eW)((t=>({fontFamily:t.actorFontFamily,fontSize:t.actorFontSize,fontWeight:t.actorFontWeight})),"actorFont");async function J(t,e){j.bumpVerticalPos(10);const{startx:n,stopx:r,message:i}=e,o=s.SY.splitBreaks(i).length,l=(0,s.l0)(i),c=l?await(0,s.nH)(i,(0,s.nV)()):a.w8.calculateTextDimensions(i,X(q));if(!l){const t=c.height/o;e.height+=t,j.bumpVerticalPos(t)}let h,u=c.height-10;const d=c.width;if(n===r){h=j.getVerticalPos()+u,q.rightAngles||(u+=q.boxMargin,h=j.getVerticalPos()+u),u+=30;const t=s.SY.getMax(d/2,q.width/2);j.insert(n-t,j.getVerticalPos()-10+u,r+t,j.getVerticalPos()+30+u)}else u+=q.boxMargin,h=j.getVerticalPos()+u,j.insert(n,h-10,r,h);return j.bumpVerticalPos(u),e.height+=u,e.stopy=e.starty+e.height,j.insert(e.fromBounds,e.starty,e.toBounds,e.stopy),h}(0,s.eW)(J,"boundMessage");var tt=(0,s.eW)((async function(t,e,n,i){const{startx:o,stopx:l,starty:c,message:h,type:u,sequenceIndex:d,sequenceVisible:p}=e,g=a.w8.calculateTextDimensions(h,X(q)),f=(0,r.AD)();f.x=o,f.y=c+10,f.width=l-o,f.class="messageText",f.dy="1em",f.text=h,f.fontFamily=q.messageFontFamily,f.fontSize=q.messageFontSize,f.fontWeight=q.messageFontWeight,f.anchor=q.messageAlign,f.valign="center",f.textMargin=q.wrapPadding,f.tspan=!1,(0,s.l0)(f.text)?await k(t,f,{startx:o,stopx:l,starty:n}):T(t,f);const m=g.width;let y;o===l?y=q.rightAngles?t.append("path").attr("d",`M ${o},${n} H ${o+s.SY.getMax(q.width/2,m/2)} V ${n+25} H ${o}`):t.append("path").attr("d","M "+o+","+n+" C "+(o+60)+","+(n-10)+" "+(o+60)+","+(n+30)+" "+o+","+(n+20)):(y=t.append("line"),y.attr("x1",o),y.attr("y1",n),y.attr("x2",l),y.attr("y2",n)),u===i.db.LINETYPE.DOTTED||u===i.db.LINETYPE.DOTTED_CROSS||u===i.db.LINETYPE.DOTTED_POINT||u===i.db.LINETYPE.DOTTED_OPEN||u===i.db.LINETYPE.BIDIRECTIONAL_DOTTED?(y.style("stroke-dasharray","3, 3"),y.attr("class","messageLine1")):y.attr("class","messageLine0");let v="";q.arrowMarkerAbsolute&&(v=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,v=v.replace(/\(/g,"\\("),v=v.replace(/\)/g,"\\)")),y.attr("stroke-width",2),y.attr("stroke","none"),y.style("fill","none"),u!==i.db.LINETYPE.SOLID&&u!==i.db.LINETYPE.DOTTED||y.attr("marker-end","url("+v+"#arrowhead)"),u!==i.db.LINETYPE.BIDIRECTIONAL_SOLID&&u!==i.db.LINETYPE.BIDIRECTIONAL_DOTTED||(y.attr("marker-start","url("+v+"#arrowhead)"),y.attr("marker-end","url("+v+"#arrowhead)")),u!==i.db.LINETYPE.SOLID_POINT&&u!==i.db.LINETYPE.DOTTED_POINT||y.attr("marker-end","url("+v+"#filled-head)"),u!==i.db.LINETYPE.SOLID_CROSS&&u!==i.db.LINETYPE.DOTTED_CROSS||y.attr("marker-end","url("+v+"#crosshead)"),(p||q.showSequenceNumbers)&&(y.attr("marker-start","url("+v+"#sequencenumber)"),t.append("text").attr("x",o).attr("y",n+4).attr("font-family","sans-serif").attr("font-size","12px").attr("text-anchor","middle").attr("class","sequenceNumber").text(d))}),"drawMessage"),et=(0,s.eW)((function(t,e,n,r,i,a,o){let l,c=0,h=0,u=0;for(const t of r){const r=e.get(t),a=r.box;l&&l!=a&&(o||j.models.addBox(l),h+=q.boxMargin+l.margin),a&&a!=l&&(o||(a.x=c+h,a.y=i),h+=a.margin),r.width=r.width||q.width,r.height=s.SY.getMax(r.height||q.height,q.height),r.margin=r.margin||q.actorMargin,u=s.SY.getMax(u,r.height),n.get(r.name)&&(h+=r.width/2),r.x=c+h,r.starty=j.getVerticalPos(),j.insert(r.x,i,r.x+r.width,r.height),c+=r.width+h,r.box&&(r.box.width=c+a.margin-r.box.x),h=r.margin,l=r.box,j.models.addActor(r)}l&&!o&&j.models.addBox(l),j.bumpVerticalPos(u)}),"addActorRenderingData"),nt=(0,s.eW)((async function(t,e,n,r){if(r){let r=0;j.bumpVerticalPos(2*q.boxMargin);for(const i of n){const n=e.get(i);n.stopy||(n.stopy=j.getVerticalPos());const a=await V.drawActor(t,n,q,!0);r=s.SY.getMax(r,a)}j.bumpVerticalPos(r+q.boxMargin)}else for(const r of n){const n=e.get(r);await V.drawActor(t,n,q,!1)}}),"drawActors"),rt=(0,s.eW)((function(t,e,n,r){let i=0,a=0;for(const s of n){const n=e.get(s),o=ut(n),l=V.drawPopup(t,n,o,q,q.forceMenus,r);l.height>i&&(i=l.height),l.width+n.x>a&&(a=l.width+n.x)}return{maxHeight:i,maxWidth:a}}),"drawActorsPopup"),it=(0,s.eW)((function(t){(0,s.Yc)(q,t),t.fontFamily&&(q.actorFontFamily=q.noteFontFamily=q.messageFontFamily=t.fontFamily),t.fontSize&&(q.actorFontSize=q.noteFontSize=q.messageFontSize=t.fontSize),t.fontWeight&&(q.actorFontWeight=q.noteFontWeight=q.messageFontWeight=t.fontWeight)}),"setConf"),at=(0,s.eW)((function(t){return j.activations.filter((function(e){return e.actor===t}))}),"actorActivations"),st=(0,s.eW)((function(t,e){const n=e.get(t),r=at(t);return[r.reduce((function(t,e){return s.SY.getMin(t,e.startx)}),n.x+n.width/2-1),r.reduce((function(t,e){return s.SY.getMax(t,e.stopx)}),n.x+n.width/2+1)]}),"activationBounds");function ot(t,e,n,r,i){j.bumpVerticalPos(n);let o=r;if(e.id&&e.message&&t[e.id]){const n=t[e.id].width,i=X(q);e.message=a.w8.wrapLabel(`[${e.message}]`,n-2*q.wrapPadding,i),e.width=n,e.wrap=!0;const l=a.w8.calculateTextDimensions(e.message,i),c=s.SY.getMax(l.height,q.labelBoxHeight);o=r+c,s.cM.debug(`${c} - ${e.message}`)}i(e),j.bumpVerticalPos(o)}function lt(t,e,n,r,i,a,o){function l(n,r){n.x{t.add(e.from),t.add(e.to)})),m=m.filter((e=>t.has(e)))}et(u,d,p,m,0,y,!1);const k=await ft(y,d,w,r);function T(t,e){const n=j.endActivation(t);n.starty+18>e&&(n.starty=e-6,e+=12),V.drawActivation(u,n,e,q,at(t.from).length),j.insert(n.startx,e-10,n.stopx,e)}V.insertArrowHead(u),V.insertArrowCrossHead(u),V.insertArrowFilledHead(u),V.insertSequenceNumber(u),(0,s.eW)(T,"activeEnd");let _=1,E=1;const C=[],A=[];let L=0;for(const t of y){let e,n,i;switch(t.type){case r.db.LINETYPE.NOTE:j.resetVerticalPos(),n=t.noteModel,await H(u,n);break;case r.db.LINETYPE.ACTIVE_START:j.newActivation(t,u,d);break;case r.db.LINETYPE.ACTIVE_END:T(t,j.getVerticalPos());break;case r.db.LINETYPE.LOOP_START:ot(k,t,q.boxMargin,q.boxMargin+q.boxTextMargin,(t=>j.newLoop(t)));break;case r.db.LINETYPE.LOOP_END:e=j.endLoop(),await V.drawLoop(u,e,"loop",q),j.bumpVerticalPos(e.stopy-j.getVerticalPos()),j.models.addLoop(e);break;case r.db.LINETYPE.RECT_START:ot(k,t,q.boxMargin,q.boxMargin,(t=>j.newLoop(void 0,t.message)));break;case r.db.LINETYPE.RECT_END:e=j.endLoop(),A.push(e),j.models.addLoop(e),j.bumpVerticalPos(e.stopy-j.getVerticalPos());break;case r.db.LINETYPE.OPT_START:ot(k,t,q.boxMargin,q.boxMargin+q.boxTextMargin,(t=>j.newLoop(t)));break;case r.db.LINETYPE.OPT_END:e=j.endLoop(),await V.drawLoop(u,e,"opt",q),j.bumpVerticalPos(e.stopy-j.getVerticalPos()),j.models.addLoop(e);break;case r.db.LINETYPE.ALT_START:ot(k,t,q.boxMargin,q.boxMargin+q.boxTextMargin,(t=>j.newLoop(t)));break;case r.db.LINETYPE.ALT_ELSE:ot(k,t,q.boxMargin+q.boxTextMargin,q.boxMargin,(t=>j.addSectionToLoop(t)));break;case r.db.LINETYPE.ALT_END:e=j.endLoop(),await V.drawLoop(u,e,"alt",q),j.bumpVerticalPos(e.stopy-j.getVerticalPos()),j.models.addLoop(e);break;case r.db.LINETYPE.PAR_START:case r.db.LINETYPE.PAR_OVER_START:ot(k,t,q.boxMargin,q.boxMargin+q.boxTextMargin,(t=>j.newLoop(t))),j.saveVerticalPos();break;case r.db.LINETYPE.PAR_AND:ot(k,t,q.boxMargin+q.boxTextMargin,q.boxMargin,(t=>j.addSectionToLoop(t)));break;case r.db.LINETYPE.PAR_END:e=j.endLoop(),await V.drawLoop(u,e,"par",q),j.bumpVerticalPos(e.stopy-j.getVerticalPos()),j.models.addLoop(e);break;case r.db.LINETYPE.AUTONUMBER:_=t.message.start||_,E=t.message.step||E,t.message.visible?r.db.enableSequenceNumbers():r.db.disableSequenceNumbers();break;case r.db.LINETYPE.CRITICAL_START:ot(k,t,q.boxMargin,q.boxMargin+q.boxTextMargin,(t=>j.newLoop(t)));break;case r.db.LINETYPE.CRITICAL_OPTION:ot(k,t,q.boxMargin+q.boxTextMargin,q.boxMargin,(t=>j.addSectionToLoop(t)));break;case r.db.LINETYPE.CRITICAL_END:e=j.endLoop(),await V.drawLoop(u,e,"critical",q),j.bumpVerticalPos(e.stopy-j.getVerticalPos()),j.models.addLoop(e);break;case r.db.LINETYPE.BREAK_START:ot(k,t,q.boxMargin,q.boxMargin+q.boxTextMargin,(t=>j.newLoop(t)));break;case r.db.LINETYPE.BREAK_END:e=j.endLoop(),await V.drawLoop(u,e,"break",q),j.bumpVerticalPos(e.stopy-j.getVerticalPos()),j.models.addLoop(e);break;default:try{i=t.msgModel,i.starty=j.getVerticalPos(),i.sequenceIndex=_,i.sequenceVisible=r.db.showSequenceNumbers();const e=await J(0,i);lt(t,i,e,L,d,p,g),C.push({messageModel:i,lineStartY:e}),j.models.addMessage(i)}catch(t){s.cM.error("error while drawing message",t)}}[r.db.LINETYPE.SOLID_OPEN,r.db.LINETYPE.DOTTED_OPEN,r.db.LINETYPE.SOLID,r.db.LINETYPE.DOTTED,r.db.LINETYPE.SOLID_CROSS,r.db.LINETYPE.DOTTED_CROSS,r.db.LINETYPE.SOLID_POINT,r.db.LINETYPE.DOTTED_POINT,r.db.LINETYPE.BIDIRECTIONAL_SOLID,r.db.LINETYPE.BIDIRECTIONAL_DOTTED].includes(t.type)&&(_+=E),L++}s.cM.debug("createdActors",p),s.cM.debug("destroyedActors",g),await nt(u,d,m,!1);for(const t of C)await tt(u,t.messageModel,t.lineStartY,r);q.mirrorActors&&await nt(u,d,m,!0),A.forEach((t=>V.drawBackgroundRect(u,t))),S(u,d,m,q);for(const t of j.models.boxes)t.height=j.getVerticalPos()-t.y,j.insert(t.x,t.y,t.x+t.width,t.height),t.startx=t.x,t.starty=t.y,t.stopx=t.startx+t.width,t.stopy=t.starty+t.height,t.stroke="rgb(0,0,0, 0.5)",V.drawBox(u,t,q);x&&j.bumpVerticalPos(q.boxMargin);const M=rt(u,d,m,h),{bounds:N}=j.getBounds();void 0===N.startx&&(N.startx=0),void 0===N.starty&&(N.starty=0),void 0===N.stopx&&(N.stopx=0),void 0===N.stopy&&(N.stopy=0);let I=N.stopy-N.starty;I{const n=X(q);let r=e.actorKeys.reduce(((e,n)=>e+(t.get(n).width+(t.get(n).margin||0))),0);r-=2*q.boxTextMargin,e.wrap&&(e.name=a.w8.wrapLabel(e.name,r-2*q.wrapPadding,n));const o=a.w8.calculateTextDimensions(e.name,n);i=s.SY.getMax(o.height,i);const l=s.SY.getMax(r,o.width+2*q.wrapPadding);if(e.margin=q.boxTextMargin,rt.textMaxHeight=i)),s.SY.getMax(r,q.height)}(0,s.eW)(dt,"calculateActorMargins");var pt=(0,s.eW)((async function(t,e,n){const r=e.get(t.from),i=e.get(t.to),o=r.x,l=i.x,c=t.wrap&&t.message;let h=(0,s.l0)(t.message)?await(0,s.nH)(t.message,(0,s.nV)()):a.w8.calculateTextDimensions(c?a.w8.wrapLabel(t.message,q.width,K(q)):t.message,K(q));const u={width:c?q.width:s.SY.getMax(q.width,h.width+2*q.noteMargin),height:0,startx:r.x,stopx:0,starty:0,stopy:0,message:t.message};return t.placement===n.db.PLACEMENT.RIGHTOF?(u.width=c?s.SY.getMax(q.width,h.width):s.SY.getMax(r.width/2+i.width/2,h.width+2*q.noteMargin),u.startx=o+(r.width+q.actorMargin)/2):t.placement===n.db.PLACEMENT.LEFTOF?(u.width=c?s.SY.getMax(q.width,h.width+2*q.noteMargin):s.SY.getMax(r.width/2+i.width/2,h.width+2*q.noteMargin),u.startx=o-u.width+(r.width-q.actorMargin)/2):t.to===t.from?(h=a.w8.calculateTextDimensions(c?a.w8.wrapLabel(t.message,s.SY.getMax(q.width,r.width),K(q)):t.message,K(q)),u.width=c?s.SY.getMax(q.width,r.width):s.SY.getMax(r.width,q.width,h.width+2*q.noteMargin),u.startx=o+(r.width-u.width)/2):(u.width=Math.abs(o+r.width/2-(l+i.width/2))+q.actorMargin,u.startx=o2,p=(0,s.eW)((t=>c?-t:t),"adjustValue");t.from===t.to?u=h:(t.activate&&!d&&(u+=p(q.activationWidth/2-1)),[n.db.LINETYPE.SOLID_OPEN,n.db.LINETYPE.DOTTED_OPEN].includes(t.type)||(u+=p(3)),[n.db.LINETYPE.BIDIRECTIONAL_SOLID,n.db.LINETYPE.BIDIRECTIONAL_DOTTED].includes(t.type)&&(h-=p(3)));const g=[r,i,o,l],f=Math.abs(h-u);t.wrap&&t.message&&(t.message=a.w8.wrapLabel(t.message,s.SY.getMax(f+2*q.wrapPadding,q.width),X(q)));const m=a.w8.calculateTextDimensions(t.message,X(q));return{width:s.SY.getMax(t.wrap?0:m.width+2*q.wrapPadding,f+2*q.wrapPadding,q.width),height:0,startx:h,stopx:u,starty:0,stopy:0,message:t.message,type:t.type,wrap:t.wrap,fromBounds:Math.min.apply(null,g),toBounds:Math.max.apply(null,g)}}),"buildMessageModel"),ft=(0,s.eW)((async function(t,e,n,r){const i={},a=[];let o,l,c;for(const n of t){switch(n.type){case r.db.LINETYPE.LOOP_START:case r.db.LINETYPE.ALT_START:case r.db.LINETYPE.OPT_START:case r.db.LINETYPE.PAR_START:case r.db.LINETYPE.PAR_OVER_START:case r.db.LINETYPE.CRITICAL_START:case r.db.LINETYPE.BREAK_START:a.push({id:n.id,msg:n.message,from:Number.MAX_SAFE_INTEGER,to:Number.MIN_SAFE_INTEGER,width:0});break;case r.db.LINETYPE.ALT_ELSE:case r.db.LINETYPE.PAR_AND:case r.db.LINETYPE.CRITICAL_OPTION:n.message&&(o=a.pop(),i[o.id]=o,i[n.id]=o,a.push(o));break;case r.db.LINETYPE.LOOP_END:case r.db.LINETYPE.ALT_END:case r.db.LINETYPE.OPT_END:case r.db.LINETYPE.PAR_END:case r.db.LINETYPE.CRITICAL_END:case r.db.LINETYPE.BREAK_END:o=a.pop(),i[o.id]=o;break;case r.db.LINETYPE.ACTIVE_START:{const t=e.get(n.from?n.from:n.to.actor),r=at(n.from?n.from:n.to.actor).length,i=t.x+t.width/2+(r-1)*q.activationWidth/2,a={startx:i,stopx:i+q.activationWidth,actor:n.from,enabled:!0};j.activations.push(a)}break;case r.db.LINETYPE.ACTIVE_END:{const t=j.activations.map((t=>t.actor)).lastIndexOf(n.from);j.activations.splice(t,1).splice(0,1)}}void 0!==n.placement?(l=await pt(n,e,r),n.noteModel=l,a.forEach((t=>{o=t,o.from=s.SY.getMin(o.from,l.startx),o.to=s.SY.getMax(o.to,l.startx+l.width),o.width=s.SY.getMax(o.width,Math.abs(o.from-o.to))-q.labelBoxWidth}))):(c=gt(n,e,r),n.msgModel=c,c.startx&&c.stopx&&a.length>0&&a.forEach((t=>{if(o=t,c.startx===c.stopx){const t=e.get(n.from),r=e.get(n.to);o.from=s.SY.getMin(t.x-c.width/2,t.x-t.width/2,o.from),o.to=s.SY.getMax(r.x+c.width/2,r.x+t.width/2,o.to),o.width=s.SY.getMax(o.width,Math.abs(o.to-o.from))-q.labelBoxWidth}else o.from=s.SY.getMin(c.startx,o.from),o.to=s.SY.getMax(c.stopx,o.to),o.width=s.SY.getMax(o.width,c.width)-q.labelBoxWidth})))}return j.activations=[],s.cM.debug("Loop type widths:",i),i}),"calculateLoopBounds"),mt={parser:h,get db(){return new g},renderer:{bounds:j,drawActors:nt,drawActorsPopup:rt,setConf:it,draw:ct},styles:f,init:(0,s.eW)((t=>{t.sequence||(t.sequence={}),t.wrap&&(t.sequence.wrap=t.wrap,(0,s.Y4)({sequence:{wrap:t.wrap}}))}),"init")}},952:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>O});var r,i=n(9836),a=(n(907),n(8337),n(1566),n(5179),n(3583),n(1426),n(6241),n(214),n(7946)),s=n(4082),o=n(3108),l=n(4840),c=n(5625),h={},u=(0,s.eW)(((t,e)=>{h[t]=e}),"set"),d=(0,s.eW)((t=>h[t]),"get"),p=(0,s.eW)((()=>Object.keys(h)),"keys"),g=(0,s.eW)((()=>p().length),"size"),f={get:d,set:u,keys:p,size:g},m=(0,s.eW)((t=>t.append("circle").attr("class","start-state").attr("r",(0,s.nV)().state.sizeUnit).attr("cx",(0,s.nV)().state.padding+(0,s.nV)().state.sizeUnit).attr("cy",(0,s.nV)().state.padding+(0,s.nV)().state.sizeUnit)),"drawStartState"),y=(0,s.eW)((t=>t.append("line").style("stroke","grey").style("stroke-dasharray","3").attr("x1",(0,s.nV)().state.textHeight).attr("class","divider").attr("x2",2*(0,s.nV)().state.textHeight).attr("y1",0).attr("y2",0)),"drawDivider"),v=(0,s.eW)(((t,e)=>{const n=t.append("text").attr("x",2*(0,s.nV)().state.padding).attr("y",(0,s.nV)().state.textHeight+2*(0,s.nV)().state.padding).attr("font-size",(0,s.nV)().state.fontSize).attr("class","state-title").text(e.id),r=n.node().getBBox();return t.insert("rect",":first-child").attr("x",(0,s.nV)().state.padding).attr("y",(0,s.nV)().state.padding).attr("width",r.width+2*(0,s.nV)().state.padding).attr("height",r.height+2*(0,s.nV)().state.padding).attr("rx",(0,s.nV)().state.radius),n}),"drawSimpleState"),x=(0,s.eW)(((t,e)=>{const n=(0,s.eW)((function(t,e,n){const r=t.append("tspan").attr("x",2*(0,s.nV)().state.padding).text(e);n||r.attr("dy",(0,s.nV)().state.textHeight)}),"addTspan"),r=t.append("text").attr("x",2*(0,s.nV)().state.padding).attr("y",(0,s.nV)().state.textHeight+1.3*(0,s.nV)().state.padding).attr("font-size",(0,s.nV)().state.fontSize).attr("class","state-title").text(e.descriptions[0]).node().getBBox(),i=r.height,a=t.append("text").attr("x",(0,s.nV)().state.padding).attr("y",i+.4*(0,s.nV)().state.padding+(0,s.nV)().state.dividerMargin+(0,s.nV)().state.textHeight).attr("class","state-description");let o=!0,l=!0;e.descriptions.forEach((function(t){o||(n(a,t,l),l=!1),o=!1}));const c=t.append("line").attr("x1",(0,s.nV)().state.padding).attr("y1",(0,s.nV)().state.padding+i+(0,s.nV)().state.dividerMargin/2).attr("y2",(0,s.nV)().state.padding+i+(0,s.nV)().state.dividerMargin/2).attr("class","descr-divider"),h=a.node().getBBox(),u=Math.max(h.width,r.width);return c.attr("x2",u+3*(0,s.nV)().state.padding),t.insert("rect",":first-child").attr("x",(0,s.nV)().state.padding).attr("y",(0,s.nV)().state.padding).attr("width",u+2*(0,s.nV)().state.padding).attr("height",h.height+i+2*(0,s.nV)().state.padding).attr("rx",(0,s.nV)().state.radius),t}),"drawDescrState"),b=(0,s.eW)(((t,e,n)=>{const r=(0,s.nV)().state.padding,i=2*(0,s.nV)().state.padding,a=t.node().getBBox(),o=a.width,l=a.x,c=t.append("text").attr("x",0).attr("y",(0,s.nV)().state.titleShift).attr("font-size",(0,s.nV)().state.fontSize).attr("class","state-title").text(e.id),h=c.node().getBBox().width+i;let u,d=Math.max(h,o);d===o&&(d+=i);const p=t.node().getBBox();e.doc,u=l-r,h>o&&(u=(o-d)/2+r),Math.abs(l-p.x)o&&(u=l-(h-o)/2);const g=1-(0,s.nV)().state.textHeight;return t.insert("rect",":first-child").attr("x",u).attr("y",g).attr("class",n?"alt-composit":"composit").attr("width",d).attr("height",p.height+(0,s.nV)().state.textHeight+(0,s.nV)().state.titleShift+1).attr("rx","0"),c.attr("x",u+r),h<=o&&c.attr("x",l+(d-i)/2-h/2+r),t.insert("rect",":first-child").attr("x",u).attr("y",(0,s.nV)().state.titleShift-(0,s.nV)().state.textHeight-(0,s.nV)().state.padding).attr("width",d).attr("height",3*(0,s.nV)().state.textHeight).attr("rx",(0,s.nV)().state.radius),t.insert("rect",":first-child").attr("x",u).attr("y",(0,s.nV)().state.titleShift-(0,s.nV)().state.textHeight-(0,s.nV)().state.padding).attr("width",d).attr("height",p.height+3+2*(0,s.nV)().state.textHeight).attr("rx",(0,s.nV)().state.radius),t}),"addTitleAndBox"),w=(0,s.eW)((t=>(t.append("circle").attr("class","end-state-outer").attr("r",(0,s.nV)().state.sizeUnit+(0,s.nV)().state.miniPadding).attr("cx",(0,s.nV)().state.padding+(0,s.nV)().state.sizeUnit+(0,s.nV)().state.miniPadding).attr("cy",(0,s.nV)().state.padding+(0,s.nV)().state.sizeUnit+(0,s.nV)().state.miniPadding),t.append("circle").attr("class","end-state-inner").attr("r",(0,s.nV)().state.sizeUnit).attr("cx",(0,s.nV)().state.padding+(0,s.nV)().state.sizeUnit+2).attr("cy",(0,s.nV)().state.padding+(0,s.nV)().state.sizeUnit+2))),"drawEndState"),k=(0,s.eW)(((t,e)=>{let n=(0,s.nV)().state.forkWidth,r=(0,s.nV)().state.forkHeight;if(e.parentId){let t=n;n=r,r=t}return t.append("rect").style("stroke","black").style("fill","black").attr("width",n).attr("height",r).attr("x",(0,s.nV)().state.padding).attr("y",(0,s.nV)().state.padding)}),"drawForkJoinState"),T=(0,s.eW)(((t,e,n,r)=>{let i=0;const a=r.append("text");a.style("text-anchor","start"),a.attr("class","noteText");let o=t.replace(/\r\n/g,"
    ");o=o.replace(/\n/g,"
    ");const l=o.split(s.SY.lineBreakRegex);let c=1.25*(0,s.nV)().state.noteMargin;for(const t of l){const r=t.trim();if(r.length>0){const t=a.append("tspan");t.text(r),0===c&&(c+=t.node().getBBox().height),i+=c,t.attr("x",e+(0,s.nV)().state.noteMargin),t.attr("y",n+i+1.25*(0,s.nV)().state.noteMargin)}}return{textWidth:a.node().getBBox().width,textHeight:i}}),"_drawLongText"),_=(0,s.eW)(((t,e)=>{e.attr("class","state-note");const n=e.append("rect").attr("x",0).attr("y",(0,s.nV)().state.padding),r=e.append("g"),{textWidth:i,textHeight:a}=T(t,0,0,r);return n.attr("height",a+2*(0,s.nV)().state.noteMargin),n.attr("width",i+2*(0,s.nV)().state.noteMargin),n}),"drawNote"),E=(0,s.eW)((function(t,e){const n=e.id,r={id:n,label:e.id,width:0,height:0},i=t.append("g").attr("id",n).attr("class","stateGroup");"start"===e.type&&m(i),"end"===e.type&&w(i),"fork"!==e.type&&"join"!==e.type||k(i,e),"note"===e.type&&_(e.note.text,i),"divider"===e.type&&y(i),"default"===e.type&&0===e.descriptions.length&&v(i,e),"default"===e.type&&e.descriptions.length>0&&x(i,e);const a=i.node().getBBox();return r.width=a.width+2*(0,s.nV)().state.padding,r.height=a.height+2*(0,s.nV)().state.padding,f.set(n,r),r}),"drawState"),S=0,C=(0,s.eW)((function(t,e,n){const r=(0,s.eW)((function(t){switch(t){case i.oI.relationType.AGGREGATION:return"aggregation";case i.oI.relationType.EXTENSION:return"extension";case i.oI.relationType.COMPOSITION:return"composition";case i.oI.relationType.DEPENDENCY:return"dependency"}}),"getRelationType");e.points=e.points.filter((t=>!Number.isNaN(t.y)));const l=e.points,c=(0,o.jvg)().x((function(t){return t.x})).y((function(t){return t.y})).curve(o.$0Z),h=t.append("path").attr("d",c(l)).attr("id","edge"+S).attr("class","transition");let u="";if((0,s.nV)().state.arrowMarkerAbsolute&&(u=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,u=u.replace(/\(/g,"\\("),u=u.replace(/\)/g,"\\)")),h.attr("marker-end","url("+u+"#"+r(i.oI.relationType.DEPENDENCY)+"End)"),void 0!==n.title){const r=t.append("g").attr("class","stateLabel"),{x:i,y:o}=a.w8.calcLabelPosition(e.points),l=s.SY.getRows(n.title);let c=0;const h=[];let u=0,d=0;for(let t=0;t<=l.length;t++){const e=r.append("text").attr("text-anchor","middle").text(l[t]).attr("x",i).attr("y",o+c),n=e.node().getBBox();if(u=Math.max(u,n.width),d=Math.min(d,n.x),s.cM.info(n.x,i,o+c),0===c){const t=e.node().getBBox();c=t.height,s.cM.info("Title height",c,o)}h.push(e)}let p=c*l.length;if(l.length>1){const t=(l.length-1)*c*.5;h.forEach(((e,n)=>e.attr("y",o+n*c-t))),p=c*l.length}const g=r.node().getBBox();r.insert("rect",":first-child").attr("class","box").attr("x",i-u/2-(0,s.nV)().state.padding/2).attr("y",o-p/2-(0,s.nV)().state.padding/2-3.5).attr("width",u+(0,s.nV)().state.padding).attr("height",p+(0,s.nV)().state.padding),s.cM.info(g)}S++}),"drawEdge"),A={},L=(0,s.eW)((function(){}),"setConf"),M=(0,s.eW)((function(t){t.append("defs").append("marker").attr("id","dependencyEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")}),"insertMarkers"),N=(0,s.eW)((function(t,e,n,i){r=(0,s.nV)().state;const a=(0,s.nV)().securityLevel;let l;"sandbox"===a&&(l=(0,o.Ys)("#i"+e));const c="sandbox"===a?(0,o.Ys)(l.nodes()[0].contentDocument.body):(0,o.Ys)("body"),h="sandbox"===a?l.nodes()[0].contentDocument:document;s.cM.debug("Rendering diagram "+t);const u=c.select(`[id='${e}']`);M(u);const d=i.db.getRootDoc();R(d,u,void 0,!1,c,h,i);const p=r.padding,g=u.node().getBBox(),f=g.width+2*p,m=g.height+2*p,y=1.75*f;(0,s.v2)(u,m,y,r.useMaxWidth),u.attr("viewBox",`${g.x-r.padding} ${g.y-r.padding} `+f+" "+m)}),"draw"),I=(0,s.eW)((t=>t?t.length*r.fontSizeFactor:1),"getLabelWidth"),R=(0,s.eW)(((t,e,n,i,a,o,h)=>{const u=new c.k({compound:!0,multigraph:!0});let d,p=!0;for(d=0;d{const e=t.parentElement;let n=0,r=0;e&&(e.parentElement&&(n=e.parentElement.getBBox().width),r=parseInt(e.getAttribute("data-x-shift"),10),Number.isNaN(r)&&(r=0)),t.setAttribute("x1",0-r+8),t.setAttribute("x2",n-r-8)}))):s.cM.debug("No Node "+t+": "+JSON.stringify(u.node(t)))}));let x=v.getBBox();u.edges().forEach((function(t){void 0!==t&&void 0!==u.edge(t)&&(s.cM.debug("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(u.edge(t))),C(e,u.edge(t),u.edge(t).relation))})),x=v.getBBox();const w={id:n||"root",label:n||"root",width:0,height:0};return w.width=x.width+2*r.padding,w.height=x.height+2*r.padding,s.cM.debug("Doc rendered",w,u),w}),"renderDoc"),D={setConf:L,draw:N},O={parser:i.J8,get db(){return new i.oI(1)},renderer:D,styles:i.Ee,init:(0,s.eW)((t=>{t.state||(t.state={}),t.state.arrowMarkerAbsolute=t.arrowMarkerAbsolute}),"init")}},8710:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>a});var r=n(9836),i=(n(907),n(8337),n(1566),n(5179),n(3583),n(1426),n(6241),n(214),n(7946),n(4082)),a={parser:r.J8,get db(){return new r.oI(2)},renderer:r._$,styles:r.Ee,init:(0,i.eW)((t=>{t.state||(t.state={}),t.state.arrowMarkerAbsolute=t.arrowMarkerAbsolute}),"init")}},2270:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>H});var r=n(4082),i=n(3108),a=n(6500),s=n(2281),o=n(7201),l=function(){var t=(0,r.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[6,8,10,11,12,14,16,17,20,21],n=[1,9],i=[1,10],a=[1,11],s=[1,12],o=[1,13],l=[1,16],c=[1,17],h={trace:(0,r.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,timeline:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,title:11,acc_title:12,acc_title_value:13,acc_descr:14,acc_descr_value:15,acc_descr_multiline_value:16,section:17,period_statement:18,event_statement:19,period:20,event:21,$accept:0,$end:1},terminals_:{2:"error",4:"timeline",6:"EOF",8:"SPACE",10:"NEWLINE",11:"title",12:"acc_title",13:"acc_title_value",14:"acc_descr",15:"acc_descr_value",16:"acc_descr_multiline_value",17:"section",20:"period",21:"event"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,1],[18,1],[19,1]],performAction:(0,r.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 1:return a[o-1];case 2:case 6:case 7:this.$=[];break;case 3:a[o-1].push(a[o]),this.$=a[o-1];break;case 4:case 5:this.$=a[o];break;case 8:r.getCommonDb().setDiagramTitle(a[o].substr(6)),this.$=a[o].substr(6);break;case 9:this.$=a[o].trim(),r.getCommonDb().setAccTitle(this.$);break;case 10:case 11:this.$=a[o].trim(),r.getCommonDb().setAccDescription(this.$);break;case 12:r.addSection(a[o].substr(8)),this.$=a[o].substr(8);break;case 15:r.addTask(a[o],0,""),this.$=a[o];break;case 16:r.addEvent(a[o].substr(2)),this.$=a[o]}}),"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:n,12:i,14:a,16:s,17:o,18:14,19:15,20:l,21:c},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:18,11:n,12:i,14:a,16:s,17:o,18:14,19:15,20:l,21:c},t(e,[2,5]),t(e,[2,6]),t(e,[2,8]),{13:[1,19]},{15:[1,20]},t(e,[2,11]),t(e,[2,12]),t(e,[2,13]),t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),t(e,[2,4]),t(e,[2,9]),t(e,[2,10])],defaultActions:{},parseError:(0,r.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,r.eW)((function(t){var e=this,n=[0],i=[],a=[null],s=[],o=this.table,l="",c=0,h=0,u=0,d=s.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;s.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=i.pop()||p.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,r.eW)((function(t){n.length=n.length-2*t,a.length=a.length-t,s.length=s.length-t}),"popStack"),(0,r.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),a.push(p.yytext),s.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=a[a.length-E],A._$={first_line:s[s.length-(E||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(E||1)].first_column,last_column:s[s.length-1].last_column},y&&(A._$.range=[s[s.length-(E||1)].range[0],s[s.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],a,s].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),a=a.slice(0,-1*E),s=s.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),a.push(A.$),s.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},u=function(){return{EOF:1,parseError:(0,r.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,r.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,r.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,r.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,r.eW)((function(){return this._more=!0,this}),"more"),reject:(0,r.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,r.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,r.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,r.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,r.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,r.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,r.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,r.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,r.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,r.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,r.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,r.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,r.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,r.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,r.eW)((function(t,e,n,r){switch(n){case 0:case 1:case 3:case 4:break;case 2:return 10;case 5:return 4;case 6:return 11;case 7:return this.begin("acc_title"),12;case 8:return this.popState(),"acc_title_value";case 9:return this.begin("acc_descr"),14;case 10:return this.popState(),"acc_descr_value";case 11:this.begin("acc_descr_multiline");break;case 12:this.popState();break;case 13:return"acc_descr_multiline_value";case 14:return 17;case 15:return 21;case 16:return 20;case 17:return 6;case 18:return"INVALID"}}),"anonymous"),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:timeline\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^:\n]+)/i,/^(?::\s[^:\n]+)/i,/^(?:[^#:\n]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,9,11,14,15,16,17,18],inclusive:!0}}}}();function d(){this.yy={}}return h.lexer=u,(0,r.eW)(d,"Parser"),d.prototype=h,h.Parser=d,new d}();l.parser=l;var c=l,h={};(0,r.r2)(h,{addEvent:()=>k,addSection:()=>v,addTask:()=>w,addTaskOrg:()=>T,clear:()=>y,default:()=>E,getCommonDb:()=>m,getSections:()=>x,getTasks:()=>b});var u="",d=0,p=[],g=[],f=[],m=(0,r.eW)((()=>r.LJ),"getCommonDb"),y=(0,r.eW)((function(){p.length=0,g.length=0,u="",f.length=0,(0,r.ZH)()}),"clear"),v=(0,r.eW)((function(t){u=t,p.push(t)}),"addSection"),x=(0,r.eW)((function(){return p}),"getSections"),b=(0,r.eW)((function(){let t=_(),e=0;for(;!t&&e<100;)t=_(),e++;return g.push(...f),g}),"getTasks"),w=(0,r.eW)((function(t,e,n){const r={id:d++,section:u,type:u,task:t,score:e||0,events:n?[n]:[]};f.push(r)}),"addTask"),k=(0,r.eW)((function(t){f.find((t=>t.id===d-1)).events.push(t)}),"addEvent"),T=(0,r.eW)((function(t){const e={section:u,type:u,description:t,task:t,classes:[]};g.push(e)}),"addTaskOrg"),_=(0,r.eW)((function(){const t=(0,r.eW)((function(t){return f[t].processed}),"compileTask");let e=!0;for(const[n,r]of f.entries())t(n),e=e&&r.processed;return e}),"compileTasks"),E={clear:y,getCommonDb:m,addSection:v,getSections:x,getTasks:b,addTask:w,addTaskOrg:T,addEvent:k},S=(0,r.eW)((function(t,e){const n=t.append("rect");return n.attr("x",e.x),n.attr("y",e.y),n.attr("fill",e.fill),n.attr("stroke",e.stroke),n.attr("width",e.width),n.attr("height",e.height),n.attr("rx",e.rx),n.attr("ry",e.ry),void 0!==e.class&&n.attr("class",e.class),n}),"drawRect"),C=(0,r.eW)((function(t,e){const n=t.append("circle").attr("cx",e.cx).attr("cy",e.cy).attr("class","face").attr("r",15).attr("stroke-width",2).attr("overflow","visible"),a=t.append("g");function s(t){const n=(0,i.Nb1)().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",n).attr("transform","translate("+e.cx+","+(e.cy+2)+")")}function o(t){const n=(0,i.Nb1)().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",n).attr("transform","translate("+e.cx+","+(e.cy+7)+")")}function l(t){t.append("line").attr("class","mouth").attr("stroke",2).attr("x1",e.cx-5).attr("y1",e.cy+7).attr("x2",e.cx+5).attr("y2",e.cy+7).attr("class","mouth").attr("stroke-width","1px").attr("stroke","#666")}return a.append("circle").attr("cx",e.cx-5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),a.append("circle").attr("cx",e.cx+5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),(0,r.eW)(s,"smile"),(0,r.eW)(o,"sad"),(0,r.eW)(l,"ambivalent"),e.score>3?s(a):e.score<3?o(a):l(a),n}),"drawFace"),A=(0,r.eW)((function(t,e){const n=t.append("circle");return n.attr("cx",e.cx),n.attr("cy",e.cy),n.attr("class","actor-"+e.pos),n.attr("fill",e.fill),n.attr("stroke",e.stroke),n.attr("r",e.r),void 0!==n.class&&n.attr("class",n.class),void 0!==e.title&&n.append("title").text(e.title),n}),"drawCircle"),L=(0,r.eW)((function(t,e){const n=e.text.replace(//gi," "),r=t.append("text");r.attr("x",e.x),r.attr("y",e.y),r.attr("class","legend"),r.style("text-anchor",e.anchor),void 0!==e.class&&r.attr("class",e.class);const i=r.append("tspan");return i.attr("x",e.x+2*e.textMargin),i.text(n),r}),"drawText"),M=(0,r.eW)((function(t,e){function n(t,e,n,r,i){return t+","+e+" "+(t+n)+","+e+" "+(t+n)+","+(e+r-i)+" "+(t+n-1.2*i)+","+(e+r)+" "+t+","+(e+r)}(0,r.eW)(n,"genPoints");const i=t.append("polygon");i.attr("points",n(e.x,e.y,50,20,7)),i.attr("class","labelBox"),e.y=e.y+e.labelMargin,e.x=e.x+.5*e.labelMargin,L(t,e)}),"drawLabel"),N=(0,r.eW)((function(t,e,n){const r=t.append("g"),i=P();i.x=e.x,i.y=e.y,i.fill=e.fill,i.width=n.width,i.height=n.height,i.class="journey-section section-type-"+e.num,i.rx=3,i.ry=3,S(r,i),$(n)(e.text,r,i.x,i.y,i.width,i.height,{class:"journey-section section-type-"+e.num},n,e.colour)}),"drawSection"),I=-1,R=(0,r.eW)((function(t,e,n){const r=e.x+n.width/2,i=t.append("g");I++,i.append("line").attr("id","task"+I).attr("x1",r).attr("y1",e.y).attr("x2",r).attr("y2",450).attr("class","task-line").attr("stroke-width","1px").attr("stroke-dasharray","4 2").attr("stroke","#666"),C(i,{cx:r,cy:300+30*(5-e.score),score:e.score});const a=P();a.x=e.x,a.y=e.y,a.fill=e.fill,a.width=n.width,a.height=n.height,a.class="task task-type-"+e.num,a.rx=3,a.ry=3,S(i,a),$(n)(e.task,i,a.x,a.y,a.width,a.height,{class:"task"},n,e.colour)}),"drawTask"),D=(0,r.eW)((function(t,e){S(t,{x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,class:"rect"}).lower()}),"drawBackgroundRect"),O=(0,r.eW)((function(){return{x:0,y:0,fill:void 0,"text-anchor":"start",width:100,height:100,textMargin:0,rx:0,ry:0}}),"getTextObj"),P=(0,r.eW)((function(){return{x:0,y:0,width:100,anchor:"start",height:100,rx:0,ry:0}}),"getNoteRect"),$=function(){function t(t,e,n,r,a,s,o,l){i(e.append("text").attr("x",n+a/2).attr("y",r+s/2+5).style("font-color",l).style("text-anchor","middle").text(t),o)}function e(t,e,n,r,a,s,o,l,c){const{taskFontSize:h,taskFontFamily:u}=l,d=t.split(//gi);for(let t=0;t)/).reverse(),a=[],s=n.attr("y"),o=parseFloat(n.attr("dy")),l=n.text(null).append("tspan").attr("x",0).attr("y",s).attr("dy",o+"em");for(let i=0;ie||"
    "===t)&&(a.pop(),l.text(a.join(" ").trim()),a="
    "===t?[""]:[t],l=n.append("tspan").attr("x",0).attr("y",s).attr("dy","1.1em").text(t))}))}(0,r.eW)(F,"wrap");var W=(0,r.eW)((function(t,e,n,r){const i=n%12-1,a=t.append("g");e.section=i,a.attr("class",(e.class?e.class+" ":"")+"timeline-node section-"+i);const s=a.append("g"),o=a.append("g"),l=o.append("text").text(e.descr).attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","middle").attr("text-anchor","middle").call(F,e.width).node().getBBox(),c=r.fontSize?.replace?r.fontSize.replace("px",""):r.fontSize;return e.height=l.height+1.1*c*.5+e.padding,e.height=Math.max(e.height,e.maxHeight),e.width=e.width+2*e.padding,o.attr("transform","translate("+e.width/2+", "+e.padding/2+")"),Z(s,e,i,r),e}),"drawNode"),z=(0,r.eW)((function(t,e,n){const r=t.append("g"),i=r.append("text").text(e.descr).attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","middle").attr("text-anchor","middle").call(F,e.width).node().getBBox(),a=n.fontSize?.replace?n.fontSize.replace("px",""):n.fontSize;return r.remove(),i.height+1.1*a*.5+e.padding}),"getVirtualNodeHeight"),Z=(0,r.eW)((function(t,e,n){t.append("path").attr("id","node-"+e.id).attr("class","node-bkg node-"+e.type).attr("d",`M0 ${e.height-5} v${10-e.height} q0,-5 5,-5 h${e.width-10} q5,0 5,5 v${e.height-5} H0 Z`),t.append("line").attr("class","node-line-"+n).attr("x1",0).attr("y1",e.height).attr("x2",e.width).attr("y2",e.height)}),"defaultBkg"),Y={drawRect:S,drawCircle:A,drawSection:N,drawText:L,drawLabel:M,drawTask:R,drawBackgroundRect:D,getTextObj:O,getNoteRect:P,initGraphics:B,drawNode:W,getVirtualNodeHeight:z},U=(0,r.eW)((function(t,e,n,a){const s=(0,r.nV)(),o=s.leftMargin??50;r.cM.debug("timeline",a.db);const l=s.securityLevel;let c;"sandbox"===l&&(c=(0,i.Ys)("#i"+e));const h=("sandbox"===l?(0,i.Ys)(c.nodes()[0].contentDocument.body):(0,i.Ys)("body")).select("#"+e);h.append("g");const u=a.db.getTasks(),d=a.db.getCommonDb().getDiagramTitle();r.cM.debug("task",u),Y.initGraphics(h);const p=a.db.getSections();r.cM.debug("sections",p);let g=0,f=0,m=0,y=0,v=50+o,x=50;y=50;let b=0,w=!0;p.forEach((function(t){const e={number:b,descr:t,section:b,width:150,padding:20,maxHeight:g},n=Y.getVirtualNodeHeight(h,e,s);r.cM.debug("sectionHeight before draw",n),g=Math.max(g,n+20)}));let k=0,T=0;r.cM.debug("tasks.length",u.length);for(const[t,e]of u.entries()){const n={number:t,descr:e,section:e.section,width:150,padding:20,maxHeight:f},i=Y.getVirtualNodeHeight(h,n,s);r.cM.debug("taskHeight before draw",i),f=Math.max(f,i+20),k=Math.max(k,e.events.length);let a=0;for(const t of e.events){const n={descr:t,section:e.section,number:e.section,width:150,padding:20,maxHeight:50};a+=Y.getVirtualNodeHeight(h,n,s)}T=Math.max(T,a)}r.cM.debug("maxSectionHeight before draw",g),r.cM.debug("maxTaskHeight before draw",f),p&&p.length>0?p.forEach((t=>{const e=u.filter((e=>e.section===t)),n={number:b,descr:t,section:b,width:200*Math.max(e.length,1)-50,padding:20,maxHeight:g};r.cM.debug("sectionNode",n);const i=h.append("g"),a=Y.drawNode(i,n,b,s);r.cM.debug("sectionNode output",a),i.attr("transform",`translate(${v}, 50)`),x+=g+50,e.length>0&&G(h,e,b,v,x,f,s,k,T,g,!1),v+=200*Math.max(e.length,1),x=50,b++})):(w=!1,G(h,u,b,v,x,f,s,k,T,g,!0));const _=h.node().getBBox();r.cM.debug("bounds",_),d&&h.append("text").text(d).attr("x",_.width/2-o).attr("font-size","4ex").attr("font-weight","bold").attr("y",20),m=w?g+f+150:f+100,h.append("g").attr("class","lineWrapper").append("line").attr("x1",o).attr("y1",m).attr("x2",_.width+3*o).attr("y2",m).attr("stroke-width",4).attr("stroke","black").attr("marker-end","url(#arrowhead)"),(0,r.j7)(void 0,h,s.timeline?.padding??50,s.timeline?.useMaxWidth??!1)}),"draw"),G=(0,r.eW)((function(t,e,n,i,a,s,o,l,c,h,u){for(const l of e){const e={descr:l.task,section:n,number:n,width:150,padding:20,maxHeight:s};r.cM.debug("taskNode",e);const d=t.append("g").attr("class","taskWrapper"),p=Y.drawNode(d,e,n,o).height;if(r.cM.debug("taskHeight after draw",p),d.attr("transform",`translate(${i}, ${a})`),s=Math.max(s,p),l.events){const e=t.append("g").attr("class","lineWrapper");let r=s;a+=100,r+=V(t,l.events,n,i,a,o),a-=100,e.append("line").attr("x1",i+95).attr("y1",a+s).attr("x2",i+95).attr("y2",a+s+(u?s:h)+c+120).attr("stroke-width",2).attr("stroke","black").attr("marker-end","url(#arrowhead)").attr("stroke-dasharray","5,5")}i+=200,u&&!o.timeline?.disableMulticolor&&n++}a-=10}),"drawTasks"),V=(0,r.eW)((function(t,e,n,i,a,s){let o=0;const l=a;a+=100;for(const l of e){const e={descr:l,section:n,number:n,width:150,padding:20,maxHeight:50};r.cM.debug("eventNode",e);const c=t.append("g").attr("class","eventWrapper"),h=Y.drawNode(c,e,n,s).height;o+=h,c.attr("transform",`translate(${i}, ${a})`),a=a+10+h}return a=l,o}),"drawEvents"),q={setConf:(0,r.eW)((()=>{}),"setConf"),draw:U},j=(0,r.eW)((t=>{let e="";for(let e=0;e`\n .edge {\n stroke-width: 3;\n }\n ${j(t)}\n .section-root rect, .section-root path, .section-root circle {\n fill: ${t.git0};\n }\n .section-root text {\n fill: ${t.gitBranchLabel0};\n }\n .icon-container {\n height:100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n .edge {\n fill: none;\n }\n .eventWrapper {\n filter: brightness(120%);\n }\n`),"getStyles")}},5587:(t,e,n)=>{"use strict";n.d(e,{diagram:()=>J});var r=n(214),i=n(7946),a=n(5430),s=n(4082),o=n(3108),l=function(){var t=(0,s.eW)((function(t,e,n,r){for(n=n||{},r=t.length;r--;n[t[r]]=e);return n}),"o"),e=[1,10,12,14,16,18,19,21,23],n=[2,6],r=[1,3],i=[1,5],a=[1,6],o=[1,7],l=[1,5,10,12,14,16,18,19,21,23,34,35,36],c=[1,25],h=[1,26],u=[1,28],d=[1,29],p=[1,30],g=[1,31],f=[1,32],m=[1,33],y=[1,34],v=[1,35],x=[1,36],b=[1,37],w=[1,43],k=[1,42],T=[1,47],_=[1,50],E=[1,10,12,14,16,18,19,21,23,34,35,36],S=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36],C=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36,41,42,43,44,45,46,47,48,49,50],A=[1,64],L={trace:(0,s.eW)((function(){}),"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,commaSeparatedNumbers:25,SQUARE_BRACES_END:26,NUMBER_WITH_DECIMAL:27,COMMA:28,xAxisData:29,bandData:30,ARROW_DELIMITER:31,commaSeparatedTexts:32,yAxisData:33,NEWLINE:34,SEMI:35,EOF:36,alphaNum:37,STR:38,MD_STR:39,alphaNumToken:40,AMP:41,NUM:42,ALPHA:43,PLUS:44,EQUALS:45,MULT:46,DOT:47,BRKT:48,MINUS:49,UNDERSCORE:50,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",27:"NUMBER_WITH_DECIMAL",28:"COMMA",31:"ARROW_DELIMITER",34:"NEWLINE",35:"SEMI",36:"EOF",38:"STR",39:"MD_STR",41:"AMP",42:"NUM",43:"ALPHA",44:"PLUS",45:"EQUALS",46:"MULT",47:"DOT",48:"BRKT",49:"MINUS",50:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[13,1],[13,2],[13,1],[29,1],[29,3],[30,3],[32,3],[32,1],[15,1],[15,2],[15,1],[33,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[37,1],[37,2],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1]],performAction:(0,s.eW)((function(t,e,n,r,i,a,s){var o=a.length-1;switch(i){case 5:r.setOrientation(a[o]);break;case 9:r.setDiagramTitle(a[o].text.trim());break;case 12:r.setLineData({text:"",type:"text"},a[o]);break;case 13:r.setLineData(a[o-1],a[o]);break;case 14:r.setBarData({text:"",type:"text"},a[o]);break;case 15:r.setBarData(a[o-1],a[o]);break;case 16:this.$=a[o].trim(),r.setAccTitle(this.$);break;case 17:case 18:this.$=a[o].trim(),r.setAccDescription(this.$);break;case 19:case 27:this.$=a[o-1];break;case 20:this.$=[Number(a[o-2]),...a[o]];break;case 21:this.$=[Number(a[o])];break;case 22:r.setXAxisTitle(a[o]);break;case 23:r.setXAxisTitle(a[o-1]);break;case 24:r.setXAxisTitle({type:"text",text:""});break;case 25:r.setXAxisBand(a[o]);break;case 26:r.setXAxisRangeData(Number(a[o-2]),Number(a[o]));break;case 28:this.$=[a[o-2],...a[o]];break;case 29:this.$=[a[o]];break;case 30:r.setYAxisTitle(a[o]);break;case 31:r.setYAxisTitle(a[o-1]);break;case 32:r.setYAxisTitle({type:"text",text:""});break;case 33:r.setYAxisRangeData(Number(a[o-2]),Number(a[o]));break;case 37:case 38:this.$={text:a[o],type:"text"};break;case 39:this.$={text:a[o],type:"markdown"};break;case 40:this.$=a[o];break;case 41:this.$=a[o-1]+""+a[o]}}),"anonymous"),table:[t(e,n,{3:1,4:2,7:4,5:r,34:i,35:a,36:o}),{1:[3]},t(e,n,{4:2,7:4,3:8,5:r,34:i,35:a,36:o}),t(e,n,{4:2,7:4,6:9,3:10,5:r,8:[1,11],34:i,35:a,36:o}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},t(l,[2,34]),t(l,[2,35]),t(l,[2,36]),{1:[2,1]},t(e,n,{4:2,7:4,3:21,5:r,34:i,35:a,36:o}),{1:[2,3]},t(l,[2,5]),t(e,[2,7],{4:22,34:i,35:a,36:o}),{11:23,37:24,38:c,39:h,40:27,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b},{11:39,13:38,24:w,27:k,29:40,30:41,37:24,38:c,39:h,40:27,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b},{11:45,15:44,27:T,33:46,37:24,38:c,39:h,40:27,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b},{11:49,17:48,24:_,37:24,38:c,39:h,40:27,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b},{11:52,17:51,24:_,37:24,38:c,39:h,40:27,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b},{20:[1,53]},{22:[1,54]},t(E,[2,18]),{1:[2,2]},t(E,[2,8]),t(E,[2,9]),t(S,[2,37],{40:55,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b}),t(S,[2,38]),t(S,[2,39]),t(C,[2,40]),t(C,[2,42]),t(C,[2,43]),t(C,[2,44]),t(C,[2,45]),t(C,[2,46]),t(C,[2,47]),t(C,[2,48]),t(C,[2,49]),t(C,[2,50]),t(C,[2,51]),t(E,[2,10]),t(E,[2,22],{30:41,29:56,24:w,27:k}),t(E,[2,24]),t(E,[2,25]),{31:[1,57]},{11:59,32:58,37:24,38:c,39:h,40:27,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b},t(E,[2,11]),t(E,[2,30],{33:60,27:T}),t(E,[2,32]),{31:[1,61]},t(E,[2,12]),{17:62,24:_},{25:63,27:A},t(E,[2,14]),{17:65,24:_},t(E,[2,16]),t(E,[2,17]),t(C,[2,41]),t(E,[2,23]),{27:[1,66]},{26:[1,67]},{26:[2,29],28:[1,68]},t(E,[2,31]),{27:[1,69]},t(E,[2,13]),{26:[1,70]},{26:[2,21],28:[1,71]},t(E,[2,15]),t(E,[2,26]),t(E,[2,27]),{11:59,32:72,37:24,38:c,39:h,40:27,41:u,42:d,43:p,44:g,45:f,46:m,47:y,48:v,49:x,50:b},t(E,[2,33]),t(E,[2,19]),{25:73,27:A},{26:[2,28]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],72:[2,28],73:[2,20]},parseError:(0,s.eW)((function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)}),"parseError"),parse:(0,s.eW)((function(t){var e=this,n=[0],r=[],i=[null],a=[],o=this.table,l="",c=0,h=0,u=0,d=a.slice.call(arguments,1),p=Object.create(this.lexer),g={yy:{}};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g.yy[f]=this.yy[f]);p.setInput(t,g.yy),g.yy.lexer=p,g.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function v(){var t;return"number"!=typeof(t=r.pop()||p.lex()||1)&&(t instanceof Array&&(t=(r=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.yy.parseError?this.parseError=g.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.eW)((function(t){n.length=n.length-2*t,i.length=i.length-t,a.length=a.length-t}),"popStack"),(0,s.eW)(v,"lex");for(var x,b,w,k,T,_,E,S,C,A={};;){if(w=n[n.length-1],this.defaultActions[w]?k=this.defaultActions[w]:(null==x&&(x=v()),k=o[w]&&o[w][x]),void 0===k||!k.length||!k[0]){var L;for(_ in C=[],o[w])this.terminals_[_]&&_>2&&C.push("'"+this.terminals_[_]+"'");L=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(L,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:C})}if(k[0]instanceof Array&&k.length>1)throw new Error("Parse Error: multiple actions possible at state: "+w+", token: "+x);switch(k[0]){case 1:n.push(x),i.push(p.yytext),a.push(p.yylloc),n.push(k[1]),x=null,b?(x=b,b=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,u>0&&u--);break;case 2:if(E=this.productions_[k[1]][1],A.$=i[i.length-E],A._$={first_line:a[a.length-(E||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(E||1)].first_column,last_column:a[a.length-1].last_column},y&&(A._$.range=[a[a.length-(E||1)].range[0],a[a.length-1].range[1]]),void 0!==(T=this.performAction.apply(A,[l,h,c,g.yy,k[1],i,a].concat(d))))return T;E&&(n=n.slice(0,-1*E*2),i=i.slice(0,-1*E),a=a.slice(0,-1*E)),n.push(this.productions_[k[1]][0]),i.push(A.$),a.push(A._$),S=o[n[n.length-2]][n[n.length-1]],n.push(S);break;case 3:return!0}}return!0}),"parse")},M=function(){return{EOF:1,parseError:(0,s.eW)((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:(0,s.eW)((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:(0,s.eW)((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:(0,s.eW)((function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var r=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===r.length?this.yylloc.first_column:0)+r[r.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this}),"unput"),more:(0,s.eW)((function(){return this._more=!0,this}),"more"),reject:(0,s.eW)((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:(0,s.eW)((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:(0,s.eW)((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:(0,s.eW)((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:(0,s.eW)((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:(0,s.eW)((function(t,e){var n,r,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(r=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=r.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var a in i)this[a]=i[a];return!1}return!1}),"test_match"),next:(0,s.eW)((function(){if(this.done)return this.EOF;var t,e,n,r;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),a=0;ae[0].length)){if(e=n,r=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[a])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[r]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:(0,s.eW)((function(){return this.next()||this.lex()}),"lex"),begin:(0,s.eW)((function(t){this.conditionStack.push(t)}),"begin"),popState:(0,s.eW)((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:(0,s.eW)((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:(0,s.eW)((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:(0,s.eW)((function(t){this.begin(t)}),"pushState"),stateStackSize:(0,s.eW)((function(){return this.conditionStack.length}),"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.eW)((function(t,e,n,r){switch(n){case 0:case 1:case 5:case 43:break;case 2:case 3:return this.popState(),34;case 4:return 34;case 6:return 10;case 7:return this.pushState("acc_title"),19;case 8:return this.popState(),"acc_title_value";case 9:return this.pushState("acc_descr"),21;case 10:return this.popState(),"acc_descr_value";case 11:this.pushState("acc_descr_multiline");break;case 12:case 25:case 27:this.popState();break;case 13:return"acc_descr_multiline_value";case 14:return 5;case 15:return 8;case 16:return this.pushState("axis_data"),"X_AXIS";case 17:return this.pushState("axis_data"),"Y_AXIS";case 18:return this.pushState("axis_band_data"),24;case 19:return 31;case 20:return this.pushState("data"),16;case 21:return this.pushState("data"),18;case 22:return this.pushState("data_inner"),24;case 23:return 27;case 24:return this.popState(),26;case 26:this.pushState("string");break;case 28:return"STR";case 29:return 24;case 30:return 26;case 31:return 43;case 32:return"COLON";case 33:return 44;case 34:return 28;case 35:return 45;case 36:return 46;case 37:return 48;case 38:return 50;case 39:return 47;case 40:return 41;case 41:return 49;case 42:return 42;case 44:return 35;case 45:return 36}}),"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:(\r?\n))/i,/^(?:(\r?\n))/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:\{)/i,/^(?:[^\}]*)/i,/^(?:xychart-beta\b)/i,/^(?:(?:vertical|horizontal))/i,/^(?:x-axis\b)/i,/^(?:y-axis\b)/i,/^(?:\[)/i,/^(?:-->)/i,/^(?:line\b)/i,/^(?:bar\b)/i,/^(?:\[)/i,/^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i,/^(?:\])/i,/^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n\(\?:`))/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s+)/i,/^(?:;)/i,/^(?:$)/i],conditions:{data_inner:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,20,21,23,24,25,26,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45],inclusive:!0},data:{rules:[0,1,3,4,5,6,7,9,11,14,15,16,17,20,21,22,25,26,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45],inclusive:!0},axis_band_data:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,20,21,24,25,26,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45],inclusive:!0},axis_data:{rules:[0,1,2,4,5,6,7,9,11,14,15,16,17,18,19,20,21,23,25,26,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45],inclusive:!0},acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},title:{rules:[],inclusive:!1},md_string:{rules:[],inclusive:!1},string:{rules:[27,28],inclusive:!1},INITIAL:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,20,21,25,26,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45],inclusive:!0}}}}();function N(){this.yy={}}return L.lexer=M,(0,s.eW)(N,"Parser"),N.prototype=L,L.Parser=N,new N}();l.parser=l;var c=l;function h(t){return"bar"===t.type}function u(t){return"band"===t.type}function d(t){return"linear"===t.type}(0,s.eW)(h,"isBarPlot"),(0,s.eW)(u,"isBandAxisData"),(0,s.eW)(d,"isLinearAxisData");var p=class{constructor(t){this.parentGroup=t}static{(0,s.eW)(this,"TextDimensionCalculatorWithFont")}getMaxDimension(t,e){if(!this.parentGroup)return{width:t.reduce(((t,e)=>Math.max(e.length,t)),0)*e,height:e};const n={width:0,height:0},i=this.parentGroup.append("g").attr("visibility","hidden").attr("font-size",e);for(const a of t){const t=(0,r.QA)(i,1,a),s=t?t.width:a.length*e,o=t?t.height:e;n.width=Math.max(n.width,s),n.height=Math.max(n.height,o)}return i.remove(),n}},g=class{constructor(t,e,n,r){this.axisConfig=t,this.title=e,this.textDimensionCalculator=n,this.axisThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left",this.showTitle=!1,this.showLabel=!1,this.showTick=!1,this.showAxisLine=!1,this.outerPadding=0,this.titleTextHeight=0,this.labelTextHeight=0,this.range=[0,10],this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left"}static{(0,s.eW)(this,"BaseAxis")}setRange(t){this.range=t,"left"===this.axisPosition||"right"===this.axisPosition?this.boundingRect.height=t[1]-t[0]:this.boundingRect.width=t[1]-t[0],this.recalculateScale()}getRange(){return[this.range[0]+this.outerPadding,this.range[1]-this.outerPadding]}setAxisPosition(t){this.axisPosition=t,this.setRange(this.range)}getTickDistance(){const t=this.getRange();return Math.abs(t[0]-t[1])/this.getTickValues().length}getAxisOuterPadding(){return this.outerPadding}getLabelDimension(){return this.textDimensionCalculator.getMaxDimension(this.getTickValues().map((t=>t.toString())),this.axisConfig.labelFontSize)}recalculateOuterPaddingToDrawBar(){.7*this.getTickDistance()>2*this.outerPadding&&(this.outerPadding=Math.floor(.7*this.getTickDistance()/2)),this.recalculateScale()}calculateSpaceIfDrawnHorizontally(t){let e=t.height;if(this.axisConfig.showAxisLine&&e>this.axisConfig.axisLineWidth&&(e-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){const n=this.getLabelDimension(),r=.2*t.width;this.outerPadding=Math.min(n.width/2,r);const i=n.height+2*this.axisConfig.labelPadding;this.labelTextHeight=n.height,i<=e&&(e-=i,this.showLabel=!0)}if(this.axisConfig.showTick&&e>=this.axisConfig.tickLength&&(this.showTick=!0,e-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){const t=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=t.height+2*this.axisConfig.titlePadding;this.titleTextHeight=t.height,n<=e&&(e-=n,this.showTitle=!0)}this.boundingRect.width=t.width,this.boundingRect.height=t.height-e}calculateSpaceIfDrawnVertical(t){let e=t.width;if(this.axisConfig.showAxisLine&&e>this.axisConfig.axisLineWidth&&(e-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){const n=this.getLabelDimension(),r=.2*t.height;this.outerPadding=Math.min(n.height/2,r);const i=n.width+2*this.axisConfig.labelPadding;i<=e&&(e-=i,this.showLabel=!0)}if(this.axisConfig.showTick&&e>=this.axisConfig.tickLength&&(this.showTick=!0,e-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){const t=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),n=t.height+2*this.axisConfig.titlePadding;this.titleTextHeight=t.height,n<=e&&(e-=n,this.showTitle=!0)}this.boundingRect.width=t.width-e,this.boundingRect.height=t.height}calculateSpace(t){return"left"===this.axisPosition||"right"===this.axisPosition?this.calculateSpaceIfDrawnVertical(t):this.calculateSpaceIfDrawnHorizontally(t),this.recalculateScale(),{width:this.boundingRect.width,height:this.boundingRect.height}}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}getDrawableElementsForLeftAxis(){const t=[];if(this.showAxisLine){const e=this.boundingRect.x+this.boundingRect.width-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["left-axis","axisl-line"],data:[{path:`M ${e},${this.boundingRect.y} L ${e},${this.boundingRect.y+this.boundingRect.height} `,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["left-axis","label"],data:this.getTickValues().map((t=>({text:t.toString(),x:this.boundingRect.x+this.boundingRect.width-(this.showLabel?this.axisConfig.labelPadding:0)-(this.showTick?this.axisConfig.tickLength:0)-(this.showAxisLine?this.axisConfig.axisLineWidth:0),y:this.getScaleValue(t),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"middle",horizontalPos:"right"})))}),this.showTick){const e=this.boundingRect.x+this.boundingRect.width-(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["left-axis","ticks"],data:this.getTickValues().map((t=>({path:`M ${e},${this.getScaleValue(t)} L ${e-this.axisConfig.tickLength},${this.getScaleValue(t)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth})))})}return this.showTitle&&t.push({type:"text",groupTexts:["left-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.axisConfig.titlePadding,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:270,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForBottomAxis(){const t=[];if(this.showAxisLine){const e=this.boundingRect.y+this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["bottom-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${e} L ${this.boundingRect.x+this.boundingRect.width},${e}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["bottom-axis","label"],data:this.getTickValues().map((t=>({text:t.toString(),x:this.getScaleValue(t),y:this.boundingRect.y+this.axisConfig.labelPadding+(this.showTick?this.axisConfig.tickLength:0)+(this.showAxisLine?this.axisConfig.axisLineWidth:0),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"})))}),this.showTick){const e=this.boundingRect.y+(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["bottom-axis","ticks"],data:this.getTickValues().map((t=>({path:`M ${this.getScaleValue(t)},${e} L ${this.getScaleValue(t)},${e+this.axisConfig.tickLength}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth})))})}return this.showTitle&&t.push({type:"text",groupTexts:["bottom-axis","title"],data:[{text:this.title,x:this.range[0]+(this.range[1]-this.range[0])/2,y:this.boundingRect.y+this.boundingRect.height-this.axisConfig.titlePadding-this.titleTextHeight,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForTopAxis(){const t=[];if(this.showAxisLine){const e=this.boundingRect.y+this.boundingRect.height-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["top-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${e} L ${this.boundingRect.x+this.boundingRect.width},${e}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["top-axis","label"],data:this.getTickValues().map((t=>({text:t.toString(),x:this.getScaleValue(t),y:this.boundingRect.y+(this.showTitle?this.titleTextHeight+2*this.axisConfig.titlePadding:0)+this.axisConfig.labelPadding,fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"})))}),this.showTick){const e=this.boundingRect.y;t.push({type:"path",groupTexts:["top-axis","ticks"],data:this.getTickValues().map((t=>({path:`M ${this.getScaleValue(t)},${e+this.boundingRect.height-(this.showAxisLine?this.axisConfig.axisLineWidth:0)} L ${this.getScaleValue(t)},${e+this.boundingRect.height-this.axisConfig.tickLength-(this.showAxisLine?this.axisConfig.axisLineWidth:0)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth})))})}return this.showTitle&&t.push({type:"text",groupTexts:["top-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.axisConfig.titlePadding,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElements(){if("left"===this.axisPosition)return this.getDrawableElementsForLeftAxis();if("right"===this.axisPosition)throw Error("Drawing of right axis is not implemented");return"bottom"===this.axisPosition?this.getDrawableElementsForBottomAxis():"top"===this.axisPosition?this.getDrawableElementsForTopAxis():[]}},f=class extends g{static{(0,s.eW)(this,"BandAxis")}constructor(t,e,n,r,i){super(t,r,i,e),this.categories=n,this.scale=(0,o.tiA)().domain(this.categories).range(this.getRange())}setRange(t){super.setRange(t)}recalculateScale(){this.scale=(0,o.tiA)().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(.5),s.cM.trace("BandAxis axis final categories, range: ",this.categories,this.getRange())}getTickValues(){return this.categories}getScaleValue(t){return this.scale(t)??this.getRange()[0]}},m=class extends g{static{(0,s.eW)(this,"LinearAxis")}constructor(t,e,n,r,i){super(t,r,i,e),this.domain=n,this.scale=(0,o.BYU)().domain(this.domain).range(this.getRange())}getTickValues(){return this.scale.ticks()}recalculateScale(){const t=[...this.domain];"left"===this.axisPosition&&t.reverse(),this.scale=(0,o.BYU)().domain(t).range(this.getRange())}getScaleValue(t){return this.scale(t)}};function y(t,e,n,r){const i=new p(r);return u(t)?new f(e,n,t.categories,t.title,i):new m(e,n,[t.min,t.max],t.title,i)}(0,s.eW)(y,"getAxis");var v=class{constructor(t,e,n,r){this.textDimensionCalculator=t,this.chartConfig=e,this.chartData=n,this.chartThemeConfig=r,this.boundingRect={x:0,y:0,width:0,height:0},this.showChartTitle=!1}static{(0,s.eW)(this,"ChartTitle")}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){const e=this.textDimensionCalculator.getMaxDimension([this.chartData.title],this.chartConfig.titleFontSize),n=Math.max(e.width,t.width),r=e.height+2*this.chartConfig.titlePadding;return e.width<=n&&e.height<=r&&this.chartConfig.showTitle&&this.chartData.title&&(this.boundingRect.width=n,this.boundingRect.height=r,this.showChartTitle=!0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){const t=[];return this.showChartTitle&&t.push({groupTexts:["chart-title"],type:"text",data:[{fontSize:this.chartConfig.titleFontSize,text:this.chartData.title,verticalPos:"middle",horizontalPos:"center",x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.chartThemeConfig.titleColor,rotation:0}]}),t}};function x(t,e,n,r){const i=new p(r);return new v(i,t,e,n)}(0,s.eW)(x,"getChartTitleComponent");var b=class{constructor(t,e,n,r,i){this.plotData=t,this.xAxis=e,this.yAxis=n,this.orientation=r,this.plotIndex=i}static{(0,s.eW)(this,"LinePlot")}getDrawableElement(){const t=this.plotData.data.map((t=>[this.xAxis.getScaleValue(t[0]),this.yAxis.getScaleValue(t[1])]));let e;return e="horizontal"===this.orientation?(0,o.jvg)().y((t=>t[0])).x((t=>t[1]))(t):(0,o.jvg)().x((t=>t[0])).y((t=>t[1]))(t),e?[{groupTexts:["plot",`line-plot-${this.plotIndex}`],type:"path",data:[{path:e,strokeFill:this.plotData.strokeFill,strokeWidth:this.plotData.strokeWidth}]}]:[]}},w=class{constructor(t,e,n,r,i,a){this.barData=t,this.boundingRect=e,this.xAxis=n,this.yAxis=r,this.orientation=i,this.plotIndex=a}static{(0,s.eW)(this,"BarPlot")}getDrawableElement(){const t=this.barData.data.map((t=>[this.xAxis.getScaleValue(t[0]),this.yAxis.getScaleValue(t[1])])),e=.95*Math.min(2*this.xAxis.getAxisOuterPadding(),this.xAxis.getTickDistance()),n=e/2;return"horizontal"===this.orientation?[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map((t=>({x:this.boundingRect.x,y:t[0]-n,height:e,width:t[1]-this.boundingRect.x,fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill})))}]:[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map((t=>({x:t[0]-n,y:t[1],width:e,height:this.boundingRect.y+this.boundingRect.height-t[1],fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill})))}]}},k=class{constructor(t,e,n){this.chartConfig=t,this.chartData=e,this.chartThemeConfig=n,this.boundingRect={x:0,y:0,width:0,height:0}}static{(0,s.eW)(this,"BasePlot")}setAxes(t,e){this.xAxis=t,this.yAxis=e}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){return this.boundingRect.width=t.width,this.boundingRect.height=t.height,{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(!this.xAxis||!this.yAxis)throw Error("Axes must be passed to render Plots");const t=[];for(const[e,n]of this.chartData.plots.entries())switch(n.type){case"line":{const r=new b(n,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,e);t.push(...r.getDrawableElement())}break;case"bar":{const r=new w(n,this.boundingRect,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,e);t.push(...r.getDrawableElement())}}return t}};function T(t,e,n){return new k(t,e,n)}(0,s.eW)(T,"getPlotComponent");var _,E=class{constructor(t,e,n,r){this.chartConfig=t,this.chartData=e,this.componentStore={title:x(t,e,n,r),plot:T(t,e,n),xAxis:y(e.xAxis,t.xAxis,{titleColor:n.xAxisTitleColor,labelColor:n.xAxisLabelColor,tickColor:n.xAxisTickColor,axisLineColor:n.xAxisLineColor},r),yAxis:y(e.yAxis,t.yAxis,{titleColor:n.yAxisTitleColor,labelColor:n.yAxisLabelColor,tickColor:n.yAxisTickColor,axisLineColor:n.yAxisLineColor},r)}}static{(0,s.eW)(this,"Orchestrator")}calculateVerticalSpace(){let t=this.chartConfig.width,e=this.chartConfig.height,n=0,r=0,i=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),a=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),s=this.componentStore.plot.calculateSpace({width:i,height:a});t-=s.width,e-=s.height,s=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:e}),r=s.height,e-=s.height,this.componentStore.xAxis.setAxisPosition("bottom"),s=this.componentStore.xAxis.calculateSpace({width:t,height:e}),e-=s.height,this.componentStore.yAxis.setAxisPosition("left"),s=this.componentStore.yAxis.calculateSpace({width:t,height:e}),n=s.width,t-=s.width,t>0&&(i+=t,t=0),e>0&&(a+=e,e=0),this.componentStore.plot.calculateSpace({width:i,height:a}),this.componentStore.plot.setBoundingBoxXY({x:n,y:r}),this.componentStore.xAxis.setRange([n,n+i]),this.componentStore.xAxis.setBoundingBoxXY({x:n,y:r+a}),this.componentStore.yAxis.setRange([r,r+a]),this.componentStore.yAxis.setBoundingBoxXY({x:0,y:r}),this.chartData.plots.some((t=>h(t)))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateHorizontalSpace(){let t=this.chartConfig.width,e=this.chartConfig.height,n=0,r=0,i=0,a=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),s=Math.floor(e*this.chartConfig.plotReservedSpacePercent/100),o=this.componentStore.plot.calculateSpace({width:a,height:s});t-=o.width,e-=o.height,o=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:e}),n=o.height,e-=o.height,this.componentStore.xAxis.setAxisPosition("left"),o=this.componentStore.xAxis.calculateSpace({width:t,height:e}),t-=o.width,r=o.width,this.componentStore.yAxis.setAxisPosition("top"),o=this.componentStore.yAxis.calculateSpace({width:t,height:e}),e-=o.height,i=n+o.height,t>0&&(a+=t,t=0),e>0&&(s+=e,e=0),this.componentStore.plot.calculateSpace({width:a,height:s}),this.componentStore.plot.setBoundingBoxXY({x:r,y:i}),this.componentStore.yAxis.setRange([r,r+a]),this.componentStore.yAxis.setBoundingBoxXY({x:r,y:n}),this.componentStore.xAxis.setRange([i,i+s]),this.componentStore.xAxis.setBoundingBoxXY({x:0,y:i}),this.chartData.plots.some((t=>h(t)))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateSpace(){"horizontal"===this.chartConfig.chartOrientation?this.calculateHorizontalSpace():this.calculateVerticalSpace()}getDrawableElement(){this.calculateSpace();const t=[];this.componentStore.plot.setAxes(this.componentStore.xAxis,this.componentStore.yAxis);for(const e of Object.values(this.componentStore))t.push(...e.getDrawableElements());return t}},S=class{static{(0,s.eW)(this,"XYChartBuilder")}static build(t,e,n,r){return new E(t,e,n,r).getDrawableElement()}},C=0,A=O(),L=D(),M={yAxis:{type:"linear",title:"",min:1/0,max:-1/0},xAxis:{type:"band",title:"",categories:[]},title:"",plots:[]},N=L.plotColorPalette.split(",").map((t=>t.trim())),I=!1,R=!1;function D(){const t=(0,s.xN)(),e=(0,s.iE)();return(0,i.Rb)(t.xyChart,e.themeVariables.xyChart)}function O(){const t=(0,s.iE)();return(0,i.Rb)(s.vZ.xyChart,t.xyChart)}function P(){return{yAxis:{type:"linear",title:"",min:1/0,max:-1/0},xAxis:{type:"band",title:"",categories:[]},title:"",plots:[]}}function $(t){const e=(0,s.iE)();return(0,s.oO)(t.trim(),e)}function B(t){_=t}function F(t){A.chartOrientation="horizontal"===t?"horizontal":"vertical"}function W(t){M.xAxis.title=$(t.text)}function z(t,e){M.xAxis={type:"linear",title:M.xAxis.title,min:t,max:e},I=!0}function Z(t){M.xAxis={type:"band",title:M.xAxis.title,categories:t.map((t=>$(t.text)))},I=!0}function Y(t){M.yAxis.title=$(t.text)}function U(t,e){M.yAxis={type:"linear",title:M.yAxis.title,min:t,max:e},R=!0}function G(t){const e=Math.min(...t),n=Math.max(...t),r=d(M.yAxis)?M.yAxis.min:1/0,i=d(M.yAxis)?M.yAxis.max:-1/0;M.yAxis={type:"linear",title:M.yAxis.title,min:Math.min(r,e),max:Math.max(i,n)}}function V(t){let e=[];if(0===t.length)return e;if(!I){const e=d(M.xAxis)?M.xAxis.min:1/0,n=d(M.xAxis)?M.xAxis.max:-1/0;z(Math.min(e,1),Math.max(n,t.length))}if(R||G(t),u(M.xAxis)&&(e=M.xAxis.categories.map(((e,n)=>[e,t[n]]))),d(M.xAxis)){const n=M.xAxis.min,r=M.xAxis.max,i=(r-n)/(t.length-1),a=[];for(let t=n;t<=r;t+=i)a.push(`${t}`);e=a.map(((e,n)=>[e,t[n]]))}return e}function q(t){return N[0===t?0:t%N.length]}function j(t,e){const n=V(e);M.plots.push({type:"line",strokeFill:q(C),strokeWidth:2,data:n}),C++}function H(t,e){const n=V(e);M.plots.push({type:"bar",fill:q(C),data:n}),C++}function X(){if(0===M.plots.length)throw Error("No Plot to render, please provide a plot with some data");return M.title=(0,s.Kr)(),S.build(A,M,L,_)}function K(){return L}function Q(){return A}(0,s.eW)(D,"getChartDefaultThemeConfig"),(0,s.eW)(O,"getChartDefaultConfig"),(0,s.eW)(P,"getChartDefaultData"),(0,s.eW)($,"textSanitizer"),(0,s.eW)(B,"setTmpSVGG"),(0,s.eW)(F,"setOrientation"),(0,s.eW)(W,"setXAxisTitle"),(0,s.eW)(z,"setXAxisRangeData"),(0,s.eW)(Z,"setXAxisBand"),(0,s.eW)(Y,"setYAxisTitle"),(0,s.eW)(U,"setYAxisRangeData"),(0,s.eW)(G,"setYAxisRangeFromPlotData"),(0,s.eW)(V,"transformDataWithoutCategory"),(0,s.eW)(q,"getPlotColorFromPalette"),(0,s.eW)(j,"setLineData"),(0,s.eW)(H,"setBarData"),(0,s.eW)(X,"getDrawableElem"),(0,s.eW)(K,"getChartThemeConfig"),(0,s.eW)(Q,"getChartConfig");var J={parser:c,db:{getDrawableElem:X,clear:(0,s.eW)((function(){(0,s.ZH)(),C=0,A=O(),M={yAxis:{type:"linear",title:"",min:1/0,max:-1/0},xAxis:{type:"band",title:"",categories:[]},title:"",plots:[]},L=D(),N=L.plotColorPalette.split(",").map((t=>t.trim())),I=!1,R=!1}),"clear"),setAccTitle:s.GN,getAccTitle:s.eu,setDiagramTitle:s.g2,getDiagramTitle:s.Kr,getAccDescription:s.Mx,setAccDescription:s.U$,setOrientation:F,setXAxisTitle:W,setXAxisRangeData:z,setXAxisBand:Z,setYAxisTitle:Y,setYAxisRangeData:U,setLineData:j,setBarData:H,setTmpSVGG:B,getChartThemeConfig:K,getChartConfig:Q},renderer:{draw:(0,s.eW)(((t,e,n,r)=>{const i=r.db,o=i.getChartThemeConfig(),l=i.getChartConfig();function c(t){return"top"===t?"text-before-edge":"middle"}function h(t){return"left"===t?"start":"right"===t?"end":"middle"}function u(t){return`translate(${t.x}, ${t.y}) rotate(${t.rotation||0})`}(0,s.eW)(c,"getDominantBaseLine"),(0,s.eW)(h,"getTextAnchor"),(0,s.eW)(u,"getTextTransformation"),s.cM.debug("Rendering xychart chart\n"+t);const d=(0,a.P)(e),p=d.append("g").attr("class","main"),g=p.append("rect").attr("width",l.width).attr("height",l.height).attr("class","background");(0,s.v2)(d,l.height,l.width,!0),d.attr("viewBox",`0 0 ${l.width} ${l.height}`),g.attr("fill",o.backgroundColor),i.setTmpSVGG(d.append("g").attr("class","mermaid-tmp-group"));const f=i.getDrawableElem(),m={};function y(t){let e=p,n="";for(const[r]of t.entries()){let i=p;r>0&&m[n]&&(i=m[n]),n+=t[r],e=m[n],e||(e=m[n]=i.append("g").attr("class",t[r]))}return e}(0,s.eW)(y,"getGroup");for(const t of f){if(0===t.data.length)continue;const e=y(t.groupTexts);switch(t.type){case"rect":e.selectAll("rect").data(t.data).enter().append("rect").attr("x",(t=>t.x)).attr("y",(t=>t.y)).attr("width",(t=>t.width)).attr("height",(t=>t.height)).attr("fill",(t=>t.fill)).attr("stroke",(t=>t.strokeFill)).attr("stroke-width",(t=>t.strokeWidth));break;case"text":e.selectAll("text").data(t.data).enter().append("text").attr("x",0).attr("y",0).attr("fill",(t=>t.fill)).attr("font-size",(t=>t.fontSize)).attr("dominant-baseline",(t=>c(t.verticalPos))).attr("text-anchor",(t=>h(t.horizontalPos))).attr("transform",(t=>u(t))).text((t=>t.text));break;case"path":e.selectAll("path").data(t.data).enter().append("path").attr("d",(t=>t.path)).attr("fill",(t=>t.fill?t.fill:"none")).attr("stroke",(t=>t.strokeFill)).attr("stroke-width",(t=>t.strokeWidth))}}}),"draw")}}},4433:(t,e,n)=>{"use strict";n.d(e,{default:()=>ni});class r{constructor(t,e,n){this.lexer=void 0,this.start=void 0,this.end=void 0,this.lexer=t,this.start=e,this.end=n}static range(t,e){return e?t&&t.loc&&e.loc&&t.loc.lexer===e.loc.lexer?new r(t.loc.lexer,t.loc.start,e.loc.end):null:t&&t.loc}}class i{constructor(t,e){this.text=void 0,this.loc=void 0,this.noexpand=void 0,this.treatAsRelax=void 0,this.text=t,this.loc=e}range(t,e){return new i(e,r.range(this,t))}}class a{constructor(t,e){this.name=void 0,this.position=void 0,this.length=void 0,this.rawMessage=void 0;var n,r,i="KaTeX parse error: "+t,s=e&&e.loc;if(s&&s.start<=s.end){var o=s.lexer.input;n=s.start,r=s.end,n===o.length?i+=" at end of input: ":i+=" at position "+(n+1)+": ";var l=o.slice(n,r).replace(/[^]/g,"$&̲");i+=(n>15?"…"+o.slice(n-15,n):o.slice(0,n))+l+(r+15":">","<":"<",'"':""","'":"'"},l=/[&><"']/g,c=function t(e){return"ordgroup"===e.type||"color"===e.type?1===e.body.length?t(e.body[0]):e:"font"===e.type?t(e.body):e},h=function(t,e){return-1!==t.indexOf(e)},u=function(t,e){return void 0===t?e:t},d=function(t){return String(t).replace(l,(t=>o[t]))},p=function(t){return t.replace(s,"-$1").toLowerCase()},g=c,f=function(t){var e=c(t);return"mathord"===e.type||"textord"===e.type||"atom"===e.type},m=function(t){var e=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(t);return e?":"!==e[2]?null:/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(e[1])?e[1].toLowerCase():null:"_relative"},y={displayMode:{type:"boolean",description:"Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.",cli:"-d, --display-mode"},output:{type:{enum:["htmlAndMathml","html","mathml"]},description:"Determines the markup language of the output.",cli:"-F, --format "},leqno:{type:"boolean",description:"Render display math in leqno style (left-justified tags)."},fleqn:{type:"boolean",description:"Render display math flush left."},throwOnError:{type:"boolean",default:!0,cli:"-t, --no-throw-on-error",cliDescription:"Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error."},errorColor:{type:"string",default:"#cc0000",cli:"-c, --error-color ",cliDescription:"A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.",cliProcessor:t=>"#"+t},macros:{type:"object",cli:"-m, --macro ",cliDescription:"Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).",cliDefault:[],cliProcessor:(t,e)=>(e.push(t),e)},minRuleThickness:{type:"number",description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:t=>Math.max(0,t),cli:"--min-rule-thickness ",cliProcessor:parseFloat},colorIsTextColor:{type:"boolean",description:"Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.",cli:"-b, --color-is-text-color"},strict:{type:[{enum:["warn","ignore","error"]},"boolean","function"],description:"Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.",cli:"-S, --strict",cliDefault:!1},trust:{type:["boolean","function"],description:"Trust the input, enabling all HTML features such as \\url.",cli:"-T, --trust"},maxSize:{type:"number",default:1/0,description:"If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large",processor:t=>Math.max(0,t),cli:"-s, --max-size ",cliProcessor:parseInt},maxExpand:{type:"number",default:1e3,description:"Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.",processor:t=>Math.max(0,t),cli:"-e, --max-expand ",cliProcessor:t=>"Infinity"===t?1/0:parseInt(t)},globalGroup:{type:"boolean",cli:!1}};function v(t){if(t.default)return t.default;var e=t.type,n=Array.isArray(e)?e[0]:e;if("string"!=typeof n)return n.enum[0];switch(n){case"boolean":return!1;case"string":return"";case"number":return 0;case"object":return{}}}class x{constructor(t){for(var e in this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,t=t||{},y)if(y.hasOwnProperty(e)){var n=y[e];this[e]=void 0!==t[e]?n.processor?n.processor(t[e]):t[e]:v(n)}}reportNonstrict(t,e,n){var r=this.strict;if("function"==typeof r&&(r=r(t,e,n)),r&&"ignore"!==r){if(!0===r||"error"===r)throw new a("LaTeX-incompatible input and strict mode is set to 'error': "+e+" ["+t+"]",n);"warn"===r?"undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+e+" ["+t+"]"):"undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to unrecognized '"+r+"': "+e+" ["+t+"]")}}useStrictBehavior(t,e,n){var r=this.strict;if("function"==typeof r)try{r=r(t,e,n)}catch(t){r="error"}return!(!r||"ignore"===r||!0!==r&&"error"!==r&&("warn"===r?("undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+e+" ["+t+"]"),1):("undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to unrecognized '"+r+"': "+e+" ["+t+"]"),1)))}isTrusted(t){if(t.url&&!t.protocol){var e=m(t.url);if(null==e)return!1;t.protocol=e}var n="function"==typeof this.trust?this.trust(t):this.trust;return Boolean(n)}}class b{constructor(t,e,n){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=t,this.size=e,this.cramped=n}sup(){return w[k[this.id]]}sub(){return w[T[this.id]]}fracNum(){return w[_[this.id]]}fracDen(){return w[E[this.id]]}cramp(){return w[S[this.id]]}text(){return w[C[this.id]]}isTight(){return this.size>=2}}var w=[new b(0,0,!1),new b(1,0,!0),new b(2,1,!1),new b(3,1,!0),new b(4,2,!1),new b(5,2,!0),new b(6,3,!1),new b(7,3,!0)],k=[4,5,4,5,6,7,6,7],T=[5,5,5,5,7,7,7,7],_=[2,3,4,5,6,7,6,7],E=[3,3,5,5,7,7,7,7],S=[1,1,3,3,5,5,7,7],C=[0,1,2,3,2,3,2,3],A={DISPLAY:w[0],TEXT:w[2],SCRIPT:w[4],SCRIPTSCRIPT:w[6]},L=[{name:"latin",blocks:[[256,591],[768,879]]},{name:"cyrillic",blocks:[[1024,1279]]},{name:"armenian",blocks:[[1328,1423]]},{name:"brahmic",blocks:[[2304,4255]]},{name:"georgian",blocks:[[4256,4351]]},{name:"cjk",blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:"hangul",blocks:[[44032,55215]]}],M=[];function N(t){for(var e=0;e=M[e]&&t<=M[e+1])return!0;return!1}L.forEach((t=>t.blocks.forEach((t=>M.push(...t)))));var I={doubleleftarrow:"M262 157\nl10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3\n 0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28\n 14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5\nc2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5\n 157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87\n-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7\n-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z\nm8 0v40h399730v-40zm0 194v40h399730v-40z",doublerightarrow:"M399738 392l\n-10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5\n 14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88\n-33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68\n-17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18\n-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782\nc-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3\n-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z",leftarrow:"M400000 241H110l3-3c68.7-52.7 113.7-120\n 135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8\n-5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247\nc-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208\n 490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3\n 1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202\n l-3-3h399890zM100 241v40h399900v-40z",leftbrace:"M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117\n-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7\n 5-6 9-10 13-.7 1-7.3 1-20 1H6z",leftbraceunder:"M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13\n 35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688\n 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7\n-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z",leftgroup:"M400000 80\nH435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0\n 435 0h399565z",leftgroupunder:"M400000 262\nH435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219\n 435 219h399565z",leftharpoon:"M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3\n-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5\n-18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7\n-196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z",leftharpoonplus:"M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5\n 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3\n-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7\n-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z\nm0 0v40h400000v-40z",leftharpoondown:"M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333\n 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5\n 1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667\n-152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z",leftharpoondownplus:"M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12\n 10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7\n-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0\nv40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z",lefthook:"M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5\n-83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3\n-68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21\n 71.5 23h399859zM103 281v-40h399897v40z",leftlinesegment:"M40 281 V428 H0 V94 H40 V241 H400000 v40z\nM40 281 V428 H0 V94 H40 V241 H400000 v40z",leftmapsto:"M40 281 V448H0V74H40V241H400000v40z\nM40 281 V448H0V74H40V241H400000v40z",leftToFrom:"M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23\n-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8\nc28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3\n 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z",longequal:"M0 50 h400000 v40H0z m0 194h40000v40H0z\nM0 50 h400000 v40H0z m0 194h40000v40H0z",midbrace:"M200428 334\nc-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14\n-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7\n 311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11\n 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z",midbraceunder:"M199572 214\nc100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14\n 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3\n 11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0\n-5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z",oiintSize1:"M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6\n-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z\nm368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8\n60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z",oiintSize2:"M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8\n-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z\nm502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2\nc0 110 84 276 504 276s502.4-166 502.4-276z",oiiintSize1:"M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6\n-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z\nm525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0\n85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z",oiiintSize2:"M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8\n-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z\nm770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1\nc0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z",rightarrow:"M0 241v40h399891c-47.3 35.3-84 78-110 128\n-16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20\n 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7\n 39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85\n-40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5\n-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67\n 151.7 139 205zm0 0v40h399900v-40z",rightbrace:"M400000 542l\n-6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5\ns-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1\nc124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z",rightbraceunder:"M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3\n 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237\n-174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z",rightgroup:"M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0\n 3-1 3-3v-38c-76-158-257-219-435-219H0z",rightgroupunder:"M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18\n 0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z",rightharpoon:"M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3\n-3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2\n-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58\n 69.2 92 94.5zm0 0v40h399900v-40z",rightharpoonplus:"M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11\n-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7\n 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z\nm0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z",rightharpoondown:"M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8\n 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5\n-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95\n-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z",rightharpoondownplus:"M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8\n 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3\n 8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3\n-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z\nm0-194v40h400000v-40zm0 0v40h400000v-40z",righthook:"M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3\n 15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0\n-13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21\n 66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z",rightlinesegment:"M399960 241 V94 h40 V428 h-40 V281 H0 v-40z\nM399960 241 V94 h40 V428 h-40 V281 H0 v-40z",rightToFrom:"M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23\n 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32\n-52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142\n-167z M100 147v40h399900v-40zM0 341v40h399900v-40z",twoheadleftarrow:"M0 167c68 40\n 115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69\n-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3\n-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19\n-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101\n 10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z",twoheadrightarrow:"M400000 167\nc-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3\n 41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42\n 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333\n-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70\n 101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z",tilde1:"M200 55.538c-77 0-168 73.953-177 73.953-3 0-7\n-2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0\n 114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0\n 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128\n-68.267.847-113-73.952-191-73.952z",tilde2:"M344 55.266c-142 0-300.638 81.316-311.5 86.418\n-8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9\n 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114\nc1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751\n 181.476 676 181.476c-149 0-189-126.21-332-126.21z",tilde3:"M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457\n-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0\n 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697\n 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696\n -338 0-409-156.573-744-156.573z",tilde4:"M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345\n-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409\n 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9\n 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409\n -175.236-744-175.236z",vec:"M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5\n3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11\n10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63\n-1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1\n-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59\nH213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359\nc-16-25.333-24-45-24-59z",widehat1:"M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22\nc-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z",widehat2:"M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",widehat3:"M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",widehat4:"M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",widecheck1:"M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1,\n-5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z",widecheck2:"M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",widecheck3:"M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",widecheck4:"M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",baraboveleftarrow:"M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202\nc4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5\nc-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130\ns-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47\n121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6\ns2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11\nc0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z\nM100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z",rightarrowabovebar:"M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32\n-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0\n13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39\n-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5\n-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5\n-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67\n151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z",baraboveshortleftharpoon:"M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11\nc1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17\nc2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21\nc-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40\nc-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z\nM0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z",rightharpoonaboveshortbar:"M0,241 l0,40c399126,0,399993,0,399993,0\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6\nc-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z\nM0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z",shortbaraboveleftharpoon:"M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11\nc1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9,\n1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7,\n-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z\nM93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z",shortrightharpoonabovebar:"M53,241l0,40c398570,0,399437,0,399437,0\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6\nc-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z\nM500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z"};class R{constructor(t){this.children=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.children=t,this.classes=[],this.height=0,this.depth=0,this.maxFontSize=0,this.style={}}hasClass(t){return h(this.classes,t)}toNode(){for(var t=document.createDocumentFragment(),e=0;et.toText())).join("")}}var D={"AMS-Regular":{32:[0,0,0,0,.25],65:[0,.68889,0,0,.72222],66:[0,.68889,0,0,.66667],67:[0,.68889,0,0,.72222],68:[0,.68889,0,0,.72222],69:[0,.68889,0,0,.66667],70:[0,.68889,0,0,.61111],71:[0,.68889,0,0,.77778],72:[0,.68889,0,0,.77778],73:[0,.68889,0,0,.38889],74:[.16667,.68889,0,0,.5],75:[0,.68889,0,0,.77778],76:[0,.68889,0,0,.66667],77:[0,.68889,0,0,.94445],78:[0,.68889,0,0,.72222],79:[.16667,.68889,0,0,.77778],80:[0,.68889,0,0,.61111],81:[.16667,.68889,0,0,.77778],82:[0,.68889,0,0,.72222],83:[0,.68889,0,0,.55556],84:[0,.68889,0,0,.66667],85:[0,.68889,0,0,.72222],86:[0,.68889,0,0,.72222],87:[0,.68889,0,0,1],88:[0,.68889,0,0,.72222],89:[0,.68889,0,0,.72222],90:[0,.68889,0,0,.66667],107:[0,.68889,0,0,.55556],160:[0,0,0,0,.25],165:[0,.675,.025,0,.75],174:[.15559,.69224,0,0,.94666],240:[0,.68889,0,0,.55556],295:[0,.68889,0,0,.54028],710:[0,.825,0,0,2.33334],732:[0,.9,0,0,2.33334],770:[0,.825,0,0,2.33334],771:[0,.9,0,0,2.33334],989:[.08167,.58167,0,0,.77778],1008:[0,.43056,.04028,0,.66667],8245:[0,.54986,0,0,.275],8463:[0,.68889,0,0,.54028],8487:[0,.68889,0,0,.72222],8498:[0,.68889,0,0,.55556],8502:[0,.68889,0,0,.66667],8503:[0,.68889,0,0,.44445],8504:[0,.68889,0,0,.66667],8513:[0,.68889,0,0,.63889],8592:[-.03598,.46402,0,0,.5],8594:[-.03598,.46402,0,0,.5],8602:[-.13313,.36687,0,0,1],8603:[-.13313,.36687,0,0,1],8606:[.01354,.52239,0,0,1],8608:[.01354,.52239,0,0,1],8610:[.01354,.52239,0,0,1.11111],8611:[.01354,.52239,0,0,1.11111],8619:[0,.54986,0,0,1],8620:[0,.54986,0,0,1],8621:[-.13313,.37788,0,0,1.38889],8622:[-.13313,.36687,0,0,1],8624:[0,.69224,0,0,.5],8625:[0,.69224,0,0,.5],8630:[0,.43056,0,0,1],8631:[0,.43056,0,0,1],8634:[.08198,.58198,0,0,.77778],8635:[.08198,.58198,0,0,.77778],8638:[.19444,.69224,0,0,.41667],8639:[.19444,.69224,0,0,.41667],8642:[.19444,.69224,0,0,.41667],8643:[.19444,.69224,0,0,.41667],8644:[.1808,.675,0,0,1],8646:[.1808,.675,0,0,1],8647:[.1808,.675,0,0,1],8648:[.19444,.69224,0,0,.83334],8649:[.1808,.675,0,0,1],8650:[.19444,.69224,0,0,.83334],8651:[.01354,.52239,0,0,1],8652:[.01354,.52239,0,0,1],8653:[-.13313,.36687,0,0,1],8654:[-.13313,.36687,0,0,1],8655:[-.13313,.36687,0,0,1],8666:[.13667,.63667,0,0,1],8667:[.13667,.63667,0,0,1],8669:[-.13313,.37788,0,0,1],8672:[-.064,.437,0,0,1.334],8674:[-.064,.437,0,0,1.334],8705:[0,.825,0,0,.5],8708:[0,.68889,0,0,.55556],8709:[.08167,.58167,0,0,.77778],8717:[0,.43056,0,0,.42917],8722:[-.03598,.46402,0,0,.5],8724:[.08198,.69224,0,0,.77778],8726:[.08167,.58167,0,0,.77778],8733:[0,.69224,0,0,.77778],8736:[0,.69224,0,0,.72222],8737:[0,.69224,0,0,.72222],8738:[.03517,.52239,0,0,.72222],8739:[.08167,.58167,0,0,.22222],8740:[.25142,.74111,0,0,.27778],8741:[.08167,.58167,0,0,.38889],8742:[.25142,.74111,0,0,.5],8756:[0,.69224,0,0,.66667],8757:[0,.69224,0,0,.66667],8764:[-.13313,.36687,0,0,.77778],8765:[-.13313,.37788,0,0,.77778],8769:[-.13313,.36687,0,0,.77778],8770:[-.03625,.46375,0,0,.77778],8774:[.30274,.79383,0,0,.77778],8776:[-.01688,.48312,0,0,.77778],8778:[.08167,.58167,0,0,.77778],8782:[.06062,.54986,0,0,.77778],8783:[.06062,.54986,0,0,.77778],8785:[.08198,.58198,0,0,.77778],8786:[.08198,.58198,0,0,.77778],8787:[.08198,.58198,0,0,.77778],8790:[0,.69224,0,0,.77778],8791:[.22958,.72958,0,0,.77778],8796:[.08198,.91667,0,0,.77778],8806:[.25583,.75583,0,0,.77778],8807:[.25583,.75583,0,0,.77778],8808:[.25142,.75726,0,0,.77778],8809:[.25142,.75726,0,0,.77778],8812:[.25583,.75583,0,0,.5],8814:[.20576,.70576,0,0,.77778],8815:[.20576,.70576,0,0,.77778],8816:[.30274,.79383,0,0,.77778],8817:[.30274,.79383,0,0,.77778],8818:[.22958,.72958,0,0,.77778],8819:[.22958,.72958,0,0,.77778],8822:[.1808,.675,0,0,.77778],8823:[.1808,.675,0,0,.77778],8828:[.13667,.63667,0,0,.77778],8829:[.13667,.63667,0,0,.77778],8830:[.22958,.72958,0,0,.77778],8831:[.22958,.72958,0,0,.77778],8832:[.20576,.70576,0,0,.77778],8833:[.20576,.70576,0,0,.77778],8840:[.30274,.79383,0,0,.77778],8841:[.30274,.79383,0,0,.77778],8842:[.13597,.63597,0,0,.77778],8843:[.13597,.63597,0,0,.77778],8847:[.03517,.54986,0,0,.77778],8848:[.03517,.54986,0,0,.77778],8858:[.08198,.58198,0,0,.77778],8859:[.08198,.58198,0,0,.77778],8861:[.08198,.58198,0,0,.77778],8862:[0,.675,0,0,.77778],8863:[0,.675,0,0,.77778],8864:[0,.675,0,0,.77778],8865:[0,.675,0,0,.77778],8872:[0,.69224,0,0,.61111],8873:[0,.69224,0,0,.72222],8874:[0,.69224,0,0,.88889],8876:[0,.68889,0,0,.61111],8877:[0,.68889,0,0,.61111],8878:[0,.68889,0,0,.72222],8879:[0,.68889,0,0,.72222],8882:[.03517,.54986,0,0,.77778],8883:[.03517,.54986,0,0,.77778],8884:[.13667,.63667,0,0,.77778],8885:[.13667,.63667,0,0,.77778],8888:[0,.54986,0,0,1.11111],8890:[.19444,.43056,0,0,.55556],8891:[.19444,.69224,0,0,.61111],8892:[.19444,.69224,0,0,.61111],8901:[0,.54986,0,0,.27778],8903:[.08167,.58167,0,0,.77778],8905:[.08167,.58167,0,0,.77778],8906:[.08167,.58167,0,0,.77778],8907:[0,.69224,0,0,.77778],8908:[0,.69224,0,0,.77778],8909:[-.03598,.46402,0,0,.77778],8910:[0,.54986,0,0,.76042],8911:[0,.54986,0,0,.76042],8912:[.03517,.54986,0,0,.77778],8913:[.03517,.54986,0,0,.77778],8914:[0,.54986,0,0,.66667],8915:[0,.54986,0,0,.66667],8916:[0,.69224,0,0,.66667],8918:[.0391,.5391,0,0,.77778],8919:[.0391,.5391,0,0,.77778],8920:[.03517,.54986,0,0,1.33334],8921:[.03517,.54986,0,0,1.33334],8922:[.38569,.88569,0,0,.77778],8923:[.38569,.88569,0,0,.77778],8926:[.13667,.63667,0,0,.77778],8927:[.13667,.63667,0,0,.77778],8928:[.30274,.79383,0,0,.77778],8929:[.30274,.79383,0,0,.77778],8934:[.23222,.74111,0,0,.77778],8935:[.23222,.74111,0,0,.77778],8936:[.23222,.74111,0,0,.77778],8937:[.23222,.74111,0,0,.77778],8938:[.20576,.70576,0,0,.77778],8939:[.20576,.70576,0,0,.77778],8940:[.30274,.79383,0,0,.77778],8941:[.30274,.79383,0,0,.77778],8994:[.19444,.69224,0,0,.77778],8995:[.19444,.69224,0,0,.77778],9416:[.15559,.69224,0,0,.90222],9484:[0,.69224,0,0,.5],9488:[0,.69224,0,0,.5],9492:[0,.37788,0,0,.5],9496:[0,.37788,0,0,.5],9585:[.19444,.68889,0,0,.88889],9586:[.19444,.74111,0,0,.88889],9632:[0,.675,0,0,.77778],9633:[0,.675,0,0,.77778],9650:[0,.54986,0,0,.72222],9651:[0,.54986,0,0,.72222],9654:[.03517,.54986,0,0,.77778],9660:[0,.54986,0,0,.72222],9661:[0,.54986,0,0,.72222],9664:[.03517,.54986,0,0,.77778],9674:[.11111,.69224,0,0,.66667],9733:[.19444,.69224,0,0,.94445],10003:[0,.69224,0,0,.83334],10016:[0,.69224,0,0,.83334],10731:[.11111,.69224,0,0,.66667],10846:[.19444,.75583,0,0,.61111],10877:[.13667,.63667,0,0,.77778],10878:[.13667,.63667,0,0,.77778],10885:[.25583,.75583,0,0,.77778],10886:[.25583,.75583,0,0,.77778],10887:[.13597,.63597,0,0,.77778],10888:[.13597,.63597,0,0,.77778],10889:[.26167,.75726,0,0,.77778],10890:[.26167,.75726,0,0,.77778],10891:[.48256,.98256,0,0,.77778],10892:[.48256,.98256,0,0,.77778],10901:[.13667,.63667,0,0,.77778],10902:[.13667,.63667,0,0,.77778],10933:[.25142,.75726,0,0,.77778],10934:[.25142,.75726,0,0,.77778],10935:[.26167,.75726,0,0,.77778],10936:[.26167,.75726,0,0,.77778],10937:[.26167,.75726,0,0,.77778],10938:[.26167,.75726,0,0,.77778],10949:[.25583,.75583,0,0,.77778],10950:[.25583,.75583,0,0,.77778],10955:[.28481,.79383,0,0,.77778],10956:[.28481,.79383,0,0,.77778],57350:[.08167,.58167,0,0,.22222],57351:[.08167,.58167,0,0,.38889],57352:[.08167,.58167,0,0,.77778],57353:[0,.43056,.04028,0,.66667],57356:[.25142,.75726,0,0,.77778],57357:[.25142,.75726,0,0,.77778],57358:[.41951,.91951,0,0,.77778],57359:[.30274,.79383,0,0,.77778],57360:[.30274,.79383,0,0,.77778],57361:[.41951,.91951,0,0,.77778],57366:[.25142,.75726,0,0,.77778],57367:[.25142,.75726,0,0,.77778],57368:[.25142,.75726,0,0,.77778],57369:[.25142,.75726,0,0,.77778],57370:[.13597,.63597,0,0,.77778],57371:[.13597,.63597,0,0,.77778]},"Caligraphic-Regular":{32:[0,0,0,0,.25],65:[0,.68333,0,.19445,.79847],66:[0,.68333,.03041,.13889,.65681],67:[0,.68333,.05834,.13889,.52653],68:[0,.68333,.02778,.08334,.77139],69:[0,.68333,.08944,.11111,.52778],70:[0,.68333,.09931,.11111,.71875],71:[.09722,.68333,.0593,.11111,.59487],72:[0,.68333,.00965,.11111,.84452],73:[0,.68333,.07382,0,.54452],74:[.09722,.68333,.18472,.16667,.67778],75:[0,.68333,.01445,.05556,.76195],76:[0,.68333,0,.13889,.68972],77:[0,.68333,0,.13889,1.2009],78:[0,.68333,.14736,.08334,.82049],79:[0,.68333,.02778,.11111,.79611],80:[0,.68333,.08222,.08334,.69556],81:[.09722,.68333,0,.11111,.81667],82:[0,.68333,0,.08334,.8475],83:[0,.68333,.075,.13889,.60556],84:[0,.68333,.25417,0,.54464],85:[0,.68333,.09931,.08334,.62583],86:[0,.68333,.08222,0,.61278],87:[0,.68333,.08222,.08334,.98778],88:[0,.68333,.14643,.13889,.7133],89:[.09722,.68333,.08222,.08334,.66834],90:[0,.68333,.07944,.13889,.72473],160:[0,0,0,0,.25]},"Fraktur-Regular":{32:[0,0,0,0,.25],33:[0,.69141,0,0,.29574],34:[0,.69141,0,0,.21471],38:[0,.69141,0,0,.73786],39:[0,.69141,0,0,.21201],40:[.24982,.74947,0,0,.38865],41:[.24982,.74947,0,0,.38865],42:[0,.62119,0,0,.27764],43:[.08319,.58283,0,0,.75623],44:[0,.10803,0,0,.27764],45:[.08319,.58283,0,0,.75623],46:[0,.10803,0,0,.27764],47:[.24982,.74947,0,0,.50181],48:[0,.47534,0,0,.50181],49:[0,.47534,0,0,.50181],50:[0,.47534,0,0,.50181],51:[.18906,.47534,0,0,.50181],52:[.18906,.47534,0,0,.50181],53:[.18906,.47534,0,0,.50181],54:[0,.69141,0,0,.50181],55:[.18906,.47534,0,0,.50181],56:[0,.69141,0,0,.50181],57:[.18906,.47534,0,0,.50181],58:[0,.47534,0,0,.21606],59:[.12604,.47534,0,0,.21606],61:[-.13099,.36866,0,0,.75623],63:[0,.69141,0,0,.36245],65:[0,.69141,0,0,.7176],66:[0,.69141,0,0,.88397],67:[0,.69141,0,0,.61254],68:[0,.69141,0,0,.83158],69:[0,.69141,0,0,.66278],70:[.12604,.69141,0,0,.61119],71:[0,.69141,0,0,.78539],72:[.06302,.69141,0,0,.7203],73:[0,.69141,0,0,.55448],74:[.12604,.69141,0,0,.55231],75:[0,.69141,0,0,.66845],76:[0,.69141,0,0,.66602],77:[0,.69141,0,0,1.04953],78:[0,.69141,0,0,.83212],79:[0,.69141,0,0,.82699],80:[.18906,.69141,0,0,.82753],81:[.03781,.69141,0,0,.82699],82:[0,.69141,0,0,.82807],83:[0,.69141,0,0,.82861],84:[0,.69141,0,0,.66899],85:[0,.69141,0,0,.64576],86:[0,.69141,0,0,.83131],87:[0,.69141,0,0,1.04602],88:[0,.69141,0,0,.71922],89:[.18906,.69141,0,0,.83293],90:[.12604,.69141,0,0,.60201],91:[.24982,.74947,0,0,.27764],93:[.24982,.74947,0,0,.27764],94:[0,.69141,0,0,.49965],97:[0,.47534,0,0,.50046],98:[0,.69141,0,0,.51315],99:[0,.47534,0,0,.38946],100:[0,.62119,0,0,.49857],101:[0,.47534,0,0,.40053],102:[.18906,.69141,0,0,.32626],103:[.18906,.47534,0,0,.5037],104:[.18906,.69141,0,0,.52126],105:[0,.69141,0,0,.27899],106:[0,.69141,0,0,.28088],107:[0,.69141,0,0,.38946],108:[0,.69141,0,0,.27953],109:[0,.47534,0,0,.76676],110:[0,.47534,0,0,.52666],111:[0,.47534,0,0,.48885],112:[.18906,.52396,0,0,.50046],113:[.18906,.47534,0,0,.48912],114:[0,.47534,0,0,.38919],115:[0,.47534,0,0,.44266],116:[0,.62119,0,0,.33301],117:[0,.47534,0,0,.5172],118:[0,.52396,0,0,.5118],119:[0,.52396,0,0,.77351],120:[.18906,.47534,0,0,.38865],121:[.18906,.47534,0,0,.49884],122:[.18906,.47534,0,0,.39054],160:[0,0,0,0,.25],8216:[0,.69141,0,0,.21471],8217:[0,.69141,0,0,.21471],58112:[0,.62119,0,0,.49749],58113:[0,.62119,0,0,.4983],58114:[.18906,.69141,0,0,.33328],58115:[.18906,.69141,0,0,.32923],58116:[.18906,.47534,0,0,.50343],58117:[0,.69141,0,0,.33301],58118:[0,.62119,0,0,.33409],58119:[0,.47534,0,0,.50073]},"Main-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.35],34:[0,.69444,0,0,.60278],35:[.19444,.69444,0,0,.95833],36:[.05556,.75,0,0,.575],37:[.05556,.75,0,0,.95833],38:[0,.69444,0,0,.89444],39:[0,.69444,0,0,.31944],40:[.25,.75,0,0,.44722],41:[.25,.75,0,0,.44722],42:[0,.75,0,0,.575],43:[.13333,.63333,0,0,.89444],44:[.19444,.15556,0,0,.31944],45:[0,.44444,0,0,.38333],46:[0,.15556,0,0,.31944],47:[.25,.75,0,0,.575],48:[0,.64444,0,0,.575],49:[0,.64444,0,0,.575],50:[0,.64444,0,0,.575],51:[0,.64444,0,0,.575],52:[0,.64444,0,0,.575],53:[0,.64444,0,0,.575],54:[0,.64444,0,0,.575],55:[0,.64444,0,0,.575],56:[0,.64444,0,0,.575],57:[0,.64444,0,0,.575],58:[0,.44444,0,0,.31944],59:[.19444,.44444,0,0,.31944],60:[.08556,.58556,0,0,.89444],61:[-.10889,.39111,0,0,.89444],62:[.08556,.58556,0,0,.89444],63:[0,.69444,0,0,.54305],64:[0,.69444,0,0,.89444],65:[0,.68611,0,0,.86944],66:[0,.68611,0,0,.81805],67:[0,.68611,0,0,.83055],68:[0,.68611,0,0,.88194],69:[0,.68611,0,0,.75555],70:[0,.68611,0,0,.72361],71:[0,.68611,0,0,.90416],72:[0,.68611,0,0,.9],73:[0,.68611,0,0,.43611],74:[0,.68611,0,0,.59444],75:[0,.68611,0,0,.90138],76:[0,.68611,0,0,.69166],77:[0,.68611,0,0,1.09166],78:[0,.68611,0,0,.9],79:[0,.68611,0,0,.86388],80:[0,.68611,0,0,.78611],81:[.19444,.68611,0,0,.86388],82:[0,.68611,0,0,.8625],83:[0,.68611,0,0,.63889],84:[0,.68611,0,0,.8],85:[0,.68611,0,0,.88472],86:[0,.68611,.01597,0,.86944],87:[0,.68611,.01597,0,1.18888],88:[0,.68611,0,0,.86944],89:[0,.68611,.02875,0,.86944],90:[0,.68611,0,0,.70277],91:[.25,.75,0,0,.31944],92:[.25,.75,0,0,.575],93:[.25,.75,0,0,.31944],94:[0,.69444,0,0,.575],95:[.31,.13444,.03194,0,.575],97:[0,.44444,0,0,.55902],98:[0,.69444,0,0,.63889],99:[0,.44444,0,0,.51111],100:[0,.69444,0,0,.63889],101:[0,.44444,0,0,.52708],102:[0,.69444,.10903,0,.35139],103:[.19444,.44444,.01597,0,.575],104:[0,.69444,0,0,.63889],105:[0,.69444,0,0,.31944],106:[.19444,.69444,0,0,.35139],107:[0,.69444,0,0,.60694],108:[0,.69444,0,0,.31944],109:[0,.44444,0,0,.95833],110:[0,.44444,0,0,.63889],111:[0,.44444,0,0,.575],112:[.19444,.44444,0,0,.63889],113:[.19444,.44444,0,0,.60694],114:[0,.44444,0,0,.47361],115:[0,.44444,0,0,.45361],116:[0,.63492,0,0,.44722],117:[0,.44444,0,0,.63889],118:[0,.44444,.01597,0,.60694],119:[0,.44444,.01597,0,.83055],120:[0,.44444,0,0,.60694],121:[.19444,.44444,.01597,0,.60694],122:[0,.44444,0,0,.51111],123:[.25,.75,0,0,.575],124:[.25,.75,0,0,.31944],125:[.25,.75,0,0,.575],126:[.35,.34444,0,0,.575],160:[0,0,0,0,.25],163:[0,.69444,0,0,.86853],168:[0,.69444,0,0,.575],172:[0,.44444,0,0,.76666],176:[0,.69444,0,0,.86944],177:[.13333,.63333,0,0,.89444],184:[.17014,0,0,0,.51111],198:[0,.68611,0,0,1.04166],215:[.13333,.63333,0,0,.89444],216:[.04861,.73472,0,0,.89444],223:[0,.69444,0,0,.59722],230:[0,.44444,0,0,.83055],247:[.13333,.63333,0,0,.89444],248:[.09722,.54167,0,0,.575],305:[0,.44444,0,0,.31944],338:[0,.68611,0,0,1.16944],339:[0,.44444,0,0,.89444],567:[.19444,.44444,0,0,.35139],710:[0,.69444,0,0,.575],711:[0,.63194,0,0,.575],713:[0,.59611,0,0,.575],714:[0,.69444,0,0,.575],715:[0,.69444,0,0,.575],728:[0,.69444,0,0,.575],729:[0,.69444,0,0,.31944],730:[0,.69444,0,0,.86944],732:[0,.69444,0,0,.575],733:[0,.69444,0,0,.575],915:[0,.68611,0,0,.69166],916:[0,.68611,0,0,.95833],920:[0,.68611,0,0,.89444],923:[0,.68611,0,0,.80555],926:[0,.68611,0,0,.76666],928:[0,.68611,0,0,.9],931:[0,.68611,0,0,.83055],933:[0,.68611,0,0,.89444],934:[0,.68611,0,0,.83055],936:[0,.68611,0,0,.89444],937:[0,.68611,0,0,.83055],8211:[0,.44444,.03194,0,.575],8212:[0,.44444,.03194,0,1.14999],8216:[0,.69444,0,0,.31944],8217:[0,.69444,0,0,.31944],8220:[0,.69444,0,0,.60278],8221:[0,.69444,0,0,.60278],8224:[.19444,.69444,0,0,.51111],8225:[.19444,.69444,0,0,.51111],8242:[0,.55556,0,0,.34444],8407:[0,.72444,.15486,0,.575],8463:[0,.69444,0,0,.66759],8465:[0,.69444,0,0,.83055],8467:[0,.69444,0,0,.47361],8472:[.19444,.44444,0,0,.74027],8476:[0,.69444,0,0,.83055],8501:[0,.69444,0,0,.70277],8592:[-.10889,.39111,0,0,1.14999],8593:[.19444,.69444,0,0,.575],8594:[-.10889,.39111,0,0,1.14999],8595:[.19444,.69444,0,0,.575],8596:[-.10889,.39111,0,0,1.14999],8597:[.25,.75,0,0,.575],8598:[.19444,.69444,0,0,1.14999],8599:[.19444,.69444,0,0,1.14999],8600:[.19444,.69444,0,0,1.14999],8601:[.19444,.69444,0,0,1.14999],8636:[-.10889,.39111,0,0,1.14999],8637:[-.10889,.39111,0,0,1.14999],8640:[-.10889,.39111,0,0,1.14999],8641:[-.10889,.39111,0,0,1.14999],8656:[-.10889,.39111,0,0,1.14999],8657:[.19444,.69444,0,0,.70277],8658:[-.10889,.39111,0,0,1.14999],8659:[.19444,.69444,0,0,.70277],8660:[-.10889,.39111,0,0,1.14999],8661:[.25,.75,0,0,.70277],8704:[0,.69444,0,0,.63889],8706:[0,.69444,.06389,0,.62847],8707:[0,.69444,0,0,.63889],8709:[.05556,.75,0,0,.575],8711:[0,.68611,0,0,.95833],8712:[.08556,.58556,0,0,.76666],8715:[.08556,.58556,0,0,.76666],8722:[.13333,.63333,0,0,.89444],8723:[.13333,.63333,0,0,.89444],8725:[.25,.75,0,0,.575],8726:[.25,.75,0,0,.575],8727:[-.02778,.47222,0,0,.575],8728:[-.02639,.47361,0,0,.575],8729:[-.02639,.47361,0,0,.575],8730:[.18,.82,0,0,.95833],8733:[0,.44444,0,0,.89444],8734:[0,.44444,0,0,1.14999],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.31944],8741:[.25,.75,0,0,.575],8743:[0,.55556,0,0,.76666],8744:[0,.55556,0,0,.76666],8745:[0,.55556,0,0,.76666],8746:[0,.55556,0,0,.76666],8747:[.19444,.69444,.12778,0,.56875],8764:[-.10889,.39111,0,0,.89444],8768:[.19444,.69444,0,0,.31944],8771:[.00222,.50222,0,0,.89444],8773:[.027,.638,0,0,.894],8776:[.02444,.52444,0,0,.89444],8781:[.00222,.50222,0,0,.89444],8801:[.00222,.50222,0,0,.89444],8804:[.19667,.69667,0,0,.89444],8805:[.19667,.69667,0,0,.89444],8810:[.08556,.58556,0,0,1.14999],8811:[.08556,.58556,0,0,1.14999],8826:[.08556,.58556,0,0,.89444],8827:[.08556,.58556,0,0,.89444],8834:[.08556,.58556,0,0,.89444],8835:[.08556,.58556,0,0,.89444],8838:[.19667,.69667,0,0,.89444],8839:[.19667,.69667,0,0,.89444],8846:[0,.55556,0,0,.76666],8849:[.19667,.69667,0,0,.89444],8850:[.19667,.69667,0,0,.89444],8851:[0,.55556,0,0,.76666],8852:[0,.55556,0,0,.76666],8853:[.13333,.63333,0,0,.89444],8854:[.13333,.63333,0,0,.89444],8855:[.13333,.63333,0,0,.89444],8856:[.13333,.63333,0,0,.89444],8857:[.13333,.63333,0,0,.89444],8866:[0,.69444,0,0,.70277],8867:[0,.69444,0,0,.70277],8868:[0,.69444,0,0,.89444],8869:[0,.69444,0,0,.89444],8900:[-.02639,.47361,0,0,.575],8901:[-.02639,.47361,0,0,.31944],8902:[-.02778,.47222,0,0,.575],8968:[.25,.75,0,0,.51111],8969:[.25,.75,0,0,.51111],8970:[.25,.75,0,0,.51111],8971:[.25,.75,0,0,.51111],8994:[-.13889,.36111,0,0,1.14999],8995:[-.13889,.36111,0,0,1.14999],9651:[.19444,.69444,0,0,1.02222],9657:[-.02778,.47222,0,0,.575],9661:[.19444,.69444,0,0,1.02222],9667:[-.02778,.47222,0,0,.575],9711:[.19444,.69444,0,0,1.14999],9824:[.12963,.69444,0,0,.89444],9825:[.12963,.69444,0,0,.89444],9826:[.12963,.69444,0,0,.89444],9827:[.12963,.69444,0,0,.89444],9837:[0,.75,0,0,.44722],9838:[.19444,.69444,0,0,.44722],9839:[.19444,.69444,0,0,.44722],10216:[.25,.75,0,0,.44722],10217:[.25,.75,0,0,.44722],10815:[0,.68611,0,0,.9],10927:[.19667,.69667,0,0,.89444],10928:[.19667,.69667,0,0,.89444],57376:[.19444,.69444,0,0,0]},"Main-BoldItalic":{32:[0,0,0,0,.25],33:[0,.69444,.11417,0,.38611],34:[0,.69444,.07939,0,.62055],35:[.19444,.69444,.06833,0,.94444],37:[.05556,.75,.12861,0,.94444],38:[0,.69444,.08528,0,.88555],39:[0,.69444,.12945,0,.35555],40:[.25,.75,.15806,0,.47333],41:[.25,.75,.03306,0,.47333],42:[0,.75,.14333,0,.59111],43:[.10333,.60333,.03306,0,.88555],44:[.19444,.14722,0,0,.35555],45:[0,.44444,.02611,0,.41444],46:[0,.14722,0,0,.35555],47:[.25,.75,.15806,0,.59111],48:[0,.64444,.13167,0,.59111],49:[0,.64444,.13167,0,.59111],50:[0,.64444,.13167,0,.59111],51:[0,.64444,.13167,0,.59111],52:[.19444,.64444,.13167,0,.59111],53:[0,.64444,.13167,0,.59111],54:[0,.64444,.13167,0,.59111],55:[.19444,.64444,.13167,0,.59111],56:[0,.64444,.13167,0,.59111],57:[0,.64444,.13167,0,.59111],58:[0,.44444,.06695,0,.35555],59:[.19444,.44444,.06695,0,.35555],61:[-.10889,.39111,.06833,0,.88555],63:[0,.69444,.11472,0,.59111],64:[0,.69444,.09208,0,.88555],65:[0,.68611,0,0,.86555],66:[0,.68611,.0992,0,.81666],67:[0,.68611,.14208,0,.82666],68:[0,.68611,.09062,0,.87555],69:[0,.68611,.11431,0,.75666],70:[0,.68611,.12903,0,.72722],71:[0,.68611,.07347,0,.89527],72:[0,.68611,.17208,0,.8961],73:[0,.68611,.15681,0,.47166],74:[0,.68611,.145,0,.61055],75:[0,.68611,.14208,0,.89499],76:[0,.68611,0,0,.69777],77:[0,.68611,.17208,0,1.07277],78:[0,.68611,.17208,0,.8961],79:[0,.68611,.09062,0,.85499],80:[0,.68611,.0992,0,.78721],81:[.19444,.68611,.09062,0,.85499],82:[0,.68611,.02559,0,.85944],83:[0,.68611,.11264,0,.64999],84:[0,.68611,.12903,0,.7961],85:[0,.68611,.17208,0,.88083],86:[0,.68611,.18625,0,.86555],87:[0,.68611,.18625,0,1.15999],88:[0,.68611,.15681,0,.86555],89:[0,.68611,.19803,0,.86555],90:[0,.68611,.14208,0,.70888],91:[.25,.75,.1875,0,.35611],93:[.25,.75,.09972,0,.35611],94:[0,.69444,.06709,0,.59111],95:[.31,.13444,.09811,0,.59111],97:[0,.44444,.09426,0,.59111],98:[0,.69444,.07861,0,.53222],99:[0,.44444,.05222,0,.53222],100:[0,.69444,.10861,0,.59111],101:[0,.44444,.085,0,.53222],102:[.19444,.69444,.21778,0,.4],103:[.19444,.44444,.105,0,.53222],104:[0,.69444,.09426,0,.59111],105:[0,.69326,.11387,0,.35555],106:[.19444,.69326,.1672,0,.35555],107:[0,.69444,.11111,0,.53222],108:[0,.69444,.10861,0,.29666],109:[0,.44444,.09426,0,.94444],110:[0,.44444,.09426,0,.64999],111:[0,.44444,.07861,0,.59111],112:[.19444,.44444,.07861,0,.59111],113:[.19444,.44444,.105,0,.53222],114:[0,.44444,.11111,0,.50167],115:[0,.44444,.08167,0,.48694],116:[0,.63492,.09639,0,.385],117:[0,.44444,.09426,0,.62055],118:[0,.44444,.11111,0,.53222],119:[0,.44444,.11111,0,.76777],120:[0,.44444,.12583,0,.56055],121:[.19444,.44444,.105,0,.56166],122:[0,.44444,.13889,0,.49055],126:[.35,.34444,.11472,0,.59111],160:[0,0,0,0,.25],168:[0,.69444,.11473,0,.59111],176:[0,.69444,0,0,.94888],184:[.17014,0,0,0,.53222],198:[0,.68611,.11431,0,1.02277],216:[.04861,.73472,.09062,0,.88555],223:[.19444,.69444,.09736,0,.665],230:[0,.44444,.085,0,.82666],248:[.09722,.54167,.09458,0,.59111],305:[0,.44444,.09426,0,.35555],338:[0,.68611,.11431,0,1.14054],339:[0,.44444,.085,0,.82666],567:[.19444,.44444,.04611,0,.385],710:[0,.69444,.06709,0,.59111],711:[0,.63194,.08271,0,.59111],713:[0,.59444,.10444,0,.59111],714:[0,.69444,.08528,0,.59111],715:[0,.69444,0,0,.59111],728:[0,.69444,.10333,0,.59111],729:[0,.69444,.12945,0,.35555],730:[0,.69444,0,0,.94888],732:[0,.69444,.11472,0,.59111],733:[0,.69444,.11472,0,.59111],915:[0,.68611,.12903,0,.69777],916:[0,.68611,0,0,.94444],920:[0,.68611,.09062,0,.88555],923:[0,.68611,0,0,.80666],926:[0,.68611,.15092,0,.76777],928:[0,.68611,.17208,0,.8961],931:[0,.68611,.11431,0,.82666],933:[0,.68611,.10778,0,.88555],934:[0,.68611,.05632,0,.82666],936:[0,.68611,.10778,0,.88555],937:[0,.68611,.0992,0,.82666],8211:[0,.44444,.09811,0,.59111],8212:[0,.44444,.09811,0,1.18221],8216:[0,.69444,.12945,0,.35555],8217:[0,.69444,.12945,0,.35555],8220:[0,.69444,.16772,0,.62055],8221:[0,.69444,.07939,0,.62055]},"Main-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.12417,0,.30667],34:[0,.69444,.06961,0,.51444],35:[.19444,.69444,.06616,0,.81777],37:[.05556,.75,.13639,0,.81777],38:[0,.69444,.09694,0,.76666],39:[0,.69444,.12417,0,.30667],40:[.25,.75,.16194,0,.40889],41:[.25,.75,.03694,0,.40889],42:[0,.75,.14917,0,.51111],43:[.05667,.56167,.03694,0,.76666],44:[.19444,.10556,0,0,.30667],45:[0,.43056,.02826,0,.35778],46:[0,.10556,0,0,.30667],47:[.25,.75,.16194,0,.51111],48:[0,.64444,.13556,0,.51111],49:[0,.64444,.13556,0,.51111],50:[0,.64444,.13556,0,.51111],51:[0,.64444,.13556,0,.51111],52:[.19444,.64444,.13556,0,.51111],53:[0,.64444,.13556,0,.51111],54:[0,.64444,.13556,0,.51111],55:[.19444,.64444,.13556,0,.51111],56:[0,.64444,.13556,0,.51111],57:[0,.64444,.13556,0,.51111],58:[0,.43056,.0582,0,.30667],59:[.19444,.43056,.0582,0,.30667],61:[-.13313,.36687,.06616,0,.76666],63:[0,.69444,.1225,0,.51111],64:[0,.69444,.09597,0,.76666],65:[0,.68333,0,0,.74333],66:[0,.68333,.10257,0,.70389],67:[0,.68333,.14528,0,.71555],68:[0,.68333,.09403,0,.755],69:[0,.68333,.12028,0,.67833],70:[0,.68333,.13305,0,.65277],71:[0,.68333,.08722,0,.77361],72:[0,.68333,.16389,0,.74333],73:[0,.68333,.15806,0,.38555],74:[0,.68333,.14028,0,.525],75:[0,.68333,.14528,0,.76888],76:[0,.68333,0,0,.62722],77:[0,.68333,.16389,0,.89666],78:[0,.68333,.16389,0,.74333],79:[0,.68333,.09403,0,.76666],80:[0,.68333,.10257,0,.67833],81:[.19444,.68333,.09403,0,.76666],82:[0,.68333,.03868,0,.72944],83:[0,.68333,.11972,0,.56222],84:[0,.68333,.13305,0,.71555],85:[0,.68333,.16389,0,.74333],86:[0,.68333,.18361,0,.74333],87:[0,.68333,.18361,0,.99888],88:[0,.68333,.15806,0,.74333],89:[0,.68333,.19383,0,.74333],90:[0,.68333,.14528,0,.61333],91:[.25,.75,.1875,0,.30667],93:[.25,.75,.10528,0,.30667],94:[0,.69444,.06646,0,.51111],95:[.31,.12056,.09208,0,.51111],97:[0,.43056,.07671,0,.51111],98:[0,.69444,.06312,0,.46],99:[0,.43056,.05653,0,.46],100:[0,.69444,.10333,0,.51111],101:[0,.43056,.07514,0,.46],102:[.19444,.69444,.21194,0,.30667],103:[.19444,.43056,.08847,0,.46],104:[0,.69444,.07671,0,.51111],105:[0,.65536,.1019,0,.30667],106:[.19444,.65536,.14467,0,.30667],107:[0,.69444,.10764,0,.46],108:[0,.69444,.10333,0,.25555],109:[0,.43056,.07671,0,.81777],110:[0,.43056,.07671,0,.56222],111:[0,.43056,.06312,0,.51111],112:[.19444,.43056,.06312,0,.51111],113:[.19444,.43056,.08847,0,.46],114:[0,.43056,.10764,0,.42166],115:[0,.43056,.08208,0,.40889],116:[0,.61508,.09486,0,.33222],117:[0,.43056,.07671,0,.53666],118:[0,.43056,.10764,0,.46],119:[0,.43056,.10764,0,.66444],120:[0,.43056,.12042,0,.46389],121:[.19444,.43056,.08847,0,.48555],122:[0,.43056,.12292,0,.40889],126:[.35,.31786,.11585,0,.51111],160:[0,0,0,0,.25],168:[0,.66786,.10474,0,.51111],176:[0,.69444,0,0,.83129],184:[.17014,0,0,0,.46],198:[0,.68333,.12028,0,.88277],216:[.04861,.73194,.09403,0,.76666],223:[.19444,.69444,.10514,0,.53666],230:[0,.43056,.07514,0,.71555],248:[.09722,.52778,.09194,0,.51111],338:[0,.68333,.12028,0,.98499],339:[0,.43056,.07514,0,.71555],710:[0,.69444,.06646,0,.51111],711:[0,.62847,.08295,0,.51111],713:[0,.56167,.10333,0,.51111],714:[0,.69444,.09694,0,.51111],715:[0,.69444,0,0,.51111],728:[0,.69444,.10806,0,.51111],729:[0,.66786,.11752,0,.30667],730:[0,.69444,0,0,.83129],732:[0,.66786,.11585,0,.51111],733:[0,.69444,.1225,0,.51111],915:[0,.68333,.13305,0,.62722],916:[0,.68333,0,0,.81777],920:[0,.68333,.09403,0,.76666],923:[0,.68333,0,0,.69222],926:[0,.68333,.15294,0,.66444],928:[0,.68333,.16389,0,.74333],931:[0,.68333,.12028,0,.71555],933:[0,.68333,.11111,0,.76666],934:[0,.68333,.05986,0,.71555],936:[0,.68333,.11111,0,.76666],937:[0,.68333,.10257,0,.71555],8211:[0,.43056,.09208,0,.51111],8212:[0,.43056,.09208,0,1.02222],8216:[0,.69444,.12417,0,.30667],8217:[0,.69444,.12417,0,.30667],8220:[0,.69444,.1685,0,.51444],8221:[0,.69444,.06961,0,.51444],8463:[0,.68889,0,0,.54028]},"Main-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.27778],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.77778],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.19444,.10556,0,0,.27778],45:[0,.43056,0,0,.33333],46:[0,.10556,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.64444,0,0,.5],49:[0,.64444,0,0,.5],50:[0,.64444,0,0,.5],51:[0,.64444,0,0,.5],52:[0,.64444,0,0,.5],53:[0,.64444,0,0,.5],54:[0,.64444,0,0,.5],55:[0,.64444,0,0,.5],56:[0,.64444,0,0,.5],57:[0,.64444,0,0,.5],58:[0,.43056,0,0,.27778],59:[.19444,.43056,0,0,.27778],60:[.0391,.5391,0,0,.77778],61:[-.13313,.36687,0,0,.77778],62:[.0391,.5391,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.77778],65:[0,.68333,0,0,.75],66:[0,.68333,0,0,.70834],67:[0,.68333,0,0,.72222],68:[0,.68333,0,0,.76389],69:[0,.68333,0,0,.68056],70:[0,.68333,0,0,.65278],71:[0,.68333,0,0,.78472],72:[0,.68333,0,0,.75],73:[0,.68333,0,0,.36111],74:[0,.68333,0,0,.51389],75:[0,.68333,0,0,.77778],76:[0,.68333,0,0,.625],77:[0,.68333,0,0,.91667],78:[0,.68333,0,0,.75],79:[0,.68333,0,0,.77778],80:[0,.68333,0,0,.68056],81:[.19444,.68333,0,0,.77778],82:[0,.68333,0,0,.73611],83:[0,.68333,0,0,.55556],84:[0,.68333,0,0,.72222],85:[0,.68333,0,0,.75],86:[0,.68333,.01389,0,.75],87:[0,.68333,.01389,0,1.02778],88:[0,.68333,0,0,.75],89:[0,.68333,.025,0,.75],90:[0,.68333,0,0,.61111],91:[.25,.75,0,0,.27778],92:[.25,.75,0,0,.5],93:[.25,.75,0,0,.27778],94:[0,.69444,0,0,.5],95:[.31,.12056,.02778,0,.5],97:[0,.43056,0,0,.5],98:[0,.69444,0,0,.55556],99:[0,.43056,0,0,.44445],100:[0,.69444,0,0,.55556],101:[0,.43056,0,0,.44445],102:[0,.69444,.07778,0,.30556],103:[.19444,.43056,.01389,0,.5],104:[0,.69444,0,0,.55556],105:[0,.66786,0,0,.27778],106:[.19444,.66786,0,0,.30556],107:[0,.69444,0,0,.52778],108:[0,.69444,0,0,.27778],109:[0,.43056,0,0,.83334],110:[0,.43056,0,0,.55556],111:[0,.43056,0,0,.5],112:[.19444,.43056,0,0,.55556],113:[.19444,.43056,0,0,.52778],114:[0,.43056,0,0,.39167],115:[0,.43056,0,0,.39445],116:[0,.61508,0,0,.38889],117:[0,.43056,0,0,.55556],118:[0,.43056,.01389,0,.52778],119:[0,.43056,.01389,0,.72222],120:[0,.43056,0,0,.52778],121:[.19444,.43056,.01389,0,.52778],122:[0,.43056,0,0,.44445],123:[.25,.75,0,0,.5],124:[.25,.75,0,0,.27778],125:[.25,.75,0,0,.5],126:[.35,.31786,0,0,.5],160:[0,0,0,0,.25],163:[0,.69444,0,0,.76909],167:[.19444,.69444,0,0,.44445],168:[0,.66786,0,0,.5],172:[0,.43056,0,0,.66667],176:[0,.69444,0,0,.75],177:[.08333,.58333,0,0,.77778],182:[.19444,.69444,0,0,.61111],184:[.17014,0,0,0,.44445],198:[0,.68333,0,0,.90278],215:[.08333,.58333,0,0,.77778],216:[.04861,.73194,0,0,.77778],223:[0,.69444,0,0,.5],230:[0,.43056,0,0,.72222],247:[.08333,.58333,0,0,.77778],248:[.09722,.52778,0,0,.5],305:[0,.43056,0,0,.27778],338:[0,.68333,0,0,1.01389],339:[0,.43056,0,0,.77778],567:[.19444,.43056,0,0,.30556],710:[0,.69444,0,0,.5],711:[0,.62847,0,0,.5],713:[0,.56778,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.66786,0,0,.27778],730:[0,.69444,0,0,.75],732:[0,.66786,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.68333,0,0,.625],916:[0,.68333,0,0,.83334],920:[0,.68333,0,0,.77778],923:[0,.68333,0,0,.69445],926:[0,.68333,0,0,.66667],928:[0,.68333,0,0,.75],931:[0,.68333,0,0,.72222],933:[0,.68333,0,0,.77778],934:[0,.68333,0,0,.72222],936:[0,.68333,0,0,.77778],937:[0,.68333,0,0,.72222],8211:[0,.43056,.02778,0,.5],8212:[0,.43056,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5],8224:[.19444,.69444,0,0,.44445],8225:[.19444,.69444,0,0,.44445],8230:[0,.123,0,0,1.172],8242:[0,.55556,0,0,.275],8407:[0,.71444,.15382,0,.5],8463:[0,.68889,0,0,.54028],8465:[0,.69444,0,0,.72222],8467:[0,.69444,0,.11111,.41667],8472:[.19444,.43056,0,.11111,.63646],8476:[0,.69444,0,0,.72222],8501:[0,.69444,0,0,.61111],8592:[-.13313,.36687,0,0,1],8593:[.19444,.69444,0,0,.5],8594:[-.13313,.36687,0,0,1],8595:[.19444,.69444,0,0,.5],8596:[-.13313,.36687,0,0,1],8597:[.25,.75,0,0,.5],8598:[.19444,.69444,0,0,1],8599:[.19444,.69444,0,0,1],8600:[.19444,.69444,0,0,1],8601:[.19444,.69444,0,0,1],8614:[.011,.511,0,0,1],8617:[.011,.511,0,0,1.126],8618:[.011,.511,0,0,1.126],8636:[-.13313,.36687,0,0,1],8637:[-.13313,.36687,0,0,1],8640:[-.13313,.36687,0,0,1],8641:[-.13313,.36687,0,0,1],8652:[.011,.671,0,0,1],8656:[-.13313,.36687,0,0,1],8657:[.19444,.69444,0,0,.61111],8658:[-.13313,.36687,0,0,1],8659:[.19444,.69444,0,0,.61111],8660:[-.13313,.36687,0,0,1],8661:[.25,.75,0,0,.61111],8704:[0,.69444,0,0,.55556],8706:[0,.69444,.05556,.08334,.5309],8707:[0,.69444,0,0,.55556],8709:[.05556,.75,0,0,.5],8711:[0,.68333,0,0,.83334],8712:[.0391,.5391,0,0,.66667],8715:[.0391,.5391,0,0,.66667],8722:[.08333,.58333,0,0,.77778],8723:[.08333,.58333,0,0,.77778],8725:[.25,.75,0,0,.5],8726:[.25,.75,0,0,.5],8727:[-.03472,.46528,0,0,.5],8728:[-.05555,.44445,0,0,.5],8729:[-.05555,.44445,0,0,.5],8730:[.2,.8,0,0,.83334],8733:[0,.43056,0,0,.77778],8734:[0,.43056,0,0,1],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.27778],8741:[.25,.75,0,0,.5],8743:[0,.55556,0,0,.66667],8744:[0,.55556,0,0,.66667],8745:[0,.55556,0,0,.66667],8746:[0,.55556,0,0,.66667],8747:[.19444,.69444,.11111,0,.41667],8764:[-.13313,.36687,0,0,.77778],8768:[.19444,.69444,0,0,.27778],8771:[-.03625,.46375,0,0,.77778],8773:[-.022,.589,0,0,.778],8776:[-.01688,.48312,0,0,.77778],8781:[-.03625,.46375,0,0,.77778],8784:[-.133,.673,0,0,.778],8801:[-.03625,.46375,0,0,.77778],8804:[.13597,.63597,0,0,.77778],8805:[.13597,.63597,0,0,.77778],8810:[.0391,.5391,0,0,1],8811:[.0391,.5391,0,0,1],8826:[.0391,.5391,0,0,.77778],8827:[.0391,.5391,0,0,.77778],8834:[.0391,.5391,0,0,.77778],8835:[.0391,.5391,0,0,.77778],8838:[.13597,.63597,0,0,.77778],8839:[.13597,.63597,0,0,.77778],8846:[0,.55556,0,0,.66667],8849:[.13597,.63597,0,0,.77778],8850:[.13597,.63597,0,0,.77778],8851:[0,.55556,0,0,.66667],8852:[0,.55556,0,0,.66667],8853:[.08333,.58333,0,0,.77778],8854:[.08333,.58333,0,0,.77778],8855:[.08333,.58333,0,0,.77778],8856:[.08333,.58333,0,0,.77778],8857:[.08333,.58333,0,0,.77778],8866:[0,.69444,0,0,.61111],8867:[0,.69444,0,0,.61111],8868:[0,.69444,0,0,.77778],8869:[0,.69444,0,0,.77778],8872:[.249,.75,0,0,.867],8900:[-.05555,.44445,0,0,.5],8901:[-.05555,.44445,0,0,.27778],8902:[-.03472,.46528,0,0,.5],8904:[.005,.505,0,0,.9],8942:[.03,.903,0,0,.278],8943:[-.19,.313,0,0,1.172],8945:[-.1,.823,0,0,1.282],8968:[.25,.75,0,0,.44445],8969:[.25,.75,0,0,.44445],8970:[.25,.75,0,0,.44445],8971:[.25,.75,0,0,.44445],8994:[-.14236,.35764,0,0,1],8995:[-.14236,.35764,0,0,1],9136:[.244,.744,0,0,.412],9137:[.244,.745,0,0,.412],9651:[.19444,.69444,0,0,.88889],9657:[-.03472,.46528,0,0,.5],9661:[.19444,.69444,0,0,.88889],9667:[-.03472,.46528,0,0,.5],9711:[.19444,.69444,0,0,1],9824:[.12963,.69444,0,0,.77778],9825:[.12963,.69444,0,0,.77778],9826:[.12963,.69444,0,0,.77778],9827:[.12963,.69444,0,0,.77778],9837:[0,.75,0,0,.38889],9838:[.19444,.69444,0,0,.38889],9839:[.19444,.69444,0,0,.38889],10216:[.25,.75,0,0,.38889],10217:[.25,.75,0,0,.38889],10222:[.244,.744,0,0,.412],10223:[.244,.745,0,0,.412],10229:[.011,.511,0,0,1.609],10230:[.011,.511,0,0,1.638],10231:[.011,.511,0,0,1.859],10232:[.024,.525,0,0,1.609],10233:[.024,.525,0,0,1.638],10234:[.024,.525,0,0,1.858],10236:[.011,.511,0,0,1.638],10815:[0,.68333,0,0,.75],10927:[.13597,.63597,0,0,.77778],10928:[.13597,.63597,0,0,.77778],57376:[.19444,.69444,0,0,0]},"Math-BoldItalic":{32:[0,0,0,0,.25],48:[0,.44444,0,0,.575],49:[0,.44444,0,0,.575],50:[0,.44444,0,0,.575],51:[.19444,.44444,0,0,.575],52:[.19444,.44444,0,0,.575],53:[.19444,.44444,0,0,.575],54:[0,.64444,0,0,.575],55:[.19444,.44444,0,0,.575],56:[0,.64444,0,0,.575],57:[.19444,.44444,0,0,.575],65:[0,.68611,0,0,.86944],66:[0,.68611,.04835,0,.8664],67:[0,.68611,.06979,0,.81694],68:[0,.68611,.03194,0,.93812],69:[0,.68611,.05451,0,.81007],70:[0,.68611,.15972,0,.68889],71:[0,.68611,0,0,.88673],72:[0,.68611,.08229,0,.98229],73:[0,.68611,.07778,0,.51111],74:[0,.68611,.10069,0,.63125],75:[0,.68611,.06979,0,.97118],76:[0,.68611,0,0,.75555],77:[0,.68611,.11424,0,1.14201],78:[0,.68611,.11424,0,.95034],79:[0,.68611,.03194,0,.83666],80:[0,.68611,.15972,0,.72309],81:[.19444,.68611,0,0,.86861],82:[0,.68611,.00421,0,.87235],83:[0,.68611,.05382,0,.69271],84:[0,.68611,.15972,0,.63663],85:[0,.68611,.11424,0,.80027],86:[0,.68611,.25555,0,.67778],87:[0,.68611,.15972,0,1.09305],88:[0,.68611,.07778,0,.94722],89:[0,.68611,.25555,0,.67458],90:[0,.68611,.06979,0,.77257],97:[0,.44444,0,0,.63287],98:[0,.69444,0,0,.52083],99:[0,.44444,0,0,.51342],100:[0,.69444,0,0,.60972],101:[0,.44444,0,0,.55361],102:[.19444,.69444,.11042,0,.56806],103:[.19444,.44444,.03704,0,.5449],104:[0,.69444,0,0,.66759],105:[0,.69326,0,0,.4048],106:[.19444,.69326,.0622,0,.47083],107:[0,.69444,.01852,0,.6037],108:[0,.69444,.0088,0,.34815],109:[0,.44444,0,0,1.0324],110:[0,.44444,0,0,.71296],111:[0,.44444,0,0,.58472],112:[.19444,.44444,0,0,.60092],113:[.19444,.44444,.03704,0,.54213],114:[0,.44444,.03194,0,.5287],115:[0,.44444,0,0,.53125],116:[0,.63492,0,0,.41528],117:[0,.44444,0,0,.68102],118:[0,.44444,.03704,0,.56666],119:[0,.44444,.02778,0,.83148],120:[0,.44444,0,0,.65903],121:[.19444,.44444,.03704,0,.59028],122:[0,.44444,.04213,0,.55509],160:[0,0,0,0,.25],915:[0,.68611,.15972,0,.65694],916:[0,.68611,0,0,.95833],920:[0,.68611,.03194,0,.86722],923:[0,.68611,0,0,.80555],926:[0,.68611,.07458,0,.84125],928:[0,.68611,.08229,0,.98229],931:[0,.68611,.05451,0,.88507],933:[0,.68611,.15972,0,.67083],934:[0,.68611,0,0,.76666],936:[0,.68611,.11653,0,.71402],937:[0,.68611,.04835,0,.8789],945:[0,.44444,0,0,.76064],946:[.19444,.69444,.03403,0,.65972],947:[.19444,.44444,.06389,0,.59003],948:[0,.69444,.03819,0,.52222],949:[0,.44444,0,0,.52882],950:[.19444,.69444,.06215,0,.50833],951:[.19444,.44444,.03704,0,.6],952:[0,.69444,.03194,0,.5618],953:[0,.44444,0,0,.41204],954:[0,.44444,0,0,.66759],955:[0,.69444,0,0,.67083],956:[.19444,.44444,0,0,.70787],957:[0,.44444,.06898,0,.57685],958:[.19444,.69444,.03021,0,.50833],959:[0,.44444,0,0,.58472],960:[0,.44444,.03704,0,.68241],961:[.19444,.44444,0,0,.6118],962:[.09722,.44444,.07917,0,.42361],963:[0,.44444,.03704,0,.68588],964:[0,.44444,.13472,0,.52083],965:[0,.44444,.03704,0,.63055],966:[.19444,.44444,0,0,.74722],967:[.19444,.44444,0,0,.71805],968:[.19444,.69444,.03704,0,.75833],969:[0,.44444,.03704,0,.71782],977:[0,.69444,0,0,.69155],981:[.19444,.69444,0,0,.7125],982:[0,.44444,.03194,0,.975],1009:[.19444,.44444,0,0,.6118],1013:[0,.44444,0,0,.48333],57649:[0,.44444,0,0,.39352],57911:[.19444,.44444,0,0,.43889]},"Math-Italic":{32:[0,0,0,0,.25],48:[0,.43056,0,0,.5],49:[0,.43056,0,0,.5],50:[0,.43056,0,0,.5],51:[.19444,.43056,0,0,.5],52:[.19444,.43056,0,0,.5],53:[.19444,.43056,0,0,.5],54:[0,.64444,0,0,.5],55:[.19444,.43056,0,0,.5],56:[0,.64444,0,0,.5],57:[.19444,.43056,0,0,.5],65:[0,.68333,0,.13889,.75],66:[0,.68333,.05017,.08334,.75851],67:[0,.68333,.07153,.08334,.71472],68:[0,.68333,.02778,.05556,.82792],69:[0,.68333,.05764,.08334,.7382],70:[0,.68333,.13889,.08334,.64306],71:[0,.68333,0,.08334,.78625],72:[0,.68333,.08125,.05556,.83125],73:[0,.68333,.07847,.11111,.43958],74:[0,.68333,.09618,.16667,.55451],75:[0,.68333,.07153,.05556,.84931],76:[0,.68333,0,.02778,.68056],77:[0,.68333,.10903,.08334,.97014],78:[0,.68333,.10903,.08334,.80347],79:[0,.68333,.02778,.08334,.76278],80:[0,.68333,.13889,.08334,.64201],81:[.19444,.68333,0,.08334,.79056],82:[0,.68333,.00773,.08334,.75929],83:[0,.68333,.05764,.08334,.6132],84:[0,.68333,.13889,.08334,.58438],85:[0,.68333,.10903,.02778,.68278],86:[0,.68333,.22222,0,.58333],87:[0,.68333,.13889,0,.94445],88:[0,.68333,.07847,.08334,.82847],89:[0,.68333,.22222,0,.58056],90:[0,.68333,.07153,.08334,.68264],97:[0,.43056,0,0,.52859],98:[0,.69444,0,0,.42917],99:[0,.43056,0,.05556,.43276],100:[0,.69444,0,.16667,.52049],101:[0,.43056,0,.05556,.46563],102:[.19444,.69444,.10764,.16667,.48959],103:[.19444,.43056,.03588,.02778,.47697],104:[0,.69444,0,0,.57616],105:[0,.65952,0,0,.34451],106:[.19444,.65952,.05724,0,.41181],107:[0,.69444,.03148,0,.5206],108:[0,.69444,.01968,.08334,.29838],109:[0,.43056,0,0,.87801],110:[0,.43056,0,0,.60023],111:[0,.43056,0,.05556,.48472],112:[.19444,.43056,0,.08334,.50313],113:[.19444,.43056,.03588,.08334,.44641],114:[0,.43056,.02778,.05556,.45116],115:[0,.43056,0,.05556,.46875],116:[0,.61508,0,.08334,.36111],117:[0,.43056,0,.02778,.57246],118:[0,.43056,.03588,.02778,.48472],119:[0,.43056,.02691,.08334,.71592],120:[0,.43056,0,.02778,.57153],121:[.19444,.43056,.03588,.05556,.49028],122:[0,.43056,.04398,.05556,.46505],160:[0,0,0,0,.25],915:[0,.68333,.13889,.08334,.61528],916:[0,.68333,0,.16667,.83334],920:[0,.68333,.02778,.08334,.76278],923:[0,.68333,0,.16667,.69445],926:[0,.68333,.07569,.08334,.74236],928:[0,.68333,.08125,.05556,.83125],931:[0,.68333,.05764,.08334,.77986],933:[0,.68333,.13889,.05556,.58333],934:[0,.68333,0,.08334,.66667],936:[0,.68333,.11,.05556,.61222],937:[0,.68333,.05017,.08334,.7724],945:[0,.43056,.0037,.02778,.6397],946:[.19444,.69444,.05278,.08334,.56563],947:[.19444,.43056,.05556,0,.51773],948:[0,.69444,.03785,.05556,.44444],949:[0,.43056,0,.08334,.46632],950:[.19444,.69444,.07378,.08334,.4375],951:[.19444,.43056,.03588,.05556,.49653],952:[0,.69444,.02778,.08334,.46944],953:[0,.43056,0,.05556,.35394],954:[0,.43056,0,0,.57616],955:[0,.69444,0,0,.58334],956:[.19444,.43056,0,.02778,.60255],957:[0,.43056,.06366,.02778,.49398],958:[.19444,.69444,.04601,.11111,.4375],959:[0,.43056,0,.05556,.48472],960:[0,.43056,.03588,0,.57003],961:[.19444,.43056,0,.08334,.51702],962:[.09722,.43056,.07986,.08334,.36285],963:[0,.43056,.03588,0,.57141],964:[0,.43056,.1132,.02778,.43715],965:[0,.43056,.03588,.02778,.54028],966:[.19444,.43056,0,.08334,.65417],967:[.19444,.43056,0,.05556,.62569],968:[.19444,.69444,.03588,.11111,.65139],969:[0,.43056,.03588,0,.62245],977:[0,.69444,0,.08334,.59144],981:[.19444,.69444,0,.08334,.59583],982:[0,.43056,.02778,0,.82813],1009:[.19444,.43056,0,.08334,.51702],1013:[0,.43056,0,.05556,.4059],57649:[0,.43056,0,.02778,.32246],57911:[.19444,.43056,0,.08334,.38403]},"SansSerif-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.36667],34:[0,.69444,0,0,.55834],35:[.19444,.69444,0,0,.91667],36:[.05556,.75,0,0,.55],37:[.05556,.75,0,0,1.02912],38:[0,.69444,0,0,.83056],39:[0,.69444,0,0,.30556],40:[.25,.75,0,0,.42778],41:[.25,.75,0,0,.42778],42:[0,.75,0,0,.55],43:[.11667,.61667,0,0,.85556],44:[.10556,.13056,0,0,.30556],45:[0,.45833,0,0,.36667],46:[0,.13056,0,0,.30556],47:[.25,.75,0,0,.55],48:[0,.69444,0,0,.55],49:[0,.69444,0,0,.55],50:[0,.69444,0,0,.55],51:[0,.69444,0,0,.55],52:[0,.69444,0,0,.55],53:[0,.69444,0,0,.55],54:[0,.69444,0,0,.55],55:[0,.69444,0,0,.55],56:[0,.69444,0,0,.55],57:[0,.69444,0,0,.55],58:[0,.45833,0,0,.30556],59:[.10556,.45833,0,0,.30556],61:[-.09375,.40625,0,0,.85556],63:[0,.69444,0,0,.51945],64:[0,.69444,0,0,.73334],65:[0,.69444,0,0,.73334],66:[0,.69444,0,0,.73334],67:[0,.69444,0,0,.70278],68:[0,.69444,0,0,.79445],69:[0,.69444,0,0,.64167],70:[0,.69444,0,0,.61111],71:[0,.69444,0,0,.73334],72:[0,.69444,0,0,.79445],73:[0,.69444,0,0,.33056],74:[0,.69444,0,0,.51945],75:[0,.69444,0,0,.76389],76:[0,.69444,0,0,.58056],77:[0,.69444,0,0,.97778],78:[0,.69444,0,0,.79445],79:[0,.69444,0,0,.79445],80:[0,.69444,0,0,.70278],81:[.10556,.69444,0,0,.79445],82:[0,.69444,0,0,.70278],83:[0,.69444,0,0,.61111],84:[0,.69444,0,0,.73334],85:[0,.69444,0,0,.76389],86:[0,.69444,.01528,0,.73334],87:[0,.69444,.01528,0,1.03889],88:[0,.69444,0,0,.73334],89:[0,.69444,.0275,0,.73334],90:[0,.69444,0,0,.67223],91:[.25,.75,0,0,.34306],93:[.25,.75,0,0,.34306],94:[0,.69444,0,0,.55],95:[.35,.10833,.03056,0,.55],97:[0,.45833,0,0,.525],98:[0,.69444,0,0,.56111],99:[0,.45833,0,0,.48889],100:[0,.69444,0,0,.56111],101:[0,.45833,0,0,.51111],102:[0,.69444,.07639,0,.33611],103:[.19444,.45833,.01528,0,.55],104:[0,.69444,0,0,.56111],105:[0,.69444,0,0,.25556],106:[.19444,.69444,0,0,.28611],107:[0,.69444,0,0,.53056],108:[0,.69444,0,0,.25556],109:[0,.45833,0,0,.86667],110:[0,.45833,0,0,.56111],111:[0,.45833,0,0,.55],112:[.19444,.45833,0,0,.56111],113:[.19444,.45833,0,0,.56111],114:[0,.45833,.01528,0,.37222],115:[0,.45833,0,0,.42167],116:[0,.58929,0,0,.40417],117:[0,.45833,0,0,.56111],118:[0,.45833,.01528,0,.5],119:[0,.45833,.01528,0,.74445],120:[0,.45833,0,0,.5],121:[.19444,.45833,.01528,0,.5],122:[0,.45833,0,0,.47639],126:[.35,.34444,0,0,.55],160:[0,0,0,0,.25],168:[0,.69444,0,0,.55],176:[0,.69444,0,0,.73334],180:[0,.69444,0,0,.55],184:[.17014,0,0,0,.48889],305:[0,.45833,0,0,.25556],567:[.19444,.45833,0,0,.28611],710:[0,.69444,0,0,.55],711:[0,.63542,0,0,.55],713:[0,.63778,0,0,.55],728:[0,.69444,0,0,.55],729:[0,.69444,0,0,.30556],730:[0,.69444,0,0,.73334],732:[0,.69444,0,0,.55],733:[0,.69444,0,0,.55],915:[0,.69444,0,0,.58056],916:[0,.69444,0,0,.91667],920:[0,.69444,0,0,.85556],923:[0,.69444,0,0,.67223],926:[0,.69444,0,0,.73334],928:[0,.69444,0,0,.79445],931:[0,.69444,0,0,.79445],933:[0,.69444,0,0,.85556],934:[0,.69444,0,0,.79445],936:[0,.69444,0,0,.85556],937:[0,.69444,0,0,.79445],8211:[0,.45833,.03056,0,.55],8212:[0,.45833,.03056,0,1.10001],8216:[0,.69444,0,0,.30556],8217:[0,.69444,0,0,.30556],8220:[0,.69444,0,0,.55834],8221:[0,.69444,0,0,.55834]},"SansSerif-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.05733,0,.31945],34:[0,.69444,.00316,0,.5],35:[.19444,.69444,.05087,0,.83334],36:[.05556,.75,.11156,0,.5],37:[.05556,.75,.03126,0,.83334],38:[0,.69444,.03058,0,.75834],39:[0,.69444,.07816,0,.27778],40:[.25,.75,.13164,0,.38889],41:[.25,.75,.02536,0,.38889],42:[0,.75,.11775,0,.5],43:[.08333,.58333,.02536,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,.01946,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,.13164,0,.5],48:[0,.65556,.11156,0,.5],49:[0,.65556,.11156,0,.5],50:[0,.65556,.11156,0,.5],51:[0,.65556,.11156,0,.5],52:[0,.65556,.11156,0,.5],53:[0,.65556,.11156,0,.5],54:[0,.65556,.11156,0,.5],55:[0,.65556,.11156,0,.5],56:[0,.65556,.11156,0,.5],57:[0,.65556,.11156,0,.5],58:[0,.44444,.02502,0,.27778],59:[.125,.44444,.02502,0,.27778],61:[-.13,.37,.05087,0,.77778],63:[0,.69444,.11809,0,.47222],64:[0,.69444,.07555,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,.08293,0,.66667],67:[0,.69444,.11983,0,.63889],68:[0,.69444,.07555,0,.72223],69:[0,.69444,.11983,0,.59722],70:[0,.69444,.13372,0,.56945],71:[0,.69444,.11983,0,.66667],72:[0,.69444,.08094,0,.70834],73:[0,.69444,.13372,0,.27778],74:[0,.69444,.08094,0,.47222],75:[0,.69444,.11983,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,.08094,0,.875],78:[0,.69444,.08094,0,.70834],79:[0,.69444,.07555,0,.73611],80:[0,.69444,.08293,0,.63889],81:[.125,.69444,.07555,0,.73611],82:[0,.69444,.08293,0,.64584],83:[0,.69444,.09205,0,.55556],84:[0,.69444,.13372,0,.68056],85:[0,.69444,.08094,0,.6875],86:[0,.69444,.1615,0,.66667],87:[0,.69444,.1615,0,.94445],88:[0,.69444,.13372,0,.66667],89:[0,.69444,.17261,0,.66667],90:[0,.69444,.11983,0,.61111],91:[.25,.75,.15942,0,.28889],93:[.25,.75,.08719,0,.28889],94:[0,.69444,.0799,0,.5],95:[.35,.09444,.08616,0,.5],97:[0,.44444,.00981,0,.48056],98:[0,.69444,.03057,0,.51667],99:[0,.44444,.08336,0,.44445],100:[0,.69444,.09483,0,.51667],101:[0,.44444,.06778,0,.44445],102:[0,.69444,.21705,0,.30556],103:[.19444,.44444,.10836,0,.5],104:[0,.69444,.01778,0,.51667],105:[0,.67937,.09718,0,.23889],106:[.19444,.67937,.09162,0,.26667],107:[0,.69444,.08336,0,.48889],108:[0,.69444,.09483,0,.23889],109:[0,.44444,.01778,0,.79445],110:[0,.44444,.01778,0,.51667],111:[0,.44444,.06613,0,.5],112:[.19444,.44444,.0389,0,.51667],113:[.19444,.44444,.04169,0,.51667],114:[0,.44444,.10836,0,.34167],115:[0,.44444,.0778,0,.38333],116:[0,.57143,.07225,0,.36111],117:[0,.44444,.04169,0,.51667],118:[0,.44444,.10836,0,.46111],119:[0,.44444,.10836,0,.68334],120:[0,.44444,.09169,0,.46111],121:[.19444,.44444,.10836,0,.46111],122:[0,.44444,.08752,0,.43472],126:[.35,.32659,.08826,0,.5],160:[0,0,0,0,.25],168:[0,.67937,.06385,0,.5],176:[0,.69444,0,0,.73752],184:[.17014,0,0,0,.44445],305:[0,.44444,.04169,0,.23889],567:[.19444,.44444,.04169,0,.26667],710:[0,.69444,.0799,0,.5],711:[0,.63194,.08432,0,.5],713:[0,.60889,.08776,0,.5],714:[0,.69444,.09205,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,.09483,0,.5],729:[0,.67937,.07774,0,.27778],730:[0,.69444,0,0,.73752],732:[0,.67659,.08826,0,.5],733:[0,.69444,.09205,0,.5],915:[0,.69444,.13372,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,.07555,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,.12816,0,.66667],928:[0,.69444,.08094,0,.70834],931:[0,.69444,.11983,0,.72222],933:[0,.69444,.09031,0,.77778],934:[0,.69444,.04603,0,.72222],936:[0,.69444,.09031,0,.77778],937:[0,.69444,.08293,0,.72222],8211:[0,.44444,.08616,0,.5],8212:[0,.44444,.08616,0,1],8216:[0,.69444,.07816,0,.27778],8217:[0,.69444,.07816,0,.27778],8220:[0,.69444,.14205,0,.5],8221:[0,.69444,.00316,0,.5]},"SansSerif-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.31945],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.75834],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,0,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.65556,0,0,.5],49:[0,.65556,0,0,.5],50:[0,.65556,0,0,.5],51:[0,.65556,0,0,.5],52:[0,.65556,0,0,.5],53:[0,.65556,0,0,.5],54:[0,.65556,0,0,.5],55:[0,.65556,0,0,.5],56:[0,.65556,0,0,.5],57:[0,.65556,0,0,.5],58:[0,.44444,0,0,.27778],59:[.125,.44444,0,0,.27778],61:[-.13,.37,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,0,0,.66667],67:[0,.69444,0,0,.63889],68:[0,.69444,0,0,.72223],69:[0,.69444,0,0,.59722],70:[0,.69444,0,0,.56945],71:[0,.69444,0,0,.66667],72:[0,.69444,0,0,.70834],73:[0,.69444,0,0,.27778],74:[0,.69444,0,0,.47222],75:[0,.69444,0,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,0,0,.875],78:[0,.69444,0,0,.70834],79:[0,.69444,0,0,.73611],80:[0,.69444,0,0,.63889],81:[.125,.69444,0,0,.73611],82:[0,.69444,0,0,.64584],83:[0,.69444,0,0,.55556],84:[0,.69444,0,0,.68056],85:[0,.69444,0,0,.6875],86:[0,.69444,.01389,0,.66667],87:[0,.69444,.01389,0,.94445],88:[0,.69444,0,0,.66667],89:[0,.69444,.025,0,.66667],90:[0,.69444,0,0,.61111],91:[.25,.75,0,0,.28889],93:[.25,.75,0,0,.28889],94:[0,.69444,0,0,.5],95:[.35,.09444,.02778,0,.5],97:[0,.44444,0,0,.48056],98:[0,.69444,0,0,.51667],99:[0,.44444,0,0,.44445],100:[0,.69444,0,0,.51667],101:[0,.44444,0,0,.44445],102:[0,.69444,.06944,0,.30556],103:[.19444,.44444,.01389,0,.5],104:[0,.69444,0,0,.51667],105:[0,.67937,0,0,.23889],106:[.19444,.67937,0,0,.26667],107:[0,.69444,0,0,.48889],108:[0,.69444,0,0,.23889],109:[0,.44444,0,0,.79445],110:[0,.44444,0,0,.51667],111:[0,.44444,0,0,.5],112:[.19444,.44444,0,0,.51667],113:[.19444,.44444,0,0,.51667],114:[0,.44444,.01389,0,.34167],115:[0,.44444,0,0,.38333],116:[0,.57143,0,0,.36111],117:[0,.44444,0,0,.51667],118:[0,.44444,.01389,0,.46111],119:[0,.44444,.01389,0,.68334],120:[0,.44444,0,0,.46111],121:[.19444,.44444,.01389,0,.46111],122:[0,.44444,0,0,.43472],126:[.35,.32659,0,0,.5],160:[0,0,0,0,.25],168:[0,.67937,0,0,.5],176:[0,.69444,0,0,.66667],184:[.17014,0,0,0,.44445],305:[0,.44444,0,0,.23889],567:[.19444,.44444,0,0,.26667],710:[0,.69444,0,0,.5],711:[0,.63194,0,0,.5],713:[0,.60889,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.67937,0,0,.27778],730:[0,.69444,0,0,.66667],732:[0,.67659,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.69444,0,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,0,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,0,0,.66667],928:[0,.69444,0,0,.70834],931:[0,.69444,0,0,.72222],933:[0,.69444,0,0,.77778],934:[0,.69444,0,0,.72222],936:[0,.69444,0,0,.77778],937:[0,.69444,0,0,.72222],8211:[0,.44444,.02778,0,.5],8212:[0,.44444,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5]},"Script-Regular":{32:[0,0,0,0,.25],65:[0,.7,.22925,0,.80253],66:[0,.7,.04087,0,.90757],67:[0,.7,.1689,0,.66619],68:[0,.7,.09371,0,.77443],69:[0,.7,.18583,0,.56162],70:[0,.7,.13634,0,.89544],71:[0,.7,.17322,0,.60961],72:[0,.7,.29694,0,.96919],73:[0,.7,.19189,0,.80907],74:[.27778,.7,.19189,0,1.05159],75:[0,.7,.31259,0,.91364],76:[0,.7,.19189,0,.87373],77:[0,.7,.15981,0,1.08031],78:[0,.7,.3525,0,.9015],79:[0,.7,.08078,0,.73787],80:[0,.7,.08078,0,1.01262],81:[0,.7,.03305,0,.88282],82:[0,.7,.06259,0,.85],83:[0,.7,.19189,0,.86767],84:[0,.7,.29087,0,.74697],85:[0,.7,.25815,0,.79996],86:[0,.7,.27523,0,.62204],87:[0,.7,.27523,0,.80532],88:[0,.7,.26006,0,.94445],89:[0,.7,.2939,0,.70961],90:[0,.7,.24037,0,.8212],160:[0,0,0,0,.25]},"Size1-Regular":{32:[0,0,0,0,.25],40:[.35001,.85,0,0,.45834],41:[.35001,.85,0,0,.45834],47:[.35001,.85,0,0,.57778],91:[.35001,.85,0,0,.41667],92:[.35001,.85,0,0,.57778],93:[.35001,.85,0,0,.41667],123:[.35001,.85,0,0,.58334],125:[.35001,.85,0,0,.58334],160:[0,0,0,0,.25],710:[0,.72222,0,0,.55556],732:[0,.72222,0,0,.55556],770:[0,.72222,0,0,.55556],771:[0,.72222,0,0,.55556],8214:[-99e-5,.601,0,0,.77778],8593:[1e-5,.6,0,0,.66667],8595:[1e-5,.6,0,0,.66667],8657:[1e-5,.6,0,0,.77778],8659:[1e-5,.6,0,0,.77778],8719:[.25001,.75,0,0,.94445],8720:[.25001,.75,0,0,.94445],8721:[.25001,.75,0,0,1.05556],8730:[.35001,.85,0,0,1],8739:[-.00599,.606,0,0,.33333],8741:[-.00599,.606,0,0,.55556],8747:[.30612,.805,.19445,0,.47222],8748:[.306,.805,.19445,0,.47222],8749:[.306,.805,.19445,0,.47222],8750:[.30612,.805,.19445,0,.47222],8896:[.25001,.75,0,0,.83334],8897:[.25001,.75,0,0,.83334],8898:[.25001,.75,0,0,.83334],8899:[.25001,.75,0,0,.83334],8968:[.35001,.85,0,0,.47222],8969:[.35001,.85,0,0,.47222],8970:[.35001,.85,0,0,.47222],8971:[.35001,.85,0,0,.47222],9168:[-99e-5,.601,0,0,.66667],10216:[.35001,.85,0,0,.47222],10217:[.35001,.85,0,0,.47222],10752:[.25001,.75,0,0,1.11111],10753:[.25001,.75,0,0,1.11111],10754:[.25001,.75,0,0,1.11111],10756:[.25001,.75,0,0,.83334],10758:[.25001,.75,0,0,.83334]},"Size2-Regular":{32:[0,0,0,0,.25],40:[.65002,1.15,0,0,.59722],41:[.65002,1.15,0,0,.59722],47:[.65002,1.15,0,0,.81111],91:[.65002,1.15,0,0,.47222],92:[.65002,1.15,0,0,.81111],93:[.65002,1.15,0,0,.47222],123:[.65002,1.15,0,0,.66667],125:[.65002,1.15,0,0,.66667],160:[0,0,0,0,.25],710:[0,.75,0,0,1],732:[0,.75,0,0,1],770:[0,.75,0,0,1],771:[0,.75,0,0,1],8719:[.55001,1.05,0,0,1.27778],8720:[.55001,1.05,0,0,1.27778],8721:[.55001,1.05,0,0,1.44445],8730:[.65002,1.15,0,0,1],8747:[.86225,1.36,.44445,0,.55556],8748:[.862,1.36,.44445,0,.55556],8749:[.862,1.36,.44445,0,.55556],8750:[.86225,1.36,.44445,0,.55556],8896:[.55001,1.05,0,0,1.11111],8897:[.55001,1.05,0,0,1.11111],8898:[.55001,1.05,0,0,1.11111],8899:[.55001,1.05,0,0,1.11111],8968:[.65002,1.15,0,0,.52778],8969:[.65002,1.15,0,0,.52778],8970:[.65002,1.15,0,0,.52778],8971:[.65002,1.15,0,0,.52778],10216:[.65002,1.15,0,0,.61111],10217:[.65002,1.15,0,0,.61111],10752:[.55001,1.05,0,0,1.51112],10753:[.55001,1.05,0,0,1.51112],10754:[.55001,1.05,0,0,1.51112],10756:[.55001,1.05,0,0,1.11111],10758:[.55001,1.05,0,0,1.11111]},"Size3-Regular":{32:[0,0,0,0,.25],40:[.95003,1.45,0,0,.73611],41:[.95003,1.45,0,0,.73611],47:[.95003,1.45,0,0,1.04445],91:[.95003,1.45,0,0,.52778],92:[.95003,1.45,0,0,1.04445],93:[.95003,1.45,0,0,.52778],123:[.95003,1.45,0,0,.75],125:[.95003,1.45,0,0,.75],160:[0,0,0,0,.25],710:[0,.75,0,0,1.44445],732:[0,.75,0,0,1.44445],770:[0,.75,0,0,1.44445],771:[0,.75,0,0,1.44445],8730:[.95003,1.45,0,0,1],8968:[.95003,1.45,0,0,.58334],8969:[.95003,1.45,0,0,.58334],8970:[.95003,1.45,0,0,.58334],8971:[.95003,1.45,0,0,.58334],10216:[.95003,1.45,0,0,.75],10217:[.95003,1.45,0,0,.75]},"Size4-Regular":{32:[0,0,0,0,.25],40:[1.25003,1.75,0,0,.79167],41:[1.25003,1.75,0,0,.79167],47:[1.25003,1.75,0,0,1.27778],91:[1.25003,1.75,0,0,.58334],92:[1.25003,1.75,0,0,1.27778],93:[1.25003,1.75,0,0,.58334],123:[1.25003,1.75,0,0,.80556],125:[1.25003,1.75,0,0,.80556],160:[0,0,0,0,.25],710:[0,.825,0,0,1.8889],732:[0,.825,0,0,1.8889],770:[0,.825,0,0,1.8889],771:[0,.825,0,0,1.8889],8730:[1.25003,1.75,0,0,1],8968:[1.25003,1.75,0,0,.63889],8969:[1.25003,1.75,0,0,.63889],8970:[1.25003,1.75,0,0,.63889],8971:[1.25003,1.75,0,0,.63889],9115:[.64502,1.155,0,0,.875],9116:[1e-5,.6,0,0,.875],9117:[.64502,1.155,0,0,.875],9118:[.64502,1.155,0,0,.875],9119:[1e-5,.6,0,0,.875],9120:[.64502,1.155,0,0,.875],9121:[.64502,1.155,0,0,.66667],9122:[-99e-5,.601,0,0,.66667],9123:[.64502,1.155,0,0,.66667],9124:[.64502,1.155,0,0,.66667],9125:[-99e-5,.601,0,0,.66667],9126:[.64502,1.155,0,0,.66667],9127:[1e-5,.9,0,0,.88889],9128:[.65002,1.15,0,0,.88889],9129:[.90001,0,0,0,.88889],9130:[0,.3,0,0,.88889],9131:[1e-5,.9,0,0,.88889],9132:[.65002,1.15,0,0,.88889],9133:[.90001,0,0,0,.88889],9143:[.88502,.915,0,0,1.05556],10216:[1.25003,1.75,0,0,.80556],10217:[1.25003,1.75,0,0,.80556],57344:[-.00499,.605,0,0,1.05556],57345:[-.00499,.605,0,0,1.05556],57680:[0,.12,0,0,.45],57681:[0,.12,0,0,.45],57682:[0,.12,0,0,.45],57683:[0,.12,0,0,.45]},"Typewriter-Regular":{32:[0,0,0,0,.525],33:[0,.61111,0,0,.525],34:[0,.61111,0,0,.525],35:[0,.61111,0,0,.525],36:[.08333,.69444,0,0,.525],37:[.08333,.69444,0,0,.525],38:[0,.61111,0,0,.525],39:[0,.61111,0,0,.525],40:[.08333,.69444,0,0,.525],41:[.08333,.69444,0,0,.525],42:[0,.52083,0,0,.525],43:[-.08056,.53055,0,0,.525],44:[.13889,.125,0,0,.525],45:[-.08056,.53055,0,0,.525],46:[0,.125,0,0,.525],47:[.08333,.69444,0,0,.525],48:[0,.61111,0,0,.525],49:[0,.61111,0,0,.525],50:[0,.61111,0,0,.525],51:[0,.61111,0,0,.525],52:[0,.61111,0,0,.525],53:[0,.61111,0,0,.525],54:[0,.61111,0,0,.525],55:[0,.61111,0,0,.525],56:[0,.61111,0,0,.525],57:[0,.61111,0,0,.525],58:[0,.43056,0,0,.525],59:[.13889,.43056,0,0,.525],60:[-.05556,.55556,0,0,.525],61:[-.19549,.41562,0,0,.525],62:[-.05556,.55556,0,0,.525],63:[0,.61111,0,0,.525],64:[0,.61111,0,0,.525],65:[0,.61111,0,0,.525],66:[0,.61111,0,0,.525],67:[0,.61111,0,0,.525],68:[0,.61111,0,0,.525],69:[0,.61111,0,0,.525],70:[0,.61111,0,0,.525],71:[0,.61111,0,0,.525],72:[0,.61111,0,0,.525],73:[0,.61111,0,0,.525],74:[0,.61111,0,0,.525],75:[0,.61111,0,0,.525],76:[0,.61111,0,0,.525],77:[0,.61111,0,0,.525],78:[0,.61111,0,0,.525],79:[0,.61111,0,0,.525],80:[0,.61111,0,0,.525],81:[.13889,.61111,0,0,.525],82:[0,.61111,0,0,.525],83:[0,.61111,0,0,.525],84:[0,.61111,0,0,.525],85:[0,.61111,0,0,.525],86:[0,.61111,0,0,.525],87:[0,.61111,0,0,.525],88:[0,.61111,0,0,.525],89:[0,.61111,0,0,.525],90:[0,.61111,0,0,.525],91:[.08333,.69444,0,0,.525],92:[.08333,.69444,0,0,.525],93:[.08333,.69444,0,0,.525],94:[0,.61111,0,0,.525],95:[.09514,0,0,0,.525],96:[0,.61111,0,0,.525],97:[0,.43056,0,0,.525],98:[0,.61111,0,0,.525],99:[0,.43056,0,0,.525],100:[0,.61111,0,0,.525],101:[0,.43056,0,0,.525],102:[0,.61111,0,0,.525],103:[.22222,.43056,0,0,.525],104:[0,.61111,0,0,.525],105:[0,.61111,0,0,.525],106:[.22222,.61111,0,0,.525],107:[0,.61111,0,0,.525],108:[0,.61111,0,0,.525],109:[0,.43056,0,0,.525],110:[0,.43056,0,0,.525],111:[0,.43056,0,0,.525],112:[.22222,.43056,0,0,.525],113:[.22222,.43056,0,0,.525],114:[0,.43056,0,0,.525],115:[0,.43056,0,0,.525],116:[0,.55358,0,0,.525],117:[0,.43056,0,0,.525],118:[0,.43056,0,0,.525],119:[0,.43056,0,0,.525],120:[0,.43056,0,0,.525],121:[.22222,.43056,0,0,.525],122:[0,.43056,0,0,.525],123:[.08333,.69444,0,0,.525],124:[.08333,.69444,0,0,.525],125:[.08333,.69444,0,0,.525],126:[0,.61111,0,0,.525],127:[0,.61111,0,0,.525],160:[0,0,0,0,.525],176:[0,.61111,0,0,.525],184:[.19445,0,0,0,.525],305:[0,.43056,0,0,.525],567:[.22222,.43056,0,0,.525],711:[0,.56597,0,0,.525],713:[0,.56555,0,0,.525],714:[0,.61111,0,0,.525],715:[0,.61111,0,0,.525],728:[0,.61111,0,0,.525],730:[0,.61111,0,0,.525],770:[0,.61111,0,0,.525],771:[0,.61111,0,0,.525],776:[0,.61111,0,0,.525],915:[0,.61111,0,0,.525],916:[0,.61111,0,0,.525],920:[0,.61111,0,0,.525],923:[0,.61111,0,0,.525],926:[0,.61111,0,0,.525],928:[0,.61111,0,0,.525],931:[0,.61111,0,0,.525],933:[0,.61111,0,0,.525],934:[0,.61111,0,0,.525],936:[0,.61111,0,0,.525],937:[0,.61111,0,0,.525],8216:[0,.61111,0,0,.525],8217:[0,.61111,0,0,.525],8242:[0,.61111,0,0,.525],9251:[.11111,.21944,0,0,.525]}},O={slant:[.25,.25,.25],space:[0,0,0],stretch:[0,0,0],shrink:[0,0,0],xHeight:[.431,.431,.431],quad:[1,1.171,1.472],extraSpace:[0,0,0],num1:[.677,.732,.925],num2:[.394,.384,.387],num3:[.444,.471,.504],denom1:[.686,.752,1.025],denom2:[.345,.344,.532],sup1:[.413,.503,.504],sup2:[.363,.431,.404],sup3:[.289,.286,.294],sub1:[.15,.143,.2],sub2:[.247,.286,.4],supDrop:[.386,.353,.494],subDrop:[.05,.071,.1],delim1:[2.39,1.7,1.98],delim2:[1.01,1.157,1.42],axisHeight:[.25,.25,.25],defaultRuleThickness:[.04,.049,.049],bigOpSpacing1:[.111,.111,.111],bigOpSpacing2:[.166,.166,.166],bigOpSpacing3:[.2,.2,.2],bigOpSpacing4:[.6,.611,.611],bigOpSpacing5:[.1,.143,.143],sqrtRuleThickness:[.04,.04,.04],ptPerEm:[10,10,10],doubleRuleSep:[.2,.2,.2],arrayRuleWidth:[.04,.04,.04],fboxsep:[.3,.3,.3],fboxrule:[.04,.04,.04]},P={Å:"A",Ð:"D",Þ:"o",å:"a",ð:"d",þ:"o",А:"A",Б:"B",В:"B",Г:"F",Д:"A",Е:"E",Ж:"K",З:"3",И:"N",Й:"N",К:"K",Л:"N",М:"M",Н:"H",О:"O",П:"N",Р:"P",С:"C",Т:"T",У:"y",Ф:"O",Х:"X",Ц:"U",Ч:"h",Ш:"W",Щ:"W",Ъ:"B",Ы:"X",Ь:"B",Э:"3",Ю:"X",Я:"R",а:"a",б:"b",в:"a",г:"r",д:"y",е:"e",ж:"m",з:"e",и:"n",й:"n",к:"n",л:"n",м:"m",н:"n",о:"o",п:"n",р:"p",с:"c",т:"o",у:"y",ф:"b",х:"x",ц:"n",ч:"n",ш:"w",щ:"w",ъ:"a",ы:"m",ь:"a",э:"e",ю:"m",я:"r"};function $(t,e,n){if(!D[e])throw new Error("Font metrics not found for font: "+e+".");var r=t.charCodeAt(0),i=D[e][r];if(!i&&t[0]in P&&(r=P[t[0]].charCodeAt(0),i=D[e][r]),i||"text"!==n||N(r)&&(i=D[e][77]),i)return{depth:i[0],height:i[1],italic:i[2],skew:i[3],width:i[4]}}var B={},F=[[1,1,1],[2,1,1],[3,1,1],[4,2,1],[5,2,1],[6,3,1],[7,4,2],[8,6,3],[9,7,6],[10,8,7],[11,10,9]],W=[.5,.6,.7,.8,.9,1,1.2,1.44,1.728,2.074,2.488],z=function(t,e){return e.size<2?t:F[t-1][e.size-1]};class Z{constructor(t){this.style=void 0,this.color=void 0,this.size=void 0,this.textSize=void 0,this.phantom=void 0,this.font=void 0,this.fontFamily=void 0,this.fontWeight=void 0,this.fontShape=void 0,this.sizeMultiplier=void 0,this.maxSize=void 0,this.minRuleThickness=void 0,this._fontMetrics=void 0,this.style=t.style,this.color=t.color,this.size=t.size||Z.BASESIZE,this.textSize=t.textSize||this.size,this.phantom=!!t.phantom,this.font=t.font||"",this.fontFamily=t.fontFamily||"",this.fontWeight=t.fontWeight||"",this.fontShape=t.fontShape||"",this.sizeMultiplier=W[this.size-1],this.maxSize=t.maxSize,this.minRuleThickness=t.minRuleThickness,this._fontMetrics=void 0}extend(t){var e={style:this.style,size:this.size,textSize:this.textSize,color:this.color,phantom:this.phantom,font:this.font,fontFamily:this.fontFamily,fontWeight:this.fontWeight,fontShape:this.fontShape,maxSize:this.maxSize,minRuleThickness:this.minRuleThickness};for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return new Z(e)}havingStyle(t){return this.style===t?this:this.extend({style:t,size:z(this.textSize,t)})}havingCrampedStyle(){return this.havingStyle(this.style.cramp())}havingSize(t){return this.size===t&&this.textSize===t?this:this.extend({style:this.style.text(),size:t,textSize:t,sizeMultiplier:W[t-1]})}havingBaseStyle(t){t=t||this.style.text();var e=z(Z.BASESIZE,t);return this.size===e&&this.textSize===Z.BASESIZE&&this.style===t?this:this.extend({style:t,size:e})}havingBaseSizing(){var t;switch(this.style.id){case 4:case 5:t=3;break;case 6:case 7:t=1;break;default:t=6}return this.extend({style:this.style.text(),size:t})}withColor(t){return this.extend({color:t})}withPhantom(){return this.extend({phantom:!0})}withFont(t){return this.extend({font:t})}withTextFontFamily(t){return this.extend({fontFamily:t,font:""})}withTextFontWeight(t){return this.extend({fontWeight:t,font:""})}withTextFontShape(t){return this.extend({fontShape:t,font:""})}sizingClasses(t){return t.size!==this.size?["sizing","reset-size"+t.size,"size"+this.size]:[]}baseSizingClasses(){return this.size!==Z.BASESIZE?["sizing","reset-size"+this.size,"size"+Z.BASESIZE]:[]}fontMetrics(){return this._fontMetrics||(this._fontMetrics=function(t){var e;if(!B[e=t>=5?0:t>=3?1:2]){var n=B[e]={cssEmPerMu:O.quad[e]/18};for(var r in O)O.hasOwnProperty(r)&&(n[r]=O[r][e])}return B[e]}(this.size)),this._fontMetrics}getColor(){return this.phantom?"transparent":this.color}}Z.BASESIZE=6;var Y={pt:1,mm:7227/2540,cm:7227/254,in:72.27,bp:1.00375,pc:12,dd:1238/1157,cc:14856/1157,nd:685/642,nc:1370/107,sp:1/65536,px:1.00375},U={ex:!0,em:!0,mu:!0},G=function(t){return"string"!=typeof t&&(t=t.unit),t in Y||t in U||"ex"===t},V=function(t,e){var n;if(t.unit in Y)n=Y[t.unit]/e.fontMetrics().ptPerEm/e.sizeMultiplier;else if("mu"===t.unit)n=e.fontMetrics().cssEmPerMu;else{var r;if(r=e.style.isTight()?e.havingStyle(e.style.text()):e,"ex"===t.unit)n=r.fontMetrics().xHeight;else{if("em"!==t.unit)throw new a("Invalid unit: '"+t.unit+"'");n=r.fontMetrics().quad}r!==e&&(n*=r.sizeMultiplier/e.sizeMultiplier)}return Math.min(t.number*n,e.maxSize)},q=function(t){return+t.toFixed(4)+"em"},j=function(t){return t.filter((t=>t)).join(" ")},H=function(t,e,n){if(this.classes=t||[],this.attributes={},this.height=0,this.depth=0,this.maxFontSize=0,this.style=n||{},e){e.style.isTight()&&this.classes.push("mtight");var r=e.getColor();r&&(this.style.color=r)}},X=function(t){var e=document.createElement(t);for(var n in e.className=j(this.classes),this.style)this.style.hasOwnProperty(n)&&(e.style[n]=this.style[n]);for(var r in this.attributes)this.attributes.hasOwnProperty(r)&&e.setAttribute(r,this.attributes[r]);for(var i=0;i/=\x00-\x1f]/,Q=function(t){var e="<"+t;this.classes.length&&(e+=' class="'+d(j(this.classes))+'"');var n="";for(var r in this.style)this.style.hasOwnProperty(r)&&(n+=p(r)+":"+this.style[r]+";");for(var i in n&&(e+=' style="'+d(n)+'"'),this.attributes)if(this.attributes.hasOwnProperty(i)){if(K.test(i))throw new a("Invalid attribute name '"+i+"'");e+=" "+i+'="'+d(this.attributes[i])+'"'}e+=">";for(var s=0;s"};class J{constructor(t,e,n,r){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.width=void 0,this.maxFontSize=void 0,this.style=void 0,H.call(this,t,n,r),this.children=e||[]}setAttribute(t,e){this.attributes[t]=e}hasClass(t){return h(this.classes,t)}toNode(){return X.call(this,"span")}toMarkup(){return Q.call(this,"span")}}class tt{constructor(t,e,n,r){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,H.call(this,e,r),this.children=n||[],this.setAttribute("href",t)}setAttribute(t,e){this.attributes[t]=e}hasClass(t){return h(this.classes,t)}toNode(){return X.call(this,"a")}toMarkup(){return Q.call(this,"a")}}class et{constructor(t,e,n){this.src=void 0,this.alt=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.alt=e,this.src=t,this.classes=["mord"],this.style=n}hasClass(t){return h(this.classes,t)}toNode(){var t=document.createElement("img");for(var e in t.src=this.src,t.alt=this.alt,t.className="mord",this.style)this.style.hasOwnProperty(e)&&(t.style[e]=this.style[e]);return t}toMarkup(){var t=''+d(this.alt)+'"}}var nt={î:"ı̂",ï:"ı̈",í:"ı́",ì:"ı̀"};class rt{constructor(t,e,n,r,i,a,s,o){this.text=void 0,this.height=void 0,this.depth=void 0,this.italic=void 0,this.skew=void 0,this.width=void 0,this.maxFontSize=void 0,this.classes=void 0,this.style=void 0,this.text=t,this.height=e||0,this.depth=n||0,this.italic=r||0,this.skew=i||0,this.width=a||0,this.classes=s||[],this.style=o||{},this.maxFontSize=0;var l=function(t){for(var e=0;e=i[0]&&t<=i[1])return n.name}return null}(this.text.charCodeAt(0));l&&this.classes.push(l+"_fallback"),/[îïíì]/.test(this.text)&&(this.text=nt[this.text])}hasClass(t){return h(this.classes,t)}toNode(){var t=document.createTextNode(this.text),e=null;for(var n in this.italic>0&&((e=document.createElement("span")).style.marginRight=q(this.italic)),this.classes.length>0&&((e=e||document.createElement("span")).className=j(this.classes)),this.style)this.style.hasOwnProperty(n)&&((e=e||document.createElement("span")).style[n]=this.style[n]);return e?(e.appendChild(t),e):t}toMarkup(){var t=!1,e="0&&(n+="margin-right:"+this.italic+"em;"),this.style)this.style.hasOwnProperty(r)&&(n+=p(r)+":"+this.style[r]+";");n&&(t=!0,e+=' style="'+d(n)+'"');var i=d(this.text);return t?(e+=">",e+=i,e+=""):i}}class it{constructor(t,e){this.children=void 0,this.attributes=void 0,this.children=t||[],this.attributes=e||{}}toNode(){var t=document.createElementNS("http://www.w3.org/2000/svg","svg");for(var e in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,e)&&t.setAttribute(e,this.attributes[e]);for(var n=0;n"}}class at{constructor(t,e){this.pathName=void 0,this.alternate=void 0,this.pathName=t,this.alternate=e}toNode(){var t=document.createElementNS("http://www.w3.org/2000/svg","path");return this.alternate?t.setAttribute("d",this.alternate):t.setAttribute("d",I[this.pathName]),t}toMarkup(){return this.alternate?'':''}}class st{constructor(t){this.attributes=void 0,this.attributes=t||{}}toNode(){var t=document.createElementNS("http://www.w3.org/2000/svg","line");for(var e in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,e)&&t.setAttribute(e,this.attributes[e]);return t}toMarkup(){var t=""}}function ot(t){if(t instanceof rt)return t;throw new Error("Expected symbolNode but got "+String(t)+".")}var lt={bin:1,close:1,inner:1,open:1,punct:1,rel:1},ct={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1},ht={math:{},text:{}};function ut(t,e,n,r,i,a){ht[t][i]={font:e,group:n,replace:r},a&&r&&(ht[t][r]=ht[t][i])}var dt="math",pt="text",gt="main",ft="ams",mt="accent-token",yt="bin",vt="close",xt="inner",bt="mathord",wt="op-token",kt="open",Tt="punct",_t="rel",Et="spacing",St="textord";ut(dt,gt,_t,"≡","\\equiv",!0),ut(dt,gt,_t,"≺","\\prec",!0),ut(dt,gt,_t,"≻","\\succ",!0),ut(dt,gt,_t,"∼","\\sim",!0),ut(dt,gt,_t,"⊥","\\perp"),ut(dt,gt,_t,"⪯","\\preceq",!0),ut(dt,gt,_t,"⪰","\\succeq",!0),ut(dt,gt,_t,"≃","\\simeq",!0),ut(dt,gt,_t,"∣","\\mid",!0),ut(dt,gt,_t,"≪","\\ll",!0),ut(dt,gt,_t,"≫","\\gg",!0),ut(dt,gt,_t,"≍","\\asymp",!0),ut(dt,gt,_t,"∥","\\parallel"),ut(dt,gt,_t,"⋈","\\bowtie",!0),ut(dt,gt,_t,"⌣","\\smile",!0),ut(dt,gt,_t,"⊑","\\sqsubseteq",!0),ut(dt,gt,_t,"⊒","\\sqsupseteq",!0),ut(dt,gt,_t,"≐","\\doteq",!0),ut(dt,gt,_t,"⌢","\\frown",!0),ut(dt,gt,_t,"∋","\\ni",!0),ut(dt,gt,_t,"∝","\\propto",!0),ut(dt,gt,_t,"⊢","\\vdash",!0),ut(dt,gt,_t,"⊣","\\dashv",!0),ut(dt,gt,_t,"∋","\\owns"),ut(dt,gt,Tt,".","\\ldotp"),ut(dt,gt,Tt,"⋅","\\cdotp"),ut(dt,gt,St,"#","\\#"),ut(pt,gt,St,"#","\\#"),ut(dt,gt,St,"&","\\&"),ut(pt,gt,St,"&","\\&"),ut(dt,gt,St,"ℵ","\\aleph",!0),ut(dt,gt,St,"∀","\\forall",!0),ut(dt,gt,St,"ℏ","\\hbar",!0),ut(dt,gt,St,"∃","\\exists",!0),ut(dt,gt,St,"∇","\\nabla",!0),ut(dt,gt,St,"♭","\\flat",!0),ut(dt,gt,St,"ℓ","\\ell",!0),ut(dt,gt,St,"♮","\\natural",!0),ut(dt,gt,St,"♣","\\clubsuit",!0),ut(dt,gt,St,"℘","\\wp",!0),ut(dt,gt,St,"♯","\\sharp",!0),ut(dt,gt,St,"♢","\\diamondsuit",!0),ut(dt,gt,St,"ℜ","\\Re",!0),ut(dt,gt,St,"♡","\\heartsuit",!0),ut(dt,gt,St,"ℑ","\\Im",!0),ut(dt,gt,St,"♠","\\spadesuit",!0),ut(dt,gt,St,"§","\\S",!0),ut(pt,gt,St,"§","\\S"),ut(dt,gt,St,"¶","\\P",!0),ut(pt,gt,St,"¶","\\P"),ut(dt,gt,St,"†","\\dag"),ut(pt,gt,St,"†","\\dag"),ut(pt,gt,St,"†","\\textdagger"),ut(dt,gt,St,"‡","\\ddag"),ut(pt,gt,St,"‡","\\ddag"),ut(pt,gt,St,"‡","\\textdaggerdbl"),ut(dt,gt,vt,"⎱","\\rmoustache",!0),ut(dt,gt,kt,"⎰","\\lmoustache",!0),ut(dt,gt,vt,"⟯","\\rgroup",!0),ut(dt,gt,kt,"⟮","\\lgroup",!0),ut(dt,gt,yt,"∓","\\mp",!0),ut(dt,gt,yt,"⊖","\\ominus",!0),ut(dt,gt,yt,"⊎","\\uplus",!0),ut(dt,gt,yt,"⊓","\\sqcap",!0),ut(dt,gt,yt,"∗","\\ast"),ut(dt,gt,yt,"⊔","\\sqcup",!0),ut(dt,gt,yt,"◯","\\bigcirc",!0),ut(dt,gt,yt,"∙","\\bullet",!0),ut(dt,gt,yt,"‡","\\ddagger"),ut(dt,gt,yt,"≀","\\wr",!0),ut(dt,gt,yt,"⨿","\\amalg"),ut(dt,gt,yt,"&","\\And"),ut(dt,gt,_t,"⟵","\\longleftarrow",!0),ut(dt,gt,_t,"⇐","\\Leftarrow",!0),ut(dt,gt,_t,"⟸","\\Longleftarrow",!0),ut(dt,gt,_t,"⟶","\\longrightarrow",!0),ut(dt,gt,_t,"⇒","\\Rightarrow",!0),ut(dt,gt,_t,"⟹","\\Longrightarrow",!0),ut(dt,gt,_t,"↔","\\leftrightarrow",!0),ut(dt,gt,_t,"⟷","\\longleftrightarrow",!0),ut(dt,gt,_t,"⇔","\\Leftrightarrow",!0),ut(dt,gt,_t,"⟺","\\Longleftrightarrow",!0),ut(dt,gt,_t,"↦","\\mapsto",!0),ut(dt,gt,_t,"⟼","\\longmapsto",!0),ut(dt,gt,_t,"↗","\\nearrow",!0),ut(dt,gt,_t,"↩","\\hookleftarrow",!0),ut(dt,gt,_t,"↪","\\hookrightarrow",!0),ut(dt,gt,_t,"↘","\\searrow",!0),ut(dt,gt,_t,"↼","\\leftharpoonup",!0),ut(dt,gt,_t,"⇀","\\rightharpoonup",!0),ut(dt,gt,_t,"↙","\\swarrow",!0),ut(dt,gt,_t,"↽","\\leftharpoondown",!0),ut(dt,gt,_t,"⇁","\\rightharpoondown",!0),ut(dt,gt,_t,"↖","\\nwarrow",!0),ut(dt,gt,_t,"⇌","\\rightleftharpoons",!0),ut(dt,ft,_t,"≮","\\nless",!0),ut(dt,ft,_t,"","\\@nleqslant"),ut(dt,ft,_t,"","\\@nleqq"),ut(dt,ft,_t,"⪇","\\lneq",!0),ut(dt,ft,_t,"≨","\\lneqq",!0),ut(dt,ft,_t,"","\\@lvertneqq"),ut(dt,ft,_t,"⋦","\\lnsim",!0),ut(dt,ft,_t,"⪉","\\lnapprox",!0),ut(dt,ft,_t,"⊀","\\nprec",!0),ut(dt,ft,_t,"⋠","\\npreceq",!0),ut(dt,ft,_t,"⋨","\\precnsim",!0),ut(dt,ft,_t,"⪹","\\precnapprox",!0),ut(dt,ft,_t,"≁","\\nsim",!0),ut(dt,ft,_t,"","\\@nshortmid"),ut(dt,ft,_t,"∤","\\nmid",!0),ut(dt,ft,_t,"⊬","\\nvdash",!0),ut(dt,ft,_t,"⊭","\\nvDash",!0),ut(dt,ft,_t,"⋪","\\ntriangleleft"),ut(dt,ft,_t,"⋬","\\ntrianglelefteq",!0),ut(dt,ft,_t,"⊊","\\subsetneq",!0),ut(dt,ft,_t,"","\\@varsubsetneq"),ut(dt,ft,_t,"⫋","\\subsetneqq",!0),ut(dt,ft,_t,"","\\@varsubsetneqq"),ut(dt,ft,_t,"≯","\\ngtr",!0),ut(dt,ft,_t,"","\\@ngeqslant"),ut(dt,ft,_t,"","\\@ngeqq"),ut(dt,ft,_t,"⪈","\\gneq",!0),ut(dt,ft,_t,"≩","\\gneqq",!0),ut(dt,ft,_t,"","\\@gvertneqq"),ut(dt,ft,_t,"⋧","\\gnsim",!0),ut(dt,ft,_t,"⪊","\\gnapprox",!0),ut(dt,ft,_t,"⊁","\\nsucc",!0),ut(dt,ft,_t,"⋡","\\nsucceq",!0),ut(dt,ft,_t,"⋩","\\succnsim",!0),ut(dt,ft,_t,"⪺","\\succnapprox",!0),ut(dt,ft,_t,"≆","\\ncong",!0),ut(dt,ft,_t,"","\\@nshortparallel"),ut(dt,ft,_t,"∦","\\nparallel",!0),ut(dt,ft,_t,"⊯","\\nVDash",!0),ut(dt,ft,_t,"⋫","\\ntriangleright"),ut(dt,ft,_t,"⋭","\\ntrianglerighteq",!0),ut(dt,ft,_t,"","\\@nsupseteqq"),ut(dt,ft,_t,"⊋","\\supsetneq",!0),ut(dt,ft,_t,"","\\@varsupsetneq"),ut(dt,ft,_t,"⫌","\\supsetneqq",!0),ut(dt,ft,_t,"","\\@varsupsetneqq"),ut(dt,ft,_t,"⊮","\\nVdash",!0),ut(dt,ft,_t,"⪵","\\precneqq",!0),ut(dt,ft,_t,"⪶","\\succneqq",!0),ut(dt,ft,_t,"","\\@nsubseteqq"),ut(dt,ft,yt,"⊴","\\unlhd"),ut(dt,ft,yt,"⊵","\\unrhd"),ut(dt,ft,_t,"↚","\\nleftarrow",!0),ut(dt,ft,_t,"↛","\\nrightarrow",!0),ut(dt,ft,_t,"⇍","\\nLeftarrow",!0),ut(dt,ft,_t,"⇏","\\nRightarrow",!0),ut(dt,ft,_t,"↮","\\nleftrightarrow",!0),ut(dt,ft,_t,"⇎","\\nLeftrightarrow",!0),ut(dt,ft,_t,"△","\\vartriangle"),ut(dt,ft,St,"ℏ","\\hslash"),ut(dt,ft,St,"▽","\\triangledown"),ut(dt,ft,St,"◊","\\lozenge"),ut(dt,ft,St,"Ⓢ","\\circledS"),ut(dt,ft,St,"®","\\circledR"),ut(pt,ft,St,"®","\\circledR"),ut(dt,ft,St,"∡","\\measuredangle",!0),ut(dt,ft,St,"∄","\\nexists"),ut(dt,ft,St,"℧","\\mho"),ut(dt,ft,St,"Ⅎ","\\Finv",!0),ut(dt,ft,St,"⅁","\\Game",!0),ut(dt,ft,St,"‵","\\backprime"),ut(dt,ft,St,"▲","\\blacktriangle"),ut(dt,ft,St,"▼","\\blacktriangledown"),ut(dt,ft,St,"■","\\blacksquare"),ut(dt,ft,St,"⧫","\\blacklozenge"),ut(dt,ft,St,"★","\\bigstar"),ut(dt,ft,St,"∢","\\sphericalangle",!0),ut(dt,ft,St,"∁","\\complement",!0),ut(dt,ft,St,"ð","\\eth",!0),ut(pt,gt,St,"ð","ð"),ut(dt,ft,St,"╱","\\diagup"),ut(dt,ft,St,"╲","\\diagdown"),ut(dt,ft,St,"□","\\square"),ut(dt,ft,St,"□","\\Box"),ut(dt,ft,St,"◊","\\Diamond"),ut(dt,ft,St,"¥","\\yen",!0),ut(pt,ft,St,"¥","\\yen",!0),ut(dt,ft,St,"✓","\\checkmark",!0),ut(pt,ft,St,"✓","\\checkmark"),ut(dt,ft,St,"ℶ","\\beth",!0),ut(dt,ft,St,"ℸ","\\daleth",!0),ut(dt,ft,St,"ℷ","\\gimel",!0),ut(dt,ft,St,"ϝ","\\digamma",!0),ut(dt,ft,St,"ϰ","\\varkappa"),ut(dt,ft,kt,"┌","\\@ulcorner",!0),ut(dt,ft,vt,"┐","\\@urcorner",!0),ut(dt,ft,kt,"└","\\@llcorner",!0),ut(dt,ft,vt,"┘","\\@lrcorner",!0),ut(dt,ft,_t,"≦","\\leqq",!0),ut(dt,ft,_t,"⩽","\\leqslant",!0),ut(dt,ft,_t,"⪕","\\eqslantless",!0),ut(dt,ft,_t,"≲","\\lesssim",!0),ut(dt,ft,_t,"⪅","\\lessapprox",!0),ut(dt,ft,_t,"≊","\\approxeq",!0),ut(dt,ft,yt,"⋖","\\lessdot"),ut(dt,ft,_t,"⋘","\\lll",!0),ut(dt,ft,_t,"≶","\\lessgtr",!0),ut(dt,ft,_t,"⋚","\\lesseqgtr",!0),ut(dt,ft,_t,"⪋","\\lesseqqgtr",!0),ut(dt,ft,_t,"≑","\\doteqdot"),ut(dt,ft,_t,"≓","\\risingdotseq",!0),ut(dt,ft,_t,"≒","\\fallingdotseq",!0),ut(dt,ft,_t,"∽","\\backsim",!0),ut(dt,ft,_t,"⋍","\\backsimeq",!0),ut(dt,ft,_t,"⫅","\\subseteqq",!0),ut(dt,ft,_t,"⋐","\\Subset",!0),ut(dt,ft,_t,"⊏","\\sqsubset",!0),ut(dt,ft,_t,"≼","\\preccurlyeq",!0),ut(dt,ft,_t,"⋞","\\curlyeqprec",!0),ut(dt,ft,_t,"≾","\\precsim",!0),ut(dt,ft,_t,"⪷","\\precapprox",!0),ut(dt,ft,_t,"⊲","\\vartriangleleft"),ut(dt,ft,_t,"⊴","\\trianglelefteq"),ut(dt,ft,_t,"⊨","\\vDash",!0),ut(dt,ft,_t,"⊪","\\Vvdash",!0),ut(dt,ft,_t,"⌣","\\smallsmile"),ut(dt,ft,_t,"⌢","\\smallfrown"),ut(dt,ft,_t,"≏","\\bumpeq",!0),ut(dt,ft,_t,"≎","\\Bumpeq",!0),ut(dt,ft,_t,"≧","\\geqq",!0),ut(dt,ft,_t,"⩾","\\geqslant",!0),ut(dt,ft,_t,"⪖","\\eqslantgtr",!0),ut(dt,ft,_t,"≳","\\gtrsim",!0),ut(dt,ft,_t,"⪆","\\gtrapprox",!0),ut(dt,ft,yt,"⋗","\\gtrdot"),ut(dt,ft,_t,"⋙","\\ggg",!0),ut(dt,ft,_t,"≷","\\gtrless",!0),ut(dt,ft,_t,"⋛","\\gtreqless",!0),ut(dt,ft,_t,"⪌","\\gtreqqless",!0),ut(dt,ft,_t,"≖","\\eqcirc",!0),ut(dt,ft,_t,"≗","\\circeq",!0),ut(dt,ft,_t,"≜","\\triangleq",!0),ut(dt,ft,_t,"∼","\\thicksim"),ut(dt,ft,_t,"≈","\\thickapprox"),ut(dt,ft,_t,"⫆","\\supseteqq",!0),ut(dt,ft,_t,"⋑","\\Supset",!0),ut(dt,ft,_t,"⊐","\\sqsupset",!0),ut(dt,ft,_t,"≽","\\succcurlyeq",!0),ut(dt,ft,_t,"⋟","\\curlyeqsucc",!0),ut(dt,ft,_t,"≿","\\succsim",!0),ut(dt,ft,_t,"⪸","\\succapprox",!0),ut(dt,ft,_t,"⊳","\\vartriangleright"),ut(dt,ft,_t,"⊵","\\trianglerighteq"),ut(dt,ft,_t,"⊩","\\Vdash",!0),ut(dt,ft,_t,"∣","\\shortmid"),ut(dt,ft,_t,"∥","\\shortparallel"),ut(dt,ft,_t,"≬","\\between",!0),ut(dt,ft,_t,"⋔","\\pitchfork",!0),ut(dt,ft,_t,"∝","\\varpropto"),ut(dt,ft,_t,"◀","\\blacktriangleleft"),ut(dt,ft,_t,"∴","\\therefore",!0),ut(dt,ft,_t,"∍","\\backepsilon"),ut(dt,ft,_t,"▶","\\blacktriangleright"),ut(dt,ft,_t,"∵","\\because",!0),ut(dt,ft,_t,"⋘","\\llless"),ut(dt,ft,_t,"⋙","\\gggtr"),ut(dt,ft,yt,"⊲","\\lhd"),ut(dt,ft,yt,"⊳","\\rhd"),ut(dt,ft,_t,"≂","\\eqsim",!0),ut(dt,gt,_t,"⋈","\\Join"),ut(dt,ft,_t,"≑","\\Doteq",!0),ut(dt,ft,yt,"∔","\\dotplus",!0),ut(dt,ft,yt,"∖","\\smallsetminus"),ut(dt,ft,yt,"⋒","\\Cap",!0),ut(dt,ft,yt,"⋓","\\Cup",!0),ut(dt,ft,yt,"⩞","\\doublebarwedge",!0),ut(dt,ft,yt,"⊟","\\boxminus",!0),ut(dt,ft,yt,"⊞","\\boxplus",!0),ut(dt,ft,yt,"⋇","\\divideontimes",!0),ut(dt,ft,yt,"⋉","\\ltimes",!0),ut(dt,ft,yt,"⋊","\\rtimes",!0),ut(dt,ft,yt,"⋋","\\leftthreetimes",!0),ut(dt,ft,yt,"⋌","\\rightthreetimes",!0),ut(dt,ft,yt,"⋏","\\curlywedge",!0),ut(dt,ft,yt,"⋎","\\curlyvee",!0),ut(dt,ft,yt,"⊝","\\circleddash",!0),ut(dt,ft,yt,"⊛","\\circledast",!0),ut(dt,ft,yt,"⋅","\\centerdot"),ut(dt,ft,yt,"⊺","\\intercal",!0),ut(dt,ft,yt,"⋒","\\doublecap"),ut(dt,ft,yt,"⋓","\\doublecup"),ut(dt,ft,yt,"⊠","\\boxtimes",!0),ut(dt,ft,_t,"⇢","\\dashrightarrow",!0),ut(dt,ft,_t,"⇠","\\dashleftarrow",!0),ut(dt,ft,_t,"⇇","\\leftleftarrows",!0),ut(dt,ft,_t,"⇆","\\leftrightarrows",!0),ut(dt,ft,_t,"⇚","\\Lleftarrow",!0),ut(dt,ft,_t,"↞","\\twoheadleftarrow",!0),ut(dt,ft,_t,"↢","\\leftarrowtail",!0),ut(dt,ft,_t,"↫","\\looparrowleft",!0),ut(dt,ft,_t,"⇋","\\leftrightharpoons",!0),ut(dt,ft,_t,"↶","\\curvearrowleft",!0),ut(dt,ft,_t,"↺","\\circlearrowleft",!0),ut(dt,ft,_t,"↰","\\Lsh",!0),ut(dt,ft,_t,"⇈","\\upuparrows",!0),ut(dt,ft,_t,"↿","\\upharpoonleft",!0),ut(dt,ft,_t,"⇃","\\downharpoonleft",!0),ut(dt,gt,_t,"⊶","\\origof",!0),ut(dt,gt,_t,"⊷","\\imageof",!0),ut(dt,ft,_t,"⊸","\\multimap",!0),ut(dt,ft,_t,"↭","\\leftrightsquigarrow",!0),ut(dt,ft,_t,"⇉","\\rightrightarrows",!0),ut(dt,ft,_t,"⇄","\\rightleftarrows",!0),ut(dt,ft,_t,"↠","\\twoheadrightarrow",!0),ut(dt,ft,_t,"↣","\\rightarrowtail",!0),ut(dt,ft,_t,"↬","\\looparrowright",!0),ut(dt,ft,_t,"↷","\\curvearrowright",!0),ut(dt,ft,_t,"↻","\\circlearrowright",!0),ut(dt,ft,_t,"↱","\\Rsh",!0),ut(dt,ft,_t,"⇊","\\downdownarrows",!0),ut(dt,ft,_t,"↾","\\upharpoonright",!0),ut(dt,ft,_t,"⇂","\\downharpoonright",!0),ut(dt,ft,_t,"⇝","\\rightsquigarrow",!0),ut(dt,ft,_t,"⇝","\\leadsto"),ut(dt,ft,_t,"⇛","\\Rrightarrow",!0),ut(dt,ft,_t,"↾","\\restriction"),ut(dt,gt,St,"‘","`"),ut(dt,gt,St,"$","\\$"),ut(pt,gt,St,"$","\\$"),ut(pt,gt,St,"$","\\textdollar"),ut(dt,gt,St,"%","\\%"),ut(pt,gt,St,"%","\\%"),ut(dt,gt,St,"_","\\_"),ut(pt,gt,St,"_","\\_"),ut(pt,gt,St,"_","\\textunderscore"),ut(dt,gt,St,"∠","\\angle",!0),ut(dt,gt,St,"∞","\\infty",!0),ut(dt,gt,St,"′","\\prime"),ut(dt,gt,St,"△","\\triangle"),ut(dt,gt,St,"Γ","\\Gamma",!0),ut(dt,gt,St,"Δ","\\Delta",!0),ut(dt,gt,St,"Θ","\\Theta",!0),ut(dt,gt,St,"Λ","\\Lambda",!0),ut(dt,gt,St,"Ξ","\\Xi",!0),ut(dt,gt,St,"Π","\\Pi",!0),ut(dt,gt,St,"Σ","\\Sigma",!0),ut(dt,gt,St,"Υ","\\Upsilon",!0),ut(dt,gt,St,"Φ","\\Phi",!0),ut(dt,gt,St,"Ψ","\\Psi",!0),ut(dt,gt,St,"Ω","\\Omega",!0),ut(dt,gt,St,"A","Α"),ut(dt,gt,St,"B","Β"),ut(dt,gt,St,"E","Ε"),ut(dt,gt,St,"Z","Ζ"),ut(dt,gt,St,"H","Η"),ut(dt,gt,St,"I","Ι"),ut(dt,gt,St,"K","Κ"),ut(dt,gt,St,"M","Μ"),ut(dt,gt,St,"N","Ν"),ut(dt,gt,St,"O","Ο"),ut(dt,gt,St,"P","Ρ"),ut(dt,gt,St,"T","Τ"),ut(dt,gt,St,"X","Χ"),ut(dt,gt,St,"¬","\\neg",!0),ut(dt,gt,St,"¬","\\lnot"),ut(dt,gt,St,"⊤","\\top"),ut(dt,gt,St,"⊥","\\bot"),ut(dt,gt,St,"∅","\\emptyset"),ut(dt,ft,St,"∅","\\varnothing"),ut(dt,gt,bt,"α","\\alpha",!0),ut(dt,gt,bt,"β","\\beta",!0),ut(dt,gt,bt,"γ","\\gamma",!0),ut(dt,gt,bt,"δ","\\delta",!0),ut(dt,gt,bt,"ϵ","\\epsilon",!0),ut(dt,gt,bt,"ζ","\\zeta",!0),ut(dt,gt,bt,"η","\\eta",!0),ut(dt,gt,bt,"θ","\\theta",!0),ut(dt,gt,bt,"ι","\\iota",!0),ut(dt,gt,bt,"κ","\\kappa",!0),ut(dt,gt,bt,"λ","\\lambda",!0),ut(dt,gt,bt,"μ","\\mu",!0),ut(dt,gt,bt,"ν","\\nu",!0),ut(dt,gt,bt,"ξ","\\xi",!0),ut(dt,gt,bt,"ο","\\omicron",!0),ut(dt,gt,bt,"π","\\pi",!0),ut(dt,gt,bt,"ρ","\\rho",!0),ut(dt,gt,bt,"σ","\\sigma",!0),ut(dt,gt,bt,"τ","\\tau",!0),ut(dt,gt,bt,"υ","\\upsilon",!0),ut(dt,gt,bt,"ϕ","\\phi",!0),ut(dt,gt,bt,"χ","\\chi",!0),ut(dt,gt,bt,"ψ","\\psi",!0),ut(dt,gt,bt,"ω","\\omega",!0),ut(dt,gt,bt,"ε","\\varepsilon",!0),ut(dt,gt,bt,"ϑ","\\vartheta",!0),ut(dt,gt,bt,"ϖ","\\varpi",!0),ut(dt,gt,bt,"ϱ","\\varrho",!0),ut(dt,gt,bt,"ς","\\varsigma",!0),ut(dt,gt,bt,"φ","\\varphi",!0),ut(dt,gt,yt,"∗","*",!0),ut(dt,gt,yt,"+","+"),ut(dt,gt,yt,"−","-",!0),ut(dt,gt,yt,"⋅","\\cdot",!0),ut(dt,gt,yt,"∘","\\circ",!0),ut(dt,gt,yt,"÷","\\div",!0),ut(dt,gt,yt,"±","\\pm",!0),ut(dt,gt,yt,"×","\\times",!0),ut(dt,gt,yt,"∩","\\cap",!0),ut(dt,gt,yt,"∪","\\cup",!0),ut(dt,gt,yt,"∖","\\setminus",!0),ut(dt,gt,yt,"∧","\\land"),ut(dt,gt,yt,"∨","\\lor"),ut(dt,gt,yt,"∧","\\wedge",!0),ut(dt,gt,yt,"∨","\\vee",!0),ut(dt,gt,St,"√","\\surd"),ut(dt,gt,kt,"⟨","\\langle",!0),ut(dt,gt,kt,"∣","\\lvert"),ut(dt,gt,kt,"∥","\\lVert"),ut(dt,gt,vt,"?","?"),ut(dt,gt,vt,"!","!"),ut(dt,gt,vt,"⟩","\\rangle",!0),ut(dt,gt,vt,"∣","\\rvert"),ut(dt,gt,vt,"∥","\\rVert"),ut(dt,gt,_t,"=","="),ut(dt,gt,_t,":",":"),ut(dt,gt,_t,"≈","\\approx",!0),ut(dt,gt,_t,"≅","\\cong",!0),ut(dt,gt,_t,"≥","\\ge"),ut(dt,gt,_t,"≥","\\geq",!0),ut(dt,gt,_t,"←","\\gets"),ut(dt,gt,_t,">","\\gt",!0),ut(dt,gt,_t,"∈","\\in",!0),ut(dt,gt,_t,"","\\@not"),ut(dt,gt,_t,"⊂","\\subset",!0),ut(dt,gt,_t,"⊃","\\supset",!0),ut(dt,gt,_t,"⊆","\\subseteq",!0),ut(dt,gt,_t,"⊇","\\supseteq",!0),ut(dt,ft,_t,"⊈","\\nsubseteq",!0),ut(dt,ft,_t,"⊉","\\nsupseteq",!0),ut(dt,gt,_t,"⊨","\\models"),ut(dt,gt,_t,"←","\\leftarrow",!0),ut(dt,gt,_t,"≤","\\le"),ut(dt,gt,_t,"≤","\\leq",!0),ut(dt,gt,_t,"<","\\lt",!0),ut(dt,gt,_t,"→","\\rightarrow",!0),ut(dt,gt,_t,"→","\\to"),ut(dt,ft,_t,"≱","\\ngeq",!0),ut(dt,ft,_t,"≰","\\nleq",!0),ut(dt,gt,Et," ","\\ "),ut(dt,gt,Et," ","\\space"),ut(dt,gt,Et," ","\\nobreakspace"),ut(pt,gt,Et," ","\\ "),ut(pt,gt,Et," "," "),ut(pt,gt,Et," ","\\space"),ut(pt,gt,Et," ","\\nobreakspace"),ut(dt,gt,Et,null,"\\nobreak"),ut(dt,gt,Et,null,"\\allowbreak"),ut(dt,gt,Tt,",",","),ut(dt,gt,Tt,";",";"),ut(dt,ft,yt,"⊼","\\barwedge",!0),ut(dt,ft,yt,"⊻","\\veebar",!0),ut(dt,gt,yt,"⊙","\\odot",!0),ut(dt,gt,yt,"⊕","\\oplus",!0),ut(dt,gt,yt,"⊗","\\otimes",!0),ut(dt,gt,St,"∂","\\partial",!0),ut(dt,gt,yt,"⊘","\\oslash",!0),ut(dt,ft,yt,"⊚","\\circledcirc",!0),ut(dt,ft,yt,"⊡","\\boxdot",!0),ut(dt,gt,yt,"△","\\bigtriangleup"),ut(dt,gt,yt,"▽","\\bigtriangledown"),ut(dt,gt,yt,"†","\\dagger"),ut(dt,gt,yt,"⋄","\\diamond"),ut(dt,gt,yt,"⋆","\\star"),ut(dt,gt,yt,"◃","\\triangleleft"),ut(dt,gt,yt,"▹","\\triangleright"),ut(dt,gt,kt,"{","\\{"),ut(pt,gt,St,"{","\\{"),ut(pt,gt,St,"{","\\textbraceleft"),ut(dt,gt,vt,"}","\\}"),ut(pt,gt,St,"}","\\}"),ut(pt,gt,St,"}","\\textbraceright"),ut(dt,gt,kt,"{","\\lbrace"),ut(dt,gt,vt,"}","\\rbrace"),ut(dt,gt,kt,"[","\\lbrack",!0),ut(pt,gt,St,"[","\\lbrack",!0),ut(dt,gt,vt,"]","\\rbrack",!0),ut(pt,gt,St,"]","\\rbrack",!0),ut(dt,gt,kt,"(","\\lparen",!0),ut(dt,gt,vt,")","\\rparen",!0),ut(pt,gt,St,"<","\\textless",!0),ut(pt,gt,St,">","\\textgreater",!0),ut(dt,gt,kt,"⌊","\\lfloor",!0),ut(dt,gt,vt,"⌋","\\rfloor",!0),ut(dt,gt,kt,"⌈","\\lceil",!0),ut(dt,gt,vt,"⌉","\\rceil",!0),ut(dt,gt,St,"\\","\\backslash"),ut(dt,gt,St,"∣","|"),ut(dt,gt,St,"∣","\\vert"),ut(pt,gt,St,"|","\\textbar",!0),ut(dt,gt,St,"∥","\\|"),ut(dt,gt,St,"∥","\\Vert"),ut(pt,gt,St,"∥","\\textbardbl"),ut(pt,gt,St,"~","\\textasciitilde"),ut(pt,gt,St,"\\","\\textbackslash"),ut(pt,gt,St,"^","\\textasciicircum"),ut(dt,gt,_t,"↑","\\uparrow",!0),ut(dt,gt,_t,"⇑","\\Uparrow",!0),ut(dt,gt,_t,"↓","\\downarrow",!0),ut(dt,gt,_t,"⇓","\\Downarrow",!0),ut(dt,gt,_t,"↕","\\updownarrow",!0),ut(dt,gt,_t,"⇕","\\Updownarrow",!0),ut(dt,gt,wt,"∐","\\coprod"),ut(dt,gt,wt,"⋁","\\bigvee"),ut(dt,gt,wt,"⋀","\\bigwedge"),ut(dt,gt,wt,"⨄","\\biguplus"),ut(dt,gt,wt,"⋂","\\bigcap"),ut(dt,gt,wt,"⋃","\\bigcup"),ut(dt,gt,wt,"∫","\\int"),ut(dt,gt,wt,"∫","\\intop"),ut(dt,gt,wt,"∬","\\iint"),ut(dt,gt,wt,"∭","\\iiint"),ut(dt,gt,wt,"∏","\\prod"),ut(dt,gt,wt,"∑","\\sum"),ut(dt,gt,wt,"⨂","\\bigotimes"),ut(dt,gt,wt,"⨁","\\bigoplus"),ut(dt,gt,wt,"⨀","\\bigodot"),ut(dt,gt,wt,"∮","\\oint"),ut(dt,gt,wt,"∯","\\oiint"),ut(dt,gt,wt,"∰","\\oiiint"),ut(dt,gt,wt,"⨆","\\bigsqcup"),ut(dt,gt,wt,"∫","\\smallint"),ut(pt,gt,xt,"…","\\textellipsis"),ut(dt,gt,xt,"…","\\mathellipsis"),ut(pt,gt,xt,"…","\\ldots",!0),ut(dt,gt,xt,"…","\\ldots",!0),ut(dt,gt,xt,"⋯","\\@cdots",!0),ut(dt,gt,xt,"⋱","\\ddots",!0),ut(dt,gt,St,"⋮","\\varvdots"),ut(pt,gt,St,"⋮","\\varvdots"),ut(dt,gt,mt,"ˊ","\\acute"),ut(dt,gt,mt,"ˋ","\\grave"),ut(dt,gt,mt,"¨","\\ddot"),ut(dt,gt,mt,"~","\\tilde"),ut(dt,gt,mt,"ˉ","\\bar"),ut(dt,gt,mt,"˘","\\breve"),ut(dt,gt,mt,"ˇ","\\check"),ut(dt,gt,mt,"^","\\hat"),ut(dt,gt,mt,"⃗","\\vec"),ut(dt,gt,mt,"˙","\\dot"),ut(dt,gt,mt,"˚","\\mathring"),ut(dt,gt,bt,"","\\@imath"),ut(dt,gt,bt,"","\\@jmath"),ut(dt,gt,St,"ı","ı"),ut(dt,gt,St,"ȷ","ȷ"),ut(pt,gt,St,"ı","\\i",!0),ut(pt,gt,St,"ȷ","\\j",!0),ut(pt,gt,St,"ß","\\ss",!0),ut(pt,gt,St,"æ","\\ae",!0),ut(pt,gt,St,"œ","\\oe",!0),ut(pt,gt,St,"ø","\\o",!0),ut(pt,gt,St,"Æ","\\AE",!0),ut(pt,gt,St,"Œ","\\OE",!0),ut(pt,gt,St,"Ø","\\O",!0),ut(pt,gt,mt,"ˊ","\\'"),ut(pt,gt,mt,"ˋ","\\`"),ut(pt,gt,mt,"ˆ","\\^"),ut(pt,gt,mt,"˜","\\~"),ut(pt,gt,mt,"ˉ","\\="),ut(pt,gt,mt,"˘","\\u"),ut(pt,gt,mt,"˙","\\."),ut(pt,gt,mt,"¸","\\c"),ut(pt,gt,mt,"˚","\\r"),ut(pt,gt,mt,"ˇ","\\v"),ut(pt,gt,mt,"¨",'\\"'),ut(pt,gt,mt,"˝","\\H"),ut(pt,gt,mt,"◯","\\textcircled");var Ct={"--":!0,"---":!0,"``":!0,"''":!0};ut(pt,gt,St,"–","--",!0),ut(pt,gt,St,"–","\\textendash"),ut(pt,gt,St,"—","---",!0),ut(pt,gt,St,"—","\\textemdash"),ut(pt,gt,St,"‘","`",!0),ut(pt,gt,St,"‘","\\textquoteleft"),ut(pt,gt,St,"’","'",!0),ut(pt,gt,St,"’","\\textquoteright"),ut(pt,gt,St,"“","``",!0),ut(pt,gt,St,"“","\\textquotedblleft"),ut(pt,gt,St,"”","''",!0),ut(pt,gt,St,"”","\\textquotedblright"),ut(dt,gt,St,"°","\\degree",!0),ut(pt,gt,St,"°","\\degree"),ut(pt,gt,St,"°","\\textdegree",!0),ut(dt,gt,St,"£","\\pounds"),ut(dt,gt,St,"£","\\mathsterling",!0),ut(pt,gt,St,"£","\\pounds"),ut(pt,gt,St,"£","\\textsterling",!0),ut(dt,ft,St,"✠","\\maltese"),ut(pt,ft,St,"✠","\\maltese");for(var At=0;At<14;At++){var Lt='0123456789/@."'.charAt(At);ut(dt,gt,St,Lt,Lt)}for(var Mt=0;Mt<25;Mt++){var Nt='0123456789!@*()-=+";:?/.,'.charAt(Mt);ut(pt,gt,St,Nt,Nt)}for(var It="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",Rt=0;Rt<52;Rt++){var Dt=It.charAt(Rt);ut(dt,gt,bt,Dt,Dt),ut(pt,gt,St,Dt,Dt)}ut(dt,ft,St,"C","ℂ"),ut(pt,ft,St,"C","ℂ"),ut(dt,ft,St,"H","ℍ"),ut(pt,ft,St,"H","ℍ"),ut(dt,ft,St,"N","ℕ"),ut(pt,ft,St,"N","ℕ"),ut(dt,ft,St,"P","ℙ"),ut(pt,ft,St,"P","ℙ"),ut(dt,ft,St,"Q","ℚ"),ut(pt,ft,St,"Q","ℚ"),ut(dt,ft,St,"R","ℝ"),ut(pt,ft,St,"R","ℝ"),ut(dt,ft,St,"Z","ℤ"),ut(pt,ft,St,"Z","ℤ"),ut(dt,gt,bt,"h","ℎ"),ut(pt,gt,bt,"h","ℎ");for(var Ot="",Pt=0;Pt<52;Pt++){var $t=It.charAt(Pt);ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56320+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56372+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56424+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56580+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56684+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56736+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56788+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56840+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56944+Pt)),ut(pt,gt,St,$t,Ot),Pt<26&&(ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56632+Pt)),ut(pt,gt,St,$t,Ot),ut(dt,gt,bt,$t,Ot=String.fromCharCode(55349,56476+Pt)),ut(pt,gt,St,$t,Ot))}ut(dt,gt,bt,"k",Ot=String.fromCharCode(55349,56668)),ut(pt,gt,St,"k",Ot);for(var Bt=0;Bt<10;Bt++){var Ft=Bt.toString();ut(dt,gt,bt,Ft,Ot=String.fromCharCode(55349,57294+Bt)),ut(pt,gt,St,Ft,Ot),ut(dt,gt,bt,Ft,Ot=String.fromCharCode(55349,57314+Bt)),ut(pt,gt,St,Ft,Ot),ut(dt,gt,bt,Ft,Ot=String.fromCharCode(55349,57324+Bt)),ut(pt,gt,St,Ft,Ot),ut(dt,gt,bt,Ft,Ot=String.fromCharCode(55349,57334+Bt)),ut(pt,gt,St,Ft,Ot)}for(var Wt=0;Wt<3;Wt++){var zt="ÐÞþ".charAt(Wt);ut(dt,gt,bt,zt,zt),ut(pt,gt,St,zt,zt)}var Zt=[["mathbf","textbf","Main-Bold"],["mathbf","textbf","Main-Bold"],["mathnormal","textit","Math-Italic"],["mathnormal","textit","Math-Italic"],["boldsymbol","boldsymbol","Main-BoldItalic"],["boldsymbol","boldsymbol","Main-BoldItalic"],["mathscr","textscr","Script-Regular"],["","",""],["","",""],["","",""],["mathfrak","textfrak","Fraktur-Regular"],["mathfrak","textfrak","Fraktur-Regular"],["mathbb","textbb","AMS-Regular"],["mathbb","textbb","AMS-Regular"],["mathboldfrak","textboldfrak","Fraktur-Regular"],["mathboldfrak","textboldfrak","Fraktur-Regular"],["mathsf","textsf","SansSerif-Regular"],["mathsf","textsf","SansSerif-Regular"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathitsf","textitsf","SansSerif-Italic"],["mathitsf","textitsf","SansSerif-Italic"],["","",""],["","",""],["mathtt","texttt","Typewriter-Regular"],["mathtt","texttt","Typewriter-Regular"]],Yt=[["mathbf","textbf","Main-Bold"],["","",""],["mathsf","textsf","SansSerif-Regular"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathtt","texttt","Typewriter-Regular"]],Ut=function(t,e,n){return ht[n][t]&&ht[n][t].replace&&(t=ht[n][t].replace),{value:t,metrics:$(t,e,n)}},Gt=function(t,e,n,r,i){var a,s=Ut(t,e,n),o=s.metrics;if(t=s.value,o){var l=o.italic;("text"===n||r&&"mathit"===r.font)&&(l=0),a=new rt(t,o.height,o.depth,l,o.skew,o.width,i)}else"undefined"!=typeof console&&console.warn("No character metrics for '"+t+"' in style '"+e+"' and mode '"+n+"'"),a=new rt(t,0,0,0,0,0,i);if(r){a.maxFontSize=r.sizeMultiplier,r.style.isTight()&&a.classes.push("mtight");var c=r.getColor();c&&(a.style.color=c)}return a},Vt=(t,e)=>{if(j(t.classes)!==j(e.classes)||t.skew!==e.skew||t.maxFontSize!==e.maxFontSize)return!1;if(1===t.classes.length){var n=t.classes[0];if("mbin"===n||"mord"===n)return!1}for(var r in t.style)if(t.style.hasOwnProperty(r)&&t.style[r]!==e.style[r])return!1;for(var i in e.style)if(e.style.hasOwnProperty(i)&&t.style[i]!==e.style[i])return!1;return!0},qt=function(t){for(var e=0,n=0,r=0,i=0;ie&&(e=a.height),a.depth>n&&(n=a.depth),a.maxFontSize>r&&(r=a.maxFontSize)}t.height=e,t.depth=n,t.maxFontSize=r},jt=function(t,e,n,r){var i=new J(t,e,n,r);return qt(i),i},Ht=(t,e,n,r)=>new J(t,e,n,r),Xt=function(t){var e=new R(t);return qt(e),e},Kt=function(t,e,n){var r="";switch(t){case"amsrm":r="AMS";break;case"textrm":r="Main";break;case"textsf":r="SansSerif";break;case"texttt":r="Typewriter";break;default:r=t}return r+"-"+("textbf"===e&&"textit"===n?"BoldItalic":"textbf"===e?"Bold":"textit"===e?"Italic":"Regular")},Qt={mathbf:{variant:"bold",fontName:"Main-Bold"},mathrm:{variant:"normal",fontName:"Main-Regular"},textit:{variant:"italic",fontName:"Main-Italic"},mathit:{variant:"italic",fontName:"Main-Italic"},mathnormal:{variant:"italic",fontName:"Math-Italic"},mathsfit:{variant:"sans-serif-italic",fontName:"SansSerif-Italic"},mathbb:{variant:"double-struck",fontName:"AMS-Regular"},mathcal:{variant:"script",fontName:"Caligraphic-Regular"},mathfrak:{variant:"fraktur",fontName:"Fraktur-Regular"},mathscr:{variant:"script",fontName:"Script-Regular"},mathsf:{variant:"sans-serif",fontName:"SansSerif-Regular"},mathtt:{variant:"monospace",fontName:"Typewriter-Regular"}},Jt={vec:["vec",.471,.714],oiintSize1:["oiintSize1",.957,.499],oiintSize2:["oiintSize2",1.472,.659],oiiintSize1:["oiiintSize1",1.304,.499],oiiintSize2:["oiiintSize2",1.98,.659]},te={fontMap:Qt,makeSymbol:Gt,mathsym:function(t,e,n,r){return void 0===r&&(r=[]),"boldsymbol"===n.font&&Ut(t,"Main-Bold",e).metrics?Gt(t,"Main-Bold",e,n,r.concat(["mathbf"])):"\\"===t||"main"===ht[e][t].font?Gt(t,"Main-Regular",e,n,r):Gt(t,"AMS-Regular",e,n,r.concat(["amsrm"]))},makeSpan:jt,makeSvgSpan:Ht,makeLineSpan:function(t,e,n){var r=jt([t],[],e);return r.height=Math.max(n||e.fontMetrics().defaultRuleThickness,e.minRuleThickness),r.style.borderBottomWidth=q(r.height),r.maxFontSize=1,r},makeAnchor:function(t,e,n,r){var i=new tt(t,e,n,r);return qt(i),i},makeFragment:Xt,wrapFragment:function(t,e){return t instanceof R?jt([],[t],e):t},makeVList:function(t,e){for(var{children:n,depth:r}=function(t){if("individualShift"===t.positionType){for(var e=t.children,n=[e[0]],r=-e[0].shift-e[0].elem.depth,i=r,a=1;a0)return Gt(i,c,r,e,s.concat(h));if(l){var u,d;if("boldsymbol"===l){var p=function(t,e,n,r,i){return"textord"!==i&&Ut(t,"Math-BoldItalic",e).metrics?{fontName:"Math-BoldItalic",fontClass:"boldsymbol"}:{fontName:"Main-Bold",fontClass:"mathbf"}}(i,r,0,0,n);u=p.fontName,d=[p.fontClass]}else o?(u=Qt[l].fontName,d=[l]):(u=Kt(l,e.fontWeight,e.fontShape),d=[l,e.fontWeight,e.fontShape]);if(Ut(i,u,r).metrics)return Gt(i,u,r,e,s.concat(d));if(Ct.hasOwnProperty(i)&&"Typewriter"===u.slice(0,10)){for(var g=[],f=0;f{var n=jt(["mspace"],[],e),r=V(t,e);return n.style.marginRight=q(r),n},staticSvg:function(t,e){var[n,r,i]=Jt[t],a=new at(n),s=new it([a],{width:q(r),height:q(i),style:"width:"+q(r),viewBox:"0 0 "+1e3*r+" "+1e3*i,preserveAspectRatio:"xMinYMin"}),o=Ht(["overlay"],[s],e);return o.height=i,o.style.height=q(i),o.style.width=q(r),o},svgData:Jt,tryCombineChars:t=>{for(var e=0;e{var n=e.classes[0],r=t.classes[0];"mbin"===n&&h(fe,r)?e.classes[0]="mord":"mbin"===r&&h(ge,n)&&(t.classes[0]="mord")}),{node:u},d,p),xe(i,((t,e)=>{var n=ke(e),r=ke(t),i=n&&r?t.hasClass("mtight")?ae[n][r]:ie[n][r]:null;if(i)return te.makeGlue(i,l)}),{node:u},d,p),i},xe=function t(e,n,r,i,a){i&&e.push(i);for(var s=0;sn=>{e.splice(t+1,0,n),s++})(s)}}i&&e.pop()},be=function(t){return t instanceof R||t instanceof tt||t instanceof J&&t.hasClass("enclosing")?t:null},we=function t(e,n){var r=be(e);if(r){var i=r.children;if(i.length){if("right"===n)return t(i[i.length-1],"right");if("left"===n)return t(i[0],"left")}}return e},ke=function(t,e){return t?(e&&(t=we(t,e)),ye[t.classes[0]]||null):null},Te=function(t,e){var n=["nulldelimiter"].concat(t.baseSizingClasses());return pe(e.concat(n))},_e=function(t,e,n){if(!t)return pe();if(oe[t.type]){var r=oe[t.type](t,e);if(n&&e.size!==n.size){r=pe(e.sizingClasses(n),[r],e);var i=e.sizeMultiplier/n.sizeMultiplier;r.height*=i,r.depth*=i}return r}throw new a("Got group of unknown type: '"+t.type+"'")};function Ee(t,e){var n=pe(["base"],t,e),r=pe(["strut"]);return r.style.height=q(n.height+n.depth),n.depth&&(r.style.verticalAlign=q(-n.depth)),n.children.unshift(r),n}function Se(t,e){var n=null;1===t.length&&"tag"===t[0].type&&(n=t[0].tag,t=t[0].body);var r,i=ve(t,e,"root");2===i.length&&i[1].hasClass("tag")&&(r=i.pop());for(var a,s=[],o=[],l=0;l0&&(s.push(Ee(o,e)),o=[]),s.push(i[l]));o.length>0&&s.push(Ee(o,e)),n?((a=Ee(ve(n,e,!0))).classes=["tag"],s.push(a)):r&&s.push(r);var h=pe(["katex-html"],s);if(h.setAttribute("aria-hidden","true"),a){var u=a.children[0];u.style.height=q(h.height+h.depth),h.depth&&(u.style.verticalAlign=q(-h.depth))}return h}function Ce(t){return new R(t)}class Ae{constructor(t,e,n){this.type=void 0,this.attributes=void 0,this.children=void 0,this.classes=void 0,this.type=t,this.attributes={},this.children=e||[],this.classes=n||[]}setAttribute(t,e){this.attributes[t]=e}getAttribute(t){return this.attributes[t]}toNode(){var t=document.createElementNS("http://www.w3.org/1998/Math/MathML",this.type);for(var e in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,e)&&t.setAttribute(e,this.attributes[e]);this.classes.length>0&&(t.className=j(this.classes));for(var n=0;n0&&(t+=' class ="'+d(j(this.classes))+'"'),t+=">";for(var n=0;n"}toText(){return this.children.map((t=>t.toText())).join("")}}class Le{constructor(t){this.text=void 0,this.text=t}toNode(){return document.createTextNode(this.text)}toMarkup(){return d(this.toText())}toText(){return this.text}}var Me={MathNode:Ae,TextNode:Le,SpaceNode:class{constructor(t){this.width=void 0,this.character=void 0,this.width=t,this.character=t>=.05555&&t<=.05556?" ":t>=.1666&&t<=.1667?" ":t>=.2222&&t<=.2223?" ":t>=.2777&&t<=.2778?"  ":t>=-.05556&&t<=-.05555?" ⁣":t>=-.1667&&t<=-.1666?" ⁣":t>=-.2223&&t<=-.2222?" ⁣":t>=-.2778&&t<=-.2777?" ⁣":null}toNode(){if(this.character)return document.createTextNode(this.character);var t=document.createElementNS("http://www.w3.org/1998/Math/MathML","mspace");return t.setAttribute("width",q(this.width)),t}toMarkup(){return this.character?""+this.character+"":''}toText(){return this.character?this.character:" "}},newDocumentFragment:Ce},Ne=function(t,e,n){return!ht[e][t]||!ht[e][t].replace||55349===t.charCodeAt(0)||Ct.hasOwnProperty(t)&&n&&(n.fontFamily&&"tt"===n.fontFamily.slice(4,6)||n.font&&"tt"===n.font.slice(4,6))||(t=ht[e][t].replace),new Me.TextNode(t)},Ie=function(t){return 1===t.length?t[0]:new Me.MathNode("mrow",t)},Re=function(t,e){if("texttt"===e.fontFamily)return"monospace";if("textsf"===e.fontFamily)return"textit"===e.fontShape&&"textbf"===e.fontWeight?"sans-serif-bold-italic":"textit"===e.fontShape?"sans-serif-italic":"textbf"===e.fontWeight?"bold-sans-serif":"sans-serif";if("textit"===e.fontShape&&"textbf"===e.fontWeight)return"bold-italic";if("textit"===e.fontShape)return"italic";if("textbf"===e.fontWeight)return"bold";var n=e.font;if(!n||"mathnormal"===n)return null;var r=t.mode;if("mathit"===n)return"italic";if("boldsymbol"===n)return"textord"===t.type?"bold":"bold-italic";if("mathbf"===n)return"bold";if("mathbb"===n)return"double-struck";if("mathsfit"===n)return"sans-serif-italic";if("mathfrak"===n)return"fraktur";if("mathscr"===n||"mathcal"===n)return"script";if("mathsf"===n)return"sans-serif";if("mathtt"===n)return"monospace";var i=t.text;return h(["\\imath","\\jmath"],i)?null:(ht[r][i]&&ht[r][i].replace&&(i=ht[r][i].replace),$(i,te.fontMap[n].fontName,r)?te.fontMap[n].variant:null)};function De(t){if(!t)return!1;if("mi"===t.type&&1===t.children.length){var e=t.children[0];return e instanceof Le&&"."===e.text}if("mo"===t.type&&1===t.children.length&&"true"===t.getAttribute("separator")&&"0em"===t.getAttribute("lspace")&&"0em"===t.getAttribute("rspace")){var n=t.children[0];return n instanceof Le&&","===n.text}return!1}var Oe=function(t,e,n){if(1===t.length){var r=$e(t[0],e);return n&&r instanceof Ae&&"mo"===r.type&&(r.setAttribute("lspace","0em"),r.setAttribute("rspace","0em")),[r]}for(var i,a=[],s=0;s=1&&("mn"===i.type||De(i))){var l=o.children[0];l instanceof Ae&&"mn"===l.type&&(l.children=[...i.children,...l.children],a.pop())}else if("mi"===i.type&&1===i.children.length){var c=i.children[0];if(c instanceof Le&&"̸"===c.text&&("mo"===o.type||"mi"===o.type||"mn"===o.type)){var h=o.children[0];h instanceof Le&&h.text.length>0&&(h.text=h.text.slice(0,1)+"̸"+h.text.slice(1),a.pop())}}}a.push(o),i=o}return a},Pe=function(t,e,n){return Ie(Oe(t,e,n))},$e=function(t,e){if(!t)return new Me.MathNode("mrow");if(le[t.type])return le[t.type](t,e);throw new a("Got group of unknown type: '"+t.type+"'")};function Be(t,e,n,r,i){var a,s=Oe(t,n);a=1===s.length&&s[0]instanceof Ae&&h(["mrow","mtable"],s[0].type)?s[0]:new Me.MathNode("mrow",s);var o=new Me.MathNode("annotation",[new Me.TextNode(e)]);o.setAttribute("encoding","application/x-tex");var l=new Me.MathNode("semantics",[a,o]),c=new Me.MathNode("math",[l]);return c.setAttribute("xmlns","http://www.w3.org/1998/Math/MathML"),r&&c.setAttribute("display","block"),te.makeSpan([i?"katex":"katex-mathml"],[c])}var Fe=function(t){return new Z({style:t.displayMode?A.DISPLAY:A.TEXT,maxSize:t.maxSize,minRuleThickness:t.minRuleThickness})},We=function(t,e){if(e.displayMode){var n=["katex-display"];e.leqno&&n.push("leqno"),e.fleqn&&n.push("fleqn"),t=te.makeSpan(n,[t])}return t},ze={widehat:"^",widecheck:"ˇ",widetilde:"~",utilde:"~",overleftarrow:"←",underleftarrow:"←",xleftarrow:"←",overrightarrow:"→",underrightarrow:"→",xrightarrow:"→",underbrace:"⏟",overbrace:"⏞",overgroup:"⏠",undergroup:"⏡",overleftrightarrow:"↔",underleftrightarrow:"↔",xleftrightarrow:"↔",Overrightarrow:"⇒",xRightarrow:"⇒",overleftharpoon:"↼",xleftharpoonup:"↼",overrightharpoon:"⇀",xrightharpoonup:"⇀",xLeftarrow:"⇐",xLeftrightarrow:"⇔",xhookleftarrow:"↩",xhookrightarrow:"↪",xmapsto:"↦",xrightharpoondown:"⇁",xleftharpoondown:"↽",xrightleftharpoons:"⇌",xleftrightharpoons:"⇋",xtwoheadleftarrow:"↞",xtwoheadrightarrow:"↠",xlongequal:"=",xtofrom:"⇄",xrightleftarrows:"⇄",xrightequilibrium:"⇌",xleftequilibrium:"⇋","\\cdrightarrow":"→","\\cdleftarrow":"←","\\cdlongequal":"="},Ze={overrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],overleftarrow:[["leftarrow"],.888,522,"xMinYMin"],underrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],underleftarrow:[["leftarrow"],.888,522,"xMinYMin"],xrightarrow:[["rightarrow"],1.469,522,"xMaxYMin"],"\\cdrightarrow":[["rightarrow"],3,522,"xMaxYMin"],xleftarrow:[["leftarrow"],1.469,522,"xMinYMin"],"\\cdleftarrow":[["leftarrow"],3,522,"xMinYMin"],Overrightarrow:[["doublerightarrow"],.888,560,"xMaxYMin"],xRightarrow:[["doublerightarrow"],1.526,560,"xMaxYMin"],xLeftarrow:[["doubleleftarrow"],1.526,560,"xMinYMin"],overleftharpoon:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoonup:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoondown:[["leftharpoondown"],.888,522,"xMinYMin"],overrightharpoon:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoonup:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoondown:[["rightharpoondown"],.888,522,"xMaxYMin"],xlongequal:[["longequal"],.888,334,"xMinYMin"],"\\cdlongequal":[["longequal"],3,334,"xMinYMin"],xtwoheadleftarrow:[["twoheadleftarrow"],.888,334,"xMinYMin"],xtwoheadrightarrow:[["twoheadrightarrow"],.888,334,"xMaxYMin"],overleftrightarrow:[["leftarrow","rightarrow"],.888,522],overbrace:[["leftbrace","midbrace","rightbrace"],1.6,548],underbrace:[["leftbraceunder","midbraceunder","rightbraceunder"],1.6,548],underleftrightarrow:[["leftarrow","rightarrow"],.888,522],xleftrightarrow:[["leftarrow","rightarrow"],1.75,522],xLeftrightarrow:[["doubleleftarrow","doublerightarrow"],1.75,560],xrightleftharpoons:[["leftharpoondownplus","rightharpoonplus"],1.75,716],xleftrightharpoons:[["leftharpoonplus","rightharpoondownplus"],1.75,716],xhookleftarrow:[["leftarrow","righthook"],1.08,522],xhookrightarrow:[["lefthook","rightarrow"],1.08,522],overlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],underlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],overgroup:[["leftgroup","rightgroup"],.888,342],undergroup:[["leftgroupunder","rightgroupunder"],.888,342],xmapsto:[["leftmapsto","rightarrow"],1.5,522],xtofrom:[["leftToFrom","rightToFrom"],1.75,528],xrightleftarrows:[["baraboveleftarrow","rightarrowabovebar"],1.75,901],xrightequilibrium:[["baraboveshortleftharpoon","rightharpoonaboveshortbar"],1.75,716],xleftequilibrium:[["shortbaraboveleftharpoon","shortrightharpoonabovebar"],1.75,716]},Ye=function(t){var e=new Me.MathNode("mo",[new Me.TextNode(ze[t.replace(/^\\/,"")])]);return e.setAttribute("stretchy","true"),e},Ue=function(t,e){var{span:n,minWidth:r,height:i}=function(){var n=4e5,r=t.label.slice(1);if(h(["widehat","widecheck","widetilde","utilde"],r)){var i,a,s,o="ordgroup"===(g=t.base).type?g.body.length:1;if(o>5)"widehat"===r||"widecheck"===r?(i=420,n=2364,s=.42,a=r+"4"):(i=312,n=2340,s=.34,a="tilde4");else{var l=[1,1,2,2,3,3][o];"widehat"===r||"widecheck"===r?(n=[0,1062,2364,2364,2364][l],i=[0,239,300,360,420][l],s=[0,.24,.3,.3,.36,.42][l],a=r+l):(n=[0,600,1033,2339,2340][l],i=[0,260,286,306,312][l],s=[0,.26,.286,.3,.306,.34][l],a="tilde"+l)}var c=new at(a),u=new it([c],{width:"100%",height:q(s),viewBox:"0 0 "+n+" "+i,preserveAspectRatio:"none"});return{span:te.makeSvgSpan([],[u],e),minWidth:0,height:s}}var d,p,g,f=[],m=Ze[r],[y,v,x]=m,b=x/1e3,w=y.length;if(1===w)d=["hide-tail"],p=[m[3]];else if(2===w)d=["halfarrow-left","halfarrow-right"],p=["xMinYMin","xMaxYMin"];else{if(3!==w)throw new Error("Correct katexImagesData or update code here to support\n "+w+" children.");d=["brace-left","brace-center","brace-right"],p=["xMinYMin","xMidYMin","xMaxYMin"]}for(var k=0;k0&&(n.style.minWidth=q(r)),n};function Ge(t,e){if(!t||t.type!==e)throw new Error("Expected node of type "+e+", but got "+(t?"node of type "+t.type:String(t)));return t}function Ve(t){var e=qe(t);if(!e)throw new Error("Expected node of symbol group type, but got "+(t?"node of type "+t.type:String(t)));return e}function qe(t){return t&&("atom"===t.type||ct.hasOwnProperty(t.type))?t:null}var je=(t,e)=>{var n,r,i;t&&"supsub"===t.type?(n=(r=Ge(t.base,"accent")).base,t.base=n,i=function(t){if(t instanceof J)return t;throw new Error("Expected span but got "+String(t)+".")}(_e(t,e)),t.base=r):n=(r=Ge(t,"accent")).base;var a=_e(n,e.havingCrampedStyle()),s=0;if(r.isShifty&&f(n)){var o=g(n);s=ot(_e(o,e.havingCrampedStyle())).skew}var l,c="\\c"===r.label,h=c?a.height+a.depth:Math.min(a.height,e.fontMetrics().xHeight);if(r.isStretchy)l=Ue(r,e),l=te.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:a},{type:"elem",elem:l,wrapperClasses:["svg-align"],wrapperStyle:s>0?{width:"calc(100% - "+q(2*s)+")",marginLeft:q(2*s)}:void 0}]},e);else{var u,d;"\\vec"===r.label?(u=te.staticSvg("vec",e),d=te.svgData.vec[1]):((u=ot(u=te.makeOrd({mode:r.mode,text:r.label},e,"textord"))).italic=0,d=u.width,c&&(h+=u.depth)),l=te.makeSpan(["accent-body"],[u]);var p="\\textcircled"===r.label;p&&(l.classes.push("accent-full"),h=a.height);var m=s;p||(m-=d/2),l.style.left=q(m),"\\textcircled"===r.label&&(l.style.top=".2em"),l=te.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:a},{type:"kern",size:-h},{type:"elem",elem:l}]},e)}var y=te.makeSpan(["mord","accent"],[l],e);return i?(i.children[0]=y,i.height=Math.max(y.height,i.height),i.classes[0]="mord",i):y},He=(t,e)=>{var n=t.isStretchy?Ye(t.label):new Me.MathNode("mo",[Ne(t.label,t.mode)]),r=new Me.MathNode("mover",[$e(t.base,e),n]);return r.setAttribute("accent","true"),r},Xe=new RegExp(["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring"].map((t=>"\\"+t)).join("|"));ce({type:"accent",names:["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring","\\widecheck","\\widehat","\\widetilde","\\overrightarrow","\\overleftarrow","\\Overrightarrow","\\overleftrightarrow","\\overgroup","\\overlinesegment","\\overleftharpoon","\\overrightharpoon"],props:{numArgs:1},handler:(t,e)=>{var n=ue(e[0]),r=!Xe.test(t.funcName),i=!r||"\\widehat"===t.funcName||"\\widetilde"===t.funcName||"\\widecheck"===t.funcName;return{type:"accent",mode:t.parser.mode,label:t.funcName,isStretchy:r,isShifty:i,base:n}},htmlBuilder:je,mathmlBuilder:He}),ce({type:"accent",names:["\\'","\\`","\\^","\\~","\\=","\\u","\\.",'\\"',"\\c","\\r","\\H","\\v","\\textcircled"],props:{numArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["primitive"]},handler:(t,e)=>{var n=e[0],r=t.parser.mode;return"math"===r&&(t.parser.settings.reportNonstrict("mathVsTextAccents","LaTeX's accent "+t.funcName+" works only in text mode"),r="text"),{type:"accent",mode:r,label:t.funcName,isStretchy:!1,isShifty:!0,base:n}},htmlBuilder:je,mathmlBuilder:He}),ce({type:"accentUnder",names:["\\underleftarrow","\\underrightarrow","\\underleftrightarrow","\\undergroup","\\underlinesegment","\\utilde"],props:{numArgs:1},handler:(t,e)=>{var{parser:n,funcName:r}=t,i=e[0];return{type:"accentUnder",mode:n.mode,label:r,base:i}},htmlBuilder:(t,e)=>{var n=_e(t.base,e),r=Ue(t,e),i="\\utilde"===t.label?.12:0,a=te.makeVList({positionType:"top",positionData:n.height,children:[{type:"elem",elem:r,wrapperClasses:["svg-align"]},{type:"kern",size:i},{type:"elem",elem:n}]},e);return te.makeSpan(["mord","accentunder"],[a],e)},mathmlBuilder:(t,e)=>{var n=Ye(t.label),r=new Me.MathNode("munder",[$e(t.base,e),n]);return r.setAttribute("accentunder","true"),r}});var Ke=t=>{var e=new Me.MathNode("mpadded",t?[t]:[]);return e.setAttribute("width","+0.6em"),e.setAttribute("lspace","0.3em"),e};ce({type:"xArrow",names:["\\xleftarrow","\\xrightarrow","\\xLeftarrow","\\xRightarrow","\\xleftrightarrow","\\xLeftrightarrow","\\xhookleftarrow","\\xhookrightarrow","\\xmapsto","\\xrightharpoondown","\\xrightharpoonup","\\xleftharpoondown","\\xleftharpoonup","\\xrightleftharpoons","\\xleftrightharpoons","\\xlongequal","\\xtwoheadrightarrow","\\xtwoheadleftarrow","\\xtofrom","\\xrightleftarrows","\\xrightequilibrium","\\xleftequilibrium","\\\\cdrightarrow","\\\\cdleftarrow","\\\\cdlongequal"],props:{numArgs:1,numOptionalArgs:1},handler(t,e,n){var{parser:r,funcName:i}=t;return{type:"xArrow",mode:r.mode,label:i,body:e[0],below:n[0]}},htmlBuilder(t,e){var n,r=e.style,i=e.havingStyle(r.sup()),a=te.wrapFragment(_e(t.body,i,e),e),s="\\x"===t.label.slice(0,2)?"x":"cd";a.classes.push(s+"-arrow-pad"),t.below&&(i=e.havingStyle(r.sub()),(n=te.wrapFragment(_e(t.below,i,e),e)).classes.push(s+"-arrow-pad"));var o,l=Ue(t,e),c=-e.fontMetrics().axisHeight+.5*l.height,h=-e.fontMetrics().axisHeight-.5*l.height-.111;if((a.depth>.25||"\\xleftequilibrium"===t.label)&&(h-=a.depth),n){var u=-e.fontMetrics().axisHeight+n.height+.5*l.height+.111;o=te.makeVList({positionType:"individualShift",children:[{type:"elem",elem:a,shift:h},{type:"elem",elem:l,shift:c},{type:"elem",elem:n,shift:u}]},e)}else o=te.makeVList({positionType:"individualShift",children:[{type:"elem",elem:a,shift:h},{type:"elem",elem:l,shift:c}]},e);return o.children[0].children[0].children[1].classes.push("svg-align"),te.makeSpan(["mrel","x-arrow"],[o],e)},mathmlBuilder(t,e){var n,r=Ye(t.label);if(r.setAttribute("minsize","x"===t.label.charAt(0)?"1.75em":"3.0em"),t.body){var i=Ke($e(t.body,e));if(t.below){var a=Ke($e(t.below,e));n=new Me.MathNode("munderover",[r,a,i])}else n=new Me.MathNode("mover",[r,i])}else if(t.below){var s=Ke($e(t.below,e));n=new Me.MathNode("munder",[r,s])}else n=Ke(),n=new Me.MathNode("mover",[r,n]);return n}});var Qe=te.makeSpan;function Je(t,e){var n=ve(t.body,e,!0);return Qe([t.mclass],n,e)}function tn(t,e){var n,r=Oe(t.body,e);return"minner"===t.mclass?n=new Me.MathNode("mpadded",r):"mord"===t.mclass?t.isCharacterBox?(n=r[0]).type="mi":n=new Me.MathNode("mi",r):(t.isCharacterBox?(n=r[0]).type="mo":n=new Me.MathNode("mo",r),"mbin"===t.mclass?(n.attributes.lspace="0.22em",n.attributes.rspace="0.22em"):"mpunct"===t.mclass?(n.attributes.lspace="0em",n.attributes.rspace="0.17em"):"mopen"===t.mclass||"mclose"===t.mclass?(n.attributes.lspace="0em",n.attributes.rspace="0em"):"minner"===t.mclass&&(n.attributes.lspace="0.0556em",n.attributes.width="+0.1111em")),n}ce({type:"mclass",names:["\\mathord","\\mathbin","\\mathrel","\\mathopen","\\mathclose","\\mathpunct","\\mathinner"],props:{numArgs:1,primitive:!0},handler(t,e){var{parser:n,funcName:r}=t,i=e[0];return{type:"mclass",mode:n.mode,mclass:"m"+r.slice(5),body:de(i),isCharacterBox:f(i)}},htmlBuilder:Je,mathmlBuilder:tn});var en=t=>{var e="ordgroup"===t.type&&t.body.length?t.body[0]:t;return"atom"!==e.type||"bin"!==e.family&&"rel"!==e.family?"mord":"m"+e.family};ce({type:"mclass",names:["\\@binrel"],props:{numArgs:2},handler(t,e){var{parser:n}=t;return{type:"mclass",mode:n.mode,mclass:en(e[0]),body:de(e[1]),isCharacterBox:f(e[1])}}}),ce({type:"mclass",names:["\\stackrel","\\overset","\\underset"],props:{numArgs:2},handler(t,e){var n,{parser:r,funcName:i}=t,a=e[1],s=e[0];n="\\stackrel"!==i?en(a):"mrel";var o={type:"op",mode:a.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:"\\stackrel"!==i,body:de(a)},l={type:"supsub",mode:s.mode,base:o,sup:"\\underset"===i?null:s,sub:"\\underset"===i?s:null};return{type:"mclass",mode:r.mode,mclass:n,body:[l],isCharacterBox:f(l)}},htmlBuilder:Je,mathmlBuilder:tn}),ce({type:"pmb",names:["\\pmb"],props:{numArgs:1,allowedInText:!0},handler(t,e){var{parser:n}=t;return{type:"pmb",mode:n.mode,mclass:en(e[0]),body:de(e[0])}},htmlBuilder(t,e){var n=ve(t.body,e,!0),r=te.makeSpan([t.mclass],n,e);return r.style.textShadow="0.02em 0.01em 0.04px",r},mathmlBuilder(t,e){var n=Oe(t.body,e),r=new Me.MathNode("mstyle",n);return r.setAttribute("style","text-shadow: 0.02em 0.01em 0.04px"),r}});var nn={">":"\\\\cdrightarrow","<":"\\\\cdleftarrow","=":"\\\\cdlongequal",A:"\\uparrow",V:"\\downarrow","|":"\\Vert",".":"no arrow"},rn=t=>"textord"===t.type&&"@"===t.text;function an(t,e,n){var r=nn[t];switch(r){case"\\\\cdrightarrow":case"\\\\cdleftarrow":return n.callFunction(r,[e[0]],[e[1]]);case"\\uparrow":case"\\downarrow":var i={type:"atom",text:r,mode:"math",family:"rel"},a={type:"ordgroup",mode:"math",body:[n.callFunction("\\\\cdleft",[e[0]],[]),n.callFunction("\\Big",[i],[]),n.callFunction("\\\\cdright",[e[1]],[])]};return n.callFunction("\\\\cdparent",[a],[]);case"\\\\cdlongequal":return n.callFunction("\\\\cdlongequal",[],[]);case"\\Vert":return n.callFunction("\\Big",[{type:"textord",text:"\\Vert",mode:"math"}],[]);default:return{type:"textord",text:" ",mode:"math"}}}ce({type:"cdlabel",names:["\\\\cdleft","\\\\cdright"],props:{numArgs:1},handler(t,e){var{parser:n,funcName:r}=t;return{type:"cdlabel",mode:n.mode,side:r.slice(4),label:e[0]}},htmlBuilder(t,e){var n=e.havingStyle(e.style.sup()),r=te.wrapFragment(_e(t.label,n,e),e);return r.classes.push("cd-label-"+t.side),r.style.bottom=q(.8-r.depth),r.height=0,r.depth=0,r},mathmlBuilder(t,e){var n=new Me.MathNode("mrow",[$e(t.label,e)]);return(n=new Me.MathNode("mpadded",[n])).setAttribute("width","0"),"left"===t.side&&n.setAttribute("lspace","-1width"),n.setAttribute("voffset","0.7em"),(n=new Me.MathNode("mstyle",[n])).setAttribute("displaystyle","false"),n.setAttribute("scriptlevel","1"),n}}),ce({type:"cdlabelparent",names:["\\\\cdparent"],props:{numArgs:1},handler(t,e){var{parser:n}=t;return{type:"cdlabelparent",mode:n.mode,fragment:e[0]}},htmlBuilder(t,e){var n=te.wrapFragment(_e(t.fragment,e),e);return n.classes.push("cd-vert-arrow"),n},mathmlBuilder:(t,e)=>new Me.MathNode("mrow",[$e(t.fragment,e)])}),ce({type:"textord",names:["\\@char"],props:{numArgs:1,allowedInText:!0},handler(t,e){for(var{parser:n}=t,r=Ge(e[0],"ordgroup").body,i="",s=0;s=1114111)throw new a("\\@char with invalid code point "+i);return l<=65535?o=String.fromCharCode(l):(l-=65536,o=String.fromCharCode(55296+(l>>10),56320+(1023&l))),{type:"textord",mode:n.mode,text:o}}});var sn=(t,e)=>{var n=ve(t.body,e.withColor(t.color),!1);return te.makeFragment(n)},on=(t,e)=>{var n=Oe(t.body,e.withColor(t.color)),r=new Me.MathNode("mstyle",n);return r.setAttribute("mathcolor",t.color),r};ce({type:"color",names:["\\textcolor"],props:{numArgs:2,allowedInText:!0,argTypes:["color","original"]},handler(t,e){var{parser:n}=t,r=Ge(e[0],"color-token").color,i=e[1];return{type:"color",mode:n.mode,color:r,body:de(i)}},htmlBuilder:sn,mathmlBuilder:on}),ce({type:"color",names:["\\color"],props:{numArgs:1,allowedInText:!0,argTypes:["color"]},handler(t,e){var{parser:n,breakOnTokenText:r}=t,i=Ge(e[0],"color-token").color;n.gullet.macros.set("\\current@color",i);var a=n.parseExpression(!0,r);return{type:"color",mode:n.mode,color:i,body:a}},htmlBuilder:sn,mathmlBuilder:on}),ce({type:"cr",names:["\\\\"],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler(t,e,n){var{parser:r}=t,i="["===r.gullet.future().text?r.parseSizeGroup(!0):null,a=!r.settings.displayMode||!r.settings.useStrictBehavior("newLineInDisplayMode","In LaTeX, \\\\ or \\newline does nothing in display mode");return{type:"cr",mode:r.mode,newLine:a,size:i&&Ge(i,"size").value}},htmlBuilder(t,e){var n=te.makeSpan(["mspace"],[],e);return t.newLine&&(n.classes.push("newline"),t.size&&(n.style.marginTop=q(V(t.size,e)))),n},mathmlBuilder(t,e){var n=new Me.MathNode("mspace");return t.newLine&&(n.setAttribute("linebreak","newline"),t.size&&n.setAttribute("height",q(V(t.size,e)))),n}});var ln={"\\global":"\\global","\\long":"\\\\globallong","\\\\globallong":"\\\\globallong","\\def":"\\gdef","\\gdef":"\\gdef","\\edef":"\\xdef","\\xdef":"\\xdef","\\let":"\\\\globallet","\\futurelet":"\\\\globalfuture"},cn=t=>{var e=t.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(e))throw new a("Expected a control sequence",t);return e},hn=(t,e,n,r)=>{var i=t.gullet.macros.get(n.text);null==i&&(n.noexpand=!0,i={tokens:[n],numArgs:0,unexpandable:!t.gullet.isExpandable(n.text)}),t.gullet.macros.set(e,i,r)};ce({type:"internal",names:["\\global","\\long","\\\\globallong"],props:{numArgs:0,allowedInText:!0},handler(t){var{parser:e,funcName:n}=t;e.consumeSpaces();var r=e.fetch();if(ln[r.text])return"\\global"!==n&&"\\\\globallong"!==n||(r.text=ln[r.text]),Ge(e.parseFunction(),"internal");throw new a("Invalid token after macro prefix",r)}}),ce({type:"internal",names:["\\def","\\gdef","\\edef","\\xdef"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:e,funcName:n}=t,r=e.gullet.popToken(),i=r.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(i))throw new a("Expected a control sequence",r);for(var s,o=0,l=[[]];"{"!==e.gullet.future().text;)if("#"===(r=e.gullet.popToken()).text){if("{"===e.gullet.future().text){s=e.gullet.future(),l[o].push("{");break}if(r=e.gullet.popToken(),!/^[1-9]$/.test(r.text))throw new a('Invalid argument number "'+r.text+'"');if(parseInt(r.text)!==o+1)throw new a('Argument number "'+r.text+'" out of order');o++,l.push([])}else{if("EOF"===r.text)throw new a("Expected a macro definition");l[o].push(r.text)}var{tokens:c}=e.gullet.consumeArg();return s&&c.unshift(s),"\\edef"!==n&&"\\xdef"!==n||(c=e.gullet.expandTokens(c)).reverse(),e.gullet.macros.set(i,{tokens:c,numArgs:o,delimiters:l},n===ln[n]),{type:"internal",mode:e.mode}}}),ce({type:"internal",names:["\\let","\\\\globallet"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:e,funcName:n}=t,r=cn(e.gullet.popToken());e.gullet.consumeSpaces();var i=(t=>{var e=t.gullet.popToken();return"="===e.text&&" "===(e=t.gullet.popToken()).text&&(e=t.gullet.popToken()),e})(e);return hn(e,r,i,"\\\\globallet"===n),{type:"internal",mode:e.mode}}}),ce({type:"internal",names:["\\futurelet","\\\\globalfuture"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t){var{parser:e,funcName:n}=t,r=cn(e.gullet.popToken()),i=e.gullet.popToken(),a=e.gullet.popToken();return hn(e,r,a,"\\\\globalfuture"===n),e.gullet.pushToken(a),e.gullet.pushToken(i),{type:"internal",mode:e.mode}}});var un=function(t,e,n){var r=$(ht.math[t]&&ht.math[t].replace||t,e,n);if(!r)throw new Error("Unsupported symbol "+t+" and font size "+e+".");return r},dn=function(t,e,n,r){var i=n.havingBaseStyle(e),a=te.makeSpan(r.concat(i.sizingClasses(n)),[t],n),s=i.sizeMultiplier/n.sizeMultiplier;return a.height*=s,a.depth*=s,a.maxFontSize=i.sizeMultiplier,a},pn=function(t,e,n){var r=e.havingBaseStyle(n),i=(1-e.sizeMultiplier/r.sizeMultiplier)*e.fontMetrics().axisHeight;t.classes.push("delimcenter"),t.style.top=q(i),t.height-=i,t.depth+=i},gn=function(t,e,n,r,i,a){var s=function(t,e,n,r){return te.makeSymbol(t,"Size"+e+"-Regular",n,r)}(t,e,i,r),o=dn(te.makeSpan(["delimsizing","size"+e],[s],r),A.TEXT,r,a);return n&&pn(o,r,A.TEXT),o},fn=function(t,e,n){return{type:"elem",elem:te.makeSpan(["delimsizinginner","Size1-Regular"===e?"delim-size1":"delim-size4"],[te.makeSpan([],[te.makeSymbol(t,e,n)])])}},mn=function(t,e,n){var r=D["Size4-Regular"][t.charCodeAt(0)]?D["Size4-Regular"][t.charCodeAt(0)][4]:D["Size1-Regular"][t.charCodeAt(0)][4],i=new at("inner",function(t,e){switch(t){case"⎜":return"M291 0 H417 V"+e+" H291z M291 0 H417 V"+e+" H291z";case"∣":return"M145 0 H188 V"+e+" H145z M145 0 H188 V"+e+" H145z";case"∥":return"M145 0 H188 V"+e+" H145z M145 0 H188 V"+e+" H145zM367 0 H410 V"+e+" H367z M367 0 H410 V"+e+" H367z";case"⎟":return"M457 0 H583 V"+e+" H457z M457 0 H583 V"+e+" H457z";case"⎢":return"M319 0 H403 V"+e+" H319z M319 0 H403 V"+e+" H319z";case"⎥":return"M263 0 H347 V"+e+" H263z M263 0 H347 V"+e+" H263z";case"⎪":return"M384 0 H504 V"+e+" H384z M384 0 H504 V"+e+" H384z";case"⏐":return"M312 0 H355 V"+e+" H312z M312 0 H355 V"+e+" H312z";case"‖":return"M257 0 H300 V"+e+" H257z M257 0 H300 V"+e+" H257zM478 0 H521 V"+e+" H478z M478 0 H521 V"+e+" H478z";default:return""}}(t,Math.round(1e3*e))),a=new it([i],{width:q(r),height:q(e),style:"width:"+q(r),viewBox:"0 0 "+1e3*r+" "+Math.round(1e3*e),preserveAspectRatio:"xMinYMin"}),s=te.makeSvgSpan([],[a],n);return s.height=e,s.style.height=q(e),s.style.width=q(r),{type:"elem",elem:s}},yn={type:"kern",size:-.008},vn=["|","\\lvert","\\rvert","\\vert"],xn=["\\|","\\lVert","\\rVert","\\Vert"],bn=function(t,e,n,r,i,a){var s,o,l,c,u="",d=0;s=l=c=t,o=null;var p="Size1-Regular";"\\uparrow"===t?l=c="⏐":"\\Uparrow"===t?l=c="‖":"\\downarrow"===t?s=l="⏐":"\\Downarrow"===t?s=l="‖":"\\updownarrow"===t?(s="\\uparrow",l="⏐",c="\\downarrow"):"\\Updownarrow"===t?(s="\\Uparrow",l="‖",c="\\Downarrow"):h(vn,t)?(l="∣",u="vert",d=333):h(xn,t)?(l="∥",u="doublevert",d=556):"["===t||"\\lbrack"===t?(s="⎡",l="⎢",c="⎣",p="Size4-Regular",u="lbrack",d=667):"]"===t||"\\rbrack"===t?(s="⎤",l="⎥",c="⎦",p="Size4-Regular",u="rbrack",d=667):"\\lfloor"===t||"⌊"===t?(l=s="⎢",c="⎣",p="Size4-Regular",u="lfloor",d=667):"\\lceil"===t||"⌈"===t?(s="⎡",l=c="⎢",p="Size4-Regular",u="lceil",d=667):"\\rfloor"===t||"⌋"===t?(l=s="⎥",c="⎦",p="Size4-Regular",u="rfloor",d=667):"\\rceil"===t||"⌉"===t?(s="⎤",l=c="⎥",p="Size4-Regular",u="rceil",d=667):"("===t||"\\lparen"===t?(s="⎛",l="⎜",c="⎝",p="Size4-Regular",u="lparen",d=875):")"===t||"\\rparen"===t?(s="⎞",l="⎟",c="⎠",p="Size4-Regular",u="rparen",d=875):"\\{"===t||"\\lbrace"===t?(s="⎧",o="⎨",c="⎩",l="⎪",p="Size4-Regular"):"\\}"===t||"\\rbrace"===t?(s="⎫",o="⎬",c="⎭",l="⎪",p="Size4-Regular"):"\\lgroup"===t||"⟮"===t?(s="⎧",c="⎩",l="⎪",p="Size4-Regular"):"\\rgroup"===t||"⟯"===t?(s="⎫",c="⎭",l="⎪",p="Size4-Regular"):"\\lmoustache"===t||"⎰"===t?(s="⎧",c="⎭",l="⎪",p="Size4-Regular"):"\\rmoustache"!==t&&"⎱"!==t||(s="⎫",c="⎩",l="⎪",p="Size4-Regular");var g=un(s,p,i),f=g.height+g.depth,m=un(l,p,i),y=m.height+m.depth,v=un(c,p,i),x=v.height+v.depth,b=0,w=1;if(null!==o){var k=un(o,p,i);b=k.height+k.depth,w=2}var T=f+x+b,_=T+Math.max(0,Math.ceil((e-T)/(w*y)))*w*y,E=r.fontMetrics().axisHeight;n&&(E*=r.sizeMultiplier);var S=_/2-E,C=[];if(u.length>0){var L=_-f-x,M=Math.round(1e3*_),N=function(t,e){switch(t){case"lbrack":return"M403 1759 V84 H666 V0 H319 V1759 v"+e+" v1759 h347 v-84\nH403z M403 1759 V0 H319 V1759 v"+e+" v1759 h84z";case"rbrack":return"M347 1759 V0 H0 V84 H263 V1759 v"+e+" v1759 H0 v84 H347z\nM347 1759 V0 H263 V1759 v"+e+" v1759 h84z";case"vert":return"M145 15 v585 v"+e+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-e+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v"+e+" v585 h43z";case"doublevert":return"M145 15 v585 v"+e+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-e+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v"+e+" v585 h43z\nM367 15 v585 v"+e+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-e+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M410 15 H367 v585 v"+e+" v585 h43z";case"lfloor":return"M319 602 V0 H403 V602 v"+e+" v1715 h263 v84 H319z\nMM319 602 V0 H403 V602 v"+e+" v1715 H319z";case"rfloor":return"M319 602 V0 H403 V602 v"+e+" v1799 H0 v-84 H319z\nMM319 602 V0 H403 V602 v"+e+" v1715 H319z";case"lceil":return"M403 1759 V84 H666 V0 H319 V1759 v"+e+" v602 h84z\nM403 1759 V0 H319 V1759 v"+e+" v602 h84z";case"rceil":return"M347 1759 V0 H0 V84 H263 V1759 v"+e+" v602 h84z\nM347 1759 V0 h-84 V1759 v"+e+" v602 h84z";case"lparen":return"M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1\nc-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349,\n-36,557 l0,"+(e+84)+"c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210,\n949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9\nc0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5,\n-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189\nl0,-"+(e+92)+"c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3,\n-210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z";case"rparen":return"M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3,\n63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5\nc11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,"+(e+9)+"\nc-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664\nc-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11\nc0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17\nc242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558\nl0,-"+(e+144)+"c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7,\n-470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z";default:throw new Error("Unknown stretchy delimiter.")}}(u,Math.round(1e3*L)),I=new at(u,N),R=(d/1e3).toFixed(3)+"em",D=(M/1e3).toFixed(3)+"em",O=new it([I],{width:R,height:D,viewBox:"0 0 "+d+" "+M}),P=te.makeSvgSpan([],[O],r);P.height=M/1e3,P.style.width=R,P.style.height=D,C.push({type:"elem",elem:P})}else{if(C.push(fn(c,p,i)),C.push(yn),null===o){var $=_-f-x+.016;C.push(mn(l,$,r))}else{var B=(_-f-x-b)/2+.016;C.push(mn(l,B,r)),C.push(yn),C.push(fn(o,p,i)),C.push(yn),C.push(mn(l,B,r))}C.push(yn),C.push(fn(s,p,i))}var F=r.havingBaseStyle(A.TEXT),W=te.makeVList({positionType:"bottom",positionData:S,children:C},F);return dn(te.makeSpan(["delimsizing","mult"],[W],F),A.TEXT,r,a)},wn=.08,kn=function(t,e,n,r,i){var a=function(t,e,n){e*=1e3;var r="";switch(t){case"sqrtMain":r=function(t,e){return"M95,"+(622+t+80)+"\nc-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14\nc0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54\nc44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10\ns173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429\nc69,-144,104.5,-217.7,106.5,-221\nl"+t/2.075+" -"+t+"\nc5.3,-9.3,12,-14,20,-14\nH400000v"+(40+t)+"H845.2724\ns-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7\nc-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z\nM"+(834+t)+" 80h400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize1":r=function(t,e){return"M263,"+(601+t+80)+"c0.7,0,18,39.7,52,119\nc34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120\nc340,-704.7,510.7,-1060.3,512,-1067\nl"+t/2.084+" -"+t+"\nc4.7,-7.3,11,-11,19,-11\nH40000v"+(40+t)+"H1012.3\ns-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232\nc-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1\ns-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26\nc-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z\nM"+(1001+t)+" 80h400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize2":r=function(t,e){return"M983 "+(10+t+80)+"\nl"+t/3.13+" -"+t+"\nc4,-6.7,10,-10,18,-10 H400000v"+(40+t)+"\nH1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7\ns-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744\nc-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30\nc26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722\nc56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5\nc53.7,-170.3,84.5,-266.8,92.5,-289.5z\nM"+(1001+t)+" 80h400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize3":r=function(t,e){return"M424,"+(2398+t+80)+"\nc-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514\nc0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20\ns-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121\ns209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081\nl"+t/4.223+" -"+t+"c4,-6.7,10,-10,18,-10 H400000\nv"+(40+t)+"H1014.6\ns-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185\nc-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2z M"+(1001+t)+" 80\nh400000v"+(40+t)+"h-400000z"}(e);break;case"sqrtSize4":r=function(t,e){return"M473,"+(2713+t+80)+"\nc339.3,-1799.3,509.3,-2700,510,-2702 l"+t/5.298+" -"+t+"\nc3.3,-7.3,9.3,-11,18,-11 H400000v"+(40+t)+"H1017.7\ns-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200\nc0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26\ns76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104,\n606zM"+(1001+t)+" 80h400000v"+(40+t)+"H1017.7z"}(e);break;case"sqrtTall":r=function(t,e,n){return"M702 "+(t+80)+"H400000"+(40+t)+"\nH742v"+(n-54-80-t)+"l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1\nh-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170\nc-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667\n219 661 l218 661zM702 80H400000v"+(40+t)+"H742z"}(e,0,n)}return r}(t,r,n),s=new at(t,a),o=new it([s],{width:"400em",height:q(e),viewBox:"0 0 400000 "+n,preserveAspectRatio:"xMinYMin slice"});return te.makeSvgSpan(["hide-tail"],[o],i)},Tn=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","\\surd"],_n=["\\uparrow","\\downarrow","\\updownarrow","\\Uparrow","\\Downarrow","\\Updownarrow","|","\\|","\\vert","\\Vert","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱"],En=["<",">","\\langle","\\rangle","/","\\backslash","\\lt","\\gt"],Sn=[0,1.2,1.8,2.4,3],Cn=[{type:"small",style:A.SCRIPTSCRIPT},{type:"small",style:A.SCRIPT},{type:"small",style:A.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4}],An=[{type:"small",style:A.SCRIPTSCRIPT},{type:"small",style:A.SCRIPT},{type:"small",style:A.TEXT},{type:"stack"}],Ln=[{type:"small",style:A.SCRIPTSCRIPT},{type:"small",style:A.SCRIPT},{type:"small",style:A.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4},{type:"stack"}],Mn=function(t){if("small"===t.type)return"Main-Regular";if("large"===t.type)return"Size"+t.size+"-Regular";if("stack"===t.type)return"Size4-Regular";throw new Error("Add support for delim type '"+t.type+"' here.")},Nn=function(t,e,n,r){for(var i=Math.min(2,3-r.style.size);ie)return n[i]}return n[n.length-1]},In=function(t,e,n,r,i,a){var s;"<"===t||"\\lt"===t||"⟨"===t?t="\\langle":">"!==t&&"\\gt"!==t&&"⟩"!==t||(t="\\rangle"),s=h(En,t)?Cn:h(Tn,t)?Ln:An;var o=Nn(t,e,s,r);return"small"===o.type?function(t,e,n,r,i,a){var s=te.makeSymbol(t,"Main-Regular",i,r),o=dn(s,e,r,a);return n&&pn(o,r,e),o}(t,o.style,n,r,i,a):"large"===o.type?gn(t,o.size,n,r,i,a):bn(t,e,n,r,i,a)},Rn={sqrtImage:function(t,e){var n,r,i=e.havingBaseSizing(),a=Nn("\\surd",t*i.sizeMultiplier,Ln,i),s=i.sizeMultiplier,o=Math.max(0,e.minRuleThickness-e.fontMetrics().sqrtRuleThickness),l=0,c=0,h=0;return"small"===a.type?(t<1?s=1:t<1.4&&(s=.7),c=(1+o)/s,(n=kn("sqrtMain",l=(1+o+wn)/s,h=1e3+1e3*o+80,o,e)).style.minWidth="0.853em",r=.833/s):"large"===a.type?(h=1080*Sn[a.size],c=(Sn[a.size]+o)/s,l=(Sn[a.size]+o+wn)/s,(n=kn("sqrtSize"+a.size,l,h,o,e)).style.minWidth="1.02em",r=1/s):(l=t+o+wn,c=t+o,h=Math.floor(1e3*t+o)+80,(n=kn("sqrtTall",l,h,o,e)).style.minWidth="0.742em",r=1.056),n.height=c,n.style.height=q(l),{span:n,advanceWidth:r,ruleWidth:(e.fontMetrics().sqrtRuleThickness+o)*s}},sizedDelim:function(t,e,n,r,i){if("<"===t||"\\lt"===t||"⟨"===t?t="\\langle":">"!==t&&"\\gt"!==t&&"⟩"!==t||(t="\\rangle"),h(Tn,t)||h(En,t))return gn(t,e,!1,n,r,i);if(h(_n,t))return bn(t,Sn[e],!1,n,r,i);throw new a("Illegal delimiter: '"+t+"'")},sizeToMaxHeight:Sn,customSizedDelim:In,leftRightDelim:function(t,e,n,r,i,a){var s=r.fontMetrics().axisHeight*r.sizeMultiplier,o=5/r.fontMetrics().ptPerEm,l=Math.max(e-s,n+s),c=Math.max(l/500*901,2*l-o);return In(t,c,!0,r,i,a)}},Dn={"\\bigl":{mclass:"mopen",size:1},"\\Bigl":{mclass:"mopen",size:2},"\\biggl":{mclass:"mopen",size:3},"\\Biggl":{mclass:"mopen",size:4},"\\bigr":{mclass:"mclose",size:1},"\\Bigr":{mclass:"mclose",size:2},"\\biggr":{mclass:"mclose",size:3},"\\Biggr":{mclass:"mclose",size:4},"\\bigm":{mclass:"mrel",size:1},"\\Bigm":{mclass:"mrel",size:2},"\\biggm":{mclass:"mrel",size:3},"\\Biggm":{mclass:"mrel",size:4},"\\big":{mclass:"mord",size:1},"\\Big":{mclass:"mord",size:2},"\\bigg":{mclass:"mord",size:3},"\\Bigg":{mclass:"mord",size:4}},On=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","<",">","\\langle","⟨","\\rangle","⟩","\\lt","\\gt","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱","/","\\backslash","|","\\vert","\\|","\\Vert","\\uparrow","\\Uparrow","\\downarrow","\\Downarrow","\\updownarrow","\\Updownarrow","."];function Pn(t,e){var n=qe(t);if(n&&h(On,n.text))return n;throw new a(n?"Invalid delimiter '"+n.text+"' after '"+e.funcName+"'":"Invalid delimiter type '"+t.type+"'",t)}function $n(t){if(!t.body)throw new Error("Bug: The leftright ParseNode wasn't fully parsed.")}ce({type:"delimsizing",names:["\\bigl","\\Bigl","\\biggl","\\Biggl","\\bigr","\\Bigr","\\biggr","\\Biggr","\\bigm","\\Bigm","\\biggm","\\Biggm","\\big","\\Big","\\bigg","\\Bigg"],props:{numArgs:1,argTypes:["primitive"]},handler:(t,e)=>{var n=Pn(e[0],t);return{type:"delimsizing",mode:t.parser.mode,size:Dn[t.funcName].size,mclass:Dn[t.funcName].mclass,delim:n.text}},htmlBuilder:(t,e)=>"."===t.delim?te.makeSpan([t.mclass]):Rn.sizedDelim(t.delim,t.size,e,t.mode,[t.mclass]),mathmlBuilder:t=>{var e=[];"."!==t.delim&&e.push(Ne(t.delim,t.mode));var n=new Me.MathNode("mo",e);"mopen"===t.mclass||"mclose"===t.mclass?n.setAttribute("fence","true"):n.setAttribute("fence","false"),n.setAttribute("stretchy","true");var r=q(Rn.sizeToMaxHeight[t.size]);return n.setAttribute("minsize",r),n.setAttribute("maxsize",r),n}}),ce({type:"leftright-right",names:["\\right"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var n=t.parser.gullet.macros.get("\\current@color");if(n&&"string"!=typeof n)throw new a("\\current@color set to non-string in \\right");return{type:"leftright-right",mode:t.parser.mode,delim:Pn(e[0],t).text,color:n}}}),ce({type:"leftright",names:["\\left"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var n=Pn(e[0],t),r=t.parser;++r.leftrightDepth;var i=r.parseExpression(!1);--r.leftrightDepth,r.expect("\\right",!1);var a=Ge(r.parseFunction(),"leftright-right");return{type:"leftright",mode:r.mode,body:i,left:n.text,right:a.delim,rightColor:a.color}},htmlBuilder:(t,e)=>{$n(t);for(var n,r,i=ve(t.body,e,!0,["mopen","mclose"]),a=0,s=0,o=!1,l=0;l{$n(t);var n=Oe(t.body,e);if("."!==t.left){var r=new Me.MathNode("mo",[Ne(t.left,t.mode)]);r.setAttribute("fence","true"),n.unshift(r)}if("."!==t.right){var i=new Me.MathNode("mo",[Ne(t.right,t.mode)]);i.setAttribute("fence","true"),t.rightColor&&i.setAttribute("mathcolor",t.rightColor),n.push(i)}return Ie(n)}}),ce({type:"middle",names:["\\middle"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var n=Pn(e[0],t);if(!t.parser.leftrightDepth)throw new a("\\middle without preceding \\left",n);return{type:"middle",mode:t.parser.mode,delim:n.text}},htmlBuilder:(t,e)=>{var n;if("."===t.delim)n=Te(e,[]);else{n=Rn.sizedDelim(t.delim,1,e,t.mode,[]);var r={delim:t.delim,options:e};n.isMiddle=r}return n},mathmlBuilder:(t,e)=>{var n="\\vert"===t.delim||"|"===t.delim?Ne("|","text"):Ne(t.delim,t.mode),r=new Me.MathNode("mo",[n]);return r.setAttribute("fence","true"),r.setAttribute("lspace","0.05em"),r.setAttribute("rspace","0.05em"),r}});var Bn=(t,e)=>{var n,r,i,a=te.wrapFragment(_e(t.body,e),e),s=t.label.slice(1),o=e.sizeMultiplier,l=0,c=f(t.body);if("sout"===s)(n=te.makeSpan(["stretchy","sout"])).height=e.fontMetrics().defaultRuleThickness/o,l=-.5*e.fontMetrics().xHeight;else if("phase"===s){var h=V({number:.6,unit:"pt"},e),u=V({number:.35,unit:"ex"},e);o/=e.havingBaseSizing().sizeMultiplier;var d=a.height+a.depth+h+u;a.style.paddingLeft=q(d/2+h);var p=Math.floor(1e3*d*o),g="M400000 "+(r=p)+" H0 L"+r/2+" 0 l65 45 L145 "+(r-80)+" H400000z",m=new it([new at("phase",g)],{width:"400em",height:q(p/1e3),viewBox:"0 0 400000 "+p,preserveAspectRatio:"xMinYMin slice"});(n=te.makeSvgSpan(["hide-tail"],[m],e)).style.height=q(d),l=a.depth+h+u}else{/cancel/.test(s)?c||a.classes.push("cancel-pad"):"angl"===s?a.classes.push("anglpad"):a.classes.push("boxpad");var y=0,v=0,x=0;/box/.test(s)?(x=Math.max(e.fontMetrics().fboxrule,e.minRuleThickness),v=y=e.fontMetrics().fboxsep+("colorbox"===s?0:x)):"angl"===s?(y=4*(x=Math.max(e.fontMetrics().defaultRuleThickness,e.minRuleThickness)),v=Math.max(0,.25-a.depth)):v=y=c?.2:0,n=function(t,e,n,r,i){var a,s=t.height+t.depth+n+r;if(/fbox|color|angl/.test(e)){if(a=te.makeSpan(["stretchy",e],[],i),"fbox"===e){var o=i.color&&i.getColor();o&&(a.style.borderColor=o)}}else{var l=[];/^[bx]cancel$/.test(e)&&l.push(new st({x1:"0",y1:"0",x2:"100%",y2:"100%","stroke-width":"0.046em"})),/^x?cancel$/.test(e)&&l.push(new st({x1:"0",y1:"100%",x2:"100%",y2:"0","stroke-width":"0.046em"}));var c=new it(l,{width:"100%",height:q(s)});a=te.makeSvgSpan([],[c],i)}return a.height=s,a.style.height=q(s),a}(a,s,y,v,e),/fbox|boxed|fcolorbox/.test(s)?(n.style.borderStyle="solid",n.style.borderWidth=q(x)):"angl"===s&&.049!==x&&(n.style.borderTopWidth=q(x),n.style.borderRightWidth=q(x)),l=a.depth+v,t.backgroundColor&&(n.style.backgroundColor=t.backgroundColor,t.borderColor&&(n.style.borderColor=t.borderColor))}if(t.backgroundColor)i=te.makeVList({positionType:"individualShift",children:[{type:"elem",elem:n,shift:l},{type:"elem",elem:a,shift:0}]},e);else{var b=/cancel|phase/.test(s)?["svg-align"]:[];i=te.makeVList({positionType:"individualShift",children:[{type:"elem",elem:a,shift:0},{type:"elem",elem:n,shift:l,wrapperClasses:b}]},e)}return/cancel/.test(s)&&(i.height=a.height,i.depth=a.depth),/cancel/.test(s)&&!c?te.makeSpan(["mord","cancel-lap"],[i],e):te.makeSpan(["mord"],[i],e)},Fn=(t,e)=>{var n=0,r=new Me.MathNode(t.label.indexOf("colorbox")>-1?"mpadded":"menclose",[$e(t.body,e)]);switch(t.label){case"\\cancel":r.setAttribute("notation","updiagonalstrike");break;case"\\bcancel":r.setAttribute("notation","downdiagonalstrike");break;case"\\phase":r.setAttribute("notation","phasorangle");break;case"\\sout":r.setAttribute("notation","horizontalstrike");break;case"\\fbox":r.setAttribute("notation","box");break;case"\\angl":r.setAttribute("notation","actuarial");break;case"\\fcolorbox":case"\\colorbox":if(n=e.fontMetrics().fboxsep*e.fontMetrics().ptPerEm,r.setAttribute("width","+"+2*n+"pt"),r.setAttribute("height","+"+2*n+"pt"),r.setAttribute("lspace",n+"pt"),r.setAttribute("voffset",n+"pt"),"\\fcolorbox"===t.label){var i=Math.max(e.fontMetrics().fboxrule,e.minRuleThickness);r.setAttribute("style","border: "+i+"em solid "+String(t.borderColor))}break;case"\\xcancel":r.setAttribute("notation","updiagonalstrike downdiagonalstrike")}return t.backgroundColor&&r.setAttribute("mathbackground",t.backgroundColor),r};ce({type:"enclose",names:["\\colorbox"],props:{numArgs:2,allowedInText:!0,argTypes:["color","text"]},handler(t,e,n){var{parser:r,funcName:i}=t,a=Ge(e[0],"color-token").color,s=e[1];return{type:"enclose",mode:r.mode,label:i,backgroundColor:a,body:s}},htmlBuilder:Bn,mathmlBuilder:Fn}),ce({type:"enclose",names:["\\fcolorbox"],props:{numArgs:3,allowedInText:!0,argTypes:["color","color","text"]},handler(t,e,n){var{parser:r,funcName:i}=t,a=Ge(e[0],"color-token").color,s=Ge(e[1],"color-token").color,o=e[2];return{type:"enclose",mode:r.mode,label:i,backgroundColor:s,borderColor:a,body:o}},htmlBuilder:Bn,mathmlBuilder:Fn}),ce({type:"enclose",names:["\\fbox"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!0},handler(t,e){var{parser:n}=t;return{type:"enclose",mode:n.mode,label:"\\fbox",body:e[0]}}}),ce({type:"enclose",names:["\\cancel","\\bcancel","\\xcancel","\\sout","\\phase"],props:{numArgs:1},handler(t,e){var{parser:n,funcName:r}=t,i=e[0];return{type:"enclose",mode:n.mode,label:r,body:i}},htmlBuilder:Bn,mathmlBuilder:Fn}),ce({type:"enclose",names:["\\angl"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!1},handler(t,e){var{parser:n}=t;return{type:"enclose",mode:n.mode,label:"\\angl",body:e[0]}}});var Wn={};function zn(t){for(var{type:e,names:n,props:r,handler:i,htmlBuilder:a,mathmlBuilder:s}=t,o={type:e,numArgs:r.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:i},l=0;l{if(!t.parser.settings.displayMode)throw new a("{"+t.envName+"} can be used only in display mode.")};function Vn(t){if(-1===t.indexOf("ed"))return-1===t.indexOf("*")}function qn(t,e,n){var{hskipBeforeAndAfter:r,addJot:s,cols:o,arraystretch:l,colSeparationType:c,autoTag:h,singleRow:u,emptySingleRow:d,maxNumCols:p,leqno:g}=e;if(t.gullet.beginGroup(),u||t.gullet.macros.set("\\cr","\\\\\\relax"),!l){var f=t.gullet.expandMacroAsText("\\arraystretch");if(null==f)l=1;else if(!(l=parseFloat(f))||l<0)throw new a("Invalid \\arraystretch: "+f)}t.gullet.beginGroup();var m=[],y=[m],v=[],x=[],b=null!=h?[]:void 0;function w(){h&&t.gullet.macros.set("\\@eqnsw","1",!0)}function k(){b&&(t.gullet.macros.get("\\df@tag")?(b.push(t.subparse([new i("\\df@tag")])),t.gullet.macros.set("\\df@tag",void 0,!0)):b.push(Boolean(h)&&"1"===t.gullet.macros.get("\\@eqnsw")))}for(w(),x.push(Un(t));;){var T=t.parseExpression(!1,u?"\\end":"\\\\");t.gullet.endGroup(),t.gullet.beginGroup(),T={type:"ordgroup",mode:t.mode,body:T},n&&(T={type:"styling",mode:t.mode,style:n,body:[T]}),m.push(T);var _=t.fetch().text;if("&"===_){if(p&&m.length===p){if(u||c)throw new a("Too many tab characters: &",t.nextToken);t.settings.reportNonstrict("textEnv","Too few columns specified in the {array} column argument.")}t.consume()}else{if("\\end"===_){k(),1===m.length&&"styling"===T.type&&0===T.body[0].body.length&&(y.length>1||!d)&&y.pop(),x.length0&&(x+=.25),c.push({pos:x,isDashed:t[e]})}for(b(s[0]),n=0;n0&&(T<(C+=v)&&(T=C),C=0),t.addJot&&(T+=f),_.height=k,_.depth=T,x+=k,_.pos=x,x+=T+C,l[n]=_,b(s[n+1])}var L,M,N=x/2+e.fontMetrics().axisHeight,I=t.cols||[],R=[],D=[];if(t.tags&&t.tags.some((t=>t)))for(n=0;n=o)){var U=void 0;(r>0||t.hskipBeforeAndAfter)&&0!==(U=u(F.pregap,p))&&((L=te.makeSpan(["arraycolsep"],[])).style.width=q(U),R.push(L));var G=[];for(n=0;n0){for(var K=te.makeLineSpan("hline",e,h),Q=te.makeLineSpan("hdashline",e,h),J=[{type:"elem",elem:l,shift:0}];c.length>0;){var tt=c.pop(),et=tt.pos-N;tt.isDashed?J.push({type:"elem",elem:Q,shift:et}):J.push({type:"elem",elem:K,shift:et})}l=te.makeVList({positionType:"individualShift",children:J},e)}if(0===D.length)return te.makeSpan(["mord"],[l],e);var nt=te.makeVList({positionType:"individualShift",children:D},e);return nt=te.makeSpan(["tag"],[nt],e),te.makeFragment([l,nt])},Xn={c:"center ",l:"left ",r:"right "},Kn=function(t,e){for(var n=[],r=new Me.MathNode("mtd",[],["mtr-glue"]),i=new Me.MathNode("mtd",[],["mml-eqn-num"]),a=0;a0){var p=t.cols,g="",f=!1,m=0,y=p.length;"separator"===p[0].type&&(u+="top ",m=1),"separator"===p[p.length-1].type&&(u+="bottom ",y-=1);for(var v=m;v0?"left ":"",u+=T[T.length-1].length>0?"right ":"";for(var _=1;_-1?"alignat":"align",s="split"===t.envName,o=qn(t.parser,{cols:r,addJot:!0,autoTag:s?void 0:Vn(t.envName),emptySingleRow:!0,colSeparationType:i,maxNumCols:s?2:void 0,leqno:t.parser.settings.leqno},"display"),l=0,c={type:"ordgroup",mode:t.mode,body:[]};if(e[0]&&"ordgroup"===e[0].type){for(var h="",u=0;u0&&d&&(f=1),r[p]={type:"align",align:g,pregap:f,postgap:0}}return o.colSeparationType=d?"align":"alignat",o};zn({type:"array",names:["array","darray"],props:{numArgs:1},handler(t,e){var n=(qe(e[0])?[e[0]]:Ge(e[0],"ordgroup").body).map((function(t){var e=Ve(t).text;if(-1!=="lcr".indexOf(e))return{type:"align",align:e};if("|"===e)return{type:"separator",separator:"|"};if(":"===e)return{type:"separator",separator:":"};throw new a("Unknown column alignment: "+e,t)})),r={cols:n,hskipBeforeAndAfter:!0,maxNumCols:n.length};return qn(t.parser,r,jn(t.envName))},htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["matrix","pmatrix","bmatrix","Bmatrix","vmatrix","Vmatrix","matrix*","pmatrix*","bmatrix*","Bmatrix*","vmatrix*","Vmatrix*"],props:{numArgs:0},handler(t){var e={matrix:null,pmatrix:["(",")"],bmatrix:["[","]"],Bmatrix:["\\{","\\}"],vmatrix:["|","|"],Vmatrix:["\\Vert","\\Vert"]}[t.envName.replace("*","")],n="c",r={hskipBeforeAndAfter:!1,cols:[{type:"align",align:n}]};if("*"===t.envName.charAt(t.envName.length-1)){var i=t.parser;if(i.consumeSpaces(),"["===i.fetch().text){if(i.consume(),i.consumeSpaces(),n=i.fetch().text,-1==="lcr".indexOf(n))throw new a("Expected l or c or r",i.nextToken);i.consume(),i.consumeSpaces(),i.expect("]"),i.consume(),r.cols=[{type:"align",align:n}]}}var s=qn(t.parser,r,jn(t.envName)),o=Math.max(0,...s.body.map((t=>t.length)));return s.cols=new Array(o).fill({type:"align",align:n}),e?{type:"leftright",mode:t.mode,body:[s],left:e[0],right:e[1],rightColor:void 0}:s},htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["smallmatrix"],props:{numArgs:0},handler(t){var e=qn(t.parser,{arraystretch:.5},"script");return e.colSeparationType="small",e},htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["subarray"],props:{numArgs:1},handler(t,e){var n=(qe(e[0])?[e[0]]:Ge(e[0],"ordgroup").body).map((function(t){var e=Ve(t).text;if(-1!=="lc".indexOf(e))return{type:"align",align:e};throw new a("Unknown column alignment: "+e,t)}));if(n.length>1)throw new a("{subarray} can contain only one column");var r={cols:n,hskipBeforeAndAfter:!1,arraystretch:.5};if((r=qn(t.parser,r,"script")).body.length>0&&r.body[0].length>1)throw new a("{subarray} can contain only one column");return r},htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["cases","dcases","rcases","drcases"],props:{numArgs:0},handler(t){var e=qn(t.parser,{arraystretch:1.2,cols:[{type:"align",align:"l",pregap:0,postgap:1},{type:"align",align:"l",pregap:0,postgap:0}]},jn(t.envName));return{type:"leftright",mode:t.mode,body:[e],left:t.envName.indexOf("r")>-1?".":"\\{",right:t.envName.indexOf("r")>-1?"\\}":".",rightColor:void 0}},htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["align","align*","aligned","split"],props:{numArgs:0},handler:Qn,htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["gathered","gather","gather*"],props:{numArgs:0},handler(t){h(["gather","gather*"],t.envName)&&Gn(t);var e={cols:[{type:"align",align:"c"}],addJot:!0,colSeparationType:"gather",autoTag:Vn(t.envName),emptySingleRow:!0,leqno:t.parser.settings.leqno};return qn(t.parser,e,"display")},htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["alignat","alignat*","alignedat"],props:{numArgs:1},handler:Qn,htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["equation","equation*"],props:{numArgs:0},handler(t){Gn(t);var e={autoTag:Vn(t.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:t.parser.settings.leqno};return qn(t.parser,e,"display")},htmlBuilder:Hn,mathmlBuilder:Kn}),zn({type:"array",names:["CD"],props:{numArgs:0},handler:t=>(Gn(t),function(t){var e=[];for(t.gullet.beginGroup(),t.gullet.macros.set("\\cr","\\\\\\relax"),t.gullet.beginGroup();;){e.push(t.parseExpression(!1,"\\\\")),t.gullet.endGroup(),t.gullet.beginGroup();var n=t.fetch().text;if("&"!==n&&"\\\\"!==n){if("\\end"===n){0===e[e.length-1].length&&e.pop();break}throw new a("Expected \\\\ or \\cr or \\end",t.nextToken)}t.consume()}for(var r,i,s=[],o=[s],l=0;l-1);else{if(!("<>AV".indexOf(d)>-1))throw new a('Expected one of "<>AV=|." after @',c[u]);for(var g=0;g<2;g++){for(var f=!0,m=u+1;m{var n=t.font,r=e.withFont(n);return _e(t.body,r)},er=(t,e)=>{var n=t.font,r=e.withFont(n);return $e(t.body,r)},nr={"\\Bbb":"\\mathbb","\\bold":"\\mathbf","\\frak":"\\mathfrak","\\bm":"\\boldsymbol"};ce({type:"font",names:["\\mathrm","\\mathit","\\mathbf","\\mathnormal","\\mathsfit","\\mathbb","\\mathcal","\\mathfrak","\\mathscr","\\mathsf","\\mathtt","\\Bbb","\\bold","\\frak"],props:{numArgs:1,allowedInArgument:!0},handler:(t,e)=>{var{parser:n,funcName:r}=t,i=ue(e[0]),a=r;return a in nr&&(a=nr[a]),{type:"font",mode:n.mode,font:a.slice(1),body:i}},htmlBuilder:tr,mathmlBuilder:er}),ce({type:"mclass",names:["\\boldsymbol","\\bm"],props:{numArgs:1},handler:(t,e)=>{var{parser:n}=t,r=e[0],i=f(r);return{type:"mclass",mode:n.mode,mclass:en(r),body:[{type:"font",mode:n.mode,font:"boldsymbol",body:r}],isCharacterBox:i}}}),ce({type:"font",names:["\\rm","\\sf","\\tt","\\bf","\\it","\\cal"],props:{numArgs:0,allowedInText:!0},handler:(t,e)=>{var{parser:n,funcName:r,breakOnTokenText:i}=t,{mode:a}=n,s=n.parseExpression(!0,i);return{type:"font",mode:a,font:"math"+r.slice(1),body:{type:"ordgroup",mode:n.mode,body:s}}},htmlBuilder:tr,mathmlBuilder:er});var rr=(t,e)=>{var n=e;return"display"===t?n=n.id>=A.SCRIPT.id?n.text():A.DISPLAY:"text"===t&&n.size===A.DISPLAY.size?n=A.TEXT:"script"===t?n=A.SCRIPT:"scriptscript"===t&&(n=A.SCRIPTSCRIPT),n},ir=(t,e)=>{var n,r=rr(t.size,e.style),i=r.fracNum(),a=r.fracDen();n=e.havingStyle(i);var s=_e(t.numer,n,e);if(t.continued){var o=8.5/e.fontMetrics().ptPerEm,l=3.5/e.fontMetrics().ptPerEm;s.height=s.height0?3*u:7*u,g=e.fontMetrics().denom1):(h>0?(d=e.fontMetrics().num2,p=u):(d=e.fontMetrics().num3,p=3*u),g=e.fontMetrics().denom2),c){var b=e.fontMetrics().axisHeight;d-s.depth-(b+.5*h){var n=new Me.MathNode("mfrac",[$e(t.numer,e),$e(t.denom,e)]);if(t.hasBarLine){if(t.barSize){var r=V(t.barSize,e);n.setAttribute("linethickness",q(r))}}else n.setAttribute("linethickness","0px");var i=rr(t.size,e.style);if(i.size!==e.style.size){n=new Me.MathNode("mstyle",[n]);var a=i.size===A.DISPLAY.size?"true":"false";n.setAttribute("displaystyle",a),n.setAttribute("scriptlevel","0")}if(null!=t.leftDelim||null!=t.rightDelim){var s=[];if(null!=t.leftDelim){var o=new Me.MathNode("mo",[new Me.TextNode(t.leftDelim.replace("\\",""))]);o.setAttribute("fence","true"),s.push(o)}if(s.push(n),null!=t.rightDelim){var l=new Me.MathNode("mo",[new Me.TextNode(t.rightDelim.replace("\\",""))]);l.setAttribute("fence","true"),s.push(l)}return Ie(s)}return n};ce({type:"genfrac",names:["\\dfrac","\\frac","\\tfrac","\\dbinom","\\binom","\\tbinom","\\\\atopfrac","\\\\bracefrac","\\\\brackfrac"],props:{numArgs:2,allowedInArgument:!0},handler:(t,e)=>{var n,{parser:r,funcName:i}=t,a=e[0],s=e[1],o=null,l=null,c="auto";switch(i){case"\\dfrac":case"\\frac":case"\\tfrac":n=!0;break;case"\\\\atopfrac":n=!1;break;case"\\dbinom":case"\\binom":case"\\tbinom":n=!1,o="(",l=")";break;case"\\\\bracefrac":n=!1,o="\\{",l="\\}";break;case"\\\\brackfrac":n=!1,o="[",l="]";break;default:throw new Error("Unrecognized genfrac command")}switch(i){case"\\dfrac":case"\\dbinom":c="display";break;case"\\tfrac":case"\\tbinom":c="text"}return{type:"genfrac",mode:r.mode,continued:!1,numer:a,denom:s,hasBarLine:n,leftDelim:o,rightDelim:l,size:c,barSize:null}},htmlBuilder:ir,mathmlBuilder:ar}),ce({type:"genfrac",names:["\\cfrac"],props:{numArgs:2},handler:(t,e)=>{var{parser:n,funcName:r}=t,i=e[0],a=e[1];return{type:"genfrac",mode:n.mode,continued:!0,numer:i,denom:a,hasBarLine:!0,leftDelim:null,rightDelim:null,size:"display",barSize:null}}}),ce({type:"infix",names:["\\over","\\choose","\\atop","\\brace","\\brack"],props:{numArgs:0,infix:!0},handler(t){var e,{parser:n,funcName:r,token:i}=t;switch(r){case"\\over":e="\\frac";break;case"\\choose":e="\\binom";break;case"\\atop":e="\\\\atopfrac";break;case"\\brace":e="\\\\bracefrac";break;case"\\brack":e="\\\\brackfrac";break;default:throw new Error("Unrecognized infix genfrac command")}return{type:"infix",mode:n.mode,replaceWith:e,token:i}}});var sr=["display","text","script","scriptscript"],or=function(t){var e=null;return t.length>0&&(e="."===(e=t)?null:e),e};ce({type:"genfrac",names:["\\genfrac"],props:{numArgs:6,allowedInArgument:!0,argTypes:["math","math","size","text","math","math"]},handler(t,e){var n,{parser:r}=t,i=e[4],a=e[5],s=ue(e[0]),o="atom"===s.type&&"open"===s.family?or(s.text):null,l=ue(e[1]),c="atom"===l.type&&"close"===l.family?or(l.text):null,h=Ge(e[2],"size"),u=null;n=!!h.isBlank||(u=h.value).number>0;var d="auto",p=e[3];if("ordgroup"===p.type){if(p.body.length>0){var g=Ge(p.body[0],"textord");d=sr[Number(g.text)]}}else p=Ge(p,"textord"),d=sr[Number(p.text)];return{type:"genfrac",mode:r.mode,numer:i,denom:a,continued:!1,hasBarLine:n,barSize:u,leftDelim:o,rightDelim:c,size:d}},htmlBuilder:ir,mathmlBuilder:ar}),ce({type:"infix",names:["\\above"],props:{numArgs:1,argTypes:["size"],infix:!0},handler(t,e){var{parser:n,funcName:r,token:i}=t;return{type:"infix",mode:n.mode,replaceWith:"\\\\abovefrac",size:Ge(e[0],"size").value,token:i}}}),ce({type:"genfrac",names:["\\\\abovefrac"],props:{numArgs:3,argTypes:["math","size","math"]},handler:(t,e)=>{var{parser:n,funcName:r}=t,i=e[0],a=function(t){if(!t)throw new Error("Expected non-null, but got "+String(t));return t}(Ge(e[1],"infix").size),s=e[2],o=a.number>0;return{type:"genfrac",mode:n.mode,numer:i,denom:s,continued:!1,hasBarLine:o,barSize:a,leftDelim:null,rightDelim:null,size:"auto"}},htmlBuilder:ir,mathmlBuilder:ar});var lr=(t,e)=>{var n,r,i=e.style;"supsub"===t.type?(n=t.sup?_e(t.sup,e.havingStyle(i.sup()),e):_e(t.sub,e.havingStyle(i.sub()),e),r=Ge(t.base,"horizBrace")):r=Ge(t,"horizBrace");var a,s=_e(r.base,e.havingBaseStyle(A.DISPLAY)),o=Ue(r,e);if(r.isOver?(a=te.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:s},{type:"kern",size:.1},{type:"elem",elem:o}]},e)).children[0].children[0].children[1].classes.push("svg-align"):(a=te.makeVList({positionType:"bottom",positionData:s.depth+.1+o.height,children:[{type:"elem",elem:o},{type:"kern",size:.1},{type:"elem",elem:s}]},e)).children[0].children[0].children[0].classes.push("svg-align"),n){var l=te.makeSpan(["mord",r.isOver?"mover":"munder"],[a],e);a=r.isOver?te.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:l},{type:"kern",size:.2},{type:"elem",elem:n}]},e):te.makeVList({positionType:"bottom",positionData:l.depth+.2+n.height+n.depth,children:[{type:"elem",elem:n},{type:"kern",size:.2},{type:"elem",elem:l}]},e)}return te.makeSpan(["mord",r.isOver?"mover":"munder"],[a],e)};ce({type:"horizBrace",names:["\\overbrace","\\underbrace"],props:{numArgs:1},handler(t,e){var{parser:n,funcName:r}=t;return{type:"horizBrace",mode:n.mode,label:r,isOver:/^\\over/.test(r),base:e[0]}},htmlBuilder:lr,mathmlBuilder:(t,e)=>{var n=Ye(t.label);return new Me.MathNode(t.isOver?"mover":"munder",[$e(t.base,e),n])}}),ce({type:"href",names:["\\href"],props:{numArgs:2,argTypes:["url","original"],allowedInText:!0},handler:(t,e)=>{var{parser:n}=t,r=e[1],i=Ge(e[0],"url").url;return n.settings.isTrusted({command:"\\href",url:i})?{type:"href",mode:n.mode,href:i,body:de(r)}:n.formatUnsupportedCmd("\\href")},htmlBuilder:(t,e)=>{var n=ve(t.body,e,!1);return te.makeAnchor(t.href,[],n,e)},mathmlBuilder:(t,e)=>{var n=Pe(t.body,e);return n instanceof Ae||(n=new Ae("mrow",[n])),n.setAttribute("href",t.href),n}}),ce({type:"href",names:["\\url"],props:{numArgs:1,argTypes:["url"],allowedInText:!0},handler:(t,e)=>{var{parser:n}=t,r=Ge(e[0],"url").url;if(!n.settings.isTrusted({command:"\\url",url:r}))return n.formatUnsupportedCmd("\\url");for(var i=[],a=0;anew Me.MathNode("mrow",Oe(t.body,e))}),ce({type:"html",names:["\\htmlClass","\\htmlId","\\htmlStyle","\\htmlData"],props:{numArgs:2,argTypes:["raw","original"],allowedInText:!0},handler:(t,e)=>{var n,{parser:r,funcName:i,token:s}=t,o=Ge(e[0],"raw").string,l=e[1];r.settings.strict&&r.settings.reportNonstrict("htmlExtension","HTML extension is disabled on strict mode");var c={};switch(i){case"\\htmlClass":c.class=o,n={command:"\\htmlClass",class:o};break;case"\\htmlId":c.id=o,n={command:"\\htmlId",id:o};break;case"\\htmlStyle":c.style=o,n={command:"\\htmlStyle",style:o};break;case"\\htmlData":for(var h=o.split(","),u=0;u{var n=ve(t.body,e,!1),r=["enclosing"];t.attributes.class&&r.push(...t.attributes.class.trim().split(/\s+/));var i=te.makeSpan(r,n,e);for(var a in t.attributes)"class"!==a&&t.attributes.hasOwnProperty(a)&&i.setAttribute(a,t.attributes[a]);return i},mathmlBuilder:(t,e)=>Pe(t.body,e)}),ce({type:"htmlmathml",names:["\\html@mathml"],props:{numArgs:2,allowedInText:!0},handler:(t,e)=>{var{parser:n}=t;return{type:"htmlmathml",mode:n.mode,html:de(e[0]),mathml:de(e[1])}},htmlBuilder:(t,e)=>{var n=ve(t.html,e,!1);return te.makeFragment(n)},mathmlBuilder:(t,e)=>Pe(t.mathml,e)});var cr=function(t){if(/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(t))return{number:+t,unit:"bp"};var e=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(t);if(!e)throw new a("Invalid size: '"+t+"' in \\includegraphics");var n={number:+(e[1]+e[2]),unit:e[3]};if(!G(n))throw new a("Invalid unit: '"+n.unit+"' in \\includegraphics.");return n};ce({type:"includegraphics",names:["\\includegraphics"],props:{numArgs:1,numOptionalArgs:1,argTypes:["raw","url"],allowedInText:!1},handler:(t,e,n)=>{var{parser:r}=t,i={number:0,unit:"em"},s={number:.9,unit:"em"},o={number:0,unit:"em"},l="";if(n[0])for(var c=Ge(n[0],"raw").string.split(","),h=0;h{var n=V(t.height,e),r=0;t.totalheight.number>0&&(r=V(t.totalheight,e)-n);var i=0;t.width.number>0&&(i=V(t.width,e));var a={height:q(n+r)};i>0&&(a.width=q(i)),r>0&&(a.verticalAlign=q(-r));var s=new et(t.src,t.alt,a);return s.height=n,s.depth=r,s},mathmlBuilder:(t,e)=>{var n=new Me.MathNode("mglyph",[]);n.setAttribute("alt",t.alt);var r=V(t.height,e),i=0;if(t.totalheight.number>0&&(i=V(t.totalheight,e)-r,n.setAttribute("valign",q(-i))),n.setAttribute("height",q(r+i)),t.width.number>0){var a=V(t.width,e);n.setAttribute("width",q(a))}return n.setAttribute("src",t.src),n}}),ce({type:"kern",names:["\\kern","\\mkern","\\hskip","\\mskip"],props:{numArgs:1,argTypes:["size"],primitive:!0,allowedInText:!0},handler(t,e){var{parser:n,funcName:r}=t,i=Ge(e[0],"size");if(n.settings.strict){var a="m"===r[1],s="mu"===i.value.unit;a?(s||n.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" supports only mu units, not "+i.value.unit+" units"),"math"!==n.mode&&n.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" works only in math mode")):s&&n.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+r+" doesn't support mu units")}return{type:"kern",mode:n.mode,dimension:i.value}},htmlBuilder:(t,e)=>te.makeGlue(t.dimension,e),mathmlBuilder(t,e){var n=V(t.dimension,e);return new Me.SpaceNode(n)}}),ce({type:"lap",names:["\\mathllap","\\mathrlap","\\mathclap"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:n,funcName:r}=t,i=e[0];return{type:"lap",mode:n.mode,alignment:r.slice(5),body:i}},htmlBuilder:(t,e)=>{var n;"clap"===t.alignment?(n=te.makeSpan([],[_e(t.body,e)]),n=te.makeSpan(["inner"],[n],e)):n=te.makeSpan(["inner"],[_e(t.body,e)]);var r=te.makeSpan(["fix"],[]),i=te.makeSpan([t.alignment],[n,r],e),a=te.makeSpan(["strut"]);return a.style.height=q(i.height+i.depth),i.depth&&(a.style.verticalAlign=q(-i.depth)),i.children.unshift(a),i=te.makeSpan(["thinbox"],[i],e),te.makeSpan(["mord","vbox"],[i],e)},mathmlBuilder:(t,e)=>{var n=new Me.MathNode("mpadded",[$e(t.body,e)]);if("rlap"!==t.alignment){var r="llap"===t.alignment?"-1":"-0.5";n.setAttribute("lspace",r+"width")}return n.setAttribute("width","0px"),n}}),ce({type:"styling",names:["\\(","$"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,e){var{funcName:n,parser:r}=t,i=r.mode;r.switchMode("math");var a="\\("===n?"\\)":"$",s=r.parseExpression(!1,a);return r.expect(a),r.switchMode(i),{type:"styling",mode:r.mode,style:"text",body:s}}}),ce({type:"text",names:["\\)","\\]"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(t,e){throw new a("Mismatched "+t.funcName)}});var hr=(t,e)=>{switch(e.style.size){case A.DISPLAY.size:return t.display;case A.TEXT.size:return t.text;case A.SCRIPT.size:return t.script;case A.SCRIPTSCRIPT.size:return t.scriptscript;default:return t.text}};ce({type:"mathchoice",names:["\\mathchoice"],props:{numArgs:4,primitive:!0},handler:(t,e)=>{var{parser:n}=t;return{type:"mathchoice",mode:n.mode,display:de(e[0]),text:de(e[1]),script:de(e[2]),scriptscript:de(e[3])}},htmlBuilder:(t,e)=>{var n=hr(t,e),r=ve(n,e,!1);return te.makeFragment(r)},mathmlBuilder:(t,e)=>{var n=hr(t,e);return Pe(n,e)}});var ur=(t,e,n,r,i,a,s)=>{t=te.makeSpan([],[t]);var o,l,c,h=n&&f(n);if(e){var u=_e(e,r.havingStyle(i.sup()),r);l={elem:u,kern:Math.max(r.fontMetrics().bigOpSpacing1,r.fontMetrics().bigOpSpacing3-u.depth)}}if(n){var d=_e(n,r.havingStyle(i.sub()),r);o={elem:d,kern:Math.max(r.fontMetrics().bigOpSpacing2,r.fontMetrics().bigOpSpacing4-d.height)}}if(l&&o){var p=r.fontMetrics().bigOpSpacing5+o.elem.height+o.elem.depth+o.kern+t.depth+s;c=te.makeVList({positionType:"bottom",positionData:p,children:[{type:"kern",size:r.fontMetrics().bigOpSpacing5},{type:"elem",elem:o.elem,marginLeft:q(-a)},{type:"kern",size:o.kern},{type:"elem",elem:t},{type:"kern",size:l.kern},{type:"elem",elem:l.elem,marginLeft:q(a)},{type:"kern",size:r.fontMetrics().bigOpSpacing5}]},r)}else if(o){var g=t.height-s;c=te.makeVList({positionType:"top",positionData:g,children:[{type:"kern",size:r.fontMetrics().bigOpSpacing5},{type:"elem",elem:o.elem,marginLeft:q(-a)},{type:"kern",size:o.kern},{type:"elem",elem:t}]},r)}else{if(!l)return t;var m=t.depth+s;c=te.makeVList({positionType:"bottom",positionData:m,children:[{type:"elem",elem:t},{type:"kern",size:l.kern},{type:"elem",elem:l.elem,marginLeft:q(a)},{type:"kern",size:r.fontMetrics().bigOpSpacing5}]},r)}var y=[c];if(o&&0!==a&&!h){var v=te.makeSpan(["mspace"],[],r);v.style.marginRight=q(a),y.unshift(v)}return te.makeSpan(["mop","op-limits"],y,r)},dr=["\\smallint"],pr=(t,e)=>{var n,r,i,a=!1;"supsub"===t.type?(n=t.sup,r=t.sub,i=Ge(t.base,"op"),a=!0):i=Ge(t,"op");var s,o=e.style,l=!1;if(o.size===A.DISPLAY.size&&i.symbol&&!h(dr,i.name)&&(l=!0),i.symbol){var c=l?"Size2-Regular":"Size1-Regular",u="";if("\\oiint"!==i.name&&"\\oiiint"!==i.name||(u=i.name.slice(1),i.name="oiint"===u?"\\iint":"\\iiint"),s=te.makeSymbol(i.name,c,"math",e,["mop","op-symbol",l?"large-op":"small-op"]),u.length>0){var d=s.italic,p=te.staticSvg(u+"Size"+(l?"2":"1"),e);s=te.makeVList({positionType:"individualShift",children:[{type:"elem",elem:s,shift:0},{type:"elem",elem:p,shift:l?.08:0}]},e),i.name="\\"+u,s.classes.unshift("mop"),s.italic=d}}else if(i.body){var g=ve(i.body,e,!0);1===g.length&&g[0]instanceof rt?(s=g[0]).classes[0]="mop":s=te.makeSpan(["mop"],g,e)}else{for(var f=[],m=1;m{var n;if(t.symbol)n=new Ae("mo",[Ne(t.name,t.mode)]),h(dr,t.name)&&n.setAttribute("largeop","false");else if(t.body)n=new Ae("mo",Oe(t.body,e));else{n=new Ae("mi",[new Le(t.name.slice(1))]);var r=new Ae("mo",[Ne("⁡","text")]);n=t.parentIsSupSub?new Ae("mrow",[n,r]):Ce([n,r])}return n},fr={"∏":"\\prod","∐":"\\coprod","∑":"\\sum","⋀":"\\bigwedge","⋁":"\\bigvee","⋂":"\\bigcap","⋃":"\\bigcup","⨀":"\\bigodot","⨁":"\\bigoplus","⨂":"\\bigotimes","⨄":"\\biguplus","⨆":"\\bigsqcup"};ce({type:"op",names:["\\coprod","\\bigvee","\\bigwedge","\\biguplus","\\bigcap","\\bigcup","\\intop","\\prod","\\sum","\\bigotimes","\\bigoplus","\\bigodot","\\bigsqcup","\\smallint","∏","∐","∑","⋀","⋁","⋂","⋃","⨀","⨁","⨂","⨄","⨆"],props:{numArgs:0},handler:(t,e)=>{var{parser:n,funcName:r}=t,i=r;return 1===i.length&&(i=fr[i]),{type:"op",mode:n.mode,limits:!0,parentIsSupSub:!1,symbol:!0,name:i}},htmlBuilder:pr,mathmlBuilder:gr}),ce({type:"op",names:["\\mathop"],props:{numArgs:1,primitive:!0},handler:(t,e)=>{var{parser:n}=t,r=e[0];return{type:"op",mode:n.mode,limits:!1,parentIsSupSub:!1,symbol:!1,body:de(r)}},htmlBuilder:pr,mathmlBuilder:gr});var mr={"∫":"\\int","∬":"\\iint","∭":"\\iiint","∮":"\\oint","∯":"\\oiint","∰":"\\oiiint"};ce({type:"op",names:["\\arcsin","\\arccos","\\arctan","\\arctg","\\arcctg","\\arg","\\ch","\\cos","\\cosec","\\cosh","\\cot","\\cotg","\\coth","\\csc","\\ctg","\\cth","\\deg","\\dim","\\exp","\\hom","\\ker","\\lg","\\ln","\\log","\\sec","\\sin","\\sinh","\\sh","\\tan","\\tanh","\\tg","\\th"],props:{numArgs:0},handler(t){var{parser:e,funcName:n}=t;return{type:"op",mode:e.mode,limits:!1,parentIsSupSub:!1,symbol:!1,name:n}},htmlBuilder:pr,mathmlBuilder:gr}),ce({type:"op",names:["\\det","\\gcd","\\inf","\\lim","\\max","\\min","\\Pr","\\sup"],props:{numArgs:0},handler(t){var{parser:e,funcName:n}=t;return{type:"op",mode:e.mode,limits:!0,parentIsSupSub:!1,symbol:!1,name:n}},htmlBuilder:pr,mathmlBuilder:gr}),ce({type:"op",names:["\\int","\\iint","\\iiint","\\oint","\\oiint","\\oiiint","∫","∬","∭","∮","∯","∰"],props:{numArgs:0},handler(t){var{parser:e,funcName:n}=t,r=n;return 1===r.length&&(r=mr[r]),{type:"op",mode:e.mode,limits:!1,parentIsSupSub:!1,symbol:!0,name:r}},htmlBuilder:pr,mathmlBuilder:gr});var yr=(t,e)=>{var n,r,i,a,s=!1;if("supsub"===t.type?(n=t.sup,r=t.sub,i=Ge(t.base,"operatorname"),s=!0):i=Ge(t,"operatorname"),i.body.length>0){for(var o=i.body.map((t=>{var e=t.text;return"string"==typeof e?{type:"textord",mode:t.mode,text:e}:t})),l=ve(o,e.withFont("mathrm"),!0),c=0;c{var{parser:n,funcName:r}=t,i=e[0];return{type:"operatorname",mode:n.mode,body:de(i),alwaysHandleSupSub:"\\operatornamewithlimits"===r,limits:!1,parentIsSupSub:!1}},htmlBuilder:yr,mathmlBuilder:(t,e)=>{for(var n=Oe(t.body,e.withFont("mathrm")),r=!0,i=0;it.toText())).join("");n=[new Me.TextNode(o)]}var l=new Me.MathNode("mi",n);l.setAttribute("mathvariant","normal");var c=new Me.MathNode("mo",[Ne("⁡","text")]);return t.parentIsSupSub?new Me.MathNode("mrow",[l,c]):Me.newDocumentFragment([l,c])}}),Yn("\\operatorname","\\@ifstar\\operatornamewithlimits\\operatorname@"),he({type:"ordgroup",htmlBuilder:(t,e)=>t.semisimple?te.makeFragment(ve(t.body,e,!1)):te.makeSpan(["mord"],ve(t.body,e,!0),e),mathmlBuilder:(t,e)=>Pe(t.body,e,!0)}),ce({type:"overline",names:["\\overline"],props:{numArgs:1},handler(t,e){var{parser:n}=t,r=e[0];return{type:"overline",mode:n.mode,body:r}},htmlBuilder(t,e){var n=_e(t.body,e.havingCrampedStyle()),r=te.makeLineSpan("overline-line",e),i=e.fontMetrics().defaultRuleThickness,a=te.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:n},{type:"kern",size:3*i},{type:"elem",elem:r},{type:"kern",size:i}]},e);return te.makeSpan(["mord","overline"],[a],e)},mathmlBuilder(t,e){var n=new Me.MathNode("mo",[new Me.TextNode("‾")]);n.setAttribute("stretchy","true");var r=new Me.MathNode("mover",[$e(t.body,e),n]);return r.setAttribute("accent","true"),r}}),ce({type:"phantom",names:["\\phantom"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:n}=t,r=e[0];return{type:"phantom",mode:n.mode,body:de(r)}},htmlBuilder:(t,e)=>{var n=ve(t.body,e.withPhantom(),!1);return te.makeFragment(n)},mathmlBuilder:(t,e)=>{var n=Oe(t.body,e);return new Me.MathNode("mphantom",n)}}),ce({type:"hphantom",names:["\\hphantom"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:n}=t,r=e[0];return{type:"hphantom",mode:n.mode,body:r}},htmlBuilder:(t,e)=>{var n=te.makeSpan([],[_e(t.body,e.withPhantom())]);if(n.height=0,n.depth=0,n.children)for(var r=0;r{var n=Oe(de(t.body),e),r=new Me.MathNode("mphantom",n),i=new Me.MathNode("mpadded",[r]);return i.setAttribute("height","0px"),i.setAttribute("depth","0px"),i}}),ce({type:"vphantom",names:["\\vphantom"],props:{numArgs:1,allowedInText:!0},handler:(t,e)=>{var{parser:n}=t,r=e[0];return{type:"vphantom",mode:n.mode,body:r}},htmlBuilder:(t,e)=>{var n=te.makeSpan(["inner"],[_e(t.body,e.withPhantom())]),r=te.makeSpan(["fix"],[]);return te.makeSpan(["mord","rlap"],[n,r],e)},mathmlBuilder:(t,e)=>{var n=Oe(de(t.body),e),r=new Me.MathNode("mphantom",n),i=new Me.MathNode("mpadded",[r]);return i.setAttribute("width","0px"),i}}),ce({type:"raisebox",names:["\\raisebox"],props:{numArgs:2,argTypes:["size","hbox"],allowedInText:!0},handler(t,e){var{parser:n}=t,r=Ge(e[0],"size").value,i=e[1];return{type:"raisebox",mode:n.mode,dy:r,body:i}},htmlBuilder(t,e){var n=_e(t.body,e),r=V(t.dy,e);return te.makeVList({positionType:"shift",positionData:-r,children:[{type:"elem",elem:n}]},e)},mathmlBuilder(t,e){var n=new Me.MathNode("mpadded",[$e(t.body,e)]),r=t.dy.number+t.dy.unit;return n.setAttribute("voffset",r),n}}),ce({type:"internal",names:["\\relax"],props:{numArgs:0,allowedInText:!0,allowedInArgument:!0},handler(t){var{parser:e}=t;return{type:"internal",mode:e.mode}}}),ce({type:"rule",names:["\\rule"],props:{numArgs:2,numOptionalArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["size","size","size"]},handler(t,e,n){var{parser:r}=t,i=n[0],a=Ge(e[0],"size"),s=Ge(e[1],"size");return{type:"rule",mode:r.mode,shift:i&&Ge(i,"size").value,width:a.value,height:s.value}},htmlBuilder(t,e){var n=te.makeSpan(["mord","rule"],[],e),r=V(t.width,e),i=V(t.height,e),a=t.shift?V(t.shift,e):0;return n.style.borderRightWidth=q(r),n.style.borderTopWidth=q(i),n.style.bottom=q(a),n.width=r,n.height=i+a,n.depth=-a,n.maxFontSize=1.125*i*e.sizeMultiplier,n},mathmlBuilder(t,e){var n=V(t.width,e),r=V(t.height,e),i=t.shift?V(t.shift,e):0,a=e.color&&e.getColor()||"black",s=new Me.MathNode("mspace");s.setAttribute("mathbackground",a),s.setAttribute("width",q(n)),s.setAttribute("height",q(r));var o=new Me.MathNode("mpadded",[s]);return i>=0?o.setAttribute("height",q(i)):(o.setAttribute("height",q(i)),o.setAttribute("depth",q(-i))),o.setAttribute("voffset",q(i)),o}});var xr=["\\tiny","\\sixptsize","\\scriptsize","\\footnotesize","\\small","\\normalsize","\\large","\\Large","\\LARGE","\\huge","\\Huge"];ce({type:"sizing",names:xr,props:{numArgs:0,allowedInText:!0},handler:(t,e)=>{var{breakOnTokenText:n,funcName:r,parser:i}=t,a=i.parseExpression(!1,n);return{type:"sizing",mode:i.mode,size:xr.indexOf(r)+1,body:a}},htmlBuilder:(t,e)=>{var n=e.havingSize(t.size);return vr(t.body,n,e)},mathmlBuilder:(t,e)=>{var n=e.havingSize(t.size),r=Oe(t.body,n),i=new Me.MathNode("mstyle",r);return i.setAttribute("mathsize",q(n.sizeMultiplier)),i}}),ce({type:"smash",names:["\\smash"],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:(t,e,n)=>{var{parser:r}=t,i=!1,a=!1,s=n[0]&&Ge(n[0],"ordgroup");if(s)for(var o="",l=0;l{var n=te.makeSpan([],[_e(t.body,e)]);if(!t.smashHeight&&!t.smashDepth)return n;if(t.smashHeight&&(n.height=0,n.children))for(var r=0;r{var n=new Me.MathNode("mpadded",[$e(t.body,e)]);return t.smashHeight&&n.setAttribute("height","0px"),t.smashDepth&&n.setAttribute("depth","0px"),n}}),ce({type:"sqrt",names:["\\sqrt"],props:{numArgs:1,numOptionalArgs:1},handler(t,e,n){var{parser:r}=t,i=n[0],a=e[0];return{type:"sqrt",mode:r.mode,body:a,index:i}},htmlBuilder(t,e){var n=_e(t.body,e.havingCrampedStyle());0===n.height&&(n.height=e.fontMetrics().xHeight),n=te.wrapFragment(n,e);var r=e.fontMetrics().defaultRuleThickness,i=r;e.style.idn.height+n.depth+a&&(a=(a+h-n.height-n.depth)/2);var u=o.height-n.height-a-l;n.style.paddingLeft=q(c);var d=te.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:n,wrapperClasses:["svg-align"]},{type:"kern",size:-(n.height+u)},{type:"elem",elem:o},{type:"kern",size:l}]},e);if(t.index){var p=e.havingStyle(A.SCRIPTSCRIPT),g=_e(t.index,p,e),f=.6*(d.height-d.depth),m=te.makeVList({positionType:"shift",positionData:-f,children:[{type:"elem",elem:g}]},e),y=te.makeSpan(["root"],[m]);return te.makeSpan(["mord","sqrt"],[y,d],e)}return te.makeSpan(["mord","sqrt"],[d],e)},mathmlBuilder(t,e){var{body:n,index:r}=t;return r?new Me.MathNode("mroot",[$e(n,e),$e(r,e)]):new Me.MathNode("msqrt",[$e(n,e)])}});var br={display:A.DISPLAY,text:A.TEXT,script:A.SCRIPT,scriptscript:A.SCRIPTSCRIPT};ce({type:"styling",names:["\\displaystyle","\\textstyle","\\scriptstyle","\\scriptscriptstyle"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(t,e){var{breakOnTokenText:n,funcName:r,parser:i}=t,a=i.parseExpression(!0,n),s=r.slice(1,r.length-5);return{type:"styling",mode:i.mode,style:s,body:a}},htmlBuilder(t,e){var n=br[t.style],r=e.havingStyle(n).withFont("");return vr(t.body,r,e)},mathmlBuilder(t,e){var n=br[t.style],r=e.havingStyle(n),i=Oe(t.body,r),a=new Me.MathNode("mstyle",i),s={display:["0","true"],text:["0","false"],script:["1","false"],scriptscript:["2","false"]}[t.style];return a.setAttribute("scriptlevel",s[0]),a.setAttribute("displaystyle",s[1]),a}}),he({type:"supsub",htmlBuilder(t,e){var n=function(t,e){var n=t.base;return n?"op"===n.type?n.limits&&(e.style.size===A.DISPLAY.size||n.alwaysHandleSupSub)?pr:null:"operatorname"===n.type?n.alwaysHandleSupSub&&(e.style.size===A.DISPLAY.size||n.limits)?yr:null:"accent"===n.type?f(n.base)?je:null:"horizBrace"===n.type&&!t.sub===n.isOver?lr:null:null}(t,e);if(n)return n(t,e);var r,i,a,{base:s,sup:o,sub:l}=t,c=_e(s,e),h=e.fontMetrics(),u=0,d=0,p=s&&f(s);if(o){var g=e.havingStyle(e.style.sup());r=_e(o,g,e),p||(u=c.height-g.fontMetrics().supDrop*g.sizeMultiplier/e.sizeMultiplier)}if(l){var m=e.havingStyle(e.style.sub());i=_e(l,m,e),p||(d=c.depth+m.fontMetrics().subDrop*m.sizeMultiplier/e.sizeMultiplier)}a=e.style===A.DISPLAY?h.sup1:e.style.cramped?h.sup3:h.sup2;var y,v=e.sizeMultiplier,x=q(.5/h.ptPerEm/v),b=null;if(i){var w=t.base&&"op"===t.base.type&&t.base.name&&("\\oiint"===t.base.name||"\\oiiint"===t.base.name);(c instanceof rt||w)&&(b=q(-c.italic))}if(r&&i){u=Math.max(u,a,r.depth+.25*h.xHeight),d=Math.max(d,h.sub2);var k=4*h.defaultRuleThickness;if(u-r.depth-(i.height-d)0&&(u+=T,d-=T)}y=te.makeVList({positionType:"individualShift",children:[{type:"elem",elem:i,shift:d,marginRight:x,marginLeft:b},{type:"elem",elem:r,shift:-u,marginRight:x}]},e)}else if(i){d=Math.max(d,h.sub1,i.height-.8*h.xHeight),y=te.makeVList({positionType:"shift",positionData:d,children:[{type:"elem",elem:i,marginLeft:b,marginRight:x}]},e)}else{if(!r)throw new Error("supsub must have either sup or sub.");u=Math.max(u,a,r.depth+.25*h.xHeight),y=te.makeVList({positionType:"shift",positionData:-u,children:[{type:"elem",elem:r,marginRight:x}]},e)}var _=ke(c,"right")||"mord";return te.makeSpan([_],[c,te.makeSpan(["msupsub"],[y])],e)},mathmlBuilder(t,e){var n,r=!1;t.base&&"horizBrace"===t.base.type&&!!t.sup===t.base.isOver&&(r=!0,n=t.base.isOver),!t.base||"op"!==t.base.type&&"operatorname"!==t.base.type||(t.base.parentIsSupSub=!0);var i,a=[$e(t.base,e)];if(t.sub&&a.push($e(t.sub,e)),t.sup&&a.push($e(t.sup,e)),r)i=n?"mover":"munder";else if(t.sub)if(t.sup){var s=t.base;i=s&&"op"===s.type&&s.limits&&e.style===A.DISPLAY||s&&"operatorname"===s.type&&s.alwaysHandleSupSub&&(e.style===A.DISPLAY||s.limits)?"munderover":"msubsup"}else{var o=t.base;i=o&&"op"===o.type&&o.limits&&(e.style===A.DISPLAY||o.alwaysHandleSupSub)||o&&"operatorname"===o.type&&o.alwaysHandleSupSub&&(o.limits||e.style===A.DISPLAY)?"munder":"msub"}else{var l=t.base;i=l&&"op"===l.type&&l.limits&&(e.style===A.DISPLAY||l.alwaysHandleSupSub)||l&&"operatorname"===l.type&&l.alwaysHandleSupSub&&(l.limits||e.style===A.DISPLAY)?"mover":"msup"}return new Me.MathNode(i,a)}}),he({type:"atom",htmlBuilder:(t,e)=>te.mathsym(t.text,t.mode,e,["m"+t.family]),mathmlBuilder(t,e){var n=new Me.MathNode("mo",[Ne(t.text,t.mode)]);if("bin"===t.family){var r=Re(t,e);"bold-italic"===r&&n.setAttribute("mathvariant",r)}else"punct"===t.family?n.setAttribute("separator","true"):"open"!==t.family&&"close"!==t.family||n.setAttribute("stretchy","false");return n}});var wr={mi:"italic",mn:"normal",mtext:"normal"};he({type:"mathord",htmlBuilder:(t,e)=>te.makeOrd(t,e,"mathord"),mathmlBuilder(t,e){var n=new Me.MathNode("mi",[Ne(t.text,t.mode,e)]),r=Re(t,e)||"italic";return r!==wr[n.type]&&n.setAttribute("mathvariant",r),n}}),he({type:"textord",htmlBuilder:(t,e)=>te.makeOrd(t,e,"textord"),mathmlBuilder(t,e){var n,r=Ne(t.text,t.mode,e),i=Re(t,e)||"normal";return n="text"===t.mode?new Me.MathNode("mtext",[r]):/[0-9]/.test(t.text)?new Me.MathNode("mn",[r]):"\\prime"===t.text?new Me.MathNode("mo",[r]):new Me.MathNode("mi",[r]),i!==wr[n.type]&&n.setAttribute("mathvariant",i),n}});var kr={"\\nobreak":"nobreak","\\allowbreak":"allowbreak"},Tr={" ":{},"\\ ":{},"~":{className:"nobreak"},"\\space":{},"\\nobreakspace":{className:"nobreak"}};he({type:"spacing",htmlBuilder(t,e){if(Tr.hasOwnProperty(t.text)){var n=Tr[t.text].className||"";if("text"===t.mode){var r=te.makeOrd(t,e,"textord");return r.classes.push(n),r}return te.makeSpan(["mspace",n],[te.mathsym(t.text,t.mode,e)],e)}if(kr.hasOwnProperty(t.text))return te.makeSpan(["mspace",kr[t.text]],[],e);throw new a('Unknown type of space "'+t.text+'"')},mathmlBuilder(t,e){if(!Tr.hasOwnProperty(t.text)){if(kr.hasOwnProperty(t.text))return new Me.MathNode("mspace");throw new a('Unknown type of space "'+t.text+'"')}return new Me.MathNode("mtext",[new Me.TextNode(" ")])}});var _r=()=>{var t=new Me.MathNode("mtd",[]);return t.setAttribute("width","50%"),t};he({type:"tag",mathmlBuilder(t,e){var n=new Me.MathNode("mtable",[new Me.MathNode("mtr",[_r(),new Me.MathNode("mtd",[Pe(t.body,e)]),_r(),new Me.MathNode("mtd",[Pe(t.tag,e)])])]);return n.setAttribute("width","100%"),n}});var Er={"\\text":void 0,"\\textrm":"textrm","\\textsf":"textsf","\\texttt":"texttt","\\textnormal":"textrm"},Sr={"\\textbf":"textbf","\\textmd":"textmd"},Cr={"\\textit":"textit","\\textup":"textup"},Ar=(t,e)=>{var n=t.font;return n?Er[n]?e.withTextFontFamily(Er[n]):Sr[n]?e.withTextFontWeight(Sr[n]):"\\emph"===n?"textit"===e.fontShape?e.withTextFontShape("textup"):e.withTextFontShape("textit"):e.withTextFontShape(Cr[n]):e};ce({type:"text",names:["\\text","\\textrm","\\textsf","\\texttt","\\textnormal","\\textbf","\\textmd","\\textit","\\textup","\\emph"],props:{numArgs:1,argTypes:["text"],allowedInArgument:!0,allowedInText:!0},handler(t,e){var{parser:n,funcName:r}=t,i=e[0];return{type:"text",mode:n.mode,body:de(i),font:r}},htmlBuilder(t,e){var n=Ar(t,e),r=ve(t.body,n,!0);return te.makeSpan(["mord","text"],r,n)},mathmlBuilder(t,e){var n=Ar(t,e);return Pe(t.body,n)}}),ce({type:"underline",names:["\\underline"],props:{numArgs:1,allowedInText:!0},handler(t,e){var{parser:n}=t;return{type:"underline",mode:n.mode,body:e[0]}},htmlBuilder(t,e){var n=_e(t.body,e),r=te.makeLineSpan("underline-line",e),i=e.fontMetrics().defaultRuleThickness,a=te.makeVList({positionType:"top",positionData:n.height,children:[{type:"kern",size:i},{type:"elem",elem:r},{type:"kern",size:3*i},{type:"elem",elem:n}]},e);return te.makeSpan(["mord","underline"],[a],e)},mathmlBuilder(t,e){var n=new Me.MathNode("mo",[new Me.TextNode("‾")]);n.setAttribute("stretchy","true");var r=new Me.MathNode("munder",[$e(t.body,e),n]);return r.setAttribute("accentunder","true"),r}}),ce({type:"vcenter",names:["\\vcenter"],props:{numArgs:1,argTypes:["original"],allowedInText:!1},handler(t,e){var{parser:n}=t;return{type:"vcenter",mode:n.mode,body:e[0]}},htmlBuilder(t,e){var n=_e(t.body,e),r=e.fontMetrics().axisHeight,i=.5*(n.height-r-(n.depth+r));return te.makeVList({positionType:"shift",positionData:i,children:[{type:"elem",elem:n}]},e)},mathmlBuilder:(t,e)=>new Me.MathNode("mpadded",[$e(t.body,e)],["vcenter"])}),ce({type:"verb",names:["\\verb"],props:{numArgs:0,allowedInText:!0},handler(t,e,n){throw new a("\\verb ended by end of line instead of matching delimiter")},htmlBuilder(t,e){for(var n=Lr(t),r=[],i=e.havingStyle(e.style.text()),a=0;at.body.replace(/ /g,t.star?"␣":" "),Mr=se,Nr="[ \r\n\t]",Ir="(\\\\[a-zA-Z@]+)"+Nr+"*",Rr="[̀-ͯ]",Dr=new RegExp(Rr+"+$"),Or="("+Nr+"+)|\\\\(\n|[ \r\t]+\n?)[ \r\t]*|([!-\\[\\]-‧‪-퟿豈-￿]"+Rr+"*|[\ud800-\udbff][\udc00-\udfff]"+Rr+"*|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5|"+Ir+"|\\\\[^\ud800-\udfff])";class Pr{constructor(t,e){this.input=void 0,this.settings=void 0,this.tokenRegex=void 0,this.catcodes=void 0,this.input=t,this.settings=e,this.tokenRegex=new RegExp(Or,"g"),this.catcodes={"%":14,"~":13}}setCatcode(t,e){this.catcodes[t]=e}lex(){var t=this.input,e=this.tokenRegex.lastIndex;if(e===t.length)return new i("EOF",new r(this,e,e));var n=this.tokenRegex.exec(t);if(null===n||n.index!==e)throw new a("Unexpected character: '"+t[e]+"'",new i(t[e],new r(this,e,e+1)));var s=n[6]||n[3]||(n[2]?"\\ ":" ");if(14===this.catcodes[s]){var o=t.indexOf("\n",this.tokenRegex.lastIndex);return-1===o?(this.tokenRegex.lastIndex=t.length,this.settings.reportNonstrict("commentAtEnd","% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)")):this.tokenRegex.lastIndex=o+1,this.lex()}return new i(s,new r(this,e,this.tokenRegex.lastIndex))}}class $r{constructor(t,e){void 0===t&&(t={}),void 0===e&&(e={}),this.current=void 0,this.builtins=void 0,this.undefStack=void 0,this.current=e,this.builtins=t,this.undefStack=[]}beginGroup(){this.undefStack.push({})}endGroup(){if(0===this.undefStack.length)throw new a("Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug");var t=this.undefStack.pop();for(var e in t)t.hasOwnProperty(e)&&(null==t[e]?delete this.current[e]:this.current[e]=t[e])}endGroups(){for(;this.undefStack.length>0;)this.endGroup()}has(t){return this.current.hasOwnProperty(t)||this.builtins.hasOwnProperty(t)}get(t){return this.current.hasOwnProperty(t)?this.current[t]:this.builtins[t]}set(t,e,n){if(void 0===n&&(n=!1),n){for(var r=0;r0&&(this.undefStack[this.undefStack.length-1][t]=e)}else{var i=this.undefStack[this.undefStack.length-1];i&&!i.hasOwnProperty(t)&&(i[t]=this.current[t])}null==e?delete this.current[t]:this.current[t]=e}}var Br=Zn;Yn("\\noexpand",(function(t){var e=t.popToken();return t.isExpandable(e.text)&&(e.noexpand=!0,e.treatAsRelax=!0),{tokens:[e],numArgs:0}})),Yn("\\expandafter",(function(t){var e=t.popToken();return t.expandOnce(!0),{tokens:[e],numArgs:0}})),Yn("\\@firstoftwo",(function(t){return{tokens:t.consumeArgs(2)[0],numArgs:0}})),Yn("\\@secondoftwo",(function(t){return{tokens:t.consumeArgs(2)[1],numArgs:0}})),Yn("\\@ifnextchar",(function(t){var e=t.consumeArgs(3);t.consumeSpaces();var n=t.future();return 1===e[0].length&&e[0][0].text===n.text?{tokens:e[1],numArgs:0}:{tokens:e[2],numArgs:0}})),Yn("\\@ifstar","\\@ifnextchar *{\\@firstoftwo{#1}}"),Yn("\\TextOrMath",(function(t){var e=t.consumeArgs(2);return"text"===t.mode?{tokens:e[0],numArgs:0}:{tokens:e[1],numArgs:0}}));var Fr={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};Yn("\\char",(function(t){var e,n=t.popToken(),r="";if("'"===n.text)e=8,n=t.popToken();else if('"'===n.text)e=16,n=t.popToken();else if("`"===n.text)if("\\"===(n=t.popToken()).text[0])r=n.text.charCodeAt(1);else{if("EOF"===n.text)throw new a("\\char` missing argument");r=n.text.charCodeAt(0)}else e=10;if(e){if(null==(r=Fr[n.text])||r>=e)throw new a("Invalid base-"+e+" digit "+n.text);for(var i;null!=(i=Fr[t.future().text])&&i{var i=t.consumeArg().tokens;if(1!==i.length)throw new a("\\newcommand's first argument must be a macro name");var s=i[0].text,o=t.isDefined(s);if(o&&!e)throw new a("\\newcommand{"+s+"} attempting to redefine "+s+"; use \\renewcommand");if(!o&&!n)throw new a("\\renewcommand{"+s+"} when command "+s+" does not yet exist; use \\newcommand");var l=0;if(1===(i=t.consumeArg().tokens).length&&"["===i[0].text){for(var c="",h=t.expandNextToken();"]"!==h.text&&"EOF"!==h.text;)c+=h.text,h=t.expandNextToken();if(!c.match(/^\s*[0-9]+\s*$/))throw new a("Invalid number of arguments: "+c);l=parseInt(c),i=t.consumeArg().tokens}return o&&r||t.macros.set(s,{tokens:i,numArgs:l}),""};Yn("\\newcommand",(t=>Wr(t,!1,!0,!1))),Yn("\\renewcommand",(t=>Wr(t,!0,!1,!1))),Yn("\\providecommand",(t=>Wr(t,!0,!0,!0))),Yn("\\message",(t=>{var e=t.consumeArgs(1)[0];return console.log(e.reverse().map((t=>t.text)).join("")),""})),Yn("\\errmessage",(t=>{var e=t.consumeArgs(1)[0];return console.error(e.reverse().map((t=>t.text)).join("")),""})),Yn("\\show",(t=>{var e=t.popToken(),n=e.text;return console.log(e,t.macros.get(n),Mr[n],ht.math[n],ht.text[n]),""})),Yn("\\bgroup","{"),Yn("\\egroup","}"),Yn("~","\\nobreakspace"),Yn("\\lq","`"),Yn("\\rq","'"),Yn("\\aa","\\r a"),Yn("\\AA","\\r A"),Yn("\\textcopyright","\\html@mathml{\\textcircled{c}}{\\char`©}"),Yn("\\copyright","\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}"),Yn("\\textregistered","\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}"),Yn("ℬ","\\mathscr{B}"),Yn("ℰ","\\mathscr{E}"),Yn("ℱ","\\mathscr{F}"),Yn("ℋ","\\mathscr{H}"),Yn("ℐ","\\mathscr{I}"),Yn("ℒ","\\mathscr{L}"),Yn("ℳ","\\mathscr{M}"),Yn("ℛ","\\mathscr{R}"),Yn("ℭ","\\mathfrak{C}"),Yn("ℌ","\\mathfrak{H}"),Yn("ℨ","\\mathfrak{Z}"),Yn("\\Bbbk","\\Bbb{k}"),Yn("·","\\cdotp"),Yn("\\llap","\\mathllap{\\textrm{#1}}"),Yn("\\rlap","\\mathrlap{\\textrm{#1}}"),Yn("\\clap","\\mathclap{\\textrm{#1}}"),Yn("\\mathstrut","\\vphantom{(}"),Yn("\\underbar","\\underline{\\text{#1}}"),Yn("\\not",'\\html@mathml{\\mathrel{\\mathrlap\\@not}}{\\char"338}'),Yn("\\neq","\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}"),Yn("\\ne","\\neq"),Yn("≠","\\neq"),Yn("\\notin","\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}"),Yn("∉","\\notin"),Yn("≘","\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}"),Yn("≙","\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}"),Yn("≚","\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}"),Yn("≛","\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}"),Yn("≝","\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}"),Yn("≞","\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}"),Yn("≟","\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}"),Yn("⟂","\\perp"),Yn("‼","\\mathclose{!\\mkern-0.8mu!}"),Yn("∌","\\notni"),Yn("⌜","\\ulcorner"),Yn("⌝","\\urcorner"),Yn("⌞","\\llcorner"),Yn("⌟","\\lrcorner"),Yn("©","\\copyright"),Yn("®","\\textregistered"),Yn("️","\\textregistered"),Yn("\\ulcorner",'\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}'),Yn("\\urcorner",'\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}'),Yn("\\llcorner",'\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}'),Yn("\\lrcorner",'\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}'),Yn("\\vdots","{\\varvdots\\rule{0pt}{15pt}}"),Yn("⋮","\\vdots"),Yn("\\varGamma","\\mathit{\\Gamma}"),Yn("\\varDelta","\\mathit{\\Delta}"),Yn("\\varTheta","\\mathit{\\Theta}"),Yn("\\varLambda","\\mathit{\\Lambda}"),Yn("\\varXi","\\mathit{\\Xi}"),Yn("\\varPi","\\mathit{\\Pi}"),Yn("\\varSigma","\\mathit{\\Sigma}"),Yn("\\varUpsilon","\\mathit{\\Upsilon}"),Yn("\\varPhi","\\mathit{\\Phi}"),Yn("\\varPsi","\\mathit{\\Psi}"),Yn("\\varOmega","\\mathit{\\Omega}"),Yn("\\substack","\\begin{subarray}{c}#1\\end{subarray}"),Yn("\\colon","\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax"),Yn("\\boxed","\\fbox{$\\displaystyle{#1}$}"),Yn("\\iff","\\DOTSB\\;\\Longleftrightarrow\\;"),Yn("\\implies","\\DOTSB\\;\\Longrightarrow\\;"),Yn("\\impliedby","\\DOTSB\\;\\Longleftarrow\\;"),Yn("\\dddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}"),Yn("\\ddddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}");var zr={",":"\\dotsc","\\not":"\\dotsb","+":"\\dotsb","=":"\\dotsb","<":"\\dotsb",">":"\\dotsb","-":"\\dotsb","*":"\\dotsb",":":"\\dotsb","\\DOTSB":"\\dotsb","\\coprod":"\\dotsb","\\bigvee":"\\dotsb","\\bigwedge":"\\dotsb","\\biguplus":"\\dotsb","\\bigcap":"\\dotsb","\\bigcup":"\\dotsb","\\prod":"\\dotsb","\\sum":"\\dotsb","\\bigotimes":"\\dotsb","\\bigoplus":"\\dotsb","\\bigodot":"\\dotsb","\\bigsqcup":"\\dotsb","\\And":"\\dotsb","\\longrightarrow":"\\dotsb","\\Longrightarrow":"\\dotsb","\\longleftarrow":"\\dotsb","\\Longleftarrow":"\\dotsb","\\longleftrightarrow":"\\dotsb","\\Longleftrightarrow":"\\dotsb","\\mapsto":"\\dotsb","\\longmapsto":"\\dotsb","\\hookrightarrow":"\\dotsb","\\doteq":"\\dotsb","\\mathbin":"\\dotsb","\\mathrel":"\\dotsb","\\relbar":"\\dotsb","\\Relbar":"\\dotsb","\\xrightarrow":"\\dotsb","\\xleftarrow":"\\dotsb","\\DOTSI":"\\dotsi","\\int":"\\dotsi","\\oint":"\\dotsi","\\iint":"\\dotsi","\\iiint":"\\dotsi","\\iiiint":"\\dotsi","\\idotsint":"\\dotsi","\\DOTSX":"\\dotsx"};Yn("\\dots",(function(t){var e="\\dotso",n=t.expandAfterFuture().text;return n in zr?e=zr[n]:("\\not"===n.slice(0,4)||n in ht.math&&h(["bin","rel"],ht.math[n].group))&&(e="\\dotsb"),e}));var Zr={")":!0,"]":!0,"\\rbrack":!0,"\\}":!0,"\\rbrace":!0,"\\rangle":!0,"\\rceil":!0,"\\rfloor":!0,"\\rgroup":!0,"\\rmoustache":!0,"\\right":!0,"\\bigr":!0,"\\biggr":!0,"\\Bigr":!0,"\\Biggr":!0,$:!0,";":!0,".":!0,",":!0};Yn("\\dotso",(function(t){return t.future().text in Zr?"\\ldots\\,":"\\ldots"})),Yn("\\dotsc",(function(t){var e=t.future().text;return e in Zr&&","!==e?"\\ldots\\,":"\\ldots"})),Yn("\\cdots",(function(t){return t.future().text in Zr?"\\@cdots\\,":"\\@cdots"})),Yn("\\dotsb","\\cdots"),Yn("\\dotsm","\\cdots"),Yn("\\dotsi","\\!\\cdots"),Yn("\\dotsx","\\ldots\\,"),Yn("\\DOTSI","\\relax"),Yn("\\DOTSB","\\relax"),Yn("\\DOTSX","\\relax"),Yn("\\tmspace","\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax"),Yn("\\,","\\tmspace+{3mu}{.1667em}"),Yn("\\thinspace","\\,"),Yn("\\>","\\mskip{4mu}"),Yn("\\:","\\tmspace+{4mu}{.2222em}"),Yn("\\medspace","\\:"),Yn("\\;","\\tmspace+{5mu}{.2777em}"),Yn("\\thickspace","\\;"),Yn("\\!","\\tmspace-{3mu}{.1667em}"),Yn("\\negthinspace","\\!"),Yn("\\negmedspace","\\tmspace-{4mu}{.2222em}"),Yn("\\negthickspace","\\tmspace-{5mu}{.277em}"),Yn("\\enspace","\\kern.5em "),Yn("\\enskip","\\hskip.5em\\relax"),Yn("\\quad","\\hskip1em\\relax"),Yn("\\qquad","\\hskip2em\\relax"),Yn("\\tag","\\@ifstar\\tag@literal\\tag@paren"),Yn("\\tag@paren","\\tag@literal{({#1})}"),Yn("\\tag@literal",(t=>{if(t.macros.get("\\df@tag"))throw new a("Multiple \\tag");return"\\gdef\\df@tag{\\text{#1}}"})),Yn("\\bmod","\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}"),Yn("\\pod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)"),Yn("\\pmod","\\pod{{\\rm mod}\\mkern6mu#1}"),Yn("\\mod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1"),Yn("\\newline","\\\\\\relax"),Yn("\\TeX","\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");var Yr=q(D["Main-Regular"]["T".charCodeAt(0)][1]-.7*D["Main-Regular"]["A".charCodeAt(0)][1]);Yn("\\LaTeX","\\textrm{\\html@mathml{L\\kern-.36em\\raisebox{"+Yr+"}{\\scriptstyle A}\\kern-.15em\\TeX}{LaTeX}}"),Yn("\\KaTeX","\\textrm{\\html@mathml{K\\kern-.17em\\raisebox{"+Yr+"}{\\scriptstyle A}\\kern-.15em\\TeX}{KaTeX}}"),Yn("\\hspace","\\@ifstar\\@hspacer\\@hspace"),Yn("\\@hspace","\\hskip #1\\relax"),Yn("\\@hspacer","\\rule{0pt}{0pt}\\hskip #1\\relax"),Yn("\\ordinarycolon",":"),Yn("\\vcentcolon","\\mathrel{\\mathop\\ordinarycolon}"),Yn("\\dblcolon",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}'),Yn("\\coloneqq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}'),Yn("\\Coloneqq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}'),Yn("\\coloneq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}'),Yn("\\Coloneq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}'),Yn("\\eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}'),Yn("\\Eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}'),Yn("\\eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}'),Yn("\\Eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}'),Yn("\\colonapprox",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}'),Yn("\\Colonapprox",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}'),Yn("\\colonsim",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}'),Yn("\\Colonsim",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}'),Yn("∷","\\dblcolon"),Yn("∹","\\eqcolon"),Yn("≔","\\coloneqq"),Yn("≕","\\eqqcolon"),Yn("⩴","\\Coloneqq"),Yn("\\ratio","\\vcentcolon"),Yn("\\coloncolon","\\dblcolon"),Yn("\\colonequals","\\coloneqq"),Yn("\\coloncolonequals","\\Coloneqq"),Yn("\\equalscolon","\\eqqcolon"),Yn("\\equalscoloncolon","\\Eqqcolon"),Yn("\\colonminus","\\coloneq"),Yn("\\coloncolonminus","\\Coloneq"),Yn("\\minuscolon","\\eqcolon"),Yn("\\minuscoloncolon","\\Eqcolon"),Yn("\\coloncolonapprox","\\Colonapprox"),Yn("\\coloncolonsim","\\Colonsim"),Yn("\\simcolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}"),Yn("\\simcoloncolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}"),Yn("\\approxcolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}"),Yn("\\approxcoloncolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}"),Yn("\\notni","\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}"),Yn("\\limsup","\\DOTSB\\operatorname*{lim\\,sup}"),Yn("\\liminf","\\DOTSB\\operatorname*{lim\\,inf}"),Yn("\\injlim","\\DOTSB\\operatorname*{inj\\,lim}"),Yn("\\projlim","\\DOTSB\\operatorname*{proj\\,lim}"),Yn("\\varlimsup","\\DOTSB\\operatorname*{\\overline{lim}}"),Yn("\\varliminf","\\DOTSB\\operatorname*{\\underline{lim}}"),Yn("\\varinjlim","\\DOTSB\\operatorname*{\\underrightarrow{lim}}"),Yn("\\varprojlim","\\DOTSB\\operatorname*{\\underleftarrow{lim}}"),Yn("\\gvertneqq","\\html@mathml{\\@gvertneqq}{≩}"),Yn("\\lvertneqq","\\html@mathml{\\@lvertneqq}{≨}"),Yn("\\ngeqq","\\html@mathml{\\@ngeqq}{≱}"),Yn("\\ngeqslant","\\html@mathml{\\@ngeqslant}{≱}"),Yn("\\nleqq","\\html@mathml{\\@nleqq}{≰}"),Yn("\\nleqslant","\\html@mathml{\\@nleqslant}{≰}"),Yn("\\nshortmid","\\html@mathml{\\@nshortmid}{∤}"),Yn("\\nshortparallel","\\html@mathml{\\@nshortparallel}{∦}"),Yn("\\nsubseteqq","\\html@mathml{\\@nsubseteqq}{⊈}"),Yn("\\nsupseteqq","\\html@mathml{\\@nsupseteqq}{⊉}"),Yn("\\varsubsetneq","\\html@mathml{\\@varsubsetneq}{⊊}"),Yn("\\varsubsetneqq","\\html@mathml{\\@varsubsetneqq}{⫋}"),Yn("\\varsupsetneq","\\html@mathml{\\@varsupsetneq}{⊋}"),Yn("\\varsupsetneqq","\\html@mathml{\\@varsupsetneqq}{⫌}"),Yn("\\imath","\\html@mathml{\\@imath}{ı}"),Yn("\\jmath","\\html@mathml{\\@jmath}{ȷ}"),Yn("\\llbracket","\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}"),Yn("\\rrbracket","\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}"),Yn("⟦","\\llbracket"),Yn("⟧","\\rrbracket"),Yn("\\lBrace","\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}"),Yn("\\rBrace","\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}"),Yn("⦃","\\lBrace"),Yn("⦄","\\rBrace"),Yn("\\minuso","\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}"),Yn("⦵","\\minuso"),Yn("\\darr","\\downarrow"),Yn("\\dArr","\\Downarrow"),Yn("\\Darr","\\Downarrow"),Yn("\\lang","\\langle"),Yn("\\rang","\\rangle"),Yn("\\uarr","\\uparrow"),Yn("\\uArr","\\Uparrow"),Yn("\\Uarr","\\Uparrow"),Yn("\\N","\\mathbb{N}"),Yn("\\R","\\mathbb{R}"),Yn("\\Z","\\mathbb{Z}"),Yn("\\alef","\\aleph"),Yn("\\alefsym","\\aleph"),Yn("\\Alpha","\\mathrm{A}"),Yn("\\Beta","\\mathrm{B}"),Yn("\\bull","\\bullet"),Yn("\\Chi","\\mathrm{X}"),Yn("\\clubs","\\clubsuit"),Yn("\\cnums","\\mathbb{C}"),Yn("\\Complex","\\mathbb{C}"),Yn("\\Dagger","\\ddagger"),Yn("\\diamonds","\\diamondsuit"),Yn("\\empty","\\emptyset"),Yn("\\Epsilon","\\mathrm{E}"),Yn("\\Eta","\\mathrm{H}"),Yn("\\exist","\\exists"),Yn("\\harr","\\leftrightarrow"),Yn("\\hArr","\\Leftrightarrow"),Yn("\\Harr","\\Leftrightarrow"),Yn("\\hearts","\\heartsuit"),Yn("\\image","\\Im"),Yn("\\infin","\\infty"),Yn("\\Iota","\\mathrm{I}"),Yn("\\isin","\\in"),Yn("\\Kappa","\\mathrm{K}"),Yn("\\larr","\\leftarrow"),Yn("\\lArr","\\Leftarrow"),Yn("\\Larr","\\Leftarrow"),Yn("\\lrarr","\\leftrightarrow"),Yn("\\lrArr","\\Leftrightarrow"),Yn("\\Lrarr","\\Leftrightarrow"),Yn("\\Mu","\\mathrm{M}"),Yn("\\natnums","\\mathbb{N}"),Yn("\\Nu","\\mathrm{N}"),Yn("\\Omicron","\\mathrm{O}"),Yn("\\plusmn","\\pm"),Yn("\\rarr","\\rightarrow"),Yn("\\rArr","\\Rightarrow"),Yn("\\Rarr","\\Rightarrow"),Yn("\\real","\\Re"),Yn("\\reals","\\mathbb{R}"),Yn("\\Reals","\\mathbb{R}"),Yn("\\Rho","\\mathrm{P}"),Yn("\\sdot","\\cdot"),Yn("\\sect","\\S"),Yn("\\spades","\\spadesuit"),Yn("\\sub","\\subset"),Yn("\\sube","\\subseteq"),Yn("\\supe","\\supseteq"),Yn("\\Tau","\\mathrm{T}"),Yn("\\thetasym","\\vartheta"),Yn("\\weierp","\\wp"),Yn("\\Zeta","\\mathrm{Z}"),Yn("\\argmin","\\DOTSB\\operatorname*{arg\\,min}"),Yn("\\argmax","\\DOTSB\\operatorname*{arg\\,max}"),Yn("\\plim","\\DOTSB\\mathop{\\operatorname{plim}}\\limits"),Yn("\\bra","\\mathinner{\\langle{#1}|}"),Yn("\\ket","\\mathinner{|{#1}\\rangle}"),Yn("\\braket","\\mathinner{\\langle{#1}\\rangle}"),Yn("\\Bra","\\left\\langle#1\\right|"),Yn("\\Ket","\\left|#1\\right\\rangle");var Ur=t=>e=>{var n=e.consumeArg().tokens,r=e.consumeArg().tokens,i=e.consumeArg().tokens,a=e.consumeArg().tokens,s=e.macros.get("|"),o=e.macros.get("\\|");e.macros.beginGroup();var l=e=>n=>{t&&(n.macros.set("|",s),i.length&&n.macros.set("\\|",o));var a=e;return!e&&i.length&&"|"===n.future().text&&(n.popToken(),a=!0),{tokens:a?i:r,numArgs:0}};e.macros.set("|",l(!1)),i.length&&e.macros.set("\\|",l(!0));var c=e.consumeArg().tokens,h=e.expandTokens([...a,...c,...n]);return e.macros.endGroup(),{tokens:h.reverse(),numArgs:0}};Yn("\\bra@ket",Ur(!1)),Yn("\\bra@set",Ur(!0)),Yn("\\Braket","\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}"),Yn("\\Set","\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}"),Yn("\\set","\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}"),Yn("\\angln","{\\angl n}"),Yn("\\blue","\\textcolor{##6495ed}{#1}"),Yn("\\orange","\\textcolor{##ffa500}{#1}"),Yn("\\pink","\\textcolor{##ff00af}{#1}"),Yn("\\red","\\textcolor{##df0030}{#1}"),Yn("\\green","\\textcolor{##28ae7b}{#1}"),Yn("\\gray","\\textcolor{gray}{#1}"),Yn("\\purple","\\textcolor{##9d38bd}{#1}"),Yn("\\blueA","\\textcolor{##ccfaff}{#1}"),Yn("\\blueB","\\textcolor{##80f6ff}{#1}"),Yn("\\blueC","\\textcolor{##63d9ea}{#1}"),Yn("\\blueD","\\textcolor{##11accd}{#1}"),Yn("\\blueE","\\textcolor{##0c7f99}{#1}"),Yn("\\tealA","\\textcolor{##94fff5}{#1}"),Yn("\\tealB","\\textcolor{##26edd5}{#1}"),Yn("\\tealC","\\textcolor{##01d1c1}{#1}"),Yn("\\tealD","\\textcolor{##01a995}{#1}"),Yn("\\tealE","\\textcolor{##208170}{#1}"),Yn("\\greenA","\\textcolor{##b6ffb0}{#1}"),Yn("\\greenB","\\textcolor{##8af281}{#1}"),Yn("\\greenC","\\textcolor{##74cf70}{#1}"),Yn("\\greenD","\\textcolor{##1fab54}{#1}"),Yn("\\greenE","\\textcolor{##0d923f}{#1}"),Yn("\\goldA","\\textcolor{##ffd0a9}{#1}"),Yn("\\goldB","\\textcolor{##ffbb71}{#1}"),Yn("\\goldC","\\textcolor{##ff9c39}{#1}"),Yn("\\goldD","\\textcolor{##e07d10}{#1}"),Yn("\\goldE","\\textcolor{##a75a05}{#1}"),Yn("\\redA","\\textcolor{##fca9a9}{#1}"),Yn("\\redB","\\textcolor{##ff8482}{#1}"),Yn("\\redC","\\textcolor{##f9685d}{#1}"),Yn("\\redD","\\textcolor{##e84d39}{#1}"),Yn("\\redE","\\textcolor{##bc2612}{#1}"),Yn("\\maroonA","\\textcolor{##ffbde0}{#1}"),Yn("\\maroonB","\\textcolor{##ff92c6}{#1}"),Yn("\\maroonC","\\textcolor{##ed5fa6}{#1}"),Yn("\\maroonD","\\textcolor{##ca337c}{#1}"),Yn("\\maroonE","\\textcolor{##9e034e}{#1}"),Yn("\\purpleA","\\textcolor{##ddd7ff}{#1}"),Yn("\\purpleB","\\textcolor{##c6b9fc}{#1}"),Yn("\\purpleC","\\textcolor{##aa87ff}{#1}"),Yn("\\purpleD","\\textcolor{##7854ab}{#1}"),Yn("\\purpleE","\\textcolor{##543b78}{#1}"),Yn("\\mintA","\\textcolor{##f5f9e8}{#1}"),Yn("\\mintB","\\textcolor{##edf2df}{#1}"),Yn("\\mintC","\\textcolor{##e0e5cc}{#1}"),Yn("\\grayA","\\textcolor{##f6f7f7}{#1}"),Yn("\\grayB","\\textcolor{##f0f1f2}{#1}"),Yn("\\grayC","\\textcolor{##e3e5e6}{#1}"),Yn("\\grayD","\\textcolor{##d6d8da}{#1}"),Yn("\\grayE","\\textcolor{##babec2}{#1}"),Yn("\\grayF","\\textcolor{##888d93}{#1}"),Yn("\\grayG","\\textcolor{##626569}{#1}"),Yn("\\grayH","\\textcolor{##3b3e40}{#1}"),Yn("\\grayI","\\textcolor{##21242c}{#1}"),Yn("\\kaBlue","\\textcolor{##314453}{#1}"),Yn("\\kaGreen","\\textcolor{##71B307}{#1}");var Gr={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0};class Vr{constructor(t,e,n){this.settings=void 0,this.expansionCount=void 0,this.lexer=void 0,this.macros=void 0,this.stack=void 0,this.mode=void 0,this.settings=e,this.expansionCount=0,this.feed(t),this.macros=new $r(Br,e.macros),this.mode=n,this.stack=[]}feed(t){this.lexer=new Pr(t,this.settings)}switchMode(t){this.mode=t}beginGroup(){this.macros.beginGroup()}endGroup(){this.macros.endGroup()}endGroups(){this.macros.endGroups()}future(){return 0===this.stack.length&&this.pushToken(this.lexer.lex()),this.stack[this.stack.length-1]}popToken(){return this.future(),this.stack.pop()}pushToken(t){this.stack.push(t)}pushTokens(t){this.stack.push(...t)}scanArgument(t){var e,n,r;if(t){if(this.consumeSpaces(),"["!==this.future().text)return null;e=this.popToken(),({tokens:r,end:n}=this.consumeArg(["]"]))}else({tokens:r,start:e,end:n}=this.consumeArg());return this.pushToken(new i("EOF",n.loc)),this.pushTokens(r),e.range(n,"")}consumeSpaces(){for(;" "===this.future().text;)this.stack.pop()}consumeArg(t){var e=[],n=t&&t.length>0;n||this.consumeSpaces();var r,i=this.future(),s=0,o=0;do{if(r=this.popToken(),e.push(r),"{"===r.text)++s;else if("}"===r.text){if(-1==--s)throw new a("Extra }",r)}else if("EOF"===r.text)throw new a("Unexpected end of input in a macro argument, expected '"+(t&&n?t[o]:"}")+"'",r);if(t&&n)if((0===s||1===s&&"{"===t[o])&&r.text===t[o]){if(++o===t.length){e.splice(-o,o);break}}else o=0}while(0!==s||n);return"{"===i.text&&"}"===e[e.length-1].text&&(e.pop(),e.shift()),e.reverse(),{tokens:e,start:i,end:r}}consumeArgs(t,e){if(e){if(e.length!==t+1)throw new a("The length of delimiters doesn't match the number of args!");for(var n=e[0],r=0;rthis.settings.maxExpand)throw new a("Too many expansions: infinite loop or need to increase maxExpand setting")}expandOnce(t){var e=this.popToken(),n=e.text,r=e.noexpand?null:this._getExpansion(n);if(null==r||t&&r.unexpandable){if(t&&null==r&&"\\"===n[0]&&!this.isDefined(n))throw new a("Undefined control sequence: "+n);return this.pushToken(e),!1}this.countExpansion(1);var i=r.tokens,s=this.consumeArgs(r.numArgs,r.delimiters);if(r.numArgs)for(var o=(i=i.slice()).length-1;o>=0;--o){var l=i[o];if("#"===l.text){if(0===o)throw new a("Incomplete placeholder at end of macro body",l);if("#"===(l=i[--o]).text)i.splice(o+1,1);else{if(!/^[1-9]$/.test(l.text))throw new a("Not a valid argument number",l);i.splice(o,2,...s[+l.text-1])}}}return this.pushTokens(i),i.length}expandAfterFuture(){return this.expandOnce(),this.future()}expandNextToken(){for(;;)if(!1===this.expandOnce()){var t=this.stack.pop();return t.treatAsRelax&&(t.text="\\relax"),t}throw new Error}expandMacro(t){return this.macros.has(t)?this.expandTokens([new i(t)]):void 0}expandTokens(t){var e=[],n=this.stack.length;for(this.pushTokens(t);this.stack.length>n;)if(!1===this.expandOnce(!0)){var r=this.stack.pop();r.treatAsRelax&&(r.noexpand=!1,r.treatAsRelax=!1),e.push(r)}return this.countExpansion(e.length),e}expandMacroAsText(t){var e=this.expandMacro(t);return e?e.map((t=>t.text)).join(""):e}_getExpansion(t){var e=this.macros.get(t);if(null==e)return e;if(1===t.length){var n=this.lexer.catcodes[t];if(null!=n&&13!==n)return}var r="function"==typeof e?e(this):e;if("string"==typeof r){var i=0;if(-1!==r.indexOf("#"))for(var a=r.replace(/##/g,"");-1!==a.indexOf("#"+(i+1));)++i;for(var s=new Pr(r,this.settings),o=[],l=s.lex();"EOF"!==l.text;)o.push(l),l=s.lex();return o.reverse(),{tokens:o,numArgs:i}}return r}isDefined(t){return this.macros.has(t)||Mr.hasOwnProperty(t)||ht.math.hasOwnProperty(t)||ht.text.hasOwnProperty(t)||Gr.hasOwnProperty(t)}isExpandable(t){var e=this.macros.get(t);return null!=e?"string"==typeof e||"function"==typeof e||!e.unexpandable:Mr.hasOwnProperty(t)&&!Mr[t].primitive}}var qr=/^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/,jr=Object.freeze({"₊":"+","₋":"-","₌":"=","₍":"(","₎":")","₀":"0","₁":"1","₂":"2","₃":"3","₄":"4","₅":"5","₆":"6","₇":"7","₈":"8","₉":"9",ₐ:"a",ₑ:"e",ₕ:"h",ᵢ:"i",ⱼ:"j",ₖ:"k",ₗ:"l",ₘ:"m",ₙ:"n",ₒ:"o",ₚ:"p",ᵣ:"r",ₛ:"s",ₜ:"t",ᵤ:"u",ᵥ:"v",ₓ:"x",ᵦ:"β",ᵧ:"γ",ᵨ:"ρ",ᵩ:"ϕ",ᵪ:"χ","⁺":"+","⁻":"-","⁼":"=","⁽":"(","⁾":")","⁰":"0","¹":"1","²":"2","³":"3","⁴":"4","⁵":"5","⁶":"6","⁷":"7","⁸":"8","⁹":"9",ᴬ:"A",ᴮ:"B",ᴰ:"D",ᴱ:"E",ᴳ:"G",ᴴ:"H",ᴵ:"I",ᴶ:"J",ᴷ:"K",ᴸ:"L",ᴹ:"M",ᴺ:"N",ᴼ:"O",ᴾ:"P",ᴿ:"R",ᵀ:"T",ᵁ:"U",ⱽ:"V",ᵂ:"W",ᵃ:"a",ᵇ:"b",ᶜ:"c",ᵈ:"d",ᵉ:"e",ᶠ:"f",ᵍ:"g",ʰ:"h",ⁱ:"i",ʲ:"j",ᵏ:"k",ˡ:"l",ᵐ:"m",ⁿ:"n",ᵒ:"o",ᵖ:"p",ʳ:"r",ˢ:"s",ᵗ:"t",ᵘ:"u",ᵛ:"v",ʷ:"w",ˣ:"x",ʸ:"y",ᶻ:"z",ᵝ:"β",ᵞ:"γ",ᵟ:"δ",ᵠ:"ϕ",ᵡ:"χ",ᶿ:"θ"}),Hr={"́":{text:"\\'",math:"\\acute"},"̀":{text:"\\`",math:"\\grave"},"̈":{text:'\\"',math:"\\ddot"},"̃":{text:"\\~",math:"\\tilde"},"̄":{text:"\\=",math:"\\bar"},"̆":{text:"\\u",math:"\\breve"},"̌":{text:"\\v",math:"\\check"},"̂":{text:"\\^",math:"\\hat"},"̇":{text:"\\.",math:"\\dot"},"̊":{text:"\\r",math:"\\mathring"},"̋":{text:"\\H"},"̧":{text:"\\c"}},Xr={á:"á",à:"à",ä:"ä",ǟ:"ǟ",ã:"ã",ā:"ā",ă:"ă",ắ:"ắ",ằ:"ằ",ẵ:"ẵ",ǎ:"ǎ",â:"â",ấ:"ấ",ầ:"ầ",ẫ:"ẫ",ȧ:"ȧ",ǡ:"ǡ",å:"å",ǻ:"ǻ",ḃ:"ḃ",ć:"ć",ḉ:"ḉ",č:"č",ĉ:"ĉ",ċ:"ċ",ç:"ç",ď:"ď",ḋ:"ḋ",ḑ:"ḑ",é:"é",è:"è",ë:"ë",ẽ:"ẽ",ē:"ē",ḗ:"ḗ",ḕ:"ḕ",ĕ:"ĕ",ḝ:"ḝ",ě:"ě",ê:"ê",ế:"ế",ề:"ề",ễ:"ễ",ė:"ė",ȩ:"ȩ",ḟ:"ḟ",ǵ:"ǵ",ḡ:"ḡ",ğ:"ğ",ǧ:"ǧ",ĝ:"ĝ",ġ:"ġ",ģ:"ģ",ḧ:"ḧ",ȟ:"ȟ",ĥ:"ĥ",ḣ:"ḣ",ḩ:"ḩ",í:"í",ì:"ì",ï:"ï",ḯ:"ḯ",ĩ:"ĩ",ī:"ī",ĭ:"ĭ",ǐ:"ǐ",î:"î",ǰ:"ǰ",ĵ:"ĵ",ḱ:"ḱ",ǩ:"ǩ",ķ:"ķ",ĺ:"ĺ",ľ:"ľ",ļ:"ļ",ḿ:"ḿ",ṁ:"ṁ",ń:"ń",ǹ:"ǹ",ñ:"ñ",ň:"ň",ṅ:"ṅ",ņ:"ņ",ó:"ó",ò:"ò",ö:"ö",ȫ:"ȫ",õ:"õ",ṍ:"ṍ",ṏ:"ṏ",ȭ:"ȭ",ō:"ō",ṓ:"ṓ",ṑ:"ṑ",ŏ:"ŏ",ǒ:"ǒ",ô:"ô",ố:"ố",ồ:"ồ",ỗ:"ỗ",ȯ:"ȯ",ȱ:"ȱ",ő:"ő",ṕ:"ṕ",ṗ:"ṗ",ŕ:"ŕ",ř:"ř",ṙ:"ṙ",ŗ:"ŗ",ś:"ś",ṥ:"ṥ",š:"š",ṧ:"ṧ",ŝ:"ŝ",ṡ:"ṡ",ş:"ş",ẗ:"ẗ",ť:"ť",ṫ:"ṫ",ţ:"ţ",ú:"ú",ù:"ù",ü:"ü",ǘ:"ǘ",ǜ:"ǜ",ǖ:"ǖ",ǚ:"ǚ",ũ:"ũ",ṹ:"ṹ",ū:"ū",ṻ:"ṻ",ŭ:"ŭ",ǔ:"ǔ",û:"û",ů:"ů",ű:"ű",ṽ:"ṽ",ẃ:"ẃ",ẁ:"ẁ",ẅ:"ẅ",ŵ:"ŵ",ẇ:"ẇ",ẘ:"ẘ",ẍ:"ẍ",ẋ:"ẋ",ý:"ý",ỳ:"ỳ",ÿ:"ÿ",ỹ:"ỹ",ȳ:"ȳ",ŷ:"ŷ",ẏ:"ẏ",ẙ:"ẙ",ź:"ź",ž:"ž",ẑ:"ẑ",ż:"ż",Á:"Á",À:"À",Ä:"Ä",Ǟ:"Ǟ",Ã:"Ã",Ā:"Ā",Ă:"Ă",Ắ:"Ắ",Ằ:"Ằ",Ẵ:"Ẵ",Ǎ:"Ǎ",Â:"Â",Ấ:"Ấ",Ầ:"Ầ",Ẫ:"Ẫ",Ȧ:"Ȧ",Ǡ:"Ǡ",Å:"Å",Ǻ:"Ǻ",Ḃ:"Ḃ",Ć:"Ć",Ḉ:"Ḉ",Č:"Č",Ĉ:"Ĉ",Ċ:"Ċ",Ç:"Ç",Ď:"Ď",Ḋ:"Ḋ",Ḑ:"Ḑ",É:"É",È:"È",Ë:"Ë",Ẽ:"Ẽ",Ē:"Ē",Ḗ:"Ḗ",Ḕ:"Ḕ",Ĕ:"Ĕ",Ḝ:"Ḝ",Ě:"Ě",Ê:"Ê",Ế:"Ế",Ề:"Ề",Ễ:"Ễ",Ė:"Ė",Ȩ:"Ȩ",Ḟ:"Ḟ",Ǵ:"Ǵ",Ḡ:"Ḡ",Ğ:"Ğ",Ǧ:"Ǧ",Ĝ:"Ĝ",Ġ:"Ġ",Ģ:"Ģ",Ḧ:"Ḧ",Ȟ:"Ȟ",Ĥ:"Ĥ",Ḣ:"Ḣ",Ḩ:"Ḩ",Í:"Í",Ì:"Ì",Ï:"Ï",Ḯ:"Ḯ",Ĩ:"Ĩ",Ī:"Ī",Ĭ:"Ĭ",Ǐ:"Ǐ",Î:"Î",İ:"İ",Ĵ:"Ĵ",Ḱ:"Ḱ",Ǩ:"Ǩ",Ķ:"Ķ",Ĺ:"Ĺ",Ľ:"Ľ",Ļ:"Ļ",Ḿ:"Ḿ",Ṁ:"Ṁ",Ń:"Ń",Ǹ:"Ǹ",Ñ:"Ñ",Ň:"Ň",Ṅ:"Ṅ",Ņ:"Ņ",Ó:"Ó",Ò:"Ò",Ö:"Ö",Ȫ:"Ȫ",Õ:"Õ",Ṍ:"Ṍ",Ṏ:"Ṏ",Ȭ:"Ȭ",Ō:"Ō",Ṓ:"Ṓ",Ṑ:"Ṑ",Ŏ:"Ŏ",Ǒ:"Ǒ",Ô:"Ô",Ố:"Ố",Ồ:"Ồ",Ỗ:"Ỗ",Ȯ:"Ȯ",Ȱ:"Ȱ",Ő:"Ő",Ṕ:"Ṕ",Ṗ:"Ṗ",Ŕ:"Ŕ",Ř:"Ř",Ṙ:"Ṙ",Ŗ:"Ŗ",Ś:"Ś",Ṥ:"Ṥ",Š:"Š",Ṧ:"Ṧ",Ŝ:"Ŝ",Ṡ:"Ṡ",Ş:"Ş",Ť:"Ť",Ṫ:"Ṫ",Ţ:"Ţ",Ú:"Ú",Ù:"Ù",Ü:"Ü",Ǘ:"Ǘ",Ǜ:"Ǜ",Ǖ:"Ǖ",Ǚ:"Ǚ",Ũ:"Ũ",Ṹ:"Ṹ",Ū:"Ū",Ṻ:"Ṻ",Ŭ:"Ŭ",Ǔ:"Ǔ",Û:"Û",Ů:"Ů",Ű:"Ű",Ṽ:"Ṽ",Ẃ:"Ẃ",Ẁ:"Ẁ",Ẅ:"Ẅ",Ŵ:"Ŵ",Ẇ:"Ẇ",Ẍ:"Ẍ",Ẋ:"Ẋ",Ý:"Ý",Ỳ:"Ỳ",Ÿ:"Ÿ",Ỹ:"Ỹ",Ȳ:"Ȳ",Ŷ:"Ŷ",Ẏ:"Ẏ",Ź:"Ź",Ž:"Ž",Ẑ:"Ẑ",Ż:"Ż",ά:"ά",ὰ:"ὰ",ᾱ:"ᾱ",ᾰ:"ᾰ",έ:"έ",ὲ:"ὲ",ή:"ή",ὴ:"ὴ",ί:"ί",ὶ:"ὶ",ϊ:"ϊ",ΐ:"ΐ",ῒ:"ῒ",ῑ:"ῑ",ῐ:"ῐ",ό:"ό",ὸ:"ὸ",ύ:"ύ",ὺ:"ὺ",ϋ:"ϋ",ΰ:"ΰ",ῢ:"ῢ",ῡ:"ῡ",ῠ:"ῠ",ώ:"ώ",ὼ:"ὼ",Ύ:"Ύ",Ὺ:"Ὺ",Ϋ:"Ϋ",Ῡ:"Ῡ",Ῠ:"Ῠ",Ώ:"Ώ",Ὼ:"Ὼ"};class Kr{constructor(t,e){this.mode=void 0,this.gullet=void 0,this.settings=void 0,this.leftrightDepth=void 0,this.nextToken=void 0,this.mode="math",this.gullet=new Vr(t,e,this.mode),this.settings=e,this.leftrightDepth=0}expect(t,e){if(void 0===e&&(e=!0),this.fetch().text!==t)throw new a("Expected '"+t+"', got '"+this.fetch().text+"'",this.fetch());e&&this.consume()}consume(){this.nextToken=null}fetch(){return null==this.nextToken&&(this.nextToken=this.gullet.expandNextToken()),this.nextToken}switchMode(t){this.mode=t,this.gullet.switchMode(t)}parse(){this.settings.globalGroup||this.gullet.beginGroup(),this.settings.colorIsTextColor&&this.gullet.macros.set("\\color","\\textcolor");try{var t=this.parseExpression(!1);return this.expect("EOF"),this.settings.globalGroup||this.gullet.endGroup(),t}finally{this.gullet.endGroups()}}subparse(t){var e=this.nextToken;this.consume(),this.gullet.pushToken(new i("}")),this.gullet.pushTokens(t);var n=this.parseExpression(!1);return this.expect("}"),this.nextToken=e,n}parseExpression(t,e){for(var n=[];;){"math"===this.mode&&this.consumeSpaces();var r=this.fetch();if(-1!==Kr.endOfExpression.indexOf(r.text))break;if(e&&r.text===e)break;if(t&&Mr[r.text]&&Mr[r.text].infix)break;var i=this.parseAtom(e);if(!i)break;"internal"!==i.type&&n.push(i)}return"text"===this.mode&&this.formLigatures(n),this.handleInfixNodes(n)}handleInfixNodes(t){for(var e,n=-1,r=0;r=0&&this.settings.reportNonstrict("unicodeTextInMathMode",'Latin-1/Unicode text character "'+e[0]+'" used in math mode',t);var l,c=ht[this.mode][e].group,h=r.range(t);if(lt.hasOwnProperty(c)){var u=c;l={type:"atom",mode:this.mode,family:u,loc:h,text:e}}else l={type:c,mode:this.mode,loc:h,text:e};s=l}else{if(!(e.charCodeAt(0)>=128))return null;this.settings.strict&&(N(e.charCodeAt(0))?"math"===this.mode&&this.settings.reportNonstrict("unicodeTextInMathMode",'Unicode text character "'+e[0]+'" used in math mode',t):this.settings.reportNonstrict("unknownSymbol",'Unrecognized Unicode character "'+e[0]+'" ('+e.charCodeAt(0)+")",t)),s={type:"textord",mode:"text",loc:r.range(t),text:e}}if(this.consume(),o)for(var d=0;d{"use strict";var r;n.d(e,{c:()=>a,o:()=>i}),(()=>{var t={470:t=>{function e(t){if("string"!=typeof t)throw new TypeError("Path must be a string. Received "+JSON.stringify(t))}function n(t,e){for(var n,r="",i=0,a=-1,s=0,o=0;o<=t.length;++o){if(o2){var l=r.lastIndexOf("/");if(l!==r.length-1){-1===l?(r="",i=0):i=(r=r.slice(0,l)).length-1-r.lastIndexOf("/"),a=o,s=0;continue}}else if(2===r.length||1===r.length){r="",i=0,a=o,s=0;continue}e&&(r.length>0?r+="/..":r="..",i=2)}else r.length>0?r+="/"+t.slice(a+1,o):r=t.slice(a+1,o),i=o-a-1;a=o,s=0}else 46===n&&-1!==s?++s:s=-1}return r}var r={resolve:function(){for(var t,r="",i=!1,a=arguments.length-1;a>=-1&&!i;a--){var s;a>=0?s=arguments[a]:(void 0===t&&(t=process.cwd()),s=t),e(s),0!==s.length&&(r=s+"/"+r,i=47===s.charCodeAt(0))}return r=n(r,!i),i?r.length>0?"/"+r:"/":r.length>0?r:"."},normalize:function(t){if(e(t),0===t.length)return".";var r=47===t.charCodeAt(0),i=47===t.charCodeAt(t.length-1);return 0!==(t=n(t,!r)).length||r||(t="."),t.length>0&&i&&(t+="/"),r?"/"+t:t},isAbsolute:function(t){return e(t),t.length>0&&47===t.charCodeAt(0)},join:function(){if(0===arguments.length)return".";for(var t,n=0;n0&&(void 0===t?t=i:t+="/"+i)}return void 0===t?".":r.normalize(t)},relative:function(t,n){if(e(t),e(n),t===n)return"";if((t=r.resolve(t))===(n=r.resolve(n)))return"";for(var i=1;ic){if(47===n.charCodeAt(o+u))return n.slice(o+u+1);if(0===u)return n.slice(o+u)}else s>c&&(47===t.charCodeAt(i+u)?h=u:0===u&&(h=0));break}var d=t.charCodeAt(i+u);if(d!==n.charCodeAt(o+u))break;47===d&&(h=u)}var p="";for(u=i+h+1;u<=a;++u)u!==a&&47!==t.charCodeAt(u)||(0===p.length?p+="..":p+="/..");return p.length>0?p+n.slice(o+h):(o+=h,47===n.charCodeAt(o)&&++o,n.slice(o))},_makeLong:function(t){return t},dirname:function(t){if(e(t),0===t.length)return".";for(var n=t.charCodeAt(0),r=47===n,i=-1,a=!0,s=t.length-1;s>=1;--s)if(47===(n=t.charCodeAt(s))){if(!a){i=s;break}}else a=!1;return-1===i?r?"/":".":r&&1===i?"//":t.slice(0,i)},basename:function(t,n){if(void 0!==n&&"string"!=typeof n)throw new TypeError('"ext" argument must be a string');e(t);var r,i=0,a=-1,s=!0;if(void 0!==n&&n.length>0&&n.length<=t.length){if(n.length===t.length&&n===t)return"";var o=n.length-1,l=-1;for(r=t.length-1;r>=0;--r){var c=t.charCodeAt(r);if(47===c){if(!s){i=r+1;break}}else-1===l&&(s=!1,l=r+1),o>=0&&(c===n.charCodeAt(o)?-1==--o&&(a=r):(o=-1,a=l))}return i===a?a=l:-1===a&&(a=t.length),t.slice(i,a)}for(r=t.length-1;r>=0;--r)if(47===t.charCodeAt(r)){if(!s){i=r+1;break}}else-1===a&&(s=!1,a=r+1);return-1===a?"":t.slice(i,a)},extname:function(t){e(t);for(var n=-1,r=0,i=-1,a=!0,s=0,o=t.length-1;o>=0;--o){var l=t.charCodeAt(o);if(47!==l)-1===i&&(a=!1,i=o+1),46===l?-1===n?n=o:1!==s&&(s=1):-1!==n&&(s=-1);else if(!a){r=o+1;break}}return-1===n||-1===i||0===s||1===s&&n===i-1&&n===r+1?"":t.slice(n,i)},format:function(t){if(null===t||"object"!=typeof t)throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof t);return function(t,e){var n=e.dir||e.root,r=e.base||(e.name||"")+(e.ext||"");return n?n===e.root?n+r:n+"/"+r:r}(0,t)},parse:function(t){e(t);var n={root:"",dir:"",base:"",ext:"",name:""};if(0===t.length)return n;var r,i=t.charCodeAt(0),a=47===i;a?(n.root="/",r=1):r=0;for(var s=-1,o=0,l=-1,c=!0,h=t.length-1,u=0;h>=r;--h)if(47!==(i=t.charCodeAt(h)))-1===l&&(c=!1,l=h+1),46===i?-1===s?s=h:1!==u&&(u=1):-1!==s&&(u=-1);else if(!c){o=h+1;break}return-1===s||-1===l||0===u||1===u&&s===l-1&&s===o+1?-1!==l&&(n.base=n.name=0===o&&a?t.slice(1,l):t.slice(o,l)):(0===o&&a?(n.name=t.slice(1,s),n.base=t.slice(1,l)):(n.name=t.slice(o,s),n.base=t.slice(o,l)),n.ext=t.slice(s,l)),o>0?n.dir=t.slice(0,o-1):a&&(n.dir="/"),n},sep:"/",delimiter:":",win32:null,posix:null};r.posix=r,t.exports=r}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var a=e[r]={exports:{}};return t[r](a,a.exports,n),a.exports}n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var i={};(()=>{let t;if(n.r(i),n.d(i,{URI:()=>h,Utils:()=>_}),"object"==typeof process)t="win32"===process.platform;else if("object"==typeof navigator){let e=navigator.userAgent;t=e.indexOf("Windows")>=0}const e=/^\w[\w\d+.-]*$/,r=/^\//,a=/^\/\//;function s(t,n){if(!t.scheme&&n)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${t.authority}", path: "${t.path}", query: "${t.query}", fragment: "${t.fragment}"}`);if(t.scheme&&!e.test(t.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(t.path)if(t.authority){if(!r.test(t.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(a.test(t.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}const o="",l="/",c=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/;class h{static isUri(t){return t instanceof h||!!t&&"string"==typeof t.authority&&"string"==typeof t.fragment&&"string"==typeof t.path&&"string"==typeof t.query&&"string"==typeof t.scheme&&"string"==typeof t.fsPath&&"function"==typeof t.with&&"function"==typeof t.toString}scheme;authority;path;query;fragment;constructor(t,e,n,r,i,a=!1){"object"==typeof t?(this.scheme=t.scheme||o,this.authority=t.authority||o,this.path=t.path||o,this.query=t.query||o,this.fragment=t.fragment||o):(this.scheme=function(t,e){return t||e?t:"file"}(t,a),this.authority=e||o,this.path=function(t,e){switch(t){case"https":case"http":case"file":e?e[0]!==l&&(e=l+e):e=l}return e}(this.scheme,n||o),this.query=r||o,this.fragment=i||o,s(this,a))}get fsPath(){return m(this,!1)}with(t){if(!t)return this;let{scheme:e,authority:n,path:r,query:i,fragment:a}=t;return void 0===e?e=this.scheme:null===e&&(e=o),void 0===n?n=this.authority:null===n&&(n=o),void 0===r?r=this.path:null===r&&(r=o),void 0===i?i=this.query:null===i&&(i=o),void 0===a?a=this.fragment:null===a&&(a=o),e===this.scheme&&n===this.authority&&r===this.path&&i===this.query&&a===this.fragment?this:new d(e,n,r,i,a)}static parse(t,e=!1){const n=c.exec(t);return n?new d(n[2]||o,b(n[4]||o),b(n[5]||o),b(n[7]||o),b(n[9]||o),e):new d(o,o,o,o,o)}static file(e){let n=o;if(t&&(e=e.replace(/\\/g,l)),e[0]===l&&e[1]===l){const t=e.indexOf(l,2);-1===t?(n=e.substring(2),e=l):(n=e.substring(2,t),e=e.substring(t)||l)}return new d("file",n,e,o,o)}static from(t){const e=new d(t.scheme,t.authority,t.path,t.query,t.fragment);return s(e,!0),e}toString(t=!1){return y(this,t)}toJSON(){return this}static revive(t){if(t){if(t instanceof h)return t;{const e=new d(t);return e._formatted=t.external,e._fsPath=t._sep===u?t.fsPath:null,e}}return t}}const u=t?1:void 0;class d extends h{_formatted=null;_fsPath=null;get fsPath(){return this._fsPath||(this._fsPath=m(this,!1)),this._fsPath}toString(t=!1){return t?y(this,!0):(this._formatted||(this._formatted=y(this,!1)),this._formatted)}toJSON(){const t={$mid:1};return this._fsPath&&(t.fsPath=this._fsPath,t._sep=u),this._formatted&&(t.external=this._formatted),this.path&&(t.path=this.path),this.scheme&&(t.scheme=this.scheme),this.authority&&(t.authority=this.authority),this.query&&(t.query=this.query),this.fragment&&(t.fragment=this.fragment),t}}const p={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function g(t,e,n){let r,i=-1;for(let a=0;a=97&&s<=122||s>=65&&s<=90||s>=48&&s<=57||45===s||46===s||95===s||126===s||e&&47===s||n&&91===s||n&&93===s||n&&58===s)-1!==i&&(r+=encodeURIComponent(t.substring(i,a)),i=-1),void 0!==r&&(r+=t.charAt(a));else{void 0===r&&(r=t.substr(0,a));const e=p[s];void 0!==e?(-1!==i&&(r+=encodeURIComponent(t.substring(i,a)),i=-1),r+=e):-1===i&&(i=a)}}return-1!==i&&(r+=encodeURIComponent(t.substring(i))),void 0!==r?r:t}function f(t){let e;for(let n=0;n1&&"file"===e.scheme?`//${e.authority}${e.path}`:47===e.path.charCodeAt(0)&&(e.path.charCodeAt(1)>=65&&e.path.charCodeAt(1)<=90||e.path.charCodeAt(1)>=97&&e.path.charCodeAt(1)<=122)&&58===e.path.charCodeAt(2)?n?e.path.substr(1):e.path[1].toLowerCase()+e.path.substr(2):e.path,t&&(r=r.replace(/\//g,"\\")),r}function y(t,e){const n=e?f:g;let r="",{scheme:i,authority:a,path:s,query:o,fragment:c}=t;if(i&&(r+=i,r+=":"),(a||"file"===i)&&(r+=l,r+=l),a){let t=a.indexOf("@");if(-1!==t){const e=a.substr(0,t);a=a.substr(t+1),t=e.lastIndexOf(":"),-1===t?r+=n(e,!1,!1):(r+=n(e.substr(0,t),!1,!1),r+=":",r+=n(e.substr(t+1),!1,!0)),r+="@"}a=a.toLowerCase(),t=a.lastIndexOf(":"),-1===t?r+=n(a,!1,!0):(r+=n(a.substr(0,t),!1,!0),r+=a.substr(t))}if(s){if(s.length>=3&&47===s.charCodeAt(0)&&58===s.charCodeAt(2)){const t=s.charCodeAt(1);t>=65&&t<=90&&(s=`/${String.fromCharCode(t+32)}:${s.substr(3)}`)}else if(s.length>=2&&58===s.charCodeAt(1)){const t=s.charCodeAt(0);t>=65&&t<=90&&(s=`${String.fromCharCode(t+32)}:${s.substr(2)}`)}r+=n(s,!0,!1)}return o&&(r+="?",r+=n(o,!1,!1)),c&&(r+="#",r+=e?c:g(c,!1,!1)),r}function v(t){try{return decodeURIComponent(t)}catch{return t.length>3?t.substr(0,3)+v(t.substr(3)):t}}const x=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function b(t){return t.match(x)?t.replace(x,(t=>v(t))):t}var w=n(470);const k=w.posix||w,T="/";var _;!function(t){t.joinPath=function(t,...e){return t.with({path:k.join(t.path,...e)})},t.resolvePath=function(t,...e){let n=t.path,r=!1;n[0]!==T&&(n=T+n,r=!0);let i=k.resolve(n,...e);return r&&i[0]===T&&!t.authority&&(i=i.substring(1)),t.with({path:i})},t.dirname=function(t){if(0===t.path.length||t.path===T)return t;let e=k.dirname(t.path);return 1===e.length&&46===e.charCodeAt(0)&&(e=""),t.with({path:e})},t.basename=function(t){return k.basename(t.path)},t.extname=function(t){return k.extname(t.path)}}(_||(_={}))})(),r=i})();const{URI:i,Utils:a}=r}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var a=e[r]={exports:{}};return t[r].call(a.exports,a,a.exports,n),a.exports}n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var r={};(()=>{"use strict";n.r(r),n.d(r,{default:()=>Ue});var t=n(9241),e=n(8337),i=(n(1566),n(5179),n(3583),n(1426),n(6241)),a=(n(214),n(7946)),s=n(2926),o=n(5430),l=n(4082),c=n(8464),h=n(3108),u="comm",d="rule",p="decl",g=Math.abs,f=String.fromCharCode;function m(t){return t.trim()}function y(t,e,n){return t.replace(e,n)}function v(t,e,n){return t.indexOf(e,n)}function x(t,e){return 0|t.charCodeAt(e)}function b(t,e,n){return t.slice(e,n)}function w(t){return t.length}function k(t,e){return e.push(t),t}function T(t,e){for(var n="",r=0;r0?x(M,--A):0,S--,10===L&&(S=1,E--),L}function R(){return L=A2||$(L)>3?"":" "}function W(t,e){for(;--e&&R()&&!(L<48||L>102||L>57&&L<65||L>70&&L<97););return P(t,O()+(e<6&&32==D()&&32==R()))}function z(t){for(;R();)switch(L){case t:return A;case 34:case 39:34!==t&&39!==t&&z(L);break;case 40:41===t&&z(t);break;case 92:R()}return A}function Z(t,e){for(;R()&&t+L!==57&&(t+L!==84||47!==D()););return"/*"+P(e,A-1)+"*"+f(47===t?t:R())}function Y(t){for(;!$(D());)R();return P(t,A)}function U(t){return function(t){return M="",t}(G("",null,null,null,[""],t=function(t){return E=S=1,C=w(M=t),A=0,[]}(t),0,[0],t))}function G(t,e,n,r,i,a,s,o,l){for(var c=0,h=0,u=s,d=0,p=0,m=0,T=1,_=1,E=1,S=0,C="",A=i,L=a,M=r,N=C;_;)switch(m=S,S=R()){case 40:if(108!=m&&58==x(N,u-1)){-1!=v(N+=y(B(S),"&","&\f"),"&\f",g(c?o[c-1]:0))&&(E=-1);break}case 34:case 39:case 91:N+=B(S);break;case 9:case 10:case 13:case 32:N+=F(m);break;case 92:N+=W(O()-1,7);continue;case 47:switch(D()){case 42:case 47:k(q(Z(R(),O()),e,n,l),l),5!=$(m||1)&&5!=$(D()||1)||!w(N)||" "===b(N,-1,void 0)||(N+=" ");break;default:N+="/"}break;case 123*T:o[c++]=w(N)*E;case 125*T:case 59:case 0:switch(S){case 0:case 125:_=0;case 59+h:-1==E&&(N=y(N,/\f/g,"")),p>0&&(w(N)-u||0===T&&47===m)&&k(p>32?j(N+";",r,n,u-1,l):j(y(N," ","")+";",r,n,u-2,l),l);break;case 59:N+=";";default:if(k(M=V(N,e,n,c,h,i,o,C,A=[],L=[],u,a),a),123===S)if(0===h)G(N,e,M,M,A,a,u,o,L);else{switch(d){case 99:if(110===x(N,3))break;case 108:if(97===x(N,2))break;default:h=0;case 100:case 109:case 115:}h?G(t,M,M,r&&k(V(t,M,M,0,0,i,o,C,i,A=[],u,L),L),i,L,u,o,r?A:L):G(N,M,M,M,[""],L,0,o,L)}}c=h=p=0,T=E=1,C=N="",u=s;break;case 58:u=1+w(N),p=m;default:if(T<1)if(123==S)--T;else if(125==S&&0==T++&&125==I())continue;switch(N+=f(S),S*T){case 38:E=h>0?1:(N+="\f",-1);break;case 44:o[c++]=(w(N)-1)*E,E=1;break;case 64:45===D()&&(N+=B(R())),d=D(),h=u=w(C=N+=Y(O())),S++;break;case 45:45===m&&2==w(N)&&(T=0)}}return a}function V(t,e,n,r,i,a,s,o,l,c,h,u){for(var p=i-1,f=0===i?a:[""],v=function(t){return t.length}(f),x=0,w=0,k=0;x0?f[T]+" "+_:y(_,/&\f/g,f[T])))&&(l[k++]=E);return N(t,e,n,0===i?d:o,l,c,h,u)}function q(t,e,n,r){return N(t,e,n,u,f(L),b(t,2,-2),0,r)}function j(t,e,n,r,i){return N(t,e,n,p,b(t,0,r),b(t,r+1,-1),r,i)}var H=n(2424),X=n(9697),K={id:"c4",detector:(0,l.eW)((t=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,8931));return{id:"c4",diagram:t}}),"loader")},Q="flowchart",J={id:Q,detector:(0,l.eW)(((t,e)=>"dagre-wrapper"!==e?.flowchart?.defaultRenderer&&"elk"!==e?.flowchart?.defaultRenderer&&/^\s*graph/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,9389));return{id:Q,diagram:t}}),"loader")},tt="flowchart-v2",et={id:tt,detector:(0,l.eW)(((t,e)=>"dagre-d3"!==e?.flowchart?.defaultRenderer&&("elk"===e?.flowchart?.defaultRenderer&&(e.layout="elk"),!(!/^\s*graph/.test(t)||"dagre-wrapper"!==e?.flowchart?.defaultRenderer)||/^\s*flowchart/.test(t))),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,9389));return{id:tt,diagram:t}}),"loader")},nt={id:"er",detector:(0,l.eW)((t=>/^\s*erDiagram/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,9640));return{id:"er",diagram:t}}),"loader")},rt="gitGraph",it={id:rt,detector:(0,l.eW)((t=>/^\s*gitGraph/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,4290));return{id:rt,diagram:t}}),"loader")},at="gantt",st={id:at,detector:(0,l.eW)((t=>/^\s*gantt/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,4748));return{id:at,diagram:t}}),"loader")},ot="info",lt={id:ot,detector:(0,l.eW)((t=>/^\s*info/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,3997));return{id:ot,diagram:t}}),"loader")},ct={id:"pie",detector:(0,l.eW)((t=>/^\s*pie/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,8661));return{id:"pie",diagram:t}}),"loader")},ht="quadrantChart",ut={id:ht,detector:(0,l.eW)((t=>/^\s*quadrantChart/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,3661));return{id:ht,diagram:t}}),"loader")},dt="xychart",pt={id:dt,detector:(0,l.eW)((t=>/^\s*xychart-beta/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,5587));return{id:dt,diagram:t}}),"loader")},gt="requirement",ft={id:gt,detector:(0,l.eW)((t=>/^\s*requirement(Diagram)?/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,9816));return{id:gt,diagram:t}}),"loader")},mt="sequence",yt={id:mt,detector:(0,l.eW)((t=>/^\s*sequenceDiagram/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,4438));return{id:mt,diagram:t}}),"loader")},vt="class",xt={id:vt,detector:(0,l.eW)(((t,e)=>"dagre-wrapper"!==e?.class?.defaultRenderer&&/^\s*classDiagram/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,5635));return{id:vt,diagram:t}}),"loader")},bt="classDiagram",wt={id:bt,detector:(0,l.eW)(((t,e)=>!(!/^\s*classDiagram/.test(t)||"dagre-wrapper"!==e?.class?.defaultRenderer)||/^\s*classDiagram-v2/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,9876));return{id:bt,diagram:t}}),"loader")},kt="state",Tt={id:kt,detector:(0,l.eW)(((t,e)=>"dagre-wrapper"!==e?.state?.defaultRenderer&&/^\s*stateDiagram/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,952));return{id:kt,diagram:t}}),"loader")},_t="stateDiagram",Et={id:_t,detector:(0,l.eW)(((t,e)=>!!/^\s*stateDiagram-v2/.test(t)||!(!/^\s*stateDiagram/.test(t)||"dagre-wrapper"!==e?.state?.defaultRenderer)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,8710));return{id:_t,diagram:t}}),"loader")},St="journey",Ct={id:St,detector:(0,l.eW)((t=>/^\s*journey/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,8891));return{id:St,diagram:t}}),"loader")},At={draw:(0,l.eW)(((t,e,n)=>{l.cM.debug("rendering svg for syntax error\n");const r=(0,o.P)(e),i=r.append("g");r.attr("viewBox","0 0 2412 512"),(0,l.v2)(r,100,512,!0),i.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),i.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),i.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),i.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),i.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),i.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),i.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),i.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${n}`)}),"draw")},Lt=At,Mt={db:{},renderer:At,parser:{parse:(0,l.eW)((()=>{}),"parse")}},Nt="flowchart-elk",It={id:Nt,detector:(0,l.eW)(((t,e={})=>!!(/^\s*flowchart-elk/.test(t)||/^\s*flowchart|graph/.test(t)&&"elk"===e?.flowchart?.defaultRenderer)&&(e.layout="elk",!0)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,9389));return{id:Nt,diagram:t}}),"loader")},Rt="timeline",Dt={id:Rt,detector:(0,l.eW)((t=>/^\s*timeline/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,2270));return{id:Rt,diagram:t}}),"loader")},Ot="mindmap",Pt={id:Ot,detector:(0,l.eW)((t=>/^\s*mindmap/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,9002));return{id:Ot,diagram:t}}),"loader")},$t="kanban",Bt={id:$t,detector:(0,l.eW)((t=>/^\s*kanban/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,7744));return{id:$t,diagram:t}}),"loader")},Ft="sankey",Wt={id:Ft,detector:(0,l.eW)((t=>/^\s*sankey-beta/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,7096));return{id:Ft,diagram:t}}),"loader")},zt="packet",Zt={id:zt,detector:(0,l.eW)((t=>/^\s*packet-beta/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,4628));return{id:zt,diagram:t}}),"loader")},Yt="radar",Ut={id:Yt,detector:(0,l.eW)((t=>/^\s*radar-beta/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,6672));return{id:Yt,diagram:t}}),"loader")},Gt="block",Vt={id:Gt,detector:(0,l.eW)((t=>/^\s*block-beta/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,7724));return{id:Gt,diagram:t}}),"loader")},qt="architecture",jt={id:qt,detector:(0,l.eW)((t=>/^\s*architecture/.test(t)),"detector"),loader:(0,l.eW)((async()=>{const{diagram:t}=await Promise.resolve().then(n.bind(n,8545));return{id:qt,diagram:t}}),"loader")},Ht=!1,Xt=(0,l.eW)((()=>{Ht||(Ht=!0,(0,l.Cq)("error",Mt,(t=>"error"===t.toLowerCase().trim())),(0,l.Cq)("---",{db:{clear:(0,l.eW)((()=>{}),"clear")},styles:{},renderer:{draw:(0,l.eW)((()=>{}),"draw")},parser:{parse:(0,l.eW)((()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")}),"parse")},init:(0,l.eW)((()=>null),"init")},(t=>t.toLowerCase().trimStart().startsWith("---"))),(0,l.KO)(K,Bt,wt,xt,nt,st,lt,ct,ft,yt,It,et,J,Pt,Dt,it,Et,Tt,Ct,ut,Wt,Zt,pt,Vt,jt,Ut))}),"addDiagrams"),Kt=(0,l.eW)((async()=>{l.cM.debug("Loading registered diagrams");const t=(await Promise.allSettled(Object.entries(l.Bf).map((async([t,{detector:e,loader:n}])=>{if(n)try{(0,l._7)(t)}catch{try{const{diagram:t,id:r}=await n();(0,l.Cq)(r,t,e)}catch(e){throw l.cM.error(`Failed to load external diagram with key ${t}. Removing from detectors.`),delete l.Bf[t],e}}})))).filter((t=>"rejected"===t.status));if(t.length>0){l.cM.error(`Failed to load ${t.length} external diagrams`);for(const e of t)l.cM.error(e);throw new Error(`Failed to load ${t.length} external diagrams`)}}),"loadRegisteredDiagrams"),Qt="graphics-document document";function Jt(t,e){t.attr("role",Qt),""!==e&&t.attr("aria-roledescription",e)}function te(t,e,n,r){if(void 0!==t.insert){if(n){const e=`chart-desc-${r}`;t.attr("aria-describedby",e),t.insert("desc",":first-child").attr("id",e).text(n)}if(e){const n=`chart-title-${r}`;t.attr("aria-labelledby",n),t.insert("title",":first-child").attr("id",n).text(e)}}}(0,l.eW)(Jt,"setA11yDiagramInfo"),(0,l.eW)(te,"addSVGa11yTitleDescription");var ee=class t{constructor(t,e,n,r,i){this.type=t,this.text=e,this.db=n,this.parser=r,this.renderer=i}static{(0,l.eW)(this,"Diagram")}static async fromText(e,n={}){const r=(0,l.iE)(),i=(0,l.Vg)(e,r);e=(0,a.Vy)(e)+"\n";try{(0,l._7)(i)}catch{const t=(0,l.cq)(i);if(!t)throw new l.cj(`Diagram ${i} not found.`);const{id:e,diagram:n}=await t();(0,l.Cq)(e,n)}const{db:s,parser:o,renderer:c,init:h}=(0,l._7)(i);return o.parser&&(o.parser.yy=s),s.clear?.(),h?.(r),n.title&&s.setDiagramTitle?.(n.title),await o.parse(e),new t(i,e,s,o,c)}async render(t,e){await this.renderer.draw(this.text,t,e,this)}getParser(){return this.parser}getType(){return this.type}},ne=[],re=(0,l.eW)((()=>{ne.forEach((t=>{t()})),ne=[]}),"attachFunctions"),ie=(0,l.eW)((t=>t.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart()),"cleanupComments");function ae(e){const n=e.match(l.M6);if(!n)return{text:e,metadata:{}};let r=(0,t.z)(n[1],{schema:t.A})??{};r="object"!=typeof r||Array.isArray(r)?{}:r;const i={};return r.displayMode&&(i.displayMode=r.displayMode.toString()),r.title&&(i.title=r.title.toString()),r.config&&(i.config=r.config),{text:e.slice(n[0].length),metadata:i}}(0,l.eW)(ae,"extractFrontMatter");var se=(0,l.eW)((t=>t.replace(/\r\n?/g,"\n").replace(/<(\w+)([^>]*)>/g,((t,e,n)=>"<"+e+n.replace(/="([^"]*)"/g,"='$1'")+">"))),"cleanupText"),oe=(0,l.eW)((t=>{const{text:e,metadata:n}=ae(t),{displayMode:r,title:i,config:a={}}=n;return r&&(a.gantt||(a.gantt={}),a.gantt.displayMode=r),{title:i,config:a,text:e}}),"processFrontmatter"),le=(0,l.eW)((t=>{const e=a.w8.detectInit(t)??{},n=a.w8.detectDirective(t,"wrap");return Array.isArray(n)?e.wrap=n.some((({type:t})=>"wrap"===t)):"wrap"===n?.type&&(e.wrap=!0),{text:(0,a.tf)(t),directive:e}}),"processDirectives");function ce(t){const e=se(t),n=oe(e),r=le(n.text),i=(0,a.Rb)(n.config,r.directive);return{code:t=ie(r.text),title:n.title,config:i}}function he(t){const e=(new TextEncoder).encode(t),n=Array.from(e,(t=>String.fromCodePoint(t))).join("");return btoa(n)}(0,l.eW)(ce,"preprocessDiagram"),(0,l.eW)(he,"toBase64");var ue=["foreignobject"],de=["dominant-baseline"];function pe(t){const e=ce(t);return(0,l.mc)(),(0,l.XV)(e.config??{}),e}async function ge(t,e){Xt();try{const{code:e,config:n}=pe(t);return{diagramType:(await Ee(e)).type,config:n}}catch(t){if(e?.suppressErrors)return!1;throw t}}(0,l.eW)(pe,"processAndSetConfigs"),(0,l.eW)(ge,"parse");var fe=(0,l.eW)(((t,e,n=[])=>`\n.${t} ${e} { ${n.join(" !important; ")} !important; }`),"cssImportantStyles"),me=(0,l.eW)(((t,e=new Map)=>{let n="";if(void 0!==t.themeCSS&&(n+=`\n${t.themeCSS}`),void 0!==t.fontFamily&&(n+=`\n:root { --mermaid-font-family: ${t.fontFamily}}`),void 0!==t.altFontFamily&&(n+=`\n:root { --mermaid-alt-font-family: ${t.altFontFamily}}`),e instanceof Map){const r=t.htmlLabels??t.flowchart?.htmlLabels?["> *","span"]:["rect","polygon","ellipse","circle","path"];e.forEach((t=>{(0,X.Z)(t.styles)||r.forEach((e=>{n+=fe(t.id,e,t.styles)})),(0,X.Z)(t.textStyles)||(n+=fe(t.id,"tspan",(t?.textStyles||[]).map((t=>t.replace("color","fill")))))}))}return n}),"createCssStyles"),ye=(0,l.eW)(((t,e,n,r)=>{const i=me(t,n);return T(U(`${r}{${(0,l.Ee)(e,i,t.themeVariables)}}`),_)}),"createUserStyles"),ve=(0,l.eW)(((t="",e,n)=>{let r=t;return n||e||(r=r.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),r=(0,a.SH)(r),r=r.replace(/
    /g,"
    "),r}),"cleanUpSvgCode"),xe=(0,l.eW)(((t="",e)=>``),"putIntoIFrame"),be=(0,l.eW)(((t,e,n,r,i)=>{const a=t.append("div");a.attr("id",n),r&&a.attr("style",r);const s=a.append("svg").attr("id",e).attr("width","100%").attr("xmlns","http://www.w3.org/2000/svg");return i&&s.attr("xmlns:xlink",i),s.append("g"),t}),"appendDivSvgG");function we(t,e){return t.append("iframe").attr("id",e).attr("style","width: 100%; height: 100%;").attr("sandbox","")}(0,l.eW)(we,"sandboxedIframe");var ke=(0,l.eW)(((t,e,n,r)=>{t.getElementById(e)?.remove(),t.getElementById(n)?.remove(),t.getElementById(r)?.remove()}),"removeExistingElements"),Te=(0,l.eW)((async function(t,e,n){Xt();const r=pe(e);e=r.code;const i=(0,l.iE)();l.cM.debug(i),e.length>(i?.maxTextSize??5e4)&&(e="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa");const a="#"+t,o="i"+t,c="#"+o,u="d"+t,d="#"+u,p=(0,l.eW)((()=>{const t=f?c:d,e=(0,h.Ys)(t).node();e&&"remove"in e&&e.remove()}),"removeTempElements");let g=(0,h.Ys)("body");const f="sandbox"===i.securityLevel,m="loose"===i.securityLevel,y=i.fontFamily;if(void 0!==n){if(n&&(n.innerHTML=""),f){const t=we((0,h.Ys)(n),o);g=(0,h.Ys)(t.nodes()[0].contentDocument.body),g.node().style.margin=0}else g=(0,h.Ys)(n);be(g,t,u,`font-family: ${y}`,"http://www.w3.org/1999/xlink")}else{if(ke(document,t,u,o),f){const t=we((0,h.Ys)("body"),o);g=(0,h.Ys)(t.nodes()[0].contentDocument.body),g.node().style.margin=0}else g=(0,h.Ys)("body");be(g,t,u)}let v,x;try{v=await ee.fromText(e,{title:r.title})}catch(t){if(i.suppressErrorRendering)throw p(),t;v=await ee.fromText("error"),x=t}const b=g.select(d).node(),w=v.type,k=b.firstChild,T=k.firstChild,_=v.renderer.getClasses?.(e,v),E=ye(i,w,_,a),S=document.createElement("style");S.innerHTML=E,k.insertBefore(S,T);try{await v.renderer.draw(e,t,s.X.version,v)}catch(n){throw i.suppressErrorRendering?p():Lt.draw(e,t,s.X.version),n}const C=g.select(`${d} svg`),A=v.db.getAccTitle?.(),L=v.db.getAccDescription?.();Se(w,C,A,L),g.select(`[id="${t}"]`).selectAll("foreignobject > *").attr("xmlns","http://www.w3.org/1999/xhtml");let M=g.select(d).node().innerHTML;if(l.cM.debug("config.arrowMarkerAbsolute",i.arrowMarkerAbsolute),M=ve(M,f,(0,l.ku)(i.arrowMarkerAbsolute)),f){const t=g.select(d+" svg").node();M=xe(M,t)}else m||(M=H.Z.sanitize(M,{ADD_TAGS:ue,ADD_ATTR:de,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));if(re(),x)throw x;return p(),{diagramType:w,svg:M,bindFunctions:v.db.bindFunctions}}),"render");function _e(t={}){const e=(0,l.Yc)({},t);e?.fontFamily&&!e.themeVariables?.fontFamily&&(e.themeVariables||(e.themeVariables={}),e.themeVariables.fontFamily=e.fontFamily),(0,l.dY)(e),e?.theme&&e.theme in l._j?e.themeVariables=l._j[e.theme].getThemeVariables(e.themeVariables):e&&(e.themeVariables=l._j.default.getThemeVariables(e.themeVariables));const n="object"==typeof e?(0,l.Yn)(e):(0,l.ZD)();(0,l.Ub)(n.logLevel),Xt()}(0,l.eW)(_e,"initialize");var Ee=(0,l.eW)(((t,e={})=>{const{code:n}=ce(t);return ee.fromText(n,e)}),"getDiagramFromText");function Se(t,e,n,r){Jt(e,t),te(e,n,r,e.attr("id"))}(0,l.eW)(Se,"addA11yInfo");var Ce=Object.freeze({render:Te,parse:ge,getDiagramFromText:Ee,initialize:_e,getConfig:l.iE,setConfig:l.v6,getSiteConfig:l.ZD,updateSiteConfig:l.Tb,reset:(0,l.eW)((()=>{(0,l.mc)()}),"reset"),globalReset:(0,l.eW)((()=>{(0,l.mc)(l.u_)}),"globalReset"),defaultConfig:l.u_});(0,l.Ub)((0,l.iE)().logLevel),(0,l.mc)((0,l.iE)());var Ae=(0,l.eW)(((t,e,n)=>{l.cM.warn(t),(0,a.bZ)(t)?(n&&n(t.str,t.hash),e.push({...t,message:t.str,error:t})):(n&&n(t),t instanceof Error&&e.push({str:t.message,message:t.message,hash:t.name,error:t}))}),"handleError"),Le=(0,l.eW)((async function(t={querySelector:".mermaid"}){try{await Me(t)}catch(e){if((0,a.bZ)(e)&&l.cM.error(e.str),ze.parseError&&ze.parseError(e),!t.suppressErrors)throw l.cM.error("Use the suppressErrors option to suppress these errors"),e}}),"run"),Me=(0,l.eW)((async function({postRenderCallback:t,querySelector:e,nodes:n}={querySelector:".mermaid"}){const r=Ce.getConfig();let i;if(l.cM.debug((t?"":"No ")+"Callback function found"),n)i=n;else{if(!e)throw new Error("Nodes and querySelector are both undefined");i=document.querySelectorAll(e)}l.cM.debug(`Found ${i.length} diagrams`),void 0!==r?.startOnLoad&&(l.cM.debug("Start On Load: "+r?.startOnLoad),Ce.updateSiteConfig({startOnLoad:r?.startOnLoad}));const s=new a.w8.InitIDGenerator(r.deterministicIds,r.deterministicIDSeed);let o;const h=[];for(const e of Array.from(i)){if(l.cM.info("Rendering diagram: "+e.id),e.getAttribute("data-processed"))continue;e.setAttribute("data-processed","true");const n=`mermaid-${s.next()}`;o=e.innerHTML,o=(0,c.Z)(a.w8.entityDecode(o)).trim().replace(//gi,"
    ");const r=a.w8.detectInit(o);r&&l.cM.debug("Detected early reinit: ",r);try{const{svg:r,bindFunctions:i}=await We(n,o,e);e.innerHTML=r,t&&await t(n),i&&i(e)}catch(t){Ae(t,h,ze.parseError)}}if(h.length>0)throw h[0]}),"runThrowsErrors"),Ne=(0,l.eW)((function(t){Ce.initialize(t)}),"initialize"),Ie=(0,l.eW)((async function(t,e,n){l.cM.warn("mermaid.init is deprecated. Please use run instead."),t&&Ne(t);const r={postRenderCallback:n,querySelector:".mermaid"};"string"==typeof e?r.querySelector=e:e&&(e instanceof HTMLElement?r.nodes=[e]:r.nodes=e),await Le(r)}),"init"),Re=(0,l.eW)((async(t,{lazyLoad:e=!0}={})=>{Xt(),(0,l.KO)(...t),!1===e&&await Kt()}),"registerExternalDiagrams"),De=(0,l.eW)((function(){if(ze.startOnLoad){const{startOnLoad:t}=Ce.getConfig();t&&ze.run().catch((t=>l.cM.error("Mermaid failed to initialize",t)))}}),"contentLoaded");"undefined"!=typeof document&&window.addEventListener("load",De,!1);var Oe=(0,l.eW)((function(t){ze.parseError=t}),"setParseErrorHandler"),Pe=[],$e=!1,Be=(0,l.eW)((async()=>{if(!$e){for($e=!0;Pe.length>0;){const t=Pe.shift();if(t)try{await t()}catch(t){l.cM.error("Error executing queue",t)}}$e=!1}}),"executeQueue"),Fe=(0,l.eW)((async(t,e)=>new Promise(((n,r)=>{const i=(0,l.eW)((()=>new Promise(((i,a)=>{Ce.parse(t,e).then((t=>{i(t),n(t)}),(t=>{l.cM.error("Error parsing",t),ze.parseError?.(t),a(t),r(t)}))}))),"performCall");Pe.push(i),Be().catch(r)}))),"parse"),We=(0,l.eW)(((t,e,n)=>new Promise(((r,i)=>{const a=(0,l.eW)((()=>new Promise(((a,s)=>{Ce.render(t,e,n).then((t=>{a(t),r(t)}),(t=>{l.cM.error("Error parsing",t),ze.parseError?.(t),s(t),i(t)}))}))),"performCall");Pe.push(a),Be().catch(i)}))),"render"),ze={startOnLoad:!0,mermaidAPI:Ce,parse:Fe,render:We,init:Ie,run:Le,registerExternalDiagrams:Re,registerLayoutLoaders:e.jM,initialize:Ne,parseError:void 0,contentLoaded:De,setParseErrorHandler:Oe,detectType:l.Vg,registerIconPacks:i.ef},Ze=ze;function Ye(t){var e=t.querySelectorAll(".mermaid");Ze.init({},e),e.forEach((function(t){return t.classList.add("content-center")}))}const Ue={initMermaid:function(){Ye(document),document.querySelectorAll(".pluggable").forEach((function(t){return t.addEventListener("onPluginReady",(function(){Ye(t)}))}))}}})(),window.__DOCS_MERMAID__=r})(); \ No newline at end of file diff --git a/resources/js/prism.js b/resources/js/prism.js new file mode 100644 index 00000000..d8e5d1b3 --- /dev/null +++ b/resources/js/prism.js @@ -0,0 +1,5 @@ +/*! Retype v3.11.0 | retype.com | Copyright 2025. Retype, Inc. All rights reserved. */ + +window.Prism=window.Prism||{manual:true}; +/*! For license information please see prism.js.LICENSE.txt */ +(()=>{var e={7193:()=>{"undefined"!=typeof Prism&&Prism.hooks.add("wrap",(function(e){"keyword"===e.type&&e.classes.push("keyword-"+e.content)}))},5660:(e,t,n)=>{var a=function(e){var t=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,n=0,a={},r={manual:e.Prism&&e.Prism.manual,disableWorkerMessageHandler:e.Prism&&e.Prism.disableWorkerMessageHandler,util:{encode:function e(t){return t instanceof i?new i(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,"&").replace(/=g.reach);w+=k.value.length,k=k.next){var A=k.value;if(t.length>e.length)return;if(!(A instanceof i)){var S,$=1;if(y){if(!(S=s(F,w,e,v))||S.index>=e.length)break;var E=S.index,_=S.index+S[0].length,j=w;for(j+=k.value.length;E>=j;)j+=(k=k.next).value.length;if(w=j-=k.value.length,k.value instanceof i)continue;for(var P=k;P!==t.tail&&(j<_||"string"==typeof P.value);P=P.next)$++,j+=P.value.length;$--,A=e.slice(w,j),S.index-=w}else if(!(S=s(F,0,A,v)))continue;E=S.index;var C=S[0],T=A.slice(0,E),O=A.slice(E+C.length),L=w+A.length;g&&L>g.reach&&(g.reach=L);var z=k.prev;if(T&&(z=u(t,z,T),w+=T.length),c(t,z,$),k=u(t,z,new i(d,m?r.tokenize(C,m):C,b,C)),O&&u(t,k,O),$>1){var M={cause:d+","+h,reach:L};o(e,t,n,k.prev,w,M),g&&M.reach>g.reach&&(g.reach=M.reach)}}}}}}function l(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function u(e,t,n){var a=t.next,r={value:n,prev:t,next:a};return t.next=r,a.prev=r,e.length++,r}function c(e,t,n){for(var a=t.next,r=0;r"+i.content+""},!e.document)return e.addEventListener?(r.disableWorkerMessageHandler||e.addEventListener("message",(function(t){var n=JSON.parse(t.data),a=n.language,i=n.code,s=n.immediateClose;e.postMessage(r.highlight(i,r.languages[a],a)),s&&e.close()}),!1),r):r;var g=r.util.currentScript();function d(){r.manual||r.highlightAll()}if(g&&(r.filename=g.src,g.hasAttribute("data-manual")&&(r.manual=!0)),!r.manual){var p=document.readyState;"loading"===p||"interactive"===p&&g&&g.defer?document.addEventListener("DOMContentLoaded",d):window.requestAnimationFrame?window.requestAnimationFrame(d):window.setTimeout(d,16)}return r}("undefined"!=typeof window?window:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:{});e.exports&&(e.exports=a),void 0!==n.g&&(n.g.Prism=a),a.languages.markup={comment:{pattern://,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern://i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},a.languages.markup.tag.inside["attr-value"].inside.entity=a.languages.markup.entity,a.languages.markup.doctype.inside["internal-subset"].inside=a.languages.markup,a.hooks.add("wrap",(function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&/,"&"))})),Object.defineProperty(a.languages.markup.tag,"addInlined",{value:function(e,t){var n={};n["language-"+t]={pattern:/(^$)/i,lookbehind:!0,inside:a.languages[t]},n.cdata=/^$/i;var r={"included-cdata":{pattern://i,inside:n}};r["language-"+t]={pattern:/[\s\S]+/,inside:a.languages[t]};var i={};i[e]={pattern:RegExp(/(<__[^>]*>)(?:))*\]\]>|(?!)/.source.replace(/__/g,(function(){return e})),"i"),lookbehind:!0,greedy:!0,inside:r},a.languages.insertBefore("markup","cdata",i)}}),Object.defineProperty(a.languages.markup.tag,"addAttribute",{value:function(e,t){a.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[t,"language-"+t],inside:a.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),a.languages.html=a.languages.markup,a.languages.mathml=a.languages.markup,a.languages.svg=a.languages.markup,a.languages.xml=a.languages.extend("markup",{}),a.languages.ssml=a.languages.xml,a.languages.atom=a.languages.xml,a.languages.rss=a.languages.xml,function(e){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+t.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+t.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+t.source+"$"),alias:"url"}}},selector:{pattern:RegExp("(^|[{}\\s])[^{}\\s](?:[^{};\"'\\s]|\\s+(?![\\s{])|"+t.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:t,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css;var n=e.languages.markup;n&&(n.tag.addInlined("style","css"),n.tag.addAttribute("style","css"))}(a),a.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},a.languages.javascript=a.languages.extend("clike",{"class-name":[a.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),a.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,a.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:a.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:a.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:a.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:a.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:a.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),a.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:a.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),a.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),a.languages.markup&&(a.languages.markup.tag.addInlined("script","javascript"),a.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),a.languages.js=a.languages.javascript,function(){if(void 0!==a&&"undefined"!=typeof document){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},t="data-src-status",n="loading",r="loaded",i="pre[data-src]:not(["+t+'="'+r+'"]):not(['+t+'="'+n+'"])';a.hooks.add("before-highlightall",(function(e){e.selector+=", "+i})),a.hooks.add("before-sanity-check",(function(s){var o=s.element;if(o.matches(i)){s.code="",o.setAttribute(t,n);var l=o.appendChild(document.createElement("CODE"));l.textContent="Loading…";var u=o.getAttribute("data-src"),c=s.language;if("none"===c){var g=(/\.(\w+)$/.exec(u)||[,"none"])[1];c=e[g]||g}a.util.setLanguage(l,c),a.util.setLanguage(o,c);var d=a.plugins.autoloader;d&&d.loadLanguages(c),function(e,n,i){var s=new XMLHttpRequest;s.open("GET",e,!0),s.onreadystatechange=function(){4==s.readyState&&(s.status<400&&s.responseText?function(e){o.setAttribute(t,r);var n=function(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||"");if(t){var n=Number(t[1]),a=t[2],r=t[3];return a?r?[n,Number(r)]:[n,void 0]:[n,n]}}(o.getAttribute("data-range"));if(n){var i=e.split(/\r\n?|\n/g),s=n[0],u=null==n[1]?i.length:n[1];s<0&&(s+=i.length),s=Math.max(0,Math.min(s-1,i.length)),u<0&&(u+=i.length),u=Math.max(0,Math.min(u,i.length)),e=i.slice(s,u).join("\n"),o.hasAttribute("data-start")||o.setAttribute("data-start",String(s+1))}l.textContent=e,a.highlightElement(l)}(s.responseText):s.status>=400?i("✖ Error "+s.status+" while fetching file: "+s.statusText):i("✖ Error: File does not exist or is empty"))},s.send(null)}(u,0,(function(e){o.setAttribute(t,"failed"),l.textContent=e}))}})),a.plugins.fileHighlight={highlight:function(e){for(var t,n=(e||document).querySelectorAll(i),r=0;t=n[r++];)a.highlightElement(t)}};var s=!1;a.fileHighlight=function(){s||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),s=!0),a.plugins.fileHighlight.highlight.apply(this,arguments)}}}()},2400:()=>{!function(){if("undefined"!=typeof Prism&&"undefined"!=typeof document&&document.querySelector){var e,t=function(){if(void 0===e){var t=document.createElement("div");t.style.fontSize="13px",t.style.lineHeight="1.5",t.style.padding="0",t.style.border="0",t.innerHTML=" 
     ",document.body.appendChild(t),e=38===t.offsetHeight,document.body.removeChild(t)}return e};Prism.hooks.add("before-sanity-check",(function(e){var t=e.element.parentElement;if(r(t)){var a=0;n(".line-highlight",t).forEach((function(e){a+=e.textContent.length,e.parentNode.removeChild(e)})),a&&/^(?: \n)+$/.test(e.code.slice(-a))&&(e.code=e.code.slice(0,-a))}})),Prism.hooks.add("complete",(function e(t){for(var n=t.element.parentElement;n&&/div/i.test(n.nodeName)&&n.className.indexOf("simplebar-")>=0;)n=n.parentElement;if(r(n)){var a=Prism.plugins.lineNumbers,s=t.plugins&&t.plugins.lineNumbers;"line-numbers",n.classList.contains("line-numbers")&&a&&!s?Prism.hooks.add("line-numbers",e):i(n)()}})),window.addEventListener("resize",(function(){n("pre").filter(r).map((function(e){return i(e)})).forEach(a)}))}function n(e,t){return Array.prototype.slice.call((t||document).querySelectorAll(e))}function a(e){e()}function r(e){return!(!e||!/pre/i.test(e.nodeName)||!e.hasAttribute("data-line"))}function i(e,n,r){var i=(n="string"==typeof n?n:e.getAttribute("data-line")||"").replace(/\s+/g,"").split(",").filter(Boolean),s=+e.getAttribute("data-line-offset")||0,o=(t()?parseInt:parseFloat)(getComputedStyle(e).lineHeight),l=e.querySelector("code"),u=e,c=[],g=l&&u!=l?function(e,t){var n=getComputedStyle(e),a=getComputedStyle(t);function r(e){return+e.substr(0,e.length-2)}return t.offsetTop+r(a.borderTopWidth)+r(a.paddingTop)-r(n.paddingTop)}(e,l):0;return i.forEach((function(t){var n=t.split("-"),a=+n[0],i=+n[1]||a,l=e.querySelector('.line-highlight[data-range="'+t+'"]')||document.createElement("div");c.push((function(){l.setAttribute("aria-hidden","true"),l.setAttribute("data-range",t),l.className=(r||"")+" line-highlight"})),c.push((function(){l.style.top=(a-s-1)*o+g+"px",l.textContent=new Array(i-a+2).join(" \n")})),c.push((function(){l.style.width=e.scrollWidth+"px"})),c.push((function(){u.appendChild(l)}))})),function(){c.forEach(a)}}}()}},t={};function n(a){var r=t[a];if(void 0!==r)return r.exports;var i=t[a]={exports:{}};return e[a](i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};(()=>{"use strict";n.r(a),n.d(a,{default:()=>r});var e=n(5660),t=n.n(e);n(7193),n(2400);const r={initPrism:function(){t().highlightAllUnder(document),document.querySelectorAll(".pluggable").forEach((function(e){return e.addEventListener("onPluginReady",(function(){setTimeout((function(){t().highlightAllUnder(e)}),10)}))}))}}})(),window.__DOCS_PRISM__=a})();Prism.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/};Prism.languages.c=Prism.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean;!function(e){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,n="\\b(?!)\\w+(?:\\s*\\.\\s*\\w+)*\\b".replace(//g,(function(){return t.source}));e.languages.cpp=e.languages.extend("c",{"class-name":[{pattern:RegExp("(\\b(?:class|concept|enum|struct|typename)\\s+)(?!)\\w+".replace(//g,(function(){return t.source}))),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore("cpp","string",{module:{pattern:RegExp('(\\b(?:import|module)\\s+)(?:"(?:\\\\(?:\r\n|[^])|[^"\\\\\r\n])*"|<[^<>\r\n]*>|'+"(?:\\s*:\\s*)?|:\\s*".replace(//g,(function(){return n}))+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),e.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:e.languages.cpp}}}}),e.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),e.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend("cpp",{})}}),e.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp["base-clause"])}(Prism);!function(e){var t="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",a={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},n={bash:a,environment:{pattern:RegExp("\\$"+t),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+t),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};e.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+t),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:n},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:a}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:n},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:n.entity}}],environment:{pattern:RegExp("\\$?"+t),alias:"constant"},variable:n.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},a.inside=e.languages.bash;for(var s=["comment","function-name","for-or-select","assign-left","parameter","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],o=n.variable[1].inside,i=0;i}]|\$[<{]/};Prism.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},Prism.languages.webmanifest=Prism.languages.json;Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python; \ No newline at end of file diff --git a/resources/js/retype.js b/resources/js/retype.js new file mode 100644 index 00000000..4a4b7d42 --- /dev/null +++ b/resources/js/retype.js @@ -0,0 +1,27 @@ +/*! Retype v3.11.0 | retype.com | Copyright 2025. Retype, Inc. All rights reserved. */ + +/*! For license information please see retype.js.LICENSE.txt */ +(()=>{var e={6184:(e,t,n)=>{"use strict";n.d(t,{BL:()=>Ce,Vn:()=>Te,nP:()=>ke,ry:()=>_e}),function(){if(void 0===window.Reflect||void 0===window.customElements||window.customElements.polyfillWrapFlushCallback)return;const e=HTMLElement;window.HTMLElement=function(){return Reflect.construct(e,[],this.constructor)},HTMLElement.prototype=e.prototype,HTMLElement.prototype.constructor=HTMLElement,Object.setPrototypeOf(HTMLElement,e)}(),function(e){function t(e,t,n){throw new e("Failed to execute 'requestSubmit' on 'HTMLFormElement': "+t+".",n)}"function"!=typeof e.requestSubmit&&(e.requestSubmit=function(e){e?(function(e,n){e instanceof HTMLElement||t(TypeError,"parameter 1 is not of type 'HTMLElement'"),"submit"==e.type||t(TypeError,"The specified element is not a submit button"),e.form==n||t(DOMException,"The specified element is not owned by this form element","NotFoundError")}(e,this),e.click()):((e=document.createElement("input")).type="submit",e.hidden=!0,this.appendChild(e),e.click(),this.removeChild(e))})}(HTMLFormElement.prototype);const r=new WeakMap;function i(e){const t=function(e){const t=e instanceof Element?e:e instanceof Node?e.parentElement:null,n=t?t.closest("input, button"):null;return"submit"==(null==n?void 0:n.type)?n:null}(e.target);t&&t.form&&r.set(t.form,t)}var o,s,a,l,c,u;!function(){if("submitter"in Event.prototype)return;let e=window.Event.prototype;if("SubmitEvent"in window&&/Apple Computer/.test(navigator.vendor))e=window.SubmitEvent.prototype;else if("SubmitEvent"in window)return;addEventListener("click",i,!0),Object.defineProperty(e,"submitter",{get(){if("submit"==this.type&&this.target instanceof HTMLFormElement)return r.get(this.target)}})}(),function(e){e.eager="eager",e.lazy="lazy"}(o||(o={}));class d extends HTMLElement{static get observedAttributes(){return["disabled","complete","loading","src"]}constructor(){super(),this.loaded=Promise.resolve(),this.delegate=new d.delegateConstructor(this)}connectedCallback(){this.delegate.connect()}disconnectedCallback(){this.delegate.disconnect()}reload(){return this.delegate.sourceURLReloaded()}attributeChangedCallback(e){"loading"==e?this.delegate.loadingStyleChanged():"complete"==e?this.delegate.completeChanged():"src"==e?this.delegate.sourceURLChanged():this.delegate.disabledChanged()}get src(){return this.getAttribute("src")}set src(e){e?this.setAttribute("src",e):this.removeAttribute("src")}get loading(){return"lazy"===(this.getAttribute("loading")||"").toLowerCase()?o.lazy:o.eager}set loading(e){e?this.setAttribute("loading",e):this.removeAttribute("loading")}get disabled(){return this.hasAttribute("disabled")}set disabled(e){e?this.setAttribute("disabled",""):this.removeAttribute("disabled")}get autoscroll(){return this.hasAttribute("autoscroll")}set autoscroll(e){e?this.setAttribute("autoscroll",""):this.removeAttribute("autoscroll")}get complete(){return!this.delegate.isLoading}get isActive(){return this.ownerDocument===document&&!this.isPreview}get isPreview(){var e,t;return null===(t=null===(e=this.ownerDocument)||void 0===e?void 0:e.documentElement)||void 0===t?void 0:t.hasAttribute("data-turbo-preview")}}function h(e){return new URL(e.toString(),document.baseURI)}function p(e){let t;return e.hash?e.hash.slice(1):(t=e.href.match(/#(.*)$/))?t[1]:void 0}function f(e,t){return h((null==t?void 0:t.getAttribute("formaction"))||e.getAttribute("action")||e.action)}function m(e,t){return function(e,t){const n=function(e){return(t=e.origin+e.pathname).endsWith("/")?t:t+"/";var t}(t);return e.href===h(n).href||e.href.startsWith(n)}(e,t)&&!!(n=e,(function(e){return function(e){return e.pathname.split("/").slice(1)}(e).slice(-1)[0]}(n).match(/\.[^.]*$/)||[])[0]||"").match(/^(?:|\.(?:htm|html|xhtml|php))$/);var n}function v(e){const t=p(e);return null!=t?e.href.slice(0,-(t.length+1)):e.href}function g(e){return v(e)}class b{constructor(e){this.response=e}get succeeded(){return this.response.ok}get failed(){return!this.succeeded}get clientError(){return this.statusCode>=400&&this.statusCode<=499}get serverError(){return this.statusCode>=500&&this.statusCode<=599}get redirected(){return this.response.redirected}get location(){return h(this.response.url)}get isHTML(){return this.contentType&&this.contentType.match(/^(?:text\/([^\s;,]+\b)?html|application\/xhtml\+xml)\b/)}get statusCode(){return this.response.status}get contentType(){return this.header("Content-Type")}get responseText(){return this.response.clone().text()}get responseHTML(){return this.isHTML?this.response.clone().text():Promise.resolve(void 0)}header(e){return this.response.headers.get(e)}}function y(e){if("false"==e.getAttribute("data-turbo-eval"))return e;{const t=document.createElement("script"),n=R("csp-nonce");return n&&(t.nonce=n),t.textContent=e.textContent,t.async=!1,function(e,t){for(const{name:n,value:r}of t.attributes)e.setAttribute(n,r)}(t,e),t}}function w(e,{target:t,cancelable:n,detail:r}={}){const i=new CustomEvent(e,{cancelable:n,bubbles:!0,composed:!0,detail:r});return t&&t.isConnected?t.dispatchEvent(i):document.documentElement.dispatchEvent(i),i}function S(){return new Promise((e=>requestAnimationFrame((()=>e()))))}function x(e=""){return(new DOMParser).parseFromString(e,"text/html")}function k(e,...t){const n=function(e,t){return e.reduce(((e,n,r)=>e+n+(null==t[r]?"":t[r])),"")}(e,t).replace(/^\n/,"").split("\n"),r=n[0].match(/^\s+/),i=r?r[0].length:0;return n.map((e=>e.slice(i))).join("\n")}function E(){return Array.from({length:36}).map(((e,t)=>8==t||13==t||18==t||23==t?"-":14==t?"4":19==t?(Math.floor(4*Math.random())+8).toString(16):Math.floor(15*Math.random()).toString(16))).join("")}function _(e,...t){for(const n of t.map((t=>null==t?void 0:t.getAttribute(e))))if("string"==typeof n)return n;return null}function C(...e){for(const t of e)"turbo-frame"==t.localName&&t.setAttribute("busy",""),t.setAttribute("aria-busy","true")}function T(...e){for(const t of e)"turbo-frame"==t.localName&&t.removeAttribute("busy"),t.removeAttribute("aria-busy")}function A(e,t=2e3){return new Promise((n=>{const r=()=>{e.removeEventListener("error",r),e.removeEventListener("load",r),n()};e.addEventListener("load",r,{once:!0}),e.addEventListener("error",r,{once:!0}),setTimeout(n,t)}))}function L(e){switch(e){case"replace":return history.replaceState;case"advance":case"restore":return history.pushState}}function D(...e){const t=_("data-turbo-action",...e);return function(e){return"advance"==e||"replace"==e||"restore"==e}(t)?t:null}function I(e){return document.querySelector(`meta[name="${e}"]`)}function R(e){const t=I(e);return t&&t.content}function O(e,t){var n;if(e instanceof Element)return e.closest(t)||O(e.assignedSlot||(null===(n=e.getRootNode())||void 0===n?void 0:n.host),t)}!function(e){e[e.get=0]="get",e[e.post=1]="post",e[e.put=2]="put",e[e.patch=3]="patch",e[e.delete=4]="delete"}(s||(s={}));class M{constructor(e,t,n,r=new URLSearchParams,i=null){this.abortController=new AbortController,this.resolveRequestPromise=e=>{},this.delegate=e,this.method=t,this.headers=this.defaultHeaders,this.body=r,this.url=n,this.target=i}get location(){return this.url}get params(){return this.url.searchParams}get entries(){return this.body?Array.from(this.body.entries()):[]}cancel(){this.abortController.abort()}async perform(){const{fetchOptions:e}=this;this.delegate.prepareRequest(this),await this.allowRequestToBeIntercepted(e);try{this.delegate.requestStarted(this);const t=await fetch(this.url.href,e);return await this.receive(t)}catch(e){if("AbortError"!==e.name)throw this.willDelegateErrorHandling(e)&&this.delegate.requestErrored(this,e),e}finally{this.delegate.requestFinished(this)}}async receive(e){const t=new b(e);return w("turbo:before-fetch-response",{cancelable:!0,detail:{fetchResponse:t},target:this.target}).defaultPrevented?this.delegate.requestPreventedHandlingResponse(this,t):t.succeeded?this.delegate.requestSucceededWithResponse(this,t):this.delegate.requestFailedWithResponse(this,t),t}get fetchOptions(){var e;return{method:s[this.method].toUpperCase(),credentials:"same-origin",headers:this.headers,redirect:"follow",body:this.isSafe?null:this.body,signal:this.abortSignal,referrer:null===(e=this.delegate.referrer)||void 0===e?void 0:e.href}}get defaultHeaders(){return{Accept:"text/html, application/xhtml+xml"}}get isSafe(){return this.method===s.get}get abortSignal(){return this.abortController.signal}acceptResponseType(e){this.headers.Accept=[e,this.headers.Accept].join(", ")}async allowRequestToBeIntercepted(e){const t=new Promise((e=>this.resolveRequestPromise=e));w("turbo:before-fetch-request",{cancelable:!0,detail:{fetchOptions:e,url:this.url,resume:this.resolveRequestPromise},target:this.target}).defaultPrevented&&await t}willDelegateErrorHandling(e){return!w("turbo:fetch-request-error",{target:this.target,cancelable:!0,detail:{request:this,error:e}}).defaultPrevented}}class N{constructor(e,t){this.started=!1,this.intersect=e=>{const t=e.slice(-1)[0];(null==t?void 0:t.isIntersecting)&&this.delegate.elementAppearedInViewport(this.element)},this.delegate=e,this.element=t,this.intersectionObserver=new IntersectionObserver(this.intersect)}start(){this.started||(this.started=!0,this.intersectionObserver.observe(this.element))}stop(){this.started&&(this.started=!1,this.intersectionObserver.unobserve(this.element))}}class F{static wrap(e){return"string"==typeof e?new this(function(e){const t=document.createElement("template");return t.innerHTML=e,t.content}(e)):e}constructor(e){this.fragment=function(e){for(const t of e.querySelectorAll("turbo-stream")){const e=document.importNode(t,!0);for(const t of e.templateElement.content.querySelectorAll("script"))t.replaceWith(y(t));t.replaceWith(e)}return e}(e)}}F.contentType="text/vnd.turbo-stream.html",function(e){e[e.initialized=0]="initialized",e[e.requesting=1]="requesting",e[e.waiting=2]="waiting",e[e.receiving=3]="receiving",e[e.stopping=4]="stopping",e[e.stopped=5]="stopped"}(a||(a={})),function(e){e.urlEncoded="application/x-www-form-urlencoded",e.multipart="multipart/form-data",e.plain="text/plain"}(l||(l={}));class P{static confirmMethod(e,t,n){return Promise.resolve(confirm(e))}constructor(e,t,n,r=!1){this.state=a.initialized,this.delegate=e,this.formElement=t,this.submitter=n,this.formData=function(e,t){const n=new FormData(e),r=null==t?void 0:t.getAttribute("name"),i=null==t?void 0:t.getAttribute("value");return r&&n.append(r,i||""),n}(t,n),this.location=h(this.action),this.method==s.get&&function(e,t){const n=new URLSearchParams;for(const[e,r]of t)r instanceof File||n.append(e,r);e.search=n.toString()}(this.location,[...this.body.entries()]),this.fetchRequest=new M(this,this.method,this.location,this.body,this.formElement),this.mustRedirect=r}get method(){var e;return function(e){switch(e.toLowerCase()){case"get":return s.get;case"post":return s.post;case"put":return s.put;case"patch":return s.patch;case"delete":return s.delete}}(((null===(e=this.submitter)||void 0===e?void 0:e.getAttribute("formmethod"))||this.formElement.getAttribute("method")||"").toLowerCase())||s.get}get action(){var e;const t="string"==typeof this.formElement.action?this.formElement.action:null;return(null===(e=this.submitter)||void 0===e?void 0:e.hasAttribute("formaction"))?this.submitter.getAttribute("formaction")||"":this.formElement.getAttribute("action")||t||""}get body(){return this.enctype==l.urlEncoded||this.method==s.get?new URLSearchParams(this.stringFormData):this.formData}get enctype(){var e;return function(e){switch(e.toLowerCase()){case l.multipart:return l.multipart;case l.plain:return l.plain;default:return l.urlEncoded}}((null===(e=this.submitter)||void 0===e?void 0:e.getAttribute("formenctype"))||this.formElement.enctype)}get isSafe(){return this.fetchRequest.isSafe}get stringFormData(){return[...this.formData].reduce(((e,[t,n])=>e.concat("string"==typeof n?[[t,n]]:[])),[])}async start(){const{initialized:e,requesting:t}=a,n=_("data-turbo-confirm",this.submitter,this.formElement);if("string"!=typeof n||await P.confirmMethod(n,this.formElement,this.submitter))return this.state==e?(this.state=t,this.fetchRequest.perform()):void 0}stop(){const{stopping:e,stopped:t}=a;if(this.state!=e&&this.state!=t)return this.state=e,this.fetchRequest.cancel(),!0}prepareRequest(e){if(!e.isSafe){const t=function(e){if(null!=e){const t=(document.cookie?document.cookie.split("; "):[]).find((t=>t.startsWith(e)));if(t){const e=t.split("=").slice(1).join("=");return e?decodeURIComponent(e):void 0}}}(R("csrf-param"))||R("csrf-token");t&&(e.headers["X-CSRF-Token"]=t)}this.requestAcceptsTurboStreamResponse(e)&&e.acceptResponseType(F.contentType)}requestStarted(e){var t;this.state=a.waiting,null===(t=this.submitter)||void 0===t||t.setAttribute("disabled",""),this.setSubmitsWith(),w("turbo:submit-start",{target:this.formElement,detail:{formSubmission:this}}),this.delegate.formSubmissionStarted(this)}requestPreventedHandlingResponse(e,t){this.result={success:t.succeeded,fetchResponse:t}}requestSucceededWithResponse(e,t){if(t.clientError||t.serverError)this.delegate.formSubmissionFailedWithResponse(this,t);else if(this.requestMustRedirect(e)&&function(e){return 200==e.statusCode&&!e.redirected}(t)){const e=new Error("Form responses must redirect to another location");this.delegate.formSubmissionErrored(this,e)}else this.state=a.receiving,this.result={success:!0,fetchResponse:t},this.delegate.formSubmissionSucceededWithResponse(this,t)}requestFailedWithResponse(e,t){this.result={success:!1,fetchResponse:t},this.delegate.formSubmissionFailedWithResponse(this,t)}requestErrored(e,t){this.result={success:!1,error:t},this.delegate.formSubmissionErrored(this,t)}requestFinished(e){var t;this.state=a.stopped,null===(t=this.submitter)||void 0===t||t.removeAttribute("disabled"),this.resetSubmitterText(),w("turbo:submit-end",{target:this.formElement,detail:Object.assign({formSubmission:this},this.result)}),this.delegate.formSubmissionFinished(this)}setSubmitsWith(){if(this.submitter&&this.submitsWith)if(this.submitter.matches("button"))this.originalSubmitText=this.submitter.innerHTML,this.submitter.innerHTML=this.submitsWith;else if(this.submitter.matches("input")){const e=this.submitter;this.originalSubmitText=e.value,e.value=this.submitsWith}}resetSubmitterText(){this.submitter&&this.originalSubmitText&&(this.submitter.matches("button")?this.submitter.innerHTML=this.originalSubmitText:this.submitter.matches("input")&&(this.submitter.value=this.originalSubmitText))}requestMustRedirect(e){return!e.isSafe&&this.mustRedirect}requestAcceptsTurboStreamResponse(e){return!e.isSafe||function(e,...t){return t.some((t=>t&&t.hasAttribute(e)))}("data-turbo-stream",this.submitter,this.formElement)}get submitsWith(){var e;return null===(e=this.submitter)||void 0===e?void 0:e.getAttribute("data-turbo-submits-with")}}class H{constructor(e){this.element=e}get activeElement(){return this.element.ownerDocument.activeElement}get children(){return[...this.element.children]}hasAnchor(e){return null!=this.getElementForAnchor(e)}getElementForAnchor(e){return e?this.element.querySelector(`[id='${e}'], a[name='${e}']`):null}get isConnected(){return this.element.isConnected}get firstAutofocusableElement(){for(const e of this.element.querySelectorAll("[autofocus]"))if(null==e.closest("[inert], :disabled, [hidden], details:not([open]), dialog:not([open])"))return e;return null}get permanentElements(){return B(this.element)}getPermanentElementById(e){return W(this.element,e)}getPermanentElementMapForSnapshot(e){const t={};for(const n of this.permanentElements){const{id:r}=n,i=e.getPermanentElementById(r);i&&(t[r]=[n,i])}return t}}function W(e,t){return e.querySelector(`#${t}[data-turbo-permanent]`)}function B(e){return e.querySelectorAll("[id][data-turbo-permanent]")}class V{constructor(e,t){this.started=!1,this.submitCaptured=()=>{this.eventTarget.removeEventListener("submit",this.submitBubbled,!1),this.eventTarget.addEventListener("submit",this.submitBubbled,!1)},this.submitBubbled=e=>{if(!e.defaultPrevented){const t=e.target instanceof HTMLFormElement?e.target:void 0,n=e.submitter||void 0;t&&function(e,t){return"dialog"!=((null==t?void 0:t.getAttribute("formmethod"))||e.getAttribute("method"))}(t,n)&&function(e,t){if((null==t?void 0:t.hasAttribute("formtarget"))||e.hasAttribute("target")){const n=(null==t?void 0:t.getAttribute("formtarget"))||e.target;for(const e of document.getElementsByName(n))if(e instanceof HTMLIFrameElement)return!1;return!0}return!0}(t,n)&&this.delegate.willSubmitForm(t,n)&&(e.preventDefault(),e.stopImmediatePropagation(),this.delegate.formSubmitted(t,n))}},this.delegate=e,this.eventTarget=t}start(){this.started||(this.eventTarget.addEventListener("submit",this.submitCaptured,!0),this.started=!0)}stop(){this.started&&(this.eventTarget.removeEventListener("submit",this.submitCaptured,!0),this.started=!1)}}class j{constructor(e,t){this.resolveRenderPromise=e=>{},this.resolveInterceptionPromise=e=>{},this.delegate=e,this.element=t}scrollToAnchor(e){const t=this.snapshot.getElementForAnchor(e);t?(this.scrollToElement(t),this.focusElement(t)):this.scrollToPosition({x:0,y:0})}scrollToAnchorFromLocation(e){this.scrollToAnchor(p(e))}scrollToElement(e){e.scrollIntoView()}focusElement(e){e instanceof HTMLElement&&(e.hasAttribute("tabindex")?e.focus():(e.setAttribute("tabindex","-1"),e.focus(),e.removeAttribute("tabindex")))}scrollToPosition({x:e,y:t}){this.scrollRoot.scrollTo(e,t)}scrollToTop(){this.scrollToPosition({x:0,y:0})}get scrollRoot(){return window}async render(e){const{isPreview:t,shouldRender:n,newSnapshot:r}=e;if(n)try{this.renderPromise=new Promise((e=>this.resolveRenderPromise=e)),this.renderer=e,await this.prepareToRenderSnapshot(e);const n=new Promise((e=>this.resolveInterceptionPromise=e)),i={resume:this.resolveInterceptionPromise,render:this.renderer.renderElement};this.delegate.allowsImmediateRender(r,i)||await n,await this.renderSnapshot(e),this.delegate.viewRenderedSnapshot(r,t),this.delegate.preloadOnLoadLinksForView(this.element),this.finishRenderingSnapshot(e)}finally{delete this.renderer,this.resolveRenderPromise(void 0),delete this.renderPromise}else this.invalidate(e.reloadReason)}invalidate(e){this.delegate.viewInvalidated(e)}async prepareToRenderSnapshot(e){this.markAsPreview(e.isPreview),await e.prepareToRender()}markAsPreview(e){e?this.element.setAttribute("data-turbo-preview",""):this.element.removeAttribute("data-turbo-preview")}async renderSnapshot(e){await e.render()}finishRenderingSnapshot(e){e.finishRendering()}}class q extends j{missing(){this.element.innerHTML='Content missing'}get snapshot(){return new H(this.element)}}class z{constructor(e,t){this.clickBubbled=e=>{this.respondsToEventTarget(e.target)?this.clickEvent=e:delete this.clickEvent},this.linkClicked=e=>{this.clickEvent&&this.respondsToEventTarget(e.target)&&e.target instanceof Element&&this.delegate.shouldInterceptLinkClick(e.target,e.detail.url,e.detail.originalEvent)&&(this.clickEvent.preventDefault(),e.preventDefault(),this.delegate.linkClickIntercepted(e.target,e.detail.url,e.detail.originalEvent)),delete this.clickEvent},this.willVisit=e=>{delete this.clickEvent},this.delegate=e,this.element=t}start(){this.element.addEventListener("click",this.clickBubbled),document.addEventListener("turbo:click",this.linkClicked),document.addEventListener("turbo:before-visit",this.willVisit)}stop(){this.element.removeEventListener("click",this.clickBubbled),document.removeEventListener("turbo:click",this.linkClicked),document.removeEventListener("turbo:before-visit",this.willVisit)}respondsToEventTarget(e){const t=e instanceof Element?e:e instanceof Node?e.parentElement:null;return t&&t.closest("turbo-frame, html")==this.element}}class ${constructor(e,t){this.started=!1,this.clickCaptured=()=>{this.eventTarget.removeEventListener("click",this.clickBubbled,!1),this.eventTarget.addEventListener("click",this.clickBubbled,!1)},this.clickBubbled=e=>{if(e instanceof MouseEvent&&this.clickEventIsSignificant(e)){const t=e.composedPath&&e.composedPath()[0]||e.target,n=this.findLinkFromClickTarget(t);if(n&&function(e){if(e.hasAttribute("target")){for(const t of document.getElementsByName(e.target))if(t instanceof HTMLIFrameElement)return!1;return!0}return!0}(n)){const t=this.getLocationForLink(n);this.delegate.willFollowLinkToLocation(n,t,e)&&(e.preventDefault(),this.delegate.followedLinkToLocation(n,t))}}},this.delegate=e,this.eventTarget=t}start(){this.started||(this.eventTarget.addEventListener("click",this.clickCaptured,!0),this.started=!0)}stop(){this.started&&(this.eventTarget.removeEventListener("click",this.clickCaptured,!0),this.started=!1)}clickEventIsSignificant(e){return!(e.target&&e.target.isContentEditable||e.defaultPrevented||e.which>1||e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)}findLinkFromClickTarget(e){return O(e,"a[href]:not([target^=_]):not([download])")}getLocationForLink(e){return h(e.getAttribute("href")||"")}}class U{constructor(e,t){this.delegate=e,this.linkInterceptor=new $(this,t)}start(){this.linkInterceptor.start()}stop(){this.linkInterceptor.stop()}willFollowLinkToLocation(e,t,n){return this.delegate.willSubmitFormLinkToLocation(e,t,n)&&e.hasAttribute("data-turbo-method")}followedLinkToLocation(e,t){const n=document.createElement("form");for(const[e,r]of t.searchParams)n.append(Object.assign(document.createElement("input"),{type:"hidden",name:e,value:r}));const r=Object.assign(t,{search:""});n.setAttribute("data-turbo","true"),n.setAttribute("action",r.href),n.setAttribute("hidden","");const i=e.getAttribute("data-turbo-method");i&&n.setAttribute("method",i);const o=e.getAttribute("data-turbo-frame");o&&n.setAttribute("data-turbo-frame",o);const s=D(e);s&&n.setAttribute("data-turbo-action",s);const a=e.getAttribute("data-turbo-confirm");a&&n.setAttribute("data-turbo-confirm",a),e.hasAttribute("data-turbo-stream")&&n.setAttribute("data-turbo-stream",""),this.delegate.submittedFormLinkToLocation(e,t,n),document.body.appendChild(n),n.addEventListener("turbo:submit-end",(()=>n.remove()),{once:!0}),requestAnimationFrame((()=>n.requestSubmit()))}}class Z{static async preservingPermanentElements(e,t,n){const r=new this(e,t);r.enter(),await n(),r.leave()}constructor(e,t){this.delegate=e,this.permanentElementMap=t}enter(){for(const e in this.permanentElementMap){const[t,n]=this.permanentElementMap[e];this.delegate.enteringBardo(t,n),this.replaceNewPermanentElementWithPlaceholder(n)}}leave(){for(const e in this.permanentElementMap){const[t]=this.permanentElementMap[e];this.replaceCurrentPermanentElementWithClone(t),this.replacePlaceholderWithPermanentElement(t),this.delegate.leavingBardo(t)}}replaceNewPermanentElementWithPlaceholder(e){const t=function(e){const t=document.createElement("meta");return t.setAttribute("name","turbo-permanent-placeholder"),t.setAttribute("content",e.id),t}(e);e.replaceWith(t)}replaceCurrentPermanentElementWithClone(e){const t=e.cloneNode(!0);e.replaceWith(t)}replacePlaceholderWithPermanentElement(e){const t=this.getPlaceholderById(e.id);null==t||t.replaceWith(e)}getPlaceholderById(e){return this.placeholders.find((t=>t.content==e))}get placeholders(){return[...document.querySelectorAll("meta[name=turbo-permanent-placeholder][content]")]}}class K{constructor(e,t,n,r,i=!0){this.activeElement=null,this.currentSnapshot=e,this.newSnapshot=t,this.isPreview=r,this.willRender=i,this.renderElement=n,this.promise=new Promise(((e,t)=>this.resolvingFunctions={resolve:e,reject:t}))}get shouldRender(){return!0}get reloadReason(){}prepareToRender(){}finishRendering(){this.resolvingFunctions&&(this.resolvingFunctions.resolve(),delete this.resolvingFunctions)}async preservingPermanentElements(e){await Z.preservingPermanentElements(this,this.permanentElementMap,e)}focusFirstAutofocusableElement(){const e=this.connectedSnapshot.firstAutofocusableElement;(function(e){return e&&"function"==typeof e.focus})(e)&&e.focus()}enteringBardo(e){this.activeElement||e.contains(this.currentSnapshot.activeElement)&&(this.activeElement=this.currentSnapshot.activeElement)}leavingBardo(e){e.contains(this.activeElement)&&this.activeElement instanceof HTMLElement&&(this.activeElement.focus(),this.activeElement=null)}get connectedSnapshot(){return this.newSnapshot.isConnected?this.newSnapshot:this.currentSnapshot}get currentElement(){return this.currentSnapshot.element}get newElement(){return this.newSnapshot.element}get permanentElementMap(){return this.currentSnapshot.getPermanentElementMapForSnapshot(this.newSnapshot)}}class Y extends K{static renderElement(e,t){var n;const r=document.createRange();r.selectNodeContents(e),r.deleteContents();const i=t,o=null===(n=i.ownerDocument)||void 0===n?void 0:n.createRange();o&&(o.selectNodeContents(i),e.appendChild(o.extractContents()))}constructor(e,t,n,r,i,o=!0){super(t,n,r,i,o),this.delegate=e}get shouldRender(){return!0}async render(){await S(),this.preservingPermanentElements((()=>{this.loadFrameElement()})),this.scrollFrameIntoView(),await S(),this.focusFirstAutofocusableElement(),await S(),this.activateScriptElements()}loadFrameElement(){this.delegate.willRenderFrame(this.currentElement,this.newElement),this.renderElement(this.currentElement,this.newElement)}scrollFrameIntoView(){if(this.currentElement.autoscroll||this.newElement.autoscroll){const t=this.currentElement.firstElementChild,n=("end","end"==(e=this.currentElement.getAttribute("data-autoscroll-block"))||"start"==e||"center"==e||"nearest"==e?e:"end"),r=function(e,t){return"auto"==e||"smooth"==e?e:"auto"}(this.currentElement.getAttribute("data-autoscroll-behavior"));if(t)return t.scrollIntoView({block:n,behavior:r}),!0}var e;return!1}activateScriptElements(){for(const e of this.newScriptElements){const t=y(e);e.replaceWith(t)}}get newScriptElements(){return this.currentElement.querySelectorAll("script")}}class G{static get defaultCSS(){return k` + .turbo-progress-bar { + position: fixed; + display: block; + top: 0; + left: 0; + height: 3px; + background: #0076ff; + z-index: 2147483647; + transition: + width ${G.animationDuration}ms ease-out, + opacity ${G.animationDuration/2}ms ${G.animationDuration/2}ms ease-in; + transform: translate3d(0, 0, 0); + } + `}constructor(){this.hiding=!1,this.value=0,this.visible=!1,this.trickle=()=>{this.setValue(this.value+Math.random()/100)},this.stylesheetElement=this.createStylesheetElement(),this.progressElement=this.createProgressElement(),this.installStylesheetElement(),this.setValue(0)}show(){this.visible||(this.visible=!0,this.installProgressElement(),this.startTrickling())}hide(){this.visible&&!this.hiding&&(this.hiding=!0,this.fadeProgressElement((()=>{this.uninstallProgressElement(),this.stopTrickling(),this.visible=!1,this.hiding=!1})))}setValue(e){this.value=e,this.refresh()}installStylesheetElement(){document.head.insertBefore(this.stylesheetElement,document.head.firstChild)}installProgressElement(){this.progressElement.style.width="0",this.progressElement.style.opacity="1",document.documentElement.insertBefore(this.progressElement,document.body),this.refresh()}fadeProgressElement(e){this.progressElement.style.opacity="0",setTimeout(e,1.5*G.animationDuration)}uninstallProgressElement(){this.progressElement.parentNode&&document.documentElement.removeChild(this.progressElement)}startTrickling(){this.trickleInterval||(this.trickleInterval=window.setInterval(this.trickle,G.animationDuration))}stopTrickling(){window.clearInterval(this.trickleInterval),delete this.trickleInterval}refresh(){requestAnimationFrame((()=>{this.progressElement.style.width=10+90*this.value+"%"}))}createStylesheetElement(){const e=document.createElement("style");return e.type="text/css",e.textContent=G.defaultCSS,this.cspNonce&&(e.nonce=this.cspNonce),e}createProgressElement(){const e=document.createElement("div");return e.className="turbo-progress-bar",e}get cspNonce(){return R("csp-nonce")}}G.animationDuration=300;class X extends H{constructor(){super(...arguments),this.detailsByOuterHTML=this.children.filter((e=>!function(e){return"noscript"==e.localName}(e))).map((e=>function(e){return e.hasAttribute("nonce")&&e.setAttribute("nonce",""),e}(e))).reduce(((e,t)=>{const{outerHTML:n}=t,r=n in e?e[n]:{type:Q(t),tracked:J(t),elements:[]};return Object.assign(Object.assign({},e),{[n]:Object.assign(Object.assign({},r),{elements:[...r.elements,t]})})}),{})}get trackedElementSignature(){return Object.keys(this.detailsByOuterHTML).filter((e=>this.detailsByOuterHTML[e].tracked)).join("")}getScriptElementsNotInSnapshot(e){return this.getElementsMatchingTypeNotInSnapshot("script",e)}getStylesheetElementsNotInSnapshot(e){return this.getElementsMatchingTypeNotInSnapshot("stylesheet",e)}getElementsMatchingTypeNotInSnapshot(e,t){return Object.keys(this.detailsByOuterHTML).filter((e=>!(e in t.detailsByOuterHTML))).map((e=>this.detailsByOuterHTML[e])).filter((({type:t})=>t==e)).map((({elements:[e]})=>e))}get provisionalElements(){return Object.keys(this.detailsByOuterHTML).reduce(((e,t)=>{const{type:n,tracked:r,elements:i}=this.detailsByOuterHTML[t];return null!=n||r?i.length>1?[...e,...i.slice(1)]:e:[...e,...i]}),[])}getMetaValue(e){const t=this.findMetaElementByName(e);return t?t.getAttribute("content"):null}findMetaElementByName(e){return Object.keys(this.detailsByOuterHTML).reduce(((t,n)=>{const{elements:[r]}=this.detailsByOuterHTML[n];return function(e,t){return"meta"==e.localName&&e.getAttribute("name")==t}(r,e)?r:t}),void 0)}}function Q(e){return function(e){return"script"==e.localName}(e)?"script":function(e){const t=e.localName;return"style"==t||"link"==t&&"stylesheet"==e.getAttribute("rel")}(e)?"stylesheet":void 0}function J(e){return"reload"==e.getAttribute("data-turbo-track")}class ee extends H{static fromHTMLString(e=""){return this.fromDocument(x(e))}static fromElement(e){return this.fromDocument(e.ownerDocument)}static fromDocument({head:e,body:t}){return new this(t,new X(e))}constructor(e,t){super(e),this.headSnapshot=t}clone(){const e=this.element.cloneNode(!0),t=this.element.querySelectorAll("select"),n=e.querySelectorAll("select");for(const[e,r]of t.entries()){const t=n[e];for(const e of t.selectedOptions)e.selected=!1;for(const e of r.selectedOptions)t.options[e.index].selected=!0}for(const t of e.querySelectorAll('input[type="password"]'))t.value="";return new ee(e,this.headSnapshot)}get headElement(){return this.headSnapshot.element}get rootLocation(){var e;return h(null!==(e=this.getSetting("root"))&&void 0!==e?e:"/")}get cacheControlValue(){return this.getSetting("cache-control")}get isPreviewable(){return"no-preview"!=this.cacheControlValue}get isCacheable(){return"no-cache"!=this.cacheControlValue}get isVisitable(){return"reload"!=this.getSetting("visit-control")}getSetting(e){return this.headSnapshot.getMetaValue(`turbo-${e}`)}}!function(e){e.visitStart="visitStart",e.requestStart="requestStart",e.requestEnd="requestEnd",e.visitEnd="visitEnd"}(c||(c={})),function(e){e.initialized="initialized",e.started="started",e.canceled="canceled",e.failed="failed",e.completed="completed"}(u||(u={}));const te={action:"advance",historyChanged:!1,visitCachedSnapshot:()=>{},willRender:!0,updateHistory:!0,shouldCacheSnapshot:!0,acceptsStreamResponse:!1};var ne,re;!function(e){e[e.networkFailure=0]="networkFailure",e[e.timeoutFailure=-1]="timeoutFailure",e[e.contentTypeMismatch=-2]="contentTypeMismatch"}(ne||(ne={}));class ie{constructor(e,t,n,r={}){this.identifier=E(),this.timingMetrics={},this.followedRedirect=!1,this.historyChanged=!1,this.scrolled=!1,this.shouldCacheSnapshot=!0,this.acceptsStreamResponse=!1,this.snapshotCached=!1,this.state=u.initialized,this.delegate=e,this.location=t,this.restorationIdentifier=n||E();const{action:i,historyChanged:o,referrer:s,snapshot:a,snapshotHTML:l,response:c,visitCachedSnapshot:d,willRender:h,updateHistory:p,shouldCacheSnapshot:f,acceptsStreamResponse:m}=Object.assign(Object.assign({},te),r);this.action=i,this.historyChanged=o,this.referrer=s,this.snapshot=a,this.snapshotHTML=l,this.response=c,this.isSamePage=this.delegate.locationWithActionIsSamePage(this.location,this.action),this.visitCachedSnapshot=d,this.willRender=h,this.updateHistory=p,this.scrolled=!h,this.shouldCacheSnapshot=f,this.acceptsStreamResponse=m}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get history(){return this.delegate.history}get restorationData(){return this.history.getRestorationDataForIdentifier(this.restorationIdentifier)}get silent(){return this.isSamePage}start(){this.state==u.initialized&&(this.recordTimingMetric(c.visitStart),this.state=u.started,this.adapter.visitStarted(this),this.delegate.visitStarted(this))}cancel(){this.state==u.started&&(this.request&&this.request.cancel(),this.cancelRender(),this.state=u.canceled)}complete(){this.state==u.started&&(this.recordTimingMetric(c.visitEnd),this.state=u.completed,this.followRedirect(),this.followedRedirect||(this.adapter.visitCompleted(this),this.delegate.visitCompleted(this)))}fail(){this.state==u.started&&(this.state=u.failed,this.adapter.visitFailed(this))}changeHistory(){var e;if(!this.historyChanged&&this.updateHistory){const t=L(this.location.href===(null===(e=this.referrer)||void 0===e?void 0:e.href)?"replace":this.action);this.history.update(t,this.location,this.restorationIdentifier),this.historyChanged=!0}}issueRequest(){this.hasPreloadedResponse()?this.simulateRequest():this.shouldIssueRequest()&&!this.request&&(this.request=new M(this,s.get,this.location),this.request.perform())}simulateRequest(){this.response&&(this.startRequest(),this.recordResponse(),this.finishRequest())}startRequest(){this.recordTimingMetric(c.requestStart),this.adapter.visitRequestStarted(this)}recordResponse(e=this.response){if(this.response=e,e){const{statusCode:t}=e;oe(t)?this.adapter.visitRequestCompleted(this):this.adapter.visitRequestFailedWithStatusCode(this,t)}}finishRequest(){this.recordTimingMetric(c.requestEnd),this.adapter.visitRequestFinished(this)}loadResponse(){if(this.response){const{statusCode:e,responseHTML:t}=this.response;this.render((async()=>{this.shouldCacheSnapshot&&this.cacheSnapshot(),this.view.renderPromise&&await this.view.renderPromise,oe(e)&&null!=t?(await this.view.renderPage(ee.fromHTMLString(t),!1,this.willRender,this),this.performScroll(),this.adapter.visitRendered(this),this.complete()):(await this.view.renderError(ee.fromHTMLString(t),this),this.adapter.visitRendered(this),this.fail())}))}}getCachedSnapshot(){const e=this.view.getCachedSnapshotForLocation(this.location)||this.getPreloadedSnapshot();if(e&&(!p(this.location)||e.hasAnchor(p(this.location)))&&("restore"==this.action||e.isPreviewable))return e}getPreloadedSnapshot(){if(this.snapshotHTML)return ee.fromHTMLString(this.snapshotHTML)}hasCachedSnapshot(){return null!=this.getCachedSnapshot()}loadCachedSnapshot(){const e=this.getCachedSnapshot();if(e){const t=this.shouldIssueRequest();this.render((async()=>{this.cacheSnapshot(),this.isSamePage?this.adapter.visitRendered(this):(this.view.renderPromise&&await this.view.renderPromise,await this.view.renderPage(e,t,this.willRender,this),this.performScroll(),this.adapter.visitRendered(this),t||this.complete())}))}}followRedirect(){var e;this.redirectedToLocation&&!this.followedRedirect&&(null===(e=this.response)||void 0===e?void 0:e.redirected)&&(this.adapter.visitProposedToLocation(this.redirectedToLocation,{action:"replace",response:this.response,shouldCacheSnapshot:!1,willRender:!1}),this.followedRedirect=!0)}goToSamePageAnchor(){this.isSamePage&&this.render((async()=>{this.cacheSnapshot(),this.performScroll(),this.changeHistory(),this.adapter.visitRendered(this)}))}prepareRequest(e){this.acceptsStreamResponse&&e.acceptResponseType(F.contentType)}requestStarted(){this.startRequest()}requestPreventedHandlingResponse(e,t){}async requestSucceededWithResponse(e,t){const n=await t.responseHTML,{redirected:r,statusCode:i}=t;null==n?this.recordResponse({statusCode:ne.contentTypeMismatch,redirected:r}):(this.redirectedToLocation=t.redirected?t.location:void 0,this.recordResponse({statusCode:i,responseHTML:n,redirected:r}))}async requestFailedWithResponse(e,t){const n=await t.responseHTML,{redirected:r,statusCode:i}=t;null==n?this.recordResponse({statusCode:ne.contentTypeMismatch,redirected:r}):this.recordResponse({statusCode:i,responseHTML:n,redirected:r})}requestErrored(e,t){this.recordResponse({statusCode:ne.networkFailure,redirected:!1})}requestFinished(){this.finishRequest()}performScroll(){this.scrolled||this.view.forceReloaded||("restore"==this.action?this.scrollToRestoredPosition()||this.scrollToAnchor()||this.view.scrollToTop():this.scrollToAnchor()||this.view.scrollToTop(),this.isSamePage&&this.delegate.visitScrolledToSamePageLocation(this.view.lastRenderedLocation,this.location),this.scrolled=!0)}scrollToRestoredPosition(){const{scrollPosition:e}=this.restorationData;if(e)return this.view.scrollToPosition(e),!0}scrollToAnchor(){const e=p(this.location);if(null!=e)return this.view.scrollToAnchor(e),!0}recordTimingMetric(e){this.timingMetrics[e]=(new Date).getTime()}getTimingMetrics(){return Object.assign({},this.timingMetrics)}getHistoryMethodForAction(e){switch(e){case"replace":return history.replaceState;case"advance":case"restore":return history.pushState}}hasPreloadedResponse(){return"object"==typeof this.response}shouldIssueRequest(){return!this.isSamePage&&("restore"==this.action?!this.hasCachedSnapshot():this.willRender)}cacheSnapshot(){this.snapshotCached||(this.view.cacheSnapshot(this.snapshot).then((e=>e&&this.visitCachedSnapshot(e))),this.snapshotCached=!0)}async render(e){this.cancelRender(),await new Promise((e=>{this.frame=requestAnimationFrame((()=>e()))})),await e(),delete this.frame}cancelRender(){this.frame&&(cancelAnimationFrame(this.frame),delete this.frame)}}function oe(e){return e>=200&&e<300}class se{constructor(e){this.progressBar=new G,this.showProgressBar=()=>{this.progressBar.show()},this.session=e}visitProposedToLocation(e,t){this.navigator.startVisit(e,(null==t?void 0:t.restorationIdentifier)||E(),t)}visitStarted(e){this.location=e.location,e.loadCachedSnapshot(),e.issueRequest(),e.goToSamePageAnchor()}visitRequestStarted(e){this.progressBar.setValue(0),e.hasCachedSnapshot()||"restore"!=e.action?this.showVisitProgressBarAfterDelay():this.showProgressBar()}visitRequestCompleted(e){e.loadResponse()}visitRequestFailedWithStatusCode(e,t){switch(t){case ne.networkFailure:case ne.timeoutFailure:case ne.contentTypeMismatch:return this.reload({reason:"request_failed",context:{statusCode:t}});default:return e.loadResponse()}}visitRequestFinished(e){this.progressBar.setValue(1),this.hideVisitProgressBar()}visitCompleted(e){}pageInvalidated(e){this.reload(e)}visitFailed(e){}visitRendered(e){}formSubmissionStarted(e){this.progressBar.setValue(0),this.showFormProgressBarAfterDelay()}formSubmissionFinished(e){this.progressBar.setValue(1),this.hideFormProgressBar()}showVisitProgressBarAfterDelay(){this.visitProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay)}hideVisitProgressBar(){this.progressBar.hide(),null!=this.visitProgressBarTimeout&&(window.clearTimeout(this.visitProgressBarTimeout),delete this.visitProgressBarTimeout)}showFormProgressBarAfterDelay(){null==this.formProgressBarTimeout&&(this.formProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay))}hideFormProgressBar(){this.progressBar.hide(),null!=this.formProgressBarTimeout&&(window.clearTimeout(this.formProgressBarTimeout),delete this.formProgressBarTimeout)}reload(e){var t;w("turbo:reload",{detail:e}),window.location.href=(null===(t=this.location)||void 0===t?void 0:t.toString())||window.location.href}get navigator(){return this.session.navigator}}class ae{constructor(){this.selector="[data-turbo-temporary]",this.deprecatedSelector="[data-turbo-cache=false]",this.started=!1,this.removeTemporaryElements=e=>{for(const e of this.temporaryElements)e.remove()}}start(){this.started||(this.started=!0,addEventListener("turbo:before-cache",this.removeTemporaryElements,!1))}stop(){this.started&&(this.started=!1,removeEventListener("turbo:before-cache",this.removeTemporaryElements,!1))}get temporaryElements(){return[...document.querySelectorAll(this.selector),...this.temporaryElementsWithDeprecation]}get temporaryElementsWithDeprecation(){const e=document.querySelectorAll(this.deprecatedSelector);return e.length&&console.warn(`The ${this.deprecatedSelector} selector is deprecated and will be removed in a future version. Use ${this.selector} instead.`),[...e]}}class le{constructor(e,t){this.session=e,this.element=t,this.linkInterceptor=new z(this,t),this.formSubmitObserver=new V(this,t)}start(){this.linkInterceptor.start(),this.formSubmitObserver.start()}stop(){this.linkInterceptor.stop(),this.formSubmitObserver.stop()}shouldInterceptLinkClick(e,t,n){return this.shouldRedirect(e)}linkClickIntercepted(e,t,n){const r=this.findFrameElement(e);r&&r.delegate.linkClickIntercepted(e,t,n)}willSubmitForm(e,t){return null==e.closest("turbo-frame")&&this.shouldSubmit(e,t)&&this.shouldRedirect(e,t)}formSubmitted(e,t){const n=this.findFrameElement(e,t);n&&n.delegate.formSubmitted(e,t)}shouldSubmit(e,t){var n;const r=f(e,t),i=this.element.ownerDocument.querySelector('meta[name="turbo-root"]'),o=h(null!==(n=null==i?void 0:i.content)&&void 0!==n?n:"/");return this.shouldRedirect(e,t)&&m(r,o)}shouldRedirect(e,t){if(e instanceof HTMLFormElement?this.session.submissionIsNavigatable(e,t):this.session.elementIsNavigatable(e)){const n=this.findFrameElement(e,t);return!!n&&n!=e.closest("turbo-frame")}return!1}findFrameElement(e,t){const n=(null==t?void 0:t.getAttribute("data-turbo-frame"))||e.getAttribute("data-turbo-frame");if(n&&"_top"!=n){const e=this.element.querySelector(`#${n}:not([disabled])`);if(e instanceof d)return e}}}class ce{constructor(e){this.restorationIdentifier=E(),this.restorationData={},this.started=!1,this.pageLoaded=!1,this.onPopState=e=>{if(this.shouldHandlePopState()){const{turbo:t}=e.state||{};if(t){this.location=new URL(window.location.href);const{restorationIdentifier:e}=t;this.restorationIdentifier=e,this.delegate.historyPoppedToLocationWithRestorationIdentifier(this.location,e)}}},this.onPageLoad=async e=>{await Promise.resolve(),this.pageLoaded=!0},this.delegate=e}start(){this.started||(addEventListener("popstate",this.onPopState,!1),addEventListener("load",this.onPageLoad,!1),this.started=!0,this.replace(new URL(window.location.href)))}stop(){this.started&&(removeEventListener("popstate",this.onPopState,!1),removeEventListener("load",this.onPageLoad,!1),this.started=!1)}push(e,t){this.update(history.pushState,e,t)}replace(e,t){this.update(history.replaceState,e,t)}update(e,t,n=E()){const r={turbo:{restorationIdentifier:n}};e.call(history,r,"",t.href),this.location=t,this.restorationIdentifier=n}getRestorationDataForIdentifier(e){return this.restorationData[e]||{}}updateRestorationData(e){const{restorationIdentifier:t}=this,n=this.restorationData[t];this.restorationData[t]=Object.assign(Object.assign({},n),e)}assumeControlOfScrollRestoration(){var e;this.previousScrollRestoration||(this.previousScrollRestoration=null!==(e=history.scrollRestoration)&&void 0!==e?e:"auto",history.scrollRestoration="manual")}relinquishControlOfScrollRestoration(){this.previousScrollRestoration&&(history.scrollRestoration=this.previousScrollRestoration,delete this.previousScrollRestoration)}shouldHandlePopState(){return this.pageIsLoaded()}pageIsLoaded(){return this.pageLoaded||"complete"==document.readyState}}class ue{constructor(e){this.delegate=e}proposeVisit(e,t={}){this.delegate.allowsVisitingLocationWithAction(e,t.action)&&(m(e,this.view.snapshot.rootLocation)?this.delegate.visitProposedToLocation(e,t):window.location.href=e.toString())}startVisit(e,t,n={}){this.stop(),this.currentVisit=new ie(this,h(e),t,Object.assign({referrer:this.location},n)),this.currentVisit.start()}submitForm(e,t){this.stop(),this.formSubmission=new P(this,e,t,!0),this.formSubmission.start()}stop(){this.formSubmission&&(this.formSubmission.stop(),delete this.formSubmission),this.currentVisit&&(this.currentVisit.cancel(),delete this.currentVisit)}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get history(){return this.delegate.history}formSubmissionStarted(e){"function"==typeof this.adapter.formSubmissionStarted&&this.adapter.formSubmissionStarted(e)}async formSubmissionSucceededWithResponse(e,t){if(e==this.formSubmission){const n=await t.responseHTML;if(n){const r=e.isSafe;r||this.view.clearSnapshotCache();const{statusCode:i,redirected:o}=t,s={action:this.getActionForFormSubmission(e),shouldCacheSnapshot:r,response:{statusCode:i,responseHTML:n,redirected:o}};this.proposeVisit(t.location,s)}}}async formSubmissionFailedWithResponse(e,t){const n=await t.responseHTML;if(n){const e=ee.fromHTMLString(n);t.serverError?await this.view.renderError(e,this.currentVisit):await this.view.renderPage(e,!1,!0,this.currentVisit),this.view.scrollToTop(),this.view.clearSnapshotCache()}}formSubmissionErrored(e,t){console.error(t)}formSubmissionFinished(e){"function"==typeof this.adapter.formSubmissionFinished&&this.adapter.formSubmissionFinished(e)}visitStarted(e){this.delegate.visitStarted(e)}visitCompleted(e){this.delegate.visitCompleted(e)}locationWithActionIsSamePage(e,t){const n=p(e),r=p(this.view.lastRenderedLocation),i="restore"===t&&void 0===n;return"replace"!==t&&v(e)===v(this.view.lastRenderedLocation)&&(i||null!=n&&n!==r)}visitScrolledToSamePageLocation(e,t){this.delegate.visitScrolledToSamePageLocation(e,t)}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}getActionForFormSubmission({submitter:e,formElement:t}){return D(e,t)||"advance"}}!function(e){e[e.initial=0]="initial",e[e.loading=1]="loading",e[e.interactive=2]="interactive",e[e.complete=3]="complete"}(re||(re={}));class de{constructor(e){this.stage=re.initial,this.started=!1,this.interpretReadyState=()=>{const{readyState:e}=this;"interactive"==e?this.pageIsInteractive():"complete"==e&&this.pageIsComplete()},this.pageWillUnload=()=>{this.delegate.pageWillUnload()},this.delegate=e}start(){this.started||(this.stage==re.initial&&(this.stage=re.loading),document.addEventListener("readystatechange",this.interpretReadyState,!1),addEventListener("pagehide",this.pageWillUnload,!1),this.started=!0)}stop(){this.started&&(document.removeEventListener("readystatechange",this.interpretReadyState,!1),removeEventListener("pagehide",this.pageWillUnload,!1),this.started=!1)}pageIsInteractive(){this.stage==re.loading&&(this.stage=re.interactive,this.delegate.pageBecameInteractive())}pageIsComplete(){this.pageIsInteractive(),this.stage==re.interactive&&(this.stage=re.complete,this.delegate.pageLoaded())}get readyState(){return document.readyState}}class he{constructor(e){this.started=!1,this.onScroll=()=>{this.updatePosition({x:window.pageXOffset,y:window.pageYOffset})},this.delegate=e}start(){this.started||(addEventListener("scroll",this.onScroll,!1),this.onScroll(),this.started=!0)}stop(){this.started&&(removeEventListener("scroll",this.onScroll,!1),this.started=!1)}updatePosition(e){this.delegate.scrollPositionChanged(e)}}class pe{render({fragment:e}){Z.preservingPermanentElements(this,function(e){const t=B(document.documentElement),n={};for(const r of t){const{id:t}=r;for(const i of e.querySelectorAll("turbo-stream")){const e=W(i.templateElement.content,t);e&&(n[t]=[r,e])}}return n}(e),(()=>document.documentElement.appendChild(e)))}enteringBardo(e,t){t.replaceWith(e.cloneNode(!0))}leavingBardo(){}}class fe{constructor(e){this.sources=new Set,this.started=!1,this.inspectFetchResponse=e=>{const t=function(e){var t;const n=null===(t=e.detail)||void 0===t?void 0:t.fetchResponse;if(n instanceof b)return n}(e);t&&function(e){var t;return(null!==(t=e.contentType)&&void 0!==t?t:"").startsWith(F.contentType)}(t)&&(e.preventDefault(),this.receiveMessageResponse(t))},this.receiveMessageEvent=e=>{this.started&&"string"==typeof e.data&&this.receiveMessageHTML(e.data)},this.delegate=e}start(){this.started||(this.started=!0,addEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}stop(){this.started&&(this.started=!1,removeEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}connectStreamSource(e){this.streamSourceIsConnected(e)||(this.sources.add(e),e.addEventListener("message",this.receiveMessageEvent,!1))}disconnectStreamSource(e){this.streamSourceIsConnected(e)&&(this.sources.delete(e),e.removeEventListener("message",this.receiveMessageEvent,!1))}streamSourceIsConnected(e){return this.sources.has(e)}async receiveMessageResponse(e){const t=await e.responseHTML;t&&this.receiveMessageHTML(t)}receiveMessageHTML(e){this.delegate.receivedMessageFromStream(F.wrap(e))}}class me extends K{static renderElement(e,t){const{documentElement:n,body:r}=document;n.replaceChild(t,r)}async render(){this.replaceHeadAndBody(),this.activateScriptElements()}replaceHeadAndBody(){const{documentElement:e,head:t}=document;e.replaceChild(this.newHead,t),this.renderElement(this.currentElement,this.newElement)}activateScriptElements(){for(const e of this.scriptElements){const t=e.parentNode;if(t){const n=y(e);t.replaceChild(n,e)}}}get newHead(){return this.newSnapshot.headSnapshot.element}get scriptElements(){return document.documentElement.querySelectorAll("script")}}class ve extends K{static renderElement(e,t){document.body&&t instanceof HTMLBodyElement?document.body.replaceWith(t):document.documentElement.appendChild(t)}get shouldRender(){return this.newSnapshot.isVisitable&&this.trackedElementsAreIdentical}get reloadReason(){return this.newSnapshot.isVisitable?this.trackedElementsAreIdentical?void 0:{reason:"tracked_element_mismatch"}:{reason:"turbo_visit_control_is_reload"}}async prepareToRender(){await this.mergeHead()}async render(){this.willRender&&await this.replaceBody()}finishRendering(){super.finishRendering(),this.isPreview||this.focusFirstAutofocusableElement()}get currentHeadSnapshot(){return this.currentSnapshot.headSnapshot}get newHeadSnapshot(){return this.newSnapshot.headSnapshot}get newElement(){return this.newSnapshot.element}async mergeHead(){const e=this.mergeProvisionalElements(),t=this.copyNewHeadStylesheetElements();this.copyNewHeadScriptElements(),await e,await t}async replaceBody(){await this.preservingPermanentElements((async()=>{this.activateNewBody(),await this.assignNewBody()}))}get trackedElementsAreIdentical(){return this.currentHeadSnapshot.trackedElementSignature==this.newHeadSnapshot.trackedElementSignature}async copyNewHeadStylesheetElements(){const e=[];for(const t of this.newHeadStylesheetElements)e.push(A(t)),document.head.appendChild(t);await Promise.all(e)}copyNewHeadScriptElements(){for(const e of this.newHeadScriptElements)document.head.appendChild(y(e))}async mergeProvisionalElements(){const e=[...this.newHeadProvisionalElements];for(const t of this.currentHeadProvisionalElements)this.isCurrentElementInElementList(t,e)||document.head.removeChild(t);for(const t of e)document.head.appendChild(t)}isCurrentElementInElementList(e,t){for(const[n,r]of t.entries()){if("TITLE"==e.tagName){if("TITLE"!=r.tagName)continue;if(e.innerHTML==r.innerHTML)return t.splice(n,1),!0}if(r.isEqualNode(e))return t.splice(n,1),!0}return!1}removeCurrentHeadProvisionalElements(){for(const e of this.currentHeadProvisionalElements)document.head.removeChild(e)}copyNewHeadProvisionalElements(){for(const e of this.newHeadProvisionalElements)document.head.appendChild(e)}activateNewBody(){document.adoptNode(this.newElement),this.activateNewBodyScriptElements()}activateNewBodyScriptElements(){for(const e of this.newBodyScriptElements){const t=y(e);e.replaceWith(t)}}async assignNewBody(){await this.renderElement(this.currentElement,this.newElement)}get newHeadStylesheetElements(){return this.newHeadSnapshot.getStylesheetElementsNotInSnapshot(this.currentHeadSnapshot)}get newHeadScriptElements(){return this.newHeadSnapshot.getScriptElementsNotInSnapshot(this.currentHeadSnapshot)}get currentHeadProvisionalElements(){return this.currentHeadSnapshot.provisionalElements}get newHeadProvisionalElements(){return this.newHeadSnapshot.provisionalElements}get newBodyScriptElements(){return this.newElement.querySelectorAll("script")}}class ge{constructor(e){this.keys=[],this.snapshots={},this.size=e}has(e){return g(e)in this.snapshots}get(e){if(this.has(e)){const t=this.read(e);return this.touch(e),t}}put(e,t){return this.write(e,t),this.touch(e),t}clear(){this.snapshots={}}read(e){return this.snapshots[g(e)]}write(e,t){this.snapshots[g(e)]=t}touch(e){const t=g(e),n=this.keys.indexOf(t);n>-1&&this.keys.splice(n,1),this.keys.unshift(t),this.trim()}trim(){for(const e of this.keys.splice(this.size))delete this.snapshots[e]}}class be extends j{constructor(){super(...arguments),this.snapshotCache=new ge(10),this.lastRenderedLocation=new URL(location.href),this.forceReloaded=!1}renderPage(e,t=!1,n=!0,r){const i=new ve(this.snapshot,e,ve.renderElement,t,n);return i.shouldRender?null==r||r.changeHistory():this.forceReloaded=!0,this.render(i)}renderError(e,t){null==t||t.changeHistory();const n=new me(this.snapshot,e,me.renderElement,!1);return this.render(n)}clearSnapshotCache(){this.snapshotCache.clear()}async cacheSnapshot(e=this.snapshot){if(e.isCacheable){this.delegate.viewWillCacheSnapshot();const{lastRenderedLocation:t}=this;await new Promise((e=>setTimeout((()=>e()),0)));const n=e.clone();return this.snapshotCache.put(t,n),n}}getCachedSnapshotForLocation(e){return this.snapshotCache.get(e)}get snapshot(){return ee.fromElement(this.element)}}class ye{constructor(e){this.selector="a[data-turbo-preload]",this.delegate=e}get snapshotCache(){return this.delegate.navigator.view.snapshotCache}start(){if("loading"===document.readyState)return document.addEventListener("DOMContentLoaded",(()=>{this.preloadOnLoadLinksForView(document.body)}));this.preloadOnLoadLinksForView(document.body)}preloadOnLoadLinksForView(e){for(const t of e.querySelectorAll(this.selector))this.preloadURL(t)}async preloadURL(e){const t=new URL(e.href);if(!this.snapshotCache.has(t))try{const e=await fetch(t.toString(),{headers:{"VND.PREFETCH":"true",Accept:"text/html"}}),n=await e.text(),r=ee.fromHTMLString(n);this.snapshotCache.put(t,r)}catch(e){}}}function we(e){Object.defineProperties(e,Se)}const Se={absoluteURL:{get(){return this.toString()}}},xe={after(){this.targetElements.forEach((e=>{var t;return null===(t=e.parentElement)||void 0===t?void 0:t.insertBefore(this.templateContent,e.nextSibling)}))},append(){this.removeDuplicateTargetChildren(),this.targetElements.forEach((e=>e.append(this.templateContent)))},before(){this.targetElements.forEach((e=>{var t;return null===(t=e.parentElement)||void 0===t?void 0:t.insertBefore(this.templateContent,e)}))},prepend(){this.removeDuplicateTargetChildren(),this.targetElements.forEach((e=>e.prepend(this.templateContent)))},remove(){this.targetElements.forEach((e=>e.remove()))},replace(){this.targetElements.forEach((e=>e.replaceWith(this.templateContent)))},update(){this.targetElements.forEach((e=>{e.innerHTML="",e.append(this.templateContent)}))}},ke=new class{constructor(){this.navigator=new ue(this),this.history=new ce(this),this.preloader=new ye(this),this.view=new be(this,document.documentElement),this.adapter=new se(this),this.pageObserver=new de(this),this.cacheObserver=new ae,this.linkClickObserver=new $(this,window),this.formSubmitObserver=new V(this,document),this.scrollObserver=new he(this),this.streamObserver=new fe(this),this.formLinkClickObserver=new U(this,document.documentElement),this.frameRedirector=new le(this,document.documentElement),this.streamMessageRenderer=new pe,this.drive=!0,this.enabled=!0,this.progressBarDelay=500,this.started=!1,this.formMode="on"}start(){this.started||(this.pageObserver.start(),this.cacheObserver.start(),this.formLinkClickObserver.start(),this.linkClickObserver.start(),this.formSubmitObserver.start(),this.scrollObserver.start(),this.streamObserver.start(),this.frameRedirector.start(),this.history.start(),this.preloader.start(),this.started=!0,this.enabled=!0)}disable(){this.enabled=!1}stop(){this.started&&(this.pageObserver.stop(),this.cacheObserver.stop(),this.formLinkClickObserver.stop(),this.linkClickObserver.stop(),this.formSubmitObserver.stop(),this.scrollObserver.stop(),this.streamObserver.stop(),this.frameRedirector.stop(),this.history.stop(),this.started=!1)}registerAdapter(e){this.adapter=e}visit(e,t={}){const n=t.frame?document.getElementById(t.frame):null;n instanceof d?(n.src=e.toString(),n.loaded):this.navigator.proposeVisit(h(e),t)}connectStreamSource(e){this.streamObserver.connectStreamSource(e)}disconnectStreamSource(e){this.streamObserver.disconnectStreamSource(e)}renderStreamMessage(e){this.streamMessageRenderer.render(F.wrap(e))}clearCache(){this.view.clearSnapshotCache()}setProgressBarDelay(e){this.progressBarDelay=e}setFormMode(e){this.formMode=e}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}historyPoppedToLocationWithRestorationIdentifier(e,t){this.enabled?this.navigator.startVisit(e,t,{action:"restore",historyChanged:!0}):this.adapter.pageInvalidated({reason:"turbo_disabled"})}scrollPositionChanged(e){this.history.updateRestorationData({scrollPosition:e})}willSubmitFormLinkToLocation(e,t){return this.elementIsNavigatable(e)&&m(t,this.snapshot.rootLocation)}submittedFormLinkToLocation(){}willFollowLinkToLocation(e,t,n){return this.elementIsNavigatable(e)&&m(t,this.snapshot.rootLocation)&&this.applicationAllowsFollowingLinkToLocation(e,t,n)}followedLinkToLocation(e,t){const n=this.getActionForLink(e),r=e.hasAttribute("data-turbo-stream");this.visit(t.href,{action:n,acceptsStreamResponse:r})}allowsVisitingLocationWithAction(e,t){return this.locationWithActionIsSamePage(e,t)||this.applicationAllowsVisitingLocation(e)}visitProposedToLocation(e,t){we(e),this.adapter.visitProposedToLocation(e,t)}visitStarted(e){e.acceptsStreamResponse||C(document.documentElement),we(e.location),e.silent||this.notifyApplicationAfterVisitingLocation(e.location,e.action)}visitCompleted(e){T(document.documentElement),this.notifyApplicationAfterPageLoad(e.getTimingMetrics())}locationWithActionIsSamePage(e,t){return this.navigator.locationWithActionIsSamePage(e,t)}visitScrolledToSamePageLocation(e,t){this.notifyApplicationAfterVisitingSamePageLocation(e,t)}willSubmitForm(e,t){const n=f(e,t);return this.submissionIsNavigatable(e,t)&&m(h(n),this.snapshot.rootLocation)}formSubmitted(e,t){this.navigator.submitForm(e,t)}pageBecameInteractive(){this.view.lastRenderedLocation=this.location,this.notifyApplicationAfterPageLoad()}pageLoaded(){this.history.assumeControlOfScrollRestoration()}pageWillUnload(){this.history.relinquishControlOfScrollRestoration()}receivedMessageFromStream(e){this.renderStreamMessage(e)}viewWillCacheSnapshot(){var e;(null===(e=this.navigator.currentVisit)||void 0===e?void 0:e.silent)||this.notifyApplicationBeforeCachingSnapshot()}allowsImmediateRender({element:e},t){const n=this.notifyApplicationBeforeRender(e,t),{defaultPrevented:r,detail:{render:i}}=n;return this.view.renderer&&i&&(this.view.renderer.renderElement=i),!r}viewRenderedSnapshot(e,t){this.view.lastRenderedLocation=this.history.location,this.notifyApplicationAfterRender()}preloadOnLoadLinksForView(e){this.preloader.preloadOnLoadLinksForView(e)}viewInvalidated(e){this.adapter.pageInvalidated(e)}frameLoaded(e){this.notifyApplicationAfterFrameLoad(e)}frameRendered(e,t){this.notifyApplicationAfterFrameRender(e,t)}applicationAllowsFollowingLinkToLocation(e,t,n){return!this.notifyApplicationAfterClickingLinkToLocation(e,t,n).defaultPrevented}applicationAllowsVisitingLocation(e){return!this.notifyApplicationBeforeVisitingLocation(e).defaultPrevented}notifyApplicationAfterClickingLinkToLocation(e,t,n){return w("turbo:click",{target:e,detail:{url:t.href,originalEvent:n},cancelable:!0})}notifyApplicationBeforeVisitingLocation(e){return w("turbo:before-visit",{detail:{url:e.href},cancelable:!0})}notifyApplicationAfterVisitingLocation(e,t){return w("turbo:visit",{detail:{url:e.href,action:t}})}notifyApplicationBeforeCachingSnapshot(){return w("turbo:before-cache")}notifyApplicationBeforeRender(e,t){return w("turbo:before-render",{detail:Object.assign({newBody:e},t),cancelable:!0})}notifyApplicationAfterRender(){return w("turbo:render")}notifyApplicationAfterPageLoad(e={}){return w("turbo:load",{detail:{url:this.location.href,timing:e}})}notifyApplicationAfterVisitingSamePageLocation(e,t){dispatchEvent(new HashChangeEvent("hashchange",{oldURL:e.toString(),newURL:t.toString()}))}notifyApplicationAfterFrameLoad(e){return w("turbo:frame-load",{target:e})}notifyApplicationAfterFrameRender(e,t){return w("turbo:frame-render",{detail:{fetchResponse:e},target:t,cancelable:!0})}submissionIsNavigatable(e,t){if("off"==this.formMode)return!1;{const n=!t||this.elementIsNavigatable(t);return"optin"==this.formMode?n&&null!=e.closest('[data-turbo="true"]'):n&&this.elementIsNavigatable(e)}}elementIsNavigatable(e){const t=O(e,"[data-turbo]"),n=O(e,"turbo-frame");return this.drive||n?!t||"false"!=t.getAttribute("data-turbo"):!!t&&"true"==t.getAttribute("data-turbo")}getActionForLink(e){return D(e)||"advance"}get snapshot(){return this.view.snapshot}},Ee=new class{constructor(e){this.session=e}clear(){this.session.clearCache()}resetCacheControl(){this.setCacheControl("")}exemptPageFromCache(){this.setCacheControl("no-cache")}exemptPageFromPreview(){this.setCacheControl("no-preview")}setCacheControl(e){!function(e,t){let n=I(e);n||(n=document.createElement("meta"),n.setAttribute("name",e),document.head.appendChild(n)),n.setAttribute("content",t)}("turbo-cache-control",e)}}(ke),{navigator:_e}=ke;function Ce(){ke.start()}function Te(e,t){ke.visit(e,t)}function Ae(e){ke.connectStreamSource(e)}function Le(e){ke.disconnectStreamSource(e)}var De=Object.freeze({__proto__:null,navigator:_e,session:ke,cache:Ee,PageRenderer:ve,PageSnapshot:ee,FrameRenderer:Y,start:Ce,registerAdapter:function(e){ke.registerAdapter(e)},visit:Te,connectStreamSource:Ae,disconnectStreamSource:Le,renderStreamMessage:function(e){ke.renderStreamMessage(e)},clearCache:function(){console.warn("Please replace `Turbo.clearCache()` with `Turbo.cache.clear()`. The top-level function is deprecated and will be removed in a future version of Turbo.`"),ke.clearCache()},setProgressBarDelay:function(e){ke.setProgressBarDelay(e)},setConfirmMethod:function(e){P.confirmMethod=e},setFormMode:function(e){ke.setFormMode(e)},StreamActions:xe});class Ie extends Error{}function Re(e){if(null!=e){const t=document.getElementById(e);if(t instanceof d)return t}}function Oe(e,t){if(e){const r=e.getAttribute("src");if(null!=r&&null!=t&&(n=t,h(r).href==h(n).href))throw new Error(`Matching element has a source URL which references itself`);if(e.ownerDocument!==document&&(e=document.importNode(e,!0)),e instanceof d)return e.connectedCallback(),e.disconnectedCallback(),e}var n}class Me extends HTMLElement{static async renderElement(e){await e.performAction()}async connectedCallback(){try{await this.render()}catch(e){console.error(e)}finally{this.disconnect()}}async render(){var e;return null!==(e=this.renderPromise)&&void 0!==e?e:this.renderPromise=(async()=>{const e=this.beforeRenderEvent;this.dispatchEvent(e)&&(await S(),await e.detail.render(this))})()}disconnect(){try{this.remove()}catch(e){}}removeDuplicateTargetChildren(){this.duplicateChildren.forEach((e=>e.remove()))}get duplicateChildren(){var e;const t=this.targetElements.flatMap((e=>[...e.children])).filter((e=>!!e.id)),n=[...(null===(e=this.templateContent)||void 0===e?void 0:e.children)||[]].filter((e=>!!e.id)).map((e=>e.id));return t.filter((e=>n.includes(e.id)))}get performAction(){if(this.action){const e=xe[this.action];if(e)return e;this.raise("unknown action")}this.raise("action attribute is missing")}get targetElements(){return this.target?this.targetElementsById:this.targets?this.targetElementsByQuery:void this.raise("target or targets attribute is missing")}get templateContent(){return this.templateElement.content.cloneNode(!0)}get templateElement(){if(null===this.firstElementChild){const e=this.ownerDocument.createElement("template");return this.appendChild(e),e}if(this.firstElementChild instanceof HTMLTemplateElement)return this.firstElementChild;this.raise("first child element must be a