( () => {
    "use strict";
    var e = {
        540: e => {
            e.exports = function(e) {
                var n = document.createElement("style");
                return e.setAttributes(n, e.attributes),
                e.insert(n, e.options),
                n
            }
        }
        ,
        1113: e => {
            e.exports = function(e, n) {
                if (n.styleSheet)
                    n.styleSheet.cssText = e;
                else {
                    for (; n.firstChild; )
                        n.removeChild(n.firstChild);
                    n.appendChild(document.createTextNode(e))
                }
            }
        }
        ,
        1601: e => {
            e.exports = function(e) {
                return e[1]
            }
        }
        ,
        4503: (e, n, t) => {
            t.d(n, {
                A: () => c
            });
            var r = t(1601)
              , o = t.n(r)
              , a = t(6314)
              , i = t.n(a)()(o());
            i.push([e.id, "#error-screen {\n\tdisplay: flex;\n\tflex-direction: column;\n\tpadding: 10px;\n\tbox-sizing: border-box;\n\tposition: absolute;\n\tleft: 0;\n\ttop: 0;\n\twidth: 100%;\n\theight: 100%;\n\tbackground-color: var(--surface-color);\n}\n\n#error-screen > .title {\n\tfont-size: 28px;\n\tcolor: var(--text-color);\n}\n\n#error-screen > .version, #error-screen > .platform, #error-screen > .user-agent {\n\tfont-size: 20px;\n\tcolor: var(--text-color);\n\topacity: 0.5;\n}\n\n#error-screen > textarea {\n\theight: 100%;\n\tflex-grow: 1;\n\tbackground-color: var(--surface-tertiary-color);\n\tborder: none;\n\tresize: none;\n\tcolor: var(--text-color);\n\tword-break: break-word;\n\tfont-size: 20px;\n}\n#error-screen > textarea:focus-visible {\n\toutline: none;\n}\n", ""]);
            const c = i
        }
        ,
        5056: (e, n, t) => {
            e.exports = function(e) {
                var n = t.nc;
                n && e.setAttribute("nonce", n)
            }
        }
        ,
        5072: e => {
            var n = [];
            function t(e) {
                for (var t = -1, r = 0; r < n.length; r++)
                    if (n[r].identifier === e) {
                        t = r;
                        break
                    }
                return t
            }
            function r(e, r) {
                for (var a = {}, i = [], c = 0; c < e.length; c++) {
                    var s = e[c]
                      , l = r.base ? s[0] + r.base : s[0]
                      , u = a[l] || 0
                      , d = "".concat(l, " ").concat(u);
                    a[l] = u + 1;
                    var p = t(d)
                      , f = {
                        css: s[1],
                        media: s[2],
                        sourceMap: s[3],
                        supports: s[4],
                        layer: s[5]
                    };
                    if (-1 !== p)
                        n[p].references++,
                        n[p].updater(f);
                    else {
                        var v = o(f, r);
                        r.byIndex = c,
                        n.splice(c, 0, {
                            identifier: d,
                            updater: v,
                            references: 1
                        })
                    }
                    i.push(d)
                }
                return i
            }
            function o(e, n) {
                var t = n.domAPI(n);
                t.update(e);
                return function(n) {
                    if (n) {
                        if (n.css === e.css && n.media === e.media && n.sourceMap === e.sourceMap && n.supports === e.supports && n.layer === e.layer)
                            return;
                        t.update(e = n)
                    } else
                        t.remove()
                }
            }
            e.exports = function(e, o) {
                var a = r(e = e || [], o = o || {});
                return function(e) {
                    e = e || [];
                    for (var i = 0; i < a.length; i++) {
                        var c = t(a[i]);
                        n[c].references--
                    }
                    for (var s = r(e, o), l = 0; l < a.length; l++) {
                        var u = t(a[l]);
                        0 === n[u].references && (n[u].updater(),
                        n.splice(u, 1))
                    }
                    a = s
                }
            }
        }
        ,
        6314: e => {
            e.exports = function(e) {
                var n = [];
                return n.toString = function() {
                    return this.map((function(n) {
                        var t = ""
                          , r = void 0 !== n[5];
                        return n[4] && (t += "@supports (".concat(n[4], ") {")),
                        n[2] && (t += "@media ".concat(n[2], " {")),
                        r && (t += "@layer".concat(n[5].length > 0 ? " ".concat(n[5]) : "", " {")),
                        t += e(n),
                        r && (t += "}"),
                        n[2] && (t += "}"),
                        n[4] && (t += "}"),
                        t
                    }
                    )).join("")
                }
                ,
                n.i = function(e, t, r, o, a) {
                    "string" == typeof e && (e = [[null, e, void 0]]);
                    var i = {};
                    if (r)
                        for (var c = 0; c < this.length; c++) {
                            var s = this[c][0];
                            null != s && (i[s] = !0)
                        }
                    for (var l = 0; l < e.length; l++) {
                        var u = [].concat(e[l]);
                        r && i[u[0]] || (void 0 !== a && (void 0 === u[5] || (u[1] = "@layer".concat(u[5].length > 0 ? " ".concat(u[5]) : "", " {").concat(u[1], "}")),
                        u[5] = a),
                        t && (u[2] ? (u[1] = "@media ".concat(u[2], " {").concat(u[1], "}"),
                        u[2] = t) : u[2] = t),
                        o && (u[4] ? (u[1] = "@supports (".concat(u[4], ") {").concat(u[1], "}"),
                        u[4] = o) : u[4] = "".concat(o)),
                        n.push(u))
                    }
                }
                ,
                n
            }
        }
        ,
        7659: e => {
            var n = {};
            e.exports = function(e, t) {
                var r = function(e) {
                    if (void 0 === n[e]) {
                        var t = document.querySelector(e);
                        if (window.HTMLIFrameElement && t instanceof window.HTMLIFrameElement)
                            try {
                                t = t.contentDocument.head
                            } catch (e) {
                                t = null
                            }
                        n[e] = t
                    }
                    return n[e]
                }(e);
                if (!r)
                    throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");
                r.appendChild(t)
            }
        }
        ,
        7825: e => {
            e.exports = function(e) {
                if ("undefined" == typeof document)
                    return {
                        update: function() {},
                        remove: function() {}
                    };
                var n = e.insertStyleElement(e);
                return {
                    update: function(t) {
                        !function(e, n, t) {
                            var r = "";
                            t.supports && (r += "@supports (".concat(t.supports, ") {")),
                            t.media && (r += "@media ".concat(t.media, " {"));
                            var o = void 0 !== t.layer;
                            o && (r += "@layer".concat(t.layer.length > 0 ? " ".concat(t.layer) : "", " {")),
                            r += t.css,
                            o && (r += "}"),
                            t.media && (r += "}"),
                            t.supports && (r += "}");
                            var a = t.sourceMap;
                            a && "undefined" != typeof btoa && (r += "\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a)))), " */")),
                            n.styleTagTransform(r, e, n.options)
                        }(n, e, t)
                    },
                    remove: function() {
                        !function(e) {
                            if (null === e.parentNode)
                                return !1;
                            e.parentNode.removeChild(e)
                        }(n)
                    }
                }
            }
        }
    }
      , n = {};
    function t(r) {
        var o = n[r];
        if (void 0 !== o)
            return o.exports;
        var a = n[r] = {
            id: r,
            exports: {}
        };
        return e[r](a, a.exports, t),
        a.exports
    }
    t.n = e => {
        var n = e && e.__esModule ? () => e.default : () => e;
        return t.d(n, {
            a: n
        }),
        n
    }
    ,
    t.d = (e, n) => {
        for (var r in n)
            t.o(n, r) && !t.o(e, r) && Object.defineProperty(e, r, {
                enumerable: !0,
                get: n[r]
            })
    }
    ,
    t.o = (e, n) => Object.prototype.hasOwnProperty.call(e, n),
    t.nc = void 0;
    var r = t(5072)
      , o = t.n(r)
      , a = t(7825)
      , i = t.n(a)
      , c = t(7659)
      , s = t.n(c)
      , l = t(5056)
      , u = t.n(l)
      , d = t(540)
      , p = t.n(d)
      , f = t(1113)
      , v = t.n(f)
      , m = t(4503)
      , h = {};
    h.styleTagTransform = v(),
    h.setAttributes = u(),
    h.insert = s().bind(null, "head"),
    h.domAPI = i(),
    h.insertStyleElement = p();
    o()(m.A, h);
    m.A && m.A.locals && m.A.locals;
    const g = JSON.parse('{"rE":"0.5.2","l$":{"r":1,"M":4}}');
    const x = "kodub"
      , y = g.l$.r;
    if (!Number.isSafeInteger(y) || y < 1)
        throw new Error("package.json beta version property must be a positive integer");
    let b = "";
    const w = g.rE + b
      , C = g.l$.M;
    if (!Number.isSafeInteger(C) || C < 1)
        throw new Error("package.json beta physicsVersion property must be a positive integer");
    let E = null;
    function A(e) {
        if (null == E) {
            const e = document.createElement("div");
            e.id = "error-screen",
            document.body.appendChild(e);
            const n = document.createElement("div");
            n.className = "title",
            n.textContent = "Oh no! PolyTrack encountered an unexpected error!",
            e.appendChild(n);
            const t = document.createElement("div");
            t.className = "version",
            t.textContent = "Version: " + w,
            e.appendChild(t);
            const r = document.createElement("div");
            r.className = "platform",
            r.textContent = "Platform: " + x,
            e.appendChild(r);
            const o = document.createElement("div");
            o.className = "user-agent",
            o.textContent = "User Agent: " + navigator.userAgent,
            e.appendChild(o);
            const a = document.createElement("textarea");
            a.readOnly = !0,
            e.appendChild(a),
            E = {
                element: e,
                textArea: a
            }
        }
        E.textArea.value = e + "\n" + E.textArea.value
    }
    window.addEventListener("error", (e => {
        A(`${e.message}\nSource: ${e.filename}\nLine: ${e.lineno.toString()}\nColumn: ${e.colno.toString()}\n`)
    }
    )),
    window.addEventListener("unhandledrejection", (e => {
        let n;
        e.reason instanceof Error ? (n = `Unhandled Rejection:\n${e.reason.message}`,
        null != e.reason.stack && (n += `\nStack:\n${e.reason.stack}`)) : n = `Unhandled Rejection:\n${String(e.reason)}`,
        A(n)
    }
    ))
}
)();
