From 471e23316114a6a9bf0b30940353090c64bf68f9 Mon Sep 17 00:00:00 2001 From: Viacheslav Fateev Date: Thu, 20 Aug 2026 07:33:47 +0300 Subject: [PATCH 1/2] Improve collections loading performance --- ...t.BmnOlML_.js => UpdatePrompt.DQlMOewA.js} | 5860 ++++---- openapi-plugin/resources/web/capture.js | 4 +- openapi-plugin/resources/web/config.js | 6 +- openapi-plugin/resources/web/environment.js | 16 +- ....YVoWfg3P.js => freemiumd-api.CctZu0yp.js} | 2 +- .../resources/web/index.BXf_Hj-1.js | 6493 +++++++++ .../resources/web/index.CRy0HWMP.js | 7509 ---------- .../resources/web/platform-api.BtY3-lHu.js | 356 + .../resources/web/platform-api.xQ9SQy05.js | 331 - ....js => rtk-query-react.modern.DVdYp0Is.js} | 1 + openapi-plugin/resources/web/scan.js | 7495 ++++++---- .../resources/web/scanconf-graphql.js | 14 +- openapi-plugin/resources/web/scanconf.js | 6 +- openapi-plugin/resources/web/tags.js | 1018 +- openapi-plugin/resources/web/tryit.js | 16 +- .../resources/web/variables.-zE0Ry6h.js | 12158 ---------------- .../resources/web/variables.CfsUBZ9t.js | 9842 +++++++++++++ .../xliic/openapi/graphql/GraphQlService.java | 1 - .../xliic/openapi/platform/PlatformAPIs.java | 24 +- .../callback/PlatformCollectionCallback.java | 7 +- .../platform/tree/PlatformAsyncTreeModel.java | 64 +- .../PlatformFavoriteCollectionsHandler.java | 106 + .../tree/actions/PlatformFilterAPIAction.java | 2 +- .../PlatformFilterCollectionAction.java | 12 +- .../actions/PlatformFilterRemoveAction.java | 6 +- .../mouse/PlatformLeftMouseClickHandler.java | 6 +- .../tree/node/PlatformCollection.java | 76 +- .../platform/tree/node/PlatformRootCloud.java | 49 +- .../tree/node/PlatformRootFavorite.java | 10 + .../platform/tree/node/core/Filter.java | 8 +- .../platform/tree/node/core/Paginator.java | 15 +- .../node/decorator/PlatformDecorator.java | 4 + .../decorator/PlatformErrorDecorator.java | 2 +- .../decorator/PlatformFilterDecorator.java | 2 +- .../decorator/PlatformLoadMoreDecorator.java | 2 +- .../decorator/PlatformLoadingDecorator.java | 2 +- .../tree/utils/PlatformCollectionUtils.java | 89 +- .../platform/tree/utils/PlatformUtils.java | 79 +- 38 files changed, 24914 insertions(+), 26779 deletions(-) rename openapi-plugin/resources/web/{UpdatePrompt.BmnOlML_.js => UpdatePrompt.DQlMOewA.js} (85%) rename openapi-plugin/resources/web/{freemiumd-api.YVoWfg3P.js => freemiumd-api.CctZu0yp.js} (96%) create mode 100644 openapi-plugin/resources/web/index.BXf_Hj-1.js delete mode 100644 openapi-plugin/resources/web/index.CRy0HWMP.js create mode 100644 openapi-plugin/resources/web/platform-api.BtY3-lHu.js delete mode 100644 openapi-plugin/resources/web/platform-api.xQ9SQy05.js rename openapi-plugin/resources/web/{rtk-query-react.modern.kJqw8Vn6.js => rtk-query-react.modern.DVdYp0Is.js} (99%) delete mode 100644 openapi-plugin/resources/web/variables.-zE0Ry6h.js create mode 100644 openapi-plugin/resources/web/variables.CfsUBZ9t.js create mode 100644 openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformFavoriteCollectionsHandler.java create mode 100644 openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformDecorator.java diff --git a/openapi-plugin/resources/web/UpdatePrompt.BmnOlML_.js b/openapi-plugin/resources/web/UpdatePrompt.DQlMOewA.js similarity index 85% rename from openapi-plugin/resources/web/UpdatePrompt.BmnOlML_.js rename to openapi-plugin/resources/web/UpdatePrompt.DQlMOewA.js index 9c76d46d..61a1529e 100644 --- a/openapi-plugin/resources/web/UpdatePrompt.BmnOlML_.js +++ b/openapi-plugin/resources/web/UpdatePrompt.DQlMOewA.js @@ -1,59 +1,59 @@ -import { j as c, f as A, H as kt, c as Wt, i as Pf, u as $c, a as $f, p as Df, I as zf, r as If, t as Af, l as Nf, b as Rf, e as E, T as w, S as wt, J as Mf, K as Lf, L as Ff, M as Dn, x as qf, y as Bf, z as Uf, A as Hf, D as Vf, B as Wf, C as Kf, Q as Dc, O as Gf, E as Xf, m as zc, R as ln, U as yi, V as Yf, W as Qf, w as Jf } from "./TriangleExclamation.BLKAXJ8l.js"; -import { q as Zf, y as Zr, z as eh, x as th, t as Ic, r as Ac, o as St, f as Zi, A as Nc, B as sr, C as Rc, F as Mc, i as Lc, d as Xn, G as Fc, H as xa, I as qc, J as nh, K as rh, D as Bc, E as oh, g as ih, j as sh } from "./variables.-zE0Ry6h.js"; -import { d as ah, F as lh, a as ie, b as vn, u as ar, c as vo } from "./index.esm.MIM2ge_D.js"; -import { S as ch, D as bn } from "./DescriptionTooltip.Dgobq1Hx.js"; -import { l as uh, e as dh, c as eo, s as fh } from "./index.CRy0HWMP.js"; -import { e as hh, o as Uc, s as qn, F as xn, b as Qo } from "./schemas.BH6uGBRD.js"; +import { j as c, f as A, H as wt, c as Wt, i as Of, u as Pc, a as Pf, p as $f, I as Df, r as zf, t as If, l as Af, b as Nf, e as E, T as w, S as St, J as Rf, K as Mf, L as Lf, M as Dn, x as Ff, y as qf, z as Bf, A as Uf, D as Hf, B as Vf, C as Wf, Q as $c, O as Kf, E as Gf, m as Dc, R as ln, U as mi, V as Xf, W as Yf, w as Qf } from "./TriangleExclamation.BLKAXJ8l.js"; +import { a as Jf, e as Zf, l as Re, s as eh } from "./index.BXf_Hj-1.js"; +import { d as th, F as nh, a as ie, b as vn, u as sr, c as yo } from "./index.esm.MIM2ge_D.js"; +import { S as rh, D as bn } from "./DescriptionTooltip.Dgobq1Hx.js"; +import { o as oh, x as Zr, y as ih, v as sh, r as zc, q as Ic, f as Ji, z as Ac, A as ar, B as Nc, C as Rc, i as Mc, d as Xn, F as Lc, G as ba, H as Fc, I as ah, J as lh, D as qc, E as ch, g as uh, j as dh } from "./variables.CfsUBZ9t.js"; +import { e as fh, o as Bc, s as qn, F as xn, b as Yo } from "./schemas.BH6uGBRD.js"; import { T as kn } from "./Tabs.BfQDe6I2.js"; -import { C as wn, B as Sn, a as to, T as Hc } from "./CollapsibleCard.BWECYxhA.js"; +import { C as wn, B as Sn, a as eo, T as Uc } from "./CollapsibleCard.BWECYxhA.js"; import { S as _n } from "./TrashCan.DYWcjlk_.js"; -import { E as no } from "./Banner.BZe2qI8d.js"; -import { S as bo } from "./AngleDown.DBLEm0qt.js"; -import { S as ph } from "./AngleUp.d5m1Xwr8.js"; -import { s as gh, g as mh, S as yh, M as Vc, a as vh, b as bh, c as xh, d as kh, C as ka, e as wa } from "./GeneralError.Dvjq_B8a.js"; -import { S as Wc, P as wh } from "./ProgressButton.BXekI9TY.js"; -import { c as Kc, a as Sh, A as _h, b as Ch, d as jh, G as Eh, L as Th, e as Oh, f as Ph, g as $h, h as Dh, i as zh, S as Ih, j as Ah, k as Nh, l as Rh } from "./index.D2cL1X0y.js"; +import { E as to } from "./Banner.BZe2qI8d.js"; +import { S as vo } from "./AngleDown.DBLEm0qt.js"; +import { S as hh } from "./AngleUp.d5m1Xwr8.js"; +import { s as ph, g as gh, S as mh, M as Hc, a as yh, b as vh, c as bh, d as xh, C as xa, e as ka } from "./GeneralError.Dvjq_B8a.js"; +import { S as Vc, P as kh } from "./ProgressButton.BXekI9TY.js"; +import { c as Wc, a as wh, A as Sh, b as _h, d as Ch, G as jh, L as Eh, e as Th, f as Oh, g as Ph, h as $h, i as Dh, S as zh, j as Ih, k as Ah, l as Nh } from "./index.D2cL1X0y.js"; import { I as Pe } from "./Input.BQnalfHf.js"; -import { T as Mh } from "./Textarea.7FvXKGUa.js"; -import { S as xo } from "./ExclamationCircle.2wqwVNIx.js"; -import { a as es, u as Gc } from "./downshift.esm.CwBPPnfz.js"; -import { l as Lh, p as Fh, u as qh, c as Bh, b as Uh, d as Hh, e as Vh, S as Xc } from "./slice.CZpj5Zis.js"; -import { a as Wh, S as Kh } from "./SearchSidebar.CtwbvK_x.js"; -import { a as Gh, S as Xh } from "./Switch.BqeA-dAP.js"; -import { n as We } from "./coerce.FZdHX8I_.js"; +import { T as Rh } from "./Textarea.7FvXKGUa.js"; +import { S as bo } from "./ExclamationCircle.2wqwVNIx.js"; +import { a as Zi, u as Kc } from "./downshift.esm.CwBPPnfz.js"; +import { l as Mh, p as Lh, u as Fh, c as qh, b as Bh, d as Uh, e as Hh, S as Gc } from "./slice.CZpj5Zis.js"; +import { a as Vh, S as Wh } from "./SearchSidebar.CtwbvK_x.js"; +import { a as Kh, S as Gh } from "./Switch.BqeA-dAP.js"; +import { n as Ke } from "./coerce.FZdHX8I_.js"; import { S as lr } from "./index.BZD5e9Cu.js"; -import { l as Yh, c as Qh } from "./slice.s4_w0CJL.js"; -import { c as Jh } from "./listener.BNWHQqef.js"; -const Yc = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M192 456c0 13.3-10.7 24-24 24H96c-53.02 0-96-42.98-96-96V128c0-53.02 42.98-96 96-96h72c13.3 0 24 10.74 24 24 0 13.25-10.7 24-24 24H96c-26.4 0-48 21.6-48 48v256c0 26.4 21.6 48 48 48h72c13.3 0 24 10.7 24 24m313.5-216.4-127.1-136c-9.094-9.688-24.28-10.12-33.91-1.031-9.656 9.062-10.12 24.25-1.031 33.91L432.4 232H183.1c-12.4 0-23.1 10.8-23.1 24s10.75 24 23.1 24h248.4l-89.92 95.56c-9.094 9.656-8.625 24.84 1.031 33.91C348.2 413.8 354.1 416 359.1 416c6.375 0 12.75-2.531 17.47-7.562l127.1-136C514.2 263.2 514.2 248.8 505.5 239.6" }) }), Qc = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 576 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M200 32h-80c-30.93 0-56 25.07-56 56v77.5a39.84 39.84 0 0 1-11.67 28.17L7 239c-4.5 4.5-7 10.6-7 17 0 6.375 2.5 12.5 7 17l45.33 45.33A39.78 39.78 0 0 1 64 346.5V424c0 30.9 25.07 56 56 56h80c13.3 0 24-10.7 24-24s-10.7-24-24-24h-80c-4.4 0-8-3.6-8-8v-77.5c0-23.44-9.337-45.91-25.95-62.45L57.88 256l28.18-28.05C102.7 211.4 112 188.9 112 165.5V88c0-4.4 3.6-8 8-8h80c13.3 0 24-10.75 24-24s-10.7-24-24-24m369 207-45.33-45.33A39.78 39.78 0 0 1 512 165.5V88c0-30.93-25.1-56-56-56h-80c-13.3 0-24 10.75-24 23.1S362.7 80 375.1 80H456c4.4 0 8 3.6 8 8v77.5c0 23.37 9.284 45.78 25.81 62.31L517.1 256l-28.19 28.19C473.3 300.7 464 323.1 464 346.5V424c0 4.4-3.6 8-8 8h-80c-13.3 0-24 10.7-24 23.1s10.7 24.9 23.1 24.9H456c30.93 0 56-25.07 56-56v-77.5a39.84 39.84 0 0 1 11.67-28.17L569 273c4.5-4.5 7-10.6 7-17s-2.5-12.5-7-17" }) }), Jc = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M243.8 339.8c-10.9 10.9-28.7 10.9-39.6 0l-64-64c-10.9-10.9-10.9-28.7 0-39.6s28.7-10.9 39.6 0l44.2 44.2 108.2-108.2c10.9-10.9 28.7-10.9 39.6 0s10.9 28.7 0 39.6zM512 256c0 141.4-114.6 256-256 256S0 397.4 0 256 114.6 0 256 0s256 114.6 256 256M256 48C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48" }) }), Zh = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M384 336H192c-8.8 0-16-7.2-16-16V64c0-8.8 7.2-16 16-16h140.1l67.9 67.9V320c0 8.8-7.2 16-16 16m-192 48h192c35.3 0 64-28.7 64-64V115.9c0-12.7-5.1-24.9-14.1-33.9l-67.8-67.9c-9-9-21.2-14.1-33.9-14.1H192c-35.3 0-64 28.7-64 64v256c0 35.3 28.7 64 64 64M64 128c-35.3 0-64 28.7-64 64v256c0 35.3 28.7 64 64 64h192c35.3 0 64-28.7 64-64v-32h-48v32c0 8.8-7.2 16-16 16H64c-8.8 0-16-7.2-16-16V192c0-8.8 7.2-16 16-16h32v-48z" }) }), ep = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M336 144c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32m0 208c-9.5 0-18.8-.7-27.9-2.2l-28 26.3c-3.6 5.4-9.7 7.9-16.1 7.9h-40v40c0 13.3-10.7 24-24 24h-40v40c0 13.3-10.7 24-24 24H24c-13.25 0-24-10.7-24-24V376c0-6.4 2.529-12.5 7.029-17L162.2 203.9c-1.4-9.1-2.2-18.4-2.2-27.9C160 78.8 238.8 0 336 0s176 78.8 176 176-78.8 176-176 176m0-48c70.7 0 128-57.3 128-128S406.7 48 336 48s-128 57.3-128 128c0 6.9.5 13.7 1.6 20.3l3.8 24.2L47.1 385.9V464h64v-64h64v-64h79l37.4-37.4 24.2 3.8c6.6 1.1 13.4 1.6 20.3 1.6" }) }), tp = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 384 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M24.52 38.13a48.02 48.02 0 0 1 48.51.91L361 215c14.3 8.8 23 24.3 23 41s-8.7 32.2-23 40.1l-287.97 176c-14.82 9.9-33.37 10.3-48.51 1.8A48.02 48.02 0 0 1 0 432V80a48.02 48.02 0 0 1 24.52-41.87M48 432l288-176L48 80z" }) }), np = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M432 256c0 13.3-10.7 24-24 24H248v160c0 13.25-10.75 24.01-24 24.01S200 453.3 200 440V280H40c-13.25 0-24-10.74-24-23.99C16 242.8 26.75 232 40 232h160V72c0-13.25 10.75-23.99 24-23.99S248 58.75 248 72v160h160c13.3 0 24 10.8 24 24" }) }), rp = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M64 80c-8.8 0-16 7.2-16 16v320c0 8.8 7.2 16 16 16h320c8.8 0 16-7.2 16-16V96c0-8.8-7.2-16-16-16zM0 96c0-35.3 28.7-64 64-64h320c35.3 0 64 28.7 64 64v320c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64zm200 248v-64h-64c-13.3 0-24-10.7-24-24s10.7-24 24-24h64v-64c0-13.3 10.7-24 24-24s24 10.7 24 24v64h64c13.3 0 24 10.7 24 24s-10.7 24-24 24h-64v64c0 13.3-10.7 24-24 24s-24-10.7-24-24" }) }), LC = { +import { l as Xh, c as Yh } from "./slice.s4_w0CJL.js"; +import { c as Qh } from "./listener.BNWHQqef.js"; +const Xc = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M192 456c0 13.3-10.7 24-24 24H96c-53.02 0-96-42.98-96-96V128c0-53.02 42.98-96 96-96h72c13.3 0 24 10.74 24 24 0 13.25-10.7 24-24 24H96c-26.4 0-48 21.6-48 48v256c0 26.4 21.6 48 48 48h72c13.3 0 24 10.7 24 24m313.5-216.4-127.1-136c-9.094-9.688-24.28-10.12-33.91-1.031-9.656 9.062-10.12 24.25-1.031 33.91L432.4 232H183.1c-12.4 0-23.1 10.8-23.1 24s10.75 24 23.1 24h248.4l-89.92 95.56c-9.094 9.656-8.625 24.84 1.031 33.91C348.2 413.8 354.1 416 359.1 416c6.375 0 12.75-2.531 17.47-7.562l127.1-136C514.2 263.2 514.2 248.8 505.5 239.6" }) }), Yc = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 576 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M200 32h-80c-30.93 0-56 25.07-56 56v77.5a39.84 39.84 0 0 1-11.67 28.17L7 239c-4.5 4.5-7 10.6-7 17 0 6.375 2.5 12.5 7 17l45.33 45.33A39.78 39.78 0 0 1 64 346.5V424c0 30.9 25.07 56 56 56h80c13.3 0 24-10.7 24-24s-10.7-24-24-24h-80c-4.4 0-8-3.6-8-8v-77.5c0-23.44-9.337-45.91-25.95-62.45L57.88 256l28.18-28.05C102.7 211.4 112 188.9 112 165.5V88c0-4.4 3.6-8 8-8h80c13.3 0 24-10.75 24-24s-10.7-24-24-24m369 207-45.33-45.33A39.78 39.78 0 0 1 512 165.5V88c0-30.93-25.1-56-56-56h-80c-13.3 0-24 10.75-24 23.1S362.7 80 375.1 80H456c4.4 0 8 3.6 8 8v77.5c0 23.37 9.284 45.78 25.81 62.31L517.1 256l-28.19 28.19C473.3 300.7 464 323.1 464 346.5V424c0 4.4-3.6 8-8 8h-80c-13.3 0-24 10.7-24 23.1s10.7 24.9 23.1 24.9H456c30.93 0 56-25.07 56-56v-77.5a39.84 39.84 0 0 1 11.67-28.17L569 273c4.5-4.5 7-10.6 7-17s-2.5-12.5-7-17" }) }), Qc = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M243.8 339.8c-10.9 10.9-28.7 10.9-39.6 0l-64-64c-10.9-10.9-10.9-28.7 0-39.6s28.7-10.9 39.6 0l44.2 44.2 108.2-108.2c10.9-10.9 28.7-10.9 39.6 0s10.9 28.7 0 39.6zM512 256c0 141.4-114.6 256-256 256S0 397.4 0 256 114.6 0 256 0s256 114.6 256 256M256 48C141.1 48 48 141.1 48 256s93.1 208 208 208 208-93.1 208-208S370.9 48 256 48" }) }), Jh = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M384 336H192c-8.8 0-16-7.2-16-16V64c0-8.8 7.2-16 16-16h140.1l67.9 67.9V320c0 8.8-7.2 16-16 16m-192 48h192c35.3 0 64-28.7 64-64V115.9c0-12.7-5.1-24.9-14.1-33.9l-67.8-67.9c-9-9-21.2-14.1-33.9-14.1H192c-35.3 0-64 28.7-64 64v256c0 35.3 28.7 64 64 64M64 128c-35.3 0-64 28.7-64 64v256c0 35.3 28.7 64 64 64h192c35.3 0 64-28.7 64-64v-32h-48v32c0 8.8-7.2 16-16 16H64c-8.8 0-16-7.2-16-16V192c0-8.8 7.2-16 16-16h32v-48z" }) }), Zh = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M336 144c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32m0 208c-9.5 0-18.8-.7-27.9-2.2l-28 26.3c-3.6 5.4-9.7 7.9-16.1 7.9h-40v40c0 13.3-10.7 24-24 24h-40v40c0 13.3-10.7 24-24 24H24c-13.25 0-24-10.7-24-24V376c0-6.4 2.529-12.5 7.029-17L162.2 203.9c-1.4-9.1-2.2-18.4-2.2-27.9C160 78.8 238.8 0 336 0s176 78.8 176 176-78.8 176-176 176m0-48c70.7 0 128-57.3 128-128S406.7 48 336 48s-128 57.3-128 128c0 6.9.5 13.7 1.6 20.3l3.8 24.2L47.1 385.9V464h64v-64h64v-64h79l37.4-37.4 24.2 3.8c6.6 1.1 13.4 1.6 20.3 1.6" }) }), ep = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 384 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M24.52 38.13a48.02 48.02 0 0 1 48.51.91L361 215c14.3 8.8 23 24.3 23 41s-8.7 32.2-23 40.1l-287.97 176c-14.82 9.9-33.37 10.3-48.51 1.8A48.02 48.02 0 0 1 0 432V80a48.02 48.02 0 0 1 24.52-41.87M48 432l288-176L48 80z" }) }), tp = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M432 256c0 13.3-10.7 24-24 24H248v160c0 13.25-10.75 24.01-24 24.01S200 453.3 200 440V280H40c-13.25 0-24-10.74-24-23.99C16 242.8 26.75 232 40 232h160V72c0-13.25 10.75-23.99 24-23.99S248 58.75 248 72v160h160c13.3 0 24 10.8 24 24" }) }), np = (e) => /* @__PURE__ */ c.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ c.jsx("path", { d: "M64 80c-8.8 0-16 7.2-16 16v320c0 8.8 7.2 16 16 16h320c8.8 0 16-7.2 16-16V96c0-8.8-7.2-16-16-16zM0 96c0-35.3 28.7-64 64-64h320c35.3 0 64 28.7 64 64v320c0 35.3-28.7 64-64 64H64c-35.3 0-64-28.7-64-64zm200 248v-64h-64c-13.3 0-24-10.7-24-24s10.7-24 24-24h64v-64c0-13.3 10.7-24 24-24s24 10.7 24 24v64h64c13.3 0 24 10.7 24 24s-10.7 24-24 24h-64v64c0 13.3-10.7 24-24 24s-24-10.7-24-24" }) }), MC = { custom: "custom" -}, op = A.createContext({ +}, rp = A.createContext({ dragDropManager: void 0 }); function ze(e) { return "Minified Redux error #" + e + "; visit https://redux.js.org/Errors?code=" + e + " for the full message or use the non-minified dev environment for full errors. "; } -var Sa = (function() { +var wa = (function() { return typeof Symbol == "function" && Symbol.observable || "@@observable"; -})(), _a = function() { +})(), Sa = function() { return Math.random().toString(36).substring(7).split("").join("."); -}, Ca = { - INIT: "@@redux/INIT" + _a(), - REPLACE: "@@redux/REPLACE" + _a() +}, _a = { + INIT: "@@redux/INIT" + Sa(), + REPLACE: "@@redux/REPLACE" + Sa() }; -function ip(e) { +function op(e) { if (typeof e != "object" || e === null) return !1; for (var t = e; Object.getPrototypeOf(t) !== null; ) t = Object.getPrototypeOf(t); return Object.getPrototypeOf(e) === t; } -function Zc(e, t, n) { +function Jc(e, t, n) { var r; if (typeof t == "function" && typeof n == "function" || typeof n == "function" && typeof arguments[3] == "function") throw new Error(ze(0)); if (typeof t == "function" && typeof n > "u" && (n = t, t = void 0), typeof n < "u") { if (typeof n != "function") throw new Error(ze(1)); - return n(Zc)(e, t); + return n(Jc)(e, t); } if (typeof e != "function") throw new Error(ze(2)); @@ -83,7 +83,7 @@ function Zc(e, t, n) { }; } function f(m) { - if (!ip(m)) + if (!op(m)) throw new Error(ze(7)); if (typeof m.type > "u") throw new Error(ze(8)); @@ -104,7 +104,7 @@ function Zc(e, t, n) { if (typeof m != "function") throw new Error(ze(10)); o = m, f({ - type: Ca.REPLACE + type: _a.REPLACE }); } function g() { @@ -130,21 +130,21 @@ function Zc(e, t, n) { unsubscribe: b }; } - }, m[Sa] = function() { + }, m[wa] = function() { return this; }, m; } return f({ - type: Ca.INIT + type: _a.INIT }), r = { dispatch: f, subscribe: h, getState: d, replaceReducer: p - }, r[Sa] = g, r; + }, r[wa] = g, r; } function Q(e, t, ...n) { - if (sp() && t === void 0) + if (ip() && t === void 0) throw new Error("invariant requires an error message argument"); if (!e) { let r; @@ -159,24 +159,24 @@ function Q(e, t, ...n) { throw r.framesToPop = 1, r; } } -function sp() { +function ip() { return typeof process < "u" && process.env.NODE_ENV === "production"; } -function ap(e, t, n) { +function sp(e, t, n) { return t.split(".").reduce( (r, o) => r && r[o] ? r[o] : n || null, e ); } -function lp(e, t) { +function ap(e, t) { return e.filter( (n) => n !== t ); } -function eu(e) { +function Zc(e) { return typeof e == "object"; } -function cp(e, t) { +function lp(e, t) { const n = /* @__PURE__ */ new Map(), r = (i) => { n.set(i, n.has(i) ? n.get(i) + 1 : 1); }; @@ -186,53 +186,53 @@ function cp(e, t) { i === 1 && o.push(s); }), o; } -function up(e, t) { +function cp(e, t) { return e.filter( (n) => t.indexOf(n) > -1 ); } -const ts = "dnd-core/INIT_COORDS", ko = "dnd-core/BEGIN_DRAG", ns = "dnd-core/PUBLISH_DRAG_SOURCE", wo = "dnd-core/HOVER", So = "dnd-core/DROP", _o = "dnd-core/END_DRAG"; -function ja(e, t) { +const es = "dnd-core/INIT_COORDS", xo = "dnd-core/BEGIN_DRAG", ts = "dnd-core/PUBLISH_DRAG_SOURCE", ko = "dnd-core/HOVER", wo = "dnd-core/DROP", So = "dnd-core/END_DRAG"; +function Ca(e, t) { return { - type: ts, + type: es, payload: { sourceClientOffset: t || null, clientOffset: e || null } }; } -const dp = { - type: ts, +const up = { + type: es, payload: { clientOffset: null, sourceClientOffset: null } }; -function fp(e) { +function dp(e) { return function(n = [], r = { publishSource: !0 }) { const { publishSource: o = !0, clientOffset: i, getSourceClientOffset: s } = r, a = e.getMonitor(), l = e.getRegistry(); - e.dispatch(ja(i)), hp(n, a, l); - const u = mp(n, a); + e.dispatch(Ca(i)), fp(n, a, l); + const u = gp(n, a); if (u == null) { - e.dispatch(dp); + e.dispatch(up); return; } let d = null; if (i) { if (!s) throw new Error("getSourceClientOffset must be defined"); - pp(s), d = s(u); + hp(s), d = s(u); } - e.dispatch(ja(i, d)); + e.dispatch(Ca(i, d)); const f = l.getSource(u).beginDrag(a, u); if (f == null) return; - gp(f), l.pinSource(u); + pp(f), l.pinSource(u); const p = l.getSourceType(u); return { - type: ko, + type: xo, payload: { itemType: p, item: f, @@ -244,18 +244,18 @@ function fp(e) { }; }; } -function hp(e, t, n) { +function fp(e, t, n) { Q(!t.isDragging(), "Cannot call beginDrag while dragging."), e.forEach(function(r) { Q(n.getSource(r), "Expected sourceIds to be registered."); }); } -function pp(e) { +function hp(e) { Q(typeof e == "function", "When clientOffset is provided, getSourceClientOffset must be a function."); } -function gp(e) { - Q(eu(e), "Item must be an object."); +function pp(e) { + Q(Zc(e), "Item must be an object."); } -function mp(e, t) { +function gp(e, t) { let n = null; for (let r = e.length - 1; r >= 0; r--) if (t.canDragSource(e[r])) { @@ -264,7 +264,7 @@ function mp(e, t) { } return n; } -function yp(e, t, n) { +function mp(e, t, n) { return t in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, @@ -272,70 +272,70 @@ function yp(e, t, n) { writable: !0 }) : e[t] = n, e; } -function vp(e) { +function yp(e) { for (var t = 1; t < arguments.length; t++) { var n = arguments[t] != null ? arguments[t] : {}, r = Object.keys(n); typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(n).filter(function(o) { return Object.getOwnPropertyDescriptor(n, o).enumerable; }))), r.forEach(function(o) { - yp(e, o, n[o]); + mp(e, o, n[o]); }); } return e; } -function bp(e) { +function vp(e) { return function(n = {}) { const r = e.getMonitor(), o = e.getRegistry(); - xp(r), Sp(r).forEach((s, a) => { - const l = kp(s, a, o, r), u = { - type: So, + bp(r), wp(r).forEach((s, a) => { + const l = xp(s, a, o, r), u = { + type: wo, payload: { - dropResult: vp({}, n, l) + dropResult: yp({}, n, l) } }; e.dispatch(u); }); }; } -function xp(e) { +function bp(e) { Q(e.isDragging(), "Cannot call drop while not dragging."), Q(!e.didDrop(), "Cannot call drop twice during one drag operation."); } -function kp(e, t, n, r) { +function xp(e, t, n, r) { const o = n.getTarget(e); let i = o ? o.drop(r, e) : void 0; - return wp(i), typeof i > "u" && (i = t === 0 ? {} : r.getDropResult()), i; + return kp(i), typeof i > "u" && (i = t === 0 ? {} : r.getDropResult()), i; } -function wp(e) { - Q(typeof e > "u" || eu(e), "Drop result must either be an object or undefined."); +function kp(e) { + Q(typeof e > "u" || Zc(e), "Drop result must either be an object or undefined."); } -function Sp(e) { +function wp(e) { const t = e.getTargetIds().filter(e.canDropOnTarget, e); return t.reverse(), t; } -function _p(e) { +function Sp(e) { return function() { const n = e.getMonitor(), r = e.getRegistry(); - Cp(n); + _p(n); const o = n.getSourceId(); return o != null && (r.getSource(o, !0).endDrag(n, o), r.unpinSource()), { - type: _o + type: So }; }; } -function Cp(e) { +function _p(e) { Q(e.isDragging(), "Cannot call endDrag while not dragging."); } -function vi(e, t) { +function yi(e, t) { return t === null ? e === null : Array.isArray(e) ? e.some( (n) => n === t ) : e === t; } -function jp(e) { +function Cp(e) { return function(n, { clientOffset: r } = {}) { - Ep(n); + jp(n); const o = n.slice(0), i = e.getMonitor(), s = e.getRegistry(), a = i.getItemType(); - return Op(o, s, a), Tp(o, i, s), Pp(o, i, s), { - type: wo, + return Tp(o, s, a), Ep(o, i, s), Op(o, i, s), { + type: ko, payload: { targetIds: o, clientOffset: r || null @@ -343,10 +343,10 @@ function jp(e) { }; }; } -function Ep(e) { +function jp(e) { Q(Array.isArray(e), "Expected targetIds to be an array."); } -function Tp(e, t, n) { +function Ep(e, t, n) { Q(t.isDragging(), "Cannot call hover while not dragging."), Q(!t.didDrop(), "Cannot call hover after drop."); for (let r = 0; r < e.length; r++) { const o = e[r]; @@ -355,35 +355,35 @@ function Tp(e, t, n) { Q(i, "Expected targetIds to be registered."); } } -function Op(e, t, n) { +function Tp(e, t, n) { for (let r = e.length - 1; r >= 0; r--) { const o = e[r], i = t.getTargetType(o); - vi(i, n) || e.splice(r, 1); + yi(i, n) || e.splice(r, 1); } } -function Pp(e, t, n) { +function Op(e, t, n) { e.forEach(function(r) { n.getTarget(r).hover(t, r); }); } -function $p(e) { +function Pp(e) { return function() { if (e.getMonitor().isDragging()) return { - type: ns + type: ts }; }; } -function Dp(e) { +function $p(e) { return { - beginDrag: fp(e), - publishDragSource: $p(e), - hover: jp(e), - drop: bp(e), - endDrag: _p(e) + beginDrag: dp(e), + publishDragSource: Pp(e), + hover: Cp(e), + drop: vp(e), + endDrag: Sp(e) }; } -class zp { +class Dp { receiveBackend(t) { this.backend = t; } @@ -404,7 +404,7 @@ class zp { typeof a < "u" && n(a); }; } - const o = Dp(this); + const o = $p(this); return Object.keys(o).reduce((i, s) => { const a = o[s]; return i[s] = r(a), i; @@ -420,33 +420,33 @@ class zp { }, this.store = t, this.monitor = n, t.subscribe(this.handleRefCountChange); } } -function Ip(e, t) { +function zp(e, t) { return { x: e.x + t.x, y: e.y + t.y }; } -function tu(e, t) { +function eu(e, t) { return { x: e.x - t.x, y: e.y - t.y }; } -function Ap(e) { +function Ip(e) { const { clientOffset: t, initialClientOffset: n, initialSourceClientOffset: r } = e; - return !t || !n || !r ? null : tu(Ip(t, r), n); + return !t || !n || !r ? null : eu(zp(t, r), n); } -function Np(e) { +function Ap(e) { const { clientOffset: t, initialClientOffset: n } = e; - return !t || !n ? null : tu(t, n); + return !t || !n ? null : eu(t, n); } -const Bn = [], rs = []; +const Bn = [], ns = []; Bn.__IS_NONE__ = !0; -rs.__IS_ALL__ = !0; -function Rp(e, t) { - return e === Bn ? !1 : e === rs || typeof t > "u" ? !0 : up(t, e).length > 0; +ns.__IS_ALL__ = !0; +function Np(e, t) { + return e === Bn ? !1 : e === ns || typeof t > "u" ? !0 : cp(t, e).length > 0; } -class Mp { +class Rp { subscribeToStateChange(t, n = {}) { const { handlerIds: r } = n; Q(typeof t == "function", "listener must be a function."), Q(typeof r > "u" || Array.isArray(r), "handlerIds, when specified, must be an array of strings."); @@ -454,7 +454,7 @@ class Mp { const i = () => { const s = this.store.getState(), a = s.stateId; try { - a === o || a === o + 1 && !Rp(s.dirtyHandlerIds, r) || t(); + a === o || a === o + 1 && !Np(s.dirtyHandlerIds, r) || t(); } finally { o = a; } @@ -483,7 +483,7 @@ class Mp { if (Q(n, `Expected to find a valid target. targetId=${t}`), !this.isDragging() || this.didDrop()) return !1; const r = this.registry.getTargetType(t), o = this.getItemType(); - return vi(r, o) && n.canDrop(this, t); + return yi(r, o) && n.canDrop(this, t); } isDragging() { return !!this.getItemType(); @@ -506,7 +506,7 @@ class Mp { if (!this.isDragging()) return !1; const o = this.registry.getTargetType(t), i = this.getItemType(); - if (i && !vi(o, i)) + if (i && !yi(o, i)) return !1; const s = this.getTargetIds(); if (!s.length) @@ -545,17 +545,17 @@ class Mp { return this.store.getState().dragOffset.clientOffset; } getSourceClientOffset() { - return Ap(this.store.getState().dragOffset); + return Ip(this.store.getState().dragOffset); } getDifferenceFromInitialOffset() { - return Np(this.store.getState().dragOffset); + return Ap(this.store.getState().dragOffset); } constructor(t, n) { this.store = t, this.registry = n; } } -const Ea = typeof global < "u" ? global : self, nu = Ea.MutationObserver || Ea.WebKitMutationObserver; -function ru(e) { +const ja = typeof global < "u" ? global : self, tu = ja.MutationObserver || ja.WebKitMutationObserver; +function nu(e) { return function() { const n = setTimeout(o, 0), r = setInterval(o, 50); function o() { @@ -563,16 +563,16 @@ function ru(e) { } }; } -function Lp(e) { +function Mp(e) { let t = 1; - const n = new nu(e), r = document.createTextNode(""); + const n = new tu(e), r = document.createTextNode(""); return n.observe(r, { characterData: !0 }), function() { t = -t, r.data = t; }; } -const Fp = typeof nu == "function" ? ( +const Lp = typeof tu == "function" ? ( // reliably everywhere they are implemented. // They are implemented in all modern browsers. // @@ -583,7 +583,7 @@ const Fp = typeof nu == "function" ? ( // - iPad Safari 6-7.1 // - iPhone Safari 7-7.1 // - Safari 6-7 - Lp + Mp ) : ( // task queue, are implemented in Internet Explorer 10, Safari 5.0-1, and Opera // 11-12, and in web workers in many engines. @@ -609,9 +609,9 @@ const Fp = typeof nu == "function" ? ( // - Internet Explorer 6-9 // - iPad Safari 4.3 // - Lynx 2.8.7 - ru + nu ); -class qp { +class Fp { // Use the fastest means possible to execute a task in its own turn, with // priority over other events including IO, animation, reflow, and redraw // events in browsers. @@ -640,13 +640,13 @@ class qp { t.length = 0, this.index = 0, this.flushing = !1; }, this.registerPendingError = (t) => { this.pendingErrors.push(t), this.requestErrorThrow(); - }, this.requestFlush = Fp(this.flush), this.requestErrorThrow = ru(() => { + }, this.requestFlush = Lp(this.flush), this.requestErrorThrow = nu(() => { if (this.pendingErrors.length) throw this.pendingErrors.shift(); }); } } -class Bp { +class qp { call() { try { this.task && this.task(); @@ -660,9 +660,9 @@ class Bp { this.onError = t, this.release = n, this.task = null; } } -class Up { +class Bp { create(t) { - const n = this.freeTasks, r = n.length ? n.pop() : new Bp( + const n = this.freeTasks, r = n.length ? n.pop() : new qp( this.onError, (o) => n[n.length] = o ); @@ -672,53 +672,53 @@ class Up { this.onError = t, this.freeTasks = []; } } -const ou = new qp(), Hp = new Up(ou.registerPendingError); -function Vp(e) { - ou.enqueueTask(Hp.create(e)); +const ru = new Fp(), Up = new Bp(ru.registerPendingError); +function Hp(e) { + ru.enqueueTask(Up.create(e)); } -const os = "dnd-core/ADD_SOURCE", is = "dnd-core/ADD_TARGET", ss = "dnd-core/REMOVE_SOURCE", Co = "dnd-core/REMOVE_TARGET"; -function Wp(e) { +const rs = "dnd-core/ADD_SOURCE", os = "dnd-core/ADD_TARGET", is = "dnd-core/REMOVE_SOURCE", _o = "dnd-core/REMOVE_TARGET"; +function Vp(e) { return { - type: os, + type: rs, payload: { sourceId: e } }; } -function Kp(e) { +function Wp(e) { return { - type: is, + type: os, payload: { targetId: e } }; } -function Gp(e) { +function Kp(e) { return { - type: ss, + type: is, payload: { sourceId: e } }; } -function Xp(e) { +function Gp(e) { return { - type: Co, + type: _o, payload: { targetId: e } }; } -function Yp(e) { +function Xp(e) { Q(typeof e.canDrag == "function", "Expected canDrag to be a function."), Q(typeof e.beginDrag == "function", "Expected beginDrag to be a function."), Q(typeof e.endDrag == "function", "Expected endDrag to be a function."); } -function Qp(e) { +function Yp(e) { Q(typeof e.canDrop == "function", "Expected canDrop to be a function."), Q(typeof e.hover == "function", "Expected hover to be a function."), Q(typeof e.drop == "function", "Expected beginDrag to be a function."); } -function bi(e, t) { +function vi(e, t) { if (t && Array.isArray(e)) { e.forEach( - (n) => bi(n, !1) + (n) => vi(n, !1) ); return; } @@ -728,12 +728,12 @@ var Ae; (function(e) { e.SOURCE = "SOURCE", e.TARGET = "TARGET"; })(Ae || (Ae = {})); -let Jp = 0; -function Zp() { - return Jp++; +let Qp = 0; +function Jp() { + return Qp++; } -function eg(e) { - const t = Zp().toString(); +function Zp(e) { + const t = Jp().toString(); switch (e) { case Ae.SOURCE: return `S${t}`; @@ -743,7 +743,7 @@ function eg(e) { throw new Error(`Unknown Handler Role: ${e}`); } } -function Ta(e) { +function Ea(e) { switch (e[0]) { case "S": return Ae.SOURCE; @@ -753,7 +753,7 @@ function Ta(e) { throw new Error(`Cannot parse handler ID: ${e}`); } } -function Oa(e, t) { +function Ta(e, t) { const n = e.entries(); let r = !1; do { @@ -764,19 +764,19 @@ function Oa(e, t) { } while (!r); return !1; } -class tg { +class eg { addSource(t, n) { - bi(t), Yp(n); + vi(t), Xp(n); const r = this.addHandler(Ae.SOURCE, t, n); - return this.store.dispatch(Wp(r)), r; + return this.store.dispatch(Vp(r)), r; } addTarget(t, n) { - bi(t, !0), Qp(n); + vi(t, !0), Yp(n); const r = this.addHandler(Ae.TARGET, t, n); - return this.store.dispatch(Kp(r)), r; + return this.store.dispatch(Wp(r)), r; } containsHandler(t) { - return Oa(this.dragSources, t) || Oa(this.dropTargets, t); + return Ta(this.dragSources, t) || Ta(this.dropTargets, t); } getSource(t, n = !1) { return Q(this.isSourceId(t), "Expected a valid source ID."), n && t === this.pinnedSourceId ? this.pinnedSource : this.dragSources.get(t); @@ -791,18 +791,18 @@ class tg { return Q(this.isTargetId(t), "Expected a valid target ID."), this.types.get(t); } isSourceId(t) { - return Ta(t) === Ae.SOURCE; + return Ea(t) === Ae.SOURCE; } isTargetId(t) { - return Ta(t) === Ae.TARGET; + return Ea(t) === Ae.TARGET; } removeSource(t) { - Q(this.getSource(t), "Expected an existing source."), this.store.dispatch(Gp(t)), Vp(() => { + Q(this.getSource(t), "Expected an existing source."), this.store.dispatch(Kp(t)), Hp(() => { this.dragSources.delete(t), this.types.delete(t); }); } removeTarget(t) { - Q(this.getTarget(t), "Expected an existing target."), this.store.dispatch(Xp(t)), this.dropTargets.delete(t), this.types.delete(t); + Q(this.getTarget(t), "Expected an existing target."), this.store.dispatch(Gp(t)), this.dropTargets.delete(t), this.types.delete(t); } pinSource(t) { const n = this.getSource(t); @@ -812,18 +812,18 @@ class tg { Q(this.pinnedSource, "No source is pinned at the time."), this.pinnedSourceId = null, this.pinnedSource = null; } addHandler(t, n, r) { - const o = eg(t); + const o = Zp(t); return this.types.set(o, n), t === Ae.SOURCE ? this.dragSources.set(o, r) : t === Ae.TARGET && this.dropTargets.set(o, r), o; } constructor(t) { this.types = /* @__PURE__ */ new Map(), this.dragSources = /* @__PURE__ */ new Map(), this.dropTargets = /* @__PURE__ */ new Map(), this.pinnedSourceId = null, this.pinnedSource = null, this.store = t; } } -const ng = (e, t) => e === t; -function rg(e, t) { +const tg = (e, t) => e === t; +function ng(e, t) { return !e && !t ? !0 : !e || !t ? !1 : e.x === t.x && e.y === t.y; } -function og(e, t, n = ng) { +function rg(e, t, n = tg) { if (e.length !== t.length) return !1; for (let r = 0; r < e.length; ++r) @@ -831,29 +831,29 @@ function og(e, t, n = ng) { return !1; return !0; } -function ig(e = Bn, t) { +function og(e = Bn, t) { switch (t.type) { - case wo: + case ko: break; + case rs: case os: + case _o: case is: - case Co: - case ss: return Bn; - case ko: - case ns: - case _o: + case xo: + case ts: case So: + case wo: default: - return rs; + return ns; } - const { targetIds: n = [], prevTargetIds: r = [] } = t.payload, o = cp(n, r); - if (!(o.length > 0 || !og(n, r))) + const { targetIds: n = [], prevTargetIds: r = [] } = t.payload, o = lp(n, r); + if (!(o.length > 0 || !rg(n, r))) return Bn; const s = r[r.length - 1], a = n[n.length - 1]; return s !== a && (s && o.push(s), a && o.push(a)), o; } -function sg(e, t, n) { +function ig(e, t, n) { return t in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, @@ -861,44 +861,44 @@ function sg(e, t, n) { writable: !0 }) : e[t] = n, e; } -function ag(e) { +function sg(e) { for (var t = 1; t < arguments.length; t++) { var n = arguments[t] != null ? arguments[t] : {}, r = Object.keys(n); typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(n).filter(function(o) { return Object.getOwnPropertyDescriptor(n, o).enumerable; }))), r.forEach(function(o) { - sg(e, o, n[o]); + ig(e, o, n[o]); }); } return e; } -const Pa = { +const Oa = { initialSourceClientOffset: null, initialClientOffset: null, clientOffset: null }; -function lg(e = Pa, t) { +function ag(e = Oa, t) { const { payload: n } = t; switch (t.type) { - case ts: - case ko: + case es: + case xo: return { initialSourceClientOffset: n.sourceClientOffset, initialClientOffset: n.clientOffset, clientOffset: n.clientOffset }; - case wo: - return rg(e.clientOffset, n.clientOffset) ? e : ag({}, e, { + case ko: + return ng(e.clientOffset, n.clientOffset) ? e : sg({}, e, { clientOffset: n.clientOffset }); - case _o: case So: - return Pa; + case wo: + return Oa; default: return e; } } -function cg(e, t, n) { +function lg(e, t, n) { return t in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, @@ -912,12 +912,12 @@ function Gt(e) { typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(n).filter(function(o) { return Object.getOwnPropertyDescriptor(n, o).enumerable; }))), r.forEach(function(o) { - cg(e, o, n[o]); + lg(e, o, n[o]); }); } return e; } -const ug = { +const cg = { itemType: null, item: null, sourceId: null, @@ -926,10 +926,10 @@ const ug = { didDrop: !1, isSourcePublic: null }; -function dg(e = ug, t) { +function ug(e = cg, t) { const { payload: n } = t; switch (t.type) { - case ko: + case xo: return Gt({}, e, { itemType: n.itemType, item: n.item, @@ -938,25 +938,25 @@ function dg(e = ug, t) { dropResult: null, didDrop: !1 }); - case ns: + case ts: return Gt({}, e, { isSourcePublic: !0 }); - case wo: + case ko: return Gt({}, e, { targetIds: n.targetIds }); - case Co: + case _o: return e.targetIds.indexOf(n.targetId) === -1 ? e : Gt({}, e, { - targetIds: lp(e.targetIds, n.targetId) + targetIds: ap(e.targetIds, n.targetId) }); - case So: + case wo: return Gt({}, e, { dropResult: n.dropResult, didDrop: !0, targetIds: [] }); - case _o: + case So: return Gt({}, e, { itemType: null, item: null, @@ -970,22 +970,22 @@ function dg(e = ug, t) { return e; } } -function fg(e = 0, t) { +function dg(e = 0, t) { switch (t.type) { + case rs: case os: - case is: return e + 1; - case ss: - case Co: + case is: + case _o: return e - 1; default: return e; } } -function hg(e = 0) { +function fg(e = 0) { return e + 1; } -function pg(e, t, n) { +function hg(e, t, n) { return t in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, @@ -993,45 +993,45 @@ function pg(e, t, n) { writable: !0 }) : e[t] = n, e; } -function gg(e) { +function pg(e) { for (var t = 1; t < arguments.length; t++) { var n = arguments[t] != null ? arguments[t] : {}, r = Object.keys(n); typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(n).filter(function(o) { return Object.getOwnPropertyDescriptor(n, o).enumerable; }))), r.forEach(function(o) { - pg(e, o, n[o]); + hg(e, o, n[o]); }); } return e; } -function mg(e = {}, t) { +function gg(e = {}, t) { return { - dirtyHandlerIds: ig(e.dirtyHandlerIds, { + dirtyHandlerIds: og(e.dirtyHandlerIds, { type: t.type, - payload: gg({}, t.payload, { - prevTargetIds: ap(e, "dragOperation.targetIds", []) + payload: pg({}, t.payload, { + prevTargetIds: sp(e, "dragOperation.targetIds", []) }) }), - dragOffset: lg(e.dragOffset, t), - refCount: fg(e.refCount, t), - dragOperation: dg(e.dragOperation, t), - stateId: hg(e.stateId) + dragOffset: ag(e.dragOffset, t), + refCount: dg(e.refCount, t), + dragOperation: ug(e.dragOperation, t), + stateId: fg(e.stateId) }; } -function yg(e, t = void 0, n = {}, r = !1) { - const o = vg(r), i = new Mp(o, new tg(o)), s = new zp(o, i), a = e(s, t, n); +function mg(e, t = void 0, n = {}, r = !1) { + const o = yg(r), i = new Rp(o, new eg(o)), s = new Dp(o, i), a = e(s, t, n); return s.receiveBackend(a), s; } -function vg(e) { +function yg(e) { const t = typeof window < "u" && window.__REDUX_DEVTOOLS_EXTENSION__; - return Zc(mg, e && t && t({ + return Jc(gg, e && t && t({ name: "dnd-core", instanceId: "dnd-core" })); } -function bg(e, t) { +function vg(e, t) { if (e == null) return {}; - var n = xg(e, t), r, o; + var n = bg(e, t), r, o; if (Object.getOwnPropertySymbols) { var i = Object.getOwnPropertySymbols(e); for (o = 0; o < i.length; o++) @@ -1039,33 +1039,33 @@ function bg(e, t) { } return n; } -function xg(e, t) { +function bg(e, t) { if (e == null) return {}; var n = {}, r = Object.keys(e), o, i; for (i = 0; i < r.length; i++) o = r[i], !(t.indexOf(o) >= 0) && (n[o] = e[o]); return n; } -let $a = 0; +let Pa = 0; const Wr = /* @__PURE__ */ Symbol.for("__REACT_DND_CONTEXT_INSTANCE__"); -var FC = /* @__PURE__ */ A.memo(function(t) { - var { children: n } = t, r = bg(t, [ +var LC = /* @__PURE__ */ A.memo(function(t) { + var { children: n } = t, r = vg(t, [ "children" ]); - const [o, i] = kg(r); + const [o, i] = xg(r); return A.useEffect(() => { if (i) { - const s = iu(); - return ++$a, () => { - --$a === 0 && (s[Wr] = null); + const s = ou(); + return ++Pa, () => { + --Pa === 0 && (s[Wr] = null); }; } - }, []), /* @__PURE__ */ c.jsx(op.Provider, { + }, []), /* @__PURE__ */ c.jsx(rp.Provider, { value: o, children: n }); }); -function kg(e) { +function xg(e) { if ("manager" in e) return [ { @@ -1073,31 +1073,31 @@ function kg(e) { }, !1 ]; - const t = wg(e.backend, e.context, e.options, e.debugMode), n = !e.context; + const t = kg(e.backend, e.context, e.options, e.debugMode), n = !e.context; return [ t, n ]; } -function wg(e, t = iu(), n, r) { +function kg(e, t = ou(), n, r) { const o = t; return o[Wr] || (o[Wr] = { - dragDropManager: yg(e, t, n, r) + dragDropManager: mg(e, t, n, r) }), o[Wr]; } -function iu() { +function ou() { return typeof global < "u" ? global : window; } -function su(e) { +function iu(e) { let t = null; return () => (t == null && (t = e()), t); } -function Sg(e, t) { +function wg(e, t) { return e.filter( (n) => n !== t ); } -function _g(e, t) { +function Sg(e, t) { const n = /* @__PURE__ */ new Set(), r = (i) => n.add(i); e.forEach(r), t.forEach(r); const o = []; @@ -1105,16 +1105,16 @@ function _g(e, t) { (i) => o.push(i) ), o; } -class Cg { +class _g { enter(t) { const n = this.entered.length, r = (o) => this.isNodeInDocument(o) && (!o.contains || o.contains(t)); - return this.entered = _g(this.entered.filter(r), [ + return this.entered = Sg(this.entered.filter(r), [ t ]), n === 0 && this.entered.length > 0; } leave(t) { const n = this.entered.length; - return this.entered = Sg(this.entered.filter(this.isNodeInDocument), t), n > 0 && this.entered.length === 0; + return this.entered = wg(this.entered.filter(this.isNodeInDocument), t), n > 0 && this.entered.length === 0; } reset() { this.entered = []; @@ -1123,7 +1123,7 @@ class Cg { this.entered = [], this.isNodeInDocument = t; } } -class jg { +class Cg { initializeExposedProperties() { Object.keys(this.config.exposeProperties).forEach((t) => { Object.defineProperty(this.item, t, { @@ -1163,22 +1163,22 @@ class jg { this.config = t, this.item = {}, this.initializeExposedProperties(); } } -const au = "__NATIVE_FILE__", lu = "__NATIVE_URL__", cu = "__NATIVE_TEXT__", uu = "__NATIVE_HTML__", Da = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +const su = "__NATIVE_FILE__", au = "__NATIVE_URL__", lu = "__NATIVE_TEXT__", cu = "__NATIVE_HTML__", $a = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, - FILE: au, - HTML: uu, - TEXT: cu, - URL: lu + FILE: su, + HTML: cu, + TEXT: lu, + URL: au }, Symbol.toStringTag, { value: "Module" })); -function Jo(e, t, n) { +function Qo(e, t, n) { const r = t.reduce( (o, i) => o || e.getData(i), "" ); return r ?? n; } -const xi = { - [au]: { +const bi = { + [su]: { exposeProperties: { files: (e) => Array.prototype.slice.call(e.files), items: (e) => e.items, @@ -1188,9 +1188,9 @@ const xi = { "Files" ] }, - [uu]: { + [cu]: { exposeProperties: { - html: (e, t) => Jo(e, t, ""), + html: (e, t) => Qo(e, t, ""), dataTransfer: (e) => e }, matchesTypes: [ @@ -1198,9 +1198,9 @@ const xi = { "text/html" ] }, - [lu]: { + [au]: { exposeProperties: { - urls: (e, t) => Jo(e, t, "").split(` + urls: (e, t) => Qo(e, t, "").split(` `), dataTransfer: (e) => e }, @@ -1209,9 +1209,9 @@ const xi = { "text/uri-list" ] }, - [cu]: { + [lu]: { exposeProperties: { - text: (e, t) => Jo(e, t, ""), + text: (e, t) => Qo(e, t, ""), dataTransfer: (e) => e }, matchesTypes: [ @@ -1220,30 +1220,30 @@ const xi = { ] } }; -function Eg(e, t) { - const n = xi[e]; +function jg(e, t) { + const n = bi[e]; if (!n) throw new Error(`native type ${e} has no configuration`); - const r = new jg(n); + const r = new Cg(n); return r.loadDataTransfer(t), r; } -function Zo(e) { +function Jo(e) { if (!e) return null; const t = Array.prototype.slice.call(e.types || []); - return Object.keys(xi).filter((n) => { - const r = xi[n]; + return Object.keys(bi).filter((n) => { + const r = bi[n]; return r?.matchesTypes ? r.matchesTypes.some( (o) => t.indexOf(o) > -1 ) : !1; })[0] || null; } -const Tg = su( +const Eg = iu( () => /firefox/i.test(navigator.userAgent) -), du = su( +), uu = iu( () => !!window.safari ); -class za { +class Da { interpolate(t) { const { xs: n, ys: r, c1s: o, c2s: i, c3s: s } = this; let a = n.length - 1; @@ -1299,9 +1299,9 @@ class za { this.xs = t, this.ys = n, this.c1s = u, this.c2s = d, this.c3s = h; } } -const Og = 1; -function fu(e) { - const t = e.nodeType === Og ? e : e.parentElement; +const Tg = 1; +function du(e) { + const t = e.nodeType === Tg ? e : e.parentElement; if (!t) return null; const { top: n, left: r } = t.getBoundingClientRect(); @@ -1316,23 +1316,23 @@ function kr(e) { y: e.clientY }; } -function Pg(e) { +function Og(e) { var t; - return e.nodeName === "IMG" && (Tg() || !(!((t = document.documentElement) === null || t === void 0) && t.contains(e))); + return e.nodeName === "IMG" && (Eg() || !(!((t = document.documentElement) === null || t === void 0) && t.contains(e))); } -function $g(e, t, n, r) { +function Pg(e, t, n, r) { let o = e ? t.width : n, i = e ? t.height : r; - return du() && e && (i /= window.devicePixelRatio, o /= window.devicePixelRatio), { + return uu() && e && (i /= window.devicePixelRatio, o /= window.devicePixelRatio), { dragPreviewWidth: o, dragPreviewHeight: i }; } -function Dg(e, t, n, r, o) { - const i = Pg(t), a = fu(i ? e : t), l = { +function $g(e, t, n, r, o) { + const i = Og(t), a = du(i ? e : t), l = { x: n.x - a.x, y: n.y - a.y - }, { offsetWidth: u, offsetHeight: d } = e, { anchorX: h, anchorY: f } = r, { dragPreviewWidth: p, dragPreviewHeight: g } = $g(i, t, u, d), m = () => { - let _ = new za([ + }, { offsetWidth: u, offsetHeight: d } = e, { anchorX: h, anchorY: f } = r, { dragPreviewWidth: p, dragPreviewHeight: g } = Pg(i, t, u, d), m = () => { + let _ = new Da([ 0, 0.5, 1 @@ -1344,8 +1344,8 @@ function Dg(e, t, n, r, o) { // Dock to the bottom l.y + g - d ]).interpolate(f); - return du() && i && (_ += (window.devicePixelRatio - 1) * g), _; - }, y = () => new za([ + return uu() && i && (_ += (window.devicePixelRatio - 1) * g), _; + }, y = () => new Da([ 0, 0.5, 1 @@ -1362,7 +1362,7 @@ function Dg(e, t, n, r, o) { y: b ? k : m() }; } -class zg { +class Dg { get window() { if (this.globalContext) return this.globalContext; @@ -1381,7 +1381,7 @@ class zg { this.ownerDocument = null, this.globalContext = t, this.optionsArgs = n; } } -function Ig(e, t, n) { +function zg(e, t, n) { return t in e ? Object.defineProperty(e, t, { value: n, enumerable: !0, @@ -1389,18 +1389,18 @@ function Ig(e, t, n) { writable: !0 }) : e[t] = n, e; } -function Ia(e) { +function za(e) { for (var t = 1; t < arguments.length; t++) { var n = arguments[t] != null ? arguments[t] : {}, r = Object.keys(n); typeof Object.getOwnPropertySymbols == "function" && (r = r.concat(Object.getOwnPropertySymbols(n).filter(function(o) { return Object.getOwnPropertyDescriptor(n, o).enumerable; }))), r.forEach(function(o) { - Ig(e, o, n[o]); + zg(e, o, n[o]); }); } return e; } -class Ag { +class Ig { /** * Generate profiling statistics for the HTML5Backend. */ @@ -1471,7 +1471,7 @@ class Ag { } getCurrentSourceNodeOptions() { const t = this.monitor.getSourceId(), n = this.sourceNodeOptions.get(t); - return Ia({ + return za({ dropEffect: this.altKeyPressed ? "copy" : "move" }, n || {}); } @@ -1480,7 +1480,7 @@ class Ag { } getCurrentSourcePreviewNodeOptions() { const t = this.monitor.getSourceId(), n = this.sourcePreviewNodeOptions.get(t); - return Ia({ + return za({ anchorX: 0.5, anchorY: 0.5, captureDraggingState: !1 @@ -1488,12 +1488,12 @@ class Ag { } isDraggingNativeItem() { const t = this.monitor.getItemType(); - return Object.keys(Da).some( - (n) => Da[n] === t + return Object.keys($a).some( + (n) => $a[n] === t ); } beginDragNativeItem(t, n) { - this.clearCurrentDragSourceNode(), this.currentNativeSource = Eg(t, n), this.currentNativeHandle = this.registry.addSource(t, this.currentNativeSource), this.actions.beginDrag([ + this.clearCurrentDragSourceNode(), this.currentNativeSource = jg(t, n), this.currentNativeHandle = this.registry.addSource(t, this.currentNativeSource), this.actions.beginDrag([ this.currentNativeHandle ]); } @@ -1530,7 +1530,7 @@ class Ag { constructor(t, n, r) { this.sourcePreviewNodes = /* @__PURE__ */ new Map(), this.sourcePreviewNodeOptions = /* @__PURE__ */ new Map(), this.sourceNodes = /* @__PURE__ */ new Map(), this.sourceNodeOptions = /* @__PURE__ */ new Map(), this.dragStartSourceIds = null, this.dropTargetIds = [], this.dragEnterTargetIds = [], this.currentNativeSource = null, this.currentNativeHandle = null, this.currentDragSourceNode = null, this.altKeyPressed = !1, this.mouseMoveTimeoutTimer = null, this.asyncEndDragFrameId = null, this.dragOverTargetIds = null, this.lastClientOffset = null, this.hoverRafId = null, this.getSourceClientOffset = (o) => { const i = this.sourceNodes.get(o); - return i && fu(i) || null; + return i && du(i) || null; }, this.endDragNativeItem = () => { this.isDraggingNativeItem() && (this.actions.endDrag(), this.currentNativeHandle && this.registry.removeSource(this.currentNativeHandle), this.currentNativeHandle = null, this.currentNativeSource = null); }, this.isNodeInDocument = (o) => !!(o && this.document && this.document.body && this.document.body.contains(o)), this.endDragIfSourceWasRemovedFromDOM = () => { @@ -1557,12 +1557,12 @@ class Ag { getSourceClientOffset: this.getSourceClientOffset, clientOffset: s }); - const { dataTransfer: a } = o, l = Zo(a); + const { dataTransfer: a } = o, l = Jo(a); if (this.monitor.isDragging()) { if (a && typeof a.setDragImage == "function") { const d = this.monitor.getSourceId(), h = this.sourceNodes.get(d), f = this.sourcePreviewNodes.get(d) || h; if (f) { - const { anchorX: p, anchorY: g, offsetX: m, offsetY: y } = this.getCurrentSourcePreviewNodeOptions(), v = Dg(h, f, s, { + const { anchorX: p, anchorY: g, offsetX: m, offsetY: y } = this.getCurrentSourcePreviewNodeOptions(), v = $g(h, f, s, { anchorX: p, anchorY: g }, { @@ -1598,7 +1598,7 @@ class Ag { } if (!this.enterLeaveCounter.enter(o.target) || this.monitor.isDragging()) return; - const { dataTransfer: a } = o, l = Zo(a); + const { dataTransfer: a } = o, l = Jo(a); l && this.beginDragNativeItem(l, a); }, this.handleTopDragEnter = (o) => { const { dragEnterTargetIds: i } = this; @@ -1632,7 +1632,7 @@ class Ag { if (this.dropTargetIds = [], this.isDraggingNativeItem()) { var i; o.preventDefault(), (i = this.currentNativeSource) === null || i === void 0 || i.loadDataTransfer(o.dataTransfer); - } else Zo(o.dataTransfer) && o.preventDefault(); + } else Jo(o.dataTransfer) && o.preventDefault(); this.enterLeaveCounter.reset(); }, this.handleTopDrop = (o) => { const { dropTargetIds: i } = this; @@ -1644,14 +1644,14 @@ class Ag { }, this.handleSelectStart = (o) => { const i = o.target; typeof i.dragDrop == "function" && (i.tagName === "INPUT" || i.tagName === "SELECT" || i.tagName === "TEXTAREA" || i.isContentEditable || (o.preventDefault(), i.dragDrop())); - }, this.options = new zg(n, r), this.actions = t.getActions(), this.monitor = t.getMonitor(), this.registry = t.getRegistry(), this.enterLeaveCounter = new Cg(this.isNodeInDocument); + }, this.options = new Dg(n, r), this.actions = t.getActions(), this.monitor = t.getMonitor(), this.registry = t.getRegistry(), this.enterLeaveCounter = new _g(this.isNodeInDocument); } } -const qC = function(t, n, r) { - return new Ag(t, n, r); -}, Ng = kt("scanconf/runScan"), BC = kt("scanconf/runFullScan"), as = kt( +const FC = function(t, n, r) { + return new Ig(t, n, r); +}, Ag = wt("scanconf/runScan"), qC = wt("scanconf/runFullScan"), ss = wt( "scanconf/showScanconfOperation" -), Rg = kt("scanconf/loadUpdatedScanconf"), Mg = kt("scanconf/loadPlaybook"), UC = kt("http/sendHttpRequest"), Lg = kt("http/showHttpResponse"), Fg = kt("http/showHttpError"), qg = "mtls:profile", HC = ["crt", "cer", "der", "pfx"], VC = ["p12", "pfx"], Bg = { +), Ng = wt("scanconf/loadUpdatedScanconf"), Rg = wt("scanconf/loadPlaybook"), BC = wt("http/sendHttpRequest"), Mg = wt("http/showHttpResponse"), Lg = wt("http/showHttpError"), Fg = "mtls:profile", UC = ["crt", "cer", "der", "pfx"], HC = ["p12", "pfx"], qg = { oas: { openapi: "3.0.0", info: { title: "", version: "0.0" }, @@ -1668,9 +1668,9 @@ const qC = function(t, n, r) { }, servers: [], selectedCredentialGroup: 0 -}, hu = Wt({ +}, fu = Wt({ name: "scanconf", - initialState: Bg, + initialState: qg, reducers: { saveScanconf: (e) => { }, @@ -1720,7 +1720,7 @@ const qC = function(t, n, r) { e.playbook.securityProfile = t; }, removeSecurityProfile: (e) => { - e.playbook.securityProfile = void 0, e.selectedCredential === qg && (e.selectedCredential = void 0, e.selectedSubcredential = void 0); + e.playbook.securityProfile = void 0, e.selectedCredential === Fg && (e.selectedCredential = void 0, e.selectedSubcredential = void 0); }, selectCredential: (e, { payload: t }) => { e.selectedCredentialGroup = t.group, e.selectedCredential = t.credential, e.selectedSubcredential = Object.keys( @@ -1759,7 +1759,7 @@ const qC = function(t, n, r) { moveStage: (e, { payload: { location: t, to: n } }) => { - Qg(wr(e.playbook, t), t.stageIndex, n); + Yg(wr(e.playbook, t), t.stageIndex, n); }, removeStage: (e, { payload: t }) => { wr(e.playbook, t).splice(t.stageIndex, 1); @@ -1805,8 +1805,8 @@ const qC = function(t, n, r) { } }, extraReducers: (e) => { - e.addCase(Mg, (t, { payload: { oas: n, playbook: r } }) => { - t.oas = n, t.playbook = r, t.servers = Zf(n), t.selectedCredentialGroup = 0, t.selectedCredential = Object.keys(r?.authenticationDetails?.[0] || {})?.[0], t.selectedCredential !== void 0 && (t.selectedSubcredential = Object.keys( + e.addCase(Rg, (t, { payload: { oas: n, playbook: r } }) => { + t.oas = n, t.playbook = r, t.servers = oh(n), t.selectedCredentialGroup = 0, t.selectedCredential = Object.keys(r?.authenticationDetails?.[0] || {})?.[0], t.selectedCredential !== void 0 && (t.selectedSubcredential = Object.keys( r?.authenticationDetails[0][t.selectedCredential]?.methods )?.[0]), t.selectedAuthorizationTest = Object.keys(r?.authorizationTests || {})?.[0]; }); @@ -1816,57 +1816,57 @@ function wr(e, t) { return t.container === "operationScenarios" ? e.operations[t.operationId].scenarios[t.scenarioIndex].requests : t.container === "operationBefore" ? e.operations[t.operationId].before : t.container === "operationAfter" ? e.operations[t.operationId].after : t.container === "globalBefore" ? e.before : t.container === "globalAfter" ? e.after : t.container === "credential" ? e.authenticationDetails[t.group][t.credentialId].methods[t.subCredentialId].requests : null; } const { - saveSettings: Ug, - saveEnvironment: Hg, - saveScanconf: WC, - addCredential: Vg, - removeCredential: Wg, - setSecurityProfile: KC, - removeSecurityProfile: GC, - addStage: XC, - moveStage: YC, - removeStage: QC, - saveOperationReference: JC, - saveCredential: Kg, - selectCredential: Gg, - selectSubcredential: Xg, - addAuthorizationTest: ZC, - saveAuthorizationTest: ej, - removeAuthorizationTest: tj, - selectAuthorizationTest: nj, - saveRequest: pu, - removeRequest: rj, - updateOperationAuthorizationTests: oj, - customizeOperation: ij, - removeCustomizationForOperation: sj, - createVariable: gu -} = hu.actions, Yg = hu.reducer; -function Qg(e, t, n) { + saveSettings: Bg, + saveEnvironment: Ug, + saveScanconf: VC, + addCredential: Hg, + removeCredential: Vg, + setSecurityProfile: WC, + removeSecurityProfile: KC, + addStage: GC, + moveStage: XC, + removeStage: YC, + saveOperationReference: QC, + saveCredential: Wg, + selectCredential: Kg, + selectSubcredential: Gg, + addAuthorizationTest: JC, + saveAuthorizationTest: ZC, + removeAuthorizationTest: ej, + selectAuthorizationTest: tj, + saveRequest: hu, + removeRequest: nj, + updateOperationAuthorizationTests: rj, + customizeOperation: oj, + removeCustomizationForOperation: ij, + createVariable: pu +} = fu.actions, Xg = fu.reducer; +function Yg(e, t, n) { const r = t < 0 ? e.length + t : t; if (r >= 0 && r < e.length) { const o = n < 0 ? e.length + n : n, [i] = e.splice(t, 1); e.splice(o, 0, i); } } -function jo(e, t) { +function Co(e, t) { if (e.auth.length === 0) return t; const [n, ...r] = e.auth, o = cn(t), i = cn(o.results); - return jo({ auth: r }, i.auth[n].execution); + return Co({ auth: r }, i.auth[n].execution); } function Ot(e, t) { - return cn(jo(e, t)); + return cn(Co(e, t)); } -function tt(e, t) { +function nt(e, t) { return cn(Ot(e, t).results); } -function Aa(e, t) { +function Ia(e, t) { const n = e.auth.slice(0, -1); - return cn(cn(jo({ auth: n }, t)).results); + return cn(cn(Co({ auth: n }, t)).results); } -const mu = { +const gu = { "playbook-started": function(e, t, n) { - jo(e, t).push({ + Co(e, t).push({ name: n.name, status: "pending", results: [] @@ -1881,7 +1881,7 @@ const mu = { }); }, "auth-started": function(e, t, n) { - tt(e, t).auth[n.name] = { + nt(e, t).auth[n.name] = { execution: [] }, e.auth.push(n.name); }, @@ -1890,7 +1890,7 @@ const mu = { }, "auth-aborted": function(e, t, n) { const r = e.auth.pop(); - tt(e, t).auth[r].error = n.error; + nt(e, t).auth[r].error = n.error; }, "playbook-finished": function(e, t, n) { Ot(e, t).status = "success"; @@ -1900,14 +1900,14 @@ const mu = { r.status = "failure", r.error = n.error; }, "payload-variables-substituted": function(e, t, n) { - tt(e, t).variablesReplaced = { + nt(e, t).variablesReplaced = { stack: n.stack, found: n.found, missing: n.missing }; }, "credential-variables-substituted": function(e, t, n) { - const r = Aa(e, t); + const r = Ia(e, t); r.auth[n.name].result = n.result, r.auth[n.name].variables = { missing: n.missing, found: n.found, @@ -1915,44 +1915,44 @@ const mu = { }; }, "credential-retrieved-from-cache": function(e, t, n) { - const r = Aa(e, t); + const r = Ia(e, t); r.auth[n.name].result = n.result; }, "http-request-prepared": function(e, t, n) { - const r = tt(e, t); + const r = nt(e, t); r.httpRequest = n.request, r.operationId = n.operationId; }, "http-request-prepare-error": function(e, t, n) { - const r = tt(e, t); + const r = nt(e, t); r.httpRequestPrepareError = n.error, r.status = "failure", Ot(e, t).status = "failure"; }, "http-response-received": function(e, t, n) { - const r = tt(e, t); + const r = nt(e, t); r.httpResponse = n.response, r.status = "success"; }, "http-error-received": function(e, t, n) { - const r = tt(e, t); + const r = nt(e, t); r.httpError = n.error, r.status = "failure", Ot(e, t).status = "failure"; }, "variables-assigned": function(e, t, n) { - tt(e, t).variablesAssigned.push(...n.assignments); + nt(e, t).variablesAssigned.push(...n.assignments); }, "response-processing-error": function(e, t, n) { - const r = tt(e, t); + const r = nt(e, t); r.responseProcessingError = n.error, r.status = "failure", Ot(e, t).status = "failure"; } }; -function Eo({ +function jo({ tryCurrent: e, tryResult: t }, n) { - mu[n.event](e, t, n); + gu[n.event](e, t, n); } -function To({ +function Eo({ mockCurrent: e, mockResult: t }, n) { - mu[n.event](e, t, n); + gu[n.event](e, t, n); } function cn(e) { return e[e.length - 1]; @@ -1960,14 +1960,14 @@ function cn(e) { function tn(e, t) { return e.filter((n) => n.name === t).pop(); } -const Jg = { +const Qg = { mockCurrent: { auth: [] }, mockResult: [], tryCurrent: { auth: [] }, tryResult: [] -}, yu = Wt({ +}, mu = Wt({ name: "auth", - initialState: Jg, + initialState: Qg, reducers: { startTryAuthentication: (e, { payload: t }) => { }, @@ -1975,23 +1975,23 @@ const Jg = { e.tryCurrent = { auth: [] }, e.tryResult = []; }, addTryAuthenticationStep: (e, { payload: t }) => { - Eo(e, t); + jo(e, t); }, resetMockAuthRequestsExecution: (e) => { e.mockCurrent = { auth: [] }, e.mockResult = []; }, addMockAuthRequestsExecutionStep: (e, { payload: t }) => { - To(e, t); + Eo(e, t); } }, extraReducers: (e) => { e.addMatcher( - Pf( - Gg, - Xg, + Of( Kg, - Vg, - Wg + Gg, + Wg, + Hg, + Vg ), (t, n) => { t.tryCurrent = { auth: [] }, t.tryResult = []; @@ -1999,20 +1999,20 @@ const Jg = { ); } }), { - startTryAuthentication: aj, - resetTryAuthentication: lj, - addTryAuthenticationStep: cj, - resetMockAuthRequestsExecution: uj, - addMockAuthRequestsExecutionStep: dj -} = yu.actions, Zg = yu.reducer, em = { + startTryAuthentication: sj, + resetTryAuthentication: aj, + addTryAuthenticationStep: lj, + resetMockAuthRequestsExecution: cj, + addMockAuthRequestsExecutionStep: uj +} = mu.actions, Jg = mu.reducer, Zg = { mockCurrent: { auth: [] }, mockResult: [], tryCurrent: { auth: [] }, tryResult: [], selected: "before" -}, vu = Wt({ +}, yu = Wt({ name: "global", - initialState: em, + initialState: Zg, reducers: { selectGlobal: (e, { payload: t }) => { e.selected = t, e.tryCurrent = { auth: [] }, e.tryResult = []; @@ -2023,31 +2023,31 @@ const Jg = { e.tryCurrent = { auth: [] }, e.tryResult = []; }, addTryGlobalStep: (e, { payload: t }) => { - Eo(e, t); + jo(e, t); }, resetMockGlobal: (e) => { e.mockCurrent = { auth: [] }, e.mockResult = []; }, addMockGlobalStep: (e, { payload: t }) => { - To(e, t); + Eo(e, t); } } }), { - selectGlobal: fj, - startTryGlobal: hj, - resetTryGlobal: pj, - addTryGlobalStep: gj, - resetMockGlobal: mj, - addMockGlobalStep: yj -} = vu.actions, tm = vu.reducer, nm = { + selectGlobal: dj, + startTryGlobal: fj, + resetTryGlobal: hj, + addTryGlobalStep: pj, + resetMockGlobal: gj, + addMockGlobalStep: mj +} = yu.actions, em = yu.reducer, tm = { mockCurrent: { auth: [] }, mockResult: [], tryCurrent: { auth: [] }, tryResult: [], scenarioId: 0 -}, bu = Wt({ +}, vu = Wt({ name: "operations", - initialState: nm, + initialState: tm, reducers: { setOperationId: (e, { payload: t }) => { e.operationId = t, e.scenarioId = 0, e.tryCurrent = { auth: [] }, e.tryResult = []; @@ -2059,7 +2059,7 @@ const Jg = { e.mockCurrent = { auth: [] }, e.mockResult = []; }, addMockOperationExecutionStep: (e, { payload: t }) => { - To(e, t); + Eo(e, t); }, startTryExecution: (e, { payload: t }) => { }, @@ -2067,31 +2067,31 @@ const Jg = { e.tryCurrent = { auth: [] }, e.tryResult = []; }, addTryExecutionStep: (e, { payload: t }) => { - Eo(e, t); + jo(e, t); } }, extraReducers: (e) => { - e.addCase(as, (t, { payload: { oas: n, path: r, method: o } }) => { + e.addCase(ss, (t, { payload: { oas: n, path: r, method: o } }) => { t.operationId = void 0; }); } }), { - setOperationId: vj, - setScenarioId: bj, - resetMockOperationExecution: xj, - startTryExecution: kj, - addMockOperationExecutionStep: wj, - resetTryExecution: Sj, - addTryExecutionStep: _j -} = bu.actions, rm = bu.reducer, om = { + setOperationId: yj, + setScenarioId: vj, + resetMockOperationExecution: bj, + startTryExecution: xj, + addMockOperationExecutionStep: kj, + resetTryExecution: wj, + addTryExecutionStep: Sj +} = vu.actions, nm = vu.reducer, rm = { tryCurrent: { auth: [] }, tryResult: [], mockCurrent: { auth: [] }, mockResult: [], mockMissingVariables: [] -}, xu = Wt({ +}, bu = Wt({ name: "requests", - initialState: om, + initialState: rm, reducers: { setRequestId: (e, { payload: t }) => { e.ref = t, e.tryResult = []; @@ -2102,36 +2102,36 @@ const Jg = { e.tryCurrent = { auth: [] }, e.tryResult = []; }, addExecutionStep: (e, { payload: t }) => { - Eo(e, t); + jo(e, t); }, resetMockRequestExecution: (e) => { e.mockCurrent = { auth: [] }, e.mockResult = [], e.mockMissingVariables = []; }, addMockRequestExecutionStep: (e, { payload: t }) => { - To(e, t), (t.event === "payload-variables-substituted" || t.event === "credential-variables-substituted") && e.mockMissingVariables.push(...t.missing.map((n) => n.name)); + Eo(e, t), (t.event === "payload-variables-substituted" || t.event === "credential-variables-substituted") && e.mockMissingVariables.push(...t.missing.map((n) => n.name)); } }, extraReducers: (e) => { - e.addCase(as, (t, { payload: { oas: n, path: r, method: o } }) => { - const i = eh(n, r, o), s = th(i?.operationId, r, o); + e.addCase(ss, (t, { payload: { oas: n, path: r, method: o } }) => { + const i = ih(n, r, o), s = sh(i?.operationId, r, o); t.ref = { id: s, type: "operation" }; }); } }), { - setRequestId: Cj, - resetExecuteRequest: jj, - addExecutionStep: Ej, - executeRequest: ku, - resetMockRequestExecution: Tj, - addMockRequestExecutionStep: Oj -} = xu.actions, im = xu.reducer; -function sm(e) { + setRequestId: _j, + resetExecuteRequest: Cj, + addExecutionStep: jj, + executeRequest: xu, + resetMockRequestExecution: Ej, + addMockRequestExecutionStep: Tj +} = bu.actions, om = bu.reducer; +function im(e) { return async function(n, r) { - const o = crypto.randomUUID(), i = am(o); + const o = crypto.randomUUID(), i = sm(o); return e(o, n, r), i; }; } -async function am(e) { +async function sm(e) { return new Promise((t) => { function n(r) { const { command: o, payload: i } = r.data; @@ -2140,19 +2140,19 @@ async function am(e) { window.addEventListener("message", n); }); } -const lm = {}, wu = Wt({ +const am = {}, ku = Wt({ name: "file-picker", - initialState: lm, + initialState: am, reducers: { selectFile: (e, t) => { } } -}), { selectFile: cm } = wu.actions, um = $c; -function dm() { - const e = um(); - return sm((t, n, r) => e(cm({ id: t, title: n, extensions: r }))); +}), { selectFile: lm } = ku.actions, cm = Pc; +function um() { + const e = cm(); + return im((t, n, r) => e(lm({ id: t, title: n, extensions: r }))); } -const fm = wu.reducer, hm = { +const dm = ku.reducer, fm = { changes: [], scanconf: "", oas: { @@ -2161,9 +2161,9 @@ const fm = wu.reducer, hm = { paths: { "/": { get: { responses: {} } } } }, updating: !1 -}, Su = Wt({ +}, wu = Wt({ name: "scanconfUpdate", - initialState: hm, + initialState: fm, reducers: { showChanges: (e, t) => { e.changes = t.payload.changes, e.scanconf = t.payload.scanconf, e.oas = t.payload.oas, e.updating = !1; @@ -2174,52 +2174,52 @@ const fm = wu.reducer, hm = { skipScanconfUpdate: (e) => { } } -}), { updateScanconf: pm, showChanges: Pj, skipScanconfUpdate: gm } = Su.actions, mm = Su.reducer, ym = { - theme: Af, - client: Jh, - scanconf: Yg, - scanconfUpdate: mm, - operations: rm, - requests: im, - auth: Zg, - router: If, - env: dh, - prefs: Fh, - config: Qh, - global: tm, - generalError: mh, - confirmationDialog: zf, - filePicker: fm -}, $j = { - changeTheme: Df, - showHttpError: Fg, - showHttpResponse: Lg, - showScanconfOperation: as, - loadUpdatedScanconf: Rg, - loadEnv: uh, - loadConfig: Yh, - loadPrefs: Lh, - showGeneralError: gh, +}), { updateScanconf: hm, showChanges: Oj, skipScanconfUpdate: pm } = wu.actions, gm = wu.reducer, mm = { + theme: If, + client: Qh, + scanconf: Xg, + scanconfUpdate: gm, + operations: nm, + requests: om, + auth: Jg, + router: zf, + env: Zf, + prefs: Lh, + config: Yh, + global: em, + generalError: gh, + confirmationDialog: Df, + filePicker: dm +}, Pj = { + changeTheme: $f, + showHttpError: Lg, + showHttpResponse: Mg, + showScanconfOperation: ss, + loadUpdatedScanconf: Ng, + loadEnv: Jf, + loadConfig: Xh, + loadPrefs: Mh, + showGeneralError: ph, loadFile: () => null, cancelFile: () => null -}, Dj = (e, t) => $f({ - reducer: ym, - middleware: (n) => n().prepend(e.middleware).concat(Nf), +}, $j = (e, t) => Pf({ + reducer: mm, + middleware: (n) => n().prepend(e.middleware).concat(Af), preloadedState: { theme: t } -}), lt = () => $c(), xe = Rf; +}), ct = () => Pc(), xe = Nf; function Yn({ isOpen: e, setOpen: t, ...n }) { - return t !== void 0 && e !== void 0 ? _u({ ...n, isOpen: e, setOpen: t }) : vm({ ...n }); + return t !== void 0 && e !== void 0 ? Su({ ...n, isOpen: e, setOpen: t }) : ym({ ...n }); } -function vm({ +function ym({ defaultOpen: e, ...t }) { const [n, r] = A.useState(e !== void 0 ? e : !0); - return _u({ ...t, isOpen: n, setOpen: r }); + return Su({ ...t, isOpen: n, setOpen: r }); } -function _u({ +function Su({ isOpen: e, setOpen: t, title: n, @@ -2227,33 +2227,33 @@ function _u({ menu: o, children: i }) { - return /* @__PURE__ */ c.jsxs(bm, { children: [ + return /* @__PURE__ */ c.jsxs(vm, { children: [ /* @__PURE__ */ c.jsxs( - xm, + bm, { onClick: (s) => { s.preventDefault(), s.stopPropagation(), t(!e); }, children: [ - e ? /* @__PURE__ */ c.jsx(ph, {}) : /* @__PURE__ */ c.jsx(bo, {}), - /* @__PURE__ */ c.jsxs(km, { children: [ - typeof n == "string" ? /* @__PURE__ */ c.jsx(wm, { children: n }) : n, - !!r && /* @__PURE__ */ c.jsx(jm, { children: r }), - o && /* @__PURE__ */ c.jsx(Sm, { children: o }) + e ? /* @__PURE__ */ c.jsx(hh, {}) : /* @__PURE__ */ c.jsx(vo, {}), + /* @__PURE__ */ c.jsxs(xm, { children: [ + typeof n == "string" ? /* @__PURE__ */ c.jsx(km, { children: n }) : n, + !!r && /* @__PURE__ */ c.jsx(Cm, { children: r }), + o && /* @__PURE__ */ c.jsx(wm, { children: o }) ] }) ] } ), - e && /* @__PURE__ */ c.jsxs(_m, { children: [ - /* @__PURE__ */ c.jsx(Cm, {}), + e && /* @__PURE__ */ c.jsxs(Sm, { children: [ + /* @__PURE__ */ c.jsx(_m, {}), /* @__PURE__ */ c.jsx("div", { children: i }) ] }) ] }); } -const bm = E.div` +const vm = E.div` margin-top: 8px; margin-bottom: 8px; -`, xm = E.div` +`, bm = E.div` display: flex; cursor: pointer; flex-direction: row; @@ -2274,30 +2274,30 @@ const bm = E.div` opacity: 1; } } -`, km = E.div` +`, xm = E.div` flex: 1; display: flex; gap: 8px; -`, wm = E.div` +`, km = E.div` font-size: 14px; font-weight: 600; -`, Sm = E.div` +`, wm = E.div` flex: 1; display: flex; align-items: center; justify-content: flex-end; -`, _m = E.div` +`, Sm = E.div` display: flex; flex-direction: row; > div:last-child { flex: 1; margin-left: 8px; } -`, Cm = E.div` +`, _m = E.div` width: 2px; background-color: var(${w.border}); margin: 0px 6px; -`, jm = E.span` +`, Cm = E.span` background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px; @@ -2307,18 +2307,18 @@ const bm = E.div` font-size: 10px; padding: 2px 4px; `; -function Em({ +function jm({ title: e, icon: t, className: n }) { - return /* @__PURE__ */ c.jsxs(Tm, { className: n, children: [ + return /* @__PURE__ */ c.jsxs(Em, { className: n, children: [ t, /* @__PURE__ */ c.jsx("div", { children: e }), /* @__PURE__ */ c.jsx("hr", {}) ] }); } -const Tm = E.div` +const Em = E.div` display: flex; gap: 8px; cursor: pointer; @@ -2341,15 +2341,15 @@ function Un({ children: t, ...n }) { - return /* @__PURE__ */ c.jsxs(Pm, { ...n, children: [ + return /* @__PURE__ */ c.jsxs(Om, { ...n, children: [ /* @__PURE__ */ c.jsxs("div", { children: [ - /* @__PURE__ */ c.jsx("div", { children: /* @__PURE__ */ c.jsx(wt, {}) }), + /* @__PURE__ */ c.jsx("div", { children: /* @__PURE__ */ c.jsx(St, {}) }), /* @__PURE__ */ c.jsx("span", { children: e }) ] }), t && /* @__PURE__ */ c.jsx("div", { children: t }) ] }); } -const Om = E.div` +const Tm = E.div` display: flex; flex-direction: column; > div:first-child { @@ -2369,7 +2369,7 @@ const Om = E.div` color: var(${w.foreground}); padding: 8px; gap: 8px; -`, Pm = E(Om)` +`, Om = E(Tm)` border: 1px solid var(${w.errorBorder}); background-color: var(${w.errorBackground}); color: var(${w.errorForeground}); @@ -2383,24 +2383,24 @@ const Om = E.div` } } `; -var ls = "ContextMenu", [$m] = Lf(ls, [ - Kc -]), Ce = Kc(), [Dm, Cu] = $m(ls), ju = (e) => { - const { __scopeContextMenu: t, children: n, onOpenChange: r, dir: o, modal: i = !0 } = e, [s, a] = A.useState(!1), l = Ce(t), u = Mf(r), d = A.useCallback( +var as = "ContextMenu", [Pm] = Mf(as, [ + Wc +]), Ce = Wc(), [$m, _u] = Pm(as), Cu = (e) => { + const { __scopeContextMenu: t, children: n, onOpenChange: r, dir: o, modal: i = !0 } = e, [s, a] = A.useState(!1), l = Ce(t), u = Rf(r), d = A.useCallback( (h) => { a(h), u(h); }, [u] ); return /* @__PURE__ */ c.jsx( - Dm, + $m, { scope: t, open: s, onOpenChange: d, modal: i, children: /* @__PURE__ */ c.jsx( - Sh, + wh, { ...l, dir: o, @@ -2413,10 +2413,10 @@ var ls = "ContextMenu", [$m] = Lf(ls, [ } ); }; -ju.displayName = ls; -var Eu = "ContextMenuTrigger", Tu = A.forwardRef( +Cu.displayName = as; +var ju = "ContextMenuTrigger", Eu = A.forwardRef( (e, t) => { - const { __scopeContextMenu: n, disabled: r = !1, ...o } = e, i = Cu(Eu, n), s = Ce(n), a = A.useRef({ x: 0, y: 0 }), l = A.useRef({ + const { __scopeContextMenu: n, disabled: r = !1, ...o } = e, i = _u(ju, n), s = Ce(n), a = A.useRef({ x: 0, y: 0 }), l = A.useRef({ getBoundingClientRect: () => DOMRect.fromRect({ width: 0, height: 0, ...a.current }) }), u = A.useRef(0), d = A.useCallback( () => window.clearTimeout(u.current), @@ -2427,9 +2427,9 @@ var Eu = "ContextMenuTrigger", Tu = A.forwardRef( return A.useEffect(() => d, [d]), A.useEffect(() => { r && d(); }, [r, d]), /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsx(_h, { ...s, virtualRef: l }), + /* @__PURE__ */ c.jsx(Sh, { ...s, virtualRef: l }), /* @__PURE__ */ c.jsx( - Ff.span, + Lf.span, { "data-state": i.open ? "open" : "closed", "data-disabled": r ? "" : void 0, @@ -2453,17 +2453,17 @@ var Eu = "ContextMenuTrigger", Tu = A.forwardRef( ] }); } ); -Tu.displayName = Eu; -var zm = "ContextMenuPortal", Ou = (e) => { +Eu.displayName = ju; +var Dm = "ContextMenuPortal", Tu = (e) => { const { __scopeContextMenu: t, ...n } = e, r = Ce(t); - return /* @__PURE__ */ c.jsx(Ch, { ...r, ...n }); + return /* @__PURE__ */ c.jsx(_h, { ...r, ...n }); }; -Ou.displayName = zm; -var Pu = "ContextMenuContent", $u = A.forwardRef( +Tu.displayName = Dm; +var Ou = "ContextMenuContent", Pu = A.forwardRef( (e, t) => { - const { __scopeContextMenu: n, ...r } = e, o = Cu(Pu, n), i = Ce(n), s = A.useRef(!1); + const { __scopeContextMenu: n, ...r } = e, o = _u(Ou, n), i = Ce(n), s = A.useRef(!1); return /* @__PURE__ */ c.jsx( - jh, + Ch, { ...i, ...r, @@ -2489,69 +2489,69 @@ var Pu = "ContextMenuContent", $u = A.forwardRef( ); } ); -$u.displayName = Pu; -var Im = "ContextMenuGroup", Am = A.forwardRef( +Pu.displayName = Ou; +var zm = "ContextMenuGroup", Im = A.forwardRef( (e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); - return /* @__PURE__ */ c.jsx(Eh, { ...o, ...r, ref: t }); + return /* @__PURE__ */ c.jsx(jh, { ...o, ...r, ref: t }); } ); -Am.displayName = Im; -var Nm = "ContextMenuLabel", Rm = A.forwardRef( +Im.displayName = zm; +var Am = "ContextMenuLabel", Nm = A.forwardRef( (e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); - return /* @__PURE__ */ c.jsx(Th, { ...o, ...r, ref: t }); + return /* @__PURE__ */ c.jsx(Eh, { ...o, ...r, ref: t }); } ); -Rm.displayName = Nm; -var Mm = "ContextMenuItem", Du = A.forwardRef( +Nm.displayName = Am; +var Rm = "ContextMenuItem", $u = A.forwardRef( (e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); - return /* @__PURE__ */ c.jsx(Oh, { ...o, ...r, ref: t }); + return /* @__PURE__ */ c.jsx(Th, { ...o, ...r, ref: t }); } ); -Du.displayName = Mm; -var Lm = "ContextMenuCheckboxItem", Fm = A.forwardRef((e, t) => { +$u.displayName = Rm; +var Mm = "ContextMenuCheckboxItem", Lm = A.forwardRef((e, t) => { + const { __scopeContextMenu: n, ...r } = e, o = Ce(n); + return /* @__PURE__ */ c.jsx(Oh, { ...o, ...r, ref: t }); +}); +Lm.displayName = Mm; +var Fm = "ContextMenuRadioGroup", qm = A.forwardRef((e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); return /* @__PURE__ */ c.jsx(Ph, { ...o, ...r, ref: t }); }); -Fm.displayName = Lm; -var qm = "ContextMenuRadioGroup", Bm = A.forwardRef((e, t) => { +qm.displayName = Fm; +var Bm = "ContextMenuRadioItem", Um = A.forwardRef((e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); return /* @__PURE__ */ c.jsx($h, { ...o, ...r, ref: t }); }); -Bm.displayName = qm; -var Um = "ContextMenuRadioItem", Hm = A.forwardRef((e, t) => { +Um.displayName = Bm; +var Hm = "ContextMenuItemIndicator", Vm = A.forwardRef((e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); return /* @__PURE__ */ c.jsx(Dh, { ...o, ...r, ref: t }); }); -Hm.displayName = Um; -var Vm = "ContextMenuItemIndicator", Wm = A.forwardRef((e, t) => { +Vm.displayName = Hm; +var Wm = "ContextMenuSeparator", Km = A.forwardRef((e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); return /* @__PURE__ */ c.jsx(zh, { ...o, ...r, ref: t }); }); -Wm.displayName = Vm; -var Km = "ContextMenuSeparator", Gm = A.forwardRef((e, t) => { - const { __scopeContextMenu: n, ...r } = e, o = Ce(n); - return /* @__PURE__ */ c.jsx(Ih, { ...o, ...r, ref: t }); -}); -Gm.displayName = Km; -var Xm = "ContextMenuArrow", Ym = A.forwardRef( +Km.displayName = Wm; +var Gm = "ContextMenuArrow", Xm = A.forwardRef( (e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); - return /* @__PURE__ */ c.jsx(Ah, { ...o, ...r, ref: t }); + return /* @__PURE__ */ c.jsx(Ih, { ...o, ...r, ref: t }); } ); -Ym.displayName = Xm; -var Qm = "ContextMenuSubTrigger", Jm = A.forwardRef((e, t) => { +Xm.displayName = Gm; +var Ym = "ContextMenuSubTrigger", Qm = A.forwardRef((e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); - return /* @__PURE__ */ c.jsx(Nh, { ...o, ...r, ref: t }); + return /* @__PURE__ */ c.jsx(Ah, { ...o, ...r, ref: t }); }); -Jm.displayName = Qm; -var Zm = "ContextMenuSubContent", ey = A.forwardRef((e, t) => { +Qm.displayName = Ym; +var Jm = "ContextMenuSubContent", Zm = A.forwardRef((e, t) => { const { __scopeContextMenu: n, ...r } = e, o = Ce(n); return /* @__PURE__ */ c.jsx( - Rh, + Nh, { ...o, ...r, @@ -2567,21 +2567,21 @@ var Zm = "ContextMenuSubContent", ey = A.forwardRef((e, t) => { } ); }); -ey.displayName = Zm; +Zm.displayName = Jm; function Sr(e) { return (t) => t.pointerType !== "mouse" ? e(t) : void 0; } -var ty = ju, ny = Tu, ry = Ou, oy = $u, iy = Du; -function sy({ +var ey = Cu, ty = Eu, ny = Tu, ry = Pu, oy = $u; +function iy({ children: e, menu: t }) { - return /* @__PURE__ */ c.jsxs(ty, { children: [ - /* @__PURE__ */ c.jsx(ny, { asChild: !0, className: "menu", children: e }), - /* @__PURE__ */ c.jsx(ry, { children: /* @__PURE__ */ c.jsx(ay, { children: t }) }) + return /* @__PURE__ */ c.jsxs(ey, { children: [ + /* @__PURE__ */ c.jsx(ty, { asChild: !0, className: "menu", children: e }), + /* @__PURE__ */ c.jsx(ny, { children: /* @__PURE__ */ c.jsx(sy, { children: t }) }) ] }); } -const ay = E(oy)` +const sy = E(ry)` margin: 4px; background-color: var(${w.dropdownBackground}); border: 1px solid var(${w.dropdownBorder}); @@ -2589,7 +2589,7 @@ const ay = E(oy)` min-width: 220px; padding: 5px; box-shadow: 0 10px 38px var(${w.computedTwo}); -`, Na = E(iy)` +`, Aa = E(oy)` margin: 2px; color: var(${w.dropdownForeground}); display: flex; @@ -2608,7 +2608,7 @@ const ay = E(oy)` fill: var(${w.foreground}); } `; -function zu({ +function Du({ onSubmit: e, defaultValues: t, trigger: n, @@ -2620,29 +2620,29 @@ function zu({ open: l, onOpenChange: u }) { - const d = ah({ + const d = th({ values: t, - resolver: i !== void 0 ? hh(i) : void 0 + resolver: i !== void 0 ? fh(i) : void 0 }), [h, f] = A.useState(!1), p = l ?? h, g = u ?? f; return A.useEffect(() => { p && d.reset(); - }, [p]), /* @__PURE__ */ c.jsxs(qf, { open: p, onOpenChange: g, children: [ - n && /* @__PURE__ */ c.jsx(Bf, { asChild: !0, children: n }), - /* @__PURE__ */ c.jsxs(Uf, { children: [ - /* @__PURE__ */ c.jsx(cy, {}), - /* @__PURE__ */ c.jsx(uy, { $noOverflow: a, children: /* @__PURE__ */ c.jsx(lh, { ...d, children: /* @__PURE__ */ c.jsxs( - ly, + }, [p]), /* @__PURE__ */ c.jsxs(Ff, { open: p, onOpenChange: g, children: [ + n && /* @__PURE__ */ c.jsx(qf, { asChild: !0, children: n }), + /* @__PURE__ */ c.jsxs(Bf, { children: [ + /* @__PURE__ */ c.jsx(ly, {}), + /* @__PURE__ */ c.jsx(cy, { $noOverflow: a, children: /* @__PURE__ */ c.jsx(nh, { ...d, children: /* @__PURE__ */ c.jsxs( + ay, { onSubmit: d.handleSubmit((m) => { e(m), g(!1); }), children: [ - r && /* @__PURE__ */ c.jsx(Hf, { children: r }), - o && /* @__PURE__ */ c.jsx(Vf, { children: o }), - /* @__PURE__ */ c.jsx(dy, { children: s }), + r && /* @__PURE__ */ c.jsx(Uf, { children: r }), + o && /* @__PURE__ */ c.jsx(Hf, { children: o }), + /* @__PURE__ */ c.jsx(uy, { children: s }), /* @__PURE__ */ c.jsxs("div", { style: { display: "flex", marginTop: 25, justifyContent: "flex-end", gap: 4 }, children: [ - /* @__PURE__ */ c.jsx(Wf, { type: "submit", children: "Ok" }), - /* @__PURE__ */ c.jsx(Kf, { asChild: !0, children: /* @__PURE__ */ c.jsx(Dc, { children: "Cancel" }) }) + /* @__PURE__ */ c.jsx(Vf, { type: "submit", children: "Ok" }), + /* @__PURE__ */ c.jsx(Wf, { asChild: !0, children: /* @__PURE__ */ c.jsx($c, { children: "Cancel" }) }) ] }) ] } @@ -2650,16 +2650,16 @@ function zu({ ] }) ] }); } -const ly = E.form` +const ay = E.form` margin: 8px; display: flex; flex-direction: column; gap: 8px; -`, cy = E(Gf)` +`, ly = E(Kf)` background-color: var(${w.computedTwo}); position: fixed; inset: 0; -`, uy = E(Xf)` +`, cy = E(Gf)` position: fixed; top: 50%; left: 50%; @@ -2673,13 +2673,13 @@ const ly = E.form` color: var(${w.foreground}); border-radius: 6px; box-shadow: hsl(206 22% 7% / 35%) 0px 10px 38px -10px, hsl(206 22% 7% / 20%) 0px 10px 20px -15px; -`, dy = E.div` +`, uy = E.div` display: flex; flex: 1; flex-direction: column; gap: 8px; `; -function fy({ +function dy({ open: e, onOpenChange: t, onCreateVariable: n, @@ -2688,9 +2688,9 @@ function fy({ const o = { varname: "", jsonPointer: r - }, i = [], s = Uc({ - varname: qn().min(1).regex(Ic(), { - message: Ac + }, i = [], s = Bc({ + varname: qn().min(1).regex(zc(), { + message: Ic }).refine((l) => !i.includes(l), { message: "Already exists" }), @@ -2699,7 +2699,7 @@ function fy({ n(l.varname, l.jsonPointer); }; return /* @__PURE__ */ c.jsx( - zu, + Du, { title: "Create variable", defaultValues: o, @@ -2707,33 +2707,33 @@ function fy({ onSubmit: a, open: e, onOpenChange: t, - children: /* @__PURE__ */ c.jsxs(hy, { children: [ + children: /* @__PURE__ */ c.jsxs(fy, { children: [ /* @__PURE__ */ c.jsx(Pe, { label: "Name", name: "varname" }), - /* @__PURE__ */ c.jsx(Mh, { label: "JSON Pointer", name: "jsonPointer" }) + /* @__PURE__ */ c.jsx(Rh, { label: "JSON Pointer", name: "jsonPointer" }) ] }) } ); } -const hy = E.div` +const fy = E.div` padding: 8px; gap: 8px; display: flex; flex-direction: column; `; -function Iu({ +function zu({ value: e, menuHandlers: t }) { - return /* @__PURE__ */ c.jsx(cs, { path: [], value: e, trailingComma: !1, menuHandlers: t }); + return /* @__PURE__ */ c.jsx(ls, { path: [], value: e, trailingComma: !1, menuHandlers: t }); } -function cs({ +function ls({ value: e, trailingComma: t, menuHandlers: n, path: r }) { return typeof e == "object" ? Array.isArray(e) ? /* @__PURE__ */ c.jsx( - gy, + py, { array: e, path: r, @@ -2741,7 +2741,7 @@ function cs({ trailingComma: t } ) : /* @__PURE__ */ c.jsx( - py, + hy, { object: e, path: r, @@ -2749,7 +2749,7 @@ function cs({ trailingComma: t } ) : /* @__PURE__ */ c.jsx( - my, + gy, { value: e, path: r, @@ -2758,7 +2758,7 @@ function cs({ } ); } -function py({ +function hy({ object: e, trailingComma: t, menuHandlers: n, @@ -2767,12 +2767,12 @@ function py({ if (e === null) return /* @__PURE__ */ c.jsx("code", { children: "null" }); const o = Object.entries(e); - return o.length === 0 ? /* @__PURE__ */ c.jsx("code", { children: t ? "{}," : "{}" }) : /* @__PURE__ */ c.jsxs(Au, { children: [ + return o.length === 0 ? /* @__PURE__ */ c.jsx("code", { children: t ? "{}," : "{}" }) : /* @__PURE__ */ c.jsxs(Iu, { children: [ /* @__PURE__ */ c.jsx("code", { children: "{" }), /* @__PURE__ */ c.jsx("div", { style: { marginLeft: "20px" }, children: o.map(([i, s], a, l) => /* @__PURE__ */ c.jsxs("div", { children: [ /* @__PURE__ */ c.jsx("code", { children: `"${i}": ` }), /* @__PURE__ */ c.jsx( - cs, + ls, { value: s, path: [...r, i], @@ -2784,16 +2784,16 @@ function py({ /* @__PURE__ */ c.jsx("code", { children: t ? "}," : "}" }) ] }); } -function gy({ +function py({ array: e, trailingComma: t, menuHandlers: n, path: r }) { - return /* @__PURE__ */ c.jsxs(Au, { children: [ + return /* @__PURE__ */ c.jsxs(Iu, { children: [ /* @__PURE__ */ c.jsx("code", { children: "[" }), /* @__PURE__ */ c.jsx("div", { style: { marginLeft: "20px" }, children: e.map((o, i) => /* @__PURE__ */ c.jsx("div", { children: /* @__PURE__ */ c.jsx( - cs, + ls, { value: o, path: [...r, i], @@ -2804,30 +2804,30 @@ function gy({ /* @__PURE__ */ c.jsx("code", { children: t ? "]," : "]" }) ] }); } -function my({ +function gy({ value: e, trailingComma: t, menuHandlers: n, path: r }) { - const o = JSON.stringify(e), [i, s] = A.useState(!1), a = /* @__PURE__ */ c.jsxs(yy, { children: [ + const o = JSON.stringify(e), [i, s] = A.useState(!1), a = /* @__PURE__ */ c.jsxs(my, { children: [ /* @__PURE__ */ c.jsx("span", { children: o }), t && /* @__PURE__ */ c.jsx("span", { children: "," }) ] }); if (n) { const l = /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsxs(Na, { onSelect: () => n.onCopy(o), children: [ - /* @__PURE__ */ c.jsx(Zh, {}), + /* @__PURE__ */ c.jsxs(Aa, { onSelect: () => n.onCopy(o), children: [ + /* @__PURE__ */ c.jsx(Jh, {}), "Copy" ] }), - /* @__PURE__ */ c.jsxs(Na, { onSelect: () => s(!0), children: [ - /* @__PURE__ */ c.jsx(Qc, {}), + /* @__PURE__ */ c.jsxs(Aa, { onSelect: () => s(!0), children: [ + /* @__PURE__ */ c.jsx(Yc, {}), "Create variable" ] }) - ] }), u = St.joinJsonPointer(r); + ] }), u = Re.joinJsonPointer(r); return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx( - fy, + dy, { open: i, onOpenChange: s, @@ -2835,41 +2835,41 @@ function my({ onCreateVariable: n.onCreateVariable } ), - /* @__PURE__ */ c.jsx(sy, { menu: l, children: a }) + /* @__PURE__ */ c.jsx(iy, { menu: l, children: a }) ] }); } else return a; } -const Au = E.div` +const Iu = E.div` code { color: var(${w.foreground}); background-color: var(${w.background}); border: none; padding: none; } -`, yy = E.span` +`, my = E.span` & > span:first-child { &:hover { background-color: var(${w.computedOne}); } } `; -function vy({ +function yy({ request: e, requestRef: t, statusCode: n }) { - return /* @__PURE__ */ c.jsx(wy, { children: xy(e) ? /* @__PURE__ */ c.jsx(by, { body: e.body, requestRef: t, statusCode: n }) : /* @__PURE__ */ c.jsx(ky, { children: e?.body !== void 0 && `${e.body}` }) }); + return /* @__PURE__ */ c.jsx(ky, { children: by(e) ? /* @__PURE__ */ c.jsx(vy, { body: e.body, requestRef: t, statusCode: n }) : /* @__PURE__ */ c.jsx(xy, { children: e?.body !== void 0 && `${e.body}` }) }); } -function by({ +function vy({ body: e, requestRef: t, statusCode: n }) { - const r = lt(); + const r = ct(); try { return /* @__PURE__ */ c.jsx( - Iu, + zu, { value: JSON.parse(e), menuHandlers: { @@ -2878,7 +2878,7 @@ function by({ }, onCreateVariable: (o, i) => { t !== void 0 && n !== void 0 && r( - gu({ + pu({ name: o, location: "request", jsonPointer: i, @@ -2893,13 +2893,13 @@ function by({ } catch { } } -function xy(e) { +function by(e) { for (const [t, n] of Object.entries(e.headers)) if (t.toLowerCase() === "content-type" && n.includes("json")) return !0; return !1; } -const ky = E.div``, wy = E.div` +const xy = E.div``, ky = E.div` padding: 4px 8px; white-space: pre-wrap; word-break: break-all; @@ -2907,22 +2907,22 @@ const ky = E.div``, wy = E.div` max-height: 400px; overflow-y: auto; `; -function Sy({ headers: e }) { - return /* @__PURE__ */ c.jsxs(_y, { children: [ - /* @__PURE__ */ c.jsxs(Cy, { children: [ +function wy({ headers: e }) { + return /* @__PURE__ */ c.jsxs(Sy, { children: [ + /* @__PURE__ */ c.jsxs(_y, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", { children: "Value" }) ] }), - Object.entries(e).map(([t, n], r) => /* @__PURE__ */ c.jsxs(jy, { children: [ + Object.entries(e).map(([t, n], r) => /* @__PURE__ */ c.jsxs(Cy, { children: [ /* @__PURE__ */ c.jsx("div", { children: t }), /* @__PURE__ */ c.jsx("div", { children: n }) ] }, r)) ] }); } -const _y = E.div` +const Sy = E.div` display: grid; grid-template-columns: 2fr 5fr; -`, Cy = E.div` +`, _y = E.div` display: contents; & > div { padding: 4px 8px; @@ -2931,7 +2931,7 @@ const _y = E.div` font-size: 90%; font-weight: 600; } -`, jy = E.div` +`, Cy = E.div` display: contents; > div { padding: 4px 8px; @@ -2940,17 +2940,17 @@ const _y = E.div` font-family: monospace; } `; -function Ey({ +function jy({ operationId: e, request: t, defaultCollapsed: n, requestRef: r, statusCode: o }) { - return /* @__PURE__ */ c.jsx(Ty, { children: /* @__PURE__ */ c.jsxs(wn, { defaultCollapsed: n, children: [ + return /* @__PURE__ */ c.jsx(Ey, { children: /* @__PURE__ */ c.jsxs(wn, { defaultCollapsed: n, children: [ /* @__PURE__ */ c.jsxs(Sn, { style: { gap: "8px" }, children: [ /* @__PURE__ */ c.jsx( - Yc, + Xc, { style: { width: 14, @@ -2961,8 +2961,8 @@ function Ey({ } } ), - /* @__PURE__ */ c.jsx(Oy, { children: t.method }), - /* @__PURE__ */ c.jsx(Py, { children: t.url }) + /* @__PURE__ */ c.jsx(Ty, { children: t.method }), + /* @__PURE__ */ c.jsx(Oy, { children: t.url }) ] }), /* @__PURE__ */ c.jsx( kn, @@ -2971,24 +2971,24 @@ function Ey({ { id: "body", title: "Body", - content: /* @__PURE__ */ c.jsx(Ra, { children: /* @__PURE__ */ c.jsx(vy, { request: t, requestRef: r, statusCode: o }) }), + content: /* @__PURE__ */ c.jsx(Na, { children: /* @__PURE__ */ c.jsx(yy, { request: t, requestRef: r, statusCode: o }) }), disabled: t.body === void 0 }, { id: "headers", title: "Headers", - content: /* @__PURE__ */ c.jsx(Ra, { children: /* @__PURE__ */ c.jsx(Sy, { headers: t.headers }) }) + content: /* @__PURE__ */ c.jsx(Na, { children: /* @__PURE__ */ c.jsx(wy, { headers: t.headers }) }) } ] } ) ] }) }); } -const Ty = E.div` +const Ey = E.div` > div { background-color: var(${w.background}); } -`, Oy = E.div` +`, Ty = E.div` background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px; @@ -3001,54 +3001,54 @@ const Ty = E.div` min-height: 16px; text-transform: uppercase; font-size: 11px; -`, Py = E.div` +`, Oy = E.div` line-break: anywhere; -`, Ra = E.div` +`, Na = E.div` padding: 8px; `; -function $y({ +function Py({ name: e, value: t, variables: n, hasMissing: r }) { return /* @__PURE__ */ c.jsxs(wn, { children: [ - /* @__PURE__ */ c.jsx(Sn, { style: { gap: "8px" }, children: /* @__PURE__ */ c.jsxs(to, { children: [ - /* @__PURE__ */ c.jsx(Qc, {}), + /* @__PURE__ */ c.jsx(Sn, { style: { gap: "8px" }, children: /* @__PURE__ */ c.jsxs(eo, { children: [ + /* @__PURE__ */ c.jsx(Yc, {}), "Credential value", - r && /* @__PURE__ */ c.jsx(xo, { style: { fill: `var(${w.errorForeground})` } }), - r && /* @__PURE__ */ c.jsxs(Dy, { children: [ + r && /* @__PURE__ */ c.jsx(bo, { style: { fill: `var(${w.errorForeground})` } }), + r && /* @__PURE__ */ c.jsxs($y, { children: [ "Missing ", n?.missing?.map((o) => `{{${o.name}}}`)?.join(", ") ] }) ] }) }), - /* @__PURE__ */ c.jsx(zy, { children: t }) + /* @__PURE__ */ c.jsx(Dy, { children: t }) ] }); } -const Dy = E.div` +const $y = E.div` color: var(${w.errorForeground}); border-radius: 4px; -`, zy = E.div` +`, Dy = E.div` font-family: monospace; padding: 8px; line-break: anywhere; `; -function Iy({ +function zy({ results: e }) { - const t = Ry(e); - return /* @__PURE__ */ c.jsx(Ay, { children: /* @__PURE__ */ c.jsxs(wn, { children: [ + const t = Ny(e); + return /* @__PURE__ */ c.jsx(Iy, { children: /* @__PURE__ */ c.jsxs(wn, { children: [ /* @__PURE__ */ c.jsxs(Sn, { style: { gap: "8px" }, children: [ - /* @__PURE__ */ c.jsx(to, { children: /* @__PURE__ */ c.jsx(ep, {}) }), - t.map((n, r) => /* @__PURE__ */ c.jsxs(to, { children: [ + /* @__PURE__ */ c.jsx(eo, { children: /* @__PURE__ */ c.jsx(Zh, {}) }), + t.map((n, r) => /* @__PURE__ */ c.jsxs(eo, { children: [ n.name, - Ly(n) + My(n) ] }, r)) ] }), - /* @__PURE__ */ c.jsx(Ny, { children: t.map((n, r) => /* @__PURE__ */ c.jsxs(ln.Fragment, { children: [ - n.execution[0] && /* @__PURE__ */ c.jsx(Nu, { playbook: n.execution[0] }), + /* @__PURE__ */ c.jsx(Ay, { children: t.map((n, r) => /* @__PURE__ */ c.jsxs(ln.Fragment, { children: [ + n.execution[0] && /* @__PURE__ */ c.jsx(Au, { playbook: n.execution[0] }), n.value && /* @__PURE__ */ c.jsx( - $y, + Py, { name: n.name, value: n.value, @@ -3060,17 +3060,17 @@ function Iy({ ] }, r)) }) ] }) }); } -const Ay = E.div` +const Iy = E.div` > div { background-color: var(${w.background}); } -`, Ny = E.div` +`, Ay = E.div` padding: 8px; display: flex; flex-flow: column; gap: 8px; `; -function Ry(e) { +function Ny(e) { return Object.entries(e).map(([t, n]) => { const r = n?.variables?.missing?.length; return { @@ -3078,48 +3078,48 @@ function Ry(e) { value: n.result, error: n.error, execution: n.execution, - status: My(n), + status: Ry(n), hasMissingVariables: r !== void 0 && r > 0, variables: n.variables }; }); } -function My(e) { +function Ry(e) { return e.error !== void 0 ? "failure" : e.execution?.some((n) => n.status === "pending") ? "pending" : e.result !== void 0 ? "success" : "failure"; } -function Ly({ +function My({ status: e, hasMissingVariables: t }) { - return e === "failure" || t ? /* @__PURE__ */ c.jsx(xo, { style: { fill: `var(${w.errorForeground})` } }) : e === "pending" ? /* @__PURE__ */ c.jsx(qy, {}) : /* @__PURE__ */ c.jsx(Jc, {}); + return e === "failure" || t ? /* @__PURE__ */ c.jsx(bo, { style: { fill: `var(${w.errorForeground})` } }) : e === "pending" ? /* @__PURE__ */ c.jsx(Fy, {}) : /* @__PURE__ */ c.jsx(Qc, {}); } -const Fy = zc` +const Ly = Dc` from { transform: rotate(0deg); } to { transform: rotate(359deg); } -`, qy = E(Wc)` - animation: ${Fy} 2s infinite linear; +`, Fy = E(Vc)` + animation: ${Ly} 2s infinite linear; transition: width 0.2s linear; `; -function By({ +function qy({ response: e, requestRef: t, statusCode: n }) { - return /* @__PURE__ */ c.jsx(Hy, { children: Wy(e) ? /* @__PURE__ */ c.jsx(Uy, { body: e.body, requestRef: t, statusCode: n }) : /* @__PURE__ */ c.jsx(Vy, { children: e?.body }) }); + return /* @__PURE__ */ c.jsx(Uy, { children: Vy(e) ? /* @__PURE__ */ c.jsx(By, { body: e.body, requestRef: t, statusCode: n }) : /* @__PURE__ */ c.jsx(Hy, { children: e?.body }) }); } -function Uy({ +function By({ body: e, requestRef: t, statusCode: n }) { - const r = lt(); + const r = ct(); try { return /* @__PURE__ */ c.jsx( - Iu, + zu, { value: JSON.parse(e), menuHandlers: { @@ -3128,7 +3128,7 @@ function Uy({ }, onCreateVariable: (o, i) => { t !== void 0 && n !== void 0 && r( - gu({ + pu({ name: o, location: "response", jsonPointer: i, @@ -3143,37 +3143,37 @@ function Uy({ } catch { } } -const Hy = E.div` +const Uy = E.div` white-space: pre-wrap; word-break: break-all; font-family: monospace; padding: 8px; max-height: 400px; overflow-y: auto; -`, Vy = E.div``; -function Wy(e) { +`, Hy = E.div``; +function Vy(e) { for (const [t, n] of e.headers) if (t.toLowerCase() === "content-type" && n.includes("json")) return !0; return !1; } -function Ky({ headers: e }) { - return /* @__PURE__ */ c.jsxs(Gy, { children: [ - /* @__PURE__ */ c.jsxs(Xy, { children: [ +function Wy({ headers: e }) { + return /* @__PURE__ */ c.jsxs(Ky, { children: [ + /* @__PURE__ */ c.jsxs(Gy, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", { children: "Value" }) ] }), - e.map(([t, n], r) => /* @__PURE__ */ c.jsxs(Yy, { children: [ + e.map(([t, n], r) => /* @__PURE__ */ c.jsxs(Xy, { children: [ /* @__PURE__ */ c.jsx("div", { children: t }), /* @__PURE__ */ c.jsx("div", { children: n }) ] }, r)) ] }); } -const Gy = E.div` +const Ky = E.div` padding: 8px; display: grid; grid-template-columns: 2fr 5fr; -`, Xy = E.div` +`, Gy = E.div` display: contents; & > div { padding: 4px 8px; @@ -3182,7 +3182,7 @@ const Gy = E.div` font-size: 90%; font-weight: 600; } -`, Yy = E.div` +`, Xy = E.div` display: contents; > div { padding: 4px 8px; @@ -3191,42 +3191,42 @@ const Gy = E.div` font-family: monospace; } `; -function Qy({ assignment: e }) { - return /* @__PURE__ */ c.jsxs(nv, { children: [ - /* @__PURE__ */ c.jsxs(rv, { children: [ +function Yy({ assignment: e }) { + return /* @__PURE__ */ c.jsxs(tv, { children: [ + /* @__PURE__ */ c.jsxs(nv, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", { children: "Value" }), /* @__PURE__ */ c.jsx("div", {}) ] }), - /* @__PURE__ */ c.jsx(ov, { children: e.flatMap((t, n) => Jy(t.id, t.assignments, n)) }) + /* @__PURE__ */ c.jsx(rv, { children: e.flatMap((t, n) => Qy(t.id, t.assignments, n)) }) ] }); } -function Jy(e, t, n) { - return t.map((r, o) => /* @__PURE__ */ c.jsx(ln.Fragment, { children: r.error !== void 0 ? ev(e, r) : Zy(e, r) }, `${n}-${o}`)); +function Qy(e, t, n) { + return t.map((r, o) => /* @__PURE__ */ c.jsx(ln.Fragment, { children: r.error !== void 0 ? Zy(e, r) : Jy(e, r) }, `${n}-${o}`)); } -function Zy(e, t) { +function Jy(e, t) { return /* @__PURE__ */ c.jsxs(ln.Fragment, { children: [ /* @__PURE__ */ c.jsx("div", { children: t.name }), /* @__PURE__ */ c.jsx("div", { children: `${t.value}` }), /* @__PURE__ */ c.jsx("div", {}) ] }); } -function ev(e, t) { +function Zy(e, t) { return /* @__PURE__ */ c.jsxs(ln.Fragment, { children: [ /* @__PURE__ */ c.jsx("div", { children: t.name }), - /* @__PURE__ */ c.jsx("div", { children: tv(t.assignment, t.error) }), - /* @__PURE__ */ c.jsx(iv, { children: /* @__PURE__ */ c.jsx(wt, {}) }) + /* @__PURE__ */ c.jsx("div", { children: ev(t.assignment, t.error) }), + /* @__PURE__ */ c.jsx(ov, { children: /* @__PURE__ */ c.jsx(St, {}) }) ] }); } -function tv(e, t) { +function ev(e, t) { return e.in == "body" ? `${e.path.type === "jsonPath" ? "JsonPath" : "JsonPointer"} "${e.path.value}" is ${t} in the ${e.from} ${e.in}` : `Name "${e.name}" is ${t} in the ${e.from} ${e.in}`; } -const nv = E.div` +const tv = E.div` margin: 8px; display: grid; grid-template-columns: 10em 1fr 2em; row-gap: 4px; -`, rv = E.div` +`, nv = E.div` display: contents; & > div { padding: 4px 8px; @@ -3235,14 +3235,14 @@ const nv = E.div` font-size: 90%; font-weight: 600; } -`, ov = E.div` +`, rv = E.div` display: contents; > div { padding-left: 8px; padding-right: 8px; line-break: anywhere; } -`, iv = E.div` +`, ov = E.div` display: flex; align-items: center; justify-content: center; @@ -3252,16 +3252,16 @@ const nv = E.div` padding-right: 4px; } `; -function sv({ +function iv({ response: e, variables: t, requestRef: n }) { - const r = lv(t); - return /* @__PURE__ */ c.jsx(av, { children: /* @__PURE__ */ c.jsxs(wn, { children: [ + const r = av(t); + return /* @__PURE__ */ c.jsx(sv, { children: /* @__PURE__ */ c.jsxs(wn, { children: [ /* @__PURE__ */ c.jsxs(Sn, { style: { gap: "8px" }, children: [ /* @__PURE__ */ c.jsx( - Yc, + Xc, { style: { width: 14, @@ -3273,10 +3273,10 @@ function sv({ } } ), - /* @__PURE__ */ c.jsxs(to, { children: [ + /* @__PURE__ */ c.jsxs(eo, { children: [ `${e?.statusCode} ${e?.statusMessage}`, r && /* @__PURE__ */ c.jsx( - wt, + St, { style: { fill: `var(${w.errorForeground})` } } @@ -3291,7 +3291,7 @@ function sv({ id: "body", title: "Body", content: /* @__PURE__ */ c.jsx( - By, + qy, { response: e, requestRef: n, @@ -3302,45 +3302,45 @@ function sv({ { id: "headers", title: "Headers", - content: /* @__PURE__ */ c.jsx(Ky, { headers: e?.headers }) + content: /* @__PURE__ */ c.jsx(Wy, { headers: e?.headers }) }, { id: "variables-assigned", title: "Variables", - content: /* @__PURE__ */ c.jsx(Qy, { assignment: t || [] }), - counter: Ma(t), + content: /* @__PURE__ */ c.jsx(Yy, { assignment: t || [] }), + counter: Ra(t), counterKind: r ? "error" : "normal", - disabled: t === void 0 || Ma(t) === 0 + disabled: t === void 0 || Ra(t) === 0 } ] } ) ] }) }); } -const av = E.div` +const sv = E.div` > div { background-color: var(${w.background}); } `; -function Ma(e) { +function Ra(e) { return e !== void 0 ? e.map((t) => t.assignments.length).reduce((t, n) => t = t + n, 0) : 0; } -function lv(e) { +function av(e) { return !!e?.map((t) => t.assignments.some((n) => n.error !== void 0)).some((t) => t); } -function cv({ operation: e }) { - return /* @__PURE__ */ c.jsxs(uv, { children: [ +function lv({ operation: e }) { + return /* @__PURE__ */ c.jsxs(cv, { children: [ e.ref && /* @__PURE__ */ c.jsx( - Em, + jm, { - icon: dv(e.status), + icon: uv(e.status), title: `${e.ref.type}/${e.ref.id}` } ), - Object.keys(e.auth).length > 0 && /* @__PURE__ */ c.jsx(Iy, { results: e.auth }), + Object.keys(e.auth).length > 0 && /* @__PURE__ */ c.jsx(zy, { results: e.auth }), e.httpRequestPrepareError !== void 0 && /* @__PURE__ */ c.jsx(Un, { message: "Failed to prepare HTTP request for sending", children: e.httpRequestPrepareError }), e.httpRequest !== void 0 && /* @__PURE__ */ c.jsx( - Ey, + jy, { operationId: e.operationId, request: e.httpRequest, @@ -3354,7 +3354,7 @@ function cv({ operation: e }) { e.httpError.message ] }), e.httpResponse !== void 0 && e.httpResponse !== null && /* @__PURE__ */ c.jsx( - sv, + iv, { response: e.httpResponse, variables: e.variablesAssigned, @@ -3364,26 +3364,26 @@ function cv({ operation: e }) { e.responseProcessingError !== void 0 && /* @__PURE__ */ c.jsx(Un, { message: e.responseProcessingError }) ] }); } -const uv = E.div` +const cv = E.div` display: flex; flex-flow: column; gap: 8px; `; -function dv(e) { - return e === "success" ? /* @__PURE__ */ c.jsx(yh, {}) : e === "failure" ? /* @__PURE__ */ c.jsx(ch, { style: { fill: `var(${w.errorForeground})` } }) : /* @__PURE__ */ c.jsx(hv, {}); +function uv(e) { + return e === "success" ? /* @__PURE__ */ c.jsx(mh, {}) : e === "failure" ? /* @__PURE__ */ c.jsx(rh, { style: { fill: `var(${w.errorForeground})` } }) : /* @__PURE__ */ c.jsx(fv, {}); } -const fv = zc` +const dv = Dc` from { transform: rotate(0deg); } to { transform: rotate(359deg); } -`, hv = E(Wc)` - animation: ${fv} 2s infinite linear; +`, fv = E(Vc)` + animation: ${dv} 2s infinite linear; transition: width 0.2s linear; `; -function Nu({ +function Au({ playbook: e, collapsible: t }) { @@ -3393,33 +3393,33 @@ function Nu({ e.status === "failure" || e.status === "pending" || e.name === "Scenario" || e.name === "Request" ); }, [e.status]); - const o = e.results.map((i, s) => /* @__PURE__ */ c.jsx(cv, { operation: i }, s)); + const o = e.results.map((i, s) => /* @__PURE__ */ c.jsx(lv, { operation: i }, s)); return t ? /* @__PURE__ */ c.jsx( Yn, { isOpen: n, setOpen: r, - title: /* @__PURE__ */ c.jsx(pv, { children: e.name || "" }), - children: /* @__PURE__ */ c.jsx(La, { children: o }) + title: /* @__PURE__ */ c.jsx(hv, { children: e.name || "" }), + children: /* @__PURE__ */ c.jsx(Ma, { children: o }) } - ) : /* @__PURE__ */ c.jsx(La, { children: o }); + ) : /* @__PURE__ */ c.jsx(Ma, { children: o }); } -const La = E.div` +const Ma = E.div` display: flex; flex-flow: column; gap: 8px; -`, pv = E.div` +`, hv = E.div` opacity: 0.8; `; -function Ru({ +function Nu({ result: e, collapsible: t }) { - return /* @__PURE__ */ c.jsx(gv, { children: e.map((n, r) => /* @__PURE__ */ c.jsx(Nu, { playbook: n, collapsible: t }, r)) }); + return /* @__PURE__ */ c.jsx(pv, { children: e.map((n, r) => /* @__PURE__ */ c.jsx(Au, { playbook: n, collapsible: t }, r)) }); } -const gv = E.div``; -function zj(e) { - const t = St.simpleClone(e), n = Object.keys(e.methods).map((r) => ({ key: r, value: e.methods[r] })); +const pv = E.div``; +function Dj(e) { + const t = Re.simpleClone(e), n = Object.keys(e.methods).map((r) => ({ key: r, value: e.methods[r] })); return { ...t, in: _r(t.in), @@ -3429,7 +3429,7 @@ function zj(e) { methods: n }; } -function Ij(e) { +function zj(e) { const t = {}; for (const { key: n, value: r } of e.methods) t[n] = r; @@ -3448,7 +3448,7 @@ function _r(e) { function Cr(e) { return e === "" ? void 0 : e; } -function mv(e) { +function gv(e) { return e ? e.label : ""; } function Kr({ @@ -3461,11 +3461,11 @@ function Kr({ const { field: i } = ie({ name: e, rules: { required: !0 } - }), s = vv(t, i.value), a = (l) => { + }), s = yv(t, i.value), a = (l) => { i.onChange(l?.value); }; return /* @__PURE__ */ c.jsx( - yv, + mv, { options: t, placeholder: n, @@ -3476,7 +3476,7 @@ function Kr({ } ); } -function yv({ +function mv({ options: e, placeholder: t, label: n, @@ -3484,36 +3484,36 @@ function yv({ onSelectedItemChange: o, description: i }) { - const s = e.filter((h) => h.value === r)?.[0], { isOpen: a, getToggleButtonProps: l, getMenuProps: u, getItemProps: d } = es({ + const s = e.filter((h) => h.value === r)?.[0], { isOpen: a, getToggleButtonProps: l, getMenuProps: u, getItemProps: d } = Zi({ items: e, - itemToString: mv, + itemToString: gv, selectedItem: s || null, onSelectedItemChange: ({ selectedItem: h }) => { o(h); } }); - return /* @__PURE__ */ c.jsxs(bv, { children: [ - /* @__PURE__ */ c.jsxs(xv, { children: [ - /* @__PURE__ */ c.jsxs(kv, { children: [ + return /* @__PURE__ */ c.jsxs(vv, { children: [ + /* @__PURE__ */ c.jsxs(bv, { children: [ + /* @__PURE__ */ c.jsxs(xv, { children: [ /* @__PURE__ */ c.jsx("div", { children: n !== void 0 && /* @__PURE__ */ c.jsx("span", { children: n }) }), i && /* @__PURE__ */ c.jsx(bn, { children: i }) ] }), - /* @__PURE__ */ c.jsxs(wv, { ...l(), children: [ + /* @__PURE__ */ c.jsxs(kv, { ...l(), children: [ /* @__PURE__ */ c.jsx("span", { children: s ? s.label : t ?? "" }), - /* @__PURE__ */ c.jsx(bo, {}) + /* @__PURE__ */ c.jsx(vo, {}) ] }) ] }), - /* @__PURE__ */ c.jsx(Sv, { ...u(), $isOpen: a, children: a && e.map((h, f) => /* @__PURE__ */ c.jsx("li", { ...d({ item: h, index: f }), children: /* @__PURE__ */ c.jsx("span", { children: h.label }) }, `${h.value}${f}`)) }) + /* @__PURE__ */ c.jsx(wv, { ...u(), $isOpen: a, children: a && e.map((h, f) => /* @__PURE__ */ c.jsx("li", { ...d({ item: h, index: f }), children: /* @__PURE__ */ c.jsx("span", { children: h.label }) }, `${h.value}${f}`)) }) ] }); } -function vv(e, t) { +function yv(e, t) { return e.filter((n) => n.value === t)?.[0]; } -const bv = E.div` +const vv = E.div` display: flex; flex-direction: column; position: relative; -`, xv = E.div` +`, bv = E.div` height: 40px; background-color: var(${w.inputBackground}); border-radius: 2px; @@ -3532,7 +3532,7 @@ const bv = E.div` line-height: 16px; color: var(${w.inputPlaceholderForeground}); } -`, kv = E.div` +`, xv = E.div` display: flex; justify-content: space-between; font-style: normal; @@ -3540,7 +3540,7 @@ const bv = E.div` font-size: 12px; line-height: 16px; color: var(${w.inputPlaceholderForeground}); -`, wv = E.div` +`, kv = E.div` display: flex; color: var(${w.foreground}); align-items: center; @@ -3555,7 +3555,7 @@ const bv = E.div` > svg { fill: var(${w.foreground}); } -`, Sv = E.ul` +`, wv = E.ul` max-height: 350px; overflow-y: auto; z-index: 1; @@ -3579,14 +3579,14 @@ const bv = E.div` & > li:hover { background-color: var(${w.listHoverBackground}); } -`, _v = [ +`, Sv = [ "hours", "minutes", "seconds", "milliseconds", "microseconds", "nanoseconds" -], Xt = (e, t) => `((?<${e}>\\d*[\\.]?\\d+)${t})?`, Cv = new RegExp( +], Xt = (e, t) => `((?<${e}>\\d*[\\.]?\\d+)${t})?`, _v = new RegExp( [ "^", "(?[-+])?", @@ -3598,7 +3598,7 @@ const bv = E.div` Xt("nanoseconds", "ns"), "$" ].join("") -), jv = { +), Cv = { hours: function(e) { return e === void 0 ? void 0 : e * 36e5; }, @@ -3618,27 +3618,27 @@ const bv = E.div` return e === void 0 ? void 0 : 0; } }; -function Ev(e) { - const t = Cv.exec(e); +function jv(e) { + const t = _v.exec(e); if (!t || !t.groups) return; let n; - for (const r of _v) + for (const r of Sv) if (t.groups[r]) { - const o = jv[r](Tv(t.groups[r])); + const o = Cv[r](Ev(t.groups[r])); n === void 0 ? n = o === void 0 ? void 0 : o : n = o === void 0 ? n : n + o; } return n; } -function Tv(e) { +function Ev(e) { if (e !== void 0) return parseFloat(e); } -function Ov({ name: e }) { +function Tv({ name: e }) { const { field: t } = ie({ name: e }); - return /* @__PURE__ */ c.jsx(Gh, { value: t.value, onChange: (n) => t.onChange(n) }); + return /* @__PURE__ */ c.jsx(Kh, { value: t.value, onChange: (n) => t.onChange(n) }); } function Cn({ options: e, @@ -3654,7 +3654,7 @@ function Cn({ function a(f) { return f?.disabled === !0; } - const { isOpen: l, getToggleButtonProps: u, getMenuProps: d, getItemProps: h } = es({ + const { isOpen: l, getToggleButtonProps: u, getMenuProps: d, getItemProps: h } = Zi({ items: e, isItemDisabled: a, itemToString: s, @@ -3663,21 +3663,21 @@ function Cn({ r(f); } }); - return /* @__PURE__ */ c.jsxs(Pv, { onClick: (f) => f.stopPropagation(), children: [ - /* @__PURE__ */ c.jsx($v, { children: /* @__PURE__ */ c.jsxs(Dv, { ...u(), children: [ - i === void 0 && t !== void 0 && /* @__PURE__ */ c.jsx(zv, { children: t }), - i !== void 0 && /* @__PURE__ */ c.jsx(Iv, { children: i.label }), - /* @__PURE__ */ c.jsx(bo, {}) + return /* @__PURE__ */ c.jsxs(Ov, { onClick: (f) => f.stopPropagation(), children: [ + /* @__PURE__ */ c.jsx(Pv, { children: /* @__PURE__ */ c.jsxs($v, { ...u(), children: [ + i === void 0 && t !== void 0 && /* @__PURE__ */ c.jsx(Dv, { children: t }), + i !== void 0 && /* @__PURE__ */ c.jsx(zv, { children: i.label }), + /* @__PURE__ */ c.jsx(vo, {}) ] }) }), - /* @__PURE__ */ c.jsxs(Av, { ...d(), $isOpen: l, children: [ + /* @__PURE__ */ c.jsxs(Iv, { ...d(), $isOpen: l, children: [ l && e.map((f, p) => /* @__PURE__ */ c.jsx("li", { ...h({ item: f, index: p }), children: /* @__PURE__ */ c.jsx("span", { children: f.label }) }, `${f.value}${p}`)), l && o ] }) ] }); } -const Pv = E.div` +const Ov = E.div` position: relative; -`, $v = E.div` +`, Pv = E.div` display: flex; flex-direction: column; gap: 4px; @@ -3685,7 +3685,7 @@ const Pv = E.div` border: 1px solid var(${w.focusBorder}); } border: 1px solid transparent; -`, Dv = E.div` +`, $v = E.div` display: flex; color: var(${w.foreground}); align-items: center; @@ -3701,9 +3701,9 @@ const Pv = E.div` margin-left: 3px; fill: var(${w.foreground}); } -`, zv = E.span` +`, Dv = E.span` color: var(${w.inputPlaceholderForeground}); -`, Iv = E.span``, Av = E.ul` +`, zv = E.span``, Iv = E.ul` max-height: 250px; overflow-y: auto; z-index: 1; @@ -3736,7 +3736,7 @@ const Pv = E.div` background-color: transparent; } `; -function Nv({ +function Av({ name: e, options: t, label: n, @@ -3746,7 +3746,7 @@ function Nv({ const { field: i } = ie({ name: e }); - return /* @__PURE__ */ c.jsxs(Rv, { children: [ + return /* @__PURE__ */ c.jsxs(Nv, { children: [ n !== void 0 && /* @__PURE__ */ c.jsx("div", { className: "label", children: n }), /* @__PURE__ */ c.jsx( Cn, @@ -3761,7 +3761,7 @@ function Nv({ ) ] }); } -const Rv = E.div` +const Nv = E.div` background-color: var(${w.inputBackground}); border-radius: 2px; border: 1px solid var(${w.border}); @@ -3780,7 +3780,7 @@ const Rv = E.div` color: var(${w.inputPlaceholderForeground}); } `; -function Mv({ +function Rv({ add: e, responseCodes: t, existingCodes: n @@ -3790,48 +3790,48 @@ function Mv({ key: i.code, value: { expectations: { - httpStatus: Bv(i.code) + httpStatus: qv(i.code) }, variableAssignments: [] } }); }; return /* @__PURE__ */ c.jsx( - zu, + Du, { title: "Add response processing", defaultValues: r, onSubmit: o, noOverflow: !0, - trigger: /* @__PURE__ */ c.jsx(Hv, { children: /* @__PURE__ */ c.jsx(np, {}) }), - children: /* @__PURE__ */ c.jsx(Lv, { responseCodes: t, existingCodes: n }) + trigger: /* @__PURE__ */ c.jsx(Uv, { children: /* @__PURE__ */ c.jsx(tp, {}) }), + children: /* @__PURE__ */ c.jsx(Mv, { responseCodes: t, existingCodes: n }) } ); } -function Lv({ +function Mv({ responseCodes: e, existingCodes: t }) { - return /* @__PURE__ */ c.jsx(Uv, { children: /* @__PURE__ */ c.jsx( - Nv, + return /* @__PURE__ */ c.jsx(Bv, { children: /* @__PURE__ */ c.jsx( + Av, { label: "HTTP response code", placeholder: "", name: "code", - options: Fv(e, t) + options: Lv(e, t) } ) }); } -function Fv(e, t) { - return e.filter((n) => !t.includes(n)).map((n) => ({ label: qv(n), value: n })); +function Lv(e, t) { + return e.filter((n) => !t.includes(n)).map((n) => ({ label: Fv(n), value: n })); } -function qv(e) { - return e in Fa ? Fa[e] : e; +function Fv(e) { + return e in La ? La[e] : e; } -function Bv(e) { +function qv(e) { return /^\d+$/.test(e) ? parseInt(e, 10) : e; } -const Fa = { +const La = { default: "default", "1XX": "1XX", 100: "100 - Continue", @@ -3879,11 +3879,11 @@ const Fa = { 503: "503 - Service Unavailable", 504: "504 - Gateway Timeout", 505: "505 - HTTP Version Not Supported" -}, Uv = E.div` +}, Bv = E.div` > div > div { padding: 4px; } -`, Hv = E.button` +`, Uv = E.button` border: none; background-color: transparent; cursor: pointer; @@ -3894,7 +3894,7 @@ const Fa = { } } `; -function Vv(e) { +function Hv(e) { return e ? e.label : ""; } function zt({ @@ -3905,11 +3905,11 @@ function zt({ const { field: r } = ie({ name: e, rules: { required: !0 } - }), o = Kv(t, r.value), i = (s) => { + }), o = Wv(t, r.value), i = (s) => { r.onChange(s?.value); }; return /* @__PURE__ */ c.jsx( - Wv, + Vv, { options: t, placeholder: n, @@ -3918,35 +3918,35 @@ function zt({ } ); } -function Wv({ +function Vv({ options: e, placeholder: t, label: n, selected: r, onSelectedItemChange: o }) { - const i = e.filter((d) => d.value === r)?.[0], { isOpen: s, getToggleButtonProps: a, getMenuProps: l, getItemProps: u } = es({ + const i = e.filter((d) => d.value === r)?.[0], { isOpen: s, getToggleButtonProps: a, getMenuProps: l, getItemProps: u } = Zi({ items: e, - itemToString: Vv, + itemToString: Hv, selectedItem: i || null, onSelectedItemChange: ({ selectedItem: d }) => { o(d); } }); - return /* @__PURE__ */ c.jsxs(Gv, { children: [ - /* @__PURE__ */ c.jsx(Xv, { children: /* @__PURE__ */ c.jsxs(Yv, { ...a(), children: [ + return /* @__PURE__ */ c.jsxs(Kv, { children: [ + /* @__PURE__ */ c.jsx(Gv, { children: /* @__PURE__ */ c.jsxs(Xv, { ...a(), children: [ /* @__PURE__ */ c.jsx("span", { children: i ? i.label : t ?? "" }), - /* @__PURE__ */ c.jsx(bo, {}) + /* @__PURE__ */ c.jsx(vo, {}) ] }) }), - /* @__PURE__ */ c.jsx(Qv, { ...l(), $isOpen: s, children: s && e.map((d, h) => /* @__PURE__ */ c.jsx("li", { ...u({ item: d, index: h }), children: /* @__PURE__ */ c.jsx("span", { children: d.label }) }, `${d.value}${h}`)) }) + /* @__PURE__ */ c.jsx(Yv, { ...l(), $isOpen: s, children: s && e.map((d, h) => /* @__PURE__ */ c.jsx("li", { ...u({ item: d, index: h }), children: /* @__PURE__ */ c.jsx("span", { children: d.label }) }, `${d.value}${h}`)) }) ] }); } -function Kv(e, t) { +function Wv(e, t) { return e.filter((n) => n.value === t)?.[0]; } -const Gv = E.div` +const Kv = E.div` position: relative; -`, Xv = E.div` +`, Gv = E.div` display: flex; flex-direction: column; padding: 4px 8px; @@ -3955,7 +3955,7 @@ const Gv = E.div` border: 1px solid var(${w.focusBorder}); } border: 1px solid transparent; -`, Yv = E.div` +`, Xv = E.div` display: flex; color: var(${w.foreground}); align-items: center; @@ -3971,7 +3971,7 @@ const Gv = E.div` margin-left: 3px; fill: var(${w.foreground}); } -`, Qv = E.ul` +`, Yv = E.ul` max-height: 350px; overflow-y: auto; z-index: 1; @@ -4010,7 +4010,7 @@ function It({ name: t }); return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsx(Jv, { style: o, children: /* @__PURE__ */ c.jsx( + /* @__PURE__ */ c.jsx(Qv, { style: o, children: /* @__PURE__ */ c.jsx( "input", { ...i, @@ -4019,10 +4019,10 @@ function It({ style: { width: "100%" } } ) }), - s && /* @__PURE__ */ c.jsx(Zv, { children: s?.message }) + s && /* @__PURE__ */ c.jsx(Jv, { children: s?.message }) ] }); } -const Jv = E.div` +const Qv = E.div` display: flex; flex-direction: column; padding: 4px 8px; @@ -4041,18 +4041,18 @@ const Jv = E.div` outline: none; } } -`, Zv = E.div` +`, Jv = E.div` color: var(${w.errorForeground}); `; -function eb({ +function Zv({ name: e, index: t }) { const { fields: n, append: r, remove: o } = vn({ name: `responses.${t}.value.variableAssignments` }); - return /* @__PURE__ */ c.jsx(tb, { children: /* @__PURE__ */ c.jsxs(nb, { children: [ - /* @__PURE__ */ c.jsxs(ob, { children: [ + return /* @__PURE__ */ c.jsx(eb, { children: /* @__PURE__ */ c.jsxs(tb, { children: [ + /* @__PURE__ */ c.jsxs(rb, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Variable name" }), /* @__PURE__ */ c.jsx("div", { children: "From" }), /* @__PURE__ */ c.jsx("div", { children: "Location" }), @@ -4060,9 +4060,9 @@ function eb({ /* @__PURE__ */ c.jsx("div", { children: "Name or Path" }), /* @__PURE__ */ c.jsx("div", {}) ] }), - /* @__PURE__ */ c.jsxs(rb, { children: [ + /* @__PURE__ */ c.jsxs(nb, { children: [ n.map((i, s) => /* @__PURE__ */ c.jsx( - ib, + ob, { name: `responses.${t}.value.variableAssignments.${s}`, remove: () => { @@ -4071,23 +4071,23 @@ function eb({ }, i.id )), - /* @__PURE__ */ c.jsx(db, { append: r }) + /* @__PURE__ */ c.jsx(ub, { append: r }) ] }) ] }) }); } -const tb = E.div` +const eb = E.div` margin: 8px 4px; -`, nb = E.div` +`, tb = E.div` margin: 4px; display: grid; row-gap: 4px; grid-template-columns: repeat(5, 1fr) 1em; -`, rb = E.div` +`, nb = E.div` display: contents; & > div > div { border-bottom: 1px solid var(${w.border}); } -`, ob = E.div` +`, rb = E.div` display: contents; & > div { padding: 4px 8px; @@ -4097,15 +4097,15 @@ const tb = E.div` font-weight: 600; } `; -function ib({ name: e, remove: t }) { - const { getValues: n } = ar(), r = n(`${e}.value.in`), o = n(`${e}.value.from`); - return /* @__PURE__ */ c.jsxs(ab, { children: [ +function ob({ name: e, remove: t }) { + const { getValues: n } = sr(), r = n(`${e}.value.in`), o = n(`${e}.value.from`); + return /* @__PURE__ */ c.jsxs(sb, { children: [ /* @__PURE__ */ c.jsx(It, { name: `${e}.key`, label: "name" }), - r === "body" && /* @__PURE__ */ c.jsx(lb, { name: e }, `${e}-value`), - r !== "body" && o === "request" && /* @__PURE__ */ c.jsx(cb, { name: e }, `${e}-value`), - r !== "body" && o === "response" && /* @__PURE__ */ c.jsx(ub, { name: e }, `${e}-value`), + r === "body" && /* @__PURE__ */ c.jsx(ab, { name: e }, `${e}-value`), + r !== "body" && o === "request" && /* @__PURE__ */ c.jsx(lb, { name: e }, `${e}-value`), + r !== "body" && o === "response" && /* @__PURE__ */ c.jsx(cb, { name: e }, `${e}-value`), /* @__PURE__ */ c.jsx( - sb, + ib, { onClick: (i) => { i.preventDefault(), i.stopPropagation(), t(); @@ -4115,7 +4115,7 @@ function ib({ name: e, remove: t }) { ) ] }); } -const sb = E.button` +const ib = E.button` background: none; border: none; padding: 0; @@ -4128,13 +4128,13 @@ const sb = E.button` > svg { fill: var(${w.foreground}); } -`, ab = E.div` +`, sb = E.div` display: contents; &:hover > :last-child { opacity: 1; } `; -function lb({ name: e }) { +function ab({ name: e }) { return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx( zt, @@ -4160,7 +4160,7 @@ function lb({ name: e }) { /* @__PURE__ */ c.jsx(It, { name: `${e}.value.path.value`, label: "path" }) ] }); } -function cb({ name: e }) { +function lb({ name: e }) { return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx( zt, @@ -4188,7 +4188,7 @@ function cb({ name: e }) { /* @__PURE__ */ c.jsx(It, { name: `${e}.value.name`, label: "name" }) ] }); } -function ub({ name: e }) { +function cb({ name: e }) { return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx( zt, @@ -4214,7 +4214,7 @@ function ub({ name: e }) { /* @__PURE__ */ c.jsx(It, { name: `${e}.value.name`, label: "name" }) ] }); } -function db({ append: e }) { +function ub({ append: e }) { return /* @__PURE__ */ c.jsx("div", { style: { gridColumn: "span 2" }, children: /* @__PURE__ */ c.jsx("div", { style: { padding: "4px 8px" }, children: /* @__PURE__ */ c.jsx( Cn, { @@ -4250,7 +4250,7 @@ function db({ append: e }) { } ) }) }); } -function us({ +function cs({ responseCodes: e, editable: t }) { @@ -4263,13 +4263,13 @@ function us({ const a = n.map((u) => u.key), l = n.map((u, d) => ({ id: u.id, title: u.key, - menu: t ? /* @__PURE__ */ c.jsx(Vc, { children: /* @__PURE__ */ c.jsxs(vh, { onClick: (h) => h.stopPropagation(), onSelect: () => o(d), children: [ + menu: t ? /* @__PURE__ */ c.jsx(Hc, { children: /* @__PURE__ */ c.jsxs(yh, { onClick: (h) => h.stopPropagation(), onSelect: () => o(d), children: [ /* @__PURE__ */ c.jsx(_n, {}), "Delete" ] }) }) : void 0, - content: /* @__PURE__ */ c.jsx(eb, { name: u.key, index: d }) + content: /* @__PURE__ */ c.jsx(Zv, { name: u.key, index: d }) })); - return /* @__PURE__ */ c.jsx(fb, { children: /* @__PURE__ */ c.jsx( + return /* @__PURE__ */ c.jsx(db, { children: /* @__PURE__ */ c.jsx( kn, { round: !0, @@ -4277,7 +4277,7 @@ function us({ setActiveTab: s, tabs: l, menu: t ? /* @__PURE__ */ c.jsx( - Mv, + Rv, { add: r, responseCodes: e, @@ -4287,13 +4287,13 @@ function us({ } ) }); } -const fb = E.div` +const db = E.div` margin-top: 4px; `; -function hb({ append: e }) { - return /* @__PURE__ */ c.jsxs(pb, { children: [ +function fb({ append: e }) { + return /* @__PURE__ */ c.jsxs(hb, { children: [ /* @__PURE__ */ c.jsx( - gb, + pb, { placeholder: "Add new entry", value: "", @@ -4302,12 +4302,12 @@ function hb({ append: e }) { } } ), - /* @__PURE__ */ c.jsx(mb, {}) + /* @__PURE__ */ c.jsx(gb, {}) ] }); } -const pb = E.div` +const hb = E.div` display: contents; -`, gb = E.input` +`, pb = E.input` background: transparent; border: none; border-bottom: 1px solid var(${w.border}); @@ -4317,16 +4317,16 @@ const pb = E.div` &::placeholder { color: var(${w.inputPlaceholderForeground}); } -`, mb = E.div` +`, gb = E.div` grid-column: span 3; -`, Mu = A.createContext(null); -function yb(e, t) { +`, Ru = A.createContext(null); +function mb(e, t) { return { getTheme: function() { return t ?? null; } }; } function Ee() { - const e = A.useContext(Mu); + const e = A.useContext(Ru); return e == null && (function(t, ...n) { const r = new URL("https://lexical.dev/docs/error"), o = new URLSearchParams(); o.append("code", t); @@ -4340,57 +4340,57 @@ function M(e, ...t) { for (const o of t) r.append("v", o); throw n.search = r.toString(), Error(`Minified Lexical error #${e}; visit ${n.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`); } -const He = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, vb = He && "documentMode" in document ? document.documentMode : null, Fe = He && /Mac|iPod|iPhone|iPad/.test(navigator.platform), pt = He && /^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent), ro = !(!He || !("InputEvent" in window) || vb) && "getTargetRanges" in new window.InputEvent("input"), Qn = He && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), un = He && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, bb = He && /Android/.test(navigator.userAgent), Lu = He && /^(?=.*Chrome).*/i.test(navigator.userAgent), qa = He && bb && Lu, oo = He && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !Lu; -function io(...e) { +const Ve = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, yb = Ve && "documentMode" in document ? document.documentMode : null, qe = Ve && /Mac|iPod|iPhone|iPad/.test(navigator.platform), gt = Ve && /^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent), no = !(!Ve || !("InputEvent" in window) || yb) && "getTargetRanges" in new window.InputEvent("input"), Qn = Ve && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), un = Ve && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, vb = Ve && /Android/.test(navigator.userAgent), Mu = Ve && /^(?=.*Chrome).*/i.test(navigator.userAgent), Fa = Ve && vb && Mu, ro = Ve && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !Mu; +function oo(...e) { const t = []; for (const n of e) if (n && typeof n == "string") for (const [r] of n.matchAll(/\S+/g)) t.push(r); return t; } -const xb = 1, kb = 3, wb = 9, Sb = 11, Mt = 0, Fu = 1, dn = 2, _b = 0, Cb = 1, jb = 2, so = 4, ao = 8, ds = 128, Eb = 1792 | (112 | (3 | so | ao) | ds), fs = 1, hs = 2, ps = 3, gs = 4, ms = 5, ys = 6, Oo = Qn || un || oo ? " " : "​", st = ` +const bb = 1, xb = 3, kb = 9, wb = 11, Mt = 0, Lu = 1, dn = 2, Sb = 0, _b = 1, Cb = 2, io = 4, so = 8, us = 128, jb = 1792 | (112 | (3 | io | so) | us), ds = 1, fs = 2, hs = 3, ps = 4, gs = 5, ms = 6, To = Qn || un || ro ? " " : "​", at = ` -`, Tb = pt ? " " : Oo, qu = "֑-߿יִ-﷽ﹰ-ﻼ", Bu = "A-Za-zÀ-ÖØ-öø-ʸ̀-֐ࠀ-῿‎Ⰰ-﬜︀-﹯﻽-￿", Ob = new RegExp("^[^" + Bu + "]*[" + qu + "]"), Pb = new RegExp("^[^" + qu + "]*[" + Bu + "]"), Lt = { bold: 1, capitalize: 1024, code: 16, highlight: ds, italic: 2, lowercase: 256, strikethrough: so, subscript: 32, superscript: 64, underline: ao, uppercase: 512 }, $b = { directionless: 1, unmergeable: 2 }, Ba = { center: hs, end: ys, justify: gs, left: fs, right: ps, start: ms }, Db = { [hs]: "center", [ys]: "end", [gs]: "justify", [fs]: "left", [ps]: "right", [ms]: "start" }, zb = { normal: 0, segmented: 2, token: 1 }, Ib = { [_b]: "normal", [jb]: "segmented", [Cb]: "token" }, Ab = "$"; -function Uu(e, t, n, r, o, i) { +`, Eb = gt ? " " : To, Fu = "֑-߿יִ-﷽ﹰ-ﻼ", qu = "A-Za-zÀ-ÖØ-öø-ʸ̀-֐ࠀ-῿‎Ⰰ-﬜︀-﹯﻽-￿", Tb = new RegExp("^[^" + qu + "]*[" + Fu + "]"), Ob = new RegExp("^[^" + Fu + "]*[" + qu + "]"), Lt = { bold: 1, capitalize: 1024, code: 16, highlight: us, italic: 2, lowercase: 256, strikethrough: io, subscript: 32, superscript: 64, underline: so, uppercase: 512 }, Pb = { directionless: 1, unmergeable: 2 }, qa = { center: fs, end: ms, justify: ps, left: ds, right: hs, start: gs }, $b = { [fs]: "center", [ms]: "end", [ps]: "justify", [ds]: "left", [hs]: "right", [gs]: "start" }, Db = { normal: 0, segmented: 2, token: 1 }, zb = { [Sb]: "normal", [Cb]: "segmented", [_b]: "token" }, Ib = "$"; +function Bu(e, t, n, r, o, i) { let s = e.getFirstChild(); for (; s !== null; ) { const a = s.__key; - s.__parent === t && (R(s) && Uu(s, a, n, r, o, i), n.has(a) || i.delete(a), o.push(a)), s = s.getNextSibling(); + s.__parent === t && (R(s) && Bu(s, a, n, r, o, i), n.has(a) || i.delete(a), o.push(a)), s = s.getNextSibling(); } } -const Nb = 100; -let ki = !1, vs = 0; -function Rb(e) { - vs = e.timeStamp; +const Ab = 100; +let xi = !1, ys = 0; +function Nb(e) { + ys = e.timeStamp; } -function ei(e, t, n) { +function Zo(e, t, n) { const r = e.nodeName === "BR", o = t.__lexicalLineBreak; - return o && (e === o || r && e.previousSibling === o) || r && Mo(e, n) !== void 0; + return o && (e === o || r && e.previousSibling === o) || r && Ro(e, n) !== void 0; } -function Mb(e, t, n) { - const r = Je(Re(n)); +function Rb(e, t, n) { + const r = Ze(Me(n)); let o = null, i = null; r !== null && r.anchorNode === e && (o = r.anchorOffset, i = r.focusOffset); const s = e.nodeValue; - s !== null && Ns(t, s, o, i, !1); + s !== null && As(t, s, o, i, !1); } -function Lb(e, t, n) { +function Mb(e, t, n) { if (L(e)) { const r = e.anchor.getNode(); if (r.is(n) && e.format !== r.getFormat()) return !1; } - return ct(t) && n.isAttached(); + return ut(t) && n.isAttached(); } -function Fb(e, t, n, r) { - for (let o = e; o && !Nx(o); o = pr(o)) { - const i = Mo(o, t); +function Lb(e, t, n, r) { + for (let o = e; o && !Ax(o); o = pr(o)) { + const i = Ro(o, t); if (i !== void 0) { const s = fe(i, n); if (s) return ne(s) || !Te(o) ? void 0 : [o, s]; - } else if (o === r) return [r, Nd(n)]; + } else if (o === r) return [r, Ad(n)]; } } -function Hu(e, t, n) { - ki = !0; - const r = performance.now() - vs > Nb; +function Uu(e, t, n) { + xi = !0; + const r = performance.now() - ys > Ab; try { $e(e, (() => { const o = H() || (function(f) { @@ -4401,17 +4401,17 @@ function Hu(e, t, n) { })(e), i = /* @__PURE__ */ new Map(), s = e.getRootElement(), a = e._editorState, l = e._blockCursorElement; let u = !1, d = ""; for (let f = 0; f < t.length; f++) { - const p = t[f], g = p.type, m = p.target, y = Fb(m, e, a, s); + const p = t[f], g = p.type, m = p.target, y = Lb(m, e, a, s); if (!y) continue; const [x, k] = y; - if (g === "characterData") r && F(k) && ct(m) && Lb(o, m, k) && Mb(m, k, e); + if (g === "characterData") r && F(k) && ut(m) && Mb(o, m, k) && Rb(m, k, e); else if (g === "childList") { u = !0; const v = p.addedNodes; for (let _ = 0; _ < v.length; _++) { - const S = v[_], P = Id(S), D = S.parentNode; - if (D != null && S !== l && P === null && !ei(S, D, e)) { - if (pt) { + const S = v[_], P = zd(S), D = S.parentNode; + if (D != null && S !== l && P === null && !Zo(S, D, e)) { + if (gt) { const $ = (Te(S) ? S.innerText : null) || S.nodeValue; $ && (d += $); } @@ -4423,7 +4423,7 @@ function Hu(e, t, n) { let _ = 0; for (let S = 0; S < j; S++) { const P = b[S]; - (ei(P, m, e) || l === P) && (m.appendChild(P), _++); + (Zo(P, m, e) || l === P) && (m.appendChild(P), _++); } j !== _ && i.set(x, k); } @@ -4436,29 +4436,29 @@ function Hu(e, t, n) { const p = h[f], g = p.addedNodes, m = p.target; for (let y = 0; y < g.length; y++) { const x = g[y], k = x.parentNode; - k == null || x.nodeName !== "BR" || ei(x, m, e) || k.removeChild(x); + k == null || x.nodeName !== "BR" || Zo(x, m, e) || k.removeChild(x); } } n.takeRecords(); } - o !== null && (u && De(o), pt && Fd(e) && o.insertRawText(d)); + o !== null && (u && De(o), gt && Ld(e) && o.insertRawText(d)); })); } finally { - ki = !1; + xi = !1; } } -function Vu(e) { +function Hu(e) { const t = e._observer; - t !== null && Hu(e, t.takeRecords(), t); + t !== null && Uu(e, t.takeRecords(), t); } -function Wu(e) { +function Vu(e) { (function(t) { - vs === 0 && Re(t).addEventListener("textInput", Rb, !0); + ys === 0 && Me(t).addEventListener("textInput", Nb, !0); })(e), e._observer = new MutationObserver(((t, n) => { - Hu(e, t, n); + Uu(e, t, n); })); } -class bs { +class vs { constructor(t, n = /* @__PURE__ */ new Map(), r = void 0, o = /* @__PURE__ */ new Map(), i = void 0) { this.node = t, this.sharedConfigMap = n, this.unknownState = r, this.knownState = o; const s = i !== void 0 ? i : (function(a, l, u) { @@ -4488,14 +4488,14 @@ class bs { toJSON() { const t = { ...this.unknownState }; for (const [n, r] of this.knownState) n.isEqual(r, n.defaultValue) ? delete t[n.key] : t[n.key] = n.unparse(r); - return jr(t) ? { [Ab]: t } : {}; + return jr(t) ? { [Ib]: t } : {}; } getWritable(t) { if (this.node === t) return this; const n = new Map(this.knownState), r = jr(o = this.unknownState) && { ...o }; var o; if (r) for (const i of n.keys()) delete r[i.key]; - return new bs(t, this.sharedConfigMap, jr(r), n, this.size); + return new vs(t, this.sharedConfigMap, jr(r), n, this.size); } updateFromKnown(t, n) { const r = t.key; @@ -4517,11 +4517,11 @@ class bs { function jr(e) { if (e) for (const t in e) return e; } -function qb(e) { - const t = e.getWritable(), n = t.__state ? t.__state.getWritable(t) : new bs(t); +function Fb(e) { + const t = e.getWritable(), n = t.__state ? t.__state.getWritable(t) : new vs(t); return t.__state = n, n; } -function Ua(e, t) { +function Ba(e, t) { const n = e.__mode, r = e.__format, o = e.__style, i = t.__mode, s = t.__format, a = t.__style, l = e.__state, u = t.__state; return (n === null || n === i) && (r === null || r === s) && (o === null || o === a) && (e.__state === null || l === u || (function(d, h) { if (d === h) return !0; @@ -4544,17 +4544,17 @@ function Ua(e, t) { return !(d && p(d, h) || h && p(h, d) || d && g(d, h) || h && g(h, d)); })(l, u)); } -function Ha(e, t) { +function Ua(e, t) { const n = e.mergeWithSibling(t), r = le()._normalizedNodes; return r.add(e.__key), r.add(t.__key), n; } -function Va(e) { +function Ha(e) { let t, n, r = e; if (r.__text !== "" || !r.isSimpleText() || r.isUnmergeable()) { for (; (t = r.getPreviousSibling()) !== null && F(t) && t.isSimpleText() && !t.isUnmergeable(); ) { if (t.__text !== "") { - if (Ua(t, r)) { - r = Ha(t, r); + if (Ba(t, r)) { + r = Ua(t, r); break; } break; @@ -4563,8 +4563,8 @@ function Va(e) { } for (; (n = r.getNextSibling()) !== null && F(n) && n.isSimpleText() && !n.isUnmergeable(); ) { if (n.__text !== "") { - if (Ua(r, n)) { - r = Ha(r, n); + if (Ba(r, n)) { + r = Ua(r, n); break; } break; @@ -4573,10 +4573,10 @@ function Va(e) { } } else r.remove(); } -function wi(e) { - return Wa(e.anchor), Wa(e.focus), e; +function ki(e) { + return Va(e.anchor), Va(e.focus), e; } -function Wa(e) { +function Va(e) { for (; e.type === "element"; ) { const t = e.getNode(), n = e.offset; let r, o; @@ -4588,47 +4588,47 @@ function Wa(e) { e.set(r.__key, o ? r.getChildrenSize() : 0, "element", !0); } } -let mt, _e, Jn, Po, Si, _i, Ft, Ue, Ci, Zn, de = "", we = "", Ke = null, Ge = "", ot = "", Ku = !1, er = !1, Gr = null; -function lo(e, t) { +let yt, _e, Jn, Oo, wi, Si, Ft, He, _i, Zn, de = "", we = "", Ge = null, Xe = "", it = "", Wu = !1, er = !1, Gr = null; +function ao(e, t) { const n = Ft.get(e); if (t !== null) { - const r = Ti(e); + const r = Ei(e); r.parentNode === t && t.removeChild(r); } - if (Ue.has(e) || _e._keyToDOMMap.delete(e), R(n)) { - const r = uo(n, Ft); - ji(r, 0, r.length - 1, null); + if (He.has(e) || _e._keyToDOMMap.delete(e), R(n)) { + const r = co(n, Ft); + Ci(r, 0, r.length - 1, null); } - n !== void 0 && Rs(Zn, Jn, Po, n, "destroyed"); + n !== void 0 && Ns(Zn, Jn, Oo, n, "destroyed"); } -function ji(e, t, n, r) { +function Ci(e, t, n, r) { let o = t; for (; o <= n; ++o) { const i = e[o]; - i !== void 0 && lo(i, r); + i !== void 0 && ao(i, r); } } function Tt(e, t) { e.setProperty("text-align", t); } -const Bb = "40px"; -function Gu(e, t) { - const n = mt.theme.indent; +const qb = "40px"; +function Ku(e, t) { + const n = yt.theme.indent; if (typeof n == "string") { const o = e.classList.contains(n); t > 0 && !o ? e.classList.add(n) : t < 1 && o && e.classList.remove(n); } - const r = getComputedStyle(e).getPropertyValue("--lexical-indent-base-value") || Bb; + const r = getComputedStyle(e).getPropertyValue("--lexical-indent-base-value") || qb; e.style.setProperty("padding-inline-start", t === 0 ? "" : `calc(${t} * ${r})`); } -function Xu(e, t) { +function Gu(e, t) { const n = e.style; - t === 0 ? Tt(n, "") : t === fs ? Tt(n, "left") : t === hs ? Tt(n, "center") : t === ps ? Tt(n, "right") : t === gs ? Tt(n, "justify") : t === ms ? Tt(n, "start") : t === ys && Tt(n, "end"); + t === 0 ? Tt(n, "") : t === ds ? Tt(n, "left") : t === fs ? Tt(n, "center") : t === hs ? Tt(n, "right") : t === ps ? Tt(n, "justify") : t === gs ? Tt(n, "start") : t === ms && Tt(n, "end"); } -function co(e, t) { - const n = Ue.get(e); +function lo(e, t) { + const n = He.get(e); n === void 0 && M(60); - const r = n.createDOM(mt, _e); + const r = n.createDOM(yt, _e); if ((function(o, i, s) { const a = s._keyToDOMMap; (function(l, u, d) { @@ -4637,37 +4637,37 @@ function co(e, t) { })(i, s, o), a.set(o, i); })(e, r, _e), F(n) ? r.setAttribute("data-lexical-text", "true") : ne(n) && r.setAttribute("data-lexical-decorator", "true"), R(n)) { const o = n.__indent, i = n.__size; - if (o !== 0 && Gu(r, o), i !== 0) { + if (o !== 0 && Ku(r, o), i !== 0) { const a = i - 1; (function(l, u, d, h) { const f = we; - we = "", Ei(l, d, 0, u, d.getDOMSlot(h)), Qu(d, h), we = f; - })(uo(n, Ue), a, n, r); + we = "", ji(l, d, 0, u, d.getDOMSlot(h)), Yu(d, h), we = f; + })(co(n, He), a, n, r); } const s = n.__format; - s !== 0 && Xu(r, s), n.isInline() || Yu(null, n, r), Lo(n) && (de += st, ot += st); + s !== 0 && Gu(r, s), n.isInline() || Xu(null, n, r), Mo(n) && (de += at, it += at); } else { const o = n.getTextContent(); if (ne(n)) { - const i = n.decorate(_e, mt); - i !== null && Ju(e, i), r.contentEditable = "false"; + const i = n.decorate(_e, yt); + i !== null && Qu(e, i), r.contentEditable = "false"; } else F(n) && (n.isDirectionless() || (we += o)); - de += o, ot += o; + de += o, it += o; } - return t !== null && t.insertChild(r), Rs(Zn, Jn, Po, n, "created"), r; + return t !== null && t.insertChild(r), Ns(Zn, Jn, Oo, n, "created"), r; } -function Ei(e, t, n, r, o) { +function ji(e, t, n, r, o) { const i = de; de = ""; let s = n; for (; s <= r; ++s) { - co(e[s], o); - const a = Ue.get(e[s]); - a !== null && F(a) && (Ke === null && (Ke = a.getFormat()), Ge === "" && (Ge = a.getStyle())); + lo(e[s], o); + const a = He.get(e[s]); + a !== null && F(a) && (Ge === null && (Ge = a.getFormat()), Xe === "" && (Xe = a.getStyle())); } - Lo(t) && (de += st), o.element.__lexicalTextContent = de, de = i + de; + Mo(t) && (de += at), o.element.__lexicalTextContent = de, de = i + de; } -function Ka(e, t) { +function Wa(e, t) { if (e) { const n = e.__last; if (n) { @@ -4678,22 +4678,22 @@ function Ka(e, t) { } return null; } -function Yu(e, t, n) { - const r = Ka(e, Ft), o = Ka(t, Ue); +function Xu(e, t, n) { + const r = Wa(e, Ft), o = Wa(t, He); r !== o && t.getDOMSlot(n).setManagedLineBreak(o); } -function Qu(e, t) { +function Yu(e, t) { const n = t.__lexicalDirTextContent || "", r = t.__lexicalDir || ""; if (n !== we || r !== Gr) { const o = we === "", i = o ? Gr : (function(s) { - return Ob.test(s) ? "rtl" : Pb.test(s) ? "ltr" : null; + return Tb.test(s) ? "rtl" : Ob.test(s) ? "ltr" : null; })(we); if (i !== r) { - const s = t.classList, a = mt.theme; + const s = t.classList, a = yt.theme; let l = r !== null ? a[r] : void 0, u = i !== null ? a[i] : void 0; if (l !== void 0) { if (typeof l == "string") { - const d = io(l); + const d = oo(l); l = a[r] = d; } s.remove(...l); @@ -4702,7 +4702,7 @@ function Qu(e, t) { else { if (u !== void 0) { if (typeof u == "string") { - const d = io(u); + const d = oo(u); u = a[i] = d; } u !== void 0 && s.add(...u); @@ -4714,10 +4714,10 @@ function Qu(e, t) { Gr = i, t.__lexicalDirTextContent = we, t.__lexicalDir = i; } } -function Ub(e, t, n) { +function Bb(e, t, n) { const r = we; var o; - we = "", Ke = null, Ge = "", (function(i, s, a) { + we = "", Ge = null, Xe = "", (function(i, s, a) { const l = de, u = i.__size, d = s.__size; de = ""; const h = a.element; @@ -4725,7 +4725,7 @@ function Ub(e, t, n) { const f = i.__first, p = s.__first; if (f === p) Mn(f, h); else { - const m = Ti(f), y = co(p, null); + const m = Ei(f), y = lo(p, null); try { h.replaceChild(y, m); } catch (x) { @@ -4735,49 +4735,49 @@ function Ub(e, t, n) { } throw x; } - lo(f, null); + ao(f, null); } - const g = Ue.get(p); - F(g) && (Ke === null && (Ke = g.getFormat()), Ge === "" && (Ge = g.getStyle())); + const g = He.get(p); + F(g) && (Ge === null && (Ge = g.getFormat()), Xe === "" && (Xe = g.getStyle())); } else { - const f = uo(i, Ft), p = uo(s, Ue); - if (f.length !== u && M(227), p.length !== d && M(228), u === 0) d !== 0 && Ei(p, s, 0, d - 1, a); + const f = co(i, Ft), p = co(s, He); + if (f.length !== u && M(227), p.length !== d && M(228), u === 0) d !== 0 && ji(p, s, 0, d - 1, a); else if (d === 0) { if (u !== 0) { const g = a.after == null && a.before == null && a.element.__lexicalLineBreak == null; - ji(f, 0, u - 1, g ? null : h), g && (h.textContent = ""); + Ci(f, 0, u - 1, g ? null : h), g && (h.textContent = ""); } } else (function(g, m, y, x, k, v) { const b = x - 1, j = k - 1; let _, S, P = v.getFirstChild(), D = 0, $ = 0; for (; D <= b && $ <= j; ) { const O = m[D], I = y[$]; - if (O === I) P = ti(Mn(I, v.element)), D++, $++; + if (O === I) P = ei(Mn(I, v.element)), D++, $++; else { _ === void 0 && (_ = new Set(m)), S === void 0 && (S = new Set(y)); const U = S.has(O), V = _.has(I); if (U) if (V) { const q = hn(_e, I); - q === P ? P = ti(Mn(I, v.element)) : (v.withBefore(P).insertChild(q), Mn(I, v.element)), D++, $++; - } else co(I, v.withBefore(P)), $++; - else P = ti(Ti(O)), lo(O, v.element), D++; + q === P ? P = ei(Mn(I, v.element)) : (v.withBefore(P).insertChild(q), Mn(I, v.element)), D++, $++; + } else lo(I, v.withBefore(P)), $++; + else P = ei(Ei(O)), ao(O, v.element), D++; } - const N = Ue.get(I); - N !== null && F(N) && (Ke === null && (Ke = N.getFormat()), Ge === "" && (Ge = N.getStyle())); + const N = He.get(I); + N !== null && F(N) && (Ge === null && (Ge = N.getFormat()), Xe === "" && (Xe = N.getStyle())); } const C = D > b, T = $ > j; if (C && !T) { const O = y[j + 1], I = O === void 0 ? null : _e.getElementByKey(O); - Ei(y, g, $, j, v.withBefore(I)); - } else T && !C && ji(m, D, b, v.element); + ji(y, g, $, j, v.withBefore(I)); + } else T && !C && Ci(m, D, b, v.element); })(s, f, p, u, d, a); } - Lo(s) && (de += st), h.__lexicalTextContent = de, de = l + de; - })(e, t, t.getDOMSlot(n)), Qu(t, n), o = t, Ke == null || Ke === o.__textFormat || er || o.setTextFormat(Ke), (function(i) { - Ge === "" || Ge === i.__textStyle || er || i.setTextStyle(Ge); + Mo(s) && (de += at), h.__lexicalTextContent = de, de = l + de; + })(e, t, t.getDOMSlot(n)), Yu(t, n), o = t, Ge == null || Ge === o.__textFormat || er || o.setTextFormat(Ge), (function(i) { + Xe === "" || Xe === i.__textStyle || er || i.setTextStyle(Xe); })(t), we = r; } -function uo(e, t) { +function co(e, t) { const n = []; let r = e.__first; for (; r !== null; ) { @@ -4788,130 +4788,130 @@ function uo(e, t) { } function Mn(e, t) { const n = Ft.get(e); - let r = Ue.get(e); + let r = He.get(e); n !== void 0 && r !== void 0 || M(61); - const o = Ku || _i.has(e) || Si.has(e), i = hn(_e, e); + const o = Wu || Si.has(e) || wi.has(e), i = hn(_e, e); if (n === r && !o) { if (R(n)) { const s = i.__lexicalTextContent; - s !== void 0 && (de += s, ot += s); + s !== void 0 && (de += s, it += s); const a = i.__lexicalDirTextContent; a !== void 0 && (we += a); } else { const s = n.getTextContent(); - F(n) && !n.isDirectionless() && (we += s), ot += s, de += s; + F(n) && !n.isDirectionless() && (we += s), it += s, de += s; } return i; } - if (n !== r && o && Rs(Zn, Jn, Po, r, "updated"), r.updateDOM(n, i, mt)) { - const s = co(e, null); - return t === null && M(62), t.replaceChild(s, i), lo(e, null), s; + if (n !== r && o && Ns(Zn, Jn, Oo, r, "updated"), r.updateDOM(n, i, yt)) { + const s = lo(e, null); + return t === null && M(62), t.replaceChild(s, i), ao(e, null), s; } if (R(n) && R(r)) { const s = r.__indent; - s !== n.__indent && Gu(i, s); + s !== n.__indent && Ku(i, s); const a = r.__format; - a !== n.__format && Xu(i, a), o && (Ub(n, r, i), Se(r) || r.isInline() || Yu(n, r, i)), Lo(r) && (de += st, ot += st); + a !== n.__format && Gu(i, a), o && (Bb(n, r, i), Se(r) || r.isInline() || Xu(n, r, i)), Mo(r) && (de += at, it += at); } else { const s = r.getTextContent(); if (ne(r)) { - const a = r.decorate(_e, mt); - a !== null && Ju(e, a); + const a = r.decorate(_e, yt); + a !== null && Qu(e, a); } else F(r) && !r.isDirectionless() && (we += s); - de += s, ot += s; + de += s, it += s; } - if (!er && Se(r) && r.__cachedText !== ot) { + if (!er && Se(r) && r.__cachedText !== it) { const s = r.getWritable(); - s.__cachedText = ot, r = s; + s.__cachedText = it, r = s; } return i; } -function Ju(e, t) { +function Qu(e, t) { let n = _e._pendingDecorators; const r = _e._decorators; if (n === null) { if (r[e] === t) return; - n = Ad(_e); + n = Id(_e); } n[e] = t; } -function ti(e) { +function ei(e) { let t = e.nextSibling; return t !== null && t === _e._blockCursorElement && (t = t.nextSibling), t; } -function Hb(e, t, n, r, o, i) { - de = "", ot = "", we = "", Ku = r === dn, Gr = null, _e = n, mt = n._config, Jn = n._nodes, Po = _e._listeners.mutation, Si = o, _i = i, Ft = e._nodeMap, Ue = t._nodeMap, er = t._readOnly, Ci = new Map(n._keyToDOMMap); +function Ub(e, t, n, r, o, i) { + de = "", it = "", we = "", Wu = r === dn, Gr = null, _e = n, yt = n._config, Jn = n._nodes, Oo = _e._listeners.mutation, wi = o, Si = i, Ft = e._nodeMap, He = t._nodeMap, er = t._readOnly, _i = new Map(n._keyToDOMMap); const s = /* @__PURE__ */ new Map(); - return Zn = s, Mn("root", null), _e = void 0, Jn = void 0, Si = void 0, _i = void 0, Ft = void 0, Ue = void 0, mt = void 0, Ci = void 0, Zn = void 0, s; + return Zn = s, Mn("root", null), _e = void 0, Jn = void 0, wi = void 0, Si = void 0, Ft = void 0, He = void 0, yt = void 0, _i = void 0, Zn = void 0, s; } -function Ti(e) { - const t = Ci.get(e); +function Ei(e) { + const t = _i.get(e); return t === void 0 && M(75, e), t; } -function Vb(e) { +function Hb(e) { return {}; } -const Zu = {}, Wb = {}, At = {}, nn = {}, Oi = {}, rn = {}, xs = {}, Pi = {}, tr = {}, nr = {}, $t = {}, ks = {}, ws = {}, Kb = {}, ed = {}, Gb = {}, td = {}, Xb = {}, nd = {}, rd = {}, rr = {}, Yb = {}, od = {}, id = {}, sd = {}, ad = {}, ld = {}, cd = {}, Qb = {}, Jb = {}, Ss = {}, _s = {}, $i = {}, Zb = {}, ex = {}, Er = {}, Tr = {}, tx = {}, ud = {}, nx = {}, nt = Object.freeze({}), Di = 30, zi = [["keydown", function(e, t) { - if (Hn = e.timeStamp, Ii = e.key, t.isComposing()) return; +const Ju = {}, Vb = {}, At = {}, nn = {}, Ti = {}, rn = {}, bs = {}, Oi = {}, tr = {}, nr = {}, $t = {}, xs = {}, ks = {}, Wb = {}, Zu = {}, Kb = {}, ed = {}, Gb = {}, td = {}, nd = {}, rr = {}, Xb = {}, rd = {}, od = {}, id = {}, sd = {}, ad = {}, ld = {}, Yb = {}, Qb = {}, ws = {}, Ss = {}, Pi = {}, Jb = {}, Zb = {}, Er = {}, Tr = {}, ex = {}, cd = {}, tx = {}, rt = Object.freeze({}), $i = 30, Di = [["keydown", function(e, t) { + if (Hn = e.timeStamp, zi = e.key, t.isComposing()) return; const { key: n, shiftKey: r, ctrlKey: o, metaKey: i, altKey: s } = e; - if (!B(t, Kb, e) && n != null) { - if (ni && Yt(Ii)) return $e(t, (() => { - Or(t, ri); - })), ni = !1, void (ri = ""); + if (!B(t, Wb, e) && n != null) { + if (ti && Yt(zi)) return $e(t, (() => { + Or(t, ni); + })), ti = !1, void (ni = ""); if ((function(a, l, u, d) { - return kl(a) && !l && !d && !u; - })(n, o, s, i)) B(t, ed, e); - else if ((function(a, l, u, d, h) { - return kl(a) && !d && !u && (l || h); - })(n, o, r, s, i)) B(t, Gb, e); - else if ((function(a, l, u, d) { return xl(a) && !l && !d && !u; - })(n, o, s, i)) B(t, td, e); + })(n, o, s, i)) B(t, Zu, e); else if ((function(a, l, u, d, h) { return xl(a) && !d && !u && (l || h); - })(n, o, r, s, i)) B(t, Xb, e); + })(n, o, r, s, i)) B(t, Kb, e); + else if ((function(a, l, u, d) { + return bl(a) && !l && !d && !u; + })(n, o, s, i)) B(t, ed, e); + else if ((function(a, l, u, d, h) { + return bl(a) && !d && !u && (l || h); + })(n, o, r, s, i)) B(t, Gb, e); else if (/* @__PURE__ */ (function(a, l, u) { return /* @__PURE__ */ (function(d) { return d === "ArrowUp"; })(a) && !l && !u; - })(n, o, i)) B(t, nd, e); + })(n, o, i)) B(t, td, e); else if (/* @__PURE__ */ (function(a, l, u) { return /* @__PURE__ */ (function(d) { return d === "ArrowDown"; })(a) && !l && !u; - })(n, o, i)) B(t, rd, e); + })(n, o, i)) B(t, nd, e); else if ((function(a, l) { - return wl(a) && l; + return kl(a) && l; })(n, r)) Vn = !0, B(t, rr, e); else if (/* @__PURE__ */ (function(a) { return a === " "; - })(n)) B(t, Yb, e); + })(n)) B(t, Xb, e); else if ((function(a, l) { - return Fe && l && a.toLowerCase() === "o"; + return qe && l && a.toLowerCase() === "o"; })(n, o)) e.preventDefault(), Vn = !0, B(t, nn, !0); else if ((function(a, l) { - return wl(a) && !l; + return kl(a) && !l; })(n, r)) Vn = !1, B(t, rr, e); else if ((function(a, l, u, d) { - return Fe ? !l && !u && (Yt(a) || a.toLowerCase() === "h" && d) : d || l || u ? !1 : Yt(a); - })(n, s, i, o)) Yt(n) ? B(t, od, e) : (e.preventDefault(), B(t, At, !0)); + return qe ? !l && !u && (Yt(a) || a.toLowerCase() === "h" && d) : d || l || u ? !1 : Yt(a); + })(n, s, i, o)) Yt(n) ? B(t, rd, e) : (e.preventDefault(), B(t, At, !0)); else if (/* @__PURE__ */ (function(a) { return a === "Escape"; - })(n)) B(t, id, e); + })(n)) B(t, od, e); else if ((function(a, l, u, d, h) { - return Fe ? !(u || d || h) && (In(a) || a.toLowerCase() === "d" && l) : l || d || h ? !1 : In(a); - })(n, o, r, s, i)) In(n) ? B(t, sd, e) : (e.preventDefault(), B(t, At, !1)); + return qe ? !(u || d || h) && (In(a) || a.toLowerCase() === "d" && l) : l || d || h ? !1 : In(a); + })(n, o, r, s, i)) In(n) ? B(t, id, e) : (e.preventDefault(), B(t, At, !1)); else if ((function(a, l, u) { - return Yt(a) && (Fe ? l : u); + return Yt(a) && (qe ? l : u); })(n, s, o)) e.preventDefault(), B(t, tr, !0); else if ((function(a, l, u) { - return In(a) && (Fe ? l : u); + return In(a) && (qe ? l : u); })(n, s, o)) e.preventDefault(), B(t, tr, !1); else if ((function(a, l) { - return Fe && l && Yt(a); + return qe && l && Yt(a); })(n, i)) e.preventDefault(), B(t, nr, !0); else if ((function(a, l, u) { - return Fe && (l && In(a) || u && a.toLowerCase() === "k"); + return qe && (l && In(a) || u && a.toLowerCase() === "k"); })(n, i, o)) e.preventDefault(), B(t, nr, !1); else if ((function(a, l, u, d) { return a.toLowerCase() === "b" && !l && Ln(u, d); @@ -4924,65 +4924,65 @@ const Zu = {}, Wb = {}, At = {}, nn = {}, Oi = {}, rn = {}, xs = {}, Pi = {}, tr })(n, s, i, o)) e.preventDefault(), B(t, $t, "italic"); else if (/* @__PURE__ */ (function(a, l, u, d) { return a === "Tab" && !l && !u && !d; - })(n, s, o, i)) B(t, ad, e); + })(n, s, o, i)) B(t, sd, e); else if ((function(a, l, u, d) { return a.toLowerCase() === "z" && !l && Ln(u, d); - })(n, r, i, o)) e.preventDefault(), B(t, ks, void 0); + })(n, r, i, o)) e.preventDefault(), B(t, xs, void 0); else if ((function(a, l, u, d) { - return Fe ? a.toLowerCase() === "z" && u && l : a.toLowerCase() === "y" && d || a.toLowerCase() === "z" && d && l; - })(n, r, i, o)) e.preventDefault(), B(t, ws, void 0); + return qe ? a.toLowerCase() === "z" && u && l : a.toLowerCase() === "y" && d || a.toLowerCase() === "z" && d && l; + })(n, r, i, o)) e.preventDefault(), B(t, ks, void 0); else { const a = t._editorState._selection; - a === null || L(a) ? !pt && Sl(n, i, o) && (e.preventDefault(), B(t, $i, e)) : (function(l, u, d, h) { - return u ? !1 : l.toLowerCase() === "c" ? Fe ? d : h : !1; - })(n, r, i, o) ? (e.preventDefault(), B(t, Ss, e)) : (function(l, u, d, h) { - return u ? !1 : l.toLowerCase() === "x" ? Fe ? d : h : !1; - })(n, r, i, o) ? (e.preventDefault(), B(t, _s, e)) : Sl(n, i, o) && (e.preventDefault(), B(t, $i, e)); + a === null || L(a) ? !gt && wl(n, i, o) && (e.preventDefault(), B(t, Pi, e)) : (function(l, u, d, h) { + return u ? !1 : l.toLowerCase() === "c" ? qe ? d : h : !1; + })(n, r, i, o) ? (e.preventDefault(), B(t, ws, e)) : (function(l, u, d, h) { + return u ? !1 : l.toLowerCase() === "x" ? qe ? d : h : !1; + })(n, r, i, o) ? (e.preventDefault(), B(t, Ss, e)) : wl(n, i, o) && (e.preventDefault(), B(t, Pi, e)); } /* @__PURE__ */ (function(a, l, u, d) { return a || l || u || d; - })(o, r, s, i) && B(t, nx, e); + })(o, r, s, i) && B(t, tx, e); } }], ["pointerdown", function(e, t) { const n = e.target, r = e.pointerType; gr(n) && r !== "touch" && e.button === 0 && $e(t, (() => { - yl(n) || (Ni = !0); + ml(n) || (Ai = !0); })); }], ["compositionstart", function(e, t) { $e(t, (() => { const n = H(); if (L(n) && !t.isComposing()) { const r = n.anchor, o = n.anchor.getNode(); - me(r.key), (e.timeStamp < Hn + Di || r.type === "element" || !n.isCollapsed() || o.getFormat() !== n.format || F(o) && o.getStyle() !== n.style) && B(t, rn, Tb); + me(r.key), (e.timeStamp < Hn + $i || r.type === "element" || !n.isCollapsed() || o.getFormat() !== n.format || F(o) && o.getStyle() !== n.style) && B(t, rn, Eb); } })); }], ["compositionend", function(e, t) { - pt ? zn = !0 : un || !Qn && !oo ? $e(t, (() => { + gt ? zn = !0 : un || !Qn && !ro ? $e(t, (() => { Or(t, e.data); - })) : (ni = !0, ri = e.data); + })) : (ti = !0, ni = e.data); }], ["input", function(e, t) { e.stopPropagation(), $e(t, (() => { - if (Te(e.target) && yl(e.target)) return; - const n = H(), r = e.data, o = gd(e); - if (r != null && L(n) && hd(n, o, r, e.timeStamp, !1)) { + if (Te(e.target) && ml(e.target)) return; + const n = H(), r = e.data, o = pd(e); + if (r != null && L(n) && fd(n, o, r, e.timeStamp, !1)) { zn && (Or(t, r), zn = !1); - const i = n.anchor.getNode(), s = Je(Re(t)); + const i = n.anchor.getNode(), s = Ze(Me(t)); if (s === null) return; const a = n.isBackward(), l = a ? n.anchor.offset : n.focus.offset, u = a ? n.focus.offset : n.anchor.offset; - ro && !n.isCollapsed() && F(i) && s.anchorNode !== null && i.getTextContent().slice(0, l) + r + i.getTextContent().slice(l + u) === Ld(s.anchorNode) || B(t, rn, r); + no && !n.isCollapsed() && F(i) && s.anchorNode !== null && i.getTextContent().slice(0, l) + r + i.getTextContent().slice(l + u) === Md(s.anchorNode) || B(t, rn, r); const d = r.length; - pt && d > 1 && e.inputType === "insertCompositionText" && !t.isComposing() && (n.anchor.offset -= d), Qn || un || oo || !t.isComposing() || (Hn = 0, me(null)); + gt && d > 1 && e.inputType === "insertCompositionText" && !t.isComposing() && (n.anchor.offset -= d), Qn || un || ro || !t.isComposing() || (Hn = 0, me(null)); } else - As(!1, t, r !== null ? r : void 0), zn && (Or(t, r || void 0), zn = !1); + Is(!1, t, r !== null ? r : void 0), zn && (Or(t, r || void 0), zn = !1); (function() { be(); const i = le(); - Vu(i); + Hu(i); })(); }), { event: e }), Qt = null; }], ["click", function(e, t) { $e(t, (() => { - const n = H(), r = Je(Re(t)), o = ur(); + const n = H(), r = Ze(Me(t)), o = ur(); if (r) { if (L(n)) { const i = n.anchor, s = i.getNode(); @@ -5000,15 +5000,15 @@ const Zu = {}, Wb = {}, At = {}, nn = {}, Oi = {}, rn = {}, xs = {}, Pi = {}, tr } } else if (e.pointerType === "touch") { const i = r.anchorNode; - (Te(i) || ct(i)) && De(Ts(o, r, t, e)); + (Te(i) || ut(i)) && De(Es(o, r, t, e)); } } - B(t, Wb, e); + B(t, Vb, e); })); -}], ["cut", nt], ["copy", nt], ["dragstart", nt], ["dragover", nt], ["dragend", nt], ["paste", nt], ["focus", nt], ["blur", nt], ["drop", nt]]; -ro && zi.push(["beforeinput", (e, t) => (function(n, r) { - const o = n.inputType, i = gd(n); - o === "deleteCompositionText" || pt && Fd(r) || o !== "insertCompositionText" && $e(r, (() => { +}], ["cut", rt], ["copy", rt], ["dragstart", rt], ["dragover", rt], ["dragend", rt], ["paste", rt], ["focus", rt], ["blur", rt], ["drop", rt]]; +no && Di.push(["beforeinput", (e, t) => (function(n, r) { + const o = n.inputType, i = pd(n); + o === "deleteCompositionText" || gt && Ld(r) || o !== "insertCompositionText" && $e(r, (() => { const s = H(); if (o === "deleteContentBackward") { if (s === null) { @@ -5018,23 +5018,23 @@ ro && zi.push(["beforeinput", (e, t) => (function(n, r) { } if (L(s)) { const p = s.anchor.key === s.focus.key; - if (a = n.timeStamp, Ii === "MediaLast" && a < Hn + Di && r.isComposing() && p) { + if (a = n.timeStamp, zi === "MediaLast" && a < Hn + $i && r.isComposing() && p) { if (me(null), Hn = 0, setTimeout((() => { $e(r, (() => { me(null); })); - }), Di), L(s)) { + }), $i), L(s)) { const g = s.anchor.getNode(); - g.markDirty(), F(g) || M(142), pd(s, g); + g.markDirty(), F(g) || M(142), hd(s, g); } } else { me(null), n.preventDefault(); const g = s.anchor.getNode(), m = g.getTextContent(), y = g.canInsertTextAfter(), x = s.anchor.offset === 0 && s.focus.offset === m.length; - let k = qa && p && !x && y; - if (k && s.isCollapsed() && (k = !ne(Ex(s.anchor, !0))), !k) { + let k = Fa && p && !x && y; + if (k && s.isCollapsed() && (k = !ne(jx(s.anchor, !0))), !k) { B(r, At, !0); const v = H(); - qa && L(v) && v.isCollapsed() && (Pt = v, setTimeout((() => Pt = null))); + Fa && L(v) && v.isCollapsed() && (Pt = v, setTimeout((() => Pt = null))); } } return; @@ -5043,7 +5043,7 @@ ro && zi.push(["beforeinput", (e, t) => (function(n, r) { var a; if (!L(s)) return; const l = n.data; - Qt !== null && As(!1, r, Qt), s.dirty && Qt === null || !s.isCollapsed() || Se(s.anchor.getNode()) || i === null || s.applyDOMRange(i), Qt = null; + Qt !== null && Is(!1, r, Qt), s.dirty && Qt === null || !s.isCollapsed() || Se(s.anchor.getNode()) || i === null || s.applyDOMRange(i), Qt = null; const u = s.anchor, d = s.focus, h = u.getNode(), f = d.getNode(); if (o !== "insertText" && o !== "insertTranspose") switch (n.preventDefault(), o) { case "insertFromYank": @@ -5058,20 +5058,20 @@ ro && zi.push(["beforeinput", (e, t) => (function(n, r) { me(null), B(r, nn, !1); break; case "insertParagraph": - me(null), Vn && !un ? (Vn = !1, B(r, nn, !1)) : B(r, Oi, void 0); + me(null), Vn && !un ? (Vn = !1, B(r, nn, !1)) : B(r, Ti, void 0); break; case "insertFromPaste": case "insertFromPasteAsQuotation": - B(r, xs, n); + B(r, bs, n); break; case "deleteByComposition": (function(p, g) { return p !== g || R(p) || R(g) || !p.isToken() || !g.isToken(); - })(h, f) && B(r, Pi, n); + })(h, f) && B(r, Oi, n); break; case "deleteByDrag": case "deleteByCut": - B(r, Pi, n); + B(r, Oi, n); break; case "deleteContent": B(r, At, !1); @@ -5104,29 +5104,29 @@ ro && zi.push(["beforeinput", (e, t) => (function(n, r) { B(r, $t, "underline"); break; case "historyUndo": - B(r, ks, void 0); + B(r, xs, void 0); break; case "historyRedo": - B(r, ws, void 0); + B(r, ks, void 0); } else { if (l === ` `) n.preventDefault(), B(r, nn, !1); - else if (l === st) n.preventDefault(), B(r, Oi, void 0); + else if (l === at) n.preventDefault(), B(r, Ti, void 0); else if (l == null && n.dataTransfer) { const p = n.dataTransfer.getData("text/plain"); n.preventDefault(), s.insertRawText(p); - } else l != null && hd(s, i, l, n.timeStamp, !0) ? (n.preventDefault(), B(r, rn, l)) : Qt = l; - dd = n.timeStamp; + } else l != null && fd(s, i, l, n.timeStamp, !0) ? (n.preventDefault(), B(r, rn, l)) : Qt = l; + ud = n.timeStamp; } })); })(e, t)]); -let Hn = 0, Ii = null, dd = 0, Qt = null; -const fo = /* @__PURE__ */ new WeakMap(); -let Ai = !1, Ni = !1, Vn = !1, zn = !1, ni = !1, ri = "", Pt = null, fd = [0, "", 0, "root", 0]; -function hd(e, t, n, r, o) { - const i = e.anchor, s = e.focus, a = i.getNode(), l = le(), u = Je(Re(l)), d = u !== null ? u.anchorNode : null, h = i.key, f = l.getElementByKey(h), p = n.length; - return h !== s.key || !F(a) || (!o && (!ro || dd < r + 50) || a.isDirty() && p < 2 || Rd(n)) && i.offset !== s.offset && !a.isComposing() || Jt(a) || a.isDirty() && p > 1 || (o || !ro) && f !== null && !a.isComposing() && d !== fn(f) || u !== null && t !== null && (!t.collapsed || t.startContainer !== u.anchorNode || t.startOffset !== u.anchorOffset) || a.getFormat() !== e.format || a.getStyle() !== e.style || (function(g, m) { +let Hn = 0, zi = null, ud = 0, Qt = null; +const uo = /* @__PURE__ */ new WeakMap(); +let Ii = !1, Ai = !1, Vn = !1, zn = !1, ti = !1, ni = "", Pt = null, dd = [0, "", 0, "root", 0]; +function fd(e, t, n, r, o) { + const i = e.anchor, s = e.focus, a = i.getNode(), l = le(), u = Ze(Me(l)), d = u !== null ? u.anchorNode : null, h = i.key, f = l.getElementByKey(h), p = n.length; + return h !== s.key || !F(a) || (!o && (!no || ud < r + 50) || a.isDirty() && p < 2 || Nd(n)) && i.offset !== s.offset && !a.isComposing() || Jt(a) || a.isDirty() && p > 1 || (o || !no) && f !== null && !a.isComposing() && d !== fn(f) || u !== null && t !== null && (!t.collapsed || t.startContainer !== u.anchorNode || t.startOffset !== u.anchorOffset) || a.getFormat() !== e.format || a.getStyle() !== e.style || (function(g, m) { if (m.isSegmented()) return !0; if (!g.isCollapsed()) return !1; const y = g.anchor.offset, x = m.getParentOrThrow(), k = m.isToken(); @@ -5136,14 +5136,14 @@ function hd(e, t, n, r, o) { })(m) : y === m.getTextContentSize() && (!m.canInsertTextAfter() || !x.canInsertTextAfter() && !m.isComposing() || k); })(e, a); } -function Ga(e, t) { - return ct(e) && e.nodeValue !== null && t !== 0 && t !== e.nodeValue.length; +function Ka(e, t) { + return ut(e) && e.nodeValue !== null && t !== 0 && t !== e.nodeValue.length; } -function Xa(e, t, n) { +function Ga(e, t, n) { const { anchorNode: r, anchorOffset: o, focusNode: i, focusOffset: s } = e; - Ai && (Ai = !1, Ga(r, o) && Ga(i, s) && !Pt) || $e(t, (() => { + Ii && (Ii = !1, Ka(r, o) && Ka(i, s) && !Pt) || $e(t, (() => { if (!n) return void De(null); - if (!No(t, r, i)) return; + if (!Ao(t, r, i)) return; let a = H(); if (Pt && L(a) && a.isCollapsed()) { const l = a.anchor, u = Pt.anchor; @@ -5153,9 +5153,9 @@ function Xa(e, t, n) { const l = a.anchor, u = l.getNode(); if (a.isCollapsed()) { e.type === "Range" && e.anchorNode === e.focusNode && (a.dirty = !0); - const d = Re(t).event, h = d ? d.timeStamp : performance.now(), [f, p, g, m, y] = fd, x = ce(), k = t.isComposing() === !1 && x.getTextContent() === ""; + const d = Me(t).event, h = d ? d.timeStamp : performance.now(), [f, p, g, m, y] = dd, x = ce(), k = t.isComposing() === !1 && x.getTextContent() === ""; if (h < y + 200 && l.offset === g && l.key === m) Xr(a, f, p); - else if (l.type === "text") F(u) || M(141), pd(a, u); + else if (l.type === "text") F(u) || M(141), hd(a, u); else if (l.type === "element" && !k) { R(u) || M(259); const v = l.getNode(); @@ -5166,7 +5166,7 @@ function Xa(e, t, n) { } } else { const d = l.key, h = a.focus.key, f = a.getNodes(), p = f.length, g = a.isBackward(), m = g ? s : o, y = g ? o : s, x = g ? h : d, k = g ? d : h; - let v = Eb, b = !1; + let v = jb, b = !1; for (let j = 0; j < p; j++) { const _ = f[j], S = _.getTextContentSize(); if (F(_) && S !== 0 && !(j === 0 && _.__key === x && m === S || j === p - 1 && _.__key === k && y === 0) && (b = !0, v &= _.getFormat(), v === 0)) break; @@ -5174,16 +5174,16 @@ function Xa(e, t, n) { a.format = b ? v : 0; } } - B(t, Zu, void 0); + B(t, Ju, void 0); })); } function Xr(e, t, n) { e.format === t && e.style === n || (e.format = t, e.style = n, e.dirty = !0); } -function pd(e, t) { +function hd(e, t) { Xr(e, t.getFormat(), t.getStyle()); } -function gd(e) { +function pd(e) { if (!e.getTargetRanges) return null; const t = e.getTargetRanges(); return t.length === 0 ? null : t[0]; @@ -5193,7 +5193,7 @@ function Or(e, t) { if (me(null), n !== null && t != null) { if (t === "") { const r = fe(n), o = fn(e.getElementByKey(n)); - return void (o !== null && o.nodeValue !== null && F(r) && Ns(r, o.nodeValue, null, null, !0)); + return void (o !== null && o.nodeValue !== null && F(r) && As(r, o.nodeValue, null, null, !0)); } if (t[t.length - 1] === ` `) { @@ -5204,48 +5204,48 @@ function Or(e, t) { } } } - As(!0, e, t); + Is(!0, e, t); } -function md(e) { +function gd(e) { let t = e.__lexicalEventHandles; return t === void 0 && (t = [], e.__lexicalEventHandles = t), t; } const on = /* @__PURE__ */ new Map(); -function yd(e) { - const t = Dx(e.target); +function md(e) { + const t = $x(e.target); if (t === null) return; - const n = zd(t.anchorNode); + const n = Dd(t.anchorNode); if (n === null) return; - Ni && (Ni = !1, $e(n, (() => { + Ai && (Ai = !1, $e(n, (() => { const l = ur(), u = t.anchorNode; - (Te(u) || ct(u)) && De(Ts(l, t, n, e)); + (Te(u) || ut(u)) && De(Es(l, t, n, e)); }))); - const r = Is(n), o = r[r.length - 1], i = o._key, s = on.get(i), a = s || o; - a !== n && Xa(t, a, !1), Xa(t, n, !0), n !== o ? on.set(i, n) : s && on.delete(i); + const r = zs(n), o = r[r.length - 1], i = o._key, s = on.get(i), a = s || o; + a !== n && Ga(t, a, !1), Ga(t, n, !0), n !== o ? on.set(i, n) : s && on.delete(i); } -function Ya(e) { +function Xa(e) { e._lexicalHandled = !0; } -function Qa(e) { +function Ya(e) { return e._lexicalHandled === !0; } -function rx(e) { - const t = e.ownerDocument, n = fo.get(t); +function nx(e) { + const t = e.ownerDocument, n = uo.get(t); if (n === void 0) return; const r = n - 1; - r >= 0 || M(164), fo.set(t, r), r === 0 && t.removeEventListener("selectionchange", yd); - const o = Ro(e); - Ds(o) ? ((function(s) { + r >= 0 || M(164), uo.set(t, r), r === 0 && t.removeEventListener("selectionchange", md); + const o = No(e); + $s(o) ? ((function(s) { if (s._parentEditor !== null) { - const a = Is(s), l = a[a.length - 1]._key; + const a = zs(s), l = a[a.length - 1]._key; on.get(l) === s && on.delete(l); } else on.delete(s._key); })(o), e.__lexicalEditor = null) : o && M(198); - const i = md(e); + const i = gd(e); for (let s = 0; s < i.length; s++) i[s](); e.__lexicalEventHandles = []; } -function Ri(e, t, n) { +function Ni(e, t, n) { be(); const r = e.__key, o = e.getParent(); if (o === null) return; @@ -5253,20 +5253,20 @@ function Ri(e, t, n) { const l = H(); if (!L(l) || !R(a)) return l; const { anchor: u, focus: d } = l, h = u.getNode(), f = d.getNode(); - return Li(h, a) && u.set(a.__key, 0, "element"), Li(f, a) && d.set(a.__key, 0, "element"), l; + return Mi(h, a) && u.set(a.__key, 0, "element"), Mi(f, a) && d.set(a.__key, 0, "element"), l; })(e); let s = !1; if (L(i) && t) { const a = i.anchor, l = i.focus; - a.key === r && (po(a, e, o, e.getPreviousSibling(), e.getNextSibling()), s = !0), l.key === r && (po(l, e, o, e.getPreviousSibling(), e.getNextSibling()), s = !0); - } else Es(i) && t && e.isSelected() && e.selectPrevious(); + a.key === r && (ho(a, e, o, e.getPreviousSibling(), e.getNextSibling()), s = !0), l.key === r && (ho(l, e, o, e.getPreviousSibling(), e.getNextSibling()), s = !0); + } else js(i) && t && e.isSelected() && e.selectPrevious(); if (L(i) && t && !s) { const a = e.getIndexWithinParent(); - Nt(e), ho(i, o, a, -1); + Nt(e), fo(i, o, a, -1); } else Nt(e); - n || jt(o) || o.canBeEmpty() || !o.isEmpty() || Ri(o, t), t && i && Se(o) && o.isEmpty() && o.selectEnd(); + n || jt(o) || o.canBeEmpty() || !o.isEmpty() || Ni(o, t), t && i && Se(o) && o.isEmpty() && o.selectEnd(); } -class $o { +class Po { static getType() { M(64, this.name); } @@ -5277,7 +5277,7 @@ class $o { this.__parent = t.__parent, this.__next = t.__next, this.__prev = t.__prev, this.__state = t.__state; } constructor(t) { - this.__type = this.constructor.getType(), this.__parent = null, this.__prev = null, this.__next = null, Object.defineProperty(this, "__state", { configurable: !0, enumerable: !1, value: void 0, writable: !0 }), Cx(this, t); + this.__type = this.constructor.getType(), this.__parent = null, this.__prev = null, this.__next = null, Object.defineProperty(this, "__state", { configurable: !0, enumerable: !1, value: void 0, writable: !0 }), _x(this, t); } getType() { return this.__type; @@ -5386,7 +5386,7 @@ class $o { } isBefore(t) { const n = Qr(this, t); - return n !== null && (n.type === "descendant" || (n.type === "branch" ? Vd(n) === -1 : (n.type !== "same" && n.type !== "ancestor" && M(279), !1))); + return n !== null && (n.type === "descendant" || (n.type === "branch" ? Hd(n) === -1 : (n.type !== "same" && n.type !== "ancestor" && M(279), !1))); } isParentOf(t) { const n = Qr(this, t); @@ -5430,9 +5430,9 @@ class $o { getWritable() { be(); const t = Ct(), n = le(), r = t._nodeMap, o = this.__key, i = this.getLatest(), s = n._cloneNotNeeded, a = H(); - if (a !== null && a.setCachedNodes(null), s.has(o)) return mo(i), i; - const l = Bd(i); - return s.add(o), mo(l), r.set(o, l), l; + if (a !== null && a.setCachedNodes(null), s.has(o)) return go(i), i; + const l = qd(i); + return s.add(o), go(l), r.set(o, l), l; } getTextContent() { return ""; @@ -5459,33 +5459,33 @@ class $o { updateFromJSON(t) { return (function(n, r) { const o = n.getWritable(); - return (r || o.__state) && qb(n).updateFromJSON(r), o; + return (r || o.__state) && Fb(n).updateFromJSON(r), o; })(this, t.$); } static transform() { return null; } remove(t) { - Ri(this, !0, t); + Ni(this, !0, t); } replace(t, n) { be(); let r = H(); - r !== null && (r = r.clone()), ci(this, t); + r !== null && (r = r.clone()), li(this, t); const o = this.getLatest(), i = this.__key, s = t.__key, a = t.getWritable(), l = this.getParentOrThrow().getWritable(), u = l.__size; Nt(a); const d = o.getPreviousSibling(), h = o.getNextSibling(), f = o.__prev, p = o.__next, g = o.__parent; - if (Ri(o, !1, !0), d === null ? l.__first = s : d.getWritable().__next = s, a.__prev = f, h === null ? l.__last = s : h.getWritable().__prev = s, a.__next = p, a.__parent = g, l.__size = u, n && (R(this) && R(a) || M(139), this.getChildren().forEach(((m) => { + if (Ni(o, !1, !0), d === null ? l.__first = s : d.getWritable().__next = s, a.__prev = f, h === null ? l.__last = s : h.getWritable().__prev = s, a.__next = p, a.__parent = g, l.__size = u, n && (R(this) && R(a) || M(139), this.getChildren().forEach(((m) => { a.append(m); }))), L(r)) { De(r); const m = r.anchor, y = r.focus; - m.key === i && tl(m, a), y.key === i && tl(y, a); + m.key === i && el(m, a), y.key === i && el(y, a); } - return ft() === i && me(s), a; + return ht() === i && me(s), a; } insertAfter(t, n = !0) { - be(), ci(this, t); + be(), li(this, t); const r = this.getWritable(), o = t.getWritable(), i = o.getParent(), s = H(); let a = !1, l = !1; if (i !== null) { @@ -5498,20 +5498,20 @@ class $o { const u = this.getNextSibling(), d = this.getParentOrThrow().getWritable(), h = o.__key, f = r.__next; if (u === null ? d.__last = h : u.getWritable().__prev = h, d.__size++, r.__next = h, o.__next = f, o.__prev = r.__key, o.__parent = r.__parent, n && L(s)) { const p = this.getIndexWithinParent(); - ho(s, d, p + 1); + fo(s, d, p + 1); const g = d.__key; a && s.anchor.set(g, p + 2, "element"), l && s.focus.set(g, p + 2, "element"); } return t; } insertBefore(t, n = !0) { - be(), ci(this, t); + be(), li(this, t); const r = this.getWritable(), o = t.getWritable(), i = o.__key; Nt(o); const s = this.getPreviousSibling(), a = this.getParentOrThrow().getWritable(), l = r.__prev, u = this.getIndexWithinParent(); s === null ? a.__first = i : s.getWritable().__next = i, a.__size++, r.__prev = i, o.__prev = l, o.__next = r.__key, o.__parent = r.__parent; const d = H(); - return n && L(d) && ho(d, this.getParentOrThrow(), u), t; + return n && L(d) && fo(d, this.getParentOrThrow(), u), t; } isParentRequired() { return !1; @@ -5554,7 +5554,7 @@ class $o { this.markDirty(); } } -class jn extends $o { +class jn extends Po { static getType() { return "linebreak"; } @@ -5580,7 +5580,7 @@ class jn extends $o { static importDOM() { return { br: (t) => (function(n) { const r = n.parentElement; - if (r !== null && Cl(r)) { + if (r !== null && _l(r)) { const o = r.firstChild; if (o === n || o.nextSibling === n && Pr(o)) { const i = r.lastChild; @@ -5590,44 +5590,44 @@ class jn extends $o { return !1; })(t) || (function(n) { const r = n.parentElement; - if (r !== null && Cl(r)) { + if (r !== null && _l(r)) { const o = r.firstChild; if (o === n || o.nextSibling === n && Pr(o)) return !1; const i = r.lastChild; if (i === n || i.previousSibling === n && Pr(i)) return !0; } return !1; - })(t) ? null : { conversion: ox, priority: 0 } }; + })(t) ? null : { conversion: rx, priority: 0 } }; } static importJSON(t) { return qt().updateFromJSON(t); } } -function ox(e) { +function rx(e) { return { node: qt() }; } function qt() { - return Fo(new jn()); + return Lo(new jn()); } function Wn(e) { return e instanceof jn; } function Pr(e) { - return ct(e) && /^( |\t|\r?\n)+$/.test(e.textContent || ""); + return ut(e) && /^( |\t|\r?\n)+$/.test(e.textContent || ""); } -function oi(e, t) { - return 16 & t ? "code" : t & ds ? "mark" : 32 & t ? "sub" : 64 & t ? "sup" : null; +function ri(e, t) { + return 16 & t ? "code" : t & us ? "mark" : 32 & t ? "sub" : 64 & t ? "sup" : null; } -function ii(e, t) { +function oi(e, t) { return 1 & t ? "strong" : 2 & t ? "em" : "span"; } -function vd(e, t, n, r, o) { +function yd(e, t, n, r, o) { const i = r.classList; let s = sn(o, "base"); s !== void 0 && i.add(...s), s = sn(o, "underlineStrikethrough"); let a = !1; - const l = t & ao && t & so; - s !== void 0 && (n & ao && n & so ? (a = !0, l || i.add(...s)) : l && i.remove(...s)); + const l = t & so && t & io; + s !== void 0 && (n & so && n & io ? (a = !0, l || i.add(...s)) : l && i.remove(...s)); for (const u in Lt) { const d = Lt[u]; if (s = sn(o, u), s !== void 0) if (n & d) { @@ -5639,12 +5639,12 @@ function vd(e, t, n, r, o) { } else t & d && i.remove(...s); } } -function bd(e, t, n) { - const r = t.firstChild, o = n.isComposing(), i = e + (o ? Oo : ""); +function vd(e, t, n) { + const r = t.firstChild, o = n.isComposing(), i = e + (o ? To : ""); if (r == null) t.textContent = i; else { const s = r.nodeValue; - if (s !== i) if (o || pt) { + if (s !== i) if (o || gt) { const [a, l, u] = (function(d, h) { const f = d.length, p = h.length; let g = 0, m = 0; @@ -5656,16 +5656,16 @@ function bd(e, t, n) { } else r.nodeValue = i; } } -function Ja(e, t, n, r, o, i) { - bd(o, e, t); +function Qa(e, t, n, r, o, i) { + vd(o, e, t); const s = i.theme.text; - s !== void 0 && vd(0, 0, r, e, s); + s !== void 0 && yd(0, 0, r, e, s); } function $r(e, t) { const n = document.createElement(t); return n.appendChild(e), n; } -class _t extends $o { +class _t extends Po { static getType() { return "text"; } @@ -5686,7 +5686,7 @@ class _t extends $o { } getMode() { const t = this.getLatest(); - return Ib[t.__mode]; + return zb[t.__mode]; } getStyle() { return this.getLatest().__style; @@ -5695,7 +5695,7 @@ class _t extends $o { return this.getLatest().__mode === 1; } isComposing() { - return this.__key === ft(); + return this.__key === ht(); } isSegmented() { return this.getLatest().__mode === 2; @@ -5717,7 +5717,7 @@ class _t extends $o { return this.getLatest().__text; } getFormatFlags(t, n) { - return go(this.getLatest().__format, t, n); + return po(this.getLatest().__format, t, n); } canHaveFormat() { return !0; @@ -5726,30 +5726,30 @@ class _t extends $o { return !0; } createDOM(t, n) { - const r = this.__format, o = oi(0, r), i = ii(0, r), s = o === null ? i : o, a = document.createElement(s); + const r = this.__format, o = ri(0, r), i = oi(0, r), s = o === null ? i : o, a = document.createElement(s); let l = a; - this.hasFormat("code") && a.setAttribute("spellcheck", "false"), o !== null && (l = document.createElement(i), a.appendChild(l)), Ja(l, this, 0, r, this.__text, t); + this.hasFormat("code") && a.setAttribute("spellcheck", "false"), o !== null && (l = document.createElement(i), a.appendChild(l)), Qa(l, this, 0, r, this.__text, t); const u = this.__style; return u !== "" && (a.style.cssText = u), a; } updateDOM(t, n, r) { - const o = this.__text, i = t.__format, s = this.__format, a = oi(0, i), l = oi(0, s), u = ii(0, i), d = ii(0, s); + const o = this.__text, i = t.__format, s = this.__format, a = ri(0, i), l = ri(0, s), u = oi(0, i), d = oi(0, s); if ((a === null ? u : a) !== (l === null ? d : l)) return !0; if (a === l && u !== d) { const m = n.firstChild; m == null && M(48); const y = document.createElement(d); - return Ja(y, this, 0, s, o, r), n.replaceChild(y, m), !1; + return Qa(y, this, 0, s, o, r), n.replaceChild(y, m), !1; } let h = n; - l !== null && a !== null && (h = n.firstChild, h == null && M(49)), bd(o, h, this); + l !== null && a !== null && (h = n.firstChild, h == null && M(49)), vd(o, h, this); const f = r.theme.text; - f !== void 0 && i !== s && vd(0, i, s, h, f); + f !== void 0 && i !== s && yd(0, i, s, h, f); const p = t.__style, g = this.__style; return p !== g && (n.style.cssText = g), !1; } static importDOM() { - return { "#text": () => ({ conversion: lx, priority: 0 }), b: () => ({ conversion: sx, priority: 0 }), code: () => ({ conversion: rt, priority: 0 }), em: () => ({ conversion: rt, priority: 0 }), i: () => ({ conversion: rt, priority: 0 }), mark: () => ({ conversion: rt, priority: 0 }), s: () => ({ conversion: rt, priority: 0 }), span: () => ({ conversion: ix, priority: 0 }), strong: () => ({ conversion: rt, priority: 0 }), sub: () => ({ conversion: rt, priority: 0 }), sup: () => ({ conversion: rt, priority: 0 }), u: () => ({ conversion: rt, priority: 0 }) }; + return { "#text": () => ({ conversion: ax, priority: 0 }), b: () => ({ conversion: ix, priority: 0 }), code: () => ({ conversion: ot, priority: 0 }), em: () => ({ conversion: ot, priority: 0 }), i: () => ({ conversion: ot, priority: 0 }), mark: () => ({ conversion: ot, priority: 0 }), s: () => ({ conversion: ot, priority: 0 }), span: () => ({ conversion: ox, priority: 0 }), strong: () => ({ conversion: ot, priority: 0 }), sub: () => ({ conversion: ot, priority: 0 }), sup: () => ({ conversion: ot, priority: 0 }), u: () => ({ conversion: ot, priority: 0 }) }; } static importJSON(t) { return ae().updateFromJSON(t); @@ -5772,14 +5772,14 @@ class _t extends $o { } setDetail(t) { const n = this.getWritable(); - return n.__detail = typeof t == "string" ? $b[t] : t, n; + return n.__detail = typeof t == "string" ? Pb[t] : t, n; } setStyle(t) { const n = this.getWritable(); return n.__style = t, n; } toggleFormat(t) { - const n = go(this.getFormat(), t, null); + const n = po(this.getFormat(), t, null); return this.setFormat(n); } toggleDirectionless() { @@ -5791,7 +5791,7 @@ class _t extends $o { return t.__detail ^= 2, t; } setMode(t) { - const n = zb[t]; + const n = Db[t]; if (this.__mode === n) return this; const r = this.getWritable(); return r.__mode = n, r; @@ -5809,9 +5809,9 @@ class _t extends $o { const l = s.length; r === void 0 && (r = l), o === void 0 && (o = l); } else r = 0, o = 0; - if (!L(i)) return wd(a, r, a, o, "text", "text"); + if (!L(i)) return kd(a, r, a, o, "text", "text"); { - const l = ft(); + const l = ht(); l !== i.anchor.key && l !== i.focus.key || me(a), i.setTextNodeRange(this, r, this, o); } return i; @@ -5845,7 +5845,7 @@ class _t extends $o { be(); const n = this.getLatest(), r = n.getTextContent(); if (r === "") return []; - const o = n.__key, i = ft(), s = r.length; + const o = n.__key, i = ht(), s = r.length; t.sort(((P, D) => P - D)), t.push(s); const a = [], l = t.length; for (let P = 0, D = 0; P < s && D <= l; D++) { @@ -5885,10 +5885,10 @@ class _t extends $o { if (h !== null) { (function($) { const C = $.getPreviousSibling(), T = $.getNextSibling(); - C !== null && mo(C), T !== null && mo(T); + C !== null && go(C), T !== null && go(T); })(this); const P = h.getWritable(), D = this.getIndexWithinParent(); - y ? (P.splice(D, 0, b), this.remove()) : P.splice(D, 1, b), L(v) && ho(v, h, D, u - 1); + y ? (P.splice(D, 0, b), this.remove()) : P.splice(D, 1, b), L(v) && fo(v, h, D, u - 1); } return b; } @@ -5896,11 +5896,11 @@ class _t extends $o { const n = t === this.getPreviousSibling(); n || t === this.getNextSibling() || M(50); const r = this.__key, o = t.__key, i = this.__text, s = i.length; - ft() === o && me(r); + ht() === o && me(r); const a = H(); if (L(a)) { const h = a.anchor, f = a.focus; - h !== null && h.key === o && ll(h, n, r, t, s), f !== null && f.key === o && ll(f, n, r, t, s); + h !== null && h.key === o && al(h, n, r, t, s), f !== null && f.key === o && al(f, n, r, t, s); } const l = t.__text, u = n ? l + i : i + l; this.setTextContent(u); @@ -5911,30 +5911,30 @@ class _t extends $o { return !1; } } -function ix(e) { - return { forChild: Cs(e.style), node: null }; +function ox(e) { + return { forChild: _s(e.style), node: null }; } -function sx(e) { +function ix(e) { const t = e, n = t.style.fontWeight === "normal"; - return { forChild: Cs(t.style, n ? void 0 : "bold"), node: null }; + return { forChild: _s(t.style, n ? void 0 : "bold"), node: null }; } -const Za = /* @__PURE__ */ new WeakMap(); -function ax(e) { +const Ja = /* @__PURE__ */ new WeakMap(); +function sx(e) { if (!Te(e)) return !1; if (e.nodeName === "PRE") return !0; const t = e.style.whiteSpace; return typeof t == "string" && t.startsWith("pre"); } -function lx(e) { +function ax(e) { const t = e; e.parentElement === null && M(129); let n = t.textContent || ""; if ((function(r) { let o, i = r.parentNode; const s = [r]; - for (; i !== null && (o = Za.get(i)) === void 0 && !ax(i); ) s.push(i), i = i.parentNode; + for (; i !== null && (o = Ja.get(i)) === void 0 && !sx(i); ) s.push(i), i = i.parentNode; const a = o === void 0 ? i : o; - for (let l = 0; l < s.length; l++) Za.set(s[l], a); + for (let l = 0; l < s.length; l++) Ja.set(s[l], a); return a; })(t) !== null) { const r = n.split(/(\r?\n|\t)/), o = [], i = r.length; @@ -5942,14 +5942,14 @@ function lx(e) { const a = r[s]; a === ` ` || a === `\r -` ? o.push(qt()) : a === " " ? o.push(js()) : a !== "" && o.push(ae(a)); +` ? o.push(qt()) : a === " " ? o.push(Cs()) : a !== "" && o.push(ae(a)); } return { node: o }; } if (n = n.replace(/\r/g, "").replace(/[ \t\n]+/g, " "), n === "") return { node: null }; if (n[0] === " ") { let r = t, o = !0; - for (; r !== null && (r = el(r, !1)) !== null; ) { + for (; r !== null && (r = Za(r, !1)) !== null; ) { const i = r.textContent || ""; if (i.length > 0) { /[ \t\n]$/.test(i) && (n = n.slice(1)), o = !1; @@ -5960,7 +5960,7 @@ function lx(e) { } if (n[n.length - 1] === " ") { let r = t, o = !0; - for (; r !== null && (r = el(r, !0)) !== null; ) + for (; r !== null && (r = Za(r, !0)) !== null; ) if ((r.textContent || "").replace(/^( |\t|\r?\n)+/, "").length > 0) { o = !1; break; @@ -5969,7 +5969,7 @@ function lx(e) { } return n === "" ? { node: null } : { node: ae(n) }; } -function el(e, t) { +function Za(e, t) { let n = e; for (; ; ) { let r; @@ -5980,26 +5980,26 @@ function el(e, t) { } if (n = r, Te(n)) { const i = n.style.display; - if (i === "" && !zx(n) || i !== "" && !i.startsWith("inline")) return null; + if (i === "" && !Dx(n) || i !== "" && !i.startsWith("inline")) return null; } let o = n; for (; (o = t ? n.firstChild : n.lastChild) !== null; ) n = o; - if (ct(n)) return n; + if (ut(n)) return n; if (n.nodeName === "BR") return null; } } -const cx = { code: "code", em: "italic", i: "italic", mark: "highlight", s: "strikethrough", strong: "bold", sub: "subscript", sup: "superscript", u: "underline" }; -function rt(e) { - const t = cx[e.nodeName.toLowerCase()]; - return t === void 0 ? { node: null } : { forChild: Cs(e.style, t), node: null }; +const lx = { code: "code", em: "italic", i: "italic", mark: "highlight", s: "strikethrough", strong: "bold", sub: "subscript", sup: "superscript", u: "underline" }; +function ot(e) { + const t = lx[e.nodeName.toLowerCase()]; + return t === void 0 ? { node: null } : { forChild: _s(e.style, t), node: null }; } function ae(e = "") { - return Fo(new _t(e)); + return Lo(new _t(e)); } function F(e) { return e instanceof _t; } -function Cs(e, t) { +function _s(e, t) { const n = e.fontWeight, r = e.textDecoration.split(" "), o = n === "700" || n === "bold", i = r.includes("line-through"), s = e.fontStyle === "italic", a = r.includes("underline"), l = e.verticalAlign; return (u) => (F(u) && (o && !u.hasFormat("bold") && u.toggleFormat("bold"), i && !u.hasFormat("strikethrough") && u.toggleFormat("strikethrough"), s && !u.hasFormat("italic") && u.toggleFormat("italic"), a && !u.hasFormat("underline") && u.toggleFormat("underline"), l !== "sub" || u.hasFormat("subscript") || u.toggleFormat("subscript"), l !== "super" || u.hasFormat("superscript") || u.toggleFormat("superscript"), t && !u.hasFormat(t) && u.toggleFormat(t)), u); } @@ -6021,7 +6021,7 @@ class cr extends _t { return r !== void 0 && n.classList.add(...r), n; } static importJSON(t) { - return js().updateFromJSON(t); + return Cs().updateFromJSON(t); } setTextContent(t) { return t !== " " && t !== "" && M(126), super.setTextContent(t); @@ -6039,13 +6039,13 @@ class cr extends _t { return !1; } } -function js() { - return Fo(new cr()); +function Cs() { + return Lo(new cr()); } -function ux(e) { +function cx(e) { return e instanceof cr; } -class dx { +class ux { constructor(t, n, r) { this._selection = null, this.key = t, this.offset = n, this.type = r; } @@ -6053,7 +6053,7 @@ class dx { return this.key === t.key && this.offset === t.offset && this.type === t.type; } isBefore(t) { - return this.key === t.key ? this.offset < t.offset : Hd(Xe(vt(this, "next")), Xe(vt(t, "next"))) < 0; + return this.key === t.key ? this.offset < t.offset : Ud(Ye(bt(this, "next")), Ye(bt(t, "next"))) < 0; } getNode() { const t = fe(this.key); @@ -6061,13 +6061,13 @@ class dx { } set(t, n, r, o) { const i = this._selection, s = this.key; - o && this.key === t && this.offset === n && this.type === r || (this.key = t, this.offset = n, this.type = r, dr() || (ft() === s && me(t), i !== null && (i.setCachedNodes(null), i.dirty = !0))); + o && this.key === t && this.offset === n && this.type === r || (this.key = t, this.offset = n, this.type = r, dr() || (ht() === s && me(t), i !== null && (i.setCachedNodes(null), i.dirty = !0))); } } -function Qe(e, t, n) { - return new dx(e, t, n); +function Je(e, t, n) { + return new ux(e, t, n); } -function si(e, t) { +function ii(e, t) { let n = t.__key, r = e.offset, o = "element"; if (F(t)) { o = "text"; @@ -6083,13 +6083,13 @@ function si(e, t) { } e.set(n, r, o); } -function tl(e, t) { +function el(e, t) { if (R(t)) { const n = t.getLastDescendant(); - R(n) || F(n) ? si(e, n) : si(e, t); - } else si(e, t); + R(n) || F(n) ? ii(e, n) : ii(e, t); + } else ii(e, t); } -class Do { +class $o { constructor(t) { this._cachedNodes = null, this._nodes = t, this.dirty = !1; } @@ -6100,7 +6100,7 @@ class Do { this._cachedNodes = t; } is(t) { - if (!Es(t)) return !1; + if (!js(t)) return !1; const n = this._nodes, r = t._nodes; return n.size === r.size && Array.from(n).every(((o) => r.has(o))); } @@ -6126,7 +6126,7 @@ class Do { return this._nodes.has(t); } clone() { - return new Do(new Set(this._nodes)); + return new $o(new Set(this._nodes)); } extract() { return this.getNodes(); @@ -6166,7 +6166,7 @@ class Do { const t = this.getNodes(); if ((H() || ur()) === this && t[0]) { const n = ke(t[0], "next"); - Vx(Vt(n, n)); + Hx(Vt(n, n)); } for (const n of t) n.remove(); } @@ -6197,25 +6197,25 @@ class Kt { const o = [], [i, s] = r.getTextSlices(); i && o.push(i.caret.origin); const a = /* @__PURE__ */ new Set(), l = /* @__PURE__ */ new Set(); - for (const u of r) if (Ye(u)) { + for (const u of r) if (Qe(u)) { const { origin: d } = u; o.length === 0 ? a.add(d) : (l.add(d), o.push(d)); } else { const { origin: d } = u; R(d) && l.has(d) || o.push(d); } - if (s && o.push(s.caret.origin), pn(r.focus) && R(r.focus.origin) && r.focus.getNodeAtCaret() === null) for (let u = yt(r.focus.origin, "previous"); Ye(u) && a.has(u.origin) && !u.origin.isEmpty() && u.origin.is(o[o.length - 1]); u = qs(u)) a.delete(u.origin), o.pop(); + if (s && o.push(s.caret.origin), pn(r.focus) && R(r.focus.origin) && r.focus.getNodeAtCaret() === null) for (let u = vt(r.focus.origin, "previous"); Qe(u) && a.has(u.origin) && !u.origin.isEmpty() && u.origin.is(o[o.length - 1]); u = Fs(u)) a.delete(u.origin), o.pop(); for (; o.length > 1; ) { const u = o[o.length - 1]; if (!R(u) || l.has(u) || u.isEmpty() || a.has(u)) break; o.pop(); } if (o.length === 0 && r.isCollapsed()) { - const u = Xe(r.anchor), d = Xe(r.anchor.getFlipped()), h = (p) => Rt(p) ? p.origin : p.getNodeAtCaret(), f = h(u) || h(d) || (r.anchor.getNodeAtCaret() ? u.origin : d.origin); + const u = Ye(r.anchor), d = Ye(r.anchor.getFlipped()), h = (p) => Rt(p) ? p.origin : p.getNodeAtCaret(), f = h(u) || h(d) || (r.anchor.getNodeAtCaret() ? u.origin : d.origin); o.push(f); } return o; - })(Kd(Pl(this), "next")); + })(Wd(Ol(this), "next")); return dr() || (this._cachedNodes = n), n; } setTextNodeRange(t, n, r, o) { @@ -6224,7 +6224,7 @@ class Kt { getTextContent() { const t = this.getNodes(); if (t.length === 0) return ""; - const n = t[0], r = t[t.length - 1], o = this.anchor, i = this.focus, s = o.isBefore(i), [a, l] = Mi(this); + const n = t[0], r = t[t.length - 1], o = this.anchor, i = this.focus, s = o.isBefore(i), [a, l] = Ri(this); let u = "", d = !0; for (let h = 0; h < t.length; h++) { const f = t[h]; @@ -6238,17 +6238,17 @@ class Kt { return u; } applyDOMRange(t) { - const n = le(), r = n.getEditorState()._selection, o = kd(t.startContainer, t.startOffset, t.endContainer, t.endOffset, n, r); + const n = le(), r = n.getEditorState()._selection, o = xd(t.startContainer, t.startOffset, t.endContainer, t.endOffset, n, r); if (o === null) return; const [i, s] = o; - this.anchor.set(i.key, i.offset, i.type, !0), this.focus.set(s.key, s.offset, s.type, !0), wi(this); + this.anchor.set(i.key, i.offset, i.type, !0), this.focus.set(s.key, s.offset, s.type, !0), ki(this); } clone() { const t = this.anchor, n = this.focus; - return new Kt(Qe(t.key, t.offset, t.type), Qe(n.key, n.offset, n.type), this.format, this.style); + return new Kt(Je(t.key, t.offset, t.type), Je(n.key, n.offset, n.type), this.format, this.style); } toggleFormat(t) { - this.format = go(this.format, t, null), this.dirty = !0; + this.format = po(this.format, t, null), this.dirty = !0; } setStyle(t) { this.style = t, this.dirty = !0; @@ -6263,7 +6263,7 @@ class Kt { const s = n[i]; s === ` ` || s === `\r -` ? r.push(qt()) : s === " " ? r.push(js()) : r.push(ae(s)); +` ? r.push(qt()) : s === " " ? r.push(Cs()) : r.push(ae(s)); } this.insertNodes(r); } @@ -6273,7 +6273,7 @@ class Kt { !this.isCollapsed() && r.isBefore(n) && (s = r, a = n), s.type === "element" && (function(y, x, k, v) { const b = y.getNode(), j = b.getChildAtIndex(y.offset), _ = ae(), S = Se(b) ? Ne().append(_) : _; _.setFormat(k), _.setStyle(v), j === null ? b.append(S) : j.insertBefore(S), y.is(x) && x.set(_.__key, 0, "text"), y.set(_.__key, 0, "text"); - })(s, a, o, i), a.type === "element" && ir(a, Xe(vt(a, "next"))); + })(s, a, o, i), a.type === "element" && ir(a, Ye(bt(a, "next"))); const l = s.offset; let u = a.offset; const d = this.getNodes(), h = d.length; @@ -6292,7 +6292,7 @@ class Kt { y.setFormat(o), f.replace(y), f = y; } else if (!this.isCollapsed() && t !== "") { const y = m.getParent(); - if (!g.canInsertTextBefore() || !g.canInsertTextAfter() || R(y) && (!y.canInsertTextBefore() || !y.canInsertTextAfter())) return this.insertText(""), xd(this.anchor, this.focus, null), void this.insertText(t); + if (!g.canInsertTextBefore() || !g.canInsertTextAfter() || R(y) && (!y.canInsertTextBefore() || !y.canInsertTextAfter())) return this.insertText(""), bd(this.anchor, this.focus, null), void this.insertText(t); } if (h === 1) { if (f.isToken()) { @@ -6301,7 +6301,7 @@ class Kt { } const y = f.getFormat(), x = f.getStyle(); if (l !== u || y === o && x === i) { - if (ux(f)) { + if (cx(f)) { const v = ae(t); return v.setFormat(o), v.setStyle(i), v.select(), void f.replace(v); } @@ -6363,7 +6363,7 @@ class Kt { } removeText() { const t = H() === this; - Jr(this, Wx(Pl(this))), t && H() !== this && De(this); + Jr(this, Vx(Ol(this))), t && H() !== this && De(this); } formatText(t, n = null) { if (this.isCollapsed()) return this.toggleFormat(t), void me(null); @@ -6411,18 +6411,18 @@ class Kt { const g = H(); return L(g) || M(134), g.insertNodes(t); } - const n = (this.isBackward() ? this.focus : this.anchor).getNode(), r = di(n, dt), o = t[t.length - 1]; + const n = (this.isBackward() ? this.focus : this.anchor).getNode(), r = ui(n, ft), o = t[t.length - 1]; if (R(r) && "__language" in r) { if ("__language" in t[0]) this.insertText(t[0].getTextContent()); else { - const g = ai(this); + const g = si(this); r.splice(g, 0, t), o.selectEnd(); } return; } if (!t.some(((g) => (R(g) || ne(g)) && !g.isInline()))) { R(r) || M(211, n.constructor.name, n.getType()); - const g = ai(this); + const g = si(this); return r.splice(g, 0, t), void o.selectEnd(); } const i = (function(g) { @@ -6439,7 +6439,7 @@ class Kt { })(t), s = i.getLastDescendant(), a = i.getChildren(), l = !R(r) || !r.isEmpty() ? this.insertParagraph() : null, u = a[a.length - 1]; let d = a[0]; var h; - R(h = d) && dt(h) && !h.isEmpty() && R(r) && (!r.isEmpty() || r.canMergeWhenEmpty()) && (R(r) || M(211, n.constructor.name, n.getType()), r.append(...d.getChildren()), d = a[1]), d && (r === null && M(212, n.constructor.name, n.getType()), (function(g, m, y) { + R(h = d) && ft(h) && !h.isEmpty() && R(r) && (!r.isEmpty() || r.canMergeWhenEmpty()) && (R(r) || M(211, n.constructor.name, n.getType()), r.append(...d.getChildren()), d = a[1]), d && (r === null && M(212, n.constructor.name, n.getType()), (function(g, m, y) { const x = m.getParentOrThrow().getLastChild(); let k = m; const v = [m]; @@ -6447,8 +6447,8 @@ class Kt { let b = g; for (const j of v) b = b.insertAfter(j); })(r, d)); - const f = di(s, dt); - l && R(f) && (l.canMergeWhenEmpty() || dt(u)) && (f.append(...l.getChildren()), l.remove()), R(r) && r.isEmpty() && r.remove(), s.selectEnd(); + const f = ui(s, ft); + l && R(f) && (l.canMergeWhenEmpty() || ft(u)) && (f.append(...l.getChildren()), l.remove()), R(r) && r.isEmpty() && r.remove(), s.selectEnd(); const p = R(r) ? r.getLastChild() : null; Wn(p) && f !== r && p.remove(); } @@ -6457,7 +6457,7 @@ class Kt { const s = Ne(); return ce().splice(this.anchor.offset, 0, [s]), s.select(), s; } - const t = ai(this), n = di(this.anchor.getNode(), dt); + const t = si(this), n = ui(this.anchor.getNode(), ft); R(n) || M(213); const r = n.getChildAtIndex(t), o = r ? [r, ...r.getNextSiblings()] : [], i = n.insertNewAfter(this, !1); return i ? (i.append(...o), i.selectStart(), i) : null; @@ -6472,7 +6472,7 @@ class Kt { extract() { const t = this.getNodes(), n = t.length, r = n - 1, o = this.anchor, i = this.focus; let s = t[0], a = t[r]; - const [l, u] = Mi(this); + const [l, u] = Ri(this); if (n === 0) return []; if (n === 1) { if (F(s) && !this.isCollapsed()) { @@ -6493,24 +6493,24 @@ class Kt { return t; } modify(t, n, r) { - if (cl(this, t, n, r)) return; - const o = t === "move", i = le(), s = Je(Re(i)); + if (ll(this, t, n, r)) return; + const o = t === "move", i = le(), s = Ze(Me(i)); if (!s) return; const a = i._blockCursorElement, l = i._rootElement, u = this.focus.getNode(); - if (l === null || a === null || !R(u) || u.isInline() || u.canBeEmpty() || Fi(a, i, l), this.dirty) { + if (l === null || a === null || !R(u) || u.isInline() || u.canBeEmpty() || Li(a, i, l), this.dirty) { let d = hn(i, this.anchor.key), h = hn(i, this.focus.key); - this.anchor.type === "text" && (d = fn(d)), this.focus.type === "text" && (h = fn(h)), d && h && _d(s, d, this.anchor.offset, h, this.focus.offset); + this.anchor.type === "text" && (d = fn(d)), this.focus.type === "text" && (h = fn(h)), d && h && Sd(s, d, this.anchor.offset, h, this.focus.offset); } if ((function(d, h, f, p) { d.modify(h, f, p); })(s, t, n ? "backward" : "forward", r), s.rangeCount > 0) { - const d = s.getRangeAt(0), h = this.anchor.getNode(), f = Se(h) ? h : Px(h); + const d = s.getRangeAt(0), h = this.anchor.getNode(), f = Se(h) ? h : Ox(h); if (this.applyDOMRange(d), this.dirty = !0, !o) { const p = this.getNodes(), g = []; let m = !1; for (let y = 0; y < p.length; y++) { const x = p[y]; - Li(x, f) ? g.push(x) : m = !0; + Mi(x, f) ? g.push(x) : m = !0; } if (m && g.length > 0) if (n) { const y = g[0]; @@ -6525,7 +6525,7 @@ class Kt { })(this); } } - r === "lineboundary" && cl(this, t, n, r, "decorators"); + r === "lineboundary" && ll(this, t, n, r, "decorators"); } forwardDeletion(t, n, r) { if (!r && (t.type === "element" && R(n) && t.offset === n.getChildrenSize() || t.type === "text" && t.offset === n.getTextContentSize())) { @@ -6540,15 +6540,15 @@ class Kt { const r = this.anchor; let o = r.getNode(); if (this.forwardDeletion(r, o, t)) return; - const i = Us(vt(r, t ? "previous" : "next")); + const i = Bs(bt(r, t ? "previous" : "next")); if (i.getTextSlices().every(((a) => a === null || a.distance === 0))) { let a = { type: "initial" }; - for (const l of i.iterNodeCarets("shadowRoot")) if (Ye(l)) { + for (const l of i.iterNodeCarets("shadowRoot")) if (Qe(l)) { if (!l.origin.isInline()) { if (l.origin.isShadowRoot()) { if (a.type === "merge-block") break; if (R(i.anchor.origin) && i.anchor.origin.isEmpty()) { - const u = Xe(l); + const u = Ye(l); Jr(this, Vt(u, u)), i.anchor.origin.remove(); } return; @@ -6567,7 +6567,7 @@ class Kt { if (ne(l.origin)) { if (!l.origin.isIsolated()) if (a.type === "merge-next-block" && (l.origin.isKeyboardSelectable() || !l.origin.isInline()) && R(i.anchor.origin) && i.anchor.origin.isEmpty()) { i.anchor.origin.remove(); - const u = Sd(); + const u = wd(); u.add(l.origin.getKey()), De(u); } else l.origin.remove(); return; @@ -6577,27 +6577,27 @@ class Kt { } if (a.type === "merge-block") { const { caret: l, block: u } = a; - return Jr(this, Vt(!l.origin.isEmpty() && u.isEmpty() ? Hs(ke(u, l.direction)) : i.anchor, l)), this.removeText(); + return Jr(this, Vt(!l.origin.isEmpty() && u.isEmpty() ? Us(ke(u, l.direction)) : i.anchor, l)), this.removeText(); } } const s = this.focus; if (this.modify("extend", t, "character"), this.isCollapsed()) { - if (t && r.offset === 0 && rl(this, r.getNode())) return; + if (t && r.offset === 0 && nl(this, r.getNode())) return; } else { const a = s.type === "text" ? s.getNode() : null; if (o = r.type === "text" ? r.getNode() : null, a !== null && a.isSegmented()) { const l = s.offset, u = a.getTextContentSize(); - if (a.is(o) || t && l !== u || !t && l !== 0) return void ol(a, t, l); + if (a.is(o) || t && l !== u || !t && l !== 0) return void rl(a, t, l); } else if (o !== null && o.isSegmented()) { const l = r.offset, u = o.getTextContentSize(); - if (o.is(a) || t && l !== 0 || !t && l !== u) return void ol(o, t, l); + if (o.is(a) || t && l !== 0 || !t && l !== u) return void rl(o, t, l); } (function(l, u) { const d = l.anchor, h = l.focus, f = d.getNode(), p = h.getNode(); if (f === p && d.type === "text" && h.type === "text") { const g = d.offset, m = h.offset, y = g < m, x = y ? g : m, k = y ? m : g, v = k - 1; x !== v && (function(b) { - return !(Rd(b) || fx(b)); + return !(Nd(b) || dx(b)); })(f.getTextContent().slice(x, k)) && (u ? h.set(h.key, v, h.type) : d.set(d.key, v, d.type)); } })(this, t); @@ -6605,7 +6605,7 @@ class Kt { } if (this.removeText(), t && !n && this.isCollapsed() && this.anchor.type === "element" && this.anchor.offset === 0) { const r = this.anchor.getNode(); - r.isEmpty() && Se(r.getParent()) && r.getPreviousSibling() === null && rl(this, r); + r.isEmpty() && Se(r.getParent()) && r.getPreviousSibling() === null && nl(this, r); } } deleteLine(t) { @@ -6626,22 +6626,22 @@ class Kt { return [this.anchor, this.focus]; } } -function Es(e) { - return e instanceof Do; +function js(e) { + return e instanceof $o; } -function nl(e) { +function tl(e) { const t = e.offset; if (e.type === "text") return t; const n = e.getNode(); return t === n.getChildrenSize() ? n.getTextContent().length : 0; } -function Mi(e) { +function Ri(e) { const t = e.getStartEndPoints(); if (t === null) return [0, 0]; const [n, r] = t; - return n.type === "element" && r.type === "element" && n.key === r.key && n.offset === r.offset ? [0, 0] : [nl(n), nl(r)]; + return n.type === "element" && r.type === "element" && n.key === r.key && n.offset === r.offset ? [0, 0] : [tl(n), tl(r)]; } -function rl(e, t) { +function nl(e, t) { for (let n = t; n; n = n.getParent()) { if (R(n)) { if (n.collapseAtStart(e)) return !0; @@ -6651,7 +6651,7 @@ function rl(e, t) { } return !1; } -const fx = (() => { +const dx = (() => { try { const e = new RegExp("\\p{Emoji}", "u"), t = e.test.bind(e); if (t("❤️") && t("#️⃣") && t("👍")) return t; @@ -6659,7 +6659,7 @@ const fx = (() => { } return () => !1; })(); -function ol(e, t, n) { +function rl(e, t, n) { const r = e, o = r.getTextContent().split(/(?=\s)/g), i = o.length; let s = 0, a = 0; for (let u = 0; u < i; u++) { @@ -6672,7 +6672,7 @@ function ol(e, t, n) { const l = o.join("").trim(); l === "" ? r.remove() : (r.setTextContent(l), r.select(a, a)); } -function il(e, t, n, r) { +function ol(e, t, n, r) { let o, i = t; if (Te(e)) { let s = !1; @@ -6684,7 +6684,7 @@ function il(e, t, n, r) { const f = u.parentNode; e === f && t > Array.prototype.indexOf.call(f.children, u) && i--; } - if (o = en(d), F(o)) i = bl(o, s); + if (o = en(d), F(o)) i = vl(o, s); else { let f = en(e); if (f === null) return null; @@ -6699,17 +6699,17 @@ function il(e, t, n, r) { const y = s ? m.getLastDescendant() : m.getFirstDescendant(); y === null ? f = m : (m = y, f = R(m) ? m : m.getParentOrThrow()), i = 0; } - F(m) ? (o = m, f = null, i = bl(m, s)) : m !== f && s && !h && (R(f) || M(216), i = Math.min(f.getChildrenSize(), i + 1)); + F(m) ? (o = m, f = null, i = vl(m, s)) : m !== f && s && !h && (R(f) || M(216), i = Math.min(f.getChildrenSize(), i + 1)); } else { const p = f.getIndexWithinParent(); i = t === 0 && ne(f) && en(e) === f ? p : p + 1, f = f.getParentOrThrow(); } - if (R(f)) return Qe(f.__key, i, "element"); + if (R(f)) return Je(f.__key, i, "element"); } } else o = en(e); - return F(o) ? Qe(o.__key, i, "text") : null; + return F(o) ? Je(o.__key, i, "text") : null; } -function sl(e, t, n) { +function il(e, t, n) { const r = e.offset, o = e.getNode(); if (r === 0) { const i = o.getPreviousSibling(), s = o.getParent(); @@ -6728,10 +6728,10 @@ function sl(e, t, n) { } } } -function xd(e, t, n) { +function bd(e, t, n) { if (e.type === "text" && t.type === "text") { const r = e.isBefore(t), o = e.is(t); - sl(e, r, o), sl(t, !r, o), o && t.set(e.key, e.offset, e.type); + il(e, r, o), il(t, !r, o), o && t.set(e.key, e.offset, e.type); const i = le(); if (i.isComposing() && i._compositionKey !== e.key && L(n)) { const s = n.anchor, a = n.focus; @@ -6739,38 +6739,38 @@ function xd(e, t, n) { } } } -function kd(e, t, n, r, o, i) { - if (e === null || n === null || !No(o, e, n)) return null; - const s = il(e, t, L(i) ? i.anchor : null, o); +function xd(e, t, n, r, o, i) { + if (e === null || n === null || !Ao(o, e, n)) return null; + const s = ol(e, t, L(i) ? i.anchor : null, o); if (s === null) return null; - const a = il(n, r, L(i) ? i.focus : null, o); + const a = ol(n, r, L(i) ? i.focus : null, o); if (a === null) return null; if (s.type === "element" && a.type === "element") { const l = en(e), u = en(n); if (ne(l) && ne(u)) return null; } - return xd(s, a, i), [s, a]; + return bd(s, a, i), [s, a]; } -function wd(e, t, n, r, o, i) { - const s = Ct(), a = new Kt(Qe(e, t, o), Qe(n, r, i), 0, ""); +function kd(e, t, n, r, o, i) { + const s = Ct(), a = new Kt(Je(e, t, o), Je(n, r, i), 0, ""); return a.dirty = !0, s._selection = a, a; } -function hx() { - const e = Qe("root", 0, "element"), t = Qe("root", 0, "element"); +function fx() { + const e = Je("root", 0, "element"), t = Je("root", 0, "element"); return new Kt(e, t, 0, ""); } -function Sd() { - return new Do(/* @__PURE__ */ new Set()); +function wd() { + return new $o(/* @__PURE__ */ new Set()); } -function Ts(e, t, n, r) { +function Es(e, t, n, r) { const o = n._window; if (o === null) return null; - const i = r || o.event, s = i ? i.type : void 0, a = s === "selectionchange", l = !ki && (a || s === "beforeinput" || s === "compositionstart" || s === "compositionend" || s === "click" && i && i.detail === 3 || s === "drop" || s === void 0); + const i = r || o.event, s = i ? i.type : void 0, a = s === "selectionchange", l = !xi && (a || s === "beforeinput" || s === "compositionstart" || s === "compositionend" || s === "click" && i && i.detail === 3 || s === "drop" || s === void 0); let u, d, h, f; if (L(e) && !l) return e.clone(); if (t === null) return null; - if (u = t.anchorNode, d = t.focusNode, h = t.anchorOffset, f = t.focusOffset, a && L(e) && !No(n, u, d)) return e.clone(); - const p = kd(u, h, d, f, n, e); + if (u = t.anchorNode, d = t.focusNode, h = t.anchorOffset, f = t.focusOffset, a && L(e) && !Ao(n, u, d)) return e.clone(); + const p = xd(u, h, d, f, n, e); if (p === null) return null; const [g, m] = p; return new Kt(g, m, L(e) ? e.format : 0, L(e) ? e.style : ""); @@ -6781,7 +6781,7 @@ function H() { function ur() { return le()._editorState._selection; } -function ho(e, t, n, r = 1) { +function fo(e, t, n, r = 1) { const o = e.anchor, i = e.focus, s = o.getNode(), a = i.getNode(); if (!t.is(s) && !t.is(a)) return; const l = t.__key; @@ -6789,7 +6789,7 @@ function ho(e, t, n, r = 1) { const u = o.offset; if (n <= u && r > 0 || n < u && r < 0) { const d = Math.max(0, u + r); - o.set(l, d, "element"), i.set(l, d, "element"), al(e); + o.set(l, d, "element"), i.set(l, d, "element"), sl(e); } } else { const u = e.isBackward(), d = u ? i : o, h = d.getNode(), f = u ? o : i, p = f.getNode(); @@ -6802,9 +6802,9 @@ function ho(e, t, n, r = 1) { (n <= g && r > 0 || n < g && r < 0) && f.set(l, Math.max(0, g + r), "element"); } } - al(e); + sl(e); } -function al(e) { +function sl(e) { const t = e.anchor, n = t.offset, r = e.focus, o = r.offset, i = t.getNode(), s = r.getNode(); if (e.isCollapsed()) { if (!R(i)) return; @@ -6830,23 +6830,23 @@ function al(e) { } } } -function po(e, t, n, r, o) { +function ho(e, t, n, r, o) { let i = null, s = 0, a = null; r !== null ? (i = r.__key, F(r) ? (s = r.getTextContentSize(), a = "text") : R(r) && (s = r.getChildrenSize(), a = "element")) : o !== null && (i = o.__key, F(o) ? a = "text" : R(o) && (a = "element")), i !== null && a !== null ? e.set(i, s, a) : (s = t.getIndexWithinParent(), s === -1 && (s = n.getChildrenSize()), e.set(n.__key, s, "element")); } -function ll(e, t, n, r, o) { +function al(e, t, n, r, o) { e.type === "text" ? e.set(n, e.offset + (t ? 0 : o), "text") : e.offset > r.getIndexWithinParent() && e.set(e.key, e.offset - 1, "element"); } -function _d(e, t, n, r, o) { +function Sd(e, t, n, r, o) { try { e.setBaseAndExtent(t, n, r, o); } catch { } } -function px(e, t, n, r, o, i, s) { +function hx(e, t, n, r, o, i, s) { const a = r.anchorNode, l = r.focusNode, u = r.anchorOffset, d = r.focusOffset, h = document.activeElement; - if (o.has("collaboration") && h !== i || h !== null && Dd(h)) return; - if (!L(t)) return void (e !== null && No(n, a, l) && r.removeAllRanges()); + if (o.has("collaboration") && h !== i || h !== null && $d(h)) return; + if (!L(t)) return void (e !== null && Ao(n, a, l) && r.removeAllRanges()); const f = t.anchor, p = t.focus, g = f.key, m = p.key, y = hn(n, g), x = hn(n, m), k = f.offset, v = p.offset, b = t.format, j = t.style, _ = t.isCollapsed(); let S = y, P = x, D = !1; if (f.type === "text") { @@ -6855,8 +6855,8 @@ function px(e, t, n, r, o, i, s) { D = N.getFormat() !== b || N.getStyle() !== j; } else L(e) && e.anchor.type === "text" && (D = !0); var $, C, T, O, I; - if (p.type === "text" && (P = fn(x)), S !== null && P !== null && (_ && (e === null || D || L(e) && (e.format !== b || e.style !== j)) && ($ = b, C = j, T = k, O = g, I = performance.now(), fd = [$, C, T, O, I]), u !== k || d !== v || a !== S || l !== P || r.type === "Range" && _ || (h !== null && i.contains(h) || i.focus({ preventScroll: !0 }), f.type === "element"))) { - if (_d(r, S, k, P, v), !o.has("skip-scroll-into-view") && t.isCollapsed() && i !== null && i === document.activeElement) { + if (p.type === "text" && (P = fn(x)), S !== null && P !== null && (_ && (e === null || D || L(e) && (e.format !== b || e.style !== j)) && ($ = b, C = j, T = k, O = g, I = performance.now(), dd = [$, C, T, O, I]), u !== k || d !== v || a !== S || l !== P || r.type === "Range" && _ || (h !== null && i.contains(h) || i.focus({ preventScroll: !0 }), f.type === "element"))) { + if (Sd(r, S, k, P, v), !o.has("skip-scroll-into-view") && t.isCollapsed() && i !== null && i === document.activeElement) { const N = L(t) && t.anchor.type === "element" ? S.childNodes[k] || null : r.rangeCount > 0 ? r.getRangeAt(0) : null; if (N !== null) { let U; @@ -6865,23 +6865,23 @@ function px(e, t, n, r, o, i, s) { V.selectNode(N), U = V.getBoundingClientRect(); } else U = N.getBoundingClientRect(); (function(V, q, J) { - const X = qd(J), re = Ms(X); + const X = Fd(J), re = Rs(X); if (X === null || re === null) return; - let { top: ve, bottom: et } = q, ge = 0, Oe = 0, Y = J; + let { top: ve, bottom: tt } = q, ge = 0, Oe = 0, Y = J; for (; Y !== null; ) { const G = Y === X.body; - if (G) ge = 0, Oe = Re(V).innerHeight; + if (G) ge = 0, Oe = Me(V).innerHeight; else { const ue = Y.getBoundingClientRect(); ge = ue.top, Oe = ue.bottom; } let ee = 0; - if (ve < ge ? ee = -(ge - ve) : et > Oe && (ee = et - Oe), ee !== 0) if (G) re.scrollBy(0, ee); + if (ve < ge ? ee = -(ge - ve) : tt > Oe && (ee = tt - Oe), ee !== 0) if (G) re.scrollBy(0, ee); else { const ue = Y.scrollTop; Y.scrollTop += ee; - const Ve = Y.scrollTop - ue; - ve -= Ve, et -= Ve; + const We = Y.scrollTop - ue; + ve -= We, tt -= We; } if (G) break; Y = pr(Y); @@ -6889,23 +6889,23 @@ function px(e, t, n, r, o, i, s) { })(n, U, i); } } - Ai = !0; + Ii = !0; } } -function ai(e) { +function si(e) { let t = e; e.isCollapsed() || t.removeText(); const n = H(); L(n) && (t = n), L(t) || M(161); const r = t.anchor; let o = r.getNode(), i = r.offset; - for (; !dt(o); ) { + for (; !ft(o); ) { const s = o; - if ([o, i] = gx(o, i), s.is(o)) break; + if ([o, i] = px(o, i), s.is(o)) break; } return i; } -function gx(e, t) { +function px(e, t) { const n = e.getParent(); if (!n) { const o = Ne(); @@ -6920,26 +6920,26 @@ function gx(e, t) { if (!R(e) || t === 0) return [n, e.getIndexWithinParent()]; const r = e.getChildAtIndex(t); if (r) { - const o = new Kt(Qe(e.__key, t, "element"), Qe(e.__key, t, "element"), 0, ""), i = e.insertNewAfter(o); + const o = new Kt(Je(e.__key, t, "element"), Je(e.__key, t, "element"), 0, ""), i = e.insertNewAfter(o); i && i.append(r, ...r.getNextSiblings()); } return [n, e.getIndexWithinParent() + 1]; } -function cl(e, t, n, r, o = "decorators-and-blocks") { +function ll(e, t, n, r, o = "decorators-and-blocks") { if (t === "move" && r === "character" && !e.isCollapsed()) { const [d, h] = n === e.isBackward() ? [e.focus, e.anchor] : [e.anchor, e.focus]; return h.set(d.key, d.offset, d.type), !0; } - const i = vt(e.focus, n ? "previous" : "next"), s = r === "lineboundary", a = t === "move"; + const i = bt(e.focus, n ? "previous" : "next"), s = r === "lineboundary", a = t === "move"; let l = i, u = o === "decorators-and-blocks"; - if (!Wd(l)) { + if (!Vd(l)) { for (const d of l) { u = !1; const { origin: h } = d; if (!ne(h) || h.isIsolated() || (l = d, !s || !h.isInline())) break; } - if (u) for (const d of Us(i).iterNodeCarets(t === "extend" ? "shadowRoot" : "root")) { - if (Ye(d)) d.origin.isInline() || (l = d); + if (u) for (const d of Bs(i).iterNodeCarets(t === "extend" ? "shadowRoot" : "root")) { + if (Qe(d)) d.origin.isInline() || (l = d); else { if (R(d.origin)) continue; ne(d.origin) && !d.origin.isInline() && (l = d); @@ -6949,34 +6949,34 @@ function cl(e, t, n, r, o = "decorators-and-blocks") { } if (l === i) return !1; if (a && !s && ne(l.origin) && l.origin.isKeyboardSelectable()) { - const d = Sd(); + const d = wd(); return d.add(l.origin.getKey()), De(d), !0; } - return l = Xe(l), a && ir(e.anchor, l), ir(e.focus, l), u || !s; + return l = Ye(l), a && ir(e.anchor, l), ir(e.focus, l), u || !s; } -let he = null, pe = null, je = !1, li = !1, Yr = 0; -const ul = { characterData: !0, childList: !0, subtree: !0 }; +let he = null, pe = null, je = !1, ai = !1, Yr = 0; +const cl = { characterData: !0, childList: !0, subtree: !0 }; function dr() { return je || he !== null && he._readOnly; } function be() { je && M(13); } -function Cd() { +function _d() { Yr > 99 && M(14); } function Ct() { - return he === null && M(195, jd()), he; + return he === null && M(195, Cd()), he; } function le() { - return pe === null && M(196, jd()), pe; + return pe === null && M(196, Cd()), pe; } -function jd() { +function Cd() { let e = 0; - const t = /* @__PURE__ */ new Set(), n = Ao.version; + const t = /* @__PURE__ */ new Set(), n = Io.version; if (typeof window < "u") for (const o of document.querySelectorAll("[contenteditable]")) { - const i = Ro(o); - if (Ds(i)) e++; + const i = No(o); + if ($s(i)) e++; else if (i) { let s = String(i.constructor.version || "<0.17.1"); s === n && (s += " (separately built, likely a bundler configuration issue)"), t.add(s); @@ -6985,10 +6985,10 @@ function jd() { let r = ` Detected on the page: ${e} compatible editor(s) with version ${n}`; return t.size && (r += ` and incompatible editors with versions ${Array.from(t).join(", ")}`), r; } -function mx() { +function gx() { return pe; } -function dl(e, t, n) { +function ul(e, t, n) { const r = t.__type, o = (function(a, l) { const u = a._nodes.get(l); return u === void 0 && M(30, l), u; @@ -6998,29 +6998,29 @@ function dl(e, t, n) { const s = i.length; for (let a = 0; a < s && (i[a](t), t.isAttached()); a++) ; } -function fl(e, t) { +function dl(e, t) { return e !== void 0 && e.__key !== t && e.isAttached(); } -function Ed(e, t) { +function jd(e, t) { if (!t) return; const n = e._updateTags; let r = t; Array.isArray(t) || (r = [t]); for (const o of r) n.add(o); } -function Td(e, t) { +function Ed(e, t) { const n = e.type, r = t.get(n); r === void 0 && M(17, n); const o = r.klass; e.type !== o.getType() && M(18, o.name); const i = o.importJSON(e), s = e.children; if (R(i) && Array.isArray(s)) for (let a = 0; a < s.length; a++) { - const l = Td(s[a], t); + const l = Ed(s[a], t); i.append(l); } return i; } -function hl(e, t, n) { +function fl(e, t, n) { const r = he, o = je, i = pe; he = t, je = !0, pe = e; try { @@ -7029,7 +7029,7 @@ function hl(e, t, n) { he = r, je = o, pe = i; } } -function it(e, t) { +function st(e, t) { const n = e._pendingEditorState, r = e._rootElement, o = e._headless || r === null; if (n === null) return; const i = e._editorState, s = i._selection, a = n._selection, l = e._dirtyType !== Mt, u = he, d = je, h = pe, f = e._updating, p = e._observer; @@ -7038,12 +7038,12 @@ function it(e, t) { pe = e, he = n, je = !1, e._updating = !0; try { const _ = e._dirtyType, S = e._dirtyElements, P = e._dirtyLeaves; - p.disconnect(), g = Hb(i, n, e, _, S, P); + p.disconnect(), g = Ub(i, n, e, _, S, P); } catch (_) { - if (_ instanceof Error && e._onError(_), li) throw _; - return $d(e, null, r, n), Wu(e), e._dirtyType = dn, li = !0, it(e, i), void (li = !1); + if (_ instanceof Error && e._onError(_), ai) throw _; + return Pd(e, null, r, n), Vu(e), e._dirtyType = dn, ai = !0, st(e, i), void (ai = !1); } finally { - p.observe(r, ul), e._updating = f, he = u, je = d, pe = h; + p.observe(r, cl), e._updating = f, he = u, je = d, pe = h; } } n._readOnly || (n._readOnly = !0); @@ -7053,15 +7053,15 @@ function it(e, t) { let D = _._pendingDecorators || P; const $ = S._nodeMap; let C; - for (C in D) $.has(C) || (D === P && (D = Ad(_)), delete D[C]); + for (C in D) $.has(C) || (D === P && (D = Id(_)), delete D[C]); })(e, n); - const b = o ? null : Je(Re(e)); + const b = o ? null : Ze(Me(e)); if (e._editable && b !== null && (l || a === null || a.dirty) && r !== null && !k.has("skip-dom-selection")) { pe = e, he = n; try { if (p !== null && p.disconnect(), l || a === null || a.dirty) { const _ = e._blockCursorElement; - _ !== null && Fi(_, e, r), px(s, a, e, b, k, r); + _ !== null && Li(_, e, r), hx(s, a, e, b, k, r); } (function(_, S, P) { let D = _._blockCursorElement; @@ -7069,12 +7069,12 @@ function it(e, t) { const $ = P.anchor, C = $.getNode(), T = $.offset; let O = !1, I = null; if (T === C.getChildrenSize()) - ui(C.getChildAtIndex(T - 1)) && (O = !0); + ci(C.getChildAtIndex(T - 1)) && (O = !0); else { const N = C.getChildAtIndex(T); - if (N !== null && ui(N)) { + if (N !== null && ci(N)) { const U = N.getPreviousSibling(); - (U === null || ui(U)) && (O = !0, I = _.getElementByKey(N.__key)); + (U === null || ci(U)) && (O = !0, I = _.getElementByKey(N.__key)); } } if (O) { @@ -7085,7 +7085,7 @@ function it(e, t) { let J = V.blockCursor; if (J !== void 0) { if (typeof J == "string") { - const X = io(J); + const X = oo(J); J = V.blockCursor = X; } J !== void 0 && q.classList.add(...J); @@ -7094,10 +7094,10 @@ function it(e, t) { })(_._config)), S.style.caretColor = "transparent", void (I === null ? N.appendChild(D) : N.insertBefore(D, I)); } } - D !== null && Fi(D, _, S); + D !== null && Li(D, _, S); })(e, r, a); } finally { - p !== null && p.observe(r, ul), pe = h, he = u; + p !== null && p.observe(r, cl), pe = h, he = u; } } g !== null && (function(_, S, P, D, $) { @@ -7106,10 +7106,10 @@ function it(e, t) { const [I, N] = C[O], U = S.get(N); U !== void 0 && I(U, { dirtyLeaves: D, prevEditorState: $, updateTags: P }); } - })(e, g, k, m, i), L(a) || a === null || s !== null && s.is(a) || e.dispatchCommand(Zu, void 0); + })(e, g, k, m, i), L(a) || a === null || s !== null && s.is(a) || e.dispatchCommand(Ju, void 0); const j = e._pendingDecorators; j !== null && (e._decorators = j, e._pendingDecorators = null, Kn("decorator", e, !0, j)), (function(_, S, P) { - const D = vl(S), $ = vl(P); + const D = yl(S), $ = yl(P); D !== $ && Kn("textcontent", _, !0, $); })(e, t || i, n), Kn("update", e, !0, { dirtyElements: y, dirtyLeaves: m, editorState: n, mutatedNodes: g, normalizedNodes: x, prevEditorState: t || i, tags: k }), (function(_, S) { if (_._deferred = [], S.length !== 0) { @@ -7127,7 +7127,7 @@ function it(e, t) { const P = S.shift(); if (P) { const [D, $] = P; - Os(_, D, $); + Ts(_, D, $); } } })(e); @@ -7142,7 +7142,7 @@ function Kn(e, t, n, ...r) { t._updating = o; } } -function pl(e, t) { +function hl(e, t) { const n = e._updates; let r = t || !1; for (; n.length !== 0; ) { @@ -7155,30 +7155,30 @@ function pl(e, t) { const l = e._pendingEditorState; l === null && M(191), l._flushSync = !0; } - a && e._deferred.push(a), Ed(e, s.tag); + a && e._deferred.push(a), jd(e, s.tag); } i(); } } return r; } -function Os(e, t, n) { +function Ts(e, t, n) { const r = e._updateTags; let o, i = !1, s = !1; - n !== void 0 && (o = n.onUpdate, Ed(e, n.tag), i = n.skipTransforms || !1, s = n.discrete || !1), o && e._deferred.push(o); + n !== void 0 && (o = n.onUpdate, jd(e, n.tag), i = n.skipTransforms || !1, s = n.discrete || !1), o && e._deferred.push(o); const a = e._editorState; let l = e._pendingEditorState, u = !1; - (l === null || l._readOnly) && (l = e._pendingEditorState = Od(l || a), u = !0), l._flushSync = s; + (l === null || l._readOnly) && (l = e._pendingEditorState = Td(l || a), u = !0), l._flushSync = s; const d = he, h = je, f = pe, p = e._updating; he = l, je = !1, e._updating = !0, pe = e; const g = e._headless || e.getRootElement() === null; try { u && (g ? a._selection !== null && (l._selection = a._selection.clone()) : l._selection = (function(k, v) { - const b = k.getEditorState()._selection, j = Je(Re(k)); - return L(b) || b == null ? Ts(b, j, k, v) : b.clone(); + const b = k.getEditorState()._selection, j = Ze(Me(k)); + return L(b) || b == null ? Es(b, j, k, v) : b.clone(); })(e, n && n.event || null)); const y = e._compositionKey; - t(), i = pl(e, i), (function(k, v) { + t(), i = hl(e, i), (function(k, v) { const b = v.getEditorState()._selection, j = k._selection; if (L(j)) { const _ = j.anchor, S = j.focus; @@ -7192,17 +7192,17 @@ function Os(e, t, n) { const b = v._dirtyLeaves, j = k._nodeMap; for (const _ of b) { const S = j.get(_); - F(S) && S.isAttached() && S.isSimpleText() && !S.isUnmergeable() && Va(S); + F(S) && S.isAttached() && S.isSimpleText() && !S.isUnmergeable() && Ha(S); } })(l, e) : (function(k, v) { - const b = v._dirtyLeaves, j = v._dirtyElements, _ = k._nodeMap, S = ft(), P = /* @__PURE__ */ new Map(); + const b = v._dirtyLeaves, j = v._dirtyElements, _ = k._nodeMap, S = ht(), P = /* @__PURE__ */ new Map(); let D = b, $ = D.size, C = j, T = C.size; for (; $ > 0 || T > 0; ) { if ($ > 0) { v._dirtyLeaves = /* @__PURE__ */ new Set(); for (const O of D) { const I = _.get(O); - F(I) && I.isAttached() && I.isSimpleText() && !I.isUnmergeable() && Va(I), I !== void 0 && fl(I, S) && dl(v, I, P), b.add(O); + F(I) && I.isAttached() && I.isSimpleText() && !I.isUnmergeable() && Ha(I), I !== void 0 && dl(I, S) && ul(v, I, P), b.add(O); } if (D = v._dirtyLeaves, $ = D.size, $ > 0) { Yr++; @@ -7214,16 +7214,16 @@ function Os(e, t, n) { const I = O[0], N = O[1]; if (j.set(I, N), !N) continue; const U = _.get(I); - U !== void 0 && fl(U, S) && dl(v, U, P); + U !== void 0 && dl(U, S) && ul(v, U, P); } D = v._dirtyLeaves, $ = D.size, C = v._dirtyElements, T = C.size, Yr++; } v._dirtyLeaves = b, v._dirtyElements = j; - })(l, e), pl(e), (function(k, v, b, j) { + })(l, e), hl(e), (function(k, v, b, j) { const _ = k._nodeMap, S = v._nodeMap, P = []; for (const [D] of j) { const $ = S.get(D); - $ !== void 0 && ($.isAttached() || (R($) && Uu($, D, _, S, P, j), _.has(D) || j.delete(D), P.push(D))); + $ !== void 0 && ($.isAttached() || (R($) && Bu($, D, _, S, P, j), _.has(D) || j.delete(D), P.push(D))); } for (const D of P) S.delete(D); for (const D of b) { @@ -7235,9 +7235,9 @@ function Os(e, t, n) { if (L(x)) { const k = l._nodeMap, v = x.anchor.key, b = x.focus.key; k.get(v) !== void 0 && k.get(b) !== void 0 || M(19); - } else Es(x) && x._nodes.size === 0 && (l._selection = null); + } else js(x) && x._nodes.size === 0 && (l._selection = null); } catch (y) { - return y instanceof Error && e._onError(y), e._pendingEditorState = a, e._dirtyType = dn, e._cloneNotNeeded.clear(), e._dirtyLeaves = /* @__PURE__ */ new Set(), e._dirtyElements.clear(), void it(e); + return y instanceof Error && e._onError(y), e._pendingEditorState = a, e._dirtyType = dn, e._cloneNotNeeded.clear(), e._dirtyLeaves = /* @__PURE__ */ new Set(), e._dirtyElements.clear(), void st(e); } finally { he = d, je = h, pe = f, e._updating = p, Yr = 0; } @@ -7247,12 +7247,12 @@ function Os(e, t, n) { if (v.dirty || !v.is(k)) return !0; } else if (k !== null) return !0; return !1; - })(l, e) ? l._flushSync ? (l._flushSync = !1, it(e)) : u && Sx((() => { - it(e); + })(l, e) ? l._flushSync ? (l._flushSync = !1, st(e)) : u && wx((() => { + st(e); })) : (l._flushSync = !1, u && (r.clear(), e._deferred = [], e._pendingEditorState = null)); } function $e(e, t, n) { - pe === e && n === void 0 ? t() : Os(e, t, n); + pe === e && n === void 0 ? t() : Ts(e, t, n); } class Gn { constructor(t, n, r) { @@ -7320,9 +7320,9 @@ class Gn { const l = this.getFirstChildOffset(); return [t, Math.min(l + t.getChildrenSize(), Math.max(l, o))]; } - const i = gl(n, r); + const i = pl(n, r); i.push(o); - const s = gl(n, this.element); + const s = pl(n, this.element); let a = t.getIndexWithinParent(); for (let l = 0; l < s.length; l++) { const u = i[l], d = s[l]; @@ -7335,7 +7335,7 @@ class Gn { return [t.getParentOrThrow(), a]; } } -function gl(e, t) { +function pl(e, t) { const n = []; let r = t; for (; r !== e && r !== null; r = t.parentNode) { @@ -7345,7 +7345,7 @@ function gl(e, t) { } return r !== e && M(225), n.reverse(); } -class zo extends $o { +class Do extends Po { constructor(t) { super(t), this.__first = null, this.__last = null, this.__size = 0, this.__format = 0, this.__style = "", this.__indent = 0, this.__dir = null, this.__textFormat = 0, this.__textStyle = ""; } @@ -7357,7 +7357,7 @@ class zo extends $o { } getFormatType() { const t = this.getFormat(); - return Db[t] || ""; + return $b[t] || ""; } getStyle() { return this.getLatest().__style; @@ -7467,7 +7467,7 @@ class zo extends $o { const n = this.getChildren(), r = n.length; for (let o = 0; o < r; o++) { const i = n[o]; - t += i.getTextContent(), R(i) && o !== r - 1 && !i.isInline() && (t += st); + t += i.getTextContent(), R(i) && o !== r - 1 && !i.isInline() && (t += at); } return t; } @@ -7476,7 +7476,7 @@ class zo extends $o { const n = this.getChildren(), r = n.length; for (let o = 0; o < r; o++) { const i = n[o]; - t += i.getTextContentSize(), R(i) && o !== r - 1 && !i.isInline() && (t += st.length); + t += i.getTextContentSize(), R(i) && o !== r - 1 && !i.isInline() && (t += at.length); } return t; } @@ -7488,7 +7488,7 @@ class zo extends $o { } hasFormat(t) { if (t !== "") { - const n = Ba[t]; + const n = qa[t]; return !!(this.getFormat() & n); } return !1; @@ -7498,7 +7498,7 @@ class zo extends $o { return !!(this.getTextFormat() & n); } getFormatFlags(t, n) { - return go(this.getLatest().__textFormat, t, n); + return po(this.getLatest().__textFormat, t, n); } getTextStyle() { return this.getLatest().__textStyle; @@ -7519,7 +7519,7 @@ class zo extends $o { } o === void 0 && (o = s), i === void 0 && (i = s); const a = this.__key; - return L(r) ? (r.anchor.set(a, o, "element"), r.focus.set(a, i, "element"), r.dirty = !0, r) : wd(a, o, a, i, "element", "element"); + return L(r) ? (r.anchor.set(a, o, "element"), r.focus.set(a, i, "element"), r.dirty = !0, r) : kd(a, o, a, i, "element", "element"); } selectStart() { const t = this.getFirstDescendant(); @@ -7541,7 +7541,7 @@ class zo extends $o { return n.__dir = t, n; } setFormat(t) { - return this.getWritable().__format = t !== "" ? Ba[t] : 0, this; + return this.getWritable().__format = t !== "" ? qa[t] : 0, this; } setStyle(t) { return this.getWritable().__style = t || "", this; @@ -7602,7 +7602,7 @@ class zo extends $o { const g = H(); if (L(g)) { const m = new Set(u), y = new Set(l), { anchor: x, focus: k } = g; - ml(x, m, y) && po(x, x.getNode(), this, h, d), ml(k, m, y) && po(k, k.getNode(), this, h, d), f !== 0 || this.canBeEmpty() || jt(this) || this.remove(); + gl(x, m, y) && ho(x, x.getNode(), this, h, d), gl(k, m, y) && ho(k, k.getNode(), this, h, d), f !== 0 || this.canBeEmpty() || jt(this) || this.remove(); } } return s; @@ -7679,9 +7679,9 @@ class zo extends $o { } } function R(e) { - return e instanceof zo; + return e instanceof Do; } -function ml(e, t, n) { +function gl(e, t, n) { let r = e.getNode(); for (; r; ) { const o = r.__key; @@ -7690,7 +7690,7 @@ function ml(e, t, n) { } return !1; } -class yx extends $o { +class mx extends Po { decorate(t, n) { M(47); } @@ -7705,9 +7705,9 @@ class yx extends $o { } } function ne(e) { - return e instanceof yx; + return e instanceof mx; } -class fr extends zo { +class fr extends Do { static getType() { return "root"; } @@ -7753,26 +7753,26 @@ class fr extends zo { function Se(e) { return e instanceof fr; } -function Od(e) { - return new Io(new Map(e._nodeMap)); +function Td(e) { + return new zo(new Map(e._nodeMap)); } -function Ps() { - return new Io(/* @__PURE__ */ new Map([["root", new fr()]])); +function Os() { + return new zo(/* @__PURE__ */ new Map([["root", new fr()]])); } -function Pd(e) { +function Od(e) { const t = e.exportJSON(), n = e.constructor; if (t.type !== n.getType() && M(130, n.name), R(e)) { const r = t.children; Array.isArray(r) || M(59, n.name); const o = e.getChildren(); for (let i = 0; i < o.length; i++) { - const s = Pd(o[i]); + const s = Od(o[i]); r.push(s); } } return t; } -class Io { +class zo { constructor(t, n) { this._nodeMap = t, this._selection = n || null, this._flushSync = !1, this._readOnly = !1; } @@ -7780,17 +7780,17 @@ class Io { return this._nodeMap.size === 1 && this._selection === null; } read(t, n) { - return hl(n && n.editor || null, this, t); + return fl(n && n.editor || null, this, t); } clone(t) { - const n = new Io(this._nodeMap, t === void 0 ? this._selection : t); + const n = new zo(this._nodeMap, t === void 0 ? this._selection : t); return n._readOnly = !0, n; } toJSON() { - return hl(null, this, (() => ({ root: Pd(ce()) }))); + return fl(null, this, (() => ({ root: Od(ce()) }))); } } -class vx extends zo { +class yx extends Do { static getType() { return "artificial"; } @@ -7798,7 +7798,7 @@ class vx extends zo { return document.createElement("div"); } } -class hr extends zo { +class hr extends Do { static getType() { return "paragraph"; } @@ -7813,7 +7813,7 @@ class hr extends zo { return !1; } static importDOM() { - return { p: (t) => ({ conversion: bx, priority: 0 }) }; + return { p: (t) => ({ conversion: vx, priority: 0 }) }; } exportDOM(t) { const { element: n } = super.exportDOM(t); @@ -7845,25 +7845,25 @@ class hr extends zo { return !1; } } -function bx(e) { +function vx(e) { const t = Ne(); - return e.style && (t.setFormat(e.style.textAlign), Ax(e, t)), { node: t }; + return e.style && (t.setFormat(e.style.textAlign), Ix(e, t)), { node: t }; } function Ne() { - return Fo(new hr()); + return Lo(new hr()); } -function xx(e) { +function bx(e) { return e instanceof hr; } -const oe = 0, $s = 1; -function $d(e, t, n, r) { +const oe = 0, Ps = 1; +function Pd(e, t, n, r) { const o = e._keyToDOMMap; - o.clear(), e._editorState = Ps(), e._pendingEditorState = r, e._compositionKey = null, e._dirtyType = Mt, e._cloneNotNeeded.clear(), e._dirtyLeaves = /* @__PURE__ */ new Set(), e._dirtyElements.clear(), e._normalizedNodes = /* @__PURE__ */ new Set(), e._updateTags = /* @__PURE__ */ new Set(), e._updates = [], e._blockCursorElement = null; + o.clear(), e._editorState = Os(), e._pendingEditorState = r, e._compositionKey = null, e._dirtyType = Mt, e._cloneNotNeeded.clear(), e._dirtyLeaves = /* @__PURE__ */ new Set(), e._dirtyElements.clear(), e._normalizedNodes = /* @__PURE__ */ new Set(), e._updateTags = /* @__PURE__ */ new Set(), e._updates = [], e._blockCursorElement = null; const i = e._observer; i !== null && (i.disconnect(), e._observer = null), t !== null && (t.textContent = ""), n !== null && (n.textContent = "", o.set("root", n)); } -function kx(e) { - const t = e || {}, n = mx(), r = t.theme || {}, o = e === void 0 ? n : t.parentEditor || null, i = t.disableEvents || !1, s = Ps(), a = t.namespace || (o !== null ? o._config.namespace : Md()), l = t.editorState, u = [fr, _t, jn, cr, hr, vx, ...t.nodes || []], { onError: d, html: h } = t, f = t.editable === void 0 || t.editable; +function xx(e) { + const t = e || {}, n = gx(), r = t.theme || {}, o = e === void 0 ? n : t.parentEditor || null, i = t.disableEvents || !1, s = Os(), a = t.namespace || (o !== null ? o._config.namespace : Rd()), l = t.editorState, u = [fr, _t, jn, cr, hr, yx, ...t.nodes || []], { onError: d, html: h } = t, f = t.editable === void 0 || t.editable; let p; if (e === void 0 && n !== null) p = n._nodes; else { @@ -7878,7 +7878,7 @@ function kx(e) { b !== null && j.add(b), p.set(v, { exportDOM: h && h.export ? h.export.get(y) : void 0, klass: y, replace: x, replaceWithKlass: k, transforms: j }); } } - const g = new Ao(s, o, p, { disableEvents: i, namespace: a, theme: r }, d || console.error, (function(m, y) { + const g = new Io(s, o, p, { disableEvents: i, namespace: a, theme: r }, d || console.error, (function(m, y) { const x = /* @__PURE__ */ new Map(), k = /* @__PURE__ */ new Set(), v = (b) => { Object.keys(b).forEach(((j) => { let _ = x.get(j); @@ -7895,9 +7895,9 @@ function kx(e) { })(p, h ? h.import : void 0), f, e); return l !== void 0 && (g._pendingEditorState = l, g._dirtyType = dn), g; } -class Ao { +class Io { constructor(t, n, r, o, i, s, a, l) { - this._createEditorArgs = l, this._parentEditor = n, this._rootElement = null, this._editorState = t, this._pendingEditorState = null, this._compositionKey = null, this._deferred = [], this._keyToDOMMap = /* @__PURE__ */ new Map(), this._updates = [], this._updating = !1, this._listeners = { decorator: /* @__PURE__ */ new Set(), editable: /* @__PURE__ */ new Set(), mutation: /* @__PURE__ */ new Map(), root: /* @__PURE__ */ new Set(), textcontent: /* @__PURE__ */ new Set(), update: /* @__PURE__ */ new Set() }, this._commands = /* @__PURE__ */ new Map(), this._config = o, this._nodes = r, this._decorators = {}, this._pendingDecorators = null, this._dirtyType = Mt, this._cloneNotNeeded = /* @__PURE__ */ new Set(), this._dirtyLeaves = /* @__PURE__ */ new Set(), this._dirtyElements = /* @__PURE__ */ new Map(), this._normalizedNodes = /* @__PURE__ */ new Set(), this._updateTags = /* @__PURE__ */ new Set(), this._observer = null, this._key = Md(), this._onError = i, this._htmlConversions = s, this._editable = a, this._headless = n !== null && n._headless, this._window = null, this._blockCursorElement = null; + this._createEditorArgs = l, this._parentEditor = n, this._rootElement = null, this._editorState = t, this._pendingEditorState = null, this._compositionKey = null, this._deferred = [], this._keyToDOMMap = /* @__PURE__ */ new Map(), this._updates = [], this._updating = !1, this._listeners = { decorator: /* @__PURE__ */ new Set(), editable: /* @__PURE__ */ new Set(), mutation: /* @__PURE__ */ new Map(), root: /* @__PURE__ */ new Set(), textcontent: /* @__PURE__ */ new Set(), update: /* @__PURE__ */ new Set() }, this._commands = /* @__PURE__ */ new Map(), this._config = o, this._nodes = r, this._decorators = {}, this._pendingDecorators = null, this._dirtyType = Mt, this._cloneNotNeeded = /* @__PURE__ */ new Set(), this._dirtyLeaves = /* @__PURE__ */ new Set(), this._dirtyElements = /* @__PURE__ */ new Map(), this._normalizedNodes = /* @__PURE__ */ new Set(), this._updateTags = /* @__PURE__ */ new Set(), this._observer = null, this._key = Rd(), this._onError = i, this._htmlConversions = s, this._editable = a, this._headless = n !== null && n._headless, this._window = null, this._blockCursorElement = null; } isComposing() { return this._compositionKey != null; @@ -7960,7 +7960,7 @@ class Ao { return t; } initializeMutationListener(t, n) { - const r = this._editorState, o = El(r).get(n.getType()); + const r = this._editorState, o = jl(r).get(n.getType()); if (!o) return; const i = /* @__PURE__ */ new Map(); for (const s of o.keys()) i.set(s, "created"); @@ -7977,7 +7977,7 @@ class Ao { o.push(s); } return (function(s, a) { - const l = El(s.getEditorState()), u = []; + const l = jl(s.getEditorState()), u = []; for (const d of a) { const h = l.get(d); h && u.push(h); @@ -8014,38 +8014,38 @@ class Ao { const n = this._rootElement; if (t !== n) { const r = sn(this._config.theme, "root"), o = this._pendingEditorState || this._editorState; - if (this._rootElement = t, $d(this, n, t, o), n !== null && (this._config.disableEvents || rx(n), r != null && n.classList.remove(...r)), t !== null) { - const i = Ms(t), s = t.style; - s.userSelect = "text", s.whiteSpace = "pre-wrap", s.wordBreak = "break-word", t.setAttribute("data-lexical-editor", "true"), this._window = i, this._dirtyType = dn, Wu(this), this._updateTags.add("history-merge"), it(this), this._config.disableEvents || (function(a, l) { - const u = a.ownerDocument, d = fo.get(u); - (d === void 0 || d < 1) && u.addEventListener("selectionchange", yd), fo.set(u, (d || 0) + 1), a.__lexicalEditor = l; - const h = md(a); - for (let f = 0; f < zi.length; f++) { - const [p, g] = zi[f], m = typeof g == "function" ? (y) => { - Qa(y) || (Ya(y), (l.isEditable() || p === "click") && g(y, l)); + if (this._rootElement = t, Pd(this, n, t, o), n !== null && (this._config.disableEvents || nx(n), r != null && n.classList.remove(...r)), t !== null) { + const i = Rs(t), s = t.style; + s.userSelect = "text", s.whiteSpace = "pre-wrap", s.wordBreak = "break-word", t.setAttribute("data-lexical-editor", "true"), this._window = i, this._dirtyType = dn, Vu(this), this._updateTags.add("history-merge"), st(this), this._config.disableEvents || (function(a, l) { + const u = a.ownerDocument, d = uo.get(u); + (d === void 0 || d < 1) && u.addEventListener("selectionchange", md), uo.set(u, (d || 0) + 1), a.__lexicalEditor = l; + const h = gd(a); + for (let f = 0; f < Di.length; f++) { + const [p, g] = Di[f], m = typeof g == "function" ? (y) => { + Ya(y) || (Xa(y), (l.isEditable() || p === "click") && g(y, l)); } : (y) => { - if (Qa(y)) return; - Ya(y); + if (Ya(y)) return; + Xa(y); const x = l.isEditable(); switch (p) { case "cut": - return x && B(l, _s, y); + return x && B(l, Ss, y); case "copy": - return B(l, Ss, y); + return B(l, ws, y); case "paste": - return x && B(l, xs, y); + return x && B(l, bs, y); case "dragstart": - return x && B(l, cd, y); + return x && B(l, ld, y); case "dragover": - return x && B(l, Qb, y); + return x && B(l, Yb, y); case "dragend": - return x && B(l, Jb, y); + return x && B(l, Qb, y); case "focus": - return x && B(l, tx, y); + return x && B(l, ex, y); case "blur": - return x && B(l, ud, y); + return x && B(l, cd, y); case "drop": - return x && B(l, ld, y); + return x && B(l, ad, y); } }; a.addEventListener(p, m), h.push((() => { @@ -8053,7 +8053,7 @@ class Ao { })); } })(t, this), r != null && t.classList.add(...r); - } else this._window = null, this._updateTags.add("history-merge"), it(this); + } else this._window = null, this._updateTags.add("history-merge"), st(this); Kn("root", this, !1, t, n); } } @@ -8066,17 +8066,17 @@ class Ao { setEditorState(t, n) { t.isEmpty() && M(38); let r = t; - r._readOnly && (r = Od(t), r._selection = t._selection ? t._selection.clone() : null), Vu(this); + r._readOnly && (r = Td(t), r._selection = t._selection ? t._selection.clone() : null), Hu(this); const o = this._pendingEditorState, i = this._updateTags, s = n !== void 0 ? n.tag : null; - o === null || o.isEmpty() || (s != null && i.add(s), it(this)), this._pendingEditorState = r, this._dirtyType = dn, this._dirtyElements.set("root", !1), this._compositionKey = null, s != null && i.add(s), this._updating || it(this); + o === null || o.isEmpty() || (s != null && i.add(s), st(this)), this._pendingEditorState = r, this._dirtyType = dn, this._dirtyElements.set("root", !1), this._compositionKey = null, s != null && i.add(s), this._updating || st(this); } parseEditorState(t, n) { return (function(r, o, i) { - const s = Ps(), a = he, l = je, u = pe, d = o._dirtyElements, h = o._dirtyLeaves, f = o._cloneNotNeeded, p = o._dirtyType; + const s = Os(), a = he, l = je, u = pe, d = o._dirtyElements, h = o._dirtyLeaves, f = o._cloneNotNeeded, p = o._dirtyType; o._dirtyElements = /* @__PURE__ */ new Map(), o._dirtyLeaves = /* @__PURE__ */ new Set(), o._cloneNotNeeded = /* @__PURE__ */ new Set(), o._dirtyType = 0, he = s, je = !1, pe = o; try { const g = o._nodes; - Td(r.root, g), i && i(), s._readOnly = !0; + Ed(r.root, g), i && i(), s._readOnly = !0; } catch (g) { g instanceof Error && o._onError(g); } finally { @@ -8086,18 +8086,18 @@ class Ao { })(typeof t == "string" ? JSON.parse(t) : t, this, n); } read(t) { - return it(this), this.getEditorState().read(t, { editor: this }); + return st(this), this.getEditorState().read(t, { editor: this }); } update(t, n) { (function(r, o, i) { - r._updating ? r._updates.push([o, i]) : Os(r, o, i); + r._updating ? r._updates.push([o, i]) : Ts(r, o, i); })(this, t, n); } focus(t, n = {}) { const r = this._rootElement; r !== null && (r.setAttribute("autocapitalize", "off"), $e(this, (() => { const o = H(), i = ce(); - o !== null ? o.dirty || De(o.clone()) : i.getChildrenSize() !== 0 && (n.defaultSelection === "rootStart" ? i.selectStart() : i.selectEnd()), Tx("focus"), Ox((() => { + o !== null ? o.dirty || De(o.clone()) : i.getChildrenSize() !== 0 && (n.defaultSelection === "rootStart" ? i.selectStart() : i.selectEnd()), Ex("focus"), Tx((() => { r.removeAttribute("autocapitalize"), t && t(); })); })), this._pendingEditorState === null && r.removeAttribute("autocapitalize")); @@ -8105,7 +8105,7 @@ class Ao { blur() { const t = this._rootElement; t !== null && t.blur(); - const n = Je(this._window); + const n = Ze(this._window); n !== null && n.removeAllRanges(); } isEditable() { @@ -8118,71 +8118,71 @@ class Ao { return { editorState: this._editorState.toJSON() }; } } -Ao.version = "0.30.0+prod.esm"; -let wx = 1; -const Sx = typeof queueMicrotask == "function" ? queueMicrotask : (e) => { +Io.version = "0.30.0+prod.esm"; +let kx = 1; +const wx = typeof queueMicrotask == "function" ? queueMicrotask : (e) => { Promise.resolve().then(e); }; -function yl(e) { - return ne(zs(e)); +function ml(e) { + return ne(Ds(e)); } -function Dd(e) { +function $d(e) { const t = document.activeElement; if (!Te(t)) return !1; const n = t.nodeName; - return ne(zs(e)) && (n === "INPUT" || n === "TEXTAREA" || t.contentEditable === "true" && Ro(t) == null); + return ne(Ds(e)) && (n === "INPUT" || n === "TEXTAREA" || t.contentEditable === "true" && No(t) == null); } -function No(e, t, n) { +function Ao(e, t, n) { const r = e.getRootElement(); try { - return r !== null && r.contains(t) && r.contains(n) && t !== null && !Dd(t) && zd(t) === e; + return r !== null && r.contains(t) && r.contains(n) && t !== null && !$d(t) && Dd(t) === e; } catch { return !1; } } -function Ds(e) { - return e instanceof Ao; +function $s(e) { + return e instanceof Io; } -function zd(e) { +function Dd(e) { let t = e; for (; t != null; ) { - const n = Ro(t); - if (Ds(n)) return n; + const n = No(t); + if ($s(n)) return n; t = pr(t); } return null; } -function Ro(e) { +function No(e) { return e ? e.__lexicalEditor : null; } function Jt(e) { return e.isToken() || e.isSegmented(); } -function ct(e) { - return gr(e) && e.nodeType === kb; +function ut(e) { + return gr(e) && e.nodeType === xb; } -function _x(e) { - return gr(e) && e.nodeType === wb; +function Sx(e) { + return gr(e) && e.nodeType === kb; } function fn(e) { let t = e; for (; t != null; ) { - if (ct(t)) return t; + if (ut(t)) return t; t = t.firstChild; } return null; } -function go(e, t, n) { +function po(e, t, n) { const r = Lt[t]; if (n !== null && (e & r) == (n & r)) return e; let o = e ^ r; return t === "subscript" ? o &= -65 : t === "superscript" ? o &= -33 : t === "lowercase" ? (o &= -513, o &= -1025) : t === "uppercase" ? (o &= -257, o &= -1025) : t === "capitalize" && (o &= -257, o &= -513), o; } -function Cx(e, t) { +function _x(e, t) { if (t != null) return void (e.__key = t); - be(), Cd(); - const n = le(), r = Ct(), o = "" + wx++; - r._nodeMap.set(o, e), R(e) ? n._dirtyElements.set(o, !0) : n._dirtyLeaves.add(o), n._cloneNotNeeded.add(o), n._dirtyType = Fu, e.__key = o; + be(), _d(); + const n = le(), r = Ct(), o = "" + kx++; + r._nodeMap.set(o, e), R(e) ? n._dirtyElements.set(o, !0) : n._dirtyLeaves.add(o), n._cloneNotNeeded.add(o), n._dirtyType = Lu, e.__key = o; } function Nt(e) { const t = e.getParent(); @@ -8215,8 +8215,8 @@ function Nt(e) { r.__size--, n.__parent = null; } } -function mo(e) { - Cd(); +function go(e) { + _d(); const t = e.getLatest(), n = t.__parent, r = Ct(), o = le(), i = r._nodeMap, s = o._dirtyElements; n !== null && (function(l, u, d) { let h = l; @@ -8228,7 +8228,7 @@ function mo(e) { } })(n, i, s); const a = t.__key; - o._dirtyType = Fu, R(e) ? s.set(a, !0) : o._dirtyLeaves.add(a); + o._dirtyType = Lu, R(e) ? s.set(a, !0) : o._dirtyLeaves.add(a); } function me(e) { be(); @@ -8244,40 +8244,40 @@ function me(e) { } } } -function ft() { +function ht() { return dr() ? null : le()._compositionKey; } function fe(e, t) { const n = (t || Ct())._nodeMap.get(e); return n === void 0 ? null : n; } -function Id(e, t) { - const n = Mo(e, le()); +function zd(e, t) { + const n = Ro(e, le()); return n !== void 0 ? fe(n, t) : null; } -function Mo(e, t) { +function Ro(e, t) { return e[`__lexicalKey_${t._key}`]; } -function zs(e, t) { +function Ds(e, t) { let n = e; for (; n != null; ) { - const r = Id(n, t); + const r = zd(n, t); if (r !== null) return r; n = pr(n); } return null; } -function Ad(e) { +function Id(e) { const t = e._decorators, n = Object.assign({}, t); return e._pendingDecorators = n, n; } -function vl(e) { +function yl(e) { return e.read((() => ce().getTextContent())); } function ce() { - return Nd(Ct()); + return Ad(Ct()); } -function Nd(e) { +function Ad(e) { return e._nodeMap.get("root"); } function De(e) { @@ -8289,7 +8289,7 @@ function en(e) { const t = le(), n = (function(r, o) { let i = r; for (; i != null; ) { - const s = Mo(i, o); + const s = Ro(i, o); if (s !== void 0) return s; i = pr(i); } @@ -8297,51 +8297,51 @@ function en(e) { })(e, t); return n === null ? e === t.getRootElement() ? fe("root") : null : fe(n); } -function bl(e, t) { +function vl(e, t) { return t ? e.getTextContentSize() : 0; } -function Rd(e) { +function Nd(e) { return /[\uD800-\uDBFF][\uDC00-\uDFFF]/g.test(e); } -function Is(e) { +function zs(e) { const t = []; let n = e; for (; n !== null; ) t.push(n), n = n._parentEditor; return t; } -function Md() { +function Rd() { return Math.random().toString(36).replace(/[^a-z]+/g, "").substring(0, 5); } -function Ld(e) { - return ct(e) ? e.nodeValue : null; +function Md(e) { + return ut(e) ? e.nodeValue : null; } -function As(e, t, n) { - const r = Je(Re(t)); +function Is(e, t, n) { + const r = Ze(Me(t)); if (r === null) return; const o = r.anchorNode; let { anchorOffset: i, focusOffset: s } = r; if (o !== null) { - let a = Ld(o); - const l = zs(o); + let a = Md(o); + const l = Ds(o); if (a !== null && F(l)) { - if (a === Oo && n) { + if (a === To && n) { const u = n.length; a = n, i = u, s = u; } - a !== null && Ns(l, a, i, s, e); + a !== null && As(l, a, i, s, e); } } } -function Ns(e, t, n, r, o) { +function As(e, t, n, r, o) { let i = e; if (i.isAttached() && (o || !i.isDirty())) { const s = i.isComposing(); let a = t; - (s || o) && t[t.length - 1] === Oo && (a = t.slice(0, -1)); + (s || o) && t[t.length - 1] === To && (a = t.slice(0, -1)); const l = i.getTextContent(); if (o || a !== l) { if (a === "") { - if (me(null), Qn || un || oo) i.remove(); + if (me(null), Qn || un || ro) i.remove(); else { const m = le(); setTimeout((() => { @@ -8352,7 +8352,7 @@ function Ns(e, t, n, r, o) { } return; } - const u = i.getParent(), d = ur(), h = i.getTextContentSize(), f = ft(), p = i.getKey(); + const u = i.getParent(), d = ur(), h = i.getTextContentSize(), f = ht(), p = i.getKey(); if (i.isToken() || f !== null && p === f && !s || L(d) && (u !== null && !u.canInsertTextBefore() && d.anchor.offset === 0 || d.anchor.key === e.__key && d.anchor.offset === 0 && !i.canInsertTextBefore() && !s || d.focus.key === e.__key && d.focus.offset === h && !i.canInsertTextAfter() && !s)) return void i.markDirty(); const g = H(); if (!L(g) || n === null || r === null) return void i.setTextContent(a); @@ -8364,16 +8364,16 @@ function Ns(e, t, n, r, o) { } } } -function xl(e) { +function bl(e) { return e === "ArrowLeft"; } -function kl(e) { +function xl(e) { return e === "ArrowRight"; } function Ln(e, t) { - return Fe ? e : t; + return qe ? e : t; } -function wl(e) { +function kl(e) { return e === "Enter"; } function Yt(e) { @@ -8382,18 +8382,18 @@ function Yt(e) { function In(e) { return e === "Delete"; } -function Sl(e, t, n) { +function wl(e, t, n) { return e.toLowerCase() === "a" && Ln(t, n); } -function jx(e) { +function Cx(e) { const t = ce(); if (L(e)) { const n = e.anchor, r = e.focus, o = n.getNode().getTopLevelElementOrThrow().getParentOrThrow(); - return n.set(o.getKey(), 0, "element"), r.set(o.getKey(), o.getChildrenSize(), "element"), wi(e), e; + return n.set(o.getKey(), 0, "element"), r.set(o.getKey(), o.getChildrenSize(), "element"), ki(e), e; } { const n = t.select(0, t.getChildrenSize()); - return De(wi(n)), n; + return De(ki(n)), n; } } function sn(e, t) { @@ -8402,12 +8402,12 @@ function sn(e, t) { if (r !== void 0) return r; const o = e[t]; if (typeof o == "string") { - const i = io(o); + const i = oo(o); return n[t] = i, i; } return o; } -function Rs(e, t, n, r, o) { +function Ns(e, t, n, r, o) { if (n.size === 0) return; const i = r.__type, s = r.__key, a = t.get(i); a === void 0 && M(33, i); @@ -8417,31 +8417,31 @@ function Rs(e, t, n, r, o) { const d = u.get(s), h = d === "destroyed" && o === "created"; (d === void 0 || h) && u.set(s, h ? "updated" : o); } -function _l(e, t, n) { +function Sl(e, t, n) { const r = e.getParent(); let o = n, i = e; return r !== null && (n === 0 && (o = i.getIndexWithinParent(), i = r)), i.getChildAtIndex(o - 1); } -function Ex(e, t) { +function jx(e, t) { const n = e.offset; if (e.type === "element") - return _l(e.getNode(), t, n); + return Sl(e.getNode(), t, n); { const r = e.getNode(); if (n === 0 || !t) { const o = r.getPreviousSibling(); - return o === null ? _l(r.getParentOrThrow(), t, r.getIndexWithinParent() + 0) : o; + return o === null ? Sl(r.getParentOrThrow(), t, r.getIndexWithinParent() + 0) : o; } } return null; } -function Fd(e) { - const t = Re(e).event, n = t && t.inputType; +function Ld(e) { + const t = Me(e).event, n = t && t.inputType; return n === "insertFromPaste" || n === "insertFromPasteAsQuotation"; } function B(e, t, n) { return (function(r, o, i) { - const s = Is(r); + const s = zs(r); for (let a = 4; a >= 0; a--) for (let l = 0; l < s.length; l++) { const u = s[l], d = u._commands.get(o); if (d !== void 0) { @@ -8458,7 +8458,7 @@ function B(e, t, n) { return !1; })(e, t, n); } -function Lo(e) { +function Mo(e) { return !Se(e) && !e.isLastChild() && !e.isInline(); } function hn(e, t) { @@ -8467,18 +8467,18 @@ function hn(e, t) { } function pr(e) { const t = e.assignedSlot || e.parentElement; - return qi(t) ? t.host : t; + return Fi(t) ? t.host : t; } -function qd(e) { - return _x(e) ? e : Te(e) ? e.ownerDocument : null; +function Fd(e) { + return Sx(e) ? e : Te(e) ? e.ownerDocument : null; } -function Tx(e) { +function Ex(e) { be(), le()._updateTags.add(e); } -function Ox(e) { +function Tx(e) { be(), le()._deferred.push(e); } -function Li(e, t) { +function Mi(e, t) { let n = e.getParent(); for (; n !== null; ) { if (n.is(t)) return !0; @@ -8486,15 +8486,15 @@ function Li(e, t) { } return !1; } -function Ms(e) { - const t = qd(e); +function Rs(e) { + const t = Fd(e); return t ? t.defaultView : null; } -function Re(e) { +function Me(e) { const t = e._window; return t === null && M(78), t; } -function Px(e) { +function Ox(e) { let t = e.getParentOrThrow(); for (; t !== null; ) { if (jt(t)) return t; @@ -8505,7 +8505,7 @@ function Px(e) { function jt(e) { return Se(e) || R(e) && e.isShadowRoot(); } -function Fo(e) { +function Lo(e) { const t = le(), n = e.constructor.getType(), r = t._nodes.get(n); r === void 0 && M(200, e.constructor.name, n); const { replace: o, replaceWithKlass: i } = r; @@ -8515,61 +8515,61 @@ function Fo(e) { } return e; } -function ci(e, t) { +function li(e, t) { !Se(e.getParent()) || R(t) || ne(t) || M(99); } -function $x(e) { +function Px(e) { const t = fe(e); return t === null && M(63, e), t; } -function ui(e) { +function ci(e) { return (ne(e) || R(e) && !e.canBeEmpty()) && !e.isInline(); } -function Fi(e, t, n) { +function Li(e, t, n) { n.style.removeProperty("caret-color"), t._blockCursorElement = null; const r = e.parentElement; r !== null && r.removeChild(e); } -function Je(e) { - return He ? (e || window).getSelection() : null; +function Ze(e) { + return Ve ? (e || window).getSelection() : null; } -function Dx(e) { - const t = Ms(e); +function $x(e) { + const t = Rs(e); return t ? t.getSelection() : null; } function Te(e) { - return gr(e) && e.nodeType === xb; + return gr(e) && e.nodeType === bb; } function gr(e) { return typeof e == "object" && e !== null && "nodeType" in e && typeof e.nodeType == "number"; } -function qi(e) { - return gr(e) && e.nodeType === Sb; +function Fi(e) { + return gr(e) && e.nodeType === wb; } -function zx(e) { +function Dx(e) { const t = new RegExp(/^(a|abbr|acronym|b|cite|code|del|em|i|ins|kbd|label|mark|output|q|ruby|s|samp|span|strong|sub|sup|time|u|tt|var|#text)$/, "i"); return e.nodeName.match(t) !== null; } -function Cl(e) { +function _l(e) { const t = new RegExp(/^(address|article|aside|blockquote|canvas|dd|div|dl|dt|fieldset|figcaption|figure|footer|form|h1|h2|h3|h4|h5|h6|header|hr|li|main|nav|noscript|ol|p|pre|section|table|td|tfoot|ul|video)$/, "i"); return e.nodeName.match(t) !== null; } -function dt(e) { +function ft(e) { if (ne(e) && !e.isInline()) return !0; if (!R(e) || jt(e)) return !1; const t = e.getFirstChild(), n = t === null || Wn(t) || F(t) || t.isInline(); return !e.isInline() && e.canBeEmpty() !== !1 && n; } -function di(e, t) { +function ui(e, t) { let n = e; for (; n !== null && n.getParent() !== null && !t(n); ) n = n.getParentOrThrow(); return t(n) ? n : null; } -const jl = /* @__PURE__ */ new WeakMap(), Ix = /* @__PURE__ */ new Map(); -function El(e) { - if (!e._readOnly && e.isEmpty()) return Ix; +const Cl = /* @__PURE__ */ new WeakMap(), zx = /* @__PURE__ */ new Map(); +function jl(e) { + if (!e._readOnly && e.isEmpty()) return zx; e._readOnly || M(192); - let t = jl.get(e); + let t = Cl.get(e); return t || (t = (function(n) { const r = /* @__PURE__ */ new Map(); for (const [o, i] of n._nodeMap) { @@ -8578,26 +8578,26 @@ function El(e) { a || (a = /* @__PURE__ */ new Map(), r.set(s, a)), a.set(o, i); } return r; - })(e), jl.set(e, t)), t; + })(e), Cl.set(e, t)), t; } -function Bd(e) { +function qd(e) { const t = e.constructor.clone(e); return t.afterCloneFrom(e), t; } -function Ax(e, t) { +function Ix(e, t) { const n = parseInt(e.style.paddingInlineStart, 10) || 0, r = Math.round(n / 40); t.setIndent(r); } -function Nx(e) { +function Ax(e) { return e.__lexicalUnmanaged === !0; } -const Rx = { next: "previous", previous: "next" }; -class Ls { +const Nx = { next: "previous", previous: "next" }; +class Ms { constructor(t) { this.origin = t; } [Symbol.iterator]() { - return Ud({ hasNext: pn, initial: this.getAdjacentCaret(), map: (t) => t, step: (t) => t.getAdjacentCaret() }); + return Bd({ hasNext: pn, initial: this.getAdjacentCaret(), map: (t) => t, step: (t) => t.getAdjacentCaret() }); } getAdjacentCaret() { return ke(this.getNodeAtCaret(), this.direction); @@ -8637,18 +8637,18 @@ class Ls { return this; } } -class or extends Ls { +class or extends Ms { type = "child"; getLatest() { const t = this.origin.getLatest(); - return t === this.origin ? this : yt(t, this.direction); + return t === this.origin ? this : vt(t, this.direction); } getParentCaret(t = "root") { - return ke(Fs(this.getParentAtCaret(), t), this.direction); + return ke(Ls(this.getParentAtCaret(), t), this.direction); } getFlipped() { const t = En(this.direction); - return ke(this.getNodeAtCaret(), t) || yt(this.origin, t); + return ke(this.getNodeAtCaret(), t) || vt(this.origin, t); } getParentAtCaret() { return this.origin; @@ -8663,14 +8663,14 @@ class or extends Ls { return this.isSameNodeCaret(t); } } -const Mx = { root: Se, shadowRoot: jt }; +const Rx = { root: Se, shadowRoot: jt }; function En(e) { - return Rx[e]; + return Nx[e]; } -function Fs(e, t = "root") { - return Mx[t](e) ? null : e; +function Ls(e, t = "root") { + return Rx[t](e) ? null : e; } -class Bt extends Ls { +class Bt extends Ms { type = "sibling"; getLatest() { const t = this.origin.getLatest(); @@ -8683,14 +8683,14 @@ class Bt extends Ls { return this.origin.getParent(); } getChildCaret() { - return R(this.origin) ? yt(this.origin, this.direction) : null; + return R(this.origin) ? vt(this.origin, this.direction) : null; } getParentCaret(t = "root") { - return ke(Fs(this.getParentAtCaret(), t), this.direction); + return ke(Ls(this.getParentAtCaret(), t), this.direction); } getFlipped() { const t = En(this.direction); - return ke(this.getNodeAtCaret(), t) || yt(this.origin.getParentOrThrow(), t); + return ke(this.getNodeAtCaret(), t) || vt(this.origin.getParentOrThrow(), t); } isSamePointCaret(t) { return t instanceof Bt && this.direction === t.direction && this.origin.is(t.origin); @@ -8699,7 +8699,7 @@ class Bt extends Ls { return (t instanceof Bt || t instanceof Ut) && this.direction === t.direction && this.origin.is(t.origin); } } -class Ut extends Ls { +class Ut extends Ms { type = "text"; constructor(t, n) { super(t), this.offset = n; @@ -8715,7 +8715,7 @@ class Ut extends Ls { return null; } getParentCaret(t = "root") { - return ke(Fs(this.getParentAtCaret(), t), this.direction); + return ke(Ls(this.getParentAtCaret(), t), this.direction); } getFlipped() { return Ht(this.origin, En(this.direction), this.offset); @@ -8736,10 +8736,10 @@ function Rt(e) { function pn(e) { return e instanceof Bt; } -function Ye(e) { +function Qe(e) { return e instanceof or; } -const Lx = { next: class extends Ut { +const Mx = { next: class extends Ut { direction = "next"; getNodeAtCaret() { return this.origin.getNextSibling(); @@ -8755,7 +8755,7 @@ const Lx = { next: class extends Ut { insert(e) { return this.origin.insertBefore(e), this; } -} }, Fx = { next: class extends Bt { +} }, Lx = { next: class extends Bt { direction = "next"; getNodeAtCaret() { return this.origin.getNextSibling(); @@ -8771,7 +8771,7 @@ const Lx = { next: class extends Ut { insert(e) { return this.origin.insertBefore(e), this; } -} }, qx = { next: class extends or { +} }, Fx = { next: class extends or { direction = "next"; getNodeAtCaret() { return this.origin.getFirstChild(); @@ -8789,12 +8789,12 @@ const Lx = { next: class extends Ut { } } }; function ke(e, t) { - return e ? new Fx[t](e) : null; + return e ? new Lx[t](e) : null; } function Ht(e, t, n) { - return e ? new Lx[t](e, qo(e, n)) : null; + return e ? new Mx[t](e, Fo(e, n)) : null; } -function qo(e, t) { +function Fo(e, t) { const n = e.getTextContentSize(); let r = t === "next" ? n : t === "previous" ? 0 : t; return (r < 0 || r > n) && ((function(o, ...i) { @@ -8804,26 +8804,26 @@ function qo(e, t) { s.search = a.toString(), console.warn(`Minified Lexical warning #${o}; visit ${s.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`); })(284, String(t), String(n), e.getKey()), r = r < 0 ? 0 : n), r; } -function Tl(e, t) { - return new Ux(e, t); +function El(e, t) { + return new Bx(e, t); } -function yt(e, t) { - return R(e) ? new qx[t](e) : null; +function vt(e, t) { + return R(e) ? new Fx[t](e) : null; } -function Bx(e) { +function qx(e) { return e && e.getChildCaret() || e; } -function qs(e) { - return e && Bx(e.getAdjacentCaret()); +function Fs(e) { + return e && qx(e.getAdjacentCaret()); } -class Bs { +class qs { type = "node-caret-range"; constructor(t, n, r) { this.anchor = t, this.focus = n, this.direction = r; } getLatest() { const t = this.anchor.getLatest(), n = this.focus.getLatest(); - return t === this.anchor && n === this.focus ? this : new Bs(t, n, this.direction); + return t === this.anchor && n === this.focus ? this : new qs(t, n, this.direction); } isCollapsed() { return this.anchor.isSamePointCaret(this.focus); @@ -8832,25 +8832,25 @@ class Bs { const t = (o) => { const i = this[o].getLatest(); return Rt(i) ? (function(s, a) { - const { direction: l, origin: u } = s, d = qo(u, a === "focus" ? En(l) : l); - return Tl(s, d - s.offset); + const { direction: l, origin: u } = s, d = Fo(u, a === "focus" ? En(l) : l); + return El(s, d - s.offset); })(i, o) : null; }, n = t("anchor"), r = t("focus"); if (n && r) { const { caret: o } = n, { caret: i } = r; - if (o.isSameNodeCaret(i)) return [Tl(o, i.offset - o.offset), null]; + if (o.isSameNodeCaret(i)) return [El(o, i.offset - o.offset), null]; } return [n, r]; } iterNodeCarets(t = "root") { - const n = Rt(this.anchor) ? this.anchor.getSiblingCaret() : this.anchor.getLatest(), r = this.focus.getLatest(), o = Rt(r), i = (s) => s.isSameNodeCaret(r) ? null : qs(s) || s.getParentCaret(t); - return Ud({ hasNext: (s) => s !== null && !(o && r.isSameNodeCaret(s)), initial: n.isSameNodeCaret(r) ? null : i(n), map: (s) => s, step: i }); + const n = Rt(this.anchor) ? this.anchor.getSiblingCaret() : this.anchor.getLatest(), r = this.focus.getLatest(), o = Rt(r), i = (s) => s.isSameNodeCaret(r) ? null : Fs(s) || s.getParentCaret(t); + return Bd({ hasNext: (s) => s !== null && !(o && r.isSameNodeCaret(s)), initial: n.isSameNodeCaret(r) ? null : i(n), map: (s) => s, step: i }); } [Symbol.iterator]() { return this.iterNodeCarets("root"); } } -class Ux { +class Bx { type = "slice"; constructor(t, n) { this.caret = t, this.distance = n; @@ -8871,16 +8871,16 @@ class Ux { return Ht(t.setTextContent(i.slice(0, r) + i.slice(o)), n, r); } } -function Us(e) { +function Bs(e) { return Vt(e, ke(ce(), e.direction)); } -function Hx(e) { +function Ux(e) { return Vt(e, e); } function Vt(e, t) { - return e.direction !== t.direction && M(265), new Bs(e, t, e.direction); + return e.direction !== t.direction && M(265), new qs(e, t, e.direction); } -function Ud(e) { +function Bd(e) { const { initial: t, hasNext: n, step: r, map: o } = e; let i = t; return { [Symbol.iterator]() { @@ -8891,7 +8891,7 @@ function Ud(e) { return i = r(i), s; } }; } -function Hd(e, t) { +function Ud(e, t) { const n = Qr(e.origin, t.origin); switch (n === null && M(275, e.origin.getKey(), t.origin.getKey()), n.type) { case "same": { @@ -8905,10 +8905,10 @@ function Hd(e, t) { case "descendant": return t.type === "child" ? 1 : -1; case "branch": - return Vd(n); + return Hd(n); } } -function Vd(e) { +function Hd(e) { const { a: t, b: n } = e, r = t.__key, o = n.__key; let i = t, s = n; for (; i && s; i = i.getNextSibling(), s = s.getNextSibling()) { @@ -8920,56 +8920,56 @@ function Vd(e) { function Dr(e, t) { return t.is(e); } -function Ol(e) { +function Tl(e) { return R(e) ? [e.getLatest(), null] : [e.getParent(), e.getLatest()]; } function Qr(e, t) { if (e.is(t)) return { commonAncestor: e, type: "same" }; const n = /* @__PURE__ */ new Map(); - for (let [r, o] = Ol(e); r; o = r, r = r.getParent()) n.set(r, o); - for (let [r, o] = Ol(t); r; o = r, r = r.getParent()) { + for (let [r, o] = Tl(e); r; o = r, r = r.getParent()) n.set(r, o); + for (let [r, o] = Tl(t); r; o = r, r = r.getParent()) { const i = n.get(r); if (i !== void 0) return i === null ? (Dr(e, r) || M(276), { commonAncestor: r, type: "ancestor" }) : o === null ? (Dr(t, r) || M(277), { commonAncestor: r, type: "descendant" }) : ((R(i) || Dr(e, i)) && (R(o) || Dr(t, o)) && r.is(i.getParent()) && r.is(o.getParent()) || M(278), { a: i, b: o, commonAncestor: r, type: "branch" }); } return null; } -function vt(e, t) { - const { type: n, key: r, offset: o } = e, i = $x(e.key); - return n === "text" ? (F(i) || M(266, i.getType(), r), Ht(i, t, o)) : (R(i) || M(267, i.getType(), r), Kx(i, e.offset, t)); +function bt(e, t) { + const { type: n, key: r, offset: o } = e, i = Px(e.key); + return n === "text" ? (F(i) || M(266, i.getType(), r), Ht(i, t, o)) : (R(i) || M(267, i.getType(), r), Wx(i, e.offset, t)); } function ir(e, t) { const { origin: n, direction: r } = t, o = r === "next"; - Rt(t) ? e.set(n.getKey(), t.offset, "text") : pn(t) ? F(n) ? e.set(n.getKey(), qo(n, r), "text") : e.set(n.getParentOrThrow().getKey(), n.getIndexWithinParent() + (o ? 1 : 0), "element") : (Ye(t) && R(n) || M(268), e.set(n.getKey(), o ? 0 : n.getChildrenSize(), "element")); + Rt(t) ? e.set(n.getKey(), t.offset, "text") : pn(t) ? F(n) ? e.set(n.getKey(), Fo(n, r), "text") : e.set(n.getParentOrThrow().getKey(), n.getIndexWithinParent() + (o ? 1 : 0), "element") : (Qe(t) && R(n) || M(268), e.set(n.getKey(), o ? 0 : n.getChildrenSize(), "element")); } -function Vx(e) { - const t = H(), n = L(t) ? t : hx(); +function Hx(e) { + const t = H(), n = L(t) ? t : fx(); return Jr(n, e), De(n), n; } function Jr(e, t) { ir(e.anchor, t.anchor), ir(e.focus, t.focus); } -function Pl(e) { - const { anchor: t, focus: n } = e, r = vt(t, "next"), o = vt(n, "next"), i = Hd(r, o) <= 0 ? "next" : "previous"; +function Ol(e) { + const { anchor: t, focus: n } = e, r = bt(t, "next"), o = bt(n, "next"), i = Ud(r, o) <= 0 ? "next" : "previous"; return Vt(gn(r, i), gn(o, i)); } -function Hs(e) { +function Us(e) { const { direction: t, origin: n } = e, r = ke(n, En(t)).getNodeAtCaret(); - return r ? ke(r, t) : yt(n.getParentOrThrow(), t); + return r ? ke(r, t) : vt(n.getParentOrThrow(), t); } -function $l(e, t = "root") { +function Pl(e, t = "root") { const n = [e]; - for (let r = Ye(e) ? e.getParentCaret(t) : e.getSiblingCaret(); r !== null; r = r.getParentCaret(t)) n.push(Hs(r)); + for (let r = Qe(e) ? e.getParentCaret(t) : e.getSiblingCaret(); r !== null; r = r.getParentCaret(t)) n.push(Us(r)); return n; } -function fi(e) { +function di(e) { return !!e && e.origin.isAttached(); } -function Wx(e, t = "removeEmptySlices") { +function Vx(e, t = "removeEmptySlices") { if (e.isCollapsed()) return e; const n = "root", r = "next"; let o = t; - const i = Kd(e, r), s = $l(i.anchor, n), a = $l(i.focus.getFlipped(), n), l = /* @__PURE__ */ new Set(), u = []; - for (const g of i.iterNodeCarets(n)) if (Ye(g)) l.add(g.origin.getKey()); + const i = Wd(e, r), s = Pl(i.anchor, n), a = Pl(i.focus.getFlipped(), n), l = /* @__PURE__ */ new Set(), u = []; + for (const g of i.iterNodeCarets(n)) if (Qe(g)) l.add(g.origin.getKey()); else if (pn(g)) { const { origin: m } = g; R(m) && !l.has(m.getKey()) || u.push(m); @@ -8977,7 +8977,7 @@ function Wx(e, t = "removeEmptySlices") { for (const g of u) g.remove(); for (const g of i.getTextSlices()) { if (!g) continue; - const { origin: m } = g.caret, y = m.getTextContentSize(), x = Hs(ke(m, r)), k = m.getMode(); + const { origin: m } = g.caret, y = m.getTextContentSize(), x = Us(ke(m, r)), k = m.getMode(); if (Math.abs(g.distance) === y && o === "removeEmptySlices" || k === "token" && g.distance !== 0) x.remove(); else if (g.distance !== 0) { o = "removeEmptySlices"; @@ -8991,12 +8991,12 @@ function Wx(e, t = "removeEmptySlices") { } } let d, h; - for (const g of s) if (fi(g)) { - d = Xe(g); + for (const g of s) if (di(g)) { + d = Ye(g); break; } - for (const g of a) if (fi(g)) { - h = Xe(g); + for (const g of a) if (di(g)) { + h = Ye(g); break; } const f = (function(g, m, y) { @@ -9018,24 +9018,24 @@ function Wx(e, t = "removeEmptySlices") { !T && C(I) && (T = I); } return T; - }, P = S(v, dt), D = P && S(b, (($) => y.has($.getKey()) && dt($))); + }, P = S(v, ft), D = P && S(b, (($) => y.has($.getKey()) && ft($))); return P && D ? [P, D] : null; })(d, h, l); if (f) { const [g, m] = f; - yt(g, "previous").splice(0, m.getChildren()), m.remove(); + vt(g, "previous").splice(0, m.getChildren()), m.remove(); } - const p = [d, h, ...s, ...a].find(fi); + const p = [d, h, ...s, ...a].find(di); if (p) - return Hx(gn(Xe(p), e.direction)); + return Ux(gn(Ye(p), e.direction)); M(269, JSON.stringify(s.map(((g) => g.origin.__key)))); } -function Xe(e) { +function Ye(e) { const t = (function(o) { let i = o; - for (; Ye(i); ) { - const s = qs(i); - if (!Ye(s)) break; + for (; Qe(i); ) { + const s = Fs(i); + if (!Qe(s)) break; i = s; } return i; @@ -9044,17 +9044,17 @@ function Xe(e) { const r = t.getAdjacentCaret(); return pn(r) && F(r.origin) ? Ht(r.origin, n, En(n)) : t; } -function Wd(e) { - return Rt(e) && e.offset !== qo(e.origin, e.direction); +function Vd(e) { + return Rt(e) && e.offset !== Fo(e.origin, e.direction); } function gn(e, t) { return e.direction === t ? e : e.getFlipped(); } -function Kd(e, t) { +function Wd(e, t) { return e.direction === t ? e : Vt(gn(e.focus, t), gn(e.anchor, t)); } -function Kx(e, t, n) { - let r = yt(e, "next"); +function Wx(e, t, n) { + let r = vt(e, "next"); for (let o = 0; o < t; o++) { const i = r.getAdjacentCaret(); if (i === null) break; @@ -9062,10 +9062,10 @@ function Kx(e, t, n) { } return gn(r, n); } -const Gd = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, Gx = Gd ? A.useLayoutEffect : A.useEffect, zr = { tag: "history-merge" }; -function Vs({ initialConfig: e, children: t }) { +const Kd = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, Kx = Kd ? A.useLayoutEffect : A.useEffect, zr = { tag: "history-merge" }; +function Hs({ initialConfig: e, children: t }) { const n = A.useMemo((() => { - const { theme: r, namespace: o, nodes: i, onError: s, editorState: a, html: l } = e, u = yb(null, r), d = kx({ editable: e.editable, html: l, namespace: o, nodes: i, onError: (h) => s(h, d), theme: r }); + const { theme: r, namespace: o, nodes: i, onError: s, editorState: a, html: l } = e, u = mb(null, r), d = xx({ editable: e.editable, html: l, namespace: o, nodes: i, onError: (h) => s(h, d), theme: r }); return (function(h, f) { if (f !== null) { if (f === void 0) h.update((() => { @@ -9073,7 +9073,7 @@ function Vs({ initialConfig: e, children: t }) { if (p.isEmpty()) { const g = Ne(); p.append(g); - const m = Gd ? document.activeElement : null; + const m = Kd ? document.activeElement : null; (H() !== null || m !== null && m === h.getRootElement()) && g.select(); } }), zr); @@ -9094,28 +9094,28 @@ function Vs({ initialConfig: e, children: t }) { } })(d, a), [d, u]; }), []); - return Gx((() => { + return Kx((() => { const r = e.editable, [o] = n; o.setEditable(r === void 0 || r); - }), []), c.jsx(Mu.Provider, { value: n, children: t }); + }), []), c.jsx(Ru.Provider, { value: n, children: t }); } -function Xx() { +function Gx() { return ce().getTextContent(); } -function Yx(e, t = !0) { +function Xx(e, t = !0) { if (e) return !1; - let n = Xx(); + let n = Gx(); return t && (n = n.trim()), n === ""; } -function Qx(e) { - if (!Yx(e, !1)) return !1; +function Yx(e) { + if (!Xx(e, !1)) return !1; const t = ce().getChildren(), n = t.length; if (n > 1) return !1; for (let r = 0; r < n; r++) { const o = t[r]; if (ne(o)) return !1; if (R(o)) { - if (!xx(o) || o.__indent !== 0) return !1; + if (!bx(o) || o.__indent !== 0) return !1; const i = o.getChildren(), s = i.length; for (let a = 0; a < s; a++) { const l = i[r]; @@ -9125,16 +9125,16 @@ function Qx(e) { } return !0; } -function Xd(e) { - return () => Qx(e); +function Gd(e) { + return () => Yx(e); } -function Jx(e, ...t) { +function Qx(e, ...t) { const n = new URL("https://lexical.dev/docs/error"), r = new URLSearchParams(); r.append("code", e); for (const o of t) r.append("v", o); throw n.search = r.toString(), Error(`Minified Lexical error #${e}; visit ${n.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`); } -function Zx(e, t, n, r) { +function Jx(e, t, n, r) { const o = (s) => s instanceof n, i = (s) => { const a = ae(s.getTextContent()); a.setFormat(s.getFormat()), s.replace(a); @@ -9178,7 +9178,7 @@ function Zx(e, t, n, r) { h += a.end; continue; } - a.start === 0 ? [f, d] = d.splitText(a.end) : [, f, d] = d.splitText(a.start + h, a.end + h), f === void 0 && Jx(165, "nodeToReplace"); + a.start === 0 ? [f, d] = d.splitText(a.end) : [, f, d] = d.splitText(a.start + h, a.end + h), f === void 0 && Qx(165, "nodeToReplace"); const g = r(f); if (g.setFormat(f.getFormat()), f.replace(g), d == null) return; h = 0, l = g; @@ -9193,23 +9193,23 @@ function Zx(e, t, n, r) { F(d) && d.isTextEntity() && (i(d), o(s) && i(s)); }))]; } -function ek(e, t) { +function Zx(e, t) { const n = e.getStartEndPoints(); if (t.isSelected(e) && !t.isSegmented() && !t.isToken() && n !== null) { const [r, o] = n, i = e.isBackward(), s = r.getNode(), a = o.getNode(), l = t.is(s), u = t.is(a); if (l || u) { - const [d, h] = Mi(e), f = s.is(a), p = t.is(i ? a : s), g = t.is(i ? s : a); + const [d, h] = Ri(e), f = s.is(a), p = t.is(i ? a : s), g = t.is(i ? s : a); let m, y = 0; return f ? (y = d > h ? h : d, m = d > h ? d : h) : p ? (y = i ? h : d, m = void 0) : g && (y = 0, m = i ? d : h), t.__text = t.__text.slice(y, m), t; } } return t; } -function Dl(e, t) { - const n = vt(e.focus, t ? "previous" : "next"); - if (Wd(n)) return !1; - for (const r of Us(n)) { - if (Ye(r)) return !r.origin.isInline(); +function $l(e, t) { + const n = bt(e.focus, t ? "previous" : "next"); + if (Vd(n)) return !1; + for (const r of Bs(n)) { + if (Qe(r)) return !r.origin.isInline(); if (!R(r.origin)) { if (ne(r.origin)) return !0; break; @@ -9217,30 +9217,30 @@ function Dl(e, t) { } return !1; } -function tk(e, t, n, r) { +function ek(e, t, n, r) { e.modify(t ? "extend" : "move", n, r); } -function nk(e) { +function tk(e) { const t = e.anchor.getNode(); return (Se(t) ? t : t.getParentOrThrow()).getDirection() === "rtl"; } -function zl(e, t, n) { - const r = nk(e); - tk(e, t, n ? !r : r, "character"); +function Dl(e, t, n) { + const r = tk(e); + ek(e, t, n ? !r : r, "character"); } -const Yd = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, rk = Yd && "documentMode" in document ? document.documentMode : null; -!(!Yd || !("InputEvent" in window) || rk) && "getTargetRanges" in new window.InputEvent("input"); -function bt(...e) { +const Xd = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, nk = Xd && "documentMode" in document ? document.documentMode : null; +!(!Xd || !("InputEvent" in window) || nk) && "getTargetRanges" in new window.InputEvent("input"); +function xt(...e) { return () => { for (let t = e.length - 1; t >= 0; t--) e[t](); e.length = 0; }; } -function Qd(e, t) { +function Yd(e, t) { return e !== null && Object.getPrototypeOf(e).constructor.name === t.name; } -const Jd = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? A.useLayoutEffect : A.useEffect; -function ok({ editor: e, ariaActiveDescendant: t, ariaAutoComplete: n, ariaControls: r, ariaDescribedBy: o, ariaErrorMessage: i, ariaExpanded: s, ariaInvalid: a, ariaLabel: l, ariaLabelledBy: u, ariaMultiline: d, ariaOwns: h, ariaRequired: f, autoCapitalize: p, className: g, id: m, role: y = "textbox", spellCheck: x = !0, style: k, tabIndex: v, "data-testid": b, ...j }, _) { +const Qd = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? A.useLayoutEffect : A.useEffect; +function rk({ editor: e, ariaActiveDescendant: t, ariaAutoComplete: n, ariaControls: r, ariaDescribedBy: o, ariaErrorMessage: i, ariaExpanded: s, ariaInvalid: a, ariaLabel: l, ariaLabelledBy: u, ariaMultiline: d, ariaOwns: h, ariaRequired: f, autoCapitalize: p, className: g, id: m, role: y = "textbox", spellCheck: x = !0, style: k, tabIndex: v, "data-testid": b, ...j }, _) { const [S, P] = A.useState(e.isEditable()), D = A.useCallback(((C) => { C && C.ownerDocument && C.ownerDocument.defaultView ? e.setRootElement(C) : e.setRootElement(null); }), [e]), $ = A.useMemo((() => /* @__PURE__ */ (function(...C) { @@ -9250,28 +9250,28 @@ function ok({ editor: e, ariaActiveDescendant: t, ariaAutoComplete: n, ariaContr })); }; })(_, D)), [D, _]); - return Jd((() => (P(e.isEditable()), e.registerEditableListener(((C) => { + return Qd((() => (P(e.isEditable()), e.registerEditableListener(((C) => { P(C); })))), [e]), c.jsx("div", { "aria-activedescendant": S ? t : void 0, "aria-autocomplete": S ? n : "none", "aria-controls": S ? r : void 0, "aria-describedby": o, ...i != null ? { "aria-errormessage": i } : {}, "aria-expanded": S && y === "combobox" ? !!s : void 0, ...a != null ? { "aria-invalid": a } : {}, "aria-label": l, "aria-labelledby": u, "aria-multiline": d, "aria-owns": S ? h : void 0, "aria-readonly": !S || void 0, "aria-required": f, autoCapitalize: p, className: g, contentEditable: S, "data-testid": b, id: m, ref: $, role: S ? y : void 0, spellCheck: x, style: k, tabIndex: v, ...j }); } -const ik = A.forwardRef(ok); -function Il(e) { - return e.getEditorState().read(Xd(e.isComposing())); +const ok = A.forwardRef(rk); +function zl(e) { + return e.getEditorState().read(Gd(e.isComposing())); } -const Ws = A.forwardRef(sk); -function sk(e, t) { +const Vs = A.forwardRef(ik); +function ik(e, t) { const { placeholder: n, ...r } = e, [o] = Ee(); - return c.jsxs(c.Fragment, { children: [c.jsx(ik, { editor: o, ...r, ref: t }), n != null && c.jsx(ak, { editor: o, content: n })] }); + return c.jsxs(c.Fragment, { children: [c.jsx(ok, { editor: o, ...r, ref: t }), n != null && c.jsx(sk, { editor: o, content: n })] }); } -function ak({ content: e, editor: t }) { +function sk({ content: e, editor: t }) { const n = (function(s) { - const [a, l] = A.useState((() => Il(s))); - return Jd((() => { + const [a, l] = A.useState((() => zl(s))); + return Qd((() => { function u() { - const d = Il(s); + const d = zl(s); l(d); } - return u(), bt(s.registerUpdateListener((() => { + return u(), xt(s.registerUpdateListener((() => { u(); })), s.registerEditableListener((() => { u(); @@ -9284,26 +9284,26 @@ function ak({ content: e, editor: t }) { let i = null; return typeof e == "function" ? i = e(r) : e !== null && (i = e), i === null ? null : c.jsx("div", { "aria-hidden": !0, children: i }); } -function Bi(e, t) { - return Bi = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(n, r) { +function qi(e, t) { + return qi = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(n, r) { return n.__proto__ = r, n; - }, Bi(e, t); + }, qi(e, t); } -var Al = { error: null }, lk = (function(e) { +var Il = { error: null }, ak = (function(e) { var t, n; function r() { for (var i, s = arguments.length, a = new Array(s), l = 0; l < s; l++) a[l] = arguments[l]; - return (i = e.call.apply(e, [this].concat(a)) || this).state = Al, i.resetErrorBoundary = function() { + return (i = e.call.apply(e, [this].concat(a)) || this).state = Il, i.resetErrorBoundary = function() { for (var u, d = arguments.length, h = new Array(d), f = 0; f < d; f++) h[f] = arguments[f]; i.props.onReset == null || (u = i.props).onReset.apply(u, h), i.reset(); }, i; } - n = e, (t = r).prototype = Object.create(n.prototype), t.prototype.constructor = t, Bi(t, n), r.getDerivedStateFromError = function(i) { + n = e, (t = r).prototype = Object.create(n.prototype), t.prototype.constructor = t, qi(t, n), r.getDerivedStateFromError = function(i) { return { error: i }; }; var o = r.prototype; return o.reset = function() { - this.setState(Al); + this.setState(Il); }, o.componentDidCatch = function(i, s) { var a, l; (a = (l = this.props).onError) == null || a.call(l, i, s); @@ -9324,15 +9324,15 @@ var Al = { error: null }, lk = (function(e) { return this.props.children; }, r; })(A.Component); -function Ks({ children: e, onError: t }) { - return c.jsx(lk, { fallback: c.jsx("div", { style: { border: "1px solid #f00", color: "#f00", padding: "8px" }, children: "An error was thrown." }), onError: t, children: e }); +function Ws({ children: e, onError: t }) { + return c.jsx(ak, { fallback: c.jsx("div", { style: { border: "1px solid #f00", color: "#f00", padding: "8px" }, children: "An error was thrown." }), onError: t, children: e }); } -const Ir = 0, Ui = 1, Hi = 2, qe = 0, ck = 1, Nl = 2, uk = 3, dk = 4; -function fk(e, t, n, r, o) { - if (e === null || n.size === 0 && r.size === 0 && !o) return qe; +const Ir = 0, Bi = 1, Ui = 2, Be = 0, lk = 1, Al = 2, ck = 3, uk = 4; +function dk(e, t, n, r, o) { + if (e === null || n.size === 0 && r.size === 0 && !o) return Be; const i = t._selection, s = e._selection; - if (o) return ck; - if (!(L(i) && L(s) && s.isCollapsed() && i.isCollapsed())) return qe; + if (o) return lk; + if (!(L(i) && L(s) && s.isCollapsed() && i.isCollapsed())) return Be; const a = (function(x, k, v) { const b = x._nodeMap, j = []; for (const _ of k) { @@ -9346,50 +9346,50 @@ function fk(e, t, n, r, o) { } return j; })(t, n, r); - if (a.length === 0) return qe; + if (a.length === 0) return Be; if (a.length > 1) { const x = t._nodeMap, k = x.get(i.anchor.key), v = x.get(s.anchor.key); - return k && v && !e._nodeMap.has(k.__key) && F(k) && k.__text.length === 1 && i.anchor.offset === 1 ? Nl : qe; + return k && v && !e._nodeMap.has(k.__key) && F(k) && k.__text.length === 1 && i.anchor.offset === 1 ? Al : Be; } const l = a[0], u = e._nodeMap.get(l.__key); - if (!F(u) || !F(l) || u.__mode !== l.__mode) return qe; + if (!F(u) || !F(l) || u.__mode !== l.__mode) return Be; const d = u.__text, h = l.__text; - if (d === h) return qe; + if (d === h) return Be; const f = i.anchor, p = s.anchor; - if (f.key !== p.key || f.type !== "text") return qe; + if (f.key !== p.key || f.type !== "text") return Be; const g = f.offset, m = p.offset, y = h.length - d.length; - return y === 1 && m === g - 1 ? Nl : y === -1 && m === g + 1 ? uk : y === -1 && m === g ? dk : qe; + return y === 1 && m === g - 1 ? Al : y === -1 && m === g + 1 ? ck : y === -1 && m === g ? uk : Be; } -function hk(e, t) { - let n = Date.now(), r = qe; +function fk(e, t) { + let n = Date.now(), r = Be; return (o, i, s, a, l, u) => { const d = Date.now(); - if (u.has("historic")) return r = qe, n = d, Hi; - const h = fk(o, i, a, l, e.isComposing()), f = (() => { + if (u.has("historic")) return r = Be, n = d, Ui; + const h = dk(o, i, a, l, e.isComposing()), f = (() => { const p = s === null || s.editor === e, g = u.has("history-push"); if (!g && p && u.has("history-merge")) return Ir; - if (o === null) return Ui; + if (o === null) return Bi; const m = i._selection; - return a.size > 0 || l.size > 0 ? g === !1 && h !== qe && h === r && d < n + t && p || a.size === 1 && (function(y, x, k) { + return a.size > 0 || l.size > 0 ? g === !1 && h !== Be && h === r && d < n + t && p || a.size === 1 && (function(y, x, k) { const v = x._nodeMap.get(y), b = k._nodeMap.get(y), j = x._selection, _ = k._selection; return !(L(j) && L(_) && j.anchor.type === "element" && j.focus.type === "element" && _.anchor.type === "text" && _.focus.type === "text" || !F(v) || !F(b) || v.__parent !== b.__parent) && JSON.stringify(x.read((() => v.exportJSON()))) === JSON.stringify(k.read((() => b.exportJSON()))); - })(Array.from(a)[0], o, i) ? Ir : Ui : m !== null ? Ir : Hi; + })(Array.from(a)[0], o, i) ? Ir : Bi : m !== null ? Ir : Ui; })(); return n = d, r = h, f; }; } -function Rl(e) { +function Nl(e) { e.undoStack = [], e.redoStack = [], e.current = null; } -function pk(e, t, n) { - const r = hk(e, n); - return bt(e.registerCommand(ks, (() => ((function(i, s) { +function hk(e, t, n) { + const r = fk(e, n); + return xt(e.registerCommand(xs, (() => ((function(i, s) { const a = s.redoStack, l = s.undoStack; if (l.length !== 0) { const u = s.current, d = l.pop(); u !== null && (a.push(u), i.dispatchCommand(Er, !0)), l.length === 0 && i.dispatchCommand(Tr, !1), s.current = d || null, d && d.editor.setEditorState(d.editorState, { tag: "historic" }); } - })(e, t), !0)), oe), e.registerCommand(ws, (() => ((function(i, s) { + })(e, t), !0)), oe), e.registerCommand(ks, (() => ((function(i, s) { const a = s.redoStack, l = s.undoStack; if (a.length !== 0) { const u = s.current; @@ -9397,41 +9397,41 @@ function pk(e, t, n) { const d = a.pop(); a.length === 0 && i.dispatchCommand(Er, !1), s.current = d || null, d && d.editor.setEditorState(d.editorState, { tag: "historic" }); } - })(e, t), !0)), oe), e.registerCommand(Zb, (() => (Rl(t), !1)), oe), e.registerCommand(ex, (() => (Rl(t), e.dispatchCommand(Er, !1), e.dispatchCommand(Tr, !1), !0)), oe), e.registerUpdateListener((({ editorState: i, prevEditorState: s, dirtyLeaves: a, dirtyElements: l, tags: u }) => { + })(e, t), !0)), oe), e.registerCommand(Jb, (() => (Nl(t), !1)), oe), e.registerCommand(Zb, (() => (Nl(t), e.dispatchCommand(Er, !1), e.dispatchCommand(Tr, !1), !0)), oe), e.registerUpdateListener((({ editorState: i, prevEditorState: s, dirtyLeaves: a, dirtyElements: l, tags: u }) => { const d = t.current, h = t.redoStack, f = t.undoStack, p = d === null ? null : d.editorState; if (d !== null && i === p) return; const g = r(s, i, d, a, l, u); - if (g === Ui) h.length !== 0 && (t.redoStack = [], e.dispatchCommand(Er, !1)), d !== null && (f.push({ ...d }), e.dispatchCommand(Tr, !0)); - else if (g === Hi) return; + if (g === Bi) h.length !== 0 && (t.redoStack = [], e.dispatchCommand(Er, !1)), d !== null && (f.push({ ...d }), e.dispatchCommand(Tr, !0)); + else if (g === Ui) return; t.current = { editor: e, editorState: i }; }))); } -function gk() { +function pk() { return { current: null, redoStack: [], undoStack: [] }; } -function Gs({ delay: e, externalHistoryState: t }) { +function Ks({ delay: e, externalHistoryState: t }) { const [n] = Ee(); return (function(r, o, i = 1e3) { - const s = A.useMemo((() => o || gk()), [o]); - A.useEffect((() => pk(r, s, i)), [i, r, s]); + const s = A.useMemo((() => o || pk()), [o]); + A.useEffect((() => hk(r, s, i)), [i, r, s]); })(n, t, e), null; } -const mk = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? A.useLayoutEffect : A.useEffect; -function yk(e) { +const gk = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? A.useLayoutEffect : A.useEffect; +function mk(e) { return { initialValueFn: () => e.isEditable(), subscribe: (t) => e.registerEditableListener(t) }; } -function vk() { +function yk() { return (function(e) { const [t] = Ee(), n = A.useMemo((() => e(t)), [t, e]), [r, o] = A.useState((() => n.initialValueFn())), i = A.useRef(r); - return mk((() => { + return gk((() => { const { initialValueFn: s, subscribe: a } = n, l = s(); return i.current !== l && (i.current = l, o(l)), a(((u) => { i.current = u, o(u); })); }), [n, e]), r; - })(yk); + })(mk); } -function bk(e) { +function vk(e) { const t = window.location.origin, n = (r) => { if (r.origin !== t) return; const o = e.getRootElement(); @@ -9472,20 +9472,20 @@ function bk(e) { window.removeEventListener("message", n, !0); }; } -function xk(e, t) { +function bk(e, t) { if (typeof document > "u" || typeof window > "u" && global.window === void 0) throw new Error("To use $generateHtmlFromNodes in headless mode please initialize a headless browser implementation such as JSDom before calling this function."); const n = document.createElement("div"), r = ce().getChildren(); for (let o = 0; o < r.length; o++) - Zd(e, r[o], n, t); + Jd(e, r[o], n, t); return n.innerHTML; } -function Zd(e, t, n, r = null) { +function Jd(e, t, n, r = null) { let o = r === null || t.isSelected(r); const i = R(t) && t.excludeFromCopy("html"); let s = t; if (r !== null) { - let p = Bd(t); - p = F(p) && r !== null ? ek(r, p) : p, s = p; + let p = qd(t); + p = F(p) && r !== null ? Zx(r, p) : p, s = p; } const a = R(s) ? s.getChildren() : [], l = e._nodes.get(s.getType()); let u; @@ -9494,45 +9494,45 @@ function Zd(e, t, n, r = null) { if (!d) return !1; const f = document.createDocumentFragment(); for (let p = 0; p < a.length; p++) { - const g = a[p], m = Zd(e, g, f, r); + const g = a[p], m = Jd(e, g, f, r); !o && R(t) && m && t.extractWithChild(g, r, "html") && (o = !0); } if (o && !i) { - if ((Te(d) || qi(d)) && d.append(f), n.append(d), h) { + if ((Te(d) || Fi(d)) && d.append(f), n.append(d), h) { const p = h.call(s, d); - p && (qi(d) ? d.replaceChildren(p) : d.replaceWith(p)); + p && (Fi(d) ? d.replaceChildren(p) : d.replaceWith(p)); } } else n.append(f); return o; } -function kk(e, ...t) { +function xk(e, ...t) { const n = new URL("https://lexical.dev/docs/error"), r = new URLSearchParams(); r.append("code", e); for (const o of t) r.append("v", o); throw n.search = r.toString(), Error(`Minified Lexical error #${e}; visit ${n.toString()} for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`); } -function wk(e, t = H()) { - return t == null && kk(166), L(t) && t.isCollapsed() || t.getNodes().length === 0 ? "" : xk(e, t); +function kk(e, t = H()) { + return t == null && xk(166), L(t) && t.isCollapsed() || t.getNodes().length === 0 ? "" : bk(e, t); } -function Ml(e, t) { +function Rl(e, t) { const n = e.getData("text/plain") || e.getData("text/uri-list"); n != null && t.insertRawText(n); } -const Tn = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, Sk = Tn && "documentMode" in document ? document.documentMode : null, _k = !(!Tn || !("InputEvent" in window) || Sk) && "getTargetRanges" in new window.InputEvent("input"), Ck = Tn && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), Ll = Tn && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, jk = Tn && /^(?=.*Chrome).*/i.test(navigator.userAgent), Ek = Tn && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !jk; -function Fl(e, t) { +const Tn = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, wk = Tn && "documentMode" in document ? document.documentMode : null, Sk = !(!Tn || !("InputEvent" in window) || wk) && "getTargetRanges" in new window.InputEvent("input"), _k = Tn && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), Ml = Tn && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, Ck = Tn && /^(?=.*Chrome).*/i.test(navigator.userAgent), jk = Tn && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !Ck; +function Ll(e, t) { t.update((() => { if (e !== null) { - const n = Qd(e, KeyboardEvent) ? null : e.clipboardData, r = H(); + const n = Yd(e, KeyboardEvent) ? null : e.clipboardData, r = H(); if (r !== null && n != null) { e.preventDefault(); - const o = wk(t); + const o = kk(t); o !== null && n.setData("text/html", o), n.setData("text/plain", r.getTextContent()); } } })); } -function Tk(e) { - return bt(e.registerCommand(At, ((t) => { +function Ek(e) { + return xt(e.registerCommand(At, ((t) => { const n = H(); return !!L(n) && (n.deleteCharacter(t), !0); }), oe), e.registerCommand(tr, ((t) => { @@ -9547,82 +9547,82 @@ function Tk(e) { if (typeof t == "string") n.insertText(t); else { const r = t.dataTransfer; - if (r != null) Ml(r, n); + if (r != null) Rl(r, n); else { const o = t.data; o && n.insertText(o); } } return !0; - }), oe), e.registerCommand(Pi, (() => { + }), oe), e.registerCommand(Oi, (() => { const t = H(); return !!L(t) && (t.removeText(), !0); }), oe), e.registerCommand(nn, ((t) => { const n = H(); return !!L(n) && (n.insertLineBreak(t), !0); - }), oe), e.registerCommand(Oi, (() => { + }), oe), e.registerCommand(Ti, (() => { const t = H(); return !!L(t) && (t.insertLineBreak(), !0); - }), oe), e.registerCommand(td, ((t) => { + }), oe), e.registerCommand(ed, ((t) => { const n = H(); if (!L(n)) return !1; const r = t, o = r.shiftKey; - return !!Dl(n, !0) && (r.preventDefault(), zl(n, o, !0), !0); - }), oe), e.registerCommand(ed, ((t) => { + return !!$l(n, !0) && (r.preventDefault(), Dl(n, o, !0), !0); + }), oe), e.registerCommand(Zu, ((t) => { const n = H(); if (!L(n)) return !1; const r = t, o = r.shiftKey; - return !!Dl(n, !1) && (r.preventDefault(), zl(n, o, !1), !0); - }), oe), e.registerCommand(od, ((t) => { + return !!$l(n, !1) && (r.preventDefault(), Dl(n, o, !1), !0); + }), oe), e.registerCommand(rd, ((t) => { const n = H(); - return !!L(n) && (!Ll || navigator.language !== "ko-KR") && (t.preventDefault(), e.dispatchCommand(At, !0)); - }), oe), e.registerCommand(sd, ((t) => { + return !!L(n) && (!Ml || navigator.language !== "ko-KR") && (t.preventDefault(), e.dispatchCommand(At, !0)); + }), oe), e.registerCommand(id, ((t) => { const n = H(); return !!L(n) && (t.preventDefault(), e.dispatchCommand(At, !1)); }), oe), e.registerCommand(rr, ((t) => { const n = H(); if (!L(n)) return !1; if (t !== null) { - if ((Ll || Ck || Ek) && _k) return !1; + if ((Ml || _k || jk) && Sk) return !1; t.preventDefault(); } return e.dispatchCommand(nn, !1); - }), oe), e.registerCommand($i, (() => (jx(), !0)), oe), e.registerCommand(Ss, ((t) => { + }), oe), e.registerCommand(Pi, (() => (Cx(), !0)), oe), e.registerCommand(ws, ((t) => { const n = H(); - return !!L(n) && (Fl(t, e), !0); - }), oe), e.registerCommand(_s, ((t) => { + return !!L(n) && (Ll(t, e), !0); + }), oe), e.registerCommand(Ss, ((t) => { const n = H(); return !!L(n) && ((function(r, o) { - Fl(r, o), o.update((() => { + Ll(r, o), o.update((() => { const i = H(); L(i) && i.removeText(); })); })(t, e), !0); - }), oe), e.registerCommand(xs, ((t) => { + }), oe), e.registerCommand(bs, ((t) => { const n = H(); return !!L(n) && ((function(r, o) { r.preventDefault(), o.update((() => { - const i = H(), s = Qd(r, ClipboardEvent) ? r.clipboardData : null; - s != null && L(i) && Ml(s, i); + const i = H(), s = Yd(r, ClipboardEvent) ? r.clipboardData : null; + s != null && L(i) && Rl(s, i); }), { tag: "paste" }); })(t, e), !0); - }), oe), e.registerCommand(ld, ((t) => { + }), oe), e.registerCommand(ad, ((t) => { const n = H(); return !!L(n) && (t.preventDefault(), !0); - }), oe), e.registerCommand(cd, ((t) => { + }), oe), e.registerCommand(ld, ((t) => { const n = H(); return !!L(n) && (t.preventDefault(), !0); }), oe)); } -const Vi = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? A.useLayoutEffect : A.useEffect; -function ql(e) { - return e.getEditorState().read(Xd(e.isComposing())); +const Hi = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? A.useLayoutEffect : A.useEffect; +function Fl(e) { + return e.getEditorState().read(Gd(e.isComposing())); } -function Xs({ contentEditable: e, placeholder: t = null, ErrorBoundary: n }) { +function Gs({ contentEditable: e, placeholder: t = null, ErrorBoundary: n }) { const [r] = Ee(), o = (function(i, s) { const [a, l] = A.useState((() => i.getDecorators())); - return Vi((() => i.registerDecoratorListener(((u) => { - yi.flushSync((() => { + return Hi((() => i.registerDecoratorListener(((u) => { + mi.flushSync((() => { l(u); })); }))), [i]), A.useEffect((() => { @@ -9631,49 +9631,49 @@ function Xs({ contentEditable: e, placeholder: t = null, ErrorBoundary: n }) { const u = [], d = Object.keys(a); for (let h = 0; h < d.length; h++) { const f = d[h], p = c.jsx(s, { onError: (m) => i._onError(m), children: c.jsx(A.Suspense, { fallback: null, children: a[f] }) }), g = i.getElementByKey(f); - g !== null && u.push(yi.createPortal(p, g, f)); + g !== null && u.push(mi.createPortal(p, g, f)); } return u; }), [s, a, i]); })(r, n); return (function(i) { - Vi((() => bt(Tk(i), bk(i))), [i]); - })(r), c.jsxs(c.Fragment, { children: [e, c.jsx(Ok, { content: t }), o] }); + Hi((() => xt(Ek(i), vk(i))), [i]); + })(r), c.jsxs(c.Fragment, { children: [e, c.jsx(Tk, { content: t }), o] }); } -function Ok({ content: e }) { +function Tk({ content: e }) { const [t] = Ee(), n = (function(o) { - const [i, s] = A.useState((() => ql(o))); - return Vi((() => { + const [i, s] = A.useState((() => Fl(o))); + return Hi((() => { function a() { - const l = ql(o); + const l = Fl(o); s(l); } - return a(), bt(o.registerUpdateListener((() => { + return a(), xt(o.registerUpdateListener((() => { a(); })), o.registerEditableListener((() => { a(); }))); }), [o]), i; - })(t), r = vk(); + })(t), r = yk(); return n ? typeof e == "function" ? e(r) : e : null; } -function Pk() { +function Ok() { const [e] = Ee(); return A.useEffect(() => e.registerNodeTransform(jn, (t) => { t.remove(); }), [e]), null; } -const $k = `background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px;`, Dk = `background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px;`; -class xt extends _t { +const Pk = `background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px;`, $k = `background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px;`; +class kt extends _t { __exists; static getType() { return "variable"; } static clone(t) { - return new xt(t.__text, t.__exists, t.__key); + return new kt(t.__text, t.__exists, t.__key); } static importJSON(t) { - const n = Wi(t.text, t.exists); + const n = Vi(t.text, t.exists); return n.setFormat(t.format), n.setDetail(t.detail), n.setMode(t.mode), n.setStyle(t.style), n; } constructor(t, n, r) { @@ -9689,7 +9689,7 @@ class xt extends _t { } createDOM(t) { const n = super.createDOM(t); - return this.__exists ? n.style.cssText = $k : n.style.cssText = Dk, n.className = "variable", n; + return this.__exists ? n.style.cssText = Pk : n.style.cssText = $k, n.className = "variable", n; } exportDOM() { const t = document.createElement("span"); @@ -9706,15 +9706,15 @@ class xt extends _t { return this.getLatest().__exists; } } -function Wi(e, t) { - return new xt(e, t); +function Vi(e, t) { + return new kt(e, t); } -function zk(e, t, n) { +function Dk(e, t, n) { const [r] = Ee(); - A.useEffect((() => bt(...Zx(r, e, t, n))), [n, r, e, t]); + A.useEffect((() => xt(...Jx(r, e, t, n))), [n, r, e, t]); } -const Bl = "startTransition", Ki = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, Ik = Ki ? A.useLayoutEffect : A.useEffect; -class Ak { +const ql = "startTransition", Wi = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, zk = Wi ? A.useLayoutEffect : A.useEffect; +class Ik { constructor(t) { this.key = t, this.ref = { current: null }, this.setRefElement = this.setRefElement.bind(this); } @@ -9722,17 +9722,17 @@ class Ak { this.ref = { current: t }; } } -const Ul = (e) => { +const Bl = (e) => { const t = document.getElementById("typeahead-menu"); if (!t) return; const n = t.getBoundingClientRect(); n.top + n.height > window.innerHeight && t.scrollIntoView({ block: "center" }), n.top < 0 && t.scrollIntoView({ block: "center" }), e.scrollIntoView({ block: "nearest" }); }; -function Hl(e, t) { +function Ul(e, t) { const n = e.getBoundingClientRect(), r = t.getBoundingClientRect(); return n.top > r.top && n.top < r.bottom; } -function Nk(e, t, n, r) { +function Ak(e, t, n, r) { const [o] = Ee(); A.useEffect((() => { if (t != null && e != null) { @@ -9743,12 +9743,12 @@ function Nk(e, t, n, r) { for (let y = h; y = y.parentElement; ) if (p = getComputedStyle(y), (!g || p.position !== "static") && m.test(p.overflow + p.overflowY + p.overflowX)) return y; return document.body; })(i) : document.body; - let a = !1, l = Hl(t, s); + let a = !1, l = Ul(t, s); const u = function() { a || (window.requestAnimationFrame((function() { n(), a = !1; })), a = !0); - const h = Hl(t, s); + const h = Ul(t, s); h !== l && (l = h, r?.(h)); }, d = new ResizeObserver(n); return window.addEventListener("resize", n), document.addEventListener("scroll", u, { capture: !0, passive: !0 }), d.observe(t), () => { @@ -9757,8 +9757,8 @@ function Nk(e, t, n, r) { } }), [t, o, r, n, e]); } -const Vl = Vb(); -function Rk({ close: e, editor: t, anchorElementRef: n, resolution: r, options: o, menuRenderFn: i, onSelectOption: s, shouldSplitNodeWithQuery: a = !1, commandPriority: l = $s, preselectFirstItem: u = !0 }) { +const Hl = Hb(); +function Nk({ close: e, editor: t, anchorElementRef: n, resolution: r, options: o, menuRenderFn: i, onSelectOption: s, shouldSplitNodeWithQuery: a = !1, commandPriority: l = Ps, preselectFirstItem: u = !0 }) { const [d, h] = A.useState(null), f = r.match && r.match.matchingString; A.useEffect((() => { u && h(0); @@ -9790,40 +9790,40 @@ function Rk({ close: e, editor: t, anchorElementRef: n, resolution: r, options: return A.useEffect((() => () => { const m = t.getRootElement(); m !== null && m.removeAttribute("aria-activedescendant"); - }), [t]), Ik((() => { + }), [t]), zk((() => { o === null ? h(null) : d === null && u && g(0); - }), [o, d, g, u]), A.useEffect((() => bt(t.registerCommand(Vl, (({ option: m }) => !(!m.ref || m.ref.current == null) && (Ul(m.ref.current), !0)), l))), [t, g, l]), A.useEffect((() => bt(t.registerCommand(rd, ((m) => { + }), [o, d, g, u]), A.useEffect((() => xt(t.registerCommand(Hl, (({ option: m }) => !(!m.ref || m.ref.current == null) && (Bl(m.ref.current), !0)), l))), [t, g, l]), A.useEffect((() => xt(t.registerCommand(nd, ((m) => { const y = m; if (o !== null && o.length) { const x = d === null ? 0 : d !== o.length - 1 ? d + 1 : 0; g(x); const k = o[x]; - k.ref != null && k.ref.current && t.dispatchCommand(Vl, { index: x, option: k }), y.preventDefault(), y.stopImmediatePropagation(); + k.ref != null && k.ref.current && t.dispatchCommand(Hl, { index: x, option: k }), y.preventDefault(), y.stopImmediatePropagation(); } return !0; - }), l), t.registerCommand(nd, ((m) => { + }), l), t.registerCommand(td, ((m) => { const y = m; if (o !== null && o.length) { const x = d === null ? o.length - 1 : d !== 0 ? d - 1 : o.length - 1; g(x); const k = o[x]; - k.ref != null && k.ref.current && Ul(k.ref.current), y.preventDefault(), y.stopImmediatePropagation(); + k.ref != null && k.ref.current && Bl(k.ref.current), y.preventDefault(), y.stopImmediatePropagation(); } return !0; - }), l), t.registerCommand(id, ((m) => { + }), l), t.registerCommand(od, ((m) => { const y = m; return y.preventDefault(), y.stopImmediatePropagation(), e(), !0; - }), l), t.registerCommand(ad, ((m) => { + }), l), t.registerCommand(sd, ((m) => { const y = m; return o !== null && d !== null && o[d] != null && (y.preventDefault(), y.stopImmediatePropagation(), p(o[d]), !0); }), l), t.registerCommand(rr, ((m) => o !== null && d !== null && o[d] != null && (m !== null && (m.preventDefault(), m.stopImmediatePropagation()), p(o[d]), !0)), l))), [p, e, t, o, d, g, l]), i(n, A.useMemo((() => ({ options: o, selectOptionAndCleanUp: p, selectedIndex: d, setHighlightedIndex: h })), [p, d, o]), r.match ? r.match.matchingString : ""); } -function Wl(e, t) { +function Vl(e, t) { t != null && (e.className = t), e.setAttribute("aria-label", "Typeahead menu"), e.setAttribute("role", "listbox"), e.style.display = "block", e.style.position = "absolute"; } -function Mk({ options: e, onQueryChange: t, onSelectOption: n, onOpen: r, onClose: o, menuRenderFn: i, triggerFn: s, anchorClassName: a, commandPriority: l = $s, parent: u, preselectFirstItem: d = !0 }) { - const [h] = Ee(), [f, p] = A.useState(null), g = (function(x, k, v, b = Ki ? document.body : void 0, j = !0) { - const [_] = Ee(), S = A.useRef(Ki ? document.createElement("div") : null), P = A.useCallback((() => { +function Rk({ options: e, onQueryChange: t, onSelectOption: n, onOpen: r, onClose: o, menuRenderFn: i, triggerFn: s, anchorClassName: a, commandPriority: l = Ps, parent: u, preselectFirstItem: d = !0 }) { + const [h] = Ee(), [f, p] = A.useState(null), g = (function(x, k, v, b = Wi ? document.body : void 0, j = !0) { + const [_] = Ee(), S = A.useRef(Wi ? document.createElement("div") : null), P = A.useCallback((() => { if (S.current === null || b === void 0) return; S.current.style.top = S.current.style.bottom; const C = _.getRootElement(), T = S.current, O = T.firstChild; @@ -9834,7 +9834,7 @@ function Mk({ options: e, onQueryChange: t, onSelectOption: n, onOpen: r, onClos const J = O.getBoundingClientRect(), X = J.height, re = J.width, ve = C.getBoundingClientRect(); I + re > ve.right && (T.style.left = `${ve.right - re + window.pageXOffset}px`), (N + X > window.innerHeight || N + X > ve.bottom) && N - ve.top > X + V && (T.style.top = `${N - X - V + (j ? window.pageYOffset : 0)}px`); } - T.isConnected || (Wl(T, v), b.append(T)), T.setAttribute("id", "typeahead-menu"), S.current = T, C.setAttribute("aria-controls", "typeahead-menu"); + T.isConnected || (Vl(T, v), b.append(T)), T.setAttribute("id", "typeahead-menu"), S.current = T, C.setAttribute("aria-controls", "typeahead-menu"); } }), [_, x, j, v, b]); A.useEffect((() => { @@ -9848,9 +9848,9 @@ function Mk({ options: e, onQueryChange: t, onSelectOption: n, onOpen: r, onClos const D = A.useCallback(((C) => { x !== null && (C || k(null)); }), [x, k]); - Nk(x, S.current, P, D); + Ak(x, S.current, P, D); const $ = S.current; - return $ != null && (Wl($, v), b?.append($)), S; + return $ != null && (Vl($, v), b?.append($)), S; })(f, p, a, u), m = A.useCallback((() => { p(null), o != null && f !== null && o(); }), [o, f]), y = A.useCallback(((x) => { @@ -9886,7 +9886,7 @@ function Mk({ options: e, onQueryChange: t, onSelectOption: n, onOpen: r, onClos return !1; })); })(h, _.leadOffset) && (function(D, $, C) { - const T = Je(C); + const T = Ze(C); if (T === null || !T.isCollapsed) return !1; const O = T.anchorNode, I = D, N = T.anchorOffset; if (O == null || N == null) return !1; @@ -9897,7 +9897,7 @@ function Mk({ options: e, onQueryChange: t, onSelectOption: n, onOpen: r, onClos } return !0; })(_.leadOffset, v, k) !== null) - return S = () => y({ getRect: () => v.getBoundingClientRect(), match: _ }), void (Bl in ln ? ln[Bl](S) : S()); + return S = () => y({ getRect: () => v.getBoundingClientRect(), match: _ }), void (ql in ln ? ln[ql](S) : S()); var S; m(); })); @@ -9907,10 +9907,10 @@ function Mk({ options: e, onQueryChange: t, onSelectOption: n, onOpen: r, onClos }; }), [h, s, t, f, m, y]), A.useEffect((() => h.registerEditableListener(((x) => { x || m(); - }))), [h, m]), f === null || h === null || g.current === null ? null : c.jsx(Rk, { close: m, resolution: f, editor: h, anchorElementRef: g, options: e, menuRenderFn: i, shouldSplitNodeWithQuery: !0, onSelectOption: n, commandPriority: l, preselectFirstItem: d }); + }))), [h, m]), f === null || h === null || g.current === null ? null : c.jsx(Nk, { close: m, resolution: f, editor: h, anchorElementRef: g, options: e, menuRenderFn: i, shouldSplitNodeWithQuery: !0, onSelectOption: n, commandPriority: l, preselectFirstItem: d }); } -const Lk = 100; -function Fk(e, t) { +const Mk = 100; +function Lk(e, t) { const n = /({{([\w.\-$^}]*))/.exec(e); if (n !== null) { const r = n[2]; @@ -9923,16 +9923,16 @@ function Fk(e, t) { } return null; } -function qk(e) { - return Fk(e, 0); +function Fk(e) { + return Lk(e, 0); } -class Bk extends Ak { +class qk extends Ik { name; constructor(t) { super(t), this.name = t; } } -function Uk({ +function Bk({ index: e, isSelected: t, onClick: n, @@ -9956,12 +9956,12 @@ function Uk({ o.key ); } -function ef({ +function Zd({ variables: e }) { const [t] = Ee(), n = A.useCallback((h) => { const f = h.getTextContent().slice(2, -2); - return Wi(h.getTextContent(), e.includes(f)); + return Vi(h.getTextContent(), e.includes(f)); }, []), r = A.useCallback((h) => { const f = /({{[\w-$]+}})/.exec(h); if (f === null) @@ -9972,9 +9972,9 @@ function ef({ end: m }; }, []); - zk(r, xt, n), A.useEffect(() => { + Dk(r, kt, n), A.useEffect(() => { t.registerMutationListener( - xt, + kt, (h) => { t.update(() => { for (let [f, p] of h) @@ -9997,30 +9997,30 @@ function ef({ ); }, [e, o]); const l = A.useMemo( - () => s.map((h) => new Bk(h)).slice(0, Lk), + () => s.map((h) => new qk(h)).slice(0, Mk), [s] ), u = A.useCallback( (h, f, p) => { t.update(() => { - const g = Wi("{{" + h.name + "}}", !0); + const g = Vi("{{" + h.name + "}}", !0); f && f.replace(g), g.select(), p(); }); }, [t] ), d = A.useCallback( - (h) => qk(h), + (h) => Fk(h), [t] ); return /* @__PURE__ */ c.jsx( - Mk, + Rk, { onQueryChange: i, onSelectOption: u, triggerFn: d, options: l, - menuRenderFn: (h, { selectedIndex: f, selectOptionAndCleanUp: p, setHighlightedIndex: g }) => h.current && s.length ? yi.createPortal( - /* @__PURE__ */ c.jsx(Hk, { children: /* @__PURE__ */ c.jsx("ul", { children: l.map((m, y) => /* @__PURE__ */ c.jsx( - Uk, + menuRenderFn: (h, { selectedIndex: f, selectOptionAndCleanUp: p, setHighlightedIndex: g }) => h.current && s.length ? mi.createPortal( + /* @__PURE__ */ c.jsx(Uk, { children: /* @__PURE__ */ c.jsx("ul", { children: l.map((m, y) => /* @__PURE__ */ c.jsx( + Bk, { index: y, isSelected: f === y, @@ -10039,7 +10039,7 @@ function ef({ } ); } -const Hk = E.div` +const Uk = E.div` margin-top: 20px; background-color: var(${w.dropdownBackground}); border: 1px solid var(${w.dropdownBorder}); @@ -10076,7 +10076,7 @@ const Hk = E.div` width: 4px; } `; -function Bo({ +function qo({ name: e, variables: t, encode: n, @@ -10106,24 +10106,24 @@ function Bo({ paragraph: "editor-paragraph" }, onError: s, - nodes: [xt] + nodes: [kt] }; - return /* @__PURE__ */ c.jsx(Vk, { ...o, onBlur: i.onBlur, children: /* @__PURE__ */ c.jsx(Vs, { initialConfig: a, children: /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ + return /* @__PURE__ */ c.jsx(Hk, { ...o, onBlur: i.onBlur, children: /* @__PURE__ */ c.jsx(Hs, { initialConfig: a, children: /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx( - Xs, + Gs, { - contentEditable: /* @__PURE__ */ c.jsx(Ws, {}), + contentEditable: /* @__PURE__ */ c.jsx(Vs, {}), placeholder: /* @__PURE__ */ c.jsx("div", {}), - ErrorBoundary: Ks + ErrorBoundary: Ws } ), - /* @__PURE__ */ c.jsx(Gs, {}), - t !== void 0 && /* @__PURE__ */ c.jsx(ef, { variables: t }), - /* @__PURE__ */ c.jsx(Wk, { name: e, decode: r }), - /* @__PURE__ */ c.jsx(Pk, {}) + /* @__PURE__ */ c.jsx(Ks, {}), + t !== void 0 && /* @__PURE__ */ c.jsx(Zd, { variables: t }), + /* @__PURE__ */ c.jsx(Vk, { name: e, decode: r }), + /* @__PURE__ */ c.jsx(Ok, {}) ] }) }) }); } -const Vk = E.div` +const Hk = E.div` background: transparent; padding: 2px; color: var(${w.foreground}); @@ -10139,7 +10139,7 @@ const Vk = E.div` margin: 0; } `; -function Wk({ name: e, decode: t }) { +function Vk({ name: e, decode: t }) { const [n] = Ee(), { field: r } = ie({ name: e }); @@ -10152,21 +10152,21 @@ function Wk({ name: e, decode: t }) { r.onChange(a); } }), i = n.registerCommand( - ud, + cd, (s, a) => (r.onBlur(), !1), - $s + Ps ); return () => { o(), i(); }; }, [n, r]), null; } -function Kk({ +function Wk({ name: e, remove: t, variables: n }) { - const { control: r } = ar(), { + const { control: r } = sr(), { field: o, fieldState: { error: i } } = ie({ @@ -10174,8 +10174,8 @@ function Kk({ control: r, rules: { pattern: { - value: Ic(), - message: Ac + value: zc(), + message: Ic } } }), { field: s } = ie({ @@ -10184,19 +10184,19 @@ function Kk({ }), { field: a } = ie({ name: `${e}.type`, control: r - }), l = Gk(s.value); - return /* @__PURE__ */ c.jsxs(Xk, { children: [ - /* @__PURE__ */ c.jsxs(Yk, { children: [ - /* @__PURE__ */ c.jsx(Qk, { type: "text", ...o }), - /* @__PURE__ */ c.jsx(Jk, { variables: n, name: `${e}.value` }), - /* @__PURE__ */ c.jsxs(Zk, { ...a, children: [ + }), l = Kk(s.value); + return /* @__PURE__ */ c.jsxs(Gk, { children: [ + /* @__PURE__ */ c.jsxs(Xk, { children: [ + /* @__PURE__ */ c.jsx(Yk, { type: "text", ...o }), + /* @__PURE__ */ c.jsx(Qk, { variables: n, name: `${e}.value` }), + /* @__PURE__ */ c.jsxs(Jk, { ...a, children: [ /* @__PURE__ */ c.jsx("option", { value: "string", children: "string" }), /* @__PURE__ */ c.jsx("option", { value: "number", disabled: !l.has("number"), children: "number" }), /* @__PURE__ */ c.jsx("option", { value: "boolean", disabled: !l.has("boolean"), children: "boolean" }), /* @__PURE__ */ c.jsx("option", { value: "null", disabled: !l.has("null"), children: "null" }) ] }), /* @__PURE__ */ c.jsx( - ew, + Zk, { onClick: (u) => { u.preventDefault(), u.stopPropagation(), t(); @@ -10205,14 +10205,14 @@ function Kk({ } ) ] }), - i && /* @__PURE__ */ c.jsxs(tw, { children: [ - /* @__PURE__ */ c.jsx(xo, {}), + i && /* @__PURE__ */ c.jsxs(ew, { children: [ + /* @__PURE__ */ c.jsx(bo, {}), "  ", i.message ] }) ] }); } -function Gk(e) { +function Kk(e) { const t = /* @__PURE__ */ new Set(["string"]); try { const r = typeof JSON.parse(e); @@ -10221,31 +10221,31 @@ function Gk(e) { } return t; } -const Xk = E.div` +const Gk = E.div` display: contents; -`, Yk = E.div` +`, Xk = E.div` display: contents; &:hover > :last-child { opacity: 1; } -`, Qk = E.input` +`, Yk = E.input` flex: 1; border: none; background: transparent; border-bottom: 1px solid var(${w.border}); color: var(${w.foreground}); padding: 4px 8px; -`, Jk = E(Bo)` +`, Qk = E(qo)` flex: 2; border-bottom: 1px solid var(${w.border}); padding: 4px 8px; -`, Zk = E.select` +`, Jk = E.select` border: none; background: transparent; color: var(${w.foreground}); border-bottom: 1px solid var(${w.border}); padding: 4px 8px; -`, ew = E.button` +`, Zk = E.button` background: none; border: none; padding: 0; @@ -10258,25 +10258,25 @@ const Xk = E.div` > svg { fill: var(${w.foreground}); } -`, tw = E.div` +`, ew = E.div` padding: 4px; display: flex; `; -function nw({ name: e, append: t }) { +function tw({ name: e, append: t }) { return /* @__PURE__ */ c.jsxs( - rw, + nw, { onClick: (n) => { n.preventDefault(), n.stopPropagation(), t({ key: e, value: "", type: "string" }, { shouldFocus: !0 }); }, children: [ /* @__PURE__ */ c.jsx("span", { children: e }), - /* @__PURE__ */ c.jsx(rp, {}) + /* @__PURE__ */ c.jsx(np, {}) ] } ); } -const rw = E.span` +const nw = E.span` display: flex; align-items: center; gap: 2px; @@ -10286,24 +10286,24 @@ const rw = E.span` fill: var(${w.linkForeground}); } `; -function Uo({ +function Bo({ name: e, variables: t, missing: n }) { - const { control: r } = ar(), { fields: o, append: i, remove: s } = vn({ + const { control: r } = sr(), { fields: o, append: i, remove: s } = vn({ control: r, name: e }); - return /* @__PURE__ */ c.jsxs(ow, { children: [ - /* @__PURE__ */ c.jsxs(iw, { children: [ + return /* @__PURE__ */ c.jsxs(rw, { children: [ + /* @__PURE__ */ c.jsxs(ow, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", { children: "Value" }), /* @__PURE__ */ c.jsx("div", { children: "Type" }), /* @__PURE__ */ c.jsx("div", {}) ] }), o.map((a, l) => /* @__PURE__ */ c.jsx( - Kk, + Wk, { name: `${e}.${l}`, variables: t, @@ -10313,21 +10313,21 @@ function Uo({ }, a.id )), - /* @__PURE__ */ c.jsx(hb, { append: i }), - n && n?.length > 0 && /* @__PURE__ */ c.jsxs(sw, { children: [ - /* @__PURE__ */ c.jsx(wt, {}), + /* @__PURE__ */ c.jsx(fb, { append: i }), + n && n?.length > 0 && /* @__PURE__ */ c.jsxs(iw, { children: [ + /* @__PURE__ */ c.jsx(St, {}), " ", /* @__PURE__ */ c.jsx("span", { className: "message", children: "Unset variables" }), - n.map((a) => /* @__PURE__ */ c.jsx(nw, { name: a, append: i }, a)) + n.map((a) => /* @__PURE__ */ c.jsx(tw, { name: a, append: i }, a)) ] }) ] }); } -const ow = E.div` +const rw = E.div` margin: 8px; display: grid; row-gap: 4px; grid-template-columns: 1fr 2fr 7em 2em; -`, iw = E.div` +`, ow = E.div` display: contents; > div { background-color: var(${w.computedOne}); @@ -10336,7 +10336,7 @@ const ow = E.div` font-size: 90%; font-weight: 600; } -`, sw = E.div` +`, iw = E.div` margin-top: 8px; padding: 8px; border: 1px solid var(${w.border}); @@ -10351,93 +10351,93 @@ const ow = E.div` color: var(${w.errorForeground}); } `; -function aw(e, t, n) { - return (Zi(e, t, n)?.security ?? e.security ?? []).length > 0; +function sw(e, t, n) { + return (Ji(e, t, n)?.security ?? e.security ?? []).length > 0; } -function Aj(e) { - return e = St.simpleClone(e), { +function Ij(e) { + return e = Re.simpleClone(e), { ...e, fuzzing: e.fuzzing === !0, expectedResponse: e.expectedResponse !== void 0 ? e.expectedResponse : "", - environment: Ys(e.environment), - responses: Qs(e.responses) + environment: Xs(e.environment), + responses: Ys(e.responses) }; } -function Nj(e) { +function Aj(e) { return { ...e, fuzzing: e.fuzzing === !0 ? !0 : void 0, expectedResponse: e.expectedResponse !== "" ? e.expectedResponse : void 0, - environment: Zs(e.environment), - responses: Js(e.responses) + environment: Js(e.environment), + responses: Qs(e.responses) }; } -function lw(e) { - return e = St.simpleClone(e), { +function aw(e) { + return e = Re.simpleClone(e), { path: e.request.path, method: e.request.method, parameters: e.request.parameters, body: e.request.body, - environment: Ys(e.environment), + environment: Xs(e.environment), defaultResponse: e.defaultResponse, injectionKey: e.injectionKey, fuzzing: e.fuzzing, operationId: e.operationId, requestOperationId: e.request.operationId, - responses: Qs(e.responses), + responses: Ys(e.responses), auth: e.auth }; } -function cw(e) { - return e = St.simpleClone(e), { +function lw(e) { + return e = Re.simpleClone(e), { url: e.request.url, method: e.request.method, parameters: e.request.parameters, body: e.request.body, - environment: Ys(e.environment), + environment: Xs(e.environment), defaultResponse: e.defaultResponse, - responses: Qs(e.responses) + responses: Ys(e.responses) }; } -function Ys(e) { +function Xs(e) { return Object.entries(e || {}).map(([n, r]) => ({ key: n, value: r, type: typeof r })); } -function Qs(e) { +function Ys(e) { return Object.entries(e || {}).map(([t, n]) => ({ key: t, value: { ...n, - variableAssignments: uw(n.variableAssignments) + variableAssignments: cw(n.variableAssignments) } })); } -function Js(e) { +function Qs(e) { const t = {}; for (const { key: n, value: r } of e) t[n] = { ...r, - variableAssignments: dw(r.variableAssignments) + variableAssignments: uw(r.variableAssignments) }; return t; } -function uw(e) { +function cw(e) { return Object.entries(e || {}).map(([t, n]) => ({ key: t, value: n })); } -function dw(e) { +function uw(e) { const t = {}; for (const { key: n, value: r } of e) t[n] = r; return t; } -function fw(e) { - return e = St.simpleClone(e), { +function dw(e) { + return e = Re.simpleClone(e), { ref: void 0, request: { path: e.path, @@ -10448,34 +10448,34 @@ function fw(e) { }, fuzzing: e.fuzzing, injectionKey: e.injectionKey, - environment: Zs(e.environment), + environment: Js(e.environment), defaultResponse: e.defaultResponse, - responses: Js(e.responses), + responses: Qs(e.responses), auth: e.auth, operationId: e.operationId }; } -function hw(e) { - return e = St.simpleClone(e), { +function fw(e) { + return e = Re.simpleClone(e), { request: { url: e.url, method: e.method, parameters: e.parameters, body: e.body }, - environment: Zs(e.environment), + environment: Js(e.environment), defaultResponse: e.defaultResponse, - responses: Js(e.responses), + responses: Qs(e.responses), operationId: void 0 }; } -function Zs(e) { +function Js(e) { const t = {}; for (const n of e) - t[n.key] = pw(n.value, n.type); + t[n.key] = hw(n.value, n.type); return t; } -function pw(e, t) { +function hw(e, t) { if (t !== "string") try { return JSON.parse(e); @@ -10484,7 +10484,7 @@ function pw(e, t) { } return `${e}`; } -function tf({ +function ef({ name: e, options: t, placeholder: n @@ -10504,7 +10504,7 @@ function tf({ } ); } -function gw({ +function pw({ options: e, placeholder: t, selected: n, @@ -10516,7 +10516,7 @@ function gw({ e.filter((f) => o === "" || f.toLowerCase().includes(o.toLowerCase())) ); }, [o, e]); - const { isOpen: l, getMenuProps: u, getInputProps: d, getItemProps: h } = Gc({ + const { isOpen: l, getMenuProps: u, getInputProps: d, getItemProps: h } = Kc({ initialInputValue: n, items: s, onInputValueChange: ({ inputValue: f }) => { @@ -10524,9 +10524,9 @@ function gw({ }, itemToString: (f) => f || "" }); - return /* @__PURE__ */ c.jsxs(mw, { children: [ - /* @__PURE__ */ c.jsx(yw, { ...d(), placeholder: t }), - /* @__PURE__ */ c.jsx(vw, { $visible: l && s.length > 0, children: /* @__PURE__ */ c.jsx(bw, { ...u(), children: s.map((f, p) => /* @__PURE__ */ c.jsx( + return /* @__PURE__ */ c.jsxs(gw, { children: [ + /* @__PURE__ */ c.jsx(mw, { ...d(), placeholder: t }), + /* @__PURE__ */ c.jsx(yw, { $visible: l && s.length > 0, children: /* @__PURE__ */ c.jsx(vw, { ...u(), children: s.map((f, p) => /* @__PURE__ */ c.jsx( "li", { ...h({ @@ -10539,14 +10539,14 @@ function gw({ )) }) }) ] }); } -const mw = E.div` +const gw = E.div` display: flex; flex-direction: column; &:focus-within { border: 1px solid var(${w.focusBorder}); } border: 1px solid transparent; -`, yw = E.input` +`, mw = E.input` background: transparent; border: none; color: var(${w.foreground}); @@ -10557,11 +10557,11 @@ const mw = E.div` &:focus { outline: none; } -`, vw = E.div` +`, yw = E.div` position: relative; z-index: 1; visibility: ${({ $visible: e }) => e ? "visible" : "hidden"}; -`, bw = E.ul` +`, vw = E.ul` border: 1px solid var(${w.dropdownBorder}); background-color: var(${w.dropdownBackground}); color: var(${w.dropdownForeground}); @@ -10579,20 +10579,20 @@ const mw = E.div` background-color: var(${w.listHoverBackground}); } `; -function nf({ +function tf({ onTry: e, onScan: t, servers: n, menu: r }) { - const { scanServer: o, useGlobalBlocks: i, rejectUnauthorized: s } = qh( + const { scanServer: o, useGlobalBlocks: i, rejectUnauthorized: s } = Fh( (g) => g.prefs - ), a = Bh(), l = (g) => a(Uh(g)), u = (g) => a(Hh(g)), d = (g) => a(Vh(g)), h = [...n], [f, p] = A.useState( + ), a = qh(), l = (g) => a(Bh(g)), u = (g) => a(Uh(g)), d = (g) => a(Hh(g)), h = [...n], [f, p] = A.useState( o !== "" ? o : h[0] ); - return !h.includes(o) && o !== "" && h.push(o), /* @__PURE__ */ c.jsx(kw, { children: /* @__PURE__ */ c.jsxs(xw, { children: [ + return !h.includes(o) && o !== "" && h.push(o), /* @__PURE__ */ c.jsx(xw, { children: /* @__PURE__ */ c.jsxs(bw, { children: [ /* @__PURE__ */ c.jsx( - gw, + pw, { options: h, selected: f, @@ -10602,50 +10602,50 @@ function nf({ } ), /* @__PURE__ */ c.jsxs( - Kl, + Wl, { onClick: (g) => { g.stopPropagation(), g.preventDefault(), e(f); }, children: [ - /* @__PURE__ */ c.jsx(bh, {}), + /* @__PURE__ */ c.jsx(vh, {}), "Try" ] } ), t && /* @__PURE__ */ c.jsxs( - Kl, + Wl, { onClick: (g) => { g.stopPropagation(), g.preventDefault(), t(f); }, children: [ - /* @__PURE__ */ c.jsx(tp, {}), + /* @__PURE__ */ c.jsx(ep, {}), "Scan" ] } ), - r && /* @__PURE__ */ c.jsx(ww, { children: /* @__PURE__ */ c.jsxs(Vc, { icon: "sliders", children: [ - /* @__PURE__ */ c.jsx(xh, { children: "Try settings" }), - /* @__PURE__ */ c.jsx(kh, {}), + r && /* @__PURE__ */ c.jsx(kw, { children: /* @__PURE__ */ c.jsxs(Hc, { icon: "sliders", children: [ + /* @__PURE__ */ c.jsx(bh, { children: "Try settings" }), + /* @__PURE__ */ c.jsx(xh, {}), /* @__PURE__ */ c.jsxs( - ka, + xa, { checked: i, onCheckedChange: (g) => u(g), children: [ - /* @__PURE__ */ c.jsx(wa, {}), + /* @__PURE__ */ c.jsx(ka, {}), "Execute global blocks" ] } ), /* @__PURE__ */ c.jsxs( - ka, + xa, { checked: s, onCheckedChange: (g) => d(g), children: [ - /* @__PURE__ */ c.jsx(wa, {}), + /* @__PURE__ */ c.jsx(ka, {}), "Reject untrusted SSL certificates" ] } @@ -10653,7 +10653,7 @@ function nf({ ] }) }) ] }) }); } -const xw = E.div` +const bw = E.div` border: 1px solid var(${w.border}); display: flex; align-items: center; @@ -10663,10 +10663,10 @@ const xw = E.div` & > div:first-child { flex: 1; } -`, kw = E.div` +`, xw = E.div` background-color: var(${w.background}); color: var(${w.foreground}); -`, Kl = E.div` +`, Wl = E.div` display: flex; padding: 8px 12px; gap: 4px; @@ -10676,10 +10676,10 @@ const xw = E.div` > svg { fill: var(${w.linkForeground}); } -`, ww = E.div` +`, kw = E.div` display: flex; padding: 8px 12px; -`, Rj = E.button` +`, Nj = E.button` cursor: pointer; background-color: var(${w.buttonBackground}); color: var(${w.buttonForeground}); @@ -10690,7 +10690,7 @@ const xw = E.div` outline: 1px solid var(${w.focusBorder}); } `; -function Mj({ +function Rj({ label: e, name: t, title: n, @@ -10700,25 +10700,25 @@ function Mj({ const { field: i, fieldState: { error: s, invalid: a } - } = ie({ name: t }), l = dm(), [u, d] = A.useState(void 0), h = async () => { + } = ie({ name: t }), l = um(), [u, d] = A.useState(void 0), h = async () => { const p = await l(n, r); p !== void 0 && (i.onChange(p.content), d(p.filename)); }, f = u !== void 0 ? u : i.value ? `${String(i.value).substring(0, 32)}…` : "No file selected"; return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsx(Sw, { children: /* @__PURE__ */ c.jsxs(_w, { $invalid: a, children: [ - /* @__PURE__ */ c.jsxs(Tw, { children: [ + /* @__PURE__ */ c.jsx(ww, { children: /* @__PURE__ */ c.jsxs(Sw, { $invalid: a, children: [ + /* @__PURE__ */ c.jsxs(Ew, { children: [ /* @__PURE__ */ c.jsx("div", { children: e }), o && /* @__PURE__ */ c.jsx(bn, { children: o }) ] }), - /* @__PURE__ */ c.jsxs(Cw, { children: [ - /* @__PURE__ */ c.jsx(jw, { $empty: u === void 0 && !i.value, children: f }), - /* @__PURE__ */ c.jsx(Ew, { type: "button", onClick: h, children: "Browse" }) + /* @__PURE__ */ c.jsxs(_w, { children: [ + /* @__PURE__ */ c.jsx(Cw, { $empty: u === void 0 && !i.value, children: f }), + /* @__PURE__ */ c.jsx(jw, { type: "button", onClick: h, children: "Browse" }) ] }) ] }) }), - s && /* @__PURE__ */ c.jsx(Ow, { children: s?.message }) + s && /* @__PURE__ */ c.jsx(Tw, { children: s?.message }) ] }); } -const Sw = E.div` +const ww = E.div` display: flex; flow-direction: column; gap: 4px; @@ -10730,7 +10730,7 @@ const Sw = E.div` align-items: center; justify-content: center; } -`, _w = E.div` +`, Sw = E.div` background-color: var(${w.inputBackground}); border-radius: 2px; display: flex; @@ -10739,11 +10739,11 @@ const Sw = E.div` gap: 4px; ${({ $invalid: e }) => e ? `border: 1px solid var(${w.errorBorder});` : `border: 1px solid var(${w.border});`} -`, Cw = E.div` +`, _w = E.div` display: flex; align-items: center; gap: 8px; -`, jw = E.div` +`, Cw = E.div` flex: 1; line-height: 20px; overflow: hidden; @@ -10752,7 +10752,7 @@ const Sw = E.div` color: var( ${({ $empty: e }) => e ? w.inputPlaceholderForeground : w.foreground} ); -`, Ew = E.button` +`, jw = E.button` cursor: pointer; border: none; padding: 4px 12px; @@ -10762,7 +10762,7 @@ const Sw = E.div` &:focus { outline: none; } -`, Tw = E.div` +`, Ew = E.div` display: flex; justify-content: space-between; font-style: normal; @@ -10770,12 +10770,12 @@ const Sw = E.div` font-size: 12px; line-height: 16px; color: var(${w.inputPlaceholderForeground}); -`, Ow = E.div` +`, Tw = E.div` color: var(${w.errorForeground}); `; -function Lj(e) { +function Mj(e) { return () => e({ - actionCreator: Yf, + actionCreator: Xf, effect: async (t, n) => { const r = n.getOriginalState().confirmationDialog.actions; for (const o of r) @@ -10783,32 +10783,32 @@ function Lj(e) { } }); } -function Pw() { +function Ow() { return /* @__PURE__ */ new Map(); } -function $w(e, t, n, r) { - const o = t.ttl !== void 0 ? Ev(t.ttl) : void 0; +function Pw(e, t, n, r) { + const o = t.ttl !== void 0 ? jv(t.ttl) : void 0; if (o !== void 0) { const i = `${t.name}/${n}`, s = Date.now() + o; e.set(i, { value: r, expiryTime: s }); } } -function Dw(e, t, n) { +function $w(e, t, n) { const r = `${t.name}/${n}`, o = e.get(r); if (o && Date.now() < o.expiryTime) return o.value; e.delete(r); } -function ea(e, t) { +function Zs(e, t) { return t.type === e.type && t.in === e.in || t.type === "http" && e.type == "basic" && t.in === e.in || t.type === "basic" && e.type == "basic" && t.in === e.in ? !0 : t.type === "http" && t.scheme == "bearer" && e.type === "bearer"; } -function zw(e, t, n) { - const r = Nc(e, e.paths[t]), o = sr(e, t, n), i = Rc(e, o); - return Mc(e, r, i); +function Dw(e, t, n) { + const r = Ac(e, e.paths[t]), o = ar(e, t, n), i = Nc(e, o); + return Rc(e, r, i); } -async function Iw(e, t, n, r, o) { +async function zw(e, t, n, r, o) { try { - const i = Lc(e) ? await Aw(e, t, n, r, o) : await Nw(e, t, n, r, o); + const i = Mc(e) ? await Iw(e, t, n, r, o) : await Aw(e, t, n, r, o); for (const { key: s, value: a } of r.parameters.header) i.headers[s.toLowerCase()] === void 0 && (i.headers[s] = String(a)); return [ @@ -10816,7 +10816,7 @@ async function Iw(e, t, n, r, o) { method: r.method, url: i.url, headers: i.headers, - body: rf(i.body) + body: nf(i.body) }, void 0 ]; @@ -10824,54 +10824,54 @@ async function Iw(e, t, n, r, o) { return [void 0, `failed to build http request: ${i}`]; } } -async function Aw(e, t, n, r, o) { - const i = Zi(e, r.path, r.method); +async function Iw(e, t, n, r, o) { + const i = Ji(e, r.path, r.method); if (i === void 0) throw new Error(`operation not found for ${r.method} ${r.path}`); - const s = af( + const s = sf( r.method, r.path, i - ), a = Ww(r); + ), a = Vw(r); return lr.buildRequest({ - spec: await Mw(e, t), + spec: await Rw(e, t), operationId: s, - parameters: Fw(r.parameters, o), - securities: Bw(e, o), + parameters: Lw(r.parameters, o), + securities: qw(e, o), requestContentType: a, requestBody: r.body?.value }); } -async function Nw(e, t, n, r, o) { - const i = sr(e, r.path, r.method); +async function Aw(e, t, n, r, o) { + const i = ar(e, r.path, r.method); if (i === void 0) throw new Error(`operation not found for ${r.method} ${r.path}`); - const s = af( + const s = sf( r.method, r.path, i ); return lr.buildRequest({ - spec: await Lw(e, t), + spec: await Mw(e, t), operationId: s, - parameters: qw(e, r, o), - securities: Hw(e?.securityDefinitions || {}, o) + parameters: Fw(e, r, o), + securities: Uw(e?.securityDefinitions || {}, o) }); } -async function Rw(e) { +async function Nw(e) { const t = new URLSearchParams( - Gl(e.parameters.query) + Kl(e.parameters.query) ).toString(); try { - const n = Gl(e.parameters.header); + const n = Kl(e.parameters.header); e.body?.mediaType !== void 0 && (n["Content-Type"] = e.body?.mediaType); - const r = e.body?.mediaType === "application/x-www-form-urlencoded" ? Vw(e.body.value) : e.body?.value; + const r = e.body?.mediaType === "application/x-www-form-urlencoded" ? Hw(e.body.value) : e.body?.value; return [ { method: e.method, url: t === "" ? e.url : `${e.url}?${t}`, headers: n, - body: rf(r) + body: nf(r) }, void 0 ]; @@ -10879,19 +10879,19 @@ async function Rw(e) { return [void 0, `failed to build http request: ${n}`]; } } -async function Mw(e, t, n) { +async function Rw(e, t, n) { const r = [{ url: t }], { spec: o, errors: i } = await lr.resolve({ spec: JSON.parse(JSON.stringify({ ...e, servers: r })) }); return o; } -async function Lw(e, t, n) { +async function Mw(e, t, n) { const r = new URL(t), o = r.protocol === "https:" ? ["https"] : ["http"], { spec: i, errors: s } = await lr.resolve({ spec: JSON.parse(JSON.stringify({ ...e, host: r.host, schemes: o })) }); return i; } -function rf(e) { +function nf(e) { if (e !== void 0) { { if (typeof e == "string") @@ -10902,24 +10902,24 @@ function rf(e) { return JSON.stringify(e); } } -function Fw(e, t) { - const n = ["path", "query", "header", "cookie"], r = of(e, n); +function Lw(e, t) { + const n = ["path", "query", "header", "cookie"], r = rf(e, n); for (const { credential: o, value: i } of Object.values(t)) n.includes(o.in) && o.name !== void 0 && (r[`${o.in}.${o.name}`] = i); return r; } -function qw(e, t, n) { - const r = ["path", "query", "header"], o = of(t.parameters, r); +function Fw(e, t, n) { + const r = ["path", "query", "header"], o = rf(t.parameters, r); for (const { credential: a, value: l } of Object.values(n)) r.includes(a.in) && a.name !== void 0 && (o[`${a.in}.${a.name}`] = l); - const i = zw(e, t.path, t.method), s = Object.keys(i.body); + const i = Dw(e, t.path, t.method), s = Object.keys(i.body); if (s.length > 0) { const a = s[0]; o[`body.${a}`] = t.body?.value; } return o; } -function of(e, t) { +function rf(e, t) { const n = {}; for (const r of t) for (const { key: o, value: i } of e[r]) { @@ -10928,15 +10928,15 @@ function of(e, t) { } return n; } -function Bw(e, t) { - const n = Uw(e), r = sf(n, t), o = {}; +function qw(e, t) { + const n = Bw(e), r = of(n, t), o = {}; for (const i of Object.keys(r)) { const s = Xn(e, n[i]), a = r[i]; - a !== void 0 && (s?.type === "oauth2" || s?.type === "openIdConnect" ? o[i] = { token: { access_token: a } } : s?.type === "http" && s.scheme !== void 0 && /^basic$/i.test(s.scheme) ? o[i] = lf(a) : o[i] = a); + a !== void 0 && (s?.type === "oauth2" || s?.type === "openIdConnect" ? o[i] = { token: { access_token: a } } : s?.type === "http" && s.scheme !== void 0 && /^basic$/i.test(s.scheme) ? o[i] = af(a) : o[i] = a); } return { authorized: o }; } -function Uw(e) { +function Bw(e) { const t = {}; for (const [n, r] of Object.entries(e.components?.securitySchemes || {})) { const o = Xn(e, r); @@ -10944,40 +10944,40 @@ function Uw(e) { } return t; } -function Hw(e, t) { - const n = {}, r = sf(e, t); +function Uw(e, t) { + const n = {}, r = of(e, t); for (const o of Object.keys(r)) { const i = e[o], s = r[o]; - s !== void 0 && (i?.type === "oauth2" ? n[o] = { token: { access_token: s } } : i?.type === "basic" ? n[o] = lf(s) : n[o] = s); + s !== void 0 && (i?.type === "oauth2" ? n[o] = { token: { access_token: s } } : i?.type === "basic" ? n[o] = af(s) : n[o] = s); } return { authorized: n }; } -function sf(e, t) { +function of(e, t) { const n = { ...t }, r = {}; for (const [o, i] of Object.entries(e)) for (const [s, { credential: a, value: l }] of Object.entries(n)) - if (ea(a, i)) { + if (Zs(a, i)) { r[o] = l, delete n[s]; break; } return r; } -function Gl(e) { +function Kl(e) { const t = {}; for (const { key: n, value: r } of e) t[n] = String(r); return t; } -function Vw(e) { +function Hw(e) { const t = new URLSearchParams(); for (const [n, r] of Object.entries(e)) t.append(n, `${r}`); return t.toString(); } -function af(e, t, n) { +function sf(e, t, n) { return lr.helpers.opId(n, t, e); } -function Ww(e) { +function Vw(e) { if (e.body?.mediaType === "raw") { for (const { key: t, value: n } of e.parameters.header) if (t.toLowerCase() === "content-type") @@ -10986,7 +10986,7 @@ function Ww(e) { } return e.body?.mediaType; } -function lf(e) { +function af(e) { if (!e.includes(":")) throw new Error( "Basic auth credential must contain a username and password separated by a colon" @@ -10994,11 +10994,11 @@ function lf(e) { const [t, n] = e.split(":", 2); return { username: t, password: n }; } -const Ho = null; -function Fj() { - return async () => [Ho, void 0]; +const Uo = null; +function Lj() { + return async () => [Uo, void 0]; } -class Kw { +class Ww { /** * @callback HookCallback * @this {*|Jsep} this @@ -11041,7 +11041,7 @@ class Kw { }); } } -class Gw { +class Kw { constructor(t) { this.jsep = t, this.registered = {}; } @@ -11614,10 +11614,10 @@ class z { }; } } -const Xw = new Kw(); +const Gw = new Ww(); Object.assign(z, { - hooks: Xw, - plugins: new Gw(z), + hooks: Gw, + plugins: new Kw(z), // Node Types // ---------- // This is the full set of types that any JSEP node can be. @@ -11713,14 +11713,14 @@ Object.assign(z, { }); z.max_unop_len = z.getMaxKeyLen(z.unary_ops); z.max_binop_len = z.getMaxKeyLen(z.binary_ops); -const at = (e) => new z(e).parse(), Yw = Object.getOwnPropertyNames(class { +const lt = (e) => new z(e).parse(), Xw = Object.getOwnPropertyNames(class { }); -Object.getOwnPropertyNames(z).filter((e) => !Yw.includes(e) && at[e] === void 0).forEach((e) => { - at[e] = z[e]; +Object.getOwnPropertyNames(z).filter((e) => !Xw.includes(e) && lt[e] === void 0).forEach((e) => { + lt[e] = z[e]; }); -at.Jsep = z; -const Qw = "ConditionalExpression"; -var Jw = { +lt.Jsep = z; +const Yw = "ConditionalExpression"; +var Qw = { name: "ternary", init(e) { e.hooks.add("after-expression", function(n) { @@ -11731,7 +11731,7 @@ var Jw = { this.index++; const i = this.gobbleExpression(); if (i || this.throwError("Expected expression"), n.node = { - type: Qw, + type: Yw, test: r, consequent: o, alternate: i @@ -11747,17 +11747,17 @@ var Jw = { }); } }; -at.plugins.register(Jw); -const Xl = 47, Zw = 92; -var e0 = { +lt.plugins.register(Qw); +const Gl = 47, Jw = 92; +var Zw = { name: "regex", init(e) { e.hooks.add("gobble-token", function(n) { - if (this.code === Xl) { + if (this.code === Gl) { const r = ++this.index; let o = !1; for (; this.index < this.expr.length; ) { - if (this.code === Xl && !o) { + if (this.code === Gl && !o) { const i = this.expr.slice(r, this.index); let s = ""; for (; ++this.index < this.expr.length; ) { @@ -11779,17 +11779,17 @@ var e0 = { raw: this.expr.slice(r - 1, this.index) }, n.node = this.gobbleTokenProperty(n.node), n.node; } - this.code === e.OBRACK_CODE ? o = !0 : o && this.code === e.CBRACK_CODE && (o = !1), this.index += this.code === Zw ? 2 : 1; + this.code === e.OBRACK_CODE ? o = !0 : o && this.code === e.CBRACK_CODE && (o = !1), this.index += this.code === Jw ? 2 : 1; } this.throwError("Unclosed Regex"); } }); } }; -const hi = 43, t0 = 45, Zt = { +const fi = 43, e0 = 45, Zt = { name: "assignment", assignmentOperators: /* @__PURE__ */ new Set(["=", "*=", "**=", "/=", "%=", "+=", "-=", "<<=", ">>=", ">>>=", "&=", "^=", "|=", "||=", "&&=", "??="]), - updateOperators: [hi, t0], + updateOperators: [fi, e0], assignmentPrecedence: 0.9, init(e) { const t = [e.IDENTIFIER, e.MEMBER_EXP]; @@ -11797,7 +11797,7 @@ const hi = 43, t0 = 45, Zt = { const i = this.code; Zt.updateOperators.some((s) => s === i && s === this.expr.charCodeAt(this.index + 1)) && (this.index += 2, o.node = { type: "UpdateExpression", - operator: i === hi ? "++" : "--", + operator: i === fi ? "++" : "--", argument: this.gobbleTokenProperty(this.gobbleIdentifier()), prefix: !0 }, (!o.node.argument || !t.includes(o.node.argument.type)) && this.throwError(`Unexpected ${o.node.operator}`)); @@ -11806,7 +11806,7 @@ const hi = 43, t0 = 45, Zt = { const i = this.code; Zt.updateOperators.some((s) => s === i && s === this.expr.charCodeAt(this.index + 1)) && (t.includes(o.node.type) || this.throwError(`Unexpected ${o.node.operator}`), this.index += 2, o.node = { type: "UpdateExpression", - operator: i === hi ? "++" : "--", + operator: i === fi ? "++" : "--", argument: o.node, prefix: !1 }); @@ -11821,11 +11821,11 @@ const hi = 43, t0 = 45, Zt = { } } }; -at.plugins.register(e0, Zt); -at.addUnaryOp("typeof"); -at.addLiteral("null", null); -at.addLiteral("undefined", void 0); -const n0 = /* @__PURE__ */ new Set(["constructor", "__proto__", "__defineGetter__", "__defineSetter__"]), te = { +lt.plugins.register(Zw, Zt); +lt.addUnaryOp("typeof"); +lt.addLiteral("null", null); +lt.addLiteral("undefined", void 0); +const t0 = /* @__PURE__ */ new Set(["constructor", "__proto__", "__defineGetter__", "__defineSetter__"]), te = { /** * @param {jsep.Expression} ast * @param {Record} subs @@ -11914,7 +11914,7 @@ const n0 = /* @__PURE__ */ new Set(["constructor", "__proto__", "__defineGetter_ ), r = te.evalAst(e.object, t); if (r == null) throw TypeError(`Cannot read properties of ${r} (reading '${n}')`); - if (!Object.hasOwn(r, n) && n0.has(n)) + if (!Object.hasOwn(r, n) && t0.has(n)) throw TypeError(`Cannot read properties of ${r} (reading '${n}')`); const o = r[n]; return typeof o == "function" ? o.bind(r) : o; @@ -11943,12 +11943,12 @@ const n0 = /* @__PURE__ */ new Set(["constructor", "__proto__", "__defineGetter_ return t[n] = r, t[n]; } }; -class r0 { +class n0 { /** * @param {string} expr Expression to evaluate */ constructor(t) { - this.code = t, this.ast = at(this.code); + this.code = t, this.ast = lt(this.code); } /** * @param {object} context Object whose items will be added @@ -11960,13 +11960,13 @@ class r0 { return te.evalAst(this.ast, n); } } -function ut(e, t) { +function dt(e, t) { return e = e.slice(), e.push(t), e; } -function Gi(e, t) { +function Ki(e, t) { return t = t.slice(), t.unshift(e), t; } -class o0 extends Error { +class r0 extends Error { /** * @param {AnyResult} value The evaluated scalar value */ @@ -11994,7 +11994,7 @@ function Z(e, t, n, r, o) { i ? "json" in e && (s.json = e.json) : s.json = n; const a = this.evaluate(s); if (!a || typeof a != "object") - throw new o0(a); + throw new r0(a); return a; } } @@ -12066,14 +12066,14 @@ Z.prototype._trace = function(e, t, n, r, o, i, s, a) { }) : h.push(p); } if ((typeof u != "string" || a) && t && Object.hasOwn(t, u)) - f(this._trace(d, t[u], ut(n, u), t, u, i, s)); + f(this._trace(d, t[u], dt(n, u), t, u, i, s)); else if (u === "*") this._walk(t, (p) => { - f(this._trace(d, t[p], ut(n, p), t, p, i, !0, !0)); + f(this._trace(d, t[p], dt(n, p), t, p, i, !0, !0)); }); else if (u === "..") f(this._trace(d, t, n, r, o, i, s)), this._walk(t, (p) => { - typeof t[p] == "object" && f(this._trace(e.slice(), t[p], ut(n, p), t, p, i, !0)); + typeof t[p] == "object" && f(this._trace(e.slice(), t[p], dt(n, p), t, p, i, !0)); }); else { if (u === "^") @@ -12084,7 +12084,7 @@ Z.prototype._trace = function(e, t, n, r, o, i, s, a) { }; if (u === "~") return l = { - path: ut(n, u), + path: dt(n, u), value: o, parent: r, parentProperty: null @@ -12099,14 +12099,14 @@ Z.prototype._trace = function(e, t, n, r, o, i, s, a) { const p = u.replace(/^\?\((.*?)\)$/u, "$1"), g = /@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(p); g ? this._walk(t, (m) => { const y = [g[2]], x = g[1] ? t[m][g[1]] : t[m]; - this._trace(y, x, n, r, o, i, !0).length > 0 && f(this._trace(d, t[m], ut(n, m), t, m, i, !0)); + this._trace(y, x, n, r, o, i, !0).length > 0 && f(this._trace(d, t[m], dt(n, m), t, m, i, !0)); }) : this._walk(t, (m) => { - this._eval(p, t[m], m, n, r, o) && f(this._trace(d, t[m], ut(n, m), t, m, i, !0)); + this._eval(p, t[m], m, n, r, o) && f(this._trace(d, t[m], dt(n, m), t, m, i, !0)); }); } else if (u[0] === "(") { if (this.currEval === !1) throw new Error("Eval [(expr)] prevented in JSONPath expression."); - f(this._trace(Gi(this._eval(u, t, n.at(-1), n.slice(0, -1), r, o), d), t, n, r, o, i, s)); + f(this._trace(Ki(this._eval(u, t, n.at(-1), n.slice(0, -1), r, o), d), t, n, r, o, i, s)); } else if (u[0] === "@") { let p = !1; const g = u.slice(1, -2); @@ -12154,12 +12154,12 @@ Z.prototype._trace = function(e, t, n, r, o, i, s, a) { }, this._handleCallback(l, i, "value"), l; } else if (u[0] === "`" && t && Object.hasOwn(t, u.slice(1))) { const p = u.slice(1); - f(this._trace(d, t[p], ut(n, p), t, p, i, s, !0)); + f(this._trace(d, t[p], dt(n, p), t, p, i, s, !0)); } else if (u.includes(",")) { const p = u.split(","); for (const g of p) - f(this._trace(Gi(g, d), t, n, r, o, i, !0)); - } else !a && t && Object.hasOwn(t, u) && f(this._trace(d, t[u], ut(n, u), t, u, i, s, !0)); + f(this._trace(Ki(g, d), t, n, r, o, i, !0)); + } else !a && t && Object.hasOwn(t, u) && f(this._trace(d, t[u], dt(n, u), t, u, i, s, !0)); } if (this._hasParentSelector) for (let p = 0; p < h.length; p++) { @@ -12194,7 +12194,7 @@ Z.prototype._slice = function(e, t, n, r, o, i, s) { d = d < 0 ? Math.max(0, d + a) : Math.min(a, d), h = h < 0 ? Math.max(0, h + a) : Math.min(a, h); const f = []; for (let p = d; p < h; p += u) - this._trace(Gi(p, t), n, r, o, i, s, !0).forEach((m) => { + this._trace(Ki(p, t), n, r, o, i, s, !0).forEach((m) => { f.push(m); }); return f; @@ -12262,16 +12262,16 @@ Z.toPathArray = function(e) { return t[e] = o, t[e].concat(); }; Z.prototype.safeVm = { - Script: r0 + Script: n0 }; -const i0 = function(e, t, n) { +const o0 = function(e, t, n) { const r = e.length; for (let o = 0; o < r; o++) { const i = e[o]; n(i) && t.push(e.splice(o--, 1)[0]); } }; -class s0 { +class i0 { /** * @param {string} expr Expression to evaluate */ @@ -12286,7 +12286,7 @@ class s0 { runInNewContext(t) { let n = this.code; const r = Object.keys(t), o = []; - i0(r, o, (u) => typeof t[u] == "function"); + o0(r, o, (u) => typeof t[u] == "function"); const i = r.map((u) => t[u]); n = o.reduce((u, d) => { let h = t[d].toString(); @@ -12297,32 +12297,32 @@ class s0 { } } Z.prototype.vm = { - Script: s0 + Script: i0 }; -var pi = {}, An = {}, Ar = {}, Yl; -function ta() { - if (Yl) return Ar; - Yl = 1, Object.defineProperty(Ar, "__esModule", { value: !0 }), Ar.pathMatch = e; +var hi = {}, An = {}, Ar = {}, Xl; +function ea() { + if (Xl) return Ar; + Xl = 1, Object.defineProperty(Ar, "__esModule", { value: !0 }), Ar.pathMatch = e; function e(t, n) { return !!(n === t || t.indexOf(n) === 0 && (n[n.length - 1] === "/" || t.startsWith(n) && t[n.length] === "/")); } return Ar; } var Nr = {}, Rr = {}; -function a0(e, t) { +function s0(e, t) { return e.endsWith(t) ? e.length === t.length || e[e.length - t.length - 1] === "." : !1; } -function l0(e, t) { +function a0(e, t) { const n = e.length - t.length - 2, r = e.lastIndexOf(".", n); return r === -1 ? e : e.slice(r + 1); } -function c0(e, t, n) { +function l0(e, t, n) { if (n.validHosts !== null) { const o = n.validHosts; for (const i of o) if ( /*@__INLINE__*/ - a0(t, i) + s0(t, i) ) return i; } @@ -12332,13 +12332,13 @@ function c0(e, t, n) { r += 1; return e.length === t.length - r ? null : ( /*@__INLINE__*/ - l0(t, e) + a0(t, e) ); } -function u0(e, t) { +function c0(e, t) { return e.slice(0, -t.length - 1); } -function Ql(e, t) { +function Yl(e, t) { let n = 0, r = e.length, o = !1; if (!t) { if (e.startsWith("data:")) @@ -12391,7 +12391,7 @@ function Ql(e, t) { const i = n !== 0 || r !== e.length ? e.slice(n, r) : e; return o ? i.toLowerCase() : i; } -function d0(e) { +function u0(e) { if (e.length < 7 || e.length > 15) return !1; let t = 0; @@ -12404,7 +12404,7 @@ function d0(e) { } return t === 3 && e.charCodeAt(0) !== 46 && e.charCodeAt(e.length - 1) !== 46; } -function f0(e) { +function d0(e) { if (e.length < 3) return !1; let t = e.startsWith("[") ? 1 : 0, n = e.length; @@ -12422,15 +12422,15 @@ function f0(e) { } return r; } -function h0(e) { - return f0(e) || d0(e); +function f0(e) { + return d0(e) || u0(e); } -function Jl(e) { +function Ql(e) { return e >= 97 && e <= 122 || e >= 48 && e <= 57 || e > 127; } -function Zl(e) { +function Jl(e) { if (e.length > 255 || e.length === 0 || /*@__INLINE__*/ - !Jl(e.charCodeAt(0)) && e.charCodeAt(0) !== 46 && // '.' (dot) + !Ql(e.charCodeAt(0)) && e.charCodeAt(0) !== 46 && // '.' (dot) e.charCodeAt(0) !== 95) return !1; let t = -1, n = -1; @@ -12448,7 +12448,7 @@ function Zl(e) { return !1; t = o; } else if (!/*@__INLINE__*/ - (Jl(i) || i === 45 || i === 95)) + (Ql(i) || i === 45 || i === 95)) return !1; n = i; } @@ -12460,7 +12460,7 @@ function Zl(e) { n !== 45 ); } -function cf({ allowIcannDomains: e = !0, allowPrivateDomains: t = !1, detectIp: n = !0, extractHostname: r = !0, mixedInputs: o = !0, validHosts: i = null, validateHostname: s = !0 }) { +function lf({ allowIcannDomains: e = !0, allowPrivateDomains: t = !1, detectIp: n = !0, extractHostname: r = !0, mixedInputs: o = !0, validHosts: i = null, validateHostname: s = !0 }) { return { allowIcannDomains: e, allowPrivateDomains: t, @@ -12471,20 +12471,20 @@ function cf({ allowIcannDomains: e = !0, allowPrivateDomains: t = !1, detectIp: validateHostname: s }; } -const p0 = ( +const h0 = ( /*@__INLINE__*/ - cf({}) + lf({}) ); -function g0(e) { - return e === void 0 ? p0 : ( +function p0(e) { + return e === void 0 ? h0 : ( /*@__INLINE__*/ - cf(e) + lf(e) ); } -function m0(e, t) { +function g0(e, t) { return t.length === e.length ? "" : e.slice(0, -t.length - 1); } -function uf() { +function cf() { return { domain: null, domainWithoutSuffix: null, @@ -12502,11 +12502,11 @@ function mr(e) { function On(e, t, n, r, o) { const i = ( /*@__INLINE__*/ - g0(r) + p0(r) ); - return typeof e != "string" || (i.extractHostname ? i.mixedInputs ? o.hostname = Ql(e, Zl(e)) : o.hostname = Ql(e, !1) : o.hostname = e, t === 0 || o.hostname === null) || i.detectIp && (o.isIp = h0(o.hostname), o.isIp) ? o : i.validateHostname && i.extractHostname && !Zl(o.hostname) ? (o.hostname = null, o) : (n(o.hostname, i, o), t === 2 || o.publicSuffix === null || (o.domain = c0(o.publicSuffix, o.hostname, i), t === 3 || o.domain === null) || (o.subdomain = m0(o.hostname, o.domain), t === 4) || (o.domainWithoutSuffix = u0(o.domain, o.publicSuffix)), o); + return typeof e != "string" || (i.extractHostname ? i.mixedInputs ? o.hostname = Yl(e, Jl(e)) : o.hostname = Yl(e, !1) : o.hostname = e, t === 0 || o.hostname === null) || i.detectIp && (o.isIp = f0(o.hostname), o.isIp) ? o : i.validateHostname && i.extractHostname && !Jl(o.hostname) ? (o.hostname = null, o) : (n(o.hostname, i, o), t === 2 || o.publicSuffix === null || (o.domain = l0(o.publicSuffix, o.hostname, i), t === 3 || o.domain === null) || (o.subdomain = g0(o.hostname, o.domain), t === 4) || (o.domainWithoutSuffix = c0(o.domain, o.publicSuffix)), o); } -function y0(e, t, n) { +function m0(e, t, n) { if (!t.allowPrivateDomains && e.length > 3) { const r = e.length - 1, o = e.charCodeAt(r), i = e.charCodeAt(r - 1), s = e.charCodeAt(r - 2), a = e.charCodeAt(r - 3); if (o === 109 && i === 111 && s === 99 && a === 46) @@ -12524,14 +12524,14 @@ function y0(e, t, n) { } return !1; } -const v0 = /* @__PURE__ */ (function() { +const y0 = /* @__PURE__ */ (function() { const e = [1, {}], t = [2, {}], n = [0, { city: e }]; return [0, { ck: [0, { www: e }], jp: [0, { kawasaki: n, kitakyushu: n, kobe: n, nagoya: n, sapporo: n, sendai: n, yokohama: n }], dev: [0, { hrsn: [0, { psl: [0, { wc: [0, { ignored: t, sub: [0, { ignored: t }] }] }] }] }] }]; -})(), b0 = /* @__PURE__ */ (function() { - const e = [1, {}], t = [2, {}], n = [1, { com: e, edu: e, gov: e, net: e, org: e }], r = [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e }], o = [0, { "*": t }], i = [2, { s: o }], s = [0, { relay: t }], a = [2, { id: t }], l = [1, { gov: e }], u = [0, { "transfer-webapp": t }], d = [0, { notebook: t, studio: t }], h = [0, { labeling: t, notebook: t, studio: t }], f = [0, { notebook: t }], p = [0, { labeling: t, notebook: t, "notebook-fips": t, studio: t }], g = [0, { notebook: t, "notebook-fips": t, studio: t, "studio-fips": t }], m = [0, { "*": e }], y = [1, { co: t }], x = [0, { objects: t }], k = [2, { nodes: t }], v = [0, { my: o }], b = [0, { s3: t, "s3-accesspoint": t, "s3-website": t }], j = [0, { s3: t, "s3-accesspoint": t }], _ = [0, { direct: t }], S = [0, { "webview-assets": t }], P = [0, { vfs: t, "webview-assets": t }], D = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: P }], $ = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: j, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: P }], C = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], T = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t }], O = [0, { s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-website": t }], I = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: P }], N = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-deprecated": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], U = [0, { s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t }], V = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: U, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t }], q = [0, { auth: t }], J = [0, { auth: t, "auth-fips": t }], X = [0, { "auth-fips": t }], re = [0, { apps: t }], ve = [0, { paas: t }], et = [2, { eu: t }], ge = [0, { app: t }], Oe = [0, { site: t }], Y = [1, { com: e, edu: e, net: e, org: e }], G = [0, { j: t }], ee = [0, { dyn: t }], ue = [1, { co: e, com: e, edu: e, gov: e, net: e, org: e }], Ve = [0, { p: t }], pa = [0, { user: t }], ga = [0, { shop: t }], $n = [0, { cdn: t }], Go = [0, { cust: t, reservd: t }], ma = [0, { cust: t }], Xo = [0, { s3: t }], ya = [1, { biz: e, com: e, edu: e, gov: e, info: e, net: e, org: e }], Yo = [0, { ipfs: t }], br = [1, { framer: t }], va = [0, { forgot: t }], se = [1, { gs: e }], ba = [0, { nes: e }], W = [1, { k12: e, cc: e, lib: e }], xr = [1, { cc: e, lib: e }]; - return [0, { ac: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, drr: t, feedback: t, forms: t }], ad: e, ae: [1, { ac: e, co: e, gov: e, mil: e, net: e, org: e, sch: e }], aero: [1, { airline: e, airport: e, "accident-investigation": e, "accident-prevention": e, aerobatic: e, aeroclub: e, aerodrome: e, agents: e, "air-surveillance": e, "air-traffic-control": e, aircraft: e, airtraffic: e, ambulance: e, association: e, author: e, ballooning: e, broker: e, caa: e, cargo: e, catering: e, certification: e, championship: e, charter: e, civilaviation: e, club: e, conference: e, consultant: e, consulting: e, control: e, council: e, crew: e, design: e, dgca: e, educator: e, emergency: e, engine: e, engineer: e, entertainment: e, equipment: e, exchange: e, express: e, federation: e, flight: e, freight: e, fuel: e, gliding: e, government: e, groundhandling: e, group: e, hanggliding: e, homebuilt: e, insurance: e, journal: e, journalist: e, leasing: e, logistics: e, magazine: e, maintenance: e, marketplace: e, media: e, microlight: e, modelling: e, navigation: e, parachuting: e, paragliding: e, "passenger-association": e, pilot: e, press: e, production: e, recreation: e, repbody: e, res: e, research: e, rotorcraft: e, safety: e, scientist: e, services: e, show: e, skydiving: e, software: e, student: e, taxi: e, trader: e, trading: e, trainer: e, union: e, workinggroup: e, works: e }], af: n, ag: [1, { co: e, com: e, net: e, nom: e, org: e, obj: t }], ai: [1, { com: e, net: e, off: e, org: e, uwu: t, framer: t }], al: r, am: [1, { co: e, com: e, commune: e, net: e, org: e, radio: t }], ao: [1, { co: e, ed: e, edu: e, gov: e, gv: e, it: e, og: e, org: e, pb: e }], aq: e, ar: [1, { bet: e, com: e, coop: e, edu: e, gob: e, gov: e, int: e, mil: e, musica: e, mutual: e, net: e, org: e, seg: e, senasa: e, tur: e }], arpa: [1, { e164: e, home: e, "in-addr": e, ip6: e, iris: e, uri: e, urn: e }], as: l, asia: [1, { cloudns: t, daemon: t, dix: t }], at: [1, { ac: [1, { sth: e }], co: e, gv: e, or: e, funkfeuer: [0, { wien: t }], futurecms: [0, { "*": t, ex: o, in: o }], futurehosting: t, futuremailing: t, ortsinfo: [0, { ex: o, kunden: o }], biz: t, info: t, "123webseite": t, priv: t, myspreadshop: t, "12hp": t, "2ix": t, "4lima": t, "lima-city": t }], au: [1, { asn: e, com: [1, { cloudlets: [0, { mel: t }], myspreadshop: t }], edu: [1, { act: e, catholic: e, nsw: [1, { schools: e }], nt: e, qld: e, sa: e, tas: e, vic: e, wa: e }], gov: [1, { qld: e, sa: e, tas: e, vic: e, wa: e }], id: e, net: e, org: e, conf: e, oz: e, act: e, nsw: e, nt: e, qld: e, sa: e, tas: e, vic: e, wa: e }], aw: [1, { com: e }], ax: e, az: [1, { biz: e, co: e, com: e, edu: e, gov: e, info: e, int: e, mil: e, name: e, net: e, org: e, pp: e, pro: e }], ba: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, rs: t }], bb: [1, { biz: e, co: e, com: e, edu: e, gov: e, info: e, net: e, org: e, store: e, tv: e }], bd: m, be: [1, { ac: e, cloudns: t, webhosting: t, interhostsolutions: [0, { cloud: t }], kuleuven: [0, { ezproxy: t }], "123website": t, myspreadshop: t, transurl: o }], bf: l, bg: [1, { 0: e, 1: e, 2: e, 3: e, 4: e, 5: e, 6: e, 7: e, 8: e, 9: e, a: e, b: e, c: e, d: e, e, f: e, g: e, h: e, i: e, j: e, k: e, l: e, m: e, n: e, o: e, p: e, q: e, r: e, s: e, t: e, u: e, v: e, w: e, x: e, y: e, z: e, barsy: t }], bh: n, bi: [1, { co: e, com: e, edu: e, or: e, org: e }], biz: [1, { activetrail: t, "cloud-ip": t, cloudns: t, jozi: t, dyndns: t, "for-better": t, "for-more": t, "for-some": t, "for-the": t, selfip: t, webhop: t, orx: t, mmafan: t, myftp: t, "no-ip": t, dscloud: t }], bj: [1, { africa: e, agro: e, architectes: e, assur: e, avocats: e, co: e, com: e, eco: e, econo: e, edu: e, info: e, loisirs: e, money: e, net: e, org: e, ote: e, restaurant: e, resto: e, tourism: e, univ: e }], bm: n, bn: [1, { com: e, edu: e, gov: e, net: e, org: e, co: t }], bo: [1, { com: e, edu: e, gob: e, int: e, mil: e, net: e, org: e, tv: e, web: e, academia: e, agro: e, arte: e, blog: e, bolivia: e, ciencia: e, cooperativa: e, democracia: e, deporte: e, ecologia: e, economia: e, empresa: e, indigena: e, industria: e, info: e, medicina: e, movimiento: e, musica: e, natural: e, nombre: e, noticias: e, patria: e, plurinacional: e, politica: e, profesional: e, pueblo: e, revista: e, salud: e, tecnologia: e, tksat: e, transporte: e, wiki: e }], br: [1, { "9guacu": e, abc: e, adm: e, adv: e, agr: e, aju: e, am: e, anani: e, aparecida: e, app: e, arq: e, art: e, ato: e, b: e, barueri: e, belem: e, bet: e, bhz: e, bib: e, bio: e, blog: e, bmd: e, boavista: e, bsb: e, campinagrande: e, campinas: e, caxias: e, cim: e, cng: e, cnt: e, com: [1, { simplesite: t }], contagem: e, coop: e, coz: e, cri: e, cuiaba: e, curitiba: e, def: e, des: e, det: e, dev: e, ecn: e, eco: e, edu: e, emp: e, enf: e, eng: e, esp: e, etc: e, eti: e, far: e, feira: e, flog: e, floripa: e, fm: e, fnd: e, fortal: e, fot: e, foz: e, fst: e, g12: e, geo: e, ggf: e, goiania: e, gov: [1, { ac: e, al: e, am: e, ap: e, ba: e, ce: e, df: e, es: e, go: e, ma: e, mg: e, ms: e, mt: e, pa: e, pb: e, pe: e, pi: e, pr: e, rj: e, rn: e, ro: e, rr: e, rs: e, sc: e, se: e, sp: e, to: e }], gru: e, imb: e, ind: e, inf: e, jab: e, jampa: e, jdf: e, joinville: e, jor: e, jus: e, leg: [1, { ac: t, al: t, am: t, ap: t, ba: t, ce: t, df: t, es: t, go: t, ma: t, mg: t, ms: t, mt: t, pa: t, pb: t, pe: t, pi: t, pr: t, rj: t, rn: t, ro: t, rr: t, rs: t, sc: t, se: t, sp: t, to: t }], leilao: e, lel: e, log: e, londrina: e, macapa: e, maceio: e, manaus: e, maringa: e, mat: e, med: e, mil: e, morena: e, mp: e, mus: e, natal: e, net: e, niteroi: e, nom: m, not: e, ntr: e, odo: e, ong: e, org: e, osasco: e, palmas: e, poa: e, ppg: e, pro: e, psc: e, psi: e, pvh: e, qsl: e, radio: e, rec: e, recife: e, rep: e, ribeirao: e, rio: e, riobranco: e, riopreto: e, salvador: e, sampa: e, santamaria: e, santoandre: e, saobernardo: e, saogonca: e, seg: e, sjc: e, slg: e, slz: e, sorocaba: e, srv: e, taxi: e, tc: e, tec: e, teo: e, the: e, tmp: e, trd: e, tur: e, tv: e, udi: e, vet: e, vix: e, vlog: e, wiki: e, zlg: e }], bs: [1, { com: e, edu: e, gov: e, net: e, org: e, we: t }], bt: n, bv: e, bw: [1, { ac: e, co: e, gov: e, net: e, org: e }], by: [1, { gov: e, mil: e, com: e, of: e, mediatech: t }], bz: [1, { co: e, com: e, edu: e, gov: e, net: e, org: e, za: t, mydns: t, gsj: t }], ca: [1, { ab: e, bc: e, mb: e, nb: e, nf: e, nl: e, ns: e, nt: e, nu: e, on: e, pe: e, qc: e, sk: e, yk: e, gc: e, barsy: t, awdev: o, co: t, "no-ip": t, myspreadshop: t, box: t }], cat: e, cc: [1, { cleverapps: t, cloudns: t, ftpaccess: t, "game-server": t, myphotos: t, scrapping: t, twmail: t, csx: t, fantasyleague: t, spawn: [0, { instances: t }] }], cd: l, cf: e, cg: e, ch: [1, { square7: t, cloudns: t, cloudscale: [0, { cust: t, lpg: x, rma: x }], flow: [0, { ae: [0, { alp1: t }], appengine: t }], "linkyard-cloud": t, gotdns: t, dnsking: t, "123website": t, myspreadshop: t, firenet: [0, { "*": t, svc: o }], "12hp": t, "2ix": t, "4lima": t, "lima-city": t }], ci: [1, { ac: e, "xn--aroport-bya": e, aéroport: e, asso: e, co: e, com: e, ed: e, edu: e, go: e, gouv: e, int: e, net: e, or: e, org: e }], ck: m, cl: [1, { co: e, gob: e, gov: e, mil: e, cloudns: t }], cm: [1, { co: e, com: e, gov: e, net: e }], cn: [1, { ac: e, com: [1, { amazonaws: [0, { "cn-north-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-deprecated": t, "s3-object-lambda": t, "s3-website": t }], "cn-northwest-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: j, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t }], compute: o, airflow: [0, { "cn-north-1": o, "cn-northwest-1": o }], eb: [0, { "cn-north-1": t, "cn-northwest-1": t }], elb: o }], sagemaker: [0, { "cn-north-1": d, "cn-northwest-1": d }] }], edu: e, gov: e, mil: e, net: e, org: e, "xn--55qx5d": e, 公司: e, "xn--od0alg": e, 網絡: e, "xn--io0a7i": e, 网络: e, ah: e, bj: e, cq: e, fj: e, gd: e, gs: e, gx: e, gz: e, ha: e, hb: e, he: e, hi: e, hk: e, hl: e, hn: e, jl: e, js: e, jx: e, ln: e, mo: e, nm: e, nx: e, qh: e, sc: e, sd: e, sh: [1, { as: t }], sn: e, sx: e, tj: e, tw: e, xj: e, xz: e, yn: e, zj: e, "canva-apps": t, canvasite: v, myqnapcloud: t, quickconnect: _ }], co: [1, { com: e, edu: e, gov: e, mil: e, net: e, nom: e, org: e, carrd: t, crd: t, otap: o, leadpages: t, lpages: t, mypi: t, xmit: o, firewalledreplit: a, repl: a, supabase: t }], com: [1, { a2hosted: t, cpserver: t, adobeaemcloud: [2, { dev: o }], africa: t, airkitapps: t, "airkitapps-au": t, aivencloud: t, alibabacloudcs: t, kasserver: t, amazonaws: [0, { "af-south-1": D, "ap-east-1": $, "ap-northeast-1": C, "ap-northeast-2": C, "ap-northeast-3": D, "ap-south-1": C, "ap-south-2": T, "ap-southeast-1": C, "ap-southeast-2": C, "ap-southeast-3": T, "ap-southeast-4": T, "ap-southeast-5": [0, { "execute-api": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-deprecated": t, "s3-object-lambda": t, "s3-website": t }], "ca-central-1": I, "ca-west-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t }], "eu-central-1": C, "eu-central-2": T, "eu-north-1": $, "eu-south-1": D, "eu-south-2": T, "eu-west-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-deprecated": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], "eu-west-2": $, "eu-west-3": D, "il-central-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: [0, { vfs: t }] }], "me-central-1": T, "me-south-1": $, "sa-east-1": D, "us-east-1": [2, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-deprecated": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], "us-east-2": N, "us-gov-east-1": V, "us-gov-west-1": V, "us-west-1": I, "us-west-2": N, compute: o, "compute-1": o, airflow: [0, { "af-south-1": o, "ap-east-1": o, "ap-northeast-1": o, "ap-northeast-2": o, "ap-northeast-3": o, "ap-south-1": o, "ap-south-2": o, "ap-southeast-1": o, "ap-southeast-2": o, "ap-southeast-3": o, "ap-southeast-4": o, "ca-central-1": o, "ca-west-1": o, "eu-central-1": o, "eu-central-2": o, "eu-north-1": o, "eu-south-1": o, "eu-south-2": o, "eu-west-1": o, "eu-west-2": o, "eu-west-3": o, "il-central-1": o, "me-central-1": o, "me-south-1": o, "sa-east-1": o, "us-east-1": o, "us-east-2": o, "us-west-1": o, "us-west-2": o }], s3: t, "s3-1": t, "s3-ap-east-1": t, "s3-ap-northeast-1": t, "s3-ap-northeast-2": t, "s3-ap-northeast-3": t, "s3-ap-south-1": t, "s3-ap-southeast-1": t, "s3-ap-southeast-2": t, "s3-ca-central-1": t, "s3-eu-central-1": t, "s3-eu-north-1": t, "s3-eu-west-1": t, "s3-eu-west-2": t, "s3-eu-west-3": t, "s3-external-1": t, "s3-fips-us-gov-east-1": t, "s3-fips-us-gov-west-1": t, "s3-global": [0, { accesspoint: [0, { mrap: t }] }], "s3-me-south-1": t, "s3-sa-east-1": t, "s3-us-east-2": t, "s3-us-gov-east-1": t, "s3-us-gov-west-1": t, "s3-us-west-1": t, "s3-us-west-2": t, "s3-website-ap-northeast-1": t, "s3-website-ap-southeast-1": t, "s3-website-ap-southeast-2": t, "s3-website-eu-west-1": t, "s3-website-sa-east-1": t, "s3-website-us-east-1": t, "s3-website-us-gov-west-1": t, "s3-website-us-west-1": t, "s3-website-us-west-2": t, elb: o }], amazoncognito: [0, { "af-south-1": q, "ap-east-1": q, "ap-northeast-1": q, "ap-northeast-2": q, "ap-northeast-3": q, "ap-south-1": q, "ap-south-2": q, "ap-southeast-1": q, "ap-southeast-2": q, "ap-southeast-3": q, "ap-southeast-4": q, "ap-southeast-5": q, "ca-central-1": q, "ca-west-1": q, "eu-central-1": q, "eu-central-2": q, "eu-north-1": q, "eu-south-1": q, "eu-south-2": q, "eu-west-1": q, "eu-west-2": q, "eu-west-3": q, "il-central-1": q, "me-central-1": q, "me-south-1": q, "sa-east-1": q, "us-east-1": J, "us-east-2": J, "us-gov-east-1": X, "us-gov-west-1": X, "us-west-1": J, "us-west-2": J }], amplifyapp: t, awsapprunner: o, awsapps: t, elasticbeanstalk: [2, { "af-south-1": t, "ap-east-1": t, "ap-northeast-1": t, "ap-northeast-2": t, "ap-northeast-3": t, "ap-south-1": t, "ap-southeast-1": t, "ap-southeast-2": t, "ap-southeast-3": t, "ca-central-1": t, "eu-central-1": t, "eu-north-1": t, "eu-south-1": t, "eu-west-1": t, "eu-west-2": t, "eu-west-3": t, "il-central-1": t, "me-south-1": t, "sa-east-1": t, "us-east-1": t, "us-east-2": t, "us-gov-east-1": t, "us-gov-west-1": t, "us-west-1": t, "us-west-2": t }], awsglobalaccelerator: t, siiites: t, appspacehosted: t, appspaceusercontent: t, "on-aptible": t, myasustor: t, "balena-devices": t, boutir: t, bplaced: t, cafjs: t, "canva-apps": t, "cdn77-storage": t, br: t, cn: t, de: t, eu: t, jpn: t, mex: t, ru: t, sa: t, uk: t, us: t, za: t, "clever-cloud": [0, { services: o }], dnsabr: t, "ip-ddns": t, jdevcloud: t, wpdevcloud: t, "cf-ipfs": t, "cloudflare-ipfs": t, trycloudflare: t, co: t, devinapps: o, builtwithdark: t, datadetect: [0, { demo: t, instance: t }], dattolocal: t, dattorelay: t, dattoweb: t, mydatto: t, digitaloceanspaces: o, discordsays: t, discordsez: t, drayddns: t, dreamhosters: t, durumis: t, mydrobo: t, blogdns: t, cechire: t, dnsalias: t, dnsdojo: t, doesntexist: t, dontexist: t, doomdns: t, "dyn-o-saur": t, dynalias: t, "dyndns-at-home": t, "dyndns-at-work": t, "dyndns-blog": t, "dyndns-free": t, "dyndns-home": t, "dyndns-ip": t, "dyndns-mail": t, "dyndns-office": t, "dyndns-pics": t, "dyndns-remote": t, "dyndns-server": t, "dyndns-web": t, "dyndns-wiki": t, "dyndns-work": t, "est-a-la-maison": t, "est-a-la-masion": t, "est-le-patron": t, "est-mon-blogueur": t, "from-ak": t, "from-al": t, "from-ar": t, "from-ca": t, "from-ct": t, "from-dc": t, "from-de": t, "from-fl": t, "from-ga": t, "from-hi": t, "from-ia": t, "from-id": t, "from-il": t, "from-in": t, "from-ks": t, "from-ky": t, "from-ma": t, "from-md": t, "from-mi": t, "from-mn": t, "from-mo": t, "from-ms": t, "from-mt": t, "from-nc": t, "from-nd": t, "from-ne": t, "from-nh": t, "from-nj": t, "from-nm": t, "from-nv": t, "from-oh": t, "from-ok": t, "from-or": t, "from-pa": t, "from-pr": t, "from-ri": t, "from-sc": t, "from-sd": t, "from-tn": t, "from-tx": t, "from-ut": t, "from-va": t, "from-vt": t, "from-wa": t, "from-wi": t, "from-wv": t, "from-wy": t, getmyip: t, gotdns: t, "hobby-site": t, homelinux: t, homeunix: t, iamallama: t, "is-a-anarchist": t, "is-a-blogger": t, "is-a-bookkeeper": t, "is-a-bulls-fan": t, "is-a-caterer": t, "is-a-chef": t, "is-a-conservative": t, "is-a-cpa": t, "is-a-cubicle-slave": t, "is-a-democrat": t, "is-a-designer": t, "is-a-doctor": t, "is-a-financialadvisor": t, "is-a-geek": t, "is-a-green": t, "is-a-guru": t, "is-a-hard-worker": t, "is-a-hunter": t, "is-a-landscaper": t, "is-a-lawyer": t, "is-a-liberal": t, "is-a-libertarian": t, "is-a-llama": t, "is-a-musician": t, "is-a-nascarfan": t, "is-a-nurse": t, "is-a-painter": t, "is-a-personaltrainer": t, "is-a-photographer": t, "is-a-player": t, "is-a-republican": t, "is-a-rockstar": t, "is-a-socialist": t, "is-a-student": t, "is-a-teacher": t, "is-a-techie": t, "is-a-therapist": t, "is-an-accountant": t, "is-an-actor": t, "is-an-actress": t, "is-an-anarchist": t, "is-an-artist": t, "is-an-engineer": t, "is-an-entertainer": t, "is-certified": t, "is-gone": t, "is-into-anime": t, "is-into-cars": t, "is-into-cartoons": t, "is-into-games": t, "is-leet": t, "is-not-certified": t, "is-slick": t, "is-uberleet": t, "is-with-theband": t, "isa-geek": t, "isa-hockeynut": t, issmarterthanyou: t, "likes-pie": t, likescandy: t, "neat-url": t, "saves-the-whales": t, selfip: t, "sells-for-less": t, "sells-for-u": t, servebbs: t, "simple-url": t, "space-to-rent": t, "teaches-yoga": t, writesthisblog: t, ddnsfree: t, ddnsgeek: t, giize: t, gleeze: t, kozow: t, loseyourip: t, ooguy: t, theworkpc: t, mytuleap: t, "tuleap-partners": t, encoreapi: t, evennode: [0, { "eu-1": t, "eu-2": t, "eu-3": t, "eu-4": t, "us-1": t, "us-2": t, "us-3": t, "us-4": t }], onfabrica: t, "fastly-edge": t, "fastly-terrarium": t, "fastvps-server": t, mydobiss: t, firebaseapp: t, fldrv: t, forgeblocks: t, framercanvas: t, "freebox-os": t, freeboxos: t, freemyip: t, aliases121: t, gentapps: t, gentlentapis: t, githubusercontent: t, "0emm": o, appspot: [2, { r: o }], blogspot: t, codespot: t, googleapis: t, googlecode: t, pagespeedmobilizer: t, withgoogle: t, withyoutube: t, grayjayleagues: t, hatenablog: t, hatenadiary: t, herokuapp: t, gr: t, smushcdn: t, wphostedmail: t, wpmucdn: t, pixolino: t, "apps-1and1": t, "live-website": t, dopaas: t, "hosted-by-previder": ve, hosteur: [0, { "rag-cloud": t, "rag-cloud-ch": t }], "ik-server": [0, { jcloud: t, "jcloud-ver-jpc": t }], jelastic: [0, { demo: t }], massivegrid: ve, wafaicloud: [0, { jed: t, ryd: t }], webadorsite: t, joyent: [0, { cns: o }], lpusercontent: t, linode: [0, { members: t, nodebalancer: o }], linodeobjects: o, linodeusercontent: [0, { ip: t }], localtonet: t, lovableproject: t, barsycenter: t, barsyonline: t, modelscape: t, mwcloudnonprod: t, polyspace: t, mazeplay: t, miniserver: t, atmeta: t, fbsbx: re, meteorapp: et, routingthecloud: t, mydbserver: t, hostedpi: t, "mythic-beasts": [0, { caracal: t, customer: t, fentiger: t, lynx: t, ocelot: t, oncilla: t, onza: t, sphinx: t, vs: t, x: t, yali: t }], nospamproxy: [0, { cloud: [2, { o365: t }] }], "4u": t, nfshost: t, "3utilities": t, blogsyte: t, ciscofreak: t, damnserver: t, ddnsking: t, ditchyourip: t, dnsiskinky: t, dynns: t, geekgalaxy: t, "health-carereform": t, homesecuritymac: t, homesecuritypc: t, myactivedirectory: t, mysecuritycamera: t, myvnc: t, "net-freaks": t, onthewifi: t, point2this: t, quicksytes: t, securitytactics: t, servebeer: t, servecounterstrike: t, serveexchange: t, serveftp: t, servegame: t, servehalflife: t, servehttp: t, servehumour: t, serveirc: t, servemp3: t, servep2p: t, servepics: t, servequake: t, servesarcasm: t, stufftoread: t, unusualperson: t, workisboring: t, myiphost: t, observableusercontent: [0, { static: t }], simplesite: t, orsites: t, operaunite: t, "customer-oci": [0, { "*": t, oci: o, ocp: o, ocs: o }], oraclecloudapps: o, oraclegovcloudapps: o, "authgear-staging": t, authgearapps: t, skygearapp: t, outsystemscloud: t, ownprovider: t, pgfog: t, pagexl: t, gotpantheon: t, paywhirl: o, upsunapp: t, "postman-echo": t, prgmr: [0, { xen: t }], pythonanywhere: et, qa2: t, "alpha-myqnapcloud": t, "dev-myqnapcloud": t, mycloudnas: t, mynascloud: t, myqnapcloud: t, qualifioapp: t, ladesk: t, qbuser: t, quipelements: o, rackmaze: t, "readthedocs-hosted": t, rhcloud: t, onrender: t, render: ge, "subsc-pay": t, "180r": t, dojin: t, sakuratan: t, sakuraweb: t, x0: t, code: [0, { builder: o, "dev-builder": o, "stg-builder": o }], salesforce: [0, { platform: [0, { "code-builder-stg": [0, { test: [0, { "001": o }] }] }] }], logoip: t, scrysec: t, "firewall-gateway": t, myshopblocks: t, myshopify: t, shopitsite: t, "1kapp": t, appchizi: t, applinzi: t, sinaapp: t, vipsinaapp: t, streamlitapp: t, "try-snowplow": t, "playstation-cloud": t, myspreadshop: t, "w-corp-staticblitz": t, "w-credentialless-staticblitz": t, "w-staticblitz": t, "stackhero-network": t, stdlib: [0, { api: t }], strapiapp: [2, { media: t }], "streak-link": t, streaklinks: t, streakusercontent: t, "temp-dns": t, dsmynas: t, familyds: t, mytabit: t, taveusercontent: t, "tb-hosting": Oe, reservd: t, thingdustdata: t, "townnews-staging": t, typeform: [0, { pro: t }], hk: t, it: t, "deus-canvas": t, vultrobjects: o, wafflecell: t, hotelwithflight: t, "reserve-online": t, cprapid: t, pleskns: t, remotewd: t, wiardweb: [0, { pages: t }], wixsite: t, wixstudio: t, messwithdns: t, "woltlab-demo": t, wpenginepowered: [2, { js: t }], xnbay: [2, { u2: t, "u2-local": t }], yolasite: t }], coop: e, cr: [1, { ac: e, co: e, ed: e, fi: e, go: e, or: e, sa: e }], cu: [1, { com: e, edu: e, gob: e, inf: e, nat: e, net: e, org: e }], cv: [1, { com: e, edu: e, id: e, int: e, net: e, nome: e, org: e, publ: e }], cw: Y, cx: [1, { gov: e, cloudns: t, ath: t, info: t, assessments: t, calculators: t, funnels: t, paynow: t, quizzes: t, researched: t, tests: t }], cy: [1, { ac: e, biz: e, com: [1, { scaleforce: G }], ekloges: e, gov: e, ltd: e, mil: e, net: e, org: e, press: e, pro: e, tm: e }], cz: [1, { contentproxy9: [0, { rsc: t }], realm: t, e4: t, co: t, metacentrum: [0, { cloud: o, custom: t }], muni: [0, { cloud: [0, { flt: t, usr: t }] }] }], de: [1, { bplaced: t, square7: t, com: t, cosidns: ee, dnsupdater: t, "dynamisches-dns": t, "internet-dns": t, "l-o-g-i-n": t, ddnss: [2, { dyn: t, dyndns: t }], "dyn-ip24": t, dyndns1: t, "home-webserver": [2, { dyn: t }], "myhome-server": t, dnshome: t, fuettertdasnetz: t, isteingeek: t, istmein: t, lebtimnetz: t, leitungsen: t, traeumtgerade: t, frusky: o, goip: t, "xn--gnstigbestellen-zvb": t, günstigbestellen: t, "xn--gnstigliefern-wob": t, günstigliefern: t, "hs-heilbronn": [0, { it: [0, { pages: t, "pages-research": t }] }], "dyn-berlin": t, "in-berlin": t, "in-brb": t, "in-butter": t, "in-dsl": t, "in-vpn": t, iservschule: t, "mein-iserv": t, schulplattform: t, schulserver: t, "test-iserv": t, keymachine: t, "git-repos": t, "lcube-server": t, "svn-repos": t, barsy: t, webspaceconfig: t, "123webseite": t, rub: t, "ruhr-uni-bochum": [2, { noc: [0, { io: t }] }], logoip: t, "firewall-gateway": t, "my-gateway": t, "my-router": t, spdns: t, speedpartner: [0, { customer: t }], myspreadshop: t, "taifun-dns": t, "12hp": t, "2ix": t, "4lima": t, "lima-city": t, "dd-dns": t, "dray-dns": t, draydns: t, "dyn-vpn": t, dynvpn: t, "mein-vigor": t, "my-vigor": t, "my-wan": t, "syno-ds": t, "synology-diskstation": t, "synology-ds": t, uberspace: o, "virtual-user": t, virtualuser: t, "community-pro": t, diskussionsbereich: t }], dj: e, dk: [1, { biz: t, co: t, firm: t, reg: t, store: t, "123hjemmeside": t, myspreadshop: t }], dm: ue, do: [1, { art: e, com: e, edu: e, gob: e, gov: e, mil: e, net: e, org: e, sld: e, web: e }], dz: [1, { art: e, asso: e, com: e, edu: e, gov: e, net: e, org: e, pol: e, soc: e, tm: e }], ec: [1, { com: e, edu: e, fin: e, gob: e, gov: e, info: e, k12: e, med: e, mil: e, net: e, org: e, pro: e, base: t, official: t }], edu: [1, { rit: [0, { "git-pages": t }] }], ee: [1, { aip: e, com: e, edu: e, fie: e, gov: e, lib: e, med: e, org: e, pri: e, riik: e }], eg: [1, { ac: e, com: e, edu: e, eun: e, gov: e, info: e, me: e, mil: e, name: e, net: e, org: e, sci: e, sport: e, tv: e }], er: m, es: [1, { com: e, edu: e, gob: e, nom: e, org: e, "123miweb": t, myspreadshop: t }], et: [1, { biz: e, com: e, edu: e, gov: e, info: e, name: e, net: e, org: e }], eu: [1, { airkitapps: t, cloudns: t, dogado: [0, { jelastic: t }], barsy: t, spdns: t, transurl: o, diskstation: t }], fi: [1, { aland: e, dy: t, "xn--hkkinen-5wa": t, häkkinen: t, iki: t, cloudplatform: [0, { fi: t }], datacenter: [0, { demo: t, paas: t }], kapsi: t, "123kotisivu": t, myspreadshop: t }], fj: [1, { ac: e, biz: e, com: e, gov: e, info: e, mil: e, name: e, net: e, org: e, pro: e }], fk: m, fm: [1, { com: e, edu: e, net: e, org: e, radio: t, user: o }], fo: e, fr: [1, { asso: e, com: e, gouv: e, nom: e, prd: e, tm: e, avoues: e, cci: e, greta: e, "huissier-justice": e, "en-root": t, "fbx-os": t, fbxos: t, "freebox-os": t, freeboxos: t, goupile: t, "123siteweb": t, "on-web": t, "chirurgiens-dentistes-en-france": t, dedibox: t, aeroport: t, avocat: t, chambagri: t, "chirurgiens-dentistes": t, "experts-comptables": t, medecin: t, notaires: t, pharmacien: t, port: t, veterinaire: t, myspreadshop: t, ynh: t }], ga: e, gb: e, gd: [1, { edu: e, gov: e }], ge: [1, { com: e, edu: e, gov: e, net: e, org: e, pvt: e, school: e }], gf: e, gg: [1, { co: e, net: e, org: e, botdash: t, kaas: t, stackit: t, panel: [2, { daemon: t }] }], gh: [1, { com: e, edu: e, gov: e, mil: e, org: e }], gi: [1, { com: e, edu: e, gov: e, ltd: e, mod: e, org: e }], gl: [1, { co: e, com: e, edu: e, net: e, org: e, biz: t }], gm: e, gn: [1, { ac: e, com: e, edu: e, gov: e, net: e, org: e }], gov: e, gp: [1, { asso: e, com: e, edu: e, mobi: e, net: e, org: e }], gq: e, gr: [1, { com: e, edu: e, gov: e, net: e, org: e, barsy: t, simplesite: t }], gs: e, gt: [1, { com: e, edu: e, gob: e, ind: e, mil: e, net: e, org: e }], gu: [1, { com: e, edu: e, gov: e, guam: e, info: e, net: e, org: e, web: e }], gw: e, gy: ue, hk: [1, { com: e, edu: e, gov: e, idv: e, net: e, org: e, "xn--ciqpn": e, 个人: e, "xn--gmqw5a": e, 個人: e, "xn--55qx5d": e, 公司: e, "xn--mxtq1m": e, 政府: e, "xn--lcvr32d": e, 敎育: e, "xn--wcvs22d": e, 教育: e, "xn--gmq050i": e, 箇人: e, "xn--uc0atv": e, 組織: e, "xn--uc0ay4a": e, 組织: e, "xn--od0alg": e, 網絡: e, "xn--zf0avx": e, 網络: e, "xn--mk0axi": e, 组織: e, "xn--tn0ag": e, 组织: e, "xn--od0aq3b": e, 网絡: e, "xn--io0a7i": e, 网络: e, inc: t, ltd: t }], hm: e, hn: [1, { com: e, edu: e, gob: e, mil: e, net: e, org: e }], hr: [1, { com: e, from: e, iz: e, name: e, brendly: ga }], ht: [1, { adult: e, art: e, asso: e, com: e, coop: e, edu: e, firm: e, gouv: e, info: e, med: e, net: e, org: e, perso: e, pol: e, pro: e, rel: e, shop: e, rt: t }], hu: [1, { 2e3: e, agrar: e, bolt: e, casino: e, city: e, co: e, erotica: e, erotika: e, film: e, forum: e, games: e, hotel: e, info: e, ingatlan: e, jogasz: e, konyvelo: e, lakas: e, media: e, news: e, org: e, priv: e, reklam: e, sex: e, shop: e, sport: e, suli: e, szex: e, tm: e, tozsde: e, utazas: e, video: e }], id: [1, { ac: e, biz: e, co: e, desa: e, go: e, mil: e, my: e, net: e, or: e, ponpes: e, sch: e, web: e, zone: t }], ie: [1, { gov: e, myspreadshop: t }], il: [1, { ac: e, co: [1, { ravpage: t, mytabit: t, tabitorder: t }], gov: e, idf: e, k12: e, muni: e, net: e, org: e }], "xn--4dbrk0ce": [1, { "xn--4dbgdty6c": e, "xn--5dbhl8d": e, "xn--8dbq2a": e, "xn--hebda8b": e }], ישראל: [1, { אקדמיה: e, ישוב: e, צהל: e, ממשל: e }], im: [1, { ac: e, co: [1, { ltd: e, plc: e }], com: e, net: e, org: e, tt: e, tv: e }], in: [1, { "5g": e, "6g": e, ac: e, ai: e, am: e, bihar: e, biz: e, business: e, ca: e, cn: e, co: e, com: e, coop: e, cs: e, delhi: e, dr: e, edu: e, er: e, firm: e, gen: e, gov: e, gujarat: e, ind: e, info: e, int: e, internet: e, io: e, me: e, mil: e, net: e, nic: e, org: e, pg: e, post: e, pro: e, res: e, travel: e, tv: e, uk: e, up: e, us: e, cloudns: t, barsy: t, web: t, supabase: t }], info: [1, { cloudns: t, "dynamic-dns": t, "barrel-of-knowledge": t, "barrell-of-knowledge": t, dyndns: t, "for-our": t, "groks-the": t, "groks-this": t, "here-for-more": t, knowsitall: t, selfip: t, webhop: t, barsy: t, mayfirst: t, mittwald: t, mittwaldserver: t, typo3server: t, dvrcam: t, ilovecollege: t, "no-ip": t, forumz: t, nsupdate: t, dnsupdate: t, "v-info": t }], int: [1, { eu: e }], io: [1, { 2038: t, co: e, com: e, edu: e, gov: e, mil: e, net: e, nom: e, org: e, "on-acorn": o, myaddr: t, apigee: t, "b-data": t, beagleboard: t, bitbucket: t, bluebite: t, boxfuse: t, brave: i, browsersafetymark: t, bubble: $n, bubbleapps: t, bigv: [0, { uk0: t }], cleverapps: t, cloudbeesusercontent: t, dappnode: [0, { dyndns: t }], darklang: t, definima: t, dedyn: t, "fh-muenster": t, shw: t, forgerock: [0, { id: t }], github: t, gitlab: t, lolipop: t, "hasura-app": t, hostyhosting: t, hypernode: t, moonscale: o, beebyte: ve, beebyteapp: [0, { sekd1: t }], jele: t, webthings: t, loginline: t, barsy: t, azurecontainer: o, ngrok: [2, { ap: t, au: t, eu: t, in: t, jp: t, sa: t, us: t }], nodeart: [0, { stage: t }], pantheonsite: t, pstmn: [2, { mock: t }], protonet: t, qcx: [2, { sys: o }], qoto: t, vaporcloud: t, myrdbx: t, "rb-hosting": Oe, "on-k3s": o, "on-rio": o, readthedocs: t, resindevice: t, resinstaging: [0, { devices: t }], hzc: t, sandcats: t, scrypted: [0, { client: t }], "mo-siemens": t, lair: re, stolos: o, musician: t, utwente: t, edugit: t, telebit: t, thingdust: [0, { dev: Go, disrec: Go, prod: ma, testing: Go }], tickets: t, webflow: t, webflowtest: t, editorx: t, wixstudio: t, basicserver: t, virtualserver: t }], iq: r, ir: [1, { ac: e, co: e, gov: e, id: e, net: e, org: e, sch: e, "xn--mgba3a4f16a": e, ایران: e, "xn--mgba3a4fra": e, ايران: e, arvanedge: t }], is: e, it: [1, { edu: e, gov: e, abr: e, abruzzo: e, "aosta-valley": e, aostavalley: e, bas: e, basilicata: e, cal: e, calabria: e, cam: e, campania: e, "emilia-romagna": e, emiliaromagna: e, emr: e, "friuli-v-giulia": e, "friuli-ve-giulia": e, "friuli-vegiulia": e, "friuli-venezia-giulia": e, "friuli-veneziagiulia": e, "friuli-vgiulia": e, "friuliv-giulia": e, "friulive-giulia": e, friulivegiulia: e, "friulivenezia-giulia": e, friuliveneziagiulia: e, friulivgiulia: e, fvg: e, laz: e, lazio: e, lig: e, liguria: e, lom: e, lombardia: e, lombardy: e, lucania: e, mar: e, marche: e, mol: e, molise: e, piedmont: e, piemonte: e, pmn: e, pug: e, puglia: e, sar: e, sardegna: e, sardinia: e, sic: e, sicilia: e, sicily: e, taa: e, tos: e, toscana: e, "trentin-sud-tirol": e, "xn--trentin-sd-tirol-rzb": e, "trentin-süd-tirol": e, "trentin-sudtirol": e, "xn--trentin-sdtirol-7vb": e, "trentin-südtirol": e, "trentin-sued-tirol": e, "trentin-suedtirol": e, trentino: e, "trentino-a-adige": e, "trentino-aadige": e, "trentino-alto-adige": e, "trentino-altoadige": e, "trentino-s-tirol": e, "trentino-stirol": e, "trentino-sud-tirol": e, "xn--trentino-sd-tirol-c3b": e, "trentino-süd-tirol": e, "trentino-sudtirol": e, "xn--trentino-sdtirol-szb": e, "trentino-südtirol": e, "trentino-sued-tirol": e, "trentino-suedtirol": e, "trentinoa-adige": e, trentinoaadige: e, "trentinoalto-adige": e, trentinoaltoadige: e, "trentinos-tirol": e, trentinostirol: e, "trentinosud-tirol": e, "xn--trentinosd-tirol-rzb": e, "trentinosüd-tirol": e, trentinosudtirol: e, "xn--trentinosdtirol-7vb": e, trentinosüdtirol: e, "trentinosued-tirol": e, trentinosuedtirol: e, "trentinsud-tirol": e, "xn--trentinsd-tirol-6vb": e, "trentinsüd-tirol": e, trentinsudtirol: e, "xn--trentinsdtirol-nsb": e, trentinsüdtirol: e, "trentinsued-tirol": e, trentinsuedtirol: e, tuscany: e, umb: e, umbria: e, "val-d-aosta": e, "val-daosta": e, "vald-aosta": e, valdaosta: e, "valle-aosta": e, "valle-d-aosta": e, "valle-daosta": e, valleaosta: e, "valled-aosta": e, valledaosta: e, "vallee-aoste": e, "xn--valle-aoste-ebb": e, "vallée-aoste": e, "vallee-d-aoste": e, "xn--valle-d-aoste-ehb": e, "vallée-d-aoste": e, valleeaoste: e, "xn--valleaoste-e7a": e, valléeaoste: e, valleedaoste: e, "xn--valledaoste-ebb": e, valléedaoste: e, vao: e, vda: e, ven: e, veneto: e, ag: e, agrigento: e, al: e, alessandria: e, "alto-adige": e, altoadige: e, an: e, ancona: e, "andria-barletta-trani": e, "andria-trani-barletta": e, andriabarlettatrani: e, andriatranibarletta: e, ao: e, aosta: e, aoste: e, ap: e, aq: e, aquila: e, ar: e, arezzo: e, "ascoli-piceno": e, ascolipiceno: e, asti: e, at: e, av: e, avellino: e, ba: e, balsan: e, "balsan-sudtirol": e, "xn--balsan-sdtirol-nsb": e, "balsan-südtirol": e, "balsan-suedtirol": e, bari: e, "barletta-trani-andria": e, barlettatraniandria: e, belluno: e, benevento: e, bergamo: e, bg: e, bi: e, biella: e, bl: e, bn: e, bo: e, bologna: e, bolzano: e, "bolzano-altoadige": e, bozen: e, "bozen-sudtirol": e, "xn--bozen-sdtirol-2ob": e, "bozen-südtirol": e, "bozen-suedtirol": e, br: e, brescia: e, brindisi: e, bs: e, bt: e, bulsan: e, "bulsan-sudtirol": e, "xn--bulsan-sdtirol-nsb": e, "bulsan-südtirol": e, "bulsan-suedtirol": e, bz: e, ca: e, cagliari: e, caltanissetta: e, "campidano-medio": e, campidanomedio: e, campobasso: e, "carbonia-iglesias": e, carboniaiglesias: e, "carrara-massa": e, carraramassa: e, caserta: e, catania: e, catanzaro: e, cb: e, ce: e, "cesena-forli": e, "xn--cesena-forl-mcb": e, "cesena-forlì": e, cesenaforli: e, "xn--cesenaforl-i8a": e, cesenaforlì: e, ch: e, chieti: e, ci: e, cl: e, cn: e, co: e, como: e, cosenza: e, cr: e, cremona: e, crotone: e, cs: e, ct: e, cuneo: e, cz: e, "dell-ogliastra": e, dellogliastra: e, en: e, enna: e, fc: e, fe: e, fermo: e, ferrara: e, fg: e, fi: e, firenze: e, florence: e, fm: e, foggia: e, "forli-cesena": e, "xn--forl-cesena-fcb": e, "forlì-cesena": e, forlicesena: e, "xn--forlcesena-c8a": e, forlìcesena: e, fr: e, frosinone: e, ge: e, genoa: e, genova: e, go: e, gorizia: e, gr: e, grosseto: e, "iglesias-carbonia": e, iglesiascarbonia: e, im: e, imperia: e, is: e, isernia: e, kr: e, "la-spezia": e, laquila: e, laspezia: e, latina: e, lc: e, le: e, lecce: e, lecco: e, li: e, livorno: e, lo: e, lodi: e, lt: e, lu: e, lucca: e, macerata: e, mantova: e, "massa-carrara": e, massacarrara: e, matera: e, mb: e, mc: e, me: e, "medio-campidano": e, mediocampidano: e, messina: e, mi: e, milan: e, milano: e, mn: e, mo: e, modena: e, monza: e, "monza-brianza": e, "monza-e-della-brianza": e, monzabrianza: e, monzaebrianza: e, monzaedellabrianza: e, ms: e, mt: e, na: e, naples: e, napoli: e, no: e, novara: e, nu: e, nuoro: e, og: e, ogliastra: e, "olbia-tempio": e, olbiatempio: e, or: e, oristano: e, ot: e, pa: e, padova: e, padua: e, palermo: e, parma: e, pavia: e, pc: e, pd: e, pe: e, perugia: e, "pesaro-urbino": e, pesarourbino: e, pescara: e, pg: e, pi: e, piacenza: e, pisa: e, pistoia: e, pn: e, po: e, pordenone: e, potenza: e, pr: e, prato: e, pt: e, pu: e, pv: e, pz: e, ra: e, ragusa: e, ravenna: e, rc: e, re: e, "reggio-calabria": e, "reggio-emilia": e, reggiocalabria: e, reggioemilia: e, rg: e, ri: e, rieti: e, rimini: e, rm: e, rn: e, ro: e, roma: e, rome: e, rovigo: e, sa: e, salerno: e, sassari: e, savona: e, si: e, siena: e, siracusa: e, so: e, sondrio: e, sp: e, sr: e, ss: e, "xn--sdtirol-n2a": e, südtirol: e, suedtirol: e, sv: e, ta: e, taranto: e, te: e, "tempio-olbia": e, tempioolbia: e, teramo: e, terni: e, tn: e, to: e, torino: e, tp: e, tr: e, "trani-andria-barletta": e, "trani-barletta-andria": e, traniandriabarletta: e, tranibarlettaandria: e, trapani: e, trento: e, treviso: e, trieste: e, ts: e, turin: e, tv: e, ud: e, udine: e, "urbino-pesaro": e, urbinopesaro: e, va: e, varese: e, vb: e, vc: e, ve: e, venezia: e, venice: e, verbania: e, vercelli: e, verona: e, vi: e, "vibo-valentia": e, vibovalentia: e, vicenza: e, viterbo: e, vr: e, vs: e, vt: e, vv: e, "12chars": t, ibxos: t, iliadboxos: t, neen: [0, { jc: t }], "123homepage": t, "16-b": t, "32-b": t, "64-b": t, myspreadshop: t, syncloud: t }], je: [1, { co: e, net: e, org: e, of: t }], jm: m, jo: [1, { agri: e, ai: e, com: e, edu: e, eng: e, fm: e, gov: e, mil: e, net: e, org: e, per: e, phd: e, sch: e, tv: e }], jobs: e, jp: [1, { ac: e, ad: e, co: e, ed: e, go: e, gr: e, lg: e, ne: [1, { aseinet: pa, gehirn: t, ivory: t, "mail-box": t, mints: t, mokuren: t, opal: t, sakura: t, sumomo: t, topaz: t }], or: e, aichi: [1, { aisai: e, ama: e, anjo: e, asuke: e, chiryu: e, chita: e, fuso: e, gamagori: e, handa: e, hazu: e, hekinan: e, higashiura: e, ichinomiya: e, inazawa: e, inuyama: e, isshiki: e, iwakura: e, kanie: e, kariya: e, kasugai: e, kira: e, kiyosu: e, komaki: e, konan: e, kota: e, mihama: e, miyoshi: e, nishio: e, nisshin: e, obu: e, oguchi: e, oharu: e, okazaki: e, owariasahi: e, seto: e, shikatsu: e, shinshiro: e, shitara: e, tahara: e, takahama: e, tobishima: e, toei: e, togo: e, tokai: e, tokoname: e, toyoake: e, toyohashi: e, toyokawa: e, toyone: e, toyota: e, tsushima: e, yatomi: e }], akita: [1, { akita: e, daisen: e, fujisato: e, gojome: e, hachirogata: e, happou: e, higashinaruse: e, honjo: e, honjyo: e, ikawa: e, kamikoani: e, kamioka: e, katagami: e, kazuno: e, kitaakita: e, kosaka: e, kyowa: e, misato: e, mitane: e, moriyoshi: e, nikaho: e, noshiro: e, odate: e, oga: e, ogata: e, semboku: e, yokote: e, yurihonjo: e }], aomori: [1, { aomori: e, gonohe: e, hachinohe: e, hashikami: e, hiranai: e, hirosaki: e, itayanagi: e, kuroishi: e, misawa: e, mutsu: e, nakadomari: e, noheji: e, oirase: e, owani: e, rokunohe: e, sannohe: e, shichinohe: e, shingo: e, takko: e, towada: e, tsugaru: e, tsuruta: e }], chiba: [1, { abiko: e, asahi: e, chonan: e, chosei: e, choshi: e, chuo: e, funabashi: e, futtsu: e, hanamigawa: e, ichihara: e, ichikawa: e, ichinomiya: e, inzai: e, isumi: e, kamagaya: e, kamogawa: e, kashiwa: e, katori: e, katsuura: e, kimitsu: e, kisarazu: e, kozaki: e, kujukuri: e, kyonan: e, matsudo: e, midori: e, mihama: e, minamiboso: e, mobara: e, mutsuzawa: e, nagara: e, nagareyama: e, narashino: e, narita: e, noda: e, oamishirasato: e, omigawa: e, onjuku: e, otaki: e, sakae: e, sakura: e, shimofusa: e, shirako: e, shiroi: e, shisui: e, sodegaura: e, sosa: e, tako: e, tateyama: e, togane: e, tohnosho: e, tomisato: e, urayasu: e, yachimata: e, yachiyo: e, yokaichiba: e, yokoshibahikari: e, yotsukaido: e }], ehime: [1, { ainan: e, honai: e, ikata: e, imabari: e, iyo: e, kamijima: e, kihoku: e, kumakogen: e, masaki: e, matsuno: e, matsuyama: e, namikata: e, niihama: e, ozu: e, saijo: e, seiyo: e, shikokuchuo: e, tobe: e, toon: e, uchiko: e, uwajima: e, yawatahama: e }], fukui: [1, { echizen: e, eiheiji: e, fukui: e, ikeda: e, katsuyama: e, mihama: e, minamiechizen: e, obama: e, ohi: e, ono: e, sabae: e, sakai: e, takahama: e, tsuruga: e, wakasa: e }], fukuoka: [1, { ashiya: e, buzen: e, chikugo: e, chikuho: e, chikujo: e, chikushino: e, chikuzen: e, chuo: e, dazaifu: e, fukuchi: e, hakata: e, higashi: e, hirokawa: e, hisayama: e, iizuka: e, inatsuki: e, kaho: e, kasuga: e, kasuya: e, kawara: e, keisen: e, koga: e, kurate: e, kurogi: e, kurume: e, minami: e, miyako: e, miyama: e, miyawaka: e, mizumaki: e, munakata: e, nakagawa: e, nakama: e, nishi: e, nogata: e, ogori: e, okagaki: e, okawa: e, oki: e, omuta: e, onga: e, onojo: e, oto: e, saigawa: e, sasaguri: e, shingu: e, shinyoshitomi: e, shonai: e, soeda: e, sue: e, tachiarai: e, tagawa: e, takata: e, toho: e, toyotsu: e, tsuiki: e, ukiha: e, umi: e, usui: e, yamada: e, yame: e, yanagawa: e, yukuhashi: e }], fukushima: [1, { aizubange: e, aizumisato: e, aizuwakamatsu: e, asakawa: e, bandai: e, date: e, fukushima: e, furudono: e, futaba: e, hanawa: e, higashi: e, hirata: e, hirono: e, iitate: e, inawashiro: e, ishikawa: e, iwaki: e, izumizaki: e, kagamiishi: e, kaneyama: e, kawamata: e, kitakata: e, kitashiobara: e, koori: e, koriyama: e, kunimi: e, miharu: e, mishima: e, namie: e, nango: e, nishiaizu: e, nishigo: e, okuma: e, omotego: e, ono: e, otama: e, samegawa: e, shimogo: e, shirakawa: e, showa: e, soma: e, sukagawa: e, taishin: e, tamakawa: e, tanagura: e, tenei: e, yabuki: e, yamato: e, yamatsuri: e, yanaizu: e, yugawa: e }], gifu: [1, { anpachi: e, ena: e, gifu: e, ginan: e, godo: e, gujo: e, hashima: e, hichiso: e, hida: e, higashishirakawa: e, ibigawa: e, ikeda: e, kakamigahara: e, kani: e, kasahara: e, kasamatsu: e, kawaue: e, kitagata: e, mino: e, minokamo: e, mitake: e, mizunami: e, motosu: e, nakatsugawa: e, ogaki: e, sakahogi: e, seki: e, sekigahara: e, shirakawa: e, tajimi: e, takayama: e, tarui: e, toki: e, tomika: e, wanouchi: e, yamagata: e, yaotsu: e, yoro: e }], gunma: [1, { annaka: e, chiyoda: e, fujioka: e, higashiagatsuma: e, isesaki: e, itakura: e, kanna: e, kanra: e, katashina: e, kawaba: e, kiryu: e, kusatsu: e, maebashi: e, meiwa: e, midori: e, minakami: e, naganohara: e, nakanojo: e, nanmoku: e, numata: e, oizumi: e, ora: e, ota: e, shibukawa: e, shimonita: e, shinto: e, showa: e, takasaki: e, takayama: e, tamamura: e, tatebayashi: e, tomioka: e, tsukiyono: e, tsumagoi: e, ueno: e, yoshioka: e }], hiroshima: [1, { asaminami: e, daiwa: e, etajima: e, fuchu: e, fukuyama: e, hatsukaichi: e, higashihiroshima: e, hongo: e, jinsekikogen: e, kaita: e, kui: e, kumano: e, kure: e, mihara: e, miyoshi: e, naka: e, onomichi: e, osakikamijima: e, otake: e, saka: e, sera: e, seranishi: e, shinichi: e, shobara: e, takehara: e }], hokkaido: [1, { abashiri: e, abira: e, aibetsu: e, akabira: e, akkeshi: e, asahikawa: e, ashibetsu: e, ashoro: e, assabu: e, atsuma: e, bibai: e, biei: e, bifuka: e, bihoro: e, biratori: e, chippubetsu: e, chitose: e, date: e, ebetsu: e, embetsu: e, eniwa: e, erimo: e, esan: e, esashi: e, fukagawa: e, fukushima: e, furano: e, furubira: e, haboro: e, hakodate: e, hamatonbetsu: e, hidaka: e, higashikagura: e, higashikawa: e, hiroo: e, hokuryu: e, hokuto: e, honbetsu: e, horokanai: e, horonobe: e, ikeda: e, imakane: e, ishikari: e, iwamizawa: e, iwanai: e, kamifurano: e, kamikawa: e, kamishihoro: e, kamisunagawa: e, kamoenai: e, kayabe: e, kembuchi: e, kikonai: e, kimobetsu: e, kitahiroshima: e, kitami: e, kiyosato: e, koshimizu: e, kunneppu: e, kuriyama: e, kuromatsunai: e, kushiro: e, kutchan: e, kyowa: e, mashike: e, matsumae: e, mikasa: e, minamifurano: e, mombetsu: e, moseushi: e, mukawa: e, muroran: e, naie: e, nakagawa: e, nakasatsunai: e, nakatombetsu: e, nanae: e, nanporo: e, nayoro: e, nemuro: e, niikappu: e, niki: e, nishiokoppe: e, noboribetsu: e, numata: e, obihiro: e, obira: e, oketo: e, okoppe: e, otaru: e, otobe: e, otofuke: e, otoineppu: e, oumu: e, ozora: e, pippu: e, rankoshi: e, rebun: e, rikubetsu: e, rishiri: e, rishirifuji: e, saroma: e, sarufutsu: e, shakotan: e, shari: e, shibecha: e, shibetsu: e, shikabe: e, shikaoi: e, shimamaki: e, shimizu: e, shimokawa: e, shinshinotsu: e, shintoku: e, shiranuka: e, shiraoi: e, shiriuchi: e, sobetsu: e, sunagawa: e, taiki: e, takasu: e, takikawa: e, takinoue: e, teshikaga: e, tobetsu: e, tohma: e, tomakomai: e, tomari: e, toya: e, toyako: e, toyotomi: e, toyoura: e, tsubetsu: e, tsukigata: e, urakawa: e, urausu: e, uryu: e, utashinai: e, wakkanai: e, wassamu: e, yakumo: e, yoichi: e }], hyogo: [1, { aioi: e, akashi: e, ako: e, amagasaki: e, aogaki: e, asago: e, ashiya: e, awaji: e, fukusaki: e, goshiki: e, harima: e, himeji: e, ichikawa: e, inagawa: e, itami: e, kakogawa: e, kamigori: e, kamikawa: e, kasai: e, kasuga: e, kawanishi: e, miki: e, minamiawaji: e, nishinomiya: e, nishiwaki: e, ono: e, sanda: e, sannan: e, sasayama: e, sayo: e, shingu: e, shinonsen: e, shiso: e, sumoto: e, taishi: e, taka: e, takarazuka: e, takasago: e, takino: e, tamba: e, tatsuno: e, toyooka: e, yabu: e, yashiro: e, yoka: e, yokawa: e }], ibaraki: [1, { ami: e, asahi: e, bando: e, chikusei: e, daigo: e, fujishiro: e, hitachi: e, hitachinaka: e, hitachiomiya: e, hitachiota: e, ibaraki: e, ina: e, inashiki: e, itako: e, iwama: e, joso: e, kamisu: e, kasama: e, kashima: e, kasumigaura: e, koga: e, miho: e, mito: e, moriya: e, naka: e, namegata: e, oarai: e, ogawa: e, omitama: e, ryugasaki: e, sakai: e, sakuragawa: e, shimodate: e, shimotsuma: e, shirosato: e, sowa: e, suifu: e, takahagi: e, tamatsukuri: e, tokai: e, tomobe: e, tone: e, toride: e, tsuchiura: e, tsukuba: e, uchihara: e, ushiku: e, yachiyo: e, yamagata: e, yawara: e, yuki: e }], ishikawa: [1, { anamizu: e, hakui: e, hakusan: e, kaga: e, kahoku: e, kanazawa: e, kawakita: e, komatsu: e, nakanoto: e, nanao: e, nomi: e, nonoichi: e, noto: e, shika: e, suzu: e, tsubata: e, tsurugi: e, uchinada: e, wajima: e }], iwate: [1, { fudai: e, fujisawa: e, hanamaki: e, hiraizumi: e, hirono: e, ichinohe: e, ichinoseki: e, iwaizumi: e, iwate: e, joboji: e, kamaishi: e, kanegasaki: e, karumai: e, kawai: e, kitakami: e, kuji: e, kunohe: e, kuzumaki: e, miyako: e, mizusawa: e, morioka: e, ninohe: e, noda: e, ofunato: e, oshu: e, otsuchi: e, rikuzentakata: e, shiwa: e, shizukuishi: e, sumita: e, tanohata: e, tono: e, yahaba: e, yamada: e }], kagawa: [1, { ayagawa: e, higashikagawa: e, kanonji: e, kotohira: e, manno: e, marugame: e, mitoyo: e, naoshima: e, sanuki: e, tadotsu: e, takamatsu: e, tonosho: e, uchinomi: e, utazu: e, zentsuji: e }], kagoshima: [1, { akune: e, amami: e, hioki: e, isa: e, isen: e, izumi: e, kagoshima: e, kanoya: e, kawanabe: e, kinko: e, kouyama: e, makurazaki: e, matsumoto: e, minamitane: e, nakatane: e, nishinoomote: e, satsumasendai: e, soo: e, tarumizu: e, yusui: e }], kanagawa: [1, { aikawa: e, atsugi: e, ayase: e, chigasaki: e, ebina: e, fujisawa: e, hadano: e, hakone: e, hiratsuka: e, isehara: e, kaisei: e, kamakura: e, kiyokawa: e, matsuda: e, minamiashigara: e, miura: e, nakai: e, ninomiya: e, odawara: e, oi: e, oiso: e, sagamihara: e, samukawa: e, tsukui: e, yamakita: e, yamato: e, yokosuka: e, yugawara: e, zama: e, zushi: e }], kochi: [1, { aki: e, geisei: e, hidaka: e, higashitsuno: e, ino: e, kagami: e, kami: e, kitagawa: e, kochi: e, mihara: e, motoyama: e, muroto: e, nahari: e, nakamura: e, nankoku: e, nishitosa: e, niyodogawa: e, ochi: e, okawa: e, otoyo: e, otsuki: e, sakawa: e, sukumo: e, susaki: e, tosa: e, tosashimizu: e, toyo: e, tsuno: e, umaji: e, yasuda: e, yusuhara: e }], kumamoto: [1, { amakusa: e, arao: e, aso: e, choyo: e, gyokuto: e, kamiamakusa: e, kikuchi: e, kumamoto: e, mashiki: e, mifune: e, minamata: e, minamioguni: e, nagasu: e, nishihara: e, oguni: e, ozu: e, sumoto: e, takamori: e, uki: e, uto: e, yamaga: e, yamato: e, yatsushiro: e }], kyoto: [1, { ayabe: e, fukuchiyama: e, higashiyama: e, ide: e, ine: e, joyo: e, kameoka: e, kamo: e, kita: e, kizu: e, kumiyama: e, kyotamba: e, kyotanabe: e, kyotango: e, maizuru: e, minami: e, minamiyamashiro: e, miyazu: e, muko: e, nagaokakyo: e, nakagyo: e, nantan: e, oyamazaki: e, sakyo: e, seika: e, tanabe: e, uji: e, ujitawara: e, wazuka: e, yamashina: e, yawata: e }], mie: [1, { asahi: e, inabe: e, ise: e, kameyama: e, kawagoe: e, kiho: e, kisosaki: e, kiwa: e, komono: e, kumano: e, kuwana: e, matsusaka: e, meiwa: e, mihama: e, minamiise: e, misugi: e, miyama: e, nabari: e, shima: e, suzuka: e, tado: e, taiki: e, taki: e, tamaki: e, toba: e, tsu: e, udono: e, ureshino: e, watarai: e, yokkaichi: e }], miyagi: [1, { furukawa: e, higashimatsushima: e, ishinomaki: e, iwanuma: e, kakuda: e, kami: e, kawasaki: e, marumori: e, matsushima: e, minamisanriku: e, misato: e, murata: e, natori: e, ogawara: e, ohira: e, onagawa: e, osaki: e, rifu: e, semine: e, shibata: e, shichikashuku: e, shikama: e, shiogama: e, shiroishi: e, tagajo: e, taiwa: e, tome: e, tomiya: e, wakuya: e, watari: e, yamamoto: e, zao: e }], miyazaki: [1, { aya: e, ebino: e, gokase: e, hyuga: e, kadogawa: e, kawaminami: e, kijo: e, kitagawa: e, kitakata: e, kitaura: e, kobayashi: e, kunitomi: e, kushima: e, mimata: e, miyakonojo: e, miyazaki: e, morotsuka: e, nichinan: e, nishimera: e, nobeoka: e, saito: e, shiiba: e, shintomi: e, takaharu: e, takanabe: e, takazaki: e, tsuno: e }], nagano: [1, { achi: e, agematsu: e, anan: e, aoki: e, asahi: e, azumino: e, chikuhoku: e, chikuma: e, chino: e, fujimi: e, hakuba: e, hara: e, hiraya: e, iida: e, iijima: e, iiyama: e, iizuna: e, ikeda: e, ikusaka: e, ina: e, karuizawa: e, kawakami: e, kiso: e, kisofukushima: e, kitaaiki: e, komagane: e, komoro: e, matsukawa: e, matsumoto: e, miasa: e, minamiaiki: e, minamimaki: e, minamiminowa: e, minowa: e, miyada: e, miyota: e, mochizuki: e, nagano: e, nagawa: e, nagiso: e, nakagawa: e, nakano: e, nozawaonsen: e, obuse: e, ogawa: e, okaya: e, omachi: e, omi: e, ookuwa: e, ooshika: e, otaki: e, otari: e, sakae: e, sakaki: e, saku: e, sakuho: e, shimosuwa: e, shinanomachi: e, shiojiri: e, suwa: e, suzaka: e, takagi: e, takamori: e, takayama: e, tateshina: e, tatsuno: e, togakushi: e, togura: e, tomi: e, ueda: e, wada: e, yamagata: e, yamanouchi: e, yasaka: e, yasuoka: e }], nagasaki: [1, { chijiwa: e, futsu: e, goto: e, hasami: e, hirado: e, iki: e, isahaya: e, kawatana: e, kuchinotsu: e, matsuura: e, nagasaki: e, obama: e, omura: e, oseto: e, saikai: e, sasebo: e, seihi: e, shimabara: e, shinkamigoto: e, togitsu: e, tsushima: e, unzen: e }], nara: [1, { ando: e, gose: e, heguri: e, higashiyoshino: e, ikaruga: e, ikoma: e, kamikitayama: e, kanmaki: e, kashiba: e, kashihara: e, katsuragi: e, kawai: e, kawakami: e, kawanishi: e, koryo: e, kurotaki: e, mitsue: e, miyake: e, nara: e, nosegawa: e, oji: e, ouda: e, oyodo: e, sakurai: e, sango: e, shimoichi: e, shimokitayama: e, shinjo: e, soni: e, takatori: e, tawaramoto: e, tenkawa: e, tenri: e, uda: e, yamatokoriyama: e, yamatotakada: e, yamazoe: e, yoshino: e }], niigata: [1, { aga: e, agano: e, gosen: e, itoigawa: e, izumozaki: e, joetsu: e, kamo: e, kariwa: e, kashiwazaki: e, minamiuonuma: e, mitsuke: e, muika: e, murakami: e, myoko: e, nagaoka: e, niigata: e, ojiya: e, omi: e, sado: e, sanjo: e, seiro: e, seirou: e, sekikawa: e, shibata: e, tagami: e, tainai: e, tochio: e, tokamachi: e, tsubame: e, tsunan: e, uonuma: e, yahiko: e, yoita: e, yuzawa: e }], oita: [1, { beppu: e, bungoono: e, bungotakada: e, hasama: e, hiji: e, himeshima: e, hita: e, kamitsue: e, kokonoe: e, kuju: e, kunisaki: e, kusu: e, oita: e, saiki: e, taketa: e, tsukumi: e, usa: e, usuki: e, yufu: e }], okayama: [1, { akaiwa: e, asakuchi: e, bizen: e, hayashima: e, ibara: e, kagamino: e, kasaoka: e, kibichuo: e, kumenan: e, kurashiki: e, maniwa: e, misaki: e, nagi: e, niimi: e, nishiawakura: e, okayama: e, satosho: e, setouchi: e, shinjo: e, shoo: e, soja: e, takahashi: e, tamano: e, tsuyama: e, wake: e, yakage: e }], okinawa: [1, { aguni: e, ginowan: e, ginoza: e, gushikami: e, haebaru: e, higashi: e, hirara: e, iheya: e, ishigaki: e, ishikawa: e, itoman: e, izena: e, kadena: e, kin: e, kitadaito: e, kitanakagusuku: e, kumejima: e, kunigami: e, minamidaito: e, motobu: e, nago: e, naha: e, nakagusuku: e, nakijin: e, nanjo: e, nishihara: e, ogimi: e, okinawa: e, onna: e, shimoji: e, taketomi: e, tarama: e, tokashiki: e, tomigusuku: e, tonaki: e, urasoe: e, uruma: e, yaese: e, yomitan: e, yonabaru: e, yonaguni: e, zamami: e }], osaka: [1, { abeno: e, chihayaakasaka: e, chuo: e, daito: e, fujiidera: e, habikino: e, hannan: e, higashiosaka: e, higashisumiyoshi: e, higashiyodogawa: e, hirakata: e, ibaraki: e, ikeda: e, izumi: e, izumiotsu: e, izumisano: e, kadoma: e, kaizuka: e, kanan: e, kashiwara: e, katano: e, kawachinagano: e, kishiwada: e, kita: e, kumatori: e, matsubara: e, minato: e, minoh: e, misaki: e, moriguchi: e, neyagawa: e, nishi: e, nose: e, osakasayama: e, sakai: e, sayama: e, sennan: e, settsu: e, shijonawate: e, shimamoto: e, suita: e, tadaoka: e, taishi: e, tajiri: e, takaishi: e, takatsuki: e, tondabayashi: e, toyonaka: e, toyono: e, yao: e }], saga: [1, { ariake: e, arita: e, fukudomi: e, genkai: e, hamatama: e, hizen: e, imari: e, kamimine: e, kanzaki: e, karatsu: e, kashima: e, kitagata: e, kitahata: e, kiyama: e, kouhoku: e, kyuragi: e, nishiarita: e, ogi: e, omachi: e, ouchi: e, saga: e, shiroishi: e, taku: e, tara: e, tosu: e, yoshinogari: e }], saitama: [1, { arakawa: e, asaka: e, chichibu: e, fujimi: e, fujimino: e, fukaya: e, hanno: e, hanyu: e, hasuda: e, hatogaya: e, hatoyama: e, hidaka: e, higashichichibu: e, higashimatsuyama: e, honjo: e, ina: e, iruma: e, iwatsuki: e, kamiizumi: e, kamikawa: e, kamisato: e, kasukabe: e, kawagoe: e, kawaguchi: e, kawajima: e, kazo: e, kitamoto: e, koshigaya: e, kounosu: e, kuki: e, kumagaya: e, matsubushi: e, minano: e, misato: e, miyashiro: e, miyoshi: e, moroyama: e, nagatoro: e, namegawa: e, niiza: e, ogano: e, ogawa: e, ogose: e, okegawa: e, omiya: e, otaki: e, ranzan: e, ryokami: e, saitama: e, sakado: e, satte: e, sayama: e, shiki: e, shiraoka: e, soka: e, sugito: e, toda: e, tokigawa: e, tokorozawa: e, tsurugashima: e, urawa: e, warabi: e, yashio: e, yokoze: e, yono: e, yorii: e, yoshida: e, yoshikawa: e, yoshimi: e }], shiga: [1, { aisho: e, gamo: e, higashiomi: e, hikone: e, koka: e, konan: e, kosei: e, koto: e, kusatsu: e, maibara: e, moriyama: e, nagahama: e, nishiazai: e, notogawa: e, omihachiman: e, otsu: e, ritto: e, ryuoh: e, takashima: e, takatsuki: e, torahime: e, toyosato: e, yasu: e }], shimane: [1, { akagi: e, ama: e, gotsu: e, hamada: e, higashiizumo: e, hikawa: e, hikimi: e, izumo: e, kakinoki: e, masuda: e, matsue: e, misato: e, nishinoshima: e, ohda: e, okinoshima: e, okuizumo: e, shimane: e, tamayu: e, tsuwano: e, unnan: e, yakumo: e, yasugi: e, yatsuka: e }], shizuoka: [1, { arai: e, atami: e, fuji: e, fujieda: e, fujikawa: e, fujinomiya: e, fukuroi: e, gotemba: e, haibara: e, hamamatsu: e, higashiizu: e, ito: e, iwata: e, izu: e, izunokuni: e, kakegawa: e, kannami: e, kawanehon: e, kawazu: e, kikugawa: e, kosai: e, makinohara: e, matsuzaki: e, minamiizu: e, mishima: e, morimachi: e, nishiizu: e, numazu: e, omaezaki: e, shimada: e, shimizu: e, shimoda: e, shizuoka: e, susono: e, yaizu: e, yoshida: e }], tochigi: [1, { ashikaga: e, bato: e, haga: e, ichikai: e, iwafune: e, kaminokawa: e, kanuma: e, karasuyama: e, kuroiso: e, mashiko: e, mibu: e, moka: e, motegi: e, nasu: e, nasushiobara: e, nikko: e, nishikata: e, nogi: e, ohira: e, ohtawara: e, oyama: e, sakura: e, sano: e, shimotsuke: e, shioya: e, takanezawa: e, tochigi: e, tsuga: e, ujiie: e, utsunomiya: e, yaita: e }], tokushima: [1, { aizumi: e, anan: e, ichiba: e, itano: e, kainan: e, komatsushima: e, matsushige: e, mima: e, minami: e, miyoshi: e, mugi: e, nakagawa: e, naruto: e, sanagochi: e, shishikui: e, tokushima: e, wajiki: e }], tokyo: [1, { adachi: e, akiruno: e, akishima: e, aogashima: e, arakawa: e, bunkyo: e, chiyoda: e, chofu: e, chuo: e, edogawa: e, fuchu: e, fussa: e, hachijo: e, hachioji: e, hamura: e, higashikurume: e, higashimurayama: e, higashiyamato: e, hino: e, hinode: e, hinohara: e, inagi: e, itabashi: e, katsushika: e, kita: e, kiyose: e, kodaira: e, koganei: e, kokubunji: e, komae: e, koto: e, kouzushima: e, kunitachi: e, machida: e, meguro: e, minato: e, mitaka: e, mizuho: e, musashimurayama: e, musashino: e, nakano: e, nerima: e, ogasawara: e, okutama: e, ome: e, oshima: e, ota: e, setagaya: e, shibuya: e, shinagawa: e, shinjuku: e, suginami: e, sumida: e, tachikawa: e, taito: e, tama: e, toshima: e }], tottori: [1, { chizu: e, hino: e, kawahara: e, koge: e, kotoura: e, misasa: e, nanbu: e, nichinan: e, sakaiminato: e, tottori: e, wakasa: e, yazu: e, yonago: e }], toyama: [1, { asahi: e, fuchu: e, fukumitsu: e, funahashi: e, himi: e, imizu: e, inami: e, johana: e, kamiichi: e, kurobe: e, nakaniikawa: e, namerikawa: e, nanto: e, nyuzen: e, oyabe: e, taira: e, takaoka: e, tateyama: e, toga: e, tonami: e, toyama: e, unazuki: e, uozu: e, yamada: e }], wakayama: [1, { arida: e, aridagawa: e, gobo: e, hashimoto: e, hidaka: e, hirogawa: e, inami: e, iwade: e, kainan: e, kamitonda: e, katsuragi: e, kimino: e, kinokawa: e, kitayama: e, koya: e, koza: e, kozagawa: e, kudoyama: e, kushimoto: e, mihama: e, misato: e, nachikatsuura: e, shingu: e, shirahama: e, taiji: e, tanabe: e, wakayama: e, yuasa: e, yura: e }], yamagata: [1, { asahi: e, funagata: e, higashine: e, iide: e, kahoku: e, kaminoyama: e, kaneyama: e, kawanishi: e, mamurogawa: e, mikawa: e, murayama: e, nagai: e, nakayama: e, nanyo: e, nishikawa: e, obanazawa: e, oe: e, oguni: e, ohkura: e, oishida: e, sagae: e, sakata: e, sakegawa: e, shinjo: e, shirataka: e, shonai: e, takahata: e, tendo: e, tozawa: e, tsuruoka: e, yamagata: e, yamanobe: e, yonezawa: e, yuza: e }], yamaguchi: [1, { abu: e, hagi: e, hikari: e, hofu: e, iwakuni: e, kudamatsu: e, mitou: e, nagato: e, oshima: e, shimonoseki: e, shunan: e, tabuse: e, tokuyama: e, toyota: e, ube: e, yuu: e }], yamanashi: [1, { chuo: e, doshi: e, fuefuki: e, fujikawa: e, fujikawaguchiko: e, fujiyoshida: e, hayakawa: e, hokuto: e, ichikawamisato: e, kai: e, kofu: e, koshu: e, kosuge: e, "minami-alps": e, minobu: e, nakamichi: e, nanbu: e, narusawa: e, nirasaki: e, nishikatsura: e, oshino: e, otsuki: e, showa: e, tabayama: e, tsuru: e, uenohara: e, yamanakako: e, yamanashi: e }], "xn--ehqz56n": e, 三重: e, "xn--1lqs03n": e, 京都: e, "xn--qqqt11m": e, 佐賀: e, "xn--f6qx53a": e, 兵庫: e, "xn--djrs72d6uy": e, 北海道: e, "xn--mkru45i": e, 千葉: e, "xn--0trq7p7nn": e, 和歌山: e, "xn--5js045d": e, 埼玉: e, "xn--kbrq7o": e, 大分: e, "xn--pssu33l": e, 大阪: e, "xn--ntsq17g": e, 奈良: e, "xn--uisz3g": e, 宮城: e, "xn--6btw5a": e, 宮崎: e, "xn--1ctwo": e, 富山: e, "xn--6orx2r": e, 山口: e, "xn--rht61e": e, 山形: e, "xn--rht27z": e, 山梨: e, "xn--nit225k": e, 岐阜: e, "xn--rht3d": e, 岡山: e, "xn--djty4k": e, 岩手: e, "xn--klty5x": e, 島根: e, "xn--kltx9a": e, 広島: e, "xn--kltp7d": e, 徳島: e, "xn--c3s14m": e, 愛媛: e, "xn--vgu402c": e, 愛知: e, "xn--efvn9s": e, 新潟: e, "xn--1lqs71d": e, 東京: e, "xn--4pvxs": e, 栃木: e, "xn--uuwu58a": e, 沖縄: e, "xn--zbx025d": e, 滋賀: e, "xn--8pvr4u": e, 熊本: e, "xn--5rtp49c": e, 石川: e, "xn--ntso0iqx3a": e, 神奈川: e, "xn--elqq16h": e, 福井: e, "xn--4it168d": e, 福岡: e, "xn--klt787d": e, 福島: e, "xn--rny31h": e, 秋田: e, "xn--7t0a264c": e, 群馬: e, "xn--uist22h": e, 茨城: e, "xn--8ltr62k": e, 長崎: e, "xn--2m4a15e": e, 長野: e, "xn--32vp30h": e, 青森: e, "xn--4it797k": e, 静岡: e, "xn--5rtq34k": e, 香川: e, "xn--k7yn95e": e, 高知: e, "xn--tor131o": e, 鳥取: e, "xn--d5qv7z876c": e, 鹿児島: e, kawasaki: m, kitakyushu: m, kobe: m, nagoya: m, sapporo: m, sendai: m, yokohama: m, buyshop: t, fashionstore: t, handcrafted: t, kawaiishop: t, supersale: t, theshop: t, "0am": t, "0g0": t, "0j0": t, "0t0": t, mydns: t, pgw: t, wjg: t, usercontent: t, angry: t, babyblue: t, babymilk: t, backdrop: t, bambina: t, bitter: t, blush: t, boo: t, boy: t, boyfriend: t, but: t, candypop: t, capoo: t, catfood: t, cheap: t, chicappa: t, chillout: t, chips: t, chowder: t, chu: t, ciao: t, cocotte: t, coolblog: t, cranky: t, cutegirl: t, daa: t, deca: t, deci: t, digick: t, egoism: t, fakefur: t, fem: t, flier: t, floppy: t, fool: t, frenchkiss: t, girlfriend: t, girly: t, gloomy: t, gonna: t, greater: t, hacca: t, heavy: t, her: t, hiho: t, hippy: t, holy: t, hungry: t, icurus: t, itigo: t, jellybean: t, kikirara: t, kill: t, kilo: t, kuron: t, littlestar: t, lolipopmc: t, lolitapunk: t, lomo: t, lovepop: t, lovesick: t, main: t, mods: t, mond: t, mongolian: t, moo: t, namaste: t, nikita: t, nobushi: t, noor: t, oops: t, parallel: t, parasite: t, pecori: t, peewee: t, penne: t, pepper: t, perma: t, pigboat: t, pinoko: t, punyu: t, pupu: t, pussycat: t, pya: t, raindrop: t, readymade: t, sadist: t, schoolbus: t, secret: t, staba: t, stripper: t, sub: t, sunnyday: t, thick: t, tonkotsu: t, under: t, upper: t, velvet: t, verse: t, versus: t, vivian: t, watson: t, weblike: t, whitesnow: t, zombie: t, hateblo: t, hatenablog: t, hatenadiary: t, "2-d": t, bona: t, crap: t, daynight: t, eek: t, flop: t, halfmoon: t, jeez: t, matrix: t, mimoza: t, netgamers: t, nyanta: t, o0o0: t, rdy: t, rgr: t, rulez: t, sakurastorage: [0, { isk01: Xo, isk02: Xo }], saloon: t, sblo: t, skr: t, tank: t, "uh-oh": t, undo: t, webaccel: [0, { rs: t, user: t }], websozai: t, xii: t }], ke: [1, { ac: e, co: e, go: e, info: e, me: e, mobi: e, ne: e, or: e, sc: e }], kg: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, us: t }], kh: m, ki: ya, km: [1, { ass: e, com: e, edu: e, gov: e, mil: e, nom: e, org: e, prd: e, tm: e, asso: e, coop: e, gouv: e, medecin: e, notaires: e, pharmaciens: e, presse: e, veterinaire: e }], kn: [1, { edu: e, gov: e, net: e, org: e }], kp: [1, { com: e, edu: e, gov: e, org: e, rep: e, tra: e }], kr: [1, { ac: e, ai: e, co: e, es: e, go: e, hs: e, io: e, it: e, kg: e, me: e, mil: e, ms: e, ne: e, or: e, pe: e, re: e, sc: e, busan: e, chungbuk: e, chungnam: e, daegu: e, daejeon: e, gangwon: e, gwangju: e, gyeongbuk: e, gyeonggi: e, gyeongnam: e, incheon: e, jeju: e, jeonbuk: e, jeonnam: e, seoul: e, ulsan: e, c01: t, "eliv-dns": t }], kw: [1, { com: e, edu: e, emb: e, gov: e, ind: e, net: e, org: e }], ky: Y, kz: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, jcloud: t }], la: [1, { com: e, edu: e, gov: e, info: e, int: e, net: e, org: e, per: e, bnr: t }], lb: n, lc: [1, { co: e, com: e, edu: e, gov: e, net: e, org: e, oy: t }], li: e, lk: [1, { ac: e, assn: e, com: e, edu: e, gov: e, grp: e, hotel: e, int: e, ltd: e, net: e, ngo: e, org: e, sch: e, soc: e, web: e }], lr: n, ls: [1, { ac: e, biz: e, co: e, edu: e, gov: e, info: e, net: e, org: e, sc: e }], lt: l, lu: [1, { "123website": t }], lv: [1, { asn: e, com: e, conf: e, edu: e, gov: e, id: e, mil: e, net: e, org: e }], ly: [1, { com: e, edu: e, gov: e, id: e, med: e, net: e, org: e, plc: e, sch: e }], ma: [1, { ac: e, co: e, gov: e, net: e, org: e, press: e }], mc: [1, { asso: e, tm: e }], md: [1, { ir: t }], me: [1, { ac: e, co: e, edu: e, gov: e, its: e, net: e, org: e, priv: e, c66: t, craft: t, edgestack: t, filegear: t, glitch: t, "filegear-sg": t, lohmus: t, barsy: t, mcdir: t, brasilia: t, ddns: t, dnsfor: t, hopto: t, loginto: t, noip: t, webhop: t, soundcast: t, tcp4: t, vp4: t, diskstation: t, dscloud: t, i234: t, myds: t, synology: t, transip: Oe, nohost: t }], mg: [1, { co: e, com: e, edu: e, gov: e, mil: e, nom: e, org: e, prd: e }], mh: e, mil: e, mk: [1, { com: e, edu: e, gov: e, inf: e, name: e, net: e, org: e }], ml: [1, { ac: e, art: e, asso: e, com: e, edu: e, gouv: e, gov: e, info: e, inst: e, net: e, org: e, pr: e, presse: e }], mm: m, mn: [1, { edu: e, gov: e, org: e, nyc: t }], mo: n, mobi: [1, { barsy: t, dscloud: t }], mp: [1, { ju: t }], mq: e, mr: l, ms: [1, { com: e, edu: e, gov: e, net: e, org: e, minisite: t }], mt: Y, mu: [1, { ac: e, co: e, com: e, gov: e, net: e, or: e, org: e }], museum: e, mv: [1, { aero: e, biz: e, com: e, coop: e, edu: e, gov: e, info: e, int: e, mil: e, museum: e, name: e, net: e, org: e, pro: e }], mw: [1, { ac: e, biz: e, co: e, com: e, coop: e, edu: e, gov: e, int: e, net: e, org: e }], mx: [1, { com: e, edu: e, gob: e, net: e, org: e }], my: [1, { biz: e, com: e, edu: e, gov: e, mil: e, name: e, net: e, org: e }], mz: [1, { ac: e, adv: e, co: e, edu: e, gov: e, mil: e, net: e, org: e }], na: [1, { alt: e, co: e, com: e, gov: e, net: e, org: e }], name: [1, { her: va, his: va }], nc: [1, { asso: e, nom: e }], ne: e, net: [1, { adobeaemcloud: t, "adobeio-static": t, adobeioruntime: t, akadns: t, akamai: t, "akamai-staging": t, akamaiedge: t, "akamaiedge-staging": t, akamaihd: t, "akamaihd-staging": t, akamaiorigin: t, "akamaiorigin-staging": t, akamaized: t, "akamaized-staging": t, edgekey: t, "edgekey-staging": t, edgesuite: t, "edgesuite-staging": t, alwaysdata: t, myamaze: t, cloudfront: t, appudo: t, "atlassian-dev": [0, { prod: $n }], myfritz: t, onavstack: t, shopselect: t, blackbaudcdn: t, boomla: t, bplaced: t, square7: t, cdn77: [0, { r: t }], "cdn77-ssl": t, gb: t, hu: t, jp: t, se: t, uk: t, clickrising: t, "ddns-ip": t, "dns-cloud": t, "dns-dynamic": t, cloudaccess: t, cloudflare: [2, { cdn: t }], cloudflareanycast: $n, cloudflarecn: $n, cloudflareglobal: $n, ctfcloud: t, "feste-ip": t, "knx-server": t, "static-access": t, cryptonomic: o, dattolocal: t, mydatto: t, debian: t, definima: t, deno: t, "at-band-camp": t, blogdns: t, "broke-it": t, buyshouses: t, dnsalias: t, dnsdojo: t, "does-it": t, dontexist: t, dynalias: t, dynathome: t, endofinternet: t, "from-az": t, "from-co": t, "from-la": t, "from-ny": t, "gets-it": t, "ham-radio-op": t, homeftp: t, homeip: t, homelinux: t, homeunix: t, "in-the-band": t, "is-a-chef": t, "is-a-geek": t, "isa-geek": t, "kicks-ass": t, "office-on-the": t, podzone: t, "scrapper-site": t, selfip: t, "sells-it": t, servebbs: t, serveftp: t, thruhere: t, webhop: t, casacam: t, dynu: t, dynv6: t, twmail: t, ru: t, channelsdvr: [2, { u: t }], fastly: [0, { freetls: t, map: t, prod: [0, { a: t, global: t }], ssl: [0, { a: t, b: t, global: t }] }], fastlylb: [2, { map: t }], edgeapp: t, "keyword-on": t, "live-on": t, "server-on": t, "cdn-edges": t, heteml: t, cloudfunctions: t, "grafana-dev": t, iobb: t, moonscale: t, "in-dsl": t, "in-vpn": t, oninferno: t, botdash: t, "apps-1and1": t, ipifony: t, cloudjiffy: [2, { "fra1-de": t, "west1-us": t }], elastx: [0, { "jls-sto1": t, "jls-sto2": t, "jls-sto3": t }], massivegrid: [0, { paas: [0, { "fr-1": t, "lon-1": t, "lon-2": t, "ny-1": t, "ny-2": t, "sg-1": t }] }], saveincloud: [0, { jelastic: t, "nordeste-idc": t }], scaleforce: G, kinghost: t, uni5: t, krellian: t, ggff: t, localcert: t, localhostcert: t, localto: o, barsy: t, memset: t, "azure-api": t, "azure-mobile": t, azureedge: t, azurefd: t, azurestaticapps: [2, { 1: t, 2: t, 3: t, 4: t, 5: t, 6: t, 7: t, centralus: t, eastasia: t, eastus2: t, westeurope: t, westus2: t }], azurewebsites: t, cloudapp: t, trafficmanager: t, windows: [0, { core: [0, { blob: t }], servicebus: t }], mynetname: [0, { sn: t }], routingthecloud: t, bounceme: t, ddns: t, "eating-organic": t, mydissent: t, myeffect: t, mymediapc: t, mypsx: t, mysecuritycamera: t, nhlfan: t, "no-ip": t, pgafan: t, privatizehealthinsurance: t, redirectme: t, serveblog: t, serveminecraft: t, sytes: t, dnsup: t, hicam: t, "now-dns": t, ownip: t, vpndns: t, cloudycluster: t, ovh: [0, { hosting: o, webpaas: o }], rackmaze: t, myradweb: t, in: t, "subsc-pay": t, squares: t, schokokeks: t, "firewall-gateway": t, seidat: t, senseering: t, siteleaf: t, mafelo: t, myspreadshop: t, "vps-host": [2, { jelastic: [0, { atl: t, njs: t, ric: t }] }], srcf: [0, { soc: t, user: t }], supabase: t, dsmynas: t, familyds: t, ts: [2, { c: o }], torproject: [2, { pages: t }], vusercontent: t, "reserve-online": t, "community-pro": t, meinforum: t, yandexcloud: [2, { storage: t, website: t }], za: t }], nf: [1, { arts: e, com: e, firm: e, info: e, net: e, other: e, per: e, rec: e, store: e, web: e }], ng: [1, { com: e, edu: e, gov: e, i: e, mil: e, mobi: e, name: e, net: e, org: e, sch: e, biz: [2, { co: t, dl: t, go: t, lg: t, on: t }], col: t, firm: t, gen: t, ltd: t, ngo: t, plc: t }], ni: [1, { ac: e, biz: e, co: e, com: e, edu: e, gob: e, in: e, info: e, int: e, mil: e, net: e, nom: e, org: e, web: e }], nl: [1, { co: t, "hosting-cluster": t, gov: t, khplay: t, "123website": t, myspreadshop: t, transurl: o, cistron: t, demon: t }], no: [1, { fhs: e, folkebibl: e, fylkesbibl: e, idrett: e, museum: e, priv: e, vgs: e, dep: e, herad: e, kommune: e, mil: e, stat: e, aa: se, ah: se, bu: se, fm: se, hl: se, hm: se, "jan-mayen": se, mr: se, nl: se, nt: se, of: se, ol: se, oslo: se, rl: se, sf: se, st: se, svalbard: se, tm: se, tr: se, va: se, vf: se, akrehamn: e, "xn--krehamn-dxa": e, åkrehamn: e, algard: e, "xn--lgrd-poac": e, ålgård: e, arna: e, bronnoysund: e, "xn--brnnysund-m8ac": e, brønnøysund: e, brumunddal: e, bryne: e, drobak: e, "xn--drbak-wua": e, drøbak: e, egersund: e, fetsund: e, floro: e, "xn--flor-jra": e, florø: e, fredrikstad: e, hokksund: e, honefoss: e, "xn--hnefoss-q1a": e, hønefoss: e, jessheim: e, jorpeland: e, "xn--jrpeland-54a": e, jørpeland: e, kirkenes: e, kopervik: e, krokstadelva: e, langevag: e, "xn--langevg-jxa": e, langevåg: e, leirvik: e, mjondalen: e, "xn--mjndalen-64a": e, mjøndalen: e, "mo-i-rana": e, mosjoen: e, "xn--mosjen-eya": e, mosjøen: e, nesoddtangen: e, orkanger: e, osoyro: e, "xn--osyro-wua": e, osøyro: e, raholt: e, "xn--rholt-mra": e, råholt: e, sandnessjoen: e, "xn--sandnessjen-ogb": e, sandnessjøen: e, skedsmokorset: e, slattum: e, spjelkavik: e, stathelle: e, stavern: e, stjordalshalsen: e, "xn--stjrdalshalsen-sqb": e, stjørdalshalsen: e, tananger: e, tranby: e, vossevangen: e, aarborte: e, aejrie: e, afjord: e, "xn--fjord-lra": e, åfjord: e, agdenes: e, akershus: ba, aknoluokta: e, "xn--koluokta-7ya57h": e, ákŋoluokta: e, al: e, "xn--l-1fa": e, ål: e, alaheadju: e, "xn--laheadju-7ya": e, álaheadju: e, alesund: e, "xn--lesund-hua": e, ålesund: e, alstahaug: e, alta: e, "xn--lt-liac": e, áltá: e, alvdal: e, amli: e, "xn--mli-tla": e, åmli: e, amot: e, "xn--mot-tla": e, åmot: e, andasuolo: e, andebu: e, andoy: e, "xn--andy-ira": e, andøy: e, ardal: e, "xn--rdal-poa": e, årdal: e, aremark: e, arendal: e, "xn--s-1fa": e, ås: e, aseral: e, "xn--seral-lra": e, åseral: e, asker: e, askim: e, askoy: e, "xn--asky-ira": e, askøy: e, askvoll: e, asnes: e, "xn--snes-poa": e, åsnes: e, audnedaln: e, aukra: e, aure: e, aurland: e, "aurskog-holand": e, "xn--aurskog-hland-jnb": e, "aurskog-høland": e, austevoll: e, austrheim: e, averoy: e, "xn--avery-yua": e, averøy: e, badaddja: e, "xn--bdddj-mrabd": e, bådåddjå: e, "xn--brum-voa": e, bærum: e, bahcavuotna: e, "xn--bhcavuotna-s4a": e, báhcavuotna: e, bahccavuotna: e, "xn--bhccavuotna-k7a": e, báhccavuotna: e, baidar: e, "xn--bidr-5nac": e, báidár: e, bajddar: e, "xn--bjddar-pta": e, bájddar: e, balat: e, "xn--blt-elab": e, bálát: e, balestrand: e, ballangen: e, balsfjord: e, bamble: e, bardu: e, barum: e, batsfjord: e, "xn--btsfjord-9za": e, båtsfjord: e, bearalvahki: e, "xn--bearalvhki-y4a": e, bearalváhki: e, beardu: e, beiarn: e, berg: e, bergen: e, berlevag: e, "xn--berlevg-jxa": e, berlevåg: e, bievat: e, "xn--bievt-0qa": e, bievát: e, bindal: e, birkenes: e, bjarkoy: e, "xn--bjarky-fya": e, bjarkøy: e, bjerkreim: e, bjugn: e, bodo: e, "xn--bod-2na": e, bodø: e, bokn: e, bomlo: e, "xn--bmlo-gra": e, bømlo: e, bremanger: e, bronnoy: e, "xn--brnny-wuac": e, brønnøy: e, budejju: e, buskerud: ba, bygland: e, bykle: e, cahcesuolo: e, "xn--hcesuolo-7ya35b": e, čáhcesuolo: e, davvenjarga: e, "xn--davvenjrga-y4a": e, davvenjárga: e, davvesiida: e, deatnu: e, dielddanuorri: e, divtasvuodna: e, divttasvuotna: e, donna: e, "xn--dnna-gra": e, dønna: e, dovre: e, drammen: e, drangedal: e, dyroy: e, "xn--dyry-ira": e, dyrøy: e, eid: e, eidfjord: e, eidsberg: e, eidskog: e, eidsvoll: e, eigersund: e, elverum: e, enebakk: e, engerdal: e, etne: e, etnedal: e, evenassi: e, "xn--eveni-0qa01ga": e, evenášši: e, evenes: e, "evje-og-hornnes": e, farsund: e, fauske: e, fedje: e, fet: e, finnoy: e, "xn--finny-yua": e, finnøy: e, fitjar: e, fjaler: e, fjell: e, fla: e, "xn--fl-zia": e, flå: e, flakstad: e, flatanger: e, flekkefjord: e, flesberg: e, flora: e, folldal: e, forde: e, "xn--frde-gra": e, førde: e, forsand: e, fosnes: e, "xn--frna-woa": e, fræna: e, frana: e, frei: e, frogn: e, froland: e, frosta: e, froya: e, "xn--frya-hra": e, frøya: e, fuoisku: e, fuossko: e, fusa: e, fyresdal: e, gaivuotna: e, "xn--givuotna-8ya": e, gáivuotna: e, galsa: e, "xn--gls-elac": e, gálsá: e, gamvik: e, gangaviika: e, "xn--ggaviika-8ya47h": e, gáŋgaviika: e, gaular: e, gausdal: e, giehtavuoatna: e, gildeskal: e, "xn--gildeskl-g0a": e, gildeskål: e, giske: e, gjemnes: e, gjerdrum: e, gjerstad: e, gjesdal: e, gjovik: e, "xn--gjvik-wua": e, gjøvik: e, gloppen: e, gol: e, gran: e, grane: e, granvin: e, gratangen: e, grimstad: e, grong: e, grue: e, gulen: e, guovdageaidnu: e, ha: e, "xn--h-2fa": e, hå: e, habmer: e, "xn--hbmer-xqa": e, hábmer: e, hadsel: e, "xn--hgebostad-g3a": e, hægebostad: e, hagebostad: e, halden: e, halsa: e, hamar: e, hamaroy: e, hammarfeasta: e, "xn--hmmrfeasta-s4ac": e, hámmárfeasta: e, hammerfest: e, hapmir: e, "xn--hpmir-xqa": e, hápmir: e, haram: e, hareid: e, harstad: e, hasvik: e, hattfjelldal: e, haugesund: e, hedmark: [0, { os: e, valer: e, "xn--vler-qoa": e, våler: e }], hemne: e, hemnes: e, hemsedal: e, hitra: e, hjartdal: e, hjelmeland: e, hobol: e, "xn--hobl-ira": e, hobøl: e, hof: e, hol: e, hole: e, holmestrand: e, holtalen: e, "xn--holtlen-hxa": e, holtålen: e, hordaland: [0, { os: e }], hornindal: e, horten: e, hoyanger: e, "xn--hyanger-q1a": e, høyanger: e, hoylandet: e, "xn--hylandet-54a": e, høylandet: e, hurdal: e, hurum: e, hvaler: e, hyllestad: e, ibestad: e, inderoy: e, "xn--indery-fya": e, inderøy: e, iveland: e, ivgu: e, jevnaker: e, jolster: e, "xn--jlster-bya": e, jølster: e, jondal: e, kafjord: e, "xn--kfjord-iua": e, kåfjord: e, karasjohka: e, "xn--krjohka-hwab49j": e, kárášjohka: e, karasjok: e, karlsoy: e, karmoy: e, "xn--karmy-yua": e, karmøy: e, kautokeino: e, klabu: e, "xn--klbu-woa": e, klæbu: e, klepp: e, kongsberg: e, kongsvinger: e, kraanghke: e, "xn--kranghke-b0a": e, kråanghke: e, kragero: e, "xn--krager-gya": e, kragerø: e, kristiansand: e, kristiansund: e, krodsherad: e, "xn--krdsherad-m8a": e, krødsherad: e, "xn--kvfjord-nxa": e, kvæfjord: e, "xn--kvnangen-k0a": e, kvænangen: e, kvafjord: e, kvalsund: e, kvam: e, kvanangen: e, kvinesdal: e, kvinnherad: e, kviteseid: e, kvitsoy: e, "xn--kvitsy-fya": e, kvitsøy: e, laakesvuemie: e, "xn--lrdal-sra": e, lærdal: e, lahppi: e, "xn--lhppi-xqa": e, láhppi: e, lardal: e, larvik: e, lavagis: e, lavangen: e, leangaviika: e, "xn--leagaviika-52b": e, leaŋgaviika: e, lebesby: e, leikanger: e, leirfjord: e, leka: e, leksvik: e, lenvik: e, lerdal: e, lesja: e, levanger: e, lier: e, lierne: e, lillehammer: e, lillesand: e, lindas: e, "xn--linds-pra": e, lindås: e, lindesnes: e, loabat: e, "xn--loabt-0qa": e, loabát: e, lodingen: e, "xn--ldingen-q1a": e, lødingen: e, lom: e, loppa: e, lorenskog: e, "xn--lrenskog-54a": e, lørenskog: e, loten: e, "xn--lten-gra": e, løten: e, lund: e, lunner: e, luroy: e, "xn--lury-ira": e, lurøy: e, luster: e, lyngdal: e, lyngen: e, malatvuopmi: e, "xn--mlatvuopmi-s4a": e, málatvuopmi: e, malselv: e, "xn--mlselv-iua": e, målselv: e, malvik: e, mandal: e, marker: e, marnardal: e, masfjorden: e, masoy: e, "xn--msy-ula0h": e, måsøy: e, "matta-varjjat": e, "xn--mtta-vrjjat-k7af": e, "mátta-várjjat": e, meland: e, meldal: e, melhus: e, meloy: e, "xn--mely-ira": e, meløy: e, meraker: e, "xn--merker-kua": e, meråker: e, midsund: e, "midtre-gauldal": e, moareke: e, "xn--moreke-jua": e, moåreke: e, modalen: e, modum: e, molde: e, "more-og-romsdal": [0, { heroy: e, sande: e }], "xn--mre-og-romsdal-qqb": [0, { "xn--hery-ira": e, sande: e }], "møre-og-romsdal": [0, { herøy: e, sande: e }], moskenes: e, moss: e, mosvik: e, muosat: e, "xn--muost-0qa": e, muosát: e, naamesjevuemie: e, "xn--nmesjevuemie-tcba": e, nååmesjevuemie: e, "xn--nry-yla5g": e, nærøy: e, namdalseid: e, namsos: e, namsskogan: e, nannestad: e, naroy: e, narviika: e, narvik: e, naustdal: e, navuotna: e, "xn--nvuotna-hwa": e, návuotna: e, "nedre-eiker": e, nesna: e, nesodden: e, nesseby: e, nesset: e, nissedal: e, nittedal: e, "nord-aurdal": e, "nord-fron": e, "nord-odal": e, norddal: e, nordkapp: e, nordland: [0, { bo: e, "xn--b-5ga": e, bø: e, heroy: e, "xn--hery-ira": e, herøy: e }], "nordre-land": e, nordreisa: e, "nore-og-uvdal": e, notodden: e, notteroy: e, "xn--nttery-byae": e, nøtterøy: e, odda: e, oksnes: e, "xn--ksnes-uua": e, øksnes: e, omasvuotna: e, oppdal: e, oppegard: e, "xn--oppegrd-ixa": e, oppegård: e, orkdal: e, orland: e, "xn--rland-uua": e, ørland: e, orskog: e, "xn--rskog-uua": e, ørskog: e, orsta: e, "xn--rsta-fra": e, ørsta: e, osen: e, osteroy: e, "xn--ostery-fya": e, osterøy: e, ostfold: [0, { valer: e }], "xn--stfold-9xa": [0, { "xn--vler-qoa": e }], østfold: [0, { våler: e }], "ostre-toten": e, "xn--stre-toten-zcb": e, "østre-toten": e, overhalla: e, "ovre-eiker": e, "xn--vre-eiker-k8a": e, "øvre-eiker": e, oyer: e, "xn--yer-zna": e, øyer: e, oygarden: e, "xn--ygarden-p1a": e, øygarden: e, "oystre-slidre": e, "xn--ystre-slidre-ujb": e, "øystre-slidre": e, porsanger: e, porsangu: e, "xn--porsgu-sta26f": e, porsáŋgu: e, porsgrunn: e, rade: e, "xn--rde-ula": e, råde: e, radoy: e, "xn--rady-ira": e, radøy: e, "xn--rlingen-mxa": e, rælingen: e, rahkkeravju: e, "xn--rhkkervju-01af": e, ráhkkerávju: e, raisa: e, "xn--risa-5na": e, ráisa: e, rakkestad: e, ralingen: e, rana: e, randaberg: e, rauma: e, rendalen: e, rennebu: e, rennesoy: e, "xn--rennesy-v1a": e, rennesøy: e, rindal: e, ringebu: e, ringerike: e, ringsaker: e, risor: e, "xn--risr-ira": e, risør: e, rissa: e, roan: e, rodoy: e, "xn--rdy-0nab": e, rødøy: e, rollag: e, romsa: e, romskog: e, "xn--rmskog-bya": e, rømskog: e, roros: e, "xn--rros-gra": e, røros: e, rost: e, "xn--rst-0na": e, røst: e, royken: e, "xn--ryken-vua": e, røyken: e, royrvik: e, "xn--ryrvik-bya": e, røyrvik: e, ruovat: e, rygge: e, salangen: e, salat: e, "xn--slat-5na": e, sálat: e, "xn--slt-elab": e, sálát: e, saltdal: e, samnanger: e, sandefjord: e, sandnes: e, sandoy: e, "xn--sandy-yua": e, sandøy: e, sarpsborg: e, sauda: e, sauherad: e, sel: e, selbu: e, selje: e, seljord: e, siellak: e, sigdal: e, siljan: e, sirdal: e, skanit: e, "xn--sknit-yqa": e, skánit: e, skanland: e, "xn--sknland-fxa": e, skånland: e, skaun: e, skedsmo: e, ski: e, skien: e, skierva: e, "xn--skierv-uta": e, skiervá: e, skiptvet: e, skjak: e, "xn--skjk-soa": e, skjåk: e, skjervoy: e, "xn--skjervy-v1a": e, skjervøy: e, skodje: e, smola: e, "xn--smla-hra": e, smøla: e, snaase: e, "xn--snase-nra": e, snåase: e, snasa: e, "xn--snsa-roa": e, snåsa: e, snillfjord: e, snoasa: e, sogndal: e, sogne: e, "xn--sgne-gra": e, søgne: e, sokndal: e, sola: e, solund: e, somna: e, "xn--smna-gra": e, sømna: e, "sondre-land": e, "xn--sndre-land-0cb": e, "søndre-land": e, songdalen: e, "sor-aurdal": e, "xn--sr-aurdal-l8a": e, "sør-aurdal": e, "sor-fron": e, "xn--sr-fron-q1a": e, "sør-fron": e, "sor-odal": e, "xn--sr-odal-q1a": e, "sør-odal": e, "sor-varanger": e, "xn--sr-varanger-ggb": e, "sør-varanger": e, sorfold: e, "xn--srfold-bya": e, sørfold: e, sorreisa: e, "xn--srreisa-q1a": e, sørreisa: e, sortland: e, sorum: e, "xn--srum-gra": e, sørum: e, spydeberg: e, stange: e, stavanger: e, steigen: e, steinkjer: e, stjordal: e, "xn--stjrdal-s1a": e, stjørdal: e, stokke: e, "stor-elvdal": e, stord: e, stordal: e, storfjord: e, strand: e, stranda: e, stryn: e, sula: e, suldal: e, sund: e, sunndal: e, surnadal: e, sveio: e, svelvik: e, sykkylven: e, tana: e, telemark: [0, { bo: e, "xn--b-5ga": e, bø: e }], time: e, tingvoll: e, tinn: e, tjeldsund: e, tjome: e, "xn--tjme-hra": e, tjøme: e, tokke: e, tolga: e, tonsberg: e, "xn--tnsberg-q1a": e, tønsberg: e, torsken: e, "xn--trna-woa": e, træna: e, trana: e, tranoy: e, "xn--trany-yua": e, tranøy: e, troandin: e, trogstad: e, "xn--trgstad-r1a": e, trøgstad: e, tromsa: e, tromso: e, "xn--troms-zua": e, tromsø: e, trondheim: e, trysil: e, tvedestrand: e, tydal: e, tynset: e, tysfjord: e, tysnes: e, "xn--tysvr-vra": e, tysvær: e, tysvar: e, ullensaker: e, ullensvang: e, ulvik: e, unjarga: e, "xn--unjrga-rta": e, unjárga: e, utsira: e, vaapste: e, vadso: e, "xn--vads-jra": e, vadsø: e, "xn--vry-yla5g": e, værøy: e, vaga: e, "xn--vg-yiab": e, vågå: e, vagan: e, "xn--vgan-qoa": e, vågan: e, vagsoy: e, "xn--vgsy-qoa0j": e, vågsøy: e, vaksdal: e, valle: e, vang: e, vanylven: e, vardo: e, "xn--vard-jra": e, vardø: e, varggat: e, "xn--vrggt-xqad": e, várggát: e, varoy: e, vefsn: e, vega: e, vegarshei: e, "xn--vegrshei-c0a": e, vegårshei: e, vennesla: e, verdal: e, verran: e, vestby: e, vestfold: [0, { sande: e }], vestnes: e, "vestre-slidre": e, "vestre-toten": e, vestvagoy: e, "xn--vestvgy-ixa6o": e, vestvågøy: e, vevelstad: e, vik: e, vikna: e, vindafjord: e, voagat: e, volda: e, voss: e, co: t, "123hjemmeside": t, myspreadshop: t }], np: m, nr: ya, nu: [1, { merseine: t, mine: t, shacknet: t, enterprisecloud: t }], nz: [1, { ac: e, co: e, cri: e, geek: e, gen: e, govt: e, health: e, iwi: e, kiwi: e, maori: e, "xn--mori-qsa": e, māori: e, mil: e, net: e, org: e, parliament: e, school: e, cloudns: t }], om: [1, { co: e, com: e, edu: e, gov: e, med: e, museum: e, net: e, org: e, pro: e }], onion: e, org: [1, { altervista: t, pimienta: t, poivron: t, potager: t, sweetpepper: t, cdn77: [0, { c: t, rsc: t }], "cdn77-secure": [0, { origin: [0, { ssl: t }] }], ae: t, cloudns: t, "ip-dynamic": t, ddnss: t, dpdns: t, duckdns: t, tunk: t, blogdns: t, blogsite: t, boldlygoingnowhere: t, dnsalias: t, dnsdojo: t, doesntexist: t, dontexist: t, doomdns: t, dvrdns: t, dynalias: t, dyndns: [2, { go: t, home: t }], endofinternet: t, endoftheinternet: t, "from-me": t, "game-host": t, gotdns: t, "hobby-site": t, homedns: t, homeftp: t, homelinux: t, homeunix: t, "is-a-bruinsfan": t, "is-a-candidate": t, "is-a-celticsfan": t, "is-a-chef": t, "is-a-geek": t, "is-a-knight": t, "is-a-linux-user": t, "is-a-patsfan": t, "is-a-soxfan": t, "is-found": t, "is-lost": t, "is-saved": t, "is-very-bad": t, "is-very-evil": t, "is-very-good": t, "is-very-nice": t, "is-very-sweet": t, "isa-geek": t, "kicks-ass": t, misconfused: t, podzone: t, readmyblog: t, selfip: t, sellsyourhome: t, servebbs: t, serveftp: t, servegame: t, "stuff-4-sale": t, webhop: t, accesscam: t, camdvr: t, freeddns: t, mywire: t, webredirect: t, twmail: t, eu: [2, { al: t, asso: t, at: t, au: t, be: t, bg: t, ca: t, cd: t, ch: t, cn: t, cy: t, cz: t, de: t, dk: t, edu: t, ee: t, es: t, fi: t, fr: t, gr: t, hr: t, hu: t, ie: t, il: t, in: t, int: t, is: t, it: t, jp: t, kr: t, lt: t, lu: t, lv: t, me: t, mk: t, mt: t, my: t, net: t, ng: t, nl: t, no: t, nz: t, pl: t, pt: t, ro: t, ru: t, se: t, si: t, sk: t, tr: t, uk: t, us: t }], fedorainfracloud: t, fedorapeople: t, fedoraproject: [0, { cloud: t, os: ge, stg: [0, { os: ge }] }], freedesktop: t, hatenadiary: t, hepforge: t, "in-dsl": t, "in-vpn": t, js: t, barsy: t, mayfirst: t, routingthecloud: t, bmoattachments: t, "cable-modem": t, collegefan: t, couchpotatofries: t, hopto: t, mlbfan: t, myftp: t, mysecuritycamera: t, nflfan: t, "no-ip": t, "read-books": t, ufcfan: t, zapto: t, dynserv: t, "now-dns": t, "is-local": t, httpbin: t, pubtls: t, jpn: t, "my-firewall": t, myfirewall: t, spdns: t, "small-web": t, dsmynas: t, familyds: t, teckids: Xo, tuxfamily: t, diskstation: t, hk: t, us: t, toolforge: t, wmcloud: t, wmflabs: t, za: t }], pa: [1, { abo: e, ac: e, com: e, edu: e, gob: e, ing: e, med: e, net: e, nom: e, org: e, sld: e }], pe: [1, { com: e, edu: e, gob: e, mil: e, net: e, nom: e, org: e }], pf: [1, { com: e, edu: e, org: e }], pg: m, ph: [1, { com: e, edu: e, gov: e, i: e, mil: e, net: e, ngo: e, org: e, cloudns: t }], pk: [1, { ac: e, biz: e, com: e, edu: e, fam: e, gkp: e, gob: e, gog: e, gok: e, gop: e, gos: e, gov: e, net: e, org: e, web: e }], pl: [1, { com: e, net: e, org: e, agro: e, aid: e, atm: e, auto: e, biz: e, edu: e, gmina: e, gsm: e, info: e, mail: e, media: e, miasta: e, mil: e, nieruchomosci: e, nom: e, pc: e, powiat: e, priv: e, realestate: e, rel: e, sex: e, shop: e, sklep: e, sos: e, szkola: e, targi: e, tm: e, tourism: e, travel: e, turystyka: e, gov: [1, { ap: e, griw: e, ic: e, is: e, kmpsp: e, konsulat: e, kppsp: e, kwp: e, kwpsp: e, mup: e, mw: e, oia: e, oirm: e, oke: e, oow: e, oschr: e, oum: e, pa: e, pinb: e, piw: e, po: e, pr: e, psp: e, psse: e, pup: e, rzgw: e, sa: e, sdn: e, sko: e, so: e, sr: e, starostwo: e, ug: e, ugim: e, um: e, umig: e, upow: e, uppo: e, us: e, uw: e, uzs: e, wif: e, wiih: e, winb: e, wios: e, witd: e, wiw: e, wkz: e, wsa: e, wskr: e, wsse: e, wuoz: e, wzmiuw: e, zp: e, zpisdn: e }], augustow: e, "babia-gora": e, bedzin: e, beskidy: e, bialowieza: e, bialystok: e, bielawa: e, bieszczady: e, boleslawiec: e, bydgoszcz: e, bytom: e, cieszyn: e, czeladz: e, czest: e, dlugoleka: e, elblag: e, elk: e, glogow: e, gniezno: e, gorlice: e, grajewo: e, ilawa: e, jaworzno: e, "jelenia-gora": e, jgora: e, kalisz: e, karpacz: e, kartuzy: e, kaszuby: e, katowice: e, "kazimierz-dolny": e, kepno: e, ketrzyn: e, klodzko: e, kobierzyce: e, kolobrzeg: e, konin: e, konskowola: e, kutno: e, lapy: e, lebork: e, legnica: e, lezajsk: e, limanowa: e, lomza: e, lowicz: e, lubin: e, lukow: e, malbork: e, malopolska: e, mazowsze: e, mazury: e, mielec: e, mielno: e, mragowo: e, naklo: e, nowaruda: e, nysa: e, olawa: e, olecko: e, olkusz: e, olsztyn: e, opoczno: e, opole: e, ostroda: e, ostroleka: e, ostrowiec: e, ostrowwlkp: e, pila: e, pisz: e, podhale: e, podlasie: e, polkowice: e, pomorskie: e, pomorze: e, prochowice: e, pruszkow: e, przeworsk: e, pulawy: e, radom: e, "rawa-maz": e, rybnik: e, rzeszow: e, sanok: e, sejny: e, skoczow: e, slask: e, slupsk: e, sosnowiec: e, "stalowa-wola": e, starachowice: e, stargard: e, suwalki: e, swidnica: e, swiebodzin: e, swinoujscie: e, szczecin: e, szczytno: e, tarnobrzeg: e, tgory: e, turek: e, tychy: e, ustka: e, walbrzych: e, warmia: e, warszawa: e, waw: e, wegrow: e, wielun: e, wlocl: e, wloclawek: e, wodzislaw: e, wolomin: e, wroclaw: e, zachpomor: e, zagan: e, zarow: e, zgora: e, zgorzelec: e, art: t, gliwice: t, krakow: t, poznan: t, wroc: t, zakopane: t, beep: t, "ecommerce-shop": t, cfolks: t, dfirma: t, dkonto: t, you2: t, shoparena: t, homesklep: t, sdscloud: t, unicloud: t, lodz: t, pabianice: t, plock: t, sieradz: t, skierniewice: t, zgierz: t, krasnik: t, leczna: t, lubartow: t, lublin: t, poniatowa: t, swidnik: t, co: t, torun: t, simplesite: t, myspreadshop: t, gda: t, gdansk: t, gdynia: t, med: t, sopot: t, bielsko: t }], pm: [1, { own: t, name: t }], pn: [1, { co: e, edu: e, gov: e, net: e, org: e }], post: e, pr: [1, { biz: e, com: e, edu: e, gov: e, info: e, isla: e, name: e, net: e, org: e, pro: e, ac: e, est: e, prof: e }], pro: [1, { aaa: e, aca: e, acct: e, avocat: e, bar: e, cpa: e, eng: e, jur: e, law: e, med: e, recht: e, "12chars": t, cloudns: t, barsy: t, ngrok: t }], ps: [1, { com: e, edu: e, gov: e, net: e, org: e, plo: e, sec: e }], pt: [1, { com: e, edu: e, gov: e, int: e, net: e, nome: e, org: e, publ: e, "123paginaweb": t }], pw: [1, { gov: e, cloudns: t, x443: t }], py: [1, { com: e, coop: e, edu: e, gov: e, mil: e, net: e, org: e }], qa: [1, { com: e, edu: e, gov: e, mil: e, name: e, net: e, org: e, sch: e }], re: [1, { asso: e, com: e, netlib: t, can: t }], ro: [1, { arts: e, com: e, firm: e, info: e, nom: e, nt: e, org: e, rec: e, store: e, tm: e, www: e, co: t, shop: t, barsy: t }], rs: [1, { ac: e, co: e, edu: e, gov: e, in: e, org: e, brendly: ga, barsy: t, ox: t }], ru: [1, { ac: t, edu: t, gov: t, int: t, mil: t, eurodir: t, adygeya: t, bashkiria: t, bir: t, cbg: t, com: t, dagestan: t, grozny: t, kalmykia: t, kustanai: t, marine: t, mordovia: t, msk: t, mytis: t, nalchik: t, nov: t, pyatigorsk: t, spb: t, vladikavkaz: t, vladimir: t, na4u: t, mircloud: t, myjino: [2, { hosting: o, landing: o, spectrum: o, vps: o }], cldmail: [0, { hb: t }], mcdir: [2, { vps: t }], mcpre: t, net: t, org: t, pp: t, lk3: t, ras: t }], rw: [1, { ac: e, co: e, coop: e, gov: e, mil: e, net: e, org: e }], sa: [1, { com: e, edu: e, gov: e, med: e, net: e, org: e, pub: e, sch: e }], sb: n, sc: n, sd: [1, { com: e, edu: e, gov: e, info: e, med: e, net: e, org: e, tv: e }], se: [1, { a: e, ac: e, b: e, bd: e, brand: e, c: e, d: e, e, f: e, fh: e, fhsk: e, fhv: e, g: e, h: e, i: e, k: e, komforb: e, kommunalforbund: e, komvux: e, l: e, lanbib: e, m: e, n: e, naturbruksgymn: e, o: e, org: e, p: e, parti: e, pp: e, press: e, r: e, s: e, t: e, tm: e, u: e, w: e, x: e, y: e, z: e, com: t, iopsys: t, "123minsida": t, itcouldbewor: t, myspreadshop: t }], sg: [1, { com: e, edu: e, gov: e, net: e, org: e, enscaled: t }], sh: [1, { com: e, gov: e, mil: e, net: e, org: e, hashbang: t, botda: t, platform: [0, { ent: t, eu: t, us: t }], now: t }], si: [1, { f5: t, gitapp: t, gitpage: t }], sj: e, sk: e, sl: n, sm: e, sn: [1, { art: e, com: e, edu: e, gouv: e, org: e, perso: e, univ: e }], so: [1, { com: e, edu: e, gov: e, me: e, net: e, org: e, surveys: t }], sr: e, ss: [1, { biz: e, co: e, com: e, edu: e, gov: e, me: e, net: e, org: e, sch: e }], st: [1, { co: e, com: e, consulado: e, edu: e, embaixada: e, mil: e, net: e, org: e, principe: e, saotome: e, store: e, helioho: t, kirara: t, noho: t }], su: [1, { abkhazia: t, adygeya: t, aktyubinsk: t, arkhangelsk: t, armenia: t, ashgabad: t, azerbaijan: t, balashov: t, bashkiria: t, bryansk: t, bukhara: t, chimkent: t, dagestan: t, "east-kazakhstan": t, exnet: t, georgia: t, grozny: t, ivanovo: t, jambyl: t, kalmykia: t, kaluga: t, karacol: t, karaganda: t, karelia: t, khakassia: t, krasnodar: t, kurgan: t, kustanai: t, lenug: t, mangyshlak: t, mordovia: t, msk: t, murmansk: t, nalchik: t, navoi: t, "north-kazakhstan": t, nov: t, obninsk: t, penza: t, pokrovsk: t, sochi: t, spb: t, tashkent: t, termez: t, togliatti: t, troitsk: t, tselinograd: t, tula: t, tuva: t, vladikavkaz: t, vladimir: t, vologda: t }], sv: [1, { com: e, edu: e, gob: e, org: e, red: e }], sx: l, sy: r, sz: [1, { ac: e, co: e, org: e }], tc: e, td: e, tel: e, tf: [1, { sch: t }], tg: e, th: [1, { ac: e, co: e, go: e, in: e, mi: e, net: e, or: e, online: t, shop: t }], tj: [1, { ac: e, biz: e, co: e, com: e, edu: e, go: e, gov: e, int: e, mil: e, name: e, net: e, nic: e, org: e, test: e, web: e }], tk: e, tl: l, tm: [1, { co: e, com: e, edu: e, gov: e, mil: e, net: e, nom: e, org: e }], tn: [1, { com: e, ens: e, fin: e, gov: e, ind: e, info: e, intl: e, mincom: e, nat: e, net: e, org: e, perso: e, tourism: e, orangecloud: t }], to: [1, { 611: t, com: e, edu: e, gov: e, mil: e, net: e, org: e, oya: t, x0: t, quickconnect: _, vpnplus: t }], tr: [1, { av: e, bbs: e, bel: e, biz: e, com: e, dr: e, edu: e, gen: e, gov: e, info: e, k12: e, kep: e, mil: e, name: e, net: e, org: e, pol: e, tel: e, tsk: e, tv: e, web: e, nc: l }], tt: [1, { biz: e, co: e, com: e, edu: e, gov: e, info: e, mil: e, name: e, net: e, org: e, pro: e }], tv: [1, { "better-than": t, dyndns: t, "on-the-web": t, "worse-than": t, from: t, sakura: t }], tw: [1, { club: e, com: [1, { mymailer: t }], ebiz: e, edu: e, game: e, gov: e, idv: e, mil: e, net: e, org: e, url: t, mydns: t }], tz: [1, { ac: e, co: e, go: e, hotel: e, info: e, me: e, mil: e, mobi: e, ne: e, or: e, sc: e, tv: e }], ua: [1, { com: e, edu: e, gov: e, in: e, net: e, org: e, cherkassy: e, cherkasy: e, chernigov: e, chernihiv: e, chernivtsi: e, chernovtsy: e, ck: e, cn: e, cr: e, crimea: e, cv: e, dn: e, dnepropetrovsk: e, dnipropetrovsk: e, donetsk: e, dp: e, if: e, "ivano-frankivsk": e, kh: e, kharkiv: e, kharkov: e, kherson: e, khmelnitskiy: e, khmelnytskyi: e, kiev: e, kirovograd: e, km: e, kr: e, kropyvnytskyi: e, krym: e, ks: e, kv: e, kyiv: e, lg: e, lt: e, lugansk: e, luhansk: e, lutsk: e, lv: e, lviv: e, mk: e, mykolaiv: e, nikolaev: e, od: e, odesa: e, odessa: e, pl: e, poltava: e, rivne: e, rovno: e, rv: e, sb: e, sebastopol: e, sevastopol: e, sm: e, sumy: e, te: e, ternopil: e, uz: e, uzhgorod: e, uzhhorod: e, vinnica: e, vinnytsia: e, vn: e, volyn: e, yalta: e, zakarpattia: e, zaporizhzhe: e, zaporizhzhia: e, zhitomir: e, zhytomyr: e, zp: e, zt: e, cc: t, inf: t, ltd: t, cx: t, ie: t, biz: t, co: t, pp: t, v: t }], ug: [1, { ac: e, co: e, com: e, edu: e, go: e, gov: e, mil: e, ne: e, or: e, org: e, sc: e, us: e }], uk: [1, { ac: e, co: [1, { bytemark: [0, { dh: t, vm: t }], layershift: G, barsy: t, barsyonline: t, retrosnub: ma, "nh-serv": t, "no-ip": t, adimo: t, myspreadshop: t }], gov: [1, { api: t, campaign: t, service: t }], ltd: e, me: e, net: e, nhs: e, org: [1, { glug: t, lug: t, lugs: t, affinitylottery: t, raffleentry: t, weeklylottery: t }], plc: e, police: e, sch: m, conn: t, copro: t, hosp: t, "independent-commission": t, "independent-inquest": t, "independent-inquiry": t, "independent-panel": t, "independent-review": t, "public-inquiry": t, "royal-commission": t, pymnt: t, barsy: t, nimsite: t, oraclegovcloudapps: o }], us: [1, { dni: e, isa: e, nsn: e, ak: W, al: W, ar: W, as: W, az: W, ca: W, co: W, ct: W, dc: W, de: [1, { cc: e, lib: t }], fl: W, ga: W, gu: W, hi: xr, ia: W, id: W, il: W, in: W, ks: W, ky: W, la: W, ma: [1, { k12: [1, { chtr: e, paroch: e, pvt: e }], cc: e, lib: e }], md: W, me: W, mi: [1, { k12: e, cc: e, lib: e, "ann-arbor": e, cog: e, dst: e, eaton: e, gen: e, mus: e, tec: e, washtenaw: e }], mn: W, mo: W, ms: W, mt: W, nc: W, nd: xr, ne: W, nh: W, nj: W, nm: W, nv: W, ny: W, oh: W, ok: W, or: W, pa: W, pr: W, ri: xr, sc: W, sd: xr, tn: W, tx: W, ut: W, va: W, vi: W, vt: W, wa: W, wi: W, wv: [1, { cc: e }], wy: W, cloudns: t, "is-by": t, "land-4-sale": t, "stuff-4-sale": t, heliohost: t, enscaled: [0, { phx: t }], mircloud: t, ngo: t, golffan: t, noip: t, pointto: t, freeddns: t, srv: [2, { gh: t, gl: t }], platterp: t, servername: t }], uy: [1, { com: e, edu: e, gub: e, mil: e, net: e, org: e }], uz: [1, { co: e, com: e, net: e, org: e }], va: e, vc: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, gv: [2, { d: t }], "0e": o, mydns: t }], ve: [1, { arts: e, bib: e, co: e, com: e, e12: e, edu: e, emprende: e, firm: e, gob: e, gov: e, info: e, int: e, mil: e, net: e, nom: e, org: e, rar: e, rec: e, store: e, tec: e, web: e }], vg: [1, { edu: e }], vi: [1, { co: e, com: e, k12: e, net: e, org: e }], vn: [1, { ac: e, ai: e, biz: e, com: e, edu: e, gov: e, health: e, id: e, info: e, int: e, io: e, name: e, net: e, org: e, pro: e, angiang: e, bacgiang: e, backan: e, baclieu: e, bacninh: e, "baria-vungtau": e, bentre: e, binhdinh: e, binhduong: e, binhphuoc: e, binhthuan: e, camau: e, cantho: e, caobang: e, daklak: e, daknong: e, danang: e, dienbien: e, dongnai: e, dongthap: e, gialai: e, hagiang: e, haiduong: e, haiphong: e, hanam: e, hanoi: e, hatinh: e, haugiang: e, hoabinh: e, hungyen: e, khanhhoa: e, kiengiang: e, kontum: e, laichau: e, lamdong: e, langson: e, laocai: e, longan: e, namdinh: e, nghean: e, ninhbinh: e, ninhthuan: e, phutho: e, phuyen: e, quangbinh: e, quangnam: e, quangngai: e, quangninh: e, quangtri: e, soctrang: e, sonla: e, tayninh: e, thaibinh: e, thainguyen: e, thanhhoa: e, thanhphohochiminh: e, thuathienhue: e, tiengiang: e, travinh: e, tuyenquang: e, vinhlong: e, vinhphuc: e, yenbai: e }], vu: Y, wf: [1, { biz: t, sch: t }], ws: [1, { com: e, edu: e, gov: e, net: e, org: e, advisor: o, cloud66: t, dyndns: t, mypets: t }], yt: [1, { org: t }], "xn--mgbaam7a8h": e, امارات: e, "xn--y9a3aq": e, հայ: e, "xn--54b7fta0cc": e, বাংলা: e, "xn--90ae": e, бг: e, "xn--mgbcpq6gpa1a": e, البحرين: e, "xn--90ais": e, бел: e, "xn--fiqs8s": e, 中国: e, "xn--fiqz9s": e, 中國: e, "xn--lgbbat1ad8j": e, الجزائر: e, "xn--wgbh1c": e, مصر: e, "xn--e1a4c": e, ею: e, "xn--qxa6a": e, ευ: e, "xn--mgbah1a3hjkrd": e, موريتانيا: e, "xn--node": e, გე: e, "xn--qxam": e, ελ: e, "xn--j6w193g": [1, { "xn--gmqw5a": e, "xn--55qx5d": e, "xn--mxtq1m": e, "xn--wcvs22d": e, "xn--uc0atv": e, "xn--od0alg": e }], 香港: [1, { 個人: e, 公司: e, 政府: e, 教育: e, 組織: e, 網絡: e }], "xn--2scrj9c": e, ಭಾರತ: e, "xn--3hcrj9c": e, ଭାରତ: e, "xn--45br5cyl": e, ভাৰত: e, "xn--h2breg3eve": e, भारतम्: e, "xn--h2brj9c8c": e, भारोत: e, "xn--mgbgu82a": e, ڀارت: e, "xn--rvc1e0am3e": e, ഭാരതം: e, "xn--h2brj9c": e, भारत: e, "xn--mgbbh1a": e, بارت: e, "xn--mgbbh1a71e": e, بھارت: e, "xn--fpcrj9c3d": e, భారత్: e, "xn--gecrj9c": e, ભારત: e, "xn--s9brj9c": e, ਭਾਰਤ: e, "xn--45brj9c": e, ভারত: e, "xn--xkc2dl3a5ee0h": e, இந்தியா: e, "xn--mgba3a4f16a": e, ایران: e, "xn--mgba3a4fra": e, ايران: e, "xn--mgbtx2b": e, عراق: e, "xn--mgbayh7gpa": e, الاردن: e, "xn--3e0b707e": e, 한국: e, "xn--80ao21a": e, қаз: e, "xn--q7ce6a": e, ລາວ: e, "xn--fzc2c9e2c": e, ලංකා: e, "xn--xkc2al3hye2a": e, இலங்கை: e, "xn--mgbc0a9azcg": e, المغرب: e, "xn--d1alf": e, мкд: e, "xn--l1acc": e, мон: e, "xn--mix891f": e, 澳門: e, "xn--mix082f": e, 澳门: e, "xn--mgbx4cd0ab": e, مليسيا: e, "xn--mgb9awbf": e, عمان: e, "xn--mgbai9azgqp6j": e, پاکستان: e, "xn--mgbai9a5eva00b": e, پاكستان: e, "xn--ygbi2ammx": e, فلسطين: e, "xn--90a3ac": [1, { "xn--80au": e, "xn--90azh": e, "xn--d1at": e, "xn--c1avg": e, "xn--o1ac": e, "xn--o1ach": e }], срб: [1, { ак: e, обр: e, од: e, орг: e, пр: e, упр: e }], "xn--p1ai": e, рф: e, "xn--wgbl6a": e, قطر: e, "xn--mgberp4a5d4ar": e, السعودية: e, "xn--mgberp4a5d4a87g": e, السعودیة: e, "xn--mgbqly7c0a67fbc": e, السعودیۃ: e, "xn--mgbqly7cvafr": e, السعوديه: e, "xn--mgbpl2fh": e, سودان: e, "xn--yfro4i67o": e, 新加坡: e, "xn--clchc0ea0b2g2a9gcd": e, சிங்கப்பூர்: e, "xn--ogbpf8fl": e, سورية: e, "xn--mgbtf8fl": e, سوريا: e, "xn--o3cw4h": [1, { "xn--o3cyx2a": e, "xn--12co0c3b4eva": e, "xn--m3ch0j3a": e, "xn--h3cuzk1di": e, "xn--12c1fe0br": e, "xn--12cfi8ixb8l": e }], ไทย: [1, { ทหาร: e, ธุรกิจ: e, เน็ต: e, รัฐบาล: e, ศึกษา: e, องค์กร: e }], "xn--pgbs0dh": e, تونس: e, "xn--kpry57d": e, 台灣: e, "xn--kprw13d": e, 台湾: e, "xn--nnx388a": e, 臺灣: e, "xn--j1amh": e, укр: e, "xn--mgb2ddes": e, اليمن: e, xxx: e, ye: r, za: [0, { ac: e, agric: e, alt: e, co: e, edu: e, gov: e, grondar: e, law: e, mil: e, net: e, ngo: e, nic: e, nis: e, nom: e, org: e, school: e, tm: e, web: e }], zm: [1, { ac: e, biz: e, co: e, com: e, edu: e, gov: e, info: e, mil: e, net: e, org: e, sch: e }], zw: [1, { ac: e, co: e, gov: e, mil: e, org: e }], aaa: e, aarp: e, abb: e, abbott: e, abbvie: e, abc: e, able: e, abogado: e, abudhabi: e, academy: [1, { official: t }], accenture: e, accountant: e, accountants: e, aco: e, actor: e, ads: e, adult: e, aeg: e, aetna: e, afl: e, africa: e, agakhan: e, agency: e, aig: e, airbus: e, airforce: e, airtel: e, akdn: e, alibaba: e, alipay: e, allfinanz: e, allstate: e, ally: e, alsace: e, alstom: e, amazon: e, americanexpress: e, americanfamily: e, amex: e, amfam: e, amica: e, amsterdam: e, analytics: e, android: e, anquan: e, anz: e, aol: e, apartments: e, app: [1, { adaptable: t, aiven: t, beget: o, brave: i, clerk: t, clerkstage: t, wnext: t, csb: [2, { preview: t }], convex: t, deta: t, ondigitalocean: t, easypanel: t, encr: t, evervault: s, expo: [2, { staging: t }], edgecompute: t, "on-fleek": t, flutterflow: t, e2b: t, framer: t, hosted: o, run: o, web: t, hasura: t, botdash: t, loginline: t, lovable: t, medusajs: t, messerli: t, netfy: t, netlify: t, ngrok: t, "ngrok-free": t, developer: o, noop: t, northflank: o, upsun: o, replit: a, nyat: t, snowflake: [0, { "*": t, privatelink: o }], streamlit: t, storipress: t, telebit: t, typedream: t, vercel: t, bookonline: t, wdh: t, windsurf: t, zeabur: t, zerops: o }], apple: e, aquarelle: e, arab: e, aramco: e, archi: e, army: e, art: e, arte: e, asda: e, associates: e, athleta: e, attorney: e, auction: e, audi: e, audible: e, audio: e, auspost: e, author: e, auto: e, autos: e, aws: [1, { sagemaker: [0, { "ap-northeast-1": h, "ap-northeast-2": h, "ap-south-1": h, "ap-southeast-1": h, "ap-southeast-2": h, "ca-central-1": p, "eu-central-1": h, "eu-west-1": h, "eu-west-2": h, "us-east-1": p, "us-east-2": p, "us-west-2": p, "af-south-1": d, "ap-east-1": d, "ap-northeast-3": d, "ap-south-2": f, "ap-southeast-3": d, "ap-southeast-4": f, "ca-west-1": [0, { notebook: t, "notebook-fips": t }], "eu-central-2": d, "eu-north-1": d, "eu-south-1": d, "eu-south-2": d, "eu-west-3": d, "il-central-1": d, "me-central-1": d, "me-south-1": d, "sa-east-1": d, "us-gov-east-1": g, "us-gov-west-1": g, "us-west-1": [0, { notebook: t, "notebook-fips": t, studio: t }], experiments: o }], repost: [0, { private: o }], on: [0, { "ap-northeast-1": u, "ap-southeast-1": u, "ap-southeast-2": u, "eu-central-1": u, "eu-north-1": u, "eu-west-1": u, "us-east-1": u, "us-east-2": u, "us-west-2": u }] }], axa: e, azure: e, baby: e, baidu: e, banamex: e, band: e, bank: e, bar: e, barcelona: e, barclaycard: e, barclays: e, barefoot: e, bargains: e, baseball: e, basketball: [1, { aus: t, nz: t }], bauhaus: e, bayern: e, bbc: e, bbt: e, bbva: e, bcg: e, bcn: e, beats: e, beauty: e, beer: e, bentley: e, berlin: e, best: e, bestbuy: e, bet: e, bharti: e, bible: e, bid: e, bike: e, bing: e, bingo: e, bio: e, black: e, blackfriday: e, blockbuster: e, blog: e, bloomberg: e, blue: e, bms: e, bmw: e, bnpparibas: e, boats: e, boehringer: e, bofa: e, bom: e, bond: e, boo: e, book: e, booking: e, bosch: e, bostik: e, boston: e, bot: e, boutique: e, box: e, bradesco: e, bridgestone: e, broadway: e, broker: e, brother: e, brussels: e, build: [1, { v0: t, windsurf: t }], builders: [1, { cloudsite: t }], business: y, buy: e, buzz: e, bzh: e, cab: e, cafe: e, cal: e, call: e, calvinklein: e, cam: e, camera: e, camp: [1, { emf: [0, { at: t }] }], canon: e, capetown: e, capital: e, capitalone: e, car: e, caravan: e, cards: e, care: e, career: e, careers: e, cars: e, casa: [1, { nabu: [0, { ui: t }] }], case: e, cash: e, casino: e, catering: e, catholic: e, cba: e, cbn: e, cbre: e, center: e, ceo: e, cern: e, cfa: e, cfd: e, chanel: e, channel: e, charity: e, chase: e, chat: e, cheap: e, chintai: e, christmas: e, chrome: e, church: e, cipriani: e, circle: e, cisco: e, citadel: e, citi: e, citic: e, city: e, claims: e, cleaning: e, click: e, clinic: e, clinique: e, clothing: e, cloud: [1, { convex: t, elementor: t, encoway: [0, { eu: t }], statics: o, ravendb: t, axarnet: [0, { "es-1": t }], diadem: t, jelastic: [0, { vip: t }], jele: t, "jenv-aruba": [0, { aruba: [0, { eur: [0, { it1: t }] }], it1: t }], keliweb: [2, { cs: t }], oxa: [2, { tn: t, uk: t }], primetel: [2, { uk: t }], reclaim: [0, { ca: t, uk: t, us: t }], trendhosting: [0, { ch: t, de: t }], jotelulu: t, kuleuven: t, laravel: t, linkyard: t, magentosite: o, matlab: t, observablehq: t, perspecta: t, vapor: t, "on-rancher": o, scw: [0, { baremetal: [0, { "fr-par-1": t, "fr-par-2": t, "nl-ams-1": t }], "fr-par": [0, { cockpit: t, fnc: [2, { functions: t }], k8s: k, s3: t, "s3-website": t, whm: t }], instances: [0, { priv: t, pub: t }], k8s: t, "nl-ams": [0, { cockpit: t, k8s: k, s3: t, "s3-website": t, whm: t }], "pl-waw": [0, { cockpit: t, k8s: k, s3: t, "s3-website": t }], scalebook: t, smartlabeling: t }], servebolt: t, onstackit: [0, { runs: t }], trafficplex: t, "unison-services": t, urown: t, voorloper: t, zap: t }], club: [1, { cloudns: t, jele: t, barsy: t }], clubmed: e, coach: e, codes: [1, { owo: o }], coffee: e, college: e, cologne: e, commbank: e, community: [1, { nog: t, ravendb: t, myforum: t }], company: e, compare: e, computer: e, comsec: e, condos: e, construction: e, consulting: e, contact: e, contractors: e, cooking: e, cool: [1, { elementor: t, de: t }], corsica: e, country: e, coupon: e, coupons: e, courses: e, cpa: e, credit: e, creditcard: e, creditunion: e, cricket: e, crown: e, crs: e, cruise: e, cruises: e, cuisinella: e, cymru: e, cyou: e, dad: e, dance: e, data: e, date: e, dating: e, datsun: e, day: e, dclk: e, dds: e, deal: e, dealer: e, deals: e, degree: e, delivery: e, dell: e, deloitte: e, delta: e, democrat: e, dental: e, dentist: e, desi: e, design: [1, { graphic: t, bss: t }], dev: [1, { "12chars": t, myaddr: t, panel: t, lcl: o, lclstage: o, stg: o, stgstage: o, pages: t, r2: t, workers: t, deno: t, "deno-staging": t, deta: t, evervault: s, fly: t, githubpreview: t, gateway: o, hrsn: [2, { psl: [0, { sub: t, wc: [0, { "*": t, sub: o }] }] }], botdash: t, inbrowser: o, "is-a-good": t, "is-a": t, iserv: t, runcontainers: t, localcert: [0, { user: o }], loginline: t, barsy: t, mediatech: t, modx: t, ngrok: t, "ngrok-free": t, "is-a-fullstack": t, "is-cool": t, "is-not-a": t, localplayer: t, xmit: t, "platter-app": t, replit: [2, { archer: t, bones: t, canary: t, global: t, hacker: t, id: t, janeway: t, kim: t, kira: t, kirk: t, odo: t, paris: t, picard: t, pike: t, prerelease: t, reed: t, riker: t, sisko: t, spock: t, staging: t, sulu: t, tarpit: t, teams: t, tucker: t, wesley: t, worf: t }], crm: [0, { d: o, w: o, wa: o, wb: o, wc: o, wd: o, we: o, wf: o }], vercel: t, webhare: o }], dhl: e, diamonds: e, diet: e, digital: [1, { cloudapps: [2, { london: t }] }], direct: [1, { libp2p: t }], directory: e, discount: e, discover: e, dish: e, diy: e, dnp: e, docs: e, doctor: e, dog: e, domains: e, dot: e, download: e, drive: e, dtv: e, dubai: e, dunlop: e, dupont: e, durban: e, dvag: e, dvr: e, earth: e, eat: e, eco: e, edeka: e, education: y, email: [1, { crisp: [0, { on: t }], tawk: Ve, tawkto: Ve }], emerck: e, energy: e, engineer: e, engineering: e, enterprises: e, epson: e, equipment: e, ericsson: e, erni: e, esq: e, estate: [1, { compute: o }], eurovision: e, eus: [1, { party: pa }], events: [1, { koobin: t, co: t }], exchange: e, expert: e, exposed: e, express: e, extraspace: e, fage: e, fail: e, fairwinds: e, faith: e, family: e, fan: e, fans: e, farm: [1, { storj: t }], farmers: e, fashion: e, fast: e, fedex: e, feedback: e, ferrari: e, ferrero: e, fidelity: e, fido: e, film: e, final: e, finance: e, financial: y, fire: e, firestone: e, firmdale: e, fish: e, fishing: e, fit: e, fitness: e, flickr: e, flights: e, flir: e, florist: e, flowers: e, fly: e, foo: e, food: e, football: e, ford: e, forex: e, forsale: e, forum: e, foundation: e, fox: e, free: e, fresenius: e, frl: e, frogans: e, frontier: e, ftr: e, fujitsu: e, fun: e, fund: e, furniture: e, futbol: e, fyi: e, gal: e, gallery: e, gallo: e, gallup: e, game: e, games: [1, { pley: t, sheezy: t }], gap: e, garden: e, gay: [1, { pages: t }], gbiz: e, gdn: [1, { cnpy: t }], gea: e, gent: e, genting: e, george: e, ggee: e, gift: e, gifts: e, gives: e, giving: e, glass: e, gle: e, global: [1, { appwrite: t }], globo: e, gmail: e, gmbh: e, gmo: e, gmx: e, godaddy: e, gold: e, goldpoint: e, golf: e, goo: e, goodyear: e, goog: [1, { cloud: t, translate: t, usercontent: o }], google: e, gop: e, got: e, grainger: e, graphics: e, gratis: e, green: e, gripe: e, grocery: e, group: [1, { discourse: t }], gucci: e, guge: e, guide: e, guitars: e, guru: e, hair: e, hamburg: e, hangout: e, haus: e, hbo: e, hdfc: e, hdfcbank: e, health: [1, { hra: t }], healthcare: e, help: e, helsinki: e, here: e, hermes: e, hiphop: e, hisamitsu: e, hitachi: e, hiv: e, hkt: e, hockey: e, holdings: e, holiday: e, homedepot: e, homegoods: e, homes: e, homesense: e, honda: e, horse: e, hospital: e, host: [1, { cloudaccess: t, freesite: t, easypanel: t, fastvps: t, myfast: t, tempurl: t, wpmudev: t, jele: t, mircloud: t, wp2: t, half: t }], hosting: [1, { opencraft: t }], hot: e, hotels: e, hotmail: e, house: e, how: e, hsbc: e, hughes: e, hyatt: e, hyundai: e, ibm: e, icbc: e, ice: e, icu: e, ieee: e, ifm: e, ikano: e, imamat: e, imdb: e, immo: e, immobilien: e, inc: e, industries: e, infiniti: e, ing: e, ink: e, institute: e, insurance: e, insure: e, international: e, intuit: e, investments: e, ipiranga: e, irish: e, ismaili: e, ist: e, istanbul: e, itau: e, itv: e, jaguar: e, java: e, jcb: e, jeep: e, jetzt: e, jewelry: e, jio: e, jll: e, jmp: e, jnj: e, joburg: e, jot: e, joy: e, jpmorgan: e, jprs: e, juegos: e, juniper: e, kaufen: e, kddi: e, kerryhotels: e, kerryproperties: e, kfh: e, kia: e, kids: e, kim: e, kindle: e, kitchen: e, kiwi: e, koeln: e, komatsu: e, kosher: e, kpmg: e, kpn: e, krd: [1, { co: t, edu: t }], kred: e, kuokgroup: e, kyoto: e, lacaixa: e, lamborghini: e, lamer: e, lancaster: e, land: e, landrover: e, lanxess: e, lasalle: e, lat: e, latino: e, latrobe: e, law: e, lawyer: e, lds: e, lease: e, leclerc: e, lefrak: e, legal: e, lego: e, lexus: e, lgbt: e, lidl: e, life: e, lifeinsurance: e, lifestyle: e, lighting: e, like: e, lilly: e, limited: e, limo: e, lincoln: e, link: [1, { myfritz: t, cyon: t, dweb: o, inbrowser: o, nftstorage: Yo, mypep: t, storacha: Yo, w3s: Yo }], live: [1, { aem: t, hlx: t, ewp: o }], living: e, llc: e, llp: e, loan: e, loans: e, locker: e, locus: e, lol: [1, { omg: t }], london: e, lotte: e, lotto: e, love: e, lpl: e, lplfinancial: e, ltd: e, ltda: e, lundbeck: e, luxe: e, luxury: e, madrid: e, maif: e, maison: e, makeup: e, man: e, management: e, mango: e, map: e, market: e, marketing: e, markets: e, marriott: e, marshalls: e, mattel: e, mba: e, mckinsey: e, med: e, media: br, meet: e, melbourne: e, meme: e, memorial: e, men: e, menu: [1, { barsy: t, barsyonline: t }], merck: e, merckmsd: e, miami: e, microsoft: e, mini: e, mint: e, mit: e, mitsubishi: e, mlb: e, mls: e, mma: e, mobile: e, moda: e, moe: e, moi: e, mom: [1, { ind: t }], monash: e, money: e, monster: e, mormon: e, mortgage: e, moscow: e, moto: e, motorcycles: e, mov: e, movie: e, msd: e, mtn: e, mtr: e, music: e, nab: e, nagoya: e, navy: e, nba: e, nec: e, netbank: e, netflix: e, network: [1, { alces: o, co: t, arvo: t, azimuth: t, tlon: t }], neustar: e, new: e, news: [1, { noticeable: t }], next: e, nextdirect: e, nexus: e, nfl: e, ngo: e, nhk: e, nico: e, nike: e, nikon: e, ninja: e, nissan: e, nissay: e, nokia: e, norton: e, now: e, nowruz: e, nowtv: e, nra: e, nrw: e, ntt: e, nyc: e, obi: e, observer: e, office: e, okinawa: e, olayan: e, olayangroup: e, ollo: e, omega: e, one: [1, { kin: o, service: t }], ong: [1, { obl: t }], onl: e, online: [1, { eero: t, "eero-stage": t, websitebuilder: t, barsy: t }], ooo: e, open: e, oracle: e, orange: [1, { tech: t }], organic: e, origins: e, osaka: e, otsuka: e, ott: e, ovh: [1, { nerdpol: t }], page: [1, { aem: t, hlx: t, hlx3: t, translated: t, codeberg: t, heyflow: t, prvcy: t, rocky: t, pdns: t, plesk: t }], panasonic: e, paris: e, pars: e, partners: e, parts: e, party: e, pay: e, pccw: e, pet: e, pfizer: e, pharmacy: e, phd: e, philips: e, phone: e, photo: e, photography: e, photos: br, physio: e, pics: e, pictet: e, pictures: [1, { 1337: t }], pid: e, pin: e, ping: e, pink: e, pioneer: e, pizza: [1, { ngrok: t }], place: y, play: e, playstation: e, plumbing: e, plus: e, pnc: e, pohl: e, poker: e, politie: e, porn: e, pramerica: e, praxi: e, press: e, prime: e, prod: e, productions: e, prof: e, progressive: e, promo: e, properties: e, property: e, protection: e, pru: e, prudential: e, pub: [1, { id: o, kin: o, barsy: t }], pwc: e, qpon: e, quebec: e, quest: e, racing: e, radio: e, read: e, realestate: e, realtor: e, realty: e, recipes: e, red: e, redstone: e, redumbrella: e, rehab: e, reise: e, reisen: e, reit: e, reliance: e, ren: e, rent: e, rentals: e, repair: e, report: e, republican: e, rest: e, restaurant: e, review: e, reviews: e, rexroth: e, rich: e, richardli: e, ricoh: e, ril: e, rio: e, rip: [1, { clan: t }], rocks: [1, { myddns: t, stackit: t, "lima-city": t, webspace: t }], rodeo: e, rogers: e, room: e, rsvp: e, rugby: e, ruhr: e, run: [1, { appwrite: o, development: t, ravendb: t, liara: [2, { iran: t }], servers: t, build: o, code: o, database: o, migration: o, onporter: t, repl: t, stackit: t, val: [0, { express: t, web: t }], wix: t }], rwe: e, ryukyu: e, saarland: e, safe: e, safety: e, sakura: e, sale: e, salon: e, samsclub: e, samsung: e, sandvik: e, sandvikcoromant: e, sanofi: e, sap: e, sarl: e, sas: e, save: e, saxo: e, sbi: e, sbs: e, scb: e, schaeffler: e, schmidt: e, scholarships: e, school: e, schule: e, schwarz: e, science: e, scot: [1, { gov: [2, { service: t }] }], search: e, seat: e, secure: e, security: e, seek: e, select: e, sener: e, services: [1, { loginline: t }], seven: e, sew: e, sex: e, sexy: e, sfr: e, shangrila: e, sharp: e, shell: e, shia: e, shiksha: e, shoes: e, shop: [1, { base: t, hoplix: t, barsy: t, barsyonline: t, shopware: t }], shopping: e, shouji: e, show: e, silk: e, sina: e, singles: e, site: [1, { square: t, canva: v, cloudera: o, convex: t, cyon: t, fastvps: t, figma: t, heyflow: t, jele: t, jouwweb: t, loginline: t, barsy: t, notion: t, omniwe: t, opensocial: t, madethis: t, platformsh: o, tst: o, byen: t, srht: t, novecore: t, cpanel: t, wpsquared: t }], ski: e, skin: e, sky: e, skype: e, sling: e, smart: e, smile: e, sncf: e, soccer: e, social: e, softbank: e, software: e, sohu: e, solar: e, solutions: e, song: e, sony: e, soy: e, spa: e, space: [1, { myfast: t, heiyu: t, hf: [2, { static: t }], "app-ionos": t, project: t, uber: t, xs4all: t }], sport: e, spot: e, srl: e, stada: e, staples: e, star: e, statebank: e, statefarm: e, stc: e, stcgroup: e, stockholm: e, storage: e, store: [1, { barsy: t, sellfy: t, shopware: t, storebase: t }], stream: e, studio: e, study: e, style: e, sucks: e, supplies: e, supply: e, support: [1, { barsy: t }], surf: e, surgery: e, suzuki: e, swatch: e, swiss: e, sydney: e, systems: [1, { knightpoint: t }], tab: e, taipei: e, talk: e, taobao: e, target: e, tatamotors: e, tatar: e, tattoo: e, tax: e, taxi: e, tci: e, tdk: e, team: [1, { discourse: t, jelastic: t }], tech: [1, { cleverapps: t }], technology: y, temasek: e, tennis: e, teva: e, thd: e, theater: e, theatre: e, tiaa: e, tickets: e, tienda: e, tips: e, tires: e, tirol: e, tjmaxx: e, tjx: e, tkmaxx: e, tmall: e, today: [1, { prequalifyme: t }], tokyo: e, tools: [1, { addr: ee, myaddr: t }], top: [1, { ntdll: t, wadl: o }], toray: e, toshiba: e, total: e, tours: e, town: e, toyota: e, toys: e, trade: e, trading: e, training: e, travel: e, travelers: e, travelersinsurance: e, trust: e, trv: e, tube: e, tui: e, tunes: e, tushu: e, tvs: e, ubank: e, ubs: e, unicom: e, university: e, uno: e, uol: e, ups: e, vacations: e, vana: e, vanguard: e, vegas: e, ventures: e, verisign: e, versicherung: e, vet: e, viajes: e, video: e, vig: e, viking: e, villas: e, vin: e, vip: e, virgin: e, visa: e, vision: e, viva: e, vivo: e, vlaanderen: e, vodka: e, volvo: e, vote: e, voting: e, voto: e, voyage: e, wales: e, walmart: e, walter: e, wang: e, wanggou: e, watch: e, watches: e, weather: e, weatherchannel: e, webcam: e, weber: e, website: br, wed: e, wedding: e, weibo: e, weir: e, whoswho: e, wien: e, wiki: br, williamhill: e, win: e, windows: e, wine: e, winners: e, wme: e, wolterskluwer: e, woodside: e, work: e, works: e, world: e, wow: e, wtc: e, wtf: e, xbox: e, xerox: e, xihuan: e, xin: e, "xn--11b4c3d": e, कॉम: e, "xn--1ck2e1b": e, セール: e, "xn--1qqw23a": e, 佛山: e, "xn--30rr7y": e, 慈善: e, "xn--3bst00m": e, 集团: e, "xn--3ds443g": e, 在线: e, "xn--3pxu8k": e, 点看: e, "xn--42c2d9a": e, คอม: e, "xn--45q11c": e, 八卦: e, "xn--4gbrim": e, موقع: e, "xn--55qw42g": e, 公益: e, "xn--55qx5d": e, 公司: e, "xn--5su34j936bgsg": e, 香格里拉: e, "xn--5tzm5g": e, 网站: e, "xn--6frz82g": e, 移动: e, "xn--6qq986b3xl": e, 我爱你: e, "xn--80adxhks": e, москва: e, "xn--80aqecdr1a": e, католик: e, "xn--80asehdb": e, онлайн: e, "xn--80aswg": e, сайт: e, "xn--8y0a063a": e, 联通: e, "xn--9dbq2a": e, קום: e, "xn--9et52u": e, 时尚: e, "xn--9krt00a": e, 微博: e, "xn--b4w605ferd": e, 淡马锡: e, "xn--bck1b9a5dre4c": e, ファッション: e, "xn--c1avg": e, орг: e, "xn--c2br7g": e, नेट: e, "xn--cck2b3b": e, ストア: e, "xn--cckwcxetd": e, アマゾン: e, "xn--cg4bki": e, 삼성: e, "xn--czr694b": e, 商标: e, "xn--czrs0t": e, 商店: e, "xn--czru2d": e, 商城: e, "xn--d1acj3b": e, дети: e, "xn--eckvdtc9d": e, ポイント: e, "xn--efvy88h": e, 新闻: e, "xn--fct429k": e, 家電: e, "xn--fhbei": e, كوم: e, "xn--fiq228c5hs": e, 中文网: e, "xn--fiq64b": e, 中信: e, "xn--fjq720a": e, 娱乐: e, "xn--flw351e": e, 谷歌: e, "xn--fzys8d69uvgm": e, 電訊盈科: e, "xn--g2xx48c": e, 购物: e, "xn--gckr3f0f": e, クラウド: e, "xn--gk3at1e": e, 通販: e, "xn--hxt814e": e, 网店: e, "xn--i1b6b1a6a2e": e, संगठन: e, "xn--imr513n": e, 餐厅: e, "xn--io0a7i": e, 网络: e, "xn--j1aef": e, ком: e, "xn--jlq480n2rg": e, 亚马逊: e, "xn--jvr189m": e, 食品: e, "xn--kcrx77d1x4a": e, 飞利浦: e, "xn--kput3i": e, 手机: e, "xn--mgba3a3ejt": e, ارامكو: e, "xn--mgba7c0bbn0a": e, العليان: e, "xn--mgbab2bd": e, بازار: e, "xn--mgbca7dzdo": e, ابوظبي: e, "xn--mgbi4ecexp": e, كاثوليك: e, "xn--mgbt3dhd": e, همراه: e, "xn--mk1bu44c": e, 닷컴: e, "xn--mxtq1m": e, 政府: e, "xn--ngbc5azd": e, شبكة: e, "xn--ngbe9e0a": e, بيتك: e, "xn--ngbrx": e, عرب: e, "xn--nqv7f": e, 机构: e, "xn--nqv7fs00ema": e, 组织机构: e, "xn--nyqy26a": e, 健康: e, "xn--otu796d": e, 招聘: e, "xn--p1acf": [1, { "xn--90amc": t, "xn--j1aef": t, "xn--j1ael8b": t, "xn--h1ahn": t, "xn--j1adp": t, "xn--c1avg": t, "xn--80aaa0cvac": t, "xn--h1aliz": t, "xn--90a1af": t, "xn--41a": t }], рус: [1, { биз: t, ком: t, крым: t, мир: t, мск: t, орг: t, самара: t, сочи: t, спб: t, я: t }], "xn--pssy2u": e, 大拿: e, "xn--q9jyb4c": e, みんな: e, "xn--qcka1pmc": e, グーグル: e, "xn--rhqv96g": e, 世界: e, "xn--rovu88b": e, 書籍: e, "xn--ses554g": e, 网址: e, "xn--t60b56a": e, 닷넷: e, "xn--tckwe": e, コム: e, "xn--tiq49xqyj": e, 天主教: e, "xn--unup4y": e, 游戏: e, "xn--vermgensberater-ctb": e, vermögensberater: e, "xn--vermgensberatung-pwb": e, vermögensberatung: e, "xn--vhquv": e, 企业: e, "xn--vuq861b": e, 信息: e, "xn--w4r85el8fhu5dnra": e, 嘉里大酒店: e, "xn--w4rs40l": e, 嘉里: e, "xn--xhq521b": e, 广东: e, "xn--zfr164b": e, 政务: e, xyz: [1, { botdash: t, telebit: o }], yachts: e, yahoo: e, yamaxun: e, yandex: e, yodobashi: e, yoga: e, yokohama: e, you: e, youtube: e, yun: e, zappos: e, zara: e, zero: e, zip: e, zone: [1, { cloud66: t, triton: o, stackit: t, lima: t }], zuerich: e }]; +})(), v0 = /* @__PURE__ */ (function() { + const e = [1, {}], t = [2, {}], n = [1, { com: e, edu: e, gov: e, net: e, org: e }], r = [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e }], o = [0, { "*": t }], i = [2, { s: o }], s = [0, { relay: t }], a = [2, { id: t }], l = [1, { gov: e }], u = [0, { "transfer-webapp": t }], d = [0, { notebook: t, studio: t }], h = [0, { labeling: t, notebook: t, studio: t }], f = [0, { notebook: t }], p = [0, { labeling: t, notebook: t, "notebook-fips": t, studio: t }], g = [0, { notebook: t, "notebook-fips": t, studio: t, "studio-fips": t }], m = [0, { "*": e }], y = [1, { co: t }], x = [0, { objects: t }], k = [2, { nodes: t }], v = [0, { my: o }], b = [0, { s3: t, "s3-accesspoint": t, "s3-website": t }], j = [0, { s3: t, "s3-accesspoint": t }], _ = [0, { direct: t }], S = [0, { "webview-assets": t }], P = [0, { vfs: t, "webview-assets": t }], D = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: P }], $ = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: j, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: P }], C = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], T = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t }], O = [0, { s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-website": t }], I = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: P }], N = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-deprecated": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], U = [0, { s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t }], V = [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: U, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t }], q = [0, { auth: t }], J = [0, { auth: t, "auth-fips": t }], X = [0, { "auth-fips": t }], re = [0, { apps: t }], ve = [0, { paas: t }], tt = [2, { eu: t }], ge = [0, { app: t }], Oe = [0, { site: t }], Y = [1, { com: e, edu: e, net: e, org: e }], G = [0, { j: t }], ee = [0, { dyn: t }], ue = [1, { co: e, com: e, edu: e, gov: e, net: e, org: e }], We = [0, { p: t }], ha = [0, { user: t }], pa = [0, { shop: t }], $n = [0, { cdn: t }], Ko = [0, { cust: t, reservd: t }], ga = [0, { cust: t }], Go = [0, { s3: t }], ma = [1, { biz: e, com: e, edu: e, gov: e, info: e, net: e, org: e }], Xo = [0, { ipfs: t }], br = [1, { framer: t }], ya = [0, { forgot: t }], se = [1, { gs: e }], va = [0, { nes: e }], W = [1, { k12: e, cc: e, lib: e }], xr = [1, { cc: e, lib: e }]; + return [0, { ac: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, drr: t, feedback: t, forms: t }], ad: e, ae: [1, { ac: e, co: e, gov: e, mil: e, net: e, org: e, sch: e }], aero: [1, { airline: e, airport: e, "accident-investigation": e, "accident-prevention": e, aerobatic: e, aeroclub: e, aerodrome: e, agents: e, "air-surveillance": e, "air-traffic-control": e, aircraft: e, airtraffic: e, ambulance: e, association: e, author: e, ballooning: e, broker: e, caa: e, cargo: e, catering: e, certification: e, championship: e, charter: e, civilaviation: e, club: e, conference: e, consultant: e, consulting: e, control: e, council: e, crew: e, design: e, dgca: e, educator: e, emergency: e, engine: e, engineer: e, entertainment: e, equipment: e, exchange: e, express: e, federation: e, flight: e, freight: e, fuel: e, gliding: e, government: e, groundhandling: e, group: e, hanggliding: e, homebuilt: e, insurance: e, journal: e, journalist: e, leasing: e, logistics: e, magazine: e, maintenance: e, marketplace: e, media: e, microlight: e, modelling: e, navigation: e, parachuting: e, paragliding: e, "passenger-association": e, pilot: e, press: e, production: e, recreation: e, repbody: e, res: e, research: e, rotorcraft: e, safety: e, scientist: e, services: e, show: e, skydiving: e, software: e, student: e, taxi: e, trader: e, trading: e, trainer: e, union: e, workinggroup: e, works: e }], af: n, ag: [1, { co: e, com: e, net: e, nom: e, org: e, obj: t }], ai: [1, { com: e, net: e, off: e, org: e, uwu: t, framer: t }], al: r, am: [1, { co: e, com: e, commune: e, net: e, org: e, radio: t }], ao: [1, { co: e, ed: e, edu: e, gov: e, gv: e, it: e, og: e, org: e, pb: e }], aq: e, ar: [1, { bet: e, com: e, coop: e, edu: e, gob: e, gov: e, int: e, mil: e, musica: e, mutual: e, net: e, org: e, seg: e, senasa: e, tur: e }], arpa: [1, { e164: e, home: e, "in-addr": e, ip6: e, iris: e, uri: e, urn: e }], as: l, asia: [1, { cloudns: t, daemon: t, dix: t }], at: [1, { ac: [1, { sth: e }], co: e, gv: e, or: e, funkfeuer: [0, { wien: t }], futurecms: [0, { "*": t, ex: o, in: o }], futurehosting: t, futuremailing: t, ortsinfo: [0, { ex: o, kunden: o }], biz: t, info: t, "123webseite": t, priv: t, myspreadshop: t, "12hp": t, "2ix": t, "4lima": t, "lima-city": t }], au: [1, { asn: e, com: [1, { cloudlets: [0, { mel: t }], myspreadshop: t }], edu: [1, { act: e, catholic: e, nsw: [1, { schools: e }], nt: e, qld: e, sa: e, tas: e, vic: e, wa: e }], gov: [1, { qld: e, sa: e, tas: e, vic: e, wa: e }], id: e, net: e, org: e, conf: e, oz: e, act: e, nsw: e, nt: e, qld: e, sa: e, tas: e, vic: e, wa: e }], aw: [1, { com: e }], ax: e, az: [1, { biz: e, co: e, com: e, edu: e, gov: e, info: e, int: e, mil: e, name: e, net: e, org: e, pp: e, pro: e }], ba: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, rs: t }], bb: [1, { biz: e, co: e, com: e, edu: e, gov: e, info: e, net: e, org: e, store: e, tv: e }], bd: m, be: [1, { ac: e, cloudns: t, webhosting: t, interhostsolutions: [0, { cloud: t }], kuleuven: [0, { ezproxy: t }], "123website": t, myspreadshop: t, transurl: o }], bf: l, bg: [1, { 0: e, 1: e, 2: e, 3: e, 4: e, 5: e, 6: e, 7: e, 8: e, 9: e, a: e, b: e, c: e, d: e, e, f: e, g: e, h: e, i: e, j: e, k: e, l: e, m: e, n: e, o: e, p: e, q: e, r: e, s: e, t: e, u: e, v: e, w: e, x: e, y: e, z: e, barsy: t }], bh: n, bi: [1, { co: e, com: e, edu: e, or: e, org: e }], biz: [1, { activetrail: t, "cloud-ip": t, cloudns: t, jozi: t, dyndns: t, "for-better": t, "for-more": t, "for-some": t, "for-the": t, selfip: t, webhop: t, orx: t, mmafan: t, myftp: t, "no-ip": t, dscloud: t }], bj: [1, { africa: e, agro: e, architectes: e, assur: e, avocats: e, co: e, com: e, eco: e, econo: e, edu: e, info: e, loisirs: e, money: e, net: e, org: e, ote: e, restaurant: e, resto: e, tourism: e, univ: e }], bm: n, bn: [1, { com: e, edu: e, gov: e, net: e, org: e, co: t }], bo: [1, { com: e, edu: e, gob: e, int: e, mil: e, net: e, org: e, tv: e, web: e, academia: e, agro: e, arte: e, blog: e, bolivia: e, ciencia: e, cooperativa: e, democracia: e, deporte: e, ecologia: e, economia: e, empresa: e, indigena: e, industria: e, info: e, medicina: e, movimiento: e, musica: e, natural: e, nombre: e, noticias: e, patria: e, plurinacional: e, politica: e, profesional: e, pueblo: e, revista: e, salud: e, tecnologia: e, tksat: e, transporte: e, wiki: e }], br: [1, { "9guacu": e, abc: e, adm: e, adv: e, agr: e, aju: e, am: e, anani: e, aparecida: e, app: e, arq: e, art: e, ato: e, b: e, barueri: e, belem: e, bet: e, bhz: e, bib: e, bio: e, blog: e, bmd: e, boavista: e, bsb: e, campinagrande: e, campinas: e, caxias: e, cim: e, cng: e, cnt: e, com: [1, { simplesite: t }], contagem: e, coop: e, coz: e, cri: e, cuiaba: e, curitiba: e, def: e, des: e, det: e, dev: e, ecn: e, eco: e, edu: e, emp: e, enf: e, eng: e, esp: e, etc: e, eti: e, far: e, feira: e, flog: e, floripa: e, fm: e, fnd: e, fortal: e, fot: e, foz: e, fst: e, g12: e, geo: e, ggf: e, goiania: e, gov: [1, { ac: e, al: e, am: e, ap: e, ba: e, ce: e, df: e, es: e, go: e, ma: e, mg: e, ms: e, mt: e, pa: e, pb: e, pe: e, pi: e, pr: e, rj: e, rn: e, ro: e, rr: e, rs: e, sc: e, se: e, sp: e, to: e }], gru: e, imb: e, ind: e, inf: e, jab: e, jampa: e, jdf: e, joinville: e, jor: e, jus: e, leg: [1, { ac: t, al: t, am: t, ap: t, ba: t, ce: t, df: t, es: t, go: t, ma: t, mg: t, ms: t, mt: t, pa: t, pb: t, pe: t, pi: t, pr: t, rj: t, rn: t, ro: t, rr: t, rs: t, sc: t, se: t, sp: t, to: t }], leilao: e, lel: e, log: e, londrina: e, macapa: e, maceio: e, manaus: e, maringa: e, mat: e, med: e, mil: e, morena: e, mp: e, mus: e, natal: e, net: e, niteroi: e, nom: m, not: e, ntr: e, odo: e, ong: e, org: e, osasco: e, palmas: e, poa: e, ppg: e, pro: e, psc: e, psi: e, pvh: e, qsl: e, radio: e, rec: e, recife: e, rep: e, ribeirao: e, rio: e, riobranco: e, riopreto: e, salvador: e, sampa: e, santamaria: e, santoandre: e, saobernardo: e, saogonca: e, seg: e, sjc: e, slg: e, slz: e, sorocaba: e, srv: e, taxi: e, tc: e, tec: e, teo: e, the: e, tmp: e, trd: e, tur: e, tv: e, udi: e, vet: e, vix: e, vlog: e, wiki: e, zlg: e }], bs: [1, { com: e, edu: e, gov: e, net: e, org: e, we: t }], bt: n, bv: e, bw: [1, { ac: e, co: e, gov: e, net: e, org: e }], by: [1, { gov: e, mil: e, com: e, of: e, mediatech: t }], bz: [1, { co: e, com: e, edu: e, gov: e, net: e, org: e, za: t, mydns: t, gsj: t }], ca: [1, { ab: e, bc: e, mb: e, nb: e, nf: e, nl: e, ns: e, nt: e, nu: e, on: e, pe: e, qc: e, sk: e, yk: e, gc: e, barsy: t, awdev: o, co: t, "no-ip": t, myspreadshop: t, box: t }], cat: e, cc: [1, { cleverapps: t, cloudns: t, ftpaccess: t, "game-server": t, myphotos: t, scrapping: t, twmail: t, csx: t, fantasyleague: t, spawn: [0, { instances: t }] }], cd: l, cf: e, cg: e, ch: [1, { square7: t, cloudns: t, cloudscale: [0, { cust: t, lpg: x, rma: x }], flow: [0, { ae: [0, { alp1: t }], appengine: t }], "linkyard-cloud": t, gotdns: t, dnsking: t, "123website": t, myspreadshop: t, firenet: [0, { "*": t, svc: o }], "12hp": t, "2ix": t, "4lima": t, "lima-city": t }], ci: [1, { ac: e, "xn--aroport-bya": e, aéroport: e, asso: e, co: e, com: e, ed: e, edu: e, go: e, gouv: e, int: e, net: e, or: e, org: e }], ck: m, cl: [1, { co: e, gob: e, gov: e, mil: e, cloudns: t }], cm: [1, { co: e, com: e, gov: e, net: e }], cn: [1, { ac: e, com: [1, { amazonaws: [0, { "cn-north-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-deprecated": t, "s3-object-lambda": t, "s3-website": t }], "cn-northwest-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: j, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t }], compute: o, airflow: [0, { "cn-north-1": o, "cn-northwest-1": o }], eb: [0, { "cn-north-1": t, "cn-northwest-1": t }], elb: o }], sagemaker: [0, { "cn-north-1": d, "cn-northwest-1": d }] }], edu: e, gov: e, mil: e, net: e, org: e, "xn--55qx5d": e, 公司: e, "xn--od0alg": e, 網絡: e, "xn--io0a7i": e, 网络: e, ah: e, bj: e, cq: e, fj: e, gd: e, gs: e, gx: e, gz: e, ha: e, hb: e, he: e, hi: e, hk: e, hl: e, hn: e, jl: e, js: e, jx: e, ln: e, mo: e, nm: e, nx: e, qh: e, sc: e, sd: e, sh: [1, { as: t }], sn: e, sx: e, tj: e, tw: e, xj: e, xz: e, yn: e, zj: e, "canva-apps": t, canvasite: v, myqnapcloud: t, quickconnect: _ }], co: [1, { com: e, edu: e, gov: e, mil: e, net: e, nom: e, org: e, carrd: t, crd: t, otap: o, leadpages: t, lpages: t, mypi: t, xmit: o, firewalledreplit: a, repl: a, supabase: t }], com: [1, { a2hosted: t, cpserver: t, adobeaemcloud: [2, { dev: o }], africa: t, airkitapps: t, "airkitapps-au": t, aivencloud: t, alibabacloudcs: t, kasserver: t, amazonaws: [0, { "af-south-1": D, "ap-east-1": $, "ap-northeast-1": C, "ap-northeast-2": C, "ap-northeast-3": D, "ap-south-1": C, "ap-south-2": T, "ap-southeast-1": C, "ap-southeast-2": C, "ap-southeast-3": T, "ap-southeast-4": T, "ap-southeast-5": [0, { "execute-api": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-deprecated": t, "s3-object-lambda": t, "s3-website": t }], "ca-central-1": I, "ca-west-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t }], "eu-central-1": C, "eu-central-2": T, "eu-north-1": $, "eu-south-1": D, "eu-south-2": T, "eu-west-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-deprecated": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], "eu-west-2": $, "eu-west-3": D, "il-central-1": [0, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: b, s3: t, "s3-accesspoint": t, "s3-object-lambda": t, "s3-website": t, "aws-cloud9": S, cloud9: [0, { vfs: t }] }], "me-central-1": T, "me-south-1": $, "sa-east-1": D, "us-east-1": [2, { "execute-api": t, "emrappui-prod": t, "emrnotebooks-prod": t, "emrstudio-prod": t, dualstack: O, s3: t, "s3-accesspoint": t, "s3-accesspoint-fips": t, "s3-deprecated": t, "s3-fips": t, "s3-object-lambda": t, "s3-website": t, "analytics-gateway": t, "aws-cloud9": S, cloud9: P }], "us-east-2": N, "us-gov-east-1": V, "us-gov-west-1": V, "us-west-1": I, "us-west-2": N, compute: o, "compute-1": o, airflow: [0, { "af-south-1": o, "ap-east-1": o, "ap-northeast-1": o, "ap-northeast-2": o, "ap-northeast-3": o, "ap-south-1": o, "ap-south-2": o, "ap-southeast-1": o, "ap-southeast-2": o, "ap-southeast-3": o, "ap-southeast-4": o, "ca-central-1": o, "ca-west-1": o, "eu-central-1": o, "eu-central-2": o, "eu-north-1": o, "eu-south-1": o, "eu-south-2": o, "eu-west-1": o, "eu-west-2": o, "eu-west-3": o, "il-central-1": o, "me-central-1": o, "me-south-1": o, "sa-east-1": o, "us-east-1": o, "us-east-2": o, "us-west-1": o, "us-west-2": o }], s3: t, "s3-1": t, "s3-ap-east-1": t, "s3-ap-northeast-1": t, "s3-ap-northeast-2": t, "s3-ap-northeast-3": t, "s3-ap-south-1": t, "s3-ap-southeast-1": t, "s3-ap-southeast-2": t, "s3-ca-central-1": t, "s3-eu-central-1": t, "s3-eu-north-1": t, "s3-eu-west-1": t, "s3-eu-west-2": t, "s3-eu-west-3": t, "s3-external-1": t, "s3-fips-us-gov-east-1": t, "s3-fips-us-gov-west-1": t, "s3-global": [0, { accesspoint: [0, { mrap: t }] }], "s3-me-south-1": t, "s3-sa-east-1": t, "s3-us-east-2": t, "s3-us-gov-east-1": t, "s3-us-gov-west-1": t, "s3-us-west-1": t, "s3-us-west-2": t, "s3-website-ap-northeast-1": t, "s3-website-ap-southeast-1": t, "s3-website-ap-southeast-2": t, "s3-website-eu-west-1": t, "s3-website-sa-east-1": t, "s3-website-us-east-1": t, "s3-website-us-gov-west-1": t, "s3-website-us-west-1": t, "s3-website-us-west-2": t, elb: o }], amazoncognito: [0, { "af-south-1": q, "ap-east-1": q, "ap-northeast-1": q, "ap-northeast-2": q, "ap-northeast-3": q, "ap-south-1": q, "ap-south-2": q, "ap-southeast-1": q, "ap-southeast-2": q, "ap-southeast-3": q, "ap-southeast-4": q, "ap-southeast-5": q, "ca-central-1": q, "ca-west-1": q, "eu-central-1": q, "eu-central-2": q, "eu-north-1": q, "eu-south-1": q, "eu-south-2": q, "eu-west-1": q, "eu-west-2": q, "eu-west-3": q, "il-central-1": q, "me-central-1": q, "me-south-1": q, "sa-east-1": q, "us-east-1": J, "us-east-2": J, "us-gov-east-1": X, "us-gov-west-1": X, "us-west-1": J, "us-west-2": J }], amplifyapp: t, awsapprunner: o, awsapps: t, elasticbeanstalk: [2, { "af-south-1": t, "ap-east-1": t, "ap-northeast-1": t, "ap-northeast-2": t, "ap-northeast-3": t, "ap-south-1": t, "ap-southeast-1": t, "ap-southeast-2": t, "ap-southeast-3": t, "ca-central-1": t, "eu-central-1": t, "eu-north-1": t, "eu-south-1": t, "eu-west-1": t, "eu-west-2": t, "eu-west-3": t, "il-central-1": t, "me-south-1": t, "sa-east-1": t, "us-east-1": t, "us-east-2": t, "us-gov-east-1": t, "us-gov-west-1": t, "us-west-1": t, "us-west-2": t }], awsglobalaccelerator: t, siiites: t, appspacehosted: t, appspaceusercontent: t, "on-aptible": t, myasustor: t, "balena-devices": t, boutir: t, bplaced: t, cafjs: t, "canva-apps": t, "cdn77-storage": t, br: t, cn: t, de: t, eu: t, jpn: t, mex: t, ru: t, sa: t, uk: t, us: t, za: t, "clever-cloud": [0, { services: o }], dnsabr: t, "ip-ddns": t, jdevcloud: t, wpdevcloud: t, "cf-ipfs": t, "cloudflare-ipfs": t, trycloudflare: t, co: t, devinapps: o, builtwithdark: t, datadetect: [0, { demo: t, instance: t }], dattolocal: t, dattorelay: t, dattoweb: t, mydatto: t, digitaloceanspaces: o, discordsays: t, discordsez: t, drayddns: t, dreamhosters: t, durumis: t, mydrobo: t, blogdns: t, cechire: t, dnsalias: t, dnsdojo: t, doesntexist: t, dontexist: t, doomdns: t, "dyn-o-saur": t, dynalias: t, "dyndns-at-home": t, "dyndns-at-work": t, "dyndns-blog": t, "dyndns-free": t, "dyndns-home": t, "dyndns-ip": t, "dyndns-mail": t, "dyndns-office": t, "dyndns-pics": t, "dyndns-remote": t, "dyndns-server": t, "dyndns-web": t, "dyndns-wiki": t, "dyndns-work": t, "est-a-la-maison": t, "est-a-la-masion": t, "est-le-patron": t, "est-mon-blogueur": t, "from-ak": t, "from-al": t, "from-ar": t, "from-ca": t, "from-ct": t, "from-dc": t, "from-de": t, "from-fl": t, "from-ga": t, "from-hi": t, "from-ia": t, "from-id": t, "from-il": t, "from-in": t, "from-ks": t, "from-ky": t, "from-ma": t, "from-md": t, "from-mi": t, "from-mn": t, "from-mo": t, "from-ms": t, "from-mt": t, "from-nc": t, "from-nd": t, "from-ne": t, "from-nh": t, "from-nj": t, "from-nm": t, "from-nv": t, "from-oh": t, "from-ok": t, "from-or": t, "from-pa": t, "from-pr": t, "from-ri": t, "from-sc": t, "from-sd": t, "from-tn": t, "from-tx": t, "from-ut": t, "from-va": t, "from-vt": t, "from-wa": t, "from-wi": t, "from-wv": t, "from-wy": t, getmyip: t, gotdns: t, "hobby-site": t, homelinux: t, homeunix: t, iamallama: t, "is-a-anarchist": t, "is-a-blogger": t, "is-a-bookkeeper": t, "is-a-bulls-fan": t, "is-a-caterer": t, "is-a-chef": t, "is-a-conservative": t, "is-a-cpa": t, "is-a-cubicle-slave": t, "is-a-democrat": t, "is-a-designer": t, "is-a-doctor": t, "is-a-financialadvisor": t, "is-a-geek": t, "is-a-green": t, "is-a-guru": t, "is-a-hard-worker": t, "is-a-hunter": t, "is-a-landscaper": t, "is-a-lawyer": t, "is-a-liberal": t, "is-a-libertarian": t, "is-a-llama": t, "is-a-musician": t, "is-a-nascarfan": t, "is-a-nurse": t, "is-a-painter": t, "is-a-personaltrainer": t, "is-a-photographer": t, "is-a-player": t, "is-a-republican": t, "is-a-rockstar": t, "is-a-socialist": t, "is-a-student": t, "is-a-teacher": t, "is-a-techie": t, "is-a-therapist": t, "is-an-accountant": t, "is-an-actor": t, "is-an-actress": t, "is-an-anarchist": t, "is-an-artist": t, "is-an-engineer": t, "is-an-entertainer": t, "is-certified": t, "is-gone": t, "is-into-anime": t, "is-into-cars": t, "is-into-cartoons": t, "is-into-games": t, "is-leet": t, "is-not-certified": t, "is-slick": t, "is-uberleet": t, "is-with-theband": t, "isa-geek": t, "isa-hockeynut": t, issmarterthanyou: t, "likes-pie": t, likescandy: t, "neat-url": t, "saves-the-whales": t, selfip: t, "sells-for-less": t, "sells-for-u": t, servebbs: t, "simple-url": t, "space-to-rent": t, "teaches-yoga": t, writesthisblog: t, ddnsfree: t, ddnsgeek: t, giize: t, gleeze: t, kozow: t, loseyourip: t, ooguy: t, theworkpc: t, mytuleap: t, "tuleap-partners": t, encoreapi: t, evennode: [0, { "eu-1": t, "eu-2": t, "eu-3": t, "eu-4": t, "us-1": t, "us-2": t, "us-3": t, "us-4": t }], onfabrica: t, "fastly-edge": t, "fastly-terrarium": t, "fastvps-server": t, mydobiss: t, firebaseapp: t, fldrv: t, forgeblocks: t, framercanvas: t, "freebox-os": t, freeboxos: t, freemyip: t, aliases121: t, gentapps: t, gentlentapis: t, githubusercontent: t, "0emm": o, appspot: [2, { r: o }], blogspot: t, codespot: t, googleapis: t, googlecode: t, pagespeedmobilizer: t, withgoogle: t, withyoutube: t, grayjayleagues: t, hatenablog: t, hatenadiary: t, herokuapp: t, gr: t, smushcdn: t, wphostedmail: t, wpmucdn: t, pixolino: t, "apps-1and1": t, "live-website": t, dopaas: t, "hosted-by-previder": ve, hosteur: [0, { "rag-cloud": t, "rag-cloud-ch": t }], "ik-server": [0, { jcloud: t, "jcloud-ver-jpc": t }], jelastic: [0, { demo: t }], massivegrid: ve, wafaicloud: [0, { jed: t, ryd: t }], webadorsite: t, joyent: [0, { cns: o }], lpusercontent: t, linode: [0, { members: t, nodebalancer: o }], linodeobjects: o, linodeusercontent: [0, { ip: t }], localtonet: t, lovableproject: t, barsycenter: t, barsyonline: t, modelscape: t, mwcloudnonprod: t, polyspace: t, mazeplay: t, miniserver: t, atmeta: t, fbsbx: re, meteorapp: tt, routingthecloud: t, mydbserver: t, hostedpi: t, "mythic-beasts": [0, { caracal: t, customer: t, fentiger: t, lynx: t, ocelot: t, oncilla: t, onza: t, sphinx: t, vs: t, x: t, yali: t }], nospamproxy: [0, { cloud: [2, { o365: t }] }], "4u": t, nfshost: t, "3utilities": t, blogsyte: t, ciscofreak: t, damnserver: t, ddnsking: t, ditchyourip: t, dnsiskinky: t, dynns: t, geekgalaxy: t, "health-carereform": t, homesecuritymac: t, homesecuritypc: t, myactivedirectory: t, mysecuritycamera: t, myvnc: t, "net-freaks": t, onthewifi: t, point2this: t, quicksytes: t, securitytactics: t, servebeer: t, servecounterstrike: t, serveexchange: t, serveftp: t, servegame: t, servehalflife: t, servehttp: t, servehumour: t, serveirc: t, servemp3: t, servep2p: t, servepics: t, servequake: t, servesarcasm: t, stufftoread: t, unusualperson: t, workisboring: t, myiphost: t, observableusercontent: [0, { static: t }], simplesite: t, orsites: t, operaunite: t, "customer-oci": [0, { "*": t, oci: o, ocp: o, ocs: o }], oraclecloudapps: o, oraclegovcloudapps: o, "authgear-staging": t, authgearapps: t, skygearapp: t, outsystemscloud: t, ownprovider: t, pgfog: t, pagexl: t, gotpantheon: t, paywhirl: o, upsunapp: t, "postman-echo": t, prgmr: [0, { xen: t }], pythonanywhere: tt, qa2: t, "alpha-myqnapcloud": t, "dev-myqnapcloud": t, mycloudnas: t, mynascloud: t, myqnapcloud: t, qualifioapp: t, ladesk: t, qbuser: t, quipelements: o, rackmaze: t, "readthedocs-hosted": t, rhcloud: t, onrender: t, render: ge, "subsc-pay": t, "180r": t, dojin: t, sakuratan: t, sakuraweb: t, x0: t, code: [0, { builder: o, "dev-builder": o, "stg-builder": o }], salesforce: [0, { platform: [0, { "code-builder-stg": [0, { test: [0, { "001": o }] }] }] }], logoip: t, scrysec: t, "firewall-gateway": t, myshopblocks: t, myshopify: t, shopitsite: t, "1kapp": t, appchizi: t, applinzi: t, sinaapp: t, vipsinaapp: t, streamlitapp: t, "try-snowplow": t, "playstation-cloud": t, myspreadshop: t, "w-corp-staticblitz": t, "w-credentialless-staticblitz": t, "w-staticblitz": t, "stackhero-network": t, stdlib: [0, { api: t }], strapiapp: [2, { media: t }], "streak-link": t, streaklinks: t, streakusercontent: t, "temp-dns": t, dsmynas: t, familyds: t, mytabit: t, taveusercontent: t, "tb-hosting": Oe, reservd: t, thingdustdata: t, "townnews-staging": t, typeform: [0, { pro: t }], hk: t, it: t, "deus-canvas": t, vultrobjects: o, wafflecell: t, hotelwithflight: t, "reserve-online": t, cprapid: t, pleskns: t, remotewd: t, wiardweb: [0, { pages: t }], wixsite: t, wixstudio: t, messwithdns: t, "woltlab-demo": t, wpenginepowered: [2, { js: t }], xnbay: [2, { u2: t, "u2-local": t }], yolasite: t }], coop: e, cr: [1, { ac: e, co: e, ed: e, fi: e, go: e, or: e, sa: e }], cu: [1, { com: e, edu: e, gob: e, inf: e, nat: e, net: e, org: e }], cv: [1, { com: e, edu: e, id: e, int: e, net: e, nome: e, org: e, publ: e }], cw: Y, cx: [1, { gov: e, cloudns: t, ath: t, info: t, assessments: t, calculators: t, funnels: t, paynow: t, quizzes: t, researched: t, tests: t }], cy: [1, { ac: e, biz: e, com: [1, { scaleforce: G }], ekloges: e, gov: e, ltd: e, mil: e, net: e, org: e, press: e, pro: e, tm: e }], cz: [1, { contentproxy9: [0, { rsc: t }], realm: t, e4: t, co: t, metacentrum: [0, { cloud: o, custom: t }], muni: [0, { cloud: [0, { flt: t, usr: t }] }] }], de: [1, { bplaced: t, square7: t, com: t, cosidns: ee, dnsupdater: t, "dynamisches-dns": t, "internet-dns": t, "l-o-g-i-n": t, ddnss: [2, { dyn: t, dyndns: t }], "dyn-ip24": t, dyndns1: t, "home-webserver": [2, { dyn: t }], "myhome-server": t, dnshome: t, fuettertdasnetz: t, isteingeek: t, istmein: t, lebtimnetz: t, leitungsen: t, traeumtgerade: t, frusky: o, goip: t, "xn--gnstigbestellen-zvb": t, günstigbestellen: t, "xn--gnstigliefern-wob": t, günstigliefern: t, "hs-heilbronn": [0, { it: [0, { pages: t, "pages-research": t }] }], "dyn-berlin": t, "in-berlin": t, "in-brb": t, "in-butter": t, "in-dsl": t, "in-vpn": t, iservschule: t, "mein-iserv": t, schulplattform: t, schulserver: t, "test-iserv": t, keymachine: t, "git-repos": t, "lcube-server": t, "svn-repos": t, barsy: t, webspaceconfig: t, "123webseite": t, rub: t, "ruhr-uni-bochum": [2, { noc: [0, { io: t }] }], logoip: t, "firewall-gateway": t, "my-gateway": t, "my-router": t, spdns: t, speedpartner: [0, { customer: t }], myspreadshop: t, "taifun-dns": t, "12hp": t, "2ix": t, "4lima": t, "lima-city": t, "dd-dns": t, "dray-dns": t, draydns: t, "dyn-vpn": t, dynvpn: t, "mein-vigor": t, "my-vigor": t, "my-wan": t, "syno-ds": t, "synology-diskstation": t, "synology-ds": t, uberspace: o, "virtual-user": t, virtualuser: t, "community-pro": t, diskussionsbereich: t }], dj: e, dk: [1, { biz: t, co: t, firm: t, reg: t, store: t, "123hjemmeside": t, myspreadshop: t }], dm: ue, do: [1, { art: e, com: e, edu: e, gob: e, gov: e, mil: e, net: e, org: e, sld: e, web: e }], dz: [1, { art: e, asso: e, com: e, edu: e, gov: e, net: e, org: e, pol: e, soc: e, tm: e }], ec: [1, { com: e, edu: e, fin: e, gob: e, gov: e, info: e, k12: e, med: e, mil: e, net: e, org: e, pro: e, base: t, official: t }], edu: [1, { rit: [0, { "git-pages": t }] }], ee: [1, { aip: e, com: e, edu: e, fie: e, gov: e, lib: e, med: e, org: e, pri: e, riik: e }], eg: [1, { ac: e, com: e, edu: e, eun: e, gov: e, info: e, me: e, mil: e, name: e, net: e, org: e, sci: e, sport: e, tv: e }], er: m, es: [1, { com: e, edu: e, gob: e, nom: e, org: e, "123miweb": t, myspreadshop: t }], et: [1, { biz: e, com: e, edu: e, gov: e, info: e, name: e, net: e, org: e }], eu: [1, { airkitapps: t, cloudns: t, dogado: [0, { jelastic: t }], barsy: t, spdns: t, transurl: o, diskstation: t }], fi: [1, { aland: e, dy: t, "xn--hkkinen-5wa": t, häkkinen: t, iki: t, cloudplatform: [0, { fi: t }], datacenter: [0, { demo: t, paas: t }], kapsi: t, "123kotisivu": t, myspreadshop: t }], fj: [1, { ac: e, biz: e, com: e, gov: e, info: e, mil: e, name: e, net: e, org: e, pro: e }], fk: m, fm: [1, { com: e, edu: e, net: e, org: e, radio: t, user: o }], fo: e, fr: [1, { asso: e, com: e, gouv: e, nom: e, prd: e, tm: e, avoues: e, cci: e, greta: e, "huissier-justice": e, "en-root": t, "fbx-os": t, fbxos: t, "freebox-os": t, freeboxos: t, goupile: t, "123siteweb": t, "on-web": t, "chirurgiens-dentistes-en-france": t, dedibox: t, aeroport: t, avocat: t, chambagri: t, "chirurgiens-dentistes": t, "experts-comptables": t, medecin: t, notaires: t, pharmacien: t, port: t, veterinaire: t, myspreadshop: t, ynh: t }], ga: e, gb: e, gd: [1, { edu: e, gov: e }], ge: [1, { com: e, edu: e, gov: e, net: e, org: e, pvt: e, school: e }], gf: e, gg: [1, { co: e, net: e, org: e, botdash: t, kaas: t, stackit: t, panel: [2, { daemon: t }] }], gh: [1, { com: e, edu: e, gov: e, mil: e, org: e }], gi: [1, { com: e, edu: e, gov: e, ltd: e, mod: e, org: e }], gl: [1, { co: e, com: e, edu: e, net: e, org: e, biz: t }], gm: e, gn: [1, { ac: e, com: e, edu: e, gov: e, net: e, org: e }], gov: e, gp: [1, { asso: e, com: e, edu: e, mobi: e, net: e, org: e }], gq: e, gr: [1, { com: e, edu: e, gov: e, net: e, org: e, barsy: t, simplesite: t }], gs: e, gt: [1, { com: e, edu: e, gob: e, ind: e, mil: e, net: e, org: e }], gu: [1, { com: e, edu: e, gov: e, guam: e, info: e, net: e, org: e, web: e }], gw: e, gy: ue, hk: [1, { com: e, edu: e, gov: e, idv: e, net: e, org: e, "xn--ciqpn": e, 个人: e, "xn--gmqw5a": e, 個人: e, "xn--55qx5d": e, 公司: e, "xn--mxtq1m": e, 政府: e, "xn--lcvr32d": e, 敎育: e, "xn--wcvs22d": e, 教育: e, "xn--gmq050i": e, 箇人: e, "xn--uc0atv": e, 組織: e, "xn--uc0ay4a": e, 組织: e, "xn--od0alg": e, 網絡: e, "xn--zf0avx": e, 網络: e, "xn--mk0axi": e, 组織: e, "xn--tn0ag": e, 组织: e, "xn--od0aq3b": e, 网絡: e, "xn--io0a7i": e, 网络: e, inc: t, ltd: t }], hm: e, hn: [1, { com: e, edu: e, gob: e, mil: e, net: e, org: e }], hr: [1, { com: e, from: e, iz: e, name: e, brendly: pa }], ht: [1, { adult: e, art: e, asso: e, com: e, coop: e, edu: e, firm: e, gouv: e, info: e, med: e, net: e, org: e, perso: e, pol: e, pro: e, rel: e, shop: e, rt: t }], hu: [1, { 2e3: e, agrar: e, bolt: e, casino: e, city: e, co: e, erotica: e, erotika: e, film: e, forum: e, games: e, hotel: e, info: e, ingatlan: e, jogasz: e, konyvelo: e, lakas: e, media: e, news: e, org: e, priv: e, reklam: e, sex: e, shop: e, sport: e, suli: e, szex: e, tm: e, tozsde: e, utazas: e, video: e }], id: [1, { ac: e, biz: e, co: e, desa: e, go: e, mil: e, my: e, net: e, or: e, ponpes: e, sch: e, web: e, zone: t }], ie: [1, { gov: e, myspreadshop: t }], il: [1, { ac: e, co: [1, { ravpage: t, mytabit: t, tabitorder: t }], gov: e, idf: e, k12: e, muni: e, net: e, org: e }], "xn--4dbrk0ce": [1, { "xn--4dbgdty6c": e, "xn--5dbhl8d": e, "xn--8dbq2a": e, "xn--hebda8b": e }], ישראל: [1, { אקדמיה: e, ישוב: e, צהל: e, ממשל: e }], im: [1, { ac: e, co: [1, { ltd: e, plc: e }], com: e, net: e, org: e, tt: e, tv: e }], in: [1, { "5g": e, "6g": e, ac: e, ai: e, am: e, bihar: e, biz: e, business: e, ca: e, cn: e, co: e, com: e, coop: e, cs: e, delhi: e, dr: e, edu: e, er: e, firm: e, gen: e, gov: e, gujarat: e, ind: e, info: e, int: e, internet: e, io: e, me: e, mil: e, net: e, nic: e, org: e, pg: e, post: e, pro: e, res: e, travel: e, tv: e, uk: e, up: e, us: e, cloudns: t, barsy: t, web: t, supabase: t }], info: [1, { cloudns: t, "dynamic-dns": t, "barrel-of-knowledge": t, "barrell-of-knowledge": t, dyndns: t, "for-our": t, "groks-the": t, "groks-this": t, "here-for-more": t, knowsitall: t, selfip: t, webhop: t, barsy: t, mayfirst: t, mittwald: t, mittwaldserver: t, typo3server: t, dvrcam: t, ilovecollege: t, "no-ip": t, forumz: t, nsupdate: t, dnsupdate: t, "v-info": t }], int: [1, { eu: e }], io: [1, { 2038: t, co: e, com: e, edu: e, gov: e, mil: e, net: e, nom: e, org: e, "on-acorn": o, myaddr: t, apigee: t, "b-data": t, beagleboard: t, bitbucket: t, bluebite: t, boxfuse: t, brave: i, browsersafetymark: t, bubble: $n, bubbleapps: t, bigv: [0, { uk0: t }], cleverapps: t, cloudbeesusercontent: t, dappnode: [0, { dyndns: t }], darklang: t, definima: t, dedyn: t, "fh-muenster": t, shw: t, forgerock: [0, { id: t }], github: t, gitlab: t, lolipop: t, "hasura-app": t, hostyhosting: t, hypernode: t, moonscale: o, beebyte: ve, beebyteapp: [0, { sekd1: t }], jele: t, webthings: t, loginline: t, barsy: t, azurecontainer: o, ngrok: [2, { ap: t, au: t, eu: t, in: t, jp: t, sa: t, us: t }], nodeart: [0, { stage: t }], pantheonsite: t, pstmn: [2, { mock: t }], protonet: t, qcx: [2, { sys: o }], qoto: t, vaporcloud: t, myrdbx: t, "rb-hosting": Oe, "on-k3s": o, "on-rio": o, readthedocs: t, resindevice: t, resinstaging: [0, { devices: t }], hzc: t, sandcats: t, scrypted: [0, { client: t }], "mo-siemens": t, lair: re, stolos: o, musician: t, utwente: t, edugit: t, telebit: t, thingdust: [0, { dev: Ko, disrec: Ko, prod: ga, testing: Ko }], tickets: t, webflow: t, webflowtest: t, editorx: t, wixstudio: t, basicserver: t, virtualserver: t }], iq: r, ir: [1, { ac: e, co: e, gov: e, id: e, net: e, org: e, sch: e, "xn--mgba3a4f16a": e, ایران: e, "xn--mgba3a4fra": e, ايران: e, arvanedge: t }], is: e, it: [1, { edu: e, gov: e, abr: e, abruzzo: e, "aosta-valley": e, aostavalley: e, bas: e, basilicata: e, cal: e, calabria: e, cam: e, campania: e, "emilia-romagna": e, emiliaromagna: e, emr: e, "friuli-v-giulia": e, "friuli-ve-giulia": e, "friuli-vegiulia": e, "friuli-venezia-giulia": e, "friuli-veneziagiulia": e, "friuli-vgiulia": e, "friuliv-giulia": e, "friulive-giulia": e, friulivegiulia: e, "friulivenezia-giulia": e, friuliveneziagiulia: e, friulivgiulia: e, fvg: e, laz: e, lazio: e, lig: e, liguria: e, lom: e, lombardia: e, lombardy: e, lucania: e, mar: e, marche: e, mol: e, molise: e, piedmont: e, piemonte: e, pmn: e, pug: e, puglia: e, sar: e, sardegna: e, sardinia: e, sic: e, sicilia: e, sicily: e, taa: e, tos: e, toscana: e, "trentin-sud-tirol": e, "xn--trentin-sd-tirol-rzb": e, "trentin-süd-tirol": e, "trentin-sudtirol": e, "xn--trentin-sdtirol-7vb": e, "trentin-südtirol": e, "trentin-sued-tirol": e, "trentin-suedtirol": e, trentino: e, "trentino-a-adige": e, "trentino-aadige": e, "trentino-alto-adige": e, "trentino-altoadige": e, "trentino-s-tirol": e, "trentino-stirol": e, "trentino-sud-tirol": e, "xn--trentino-sd-tirol-c3b": e, "trentino-süd-tirol": e, "trentino-sudtirol": e, "xn--trentino-sdtirol-szb": e, "trentino-südtirol": e, "trentino-sued-tirol": e, "trentino-suedtirol": e, "trentinoa-adige": e, trentinoaadige: e, "trentinoalto-adige": e, trentinoaltoadige: e, "trentinos-tirol": e, trentinostirol: e, "trentinosud-tirol": e, "xn--trentinosd-tirol-rzb": e, "trentinosüd-tirol": e, trentinosudtirol: e, "xn--trentinosdtirol-7vb": e, trentinosüdtirol: e, "trentinosued-tirol": e, trentinosuedtirol: e, "trentinsud-tirol": e, "xn--trentinsd-tirol-6vb": e, "trentinsüd-tirol": e, trentinsudtirol: e, "xn--trentinsdtirol-nsb": e, trentinsüdtirol: e, "trentinsued-tirol": e, trentinsuedtirol: e, tuscany: e, umb: e, umbria: e, "val-d-aosta": e, "val-daosta": e, "vald-aosta": e, valdaosta: e, "valle-aosta": e, "valle-d-aosta": e, "valle-daosta": e, valleaosta: e, "valled-aosta": e, valledaosta: e, "vallee-aoste": e, "xn--valle-aoste-ebb": e, "vallée-aoste": e, "vallee-d-aoste": e, "xn--valle-d-aoste-ehb": e, "vallée-d-aoste": e, valleeaoste: e, "xn--valleaoste-e7a": e, valléeaoste: e, valleedaoste: e, "xn--valledaoste-ebb": e, valléedaoste: e, vao: e, vda: e, ven: e, veneto: e, ag: e, agrigento: e, al: e, alessandria: e, "alto-adige": e, altoadige: e, an: e, ancona: e, "andria-barletta-trani": e, "andria-trani-barletta": e, andriabarlettatrani: e, andriatranibarletta: e, ao: e, aosta: e, aoste: e, ap: e, aq: e, aquila: e, ar: e, arezzo: e, "ascoli-piceno": e, ascolipiceno: e, asti: e, at: e, av: e, avellino: e, ba: e, balsan: e, "balsan-sudtirol": e, "xn--balsan-sdtirol-nsb": e, "balsan-südtirol": e, "balsan-suedtirol": e, bari: e, "barletta-trani-andria": e, barlettatraniandria: e, belluno: e, benevento: e, bergamo: e, bg: e, bi: e, biella: e, bl: e, bn: e, bo: e, bologna: e, bolzano: e, "bolzano-altoadige": e, bozen: e, "bozen-sudtirol": e, "xn--bozen-sdtirol-2ob": e, "bozen-südtirol": e, "bozen-suedtirol": e, br: e, brescia: e, brindisi: e, bs: e, bt: e, bulsan: e, "bulsan-sudtirol": e, "xn--bulsan-sdtirol-nsb": e, "bulsan-südtirol": e, "bulsan-suedtirol": e, bz: e, ca: e, cagliari: e, caltanissetta: e, "campidano-medio": e, campidanomedio: e, campobasso: e, "carbonia-iglesias": e, carboniaiglesias: e, "carrara-massa": e, carraramassa: e, caserta: e, catania: e, catanzaro: e, cb: e, ce: e, "cesena-forli": e, "xn--cesena-forl-mcb": e, "cesena-forlì": e, cesenaforli: e, "xn--cesenaforl-i8a": e, cesenaforlì: e, ch: e, chieti: e, ci: e, cl: e, cn: e, co: e, como: e, cosenza: e, cr: e, cremona: e, crotone: e, cs: e, ct: e, cuneo: e, cz: e, "dell-ogliastra": e, dellogliastra: e, en: e, enna: e, fc: e, fe: e, fermo: e, ferrara: e, fg: e, fi: e, firenze: e, florence: e, fm: e, foggia: e, "forli-cesena": e, "xn--forl-cesena-fcb": e, "forlì-cesena": e, forlicesena: e, "xn--forlcesena-c8a": e, forlìcesena: e, fr: e, frosinone: e, ge: e, genoa: e, genova: e, go: e, gorizia: e, gr: e, grosseto: e, "iglesias-carbonia": e, iglesiascarbonia: e, im: e, imperia: e, is: e, isernia: e, kr: e, "la-spezia": e, laquila: e, laspezia: e, latina: e, lc: e, le: e, lecce: e, lecco: e, li: e, livorno: e, lo: e, lodi: e, lt: e, lu: e, lucca: e, macerata: e, mantova: e, "massa-carrara": e, massacarrara: e, matera: e, mb: e, mc: e, me: e, "medio-campidano": e, mediocampidano: e, messina: e, mi: e, milan: e, milano: e, mn: e, mo: e, modena: e, monza: e, "monza-brianza": e, "monza-e-della-brianza": e, monzabrianza: e, monzaebrianza: e, monzaedellabrianza: e, ms: e, mt: e, na: e, naples: e, napoli: e, no: e, novara: e, nu: e, nuoro: e, og: e, ogliastra: e, "olbia-tempio": e, olbiatempio: e, or: e, oristano: e, ot: e, pa: e, padova: e, padua: e, palermo: e, parma: e, pavia: e, pc: e, pd: e, pe: e, perugia: e, "pesaro-urbino": e, pesarourbino: e, pescara: e, pg: e, pi: e, piacenza: e, pisa: e, pistoia: e, pn: e, po: e, pordenone: e, potenza: e, pr: e, prato: e, pt: e, pu: e, pv: e, pz: e, ra: e, ragusa: e, ravenna: e, rc: e, re: e, "reggio-calabria": e, "reggio-emilia": e, reggiocalabria: e, reggioemilia: e, rg: e, ri: e, rieti: e, rimini: e, rm: e, rn: e, ro: e, roma: e, rome: e, rovigo: e, sa: e, salerno: e, sassari: e, savona: e, si: e, siena: e, siracusa: e, so: e, sondrio: e, sp: e, sr: e, ss: e, "xn--sdtirol-n2a": e, südtirol: e, suedtirol: e, sv: e, ta: e, taranto: e, te: e, "tempio-olbia": e, tempioolbia: e, teramo: e, terni: e, tn: e, to: e, torino: e, tp: e, tr: e, "trani-andria-barletta": e, "trani-barletta-andria": e, traniandriabarletta: e, tranibarlettaandria: e, trapani: e, trento: e, treviso: e, trieste: e, ts: e, turin: e, tv: e, ud: e, udine: e, "urbino-pesaro": e, urbinopesaro: e, va: e, varese: e, vb: e, vc: e, ve: e, venezia: e, venice: e, verbania: e, vercelli: e, verona: e, vi: e, "vibo-valentia": e, vibovalentia: e, vicenza: e, viterbo: e, vr: e, vs: e, vt: e, vv: e, "12chars": t, ibxos: t, iliadboxos: t, neen: [0, { jc: t }], "123homepage": t, "16-b": t, "32-b": t, "64-b": t, myspreadshop: t, syncloud: t }], je: [1, { co: e, net: e, org: e, of: t }], jm: m, jo: [1, { agri: e, ai: e, com: e, edu: e, eng: e, fm: e, gov: e, mil: e, net: e, org: e, per: e, phd: e, sch: e, tv: e }], jobs: e, jp: [1, { ac: e, ad: e, co: e, ed: e, go: e, gr: e, lg: e, ne: [1, { aseinet: ha, gehirn: t, ivory: t, "mail-box": t, mints: t, mokuren: t, opal: t, sakura: t, sumomo: t, topaz: t }], or: e, aichi: [1, { aisai: e, ama: e, anjo: e, asuke: e, chiryu: e, chita: e, fuso: e, gamagori: e, handa: e, hazu: e, hekinan: e, higashiura: e, ichinomiya: e, inazawa: e, inuyama: e, isshiki: e, iwakura: e, kanie: e, kariya: e, kasugai: e, kira: e, kiyosu: e, komaki: e, konan: e, kota: e, mihama: e, miyoshi: e, nishio: e, nisshin: e, obu: e, oguchi: e, oharu: e, okazaki: e, owariasahi: e, seto: e, shikatsu: e, shinshiro: e, shitara: e, tahara: e, takahama: e, tobishima: e, toei: e, togo: e, tokai: e, tokoname: e, toyoake: e, toyohashi: e, toyokawa: e, toyone: e, toyota: e, tsushima: e, yatomi: e }], akita: [1, { akita: e, daisen: e, fujisato: e, gojome: e, hachirogata: e, happou: e, higashinaruse: e, honjo: e, honjyo: e, ikawa: e, kamikoani: e, kamioka: e, katagami: e, kazuno: e, kitaakita: e, kosaka: e, kyowa: e, misato: e, mitane: e, moriyoshi: e, nikaho: e, noshiro: e, odate: e, oga: e, ogata: e, semboku: e, yokote: e, yurihonjo: e }], aomori: [1, { aomori: e, gonohe: e, hachinohe: e, hashikami: e, hiranai: e, hirosaki: e, itayanagi: e, kuroishi: e, misawa: e, mutsu: e, nakadomari: e, noheji: e, oirase: e, owani: e, rokunohe: e, sannohe: e, shichinohe: e, shingo: e, takko: e, towada: e, tsugaru: e, tsuruta: e }], chiba: [1, { abiko: e, asahi: e, chonan: e, chosei: e, choshi: e, chuo: e, funabashi: e, futtsu: e, hanamigawa: e, ichihara: e, ichikawa: e, ichinomiya: e, inzai: e, isumi: e, kamagaya: e, kamogawa: e, kashiwa: e, katori: e, katsuura: e, kimitsu: e, kisarazu: e, kozaki: e, kujukuri: e, kyonan: e, matsudo: e, midori: e, mihama: e, minamiboso: e, mobara: e, mutsuzawa: e, nagara: e, nagareyama: e, narashino: e, narita: e, noda: e, oamishirasato: e, omigawa: e, onjuku: e, otaki: e, sakae: e, sakura: e, shimofusa: e, shirako: e, shiroi: e, shisui: e, sodegaura: e, sosa: e, tako: e, tateyama: e, togane: e, tohnosho: e, tomisato: e, urayasu: e, yachimata: e, yachiyo: e, yokaichiba: e, yokoshibahikari: e, yotsukaido: e }], ehime: [1, { ainan: e, honai: e, ikata: e, imabari: e, iyo: e, kamijima: e, kihoku: e, kumakogen: e, masaki: e, matsuno: e, matsuyama: e, namikata: e, niihama: e, ozu: e, saijo: e, seiyo: e, shikokuchuo: e, tobe: e, toon: e, uchiko: e, uwajima: e, yawatahama: e }], fukui: [1, { echizen: e, eiheiji: e, fukui: e, ikeda: e, katsuyama: e, mihama: e, minamiechizen: e, obama: e, ohi: e, ono: e, sabae: e, sakai: e, takahama: e, tsuruga: e, wakasa: e }], fukuoka: [1, { ashiya: e, buzen: e, chikugo: e, chikuho: e, chikujo: e, chikushino: e, chikuzen: e, chuo: e, dazaifu: e, fukuchi: e, hakata: e, higashi: e, hirokawa: e, hisayama: e, iizuka: e, inatsuki: e, kaho: e, kasuga: e, kasuya: e, kawara: e, keisen: e, koga: e, kurate: e, kurogi: e, kurume: e, minami: e, miyako: e, miyama: e, miyawaka: e, mizumaki: e, munakata: e, nakagawa: e, nakama: e, nishi: e, nogata: e, ogori: e, okagaki: e, okawa: e, oki: e, omuta: e, onga: e, onojo: e, oto: e, saigawa: e, sasaguri: e, shingu: e, shinyoshitomi: e, shonai: e, soeda: e, sue: e, tachiarai: e, tagawa: e, takata: e, toho: e, toyotsu: e, tsuiki: e, ukiha: e, umi: e, usui: e, yamada: e, yame: e, yanagawa: e, yukuhashi: e }], fukushima: [1, { aizubange: e, aizumisato: e, aizuwakamatsu: e, asakawa: e, bandai: e, date: e, fukushima: e, furudono: e, futaba: e, hanawa: e, higashi: e, hirata: e, hirono: e, iitate: e, inawashiro: e, ishikawa: e, iwaki: e, izumizaki: e, kagamiishi: e, kaneyama: e, kawamata: e, kitakata: e, kitashiobara: e, koori: e, koriyama: e, kunimi: e, miharu: e, mishima: e, namie: e, nango: e, nishiaizu: e, nishigo: e, okuma: e, omotego: e, ono: e, otama: e, samegawa: e, shimogo: e, shirakawa: e, showa: e, soma: e, sukagawa: e, taishin: e, tamakawa: e, tanagura: e, tenei: e, yabuki: e, yamato: e, yamatsuri: e, yanaizu: e, yugawa: e }], gifu: [1, { anpachi: e, ena: e, gifu: e, ginan: e, godo: e, gujo: e, hashima: e, hichiso: e, hida: e, higashishirakawa: e, ibigawa: e, ikeda: e, kakamigahara: e, kani: e, kasahara: e, kasamatsu: e, kawaue: e, kitagata: e, mino: e, minokamo: e, mitake: e, mizunami: e, motosu: e, nakatsugawa: e, ogaki: e, sakahogi: e, seki: e, sekigahara: e, shirakawa: e, tajimi: e, takayama: e, tarui: e, toki: e, tomika: e, wanouchi: e, yamagata: e, yaotsu: e, yoro: e }], gunma: [1, { annaka: e, chiyoda: e, fujioka: e, higashiagatsuma: e, isesaki: e, itakura: e, kanna: e, kanra: e, katashina: e, kawaba: e, kiryu: e, kusatsu: e, maebashi: e, meiwa: e, midori: e, minakami: e, naganohara: e, nakanojo: e, nanmoku: e, numata: e, oizumi: e, ora: e, ota: e, shibukawa: e, shimonita: e, shinto: e, showa: e, takasaki: e, takayama: e, tamamura: e, tatebayashi: e, tomioka: e, tsukiyono: e, tsumagoi: e, ueno: e, yoshioka: e }], hiroshima: [1, { asaminami: e, daiwa: e, etajima: e, fuchu: e, fukuyama: e, hatsukaichi: e, higashihiroshima: e, hongo: e, jinsekikogen: e, kaita: e, kui: e, kumano: e, kure: e, mihara: e, miyoshi: e, naka: e, onomichi: e, osakikamijima: e, otake: e, saka: e, sera: e, seranishi: e, shinichi: e, shobara: e, takehara: e }], hokkaido: [1, { abashiri: e, abira: e, aibetsu: e, akabira: e, akkeshi: e, asahikawa: e, ashibetsu: e, ashoro: e, assabu: e, atsuma: e, bibai: e, biei: e, bifuka: e, bihoro: e, biratori: e, chippubetsu: e, chitose: e, date: e, ebetsu: e, embetsu: e, eniwa: e, erimo: e, esan: e, esashi: e, fukagawa: e, fukushima: e, furano: e, furubira: e, haboro: e, hakodate: e, hamatonbetsu: e, hidaka: e, higashikagura: e, higashikawa: e, hiroo: e, hokuryu: e, hokuto: e, honbetsu: e, horokanai: e, horonobe: e, ikeda: e, imakane: e, ishikari: e, iwamizawa: e, iwanai: e, kamifurano: e, kamikawa: e, kamishihoro: e, kamisunagawa: e, kamoenai: e, kayabe: e, kembuchi: e, kikonai: e, kimobetsu: e, kitahiroshima: e, kitami: e, kiyosato: e, koshimizu: e, kunneppu: e, kuriyama: e, kuromatsunai: e, kushiro: e, kutchan: e, kyowa: e, mashike: e, matsumae: e, mikasa: e, minamifurano: e, mombetsu: e, moseushi: e, mukawa: e, muroran: e, naie: e, nakagawa: e, nakasatsunai: e, nakatombetsu: e, nanae: e, nanporo: e, nayoro: e, nemuro: e, niikappu: e, niki: e, nishiokoppe: e, noboribetsu: e, numata: e, obihiro: e, obira: e, oketo: e, okoppe: e, otaru: e, otobe: e, otofuke: e, otoineppu: e, oumu: e, ozora: e, pippu: e, rankoshi: e, rebun: e, rikubetsu: e, rishiri: e, rishirifuji: e, saroma: e, sarufutsu: e, shakotan: e, shari: e, shibecha: e, shibetsu: e, shikabe: e, shikaoi: e, shimamaki: e, shimizu: e, shimokawa: e, shinshinotsu: e, shintoku: e, shiranuka: e, shiraoi: e, shiriuchi: e, sobetsu: e, sunagawa: e, taiki: e, takasu: e, takikawa: e, takinoue: e, teshikaga: e, tobetsu: e, tohma: e, tomakomai: e, tomari: e, toya: e, toyako: e, toyotomi: e, toyoura: e, tsubetsu: e, tsukigata: e, urakawa: e, urausu: e, uryu: e, utashinai: e, wakkanai: e, wassamu: e, yakumo: e, yoichi: e }], hyogo: [1, { aioi: e, akashi: e, ako: e, amagasaki: e, aogaki: e, asago: e, ashiya: e, awaji: e, fukusaki: e, goshiki: e, harima: e, himeji: e, ichikawa: e, inagawa: e, itami: e, kakogawa: e, kamigori: e, kamikawa: e, kasai: e, kasuga: e, kawanishi: e, miki: e, minamiawaji: e, nishinomiya: e, nishiwaki: e, ono: e, sanda: e, sannan: e, sasayama: e, sayo: e, shingu: e, shinonsen: e, shiso: e, sumoto: e, taishi: e, taka: e, takarazuka: e, takasago: e, takino: e, tamba: e, tatsuno: e, toyooka: e, yabu: e, yashiro: e, yoka: e, yokawa: e }], ibaraki: [1, { ami: e, asahi: e, bando: e, chikusei: e, daigo: e, fujishiro: e, hitachi: e, hitachinaka: e, hitachiomiya: e, hitachiota: e, ibaraki: e, ina: e, inashiki: e, itako: e, iwama: e, joso: e, kamisu: e, kasama: e, kashima: e, kasumigaura: e, koga: e, miho: e, mito: e, moriya: e, naka: e, namegata: e, oarai: e, ogawa: e, omitama: e, ryugasaki: e, sakai: e, sakuragawa: e, shimodate: e, shimotsuma: e, shirosato: e, sowa: e, suifu: e, takahagi: e, tamatsukuri: e, tokai: e, tomobe: e, tone: e, toride: e, tsuchiura: e, tsukuba: e, uchihara: e, ushiku: e, yachiyo: e, yamagata: e, yawara: e, yuki: e }], ishikawa: [1, { anamizu: e, hakui: e, hakusan: e, kaga: e, kahoku: e, kanazawa: e, kawakita: e, komatsu: e, nakanoto: e, nanao: e, nomi: e, nonoichi: e, noto: e, shika: e, suzu: e, tsubata: e, tsurugi: e, uchinada: e, wajima: e }], iwate: [1, { fudai: e, fujisawa: e, hanamaki: e, hiraizumi: e, hirono: e, ichinohe: e, ichinoseki: e, iwaizumi: e, iwate: e, joboji: e, kamaishi: e, kanegasaki: e, karumai: e, kawai: e, kitakami: e, kuji: e, kunohe: e, kuzumaki: e, miyako: e, mizusawa: e, morioka: e, ninohe: e, noda: e, ofunato: e, oshu: e, otsuchi: e, rikuzentakata: e, shiwa: e, shizukuishi: e, sumita: e, tanohata: e, tono: e, yahaba: e, yamada: e }], kagawa: [1, { ayagawa: e, higashikagawa: e, kanonji: e, kotohira: e, manno: e, marugame: e, mitoyo: e, naoshima: e, sanuki: e, tadotsu: e, takamatsu: e, tonosho: e, uchinomi: e, utazu: e, zentsuji: e }], kagoshima: [1, { akune: e, amami: e, hioki: e, isa: e, isen: e, izumi: e, kagoshima: e, kanoya: e, kawanabe: e, kinko: e, kouyama: e, makurazaki: e, matsumoto: e, minamitane: e, nakatane: e, nishinoomote: e, satsumasendai: e, soo: e, tarumizu: e, yusui: e }], kanagawa: [1, { aikawa: e, atsugi: e, ayase: e, chigasaki: e, ebina: e, fujisawa: e, hadano: e, hakone: e, hiratsuka: e, isehara: e, kaisei: e, kamakura: e, kiyokawa: e, matsuda: e, minamiashigara: e, miura: e, nakai: e, ninomiya: e, odawara: e, oi: e, oiso: e, sagamihara: e, samukawa: e, tsukui: e, yamakita: e, yamato: e, yokosuka: e, yugawara: e, zama: e, zushi: e }], kochi: [1, { aki: e, geisei: e, hidaka: e, higashitsuno: e, ino: e, kagami: e, kami: e, kitagawa: e, kochi: e, mihara: e, motoyama: e, muroto: e, nahari: e, nakamura: e, nankoku: e, nishitosa: e, niyodogawa: e, ochi: e, okawa: e, otoyo: e, otsuki: e, sakawa: e, sukumo: e, susaki: e, tosa: e, tosashimizu: e, toyo: e, tsuno: e, umaji: e, yasuda: e, yusuhara: e }], kumamoto: [1, { amakusa: e, arao: e, aso: e, choyo: e, gyokuto: e, kamiamakusa: e, kikuchi: e, kumamoto: e, mashiki: e, mifune: e, minamata: e, minamioguni: e, nagasu: e, nishihara: e, oguni: e, ozu: e, sumoto: e, takamori: e, uki: e, uto: e, yamaga: e, yamato: e, yatsushiro: e }], kyoto: [1, { ayabe: e, fukuchiyama: e, higashiyama: e, ide: e, ine: e, joyo: e, kameoka: e, kamo: e, kita: e, kizu: e, kumiyama: e, kyotamba: e, kyotanabe: e, kyotango: e, maizuru: e, minami: e, minamiyamashiro: e, miyazu: e, muko: e, nagaokakyo: e, nakagyo: e, nantan: e, oyamazaki: e, sakyo: e, seika: e, tanabe: e, uji: e, ujitawara: e, wazuka: e, yamashina: e, yawata: e }], mie: [1, { asahi: e, inabe: e, ise: e, kameyama: e, kawagoe: e, kiho: e, kisosaki: e, kiwa: e, komono: e, kumano: e, kuwana: e, matsusaka: e, meiwa: e, mihama: e, minamiise: e, misugi: e, miyama: e, nabari: e, shima: e, suzuka: e, tado: e, taiki: e, taki: e, tamaki: e, toba: e, tsu: e, udono: e, ureshino: e, watarai: e, yokkaichi: e }], miyagi: [1, { furukawa: e, higashimatsushima: e, ishinomaki: e, iwanuma: e, kakuda: e, kami: e, kawasaki: e, marumori: e, matsushima: e, minamisanriku: e, misato: e, murata: e, natori: e, ogawara: e, ohira: e, onagawa: e, osaki: e, rifu: e, semine: e, shibata: e, shichikashuku: e, shikama: e, shiogama: e, shiroishi: e, tagajo: e, taiwa: e, tome: e, tomiya: e, wakuya: e, watari: e, yamamoto: e, zao: e }], miyazaki: [1, { aya: e, ebino: e, gokase: e, hyuga: e, kadogawa: e, kawaminami: e, kijo: e, kitagawa: e, kitakata: e, kitaura: e, kobayashi: e, kunitomi: e, kushima: e, mimata: e, miyakonojo: e, miyazaki: e, morotsuka: e, nichinan: e, nishimera: e, nobeoka: e, saito: e, shiiba: e, shintomi: e, takaharu: e, takanabe: e, takazaki: e, tsuno: e }], nagano: [1, { achi: e, agematsu: e, anan: e, aoki: e, asahi: e, azumino: e, chikuhoku: e, chikuma: e, chino: e, fujimi: e, hakuba: e, hara: e, hiraya: e, iida: e, iijima: e, iiyama: e, iizuna: e, ikeda: e, ikusaka: e, ina: e, karuizawa: e, kawakami: e, kiso: e, kisofukushima: e, kitaaiki: e, komagane: e, komoro: e, matsukawa: e, matsumoto: e, miasa: e, minamiaiki: e, minamimaki: e, minamiminowa: e, minowa: e, miyada: e, miyota: e, mochizuki: e, nagano: e, nagawa: e, nagiso: e, nakagawa: e, nakano: e, nozawaonsen: e, obuse: e, ogawa: e, okaya: e, omachi: e, omi: e, ookuwa: e, ooshika: e, otaki: e, otari: e, sakae: e, sakaki: e, saku: e, sakuho: e, shimosuwa: e, shinanomachi: e, shiojiri: e, suwa: e, suzaka: e, takagi: e, takamori: e, takayama: e, tateshina: e, tatsuno: e, togakushi: e, togura: e, tomi: e, ueda: e, wada: e, yamagata: e, yamanouchi: e, yasaka: e, yasuoka: e }], nagasaki: [1, { chijiwa: e, futsu: e, goto: e, hasami: e, hirado: e, iki: e, isahaya: e, kawatana: e, kuchinotsu: e, matsuura: e, nagasaki: e, obama: e, omura: e, oseto: e, saikai: e, sasebo: e, seihi: e, shimabara: e, shinkamigoto: e, togitsu: e, tsushima: e, unzen: e }], nara: [1, { ando: e, gose: e, heguri: e, higashiyoshino: e, ikaruga: e, ikoma: e, kamikitayama: e, kanmaki: e, kashiba: e, kashihara: e, katsuragi: e, kawai: e, kawakami: e, kawanishi: e, koryo: e, kurotaki: e, mitsue: e, miyake: e, nara: e, nosegawa: e, oji: e, ouda: e, oyodo: e, sakurai: e, sango: e, shimoichi: e, shimokitayama: e, shinjo: e, soni: e, takatori: e, tawaramoto: e, tenkawa: e, tenri: e, uda: e, yamatokoriyama: e, yamatotakada: e, yamazoe: e, yoshino: e }], niigata: [1, { aga: e, agano: e, gosen: e, itoigawa: e, izumozaki: e, joetsu: e, kamo: e, kariwa: e, kashiwazaki: e, minamiuonuma: e, mitsuke: e, muika: e, murakami: e, myoko: e, nagaoka: e, niigata: e, ojiya: e, omi: e, sado: e, sanjo: e, seiro: e, seirou: e, sekikawa: e, shibata: e, tagami: e, tainai: e, tochio: e, tokamachi: e, tsubame: e, tsunan: e, uonuma: e, yahiko: e, yoita: e, yuzawa: e }], oita: [1, { beppu: e, bungoono: e, bungotakada: e, hasama: e, hiji: e, himeshima: e, hita: e, kamitsue: e, kokonoe: e, kuju: e, kunisaki: e, kusu: e, oita: e, saiki: e, taketa: e, tsukumi: e, usa: e, usuki: e, yufu: e }], okayama: [1, { akaiwa: e, asakuchi: e, bizen: e, hayashima: e, ibara: e, kagamino: e, kasaoka: e, kibichuo: e, kumenan: e, kurashiki: e, maniwa: e, misaki: e, nagi: e, niimi: e, nishiawakura: e, okayama: e, satosho: e, setouchi: e, shinjo: e, shoo: e, soja: e, takahashi: e, tamano: e, tsuyama: e, wake: e, yakage: e }], okinawa: [1, { aguni: e, ginowan: e, ginoza: e, gushikami: e, haebaru: e, higashi: e, hirara: e, iheya: e, ishigaki: e, ishikawa: e, itoman: e, izena: e, kadena: e, kin: e, kitadaito: e, kitanakagusuku: e, kumejima: e, kunigami: e, minamidaito: e, motobu: e, nago: e, naha: e, nakagusuku: e, nakijin: e, nanjo: e, nishihara: e, ogimi: e, okinawa: e, onna: e, shimoji: e, taketomi: e, tarama: e, tokashiki: e, tomigusuku: e, tonaki: e, urasoe: e, uruma: e, yaese: e, yomitan: e, yonabaru: e, yonaguni: e, zamami: e }], osaka: [1, { abeno: e, chihayaakasaka: e, chuo: e, daito: e, fujiidera: e, habikino: e, hannan: e, higashiosaka: e, higashisumiyoshi: e, higashiyodogawa: e, hirakata: e, ibaraki: e, ikeda: e, izumi: e, izumiotsu: e, izumisano: e, kadoma: e, kaizuka: e, kanan: e, kashiwara: e, katano: e, kawachinagano: e, kishiwada: e, kita: e, kumatori: e, matsubara: e, minato: e, minoh: e, misaki: e, moriguchi: e, neyagawa: e, nishi: e, nose: e, osakasayama: e, sakai: e, sayama: e, sennan: e, settsu: e, shijonawate: e, shimamoto: e, suita: e, tadaoka: e, taishi: e, tajiri: e, takaishi: e, takatsuki: e, tondabayashi: e, toyonaka: e, toyono: e, yao: e }], saga: [1, { ariake: e, arita: e, fukudomi: e, genkai: e, hamatama: e, hizen: e, imari: e, kamimine: e, kanzaki: e, karatsu: e, kashima: e, kitagata: e, kitahata: e, kiyama: e, kouhoku: e, kyuragi: e, nishiarita: e, ogi: e, omachi: e, ouchi: e, saga: e, shiroishi: e, taku: e, tara: e, tosu: e, yoshinogari: e }], saitama: [1, { arakawa: e, asaka: e, chichibu: e, fujimi: e, fujimino: e, fukaya: e, hanno: e, hanyu: e, hasuda: e, hatogaya: e, hatoyama: e, hidaka: e, higashichichibu: e, higashimatsuyama: e, honjo: e, ina: e, iruma: e, iwatsuki: e, kamiizumi: e, kamikawa: e, kamisato: e, kasukabe: e, kawagoe: e, kawaguchi: e, kawajima: e, kazo: e, kitamoto: e, koshigaya: e, kounosu: e, kuki: e, kumagaya: e, matsubushi: e, minano: e, misato: e, miyashiro: e, miyoshi: e, moroyama: e, nagatoro: e, namegawa: e, niiza: e, ogano: e, ogawa: e, ogose: e, okegawa: e, omiya: e, otaki: e, ranzan: e, ryokami: e, saitama: e, sakado: e, satte: e, sayama: e, shiki: e, shiraoka: e, soka: e, sugito: e, toda: e, tokigawa: e, tokorozawa: e, tsurugashima: e, urawa: e, warabi: e, yashio: e, yokoze: e, yono: e, yorii: e, yoshida: e, yoshikawa: e, yoshimi: e }], shiga: [1, { aisho: e, gamo: e, higashiomi: e, hikone: e, koka: e, konan: e, kosei: e, koto: e, kusatsu: e, maibara: e, moriyama: e, nagahama: e, nishiazai: e, notogawa: e, omihachiman: e, otsu: e, ritto: e, ryuoh: e, takashima: e, takatsuki: e, torahime: e, toyosato: e, yasu: e }], shimane: [1, { akagi: e, ama: e, gotsu: e, hamada: e, higashiizumo: e, hikawa: e, hikimi: e, izumo: e, kakinoki: e, masuda: e, matsue: e, misato: e, nishinoshima: e, ohda: e, okinoshima: e, okuizumo: e, shimane: e, tamayu: e, tsuwano: e, unnan: e, yakumo: e, yasugi: e, yatsuka: e }], shizuoka: [1, { arai: e, atami: e, fuji: e, fujieda: e, fujikawa: e, fujinomiya: e, fukuroi: e, gotemba: e, haibara: e, hamamatsu: e, higashiizu: e, ito: e, iwata: e, izu: e, izunokuni: e, kakegawa: e, kannami: e, kawanehon: e, kawazu: e, kikugawa: e, kosai: e, makinohara: e, matsuzaki: e, minamiizu: e, mishima: e, morimachi: e, nishiizu: e, numazu: e, omaezaki: e, shimada: e, shimizu: e, shimoda: e, shizuoka: e, susono: e, yaizu: e, yoshida: e }], tochigi: [1, { ashikaga: e, bato: e, haga: e, ichikai: e, iwafune: e, kaminokawa: e, kanuma: e, karasuyama: e, kuroiso: e, mashiko: e, mibu: e, moka: e, motegi: e, nasu: e, nasushiobara: e, nikko: e, nishikata: e, nogi: e, ohira: e, ohtawara: e, oyama: e, sakura: e, sano: e, shimotsuke: e, shioya: e, takanezawa: e, tochigi: e, tsuga: e, ujiie: e, utsunomiya: e, yaita: e }], tokushima: [1, { aizumi: e, anan: e, ichiba: e, itano: e, kainan: e, komatsushima: e, matsushige: e, mima: e, minami: e, miyoshi: e, mugi: e, nakagawa: e, naruto: e, sanagochi: e, shishikui: e, tokushima: e, wajiki: e }], tokyo: [1, { adachi: e, akiruno: e, akishima: e, aogashima: e, arakawa: e, bunkyo: e, chiyoda: e, chofu: e, chuo: e, edogawa: e, fuchu: e, fussa: e, hachijo: e, hachioji: e, hamura: e, higashikurume: e, higashimurayama: e, higashiyamato: e, hino: e, hinode: e, hinohara: e, inagi: e, itabashi: e, katsushika: e, kita: e, kiyose: e, kodaira: e, koganei: e, kokubunji: e, komae: e, koto: e, kouzushima: e, kunitachi: e, machida: e, meguro: e, minato: e, mitaka: e, mizuho: e, musashimurayama: e, musashino: e, nakano: e, nerima: e, ogasawara: e, okutama: e, ome: e, oshima: e, ota: e, setagaya: e, shibuya: e, shinagawa: e, shinjuku: e, suginami: e, sumida: e, tachikawa: e, taito: e, tama: e, toshima: e }], tottori: [1, { chizu: e, hino: e, kawahara: e, koge: e, kotoura: e, misasa: e, nanbu: e, nichinan: e, sakaiminato: e, tottori: e, wakasa: e, yazu: e, yonago: e }], toyama: [1, { asahi: e, fuchu: e, fukumitsu: e, funahashi: e, himi: e, imizu: e, inami: e, johana: e, kamiichi: e, kurobe: e, nakaniikawa: e, namerikawa: e, nanto: e, nyuzen: e, oyabe: e, taira: e, takaoka: e, tateyama: e, toga: e, tonami: e, toyama: e, unazuki: e, uozu: e, yamada: e }], wakayama: [1, { arida: e, aridagawa: e, gobo: e, hashimoto: e, hidaka: e, hirogawa: e, inami: e, iwade: e, kainan: e, kamitonda: e, katsuragi: e, kimino: e, kinokawa: e, kitayama: e, koya: e, koza: e, kozagawa: e, kudoyama: e, kushimoto: e, mihama: e, misato: e, nachikatsuura: e, shingu: e, shirahama: e, taiji: e, tanabe: e, wakayama: e, yuasa: e, yura: e }], yamagata: [1, { asahi: e, funagata: e, higashine: e, iide: e, kahoku: e, kaminoyama: e, kaneyama: e, kawanishi: e, mamurogawa: e, mikawa: e, murayama: e, nagai: e, nakayama: e, nanyo: e, nishikawa: e, obanazawa: e, oe: e, oguni: e, ohkura: e, oishida: e, sagae: e, sakata: e, sakegawa: e, shinjo: e, shirataka: e, shonai: e, takahata: e, tendo: e, tozawa: e, tsuruoka: e, yamagata: e, yamanobe: e, yonezawa: e, yuza: e }], yamaguchi: [1, { abu: e, hagi: e, hikari: e, hofu: e, iwakuni: e, kudamatsu: e, mitou: e, nagato: e, oshima: e, shimonoseki: e, shunan: e, tabuse: e, tokuyama: e, toyota: e, ube: e, yuu: e }], yamanashi: [1, { chuo: e, doshi: e, fuefuki: e, fujikawa: e, fujikawaguchiko: e, fujiyoshida: e, hayakawa: e, hokuto: e, ichikawamisato: e, kai: e, kofu: e, koshu: e, kosuge: e, "minami-alps": e, minobu: e, nakamichi: e, nanbu: e, narusawa: e, nirasaki: e, nishikatsura: e, oshino: e, otsuki: e, showa: e, tabayama: e, tsuru: e, uenohara: e, yamanakako: e, yamanashi: e }], "xn--ehqz56n": e, 三重: e, "xn--1lqs03n": e, 京都: e, "xn--qqqt11m": e, 佐賀: e, "xn--f6qx53a": e, 兵庫: e, "xn--djrs72d6uy": e, 北海道: e, "xn--mkru45i": e, 千葉: e, "xn--0trq7p7nn": e, 和歌山: e, "xn--5js045d": e, 埼玉: e, "xn--kbrq7o": e, 大分: e, "xn--pssu33l": e, 大阪: e, "xn--ntsq17g": e, 奈良: e, "xn--uisz3g": e, 宮城: e, "xn--6btw5a": e, 宮崎: e, "xn--1ctwo": e, 富山: e, "xn--6orx2r": e, 山口: e, "xn--rht61e": e, 山形: e, "xn--rht27z": e, 山梨: e, "xn--nit225k": e, 岐阜: e, "xn--rht3d": e, 岡山: e, "xn--djty4k": e, 岩手: e, "xn--klty5x": e, 島根: e, "xn--kltx9a": e, 広島: e, "xn--kltp7d": e, 徳島: e, "xn--c3s14m": e, 愛媛: e, "xn--vgu402c": e, 愛知: e, "xn--efvn9s": e, 新潟: e, "xn--1lqs71d": e, 東京: e, "xn--4pvxs": e, 栃木: e, "xn--uuwu58a": e, 沖縄: e, "xn--zbx025d": e, 滋賀: e, "xn--8pvr4u": e, 熊本: e, "xn--5rtp49c": e, 石川: e, "xn--ntso0iqx3a": e, 神奈川: e, "xn--elqq16h": e, 福井: e, "xn--4it168d": e, 福岡: e, "xn--klt787d": e, 福島: e, "xn--rny31h": e, 秋田: e, "xn--7t0a264c": e, 群馬: e, "xn--uist22h": e, 茨城: e, "xn--8ltr62k": e, 長崎: e, "xn--2m4a15e": e, 長野: e, "xn--32vp30h": e, 青森: e, "xn--4it797k": e, 静岡: e, "xn--5rtq34k": e, 香川: e, "xn--k7yn95e": e, 高知: e, "xn--tor131o": e, 鳥取: e, "xn--d5qv7z876c": e, 鹿児島: e, kawasaki: m, kitakyushu: m, kobe: m, nagoya: m, sapporo: m, sendai: m, yokohama: m, buyshop: t, fashionstore: t, handcrafted: t, kawaiishop: t, supersale: t, theshop: t, "0am": t, "0g0": t, "0j0": t, "0t0": t, mydns: t, pgw: t, wjg: t, usercontent: t, angry: t, babyblue: t, babymilk: t, backdrop: t, bambina: t, bitter: t, blush: t, boo: t, boy: t, boyfriend: t, but: t, candypop: t, capoo: t, catfood: t, cheap: t, chicappa: t, chillout: t, chips: t, chowder: t, chu: t, ciao: t, cocotte: t, coolblog: t, cranky: t, cutegirl: t, daa: t, deca: t, deci: t, digick: t, egoism: t, fakefur: t, fem: t, flier: t, floppy: t, fool: t, frenchkiss: t, girlfriend: t, girly: t, gloomy: t, gonna: t, greater: t, hacca: t, heavy: t, her: t, hiho: t, hippy: t, holy: t, hungry: t, icurus: t, itigo: t, jellybean: t, kikirara: t, kill: t, kilo: t, kuron: t, littlestar: t, lolipopmc: t, lolitapunk: t, lomo: t, lovepop: t, lovesick: t, main: t, mods: t, mond: t, mongolian: t, moo: t, namaste: t, nikita: t, nobushi: t, noor: t, oops: t, parallel: t, parasite: t, pecori: t, peewee: t, penne: t, pepper: t, perma: t, pigboat: t, pinoko: t, punyu: t, pupu: t, pussycat: t, pya: t, raindrop: t, readymade: t, sadist: t, schoolbus: t, secret: t, staba: t, stripper: t, sub: t, sunnyday: t, thick: t, tonkotsu: t, under: t, upper: t, velvet: t, verse: t, versus: t, vivian: t, watson: t, weblike: t, whitesnow: t, zombie: t, hateblo: t, hatenablog: t, hatenadiary: t, "2-d": t, bona: t, crap: t, daynight: t, eek: t, flop: t, halfmoon: t, jeez: t, matrix: t, mimoza: t, netgamers: t, nyanta: t, o0o0: t, rdy: t, rgr: t, rulez: t, sakurastorage: [0, { isk01: Go, isk02: Go }], saloon: t, sblo: t, skr: t, tank: t, "uh-oh": t, undo: t, webaccel: [0, { rs: t, user: t }], websozai: t, xii: t }], ke: [1, { ac: e, co: e, go: e, info: e, me: e, mobi: e, ne: e, or: e, sc: e }], kg: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, us: t }], kh: m, ki: ma, km: [1, { ass: e, com: e, edu: e, gov: e, mil: e, nom: e, org: e, prd: e, tm: e, asso: e, coop: e, gouv: e, medecin: e, notaires: e, pharmaciens: e, presse: e, veterinaire: e }], kn: [1, { edu: e, gov: e, net: e, org: e }], kp: [1, { com: e, edu: e, gov: e, org: e, rep: e, tra: e }], kr: [1, { ac: e, ai: e, co: e, es: e, go: e, hs: e, io: e, it: e, kg: e, me: e, mil: e, ms: e, ne: e, or: e, pe: e, re: e, sc: e, busan: e, chungbuk: e, chungnam: e, daegu: e, daejeon: e, gangwon: e, gwangju: e, gyeongbuk: e, gyeonggi: e, gyeongnam: e, incheon: e, jeju: e, jeonbuk: e, jeonnam: e, seoul: e, ulsan: e, c01: t, "eliv-dns": t }], kw: [1, { com: e, edu: e, emb: e, gov: e, ind: e, net: e, org: e }], ky: Y, kz: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, jcloud: t }], la: [1, { com: e, edu: e, gov: e, info: e, int: e, net: e, org: e, per: e, bnr: t }], lb: n, lc: [1, { co: e, com: e, edu: e, gov: e, net: e, org: e, oy: t }], li: e, lk: [1, { ac: e, assn: e, com: e, edu: e, gov: e, grp: e, hotel: e, int: e, ltd: e, net: e, ngo: e, org: e, sch: e, soc: e, web: e }], lr: n, ls: [1, { ac: e, biz: e, co: e, edu: e, gov: e, info: e, net: e, org: e, sc: e }], lt: l, lu: [1, { "123website": t }], lv: [1, { asn: e, com: e, conf: e, edu: e, gov: e, id: e, mil: e, net: e, org: e }], ly: [1, { com: e, edu: e, gov: e, id: e, med: e, net: e, org: e, plc: e, sch: e }], ma: [1, { ac: e, co: e, gov: e, net: e, org: e, press: e }], mc: [1, { asso: e, tm: e }], md: [1, { ir: t }], me: [1, { ac: e, co: e, edu: e, gov: e, its: e, net: e, org: e, priv: e, c66: t, craft: t, edgestack: t, filegear: t, glitch: t, "filegear-sg": t, lohmus: t, barsy: t, mcdir: t, brasilia: t, ddns: t, dnsfor: t, hopto: t, loginto: t, noip: t, webhop: t, soundcast: t, tcp4: t, vp4: t, diskstation: t, dscloud: t, i234: t, myds: t, synology: t, transip: Oe, nohost: t }], mg: [1, { co: e, com: e, edu: e, gov: e, mil: e, nom: e, org: e, prd: e }], mh: e, mil: e, mk: [1, { com: e, edu: e, gov: e, inf: e, name: e, net: e, org: e }], ml: [1, { ac: e, art: e, asso: e, com: e, edu: e, gouv: e, gov: e, info: e, inst: e, net: e, org: e, pr: e, presse: e }], mm: m, mn: [1, { edu: e, gov: e, org: e, nyc: t }], mo: n, mobi: [1, { barsy: t, dscloud: t }], mp: [1, { ju: t }], mq: e, mr: l, ms: [1, { com: e, edu: e, gov: e, net: e, org: e, minisite: t }], mt: Y, mu: [1, { ac: e, co: e, com: e, gov: e, net: e, or: e, org: e }], museum: e, mv: [1, { aero: e, biz: e, com: e, coop: e, edu: e, gov: e, info: e, int: e, mil: e, museum: e, name: e, net: e, org: e, pro: e }], mw: [1, { ac: e, biz: e, co: e, com: e, coop: e, edu: e, gov: e, int: e, net: e, org: e }], mx: [1, { com: e, edu: e, gob: e, net: e, org: e }], my: [1, { biz: e, com: e, edu: e, gov: e, mil: e, name: e, net: e, org: e }], mz: [1, { ac: e, adv: e, co: e, edu: e, gov: e, mil: e, net: e, org: e }], na: [1, { alt: e, co: e, com: e, gov: e, net: e, org: e }], name: [1, { her: ya, his: ya }], nc: [1, { asso: e, nom: e }], ne: e, net: [1, { adobeaemcloud: t, "adobeio-static": t, adobeioruntime: t, akadns: t, akamai: t, "akamai-staging": t, akamaiedge: t, "akamaiedge-staging": t, akamaihd: t, "akamaihd-staging": t, akamaiorigin: t, "akamaiorigin-staging": t, akamaized: t, "akamaized-staging": t, edgekey: t, "edgekey-staging": t, edgesuite: t, "edgesuite-staging": t, alwaysdata: t, myamaze: t, cloudfront: t, appudo: t, "atlassian-dev": [0, { prod: $n }], myfritz: t, onavstack: t, shopselect: t, blackbaudcdn: t, boomla: t, bplaced: t, square7: t, cdn77: [0, { r: t }], "cdn77-ssl": t, gb: t, hu: t, jp: t, se: t, uk: t, clickrising: t, "ddns-ip": t, "dns-cloud": t, "dns-dynamic": t, cloudaccess: t, cloudflare: [2, { cdn: t }], cloudflareanycast: $n, cloudflarecn: $n, cloudflareglobal: $n, ctfcloud: t, "feste-ip": t, "knx-server": t, "static-access": t, cryptonomic: o, dattolocal: t, mydatto: t, debian: t, definima: t, deno: t, "at-band-camp": t, blogdns: t, "broke-it": t, buyshouses: t, dnsalias: t, dnsdojo: t, "does-it": t, dontexist: t, dynalias: t, dynathome: t, endofinternet: t, "from-az": t, "from-co": t, "from-la": t, "from-ny": t, "gets-it": t, "ham-radio-op": t, homeftp: t, homeip: t, homelinux: t, homeunix: t, "in-the-band": t, "is-a-chef": t, "is-a-geek": t, "isa-geek": t, "kicks-ass": t, "office-on-the": t, podzone: t, "scrapper-site": t, selfip: t, "sells-it": t, servebbs: t, serveftp: t, thruhere: t, webhop: t, casacam: t, dynu: t, dynv6: t, twmail: t, ru: t, channelsdvr: [2, { u: t }], fastly: [0, { freetls: t, map: t, prod: [0, { a: t, global: t }], ssl: [0, { a: t, b: t, global: t }] }], fastlylb: [2, { map: t }], edgeapp: t, "keyword-on": t, "live-on": t, "server-on": t, "cdn-edges": t, heteml: t, cloudfunctions: t, "grafana-dev": t, iobb: t, moonscale: t, "in-dsl": t, "in-vpn": t, oninferno: t, botdash: t, "apps-1and1": t, ipifony: t, cloudjiffy: [2, { "fra1-de": t, "west1-us": t }], elastx: [0, { "jls-sto1": t, "jls-sto2": t, "jls-sto3": t }], massivegrid: [0, { paas: [0, { "fr-1": t, "lon-1": t, "lon-2": t, "ny-1": t, "ny-2": t, "sg-1": t }] }], saveincloud: [0, { jelastic: t, "nordeste-idc": t }], scaleforce: G, kinghost: t, uni5: t, krellian: t, ggff: t, localcert: t, localhostcert: t, localto: o, barsy: t, memset: t, "azure-api": t, "azure-mobile": t, azureedge: t, azurefd: t, azurestaticapps: [2, { 1: t, 2: t, 3: t, 4: t, 5: t, 6: t, 7: t, centralus: t, eastasia: t, eastus2: t, westeurope: t, westus2: t }], azurewebsites: t, cloudapp: t, trafficmanager: t, windows: [0, { core: [0, { blob: t }], servicebus: t }], mynetname: [0, { sn: t }], routingthecloud: t, bounceme: t, ddns: t, "eating-organic": t, mydissent: t, myeffect: t, mymediapc: t, mypsx: t, mysecuritycamera: t, nhlfan: t, "no-ip": t, pgafan: t, privatizehealthinsurance: t, redirectme: t, serveblog: t, serveminecraft: t, sytes: t, dnsup: t, hicam: t, "now-dns": t, ownip: t, vpndns: t, cloudycluster: t, ovh: [0, { hosting: o, webpaas: o }], rackmaze: t, myradweb: t, in: t, "subsc-pay": t, squares: t, schokokeks: t, "firewall-gateway": t, seidat: t, senseering: t, siteleaf: t, mafelo: t, myspreadshop: t, "vps-host": [2, { jelastic: [0, { atl: t, njs: t, ric: t }] }], srcf: [0, { soc: t, user: t }], supabase: t, dsmynas: t, familyds: t, ts: [2, { c: o }], torproject: [2, { pages: t }], vusercontent: t, "reserve-online": t, "community-pro": t, meinforum: t, yandexcloud: [2, { storage: t, website: t }], za: t }], nf: [1, { arts: e, com: e, firm: e, info: e, net: e, other: e, per: e, rec: e, store: e, web: e }], ng: [1, { com: e, edu: e, gov: e, i: e, mil: e, mobi: e, name: e, net: e, org: e, sch: e, biz: [2, { co: t, dl: t, go: t, lg: t, on: t }], col: t, firm: t, gen: t, ltd: t, ngo: t, plc: t }], ni: [1, { ac: e, biz: e, co: e, com: e, edu: e, gob: e, in: e, info: e, int: e, mil: e, net: e, nom: e, org: e, web: e }], nl: [1, { co: t, "hosting-cluster": t, gov: t, khplay: t, "123website": t, myspreadshop: t, transurl: o, cistron: t, demon: t }], no: [1, { fhs: e, folkebibl: e, fylkesbibl: e, idrett: e, museum: e, priv: e, vgs: e, dep: e, herad: e, kommune: e, mil: e, stat: e, aa: se, ah: se, bu: se, fm: se, hl: se, hm: se, "jan-mayen": se, mr: se, nl: se, nt: se, of: se, ol: se, oslo: se, rl: se, sf: se, st: se, svalbard: se, tm: se, tr: se, va: se, vf: se, akrehamn: e, "xn--krehamn-dxa": e, åkrehamn: e, algard: e, "xn--lgrd-poac": e, ålgård: e, arna: e, bronnoysund: e, "xn--brnnysund-m8ac": e, brønnøysund: e, brumunddal: e, bryne: e, drobak: e, "xn--drbak-wua": e, drøbak: e, egersund: e, fetsund: e, floro: e, "xn--flor-jra": e, florø: e, fredrikstad: e, hokksund: e, honefoss: e, "xn--hnefoss-q1a": e, hønefoss: e, jessheim: e, jorpeland: e, "xn--jrpeland-54a": e, jørpeland: e, kirkenes: e, kopervik: e, krokstadelva: e, langevag: e, "xn--langevg-jxa": e, langevåg: e, leirvik: e, mjondalen: e, "xn--mjndalen-64a": e, mjøndalen: e, "mo-i-rana": e, mosjoen: e, "xn--mosjen-eya": e, mosjøen: e, nesoddtangen: e, orkanger: e, osoyro: e, "xn--osyro-wua": e, osøyro: e, raholt: e, "xn--rholt-mra": e, råholt: e, sandnessjoen: e, "xn--sandnessjen-ogb": e, sandnessjøen: e, skedsmokorset: e, slattum: e, spjelkavik: e, stathelle: e, stavern: e, stjordalshalsen: e, "xn--stjrdalshalsen-sqb": e, stjørdalshalsen: e, tananger: e, tranby: e, vossevangen: e, aarborte: e, aejrie: e, afjord: e, "xn--fjord-lra": e, åfjord: e, agdenes: e, akershus: va, aknoluokta: e, "xn--koluokta-7ya57h": e, ákŋoluokta: e, al: e, "xn--l-1fa": e, ål: e, alaheadju: e, "xn--laheadju-7ya": e, álaheadju: e, alesund: e, "xn--lesund-hua": e, ålesund: e, alstahaug: e, alta: e, "xn--lt-liac": e, áltá: e, alvdal: e, amli: e, "xn--mli-tla": e, åmli: e, amot: e, "xn--mot-tla": e, åmot: e, andasuolo: e, andebu: e, andoy: e, "xn--andy-ira": e, andøy: e, ardal: e, "xn--rdal-poa": e, årdal: e, aremark: e, arendal: e, "xn--s-1fa": e, ås: e, aseral: e, "xn--seral-lra": e, åseral: e, asker: e, askim: e, askoy: e, "xn--asky-ira": e, askøy: e, askvoll: e, asnes: e, "xn--snes-poa": e, åsnes: e, audnedaln: e, aukra: e, aure: e, aurland: e, "aurskog-holand": e, "xn--aurskog-hland-jnb": e, "aurskog-høland": e, austevoll: e, austrheim: e, averoy: e, "xn--avery-yua": e, averøy: e, badaddja: e, "xn--bdddj-mrabd": e, bådåddjå: e, "xn--brum-voa": e, bærum: e, bahcavuotna: e, "xn--bhcavuotna-s4a": e, báhcavuotna: e, bahccavuotna: e, "xn--bhccavuotna-k7a": e, báhccavuotna: e, baidar: e, "xn--bidr-5nac": e, báidár: e, bajddar: e, "xn--bjddar-pta": e, bájddar: e, balat: e, "xn--blt-elab": e, bálát: e, balestrand: e, ballangen: e, balsfjord: e, bamble: e, bardu: e, barum: e, batsfjord: e, "xn--btsfjord-9za": e, båtsfjord: e, bearalvahki: e, "xn--bearalvhki-y4a": e, bearalváhki: e, beardu: e, beiarn: e, berg: e, bergen: e, berlevag: e, "xn--berlevg-jxa": e, berlevåg: e, bievat: e, "xn--bievt-0qa": e, bievát: e, bindal: e, birkenes: e, bjarkoy: e, "xn--bjarky-fya": e, bjarkøy: e, bjerkreim: e, bjugn: e, bodo: e, "xn--bod-2na": e, bodø: e, bokn: e, bomlo: e, "xn--bmlo-gra": e, bømlo: e, bremanger: e, bronnoy: e, "xn--brnny-wuac": e, brønnøy: e, budejju: e, buskerud: va, bygland: e, bykle: e, cahcesuolo: e, "xn--hcesuolo-7ya35b": e, čáhcesuolo: e, davvenjarga: e, "xn--davvenjrga-y4a": e, davvenjárga: e, davvesiida: e, deatnu: e, dielddanuorri: e, divtasvuodna: e, divttasvuotna: e, donna: e, "xn--dnna-gra": e, dønna: e, dovre: e, drammen: e, drangedal: e, dyroy: e, "xn--dyry-ira": e, dyrøy: e, eid: e, eidfjord: e, eidsberg: e, eidskog: e, eidsvoll: e, eigersund: e, elverum: e, enebakk: e, engerdal: e, etne: e, etnedal: e, evenassi: e, "xn--eveni-0qa01ga": e, evenášši: e, evenes: e, "evje-og-hornnes": e, farsund: e, fauske: e, fedje: e, fet: e, finnoy: e, "xn--finny-yua": e, finnøy: e, fitjar: e, fjaler: e, fjell: e, fla: e, "xn--fl-zia": e, flå: e, flakstad: e, flatanger: e, flekkefjord: e, flesberg: e, flora: e, folldal: e, forde: e, "xn--frde-gra": e, førde: e, forsand: e, fosnes: e, "xn--frna-woa": e, fræna: e, frana: e, frei: e, frogn: e, froland: e, frosta: e, froya: e, "xn--frya-hra": e, frøya: e, fuoisku: e, fuossko: e, fusa: e, fyresdal: e, gaivuotna: e, "xn--givuotna-8ya": e, gáivuotna: e, galsa: e, "xn--gls-elac": e, gálsá: e, gamvik: e, gangaviika: e, "xn--ggaviika-8ya47h": e, gáŋgaviika: e, gaular: e, gausdal: e, giehtavuoatna: e, gildeskal: e, "xn--gildeskl-g0a": e, gildeskål: e, giske: e, gjemnes: e, gjerdrum: e, gjerstad: e, gjesdal: e, gjovik: e, "xn--gjvik-wua": e, gjøvik: e, gloppen: e, gol: e, gran: e, grane: e, granvin: e, gratangen: e, grimstad: e, grong: e, grue: e, gulen: e, guovdageaidnu: e, ha: e, "xn--h-2fa": e, hå: e, habmer: e, "xn--hbmer-xqa": e, hábmer: e, hadsel: e, "xn--hgebostad-g3a": e, hægebostad: e, hagebostad: e, halden: e, halsa: e, hamar: e, hamaroy: e, hammarfeasta: e, "xn--hmmrfeasta-s4ac": e, hámmárfeasta: e, hammerfest: e, hapmir: e, "xn--hpmir-xqa": e, hápmir: e, haram: e, hareid: e, harstad: e, hasvik: e, hattfjelldal: e, haugesund: e, hedmark: [0, { os: e, valer: e, "xn--vler-qoa": e, våler: e }], hemne: e, hemnes: e, hemsedal: e, hitra: e, hjartdal: e, hjelmeland: e, hobol: e, "xn--hobl-ira": e, hobøl: e, hof: e, hol: e, hole: e, holmestrand: e, holtalen: e, "xn--holtlen-hxa": e, holtålen: e, hordaland: [0, { os: e }], hornindal: e, horten: e, hoyanger: e, "xn--hyanger-q1a": e, høyanger: e, hoylandet: e, "xn--hylandet-54a": e, høylandet: e, hurdal: e, hurum: e, hvaler: e, hyllestad: e, ibestad: e, inderoy: e, "xn--indery-fya": e, inderøy: e, iveland: e, ivgu: e, jevnaker: e, jolster: e, "xn--jlster-bya": e, jølster: e, jondal: e, kafjord: e, "xn--kfjord-iua": e, kåfjord: e, karasjohka: e, "xn--krjohka-hwab49j": e, kárášjohka: e, karasjok: e, karlsoy: e, karmoy: e, "xn--karmy-yua": e, karmøy: e, kautokeino: e, klabu: e, "xn--klbu-woa": e, klæbu: e, klepp: e, kongsberg: e, kongsvinger: e, kraanghke: e, "xn--kranghke-b0a": e, kråanghke: e, kragero: e, "xn--krager-gya": e, kragerø: e, kristiansand: e, kristiansund: e, krodsherad: e, "xn--krdsherad-m8a": e, krødsherad: e, "xn--kvfjord-nxa": e, kvæfjord: e, "xn--kvnangen-k0a": e, kvænangen: e, kvafjord: e, kvalsund: e, kvam: e, kvanangen: e, kvinesdal: e, kvinnherad: e, kviteseid: e, kvitsoy: e, "xn--kvitsy-fya": e, kvitsøy: e, laakesvuemie: e, "xn--lrdal-sra": e, lærdal: e, lahppi: e, "xn--lhppi-xqa": e, láhppi: e, lardal: e, larvik: e, lavagis: e, lavangen: e, leangaviika: e, "xn--leagaviika-52b": e, leaŋgaviika: e, lebesby: e, leikanger: e, leirfjord: e, leka: e, leksvik: e, lenvik: e, lerdal: e, lesja: e, levanger: e, lier: e, lierne: e, lillehammer: e, lillesand: e, lindas: e, "xn--linds-pra": e, lindås: e, lindesnes: e, loabat: e, "xn--loabt-0qa": e, loabát: e, lodingen: e, "xn--ldingen-q1a": e, lødingen: e, lom: e, loppa: e, lorenskog: e, "xn--lrenskog-54a": e, lørenskog: e, loten: e, "xn--lten-gra": e, løten: e, lund: e, lunner: e, luroy: e, "xn--lury-ira": e, lurøy: e, luster: e, lyngdal: e, lyngen: e, malatvuopmi: e, "xn--mlatvuopmi-s4a": e, málatvuopmi: e, malselv: e, "xn--mlselv-iua": e, målselv: e, malvik: e, mandal: e, marker: e, marnardal: e, masfjorden: e, masoy: e, "xn--msy-ula0h": e, måsøy: e, "matta-varjjat": e, "xn--mtta-vrjjat-k7af": e, "mátta-várjjat": e, meland: e, meldal: e, melhus: e, meloy: e, "xn--mely-ira": e, meløy: e, meraker: e, "xn--merker-kua": e, meråker: e, midsund: e, "midtre-gauldal": e, moareke: e, "xn--moreke-jua": e, moåreke: e, modalen: e, modum: e, molde: e, "more-og-romsdal": [0, { heroy: e, sande: e }], "xn--mre-og-romsdal-qqb": [0, { "xn--hery-ira": e, sande: e }], "møre-og-romsdal": [0, { herøy: e, sande: e }], moskenes: e, moss: e, mosvik: e, muosat: e, "xn--muost-0qa": e, muosát: e, naamesjevuemie: e, "xn--nmesjevuemie-tcba": e, nååmesjevuemie: e, "xn--nry-yla5g": e, nærøy: e, namdalseid: e, namsos: e, namsskogan: e, nannestad: e, naroy: e, narviika: e, narvik: e, naustdal: e, navuotna: e, "xn--nvuotna-hwa": e, návuotna: e, "nedre-eiker": e, nesna: e, nesodden: e, nesseby: e, nesset: e, nissedal: e, nittedal: e, "nord-aurdal": e, "nord-fron": e, "nord-odal": e, norddal: e, nordkapp: e, nordland: [0, { bo: e, "xn--b-5ga": e, bø: e, heroy: e, "xn--hery-ira": e, herøy: e }], "nordre-land": e, nordreisa: e, "nore-og-uvdal": e, notodden: e, notteroy: e, "xn--nttery-byae": e, nøtterøy: e, odda: e, oksnes: e, "xn--ksnes-uua": e, øksnes: e, omasvuotna: e, oppdal: e, oppegard: e, "xn--oppegrd-ixa": e, oppegård: e, orkdal: e, orland: e, "xn--rland-uua": e, ørland: e, orskog: e, "xn--rskog-uua": e, ørskog: e, orsta: e, "xn--rsta-fra": e, ørsta: e, osen: e, osteroy: e, "xn--ostery-fya": e, osterøy: e, ostfold: [0, { valer: e }], "xn--stfold-9xa": [0, { "xn--vler-qoa": e }], østfold: [0, { våler: e }], "ostre-toten": e, "xn--stre-toten-zcb": e, "østre-toten": e, overhalla: e, "ovre-eiker": e, "xn--vre-eiker-k8a": e, "øvre-eiker": e, oyer: e, "xn--yer-zna": e, øyer: e, oygarden: e, "xn--ygarden-p1a": e, øygarden: e, "oystre-slidre": e, "xn--ystre-slidre-ujb": e, "øystre-slidre": e, porsanger: e, porsangu: e, "xn--porsgu-sta26f": e, porsáŋgu: e, porsgrunn: e, rade: e, "xn--rde-ula": e, råde: e, radoy: e, "xn--rady-ira": e, radøy: e, "xn--rlingen-mxa": e, rælingen: e, rahkkeravju: e, "xn--rhkkervju-01af": e, ráhkkerávju: e, raisa: e, "xn--risa-5na": e, ráisa: e, rakkestad: e, ralingen: e, rana: e, randaberg: e, rauma: e, rendalen: e, rennebu: e, rennesoy: e, "xn--rennesy-v1a": e, rennesøy: e, rindal: e, ringebu: e, ringerike: e, ringsaker: e, risor: e, "xn--risr-ira": e, risør: e, rissa: e, roan: e, rodoy: e, "xn--rdy-0nab": e, rødøy: e, rollag: e, romsa: e, romskog: e, "xn--rmskog-bya": e, rømskog: e, roros: e, "xn--rros-gra": e, røros: e, rost: e, "xn--rst-0na": e, røst: e, royken: e, "xn--ryken-vua": e, røyken: e, royrvik: e, "xn--ryrvik-bya": e, røyrvik: e, ruovat: e, rygge: e, salangen: e, salat: e, "xn--slat-5na": e, sálat: e, "xn--slt-elab": e, sálát: e, saltdal: e, samnanger: e, sandefjord: e, sandnes: e, sandoy: e, "xn--sandy-yua": e, sandøy: e, sarpsborg: e, sauda: e, sauherad: e, sel: e, selbu: e, selje: e, seljord: e, siellak: e, sigdal: e, siljan: e, sirdal: e, skanit: e, "xn--sknit-yqa": e, skánit: e, skanland: e, "xn--sknland-fxa": e, skånland: e, skaun: e, skedsmo: e, ski: e, skien: e, skierva: e, "xn--skierv-uta": e, skiervá: e, skiptvet: e, skjak: e, "xn--skjk-soa": e, skjåk: e, skjervoy: e, "xn--skjervy-v1a": e, skjervøy: e, skodje: e, smola: e, "xn--smla-hra": e, smøla: e, snaase: e, "xn--snase-nra": e, snåase: e, snasa: e, "xn--snsa-roa": e, snåsa: e, snillfjord: e, snoasa: e, sogndal: e, sogne: e, "xn--sgne-gra": e, søgne: e, sokndal: e, sola: e, solund: e, somna: e, "xn--smna-gra": e, sømna: e, "sondre-land": e, "xn--sndre-land-0cb": e, "søndre-land": e, songdalen: e, "sor-aurdal": e, "xn--sr-aurdal-l8a": e, "sør-aurdal": e, "sor-fron": e, "xn--sr-fron-q1a": e, "sør-fron": e, "sor-odal": e, "xn--sr-odal-q1a": e, "sør-odal": e, "sor-varanger": e, "xn--sr-varanger-ggb": e, "sør-varanger": e, sorfold: e, "xn--srfold-bya": e, sørfold: e, sorreisa: e, "xn--srreisa-q1a": e, sørreisa: e, sortland: e, sorum: e, "xn--srum-gra": e, sørum: e, spydeberg: e, stange: e, stavanger: e, steigen: e, steinkjer: e, stjordal: e, "xn--stjrdal-s1a": e, stjørdal: e, stokke: e, "stor-elvdal": e, stord: e, stordal: e, storfjord: e, strand: e, stranda: e, stryn: e, sula: e, suldal: e, sund: e, sunndal: e, surnadal: e, sveio: e, svelvik: e, sykkylven: e, tana: e, telemark: [0, { bo: e, "xn--b-5ga": e, bø: e }], time: e, tingvoll: e, tinn: e, tjeldsund: e, tjome: e, "xn--tjme-hra": e, tjøme: e, tokke: e, tolga: e, tonsberg: e, "xn--tnsberg-q1a": e, tønsberg: e, torsken: e, "xn--trna-woa": e, træna: e, trana: e, tranoy: e, "xn--trany-yua": e, tranøy: e, troandin: e, trogstad: e, "xn--trgstad-r1a": e, trøgstad: e, tromsa: e, tromso: e, "xn--troms-zua": e, tromsø: e, trondheim: e, trysil: e, tvedestrand: e, tydal: e, tynset: e, tysfjord: e, tysnes: e, "xn--tysvr-vra": e, tysvær: e, tysvar: e, ullensaker: e, ullensvang: e, ulvik: e, unjarga: e, "xn--unjrga-rta": e, unjárga: e, utsira: e, vaapste: e, vadso: e, "xn--vads-jra": e, vadsø: e, "xn--vry-yla5g": e, værøy: e, vaga: e, "xn--vg-yiab": e, vågå: e, vagan: e, "xn--vgan-qoa": e, vågan: e, vagsoy: e, "xn--vgsy-qoa0j": e, vågsøy: e, vaksdal: e, valle: e, vang: e, vanylven: e, vardo: e, "xn--vard-jra": e, vardø: e, varggat: e, "xn--vrggt-xqad": e, várggát: e, varoy: e, vefsn: e, vega: e, vegarshei: e, "xn--vegrshei-c0a": e, vegårshei: e, vennesla: e, verdal: e, verran: e, vestby: e, vestfold: [0, { sande: e }], vestnes: e, "vestre-slidre": e, "vestre-toten": e, vestvagoy: e, "xn--vestvgy-ixa6o": e, vestvågøy: e, vevelstad: e, vik: e, vikna: e, vindafjord: e, voagat: e, volda: e, voss: e, co: t, "123hjemmeside": t, myspreadshop: t }], np: m, nr: ma, nu: [1, { merseine: t, mine: t, shacknet: t, enterprisecloud: t }], nz: [1, { ac: e, co: e, cri: e, geek: e, gen: e, govt: e, health: e, iwi: e, kiwi: e, maori: e, "xn--mori-qsa": e, māori: e, mil: e, net: e, org: e, parliament: e, school: e, cloudns: t }], om: [1, { co: e, com: e, edu: e, gov: e, med: e, museum: e, net: e, org: e, pro: e }], onion: e, org: [1, { altervista: t, pimienta: t, poivron: t, potager: t, sweetpepper: t, cdn77: [0, { c: t, rsc: t }], "cdn77-secure": [0, { origin: [0, { ssl: t }] }], ae: t, cloudns: t, "ip-dynamic": t, ddnss: t, dpdns: t, duckdns: t, tunk: t, blogdns: t, blogsite: t, boldlygoingnowhere: t, dnsalias: t, dnsdojo: t, doesntexist: t, dontexist: t, doomdns: t, dvrdns: t, dynalias: t, dyndns: [2, { go: t, home: t }], endofinternet: t, endoftheinternet: t, "from-me": t, "game-host": t, gotdns: t, "hobby-site": t, homedns: t, homeftp: t, homelinux: t, homeunix: t, "is-a-bruinsfan": t, "is-a-candidate": t, "is-a-celticsfan": t, "is-a-chef": t, "is-a-geek": t, "is-a-knight": t, "is-a-linux-user": t, "is-a-patsfan": t, "is-a-soxfan": t, "is-found": t, "is-lost": t, "is-saved": t, "is-very-bad": t, "is-very-evil": t, "is-very-good": t, "is-very-nice": t, "is-very-sweet": t, "isa-geek": t, "kicks-ass": t, misconfused: t, podzone: t, readmyblog: t, selfip: t, sellsyourhome: t, servebbs: t, serveftp: t, servegame: t, "stuff-4-sale": t, webhop: t, accesscam: t, camdvr: t, freeddns: t, mywire: t, webredirect: t, twmail: t, eu: [2, { al: t, asso: t, at: t, au: t, be: t, bg: t, ca: t, cd: t, ch: t, cn: t, cy: t, cz: t, de: t, dk: t, edu: t, ee: t, es: t, fi: t, fr: t, gr: t, hr: t, hu: t, ie: t, il: t, in: t, int: t, is: t, it: t, jp: t, kr: t, lt: t, lu: t, lv: t, me: t, mk: t, mt: t, my: t, net: t, ng: t, nl: t, no: t, nz: t, pl: t, pt: t, ro: t, ru: t, se: t, si: t, sk: t, tr: t, uk: t, us: t }], fedorainfracloud: t, fedorapeople: t, fedoraproject: [0, { cloud: t, os: ge, stg: [0, { os: ge }] }], freedesktop: t, hatenadiary: t, hepforge: t, "in-dsl": t, "in-vpn": t, js: t, barsy: t, mayfirst: t, routingthecloud: t, bmoattachments: t, "cable-modem": t, collegefan: t, couchpotatofries: t, hopto: t, mlbfan: t, myftp: t, mysecuritycamera: t, nflfan: t, "no-ip": t, "read-books": t, ufcfan: t, zapto: t, dynserv: t, "now-dns": t, "is-local": t, httpbin: t, pubtls: t, jpn: t, "my-firewall": t, myfirewall: t, spdns: t, "small-web": t, dsmynas: t, familyds: t, teckids: Go, tuxfamily: t, diskstation: t, hk: t, us: t, toolforge: t, wmcloud: t, wmflabs: t, za: t }], pa: [1, { abo: e, ac: e, com: e, edu: e, gob: e, ing: e, med: e, net: e, nom: e, org: e, sld: e }], pe: [1, { com: e, edu: e, gob: e, mil: e, net: e, nom: e, org: e }], pf: [1, { com: e, edu: e, org: e }], pg: m, ph: [1, { com: e, edu: e, gov: e, i: e, mil: e, net: e, ngo: e, org: e, cloudns: t }], pk: [1, { ac: e, biz: e, com: e, edu: e, fam: e, gkp: e, gob: e, gog: e, gok: e, gop: e, gos: e, gov: e, net: e, org: e, web: e }], pl: [1, { com: e, net: e, org: e, agro: e, aid: e, atm: e, auto: e, biz: e, edu: e, gmina: e, gsm: e, info: e, mail: e, media: e, miasta: e, mil: e, nieruchomosci: e, nom: e, pc: e, powiat: e, priv: e, realestate: e, rel: e, sex: e, shop: e, sklep: e, sos: e, szkola: e, targi: e, tm: e, tourism: e, travel: e, turystyka: e, gov: [1, { ap: e, griw: e, ic: e, is: e, kmpsp: e, konsulat: e, kppsp: e, kwp: e, kwpsp: e, mup: e, mw: e, oia: e, oirm: e, oke: e, oow: e, oschr: e, oum: e, pa: e, pinb: e, piw: e, po: e, pr: e, psp: e, psse: e, pup: e, rzgw: e, sa: e, sdn: e, sko: e, so: e, sr: e, starostwo: e, ug: e, ugim: e, um: e, umig: e, upow: e, uppo: e, us: e, uw: e, uzs: e, wif: e, wiih: e, winb: e, wios: e, witd: e, wiw: e, wkz: e, wsa: e, wskr: e, wsse: e, wuoz: e, wzmiuw: e, zp: e, zpisdn: e }], augustow: e, "babia-gora": e, bedzin: e, beskidy: e, bialowieza: e, bialystok: e, bielawa: e, bieszczady: e, boleslawiec: e, bydgoszcz: e, bytom: e, cieszyn: e, czeladz: e, czest: e, dlugoleka: e, elblag: e, elk: e, glogow: e, gniezno: e, gorlice: e, grajewo: e, ilawa: e, jaworzno: e, "jelenia-gora": e, jgora: e, kalisz: e, karpacz: e, kartuzy: e, kaszuby: e, katowice: e, "kazimierz-dolny": e, kepno: e, ketrzyn: e, klodzko: e, kobierzyce: e, kolobrzeg: e, konin: e, konskowola: e, kutno: e, lapy: e, lebork: e, legnica: e, lezajsk: e, limanowa: e, lomza: e, lowicz: e, lubin: e, lukow: e, malbork: e, malopolska: e, mazowsze: e, mazury: e, mielec: e, mielno: e, mragowo: e, naklo: e, nowaruda: e, nysa: e, olawa: e, olecko: e, olkusz: e, olsztyn: e, opoczno: e, opole: e, ostroda: e, ostroleka: e, ostrowiec: e, ostrowwlkp: e, pila: e, pisz: e, podhale: e, podlasie: e, polkowice: e, pomorskie: e, pomorze: e, prochowice: e, pruszkow: e, przeworsk: e, pulawy: e, radom: e, "rawa-maz": e, rybnik: e, rzeszow: e, sanok: e, sejny: e, skoczow: e, slask: e, slupsk: e, sosnowiec: e, "stalowa-wola": e, starachowice: e, stargard: e, suwalki: e, swidnica: e, swiebodzin: e, swinoujscie: e, szczecin: e, szczytno: e, tarnobrzeg: e, tgory: e, turek: e, tychy: e, ustka: e, walbrzych: e, warmia: e, warszawa: e, waw: e, wegrow: e, wielun: e, wlocl: e, wloclawek: e, wodzislaw: e, wolomin: e, wroclaw: e, zachpomor: e, zagan: e, zarow: e, zgora: e, zgorzelec: e, art: t, gliwice: t, krakow: t, poznan: t, wroc: t, zakopane: t, beep: t, "ecommerce-shop": t, cfolks: t, dfirma: t, dkonto: t, you2: t, shoparena: t, homesklep: t, sdscloud: t, unicloud: t, lodz: t, pabianice: t, plock: t, sieradz: t, skierniewice: t, zgierz: t, krasnik: t, leczna: t, lubartow: t, lublin: t, poniatowa: t, swidnik: t, co: t, torun: t, simplesite: t, myspreadshop: t, gda: t, gdansk: t, gdynia: t, med: t, sopot: t, bielsko: t }], pm: [1, { own: t, name: t }], pn: [1, { co: e, edu: e, gov: e, net: e, org: e }], post: e, pr: [1, { biz: e, com: e, edu: e, gov: e, info: e, isla: e, name: e, net: e, org: e, pro: e, ac: e, est: e, prof: e }], pro: [1, { aaa: e, aca: e, acct: e, avocat: e, bar: e, cpa: e, eng: e, jur: e, law: e, med: e, recht: e, "12chars": t, cloudns: t, barsy: t, ngrok: t }], ps: [1, { com: e, edu: e, gov: e, net: e, org: e, plo: e, sec: e }], pt: [1, { com: e, edu: e, gov: e, int: e, net: e, nome: e, org: e, publ: e, "123paginaweb": t }], pw: [1, { gov: e, cloudns: t, x443: t }], py: [1, { com: e, coop: e, edu: e, gov: e, mil: e, net: e, org: e }], qa: [1, { com: e, edu: e, gov: e, mil: e, name: e, net: e, org: e, sch: e }], re: [1, { asso: e, com: e, netlib: t, can: t }], ro: [1, { arts: e, com: e, firm: e, info: e, nom: e, nt: e, org: e, rec: e, store: e, tm: e, www: e, co: t, shop: t, barsy: t }], rs: [1, { ac: e, co: e, edu: e, gov: e, in: e, org: e, brendly: pa, barsy: t, ox: t }], ru: [1, { ac: t, edu: t, gov: t, int: t, mil: t, eurodir: t, adygeya: t, bashkiria: t, bir: t, cbg: t, com: t, dagestan: t, grozny: t, kalmykia: t, kustanai: t, marine: t, mordovia: t, msk: t, mytis: t, nalchik: t, nov: t, pyatigorsk: t, spb: t, vladikavkaz: t, vladimir: t, na4u: t, mircloud: t, myjino: [2, { hosting: o, landing: o, spectrum: o, vps: o }], cldmail: [0, { hb: t }], mcdir: [2, { vps: t }], mcpre: t, net: t, org: t, pp: t, lk3: t, ras: t }], rw: [1, { ac: e, co: e, coop: e, gov: e, mil: e, net: e, org: e }], sa: [1, { com: e, edu: e, gov: e, med: e, net: e, org: e, pub: e, sch: e }], sb: n, sc: n, sd: [1, { com: e, edu: e, gov: e, info: e, med: e, net: e, org: e, tv: e }], se: [1, { a: e, ac: e, b: e, bd: e, brand: e, c: e, d: e, e, f: e, fh: e, fhsk: e, fhv: e, g: e, h: e, i: e, k: e, komforb: e, kommunalforbund: e, komvux: e, l: e, lanbib: e, m: e, n: e, naturbruksgymn: e, o: e, org: e, p: e, parti: e, pp: e, press: e, r: e, s: e, t: e, tm: e, u: e, w: e, x: e, y: e, z: e, com: t, iopsys: t, "123minsida": t, itcouldbewor: t, myspreadshop: t }], sg: [1, { com: e, edu: e, gov: e, net: e, org: e, enscaled: t }], sh: [1, { com: e, gov: e, mil: e, net: e, org: e, hashbang: t, botda: t, platform: [0, { ent: t, eu: t, us: t }], now: t }], si: [1, { f5: t, gitapp: t, gitpage: t }], sj: e, sk: e, sl: n, sm: e, sn: [1, { art: e, com: e, edu: e, gouv: e, org: e, perso: e, univ: e }], so: [1, { com: e, edu: e, gov: e, me: e, net: e, org: e, surveys: t }], sr: e, ss: [1, { biz: e, co: e, com: e, edu: e, gov: e, me: e, net: e, org: e, sch: e }], st: [1, { co: e, com: e, consulado: e, edu: e, embaixada: e, mil: e, net: e, org: e, principe: e, saotome: e, store: e, helioho: t, kirara: t, noho: t }], su: [1, { abkhazia: t, adygeya: t, aktyubinsk: t, arkhangelsk: t, armenia: t, ashgabad: t, azerbaijan: t, balashov: t, bashkiria: t, bryansk: t, bukhara: t, chimkent: t, dagestan: t, "east-kazakhstan": t, exnet: t, georgia: t, grozny: t, ivanovo: t, jambyl: t, kalmykia: t, kaluga: t, karacol: t, karaganda: t, karelia: t, khakassia: t, krasnodar: t, kurgan: t, kustanai: t, lenug: t, mangyshlak: t, mordovia: t, msk: t, murmansk: t, nalchik: t, navoi: t, "north-kazakhstan": t, nov: t, obninsk: t, penza: t, pokrovsk: t, sochi: t, spb: t, tashkent: t, termez: t, togliatti: t, troitsk: t, tselinograd: t, tula: t, tuva: t, vladikavkaz: t, vladimir: t, vologda: t }], sv: [1, { com: e, edu: e, gob: e, org: e, red: e }], sx: l, sy: r, sz: [1, { ac: e, co: e, org: e }], tc: e, td: e, tel: e, tf: [1, { sch: t }], tg: e, th: [1, { ac: e, co: e, go: e, in: e, mi: e, net: e, or: e, online: t, shop: t }], tj: [1, { ac: e, biz: e, co: e, com: e, edu: e, go: e, gov: e, int: e, mil: e, name: e, net: e, nic: e, org: e, test: e, web: e }], tk: e, tl: l, tm: [1, { co: e, com: e, edu: e, gov: e, mil: e, net: e, nom: e, org: e }], tn: [1, { com: e, ens: e, fin: e, gov: e, ind: e, info: e, intl: e, mincom: e, nat: e, net: e, org: e, perso: e, tourism: e, orangecloud: t }], to: [1, { 611: t, com: e, edu: e, gov: e, mil: e, net: e, org: e, oya: t, x0: t, quickconnect: _, vpnplus: t }], tr: [1, { av: e, bbs: e, bel: e, biz: e, com: e, dr: e, edu: e, gen: e, gov: e, info: e, k12: e, kep: e, mil: e, name: e, net: e, org: e, pol: e, tel: e, tsk: e, tv: e, web: e, nc: l }], tt: [1, { biz: e, co: e, com: e, edu: e, gov: e, info: e, mil: e, name: e, net: e, org: e, pro: e }], tv: [1, { "better-than": t, dyndns: t, "on-the-web": t, "worse-than": t, from: t, sakura: t }], tw: [1, { club: e, com: [1, { mymailer: t }], ebiz: e, edu: e, game: e, gov: e, idv: e, mil: e, net: e, org: e, url: t, mydns: t }], tz: [1, { ac: e, co: e, go: e, hotel: e, info: e, me: e, mil: e, mobi: e, ne: e, or: e, sc: e, tv: e }], ua: [1, { com: e, edu: e, gov: e, in: e, net: e, org: e, cherkassy: e, cherkasy: e, chernigov: e, chernihiv: e, chernivtsi: e, chernovtsy: e, ck: e, cn: e, cr: e, crimea: e, cv: e, dn: e, dnepropetrovsk: e, dnipropetrovsk: e, donetsk: e, dp: e, if: e, "ivano-frankivsk": e, kh: e, kharkiv: e, kharkov: e, kherson: e, khmelnitskiy: e, khmelnytskyi: e, kiev: e, kirovograd: e, km: e, kr: e, kropyvnytskyi: e, krym: e, ks: e, kv: e, kyiv: e, lg: e, lt: e, lugansk: e, luhansk: e, lutsk: e, lv: e, lviv: e, mk: e, mykolaiv: e, nikolaev: e, od: e, odesa: e, odessa: e, pl: e, poltava: e, rivne: e, rovno: e, rv: e, sb: e, sebastopol: e, sevastopol: e, sm: e, sumy: e, te: e, ternopil: e, uz: e, uzhgorod: e, uzhhorod: e, vinnica: e, vinnytsia: e, vn: e, volyn: e, yalta: e, zakarpattia: e, zaporizhzhe: e, zaporizhzhia: e, zhitomir: e, zhytomyr: e, zp: e, zt: e, cc: t, inf: t, ltd: t, cx: t, ie: t, biz: t, co: t, pp: t, v: t }], ug: [1, { ac: e, co: e, com: e, edu: e, go: e, gov: e, mil: e, ne: e, or: e, org: e, sc: e, us: e }], uk: [1, { ac: e, co: [1, { bytemark: [0, { dh: t, vm: t }], layershift: G, barsy: t, barsyonline: t, retrosnub: ga, "nh-serv": t, "no-ip": t, adimo: t, myspreadshop: t }], gov: [1, { api: t, campaign: t, service: t }], ltd: e, me: e, net: e, nhs: e, org: [1, { glug: t, lug: t, lugs: t, affinitylottery: t, raffleentry: t, weeklylottery: t }], plc: e, police: e, sch: m, conn: t, copro: t, hosp: t, "independent-commission": t, "independent-inquest": t, "independent-inquiry": t, "independent-panel": t, "independent-review": t, "public-inquiry": t, "royal-commission": t, pymnt: t, barsy: t, nimsite: t, oraclegovcloudapps: o }], us: [1, { dni: e, isa: e, nsn: e, ak: W, al: W, ar: W, as: W, az: W, ca: W, co: W, ct: W, dc: W, de: [1, { cc: e, lib: t }], fl: W, ga: W, gu: W, hi: xr, ia: W, id: W, il: W, in: W, ks: W, ky: W, la: W, ma: [1, { k12: [1, { chtr: e, paroch: e, pvt: e }], cc: e, lib: e }], md: W, me: W, mi: [1, { k12: e, cc: e, lib: e, "ann-arbor": e, cog: e, dst: e, eaton: e, gen: e, mus: e, tec: e, washtenaw: e }], mn: W, mo: W, ms: W, mt: W, nc: W, nd: xr, ne: W, nh: W, nj: W, nm: W, nv: W, ny: W, oh: W, ok: W, or: W, pa: W, pr: W, ri: xr, sc: W, sd: xr, tn: W, tx: W, ut: W, va: W, vi: W, vt: W, wa: W, wi: W, wv: [1, { cc: e }], wy: W, cloudns: t, "is-by": t, "land-4-sale": t, "stuff-4-sale": t, heliohost: t, enscaled: [0, { phx: t }], mircloud: t, ngo: t, golffan: t, noip: t, pointto: t, freeddns: t, srv: [2, { gh: t, gl: t }], platterp: t, servername: t }], uy: [1, { com: e, edu: e, gub: e, mil: e, net: e, org: e }], uz: [1, { co: e, com: e, net: e, org: e }], va: e, vc: [1, { com: e, edu: e, gov: e, mil: e, net: e, org: e, gv: [2, { d: t }], "0e": o, mydns: t }], ve: [1, { arts: e, bib: e, co: e, com: e, e12: e, edu: e, emprende: e, firm: e, gob: e, gov: e, info: e, int: e, mil: e, net: e, nom: e, org: e, rar: e, rec: e, store: e, tec: e, web: e }], vg: [1, { edu: e }], vi: [1, { co: e, com: e, k12: e, net: e, org: e }], vn: [1, { ac: e, ai: e, biz: e, com: e, edu: e, gov: e, health: e, id: e, info: e, int: e, io: e, name: e, net: e, org: e, pro: e, angiang: e, bacgiang: e, backan: e, baclieu: e, bacninh: e, "baria-vungtau": e, bentre: e, binhdinh: e, binhduong: e, binhphuoc: e, binhthuan: e, camau: e, cantho: e, caobang: e, daklak: e, daknong: e, danang: e, dienbien: e, dongnai: e, dongthap: e, gialai: e, hagiang: e, haiduong: e, haiphong: e, hanam: e, hanoi: e, hatinh: e, haugiang: e, hoabinh: e, hungyen: e, khanhhoa: e, kiengiang: e, kontum: e, laichau: e, lamdong: e, langson: e, laocai: e, longan: e, namdinh: e, nghean: e, ninhbinh: e, ninhthuan: e, phutho: e, phuyen: e, quangbinh: e, quangnam: e, quangngai: e, quangninh: e, quangtri: e, soctrang: e, sonla: e, tayninh: e, thaibinh: e, thainguyen: e, thanhhoa: e, thanhphohochiminh: e, thuathienhue: e, tiengiang: e, travinh: e, tuyenquang: e, vinhlong: e, vinhphuc: e, yenbai: e }], vu: Y, wf: [1, { biz: t, sch: t }], ws: [1, { com: e, edu: e, gov: e, net: e, org: e, advisor: o, cloud66: t, dyndns: t, mypets: t }], yt: [1, { org: t }], "xn--mgbaam7a8h": e, امارات: e, "xn--y9a3aq": e, հայ: e, "xn--54b7fta0cc": e, বাংলা: e, "xn--90ae": e, бг: e, "xn--mgbcpq6gpa1a": e, البحرين: e, "xn--90ais": e, бел: e, "xn--fiqs8s": e, 中国: e, "xn--fiqz9s": e, 中國: e, "xn--lgbbat1ad8j": e, الجزائر: e, "xn--wgbh1c": e, مصر: e, "xn--e1a4c": e, ею: e, "xn--qxa6a": e, ευ: e, "xn--mgbah1a3hjkrd": e, موريتانيا: e, "xn--node": e, გე: e, "xn--qxam": e, ελ: e, "xn--j6w193g": [1, { "xn--gmqw5a": e, "xn--55qx5d": e, "xn--mxtq1m": e, "xn--wcvs22d": e, "xn--uc0atv": e, "xn--od0alg": e }], 香港: [1, { 個人: e, 公司: e, 政府: e, 教育: e, 組織: e, 網絡: e }], "xn--2scrj9c": e, ಭಾರತ: e, "xn--3hcrj9c": e, ଭାରତ: e, "xn--45br5cyl": e, ভাৰত: e, "xn--h2breg3eve": e, भारतम्: e, "xn--h2brj9c8c": e, भारोत: e, "xn--mgbgu82a": e, ڀارت: e, "xn--rvc1e0am3e": e, ഭാരതം: e, "xn--h2brj9c": e, भारत: e, "xn--mgbbh1a": e, بارت: e, "xn--mgbbh1a71e": e, بھارت: e, "xn--fpcrj9c3d": e, భారత్: e, "xn--gecrj9c": e, ભારત: e, "xn--s9brj9c": e, ਭਾਰਤ: e, "xn--45brj9c": e, ভারত: e, "xn--xkc2dl3a5ee0h": e, இந்தியா: e, "xn--mgba3a4f16a": e, ایران: e, "xn--mgba3a4fra": e, ايران: e, "xn--mgbtx2b": e, عراق: e, "xn--mgbayh7gpa": e, الاردن: e, "xn--3e0b707e": e, 한국: e, "xn--80ao21a": e, қаз: e, "xn--q7ce6a": e, ລາວ: e, "xn--fzc2c9e2c": e, ලංකා: e, "xn--xkc2al3hye2a": e, இலங்கை: e, "xn--mgbc0a9azcg": e, المغرب: e, "xn--d1alf": e, мкд: e, "xn--l1acc": e, мон: e, "xn--mix891f": e, 澳門: e, "xn--mix082f": e, 澳门: e, "xn--mgbx4cd0ab": e, مليسيا: e, "xn--mgb9awbf": e, عمان: e, "xn--mgbai9azgqp6j": e, پاکستان: e, "xn--mgbai9a5eva00b": e, پاكستان: e, "xn--ygbi2ammx": e, فلسطين: e, "xn--90a3ac": [1, { "xn--80au": e, "xn--90azh": e, "xn--d1at": e, "xn--c1avg": e, "xn--o1ac": e, "xn--o1ach": e }], срб: [1, { ак: e, обр: e, од: e, орг: e, пр: e, упр: e }], "xn--p1ai": e, рф: e, "xn--wgbl6a": e, قطر: e, "xn--mgberp4a5d4ar": e, السعودية: e, "xn--mgberp4a5d4a87g": e, السعودیة: e, "xn--mgbqly7c0a67fbc": e, السعودیۃ: e, "xn--mgbqly7cvafr": e, السعوديه: e, "xn--mgbpl2fh": e, سودان: e, "xn--yfro4i67o": e, 新加坡: e, "xn--clchc0ea0b2g2a9gcd": e, சிங்கப்பூர்: e, "xn--ogbpf8fl": e, سورية: e, "xn--mgbtf8fl": e, سوريا: e, "xn--o3cw4h": [1, { "xn--o3cyx2a": e, "xn--12co0c3b4eva": e, "xn--m3ch0j3a": e, "xn--h3cuzk1di": e, "xn--12c1fe0br": e, "xn--12cfi8ixb8l": e }], ไทย: [1, { ทหาร: e, ธุรกิจ: e, เน็ต: e, รัฐบาล: e, ศึกษา: e, องค์กร: e }], "xn--pgbs0dh": e, تونس: e, "xn--kpry57d": e, 台灣: e, "xn--kprw13d": e, 台湾: e, "xn--nnx388a": e, 臺灣: e, "xn--j1amh": e, укр: e, "xn--mgb2ddes": e, اليمن: e, xxx: e, ye: r, za: [0, { ac: e, agric: e, alt: e, co: e, edu: e, gov: e, grondar: e, law: e, mil: e, net: e, ngo: e, nic: e, nis: e, nom: e, org: e, school: e, tm: e, web: e }], zm: [1, { ac: e, biz: e, co: e, com: e, edu: e, gov: e, info: e, mil: e, net: e, org: e, sch: e }], zw: [1, { ac: e, co: e, gov: e, mil: e, org: e }], aaa: e, aarp: e, abb: e, abbott: e, abbvie: e, abc: e, able: e, abogado: e, abudhabi: e, academy: [1, { official: t }], accenture: e, accountant: e, accountants: e, aco: e, actor: e, ads: e, adult: e, aeg: e, aetna: e, afl: e, africa: e, agakhan: e, agency: e, aig: e, airbus: e, airforce: e, airtel: e, akdn: e, alibaba: e, alipay: e, allfinanz: e, allstate: e, ally: e, alsace: e, alstom: e, amazon: e, americanexpress: e, americanfamily: e, amex: e, amfam: e, amica: e, amsterdam: e, analytics: e, android: e, anquan: e, anz: e, aol: e, apartments: e, app: [1, { adaptable: t, aiven: t, beget: o, brave: i, clerk: t, clerkstage: t, wnext: t, csb: [2, { preview: t }], convex: t, deta: t, ondigitalocean: t, easypanel: t, encr: t, evervault: s, expo: [2, { staging: t }], edgecompute: t, "on-fleek": t, flutterflow: t, e2b: t, framer: t, hosted: o, run: o, web: t, hasura: t, botdash: t, loginline: t, lovable: t, medusajs: t, messerli: t, netfy: t, netlify: t, ngrok: t, "ngrok-free": t, developer: o, noop: t, northflank: o, upsun: o, replit: a, nyat: t, snowflake: [0, { "*": t, privatelink: o }], streamlit: t, storipress: t, telebit: t, typedream: t, vercel: t, bookonline: t, wdh: t, windsurf: t, zeabur: t, zerops: o }], apple: e, aquarelle: e, arab: e, aramco: e, archi: e, army: e, art: e, arte: e, asda: e, associates: e, athleta: e, attorney: e, auction: e, audi: e, audible: e, audio: e, auspost: e, author: e, auto: e, autos: e, aws: [1, { sagemaker: [0, { "ap-northeast-1": h, "ap-northeast-2": h, "ap-south-1": h, "ap-southeast-1": h, "ap-southeast-2": h, "ca-central-1": p, "eu-central-1": h, "eu-west-1": h, "eu-west-2": h, "us-east-1": p, "us-east-2": p, "us-west-2": p, "af-south-1": d, "ap-east-1": d, "ap-northeast-3": d, "ap-south-2": f, "ap-southeast-3": d, "ap-southeast-4": f, "ca-west-1": [0, { notebook: t, "notebook-fips": t }], "eu-central-2": d, "eu-north-1": d, "eu-south-1": d, "eu-south-2": d, "eu-west-3": d, "il-central-1": d, "me-central-1": d, "me-south-1": d, "sa-east-1": d, "us-gov-east-1": g, "us-gov-west-1": g, "us-west-1": [0, { notebook: t, "notebook-fips": t, studio: t }], experiments: o }], repost: [0, { private: o }], on: [0, { "ap-northeast-1": u, "ap-southeast-1": u, "ap-southeast-2": u, "eu-central-1": u, "eu-north-1": u, "eu-west-1": u, "us-east-1": u, "us-east-2": u, "us-west-2": u }] }], axa: e, azure: e, baby: e, baidu: e, banamex: e, band: e, bank: e, bar: e, barcelona: e, barclaycard: e, barclays: e, barefoot: e, bargains: e, baseball: e, basketball: [1, { aus: t, nz: t }], bauhaus: e, bayern: e, bbc: e, bbt: e, bbva: e, bcg: e, bcn: e, beats: e, beauty: e, beer: e, bentley: e, berlin: e, best: e, bestbuy: e, bet: e, bharti: e, bible: e, bid: e, bike: e, bing: e, bingo: e, bio: e, black: e, blackfriday: e, blockbuster: e, blog: e, bloomberg: e, blue: e, bms: e, bmw: e, bnpparibas: e, boats: e, boehringer: e, bofa: e, bom: e, bond: e, boo: e, book: e, booking: e, bosch: e, bostik: e, boston: e, bot: e, boutique: e, box: e, bradesco: e, bridgestone: e, broadway: e, broker: e, brother: e, brussels: e, build: [1, { v0: t, windsurf: t }], builders: [1, { cloudsite: t }], business: y, buy: e, buzz: e, bzh: e, cab: e, cafe: e, cal: e, call: e, calvinklein: e, cam: e, camera: e, camp: [1, { emf: [0, { at: t }] }], canon: e, capetown: e, capital: e, capitalone: e, car: e, caravan: e, cards: e, care: e, career: e, careers: e, cars: e, casa: [1, { nabu: [0, { ui: t }] }], case: e, cash: e, casino: e, catering: e, catholic: e, cba: e, cbn: e, cbre: e, center: e, ceo: e, cern: e, cfa: e, cfd: e, chanel: e, channel: e, charity: e, chase: e, chat: e, cheap: e, chintai: e, christmas: e, chrome: e, church: e, cipriani: e, circle: e, cisco: e, citadel: e, citi: e, citic: e, city: e, claims: e, cleaning: e, click: e, clinic: e, clinique: e, clothing: e, cloud: [1, { convex: t, elementor: t, encoway: [0, { eu: t }], statics: o, ravendb: t, axarnet: [0, { "es-1": t }], diadem: t, jelastic: [0, { vip: t }], jele: t, "jenv-aruba": [0, { aruba: [0, { eur: [0, { it1: t }] }], it1: t }], keliweb: [2, { cs: t }], oxa: [2, { tn: t, uk: t }], primetel: [2, { uk: t }], reclaim: [0, { ca: t, uk: t, us: t }], trendhosting: [0, { ch: t, de: t }], jotelulu: t, kuleuven: t, laravel: t, linkyard: t, magentosite: o, matlab: t, observablehq: t, perspecta: t, vapor: t, "on-rancher": o, scw: [0, { baremetal: [0, { "fr-par-1": t, "fr-par-2": t, "nl-ams-1": t }], "fr-par": [0, { cockpit: t, fnc: [2, { functions: t }], k8s: k, s3: t, "s3-website": t, whm: t }], instances: [0, { priv: t, pub: t }], k8s: t, "nl-ams": [0, { cockpit: t, k8s: k, s3: t, "s3-website": t, whm: t }], "pl-waw": [0, { cockpit: t, k8s: k, s3: t, "s3-website": t }], scalebook: t, smartlabeling: t }], servebolt: t, onstackit: [0, { runs: t }], trafficplex: t, "unison-services": t, urown: t, voorloper: t, zap: t }], club: [1, { cloudns: t, jele: t, barsy: t }], clubmed: e, coach: e, codes: [1, { owo: o }], coffee: e, college: e, cologne: e, commbank: e, community: [1, { nog: t, ravendb: t, myforum: t }], company: e, compare: e, computer: e, comsec: e, condos: e, construction: e, consulting: e, contact: e, contractors: e, cooking: e, cool: [1, { elementor: t, de: t }], corsica: e, country: e, coupon: e, coupons: e, courses: e, cpa: e, credit: e, creditcard: e, creditunion: e, cricket: e, crown: e, crs: e, cruise: e, cruises: e, cuisinella: e, cymru: e, cyou: e, dad: e, dance: e, data: e, date: e, dating: e, datsun: e, day: e, dclk: e, dds: e, deal: e, dealer: e, deals: e, degree: e, delivery: e, dell: e, deloitte: e, delta: e, democrat: e, dental: e, dentist: e, desi: e, design: [1, { graphic: t, bss: t }], dev: [1, { "12chars": t, myaddr: t, panel: t, lcl: o, lclstage: o, stg: o, stgstage: o, pages: t, r2: t, workers: t, deno: t, "deno-staging": t, deta: t, evervault: s, fly: t, githubpreview: t, gateway: o, hrsn: [2, { psl: [0, { sub: t, wc: [0, { "*": t, sub: o }] }] }], botdash: t, inbrowser: o, "is-a-good": t, "is-a": t, iserv: t, runcontainers: t, localcert: [0, { user: o }], loginline: t, barsy: t, mediatech: t, modx: t, ngrok: t, "ngrok-free": t, "is-a-fullstack": t, "is-cool": t, "is-not-a": t, localplayer: t, xmit: t, "platter-app": t, replit: [2, { archer: t, bones: t, canary: t, global: t, hacker: t, id: t, janeway: t, kim: t, kira: t, kirk: t, odo: t, paris: t, picard: t, pike: t, prerelease: t, reed: t, riker: t, sisko: t, spock: t, staging: t, sulu: t, tarpit: t, teams: t, tucker: t, wesley: t, worf: t }], crm: [0, { d: o, w: o, wa: o, wb: o, wc: o, wd: o, we: o, wf: o }], vercel: t, webhare: o }], dhl: e, diamonds: e, diet: e, digital: [1, { cloudapps: [2, { london: t }] }], direct: [1, { libp2p: t }], directory: e, discount: e, discover: e, dish: e, diy: e, dnp: e, docs: e, doctor: e, dog: e, domains: e, dot: e, download: e, drive: e, dtv: e, dubai: e, dunlop: e, dupont: e, durban: e, dvag: e, dvr: e, earth: e, eat: e, eco: e, edeka: e, education: y, email: [1, { crisp: [0, { on: t }], tawk: We, tawkto: We }], emerck: e, energy: e, engineer: e, engineering: e, enterprises: e, epson: e, equipment: e, ericsson: e, erni: e, esq: e, estate: [1, { compute: o }], eurovision: e, eus: [1, { party: ha }], events: [1, { koobin: t, co: t }], exchange: e, expert: e, exposed: e, express: e, extraspace: e, fage: e, fail: e, fairwinds: e, faith: e, family: e, fan: e, fans: e, farm: [1, { storj: t }], farmers: e, fashion: e, fast: e, fedex: e, feedback: e, ferrari: e, ferrero: e, fidelity: e, fido: e, film: e, final: e, finance: e, financial: y, fire: e, firestone: e, firmdale: e, fish: e, fishing: e, fit: e, fitness: e, flickr: e, flights: e, flir: e, florist: e, flowers: e, fly: e, foo: e, food: e, football: e, ford: e, forex: e, forsale: e, forum: e, foundation: e, fox: e, free: e, fresenius: e, frl: e, frogans: e, frontier: e, ftr: e, fujitsu: e, fun: e, fund: e, furniture: e, futbol: e, fyi: e, gal: e, gallery: e, gallo: e, gallup: e, game: e, games: [1, { pley: t, sheezy: t }], gap: e, garden: e, gay: [1, { pages: t }], gbiz: e, gdn: [1, { cnpy: t }], gea: e, gent: e, genting: e, george: e, ggee: e, gift: e, gifts: e, gives: e, giving: e, glass: e, gle: e, global: [1, { appwrite: t }], globo: e, gmail: e, gmbh: e, gmo: e, gmx: e, godaddy: e, gold: e, goldpoint: e, golf: e, goo: e, goodyear: e, goog: [1, { cloud: t, translate: t, usercontent: o }], google: e, gop: e, got: e, grainger: e, graphics: e, gratis: e, green: e, gripe: e, grocery: e, group: [1, { discourse: t }], gucci: e, guge: e, guide: e, guitars: e, guru: e, hair: e, hamburg: e, hangout: e, haus: e, hbo: e, hdfc: e, hdfcbank: e, health: [1, { hra: t }], healthcare: e, help: e, helsinki: e, here: e, hermes: e, hiphop: e, hisamitsu: e, hitachi: e, hiv: e, hkt: e, hockey: e, holdings: e, holiday: e, homedepot: e, homegoods: e, homes: e, homesense: e, honda: e, horse: e, hospital: e, host: [1, { cloudaccess: t, freesite: t, easypanel: t, fastvps: t, myfast: t, tempurl: t, wpmudev: t, jele: t, mircloud: t, wp2: t, half: t }], hosting: [1, { opencraft: t }], hot: e, hotels: e, hotmail: e, house: e, how: e, hsbc: e, hughes: e, hyatt: e, hyundai: e, ibm: e, icbc: e, ice: e, icu: e, ieee: e, ifm: e, ikano: e, imamat: e, imdb: e, immo: e, immobilien: e, inc: e, industries: e, infiniti: e, ing: e, ink: e, institute: e, insurance: e, insure: e, international: e, intuit: e, investments: e, ipiranga: e, irish: e, ismaili: e, ist: e, istanbul: e, itau: e, itv: e, jaguar: e, java: e, jcb: e, jeep: e, jetzt: e, jewelry: e, jio: e, jll: e, jmp: e, jnj: e, joburg: e, jot: e, joy: e, jpmorgan: e, jprs: e, juegos: e, juniper: e, kaufen: e, kddi: e, kerryhotels: e, kerryproperties: e, kfh: e, kia: e, kids: e, kim: e, kindle: e, kitchen: e, kiwi: e, koeln: e, komatsu: e, kosher: e, kpmg: e, kpn: e, krd: [1, { co: t, edu: t }], kred: e, kuokgroup: e, kyoto: e, lacaixa: e, lamborghini: e, lamer: e, lancaster: e, land: e, landrover: e, lanxess: e, lasalle: e, lat: e, latino: e, latrobe: e, law: e, lawyer: e, lds: e, lease: e, leclerc: e, lefrak: e, legal: e, lego: e, lexus: e, lgbt: e, lidl: e, life: e, lifeinsurance: e, lifestyle: e, lighting: e, like: e, lilly: e, limited: e, limo: e, lincoln: e, link: [1, { myfritz: t, cyon: t, dweb: o, inbrowser: o, nftstorage: Xo, mypep: t, storacha: Xo, w3s: Xo }], live: [1, { aem: t, hlx: t, ewp: o }], living: e, llc: e, llp: e, loan: e, loans: e, locker: e, locus: e, lol: [1, { omg: t }], london: e, lotte: e, lotto: e, love: e, lpl: e, lplfinancial: e, ltd: e, ltda: e, lundbeck: e, luxe: e, luxury: e, madrid: e, maif: e, maison: e, makeup: e, man: e, management: e, mango: e, map: e, market: e, marketing: e, markets: e, marriott: e, marshalls: e, mattel: e, mba: e, mckinsey: e, med: e, media: br, meet: e, melbourne: e, meme: e, memorial: e, men: e, menu: [1, { barsy: t, barsyonline: t }], merck: e, merckmsd: e, miami: e, microsoft: e, mini: e, mint: e, mit: e, mitsubishi: e, mlb: e, mls: e, mma: e, mobile: e, moda: e, moe: e, moi: e, mom: [1, { ind: t }], monash: e, money: e, monster: e, mormon: e, mortgage: e, moscow: e, moto: e, motorcycles: e, mov: e, movie: e, msd: e, mtn: e, mtr: e, music: e, nab: e, nagoya: e, navy: e, nba: e, nec: e, netbank: e, netflix: e, network: [1, { alces: o, co: t, arvo: t, azimuth: t, tlon: t }], neustar: e, new: e, news: [1, { noticeable: t }], next: e, nextdirect: e, nexus: e, nfl: e, ngo: e, nhk: e, nico: e, nike: e, nikon: e, ninja: e, nissan: e, nissay: e, nokia: e, norton: e, now: e, nowruz: e, nowtv: e, nra: e, nrw: e, ntt: e, nyc: e, obi: e, observer: e, office: e, okinawa: e, olayan: e, olayangroup: e, ollo: e, omega: e, one: [1, { kin: o, service: t }], ong: [1, { obl: t }], onl: e, online: [1, { eero: t, "eero-stage": t, websitebuilder: t, barsy: t }], ooo: e, open: e, oracle: e, orange: [1, { tech: t }], organic: e, origins: e, osaka: e, otsuka: e, ott: e, ovh: [1, { nerdpol: t }], page: [1, { aem: t, hlx: t, hlx3: t, translated: t, codeberg: t, heyflow: t, prvcy: t, rocky: t, pdns: t, plesk: t }], panasonic: e, paris: e, pars: e, partners: e, parts: e, party: e, pay: e, pccw: e, pet: e, pfizer: e, pharmacy: e, phd: e, philips: e, phone: e, photo: e, photography: e, photos: br, physio: e, pics: e, pictet: e, pictures: [1, { 1337: t }], pid: e, pin: e, ping: e, pink: e, pioneer: e, pizza: [1, { ngrok: t }], place: y, play: e, playstation: e, plumbing: e, plus: e, pnc: e, pohl: e, poker: e, politie: e, porn: e, pramerica: e, praxi: e, press: e, prime: e, prod: e, productions: e, prof: e, progressive: e, promo: e, properties: e, property: e, protection: e, pru: e, prudential: e, pub: [1, { id: o, kin: o, barsy: t }], pwc: e, qpon: e, quebec: e, quest: e, racing: e, radio: e, read: e, realestate: e, realtor: e, realty: e, recipes: e, red: e, redstone: e, redumbrella: e, rehab: e, reise: e, reisen: e, reit: e, reliance: e, ren: e, rent: e, rentals: e, repair: e, report: e, republican: e, rest: e, restaurant: e, review: e, reviews: e, rexroth: e, rich: e, richardli: e, ricoh: e, ril: e, rio: e, rip: [1, { clan: t }], rocks: [1, { myddns: t, stackit: t, "lima-city": t, webspace: t }], rodeo: e, rogers: e, room: e, rsvp: e, rugby: e, ruhr: e, run: [1, { appwrite: o, development: t, ravendb: t, liara: [2, { iran: t }], servers: t, build: o, code: o, database: o, migration: o, onporter: t, repl: t, stackit: t, val: [0, { express: t, web: t }], wix: t }], rwe: e, ryukyu: e, saarland: e, safe: e, safety: e, sakura: e, sale: e, salon: e, samsclub: e, samsung: e, sandvik: e, sandvikcoromant: e, sanofi: e, sap: e, sarl: e, sas: e, save: e, saxo: e, sbi: e, sbs: e, scb: e, schaeffler: e, schmidt: e, scholarships: e, school: e, schule: e, schwarz: e, science: e, scot: [1, { gov: [2, { service: t }] }], search: e, seat: e, secure: e, security: e, seek: e, select: e, sener: e, services: [1, { loginline: t }], seven: e, sew: e, sex: e, sexy: e, sfr: e, shangrila: e, sharp: e, shell: e, shia: e, shiksha: e, shoes: e, shop: [1, { base: t, hoplix: t, barsy: t, barsyonline: t, shopware: t }], shopping: e, shouji: e, show: e, silk: e, sina: e, singles: e, site: [1, { square: t, canva: v, cloudera: o, convex: t, cyon: t, fastvps: t, figma: t, heyflow: t, jele: t, jouwweb: t, loginline: t, barsy: t, notion: t, omniwe: t, opensocial: t, madethis: t, platformsh: o, tst: o, byen: t, srht: t, novecore: t, cpanel: t, wpsquared: t }], ski: e, skin: e, sky: e, skype: e, sling: e, smart: e, smile: e, sncf: e, soccer: e, social: e, softbank: e, software: e, sohu: e, solar: e, solutions: e, song: e, sony: e, soy: e, spa: e, space: [1, { myfast: t, heiyu: t, hf: [2, { static: t }], "app-ionos": t, project: t, uber: t, xs4all: t }], sport: e, spot: e, srl: e, stada: e, staples: e, star: e, statebank: e, statefarm: e, stc: e, stcgroup: e, stockholm: e, storage: e, store: [1, { barsy: t, sellfy: t, shopware: t, storebase: t }], stream: e, studio: e, study: e, style: e, sucks: e, supplies: e, supply: e, support: [1, { barsy: t }], surf: e, surgery: e, suzuki: e, swatch: e, swiss: e, sydney: e, systems: [1, { knightpoint: t }], tab: e, taipei: e, talk: e, taobao: e, target: e, tatamotors: e, tatar: e, tattoo: e, tax: e, taxi: e, tci: e, tdk: e, team: [1, { discourse: t, jelastic: t }], tech: [1, { cleverapps: t }], technology: y, temasek: e, tennis: e, teva: e, thd: e, theater: e, theatre: e, tiaa: e, tickets: e, tienda: e, tips: e, tires: e, tirol: e, tjmaxx: e, tjx: e, tkmaxx: e, tmall: e, today: [1, { prequalifyme: t }], tokyo: e, tools: [1, { addr: ee, myaddr: t }], top: [1, { ntdll: t, wadl: o }], toray: e, toshiba: e, total: e, tours: e, town: e, toyota: e, toys: e, trade: e, trading: e, training: e, travel: e, travelers: e, travelersinsurance: e, trust: e, trv: e, tube: e, tui: e, tunes: e, tushu: e, tvs: e, ubank: e, ubs: e, unicom: e, university: e, uno: e, uol: e, ups: e, vacations: e, vana: e, vanguard: e, vegas: e, ventures: e, verisign: e, versicherung: e, vet: e, viajes: e, video: e, vig: e, viking: e, villas: e, vin: e, vip: e, virgin: e, visa: e, vision: e, viva: e, vivo: e, vlaanderen: e, vodka: e, volvo: e, vote: e, voting: e, voto: e, voyage: e, wales: e, walmart: e, walter: e, wang: e, wanggou: e, watch: e, watches: e, weather: e, weatherchannel: e, webcam: e, weber: e, website: br, wed: e, wedding: e, weibo: e, weir: e, whoswho: e, wien: e, wiki: br, williamhill: e, win: e, windows: e, wine: e, winners: e, wme: e, wolterskluwer: e, woodside: e, work: e, works: e, world: e, wow: e, wtc: e, wtf: e, xbox: e, xerox: e, xihuan: e, xin: e, "xn--11b4c3d": e, कॉम: e, "xn--1ck2e1b": e, セール: e, "xn--1qqw23a": e, 佛山: e, "xn--30rr7y": e, 慈善: e, "xn--3bst00m": e, 集团: e, "xn--3ds443g": e, 在线: e, "xn--3pxu8k": e, 点看: e, "xn--42c2d9a": e, คอม: e, "xn--45q11c": e, 八卦: e, "xn--4gbrim": e, موقع: e, "xn--55qw42g": e, 公益: e, "xn--55qx5d": e, 公司: e, "xn--5su34j936bgsg": e, 香格里拉: e, "xn--5tzm5g": e, 网站: e, "xn--6frz82g": e, 移动: e, "xn--6qq986b3xl": e, 我爱你: e, "xn--80adxhks": e, москва: e, "xn--80aqecdr1a": e, католик: e, "xn--80asehdb": e, онлайн: e, "xn--80aswg": e, сайт: e, "xn--8y0a063a": e, 联通: e, "xn--9dbq2a": e, קום: e, "xn--9et52u": e, 时尚: e, "xn--9krt00a": e, 微博: e, "xn--b4w605ferd": e, 淡马锡: e, "xn--bck1b9a5dre4c": e, ファッション: e, "xn--c1avg": e, орг: e, "xn--c2br7g": e, नेट: e, "xn--cck2b3b": e, ストア: e, "xn--cckwcxetd": e, アマゾン: e, "xn--cg4bki": e, 삼성: e, "xn--czr694b": e, 商标: e, "xn--czrs0t": e, 商店: e, "xn--czru2d": e, 商城: e, "xn--d1acj3b": e, дети: e, "xn--eckvdtc9d": e, ポイント: e, "xn--efvy88h": e, 新闻: e, "xn--fct429k": e, 家電: e, "xn--fhbei": e, كوم: e, "xn--fiq228c5hs": e, 中文网: e, "xn--fiq64b": e, 中信: e, "xn--fjq720a": e, 娱乐: e, "xn--flw351e": e, 谷歌: e, "xn--fzys8d69uvgm": e, 電訊盈科: e, "xn--g2xx48c": e, 购物: e, "xn--gckr3f0f": e, クラウド: e, "xn--gk3at1e": e, 通販: e, "xn--hxt814e": e, 网店: e, "xn--i1b6b1a6a2e": e, संगठन: e, "xn--imr513n": e, 餐厅: e, "xn--io0a7i": e, 网络: e, "xn--j1aef": e, ком: e, "xn--jlq480n2rg": e, 亚马逊: e, "xn--jvr189m": e, 食品: e, "xn--kcrx77d1x4a": e, 飞利浦: e, "xn--kput3i": e, 手机: e, "xn--mgba3a3ejt": e, ارامكو: e, "xn--mgba7c0bbn0a": e, العليان: e, "xn--mgbab2bd": e, بازار: e, "xn--mgbca7dzdo": e, ابوظبي: e, "xn--mgbi4ecexp": e, كاثوليك: e, "xn--mgbt3dhd": e, همراه: e, "xn--mk1bu44c": e, 닷컴: e, "xn--mxtq1m": e, 政府: e, "xn--ngbc5azd": e, شبكة: e, "xn--ngbe9e0a": e, بيتك: e, "xn--ngbrx": e, عرب: e, "xn--nqv7f": e, 机构: e, "xn--nqv7fs00ema": e, 组织机构: e, "xn--nyqy26a": e, 健康: e, "xn--otu796d": e, 招聘: e, "xn--p1acf": [1, { "xn--90amc": t, "xn--j1aef": t, "xn--j1ael8b": t, "xn--h1ahn": t, "xn--j1adp": t, "xn--c1avg": t, "xn--80aaa0cvac": t, "xn--h1aliz": t, "xn--90a1af": t, "xn--41a": t }], рус: [1, { биз: t, ком: t, крым: t, мир: t, мск: t, орг: t, самара: t, сочи: t, спб: t, я: t }], "xn--pssy2u": e, 大拿: e, "xn--q9jyb4c": e, みんな: e, "xn--qcka1pmc": e, グーグル: e, "xn--rhqv96g": e, 世界: e, "xn--rovu88b": e, 書籍: e, "xn--ses554g": e, 网址: e, "xn--t60b56a": e, 닷넷: e, "xn--tckwe": e, コム: e, "xn--tiq49xqyj": e, 天主教: e, "xn--unup4y": e, 游戏: e, "xn--vermgensberater-ctb": e, vermögensberater: e, "xn--vermgensberatung-pwb": e, vermögensberatung: e, "xn--vhquv": e, 企业: e, "xn--vuq861b": e, 信息: e, "xn--w4r85el8fhu5dnra": e, 嘉里大酒店: e, "xn--w4rs40l": e, 嘉里: e, "xn--xhq521b": e, 广东: e, "xn--zfr164b": e, 政务: e, xyz: [1, { botdash: t, telebit: o }], yachts: e, yahoo: e, yamaxun: e, yandex: e, yodobashi: e, yoga: e, yokohama: e, you: e, youtube: e, yun: e, zappos: e, zara: e, zero: e, zip: e, zone: [1, { cloud66: t, triton: o, stackit: t, lima: t }], zuerich: e }]; })(); -function ec(e, t, n, r) { +function Zl(e, t, n, r) { let o = null, i = t; for (; i !== void 0 && ((i[0] & r) !== 0 && (o = { index: n + 1, @@ -12545,53 +12545,53 @@ function ec(e, t, n, r) { } function Pn(e, t, n) { var r; - if (y0(e, t, n)) + if (m0(e, t, n)) return; - const o = e.split("."), i = (t.allowPrivateDomains ? 2 : 0) | (t.allowIcannDomains ? 1 : 0), s = ec(o, v0, o.length - 1, i); + const o = e.split("."), i = (t.allowPrivateDomains ? 2 : 0) | (t.allowIcannDomains ? 1 : 0), s = Zl(o, y0, o.length - 1, i); if (s !== null) { n.isIcann = s.isIcann, n.isPrivate = s.isPrivate, n.publicSuffix = o.slice(s.index + 1).join("."); return; } - const a = ec(o, b0, o.length - 1, i); + const a = Zl(o, v0, o.length - 1, i); if (a !== null) { n.isIcann = a.isIcann, n.isPrivate = a.isPrivate, n.publicSuffix = o.slice(a.index).join("."); return; } n.isIcann = !1, n.isPrivate = !1, n.publicSuffix = (r = o[o.length - 1]) !== null && r !== void 0 ? r : null; } -const Ze = uf(); +const et = cf(); +function b0(e, t = {}) { + return On(e, 5, Pn, t, cf()); +} function x0(e, t = {}) { - return On(e, 5, Pn, t, uf()); + return mr(et), On(e, 0, Pn, t, et).hostname; } function k0(e, t = {}) { - return mr(Ze), On(e, 0, Pn, t, Ze).hostname; + return mr(et), On(e, 2, Pn, t, et).publicSuffix; } function w0(e, t = {}) { - return mr(Ze), On(e, 2, Pn, t, Ze).publicSuffix; + return mr(et), On(e, 3, Pn, t, et).domain; } function S0(e, t = {}) { - return mr(Ze), On(e, 3, Pn, t, Ze).domain; + return mr(et), On(e, 4, Pn, t, et).subdomain; } function _0(e, t = {}) { - return mr(Ze), On(e, 4, Pn, t, Ze).subdomain; + return mr(et), On(e, 5, Pn, t, et).domainWithoutSuffix; } -function C0(e, t = {}) { - return mr(Ze), On(e, 5, Pn, t, Ze).domainWithoutSuffix; -} -const j0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ +const C0 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ __proto__: null, - getDomain: S0, - getDomainWithoutSuffix: C0, - getHostname: k0, - getPublicSuffix: w0, - getSubdomain: _0, - parse: x0 -}, Symbol.toStringTag, { value: "Module" })), E0 = /* @__PURE__ */ Qf(j0); -var tc; -function Vo() { - if (tc) return Rr; - tc = 1, Object.defineProperty(Rr, "__esModule", { value: !0 }), Rr.getPublicSuffix = o; - const e = E0, t = ["local", "example", "invalid", "localhost", "test"], n = ["localhost", "invalid"], r = { + getDomain: w0, + getDomainWithoutSuffix: _0, + getHostname: x0, + getPublicSuffix: k0, + getSubdomain: S0, + parse: b0 +}, Symbol.toStringTag, { value: "Module" })), j0 = /* @__PURE__ */ Yf(C0); +var ec; +function Ho() { + if (ec) return Rr; + ec = 1, Object.defineProperty(Rr, "__esModule", { value: !0 }), Rr.getPublicSuffix = o; + const e = j0, t = ["local", "example", "invalid", "localhost", "test"], n = ["localhost", "invalid"], r = { allowSpecialUseDomain: !1, ignoreError: !1 }; @@ -12615,11 +12615,11 @@ function Vo() { } return Rr; } -var nc; -function df() { - if (nc) return Nr; - nc = 1, Object.defineProperty(Nr, "__esModule", { value: !0 }), Nr.permuteDomain = t; - const e = Vo(); +var tc; +function uf() { + if (tc) return Nr; + tc = 1, Object.defineProperty(Nr, "__esModule", { value: !0 }), Nr.permuteDomain = t; + const e = Ho(); function t(n, r) { const o = (0, e.getPublicSuffix)(n, { allowSpecialUseDomain: r @@ -12638,10 +12638,10 @@ function df() { } return Nr; } -var Nn = {}, rc; -function na() { - if (rc) return Nn; - rc = 1, Object.defineProperty(Nn, "__esModule", { value: !0 }), Nn.Store = void 0; +var Nn = {}, nc; +function ta() { + if (nc) return Nn; + nc = 1, Object.defineProperty(Nn, "__esModule", { value: !0 }), Nn.Store = void 0; class e { constructor() { this.synchronous = !1; @@ -12697,9 +12697,9 @@ function na() { } return Nn.Store = e, Nn; } -var gi = {}, oc; -function Wo() { - return oc || (oc = 1, (function(e) { +var pi = {}, rc; +function Vo() { + return rc || (rc = 1, (function(e) { Object.defineProperty(e, "__esModule", { value: !0 }), e.safeToString = e.objectToString = void 0, e.createPromiseCallback = i, e.inOperator = s; const t = (a) => Object.prototype.toString.call(a); e.objectToString = t; @@ -12738,13 +12738,13 @@ function Wo() { function s(a, l) { return a in l; } - })(gi)), gi; + })(pi)), pi; } -var ic; -function ff() { - if (ic) return An; - ic = 1, Object.defineProperty(An, "__esModule", { value: !0 }), An.MemoryCookieStore = void 0; - const e = ta(), t = df(), n = na(), r = Wo(); +var oc; +function df() { + if (oc) return An; + oc = 1, Object.defineProperty(An, "__esModule", { value: !0 }), An.MemoryCookieStore = void 0; + const e = ea(), t = uf(), n = ta(), r = Vo(); class o extends n.Store { /** * Create a new {@link MemoryCookieStore}. @@ -12856,11 +12856,11 @@ function ff() { } return An.MemoryCookieStore = o, An; } -var Ie = {}, sc; -function yo() { - if (sc) return Ie; - sc = 1, Object.defineProperty(Ie, "__esModule", { value: !0 }), Ie.ParameterError = void 0, Ie.isNonEmptyString = t, Ie.isDate = n, Ie.isEmptyString = r, Ie.isString = o, Ie.isObject = i, Ie.isInteger = s, Ie.validate = a; - const e = Wo(); +var Ie = {}, ic; +function mo() { + if (ic) return Ie; + ic = 1, Object.defineProperty(Ie, "__esModule", { value: !0 }), Ie.ParameterError = void 0, Ie.isNonEmptyString = t, Ie.isDate = n, Ie.isEmptyString = r, Ie.isString = o, Ie.isObject = i, Ie.isInteger = s, Ie.validate = a; + const e = Vo(); function t(u) { return o(u) && u !== ""; } @@ -12895,13 +12895,13 @@ function yo() { } return Ie.ParameterError = l, Ie; } -var Rn = {}, ac; -function hf() { - return ac || (ac = 1, Object.defineProperty(Rn, "__esModule", { value: !0 }), Rn.version = void 0, Rn.version = "5.1.2"), Rn; +var Rn = {}, sc; +function ff() { + return sc || (sc = 1, Object.defineProperty(Rn, "__esModule", { value: !0 }), Rn.version = void 0, Rn.version = "5.1.2"), Rn; } -var Mr = {}, mi = {}, lc; -function ra() { - return lc || (lc = 1, (function(e) { +var Mr = {}, gi = {}, ac; +function na() { + return ac || (ac = 1, (function(e) { Object.defineProperty(e, "__esModule", { value: !0 }), e.IP_V6_REGEX_OBJECT = e.PrefixSecurityEnum = void 0, e.PrefixSecurityEnum = { SILENT: "silent", STRICT: "strict", @@ -12920,13 +12920,13 @@ function ra() { )(?:%[0-9a-zA-Z]{1,})?\\]? `.replace(/\s*\/\/.*$/gm, "").replace(/\n/g, "").trim(); e.IP_V6_REGEX_OBJECT = new RegExp(`^${t}$`); - })(mi)), mi; + })(gi)), gi; } -var cc; -function Ko() { - if (cc) return Mr; - cc = 1, Object.defineProperty(Mr, "__esModule", { value: !0 }), Mr.canonicalDomain = n; - const e = ra(); +var lc; +function Wo() { + if (lc) return Mr; + lc = 1, Object.defineProperty(Mr, "__esModule", { value: !0 }), Mr.canonicalDomain = n; + const e = na(); function t(r) { return new URL(`http://${r}`).hostname; } @@ -12938,19 +12938,19 @@ function Ko() { } return Mr; } -var Me = {}, Lr = {}, uc; -function pf() { - if (uc) return Lr; - uc = 1, Object.defineProperty(Lr, "__esModule", { value: !0 }), Lr.formatDate = e; +var Le = {}, Lr = {}, cc; +function hf() { + if (cc) return Lr; + cc = 1, Object.defineProperty(Lr, "__esModule", { value: !0 }), Lr.formatDate = e; function e(t) { return t.toUTCString(); } return Lr; } -var Fr = {}, dc; -function gf() { - if (dc) return Fr; - dc = 1, Object.defineProperty(Fr, "__esModule", { value: !0 }), Fr.parseDate = i; +var Fr = {}, uc; +function pf() { + if (uc) return Fr; + uc = 1, Object.defineProperty(Fr, "__esModule", { value: !0 }), Fr.parseDate = i; const e = /[\x09\x20-\x2F\x3B-\x40\x5B-\x60\x7B-\x7E]/, t = { jan: 0, feb: 1, @@ -13061,11 +13061,11 @@ function gf() { } return Fr; } -var fc; -function Xi() { - if (fc) return Me; - fc = 1; - var e = Me && Me.__createBinding || (Object.create ? (function(v, b, j, _) { +var dc; +function Gi() { + if (dc) return Le; + dc = 1; + var e = Le && Le.__createBinding || (Object.create ? (function(v, b, j, _) { _ === void 0 && (_ = j); var S = Object.getOwnPropertyDescriptor(b, j); (!S || ("get" in S ? !b.__esModule : S.writable || S.configurable)) && (S = { enumerable: !0, get: function() { @@ -13073,18 +13073,18 @@ function Xi() { } }), Object.defineProperty(v, _, S); }) : (function(v, b, j, _) { _ === void 0 && (_ = j), v[_] = b[j]; - })), t = Me && Me.__setModuleDefault || (Object.create ? (function(v, b) { + })), t = Le && Le.__setModuleDefault || (Object.create ? (function(v, b) { Object.defineProperty(v, "default", { enumerable: !0, value: b }); }) : function(v, b) { v.default = b; - }), n = Me && Me.__importStar || function(v) { + }), n = Le && Le.__importStar || function(v) { if (v && v.__esModule) return v; var b = {}; if (v != null) for (var j in v) j !== "default" && Object.prototype.hasOwnProperty.call(v, j) && e(b, v, j); return t(b, v), b; }; - Object.defineProperty(Me, "__esModule", { value: !0 }), Me.Cookie = void 0; - const r = Vo(), o = n(yo()), i = Wo(), s = pf(), a = gf(), l = Ko(), u = /^[\x21\x23-\x2B\x2D-\x3A\x3C-\x5B\x5D-\x7E]+$/, d = /[\x20-\x3A\x3C-\x7E]+/, h = /[\x00-\x1F]/, f = [` + Object.defineProperty(Le, "__esModule", { value: !0 }), Le.Cookie = void 0; + const r = Ho(), o = n(mo()), i = Vo(), s = hf(), a = pf(), l = Wo(), u = /^[\x21\x23-\x2B\x2D-\x3A\x3C-\x5B\x5D-\x7E]+$/, d = /[\x20-\x3A\x3C-\x7E]+/, h = /[\x00-\x1F]/, f = [` `, "\r", "\0"]; function p(v) { if (o.isEmptyString(v)) @@ -13511,7 +13511,7 @@ function Xi() { return y(b); } } - return Me.Cookie = k, k.cookiesCreated = 0, k.sameSiteLevel = { + return Le.Cookie = k, k.cookiesCreated = 0, k.sameSiteLevel = { strict: 3, lax: 2, none: 1 @@ -13533,12 +13533,12 @@ function Xi() { "creation", "lastAccessed", "sameSite" - ], Me; + ], Le; } -var qr = {}, hc; -function mf() { - if (hc) return qr; - hc = 1, Object.defineProperty(qr, "__esModule", { value: !0 }), qr.cookieCompare = t; +var qr = {}, fc; +function gf() { + if (fc) return qr; + fc = 1, Object.defineProperty(qr, "__esModule", { value: !0 }), qr.cookieCompare = t; const e = 2147483647e3; function t(n, r) { let o; @@ -13550,10 +13550,10 @@ function mf() { } return qr; } -var Le = {}, Br = {}, pc; -function yf() { - if (pc) return Br; - pc = 1, Object.defineProperty(Br, "__esModule", { value: !0 }), Br.defaultPath = e; +var Fe = {}, Br = {}, hc; +function mf() { + if (hc) return Br; + hc = 1, Object.defineProperty(Br, "__esModule", { value: !0 }), Br.defaultPath = e; function e(t) { if (!t || t.slice(0, 1) !== "/") return "/"; @@ -13564,11 +13564,11 @@ function yf() { } return Br; } -var Ur = {}, gc; -function vf() { - if (gc) return Ur; - gc = 1, Object.defineProperty(Ur, "__esModule", { value: !0 }), Ur.domainMatch = n; - const e = Ko(), t = /(?:^(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}$)|(?:^(?:(?:[a-f\d]{1,4}:){7}(?:[a-f\d]{1,4}|:)|(?:[a-f\d]{1,4}:){6}(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|:[a-f\d]{1,4}|:)|(?:[a-f\d]{1,4}:){5}(?::(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,2}|:)|(?:[a-f\d]{1,4}:){4}(?:(?::[a-f\d]{1,4}){0,1}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,3}|:)|(?:[a-f\d]{1,4}:){3}(?:(?::[a-f\d]{1,4}){0,2}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,4}|:)|(?:[a-f\d]{1,4}:){2}(?:(?::[a-f\d]{1,4}){0,3}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,5}|:)|(?:[a-f\d]{1,4}:){1}(?:(?::[a-f\d]{1,4}){0,4}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,6}|:)|(?::(?:(?::[a-f\d]{1,4}){0,5}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,7}|:)))$)/; +var Ur = {}, pc; +function yf() { + if (pc) return Ur; + pc = 1, Object.defineProperty(Ur, "__esModule", { value: !0 }), Ur.domainMatch = n; + const e = Wo(), t = /(?:^(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}$)|(?:^(?:(?:[a-f\d]{1,4}:){7}(?:[a-f\d]{1,4}|:)|(?:[a-f\d]{1,4}:){6}(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|:[a-f\d]{1,4}|:)|(?:[a-f\d]{1,4}:){5}(?::(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,2}|:)|(?:[a-f\d]{1,4}:){4}(?:(?::[a-f\d]{1,4}){0,1}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,3}|:)|(?:[a-f\d]{1,4}:){3}(?:(?::[a-f\d]{1,4}){0,2}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,4}|:)|(?:[a-f\d]{1,4}:){2}(?:(?::[a-f\d]{1,4}){0,3}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,5}|:)|(?:[a-f\d]{1,4}:){1}(?:(?::[a-f\d]{1,4}){0,4}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,6}|:)|(?::(?:(?::[a-f\d]{1,4}){0,5}:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)){3}|(?::[a-f\d]{1,4}){1,7}|:)))$)/; function n(r, o, i) { if (r == null || o == null) return; @@ -13582,11 +13582,11 @@ function vf() { } return Ur; } -var mc; -function T0() { - if (mc) return Le; - mc = 1; - var e = Le && Le.__createBinding || (Object.create ? (function($, C, T, O) { +var gc; +function E0() { + if (gc) return Fe; + gc = 1; + var e = Fe && Fe.__createBinding || (Object.create ? (function($, C, T, O) { O === void 0 && (O = T); var I = Object.getOwnPropertyDescriptor(C, T); (!I || ("get" in I ? !C.__esModule : I.writable || I.configurable)) && (I = { enumerable: !0, get: function() { @@ -13594,18 +13594,18 @@ function T0() { } }), Object.defineProperty($, O, I); }) : (function($, C, T, O) { O === void 0 && (O = T), $[O] = C[T]; - })), t = Le && Le.__setModuleDefault || (Object.create ? (function($, C) { + })), t = Fe && Fe.__setModuleDefault || (Object.create ? (function($, C) { Object.defineProperty($, "default", { enumerable: !0, value: C }); }) : function($, C) { $.default = C; - }), n = Le && Le.__importStar || function($) { + }), n = Fe && Fe.__importStar || function($) { if ($ && $.__esModule) return $; var C = {}; if ($ != null) for (var T in $) T !== "default" && Object.prototype.hasOwnProperty.call($, T) && e(C, $, T); return t(C, $), C; }; - Object.defineProperty(Le, "__esModule", { value: !0 }), Le.CookieJar = void 0; - const r = Vo(), o = n(yo()), i = yo(), s = na(), a = ff(), l = ta(), u = Xi(), d = Wo(), h = Ko(), f = ra(), p = yf(), g = vf(), m = mf(), y = hf(), x = { + Object.defineProperty(Fe, "__esModule", { value: !0 }), Fe.CookieJar = void 0; + const r = Ho(), o = n(mo()), i = mo(), s = ta(), a = df(), l = ea(), u = Gi(), d = Vo(), h = Wo(), f = na(), p = mf(), g = yf(), m = gf(), y = ff(), x = { loose: !1, sameSiteContext: void 0, ignoreError: !1, @@ -13762,8 +13762,8 @@ function T0() { U(G); return; } - const ue = function(Ve) { - Ve ? U(Ve) : typeof C == "string" ? U(null, void 0) : U(null, C); + const ue = function(We) { + We ? U(We) : typeof C == "string" ? U(null, void 0) : U(null, C); }; if (ee) { if (O && "http" in O && O.http === !1 && ee.httpOnly) { @@ -13821,7 +13821,7 @@ function T0() { if (X = u.Cookie.sameSiteLevel[G], !X) return I.reject(new Error(v)); } - const re = T.http ?? !0, ve = Date.now(), et = T.expire ?? !0, ge = T.allPaths ?? !1, Oe = this.store; + const re = T.http ?? !0, ve = Date.now(), tt = T.expire ?? !0, ge = T.allPaths ?? !1, Oe = this.store; function Y(G) { if (G.hostOnly) { if (G.domain != V) @@ -13836,7 +13836,7 @@ function T0() { return !1; } const ee = G.expiryTime(); - return et && ee != null && ee <= ve ? (Oe.removeCookie(G.domain, G.path, G.key, () => { + return tt && ee != null && ee <= ve ? (Oe.removeCookie(G.domain, G.path, G.key, () => { }), !1) : !0; } return Oe.findCookies(V, ge ? null : q, this.allowSpecialUseDomain, (G, ee) => { @@ -13850,8 +13850,8 @@ function T0() { } ee = ee.filter(Y), "sort" in T && T.sort !== !1 && (ee = ee.sort(m.cookieCompare)); const ue = /* @__PURE__ */ new Date(); - for (const Ve of ee) - Ve.lastAccessed = ue; + for (const We of ee) + We.lastAccessed = ue; N(null, ee); }), I.promise; } @@ -14180,12 +14180,12 @@ function T0() { return D.deserializeSync(C, T); } } - return Le.CookieJar = D, Le; + return Fe.CookieJar = D, Fe; } -var Hr = {}, yc; -function O0() { - if (yc) return Hr; - yc = 1, Object.defineProperty(Hr, "__esModule", { value: !0 }), Hr.permutePath = e; +var Hr = {}, mc; +function T0() { + if (mc) return Hr; + mc = 1, Object.defineProperty(Hr, "__esModule", { value: !0 }), Hr.permutePath = e; function e(t) { if (t === "/") return ["/"]; @@ -14200,95 +14200,95 @@ function O0() { } return Hr; } -var vc; -function P0() { - return vc || (vc = 1, (function(e) { +var yc; +function O0() { + return yc || (yc = 1, (function(e) { Object.defineProperty(e, "__esModule", { value: !0 }), e.permutePath = e.parseDate = e.formatDate = e.domainMatch = e.defaultPath = e.CookieJar = e.cookieCompare = e.Cookie = e.PrefixSecurityEnum = e.canonicalDomain = e.version = e.ParameterError = e.Store = e.getPublicSuffix = e.permuteDomain = e.pathMatch = e.MemoryCookieStore = void 0, e.parse = v, e.fromJSON = b; - var t = ff(); + var t = df(); Object.defineProperty(e, "MemoryCookieStore", { enumerable: !0, get: function() { return t.MemoryCookieStore; } }); - var n = ta(); + var n = ea(); Object.defineProperty(e, "pathMatch", { enumerable: !0, get: function() { return n.pathMatch; } }); - var r = df(); + var r = uf(); Object.defineProperty(e, "permuteDomain", { enumerable: !0, get: function() { return r.permuteDomain; } }); - var o = Vo(); + var o = Ho(); Object.defineProperty(e, "getPublicSuffix", { enumerable: !0, get: function() { return o.getPublicSuffix; } }); - var i = na(); + var i = ta(); Object.defineProperty(e, "Store", { enumerable: !0, get: function() { return i.Store; } }); - var s = yo(); + var s = mo(); Object.defineProperty(e, "ParameterError", { enumerable: !0, get: function() { return s.ParameterError; } }); - var a = hf(); + var a = ff(); Object.defineProperty(e, "version", { enumerable: !0, get: function() { return a.version; } }); - var l = Ko(); + var l = Wo(); Object.defineProperty(e, "canonicalDomain", { enumerable: !0, get: function() { return l.canonicalDomain; } }); - var u = ra(); + var u = na(); Object.defineProperty(e, "PrefixSecurityEnum", { enumerable: !0, get: function() { return u.PrefixSecurityEnum; } }); - var d = Xi(); + var d = Gi(); Object.defineProperty(e, "Cookie", { enumerable: !0, get: function() { return d.Cookie; } }); - var h = mf(); + var h = gf(); Object.defineProperty(e, "cookieCompare", { enumerable: !0, get: function() { return h.cookieCompare; } }); - var f = T0(); + var f = E0(); Object.defineProperty(e, "CookieJar", { enumerable: !0, get: function() { return f.CookieJar; } }); - var p = yf(); + var p = mf(); Object.defineProperty(e, "defaultPath", { enumerable: !0, get: function() { return p.defaultPath; } }); - var g = vf(); + var g = yf(); Object.defineProperty(e, "domainMatch", { enumerable: !0, get: function() { return g.domainMatch; } }); - var m = pf(); + var m = hf(); Object.defineProperty(e, "formatDate", { enumerable: !0, get: function() { return m.formatDate; } }); - var y = gf(); + var y = pf(); Object.defineProperty(e, "parseDate", { enumerable: !0, get: function() { return y.parseDate; } }); - var x = O0(); + var x = T0(); Object.defineProperty(e, "permutePath", { enumerable: !0, get: function() { return x.permutePath; } }); - const k = Xi(); + const k = Gi(); function v(j, _) { return k.Cookie.parse(j, _); } function b(j) { return k.Cookie.fromJSON(j); } - })(pi)), pi; + })(hi)), hi; } -var bf = P0(); -function bc(e, t, n, r, o) { +var vf = O0(); +function vc(e, t, n, r, o) { const i = []; if (t === void 0) return [[], void 0]; - const s = $0(t, r); + const s = P0(t, r); for (const [a, l] of s) { - const [u, d] = z0( + const [u, d] = D0( { ...e, responseCode: a }, l, n, @@ -14304,50 +14304,50 @@ function bc(e, t, n, r, o) { } return [i, void 0]; } -function $0(e, t) { - const n = [], r = Object.keys(e).sort(L0); +function P0(e, t) { + const n = [], r = Object.keys(e).sort(M0); for (const o of r) - D0(o, t) && n.push([o, e[o]]); + $0(o, t) && n.push([o, e[o]]); return n; } -function D0(e, t) { - return t === Ho || t.statusCode.toString() === e || Zr(t.statusCode) === e || e === "default"; +function $0(e, t) { + return t === Uo || t.statusCode.toString() === e || Zr(t.statusCode) === e || e === "default"; } -function z0(e, t, n, r, o) { +function D0(e, t, n, r, o) { const i = {}, s = []; for (const [a, l] of Object.entries(t.variableAssignments || {})) { - const [u, d] = I0(l, n, r, o); + const [u, d] = z0(l, n, r, o); d !== void 0 ? s.push({ name: a, error: d, value: void 0, assignment: l }) : u === void 0 ? s.push({ name: a, error: "not found", value: void 0, assignment: l }) : (i[a] = u, s.push({ name: a, value: u, error: void 0 })); } return [{ id: e, env: i, assignments: s }, void 0]; } -function I0(e, t, n, r) { - if (n === Ho) +function z0(e, t, n, r) { + if (n === Uo) return ["foo", void 0]; if (e.in === "body" && e?.path?.type == "jsonPointer") - return e.from === "request" ? xc(t.body, e.path.value) : xc(n.body, e.path.value); + return e.from === "request" ? bc(t.body, e.path.value) : bc(n.body, e.path.value); if (e.in === "body" && e?.path?.type == "jsonPath") - return e.from === "request" ? kc(t.body, e.path.value) : kc(n.body, e.path.value); + return e.from === "request" ? xc(t.body, e.path.value) : xc(n.body, e.path.value); if (e.in === "header") - return e.from === "request" ? A0(t.headers, e.name) : N0(n.headers, e.name); + return e.from === "request" ? I0(t.headers, e.name) : A0(n.headers, e.name); if (e.in === "cookie") - return e.from === "request" ? M0(t.headers, e.name) : R0(n.headers, e.name); + return e.from === "request" ? R0(t.headers, e.name) : N0(n.headers, e.name); if (e.in === "query") { if (e.from === "request") - return wc(r.query, e.name); + return kc(r.query, e.name); } else if (e.in === "path" && e.from === "request") - return wc(r.path, e.name); + return kc(r.path, e.name); return [void 0, `unsupported assignment: from ${e.from} in ${e.in}`]; } -function xc(e, t) { +function bc(e, t) { try { - const n = JSON.parse(e), r = St.find(n, t); + const n = JSON.parse(e), r = Re.find(n, t); return typeof r == "object" ? [void 0, "must be a primitive value"] : [r, void 0]; } catch (n) { return [void 0, `Failed to extract value using JSON Pointer "${t}": ${n}`]; } } -function kc(e, t) { +function xc(e, t) { try { const n = JSON.parse(e), r = Z({ json: n, path: t }); return typeof r?.[0] == "object" ? [void 0, "must be a primitive value"] : [r?.[0], void 0]; @@ -14355,46 +14355,46 @@ function kc(e, t) { return [void 0, `Failed to extract value using JSON Path "${t}": ${n}`]; } } -function A0(e, t) { +function I0(e, t) { for (const [n, r] of Object.entries(e)) if (n.toLowerCase() === t.toLowerCase()) return [r, void 0]; return [void 0, "not found"]; } -function N0(e, t) { +function A0(e, t) { for (const [n, r] of e) if (n.toLowerCase() === t.toLowerCase()) return [r, void 0]; return [void 0, "not found"]; } -function R0(e, t) { +function N0(e, t) { for (const [n, r] of e) if (n.toLowerCase() === "set-cookie") { - const o = bf.Cookie.parse(r); + const o = vf.Cookie.parse(r); if (o !== void 0 && o.key === t) return [o.value, void 0]; } return [void 0, "not found"]; } -function M0(e, t) { +function R0(e, t) { for (const [n, r] of Object.entries(e)) if (n.toLowerCase() === "cookie") { const o = r.split("; "); for (const i of o) { - const s = bf.Cookie.parse(i); + const s = vf.Cookie.parse(i); if (s !== void 0 && s.key === t) return [s.value, void 0]; } } return [void 0, "not found"]; } -function wc(e, t) { +function kc(e, t) { for (const { key: n, value: r } of e) if (n === t) return [r, void 0]; return [void 0, "not found"]; } -function L0(e, t) { +function M0(e, t) { const n = { default: 0, "1XX": 1, @@ -14405,17 +14405,17 @@ function L0(e, t) { }, r = e in n ? n[e] : Number.MAX_SAFE_INTEGER, o = t in n ? n[t] : Number.MAX_SAFE_INTEGER; return r - o; } -function Sc(e) { +function wc(e) { const t = []; for (const { assignments: n } of e) for (const r of n) r.error !== void 0 && t.push(r); return t; } -async function* Bj(e, t, n, r, o, i, s = []) { - const a = Pw(), l = [B0(r, i)], u = []; +async function* qj(e, t, n, r, o, i, s = []) { + const a = Ow(), l = [q0(r, i)], u = []; for (const { name: d, requests: h } of o) { - const f = yield* xf( + const f = yield* bf( d, a, e, @@ -14432,7 +14432,7 @@ async function* Bj(e, t, n, r, o, i, s = []) { } return u; } -async function* xf(e, t, n, r, o, i, s, a, l) { +async function* bf(e, t, n, r, o, i, s, a, l) { const u = []; if (yield { event: "playbook-started", name: e }, l >= 5) { yield { @@ -14450,7 +14450,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { }; return; } - const f = U0(i, h.ref); + const f = B0(i, h.ref); if (f === void 0) { yield { event: "playbook-aborted", @@ -14459,7 +14459,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { return; } yield { event: "request-started", ref: h.ref }; - const p = f.operationId === void 0 ? void 0 : f.auth, g = yield* F0( + const p = f.operationId === void 0 ? void 0 : f.auth, g = yield* L0( t, n, r, @@ -14476,7 +14476,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { }; return; } - const m = xa( + const m = ba( "stage-environment", h.environment || {}, [...a, ...u] @@ -14485,7 +14485,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { env: m.value, // FIXME can we make replaceEnvVariables return assignments? assignments: [] - }, x = [...a, ...u, y], k = xa( + }, x = [...a, ...u, y], k = ba( "request-environment", f.environment || {}, x @@ -14493,7 +14493,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { id: { type: "request-environment" }, env: k.value, assignments: [] - }, b = f.operationId !== void 0 ? qc(r, f.operationId)?.operation : void 0, j = nh(r, f.request, b, [ + }, b = f.operationId !== void 0 ? Fc(r, f.operationId)?.operation : void 0, j = ah(r, f.request, b, [ ...a, ...u, v, @@ -14511,11 +14511,11 @@ async function* xf(e, t, n, r, o, i, s, a, l) { }, _.length > 0) { yield { event: "http-request-prepare-error", - error: `failed to replace request variables: ${rh(_)}` + error: `failed to replace request variables: ${lh(_)}` }; return; } - const [S, P] = "operationId" in j.value ? await Iw(r, o, f.operationId, j.value, g) : await Rw(j.value); + const [S, P] = "operationId" in j.value ? await zw(r, o, f.operationId, j.value, g) : await Nw(j.value); if (P !== void 0) { yield { event: "http-request-prepare-error", error: P }; return; @@ -14525,12 +14525,12 @@ async function* xf(e, t, n, r, o, i, s, a, l) { request: S, operationId: f.operationId }; - const D = "operationId" in j.value ? H0(i.securityProfile, a) : void 0, [$, C] = await n(S, D); + const D = "operationId" in j.value ? U0(i.securityProfile, a) : void 0, [$, C] = await n(S, D); if (C !== void 0) { yield { event: "http-error-received", error: C }; return; } - if (yield { event: "http-response-received", response: $ }, $ !== Ho) { + if (yield { event: "http-response-received", response: $ }, $ !== Uo) { if (h.expectedResponse !== void 0) { if (String($?.statusCode) !== h.expectedResponse && Zr($.statusCode) !== h.expectedResponse && f.defaultResponse !== "default") { yield { @@ -14547,7 +14547,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { return; } } - const [T, O] = bc( + const [T, O] = vc( { type: "playbook-request", name: e, step: d, responseCode: "default" }, f.responses, S, @@ -14562,7 +14562,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { return; } u.push(...T), yield { event: "variables-assigned", assignments: T }; - const I = Sc(T); + const I = wc(T); if (I.length > 0) { yield { event: "response-processing-error", @@ -14570,7 +14570,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { }; return; } - const [N, U] = bc( + const [N, U] = vc( { type: "playbook-stage", name: e, step: d, responseCode: "default" }, h.responses, S, @@ -14585,7 +14585,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { return; } yield { event: "variables-assigned", assignments: N }; - const V = Sc(N); + const V = wc(N); if (V.length > 0) { yield { event: "response-processing-error", @@ -14597,7 +14597,7 @@ async function* xf(e, t, n, r, o, i, s, a, l) { } return yield { event: "playbook-finished" }, u; } -async function* F0(e, t, n, r, o, i, s, a) { +async function* L0(e, t, n, r, o, i, s, a) { const l = {}; if (i === void 0) return l; @@ -14620,7 +14620,7 @@ async function* F0(e, t, n, r, o, i, s, a) { yield { event: "auth-aborted", error: `credential: "${d}" is not found` }; return; } - const m = Dw(e, f, p); + const m = $w(e, f, p); if (m !== void 0) yield { event: "credential-retrieved-from-cache", @@ -14628,7 +14628,7 @@ async function* F0(e, t, n, r, o, i, s, a) { result: m }, l[u] = { credential: f, value: m }; else { - const y = yield* q0( + const y = yield* F0( e, t, n, @@ -14646,16 +14646,16 @@ async function* F0(e, t, n, r, o, i, s, a) { }; return; } - $w(e, f, p, y), l[u] = { credential: f, value: y }; + Pw(e, f, p, y), l[u] = { credential: f, value: y }; } yield { event: "auth-finished" }; } return l; } -async function* q0(e, t, n, r, o, i, s, a, l) { +async function* F0(e, t, n, r, o, i, s, a, l) { const u = [...a]; if (s.requests !== void 0) { - const h = yield* xf( + const h = yield* bf( i, e, t, @@ -14670,7 +14670,7 @@ async function* q0(e, t, n, r, o, i, s, a, l) { return void 0; u.push(...h); } - const d = Fc(s.credential, u); + const d = Lc(s.credential, u); return d.missing.length, yield { event: "credential-variables-substituted", name: i, @@ -14690,26 +14690,26 @@ function yr(e, t) { missing: o }; } -function B0(e, t) { +function q0(e, t) { const n = e.runtimeConfiguration?.environment || "default", { environment: r } = yr( e?.environments?.[n] || { variables: {} }, t ); return r; } -function U0(e, t) { +function B0(e, t) { return t.type === "operation" ? e.operations[t.id]?.request : e.requests?.[t.id]; } -function H0(e, t) { +function U0(e, t) { if (e === void 0) return; - const n = Fc(e.clientCertificatePassword, t); + const n = Lc(e.clientCertificatePassword, t); return { ...e, clientCertificatePassword: n.value }; } -function Uj(e) { +function Bj(e) { return { getOperationDetailsById: (t) => { - const n = qc(e, t); + const n = Fc(e, t); return n === void 0 ? [ void 0, `Unable to find in the OpenAPI file an operation with operationId: "${t}"` @@ -14717,51 +14717,51 @@ function Uj(e) { } }; } -function Hj() { +function Uj() { return { getOperationDetailsById: (e) => [{ path: "/", method: "post" }, void 0] }; } -function Vj(e, t) { - const [n, r] = V0(e, t); +function Hj(e, t) { + const [n, r] = H0(e, t); return r == null ? [n, void 0] : [ void 0, r.map((o) => ({ message: o.message.slice(-1).join(": "), - pointer: eo.joinJsonPointer(o.path) + pointer: Re.joinJsonPointer(o.path) })) ]; } -function V0(e, t) { +function H0(e, t) { return ye({ - before: gt(e, t, t.before || [], mn), - after: gt(e, t, t.after || [], mn), - operations: Be(e, t, t.operations || {}, Y0), - authenticationDetails: gt(e, t, t.authenticationDetails === void 0 || t.authenticationDetails.length === 0 ? [{}] : t.authenticationDetails, c1), - securityProfile: W0(e, t, t.securityProfile), - runtimeConfiguration: K0(e, t, t.runtimeConfiguration || {}), + before: mt(e, t, t.before || [], mn), + after: mt(e, t, t.after || [], mn), + operations: Ue(e, t, t.operations || {}, X0), + authenticationDetails: mt(e, t, t.authenticationDetails === void 0 || t.authenticationDetails.length === 0 ? [{}] : t.authenticationDetails, l1), + securityProfile: V0(e, t, t.securityProfile), + runtimeConfiguration: W0(e, t, t.runtimeConfiguration || {}), customizations: K(t.customizations), - environments: Be(e, t, t.environments || {}, G0), - authorizationTests: Be(e, t, t.authorizationTests || {}, h1), - requests: Be(e, t, t.requests || {}, t1) + environments: Ue(e, t, t.environments || {}, K0), + authorizationTests: Ue(e, t, t.authorizationTests || {}, f1), + requests: Ue(e, t, t.requests || {}, e1) }); } -function W0(e, t, n) { +function V0(e, t, n) { return n === void 0 ? [void 0, void 0] : ye({ clientCertificate: K(n.clientCertificate), clientCertificatePassword: K(n.clientCertificatePassword), caServerCertificate: K(n.caServerCertificate) }); } -function K0(e, t, n) { +function W0(e, t, n) { return [{ ...n }, void 0]; } -function G0(e, t, n) { +function K0(e, t, n) { return ye({ - variables: Be(e, t, n.variables || {}, X0) + variables: Ue(e, t, n.variables || {}, G0) }); } -function X0(e, t, n) { +function G0(e, t, n) { return n.from === "environment" ? ye({ name: K(n.name), from: K(n.from), @@ -14772,72 +14772,72 @@ function X0(e, t, n) { value: K(n.value) }) : Et("unknown env from"); } -function Y0(e, t, n) { +function X0(e, t, n) { return ye({ - request: oa(e, t, n.request, n.operationId), + request: ra(e, t, n.request, n.operationId), operationId: K(n.operationId), - before: gt(e, t, n.before || [], mn), - after: gt(e, t, n.after || [], mn), + before: mt(e, t, n.before || [], mn), + after: mt(e, t, n.after || [], mn), authorizationTests: K(n.authorizationTests || []), - scenarios: gt(e, t, n.scenarios || [], f1), + scenarios: mt(e, t, n.scenarios || [], d1), customTests: K(n.customTests), - customized: K(Q0(n)) + customized: K(Y0(n)) }); } -function Q0(e) { - const t = e.scenarios?.[0]?.requests, n = t?.[0], r = e.customTests && e.customTests.length > 0, o = e.authorizationTests && e.authorizationTests.length > 0, i = e.before && e.before.length > 0, s = e.after && e.after.length > 0, a = e.scenarios && e.scenarios.length > 1, l = t && t.length > 1, u = n !== void 0 && J0(n); +function Y0(e) { + const t = e.scenarios?.[0]?.requests, n = t?.[0], r = e.customTests && e.customTests.length > 0, o = e.authorizationTests && e.authorizationTests.length > 0, i = e.before && e.before.length > 0, s = e.after && e.after.length > 0, a = e.scenarios && e.scenarios.length > 1, l = t && t.length > 1, u = n !== void 0 && Q0(n); return r || o || i || s || a || l || u; } -function J0(e) { +function Q0(e) { const t = e.environment && Object.keys(e.environment).length > 0, n = e.auth && e.auth.length > 0, r = e.responses && Object.keys(e.responses).length > 0, o = "expectedResponse" in e; return t || n || r || o; } function mn(e, t, n) { - return n.$ref !== void 0 ? Z0(e, t, n) : oa(e, t, n); + return n.$ref !== void 0 ? J0(e, t, n) : ra(e, t, n); } -function Z0(e, t, n) { +function J0(e, t, n) { return ye({ - responses: Be(e, t, n.responses || {}, ia), + responses: Ue(e, t, n.responses || {}, oa), auth: K(n.auth || []), - ref: l1(e, t, n.$ref), + ref: a1(e, t, n.$ref), fuzzing: K(n.fuzzing), - environment: sa(e, t, n.environment || {}), + environment: ia(e, t, n.environment || {}), injectionKey: K(n.injectionKey), expectedResponse: K(n.expectedResponse) }); } -function oa(e, t, n, r) { +function ra(e, t, n, r) { return ye({ - responses: Be(e, t, n.responses || {}, ia), + responses: Ue(e, t, n.responses || {}, oa), fuzzing: K(n.fuzzing), auth: K(n.auth || []), - environment: sa(e, t, n.environment || {}), + environment: ia(e, t, n.environment || {}), injectionKey: K(n.injectionKey), ref: K(void 0), defaultResponse: K(n.defaultResponse), - request: n1(e, t, n.request, r), + request: t1(e, t, n.request, r), operationId: K(r) }); } -function e1(e, t, n) { +function Z0(e, t, n) { return ye({ operationId: [void 0, void 0], - responses: Be(e, t, n.responses || {}, ia), - environment: sa(e, t, n.environment || {}), + responses: Ue(e, t, n.responses || {}, oa), + environment: ia(e, t, n.environment || {}), defaultResponse: K(n.defaultResponse), - request: r1(e, t, n.request) + request: n1(e, t, n.request) }); } -function t1(e, t, n) { - return n.operationId === void 0 ? e1(e, t, n) : oa(e, t, n, n.operationId); +function e1(e, t, n) { + return n.operationId === void 0 ? Z0(e, t, n) : ra(e, t, n, n.operationId); } -function n1(e, t, n, r) { - return n.type === "42c" ? o1(e, t, n, r) : Et(`unknown request type: ${n.type}`); +function t1(e, t, n, r) { + return n.type === "42c" ? r1(e, t, n, r) : Et(`unknown request type: ${n.type}`); } -function r1(e, t, n) { - return n.type === "42c" ? i1(e, t, n) : Et(`unknown request type: ${n.type}`); +function n1(e, t, n) { + return n.type === "42c" ? o1(e, t, n) : Et(`unknown request type: ${n.type}`); } -function o1(e, t, n, r) { +function r1(e, t, n, r) { const o = n?.details?.operationId || r; if (o === void 0) return [ @@ -14849,28 +14849,28 @@ function o1(e, t, n, r) { operationId: K(o), path: K(i.path), method: K(i.method.toLowerCase()), - parameters: wf(e, t, n?.details || {}), - body: kf(e, t, n?.details?.requestBody) + parameters: kf(e, t, n?.details || {}), + body: xf(e, t, n?.details?.requestBody) }); } -function i1(e, t, n) { +function o1(e, t, n) { return ye({ url: K(n.details.url), method: K(n.details.method.toLowerCase()), - parameters: wf(e, t, n?.details || {}), - body: kf(e, t, n?.details?.requestBody) + parameters: kf(e, t, n?.details || {}), + body: xf(e, t, n?.details?.requestBody) }); } -function kf(e, t, n) { +function xf(e, t, n) { return n == null ? [void 0, void 0] : n.mode === "json" ? [{ mediaType: "application/json", value: n.json }, void 0] : n.mode === "urlencoded" ? [ - { mediaType: "application/x-www-form-urlencoded", value: s1(n.urlencoded) }, + { mediaType: "application/x-www-form-urlencoded", value: i1(n.urlencoded) }, void 0 ] : n.mode === "raw" ? [{ mediaType: "raw", value: n.raw }, void 0] : [void 0, void 0]; } -function s1(e) { +function i1(e) { return Object.entries(e).reduce((t, [n, r]) => (t[n] = r.value, t), {}); } -function wf(e, t, n) { +function kf(e, t, n) { return ye({ cookie: Vr(e, t, n.cookies || []), path: Vr(e, t, n.paths || []), @@ -14884,13 +14884,13 @@ function Vr(e, t, n) { void 0 ]; } -function ia(e, t, n) { +function oa(e, t, n) { return ye({ expectations: K(n.expectations), - variableAssignments: Be(e, t, n.variableAssignments || {}, a1) + variableAssignments: Ue(e, t, n.variableAssignments || {}, s1) }); } -function a1(e, t, n) { +function s1(e, t, n) { return n.in === "body" && (n.from == "response" || n.from == "request") ? [ { in: n.in, @@ -14911,19 +14911,19 @@ function a1(e, t, n) { void 0 ] : Et("unexpected assignment"); } -function sa(e, t, n) { +function ia(e, t, n) { return [n, void 0]; } -function l1(e, t, n) { +function a1(e, t, n) { if (n === void 0) return [void 0, void 0]; - const r = eo.parseJsonPointer(n); + const r = Re.parseJsonPointer(n); return r.length === 2 && r[0] === "requests" ? [{ type: "request", id: String(r[1]) }, void 0] : r.length === 3 && r[0] === "operations" && r[2] === "request" ? [{ type: "operation", id: String(r[1]) }, void 0] : Et(`unexpected stage $ref, must point to operations or requests: ${n}`); } -function c1(e, t, n) { - return n.$ref !== void 0 ? Et(`external credential refs are not supported: ${n.$ref}`) : Be(e, t, n, u1); +function l1(e, t, n) { + return n.$ref !== void 0 ? Et(`external credential refs are not supported: ${n.$ref}`) : Ue(e, t, n, c1); } -function u1(e, t, n) { +function c1(e, t, n) { return ye({ in: K(n.in), type: K(n.type), @@ -14931,25 +14931,25 @@ function u1(e, t, n) { default: K(n.default), ttl: K(n.ttl), tti: K(n.tti), - methods: Be(e, t, n.credentials || {}, d1), + methods: Ue(e, t, n.credentials || {}, u1), description: K(n.description) }); } -function d1(e, t, n) { +function u1(e, t, n) { return ye({ description: K(n.description), - requests: gt(e, t, n.requests || [], mn), + requests: mt(e, t, n.requests || [], mn), credential: K(n.credential) }); } -function f1(e, t, n) { +function d1(e, t, n) { return ye({ - requests: gt(e, t, n.requests || [], mn), + requests: mt(e, t, n.requests || [], mn), key: K(n.key), fuzzing: K(n.fuzzing) }); } -function h1(e, t, n) { +function f1(e, t, n) { const r = n.source === null ? [] : n.source, o = n.target === null ? [] : n.target; return r.some((i) => typeof i != "string") || o.some((i) => typeof i != "string") ? Et("only strings are allowed, embedding Credential objects is not supported yet") : ye({ key: K(n.key), @@ -14978,7 +14978,7 @@ function ye(e) { function K(e) { return [e, void 0]; } -function Be(e, t, n, r) { +function Ue(e, t, n, r) { const o = [], i = {}, s = Object.entries(n).map(([a, l]) => [a, r(e, t, l)]); for (const [a, l] of s) { const [u, d] = l; @@ -14986,7 +14986,7 @@ function Be(e, t, n, r) { } return o.length > 0 ? [void 0, o] : [i, void 0]; } -function gt(e, t, n, r) { +function mt(e, t, n, r) { const o = [], i = [], s = (n || []).map((a) => r(e, t, a)); for (const [a, l] of s.entries()) { const [u, d] = l; @@ -14994,14 +14994,14 @@ function gt(e, t, n, r) { } return o.length > 0 ? [void 0, o] : [i, void 0]; } -function p1(e) { - const t = e.runtimeConfiguration, n = e.customizations, r = e.environments, [o, i] = m1(e, e.authenticationDetails); +function h1(e) { + const t = e.runtimeConfiguration, n = e.customizations, r = e.environments, [o, i] = g1(e, e.authenticationDetails); if (i !== void 0) return [void 0, `failed to serialize authentication details: ${i}`]; - const [s, a] = b1(e); + const [s, a] = v1(e); if (a !== void 0) return [void 0, `failed to serialize operations: ${a}`]; - const [l, u] = C1(e, e.requests); + const [l, u] = _1(e, e.requests); if (u !== void 0) return [void 0, `unable to serialize requests: ${u}`]; const [d, h] = yn(e, e.before); @@ -15018,7 +15018,7 @@ function p1(e) { before: Fn(d), after: Fn(f), authenticationDetails: o, - securityProfile: g1(e.securityProfile), + securityProfile: p1(e.securityProfile), authorizationTests: Fn(e.authorizationTests), requests: Fn(l) }, @@ -15028,7 +15028,7 @@ function p1(e) { function Fn(e) { return e instanceof Array ? e.length > 0 ? e : void 0 : Object.keys(e).length > 0 ? e : void 0; } -function g1(e) { +function p1(e) { if (e !== void 0) return { clientCertificate: e.clientCertificate, @@ -15036,20 +15036,20 @@ function g1(e) { caServerCertificate: e.caServerCertificate }; } -function m1(e, t) { +function g1(e, t) { const n = []; for (const r of t) { - const [o, i] = y1(e, r); + const [o, i] = m1(e, r); if (i !== void 0) return [void 0, "xxx"]; n.push(o); } return [n.length === 1 && Object.keys(n[0]).length === 0 ? [] : n, void 0]; } -function y1(e, t) { +function m1(e, t) { const n = {}; for (const [r, o] of Object.entries(t)) { - const [i, s] = v1(e, o.methods); + const [i, s] = y1(e, o.methods); if (s !== void 0) return [void 0, "xxx"]; n[r] = { @@ -15065,7 +15065,7 @@ function y1(e, t) { } return [n, void 0]; } -function v1(e, t) { +function y1(e, t) { const n = {}; for (const [r, o] of Object.entries(t)) { const [i, s] = yn(e, o.requests || []); @@ -15079,21 +15079,21 @@ function v1(e, t) { } return [n, void 0]; } -function b1(e) { +function v1(e) { const t = {}; for (const [n, r] of Object.entries(e.operations)) { - const [o, i] = x1(e, r); + const [o, i] = b1(e, r); if (i !== void 0) return [void 0, `unable to serialize operation '${n}: ${i}'`]; t[n] = o; } return [t, void 0]; } -function x1(e, t) { - const [n, r] = aa(e, t.request, t.operationId); +function b1(e, t) { + const [n, r] = sa(e, t.request, t.operationId); if (r !== void 0) return [void 0, `failed to serialize request: ${r}`]; - const [o, i] = S1(e, t); + const [o, i] = w1(e, t); if (i !== void 0) return [void 0, `failed to serialize scenarios: ${i}`]; const [s, a] = yn(e, t.before); @@ -15113,62 +15113,62 @@ function x1(e, t) { void 0 ]; } -function k1(e, t) { - const [n, r] = ca(e, t.responses); +function x1(e, t) { + const [n, r] = la(e, t.responses); if (r !== void 0) return [void 0, `failed to serialize responses: ${r}`]; - const [o, i] = j1(t.ref); + const [o, i] = C1(t.ref); return i !== void 0 ? [void 0, `failed to serialize responses: ${i}`] : [{ fuzzing: t.fuzzing, $ref: o, - auth: Sf(t.auth), + auth: wf(t.auth), expectedResponse: t.expectedResponse, - environment: la(t.environment), + environment: aa(t.environment), responses: n }, void 0]; } -function aa(e, t, n) { - const [r, o] = E1(e, t.request, n); +function sa(e, t, n) { + const [r, o] = j1(e, t.request, n); if (o !== void 0) return [void 0, `failed to serialize request: ${o}`]; - const [i, s] = ca(e, t.responses); + const [i, s] = la(e, t.responses); return s !== void 0 ? [void 0, `failed to serialize responses: ${s}`] : [{ operationId: n || t.request.operationId, fuzzing: t.fuzzing, - auth: Sf(t.auth), + auth: wf(t.auth), request: r, defaultResponse: t.defaultResponse, - environment: la(t.environment), + environment: aa(t.environment), responses: i }, void 0]; } -function w1(e, t) { - const [n, r] = T1(e, t.request); +function k1(e, t) { + const [n, r] = E1(e, t.request); if (r !== void 0) return [void 0, `failed to serialize request: ${r}`]; - const [o, i] = ca(e, t.responses); + const [o, i] = la(e, t.responses); return i !== void 0 ? [void 0, `failed to serialize responses: ${i}`] : [{ request: n, defaultResponse: t.defaultResponse, - environment: la(t.environment), + environment: aa(t.environment), responses: o }, void 0]; } -function Sf(e) { +function wf(e) { if (!(e === void 0 || e.length === 0)) return e; } -function S1(e, t) { +function w1(e, t) { const n = []; for (const r of t.scenarios) { - const [o, i] = _1(e, r); + const [o, i] = S1(e, r); if (i !== void 0) return [void 0, `unable to serialize scenario: ${i}`]; n.push(o); } return [{ scenarios: n }, void 0]; } -function _1(e, t) { +function S1(e, t) { const [n, r] = yn(e, t.requests); return r !== void 0 ? [void 0, `unable to serialize requests: ${r}`] : [ { @@ -15183,57 +15183,57 @@ function yn(e, t) { const n = []; for (const r of t) if (r.ref === void 0) { - const [o, i] = aa(e, r, r.operationId); + const [o, i] = sa(e, r, r.operationId); if (i !== void 0) return [void 0, `unable to serialize stage: ${i}`]; n.push(o); } else { - const [o, i] = k1(e, r); + const [o, i] = x1(e, r); if (i !== void 0) return [void 0, `unable to serialize stage reference: ${i}`]; n.push(o); } return [n, void 0]; } -function C1(e, t) { +function _1(e, t) { const n = {}; for (const [r, o] of Object.entries(t || {})) if (o.operationId === void 0) { - const [i, s] = w1(e, o); + const [i, s] = k1(e, o); if (s !== void 0) return [void 0, `unable to serialize request: ${s}`]; n[r] = i; } else { - const [i, s] = aa(e, o, o.operationId); + const [i, s] = sa(e, o, o.operationId); if (s !== void 0) return [void 0, `unable to serialize request: ${s}`]; n[r] = i; } return [n, void 0]; } -function j1(e) { - return e.type === "operation" ? ["#" + eo.joinJsonPointer(["operations", e.id, "request"]), void 0] : e.type === "request" ? ["#" + eo.joinJsonPointer(["requests", e.id]), void 0] : [void 0, `Unable to serialize unknown $ref type: ${e}`]; +function C1(e) { + return e.type === "operation" ? ["#" + Re.joinJsonPointer(["operations", e.id, "request"]), void 0] : e.type === "request" ? ["#" + Re.joinJsonPointer(["requests", e.id]), void 0] : [void 0, `Unable to serialize unknown $ref type: ${e}`]; } -function la(e) { +function aa(e) { if (!(e === void 0 || Object.keys(e).length === 0)) return e; } -function E1(e, t, n) { +function j1(e, t, n) { const r = { operationId: n, method: t.method.toUpperCase(), url: `{{host}}${t.path}`, - headers: ht(e, t.parameters.header), - queries: ht(e, t.parameters.query), - paths: ht(e, t.parameters.path), - cookies: ht(e, t.parameters.cookie) + headers: pt(e, t.parameters.header), + queries: pt(e, t.parameters.query), + paths: pt(e, t.parameters.path), + cookies: pt(e, t.parameters.cookie) }; return t.body !== void 0 && (t.body.mediaType === "application/json" ? r.requestBody = { mode: "json", json: t.body.value } : t.body.mediaType === "application/x-www-form-urlencoded" ? r.requestBody = { mode: "urlencoded", - urlencoded: _f(t.body.value) + urlencoded: Sf(t.body.value) } : t.body.mediaType === "raw" && (r.requestBody = { mode: "raw", raw: t.body.value @@ -15245,22 +15245,22 @@ function E1(e, t, n) { void 0 ]; } -function T1(e, t) { +function E1(e, t) { const n = { //operationId: operation.operationId, method: t.method.toUpperCase(), url: t.url, - headers: ht(e, t.parameters.header), - queries: ht(e, t.parameters.query), - paths: ht(e, t.parameters.path), - cookies: ht(e, t.parameters.cookie) + headers: pt(e, t.parameters.header), + queries: pt(e, t.parameters.query), + paths: pt(e, t.parameters.path), + cookies: pt(e, t.parameters.cookie) }; return t.body !== void 0 && (t.body.mediaType === "application/json" ? n.requestBody = { mode: "json", json: t.body.value } : t.body.mediaType === "application/x-www-form-urlencoded" ? n.requestBody = { mode: "urlencoded", - urlencoded: _f(t.body.value) + urlencoded: Sf(t.body.value) } : t.body.mediaType === "raw" && (n.requestBody = { mode: "raw", raw: t.body.value @@ -15272,73 +15272,73 @@ function T1(e, t) { void 0 ]; } -function ca(e, t) { +function la(e, t) { const n = {}, r = Object.entries(t || {}); if (r.length === 0) return [void 0, void 0]; for (const [o, i] of r) n[o] = { expectations: i.expectations, - variableAssignments: O1(i.variableAssignments) + variableAssignments: T1(i.variableAssignments) }; return [n, void 0]; } -function ht(e, t) { +function pt(e, t) { if (t.length !== 0) return t; } -function O1(e) { +function T1(e) { if (Object.keys(e || {}).length !== 0) return e; } -function _f(e) { +function Sf(e) { return Object.entries(e).reduce((t, [n, r]) => (t[n] = { value: r }, t), {}); } -function Cf(e) { +function _f(e) { const t = e.runtimeConfiguration?.environment || "default"; return e.environments[t]; } -function jf(e, t, n) { +function Cf(e, t, n) { const { environment: { env: { host: r } } - } = yr(Cf(e), t); + } = yr(_f(e), t); return r && typeof r == "string" && !n.includes(r) ? [r, ...n] : [...n]; } -function P1(e, t) { +function O1(e, t) { if (e.operations !== void 0) for (const n of Object.keys(e?.operations)) n !== t && (e.operations[n].scenarios = [], e.operations[n].before = [], e.operations[n].after = [], e.operations[n].customTests = [], e.operations[n].authorizationTests = []); return JSON.stringify(e, null, 2); } -function $1(e, t, n, r, o) { +function P1(e, t, n, r, o) { return t === "api-token" && n == "docker" && r && (o === "darwin" || o === "win32") && (e.toLowerCase().startsWith("https://localhost") || e.toLowerCase().startsWith("http://localhost")) ? e.replace(/localhost/i, "host.docker.internal") : e; } -function ua({ +function ca({ path: e, method: t, operationId: n, children: r }) { - return /* @__PURE__ */ c.jsxs(D1, { children: [ - n && /* @__PURE__ */ c.jsxs(z1, { children: [ + return /* @__PURE__ */ c.jsxs($1, { children: [ + n && /* @__PURE__ */ c.jsxs(D1, { children: [ n, - /* @__PURE__ */ c.jsx(Xh, {}) + /* @__PURE__ */ c.jsx(Gh, {}) ] }), - /* @__PURE__ */ c.jsxs(I1, { children: [ - /* @__PURE__ */ c.jsx(A1, { children: t }), - /* @__PURE__ */ c.jsx(N1, { children: e }) + /* @__PURE__ */ c.jsxs(z1, { children: [ + /* @__PURE__ */ c.jsx(I1, { children: t }), + /* @__PURE__ */ c.jsx(A1, { children: e }) ] }), r ] }); } -const D1 = E.div` +const $1 = E.div` display: flex; flex-direction: column; gap: 8px; line-break: anywhere; -`, z1 = E.div` +`, D1 = E.div` font-size: 14px; font-weight: 600; display: flex; @@ -15346,10 +15346,10 @@ const D1 = E.div` > svg { fill: var(${w.linkForeground}); } -`, I1 = E.div` +`, z1 = E.div` display: flex; gap: 4px; -`, A1 = E.div` +`, I1 = E.div` background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px; @@ -15360,8 +15360,8 @@ const D1 = E.div` height: 16px; text-transform: uppercase; font-size: 11px; -`, N1 = E.div``; -function Ef({ name: e, variables: t }) { +`, A1 = E.div``; +function jf({ name: e, variables: t }) { const { field: { value: n } } = ie({ @@ -15384,23 +15384,23 @@ function Ef({ name: e, variables: t }) { paragraph: "editor-paragraph" }, onError: r, - nodes: [xt] + nodes: [kt] }; - return /* @__PURE__ */ c.jsx(M1, { children: /* @__PURE__ */ c.jsxs(Vs, { initialConfig: o, children: [ + return /* @__PURE__ */ c.jsx(R1, { children: /* @__PURE__ */ c.jsxs(Hs, { initialConfig: o, children: [ /* @__PURE__ */ c.jsx( - Xs, + Gs, { - contentEditable: /* @__PURE__ */ c.jsx(Ws, {}), + contentEditable: /* @__PURE__ */ c.jsx(Vs, {}), placeholder: /* @__PURE__ */ c.jsx("div", {}), - ErrorBoundary: Ks + ErrorBoundary: Ws } ), - /* @__PURE__ */ c.jsx(Gs, {}), - /* @__PURE__ */ c.jsx(ef, { variables: t }), - /* @__PURE__ */ c.jsx(R1, { name: e }) + /* @__PURE__ */ c.jsx(Ks, {}), + /* @__PURE__ */ c.jsx(Zd, { variables: t }), + /* @__PURE__ */ c.jsx(N1, { name: e }) ] }) }); } -function R1({ name: e }) { +function N1({ name: e }) { const [t] = Ee(), [n, r] = A.useState(void 0), { field: o } = ie({ name: e }); @@ -15416,20 +15416,20 @@ function R1({ name: e }) { }, 500); } }); - }, [t, o]), n === void 0 ? /* @__PURE__ */ c.jsxs(_c, { children: [ + }, [t, o]), n === void 0 ? /* @__PURE__ */ c.jsxs(Sc, { children: [ "Valid JSON", /* @__PURE__ */ c.jsx( - Jc, + Qc, { style: { fill: `var(${w.foreground})` } } ) - ] }) : /* @__PURE__ */ c.jsxs(_c, { $error: !0, children: [ + ] }) : /* @__PURE__ */ c.jsxs(Sc, { $error: !0, children: [ n, /* @__PURE__ */ c.jsx( - xo, + bo, { style: { fill: `var(${w.errorForeground})` @@ -15438,7 +15438,7 @@ function R1({ name: e }) { ) ] }); } -const M1 = E.div` +const R1 = E.div` color: var(${w.foreground}); background-color: var(${w.background}); border: 1px solid var(${w.border}); @@ -15461,7 +15461,7 @@ const M1 = E.div` .editor-paragraph { margin: 0; } -`, _c = E.div` +`, Sc = E.div` display: flex; align-items: center; justify-content: flex-end; @@ -15472,7 +15472,7 @@ const M1 = E.div` color: ${({ $error: e }) => e ? `var(${w.errorForeground})` : `var(${w.foreground})`}; background-color: ${({ $error: e }) => e ? `var(${w.errorBackground})` : `var(${w.background})`}; `; -function L1({ +function M1({ name: e, password: t }) { @@ -15481,21 +15481,21 @@ function L1({ }); return /* @__PURE__ */ c.jsx("input", { ...n, type: t ? "password" : "text" }); } -function Cc({ +function _c({ name: e, variables: t }) { const { fields: n, append: r, remove: o } = vn({ name: e }); - return /* @__PURE__ */ c.jsx(B1, { children: /* @__PURE__ */ c.jsxs(U1, { children: [ - /* @__PURE__ */ c.jsxs(V1, { children: [ + return /* @__PURE__ */ c.jsx(q1, { children: /* @__PURE__ */ c.jsxs(B1, { children: [ + /* @__PURE__ */ c.jsxs(H1, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", { children: "Value" }), /* @__PURE__ */ c.jsx("div", {}) ] }), - /* @__PURE__ */ c.jsx(H1, { children: n.map((i, s) => /* @__PURE__ */ c.jsx( - W1, + /* @__PURE__ */ c.jsx(U1, { children: n.map((i, s) => /* @__PURE__ */ c.jsx( + V1, { name: `${e}.${s}`, variables: t, @@ -15505,12 +15505,12 @@ function Cc({ }, i.id )) }), - /* @__PURE__ */ c.jsx(F1, { append: r }) + /* @__PURE__ */ c.jsx(L1, { append: r }) ] }) }); } -function F1({ append: e }) { +function L1({ append: e }) { return /* @__PURE__ */ c.jsx( - q1, + F1, { placeholder: "name", value: "", @@ -15520,7 +15520,7 @@ function F1({ append: e }) { } ); } -const q1 = E.input` +const F1 = E.input` grid-column: span 3; background: transparent; border: none; @@ -15528,16 +15528,16 @@ const q1 = E.input` color: var(${w.foreground}); margin-right: 10px; padding: 4px 8px; -`, B1 = E.div` +`, q1 = E.div` margin: 8px 4px; -`, U1 = E.div` +`, B1 = E.div` margin: 4px; display: grid; row-gap: 4px; grid-template-columns: 1fr 2fr 1em; -`, H1 = E.div` +`, U1 = E.div` display: contents; -`, V1 = E.div` +`, H1 = E.div` display: contents; & > div { padding: 4px 8px; @@ -15547,16 +15547,16 @@ const q1 = E.input` font-weight: 600; } `; -function W1({ +function V1({ name: e, variables: t, remove: n }) { - return /* @__PURE__ */ c.jsxs(G1, { children: [ - /* @__PURE__ */ c.jsx(L1, { name: `${e}.key` }), - /* @__PURE__ */ c.jsx(Bo, { name: `${e}.value`, variables: t }), + return /* @__PURE__ */ c.jsxs(K1, { children: [ + /* @__PURE__ */ c.jsx(M1, { name: `${e}.key` }), + /* @__PURE__ */ c.jsx(qo, { name: `${e}.value`, variables: t }), /* @__PURE__ */ c.jsx( - K1, + W1, { onClick: (r) => { r.preventDefault(), r.stopPropagation(), n(); @@ -15566,7 +15566,7 @@ function W1({ ) ] }); } -const K1 = E.button` +const W1 = E.button` background: none; border: none; padding: 0; @@ -15579,7 +15579,7 @@ const K1 = E.button` > svg { fill: var(${w.foreground}); } -`, G1 = E.div` +`, K1 = E.div` display: contents; > input, > div { @@ -15593,75 +15593,75 @@ const K1 = E.button` visibility: visible; } `; -function X1({ +function G1({ requestRef: e, stage: t, saveRequest: n, defaultCollapsed: r, variables: o }) { - const i = Q1(t); - return /* @__PURE__ */ c.jsx(Tf, { children: /* @__PURE__ */ c.jsx( + const i = Y1(t); + return /* @__PURE__ */ c.jsx(Ef, { children: /* @__PURE__ */ c.jsx( xn, { data: t, saveData: n, - wrapFormData: cw, - unwrapFormData: hw, + wrapFormData: lw, + unwrapFormData: fw, children: /* @__PURE__ */ c.jsxs(wn, { defaultCollapsed: r, children: [ - /* @__PURE__ */ c.jsxs(Hc, { children: [ + /* @__PURE__ */ c.jsxs(Uc, { children: [ /* @__PURE__ */ c.jsx("span", { children: e.id }), - /* @__PURE__ */ c.jsxs(tS, { children: [ + /* @__PURE__ */ c.jsxs(eS, { children: [ /* @__PURE__ */ c.jsx("span", { children: "Default Response" }), - /* @__PURE__ */ c.jsx(tf, { name: "defaultResponse", options: i }) + /* @__PURE__ */ c.jsx(ef, { name: "defaultResponse", options: i }) ] }) ] }), /* @__PURE__ */ c.jsxs(Sn, { children: [ - /* @__PURE__ */ c.jsx(eS, { children: t.request.method }), - /* @__PURE__ */ c.jsx(Z1, { onClick: (s) => s.stopPropagation(), children: /* @__PURE__ */ c.jsx(Bo, { variables: o, name: "url" }) }) + /* @__PURE__ */ c.jsx(Z1, { children: t.request.method }), + /* @__PURE__ */ c.jsx(J1, { onClick: (s) => s.stopPropagation(), children: /* @__PURE__ */ c.jsx(qo, { variables: o, name: "url" }) }) ] }), - /* @__PURE__ */ c.jsx(Y1, { stage: t, variables: o }) + /* @__PURE__ */ c.jsx(X1, { stage: t, variables: o }) ] }) } ) }); } -function Y1({ +function X1({ stage: e, variables: t }) { - return /* @__PURE__ */ c.jsx(Tf, { children: /* @__PURE__ */ c.jsx( + return /* @__PURE__ */ c.jsx(Ef, { children: /* @__PURE__ */ c.jsx( kn, { tabs: [ { id: "body", title: "Body", - content: /* @__PURE__ */ c.jsx(Ef, { variables: t, name: "body.value" }), + content: /* @__PURE__ */ c.jsx(jf, { variables: t, name: "body.value" }), disabled: e.request.body === void 0 }, { id: "query", title: "Query", - content: /* @__PURE__ */ c.jsx(Cc, { name: "parameters.query", variables: t }) + content: /* @__PURE__ */ c.jsx(_c, { name: "parameters.query", variables: t }) }, { id: "header", title: "Headers", - content: /* @__PURE__ */ c.jsx(Cc, { name: "parameters.header", variables: t }) + content: /* @__PURE__ */ c.jsx(_c, { name: "parameters.header", variables: t }) }, { id: "responses", title: "Response processing", - content: /* @__PURE__ */ c.jsx(us, { editable: !0, responseCodes: J1 }) + content: /* @__PURE__ */ c.jsx(cs, { editable: !0, responseCodes: Q1 }) } ] } ) }); } -function Q1(e) { +function Y1(e) { return Object.keys(e.responses || {}).map((t) => ({ label: t, value: t })); } -const J1 = [ +const Q1 = [ "100", "101", "200", @@ -15703,15 +15703,15 @@ const J1 = [ "503", "504", "505" -], Tf = E.div` +], Ef = E.div` > div { background-color: var(${w.background}); } -`, Z1 = E.div` +`, J1 = E.div` flex: 1; background-color: var(${w.background}); border: 1px solid var(${w.border}); -`, eS = E.div` +`, Z1 = E.div` background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px; @@ -15722,7 +15722,7 @@ const J1 = [ height: 16px; text-transform: uppercase; font-size: 11px; -`, tS = E.div` +`, eS = E.div` display: flex; flex-direction: row; gap: 4px; @@ -15735,7 +15735,7 @@ const J1 = [ border: 1px solid var(${w.border}); } `; -function Wj({ +function Vj({ request: e, requestRef: t }) { @@ -15743,10 +15743,10 @@ function Wj({ tryResult: r, mockResult: o, mockMissingVariables: i - } = xe((v) => v.requests), s = lt(), { playbook: a, servers: l } = xe((v) => v.scanconf), u = xe((v) => v.env.data), d = (v, b) => s(ku({ server: v, inputs: b })), h = (v) => s(pu({ ref: t, stage: v })), f = tn(o, "Global Before"), p = tn(o, "Global After"), g = tn(o, "Request"), m = [ - ...Bc, - ...lS(g?.results?.[0]?.variablesReplaced?.stack || []) - ], [y, x] = A.useState({}), k = jf(a, u, l); + } = xe((v) => v.requests), s = ct(), { playbook: a, servers: l } = xe((v) => v.scanconf), u = xe((v) => v.env.data), d = (v, b) => s(xu({ server: v, inputs: b })), h = (v) => s(hu({ ref: t, stage: v })), f = tn(o, "Global Before"), p = tn(o, "Global After"), g = tn(o, "Request"), m = [ + ...qc, + ...aS(g?.results?.[0]?.variablesReplaced?.stack || []) + ], [y, x] = A.useState({}), k = Cf(a, u, l); return A.useEffect(() => { const v = { ...y }; for (const b of Object.keys(v)) @@ -15754,9 +15754,9 @@ function Wj({ for (const b of i) v[b] === void 0 && (v[b] = ""); x(v); - }, [i]), /* @__PURE__ */ c.jsxs(nS, { children: [ + }, [i]), /* @__PURE__ */ c.jsxs(tS, { children: [ /* @__PURE__ */ c.jsx( - nf, + tf, { servers: k, onTry: (v) => d(v, y), @@ -15765,7 +15765,7 @@ function Wj({ ), /* @__PURE__ */ c.jsxs(Yn, { title: "Request", children: [ /* @__PURE__ */ c.jsx( - X1, + G1, { defaultCollapsed: !1, variables: m, @@ -15774,44 +15774,44 @@ function Wj({ saveRequest: h } ), - /* @__PURE__ */ c.jsxs(aS, { children: [ + /* @__PURE__ */ c.jsxs(sS, { children: [ "Unset variables", /* @__PURE__ */ c.jsx(bn, { children: "Enter values for these unset variables to 'Try' the Operation. Note that these values will not be persisted in the Scan configuration." }) ] }), - /* @__PURE__ */ c.jsx(sS, { children: /* @__PURE__ */ c.jsx( + /* @__PURE__ */ c.jsx(iS, { children: /* @__PURE__ */ c.jsx( xn, { - wrapFormData: rS, - unwrapFormData: oS, + wrapFormData: nS, + unwrapFormData: rS, data: y, saveData: (v) => x(v), - children: /* @__PURE__ */ c.jsx(Uo, { name: "env" }) + children: /* @__PURE__ */ c.jsx(Bo, { name: "env" }) } ) }) ] }), - n && f?.status === "failure" && /* @__PURE__ */ c.jsx(jc, { children: /* @__PURE__ */ c.jsx(no, { message: "Check Global Before block" }) }), - n && p?.status === "failure" && /* @__PURE__ */ c.jsx(jc, { children: /* @__PURE__ */ c.jsx(no, { message: "Check Global After block" }) }), - r.length > 0 && /* @__PURE__ */ c.jsx(Yn, { title: "Result", children: /* @__PURE__ */ c.jsx(Ru, { result: r, collapsible: n }) }) + n && f?.status === "failure" && /* @__PURE__ */ c.jsx(Cc, { children: /* @__PURE__ */ c.jsx(to, { message: "Check Global Before block" }) }), + n && p?.status === "failure" && /* @__PURE__ */ c.jsx(Cc, { children: /* @__PURE__ */ c.jsx(to, { message: "Check Global After block" }) }), + r.length > 0 && /* @__PURE__ */ c.jsx(Yn, { title: "Result", children: /* @__PURE__ */ c.jsx(Nu, { result: r, collapsible: n }) }) ] }); } -const nS = E.div` +const tS = E.div` padding: 8px; -`, jc = E.div` +`, Cc = E.div` margin-top: 8px; margin-bottom: 8px; `; -function rS(e) { +function nS(e) { return { env: Object.entries(e).map(([t, n]) => ({ key: t, value: n, type: typeof n })) }; } -function oS(e) { +function rS(e) { const t = {}; for (const { key: n, value: r, type: o } of e.env) - t[n] = iS(r, o); + t[n] = oS(r, o); return t; } -function iS(e, t) { +function oS(e, t) { if (t !== "string") try { return JSON.parse(e); @@ -15820,10 +15820,10 @@ function iS(e, t) { } return `${e}`; } -const sS = E.div` +const iS = E.div` border: 1px solid var(${w.border}); background-color: var(${w.background}); -`, aS = E.div` +`, sS = E.div` display: flex; padding-top: 12px; padding-bottom: 12px; @@ -15832,15 +15832,15 @@ const sS = E.div` cursor: pointer; align-items: center; `; -function lS(e) { +function aS(e) { const t = []; for (const n of e) for (const r of Object.keys(n.env)) t.includes(r) || t.push(r); return t.sort(), t; } -const cS = { type: "string" }; -function uS({ +const lS = { type: "string" }; +function cS({ name: e, schema: t, onDelete: n, @@ -15850,22 +15850,22 @@ function uS({ const { fieldState: { error: i } } = ie({ name: `${e}.value` }), { field: s } = ie({ name: `${e}.key` }); - return /* @__PURE__ */ c.jsxs(dS, { children: [ - /* @__PURE__ */ c.jsxs(hS, { children: [ + return /* @__PURE__ */ c.jsxs(uS, { children: [ + /* @__PURE__ */ c.jsxs(fS, { children: [ s.value, !o && /* @__PURE__ */ c.jsx(bn, { icon: "exclamation", children: "Parameter is not defined in the OpenAPI specification for this API" }) ] }), /* @__PURE__ */ c.jsx( - Bo, + qo, { name: `${e}.value`, variables: r, - encode: (a) => gS(t || cS, a), - decode: (a) => mS(t, a) + encode: (a) => pS(t || lS, a), + decode: (a) => gS(t, a) } ), /* @__PURE__ */ c.jsx( - pS, + hS, { onClick: (a) => { a.preventDefault(), a.stopPropagation(), n(); @@ -15874,20 +15874,20 @@ function uS({ } ), i && /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsxs(fS, { children: [ - /* @__PURE__ */ c.jsx(wt, {}), + /* @__PURE__ */ c.jsxs(dS, { children: [ + /* @__PURE__ */ c.jsx(St, {}), /* @__PURE__ */ c.jsx("span", { children: i.message }) ] }), /* @__PURE__ */ c.jsx("div", {}) ] }) ] }); } -const dS = E.div` +const uS = E.div` display: contents; &:hover > :last-child { opacity: 1; } -`, fS = E.div` +`, dS = E.div` color: var(${w.errorForeground}); background-color: var(${w.errorBackground}); border: none !important; @@ -15898,14 +15898,14 @@ const dS = E.div` display: flex; gap: 4px; grid-column: span 2; -`, hS = E.div` +`, fS = E.div` flex: 1; border-bottom: 1px solid var(${w.border}); margin-right: 10px; display: flex; align-items: center; gap: 4px; -`, pS = E.button` +`, hS = E.button` background: none; border: none; padding: 0; @@ -15919,49 +15919,49 @@ const dS = E.div` fill: var(${w.foreground}); } `; -function gS(e, t) { +function pS(e, t) { if (t === void 0) return ""; const n = e.type; return n === void 0 || n === "string" || n === "number" || n === "integer" || n === "boolean" ? `${t}` : JSON.stringify(t); } -function mS(e, t) { +function gS(e, t) { const n = e?.type || "string"; - if (t.match(oh()) || n === "string") + if (t.match(ch()) || n === "string") return t; if (n === "integer") - return yS(t); + return mS(t); if (n === "number") - return vS(t); + return yS(t); if (n === "boolean") { if (t === "true" || t === "false") return t === "true"; throw new Error("failed to convert to 'boolean'"); } if (n === "object" || n === "array") - return bS(t); + return vS(t); throw new Error(`failed to convert, unsupported type: ${n}`); } -function yS(e) { +function mS(e) { const t = Number.parseInt(e, 10); if (isNaN(t)) throw new Error("failed to convert to 'integer'"); return t; } -function vS(e) { +function yS(e) { const t = Number.parseFloat(e); if (isNaN(t)) throw new Error("failed to convert to 'number'"); return t; } -function bS(e) { +function vS(e) { try { return JSON.parse(e); } catch (t) { throw new Error(`failed to convert: ${t}`); } } -function xS({ +function bS({ options: e, placeholder: t, selected: n, @@ -15973,7 +15973,7 @@ function xS({ e.filter((p) => o === "" || p.toLowerCase().includes(o.toLowerCase())) ); }, [o, e]); - const { isOpen: l, getMenuProps: u, getInputProps: d, getItemProps: h, reset: f } = Gc({ + const { isOpen: l, getMenuProps: u, getInputProps: d, getItemProps: h, reset: f } = Kc({ initialInputValue: n, items: s, onSelectedItemChange: ({ selectedItem: p }) => { @@ -15984,9 +15984,9 @@ function xS({ }, itemToString: (p) => p || "" }); - return /* @__PURE__ */ c.jsxs(kS, { children: [ + return /* @__PURE__ */ c.jsxs(xS, { children: [ /* @__PURE__ */ c.jsx( - wS, + kS, { ...d({ onKeyDown: (p) => { @@ -15996,7 +15996,7 @@ function xS({ placeholder: t } ), - /* @__PURE__ */ c.jsx(SS, { $visible: l && (s.length > 0 || o.length > 0), children: /* @__PURE__ */ c.jsxs(_S, { ...u(), children: [ + /* @__PURE__ */ c.jsx(wS, { $visible: l && (s.length > 0 || o.length > 0), children: /* @__PURE__ */ c.jsxs(SS, { ...u(), children: [ s.map((p, g) => /* @__PURE__ */ c.jsx( "li", { @@ -16020,14 +16020,14 @@ function xS({ ] }) }) ] }); } -const kS = E.div` +const xS = E.div` display: flex; flex-direction: column; &:focus-within { border: 1px solid var(${w.focusBorder}); } border: 1px solid transparent; -`, wS = E.input` +`, kS = E.input` background: transparent; border: none; color: var(${w.foreground}); @@ -16037,11 +16037,11 @@ const kS = E.div` &:focus { outline: none; } -`, SS = E.div` +`, wS = E.div` position: relative; z-index: 1; visibility: ${({ $visible: e }) => e ? "visible" : "hidden"}; -`, _S = E.ul` +`, SS = E.ul` border: 1px solid var(${w.dropdownBorder}); background-color: var(${w.dropdownBackground}); color: var(${w.dropdownForeground}); @@ -16059,22 +16059,22 @@ const kS = E.div` background-color: var(${w.listHoverBackground}); } `; -function CS({ +function _S({ name: e, group: t, onSelection: n, placeholder: r, allowUnknown: o }) { - const i = vo({ name: e }), s = Object.keys(t), a = i.map(({ key: d }) => d), l = Object.entries(t).map(([d, h]) => ({ + const i = yo({ name: e }), s = Object.keys(t), a = i.map(({ key: d }) => d), l = Object.entries(t).map(([d, h]) => ({ name: d, - isArray: jS(h) + isArray: CS(h) })).filter(({ isArray: d }) => d).map(({ name: d }) => d), u = s.filter( (d) => l.includes(d) || !a.includes(d) ); - return /* @__PURE__ */ c.jsx(ES, { children: /* @__PURE__ */ c.jsxs("div", { children: [ + return /* @__PURE__ */ c.jsx(jS, { children: /* @__PURE__ */ c.jsxs("div", { children: [ o && /* @__PURE__ */ c.jsx( - xS, + bS, { placeholder: r, options: s.filter((d) => u.includes(d)), @@ -16099,10 +16099,10 @@ function CS({ ) ] }) }); } -function jS(e) { +function CS(e) { return "type" in e && e.type === "array" || "schema" in e && e.schema?.type === "array"; } -const ES = E.div` +const jS = E.div` display: flex; margin-right: 10px; > div { @@ -16122,26 +16122,26 @@ function Dt({ }), u = async (d, h) => { a({ key: d, value: "" }, { shouldFocus: !0 }); }; - return /* @__PURE__ */ c.jsxs(zS, { children: [ - /* @__PURE__ */ c.jsxs(IS, { children: [ + return /* @__PURE__ */ c.jsxs(DS, { children: [ + /* @__PURE__ */ c.jsxs(zS, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", { children: "Value" }), /* @__PURE__ */ c.jsx("div", {}) ] }), - /* @__PURE__ */ c.jsxs(AS, { children: [ + /* @__PURE__ */ c.jsxs(IS, { children: [ s.map((d, h) => /* @__PURE__ */ c.jsx( - uS, + cS, { name: `${t}.${h}`, - schema: OS(e, n, d.key), + schema: TS(e, n, d.key), onDelete: () => l(h), variables: o, - isDefinedInOpenAPI: TS(n, d.key) + isDefinedInOpenAPI: ES(n, d.key) }, d.id )), /* @__PURE__ */ c.jsx( - CS, + _S, { placeholder: r, name: t, @@ -16153,36 +16153,36 @@ function Dt({ ] }) ] }); } -function TS(e, t) { +function ES(e, t) { return e[t] !== void 0; } -function OS(e, t, n) { +function TS(e, t, n) { if (t[n]) { const r = t[n]; - return PS(r) ? DS(e, r) : $S(r); + return OS(r) ? $S(e, r) : PS(r); } } -function PS(e) { +function OS(e) { return "type" in e && e.type === "array" || "schema" in e && e.schema?.type === "array"; } -function $S(e) { +function PS(e) { if ("schema" in e) return e.schema; if ("type" in e) return e; } -function DS(e, t) { +function $S(e, t) { if ("schema" in t && t.schema?.type === "array") return Xn(e, t.schema.items); if ("type" in t && t.type === "array") return Xn(e, t.items); } -const zS = E.div` +const DS = E.div` padding: 8px; display: grid; row-gap: 4px; grid-template-columns: 1fr 2fr 1em; -`, IS = E.div` +`, zS = E.div` display: contents; & > div { padding: 4px 8px; @@ -16191,7 +16191,7 @@ const zS = E.div` font-size: 90%; font-weight: 600; } -`, AS = E.div` +`, IS = E.div` display: contents; & > div > div { padding: 4px 8px; @@ -16205,15 +16205,15 @@ const zS = E.div` // grid-column: span 3; // } `; +function AS(e, t, n) { + const r = Ac(e, e.paths[t]), o = ar(e, t, n), i = Nc(e, o); + return Rc(e, r, i); +} function NS(e, t, n) { - const r = Nc(e, e.paths[t]), o = sr(e, t, n), i = Rc(e, o); - return Mc(e, r, i); + return (ar(e, t, n)?.security ?? e.security ?? []).length > 0; } function RS(e, t, n) { - return (sr(e, t, n)?.security ?? e.security ?? []).length > 0; -} -function MS(e, t, n) { - const o = sr(e, t, n)?.security ?? e.security ?? [], i = []; + const o = ar(e, t, n)?.security ?? e.security ?? [], i = []; for (const s of o) { const a = {}; for (const l of Object.keys(s)) @@ -16222,17 +16222,17 @@ function MS(e, t, n) { } return i; } -function LS({ +function MS({ scheme: e, schemeName: t, credentials: n, value: r, onChange: o }) { - const i = lt(), a = BS(n).filter( - ({ credential: l }) => ea(l, e) + const i = ct(), a = qS(n).filter( + ({ credential: l }) => Zs(l, e) ).map(({ name: l }) => ({ label: l, value: l })); - return /* @__PURE__ */ c.jsx(FS, { children: /* @__PURE__ */ c.jsx( + return /* @__PURE__ */ c.jsx(LS, { children: /* @__PURE__ */ c.jsx( Cn, { placeholder: "", @@ -16240,21 +16240,21 @@ function LS({ selected: r, onSelectedItemChange: (l) => l && o(l.value), bottomMenu: /* @__PURE__ */ c.jsxs( - qS, + FS, { onClick: (l) => { - l.stopPropagation(), l.preventDefault(), i(Jf(["scanconf", "auth"])); + l.stopPropagation(), l.preventDefault(), i(Qf(["scanconf", "auth"])); }, children: [ "Manage authentication ", - /* @__PURE__ */ c.jsx(Xc, {}) + /* @__PURE__ */ c.jsx(Gc, {}) ] } ) } ) }); } -const FS = E.div``, qS = E.li` +const LS = E.div``, FS = E.li` color: var(${w.linkForeground}); &:hover { color: var(${w.linkActiveForeground}); @@ -16265,10 +16265,10 @@ const FS = E.div``, qS = E.li` height: 10px; } `; -function BS(e) { +function qS(e) { return Object.entries(e).map(([t, n]) => Object.entries(n.methods || {}).map(([r, o]) => ({ name: n.default === r ? t : `${t}/${r}`, credential: n }))).flat(); } -function US({ +function BS({ requirement: e, credentials: t, values: n, @@ -16276,14 +16276,14 @@ function US({ }) { return /* @__PURE__ */ c.jsx(c.Fragment, { children: Object.keys(e).sort().map((o) => { const i = e[o]; - return /* @__PURE__ */ c.jsxs(HS, { children: [ - /* @__PURE__ */ c.jsxs(VS, { children: [ + return /* @__PURE__ */ c.jsxs(US, { children: [ + /* @__PURE__ */ c.jsxs(HS, { children: [ 'Credential for "', o, '"' ] }), /* @__PURE__ */ c.jsx( - LS, + MS, { value: n[o], scheme: i, @@ -16298,13 +16298,13 @@ function US({ ] }, o); }) }); } -const HS = E.div` +const US = E.div` display: contents; -`, VS = E.div` +`, HS = E.div` display: flex; align-items: center; `; -function WS({ +function VS({ security: e, value: t, setValue: n @@ -16313,8 +16313,8 @@ function WS({ value: i, label: Object.keys(o).sort().join(", ") })); - return /* @__PURE__ */ c.jsxs(KS, { children: [ - /* @__PURE__ */ c.jsx(GS, { children: "Security scheme(s)" }), + return /* @__PURE__ */ c.jsxs(WS, { children: [ + /* @__PURE__ */ c.jsx(KS, { children: "Security scheme(s)" }), /* @__PURE__ */ c.jsx("div", { children: /* @__PURE__ */ c.jsx( Cn, { @@ -16325,32 +16325,32 @@ function WS({ ) }) ] }); } -const KS = E.div` +const WS = E.div` display: contents; -`, GS = E.div` +`, KS = E.div` display: flex; align-items: center; `; -function Of({ +function Tf({ oas: e, security: t, credentials: n }) { const { field: r } = ie({ name: "auth" - }), o = JS(t, n, r.value), i = o.reduce( + }), o = QS(t, n, r.value), i = o.reduce( (l, u) => l.relevance > u.relevance ? l : u ), [s, a] = A.useState( i.requirementIndex ); - return /* @__PURE__ */ c.jsxs(XS, { children: [ - /* @__PURE__ */ c.jsxs(YS, { children: [ + return /* @__PURE__ */ c.jsxs(GS, { children: [ + /* @__PURE__ */ c.jsxs(XS, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", { children: "Value" }) ] }), - /* @__PURE__ */ c.jsxs(QS, { children: [ + /* @__PURE__ */ c.jsxs(YS, { children: [ /* @__PURE__ */ c.jsx( - WS, + VS, { security: t, value: s, @@ -16360,7 +16360,7 @@ function Of({ } ), /* @__PURE__ */ c.jsx( - US, + BS, { requirement: t[s], credentials: n, @@ -16374,11 +16374,11 @@ function Of({ ] }) ] }); } -const XS = E.div` +const GS = E.div` margin: 8px; display: grid; grid-template-columns: 1fr 2fr; -`, YS = E.div` +`, XS = E.div` display: contents; & > div { padding: 4px 8px; @@ -16387,17 +16387,17 @@ const XS = E.div` font-size: 90%; font-weight: 600; } -`, QS = E.div` +`, YS = E.div` display: contents; & > div > div { padding: 4px 8px; border-bottom: 1px solid var(${w.border}); } `; -function JS(e, t, n) { - const r = ZS(t, n); +function QS(e, t, n) { + const r = JS(t, n); return e.map((o, i) => { - const s = t_(o, r), a = Object.keys(o).length, l = Object.keys(s).length; + const s = e_(o, r), a = Object.keys(o).length, l = Object.keys(s).length; return { requirementIndex: i, matches: s, @@ -16405,15 +16405,15 @@ function JS(e, t, n) { }; }); } -function ZS(e, t) { +function JS(e, t) { const n = {}; for (const r of t) { - const o = e_(e, r); + const o = ZS(e, r); o !== void 0 && (n[r] = o); } return n; } -function e_(e, t) { +function ZS(e, t) { for (const [n, r] of Object.entries(e)) { if (n === t) return r; @@ -16422,17 +16422,17 @@ function e_(e, t) { return r; } } -function t_(e, t) { +function e_(e, t) { const n = { ...t }, r = {}; for (const [o, i] of Object.entries(e)) for (const [s, a] of Object.entries(n)) - if (ea(a, i)) { + if (Zs(a, i)) { r[o] = s, delete n[s]; break; } return r; } -function n_({ name: e, readOnly: t }) { +function t_({ name: e, readOnly: t }) { const { field: { value: n } } = ie({ name: e }); @@ -16454,22 +16454,22 @@ function n_({ name: e, readOnly: t }) { paragraph: "editor-paragraph" }, onError: r, - nodes: [xt] + nodes: [kt] }; - return /* @__PURE__ */ c.jsx(o_, { children: /* @__PURE__ */ c.jsxs(Vs, { initialConfig: o, children: [ + return /* @__PURE__ */ c.jsx(r_, { children: /* @__PURE__ */ c.jsxs(Hs, { initialConfig: o, children: [ /* @__PURE__ */ c.jsx( - Xs, + Gs, { - contentEditable: /* @__PURE__ */ c.jsx(Ws, {}), + contentEditable: /* @__PURE__ */ c.jsx(Vs, {}), placeholder: /* @__PURE__ */ c.jsx("div", {}), - ErrorBoundary: Ks + ErrorBoundary: Ws } ), - /* @__PURE__ */ c.jsx(Gs, {}), - /* @__PURE__ */ c.jsx(r_, { name: e }) + /* @__PURE__ */ c.jsx(Ks, {}), + /* @__PURE__ */ c.jsx(n_, { name: e }) ] }) }); } -function r_({ name: e }) { +function n_({ name: e }) { const [t] = Ee(), { field: n } = ie({ name: e }); @@ -16477,7 +16477,7 @@ function r_({ name: e }) { n.onChange(r); }), [t, n]), null; } -const o_ = E.div` +const r_ = E.div` color: var(${w.foreground}); background-color: var(${w.background}); border: 1px solid var(${w.border}); @@ -16501,7 +16501,7 @@ const o_ = E.div` margin: 0; } `; -function i_({ +function o_({ oas: e, requestBody: t, variables: n @@ -16509,65 +16509,65 @@ function i_({ const { field: { value: r } } = ie({ name: "body.mediaType" }); - return t === void 0 ? null : /* @__PURE__ */ c.jsxs(s_, { children: [ - r === "raw" && /* @__PURE__ */ c.jsx(n_, { name: "body.value" }), - r !== "raw" && /* @__PURE__ */ c.jsx(Ef, { variables: n, name: "body.value" }) + return t === void 0 ? null : /* @__PURE__ */ c.jsxs(i_, { children: [ + r === "raw" && /* @__PURE__ */ c.jsx(t_, { name: "body.value" }), + r !== "raw" && /* @__PURE__ */ c.jsx(jf, { variables: n, name: "body.value" }) ] }); } -const s_ = E.div` +const i_ = E.div` margin: 8px; gap: 8px; display: flex; flex-flow: column; `; -function Ec(e) { +function jc(e) { return JSON.stringify(e, null, 2); } -function Tc(e) { +function Ec(e) { try { return JSON.parse(e); } catch (t) { return new Error(`failed to convert: ${t}`); } } -function a_({ +function s_({ oas: e, group: t, variables: n }) { - const { control: r } = ar(), { + const { control: r } = sr(), { field: o, fieldState: { error: i } } = ie({ name: "body.value", control: r, rules: { - validate: (l) => u_(l) + validate: (l) => c_(l) } - }), [s, a] = A.useState(Ec(o.value)); + }), [s, a] = A.useState(jc(o.value)); return A.useEffect(() => { - o.value instanceof Error || JSON.stringify(Tc(s)) !== JSON.stringify(o.value) && a(Ec(o.value)); - }, [o.value, s]), /* @__PURE__ */ c.jsxs(l_, { children: [ + o.value instanceof Error || JSON.stringify(Ec(s)) !== JSON.stringify(o.value) && a(jc(o.value)); + }, [o.value, s]), /* @__PURE__ */ c.jsxs(a_, { children: [ /* @__PURE__ */ c.jsx( "textarea", { rows: 10, onChange: (l) => { - o.onChange(Tc(l.target.value)), a(l.target.value); + o.onChange(Ec(l.target.value)), a(l.target.value); }, onBlur: o.onBlur, value: s, ref: o.ref } ), - i && /* @__PURE__ */ c.jsxs(c_, { children: [ - /* @__PURE__ */ c.jsx(wt, {}), + i && /* @__PURE__ */ c.jsxs(l_, { children: [ + /* @__PURE__ */ c.jsx(St, {}), " ", i.message ] }) ] }); } -const l_ = E.div` +const a_ = E.div` margin: 8px; gap: 8px; display: flex; @@ -16579,7 +16579,7 @@ const l_ = E.div` border: 1px solid var(${w.border}); padding: 4px; } -`, c_ = E.div` +`, l_ = E.div` display: flex; align-items: center; color: var(${w.errorForeground}); @@ -16590,11 +16590,11 @@ const l_ = E.div` display: flex; margin: 4px 0; `; -function u_(e) { +function c_(e) { if (e instanceof Error) return e.message; } -function d_({ +function u_({ oas: e, path: t, method: n, @@ -16602,33 +16602,33 @@ function d_({ settings: o, availableVariables: i }) { - const { getValues: s } = ar(), a = s("body") !== void 0, l = Lc(e) ? f_(e, r, t, n, i, a) : h_(e, r, t, n, i, a); + const { getValues: s } = sr(), a = s("body") !== void 0, l = Mc(e) ? d_(e, r, t, n, i, a) : f_(e, r, t, n, i, a); return /* @__PURE__ */ c.jsx(kn, { tabs: l }); } -function f_(e, t, n, r, o, i) { - const s = ih(e, n, r), a = Zi(e, n, r), l = Xn( +function d_(e, t, n, r, o, i) { + const s = uh(e, n, r), a = Ji(e, n, r), l = Xn( e, a?.requestBody - ), u = vo({ name: "parameters" }); + ), u = yo({ name: "parameters" }); return [ { id: "body", title: "Body", - content: /* @__PURE__ */ c.jsx(i_, { oas: e, requestBody: l, variables: o }), + content: /* @__PURE__ */ c.jsx(o_, { oas: e, requestBody: l, variables: o }), disabled: l === void 0 || !i }, { id: "security", title: "Auth", content: /* @__PURE__ */ c.jsx( - Of, + Tf, { oas: e, credentials: t, - security: sh(e, n, r) + security: dh(e, n, r) } ), - disabled: !aw(e, n, r) + disabled: !sw(e, n, r) }, { id: "path", @@ -16693,36 +16693,36 @@ function f_(e, t, n, r, o, i) { { id: "environment", title: "Environment", - content: /* @__PURE__ */ c.jsx(Uo, { name: "environment", variables: o }) + content: /* @__PURE__ */ c.jsx(Bo, { name: "environment", variables: o }) }, { id: "responses", title: "Response processing", - content: /* @__PURE__ */ c.jsx(us, {}) + content: /* @__PURE__ */ c.jsx(cs, {}) } ]; } -function h_(e, t, n, r, o, i) { - const s = NS(e, n, r), a = vo({ name: "parameters" }); +function f_(e, t, n, r, o, i) { + const s = AS(e, n, r), a = yo({ name: "parameters" }); return [ { id: "body", title: "Body", - content: /* @__PURE__ */ c.jsx(a_, { oas: e, group: s.body, variables: o }), + content: /* @__PURE__ */ c.jsx(s_, { oas: e, group: s.body, variables: o }), disabled: an(s.body, a.body) || !i }, { id: "security", title: "Auth", content: /* @__PURE__ */ c.jsx( - Of, + Tf, { oas: e, credentials: t, - security: MS(e, n, r) + security: RS(e, n, r) } ), - disabled: !RS(e, n, r) + disabled: !NS(e, n, r) }, // multipart form-data are not supported for now // { @@ -16787,19 +16787,19 @@ function h_(e, t, n, r, o, i) { { id: "environment", title: "Environment", - content: /* @__PURE__ */ c.jsx(Uo, { name: "environment", variables: o }) + content: /* @__PURE__ */ c.jsx(Bo, { name: "environment", variables: o }) }, { id: "responses", title: "Response processing", - content: /* @__PURE__ */ c.jsx(us, {}) + content: /* @__PURE__ */ c.jsx(cs, {}) } ]; } function an(e, t) { return (e === void 0 || Object.keys(e).length === 0) && (t === void 0 || t.length === 0); } -function p_({ +function h_({ oas: e, requestRef: t, stage: n, @@ -16808,28 +16808,28 @@ function p_({ defaultCollapsed: i, availableVariables: s }) { - const a = g_(n); - return /* @__PURE__ */ c.jsx(m_, { children: /* @__PURE__ */ c.jsx( + const a = p_(n); + return /* @__PURE__ */ c.jsx(g_, { children: /* @__PURE__ */ c.jsx( xn, { data: n, saveData: o, - wrapFormData: lw, - unwrapFormData: fw, + wrapFormData: aw, + unwrapFormData: dw, children: /* @__PURE__ */ c.jsxs(wn, { defaultCollapsed: i, children: [ - /* @__PURE__ */ c.jsxs(Hc, { children: [ + /* @__PURE__ */ c.jsxs(Uc, { children: [ /* @__PURE__ */ c.jsx("span", { children: t.id }), - /* @__PURE__ */ c.jsxs(b_, { children: [ + /* @__PURE__ */ c.jsxs(v_, { children: [ /* @__PURE__ */ c.jsx("span", { children: "Default Response" }), - /* @__PURE__ */ c.jsx(tf, { name: "defaultResponse", options: a }) + /* @__PURE__ */ c.jsx(ef, { name: "defaultResponse", options: a }) ] }) ] }), /* @__PURE__ */ c.jsxs(Sn, { children: [ - /* @__PURE__ */ c.jsx(y_, { children: n.request.method }), - /* @__PURE__ */ c.jsx(v_, { children: n.request.path }) + /* @__PURE__ */ c.jsx(m_, { children: n.request.method }), + /* @__PURE__ */ c.jsx(y_, { children: n.request.path }) ] }), /* @__PURE__ */ c.jsx( - d_, + u_, { oas: e, credentials: r, @@ -16842,14 +16842,14 @@ function p_({ } ) }); } -function g_(e) { +function p_(e) { return Object.keys(e.responses || {}).map((t) => ({ label: t, value: t })); } -const m_ = E.div` +const g_ = E.div` > div { background-color: var(${w.background}); } -`, y_ = E.div` +`, m_ = E.div` background-color: var(${w.badgeBackground}); color: var(${w.badgeForeground}); border-radius: 4px; @@ -16860,7 +16860,7 @@ const m_ = E.div` height: 16px; text-transform: uppercase; font-size: 11px; -`, v_ = E.div``, b_ = E.div` +`, y_ = E.div``, v_ = E.div` display: flex; flex-direction: row; gap: 4px; @@ -16873,18 +16873,18 @@ const m_ = E.div` border: 1px solid var(${w.border}); } `; -function Kj({ +function Wj({ request: e, requestRef: t }) { - const n = lt(), { oas: r, playbook: o, servers: i } = xe((S) => S.scanconf), s = xe((S) => S.config.data), a = xe((S) => S.env.data), l = xe((S) => S.prefs.useGlobalBlocks), { + const n = ct(), { oas: r, playbook: o, servers: i } = xe((S) => S.scanconf), s = xe((S) => S.config.data), a = xe((S) => S.env.data), l = xe((S) => S.prefs.useGlobalBlocks), { tryResult: u, mockResult: d, mockMissingVariables: h - } = xe((S) => S.requests), f = (S, P) => n(ku({ server: S, inputs: P })), p = (S) => n(pu({ ref: t, stage: S })), g = o.authenticationDetails[0], m = tn(d, "Global Before"), y = tn(d, "Global After"), x = tn(d, "Request"), k = [ - ...Bc, - ...j_(x?.results?.[0]?.variablesReplaced?.stack || []) - ], [v, b] = A.useState({}), { simple: j } = yr(Cf(o), a), _ = jf(o, a, i); + } = xe((S) => S.requests), f = (S, P) => n(xu({ server: S, inputs: P })), p = (S) => n(hu({ ref: t, stage: S })), g = o.authenticationDetails[0], m = tn(d, "Global Before"), y = tn(d, "Global After"), x = tn(d, "Request"), k = [ + ...qc, + ...C_(x?.results?.[0]?.variablesReplaced?.stack || []) + ], [v, b] = A.useState({}), { simple: j } = yr(_f(o), a), _ = Cf(o, a, i); return A.useEffect(() => { const S = { ...v }; for (const P of Object.keys(S)) @@ -16892,27 +16892,27 @@ function Kj({ for (const P of h) S[P] === void 0 && (S[P] = ""); b(S); - }, [h]), /* @__PURE__ */ c.jsxs(x_, { children: [ + }, [h]), /* @__PURE__ */ c.jsxs(b_, { children: [ /* @__PURE__ */ c.jsx( - nf, + tf, { menu: !0, servers: _, onTry: (S) => f(S, v), onScan: (S) => { - const P = $1( + const P = P1( S, s.platformAuthType, s.scanRuntime, s.docker.replaceLocalhost, s.platform - ), [D, $] = p1(o); + ), [D, $] = h1(o); if ($ !== void 0) { console.log("failed to serialize", $); return; } n( - Ng({ + Ag({ path: e.request.path, method: e.request.method, operationId: e.operationId, @@ -16920,7 +16920,7 @@ function Kj({ SCAN42C_HOST: P, ...j }, - scanconf: P1(D, e.operationId) + scanconf: O1(D, e.operationId) }) ); } @@ -16928,7 +16928,7 @@ function Kj({ ), /* @__PURE__ */ c.jsxs(Yn, { title: "Request", children: [ /* @__PURE__ */ c.jsx( - p_, + h_, { defaultCollapsed: !1, oas: r, @@ -16939,41 +16939,41 @@ function Kj({ saveRequest: p } ), - /* @__PURE__ */ c.jsxs(C_, { children: [ + /* @__PURE__ */ c.jsxs(__, { children: [ "Unset variables", /* @__PURE__ */ c.jsx(bn, { children: "Enter values for these unset variables to 'Try' the Operation. Note that these values will not be persisted in the Scan configuration." }) ] }), - /* @__PURE__ */ c.jsx(__, { children: /* @__PURE__ */ c.jsx( + /* @__PURE__ */ c.jsx(S_, { children: /* @__PURE__ */ c.jsx( xn, { - wrapFormData: k_, - unwrapFormData: w_, + wrapFormData: x_, + unwrapFormData: k_, data: v, saveData: (S) => b(S), - children: /* @__PURE__ */ c.jsx(Uo, { name: "env" }) + children: /* @__PURE__ */ c.jsx(Bo, { name: "env" }) } ) }) ] }), - l && m?.status === "failure" && /* @__PURE__ */ c.jsx(Oc, { children: /* @__PURE__ */ c.jsx(no, { message: "Check Global Before block" }) }), - l && y?.status === "failure" && /* @__PURE__ */ c.jsx(Oc, { children: /* @__PURE__ */ c.jsx(no, { message: "Check Global After block" }) }), - u.length > 0 && /* @__PURE__ */ c.jsx(Yn, { title: "Result", children: /* @__PURE__ */ c.jsx(Ru, { result: u, collapsible: l }) }) + l && m?.status === "failure" && /* @__PURE__ */ c.jsx(Tc, { children: /* @__PURE__ */ c.jsx(to, { message: "Check Global Before block" }) }), + l && y?.status === "failure" && /* @__PURE__ */ c.jsx(Tc, { children: /* @__PURE__ */ c.jsx(to, { message: "Check Global After block" }) }), + u.length > 0 && /* @__PURE__ */ c.jsx(Yn, { title: "Result", children: /* @__PURE__ */ c.jsx(Nu, { result: u, collapsible: l }) }) ] }); } -const x_ = E.div` +const b_ = E.div` padding: 8px; `; -function k_(e) { +function x_(e) { return { env: Object.entries(e).map(([t, n]) => ({ key: t, value: n, type: typeof n })) }; } -function w_(e) { +function k_(e) { const t = {}; for (const { key: n, value: r, type: o } of e.env) - t[n] = S_(r, o); + t[n] = w_(r, o); return t; } -function S_(e, t) { +function w_(e, t) { if (t !== "string") try { return JSON.parse(e); @@ -16982,10 +16982,10 @@ function S_(e, t) { } return `${e}`; } -const __ = E.div` +const S_ = E.div` border: 1px solid var(${w.border}); background-color: var(${w.background}); -`, C_ = E.div` +`, __ = E.div` display: flex; padding-top: 12px; padding-bottom: 12px; @@ -16993,20 +16993,20 @@ const __ = E.div` gap: 8px; cursor: pointer; align-items: center; -`, Oc = E.div` +`, Tc = E.div` margin-top: 8px; margin-bottom: 8px; `; -function j_(e) { +function C_(e) { const t = []; for (const n of e) for (const r of Object.keys(n.env)) t.includes(r) || t.push(r); return t.sort(), t; } -function E_({ append: e }) { - return /* @__PURE__ */ c.jsx(T_, { children: /* @__PURE__ */ c.jsx( - O_, +function j_({ append: e }) { + return /* @__PURE__ */ c.jsx(E_, { children: /* @__PURE__ */ c.jsx( + T_, { placeholder: "name", value: "", @@ -17027,10 +17027,10 @@ function E_({ append: e }) { } ) }); } -const T_ = E.div` +const E_ = E.div` grid-column: span 5; display: flex; -`, O_ = E.input` +`, T_ = E.input` flex: 1; background: transparent; border: none; @@ -17038,13 +17038,13 @@ const T_ = E.div` color: var(${w.foreground}); padding: 4px 8px; `; -function P_({ missing: e }) { - const t = lt(), { fields: n, append: r, remove: o } = vn({ +function O_({ missing: e }) { + const t = ct(), { fields: n, append: r, remove: o } = vn({ name: "variables" }); - return /* @__PURE__ */ c.jsxs($_, { children: [ - /* @__PURE__ */ c.jsxs(z_, { children: [ - /* @__PURE__ */ c.jsxs(A_, { children: [ + return /* @__PURE__ */ c.jsxs(P_, { children: [ + /* @__PURE__ */ c.jsxs(D_, { children: [ + /* @__PURE__ */ c.jsxs(I_, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Name" }), /* @__PURE__ */ c.jsx("div", {}), /* @__PURE__ */ c.jsx("div", { children: "Source environment variable" }), @@ -17052,10 +17052,10 @@ function P_({ missing: e }) { /* @__PURE__ */ c.jsx("div", { children: "Required" }), /* @__PURE__ */ c.jsx("div", {}) ] }), - /* @__PURE__ */ c.jsx(I_, { children: n.map((i, s) => { + /* @__PURE__ */ c.jsx(z_, { children: n.map((i, s) => { const a = e !== void 0 && e.includes(i.value.name); return /* @__PURE__ */ c.jsx( - N_, + A_, { missing: a, name: `variables.${s}`, @@ -17066,39 +17066,39 @@ function P_({ missing: e }) { i.id ); }) }), - /* @__PURE__ */ c.jsx(E_, { append: r }) + /* @__PURE__ */ c.jsx(j_, { append: r }) ] }), - /* @__PURE__ */ c.jsx(D_, { children: /* @__PURE__ */ c.jsxs( - q_, + /* @__PURE__ */ c.jsx($_, { children: /* @__PURE__ */ c.jsxs( + F_, { onClick: (i) => { - i.stopPropagation(), i.preventDefault(), t(fh()); + i.stopPropagation(), i.preventDefault(), t(eh()); }, children: [ "Manage IDE Environment ", - /* @__PURE__ */ c.jsx(Xc, {}) + /* @__PURE__ */ c.jsx(Gc, {}) ] } ) }) ] }); } -const $_ = E.div``, D_ = E.div` +const P_ = E.div``, $_ = E.div` padding-top: 8px; margin: 4px; display: flex; gap: 4px; align-items: center; -`, z_ = E.div` +`, D_ = E.div` margin: 8px; display: grid; row-gap: 4px; grid-template-columns: 10em 1.5em 1fr 1fr 5em 1em; -`, I_ = E.div` +`, z_ = E.div` display: contents; & > div > div { border-bottom: 1px solid var(${w.border}); } -`, A_ = E.div` +`, I_ = E.div` display: contents; & > div { padding: 4px 8px; @@ -17108,20 +17108,20 @@ const $_ = E.div``, D_ = E.div` font-weight: 600; } `; -function N_({ +function A_({ name: e, remove: t, missing: n }) { - const r = vo({ name: `${e}.value.required` }); - return /* @__PURE__ */ c.jsxs(F_, { children: [ + const r = yo({ name: `${e}.value.required` }); + return /* @__PURE__ */ c.jsxs(L_, { children: [ /* @__PURE__ */ c.jsx(It, { name: `${e}.key`, label: "name" }), - /* @__PURE__ */ c.jsx(R_, { children: n && /* @__PURE__ */ c.jsx(wt, {}) }), + /* @__PURE__ */ c.jsx(N_, { children: n && /* @__PURE__ */ c.jsx(St, {}) }), /* @__PURE__ */ c.jsx(It, { name: `${e}.value.name`, label: "name" }), r ? /* @__PURE__ */ c.jsx("div", {}) : /* @__PURE__ */ c.jsx(It, { name: `${e}.value.default`, label: "default", disabled: r }), - /* @__PURE__ */ c.jsx(M_, { children: /* @__PURE__ */ c.jsx(Ov, { name: `${e}.value.required` }) }), + /* @__PURE__ */ c.jsx(R_, { children: /* @__PURE__ */ c.jsx(Tv, { name: `${e}.value.required` }) }), /* @__PURE__ */ c.jsx( - L_, + M_, { onClick: (o) => { o.preventDefault(), o.stopPropagation(), t(); @@ -17131,7 +17131,7 @@ function N_({ ) ] }); } -const R_ = E.div` +const N_ = E.div` display: flex; align-items: center; justify-content: center; @@ -17139,9 +17139,9 @@ const R_ = E.div` fill: var(${w.errorForeground}); padding-right: 4px; } -`, M_ = E.div` +`, R_ = E.div` display: flex; -`, L_ = E.button` +`, M_ = E.button` background: none; border: none; padding: 0; @@ -17154,12 +17154,12 @@ const R_ = E.div` > svg { fill: var(${w.foreground}); } -`, F_ = E.div` +`, L_ = E.div` display: contents; &:hover > :last-child { visibility: visible; } -`, q_ = E.div` +`, F_ = E.div` display: flex; gap: 4px; align-items: center; @@ -17173,17 +17173,17 @@ const R_ = E.div` height: 10px; } `; -function B_({ name: e }) { - const t = lt(), { +function q_({ name: e }) { + const t = ct(), { playbook: { environments: n } } = xe((l) => l.scanconf), r = xe((l) => l.env.data), [o, i] = A.useState("environment"), s = n[e], { missing: a } = yr(s, r); return /* @__PURE__ */ c.jsx( xn, { - wrapFormData: U_, - unwrapFormData: H_, + wrapFormData: B_, + unwrapFormData: U_, data: s, - saveData: (l) => t(Hg({ name: e, environment: l })), + saveData: (l) => t(Ug({ name: e, environment: l })), children: /* @__PURE__ */ c.jsx( kn, { @@ -17196,7 +17196,7 @@ function B_({ name: e }) { id: "environment", title: "External inputs", content: /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsx(P_, { missing: a }), + /* @__PURE__ */ c.jsx(O_, { missing: a }), a.length > 0 && /* @__PURE__ */ c.jsx( Un, { @@ -17216,7 +17216,7 @@ function B_({ name: e }) { } ); } -function U_(e) { +function B_(e) { return { variables: Object.entries(e.variables).filter(([t, n]) => n.from === "environment").map(([t, n]) => ({ key: t, value: n })), constants: Object.entries(e.variables).filter(([t, n]) => n.from === "hardcoded").map(([t, n]) => ({ @@ -17226,7 +17226,7 @@ function U_(e) { })) }; } -function H_(e) { +function U_(e) { const t = { variables: {} }; @@ -17235,11 +17235,11 @@ function H_(e) { for (const { key: n, value: r, type: o } of e.constants) t.variables[n] = { from: "hardcoded", - value: V_(r, o) + value: H_(r, o) }; return t; } -function V_(e, t) { +function H_(e, t) { if (t !== "string") try { return JSON.parse(e); @@ -17248,7 +17248,7 @@ function V_(e, t) { } return `${e}`; } -function Gj() { +function Kj() { const [e, t] = A.useState("default"), { playbook: { environments: n } } = xe((i) => i.scanconf), o = [ @@ -17259,68 +17259,68 @@ function Gj() { } ]; return /* @__PURE__ */ c.jsx( - Wh, + Vh, { title: "environment", noSectionTitles: !0, selected: e ? { sectionId: "environment", itemId: e } : void 0, sections: o, onSelected: (i) => t(i.itemId), - render: (i) => /* @__PURE__ */ c.jsx(B_, { name: i.itemId }, i.itemId) + render: (i) => /* @__PURE__ */ c.jsx(q_, { name: i.itemId }, i.itemId) } ); } -const da = E.div` +const ua = E.div` display: flex; flex-direction: column; gap: 8px; //max-width: 560px; -`, fa = E.div` +`, da = E.div` font-weight: 700; margin-bottom: 16px; -`, ha = Uc({ +`, fa = Bc({ environment: qn(), logLevel: qn(), logDestination: qn(), - requestFlowrate: We(), - requestTimeout: We(), - requestTlsInsecureSkipVerify: Qo(), - happyPathOnly: Qo(), - responseFollowRedirection: Qo(), - maxScanDuration: We(), - reportMaxIssues: We(), - reportMaxSize: We(), - responseMaxBodySizeScan: We(), - reportMaxHttpResponseSizeHappyPath: We(), - reportMaxBodySizeHappyPath: We(), - reportMaxBodySizeTest: We(), - reportMaxHttpResponseSizeTest: We() + requestFlowrate: Ke(), + requestTimeout: Ke(), + requestTlsInsecureSkipVerify: Yo(), + happyPathOnly: Yo(), + responseFollowRedirection: Yo(), + maxScanDuration: Ke(), + reportMaxIssues: Ke(), + reportMaxSize: Ke(), + responseMaxBodySizeScan: Ke(), + reportMaxHttpResponseSizeHappyPath: Ke(), + reportMaxBodySizeHappyPath: Ke(), + reportMaxBodySizeTest: Ke(), + reportMaxHttpResponseSizeTest: Ke() }); -function W_(e) { +function V_(e) { return { ...e, logLevel: e.logLevel !== void 0 ? e.logLevel : "" }; } -function K_(e) { +function W_(e) { return { ...e, logLevel: e.logLevel !== "" ? e.logLevel : void 0 }; } -function G_() { +function K_() { return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsx(fa, { children: "Default environment" }), - /* @__PURE__ */ c.jsx(da, { children: /* @__PURE__ */ c.jsx(Pe, { name: "environment", label: "Default environment", disabled: !0 }) }) + /* @__PURE__ */ c.jsx(da, { children: "Default environment" }), + /* @__PURE__ */ c.jsx(ua, { children: /* @__PURE__ */ c.jsx(Pe, { name: "environment", label: "Default environment", disabled: !0 }) }) ] }); } -const Yi = { +const Xi = { id: "environment", label: "Environment settings", - schema: ha, - form: G_ + schema: fa, + form: K_ }; -function X_() { +function G_() { return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsx(fa, { children: "Logging settings" }), - /* @__PURE__ */ c.jsxs(da, { children: [ + /* @__PURE__ */ c.jsx(da, { children: "Logging settings" }), + /* @__PURE__ */ c.jsxs(ua, { children: [ /* @__PURE__ */ c.jsx( Kr, { @@ -17345,16 +17345,16 @@ function X_() { ] }) ] }); } -const Qi = { +const Yi = { id: "logging", label: "Logging settings", - schema: ha, - form: X_ + schema: fa, + form: G_ }; -function Y_() { +function X_() { return /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ - /* @__PURE__ */ c.jsx(fa, { children: "General settings" }), - /* @__PURE__ */ c.jsxs(da, { children: [ + /* @__PURE__ */ c.jsx(da, { children: "General settings" }), + /* @__PURE__ */ c.jsxs(ua, { children: [ /* @__PURE__ */ c.jsx( Pe, { @@ -17473,52 +17473,52 @@ function Y_() { ] }) ] }); } -const Ji = { +const Qi = { id: "general", label: "General settings", - schema: ha, - form: Y_ -}, Q_ = [ + schema: fa, + form: X_ +}, Y_ = [ { id: "logging", title: "Logging", - items: [Qi] + items: [Yi] }, { id: "environment", title: "Environment", - items: [Yi] + items: [Xi] }, { id: "general", title: "General", - items: [Ji] + items: [Qi] } -], J_ = { - [Ji.id]: Ji, +], Q_ = { [Qi.id]: Qi, - [Yi.id]: Yi + [Yi.id]: Yi, + [Xi.id]: Xi }; -function Xj() { - const e = lt(), t = xe( +function Gj() { + const e = ct(), t = xe( (n) => n.scanconf.playbook.runtimeConfiguration ); return /* @__PURE__ */ c.jsx( - Kh, + Wh, { noSectionTitles: !0, - sections: Q_, + sections: Y_, defaultSelection: { sectionId: "logging", itemId: "logging" }, render: (n) => { - const { id: r, form: o, schema: i } = J_[n.itemId]; + const { id: r, form: o, schema: i } = Q_[n.itemId]; return /* @__PURE__ */ c.jsx( xn, { schema: i, - wrapFormData: W_, - unwrapFormData: K_, + wrapFormData: V_, + unwrapFormData: W_, data: t || {}, - saveData: (s) => e(Ug(s)), + saveData: (s) => e(Bg(s)), children: /* @__PURE__ */ c.jsx(o, {}) } ); @@ -17526,19 +17526,19 @@ function Xj() { } ); } -function Yj() { +function Xj() { const { playbook: { environments: e, runtimeConfiguration: t } } = xe((o) => o.scanconf), n = xe((o) => o.env.data); if (e == null || t == null) - return /* @__PURE__ */ c.jsx(Pc, { children: "Environment" }); + return /* @__PURE__ */ c.jsx(Oc, { children: "Environment" }); const { missing: r } = yr(e[t?.environment || "default"], n); - return /* @__PURE__ */ c.jsxs(Pc, { children: [ + return /* @__PURE__ */ c.jsxs(Oc, { children: [ "Environment", - r.length > 0 && /* @__PURE__ */ c.jsx(wt, {}) + r.length > 0 && /* @__PURE__ */ c.jsx(St, {}) ] }); } -const Pc = E.div` +const Oc = E.div` display: flex; gap: 4px; align-items: center; @@ -17547,31 +17547,31 @@ const Pc = E.div` padding-right: 4px; } `; -function Z_({ change: e }) { - return /* @__PURE__ */ c.jsx(eC, { children: /* @__PURE__ */ c.jsx(ua, { path: e.path, method: e.method, operationId: e.operationId }) }); +function J_({ change: e }) { + return /* @__PURE__ */ c.jsx(Z_, { children: /* @__PURE__ */ c.jsx(ca, { path: e.path, method: e.method, operationId: e.operationId }) }); } -const eC = E.div` +const Z_ = E.div` border: 1px solid var(${w.border}); padding: 8px; background-color: var(${w.computedOne}); `; -function tC({ change: e }) { - return /* @__PURE__ */ c.jsx(nC, { children: /* @__PURE__ */ c.jsx(ua, { path: e.path, method: e.method, operationId: e.operationId, children: e.references.length > 0 && /* @__PURE__ */ c.jsxs(rC, { children: [ +function eC({ change: e }) { + return /* @__PURE__ */ c.jsx(tC, { children: /* @__PURE__ */ c.jsx(ca, { path: e.path, method: e.method, operationId: e.operationId, children: e.references.length > 0 && /* @__PURE__ */ c.jsxs(nC, { children: [ "References in ", e.references.length, " locations will be removed" ] }) }) }); } -const nC = E.div` +const tC = E.div` border: 1px solid var(${w.border}); padding: 8px; background-color: var(${w.computedOne}); -`, rC = E.div` +`, nC = E.div` padding: 8px; background-color: var(${w.background}); `; -function oC({ change: e }) { - return /* @__PURE__ */ c.jsx(iC, { children: /* @__PURE__ */ c.jsx(ua, { path: e.path, method: e.method, operationId: e.oldOperationId, children: /* @__PURE__ */ c.jsxs(sC, { children: [ +function rC({ change: e }) { + return /* @__PURE__ */ c.jsx(oC, { children: /* @__PURE__ */ c.jsx(ca, { path: e.path, method: e.method, operationId: e.oldOperationId, children: /* @__PURE__ */ c.jsxs(iC, { children: [ '"', e.oldOperationId, '" renamed to "', @@ -17579,70 +17579,70 @@ function oC({ change: e }) { '"' ] }) }) }); } -const iC = E.div` +const oC = E.div` border: 1px solid var(${w.border}); padding: 8px; background-color: var(${w.computedOne}); -`, sC = E.div` +`, iC = E.div` padding: 8px; background-color: var(${w.background}); `; -function aC({ change: e }) { - return /* @__PURE__ */ c.jsx(lC, { children: e.schema }); +function sC({ change: e }) { + return /* @__PURE__ */ c.jsx(aC, { children: e.schema }); } -const lC = E.div` +const aC = E.div` border: 1px solid var(${w.border}); padding: 8px; background-color: var(${w.computedOne}); `; -function Qj() { - const e = lt(), { changes: t, updating: n } = xe((a) => a.scanconfUpdate), r = t.filter((a) => a.type === "operation-added"), o = t.filter((a) => a.type === "operation-removed"), i = t.filter((a) => a.type === "operation-renamed"), s = t.filter((a) => a.type === "security-added"); - return /* @__PURE__ */ c.jsxs(cC, { children: [ +function Yj() { + const e = ct(), { changes: t, updating: n } = xe((a) => a.scanconfUpdate), r = t.filter((a) => a.type === "operation-added"), o = t.filter((a) => a.type === "operation-removed"), i = t.filter((a) => a.type === "operation-renamed"), s = t.filter((a) => a.type === "security-added"); + return /* @__PURE__ */ c.jsxs(lC, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Your OpenAPI file has deviated from your scan configuration." }), /* @__PURE__ */ c.jsx("div", { children: "Please update your scan configuration to reflect the changes in your OpenAPI file. If you decide to ignore the changes, the scan will be performed using the old configuration." }), - /* @__PURE__ */ c.jsxs(dC, { children: [ + /* @__PURE__ */ c.jsxs(uC, { children: [ r.length > 0 && /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Added:" }), - r.map((a, l) => /* @__PURE__ */ c.jsx(Z_, { change: a }, l)) + r.map((a, l) => /* @__PURE__ */ c.jsx(J_, { change: a }, l)) ] }), o.length > 0 && /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Removed:" }), - o.map((a, l) => /* @__PURE__ */ c.jsx(tC, { change: a }, l)) + o.map((a, l) => /* @__PURE__ */ c.jsx(eC, { change: a }, l)) ] }), i.length > 0 && /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx("div", { children: "OperationId changed:" }), - i.map((a, l) => /* @__PURE__ */ c.jsx(oC, { change: a }, l)) + i.map((a, l) => /* @__PURE__ */ c.jsx(rC, { change: a }, l)) ] }), s.length > 0 && /* @__PURE__ */ c.jsxs(c.Fragment, { children: [ /* @__PURE__ */ c.jsx("div", { children: "Security scheme added:" }), - s.map((a, l) => /* @__PURE__ */ c.jsx(aC, { change: a }, l)) + s.map((a, l) => /* @__PURE__ */ c.jsx(sC, { change: a }, l)) ] }) ] }), - /* @__PURE__ */ c.jsxs(uC, { children: [ + /* @__PURE__ */ c.jsxs(cC, { children: [ /* @__PURE__ */ c.jsx( - wh, + kh, { label: "Update", waiting: n, - onClick: () => e(pm()) + onClick: () => e(hm()) } ), - /* @__PURE__ */ c.jsx(Dc, { disabled: n, onClick: () => e(gm()), children: "Skip" }) + /* @__PURE__ */ c.jsx($c, { disabled: n, onClick: () => e(pm()), children: "Skip" }) ] }) ] }); } -const cC = E.div` +const lC = E.div` padding: 16px; display: flex; flex-direction: column; gap: 8px; height: 100%; overflow: auto; -`, uC = E.div` +`, cC = E.div` display: flex; gap: 8px; padding-bottom: 32px; -`, dC = E.div` +`, uC = E.div` display: flex; flex-direction: column; gap: 8px; @@ -17650,132 +17650,132 @@ const cC = E.div` margin-bottom: 16px; `; export { - wj as $, - Gg as A, - Rj as B, + kj as $, + Kg as A, + Nj as B, Yn as C, - op as D, - Uo as E, - zu as F, - Vg as G, - Fj as H, - fj as I, - hj as J, - B0 as K, - lj as L, - qg as M, - cj as N, - F0 as O, - dj as P, - uj as Q, - us as R, + rp as D, + Bo as E, + Du as F, + Hg as G, + Lj as H, + dj as I, + fj as J, + q0 as K, + aj as L, + Fg as M, + lj as N, + L0 as O, + uj as P, + cj as Q, + cs as R, Kr as S, - nf as T, - pu as U, - ku as V, - bj as W, - vj as X, - kj as Y, - LC as Z, - Bj as _, - Nj as a, - Ys as a$, - xj as a0, - Oj as a1, - Tj as a2, - yj as a3, - mj as a4, - _j as a5, - Sj as a6, - Pw as a7, - Ej as a8, - jj as a9, + tf as T, + hu as U, + xu as V, + vj as W, + yj as X, + xj as Y, + MC as Z, + qj as _, + Aj as a, + Xs as a$, + bj as a0, + Tj as a1, + Ej as a2, + mj as a3, + gj as a4, + Sj as a5, + wj as a6, + Ow as a7, + jj as a8, + Cj as a9, yr as aA, - Cf as aB, - jf as aC, - $1 as aD, - P1 as aE, - ua as aF, - gw as aG, - ij as aH, - Wj as aI, - Kj as aJ, - Nv as aK, - nj as aL, - Dj as aM, - FC as aN, - qC as aO, - $j as aP, - Qj as aQ, - Gj as aR, - Yj as aS, - Xj as aT, + _f as aB, + Cf as aC, + P1 as aD, + O1 as aE, + ca as aF, + pw as aG, + oj as aH, + Vj as aI, + Wj as aJ, + Av as aK, + tj as aL, + $j as aM, + LC as aN, + FC as aO, + Pj as aP, + Yj as aQ, + Kj as aR, + Xj as aS, + Gj as aT, wr as aU, - Qg as aV, - fm as aW, - mm as aX, - tp as aY, - Hj as aZ, - Qs as a_, - gj as aa, - pj as ab, - Rg as ac, - Vj as ad, - Mg as ae, - as as af, - Pj as ag, - Uj as ah, - cm as ai, - pm as aj, - UC as ak, - p1 as al, - sj as am, - gu as an, - oj as ao, - ZC as ap, - tj as aq, - ej as ar, - rj as as, - Hg as at, - Ug as au, - BC as av, - Ng as aw, - gm as ax, - Lj as ay, + Yg as aV, + dm as aW, + gm as aX, + ep as aY, + Uj as aZ, + Ys as a_, + pj as aa, + hj as ab, + Ng as ac, + Hj as ad, + Rg as ae, + ss as af, + Oj as ag, + Bj as ah, + lm as ai, + hm as aj, + BC as ak, + h1 as al, + ij as am, + pu as an, + rj as ao, + JC as ap, + ej as aq, + ZC as ar, + nj as as, + Ug as at, + Bg as au, + qC as av, + Ag as aw, + pm as ax, + Mj as ay, tn as az, - Aj as b, - hw as b0, - Bo as b1, - Ef as b2, - Cc as b3, - lS as b4, - oS as b5, - rS as b6, - n_ as b7, - fw as b8, - j_ as b9, - tf as c, - Ov as d, - np as e, - lt as f, + Ij as b, + fw as b0, + qo as b1, + jf as b2, + _c as b3, + aS as b4, + rS as b5, + nS as b6, + t_ as b7, + dw as b8, + C_ as b9, + ef as c, + Tv as d, + tp as e, + ct as f, xe as g, - JC as h, + QC as h, Q as i, - XC as j, - Cj as k, - aj as l, - YC as m, - Ru as n, - Kg as o, - Ev as p, - Mj as q, - QC as r, - Xg as s, - VC as t, - Ij as u, - HC as v, - zj as w, - KC as x, - Wg as y, - GC as z + GC as j, + _j as k, + sj as l, + XC as m, + Nu as n, + Wg as o, + jv as p, + Rj as q, + YC as r, + Gg as s, + HC as t, + zj as u, + UC as v, + Dj as w, + WC as x, + Vg as y, + KC as z }; diff --git a/openapi-plugin/resources/web/capture.js b/openapi-plugin/resources/web/capture.js index c774389e..ffd1ea7e 100644 --- a/openapi-plugin/resources/web/capture.js +++ b/openapi-plugin/resources/web/capture.js @@ -1,10 +1,10 @@ import { j as e, c as Y, d as Z, s as ee, w as se, i as te, p as ie, a as ne, I as re, r as oe, t as ae, l as le, u as de, b as ce, T as l, e as a, m as pe, B as D, g as ue, R as he, P as ge, h as xe, a0 as me, k as fe } from "./TriangleExclamation.BLKAXJ8l.js"; import { s as ve } from "./listener.BM8yBkLB.js"; import { o as je, c as we } from "./listener.BNWHQqef.js"; -import { s as ye } from "./rtk-query-react.modern.kJqw8Vn6.js"; +import { s as ye } from "./rtk-query-react.modern.DVdYp0Is.js"; import { l as be, c as Ce } from "./slice.s4_w0CJL.js"; import { s as Se, g as Fe, M as H, a as z, b as Ie, G as Pe, S as Ae } from "./GeneralError.Dvjq_B8a.js"; -import { f as M, u as $e, g as ke } from "./freemiumd-api.YVoWfg3P.js"; +import { f as M, u as $e, g as ke } from "./freemiumd-api.CctZu0yp.js"; import { S as G } from "./TrashCan.DYWcjlk_.js"; import { a as Me } from "./SearchSidebar.CtwbvK_x.js"; import { u as Le } from "./index.esm.MIM2ge_D.js"; diff --git a/openapi-plugin/resources/web/config.js b/openapi-plugin/resources/web/config.js index 14a49e62..ab393fe0 100644 --- a/openapi-plugin/resources/web/config.js +++ b/openapi-plugin/resources/web/config.js @@ -6,9 +6,9 @@ import { o as u, s as d, l as C, _ as E, u as ne, i as Ve, a as _e, b as $, c as import { T as de, I as c } from "./Textarea.7FvXKGUa.js"; import { N as We } from "./ProgressButton.BXekI9TY.js"; import { B as w, E as H } from "./Banner.BZe2qI8d.js"; -import { R as qe, p as Q } from "./platform-api.xQ9SQy05.js"; -import { f as Z, u as Je, g as Xe } from "./freemiumd-api.YVoWfg3P.js"; -import { s as Ye } from "./rtk-query-react.modern.kJqw8Vn6.js"; +import { R as qe, p as Q } from "./platform-api.BtY3-lHu.js"; +import { f as Z, u as Je, g as Xe } from "./freemiumd-api.CctZu0yp.js"; +import { s as Ye } from "./rtk-query-react.modern.DVdYp0Is.js"; import { c as Ke, o as Qe } from "./listener.BNWHQqef.js"; import { S as U } from "./Select.Jkx8eZok.js"; import { n as Ze } from "./coerce.FZdHX8I_.js"; diff --git a/openapi-plugin/resources/web/environment.js b/openapi-plugin/resources/web/environment.js index accec7aa..f6c695df 100644 --- a/openapi-plugin/resources/web/environment.js +++ b/openapi-plugin/resources/web/environment.js @@ -1,15 +1,15 @@ import { a as y, t as w, l as S, d as C, s as $, e as o, T as s, j as e, g as F, R as k, P as V, k as A, p as R, n as M } from "./TriangleExclamation.BLKAXJ8l.js"; -import { e as _, a as g, u as L, b as N, l as T } from "./index.CRy0HWMP.js"; +import { e as _, b as g, u as L, c as N, a as T } from "./index.BXf_Hj-1.js"; import { T as P } from "./Tabs.BfQDe6I2.js"; import { u as D, a as v, d as G, b as W, F as H } from "./index.esm.MIM2ge_D.js"; import { S as K } from "./ExclamationCircle.2wqwVNIx.js"; import { S as X } from "./TrashCan.DYWcjlk_.js"; -import { r as B, t as I } from "./variables.-zE0Ry6h.js"; -const O = { +import { q, r as B } from "./variables.CfsUBZ9t.js"; +const I = { theme: w, env: _ -}, q = (r, t) => y({ - reducer: O, +}, O = (r, t) => y({ + reducer: I, middleware: (n) => n().prepend(r.middleware).concat(S), preloadedState: { theme: t @@ -41,8 +41,8 @@ function Q({ control: a, rules: { pattern: { - value: I(), - message: B + value: B(), + message: q } } }), { field: d } = v({ @@ -214,7 +214,7 @@ function me() { ] }); } function pe(r, t) { - const n = q(J(r), t); + const n = O(J(r), t); F.createRoot(document.getElementById("root")).render( /* @__PURE__ */ e.jsx(k.StrictMode, { children: /* @__PURE__ */ e.jsx(V, { store: n, children: /* @__PURE__ */ e.jsx(me, {}) }) }) ), window.addEventListener("message", A(n, ue)); diff --git a/openapi-plugin/resources/web/freemiumd-api.YVoWfg3P.js b/openapi-plugin/resources/web/freemiumd-api.CctZu0yp.js similarity index 96% rename from openapi-plugin/resources/web/freemiumd-api.YVoWfg3P.js rename to openapi-plugin/resources/web/freemiumd-api.CctZu0yp.js index c1571dbc..70f1454b 100644 --- a/openapi-plugin/resources/web/freemiumd-api.YVoWfg3P.js +++ b/openapi-plugin/resources/web/freemiumd-api.CctZu0yp.js @@ -1,4 +1,4 @@ -import { c as m } from "./rtk-query-react.modern.kJqw8Vn6.js"; +import { c as m } from "./rtk-query-react.modern.DVdYp0Is.js"; import { w as h } from "./webapp-client.CEJRS8eu.js"; import { s as f } from "./listener.BNWHQqef.js"; function g(t) { diff --git a/openapi-plugin/resources/web/index.BXf_Hj-1.js b/openapi-plugin/resources/web/index.BXf_Hj-1.js new file mode 100644 index 00000000..23173b93 --- /dev/null +++ b/openapi-plugin/resources/web/index.BXf_Hj-1.js @@ -0,0 +1,6493 @@ +import { c as Gs, u as Ws, b as Qs, W as Un } from "./TriangleExclamation.BLKAXJ8l.js"; +const Hs = { + ready: !1, + data: { default: {}, secrets: {} } +}, Vn = Gs({ + name: "env", + initialState: Hs, + reducers: { + loadEnv: (e, t) => { + t.payload.default && (e.data.default = t.payload.default), t.payload.secrets && (e.data.secrets = t.payload.secrets), e.ready = !0; + }, + saveEnv: (e, t) => { + e.data[t.payload.name] = t.payload.environment; + }, + showEnvWindow: (e, t) => { + } + } +}), { loadEnv: Mr, saveEnv: Rr, showEnvWindow: Kr } = Vn.actions, Dr = Ws, qr = Qs, Fr = Vn.reducer, Ur = [ + "get", + "put", + "post", + "delete", + "options", + "head", + "patch", + "trace" +]; +var _t = {}, Qe = {}, He = {}, Y = {}, Q = {}, mn; +function zs() { + return mn || (mn = 1, Object.defineProperty(Q, "__esModule", { value: !0 }), Q.preserveLocationKey = Q.preserveFormattingKey = Q.preserveRootRangeKey = void 0, Q.preserveRootRangeKey = /* @__PURE__ */ Symbol("preserve-root-location"), Q.preserveFormattingKey = /* @__PURE__ */ Symbol("preserve-formatting"), Q.preserveLocationKey = /* @__PURE__ */ Symbol("preserve-location")), Q; +} +var yn; +function qe() { + if (yn) return Y; + yn = 1, Object.defineProperty(Y, "__esModule", { value: !0 }), Y.getPreservedValue = t, Y.setPreservedValue = n, Y.getPreservedLocation = s, Y.setPreservedLocation = i, Y.getPreservedRootRange = r, Y.setPreservedRootRange = o, Y.copyPreservedValues = a; + const e = zs(); + function t(l, c) { + var f; + return (f = l?.[e.preserveFormattingKey]) === null || f === void 0 ? void 0 : f[c]; + } + function n(l, c, f) { + l[e.preserveFormattingKey] === void 0 && Object.defineProperty(l, e.preserveFormattingKey, { enumerable: !1, value: {} }), l[e.preserveFormattingKey][c] = f; + } + function s(l, c) { + var f; + return (f = l?.[e.preserveLocationKey]) === null || f === void 0 ? void 0 : f[c]; + } + function i(l, c, f) { + l[e.preserveLocationKey] === void 0 && Object.defineProperty(l, e.preserveLocationKey, { enumerable: !1, value: {} }), l[e.preserveLocationKey][c] = f; + } + function r(l) { + return l[e.preserveRootRangeKey]; + } + function o(l, c) { + Object.defineProperty(l, e.preserveRootRangeKey, { enumerable: !1, value: c }); + } + function a(l, c) { + l && l[e.preserveFormattingKey] !== void 0 && Object.defineProperty(c, e.preserveFormattingKey, { + enumerable: !1, + value: l[e.preserveFormattingKey] + }); + } + return Y; +} +var bn; +function Jn() { + if (bn) return He; + bn = 1, Object.defineProperty(He, "__esModule", { value: !0 }), He.visitObject = t; + const e = qe(); + function t(s, i, r, o) { + const a = n(r); + if (a === "object") { + o.onObjectStart(s, i, r, (0, e.getPreservedLocation)(s, i)); + for (const l in r) + t(r, l, r[l], o); + o.onObjectEnd(); + } else a === "array" ? (o.onArrayStart(s, i, r, (0, e.getPreservedLocation)(s, i)), r.forEach((l, c) => { + t(r, c, l, o); + }), o.onArrayEnd()) : o.onValue(s, i, r, (0, e.getPreservedValue)(s, i), (0, e.getPreservedLocation)(s, i)); + } + function n(s) { + return typeof s == "object" ? s === null || s instanceof Number || s instanceof String || s instanceof Boolean ? "value" : s instanceof Array ? "array" : "object" : "value"; + } + return He; +} +var wn; +function Xs() { + if (wn) return Qe; + wn = 1, Object.defineProperty(Qe, "__esModule", { value: !0 }), Qe.simpleClone = n; + const e = Jn(), t = qe(); + function n(s, i) { + let r = {}, o = []; + const a = [r]; + return (0, e.visitObject)(void 0, "fakeroot", s, { + onObjectStart: (l, c, f) => { + o.push(c), a.push(r), r = r[c] = {}, (0, t.copyPreservedValues)(f, r); + }, + onObjectEnd: () => { + o.pop(), r = a.pop(); + }, + onArrayStart: (l, c, f) => { + o.push(c), a.push(r), r = r[c] = [], (0, t.copyPreservedValues)(f, r); + }, + onArrayEnd: () => { + o.pop(), r = a.pop(); + }, + onValue: (l, c, f, u) => { + r[c] = i ? i(f, [...o.slice(1), c]) : f; + } + }), a[0].fakeroot; + } + return Qe; +} +var _e = {}, ze = {}; +const Zt = /* @__PURE__ */ Symbol.for("yaml.alias"), qt = /* @__PURE__ */ Symbol.for("yaml.document"), te = /* @__PURE__ */ Symbol.for("yaml.map"), Yn = /* @__PURE__ */ Symbol.for("yaml.pair"), W = /* @__PURE__ */ Symbol.for("yaml.scalar"), Ee = /* @__PURE__ */ Symbol.for("yaml.seq"), U = /* @__PURE__ */ Symbol.for("yaml.node.type"), Z = (e) => !!e && typeof e == "object" && e[U] === Zt, ne = (e) => !!e && typeof e == "object" && e[U] === qt, ce = (e) => !!e && typeof e == "object" && e[U] === te, L = (e) => !!e && typeof e == "object" && e[U] === Yn, E = (e) => !!e && typeof e == "object" && e[U] === W, fe = (e) => !!e && typeof e == "object" && e[U] === Ee; +function I(e) { + if (e && typeof e == "object") + switch (e[U]) { + case te: + case Ee: + return !0; + } + return !1; +} +function _(e) { + if (e && typeof e == "object") + switch (e[U]) { + case Zt: + case te: + case W: + case Ee: + return !0; + } + return !1; +} +const Gn = (e) => (E(e) || I(e)) && !!e.anchor, R = /* @__PURE__ */ Symbol("break visit"), Wn = /* @__PURE__ */ Symbol("skip children"), G = /* @__PURE__ */ Symbol("remove node"); +function se(e, t) { + const n = Qn(t); + ne(e) ? we(null, e.contents, n, Object.freeze([e])) === G && (e.contents = null) : we(null, e, n, Object.freeze([])); +} +se.BREAK = R; +se.SKIP = Wn; +se.REMOVE = G; +function we(e, t, n, s) { + const i = Hn(e, t, n, s); + if (_(i) || L(i)) + return zn(e, s, i), we(e, i, n, s); + if (typeof i != "symbol") { + if (I(t)) { + s = Object.freeze(s.concat(t)); + for (let r = 0; r < t.items.length; ++r) { + const o = we(r, t.items[r], n, s); + if (typeof o == "number") + r = o - 1; + else { + if (o === R) + return R; + o === G && (t.items.splice(r, 1), r -= 1); + } + } + } else if (L(t)) { + s = Object.freeze(s.concat(t)); + const r = we("key", t.key, n, s); + if (r === R) + return R; + r === G && (t.key = null); + const o = we("value", t.value, n, s); + if (o === R) + return R; + o === G && (t.value = null); + } + } + return i; +} +async function Fe(e, t) { + const n = Qn(t); + ne(e) ? await ke(null, e.contents, n, Object.freeze([e])) === G && (e.contents = null) : await ke(null, e, n, Object.freeze([])); +} +Fe.BREAK = R; +Fe.SKIP = Wn; +Fe.REMOVE = G; +async function ke(e, t, n, s) { + const i = await Hn(e, t, n, s); + if (_(i) || L(i)) + return zn(e, s, i), ke(e, i, n, s); + if (typeof i != "symbol") { + if (I(t)) { + s = Object.freeze(s.concat(t)); + for (let r = 0; r < t.items.length; ++r) { + const o = await ke(r, t.items[r], n, s); + if (typeof o == "number") + r = o - 1; + else { + if (o === R) + return R; + o === G && (t.items.splice(r, 1), r -= 1); + } + } + } else if (L(t)) { + s = Object.freeze(s.concat(t)); + const r = await ke("key", t.key, n, s); + if (r === R) + return R; + r === G && (t.key = null); + const o = await ke("value", t.value, n, s); + if (o === R) + return R; + o === G && (t.value = null); + } + } + return i; +} +function Qn(e) { + return typeof e == "object" && (e.Collection || e.Node || e.Value) ? Object.assign({ + Alias: e.Node, + Map: e.Node, + Scalar: e.Node, + Seq: e.Node + }, e.Value && { + Map: e.Value, + Scalar: e.Value, + Seq: e.Value + }, e.Collection && { + Map: e.Collection, + Seq: e.Collection + }, e) : e; +} +function Hn(e, t, n, s) { + if (typeof n == "function") + return n(e, t, s); + if (ce(t)) + return n.Map?.(e, t, s); + if (fe(t)) + return n.Seq?.(e, t, s); + if (L(t)) + return n.Pair?.(e, t, s); + if (E(t)) + return n.Scalar?.(e, t, s); + if (Z(t)) + return n.Alias?.(e, t, s); +} +function zn(e, t, n) { + const s = t[t.length - 1]; + if (I(s)) + s.items[e] = n; + else if (L(s)) + e === "key" ? s.key = n : s.value = n; + else if (ne(s)) + s.contents = n; + else { + const i = Z(s) ? "alias" : "scalar"; + throw new Error(`Cannot replace node with ${i} parent`); + } +} +const Zs = { + "!": "%21", + ",": "%2C", + "[": "%5B", + "]": "%5D", + "{": "%7B", + "}": "%7D" +}, Cs = (e) => e.replace(/[!,[\]{}]/g, (t) => Zs[t]); +class M { + constructor(t, n) { + this.docStart = null, this.docEnd = !1, this.yaml = Object.assign({}, M.defaultYaml, t), this.tags = Object.assign({}, M.defaultTags, n); + } + clone() { + const t = new M(this.yaml, this.tags); + return t.docStart = this.docStart, t; + } + /** + * During parsing, get a Directives instance for the current document and + * update the stream state according to the current version's spec. + */ + atDocument() { + const t = new M(this.yaml, this.tags); + switch (this.yaml.version) { + case "1.1": + this.atNextDocument = !0; + break; + case "1.2": + this.atNextDocument = !1, this.yaml = { + explicit: M.defaultYaml.explicit, + version: "1.2" + }, this.tags = Object.assign({}, M.defaultTags); + break; + } + return t; + } + /** + * @param onError - May be called even if the action was successful + * @returns `true` on success + */ + add(t, n) { + this.atNextDocument && (this.yaml = { explicit: M.defaultYaml.explicit, version: "1.1" }, this.tags = Object.assign({}, M.defaultTags), this.atNextDocument = !1); + const s = t.trim().split(/[ \t]+/), i = s.shift(); + switch (i) { + case "%TAG": { + if (s.length !== 2 && (n(0, "%TAG directive should contain exactly two parts"), s.length < 2)) + return !1; + const [r, o] = s; + return this.tags[r] = o, !0; + } + case "%YAML": { + if (this.yaml.explicit = !0, s.length !== 1) + return n(0, "%YAML directive should contain exactly one part"), !1; + const [r] = s; + if (r === "1.1" || r === "1.2") + return this.yaml.version = r, !0; + { + const o = /^\d+\.\d+$/.test(r); + return n(6, `Unsupported YAML version ${r}`, o), !1; + } + } + default: + return n(0, `Unknown directive ${i}`, !0), !1; + } + } + /** + * Resolves a tag, matching handles to those defined in %TAG directives. + * + * @returns Resolved tag, which may also be the non-specific tag `'!'` or a + * `'!local'` tag, or `null` if unresolvable. + */ + tagName(t, n) { + if (t === "!") + return "!"; + if (t[0] !== "!") + return n(`Not a valid tag: ${t}`), null; + if (t[1] === "<") { + const o = t.slice(2, -1); + return o === "!" || o === "!!" ? (n(`Verbatim tags aren't resolved, so ${t} is invalid.`), null) : (t[t.length - 1] !== ">" && n("Verbatim tags must end with a >"), o); + } + const [, s, i] = t.match(/^(.*!)([^!]*)$/s); + i || n(`The ${t} tag has no suffix`); + const r = this.tags[s]; + if (r) + try { + return r + decodeURIComponent(i); + } catch (o) { + return n(String(o)), null; + } + return s === "!" ? t : (n(`Could not resolve tag: ${t}`), null); + } + /** + * Given a fully resolved tag, returns its printable string form, + * taking into account current tag prefixes and defaults. + */ + tagString(t) { + for (const [n, s] of Object.entries(this.tags)) + if (t.startsWith(s)) + return n + Cs(t.substring(s.length)); + return t[0] === "!" ? t : `!<${t}>`; + } + toString(t) { + const n = this.yaml.explicit ? [`%YAML ${this.yaml.version || "1.2"}`] : [], s = Object.entries(this.tags); + let i; + if (t && s.length > 0 && _(t.contents)) { + const r = {}; + se(t.contents, (o, a) => { + _(a) && a.tag && (r[a.tag] = !0); + }), i = Object.keys(r); + } else + i = []; + for (const [r, o] of s) + r === "!!" && o === "tag:yaml.org,2002:" || (!t || i.some((a) => a.startsWith(o))) && n.push(`%TAG ${r} ${o}`); + return n.join(` +`); + } +} +M.defaultYaml = { explicit: !1, version: "1.2" }; +M.defaultTags = { "!!": "tag:yaml.org,2002:" }; +function Xn(e) { + if (/[\x00-\x19\s,[\]{}]/.test(e)) { + const n = `Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`; + throw new Error(n); + } + return !0; +} +function Zn(e) { + const t = /* @__PURE__ */ new Set(); + return se(e, { + Value(n, s) { + s.anchor && t.add(s.anchor); + } + }), t; +} +function Cn(e, t) { + for (let n = 1; ; ++n) { + const s = `${e}${n}`; + if (!t.has(s)) + return s; + } +} +function xs(e, t) { + const n = [], s = /* @__PURE__ */ new Map(); + let i = null; + return { + onAnchor: (r) => { + n.push(r), i ?? (i = Zn(e)); + const o = Cn(t, i); + return i.add(o), o; + }, + /** + * With circular references, the source node is only resolved after all + * of its child nodes are. This is why anchors are set only after all of + * the nodes have been created. + */ + setAnchors: () => { + for (const r of n) { + const o = s.get(r); + if (typeof o == "object" && o.anchor && (E(o.node) || I(o.node))) + o.node.anchor = o.anchor; + else { + const a = new Error("Failed to resolve repeated object (this should not happen)"); + throw a.source = r, a; + } + } + }, + sourceObjects: s + }; +} +function Se(e, t, n, s) { + if (s && typeof s == "object") + if (Array.isArray(s)) + for (let i = 0, r = s.length; i < r; ++i) { + const o = s[i], a = Se(e, s, String(i), o); + a === void 0 ? delete s[i] : a !== o && (s[i] = a); + } + else if (s instanceof Map) + for (const i of Array.from(s.keys())) { + const r = s.get(i), o = Se(e, s, i, r); + o === void 0 ? s.delete(i) : o !== r && s.set(i, o); + } + else if (s instanceof Set) + for (const i of Array.from(s)) { + const r = Se(e, s, i, i); + r === void 0 ? s.delete(i) : r !== i && (s.delete(i), s.add(r)); + } + else + for (const [i, r] of Object.entries(s)) { + const o = Se(e, s, i, r); + o === void 0 ? delete s[i] : o !== r && (s[i] = o); + } + return e.call(t, n, s); +} +function F(e, t, n) { + if (Array.isArray(e)) + return e.map((s, i) => F(s, String(i), n)); + if (e && typeof e.toJSON == "function") { + if (!n || !Gn(e)) + return e.toJSON(t, n); + const s = { aliasCount: 0, count: 1, res: void 0 }; + n.anchors.set(e, s), n.onCreate = (r) => { + s.res = r, delete n.onCreate; + }; + const i = e.toJSON(t, n); + return n.onCreate && n.onCreate(i), i; + } + return typeof e == "bigint" && !n?.keep ? Number(e) : e; +} +class Ct { + constructor(t) { + Object.defineProperty(this, U, { value: t }); + } + /** Create a copy of this node. */ + clone() { + const t = Object.create(Object.getPrototypeOf(this), Object.getOwnPropertyDescriptors(this)); + return this.range && (t.range = this.range.slice()), t; + } + /** A plain JavaScript representation of this node. */ + toJS(t, { mapAsMap: n, maxAliasCount: s, onAnchor: i, reviver: r } = {}) { + if (!ne(t)) + throw new TypeError("A document argument is required"); + const o = { + anchors: /* @__PURE__ */ new Map(), + doc: t, + keep: !0, + mapAsMap: n === !0, + mapKeyWarned: !1, + maxAliasCount: typeof s == "number" ? s : 100 + }, a = F(this, "", o); + if (typeof i == "function") + for (const { count: l, res: c } of o.anchors.values()) + i(c, l); + return typeof r == "function" ? Se(r, { "": a }, "", a) : a; + } +} +class Ue extends Ct { + constructor(t) { + super(Zt), this.source = t, Object.defineProperty(this, "tag", { + set() { + throw new Error("Alias nodes cannot have tags"); + } + }); + } + /** + * Resolve the value of this alias within `doc`, finding the last + * instance of the `source` anchor before this node. + */ + resolve(t, n) { + let s; + n?.aliasResolveCache ? s = n.aliasResolveCache : (s = [], se(t, { + Node: (r, o) => { + (Z(o) || Gn(o)) && s.push(o); + } + }), n && (n.aliasResolveCache = s)); + let i; + for (const r of s) { + if (r === this) + break; + r.anchor === this.source && (i = r); + } + return i; + } + toJSON(t, n) { + if (!n) + return { source: this.source }; + const { anchors: s, doc: i, maxAliasCount: r } = n, o = this.resolve(i, n); + if (!o) { + const l = `Unresolved alias (the anchor must be set before the alias): ${this.source}`; + throw new ReferenceError(l); + } + let a = s.get(o); + if (a || (F(o, null, n), a = s.get(o)), !a || a.res === void 0) { + const l = "This should not happen: Alias anchor was not resolved?"; + throw new ReferenceError(l); + } + if (r >= 0 && (a.count += 1, a.aliasCount === 0 && (a.aliasCount = rt(i, o, s)), a.count * a.aliasCount > r)) { + const l = "Excessive alias count indicates a resource exhaustion attack"; + throw new ReferenceError(l); + } + return a.res; + } + toString(t, n, s) { + const i = `*${this.source}`; + if (t) { + if (Xn(this.source), t.options.verifyAliasOrder && !t.anchors.has(this.source)) { + const r = `Unresolved alias (the anchor must be set before the alias): ${this.source}`; + throw new Error(r); + } + if (t.implicitKey) + return `${i} `; + } + return i; + } +} +function rt(e, t, n) { + if (Z(t)) { + const s = t.resolve(e), i = n && s && n.get(s); + return i ? i.count * i.aliasCount : 0; + } else if (I(t)) { + let s = 0; + for (const i of t.items) { + const r = rt(e, i, n); + r > s && (s = r); + } + return s; + } else if (L(t)) { + const s = rt(e, t.key, n), i = rt(e, t.value, n); + return Math.max(s, i); + } + return 1; +} +const xn = (e) => !e || typeof e != "function" && typeof e != "object"; +class v extends Ct { + constructor(t) { + super(W), this.value = t; + } + toJSON(t, n) { + return n?.keep ? this.value : F(this.value, t, n); + } + toString() { + return String(this.value); + } +} +v.BLOCK_FOLDED = "BLOCK_FOLDED"; +v.BLOCK_LITERAL = "BLOCK_LITERAL"; +v.PLAIN = "PLAIN"; +v.QUOTE_DOUBLE = "QUOTE_DOUBLE"; +v.QUOTE_SINGLE = "QUOTE_SINGLE"; +const ei = "tag:yaml.org,2002:"; +function ti(e, t, n) { + if (t) { + const s = n.filter((r) => r.tag === t), i = s.find((r) => !r.format) ?? s[0]; + if (!i) + throw new Error(`Tag ${t} not found`); + return i; + } + return n.find((s) => s.identify?.(e) && !s.format); +} +function Me(e, t, n) { + if (ne(e) && (e = e.contents), _(e)) + return e; + if (L(e)) { + const u = n.schema[te].createNode?.(n.schema, null, n); + return u.items.push(e), u; + } + (e instanceof String || e instanceof Number || e instanceof Boolean || typeof BigInt < "u" && e instanceof BigInt) && (e = e.valueOf()); + const { aliasDuplicateObjects: s, onAnchor: i, onTagObj: r, schema: o, sourceObjects: a } = n; + let l; + if (s && e && typeof e == "object") { + if (l = a.get(e), l) + return l.anchor ?? (l.anchor = i(e)), new Ue(l.anchor); + l = { anchor: null, node: null }, a.set(e, l); + } + t?.startsWith("!!") && (t = ei + t.slice(2)); + let c = ti(e, t, o.tags); + if (!c) { + if (e && typeof e.toJSON == "function" && (e = e.toJSON()), !e || typeof e != "object") { + const u = new v(e); + return l && (l.node = u), u; + } + c = e instanceof Map ? o[te] : Symbol.iterator in Object(e) ? o[Ee] : o[te]; + } + r && (r(c), delete n.onTagObj); + const f = c?.createNode ? c.createNode(n.schema, e, n) : typeof c?.nodeClass?.from == "function" ? c.nodeClass.from(n.schema, e, n) : new v(e); + return t ? f.tag = t : c.default || (f.tag = c.tag), l && (l.node = f), f; +} +function ct(e, t, n) { + let s = n; + for (let i = t.length - 1; i >= 0; --i) { + const r = t[i]; + if (typeof r == "number" && Number.isInteger(r) && r >= 0) { + const o = []; + o[r] = s, s = o; + } else + s = /* @__PURE__ */ new Map([[r, s]]); + } + return Me(s, void 0, { + aliasDuplicateObjects: !1, + keepUndefined: !1, + onAnchor: () => { + throw new Error("This should not happen, please report a bug."); + }, + schema: e, + sourceObjects: /* @__PURE__ */ new Map() + }); +} +const Pe = (e) => e == null || typeof e == "object" && !!e[Symbol.iterator]().next().done; +class es extends Ct { + constructor(t, n) { + super(t), Object.defineProperty(this, "schema", { + value: n, + configurable: !0, + enumerable: !1, + writable: !0 + }); + } + /** + * Create a copy of this collection. + * + * @param schema - If defined, overwrites the original's schema + */ + clone(t) { + const n = Object.create(Object.getPrototypeOf(this), Object.getOwnPropertyDescriptors(this)); + return t && (n.schema = t), n.items = n.items.map((s) => _(s) || L(s) ? s.clone(t) : s), this.range && (n.range = this.range.slice()), n; + } + /** + * Adds a value to the collection. For `!!map` and `!!omap` the value must + * be a Pair instance or a `{ key, value }` object, which may not have a key + * that already exists in the map. + */ + addIn(t, n) { + if (Pe(t)) + this.add(n); + else { + const [s, ...i] = t, r = this.get(s, !0); + if (I(r)) + r.addIn(i, n); + else if (r === void 0 && this.schema) + this.set(s, ct(this.schema, i, n)); + else + throw new Error(`Expected YAML collection at ${s}. Remaining path: ${i}`); + } + } + /** + * Removes a value from the collection. + * @returns `true` if the item was found and removed. + */ + deleteIn(t) { + const [n, ...s] = t; + if (s.length === 0) + return this.delete(n); + const i = this.get(n, !0); + if (I(i)) + return i.deleteIn(s); + throw new Error(`Expected YAML collection at ${n}. Remaining path: ${s}`); + } + /** + * Returns item at `key`, or `undefined` if not found. By default unwraps + * scalar values from their surrounding node; to disable set `keepScalar` to + * `true` (collections are always returned intact). + */ + getIn(t, n) { + const [s, ...i] = t, r = this.get(s, !0); + return i.length === 0 ? !n && E(r) ? r.value : r : I(r) ? r.getIn(i, n) : void 0; + } + hasAllNullValues(t) { + return this.items.every((n) => { + if (!L(n)) + return !1; + const s = n.value; + return s == null || t && E(s) && s.value == null && !s.commentBefore && !s.comment && !s.tag; + }); + } + /** + * Checks if the collection includes a value with the key `key`. + */ + hasIn(t) { + const [n, ...s] = t; + if (s.length === 0) + return this.has(n); + const i = this.get(n, !0); + return I(i) ? i.hasIn(s) : !1; + } + /** + * Sets a value in this collection. For `!!set`, `value` needs to be a + * boolean to add/remove the item from the set. + */ + setIn(t, n) { + const [s, ...i] = t; + if (i.length === 0) + this.set(s, n); + else { + const r = this.get(s, !0); + if (I(r)) + r.setIn(i, n); + else if (r === void 0 && this.schema) + this.set(s, ct(this.schema, i, n)); + else + throw new Error(`Expected YAML collection at ${s}. Remaining path: ${i}`); + } + } +} +const ni = (e) => e.replace(/^(?!$)(?: $)?/gm, "#"); +function H(e, t) { + return /^\n+$/.test(e) ? e.substring(1) : t ? e.replace(/^(?! *$)/gm, t) : e; +} +const oe = (e, t, n) => e.endsWith(` +`) ? H(n, t) : n.includes(` +`) ? ` +` + H(n, t) : (e.endsWith(" ") ? "" : " ") + n, ts = "flow", Ft = "block", ot = "quoted"; +function pt(e, t, n = "flow", { indentAtStart: s, lineWidth: i = 80, minContentWidth: r = 20, onFold: o, onOverflow: a } = {}) { + if (!i || i < 0) + return e; + i < r && (r = 0); + const l = Math.max(1 + r, 1 + i - t.length); + if (e.length <= l) + return e; + const c = [], f = {}; + let u = i - t.length; + typeof s == "number" && (s > i - Math.max(2, r) ? c.push(0) : u = i - s); + let h, p, m = !1, d = -1, g = -1, S = -1; + n === Ft && (d = kn(e, d, t.length), d !== -1 && (u = d + l)); + for (let y; y = e[d += 1]; ) { + if (n === ot && y === "\\") { + switch (g = d, e[d + 1]) { + case "x": + d += 3; + break; + case "u": + d += 5; + break; + case "U": + d += 9; + break; + default: + d += 1; + } + S = d; + } + if (y === ` +`) + n === Ft && (d = kn(e, d, t.length)), u = d + t.length + l, h = void 0; + else { + if (y === " " && p && p !== " " && p !== ` +` && p !== " ") { + const O = e[d + 1]; + O && O !== " " && O !== ` +` && O !== " " && (h = d); + } + if (d >= u) + if (h) + c.push(h), u = h + l, h = void 0; + else if (n === ot) { + for (; p === " " || p === " "; ) + p = y, y = e[d += 1], m = !0; + const O = d > S + 1 ? d - 2 : g - 1; + if (f[O]) + return e; + c.push(O), f[O] = !0, u = O + l, h = void 0; + } else + m = !0; + } + p = y; + } + if (m && a && a(), c.length === 0) + return e; + o && o(); + let A = e.slice(0, c[0]); + for (let y = 0; y < c.length; ++y) { + const O = c[y], b = c[y + 1] || e.length; + O === 0 ? A = ` +${t}${e.slice(0, b)}` : (n === ot && f[O] && (A += `${e[O]}\\`), A += ` +${t}${e.slice(O + 1, b)}`); + } + return A; +} +function kn(e, t, n) { + let s = t, i = t + 1, r = e[i]; + for (; r === " " || r === " "; ) + if (t < i + n) + r = e[++t]; + else { + do + r = e[++t]; + while (r && r !== ` +`); + s = t, i = t + 1, r = e[i]; + } + return s; +} +const gt = (e, t) => ({ + indentAtStart: t ? e.indent.length : e.indentAtStart, + lineWidth: e.options.lineWidth, + minContentWidth: e.options.minContentWidth +}), mt = (e) => /^(%|---|\.\.\.)/m.test(e); +function si(e, t, n) { + if (!t || t < 0) + return !1; + const s = t - n, i = e.length; + if (i <= s) + return !1; + for (let r = 0, o = 0; r < i; ++r) + if (e[r] === ` +`) { + if (r - o > s) + return !0; + if (o = r + 1, i - o <= s) + return !1; + } + return !0; +} +function Be(e, t) { + const n = JSON.stringify(e); + if (t.options.doubleQuotedAsJSON) + return n; + const { implicitKey: s } = t, i = t.options.doubleQuotedMinMultiLineLength, r = t.indent || (mt(e) ? " " : ""); + let o = "", a = 0; + for (let l = 0, c = n[l]; c; c = n[++l]) + if (c === " " && n[l + 1] === "\\" && n[l + 2] === "n" && (o += n.slice(a, l) + "\\ ", l += 1, a = l, c = "\\"), c === "\\") + switch (n[l + 1]) { + case "u": + { + o += n.slice(a, l); + const f = n.substr(l + 2, 4); + switch (f) { + case "0000": + o += "\\0"; + break; + case "0007": + o += "\\a"; + break; + case "000b": + o += "\\v"; + break; + case "001b": + o += "\\e"; + break; + case "0085": + o += "\\N"; + break; + case "00a0": + o += "\\_"; + break; + case "2028": + o += "\\L"; + break; + case "2029": + o += "\\P"; + break; + default: + f.substr(0, 2) === "00" ? o += "\\x" + f.substr(2) : o += n.substr(l, 6); + } + l += 5, a = l + 1; + } + break; + case "n": + if (s || n[l + 2] === '"' || n.length < i) + l += 1; + else { + for (o += n.slice(a, l) + ` + +`; n[l + 2] === "\\" && n[l + 3] === "n" && n[l + 4] !== '"'; ) + o += ` +`, l += 2; + o += r, n[l + 2] === " " && (o += "\\"), l += 1, a = l + 1; + } + break; + default: + l += 1; + } + return o = a ? o + n.slice(a) : n, s ? o : pt(o, r, ot, gt(t, !1)); +} +function Ut(e, t) { + if (t.options.singleQuote === !1 || t.implicitKey && e.includes(` +`) || /[ \t]\n|\n[ \t]/.test(e)) + return Be(e, t); + const n = t.indent || (mt(e) ? " " : ""), s = "'" + e.replace(/'/g, "''").replace(/\n+/g, `$& +${n}`) + "'"; + return t.implicitKey ? s : pt(s, n, ts, gt(t, !1)); +} +function Oe(e, t) { + const { singleQuote: n } = t.options; + let s; + if (n === !1) + s = Be; + else { + const i = e.includes('"'), r = e.includes("'"); + i && !r ? s = Ut : r && !i ? s = Be : s = n ? Ut : Be; + } + return s(e, t); +} +let Vt; +try { + Vt = new RegExp(`(^|(? +`; + let u, h; + for (h = n.length; h > 0; --h) { + const b = n[h - 1]; + if (b !== ` +` && b !== " " && b !== " ") + break; + } + let p = n.substring(h); + const m = p.indexOf(` +`); + m === -1 ? u = "-" : n === p || m !== p.length - 1 ? (u = "+", r && r()) : u = "", p && (n = n.slice(0, -p.length), p[p.length - 1] === ` +` && (p = p.slice(0, -1)), p = p.replace(Vt, `$&${c}`)); + let d = !1, g, S = -1; + for (g = 0; g < n.length; ++g) { + const b = n[g]; + if (b === " ") + d = !0; + else if (b === ` +`) + S = g; + else + break; + } + let A = n.substring(0, S < g ? S + 1 : g); + A && (n = n.substring(A.length), A = A.replace(/\n+/g, `$&${c}`)); + let O = (d ? c ? "2" : "1" : "") + u; + if (e && (O += " " + a(e.replace(/ ?[\r\n]+/g, " ")), i && i()), !f) { + const b = n.replace(/\n+/g, ` +$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${c}`); + let w = !1; + const k = gt(s, !0); + o !== "folded" && t !== v.BLOCK_FOLDED && (k.onOverflow = () => { + w = !0; + }); + const N = pt(`${A}${b}${p}`, c, Ft, k); + if (!w) + return `>${O} +${c}${N}`; + } + return n = n.replace(/\n+/g, `$&${c}`), `|${O} +${c}${A}${n}${p}`; +} +function ii(e, t, n, s) { + const { type: i, value: r } = e, { actualString: o, implicitKey: a, indent: l, indentStep: c, inFlow: f } = t; + if (a && r.includes(` +`) || f && /[[\]{},]/.test(r)) + return Oe(r, t); + if (/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(r)) + return a || f || !r.includes(` +`) ? Oe(r, t) : lt(e, t, n, s); + if (!a && !f && i !== v.PLAIN && r.includes(` +`)) + return lt(e, t, n, s); + if (mt(r)) { + if (l === "") + return t.forceBlockIndent = !0, lt(e, t, n, s); + if (a && l === c) + return Oe(r, t); + } + const u = r.replace(/\n+/g, `$& +${l}`); + if (o) { + const h = (d) => d.default && d.tag !== "tag:yaml.org,2002:str" && d.test?.test(u), { compat: p, tags: m } = t.doc.schema; + if (m.some(h) || p?.some(h)) + return Oe(r, t); + } + return a ? u : pt(u, l, ts, gt(t, !1)); +} +function Ve(e, t, n, s) { + const { implicitKey: i, inFlow: r } = t, o = typeof e.value == "string" ? e : Object.assign({}, e, { value: String(e.value) }); + let { type: a } = e; + a !== v.QUOTE_DOUBLE && /[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value) && (a = v.QUOTE_DOUBLE); + const l = (f) => { + switch (f) { + case v.BLOCK_FOLDED: + case v.BLOCK_LITERAL: + return i || r ? Oe(o.value, t) : lt(o, t, n, s); + case v.QUOTE_DOUBLE: + return Be(o.value, t); + case v.QUOTE_SINGLE: + return Ut(o.value, t); + case v.PLAIN: + return ii(o, t, n, s); + default: + return null; + } + }; + let c = l(a); + if (c === null) { + const { defaultKeyType: f, defaultStringType: u } = t.options, h = i && f || u; + if (c = l(h), c === null) + throw new Error(`Unsupported default string type ${h}`); + } + return c; +} +function ns(e, t) { + const n = Object.assign({ + blockQuote: !0, + commentString: ni, + defaultKeyType: null, + defaultStringType: "PLAIN", + directives: null, + doubleQuotedAsJSON: !1, + doubleQuotedMinMultiLineLength: 40, + falseStr: "false", + flowCollectionPadding: !0, + indentSeq: !0, + lineWidth: 80, + minContentWidth: 20, + nullStr: "null", + simpleKeys: !1, + singleQuote: null, + trueStr: "true", + verifyAliasOrder: !0 + }, e.schema.toStringOptions, t); + let s; + switch (n.collectionStyle) { + case "block": + s = !1; + break; + case "flow": + s = !0; + break; + default: + s = null; + } + return { + anchors: /* @__PURE__ */ new Set(), + doc: e, + flowCollectionPadding: n.flowCollectionPadding ? " " : "", + indent: "", + indentStep: typeof n.indent == "number" ? " ".repeat(n.indent) : " ", + inFlow: s, + options: n + }; +} +function ri(e, t) { + if (t.tag) { + const i = e.filter((r) => r.tag === t.tag); + if (i.length > 0) + return i.find((r) => r.format === t.format) ?? i[0]; + } + let n, s; + if (E(t)) { + s = t.value; + let i = e.filter((r) => r.identify?.(s)); + if (i.length > 1) { + const r = i.filter((o) => o.test); + r.length > 0 && (i = r); + } + n = i.find((r) => r.format === t.format) ?? i.find((r) => !r.format); + } else + s = t, n = e.find((i) => i.nodeClass && s instanceof i.nodeClass); + if (!n) { + const i = s?.constructor?.name ?? (s === null ? "null" : typeof s); + throw new Error(`Tag not resolved for ${i} value`); + } + return n; +} +function oi(e, t, { anchors: n, doc: s }) { + if (!s.directives) + return ""; + const i = [], r = (E(e) || I(e)) && e.anchor; + r && Xn(r) && (n.add(r), i.push(`&${r}`)); + const o = e.tag ?? (t.default ? null : t.tag); + return o && i.push(s.directives.tagString(o)), i.join(" "); +} +function ve(e, t, n, s) { + if (L(e)) + return e.toString(t, n, s); + if (Z(e)) { + if (t.doc.directives) + return e.toString(t); + if (t.resolvedAliases?.has(e)) + throw new TypeError("Cannot stringify circular structure without alias nodes"); + t.resolvedAliases ? t.resolvedAliases.add(e) : t.resolvedAliases = /* @__PURE__ */ new Set([e]), e = e.resolve(t.doc); + } + let i; + const r = _(e) ? e : t.doc.createNode(e, { onTagObj: (l) => i = l }); + i ?? (i = ri(t.doc.schema.tags, r)); + const o = oi(r, i, t); + o.length > 0 && (t.indentAtStart = (t.indentAtStart ?? 0) + o.length + 1); + const a = typeof i.stringify == "function" ? i.stringify(r, t, n, s) : E(r) ? Ve(r, t, n, s) : r.toString(t, n, s); + return o ? E(r) || a[0] === "{" || a[0] === "[" ? `${o} ${a}` : `${o} +${t.indent}${a}` : a; +} +function li({ key: e, value: t }, n, s, i) { + const { allNullValues: r, doc: o, indent: a, indentStep: l, options: { commentString: c, indentSeq: f, simpleKeys: u } } = n; + let h = _(e) && e.comment || null; + if (u) { + if (h) + throw new Error("With simple keys, key nodes cannot have comments"); + if (I(e) || !_(e) && typeof e == "object") { + const k = "With simple keys, collection cannot be used as a key value"; + throw new Error(k); + } + } + let p = !u && (!e || h && t == null && !n.inFlow || I(e) || (E(e) ? e.type === v.BLOCK_FOLDED || e.type === v.BLOCK_LITERAL : typeof e == "object")); + n = Object.assign({}, n, { + allNullValues: !1, + implicitKey: !p && (u || !r), + indent: a + l + }); + let m = !1, d = !1, g = ve(e, n, () => m = !0, () => d = !0); + if (!p && !n.inFlow && g.length > 1024) { + if (u) + throw new Error("With simple keys, single line scalar must not span more than 1024 characters"); + p = !0; + } + if (n.inFlow) { + if (r || t == null) + return m && s && s(), g === "" ? "?" : p ? `? ${g}` : g; + } else if (r && !u || t == null && p) + return g = `? ${g}`, h && !m ? g += oe(g, n.indent, c(h)) : d && i && i(), g; + m && (h = null), p ? (h && (g += oe(g, n.indent, c(h))), g = `? ${g} +${a}:`) : (g = `${g}:`, h && (g += oe(g, n.indent, c(h)))); + let S, A, y; + _(t) ? (S = !!t.spaceBefore, A = t.commentBefore, y = t.comment) : (S = !1, A = null, y = null, t && typeof t == "object" && (t = o.createNode(t))), n.implicitKey = !1, !p && !h && E(t) && (n.indentAtStart = g.length + 1), d = !1, !f && l.length >= 2 && !n.inFlow && !p && fe(t) && !t.flow && !t.tag && !t.anchor && (n.indent = n.indent.substring(2)); + let O = !1; + const b = ve(t, n, () => O = !0, () => d = !0); + let w = " "; + if (h || S || A) { + if (w = S ? ` +` : "", A) { + const k = c(A); + w += ` +${H(k, n.indent)}`; + } + b === "" && !n.inFlow ? w === ` +` && (w = ` + +`) : w += ` +${n.indent}`; + } else if (!p && I(t)) { + const k = b[0], N = b.indexOf(` +`), j = N !== -1, D = n.inFlow ?? t.flow ?? t.items.length === 0; + if (j || !D) { + let C = !1; + if (j && (k === "&" || k === "!")) { + let $ = b.indexOf(" "); + k === "&" && $ !== -1 && $ < N && b[$ + 1] === "!" && ($ = b.indexOf(" ", $ + 1)), ($ === -1 || N < $) && (C = !0); + } + C || (w = ` +${n.indent}`); + } + } else (b === "" || b[0] === ` +`) && (w = ""); + return g += w + b, n.inFlow ? O && s && s() : y && !O ? g += oe(g, n.indent, c(y)) : d && i && i(), g; +} +function ss(e, t) { + (e === "debug" || e === "warn") && console.warn(t); +} +const Xe = "<<", z = { + identify: (e) => e === Xe || typeof e == "symbol" && e.description === Xe, + default: "key", + tag: "tag:yaml.org,2002:merge", + test: /^<<$/, + resolve: () => Object.assign(new v(Symbol(Xe)), { + addToJSMap: is + }), + stringify: () => Xe +}, ai = (e, t) => (z.identify(t) || E(t) && (!t.type || t.type === v.PLAIN) && z.identify(t.value)) && e?.doc.schema.tags.some((n) => n.tag === z.tag && n.default); +function is(e, t, n) { + if (n = e && Z(n) ? n.resolve(e.doc) : n, fe(n)) + for (const s of n.items) + jt(e, t, s); + else if (Array.isArray(n)) + for (const s of n) + jt(e, t, s); + else + jt(e, t, n); +} +function jt(e, t, n) { + const s = e && Z(n) ? n.resolve(e.doc) : n; + if (!ce(s)) + throw new Error("Merge sources must be maps or map aliases"); + const i = s.toJSON(null, e, Map); + for (const [r, o] of i) + t instanceof Map ? t.has(r) || t.set(r, o) : t instanceof Set ? t.add(r) : Object.prototype.hasOwnProperty.call(t, r) || Object.defineProperty(t, r, { + value: o, + writable: !0, + enumerable: !0, + configurable: !0 + }); + return t; +} +function rs(e, t, { key: n, value: s }) { + if (_(n) && n.addToJSMap) + n.addToJSMap(e, t, s); + else if (ai(e, n)) + is(e, t, s); + else { + const i = F(n, "", e); + if (t instanceof Map) + t.set(i, F(s, i, e)); + else if (t instanceof Set) + t.add(i); + else { + const r = ci(n, i, e), o = F(s, r, e); + r in t ? Object.defineProperty(t, r, { + value: o, + writable: !0, + enumerable: !0, + configurable: !0 + }) : t[r] = o; + } + } + return t; +} +function ci(e, t, n) { + if (t === null) + return ""; + if (typeof t != "object") + return String(t); + if (_(e) && n?.doc) { + const s = ns(n.doc, {}); + s.anchors = /* @__PURE__ */ new Set(); + for (const r of n.anchors.keys()) + s.anchors.add(r.anchor); + s.inFlow = !0, s.inStringifyKey = !0; + const i = e.toString(s); + if (!n.mapKeyWarned) { + let r = JSON.stringify(i); + r.length > 40 && (r = r.substring(0, 36) + '..."'), ss(n.doc.options.logLevel, `Keys with collection values will be stringified due to JS Object restrictions: ${r}. Set mapAsMap: true to use object keys.`), n.mapKeyWarned = !0; + } + return i; + } + return JSON.stringify(t); +} +function xt(e, t, n) { + const s = Me(e, void 0, n), i = Me(t, void 0, n); + return new B(s, i); +} +class B { + constructor(t, n = null) { + Object.defineProperty(this, U, { value: Yn }), this.key = t, this.value = n; + } + clone(t) { + let { key: n, value: s } = this; + return _(n) && (n = n.clone(t)), _(s) && (s = s.clone(t)), new B(n, s); + } + toJSON(t, n) { + const s = n?.mapAsMap ? /* @__PURE__ */ new Map() : {}; + return rs(n, s, this); + } + toString(t, n, s) { + return t?.doc ? li(this, t, n, s) : JSON.stringify(this); + } +} +function os(e, t, n) { + return (t.inFlow ?? e.flow ? ui : fi)(e, t, n); +} +function fi({ comment: e, items: t }, n, { blockItemPrefix: s, flowChars: i, itemIndent: r, onChompKeep: o, onComment: a }) { + const { indent: l, options: { commentString: c } } = n, f = Object.assign({}, n, { indent: r, type: null }); + let u = !1; + const h = []; + for (let m = 0; m < t.length; ++m) { + const d = t[m]; + let g = null; + if (_(d)) + !u && d.spaceBefore && h.push(""), ft(n, h, d.commentBefore, u), d.comment && (g = d.comment); + else if (L(d)) { + const A = _(d.key) ? d.key : null; + A && (!u && A.spaceBefore && h.push(""), ft(n, h, A.commentBefore, u)); + } + u = !1; + let S = ve(d, f, () => g = null, () => u = !0); + g && (S += oe(S, r, c(g))), u && g && (u = !1), h.push(s + S); + } + let p; + if (h.length === 0) + p = i.start + i.end; + else { + p = h[0]; + for (let m = 1; m < h.length; ++m) { + const d = h[m]; + p += d ? ` +${l}${d}` : ` +`; + } + } + return e ? (p += ` +` + H(c(e), l), a && a()) : u && o && o(), p; +} +function ui({ items: e }, t, { flowChars: n, itemIndent: s }) { + const { indent: i, indentStep: r, flowCollectionPadding: o, options: { commentString: a } } = t; + s += r; + const l = Object.assign({}, t, { + indent: s, + inFlow: !0, + type: null + }); + let c = !1, f = 0; + const u = []; + for (let m = 0; m < e.length; ++m) { + const d = e[m]; + let g = null; + if (_(d)) + d.spaceBefore && u.push(""), ft(t, u, d.commentBefore, !1), d.comment && (g = d.comment); + else if (L(d)) { + const A = _(d.key) ? d.key : null; + A && (A.spaceBefore && u.push(""), ft(t, u, A.commentBefore, !1), A.comment && (c = !0)); + const y = _(d.value) ? d.value : null; + y ? (y.comment && (g = y.comment), y.commentBefore && (c = !0)) : d.value == null && A?.comment && (g = A.comment); + } + g && (c = !0); + let S = ve(d, l, () => g = null); + m < e.length - 1 && (S += ","), g && (S += oe(S, s, a(g))), !c && (u.length > f || S.includes(` +`)) && (c = !0), u.push(S), f = u.length; + } + const { start: h, end: p } = n; + if (u.length === 0) + return h + p; + if (!c) { + const m = u.reduce((d, g) => d + g.length + 2, 2); + c = t.options.lineWidth > 0 && m > t.options.lineWidth; + } + if (c) { + let m = h; + for (const d of u) + m += d ? ` +${r}${i}${d}` : ` +`; + return `${m} +${i}${p}`; + } else + return `${h}${o}${u.join(" ")}${o}${p}`; +} +function ft({ indent: e, options: { commentString: t } }, n, s, i) { + if (s && i && (s = s.replace(/^\n+/, "")), s) { + const r = H(t(s), e); + n.push(r.trimStart()); + } +} +function le(e, t) { + const n = E(t) ? t.value : t; + for (const s of e) + if (L(s) && (s.key === t || s.key === n || E(s.key) && s.key.value === n)) + return s; +} +class K extends es { + static get tagName() { + return "tag:yaml.org,2002:map"; + } + constructor(t) { + super(te, t), this.items = []; + } + /** + * A generic collection parsing method that can be extended + * to other node classes that inherit from YAMLMap + */ + static from(t, n, s) { + const { keepUndefined: i, replacer: r } = s, o = new this(t), a = (l, c) => { + if (typeof r == "function") + c = r.call(n, l, c); + else if (Array.isArray(r) && !r.includes(l)) + return; + (c !== void 0 || i) && o.items.push(xt(l, c, s)); + }; + if (n instanceof Map) + for (const [l, c] of n) + a(l, c); + else if (n && typeof n == "object") + for (const l of Object.keys(n)) + a(l, n[l]); + return typeof t.sortMapEntries == "function" && o.items.sort(t.sortMapEntries), o; + } + /** + * Adds a value to the collection. + * + * @param overwrite - If not set `true`, using a key that is already in the + * collection will throw. Otherwise, overwrites the previous value. + */ + add(t, n) { + let s; + L(t) ? s = t : !t || typeof t != "object" || !("key" in t) ? s = new B(t, t?.value) : s = new B(t.key, t.value); + const i = le(this.items, s.key), r = this.schema?.sortMapEntries; + if (i) { + if (!n) + throw new Error(`Key ${s.key} already set`); + E(i.value) && xn(s.value) ? i.value.value = s.value : i.value = s.value; + } else if (r) { + const o = this.items.findIndex((a) => r(s, a) < 0); + o === -1 ? this.items.push(s) : this.items.splice(o, 0, s); + } else + this.items.push(s); + } + delete(t) { + const n = le(this.items, t); + return n ? this.items.splice(this.items.indexOf(n), 1).length > 0 : !1; + } + get(t, n) { + const i = le(this.items, t)?.value; + return (!n && E(i) ? i.value : i) ?? void 0; + } + has(t) { + return !!le(this.items, t); + } + set(t, n) { + this.add(new B(t, n), !0); + } + /** + * @param ctx - Conversion context, originally set in Document#toJS() + * @param {Class} Type - If set, forces the returned collection type + * @returns Instance of Type, Map, or Object + */ + toJSON(t, n, s) { + const i = s ? new s() : n?.mapAsMap ? /* @__PURE__ */ new Map() : {}; + n?.onCreate && n.onCreate(i); + for (const r of this.items) + rs(n, i, r); + return i; + } + toString(t, n, s) { + if (!t) + return JSON.stringify(this); + for (const i of this.items) + if (!L(i)) + throw new Error(`Map items must all be pairs; found ${JSON.stringify(i)} instead`); + return !t.allNullValues && this.hasAllNullValues(!1) && (t = Object.assign({}, t, { allNullValues: !0 })), os(this, t, { + blockItemPrefix: "", + flowChars: { start: "{", end: "}" }, + itemIndent: t.indent || "", + onChompKeep: s, + onComment: n + }); + } +} +const Le = { + collection: "map", + default: !0, + nodeClass: K, + tag: "tag:yaml.org,2002:map", + resolve(e, t) { + return ce(e) || t("Expected a mapping for this tag"), e; + }, + createNode: (e, t, n) => K.from(e, t, n) +}; +class X extends es { + static get tagName() { + return "tag:yaml.org,2002:seq"; + } + constructor(t) { + super(Ee, t), this.items = []; + } + add(t) { + this.items.push(t); + } + /** + * Removes a value from the collection. + * + * `key` must contain a representation of an integer for this to succeed. + * It may be wrapped in a `Scalar`. + * + * @returns `true` if the item was found and removed. + */ + delete(t) { + const n = Ze(t); + return typeof n != "number" ? !1 : this.items.splice(n, 1).length > 0; + } + get(t, n) { + const s = Ze(t); + if (typeof s != "number") + return; + const i = this.items[s]; + return !n && E(i) ? i.value : i; + } + /** + * Checks if the collection includes a value with the key `key`. + * + * `key` must contain a representation of an integer for this to succeed. + * It may be wrapped in a `Scalar`. + */ + has(t) { + const n = Ze(t); + return typeof n == "number" && n < this.items.length; + } + /** + * Sets a value in this collection. For `!!set`, `value` needs to be a + * boolean to add/remove the item from the set. + * + * If `key` does not contain a representation of an integer, this will throw. + * It may be wrapped in a `Scalar`. + */ + set(t, n) { + const s = Ze(t); + if (typeof s != "number") + throw new Error(`Expected a valid index, not ${t}.`); + const i = this.items[s]; + E(i) && xn(n) ? i.value = n : this.items[s] = n; + } + toJSON(t, n) { + const s = []; + n?.onCreate && n.onCreate(s); + let i = 0; + for (const r of this.items) + s.push(F(r, String(i++), n)); + return s; + } + toString(t, n, s) { + return t ? os(this, t, { + blockItemPrefix: "- ", + flowChars: { start: "[", end: "]" }, + itemIndent: (t.indent || "") + " ", + onChompKeep: s, + onComment: n + }) : JSON.stringify(this); + } + static from(t, n, s) { + const { replacer: i } = s, r = new this(t); + if (n && Symbol.iterator in Object(n)) { + let o = 0; + for (let a of n) { + if (typeof i == "function") { + const l = n instanceof Set ? a : String(o++); + a = i.call(n, l, a); + } + r.items.push(Me(a, void 0, s)); + } + } + return r; + } +} +function Ze(e) { + let t = E(e) ? e.value : e; + return t && typeof t == "string" && (t = Number(t)), typeof t == "number" && Number.isInteger(t) && t >= 0 ? t : null; +} +const Ie = { + collection: "seq", + default: !0, + nodeClass: X, + tag: "tag:yaml.org,2002:seq", + resolve(e, t) { + return fe(e) || t("Expected a sequence for this tag"), e; + }, + createNode: (e, t, n) => X.from(e, t, n) +}, yt = { + identify: (e) => typeof e == "string", + default: !0, + tag: "tag:yaml.org,2002:str", + resolve: (e) => e, + stringify(e, t, n, s) { + return t = Object.assign({ actualString: !0 }, t), Ve(e, t, n, s); + } +}, bt = { + identify: (e) => e == null, + createNode: () => new v(null), + default: !0, + tag: "tag:yaml.org,2002:null", + test: /^(?:~|[Nn]ull|NULL)?$/, + resolve: () => new v(null), + stringify: ({ source: e }, t) => typeof e == "string" && bt.test.test(e) ? e : t.options.nullStr +}, en = { + identify: (e) => typeof e == "boolean", + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/, + resolve: (e) => new v(e[0] === "t" || e[0] === "T"), + stringify({ source: e, value: t }, n) { + if (e && en.test.test(e)) { + const s = e[0] === "t" || e[0] === "T"; + if (t === s) + return e; + } + return t ? n.options.trueStr : n.options.falseStr; + } +}; +function J({ format: e, minFractionDigits: t, tag: n, value: s }) { + if (typeof s == "bigint") + return String(s); + const i = typeof s == "number" ? s : Number(s); + if (!isFinite(i)) + return isNaN(i) ? ".nan" : i < 0 ? "-.inf" : ".inf"; + let r = JSON.stringify(s); + if (!e && t && (!n || n === "tag:yaml.org,2002:float") && /^\d/.test(r)) { + let o = r.indexOf("."); + o < 0 && (o = r.length, r += "."); + let a = t - (r.length - o - 1); + for (; a-- > 0; ) + r += "0"; + } + return r; +} +const ls = { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/, + resolve: (e) => e.slice(-3).toLowerCase() === "nan" ? NaN : e[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, + stringify: J +}, as = { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + format: "EXP", + test: /^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/, + resolve: (e) => parseFloat(e), + stringify(e) { + const t = Number(e.value); + return isFinite(t) ? t.toExponential() : J(e); + } +}, cs = { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/, + resolve(e) { + const t = new v(parseFloat(e)), n = e.indexOf("."); + return n !== -1 && e[e.length - 1] === "0" && (t.minFractionDigits = e.length - n - 1), t; + }, + stringify: J +}, wt = (e) => typeof e == "bigint" || Number.isInteger(e), tn = (e, t, n, { intAsBigInt: s }) => s ? BigInt(e) : parseInt(e.substring(t), n); +function fs(e, t, n) { + const { value: s } = e; + return wt(s) && s >= 0 ? n + s.toString(t) : J(e); +} +const us = { + identify: (e) => wt(e) && e >= 0, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "OCT", + test: /^0o[0-7]+$/, + resolve: (e, t, n) => tn(e, 2, 8, n), + stringify: (e) => fs(e, 8, "0o") +}, hs = { + identify: wt, + default: !0, + tag: "tag:yaml.org,2002:int", + test: /^[-+]?[0-9]+$/, + resolve: (e, t, n) => tn(e, 0, 10, n), + stringify: J +}, ds = { + identify: (e) => wt(e) && e >= 0, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "HEX", + test: /^0x[0-9a-fA-F]+$/, + resolve: (e, t, n) => tn(e, 2, 16, n), + stringify: (e) => fs(e, 16, "0x") +}, hi = [ + Le, + Ie, + yt, + bt, + en, + us, + hs, + ds, + ls, + as, + cs +]; +function Sn(e) { + return typeof e == "bigint" || Number.isInteger(e); +} +const Ce = ({ value: e }) => JSON.stringify(e), di = [ + { + identify: (e) => typeof e == "string", + default: !0, + tag: "tag:yaml.org,2002:str", + resolve: (e) => e, + stringify: Ce + }, + { + identify: (e) => e == null, + createNode: () => new v(null), + default: !0, + tag: "tag:yaml.org,2002:null", + test: /^null$/, + resolve: () => null, + stringify: Ce + }, + { + identify: (e) => typeof e == "boolean", + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^true$|^false$/, + resolve: (e) => e === "true", + stringify: Ce + }, + { + identify: Sn, + default: !0, + tag: "tag:yaml.org,2002:int", + test: /^-?(?:0|[1-9][0-9]*)$/, + resolve: (e, t, { intAsBigInt: n }) => n ? BigInt(e) : parseInt(e, 10), + stringify: ({ value: e }) => Sn(e) ? e.toString() : JSON.stringify(e) + }, + { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/, + resolve: (e) => parseFloat(e), + stringify: Ce + } +], pi = { + default: !0, + tag: "", + test: /^/, + resolve(e, t) { + return t(`Unresolved plain scalar ${JSON.stringify(e)}`), e; + } +}, gi = [Le, Ie].concat(di, pi), nn = { + identify: (e) => e instanceof Uint8Array, + // Buffer inherits from Uint8Array + default: !1, + tag: "tag:yaml.org,2002:binary", + /** + * Returns a Buffer in node and an Uint8Array in browsers + * + * To use the resulting buffer as an image, you'll want to do something like: + * + * const blob = new Blob([buffer], { type: 'image/jpeg' }) + * document.querySelector('#photo').src = URL.createObjectURL(blob) + */ + resolve(e, t) { + if (typeof atob == "function") { + const n = atob(e.replace(/[\n\r]/g, "")), s = new Uint8Array(n.length); + for (let i = 0; i < n.length; ++i) + s[i] = n.charCodeAt(i); + return s; + } else + return t("This environment does not support reading binary tags; either Buffer or atob is required"), e; + }, + stringify({ comment: e, type: t, value: n }, s, i, r) { + if (!n) + return ""; + const o = n; + let a; + if (typeof btoa == "function") { + let l = ""; + for (let c = 0; c < o.length; ++c) + l += String.fromCharCode(o[c]); + a = btoa(l); + } else + throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required"); + if (t ?? (t = v.BLOCK_LITERAL), t !== v.QUOTE_DOUBLE) { + const l = Math.max(s.options.lineWidth - s.indent.length, s.options.minContentWidth), c = Math.ceil(a.length / l), f = new Array(c); + for (let u = 0, h = 0; u < c; ++u, h += l) + f[u] = a.substr(h, l); + a = f.join(t === v.BLOCK_LITERAL ? ` +` : " "); + } + return Ve({ comment: e, type: t, value: a }, s, i, r); + } +}; +function ps(e, t) { + if (fe(e)) + for (let n = 0; n < e.items.length; ++n) { + let s = e.items[n]; + if (!L(s)) { + if (ce(s)) { + s.items.length > 1 && t("Each pair must have its own sequence indicator"); + const i = s.items[0] || new B(new v(null)); + if (s.commentBefore && (i.key.commentBefore = i.key.commentBefore ? `${s.commentBefore} +${i.key.commentBefore}` : s.commentBefore), s.comment) { + const r = i.value ?? i.key; + r.comment = r.comment ? `${s.comment} +${r.comment}` : s.comment; + } + s = i; + } + e.items[n] = L(s) ? s : new B(s); + } + } + else + t("Expected a sequence for this tag"); + return e; +} +function gs(e, t, n) { + const { replacer: s } = n, i = new X(e); + i.tag = "tag:yaml.org,2002:pairs"; + let r = 0; + if (t && Symbol.iterator in Object(t)) + for (let o of t) { + typeof s == "function" && (o = s.call(t, String(r++), o)); + let a, l; + if (Array.isArray(o)) + if (o.length === 2) + a = o[0], l = o[1]; + else + throw new TypeError(`Expected [key, value] tuple: ${o}`); + else if (o && o instanceof Object) { + const c = Object.keys(o); + if (c.length === 1) + a = c[0], l = o[a]; + else + throw new TypeError(`Expected tuple with one key, not ${c.length} keys`); + } else + a = o; + i.items.push(xt(a, l, n)); + } + return i; +} +const sn = { + collection: "seq", + default: !1, + tag: "tag:yaml.org,2002:pairs", + resolve: ps, + createNode: gs +}; +class Ae extends X { + constructor() { + super(), this.add = K.prototype.add.bind(this), this.delete = K.prototype.delete.bind(this), this.get = K.prototype.get.bind(this), this.has = K.prototype.has.bind(this), this.set = K.prototype.set.bind(this), this.tag = Ae.tag; + } + /** + * If `ctx` is given, the return type is actually `Map`, + * but TypeScript won't allow widening the signature of a child method. + */ + toJSON(t, n) { + if (!n) + return super.toJSON(t); + const s = /* @__PURE__ */ new Map(); + n?.onCreate && n.onCreate(s); + for (const i of this.items) { + let r, o; + if (L(i) ? (r = F(i.key, "", n), o = F(i.value, r, n)) : r = F(i, "", n), s.has(r)) + throw new Error("Ordered maps must not include duplicate keys"); + s.set(r, o); + } + return s; + } + static from(t, n, s) { + const i = gs(t, n, s), r = new this(); + return r.items = i.items, r; + } +} +Ae.tag = "tag:yaml.org,2002:omap"; +const rn = { + collection: "seq", + identify: (e) => e instanceof Map, + nodeClass: Ae, + default: !1, + tag: "tag:yaml.org,2002:omap", + resolve(e, t) { + const n = ps(e, t), s = []; + for (const { key: i } of n.items) + E(i) && (s.includes(i.value) ? t(`Ordered maps must not include duplicate keys: ${i.value}`) : s.push(i.value)); + return Object.assign(new Ae(), n); + }, + createNode: (e, t, n) => Ae.from(e, t, n) +}; +function ms({ value: e, source: t }, n) { + return t && (e ? ys : bs).test.test(t) ? t : e ? n.options.trueStr : n.options.falseStr; +} +const ys = { + identify: (e) => e === !0, + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/, + resolve: () => new v(!0), + stringify: ms +}, bs = { + identify: (e) => e === !1, + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/, + resolve: () => new v(!1), + stringify: ms +}, mi = { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/, + resolve: (e) => e.slice(-3).toLowerCase() === "nan" ? NaN : e[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, + stringify: J +}, yi = { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + format: "EXP", + test: /^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/, + resolve: (e) => parseFloat(e.replace(/_/g, "")), + stringify(e) { + const t = Number(e.value); + return isFinite(t) ? t.toExponential() : J(e); + } +}, bi = { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/, + resolve(e) { + const t = new v(parseFloat(e.replace(/_/g, ""))), n = e.indexOf("."); + if (n !== -1) { + const s = e.substring(n + 1).replace(/_/g, ""); + s[s.length - 1] === "0" && (t.minFractionDigits = s.length); + } + return t; + }, + stringify: J +}, Je = (e) => typeof e == "bigint" || Number.isInteger(e); +function kt(e, t, n, { intAsBigInt: s }) { + const i = e[0]; + if ((i === "-" || i === "+") && (t += 1), e = e.substring(t).replace(/_/g, ""), s) { + switch (n) { + case 2: + e = `0b${e}`; + break; + case 8: + e = `0o${e}`; + break; + case 16: + e = `0x${e}`; + break; + } + const o = BigInt(e); + return i === "-" ? BigInt(-1) * o : o; + } + const r = parseInt(e, n); + return i === "-" ? -1 * r : r; +} +function on(e, t, n) { + const { value: s } = e; + if (Je(s)) { + const i = s.toString(t); + return s < 0 ? "-" + n + i.substr(1) : n + i; + } + return J(e); +} +const wi = { + identify: Je, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "BIN", + test: /^[-+]?0b[0-1_]+$/, + resolve: (e, t, n) => kt(e, 2, 2, n), + stringify: (e) => on(e, 2, "0b") +}, ki = { + identify: Je, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "OCT", + test: /^[-+]?0[0-7_]+$/, + resolve: (e, t, n) => kt(e, 1, 8, n), + stringify: (e) => on(e, 8, "0") +}, Si = { + identify: Je, + default: !0, + tag: "tag:yaml.org,2002:int", + test: /^[-+]?[0-9][0-9_]*$/, + resolve: (e, t, n) => kt(e, 0, 10, n), + stringify: J +}, Oi = { + identify: Je, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "HEX", + test: /^[-+]?0x[0-9a-fA-F_]+$/, + resolve: (e, t, n) => kt(e, 2, 16, n), + stringify: (e) => on(e, 16, "0x") +}; +class Ne extends K { + constructor(t) { + super(t), this.tag = Ne.tag; + } + add(t) { + let n; + L(t) ? n = t : t && typeof t == "object" && "key" in t && "value" in t && t.value === null ? n = new B(t.key, null) : n = new B(t, null), le(this.items, n.key) || this.items.push(n); + } + /** + * If `keepPair` is `true`, returns the Pair matching `key`. + * Otherwise, returns the value of that Pair's key. + */ + get(t, n) { + const s = le(this.items, t); + return !n && L(s) ? E(s.key) ? s.key.value : s.key : s; + } + set(t, n) { + if (typeof n != "boolean") + throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof n}`); + const s = le(this.items, t); + s && !n ? this.items.splice(this.items.indexOf(s), 1) : !s && n && this.items.push(new B(t)); + } + toJSON(t, n) { + return super.toJSON(t, n, Set); + } + toString(t, n, s) { + if (!t) + return JSON.stringify(this); + if (this.hasAllNullValues(!0)) + return super.toString(Object.assign({}, t, { allNullValues: !0 }), n, s); + throw new Error("Set items must all have null values"); + } + static from(t, n, s) { + const { replacer: i } = s, r = new this(t); + if (n && Symbol.iterator in Object(n)) + for (let o of n) + typeof i == "function" && (o = i.call(n, o, o)), r.items.push(xt(o, null, s)); + return r; + } +} +Ne.tag = "tag:yaml.org,2002:set"; +const ln = { + collection: "map", + identify: (e) => e instanceof Set, + nodeClass: Ne, + default: !1, + tag: "tag:yaml.org,2002:set", + createNode: (e, t, n) => Ne.from(e, t, n), + resolve(e, t) { + if (ce(e)) { + if (e.hasAllNullValues(!0)) + return Object.assign(new Ne(), e); + t("Set items must all have null values"); + } else + t("Expected a mapping for this tag"); + return e; + } +}; +function an(e, t) { + const n = e[0], s = n === "-" || n === "+" ? e.substring(1) : e, i = (o) => t ? BigInt(o) : Number(o), r = s.replace(/_/g, "").split(":").reduce((o, a) => o * i(60) + i(a), i(0)); + return n === "-" ? i(-1) * r : r; +} +function ws(e) { + let { value: t } = e, n = (o) => o; + if (typeof t == "bigint") + n = (o) => BigInt(o); + else if (isNaN(t) || !isFinite(t)) + return J(e); + let s = ""; + t < 0 && (s = "-", t *= n(-1)); + const i = n(60), r = [t % i]; + return t < 60 ? r.unshift(0) : (t = (t - r[0]) / i, r.unshift(t % i), t >= 60 && (t = (t - r[0]) / i, r.unshift(t))), s + r.map((o) => String(o).padStart(2, "0")).join(":").replace(/000000\d*$/, ""); +} +const ks = { + identify: (e) => typeof e == "bigint" || Number.isInteger(e), + default: !0, + tag: "tag:yaml.org,2002:int", + format: "TIME", + test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/, + resolve: (e, t, { intAsBigInt: n }) => an(e, n), + stringify: ws +}, Ss = { + identify: (e) => typeof e == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + format: "TIME", + test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/, + resolve: (e) => an(e, !1), + stringify: ws +}, St = { + identify: (e) => e instanceof Date, + default: !0, + tag: "tag:yaml.org,2002:timestamp", + // If the time zone is omitted, the timestamp is assumed to be specified in UTC. The time part + // may be omitted altogether, resulting in a date format. In such a case, the time part is + // assumed to be 00:00:00Z (start of day, UTC). + test: RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"), + resolve(e) { + const t = e.match(St.test); + if (!t) + throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd"); + const [, n, s, i, r, o, a] = t.map(Number), l = t[7] ? Number((t[7] + "00").substr(1, 3)) : 0; + let c = Date.UTC(n, s - 1, i, r || 0, o || 0, a || 0, l); + const f = t[8]; + if (f && f !== "Z") { + let u = an(f, !1); + Math.abs(u) < 30 && (u *= 60), c -= 6e4 * u; + } + return new Date(c); + }, + stringify: ({ value: e }) => e?.toISOString().replace(/(T00:00:00)?\.000Z$/, "") ?? "" +}, On = [ + Le, + Ie, + yt, + bt, + ys, + bs, + wi, + ki, + Si, + Oi, + mi, + yi, + bi, + nn, + z, + rn, + sn, + ln, + ks, + Ss, + St +], An = /* @__PURE__ */ new Map([ + ["core", hi], + ["failsafe", [Le, Ie, yt]], + ["json", gi], + ["yaml11", On], + ["yaml-1.1", On] +]), Nn = { + binary: nn, + bool: en, + float: cs, + floatExp: as, + floatNaN: ls, + floatTime: Ss, + int: hs, + intHex: ds, + intOct: us, + intTime: ks, + map: Le, + merge: z, + null: bt, + omap: rn, + pairs: sn, + seq: Ie, + set: ln, + timestamp: St +}, Ai = { + "tag:yaml.org,2002:binary": nn, + "tag:yaml.org,2002:merge": z, + "tag:yaml.org,2002:omap": rn, + "tag:yaml.org,2002:pairs": sn, + "tag:yaml.org,2002:set": ln, + "tag:yaml.org,2002:timestamp": St +}; +function $t(e, t, n) { + const s = An.get(t); + if (s && !e) + return n && !s.includes(z) ? s.concat(z) : s.slice(); + let i = s; + if (!i) + if (Array.isArray(e)) + i = []; + else { + const r = Array.from(An.keys()).filter((o) => o !== "yaml11").map((o) => JSON.stringify(o)).join(", "); + throw new Error(`Unknown schema "${t}"; use one of ${r} or define customTags array`); + } + if (Array.isArray(e)) + for (const r of e) + i = i.concat(r); + else typeof e == "function" && (i = e(i.slice())); + return n && (i = i.concat(z)), i.reduce((r, o) => { + const a = typeof o == "string" ? Nn[o] : o; + if (!a) { + const l = JSON.stringify(o), c = Object.keys(Nn).map((f) => JSON.stringify(f)).join(", "); + throw new Error(`Unknown custom tag ${l}; use one of ${c}`); + } + return r.includes(a) || r.push(a), r; + }, []); +} +const Ni = (e, t) => e.key < t.key ? -1 : e.key > t.key ? 1 : 0; +class Ye { + constructor({ compat: t, customTags: n, merge: s, resolveKnownTags: i, schema: r, sortMapEntries: o, toStringDefaults: a }) { + this.compat = Array.isArray(t) ? $t(t, "compat") : t ? $t(null, t) : null, this.name = typeof r == "string" && r || "core", this.knownTags = i ? Ai : {}, this.tags = $t(n, this.name, s), this.toStringOptions = a ?? null, Object.defineProperty(this, te, { value: Le }), Object.defineProperty(this, W, { value: yt }), Object.defineProperty(this, Ee, { value: Ie }), this.sortMapEntries = typeof o == "function" ? o : o === !0 ? Ni : null; + } + clone() { + const t = Object.create(Ye.prototype, Object.getOwnPropertyDescriptors(this)); + return t.tags = this.tags.slice(), t; + } +} +function vi(e, t) { + const n = []; + let s = t.directives === !0; + if (t.directives !== !1 && e.directives) { + const l = e.directives.toString(e); + l ? (n.push(l), s = !0) : e.directives.docStart && (s = !0); + } + s && n.push("---"); + const i = ns(e, t), { commentString: r } = i.options; + if (e.commentBefore) { + n.length !== 1 && n.unshift(""); + const l = r(e.commentBefore); + n.unshift(H(l, "")); + } + let o = !1, a = null; + if (e.contents) { + if (_(e.contents)) { + if (e.contents.spaceBefore && s && n.push(""), e.contents.commentBefore) { + const f = r(e.contents.commentBefore); + n.push(H(f, "")); + } + i.forceBlockIndent = !!e.comment, a = e.contents.comment; + } + const l = a ? void 0 : () => o = !0; + let c = ve(e.contents, i, () => a = null, l); + a && (c += oe(c, "", r(a))), (c[0] === "|" || c[0] === ">") && n[n.length - 1] === "---" ? n[n.length - 1] = `--- ${c}` : n.push(c); + } else + n.push(ve(e.contents, i)); + if (e.directives?.docEnd) + if (e.comment) { + const l = r(e.comment); + l.includes(` +`) ? (n.push("..."), n.push(H(l, ""))) : n.push(`... ${l}`); + } else + n.push("..."); + else { + let l = e.comment; + l && o && (l = l.replace(/^\n+/, "")), l && ((!o || a) && n[n.length - 1] !== "" && n.push(""), n.push(H(r(l), ""))); + } + return n.join(` +`) + ` +`; +} +class ue { + constructor(t, n, s) { + this.commentBefore = null, this.comment = null, this.errors = [], this.warnings = [], Object.defineProperty(this, U, { value: qt }); + let i = null; + typeof n == "function" || Array.isArray(n) ? i = n : s === void 0 && n && (s = n, n = void 0); + const r = Object.assign({ + intAsBigInt: !1, + keepSourceTokens: !1, + logLevel: "warn", + prettyErrors: !0, + strict: !0, + stringKeys: !1, + uniqueKeys: !0, + version: "1.2" + }, s); + this.options = r; + let { version: o } = r; + s?._directives ? (this.directives = s._directives.atDocument(), this.directives.yaml.explicit && (o = this.directives.yaml.version)) : this.directives = new M({ version: o }), this.setSchema(o, s), this.contents = t === void 0 ? null : this.createNode(t, i, s); + } + /** + * Create a deep copy of this Document and its contents. + * + * Custom Node values that inherit from `Object` still refer to their original instances. + */ + clone() { + const t = Object.create(ue.prototype, { + [U]: { value: qt } + }); + return t.commentBefore = this.commentBefore, t.comment = this.comment, t.errors = this.errors.slice(), t.warnings = this.warnings.slice(), t.options = Object.assign({}, this.options), this.directives && (t.directives = this.directives.clone()), t.schema = this.schema.clone(), t.contents = _(this.contents) ? this.contents.clone(t.schema) : this.contents, this.range && (t.range = this.range.slice()), t; + } + /** Adds a value to the document. */ + add(t) { + de(this.contents) && this.contents.add(t); + } + /** Adds a value to the document. */ + addIn(t, n) { + de(this.contents) && this.contents.addIn(t, n); + } + /** + * Create a new `Alias` node, ensuring that the target `node` has the required anchor. + * + * If `node` already has an anchor, `name` is ignored. + * Otherwise, the `node.anchor` value will be set to `name`, + * or if an anchor with that name is already present in the document, + * `name` will be used as a prefix for a new unique anchor. + * If `name` is undefined, the generated anchor will use 'a' as a prefix. + */ + createAlias(t, n) { + if (!t.anchor) { + const s = Zn(this); + t.anchor = // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing + !n || s.has(n) ? Cn(n || "a", s) : n; + } + return new Ue(t.anchor); + } + createNode(t, n, s) { + let i; + if (typeof n == "function") + t = n.call({ "": t }, "", t), i = n; + else if (Array.isArray(n)) { + const g = (A) => typeof A == "number" || A instanceof String || A instanceof Number, S = n.filter(g).map(String); + S.length > 0 && (n = n.concat(S)), i = n; + } else s === void 0 && n && (s = n, n = void 0); + const { aliasDuplicateObjects: r, anchorPrefix: o, flow: a, keepUndefined: l, onTagObj: c, tag: f } = s ?? {}, { onAnchor: u, setAnchors: h, sourceObjects: p } = xs( + this, + // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing + o || "a" + ), m = { + aliasDuplicateObjects: r ?? !0, + keepUndefined: l ?? !1, + onAnchor: u, + onTagObj: c, + replacer: i, + schema: this.schema, + sourceObjects: p + }, d = Me(t, f, m); + return a && I(d) && (d.flow = !0), h(), d; + } + /** + * Convert a key and a value into a `Pair` using the current schema, + * recursively wrapping all values as `Scalar` or `Collection` nodes. + */ + createPair(t, n, s = {}) { + const i = this.createNode(t, null, s), r = this.createNode(n, null, s); + return new B(i, r); + } + /** + * Removes a value from the document. + * @returns `true` if the item was found and removed. + */ + delete(t) { + return de(this.contents) ? this.contents.delete(t) : !1; + } + /** + * Removes a value from the document. + * @returns `true` if the item was found and removed. + */ + deleteIn(t) { + return Pe(t) ? this.contents == null ? !1 : (this.contents = null, !0) : de(this.contents) ? this.contents.deleteIn(t) : !1; + } + /** + * Returns item at `key`, or `undefined` if not found. By default unwraps + * scalar values from their surrounding node; to disable set `keepScalar` to + * `true` (collections are always returned intact). + */ + get(t, n) { + return I(this.contents) ? this.contents.get(t, n) : void 0; + } + /** + * Returns item at `path`, or `undefined` if not found. By default unwraps + * scalar values from their surrounding node; to disable set `keepScalar` to + * `true` (collections are always returned intact). + */ + getIn(t, n) { + return Pe(t) ? !n && E(this.contents) ? this.contents.value : this.contents : I(this.contents) ? this.contents.getIn(t, n) : void 0; + } + /** + * Checks if the document includes a value with the key `key`. + */ + has(t) { + return I(this.contents) ? this.contents.has(t) : !1; + } + /** + * Checks if the document includes a value at `path`. + */ + hasIn(t) { + return Pe(t) ? this.contents !== void 0 : I(this.contents) ? this.contents.hasIn(t) : !1; + } + /** + * Sets a value in this document. For `!!set`, `value` needs to be a + * boolean to add/remove the item from the set. + */ + set(t, n) { + this.contents == null ? this.contents = ct(this.schema, [t], n) : de(this.contents) && this.contents.set(t, n); + } + /** + * Sets a value in this document. For `!!set`, `value` needs to be a + * boolean to add/remove the item from the set. + */ + setIn(t, n) { + Pe(t) ? this.contents = n : this.contents == null ? this.contents = ct(this.schema, Array.from(t), n) : de(this.contents) && this.contents.setIn(t, n); + } + /** + * Change the YAML version and schema used by the document. + * A `null` version disables support for directives, explicit tags, anchors, and aliases. + * It also requires the `schema` option to be given as a `Schema` instance value. + * + * Overrides all previously set schema options. + */ + setSchema(t, n = {}) { + typeof t == "number" && (t = String(t)); + let s; + switch (t) { + case "1.1": + this.directives ? this.directives.yaml.version = "1.1" : this.directives = new M({ version: "1.1" }), s = { resolveKnownTags: !1, schema: "yaml-1.1" }; + break; + case "1.2": + case "next": + this.directives ? this.directives.yaml.version = t : this.directives = new M({ version: t }), s = { resolveKnownTags: !0, schema: "core" }; + break; + case null: + this.directives && delete this.directives, s = null; + break; + default: { + const i = JSON.stringify(t); + throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${i}`); + } + } + if (n.schema instanceof Object) + this.schema = n.schema; + else if (s) + this.schema = new Ye(Object.assign(s, n)); + else + throw new Error("With a null YAML version, the { schema: Schema } option is required"); + } + // json & jsonArg are only used from toJSON() + toJS({ json: t, jsonArg: n, mapAsMap: s, maxAliasCount: i, onAnchor: r, reviver: o } = {}) { + const a = { + anchors: /* @__PURE__ */ new Map(), + doc: this, + keep: !t, + mapAsMap: s === !0, + mapKeyWarned: !1, + maxAliasCount: typeof i == "number" ? i : 100 + }, l = F(this.contents, n ?? "", a); + if (typeof r == "function") + for (const { count: c, res: f } of a.anchors.values()) + r(f, c); + return typeof o == "function" ? Se(o, { "": l }, "", l) : l; + } + /** + * A JSON representation of the document `contents`. + * + * @param jsonArg Used by `JSON.stringify` to indicate the array index or + * property name. + */ + toJSON(t, n) { + return this.toJS({ json: !0, jsonArg: t, mapAsMap: !1, onAnchor: n }); + } + /** A YAML representation of the document. */ + toString(t = {}) { + if (this.errors.length > 0) + throw new Error("Document with errors cannot be stringified"); + if ("indent" in t && (!Number.isInteger(t.indent) || Number(t.indent) <= 0)) { + const n = JSON.stringify(t.indent); + throw new Error(`"indent" option must be a positive integer, not ${n}`); + } + return vi(this, t); + } +} +function de(e) { + if (I(e)) + return !0; + throw new Error("Expected a YAML collection as document contents"); +} +class Ot extends Error { + constructor(t, n, s, i) { + super(), this.name = t, this.code = s, this.message = i, this.pos = n; + } +} +class ee extends Ot { + constructor(t, n, s) { + super("YAMLParseError", t, n, s); + } +} +class cn extends Ot { + constructor(t, n, s) { + super("YAMLWarning", t, n, s); + } +} +const ut = (e, t) => (n) => { + if (n.pos[0] === -1) + return; + n.linePos = n.pos.map((a) => t.linePos(a)); + const { line: s, col: i } = n.linePos[0]; + n.message += ` at line ${s}, column ${i}`; + let r = i - 1, o = e.substring(t.lineStarts[s - 1], t.lineStarts[s]).replace(/[\n\r]+$/, ""); + if (r >= 60 && o.length > 80) { + const a = Math.min(r - 39, o.length - 79); + o = "…" + o.substring(a), r -= a - 1; + } + if (o.length > 80 && (o = o.substring(0, 79) + "…"), s > 1 && /^ *$/.test(o.substring(0, r))) { + let a = e.substring(t.lineStarts[s - 2], t.lineStarts[s - 1]); + a.length > 80 && (a = a.substring(0, 79) + `… +`), o = a + o; + } + if (/[^ ]/.test(o)) { + let a = 1; + const l = n.linePos[1]; + l && l.line === s && l.col > i && (a = Math.max(1, Math.min(l.col - i, 80 - r))); + const c = " ".repeat(r) + "^".repeat(a); + n.message += `: + +${o} +${c} +`; + } +}; +function Te(e, { flow: t, indicator: n, next: s, offset: i, onError: r, parentIndent: o, startOnNewline: a }) { + let l = !1, c = a, f = a, u = "", h = "", p = !1, m = !1, d = null, g = null, S = null, A = null, y = null, O = null, b = null; + for (const N of e) + switch (m && (N.type !== "space" && N.type !== "newline" && N.type !== "comma" && r(N.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), m = !1), d && (c && N.type !== "comment" && N.type !== "newline" && r(d, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), d = null), N.type) { + case "space": + !t && (n !== "doc-start" || s?.type !== "flow-collection") && N.source.includes(" ") && (d = N), f = !0; + break; + case "comment": { + f || r(N, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"); + const j = N.source.substring(1) || " "; + u ? u += h + j : u = j, h = "", c = !1; + break; + } + case "newline": + c ? u ? u += N.source : (!O || n !== "seq-item-ind") && (l = !0) : h += N.source, c = !0, p = !0, (g || S) && (A = N), f = !0; + break; + case "anchor": + g && r(N, "MULTIPLE_ANCHORS", "A node can have at most one anchor"), N.source.endsWith(":") && r(N.offset + N.source.length - 1, "BAD_ALIAS", "Anchor ending in : is ambiguous", !0), g = N, b ?? (b = N.offset), c = !1, f = !1, m = !0; + break; + case "tag": { + S && r(N, "MULTIPLE_TAGS", "A node can have at most one tag"), S = N, b ?? (b = N.offset), c = !1, f = !1, m = !0; + break; + } + case n: + (g || S) && r(N, "BAD_PROP_ORDER", `Anchors and tags must be after the ${N.source} indicator`), O && r(N, "UNEXPECTED_TOKEN", `Unexpected ${N.source} in ${t ?? "collection"}`), O = N, c = n === "seq-item-ind" || n === "explicit-key-ind", f = !1; + break; + case "comma": + if (t) { + y && r(N, "UNEXPECTED_TOKEN", `Unexpected , in ${t}`), y = N, c = !1, f = !1; + break; + } + // else fallthrough + default: + r(N, "UNEXPECTED_TOKEN", `Unexpected ${N.type} token`), c = !1, f = !1; + } + const w = e[e.length - 1], k = w ? w.offset + w.source.length : i; + return m && s && s.type !== "space" && s.type !== "newline" && s.type !== "comma" && (s.type !== "scalar" || s.source !== "") && r(s.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), d && (c && d.indent <= o || s?.type === "block-map" || s?.type === "block-seq") && r(d, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), { + comma: y, + found: O, + spaceBefore: l, + comment: u, + hasNewline: p, + anchor: g, + tag: S, + newlineAfterProp: A, + end: k, + start: b ?? k + }; +} +function Re(e) { + if (!e) + return null; + switch (e.type) { + case "alias": + case "scalar": + case "double-quoted-scalar": + case "single-quoted-scalar": + if (e.source.includes(` +`)) + return !0; + if (e.end) { + for (const t of e.end) + if (t.type === "newline") + return !0; + } + return !1; + case "flow-collection": + for (const t of e.items) { + for (const n of t.start) + if (n.type === "newline") + return !0; + if (t.sep) { + for (const n of t.sep) + if (n.type === "newline") + return !0; + } + if (Re(t.key) || Re(t.value)) + return !0; + } + return !1; + default: + return !0; + } +} +function Jt(e, t, n) { + if (t?.type === "flow-collection") { + const s = t.end[0]; + s.indent === e && (s.source === "]" || s.source === "}") && Re(t) && n(s, "BAD_INDENT", "Flow end indicator should be more indented than parent", !0); + } +} +function Os(e, t, n) { + const { uniqueKeys: s } = e.options; + if (s === !1) + return !1; + const i = typeof s == "function" ? s : (r, o) => r === o || E(r) && E(o) && r.value === o.value; + return t.some((r) => i(r.key, n)); +} +const vn = "All mapping items must start at the same column"; +function Ti({ composeNode: e, composeEmptyNode: t }, n, s, i, r) { + const o = r?.nodeClass ?? K, a = new o(n.schema); + n.atRoot && (n.atRoot = !1); + let l = s.offset, c = null; + for (const f of s.items) { + const { start: u, key: h, sep: p, value: m } = f, d = Te(u, { + indicator: "explicit-key-ind", + next: h ?? p?.[0], + offset: l, + onError: i, + parentIndent: s.indent, + startOnNewline: !0 + }), g = !d.found; + if (g) { + if (h && (h.type === "block-seq" ? i(l, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in h && h.indent !== s.indent && i(l, "BAD_INDENT", vn)), !d.anchor && !d.tag && !p) { + c = d.end, d.comment && (a.comment ? a.comment += ` +` + d.comment : a.comment = d.comment); + continue; + } + (d.newlineAfterProp || Re(h)) && i(h ?? u[u.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line"); + } else d.found?.indent !== s.indent && i(l, "BAD_INDENT", vn); + n.atKey = !0; + const S = d.end, A = h ? e(n, h, d, i) : t(n, S, u, null, d, i); + n.schema.compat && Jt(s.indent, h, i), n.atKey = !1, Os(n, a.items, A) && i(S, "DUPLICATE_KEY", "Map keys must be unique"); + const y = Te(p ?? [], { + indicator: "map-value-ind", + next: m, + offset: A.range[2], + onError: i, + parentIndent: s.indent, + startOnNewline: !h || h.type === "block-scalar" + }); + if (l = y.end, y.found) { + g && (m?.type === "block-map" && !y.hasNewline && i(l, "BLOCK_AS_IMPLICIT_KEY", "Nested mappings are not allowed in compact mappings"), n.options.strict && d.start < y.found.offset - 1024 && i(A.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key")); + const O = m ? e(n, m, y, i) : t(n, l, p, null, y, i); + n.schema.compat && Jt(s.indent, m, i), l = O.range[2]; + const b = new B(A, O); + n.options.keepSourceTokens && (b.srcToken = f), a.items.push(b); + } else { + g && i(A.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values"), y.comment && (A.comment ? A.comment += ` +` + y.comment : A.comment = y.comment); + const O = new B(A); + n.options.keepSourceTokens && (O.srcToken = f), a.items.push(O); + } + } + return c && c < l && i(c, "IMPOSSIBLE", "Map comment with trailing content"), a.range = [s.offset, l, c ?? l], a; +} +function Ei({ composeNode: e, composeEmptyNode: t }, n, s, i, r) { + const o = r?.nodeClass ?? X, a = new o(n.schema); + n.atRoot && (n.atRoot = !1), n.atKey && (n.atKey = !1); + let l = s.offset, c = null; + for (const { start: f, value: u } of s.items) { + const h = Te(f, { + indicator: "seq-item-ind", + next: u, + offset: l, + onError: i, + parentIndent: s.indent, + startOnNewline: !0 + }); + if (!h.found) + if (h.anchor || h.tag || u) + u && u.type === "block-seq" ? i(h.end, "BAD_INDENT", "All sequence items must start at the same column") : i(l, "MISSING_CHAR", "Sequence item without - indicator"); + else { + c = h.end, h.comment && (a.comment = h.comment); + continue; + } + const p = u ? e(n, u, h, i) : t(n, h.end, f, null, h, i); + n.schema.compat && Jt(s.indent, u, i), l = p.range[2], a.items.push(p); + } + return a.range = [s.offset, l, c ?? l], a; +} +function Ge(e, t, n, s) { + let i = ""; + if (e) { + let r = !1, o = ""; + for (const a of e) { + const { source: l, type: c } = a; + switch (c) { + case "space": + r = !0; + break; + case "comment": { + n && !r && s(a, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"); + const f = l.substring(1) || " "; + i ? i += o + f : i = f, o = ""; + break; + } + case "newline": + i && (o += l), r = !0; + break; + default: + s(a, "UNEXPECTED_TOKEN", `Unexpected ${c} at node end`); + } + t += l.length; + } + } + return { comment: i, offset: t }; +} +const Pt = "Block collections are not allowed within flow collections", Bt = (e) => e && (e.type === "block-map" || e.type === "block-seq"); +function Li({ composeNode: e, composeEmptyNode: t }, n, s, i, r) { + const o = s.start.source === "{", a = o ? "flow map" : "flow sequence", l = r?.nodeClass ?? (o ? K : X), c = new l(n.schema); + c.flow = !0; + const f = n.atRoot; + f && (n.atRoot = !1), n.atKey && (n.atKey = !1); + let u = s.offset + s.start.source.length; + for (let g = 0; g < s.items.length; ++g) { + const S = s.items[g], { start: A, key: y, sep: O, value: b } = S, w = Te(A, { + flow: a, + indicator: "explicit-key-ind", + next: y ?? O?.[0], + offset: u, + onError: i, + parentIndent: s.indent, + startOnNewline: !1 + }); + if (!w.found) { + if (!w.anchor && !w.tag && !O && !b) { + g === 0 && w.comma ? i(w.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${a}`) : g < s.items.length - 1 && i(w.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${a}`), w.comment && (c.comment ? c.comment += ` +` + w.comment : c.comment = w.comment), u = w.end; + continue; + } + !o && n.options.strict && Re(y) && i( + y, + // checked by containsNewline() + "MULTILINE_IMPLICIT_KEY", + "Implicit keys of flow sequence pairs need to be on a single line" + ); + } + if (g === 0) + w.comma && i(w.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${a}`); + else if (w.comma || i(w.start, "MISSING_CHAR", `Missing , between ${a} items`), w.comment) { + let k = ""; + e: for (const N of A) + switch (N.type) { + case "comma": + case "space": + break; + case "comment": + k = N.source.substring(1); + break e; + default: + break e; + } + if (k) { + let N = c.items[c.items.length - 1]; + L(N) && (N = N.value ?? N.key), N.comment ? N.comment += ` +` + k : N.comment = k, w.comment = w.comment.substring(k.length + 1); + } + } + if (!o && !O && !w.found) { + const k = b ? e(n, b, w, i) : t(n, w.end, O, null, w, i); + c.items.push(k), u = k.range[2], Bt(b) && i(k.range, "BLOCK_IN_FLOW", Pt); + } else { + n.atKey = !0; + const k = w.end, N = y ? e(n, y, w, i) : t(n, k, A, null, w, i); + Bt(y) && i(N.range, "BLOCK_IN_FLOW", Pt), n.atKey = !1; + const j = Te(O ?? [], { + flow: a, + indicator: "map-value-ind", + next: b, + offset: N.range[2], + onError: i, + parentIndent: s.indent, + startOnNewline: !1 + }); + if (j.found) { + if (!o && !w.found && n.options.strict) { + if (O) + for (const $ of O) { + if ($ === j.found) + break; + if ($.type === "newline") { + i($, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line"); + break; + } + } + w.start < j.found.offset - 1024 && i(j.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key"); + } + } else b && ("source" in b && b.source && b.source[0] === ":" ? i(b, "MISSING_CHAR", `Missing space after : in ${a}`) : i(j.start, "MISSING_CHAR", `Missing , or : between ${a} items`)); + const D = b ? e(n, b, j, i) : j.found ? t(n, j.end, O, null, j, i) : null; + D ? Bt(b) && i(D.range, "BLOCK_IN_FLOW", Pt) : j.comment && (N.comment ? N.comment += ` +` + j.comment : N.comment = j.comment); + const C = new B(N, D); + if (n.options.keepSourceTokens && (C.srcToken = S), o) { + const $ = c; + Os(n, $.items, N) && i(k, "DUPLICATE_KEY", "Map keys must be unique"), $.items.push(C); + } else { + const $ = new K(n.schema); + $.flow = !0, $.items.push(C); + const he = (D ?? N).range; + $.range = [N.range[0], he[1], he[2]], c.items.push($); + } + u = D ? D.range[2] : j.end; + } + } + const h = o ? "}" : "]", [p, ...m] = s.end; + let d = u; + if (p && p.source === h) + d = p.offset + p.source.length; + else { + const g = a[0].toUpperCase() + a.substring(1), S = f ? `${g} must end with a ${h}` : `${g} in block collection must be sufficiently indented and end with a ${h}`; + i(u, f ? "MISSING_CHAR" : "BAD_INDENT", S), p && p.source.length !== 1 && m.unshift(p); + } + if (m.length > 0) { + const g = Ge(m, d, n.options.strict, i); + g.comment && (c.comment ? c.comment += ` +` + g.comment : c.comment = g.comment), c.range = [s.offset, d, g.offset]; + } else + c.range = [s.offset, d, d]; + return c; +} +function Mt(e, t, n, s, i, r) { + const o = n.type === "block-map" ? Ti(e, t, n, s, r) : n.type === "block-seq" ? Ei(e, t, n, s, r) : Li(e, t, n, s, r), a = o.constructor; + return i === "!" || i === a.tagName ? (o.tag = a.tagName, o) : (i && (o.tag = i), o); +} +function Ii(e, t, n, s, i) { + const r = s.tag, o = r ? t.directives.tagName(r.source, (h) => i(r, "TAG_RESOLVE_FAILED", h)) : null; + if (n.type === "block-seq") { + const { anchor: h, newlineAfterProp: p } = s, m = h && r ? h.offset > r.offset ? h : r : h ?? r; + m && (!p || p.offset < m.offset) && i(m, "MISSING_CHAR", "Missing newline after block sequence props"); + } + const a = n.type === "block-map" ? "map" : n.type === "block-seq" ? "seq" : n.start.source === "{" ? "map" : "seq"; + if (!r || !o || o === "!" || o === K.tagName && a === "map" || o === X.tagName && a === "seq") + return Mt(e, t, n, i, o); + let l = t.schema.tags.find((h) => h.tag === o && h.collection === a); + if (!l) { + const h = t.schema.knownTags[o]; + if (h && h.collection === a) + t.schema.tags.push(Object.assign({}, h, { default: !1 })), l = h; + else + return h ? i(r, "BAD_COLLECTION_TYPE", `${h.tag} used for ${a} collection, but expects ${h.collection ?? "scalar"}`, !0) : i(r, "TAG_RESOLVE_FAILED", `Unresolved tag: ${o}`, !0), Mt(e, t, n, i, o); + } + const c = Mt(e, t, n, i, o, l), f = l.resolve?.(c, (h) => i(r, "TAG_RESOLVE_FAILED", h), t.options) ?? c, u = _(f) ? f : new v(f); + return u.range = c.range, u.tag = o, l?.format && (u.format = l.format), u; +} +function As(e, t, n) { + const s = t.offset, i = _i(t, e.options.strict, n); + if (!i) + return { value: "", type: null, comment: "", range: [s, s, s] }; + const r = i.mode === ">" ? v.BLOCK_FOLDED : v.BLOCK_LITERAL, o = t.source ? ji(t.source) : []; + let a = o.length; + for (let d = o.length - 1; d >= 0; --d) { + const g = o[d][1]; + if (g === "" || g === "\r") + a = d; + else + break; + } + if (a === 0) { + const d = i.chomp === "+" && o.length > 0 ? ` +`.repeat(Math.max(1, o.length - 1)) : ""; + let g = s + i.length; + return t.source && (g += t.source.length), { value: d, type: r, comment: i.comment, range: [s, g, g] }; + } + let l = t.indent + i.indent, c = t.offset + i.length, f = 0; + for (let d = 0; d < a; ++d) { + const [g, S] = o[d]; + if (S === "" || S === "\r") + i.indent === 0 && g.length > l && (l = g.length); + else { + g.length < l && n(c + g.length, "MISSING_CHAR", "Block scalars with more-indented leading empty lines must use an explicit indentation indicator"), i.indent === 0 && (l = g.length), f = d, l === 0 && !e.atRoot && n(c, "BAD_INDENT", "Block scalar values in collections must be indented"); + break; + } + c += g.length + S.length + 1; + } + for (let d = o.length - 1; d >= a; --d) + o[d][0].length > l && (a = d + 1); + let u = "", h = "", p = !1; + for (let d = 0; d < f; ++d) + u += o[d][0].slice(l) + ` +`; + for (let d = f; d < a; ++d) { + let [g, S] = o[d]; + c += g.length + S.length + 1; + const A = S[S.length - 1] === "\r"; + if (A && (S = S.slice(0, -1)), S && g.length < l) { + const O = `Block scalar lines must not be less indented than their ${i.indent ? "explicit indentation indicator" : "first line"}`; + n(c - S.length - (A ? 2 : 1), "BAD_INDENT", O), g = ""; + } + r === v.BLOCK_LITERAL ? (u += h + g.slice(l) + S, h = ` +`) : g.length > l || S[0] === " " ? (h === " " ? h = ` +` : !p && h === ` +` && (h = ` + +`), u += h + g.slice(l) + S, h = ` +`, p = !0) : S === "" ? h === ` +` ? u += ` +` : h = ` +` : (u += h + S, h = " ", p = !1); + } + switch (i.chomp) { + case "-": + break; + case "+": + for (let d = a; d < o.length; ++d) + u += ` +` + o[d][0].slice(l); + u[u.length - 1] !== ` +` && (u += ` +`); + break; + default: + u += ` +`; + } + const m = s + i.length + t.source.length; + return { value: u, type: r, comment: i.comment, range: [s, m, m] }; +} +function _i({ offset: e, props: t }, n, s) { + if (t[0].type !== "block-scalar-header") + return s(t[0], "IMPOSSIBLE", "Block scalar header not found"), null; + const { source: i } = t[0], r = i[0]; + let o = 0, a = "", l = -1; + for (let h = 1; h < i.length; ++h) { + const p = i[h]; + if (!a && (p === "-" || p === "+")) + a = p; + else { + const m = Number(p); + !o && m ? o = m : l === -1 && (l = e + h); + } + } + l !== -1 && s(l, "UNEXPECTED_TOKEN", `Block scalar header includes extra characters: ${i}`); + let c = !1, f = "", u = i.length; + for (let h = 1; h < t.length; ++h) { + const p = t[h]; + switch (p.type) { + case "space": + c = !0; + // fallthrough + case "newline": + u += p.source.length; + break; + case "comment": + n && !c && s(p, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"), u += p.source.length, f = p.source.substring(1); + break; + case "error": + s(p, "UNEXPECTED_TOKEN", p.message), u += p.source.length; + break; + /* istanbul ignore next should not happen */ + default: { + const m = `Unexpected token in block scalar header: ${p.type}`; + s(p, "UNEXPECTED_TOKEN", m); + const d = p.source; + d && typeof d == "string" && (u += d.length); + } + } + } + return { mode: r, indent: o, chomp: a, comment: f, length: u }; +} +function ji(e) { + const t = e.split(/\n( *)/), n = t[0], s = n.match(/^( *)/), r = [s?.[1] ? [s[1], n.slice(s[1].length)] : ["", n]]; + for (let o = 1; o < t.length; o += 2) + r.push([t[o], t[o + 1]]); + return r; +} +function Ns(e, t, n) { + const { offset: s, type: i, source: r, end: o } = e; + let a, l; + const c = (h, p, m) => n(s + h, p, m); + switch (i) { + case "scalar": + a = v.PLAIN, l = $i(r, c); + break; + case "single-quoted-scalar": + a = v.QUOTE_SINGLE, l = Pi(r, c); + break; + case "double-quoted-scalar": + a = v.QUOTE_DOUBLE, l = Bi(r, c); + break; + /* istanbul ignore next should not happen */ + default: + return n(e, "UNEXPECTED_TOKEN", `Expected a flow scalar value, but found: ${i}`), { + value: "", + type: null, + comment: "", + range: [s, s + r.length, s + r.length] + }; + } + const f = s + r.length, u = Ge(o, f, t, n); + return { + value: l, + type: a, + comment: u.comment, + range: [s, f, u.offset] + }; +} +function $i(e, t) { + let n = ""; + switch (e[0]) { + /* istanbul ignore next should not happen */ + case " ": + n = "a tab character"; + break; + case ",": + n = "flow indicator character ,"; + break; + case "%": + n = "directive indicator character %"; + break; + case "|": + case ">": { + n = `block scalar indicator ${e[0]}`; + break; + } + case "@": + case "`": { + n = `reserved character ${e[0]}`; + break; + } + } + return n && t(0, "BAD_SCALAR_START", `Plain value cannot start with ${n}`), vs(e); +} +function Pi(e, t) { + return (e[e.length - 1] !== "'" || e.length === 1) && t(e.length, "MISSING_CHAR", "Missing closing 'quote"), vs(e.slice(1, -1)).replace(/''/g, "'"); +} +function vs(e) { + let t, n; + try { + t = new RegExp(`(.*?)(? r ? e.slice(r, s + 1) : i); + } else + n += i; + } + return (e[e.length - 1] !== '"' || e.length === 1) && t(e.length, "MISSING_CHAR", 'Missing closing "quote'), n; +} +function Mi(e, t) { + let n = "", s = e[t + 1]; + for (; (s === " " || s === " " || s === ` +` || s === "\r") && !(s === "\r" && e[t + 2] !== ` +`); ) + s === ` +` && (n += ` +`), t += 1, s = e[t + 1]; + return n || (n = " "), { fold: n, offset: t }; +} +const Ri = { + 0: "\0", + // null character + a: "\x07", + // bell character + b: "\b", + // backspace + e: "\x1B", + // escape character + f: "\f", + // form feed + n: ` +`, + // line feed + r: "\r", + // carriage return + t: " ", + // horizontal tab + v: "\v", + // vertical tab + N: "…", + // Unicode next line + _: " ", + // Unicode non-breaking space + L: "\u2028", + // Unicode line separator + P: "\u2029", + // Unicode paragraph separator + " ": " ", + '"': '"', + "/": "/", + "\\": "\\", + " ": " " +}; +function Ki(e, t, n, s) { + const i = e.substr(t, n), o = i.length === n && /^[0-9a-fA-F]+$/.test(i) ? parseInt(i, 16) : NaN; + if (isNaN(o)) { + const a = e.substr(t - 2, n + 2); + return s(t - 2, "BAD_DQ_ESCAPE", `Invalid escape sequence ${a}`), a; + } + return String.fromCodePoint(o); +} +function Ts(e, t, n, s) { + const { value: i, type: r, comment: o, range: a } = t.type === "block-scalar" ? As(e, t, s) : Ns(t, e.options.strict, s), l = n ? e.directives.tagName(n.source, (u) => s(n, "TAG_RESOLVE_FAILED", u)) : null; + let c; + e.options.stringKeys && e.atKey ? c = e.schema[W] : l ? c = Di(e.schema, i, l, n, s) : t.type === "scalar" ? c = qi(e, i, t, s) : c = e.schema[W]; + let f; + try { + const u = c.resolve(i, (h) => s(n ?? t, "TAG_RESOLVE_FAILED", h), e.options); + f = E(u) ? u : new v(u); + } catch (u) { + const h = u instanceof Error ? u.message : String(u); + s(n ?? t, "TAG_RESOLVE_FAILED", h), f = new v(i); + } + return f.range = a, f.source = i, r && (f.type = r), l && (f.tag = l), c.format && (f.format = c.format), o && (f.comment = o), f; +} +function Di(e, t, n, s, i) { + if (n === "!") + return e[W]; + const r = []; + for (const a of e.tags) + if (!a.collection && a.tag === n) + if (a.default && a.test) + r.push(a); + else + return a; + for (const a of r) + if (a.test?.test(t)) + return a; + const o = e.knownTags[n]; + return o && !o.collection ? (e.tags.push(Object.assign({}, o, { default: !1, test: void 0 })), o) : (i(s, "TAG_RESOLVE_FAILED", `Unresolved tag: ${n}`, n !== "tag:yaml.org,2002:str"), e[W]); +} +function qi({ atKey: e, directives: t, schema: n }, s, i, r) { + const o = n.tags.find((a) => (a.default === !0 || e && a.default === "key") && a.test?.test(s)) || n[W]; + if (n.compat) { + const a = n.compat.find((l) => l.default && l.test?.test(s)) ?? n[W]; + if (o.tag !== a.tag) { + const l = t.tagString(o.tag), c = t.tagString(a.tag), f = `Value may be parsed as either ${l} or ${c}`; + r(i, "TAG_RESOLVE_FAILED", f, !0); + } + } + return o; +} +function Fi(e, t, n) { + if (t) { + n ?? (n = t.length); + for (let s = n - 1; s >= 0; --s) { + let i = t[s]; + switch (i.type) { + case "space": + case "comment": + case "newline": + e -= i.source.length; + continue; + } + for (i = t[++s]; i?.type === "space"; ) + e += i.source.length, i = t[++s]; + break; + } + } + return e; +} +const Ui = { composeNode: Es, composeEmptyNode: fn }; +function Es(e, t, n, s) { + const i = e.atKey, { spaceBefore: r, comment: o, anchor: a, tag: l } = n; + let c, f = !0; + switch (t.type) { + case "alias": + c = Vi(e, t, s), (a || l) && s(t, "ALIAS_PROPS", "An alias node must not specify any properties"); + break; + case "scalar": + case "single-quoted-scalar": + case "double-quoted-scalar": + case "block-scalar": + c = Ts(e, t, l, s), a && (c.anchor = a.source.substring(1)); + break; + case "block-map": + case "block-seq": + case "flow-collection": + c = Ii(Ui, e, t, n, s), a && (c.anchor = a.source.substring(1)); + break; + default: { + const u = t.type === "error" ? t.message : `Unsupported token (type: ${t.type})`; + s(t, "UNEXPECTED_TOKEN", u), c = fn(e, t.offset, void 0, null, n, s), f = !1; + } + } + return a && c.anchor === "" && s(a, "BAD_ALIAS", "Anchor cannot be an empty string"), i && e.options.stringKeys && (!E(c) || typeof c.value != "string" || c.tag && c.tag !== "tag:yaml.org,2002:str") && s(l ?? t, "NON_STRING_KEY", "With stringKeys, all keys must be strings"), r && (c.spaceBefore = !0), o && (t.type === "scalar" && t.source === "" ? c.comment = o : c.commentBefore = o), e.options.keepSourceTokens && f && (c.srcToken = t), c; +} +function fn(e, t, n, s, { spaceBefore: i, comment: r, anchor: o, tag: a, end: l }, c) { + const f = { + type: "scalar", + offset: Fi(t, n, s), + indent: -1, + source: "" + }, u = Ts(e, f, a, c); + return o && (u.anchor = o.source.substring(1), u.anchor === "" && c(o, "BAD_ALIAS", "Anchor cannot be an empty string")), i && (u.spaceBefore = !0), r && (u.comment = r, u.range[2] = l), u; +} +function Vi({ options: e }, { offset: t, source: n, end: s }, i) { + const r = new Ue(n.substring(1)); + r.source === "" && i(t, "BAD_ALIAS", "Alias cannot be an empty string"), r.source.endsWith(":") && i(t + n.length - 1, "BAD_ALIAS", "Alias ending in : is ambiguous", !0); + const o = t + n.length, a = Ge(s, o, e.strict, i); + return r.range = [t, o, a.offset], a.comment && (r.comment = a.comment), r; +} +function Ji(e, t, { offset: n, start: s, value: i, end: r }, o) { + const a = Object.assign({ _directives: t }, e), l = new ue(void 0, a), c = { + atKey: !1, + atRoot: !0, + directives: l.directives, + options: l.options, + schema: l.schema + }, f = Te(s, { + indicator: "doc-start", + next: i ?? r?.[0], + offset: n, + onError: o, + parentIndent: 0, + startOnNewline: !0 + }); + f.found && (l.directives.docStart = !0, i && (i.type === "block-map" || i.type === "block-seq") && !f.hasNewline && o(f.end, "MISSING_CHAR", "Block collection cannot start on same line with directives-end marker")), l.contents = i ? Es(c, i, f, o) : fn(c, f.end, s, null, f, o); + const u = l.contents.range[2], h = Ge(r, u, !1, o); + return h.comment && (l.comment = h.comment), l.range = [n, u, h.offset], l; +} +function je(e) { + if (typeof e == "number") + return [e, e + 1]; + if (Array.isArray(e)) + return e.length === 2 ? e : [e[0], e[1]]; + const { offset: t, source: n } = e; + return [t, t + (typeof n == "string" ? n.length : 1)]; +} +function Tn(e) { + let t = "", n = !1, s = !1; + for (let i = 0; i < e.length; ++i) { + const r = e[i]; + switch (r[0]) { + case "#": + t += (t === "" ? "" : s ? ` + +` : ` +`) + (r.substring(1) || " "), n = !0, s = !1; + break; + case "%": + e[i + 1]?.[0] !== "#" && (i += 1), n = !1; + break; + default: + n || (s = !0), n = !1; + } + } + return { comment: t, afterEmptyLine: s }; +} +class At { + constructor(t = {}) { + this.doc = null, this.atDirectives = !1, this.prelude = [], this.errors = [], this.warnings = [], this.onError = (n, s, i, r) => { + const o = je(n); + r ? this.warnings.push(new cn(o, s, i)) : this.errors.push(new ee(o, s, i)); + }, this.directives = new M({ version: t.version || "1.2" }), this.options = t; + } + decorate(t, n) { + const { comment: s, afterEmptyLine: i } = Tn(this.prelude); + if (s) { + const r = t.contents; + if (n) + t.comment = t.comment ? `${t.comment} +${s}` : s; + else if (i || t.directives.docStart || !r) + t.commentBefore = s; + else if (I(r) && !r.flow && r.items.length > 0) { + let o = r.items[0]; + L(o) && (o = o.key); + const a = o.commentBefore; + o.commentBefore = a ? `${s} +${a}` : s; + } else { + const o = r.commentBefore; + r.commentBefore = o ? `${s} +${o}` : s; + } + } + n ? (Array.prototype.push.apply(t.errors, this.errors), Array.prototype.push.apply(t.warnings, this.warnings)) : (t.errors = this.errors, t.warnings = this.warnings), this.prelude = [], this.errors = [], this.warnings = []; + } + /** + * Current stream status information. + * + * Mostly useful at the end of input for an empty stream. + */ + streamInfo() { + return { + comment: Tn(this.prelude).comment, + directives: this.directives, + errors: this.errors, + warnings: this.warnings + }; + } + /** + * Compose tokens into documents. + * + * @param forceDoc - If the stream contains no document, still emit a final document including any comments and directives that would be applied to a subsequent document. + * @param endOffset - Should be set if `forceDoc` is also set, to set the document range end and to indicate errors correctly. + */ + *compose(t, n = !1, s = -1) { + for (const i of t) + yield* this.next(i); + yield* this.end(n, s); + } + /** Advance the composer by one CST token. */ + *next(t) { + switch (t.type) { + case "directive": + this.directives.add(t.source, (n, s, i) => { + const r = je(t); + r[0] += n, this.onError(r, "BAD_DIRECTIVE", s, i); + }), this.prelude.push(t.source), this.atDirectives = !0; + break; + case "document": { + const n = Ji(this.options, this.directives, t, this.onError); + this.atDirectives && !n.directives.docStart && this.onError(t, "MISSING_CHAR", "Missing directives-end/doc-start indicator line"), this.decorate(n, !1), this.doc && (yield this.doc), this.doc = n, this.atDirectives = !1; + break; + } + case "byte-order-mark": + case "space": + break; + case "comment": + case "newline": + this.prelude.push(t.source); + break; + case "error": { + const n = t.source ? `${t.message}: ${JSON.stringify(t.source)}` : t.message, s = new ee(je(t), "UNEXPECTED_TOKEN", n); + this.atDirectives || !this.doc ? this.errors.push(s) : this.doc.errors.push(s); + break; + } + case "doc-end": { + if (!this.doc) { + const s = "Unexpected doc-end without preceding document"; + this.errors.push(new ee(je(t), "UNEXPECTED_TOKEN", s)); + break; + } + this.doc.directives.docEnd = !0; + const n = Ge(t.end, t.offset + t.source.length, this.doc.options.strict, this.onError); + if (this.decorate(this.doc, !0), n.comment) { + const s = this.doc.comment; + this.doc.comment = s ? `${s} +${n.comment}` : n.comment; + } + this.doc.range[2] = n.offset; + break; + } + default: + this.errors.push(new ee(je(t), "UNEXPECTED_TOKEN", `Unsupported token ${t.type}`)); + } + } + /** + * Call at end of input to yield any remaining document. + * + * @param forceDoc - If the stream contains no document, still emit a final document including any comments and directives that would be applied to a subsequent document. + * @param endOffset - Should be set if `forceDoc` is also set, to set the document range end and to indicate errors correctly. + */ + *end(t = !1, n = -1) { + if (this.doc) + this.decorate(this.doc, !0), yield this.doc, this.doc = null; + else if (t) { + const s = Object.assign({ _directives: this.directives }, this.options), i = new ue(void 0, s); + this.atDirectives && this.onError(n, "MISSING_CHAR", "Missing directives-end indicator line"), i.range = [0, n, n], this.decorate(i, !1), yield i; + } + } +} +function Yi(e, t = !0, n) { + if (e) { + const s = (i, r, o) => { + const a = typeof i == "number" ? i : Array.isArray(i) ? i[0] : i.offset; + if (n) + n(a, r, o); + else + throw new ee([a, a + 1], r, o); + }; + switch (e.type) { + case "scalar": + case "single-quoted-scalar": + case "double-quoted-scalar": + return Ns(e, t, s); + case "block-scalar": + return As({ options: { strict: t } }, e, s); + } + } + return null; +} +function Gi(e, t) { + const { implicitKey: n = !1, indent: s, inFlow: i = !1, offset: r = -1, type: o = "PLAIN" } = t, a = Ve({ type: o, value: e }, { + implicitKey: n, + indent: s > 0 ? " ".repeat(s) : "", + inFlow: i, + options: { blockQuote: !0, lineWidth: -1 } + }), l = t.end ?? [ + { type: "newline", offset: -1, indent: s, source: ` +` } + ]; + switch (a[0]) { + case "|": + case ">": { + const c = a.indexOf(` +`), f = a.substring(0, c), u = a.substring(c + 1) + ` +`, h = [ + { type: "block-scalar-header", offset: r, indent: s, source: f } + ]; + return Ls(h, l) || h.push({ type: "newline", offset: -1, indent: s, source: ` +` }), { type: "block-scalar", offset: r, indent: s, props: h, source: u }; + } + case '"': + return { type: "double-quoted-scalar", offset: r, indent: s, source: a, end: l }; + case "'": + return { type: "single-quoted-scalar", offset: r, indent: s, source: a, end: l }; + default: + return { type: "scalar", offset: r, indent: s, source: a, end: l }; + } +} +function Wi(e, t, n = {}) { + let { afterKey: s = !1, implicitKey: i = !1, inFlow: r = !1, type: o } = n, a = "indent" in e ? e.indent : null; + if (s && typeof a == "number" && (a += 2), !o) + switch (e.type) { + case "single-quoted-scalar": + o = "QUOTE_SINGLE"; + break; + case "double-quoted-scalar": + o = "QUOTE_DOUBLE"; + break; + case "block-scalar": { + const c = e.props[0]; + if (c.type !== "block-scalar-header") + throw new Error("Invalid block scalar header"); + o = c.source[0] === ">" ? "BLOCK_FOLDED" : "BLOCK_LITERAL"; + break; + } + default: + o = "PLAIN"; + } + const l = Ve({ type: o, value: t }, { + implicitKey: i || a === null, + indent: a !== null && a > 0 ? " ".repeat(a) : "", + inFlow: r, + options: { blockQuote: !0, lineWidth: -1 } + }); + switch (l[0]) { + case "|": + case ">": + Qi(e, l); + break; + case '"': + Rt(e, l, "double-quoted-scalar"); + break; + case "'": + Rt(e, l, "single-quoted-scalar"); + break; + default: + Rt(e, l, "scalar"); + } +} +function Qi(e, t) { + const n = t.indexOf(` +`), s = t.substring(0, n), i = t.substring(n + 1) + ` +`; + if (e.type === "block-scalar") { + const r = e.props[0]; + if (r.type !== "block-scalar-header") + throw new Error("Invalid block scalar header"); + r.source = s, e.source = i; + } else { + const { offset: r } = e, o = "indent" in e ? e.indent : -1, a = [ + { type: "block-scalar-header", offset: r, indent: o, source: s } + ]; + Ls(a, "end" in e ? e.end : void 0) || a.push({ type: "newline", offset: -1, indent: o, source: ` +` }); + for (const l of Object.keys(e)) + l !== "type" && l !== "offset" && delete e[l]; + Object.assign(e, { type: "block-scalar", indent: o, props: a, source: i }); + } +} +function Ls(e, t) { + if (t) + for (const n of t) + switch (n.type) { + case "space": + case "comment": + e.push(n); + break; + case "newline": + return e.push(n), !0; + } + return !1; +} +function Rt(e, t, n) { + switch (e.type) { + case "scalar": + case "double-quoted-scalar": + case "single-quoted-scalar": + e.type = n, e.source = t; + break; + case "block-scalar": { + const s = e.props.slice(1); + let i = t.length; + e.props[0].type === "block-scalar-header" && (i -= e.props[0].source.length); + for (const r of s) + r.offset += i; + delete e.props, Object.assign(e, { type: n, source: t, end: s }); + break; + } + case "block-map": + case "block-seq": { + const i = { type: "newline", offset: e.offset + t.length, indent: e.indent, source: ` +` }; + delete e.items, Object.assign(e, { type: n, source: t, end: [i] }); + break; + } + default: { + const s = "indent" in e ? e.indent : -1, i = "end" in e && Array.isArray(e.end) ? e.end.filter((r) => r.type === "space" || r.type === "comment" || r.type === "newline") : []; + for (const r of Object.keys(e)) + r !== "type" && r !== "offset" && delete e[r]; + Object.assign(e, { type: n, indent: s, source: t, end: i }); + } + } +} +const Hi = (e) => "type" in e ? ht(e) : at(e); +function ht(e) { + switch (e.type) { + case "block-scalar": { + let t = ""; + for (const n of e.props) + t += ht(n); + return t + e.source; + } + case "block-map": + case "block-seq": { + let t = ""; + for (const n of e.items) + t += at(n); + return t; + } + case "flow-collection": { + let t = e.start.source; + for (const n of e.items) + t += at(n); + for (const n of e.end) + t += n.source; + return t; + } + case "document": { + let t = at(e); + if (e.end) + for (const n of e.end) + t += n.source; + return t; + } + default: { + let t = e.source; + if ("end" in e && e.end) + for (const n of e.end) + t += n.source; + return t; + } + } +} +function at({ start: e, key: t, sep: n, value: s }) { + let i = ""; + for (const r of e) + i += r.source; + if (t && (i += ht(t)), n) + for (const r of n) + i += r.source; + return s && (i += ht(s)), i; +} +const Yt = /* @__PURE__ */ Symbol("break visit"), zi = /* @__PURE__ */ Symbol("skip children"), Is = /* @__PURE__ */ Symbol("remove item"); +function ae(e, t) { + "type" in e && e.type === "document" && (e = { start: e.start, value: e.value }), _s(Object.freeze([]), e, t); +} +ae.BREAK = Yt; +ae.SKIP = zi; +ae.REMOVE = Is; +ae.itemAtPath = (e, t) => { + let n = e; + for (const [s, i] of t) { + const r = n?.[s]; + if (r && "items" in r) + n = r.items[i]; + else + return; + } + return n; +}; +ae.parentCollection = (e, t) => { + const n = ae.itemAtPath(e, t.slice(0, -1)), s = t[t.length - 1][0], i = n?.[s]; + if (i && "items" in i) + return i; + throw new Error("Parent collection not found"); +}; +function _s(e, t, n) { + let s = n(t, e); + if (typeof s == "symbol") + return s; + for (const i of ["key", "value"]) { + const r = t[i]; + if (r && "items" in r) { + for (let o = 0; o < r.items.length; ++o) { + const a = _s(Object.freeze(e.concat([[i, o]])), r.items[o], n); + if (typeof a == "number") + o = a - 1; + else { + if (a === Yt) + return Yt; + a === Is && (r.items.splice(o, 1), o -= 1); + } + } + typeof s == "function" && i === "key" && (s = s(t, e)); + } + } + return typeof s == "function" ? s(t, e) : s; +} +const Nt = "\uFEFF", vt = "", Tt = "", Ke = "", Xi = (e) => !!e && "items" in e, Zi = (e) => !!e && (e.type === "scalar" || e.type === "single-quoted-scalar" || e.type === "double-quoted-scalar" || e.type === "block-scalar"); +function Ci(e) { + switch (e) { + case Nt: + return ""; + case vt: + return ""; + case Tt: + return ""; + case Ke: + return ""; + default: + return JSON.stringify(e); + } +} +function js(e) { + switch (e) { + case Nt: + return "byte-order-mark"; + case vt: + return "doc-mode"; + case Tt: + return "flow-error-end"; + case Ke: + return "scalar"; + case "---": + return "doc-start"; + case "...": + return "doc-end"; + case "": + case ` +`: + case `\r +`: + return "newline"; + case "-": + return "seq-item-ind"; + case "?": + return "explicit-key-ind"; + case ":": + return "map-value-ind"; + case "{": + return "flow-map-start"; + case "}": + return "flow-map-end"; + case "[": + return "flow-seq-start"; + case "]": + return "flow-seq-end"; + case ",": + return "comma"; + } + switch (e[0]) { + case " ": + case " ": + return "space"; + case "#": + return "comment"; + case "%": + return "directive-line"; + case "*": + return "alias"; + case "&": + return "anchor"; + case "!": + return "tag"; + case "'": + return "single-quoted-scalar"; + case '"': + return "double-quoted-scalar"; + case "|": + case ">": + return "block-scalar-header"; + } + return null; +} +const $s = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ + __proto__: null, + BOM: Nt, + DOCUMENT: vt, + FLOW_END: Tt, + SCALAR: Ke, + createScalarToken: Gi, + isCollection: Xi, + isScalar: Zi, + prettyToken: Ci, + resolveAsScalar: Yi, + setScalarValue: Wi, + stringify: Hi, + tokenType: js, + visit: ae +}, Symbol.toStringTag, { value: "Module" })); +function V(e) { + switch (e) { + case void 0: + case " ": + case ` +`: + case "\r": + case " ": + return !0; + default: + return !1; + } +} +const En = new Set("0123456789ABCDEFabcdef"), xi = new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"), xe = new Set(",[]{}"), er = new Set(` ,[]{} +\r `), Kt = (e) => !e || er.has(e); +class un { + constructor() { + this.atEnd = !1, this.blockScalarIndent = -1, this.blockScalarKeep = !1, this.buffer = "", this.flowKey = !1, this.flowLevel = 0, this.indentNext = 0, this.indentValue = 0, this.lineEndPos = null, this.next = null, this.pos = 0; + } + /** + * Generate YAML tokens from the `source` string. If `incomplete`, + * a part of the last line may be left as a buffer for the next call. + * + * @returns A generator of lexical tokens + */ + *lex(t, n = !1) { + if (t) { + if (typeof t != "string") + throw TypeError("source is not a string"); + this.buffer = this.buffer ? this.buffer + t : t, this.lineEndPos = null; + } + this.atEnd = !n; + let s = this.next ?? "stream"; + for (; s && (n || this.hasChars(1)); ) + s = yield* this.parseNext(s); + } + atLineEnd() { + let t = this.pos, n = this.buffer[t]; + for (; n === " " || n === " "; ) + n = this.buffer[++t]; + return !n || n === "#" || n === ` +` ? !0 : n === "\r" ? this.buffer[t + 1] === ` +` : !1; + } + charAt(t) { + return this.buffer[this.pos + t]; + } + continueScalar(t) { + let n = this.buffer[t]; + if (this.indentNext > 0) { + let s = 0; + for (; n === " "; ) + n = this.buffer[++s + t]; + if (n === "\r") { + const i = this.buffer[s + t + 1]; + if (i === ` +` || !i && !this.atEnd) + return t + s + 1; + } + return n === ` +` || s >= this.indentNext || !n && !this.atEnd ? t + s : -1; + } + if (n === "-" || n === ".") { + const s = this.buffer.substr(t, 3); + if ((s === "---" || s === "...") && V(this.buffer[t + 3])) + return -1; + } + return t; + } + getLine() { + let t = this.lineEndPos; + return (typeof t != "number" || t !== -1 && t < this.pos) && (t = this.buffer.indexOf(` +`, this.pos), this.lineEndPos = t), t === -1 ? this.atEnd ? this.buffer.substring(this.pos) : null : (this.buffer[t - 1] === "\r" && (t -= 1), this.buffer.substring(this.pos, t)); + } + hasChars(t) { + return this.pos + t <= this.buffer.length; + } + setNext(t) { + return this.buffer = this.buffer.substring(this.pos), this.pos = 0, this.lineEndPos = null, this.next = t, null; + } + peek(t) { + return this.buffer.substr(this.pos, t); + } + *parseNext(t) { + switch (t) { + case "stream": + return yield* this.parseStream(); + case "line-start": + return yield* this.parseLineStart(); + case "block-start": + return yield* this.parseBlockStart(); + case "doc": + return yield* this.parseDocument(); + case "flow": + return yield* this.parseFlowCollection(); + case "quoted-scalar": + return yield* this.parseQuotedScalar(); + case "block-scalar": + return yield* this.parseBlockScalar(); + case "plain-scalar": + return yield* this.parsePlainScalar(); + } + } + *parseStream() { + let t = this.getLine(); + if (t === null) + return this.setNext("stream"); + if (t[0] === Nt && (yield* this.pushCount(1), t = t.substring(1)), t[0] === "%") { + let n = t.length, s = t.indexOf("#"); + for (; s !== -1; ) { + const r = t[s - 1]; + if (r === " " || r === " ") { + n = s - 1; + break; + } else + s = t.indexOf("#", s + 1); + } + for (; ; ) { + const r = t[n - 1]; + if (r === " " || r === " ") + n -= 1; + else + break; + } + const i = (yield* this.pushCount(n)) + (yield* this.pushSpaces(!0)); + return yield* this.pushCount(t.length - i), this.pushNewline(), "stream"; + } + if (this.atLineEnd()) { + const n = yield* this.pushSpaces(!0); + return yield* this.pushCount(t.length - n), yield* this.pushNewline(), "stream"; + } + return yield vt, yield* this.parseLineStart(); + } + *parseLineStart() { + const t = this.charAt(0); + if (!t && !this.atEnd) + return this.setNext("line-start"); + if (t === "-" || t === ".") { + if (!this.atEnd && !this.hasChars(4)) + return this.setNext("line-start"); + const n = this.peek(3); + if ((n === "---" || n === "...") && V(this.charAt(3))) + return yield* this.pushCount(3), this.indentValue = 0, this.indentNext = 0, n === "---" ? "doc" : "stream"; + } + return this.indentValue = yield* this.pushSpaces(!1), this.indentNext > this.indentValue && !V(this.charAt(1)) && (this.indentNext = this.indentValue), yield* this.parseBlockStart(); + } + *parseBlockStart() { + const [t, n] = this.peek(2); + if (!n && !this.atEnd) + return this.setNext("block-start"); + if ((t === "-" || t === "?" || t === ":") && V(n)) { + const s = (yield* this.pushCount(1)) + (yield* this.pushSpaces(!0)); + return this.indentNext = this.indentValue + 1, this.indentValue += s, yield* this.parseBlockStart(); + } + return "doc"; + } + *parseDocument() { + yield* this.pushSpaces(!0); + const t = this.getLine(); + if (t === null) + return this.setNext("doc"); + let n = yield* this.pushIndicators(); + switch (t[n]) { + case "#": + yield* this.pushCount(t.length - n); + // fallthrough + case void 0: + return yield* this.pushNewline(), yield* this.parseLineStart(); + case "{": + case "[": + return yield* this.pushCount(1), this.flowKey = !1, this.flowLevel = 1, "flow"; + case "}": + case "]": + return yield* this.pushCount(1), "doc"; + case "*": + return yield* this.pushUntil(Kt), "doc"; + case '"': + case "'": + return yield* this.parseQuotedScalar(); + case "|": + case ">": + return n += yield* this.parseBlockScalarHeader(), n += yield* this.pushSpaces(!0), yield* this.pushCount(t.length - n), yield* this.pushNewline(), yield* this.parseBlockScalar(); + default: + return yield* this.parsePlainScalar(); + } + } + *parseFlowCollection() { + let t, n, s = -1; + do + t = yield* this.pushNewline(), t > 0 ? (n = yield* this.pushSpaces(!1), this.indentValue = s = n) : n = 0, n += yield* this.pushSpaces(!0); + while (t + n > 0); + const i = this.getLine(); + if (i === null) + return this.setNext("flow"); + if ((s !== -1 && s < this.indentNext && i[0] !== "#" || s === 0 && (i.startsWith("---") || i.startsWith("...")) && V(i[3])) && !(s === this.indentNext - 1 && this.flowLevel === 1 && (i[0] === "]" || i[0] === "}"))) + return this.flowLevel = 0, yield Tt, yield* this.parseLineStart(); + let r = 0; + for (; i[r] === ","; ) + r += yield* this.pushCount(1), r += yield* this.pushSpaces(!0), this.flowKey = !1; + switch (r += yield* this.pushIndicators(), i[r]) { + case void 0: + return "flow"; + case "#": + return yield* this.pushCount(i.length - r), "flow"; + case "{": + case "[": + return yield* this.pushCount(1), this.flowKey = !1, this.flowLevel += 1, "flow"; + case "}": + case "]": + return yield* this.pushCount(1), this.flowKey = !0, this.flowLevel -= 1, this.flowLevel ? "flow" : "doc"; + case "*": + return yield* this.pushUntil(Kt), "flow"; + case '"': + case "'": + return this.flowKey = !0, yield* this.parseQuotedScalar(); + case ":": { + const o = this.charAt(1); + if (this.flowKey || V(o) || o === ",") + return this.flowKey = !1, yield* this.pushCount(1), yield* this.pushSpaces(!0), "flow"; + } + // fallthrough + default: + return this.flowKey = !1, yield* this.parsePlainScalar(); + } + } + *parseQuotedScalar() { + const t = this.charAt(0); + let n = this.buffer.indexOf(t, this.pos + 1); + if (t === "'") + for (; n !== -1 && this.buffer[n + 1] === "'"; ) + n = this.buffer.indexOf("'", n + 2); + else + for (; n !== -1; ) { + let r = 0; + for (; this.buffer[n - 1 - r] === "\\"; ) + r += 1; + if (r % 2 === 0) + break; + n = this.buffer.indexOf('"', n + 1); + } + const s = this.buffer.substring(0, n); + let i = s.indexOf(` +`, this.pos); + if (i !== -1) { + for (; i !== -1; ) { + const r = this.continueScalar(i + 1); + if (r === -1) + break; + i = s.indexOf(` +`, r); + } + i !== -1 && (n = i - (s[i - 1] === "\r" ? 2 : 1)); + } + if (n === -1) { + if (!this.atEnd) + return this.setNext("quoted-scalar"); + n = this.buffer.length; + } + return yield* this.pushToIndex(n + 1, !1), this.flowLevel ? "flow" : "doc"; + } + *parseBlockScalarHeader() { + this.blockScalarIndent = -1, this.blockScalarKeep = !1; + let t = this.pos; + for (; ; ) { + const n = this.buffer[++t]; + if (n === "+") + this.blockScalarKeep = !0; + else if (n > "0" && n <= "9") + this.blockScalarIndent = Number(n) - 1; + else if (n !== "-") + break; + } + return yield* this.pushUntil((n) => V(n) || n === "#"); + } + *parseBlockScalar() { + let t = this.pos - 1, n = 0, s; + e: for (let r = this.pos; s = this.buffer[r]; ++r) + switch (s) { + case " ": + n += 1; + break; + case ` +`: + t = r, n = 0; + break; + case "\r": { + const o = this.buffer[r + 1]; + if (!o && !this.atEnd) + return this.setNext("block-scalar"); + if (o === ` +`) + break; + } + // fallthrough + default: + break e; + } + if (!s && !this.atEnd) + return this.setNext("block-scalar"); + if (n >= this.indentNext) { + this.blockScalarIndent === -1 ? this.indentNext = n : this.indentNext = this.blockScalarIndent + (this.indentNext === 0 ? 1 : this.indentNext); + do { + const r = this.continueScalar(t + 1); + if (r === -1) + break; + t = this.buffer.indexOf(` +`, r); + } while (t !== -1); + if (t === -1) { + if (!this.atEnd) + return this.setNext("block-scalar"); + t = this.buffer.length; + } + } + let i = t + 1; + for (s = this.buffer[i]; s === " "; ) + s = this.buffer[++i]; + if (s === " ") { + for (; s === " " || s === " " || s === "\r" || s === ` +`; ) + s = this.buffer[++i]; + t = i - 1; + } else if (!this.blockScalarKeep) + do { + let r = t - 1, o = this.buffer[r]; + o === "\r" && (o = this.buffer[--r]); + const a = r; + for (; o === " "; ) + o = this.buffer[--r]; + if (o === ` +` && r >= this.pos && r + 1 + n > a) + t = r; + else + break; + } while (!0); + return yield Ke, yield* this.pushToIndex(t + 1, !0), yield* this.parseLineStart(); + } + *parsePlainScalar() { + const t = this.flowLevel > 0; + let n = this.pos - 1, s = this.pos - 1, i; + for (; i = this.buffer[++s]; ) + if (i === ":") { + const r = this.buffer[s + 1]; + if (V(r) || t && xe.has(r)) + break; + n = s; + } else if (V(i)) { + let r = this.buffer[s + 1]; + if (i === "\r" && (r === ` +` ? (s += 1, i = ` +`, r = this.buffer[s + 1]) : n = s), r === "#" || t && xe.has(r)) + break; + if (i === ` +`) { + const o = this.continueScalar(s + 1); + if (o === -1) + break; + s = Math.max(s, o - 2); + } + } else { + if (t && xe.has(i)) + break; + n = s; + } + return !i && !this.atEnd ? this.setNext("plain-scalar") : (yield Ke, yield* this.pushToIndex(n + 1, !0), t ? "flow" : "doc"); + } + *pushCount(t) { + return t > 0 ? (yield this.buffer.substr(this.pos, t), this.pos += t, t) : 0; + } + *pushToIndex(t, n) { + const s = this.buffer.slice(this.pos, t); + return s ? (yield s, this.pos += s.length, s.length) : (n && (yield ""), 0); + } + *pushIndicators() { + switch (this.charAt(0)) { + case "!": + return (yield* this.pushTag()) + (yield* this.pushSpaces(!0)) + (yield* this.pushIndicators()); + case "&": + return (yield* this.pushUntil(Kt)) + (yield* this.pushSpaces(!0)) + (yield* this.pushIndicators()); + case "-": + // this is an error + case "?": + // this is an error outside flow collections + case ":": { + const t = this.flowLevel > 0, n = this.charAt(1); + if (V(n) || t && xe.has(n)) + return t ? this.flowKey && (this.flowKey = !1) : this.indentNext = this.indentValue + 1, (yield* this.pushCount(1)) + (yield* this.pushSpaces(!0)) + (yield* this.pushIndicators()); + } + } + return 0; + } + *pushTag() { + if (this.charAt(1) === "<") { + let t = this.pos + 2, n = this.buffer[t]; + for (; !V(n) && n !== ">"; ) + n = this.buffer[++t]; + return yield* this.pushToIndex(n === ">" ? t + 1 : t, !1); + } else { + let t = this.pos + 1, n = this.buffer[t]; + for (; n; ) + if (xi.has(n)) + n = this.buffer[++t]; + else if (n === "%" && En.has(this.buffer[t + 1]) && En.has(this.buffer[t + 2])) + n = this.buffer[t += 3]; + else + break; + return yield* this.pushToIndex(t, !1); + } + } + *pushNewline() { + const t = this.buffer[this.pos]; + return t === ` +` ? yield* this.pushCount(1) : t === "\r" && this.charAt(1) === ` +` ? yield* this.pushCount(2) : 0; + } + *pushSpaces(t) { + let n = this.pos - 1, s; + do + s = this.buffer[++n]; + while (s === " " || t && s === " "); + const i = n - this.pos; + return i > 0 && (yield this.buffer.substr(this.pos, i), this.pos = n), i; + } + *pushUntil(t) { + let n = this.pos, s = this.buffer[n]; + for (; !t(s); ) + s = this.buffer[++n]; + return yield* this.pushToIndex(n, !1); + } +} +class hn { + constructor() { + this.lineStarts = [], this.addNewLine = (t) => this.lineStarts.push(t), this.linePos = (t) => { + let n = 0, s = this.lineStarts.length; + for (; n < s; ) { + const r = n + s >> 1; + this.lineStarts[r] < t ? n = r + 1 : s = r; + } + if (this.lineStarts[n] === t) + return { line: n + 1, col: 1 }; + if (n === 0) + return { line: 0, col: t }; + const i = this.lineStarts[n - 1]; + return { line: n, col: t - i + 1 }; + }; + } +} +function x(e, t) { + for (let n = 0; n < e.length; ++n) + if (e[n].type === t) + return !0; + return !1; +} +function Ln(e) { + for (let t = 0; t < e.length; ++t) + switch (e[t].type) { + case "space": + case "comment": + case "newline": + break; + default: + return t; + } + return -1; +} +function Ps(e) { + switch (e?.type) { + case "alias": + case "scalar": + case "single-quoted-scalar": + case "double-quoted-scalar": + case "flow-collection": + return !0; + default: + return !1; + } +} +function et(e) { + switch (e.type) { + case "document": + return e.start; + case "block-map": { + const t = e.items[e.items.length - 1]; + return t.sep ?? t.start; + } + case "block-seq": + return e.items[e.items.length - 1].start; + /* istanbul ignore next should not happen */ + default: + return []; + } +} +function pe(e) { + if (e.length === 0) + return []; + let t = e.length; + e: for (; --t >= 0; ) + switch (e[t].type) { + case "doc-start": + case "explicit-key-ind": + case "map-value-ind": + case "seq-item-ind": + case "newline": + break e; + } + for (; e[++t]?.type === "space"; ) + ; + return e.splice(t, e.length); +} +function In(e) { + if (e.start.type === "flow-seq-start") + for (const t of e.items) + t.sep && !t.value && !x(t.start, "explicit-key-ind") && !x(t.sep, "map-value-ind") && (t.key && (t.value = t.key), delete t.key, Ps(t.value) ? t.value.end ? Array.prototype.push.apply(t.value.end, t.sep) : t.value.end = t.sep : Array.prototype.push.apply(t.start, t.sep), delete t.sep); +} +class Et { + /** + * @param onNewLine - If defined, called separately with the start position of + * each new line (in `parse()`, including the start of input). + */ + constructor(t) { + this.atNewLine = !0, this.atScalar = !1, this.indent = 0, this.offset = 0, this.onKeyLine = !1, this.stack = [], this.source = "", this.type = "", this.lexer = new un(), this.onNewLine = t; + } + /** + * Parse `source` as a YAML stream. + * If `incomplete`, a part of the last line may be left as a buffer for the next call. + * + * Errors are not thrown, but yielded as `{ type: 'error', message }` tokens. + * + * @returns A generator of tokens representing each directive, document, and other structure. + */ + *parse(t, n = !1) { + this.onNewLine && this.offset === 0 && this.onNewLine(0); + for (const s of this.lexer.lex(t, n)) + yield* this.next(s); + n || (yield* this.end()); + } + /** + * Advance the parser by the `source` of one lexical token. + */ + *next(t) { + if (this.source = t, this.atScalar) { + this.atScalar = !1, yield* this.step(), this.offset += t.length; + return; + } + const n = js(t); + if (n) + if (n === "scalar") + this.atNewLine = !1, this.atScalar = !0, this.type = "scalar"; + else { + switch (this.type = n, yield* this.step(), n) { + case "newline": + this.atNewLine = !0, this.indent = 0, this.onNewLine && this.onNewLine(this.offset + t.length); + break; + case "space": + this.atNewLine && t[0] === " " && (this.indent += t.length); + break; + case "explicit-key-ind": + case "map-value-ind": + case "seq-item-ind": + this.atNewLine && (this.indent += t.length); + break; + case "doc-mode": + case "flow-error-end": + return; + default: + this.atNewLine = !1; + } + this.offset += t.length; + } + else { + const s = `Not a YAML token: ${t}`; + yield* this.pop({ type: "error", offset: this.offset, message: s, source: t }), this.offset += t.length; + } + } + /** Call at end of input to push out any remaining constructions */ + *end() { + for (; this.stack.length > 0; ) + yield* this.pop(); + } + get sourceToken() { + return { + type: this.type, + offset: this.offset, + indent: this.indent, + source: this.source + }; + } + *step() { + const t = this.peek(1); + if (this.type === "doc-end" && (!t || t.type !== "doc-end")) { + for (; this.stack.length > 0; ) + yield* this.pop(); + this.stack.push({ + type: "doc-end", + offset: this.offset, + source: this.source + }); + return; + } + if (!t) + return yield* this.stream(); + switch (t.type) { + case "document": + return yield* this.document(t); + case "alias": + case "scalar": + case "single-quoted-scalar": + case "double-quoted-scalar": + return yield* this.scalar(t); + case "block-scalar": + return yield* this.blockScalar(t); + case "block-map": + return yield* this.blockMap(t); + case "block-seq": + return yield* this.blockSequence(t); + case "flow-collection": + return yield* this.flowCollection(t); + case "doc-end": + return yield* this.documentEnd(t); + } + yield* this.pop(); + } + peek(t) { + return this.stack[this.stack.length - t]; + } + *pop(t) { + const n = t ?? this.stack.pop(); + if (!n) + yield { type: "error", offset: this.offset, source: "", message: "Tried to pop an empty stack" }; + else if (this.stack.length === 0) + yield n; + else { + const s = this.peek(1); + switch (n.type === "block-scalar" ? n.indent = "indent" in s ? s.indent : 0 : n.type === "flow-collection" && s.type === "document" && (n.indent = 0), n.type === "flow-collection" && In(n), s.type) { + case "document": + s.value = n; + break; + case "block-scalar": + s.props.push(n); + break; + case "block-map": { + const i = s.items[s.items.length - 1]; + if (i.value) { + s.items.push({ start: [], key: n, sep: [] }), this.onKeyLine = !0; + return; + } else if (i.sep) + i.value = n; + else { + Object.assign(i, { key: n, sep: [] }), this.onKeyLine = !i.explicitKey; + return; + } + break; + } + case "block-seq": { + const i = s.items[s.items.length - 1]; + i.value ? s.items.push({ start: [], value: n }) : i.value = n; + break; + } + case "flow-collection": { + const i = s.items[s.items.length - 1]; + !i || i.value ? s.items.push({ start: [], key: n, sep: [] }) : i.sep ? i.value = n : Object.assign(i, { key: n, sep: [] }); + return; + } + /* istanbul ignore next should not happen */ + default: + yield* this.pop(), yield* this.pop(n); + } + if ((s.type === "document" || s.type === "block-map" || s.type === "block-seq") && (n.type === "block-map" || n.type === "block-seq")) { + const i = n.items[n.items.length - 1]; + i && !i.sep && !i.value && i.start.length > 0 && Ln(i.start) === -1 && (n.indent === 0 || i.start.every((r) => r.type !== "comment" || r.indent < n.indent)) && (s.type === "document" ? s.end = i.start : s.items.push({ start: i.start }), n.items.splice(-1, 1)); + } + } + } + *stream() { + switch (this.type) { + case "directive-line": + yield { type: "directive", offset: this.offset, source: this.source }; + return; + case "byte-order-mark": + case "space": + case "comment": + case "newline": + yield this.sourceToken; + return; + case "doc-mode": + case "doc-start": { + const t = { + type: "document", + offset: this.offset, + start: [] + }; + this.type === "doc-start" && t.start.push(this.sourceToken), this.stack.push(t); + return; + } + } + yield { + type: "error", + offset: this.offset, + message: `Unexpected ${this.type} token in YAML stream`, + source: this.source + }; + } + *document(t) { + if (t.value) + return yield* this.lineEnd(t); + switch (this.type) { + case "doc-start": { + Ln(t.start) !== -1 ? (yield* this.pop(), yield* this.step()) : t.start.push(this.sourceToken); + return; + } + case "anchor": + case "tag": + case "space": + case "comment": + case "newline": + t.start.push(this.sourceToken); + return; + } + const n = this.startBlockValue(t); + n ? this.stack.push(n) : yield { + type: "error", + offset: this.offset, + message: `Unexpected ${this.type} token in YAML document`, + source: this.source + }; + } + *scalar(t) { + if (this.type === "map-value-ind") { + const n = et(this.peek(2)), s = pe(n); + let i; + t.end ? (i = t.end, i.push(this.sourceToken), delete t.end) : i = [this.sourceToken]; + const r = { + type: "block-map", + offset: t.offset, + indent: t.indent, + items: [{ start: s, key: t, sep: i }] + }; + this.onKeyLine = !0, this.stack[this.stack.length - 1] = r; + } else + yield* this.lineEnd(t); + } + *blockScalar(t) { + switch (this.type) { + case "space": + case "comment": + case "newline": + t.props.push(this.sourceToken); + return; + case "scalar": + if (t.source = this.source, this.atNewLine = !0, this.indent = 0, this.onNewLine) { + let n = this.source.indexOf(` +`) + 1; + for (; n !== 0; ) + this.onNewLine(this.offset + n), n = this.source.indexOf(` +`, n) + 1; + } + yield* this.pop(); + break; + /* istanbul ignore next should not happen */ + default: + yield* this.pop(), yield* this.step(); + } + } + *blockMap(t) { + const n = t.items[t.items.length - 1]; + switch (this.type) { + case "newline": + if (this.onKeyLine = !1, n.value) { + const s = "end" in n.value ? n.value.end : void 0; + (Array.isArray(s) ? s[s.length - 1] : void 0)?.type === "comment" ? s?.push(this.sourceToken) : t.items.push({ start: [this.sourceToken] }); + } else n.sep ? n.sep.push(this.sourceToken) : n.start.push(this.sourceToken); + return; + case "space": + case "comment": + if (n.value) + t.items.push({ start: [this.sourceToken] }); + else if (n.sep) + n.sep.push(this.sourceToken); + else { + if (this.atIndentedComment(n.start, t.indent)) { + const i = t.items[t.items.length - 2]?.value?.end; + if (Array.isArray(i)) { + Array.prototype.push.apply(i, n.start), i.push(this.sourceToken), t.items.pop(); + return; + } + } + n.start.push(this.sourceToken); + } + return; + } + if (this.indent >= t.indent) { + const s = !this.onKeyLine && this.indent === t.indent, i = s && (n.sep || n.explicitKey) && this.type !== "seq-item-ind"; + let r = []; + if (i && n.sep && !n.value) { + const o = []; + for (let a = 0; a < n.sep.length; ++a) { + const l = n.sep[a]; + switch (l.type) { + case "newline": + o.push(a); + break; + case "space": + break; + case "comment": + l.indent > t.indent && (o.length = 0); + break; + default: + o.length = 0; + } + } + o.length >= 2 && (r = n.sep.splice(o[1])); + } + switch (this.type) { + case "anchor": + case "tag": + i || n.value ? (r.push(this.sourceToken), t.items.push({ start: r }), this.onKeyLine = !0) : n.sep ? n.sep.push(this.sourceToken) : n.start.push(this.sourceToken); + return; + case "explicit-key-ind": + !n.sep && !n.explicitKey ? (n.start.push(this.sourceToken), n.explicitKey = !0) : i || n.value ? (r.push(this.sourceToken), t.items.push({ start: r, explicitKey: !0 })) : this.stack.push({ + type: "block-map", + offset: this.offset, + indent: this.indent, + items: [{ start: [this.sourceToken], explicitKey: !0 }] + }), this.onKeyLine = !0; + return; + case "map-value-ind": + if (n.explicitKey) + if (n.sep) + if (n.value) + t.items.push({ start: [], key: null, sep: [this.sourceToken] }); + else if (x(n.sep, "map-value-ind")) + this.stack.push({ + type: "block-map", + offset: this.offset, + indent: this.indent, + items: [{ start: r, key: null, sep: [this.sourceToken] }] + }); + else if (Ps(n.key) && !x(n.sep, "newline")) { + const o = pe(n.start), a = n.key, l = n.sep; + l.push(this.sourceToken), delete n.key, delete n.sep, this.stack.push({ + type: "block-map", + offset: this.offset, + indent: this.indent, + items: [{ start: o, key: a, sep: l }] + }); + } else r.length > 0 ? n.sep = n.sep.concat(r, this.sourceToken) : n.sep.push(this.sourceToken); + else if (x(n.start, "newline")) + Object.assign(n, { key: null, sep: [this.sourceToken] }); + else { + const o = pe(n.start); + this.stack.push({ + type: "block-map", + offset: this.offset, + indent: this.indent, + items: [{ start: o, key: null, sep: [this.sourceToken] }] + }); + } + else + n.sep ? n.value || i ? t.items.push({ start: r, key: null, sep: [this.sourceToken] }) : x(n.sep, "map-value-ind") ? this.stack.push({ + type: "block-map", + offset: this.offset, + indent: this.indent, + items: [{ start: [], key: null, sep: [this.sourceToken] }] + }) : n.sep.push(this.sourceToken) : Object.assign(n, { key: null, sep: [this.sourceToken] }); + this.onKeyLine = !0; + return; + case "alias": + case "scalar": + case "single-quoted-scalar": + case "double-quoted-scalar": { + const o = this.flowScalar(this.type); + i || n.value ? (t.items.push({ start: r, key: o, sep: [] }), this.onKeyLine = !0) : n.sep ? this.stack.push(o) : (Object.assign(n, { key: o, sep: [] }), this.onKeyLine = !0); + return; + } + default: { + const o = this.startBlockValue(t); + if (o) { + if (o.type === "block-seq") { + if (!n.explicitKey && n.sep && !x(n.sep, "newline")) { + yield* this.pop({ + type: "error", + offset: this.offset, + message: "Unexpected block-seq-ind on same line with key", + source: this.source + }); + return; + } + } else s && t.items.push({ start: r }); + this.stack.push(o); + return; + } + } + } + } + yield* this.pop(), yield* this.step(); + } + *blockSequence(t) { + const n = t.items[t.items.length - 1]; + switch (this.type) { + case "newline": + if (n.value) { + const s = "end" in n.value ? n.value.end : void 0; + (Array.isArray(s) ? s[s.length - 1] : void 0)?.type === "comment" ? s?.push(this.sourceToken) : t.items.push({ start: [this.sourceToken] }); + } else + n.start.push(this.sourceToken); + return; + case "space": + case "comment": + if (n.value) + t.items.push({ start: [this.sourceToken] }); + else { + if (this.atIndentedComment(n.start, t.indent)) { + const i = t.items[t.items.length - 2]?.value?.end; + if (Array.isArray(i)) { + Array.prototype.push.apply(i, n.start), i.push(this.sourceToken), t.items.pop(); + return; + } + } + n.start.push(this.sourceToken); + } + return; + case "anchor": + case "tag": + if (n.value || this.indent <= t.indent) + break; + n.start.push(this.sourceToken); + return; + case "seq-item-ind": + if (this.indent !== t.indent) + break; + n.value || x(n.start, "seq-item-ind") ? t.items.push({ start: [this.sourceToken] }) : n.start.push(this.sourceToken); + return; + } + if (this.indent > t.indent) { + const s = this.startBlockValue(t); + if (s) { + this.stack.push(s); + return; + } + } + yield* this.pop(), yield* this.step(); + } + *flowCollection(t) { + const n = t.items[t.items.length - 1]; + if (this.type === "flow-error-end") { + let s; + do + yield* this.pop(), s = this.peek(1); + while (s && s.type === "flow-collection"); + } else if (t.end.length === 0) { + switch (this.type) { + case "comma": + case "explicit-key-ind": + !n || n.sep ? t.items.push({ start: [this.sourceToken] }) : n.start.push(this.sourceToken); + return; + case "map-value-ind": + !n || n.value ? t.items.push({ start: [], key: null, sep: [this.sourceToken] }) : n.sep ? n.sep.push(this.sourceToken) : Object.assign(n, { key: null, sep: [this.sourceToken] }); + return; + case "space": + case "comment": + case "newline": + case "anchor": + case "tag": + !n || n.value ? t.items.push({ start: [this.sourceToken] }) : n.sep ? n.sep.push(this.sourceToken) : n.start.push(this.sourceToken); + return; + case "alias": + case "scalar": + case "single-quoted-scalar": + case "double-quoted-scalar": { + const i = this.flowScalar(this.type); + !n || n.value ? t.items.push({ start: [], key: i, sep: [] }) : n.sep ? this.stack.push(i) : Object.assign(n, { key: i, sep: [] }); + return; + } + case "flow-map-end": + case "flow-seq-end": + t.end.push(this.sourceToken); + return; + } + const s = this.startBlockValue(t); + s ? this.stack.push(s) : (yield* this.pop(), yield* this.step()); + } else { + const s = this.peek(2); + if (s.type === "block-map" && (this.type === "map-value-ind" && s.indent === t.indent || this.type === "newline" && !s.items[s.items.length - 1].sep)) + yield* this.pop(), yield* this.step(); + else if (this.type === "map-value-ind" && s.type !== "flow-collection") { + const i = et(s), r = pe(i); + In(t); + const o = t.end.splice(1, t.end.length); + o.push(this.sourceToken); + const a = { + type: "block-map", + offset: t.offset, + indent: t.indent, + items: [{ start: r, key: t, sep: o }] + }; + this.onKeyLine = !0, this.stack[this.stack.length - 1] = a; + } else + yield* this.lineEnd(t); + } + } + flowScalar(t) { + if (this.onNewLine) { + let n = this.source.indexOf(` +`) + 1; + for (; n !== 0; ) + this.onNewLine(this.offset + n), n = this.source.indexOf(` +`, n) + 1; + } + return { + type: t, + offset: this.offset, + indent: this.indent, + source: this.source + }; + } + startBlockValue(t) { + switch (this.type) { + case "alias": + case "scalar": + case "single-quoted-scalar": + case "double-quoted-scalar": + return this.flowScalar(this.type); + case "block-scalar-header": + return { + type: "block-scalar", + offset: this.offset, + indent: this.indent, + props: [this.sourceToken], + source: "" + }; + case "flow-map-start": + case "flow-seq-start": + return { + type: "flow-collection", + offset: this.offset, + indent: this.indent, + start: this.sourceToken, + items: [], + end: [] + }; + case "seq-item-ind": + return { + type: "block-seq", + offset: this.offset, + indent: this.indent, + items: [{ start: [this.sourceToken] }] + }; + case "explicit-key-ind": { + this.onKeyLine = !0; + const n = et(t), s = pe(n); + return s.push(this.sourceToken), { + type: "block-map", + offset: this.offset, + indent: this.indent, + items: [{ start: s, explicitKey: !0 }] + }; + } + case "map-value-ind": { + this.onKeyLine = !0; + const n = et(t), s = pe(n); + return { + type: "block-map", + offset: this.offset, + indent: this.indent, + items: [{ start: s, key: null, sep: [this.sourceToken] }] + }; + } + } + return null; + } + atIndentedComment(t, n) { + return this.type !== "comment" || this.indent <= n ? !1 : t.every((s) => s.type === "newline" || s.type === "space"); + } + *documentEnd(t) { + this.type !== "doc-mode" && (t.end ? t.end.push(this.sourceToken) : t.end = [this.sourceToken], this.type === "newline" && (yield* this.pop())); + } + *lineEnd(t) { + switch (this.type) { + case "comma": + case "doc-start": + case "doc-end": + case "flow-seq-end": + case "flow-map-end": + case "map-value-ind": + yield* this.pop(), yield* this.step(); + break; + case "newline": + this.onKeyLine = !1; + default: + t.end ? t.end.push(this.sourceToken) : t.end = [this.sourceToken], this.type === "newline" && (yield* this.pop()); + } + } +} +function Bs(e) { + const t = e.prettyErrors !== !1; + return { lineCounter: e.lineCounter || t && new hn() || null, prettyErrors: t }; +} +function Ms(e, t = {}) { + const { lineCounter: n, prettyErrors: s } = Bs(t), i = new Et(n?.addNewLine), r = new At(t), o = Array.from(r.compose(i.parse(e))); + if (s && n) + for (const a of o) + a.errors.forEach(ut(e, n)), a.warnings.forEach(ut(e, n)); + return o.length > 0 ? o : Object.assign([], { empty: !0 }, r.streamInfo()); +} +function dn(e, t = {}) { + const { lineCounter: n, prettyErrors: s } = Bs(t), i = new Et(n?.addNewLine), r = new At(t); + let o = null; + for (const a of r.compose(i.parse(e), !0, e.length)) + if (!o) + o = a; + else if (o.options.logLevel !== "silent") { + o.errors.push(new ee(a.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()")); + break; + } + return s && n && (o.errors.forEach(ut(e, n)), o.warnings.forEach(ut(e, n))), o; +} +function Rs(e, t, n) { + let s; + typeof t == "function" ? s = t : n === void 0 && t && typeof t == "object" && (n = t); + const i = dn(e, n); + if (!i) + return null; + if (i.warnings.forEach((r) => ss(i.options.logLevel, r)), i.errors.length > 0) { + if (i.options.logLevel !== "silent") + throw i.errors[0]; + i.errors = []; + } + return i.toJS(Object.assign({ reviver: s }, n)); +} +function Ks(e, t, n) { + let s = null; + if (typeof t == "function" || Array.isArray(t) ? s = t : n === void 0 && t && (n = t), typeof n == "string" && (n = n.length), typeof n == "number") { + const i = Math.round(n); + n = i < 1 ? void 0 : i > 8 ? { indent: 8 } : { indent: i }; + } + if (e === void 0) { + const { keepUndefined: i } = n ?? t ?? {}; + if (!i) + return; + } + return ne(e) && !s ? e.toString(n) : new ue(e, s, n).toString(n); +} +const tr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ + __proto__: null, + Alias: Ue, + CST: $s, + Composer: At, + Document: ue, + Lexer: un, + LineCounter: hn, + Pair: B, + Parser: Et, + Scalar: v, + Schema: Ye, + YAMLError: Ot, + YAMLMap: K, + YAMLParseError: ee, + YAMLSeq: X, + YAMLWarning: cn, + isAlias: Z, + isCollection: I, + isDocument: ne, + isMap: ce, + isNode: _, + isPair: L, + isScalar: E, + isSeq: fe, + parse: Rs, + parseAllDocuments: Ms, + parseDocument: dn, + stringify: Ks, + visit: se, + visitAsync: Fe +}, Symbol.toStringTag, { value: "Module" })), nr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ + __proto__: null, + Alias: Ue, + CST: $s, + Composer: At, + Document: ue, + Lexer: un, + LineCounter: hn, + Pair: B, + Parser: Et, + Scalar: v, + Schema: Ye, + YAMLError: Ot, + YAMLMap: K, + YAMLParseError: ee, + YAMLSeq: X, + YAMLWarning: cn, + default: tr, + isAlias: Z, + isCollection: I, + isDocument: ne, + isMap: ce, + isNode: _, + isPair: L, + isScalar: E, + isSeq: fe, + parse: Rs, + parseAllDocuments: Ms, + parseDocument: dn, + stringify: Ks, + visit: se, + visitAsync: Fe +}, Symbol.toStringTag, { value: "Module" })), pn = /* @__PURE__ */ Un(nr); +var _n; +function sr() { + if (_n) return ze; + _n = 1, Object.defineProperty(ze, "__esModule", { value: !0 }), ze.visitYaml = t; + const e = pn; + function t(r, o, a, l, c) { + const f = n(o, a, l); + if ((0, e.isMap)(l)) { + c.onObjectStart(o, a, l, f); + for (const u of l.items) + t(r, l, u.key.value, u.value, c); + c.onObjectEnd(); + } else if ((0, e.isSeq)(l)) + c.onArrayStart(o, a, l, f), l.items.forEach((u, h) => { + t(r, l, h, u, c); + }), c.onArrayEnd(); + else if ((0, e.isScalar)(l)) + c.onValue(o, a, l.value, l.source, f); + else if ((0, e.isAlias)(l)) { + const u = l.resolve(r); + u !== void 0 && t(r, o, a, u, c); + } + } + function n(r, o, a) { + return { key: s(r, o), value: { start: a.range[0], end: a.range[1] } }; + } + function s(r, o) { + if ((0, e.isMap)(r)) { + const a = i(r.items, o); + if (a !== void 0 && a.key.range) + return { start: a.key.range[0], end: a.key.range[1] }; + } + } + function i(r, o) { + const a = (0, e.isScalar)(o) ? o.value : o; + for (const l of r) + if ((0, e.isPair)(l) && (l.key === o || l.key === a || (0, e.isScalar)(l.key) && l.key.value === a)) + return l; + } + return ze; +} +var tt = {}, jn; +function ir() { + if (jn) return tt; + jn = 1, Object.defineProperty(tt, "__esModule", { value: !0 }), tt.visitJson = e; + function e(t, n, s, i, r) { + if (i === void 0) { + r.onValue(n, s, null, void 0, { value: { start: 0, end: 0 } }); + return; + } + const o = { value: { start: i.offset, end: i.offset + i.length } }; + if (n && n.type === "property") { + const a = n.children[0]; + o.key = { start: a.offset, end: a.offset + a.length }; + } + if (i.type === "object") { + r.onObjectStart(n, s, i, o); + for (const a of i.children) { + const [l, c] = a.children; + e(void 0, a, l.value, c, r); + } + r.onObjectEnd(); + } else i.type === "array" ? (r.onArrayStart(n, s, i, o), i.children.forEach((a, l) => { + e(void 0, i, l, a, r); + }), r.onArrayEnd()) : r.onValue(n, s, i.value, i.rawValue, o); + } + return tt; +} +var nt = {}; +function Lt(e, t = !1) { + const n = e.length; + let s = 0, i = "", r = 0, o = 16, a = 0, l = 0, c = 0, f = 0, u = 0; + function h(y, O) { + let b = 0, w = 0; + for (; b < y; ) { + let k = e.charCodeAt(s); + if (k >= 48 && k <= 57) + w = w * 16 + k - 48; + else if (k >= 65 && k <= 70) + w = w * 16 + k - 65 + 10; + else if (k >= 97 && k <= 102) + w = w * 16 + k - 97 + 10; + else + break; + s++, b++; + } + return b < y && (w = -1), w; + } + function p(y) { + s = y, i = "", r = 0, o = 16, u = 0; + } + function m() { + let y = s; + if (e.charCodeAt(s) === 48) + s++; + else + for (s++; s < e.length && ge(e.charCodeAt(s)); ) + s++; + if (s < e.length && e.charCodeAt(s) === 46) + if (s++, s < e.length && ge(e.charCodeAt(s))) + for (s++; s < e.length && ge(e.charCodeAt(s)); ) + s++; + else + return u = 3, e.substring(y, s); + let O = s; + if (s < e.length && (e.charCodeAt(s) === 69 || e.charCodeAt(s) === 101)) + if (s++, (s < e.length && e.charCodeAt(s) === 43 || e.charCodeAt(s) === 45) && s++, s < e.length && ge(e.charCodeAt(s))) { + for (s++; s < e.length && ge(e.charCodeAt(s)); ) + s++; + O = s; + } else + u = 3; + return e.substring(y, O); + } + function d() { + let y = "", O = s; + for (; ; ) { + if (s >= n) { + y += e.substring(O, s), u = 2; + break; + } + const b = e.charCodeAt(s); + if (b === 34) { + y += e.substring(O, s), s++; + break; + } + if (b === 92) { + if (y += e.substring(O, s), s++, s >= n) { + u = 2; + break; + } + switch (e.charCodeAt(s++)) { + case 34: + y += '"'; + break; + case 92: + y += "\\"; + break; + case 47: + y += "/"; + break; + case 98: + y += "\b"; + break; + case 102: + y += "\f"; + break; + case 110: + y += ` +`; + break; + case 114: + y += "\r"; + break; + case 116: + y += " "; + break; + case 117: + const k = h(4); + k >= 0 ? y += String.fromCharCode(k) : u = 4; + break; + default: + u = 5; + } + O = s; + continue; + } + if (b >= 0 && b <= 31) + if ($e(b)) { + y += e.substring(O, s), u = 2; + break; + } else + u = 6; + s++; + } + return y; + } + function g() { + if (i = "", u = 0, r = s, l = a, f = c, s >= n) + return r = n, o = 17; + let y = e.charCodeAt(s); + if (Dt(y)) { + do + s++, i += String.fromCharCode(y), y = e.charCodeAt(s); + while (Dt(y)); + return o = 15; + } + if ($e(y)) + return s++, i += String.fromCharCode(y), y === 13 && e.charCodeAt(s) === 10 && (s++, i += ` +`), a++, c = s, o = 14; + switch (y) { + // tokens: []{}:, + case 123: + return s++, o = 1; + case 125: + return s++, o = 2; + case 91: + return s++, o = 3; + case 93: + return s++, o = 4; + case 58: + return s++, o = 6; + case 44: + return s++, o = 5; + // strings + case 34: + return s++, i = d(), o = 10; + // comments + case 47: + const O = s - 1; + if (e.charCodeAt(s + 1) === 47) { + for (s += 2; s < n && !$e(e.charCodeAt(s)); ) + s++; + return i = e.substring(O, s), o = 12; + } + if (e.charCodeAt(s + 1) === 42) { + s += 2; + const b = n - 1; + let w = !1; + for (; s < b; ) { + const k = e.charCodeAt(s); + if (k === 42 && e.charCodeAt(s + 1) === 47) { + s += 2, w = !0; + break; + } + s++, $e(k) && (k === 13 && e.charCodeAt(s) === 10 && s++, a++, c = s); + } + return w || (s++, u = 1), i = e.substring(O, s), o = 13; + } + return i += String.fromCharCode(y), s++, o = 16; + // numbers + case 45: + if (i += String.fromCharCode(y), s++, s === n || !ge(e.charCodeAt(s))) + return o = 16; + // found a minus, followed by a number so + // we fall through to proceed with scanning + // numbers + case 48: + case 49: + case 50: + case 51: + case 52: + case 53: + case 54: + case 55: + case 56: + case 57: + return i += m(), o = 11; + // literals and unknown symbols + default: + for (; s < n && S(y); ) + s++, y = e.charCodeAt(s); + if (r !== s) { + switch (i = e.substring(r, s), i) { + case "true": + return o = 8; + case "false": + return o = 9; + case "null": + return o = 7; + } + return o = 16; + } + return i += String.fromCharCode(y), s++, o = 16; + } + } + function S(y) { + if (Dt(y) || $e(y)) + return !1; + switch (y) { + case 125: + case 93: + case 123: + case 91: + case 34: + case 58: + case 44: + case 47: + return !1; + } + return !0; + } + function A() { + let y; + do + y = g(); + while (y >= 12 && y <= 15); + return y; + } + return { + setPosition: p, + getPosition: () => s, + scan: t ? A : g, + getToken: () => o, + getTokenValue: () => i, + getTokenOffset: () => r, + getTokenLength: () => s - r, + getTokenStartLine: () => l, + getTokenStartCharacter: () => r - f, + getTokenError: () => u + }; +} +function Dt(e) { + return e === 32 || e === 9; +} +function $e(e) { + return e === 10 || e === 13; +} +function ge(e) { + return e >= 48 && e <= 57; +} +var $n; +(function(e) { + e[e.lineFeed = 10] = "lineFeed", e[e.carriageReturn = 13] = "carriageReturn", e[e.space = 32] = "space", e[e._0 = 48] = "_0", e[e._1 = 49] = "_1", e[e._2 = 50] = "_2", e[e._3 = 51] = "_3", e[e._4 = 52] = "_4", e[e._5 = 53] = "_5", e[e._6 = 54] = "_6", e[e._7 = 55] = "_7", e[e._8 = 56] = "_8", e[e._9 = 57] = "_9", e[e.a = 97] = "a", e[e.b = 98] = "b", e[e.c = 99] = "c", e[e.d = 100] = "d", e[e.e = 101] = "e", e[e.f = 102] = "f", e[e.g = 103] = "g", e[e.h = 104] = "h", e[e.i = 105] = "i", e[e.j = 106] = "j", e[e.k = 107] = "k", e[e.l = 108] = "l", e[e.m = 109] = "m", e[e.n = 110] = "n", e[e.o = 111] = "o", e[e.p = 112] = "p", e[e.q = 113] = "q", e[e.r = 114] = "r", e[e.s = 115] = "s", e[e.t = 116] = "t", e[e.u = 117] = "u", e[e.v = 118] = "v", e[e.w = 119] = "w", e[e.x = 120] = "x", e[e.y = 121] = "y", e[e.z = 122] = "z", e[e.A = 65] = "A", e[e.B = 66] = "B", e[e.C = 67] = "C", e[e.D = 68] = "D", e[e.E = 69] = "E", e[e.F = 70] = "F", e[e.G = 71] = "G", e[e.H = 72] = "H", e[e.I = 73] = "I", e[e.J = 74] = "J", e[e.K = 75] = "K", e[e.L = 76] = "L", e[e.M = 77] = "M", e[e.N = 78] = "N", e[e.O = 79] = "O", e[e.P = 80] = "P", e[e.Q = 81] = "Q", e[e.R = 82] = "R", e[e.S = 83] = "S", e[e.T = 84] = "T", e[e.U = 85] = "U", e[e.V = 86] = "V", e[e.W = 87] = "W", e[e.X = 88] = "X", e[e.Y = 89] = "Y", e[e.Z = 90] = "Z", e[e.asterisk = 42] = "asterisk", e[e.backslash = 92] = "backslash", e[e.closeBrace = 125] = "closeBrace", e[e.closeBracket = 93] = "closeBracket", e[e.colon = 58] = "colon", e[e.comma = 44] = "comma", e[e.dot = 46] = "dot", e[e.doubleQuote = 34] = "doubleQuote", e[e.minus = 45] = "minus", e[e.openBrace = 123] = "openBrace", e[e.openBracket = 91] = "openBracket", e[e.plus = 43] = "plus", e[e.slash = 47] = "slash", e[e.formFeed = 12] = "formFeed", e[e.tab = 9] = "tab"; +})($n || ($n = {})); +const q = new Array(20).fill(0).map((e, t) => " ".repeat(t)), me = 200, Pn = { + " ": { + "\n": new Array(me).fill(0).map((e, t) => ` +` + " ".repeat(t)), + "\r": new Array(me).fill(0).map((e, t) => "\r" + " ".repeat(t)), + "\r\n": new Array(me).fill(0).map((e, t) => `\r +` + " ".repeat(t)) + }, + " ": { + "\n": new Array(me).fill(0).map((e, t) => ` +` + " ".repeat(t)), + "\r": new Array(me).fill(0).map((e, t) => "\r" + " ".repeat(t)), + "\r\n": new Array(me).fill(0).map((e, t) => `\r +` + " ".repeat(t)) + } +}, rr = [` +`, "\r", `\r +`]; +function Ds(e, t, n) { + let s, i, r, o, a; + if (t) { + for (o = t.offset, a = o + t.length, r = o; r > 0 && !dt(e, r - 1); ) + r--; + let b = a; + for (; b < e.length && !dt(e, b); ) + b++; + i = e.substring(r, b), s = or(i, n); + } else + i = e, s = 0, r = 0, o = 0, a = e.length; + const l = lr(n, e), c = rr.includes(l); + let f = 0, u = 0, h; + n.insertSpaces ? h = q[n.tabSize || 4] ?? ye(q[1], n.tabSize || 4) : h = " "; + const p = h === " " ? " " : " "; + let m = Lt(i, !1), d = !1; + function g() { + if (f > 1) + return ye(l, f) + ye(h, s + u); + const b = h.length * (s + u); + return !c || b > Pn[p][l].length ? l + ye(h, s + u) : b <= 0 ? l : Pn[p][l][b]; + } + function S() { + let b = m.scan(); + for (f = 0; b === 15 || b === 14; ) + b === 14 && n.keepLines ? f += 1 : b === 14 && (f = 1), b = m.scan(); + return d = b === 16 || m.getTokenError() !== 0, b; + } + const A = []; + function y(b, w, k) { + !d && (!t || w < a && k > o) && e.substring(w, k) !== b && A.push({ offset: w, length: k - w, content: b }); + } + let O = S(); + if (n.keepLines && f > 0 && y(ye(l, f), 0, 0), O !== 17) { + let b = m.getTokenOffset() + r, w = h.length * s < 20 && n.insertSpaces ? q[h.length * s] : ye(h, s); + y(w, r, b); + } + for (; O !== 17; ) { + let b = m.getTokenOffset() + m.getTokenLength() + r, w = S(), k = "", N = !1; + for (; f === 0 && (w === 12 || w === 13); ) { + let D = m.getTokenOffset() + r; + y(q[1], b, D), b = m.getTokenOffset() + m.getTokenLength() + r, N = w === 12, k = N ? g() : "", w = S(); + } + if (w === 2) + O !== 1 && u--, n.keepLines && f > 0 || !n.keepLines && O !== 1 ? k = g() : n.keepLines && (k = q[1]); + else if (w === 4) + O !== 3 && u--, n.keepLines && f > 0 || !n.keepLines && O !== 3 ? k = g() : n.keepLines && (k = q[1]); + else { + switch (O) { + case 3: + case 1: + u++, n.keepLines && f > 0 || !n.keepLines ? k = g() : k = q[1]; + break; + case 5: + n.keepLines && f > 0 || !n.keepLines ? k = g() : k = q[1]; + break; + case 12: + k = g(); + break; + case 13: + f > 0 ? k = g() : N || (k = q[1]); + break; + case 6: + n.keepLines && f > 0 ? k = g() : N || (k = q[1]); + break; + case 10: + n.keepLines && f > 0 ? k = g() : w === 6 && !N && (k = ""); + break; + case 7: + case 8: + case 9: + case 11: + case 2: + case 4: + n.keepLines && f > 0 ? k = g() : (w === 12 || w === 13) && !N ? k = q[1] : w !== 5 && w !== 17 && (d = !0); + break; + case 16: + d = !0; + break; + } + f > 0 && (w === 12 || w === 13) && (k = g()); + } + w === 17 && (n.keepLines && f > 0 ? k = g() : k = n.insertFinalNewline ? l : ""); + const j = m.getTokenOffset() + r; + y(k, b, j), O = w; + } + return A; +} +function ye(e, t) { + let n = ""; + for (let s = 0; s < t; s++) + n += e; + return n; +} +function or(e, t) { + let n = 0, s = 0; + const i = t.tabSize || 4; + for (; n < e.length; ) { + let r = e.charAt(n); + if (r === q[1]) + s++; + else if (r === " ") + s += i; + else + break; + n++; + } + return Math.floor(s / i); +} +function lr(e, t) { + for (let n = 0; n < t.length; n++) { + const s = t.charAt(n); + if (s === "\r") + return n + 1 < t.length && t.charAt(n + 1) === ` +` ? `\r +` : "\r"; + if (s === ` +`) + return ` +`; + } + return e && e.eol || ` +`; +} +function dt(e, t) { + return `\r +`.indexOf(e.charAt(t)) !== -1; +} +var De; +(function(e) { + e.DEFAULT = { + allowTrailingComma: !1 + }; +})(De || (De = {})); +function ar(e, t) { + const n = [], s = new Object(); + let i; + const r = { + value: {}, + offset: 0, + length: 0, + type: "object", + parent: void 0 + }; + let o = !1; + function a(l, c, f, u) { + r.value = l, r.offset = c, r.length = f, r.type = u, r.colonOffset = void 0, i = r; + } + try { + It(e, { + onObjectBegin: (l, c) => { + if (t <= l) + throw s; + i = void 0, o = t > l, n.push(""); + }, + onObjectProperty: (l, c, f) => { + if (t < c || (a(l, c, f, "property"), n[n.length - 1] = l, t <= c + f)) + throw s; + }, + onObjectEnd: (l, c) => { + if (t <= l) + throw s; + i = void 0, n.pop(); + }, + onArrayBegin: (l, c) => { + if (t <= l) + throw s; + i = void 0, n.push(0); + }, + onArrayEnd: (l, c) => { + if (t <= l) + throw s; + i = void 0, n.pop(); + }, + onLiteralValue: (l, c, f) => { + if (t < c || (a(l, c, f, Vs(l)), t <= c + f)) + throw s; + }, + onSeparator: (l, c, f) => { + if (t <= c) + throw s; + if (l === ":" && i && i.type === "property") + i.colonOffset = c, o = !1, i = void 0; + else if (l === ",") { + const u = n[n.length - 1]; + typeof u == "number" ? n[n.length - 1] = u + 1 : (o = !0, n[n.length - 1] = ""), i = void 0; + } + } + }); + } catch (l) { + if (l !== s) + throw l; + } + return { + path: n, + previousNode: i, + isAtPropertyKey: o, + matches: (l) => { + let c = 0; + for (let f = 0; c < l.length && f < n.length; f++) + if (l[c] === n[f] || l[c] === "*") + c++; + else if (l[c] !== "**") + return !1; + return c === l.length; + } + }; +} +function cr(e, t = [], n = De.DEFAULT) { + let s = null, i = []; + const r = []; + function o(l) { + Array.isArray(i) ? i.push(l) : s !== null && (i[s] = l); + } + return It(e, { + onObjectBegin: () => { + const l = {}; + o(l), r.push(i), i = l, s = null; + }, + onObjectProperty: (l) => { + s = l; + }, + onObjectEnd: () => { + i = r.pop(); + }, + onArrayBegin: () => { + const l = []; + o(l), r.push(i), i = l, s = null; + }, + onArrayEnd: () => { + i = r.pop(); + }, + onLiteralValue: o, + onError: (l, c, f) => { + t.push({ error: l, offset: c, length: f }); + } + }, n), i[0]; +} +function qs(e, t = [], n = De.DEFAULT) { + let s = { type: "array", offset: -1, length: -1, children: [], parent: void 0 }; + function i(l) { + s.type === "property" && (s.length = l - s.offset, s = s.parent); + } + function r(l) { + return s.children.push(l), l; + } + It(e, { + onObjectBegin: (l) => { + s = r({ type: "object", offset: l, length: -1, parent: s, children: [] }); + }, + onObjectProperty: (l, c, f) => { + s = r({ type: "property", offset: c, length: -1, parent: s, children: [] }), s.children.push({ type: "string", value: l, offset: c, length: f, parent: s }); + }, + onObjectEnd: (l, c) => { + i(l + c), s.length = l + c - s.offset, s = s.parent, i(l + c); + }, + onArrayBegin: (l, c) => { + s = r({ type: "array", offset: l, length: -1, parent: s, children: [] }); + }, + onArrayEnd: (l, c) => { + s.length = l + c - s.offset, s = s.parent, i(l + c); + }, + onLiteralValue: (l, c, f) => { + r({ type: Vs(l), offset: c, length: f, parent: s, value: l }), i(c + f); + }, + onSeparator: (l, c, f) => { + s.type === "property" && (l === ":" ? s.colonOffset = c : l === "," && i(c)); + }, + onError: (l, c, f) => { + t.push({ error: l, offset: c, length: f }); + } + }, n); + const a = s.children[0]; + return a && delete a.parent, a; +} +function Gt(e, t) { + if (!e) + return; + let n = e; + for (let s of t) + if (typeof s == "string") { + if (n.type !== "object" || !Array.isArray(n.children)) + return; + let i = !1; + for (const r of n.children) + if (Array.isArray(r.children) && r.children[0].value === s && r.children.length === 2) { + n = r.children[1], i = !0; + break; + } + if (!i) + return; + } else { + const i = s; + if (n.type !== "array" || i < 0 || !Array.isArray(n.children) || i >= n.children.length) + return; + n = n.children[i]; + } + return n; +} +function Fs(e) { + if (!e.parent || !e.parent.children) + return []; + const t = Fs(e.parent); + if (e.parent.type === "property") { + const n = e.parent.children[0].value; + t.push(n); + } else if (e.parent.type === "array") { + const n = e.parent.children.indexOf(e); + n !== -1 && t.push(n); + } + return t; +} +function Wt(e) { + switch (e.type) { + case "array": + return e.children.map(Wt); + case "object": + const t = /* @__PURE__ */ Object.create(null); + for (let n of e.children) { + const s = n.children[1]; + s && (t[n.children[0].value] = Wt(s)); + } + return t; + case "null": + case "string": + case "number": + case "boolean": + return e.value; + default: + return; + } +} +function fr(e, t, n = !1) { + return t >= e.offset && t < e.offset + e.length || n && t === e.offset + e.length; +} +function Us(e, t, n = !1) { + if (fr(e, t, n)) { + const s = e.children; + if (Array.isArray(s)) + for (let i = 0; i < s.length && s[i].offset <= t; i++) { + const r = Us(s[i], t, n); + if (r) + return r; + } + return e; + } +} +function It(e, t, n = De.DEFAULT) { + const s = Lt(e, !1), i = []; + let r = 0; + function o(T) { + return T ? () => r === 0 && T(s.getTokenOffset(), s.getTokenLength(), s.getTokenStartLine(), s.getTokenStartCharacter()) : () => !0; + } + function a(T) { + return T ? (P) => r === 0 && T(P, s.getTokenOffset(), s.getTokenLength(), s.getTokenStartLine(), s.getTokenStartCharacter()) : () => !0; + } + function l(T) { + return T ? (P) => r === 0 && T(P, s.getTokenOffset(), s.getTokenLength(), s.getTokenStartLine(), s.getTokenStartCharacter(), () => i.slice()) : () => !0; + } + function c(T) { + return T ? () => { + r > 0 ? r++ : T(s.getTokenOffset(), s.getTokenLength(), s.getTokenStartLine(), s.getTokenStartCharacter(), () => i.slice()) === !1 && (r = 1); + } : () => !0; + } + function f(T) { + return T ? () => { + r > 0 && r--, r === 0 && T(s.getTokenOffset(), s.getTokenLength(), s.getTokenStartLine(), s.getTokenStartCharacter()); + } : () => !0; + } + const u = c(t.onObjectBegin), h = l(t.onObjectProperty), p = f(t.onObjectEnd), m = c(t.onArrayBegin), d = f(t.onArrayEnd), g = l(t.onLiteralValue), S = a(t.onSeparator), A = o(t.onComment), y = a(t.onError), O = n && n.disallowComments, b = n && n.allowTrailingComma; + function w() { + for (; ; ) { + const T = s.scan(); + switch (s.getTokenError()) { + case 4: + k( + 14 + /* ParseErrorCode.InvalidUnicode */ + ); + break; + case 5: + k( + 15 + /* ParseErrorCode.InvalidEscapeCharacter */ + ); + break; + case 3: + k( + 13 + /* ParseErrorCode.UnexpectedEndOfNumber */ + ); + break; + case 1: + O || k( + 11 + /* ParseErrorCode.UnexpectedEndOfComment */ + ); + break; + case 2: + k( + 12 + /* ParseErrorCode.UnexpectedEndOfString */ + ); + break; + case 6: + k( + 16 + /* ParseErrorCode.InvalidCharacter */ + ); + break; + } + switch (T) { + case 12: + case 13: + O ? k( + 10 + /* ParseErrorCode.InvalidCommentToken */ + ) : A(); + break; + case 16: + k( + 1 + /* ParseErrorCode.InvalidSymbol */ + ); + break; + case 15: + case 14: + break; + default: + return T; + } + } + } + function k(T, P = [], gn = []) { + if (y(T), P.length + gn.length > 0) { + let We = s.getToken(); + for (; We !== 17; ) { + if (P.indexOf(We) !== -1) { + w(); + break; + } else if (gn.indexOf(We) !== -1) + break; + We = w(); + } + } + } + function N(T) { + const P = s.getTokenValue(); + return T ? g(P) : (h(P), i.push(P)), w(), !0; + } + function j() { + switch (s.getToken()) { + case 11: + const T = s.getTokenValue(); + let P = Number(T); + isNaN(P) && (k( + 2 + /* ParseErrorCode.InvalidNumberFormat */ + ), P = 0), g(P); + break; + case 7: + g(null); + break; + case 8: + g(!0); + break; + case 9: + g(!1); + break; + default: + return !1; + } + return w(), !0; + } + function D() { + return s.getToken() !== 10 ? (k(3, [], [ + 2, + 5 + /* SyntaxKind.CommaToken */ + ]), !1) : (N(!1), s.getToken() === 6 ? (S(":"), w(), he() || k(4, [], [ + 2, + 5 + /* SyntaxKind.CommaToken */ + ])) : k(5, [], [ + 2, + 5 + /* SyntaxKind.CommaToken */ + ]), i.pop(), !0); + } + function C() { + u(), w(); + let T = !1; + for (; s.getToken() !== 2 && s.getToken() !== 17; ) { + if (s.getToken() === 5) { + if (T || k(4, [], []), S(","), w(), s.getToken() === 2 && b) + break; + } else T && k(6, [], []); + D() || k(4, [], [ + 2, + 5 + /* SyntaxKind.CommaToken */ + ]), T = !0; + } + return p(), s.getToken() !== 2 ? k(7, [ + 2 + /* SyntaxKind.CloseBraceToken */ + ], []) : w(), !0; + } + function $() { + m(), w(); + let T = !0, P = !1; + for (; s.getToken() !== 4 && s.getToken() !== 17; ) { + if (s.getToken() === 5) { + if (P || k(4, [], []), S(","), w(), s.getToken() === 4 && b) + break; + } else P && k(6, [], []); + T ? (i.push(0), T = !1) : i[i.length - 1]++, he() || k(4, [], [ + 4, + 5 + /* SyntaxKind.CommaToken */ + ]), P = !0; + } + return d(), T || i.pop(), s.getToken() !== 4 ? k(8, [ + 4 + /* SyntaxKind.CloseBracketToken */ + ], []) : w(), !0; + } + function he() { + switch (s.getToken()) { + case 3: + return $(); + case 1: + return C(); + case 10: + return N(!0); + default: + return j(); + } + } + return w(), s.getToken() === 17 ? n.allowEmptyContent ? !0 : (k(4, [], []), !1) : he() ? (s.getToken() !== 17 && k(9, [], []), !0) : (k(4, [], []), !1); +} +function ur(e, t) { + let n = Lt(e), s = [], i, r = 0, o; + do + switch (o = n.getPosition(), i = n.scan(), i) { + case 12: + case 13: + case 17: + r !== o && s.push(e.substring(r, o)), t !== void 0 && s.push(n.getTokenValue().replace(/[^\r\n]/g, t)), r = n.getPosition(); + break; + } + while (i !== 17); + return s.join(""); +} +function Vs(e) { + switch (typeof e) { + case "boolean": + return "boolean"; + case "number": + return "number"; + case "string": + return "string"; + case "object": { + if (e) { + if (Array.isArray(e)) + return "array"; + } else return "null"; + return "object"; + } + default: + return "null"; + } +} +function hr(e, t, n, s) { + const i = t.slice(), o = qs(e, []); + let a, l; + for (; i.length > 0 && (l = i.pop(), a = Gt(o, i), a === void 0 && n !== void 0); ) + typeof l == "string" ? n = { [l]: n } : n = [n]; + if (a) + if (a.type === "object" && typeof l == "string" && Array.isArray(a.children)) { + const c = Gt(a, [l]); + if (c !== void 0) + if (n === void 0) { + if (!c.parent) + throw new Error("Malformed AST"); + const f = a.children.indexOf(c.parent); + let u, h = c.parent.offset + c.parent.length; + if (f > 0) { + let p = a.children[f - 1]; + u = p.offset + p.length; + } else + u = a.offset + 1, a.children.length > 1 && (h = a.children[1].offset); + return ie(e, { offset: u, length: h - u, content: "" }, s); + } else + return ie(e, { offset: c.offset, length: c.length, content: JSON.stringify(n) }, s); + else { + if (n === void 0) + return []; + const f = `${JSON.stringify(l)}: ${JSON.stringify(n)}`, u = s.getInsertionIndex ? s.getInsertionIndex(a.children.map((p) => p.children[0].value)) : a.children.length; + let h; + if (u > 0) { + let p = a.children[u - 1]; + h = { offset: p.offset + p.length, length: 0, content: "," + f }; + } else a.children.length === 0 ? h = { offset: a.offset + 1, length: 0, content: f } : h = { offset: a.offset + 1, length: 0, content: f + "," }; + return ie(e, h, s); + } + } else if (a.type === "array" && typeof l == "number" && Array.isArray(a.children)) { + const c = l; + if (c === -1) { + const f = `${JSON.stringify(n)}`; + let u; + if (a.children.length === 0) + u = { offset: a.offset + 1, length: 0, content: f }; + else { + const h = a.children[a.children.length - 1]; + u = { offset: h.offset + h.length, length: 0, content: "," + f }; + } + return ie(e, u, s); + } else if (n === void 0 && a.children.length >= 0) { + const f = l, u = a.children[f]; + let h; + if (a.children.length === 1) + h = { offset: a.offset + 1, length: a.length - 2, content: "" }; + else if (a.children.length - 1 === f) { + let p = a.children[f - 1], m = p.offset + p.length, d = a.offset + a.length; + h = { offset: m, length: d - 2 - m, content: "" }; + } else + h = { offset: u.offset, length: a.children[f + 1].offset - u.offset, content: "" }; + return ie(e, h, s); + } else if (n !== void 0) { + let f; + const u = `${JSON.stringify(n)}`; + if (!s.isArrayInsertion && a.children.length > l) { + const h = a.children[l]; + f = { offset: h.offset, length: h.length, content: u }; + } else if (a.children.length === 0 || l === 0) + f = { offset: a.offset + 1, length: 0, content: a.children.length === 0 ? u : u + "," }; + else { + const h = l > a.children.length ? a.children.length : l, p = a.children[h - 1]; + f = { offset: p.offset + p.length, length: 0, content: "," + u }; + } + return ie(e, f, s); + } else + throw new Error(`Can not ${n === void 0 ? "remove" : s.isArrayInsertion ? "insert" : "modify"} Array index ${c} as length is not sufficient`); + } else + throw new Error(`Can not add ${typeof l != "number" ? "index" : "property"} to parent of type ${a.type}`); + else { + if (n === void 0) + throw new Error("Can not delete in empty document"); + return ie(e, { offset: o ? o.offset : 0, length: o ? o.length : 0, content: JSON.stringify(n) }, s); + } +} +function ie(e, t, n) { + if (!n.formattingOptions) + return [t]; + let s = Qt(e, t), i = t.offset, r = t.offset + t.content.length; + if (t.length === 0 || t.content.length === 0) { + for (; i > 0 && !dt(s, i - 1); ) + i--; + for (; r < s.length && !dt(s, r); ) + r++; + } + const o = Ds(s, { offset: i, length: r - i }, { ...n.formattingOptions, keepLines: !1 }); + for (let l = o.length - 1; l >= 0; l--) { + const c = o[l]; + s = Qt(s, c), i = Math.min(i, c.offset), r = Math.max(r, c.offset + c.length), r += c.content.length - c.length; + } + const a = e.length - (s.length - r) - i; + return [{ offset: i, length: a, content: s.substring(i, r) }]; +} +function Qt(e, t) { + return e.substring(0, t.offset) + t.content + e.substring(t.offset + t.length); +} +const dr = Lt; +var Ht; +(function(e) { + e[e.None = 0] = "None", e[e.UnexpectedEndOfComment = 1] = "UnexpectedEndOfComment", e[e.UnexpectedEndOfString = 2] = "UnexpectedEndOfString", e[e.UnexpectedEndOfNumber = 3] = "UnexpectedEndOfNumber", e[e.InvalidUnicode = 4] = "InvalidUnicode", e[e.InvalidEscapeCharacter = 5] = "InvalidEscapeCharacter", e[e.InvalidCharacter = 6] = "InvalidCharacter"; +})(Ht || (Ht = {})); +var zt; +(function(e) { + e[e.OpenBraceToken = 1] = "OpenBraceToken", e[e.CloseBraceToken = 2] = "CloseBraceToken", e[e.OpenBracketToken = 3] = "OpenBracketToken", e[e.CloseBracketToken = 4] = "CloseBracketToken", e[e.CommaToken = 5] = "CommaToken", e[e.ColonToken = 6] = "ColonToken", e[e.NullKeyword = 7] = "NullKeyword", e[e.TrueKeyword = 8] = "TrueKeyword", e[e.FalseKeyword = 9] = "FalseKeyword", e[e.StringLiteral = 10] = "StringLiteral", e[e.NumericLiteral = 11] = "NumericLiteral", e[e.LineCommentTrivia = 12] = "LineCommentTrivia", e[e.BlockCommentTrivia = 13] = "BlockCommentTrivia", e[e.LineBreakTrivia = 14] = "LineBreakTrivia", e[e.Trivia = 15] = "Trivia", e[e.Unknown = 16] = "Unknown", e[e.EOF = 17] = "EOF"; +})(zt || (zt = {})); +const pr = ar, gr = cr, mr = qs, yr = Gt, br = Us, wr = Fs, kr = Wt, Sr = It, Or = ur; +var Xt; +(function(e) { + e[e.InvalidSymbol = 1] = "InvalidSymbol", e[e.InvalidNumberFormat = 2] = "InvalidNumberFormat", e[e.PropertyNameExpected = 3] = "PropertyNameExpected", e[e.ValueExpected = 4] = "ValueExpected", e[e.ColonExpected = 5] = "ColonExpected", e[e.CommaExpected = 6] = "CommaExpected", e[e.CloseBraceExpected = 7] = "CloseBraceExpected", e[e.CloseBracketExpected = 8] = "CloseBracketExpected", e[e.EndOfFileExpected = 9] = "EndOfFileExpected", e[e.InvalidCommentToken = 10] = "InvalidCommentToken", e[e.UnexpectedEndOfComment = 11] = "UnexpectedEndOfComment", e[e.UnexpectedEndOfString = 12] = "UnexpectedEndOfString", e[e.UnexpectedEndOfNumber = 13] = "UnexpectedEndOfNumber", e[e.InvalidUnicode = 14] = "InvalidUnicode", e[e.InvalidEscapeCharacter = 15] = "InvalidEscapeCharacter", e[e.InvalidCharacter = 16] = "InvalidCharacter"; +})(Xt || (Xt = {})); +function Ar(e) { + switch (e) { + case 1: + return "InvalidSymbol"; + case 2: + return "InvalidNumberFormat"; + case 3: + return "PropertyNameExpected"; + case 4: + return "ValueExpected"; + case 5: + return "ColonExpected"; + case 6: + return "CommaExpected"; + case 7: + return "CloseBraceExpected"; + case 8: + return "CloseBracketExpected"; + case 9: + return "EndOfFileExpected"; + case 10: + return "InvalidCommentToken"; + case 11: + return "UnexpectedEndOfComment"; + case 12: + return "UnexpectedEndOfString"; + case 13: + return "UnexpectedEndOfNumber"; + case 14: + return "InvalidUnicode"; + case 15: + return "InvalidEscapeCharacter"; + case 16: + return "InvalidCharacter"; + } + return ""; +} +function Nr(e, t, n) { + return Ds(e, t, n); +} +function vr(e, t, n, s) { + return hr(e, t, n, s); +} +function Tr(e, t) { + let n = t.slice(0).sort((i, r) => { + const o = i.offset - r.offset; + return o === 0 ? i.length - r.length : o; + }), s = e.length; + for (let i = n.length - 1; i >= 0; i--) { + let r = n[i]; + if (r.offset + r.length <= s) + e = Qt(e, r); + else + throw new Error("Overlapping edit"); + s = r.offset; + } + return e; +} +const Er = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ + __proto__: null, + get ParseErrorCode() { + return Xt; + }, + get ScanError() { + return Ht; + }, + get SyntaxKind() { + return zt; + }, + applyEdits: Tr, + createScanner: dr, + findNodeAtLocation: yr, + findNodeAtOffset: br, + format: Nr, + getLocation: pr, + getNodePath: wr, + getNodeValue: kr, + modify: vr, + parse: gr, + parseTree: mr, + printParseErrorCode: Ar, + stripComments: Or, + visit: Sr +}, Symbol.toStringTag, { value: "Module" })), Js = /* @__PURE__ */ Un(Er); +var Bn; +function Lr() { + if (Bn) return nt; + Bn = 1, Object.defineProperty(nt, "__esModule", { value: !0 }), nt.parseTree = i; + const e = Js; + var t; + (function(r) { + r.DEFAULT = { + allowTrailingComma: !1 + }; + })(t || (t = {})); + function n(r) { + switch (typeof r) { + case "boolean": + return "boolean"; + case "number": + return "number"; + case "string": + return "string"; + case "object": { + if (r) { + if (Array.isArray(r)) + return "array"; + } else return "null"; + return "object"; + } + default: + return "null"; + } + } + function s(r) { + const o = []; + for (let a = 0; a < r.length; a++) { + const l = r[a]; + if (l.type === "property") + for (let c = 0; c < r.length; c++) { + const f = r[c]; + f.type === "property" && l.children[0].value === f.children[0].value && a !== c && o.push(r[a].children[0]); + } + } + return o; + } + function i(r, o = [], a = t.DEFAULT) { + let l = { + type: "array", + offset: -1, + length: -1, + children: [], + parent: void 0 + }; + function c(p) { + l.type === "property" && (l.length = p - l.offset, l = l.parent); + } + function f(p) { + return l.children.push(p), p; + } + const u = { + onObjectBegin: (p) => { + l = f({ + type: "object", + offset: p, + length: -1, + parent: l, + children: [] + }); + }, + onObjectProperty: (p, m, d) => { + l = f({ + type: "property", + offset: m, + length: -1, + parent: l, + children: [] + }), l.children.push({ + type: "string", + value: p, + offset: m, + length: d, + parent: l + }); + }, + onObjectEnd: (p, m) => { + if (c(p + m), l.type === "object" && l.children && l.children.length > 1) { + const d = s(l.children); + for (const { offset: g, length: S } of d) + o.push({ + error: 0, + extendedError: 1, + offset: g, + length: S + }); + } + l.length = p + m - l.offset, l = l.parent, c(p + m); + }, + onArrayBegin: (p, m) => { + l = f({ + type: "array", + offset: p, + length: -1, + parent: l, + children: [] + }); + }, + onArrayEnd: (p, m) => { + l.length = p + m - l.offset, l = l.parent, c(p + m); + }, + onLiteralValue: (p, m, d) => { + f({ + type: n(p), + offset: m, + length: d, + parent: l, + value: p, + rawValue: r.substring(m, m + d) + }), c(m + d); + }, + onSeparator: (p, m, d) => { + l.type === "property" && (p === ":" ? l.colonOffset = m : p === "," && c(m)); + }, + onError: (p, m, d) => { + o.push({ error: p, offset: m, length: d }); + } + }; + (0, e.visit)(r, u, a); + const h = l.children[0]; + return h && delete h.parent, h; + } + return nt; +} +var st = {}, Mn; +function Ir() { + if (Mn) return st; + Mn = 1, Object.defineProperty(st, "__esModule", { value: !0 }), st.getCustomTags = s; + const e = pn; + class t { + constructor(r, o) { + this.tag = r, this.type = o; + } + resolve(r, o) { + if ((0, e.isMap)(r) && this.type === "mapping" || (0, e.isSeq)(r) && this.type === "sequence" || typeof r == "string" && this.type === "scalar") + return r; + o(`Unexpected type for tag ${this.tag}: ${typeof r}, expected ${this.type}`); + } + } + class n { + constructor() { + this.tag = "!include", this.type = "scalar"; + } + resolve(r, o) { + if (r && r.length > 0 && r.trim()) + return r; + o("!include without value"); + } + } + function s(i) { + const r = []; + for (const [o, a] of Object.entries(i)) + r.push(new t(o, a)); + return r.push(new n()), r; + } + return st; +} +var Rn; +function _r() { + if (Rn) return _e; + Rn = 1, Object.defineProperty(_e, "__esModule", { value: !0 }), _e.parseJson = l, _e.parseYaml = c; + const e = sr(), t = ir(), n = qe(), s = Lr(), i = Js, r = pn, o = Ir(); + function a(u) { + return u.extendedError ? u.extendedError === 1 ? "DuplicateKey" : "" : i.printParseErrorCode(u.error); + } + function l(u) { + const h = [], p = (0, s.parseTree)(u, h, { + disallowComments: !0, + allowTrailingComma: !1, + allowEmptyContent: !1 + }), m = h.map((d) => ({ + message: a(d), + offset: d.offset, + length: d.length + })); + return p ? [f(t.visitJson, void 0, p), m] : [void 0, m]; + } + function c(u, h) { + const p = r.parseAllDocuments(u, { + customTags: (0, o.getCustomTags)(h || {}) + }); + if (p.length !== 1) + return [void 0, []]; + const m = p[0], d = m.errors.map((S) => ({ + message: S.message, + offset: S.pos[0], + length: S.pos[1] - S.pos[0] + })); + return r.visit(m, { + Alias(S, A) { + A.resolve(m) || d.push({ + message: `Alias "${S}" could not be resolved`, + offset: A.range[0], + length: A.range[1] - A.range[0] + }); + } + }), [f(e.visitYaml, m, m.contents), d]; + } + function f(u, h, p) { + var m; + let d = {}; + const g = [d]; + if (u(h, null, "fakeroot", p, { + onObjectStart: (A, y, O, b) => { + b && (0, n.setPreservedLocation)(d, y, b), g.push(d), d = d[y] = {}; + }, + onObjectEnd: () => { + d = g.pop(); + }, + onArrayStart: (A, y, O, b) => { + b && (0, n.setPreservedLocation)(d, y, b), g.push(d), d = d[y] = []; + }, + onArrayEnd: () => { + d = g.pop(); + }, + onValue: (A, y, O, b, w) => { + d[y] = O, typeof O == "number" && b !== void 0 && (0, n.setPreservedValue)(d, y, b), w && (0, n.setPreservedLocation)(d, y, w); + } + }), typeof g[0].fakeroot != "object") + return; + const S = (m = (0, n.getPreservedLocation)(g[0], "fakeroot")) === null || m === void 0 ? void 0 : m.value; + return (0, n.setPreservedRootRange)(g[0].fakeroot, S), g[0].fakeroot; + } + return _e; +} +var it = {}, Kn; +function jr() { + if (Kn) return it; + Kn = 1, Object.defineProperty(it, "__esModule", { value: !0 }), it.stringify = t; + const e = Jn(); + function t(a, l = 0, c) { + return l === 0 ? n(a, c) : s(a, l, c); + } + function n(a, l) { + if (!a) + return JSON.stringify(a); + const c = []; + return (0, e.visitObject)(void 0, "fakeroot", a, { + onObjectStart: (f, u, h) => { + c.push(r(u, "{")); + }, + onObjectEnd: () => { + c[c.length - 1].endsWith(",") && i(c, 1), c.push("},"); + }, + onArrayStart: (f, u, h) => { + c.push(r(u, "[")); + }, + onArrayEnd: () => { + c[c.length - 1].endsWith(",") && i(c, 1), c.push("],"); + }, + onValue: (f, u, h, p) => { + p !== void 0 ? c.push(r(u, l ? l(h, p) : p) + ",") : c.push(r(u, JSON.stringify(h)) + ","); + } + }), c[0] = c[0].slice(11), i(c, 1), c.join(""); + } + function s(a, l, c) { + if (!a) + return JSON.stringify(a); + const f = []; + let u = 0; + const h = [!0]; + return (0, e.visitObject)(void 0, "fakeroot", a, { + onObjectStart: (p, m, d) => { + f.push(o(l, u) + r(m, `{ +`, !1)), h[h.length - 1] = !1, h.push(!0), u++; + }, + onObjectEnd: () => { + u--, h.pop() ? (i(f, 1), f.push(`}, +`)) : (i(f, 2), f.push(` +` + o(l, u) + `}, +`)); + }, + onArrayStart: (p, m, d) => { + f.push(o(l, u) + r(m, `[ +`, !1)), h[h.length - 1] = !1, h.push(!0), u++; + }, + onArrayEnd: () => { + u--, h.pop() ? (i(f, 1), f.push(`], +`)) : (i(f, 2), f.push(` +` + o(l, u) + `], +`)); + }, + onValue: (p, m, d, g) => { + h[h.length - 1] = !1, g !== void 0 ? f.push(o(l, u) + r(m, c ? c(d, g) : g, !1) + `, +`) : f.push(o(l, u) + r(m, JSON.stringify(d), !1) + `, +`); + } + }), f[0] = f[0].slice(12), i(f, 2), f.join(""); + } + function i(a, l) { + const c = a.length - 1; + a[c] = a[c].slice(0, -l); + } + function r(a, l, c = !0) { + const f = c ? ":" : ": "; + return typeof a == "string" ? JSON.stringify(a) + f + l : l; + } + function o(a, l) { + return " ".repeat(a * l); + } + return it; +} +var be = {}, re = {}, Dn; +function Ys() { + if (Dn) return re; + Dn = 1, Object.defineProperty(re, "__esModule", { value: !0 }), re.joinJsonPointer = s, re.parseJsonPointer = i, re.findByPath = r, re.find = o; + const e = /\//g, t = /~/g; + function n(a) { + return typeof a == "number" ? String(a) : a.replace(t, "~0").replace(e, "~1"); + } + function s(a) { + return a.length == 0 ? "" : "/" + a.map((l) => n(l)).join("/"); + } + function i(a) { + const l = /~/, c = /~[01]/g; + function f(h) { + switch (h) { + case "~1": + return "/"; + case "~0": + return "~"; + } + throw new Error("Invalid tilde escape: " + h); + } + function u(h) { + return l.test(h) ? h.replace(c, f) : h; + } + return a.split("/").slice(1).map(u).map(decodeURIComponent); + } + function r(a, l) { + let c = a; + for (const f of l) + if (typeof c == "object" && c !== null) + if (Array.isArray(c)) { + const u = typeof f == "string" ? parseInt(f, 10) : f; + if (isNaN(u)) + return; + c = c[u]; + } else if (c.hasOwnProperty(f)) + c = c[f]; + else + return; + else + return; + return c; + } + function o(a, l) { + return r(a, i(l)); + } + return re; +} +var qn; +function $r() { + if (qn) return be; + qn = 1, Object.defineProperty(be, "__esModule", { value: !0 }), be.findNodeAtOffset = s, be.findLocationForPath = r, be.findLocationForJsonPointer = o; + const e = qe(), t = Ys(); + function n(a, l) { + return l >= a.start && l <= a.end; + } + function s(a, l) { + const c = { value: (0, e.getPreservedRootRange)(a) }; + return i(a, l, [], c); + } + function i(a, l, c, f) { + const u = Array.isArray(a) ? a.keys() : Object.keys(a); + for (const h of u) { + const p = (0, e.getPreservedLocation)(a, h); + if (p && n(p.value, l)) { + const m = a[h]; + return c.push(h), m !== null && typeof m == "object" ? i(m, l, c, p) : [m, c, p]; + } + } + return [a, c, f]; + } + function r(a, l) { + if (l.length === 0) + return { value: (0, e.getPreservedRootRange)(a) }; + let c = a, f = 0; + for (; f < l.length - 1 && c; ) + c = c[l[f]], f++; + if (c) + return (0, e.getPreservedLocation)(c, l[f]); + } + function o(a, l) { + return r(a, (0, t.parseJsonPointer)(l)); + } + return be; +} +var Fn; +function Pr() { + return Fn || (Fn = 1, (function(e) { + Object.defineProperty(e, "__esModule", { value: !0 }), e.parseJsonPointer = e.joinJsonPointer = e.findLocationForPath = e.findByPath = e.findLocationForJsonPointer = e.find = e.findNodeAtOffset = e.getRootRange = e.getLocation = e.simpleClone = e.stringify = e.parseYaml = e.parseJson = void 0, e.parse = a; + const t = Xs(); + Object.defineProperty(e, "simpleClone", { enumerable: !0, get: function() { + return t.simpleClone; + } }); + const n = _r(); + Object.defineProperty(e, "parseJson", { enumerable: !0, get: function() { + return n.parseJson; + } }), Object.defineProperty(e, "parseYaml", { enumerable: !0, get: function() { + return n.parseYaml; + } }); + const s = jr(); + Object.defineProperty(e, "stringify", { enumerable: !0, get: function() { + return s.stringify; + } }); + const i = qe(); + Object.defineProperty(e, "getLocation", { enumerable: !0, get: function() { + return i.getPreservedLocation; + } }), Object.defineProperty(e, "getRootRange", { enumerable: !0, get: function() { + return i.getPreservedRootRange; + } }); + const r = $r(); + Object.defineProperty(e, "findLocationForJsonPointer", { enumerable: !0, get: function() { + return r.findLocationForJsonPointer; + } }), Object.defineProperty(e, "findLocationForPath", { enumerable: !0, get: function() { + return r.findLocationForPath; + } }), Object.defineProperty(e, "findNodeAtOffset", { enumerable: !0, get: function() { + return r.findNodeAtOffset; + } }); + const o = Ys(); + Object.defineProperty(e, "find", { enumerable: !0, get: function() { + return o.find; + } }), Object.defineProperty(e, "joinJsonPointer", { enumerable: !0, get: function() { + return o.joinJsonPointer; + } }), Object.defineProperty(e, "parseJsonPointer", { enumerable: !0, get: function() { + return o.parseJsonPointer; + } }), Object.defineProperty(e, "findByPath", { enumerable: !0, get: function() { + return o.findByPath; + } }); + function a(l, c, f) { + var u; + return c === "yaml" ? (0, n.parseYaml)(l, (u = f?.yaml) === null || u === void 0 ? void 0 : u.customTags) : (0, n.parseJson)(l); + } + })(_t)), _t; +} +var Vr = Pr(); +export { + Ur as H, + Mr as a, + Rr as b, + qr as c, + Fr as e, + Vr as l, + Kr as s, + Dr as u +}; diff --git a/openapi-plugin/resources/web/index.CRy0HWMP.js b/openapi-plugin/resources/web/index.CRy0HWMP.js deleted file mode 100644 index 0441d3d2..00000000 --- a/openapi-plugin/resources/web/index.CRy0HWMP.js +++ /dev/null @@ -1,7509 +0,0 @@ -import { c as Rs, u as Ds, b as xs, W as Oi } from "./TriangleExclamation.BLKAXJ8l.js"; -const qs = { - ready: !1, - data: { default: {}, secrets: {} } -}, Ii = Rs({ - name: "env", - initialState: qs, - reducers: { - loadEnv: (e, t) => { - t.payload.default && (e.data.default = t.payload.default), t.payload.secrets && (e.data.secrets = t.payload.secrets), e.ready = !0; - }, - saveEnv: (e, t) => { - e.data[t.payload.name] = t.payload.environment; - }, - showEnvWindow: (e, t) => { - } - } -}), { loadEnv: vo, saveEnv: $o, showEnvWindow: Po } = Ii.actions, jo = Ds, Fo = xs, Uo = Ii.reducer, Mo = [ - "get", - "put", - "post", - "delete", - "options", - "head", - "patch", - "trace" -]; -var nn = {}, gt = {}, yt = {}, oe = {}, ce = {}, Hn; -function Ks() { - return Hn || (Hn = 1, Object.defineProperty(ce, "__esModule", { value: !0 }), ce.preserveLocationKey = ce.preserveFormattingKey = ce.preserveRootRangeKey = void 0, ce.preserveRootRangeKey = /* @__PURE__ */ Symbol("preserve-root-location"), ce.preserveFormattingKey = /* @__PURE__ */ Symbol("preserve-formatting"), ce.preserveLocationKey = /* @__PURE__ */ Symbol("preserve-location")), ce; -} -var zn; -function ot() { - if (zn) return oe; - zn = 1, Object.defineProperty(oe, "__esModule", { value: !0 }), oe.getPreservedValue = t, oe.setPreservedValue = n, oe.getPreservedLocation = i, oe.setPreservedLocation = s, oe.getPreservedRootRange = r, oe.setPreservedRootRange = o, oe.copyPreservedValues = l; - const e = Ks(); - function t(f, u) { - var p; - return (p = f?.[e.preserveFormattingKey]) === null || p === void 0 ? void 0 : p[u]; - } - function n(f, u, p) { - f[e.preserveFormattingKey] === void 0 && Object.defineProperty(f, e.preserveFormattingKey, { enumerable: !1, value: {} }), f[e.preserveFormattingKey][u] = p; - } - function i(f, u) { - var p; - return (p = f?.[e.preserveLocationKey]) === null || p === void 0 ? void 0 : p[u]; - } - function s(f, u, p) { - f[e.preserveLocationKey] === void 0 && Object.defineProperty(f, e.preserveLocationKey, { enumerable: !1, value: {} }), f[e.preserveLocationKey][u] = p; - } - function r(f) { - return f[e.preserveRootRangeKey]; - } - function o(f, u) { - Object.defineProperty(f, e.preserveRootRangeKey, { enumerable: !1, value: u }); - } - function l(f, u) { - f && f[e.preserveFormattingKey] !== void 0 && Object.defineProperty(u, e.preserveFormattingKey, { - enumerable: !1, - value: f[e.preserveFormattingKey] - }); - } - return oe; -} -var Xn; -function Ti() { - if (Xn) return yt; - Xn = 1, Object.defineProperty(yt, "__esModule", { value: !0 }), yt.visitObject = t; - const e = ot(); - function t(i, s, r, o) { - const l = n(r); - if (l === "object") { - o.onObjectStart(i, s, r, (0, e.getPreservedLocation)(i, s)); - for (const f in r) - t(r, f, r[f], o); - o.onObjectEnd(); - } else l === "array" ? (o.onArrayStart(i, s, r, (0, e.getPreservedLocation)(i, s)), r.forEach((f, u) => { - t(r, u, f, o); - }), o.onArrayEnd()) : o.onValue(i, s, r, (0, e.getPreservedValue)(i, s), (0, e.getPreservedLocation)(i, s)); - } - function n(i) { - return typeof i == "object" ? i === null || i instanceof Number || i instanceof String || i instanceof Boolean ? "value" : i instanceof Array ? "array" : "object" : "value"; - } - return yt; -} -var Zn; -function Vs() { - if (Zn) return gt; - Zn = 1, Object.defineProperty(gt, "__esModule", { value: !0 }), gt.simpleClone = n; - const e = Ti(), t = ot(); - function n(i, s) { - let r = {}, o = []; - const l = [r]; - return (0, e.visitObject)(void 0, "fakeroot", i, { - onObjectStart: (f, u, p) => { - o.push(u), l.push(r), r = r[u] = {}, (0, t.copyPreservedValues)(p, r); - }, - onObjectEnd: () => { - o.pop(), r = l.pop(); - }, - onArrayStart: (f, u, p) => { - o.push(u), l.push(r), r = r[u] = [], (0, t.copyPreservedValues)(p, r); - }, - onArrayEnd: () => { - o.pop(), r = l.pop(); - }, - onValue: (f, u, p, g) => { - r[u] = s ? s(p, [...o.slice(1), u]) : p; - } - }), l[0].fakeroot; - } - return gt; -} -var He = {}, mt = {}; -const In = /* @__PURE__ */ Symbol.for("yaml.alias"), pn = /* @__PURE__ */ Symbol.for("yaml.document"), be = /* @__PURE__ */ Symbol.for("yaml.map"), Ni = /* @__PURE__ */ Symbol.for("yaml.pair"), ae = /* @__PURE__ */ Symbol.for("yaml.scalar"), Ge = /* @__PURE__ */ Symbol.for("yaml.seq"), te = /* @__PURE__ */ Symbol.for("yaml.node.type"), pe = (e) => !!e && typeof e == "object" && e[te] === In, we = (e) => !!e && typeof e == "object" && e[te] === pn, Te = (e) => !!e && typeof e == "object" && e[te] === be, R = (e) => !!e && typeof e == "object" && e[te] === Ni, F = (e) => !!e && typeof e == "object" && e[te] === ae, Ne = (e) => !!e && typeof e == "object" && e[te] === Ge; -function x(e) { - if (e && typeof e == "object") - switch (e[te]) { - case be: - case Ge: - return !0; - } - return !1; -} -function q(e) { - if (e && typeof e == "object") - switch (e[te]) { - case In: - case be: - case ae: - case Ge: - return !0; - } - return !1; -} -const Bi = (e) => (F(e) || x(e)) && !!e.anchor, z = /* @__PURE__ */ Symbol("break visit"), Li = /* @__PURE__ */ Symbol("skip children"), le = /* @__PURE__ */ Symbol("remove node"); -function ke(e, t) { - const n = _i(t); - we(e) ? Re(null, e.contents, n, Object.freeze([e])) === le && (e.contents = null) : Re(null, e, n, Object.freeze([])); -} -ke.BREAK = z; -ke.SKIP = Li; -ke.REMOVE = le; -function Re(e, t, n, i) { - const s = vi(e, t, n, i); - if (q(s) || R(s)) - return $i(e, i, s), Re(e, s, n, i); - if (typeof s != "symbol") { - if (x(t)) { - i = Object.freeze(i.concat(t)); - for (let r = 0; r < t.items.length; ++r) { - const o = Re(r, t.items[r], n, i); - if (typeof o == "number") - r = o - 1; - else { - if (o === z) - return z; - o === le && (t.items.splice(r, 1), r -= 1); - } - } - } else if (R(t)) { - i = Object.freeze(i.concat(t)); - const r = Re("key", t.key, n, i); - if (r === z) - return z; - r === le && (t.key = null); - const o = Re("value", t.value, n, i); - if (o === z) - return z; - o === le && (t.value = null); - } - } - return s; -} -async function lt(e, t) { - const n = _i(t); - we(e) ? await De(null, e.contents, n, Object.freeze([e])) === le && (e.contents = null) : await De(null, e, n, Object.freeze([])); -} -lt.BREAK = z; -lt.SKIP = Li; -lt.REMOVE = le; -async function De(e, t, n, i) { - const s = await vi(e, t, n, i); - if (q(s) || R(s)) - return $i(e, i, s), De(e, s, n, i); - if (typeof s != "symbol") { - if (x(t)) { - i = Object.freeze(i.concat(t)); - for (let r = 0; r < t.items.length; ++r) { - const o = await De(r, t.items[r], n, i); - if (typeof o == "number") - r = o - 1; - else { - if (o === z) - return z; - o === le && (t.items.splice(r, 1), r -= 1); - } - } - } else if (R(t)) { - i = Object.freeze(i.concat(t)); - const r = await De("key", t.key, n, i); - if (r === z) - return z; - r === le && (t.key = null); - const o = await De("value", t.value, n, i); - if (o === z) - return z; - o === le && (t.value = null); - } - } - return s; -} -function _i(e) { - return typeof e == "object" && (e.Collection || e.Node || e.Value) ? Object.assign({ - Alias: e.Node, - Map: e.Node, - Scalar: e.Node, - Seq: e.Node - }, e.Value && { - Map: e.Value, - Scalar: e.Value, - Seq: e.Value - }, e.Collection && { - Map: e.Collection, - Seq: e.Collection - }, e) : e; -} -function vi(e, t, n, i) { - if (typeof n == "function") - return n(e, t, i); - if (Te(t)) - return n.Map?.(e, t, i); - if (Ne(t)) - return n.Seq?.(e, t, i); - if (R(t)) - return n.Pair?.(e, t, i); - if (F(t)) - return n.Scalar?.(e, t, i); - if (pe(t)) - return n.Alias?.(e, t, i); -} -function $i(e, t, n) { - const i = t[t.length - 1]; - if (x(i)) - i.items[e] = n; - else if (R(i)) - e === "key" ? i.key = n : i.value = n; - else if (we(i)) - i.contents = n; - else { - const s = pe(i) ? "alias" : "scalar"; - throw new Error(`Cannot replace node with ${s} parent`); - } -} -const Js = { - "!": "%21", - ",": "%2C", - "[": "%5B", - "]": "%5D", - "{": "%7B", - "}": "%7D" -}, Ys = (e) => e.replace(/[!,[\]{}]/g, (t) => Js[t]); -class C { - constructor(t, n) { - this.docStart = null, this.docEnd = !1, this.yaml = Object.assign({}, C.defaultYaml, t), this.tags = Object.assign({}, C.defaultTags, n); - } - clone() { - const t = new C(this.yaml, this.tags); - return t.docStart = this.docStart, t; - } - /** - * During parsing, get a Directives instance for the current document and - * update the stream state according to the current version's spec. - */ - atDocument() { - const t = new C(this.yaml, this.tags); - switch (this.yaml.version) { - case "1.1": - this.atNextDocument = !0; - break; - case "1.2": - this.atNextDocument = !1, this.yaml = { - explicit: C.defaultYaml.explicit, - version: "1.2" - }, this.tags = Object.assign({}, C.defaultTags); - break; - } - return t; - } - /** - * @param onError - May be called even if the action was successful - * @returns `true` on success - */ - add(t, n) { - this.atNextDocument && (this.yaml = { explicit: C.defaultYaml.explicit, version: "1.1" }, this.tags = Object.assign({}, C.defaultTags), this.atNextDocument = !1); - const i = t.trim().split(/[ \t]+/), s = i.shift(); - switch (s) { - case "%TAG": { - if (i.length !== 2 && (n(0, "%TAG directive should contain exactly two parts"), i.length < 2)) - return !1; - const [r, o] = i; - return this.tags[r] = o, !0; - } - case "%YAML": { - if (this.yaml.explicit = !0, i.length !== 1) - return n(0, "%YAML directive should contain exactly one part"), !1; - const [r] = i; - if (r === "1.1" || r === "1.2") - return this.yaml.version = r, !0; - { - const o = /^\d+\.\d+$/.test(r); - return n(6, `Unsupported YAML version ${r}`, o), !1; - } - } - default: - return n(0, `Unknown directive ${s}`, !0), !1; - } - } - /** - * Resolves a tag, matching handles to those defined in %TAG directives. - * - * @returns Resolved tag, which may also be the non-specific tag `'!'` or a - * `'!local'` tag, or `null` if unresolvable. - */ - tagName(t, n) { - if (t === "!") - return "!"; - if (t[0] !== "!") - return n(`Not a valid tag: ${t}`), null; - if (t[1] === "<") { - const o = t.slice(2, -1); - return o === "!" || o === "!!" ? (n(`Verbatim tags aren't resolved, so ${t} is invalid.`), null) : (t[t.length - 1] !== ">" && n("Verbatim tags must end with a >"), o); - } - const [, i, s] = t.match(/^(.*!)([^!]*)$/s); - s || n(`The ${t} tag has no suffix`); - const r = this.tags[i]; - if (r) - try { - return r + decodeURIComponent(s); - } catch (o) { - return n(String(o)), null; - } - return i === "!" ? t : (n(`Could not resolve tag: ${t}`), null); - } - /** - * Given a fully resolved tag, returns its printable string form, - * taking into account current tag prefixes and defaults. - */ - tagString(t) { - for (const [n, i] of Object.entries(this.tags)) - if (t.startsWith(i)) - return n + Ys(t.substring(i.length)); - return t[0] === "!" ? t : `!<${t}>`; - } - toString(t) { - const n = this.yaml.explicit ? [`%YAML ${this.yaml.version || "1.2"}`] : [], i = Object.entries(this.tags); - let s; - if (t && i.length > 0 && q(t.contents)) { - const r = {}; - ke(t.contents, (o, l) => { - q(l) && l.tag && (r[l.tag] = !0); - }), s = Object.keys(r); - } else - s = []; - for (const [r, o] of i) - r === "!!" && o === "tag:yaml.org,2002:" || (!t || s.some((l) => l.startsWith(o))) && n.push(`%TAG ${r} ${o}`); - return n.join(` -`); - } -} -C.defaultYaml = { explicit: !1, version: "1.2" }; -C.defaultTags = { "!!": "tag:yaml.org,2002:" }; -function Pi(e) { - if (/[\x00-\x19\s,[\]{}]/.test(e)) { - const n = `Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`; - throw new Error(n); - } - return !0; -} -function ji(e) { - const t = /* @__PURE__ */ new Set(); - return ke(e, { - Value(n, i) { - i.anchor && t.add(i.anchor); - } - }), t; -} -function Fi(e, t) { - for (let n = 1; ; ++n) { - const i = `${e}${n}`; - if (!t.has(i)) - return i; - } -} -function Gs(e, t) { - const n = [], i = /* @__PURE__ */ new Map(); - let s = null; - return { - onAnchor: (r) => { - n.push(r), s ?? (s = ji(e)); - const o = Fi(t, s); - return s.add(o), o; - }, - /** - * With circular references, the source node is only resolved after all - * of its child nodes are. This is why anchors are set only after all of - * the nodes have been created. - */ - setAnchors: () => { - for (const r of n) { - const o = i.get(r); - if (typeof o == "object" && o.anchor && (F(o.node) || x(o.node))) - o.node.anchor = o.anchor; - else { - const l = new Error("Failed to resolve repeated object (this should not happen)"); - throw l.source = r, l; - } - } - }, - sourceObjects: i - }; -} -function xe(e, t, n, i) { - if (i && typeof i == "object") - if (Array.isArray(i)) - for (let s = 0, r = i.length; s < r; ++s) { - const o = i[s], l = xe(e, i, String(s), o); - l === void 0 ? delete i[s] : l !== o && (i[s] = l); - } - else if (i instanceof Map) - for (const s of Array.from(i.keys())) { - const r = i.get(s), o = xe(e, i, s, r); - o === void 0 ? i.delete(s) : o !== r && i.set(s, o); - } - else if (i instanceof Set) - for (const s of Array.from(i)) { - const r = xe(e, i, s, s); - r === void 0 ? i.delete(s) : r !== s && (i.delete(s), i.add(r)); - } - else - for (const [s, r] of Object.entries(i)) { - const o = xe(e, i, s, r); - o === void 0 ? delete i[s] : o !== r && (i[s] = o); - } - return e.call(t, n, i); -} -function ee(e, t, n) { - if (Array.isArray(e)) - return e.map((i, s) => ee(i, String(s), n)); - if (e && typeof e.toJSON == "function") { - if (!n || !Bi(e)) - return e.toJSON(t, n); - const i = { aliasCount: 0, count: 1, res: void 0 }; - n.anchors.set(e, i), n.onCreate = (r) => { - i.res = r, delete n.onCreate; - }; - const s = e.toJSON(t, n); - return n.onCreate && n.onCreate(s), s; - } - return typeof e == "bigint" && !n?.keep ? Number(e) : e; -} -class Tn { - constructor(t) { - Object.defineProperty(this, te, { value: t }); - } - /** Create a copy of this node. */ - clone() { - const t = Object.create(Object.getPrototypeOf(this), Object.getOwnPropertyDescriptors(this)); - return this.range && (t.range = this.range.slice()), t; - } - /** A plain JavaScript representation of this node. */ - toJS(t, { mapAsMap: n, maxAliasCount: i, onAnchor: s, reviver: r } = {}) { - if (!we(t)) - throw new TypeError("A document argument is required"); - const o = { - anchors: /* @__PURE__ */ new Map(), - doc: t, - keep: !0, - mapAsMap: n === !0, - mapKeyWarned: !1, - maxAliasCount: typeof i == "number" ? i : 100 - }, l = ee(this, "", o); - if (typeof s == "function") - for (const { count: f, res: u } of o.anchors.values()) - s(u, f); - return typeof r == "function" ? xe(r, { "": l }, "", l) : l; - } -} -class at extends Tn { - constructor(t) { - super(In), this.source = t, Object.defineProperty(this, "tag", { - set() { - throw new Error("Alias nodes cannot have tags"); - } - }); - } - /** - * Resolve the value of this alias within `doc`, finding the last - * instance of the `source` anchor before this node. - */ - resolve(t, n) { - let i; - n?.aliasResolveCache ? i = n.aliasResolveCache : (i = [], ke(t, { - Node: (r, o) => { - (pe(o) || Bi(o)) && i.push(o); - } - }), n && (n.aliasResolveCache = i)); - let s; - for (const r of i) { - if (r === this) - break; - r.anchor === this.source && (s = r); - } - return s; - } - toJSON(t, n) { - if (!n) - return { source: this.source }; - const { anchors: i, doc: s, maxAliasCount: r } = n, o = this.resolve(s, n); - if (!o) { - const f = `Unresolved alias (the anchor must be set before the alias): ${this.source}`; - throw new ReferenceError(f); - } - let l = i.get(o); - if (l || (ee(o, null, n), l = i.get(o)), !l || l.res === void 0) { - const f = "This should not happen: Alias anchor was not resolved?"; - throw new ReferenceError(f); - } - if (r >= 0 && (l.count += 1, l.aliasCount === 0 && (l.aliasCount = Bt(s, o, i)), l.count * l.aliasCount > r)) { - const f = "Excessive alias count indicates a resource exhaustion attack"; - throw new ReferenceError(f); - } - return l.res; - } - toString(t, n, i) { - const s = `*${this.source}`; - if (t) { - if (Pi(this.source), t.options.verifyAliasOrder && !t.anchors.has(this.source)) { - const r = `Unresolved alias (the anchor must be set before the alias): ${this.source}`; - throw new Error(r); - } - if (t.implicitKey) - return `${s} `; - } - return s; - } -} -function Bt(e, t, n) { - if (pe(t)) { - const i = t.resolve(e), s = n && i && n.get(i); - return s ? s.count * s.aliasCount : 0; - } else if (x(t)) { - let i = 0; - for (const s of t.items) { - const r = Bt(e, s, n); - r > i && (i = r); - } - return i; - } else if (R(t)) { - const i = Bt(e, t.key, n), s = Bt(e, t.value, n); - return Math.max(i, s); - } - return 1; -} -const Ui = (e) => !e || typeof e != "function" && typeof e != "object"; -class $ extends Tn { - constructor(t) { - super(ae), this.value = t; - } - toJSON(t, n) { - return n?.keep ? this.value : ee(this.value, t, n); - } - toString() { - return String(this.value); - } -} -$.BLOCK_FOLDED = "BLOCK_FOLDED"; -$.BLOCK_LITERAL = "BLOCK_LITERAL"; -$.PLAIN = "PLAIN"; -$.QUOTE_DOUBLE = "QUOTE_DOUBLE"; -$.QUOTE_SINGLE = "QUOTE_SINGLE"; -const Ws = "tag:yaml.org,2002:"; -function Cs(e, t, n) { - if (t) { - const i = n.filter((r) => r.tag === t), s = i.find((r) => !r.format) ?? i[0]; - if (!s) - throw new Error(`Tag ${t} not found`); - return s; - } - return n.find((i) => i.identify?.(e) && !i.format); -} -function nt(e, t, n) { - if (we(e) && (e = e.contents), q(e)) - return e; - if (R(e)) { - const g = n.schema[be].createNode?.(n.schema, null, n); - return g.items.push(e), g; - } - (e instanceof String || e instanceof Number || e instanceof Boolean || typeof BigInt < "u" && e instanceof BigInt) && (e = e.valueOf()); - const { aliasDuplicateObjects: i, onAnchor: s, onTagObj: r, schema: o, sourceObjects: l } = n; - let f; - if (i && e && typeof e == "object") { - if (f = l.get(e), f) - return f.anchor ?? (f.anchor = s(e)), new at(f.anchor); - f = { anchor: null, node: null }, l.set(e, f); - } - t?.startsWith("!!") && (t = Ws + t.slice(2)); - let u = Cs(e, t, o.tags); - if (!u) { - if (e && typeof e.toJSON == "function" && (e = e.toJSON()), !e || typeof e != "object") { - const g = new $(e); - return f && (f.node = g), g; - } - u = e instanceof Map ? o[be] : Symbol.iterator in Object(e) ? o[Ge] : o[be]; - } - r && (r(u), delete n.onTagObj); - const p = u?.createNode ? u.createNode(n.schema, e, n) : typeof u?.nodeClass?.from == "function" ? u.nodeClass.from(n.schema, e, n) : new $(e); - return t ? p.tag = t : u.default || (p.tag = u.tag), f && (f.node = p), p; -} -function $t(e, t, n) { - let i = n; - for (let s = t.length - 1; s >= 0; --s) { - const r = t[s]; - if (typeof r == "number" && Number.isInteger(r) && r >= 0) { - const o = []; - o[r] = i, i = o; - } else - i = /* @__PURE__ */ new Map([[r, i]]); - } - return nt(i, void 0, { - aliasDuplicateObjects: !1, - keepUndefined: !1, - onAnchor: () => { - throw new Error("This should not happen, please report a bug."); - }, - schema: e, - sourceObjects: /* @__PURE__ */ new Map() - }); -} -const et = (e) => e == null || typeof e == "object" && !!e[Symbol.iterator]().next().done; -class Mi extends Tn { - constructor(t, n) { - super(t), Object.defineProperty(this, "schema", { - value: n, - configurable: !0, - enumerable: !1, - writable: !0 - }); - } - /** - * Create a copy of this collection. - * - * @param schema - If defined, overwrites the original's schema - */ - clone(t) { - const n = Object.create(Object.getPrototypeOf(this), Object.getOwnPropertyDescriptors(this)); - return t && (n.schema = t), n.items = n.items.map((i) => q(i) || R(i) ? i.clone(t) : i), this.range && (n.range = this.range.slice()), n; - } - /** - * Adds a value to the collection. For `!!map` and `!!omap` the value must - * be a Pair instance or a `{ key, value }` object, which may not have a key - * that already exists in the map. - */ - addIn(t, n) { - if (et(t)) - this.add(n); - else { - const [i, ...s] = t, r = this.get(i, !0); - if (x(r)) - r.addIn(s, n); - else if (r === void 0 && this.schema) - this.set(i, $t(this.schema, s, n)); - else - throw new Error(`Expected YAML collection at ${i}. Remaining path: ${s}`); - } - } - /** - * Removes a value from the collection. - * @returns `true` if the item was found and removed. - */ - deleteIn(t) { - const [n, ...i] = t; - if (i.length === 0) - return this.delete(n); - const s = this.get(n, !0); - if (x(s)) - return s.deleteIn(i); - throw new Error(`Expected YAML collection at ${n}. Remaining path: ${i}`); - } - /** - * Returns item at `key`, or `undefined` if not found. By default unwraps - * scalar values from their surrounding node; to disable set `keepScalar` to - * `true` (collections are always returned intact). - */ - getIn(t, n) { - const [i, ...s] = t, r = this.get(i, !0); - return s.length === 0 ? !n && F(r) ? r.value : r : x(r) ? r.getIn(s, n) : void 0; - } - hasAllNullValues(t) { - return this.items.every((n) => { - if (!R(n)) - return !1; - const i = n.value; - return i == null || t && F(i) && i.value == null && !i.commentBefore && !i.comment && !i.tag; - }); - } - /** - * Checks if the collection includes a value with the key `key`. - */ - hasIn(t) { - const [n, ...i] = t; - if (i.length === 0) - return this.has(n); - const s = this.get(n, !0); - return x(s) ? s.hasIn(i) : !1; - } - /** - * Sets a value in this collection. For `!!set`, `value` needs to be a - * boolean to add/remove the item from the set. - */ - setIn(t, n) { - const [i, ...s] = t; - if (s.length === 0) - this.set(i, n); - else { - const r = this.get(i, !0); - if (x(r)) - r.setIn(s, n); - else if (r === void 0 && this.schema) - this.set(i, $t(this.schema, s, n)); - else - throw new Error(`Expected YAML collection at ${i}. Remaining path: ${s}`); - } - } -} -const Qs = (e) => e.replace(/^(?!$)(?: $)?/gm, "#"); -function fe(e, t) { - return /^\n+$/.test(e) ? e.substring(1) : t ? e.replace(/^(?! *$)/gm, t) : e; -} -const Ae = (e, t, n) => e.endsWith(` -`) ? fe(n, t) : n.includes(` -`) ? ` -` + fe(n, t) : (e.endsWith(" ") ? "" : " ") + n, Ri = "flow", dn = "block", Lt = "quoted"; -function Mt(e, t, n = "flow", { indentAtStart: i, lineWidth: s = 80, minContentWidth: r = 20, onFold: o, onOverflow: l } = {}) { - if (!s || s < 0) - return e; - s < r && (r = 0); - const f = Math.max(1 + r, 1 + s - t.length); - if (e.length <= f) - return e; - const u = [], p = {}; - let g = s - t.length; - typeof i == "number" && (i > s - Math.max(2, r) ? u.push(0) : g = s - i); - let y, m, k = !1, b = -1, E = -1, B = -1; - n === dn && (b = ei(e, b, t.length), b !== -1 && (g = b + f)); - for (let A; A = e[b += 1]; ) { - if (n === Lt && A === "\\") { - switch (E = b, e[b + 1]) { - case "x": - b += 3; - break; - case "u": - b += 5; - break; - case "U": - b += 9; - break; - default: - b += 1; - } - B = b; - } - if (A === ` -`) - n === dn && (b = ei(e, b, t.length)), g = b + t.length + f, y = void 0; - else { - if (A === " " && m && m !== " " && m !== ` -` && m !== " ") { - const _ = e[b + 1]; - _ && _ !== " " && _ !== ` -` && _ !== " " && (y = b); - } - if (b >= g) - if (y) - u.push(y), g = y + f, y = void 0; - else if (n === Lt) { - for (; m === " " || m === " "; ) - m = A, A = e[b += 1], k = !0; - const _ = b > B + 1 ? b - 2 : E - 1; - if (p[_]) - return e; - u.push(_), p[_] = !0, g = _ + f, y = void 0; - } else - k = !0; - } - m = A; - } - if (k && l && l(), u.length === 0) - return e; - o && o(); - let L = e.slice(0, u[0]); - for (let A = 0; A < u.length; ++A) { - const _ = u[A], O = u[A + 1] || e.length; - _ === 0 ? L = ` -${t}${e.slice(0, O)}` : (n === Lt && p[_] && (L += `${e[_]}\\`), L += ` -${t}${e.slice(_ + 1, O)}`); - } - return L; -} -function ei(e, t, n) { - let i = t, s = t + 1, r = e[s]; - for (; r === " " || r === " "; ) - if (t < s + n) - r = e[++t]; - else { - do - r = e[++t]; - while (r && r !== ` -`); - i = t, s = t + 1, r = e[s]; - } - return i; -} -const Rt = (e, t) => ({ - indentAtStart: t ? e.indent.length : e.indentAtStart, - lineWidth: e.options.lineWidth, - minContentWidth: e.options.minContentWidth -}), Dt = (e) => /^(%|---|\.\.\.)/m.test(e); -function Hs(e, t, n) { - if (!t || t < 0) - return !1; - const i = t - n, s = e.length; - if (s <= i) - return !1; - for (let r = 0, o = 0; r < s; ++r) - if (e[r] === ` -`) { - if (r - o > i) - return !0; - if (o = r + 1, s - o <= i) - return !1; - } - return !0; -} -function tt(e, t) { - const n = JSON.stringify(e); - if (t.options.doubleQuotedAsJSON) - return n; - const { implicitKey: i } = t, s = t.options.doubleQuotedMinMultiLineLength, r = t.indent || (Dt(e) ? " " : ""); - let o = "", l = 0; - for (let f = 0, u = n[f]; u; u = n[++f]) - if (u === " " && n[f + 1] === "\\" && n[f + 2] === "n" && (o += n.slice(l, f) + "\\ ", f += 1, l = f, u = "\\"), u === "\\") - switch (n[f + 1]) { - case "u": - { - o += n.slice(l, f); - const p = n.substr(f + 2, 4); - switch (p) { - case "0000": - o += "\\0"; - break; - case "0007": - o += "\\a"; - break; - case "000b": - o += "\\v"; - break; - case "001b": - o += "\\e"; - break; - case "0085": - o += "\\N"; - break; - case "00a0": - o += "\\_"; - break; - case "2028": - o += "\\L"; - break; - case "2029": - o += "\\P"; - break; - default: - p.substr(0, 2) === "00" ? o += "\\x" + p.substr(2) : o += n.substr(f, 6); - } - f += 5, l = f + 1; - } - break; - case "n": - if (i || n[f + 2] === '"' || n.length < s) - f += 1; - else { - for (o += n.slice(l, f) + ` - -`; n[f + 2] === "\\" && n[f + 3] === "n" && n[f + 4] !== '"'; ) - o += ` -`, f += 2; - o += r, n[f + 2] === " " && (o += "\\"), f += 1, l = f + 1; - } - break; - default: - f += 1; - } - return o = l ? o + n.slice(l) : n, i ? o : Mt(o, r, Lt, Rt(t, !1)); -} -function gn(e, t) { - if (t.options.singleQuote === !1 || t.implicitKey && e.includes(` -`) || /[ \t]\n|\n[ \t]/.test(e)) - return tt(e, t); - const n = t.indent || (Dt(e) ? " " : ""), i = "'" + e.replace(/'/g, "''").replace(/\n+/g, `$& -${n}`) + "'"; - return t.implicitKey ? i : Mt(i, n, Ri, Rt(t, !1)); -} -function qe(e, t) { - const { singleQuote: n } = t.options; - let i; - if (n === !1) - i = tt; - else { - const s = e.includes('"'), r = e.includes("'"); - s && !r ? i = gn : r && !s ? i = tt : i = n ? gn : tt; - } - return i(e, t); -} -let yn; -try { - yn = new RegExp(`(^|(? -`; - let g, y; - for (y = n.length; y > 0; --y) { - const O = n[y - 1]; - if (O !== ` -` && O !== " " && O !== " ") - break; - } - let m = n.substring(y); - const k = m.indexOf(` -`); - k === -1 ? g = "-" : n === m || k !== m.length - 1 ? (g = "+", r && r()) : g = "", m && (n = n.slice(0, -m.length), m[m.length - 1] === ` -` && (m = m.slice(0, -1)), m = m.replace(yn, `$&${u}`)); - let b = !1, E, B = -1; - for (E = 0; E < n.length; ++E) { - const O = n[E]; - if (O === " ") - b = !0; - else if (O === ` -`) - B = E; - else - break; - } - let L = n.substring(0, B < E ? B + 1 : E); - L && (n = n.substring(L.length), L = L.replace(/\n+/g, `$&${u}`)); - let _ = (b ? u ? "2" : "1" : "") + g; - if (e && (_ += " " + l(e.replace(/ ?[\r\n]+/g, " ")), s && s()), !p) { - const O = n.replace(/\n+/g, ` -$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${u}`); - let T = !1; - const N = Rt(i, !0); - o !== "folded" && t !== $.BLOCK_FOLDED && (N.onOverflow = () => { - T = !0; - }); - const v = Mt(`${L}${O}${m}`, u, dn, N); - if (!T) - return `>${_} -${u}${v}`; - } - return n = n.replace(/\n+/g, `$&${u}`), `|${_} -${u}${L}${n}${m}`; -} -function zs(e, t, n, i) { - const { type: s, value: r } = e, { actualString: o, implicitKey: l, indent: f, indentStep: u, inFlow: p } = t; - if (l && r.includes(` -`) || p && /[[\]{},]/.test(r)) - return qe(r, t); - if (/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(r)) - return l || p || !r.includes(` -`) ? qe(r, t) : _t(e, t, n, i); - if (!l && !p && s !== $.PLAIN && r.includes(` -`)) - return _t(e, t, n, i); - if (Dt(r)) { - if (f === "") - return t.forceBlockIndent = !0, _t(e, t, n, i); - if (l && f === u) - return qe(r, t); - } - const g = r.replace(/\n+/g, `$& -${f}`); - if (o) { - const y = (b) => b.default && b.tag !== "tag:yaml.org,2002:str" && b.test?.test(g), { compat: m, tags: k } = t.doc.schema; - if (k.some(y) || m?.some(y)) - return qe(r, t); - } - return l ? g : Mt(g, f, Ri, Rt(t, !1)); -} -function ct(e, t, n, i) { - const { implicitKey: s, inFlow: r } = t, o = typeof e.value == "string" ? e : Object.assign({}, e, { value: String(e.value) }); - let { type: l } = e; - l !== $.QUOTE_DOUBLE && /[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value) && (l = $.QUOTE_DOUBLE); - const f = (p) => { - switch (p) { - case $.BLOCK_FOLDED: - case $.BLOCK_LITERAL: - return s || r ? qe(o.value, t) : _t(o, t, n, i); - case $.QUOTE_DOUBLE: - return tt(o.value, t); - case $.QUOTE_SINGLE: - return gn(o.value, t); - case $.PLAIN: - return zs(o, t, n, i); - default: - return null; - } - }; - let u = f(l); - if (u === null) { - const { defaultKeyType: p, defaultStringType: g } = t.options, y = s && p || g; - if (u = f(y), u === null) - throw new Error(`Unsupported default string type ${y}`); - } - return u; -} -function Di(e, t) { - const n = Object.assign({ - blockQuote: !0, - commentString: Qs, - defaultKeyType: null, - defaultStringType: "PLAIN", - directives: null, - doubleQuotedAsJSON: !1, - doubleQuotedMinMultiLineLength: 40, - falseStr: "false", - flowCollectionPadding: !0, - indentSeq: !0, - lineWidth: 80, - minContentWidth: 20, - nullStr: "null", - simpleKeys: !1, - singleQuote: null, - trueStr: "true", - verifyAliasOrder: !0 - }, e.schema.toStringOptions, t); - let i; - switch (n.collectionStyle) { - case "block": - i = !1; - break; - case "flow": - i = !0; - break; - default: - i = null; - } - return { - anchors: /* @__PURE__ */ new Set(), - doc: e, - flowCollectionPadding: n.flowCollectionPadding ? " " : "", - indent: "", - indentStep: typeof n.indent == "number" ? " ".repeat(n.indent) : " ", - inFlow: i, - options: n - }; -} -function Xs(e, t) { - if (t.tag) { - const s = e.filter((r) => r.tag === t.tag); - if (s.length > 0) - return s.find((r) => r.format === t.format) ?? s[0]; - } - let n, i; - if (F(t)) { - i = t.value; - let s = e.filter((r) => r.identify?.(i)); - if (s.length > 1) { - const r = s.filter((o) => o.test); - r.length > 0 && (s = r); - } - n = s.find((r) => r.format === t.format) ?? s.find((r) => !r.format); - } else - i = t, n = e.find((s) => s.nodeClass && i instanceof s.nodeClass); - if (!n) { - const s = i?.constructor?.name ?? (i === null ? "null" : typeof i); - throw new Error(`Tag not resolved for ${s} value`); - } - return n; -} -function Zs(e, t, { anchors: n, doc: i }) { - if (!i.directives) - return ""; - const s = [], r = (F(e) || x(e)) && e.anchor; - r && Pi(r) && (n.add(r), s.push(`&${r}`)); - const o = e.tag ?? (t.default ? null : t.tag); - return o && s.push(i.directives.tagString(o)), s.join(" "); -} -function Je(e, t, n, i) { - if (R(e)) - return e.toString(t, n, i); - if (pe(e)) { - if (t.doc.directives) - return e.toString(t); - if (t.resolvedAliases?.has(e)) - throw new TypeError("Cannot stringify circular structure without alias nodes"); - t.resolvedAliases ? t.resolvedAliases.add(e) : t.resolvedAliases = /* @__PURE__ */ new Set([e]), e = e.resolve(t.doc); - } - let s; - const r = q(e) ? e : t.doc.createNode(e, { onTagObj: (f) => s = f }); - s ?? (s = Xs(t.doc.schema.tags, r)); - const o = Zs(r, s, t); - o.length > 0 && (t.indentAtStart = (t.indentAtStart ?? 0) + o.length + 1); - const l = typeof s.stringify == "function" ? s.stringify(r, t, n, i) : F(r) ? ct(r, t, n, i) : r.toString(t, n, i); - return o ? F(r) || l[0] === "{" || l[0] === "[" ? `${o} ${l}` : `${o} -${t.indent}${l}` : l; -} -function er({ key: e, value: t }, n, i, s) { - const { allNullValues: r, doc: o, indent: l, indentStep: f, options: { commentString: u, indentSeq: p, simpleKeys: g } } = n; - let y = q(e) && e.comment || null; - if (g) { - if (y) - throw new Error("With simple keys, key nodes cannot have comments"); - if (x(e) || !q(e) && typeof e == "object") { - const N = "With simple keys, collection cannot be used as a key value"; - throw new Error(N); - } - } - let m = !g && (!e || y && t == null && !n.inFlow || x(e) || (F(e) ? e.type === $.BLOCK_FOLDED || e.type === $.BLOCK_LITERAL : typeof e == "object")); - n = Object.assign({}, n, { - allNullValues: !1, - implicitKey: !m && (g || !r), - indent: l + f - }); - let k = !1, b = !1, E = Je(e, n, () => k = !0, () => b = !0); - if (!m && !n.inFlow && E.length > 1024) { - if (g) - throw new Error("With simple keys, single line scalar must not span more than 1024 characters"); - m = !0; - } - if (n.inFlow) { - if (r || t == null) - return k && i && i(), E === "" ? "?" : m ? `? ${E}` : E; - } else if (r && !g || t == null && m) - return E = `? ${E}`, y && !k ? E += Ae(E, n.indent, u(y)) : b && s && s(), E; - k && (y = null), m ? (y && (E += Ae(E, n.indent, u(y))), E = `? ${E} -${l}:`) : (E = `${E}:`, y && (E += Ae(E, n.indent, u(y)))); - let B, L, A; - q(t) ? (B = !!t.spaceBefore, L = t.commentBefore, A = t.comment) : (B = !1, L = null, A = null, t && typeof t == "object" && (t = o.createNode(t))), n.implicitKey = !1, !m && !y && F(t) && (n.indentAtStart = E.length + 1), b = !1, !p && f.length >= 2 && !n.inFlow && !m && Ne(t) && !t.flow && !t.tag && !t.anchor && (n.indent = n.indent.substring(2)); - let _ = !1; - const O = Je(t, n, () => _ = !0, () => b = !0); - let T = " "; - if (y || B || L) { - if (T = B ? ` -` : "", L) { - const N = u(L); - T += ` -${fe(N, n.indent)}`; - } - O === "" && !n.inFlow ? T === ` -` && (T = ` - -`) : T += ` -${n.indent}`; - } else if (!m && x(t)) { - const N = O[0], v = O.indexOf(` -`), M = v !== -1, Q = n.inFlow ?? t.flow ?? t.items.length === 0; - if (M || !Q) { - let se = !1; - if (M && (N === "&" || N === "!")) { - let K = O.indexOf(" "); - N === "&" && K !== -1 && K < v && O[K + 1] === "!" && (K = O.indexOf(" ", K + 1)), (K === -1 || v < K) && (se = !0); - } - se || (T = ` -${n.indent}`); - } - } else (O === "" || O[0] === ` -`) && (T = ""); - return E += T + O, n.inFlow ? _ && i && i() : A && !_ ? E += Ae(E, n.indent, u(A)) : b && s && s(), E; -} -function xi(e, t) { - (e === "debug" || e === "warn") && console.warn(t); -} -const bt = "<<", ue = { - identify: (e) => e === bt || typeof e == "symbol" && e.description === bt, - default: "key", - tag: "tag:yaml.org,2002:merge", - test: /^<<$/, - resolve: () => Object.assign(new $(Symbol(bt)), { - addToJSMap: qi - }), - stringify: () => bt -}, tr = (e, t) => (ue.identify(t) || F(t) && (!t.type || t.type === $.PLAIN) && ue.identify(t.value)) && e?.doc.schema.tags.some((n) => n.tag === ue.tag && n.default); -function qi(e, t, n) { - if (n = e && pe(n) ? n.resolve(e.doc) : n, Ne(n)) - for (const i of n.items) - sn(e, t, i); - else if (Array.isArray(n)) - for (const i of n) - sn(e, t, i); - else - sn(e, t, n); -} -function sn(e, t, n) { - const i = e && pe(n) ? n.resolve(e.doc) : n; - if (!Te(i)) - throw new Error("Merge sources must be maps or map aliases"); - const s = i.toJSON(null, e, Map); - for (const [r, o] of s) - t instanceof Map ? t.has(r) || t.set(r, o) : t instanceof Set ? t.add(r) : Object.prototype.hasOwnProperty.call(t, r) || Object.defineProperty(t, r, { - value: o, - writable: !0, - enumerable: !0, - configurable: !0 - }); - return t; -} -function Ki(e, t, { key: n, value: i }) { - if (q(n) && n.addToJSMap) - n.addToJSMap(e, t, i); - else if (tr(e, n)) - qi(e, t, i); - else { - const s = ee(n, "", e); - if (t instanceof Map) - t.set(s, ee(i, s, e)); - else if (t instanceof Set) - t.add(s); - else { - const r = nr(n, s, e), o = ee(i, r, e); - r in t ? Object.defineProperty(t, r, { - value: o, - writable: !0, - enumerable: !0, - configurable: !0 - }) : t[r] = o; - } - } - return t; -} -function nr(e, t, n) { - if (t === null) - return ""; - if (typeof t != "object") - return String(t); - if (q(e) && n?.doc) { - const i = Di(n.doc, {}); - i.anchors = /* @__PURE__ */ new Set(); - for (const r of n.anchors.keys()) - i.anchors.add(r.anchor); - i.inFlow = !0, i.inStringifyKey = !0; - const s = e.toString(i); - if (!n.mapKeyWarned) { - let r = JSON.stringify(s); - r.length > 40 && (r = r.substring(0, 36) + '..."'), xi(n.doc.options.logLevel, `Keys with collection values will be stringified due to JS Object restrictions: ${r}. Set mapAsMap: true to use object keys.`), n.mapKeyWarned = !0; - } - return s; - } - return JSON.stringify(t); -} -function Nn(e, t, n) { - const i = nt(e, void 0, n), s = nt(t, void 0, n); - return new W(i, s); -} -class W { - constructor(t, n = null) { - Object.defineProperty(this, te, { value: Ni }), this.key = t, this.value = n; - } - clone(t) { - let { key: n, value: i } = this; - return q(n) && (n = n.clone(t)), q(i) && (i = i.clone(t)), new W(n, i); - } - toJSON(t, n) { - const i = n?.mapAsMap ? /* @__PURE__ */ new Map() : {}; - return Ki(n, i, this); - } - toString(t, n, i) { - return t?.doc ? er(this, t, n, i) : JSON.stringify(this); - } -} -function Vi(e, t, n) { - return (t.inFlow ?? e.flow ? sr : ir)(e, t, n); -} -function ir({ comment: e, items: t }, n, { blockItemPrefix: i, flowChars: s, itemIndent: r, onChompKeep: o, onComment: l }) { - const { indent: f, options: { commentString: u } } = n, p = Object.assign({}, n, { indent: r, type: null }); - let g = !1; - const y = []; - for (let k = 0; k < t.length; ++k) { - const b = t[k]; - let E = null; - if (q(b)) - !g && b.spaceBefore && y.push(""), Pt(n, y, b.commentBefore, g), b.comment && (E = b.comment); - else if (R(b)) { - const L = q(b.key) ? b.key : null; - L && (!g && L.spaceBefore && y.push(""), Pt(n, y, L.commentBefore, g)); - } - g = !1; - let B = Je(b, p, () => E = null, () => g = !0); - E && (B += Ae(B, r, u(E))), g && E && (g = !1), y.push(i + B); - } - let m; - if (y.length === 0) - m = s.start + s.end; - else { - m = y[0]; - for (let k = 1; k < y.length; ++k) { - const b = y[k]; - m += b ? ` -${f}${b}` : ` -`; - } - } - return e ? (m += ` -` + fe(u(e), f), l && l()) : g && o && o(), m; -} -function sr({ items: e }, t, { flowChars: n, itemIndent: i }) { - const { indent: s, indentStep: r, flowCollectionPadding: o, options: { commentString: l } } = t; - i += r; - const f = Object.assign({}, t, { - indent: i, - inFlow: !0, - type: null - }); - let u = !1, p = 0; - const g = []; - for (let k = 0; k < e.length; ++k) { - const b = e[k]; - let E = null; - if (q(b)) - b.spaceBefore && g.push(""), Pt(t, g, b.commentBefore, !1), b.comment && (E = b.comment); - else if (R(b)) { - const L = q(b.key) ? b.key : null; - L && (L.spaceBefore && g.push(""), Pt(t, g, L.commentBefore, !1), L.comment && (u = !0)); - const A = q(b.value) ? b.value : null; - A ? (A.comment && (E = A.comment), A.commentBefore && (u = !0)) : b.value == null && L?.comment && (E = L.comment); - } - E && (u = !0); - let B = Je(b, f, () => E = null); - k < e.length - 1 && (B += ","), E && (B += Ae(B, i, l(E))), !u && (g.length > p || B.includes(` -`)) && (u = !0), g.push(B), p = g.length; - } - const { start: y, end: m } = n; - if (g.length === 0) - return y + m; - if (!u) { - const k = g.reduce((b, E) => b + E.length + 2, 2); - u = t.options.lineWidth > 0 && k > t.options.lineWidth; - } - if (u) { - let k = y; - for (const b of g) - k += b ? ` -${r}${s}${b}` : ` -`; - return `${k} -${s}${m}`; - } else - return `${y}${o}${g.join(" ")}${o}${m}`; -} -function Pt({ indent: e, options: { commentString: t } }, n, i, s) { - if (i && s && (i = i.replace(/^\n+/, "")), i) { - const r = fe(t(i), e); - n.push(r.trimStart()); - } -} -function Oe(e, t) { - const n = F(t) ? t.value : t; - for (const i of e) - if (R(i) && (i.key === t || i.key === n || F(i.key) && i.key.value === n)) - return i; -} -class X extends Mi { - static get tagName() { - return "tag:yaml.org,2002:map"; - } - constructor(t) { - super(be, t), this.items = []; - } - /** - * A generic collection parsing method that can be extended - * to other node classes that inherit from YAMLMap - */ - static from(t, n, i) { - const { keepUndefined: s, replacer: r } = i, o = new this(t), l = (f, u) => { - if (typeof r == "function") - u = r.call(n, f, u); - else if (Array.isArray(r) && !r.includes(f)) - return; - (u !== void 0 || s) && o.items.push(Nn(f, u, i)); - }; - if (n instanceof Map) - for (const [f, u] of n) - l(f, u); - else if (n && typeof n == "object") - for (const f of Object.keys(n)) - l(f, n[f]); - return typeof t.sortMapEntries == "function" && o.items.sort(t.sortMapEntries), o; - } - /** - * Adds a value to the collection. - * - * @param overwrite - If not set `true`, using a key that is already in the - * collection will throw. Otherwise, overwrites the previous value. - */ - add(t, n) { - let i; - R(t) ? i = t : !t || typeof t != "object" || !("key" in t) ? i = new W(t, t?.value) : i = new W(t.key, t.value); - const s = Oe(this.items, i.key), r = this.schema?.sortMapEntries; - if (s) { - if (!n) - throw new Error(`Key ${i.key} already set`); - F(s.value) && Ui(i.value) ? s.value.value = i.value : s.value = i.value; - } else if (r) { - const o = this.items.findIndex((l) => r(i, l) < 0); - o === -1 ? this.items.push(i) : this.items.splice(o, 0, i); - } else - this.items.push(i); - } - delete(t) { - const n = Oe(this.items, t); - return n ? this.items.splice(this.items.indexOf(n), 1).length > 0 : !1; - } - get(t, n) { - const s = Oe(this.items, t)?.value; - return (!n && F(s) ? s.value : s) ?? void 0; - } - has(t) { - return !!Oe(this.items, t); - } - set(t, n) { - this.add(new W(t, n), !0); - } - /** - * @param ctx - Conversion context, originally set in Document#toJS() - * @param {Class} Type - If set, forces the returned collection type - * @returns Instance of Type, Map, or Object - */ - toJSON(t, n, i) { - const s = i ? new i() : n?.mapAsMap ? /* @__PURE__ */ new Map() : {}; - n?.onCreate && n.onCreate(s); - for (const r of this.items) - Ki(n, s, r); - return s; - } - toString(t, n, i) { - if (!t) - return JSON.stringify(this); - for (const s of this.items) - if (!R(s)) - throw new Error(`Map items must all be pairs; found ${JSON.stringify(s)} instead`); - return !t.allNullValues && this.hasAllNullValues(!1) && (t = Object.assign({}, t, { allNullValues: !0 })), Vi(this, t, { - blockItemPrefix: "", - flowChars: { start: "{", end: "}" }, - itemIndent: t.indent || "", - onChompKeep: i, - onComment: n - }); - } -} -const We = { - collection: "map", - default: !0, - nodeClass: X, - tag: "tag:yaml.org,2002:map", - resolve(e, t) { - return Te(e) || t("Expected a mapping for this tag"), e; - }, - createNode: (e, t, n) => X.from(e, t, n) -}; -class he extends Mi { - static get tagName() { - return "tag:yaml.org,2002:seq"; - } - constructor(t) { - super(Ge, t), this.items = []; - } - add(t) { - this.items.push(t); - } - /** - * Removes a value from the collection. - * - * `key` must contain a representation of an integer for this to succeed. - * It may be wrapped in a `Scalar`. - * - * @returns `true` if the item was found and removed. - */ - delete(t) { - const n = wt(t); - return typeof n != "number" ? !1 : this.items.splice(n, 1).length > 0; - } - get(t, n) { - const i = wt(t); - if (typeof i != "number") - return; - const s = this.items[i]; - return !n && F(s) ? s.value : s; - } - /** - * Checks if the collection includes a value with the key `key`. - * - * `key` must contain a representation of an integer for this to succeed. - * It may be wrapped in a `Scalar`. - */ - has(t) { - const n = wt(t); - return typeof n == "number" && n < this.items.length; - } - /** - * Sets a value in this collection. For `!!set`, `value` needs to be a - * boolean to add/remove the item from the set. - * - * If `key` does not contain a representation of an integer, this will throw. - * It may be wrapped in a `Scalar`. - */ - set(t, n) { - const i = wt(t); - if (typeof i != "number") - throw new Error(`Expected a valid index, not ${t}.`); - const s = this.items[i]; - F(s) && Ui(n) ? s.value = n : this.items[i] = n; - } - toJSON(t, n) { - const i = []; - n?.onCreate && n.onCreate(i); - let s = 0; - for (const r of this.items) - i.push(ee(r, String(s++), n)); - return i; - } - toString(t, n, i) { - return t ? Vi(this, t, { - blockItemPrefix: "- ", - flowChars: { start: "[", end: "]" }, - itemIndent: (t.indent || "") + " ", - onChompKeep: i, - onComment: n - }) : JSON.stringify(this); - } - static from(t, n, i) { - const { replacer: s } = i, r = new this(t); - if (n && Symbol.iterator in Object(n)) { - let o = 0; - for (let l of n) { - if (typeof s == "function") { - const f = n instanceof Set ? l : String(o++); - l = s.call(n, f, l); - } - r.items.push(nt(l, void 0, i)); - } - } - return r; - } -} -function wt(e) { - let t = F(e) ? e.value : e; - return t && typeof t == "string" && (t = Number(t)), typeof t == "number" && Number.isInteger(t) && t >= 0 ? t : null; -} -const Ce = { - collection: "seq", - default: !0, - nodeClass: he, - tag: "tag:yaml.org,2002:seq", - resolve(e, t) { - return Ne(e) || t("Expected a sequence for this tag"), e; - }, - createNode: (e, t, n) => he.from(e, t, n) -}, xt = { - identify: (e) => typeof e == "string", - default: !0, - tag: "tag:yaml.org,2002:str", - resolve: (e) => e, - stringify(e, t, n, i) { - return t = Object.assign({ actualString: !0 }, t), ct(e, t, n, i); - } -}, qt = { - identify: (e) => e == null, - createNode: () => new $(null), - default: !0, - tag: "tag:yaml.org,2002:null", - test: /^(?:~|[Nn]ull|NULL)?$/, - resolve: () => new $(null), - stringify: ({ source: e }, t) => typeof e == "string" && qt.test.test(e) ? e : t.options.nullStr -}, Bn = { - identify: (e) => typeof e == "boolean", - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/, - resolve: (e) => new $(e[0] === "t" || e[0] === "T"), - stringify({ source: e, value: t }, n) { - if (e && Bn.test.test(e)) { - const i = e[0] === "t" || e[0] === "T"; - if (t === i) - return e; - } - return t ? n.options.trueStr : n.options.falseStr; - } -}; -function ie({ format: e, minFractionDigits: t, tag: n, value: i }) { - if (typeof i == "bigint") - return String(i); - const s = typeof i == "number" ? i : Number(i); - if (!isFinite(s)) - return isNaN(s) ? ".nan" : s < 0 ? "-.inf" : ".inf"; - let r = JSON.stringify(i); - if (!e && t && (!n || n === "tag:yaml.org,2002:float") && /^\d/.test(r)) { - let o = r.indexOf("."); - o < 0 && (o = r.length, r += "."); - let l = t - (r.length - o - 1); - for (; l-- > 0; ) - r += "0"; - } - return r; -} -const Ji = { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/, - resolve: (e) => e.slice(-3).toLowerCase() === "nan" ? NaN : e[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, - stringify: ie -}, Yi = { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - format: "EXP", - test: /^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/, - resolve: (e) => parseFloat(e), - stringify(e) { - const t = Number(e.value); - return isFinite(t) ? t.toExponential() : ie(e); - } -}, Gi = { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/, - resolve(e) { - const t = new $(parseFloat(e)), n = e.indexOf("."); - return n !== -1 && e[e.length - 1] === "0" && (t.minFractionDigits = e.length - n - 1), t; - }, - stringify: ie -}, Kt = (e) => typeof e == "bigint" || Number.isInteger(e), Ln = (e, t, n, { intAsBigInt: i }) => i ? BigInt(e) : parseInt(e.substring(t), n); -function Wi(e, t, n) { - const { value: i } = e; - return Kt(i) && i >= 0 ? n + i.toString(t) : ie(e); -} -const Ci = { - identify: (e) => Kt(e) && e >= 0, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "OCT", - test: /^0o[0-7]+$/, - resolve: (e, t, n) => Ln(e, 2, 8, n), - stringify: (e) => Wi(e, 8, "0o") -}, Qi = { - identify: Kt, - default: !0, - tag: "tag:yaml.org,2002:int", - test: /^[-+]?[0-9]+$/, - resolve: (e, t, n) => Ln(e, 0, 10, n), - stringify: ie -}, Hi = { - identify: (e) => Kt(e) && e >= 0, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "HEX", - test: /^0x[0-9a-fA-F]+$/, - resolve: (e, t, n) => Ln(e, 2, 16, n), - stringify: (e) => Wi(e, 16, "0x") -}, rr = [ - We, - Ce, - xt, - qt, - Bn, - Ci, - Qi, - Hi, - Ji, - Yi, - Gi -]; -function ti(e) { - return typeof e == "bigint" || Number.isInteger(e); -} -const kt = ({ value: e }) => JSON.stringify(e), or = [ - { - identify: (e) => typeof e == "string", - default: !0, - tag: "tag:yaml.org,2002:str", - resolve: (e) => e, - stringify: kt - }, - { - identify: (e) => e == null, - createNode: () => new $(null), - default: !0, - tag: "tag:yaml.org,2002:null", - test: /^null$/, - resolve: () => null, - stringify: kt - }, - { - identify: (e) => typeof e == "boolean", - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^true$|^false$/, - resolve: (e) => e === "true", - stringify: kt - }, - { - identify: ti, - default: !0, - tag: "tag:yaml.org,2002:int", - test: /^-?(?:0|[1-9][0-9]*)$/, - resolve: (e, t, { intAsBigInt: n }) => n ? BigInt(e) : parseInt(e, 10), - stringify: ({ value: e }) => ti(e) ? e.toString() : JSON.stringify(e) - }, - { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/, - resolve: (e) => parseFloat(e), - stringify: kt - } -], lr = { - default: !0, - tag: "", - test: /^/, - resolve(e, t) { - return t(`Unresolved plain scalar ${JSON.stringify(e)}`), e; - } -}, ar = [We, Ce].concat(or, lr), _n = { - identify: (e) => e instanceof Uint8Array, - // Buffer inherits from Uint8Array - default: !1, - tag: "tag:yaml.org,2002:binary", - /** - * Returns a Buffer in node and an Uint8Array in browsers - * - * To use the resulting buffer as an image, you'll want to do something like: - * - * const blob = new Blob([buffer], { type: 'image/jpeg' }) - * document.querySelector('#photo').src = URL.createObjectURL(blob) - */ - resolve(e, t) { - if (typeof atob == "function") { - const n = atob(e.replace(/[\n\r]/g, "")), i = new Uint8Array(n.length); - for (let s = 0; s < n.length; ++s) - i[s] = n.charCodeAt(s); - return i; - } else - return t("This environment does not support reading binary tags; either Buffer or atob is required"), e; - }, - stringify({ comment: e, type: t, value: n }, i, s, r) { - if (!n) - return ""; - const o = n; - let l; - if (typeof btoa == "function") { - let f = ""; - for (let u = 0; u < o.length; ++u) - f += String.fromCharCode(o[u]); - l = btoa(f); - } else - throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required"); - if (t ?? (t = $.BLOCK_LITERAL), t !== $.QUOTE_DOUBLE) { - const f = Math.max(i.options.lineWidth - i.indent.length, i.options.minContentWidth), u = Math.ceil(l.length / f), p = new Array(u); - for (let g = 0, y = 0; g < u; ++g, y += f) - p[g] = l.substr(y, f); - l = p.join(t === $.BLOCK_LITERAL ? ` -` : " "); - } - return ct({ comment: e, type: t, value: l }, i, s, r); - } -}; -function zi(e, t) { - if (Ne(e)) - for (let n = 0; n < e.items.length; ++n) { - let i = e.items[n]; - if (!R(i)) { - if (Te(i)) { - i.items.length > 1 && t("Each pair must have its own sequence indicator"); - const s = i.items[0] || new W(new $(null)); - if (i.commentBefore && (s.key.commentBefore = s.key.commentBefore ? `${i.commentBefore} -${s.key.commentBefore}` : i.commentBefore), i.comment) { - const r = s.value ?? s.key; - r.comment = r.comment ? `${i.comment} -${r.comment}` : i.comment; - } - i = s; - } - e.items[n] = R(i) ? i : new W(i); - } - } - else - t("Expected a sequence for this tag"); - return e; -} -function Xi(e, t, n) { - const { replacer: i } = n, s = new he(e); - s.tag = "tag:yaml.org,2002:pairs"; - let r = 0; - if (t && Symbol.iterator in Object(t)) - for (let o of t) { - typeof i == "function" && (o = i.call(t, String(r++), o)); - let l, f; - if (Array.isArray(o)) - if (o.length === 2) - l = o[0], f = o[1]; - else - throw new TypeError(`Expected [key, value] tuple: ${o}`); - else if (o && o instanceof Object) { - const u = Object.keys(o); - if (u.length === 1) - l = u[0], f = o[l]; - else - throw new TypeError(`Expected tuple with one key, not ${u.length} keys`); - } else - l = o; - s.items.push(Nn(l, f, n)); - } - return s; -} -const vn = { - collection: "seq", - default: !1, - tag: "tag:yaml.org,2002:pairs", - resolve: zi, - createNode: Xi -}; -class Ke extends he { - constructor() { - super(), this.add = X.prototype.add.bind(this), this.delete = X.prototype.delete.bind(this), this.get = X.prototype.get.bind(this), this.has = X.prototype.has.bind(this), this.set = X.prototype.set.bind(this), this.tag = Ke.tag; - } - /** - * If `ctx` is given, the return type is actually `Map`, - * but TypeScript won't allow widening the signature of a child method. - */ - toJSON(t, n) { - if (!n) - return super.toJSON(t); - const i = /* @__PURE__ */ new Map(); - n?.onCreate && n.onCreate(i); - for (const s of this.items) { - let r, o; - if (R(s) ? (r = ee(s.key, "", n), o = ee(s.value, r, n)) : r = ee(s, "", n), i.has(r)) - throw new Error("Ordered maps must not include duplicate keys"); - i.set(r, o); - } - return i; - } - static from(t, n, i) { - const s = Xi(t, n, i), r = new this(); - return r.items = s.items, r; - } -} -Ke.tag = "tag:yaml.org,2002:omap"; -const $n = { - collection: "seq", - identify: (e) => e instanceof Map, - nodeClass: Ke, - default: !1, - tag: "tag:yaml.org,2002:omap", - resolve(e, t) { - const n = zi(e, t), i = []; - for (const { key: s } of n.items) - F(s) && (i.includes(s.value) ? t(`Ordered maps must not include duplicate keys: ${s.value}`) : i.push(s.value)); - return Object.assign(new Ke(), n); - }, - createNode: (e, t, n) => Ke.from(e, t, n) -}; -function Zi({ value: e, source: t }, n) { - return t && (e ? es : ts).test.test(t) ? t : e ? n.options.trueStr : n.options.falseStr; -} -const es = { - identify: (e) => e === !0, - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/, - resolve: () => new $(!0), - stringify: Zi -}, ts = { - identify: (e) => e === !1, - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/, - resolve: () => new $(!1), - stringify: Zi -}, cr = { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/, - resolve: (e) => e.slice(-3).toLowerCase() === "nan" ? NaN : e[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, - stringify: ie -}, fr = { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - format: "EXP", - test: /^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/, - resolve: (e) => parseFloat(e.replace(/_/g, "")), - stringify(e) { - const t = Number(e.value); - return isFinite(t) ? t.toExponential() : ie(e); - } -}, ur = { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/, - resolve(e) { - const t = new $(parseFloat(e.replace(/_/g, ""))), n = e.indexOf("."); - if (n !== -1) { - const i = e.substring(n + 1).replace(/_/g, ""); - i[i.length - 1] === "0" && (t.minFractionDigits = i.length); - } - return t; - }, - stringify: ie -}, ft = (e) => typeof e == "bigint" || Number.isInteger(e); -function Vt(e, t, n, { intAsBigInt: i }) { - const s = e[0]; - if ((s === "-" || s === "+") && (t += 1), e = e.substring(t).replace(/_/g, ""), i) { - switch (n) { - case 2: - e = `0b${e}`; - break; - case 8: - e = `0o${e}`; - break; - case 16: - e = `0x${e}`; - break; - } - const o = BigInt(e); - return s === "-" ? BigInt(-1) * o : o; - } - const r = parseInt(e, n); - return s === "-" ? -1 * r : r; -} -function Pn(e, t, n) { - const { value: i } = e; - if (ft(i)) { - const s = i.toString(t); - return i < 0 ? "-" + n + s.substr(1) : n + s; - } - return ie(e); -} -const hr = { - identify: ft, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "BIN", - test: /^[-+]?0b[0-1_]+$/, - resolve: (e, t, n) => Vt(e, 2, 2, n), - stringify: (e) => Pn(e, 2, "0b") -}, pr = { - identify: ft, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "OCT", - test: /^[-+]?0[0-7_]+$/, - resolve: (e, t, n) => Vt(e, 1, 8, n), - stringify: (e) => Pn(e, 8, "0") -}, dr = { - identify: ft, - default: !0, - tag: "tag:yaml.org,2002:int", - test: /^[-+]?[0-9][0-9_]*$/, - resolve: (e, t, n) => Vt(e, 0, 10, n), - stringify: ie -}, gr = { - identify: ft, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "HEX", - test: /^[-+]?0x[0-9a-fA-F_]+$/, - resolve: (e, t, n) => Vt(e, 2, 16, n), - stringify: (e) => Pn(e, 16, "0x") -}; -class Ve extends X { - constructor(t) { - super(t), this.tag = Ve.tag; - } - add(t) { - let n; - R(t) ? n = t : t && typeof t == "object" && "key" in t && "value" in t && t.value === null ? n = new W(t.key, null) : n = new W(t, null), Oe(this.items, n.key) || this.items.push(n); - } - /** - * If `keepPair` is `true`, returns the Pair matching `key`. - * Otherwise, returns the value of that Pair's key. - */ - get(t, n) { - const i = Oe(this.items, t); - return !n && R(i) ? F(i.key) ? i.key.value : i.key : i; - } - set(t, n) { - if (typeof n != "boolean") - throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof n}`); - const i = Oe(this.items, t); - i && !n ? this.items.splice(this.items.indexOf(i), 1) : !i && n && this.items.push(new W(t)); - } - toJSON(t, n) { - return super.toJSON(t, n, Set); - } - toString(t, n, i) { - if (!t) - return JSON.stringify(this); - if (this.hasAllNullValues(!0)) - return super.toString(Object.assign({}, t, { allNullValues: !0 }), n, i); - throw new Error("Set items must all have null values"); - } - static from(t, n, i) { - const { replacer: s } = i, r = new this(t); - if (n && Symbol.iterator in Object(n)) - for (let o of n) - typeof s == "function" && (o = s.call(n, o, o)), r.items.push(Nn(o, null, i)); - return r; - } -} -Ve.tag = "tag:yaml.org,2002:set"; -const jn = { - collection: "map", - identify: (e) => e instanceof Set, - nodeClass: Ve, - default: !1, - tag: "tag:yaml.org,2002:set", - createNode: (e, t, n) => Ve.from(e, t, n), - resolve(e, t) { - if (Te(e)) { - if (e.hasAllNullValues(!0)) - return Object.assign(new Ve(), e); - t("Set items must all have null values"); - } else - t("Expected a mapping for this tag"); - return e; - } -}; -function Fn(e, t) { - const n = e[0], i = n === "-" || n === "+" ? e.substring(1) : e, s = (o) => t ? BigInt(o) : Number(o), r = i.replace(/_/g, "").split(":").reduce((o, l) => o * s(60) + s(l), s(0)); - return n === "-" ? s(-1) * r : r; -} -function ns(e) { - let { value: t } = e, n = (o) => o; - if (typeof t == "bigint") - n = (o) => BigInt(o); - else if (isNaN(t) || !isFinite(t)) - return ie(e); - let i = ""; - t < 0 && (i = "-", t *= n(-1)); - const s = n(60), r = [t % s]; - return t < 60 ? r.unshift(0) : (t = (t - r[0]) / s, r.unshift(t % s), t >= 60 && (t = (t - r[0]) / s, r.unshift(t))), i + r.map((o) => String(o).padStart(2, "0")).join(":").replace(/000000\d*$/, ""); -} -const is = { - identify: (e) => typeof e == "bigint" || Number.isInteger(e), - default: !0, - tag: "tag:yaml.org,2002:int", - format: "TIME", - test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/, - resolve: (e, t, { intAsBigInt: n }) => Fn(e, n), - stringify: ns -}, ss = { - identify: (e) => typeof e == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - format: "TIME", - test: /^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/, - resolve: (e) => Fn(e, !1), - stringify: ns -}, Jt = { - identify: (e) => e instanceof Date, - default: !0, - tag: "tag:yaml.org,2002:timestamp", - // If the time zone is omitted, the timestamp is assumed to be specified in UTC. The time part - // may be omitted altogether, resulting in a date format. In such a case, the time part is - // assumed to be 00:00:00Z (start of day, UTC). - test: RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"), - resolve(e) { - const t = e.match(Jt.test); - if (!t) - throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd"); - const [, n, i, s, r, o, l] = t.map(Number), f = t[7] ? Number((t[7] + "00").substr(1, 3)) : 0; - let u = Date.UTC(n, i - 1, s, r || 0, o || 0, l || 0, f); - const p = t[8]; - if (p && p !== "Z") { - let g = Fn(p, !1); - Math.abs(g) < 30 && (g *= 60), u -= 6e4 * g; - } - return new Date(u); - }, - stringify: ({ value: e }) => e?.toISOString().replace(/(T00:00:00)?\.000Z$/, "") ?? "" -}, ni = [ - We, - Ce, - xt, - qt, - es, - ts, - hr, - pr, - dr, - gr, - cr, - fr, - ur, - _n, - ue, - $n, - vn, - jn, - is, - ss, - Jt -], ii = /* @__PURE__ */ new Map([ - ["core", rr], - ["failsafe", [We, Ce, xt]], - ["json", ar], - ["yaml11", ni], - ["yaml-1.1", ni] -]), si = { - binary: _n, - bool: Bn, - float: Gi, - floatExp: Yi, - floatNaN: Ji, - floatTime: ss, - int: Qi, - intHex: Hi, - intOct: Ci, - intTime: is, - map: We, - merge: ue, - null: qt, - omap: $n, - pairs: vn, - seq: Ce, - set: jn, - timestamp: Jt -}, yr = { - "tag:yaml.org,2002:binary": _n, - "tag:yaml.org,2002:merge": ue, - "tag:yaml.org,2002:omap": $n, - "tag:yaml.org,2002:pairs": vn, - "tag:yaml.org,2002:set": jn, - "tag:yaml.org,2002:timestamp": Jt -}; -function rn(e, t, n) { - const i = ii.get(t); - if (i && !e) - return n && !i.includes(ue) ? i.concat(ue) : i.slice(); - let s = i; - if (!s) - if (Array.isArray(e)) - s = []; - else { - const r = Array.from(ii.keys()).filter((o) => o !== "yaml11").map((o) => JSON.stringify(o)).join(", "); - throw new Error(`Unknown schema "${t}"; use one of ${r} or define customTags array`); - } - if (Array.isArray(e)) - for (const r of e) - s = s.concat(r); - else typeof e == "function" && (s = e(s.slice())); - return n && (s = s.concat(ue)), s.reduce((r, o) => { - const l = typeof o == "string" ? si[o] : o; - if (!l) { - const f = JSON.stringify(o), u = Object.keys(si).map((p) => JSON.stringify(p)).join(", "); - throw new Error(`Unknown custom tag ${f}; use one of ${u}`); - } - return r.includes(l) || r.push(l), r; - }, []); -} -const mr = (e, t) => e.key < t.key ? -1 : e.key > t.key ? 1 : 0; -class ut { - constructor({ compat: t, customTags: n, merge: i, resolveKnownTags: s, schema: r, sortMapEntries: o, toStringDefaults: l }) { - this.compat = Array.isArray(t) ? rn(t, "compat") : t ? rn(null, t) : null, this.name = typeof r == "string" && r || "core", this.knownTags = s ? yr : {}, this.tags = rn(n, this.name, i), this.toStringOptions = l ?? null, Object.defineProperty(this, be, { value: We }), Object.defineProperty(this, ae, { value: xt }), Object.defineProperty(this, Ge, { value: Ce }), this.sortMapEntries = typeof o == "function" ? o : o === !0 ? mr : null; - } - clone() { - const t = Object.create(ut.prototype, Object.getOwnPropertyDescriptors(this)); - return t.tags = this.tags.slice(), t; - } -} -function br(e, t) { - const n = []; - let i = t.directives === !0; - if (t.directives !== !1 && e.directives) { - const f = e.directives.toString(e); - f ? (n.push(f), i = !0) : e.directives.docStart && (i = !0); - } - i && n.push("---"); - const s = Di(e, t), { commentString: r } = s.options; - if (e.commentBefore) { - n.length !== 1 && n.unshift(""); - const f = r(e.commentBefore); - n.unshift(fe(f, "")); - } - let o = !1, l = null; - if (e.contents) { - if (q(e.contents)) { - if (e.contents.spaceBefore && i && n.push(""), e.contents.commentBefore) { - const p = r(e.contents.commentBefore); - n.push(fe(p, "")); - } - s.forceBlockIndent = !!e.comment, l = e.contents.comment; - } - const f = l ? void 0 : () => o = !0; - let u = Je(e.contents, s, () => l = null, f); - l && (u += Ae(u, "", r(l))), (u[0] === "|" || u[0] === ">") && n[n.length - 1] === "---" ? n[n.length - 1] = `--- ${u}` : n.push(u); - } else - n.push(Je(e.contents, s)); - if (e.directives?.docEnd) - if (e.comment) { - const f = r(e.comment); - f.includes(` -`) ? (n.push("..."), n.push(fe(f, ""))) : n.push(`... ${f}`); - } else - n.push("..."); - else { - let f = e.comment; - f && o && (f = f.replace(/^\n+/, "")), f && ((!o || l) && n[n.length - 1] !== "" && n.push(""), n.push(fe(r(f), ""))); - } - return n.join(` -`) + ` -`; -} -class Be { - constructor(t, n, i) { - this.commentBefore = null, this.comment = null, this.errors = [], this.warnings = [], Object.defineProperty(this, te, { value: pn }); - let s = null; - typeof n == "function" || Array.isArray(n) ? s = n : i === void 0 && n && (i = n, n = void 0); - const r = Object.assign({ - intAsBigInt: !1, - keepSourceTokens: !1, - logLevel: "warn", - prettyErrors: !0, - strict: !0, - stringKeys: !1, - uniqueKeys: !0, - version: "1.2" - }, i); - this.options = r; - let { version: o } = r; - i?._directives ? (this.directives = i._directives.atDocument(), this.directives.yaml.explicit && (o = this.directives.yaml.version)) : this.directives = new C({ version: o }), this.setSchema(o, i), this.contents = t === void 0 ? null : this.createNode(t, s, i); - } - /** - * Create a deep copy of this Document and its contents. - * - * Custom Node values that inherit from `Object` still refer to their original instances. - */ - clone() { - const t = Object.create(Be.prototype, { - [te]: { value: pn } - }); - return t.commentBefore = this.commentBefore, t.comment = this.comment, t.errors = this.errors.slice(), t.warnings = this.warnings.slice(), t.options = Object.assign({}, this.options), this.directives && (t.directives = this.directives.clone()), t.schema = this.schema.clone(), t.contents = q(this.contents) ? this.contents.clone(t.schema) : this.contents, this.range && (t.range = this.range.slice()), t; - } - /** Adds a value to the document. */ - add(t) { - $e(this.contents) && this.contents.add(t); - } - /** Adds a value to the document. */ - addIn(t, n) { - $e(this.contents) && this.contents.addIn(t, n); - } - /** - * Create a new `Alias` node, ensuring that the target `node` has the required anchor. - * - * If `node` already has an anchor, `name` is ignored. - * Otherwise, the `node.anchor` value will be set to `name`, - * or if an anchor with that name is already present in the document, - * `name` will be used as a prefix for a new unique anchor. - * If `name` is undefined, the generated anchor will use 'a' as a prefix. - */ - createAlias(t, n) { - if (!t.anchor) { - const i = ji(this); - t.anchor = // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - !n || i.has(n) ? Fi(n || "a", i) : n; - } - return new at(t.anchor); - } - createNode(t, n, i) { - let s; - if (typeof n == "function") - t = n.call({ "": t }, "", t), s = n; - else if (Array.isArray(n)) { - const E = (L) => typeof L == "number" || L instanceof String || L instanceof Number, B = n.filter(E).map(String); - B.length > 0 && (n = n.concat(B)), s = n; - } else i === void 0 && n && (i = n, n = void 0); - const { aliasDuplicateObjects: r, anchorPrefix: o, flow: l, keepUndefined: f, onTagObj: u, tag: p } = i ?? {}, { onAnchor: g, setAnchors: y, sourceObjects: m } = Gs( - this, - // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing - o || "a" - ), k = { - aliasDuplicateObjects: r ?? !0, - keepUndefined: f ?? !1, - onAnchor: g, - onTagObj: u, - replacer: s, - schema: this.schema, - sourceObjects: m - }, b = nt(t, p, k); - return l && x(b) && (b.flow = !0), y(), b; - } - /** - * Convert a key and a value into a `Pair` using the current schema, - * recursively wrapping all values as `Scalar` or `Collection` nodes. - */ - createPair(t, n, i = {}) { - const s = this.createNode(t, null, i), r = this.createNode(n, null, i); - return new W(s, r); - } - /** - * Removes a value from the document. - * @returns `true` if the item was found and removed. - */ - delete(t) { - return $e(this.contents) ? this.contents.delete(t) : !1; - } - /** - * Removes a value from the document. - * @returns `true` if the item was found and removed. - */ - deleteIn(t) { - return et(t) ? this.contents == null ? !1 : (this.contents = null, !0) : $e(this.contents) ? this.contents.deleteIn(t) : !1; - } - /** - * Returns item at `key`, or `undefined` if not found. By default unwraps - * scalar values from their surrounding node; to disable set `keepScalar` to - * `true` (collections are always returned intact). - */ - get(t, n) { - return x(this.contents) ? this.contents.get(t, n) : void 0; - } - /** - * Returns item at `path`, or `undefined` if not found. By default unwraps - * scalar values from their surrounding node; to disable set `keepScalar` to - * `true` (collections are always returned intact). - */ - getIn(t, n) { - return et(t) ? !n && F(this.contents) ? this.contents.value : this.contents : x(this.contents) ? this.contents.getIn(t, n) : void 0; - } - /** - * Checks if the document includes a value with the key `key`. - */ - has(t) { - return x(this.contents) ? this.contents.has(t) : !1; - } - /** - * Checks if the document includes a value at `path`. - */ - hasIn(t) { - return et(t) ? this.contents !== void 0 : x(this.contents) ? this.contents.hasIn(t) : !1; - } - /** - * Sets a value in this document. For `!!set`, `value` needs to be a - * boolean to add/remove the item from the set. - */ - set(t, n) { - this.contents == null ? this.contents = $t(this.schema, [t], n) : $e(this.contents) && this.contents.set(t, n); - } - /** - * Sets a value in this document. For `!!set`, `value` needs to be a - * boolean to add/remove the item from the set. - */ - setIn(t, n) { - et(t) ? this.contents = n : this.contents == null ? this.contents = $t(this.schema, Array.from(t), n) : $e(this.contents) && this.contents.setIn(t, n); - } - /** - * Change the YAML version and schema used by the document. - * A `null` version disables support for directives, explicit tags, anchors, and aliases. - * It also requires the `schema` option to be given as a `Schema` instance value. - * - * Overrides all previously set schema options. - */ - setSchema(t, n = {}) { - typeof t == "number" && (t = String(t)); - let i; - switch (t) { - case "1.1": - this.directives ? this.directives.yaml.version = "1.1" : this.directives = new C({ version: "1.1" }), i = { resolveKnownTags: !1, schema: "yaml-1.1" }; - break; - case "1.2": - case "next": - this.directives ? this.directives.yaml.version = t : this.directives = new C({ version: t }), i = { resolveKnownTags: !0, schema: "core" }; - break; - case null: - this.directives && delete this.directives, i = null; - break; - default: { - const s = JSON.stringify(t); - throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${s}`); - } - } - if (n.schema instanceof Object) - this.schema = n.schema; - else if (i) - this.schema = new ut(Object.assign(i, n)); - else - throw new Error("With a null YAML version, the { schema: Schema } option is required"); - } - // json & jsonArg are only used from toJSON() - toJS({ json: t, jsonArg: n, mapAsMap: i, maxAliasCount: s, onAnchor: r, reviver: o } = {}) { - const l = { - anchors: /* @__PURE__ */ new Map(), - doc: this, - keep: !t, - mapAsMap: i === !0, - mapKeyWarned: !1, - maxAliasCount: typeof s == "number" ? s : 100 - }, f = ee(this.contents, n ?? "", l); - if (typeof r == "function") - for (const { count: u, res: p } of l.anchors.values()) - r(p, u); - return typeof o == "function" ? xe(o, { "": f }, "", f) : f; - } - /** - * A JSON representation of the document `contents`. - * - * @param jsonArg Used by `JSON.stringify` to indicate the array index or - * property name. - */ - toJSON(t, n) { - return this.toJS({ json: !0, jsonArg: t, mapAsMap: !1, onAnchor: n }); - } - /** A YAML representation of the document. */ - toString(t = {}) { - if (this.errors.length > 0) - throw new Error("Document with errors cannot be stringified"); - if ("indent" in t && (!Number.isInteger(t.indent) || Number(t.indent) <= 0)) { - const n = JSON.stringify(t.indent); - throw new Error(`"indent" option must be a positive integer, not ${n}`); - } - return br(this, t); - } -} -function $e(e) { - if (x(e)) - return !0; - throw new Error("Expected a YAML collection as document contents"); -} -class Yt extends Error { - constructor(t, n, i, s) { - super(), this.name = t, this.code = i, this.message = s, this.pos = n; - } -} -class me extends Yt { - constructor(t, n, i) { - super("YAMLParseError", t, n, i); - } -} -class Un extends Yt { - constructor(t, n, i) { - super("YAMLWarning", t, n, i); - } -} -const jt = (e, t) => (n) => { - if (n.pos[0] === -1) - return; - n.linePos = n.pos.map((l) => t.linePos(l)); - const { line: i, col: s } = n.linePos[0]; - n.message += ` at line ${i}, column ${s}`; - let r = s - 1, o = e.substring(t.lineStarts[i - 1], t.lineStarts[i]).replace(/[\n\r]+$/, ""); - if (r >= 60 && o.length > 80) { - const l = Math.min(r - 39, o.length - 79); - o = "…" + o.substring(l), r -= l - 1; - } - if (o.length > 80 && (o = o.substring(0, 79) + "…"), i > 1 && /^ *$/.test(o.substring(0, r))) { - let l = e.substring(t.lineStarts[i - 2], t.lineStarts[i - 1]); - l.length > 80 && (l = l.substring(0, 79) + `… -`), o = l + o; - } - if (/[^ ]/.test(o)) { - let l = 1; - const f = n.linePos[1]; - f && f.line === i && f.col > s && (l = Math.max(1, Math.min(f.col - s, 80 - r))); - const u = " ".repeat(r) + "^".repeat(l); - n.message += `: - -${o} -${u} -`; - } -}; -function Ye(e, { flow: t, indicator: n, next: i, offset: s, onError: r, parentIndent: o, startOnNewline: l }) { - let f = !1, u = l, p = l, g = "", y = "", m = !1, k = !1, b = null, E = null, B = null, L = null, A = null, _ = null, O = null; - for (const v of e) - switch (k && (v.type !== "space" && v.type !== "newline" && v.type !== "comma" && r(v.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), k = !1), b && (u && v.type !== "comment" && v.type !== "newline" && r(b, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), b = null), v.type) { - case "space": - !t && (n !== "doc-start" || i?.type !== "flow-collection") && v.source.includes(" ") && (b = v), p = !0; - break; - case "comment": { - p || r(v, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"); - const M = v.source.substring(1) || " "; - g ? g += y + M : g = M, y = "", u = !1; - break; - } - case "newline": - u ? g ? g += v.source : (!_ || n !== "seq-item-ind") && (f = !0) : y += v.source, u = !0, m = !0, (E || B) && (L = v), p = !0; - break; - case "anchor": - E && r(v, "MULTIPLE_ANCHORS", "A node can have at most one anchor"), v.source.endsWith(":") && r(v.offset + v.source.length - 1, "BAD_ALIAS", "Anchor ending in : is ambiguous", !0), E = v, O ?? (O = v.offset), u = !1, p = !1, k = !0; - break; - case "tag": { - B && r(v, "MULTIPLE_TAGS", "A node can have at most one tag"), B = v, O ?? (O = v.offset), u = !1, p = !1, k = !0; - break; - } - case n: - (E || B) && r(v, "BAD_PROP_ORDER", `Anchors and tags must be after the ${v.source} indicator`), _ && r(v, "UNEXPECTED_TOKEN", `Unexpected ${v.source} in ${t ?? "collection"}`), _ = v, u = n === "seq-item-ind" || n === "explicit-key-ind", p = !1; - break; - case "comma": - if (t) { - A && r(v, "UNEXPECTED_TOKEN", `Unexpected , in ${t}`), A = v, u = !1, p = !1; - break; - } - // else fallthrough - default: - r(v, "UNEXPECTED_TOKEN", `Unexpected ${v.type} token`), u = !1, p = !1; - } - const T = e[e.length - 1], N = T ? T.offset + T.source.length : s; - return k && i && i.type !== "space" && i.type !== "newline" && i.type !== "comma" && (i.type !== "scalar" || i.source !== "") && r(i.offset, "MISSING_CHAR", "Tags and anchors must be separated from the next token by white space"), b && (u && b.indent <= o || i?.type === "block-map" || i?.type === "block-seq") && r(b, "TAB_AS_INDENT", "Tabs are not allowed as indentation"), { - comma: A, - found: _, - spaceBefore: f, - comment: g, - hasNewline: m, - anchor: E, - tag: B, - newlineAfterProp: L, - end: N, - start: O ?? N - }; -} -function it(e) { - if (!e) - return null; - switch (e.type) { - case "alias": - case "scalar": - case "double-quoted-scalar": - case "single-quoted-scalar": - if (e.source.includes(` -`)) - return !0; - if (e.end) { - for (const t of e.end) - if (t.type === "newline") - return !0; - } - return !1; - case "flow-collection": - for (const t of e.items) { - for (const n of t.start) - if (n.type === "newline") - return !0; - if (t.sep) { - for (const n of t.sep) - if (n.type === "newline") - return !0; - } - if (it(t.key) || it(t.value)) - return !0; - } - return !1; - default: - return !0; - } -} -function mn(e, t, n) { - if (t?.type === "flow-collection") { - const i = t.end[0]; - i.indent === e && (i.source === "]" || i.source === "}") && it(t) && n(i, "BAD_INDENT", "Flow end indicator should be more indented than parent", !0); - } -} -function rs(e, t, n) { - const { uniqueKeys: i } = e.options; - if (i === !1) - return !1; - const s = typeof i == "function" ? i : (r, o) => r === o || F(r) && F(o) && r.value === o.value; - return t.some((r) => s(r.key, n)); -} -const ri = "All mapping items must start at the same column"; -function wr({ composeNode: e, composeEmptyNode: t }, n, i, s, r) { - const o = r?.nodeClass ?? X, l = new o(n.schema); - n.atRoot && (n.atRoot = !1); - let f = i.offset, u = null; - for (const p of i.items) { - const { start: g, key: y, sep: m, value: k } = p, b = Ye(g, { - indicator: "explicit-key-ind", - next: y ?? m?.[0], - offset: f, - onError: s, - parentIndent: i.indent, - startOnNewline: !0 - }), E = !b.found; - if (E) { - if (y && (y.type === "block-seq" ? s(f, "BLOCK_AS_IMPLICIT_KEY", "A block sequence may not be used as an implicit map key") : "indent" in y && y.indent !== i.indent && s(f, "BAD_INDENT", ri)), !b.anchor && !b.tag && !m) { - u = b.end, b.comment && (l.comment ? l.comment += ` -` + b.comment : l.comment = b.comment); - continue; - } - (b.newlineAfterProp || it(y)) && s(y ?? g[g.length - 1], "MULTILINE_IMPLICIT_KEY", "Implicit keys need to be on a single line"); - } else b.found?.indent !== i.indent && s(f, "BAD_INDENT", ri); - n.atKey = !0; - const B = b.end, L = y ? e(n, y, b, s) : t(n, B, g, null, b, s); - n.schema.compat && mn(i.indent, y, s), n.atKey = !1, rs(n, l.items, L) && s(B, "DUPLICATE_KEY", "Map keys must be unique"); - const A = Ye(m ?? [], { - indicator: "map-value-ind", - next: k, - offset: L.range[2], - onError: s, - parentIndent: i.indent, - startOnNewline: !y || y.type === "block-scalar" - }); - if (f = A.end, A.found) { - E && (k?.type === "block-map" && !A.hasNewline && s(f, "BLOCK_AS_IMPLICIT_KEY", "Nested mappings are not allowed in compact mappings"), n.options.strict && b.start < A.found.offset - 1024 && s(L.range, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit block mapping key")); - const _ = k ? e(n, k, A, s) : t(n, f, m, null, A, s); - n.schema.compat && mn(i.indent, k, s), f = _.range[2]; - const O = new W(L, _); - n.options.keepSourceTokens && (O.srcToken = p), l.items.push(O); - } else { - E && s(L.range, "MISSING_CHAR", "Implicit map keys need to be followed by map values"), A.comment && (L.comment ? L.comment += ` -` + A.comment : L.comment = A.comment); - const _ = new W(L); - n.options.keepSourceTokens && (_.srcToken = p), l.items.push(_); - } - } - return u && u < f && s(u, "IMPOSSIBLE", "Map comment with trailing content"), l.range = [i.offset, f, u ?? f], l; -} -function kr({ composeNode: e, composeEmptyNode: t }, n, i, s, r) { - const o = r?.nodeClass ?? he, l = new o(n.schema); - n.atRoot && (n.atRoot = !1), n.atKey && (n.atKey = !1); - let f = i.offset, u = null; - for (const { start: p, value: g } of i.items) { - const y = Ye(p, { - indicator: "seq-item-ind", - next: g, - offset: f, - onError: s, - parentIndent: i.indent, - startOnNewline: !0 - }); - if (!y.found) - if (y.anchor || y.tag || g) - g && g.type === "block-seq" ? s(y.end, "BAD_INDENT", "All sequence items must start at the same column") : s(f, "MISSING_CHAR", "Sequence item without - indicator"); - else { - u = y.end, y.comment && (l.comment = y.comment); - continue; - } - const m = g ? e(n, g, y, s) : t(n, y.end, p, null, y, s); - n.schema.compat && mn(i.indent, g, s), f = m.range[2], l.items.push(m); - } - return l.range = [i.offset, f, u ?? f], l; -} -function ht(e, t, n, i) { - let s = ""; - if (e) { - let r = !1, o = ""; - for (const l of e) { - const { source: f, type: u } = l; - switch (u) { - case "space": - r = !0; - break; - case "comment": { - n && !r && i(l, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"); - const p = f.substring(1) || " "; - s ? s += o + p : s = p, o = ""; - break; - } - case "newline": - s && (o += f), r = !0; - break; - default: - i(l, "UNEXPECTED_TOKEN", `Unexpected ${u} at node end`); - } - t += f.length; - } - } - return { comment: s, offset: t }; -} -const on = "Block collections are not allowed within flow collections", ln = (e) => e && (e.type === "block-map" || e.type === "block-seq"); -function Er({ composeNode: e, composeEmptyNode: t }, n, i, s, r) { - const o = i.start.source === "{", l = o ? "flow map" : "flow sequence", f = r?.nodeClass ?? (o ? X : he), u = new f(n.schema); - u.flow = !0; - const p = n.atRoot; - p && (n.atRoot = !1), n.atKey && (n.atKey = !1); - let g = i.offset + i.start.source.length; - for (let E = 0; E < i.items.length; ++E) { - const B = i.items[E], { start: L, key: A, sep: _, value: O } = B, T = Ye(L, { - flow: l, - indicator: "explicit-key-ind", - next: A ?? _?.[0], - offset: g, - onError: s, - parentIndent: i.indent, - startOnNewline: !1 - }); - if (!T.found) { - if (!T.anchor && !T.tag && !_ && !O) { - E === 0 && T.comma ? s(T.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${l}`) : E < i.items.length - 1 && s(T.start, "UNEXPECTED_TOKEN", `Unexpected empty item in ${l}`), T.comment && (u.comment ? u.comment += ` -` + T.comment : u.comment = T.comment), g = T.end; - continue; - } - !o && n.options.strict && it(A) && s( - A, - // checked by containsNewline() - "MULTILINE_IMPLICIT_KEY", - "Implicit keys of flow sequence pairs need to be on a single line" - ); - } - if (E === 0) - T.comma && s(T.comma, "UNEXPECTED_TOKEN", `Unexpected , in ${l}`); - else if (T.comma || s(T.start, "MISSING_CHAR", `Missing , between ${l} items`), T.comment) { - let N = ""; - e: for (const v of L) - switch (v.type) { - case "comma": - case "space": - break; - case "comment": - N = v.source.substring(1); - break e; - default: - break e; - } - if (N) { - let v = u.items[u.items.length - 1]; - R(v) && (v = v.value ?? v.key), v.comment ? v.comment += ` -` + N : v.comment = N, T.comment = T.comment.substring(N.length + 1); - } - } - if (!o && !_ && !T.found) { - const N = O ? e(n, O, T, s) : t(n, T.end, _, null, T, s); - u.items.push(N), g = N.range[2], ln(O) && s(N.range, "BLOCK_IN_FLOW", on); - } else { - n.atKey = !0; - const N = T.end, v = A ? e(n, A, T, s) : t(n, N, L, null, T, s); - ln(A) && s(v.range, "BLOCK_IN_FLOW", on), n.atKey = !1; - const M = Ye(_ ?? [], { - flow: l, - indicator: "map-value-ind", - next: O, - offset: v.range[2], - onError: s, - parentIndent: i.indent, - startOnNewline: !1 - }); - if (M.found) { - if (!o && !T.found && n.options.strict) { - if (_) - for (const K of _) { - if (K === M.found) - break; - if (K.type === "newline") { - s(K, "MULTILINE_IMPLICIT_KEY", "Implicit keys of flow sequence pairs need to be on a single line"); - break; - } - } - T.start < M.found.offset - 1024 && s(M.found, "KEY_OVER_1024_CHARS", "The : indicator must be at most 1024 chars after the start of an implicit flow sequence key"); - } - } else O && ("source" in O && O.source && O.source[0] === ":" ? s(O, "MISSING_CHAR", `Missing space after : in ${l}`) : s(M.start, "MISSING_CHAR", `Missing , or : between ${l} items`)); - const Q = O ? e(n, O, M, s) : M.found ? t(n, M.end, _, null, M, s) : null; - Q ? ln(O) && s(Q.range, "BLOCK_IN_FLOW", on) : M.comment && (v.comment ? v.comment += ` -` + M.comment : v.comment = M.comment); - const se = new W(v, Q); - if (n.options.keepSourceTokens && (se.srcToken = B), o) { - const K = u; - rs(n, K.items, v) && s(N, "DUPLICATE_KEY", "Map keys must be unique"), K.items.push(se); - } else { - const K = new X(n.schema); - K.flow = !0, K.items.push(se); - const de = (Q ?? v).range; - K.range = [v.range[0], de[1], de[2]], u.items.push(K); - } - g = Q ? Q.range[2] : M.end; - } - } - const y = o ? "}" : "]", [m, ...k] = i.end; - let b = g; - if (m && m.source === y) - b = m.offset + m.source.length; - else { - const E = l[0].toUpperCase() + l.substring(1), B = p ? `${E} must end with a ${y}` : `${E} in block collection must be sufficiently indented and end with a ${y}`; - s(g, p ? "MISSING_CHAR" : "BAD_INDENT", B), m && m.source.length !== 1 && k.unshift(m); - } - if (k.length > 0) { - const E = ht(k, b, n.options.strict, s); - E.comment && (u.comment ? u.comment += ` -` + E.comment : u.comment = E.comment), u.range = [i.offset, b, E.offset]; - } else - u.range = [i.offset, b, b]; - return u; -} -function an(e, t, n, i, s, r) { - const o = n.type === "block-map" ? wr(e, t, n, i, r) : n.type === "block-seq" ? kr(e, t, n, i, r) : Er(e, t, n, i, r), l = o.constructor; - return s === "!" || s === l.tagName ? (o.tag = l.tagName, o) : (s && (o.tag = s), o); -} -function Sr(e, t, n, i, s) { - const r = i.tag, o = r ? t.directives.tagName(r.source, (y) => s(r, "TAG_RESOLVE_FAILED", y)) : null; - if (n.type === "block-seq") { - const { anchor: y, newlineAfterProp: m } = i, k = y && r ? y.offset > r.offset ? y : r : y ?? r; - k && (!m || m.offset < k.offset) && s(k, "MISSING_CHAR", "Missing newline after block sequence props"); - } - const l = n.type === "block-map" ? "map" : n.type === "block-seq" ? "seq" : n.start.source === "{" ? "map" : "seq"; - if (!r || !o || o === "!" || o === X.tagName && l === "map" || o === he.tagName && l === "seq") - return an(e, t, n, s, o); - let f = t.schema.tags.find((y) => y.tag === o && y.collection === l); - if (!f) { - const y = t.schema.knownTags[o]; - if (y && y.collection === l) - t.schema.tags.push(Object.assign({}, y, { default: !1 })), f = y; - else - return y ? s(r, "BAD_COLLECTION_TYPE", `${y.tag} used for ${l} collection, but expects ${y.collection ?? "scalar"}`, !0) : s(r, "TAG_RESOLVE_FAILED", `Unresolved tag: ${o}`, !0), an(e, t, n, s, o); - } - const u = an(e, t, n, s, o, f), p = f.resolve?.(u, (y) => s(r, "TAG_RESOLVE_FAILED", y), t.options) ?? u, g = q(p) ? p : new $(p); - return g.range = u.range, g.tag = o, f?.format && (g.format = f.format), g; -} -function os(e, t, n) { - const i = t.offset, s = Ar(t, e.options.strict, n); - if (!s) - return { value: "", type: null, comment: "", range: [i, i, i] }; - const r = s.mode === ">" ? $.BLOCK_FOLDED : $.BLOCK_LITERAL, o = t.source ? Or(t.source) : []; - let l = o.length; - for (let b = o.length - 1; b >= 0; --b) { - const E = o[b][1]; - if (E === "" || E === "\r") - l = b; - else - break; - } - if (l === 0) { - const b = s.chomp === "+" && o.length > 0 ? ` -`.repeat(Math.max(1, o.length - 1)) : ""; - let E = i + s.length; - return t.source && (E += t.source.length), { value: b, type: r, comment: s.comment, range: [i, E, E] }; - } - let f = t.indent + s.indent, u = t.offset + s.length, p = 0; - for (let b = 0; b < l; ++b) { - const [E, B] = o[b]; - if (B === "" || B === "\r") - s.indent === 0 && E.length > f && (f = E.length); - else { - E.length < f && n(u + E.length, "MISSING_CHAR", "Block scalars with more-indented leading empty lines must use an explicit indentation indicator"), s.indent === 0 && (f = E.length), p = b, f === 0 && !e.atRoot && n(u, "BAD_INDENT", "Block scalar values in collections must be indented"); - break; - } - u += E.length + B.length + 1; - } - for (let b = o.length - 1; b >= l; --b) - o[b][0].length > f && (l = b + 1); - let g = "", y = "", m = !1; - for (let b = 0; b < p; ++b) - g += o[b][0].slice(f) + ` -`; - for (let b = p; b < l; ++b) { - let [E, B] = o[b]; - u += E.length + B.length + 1; - const L = B[B.length - 1] === "\r"; - if (L && (B = B.slice(0, -1)), B && E.length < f) { - const _ = `Block scalar lines must not be less indented than their ${s.indent ? "explicit indentation indicator" : "first line"}`; - n(u - B.length - (L ? 2 : 1), "BAD_INDENT", _), E = ""; - } - r === $.BLOCK_LITERAL ? (g += y + E.slice(f) + B, y = ` -`) : E.length > f || B[0] === " " ? (y === " " ? y = ` -` : !m && y === ` -` && (y = ` - -`), g += y + E.slice(f) + B, y = ` -`, m = !0) : B === "" ? y === ` -` ? g += ` -` : y = ` -` : (g += y + B, y = " ", m = !1); - } - switch (s.chomp) { - case "-": - break; - case "+": - for (let b = l; b < o.length; ++b) - g += ` -` + o[b][0].slice(f); - g[g.length - 1] !== ` -` && (g += ` -`); - break; - default: - g += ` -`; - } - const k = i + s.length + t.source.length; - return { value: g, type: r, comment: s.comment, range: [i, k, k] }; -} -function Ar({ offset: e, props: t }, n, i) { - if (t[0].type !== "block-scalar-header") - return i(t[0], "IMPOSSIBLE", "Block scalar header not found"), null; - const { source: s } = t[0], r = s[0]; - let o = 0, l = "", f = -1; - for (let y = 1; y < s.length; ++y) { - const m = s[y]; - if (!l && (m === "-" || m === "+")) - l = m; - else { - const k = Number(m); - !o && k ? o = k : f === -1 && (f = e + y); - } - } - f !== -1 && i(f, "UNEXPECTED_TOKEN", `Block scalar header includes extra characters: ${s}`); - let u = !1, p = "", g = s.length; - for (let y = 1; y < t.length; ++y) { - const m = t[y]; - switch (m.type) { - case "space": - u = !0; - // fallthrough - case "newline": - g += m.source.length; - break; - case "comment": - n && !u && i(m, "MISSING_CHAR", "Comments must be separated from other tokens by white space characters"), g += m.source.length, p = m.source.substring(1); - break; - case "error": - i(m, "UNEXPECTED_TOKEN", m.message), g += m.source.length; - break; - /* istanbul ignore next should not happen */ - default: { - const k = `Unexpected token in block scalar header: ${m.type}`; - i(m, "UNEXPECTED_TOKEN", k); - const b = m.source; - b && typeof b == "string" && (g += b.length); - } - } - } - return { mode: r, indent: o, chomp: l, comment: p, length: g }; -} -function Or(e) { - const t = e.split(/\n( *)/), n = t[0], i = n.match(/^( *)/), r = [i?.[1] ? [i[1], n.slice(i[1].length)] : ["", n]]; - for (let o = 1; o < t.length; o += 2) - r.push([t[o], t[o + 1]]); - return r; -} -function ls(e, t, n) { - const { offset: i, type: s, source: r, end: o } = e; - let l, f; - const u = (y, m, k) => n(i + y, m, k); - switch (s) { - case "scalar": - l = $.PLAIN, f = Ir(r, u); - break; - case "single-quoted-scalar": - l = $.QUOTE_SINGLE, f = Tr(r, u); - break; - case "double-quoted-scalar": - l = $.QUOTE_DOUBLE, f = Nr(r, u); - break; - /* istanbul ignore next should not happen */ - default: - return n(e, "UNEXPECTED_TOKEN", `Expected a flow scalar value, but found: ${s}`), { - value: "", - type: null, - comment: "", - range: [i, i + r.length, i + r.length] - }; - } - const p = i + r.length, g = ht(o, p, t, n); - return { - value: f, - type: l, - comment: g.comment, - range: [i, p, g.offset] - }; -} -function Ir(e, t) { - let n = ""; - switch (e[0]) { - /* istanbul ignore next should not happen */ - case " ": - n = "a tab character"; - break; - case ",": - n = "flow indicator character ,"; - break; - case "%": - n = "directive indicator character %"; - break; - case "|": - case ">": { - n = `block scalar indicator ${e[0]}`; - break; - } - case "@": - case "`": { - n = `reserved character ${e[0]}`; - break; - } - } - return n && t(0, "BAD_SCALAR_START", `Plain value cannot start with ${n}`), as(e); -} -function Tr(e, t) { - return (e[e.length - 1] !== "'" || e.length === 1) && t(e.length, "MISSING_CHAR", "Missing closing 'quote"), as(e.slice(1, -1)).replace(/''/g, "'"); -} -function as(e) { - let t, n; - try { - t = new RegExp(`(.*?)(? r ? e.slice(r, i + 1) : s); - } else - n += s; - } - return (e[e.length - 1] !== '"' || e.length === 1) && t(e.length, "MISSING_CHAR", 'Missing closing "quote'), n; -} -function Br(e, t) { - let n = "", i = e[t + 1]; - for (; (i === " " || i === " " || i === ` -` || i === "\r") && !(i === "\r" && e[t + 2] !== ` -`); ) - i === ` -` && (n += ` -`), t += 1, i = e[t + 1]; - return n || (n = " "), { fold: n, offset: t }; -} -const Lr = { - 0: "\0", - // null character - a: "\x07", - // bell character - b: "\b", - // backspace - e: "\x1B", - // escape character - f: "\f", - // form feed - n: ` -`, - // line feed - r: "\r", - // carriage return - t: " ", - // horizontal tab - v: "\v", - // vertical tab - N: "…", - // Unicode next line - _: " ", - // Unicode non-breaking space - L: "\u2028", - // Unicode line separator - P: "\u2029", - // Unicode paragraph separator - " ": " ", - '"': '"', - "/": "/", - "\\": "\\", - " ": " " -}; -function _r(e, t, n, i) { - const s = e.substr(t, n), o = s.length === n && /^[0-9a-fA-F]+$/.test(s) ? parseInt(s, 16) : NaN; - if (isNaN(o)) { - const l = e.substr(t - 2, n + 2); - return i(t - 2, "BAD_DQ_ESCAPE", `Invalid escape sequence ${l}`), l; - } - return String.fromCodePoint(o); -} -function cs(e, t, n, i) { - const { value: s, type: r, comment: o, range: l } = t.type === "block-scalar" ? os(e, t, i) : ls(t, e.options.strict, i), f = n ? e.directives.tagName(n.source, (g) => i(n, "TAG_RESOLVE_FAILED", g)) : null; - let u; - e.options.stringKeys && e.atKey ? u = e.schema[ae] : f ? u = vr(e.schema, s, f, n, i) : t.type === "scalar" ? u = $r(e, s, t, i) : u = e.schema[ae]; - let p; - try { - const g = u.resolve(s, (y) => i(n ?? t, "TAG_RESOLVE_FAILED", y), e.options); - p = F(g) ? g : new $(g); - } catch (g) { - const y = g instanceof Error ? g.message : String(g); - i(n ?? t, "TAG_RESOLVE_FAILED", y), p = new $(s); - } - return p.range = l, p.source = s, r && (p.type = r), f && (p.tag = f), u.format && (p.format = u.format), o && (p.comment = o), p; -} -function vr(e, t, n, i, s) { - if (n === "!") - return e[ae]; - const r = []; - for (const l of e.tags) - if (!l.collection && l.tag === n) - if (l.default && l.test) - r.push(l); - else - return l; - for (const l of r) - if (l.test?.test(t)) - return l; - const o = e.knownTags[n]; - return o && !o.collection ? (e.tags.push(Object.assign({}, o, { default: !1, test: void 0 })), o) : (s(i, "TAG_RESOLVE_FAILED", `Unresolved tag: ${n}`, n !== "tag:yaml.org,2002:str"), e[ae]); -} -function $r({ atKey: e, directives: t, schema: n }, i, s, r) { - const o = n.tags.find((l) => (l.default === !0 || e && l.default === "key") && l.test?.test(i)) || n[ae]; - if (n.compat) { - const l = n.compat.find((f) => f.default && f.test?.test(i)) ?? n[ae]; - if (o.tag !== l.tag) { - const f = t.tagString(o.tag), u = t.tagString(l.tag), p = `Value may be parsed as either ${f} or ${u}`; - r(s, "TAG_RESOLVE_FAILED", p, !0); - } - } - return o; -} -function Pr(e, t, n) { - if (t) { - n ?? (n = t.length); - for (let i = n - 1; i >= 0; --i) { - let s = t[i]; - switch (s.type) { - case "space": - case "comment": - case "newline": - e -= s.source.length; - continue; - } - for (s = t[++i]; s?.type === "space"; ) - e += s.source.length, s = t[++i]; - break; - } - } - return e; -} -const jr = { composeNode: fs, composeEmptyNode: Mn }; -function fs(e, t, n, i) { - const s = e.atKey, { spaceBefore: r, comment: o, anchor: l, tag: f } = n; - let u, p = !0; - switch (t.type) { - case "alias": - u = Fr(e, t, i), (l || f) && i(t, "ALIAS_PROPS", "An alias node must not specify any properties"); - break; - case "scalar": - case "single-quoted-scalar": - case "double-quoted-scalar": - case "block-scalar": - u = cs(e, t, f, i), l && (u.anchor = l.source.substring(1)); - break; - case "block-map": - case "block-seq": - case "flow-collection": - u = Sr(jr, e, t, n, i), l && (u.anchor = l.source.substring(1)); - break; - default: { - const g = t.type === "error" ? t.message : `Unsupported token (type: ${t.type})`; - i(t, "UNEXPECTED_TOKEN", g), u = Mn(e, t.offset, void 0, null, n, i), p = !1; - } - } - return l && u.anchor === "" && i(l, "BAD_ALIAS", "Anchor cannot be an empty string"), s && e.options.stringKeys && (!F(u) || typeof u.value != "string" || u.tag && u.tag !== "tag:yaml.org,2002:str") && i(f ?? t, "NON_STRING_KEY", "With stringKeys, all keys must be strings"), r && (u.spaceBefore = !0), o && (t.type === "scalar" && t.source === "" ? u.comment = o : u.commentBefore = o), e.options.keepSourceTokens && p && (u.srcToken = t), u; -} -function Mn(e, t, n, i, { spaceBefore: s, comment: r, anchor: o, tag: l, end: f }, u) { - const p = { - type: "scalar", - offset: Pr(t, n, i), - indent: -1, - source: "" - }, g = cs(e, p, l, u); - return o && (g.anchor = o.source.substring(1), g.anchor === "" && u(o, "BAD_ALIAS", "Anchor cannot be an empty string")), s && (g.spaceBefore = !0), r && (g.comment = r, g.range[2] = f), g; -} -function Fr({ options: e }, { offset: t, source: n, end: i }, s) { - const r = new at(n.substring(1)); - r.source === "" && s(t, "BAD_ALIAS", "Alias cannot be an empty string"), r.source.endsWith(":") && s(t + n.length - 1, "BAD_ALIAS", "Alias ending in : is ambiguous", !0); - const o = t + n.length, l = ht(i, o, e.strict, s); - return r.range = [t, o, l.offset], l.comment && (r.comment = l.comment), r; -} -function Ur(e, t, { offset: n, start: i, value: s, end: r }, o) { - const l = Object.assign({ _directives: t }, e), f = new Be(void 0, l), u = { - atKey: !1, - atRoot: !0, - directives: f.directives, - options: f.options, - schema: f.schema - }, p = Ye(i, { - indicator: "doc-start", - next: s ?? r?.[0], - offset: n, - onError: o, - parentIndent: 0, - startOnNewline: !0 - }); - p.found && (f.directives.docStart = !0, s && (s.type === "block-map" || s.type === "block-seq") && !p.hasNewline && o(p.end, "MISSING_CHAR", "Block collection cannot start on same line with directives-end marker")), f.contents = s ? fs(u, s, p, o) : Mn(u, p.end, i, null, p, o); - const g = f.contents.range[2], y = ht(r, g, !1, o); - return y.comment && (f.comment = y.comment), f.range = [n, g, y.offset], f; -} -function ze(e) { - if (typeof e == "number") - return [e, e + 1]; - if (Array.isArray(e)) - return e.length === 2 ? e : [e[0], e[1]]; - const { offset: t, source: n } = e; - return [t, t + (typeof n == "string" ? n.length : 1)]; -} -function oi(e) { - let t = "", n = !1, i = !1; - for (let s = 0; s < e.length; ++s) { - const r = e[s]; - switch (r[0]) { - case "#": - t += (t === "" ? "" : i ? ` - -` : ` -`) + (r.substring(1) || " "), n = !0, i = !1; - break; - case "%": - e[s + 1]?.[0] !== "#" && (s += 1), n = !1; - break; - default: - n || (i = !0), n = !1; - } - } - return { comment: t, afterEmptyLine: i }; -} -class Gt { - constructor(t = {}) { - this.doc = null, this.atDirectives = !1, this.prelude = [], this.errors = [], this.warnings = [], this.onError = (n, i, s, r) => { - const o = ze(n); - r ? this.warnings.push(new Un(o, i, s)) : this.errors.push(new me(o, i, s)); - }, this.directives = new C({ version: t.version || "1.2" }), this.options = t; - } - decorate(t, n) { - const { comment: i, afterEmptyLine: s } = oi(this.prelude); - if (i) { - const r = t.contents; - if (n) - t.comment = t.comment ? `${t.comment} -${i}` : i; - else if (s || t.directives.docStart || !r) - t.commentBefore = i; - else if (x(r) && !r.flow && r.items.length > 0) { - let o = r.items[0]; - R(o) && (o = o.key); - const l = o.commentBefore; - o.commentBefore = l ? `${i} -${l}` : i; - } else { - const o = r.commentBefore; - r.commentBefore = o ? `${i} -${o}` : i; - } - } - n ? (Array.prototype.push.apply(t.errors, this.errors), Array.prototype.push.apply(t.warnings, this.warnings)) : (t.errors = this.errors, t.warnings = this.warnings), this.prelude = [], this.errors = [], this.warnings = []; - } - /** - * Current stream status information. - * - * Mostly useful at the end of input for an empty stream. - */ - streamInfo() { - return { - comment: oi(this.prelude).comment, - directives: this.directives, - errors: this.errors, - warnings: this.warnings - }; - } - /** - * Compose tokens into documents. - * - * @param forceDoc - If the stream contains no document, still emit a final document including any comments and directives that would be applied to a subsequent document. - * @param endOffset - Should be set if `forceDoc` is also set, to set the document range end and to indicate errors correctly. - */ - *compose(t, n = !1, i = -1) { - for (const s of t) - yield* this.next(s); - yield* this.end(n, i); - } - /** Advance the composer by one CST token. */ - *next(t) { - switch (t.type) { - case "directive": - this.directives.add(t.source, (n, i, s) => { - const r = ze(t); - r[0] += n, this.onError(r, "BAD_DIRECTIVE", i, s); - }), this.prelude.push(t.source), this.atDirectives = !0; - break; - case "document": { - const n = Ur(this.options, this.directives, t, this.onError); - this.atDirectives && !n.directives.docStart && this.onError(t, "MISSING_CHAR", "Missing directives-end/doc-start indicator line"), this.decorate(n, !1), this.doc && (yield this.doc), this.doc = n, this.atDirectives = !1; - break; - } - case "byte-order-mark": - case "space": - break; - case "comment": - case "newline": - this.prelude.push(t.source); - break; - case "error": { - const n = t.source ? `${t.message}: ${JSON.stringify(t.source)}` : t.message, i = new me(ze(t), "UNEXPECTED_TOKEN", n); - this.atDirectives || !this.doc ? this.errors.push(i) : this.doc.errors.push(i); - break; - } - case "doc-end": { - if (!this.doc) { - const i = "Unexpected doc-end without preceding document"; - this.errors.push(new me(ze(t), "UNEXPECTED_TOKEN", i)); - break; - } - this.doc.directives.docEnd = !0; - const n = ht(t.end, t.offset + t.source.length, this.doc.options.strict, this.onError); - if (this.decorate(this.doc, !0), n.comment) { - const i = this.doc.comment; - this.doc.comment = i ? `${i} -${n.comment}` : n.comment; - } - this.doc.range[2] = n.offset; - break; - } - default: - this.errors.push(new me(ze(t), "UNEXPECTED_TOKEN", `Unsupported token ${t.type}`)); - } - } - /** - * Call at end of input to yield any remaining document. - * - * @param forceDoc - If the stream contains no document, still emit a final document including any comments and directives that would be applied to a subsequent document. - * @param endOffset - Should be set if `forceDoc` is also set, to set the document range end and to indicate errors correctly. - */ - *end(t = !1, n = -1) { - if (this.doc) - this.decorate(this.doc, !0), yield this.doc, this.doc = null; - else if (t) { - const i = Object.assign({ _directives: this.directives }, this.options), s = new Be(void 0, i); - this.atDirectives && this.onError(n, "MISSING_CHAR", "Missing directives-end indicator line"), s.range = [0, n, n], this.decorate(s, !1), yield s; - } - } -} -function Mr(e, t = !0, n) { - if (e) { - const i = (s, r, o) => { - const l = typeof s == "number" ? s : Array.isArray(s) ? s[0] : s.offset; - if (n) - n(l, r, o); - else - throw new me([l, l + 1], r, o); - }; - switch (e.type) { - case "scalar": - case "single-quoted-scalar": - case "double-quoted-scalar": - return ls(e, t, i); - case "block-scalar": - return os({ options: { strict: t } }, e, i); - } - } - return null; -} -function Rr(e, t) { - const { implicitKey: n = !1, indent: i, inFlow: s = !1, offset: r = -1, type: o = "PLAIN" } = t, l = ct({ type: o, value: e }, { - implicitKey: n, - indent: i > 0 ? " ".repeat(i) : "", - inFlow: s, - options: { blockQuote: !0, lineWidth: -1 } - }), f = t.end ?? [ - { type: "newline", offset: -1, indent: i, source: ` -` } - ]; - switch (l[0]) { - case "|": - case ">": { - const u = l.indexOf(` -`), p = l.substring(0, u), g = l.substring(u + 1) + ` -`, y = [ - { type: "block-scalar-header", offset: r, indent: i, source: p } - ]; - return us(y, f) || y.push({ type: "newline", offset: -1, indent: i, source: ` -` }), { type: "block-scalar", offset: r, indent: i, props: y, source: g }; - } - case '"': - return { type: "double-quoted-scalar", offset: r, indent: i, source: l, end: f }; - case "'": - return { type: "single-quoted-scalar", offset: r, indent: i, source: l, end: f }; - default: - return { type: "scalar", offset: r, indent: i, source: l, end: f }; - } -} -function Dr(e, t, n = {}) { - let { afterKey: i = !1, implicitKey: s = !1, inFlow: r = !1, type: o } = n, l = "indent" in e ? e.indent : null; - if (i && typeof l == "number" && (l += 2), !o) - switch (e.type) { - case "single-quoted-scalar": - o = "QUOTE_SINGLE"; - break; - case "double-quoted-scalar": - o = "QUOTE_DOUBLE"; - break; - case "block-scalar": { - const u = e.props[0]; - if (u.type !== "block-scalar-header") - throw new Error("Invalid block scalar header"); - o = u.source[0] === ">" ? "BLOCK_FOLDED" : "BLOCK_LITERAL"; - break; - } - default: - o = "PLAIN"; - } - const f = ct({ type: o, value: t }, { - implicitKey: s || l === null, - indent: l !== null && l > 0 ? " ".repeat(l) : "", - inFlow: r, - options: { blockQuote: !0, lineWidth: -1 } - }); - switch (f[0]) { - case "|": - case ">": - xr(e, f); - break; - case '"': - cn(e, f, "double-quoted-scalar"); - break; - case "'": - cn(e, f, "single-quoted-scalar"); - break; - default: - cn(e, f, "scalar"); - } -} -function xr(e, t) { - const n = t.indexOf(` -`), i = t.substring(0, n), s = t.substring(n + 1) + ` -`; - if (e.type === "block-scalar") { - const r = e.props[0]; - if (r.type !== "block-scalar-header") - throw new Error("Invalid block scalar header"); - r.source = i, e.source = s; - } else { - const { offset: r } = e, o = "indent" in e ? e.indent : -1, l = [ - { type: "block-scalar-header", offset: r, indent: o, source: i } - ]; - us(l, "end" in e ? e.end : void 0) || l.push({ type: "newline", offset: -1, indent: o, source: ` -` }); - for (const f of Object.keys(e)) - f !== "type" && f !== "offset" && delete e[f]; - Object.assign(e, { type: "block-scalar", indent: o, props: l, source: s }); - } -} -function us(e, t) { - if (t) - for (const n of t) - switch (n.type) { - case "space": - case "comment": - e.push(n); - break; - case "newline": - return e.push(n), !0; - } - return !1; -} -function cn(e, t, n) { - switch (e.type) { - case "scalar": - case "double-quoted-scalar": - case "single-quoted-scalar": - e.type = n, e.source = t; - break; - case "block-scalar": { - const i = e.props.slice(1); - let s = t.length; - e.props[0].type === "block-scalar-header" && (s -= e.props[0].source.length); - for (const r of i) - r.offset += s; - delete e.props, Object.assign(e, { type: n, source: t, end: i }); - break; - } - case "block-map": - case "block-seq": { - const s = { type: "newline", offset: e.offset + t.length, indent: e.indent, source: ` -` }; - delete e.items, Object.assign(e, { type: n, source: t, end: [s] }); - break; - } - default: { - const i = "indent" in e ? e.indent : -1, s = "end" in e && Array.isArray(e.end) ? e.end.filter((r) => r.type === "space" || r.type === "comment" || r.type === "newline") : []; - for (const r of Object.keys(e)) - r !== "type" && r !== "offset" && delete e[r]; - Object.assign(e, { type: n, indent: i, source: t, end: s }); - } - } -} -const qr = (e) => "type" in e ? Ft(e) : vt(e); -function Ft(e) { - switch (e.type) { - case "block-scalar": { - let t = ""; - for (const n of e.props) - t += Ft(n); - return t + e.source; - } - case "block-map": - case "block-seq": { - let t = ""; - for (const n of e.items) - t += vt(n); - return t; - } - case "flow-collection": { - let t = e.start.source; - for (const n of e.items) - t += vt(n); - for (const n of e.end) - t += n.source; - return t; - } - case "document": { - let t = vt(e); - if (e.end) - for (const n of e.end) - t += n.source; - return t; - } - default: { - let t = e.source; - if ("end" in e && e.end) - for (const n of e.end) - t += n.source; - return t; - } - } -} -function vt({ start: e, key: t, sep: n, value: i }) { - let s = ""; - for (const r of e) - s += r.source; - if (t && (s += Ft(t)), n) - for (const r of n) - s += r.source; - return i && (s += Ft(i)), s; -} -const bn = /* @__PURE__ */ Symbol("break visit"), Kr = /* @__PURE__ */ Symbol("skip children"), hs = /* @__PURE__ */ Symbol("remove item"); -function Ie(e, t) { - "type" in e && e.type === "document" && (e = { start: e.start, value: e.value }), ps(Object.freeze([]), e, t); -} -Ie.BREAK = bn; -Ie.SKIP = Kr; -Ie.REMOVE = hs; -Ie.itemAtPath = (e, t) => { - let n = e; - for (const [i, s] of t) { - const r = n?.[i]; - if (r && "items" in r) - n = r.items[s]; - else - return; - } - return n; -}; -Ie.parentCollection = (e, t) => { - const n = Ie.itemAtPath(e, t.slice(0, -1)), i = t[t.length - 1][0], s = n?.[i]; - if (s && "items" in s) - return s; - throw new Error("Parent collection not found"); -}; -function ps(e, t, n) { - let i = n(t, e); - if (typeof i == "symbol") - return i; - for (const s of ["key", "value"]) { - const r = t[s]; - if (r && "items" in r) { - for (let o = 0; o < r.items.length; ++o) { - const l = ps(Object.freeze(e.concat([[s, o]])), r.items[o], n); - if (typeof l == "number") - o = l - 1; - else { - if (l === bn) - return bn; - l === hs && (r.items.splice(o, 1), o -= 1); - } - } - typeof i == "function" && s === "key" && (i = i(t, e)); - } - } - return typeof i == "function" ? i(t, e) : i; -} -const Wt = "\uFEFF", Ct = "", Qt = "", st = "", Vr = (e) => !!e && "items" in e, Jr = (e) => !!e && (e.type === "scalar" || e.type === "single-quoted-scalar" || e.type === "double-quoted-scalar" || e.type === "block-scalar"); -function Yr(e) { - switch (e) { - case Wt: - return ""; - case Ct: - return ""; - case Qt: - return ""; - case st: - return ""; - default: - return JSON.stringify(e); - } -} -function ds(e) { - switch (e) { - case Wt: - return "byte-order-mark"; - case Ct: - return "doc-mode"; - case Qt: - return "flow-error-end"; - case st: - return "scalar"; - case "---": - return "doc-start"; - case "...": - return "doc-end"; - case "": - case ` -`: - case `\r -`: - return "newline"; - case "-": - return "seq-item-ind"; - case "?": - return "explicit-key-ind"; - case ":": - return "map-value-ind"; - case "{": - return "flow-map-start"; - case "}": - return "flow-map-end"; - case "[": - return "flow-seq-start"; - case "]": - return "flow-seq-end"; - case ",": - return "comma"; - } - switch (e[0]) { - case " ": - case " ": - return "space"; - case "#": - return "comment"; - case "%": - return "directive-line"; - case "*": - return "alias"; - case "&": - return "anchor"; - case "!": - return "tag"; - case "'": - return "single-quoted-scalar"; - case '"': - return "double-quoted-scalar"; - case "|": - case ">": - return "block-scalar-header"; - } - return null; -} -const gs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ - __proto__: null, - BOM: Wt, - DOCUMENT: Ct, - FLOW_END: Qt, - SCALAR: st, - createScalarToken: Rr, - isCollection: Vr, - isScalar: Jr, - prettyToken: Yr, - resolveAsScalar: Mr, - setScalarValue: Dr, - stringify: qr, - tokenType: ds, - visit: Ie -}, Symbol.toStringTag, { value: "Module" })); -function ne(e) { - switch (e) { - case void 0: - case " ": - case ` -`: - case "\r": - case " ": - return !0; - default: - return !1; - } -} -const li = new Set("0123456789ABCDEFabcdef"), Gr = new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"), Et = new Set(",[]{}"), Wr = new Set(` ,[]{} -\r `), fn = (e) => !e || Wr.has(e); -class Rn { - constructor() { - this.atEnd = !1, this.blockScalarIndent = -1, this.blockScalarKeep = !1, this.buffer = "", this.flowKey = !1, this.flowLevel = 0, this.indentNext = 0, this.indentValue = 0, this.lineEndPos = null, this.next = null, this.pos = 0; - } - /** - * Generate YAML tokens from the `source` string. If `incomplete`, - * a part of the last line may be left as a buffer for the next call. - * - * @returns A generator of lexical tokens - */ - *lex(t, n = !1) { - if (t) { - if (typeof t != "string") - throw TypeError("source is not a string"); - this.buffer = this.buffer ? this.buffer + t : t, this.lineEndPos = null; - } - this.atEnd = !n; - let i = this.next ?? "stream"; - for (; i && (n || this.hasChars(1)); ) - i = yield* this.parseNext(i); - } - atLineEnd() { - let t = this.pos, n = this.buffer[t]; - for (; n === " " || n === " "; ) - n = this.buffer[++t]; - return !n || n === "#" || n === ` -` ? !0 : n === "\r" ? this.buffer[t + 1] === ` -` : !1; - } - charAt(t) { - return this.buffer[this.pos + t]; - } - continueScalar(t) { - let n = this.buffer[t]; - if (this.indentNext > 0) { - let i = 0; - for (; n === " "; ) - n = this.buffer[++i + t]; - if (n === "\r") { - const s = this.buffer[i + t + 1]; - if (s === ` -` || !s && !this.atEnd) - return t + i + 1; - } - return n === ` -` || i >= this.indentNext || !n && !this.atEnd ? t + i : -1; - } - if (n === "-" || n === ".") { - const i = this.buffer.substr(t, 3); - if ((i === "---" || i === "...") && ne(this.buffer[t + 3])) - return -1; - } - return t; - } - getLine() { - let t = this.lineEndPos; - return (typeof t != "number" || t !== -1 && t < this.pos) && (t = this.buffer.indexOf(` -`, this.pos), this.lineEndPos = t), t === -1 ? this.atEnd ? this.buffer.substring(this.pos) : null : (this.buffer[t - 1] === "\r" && (t -= 1), this.buffer.substring(this.pos, t)); - } - hasChars(t) { - return this.pos + t <= this.buffer.length; - } - setNext(t) { - return this.buffer = this.buffer.substring(this.pos), this.pos = 0, this.lineEndPos = null, this.next = t, null; - } - peek(t) { - return this.buffer.substr(this.pos, t); - } - *parseNext(t) { - switch (t) { - case "stream": - return yield* this.parseStream(); - case "line-start": - return yield* this.parseLineStart(); - case "block-start": - return yield* this.parseBlockStart(); - case "doc": - return yield* this.parseDocument(); - case "flow": - return yield* this.parseFlowCollection(); - case "quoted-scalar": - return yield* this.parseQuotedScalar(); - case "block-scalar": - return yield* this.parseBlockScalar(); - case "plain-scalar": - return yield* this.parsePlainScalar(); - } - } - *parseStream() { - let t = this.getLine(); - if (t === null) - return this.setNext("stream"); - if (t[0] === Wt && (yield* this.pushCount(1), t = t.substring(1)), t[0] === "%") { - let n = t.length, i = t.indexOf("#"); - for (; i !== -1; ) { - const r = t[i - 1]; - if (r === " " || r === " ") { - n = i - 1; - break; - } else - i = t.indexOf("#", i + 1); - } - for (; ; ) { - const r = t[n - 1]; - if (r === " " || r === " ") - n -= 1; - else - break; - } - const s = (yield* this.pushCount(n)) + (yield* this.pushSpaces(!0)); - return yield* this.pushCount(t.length - s), this.pushNewline(), "stream"; - } - if (this.atLineEnd()) { - const n = yield* this.pushSpaces(!0); - return yield* this.pushCount(t.length - n), yield* this.pushNewline(), "stream"; - } - return yield Ct, yield* this.parseLineStart(); - } - *parseLineStart() { - const t = this.charAt(0); - if (!t && !this.atEnd) - return this.setNext("line-start"); - if (t === "-" || t === ".") { - if (!this.atEnd && !this.hasChars(4)) - return this.setNext("line-start"); - const n = this.peek(3); - if ((n === "---" || n === "...") && ne(this.charAt(3))) - return yield* this.pushCount(3), this.indentValue = 0, this.indentNext = 0, n === "---" ? "doc" : "stream"; - } - return this.indentValue = yield* this.pushSpaces(!1), this.indentNext > this.indentValue && !ne(this.charAt(1)) && (this.indentNext = this.indentValue), yield* this.parseBlockStart(); - } - *parseBlockStart() { - const [t, n] = this.peek(2); - if (!n && !this.atEnd) - return this.setNext("block-start"); - if ((t === "-" || t === "?" || t === ":") && ne(n)) { - const i = (yield* this.pushCount(1)) + (yield* this.pushSpaces(!0)); - return this.indentNext = this.indentValue + 1, this.indentValue += i, yield* this.parseBlockStart(); - } - return "doc"; - } - *parseDocument() { - yield* this.pushSpaces(!0); - const t = this.getLine(); - if (t === null) - return this.setNext("doc"); - let n = yield* this.pushIndicators(); - switch (t[n]) { - case "#": - yield* this.pushCount(t.length - n); - // fallthrough - case void 0: - return yield* this.pushNewline(), yield* this.parseLineStart(); - case "{": - case "[": - return yield* this.pushCount(1), this.flowKey = !1, this.flowLevel = 1, "flow"; - case "}": - case "]": - return yield* this.pushCount(1), "doc"; - case "*": - return yield* this.pushUntil(fn), "doc"; - case '"': - case "'": - return yield* this.parseQuotedScalar(); - case "|": - case ">": - return n += yield* this.parseBlockScalarHeader(), n += yield* this.pushSpaces(!0), yield* this.pushCount(t.length - n), yield* this.pushNewline(), yield* this.parseBlockScalar(); - default: - return yield* this.parsePlainScalar(); - } - } - *parseFlowCollection() { - let t, n, i = -1; - do - t = yield* this.pushNewline(), t > 0 ? (n = yield* this.pushSpaces(!1), this.indentValue = i = n) : n = 0, n += yield* this.pushSpaces(!0); - while (t + n > 0); - const s = this.getLine(); - if (s === null) - return this.setNext("flow"); - if ((i !== -1 && i < this.indentNext && s[0] !== "#" || i === 0 && (s.startsWith("---") || s.startsWith("...")) && ne(s[3])) && !(i === this.indentNext - 1 && this.flowLevel === 1 && (s[0] === "]" || s[0] === "}"))) - return this.flowLevel = 0, yield Qt, yield* this.parseLineStart(); - let r = 0; - for (; s[r] === ","; ) - r += yield* this.pushCount(1), r += yield* this.pushSpaces(!0), this.flowKey = !1; - switch (r += yield* this.pushIndicators(), s[r]) { - case void 0: - return "flow"; - case "#": - return yield* this.pushCount(s.length - r), "flow"; - case "{": - case "[": - return yield* this.pushCount(1), this.flowKey = !1, this.flowLevel += 1, "flow"; - case "}": - case "]": - return yield* this.pushCount(1), this.flowKey = !0, this.flowLevel -= 1, this.flowLevel ? "flow" : "doc"; - case "*": - return yield* this.pushUntil(fn), "flow"; - case '"': - case "'": - return this.flowKey = !0, yield* this.parseQuotedScalar(); - case ":": { - const o = this.charAt(1); - if (this.flowKey || ne(o) || o === ",") - return this.flowKey = !1, yield* this.pushCount(1), yield* this.pushSpaces(!0), "flow"; - } - // fallthrough - default: - return this.flowKey = !1, yield* this.parsePlainScalar(); - } - } - *parseQuotedScalar() { - const t = this.charAt(0); - let n = this.buffer.indexOf(t, this.pos + 1); - if (t === "'") - for (; n !== -1 && this.buffer[n + 1] === "'"; ) - n = this.buffer.indexOf("'", n + 2); - else - for (; n !== -1; ) { - let r = 0; - for (; this.buffer[n - 1 - r] === "\\"; ) - r += 1; - if (r % 2 === 0) - break; - n = this.buffer.indexOf('"', n + 1); - } - const i = this.buffer.substring(0, n); - let s = i.indexOf(` -`, this.pos); - if (s !== -1) { - for (; s !== -1; ) { - const r = this.continueScalar(s + 1); - if (r === -1) - break; - s = i.indexOf(` -`, r); - } - s !== -1 && (n = s - (i[s - 1] === "\r" ? 2 : 1)); - } - if (n === -1) { - if (!this.atEnd) - return this.setNext("quoted-scalar"); - n = this.buffer.length; - } - return yield* this.pushToIndex(n + 1, !1), this.flowLevel ? "flow" : "doc"; - } - *parseBlockScalarHeader() { - this.blockScalarIndent = -1, this.blockScalarKeep = !1; - let t = this.pos; - for (; ; ) { - const n = this.buffer[++t]; - if (n === "+") - this.blockScalarKeep = !0; - else if (n > "0" && n <= "9") - this.blockScalarIndent = Number(n) - 1; - else if (n !== "-") - break; - } - return yield* this.pushUntil((n) => ne(n) || n === "#"); - } - *parseBlockScalar() { - let t = this.pos - 1, n = 0, i; - e: for (let r = this.pos; i = this.buffer[r]; ++r) - switch (i) { - case " ": - n += 1; - break; - case ` -`: - t = r, n = 0; - break; - case "\r": { - const o = this.buffer[r + 1]; - if (!o && !this.atEnd) - return this.setNext("block-scalar"); - if (o === ` -`) - break; - } - // fallthrough - default: - break e; - } - if (!i && !this.atEnd) - return this.setNext("block-scalar"); - if (n >= this.indentNext) { - this.blockScalarIndent === -1 ? this.indentNext = n : this.indentNext = this.blockScalarIndent + (this.indentNext === 0 ? 1 : this.indentNext); - do { - const r = this.continueScalar(t + 1); - if (r === -1) - break; - t = this.buffer.indexOf(` -`, r); - } while (t !== -1); - if (t === -1) { - if (!this.atEnd) - return this.setNext("block-scalar"); - t = this.buffer.length; - } - } - let s = t + 1; - for (i = this.buffer[s]; i === " "; ) - i = this.buffer[++s]; - if (i === " ") { - for (; i === " " || i === " " || i === "\r" || i === ` -`; ) - i = this.buffer[++s]; - t = s - 1; - } else if (!this.blockScalarKeep) - do { - let r = t - 1, o = this.buffer[r]; - o === "\r" && (o = this.buffer[--r]); - const l = r; - for (; o === " "; ) - o = this.buffer[--r]; - if (o === ` -` && r >= this.pos && r + 1 + n > l) - t = r; - else - break; - } while (!0); - return yield st, yield* this.pushToIndex(t + 1, !0), yield* this.parseLineStart(); - } - *parsePlainScalar() { - const t = this.flowLevel > 0; - let n = this.pos - 1, i = this.pos - 1, s; - for (; s = this.buffer[++i]; ) - if (s === ":") { - const r = this.buffer[i + 1]; - if (ne(r) || t && Et.has(r)) - break; - n = i; - } else if (ne(s)) { - let r = this.buffer[i + 1]; - if (s === "\r" && (r === ` -` ? (i += 1, s = ` -`, r = this.buffer[i + 1]) : n = i), r === "#" || t && Et.has(r)) - break; - if (s === ` -`) { - const o = this.continueScalar(i + 1); - if (o === -1) - break; - i = Math.max(i, o - 2); - } - } else { - if (t && Et.has(s)) - break; - n = i; - } - return !s && !this.atEnd ? this.setNext("plain-scalar") : (yield st, yield* this.pushToIndex(n + 1, !0), t ? "flow" : "doc"); - } - *pushCount(t) { - return t > 0 ? (yield this.buffer.substr(this.pos, t), this.pos += t, t) : 0; - } - *pushToIndex(t, n) { - const i = this.buffer.slice(this.pos, t); - return i ? (yield i, this.pos += i.length, i.length) : (n && (yield ""), 0); - } - *pushIndicators() { - switch (this.charAt(0)) { - case "!": - return (yield* this.pushTag()) + (yield* this.pushSpaces(!0)) + (yield* this.pushIndicators()); - case "&": - return (yield* this.pushUntil(fn)) + (yield* this.pushSpaces(!0)) + (yield* this.pushIndicators()); - case "-": - // this is an error - case "?": - // this is an error outside flow collections - case ":": { - const t = this.flowLevel > 0, n = this.charAt(1); - if (ne(n) || t && Et.has(n)) - return t ? this.flowKey && (this.flowKey = !1) : this.indentNext = this.indentValue + 1, (yield* this.pushCount(1)) + (yield* this.pushSpaces(!0)) + (yield* this.pushIndicators()); - } - } - return 0; - } - *pushTag() { - if (this.charAt(1) === "<") { - let t = this.pos + 2, n = this.buffer[t]; - for (; !ne(n) && n !== ">"; ) - n = this.buffer[++t]; - return yield* this.pushToIndex(n === ">" ? t + 1 : t, !1); - } else { - let t = this.pos + 1, n = this.buffer[t]; - for (; n; ) - if (Gr.has(n)) - n = this.buffer[++t]; - else if (n === "%" && li.has(this.buffer[t + 1]) && li.has(this.buffer[t + 2])) - n = this.buffer[t += 3]; - else - break; - return yield* this.pushToIndex(t, !1); - } - } - *pushNewline() { - const t = this.buffer[this.pos]; - return t === ` -` ? yield* this.pushCount(1) : t === "\r" && this.charAt(1) === ` -` ? yield* this.pushCount(2) : 0; - } - *pushSpaces(t) { - let n = this.pos - 1, i; - do - i = this.buffer[++n]; - while (i === " " || t && i === " "); - const s = n - this.pos; - return s > 0 && (yield this.buffer.substr(this.pos, s), this.pos = n), s; - } - *pushUntil(t) { - let n = this.pos, i = this.buffer[n]; - for (; !t(i); ) - i = this.buffer[++n]; - return yield* this.pushToIndex(n, !1); - } -} -class Dn { - constructor() { - this.lineStarts = [], this.addNewLine = (t) => this.lineStarts.push(t), this.linePos = (t) => { - let n = 0, i = this.lineStarts.length; - for (; n < i; ) { - const r = n + i >> 1; - this.lineStarts[r] < t ? n = r + 1 : i = r; - } - if (this.lineStarts[n] === t) - return { line: n + 1, col: 1 }; - if (n === 0) - return { line: 0, col: t }; - const s = this.lineStarts[n - 1]; - return { line: n, col: t - s + 1 }; - }; - } -} -function ye(e, t) { - for (let n = 0; n < e.length; ++n) - if (e[n].type === t) - return !0; - return !1; -} -function ai(e) { - for (let t = 0; t < e.length; ++t) - switch (e[t].type) { - case "space": - case "comment": - case "newline": - break; - default: - return t; - } - return -1; -} -function ys(e) { - switch (e?.type) { - case "alias": - case "scalar": - case "single-quoted-scalar": - case "double-quoted-scalar": - case "flow-collection": - return !0; - default: - return !1; - } -} -function St(e) { - switch (e.type) { - case "document": - return e.start; - case "block-map": { - const t = e.items[e.items.length - 1]; - return t.sep ?? t.start; - } - case "block-seq": - return e.items[e.items.length - 1].start; - /* istanbul ignore next should not happen */ - default: - return []; - } -} -function Pe(e) { - if (e.length === 0) - return []; - let t = e.length; - e: for (; --t >= 0; ) - switch (e[t].type) { - case "doc-start": - case "explicit-key-ind": - case "map-value-ind": - case "seq-item-ind": - case "newline": - break e; - } - for (; e[++t]?.type === "space"; ) - ; - return e.splice(t, e.length); -} -function ci(e) { - if (e.start.type === "flow-seq-start") - for (const t of e.items) - t.sep && !t.value && !ye(t.start, "explicit-key-ind") && !ye(t.sep, "map-value-ind") && (t.key && (t.value = t.key), delete t.key, ys(t.value) ? t.value.end ? Array.prototype.push.apply(t.value.end, t.sep) : t.value.end = t.sep : Array.prototype.push.apply(t.start, t.sep), delete t.sep); -} -class Ht { - /** - * @param onNewLine - If defined, called separately with the start position of - * each new line (in `parse()`, including the start of input). - */ - constructor(t) { - this.atNewLine = !0, this.atScalar = !1, this.indent = 0, this.offset = 0, this.onKeyLine = !1, this.stack = [], this.source = "", this.type = "", this.lexer = new Rn(), this.onNewLine = t; - } - /** - * Parse `source` as a YAML stream. - * If `incomplete`, a part of the last line may be left as a buffer for the next call. - * - * Errors are not thrown, but yielded as `{ type: 'error', message }` tokens. - * - * @returns A generator of tokens representing each directive, document, and other structure. - */ - *parse(t, n = !1) { - this.onNewLine && this.offset === 0 && this.onNewLine(0); - for (const i of this.lexer.lex(t, n)) - yield* this.next(i); - n || (yield* this.end()); - } - /** - * Advance the parser by the `source` of one lexical token. - */ - *next(t) { - if (this.source = t, this.atScalar) { - this.atScalar = !1, yield* this.step(), this.offset += t.length; - return; - } - const n = ds(t); - if (n) - if (n === "scalar") - this.atNewLine = !1, this.atScalar = !0, this.type = "scalar"; - else { - switch (this.type = n, yield* this.step(), n) { - case "newline": - this.atNewLine = !0, this.indent = 0, this.onNewLine && this.onNewLine(this.offset + t.length); - break; - case "space": - this.atNewLine && t[0] === " " && (this.indent += t.length); - break; - case "explicit-key-ind": - case "map-value-ind": - case "seq-item-ind": - this.atNewLine && (this.indent += t.length); - break; - case "doc-mode": - case "flow-error-end": - return; - default: - this.atNewLine = !1; - } - this.offset += t.length; - } - else { - const i = `Not a YAML token: ${t}`; - yield* this.pop({ type: "error", offset: this.offset, message: i, source: t }), this.offset += t.length; - } - } - /** Call at end of input to push out any remaining constructions */ - *end() { - for (; this.stack.length > 0; ) - yield* this.pop(); - } - get sourceToken() { - return { - type: this.type, - offset: this.offset, - indent: this.indent, - source: this.source - }; - } - *step() { - const t = this.peek(1); - if (this.type === "doc-end" && (!t || t.type !== "doc-end")) { - for (; this.stack.length > 0; ) - yield* this.pop(); - this.stack.push({ - type: "doc-end", - offset: this.offset, - source: this.source - }); - return; - } - if (!t) - return yield* this.stream(); - switch (t.type) { - case "document": - return yield* this.document(t); - case "alias": - case "scalar": - case "single-quoted-scalar": - case "double-quoted-scalar": - return yield* this.scalar(t); - case "block-scalar": - return yield* this.blockScalar(t); - case "block-map": - return yield* this.blockMap(t); - case "block-seq": - return yield* this.blockSequence(t); - case "flow-collection": - return yield* this.flowCollection(t); - case "doc-end": - return yield* this.documentEnd(t); - } - yield* this.pop(); - } - peek(t) { - return this.stack[this.stack.length - t]; - } - *pop(t) { - const n = t ?? this.stack.pop(); - if (!n) - yield { type: "error", offset: this.offset, source: "", message: "Tried to pop an empty stack" }; - else if (this.stack.length === 0) - yield n; - else { - const i = this.peek(1); - switch (n.type === "block-scalar" ? n.indent = "indent" in i ? i.indent : 0 : n.type === "flow-collection" && i.type === "document" && (n.indent = 0), n.type === "flow-collection" && ci(n), i.type) { - case "document": - i.value = n; - break; - case "block-scalar": - i.props.push(n); - break; - case "block-map": { - const s = i.items[i.items.length - 1]; - if (s.value) { - i.items.push({ start: [], key: n, sep: [] }), this.onKeyLine = !0; - return; - } else if (s.sep) - s.value = n; - else { - Object.assign(s, { key: n, sep: [] }), this.onKeyLine = !s.explicitKey; - return; - } - break; - } - case "block-seq": { - const s = i.items[i.items.length - 1]; - s.value ? i.items.push({ start: [], value: n }) : s.value = n; - break; - } - case "flow-collection": { - const s = i.items[i.items.length - 1]; - !s || s.value ? i.items.push({ start: [], key: n, sep: [] }) : s.sep ? s.value = n : Object.assign(s, { key: n, sep: [] }); - return; - } - /* istanbul ignore next should not happen */ - default: - yield* this.pop(), yield* this.pop(n); - } - if ((i.type === "document" || i.type === "block-map" || i.type === "block-seq") && (n.type === "block-map" || n.type === "block-seq")) { - const s = n.items[n.items.length - 1]; - s && !s.sep && !s.value && s.start.length > 0 && ai(s.start) === -1 && (n.indent === 0 || s.start.every((r) => r.type !== "comment" || r.indent < n.indent)) && (i.type === "document" ? i.end = s.start : i.items.push({ start: s.start }), n.items.splice(-1, 1)); - } - } - } - *stream() { - switch (this.type) { - case "directive-line": - yield { type: "directive", offset: this.offset, source: this.source }; - return; - case "byte-order-mark": - case "space": - case "comment": - case "newline": - yield this.sourceToken; - return; - case "doc-mode": - case "doc-start": { - const t = { - type: "document", - offset: this.offset, - start: [] - }; - this.type === "doc-start" && t.start.push(this.sourceToken), this.stack.push(t); - return; - } - } - yield { - type: "error", - offset: this.offset, - message: `Unexpected ${this.type} token in YAML stream`, - source: this.source - }; - } - *document(t) { - if (t.value) - return yield* this.lineEnd(t); - switch (this.type) { - case "doc-start": { - ai(t.start) !== -1 ? (yield* this.pop(), yield* this.step()) : t.start.push(this.sourceToken); - return; - } - case "anchor": - case "tag": - case "space": - case "comment": - case "newline": - t.start.push(this.sourceToken); - return; - } - const n = this.startBlockValue(t); - n ? this.stack.push(n) : yield { - type: "error", - offset: this.offset, - message: `Unexpected ${this.type} token in YAML document`, - source: this.source - }; - } - *scalar(t) { - if (this.type === "map-value-ind") { - const n = St(this.peek(2)), i = Pe(n); - let s; - t.end ? (s = t.end, s.push(this.sourceToken), delete t.end) : s = [this.sourceToken]; - const r = { - type: "block-map", - offset: t.offset, - indent: t.indent, - items: [{ start: i, key: t, sep: s }] - }; - this.onKeyLine = !0, this.stack[this.stack.length - 1] = r; - } else - yield* this.lineEnd(t); - } - *blockScalar(t) { - switch (this.type) { - case "space": - case "comment": - case "newline": - t.props.push(this.sourceToken); - return; - case "scalar": - if (t.source = this.source, this.atNewLine = !0, this.indent = 0, this.onNewLine) { - let n = this.source.indexOf(` -`) + 1; - for (; n !== 0; ) - this.onNewLine(this.offset + n), n = this.source.indexOf(` -`, n) + 1; - } - yield* this.pop(); - break; - /* istanbul ignore next should not happen */ - default: - yield* this.pop(), yield* this.step(); - } - } - *blockMap(t) { - const n = t.items[t.items.length - 1]; - switch (this.type) { - case "newline": - if (this.onKeyLine = !1, n.value) { - const i = "end" in n.value ? n.value.end : void 0; - (Array.isArray(i) ? i[i.length - 1] : void 0)?.type === "comment" ? i?.push(this.sourceToken) : t.items.push({ start: [this.sourceToken] }); - } else n.sep ? n.sep.push(this.sourceToken) : n.start.push(this.sourceToken); - return; - case "space": - case "comment": - if (n.value) - t.items.push({ start: [this.sourceToken] }); - else if (n.sep) - n.sep.push(this.sourceToken); - else { - if (this.atIndentedComment(n.start, t.indent)) { - const s = t.items[t.items.length - 2]?.value?.end; - if (Array.isArray(s)) { - Array.prototype.push.apply(s, n.start), s.push(this.sourceToken), t.items.pop(); - return; - } - } - n.start.push(this.sourceToken); - } - return; - } - if (this.indent >= t.indent) { - const i = !this.onKeyLine && this.indent === t.indent, s = i && (n.sep || n.explicitKey) && this.type !== "seq-item-ind"; - let r = []; - if (s && n.sep && !n.value) { - const o = []; - for (let l = 0; l < n.sep.length; ++l) { - const f = n.sep[l]; - switch (f.type) { - case "newline": - o.push(l); - break; - case "space": - break; - case "comment": - f.indent > t.indent && (o.length = 0); - break; - default: - o.length = 0; - } - } - o.length >= 2 && (r = n.sep.splice(o[1])); - } - switch (this.type) { - case "anchor": - case "tag": - s || n.value ? (r.push(this.sourceToken), t.items.push({ start: r }), this.onKeyLine = !0) : n.sep ? n.sep.push(this.sourceToken) : n.start.push(this.sourceToken); - return; - case "explicit-key-ind": - !n.sep && !n.explicitKey ? (n.start.push(this.sourceToken), n.explicitKey = !0) : s || n.value ? (r.push(this.sourceToken), t.items.push({ start: r, explicitKey: !0 })) : this.stack.push({ - type: "block-map", - offset: this.offset, - indent: this.indent, - items: [{ start: [this.sourceToken], explicitKey: !0 }] - }), this.onKeyLine = !0; - return; - case "map-value-ind": - if (n.explicitKey) - if (n.sep) - if (n.value) - t.items.push({ start: [], key: null, sep: [this.sourceToken] }); - else if (ye(n.sep, "map-value-ind")) - this.stack.push({ - type: "block-map", - offset: this.offset, - indent: this.indent, - items: [{ start: r, key: null, sep: [this.sourceToken] }] - }); - else if (ys(n.key) && !ye(n.sep, "newline")) { - const o = Pe(n.start), l = n.key, f = n.sep; - f.push(this.sourceToken), delete n.key, delete n.sep, this.stack.push({ - type: "block-map", - offset: this.offset, - indent: this.indent, - items: [{ start: o, key: l, sep: f }] - }); - } else r.length > 0 ? n.sep = n.sep.concat(r, this.sourceToken) : n.sep.push(this.sourceToken); - else if (ye(n.start, "newline")) - Object.assign(n, { key: null, sep: [this.sourceToken] }); - else { - const o = Pe(n.start); - this.stack.push({ - type: "block-map", - offset: this.offset, - indent: this.indent, - items: [{ start: o, key: null, sep: [this.sourceToken] }] - }); - } - else - n.sep ? n.value || s ? t.items.push({ start: r, key: null, sep: [this.sourceToken] }) : ye(n.sep, "map-value-ind") ? this.stack.push({ - type: "block-map", - offset: this.offset, - indent: this.indent, - items: [{ start: [], key: null, sep: [this.sourceToken] }] - }) : n.sep.push(this.sourceToken) : Object.assign(n, { key: null, sep: [this.sourceToken] }); - this.onKeyLine = !0; - return; - case "alias": - case "scalar": - case "single-quoted-scalar": - case "double-quoted-scalar": { - const o = this.flowScalar(this.type); - s || n.value ? (t.items.push({ start: r, key: o, sep: [] }), this.onKeyLine = !0) : n.sep ? this.stack.push(o) : (Object.assign(n, { key: o, sep: [] }), this.onKeyLine = !0); - return; - } - default: { - const o = this.startBlockValue(t); - if (o) { - if (o.type === "block-seq") { - if (!n.explicitKey && n.sep && !ye(n.sep, "newline")) { - yield* this.pop({ - type: "error", - offset: this.offset, - message: "Unexpected block-seq-ind on same line with key", - source: this.source - }); - return; - } - } else i && t.items.push({ start: r }); - this.stack.push(o); - return; - } - } - } - } - yield* this.pop(), yield* this.step(); - } - *blockSequence(t) { - const n = t.items[t.items.length - 1]; - switch (this.type) { - case "newline": - if (n.value) { - const i = "end" in n.value ? n.value.end : void 0; - (Array.isArray(i) ? i[i.length - 1] : void 0)?.type === "comment" ? i?.push(this.sourceToken) : t.items.push({ start: [this.sourceToken] }); - } else - n.start.push(this.sourceToken); - return; - case "space": - case "comment": - if (n.value) - t.items.push({ start: [this.sourceToken] }); - else { - if (this.atIndentedComment(n.start, t.indent)) { - const s = t.items[t.items.length - 2]?.value?.end; - if (Array.isArray(s)) { - Array.prototype.push.apply(s, n.start), s.push(this.sourceToken), t.items.pop(); - return; - } - } - n.start.push(this.sourceToken); - } - return; - case "anchor": - case "tag": - if (n.value || this.indent <= t.indent) - break; - n.start.push(this.sourceToken); - return; - case "seq-item-ind": - if (this.indent !== t.indent) - break; - n.value || ye(n.start, "seq-item-ind") ? t.items.push({ start: [this.sourceToken] }) : n.start.push(this.sourceToken); - return; - } - if (this.indent > t.indent) { - const i = this.startBlockValue(t); - if (i) { - this.stack.push(i); - return; - } - } - yield* this.pop(), yield* this.step(); - } - *flowCollection(t) { - const n = t.items[t.items.length - 1]; - if (this.type === "flow-error-end") { - let i; - do - yield* this.pop(), i = this.peek(1); - while (i && i.type === "flow-collection"); - } else if (t.end.length === 0) { - switch (this.type) { - case "comma": - case "explicit-key-ind": - !n || n.sep ? t.items.push({ start: [this.sourceToken] }) : n.start.push(this.sourceToken); - return; - case "map-value-ind": - !n || n.value ? t.items.push({ start: [], key: null, sep: [this.sourceToken] }) : n.sep ? n.sep.push(this.sourceToken) : Object.assign(n, { key: null, sep: [this.sourceToken] }); - return; - case "space": - case "comment": - case "newline": - case "anchor": - case "tag": - !n || n.value ? t.items.push({ start: [this.sourceToken] }) : n.sep ? n.sep.push(this.sourceToken) : n.start.push(this.sourceToken); - return; - case "alias": - case "scalar": - case "single-quoted-scalar": - case "double-quoted-scalar": { - const s = this.flowScalar(this.type); - !n || n.value ? t.items.push({ start: [], key: s, sep: [] }) : n.sep ? this.stack.push(s) : Object.assign(n, { key: s, sep: [] }); - return; - } - case "flow-map-end": - case "flow-seq-end": - t.end.push(this.sourceToken); - return; - } - const i = this.startBlockValue(t); - i ? this.stack.push(i) : (yield* this.pop(), yield* this.step()); - } else { - const i = this.peek(2); - if (i.type === "block-map" && (this.type === "map-value-ind" && i.indent === t.indent || this.type === "newline" && !i.items[i.items.length - 1].sep)) - yield* this.pop(), yield* this.step(); - else if (this.type === "map-value-ind" && i.type !== "flow-collection") { - const s = St(i), r = Pe(s); - ci(t); - const o = t.end.splice(1, t.end.length); - o.push(this.sourceToken); - const l = { - type: "block-map", - offset: t.offset, - indent: t.indent, - items: [{ start: r, key: t, sep: o }] - }; - this.onKeyLine = !0, this.stack[this.stack.length - 1] = l; - } else - yield* this.lineEnd(t); - } - } - flowScalar(t) { - if (this.onNewLine) { - let n = this.source.indexOf(` -`) + 1; - for (; n !== 0; ) - this.onNewLine(this.offset + n), n = this.source.indexOf(` -`, n) + 1; - } - return { - type: t, - offset: this.offset, - indent: this.indent, - source: this.source - }; - } - startBlockValue(t) { - switch (this.type) { - case "alias": - case "scalar": - case "single-quoted-scalar": - case "double-quoted-scalar": - return this.flowScalar(this.type); - case "block-scalar-header": - return { - type: "block-scalar", - offset: this.offset, - indent: this.indent, - props: [this.sourceToken], - source: "" - }; - case "flow-map-start": - case "flow-seq-start": - return { - type: "flow-collection", - offset: this.offset, - indent: this.indent, - start: this.sourceToken, - items: [], - end: [] - }; - case "seq-item-ind": - return { - type: "block-seq", - offset: this.offset, - indent: this.indent, - items: [{ start: [this.sourceToken] }] - }; - case "explicit-key-ind": { - this.onKeyLine = !0; - const n = St(t), i = Pe(n); - return i.push(this.sourceToken), { - type: "block-map", - offset: this.offset, - indent: this.indent, - items: [{ start: i, explicitKey: !0 }] - }; - } - case "map-value-ind": { - this.onKeyLine = !0; - const n = St(t), i = Pe(n); - return { - type: "block-map", - offset: this.offset, - indent: this.indent, - items: [{ start: i, key: null, sep: [this.sourceToken] }] - }; - } - } - return null; - } - atIndentedComment(t, n) { - return this.type !== "comment" || this.indent <= n ? !1 : t.every((i) => i.type === "newline" || i.type === "space"); - } - *documentEnd(t) { - this.type !== "doc-mode" && (t.end ? t.end.push(this.sourceToken) : t.end = [this.sourceToken], this.type === "newline" && (yield* this.pop())); - } - *lineEnd(t) { - switch (this.type) { - case "comma": - case "doc-start": - case "doc-end": - case "flow-seq-end": - case "flow-map-end": - case "map-value-ind": - yield* this.pop(), yield* this.step(); - break; - case "newline": - this.onKeyLine = !1; - default: - t.end ? t.end.push(this.sourceToken) : t.end = [this.sourceToken], this.type === "newline" && (yield* this.pop()); - } - } -} -function ms(e) { - const t = e.prettyErrors !== !1; - return { lineCounter: e.lineCounter || t && new Dn() || null, prettyErrors: t }; -} -function bs(e, t = {}) { - const { lineCounter: n, prettyErrors: i } = ms(t), s = new Ht(n?.addNewLine), r = new Gt(t), o = Array.from(r.compose(s.parse(e))); - if (i && n) - for (const l of o) - l.errors.forEach(jt(e, n)), l.warnings.forEach(jt(e, n)); - return o.length > 0 ? o : Object.assign([], { empty: !0 }, r.streamInfo()); -} -function xn(e, t = {}) { - const { lineCounter: n, prettyErrors: i } = ms(t), s = new Ht(n?.addNewLine), r = new Gt(t); - let o = null; - for (const l of r.compose(s.parse(e), !0, e.length)) - if (!o) - o = l; - else if (o.options.logLevel !== "silent") { - o.errors.push(new me(l.range.slice(0, 2), "MULTIPLE_DOCS", "Source contains multiple documents; please use YAML.parseAllDocuments()")); - break; - } - return i && n && (o.errors.forEach(jt(e, n)), o.warnings.forEach(jt(e, n))), o; -} -function ws(e, t, n) { - let i; - typeof t == "function" ? i = t : n === void 0 && t && typeof t == "object" && (n = t); - const s = xn(e, n); - if (!s) - return null; - if (s.warnings.forEach((r) => xi(s.options.logLevel, r)), s.errors.length > 0) { - if (s.options.logLevel !== "silent") - throw s.errors[0]; - s.errors = []; - } - return s.toJS(Object.assign({ reviver: i }, n)); -} -function ks(e, t, n) { - let i = null; - if (typeof t == "function" || Array.isArray(t) ? i = t : n === void 0 && t && (n = t), typeof n == "string" && (n = n.length), typeof n == "number") { - const s = Math.round(n); - n = s < 1 ? void 0 : s > 8 ? { indent: 8 } : { indent: s }; - } - if (e === void 0) { - const { keepUndefined: s } = n ?? t ?? {}; - if (!s) - return; - } - return we(e) && !i ? e.toString(n) : new Be(e, i, n).toString(n); -} -const Cr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ - __proto__: null, - Alias: at, - CST: gs, - Composer: Gt, - Document: Be, - Lexer: Rn, - LineCounter: Dn, - Pair: W, - Parser: Ht, - Scalar: $, - Schema: ut, - YAMLError: Yt, - YAMLMap: X, - YAMLParseError: me, - YAMLSeq: he, - YAMLWarning: Un, - isAlias: pe, - isCollection: x, - isDocument: we, - isMap: Te, - isNode: q, - isPair: R, - isScalar: F, - isSeq: Ne, - parse: ws, - parseAllDocuments: bs, - parseDocument: xn, - stringify: ks, - visit: ke, - visitAsync: lt -}, Symbol.toStringTag, { value: "Module" })), Qr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ - __proto__: null, - Alias: at, - CST: gs, - Composer: Gt, - Document: Be, - Lexer: Rn, - LineCounter: Dn, - Pair: W, - Parser: Ht, - Scalar: $, - Schema: ut, - YAMLError: Yt, - YAMLMap: X, - YAMLParseError: me, - YAMLSeq: he, - YAMLWarning: Un, - default: Cr, - isAlias: pe, - isCollection: x, - isDocument: we, - isMap: Te, - isNode: q, - isPair: R, - isScalar: F, - isSeq: Ne, - parse: ws, - parseAllDocuments: bs, - parseDocument: xn, - stringify: ks, - visit: ke, - visitAsync: lt -}, Symbol.toStringTag, { value: "Module" })), qn = /* @__PURE__ */ Oi(Qr); -var fi; -function Hr() { - if (fi) return mt; - fi = 1, Object.defineProperty(mt, "__esModule", { value: !0 }), mt.visitYaml = t; - const e = qn; - function t(r, o, l, f, u) { - const p = n(o, l, f); - if ((0, e.isMap)(f)) { - u.onObjectStart(o, l, f, p); - for (const g of f.items) - t(r, f, g.key.value, g.value, u); - u.onObjectEnd(); - } else if ((0, e.isSeq)(f)) - u.onArrayStart(o, l, f, p), f.items.forEach((g, y) => { - t(r, f, y, g, u); - }), u.onArrayEnd(); - else if ((0, e.isScalar)(f)) - u.onValue(o, l, f.value, f.source, p); - else if ((0, e.isAlias)(f)) { - const g = f.resolve(r); - g !== void 0 && t(r, o, l, g, u); - } - } - function n(r, o, l) { - return { key: i(r, o), value: { start: l.range[0], end: l.range[1] } }; - } - function i(r, o) { - if ((0, e.isMap)(r)) { - const l = s(r.items, o); - if (l !== void 0 && l.key.range) - return { start: l.key.range[0], end: l.key.range[1] }; - } - } - function s(r, o) { - const l = (0, e.isScalar)(o) ? o.value : o; - for (const f of r) - if ((0, e.isPair)(f) && (f.key === o || f.key === l || (0, e.isScalar)(f.key) && f.key.value === l)) - return f; - } - return mt; -} -var At = {}, ui; -function zr() { - if (ui) return At; - ui = 1, Object.defineProperty(At, "__esModule", { value: !0 }), At.visitJson = e; - function e(t, n, i, s, r) { - if (s === void 0) { - r.onValue(n, i, null, void 0, { value: { start: 0, end: 0 } }); - return; - } - const o = { value: { start: s.offset, end: s.offset + s.length } }; - if (n && n.type === "property") { - const l = n.children[0]; - o.key = { start: l.offset, end: l.offset + l.length }; - } - if (s.type === "object") { - r.onObjectStart(n, i, s, o); - for (const l of s.children) { - const [f, u] = l.children; - e(void 0, l, f.value, u, r); - } - r.onObjectEnd(); - } else s.type === "array" ? (r.onArrayStart(n, i, s, o), s.children.forEach((l, f) => { - e(void 0, s, f, l, r); - }), r.onArrayEnd()) : r.onValue(n, i, s.value, s.rawValue, o); - } - return At; -} -var Ot = {}; -function zt(e, t = !1) { - const n = e.length; - let i = 0, s = "", r = 0, o = 16, l = 0, f = 0, u = 0, p = 0, g = 0; - function y(A, _) { - let O = 0, T = 0; - for (; O < A; ) { - let N = e.charCodeAt(i); - if (N >= 48 && N <= 57) - T = T * 16 + N - 48; - else if (N >= 65 && N <= 70) - T = T * 16 + N - 65 + 10; - else if (N >= 97 && N <= 102) - T = T * 16 + N - 97 + 10; - else - break; - i++, O++; - } - return O < A && (T = -1), T; - } - function m(A) { - i = A, s = "", r = 0, o = 16, g = 0; - } - function k() { - let A = i; - if (e.charCodeAt(i) === 48) - i++; - else - for (i++; i < e.length && je(e.charCodeAt(i)); ) - i++; - if (i < e.length && e.charCodeAt(i) === 46) - if (i++, i < e.length && je(e.charCodeAt(i))) - for (i++; i < e.length && je(e.charCodeAt(i)); ) - i++; - else - return g = 3, e.substring(A, i); - let _ = i; - if (i < e.length && (e.charCodeAt(i) === 69 || e.charCodeAt(i) === 101)) - if (i++, (i < e.length && e.charCodeAt(i) === 43 || e.charCodeAt(i) === 45) && i++, i < e.length && je(e.charCodeAt(i))) { - for (i++; i < e.length && je(e.charCodeAt(i)); ) - i++; - _ = i; - } else - g = 3; - return e.substring(A, _); - } - function b() { - let A = "", _ = i; - for (; ; ) { - if (i >= n) { - A += e.substring(_, i), g = 2; - break; - } - const O = e.charCodeAt(i); - if (O === 34) { - A += e.substring(_, i), i++; - break; - } - if (O === 92) { - if (A += e.substring(_, i), i++, i >= n) { - g = 2; - break; - } - switch (e.charCodeAt(i++)) { - case 34: - A += '"'; - break; - case 92: - A += "\\"; - break; - case 47: - A += "/"; - break; - case 98: - A += "\b"; - break; - case 102: - A += "\f"; - break; - case 110: - A += ` -`; - break; - case 114: - A += "\r"; - break; - case 116: - A += " "; - break; - case 117: - const N = y(4); - N >= 0 ? A += String.fromCharCode(N) : g = 4; - break; - default: - g = 5; - } - _ = i; - continue; - } - if (O >= 0 && O <= 31) - if (Xe(O)) { - A += e.substring(_, i), g = 2; - break; - } else - g = 6; - i++; - } - return A; - } - function E() { - if (s = "", g = 0, r = i, f = l, p = u, i >= n) - return r = n, o = 17; - let A = e.charCodeAt(i); - if (un(A)) { - do - i++, s += String.fromCharCode(A), A = e.charCodeAt(i); - while (un(A)); - return o = 15; - } - if (Xe(A)) - return i++, s += String.fromCharCode(A), A === 13 && e.charCodeAt(i) === 10 && (i++, s += ` -`), l++, u = i, o = 14; - switch (A) { - // tokens: []{}:, - case 123: - return i++, o = 1; - case 125: - return i++, o = 2; - case 91: - return i++, o = 3; - case 93: - return i++, o = 4; - case 58: - return i++, o = 6; - case 44: - return i++, o = 5; - // strings - case 34: - return i++, s = b(), o = 10; - // comments - case 47: - const _ = i - 1; - if (e.charCodeAt(i + 1) === 47) { - for (i += 2; i < n && !Xe(e.charCodeAt(i)); ) - i++; - return s = e.substring(_, i), o = 12; - } - if (e.charCodeAt(i + 1) === 42) { - i += 2; - const O = n - 1; - let T = !1; - for (; i < O; ) { - const N = e.charCodeAt(i); - if (N === 42 && e.charCodeAt(i + 1) === 47) { - i += 2, T = !0; - break; - } - i++, Xe(N) && (N === 13 && e.charCodeAt(i) === 10 && i++, l++, u = i); - } - return T || (i++, g = 1), s = e.substring(_, i), o = 13; - } - return s += String.fromCharCode(A), i++, o = 16; - // numbers - case 45: - if (s += String.fromCharCode(A), i++, i === n || !je(e.charCodeAt(i))) - return o = 16; - // found a minus, followed by a number so - // we fall through to proceed with scanning - // numbers - case 48: - case 49: - case 50: - case 51: - case 52: - case 53: - case 54: - case 55: - case 56: - case 57: - return s += k(), o = 11; - // literals and unknown symbols - default: - for (; i < n && B(A); ) - i++, A = e.charCodeAt(i); - if (r !== i) { - switch (s = e.substring(r, i), s) { - case "true": - return o = 8; - case "false": - return o = 9; - case "null": - return o = 7; - } - return o = 16; - } - return s += String.fromCharCode(A), i++, o = 16; - } - } - function B(A) { - if (un(A) || Xe(A)) - return !1; - switch (A) { - case 125: - case 93: - case 123: - case 91: - case 34: - case 58: - case 44: - case 47: - return !1; - } - return !0; - } - function L() { - let A; - do - A = E(); - while (A >= 12 && A <= 15); - return A; - } - return { - setPosition: m, - getPosition: () => i, - scan: t ? L : E, - getToken: () => o, - getTokenValue: () => s, - getTokenOffset: () => r, - getTokenLength: () => i - r, - getTokenStartLine: () => f, - getTokenStartCharacter: () => r - p, - getTokenError: () => g - }; -} -function un(e) { - return e === 32 || e === 9; -} -function Xe(e) { - return e === 10 || e === 13; -} -function je(e) { - return e >= 48 && e <= 57; -} -var hi; -(function(e) { - e[e.lineFeed = 10] = "lineFeed", e[e.carriageReturn = 13] = "carriageReturn", e[e.space = 32] = "space", e[e._0 = 48] = "_0", e[e._1 = 49] = "_1", e[e._2 = 50] = "_2", e[e._3 = 51] = "_3", e[e._4 = 52] = "_4", e[e._5 = 53] = "_5", e[e._6 = 54] = "_6", e[e._7 = 55] = "_7", e[e._8 = 56] = "_8", e[e._9 = 57] = "_9", e[e.a = 97] = "a", e[e.b = 98] = "b", e[e.c = 99] = "c", e[e.d = 100] = "d", e[e.e = 101] = "e", e[e.f = 102] = "f", e[e.g = 103] = "g", e[e.h = 104] = "h", e[e.i = 105] = "i", e[e.j = 106] = "j", e[e.k = 107] = "k", e[e.l = 108] = "l", e[e.m = 109] = "m", e[e.n = 110] = "n", e[e.o = 111] = "o", e[e.p = 112] = "p", e[e.q = 113] = "q", e[e.r = 114] = "r", e[e.s = 115] = "s", e[e.t = 116] = "t", e[e.u = 117] = "u", e[e.v = 118] = "v", e[e.w = 119] = "w", e[e.x = 120] = "x", e[e.y = 121] = "y", e[e.z = 122] = "z", e[e.A = 65] = "A", e[e.B = 66] = "B", e[e.C = 67] = "C", e[e.D = 68] = "D", e[e.E = 69] = "E", e[e.F = 70] = "F", e[e.G = 71] = "G", e[e.H = 72] = "H", e[e.I = 73] = "I", e[e.J = 74] = "J", e[e.K = 75] = "K", e[e.L = 76] = "L", e[e.M = 77] = "M", e[e.N = 78] = "N", e[e.O = 79] = "O", e[e.P = 80] = "P", e[e.Q = 81] = "Q", e[e.R = 82] = "R", e[e.S = 83] = "S", e[e.T = 84] = "T", e[e.U = 85] = "U", e[e.V = 86] = "V", e[e.W = 87] = "W", e[e.X = 88] = "X", e[e.Y = 89] = "Y", e[e.Z = 90] = "Z", e[e.asterisk = 42] = "asterisk", e[e.backslash = 92] = "backslash", e[e.closeBrace = 125] = "closeBrace", e[e.closeBracket = 93] = "closeBracket", e[e.colon = 58] = "colon", e[e.comma = 44] = "comma", e[e.dot = 46] = "dot", e[e.doubleQuote = 34] = "doubleQuote", e[e.minus = 45] = "minus", e[e.openBrace = 123] = "openBrace", e[e.openBracket = 91] = "openBracket", e[e.plus = 43] = "plus", e[e.slash = 47] = "slash", e[e.formFeed = 12] = "formFeed", e[e.tab = 9] = "tab"; -})(hi || (hi = {})); -const Z = new Array(20).fill(0).map((e, t) => " ".repeat(t)), Fe = 200, pi = { - " ": { - "\n": new Array(Fe).fill(0).map((e, t) => ` -` + " ".repeat(t)), - "\r": new Array(Fe).fill(0).map((e, t) => "\r" + " ".repeat(t)), - "\r\n": new Array(Fe).fill(0).map((e, t) => `\r -` + " ".repeat(t)) - }, - " ": { - "\n": new Array(Fe).fill(0).map((e, t) => ` -` + " ".repeat(t)), - "\r": new Array(Fe).fill(0).map((e, t) => "\r" + " ".repeat(t)), - "\r\n": new Array(Fe).fill(0).map((e, t) => `\r -` + " ".repeat(t)) - } -}, Xr = [` -`, "\r", `\r -`]; -function Es(e, t, n) { - let i, s, r, o, l; - if (t) { - for (o = t.offset, l = o + t.length, r = o; r > 0 && !Ut(e, r - 1); ) - r--; - let O = l; - for (; O < e.length && !Ut(e, O); ) - O++; - s = e.substring(r, O), i = Zr(s, n); - } else - s = e, i = 0, r = 0, o = 0, l = e.length; - const f = eo(n, e), u = Xr.includes(f); - let p = 0, g = 0, y; - n.insertSpaces ? y = Z[n.tabSize || 4] ?? Ue(Z[1], n.tabSize || 4) : y = " "; - const m = y === " " ? " " : " "; - let k = zt(s, !1), b = !1; - function E() { - if (p > 1) - return Ue(f, p) + Ue(y, i + g); - const O = y.length * (i + g); - return !u || O > pi[m][f].length ? f + Ue(y, i + g) : O <= 0 ? f : pi[m][f][O]; - } - function B() { - let O = k.scan(); - for (p = 0; O === 15 || O === 14; ) - O === 14 && n.keepLines ? p += 1 : O === 14 && (p = 1), O = k.scan(); - return b = O === 16 || k.getTokenError() !== 0, O; - } - const L = []; - function A(O, T, N) { - !b && (!t || T < l && N > o) && e.substring(T, N) !== O && L.push({ offset: T, length: N - T, content: O }); - } - let _ = B(); - if (n.keepLines && p > 0 && A(Ue(f, p), 0, 0), _ !== 17) { - let O = k.getTokenOffset() + r, T = y.length * i < 20 && n.insertSpaces ? Z[y.length * i] : Ue(y, i); - A(T, r, O); - } - for (; _ !== 17; ) { - let O = k.getTokenOffset() + k.getTokenLength() + r, T = B(), N = "", v = !1; - for (; p === 0 && (T === 12 || T === 13); ) { - let Q = k.getTokenOffset() + r; - A(Z[1], O, Q), O = k.getTokenOffset() + k.getTokenLength() + r, v = T === 12, N = v ? E() : "", T = B(); - } - if (T === 2) - _ !== 1 && g--, n.keepLines && p > 0 || !n.keepLines && _ !== 1 ? N = E() : n.keepLines && (N = Z[1]); - else if (T === 4) - _ !== 3 && g--, n.keepLines && p > 0 || !n.keepLines && _ !== 3 ? N = E() : n.keepLines && (N = Z[1]); - else { - switch (_) { - case 3: - case 1: - g++, n.keepLines && p > 0 || !n.keepLines ? N = E() : N = Z[1]; - break; - case 5: - n.keepLines && p > 0 || !n.keepLines ? N = E() : N = Z[1]; - break; - case 12: - N = E(); - break; - case 13: - p > 0 ? N = E() : v || (N = Z[1]); - break; - case 6: - n.keepLines && p > 0 ? N = E() : v || (N = Z[1]); - break; - case 10: - n.keepLines && p > 0 ? N = E() : T === 6 && !v && (N = ""); - break; - case 7: - case 8: - case 9: - case 11: - case 2: - case 4: - n.keepLines && p > 0 ? N = E() : (T === 12 || T === 13) && !v ? N = Z[1] : T !== 5 && T !== 17 && (b = !0); - break; - case 16: - b = !0; - break; - } - p > 0 && (T === 12 || T === 13) && (N = E()); - } - T === 17 && (n.keepLines && p > 0 ? N = E() : N = n.insertFinalNewline ? f : ""); - const M = k.getTokenOffset() + r; - A(N, O, M), _ = T; - } - return L; -} -function Ue(e, t) { - let n = ""; - for (let i = 0; i < t; i++) - n += e; - return n; -} -function Zr(e, t) { - let n = 0, i = 0; - const s = t.tabSize || 4; - for (; n < e.length; ) { - let r = e.charAt(n); - if (r === Z[1]) - i++; - else if (r === " ") - i += s; - else - break; - n++; - } - return Math.floor(i / s); -} -function eo(e, t) { - for (let n = 0; n < t.length; n++) { - const i = t.charAt(n); - if (i === "\r") - return n + 1 < t.length && t.charAt(n + 1) === ` -` ? `\r -` : "\r"; - if (i === ` -`) - return ` -`; - } - return e && e.eol || ` -`; -} -function Ut(e, t) { - return `\r -`.indexOf(e.charAt(t)) !== -1; -} -var rt; -(function(e) { - e.DEFAULT = { - allowTrailingComma: !1 - }; -})(rt || (rt = {})); -function to(e, t) { - const n = [], i = new Object(); - let s; - const r = { - value: {}, - offset: 0, - length: 0, - type: "object", - parent: void 0 - }; - let o = !1; - function l(f, u, p, g) { - r.value = f, r.offset = u, r.length = p, r.type = g, r.colonOffset = void 0, s = r; - } - try { - Xt(e, { - onObjectBegin: (f, u) => { - if (t <= f) - throw i; - s = void 0, o = t > f, n.push(""); - }, - onObjectProperty: (f, u, p) => { - if (t < u || (l(f, u, p, "property"), n[n.length - 1] = f, t <= u + p)) - throw i; - }, - onObjectEnd: (f, u) => { - if (t <= f) - throw i; - s = void 0, n.pop(); - }, - onArrayBegin: (f, u) => { - if (t <= f) - throw i; - s = void 0, n.push(0); - }, - onArrayEnd: (f, u) => { - if (t <= f) - throw i; - s = void 0, n.pop(); - }, - onLiteralValue: (f, u, p) => { - if (t < u || (l(f, u, p, Is(f)), t <= u + p)) - throw i; - }, - onSeparator: (f, u, p) => { - if (t <= u) - throw i; - if (f === ":" && s && s.type === "property") - s.colonOffset = u, o = !1, s = void 0; - else if (f === ",") { - const g = n[n.length - 1]; - typeof g == "number" ? n[n.length - 1] = g + 1 : (o = !0, n[n.length - 1] = ""), s = void 0; - } - } - }); - } catch (f) { - if (f !== i) - throw f; - } - return { - path: n, - previousNode: s, - isAtPropertyKey: o, - matches: (f) => { - let u = 0; - for (let p = 0; u < f.length && p < n.length; p++) - if (f[u] === n[p] || f[u] === "*") - u++; - else if (f[u] !== "**") - return !1; - return u === f.length; - } - }; -} -function no(e, t = [], n = rt.DEFAULT) { - let i = null, s = []; - const r = []; - function o(f) { - Array.isArray(s) ? s.push(f) : i !== null && (s[i] = f); - } - return Xt(e, { - onObjectBegin: () => { - const f = {}; - o(f), r.push(s), s = f, i = null; - }, - onObjectProperty: (f) => { - i = f; - }, - onObjectEnd: () => { - s = r.pop(); - }, - onArrayBegin: () => { - const f = []; - o(f), r.push(s), s = f, i = null; - }, - onArrayEnd: () => { - s = r.pop(); - }, - onLiteralValue: o, - onError: (f, u, p) => { - t.push({ error: f, offset: u, length: p }); - } - }, n), s[0]; -} -function Ss(e, t = [], n = rt.DEFAULT) { - let i = { type: "array", offset: -1, length: -1, children: [], parent: void 0 }; - function s(f) { - i.type === "property" && (i.length = f - i.offset, i = i.parent); - } - function r(f) { - return i.children.push(f), f; - } - Xt(e, { - onObjectBegin: (f) => { - i = r({ type: "object", offset: f, length: -1, parent: i, children: [] }); - }, - onObjectProperty: (f, u, p) => { - i = r({ type: "property", offset: u, length: -1, parent: i, children: [] }), i.children.push({ type: "string", value: f, offset: u, length: p, parent: i }); - }, - onObjectEnd: (f, u) => { - s(f + u), i.length = f + u - i.offset, i = i.parent, s(f + u); - }, - onArrayBegin: (f, u) => { - i = r({ type: "array", offset: f, length: -1, parent: i, children: [] }); - }, - onArrayEnd: (f, u) => { - i.length = f + u - i.offset, i = i.parent, s(f + u); - }, - onLiteralValue: (f, u, p) => { - r({ type: Is(f), offset: u, length: p, parent: i, value: f }), s(u + p); - }, - onSeparator: (f, u, p) => { - i.type === "property" && (f === ":" ? i.colonOffset = u : f === "," && s(u)); - }, - onError: (f, u, p) => { - t.push({ error: f, offset: u, length: p }); - } - }, n); - const l = i.children[0]; - return l && delete l.parent, l; -} -function wn(e, t) { - if (!e) - return; - let n = e; - for (let i of t) - if (typeof i == "string") { - if (n.type !== "object" || !Array.isArray(n.children)) - return; - let s = !1; - for (const r of n.children) - if (Array.isArray(r.children) && r.children[0].value === i && r.children.length === 2) { - n = r.children[1], s = !0; - break; - } - if (!s) - return; - } else { - const s = i; - if (n.type !== "array" || s < 0 || !Array.isArray(n.children) || s >= n.children.length) - return; - n = n.children[s]; - } - return n; -} -function As(e) { - if (!e.parent || !e.parent.children) - return []; - const t = As(e.parent); - if (e.parent.type === "property") { - const n = e.parent.children[0].value; - t.push(n); - } else if (e.parent.type === "array") { - const n = e.parent.children.indexOf(e); - n !== -1 && t.push(n); - } - return t; -} -function kn(e) { - switch (e.type) { - case "array": - return e.children.map(kn); - case "object": - const t = /* @__PURE__ */ Object.create(null); - for (let n of e.children) { - const i = n.children[1]; - i && (t[n.children[0].value] = kn(i)); - } - return t; - case "null": - case "string": - case "number": - case "boolean": - return e.value; - default: - return; - } -} -function io(e, t, n = !1) { - return t >= e.offset && t < e.offset + e.length || n && t === e.offset + e.length; -} -function Os(e, t, n = !1) { - if (io(e, t, n)) { - const i = e.children; - if (Array.isArray(i)) - for (let s = 0; s < i.length && i[s].offset <= t; s++) { - const r = Os(i[s], t, n); - if (r) - return r; - } - return e; - } -} -function Xt(e, t, n = rt.DEFAULT) { - const i = zt(e, !1), s = []; - let r = 0; - function o(j) { - return j ? () => r === 0 && j(i.getTokenOffset(), i.getTokenLength(), i.getTokenStartLine(), i.getTokenStartCharacter()) : () => !0; - } - function l(j) { - return j ? (V) => r === 0 && j(V, i.getTokenOffset(), i.getTokenLength(), i.getTokenStartLine(), i.getTokenStartCharacter()) : () => !0; - } - function f(j) { - return j ? (V) => r === 0 && j(V, i.getTokenOffset(), i.getTokenLength(), i.getTokenStartLine(), i.getTokenStartCharacter(), () => s.slice()) : () => !0; - } - function u(j) { - return j ? () => { - r > 0 ? r++ : j(i.getTokenOffset(), i.getTokenLength(), i.getTokenStartLine(), i.getTokenStartCharacter(), () => s.slice()) === !1 && (r = 1); - } : () => !0; - } - function p(j) { - return j ? () => { - r > 0 && r--, r === 0 && j(i.getTokenOffset(), i.getTokenLength(), i.getTokenStartLine(), i.getTokenStartCharacter()); - } : () => !0; - } - const g = u(t.onObjectBegin), y = f(t.onObjectProperty), m = p(t.onObjectEnd), k = u(t.onArrayBegin), b = p(t.onArrayEnd), E = f(t.onLiteralValue), B = l(t.onSeparator), L = o(t.onComment), A = l(t.onError), _ = n && n.disallowComments, O = n && n.allowTrailingComma; - function T() { - for (; ; ) { - const j = i.scan(); - switch (i.getTokenError()) { - case 4: - N( - 14 - /* ParseErrorCode.InvalidUnicode */ - ); - break; - case 5: - N( - 15 - /* ParseErrorCode.InvalidEscapeCharacter */ - ); - break; - case 3: - N( - 13 - /* ParseErrorCode.UnexpectedEndOfNumber */ - ); - break; - case 1: - _ || N( - 11 - /* ParseErrorCode.UnexpectedEndOfComment */ - ); - break; - case 2: - N( - 12 - /* ParseErrorCode.UnexpectedEndOfString */ - ); - break; - case 6: - N( - 16 - /* ParseErrorCode.InvalidCharacter */ - ); - break; - } - switch (j) { - case 12: - case 13: - _ ? N( - 10 - /* ParseErrorCode.InvalidCommentToken */ - ) : L(); - break; - case 16: - N( - 1 - /* ParseErrorCode.InvalidSymbol */ - ); - break; - case 15: - case 14: - break; - default: - return j; - } - } - } - function N(j, V = [], pt = []) { - if (A(j), V.length + pt.length > 0) { - let Le = i.getToken(); - for (; Le !== 17; ) { - if (V.indexOf(Le) !== -1) { - T(); - break; - } else if (pt.indexOf(Le) !== -1) - break; - Le = T(); - } - } - } - function v(j) { - const V = i.getTokenValue(); - return j ? E(V) : (y(V), s.push(V)), T(), !0; - } - function M() { - switch (i.getToken()) { - case 11: - const j = i.getTokenValue(); - let V = Number(j); - isNaN(V) && (N( - 2 - /* ParseErrorCode.InvalidNumberFormat */ - ), V = 0), E(V); - break; - case 7: - E(null); - break; - case 8: - E(!0); - break; - case 9: - E(!1); - break; - default: - return !1; - } - return T(), !0; - } - function Q() { - return i.getToken() !== 10 ? (N(3, [], [ - 2, - 5 - /* SyntaxKind.CommaToken */ - ]), !1) : (v(!1), i.getToken() === 6 ? (B(":"), T(), de() || N(4, [], [ - 2, - 5 - /* SyntaxKind.CommaToken */ - ])) : N(5, [], [ - 2, - 5 - /* SyntaxKind.CommaToken */ - ]), s.pop(), !0); - } - function se() { - g(), T(); - let j = !1; - for (; i.getToken() !== 2 && i.getToken() !== 17; ) { - if (i.getToken() === 5) { - if (j || N(4, [], []), B(","), T(), i.getToken() === 2 && O) - break; - } else j && N(6, [], []); - Q() || N(4, [], [ - 2, - 5 - /* SyntaxKind.CommaToken */ - ]), j = !0; - } - return m(), i.getToken() !== 2 ? N(7, [ - 2 - /* SyntaxKind.CloseBraceToken */ - ], []) : T(), !0; - } - function K() { - k(), T(); - let j = !0, V = !1; - for (; i.getToken() !== 4 && i.getToken() !== 17; ) { - if (i.getToken() === 5) { - if (V || N(4, [], []), B(","), T(), i.getToken() === 4 && O) - break; - } else V && N(6, [], []); - j ? (s.push(0), j = !1) : s[s.length - 1]++, de() || N(4, [], [ - 4, - 5 - /* SyntaxKind.CommaToken */ - ]), V = !0; - } - return b(), j || s.pop(), i.getToken() !== 4 ? N(8, [ - 4 - /* SyntaxKind.CloseBracketToken */ - ], []) : T(), !0; - } - function de() { - switch (i.getToken()) { - case 3: - return K(); - case 1: - return se(); - case 10: - return v(!0); - default: - return M(); - } - } - return T(), i.getToken() === 17 ? n.allowEmptyContent ? !0 : (N(4, [], []), !1) : de() ? (i.getToken() !== 17 && N(9, [], []), !0) : (N(4, [], []), !1); -} -function so(e, t) { - let n = zt(e), i = [], s, r = 0, o; - do - switch (o = n.getPosition(), s = n.scan(), s) { - case 12: - case 13: - case 17: - r !== o && i.push(e.substring(r, o)), t !== void 0 && i.push(n.getTokenValue().replace(/[^\r\n]/g, t)), r = n.getPosition(); - break; - } - while (s !== 17); - return i.join(""); -} -function Is(e) { - switch (typeof e) { - case "boolean": - return "boolean"; - case "number": - return "number"; - case "string": - return "string"; - case "object": { - if (e) { - if (Array.isArray(e)) - return "array"; - } else return "null"; - return "object"; - } - default: - return "null"; - } -} -function ro(e, t, n, i) { - const s = t.slice(), o = Ss(e, []); - let l, f; - for (; s.length > 0 && (f = s.pop(), l = wn(o, s), l === void 0 && n !== void 0); ) - typeof f == "string" ? n = { [f]: n } : n = [n]; - if (l) - if (l.type === "object" && typeof f == "string" && Array.isArray(l.children)) { - const u = wn(l, [f]); - if (u !== void 0) - if (n === void 0) { - if (!u.parent) - throw new Error("Malformed AST"); - const p = l.children.indexOf(u.parent); - let g, y = u.parent.offset + u.parent.length; - if (p > 0) { - let m = l.children[p - 1]; - g = m.offset + m.length; - } else - g = l.offset + 1, l.children.length > 1 && (y = l.children[1].offset); - return Ee(e, { offset: g, length: y - g, content: "" }, i); - } else - return Ee(e, { offset: u.offset, length: u.length, content: JSON.stringify(n) }, i); - else { - if (n === void 0) - return []; - const p = `${JSON.stringify(f)}: ${JSON.stringify(n)}`, g = i.getInsertionIndex ? i.getInsertionIndex(l.children.map((m) => m.children[0].value)) : l.children.length; - let y; - if (g > 0) { - let m = l.children[g - 1]; - y = { offset: m.offset + m.length, length: 0, content: "," + p }; - } else l.children.length === 0 ? y = { offset: l.offset + 1, length: 0, content: p } : y = { offset: l.offset + 1, length: 0, content: p + "," }; - return Ee(e, y, i); - } - } else if (l.type === "array" && typeof f == "number" && Array.isArray(l.children)) { - const u = f; - if (u === -1) { - const p = `${JSON.stringify(n)}`; - let g; - if (l.children.length === 0) - g = { offset: l.offset + 1, length: 0, content: p }; - else { - const y = l.children[l.children.length - 1]; - g = { offset: y.offset + y.length, length: 0, content: "," + p }; - } - return Ee(e, g, i); - } else if (n === void 0 && l.children.length >= 0) { - const p = f, g = l.children[p]; - let y; - if (l.children.length === 1) - y = { offset: l.offset + 1, length: l.length - 2, content: "" }; - else if (l.children.length - 1 === p) { - let m = l.children[p - 1], k = m.offset + m.length, b = l.offset + l.length; - y = { offset: k, length: b - 2 - k, content: "" }; - } else - y = { offset: g.offset, length: l.children[p + 1].offset - g.offset, content: "" }; - return Ee(e, y, i); - } else if (n !== void 0) { - let p; - const g = `${JSON.stringify(n)}`; - if (!i.isArrayInsertion && l.children.length > f) { - const y = l.children[f]; - p = { offset: y.offset, length: y.length, content: g }; - } else if (l.children.length === 0 || f === 0) - p = { offset: l.offset + 1, length: 0, content: l.children.length === 0 ? g : g + "," }; - else { - const y = f > l.children.length ? l.children.length : f, m = l.children[y - 1]; - p = { offset: m.offset + m.length, length: 0, content: "," + g }; - } - return Ee(e, p, i); - } else - throw new Error(`Can not ${n === void 0 ? "remove" : i.isArrayInsertion ? "insert" : "modify"} Array index ${u} as length is not sufficient`); - } else - throw new Error(`Can not add ${typeof f != "number" ? "index" : "property"} to parent of type ${l.type}`); - else { - if (n === void 0) - throw new Error("Can not delete in empty document"); - return Ee(e, { offset: o ? o.offset : 0, length: o ? o.length : 0, content: JSON.stringify(n) }, i); - } -} -function Ee(e, t, n) { - if (!n.formattingOptions) - return [t]; - let i = En(e, t), s = t.offset, r = t.offset + t.content.length; - if (t.length === 0 || t.content.length === 0) { - for (; s > 0 && !Ut(i, s - 1); ) - s--; - for (; r < i.length && !Ut(i, r); ) - r++; - } - const o = Es(i, { offset: s, length: r - s }, { ...n.formattingOptions, keepLines: !1 }); - for (let f = o.length - 1; f >= 0; f--) { - const u = o[f]; - i = En(i, u), s = Math.min(s, u.offset), r = Math.max(r, u.offset + u.length), r += u.content.length - u.length; - } - const l = e.length - (i.length - r) - s; - return [{ offset: s, length: l, content: i.substring(s, r) }]; -} -function En(e, t) { - return e.substring(0, t.offset) + t.content + e.substring(t.offset + t.length); -} -const oo = zt; -var Sn; -(function(e) { - e[e.None = 0] = "None", e[e.UnexpectedEndOfComment = 1] = "UnexpectedEndOfComment", e[e.UnexpectedEndOfString = 2] = "UnexpectedEndOfString", e[e.UnexpectedEndOfNumber = 3] = "UnexpectedEndOfNumber", e[e.InvalidUnicode = 4] = "InvalidUnicode", e[e.InvalidEscapeCharacter = 5] = "InvalidEscapeCharacter", e[e.InvalidCharacter = 6] = "InvalidCharacter"; -})(Sn || (Sn = {})); -var An; -(function(e) { - e[e.OpenBraceToken = 1] = "OpenBraceToken", e[e.CloseBraceToken = 2] = "CloseBraceToken", e[e.OpenBracketToken = 3] = "OpenBracketToken", e[e.CloseBracketToken = 4] = "CloseBracketToken", e[e.CommaToken = 5] = "CommaToken", e[e.ColonToken = 6] = "ColonToken", e[e.NullKeyword = 7] = "NullKeyword", e[e.TrueKeyword = 8] = "TrueKeyword", e[e.FalseKeyword = 9] = "FalseKeyword", e[e.StringLiteral = 10] = "StringLiteral", e[e.NumericLiteral = 11] = "NumericLiteral", e[e.LineCommentTrivia = 12] = "LineCommentTrivia", e[e.BlockCommentTrivia = 13] = "BlockCommentTrivia", e[e.LineBreakTrivia = 14] = "LineBreakTrivia", e[e.Trivia = 15] = "Trivia", e[e.Unknown = 16] = "Unknown", e[e.EOF = 17] = "EOF"; -})(An || (An = {})); -const lo = to, ao = no, co = Ss, fo = wn, uo = Os, ho = As, po = kn, go = Xt, yo = so; -var On; -(function(e) { - e[e.InvalidSymbol = 1] = "InvalidSymbol", e[e.InvalidNumberFormat = 2] = "InvalidNumberFormat", e[e.PropertyNameExpected = 3] = "PropertyNameExpected", e[e.ValueExpected = 4] = "ValueExpected", e[e.ColonExpected = 5] = "ColonExpected", e[e.CommaExpected = 6] = "CommaExpected", e[e.CloseBraceExpected = 7] = "CloseBraceExpected", e[e.CloseBracketExpected = 8] = "CloseBracketExpected", e[e.EndOfFileExpected = 9] = "EndOfFileExpected", e[e.InvalidCommentToken = 10] = "InvalidCommentToken", e[e.UnexpectedEndOfComment = 11] = "UnexpectedEndOfComment", e[e.UnexpectedEndOfString = 12] = "UnexpectedEndOfString", e[e.UnexpectedEndOfNumber = 13] = "UnexpectedEndOfNumber", e[e.InvalidUnicode = 14] = "InvalidUnicode", e[e.InvalidEscapeCharacter = 15] = "InvalidEscapeCharacter", e[e.InvalidCharacter = 16] = "InvalidCharacter"; -})(On || (On = {})); -function mo(e) { - switch (e) { - case 1: - return "InvalidSymbol"; - case 2: - return "InvalidNumberFormat"; - case 3: - return "PropertyNameExpected"; - case 4: - return "ValueExpected"; - case 5: - return "ColonExpected"; - case 6: - return "CommaExpected"; - case 7: - return "CloseBraceExpected"; - case 8: - return "CloseBracketExpected"; - case 9: - return "EndOfFileExpected"; - case 10: - return "InvalidCommentToken"; - case 11: - return "UnexpectedEndOfComment"; - case 12: - return "UnexpectedEndOfString"; - case 13: - return "UnexpectedEndOfNumber"; - case 14: - return "InvalidUnicode"; - case 15: - return "InvalidEscapeCharacter"; - case 16: - return "InvalidCharacter"; - } - return ""; -} -function bo(e, t, n) { - return Es(e, t, n); -} -function wo(e, t, n, i) { - return ro(e, t, n, i); -} -function ko(e, t) { - let n = t.slice(0).sort((s, r) => { - const o = s.offset - r.offset; - return o === 0 ? s.length - r.length : o; - }), i = e.length; - for (let s = n.length - 1; s >= 0; s--) { - let r = n[s]; - if (r.offset + r.length <= i) - e = En(e, r); - else - throw new Error("Overlapping edit"); - i = r.offset; - } - return e; -} -const Eo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({ - __proto__: null, - get ParseErrorCode() { - return On; - }, - get ScanError() { - return Sn; - }, - get SyntaxKind() { - return An; - }, - applyEdits: ko, - createScanner: oo, - findNodeAtLocation: fo, - findNodeAtOffset: uo, - format: bo, - getLocation: lo, - getNodePath: ho, - getNodeValue: po, - modify: wo, - parse: ao, - parseTree: co, - printParseErrorCode: mo, - stripComments: yo, - visit: go -}, Symbol.toStringTag, { value: "Module" })), Ts = /* @__PURE__ */ Oi(Eo); -var di; -function So() { - if (di) return Ot; - di = 1, Object.defineProperty(Ot, "__esModule", { value: !0 }), Ot.parseTree = s; - const e = Ts; - var t; - (function(r) { - r.DEFAULT = { - allowTrailingComma: !1 - }; - })(t || (t = {})); - function n(r) { - switch (typeof r) { - case "boolean": - return "boolean"; - case "number": - return "number"; - case "string": - return "string"; - case "object": { - if (r) { - if (Array.isArray(r)) - return "array"; - } else return "null"; - return "object"; - } - default: - return "null"; - } - } - function i(r) { - const o = []; - for (let l = 0; l < r.length; l++) { - const f = r[l]; - if (f.type === "property") - for (let u = 0; u < r.length; u++) { - const p = r[u]; - p.type === "property" && f.children[0].value === p.children[0].value && l !== u && o.push(r[l].children[0]); - } - } - return o; - } - function s(r, o = [], l = t.DEFAULT) { - let f = { - type: "array", - offset: -1, - length: -1, - children: [], - parent: void 0 - }; - function u(m) { - f.type === "property" && (f.length = m - f.offset, f = f.parent); - } - function p(m) { - return f.children.push(m), m; - } - const g = { - onObjectBegin: (m) => { - f = p({ - type: "object", - offset: m, - length: -1, - parent: f, - children: [] - }); - }, - onObjectProperty: (m, k, b) => { - f = p({ - type: "property", - offset: k, - length: -1, - parent: f, - children: [] - }), f.children.push({ - type: "string", - value: m, - offset: k, - length: b, - parent: f - }); - }, - onObjectEnd: (m, k) => { - if (u(m + k), f.type === "object" && f.children && f.children.length > 1) { - const b = i(f.children); - for (const { offset: E, length: B } of b) - o.push({ - error: 0, - extendedError: 1, - offset: E, - length: B - }); - } - f.length = m + k - f.offset, f = f.parent, u(m + k); - }, - onArrayBegin: (m, k) => { - f = p({ - type: "array", - offset: m, - length: -1, - parent: f, - children: [] - }); - }, - onArrayEnd: (m, k) => { - f.length = m + k - f.offset, f = f.parent, u(m + k); - }, - onLiteralValue: (m, k, b) => { - p({ - type: n(m), - offset: k, - length: b, - parent: f, - value: m, - rawValue: r.substring(k, k + b) - }), u(k + b); - }, - onSeparator: (m, k, b) => { - f.type === "property" && (m === ":" ? f.colonOffset = k : m === "," && u(k)); - }, - onError: (m, k, b) => { - o.push({ error: m, offset: k, length: b }); - } - }; - (0, e.visit)(r, g, l); - const y = f.children[0]; - return y && delete y.parent, y; - } - return Ot; -} -var It = {}, gi; -function Ao() { - if (gi) return It; - gi = 1, Object.defineProperty(It, "__esModule", { value: !0 }), It.getCustomTags = i; - const e = qn; - class t { - constructor(r, o) { - this.tag = r, this.type = o; - } - resolve(r, o) { - if ((0, e.isMap)(r) && this.type === "mapping" || (0, e.isSeq)(r) && this.type === "sequence" || typeof r == "string" && this.type === "scalar") - return r; - o(`Unexpected type for tag ${this.tag}: ${typeof r}, expected ${this.type}`); - } - } - class n { - constructor() { - this.tag = "!include", this.type = "scalar"; - } - resolve(r, o) { - if (r && r.length > 0 && r.trim()) - return r; - o("!include without value"); - } - } - function i(s) { - const r = []; - for (const [o, l] of Object.entries(s)) - r.push(new t(o, l)); - return r.push(new n()), r; - } - return It; -} -var yi; -function Oo() { - if (yi) return He; - yi = 1, Object.defineProperty(He, "__esModule", { value: !0 }), He.parseJson = f, He.parseYaml = u; - const e = Hr(), t = zr(), n = ot(), i = So(), s = Ts, r = qn, o = Ao(); - function l(g) { - return g.extendedError ? g.extendedError === 1 ? "DuplicateKey" : "" : s.printParseErrorCode(g.error); - } - function f(g) { - const y = [], m = (0, i.parseTree)(g, y, { - disallowComments: !0, - allowTrailingComma: !1, - allowEmptyContent: !1 - }), k = y.map((b) => ({ - message: l(b), - offset: b.offset, - length: b.length - })); - return m ? [p(t.visitJson, void 0, m), k] : [void 0, k]; - } - function u(g, y) { - const m = r.parseAllDocuments(g, { - customTags: (0, o.getCustomTags)(y || {}) - }); - if (m.length !== 1) - return [void 0, []]; - const k = m[0], b = k.errors.map((B) => ({ - message: B.message, - offset: B.pos[0], - length: B.pos[1] - B.pos[0] - })); - return r.visit(k, { - Alias(B, L) { - L.resolve(k) || b.push({ - message: `Alias "${B}" could not be resolved`, - offset: L.range[0], - length: L.range[1] - L.range[0] - }); - } - }), [p(e.visitYaml, k, k.contents), b]; - } - function p(g, y, m) { - var k; - let b = {}; - const E = [b]; - if (g(y, null, "fakeroot", m, { - onObjectStart: (L, A, _, O) => { - O && (0, n.setPreservedLocation)(b, A, O), E.push(b), b = b[A] = {}; - }, - onObjectEnd: () => { - b = E.pop(); - }, - onArrayStart: (L, A, _, O) => { - O && (0, n.setPreservedLocation)(b, A, O), E.push(b), b = b[A] = []; - }, - onArrayEnd: () => { - b = E.pop(); - }, - onValue: (L, A, _, O, T) => { - b[A] = _, typeof _ == "number" && O !== void 0 && (0, n.setPreservedValue)(b, A, O), T && (0, n.setPreservedLocation)(b, A, T); - } - }), typeof E[0].fakeroot != "object") - return; - const B = (k = (0, n.getPreservedLocation)(E[0], "fakeroot")) === null || k === void 0 ? void 0 : k.value; - return (0, n.setPreservedRootRange)(E[0].fakeroot, B), E[0].fakeroot; - } - return He; -} -var Tt = {}, mi; -function Io() { - if (mi) return Tt; - mi = 1, Object.defineProperty(Tt, "__esModule", { value: !0 }), Tt.stringify = t; - const e = Ti(); - function t(l, f = 0) { - return f === 0 ? n(l) : i(l, f); - } - function n(l) { - if (!l) - return JSON.stringify(l); - const f = []; - return (0, e.visitObject)(void 0, "fakeroot", l, { - onObjectStart: (u, p, g) => { - f.push(r(p, "{")); - }, - onObjectEnd: () => { - f[f.length - 1].endsWith(",") && s(f, 1), f.push("},"); - }, - onArrayStart: (u, p, g) => { - f.push(r(p, "[")); - }, - onArrayEnd: () => { - f[f.length - 1].endsWith(",") && s(f, 1), f.push("],"); - }, - onValue: (u, p, g, y) => { - y !== void 0 ? f.push(r(p, y) + ",") : f.push(r(p, JSON.stringify(g)) + ","); - } - }), f[0] = f[0].slice(11), s(f, 1), f.join(""); - } - function i(l, f) { - if (!l) - return JSON.stringify(l); - const u = []; - let p = 0; - const g = [!0]; - return (0, e.visitObject)(void 0, "fakeroot", l, { - onObjectStart: (y, m, k) => { - u.push(o(f, p) + r(m, `{ -`, !1)), g[g.length - 1] = !1, g.push(!0), p++; - }, - onObjectEnd: () => { - p--, g.pop() ? (s(u, 1), u.push(`}, -`)) : (s(u, 2), u.push(` -` + o(f, p) + `}, -`)); - }, - onArrayStart: (y, m, k) => { - u.push(o(f, p) + r(m, `[ -`, !1)), g[g.length - 1] = !1, g.push(!0), p++; - }, - onArrayEnd: () => { - p--, g.pop() ? (s(u, 1), u.push(`], -`)) : (s(u, 2), u.push(` -` + o(f, p) + `], -`)); - }, - onValue: (y, m, k, b) => { - g[g.length - 1] = !1, b !== void 0 ? u.push(o(f, p) + r(m, b, !1) + `, -`) : u.push(o(f, p) + r(m, JSON.stringify(k), !1) + `, -`); - } - }), u[0] = u[0].slice(12), s(u, 2), u.join(""); - } - function s(l, f) { - const u = l.length - 1; - l[u] = l[u].slice(0, -f); - } - function r(l, f, u = !0) { - const p = u ? ":" : ": "; - return typeof l == "string" ? JSON.stringify(l) + p + f : f; - } - function o(l, f) { - return " ".repeat(l * f); - } - return Tt; -} -var Me = {}, Se = {}, bi; -function Ns() { - if (bi) return Se; - bi = 1, Object.defineProperty(Se, "__esModule", { value: !0 }), Se.joinJsonPointer = i, Se.parseJsonPointer = s, Se.findByPath = r, Se.find = o; - const e = /\//g, t = /~/g; - function n(l) { - return typeof l == "number" ? String(l) : l.replace(t, "~0").replace(e, "~1"); - } - function i(l) { - return l.length == 0 ? "" : "/" + l.map((f) => n(f)).join("/"); - } - function s(l) { - const f = /~/, u = /~[01]/g; - function p(y) { - switch (y) { - case "~1": - return "/"; - case "~0": - return "~"; - } - throw new Error("Invalid tilde escape: " + y); - } - function g(y) { - return f.test(y) ? y.replace(u, p) : y; - } - return l.split("/").slice(1).map(g).map(decodeURIComponent); - } - function r(l, f) { - let u = l; - for (const p of f) - if (typeof u == "object" && u !== null) - if (Array.isArray(u)) { - const g = typeof p == "string" ? parseInt(p, 10) : p; - if (isNaN(g)) - return; - u = u[g]; - } else if (u.hasOwnProperty(p)) - u = u[p]; - else - return; - else - return; - return u; - } - function o(l, f) { - return r(l, s(f)); - } - return Se; -} -var wi; -function To() { - if (wi) return Me; - wi = 1, Object.defineProperty(Me, "__esModule", { value: !0 }), Me.findNodeAtOffset = i, Me.findLocationForPath = r, Me.findLocationForJsonPointer = o; - const e = ot(), t = Ns(); - function n(l, f) { - return f >= l.start && f <= l.end; - } - function i(l, f) { - const u = { value: (0, e.getPreservedRootRange)(l) }; - return s(l, f, [], u); - } - function s(l, f, u, p) { - const g = Array.isArray(l) ? l.keys() : Object.keys(l); - for (const y of g) { - const m = (0, e.getPreservedLocation)(l, y); - if (m && n(m.value, f)) { - const k = l[y]; - return u.push(y), k !== null && typeof k == "object" ? s(k, f, u, m) : [k, u, m]; - } - } - return [l, u, p]; - } - function r(l, f) { - if (f.length === 0) - return { value: (0, e.getPreservedRootRange)(l) }; - let u = l, p = 0; - for (; p < f.length - 1 && u; ) - u = u[f[p]], p++; - if (u) - return (0, e.getPreservedLocation)(u, f[p]); - } - function o(l, f) { - return r(l, (0, t.parseJsonPointer)(f)); - } - return Me; -} -var ki; -function No() { - return ki || (ki = 1, (function(e) { - Object.defineProperty(e, "__esModule", { value: !0 }), e.parseJsonPointer = e.joinJsonPointer = e.findLocationForPath = e.findByPath = e.findLocationForJsonPointer = e.find = e.findNodeAtOffset = e.getRootRange = e.getLocation = e.simpleClone = e.stringify = e.parseYaml = e.parseJson = void 0, e.parse = l; - const t = Vs(); - Object.defineProperty(e, "simpleClone", { enumerable: !0, get: function() { - return t.simpleClone; - } }); - const n = Oo(); - Object.defineProperty(e, "parseJson", { enumerable: !0, get: function() { - return n.parseJson; - } }), Object.defineProperty(e, "parseYaml", { enumerable: !0, get: function() { - return n.parseYaml; - } }); - const i = Io(); - Object.defineProperty(e, "stringify", { enumerable: !0, get: function() { - return i.stringify; - } }); - const s = ot(); - Object.defineProperty(e, "getLocation", { enumerable: !0, get: function() { - return s.getPreservedLocation; - } }), Object.defineProperty(e, "getRootRange", { enumerable: !0, get: function() { - return s.getPreservedRootRange; - } }); - const r = To(); - Object.defineProperty(e, "findLocationForJsonPointer", { enumerable: !0, get: function() { - return r.findLocationForJsonPointer; - } }), Object.defineProperty(e, "findLocationForPath", { enumerable: !0, get: function() { - return r.findLocationForPath; - } }), Object.defineProperty(e, "findNodeAtOffset", { enumerable: !0, get: function() { - return r.findNodeAtOffset; - } }); - const o = Ns(); - Object.defineProperty(e, "find", { enumerable: !0, get: function() { - return o.find; - } }), Object.defineProperty(e, "joinJsonPointer", { enumerable: !0, get: function() { - return o.joinJsonPointer; - } }), Object.defineProperty(e, "parseJsonPointer", { enumerable: !0, get: function() { - return o.parseJsonPointer; - } }), Object.defineProperty(e, "findByPath", { enumerable: !0, get: function() { - return o.findByPath; - } }); - function l(f, u, p) { - var g; - return u === "yaml" ? (0, n.parseYaml)(f, (g = p?.yaml) === null || g === void 0 ? void 0 : g.customTags) : (0, n.parseJson)(f); - } - })(nn)), nn; -} -var Ro = No(), hn = {}, Ze = {}, Ei; -function Bo() { - if (Ei) return Ze; - Ei = 1, Ze.byteLength = l, Ze.toByteArray = u, Ze.fromByteArray = y; - for (var e = [], t = [], n = typeof Uint8Array < "u" ? Uint8Array : Array, i = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", s = 0, r = i.length; s < r; ++s) - e[s] = i[s], t[i.charCodeAt(s)] = s; - t[45] = 62, t[95] = 63; - function o(m) { - var k = m.length; - if (k % 4 > 0) - throw new Error("Invalid string. Length must be a multiple of 4"); - var b = m.indexOf("="); - b === -1 && (b = k); - var E = b === k ? 0 : 4 - b % 4; - return [b, E]; - } - function l(m) { - var k = o(m), b = k[0], E = k[1]; - return (b + E) * 3 / 4 - E; - } - function f(m, k, b) { - return (k + b) * 3 / 4 - b; - } - function u(m) { - var k, b = o(m), E = b[0], B = b[1], L = new n(f(m, E, B)), A = 0, _ = B > 0 ? E - 4 : E, O; - for (O = 0; O < _; O += 4) - k = t[m.charCodeAt(O)] << 18 | t[m.charCodeAt(O + 1)] << 12 | t[m.charCodeAt(O + 2)] << 6 | t[m.charCodeAt(O + 3)], L[A++] = k >> 16 & 255, L[A++] = k >> 8 & 255, L[A++] = k & 255; - return B === 2 && (k = t[m.charCodeAt(O)] << 2 | t[m.charCodeAt(O + 1)] >> 4, L[A++] = k & 255), B === 1 && (k = t[m.charCodeAt(O)] << 10 | t[m.charCodeAt(O + 1)] << 4 | t[m.charCodeAt(O + 2)] >> 2, L[A++] = k >> 8 & 255, L[A++] = k & 255), L; - } - function p(m) { - return e[m >> 18 & 63] + e[m >> 12 & 63] + e[m >> 6 & 63] + e[m & 63]; - } - function g(m, k, b) { - for (var E, B = [], L = k; L < b; L += 3) - E = (m[L] << 16 & 16711680) + (m[L + 1] << 8 & 65280) + (m[L + 2] & 255), B.push(p(E)); - return B.join(""); - } - function y(m) { - for (var k, b = m.length, E = b % 3, B = [], L = 16383, A = 0, _ = b - E; A < _; A += L) - B.push(g(m, A, A + L > _ ? _ : A + L)); - return E === 1 ? (k = m[b - 1], B.push( - e[k >> 2] + e[k << 4 & 63] + "==" - )) : E === 2 && (k = (m[b - 2] << 8) + m[b - 1], B.push( - e[k >> 10] + e[k >> 4 & 63] + e[k << 2 & 63] + "=" - )), B.join(""); - } - return Ze; -} -var Nt = {}; -var Si; -function Lo() { - return Si || (Si = 1, Nt.read = function(e, t, n, i, s) { - var r, o, l = s * 8 - i - 1, f = (1 << l) - 1, u = f >> 1, p = -7, g = n ? s - 1 : 0, y = n ? -1 : 1, m = e[t + g]; - for (g += y, r = m & (1 << -p) - 1, m >>= -p, p += l; p > 0; r = r * 256 + e[t + g], g += y, p -= 8) - ; - for (o = r & (1 << -p) - 1, r >>= -p, p += i; p > 0; o = o * 256 + e[t + g], g += y, p -= 8) - ; - if (r === 0) - r = 1 - u; - else { - if (r === f) - return o ? NaN : (m ? -1 : 1) * (1 / 0); - o = o + Math.pow(2, i), r = r - u; - } - return (m ? -1 : 1) * o * Math.pow(2, r - i); - }, Nt.write = function(e, t, n, i, s, r) { - var o, l, f, u = r * 8 - s - 1, p = (1 << u) - 1, g = p >> 1, y = s === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, m = i ? 0 : r - 1, k = i ? 1 : -1, b = t < 0 || t === 0 && 1 / t < 0 ? 1 : 0; - for (t = Math.abs(t), isNaN(t) || t === 1 / 0 ? (l = isNaN(t) ? 1 : 0, o = p) : (o = Math.floor(Math.log(t) / Math.LN2), t * (f = Math.pow(2, -o)) < 1 && (o--, f *= 2), o + g >= 1 ? t += y / f : t += y * Math.pow(2, 1 - g), t * f >= 2 && (o++, f /= 2), o + g >= p ? (l = 0, o = p) : o + g >= 1 ? (l = (t * f - 1) * Math.pow(2, s), o = o + g) : (l = t * Math.pow(2, g - 1) * Math.pow(2, s), o = 0)); s >= 8; e[n + m] = l & 255, m += k, l /= 256, s -= 8) - ; - for (o = o << s | l, u += s; u > 0; e[n + m] = o & 255, m += k, o /= 256, u -= 8) - ; - e[n + m - k] |= b * 128; - }), Nt; -} -var Ai; -function xo() { - return Ai || (Ai = 1, (function(e) { - const t = Bo(), n = Lo(), i = typeof Symbol == "function" && typeof Symbol.for == "function" ? /* @__PURE__ */ Symbol.for("nodejs.util.inspect.custom") : null; - e.Buffer = l, e.SlowBuffer = L, e.INSPECT_MAX_BYTES = 50; - const s = 2147483647; - e.kMaxLength = s, l.TYPED_ARRAY_SUPPORT = r(), !l.TYPED_ARRAY_SUPPORT && typeof console < "u" && typeof console.error == "function" && console.error( - "This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support." - ); - function r() { - try { - const h = new Uint8Array(1), a = { foo: function() { - return 42; - } }; - return Object.setPrototypeOf(a, Uint8Array.prototype), Object.setPrototypeOf(h, a), h.foo() === 42; - } catch { - return !1; - } - } - Object.defineProperty(l.prototype, "parent", { - enumerable: !0, - get: function() { - if (l.isBuffer(this)) - return this.buffer; - } - }), Object.defineProperty(l.prototype, "offset", { - enumerable: !0, - get: function() { - if (l.isBuffer(this)) - return this.byteOffset; - } - }); - function o(h) { - if (h > s) - throw new RangeError('The value "' + h + '" is invalid for option "size"'); - const a = new Uint8Array(h); - return Object.setPrototypeOf(a, l.prototype), a; - } - function l(h, a, c) { - if (typeof h == "number") { - if (typeof a == "string") - throw new TypeError( - 'The "string" argument must be of type string. Received type number' - ); - return g(h); - } - return f(h, a, c); - } - l.poolSize = 8192; - function f(h, a, c) { - if (typeof h == "string") - return y(h, a); - if (ArrayBuffer.isView(h)) - return k(h); - if (h == null) - throw new TypeError( - "The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof h - ); - if (re(h, ArrayBuffer) || h && re(h.buffer, ArrayBuffer) || typeof SharedArrayBuffer < "u" && (re(h, SharedArrayBuffer) || h && re(h.buffer, SharedArrayBuffer))) - return b(h, a, c); - if (typeof h == "number") - throw new TypeError( - 'The "value" argument must not be of type number. Received type number' - ); - const d = h.valueOf && h.valueOf(); - if (d != null && d !== h) - return l.from(d, a, c); - const w = E(h); - if (w) return w; - if (typeof Symbol < "u" && Symbol.toPrimitive != null && typeof h[Symbol.toPrimitive] == "function") - return l.from(h[Symbol.toPrimitive]("string"), a, c); - throw new TypeError( - "The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof h - ); - } - l.from = function(h, a, c) { - return f(h, a, c); - }, Object.setPrototypeOf(l.prototype, Uint8Array.prototype), Object.setPrototypeOf(l, Uint8Array); - function u(h) { - if (typeof h != "number") - throw new TypeError('"size" argument must be of type number'); - if (h < 0) - throw new RangeError('The value "' + h + '" is invalid for option "size"'); - } - function p(h, a, c) { - return u(h), h <= 0 ? o(h) : a !== void 0 ? typeof c == "string" ? o(h).fill(a, c) : o(h).fill(a) : o(h); - } - l.alloc = function(h, a, c) { - return p(h, a, c); - }; - function g(h) { - return u(h), o(h < 0 ? 0 : B(h) | 0); - } - l.allocUnsafe = function(h) { - return g(h); - }, l.allocUnsafeSlow = function(h) { - return g(h); - }; - function y(h, a) { - if ((typeof a != "string" || a === "") && (a = "utf8"), !l.isEncoding(a)) - throw new TypeError("Unknown encoding: " + a); - const c = A(h, a) | 0; - let d = o(c); - const w = d.write(h, a); - return w !== c && (d = d.slice(0, w)), d; - } - function m(h) { - const a = h.length < 0 ? 0 : B(h.length) | 0, c = o(a); - for (let d = 0; d < a; d += 1) - c[d] = h[d] & 255; - return c; - } - function k(h) { - if (re(h, Uint8Array)) { - const a = new Uint8Array(h); - return b(a.buffer, a.byteOffset, a.byteLength); - } - return m(h); - } - function b(h, a, c) { - if (a < 0 || h.byteLength < a) - throw new RangeError('"offset" is outside of buffer bounds'); - if (h.byteLength < a + (c || 0)) - throw new RangeError('"length" is outside of buffer bounds'); - let d; - return a === void 0 && c === void 0 ? d = new Uint8Array(h) : c === void 0 ? d = new Uint8Array(h, a) : d = new Uint8Array(h, a, c), Object.setPrototypeOf(d, l.prototype), d; - } - function E(h) { - if (l.isBuffer(h)) { - const a = B(h.length) | 0, c = o(a); - return c.length === 0 || h.copy(c, 0, 0, a), c; - } - if (h.length !== void 0) - return typeof h.length != "number" || tn(h.length) ? o(0) : m(h); - if (h.type === "Buffer" && Array.isArray(h.data)) - return m(h.data); - } - function B(h) { - if (h >= s) - throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + s.toString(16) + " bytes"); - return h | 0; - } - function L(h) { - return +h != h && (h = 0), l.alloc(+h); - } - l.isBuffer = function(a) { - return a != null && a._isBuffer === !0 && a !== l.prototype; - }, l.compare = function(a, c) { - if (re(a, Uint8Array) && (a = l.from(a, a.offset, a.byteLength)), re(c, Uint8Array) && (c = l.from(c, c.offset, c.byteLength)), !l.isBuffer(a) || !l.isBuffer(c)) - throw new TypeError( - 'The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array' - ); - if (a === c) return 0; - let d = a.length, w = c.length; - for (let S = 0, I = Math.min(d, w); S < I; ++S) - if (a[S] !== c[S]) { - d = a[S], w = c[S]; - break; - } - return d < w ? -1 : w < d ? 1 : 0; - }, l.isEncoding = function(a) { - switch (String(a).toLowerCase()) { - case "hex": - case "utf8": - case "utf-8": - case "ascii": - case "latin1": - case "binary": - case "base64": - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return !0; - default: - return !1; - } - }, l.concat = function(a, c) { - if (!Array.isArray(a)) - throw new TypeError('"list" argument must be an Array of Buffers'); - if (a.length === 0) - return l.alloc(0); - let d; - if (c === void 0) - for (c = 0, d = 0; d < a.length; ++d) - c += a[d].length; - const w = l.allocUnsafe(c); - let S = 0; - for (d = 0; d < a.length; ++d) { - let I = a[d]; - if (re(I, Uint8Array)) - S + I.length > w.length ? (l.isBuffer(I) || (I = l.from(I)), I.copy(w, S)) : Uint8Array.prototype.set.call( - w, - I, - S - ); - else if (l.isBuffer(I)) - I.copy(w, S); - else - throw new TypeError('"list" argument must be an Array of Buffers'); - S += I.length; - } - return w; - }; - function A(h, a) { - if (l.isBuffer(h)) - return h.length; - if (ArrayBuffer.isView(h) || re(h, ArrayBuffer)) - return h.byteLength; - if (typeof h != "string") - throw new TypeError( - 'The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ' + typeof h - ); - const c = h.length, d = arguments.length > 2 && arguments[2] === !0; - if (!d && c === 0) return 0; - let w = !1; - for (; ; ) - switch (a) { - case "ascii": - case "latin1": - case "binary": - return c; - case "utf8": - case "utf-8": - return en(h).length; - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return c * 2; - case "hex": - return c >>> 1; - case "base64": - return Qn(h).length; - default: - if (w) - return d ? -1 : en(h).length; - a = ("" + a).toLowerCase(), w = !0; - } - } - l.byteLength = A; - function _(h, a, c) { - let d = !1; - if ((a === void 0 || a < 0) && (a = 0), a > this.length || ((c === void 0 || c > this.length) && (c = this.length), c <= 0) || (c >>>= 0, a >>>= 0, c <= a)) - return ""; - for (h || (h = "utf8"); ; ) - switch (h) { - case "hex": - return Ls(this, a, c); - case "utf8": - case "utf-8": - return j(this, a, c); - case "ascii": - return Le(this, a, c); - case "latin1": - case "binary": - return Bs(this, a, c); - case "base64": - return de(this, a, c); - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return _s(this, a, c); - default: - if (d) throw new TypeError("Unknown encoding: " + h); - h = (h + "").toLowerCase(), d = !0; - } - } - l.prototype._isBuffer = !0; - function O(h, a, c) { - const d = h[a]; - h[a] = h[c], h[c] = d; - } - l.prototype.swap16 = function() { - const a = this.length; - if (a % 2 !== 0) - throw new RangeError("Buffer size must be a multiple of 16-bits"); - for (let c = 0; c < a; c += 2) - O(this, c, c + 1); - return this; - }, l.prototype.swap32 = function() { - const a = this.length; - if (a % 4 !== 0) - throw new RangeError("Buffer size must be a multiple of 32-bits"); - for (let c = 0; c < a; c += 4) - O(this, c, c + 3), O(this, c + 1, c + 2); - return this; - }, l.prototype.swap64 = function() { - const a = this.length; - if (a % 8 !== 0) - throw new RangeError("Buffer size must be a multiple of 64-bits"); - for (let c = 0; c < a; c += 8) - O(this, c, c + 7), O(this, c + 1, c + 6), O(this, c + 2, c + 5), O(this, c + 3, c + 4); - return this; - }, l.prototype.toString = function() { - const a = this.length; - return a === 0 ? "" : arguments.length === 0 ? j(this, 0, a) : _.apply(this, arguments); - }, l.prototype.toLocaleString = l.prototype.toString, l.prototype.equals = function(a) { - if (!l.isBuffer(a)) throw new TypeError("Argument must be a Buffer"); - return this === a ? !0 : l.compare(this, a) === 0; - }, l.prototype.inspect = function() { - let a = ""; - const c = e.INSPECT_MAX_BYTES; - return a = this.toString("hex", 0, c).replace(/(.{2})/g, "$1 ").trim(), this.length > c && (a += " ... "), ""; - }, i && (l.prototype[i] = l.prototype.inspect), l.prototype.compare = function(a, c, d, w, S) { - if (re(a, Uint8Array) && (a = l.from(a, a.offset, a.byteLength)), !l.isBuffer(a)) - throw new TypeError( - 'The "target" argument must be one of type Buffer or Uint8Array. Received type ' + typeof a - ); - if (c === void 0 && (c = 0), d === void 0 && (d = a ? a.length : 0), w === void 0 && (w = 0), S === void 0 && (S = this.length), c < 0 || d > a.length || w < 0 || S > this.length) - throw new RangeError("out of range index"); - if (w >= S && c >= d) - return 0; - if (w >= S) - return -1; - if (c >= d) - return 1; - if (c >>>= 0, d >>>= 0, w >>>= 0, S >>>= 0, this === a) return 0; - let I = S - w, P = d - c; - const J = Math.min(I, P), D = this.slice(w, S), Y = a.slice(c, d); - for (let U = 0; U < J; ++U) - if (D[U] !== Y[U]) { - I = D[U], P = Y[U]; - break; - } - return I < P ? -1 : P < I ? 1 : 0; - }; - function T(h, a, c, d, w) { - if (h.length === 0) return -1; - if (typeof c == "string" ? (d = c, c = 0) : c > 2147483647 ? c = 2147483647 : c < -2147483648 && (c = -2147483648), c = +c, tn(c) && (c = w ? 0 : h.length - 1), c < 0 && (c = h.length + c), c >= h.length) { - if (w) return -1; - c = h.length - 1; - } else if (c < 0) - if (w) c = 0; - else return -1; - if (typeof a == "string" && (a = l.from(a, d)), l.isBuffer(a)) - return a.length === 0 ? -1 : N(h, a, c, d, w); - if (typeof a == "number") - return a = a & 255, typeof Uint8Array.prototype.indexOf == "function" ? w ? Uint8Array.prototype.indexOf.call(h, a, c) : Uint8Array.prototype.lastIndexOf.call(h, a, c) : N(h, [a], c, d, w); - throw new TypeError("val must be string, number or Buffer"); - } - function N(h, a, c, d, w) { - let S = 1, I = h.length, P = a.length; - if (d !== void 0 && (d = String(d).toLowerCase(), d === "ucs2" || d === "ucs-2" || d === "utf16le" || d === "utf-16le")) { - if (h.length < 2 || a.length < 2) - return -1; - S = 2, I /= 2, P /= 2, c /= 2; - } - function J(Y, U) { - return S === 1 ? Y[U] : Y.readUInt16BE(U * S); - } - let D; - if (w) { - let Y = -1; - for (D = c; D < I; D++) - if (J(h, D) === J(a, Y === -1 ? 0 : D - Y)) { - if (Y === -1 && (Y = D), D - Y + 1 === P) return Y * S; - } else - Y !== -1 && (D -= D - Y), Y = -1; - } else - for (c + P > I && (c = I - P), D = c; D >= 0; D--) { - let Y = !0; - for (let U = 0; U < P; U++) - if (J(h, D + U) !== J(a, U)) { - Y = !1; - break; - } - if (Y) return D; - } - return -1; - } - l.prototype.includes = function(a, c, d) { - return this.indexOf(a, c, d) !== -1; - }, l.prototype.indexOf = function(a, c, d) { - return T(this, a, c, d, !0); - }, l.prototype.lastIndexOf = function(a, c, d) { - return T(this, a, c, d, !1); - }; - function v(h, a, c, d) { - c = Number(c) || 0; - const w = h.length - c; - d ? (d = Number(d), d > w && (d = w)) : d = w; - const S = a.length; - d > S / 2 && (d = S / 2); - let I; - for (I = 0; I < d; ++I) { - const P = parseInt(a.substr(I * 2, 2), 16); - if (tn(P)) return I; - h[c + I] = P; - } - return I; - } - function M(h, a, c, d) { - return dt(en(a, h.length - c), h, c, d); - } - function Q(h, a, c, d) { - return dt(js(a), h, c, d); - } - function se(h, a, c, d) { - return dt(Qn(a), h, c, d); - } - function K(h, a, c, d) { - return dt(Fs(a, h.length - c), h, c, d); - } - l.prototype.write = function(a, c, d, w) { - if (c === void 0) - w = "utf8", d = this.length, c = 0; - else if (d === void 0 && typeof c == "string") - w = c, d = this.length, c = 0; - else if (isFinite(c)) - c = c >>> 0, isFinite(d) ? (d = d >>> 0, w === void 0 && (w = "utf8")) : (w = d, d = void 0); - else - throw new Error( - "Buffer.write(string, encoding, offset[, length]) is no longer supported" - ); - const S = this.length - c; - if ((d === void 0 || d > S) && (d = S), a.length > 0 && (d < 0 || c < 0) || c > this.length) - throw new RangeError("Attempt to write outside buffer bounds"); - w || (w = "utf8"); - let I = !1; - for (; ; ) - switch (w) { - case "hex": - return v(this, a, c, d); - case "utf8": - case "utf-8": - return M(this, a, c, d); - case "ascii": - case "latin1": - case "binary": - return Q(this, a, c, d); - case "base64": - return se(this, a, c, d); - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return K(this, a, c, d); - default: - if (I) throw new TypeError("Unknown encoding: " + w); - w = ("" + w).toLowerCase(), I = !0; - } - }, l.prototype.toJSON = function() { - return { - type: "Buffer", - data: Array.prototype.slice.call(this._arr || this, 0) - }; - }; - function de(h, a, c) { - return a === 0 && c === h.length ? t.fromByteArray(h) : t.fromByteArray(h.slice(a, c)); - } - function j(h, a, c) { - c = Math.min(h.length, c); - const d = []; - let w = a; - for (; w < c; ) { - const S = h[w]; - let I = null, P = S > 239 ? 4 : S > 223 ? 3 : S > 191 ? 2 : 1; - if (w + P <= c) { - let J, D, Y, U; - switch (P) { - case 1: - S < 128 && (I = S); - break; - case 2: - J = h[w + 1], (J & 192) === 128 && (U = (S & 31) << 6 | J & 63, U > 127 && (I = U)); - break; - case 3: - J = h[w + 1], D = h[w + 2], (J & 192) === 128 && (D & 192) === 128 && (U = (S & 15) << 12 | (J & 63) << 6 | D & 63, U > 2047 && (U < 55296 || U > 57343) && (I = U)); - break; - case 4: - J = h[w + 1], D = h[w + 2], Y = h[w + 3], (J & 192) === 128 && (D & 192) === 128 && (Y & 192) === 128 && (U = (S & 15) << 18 | (J & 63) << 12 | (D & 63) << 6 | Y & 63, U > 65535 && U < 1114112 && (I = U)); - } - } - I === null ? (I = 65533, P = 1) : I > 65535 && (I -= 65536, d.push(I >>> 10 & 1023 | 55296), I = 56320 | I & 1023), d.push(I), w += P; - } - return pt(d); - } - const V = 4096; - function pt(h) { - const a = h.length; - if (a <= V) - return String.fromCharCode.apply(String, h); - let c = "", d = 0; - for (; d < a; ) - c += String.fromCharCode.apply( - String, - h.slice(d, d += V) - ); - return c; - } - function Le(h, a, c) { - let d = ""; - c = Math.min(h.length, c); - for (let w = a; w < c; ++w) - d += String.fromCharCode(h[w] & 127); - return d; - } - function Bs(h, a, c) { - let d = ""; - c = Math.min(h.length, c); - for (let w = a; w < c; ++w) - d += String.fromCharCode(h[w]); - return d; - } - function Ls(h, a, c) { - const d = h.length; - (!a || a < 0) && (a = 0), (!c || c < 0 || c > d) && (c = d); - let w = ""; - for (let S = a; S < c; ++S) - w += Us[h[S]]; - return w; - } - function _s(h, a, c) { - const d = h.slice(a, c); - let w = ""; - for (let S = 0; S < d.length - 1; S += 2) - w += String.fromCharCode(d[S] + d[S + 1] * 256); - return w; - } - l.prototype.slice = function(a, c) { - const d = this.length; - a = ~~a, c = c === void 0 ? d : ~~c, a < 0 ? (a += d, a < 0 && (a = 0)) : a > d && (a = d), c < 0 ? (c += d, c < 0 && (c = 0)) : c > d && (c = d), c < a && (c = a); - const w = this.subarray(a, c); - return Object.setPrototypeOf(w, l.prototype), w; - }; - function G(h, a, c) { - if (h % 1 !== 0 || h < 0) throw new RangeError("offset is not uint"); - if (h + a > c) throw new RangeError("Trying to access beyond buffer length"); - } - l.prototype.readUintLE = l.prototype.readUIntLE = function(a, c, d) { - a = a >>> 0, c = c >>> 0, d || G(a, c, this.length); - let w = this[a], S = 1, I = 0; - for (; ++I < c && (S *= 256); ) - w += this[a + I] * S; - return w; - }, l.prototype.readUintBE = l.prototype.readUIntBE = function(a, c, d) { - a = a >>> 0, c = c >>> 0, d || G(a, c, this.length); - let w = this[a + --c], S = 1; - for (; c > 0 && (S *= 256); ) - w += this[a + --c] * S; - return w; - }, l.prototype.readUint8 = l.prototype.readUInt8 = function(a, c) { - return a = a >>> 0, c || G(a, 1, this.length), this[a]; - }, l.prototype.readUint16LE = l.prototype.readUInt16LE = function(a, c) { - return a = a >>> 0, c || G(a, 2, this.length), this[a] | this[a + 1] << 8; - }, l.prototype.readUint16BE = l.prototype.readUInt16BE = function(a, c) { - return a = a >>> 0, c || G(a, 2, this.length), this[a] << 8 | this[a + 1]; - }, l.prototype.readUint32LE = l.prototype.readUInt32LE = function(a, c) { - return a = a >>> 0, c || G(a, 4, this.length), (this[a] | this[a + 1] << 8 | this[a + 2] << 16) + this[a + 3] * 16777216; - }, l.prototype.readUint32BE = l.prototype.readUInt32BE = function(a, c) { - return a = a >>> 0, c || G(a, 4, this.length), this[a] * 16777216 + (this[a + 1] << 16 | this[a + 2] << 8 | this[a + 3]); - }, l.prototype.readBigUInt64LE = ge(function(a) { - a = a >>> 0, ve(a, "offset"); - const c = this[a], d = this[a + 7]; - (c === void 0 || d === void 0) && Qe(a, this.length - 8); - const w = c + this[++a] * 2 ** 8 + this[++a] * 2 ** 16 + this[++a] * 2 ** 24, S = this[++a] + this[++a] * 2 ** 8 + this[++a] * 2 ** 16 + d * 2 ** 24; - return BigInt(w) + (BigInt(S) << BigInt(32)); - }), l.prototype.readBigUInt64BE = ge(function(a) { - a = a >>> 0, ve(a, "offset"); - const c = this[a], d = this[a + 7]; - (c === void 0 || d === void 0) && Qe(a, this.length - 8); - const w = c * 2 ** 24 + this[++a] * 2 ** 16 + this[++a] * 2 ** 8 + this[++a], S = this[++a] * 2 ** 24 + this[++a] * 2 ** 16 + this[++a] * 2 ** 8 + d; - return (BigInt(w) << BigInt(32)) + BigInt(S); - }), l.prototype.readIntLE = function(a, c, d) { - a = a >>> 0, c = c >>> 0, d || G(a, c, this.length); - let w = this[a], S = 1, I = 0; - for (; ++I < c && (S *= 256); ) - w += this[a + I] * S; - return S *= 128, w >= S && (w -= Math.pow(2, 8 * c)), w; - }, l.prototype.readIntBE = function(a, c, d) { - a = a >>> 0, c = c >>> 0, d || G(a, c, this.length); - let w = c, S = 1, I = this[a + --w]; - for (; w > 0 && (S *= 256); ) - I += this[a + --w] * S; - return S *= 128, I >= S && (I -= Math.pow(2, 8 * c)), I; - }, l.prototype.readInt8 = function(a, c) { - return a = a >>> 0, c || G(a, 1, this.length), this[a] & 128 ? (255 - this[a] + 1) * -1 : this[a]; - }, l.prototype.readInt16LE = function(a, c) { - a = a >>> 0, c || G(a, 2, this.length); - const d = this[a] | this[a + 1] << 8; - return d & 32768 ? d | 4294901760 : d; - }, l.prototype.readInt16BE = function(a, c) { - a = a >>> 0, c || G(a, 2, this.length); - const d = this[a + 1] | this[a] << 8; - return d & 32768 ? d | 4294901760 : d; - }, l.prototype.readInt32LE = function(a, c) { - return a = a >>> 0, c || G(a, 4, this.length), this[a] | this[a + 1] << 8 | this[a + 2] << 16 | this[a + 3] << 24; - }, l.prototype.readInt32BE = function(a, c) { - return a = a >>> 0, c || G(a, 4, this.length), this[a] << 24 | this[a + 1] << 16 | this[a + 2] << 8 | this[a + 3]; - }, l.prototype.readBigInt64LE = ge(function(a) { - a = a >>> 0, ve(a, "offset"); - const c = this[a], d = this[a + 7]; - (c === void 0 || d === void 0) && Qe(a, this.length - 8); - const w = this[a + 4] + this[a + 5] * 2 ** 8 + this[a + 6] * 2 ** 16 + (d << 24); - return (BigInt(w) << BigInt(32)) + BigInt(c + this[++a] * 2 ** 8 + this[++a] * 2 ** 16 + this[++a] * 2 ** 24); - }), l.prototype.readBigInt64BE = ge(function(a) { - a = a >>> 0, ve(a, "offset"); - const c = this[a], d = this[a + 7]; - (c === void 0 || d === void 0) && Qe(a, this.length - 8); - const w = (c << 24) + // Overflow - this[++a] * 2 ** 16 + this[++a] * 2 ** 8 + this[++a]; - return (BigInt(w) << BigInt(32)) + BigInt(this[++a] * 2 ** 24 + this[++a] * 2 ** 16 + this[++a] * 2 ** 8 + d); - }), l.prototype.readFloatLE = function(a, c) { - return a = a >>> 0, c || G(a, 4, this.length), n.read(this, a, !0, 23, 4); - }, l.prototype.readFloatBE = function(a, c) { - return a = a >>> 0, c || G(a, 4, this.length), n.read(this, a, !1, 23, 4); - }, l.prototype.readDoubleLE = function(a, c) { - return a = a >>> 0, c || G(a, 8, this.length), n.read(this, a, !0, 52, 8); - }, l.prototype.readDoubleBE = function(a, c) { - return a = a >>> 0, c || G(a, 8, this.length), n.read(this, a, !1, 52, 8); - }; - function H(h, a, c, d, w, S) { - if (!l.isBuffer(h)) throw new TypeError('"buffer" argument must be a Buffer instance'); - if (a > w || a < S) throw new RangeError('"value" argument is out of bounds'); - if (c + d > h.length) throw new RangeError("Index out of range"); - } - l.prototype.writeUintLE = l.prototype.writeUIntLE = function(a, c, d, w) { - if (a = +a, c = c >>> 0, d = d >>> 0, !w) { - const P = Math.pow(2, 8 * d) - 1; - H(this, a, c, d, P, 0); - } - let S = 1, I = 0; - for (this[c] = a & 255; ++I < d && (S *= 256); ) - this[c + I] = a / S & 255; - return c + d; - }, l.prototype.writeUintBE = l.prototype.writeUIntBE = function(a, c, d, w) { - if (a = +a, c = c >>> 0, d = d >>> 0, !w) { - const P = Math.pow(2, 8 * d) - 1; - H(this, a, c, d, P, 0); - } - let S = d - 1, I = 1; - for (this[c + S] = a & 255; --S >= 0 && (I *= 256); ) - this[c + S] = a / I & 255; - return c + d; - }, l.prototype.writeUint8 = l.prototype.writeUInt8 = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 1, 255, 0), this[c] = a & 255, c + 1; - }, l.prototype.writeUint16LE = l.prototype.writeUInt16LE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 2, 65535, 0), this[c] = a & 255, this[c + 1] = a >>> 8, c + 2; - }, l.prototype.writeUint16BE = l.prototype.writeUInt16BE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 2, 65535, 0), this[c] = a >>> 8, this[c + 1] = a & 255, c + 2; - }, l.prototype.writeUint32LE = l.prototype.writeUInt32LE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 4, 4294967295, 0), this[c + 3] = a >>> 24, this[c + 2] = a >>> 16, this[c + 1] = a >>> 8, this[c] = a & 255, c + 4; - }, l.prototype.writeUint32BE = l.prototype.writeUInt32BE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 4, 4294967295, 0), this[c] = a >>> 24, this[c + 1] = a >>> 16, this[c + 2] = a >>> 8, this[c + 3] = a & 255, c + 4; - }; - function Kn(h, a, c, d, w) { - Cn(a, d, w, h, c, 7); - let S = Number(a & BigInt(4294967295)); - h[c++] = S, S = S >> 8, h[c++] = S, S = S >> 8, h[c++] = S, S = S >> 8, h[c++] = S; - let I = Number(a >> BigInt(32) & BigInt(4294967295)); - return h[c++] = I, I = I >> 8, h[c++] = I, I = I >> 8, h[c++] = I, I = I >> 8, h[c++] = I, c; - } - function Vn(h, a, c, d, w) { - Cn(a, d, w, h, c, 7); - let S = Number(a & BigInt(4294967295)); - h[c + 7] = S, S = S >> 8, h[c + 6] = S, S = S >> 8, h[c + 5] = S, S = S >> 8, h[c + 4] = S; - let I = Number(a >> BigInt(32) & BigInt(4294967295)); - return h[c + 3] = I, I = I >> 8, h[c + 2] = I, I = I >> 8, h[c + 1] = I, I = I >> 8, h[c] = I, c + 8; - } - l.prototype.writeBigUInt64LE = ge(function(a, c = 0) { - return Kn(this, a, c, BigInt(0), BigInt("0xffffffffffffffff")); - }), l.prototype.writeBigUInt64BE = ge(function(a, c = 0) { - return Vn(this, a, c, BigInt(0), BigInt("0xffffffffffffffff")); - }), l.prototype.writeIntLE = function(a, c, d, w) { - if (a = +a, c = c >>> 0, !w) { - const J = Math.pow(2, 8 * d - 1); - H(this, a, c, d, J - 1, -J); - } - let S = 0, I = 1, P = 0; - for (this[c] = a & 255; ++S < d && (I *= 256); ) - a < 0 && P === 0 && this[c + S - 1] !== 0 && (P = 1), this[c + S] = (a / I >> 0) - P & 255; - return c + d; - }, l.prototype.writeIntBE = function(a, c, d, w) { - if (a = +a, c = c >>> 0, !w) { - const J = Math.pow(2, 8 * d - 1); - H(this, a, c, d, J - 1, -J); - } - let S = d - 1, I = 1, P = 0; - for (this[c + S] = a & 255; --S >= 0 && (I *= 256); ) - a < 0 && P === 0 && this[c + S + 1] !== 0 && (P = 1), this[c + S] = (a / I >> 0) - P & 255; - return c + d; - }, l.prototype.writeInt8 = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 1, 127, -128), a < 0 && (a = 255 + a + 1), this[c] = a & 255, c + 1; - }, l.prototype.writeInt16LE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 2, 32767, -32768), this[c] = a & 255, this[c + 1] = a >>> 8, c + 2; - }, l.prototype.writeInt16BE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 2, 32767, -32768), this[c] = a >>> 8, this[c + 1] = a & 255, c + 2; - }, l.prototype.writeInt32LE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 4, 2147483647, -2147483648), this[c] = a & 255, this[c + 1] = a >>> 8, this[c + 2] = a >>> 16, this[c + 3] = a >>> 24, c + 4; - }, l.prototype.writeInt32BE = function(a, c, d) { - return a = +a, c = c >>> 0, d || H(this, a, c, 4, 2147483647, -2147483648), a < 0 && (a = 4294967295 + a + 1), this[c] = a >>> 24, this[c + 1] = a >>> 16, this[c + 2] = a >>> 8, this[c + 3] = a & 255, c + 4; - }, l.prototype.writeBigInt64LE = ge(function(a, c = 0) { - return Kn(this, a, c, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff")); - }), l.prototype.writeBigInt64BE = ge(function(a, c = 0) { - return Vn(this, a, c, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff")); - }); - function Jn(h, a, c, d, w, S) { - if (c + d > h.length) throw new RangeError("Index out of range"); - if (c < 0) throw new RangeError("Index out of range"); - } - function Yn(h, a, c, d, w) { - return a = +a, c = c >>> 0, w || Jn(h, a, c, 4), n.write(h, a, c, d, 23, 4), c + 4; - } - l.prototype.writeFloatLE = function(a, c, d) { - return Yn(this, a, c, !0, d); - }, l.prototype.writeFloatBE = function(a, c, d) { - return Yn(this, a, c, !1, d); - }; - function Gn(h, a, c, d, w) { - return a = +a, c = c >>> 0, w || Jn(h, a, c, 8), n.write(h, a, c, d, 52, 8), c + 8; - } - l.prototype.writeDoubleLE = function(a, c, d) { - return Gn(this, a, c, !0, d); - }, l.prototype.writeDoubleBE = function(a, c, d) { - return Gn(this, a, c, !1, d); - }, l.prototype.copy = function(a, c, d, w) { - if (!l.isBuffer(a)) throw new TypeError("argument should be a Buffer"); - if (d || (d = 0), !w && w !== 0 && (w = this.length), c >= a.length && (c = a.length), c || (c = 0), w > 0 && w < d && (w = d), w === d || a.length === 0 || this.length === 0) return 0; - if (c < 0) - throw new RangeError("targetStart out of bounds"); - if (d < 0 || d >= this.length) throw new RangeError("Index out of range"); - if (w < 0) throw new RangeError("sourceEnd out of bounds"); - w > this.length && (w = this.length), a.length - c < w - d && (w = a.length - c + d); - const S = w - d; - return this === a && typeof Uint8Array.prototype.copyWithin == "function" ? this.copyWithin(c, d, w) : Uint8Array.prototype.set.call( - a, - this.subarray(d, w), - c - ), S; - }, l.prototype.fill = function(a, c, d, w) { - if (typeof a == "string") { - if (typeof c == "string" ? (w = c, c = 0, d = this.length) : typeof d == "string" && (w = d, d = this.length), w !== void 0 && typeof w != "string") - throw new TypeError("encoding must be a string"); - if (typeof w == "string" && !l.isEncoding(w)) - throw new TypeError("Unknown encoding: " + w); - if (a.length === 1) { - const I = a.charCodeAt(0); - (w === "utf8" && I < 128 || w === "latin1") && (a = I); - } - } else typeof a == "number" ? a = a & 255 : typeof a == "boolean" && (a = Number(a)); - if (c < 0 || this.length < c || this.length < d) - throw new RangeError("Out of range index"); - if (d <= c) - return this; - c = c >>> 0, d = d === void 0 ? this.length : d >>> 0, a || (a = 0); - let S; - if (typeof a == "number") - for (S = c; S < d; ++S) - this[S] = a; - else { - const I = l.isBuffer(a) ? a : l.from(a, w), P = I.length; - if (P === 0) - throw new TypeError('The value "' + a + '" is invalid for argument "value"'); - for (S = 0; S < d - c; ++S) - this[S + c] = I[S % P]; - } - return this; - }; - const _e = {}; - function Zt(h, a, c) { - _e[h] = class extends c { - constructor() { - super(), Object.defineProperty(this, "message", { - value: a.apply(this, arguments), - writable: !0, - configurable: !0 - }), this.name = `${this.name} [${h}]`, this.stack, delete this.name; - } - get code() { - return h; - } - set code(w) { - Object.defineProperty(this, "code", { - configurable: !0, - enumerable: !0, - value: w, - writable: !0 - }); - } - toString() { - return `${this.name} [${h}]: ${this.message}`; - } - }; - } - Zt( - "ERR_BUFFER_OUT_OF_BOUNDS", - function(h) { - return h ? `${h} is outside of buffer bounds` : "Attempt to access memory outside buffer bounds"; - }, - RangeError - ), Zt( - "ERR_INVALID_ARG_TYPE", - function(h, a) { - return `The "${h}" argument must be of type number. Received type ${typeof a}`; - }, - TypeError - ), Zt( - "ERR_OUT_OF_RANGE", - function(h, a, c) { - let d = `The value of "${h}" is out of range.`, w = c; - return Number.isInteger(c) && Math.abs(c) > 2 ** 32 ? w = Wn(String(c)) : typeof c == "bigint" && (w = String(c), (c > BigInt(2) ** BigInt(32) || c < -(BigInt(2) ** BigInt(32))) && (w = Wn(w)), w += "n"), d += ` It must be ${a}. Received ${w}`, d; - }, - RangeError - ); - function Wn(h) { - let a = "", c = h.length; - const d = h[0] === "-" ? 1 : 0; - for (; c >= d + 4; c -= 3) - a = `_${h.slice(c - 3, c)}${a}`; - return `${h.slice(0, c)}${a}`; - } - function vs(h, a, c) { - ve(a, "offset"), (h[a] === void 0 || h[a + c] === void 0) && Qe(a, h.length - (c + 1)); - } - function Cn(h, a, c, d, w, S) { - if (h > c || h < a) { - const I = typeof a == "bigint" ? "n" : ""; - let P; - throw a === 0 || a === BigInt(0) ? P = `>= 0${I} and < 2${I} ** ${(S + 1) * 8}${I}` : P = `>= -(2${I} ** ${(S + 1) * 8 - 1}${I}) and < 2 ** ${(S + 1) * 8 - 1}${I}`, new _e.ERR_OUT_OF_RANGE("value", P, h); - } - vs(d, w, S); - } - function ve(h, a) { - if (typeof h != "number") - throw new _e.ERR_INVALID_ARG_TYPE(a, "number", h); - } - function Qe(h, a, c) { - throw Math.floor(h) !== h ? (ve(h, c), new _e.ERR_OUT_OF_RANGE("offset", "an integer", h)) : a < 0 ? new _e.ERR_BUFFER_OUT_OF_BOUNDS() : new _e.ERR_OUT_OF_RANGE( - "offset", - `>= 0 and <= ${a}`, - h - ); - } - const $s = /[^+/0-9A-Za-z-_]/g; - function Ps(h) { - if (h = h.split("=")[0], h = h.trim().replace($s, ""), h.length < 2) return ""; - for (; h.length % 4 !== 0; ) - h = h + "="; - return h; - } - function en(h, a) { - a = a || 1 / 0; - let c; - const d = h.length; - let w = null; - const S = []; - for (let I = 0; I < d; ++I) { - if (c = h.charCodeAt(I), c > 55295 && c < 57344) { - if (!w) { - if (c > 56319) { - (a -= 3) > -1 && S.push(239, 191, 189); - continue; - } else if (I + 1 === d) { - (a -= 3) > -1 && S.push(239, 191, 189); - continue; - } - w = c; - continue; - } - if (c < 56320) { - (a -= 3) > -1 && S.push(239, 191, 189), w = c; - continue; - } - c = (w - 55296 << 10 | c - 56320) + 65536; - } else w && (a -= 3) > -1 && S.push(239, 191, 189); - if (w = null, c < 128) { - if ((a -= 1) < 0) break; - S.push(c); - } else if (c < 2048) { - if ((a -= 2) < 0) break; - S.push( - c >> 6 | 192, - c & 63 | 128 - ); - } else if (c < 65536) { - if ((a -= 3) < 0) break; - S.push( - c >> 12 | 224, - c >> 6 & 63 | 128, - c & 63 | 128 - ); - } else if (c < 1114112) { - if ((a -= 4) < 0) break; - S.push( - c >> 18 | 240, - c >> 12 & 63 | 128, - c >> 6 & 63 | 128, - c & 63 | 128 - ); - } else - throw new Error("Invalid code point"); - } - return S; - } - function js(h) { - const a = []; - for (let c = 0; c < h.length; ++c) - a.push(h.charCodeAt(c) & 255); - return a; - } - function Fs(h, a) { - let c, d, w; - const S = []; - for (let I = 0; I < h.length && !((a -= 2) < 0); ++I) - c = h.charCodeAt(I), d = c >> 8, w = c % 256, S.push(w), S.push(d); - return S; - } - function Qn(h) { - return t.toByteArray(Ps(h)); - } - function dt(h, a, c, d) { - let w; - for (w = 0; w < d && !(w + c >= a.length || w >= h.length); ++w) - a[w + c] = h[w]; - return w; - } - function re(h, a) { - return h instanceof a || h != null && h.constructor != null && h.constructor.name != null && h.constructor.name === a.name; - } - function tn(h) { - return h !== h; - } - const Us = (function() { - const h = "0123456789abcdef", a = new Array(256); - for (let c = 0; c < 16; ++c) { - const d = c * 16; - for (let w = 0; w < 16; ++w) - a[d + w] = h[c] + h[w]; - } - return a; - })(); - function ge(h) { - return typeof BigInt > "u" ? Ms : h; - } - function Ms() { - throw new Error("BigInt not supported"); - } - })(hn)), hn; -} -export { - Mo as H, - $o as a, - Fo as b, - Ro as c, - Ts as d, - Uo as e, - vo as l, - xo as r, - Po as s, - jo as u -}; diff --git a/openapi-plugin/resources/web/platform-api.BtY3-lHu.js b/openapi-plugin/resources/web/platform-api.BtY3-lHu.js new file mode 100644 index 00000000..60d8f854 --- /dev/null +++ b/openapi-plugin/resources/web/platform-api.BtY3-lHu.js @@ -0,0 +1,356 @@ +import { j as s, f as d, X as M, K as E, L as x, _ as j, M as b, Z as B, e as y, T as I } from "./TriangleExclamation.BLKAXJ8l.js"; +import { c as k, u as U, R as K, I as Q } from "./index.Cju85Yia.js"; +import { u as V } from "./index.Cyn4uFgE.js"; +import { u as H } from "./index.rMN5z6gU.js"; +import { c as X } from "./rtk-query-react.modern.DVdYp0Is.js"; +import { w as z } from "./webapp-client.CEJRS8eu.js"; +import { s as Y } from "./listener.BNWHQqef.js"; +const J = (e) => /* @__PURE__ */ s.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ s.jsx("path", { d: "M256 512a256 256 0 1 0 0-512 256 256 0 1 0 0 512" }) }); +var A = "Radio", [W, G] = E(A), [Z, ee] = W(A), P = d.forwardRef( + (e, r) => { + const { + __scopeRadio: o, + name: n, + checked: t = !1, + required: a, + disabled: i, + value: f = "on", + onCheck: m, + form: v, + ...l + } = e, [p, R] = d.useState(null), c = j(r, (g) => R(g)), u = d.useRef(!1), h = p ? v || !!p.closest("form") : !0; + return /* @__PURE__ */ s.jsxs(Z, { scope: o, checked: t, disabled: i, children: [ + /* @__PURE__ */ s.jsx( + x.button, + { + type: "button", + role: "radio", + "aria-checked": t, + "data-state": q(t), + "data-disabled": i ? "" : void 0, + disabled: i, + value: f, + ...l, + ref: c, + onClick: b(e.onClick, (g) => { + t || m?.(), h && (u.current = g.isPropagationStopped(), u.current || g.stopPropagation()); + }) + } + ), + h && /* @__PURE__ */ s.jsx( + N, + { + control: p, + bubbles: !u.current, + name: n, + value: f, + checked: t, + required: a, + disabled: i, + form: v, + style: { transform: "translateX(-100%)" } + } + ) + ] }); + } +); +P.displayName = A; +var _ = "RadioIndicator", S = d.forwardRef( + (e, r) => { + const { __scopeRadio: o, forceMount: n, ...t } = e, a = ee(_, o); + return /* @__PURE__ */ s.jsx(B, { present: n || a.checked, children: /* @__PURE__ */ s.jsx( + x.span, + { + "data-state": q(a.checked), + "data-disabled": a.disabled ? "" : void 0, + ...t, + ref: r + } + ) }); + } +); +S.displayName = _; +var oe = "RadioBubbleInput", N = d.forwardRef( + ({ + __scopeRadio: e, + control: r, + checked: o, + bubbles: n = !0, + ...t + }, a) => { + const i = d.useRef(null), f = j(i, a), m = H(o), v = V(r); + return d.useEffect(() => { + const l = i.current; + if (!l) return; + const p = window.HTMLInputElement.prototype, c = Object.getOwnPropertyDescriptor( + p, + "checked" + ).set; + if (m !== o && c) { + const u = new Event("click", { bubbles: n }); + c.call(l, o), l.dispatchEvent(u); + } + }, [m, o, n]), /* @__PURE__ */ s.jsx( + x.input, + { + type: "radio", + "aria-hidden": !0, + defaultChecked: o, + ...t, + tabIndex: -1, + ref: f, + style: { + ...t.style, + ...v, + position: "absolute", + pointerEvents: "none", + opacity: 0, + margin: 0 + } + } + ); + } +); +N.displayName = oe; +function q(e) { + return e ? "checked" : "unchecked"; +} +var re = ["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight"], C = "RadioGroup", [te] = E(C, [ + k, + G +]), O = k(), $ = G(), [ae, se] = te(C), T = d.forwardRef( + (e, r) => { + const { + __scopeRadioGroup: o, + name: n, + defaultValue: t, + value: a, + required: i = !1, + disabled: f = !1, + orientation: m, + dir: v, + loop: l = !0, + onValueChange: p, + ...R + } = e, c = O(o), u = U(v), [h, g] = M({ + prop: a, + defaultProp: t ?? null, + onChange: p, + caller: C + }); + return /* @__PURE__ */ s.jsx( + ae, + { + scope: o, + name: n, + required: i, + disabled: f, + value: h, + onValueChange: g, + children: /* @__PURE__ */ s.jsx( + K, + { + asChild: !0, + ...c, + orientation: m, + dir: u, + loop: l, + children: /* @__PURE__ */ s.jsx( + x.div, + { + role: "radiogroup", + "aria-required": i, + "aria-orientation": m, + "data-disabled": f ? "" : void 0, + dir: u, + ...R, + ref: r + } + ) + } + ) + } + ); + } +); +T.displayName = C; +var D = "RadioGroupItem", F = d.forwardRef( + (e, r) => { + const { __scopeRadioGroup: o, disabled: n, ...t } = e, a = se(D, o), i = a.disabled || n, f = O(o), m = $(o), v = d.useRef(null), l = j(r, v), p = a.value === t.value, R = d.useRef(!1); + return d.useEffect(() => { + const c = (h) => { + re.includes(h.key) && (R.current = !0); + }, u = () => R.current = !1; + return document.addEventListener("keydown", c), document.addEventListener("keyup", u), () => { + document.removeEventListener("keydown", c), document.removeEventListener("keyup", u); + }; + }, []), /* @__PURE__ */ s.jsx( + Q, + { + asChild: !0, + ...f, + focusable: !i, + active: p, + children: /* @__PURE__ */ s.jsx( + P, + { + disabled: i, + required: a.required, + checked: p, + ...m, + ...t, + name: a.name, + ref: l, + onCheck: () => a.onValueChange(t.value), + onKeyDown: b((c) => { + c.key === "Enter" && c.preventDefault(); + }), + onFocus: b(t.onFocus, () => { + R.current && v.current?.click(); + }) + } + ) + } + ); + } +); +F.displayName = D; +var ne = "RadioGroupIndicator", L = d.forwardRef( + (e, r) => { + const { __scopeRadioGroup: o, ...n } = e, t = $(o); + return /* @__PURE__ */ s.jsx(S, { ...t, ...n, ref: r }); + } +); +L.displayName = ne; +var ie = T, ce = F, de = L; +function je({ + value: e, + options: r, + onValueChange: o +}) { + const n = d.useId(); + return /* @__PURE__ */ s.jsx(ue, { value: e, onValueChange: o, children: r.map((t, a) => /* @__PURE__ */ s.jsxs(le, { children: [ + /* @__PURE__ */ s.jsx(pe, { value: t.value, id: `${n}-${a}`, children: /* @__PURE__ */ s.jsx(fe, { children: /* @__PURE__ */ s.jsx(J, {}) }) }), + /* @__PURE__ */ s.jsx("label", { htmlFor: `${n}-${a}`, children: t.label }) + ] }, a)) }); +} +const ue = y(ie)` + display: flex; + flex-direction: row; + gap: 8px; +`, le = y.div` + display: flex; + align-items: center; + gap: 4px; +`, pe = y(ce)` + width: 20px; + height: 20px; + border-radius: 100%; + background-color: var(${I.checkboxBackground}); + border-color: var(${I.checkboxBorder}); + border-width: 2px; + border-style: solid; + display: flex; + align-items: center; + justify-content: center; +`, fe = y(de)` + display: flex; + align-items: center; + justify-content: center; + width: 8px; + height: 8px; + > svg { + fill: var(${I.checkboxForeground}); + } +`, Ae = { + refetchOnFocus: !0, + pollingInterval: 1e3 * 60 * 10 + // refresh every 10 minutes +}, me = 10, ve = X({ + reducerPath: "platformApi", + baseQuery: he, + endpoints: (e) => ({ + getCategories: e.query({ + query: () => "api/v2/categories", + transformResponse: w + }), + getTags: e.query({ + query: () => "api/v2/tags", + transformResponse: w + }), + searchCollections: e.query({ + query: (r) => `api/v1/search/collections?page=1&perPage=${me}&order=default&sort=default&collectionName=${encodeURIComponent(r)}`, + transformResponse: Re + }), + getCollection: e.query({ + query: (r) => `api/v1/collections/${r}`, + // the platform replies with an error payload rather than a collection + // if the collection does not exist or is not accessible + transformResponse: (r) => r?.desc?.id ? r : void 0 + }), + getApisFromCollection: e.query({ + query: (r) => `api/v2/collections/${r}/apis?withTags=true&perPage=0`, + transformResponse: w + }) + }) +}); +function w(e) { + return e.list; +} +function Re(e) { + const r = e?.list ?? []; + return { + collections: r.map((o) => ({ + desc: { + id: o.id, + name: o.name, + technicalName: o.technicalName + }, + summary: { + apis: o.apiCount, + writeApis: o.writeApis + } + })), + total: e?.num ?? r.length + }; +} +async function he(e, { signal: r, dispatch: o, getState: n }, t) { + const { config: a } = n(), { platformUrl: i, platformApiToken: f } = a.data, m = z( + { https: { rejectUnauthorized: !0 } }, + (p, R, c, u) => o(Y({ id: p, request: R, config: c, mtlsConfig: u })) + ), [v, l] = await m( + { + url: `${i}/${e}`, + method: "get", + headers: { + Accept: "application/json", + "X-API-KEY": f, + "X-42C-IDE": "true" + } + }, + void 0 + ); + return l !== void 0 ? { error: l } : { data: JSON.parse(v.body) }; +} +const { + useGetTagsQuery: Ee, + useGetCategoriesQuery: ke, + useSearchCollectionsQuery: Ge, + useGetCollectionQuery: Pe, + useGetApisFromCollectionQuery: _e +} = ve; +export { + ue as G, + pe as I, + le as O, + je as R, + J as S, + Pe as a, + _e as b, + fe as c, + ke as d, + Ee as e, + ve as p, + Ae as r, + Ge as u +}; diff --git a/openapi-plugin/resources/web/platform-api.xQ9SQy05.js b/openapi-plugin/resources/web/platform-api.xQ9SQy05.js deleted file mode 100644 index 955f06e4..00000000 --- a/openapi-plugin/resources/web/platform-api.xQ9SQy05.js +++ /dev/null @@ -1,331 +0,0 @@ -import { j as a, f as d, X as T, K as A, L as y, _ as j, M as C, Z as B, e as b, T as I } from "./TriangleExclamation.BLKAXJ8l.js"; -import { c as E, u as K, R as U, I as Q } from "./index.Cju85Yia.js"; -import { u as V } from "./index.Cyn4uFgE.js"; -import { u as H } from "./index.rMN5z6gU.js"; -import { c as X } from "./rtk-query-react.modern.kJqw8Vn6.js"; -import { w as z } from "./webapp-client.CEJRS8eu.js"; -import { s as Y } from "./listener.BNWHQqef.js"; -const J = (e) => /* @__PURE__ */ a.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ a.jsx("path", { d: "M256 512a256 256 0 1 0 0-512 256 256 0 1 0 0 512" }) }); -var k = "Radio", [W, G] = A(k), [Z, ee] = W(k), P = d.forwardRef( - (e, n) => { - const { - __scopeRadio: r, - name: s, - checked: o = !1, - required: t, - disabled: i, - value: f = "on", - onCheck: v, - form: m, - ...p - } = e, [l, R] = d.useState(null), c = j(n, (g) => R(g)), u = d.useRef(!1), h = l ? m || !!l.closest("form") : !0; - return /* @__PURE__ */ a.jsxs(Z, { scope: r, checked: o, disabled: i, children: [ - /* @__PURE__ */ a.jsx( - y.button, - { - type: "button", - role: "radio", - "aria-checked": o, - "data-state": O(o), - "data-disabled": i ? "" : void 0, - disabled: i, - value: f, - ...p, - ref: c, - onClick: C(e.onClick, (g) => { - o || v?.(), h && (u.current = g.isPropagationStopped(), u.current || g.stopPropagation()); - }) - } - ), - h && /* @__PURE__ */ a.jsx( - N, - { - control: l, - bubbles: !u.current, - name: s, - value: f, - checked: o, - required: t, - disabled: i, - form: m, - style: { transform: "translateX(-100%)" } - } - ) - ] }); - } -); -P.displayName = k; -var _ = "RadioIndicator", S = d.forwardRef( - (e, n) => { - const { __scopeRadio: r, forceMount: s, ...o } = e, t = ee(_, r); - return /* @__PURE__ */ a.jsx(B, { present: s || t.checked, children: /* @__PURE__ */ a.jsx( - y.span, - { - "data-state": O(t.checked), - "data-disabled": t.disabled ? "" : void 0, - ...o, - ref: n - } - ) }); - } -); -S.displayName = _; -var oe = "RadioBubbleInput", N = d.forwardRef( - ({ - __scopeRadio: e, - control: n, - checked: r, - bubbles: s = !0, - ...o - }, t) => { - const i = d.useRef(null), f = j(i, t), v = H(r), m = V(n); - return d.useEffect(() => { - const p = i.current; - if (!p) return; - const l = window.HTMLInputElement.prototype, c = Object.getOwnPropertyDescriptor( - l, - "checked" - ).set; - if (v !== r && c) { - const u = new Event("click", { bubbles: s }); - c.call(p, r), p.dispatchEvent(u); - } - }, [v, r, s]), /* @__PURE__ */ a.jsx( - y.input, - { - type: "radio", - "aria-hidden": !0, - defaultChecked: r, - ...o, - tabIndex: -1, - ref: f, - style: { - ...o.style, - ...m, - position: "absolute", - pointerEvents: "none", - opacity: 0, - margin: 0 - } - } - ); - } -); -N.displayName = oe; -function O(e) { - return e ? "checked" : "unchecked"; -} -var re = ["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight"], w = "RadioGroup", [te] = A(w, [ - E, - G -]), q = E(), $ = G(), [ae, se] = te(w), D = d.forwardRef( - (e, n) => { - const { - __scopeRadioGroup: r, - name: s, - defaultValue: o, - value: t, - required: i = !1, - disabled: f = !1, - orientation: v, - dir: m, - loop: p = !0, - onValueChange: l, - ...R - } = e, c = q(r), u = K(m), [h, g] = T({ - prop: t, - defaultProp: o ?? null, - onChange: l, - caller: w - }); - return /* @__PURE__ */ a.jsx( - ae, - { - scope: r, - name: s, - required: i, - disabled: f, - value: h, - onValueChange: g, - children: /* @__PURE__ */ a.jsx( - U, - { - asChild: !0, - ...c, - orientation: v, - dir: u, - loop: p, - children: /* @__PURE__ */ a.jsx( - y.div, - { - role: "radiogroup", - "aria-required": i, - "aria-orientation": v, - "data-disabled": f ? "" : void 0, - dir: u, - ...R, - ref: n - } - ) - } - ) - } - ); - } -); -D.displayName = w; -var F = "RadioGroupItem", L = d.forwardRef( - (e, n) => { - const { __scopeRadioGroup: r, disabled: s, ...o } = e, t = se(F, r), i = t.disabled || s, f = q(r), v = $(r), m = d.useRef(null), p = j(n, m), l = t.value === o.value, R = d.useRef(!1); - return d.useEffect(() => { - const c = (h) => { - re.includes(h.key) && (R.current = !0); - }, u = () => R.current = !1; - return document.addEventListener("keydown", c), document.addEventListener("keyup", u), () => { - document.removeEventListener("keydown", c), document.removeEventListener("keyup", u); - }; - }, []), /* @__PURE__ */ a.jsx( - Q, - { - asChild: !0, - ...f, - focusable: !i, - active: l, - children: /* @__PURE__ */ a.jsx( - P, - { - disabled: i, - required: t.required, - checked: l, - ...v, - ...o, - name: t.name, - ref: p, - onCheck: () => t.onValueChange(o.value), - onKeyDown: C((c) => { - c.key === "Enter" && c.preventDefault(); - }), - onFocus: C(o.onFocus, () => { - R.current && m.current?.click(); - }) - } - ) - } - ); - } -); -L.displayName = F; -var ne = "RadioGroupIndicator", M = d.forwardRef( - (e, n) => { - const { __scopeRadioGroup: r, ...s } = e, o = $(r); - return /* @__PURE__ */ a.jsx(S, { ...o, ...s, ref: n }); - } -); -M.displayName = ne; -var ie = D, ce = L, de = M; -function Ce({ - value: e, - options: n, - onValueChange: r -}) { - const s = d.useId(); - return /* @__PURE__ */ a.jsx(ue, { value: e, onValueChange: r, children: n.map((o, t) => /* @__PURE__ */ a.jsxs(pe, { children: [ - /* @__PURE__ */ a.jsx(le, { value: o.value, id: `${s}-${t}`, children: /* @__PURE__ */ a.jsx(fe, { children: /* @__PURE__ */ a.jsx(J, {}) }) }), - /* @__PURE__ */ a.jsx("label", { htmlFor: `${s}-${t}`, children: o.label }) - ] }, t)) }); -} -const ue = b(ie)` - display: flex; - flex-direction: row; - gap: 8px; -`, pe = b.div` - display: flex; - align-items: center; - gap: 4px; -`, le = b(ce)` - width: 20px; - height: 20px; - border-radius: 100%; - background-color: var(${I.checkboxBackground}); - border-color: var(${I.checkboxBorder}); - border-width: 2px; - border-style: solid; - display: flex; - align-items: center; - justify-content: center; -`, fe = b(de)` - display: flex; - align-items: center; - justify-content: center; - width: 8px; - height: 8px; - > svg { - fill: var(${I.checkboxForeground}); - } -`, Ie = { - refetchOnFocus: !0, - pollingInterval: 1e3 * 60 * 10 - // refresh every 10 minutes -}, ve = X({ - reducerPath: "platformApi", - baseQuery: me, - endpoints: (e) => ({ - getCategories: e.query({ - query: () => "api/v2/categories", - transformResponse: x - }), - getTags: e.query({ - query: () => "api/v2/tags", - transformResponse: x - }), - getCollections: e.query({ - query: () => "api/v2/collections?listOption=ALL&perPage=0", - transformResponse: x - }), - getApisFromCollection: e.query({ - query: (n) => `api/v2/collections/${n}/apis?withTags=true&perPage=0`, - transformResponse: x - }) - }) -}); -function x(e) { - return e.list; -} -async function me(e, { signal: n, dispatch: r, getState: s }, o) { - const { config: t } = s(), { platformUrl: i, platformApiToken: f } = t.data, v = z( - { https: { rejectUnauthorized: !0 } }, - (l, R, c, u) => r(Y({ id: l, request: R, config: c, mtlsConfig: u })) - ), [m, p] = await v( - { - url: `${i}/${e}`, - method: "get", - headers: { - Accept: "application/json", - "X-API-KEY": f, - "X-42C-IDE": "true" - } - }, - void 0 - ); - return p !== void 0 ? { error: p } : { data: JSON.parse(m.body) }; -} -const { - useGetTagsQuery: je, - useGetCategoriesQuery: ke, - useGetCollectionsQuery: Ae, - useGetApisFromCollectionQuery: Ee -} = ve; -export { - ue as G, - le as I, - pe as O, - Ce as R, - J as S, - Ee as a, - fe as b, - ke as c, - je as d, - ve as p, - Ie as r, - Ae as u -}; diff --git a/openapi-plugin/resources/web/rtk-query-react.modern.kJqw8Vn6.js b/openapi-plugin/resources/web/rtk-query-react.modern.DVdYp0Is.js similarity index 99% rename from openapi-plugin/resources/web/rtk-query-react.modern.kJqw8Vn6.js rename to openapi-plugin/resources/web/rtk-query-react.modern.DVdYp0Is.js index 1fb87f59..ea0ddadb 100644 --- a/openapi-plugin/resources/web/rtk-query-react.modern.kJqw8Vn6.js +++ b/openapi-plugin/resources/web/rtk-query-react.modern.DVdYp0Is.js @@ -2525,6 +2525,7 @@ var In = /* @__PURE__ */ Symbol(), An = ({ } }), En = /* @__PURE__ */ Pt(wt(), An()); export { + W as a, En as c, Mn as s }; diff --git a/openapi-plugin/resources/web/scan.js b/openapi-plugin/resources/web/scan.js index 31f6268e..ec78d57b 100644 --- a/openapi-plugin/resources/web/scan.js +++ b/openapi-plugin/resources/web/scan.js @@ -1,20 +1,20 @@ -import { j as f, c as Ei, b as Ii, a as Mo, r as To, t as Ko, l as Ro, u as Oi, q as Do, v as No, d as qo, s as Bo, f as pt, n as Fo, o as $o, T as Q, e as V, S as Lo, g as Ho, R as Uo, P as zo, h as Yo, k as Vo, p as Wo } from "./TriangleExclamation.BLKAXJ8l.js"; -import { e as Qo, H as Ai, r as Go } from "./index.CRy0HWMP.js"; -import { p as Jo, S as ar } from "./slice.CZpj5Zis.js"; -import { c as Xo, l as Zo } from "./slice.s4_w0CJL.js"; -import { s as es } from "./listener.BM8yBkLB.js"; -import { T as ts } from "./Tabs.BfQDe6I2.js"; -import { R as ns } from "./Response.BJC209BA.js"; -import { P as rs, R as is, T as os, a as ss, C as as, A as us } from "./index.CduJ8u-z.js"; -import { b as cs, S as ls, a as ds } from "./Xmark.Doc6BN9Q.js"; -import { C as fs } from "./CollapsibleCard.BWECYxhA.js"; -import { S as Tt } from "./Check.BVLcLyMb.js"; -import { D as hn } from "./luxon.Cf3YS84f.js"; -import { S as hs } from "./AngleDown.DBLEm0qt.js"; -import { S as ps } from "./AngleUp.d5m1Xwr8.js"; -import { S as Mt } from "./ExclamationCircle.2wqwVNIx.js"; -import { P as Dt } from "./Select.Jkx8eZok.js"; -const ys = (s) => /* @__PURE__ */ f.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", width: "1em", height: "1em", ...s, children: /* @__PURE__ */ f.jsx("path", { d: "M15 239c-9.4 9.4-9.4 24.6 0 33.9L207 465c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9L65.9 256 241 81c9.4-9.4 9.4-24.6 0-33.9s-24.6-9.4-33.9 0z" }) }), ms = (s) => /* @__PURE__ */ f.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", width: "1em", height: "1em", ...s, children: /* @__PURE__ */ f.jsx("path", { d: "M305 239c9.4 9.4 9.4 24.6 0 33.9L113 465c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l175-175L79 81c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0z" }) }), vs = { +import { j as m, c as Hi, b as Yi, a as Ko, r as No, t as qo, l as Uo, u as zi, q as $o, v as Lo, d as Ho, s as Yo, f as Nt, n as zo, o as Vo, T as re, e as te, S as Wo, g as Go, R as Jo, P as Qo, h as Xo, k as Zo, p as es } from "./TriangleExclamation.BLKAXJ8l.js"; +import { e as ts, H as Vi } from "./index.BXf_Hj-1.js"; +import { p as ns, S as Sr } from "./slice.CZpj5Zis.js"; +import { c as rs, l as is } from "./slice.s4_w0CJL.js"; +import { s as os } from "./listener.BM8yBkLB.js"; +import { T as ss } from "./Tabs.BfQDe6I2.js"; +import { R as as } from "./Response.BJC209BA.js"; +import { P as us, R as cs, T as ls, a as fs, C as hs, A as ds } from "./index.CduJ8u-z.js"; +import { b as ps, S as ys, a as ms } from "./Xmark.Doc6BN9Q.js"; +import { C as gs } from "./CollapsibleCard.BWECYxhA.js"; +import { S as nn } from "./Check.BVLcLyMb.js"; +import { D as Fn } from "./luxon.Cf3YS84f.js"; +import { S as vs } from "./AngleDown.DBLEm0qt.js"; +import { S as bs } from "./AngleUp.d5m1Xwr8.js"; +import { S as en } from "./ExclamationCircle.2wqwVNIx.js"; +import { P as sn } from "./Select.Jkx8eZok.js"; +const xs = (u) => /* @__PURE__ */ m.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", width: "1em", height: "1em", ...u, children: /* @__PURE__ */ m.jsx("path", { d: "M15 239c-9.4 9.4-9.4 24.6 0 33.9L207 465c9.4 9.4 24.6 9.4 33.9 0s9.4-24.6 0-33.9L65.9 256 241 81c9.4-9.4 9.4-24.6 0-33.9s-24.6-9.4-33.9 0z" }) }), ws = (u) => /* @__PURE__ */ m.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", width: "1em", height: "1em", ...u, children: /* @__PURE__ */ m.jsx("path", { d: "M305 239c9.4 9.4 9.4 24.6 0 33.9L113 465c-9.4 9.4-24.6 9.4-33.9 0s-9.4-24.6 0-33.9l175-175L79 81c-9.4-9.4-9.4-24.6 0-33.9s24.6-9.4 33.9 0z" }) }), _s = { scanReport: void 0, error: void 0, waiting: !0, @@ -32,239 +32,239 @@ const ys = (s) => /* @__PURE__ */ f.jsx("svg", { xmlns: "http://www.w3.org/2000/ total: 0, current: 0 } -}, Mi = Ei({ +}, Wi = Hi({ name: "scan", - initialState: vs, + initialState: _s, reducers: { - showScanReport: (s, c) => { - s.apiAlias = c.payload.apiAlias, s.scanReport = void 0, s.error = void 0, s.waiting = !0, s.filter = {}, s.tab = "summary", s.happyPathPage = { + showScanReport: (u, l) => { + u.apiAlias = l.payload.apiAlias, u.scanReport = void 0, u.error = void 0, u.waiting = !0, u.filter = {}, u.tab = "summary", u.happyPathPage = { items: [], pages: 0, total: 0, current: 0 - }, s.testsPage = { + }, u.testsPage = { items: [], pages: 0, total: 0, current: 0 }; }, - changeFilter: (s, c) => { - s.filter = c.payload; + changeFilter: (u, l) => { + u.filter = l.payload; }, - changeTab: (s, c) => { - s.tab = c.payload; + changeTab: (u, l) => { + u.tab = l.payload; }, - showGeneralError: (s, c) => { - s.error = c.payload, s.waiting = !1; + showGeneralError: (u, l) => { + u.error = l.payload, u.waiting = !1; }, - showJsonPointer: (s, c) => { + showJsonPointer: (u, l) => { }, - sendCurlRequest: (s, c) => { + sendCurlRequest: (u, l) => { }, - parseChunk: (s, c) => { + parseChunk: (u, l) => { }, - parseChunkCompleted: (s) => { + parseChunkCompleted: (u) => { }, - started: (s) => { + started: (u) => { }, - reportLoaded: (s, c) => { - s.scanReport = c.payload, s.waiting = !1; + reportLoaded: (u, l) => { + u.scanReport = l.payload, u.waiting = !1; }, - loadHappyPathPage: (s, c) => { + loadHappyPathPage: (u, l) => { }, - happyPathPageLoaded: (s, c) => { - s.happyPathPage = c.payload; + happyPathPageLoaded: (u, l) => { + u.happyPathPage = l.payload; }, - loadTestsPage: (s, c) => { + loadTestsPage: (u, l) => { }, - testsPageLoaded: (s, c) => { - s.testsPage = c.payload; + testsPageLoaded: (u, l) => { + u.testsPage = l.payload; } } }), { - showScanReport: Ti, - showGeneralError: Ki, - showJsonPointer: Ri, - sendCurlRequest: Di, - changeTab: mn, - changeFilter: ye, - parseChunk: Ni, - parseChunkCompleted: ai, - started: mr, - loadHappyPathPage: fr, - happyPathPageLoaded: gs, - reportLoaded: bs, - loadTestsPage: hr, - testsPageLoaded: ui -} = Mi.actions, xs = Mi.reducer, _s = { + showScanReport: Gi, + showGeneralError: Ji, + showJsonPointer: Qi, + sendCurlRequest: Xi, + changeTab: qn, + changeFilter: Fe, + parseChunk: Zi, + parseChunkCompleted: xi, + started: Kr, + loadHappyPathPage: Mr, + happyPathPageLoaded: Es, + reportLoaded: Is, + loadTestsPage: Rr, + testsPageLoaded: wi +} = Wi.actions, Ps = Wi.reducer, js = { messages: [] -}, qi = Ei({ +}, eo = Hi({ name: "logging", - initialState: _s, + initialState: js, reducers: { - showLogMessage: (s, c) => { - s.messages.push(c.payload); + showLogMessage: (u, l) => { + u.messages.push(l.payload); }, - clearLogs: (s) => { - s.messages = []; + clearLogs: (u) => { + u.messages = []; } } -}), { showLogMessage: ws, clearLogs: Ju } = qi.actions, Bi = Ii, Ps = qi.reducer, js = { - theme: Ko, - scan: xs, - router: To, - env: Qo, - prefs: Jo, - config: Xo, - logging: Ps -}, ks = (s, c) => Mo({ - reducer: js, - middleware: (a) => a().prepend(s.middleware).concat(Ro), +}), { showLogMessage: ks, clearLogs: oc } = eo.actions, to = Yi, Ss = eo.reducer, Cs = { + theme: qo, + scan: Ps, + router: No, + env: ts, + prefs: ns, + config: rs, + logging: Ss +}, As = (u, l) => Ko({ + reducer: Cs, + middleware: (f) => f().prepend(u.middleware).concat(Uo), preloadedState: { - theme: c + theme: l } -}), _e = () => Oi(), be = Ii; -var vn = { exports: {} }, Ss = vn.exports, ci; -function Cs() { - return ci || (ci = 1, (function(s, c) { - (function(a, l) { - s.exports = l(); - })(Ss, function() { - var a = function(e, t) { - return (a = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(n, r) { - n.__proto__ = r; - } || function(n, r) { - for (var i in r) Object.prototype.hasOwnProperty.call(r, i) && (n[i] = r[i]); +}), Ve = () => zi(), $e = Yi; +var Un = { exports: {} }, Bs = Un.exports, _i; +function Os() { + return _i || (_i = 1, (function(u, l) { + (function(f, h) { + u.exports = h(); + })(Bs, function() { + var f = function(e, t) { + return (f = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(n, o) { + n.__proto__ = o; + } || function(n, o) { + for (var s in o) Object.prototype.hasOwnProperty.call(o, s) && (n[s] = o[s]); })(e, t); - }, l = function() { - return (l = Object.assign || function(e) { - for (var t, n = 1, r = arguments.length; n < r; n++) for (var i in t = arguments[n]) Object.prototype.hasOwnProperty.call(t, i) && (e[i] = t[i]); + }, h = function() { + return (h = Object.assign || function(e) { + for (var t, n = 1, o = arguments.length; n < o; n++) for (var s in t = arguments[n]) Object.prototype.hasOwnProperty.call(t, s) && (e[s] = t[s]); return e; }).apply(this, arguments); }; - function E(e, t, n) { - for (var r, i = 0, o = t.length; i < o; i++) !r && i in t || ((r = r || Array.prototype.slice.call(t, 0, i))[i] = t[i]); - return e.concat(r || Array.prototype.slice.call(t)); + function T(e, t, n) { + for (var o, s = 0, a = t.length; s < a; s++) !o && s in t || ((o = o || Array.prototype.slice.call(t, 0, s))[s] = t[s]); + return e.concat(o || Array.prototype.slice.call(t)); } - var M = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : Do, C = Object.keys, O = Array.isArray; - function z(e, t) { - return typeof t != "object" || C(t).forEach(function(n) { + var D = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : $o, O = Object.keys, g = Array.isArray; + function G(e, t) { + return typeof t != "object" || O(t).forEach(function(n) { e[n] = t[n]; }), e; } - typeof Promise > "u" || M.Promise || (M.Promise = Promise); - var Y = Object.getPrototypeOf, K = {}.hasOwnProperty; - function B(e, t) { + typeof Promise > "u" || D.Promise || (D.Promise = Promise); + var Q = Object.getPrototypeOf, K = {}.hasOwnProperty; + function N(e, t) { return K.call(e, t); } - function H(e, t) { - typeof t == "function" && (t = t(Y(e))), (typeof Reflect > "u" ? C : Reflect.ownKeys)(t).forEach(function(n) { - ie(e, n, t[n]); + function J(e, t) { + typeof t == "function" && (t = t(Q(e))), (typeof Reflect > "u" ? O : Reflect.ownKeys)(t).forEach(function(n) { + Z(e, n, t[n]); }); } - var w = Object.defineProperty; - function ie(e, t, n, r) { - w(e, t, z(n && B(n, "get") && typeof n.get == "function" ? { get: n.get, set: n.set, configurable: !0 } : { value: n, configurable: !0, writable: !0 }, r)); + var b = Object.defineProperty; + function Z(e, t, n, o) { + b(e, t, G(n && N(n, "get") && typeof n.get == "function" ? { get: n.get, set: n.set, configurable: !0 } : { value: n, configurable: !0, writable: !0 }, o)); } - function Se(e) { + function ue(e) { return { from: function(t) { - return e.prototype = Object.create(t.prototype), ie(e.prototype, "constructor", e), { extend: H.bind(null, e.prototype) }; + return e.prototype = Object.create(t.prototype), Z(e.prototype, "constructor", e), { extend: J.bind(null, e.prototype) }; } }; } - var Nt = Object.getOwnPropertyDescriptor, et = [].slice; - function tt(e, t, n) { - return et.call(e, t, n); + var xe = Object.getOwnPropertyDescriptor, ve = [].slice; + function ye(e, t, n) { + return ve.call(e, t, n); } - function br(e, t) { + function Pe(e, t) { return t(e); } - function mt(e) { + function Ke(e) { if (!e) throw new Error("Assertion Failed"); } - function xr(e) { - M.setImmediate ? setImmediate(e) : setTimeout(e, 0); + function be(e) { + D.setImmediate ? setImmediate(e) : setTimeout(e, 0); } - function Ce(e, t) { - if (typeof t == "string" && B(e, t)) return e[t]; + function Le(e, t) { + if (typeof t == "string" && N(e, t)) return e[t]; if (!t) return e; if (typeof t != "string") { - for (var n = [], r = 0, i = t.length; r < i; ++r) { - var o = Ce(e, t[r]); - n.push(o); + for (var n = [], o = 0, s = t.length; o < s; ++o) { + var a = Le(e, t[o]); + n.push(a); } return n; } - var u = t.indexOf("."); - if (u !== -1) { - var d = e[t.substr(0, u)]; - return d == null ? void 0 : Ce(d, t.substr(u + 1)); + var d = t.indexOf("."); + if (d !== -1) { + var y = e[t.substr(0, d)]; + return y == null ? void 0 : Le(y, t.substr(d + 1)); } } - function me(e, t, n) { + function Ce(e, t, n) { if (e && t !== void 0 && !("isFrozen" in Object && Object.isFrozen(e))) if (typeof t != "string" && "length" in t) { - mt(typeof n != "string" && "length" in n); - for (var r = 0, i = t.length; r < i; ++r) me(e, t[r], n[r]); + Ke(typeof n != "string" && "length" in n); + for (var o = 0, s = t.length; o < s; ++o) Ce(e, t[o], n[o]); } else { - var o, u, d = t.indexOf("."); - d !== -1 ? (o = t.substr(0, d), (u = t.substr(d + 1)) === "" ? n === void 0 ? O(e) && !isNaN(parseInt(o)) ? e.splice(o, 1) : delete e[o] : e[o] = n : me(d = !(d = e[o]) || !B(e, o) ? e[o] = {} : d, u, n)) : n === void 0 ? O(e) && !isNaN(parseInt(t)) ? e.splice(t, 1) : delete e[t] : e[t] = n; + var a, d, y = t.indexOf("."); + y !== -1 ? (a = t.substr(0, y), (d = t.substr(y + 1)) === "" ? n === void 0 ? g(e) && !isNaN(parseInt(a)) ? e.splice(a, 1) : delete e[a] : e[a] = n : Ce(y = !(y = e[a]) || !N(e, a) ? e[a] = {} : y, d, n)) : n === void 0 ? g(e) && !isNaN(parseInt(t)) ? e.splice(t, 1) : delete e[t] : e[t] = n; } } - function _r(e) { + function an(e) { var t, n = {}; - for (t in e) B(e, t) && (n[t] = e[t]); + for (t in e) N(e, t) && (n[t] = e[t]); return n; } - var Gi = [].concat; - function wr(e) { - return Gi.apply([], e); + var zn = [].concat; + function un(e) { + return zn.apply([], e); } - var He = "BigUint64Array,BigInt64Array,Array,Boolean,String,Date,RegExp,Blob,File,FileList,FileSystemFileHandle,FileSystemDirectoryHandle,ArrayBuffer,DataView,Uint8ClampedArray,ImageBitmap,ImageData,Map,Set,CryptoKey".split(",").concat(wr([8, 16, 32, 64].map(function(e) { + var rt = "BigUint64Array,BigInt64Array,Array,Boolean,String,Date,RegExp,Blob,File,FileList,FileSystemFileHandle,FileSystemDirectoryHandle,ArrayBuffer,DataView,Uint8ClampedArray,ImageBitmap,ImageData,Map,Set,CryptoKey".split(",").concat(un([8, 16, 32, 64].map(function(e) { return ["Int", "Uint", "Float"].map(function(t) { return t + e + "Array"; }); }))).filter(function(e) { - return M[e]; - }), Pr = new Set(He.map(function(e) { - return M[e]; - })), vt = null; - function Fe(e) { - return vt = /* @__PURE__ */ new WeakMap(), e = (function t(n) { + return D[e]; + }), cn = new Set(rt.map(function(e) { + return D[e]; + })), mt = null; + function Qe(e) { + return mt = /* @__PURE__ */ new WeakMap(), e = (function t(n) { if (!n || typeof n != "object") return n; - var r = vt.get(n); - if (r) return r; - if (O(n)) { - r = [], vt.set(n, r); - for (var i = 0, o = n.length; i < o; ++i) r.push(t(n[i])); - } else if (Pr.has(n.constructor)) r = n; + var o = mt.get(n); + if (o) return o; + if (g(n)) { + o = [], mt.set(n, o); + for (var s = 0, a = n.length; s < a; ++s) o.push(t(n[s])); + } else if (cn.has(n.constructor)) o = n; else { - var u, d = Y(n); - for (u in r = d === Object.prototype ? {} : Object.create(d), vt.set(n, r), n) B(n, u) && (r[u] = t(n[u])); + var d, y = Q(n); + for (d in o = y === Object.prototype ? {} : Object.create(y), mt.set(n, o), n) N(n, d) && (o[d] = t(n[d])); } - return r; - })(e), vt = null, e; + return o; + })(e), mt = null, e; } - var Ji = {}.toString; - function wn(e) { - return Ji.call(e).slice(8, -1); + var ln = {}.toString; + function jt(e) { + return ln.call(e).slice(8, -1); } - var Pn = typeof Symbol < "u" ? Symbol.iterator : "@@iterator", Xi = typeof Pn == "symbol" ? function(e) { + var Ut = typeof Symbol < "u" ? Symbol.iterator : "@@iterator", Vn = typeof Ut == "symbol" ? function(e) { var t; - return e != null && (t = e[Pn]) && t.apply(e); + return e != null && (t = e[Ut]) && t.apply(e); } : function() { return null; }; - function $e(e, t) { + function Xe(e, t) { return t = e.indexOf(t), 0 <= t && e.splice(t, 1), 0 <= t; } - var nt = {}; - function Ee(e) { - var t, n, r, i; + var at = {}; + function ze(e) { + var t, n, o, s; if (arguments.length === 1) { - if (O(e)) return e.slice(); - if (this === nt && typeof e == "string") return [e]; - if (i = Xi(e)) { - for (n = []; !(r = i.next()).done; ) n.push(r.value); + if (g(e)) return e.slice(); + if (this === at && typeof e == "string") return [e]; + if (s = Vn(e)) { + for (n = []; !(o = s.next()).done; ) n.push(o.value); return n; } if (e == null) return [e]; @@ -275,470 +275,470 @@ function Cs() { for (t = arguments.length, n = new Array(t); t--; ) n[t] = arguments[t]; return n; } - var jn = typeof Symbol < "u" ? function(e) { + var we = typeof Symbol < "u" ? function(e) { return e[Symbol.toStringTag] === "AsyncFunction"; } : function() { return !1; - }, xt = ["Unknown", "Constraint", "Data", "TransactionInactive", "ReadOnly", "Version", "NotFound", "InvalidState", "InvalidAccess", "Abort", "Timeout", "QuotaExceeded", "Syntax", "DataClone"], xe = ["Modify", "Bulk", "OpenFailed", "VersionChange", "Schema", "Upgrade", "InvalidTable", "MissingAPI", "NoSuchDatabase", "InvalidArgument", "SubTransaction", "Unsupported", "Internal", "DatabaseClosed", "PrematureCommit", "ForeignAwait"].concat(xt), Zi = { VersionChanged: "Database version changed by other database connection", DatabaseClosed: "Database has been closed", Abort: "Transaction aborted", TransactionInactive: "Transaction has already completed or failed", MissingAPI: "IndexedDB API missing. Please visit https://tinyurl.com/y2uuvskb" }; - function rt(e, t) { + }, De = ["Unknown", "Constraint", "Data", "TransactionInactive", "ReadOnly", "Version", "NotFound", "InvalidState", "InvalidAccess", "Abort", "Timeout", "QuotaExceeded", "Syntax", "DataClone"], Ye = ["Modify", "Bulk", "OpenFailed", "VersionChange", "Schema", "Upgrade", "InvalidTable", "MissingAPI", "NoSuchDatabase", "InvalidArgument", "SubTransaction", "Unsupported", "Internal", "DatabaseClosed", "PrematureCommit", "ForeignAwait"].concat(De), Ae = { VersionChanged: "Database version changed by other database connection", DatabaseClosed: "Database has been closed", Abort: "Transaction aborted", TransactionInactive: "Transaction has already completed or failed", MissingAPI: "IndexedDB API missing. Please visit https://tinyurl.com/y2uuvskb" }; + function Ze(e, t) { this.name = e, this.message = t; } - function jr(e, t) { + function $t(e, t) { return e + ". Errors: " + Object.keys(t).map(function(n) { return t[n].toString(); - }).filter(function(n, r, i) { - return i.indexOf(n) === r; + }).filter(function(n, o, s) { + return s.indexOf(n) === o; }).join(` `); } - function qt(e, t, n, r) { - this.failures = t, this.failedKeys = r, this.successCount = n, this.message = jr(e, t); + function gt(e, t, n, o) { + this.failures = t, this.failedKeys = o, this.successCount = n, this.message = $t(e, t); } - function it(e, t) { + function et(e, t) { this.name = "BulkError", this.failures = Object.keys(t).map(function(n) { return t[n]; - }), this.failuresByPos = t, this.message = jr(e, this.failures); + }), this.failuresByPos = t, this.message = $t(e, this.failures); } - Se(rt).from(Error).extend({ toString: function() { + ue(Ze).from(Error).extend({ toString: function() { return this.name + ": " + this.message; - } }), Se(qt).from(rt), Se(it).from(rt); - var kn = xe.reduce(function(e, t) { + } }), ue(gt).from(Ze), ue(et).from(Ze); + var kt = Ye.reduce(function(e, t) { return e[t] = t + "Error", e; - }, {}), eo = rt, U = xe.reduce(function(e, t) { + }, {}), ut = Ze, X = Ye.reduce(function(e, t) { var n = t + "Error"; - function r(i, o) { - this.name = n, i ? typeof i == "string" ? (this.message = "".concat(i).concat(o ? ` - ` + o : ""), this.inner = o || null) : typeof i == "object" && (this.message = "".concat(i.name, " ").concat(i.message), this.inner = i) : (this.message = Zi[t] || n, this.inner = null); + function o(s, a) { + this.name = n, s ? typeof s == "string" ? (this.message = "".concat(s).concat(a ? ` + ` + a : ""), this.inner = a || null) : typeof s == "object" && (this.message = "".concat(s.name, " ").concat(s.message), this.inner = s) : (this.message = Ae[t] || n, this.inner = null); } - return Se(r).from(eo), e[t] = r, e; + return ue(o).from(ut), e[t] = o, e; }, {}); - U.Syntax = SyntaxError, U.Type = TypeError, U.Range = RangeError; - var kr = xt.reduce(function(e, t) { - return e[t + "Error"] = U[t], e; - }, {}), Bt = xe.reduce(function(e, t) { - return ["Syntax", "Type", "Range"].indexOf(t) === -1 && (e[t + "Error"] = U[t]), e; + X.Syntax = SyntaxError, X.Type = TypeError, X.Range = RangeError; + var Lt = De.reduce(function(e, t) { + return e[t + "Error"] = X[t], e; + }, {}), St = Ye.reduce(function(e, t) { + return ["Syntax", "Type", "Range"].indexOf(t) === -1 && (e[t + "Error"] = X[t]), e; }, {}); - function te() { + function he() { } - function gt(e) { + function He(e) { return e; } - function to(e, t) { - return e == null || e === gt ? t : function(n) { + function vt(e, t) { + return e == null || e === He ? t : function(n) { return t(e(n)); }; } - function Le(e, t) { + function tt(e, t) { return function() { e.apply(this, arguments), t.apply(this, arguments); }; } - function no(e, t) { - return e === te ? t : function() { + function Wn(e, t) { + return e === he ? t : function() { var n = e.apply(this, arguments); n !== void 0 && (arguments[0] = n); - var r = this.onsuccess, i = this.onerror; + var o = this.onsuccess, s = this.onerror; this.onsuccess = null, this.onerror = null; - var o = t.apply(this, arguments); - return r && (this.onsuccess = this.onsuccess ? Le(r, this.onsuccess) : r), i && (this.onerror = this.onerror ? Le(i, this.onerror) : i), o !== void 0 ? o : n; + var a = t.apply(this, arguments); + return o && (this.onsuccess = this.onsuccess ? tt(o, this.onsuccess) : o), s && (this.onerror = this.onerror ? tt(s, this.onerror) : s), a !== void 0 ? a : n; }; } - function ro(e, t) { - return e === te ? t : function() { + function Ht(e, t) { + return e === he ? t : function() { e.apply(this, arguments); - var n = this.onsuccess, r = this.onerror; - this.onsuccess = this.onerror = null, t.apply(this, arguments), n && (this.onsuccess = this.onsuccess ? Le(n, this.onsuccess) : n), r && (this.onerror = this.onerror ? Le(r, this.onerror) : r); + var n = this.onsuccess, o = this.onerror; + this.onsuccess = this.onerror = null, t.apply(this, arguments), n && (this.onsuccess = this.onsuccess ? tt(n, this.onsuccess) : n), o && (this.onerror = this.onerror ? tt(o, this.onerror) : o); }; } - function io(e, t) { - return e === te ? t : function(n) { - var r = e.apply(this, arguments); - z(n, r); - var i = this.onsuccess, o = this.onerror; - return this.onsuccess = null, this.onerror = null, n = t.apply(this, arguments), i && (this.onsuccess = this.onsuccess ? Le(i, this.onsuccess) : i), o && (this.onerror = this.onerror ? Le(o, this.onerror) : o), r === void 0 ? n === void 0 ? void 0 : n : z(r, n); + function Gn(e, t) { + return e === he ? t : function(n) { + var o = e.apply(this, arguments); + G(n, o); + var s = this.onsuccess, a = this.onerror; + return this.onsuccess = null, this.onerror = null, n = t.apply(this, arguments), s && (this.onsuccess = this.onsuccess ? tt(s, this.onsuccess) : s), a && (this.onerror = this.onerror ? tt(a, this.onerror) : a), o === void 0 ? n === void 0 ? void 0 : n : G(o, n); }; } - function oo(e, t) { - return e === te ? t : function() { + function Jn(e, t) { + return e === he ? t : function() { return t.apply(this, arguments) !== !1 && e.apply(this, arguments); }; } - function Sn(e, t) { - return e === te ? t : function() { + function Ct(e, t) { + return e === he ? t : function() { var n = e.apply(this, arguments); if (n && typeof n.then == "function") { - for (var r = this, i = arguments.length, o = new Array(i); i--; ) o[i] = arguments[i]; + for (var o = this, s = arguments.length, a = new Array(s); s--; ) a[s] = arguments[s]; return n.then(function() { - return t.apply(r, o); + return t.apply(o, a); }); } return t.apply(this, arguments); }; } - Bt.ModifyError = qt, Bt.DexieError = rt, Bt.BulkError = it; - var we = typeof location < "u" && /^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href); - function Sr(e) { - we = e; + St.ModifyError = gt, St.DexieError = Ze, St.BulkError = et; + var Me = typeof location < "u" && /^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href); + function Ne(e) { + Me = e; } - var bt = {}, Cr = 100, He = typeof Promise > "u" ? [] : (function() { + var nt = {}, fn = 100, rt = typeof Promise > "u" ? [] : (function() { var e = Promise.resolve(); - if (typeof crypto > "u" || !crypto.subtle) return [e, Y(e), e]; + if (typeof crypto > "u" || !crypto.subtle) return [e, Q(e), e]; var t = crypto.subtle.digest("SHA-512", new Uint8Array([0])); - return [t, Y(t), e]; - })(), xt = He[0], xe = He[1], He = He[2], xe = xe && xe.then, Ue = xt && xt.constructor, Cn = !!He, _t = function(e, t) { - wt.push([e, t]), Ft && (queueMicrotask(ao), Ft = !1); - }, En = !0, Ft = !0, ze = [], $t = [], In = gt, Me = { id: "global", global: !0, ref: 0, unhandleds: [], onunhandled: te, pgp: !1, env: {}, finalize: te }, $ = Me, wt = [], Ye = 0, Lt = []; - function q(e) { + return [t, Q(t), e]; + })(), De = rt[0], Ye = rt[1], rt = rt[2], Ye = Ye && Ye.then, c = De && De.constructor, r = !!rt, i = function(e, t) { + pe.push([e, t]), E && (queueMicrotask(po), E = !1); + }, p = !0, E = !0, A = [], R = [], oe = He, de = { id: "global", global: !0, ref: 0, unhandleds: [], onunhandled: he, pgp: !1, env: {}, finalize: he }, L = de, pe = [], ce = 0, hn = []; + function V(e) { if (typeof this != "object") throw new TypeError("Promises must be constructed via new"); this._listeners = [], this._lib = !1; - var t = this._PSD = $; + var t = this._PSD = L; if (typeof e != "function") { - if (e !== bt) throw new TypeError("Not a function"); - return this._state = arguments[1], this._value = arguments[2], void (this._state === !1 && An(this, this._value)); + if (e !== nt) throw new TypeError("Not a function"); + return this._state = arguments[1], this._value = arguments[2], void (this._state === !1 && Xn(this, this._value)); } - this._state = null, this._value = null, ++t.ref, (function n(r, i) { + this._state = null, this._value = null, ++t.ref, (function n(o, s) { try { - i(function(o) { - if (r._state === null) { - if (o === r) throw new TypeError("A promise cannot be resolved with itself."); - var u = r._lib && ot(); - o && typeof o.then == "function" ? n(r, function(d, p) { - o instanceof q ? o._then(d, p) : o.then(d, p); - }) : (r._state = !0, r._value = o, Ir(r)), u && st(); + s(function(a) { + if (o._state === null) { + if (a === o) throw new TypeError("A promise cannot be resolved with itself."); + var d = o._lib && At(); + a && typeof a.then == "function" ? n(o, function(y, x) { + a instanceof V ? a._then(y, x) : a.then(y, x); + }) : (o._state = !0, o._value = a, $r(o)), d && Bt(); } - }, An.bind(null, r)); - } catch (o) { - An(r, o); + }, Xn.bind(null, o)); + } catch (a) { + Xn(o, a); } })(this, e); } - var On = { get: function() { - var e = $, t = Yt; - function n(r, i) { - var o = this, u = !e.global && (e !== $ || t !== Yt), d = u && !Ke(), p = new q(function(y, b) { - Mn(o, new Er(Ar(r, e, u, d), Ar(i, e, u, d), y, b, e)); + var Qn = { get: function() { + var e = L, t = mn; + function n(o, s) { + var a = this, d = !e.global && (e !== L || t !== mn), y = d && !lt(), x = new V(function(w, j) { + Zn(a, new Ur(Hr(o, e, d, y), Hr(s, e, d, y), w, j, e)); }); - return this._consoleTask && (p._consoleTask = this._consoleTask), p; + return this._consoleTask && (x._consoleTask = this._consoleTask), x; } - return n.prototype = bt, n; + return n.prototype = nt, n; }, set: function(e) { - ie(this, "then", e && e.prototype === bt ? On : { get: function() { + Z(this, "then", e && e.prototype === nt ? Qn : { get: function() { return e; - }, set: On.set }); + }, set: Qn.set }); } }; - function Er(e, t, n, r, i) { - this.onFulfilled = typeof e == "function" ? e : null, this.onRejected = typeof t == "function" ? t : null, this.resolve = n, this.reject = r, this.psd = i; + function Ur(e, t, n, o, s) { + this.onFulfilled = typeof e == "function" ? e : null, this.onRejected = typeof t == "function" ? t : null, this.resolve = n, this.reject = o, this.psd = s; } - function An(e, t) { - var n, r; - $t.push(t), e._state === null && (n = e._lib && ot(), t = In(t), e._state = !1, e._value = t, r = e, ze.some(function(i) { - return i._value === r._value; - }) || ze.push(r), Ir(e), n && st()); + function Xn(e, t) { + var n, o; + R.push(t), e._state === null && (n = e._lib && At(), t = oe(t), e._state = !1, e._value = t, o = e, A.some(function(s) { + return s._value === o._value; + }) || A.push(o), $r(e), n && Bt()); } - function Ir(e) { + function $r(e) { var t = e._listeners; e._listeners = []; - for (var n = 0, r = t.length; n < r; ++n) Mn(e, t[n]); - var i = e._PSD; - --i.ref || i.finalize(), Ye === 0 && (++Ye, _t(function() { - --Ye == 0 && Tn(); + for (var n = 0, o = t.length; n < o; ++n) Zn(e, t[n]); + var s = e._PSD; + --s.ref || s.finalize(), ce === 0 && (++ce, i(function() { + --ce == 0 && er(); }, [])); } - function Mn(e, t) { + function Zn(e, t) { if (e._state !== null) { var n = e._state ? t.onFulfilled : t.onRejected; if (n === null) return (e._state ? t.resolve : t.reject)(e._value); - ++t.psd.ref, ++Ye, _t(so, [n, e, t]); + ++t.psd.ref, ++ce, i(ho, [n, e, t]); } else e._listeners.push(t); } - function so(e, t, n) { + function ho(e, t, n) { try { - var r, i = t._value; - !t._state && $t.length && ($t = []), r = we && t._consoleTask ? t._consoleTask.run(function() { - return e(i); - }) : e(i), t._state || $t.indexOf(i) !== -1 || (function(o) { - for (var u = ze.length; u; ) if (ze[--u]._value === o._value) return ze.splice(u, 1); - })(t), n.resolve(r); - } catch (o) { - n.reject(o); + var o, s = t._value; + !t._state && R.length && (R = []), o = Me && t._consoleTask ? t._consoleTask.run(function() { + return e(s); + }) : e(s), t._state || R.indexOf(s) !== -1 || (function(a) { + for (var d = A.length; d; ) if (A[--d]._value === a._value) return A.splice(d, 1); + })(t), n.resolve(o); + } catch (a) { + n.reject(a); } finally { - --Ye == 0 && Tn(), --n.psd.ref || n.psd.finalize(); + --ce == 0 && er(), --n.psd.ref || n.psd.finalize(); } } - function ao() { - Ve(Me, function() { - ot() && st(); + function po() { + bt(de, function() { + At() && Bt(); }); } - function ot() { - var e = En; - return Ft = En = !1, e; + function At() { + var e = p; + return E = p = !1, e; } - function st() { + function Bt() { var e, t, n; do - for (; 0 < wt.length; ) for (e = wt, wt = [], n = e.length, t = 0; t < n; ++t) { - var r = e[t]; - r[0].apply(null, r[1]); + for (; 0 < pe.length; ) for (e = pe, pe = [], n = e.length, t = 0; t < n; ++t) { + var o = e[t]; + o[0].apply(null, o[1]); } - while (0 < wt.length); - Ft = En = !0; + while (0 < pe.length); + E = p = !0; } - function Tn() { - var e = ze; - ze = [], e.forEach(function(r) { - r._PSD.onunhandled.call(null, r._value, r); + function er() { + var e = A; + A = [], e.forEach(function(o) { + o._PSD.onunhandled.call(null, o._value, o); }); - for (var t = Lt.slice(0), n = t.length; n; ) t[--n](); + for (var t = hn.slice(0), n = t.length; n; ) t[--n](); } - function Ht(e) { - return new q(bt, !1, e); + function dn(e) { + return new V(nt, !1, e); } - function re(e, t) { - var n = $; + function ge(e, t) { + var n = L; return function() { - var r = ot(), i = $; + var o = At(), s = L; try { - return Re(n, !0), e.apply(this, arguments); - } catch (o) { - t && t(o); + return ft(n, !0), e.apply(this, arguments); + } catch (a) { + t && t(a); } finally { - Re(i, !1), r && st(); + ft(s, !1), o && Bt(); } }; } - H(q.prototype, { then: On, _then: function(e, t) { - Mn(this, new Er(null, null, e, t, $)); + J(V.prototype, { then: Qn, _then: function(e, t) { + Zn(this, new Ur(null, null, e, t, L)); }, catch: function(e) { if (arguments.length === 1) return this.then(null, e); var t = e, n = arguments[1]; - return typeof t == "function" ? this.then(null, function(r) { - return (r instanceof t ? n : Ht)(r); - }) : this.then(null, function(r) { - return (r && r.name === t ? n : Ht)(r); + return typeof t == "function" ? this.then(null, function(o) { + return (o instanceof t ? n : dn)(o); + }) : this.then(null, function(o) { + return (o && o.name === t ? n : dn)(o); }); }, finally: function(e) { return this.then(function(t) { - return q.resolve(e()).then(function() { + return V.resolve(e()).then(function() { return t; }); }, function(t) { - return q.resolve(e()).then(function() { - return Ht(t); + return V.resolve(e()).then(function() { + return dn(t); }); }); }, timeout: function(e, t) { var n = this; - return e < 1 / 0 ? new q(function(r, i) { - var o = setTimeout(function() { - return i(new U.Timeout(t)); + return e < 1 / 0 ? new V(function(o, s) { + var a = setTimeout(function() { + return s(new X.Timeout(t)); }, e); - n.then(r, i).finally(clearTimeout.bind(null, o)); + n.then(o, s).finally(clearTimeout.bind(null, a)); }) : this; - } }), typeof Symbol < "u" && Symbol.toStringTag && ie(q.prototype, Symbol.toStringTag, "Dexie.Promise"), Me.env = Or(), H(q, { all: function() { - var e = Ee.apply(null, arguments).map(Vt); - return new q(function(t, n) { + } }), typeof Symbol < "u" && Symbol.toStringTag && Z(V.prototype, Symbol.toStringTag, "Dexie.Promise"), de.env = Lr(), J(V, { all: function() { + var e = ze.apply(null, arguments).map(gn); + return new V(function(t, n) { e.length === 0 && t([]); - var r = e.length; - e.forEach(function(i, o) { - return q.resolve(i).then(function(u) { - e[o] = u, --r || t(e); + var o = e.length; + e.forEach(function(s, a) { + return V.resolve(s).then(function(d) { + e[a] = d, --o || t(e); }, n); }); }); }, resolve: function(e) { - return e instanceof q ? e : e && typeof e.then == "function" ? new q(function(t, n) { + return e instanceof V ? e : e && typeof e.then == "function" ? new V(function(t, n) { e.then(t, n); - }) : new q(bt, !0, e); - }, reject: Ht, race: function() { - var e = Ee.apply(null, arguments).map(Vt); - return new q(function(t, n) { - e.map(function(r) { - return q.resolve(r).then(t, n); + }) : new V(nt, !0, e); + }, reject: dn, race: function() { + var e = ze.apply(null, arguments).map(gn); + return new V(function(t, n) { + e.map(function(o) { + return V.resolve(o).then(t, n); }); }); }, PSD: { get: function() { - return $; + return L; }, set: function(e) { - return $ = e; + return L = e; } }, totalEchoes: { get: function() { - return Yt; - } }, newPSD: Te, usePSD: Ve, scheduler: { get: function() { - return _t; + return mn; + } }, newPSD: ct, usePSD: bt, scheduler: { get: function() { + return i; }, set: function(e) { - _t = e; + i = e; } }, rejectionMapper: { get: function() { - return In; + return oe; }, set: function(e) { - In = e; + oe = e; } }, follow: function(e, t) { - return new q(function(n, r) { - return Te(function(i, o) { - var u = $; - u.unhandleds = [], u.onunhandled = o, u.finalize = Le(function() { - var d, p = this; - d = function() { - p.unhandleds.length === 0 ? i() : o(p.unhandleds[0]); - }, Lt.push(function y() { - d(), Lt.splice(Lt.indexOf(y), 1); - }), ++Ye, _t(function() { - --Ye == 0 && Tn(); + return new V(function(n, o) { + return ct(function(s, a) { + var d = L; + d.unhandleds = [], d.onunhandled = a, d.finalize = tt(function() { + var y, x = this; + y = function() { + x.unhandleds.length === 0 ? s() : a(x.unhandleds[0]); + }, hn.push(function w() { + y(), hn.splice(hn.indexOf(w), 1); + }), ++ce, i(function() { + --ce == 0 && er(); }, []); - }, u.finalize), e(); - }, t, n, r); + }, d.finalize), e(); + }, t, n, o); }); - } }), Ue && (Ue.allSettled && ie(q, "allSettled", function() { - var e = Ee.apply(null, arguments).map(Vt); - return new q(function(t) { + } }), c && (c.allSettled && Z(V, "allSettled", function() { + var e = ze.apply(null, arguments).map(gn); + return new V(function(t) { e.length === 0 && t([]); - var n = e.length, r = new Array(n); - e.forEach(function(i, o) { - return q.resolve(i).then(function(u) { - return r[o] = { status: "fulfilled", value: u }; - }, function(u) { - return r[o] = { status: "rejected", reason: u }; + var n = e.length, o = new Array(n); + e.forEach(function(s, a) { + return V.resolve(s).then(function(d) { + return o[a] = { status: "fulfilled", value: d }; + }, function(d) { + return o[a] = { status: "rejected", reason: d }; }).then(function() { - return --n || t(r); + return --n || t(o); }); }); }); - }), Ue.any && typeof AggregateError < "u" && ie(q, "any", function() { - var e = Ee.apply(null, arguments).map(Vt); - return new q(function(t, n) { + }), c.any && typeof AggregateError < "u" && Z(V, "any", function() { + var e = ze.apply(null, arguments).map(gn); + return new V(function(t, n) { e.length === 0 && n(new AggregateError([])); - var r = e.length, i = new Array(r); - e.forEach(function(o, u) { - return q.resolve(o).then(function(d) { - return t(d); - }, function(d) { - i[u] = d, --r || n(new AggregateError(i)); + var o = e.length, s = new Array(o); + e.forEach(function(a, d) { + return V.resolve(a).then(function(y) { + return t(y); + }, function(y) { + s[d] = y, --o || n(new AggregateError(s)); }); }); }); - }), Ue.withResolvers && (q.withResolvers = Ue.withResolvers)); - var ue = { awaits: 0, echoes: 0, id: 0 }, uo = 0, Ut = [], zt = 0, Yt = 0, co = 0; - function Te(e, t, n, r) { - var i = $, o = Object.create(i); - return o.parent = i, o.ref = 0, o.global = !1, o.id = ++co, Me.env, o.env = Cn ? { Promise: q, PromiseProp: { value: q, configurable: !0, writable: !0 }, all: q.all, race: q.race, allSettled: q.allSettled, any: q.any, resolve: q.resolve, reject: q.reject } : {}, t && z(o, t), ++i.ref, o.finalize = function() { + }), c.withResolvers && (V.withResolvers = c.withResolvers)); + var je = { awaits: 0, echoes: 0, id: 0 }, yo = 0, pn = [], yn = 0, mn = 0, mo = 0; + function ct(e, t, n, o) { + var s = L, a = Object.create(s); + return a.parent = s, a.ref = 0, a.global = !1, a.id = ++mo, de.env, a.env = r ? { Promise: V, PromiseProp: { value: V, configurable: !0, writable: !0 }, all: V.all, race: V.race, allSettled: V.allSettled, any: V.any, resolve: V.resolve, reject: V.reject } : {}, t && G(a, t), ++s.ref, a.finalize = function() { --this.parent.ref || this.parent.finalize(); - }, r = Ve(o, e, n, r), o.ref === 0 && o.finalize(), r; + }, o = bt(a, e, n, o), a.ref === 0 && a.finalize(), o; } - function at() { - return ue.id || (ue.id = ++uo), ++ue.awaits, ue.echoes += Cr, ue.id; + function Ot() { + return je.id || (je.id = ++yo), ++je.awaits, je.echoes += fn, je.id; } - function Ke() { - return !!ue.awaits && (--ue.awaits == 0 && (ue.id = 0), ue.echoes = ue.awaits * Cr, !0); + function lt() { + return !!je.awaits && (--je.awaits == 0 && (je.id = 0), je.echoes = je.awaits * fn, !0); } - function Vt(e) { - return ue.echoes && e && e.constructor === Ue ? (at(), e.then(function(t) { - return Ke(), t; + function gn(e) { + return je.echoes && e && e.constructor === c ? (Ot(), e.then(function(t) { + return lt(), t; }, function(t) { - return Ke(), oe(t); + return lt(), _e(t); })) : e; } - function lo() { - var e = Ut[Ut.length - 1]; - Ut.pop(), Re(e, !1); + function go() { + var e = pn[pn.length - 1]; + pn.pop(), ft(e, !1); } - function Re(e, t) { - var n, r = $; - (t ? !ue.echoes || zt++ && e === $ : !zt || --zt && e === $) || queueMicrotask(t ? (function(i) { - ++Yt, ue.echoes && --ue.echoes != 0 || (ue.echoes = ue.awaits = ue.id = 0), Ut.push($), Re(i, !0); - }).bind(null, e) : lo), e !== $ && ($ = e, r === Me && (Me.env = Or()), Cn && (n = Me.env.Promise, t = e.env, (r.global || e.global) && (Object.defineProperty(M, "Promise", t.PromiseProp), n.all = t.all, n.race = t.race, n.resolve = t.resolve, n.reject = t.reject, t.allSettled && (n.allSettled = t.allSettled), t.any && (n.any = t.any)))); + function ft(e, t) { + var n, o = L; + (t ? !je.echoes || yn++ && e === L : !yn || --yn && e === L) || queueMicrotask(t ? (function(s) { + ++mn, je.echoes && --je.echoes != 0 || (je.echoes = je.awaits = je.id = 0), pn.push(L), ft(s, !0); + }).bind(null, e) : go), e !== L && (L = e, o === de && (de.env = Lr()), r && (n = de.env.Promise, t = e.env, (o.global || e.global) && (Object.defineProperty(D, "Promise", t.PromiseProp), n.all = t.all, n.race = t.race, n.resolve = t.resolve, n.reject = t.reject, t.allSettled && (n.allSettled = t.allSettled), t.any && (n.any = t.any)))); } - function Or() { - var e = M.Promise; - return Cn ? { Promise: e, PromiseProp: Object.getOwnPropertyDescriptor(M, "Promise"), all: e.all, race: e.race, allSettled: e.allSettled, any: e.any, resolve: e.resolve, reject: e.reject } : {}; + function Lr() { + var e = D.Promise; + return r ? { Promise: e, PromiseProp: Object.getOwnPropertyDescriptor(D, "Promise"), all: e.all, race: e.race, allSettled: e.allSettled, any: e.any, resolve: e.resolve, reject: e.reject } : {}; } - function Ve(e, t, n, r, i) { - var o = $; + function bt(e, t, n, o, s) { + var a = L; try { - return Re(e, !0), t(n, r, i); + return ft(e, !0), t(n, o, s); } finally { - Re(o, !1); + ft(a, !1); } } - function Ar(e, t, n, r) { + function Hr(e, t, n, o) { return typeof e != "function" ? e : function() { - var i = $; - n && at(), Re(t, !0); + var s = L; + n && Ot(), ft(t, !0); try { return e.apply(this, arguments); } finally { - Re(i, !1), r && queueMicrotask(Ke); + ft(s, !1), o && queueMicrotask(lt); } }; } - function Kn(e) { - Promise === Ue && ue.echoes === 0 ? zt === 0 ? e() : enqueueNativeMicroTask(e) : setTimeout(e, 0); + function tr(e) { + Promise === c && je.echoes === 0 ? yn === 0 ? e() : enqueueNativeMicroTask(e) : setTimeout(e, 0); } - ("" + xe).indexOf("[native code]") === -1 && (at = Ke = te); - var oe = q.reject, We = "￿", Ie = "Invalid key provided. Keys must be of type string, number, Date or Array.", Mr = "String expected.", ut = [], Wt = "__dbnames", Rn = "readonly", Dn = "readwrite"; - function Qe(e, t) { + ("" + Ye).indexOf("[native code]") === -1 && (Ot = lt = he); + var _e = V.reject, xt = "￿", it = "Invalid key provided. Keys must be of type string, number, Date or Array.", Yr = "String expected.", Tt = [], vn = "__dbnames", nr = "readonly", rr = "readwrite"; + function wt(e, t) { return e ? t ? function() { return e.apply(this, arguments) && t.apply(this, arguments); } : e : t; } - var Tr = { type: 3, lower: -1 / 0, lowerOpen: !1, upper: [[]], upperOpen: !1 }; - function Qt(e) { + var zr = { type: 3, lower: -1 / 0, lowerOpen: !1, upper: [[]], upperOpen: !1 }; + function bn(e) { return typeof e != "string" || /\./.test(e) ? function(t) { return t; } : function(t) { - return t[e] === void 0 && e in t && delete (t = Fe(t))[e], t; + return t[e] === void 0 && e in t && delete (t = Qe(t))[e], t; }; } - function Kr() { - throw U.Type("Entity instances must never be new:ed. Instances are generated by the framework bypassing the constructor."); + function Vr() { + throw X.Type("Entity instances must never be new:ed. Instances are generated by the framework bypassing the constructor."); } - function Z(e, t) { + function le(e, t) { try { - var n = Rr(e), r = Rr(t); - if (n !== r) return n === "Array" ? 1 : r === "Array" ? -1 : n === "binary" ? 1 : r === "binary" ? -1 : n === "string" ? 1 : r === "string" ? -1 : n === "Date" ? 1 : r !== "Date" ? NaN : -1; + var n = Wr(e), o = Wr(t); + if (n !== o) return n === "Array" ? 1 : o === "Array" ? -1 : n === "binary" ? 1 : o === "binary" ? -1 : n === "string" ? 1 : o === "string" ? -1 : n === "Date" ? 1 : o !== "Date" ? NaN : -1; switch (n) { case "number": case "Date": case "string": return t < e ? 1 : e < t ? -1 : 0; case "binary": - return (function(i, o) { - for (var u = i.length, d = o.length, p = u < d ? u : d, y = 0; y < p; ++y) if (i[y] !== o[y]) return i[y] < o[y] ? -1 : 1; - return u === d ? 0 : u < d ? -1 : 1; - })(Dr(e), Dr(t)); + return (function(s, a) { + for (var d = s.length, y = a.length, x = d < y ? d : y, w = 0; w < x; ++w) if (s[w] !== a[w]) return s[w] < a[w] ? -1 : 1; + return d === y ? 0 : d < y ? -1 : 1; + })(Gr(e), Gr(t)); case "Array": - return (function(i, o) { - for (var u = i.length, d = o.length, p = u < d ? u : d, y = 0; y < p; ++y) { - var b = Z(i[y], o[y]); - if (b !== 0) return b; + return (function(s, a) { + for (var d = s.length, y = a.length, x = d < y ? d : y, w = 0; w < x; ++w) { + var j = le(s[w], a[w]); + if (j !== 0) return j; } - return u === d ? 0 : u < d ? -1 : 1; + return d === y ? 0 : d < y ? -1 : 1; })(e, t); } } catch { } return NaN; } - function Rr(e) { + function Wr(e) { var t = typeof e; - return t != "object" ? t : ArrayBuffer.isView(e) ? "binary" : (e = wn(e), e === "ArrayBuffer" ? "binary" : e); + return t != "object" ? t : ArrayBuffer.isView(e) ? "binary" : (e = jt(e), e === "ArrayBuffer" ? "binary" : e); } - function Dr(e) { + function Gr(e) { return e instanceof Uint8Array ? e : ArrayBuffer.isView(e) ? new Uint8Array(e.buffer, e.byteOffset, e.byteLength) : new Uint8Array(e); } - function Gt(e, t, n) { - var r = e.schema.yProps; - return r ? (t && 0 < n.numFailures && (t = t.filter(function(i, o) { - return !n.failures[o]; - })), Promise.all(r.map(function(i) { - return i = i.updatesTable, t ? e.db.table(i).where("k").anyOf(t).delete() : e.db.table(i).clear(); + function xn(e, t, n) { + var o = e.schema.yProps; + return o ? (t && 0 < n.numFailures && (t = t.filter(function(s, a) { + return !n.failures[a]; + })), Promise.all(o.map(function(s) { + return s = s.updatesTable, t ? e.db.table(s).where("k").anyOf(t).delete() : e.db.table(s).clear(); })).then(function() { return n; })) : n; } - var Pt = (Nr.prototype.execute = function(e) { + var Yt = (Jr.prototype.execute = function(e) { var t = this["@@propmod"]; if (t.add !== void 0) { var n = t.add; - if (O(n)) return E(E([], O(e) ? e : [], !0), n).sort(); + if (g(n)) return T(T([], g(e) ? e : [], !0), n).sort(); if (typeof n == "number") return (Number(e) || 0) + n; if (typeof n == "bigint") try { return BigInt(e) + n; @@ -748,348 +748,348 @@ function Cs() { throw new TypeError("Invalid term ".concat(n)); } if (t.remove !== void 0) { - var r = t.remove; - if (O(r)) return O(e) ? e.filter(function(i) { - return !r.includes(i); + var o = t.remove; + if (g(o)) return g(e) ? e.filter(function(s) { + return !o.includes(s); }).sort() : []; - if (typeof r == "number") return Number(e) - r; - if (typeof r == "bigint") try { - return BigInt(e) - r; + if (typeof o == "number") return Number(e) - o; + if (typeof o == "bigint") try { + return BigInt(e) - o; } catch { - return BigInt(0) - r; + return BigInt(0) - o; } - throw new TypeError("Invalid subtrahend ".concat(r)); + throw new TypeError("Invalid subtrahend ".concat(o)); } return n = (n = t.replacePrefix) === null || n === void 0 ? void 0 : n[0], n && typeof e == "string" && e.startsWith(n) ? t.replacePrefix[1] + e.substring(n.length) : e; - }, Nr); - function Nr(e) { + }, Jr); + function Jr(e) { this["@@propmod"] = e; } - function qr(e, t) { - for (var n = C(t), r = n.length, i = !1, o = 0; o < r; ++o) { - var u = n[o], d = t[u], p = Ce(e, u); - d instanceof Pt ? (me(e, u, d.execute(p)), i = !0) : p !== d && (me(e, u, d), i = !0); + function Qr(e, t) { + for (var n = O(t), o = n.length, s = !1, a = 0; a < o; ++a) { + var d = n[a], y = t[d], x = Le(e, d); + y instanceof Yt ? (Ce(e, d, y.execute(x)), s = !0) : x !== y && (Ce(e, d, y), s = !0); } - return i; + return s; } - var Br = (ne.prototype._trans = function(e, t, n) { - var r = this._tx || $.trans, i = this.name, o = we && typeof console < "u" && console.createTask && console.createTask("Dexie: ".concat(e === "readonly" ? "read" : "write", " ").concat(this.name)); - function u(y, b, h) { - if (!h.schema[i]) throw new U.NotFound("Table " + i + " not part of transaction"); - return t(h.idbtrans, h); + var Xr = (me.prototype._trans = function(e, t, n) { + var o = this._tx || L.trans, s = this.name, a = Me && typeof console < "u" && console.createTask && console.createTask("Dexie: ".concat(e === "readonly" ? "read" : "write", " ").concat(this.name)); + function d(w, j, v) { + if (!v.schema[s]) throw new X.NotFound("Table " + s + " not part of transaction"); + return t(v.idbtrans, v); } - var d = ot(); + var y = At(); try { - var p = r && r.db._novip === this.db._novip ? r === $.trans ? r._promise(e, u, n) : Te(function() { - return r._promise(e, u, n); - }, { trans: r, transless: $.transless || $ }) : (function y(b, h, _, m) { - if (b.idbdb && (b._state.openComplete || $.letThrough || b._vip)) { - var v = b._createTransaction(h, _, b._dbSchema); + var x = o && o.db._novip === this.db._novip ? o === L.trans ? o._promise(e, d, n) : ct(function() { + return o._promise(e, d, n); + }, { trans: o, transless: L.transless || L }) : (function w(j, v, S, _) { + if (j.idbdb && (j._state.openComplete || L.letThrough || j._vip)) { + var I = j._createTransaction(v, S, j._dbSchema); try { - v.create(), b._state.PR1398_maxLoop = 3; - } catch (g) { - return g.name === kn.InvalidState && b.isOpen() && 0 < --b._state.PR1398_maxLoop ? (console.warn("Dexie: Need to reopen db"), b.close({ disableAutoOpen: !1 }), b.open().then(function() { - return y(b, h, _, m); - })) : oe(g); + I.create(), j._state.PR1398_maxLoop = 3; + } catch (P) { + return P.name === kt.InvalidState && j.isOpen() && 0 < --j._state.PR1398_maxLoop ? (console.warn("Dexie: Need to reopen db"), j.close({ disableAutoOpen: !1 }), j.open().then(function() { + return w(j, v, S, _); + })) : _e(P); } - return v._promise(h, function(g, x) { - return Te(function() { - return $.trans = v, m(g, x, v); + return I._promise(v, function(P, k) { + return ct(function() { + return L.trans = I, _(P, k, I); }); - }).then(function(g) { - if (h === "readwrite") try { - v.idbtrans.commit(); + }).then(function(P) { + if (v === "readwrite") try { + I.idbtrans.commit(); } catch { } - return h === "readonly" ? g : v._completion.then(function() { - return g; + return v === "readonly" ? P : I._completion.then(function() { + return P; }); }); } - if (b._state.openComplete) return oe(new U.DatabaseClosed(b._state.dbOpenError)); - if (!b._state.isBeingOpened) { - if (!b._state.autoOpen) return oe(new U.DatabaseClosed()); - b.open().catch(te); + if (j._state.openComplete) return _e(new X.DatabaseClosed(j._state.dbOpenError)); + if (!j._state.isBeingOpened) { + if (!j._state.autoOpen) return _e(new X.DatabaseClosed()); + j.open().catch(he); } - return b._state.dbReadyPromise.then(function() { - return y(b, h, _, m); + return j._state.dbReadyPromise.then(function() { + return w(j, v, S, _); }); - })(this.db, e, [this.name], u); - return o && (p._consoleTask = o, p = p.catch(function(y) { - return console.trace(y), oe(y); - })), p; + })(this.db, e, [this.name], d); + return a && (x._consoleTask = a, x = x.catch(function(w) { + return console.trace(w), _e(w); + })), x; } finally { - d && st(); + y && Bt(); } - }, ne.prototype.get = function(e, t) { + }, me.prototype.get = function(e, t) { var n = this; - return e && e.constructor === Object ? this.where(e).first(t) : e == null ? oe(new U.Type("Invalid argument to Table.get()")) : this._trans("readonly", function(r) { - return n.core.get({ trans: r, key: e }).then(function(i) { - return n.hook.reading.fire(i); + return e && e.constructor === Object ? this.where(e).first(t) : e == null ? _e(new X.Type("Invalid argument to Table.get()")) : this._trans("readonly", function(o) { + return n.core.get({ trans: o, key: e }).then(function(s) { + return n.hook.reading.fire(s); }); }).then(t); - }, ne.prototype.where = function(e) { + }, me.prototype.where = function(e) { if (typeof e == "string") return new this.db.WhereClause(this, e); - if (O(e)) return new this.db.WhereClause(this, "[".concat(e.join("+"), "]")); - var t = C(e); + if (g(e)) return new this.db.WhereClause(this, "[".concat(e.join("+"), "]")); + var t = O(e); if (t.length === 1) return this.where(t[0]).equals(e[t[0]]); - var n = this.schema.indexes.concat(this.schema.primKey).filter(function(d) { - if (d.compound && t.every(function(y) { - return 0 <= d.keyPath.indexOf(y); + var n = this.schema.indexes.concat(this.schema.primKey).filter(function(y) { + if (y.compound && t.every(function(w) { + return 0 <= y.keyPath.indexOf(w); })) { - for (var p = 0; p < t.length; ++p) if (t.indexOf(d.keyPath[p]) === -1) return !1; + for (var x = 0; x < t.length; ++x) if (t.indexOf(y.keyPath[x]) === -1) return !1; return !0; } return !1; - }).sort(function(d, p) { - return d.keyPath.length - p.keyPath.length; + }).sort(function(y, x) { + return y.keyPath.length - x.keyPath.length; })[0]; - if (n && this.db._maxKey !== We) { - var o = n.keyPath.slice(0, t.length); - return this.where(o).equals(o.map(function(p) { - return e[p]; + if (n && this.db._maxKey !== xt) { + var a = n.keyPath.slice(0, t.length); + return this.where(a).equals(a.map(function(x) { + return e[x]; })); } - !n && we && console.warn("The query ".concat(JSON.stringify(e), " on ").concat(this.name, " would benefit from a ") + "compound index [".concat(t.join("+"), "]")); - var r = this.schema.idxByName; - function i(d, p) { - return Z(d, p) === 0; + !n && Me && console.warn("The query ".concat(JSON.stringify(e), " on ").concat(this.name, " would benefit from a ") + "compound index [".concat(t.join("+"), "]")); + var o = this.schema.idxByName; + function s(y, x) { + return le(y, x) === 0; } - var u = t.reduce(function(h, p) { - var y = h[0], b = h[1], h = r[p], _ = e[p]; - return [y || h, y || !h ? Qe(b, h && h.multi ? function(m) { - return m = Ce(m, p), O(m) && m.some(function(v) { - return i(_, v); + var d = t.reduce(function(v, x) { + var w = v[0], j = v[1], v = o[x], S = e[x]; + return [w || v, w || !v ? wt(j, v && v.multi ? function(_) { + return _ = Le(_, x), g(_) && _.some(function(I) { + return s(S, I); }); - } : function(m) { - return i(_, Ce(m, p)); - }) : b]; - }, [null, null]), o = u[0], u = u[1]; - return o ? this.where(o.name).equals(e[o.keyPath]).filter(u) : n ? this.filter(u) : this.where(t).equals(""); - }, ne.prototype.filter = function(e) { + } : function(_) { + return s(S, Le(_, x)); + }) : j]; + }, [null, null]), a = d[0], d = d[1]; + return a ? this.where(a.name).equals(e[a.keyPath]).filter(d) : n ? this.filter(d) : this.where(t).equals(""); + }, me.prototype.filter = function(e) { return this.toCollection().and(e); - }, ne.prototype.count = function(e) { + }, me.prototype.count = function(e) { return this.toCollection().count(e); - }, ne.prototype.offset = function(e) { + }, me.prototype.offset = function(e) { return this.toCollection().offset(e); - }, ne.prototype.limit = function(e) { + }, me.prototype.limit = function(e) { return this.toCollection().limit(e); - }, ne.prototype.each = function(e) { + }, me.prototype.each = function(e) { return this.toCollection().each(e); - }, ne.prototype.toArray = function(e) { + }, me.prototype.toArray = function(e) { return this.toCollection().toArray(e); - }, ne.prototype.toCollection = function() { + }, me.prototype.toCollection = function() { return new this.db.Collection(new this.db.WhereClause(this)); - }, ne.prototype.orderBy = function(e) { - return new this.db.Collection(new this.db.WhereClause(this, O(e) ? "[".concat(e.join("+"), "]") : e)); - }, ne.prototype.reverse = function() { + }, me.prototype.orderBy = function(e) { + return new this.db.Collection(new this.db.WhereClause(this, g(e) ? "[".concat(e.join("+"), "]") : e)); + }, me.prototype.reverse = function() { return this.toCollection().reverse(); - }, ne.prototype.mapToClass = function(e) { - var t, n = this.db, r = this.name; - function i() { + }, me.prototype.mapToClass = function(e) { + var t, n = this.db, o = this.name; + function s() { return t !== null && t.apply(this, arguments) || this; } - (this.schema.mappedClass = e).prototype instanceof Kr && ((function(p, y) { - if (typeof y != "function" && y !== null) throw new TypeError("Class extends value " + String(y) + " is not a constructor or null"); - function b() { - this.constructor = p; + (this.schema.mappedClass = e).prototype instanceof Vr && ((function(x, w) { + if (typeof w != "function" && w !== null) throw new TypeError("Class extends value " + String(w) + " is not a constructor or null"); + function j() { + this.constructor = x; } - a(p, y), p.prototype = y === null ? Object.create(y) : (b.prototype = y.prototype, new b()); - })(i, t = e), Object.defineProperty(i.prototype, "db", { get: function() { + f(x, w), x.prototype = w === null ? Object.create(w) : (j.prototype = w.prototype, new j()); + })(s, t = e), Object.defineProperty(s.prototype, "db", { get: function() { return n; - }, enumerable: !1, configurable: !0 }), i.prototype.table = function() { - return r; - }, e = i); - for (var o = /* @__PURE__ */ new Set(), u = e.prototype; u; u = Y(u)) Object.getOwnPropertyNames(u).forEach(function(p) { - return o.add(p); + }, enumerable: !1, configurable: !0 }), s.prototype.table = function() { + return o; + }, e = s); + for (var a = /* @__PURE__ */ new Set(), d = e.prototype; d; d = Q(d)) Object.getOwnPropertyNames(d).forEach(function(x) { + return a.add(x); }); - function d(p) { - if (!p) return p; - var y, b = Object.create(e.prototype); - for (y in p) if (!o.has(y)) try { - b[y] = p[y]; + function y(x) { + if (!x) return x; + var w, j = Object.create(e.prototype); + for (w in x) if (!a.has(w)) try { + j[w] = x[w]; } catch { } - return b; + return j; } - return this.schema.readHook && this.hook.reading.unsubscribe(this.schema.readHook), this.schema.readHook = d, this.hook("reading", d), e; - }, ne.prototype.defineClass = function() { + return this.schema.readHook && this.hook.reading.unsubscribe(this.schema.readHook), this.schema.readHook = y, this.hook("reading", y), e; + }, me.prototype.defineClass = function() { return this.mapToClass(function(e) { - z(this, e); + G(this, e); }); - }, ne.prototype.add = function(e, t) { - var n = this, r = this.schema.primKey, i = r.auto, o = r.keyPath, u = e; - return o && i && (u = Qt(o)(e)), this._trans("readwrite", function(d) { - return n.core.mutate({ trans: d, type: "add", keys: t != null ? [t] : null, values: [u] }); - }).then(function(d) { - return d.numFailures ? q.reject(d.failures[0]) : d.lastResult; - }).then(function(d) { - if (o) try { - me(e, o, d); + }, me.prototype.add = function(e, t) { + var n = this, o = this.schema.primKey, s = o.auto, a = o.keyPath, d = e; + return a && s && (d = bn(a)(e)), this._trans("readwrite", function(y) { + return n.core.mutate({ trans: y, type: "add", keys: t != null ? [t] : null, values: [d] }); + }).then(function(y) { + return y.numFailures ? V.reject(y.failures[0]) : y.lastResult; + }).then(function(y) { + if (a) try { + Ce(e, a, y); } catch { } - return d; + return y; }); - }, ne.prototype.upsert = function(e, t) { - var n = this, r = this.schema.primKey.keyPath; - return this._trans("readwrite", function(i) { - return n.core.get({ trans: i, key: e }).then(function(o) { - var u = o ?? {}; - return qr(u, t), r && me(u, r, e), n.core.mutate({ trans: i, type: "put", values: [u], keys: [e], upsert: !0, updates: { keys: [e], changeSpecs: [t] } }).then(function(d) { - return d.numFailures ? q.reject(d.failures[0]) : !!o; + }, me.prototype.upsert = function(e, t) { + var n = this, o = this.schema.primKey.keyPath; + return this._trans("readwrite", function(s) { + return n.core.get({ trans: s, key: e }).then(function(a) { + var d = a ?? {}; + return Qr(d, t), o && Ce(d, o, e), n.core.mutate({ trans: s, type: "put", values: [d], keys: [e], upsert: !0, updates: { keys: [e], changeSpecs: [t] } }).then(function(y) { + return y.numFailures ? V.reject(y.failures[0]) : !!a; }); }); }); - }, ne.prototype.update = function(e, t) { - return typeof e != "object" || O(e) ? this.where(":id").equals(e).modify(t) : (e = Ce(e, this.schema.primKey.keyPath), e === void 0 ? oe(new U.InvalidArgument("Given object does not contain its primary key")) : this.where(":id").equals(e).modify(t)); - }, ne.prototype.put = function(e, t) { - var n = this, r = this.schema.primKey, i = r.auto, o = r.keyPath, u = e; - return o && i && (u = Qt(o)(e)), this._trans("readwrite", function(d) { - return n.core.mutate({ trans: d, type: "put", values: [u], keys: t != null ? [t] : null }); - }).then(function(d) { - return d.numFailures ? q.reject(d.failures[0]) : d.lastResult; - }).then(function(d) { - if (o) try { - me(e, o, d); + }, me.prototype.update = function(e, t) { + return typeof e != "object" || g(e) ? this.where(":id").equals(e).modify(t) : (e = Le(e, this.schema.primKey.keyPath), e === void 0 ? _e(new X.InvalidArgument("Given object does not contain its primary key")) : this.where(":id").equals(e).modify(t)); + }, me.prototype.put = function(e, t) { + var n = this, o = this.schema.primKey, s = o.auto, a = o.keyPath, d = e; + return a && s && (d = bn(a)(e)), this._trans("readwrite", function(y) { + return n.core.mutate({ trans: y, type: "put", values: [d], keys: t != null ? [t] : null }); + }).then(function(y) { + return y.numFailures ? V.reject(y.failures[0]) : y.lastResult; + }).then(function(y) { + if (a) try { + Ce(e, a, y); } catch { } - return d; + return y; }); - }, ne.prototype.delete = function(e) { + }, me.prototype.delete = function(e) { var t = this; return this._trans("readwrite", function(n) { - return t.core.mutate({ trans: n, type: "delete", keys: [e] }).then(function(r) { - return Gt(t, [e], r); - }).then(function(r) { - return r.numFailures ? q.reject(r.failures[0]) : void 0; + return t.core.mutate({ trans: n, type: "delete", keys: [e] }).then(function(o) { + return xn(t, [e], o); + }).then(function(o) { + return o.numFailures ? V.reject(o.failures[0]) : void 0; }); }); - }, ne.prototype.clear = function() { + }, me.prototype.clear = function() { var e = this; return this._trans("readwrite", function(t) { - return e.core.mutate({ trans: t, type: "deleteRange", range: Tr }).then(function(n) { - return Gt(e, null, n); + return e.core.mutate({ trans: t, type: "deleteRange", range: zr }).then(function(n) { + return xn(e, null, n); }); }).then(function(t) { - return t.numFailures ? q.reject(t.failures[0]) : void 0; + return t.numFailures ? V.reject(t.failures[0]) : void 0; }); - }, ne.prototype.bulkGet = function(e) { + }, me.prototype.bulkGet = function(e) { var t = this; return this._trans("readonly", function(n) { - return t.core.getMany({ keys: e, trans: n }).then(function(r) { - return r.map(function(i) { - return t.hook.reading.fire(i); + return t.core.getMany({ keys: e, trans: n }).then(function(o) { + return o.map(function(s) { + return t.hook.reading.fire(s); }); }); }); - }, ne.prototype.bulkAdd = function(e, t, n) { - var r = this, i = Array.isArray(t) ? t : void 0, o = (n = n || (i ? void 0 : t)) ? n.allKeys : void 0; - return this._trans("readwrite", function(u) { - var y = r.schema.primKey, d = y.auto, y = y.keyPath; - if (y && i) throw new U.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys"); - if (i && i.length !== e.length) throw new U.InvalidArgument("Arguments objects and keys must have the same length"); - var p = e.length, y = y && d ? e.map(Qt(y)) : e; - return r.core.mutate({ trans: u, type: "add", keys: i, values: y, wantResults: o }).then(function(v) { - var h = v.numFailures, _ = v.results, m = v.lastResult, v = v.failures; - if (h === 0) return o ? _ : m; - throw new it("".concat(r.name, ".bulkAdd(): ").concat(h, " of ").concat(p, " operations failed"), v); + }, me.prototype.bulkAdd = function(e, t, n) { + var o = this, s = Array.isArray(t) ? t : void 0, a = (n = n || (s ? void 0 : t)) ? n.allKeys : void 0; + return this._trans("readwrite", function(d) { + var w = o.schema.primKey, y = w.auto, w = w.keyPath; + if (w && s) throw new X.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys"); + if (s && s.length !== e.length) throw new X.InvalidArgument("Arguments objects and keys must have the same length"); + var x = e.length, w = w && y ? e.map(bn(w)) : e; + return o.core.mutate({ trans: d, type: "add", keys: s, values: w, wantResults: a }).then(function(I) { + var v = I.numFailures, S = I.results, _ = I.lastResult, I = I.failures; + if (v === 0) return a ? S : _; + throw new et("".concat(o.name, ".bulkAdd(): ").concat(v, " of ").concat(x, " operations failed"), I); }); }); - }, ne.prototype.bulkPut = function(e, t, n) { - var r = this, i = Array.isArray(t) ? t : void 0, o = (n = n || (i ? void 0 : t)) ? n.allKeys : void 0; - return this._trans("readwrite", function(u) { - var y = r.schema.primKey, d = y.auto, y = y.keyPath; - if (y && i) throw new U.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys"); - if (i && i.length !== e.length) throw new U.InvalidArgument("Arguments objects and keys must have the same length"); - var p = e.length, y = y && d ? e.map(Qt(y)) : e; - return r.core.mutate({ trans: u, type: "put", keys: i, values: y, wantResults: o }).then(function(v) { - var h = v.numFailures, _ = v.results, m = v.lastResult, v = v.failures; - if (h === 0) return o ? _ : m; - throw new it("".concat(r.name, ".bulkPut(): ").concat(h, " of ").concat(p, " operations failed"), v); + }, me.prototype.bulkPut = function(e, t, n) { + var o = this, s = Array.isArray(t) ? t : void 0, a = (n = n || (s ? void 0 : t)) ? n.allKeys : void 0; + return this._trans("readwrite", function(d) { + var w = o.schema.primKey, y = w.auto, w = w.keyPath; + if (w && s) throw new X.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys"); + if (s && s.length !== e.length) throw new X.InvalidArgument("Arguments objects and keys must have the same length"); + var x = e.length, w = w && y ? e.map(bn(w)) : e; + return o.core.mutate({ trans: d, type: "put", keys: s, values: w, wantResults: a }).then(function(I) { + var v = I.numFailures, S = I.results, _ = I.lastResult, I = I.failures; + if (v === 0) return a ? S : _; + throw new et("".concat(o.name, ".bulkPut(): ").concat(v, " of ").concat(x, " operations failed"), I); }); }); - }, ne.prototype.bulkUpdate = function(e) { - var t = this, n = this.core, r = e.map(function(u) { - return u.key; - }), i = e.map(function(u) { - return u.changes; - }), o = []; - return this._trans("readwrite", function(u) { - return n.getMany({ trans: u, keys: r, cache: "clone" }).then(function(d) { - var p = [], y = []; - e.forEach(function(h, _) { - var m = h.key, v = h.changes, g = d[_]; - if (g) { - for (var x = 0, P = Object.keys(v); x < P.length; x++) { - var j = P[x], k = v[j]; - if (j === t.schema.primKey.keyPath) { - if (Z(k, m) !== 0) throw new U.Constraint("Cannot update primary key in bulkUpdate()"); - } else me(g, j, k); + }, me.prototype.bulkUpdate = function(e) { + var t = this, n = this.core, o = e.map(function(d) { + return d.key; + }), s = e.map(function(d) { + return d.changes; + }), a = []; + return this._trans("readwrite", function(d) { + return n.getMany({ trans: d, keys: o, cache: "clone" }).then(function(y) { + var x = [], w = []; + e.forEach(function(v, S) { + var _ = v.key, I = v.changes, P = y[S]; + if (P) { + for (var k = 0, C = Object.keys(I); k < C.length; k++) { + var B = C[k], M = I[B]; + if (B === t.schema.primKey.keyPath) { + if (le(M, _) !== 0) throw new X.Constraint("Cannot update primary key in bulkUpdate()"); + } else Ce(P, B, M); } - o.push(_), p.push(m), y.push(g); + a.push(S), x.push(_), w.push(P); } }); - var b = p.length; - return n.mutate({ trans: u, type: "put", keys: p, values: y, updates: { keys: r, changeSpecs: i } }).then(function(h) { - var _ = h.numFailures, m = h.failures; - if (_ === 0) return b; - for (var v = 0, g = Object.keys(m); v < g.length; v++) { - var x, P = g[v], j = o[Number(P)]; - j != null && (x = m[P], delete m[P], m[j] = x); + var j = x.length; + return n.mutate({ trans: d, type: "put", keys: x, values: w, updates: { keys: o, changeSpecs: s } }).then(function(v) { + var S = v.numFailures, _ = v.failures; + if (S === 0) return j; + for (var I = 0, P = Object.keys(_); I < P.length; I++) { + var k, C = P[I], B = a[Number(C)]; + B != null && (k = _[C], delete _[C], _[B] = k); } - throw new it("".concat(t.name, ".bulkUpdate(): ").concat(_, " of ").concat(b, " operations failed"), m); + throw new et("".concat(t.name, ".bulkUpdate(): ").concat(S, " of ").concat(j, " operations failed"), _); }); }); }); - }, ne.prototype.bulkDelete = function(e) { + }, me.prototype.bulkDelete = function(e) { var t = this, n = e.length; - return this._trans("readwrite", function(r) { - return t.core.mutate({ trans: r, type: "delete", keys: e }).then(function(i) { - return Gt(t, e, i); + return this._trans("readwrite", function(o) { + return t.core.mutate({ trans: o, type: "delete", keys: e }).then(function(s) { + return xn(t, e, s); }); - }).then(function(u) { - var i = u.numFailures, o = u.lastResult, u = u.failures; - if (i === 0) return o; - throw new it("".concat(t.name, ".bulkDelete(): ").concat(i, " of ").concat(n, " operations failed"), u); + }).then(function(d) { + var s = d.numFailures, a = d.lastResult, d = d.failures; + if (s === 0) return a; + throw new et("".concat(t.name, ".bulkDelete(): ").concat(s, " of ").concat(n, " operations failed"), d); }); - }, ne); - function ne() { - } - function jt(e) { - function t(u, d) { - if (d) { - for (var p = arguments.length, y = new Array(p - 1); --p; ) y[p - 1] = arguments[p]; - return n[u].subscribe.apply(null, y), e; + }, me); + function me() { + } + function zt(e) { + function t(d, y) { + if (y) { + for (var x = arguments.length, w = new Array(x - 1); --x; ) w[x - 1] = arguments[x]; + return n[d].subscribe.apply(null, w), e; } - if (typeof u == "string") return n[u]; + if (typeof d == "string") return n[d]; } var n = {}; - t.addEventType = o; - for (var r = 1, i = arguments.length; r < i; ++r) o(arguments[r]); + t.addEventType = a; + for (var o = 1, s = arguments.length; o < s; ++o) a(arguments[o]); return t; - function o(u, d, p) { - if (typeof u != "object") { - var y; - d = d || oo; - var b = { subscribers: [], fire: p = p || te, subscribe: function(h) { - b.subscribers.indexOf(h) === -1 && (b.subscribers.push(h), b.fire = d(b.fire, h)); - }, unsubscribe: function(h) { - b.subscribers = b.subscribers.filter(function(_) { - return _ !== h; - }), b.fire = b.subscribers.reduce(d, p); + function a(d, y, x) { + if (typeof d != "object") { + var w; + y = y || Jn; + var j = { subscribers: [], fire: x = x || he, subscribe: function(v) { + j.subscribers.indexOf(v) === -1 && (j.subscribers.push(v), j.fire = y(j.fire, v)); + }, unsubscribe: function(v) { + j.subscribers = j.subscribers.filter(function(S) { + return S !== v; + }), j.fire = j.subscribers.reduce(y, x); } }; - return n[u] = t[u] = b; + return n[d] = t[d] = j; } - C(y = u).forEach(function(h) { - var _ = y[h]; - if (O(_)) o(h, y[h][0], y[h][1]); + O(w = d).forEach(function(v) { + var S = w[v]; + if (g(S)) a(v, w[v][0], w[v][1]); else { - if (_ !== "asap") throw new U.InvalidArgument("Invalid event config"); - var m = o(h, gt, function() { - for (var v = arguments.length, g = new Array(v); v--; ) g[v] = arguments[v]; - m.subscribers.forEach(function(x) { - xr(function() { - x.apply(null, g); + if (S !== "asap") throw new X.InvalidArgument("Invalid event config"); + var _ = a(v, He, function() { + for (var I = arguments.length, P = new Array(I); I--; ) P[I] = arguments[I]; + _.subscribers.forEach(function(k) { + be(function() { + k.apply(null, P); }); }); }); @@ -1097,1058 +1097,1058 @@ function Cs() { }); } } - function kt(e, t) { - return Se(t).from({ prototype: e }), t; + function Vt(e, t) { + return ue(t).from({ prototype: e }), t; } - function ct(e, t) { + function Mt(e, t) { return !(e.filter || e.algorithm || e.or) && (t ? e.justLimit : !e.replayFilter); } - function Nn(e, t) { - e.filter = Qe(e.filter, t); + function ir(e, t) { + e.filter = wt(e.filter, t); } - function qn(e, t, n) { - var r = e.replayFilter; - e.replayFilter = r ? function() { - return Qe(r(), t()); - } : t, e.justLimit = n && !r; + function or(e, t, n) { + var o = e.replayFilter; + e.replayFilter = o ? function() { + return wt(o(), t()); + } : t, e.justLimit = n && !o; } - function Jt(e, t) { + function wn(e, t) { if (e.isPrimKey) return t.primaryKey; var n = t.getIndexByKeyPath(e.index); - if (!n) throw new U.Schema("KeyPath " + e.index + " on object store " + t.name + " is not indexed"); + if (!n) throw new X.Schema("KeyPath " + e.index + " on object store " + t.name + " is not indexed"); return n; } - function Fr(e, t, n) { - var r = Jt(e, t.schema); - return t.openCursor({ trans: n, values: !e.keysOnly, reverse: e.dir === "prev", unique: !!e.unique, query: { index: r, range: e.range } }); + function Zr(e, t, n) { + var o = wn(e, t.schema); + return t.openCursor({ trans: n, values: !e.keysOnly, reverse: e.dir === "prev", unique: !!e.unique, query: { index: o, range: e.range } }); } - function Xt(e, t, n, r) { - var i = e.replayFilter ? Qe(e.filter, e.replayFilter()) : e.filter; + function _n(e, t, n, o) { + var s = e.replayFilter ? wt(e.filter, e.replayFilter()) : e.filter; if (e.or) { - var o = {}, u = function(d, p, y) { - var b, h; - i && !i(p, y, function(_) { - return p.stop(_); - }, function(_) { - return p.fail(_); - }) || ((h = "" + (b = p.primaryKey)) == "[object ArrayBuffer]" && (h = "" + new Uint8Array(b)), B(o, h) || (o[h] = !0, t(d, p, y))); + var a = {}, d = function(y, x, w) { + var j, v; + s && !s(x, w, function(S) { + return x.stop(S); + }, function(S) { + return x.fail(S); + }) || ((v = "" + (j = x.primaryKey)) == "[object ArrayBuffer]" && (v = "" + new Uint8Array(j)), N(a, v) || (a[v] = !0, t(y, x, w))); }; - return Promise.all([e.or._iterate(u, n), $r(Fr(e, r, n), e.algorithm, u, !e.keysOnly && e.valueMapper)]); + return Promise.all([e.or._iterate(d, n), ei(Zr(e, o, n), e.algorithm, d, !e.keysOnly && e.valueMapper)]); } - return $r(Fr(e, r, n), Qe(e.algorithm, i), t, !e.keysOnly && e.valueMapper); + return ei(Zr(e, o, n), wt(e.algorithm, s), t, !e.keysOnly && e.valueMapper); } - function $r(e, t, n, r) { - var i = re(r ? function(o, u, d) { - return n(r(o), u, d); + function ei(e, t, n, o) { + var s = ge(o ? function(a, d, y) { + return n(o(a), d, y); } : n); - return e.then(function(o) { - if (o) return o.start(function() { - var u = function() { - return o.continue(); + return e.then(function(a) { + if (a) return a.start(function() { + var d = function() { + return a.continue(); }; - t && !t(o, function(d) { - return u = d; - }, function(d) { - o.stop(d), u = te; - }, function(d) { - o.fail(d), u = te; - }) || i(o.value, o, function(d) { - return u = d; - }), u(); + t && !t(a, function(y) { + return d = y; + }, function(y) { + a.stop(y), d = he; + }, function(y) { + a.fail(y), d = he; + }) || s(a.value, a, function(y) { + return d = y; + }), d(); }); }); } - var fo = (ee.prototype._read = function(e, t) { + var vo = (fe.prototype._read = function(e, t) { var n = this._ctx; - return n.error ? n.table._trans(null, oe.bind(null, n.error)) : n.table._trans("readonly", e).then(t); - }, ee.prototype._write = function(e) { + return n.error ? n.table._trans(null, _e.bind(null, n.error)) : n.table._trans("readonly", e).then(t); + }, fe.prototype._write = function(e) { var t = this._ctx; - return t.error ? t.table._trans(null, oe.bind(null, t.error)) : t.table._trans("readwrite", e, "locked"); - }, ee.prototype._addAlgorithm = function(e) { + return t.error ? t.table._trans(null, _e.bind(null, t.error)) : t.table._trans("readwrite", e, "locked"); + }, fe.prototype._addAlgorithm = function(e) { var t = this._ctx; - t.algorithm = Qe(t.algorithm, e); - }, ee.prototype._iterate = function(e, t) { - return Xt(this._ctx, e, t, this._ctx.table.core); - }, ee.prototype.clone = function(e) { + t.algorithm = wt(t.algorithm, e); + }, fe.prototype._iterate = function(e, t) { + return _n(this._ctx, e, t, this._ctx.table.core); + }, fe.prototype.clone = function(e) { var t = Object.create(this.constructor.prototype), n = Object.create(this._ctx); - return e && z(n, e), t._ctx = n, t; - }, ee.prototype.raw = function() { + return e && G(n, e), t._ctx = n, t; + }, fe.prototype.raw = function() { return this._ctx.valueMapper = null, this; - }, ee.prototype.each = function(e) { + }, fe.prototype.each = function(e) { var t = this._ctx; return this._read(function(n) { - return Xt(t, e, n, t.table.core); + return _n(t, e, n, t.table.core); }); - }, ee.prototype.count = function(e) { + }, fe.prototype.count = function(e) { var t = this; return this._read(function(n) { - var r = t._ctx, i = r.table.core; - if (ct(r, !0)) return i.count({ trans: n, query: { index: Jt(r, i.schema), range: r.range } }).then(function(u) { - return Math.min(u, r.limit); + var o = t._ctx, s = o.table.core; + if (Mt(o, !0)) return s.count({ trans: n, query: { index: wn(o, s.schema), range: o.range } }).then(function(d) { + return Math.min(d, o.limit); }); - var o = 0; - return Xt(r, function() { - return ++o, !1; - }, n, i).then(function() { - return o; + var a = 0; + return _n(o, function() { + return ++a, !1; + }, n, s).then(function() { + return a; }); }).then(e); - }, ee.prototype.sortBy = function(e, t) { - var n = e.split(".").reverse(), r = n[0], i = n.length - 1; - function o(p, y) { - return y ? o(p[n[y]], y - 1) : p[r]; + }, fe.prototype.sortBy = function(e, t) { + var n = e.split(".").reverse(), o = n[0], s = n.length - 1; + function a(x, w) { + return w ? a(x[n[w]], w - 1) : x[o]; } - var u = this._ctx.dir === "next" ? 1 : -1; - function d(p, y) { - return Z(o(p, i), o(y, i)) * u; + var d = this._ctx.dir === "next" ? 1 : -1; + function y(x, w) { + return le(a(x, s), a(w, s)) * d; } - return this.toArray(function(p) { - return p.sort(d); + return this.toArray(function(x) { + return x.sort(y); }).then(t); - }, ee.prototype.toArray = function(e) { + }, fe.prototype.toArray = function(e) { var t = this; return this._read(function(n) { - var r = t._ctx; - if (r.dir === "next" && ct(r, !0) && 0 < r.limit) { - var i = r.valueMapper, o = Jt(r, r.table.core.schema); - return r.table.core.query({ trans: n, limit: r.limit, values: !0, query: { index: o, range: r.range } }).then(function(d) { - return d = d.result, i ? d.map(i) : d; + var o = t._ctx; + if (o.dir === "next" && Mt(o, !0) && 0 < o.limit) { + var s = o.valueMapper, a = wn(o, o.table.core.schema); + return o.table.core.query({ trans: n, limit: o.limit, values: !0, query: { index: a, range: o.range } }).then(function(y) { + return y = y.result, s ? y.map(s) : y; }); } - var u = []; - return Xt(r, function(d) { - return u.push(d); - }, n, r.table.core).then(function() { - return u; + var d = []; + return _n(o, function(y) { + return d.push(y); + }, n, o.table.core).then(function() { + return d; }); }, e); - }, ee.prototype.offset = function(e) { + }, fe.prototype.offset = function(e) { var t = this._ctx; - return e <= 0 || (t.offset += e, ct(t) ? qn(t, function() { + return e <= 0 || (t.offset += e, Mt(t) ? or(t, function() { var n = e; - return function(r, i) { - return n === 0 || (n === 1 ? --n : i(function() { - r.advance(n), n = 0; + return function(o, s) { + return n === 0 || (n === 1 ? --n : s(function() { + o.advance(n), n = 0; }), !1); }; - }) : qn(t, function() { + }) : or(t, function() { var n = e; return function() { return --n < 0; }; })), this; - }, ee.prototype.limit = function(e) { - return this._ctx.limit = Math.min(this._ctx.limit, e), qn(this._ctx, function() { + }, fe.prototype.limit = function(e) { + return this._ctx.limit = Math.min(this._ctx.limit, e), or(this._ctx, function() { var t = e; - return function(n, r, i) { - return --t <= 0 && r(i), 0 <= t; + return function(n, o, s) { + return --t <= 0 && o(s), 0 <= t; }; }, !0), this; - }, ee.prototype.until = function(e, t) { - return Nn(this._ctx, function(n, r, i) { - return !e(n.value) || (r(i), t); + }, fe.prototype.until = function(e, t) { + return ir(this._ctx, function(n, o, s) { + return !e(n.value) || (o(s), t); }), this; - }, ee.prototype.first = function(e) { + }, fe.prototype.first = function(e) { return this.limit(1).toArray(function(t) { return t[0]; }).then(e); - }, ee.prototype.last = function(e) { + }, fe.prototype.last = function(e) { return this.reverse().first(e); - }, ee.prototype.filter = function(e) { + }, fe.prototype.filter = function(e) { var t; - return Nn(this._ctx, function(n) { + return ir(this._ctx, function(n) { return e(n.value); - }), (t = this._ctx).isMatch = Qe(t.isMatch, e), this; - }, ee.prototype.and = function(e) { + }), (t = this._ctx).isMatch = wt(t.isMatch, e), this; + }, fe.prototype.and = function(e) { return this.filter(e); - }, ee.prototype.or = function(e) { + }, fe.prototype.or = function(e) { return new this.db.WhereClause(this._ctx.table, e, this); - }, ee.prototype.reverse = function() { + }, fe.prototype.reverse = function() { return this._ctx.dir = this._ctx.dir === "prev" ? "next" : "prev", this._ondirectionchange && this._ondirectionchange(this._ctx.dir), this; - }, ee.prototype.desc = function() { + }, fe.prototype.desc = function() { return this.reverse(); - }, ee.prototype.eachKey = function(e) { + }, fe.prototype.eachKey = function(e) { var t = this._ctx; - return t.keysOnly = !t.isMatch, this.each(function(n, r) { - e(r.key, r); + return t.keysOnly = !t.isMatch, this.each(function(n, o) { + e(o.key, o); }); - }, ee.prototype.eachUniqueKey = function(e) { + }, fe.prototype.eachUniqueKey = function(e) { return this._ctx.unique = "unique", this.eachKey(e); - }, ee.prototype.eachPrimaryKey = function(e) { + }, fe.prototype.eachPrimaryKey = function(e) { var t = this._ctx; - return t.keysOnly = !t.isMatch, this.each(function(n, r) { - e(r.primaryKey, r); + return t.keysOnly = !t.isMatch, this.each(function(n, o) { + e(o.primaryKey, o); }); - }, ee.prototype.keys = function(e) { + }, fe.prototype.keys = function(e) { var t = this._ctx; t.keysOnly = !t.isMatch; var n = []; - return this.each(function(r, i) { - n.push(i.key); + return this.each(function(o, s) { + n.push(s.key); }).then(function() { return n; }).then(e); - }, ee.prototype.primaryKeys = function(e) { + }, fe.prototype.primaryKeys = function(e) { var t = this._ctx; - if (t.dir === "next" && ct(t, !0) && 0 < t.limit) return this._read(function(r) { - var i = Jt(t, t.table.core.schema); - return t.table.core.query({ trans: r, values: !1, limit: t.limit, query: { index: i, range: t.range } }); - }).then(function(r) { - return r.result; + if (t.dir === "next" && Mt(t, !0) && 0 < t.limit) return this._read(function(o) { + var s = wn(t, t.table.core.schema); + return t.table.core.query({ trans: o, values: !1, limit: t.limit, query: { index: s, range: t.range } }); + }).then(function(o) { + return o.result; }).then(e); t.keysOnly = !t.isMatch; var n = []; - return this.each(function(r, i) { - n.push(i.primaryKey); + return this.each(function(o, s) { + n.push(s.primaryKey); }).then(function() { return n; }).then(e); - }, ee.prototype.uniqueKeys = function(e) { + }, fe.prototype.uniqueKeys = function(e) { return this._ctx.unique = "unique", this.keys(e); - }, ee.prototype.firstKey = function(e) { + }, fe.prototype.firstKey = function(e) { return this.limit(1).keys(function(t) { return t[0]; }).then(e); - }, ee.prototype.lastKey = function(e) { + }, fe.prototype.lastKey = function(e) { return this.reverse().firstKey(e); - }, ee.prototype.distinct = function() { + }, fe.prototype.distinct = function() { var e = this._ctx, e = e.index && e.table.schema.idxByName[e.index]; if (!e || !e.multi) return this; var t = {}; - return Nn(this._ctx, function(i) { - var r = i.primaryKey.toString(), i = B(t, r); - return t[r] = !0, !i; + return ir(this._ctx, function(s) { + var o = s.primaryKey.toString(), s = N(t, o); + return t[o] = !0, !s; }), this; - }, ee.prototype.modify = function(e) { + }, fe.prototype.modify = function(e) { var t = this, n = this._ctx; - return this._write(function(r) { - var i = typeof e == "function" ? e : function(g) { - return qr(g, e); - }, o = n.table.core, y = o.schema.primaryKey, u = y.outbound, d = y.extractKey, p = 200, y = t.db._options.modifyChunkSize; - y && (p = typeof y == "object" ? y[o.name] || y["*"] || 200 : y); - function b(g, j) { - var P = j.failures, j = j.numFailures; - _ += g - j; - for (var k = 0, S = C(P); k < S.length; k++) { - var A = S[k]; - h.push(P[A]); + return this._write(function(o) { + var s = typeof e == "function" ? e : function(P) { + return Qr(P, e); + }, a = n.table.core, w = a.schema.primaryKey, d = w.outbound, y = w.extractKey, x = 200, w = t.db._options.modifyChunkSize; + w && (x = typeof w == "object" ? w[a.name] || w["*"] || 200 : w); + function j(P, B) { + var C = B.failures, B = B.numFailures; + S += P - B; + for (var M = 0, F = O(C); M < F.length; M++) { + var U = F[M]; + v.push(C[U]); } } - var h = [], _ = 0, m = [], v = e === Lr; - return t.clone().primaryKeys().then(function(g) { - function x(j) { - var k = Math.min(p, g.length - j), S = g.slice(j, j + k); - return (v ? Promise.resolve([]) : o.getMany({ trans: r, keys: S, cache: "immutable" })).then(function(A) { - var D = [], I = [], T = u ? [] : null, N = v ? S : []; - if (!v) for (var R = 0; R < k; ++R) { - var F = A[R], G = { value: Fe(F), primKey: g[j + R] }; - i.call(G, G.value, G) !== !1 && (G.value == null ? N.push(g[j + R]) : u || Z(d(F), d(G.value)) === 0 ? (I.push(G.value), u && T.push(g[j + R])) : (N.push(g[j + R]), D.push(G.value))); + var v = [], S = 0, _ = [], I = e === ti; + return t.clone().primaryKeys().then(function(P) { + function k(B) { + var M = Math.min(x, P.length - B), F = P.slice(B, B + M); + return (I ? Promise.resolve([]) : a.getMany({ trans: o, keys: F, cache: "immutable" })).then(function(U) { + var Y = [], q = [], $ = d ? [] : null, z = I ? F : []; + if (!I) for (var H = 0; H < M; ++H) { + var W = U[H], ie = { value: Qe(W), primKey: P[B + H] }; + s.call(ie, ie.value, ie) !== !1 && (ie.value == null ? z.push(P[B + H]) : d || le(y(W), y(ie.value)) === 0 ? (q.push(ie.value), d && $.push(P[B + H])) : (z.push(P[B + H]), Y.push(ie.value))); } - return Promise.resolve(0 < D.length && o.mutate({ trans: r, type: "add", values: D }).then(function(J) { - for (var X in J.failures) N.splice(parseInt(X), 1); - b(D.length, J); + return Promise.resolve(0 < Y.length && a.mutate({ trans: o, type: "add", values: Y }).then(function(se) { + for (var ae in se.failures) z.splice(parseInt(ae), 1); + j(Y.length, se); })).then(function() { - return (0 < I.length || P && typeof e == "object") && o.mutate({ trans: r, type: "put", keys: T, values: I, criteria: P, changeSpec: typeof e != "function" && e, isAdditionalChunk: 0 < j }).then(function(J) { - return b(I.length, J); + return (0 < q.length || C && typeof e == "object") && a.mutate({ trans: o, type: "put", keys: $, values: q, criteria: C, changeSpec: typeof e != "function" && e, isAdditionalChunk: 0 < B }).then(function(se) { + return j(q.length, se); }); }).then(function() { - return (0 < N.length || P && v) && o.mutate({ trans: r, type: "delete", keys: N, criteria: P, isAdditionalChunk: 0 < j }).then(function(J) { - return Gt(n.table, N, J); - }).then(function(J) { - return b(N.length, J); + return (0 < z.length || C && I) && a.mutate({ trans: o, type: "delete", keys: z, criteria: C, isAdditionalChunk: 0 < B }).then(function(se) { + return xn(n.table, z, se); + }).then(function(se) { + return j(z.length, se); }); }).then(function() { - return g.length > j + k && x(j + p); + return P.length > B + M && k(B + x); }); }); } - var P = ct(n) && n.limit === 1 / 0 && (typeof e != "function" || v) && { index: n.index, range: n.range }; - return x(0).then(function() { - if (0 < h.length) throw new qt("Error modifying one or more objects", h, _, m); - return g.length; + var C = Mt(n) && n.limit === 1 / 0 && (typeof e != "function" || I) && { index: n.index, range: n.range }; + return k(0).then(function() { + if (0 < v.length) throw new gt("Error modifying one or more objects", v, S, _); + return P.length; }); }); }); - }, ee.prototype.delete = function() { + }, fe.prototype.delete = function() { var e = this._ctx, t = e.range; - return !ct(e) || e.table.schema.yProps || !e.isPrimKey && t.type !== 3 ? this.modify(Lr) : this._write(function(n) { - var r = e.table.core.schema.primaryKey, i = t; - return e.table.core.count({ trans: n, query: { index: r, range: i } }).then(function(o) { - return e.table.core.mutate({ trans: n, type: "deleteRange", range: i }).then(function(p) { - var d = p.failures, p = p.numFailures; - if (p) throw new qt("Could not delete some values", Object.keys(d).map(function(y) { - return d[y]; - }), o - p); - return o - p; + return !Mt(e) || e.table.schema.yProps || !e.isPrimKey && t.type !== 3 ? this.modify(ti) : this._write(function(n) { + var o = e.table.core.schema.primaryKey, s = t; + return e.table.core.count({ trans: n, query: { index: o, range: s } }).then(function(a) { + return e.table.core.mutate({ trans: n, type: "deleteRange", range: s }).then(function(x) { + var y = x.failures, x = x.numFailures; + if (x) throw new gt("Could not delete some values", Object.keys(y).map(function(w) { + return y[w]; + }), a - x); + return a - x; }); }); }); - }, ee); - function ee() { + }, fe); + function fe() { } - var Lr = function(e, t) { + var ti = function(e, t) { return t.value = null; }; - function ho(e, t) { + function bo(e, t) { return e < t ? -1 : e === t ? 0 : 1; } - function po(e, t) { + function xo(e, t) { return t < e ? -1 : e === t ? 0 : 1; } - function ve(e, t, n) { - return e = e instanceof Ur ? new e.Collection(e) : e, e._ctx.error = new (n || TypeError)(t), e; + function qe(e, t, n) { + return e = e instanceof ri ? new e.Collection(e) : e, e._ctx.error = new (n || TypeError)(t), e; } - function lt(e) { + function Rt(e) { return new e.Collection(e, function() { - return Hr(""); + return ni(""); }).limit(0); } - function Zt(e, t, n, r) { - var i, o, u, d, p, y, b, h = n.length; - if (!n.every(function(v) { - return typeof v == "string"; - })) return ve(e, Mr); - function _(v) { - i = v === "next" ? function(x) { - return x.toUpperCase(); - } : function(x) { - return x.toLowerCase(); - }, o = v === "next" ? function(x) { - return x.toLowerCase(); - } : function(x) { - return x.toUpperCase(); - }, u = v === "next" ? ho : po; - var g = n.map(function(x) { - return { lower: o(x), upper: i(x) }; - }).sort(function(x, P) { - return u(x.lower, P.lower); + function En(e, t, n, o) { + var s, a, d, y, x, w, j, v = n.length; + if (!n.every(function(I) { + return typeof I == "string"; + })) return qe(e, Yr); + function S(I) { + s = I === "next" ? function(k) { + return k.toUpperCase(); + } : function(k) { + return k.toLowerCase(); + }, a = I === "next" ? function(k) { + return k.toLowerCase(); + } : function(k) { + return k.toUpperCase(); + }, d = I === "next" ? bo : xo; + var P = n.map(function(k) { + return { lower: a(k), upper: s(k) }; + }).sort(function(k, C) { + return d(k.lower, C.lower); }); - d = g.map(function(x) { - return x.upper; - }), p = g.map(function(x) { - return x.lower; - }), b = (y = v) === "next" ? "" : r; + y = P.map(function(k) { + return k.upper; + }), x = P.map(function(k) { + return k.lower; + }), j = (w = I) === "next" ? "" : o; } - _("next"), e = new e.Collection(e, function() { - return De(d[0], p[h - 1] + r); - }), e._ondirectionchange = function(v) { - _(v); + S("next"), e = new e.Collection(e, function() { + return ht(y[0], x[v - 1] + o); + }), e._ondirectionchange = function(I) { + S(I); }; - var m = 0; - return e._addAlgorithm(function(v, g, x) { - var P = v.key; - if (typeof P != "string") return !1; - var j = o(P); - if (t(j, p, m)) return !0; - for (var k = null, S = m; S < h; ++S) { - var A = (function(D, I, T, N, R, F) { - for (var G = Math.min(D.length, N.length), J = -1, X = 0; X < G; ++X) { - var ge = I[X]; - if (ge !== N[X]) return R(D[X], T[X]) < 0 ? D.substr(0, X) + T[X] + T.substr(X + 1) : R(D[X], N[X]) < 0 ? D.substr(0, X) + N[X] + T.substr(X + 1) : 0 <= J ? D.substr(0, J) + I[J] + T.substr(J + 1) : null; - R(D[X], ge) < 0 && (J = X); + var _ = 0; + return e._addAlgorithm(function(I, P, k) { + var C = I.key; + if (typeof C != "string") return !1; + var B = a(C); + if (t(B, x, _)) return !0; + for (var M = null, F = _; F < v; ++F) { + var U = (function(Y, q, $, z, H, W) { + for (var ie = Math.min(Y.length, z.length), se = -1, ae = 0; ae < ie; ++ae) { + var Ue = q[ae]; + if (Ue !== z[ae]) return H(Y[ae], $[ae]) < 0 ? Y.substr(0, ae) + $[ae] + $.substr(ae + 1) : H(Y[ae], z[ae]) < 0 ? Y.substr(0, ae) + z[ae] + $.substr(ae + 1) : 0 <= se ? Y.substr(0, se) + q[se] + $.substr(se + 1) : null; + H(Y[ae], Ue) < 0 && (se = ae); } - return G < N.length && F === "next" ? D + T.substr(D.length) : G < D.length && F === "prev" ? D.substr(0, T.length) : J < 0 ? null : D.substr(0, J) + N[J] + T.substr(J + 1); - })(P, j, d[S], p[S], u, y); - A === null && k === null ? m = S + 1 : (k === null || 0 < u(k, A)) && (k = A); + return ie < z.length && W === "next" ? Y + $.substr(Y.length) : ie < Y.length && W === "prev" ? Y.substr(0, $.length) : se < 0 ? null : Y.substr(0, se) + z[se] + $.substr(se + 1); + })(C, B, y[F], x[F], d, w); + U === null && M === null ? _ = F + 1 : (M === null || 0 < d(M, U)) && (M = U); } - return g(k !== null ? function() { - v.continue(k + b); - } : x), !1; + return P(M !== null ? function() { + I.continue(M + j); + } : k), !1; }), e; } - function De(e, t, n, r) { - return { type: 2, lower: e, upper: t, lowerOpen: n, upperOpen: r }; + function ht(e, t, n, o) { + return { type: 2, lower: e, upper: t, lowerOpen: n, upperOpen: o }; } - function Hr(e) { + function ni(e) { return { type: 1, lower: e, upper: e }; } - var Ur = (Object.defineProperty(ce.prototype, "Collection", { get: function() { + var ri = (Object.defineProperty(ke.prototype, "Collection", { get: function() { return this._ctx.table.db.Collection; - }, enumerable: !1, configurable: !0 }), ce.prototype.between = function(e, t, n, r) { - n = n !== !1, r = r === !0; + }, enumerable: !1, configurable: !0 }), ke.prototype.between = function(e, t, n, o) { + n = n !== !1, o = o === !0; try { - return 0 < this._cmp(e, t) || this._cmp(e, t) === 0 && (n || r) && (!n || !r) ? lt(this) : new this.Collection(this, function() { - return De(e, t, !n, !r); + return 0 < this._cmp(e, t) || this._cmp(e, t) === 0 && (n || o) && (!n || !o) ? Rt(this) : new this.Collection(this, function() { + return ht(e, t, !n, !o); }); } catch { - return ve(this, Ie); + return qe(this, it); } - }, ce.prototype.equals = function(e) { - return e == null ? ve(this, Ie) : new this.Collection(this, function() { - return Hr(e); + }, ke.prototype.equals = function(e) { + return e == null ? qe(this, it) : new this.Collection(this, function() { + return ni(e); }); - }, ce.prototype.above = function(e) { - return e == null ? ve(this, Ie) : new this.Collection(this, function() { - return De(e, void 0, !0); + }, ke.prototype.above = function(e) { + return e == null ? qe(this, it) : new this.Collection(this, function() { + return ht(e, void 0, !0); }); - }, ce.prototype.aboveOrEqual = function(e) { - return e == null ? ve(this, Ie) : new this.Collection(this, function() { - return De(e, void 0, !1); + }, ke.prototype.aboveOrEqual = function(e) { + return e == null ? qe(this, it) : new this.Collection(this, function() { + return ht(e, void 0, !1); }); - }, ce.prototype.below = function(e) { - return e == null ? ve(this, Ie) : new this.Collection(this, function() { - return De(void 0, e, !1, !0); + }, ke.prototype.below = function(e) { + return e == null ? qe(this, it) : new this.Collection(this, function() { + return ht(void 0, e, !1, !0); }); - }, ce.prototype.belowOrEqual = function(e) { - return e == null ? ve(this, Ie) : new this.Collection(this, function() { - return De(void 0, e); + }, ke.prototype.belowOrEqual = function(e) { + return e == null ? qe(this, it) : new this.Collection(this, function() { + return ht(void 0, e); }); - }, ce.prototype.startsWith = function(e) { - return typeof e != "string" ? ve(this, Mr) : this.between(e, e + We, !0, !0); - }, ce.prototype.startsWithIgnoreCase = function(e) { - return e === "" ? this.startsWith(e) : Zt(this, function(t, n) { + }, ke.prototype.startsWith = function(e) { + return typeof e != "string" ? qe(this, Yr) : this.between(e, e + xt, !0, !0); + }, ke.prototype.startsWithIgnoreCase = function(e) { + return e === "" ? this.startsWith(e) : En(this, function(t, n) { return t.indexOf(n[0]) === 0; - }, [e], We); - }, ce.prototype.equalsIgnoreCase = function(e) { - return Zt(this, function(t, n) { + }, [e], xt); + }, ke.prototype.equalsIgnoreCase = function(e) { + return En(this, function(t, n) { return t === n[0]; }, [e], ""); - }, ce.prototype.anyOfIgnoreCase = function() { - var e = Ee.apply(nt, arguments); - return e.length === 0 ? lt(this) : Zt(this, function(t, n) { + }, ke.prototype.anyOfIgnoreCase = function() { + var e = ze.apply(at, arguments); + return e.length === 0 ? Rt(this) : En(this, function(t, n) { return n.indexOf(t) !== -1; }, e, ""); - }, ce.prototype.startsWithAnyOfIgnoreCase = function() { - var e = Ee.apply(nt, arguments); - return e.length === 0 ? lt(this) : Zt(this, function(t, n) { - return n.some(function(r) { - return t.indexOf(r) === 0; + }, ke.prototype.startsWithAnyOfIgnoreCase = function() { + var e = ze.apply(at, arguments); + return e.length === 0 ? Rt(this) : En(this, function(t, n) { + return n.some(function(o) { + return t.indexOf(o) === 0; }); - }, e, We); - }, ce.prototype.anyOf = function() { - var e = this, t = Ee.apply(nt, arguments), n = this._cmp; + }, e, xt); + }, ke.prototype.anyOf = function() { + var e = this, t = ze.apply(at, arguments), n = this._cmp; try { t.sort(n); } catch { - return ve(this, Ie); + return qe(this, it); } - if (t.length === 0) return lt(this); - var r = new this.Collection(this, function() { - return De(t[0], t[t.length - 1]); + if (t.length === 0) return Rt(this); + var o = new this.Collection(this, function() { + return ht(t[0], t[t.length - 1]); }); - r._ondirectionchange = function(o) { - n = o === "next" ? e._ascending : e._descending, t.sort(n); + o._ondirectionchange = function(a) { + n = a === "next" ? e._ascending : e._descending, t.sort(n); }; - var i = 0; - return r._addAlgorithm(function(o, u, d) { - for (var p = o.key; 0 < n(p, t[i]); ) if (++i === t.length) return u(d), !1; - return n(p, t[i]) === 0 || (u(function() { - o.continue(t[i]); + var s = 0; + return o._addAlgorithm(function(a, d, y) { + for (var x = a.key; 0 < n(x, t[s]); ) if (++s === t.length) return d(y), !1; + return n(x, t[s]) === 0 || (d(function() { + a.continue(t[s]); }), !1); - }), r; - }, ce.prototype.notEqual = function(e) { + }), o; + }, ke.prototype.notEqual = function(e) { return this.inAnyRange([[-1 / 0, e], [e, this.db._maxKey]], { includeLowers: !1, includeUppers: !1 }); - }, ce.prototype.noneOf = function() { - var e = Ee.apply(nt, arguments); + }, ke.prototype.noneOf = function() { + var e = ze.apply(at, arguments); if (e.length === 0) return new this.Collection(this); try { e.sort(this._ascending); } catch { - return ve(this, Ie); + return qe(this, it); } - var t = e.reduce(function(n, r) { - return n ? n.concat([[n[n.length - 1][1], r]]) : [[-1 / 0, r]]; + var t = e.reduce(function(n, o) { + return n ? n.concat([[n[n.length - 1][1], o]]) : [[-1 / 0, o]]; }, null); return t.push([e[e.length - 1], this.db._maxKey]), this.inAnyRange(t, { includeLowers: !1, includeUppers: !1 }); - }, ce.prototype.inAnyRange = function(P, t) { - var n = this, r = this._cmp, i = this._ascending, o = this._descending, u = this._min, d = this._max; - if (P.length === 0) return lt(this); - if (!P.every(function(j) { - return j[0] !== void 0 && j[1] !== void 0 && i(j[0], j[1]) <= 0; - })) return ve(this, "First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower", U.InvalidArgument); - var p = !t || t.includeLowers !== !1, y = t && t.includeUppers === !0, b, h = i; - function _(j, k) { - return h(j[0], k[0]); + }, ke.prototype.inAnyRange = function(C, t) { + var n = this, o = this._cmp, s = this._ascending, a = this._descending, d = this._min, y = this._max; + if (C.length === 0) return Rt(this); + if (!C.every(function(B) { + return B[0] !== void 0 && B[1] !== void 0 && s(B[0], B[1]) <= 0; + })) return qe(this, "First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower", X.InvalidArgument); + var x = !t || t.includeLowers !== !1, w = t && t.includeUppers === !0, j, v = s; + function S(B, M) { + return v(B[0], M[0]); } try { - (b = P.reduce(function(j, k) { - for (var S = 0, A = j.length; S < A; ++S) { - var D = j[S]; - if (r(k[0], D[1]) < 0 && 0 < r(k[1], D[0])) { - D[0] = u(D[0], k[0]), D[1] = d(D[1], k[1]); + (j = C.reduce(function(B, M) { + for (var F = 0, U = B.length; F < U; ++F) { + var Y = B[F]; + if (o(M[0], Y[1]) < 0 && 0 < o(M[1], Y[0])) { + Y[0] = d(Y[0], M[0]), Y[1] = y(Y[1], M[1]); break; } } - return S === A && j.push(k), j; - }, [])).sort(_); + return F === U && B.push(M), B; + }, [])).sort(S); } catch { - return ve(this, Ie); + return qe(this, it); } - var m = 0, v = y ? function(j) { - return 0 < i(j, b[m][1]); - } : function(j) { - return 0 <= i(j, b[m][1]); - }, g = p ? function(j) { - return 0 < o(j, b[m][0]); - } : function(j) { - return 0 <= o(j, b[m][0]); - }, x = v, P = new this.Collection(this, function() { - return De(b[0][0], b[b.length - 1][1], !p, !y); + var _ = 0, I = w ? function(B) { + return 0 < s(B, j[_][1]); + } : function(B) { + return 0 <= s(B, j[_][1]); + }, P = x ? function(B) { + return 0 < a(B, j[_][0]); + } : function(B) { + return 0 <= a(B, j[_][0]); + }, k = I, C = new this.Collection(this, function() { + return ht(j[0][0], j[j.length - 1][1], !x, !w); }); - return P._ondirectionchange = function(j) { - h = j === "next" ? (x = v, i) : (x = g, o), b.sort(_); - }, P._addAlgorithm(function(j, k, S) { - for (var A, D = j.key; x(D); ) if (++m === b.length) return k(S), !1; - return !v(A = D) && !g(A) || (n._cmp(D, b[m][1]) === 0 || n._cmp(D, b[m][0]) === 0 || k(function() { - h === i ? j.continue(b[m][0]) : j.continue(b[m][1]); + return C._ondirectionchange = function(B) { + v = B === "next" ? (k = I, s) : (k = P, a), j.sort(S); + }, C._addAlgorithm(function(B, M, F) { + for (var U, Y = B.key; k(Y); ) if (++_ === j.length) return M(F), !1; + return !I(U = Y) && !P(U) || (n._cmp(Y, j[_][1]) === 0 || n._cmp(Y, j[_][0]) === 0 || M(function() { + v === s ? B.continue(j[_][0]) : B.continue(j[_][1]); }), !1); - }), P; - }, ce.prototype.startsWithAnyOf = function() { - var e = Ee.apply(nt, arguments); + }), C; + }, ke.prototype.startsWithAnyOf = function() { + var e = ze.apply(at, arguments); return e.every(function(t) { return typeof t == "string"; - }) ? e.length === 0 ? lt(this) : this.inAnyRange(e.map(function(t) { - return [t, t + We]; - })) : ve(this, "startsWithAnyOf() only works with strings"); - }, ce); - function ce() { - } - function Pe(e) { - return re(function(t) { - return St(t), e(t.target.error), !1; + }) ? e.length === 0 ? Rt(this) : this.inAnyRange(e.map(function(t) { + return [t, t + xt]; + })) : qe(this, "startsWithAnyOf() only works with strings"); + }, ke); + function ke() { + } + function We(e) { + return ge(function(t) { + return Wt(t), e(t.target.error), !1; }); } - function St(e) { + function Wt(e) { e.stopPropagation && e.stopPropagation(), e.preventDefault && e.preventDefault(); } - var Ct = "storagemutated", Bn = "x-storagemutated-1", Ne = jt(null, Ct), yo = (je.prototype._lock = function() { - return mt(!$.global), ++this._reculock, this._reculock !== 1 || $.global || ($.lockOwnerFor = this), this; - }, je.prototype._unlock = function() { - if (mt(!$.global), --this._reculock == 0) for ($.global || ($.lockOwnerFor = null); 0 < this._blockedFuncs.length && !this._locked(); ) { + var Gt = "storagemutated", sr = "x-storagemutated-1", dt = zt(null, Gt), wo = (Ge.prototype._lock = function() { + return Ke(!L.global), ++this._reculock, this._reculock !== 1 || L.global || (L.lockOwnerFor = this), this; + }, Ge.prototype._unlock = function() { + if (Ke(!L.global), --this._reculock == 0) for (L.global || (L.lockOwnerFor = null); 0 < this._blockedFuncs.length && !this._locked(); ) { var e = this._blockedFuncs.shift(); try { - Ve(e[1], e[0]); + bt(e[1], e[0]); } catch { } } return this; - }, je.prototype._locked = function() { - return this._reculock && $.lockOwnerFor !== this; - }, je.prototype.create = function(e) { + }, Ge.prototype._locked = function() { + return this._reculock && L.lockOwnerFor !== this; + }, Ge.prototype.create = function(e) { var t = this; if (!this.mode) return this; - var n = this.db.idbdb, r = this.db._state.dbOpenError; - if (mt(!this.idbtrans), !e && !n) switch (r && r.name) { + var n = this.db.idbdb, o = this.db._state.dbOpenError; + if (Ke(!this.idbtrans), !e && !n) switch (o && o.name) { case "DatabaseClosedError": - throw new U.DatabaseClosed(r); + throw new X.DatabaseClosed(o); case "MissingAPIError": - throw new U.MissingAPI(r.message, r); + throw new X.MissingAPI(o.message, o); default: - throw new U.OpenFailed(r); + throw new X.OpenFailed(o); } - if (!this.active) throw new U.TransactionInactive(); - return mt(this._completion._state === null), (e = this.idbtrans = e || (this.db.core || n).transaction(this.storeNames, this.mode, { durability: this.chromeTransactionDurability })).onerror = re(function(i) { - St(i), t._reject(e.error); - }), e.onabort = re(function(i) { - St(i), t.active && t._reject(new U.Abort(e.error)), t.active = !1, t.on("abort").fire(i); - }), e.oncomplete = re(function() { - t.active = !1, t._resolve(), "mutatedParts" in e && Ne.storagemutated.fire(e.mutatedParts); + if (!this.active) throw new X.TransactionInactive(); + return Ke(this._completion._state === null), (e = this.idbtrans = e || (this.db.core || n).transaction(this.storeNames, this.mode, { durability: this.chromeTransactionDurability })).onerror = ge(function(s) { + Wt(s), t._reject(e.error); + }), e.onabort = ge(function(s) { + Wt(s), t.active && t._reject(new X.Abort(e.error)), t.active = !1, t.on("abort").fire(s); + }), e.oncomplete = ge(function() { + t.active = !1, t._resolve(), "mutatedParts" in e && dt.storagemutated.fire(e.mutatedParts); }), this; - }, je.prototype._promise = function(e, t, n) { - var r = this; - if (e === "readwrite" && this.mode !== "readwrite") return oe(new U.ReadOnly("Transaction is readonly")); - if (!this.active) return oe(new U.TransactionInactive()); - if (this._locked()) return new q(function(o, u) { - r._blockedFuncs.push([function() { - r._promise(e, t, n).then(o, u); - }, $]); + }, Ge.prototype._promise = function(e, t, n) { + var o = this; + if (e === "readwrite" && this.mode !== "readwrite") return _e(new X.ReadOnly("Transaction is readonly")); + if (!this.active) return _e(new X.TransactionInactive()); + if (this._locked()) return new V(function(a, d) { + o._blockedFuncs.push([function() { + o._promise(e, t, n).then(a, d); + }, L]); }); - if (n) return Te(function() { - var o = new q(function(u, d) { - r._lock(); - var p = t(u, d, r); - p && p.then && p.then(u, d); + if (n) return ct(function() { + var a = new V(function(d, y) { + o._lock(); + var x = t(d, y, o); + x && x.then && x.then(d, y); }); - return o.finally(function() { - return r._unlock(); - }), o._lib = !0, o; + return a.finally(function() { + return o._unlock(); + }), a._lib = !0, a; }); - var i = new q(function(o, u) { - var d = t(o, u, r); - d && d.then && d.then(o, u); + var s = new V(function(a, d) { + var y = t(a, d, o); + y && y.then && y.then(a, d); }); - return i._lib = !0, i; - }, je.prototype._root = function() { + return s._lib = !0, s; + }, Ge.prototype._root = function() { return this.parent ? this.parent._root() : this; - }, je.prototype.waitFor = function(e) { - var t, n = this._root(), r = q.resolve(e); + }, Ge.prototype.waitFor = function(e) { + var t, n = this._root(), o = V.resolve(e); n._waitingFor ? n._waitingFor = n._waitingFor.then(function() { - return r; - }) : (n._waitingFor = r, n._waitingQueue = [], t = n.idbtrans.objectStore(n.storeNames[0]), (function o() { + return o; + }) : (n._waitingFor = o, n._waitingQueue = [], t = n.idbtrans.objectStore(n.storeNames[0]), (function a() { for (++n._spinCount; n._waitingQueue.length; ) n._waitingQueue.shift()(); - n._waitingFor && (t.get(-1 / 0).onsuccess = o); + n._waitingFor && (t.get(-1 / 0).onsuccess = a); })()); - var i = n._waitingFor; - return new q(function(o, u) { - r.then(function(d) { - return n._waitingQueue.push(re(o.bind(null, d))); - }, function(d) { - return n._waitingQueue.push(re(u.bind(null, d))); + var s = n._waitingFor; + return new V(function(a, d) { + o.then(function(y) { + return n._waitingQueue.push(ge(a.bind(null, y))); + }, function(y) { + return n._waitingQueue.push(ge(d.bind(null, y))); }).finally(function() { - n._waitingFor === i && (n._waitingFor = null); + n._waitingFor === s && (n._waitingFor = null); }); }); - }, je.prototype.abort = function() { - this.active && (this.active = !1, this.idbtrans && this.idbtrans.abort(), this._reject(new U.Abort())); - }, je.prototype.table = function(e) { + }, Ge.prototype.abort = function() { + this.active && (this.active = !1, this.idbtrans && this.idbtrans.abort(), this._reject(new X.Abort())); + }, Ge.prototype.table = function(e) { var t = this._memoizedTables || (this._memoizedTables = {}); - if (B(t, e)) return t[e]; + if (N(t, e)) return t[e]; var n = this.schema[e]; - if (!n) throw new U.NotFound("Table " + e + " not part of transaction"); + if (!n) throw new X.NotFound("Table " + e + " not part of transaction"); return n = new this.db.Table(e, n, this), n.core = this.db.core.table(e), t[e] = n; - }, je); - function je() { + }, Ge); + function Ge() { } - function Fn(e, t, n, r, i, o, u, d) { - return { name: e, keyPath: t, unique: n, multi: r, auto: i, compound: o, src: (n && !u ? "&" : "") + (r ? "*" : "") + (i ? "++" : "") + zr(t), type: d }; + function ar(e, t, n, o, s, a, d, y) { + return { name: e, keyPath: t, unique: n, multi: o, auto: s, compound: a, src: (n && !d ? "&" : "") + (o ? "*" : "") + (s ? "++" : "") + ii(t), type: y }; } - function zr(e) { + function ii(e) { return typeof e == "string" ? e : e ? "[" + [].join.call(e, "+") + "]" : ""; } - function $n(e, t, n) { - return { name: e, primKey: t, indexes: n, mappedClass: null, idxByName: (r = function(i) { - return [i.name, i]; - }, n.reduce(function(i, o, u) { - return u = r(o, u), u && (i[u[0]] = u[1]), i; + function ur(e, t, n) { + return { name: e, primKey: t, indexes: n, mappedClass: null, idxByName: (o = function(s) { + return [s.name, s]; + }, n.reduce(function(s, a, d) { + return d = o(a, d), d && (s[d[0]] = d[1]), s; }, {})) }; - var r; + var o; } - var Et = function(e) { + var Jt = function(e) { try { - return e.only([[]]), Et = function() { + return e.only([[]]), Jt = function() { return [[]]; }, [[]]; } catch { - return Et = function() { - return We; - }, We; + return Jt = function() { + return xt; + }, xt; } }; - function Ln(e) { + function cr(e) { return e == null ? function() { } : typeof e == "string" ? (t = e).split(".").length === 1 ? function(n) { return n[t]; } : function(n) { - return Ce(n, t); + return Le(n, t); } : function(n) { - return Ce(n, e); + return Le(n, e); }; var t; } - function Yr(e) { + function oi(e) { return [].slice.call(e); } - var mo = 0; - function It(e) { + var _o = 0; + function Qt(e) { return e == null ? ":id" : typeof e == "string" ? e : "[".concat(e.join("+"), "]"); } - function vo(e, t, p) { - function r(x) { - if (x.type === 3) return null; - if (x.type === 4) throw new Error("Cannot convert never type to IDBKeyRange"); - var m = x.lower, v = x.upper, g = x.lowerOpen, x = x.upperOpen; - return m === void 0 ? v === void 0 ? null : t.upperBound(v, !!x) : v === void 0 ? t.lowerBound(m, !!g) : t.bound(m, v, !!g, !!x); + function Eo(e, t, x) { + function o(k) { + if (k.type === 3) return null; + if (k.type === 4) throw new Error("Cannot convert never type to IDBKeyRange"); + var _ = k.lower, I = k.upper, P = k.lowerOpen, k = k.upperOpen; + return _ === void 0 ? I === void 0 ? null : t.upperBound(I, !!k) : I === void 0 ? t.lowerBound(_, !!P) : t.bound(_, I, !!P, !!k); } - function i(_) { - var m, v = _.name; - return { name: v, schema: _, mutate: function(g) { - var x = g.trans, P = g.type, j = g.keys, k = g.values, S = g.range; - return new Promise(function(A, D) { - A = re(A); - var I = x.objectStore(v), T = I.keyPath == null, N = P === "put" || P === "add"; - if (!N && P !== "delete" && P !== "deleteRange") throw new Error("Invalid operation type: " + P); - var R, F = (j || k || { length: 1 }).length; - if (j && k && j.length !== k.length) throw new Error("Given keys array must have same length as given values array."); - if (F === 0) return A({ numFailures: 0, failures: {}, results: [], lastResult: void 0 }); - function G(pe) { - ++ge, St(pe); + function s(S) { + var _, I = S.name; + return { name: I, schema: S, mutate: function(P) { + var k = P.trans, C = P.type, B = P.keys, M = P.values, F = P.range; + return new Promise(function(U, Y) { + U = ge(U); + var q = k.objectStore(I), $ = q.keyPath == null, z = C === "put" || C === "add"; + if (!z && C !== "delete" && C !== "deleteRange") throw new Error("Invalid operation type: " + C); + var H, W = (B || M || { length: 1 }).length; + if (B && M && B.length !== M.length) throw new Error("Given keys array must have same length as given values array."); + if (W === 0) return U({ numFailures: 0, failures: {}, results: [], lastResult: void 0 }); + function ie(Re) { + ++Ue, Wt(Re); } - var J = [], X = [], ge = 0; - if (P === "deleteRange") { - if (S.type === 4) return A({ numFailures: ge, failures: X, results: [], lastResult: void 0 }); - S.type === 3 ? J.push(R = I.clear()) : J.push(R = I.delete(r(S))); + var se = [], ae = [], Ue = 0; + if (C === "deleteRange") { + if (F.type === 4) return U({ numFailures: Ue, failures: ae, results: [], lastResult: void 0 }); + F.type === 3 ? se.push(H = q.clear()) : se.push(H = q.delete(o(F))); } else { - var T = N ? T ? [k, j] : [k, null] : [j, null], W = T[0], fe = T[1]; - if (N) for (var he = 0; he < F; ++he) J.push(R = fe && fe[he] !== void 0 ? I[P](W[he], fe[he]) : I[P](W[he])), R.onerror = G; - else for (he = 0; he < F; ++he) J.push(R = I[P](W[he])), R.onerror = G; + var $ = z ? $ ? [M, B] : [M, null] : [B, null], ne = $[0], Oe = $[1]; + if (z) for (var Te = 0; Te < W; ++Te) se.push(H = Oe && Oe[Te] !== void 0 ? q[C](ne[Te], Oe[Te]) : q[C](ne[Te])), H.onerror = ie; + else for (Te = 0; Te < W; ++Te) se.push(H = q[C](ne[Te])), H.onerror = ie; } - function fn(pe) { - pe = pe.target.result, J.forEach(function(Xe, sr) { - return Xe.error != null && (X[sr] = Xe.error); - }), A({ numFailures: ge, failures: X, results: P === "delete" ? j : J.map(function(Xe) { - return Xe.result; - }), lastResult: pe }); + function Rn(Re) { + Re = Re.target.result, se.forEach(function(It, kr) { + return It.error != null && (ae[kr] = It.error); + }), U({ numFailures: Ue, failures: ae, results: C === "delete" ? B : se.map(function(It) { + return It.result; + }), lastResult: Re }); } - R.onerror = function(pe) { - G(pe), fn(pe); - }, R.onsuccess = fn; + H.onerror = function(Re) { + ie(Re), Rn(Re); + }, H.onsuccess = Rn; }); - }, getMany: function(g) { - var x = g.trans, P = g.keys; - return new Promise(function(j, k) { - j = re(j); - for (var S, A = x.objectStore(v), D = P.length, I = new Array(D), T = 0, N = 0, R = function(J) { - J = J.target, I[J._pos] = J.result, ++N === T && j(I); - }, F = Pe(k), G = 0; G < D; ++G) P[G] != null && ((S = A.get(P[G]))._pos = G, S.onsuccess = R, S.onerror = F, ++T); - T === 0 && j(I); + }, getMany: function(P) { + var k = P.trans, C = P.keys; + return new Promise(function(B, M) { + B = ge(B); + for (var F, U = k.objectStore(I), Y = C.length, q = new Array(Y), $ = 0, z = 0, H = function(se) { + se = se.target, q[se._pos] = se.result, ++z === $ && B(q); + }, W = We(M), ie = 0; ie < Y; ++ie) C[ie] != null && ((F = U.get(C[ie]))._pos = ie, F.onsuccess = H, F.onerror = W, ++$); + $ === 0 && B(q); }); - }, get: function(g) { - var x = g.trans, P = g.key; - return new Promise(function(j, k) { - j = re(j); - var S = x.objectStore(v).get(P); - S.onsuccess = function(A) { - return j(A.target.result); - }, S.onerror = Pe(k); + }, get: function(P) { + var k = P.trans, C = P.key; + return new Promise(function(B, M) { + B = ge(B); + var F = k.objectStore(I).get(C); + F.onsuccess = function(U) { + return B(U.target.result); + }, F.onerror = We(M); }); - }, query: (m = y, function(g) { - return new Promise(function(x, P) { - x = re(x); - var j, k, S, T = g.trans, A = g.values, D = g.limit, R = g.query, I = D === 1 / 0 ? void 0 : D, N = R.index, R = R.range, T = T.objectStore(v), N = N.isPrimaryKey ? T : T.index(N.name), R = r(R); - if (D === 0) return x({ result: [] }); - m ? ((I = A ? N.getAll(R, I) : N.getAllKeys(R, I)).onsuccess = function(F) { - return x({ result: F.target.result }); - }, I.onerror = Pe(P)) : (j = 0, k = !A && "openKeyCursor" in N ? N.openKeyCursor(R) : N.openCursor(R), S = [], k.onsuccess = function(F) { - var G = k.result; - return G ? (S.push(A ? G.value : G.primaryKey), ++j === D ? x({ result: S }) : void G.continue()) : x({ result: S }); - }, k.onerror = Pe(P)); + }, query: (_ = w, function(P) { + return new Promise(function(k, C) { + k = ge(k); + var B, M, F, $ = P.trans, U = P.values, Y = P.limit, H = P.query, q = Y === 1 / 0 ? void 0 : Y, z = H.index, H = H.range, $ = $.objectStore(I), z = z.isPrimaryKey ? $ : $.index(z.name), H = o(H); + if (Y === 0) return k({ result: [] }); + _ ? ((q = U ? z.getAll(H, q) : z.getAllKeys(H, q)).onsuccess = function(W) { + return k({ result: W.target.result }); + }, q.onerror = We(C)) : (B = 0, M = !U && "openKeyCursor" in z ? z.openKeyCursor(H) : z.openCursor(H), F = [], M.onsuccess = function(W) { + var ie = M.result; + return ie ? (F.push(U ? ie.value : ie.primaryKey), ++B === Y ? k({ result: F }) : void ie.continue()) : k({ result: F }); + }, M.onerror = We(C)); }); - }), openCursor: function(g) { - var x = g.trans, P = g.values, j = g.query, k = g.reverse, S = g.unique; - return new Promise(function(A, D) { - A = re(A); - var N = j.index, I = j.range, T = x.objectStore(v), T = N.isPrimaryKey ? T : T.index(N.name), N = k ? S ? "prevunique" : "prev" : S ? "nextunique" : "next", R = !P && "openKeyCursor" in T ? T.openKeyCursor(r(I), N) : T.openCursor(r(I), N); - R.onerror = Pe(D), R.onsuccess = re(function(F) { - var G, J, X, ge, W = R.result; - W ? (W.___id = ++mo, W.done = !1, G = W.continue.bind(W), J = (J = W.continuePrimaryKey) && J.bind(W), X = W.advance.bind(W), ge = function() { + }), openCursor: function(P) { + var k = P.trans, C = P.values, B = P.query, M = P.reverse, F = P.unique; + return new Promise(function(U, Y) { + U = ge(U); + var z = B.index, q = B.range, $ = k.objectStore(I), $ = z.isPrimaryKey ? $ : $.index(z.name), z = M ? F ? "prevunique" : "prev" : F ? "nextunique" : "next", H = !C && "openKeyCursor" in $ ? $.openKeyCursor(o(q), z) : $.openCursor(o(q), z); + H.onerror = We(Y), H.onsuccess = ge(function(W) { + var ie, se, ae, Ue, ne = H.result; + ne ? (ne.___id = ++_o, ne.done = !1, ie = ne.continue.bind(ne), se = (se = ne.continuePrimaryKey) && se.bind(ne), ae = ne.advance.bind(ne), Ue = function() { throw new Error("Cursor not stopped"); - }, W.trans = x, W.stop = W.continue = W.continuePrimaryKey = W.advance = function() { + }, ne.trans = k, ne.stop = ne.continue = ne.continuePrimaryKey = ne.advance = function() { throw new Error("Cursor not started"); - }, W.fail = re(D), W.next = function() { - var fe = this, he = 1; + }, ne.fail = ge(Y), ne.next = function() { + var Oe = this, Te = 1; return this.start(function() { - return he-- ? fe.continue() : fe.stop(); + return Te-- ? Oe.continue() : Oe.stop(); }).then(function() { - return fe; + return Oe; }); - }, W.start = function(fe) { - function he() { - if (R.result) try { - fe(); - } catch (pe) { - W.fail(pe); + }, ne.start = function(Oe) { + function Te() { + if (H.result) try { + Oe(); + } catch (Re) { + ne.fail(Re); } - else W.done = !0, W.start = function() { + else ne.done = !0, ne.start = function() { throw new Error("Cursor behind last entry"); - }, W.stop(); + }, ne.stop(); } - var fn = new Promise(function(pe, Xe) { - pe = re(pe), R.onerror = Pe(Xe), W.fail = Xe, W.stop = function(sr) { - W.stop = W.continue = W.continuePrimaryKey = W.advance = ge, pe(sr); + var Rn = new Promise(function(Re, It) { + Re = ge(Re), H.onerror = We(It), ne.fail = It, ne.stop = function(kr) { + ne.stop = ne.continue = ne.continuePrimaryKey = ne.advance = Ue, Re(kr); }; }); - return R.onsuccess = re(function(pe) { - R.onsuccess = he, he(); - }), W.continue = G, W.continuePrimaryKey = J, W.advance = X, he(), fn; - }, A(W)) : A(null); - }, D); + return H.onsuccess = ge(function(Re) { + H.onsuccess = Te, Te(); + }), ne.continue = ie, ne.continuePrimaryKey = se, ne.advance = ae, Te(), Rn; + }, U(ne)) : U(null); + }, Y); }); - }, count: function(g) { - var x = g.query, P = g.trans, j = x.index, k = x.range; - return new Promise(function(S, A) { - var D = P.objectStore(v), I = j.isPrimaryKey ? D : D.index(j.name), D = r(k), I = D ? I.count(D) : I.count(); - I.onsuccess = re(function(T) { - return S(T.target.result); - }), I.onerror = Pe(A); + }, count: function(P) { + var k = P.query, C = P.trans, B = k.index, M = k.range; + return new Promise(function(F, U) { + var Y = C.objectStore(I), q = B.isPrimaryKey ? Y : Y.index(B.name), Y = o(M), q = Y ? q.count(Y) : q.count(); + q.onsuccess = ge(function($) { + return F($.target.result); + }), q.onerror = We(U); }); } }; } - var o, u, d, b = (u = p, d = Yr((o = e).objectStoreNames), { schema: { name: o.name, tables: d.map(function(_) { - return u.objectStore(_); - }).map(function(_) { - var m = _.keyPath, x = _.autoIncrement, v = O(m), g = {}, x = { name: _.name, primaryKey: { name: null, isPrimaryKey: !0, outbound: m == null, compound: v, keyPath: m, autoIncrement: x, unique: !0, extractKey: Ln(m) }, indexes: Yr(_.indexNames).map(function(P) { - return _.index(P); - }).map(function(S) { - var j = S.name, k = S.unique, A = S.multiEntry, S = S.keyPath, A = { name: j, compound: O(S), keyPath: S, unique: k, multiEntry: A, extractKey: Ln(S) }; - return g[It(S)] = A; - }), getIndexByKeyPath: function(P) { - return g[It(P)]; + var a, d, y, j = (d = x, y = oi((a = e).objectStoreNames), { schema: { name: a.name, tables: y.map(function(S) { + return d.objectStore(S); + }).map(function(S) { + var _ = S.keyPath, k = S.autoIncrement, I = g(_), P = {}, k = { name: S.name, primaryKey: { name: null, isPrimaryKey: !0, outbound: _ == null, compound: I, keyPath: _, autoIncrement: k, unique: !0, extractKey: cr(_) }, indexes: oi(S.indexNames).map(function(C) { + return S.index(C); + }).map(function(F) { + var B = F.name, M = F.unique, U = F.multiEntry, F = F.keyPath, U = { name: B, compound: g(F), keyPath: F, unique: M, multiEntry: U, extractKey: cr(F) }; + return P[Qt(F)] = U; + }), getIndexByKeyPath: function(C) { + return P[Qt(C)]; } }; - return g[":id"] = x.primaryKey, m != null && (g[It(m)] = x.primaryKey), x; - }) }, hasGetAll: 0 < d.length && "getAll" in u.objectStore(d[0]) && !(typeof navigator < "u" && /Safari/.test(navigator.userAgent) && !/(Chrome\/|Edge\/)/.test(navigator.userAgent) && [].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1] < 604) }), p = b.schema, y = b.hasGetAll, b = p.tables.map(i), h = {}; - return b.forEach(function(_) { - return h[_.name] = _; - }), { stack: "dbcore", transaction: e.transaction.bind(e), table: function(_) { - if (!h[_]) throw new Error("Table '".concat(_, "' not found")); - return h[_]; - }, MIN_KEY: -1 / 0, MAX_KEY: Et(t), schema: p }; - } - function go(e, t, n, r) { - var i = n.IDBKeyRange; - return n.indexedDB, { dbcore: (r = vo(t, i, r), e.dbcore.reduce(function(o, u) { - return u = u.create, l(l({}, o), u(o)); - }, r)) }; - } - function en(e, r) { - var n = r.db, r = go(e._middlewares, n, e._deps, r); - e.core = r.dbcore, e.tables.forEach(function(i) { - var o = i.name; - e.core.schema.tables.some(function(u) { - return u.name === o; - }) && (i.core = e.core.table(o), e[o] instanceof e.Table && (e[o].core = i.core)); + return P[":id"] = k.primaryKey, _ != null && (P[Qt(_)] = k.primaryKey), k; + }) }, hasGetAll: 0 < y.length && "getAll" in d.objectStore(y[0]) && !(typeof navigator < "u" && /Safari/.test(navigator.userAgent) && !/(Chrome\/|Edge\/)/.test(navigator.userAgent) && [].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1] < 604) }), x = j.schema, w = j.hasGetAll, j = x.tables.map(s), v = {}; + return j.forEach(function(S) { + return v[S.name] = S; + }), { stack: "dbcore", transaction: e.transaction.bind(e), table: function(S) { + if (!v[S]) throw new Error("Table '".concat(S, "' not found")); + return v[S]; + }, MIN_KEY: -1 / 0, MAX_KEY: Jt(t), schema: x }; + } + function Io(e, t, n, o) { + var s = n.IDBKeyRange; + return n.indexedDB, { dbcore: (o = Eo(t, s, o), e.dbcore.reduce(function(a, d) { + return d = d.create, h(h({}, a), d(a)); + }, o)) }; + } + function In(e, o) { + var n = o.db, o = Io(e._middlewares, n, e._deps, o); + e.core = o.dbcore, e.tables.forEach(function(s) { + var a = s.name; + e.core.schema.tables.some(function(d) { + return d.name === a; + }) && (s.core = e.core.table(a), e[a] instanceof e.Table && (e[a].core = s.core)); }); } - function tn(e, t, n, r) { - n.forEach(function(i) { - var o = r[i]; - t.forEach(function(u) { - var d = (function p(y, b) { - return Nt(y, b) || (y = Y(y)) && p(y, b); - })(u, i); - (!d || "value" in d && d.value === void 0) && (u === e.Transaction.prototype || u instanceof e.Transaction ? ie(u, i, { get: function() { - return this.table(i); - }, set: function(p) { - w(this, i, { value: p, writable: !0, configurable: !0, enumerable: !0 }); - } }) : u[i] = new e.Table(i, o)); + function Pn(e, t, n, o) { + n.forEach(function(s) { + var a = o[s]; + t.forEach(function(d) { + var y = (function x(w, j) { + return xe(w, j) || (w = Q(w)) && x(w, j); + })(d, s); + (!y || "value" in y && y.value === void 0) && (d === e.Transaction.prototype || d instanceof e.Transaction ? Z(d, s, { get: function() { + return this.table(s); + }, set: function(x) { + b(this, s, { value: x, writable: !0, configurable: !0, enumerable: !0 }); + } }) : d[s] = new e.Table(s, a)); }); }); } - function Hn(e, t) { + function lr(e, t) { t.forEach(function(n) { - for (var r in n) n[r] instanceof e.Table && delete n[r]; + for (var o in n) n[o] instanceof e.Table && delete n[o]; }); } - function bo(e, t) { + function Po(e, t) { return e._cfg.version - t._cfg.version; } - function xo(e, t, n, r) { - var i = e._dbSchema; - n.objectStoreNames.contains("$meta") && !i.$meta && (i.$meta = $n("$meta", Wr("")[0], []), e._storeNames.push("$meta")); - var o = e._createTransaction("readwrite", e._storeNames, i); - o.create(n), o._completion.catch(r); - var u = o._reject.bind(o), d = $.transless || $; - Te(function() { - return $.trans = o, $.transless = d, t !== 0 ? (en(e, n), y = t, ((p = o).storeNames.includes("$meta") ? p.table("$meta").get("version").then(function(b) { - return b ?? y; - }) : q.resolve(y)).then(function(b) { - return _ = b, m = o, v = n, g = [], b = (h = e)._versions, x = h._dbSchema = rn(0, h.idbdb, v), (b = b.filter(function(P) { - return P._cfg.version >= _; - })).length !== 0 ? (b.forEach(function(P) { - g.push(function() { - var j = x, k = P._cfg.dbschema; - on(h, j, v), on(h, k, v), x = h._dbSchema = k; - var S = Un(j, k); - S.add.forEach(function(N) { - zn(v, N[0], N[1].primKey, N[1].indexes); - }), S.change.forEach(function(N) { - if (N.recreate) throw new U.Upgrade("Not yet support for changing primary key"); - var R = v.objectStore(N.name); - N.add.forEach(function(F) { - return nn(R, F); - }), N.change.forEach(function(F) { - R.deleteIndex(F.name), nn(R, F); - }), N.del.forEach(function(F) { - return R.deleteIndex(F); + function jo(e, t, n, o) { + var s = e._dbSchema; + n.objectStoreNames.contains("$meta") && !s.$meta && (s.$meta = ur("$meta", ai("")[0], []), e._storeNames.push("$meta")); + var a = e._createTransaction("readwrite", e._storeNames, s); + a.create(n), a._completion.catch(o); + var d = a._reject.bind(a), y = L.transless || L; + ct(function() { + return L.trans = a, L.transless = y, t !== 0 ? (In(e, n), w = t, ((x = a).storeNames.includes("$meta") ? x.table("$meta").get("version").then(function(j) { + return j ?? w; + }) : V.resolve(w)).then(function(j) { + return S = j, _ = a, I = n, P = [], j = (v = e)._versions, k = v._dbSchema = kn(0, v.idbdb, I), (j = j.filter(function(C) { + return C._cfg.version >= S; + })).length !== 0 ? (j.forEach(function(C) { + P.push(function() { + var B = k, M = C._cfg.dbschema; + Sn(v, B, I), Sn(v, M, I), k = v._dbSchema = M; + var F = fr(B, M); + F.add.forEach(function(z) { + hr(I, z[0], z[1].primKey, z[1].indexes); + }), F.change.forEach(function(z) { + if (z.recreate) throw new X.Upgrade("Not yet support for changing primary key"); + var H = I.objectStore(z.name); + z.add.forEach(function(W) { + return jn(H, W); + }), z.change.forEach(function(W) { + H.deleteIndex(W.name), jn(H, W); + }), z.del.forEach(function(W) { + return H.deleteIndex(W); }); }); - var A = P._cfg.contentUpgrade; - if (A && P._cfg.version > _) { - en(h, v), m._memoizedTables = {}; - var D = _r(k); - S.del.forEach(function(N) { - D[N] = j[N]; - }), Hn(h, [h.Transaction.prototype]), tn(h, [h.Transaction.prototype], C(D), D), m.schema = D; - var I, T = jn(A); - return T && at(), S = q.follow(function() { - var N; - (I = A(m)) && T && (N = Ke.bind(null, null), I.then(N, N)); - }), I && typeof I.then == "function" ? q.resolve(I) : S.then(function() { - return I; + var U = C._cfg.contentUpgrade; + if (U && C._cfg.version > S) { + In(v, I), _._memoizedTables = {}; + var Y = an(M); + F.del.forEach(function(z) { + Y[z] = B[z]; + }), lr(v, [v.Transaction.prototype]), Pn(v, [v.Transaction.prototype], O(Y), Y), _.schema = Y; + var q, $ = we(U); + return $ && Ot(), F = V.follow(function() { + var z; + (q = U(_)) && $ && (z = lt.bind(null, null), q.then(z, z)); + }), q && typeof q.then == "function" ? V.resolve(q) : F.then(function() { + return q; }); } - }), g.push(function(j) { - var k, S, A = P._cfg.dbschema; - k = A, S = j, [].slice.call(S.db.objectStoreNames).forEach(function(D) { - return k[D] == null && S.db.deleteObjectStore(D); - }), Hn(h, [h.Transaction.prototype]), tn(h, [h.Transaction.prototype], h._storeNames, h._dbSchema), m.schema = h._dbSchema; - }), g.push(function(j) { - h.idbdb.objectStoreNames.contains("$meta") && (Math.ceil(h.idbdb.version / 10) === P._cfg.version ? (h.idbdb.deleteObjectStore("$meta"), delete h._dbSchema.$meta, h._storeNames = h._storeNames.filter(function(k) { - return k !== "$meta"; - })) : j.objectStore("$meta").put(P._cfg.version, "version")); + }), P.push(function(B) { + var M, F, U = C._cfg.dbschema; + M = U, F = B, [].slice.call(F.db.objectStoreNames).forEach(function(Y) { + return M[Y] == null && F.db.deleteObjectStore(Y); + }), lr(v, [v.Transaction.prototype]), Pn(v, [v.Transaction.prototype], v._storeNames, v._dbSchema), _.schema = v._dbSchema; + }), P.push(function(B) { + v.idbdb.objectStoreNames.contains("$meta") && (Math.ceil(v.idbdb.version / 10) === C._cfg.version ? (v.idbdb.deleteObjectStore("$meta"), delete v._dbSchema.$meta, v._storeNames = v._storeNames.filter(function(M) { + return M !== "$meta"; + })) : B.objectStore("$meta").put(C._cfg.version, "version")); }); - }), (function P() { - return g.length ? q.resolve(g.shift()(m.idbtrans)).then(P) : q.resolve(); + }), (function C() { + return P.length ? V.resolve(P.shift()(_.idbtrans)).then(C) : V.resolve(); })().then(function() { - Vr(x, v); - })) : q.resolve(); - var h, _, m, v, g, x; - }).catch(u)) : (C(i).forEach(function(b) { - zn(n, b, i[b].primKey, i[b].indexes); - }), en(e, n), void q.follow(function() { - return e.on.populate.fire(o); - }).catch(u)); - var p, y; + si(k, I); + })) : V.resolve(); + var v, S, _, I, P, k; + }).catch(d)) : (O(s).forEach(function(j) { + hr(n, j, s[j].primKey, s[j].indexes); + }), In(e, n), void V.follow(function() { + return e.on.populate.fire(a); + }).catch(d)); + var x, w; }); } - function _o(e, t) { - Vr(e._dbSchema, t), t.db.version % 10 != 0 || t.objectStoreNames.contains("$meta") || t.db.createObjectStore("$meta").add(Math.ceil(t.db.version / 10 - 1), "version"); - var n = rn(0, e.idbdb, t); - on(e, e._dbSchema, t); - for (var r = 0, i = Un(n, e._dbSchema).change; r < i.length; r++) { - var o = (function(u) { - if (u.change.length || u.recreate) return console.warn("Unable to patch indexes of table ".concat(u.name, " because it has changes on the type of index or primary key.")), { value: void 0 }; - var d = t.objectStore(u.name); - u.add.forEach(function(p) { - we && console.debug("Dexie upgrade patch: Creating missing index ".concat(u.name, ".").concat(p.src)), nn(d, p); + function ko(e, t) { + si(e._dbSchema, t), t.db.version % 10 != 0 || t.objectStoreNames.contains("$meta") || t.db.createObjectStore("$meta").add(Math.ceil(t.db.version / 10 - 1), "version"); + var n = kn(0, e.idbdb, t); + Sn(e, e._dbSchema, t); + for (var o = 0, s = fr(n, e._dbSchema).change; o < s.length; o++) { + var a = (function(d) { + if (d.change.length || d.recreate) return console.warn("Unable to patch indexes of table ".concat(d.name, " because it has changes on the type of index or primary key.")), { value: void 0 }; + var y = t.objectStore(d.name); + d.add.forEach(function(x) { + Me && console.debug("Dexie upgrade patch: Creating missing index ".concat(d.name, ".").concat(x.src)), jn(y, x); }); - })(i[r]); - if (typeof o == "object") return o.value; + })(s[o]); + if (typeof a == "object") return a.value; } } - function Un(e, t) { - var n, r = { del: [], add: [], change: [] }; - for (n in e) t[n] || r.del.push(n); + function fr(e, t) { + var n, o = { del: [], add: [], change: [] }; + for (n in e) t[n] || o.del.push(n); for (n in t) { - var i = e[n], o = t[n]; - if (i) { - var u = { name: n, def: o, recreate: !1, del: [], add: [], change: [] }; - if ("" + (i.primKey.keyPath || "") != "" + (o.primKey.keyPath || "") || i.primKey.auto !== o.primKey.auto) u.recreate = !0, r.change.push(u); + var s = e[n], a = t[n]; + if (s) { + var d = { name: n, def: a, recreate: !1, del: [], add: [], change: [] }; + if ("" + (s.primKey.keyPath || "") != "" + (a.primKey.keyPath || "") || s.primKey.auto !== a.primKey.auto) d.recreate = !0, o.change.push(d); else { - var d = i.idxByName, p = o.idxByName, y = void 0; - for (y in d) p[y] || u.del.push(y); - for (y in p) { - var b = d[y], h = p[y]; - b ? b.src !== h.src && u.change.push(h) : u.add.push(h); + var y = s.idxByName, x = a.idxByName, w = void 0; + for (w in y) x[w] || d.del.push(w); + for (w in x) { + var j = y[w], v = x[w]; + j ? j.src !== v.src && d.change.push(v) : d.add.push(v); } - (0 < u.del.length || 0 < u.add.length || 0 < u.change.length) && r.change.push(u); + (0 < d.del.length || 0 < d.add.length || 0 < d.change.length) && o.change.push(d); } - } else r.add.push([n, o]); + } else o.add.push([n, a]); } - return r; + return o; } - function zn(e, t, n, r) { - var i = e.db.createObjectStore(t, n.keyPath ? { keyPath: n.keyPath, autoIncrement: n.auto } : { autoIncrement: n.auto }); - return r.forEach(function(o) { - return nn(i, o); - }), i; + function hr(e, t, n, o) { + var s = e.db.createObjectStore(t, n.keyPath ? { keyPath: n.keyPath, autoIncrement: n.auto } : { autoIncrement: n.auto }); + return o.forEach(function(a) { + return jn(s, a); + }), s; } - function Vr(e, t) { - C(e).forEach(function(n) { - t.db.objectStoreNames.contains(n) || (we && console.debug("Dexie: Creating missing table", n), zn(t, n, e[n].primKey, e[n].indexes)); + function si(e, t) { + O(e).forEach(function(n) { + t.db.objectStoreNames.contains(n) || (Me && console.debug("Dexie: Creating missing table", n), hr(t, n, e[n].primKey, e[n].indexes)); }); } - function nn(e, t) { + function jn(e, t) { e.createIndex(t.name, t.keyPath, { unique: t.unique, multiEntry: t.multi }); } - function rn(e, t, n) { - var r = {}; - return tt(t.objectStoreNames, 0).forEach(function(i) { - for (var o = n.objectStore(i), u = Fn(zr(y = o.keyPath), y || "", !0, !1, !!o.autoIncrement, y && typeof y != "string", !0), d = [], p = 0; p < o.indexNames.length; ++p) { - var b = o.index(o.indexNames[p]), y = b.keyPath, b = Fn(b.name, y, !!b.unique, !!b.multiEntry, !1, y && typeof y != "string", !1); - d.push(b); + function kn(e, t, n) { + var o = {}; + return ye(t.objectStoreNames, 0).forEach(function(s) { + for (var a = n.objectStore(s), d = ar(ii(w = a.keyPath), w || "", !0, !1, !!a.autoIncrement, w && typeof w != "string", !0), y = [], x = 0; x < a.indexNames.length; ++x) { + var j = a.index(a.indexNames[x]), w = j.keyPath, j = ar(j.name, w, !!j.unique, !!j.multiEntry, !1, w && typeof w != "string", !1); + y.push(j); } - r[i] = $n(i, u, d); - }), r; - } - function on(e, t, n) { - for (var r = n.db.objectStoreNames, i = 0; i < r.length; ++i) { - var o = r[i], u = n.objectStore(o); - e._hasGetAll = "getAll" in u; - for (var d = 0; d < u.indexNames.length; ++d) { - var p = u.indexNames[d], y = u.index(p).keyPath, b = typeof y == "string" ? y : "[" + tt(y).join("+") + "]"; - !t[o] || (y = t[o].idxByName[b]) && (y.name = p, delete t[o].idxByName[b], t[o].idxByName[p] = y); + o[s] = ur(s, d, y); + }), o; + } + function Sn(e, t, n) { + for (var o = n.db.objectStoreNames, s = 0; s < o.length; ++s) { + var a = o[s], d = n.objectStore(a); + e._hasGetAll = "getAll" in d; + for (var y = 0; y < d.indexNames.length; ++y) { + var x = d.indexNames[y], w = d.index(x).keyPath, j = typeof w == "string" ? w : "[" + ye(w).join("+") + "]"; + !t[a] || (w = t[a].idxByName[j]) && (w.name = x, delete t[a].idxByName[j], t[a].idxByName[x] = w); } } - typeof navigator < "u" && /Safari/.test(navigator.userAgent) && !/(Chrome\/|Edge\/)/.test(navigator.userAgent) && M.WorkerGlobalScope && M instanceof M.WorkerGlobalScope && [].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1] < 604 && (e._hasGetAll = !1); + typeof navigator < "u" && /Safari/.test(navigator.userAgent) && !/(Chrome\/|Edge\/)/.test(navigator.userAgent) && D.WorkerGlobalScope && D instanceof D.WorkerGlobalScope && [].concat(navigator.userAgent.match(/Safari\/(\d*)/))[1] < 604 && (e._hasGetAll = !1); } - function Wr(e) { + function ai(e) { return e.split(",").map(function(t, n) { - var o = t.split(":"), r = (i = o[1]) === null || i === void 0 ? void 0 : i.trim(), i = (t = o[0].trim()).replace(/([&*]|\+\+)/g, ""), o = /^\[/.test(i) ? i.match(/^\[(.*)\]$/)[1].split("+") : i; - return Fn(i, o || null, /\&/.test(t), /\*/.test(t), /\+\+/.test(t), O(o), n === 0, r); + var a = t.split(":"), o = (s = a[1]) === null || s === void 0 ? void 0 : s.trim(), s = (t = a[0].trim()).replace(/([&*]|\+\+)/g, ""), a = /^\[/.test(s) ? s.match(/^\[(.*)\]$/)[1].split("+") : s; + return ar(s, a || null, /\&/.test(t), /\*/.test(t), /\+\+/.test(t), g(a), n === 0, o); }); } - var wo = (dt.prototype._createTableSchema = $n, dt.prototype._parseIndexSyntax = Wr, dt.prototype._parseStoresSpec = function(e, t) { + var So = (Ft.prototype._createTableSchema = ur, Ft.prototype._parseIndexSyntax = ai, Ft.prototype._parseStoresSpec = function(e, t) { var n = this; - C(e).forEach(function(r) { - if (e[r] !== null) { - var i = n._parseIndexSyntax(e[r]), o = i.shift(); - if (!o) throw new U.Schema("Invalid schema for table " + r + ": " + e[r]); - if (o.unique = !0, o.multi) throw new U.Schema("Primary key cannot be multiEntry*"); - i.forEach(function(u) { - if (u.auto) throw new U.Schema("Only primary key can be marked as autoIncrement (++)"); - if (!u.keyPath) throw new U.Schema("Index must have a name and cannot be an empty string"); - }), i = n._createTableSchema(r, o, i), t[r] = i; + O(e).forEach(function(o) { + if (e[o] !== null) { + var s = n._parseIndexSyntax(e[o]), a = s.shift(); + if (!a) throw new X.Schema("Invalid schema for table " + o + ": " + e[o]); + if (a.unique = !0, a.multi) throw new X.Schema("Primary key cannot be multiEntry*"); + s.forEach(function(d) { + if (d.auto) throw new X.Schema("Only primary key can be marked as autoIncrement (++)"); + if (!d.keyPath) throw new X.Schema("Index must have a name and cannot be an empty string"); + }), s = n._createTableSchema(o, a, s), t[o] = s; } }); - }, dt.prototype.stores = function(n) { + }, Ft.prototype.stores = function(n) { var t = this.db; - this._cfg.storesSource = this._cfg.storesSource ? z(this._cfg.storesSource, n) : n; - var n = t._versions, r = {}, i = {}; - return n.forEach(function(o) { - z(r, o._cfg.storesSource), i = o._cfg.dbschema = {}, o._parseStoresSpec(r, i); - }), t._dbSchema = i, Hn(t, [t._allTables, t, t.Transaction.prototype]), tn(t, [t._allTables, t, t.Transaction.prototype, this._cfg.tables], C(i), i), t._storeNames = C(i), this; - }, dt.prototype.upgrade = function(e) { - return this._cfg.contentUpgrade = Sn(this._cfg.contentUpgrade || te, e), this; - }, dt); - function dt() { - } - function Yn(e, t) { + this._cfg.storesSource = this._cfg.storesSource ? G(this._cfg.storesSource, n) : n; + var n = t._versions, o = {}, s = {}; + return n.forEach(function(a) { + G(o, a._cfg.storesSource), s = a._cfg.dbschema = {}, a._parseStoresSpec(o, s); + }), t._dbSchema = s, lr(t, [t._allTables, t, t.Transaction.prototype]), Pn(t, [t._allTables, t, t.Transaction.prototype, this._cfg.tables], O(s), s), t._storeNames = O(s), this; + }, Ft.prototype.upgrade = function(e) { + return this._cfg.contentUpgrade = Ct(this._cfg.contentUpgrade || he, e), this; + }, Ft); + function Ft() { + } + function dr(e, t) { var n = e._dbNamesDB; - return n || (n = e._dbNamesDB = new Oe(Wt, { addons: [], indexedDB: e, IDBKeyRange: t })).version(1).stores({ dbnames: "name" }), n.table("dbnames"); + return n || (n = e._dbNamesDB = new ot(vn, { addons: [], indexedDB: e, IDBKeyRange: t })).version(1).stores({ dbnames: "name" }), n.table("dbnames"); } - function Vn(e) { + function pr(e) { return e && typeof e.databases == "function"; } - function Wn(e) { - return Te(function() { - return $.letThrough = !0, e(); + function yr(e) { + return ct(function() { + return L.letThrough = !0, e(); }); } - function Qn(e) { + function mr(e) { return !("from" in e); } - var de = function(e, t) { + var Be = function(e, t) { if (!this) { - var n = new de(); - return e && "d" in e && z(n, e), n; + var n = new Be(); + return e && "d" in e && G(n, e), n; } - z(this, arguments.length ? { d: 1, from: e, to: 1 < arguments.length ? t : e } : { d: 0 }); + G(this, arguments.length ? { d: 1, from: e, to: 1 < arguments.length ? t : e } : { d: 0 }); }; - function Ot(e, t, n) { - var r = Z(t, n); - if (!isNaN(r)) { - if (0 < r) throw RangeError(); - if (Qn(e)) return z(e, { from: t, to: n, d: 1 }); - var i = e.l, r = e.r; - if (Z(n, e.from) < 0) return i ? Ot(i, t, n) : e.l = { from: t, to: n, d: 1, l: null, r: null }, Gr(e); - if (0 < Z(t, e.to)) return r ? Ot(r, t, n) : e.r = { from: t, to: n, d: 1, l: null, r: null }, Gr(e); - Z(t, e.from) < 0 && (e.from = t, e.l = null, e.d = r ? r.d + 1 : 1), 0 < Z(n, e.to) && (e.to = n, e.r = null, e.d = e.l ? e.l.d + 1 : 1), n = !e.r, i && !e.l && At(e, i), r && n && At(e, r); + function Xt(e, t, n) { + var o = le(t, n); + if (!isNaN(o)) { + if (0 < o) throw RangeError(); + if (mr(e)) return G(e, { from: t, to: n, d: 1 }); + var s = e.l, o = e.r; + if (le(n, e.from) < 0) return s ? Xt(s, t, n) : e.l = { from: t, to: n, d: 1, l: null, r: null }, ci(e); + if (0 < le(t, e.to)) return o ? Xt(o, t, n) : e.r = { from: t, to: n, d: 1, l: null, r: null }, ci(e); + le(t, e.from) < 0 && (e.from = t, e.l = null, e.d = o ? o.d + 1 : 1), 0 < le(n, e.to) && (e.to = n, e.r = null, e.d = e.l ? e.l.d + 1 : 1), n = !e.r, s && !e.l && Zt(e, s), o && n && Zt(e, o); } } - function At(e, t) { - Qn(t) || (function n(r, p) { - var o = p.from, u = p.to, d = p.l, p = p.r; - Ot(r, o, u), d && n(r, d), p && n(r, p); + function Zt(e, t) { + mr(t) || (function n(o, x) { + var a = x.from, d = x.to, y = x.l, x = x.r; + Xt(o, a, d), y && n(o, y), x && n(o, x); })(e, t); } - function Qr(e, t) { - var n = sn(t), r = n.next(); - if (r.done) return !1; - for (var i = r.value, o = sn(e), u = o.next(i.from), d = u.value; !r.done && !u.done; ) { - if (Z(d.from, i.to) <= 0 && 0 <= Z(d.to, i.from)) return !0; - Z(i.from, d.from) < 0 ? i = (r = n.next(d.from)).value : d = (u = o.next(i.from)).value; + function ui(e, t) { + var n = Cn(t), o = n.next(); + if (o.done) return !1; + for (var s = o.value, a = Cn(e), d = a.next(s.from), y = d.value; !o.done && !d.done; ) { + if (le(y.from, s.to) <= 0 && 0 <= le(y.to, s.from)) return !0; + le(s.from, y.from) < 0 ? s = (o = n.next(y.from)).value : y = (d = a.next(s.from)).value; } return !1; } - function sn(e) { - var t = Qn(e) ? null : { s: 0, n: e }; + function Cn(e) { + var t = mr(e) ? null : { s: 0, n: e }; return { next: function(n) { - for (var r = 0 < arguments.length; t; ) switch (t.s) { + for (var o = 0 < arguments.length; t; ) switch (t.s) { case 0: - if (t.s = 1, r) for (; t.n.l && Z(n, t.n.from) < 0; ) t = { up: t, n: t.n.l, s: 1 }; + if (t.s = 1, o) for (; t.n.l && le(n, t.n.from) < 0; ) t = { up: t, n: t.n.l, s: 1 }; else for (; t.n.l; ) t = { up: t, n: t.n.l, s: 1 }; case 1: - if (t.s = 2, !r || Z(n, t.n.to) <= 0) return { value: t.n, done: !1 }; + if (t.s = 2, !o || le(n, t.n.to) <= 0) return { value: t.n, done: !1 }; case 2: if (t.n.r) { t.s = 3, t = { up: t, n: t.n.r, s: 0 }; @@ -2160,328 +2160,328 @@ function Cs() { return { done: !0 }; } }; } - function Gr(e) { - var t, n, r = (((t = e.r) === null || t === void 0 ? void 0 : t.d) || 0) - (((n = e.l) === null || n === void 0 ? void 0 : n.d) || 0), i = 1 < r ? "r" : r < -1 ? "l" : ""; - i && (t = i == "r" ? "l" : "r", n = l({}, e), r = e[i], e.from = r.from, e.to = r.to, e[i] = r[i], n[i] = r[t], (e[t] = n).d = Jr(n)), e.d = Jr(e); + function ci(e) { + var t, n, o = (((t = e.r) === null || t === void 0 ? void 0 : t.d) || 0) - (((n = e.l) === null || n === void 0 ? void 0 : n.d) || 0), s = 1 < o ? "r" : o < -1 ? "l" : ""; + s && (t = s == "r" ? "l" : "r", n = h({}, e), o = e[s], e.from = o.from, e.to = o.to, e[s] = o[s], n[s] = o[t], (e[t] = n).d = li(n)), e.d = li(e); } - function Jr(n) { + function li(n) { var t = n.r, n = n.l; return (t ? n ? Math.max(t.d, n.d) : t.d : n ? n.d : 0) + 1; } - function an(e, t) { - return C(t).forEach(function(n) { - e[n] ? At(e[n], t[n]) : e[n] = (function r(i) { - var o, u, d = {}; - for (o in i) B(i, o) && (u = i[o], d[o] = !u || typeof u != "object" || Pr.has(u.constructor) ? u : r(u)); - return d; + function An(e, t) { + return O(t).forEach(function(n) { + e[n] ? Zt(e[n], t[n]) : e[n] = (function o(s) { + var a, d, y = {}; + for (a in s) N(s, a) && (d = s[a], y[a] = !d || typeof d != "object" || cn.has(d.constructor) ? d : o(d)); + return y; })(t[n]); }), e; } - function Gn(e, t) { + function gr(e, t) { return e.all || t.all || Object.keys(e).some(function(n) { - return t[n] && Qr(t[n], e[n]); + return t[n] && ui(t[n], e[n]); }); } - H(de.prototype, ((xe = { add: function(e) { - return At(this, e), this; + J(Be.prototype, ((Ye = { add: function(e) { + return Zt(this, e), this; }, addKey: function(e) { - return Ot(this, e, e), this; + return Xt(this, e, e), this; }, addKeys: function(e) { var t = this; return e.forEach(function(n) { - return Ot(t, n, n); + return Xt(t, n, n); }), this; }, hasKey: function(e) { - var t = sn(this).next(e).value; - return t && Z(t.from, e) <= 0 && 0 <= Z(t.to, e); - } })[Pn] = function() { - return sn(this); - }, xe)); - var Ge = {}, Jn = {}, Xn = !1; - function un(e) { - an(Jn, e), Xn || (Xn = !0, setTimeout(function() { - Xn = !1, Zn(Jn, !(Jn = {})); + var t = Cn(this).next(e).value; + return t && le(t.from, e) <= 0 && 0 <= le(t.to, e); + } })[Ut] = function() { + return Cn(this); + }, Ye)); + var _t = {}, vr = {}, br = !1; + function Bn(e) { + An(vr, e), br || (br = !0, setTimeout(function() { + br = !1, xr(vr, !(vr = {})); }, 0)); } - function Zn(e, t) { + function xr(e, t) { t === void 0 && (t = !1); var n = /* @__PURE__ */ new Set(); - if (e.all) for (var r = 0, i = Object.values(Ge); r < i.length; r++) Xr(u = i[r], e, n, t); - else for (var o in e) { - var u, d = /^idb\:\/\/(.*)\/(.*)\//.exec(o); - d && (o = d[1], d = d[2], (u = Ge["idb://".concat(o, "/").concat(d)]) && Xr(u, e, n, t)); + if (e.all) for (var o = 0, s = Object.values(_t); o < s.length; o++) fi(d = s[o], e, n, t); + else for (var a in e) { + var d, y = /^idb\:\/\/(.*)\/(.*)\//.exec(a); + y && (a = y[1], y = y[2], (d = _t["idb://".concat(a, "/").concat(y)]) && fi(d, e, n, t)); } - n.forEach(function(p) { - return p(); + n.forEach(function(x) { + return x(); }); } - function Xr(e, t, n, r) { - for (var i = [], o = 0, u = Object.entries(e.queries.query); o < u.length; o++) { - for (var d = u[o], p = d[0], y = [], b = 0, h = d[1]; b < h.length; b++) { - var _ = h[b]; - Gn(t, _.obsSet) ? _.subscribers.forEach(function(x) { - return n.add(x); - }) : r && y.push(_); + function fi(e, t, n, o) { + for (var s = [], a = 0, d = Object.entries(e.queries.query); a < d.length; a++) { + for (var y = d[a], x = y[0], w = [], j = 0, v = y[1]; j < v.length; j++) { + var S = v[j]; + gr(t, S.obsSet) ? S.subscribers.forEach(function(k) { + return n.add(k); + }) : o && w.push(S); } - r && i.push([p, y]); + o && s.push([x, w]); } - if (r) for (var m = 0, v = i; m < v.length; m++) { - var g = v[m], p = g[0], y = g[1]; - e.queries.query[p] = y; + if (o) for (var _ = 0, I = s; _ < I.length; _++) { + var P = I[_], x = P[0], w = P[1]; + e.queries.query[x] = w; } } - function Po(e) { + function Co(e) { var t = e._state, n = e._deps.indexedDB; if (t.isBeingOpened || e.idbdb) return t.dbReadyPromise.then(function() { - return t.dbOpenError ? oe(t.dbOpenError) : e; + return t.dbOpenError ? _e(t.dbOpenError) : e; }); t.isBeingOpened = !0, t.dbOpenError = null, t.openComplete = !1; - var r = t.openCanceller, i = Math.round(10 * e.verno), o = !1; - function u() { - if (t.openCanceller !== r) throw new U.DatabaseClosed("db.open() was cancelled"); - } + var o = t.openCanceller, s = Math.round(10 * e.verno), a = !1; function d() { - return new q(function(_, m) { - if (u(), !n) throw new U.MissingAPI(); - var v = e.name, g = t.autoSchema || !i ? n.open(v) : n.open(v, i); - if (!g) throw new U.MissingAPI(); - g.onerror = Pe(m), g.onblocked = re(e._fireOnBlocked), g.onupgradeneeded = re(function(x) { - var P; - b = g.transaction, t.autoSchema && !e._options.allowEmptyDB ? (g.onerror = St, b.abort(), g.result.close(), (P = n.deleteDatabase(v)).onsuccess = P.onerror = re(function() { - m(new U.NoSuchDatabase("Database ".concat(v, " doesnt exist"))); - })) : (b.onerror = Pe(m), x = x.oldVersion > Math.pow(2, 62) ? 0 : x.oldVersion, h = x < 1, e.idbdb = g.result, o && _o(e, b), xo(e, x / 10, b, m)); - }, m), g.onsuccess = re(function() { - b = null; - var x, P, j, k, S, A = e.idbdb = g.result, D = tt(A.objectStoreNames); - if (0 < D.length) try { - var I = A.transaction((k = D).length === 1 ? k[0] : k, "readonly"); - if (t.autoSchema) P = A, j = I, (x = e).verno = P.version / 10, j = x._dbSchema = rn(0, P, j), x._storeNames = tt(P.objectStoreNames, 0), tn(x, [x._allTables], C(j), j); - else if (on(e, e._dbSchema, I), ((S = Un(rn(0, (S = e).idbdb, I), S._dbSchema)).add.length || S.change.some(function(T) { - return T.add.length || T.change.length; - })) && !o) return console.warn("Dexie SchemaDiff: Schema was extended without increasing the number passed to db.version(). Dexie will add missing parts and increment native version number to workaround this."), A.close(), i = A.version + 1, o = !0, _(d()); - en(e, I); + if (t.openCanceller !== o) throw new X.DatabaseClosed("db.open() was cancelled"); + } + function y() { + return new V(function(S, _) { + if (d(), !n) throw new X.MissingAPI(); + var I = e.name, P = t.autoSchema || !s ? n.open(I) : n.open(I, s); + if (!P) throw new X.MissingAPI(); + P.onerror = We(_), P.onblocked = ge(e._fireOnBlocked), P.onupgradeneeded = ge(function(k) { + var C; + j = P.transaction, t.autoSchema && !e._options.allowEmptyDB ? (P.onerror = Wt, j.abort(), P.result.close(), (C = n.deleteDatabase(I)).onsuccess = C.onerror = ge(function() { + _(new X.NoSuchDatabase("Database ".concat(I, " doesnt exist"))); + })) : (j.onerror = We(_), k = k.oldVersion > Math.pow(2, 62) ? 0 : k.oldVersion, v = k < 1, e.idbdb = P.result, a && ko(e, j), jo(e, k / 10, j, _)); + }, _), P.onsuccess = ge(function() { + j = null; + var k, C, B, M, F, U = e.idbdb = P.result, Y = ye(U.objectStoreNames); + if (0 < Y.length) try { + var q = U.transaction((M = Y).length === 1 ? M[0] : M, "readonly"); + if (t.autoSchema) C = U, B = q, (k = e).verno = C.version / 10, B = k._dbSchema = kn(0, C, B), k._storeNames = ye(C.objectStoreNames, 0), Pn(k, [k._allTables], O(B), B); + else if (Sn(e, e._dbSchema, q), ((F = fr(kn(0, (F = e).idbdb, q), F._dbSchema)).add.length || F.change.some(function($) { + return $.add.length || $.change.length; + })) && !a) return console.warn("Dexie SchemaDiff: Schema was extended without increasing the number passed to db.version(). Dexie will add missing parts and increment native version number to workaround this."), U.close(), s = U.version + 1, a = !0, S(y()); + In(e, q); } catch { } - ut.push(e), A.onversionchange = re(function(T) { - t.vcFired = !0, e.on("versionchange").fire(T); - }), A.onclose = re(function() { + Tt.push(e), U.onversionchange = ge(function($) { + t.vcFired = !0, e.on("versionchange").fire($); + }), U.onclose = ge(function() { e.close({ disableAutoOpen: !1 }); - }), h && (S = e._deps, I = v, A = S.indexedDB, S = S.IDBKeyRange, Vn(A) || I === Wt || Yn(A, S).put({ name: I }).catch(te)), _(); - }, m); - }).catch(function(_) { - switch (_?.name) { + }), v && (F = e._deps, q = I, U = F.indexedDB, F = F.IDBKeyRange, pr(U) || q === vn || dr(U, F).put({ name: q }).catch(he)), S(); + }, _); + }).catch(function(S) { + switch (S?.name) { case "UnknownError": - if (0 < t.PR1398_maxLoop) return t.PR1398_maxLoop--, console.warn("Dexie: Workaround for Chrome UnknownError on open()"), d(); + if (0 < t.PR1398_maxLoop) return t.PR1398_maxLoop--, console.warn("Dexie: Workaround for Chrome UnknownError on open()"), y(); break; case "VersionError": - if (0 < i) return i = 0, d(); + if (0 < s) return s = 0, y(); } - return q.reject(_); + return V.reject(S); }); } - var p, y = t.dbReadyResolve, b = null, h = !1; - return q.race([r, (typeof navigator > "u" ? q.resolve() : !navigator.userAgentData && /Safari\//.test(navigator.userAgent) && !/Chrom(e|ium)\//.test(navigator.userAgent) && indexedDB.databases ? new Promise(function(_) { - function m() { - return indexedDB.databases().finally(_); + var x, w = t.dbReadyResolve, j = null, v = !1; + return V.race([o, (typeof navigator > "u" ? V.resolve() : !navigator.userAgentData && /Safari\//.test(navigator.userAgent) && !/Chrom(e|ium)\//.test(navigator.userAgent) && indexedDB.databases ? new Promise(function(S) { + function _() { + return indexedDB.databases().finally(S); } - p = setInterval(m, 100), m(); + x = setInterval(_, 100), _(); }).finally(function() { - return clearInterval(p); - }) : Promise.resolve()).then(d)]).then(function() { - return u(), t.onReadyBeingFired = [], q.resolve(Wn(function() { + return clearInterval(x); + }) : Promise.resolve()).then(y)]).then(function() { + return d(), t.onReadyBeingFired = [], V.resolve(yr(function() { return e.on.ready.fire(e.vip); - })).then(function _() { + })).then(function S() { if (0 < t.onReadyBeingFired.length) { - var m = t.onReadyBeingFired.reduce(Sn, te); - return t.onReadyBeingFired = [], q.resolve(Wn(function() { - return m(e.vip); - })).then(_); + var _ = t.onReadyBeingFired.reduce(Ct, he); + return t.onReadyBeingFired = [], V.resolve(yr(function() { + return _(e.vip); + })).then(S); } }); }).finally(function() { - t.openCanceller === r && (t.onReadyBeingFired = null, t.isBeingOpened = !1); - }).catch(function(_) { - t.dbOpenError = _; + t.openCanceller === o && (t.onReadyBeingFired = null, t.isBeingOpened = !1); + }).catch(function(S) { + t.dbOpenError = S; try { - b && b.abort(); + j && j.abort(); } catch { } - return r === t.openCanceller && e._close(), oe(_); + return o === t.openCanceller && e._close(), _e(S); }).finally(function() { - t.openComplete = !0, y(); + t.openComplete = !0, w(); }).then(function() { - var _; - return h && (_ = {}, e.tables.forEach(function(m) { - m.schema.indexes.forEach(function(v) { - v.name && (_["idb://".concat(e.name, "/").concat(m.name, "/").concat(v.name)] = new de(-1 / 0, [[[]]])); - }), _["idb://".concat(e.name, "/").concat(m.name, "/")] = _["idb://".concat(e.name, "/").concat(m.name, "/:dels")] = new de(-1 / 0, [[[]]]); - }), Ne(Ct).fire(_), Zn(_, !0)), e; + var S; + return v && (S = {}, e.tables.forEach(function(_) { + _.schema.indexes.forEach(function(I) { + I.name && (S["idb://".concat(e.name, "/").concat(_.name, "/").concat(I.name)] = new Be(-1 / 0, [[[]]])); + }), S["idb://".concat(e.name, "/").concat(_.name, "/")] = S["idb://".concat(e.name, "/").concat(_.name, "/:dels")] = new Be(-1 / 0, [[[]]]); + }), dt(Gt).fire(S), xr(S, !0)), e; }); } - function er(e) { - function t(o) { - return e.next(o); + function wr(e) { + function t(a) { + return e.next(a); } - var n = i(t), r = i(function(o) { - return e.throw(o); + var n = s(t), o = s(function(a) { + return e.throw(a); }); - function i(o) { - return function(p) { - var d = o(p), p = d.value; - return d.done ? p : p && typeof p.then == "function" ? p.then(n, r) : O(p) ? Promise.all(p).then(n, r) : n(p); + function s(a) { + return function(x) { + var y = a(x), x = y.value; + return y.done ? x : x && typeof x.then == "function" ? x.then(n, o) : g(x) ? Promise.all(x).then(n, o) : n(x); }; } - return i(t)(); - } - function cn(e, t, n) { - for (var r = O(e) ? e.slice() : [e], i = 0; i < n; ++i) r.push(t); - return r; - } - var jo = { stack: "dbcore", name: "VirtualIndexMiddleware", level: 1, create: function(e) { - return l(l({}, e), { table: function(t) { - var n = e.table(t), r = n.schema, i = {}, o = []; - function u(h, _, m) { - var v = It(h), g = i[v] = i[v] || [], x = h == null ? 0 : typeof h == "string" ? 1 : h.length, P = 0 < _, P = l(l({}, m), { name: P ? "".concat(v, "(virtual-from:").concat(m.name, ")") : m.name, lowLevelIndex: m, isVirtual: P, keyTail: _, keyLength: x, extractKey: Ln(h), unique: !P && m.unique }); - return g.push(P), P.isPrimaryKey || o.push(P), 1 < x && u(x === 2 ? h[0] : h.slice(0, x - 1), _ + 1, m), g.sort(function(j, k) { - return j.keyTail - k.keyTail; - }), P; + return s(t)(); + } + function On(e, t, n) { + for (var o = g(e) ? e.slice() : [e], s = 0; s < n; ++s) o.push(t); + return o; + } + var Ao = { stack: "dbcore", name: "VirtualIndexMiddleware", level: 1, create: function(e) { + return h(h({}, e), { table: function(t) { + var n = e.table(t), o = n.schema, s = {}, a = []; + function d(v, S, _) { + var I = Qt(v), P = s[I] = s[I] || [], k = v == null ? 0 : typeof v == "string" ? 1 : v.length, C = 0 < S, C = h(h({}, _), { name: C ? "".concat(I, "(virtual-from:").concat(_.name, ")") : _.name, lowLevelIndex: _, isVirtual: C, keyTail: S, keyLength: k, extractKey: cr(v), unique: !C && _.unique }); + return P.push(C), C.isPrimaryKey || a.push(C), 1 < k && d(k === 2 ? v[0] : v.slice(0, k - 1), S + 1, _), P.sort(function(B, M) { + return B.keyTail - M.keyTail; + }), C; } - t = u(r.primaryKey.keyPath, 0, r.primaryKey), i[":id"] = [t]; - for (var d = 0, p = r.indexes; d < p.length; d++) { - var y = p[d]; - u(y.keyPath, 0, y); + t = d(o.primaryKey.keyPath, 0, o.primaryKey), s[":id"] = [t]; + for (var y = 0, x = o.indexes; y < x.length; y++) { + var w = x[y]; + d(w.keyPath, 0, w); } - function b(h) { - var _, m = h.query.index; - return m.isVirtual ? l(l({}, h), { query: { index: m.lowLevelIndex, range: (_ = h.query.range, m = m.keyTail, { type: _.type === 1 ? 2 : _.type, lower: cn(_.lower, _.lowerOpen ? e.MAX_KEY : e.MIN_KEY, m), lowerOpen: !0, upper: cn(_.upper, _.upperOpen ? e.MIN_KEY : e.MAX_KEY, m), upperOpen: !0 }) } }) : h; + function j(v) { + var S, _ = v.query.index; + return _.isVirtual ? h(h({}, v), { query: { index: _.lowLevelIndex, range: (S = v.query.range, _ = _.keyTail, { type: S.type === 1 ? 2 : S.type, lower: On(S.lower, S.lowerOpen ? e.MAX_KEY : e.MIN_KEY, _), lowerOpen: !0, upper: On(S.upper, S.upperOpen ? e.MIN_KEY : e.MAX_KEY, _), upperOpen: !0 }) } }) : v; } - return l(l({}, n), { schema: l(l({}, r), { primaryKey: t, indexes: o, getIndexByKeyPath: function(h) { - return (h = i[It(h)]) && h[0]; - } }), count: function(h) { - return n.count(b(h)); - }, query: function(h) { - return n.query(b(h)); - }, openCursor: function(h) { - var _ = h.query.index, m = _.keyTail, v = _.isVirtual, g = _.keyLength; - return v ? n.openCursor(b(h)).then(function(P) { - return P && x(P); - }) : n.openCursor(h); - function x(P) { - return Object.create(P, { continue: { value: function(j) { - j != null ? P.continue(cn(j, h.reverse ? e.MAX_KEY : e.MIN_KEY, m)) : h.unique ? P.continue(P.key.slice(0, g).concat(h.reverse ? e.MIN_KEY : e.MAX_KEY, m)) : P.continue(); - } }, continuePrimaryKey: { value: function(j, k) { - P.continuePrimaryKey(cn(j, e.MAX_KEY, m), k); + return h(h({}, n), { schema: h(h({}, o), { primaryKey: t, indexes: a, getIndexByKeyPath: function(v) { + return (v = s[Qt(v)]) && v[0]; + } }), count: function(v) { + return n.count(j(v)); + }, query: function(v) { + return n.query(j(v)); + }, openCursor: function(v) { + var S = v.query.index, _ = S.keyTail, I = S.isVirtual, P = S.keyLength; + return I ? n.openCursor(j(v)).then(function(C) { + return C && k(C); + }) : n.openCursor(v); + function k(C) { + return Object.create(C, { continue: { value: function(B) { + B != null ? C.continue(On(B, v.reverse ? e.MAX_KEY : e.MIN_KEY, _)) : v.unique ? C.continue(C.key.slice(0, P).concat(v.reverse ? e.MIN_KEY : e.MAX_KEY, _)) : C.continue(); + } }, continuePrimaryKey: { value: function(B, M) { + C.continuePrimaryKey(On(B, e.MAX_KEY, _), M); } }, primaryKey: { get: function() { - return P.primaryKey; + return C.primaryKey; } }, key: { get: function() { - var j = P.key; - return g === 1 ? j[0] : j.slice(0, g); + var B = C.key; + return P === 1 ? B[0] : B.slice(0, P); } }, value: { get: function() { - return P.value; + return C.value; } } }); } } }); } }); } }; - function tr(e, t, n, r) { - return n = n || {}, r = r || "", C(e).forEach(function(i) { - var o, u, d; - B(t, i) ? (o = e[i], u = t[i], typeof o == "object" && typeof u == "object" && o && u ? (d = wn(o)) !== wn(u) ? n[r + i] = t[i] : d === "Object" ? tr(o, u, n, r + i + ".") : o !== u && (n[r + i] = t[i]) : o !== u && (n[r + i] = t[i])) : n[r + i] = void 0; - }), C(t).forEach(function(i) { - B(e, i) || (n[r + i] = t[i]); + function _r(e, t, n, o) { + return n = n || {}, o = o || "", O(e).forEach(function(s) { + var a, d, y; + N(t, s) ? (a = e[s], d = t[s], typeof a == "object" && typeof d == "object" && a && d ? (y = jt(a)) !== jt(d) ? n[o + s] = t[s] : y === "Object" ? _r(a, d, n, o + s + ".") : a !== d && (n[o + s] = t[s]) : a !== d && (n[o + s] = t[s])) : n[o + s] = void 0; + }), O(t).forEach(function(s) { + N(e, s) || (n[o + s] = t[s]); }), n; } - function nr(e, t) { + function Er(e, t) { return t.type === "delete" ? t.keys : t.keys || t.values.map(e.extractKey); } - var ko = { stack: "dbcore", name: "HooksMiddleware", level: 2, create: function(e) { - return l(l({}, e), { table: function(t) { - var n = e.table(t), r = n.schema.primaryKey; - return l(l({}, n), { mutate: function(i) { - var o = $.trans, u = o.table(t).hook, d = u.deleting, p = u.creating, y = u.updating; - switch (i.type) { + var Bo = { stack: "dbcore", name: "HooksMiddleware", level: 2, create: function(e) { + return h(h({}, e), { table: function(t) { + var n = e.table(t), o = n.schema.primaryKey; + return h(h({}, n), { mutate: function(s) { + var a = L.trans, d = a.table(t).hook, y = d.deleting, x = d.creating, w = d.updating; + switch (s.type) { case "add": - if (p.fire === te) break; - return o._promise("readwrite", function() { - return b(i); + if (x.fire === he) break; + return a._promise("readwrite", function() { + return j(s); }, !0); case "put": - if (p.fire === te && y.fire === te) break; - return o._promise("readwrite", function() { - return b(i); + if (x.fire === he && w.fire === he) break; + return a._promise("readwrite", function() { + return j(s); }, !0); case "delete": - if (d.fire === te) break; - return o._promise("readwrite", function() { - return b(i); + if (y.fire === he) break; + return a._promise("readwrite", function() { + return j(s); }, !0); case "deleteRange": - if (d.fire === te) break; - return o._promise("readwrite", function() { - return (function h(_, m, v) { - return n.query({ trans: _, values: !1, query: { index: r, range: m }, limit: v }).then(function(g) { - var x = g.result; - return b({ type: "delete", keys: x, trans: _ }).then(function(P) { - return 0 < P.numFailures ? Promise.reject(P.failures[0]) : x.length < v ? { failures: [], numFailures: 0, lastResult: void 0 } : h(_, l(l({}, m), { lower: x[x.length - 1], lowerOpen: !0 }), v); + if (y.fire === he) break; + return a._promise("readwrite", function() { + return (function v(S, _, I) { + return n.query({ trans: S, values: !1, query: { index: o, range: _ }, limit: I }).then(function(P) { + var k = P.result; + return j({ type: "delete", keys: k, trans: S }).then(function(C) { + return 0 < C.numFailures ? Promise.reject(C.failures[0]) : k.length < I ? { failures: [], numFailures: 0, lastResult: void 0 } : v(S, h(h({}, _), { lower: k[k.length - 1], lowerOpen: !0 }), I); }); }); - })(i.trans, i.range, 1e4); + })(s.trans, s.range, 1e4); }, !0); } - return n.mutate(i); - function b(h) { - var _, m, v, g = $.trans, x = h.keys || nr(r, h); - if (!x) throw new Error("Keys missing"); - return (h = h.type === "add" || h.type === "put" ? l(l({}, h), { keys: x }) : l({}, h)).type !== "delete" && (h.values = E([], h.values)), h.keys && (h.keys = E([], h.keys)), _ = n, v = x, ((m = h).type === "add" ? Promise.resolve([]) : _.getMany({ trans: m.trans, keys: v, cache: "immutable" })).then(function(P) { - var j = x.map(function(k, S) { - var A, D, I, T = P[S], N = { onerror: null, onsuccess: null }; - return h.type === "delete" ? d.fire.call(N, k, T, g) : h.type === "add" || T === void 0 ? (A = p.fire.call(N, k, h.values[S], g), k == null && A != null && (h.keys[S] = k = A, r.outbound || me(h.values[S], r.keyPath, k))) : (A = tr(T, h.values[S]), (D = y.fire.call(N, A, k, T, g)) && (I = h.values[S], Object.keys(D).forEach(function(R) { - B(I, R) ? I[R] = D[R] : me(I, R, D[R]); - }))), N; + return n.mutate(s); + function j(v) { + var S, _, I, P = L.trans, k = v.keys || Er(o, v); + if (!k) throw new Error("Keys missing"); + return (v = v.type === "add" || v.type === "put" ? h(h({}, v), { keys: k }) : h({}, v)).type !== "delete" && (v.values = T([], v.values)), v.keys && (v.keys = T([], v.keys)), S = n, I = k, ((_ = v).type === "add" ? Promise.resolve([]) : S.getMany({ trans: _.trans, keys: I, cache: "immutable" })).then(function(C) { + var B = k.map(function(M, F) { + var U, Y, q, $ = C[F], z = { onerror: null, onsuccess: null }; + return v.type === "delete" ? y.fire.call(z, M, $, P) : v.type === "add" || $ === void 0 ? (U = x.fire.call(z, M, v.values[F], P), M == null && U != null && (v.keys[F] = M = U, o.outbound || Ce(v.values[F], o.keyPath, M))) : (U = _r($, v.values[F]), (Y = w.fire.call(z, U, M, $, P)) && (q = v.values[F], Object.keys(Y).forEach(function(H) { + N(q, H) ? q[H] = Y[H] : Ce(q, H, Y[H]); + }))), z; }); - return n.mutate(h).then(function(k) { - for (var S = k.failures, A = k.results, D = k.numFailures, k = k.lastResult, I = 0; I < x.length; ++I) { - var T = (A || x)[I], N = j[I]; - T == null ? N.onerror && N.onerror(S[I]) : N.onsuccess && N.onsuccess(h.type === "put" && P[I] ? h.values[I] : T); + return n.mutate(v).then(function(M) { + for (var F = M.failures, U = M.results, Y = M.numFailures, M = M.lastResult, q = 0; q < k.length; ++q) { + var $ = (U || k)[q], z = B[q]; + $ == null ? z.onerror && z.onerror(F[q]) : z.onsuccess && z.onsuccess(v.type === "put" && C[q] ? v.values[q] : $); } - return { failures: S, results: A, numFailures: D, lastResult: k }; - }).catch(function(k) { - return j.forEach(function(S) { - return S.onerror && S.onerror(k); - }), Promise.reject(k); + return { failures: F, results: U, numFailures: Y, lastResult: M }; + }).catch(function(M) { + return B.forEach(function(F) { + return F.onerror && F.onerror(M); + }), Promise.reject(M); }); }); } } }); } }); } }; - function Zr(e, t, n) { + function hi(e, t, n) { try { if (!t || t.keys.length < e.length) return null; - for (var r = [], i = 0, o = 0; i < t.keys.length && o < e.length; ++i) Z(t.keys[i], e[o]) === 0 && (r.push(n ? Fe(t.values[i]) : t.values[i]), ++o); - return r.length === e.length ? r : null; + for (var o = [], s = 0, a = 0; s < t.keys.length && a < e.length; ++s) le(t.keys[s], e[a]) === 0 && (o.push(n ? Qe(t.values[s]) : t.values[s]), ++a); + return o.length === e.length ? o : null; } catch { return null; } } - var So = { stack: "dbcore", level: -1, create: function(e) { + var Oo = { stack: "dbcore", level: -1, create: function(e) { return { table: function(t) { var n = e.table(t); - return l(l({}, n), { getMany: function(r) { - if (!r.cache) return n.getMany(r); - var i = Zr(r.keys, r.trans._cache, r.cache === "clone"); - return i ? q.resolve(i) : n.getMany(r).then(function(o) { - return r.trans._cache = { keys: r.keys, values: r.cache === "clone" ? Fe(o) : o }, o; + return h(h({}, n), { getMany: function(o) { + if (!o.cache) return n.getMany(o); + var s = hi(o.keys, o.trans._cache, o.cache === "clone"); + return s ? V.resolve(s) : n.getMany(o).then(function(a) { + return o.trans._cache = { keys: o.keys, values: o.cache === "clone" ? Qe(a) : a }, a; }); - }, mutate: function(r) { - return r.type !== "add" && (r.trans._cache = null), n.mutate(r); + }, mutate: function(o) { + return o.type !== "add" && (o.trans._cache = null), n.mutate(o); } }); } }; } }; - function ei(e, t) { + function di(e, t) { return e.trans.mode === "readonly" && !!e.subscr && !e.trans.explicit && e.trans.db._options.cache !== "disabled" && !t.schema.primaryKey.outbound; } - function ti(e, t) { + function pi(e, t) { switch (e) { case "query": return t.values && !t.unique; @@ -2492,710 +2492,710 @@ function Cs() { return !1; } } - var Co = { stack: "dbcore", level: 0, name: "Observability", create: function(e) { - var t = e.schema.name, n = new de(e.MIN_KEY, e.MAX_KEY); - return l(l({}, e), { transaction: function(r, i, o) { - if ($.subscr && i !== "readonly") throw new U.ReadOnly("Readwrite transaction in liveQuery context. Querier source: ".concat($.querier)); - return e.transaction(r, i, o); - }, table: function(r) { - var i = e.table(r), o = i.schema, u = o.primaryKey, h = o.indexes, d = u.extractKey, p = u.outbound, y = u.autoIncrement && h.filter(function(m) { - return m.compound && m.keyPath.includes(u.keyPath); - }), b = l(l({}, i), { mutate: function(m) { - function v(R) { - return R = "idb://".concat(t, "/").concat(r, "/").concat(R), k[R] || (k[R] = new de()); + var To = { stack: "dbcore", level: 0, name: "Observability", create: function(e) { + var t = e.schema.name, n = new Be(e.MIN_KEY, e.MAX_KEY); + return h(h({}, e), { transaction: function(o, s, a) { + if (L.subscr && s !== "readonly") throw new X.ReadOnly("Readwrite transaction in liveQuery context. Querier source: ".concat(L.querier)); + return e.transaction(o, s, a); + }, table: function(o) { + var s = e.table(o), a = s.schema, d = a.primaryKey, v = a.indexes, y = d.extractKey, x = d.outbound, w = d.autoIncrement && v.filter(function(_) { + return _.compound && _.keyPath.includes(d.keyPath); + }), j = h(h({}, s), { mutate: function(_) { + function I(H) { + return H = "idb://".concat(t, "/").concat(o, "/").concat(H), M[H] || (M[H] = new Be()); } - var g, x, P, j = m.trans, k = m.mutatedParts || (m.mutatedParts = {}), S = v(""), A = v(":dels"), D = m.type, N = m.type === "deleteRange" ? [m.range] : m.type === "delete" ? [m.keys] : m.values.length < 50 ? [nr(u, m).filter(function(R) { - return R; - }), m.values] : [], I = N[0], T = N[1], N = m.trans._cache; - return O(I) ? (S.addKeys(I), (N = D === "delete" || I.length === T.length ? Zr(I, N) : null) || A.addKeys(I), (N || T) && (g = v, x = N, P = T, o.indexes.forEach(function(R) { - var F = g(R.name || ""); - function G(X) { - return X != null ? R.extractKey(X) : null; + var P, k, C, B = _.trans, M = _.mutatedParts || (_.mutatedParts = {}), F = I(""), U = I(":dels"), Y = _.type, z = _.type === "deleteRange" ? [_.range] : _.type === "delete" ? [_.keys] : _.values.length < 50 ? [Er(d, _).filter(function(H) { + return H; + }), _.values] : [], q = z[0], $ = z[1], z = _.trans._cache; + return g(q) ? (F.addKeys(q), (z = Y === "delete" || q.length === $.length ? hi(q, z) : null) || U.addKeys(q), (z || $) && (P = I, k = z, C = $, a.indexes.forEach(function(H) { + var W = P(H.name || ""); + function ie(ae) { + return ae != null ? H.extractKey(ae) : null; } - function J(X) { - return R.multiEntry && O(X) ? X.forEach(function(ge) { - return F.addKey(ge); - }) : F.addKey(X); + function se(ae) { + return H.multiEntry && g(ae) ? ae.forEach(function(Ue) { + return W.addKey(Ue); + }) : W.addKey(ae); } - (x || P).forEach(function(X, fe) { - var W = x && G(x[fe]), fe = P && G(P[fe]); - Z(W, fe) !== 0 && (W != null && J(W), fe != null && J(fe)); + (k || C).forEach(function(ae, Oe) { + var ne = k && ie(k[Oe]), Oe = C && ie(C[Oe]); + le(ne, Oe) !== 0 && (ne != null && se(ne), Oe != null && se(Oe)); }); - }))) : I ? (T = { from: (T = I.lower) !== null && T !== void 0 ? T : e.MIN_KEY, to: (T = I.upper) !== null && T !== void 0 ? T : e.MAX_KEY }, A.add(T), S.add(T)) : (S.add(n), A.add(n), o.indexes.forEach(function(R) { - return v(R.name).add(n); - })), i.mutate(m).then(function(R) { - return !I || m.type !== "add" && m.type !== "put" || (S.addKeys(R.results), y && y.forEach(function(F) { - for (var G = m.values.map(function(W) { - return F.extractKey(W); - }), J = F.keyPath.findIndex(function(W) { - return W === u.keyPath; - }), X = 0, ge = R.results.length; X < ge; ++X) G[X][J] = R.results[X]; - v(F.name).addKeys(G); - })), j.mutatedParts = an(j.mutatedParts || {}, k), R; + }))) : q ? ($ = { from: ($ = q.lower) !== null && $ !== void 0 ? $ : e.MIN_KEY, to: ($ = q.upper) !== null && $ !== void 0 ? $ : e.MAX_KEY }, U.add($), F.add($)) : (F.add(n), U.add(n), a.indexes.forEach(function(H) { + return I(H.name).add(n); + })), s.mutate(_).then(function(H) { + return !q || _.type !== "add" && _.type !== "put" || (F.addKeys(H.results), w && w.forEach(function(W) { + for (var ie = _.values.map(function(ne) { + return W.extractKey(ne); + }), se = W.keyPath.findIndex(function(ne) { + return ne === d.keyPath; + }), ae = 0, Ue = H.results.length; ae < Ue; ++ae) ie[ae][se] = H.results[ae]; + I(W.name).addKeys(ie); + })), B.mutatedParts = An(B.mutatedParts || {}, M), H; }); - } }), h = function(v) { - var g = v.query, v = g.index, g = g.range; - return [v, new de((v = g.lower) !== null && v !== void 0 ? v : e.MIN_KEY, (g = g.upper) !== null && g !== void 0 ? g : e.MAX_KEY)]; - }, _ = { get: function(m) { - return [u, new de(m.key)]; - }, getMany: function(m) { - return [u, new de().addKeys(m.keys)]; - }, count: h, query: h, openCursor: h }; - return C(_).forEach(function(m) { - b[m] = function(v) { - var g = $.subscr, x = !!g, P = ei($, i) && ti(m, v) ? v.obsSet = {} : g; - if (x) { - var j = function(T) { - return T = "idb://".concat(t, "/").concat(r, "/").concat(T), P[T] || (P[T] = new de()); - }, k = j(""), S = j(":dels"), g = _[m](v), x = g[0], g = g[1]; - if ((m === "query" && x.isPrimaryKey && !v.values ? S : j(x.name || "")).add(g), !x.isPrimaryKey) { - if (m !== "count") { - var A = m === "query" && p && v.values && i.query(l(l({}, v), { values: !1 })); - return i[m].apply(this, arguments).then(function(T) { - if (m === "query") { - if (p && v.values) return A.then(function(G) { - return G = G.result, k.addKeys(G), T; + } }), v = function(I) { + var P = I.query, I = P.index, P = P.range; + return [I, new Be((I = P.lower) !== null && I !== void 0 ? I : e.MIN_KEY, (P = P.upper) !== null && P !== void 0 ? P : e.MAX_KEY)]; + }, S = { get: function(_) { + return [d, new Be(_.key)]; + }, getMany: function(_) { + return [d, new Be().addKeys(_.keys)]; + }, count: v, query: v, openCursor: v }; + return O(S).forEach(function(_) { + j[_] = function(I) { + var P = L.subscr, k = !!P, C = di(L, s) && pi(_, I) ? I.obsSet = {} : P; + if (k) { + var B = function($) { + return $ = "idb://".concat(t, "/").concat(o, "/").concat($), C[$] || (C[$] = new Be()); + }, M = B(""), F = B(":dels"), P = S[_](I), k = P[0], P = P[1]; + if ((_ === "query" && k.isPrimaryKey && !I.values ? F : B(k.name || "")).add(P), !k.isPrimaryKey) { + if (_ !== "count") { + var U = _ === "query" && x && I.values && s.query(h(h({}, I), { values: !1 })); + return s[_].apply(this, arguments).then(function($) { + if (_ === "query") { + if (x && I.values) return U.then(function(ie) { + return ie = ie.result, M.addKeys(ie), $; }); - var N = v.values ? T.result.map(d) : T.result; - (v.values ? k : S).addKeys(N); - } else if (m === "openCursor") { - var R = T, F = v.values; - return R && Object.create(R, { key: { get: function() { - return S.addKey(R.primaryKey), R.key; + var z = I.values ? $.result.map(y) : $.result; + (I.values ? M : F).addKeys(z); + } else if (_ === "openCursor") { + var H = $, W = I.values; + return H && Object.create(H, { key: { get: function() { + return F.addKey(H.primaryKey), H.key; } }, primaryKey: { get: function() { - var G = R.primaryKey; - return S.addKey(G), G; + var ie = H.primaryKey; + return F.addKey(ie), ie; } }, value: { get: function() { - return F && k.addKey(R.primaryKey), R.value; + return W && M.addKey(H.primaryKey), H.value; } } }); } - return T; + return $; }); } - S.add(n); + F.add(n); } } - return i[m].apply(this, arguments); + return s[_].apply(this, arguments); }; - }), b; + }), j; } }); } }; - function ni(e, t, n) { + function yi(e, t, n) { if (n.numFailures === 0) return t; if (t.type === "deleteRange") return null; - var r = t.keys ? t.keys.length : "values" in t && t.values ? t.values.length : 1; - return n.numFailures === r ? null : (t = l({}, t), O(t.keys) && (t.keys = t.keys.filter(function(i, o) { - return !(o in n.failures); - })), "values" in t && O(t.values) && (t.values = t.values.filter(function(i, o) { - return !(o in n.failures); + var o = t.keys ? t.keys.length : "values" in t && t.values ? t.values.length : 1; + return n.numFailures === o ? null : (t = h({}, t), g(t.keys) && (t.keys = t.keys.filter(function(s, a) { + return !(a in n.failures); + })), "values" in t && g(t.values) && (t.values = t.values.filter(function(s, a) { + return !(a in n.failures); })), t); } - function rr(e, t) { - return n = e, ((r = t).lower === void 0 || (r.lowerOpen ? 0 < Z(n, r.lower) : 0 <= Z(n, r.lower))) && (e = e, (t = t).upper === void 0 || (t.upperOpen ? Z(e, t.upper) < 0 : Z(e, t.upper) <= 0)); - var n, r; - } - function ri(e, t, _, r, i, o) { - if (!_ || _.length === 0) return e; - var u = t.query.index, d = u.multiEntry, p = t.query.range, y = r.schema.primaryKey.extractKey, b = u.extractKey, h = (u.lowLevelIndex || u).extractKey, _ = _.reduce(function(m, v) { - var g = m, x = []; - if (v.type === "add" || v.type === "put") for (var P = new de(), j = v.values.length - 1; 0 <= j; --j) { - var k, S = v.values[j], A = y(S); - P.hasKey(A) || (k = b(S), (d && O(k) ? k.some(function(R) { - return rr(R, p); - }) : rr(k, p)) && (P.addKey(A), x.push(S))); + function Ir(e, t) { + return n = e, ((o = t).lower === void 0 || (o.lowerOpen ? 0 < le(n, o.lower) : 0 <= le(n, o.lower))) && (e = e, (t = t).upper === void 0 || (t.upperOpen ? le(e, t.upper) < 0 : le(e, t.upper) <= 0)); + var n, o; + } + function mi(e, t, S, o, s, a) { + if (!S || S.length === 0) return e; + var d = t.query.index, y = d.multiEntry, x = t.query.range, w = o.schema.primaryKey.extractKey, j = d.extractKey, v = (d.lowLevelIndex || d).extractKey, S = S.reduce(function(_, I) { + var P = _, k = []; + if (I.type === "add" || I.type === "put") for (var C = new Be(), B = I.values.length - 1; 0 <= B; --B) { + var M, F = I.values[B], U = w(F); + C.hasKey(U) || (M = j(F), (y && g(M) ? M.some(function(H) { + return Ir(H, x); + }) : Ir(M, x)) && (C.addKey(U), k.push(F))); } - switch (v.type) { + switch (I.type) { case "add": - var D = new de().addKeys(t.values ? m.map(function(F) { - return y(F); - }) : m), g = m.concat(t.values ? x.filter(function(F) { - return F = y(F), !D.hasKey(F) && (D.addKey(F), !0); - }) : x.map(function(F) { - return y(F); - }).filter(function(F) { - return !D.hasKey(F) && (D.addKey(F), !0); + var Y = new Be().addKeys(t.values ? _.map(function(W) { + return w(W); + }) : _), P = _.concat(t.values ? k.filter(function(W) { + return W = w(W), !Y.hasKey(W) && (Y.addKey(W), !0); + }) : k.map(function(W) { + return w(W); + }).filter(function(W) { + return !Y.hasKey(W) && (Y.addKey(W), !0); })); break; case "put": - var I = new de().addKeys(v.values.map(function(F) { - return y(F); + var q = new Be().addKeys(I.values.map(function(W) { + return w(W); })); - g = m.filter(function(F) { - return !I.hasKey(t.values ? y(F) : F); - }).concat(t.values ? x : x.map(function(F) { - return y(F); + P = _.filter(function(W) { + return !q.hasKey(t.values ? w(W) : W); + }).concat(t.values ? k : k.map(function(W) { + return w(W); })); break; case "delete": - var T = new de().addKeys(v.keys); - g = m.filter(function(F) { - return !T.hasKey(t.values ? y(F) : F); + var $ = new Be().addKeys(I.keys); + P = _.filter(function(W) { + return !$.hasKey(t.values ? w(W) : W); }); break; case "deleteRange": - var N = v.range; - g = m.filter(function(F) { - return !rr(y(F), N); + var z = I.range; + P = _.filter(function(W) { + return !Ir(w(W), z); }); } - return g; + return P; }, e); - return _ === e ? e : (_.sort(function(m, v) { - return Z(h(m), h(v)) || Z(y(m), y(v)); - }), t.limit && t.limit < 1 / 0 && (_.length > t.limit ? _.length = t.limit : e.length === t.limit && _.length < t.limit && (i.dirty = !0)), o ? Object.freeze(_) : _); - } - function ii(e, t) { - return Z(e.lower, t.lower) === 0 && Z(e.upper, t.upper) === 0 && !!e.lowerOpen == !!t.lowerOpen && !!e.upperOpen == !!t.upperOpen; - } - function Eo(e, t) { - return (function(n, r, i, o) { - if (n === void 0) return r !== void 0 ? -1 : 0; - if (r === void 0) return 1; - if ((r = Z(n, r)) === 0) { - if (i && o) return 0; - if (i) return 1; - if (o) return -1; + return S === e ? e : (S.sort(function(_, I) { + return le(v(_), v(I)) || le(w(_), w(I)); + }), t.limit && t.limit < 1 / 0 && (S.length > t.limit ? S.length = t.limit : e.length === t.limit && S.length < t.limit && (s.dirty = !0)), a ? Object.freeze(S) : S); + } + function gi(e, t) { + return le(e.lower, t.lower) === 0 && le(e.upper, t.upper) === 0 && !!e.lowerOpen == !!t.lowerOpen && !!e.upperOpen == !!t.upperOpen; + } + function Mo(e, t) { + return (function(n, o, s, a) { + if (n === void 0) return o !== void 0 ? -1 : 0; + if (o === void 0) return 1; + if ((o = le(n, o)) === 0) { + if (s && a) return 0; + if (s) return 1; + if (a) return -1; } - return r; - })(e.lower, t.lower, e.lowerOpen, t.lowerOpen) <= 0 && 0 <= (function(n, r, i, o) { - if (n === void 0) return r !== void 0 ? 1 : 0; - if (r === void 0) return -1; - if ((r = Z(n, r)) === 0) { - if (i && o) return 0; - if (i) return -1; - if (o) return 1; + return o; + })(e.lower, t.lower, e.lowerOpen, t.lowerOpen) <= 0 && 0 <= (function(n, o, s, a) { + if (n === void 0) return o !== void 0 ? 1 : 0; + if (o === void 0) return -1; + if ((o = le(n, o)) === 0) { + if (s && a) return 0; + if (s) return -1; + if (a) return 1; } - return r; + return o; })(e.upper, t.upper, e.upperOpen, t.upperOpen); } - function Io(e, t, n, r) { - e.subscribers.add(n), r.addEventListener("abort", function() { - var i, o; - e.subscribers.delete(n), e.subscribers.size === 0 && (i = e, o = t, setTimeout(function() { - i.subscribers.size === 0 && $e(o, i); + function Ro(e, t, n, o) { + e.subscribers.add(n), o.addEventListener("abort", function() { + var s, a; + e.subscribers.delete(n), e.subscribers.size === 0 && (s = e, a = t, setTimeout(function() { + s.subscribers.size === 0 && Xe(a, s); }, 3e3)); }); } - var Oo = { stack: "dbcore", level: 0, name: "Cache", create: function(e) { + var Fo = { stack: "dbcore", level: 0, name: "Cache", create: function(e) { var t = e.schema.name; - return l(l({}, e), { transaction: function(n, r, i) { - var o, u, d = e.transaction(n, r, i); - return r === "readwrite" && (u = (o = new AbortController()).signal, i = function(p) { + return h(h({}, e), { transaction: function(n, o, s) { + var a, d, y = e.transaction(n, o, s); + return o === "readwrite" && (d = (a = new AbortController()).signal, s = function(x) { return function() { - if (o.abort(), r === "readwrite") { - for (var y = /* @__PURE__ */ new Set(), b = 0, h = n; b < h.length; b++) { - var _ = h[b], m = Ge["idb://".concat(t, "/").concat(_)]; - if (m) { - var v = e.table(_), g = m.optimisticOps.filter(function(F) { - return F.trans === d; + if (a.abort(), o === "readwrite") { + for (var w = /* @__PURE__ */ new Set(), j = 0, v = n; j < v.length; j++) { + var S = v[j], _ = _t["idb://".concat(t, "/").concat(S)]; + if (_) { + var I = e.table(S), P = _.optimisticOps.filter(function(W) { + return W.trans === y; }); - if (d._explicit && p && d.mutatedParts) for (var x = 0, P = Object.values(m.queries.query); x < P.length; x++) for (var j = 0, k = (D = P[x]).slice(); j < k.length; j++) Gn((I = k[j]).obsSet, d.mutatedParts) && ($e(D, I), I.subscribers.forEach(function(F) { - return y.add(F); + if (y._explicit && x && y.mutatedParts) for (var k = 0, C = Object.values(_.queries.query); k < C.length; k++) for (var B = 0, M = (Y = C[k]).slice(); B < M.length; B++) gr((q = M[B]).obsSet, y.mutatedParts) && (Xe(Y, q), q.subscribers.forEach(function(W) { + return w.add(W); })); - else if (0 < g.length) { - m.optimisticOps = m.optimisticOps.filter(function(F) { - return F.trans !== d; + else if (0 < P.length) { + _.optimisticOps = _.optimisticOps.filter(function(W) { + return W.trans !== y; }); - for (var S = 0, A = Object.values(m.queries.query); S < A.length; S++) for (var D, I, T, N = 0, R = (D = A[S]).slice(); N < R.length; N++) (I = R[N]).res != null && d.mutatedParts && (p && !I.dirty ? (T = Object.isFrozen(I.res), T = ri(I.res, I.req, g, v, I, T), I.dirty ? ($e(D, I), I.subscribers.forEach(function(F) { - return y.add(F); - })) : T !== I.res && (I.res = T, I.promise = q.resolve({ result: T }))) : (I.dirty && $e(D, I), I.subscribers.forEach(function(F) { - return y.add(F); + for (var F = 0, U = Object.values(_.queries.query); F < U.length; F++) for (var Y, q, $, z = 0, H = (Y = U[F]).slice(); z < H.length; z++) (q = H[z]).res != null && y.mutatedParts && (x && !q.dirty ? ($ = Object.isFrozen(q.res), $ = mi(q.res, q.req, P, I, q, $), q.dirty ? (Xe(Y, q), q.subscribers.forEach(function(W) { + return w.add(W); + })) : $ !== q.res && (q.res = $, q.promise = V.resolve({ result: $ }))) : (q.dirty && Xe(Y, q), q.subscribers.forEach(function(W) { + return w.add(W); }))); } } } - y.forEach(function(F) { - return F(); + w.forEach(function(W) { + return W(); }); } }; - }, d.addEventListener("abort", i(!1), { signal: u }), d.addEventListener("error", i(!1), { signal: u }), d.addEventListener("complete", i(!0), { signal: u })), d; + }, y.addEventListener("abort", s(!1), { signal: d }), y.addEventListener("error", s(!1), { signal: d }), y.addEventListener("complete", s(!0), { signal: d })), y; }, table: function(n) { - var r = e.table(n), i = r.schema.primaryKey; - return l(l({}, r), { mutate: function(o) { - var u = $.trans; - if (i.outbound || u.db._options.cache === "disabled" || u.explicit || u.idbtrans.mode !== "readwrite") return r.mutate(o); - var d = Ge["idb://".concat(t, "/").concat(n)]; - return d ? (u = r.mutate(o), o.type !== "add" && o.type !== "put" || !(50 <= o.values.length || nr(i, o).some(function(p) { - return p == null; - })) ? (d.optimisticOps.push(o), o.mutatedParts && un(o.mutatedParts), u.then(function(p) { - 0 < p.numFailures && ($e(d.optimisticOps, o), (p = ni(0, o, p)) && d.optimisticOps.push(p), o.mutatedParts && un(o.mutatedParts)); - }), u.catch(function() { - $e(d.optimisticOps, o), o.mutatedParts && un(o.mutatedParts); - })) : u.then(function(p) { - var y = ni(0, l(l({}, o), { values: o.values.map(function(b, h) { - var _; - return p.failures[h] ? b : (b = (_ = i.keyPath) !== null && _ !== void 0 && _.includes(".") ? Fe(b) : l({}, b), me(b, i.keyPath, p.results[h]), b); - }) }), p); - d.optimisticOps.push(y), queueMicrotask(function() { - return o.mutatedParts && un(o.mutatedParts); + var o = e.table(n), s = o.schema.primaryKey; + return h(h({}, o), { mutate: function(a) { + var d = L.trans; + if (s.outbound || d.db._options.cache === "disabled" || d.explicit || d.idbtrans.mode !== "readwrite") return o.mutate(a); + var y = _t["idb://".concat(t, "/").concat(n)]; + return y ? (d = o.mutate(a), a.type !== "add" && a.type !== "put" || !(50 <= a.values.length || Er(s, a).some(function(x) { + return x == null; + })) ? (y.optimisticOps.push(a), a.mutatedParts && Bn(a.mutatedParts), d.then(function(x) { + 0 < x.numFailures && (Xe(y.optimisticOps, a), (x = yi(0, a, x)) && y.optimisticOps.push(x), a.mutatedParts && Bn(a.mutatedParts)); + }), d.catch(function() { + Xe(y.optimisticOps, a), a.mutatedParts && Bn(a.mutatedParts); + })) : d.then(function(x) { + var w = yi(0, h(h({}, a), { values: a.values.map(function(j, v) { + var S; + return x.failures[v] ? j : (j = (S = s.keyPath) !== null && S !== void 0 && S.includes(".") ? Qe(j) : h({}, j), Ce(j, s.keyPath, x.results[v]), j); + }) }), x); + y.optimisticOps.push(w), queueMicrotask(function() { + return a.mutatedParts && Bn(a.mutatedParts); }); - }), u) : r.mutate(o); - }, query: function(o) { - if (!ei($, r) || !ti("query", o)) return r.query(o); - var u = ((y = $.trans) === null || y === void 0 ? void 0 : y.db._options.cache) === "immutable", h = $, d = h.requery, p = h.signal, y = (function(v, g, x, P) { - var j = Ge["idb://".concat(v, "/").concat(g)]; - if (!j) return []; - if (!(g = j.queries[x])) return [null, !1, j, null]; - var k = g[(P.query ? P.query.index.name : null) || ""]; - if (!k) return [null, !1, j, null]; - switch (x) { + }), d) : o.mutate(a); + }, query: function(a) { + if (!di(L, o) || !pi("query", a)) return o.query(a); + var d = ((w = L.trans) === null || w === void 0 ? void 0 : w.db._options.cache) === "immutable", v = L, y = v.requery, x = v.signal, w = (function(I, P, k, C) { + var B = _t["idb://".concat(I, "/").concat(P)]; + if (!B) return []; + if (!(P = B.queries[k])) return [null, !1, B, null]; + var M = P[(C.query ? C.query.index.name : null) || ""]; + if (!M) return [null, !1, B, null]; + switch (k) { case "query": - var S = k.find(function(A) { - return A.req.limit === P.limit && A.req.values === P.values && ii(A.req.query.range, P.query.range); + var F = M.find(function(U) { + return U.req.limit === C.limit && U.req.values === C.values && gi(U.req.query.range, C.query.range); }); - return S ? [S, !0, j, k] : [k.find(function(A) { - return ("limit" in A.req ? A.req.limit : 1 / 0) >= P.limit && (!P.values || A.req.values) && Eo(A.req.query.range, P.query.range); - }), !1, j, k]; + return F ? [F, !0, B, M] : [M.find(function(U) { + return ("limit" in U.req ? U.req.limit : 1 / 0) >= C.limit && (!C.values || U.req.values) && Mo(U.req.query.range, C.query.range); + }), !1, B, M]; case "count": - return S = k.find(function(A) { - return ii(A.req.query.range, P.query.range); - }), [S, !!S, j, k]; + return F = M.find(function(U) { + return gi(U.req.query.range, C.query.range); + }), [F, !!F, B, M]; } - })(t, n, "query", o), b = y[0], h = y[1], _ = y[2], m = y[3]; - return b && h ? b.obsSet = o.obsSet : (h = r.query(o).then(function(v) { - var g = v.result; - if (b && (b.res = g), u) { - for (var x = 0, P = g.length; x < P; ++x) Object.freeze(g[x]); - Object.freeze(g); - } else v.result = Fe(g); - return v; - }).catch(function(v) { - return m && b && $e(m, b), Promise.reject(v); - }), b = { obsSet: o.obsSet, promise: h, subscribers: /* @__PURE__ */ new Set(), type: "query", req: o, dirty: !1 }, m ? m.push(b) : (m = [b], (_ = _ || (Ge["idb://".concat(t, "/").concat(n)] = { queries: { query: {}, count: {} }, objs: /* @__PURE__ */ new Map(), optimisticOps: [], unsignaledParts: {} })).queries.query[o.query.index.name || ""] = m)), Io(b, m, d, p), b.promise.then(function(v) { - return { result: ri(v.result, o, _?.optimisticOps, r, b, u) }; + })(t, n, "query", a), j = w[0], v = w[1], S = w[2], _ = w[3]; + return j && v ? j.obsSet = a.obsSet : (v = o.query(a).then(function(I) { + var P = I.result; + if (j && (j.res = P), d) { + for (var k = 0, C = P.length; k < C; ++k) Object.freeze(P[k]); + Object.freeze(P); + } else I.result = Qe(P); + return I; + }).catch(function(I) { + return _ && j && Xe(_, j), Promise.reject(I); + }), j = { obsSet: a.obsSet, promise: v, subscribers: /* @__PURE__ */ new Set(), type: "query", req: a, dirty: !1 }, _ ? _.push(j) : (_ = [j], (S = S || (_t["idb://".concat(t, "/").concat(n)] = { queries: { query: {}, count: {} }, objs: /* @__PURE__ */ new Map(), optimisticOps: [], unsignaledParts: {} })).queries.query[a.query.index.name || ""] = _)), Ro(j, _, y, x), j.promise.then(function(I) { + return { result: mi(I.result, a, S?.optimisticOps, o, j, d) }; }); } }); } }); } }; - function ln(e, t) { - return new Proxy(e, { get: function(n, r, i) { - return r === "db" ? t : Reflect.get(n, r, i); + function Tn(e, t) { + return new Proxy(e, { get: function(n, o, s) { + return o === "db" ? t : Reflect.get(n, o, s); } }); } - var Oe = (se.prototype.version = function(e) { - if (isNaN(e) || e < 0.1) throw new U.Type("Given version is not a positive number"); - if (e = Math.round(10 * e) / 10, this.idbdb || this._state.isBeingOpened) throw new U.Schema("Cannot add version when database is open"); + var ot = (Ee.prototype.version = function(e) { + if (isNaN(e) || e < 0.1) throw new X.Type("Given version is not a positive number"); + if (e = Math.round(10 * e) / 10, this.idbdb || this._state.isBeingOpened) throw new X.Schema("Cannot add version when database is open"); this.verno = Math.max(this.verno, e); - var t = this._versions, n = t.filter(function(r) { - return r._cfg.version === e; + var t = this._versions, n = t.filter(function(o) { + return o._cfg.version === e; })[0]; - return n || (n = new this.Version(e), t.push(n), t.sort(bo), n.stores({}), this._state.autoSchema = !1, n); - }, se.prototype._whenReady = function(e) { + return n || (n = new this.Version(e), t.push(n), t.sort(Po), n.stores({}), this._state.autoSchema = !1, n); + }, Ee.prototype._whenReady = function(e) { var t = this; - return this.idbdb && (this._state.openComplete || $.letThrough || this._vip) ? e() : new q(function(n, r) { - if (t._state.openComplete) return r(new U.DatabaseClosed(t._state.dbOpenError)); + return this.idbdb && (this._state.openComplete || L.letThrough || this._vip) ? e() : new V(function(n, o) { + if (t._state.openComplete) return o(new X.DatabaseClosed(t._state.dbOpenError)); if (!t._state.isBeingOpened) { - if (!t._state.autoOpen) return void r(new U.DatabaseClosed()); - t.open().catch(te); + if (!t._state.autoOpen) return void o(new X.DatabaseClosed()); + t.open().catch(he); } - t._state.dbReadyPromise.then(n, r); + t._state.dbReadyPromise.then(n, o); }).then(e); - }, se.prototype.use = function(e) { - var t = e.stack, n = e.create, r = e.level, i = e.name; - return i && this.unuse({ stack: t, name: i }), e = this._middlewares[t] || (this._middlewares[t] = []), e.push({ stack: t, create: n, level: r ?? 10, name: i }), e.sort(function(o, u) { - return o.level - u.level; + }, Ee.prototype.use = function(e) { + var t = e.stack, n = e.create, o = e.level, s = e.name; + return s && this.unuse({ stack: t, name: s }), e = this._middlewares[t] || (this._middlewares[t] = []), e.push({ stack: t, create: n, level: o ?? 10, name: s }), e.sort(function(a, d) { + return a.level - d.level; }), this; - }, se.prototype.unuse = function(e) { - var t = e.stack, n = e.name, r = e.create; - return t && this._middlewares[t] && (this._middlewares[t] = this._middlewares[t].filter(function(i) { - return r ? i.create !== r : !!n && i.name !== n; + }, Ee.prototype.unuse = function(e) { + var t = e.stack, n = e.name, o = e.create; + return t && this._middlewares[t] && (this._middlewares[t] = this._middlewares[t].filter(function(s) { + return o ? s.create !== o : !!n && s.name !== n; })), this; - }, se.prototype.open = function() { + }, Ee.prototype.open = function() { var e = this; - return Ve(Me, function() { - return Po(e); + return bt(de, function() { + return Co(e); }); - }, se.prototype._close = function() { + }, Ee.prototype._close = function() { this.on.close.fire(new CustomEvent("close")); - var e = this._state, t = ut.indexOf(this); - if (0 <= t && ut.splice(t, 1), this.idbdb) { + var e = this._state, t = Tt.indexOf(this); + if (0 <= t && Tt.splice(t, 1), this.idbdb) { try { this.idbdb.close(); } catch { } this.idbdb = null; } - e.isBeingOpened || (e.dbReadyPromise = new q(function(n) { + e.isBeingOpened || (e.dbReadyPromise = new V(function(n) { e.dbReadyResolve = n; - }), e.openCanceller = new q(function(n, r) { - e.cancelOpen = r; + }), e.openCanceller = new V(function(n, o) { + e.cancelOpen = o; })); - }, se.prototype.close = function(n) { + }, Ee.prototype.close = function(n) { var t = (n === void 0 ? { disableAutoOpen: !0 } : n).disableAutoOpen, n = this._state; - t ? (n.isBeingOpened && n.cancelOpen(new U.DatabaseClosed()), this._close(), n.autoOpen = !1, n.dbOpenError = new U.DatabaseClosed()) : (this._close(), n.autoOpen = this._options.autoOpen || n.isBeingOpened, n.openComplete = !1, n.dbOpenError = null); - }, se.prototype.delete = function(e) { + t ? (n.isBeingOpened && n.cancelOpen(new X.DatabaseClosed()), this._close(), n.autoOpen = !1, n.dbOpenError = new X.DatabaseClosed()) : (this._close(), n.autoOpen = this._options.autoOpen || n.isBeingOpened, n.openComplete = !1, n.dbOpenError = null); + }, Ee.prototype.delete = function(e) { var t = this; e === void 0 && (e = { disableAutoOpen: !0 }); - var n = 0 < arguments.length && typeof arguments[0] != "object", r = this._state; - return new q(function(i, o) { - function u() { + var n = 0 < arguments.length && typeof arguments[0] != "object", o = this._state; + return new V(function(s, a) { + function d() { t.close(e); - var d = t._deps.indexedDB.deleteDatabase(t.name); - d.onsuccess = re(function() { - var p, y, b; - p = t._deps, y = t.name, b = p.indexedDB, p = p.IDBKeyRange, Vn(b) || y === Wt || Yn(b, p).delete(y).catch(te), i(); - }), d.onerror = Pe(o), d.onblocked = t._fireOnBlocked; + var y = t._deps.indexedDB.deleteDatabase(t.name); + y.onsuccess = ge(function() { + var x, w, j; + x = t._deps, w = t.name, j = x.indexedDB, x = x.IDBKeyRange, pr(j) || w === vn || dr(j, x).delete(w).catch(he), s(); + }), y.onerror = We(a), y.onblocked = t._fireOnBlocked; } - if (n) throw new U.InvalidArgument("Invalid closeOptions argument to db.delete()"); - r.isBeingOpened ? r.dbReadyPromise.then(u) : u(); + if (n) throw new X.InvalidArgument("Invalid closeOptions argument to db.delete()"); + o.isBeingOpened ? o.dbReadyPromise.then(d) : d(); }); - }, se.prototype.backendDB = function() { + }, Ee.prototype.backendDB = function() { return this.idbdb; - }, se.prototype.isOpen = function() { + }, Ee.prototype.isOpen = function() { return this.idbdb !== null; - }, se.prototype.hasBeenClosed = function() { + }, Ee.prototype.hasBeenClosed = function() { var e = this._state.dbOpenError; return e && e.name === "DatabaseClosed"; - }, se.prototype.hasFailed = function() { + }, Ee.prototype.hasFailed = function() { return this._state.dbOpenError !== null; - }, se.prototype.dynamicallyOpened = function() { + }, Ee.prototype.dynamicallyOpened = function() { return this._state.autoSchema; - }, Object.defineProperty(se.prototype, "tables", { get: function() { + }, Object.defineProperty(Ee.prototype, "tables", { get: function() { var e = this; - return C(this._allTables).map(function(t) { + return O(this._allTables).map(function(t) { return e._allTables[t]; }); - }, enumerable: !1, configurable: !0 }), se.prototype.transaction = function() { - var e = (function(t, n, r) { - var i = arguments.length; - if (i < 2) throw new U.InvalidArgument("Too few arguments"); - for (var o = new Array(i - 1); --i; ) o[i - 1] = arguments[i]; - return r = o.pop(), [t, wr(o), r]; + }, enumerable: !1, configurable: !0 }), Ee.prototype.transaction = function() { + var e = (function(t, n, o) { + var s = arguments.length; + if (s < 2) throw new X.InvalidArgument("Too few arguments"); + for (var a = new Array(s - 1); --s; ) a[s - 1] = arguments[s]; + return o = a.pop(), [t, un(a), o]; }).apply(this, arguments); return this._transaction.apply(this, e); - }, se.prototype._transaction = function(e, t, n) { - var r = this, i = $.trans; - i && i.db === this && e.indexOf("!") === -1 || (i = null); - var o, u, d = e.indexOf("?") !== -1; + }, Ee.prototype._transaction = function(e, t, n) { + var o = this, s = L.trans; + s && s.db === this && e.indexOf("!") === -1 || (s = null); + var a, d, y = e.indexOf("?") !== -1; e = e.replace("!", "").replace("?", ""); try { - if (u = t.map(function(y) { - if (y = y instanceof r.Table ? y.name : y, typeof y != "string") throw new TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed"); - return y; - }), e == "r" || e === Rn) o = Rn; + if (d = t.map(function(w) { + if (w = w instanceof o.Table ? w.name : w, typeof w != "string") throw new TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed"); + return w; + }), e == "r" || e === nr) a = nr; else { - if (e != "rw" && e != Dn) throw new U.InvalidArgument("Invalid transaction mode: " + e); - o = Dn; + if (e != "rw" && e != rr) throw new X.InvalidArgument("Invalid transaction mode: " + e); + a = rr; } - if (i) { - if (i.mode === Rn && o === Dn) { - if (!d) throw new U.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY"); - i = null; + if (s) { + if (s.mode === nr && a === rr) { + if (!y) throw new X.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY"); + s = null; } - i && u.forEach(function(y) { - if (i && i.storeNames.indexOf(y) === -1) { - if (!d) throw new U.SubTransaction("Table " + y + " not included in parent transaction."); - i = null; + s && d.forEach(function(w) { + if (s && s.storeNames.indexOf(w) === -1) { + if (!y) throw new X.SubTransaction("Table " + w + " not included in parent transaction."); + s = null; } - }), d && i && !i.active && (i = null); + }), y && s && !s.active && (s = null); } - } catch (y) { - return i ? i._promise(null, function(b, h) { - h(y); - }) : oe(y); + } catch (w) { + return s ? s._promise(null, function(j, v) { + v(w); + }) : _e(w); } - var p = (function y(b, h, _, m, v) { - return q.resolve().then(function() { - var g = $.transless || $, x = b._createTransaction(h, _, b._dbSchema, m); - if (x.explicit = !0, g = { trans: x, transless: g }, m) x.idbtrans = m.idbtrans; + var x = (function w(j, v, S, _, I) { + return V.resolve().then(function() { + var P = L.transless || L, k = j._createTransaction(v, S, j._dbSchema, _); + if (k.explicit = !0, P = { trans: k, transless: P }, _) k.idbtrans = _.idbtrans; else try { - x.create(), x.idbtrans._explicit = !0, b._state.PR1398_maxLoop = 3; - } catch (k) { - return k.name === kn.InvalidState && b.isOpen() && 0 < --b._state.PR1398_maxLoop ? (console.warn("Dexie: Need to reopen db"), b.close({ disableAutoOpen: !1 }), b.open().then(function() { - return y(b, h, _, null, v); - })) : oe(k); + k.create(), k.idbtrans._explicit = !0, j._state.PR1398_maxLoop = 3; + } catch (M) { + return M.name === kt.InvalidState && j.isOpen() && 0 < --j._state.PR1398_maxLoop ? (console.warn("Dexie: Need to reopen db"), j.close({ disableAutoOpen: !1 }), j.open().then(function() { + return w(j, v, S, null, I); + })) : _e(M); } - var P, j = jn(v); - return j && at(), g = q.follow(function() { - var k; - (P = v.call(x, x)) && (j ? (k = Ke.bind(null, null), P.then(k, k)) : typeof P.next == "function" && typeof P.throw == "function" && (P = er(P))); - }, g), (P && typeof P.then == "function" ? q.resolve(P).then(function(k) { - return x.active ? k : oe(new U.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn")); - }) : g.then(function() { - return P; - })).then(function(k) { - return m && x._resolve(), x._completion.then(function() { - return k; + var C, B = we(I); + return B && Ot(), P = V.follow(function() { + var M; + (C = I.call(k, k)) && (B ? (M = lt.bind(null, null), C.then(M, M)) : typeof C.next == "function" && typeof C.throw == "function" && (C = wr(C))); + }, P), (C && typeof C.then == "function" ? V.resolve(C).then(function(M) { + return k.active ? M : _e(new X.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn")); + }) : P.then(function() { + return C; + })).then(function(M) { + return _ && k._resolve(), k._completion.then(function() { + return M; }); - }).catch(function(k) { - return x._reject(k), oe(k); + }).catch(function(M) { + return k._reject(M), _e(M); }); }); - }).bind(null, this, o, u, i, n); - return i ? i._promise(o, p, "lock") : $.trans ? Ve($.transless, function() { - return r._whenReady(p); - }) : this._whenReady(p); - }, se.prototype.table = function(e) { - if (!B(this._allTables, e)) throw new U.InvalidTable("Table ".concat(e, " does not exist")); + }).bind(null, this, a, d, s, n); + return s ? s._promise(a, x, "lock") : L.trans ? bt(L.transless, function() { + return o._whenReady(x); + }) : this._whenReady(x); + }, Ee.prototype.table = function(e) { + if (!N(this._allTables, e)) throw new X.InvalidTable("Table ".concat(e, " does not exist")); return this._allTables[e]; - }, se); - function se(e, t) { + }, Ee); + function Ee(e, t) { var n = this; this._middlewares = {}, this.verno = 0; - var r = se.dependencies; - this._options = t = l({ addons: se.addons, autoOpen: !0, indexedDB: r.indexedDB, IDBKeyRange: r.IDBKeyRange, cache: "cloned" }, t), this._deps = { indexedDB: t.indexedDB, IDBKeyRange: t.IDBKeyRange }, r = t.addons, this._dbSchema = {}, this._versions = [], this._storeNames = [], this._allTables = {}, this.idbdb = null, this._novip = this; - var i, o, u, d, p, y = { dbOpenError: null, isBeingOpened: !1, onReadyBeingFired: null, openComplete: !1, dbReadyResolve: te, dbReadyPromise: null, cancelOpen: te, openCanceller: null, autoSchema: !0, PR1398_maxLoop: 3, autoOpen: t.autoOpen }; - y.dbReadyPromise = new q(function(h) { - y.dbReadyResolve = h; - }), y.openCanceller = new q(function(h, _) { - y.cancelOpen = _; - }), this._state = y, this.name = e, this.on = jt(this, "populate", "blocked", "versionchange", "close", { ready: [Sn, te] }), this.once = function(h, _) { - var m = function() { - for (var v = [], g = 0; g < arguments.length; g++) v[g] = arguments[g]; - n.on(h).unsubscribe(m), _.apply(n, v); + var o = Ee.dependencies; + this._options = t = h({ addons: Ee.addons, autoOpen: !0, indexedDB: o.indexedDB, IDBKeyRange: o.IDBKeyRange, cache: "cloned" }, t), this._deps = { indexedDB: t.indexedDB, IDBKeyRange: t.IDBKeyRange }, o = t.addons, this._dbSchema = {}, this._versions = [], this._storeNames = [], this._allTables = {}, this.idbdb = null, this._novip = this; + var s, a, d, y, x, w = { dbOpenError: null, isBeingOpened: !1, onReadyBeingFired: null, openComplete: !1, dbReadyResolve: he, dbReadyPromise: null, cancelOpen: he, openCanceller: null, autoSchema: !0, PR1398_maxLoop: 3, autoOpen: t.autoOpen }; + w.dbReadyPromise = new V(function(v) { + w.dbReadyResolve = v; + }), w.openCanceller = new V(function(v, S) { + w.cancelOpen = S; + }), this._state = w, this.name = e, this.on = zt(this, "populate", "blocked", "versionchange", "close", { ready: [Ct, he] }), this.once = function(v, S) { + var _ = function() { + for (var I = [], P = 0; P < arguments.length; P++) I[P] = arguments[P]; + n.on(v).unsubscribe(_), S.apply(n, I); }; - return n.on(h, m); - }, this.on.ready.subscribe = br(this.on.ready.subscribe, function(h) { - return function(_, m) { - se.vip(function() { - var v, g = n._state; - g.openComplete ? (g.dbOpenError || q.resolve().then(_), m && h(_)) : g.onReadyBeingFired ? (g.onReadyBeingFired.push(_), m && h(_)) : (h(_), v = n, m || h(function x() { - v.on.ready.unsubscribe(_), v.on.ready.unsubscribe(x); + return n.on(v, _); + }, this.on.ready.subscribe = Pe(this.on.ready.subscribe, function(v) { + return function(S, _) { + Ee.vip(function() { + var I, P = n._state; + P.openComplete ? (P.dbOpenError || V.resolve().then(S), _ && v(S)) : P.onReadyBeingFired ? (P.onReadyBeingFired.push(S), _ && v(S)) : (v(S), I = n, _ || v(function k() { + I.on.ready.unsubscribe(S), I.on.ready.unsubscribe(k); })); }); }; - }), this.Collection = (i = this, kt(fo.prototype, function(P, x) { - this.db = i; - var m = Tr, v = null; - if (x) try { - m = x(); - } catch (j) { - v = j; + }), this.Collection = (s = this, Vt(vo.prototype, function(C, k) { + this.db = s; + var _ = zr, I = null; + if (k) try { + _ = k(); + } catch (B) { + I = B; } - var g = P._ctx, x = g.table, P = x.hook.reading.fire; - this._ctx = { table: x, index: g.index, isPrimKey: !g.index || x.schema.primKey.keyPath && g.index === x.schema.primKey.name, range: m, keysOnly: !1, dir: "next", unique: "", algorithm: null, filter: null, replayFilter: null, justLimit: !0, isMatch: null, offset: 0, limit: 1 / 0, error: v, or: g.or, valueMapper: P !== gt ? P : null }; - })), this.Table = (o = this, kt(Br.prototype, function(h, _, m) { - this.db = o, this._tx = m, this.name = h, this.schema = _, this.hook = o._allTables[h] ? o._allTables[h].hook : jt(null, { creating: [no, te], reading: [to, gt], updating: [io, te], deleting: [ro, te] }); - })), this.Transaction = (u = this, kt(yo.prototype, function(h, _, m, v, g) { - var x = this; - h !== "readonly" && _.forEach(function(P) { - P = (P = m[P]) === null || P === void 0 ? void 0 : P.yProps, P && (_ = _.concat(P.map(function(j) { - return j.updatesTable; + var P = C._ctx, k = P.table, C = k.hook.reading.fire; + this._ctx = { table: k, index: P.index, isPrimKey: !P.index || k.schema.primKey.keyPath && P.index === k.schema.primKey.name, range: _, keysOnly: !1, dir: "next", unique: "", algorithm: null, filter: null, replayFilter: null, justLimit: !0, isMatch: null, offset: 0, limit: 1 / 0, error: I, or: P.or, valueMapper: C !== He ? C : null }; + })), this.Table = (a = this, Vt(Xr.prototype, function(v, S, _) { + this.db = a, this._tx = _, this.name = v, this.schema = S, this.hook = a._allTables[v] ? a._allTables[v].hook : zt(null, { creating: [Wn, he], reading: [vt, He], updating: [Gn, he], deleting: [Ht, he] }); + })), this.Transaction = (d = this, Vt(wo.prototype, function(v, S, _, I, P) { + var k = this; + v !== "readonly" && S.forEach(function(C) { + C = (C = _[C]) === null || C === void 0 ? void 0 : C.yProps, C && (S = S.concat(C.map(function(B) { + return B.updatesTable; }))); - }), this.db = u, this.mode = h, this.storeNames = _, this.schema = m, this.chromeTransactionDurability = v, this.idbtrans = null, this.on = jt(this, "complete", "error", "abort"), this.parent = g || null, this.active = !0, this._reculock = 0, this._blockedFuncs = [], this._resolve = null, this._reject = null, this._waitingFor = null, this._waitingQueue = null, this._spinCount = 0, this._completion = new q(function(P, j) { - x._resolve = P, x._reject = j; + }), this.db = d, this.mode = v, this.storeNames = S, this.schema = _, this.chromeTransactionDurability = I, this.idbtrans = null, this.on = zt(this, "complete", "error", "abort"), this.parent = P || null, this.active = !0, this._reculock = 0, this._blockedFuncs = [], this._resolve = null, this._reject = null, this._waitingFor = null, this._waitingQueue = null, this._spinCount = 0, this._completion = new V(function(C, B) { + k._resolve = C, k._reject = B; }), this._completion.then(function() { - x.active = !1, x.on.complete.fire(); - }, function(P) { - var j = x.active; - return x.active = !1, x.on.error.fire(P), x.parent ? x.parent._reject(P) : j && x.idbtrans && x.idbtrans.abort(), oe(P); + k.active = !1, k.on.complete.fire(); + }, function(C) { + var B = k.active; + return k.active = !1, k.on.error.fire(C), k.parent ? k.parent._reject(C) : B && k.idbtrans && k.idbtrans.abort(), _e(C); }); - })), this.Version = (d = this, kt(wo.prototype, function(h) { - this.db = d, this._cfg = { version: h, storesSource: null, dbschema: {}, tables: {}, contentUpgrade: null }; - })), this.WhereClause = (p = this, kt(Ur.prototype, function(h, _, m) { - if (this.db = p, this._ctx = { table: h, index: _ === ":id" ? null : _, or: m }, this._cmp = this._ascending = Z, this._descending = function(v, g) { - return Z(g, v); - }, this._max = function(v, g) { - return 0 < Z(v, g) ? v : g; - }, this._min = function(v, g) { - return Z(v, g) < 0 ? v : g; - }, this._IDBKeyRange = p._deps.IDBKeyRange, !this._IDBKeyRange) throw new U.MissingAPI(); - })), this.on("versionchange", function(h) { - 0 < h.newVersion ? console.warn("Another connection wants to upgrade database '".concat(n.name, "'. Closing db now to resume the upgrade.")) : console.warn("Another connection wants to delete database '".concat(n.name, "'. Closing db now to resume the delete request.")), n.close({ disableAutoOpen: !1 }); - }), this.on("blocked", function(h) { - !h.newVersion || h.newVersion < h.oldVersion ? console.warn("Dexie.delete('".concat(n.name, "') was blocked")) : console.warn("Upgrade '".concat(n.name, "' blocked by other connection holding version ").concat(h.oldVersion / 10)); - }), this._maxKey = Et(t.IDBKeyRange), this._createTransaction = function(h, _, m, v) { - return new n.Transaction(h, _, m, n._options.chromeTransactionDurability, v); - }, this._fireOnBlocked = function(h) { - n.on("blocked").fire(h), ut.filter(function(_) { - return _.name === n.name && _ !== n && !_._state.vcFired; - }).map(function(_) { - return _.on("versionchange").fire(h); + })), this.Version = (y = this, Vt(So.prototype, function(v) { + this.db = y, this._cfg = { version: v, storesSource: null, dbschema: {}, tables: {}, contentUpgrade: null }; + })), this.WhereClause = (x = this, Vt(ri.prototype, function(v, S, _) { + if (this.db = x, this._ctx = { table: v, index: S === ":id" ? null : S, or: _ }, this._cmp = this._ascending = le, this._descending = function(I, P) { + return le(P, I); + }, this._max = function(I, P) { + return 0 < le(I, P) ? I : P; + }, this._min = function(I, P) { + return le(I, P) < 0 ? I : P; + }, this._IDBKeyRange = x._deps.IDBKeyRange, !this._IDBKeyRange) throw new X.MissingAPI(); + })), this.on("versionchange", function(v) { + 0 < v.newVersion ? console.warn("Another connection wants to upgrade database '".concat(n.name, "'. Closing db now to resume the upgrade.")) : console.warn("Another connection wants to delete database '".concat(n.name, "'. Closing db now to resume the delete request.")), n.close({ disableAutoOpen: !1 }); + }), this.on("blocked", function(v) { + !v.newVersion || v.newVersion < v.oldVersion ? console.warn("Dexie.delete('".concat(n.name, "') was blocked")) : console.warn("Upgrade '".concat(n.name, "' blocked by other connection holding version ").concat(v.oldVersion / 10)); + }), this._maxKey = Jt(t.IDBKeyRange), this._createTransaction = function(v, S, _, I) { + return new n.Transaction(v, S, _, n._options.chromeTransactionDurability, I); + }, this._fireOnBlocked = function(v) { + n.on("blocked").fire(v), Tt.filter(function(S) { + return S.name === n.name && S !== n && !S._state.vcFired; + }).map(function(S) { + return S.on("versionchange").fire(v); }); - }, this.use(So), this.use(Oo), this.use(Co), this.use(jo), this.use(ko); - var b = new Proxy(this, { get: function(h, _, m) { - if (_ === "_vip") return !0; - if (_ === "table") return function(g) { - return ln(n.table(g), b); + }, this.use(Oo), this.use(Fo), this.use(To), this.use(Ao), this.use(Bo); + var j = new Proxy(this, { get: function(v, S, _) { + if (S === "_vip") return !0; + if (S === "table") return function(P) { + return Tn(n.table(P), j); }; - var v = Reflect.get(h, _, m); - return v instanceof Br ? ln(v, b) : _ === "tables" ? v.map(function(g) { - return ln(g, b); - }) : _ === "_createTransaction" ? function() { - return ln(v.apply(this, arguments), b); - } : v; + var I = Reflect.get(v, S, _); + return I instanceof Xr ? Tn(I, j) : S === "tables" ? I.map(function(P) { + return Tn(P, j); + }) : S === "_createTransaction" ? function() { + return Tn(I.apply(this, arguments), j); + } : I; } }); - this.vip = b, r.forEach(function(h) { - return h(n); + this.vip = j, o.forEach(function(v) { + return v(n); }); } - var dn, xe = typeof Symbol < "u" && "observable" in Symbol ? Symbol.observable : "@@observable", Ao = (ir.prototype.subscribe = function(e, t, n) { + var Mn, Ye = typeof Symbol < "u" && "observable" in Symbol ? Symbol.observable : "@@observable", Do = (Pr.prototype.subscribe = function(e, t, n) { return this._subscribe(e && typeof e != "function" ? e : { next: e, error: t, complete: n }); - }, ir.prototype[xe] = function() { + }, Pr.prototype[Ye] = function() { return this; - }, ir); - function ir(e) { + }, Pr); + function Pr(e) { this._subscribe = e; } try { - dn = { indexedDB: M.indexedDB || M.mozIndexedDB || M.webkitIndexedDB || M.msIndexedDB, IDBKeyRange: M.IDBKeyRange || M.webkitIDBKeyRange }; + Mn = { indexedDB: D.indexedDB || D.mozIndexedDB || D.webkitIndexedDB || D.msIndexedDB, IDBKeyRange: D.IDBKeyRange || D.webkitIDBKeyRange }; } catch { - dn = { indexedDB: null, IDBKeyRange: null }; + Mn = { indexedDB: null, IDBKeyRange: null }; } - function oi(e) { - var t, n = !1, r = new Ao(function(i) { - var o = jn(e), u, d = !1, p = {}, y = {}, b = { get closed() { - return d; + function vi(e) { + var t, n = !1, o = new Do(function(s) { + var a = we(e), d, y = !1, x = {}, w = {}, j = { get closed() { + return y; }, unsubscribe: function() { - d || (d = !0, u && u.abort(), h && Ne.storagemutated.unsubscribe(m)); + y || (y = !0, d && d.abort(), v && dt.storagemutated.unsubscribe(_)); } }; - i.start && i.start(b); - var h = !1, _ = function() { - return Kn(v); - }, m = function(g) { - an(p, g), Gn(y, p) && _(); - }, v = function() { - var g, x, P; - !d && dn.indexedDB && (p = {}, g = {}, u && u.abort(), u = new AbortController(), P = (function(j) { - var k = ot(); + s.start && s.start(j); + var v = !1, S = function() { + return tr(I); + }, _ = function(P) { + An(x, P), gr(w, x) && S(); + }, I = function() { + var P, k, C; + !y && Mn.indexedDB && (x = {}, P = {}, d && d.abort(), d = new AbortController(), C = (function(B) { + var M = At(); try { - o && at(); - var S = Te(e, j); - return S = o ? S.finally(Ke) : S; + a && Ot(); + var F = ct(e, B); + return F = a ? F.finally(lt) : F; } finally { - k && st(); + M && Bt(); } - })(x = { subscr: g, signal: u.signal, requery: _, querier: e, trans: null }), Promise.resolve(P).then(function(j) { - n = !0, t = j, d || x.signal.aborted || (p = {}, (function(k) { - for (var S in k) if (B(k, S)) return; + })(k = { subscr: P, signal: d.signal, requery: S, querier: e, trans: null }), Promise.resolve(C).then(function(B) { + n = !0, t = B, y || k.signal.aborted || (x = {}, (function(M) { + for (var F in M) if (N(M, F)) return; return 1; - })(y = g) || h || (Ne(Ct, m), h = !0), Kn(function() { - return !d && i.next && i.next(j); + })(w = P) || v || (dt(Gt, _), v = !0), tr(function() { + return !y && s.next && s.next(B); })); - }, function(j) { - n = !1, ["DatabaseClosedError", "AbortError"].includes(j?.name) || d || Kn(function() { - d || i.error && i.error(j); + }, function(B) { + n = !1, ["DatabaseClosedError", "AbortError"].includes(B?.name) || y || tr(function() { + y || s.error && s.error(B); }); })); }; - return setTimeout(_, 0), b; + return setTimeout(S, 0), j; }); - return r.hasValue = function() { + return o.hasValue = function() { return n; - }, r.getValue = function() { + }, o.getValue = function() { return t; - }, r; + }, o; } - var Je = Oe; - function or(e) { - var t = qe; + var Et = ot; + function jr(e) { + var t = pt; try { - qe = !0, Ne.storagemutated.fire(e), Zn(e, !0); + pt = !0, dt.storagemutated.fire(e), xr(e, !0); } finally { - qe = t; + pt = t; } } - H(Je, l(l({}, Bt), { delete: function(e) { - return new Je(e, { addons: [] }).delete(); + J(Et, h(h({}, St), { delete: function(e) { + return new Et(e, { addons: [] }).delete(); }, exists: function(e) { - return new Je(e, { addons: [] }).open().then(function(t) { + return new Et(e, { addons: [] }).open().then(function(t) { return t.close(), !0; }).catch("NoSuchDatabaseError", function() { return !1; }); }, getDatabaseNames: function(e) { try { - return t = Je.dependencies, n = t.indexedDB, t = t.IDBKeyRange, (Vn(n) ? Promise.resolve(n.databases()).then(function(r) { - return r.map(function(i) { - return i.name; - }).filter(function(i) { - return i !== Wt; + return t = Et.dependencies, n = t.indexedDB, t = t.IDBKeyRange, (pr(n) ? Promise.resolve(n.databases()).then(function(o) { + return o.map(function(s) { + return s.name; + }).filter(function(s) { + return s !== vn; }); - }) : Yn(n, t).toCollection().primaryKeys()).then(e); + }) : dr(n, t).toCollection().primaryKeys()).then(e); } catch { - return oe(new U.MissingAPI()); + return _e(new X.MissingAPI()); } var t, n; }, defineClass: function() { return function(e) { - z(this, e); + G(this, e); }; }, ignoreTransaction: function(e) { - return $.trans ? Ve($.transless, e) : e(); - }, vip: Wn, async: function(e) { + return L.trans ? bt(L.transless, e) : e(); + }, vip: yr, async: function(e) { return function() { try { - var t = er(e.apply(this, arguments)); - return t && typeof t.then == "function" ? t : q.resolve(t); + var t = wr(e.apply(this, arguments)); + return t && typeof t.then == "function" ? t : V.resolve(t); } catch (n) { - return oe(n); + return _e(n); } }; }, spawn: function(e, t, n) { try { - var r = er(e.apply(n, t || [])); - return r && typeof r.then == "function" ? r : q.resolve(r); - } catch (i) { - return oe(i); + var o = wr(e.apply(n, t || [])); + return o && typeof o.then == "function" ? o : V.resolve(o); + } catch (s) { + return _e(s); } }, currentTransaction: { get: function() { - return $.trans || null; + return L.trans || null; } }, waitFor: function(e, t) { - return t = q.resolve(typeof e == "function" ? Je.ignoreTransaction(e) : e).timeout(t || 6e4), $.trans ? $.trans.waitFor(t) : t; - }, Promise: q, debug: { get: function() { - return we; + return t = V.resolve(typeof e == "function" ? Et.ignoreTransaction(e) : e).timeout(t || 6e4), L.trans ? L.trans.waitFor(t) : t; + }, Promise: V, debug: { get: function() { + return Me; }, set: function(e) { - Sr(e); - } }, derive: Se, extend: z, props: H, override: br, Events: jt, on: Ne, liveQuery: oi, extendObservabilitySet: an, getByKeyPath: Ce, setByKeyPath: me, delByKeyPath: function(e, t) { - typeof t == "string" ? me(e, t, void 0) : "length" in t && [].map.call(t, function(n) { - me(e, n, void 0); + Ne(e); + } }, derive: ue, extend: G, props: J, override: Pe, Events: zt, on: dt, liveQuery: vi, extendObservabilitySet: An, getByKeyPath: Le, setByKeyPath: Ce, delByKeyPath: function(e, t) { + typeof t == "string" ? Ce(e, t, void 0) : "length" in t && [].map.call(t, function(n) { + Ce(e, n, void 0); }); - }, shallowClone: _r, deepClone: Fe, getObjectDiff: tr, cmp: Z, asap: xr, minKey: -1 / 0, addons: [], connections: ut, errnames: kn, dependencies: dn, cache: Ge, semVer: "4.2.1", version: "4.2.1".split(".").map(function(e) { + }, shallowClone: an, deepClone: Qe, getObjectDiff: _r, cmp: le, asap: be, minKey: -1 / 0, addons: [], connections: Tt, errnames: kt, dependencies: Mn, cache: _t, semVer: "4.2.1", version: "4.2.1".split(".").map(function(e) { return parseInt(e); }).reduce(function(e, t, n) { return e + t / Math.pow(10, 2 * n); - }) })), Je.maxKey = Et(Je.dependencies.IDBKeyRange), typeof dispatchEvent < "u" && typeof addEventListener < "u" && (Ne(Ct, function(e) { - qe || (e = new CustomEvent(Bn, { detail: e }), qe = !0, dispatchEvent(e), qe = !1); - }), addEventListener(Bn, function(e) { - e = e.detail, qe || or(e); + }) })), Et.maxKey = Jt(Et.dependencies.IDBKeyRange), typeof dispatchEvent < "u" && typeof addEventListener < "u" && (dt(Gt, function(e) { + pt || (e = new CustomEvent(sr, { detail: e }), pt = !0, dispatchEvent(e), pt = !1); + }), addEventListener(sr, function(e) { + e = e.detail, pt || jr(e); })); - var ft, qe = !1, si = function() { + var Dt, pt = !1, bi = function() { }; - return typeof BroadcastChannel < "u" && ((si = function() { - (ft = new BroadcastChannel(Bn)).onmessage = function(e) { - return e.data && or(e.data); + return typeof BroadcastChannel < "u" && ((bi = function() { + (Dt = new BroadcastChannel(sr)).onmessage = function(e) { + return e.data && jr(e.data); }; - })(), typeof ft.unref == "function" && ft.unref(), Ne(Ct, function(e) { - qe || ft.postMessage(e); + })(), typeof Dt.unref == "function" && Dt.unref(), dt(Gt, function(e) { + pt || Dt.postMessage(e); })), typeof addEventListener < "u" && (addEventListener("pagehide", function(e) { - if (!Oe.disableBfCache && e.persisted) { - we && console.debug("Dexie: handling persisted pagehide"), ft?.close(); - for (var t = 0, n = ut; t < n.length; t++) n[t].close({ disableAutoOpen: !1 }); + if (!ot.disableBfCache && e.persisted) { + Me && console.debug("Dexie: handling persisted pagehide"), Dt?.close(); + for (var t = 0, n = Tt; t < n.length; t++) n[t].close({ disableAutoOpen: !1 }); } }), addEventListener("pageshow", function(e) { - !Oe.disableBfCache && e.persisted && (we && console.debug("Dexie: handling persisted pageshow"), si(), or({ all: new de(-1 / 0, [[]]) })); - })), q.rejectionMapper = function(e, t) { - return !e || e instanceof rt || e instanceof TypeError || e instanceof SyntaxError || !e.name || !kr[e.name] ? e : (t = new kr[e.name](t || e.message, e), "stack" in e && ie(t, "stack", { get: function() { + !ot.disableBfCache && e.persisted && (Me && console.debug("Dexie: handling persisted pageshow"), bi(), jr({ all: new Be(-1 / 0, [[]]) })); + })), V.rejectionMapper = function(e, t) { + return !e || e instanceof Ze || e instanceof TypeError || e instanceof SyntaxError || !e.name || !Lt[e.name] ? e : (t = new Lt[e.name](t || e.message, e), "stack" in e && Z(t, "stack", { get: function() { return this.inner.stack; } }), t); - }, Sr(we), l(Oe, Object.freeze({ __proto__: null, Dexie: Oe, liveQuery: oi, Entity: Kr, cmp: Z, PropModification: Pt, replacePrefix: function(e, t) { - return new Pt({ replacePrefix: [e, t] }); + }, Ne(Me), h(ot, Object.freeze({ __proto__: null, Dexie: ot, liveQuery: vi, Entity: Vr, cmp: le, PropModification: Yt, replacePrefix: function(e, t) { + return new Yt({ replacePrefix: [e, t] }); }, add: function(e) { - return new Pt({ add: e }); + return new Yt({ add: e }); }, remove: function(e) { - return new Pt({ remove: e }); - }, default: Oe, RangeSet: de, mergeRanges: At, rangesOverlap: Qr }), { default: Oe }), Oe; + return new Yt({ remove: e }); + }, default: ot, RangeSet: Be, mergeRanges: Zt, rangesOverlap: ui }), { default: ot }), ot; }); - })(vn)), vn.exports; + })(Un)), Un.exports; } -var Es = Cs(); -const pr = /* @__PURE__ */ No(Es), li = /* @__PURE__ */ Symbol.for("Dexie"), Rt = globalThis[li] || (globalThis[li] = pr); -if (pr.semVer !== Rt.semVer) - throw new Error(`Two different versions of Dexie loaded in the same app: ${pr.semVer} and ${Rt.semVer}`); +var Ts = Os(); +const Fr = /* @__PURE__ */ Lo(Ts), Ei = /* @__PURE__ */ Symbol.for("Dexie"), on = globalThis[Ei] || (globalThis[Ei] = Fr); +if (Fr.semVer !== on.semVer) + throw new Error(`Two different versions of Dexie loaded in the same app: ${Fr.semVer} and ${on.semVer}`); const { - liveQuery: Xu, - mergeRanges: Zu, - rangesOverlap: ec, - RangeSet: tc, - cmp: nc, - Entity: rc, - PropModification: ic, - replacePrefix: oc, - add: sc, - remove: ac, - DexieYProvider: uc -} = Rt, Fi = { + liveQuery: sc, + mergeRanges: ac, + rangesOverlap: uc, + RangeSet: cc, + cmp: lc, + Entity: fc, + PropModification: hc, + replacePrefix: dc, + add: pc, + remove: yc, + DexieYProvider: mc +} = on, no = { _0_: "0".codePointAt(0), _1_: "1".codePointAt(0), _9_: "9".codePointAt(0), @@ -3230,213 +3230,213 @@ const { _l_: "l".codePointAt(0), _s_: "s".codePointAt(0) }, { - _0_: gn, - _1_: Is, - _9_: vr, - _A_: Os, - _E_: As, - _F_: Ms, - _a_: di, - _b_: Ts, - _backslash_: fi, - _closeCurly_: hi, - _closeSquare_: Ks, - _colon_: Rs, - _comma_: Ds, - _dot_: Ns, - _e_: ur, - _f_: cr, - _l_: lr, - _minus_: pi, - _n_: yi, - _newline_: qs, - _openCurly_: Bs, - _openSquare_: Fs, - _plus_: $s, - _quoteMark_: pn, - _r_: mi, - _return_: Ls, - _s_: Hs, - _slash_: Us, - _space_: zs, - _t_: vi, - _tab_: Ys, - _u_: dr -} = Fi, yt = { + _0_: $n, + _1_: Ms, + _9_: Nr, + _A_: Rs, + _E_: Fs, + _F_: Ds, + _a_: Ii, + _b_: Ks, + _backslash_: Pi, + _closeCurly_: ji, + _closeSquare_: Ns, + _colon_: qs, + _comma_: Us, + _dot_: $s, + _e_: Cr, + _f_: Ar, + _l_: Br, + _minus_: ki, + _n_: Si, + _newline_: Ls, + _openCurly_: Hs, + _openSquare_: Ys, + _plus_: zs, + _quoteMark_: Dn, + _r_: Ci, + _return_: Vs, + _s_: Ws, + _slash_: Gs, + _space_: Js, + _t_: Ai, + _tab_: Qs, + _u_: Or +} = no, qt = { error: "JsonFeedbackType.error" -}, $i = { +}, ro = { unexpected: "JsonErrorType.unexpected", unexpectedEnd: "JsonErrorType.unexpectedEnd" -}, Kt = (s) => ({ - type: yt.error, - message: s -}), ae = (s, c, a) => ({ - type: yt.error, - errorType: $i.unexpected, - codePoint: s, - context: c, - expected: a -}), le = (s, c) => ({ - type: yt.error, - errorType: $i.unexpectedEnd, - context: s, - expected: c -}), Ze = (s) => s >= gn && s <= vr, gi = (s) => s >= Is && s <= vr, yn = (s) => s === zs || s === qs || s === Ys || s === Ls, Vs = (s, c = {}) => { - let a = c.mode ?? "Mode._value", l = c.parents ?? ["Parent.top"], E = c.hexIndex ?? 0, M = c.maxDepth ?? 65536, C = c.isKey ?? !1; - const O = (w) => w === Ns ? (a = "Mode.dot_", s.codePoint?.(w)) : z(w), z = (w) => w === ur || w === As ? (a = "Mode.exponent_", s.codePoint?.(w)) : Y(w), Y = (w) => (a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeNumber?.(), H.codePoint(w)), K = () => Kt( - `Invalid parser state! Max depth of ${M} exceeded!` - ), B = (w) => { - const ie = l.pop(); - return w === hi && ie === "Parent.object" ? (a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeObject?.(w)) : w === Ks && ie === "Parent.array" ? (a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeArray?.(w)) : ae(w, `in ${bi(ie)}`); - }, H = { - codePoint: (w) => { - switch (a) { +}, rn = (u) => ({ + type: qt.error, + message: u +}), Ie = (u, l, f) => ({ + type: qt.error, + errorType: ro.unexpected, + codePoint: u, + context: l, + expected: f +}), Se = (u, l) => ({ + type: qt.error, + errorType: ro.unexpectedEnd, + context: u, + expected: l +}), Pt = (u) => u >= $n && u <= Nr, Bi = (u) => u >= Ms && u <= Nr, Kn = (u) => u === Js || u === Ls || u === Qs || u === Vs, Xs = (u, l = {}) => { + let f = l.mode ?? "Mode._value", h = l.parents ?? ["Parent.top"], T = l.hexIndex ?? 0, D = l.maxDepth ?? 65536, O = l.isKey ?? !1; + const g = (b) => b === $s ? (f = "Mode.dot_", u.codePoint?.(b)) : G(b), G = (b) => b === Cr || b === Fs ? (f = "Mode.exponent_", u.codePoint?.(b)) : Q(b), Q = (b) => (f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeNumber?.(), J.codePoint(b)), K = () => rn( + `Invalid parser state! Max depth of ${D} exceeded!` + ), N = (b) => { + const Z = h.pop(); + return b === ji && Z === "Parent.object" ? (f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeObject?.(b)) : b === Ns && Z === "Parent.array" ? (f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeArray?.(b)) : Ie(b, `in ${Oi(Z)}`); + }, J = { + codePoint: (b) => { + switch (f) { case "Mode._value": - switch (w) { - case Bs: - return l.length >= M ? K() : (l.push("Parent.object"), C = !0, a = "Mode._key", s.openObject?.(w)); - case Fs: - return l.length >= M ? K() : (l.push("Parent.array"), a = "Mode._value", s.openArray?.(w)); - case pn: - return a = "Mode.string_", s.openString?.(w); - case vi: - return a = "Mode.t_rue", s.openTrue?.(w); - case cr: - return a = "Mode.f_alse", s.openFalse?.(w); - case yi: - return a = "Mode.n_ull", s.openNull?.(w); - case pi: - return a = "Mode.minus_", s.openNumber?.(w); - case gn: - return a = "Mode.zero_", s.openNumber?.(w); + switch (b) { + case Hs: + return h.length >= D ? K() : (h.push("Parent.object"), O = !0, f = "Mode._key", u.openObject?.(b)); + case Ys: + return h.length >= D ? K() : (h.push("Parent.array"), f = "Mode._value", u.openArray?.(b)); + case Dn: + return f = "Mode.string_", u.openString?.(b); + case Ai: + return f = "Mode.t_rue", u.openTrue?.(b); + case Ar: + return f = "Mode.f_alse", u.openFalse?.(b); + case Si: + return f = "Mode.n_ull", u.openNull?.(b); + case ki: + return f = "Mode.minus_", u.openNumber?.(b); + case $n: + return f = "Mode.zero_", u.openNumber?.(b); default: - return gi(w) ? (a = "Mode.onenine_", s.openNumber?.(w)) : yn(w) ? s.whitespace?.(w) : B(w); + return Bi(b) ? (f = "Mode.onenine_", u.openNumber?.(b)) : Kn(b) ? u.whitespace?.(b) : N(b); } case "Mode.value_": - if (w === Ds) { - const ie = l[l.length - 1]; - return ie === "Parent.object" ? (C = !0, a = "Mode._key", s.comma?.(w)) : ie === "Parent.array" ? (a = "Mode._value", s.comma?.(w)) : Kt(`Invalid parser state! Unexpected parent ${ie}.`); + if (b === Us) { + const Z = h[h.length - 1]; + return Z === "Parent.object" ? (O = !0, f = "Mode._key", u.comma?.(b)) : Z === "Parent.array" ? (f = "Mode._value", u.comma?.(b)) : rn(`Invalid parser state! Unexpected parent ${Z}.`); } - return yn(w) ? s.whitespace?.(w) : B(w); + return Kn(b) ? u.whitespace?.(b) : N(b); case "Mode._key": - return w === pn ? (a = "Mode.string_", s.openKey?.(w)) : w === hi ? (l.pop(), C = !1, a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeObject?.(w)) : yn(w) ? s.whitespace?.(w) : ae(w, "in an object", ['"', "}", "whitespace"]); + return b === Dn ? (f = "Mode.string_", u.openKey?.(b)) : b === ji ? (h.pop(), O = !1, f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeObject?.(b)) : Kn(b) ? u.whitespace?.(b) : Ie(b, "in an object", ['"', "}", "whitespace"]); case "Mode.key_": - return w === Rs ? (C = !1, a = "Mode._value", s.colon?.(w)) : yn(w) ? s.whitespace?.(w) : ae(w, "after key", [":", "whitespace"]); + return b === qs ? (O = !1, f = "Mode._value", u.colon?.(b)) : Kn(b) ? u.whitespace?.(b) : Ie(b, "after key", [":", "whitespace"]); case "Mode.string_": - return w === pn ? C ? (a = "Mode.key_", s.closeKey?.(w)) : (a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeString?.(w)) : w === fi ? (a = "Mode.escape_", s.escape?.(w)) : w >= 32 && w <= 1114111 ? s.codePoint?.(w) : ae(w, "in a string", ['"', "\\", "a code point 0x0020 thru 0x10ffff"]); + return b === Dn ? O ? (f = "Mode.key_", u.closeKey?.(b)) : (f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeString?.(b)) : b === Pi ? (f = "Mode.escape_", u.escape?.(b)) : b >= 32 && b <= 1114111 ? u.codePoint?.(b) : Ie(b, "in a string", ['"', "\\", "a code point 0x0020 thru 0x10ffff"]); case "Mode.escape_": - return w === pn || w === yi || w === fi || w === vi || w === Us || w === Ts || w === cr || w === mi ? (a = "Mode.string_", s.codePoint?.(w)) : w === dr ? (a = "Mode.hex_", s.openHex?.(w)) : ae(w, "after escape", ['"', "n", "\\", "t", "/", "b", "f", "r", "u"]); + return b === Dn || b === Si || b === Pi || b === Ai || b === Gs || b === Ks || b === Ar || b === Ci ? (f = "Mode.string_", u.codePoint?.(b)) : b === Or ? (f = "Mode.hex_", u.openHex?.(b)) : Ie(b, "after escape", ['"', "n", "\\", "t", "/", "b", "f", "r", "u"]); case "Mode.hex_": - return w >= gn && w <= vr || w >= di && w <= cr || w >= Os && w <= Ms ? E < 3 ? (E += 1, s.codePoint?.(w)) : (E = 0, a = "Mode.string_", s.closeHex?.(w)) : ae(w, `at index ${E} of a hexadecimal escape sequence`, [["a", "f"], ["A", "F"], ["0", "9"]]); + return b >= $n && b <= Nr || b >= Ii && b <= Ar || b >= Rs && b <= Ds ? T < 3 ? (T += 1, u.codePoint?.(b)) : (T = 0, f = "Mode.string_", u.closeHex?.(b)) : Ie(b, `at index ${T} of a hexadecimal escape sequence`, [["a", "f"], ["A", "F"], ["0", "9"]]); case "Mode.minus_": - return w === gn ? (a = "Mode.zero_", s.codePoint?.(w)) : gi(w) ? (a = "Mode.onenine_", s.codePoint?.(w)) : ae(w, "after '-'", [["0", "9"]]); + return b === $n ? (f = "Mode.zero_", u.codePoint?.(b)) : Bi(b) ? (f = "Mode.onenine_", u.codePoint?.(b)) : Ie(b, "after '-'", [["0", "9"]]); case "Mode.zero_": - return O(w); + return g(b); case "Mode.onenine_": - return Ze(w) ? (a = "Mode.onenineDigit_", s.codePoint?.(w)) : O(w); + return Pt(b) ? (f = "Mode.onenineDigit_", u.codePoint?.(b)) : g(b); case "Mode.dot_": - return Ze(w) ? (a = "Mode.digitDotDigit_", s.codePoint?.(w)) : ae(w, "after '.'", [["0", "9"]]); + return Pt(b) ? (f = "Mode.digitDotDigit_", u.codePoint?.(b)) : Ie(b, "after '.'", [["0", "9"]]); case "Mode.exponent_": - return w === $s || w === pi ? (a = "Mode.exponentSign_", s.codePoint?.(w)) : Ze(w) ? (a = "Mode.exponentSignDigit_", s.codePoint?.(w)) : ae(w, "after exponent", ["+", "-", ["0", "9"]]); + return b === zs || b === ki ? (f = "Mode.exponentSign_", u.codePoint?.(b)) : Pt(b) ? (f = "Mode.exponentSignDigit_", u.codePoint?.(b)) : Ie(b, "after exponent", ["+", "-", ["0", "9"]]); case "Mode.exponentSign_": - return Ze(w) ? (a = "Mode.exponentSignDigit_", s.codePoint?.(w)) : ae(w, "after exponent sign", [["0", "9"]]); + return Pt(b) ? (f = "Mode.exponentSignDigit_", u.codePoint?.(b)) : Ie(b, "after exponent sign", [["0", "9"]]); case "Mode.onenineDigit_": - return Ze(w) ? s.codePoint?.(w) : O(w); + return Pt(b) ? u.codePoint?.(b) : g(b); case "Mode.digitDotDigit_": - return Ze(w) ? s.codePoint?.(w) : z(w); + return Pt(b) ? u.codePoint?.(b) : G(b); case "Mode.exponentSignDigit_": - return Ze(w) ? s.codePoint?.(w) : Y(w); + return Pt(b) ? u.codePoint?.(b) : Q(b); case "Mode.t_rue": - return w === mi ? (a = "Mode.tr_ue", s.codePoint?.(w)) : ae(w, "at the second position in true", ["r"]); + return b === Ci ? (f = "Mode.tr_ue", u.codePoint?.(b)) : Ie(b, "at the second position in true", ["r"]); case "Mode.tr_ue": - return w === dr ? (a = "Mode.tru_e", s.codePoint?.(w)) : ae(w, "at the third position in true", ["u"]); + return b === Or ? (f = "Mode.tru_e", u.codePoint?.(b)) : Ie(b, "at the third position in true", ["u"]); case "Mode.tru_e": - return w === ur ? (a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeTrue?.(w)) : ae(w, "at the fourth position in true", ["e"]); + return b === Cr ? (f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeTrue?.(b)) : Ie(b, "at the fourth position in true", ["e"]); case "Mode.f_alse": - return w === di ? (a = "Mode.fa_lse", s.codePoint?.(w)) : ae(w, "at the second position in false", ["a"]); + return b === Ii ? (f = "Mode.fa_lse", u.codePoint?.(b)) : Ie(b, "at the second position in false", ["a"]); case "Mode.fa_lse": - return w === lr ? (a = "Mode.fal_se", s.codePoint?.(w)) : ae(w, "at the third position in false", ["l"]); + return b === Br ? (f = "Mode.fal_se", u.codePoint?.(b)) : Ie(b, "at the third position in false", ["l"]); case "Mode.fal_se": - return w === Hs ? (a = "Mode.fals_e", s.codePoint?.(w)) : ae(w, "at the fourth position in false", ["s"]); + return b === Ws ? (f = "Mode.fals_e", u.codePoint?.(b)) : Ie(b, "at the fourth position in false", ["s"]); case "Mode.fals_e": - return w === ur ? (a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeFalse?.(w)) : ae(w, "at the fifth position in false", ["e"]); + return b === Cr ? (f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeFalse?.(b)) : Ie(b, "at the fifth position in false", ["e"]); case "Mode.n_ull": - return w === dr ? (a = "Mode.nu_ll", s.codePoint?.(w)) : ae(w, "at the second position in null", ["u"]); + return b === Or ? (f = "Mode.nu_ll", u.codePoint?.(b)) : Ie(b, "at the second position in null", ["u"]); case "Mode.nu_ll": - return w === lr ? (a = "Mode.nul_l", s.codePoint?.(w)) : ae(w, "at the third position in null", ["l"]); + return b === Br ? (f = "Mode.nul_l", u.codePoint?.(b)) : Ie(b, "at the third position in null", ["l"]); case "Mode.nul_l": - return w === lr ? (a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeNull?.(w)) : ae(w, "at the fourth position in null", ["l"]); + return b === Br ? (f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeNull?.(b)) : Ie(b, "at the fourth position in null", ["l"]); default: - return Kt(`Invalid parser mode: ${a}`); + return rn(`Invalid parser mode: ${f}`); } }, end: () => { - if (C) return le("a key/object left unclosed!"); - const w = l[l.length - 1]; - if (w !== "Parent.top") return le( - `${bi(w)} left unclosed!` + if (O) return Se("a key/object left unclosed!"); + const b = h[h.length - 1]; + if (b !== "Parent.top") return Se( + `${Oi(b)} left unclosed!` ); - switch (a) { + switch (f) { case "Mode._value": - return s.end?.(); + return u.end?.(); case "Mode.key_": - return Kt("a key/object left unclosed!"); + return rn("a key/object left unclosed!"); case "Mode._key": - return le("an object left unclosed!"); + return Se("an object left unclosed!"); case "Mode.exponentSignDigit_": case "Mode.onenine_": case "Mode.onenineDigit_": case "Mode.digitDotDigit_": case "Mode.zero_": - return a = l[l.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", s.closeNumber?.(), s.end?.(); + return f = h[h.length - 1] === "Parent.top" ? "Mode._value" : "Mode.value_", u.closeNumber?.(), u.end?.(); case "Mode.minus_": case "Mode.dot_": case "Mode.exponent_": case "Mode.exponentSign_": - return le("incomplete number!"); + return Se("incomplete number!"); case "Mode.hex_": - return le("after hexadecimal escape in string!"); + return Se("after hexadecimal escape in string!"); case "Mode.escape_": - return le("after escape in string!"); + return Se("after escape in string!"); case "Mode.string_": - return le("a string left unclosed!"); + return Se("a string left unclosed!"); case "Mode.t_rue": - return le("before the second position in true!", ["r"]); + return Se("before the second position in true!", ["r"]); case "Mode.tr_ue": - return le("before the third position in true!", ["u"]); + return Se("before the third position in true!", ["u"]); case "Mode.tru_e": - return le("before the fourth position in true!", ["e"]); + return Se("before the fourth position in true!", ["e"]); case "Mode.f_alse": - return le("before the second position in false!", ["a"]); + return Se("before the second position in false!", ["a"]); case "Mode.fa_lse": - return le("before the third position in false!", ["l"]); + return Se("before the third position in false!", ["l"]); case "Mode.fal_se": - return le("before the fourth position in false!", ["s"]); + return Se("before the fourth position in false!", ["s"]); case "Mode.fals_e": - return le("before the fifth position in false!", ["e"]); + return Se("before the fifth position in false!", ["e"]); case "Mode.n_ull": - return le("before the second position in null!", ["u"]); + return Se("before the second position in null!", ["u"]); case "Mode.nu_ll": - return le("before the third position in null!", ["l"]); + return Se("before the third position in null!", ["l"]); case "Mode.nul_l": - return le("before the fourth position in null!", ["l"]); + return Se("before the fourth position in null!", ["l"]); default: - return le(); + return Se(); } }, - depth: () => l.length - 1, + depth: () => h.length - 1, state: () => { - const w = s.state?.(); - return { mode: a, parents: [...l], isKey: C, hexIndex: E, downstream: w }; + const b = u.state?.(); + return { mode: f, parents: [...h], isKey: O, hexIndex: T, downstream: b }; }, config: () => { - const w = s.config?.(); - return { maxDepth: M, downstream: w }; + const b = u.config?.(); + return { maxDepth: D, downstream: b }; } }; - return H; -}, bi = (s) => { - switch (s) { + return J; +}, Oi = (u) => { + switch (u) { case "Parent.array": return "an array"; case "Parent.object": @@ -3444,262 +3444,262 @@ const { case "Parent.top": return "the top-level value"; } -}, { _t_: Ws, _n_: Qs, _b_: Gs, _r_: Js, _f_: Xs } = Fi, Zs = (s) => { +}, { _t_: Zs, _n_: ea, _b_: ta, _r_: na, _f_: ra } = no, ia = (u) => { const { - maxStringBufferLength: c = 1 / 0, - maxNumberLength: a = 8192, - parseNumbers: l = !0 - } = s; - if (c < 1) throw Error("maxStringBufferLength must be at least 1!"); - if (a < 1) throw Error("maxNumberLength must be at least 1!"); - let E = "top", M = "string", C = "", O = 0, z = "", Y = []; + maxStringBufferLength: l = 1 / 0, + maxNumberLength: f = 8192, + parseNumbers: h = !0 + } = u; + if (l < 1) throw Error("maxStringBufferLength must be at least 1!"); + if (f < 1) throw Error("maxNumberLength must be at least 1!"); + let T = "top", D = "string", O = "", g = 0, G = "", Q = []; const K = { // note: for the closeNumber edge case we store feedback here // and check inside JsonHigh closeNumberFeedback: void 0, - openString: () => (C = "", O = 0, E = "string", M = "string", s.openString?.()), - openKey: () => (C = "", O = 0, E = "string", M = "key", s.openKey?.()), - openNumber: (B) => (z = String.fromCharCode(B), E = "number", s.openNumber?.()), - openObject: () => s.openObject?.(), - openArray: () => s.openArray?.(), - closeObject: () => s.closeObject?.(), - closeArray: () => s.closeArray?.(), - closeTrue: () => s.value?.(!0), - closeFalse: () => s.value?.(!1), - closeNull: () => s.value?.(null), - codePoint: (B) => { - if (E === "string") { - const H = String.fromCodePoint(B); - if (O === c) { - const w = C; - return C = H, O = 1, M === "string" ? s.bufferString?.(w) : s.bufferKey?.(w); + openString: () => (O = "", g = 0, T = "string", D = "string", u.openString?.()), + openKey: () => (O = "", g = 0, T = "string", D = "key", u.openKey?.()), + openNumber: (N) => (G = String.fromCharCode(N), T = "number", u.openNumber?.()), + openObject: () => u.openObject?.(), + openArray: () => u.openArray?.(), + closeObject: () => u.closeObject?.(), + closeArray: () => u.closeArray?.(), + closeTrue: () => u.value?.(!0), + closeFalse: () => u.value?.(!1), + closeNull: () => u.value?.(null), + codePoint: (N) => { + if (T === "string") { + const J = String.fromCodePoint(N); + if (g === l) { + const b = O; + return O = J, g = 1, D === "string" ? u.bufferString?.(b) : u.bufferKey?.(b); } - C += H, O += 1; - } else if (E === "escape") { - let H; - if (B === Qs ? H = ` -` : B === Ws ? H = " " : B === Js ? H = "\r" : B === Gs ? H = "\b" : B === Xs ? H = "\f" : H = String.fromCharCode(B), E = "string", O === c) { - const w = C; - return C = H, O = 1, M === "string" ? s.bufferString?.(w) : s.bufferKey?.(w); + O += J, g += 1; + } else if (T === "escape") { + let J; + if (N === ea ? J = ` +` : N === Zs ? J = " " : N === na ? J = "\r" : N === ta ? J = "\b" : N === ra ? J = "\f" : J = String.fromCharCode(N), T = "string", g === l) { + const b = O; + return O = J, g = 1, D === "string" ? u.bufferString?.(b) : u.bufferKey?.(b); } - C += H, O += 1; - } else if (E === "hex") - Y.push(B); - else if (E === "number") { - if (z.length === a) return Kt(`Number length over the limit of ${a}! Try increasing the limit.`); - z += String.fromCharCode(B); + O += J, g += 1; + } else if (T === "hex") + Q.push(N); + else if (T === "number") { + if (G.length === f) return rn(`Number length over the limit of ${f}! Try increasing the limit.`); + G += String.fromCharCode(N); } }, escape: () => { - E = "escape"; + T = "escape"; }, openHex: () => { - Y = [], E = "hex"; + Q = [], T = "hex"; }, - closeString: () => (E = "top", c === 1 / 0 ? s.value?.(C) : { feedbacks: [ - s.bufferString?.(C), - s.closeString?.() + closeString: () => (T = "top", l === 1 / 0 ? u.value?.(O) : { feedbacks: [ + u.bufferString?.(O), + u.closeString?.() ] }), - closeKey: () => (E = "top", c === 1 / 0 ? s.key?.(C) : { feedbacks: [ - s.bufferKey?.(C), - s.closeKey?.() + closeKey: () => (T = "top", l === 1 / 0 ? u.key?.(O) : { feedbacks: [ + u.bufferKey?.(O), + u.closeKey?.() ] }), - closeHex: (B) => { - Y.push(B), E = "string"; - const H = String.fromCharCode(Number.parseInt(String.fromCharCode(...Y), 16)); - if (O === c) { - const w = C; - return C = H, O = 1, M === "string" ? s.bufferString?.(w) : s.bufferKey?.(w); - } - C += H, O += 1; + closeHex: (N) => { + Q.push(N), T = "string"; + const J = String.fromCharCode(Number.parseInt(String.fromCharCode(...Q), 16)); + if (g === l) { + const b = O; + return O = J, g = 1, D === "string" ? u.bufferString?.(b) : u.bufferKey?.(b); + } + O += J, g += 1; }, closeNumber: () => { - E = "top", l ? K.closeNumberFeedback = s.value?.( - Number.parseFloat(z) - ) : K.closeNumberFeedback = s.bufferNumber?.(z); + T = "top", h ? K.closeNumberFeedback = u.value?.( + Number.parseFloat(G) + ) : K.closeNumberFeedback = u.bufferNumber?.(G); }, - end: () => s.end?.() + end: () => u.end?.() }; return K; -}, ea = 10, ta = (s) => { - let c = 0, a = 1, l = 1; - const E = { - codePoint: (M) => { - const C = s.codePoint(M), O = { - pos: c, - line: a, - col: l, - ...C +}, oa = 10, sa = (u) => { + let l = 0, f = 1, h = 1; + const T = { + codePoint: (D) => { + const O = u.codePoint(D), g = { + pos: l, + line: f, + col: h, + ...O }; - return c += 1, M === ea ? (a += 1, l = 1) : l += 1, O; + return l += 1, D === oa ? (f += 1, h = 1) : h += 1, g; }, end: () => { - const M = s.end(); - return c += 1, l += 1, { - pos: c, - line: a, - col: l, - ...M + const D = u.end(); + return l += 1, h += 1, { + pos: l, + line: f, + col: h, + ...D }; } }; - return new Proxy(s, { - get: (M, C, O) => E[C] || M[C] + return new Proxy(u, { + get: (D, O, g) => T[O] || D[O] }); -}, na = (s) => { - const c = Zs(s), a = ta(Vs(c)), l = { - chunk(E) { - for (const M of E) { - const C = a.codePoint(M.codePointAt(0)), { closeNumberFeedback: O } = c; - if (O !== void 0 && (c.closeNumberFeedback = void 0, O.type === yt.error)) - throw Error(JSON.stringify(O, null, 2)); - if (C !== void 0) { - if ("feedbacks" in C) { - for (const z of C.feedbacks) - if (z !== void 0 && z.type === yt.error) - throw Error(JSON.stringify(z, null, 2)); - } else if (C.type === yt.error) - throw Error(JSON.stringify(C, null, 2)); +}, aa = (u) => { + const l = ia(u), f = sa(Xs(l)), h = { + chunk(T) { + for (const D of T) { + const O = f.codePoint(D.codePointAt(0)), { closeNumberFeedback: g } = l; + if (g !== void 0 && (l.closeNumberFeedback = void 0, g.type === qt.error)) + throw Error(JSON.stringify(g, null, 2)); + if (O !== void 0) { + if ("feedbacks" in O) { + for (const G of O.feedbacks) + if (G !== void 0 && G.type === qt.error) + throw Error(JSON.stringify(G, null, 2)); + } else if (O.type === qt.error) + throw Error(JSON.stringify(O, null, 2)); } } - return l; + return h; }, end() { - return a.end(); + return f.end(); }, depth() { - return a.depth(); + return f.depth(); }, state() { - return a.state(); + return f.state(); } }; - return l; + return h; }; -function ra(s) { - const c = []; - for (const [a, l] of Object.entries(s)) { - const E = ia(a), M = E.pop(), C = M === "deep()" ? "deep" : M === "shallow()" ? "shallow" : "value"; - c.push({ path: E, type: C, handler: l }); +function ua(u) { + const l = []; + for (const [f, h] of Object.entries(u)) { + const T = ca(f), D = T.pop(), O = D === "deep()" ? "deep" : D === "shallow()" ? "shallow" : "value"; + l.push({ path: T, type: O, handler: h }); } - return c.sort((a, l) => l.path.length - a.path.length), c; + return l.sort((f, h) => h.path.length - f.path.length), l; } -function ia(s) { - return s.split("."); +function ca(u) { + return u.split("."); } -function oa(s) { - const c = ra(s); - return aa(c, []); +function la(u) { + const l = ua(u); + return ha(l, []); } -function sa(s, c) { - if (s.length !== c.length) +function fa(u, l) { + if (u.length !== l.length) return; - const a = []; - for (let l = 0; l < s.length; l++) - if (s[l] !== c[l]) { - if (s[l] === "*") { - a.push(c[l]); + const f = []; + for (let h = 0; h < u.length; h++) + if (u[h] !== l[h]) { + if (u[h] === "*") { + f.push(l[h]); continue; } return; } - return a; + return f; } -function xi(s, c) { - for (const a of s) { - const l = sa(a.path, c); - if (l) +function Ti(u, l) { + for (const f of u) { + const h = fa(f.path, l); + if (h) return { - value: a.type === "value" ? a.handler : void 0, - shallow: a.type === "shallow" ? a.handler : void 0, - deep: a.type === "deep" ? a.handler : void 0, - matches: l, - level: c.length + value: f.type === "value" ? f.handler : void 0, + shallow: f.type === "shallow" ? f.handler : void 0, + deep: f.type === "deep" ? f.handler : void 0, + matches: h, + level: l.length }; } } -function aa(s, c) { - const a = [{}], l = ["$"]; - let E = [xi(s, l)]; - const M = (Y) => () => { - const K = xi(s, l); - K && E.push(K), Y === "object" ? (a.push({}), l.push("")) : (a.push([]), l.push(-1)); - }, C = () => { - l.pop(), c.pop(); - const Y = a.pop(), K = a.at(-1), B = l.at(-1), H = E.at(-1); - H?.level === l.length && (H.deep ? H.deep(Y, H.matches) : H.shallow && H.shallow(Y, H.matches), E.pop()), H?.deep && (Array.isArray(K) ? K.push(Y) : K[B] = Y); - }, O = (Y) => { - l[l.length - 1] = Y; - }, z = (Y) => { - const K = E.at(-1); - if (K?.level === l.length - 1 && K.value) - K.value(Y, K.matches); - else if (K?.level === l.length - 1 && K.shallow || K?.deep) { - const B = a.at(-1); - Array.isArray(B) ? B.push(Y) : B[l.at(-1)] = Y; +function ha(u, l) { + const f = [{}], h = ["$"]; + let T = [Ti(u, h)]; + const D = (Q) => () => { + const K = Ti(u, h); + K && T.push(K), Q === "object" ? (f.push({}), h.push("")) : (f.push([]), h.push(-1)); + }, O = () => { + h.pop(), l.pop(); + const Q = f.pop(), K = f.at(-1), N = h.at(-1), J = T.at(-1); + J?.level === h.length && (J.deep ? J.deep(Q, J.matches) : J.shallow && J.shallow(Q, J.matches), T.pop()), J?.deep && (Array.isArray(K) ? K.push(Q) : K[N] = Q); + }, g = (Q) => { + h[h.length - 1] = Q; + }, G = (Q) => { + const K = T.at(-1); + if (K?.level === h.length - 1 && K.value) + K.value(Q, K.matches); + else if (K?.level === h.length - 1 && K.shallow || K?.deep) { + const N = f.at(-1); + Array.isArray(N) ? N.push(Q) : N[h.at(-1)] = Q; } }; - return na({ - openArray: M("array"), - openObject: M("object"), - closeArray: C, - closeObject: C, - key: O, - value: z + return aa({ + openArray: D("array"), + openObject: D("object"), + closeArray: O, + closeObject: O, + key: g, + value: G }); } -class ua { +class da { contents; constructor() { this.contents = /* @__PURE__ */ new Map(); } - put(c) { - if (!this.contents.has(c)) { - const a = this.contents.size; - return this.contents.set(c, a), a; + put(l) { + if (!this.contents.has(l)) { + const f = this.contents.size; + return this.contents.set(l, f), f; } - return this.contents.get(c); + return this.contents.get(l); } entries() { - const c = new Array(this.contents.size); - for (const [a, l] of this.contents.entries()) - c[l] = { id: l, value: a }; - return c; + const l = new Array(this.contents.size); + for (const [f, h] of this.contents.entries()) + l[h] = { id: h, value: f }; + return l; } } -class _i { +class Mi { contents; constructor() { this.contents = /* @__PURE__ */ new Map(); } - put(c) { - if (!this.contents.has(c)) { - const a = { id: this.contents.size }; - return this.contents.set(c, a), a; + put(l) { + if (!this.contents.has(l)) { + const f = { id: this.contents.size }; + return this.contents.set(l, f), f; } - return this.contents.get(c); + return this.contents.get(l); } - get(c) { - return this.contents.get(c); + get(l) { + return this.contents.get(l); } entries() { - const c = new Array(this.contents.size); - for (const [a, { id: l }] of this.contents.entries()) - c[l] = { id: l, value: a }; - return c; + const l = new Array(this.contents.size); + for (const [f, { id: h }] of this.contents.entries()) + l[h] = { id: h, value: f }; + return l; } sort() { - const c = Array.from(this.contents.keys()).sort(); - for (const [a, l] of c.entries()) - this.contents.get(l).id = a; + const l = Array.from(this.contents.keys()).sort(); + for (const [f, h] of l.entries()) + this.contents.get(h).id = f; } } -class wi { +class Ri { counter = 0; contents = []; - put(c) { - const a = this.counter; - return this.contents.push({ id: a, value: c }), this.counter++, a; + put(l) { + const f = this.counter; + return this.contents.push({ id: f, value: l }), this.counter++, f; } objects() { return this.contents; @@ -3708,73 +3708,73 @@ class wi { this.contents.length = 0; } } -class bn { +class Ln { contents = []; mutable; sortable; flat = !1; - constructor(c) { - this.contents = [], this.mutable = c.mutable || [], this.sortable = c.sortable || [], this.flat = c.flat || !1; + constructor(l) { + this.contents = [], this.mutable = l.mutable || [], this.sortable = l.sortable || [], this.flat = l.flat || !1; } - put(c, a) { - this.contents.push({ index: c, value: a }); + put(l, f) { + this.contents.push({ index: l, value: f }); } - objects(c) { - return this.contents.map(({ index: a, value: l }) => { - const E = this.mutable.includes("id") ? a.id : a, M = Object.entries(c ? c({ ...l }) : l).map(([O, z]) => z !== void 0 && this.mutable.includes(O) ? [O, z.id] : [O, z]), C = Object.fromEntries(M); - return this.flat ? { id: E, ...C } : { id: E, value: C }; + objects(l) { + return this.contents.map(({ index: f, value: h }) => { + const T = this.mutable.includes("id") ? f.id : f, D = Object.entries(l ? l({ ...h }) : h).map(([g, G]) => G !== void 0 && this.mutable.includes(g) ? [g, G.id] : [g, G]), O = Object.fromEntries(D); + return this.flat ? { id: T, ...O } : { id: T, value: O }; }); } getKeys() { return ["id", ...this.sortable].join(","); } } -function ca(s) { - return Object.fromEntries(Object.entries(s).map(([a, l]) => l instanceof bn ? [a, l.getKeys()] : [a, "id"])); +function pa(u) { + return Object.fromEntries(Object.entries(u).map(([f, h]) => h instanceof Ln ? [f, h.getKeys()] : [f, "id"])); } -function Li() { +function io() { return { - pathIndex: new _i(), - operationIdIndex: new _i(), - testKeyIndex: new ua(), - test: new wi(), - happyPath: new wi(), - operation: new bn({ mutable: ["id"] }), - testIndex: new bn({ + pathIndex: new Mi(), + operationIdIndex: new Mi(), + testKeyIndex: new da(), + test: new Ri(), + happyPath: new Ri(), + operation: new Ln({ mutable: ["id"] }), + testIndex: new Ln({ flat: !0, mutable: ["operationIdIndex", "pathIndex"], sortable: ["pathIndex", "criticality"] }), - happyPathIndex: new bn({ + happyPathIndex: new Ln({ flat: !0, mutable: ["operationIdIndex", "pathIndex"], sortable: ["pathIndex"] }) }; } -class la { +class ya { db; startedPromise; successfullyStarted; failedToStart; happyPathIndex; testIndex; - async start(c) { - this.startedPromise = new Promise((a, l) => { - this.successfullyStarted = a, this.failedToStart = l; + async start(l) { + this.startedPromise = new Promise((f, h) => { + this.successfullyStarted = f, this.failedToStart = h; }); try { try { - await Rt.delete(c); + await on.delete(l); } catch { } - const a = ca(Li()); - this.db = new Rt(c), this.db.version(1).stores({ __metadata: "id", ...a }), await this.db.open(), await this.db.__metadata.clear(); - for (const l of Object.keys(a)) - await this.db[l].clear(); + const f = pa(io()); + this.db = new on(l), this.db.version(1).stores({ __metadata: "id", ...f }), await this.db.open(), await this.db.__metadata.clear(); + for (const h of Object.keys(f)) + await this.db[h].clear(); await this.db.__metadata.put({ id: 0, created: (/* @__PURE__ */ new Date()).toISOString() }), this.successfullyStarted?.(); - } catch (a) { - this.failedToStart?.(a); + } catch (f) { + this.failedToStart?.(f); } } async stop() { @@ -3783,78 +3783,78 @@ class la { started() { return this.startedPromise; } - async save(c, a) { - a.length > 0 && await this.db[c].bulkPut(a); + async save(l, f) { + f.length > 0 && await this.db[l].bulkPut(f); } - async getStrings(c) { - return this.db[c].toArray().then((a) => a.map((l) => ({ - value: l.id, - label: l.value + async getStrings(l) { + return this.db[l].toArray().then((f) => f.map((h) => ({ + value: h.id, + label: h.value }))); } - async getHappyPaths(c, a, l) { - const E = await this.readHappyPathIndex(l), M = []; - for (const Y of E) - M.push(Y); - const C = Pi(M, c, a), O = Math.ceil(M.length / a), z = []; - for (const Y of C) { - const K = await this.db.happyPath.get(Y.id), B = await this.db.operation.get(Y.operationIdIndex), H = await this.db.operationIdIndex.get(Y.operationIdIndex); - z.push({ - operationId: H.value, - operation: B.value, + async getHappyPaths(l, f, h) { + const T = await this.readHappyPathIndex(h), D = []; + for (const Q of T) + D.push(Q); + const O = Fi(D, l, f), g = Math.ceil(D.length / f), G = []; + for (const Q of O) { + const K = await this.db.happyPath.get(Q.id), N = await this.db.operation.get(Q.operationIdIndex), J = await this.db.operationIdIndex.get(Q.operationIdIndex); + G.push({ + operationId: J.value, + operation: N.value, report: K.value }); } return { - items: z, - pages: O, - current: c, - total: M.length + items: G, + pages: g, + current: l, + total: D.length }; } - async getTests(c, a, l, E) { - const M = await this.readTestIndex(l), C = []; - for (const K of M) { - let B = !0; - E.criticality !== void 0 && K.criticality < E.criticality && (B = !1), E.testKey !== void 0 && K.testKeyIndex !== E.testKey && (B = !1), E.path !== void 0 && K.pathIndex !== E.path && (B = !1), E.method !== void 0 && K.methodIndex !== E.method && (B = !1), E.operationId !== void 0 && K.operationIdIndex !== E.operationId && (B = !1), B && C.push(K); + async getTests(l, f, h, T) { + const D = await this.readTestIndex(h), O = []; + for (const K of D) { + let N = !0; + T.criticality !== void 0 && K.criticality < T.criticality && (N = !1), T.testKey !== void 0 && K.testKeyIndex !== T.testKey && (N = !1), T.path !== void 0 && K.pathIndex !== T.path && (N = !1), T.method !== void 0 && K.methodIndex !== T.method && (N = !1), T.operationId !== void 0 && K.operationIdIndex !== T.operationId && (N = !1), N && O.push(K); } - const O = Pi(C, c, a), z = Math.ceil(C.length / a), Y = []; - for (const K of O) { - const B = await this.db.test.get(K.id), H = K.operationIdIndex !== void 0 ? await this.db.operation.get(K.operationIdIndex) : void 0, w = K.operationIdIndex !== void 0 ? await this.db.operationIdIndex.get(K.operationIdIndex) : void 0, ie = K.pathIndex !== void 0 ? await this.db.pathIndex.get(K.pathIndex) : void 0; - Y.push({ - operationId: w?.value, - operation: H?.value, - path: ie?.value, + const g = Fi(O, l, f), G = Math.ceil(O.length / f), Q = []; + for (const K of g) { + const N = await this.db.test.get(K.id), J = K.operationIdIndex !== void 0 ? await this.db.operation.get(K.operationIdIndex) : void 0, b = K.operationIdIndex !== void 0 ? await this.db.operationIdIndex.get(K.operationIdIndex) : void 0, Z = K.pathIndex !== void 0 ? await this.db.pathIndex.get(K.pathIndex) : void 0; + Q.push({ + operationId: b?.value, + operation: J?.value, + path: Z?.value, method: "FOO", // FIXME - test: B.value + test: N.value }); } return { - items: Y, - pages: z, - current: c, - total: C.length + items: Q, + pages: G, + current: l, + total: O.length }; } - async readHappyPathIndex(c) { + async readHappyPathIndex(l) { if (this.happyPathIndex !== void 0) return this.happyPathIndex; - const a = c?.fieldName || "pathIndex", l = await this.db.happyPathIndex.orderBy(a).toArray(); - return c?.order === "desc" && l.reverse(), this.happyPathIndex = l, l; + const f = l?.fieldName || "pathIndex", h = await this.db.happyPathIndex.orderBy(f).toArray(); + return l?.order === "desc" && h.reverse(), this.happyPathIndex = h, h; } - async readTestIndex(c) { + async readTestIndex(l) { if (this.testIndex !== void 0) return this.testIndex; - const a = c?.fieldName || "pathIndex", l = await this.db.testIndex.orderBy(a).toArray(); - return c?.order === "desc" && l.reverse(), this.testIndex = l, l; + const f = l?.fieldName || "pathIndex", h = await this.db.testIndex.orderBy(f).toArray(); + return l?.order === "desc" && h.reverse(), this.testIndex = h, h; } } -function Pi(s, c, a) { - const l = c * a, E = l + a; - return s.slice(l, E); +function Fi(u, l, f) { + const h = l * f, T = h + f; + return u.slice(h, T); } -class da { +class ma { db; parser; methods; @@ -3863,30 +3863,30 @@ class da { summary; stats; operationsMap; - constructor(c) { - this.db = c, this.stores = Li(), this.parser = this.makeParser(), this.methods = Object.fromEntries( - Ai.map((a, l) => [a, l]) + constructor(l) { + this.db = l, this.stores = io(), this.parser = this.makeParser(), this.methods = Object.fromEntries( + Vi.map((f, h) => [f, h]) ), this.scanVersion = "", this.summary = void 0, this.operationsMap = /* @__PURE__ */ new Map(), this.stats = { issues: 0, lowAndAbove: 0, criticalAndHigh: 0 }; } - async parse(c) { - return c !== null ? (this.parser.chunk(c), await this.db.save("happyPath", this.stores.happyPath.objects()), await this.db.save("test", this.stores.test.objects()), this.stores.happyPath.trim(), this.stores.test.trim(), !1) : (await this.db.save("operation", this.stores.operation.objects()), this.stores.operationIdIndex.sort(), this.stores.pathIndex.sort(), await this.db.save("operationIdIndex", this.stores.operationIdIndex.entries()), await this.db.save("pathIndex", this.stores.pathIndex.entries()), await this.db.save("testKeyIndex", this.stores.testKeyIndex.entries()), await this.db.save( + async parse(l) { + return l !== null ? (this.parser.chunk(l), await this.db.save("happyPath", this.stores.happyPath.objects()), await this.db.save("test", this.stores.test.objects()), this.stores.happyPath.trim(), this.stores.test.trim(), !1) : (await this.db.save("operation", this.stores.operation.objects()), this.stores.operationIdIndex.sort(), this.stores.pathIndex.sort(), await this.db.save("operationIdIndex", this.stores.operationIdIndex.entries()), await this.db.save("pathIndex", this.stores.pathIndex.entries()), await this.db.save("testKeyIndex", this.stores.testKeyIndex.entries()), await this.db.save( "testIndex", - this.stores.testIndex.objects((a) => { - if (a.operationIdIndex !== void 0) { - const l = this.operationsMap.get(a.operationIdIndex); - a.pathIndex = l.pathIndex, a.methodIndex = l.methodIndex; + this.stores.testIndex.objects((f) => { + if (f.operationIdIndex !== void 0) { + const h = this.operationsMap.get(f.operationIdIndex); + f.pathIndex = h.pathIndex, f.methodIndex = h.methodIndex; } - return a; + return f; }) ), await this.db.save( "happyPathIndex", - this.stores.happyPathIndex.objects((a) => { - const l = this.operationsMap.get(a.operationIdIndex); - return a.pathIndex = l.pathIndex, a.methodIndex = l.methodIndex, a; + this.stores.happyPathIndex.objects((f) => { + const h = this.operationsMap.get(f.operationIdIndex); + return f.pathIndex = h.pathIndex, f.methodIndex = h.methodIndex, f; }) ), this.parser.end(), this.stores = null, this.operationsMap = null, !0); } @@ -3900,214 +3900,214 @@ class da { return this.stats; } makeParser() { - return oa({ - "$.shallow()": (c) => { - this.scanVersion = c.scanVersion; + return la({ + "$.shallow()": (l) => { + this.scanVersion = l.scanVersion; }, - "$.summary.deep()": (c) => { - this.summary = c; + "$.summary.deep()": (l) => { + this.summary = l; }, - "$.operations.*.shallow()": (c, [a]) => { - this.onOperation(a, c); + "$.operations.*.shallow()": (l, [f]) => { + this.onOperation(f, l); }, - "$.operations.*.scenarios.*.deep()": (c, [a]) => { - this.onHappyPath(a, c); + "$.operations.*.scenarios.*.deep()": (l, [f]) => { + this.onHappyPath(f, l); }, - "$.operations.*.conformanceRequestsResults.*.deep()": (c, [a]) => { - this.onTest(a, "conformance", c); + "$.operations.*.conformanceRequestsResults.*.deep()": (l, [f]) => { + this.onTest(f, "conformance", l); }, - "$.operations.*.authorizationRequestsResults.*.deep()": (c, [a]) => { - this.onTest(a, "authorization", c); + "$.operations.*.authorizationRequestsResults.*.deep()": (l, [f]) => { + this.onTest(f, "authorization", l); }, - "$.operations.*.customRequestsResults.*.deep()": (c, [a]) => { - this.onTest(a, "custom", c); + "$.operations.*.customRequestsResults.*.deep()": (l, [f]) => { + this.onTest(f, "custom", l); }, - "$.methodNotAllowed.*.*.conformanceRequestsResults.*.deep()": (c, [a, l]) => { - this.onMethodNotAllowedTest(a, l, c); + "$.methodNotAllowed.*.*.conformanceRequestsResults.*.deep()": (l, [f, h]) => { + this.onMethodNotAllowedTest(f, h, l); } }); } - onOperation(c, a) { - const l = this.stores.operationIdIndex.put(c); - this.stores.operation.put(l, a), this.operationsMap.set(l, { - pathIndex: this.stores.pathIndex.put(a.path), - methodIndex: this.methods[a.method.toLowerCase()] + onOperation(l, f) { + const h = this.stores.operationIdIndex.put(l); + this.stores.operation.put(h, f), this.operationsMap.set(h, { + pathIndex: this.stores.pathIndex.put(f.path), + methodIndex: this.methods[f.method.toLowerCase()] }); } - onHappyPath(c, a) { - const l = this.stores.happyPath.put(a); - this.stores.happyPathIndex.put(l, { - operationIdIndex: this.stores.operationIdIndex.put(c), + onHappyPath(l, f) { + const h = this.stores.happyPath.put(f); + this.stores.happyPathIndex.put(h, { + operationIdIndex: this.stores.operationIdIndex.put(l), pathIndex: void 0, methodIndex: void 0 }); } - onTest(c, a, l) { - this.updateStats(l); - const E = this.stores.test.put(l), M = this.stores.testKeyIndex.put(l.test?.key), C = this.stores.operationIdIndex.put(c); - this.stores.testIndex.put(E, { - operationIdIndex: C, + onTest(l, f, h) { + this.updateStats(h); + const T = this.stores.test.put(h), D = this.stores.testKeyIndex.put(h.test?.key), O = this.stores.operationIdIndex.put(l); + this.stores.testIndex.put(T, { + operationIdIndex: O, pathIndex: void 0, methodIndex: void 0, - testKeyIndex: M, - criticality: l.outcome?.criticality, - testType: ji[a] + testKeyIndex: D, + criticality: h.outcome?.criticality, + testType: Di[f] }); } - onMethodNotAllowedTest(c, a, l) { - this.updateStats(l); - const E = this.stores.test.put(l), M = this.stores.testKeyIndex.put(l.test?.key), C = this.stores.pathIndex.put(c); - this.stores.testIndex.put(E, { + onMethodNotAllowedTest(l, f, h) { + this.updateStats(h); + const T = this.stores.test.put(h), D = this.stores.testKeyIndex.put(h.test?.key), O = this.stores.pathIndex.put(l); + this.stores.testIndex.put(T, { operationIdIndex: void 0, - pathIndex: C, - methodIndex: this.methods[a.toLowerCase()], - testKeyIndex: M, - criticality: l.outcome?.criticality, - testType: ji.methodNotAllowed + pathIndex: O, + methodIndex: this.methods[f.toLowerCase()], + testKeyIndex: D, + criticality: h.outcome?.criticality, + testType: Di.methodNotAllowed }); } - updateStats(c) { + updateStats(l) { this.stats.issues++; - const a = c.outcome?.criticality; - a !== void 0 && a >= 2 && this.stats.lowAndAbove++, a !== void 0 && a >= 4 && this.stats.criticalAndHigh++; + const f = l.outcome?.criticality; + f !== void 0 && f >= 2 && this.stats.lowAndAbove++, f !== void 0 && f >= 4 && this.stats.criticalAndHigh++; } } -const ji = { +const Di = { methodNotAllowed: 1, conformance: 2, authorization: 3, custom: 4 -}, Hi = qo(), ke = Hi.startListening; -function fa(s, c) { - let a, l; - const E = () => ke({ - actionCreator: Ti, - effect: async (K, B) => { - const { apiAlias: H } = K.payload; - a !== void 0 && a.stop(), a = new la(), l = new da(a), a.start(`scanv2-report-${H}`); +}, oo = Ho(), Je = oo.startListening; +function ga(u, l) { + let f, h; + const T = () => Je({ + actionCreator: Gi, + effect: async (K, N) => { + const { apiAlias: J } = K.payload; + f !== void 0 && f.stop(), f = new ya(), h = new ma(f), f.start(`scanv2-report-${J}`); } - }), M = () => ke({ - actionCreator: Ni, - effect: async (K, B) => { + }), D = () => Je({ + actionCreator: Zi, + effect: async (K, N) => { try { - await a.started(); - const H = await l.parse(K.payload); - B.dispatch(ai()), H && (B.dispatch(fr(0)), B.dispatch(hr(0))); - } catch (H) { - B.dispatch( - Ki({ message: `Error when processing the report: ${H}` }) + await f.started(); + const J = await h.parse(K.payload); + N.dispatch(xi()), J && (N.dispatch(Mr(0)), N.dispatch(Rr(0))); + } catch (J) { + N.dispatch( + Ji({ message: `Error when processing the report: ${J}` }) ); } } - }), C = () => ke({ - actionCreator: fr, - effect: async (K, B) => { - const H = await a.getHappyPaths(K.payload, 100, void 0); - B.dispatch(gs(H)), B.dispatch( - bs({ - scanVersion: l.getScanVersion(), - summary: l.getSummary(), - stats: l.getStats(), - paths: await a.getStrings("pathIndex"), - operationIds: await a.getStrings("operationIdIndex"), - testKeys: await a.getStrings("testKeyIndex") + }), O = () => Je({ + actionCreator: Mr, + effect: async (K, N) => { + const J = await f.getHappyPaths(K.payload, 100, void 0); + N.dispatch(Es(J)), N.dispatch( + Is({ + scanVersion: h.getScanVersion(), + summary: h.getSummary(), + stats: h.getStats(), + paths: await f.getStrings("pathIndex"), + operationIds: await f.getStrings("operationIdIndex"), + testKeys: await f.getStrings("testKeyIndex") }) ); } - }), O = () => ke({ - actionCreator: hr, - effect: async (K, B) => { + }), g = () => Je({ + actionCreator: Rr, + effect: async (K, N) => { const { - scan: { filter: H } - } = B.getState(), w = await a.getTests(K.payload, 100, void 0, H); - B.dispatch(ui(w)); + scan: { filter: J } + } = N.getState(), b = await f.getTests(K.payload, 100, void 0, J); + N.dispatch(wi(b)); } - }), z = () => ke({ - actionCreator: ye, - effect: async (K, B) => { + }), G = () => Je({ + actionCreator: Fe, + effect: async (K, N) => { const { - scan: { filter: H } - } = B.getState(), w = await a.getTests(0, 100, void 0, H); - B.dispatch(ui(w)); + scan: { filter: J } + } = N.getState(), b = await f.getTests(0, 100, void 0, J); + N.dispatch(wi(b)); } - }), Y = { - started: () => ke({ - actionCreator: mr, - effect: async (K, B) => { - s.postMessage({ command: "started", payload: crypto.randomUUID() }); + }), Q = { + started: () => Je({ + actionCreator: Kr, + effect: async (K, N) => { + u.postMessage({ command: "started", payload: crypto.randomUUID() }); } }), - parseChunkCompleted: () => ke({ - actionCreator: ai, - effect: async (K, B) => { - s.postMessage({ command: "parseChunkCompleted", payload: void 0 }); + parseChunkCompleted: () => Je({ + actionCreator: xi, + effect: async (K, N) => { + u.postMessage({ command: "parseChunkCompleted", payload: void 0 }); } }), - sendCurlRequest: () => ke({ - actionCreator: Di, - effect: async (K, B) => { - s.postMessage({ + sendCurlRequest: () => Je({ + actionCreator: Xi, + effect: async (K, N) => { + u.postMessage({ command: "sendCurlRequest", payload: K.payload }); } }), - showJsonPointer: () => ke({ - actionCreator: Ri, - effect: async (K, B) => { - s.postMessage({ + showJsonPointer: () => Je({ + actionCreator: Qi, + effect: async (K, N) => { + u.postMessage({ command: "showJsonPointer", payload: K.payload }); } }) }; - return es(ke, c), Bo({ - ...Y, - onShowScanReport: E, - onParseChunk: M, - onLoadHappyPathPage: C, - onLoadTestsPage: O, - onChangeFilter: z - }), Hi; + return os(Je, l), Yo({ + ...Q, + onShowScanReport: T, + onParseChunk: D, + onLoadHappyPathPage: O, + onLoadTestsPage: g, + onChangeFilter: G + }), oo; } -function ha() { - const s = Oi(); - return pt.useEffect(() => { - s(mr()); - }, [s]), /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(Fo, {}), - /* @__PURE__ */ f.jsx($o, {}) +function va() { + const u = zi(); + return Nt.useEffect(() => { + u(Kr()); + }, [u]), /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(zo, {}), + /* @__PURE__ */ m.jsx(Vo, {}) ] }); } -function pa() { - const c = Bi((C) => C.logging.messages).filter((C) => !0), a = pt.useRef(null), [l, E] = pt.useState(!1); - if (pt.useEffect(() => { - a.current && !l && (a.current.scrollTop = a.current.scrollHeight); - }, [c, l]), c.length === 0) +function ba() { + const l = to((O) => O.logging.messages).filter((O) => !0), f = Nt.useRef(null), [h, T] = Nt.useState(!1); + if (Nt.useEffect(() => { + f.current && !h && (f.current.scrollTop = f.current.scrollHeight); + }, [l, h]), l.length === 0) return null; - const M = () => { - const C = a.current; - if (C) { - const O = C.scrollTop, z = C.scrollHeight, Y = C.clientHeight; - z - (O + Y) < 10 ? E(!1) : E(!0); + const D = () => { + const O = f.current; + if (O) { + const g = O.scrollTop, G = O.scrollHeight, Q = O.clientHeight; + G - (g + Q) < 10 ? T(!1) : T(!0); } }; - return /* @__PURE__ */ f.jsx(ga, { children: /* @__PURE__ */ f.jsx(ma, { ref: a, onScroll: M, children: c.map((C, O, z) => /* @__PURE__ */ f.jsxs("div", { children: [ - /* @__PURE__ */ f.jsx(ya, { first: O === 0, last: O === z.length - 1 }), - /* @__PURE__ */ f.jsx("div", { children: C.message }) - ] }, O)) }) }); + return /* @__PURE__ */ m.jsx(Ea, { children: /* @__PURE__ */ m.jsx(wa, { ref: f, onScroll: D, children: l.map((O, g, G) => /* @__PURE__ */ m.jsxs("div", { children: [ + /* @__PURE__ */ m.jsx(xa, { first: g === 0, last: g === G.length - 1 }), + /* @__PURE__ */ m.jsx("div", { children: O.message }) + ] }, g)) }) }); } -function ya({ first: s, last: c }) { - return /* @__PURE__ */ f.jsxs(va, { $first: s, $last: c, children: [ - /* @__PURE__ */ f.jsx("div", {}), - /* @__PURE__ */ f.jsx("div", {}), - /* @__PURE__ */ f.jsx("div", {}) +function xa({ first: u, last: l }) { + return /* @__PURE__ */ m.jsxs(_a, { $first: u, $last: l, children: [ + /* @__PURE__ */ m.jsx("div", {}), + /* @__PURE__ */ m.jsx("div", {}), + /* @__PURE__ */ m.jsx("div", {}) ] }); } -const ma = V.div` - color: var(${Q.foreground}); - background-color: var(${Q.background}); +const wa = te.div` + color: var(${re.foreground}); + background-color: var(${re.background}); line-break: anywhere; overflow-y: scroll; max-height: 200px; @@ -4120,7 +4120,7 @@ const ma = V.div` padding: 4px 0px 4px 4px; } } -`, va = V.div` +`, _a = te.div` display: flex; flex-flow: column; align-items: center; @@ -4128,11 +4128,11 @@ const ma = V.div` > div:first-child { width: 1px; height: 8px; - ${({ $first: s }) => !s && `background-color: var(${Q.border});`} + ${({ $first: u }) => !u && `background-color: var(${re.border});`} } > div:nth-child(2) { - background-color: var(${Q.border}); - border: 1px solid var(${Q.border}); + background-color: var(${re.border}); + border: 1px solid var(${re.border}); border-radius: 50%; width: 6px; height: 6px; @@ -4140,25 +4140,25 @@ const ma = V.div` > div:last-child { flex: 1; width: 1px; - ${({ $last: s }) => !s && `background-color: var(${Q.border});`} + ${({ $last: u }) => !u && `background-color: var(${re.border});`} } -`, ga = V.div` +`, Ea = te.div` padding: 8px; margin: 8px; border-radius: 2px; - border: 1px solid var(${Q.border}); + border: 1px solid var(${re.border}); `; -function ba() { - const s = be((c) => c.scan.error); - return s ? /* @__PURE__ */ f.jsx(_a, { children: /* @__PURE__ */ f.jsxs(xa, { children: [ - /* @__PURE__ */ f.jsx("div", { children: s.message }), - s.details && /* @__PURE__ */ f.jsx("div", { children: s.details }) +function Ia() { + const u = $e((l) => l.scan.error); + return u ? /* @__PURE__ */ m.jsx(ja, { children: /* @__PURE__ */ m.jsxs(Pa, { children: [ + /* @__PURE__ */ m.jsx("div", { children: u.message }), + u.details && /* @__PURE__ */ m.jsx("div", { children: u.details }) ] }) }) : null; } -const xa = V.div` - border: 1px solid var(${Q.errorBorder}); - color: var(${Q.errorForeground}); - background-color: var(${Q.errorBackground}); +const Pa = te.div` + border: 1px solid var(${re.errorBorder}); + color: var(${re.errorForeground}); + background-color: var(${re.errorBackground}); margin-top: 1rem; margin-bottom: 1rem; padding: 0.75rem; @@ -4166,26 +4166,26 @@ const xa = V.div` > div { font-family: monospace; } -`, _a = V.div` +`, ja = te.div` padding: 8px; `; -function wa() { - const c = Bi((a) => a.logging.messages).filter((a) => !0); - return c.length === 0 ? null : /* @__PURE__ */ f.jsx(ja, { children: c.map((a, l, E) => /* @__PURE__ */ f.jsxs("div", { children: [ - /* @__PURE__ */ f.jsx(Pa, { first: l === 0, last: l === E.length - 1 }), - /* @__PURE__ */ f.jsx("div", { children: a.message }) - ] }, l)) }); +function ka() { + const l = to((f) => f.logging.messages).filter((f) => !0); + return l.length === 0 ? null : /* @__PURE__ */ m.jsx(Ca, { children: l.map((f, h, T) => /* @__PURE__ */ m.jsxs("div", { children: [ + /* @__PURE__ */ m.jsx(Sa, { first: h === 0, last: h === T.length - 1 }), + /* @__PURE__ */ m.jsx("div", { children: f.message }) + ] }, h)) }); } -function Pa({ first: s, last: c }) { - return /* @__PURE__ */ f.jsxs(ka, { $first: s, $last: c, children: [ - /* @__PURE__ */ f.jsx("div", {}), - /* @__PURE__ */ f.jsx("div", {}), - /* @__PURE__ */ f.jsx("div", {}) +function Sa({ first: u, last: l }) { + return /* @__PURE__ */ m.jsxs(Aa, { $first: u, $last: l, children: [ + /* @__PURE__ */ m.jsx("div", {}), + /* @__PURE__ */ m.jsx("div", {}), + /* @__PURE__ */ m.jsx("div", {}) ] }); } -const ja = V.div` - color: var(${Q.foreground}); - background-color: var(${Q.background}); +const Ca = te.div` + color: var(${re.foreground}); + background-color: var(${re.background}); line-break: anywhere; padding: 8px; @@ -4197,7 +4197,7 @@ const ja = V.div` padding: 4px 0px 4px 4px; } } -`, ka = V.div` +`, Aa = te.div` display: flex; flex-flow: column; align-items: center; @@ -4205,11 +4205,11 @@ const ja = V.div` > div:first-child { width: 1px; height: 8px; - ${({ $first: s }) => !s && `background-color: var(${Q.border});`} + ${({ $first: u }) => !u && `background-color: var(${re.border});`} } > div:nth-child(2) { - background-color: var(${Q.border}); - border: 1px solid var(${Q.border}); + background-color: var(${re.border}); + border: 1px solid var(${re.border}); border-radius: 50%; width: 6px; height: 6px; @@ -4217,33 +4217,1048 @@ const ja = V.div` > div:last-child { flex: 1; width: 1px; - ${({ $last: s }) => !s && `background-color: var(${Q.border});`} + ${({ $last: u }) => !u && `background-color: var(${re.border});`} } `; -var Sa = Go(); -function L(s) { - s === void 0 || this.initialize(s), this.maxHeaderSize = L.maxHeaderSize; +var Tr = {}, tn = {}, Ki; +function Ba() { + if (Ki) return tn; + Ki = 1, tn.byteLength = g, tn.toByteArray = Q, tn.fromByteArray = J; + for (var u = [], l = [], f = typeof Uint8Array < "u" ? Uint8Array : Array, h = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", T = 0, D = h.length; T < D; ++T) + u[T] = h[T], l[h.charCodeAt(T)] = T; + l[45] = 62, l[95] = 63; + function O(b) { + var Z = b.length; + if (Z % 4 > 0) + throw new Error("Invalid string. Length must be a multiple of 4"); + var ue = b.indexOf("="); + ue === -1 && (ue = Z); + var xe = ue === Z ? 0 : 4 - ue % 4; + return [ue, xe]; + } + function g(b) { + var Z = O(b), ue = Z[0], xe = Z[1]; + return (ue + xe) * 3 / 4 - xe; + } + function G(b, Z, ue) { + return (Z + ue) * 3 / 4 - ue; + } + function Q(b) { + var Z, ue = O(b), xe = ue[0], ve = ue[1], ye = new f(G(b, xe, ve)), Pe = 0, Ke = ve > 0 ? xe - 4 : xe, be; + for (be = 0; be < Ke; be += 4) + Z = l[b.charCodeAt(be)] << 18 | l[b.charCodeAt(be + 1)] << 12 | l[b.charCodeAt(be + 2)] << 6 | l[b.charCodeAt(be + 3)], ye[Pe++] = Z >> 16 & 255, ye[Pe++] = Z >> 8 & 255, ye[Pe++] = Z & 255; + return ve === 2 && (Z = l[b.charCodeAt(be)] << 2 | l[b.charCodeAt(be + 1)] >> 4, ye[Pe++] = Z & 255), ve === 1 && (Z = l[b.charCodeAt(be)] << 10 | l[b.charCodeAt(be + 1)] << 4 | l[b.charCodeAt(be + 2)] >> 2, ye[Pe++] = Z >> 8 & 255, ye[Pe++] = Z & 255), ye; + } + function K(b) { + return u[b >> 18 & 63] + u[b >> 12 & 63] + u[b >> 6 & 63] + u[b & 63]; + } + function N(b, Z, ue) { + for (var xe, ve = [], ye = Z; ye < ue; ye += 3) + xe = (b[ye] << 16 & 16711680) + (b[ye + 1] << 8 & 65280) + (b[ye + 2] & 255), ve.push(K(xe)); + return ve.join(""); + } + function J(b) { + for (var Z, ue = b.length, xe = ue % 3, ve = [], ye = 16383, Pe = 0, Ke = ue - xe; Pe < Ke; Pe += ye) + ve.push(N(b, Pe, Pe + ye > Ke ? Ke : Pe + ye)); + return xe === 1 ? (Z = b[ue - 1], ve.push( + u[Z >> 2] + u[Z << 4 & 63] + "==" + )) : xe === 2 && (Z = (b[ue - 2] << 8) + b[ue - 1], ve.push( + u[Z >> 10] + u[Z >> 4 & 63] + u[Z << 2 & 63] + "=" + )), ve.join(""); + } + return tn; +} +var Nn = {}; +var Ni; +function Oa() { + return Ni || (Ni = 1, Nn.read = function(u, l, f, h, T) { + var D, O, g = T * 8 - h - 1, G = (1 << g) - 1, Q = G >> 1, K = -7, N = f ? T - 1 : 0, J = f ? -1 : 1, b = u[l + N]; + for (N += J, D = b & (1 << -K) - 1, b >>= -K, K += g; K > 0; D = D * 256 + u[l + N], N += J, K -= 8) + ; + for (O = D & (1 << -K) - 1, D >>= -K, K += h; K > 0; O = O * 256 + u[l + N], N += J, K -= 8) + ; + if (D === 0) + D = 1 - Q; + else { + if (D === G) + return O ? NaN : (b ? -1 : 1) * (1 / 0); + O = O + Math.pow(2, h), D = D - Q; + } + return (b ? -1 : 1) * O * Math.pow(2, D - h); + }, Nn.write = function(u, l, f, h, T, D) { + var O, g, G, Q = D * 8 - T - 1, K = (1 << Q) - 1, N = K >> 1, J = T === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, b = h ? 0 : D - 1, Z = h ? 1 : -1, ue = l < 0 || l === 0 && 1 / l < 0 ? 1 : 0; + for (l = Math.abs(l), isNaN(l) || l === 1 / 0 ? (g = isNaN(l) ? 1 : 0, O = K) : (O = Math.floor(Math.log(l) / Math.LN2), l * (G = Math.pow(2, -O)) < 1 && (O--, G *= 2), O + N >= 1 ? l += J / G : l += J * Math.pow(2, 1 - N), l * G >= 2 && (O++, G /= 2), O + N >= K ? (g = 0, O = K) : O + N >= 1 ? (g = (l * G - 1) * Math.pow(2, T), O = O + N) : (g = l * Math.pow(2, N - 1) * Math.pow(2, T), O = 0)); T >= 8; u[f + b] = g & 255, b += Z, g /= 256, T -= 8) + ; + for (O = O << T | g, Q += T; Q > 0; u[f + b] = O & 255, b += Z, O /= 256, Q -= 8) + ; + u[f + b - Z] |= ue * 128; + }), Nn; } -L.prototype.initialize = function(s, c) { - this.type = s, this.state = s + "_LINE", this.info = { +var qi; +function Ta() { + return qi || (qi = 1, (function(u) { + const l = Ba(), f = Oa(), h = typeof Symbol == "function" && typeof Symbol.for == "function" ? /* @__PURE__ */ Symbol.for("nodejs.util.inspect.custom") : null; + u.Buffer = g, u.SlowBuffer = ye, u.INSPECT_MAX_BYTES = 50; + const T = 2147483647; + u.kMaxLength = T, g.TYPED_ARRAY_SUPPORT = D(), !g.TYPED_ARRAY_SUPPORT && typeof console < "u" && typeof console.error == "function" && console.error( + "This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support." + ); + function D() { + try { + const c = new Uint8Array(1), r = { foo: function() { + return 42; + } }; + return Object.setPrototypeOf(r, Uint8Array.prototype), Object.setPrototypeOf(c, r), c.foo() === 42; + } catch { + return !1; + } + } + Object.defineProperty(g.prototype, "parent", { + enumerable: !0, + get: function() { + if (g.isBuffer(this)) + return this.buffer; + } + }), Object.defineProperty(g.prototype, "offset", { + enumerable: !0, + get: function() { + if (g.isBuffer(this)) + return this.byteOffset; + } + }); + function O(c) { + if (c > T) + throw new RangeError('The value "' + c + '" is invalid for option "size"'); + const r = new Uint8Array(c); + return Object.setPrototypeOf(r, g.prototype), r; + } + function g(c, r, i) { + if (typeof c == "number") { + if (typeof r == "string") + throw new TypeError( + 'The "string" argument must be of type string. Received type number' + ); + return N(c); + } + return G(c, r, i); + } + g.poolSize = 8192; + function G(c, r, i) { + if (typeof c == "string") + return J(c, r); + if (ArrayBuffer.isView(c)) + return Z(c); + if (c == null) + throw new TypeError( + "The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof c + ); + if (Ne(c, ArrayBuffer) || c && Ne(c.buffer, ArrayBuffer) || typeof SharedArrayBuffer < "u" && (Ne(c, SharedArrayBuffer) || c && Ne(c.buffer, SharedArrayBuffer))) + return ue(c, r, i); + if (typeof c == "number") + throw new TypeError( + 'The "value" argument must not be of type number. Received type number' + ); + const p = c.valueOf && c.valueOf(); + if (p != null && p !== c) + return g.from(p, r, i); + const E = xe(c); + if (E) return E; + if (typeof Symbol < "u" && Symbol.toPrimitive != null && typeof c[Symbol.toPrimitive] == "function") + return g.from(c[Symbol.toPrimitive]("string"), r, i); + throw new TypeError( + "The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof c + ); + } + g.from = function(c, r, i) { + return G(c, r, i); + }, Object.setPrototypeOf(g.prototype, Uint8Array.prototype), Object.setPrototypeOf(g, Uint8Array); + function Q(c) { + if (typeof c != "number") + throw new TypeError('"size" argument must be of type number'); + if (c < 0) + throw new RangeError('The value "' + c + '" is invalid for option "size"'); + } + function K(c, r, i) { + return Q(c), c <= 0 ? O(c) : r !== void 0 ? typeof i == "string" ? O(c).fill(r, i) : O(c).fill(r) : O(c); + } + g.alloc = function(c, r, i) { + return K(c, r, i); + }; + function N(c) { + return Q(c), O(c < 0 ? 0 : ve(c) | 0); + } + g.allocUnsafe = function(c) { + return N(c); + }, g.allocUnsafeSlow = function(c) { + return N(c); + }; + function J(c, r) { + if ((typeof r != "string" || r === "") && (r = "utf8"), !g.isEncoding(r)) + throw new TypeError("Unknown encoding: " + r); + const i = Pe(c, r) | 0; + let p = O(i); + const E = p.write(c, r); + return E !== i && (p = p.slice(0, E)), p; + } + function b(c) { + const r = c.length < 0 ? 0 : ve(c.length) | 0, i = O(r); + for (let p = 0; p < r; p += 1) + i[p] = c[p] & 255; + return i; + } + function Z(c) { + if (Ne(c, Uint8Array)) { + const r = new Uint8Array(c); + return ue(r.buffer, r.byteOffset, r.byteLength); + } + return b(c); + } + function ue(c, r, i) { + if (r < 0 || c.byteLength < r) + throw new RangeError('"offset" is outside of buffer bounds'); + if (c.byteLength < r + (i || 0)) + throw new RangeError('"length" is outside of buffer bounds'); + let p; + return r === void 0 && i === void 0 ? p = new Uint8Array(c) : i === void 0 ? p = new Uint8Array(c, r) : p = new Uint8Array(c, r, i), Object.setPrototypeOf(p, g.prototype), p; + } + function xe(c) { + if (g.isBuffer(c)) { + const r = ve(c.length) | 0, i = O(r); + return i.length === 0 || c.copy(i, 0, 0, r), i; + } + if (c.length !== void 0) + return typeof c.length != "number" || nt(c.length) ? O(0) : b(c); + if (c.type === "Buffer" && Array.isArray(c.data)) + return b(c.data); + } + function ve(c) { + if (c >= T) + throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + T.toString(16) + " bytes"); + return c | 0; + } + function ye(c) { + return +c != c && (c = 0), g.alloc(+c); + } + g.isBuffer = function(r) { + return r != null && r._isBuffer === !0 && r !== g.prototype; + }, g.compare = function(r, i) { + if (Ne(r, Uint8Array) && (r = g.from(r, r.offset, r.byteLength)), Ne(i, Uint8Array) && (i = g.from(i, i.offset, i.byteLength)), !g.isBuffer(r) || !g.isBuffer(i)) + throw new TypeError( + 'The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array' + ); + if (r === i) return 0; + let p = r.length, E = i.length; + for (let A = 0, R = Math.min(p, E); A < R; ++A) + if (r[A] !== i[A]) { + p = r[A], E = i[A]; + break; + } + return p < E ? -1 : E < p ? 1 : 0; + }, g.isEncoding = function(r) { + switch (String(r).toLowerCase()) { + case "hex": + case "utf8": + case "utf-8": + case "ascii": + case "latin1": + case "binary": + case "base64": + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return !0; + default: + return !1; + } + }, g.concat = function(r, i) { + if (!Array.isArray(r)) + throw new TypeError('"list" argument must be an Array of Buffers'); + if (r.length === 0) + return g.alloc(0); + let p; + if (i === void 0) + for (i = 0, p = 0; p < r.length; ++p) + i += r[p].length; + const E = g.allocUnsafe(i); + let A = 0; + for (p = 0; p < r.length; ++p) { + let R = r[p]; + if (Ne(R, Uint8Array)) + A + R.length > E.length ? (g.isBuffer(R) || (R = g.from(R)), R.copy(E, A)) : Uint8Array.prototype.set.call( + E, + R, + A + ); + else if (g.isBuffer(R)) + R.copy(E, A); + else + throw new TypeError('"list" argument must be an Array of Buffers'); + A += R.length; + } + return E; + }; + function Pe(c, r) { + if (g.isBuffer(c)) + return c.length; + if (ArrayBuffer.isView(c) || Ne(c, ArrayBuffer)) + return c.byteLength; + if (typeof c != "string") + throw new TypeError( + 'The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ' + typeof c + ); + const i = c.length, p = arguments.length > 2 && arguments[2] === !0; + if (!p && i === 0) return 0; + let E = !1; + for (; ; ) + switch (r) { + case "ascii": + case "latin1": + case "binary": + return i; + case "utf8": + case "utf-8": + return Ht(c).length; + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return i * 2; + case "hex": + return i >>> 1; + case "base64": + return Ct(c).length; + default: + if (E) + return p ? -1 : Ht(c).length; + r = ("" + r).toLowerCase(), E = !0; + } + } + g.byteLength = Pe; + function Ke(c, r, i) { + let p = !1; + if ((r === void 0 || r < 0) && (r = 0), r > this.length || ((i === void 0 || i > this.length) && (i = this.length), i <= 0) || (i >>>= 0, r >>>= 0, i <= r)) + return ""; + for (c || (c = "utf8"); ; ) + switch (c) { + case "hex": + return at(this, r, i); + case "utf8": + case "utf-8": + return ln(this, r, i); + case "ascii": + return Vn(this, r, i); + case "latin1": + case "binary": + return Xe(this, r, i); + case "base64": + return Qe(this, r, i); + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return ze(this, r, i); + default: + if (p) throw new TypeError("Unknown encoding: " + c); + c = (c + "").toLowerCase(), p = !0; + } + } + g.prototype._isBuffer = !0; + function be(c, r, i) { + const p = c[r]; + c[r] = c[i], c[i] = p; + } + g.prototype.swap16 = function() { + const r = this.length; + if (r % 2 !== 0) + throw new RangeError("Buffer size must be a multiple of 16-bits"); + for (let i = 0; i < r; i += 2) + be(this, i, i + 1); + return this; + }, g.prototype.swap32 = function() { + const r = this.length; + if (r % 4 !== 0) + throw new RangeError("Buffer size must be a multiple of 32-bits"); + for (let i = 0; i < r; i += 4) + be(this, i, i + 3), be(this, i + 1, i + 2); + return this; + }, g.prototype.swap64 = function() { + const r = this.length; + if (r % 8 !== 0) + throw new RangeError("Buffer size must be a multiple of 64-bits"); + for (let i = 0; i < r; i += 8) + be(this, i, i + 7), be(this, i + 1, i + 6), be(this, i + 2, i + 5), be(this, i + 3, i + 4); + return this; + }, g.prototype.toString = function() { + const r = this.length; + return r === 0 ? "" : arguments.length === 0 ? ln(this, 0, r) : Ke.apply(this, arguments); + }, g.prototype.toLocaleString = g.prototype.toString, g.prototype.equals = function(r) { + if (!g.isBuffer(r)) throw new TypeError("Argument must be a Buffer"); + return this === r ? !0 : g.compare(this, r) === 0; + }, g.prototype.inspect = function() { + let r = ""; + const i = u.INSPECT_MAX_BYTES; + return r = this.toString("hex", 0, i).replace(/(.{2})/g, "$1 ").trim(), this.length > i && (r += " ... "), ""; + }, h && (g.prototype[h] = g.prototype.inspect), g.prototype.compare = function(r, i, p, E, A) { + if (Ne(r, Uint8Array) && (r = g.from(r, r.offset, r.byteLength)), !g.isBuffer(r)) + throw new TypeError( + 'The "target" argument must be one of type Buffer or Uint8Array. Received type ' + typeof r + ); + if (i === void 0 && (i = 0), p === void 0 && (p = r ? r.length : 0), E === void 0 && (E = 0), A === void 0 && (A = this.length), i < 0 || p > r.length || E < 0 || A > this.length) + throw new RangeError("out of range index"); + if (E >= A && i >= p) + return 0; + if (E >= A) + return -1; + if (i >= p) + return 1; + if (i >>>= 0, p >>>= 0, E >>>= 0, A >>>= 0, this === r) return 0; + let R = A - E, oe = p - i; + const de = Math.min(R, oe), L = this.slice(E, A), pe = r.slice(i, p); + for (let ce = 0; ce < de; ++ce) + if (L[ce] !== pe[ce]) { + R = L[ce], oe = pe[ce]; + break; + } + return R < oe ? -1 : oe < R ? 1 : 0; + }; + function Le(c, r, i, p, E) { + if (c.length === 0) return -1; + if (typeof i == "string" ? (p = i, i = 0) : i > 2147483647 ? i = 2147483647 : i < -2147483648 && (i = -2147483648), i = +i, nt(i) && (i = E ? 0 : c.length - 1), i < 0 && (i = c.length + i), i >= c.length) { + if (E) return -1; + i = c.length - 1; + } else if (i < 0) + if (E) i = 0; + else return -1; + if (typeof r == "string" && (r = g.from(r, p)), g.isBuffer(r)) + return r.length === 0 ? -1 : Ce(c, r, i, p, E); + if (typeof r == "number") + return r = r & 255, typeof Uint8Array.prototype.indexOf == "function" ? E ? Uint8Array.prototype.indexOf.call(c, r, i) : Uint8Array.prototype.lastIndexOf.call(c, r, i) : Ce(c, [r], i, p, E); + throw new TypeError("val must be string, number or Buffer"); + } + function Ce(c, r, i, p, E) { + let A = 1, R = c.length, oe = r.length; + if (p !== void 0 && (p = String(p).toLowerCase(), p === "ucs2" || p === "ucs-2" || p === "utf16le" || p === "utf-16le")) { + if (c.length < 2 || r.length < 2) + return -1; + A = 2, R /= 2, oe /= 2, i /= 2; + } + function de(pe, ce) { + return A === 1 ? pe[ce] : pe.readUInt16BE(ce * A); + } + let L; + if (E) { + let pe = -1; + for (L = i; L < R; L++) + if (de(c, L) === de(r, pe === -1 ? 0 : L - pe)) { + if (pe === -1 && (pe = L), L - pe + 1 === oe) return pe * A; + } else + pe !== -1 && (L -= L - pe), pe = -1; + } else + for (i + oe > R && (i = R - oe), L = i; L >= 0; L--) { + let pe = !0; + for (let ce = 0; ce < oe; ce++) + if (de(c, L + ce) !== de(r, ce)) { + pe = !1; + break; + } + if (pe) return L; + } + return -1; + } + g.prototype.includes = function(r, i, p) { + return this.indexOf(r, i, p) !== -1; + }, g.prototype.indexOf = function(r, i, p) { + return Le(this, r, i, p, !0); + }, g.prototype.lastIndexOf = function(r, i, p) { + return Le(this, r, i, p, !1); + }; + function an(c, r, i, p) { + i = Number(i) || 0; + const E = c.length - i; + p ? (p = Number(p), p > E && (p = E)) : p = E; + const A = r.length; + p > A / 2 && (p = A / 2); + let R; + for (R = 0; R < p; ++R) { + const oe = parseInt(r.substr(R * 2, 2), 16); + if (nt(oe)) return R; + c[i + R] = oe; + } + return R; + } + function zn(c, r, i, p) { + return Me(Ht(r, c.length - i), c, i, p); + } + function un(c, r, i, p) { + return Me(Gn(r), c, i, p); + } + function cn(c, r, i, p) { + return Me(Ct(r), c, i, p); + } + function mt(c, r, i, p) { + return Me(Jn(r, c.length - i), c, i, p); + } + g.prototype.write = function(r, i, p, E) { + if (i === void 0) + E = "utf8", p = this.length, i = 0; + else if (p === void 0 && typeof i == "string") + E = i, p = this.length, i = 0; + else if (isFinite(i)) + i = i >>> 0, isFinite(p) ? (p = p >>> 0, E === void 0 && (E = "utf8")) : (E = p, p = void 0); + else + throw new Error( + "Buffer.write(string, encoding, offset[, length]) is no longer supported" + ); + const A = this.length - i; + if ((p === void 0 || p > A) && (p = A), r.length > 0 && (p < 0 || i < 0) || i > this.length) + throw new RangeError("Attempt to write outside buffer bounds"); + E || (E = "utf8"); + let R = !1; + for (; ; ) + switch (E) { + case "hex": + return an(this, r, i, p); + case "utf8": + case "utf-8": + return zn(this, r, i, p); + case "ascii": + case "latin1": + case "binary": + return un(this, r, i, p); + case "base64": + return cn(this, r, i, p); + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return mt(this, r, i, p); + default: + if (R) throw new TypeError("Unknown encoding: " + E); + E = ("" + E).toLowerCase(), R = !0; + } + }, g.prototype.toJSON = function() { + return { + type: "Buffer", + data: Array.prototype.slice.call(this._arr || this, 0) + }; + }; + function Qe(c, r, i) { + return r === 0 && i === c.length ? l.fromByteArray(c) : l.fromByteArray(c.slice(r, i)); + } + function ln(c, r, i) { + i = Math.min(c.length, i); + const p = []; + let E = r; + for (; E < i; ) { + const A = c[E]; + let R = null, oe = A > 239 ? 4 : A > 223 ? 3 : A > 191 ? 2 : 1; + if (E + oe <= i) { + let de, L, pe, ce; + switch (oe) { + case 1: + A < 128 && (R = A); + break; + case 2: + de = c[E + 1], (de & 192) === 128 && (ce = (A & 31) << 6 | de & 63, ce > 127 && (R = ce)); + break; + case 3: + de = c[E + 1], L = c[E + 2], (de & 192) === 128 && (L & 192) === 128 && (ce = (A & 15) << 12 | (de & 63) << 6 | L & 63, ce > 2047 && (ce < 55296 || ce > 57343) && (R = ce)); + break; + case 4: + de = c[E + 1], L = c[E + 2], pe = c[E + 3], (de & 192) === 128 && (L & 192) === 128 && (pe & 192) === 128 && (ce = (A & 15) << 18 | (de & 63) << 12 | (L & 63) << 6 | pe & 63, ce > 65535 && ce < 1114112 && (R = ce)); + } + } + R === null ? (R = 65533, oe = 1) : R > 65535 && (R -= 65536, p.push(R >>> 10 & 1023 | 55296), R = 56320 | R & 1023), p.push(R), E += oe; + } + return Ut(p); + } + const jt = 4096; + function Ut(c) { + const r = c.length; + if (r <= jt) + return String.fromCharCode.apply(String, c); + let i = "", p = 0; + for (; p < r; ) + i += String.fromCharCode.apply( + String, + c.slice(p, p += jt) + ); + return i; + } + function Vn(c, r, i) { + let p = ""; + i = Math.min(c.length, i); + for (let E = r; E < i; ++E) + p += String.fromCharCode(c[E] & 127); + return p; + } + function Xe(c, r, i) { + let p = ""; + i = Math.min(c.length, i); + for (let E = r; E < i; ++E) + p += String.fromCharCode(c[E]); + return p; + } + function at(c, r, i) { + const p = c.length; + (!r || r < 0) && (r = 0), (!i || i < 0 || i > p) && (i = p); + let E = ""; + for (let A = r; A < i; ++A) + E += fn[c[A]]; + return E; + } + function ze(c, r, i) { + const p = c.slice(r, i); + let E = ""; + for (let A = 0; A < p.length - 1; A += 2) + E += String.fromCharCode(p[A] + p[A + 1] * 256); + return E; + } + g.prototype.slice = function(r, i) { + const p = this.length; + r = ~~r, i = i === void 0 ? p : ~~i, r < 0 ? (r += p, r < 0 && (r = 0)) : r > p && (r = p), i < 0 ? (i += p, i < 0 && (i = 0)) : i > p && (i = p), i < r && (i = r); + const E = this.subarray(r, i); + return Object.setPrototypeOf(E, g.prototype), E; + }; + function we(c, r, i) { + if (c % 1 !== 0 || c < 0) throw new RangeError("offset is not uint"); + if (c + r > i) throw new RangeError("Trying to access beyond buffer length"); + } + g.prototype.readUintLE = g.prototype.readUIntLE = function(r, i, p) { + r = r >>> 0, i = i >>> 0, p || we(r, i, this.length); + let E = this[r], A = 1, R = 0; + for (; ++R < i && (A *= 256); ) + E += this[r + R] * A; + return E; + }, g.prototype.readUintBE = g.prototype.readUIntBE = function(r, i, p) { + r = r >>> 0, i = i >>> 0, p || we(r, i, this.length); + let E = this[r + --i], A = 1; + for (; i > 0 && (A *= 256); ) + E += this[r + --i] * A; + return E; + }, g.prototype.readUint8 = g.prototype.readUInt8 = function(r, i) { + return r = r >>> 0, i || we(r, 1, this.length), this[r]; + }, g.prototype.readUint16LE = g.prototype.readUInt16LE = function(r, i) { + return r = r >>> 0, i || we(r, 2, this.length), this[r] | this[r + 1] << 8; + }, g.prototype.readUint16BE = g.prototype.readUInt16BE = function(r, i) { + return r = r >>> 0, i || we(r, 2, this.length), this[r] << 8 | this[r + 1]; + }, g.prototype.readUint32LE = g.prototype.readUInt32LE = function(r, i) { + return r = r >>> 0, i || we(r, 4, this.length), (this[r] | this[r + 1] << 8 | this[r + 2] << 16) + this[r + 3] * 16777216; + }, g.prototype.readUint32BE = g.prototype.readUInt32BE = function(r, i) { + return r = r >>> 0, i || we(r, 4, this.length), this[r] * 16777216 + (this[r + 1] << 16 | this[r + 2] << 8 | this[r + 3]); + }, g.prototype.readBigUInt64LE = De(function(r) { + r = r >>> 0, He(r, "offset"); + const i = this[r], p = this[r + 7]; + (i === void 0 || p === void 0) && vt(r, this.length - 8); + const E = i + this[++r] * 2 ** 8 + this[++r] * 2 ** 16 + this[++r] * 2 ** 24, A = this[++r] + this[++r] * 2 ** 8 + this[++r] * 2 ** 16 + p * 2 ** 24; + return BigInt(E) + (BigInt(A) << BigInt(32)); + }), g.prototype.readBigUInt64BE = De(function(r) { + r = r >>> 0, He(r, "offset"); + const i = this[r], p = this[r + 7]; + (i === void 0 || p === void 0) && vt(r, this.length - 8); + const E = i * 2 ** 24 + this[++r] * 2 ** 16 + this[++r] * 2 ** 8 + this[++r], A = this[++r] * 2 ** 24 + this[++r] * 2 ** 16 + this[++r] * 2 ** 8 + p; + return (BigInt(E) << BigInt(32)) + BigInt(A); + }), g.prototype.readIntLE = function(r, i, p) { + r = r >>> 0, i = i >>> 0, p || we(r, i, this.length); + let E = this[r], A = 1, R = 0; + for (; ++R < i && (A *= 256); ) + E += this[r + R] * A; + return A *= 128, E >= A && (E -= Math.pow(2, 8 * i)), E; + }, g.prototype.readIntBE = function(r, i, p) { + r = r >>> 0, i = i >>> 0, p || we(r, i, this.length); + let E = i, A = 1, R = this[r + --E]; + for (; E > 0 && (A *= 256); ) + R += this[r + --E] * A; + return A *= 128, R >= A && (R -= Math.pow(2, 8 * i)), R; + }, g.prototype.readInt8 = function(r, i) { + return r = r >>> 0, i || we(r, 1, this.length), this[r] & 128 ? (255 - this[r] + 1) * -1 : this[r]; + }, g.prototype.readInt16LE = function(r, i) { + r = r >>> 0, i || we(r, 2, this.length); + const p = this[r] | this[r + 1] << 8; + return p & 32768 ? p | 4294901760 : p; + }, g.prototype.readInt16BE = function(r, i) { + r = r >>> 0, i || we(r, 2, this.length); + const p = this[r + 1] | this[r] << 8; + return p & 32768 ? p | 4294901760 : p; + }, g.prototype.readInt32LE = function(r, i) { + return r = r >>> 0, i || we(r, 4, this.length), this[r] | this[r + 1] << 8 | this[r + 2] << 16 | this[r + 3] << 24; + }, g.prototype.readInt32BE = function(r, i) { + return r = r >>> 0, i || we(r, 4, this.length), this[r] << 24 | this[r + 1] << 16 | this[r + 2] << 8 | this[r + 3]; + }, g.prototype.readBigInt64LE = De(function(r) { + r = r >>> 0, He(r, "offset"); + const i = this[r], p = this[r + 7]; + (i === void 0 || p === void 0) && vt(r, this.length - 8); + const E = this[r + 4] + this[r + 5] * 2 ** 8 + this[r + 6] * 2 ** 16 + (p << 24); + return (BigInt(E) << BigInt(32)) + BigInt(i + this[++r] * 2 ** 8 + this[++r] * 2 ** 16 + this[++r] * 2 ** 24); + }), g.prototype.readBigInt64BE = De(function(r) { + r = r >>> 0, He(r, "offset"); + const i = this[r], p = this[r + 7]; + (i === void 0 || p === void 0) && vt(r, this.length - 8); + const E = (i << 24) + // Overflow + this[++r] * 2 ** 16 + this[++r] * 2 ** 8 + this[++r]; + return (BigInt(E) << BigInt(32)) + BigInt(this[++r] * 2 ** 24 + this[++r] * 2 ** 16 + this[++r] * 2 ** 8 + p); + }), g.prototype.readFloatLE = function(r, i) { + return r = r >>> 0, i || we(r, 4, this.length), f.read(this, r, !0, 23, 4); + }, g.prototype.readFloatBE = function(r, i) { + return r = r >>> 0, i || we(r, 4, this.length), f.read(this, r, !1, 23, 4); + }, g.prototype.readDoubleLE = function(r, i) { + return r = r >>> 0, i || we(r, 8, this.length), f.read(this, r, !0, 52, 8); + }, g.prototype.readDoubleBE = function(r, i) { + return r = r >>> 0, i || we(r, 8, this.length), f.read(this, r, !1, 52, 8); + }; + function Ae(c, r, i, p, E, A) { + if (!g.isBuffer(c)) throw new TypeError('"buffer" argument must be a Buffer instance'); + if (r > E || r < A) throw new RangeError('"value" argument is out of bounds'); + if (i + p > c.length) throw new RangeError("Index out of range"); + } + g.prototype.writeUintLE = g.prototype.writeUIntLE = function(r, i, p, E) { + if (r = +r, i = i >>> 0, p = p >>> 0, !E) { + const oe = Math.pow(2, 8 * p) - 1; + Ae(this, r, i, p, oe, 0); + } + let A = 1, R = 0; + for (this[i] = r & 255; ++R < p && (A *= 256); ) + this[i + R] = r / A & 255; + return i + p; + }, g.prototype.writeUintBE = g.prototype.writeUIntBE = function(r, i, p, E) { + if (r = +r, i = i >>> 0, p = p >>> 0, !E) { + const oe = Math.pow(2, 8 * p) - 1; + Ae(this, r, i, p, oe, 0); + } + let A = p - 1, R = 1; + for (this[i + A] = r & 255; --A >= 0 && (R *= 256); ) + this[i + A] = r / R & 255; + return i + p; + }, g.prototype.writeUint8 = g.prototype.writeUInt8 = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 1, 255, 0), this[i] = r & 255, i + 1; + }, g.prototype.writeUint16LE = g.prototype.writeUInt16LE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 2, 65535, 0), this[i] = r & 255, this[i + 1] = r >>> 8, i + 2; + }, g.prototype.writeUint16BE = g.prototype.writeUInt16BE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 2, 65535, 0), this[i] = r >>> 8, this[i + 1] = r & 255, i + 2; + }, g.prototype.writeUint32LE = g.prototype.writeUInt32LE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 4, 4294967295, 0), this[i + 3] = r >>> 24, this[i + 2] = r >>> 16, this[i + 1] = r >>> 8, this[i] = r & 255, i + 4; + }, g.prototype.writeUint32BE = g.prototype.writeUInt32BE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 4, 4294967295, 0), this[i] = r >>> 24, this[i + 1] = r >>> 16, this[i + 2] = r >>> 8, this[i + 3] = r & 255, i + 4; + }; + function Ze(c, r, i, p, E) { + he(r, p, E, c, i, 7); + let A = Number(r & BigInt(4294967295)); + c[i++] = A, A = A >> 8, c[i++] = A, A = A >> 8, c[i++] = A, A = A >> 8, c[i++] = A; + let R = Number(r >> BigInt(32) & BigInt(4294967295)); + return c[i++] = R, R = R >> 8, c[i++] = R, R = R >> 8, c[i++] = R, R = R >> 8, c[i++] = R, i; + } + function $t(c, r, i, p, E) { + he(r, p, E, c, i, 7); + let A = Number(r & BigInt(4294967295)); + c[i + 7] = A, A = A >> 8, c[i + 6] = A, A = A >> 8, c[i + 5] = A, A = A >> 8, c[i + 4] = A; + let R = Number(r >> BigInt(32) & BigInt(4294967295)); + return c[i + 3] = R, R = R >> 8, c[i + 2] = R, R = R >> 8, c[i + 1] = R, R = R >> 8, c[i] = R, i + 8; + } + g.prototype.writeBigUInt64LE = De(function(r, i = 0) { + return Ze(this, r, i, BigInt(0), BigInt("0xffffffffffffffff")); + }), g.prototype.writeBigUInt64BE = De(function(r, i = 0) { + return $t(this, r, i, BigInt(0), BigInt("0xffffffffffffffff")); + }), g.prototype.writeIntLE = function(r, i, p, E) { + if (r = +r, i = i >>> 0, !E) { + const de = Math.pow(2, 8 * p - 1); + Ae(this, r, i, p, de - 1, -de); + } + let A = 0, R = 1, oe = 0; + for (this[i] = r & 255; ++A < p && (R *= 256); ) + r < 0 && oe === 0 && this[i + A - 1] !== 0 && (oe = 1), this[i + A] = (r / R >> 0) - oe & 255; + return i + p; + }, g.prototype.writeIntBE = function(r, i, p, E) { + if (r = +r, i = i >>> 0, !E) { + const de = Math.pow(2, 8 * p - 1); + Ae(this, r, i, p, de - 1, -de); + } + let A = p - 1, R = 1, oe = 0; + for (this[i + A] = r & 255; --A >= 0 && (R *= 256); ) + r < 0 && oe === 0 && this[i + A + 1] !== 0 && (oe = 1), this[i + A] = (r / R >> 0) - oe & 255; + return i + p; + }, g.prototype.writeInt8 = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 1, 127, -128), r < 0 && (r = 255 + r + 1), this[i] = r & 255, i + 1; + }, g.prototype.writeInt16LE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 2, 32767, -32768), this[i] = r & 255, this[i + 1] = r >>> 8, i + 2; + }, g.prototype.writeInt16BE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 2, 32767, -32768), this[i] = r >>> 8, this[i + 1] = r & 255, i + 2; + }, g.prototype.writeInt32LE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 4, 2147483647, -2147483648), this[i] = r & 255, this[i + 1] = r >>> 8, this[i + 2] = r >>> 16, this[i + 3] = r >>> 24, i + 4; + }, g.prototype.writeInt32BE = function(r, i, p) { + return r = +r, i = i >>> 0, p || Ae(this, r, i, 4, 2147483647, -2147483648), r < 0 && (r = 4294967295 + r + 1), this[i] = r >>> 24, this[i + 1] = r >>> 16, this[i + 2] = r >>> 8, this[i + 3] = r & 255, i + 4; + }, g.prototype.writeBigInt64LE = De(function(r, i = 0) { + return Ze(this, r, i, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff")); + }), g.prototype.writeBigInt64BE = De(function(r, i = 0) { + return $t(this, r, i, -BigInt("0x8000000000000000"), BigInt("0x7fffffffffffffff")); + }); + function gt(c, r, i, p, E, A) { + if (i + p > c.length) throw new RangeError("Index out of range"); + if (i < 0) throw new RangeError("Index out of range"); + } + function et(c, r, i, p, E) { + return r = +r, i = i >>> 0, E || gt(c, r, i, 4), f.write(c, r, i, p, 23, 4), i + 4; + } + g.prototype.writeFloatLE = function(r, i, p) { + return et(this, r, i, !0, p); + }, g.prototype.writeFloatBE = function(r, i, p) { + return et(this, r, i, !1, p); + }; + function kt(c, r, i, p, E) { + return r = +r, i = i >>> 0, E || gt(c, r, i, 8), f.write(c, r, i, p, 52, 8), i + 8; + } + g.prototype.writeDoubleLE = function(r, i, p) { + return kt(this, r, i, !0, p); + }, g.prototype.writeDoubleBE = function(r, i, p) { + return kt(this, r, i, !1, p); + }, g.prototype.copy = function(r, i, p, E) { + if (!g.isBuffer(r)) throw new TypeError("argument should be a Buffer"); + if (p || (p = 0), !E && E !== 0 && (E = this.length), i >= r.length && (i = r.length), i || (i = 0), E > 0 && E < p && (E = p), E === p || r.length === 0 || this.length === 0) return 0; + if (i < 0) + throw new RangeError("targetStart out of bounds"); + if (p < 0 || p >= this.length) throw new RangeError("Index out of range"); + if (E < 0) throw new RangeError("sourceEnd out of bounds"); + E > this.length && (E = this.length), r.length - i < E - p && (E = r.length - i + p); + const A = E - p; + return this === r && typeof Uint8Array.prototype.copyWithin == "function" ? this.copyWithin(i, p, E) : Uint8Array.prototype.set.call( + r, + this.subarray(p, E), + i + ), A; + }, g.prototype.fill = function(r, i, p, E) { + if (typeof r == "string") { + if (typeof i == "string" ? (E = i, i = 0, p = this.length) : typeof p == "string" && (E = p, p = this.length), E !== void 0 && typeof E != "string") + throw new TypeError("encoding must be a string"); + if (typeof E == "string" && !g.isEncoding(E)) + throw new TypeError("Unknown encoding: " + E); + if (r.length === 1) { + const R = r.charCodeAt(0); + (E === "utf8" && R < 128 || E === "latin1") && (r = R); + } + } else typeof r == "number" ? r = r & 255 : typeof r == "boolean" && (r = Number(r)); + if (i < 0 || this.length < i || this.length < p) + throw new RangeError("Out of range index"); + if (p <= i) + return this; + i = i >>> 0, p = p === void 0 ? this.length : p >>> 0, r || (r = 0); + let A; + if (typeof r == "number") + for (A = i; A < p; ++A) + this[A] = r; + else { + const R = g.isBuffer(r) ? r : g.from(r, E), oe = R.length; + if (oe === 0) + throw new TypeError('The value "' + r + '" is invalid for argument "value"'); + for (A = 0; A < p - i; ++A) + this[A + i] = R[A % oe]; + } + return this; + }; + const ut = {}; + function X(c, r, i) { + ut[c] = class extends i { + constructor() { + super(), Object.defineProperty(this, "message", { + value: r.apply(this, arguments), + writable: !0, + configurable: !0 + }), this.name = `${this.name} [${c}]`, this.stack, delete this.name; + } + get code() { + return c; + } + set code(E) { + Object.defineProperty(this, "code", { + configurable: !0, + enumerable: !0, + value: E, + writable: !0 + }); + } + toString() { + return `${this.name} [${c}]: ${this.message}`; + } + }; + } + X( + "ERR_BUFFER_OUT_OF_BOUNDS", + function(c) { + return c ? `${c} is outside of buffer bounds` : "Attempt to access memory outside buffer bounds"; + }, + RangeError + ), X( + "ERR_INVALID_ARG_TYPE", + function(c, r) { + return `The "${c}" argument must be of type number. Received type ${typeof r}`; + }, + TypeError + ), X( + "ERR_OUT_OF_RANGE", + function(c, r, i) { + let p = `The value of "${c}" is out of range.`, E = i; + return Number.isInteger(i) && Math.abs(i) > 2 ** 32 ? E = Lt(String(i)) : typeof i == "bigint" && (E = String(i), (i > BigInt(2) ** BigInt(32) || i < -(BigInt(2) ** BigInt(32))) && (E = Lt(E)), E += "n"), p += ` It must be ${r}. Received ${E}`, p; + }, + RangeError + ); + function Lt(c) { + let r = "", i = c.length; + const p = c[0] === "-" ? 1 : 0; + for (; i >= p + 4; i -= 3) + r = `_${c.slice(i - 3, i)}${r}`; + return `${c.slice(0, i)}${r}`; + } + function St(c, r, i) { + He(r, "offset"), (c[r] === void 0 || c[r + i] === void 0) && vt(r, c.length - (i + 1)); + } + function he(c, r, i, p, E, A) { + if (c > i || c < r) { + const R = typeof r == "bigint" ? "n" : ""; + let oe; + throw r === 0 || r === BigInt(0) ? oe = `>= 0${R} and < 2${R} ** ${(A + 1) * 8}${R}` : oe = `>= -(2${R} ** ${(A + 1) * 8 - 1}${R}) and < 2 ** ${(A + 1) * 8 - 1}${R}`, new ut.ERR_OUT_OF_RANGE("value", oe, c); + } + St(p, E, A); + } + function He(c, r) { + if (typeof c != "number") + throw new ut.ERR_INVALID_ARG_TYPE(r, "number", c); + } + function vt(c, r, i) { + throw Math.floor(c) !== c ? (He(c, i), new ut.ERR_OUT_OF_RANGE("offset", "an integer", c)) : r < 0 ? new ut.ERR_BUFFER_OUT_OF_BOUNDS() : new ut.ERR_OUT_OF_RANGE( + "offset", + `>= 0 and <= ${r}`, + c + ); + } + const tt = /[^+/0-9A-Za-z-_]/g; + function Wn(c) { + if (c = c.split("=")[0], c = c.trim().replace(tt, ""), c.length < 2) return ""; + for (; c.length % 4 !== 0; ) + c = c + "="; + return c; + } + function Ht(c, r) { + r = r || 1 / 0; + let i; + const p = c.length; + let E = null; + const A = []; + for (let R = 0; R < p; ++R) { + if (i = c.charCodeAt(R), i > 55295 && i < 57344) { + if (!E) { + if (i > 56319) { + (r -= 3) > -1 && A.push(239, 191, 189); + continue; + } else if (R + 1 === p) { + (r -= 3) > -1 && A.push(239, 191, 189); + continue; + } + E = i; + continue; + } + if (i < 56320) { + (r -= 3) > -1 && A.push(239, 191, 189), E = i; + continue; + } + i = (E - 55296 << 10 | i - 56320) + 65536; + } else E && (r -= 3) > -1 && A.push(239, 191, 189); + if (E = null, i < 128) { + if ((r -= 1) < 0) break; + A.push(i); + } else if (i < 2048) { + if ((r -= 2) < 0) break; + A.push( + i >> 6 | 192, + i & 63 | 128 + ); + } else if (i < 65536) { + if ((r -= 3) < 0) break; + A.push( + i >> 12 | 224, + i >> 6 & 63 | 128, + i & 63 | 128 + ); + } else if (i < 1114112) { + if ((r -= 4) < 0) break; + A.push( + i >> 18 | 240, + i >> 12 & 63 | 128, + i >> 6 & 63 | 128, + i & 63 | 128 + ); + } else + throw new Error("Invalid code point"); + } + return A; + } + function Gn(c) { + const r = []; + for (let i = 0; i < c.length; ++i) + r.push(c.charCodeAt(i) & 255); + return r; + } + function Jn(c, r) { + let i, p, E; + const A = []; + for (let R = 0; R < c.length && !((r -= 2) < 0); ++R) + i = c.charCodeAt(R), p = i >> 8, E = i % 256, A.push(E), A.push(p); + return A; + } + function Ct(c) { + return l.toByteArray(Wn(c)); + } + function Me(c, r, i, p) { + let E; + for (E = 0; E < p && !(E + i >= r.length || E >= c.length); ++E) + r[E + i] = c[E]; + return E; + } + function Ne(c, r) { + return c instanceof r || c != null && c.constructor != null && c.constructor.name != null && c.constructor.name === r.name; + } + function nt(c) { + return c !== c; + } + const fn = (function() { + const c = "0123456789abcdef", r = new Array(256); + for (let i = 0; i < 16; ++i) { + const p = i * 16; + for (let E = 0; E < 16; ++E) + r[p + E] = c[i] + c[E]; + } + return r; + })(); + function De(c) { + return typeof BigInt > "u" ? rt : c; + } + function rt() { + throw new Error("BigInt not supported"); + } + })(Tr)), Tr; +} +var Ma = Ta(); +function ee(u) { + u === void 0 || this.initialize(u), this.maxHeaderSize = ee.maxHeaderSize; +} +ee.prototype.initialize = function(u, l) { + this.type = u, this.state = u + "_LINE", this.info = { headers: [], upgrade: !1 }, this.trailers = [], this.line = "", this.isChunked = !1, this.connection = "", this.headerSize = 0, this.body_bytes = null, this.isUserCall = !1, this.hadError = !1; }; -L.encoding = "ascii"; -L.maxHeaderSize = 80 * 1024; -L.REQUEST = "REQUEST"; -L.RESPONSE = "RESPONSE"; -var Ui = L.kOnHeaders = 1, yr = L.kOnHeadersComplete = 2, xn = L.kOnBody = 3, gr = L.kOnMessageComplete = 4; -L.prototype[Ui] = L.prototype[yr] = L.prototype[xn] = L.prototype[gr] = function() { +ee.encoding = "ascii"; +ee.maxHeaderSize = 80 * 1024; +ee.REQUEST = "REQUEST"; +ee.RESPONSE = "RESPONSE"; +var so = ee.kOnHeaders = 1, Dr = ee.kOnHeadersComplete = 2, Hn = ee.kOnBody = 3, qr = ee.kOnMessageComplete = 4; +ee.prototype[so] = ee.prototype[Dr] = ee.prototype[Hn] = ee.prototype[qr] = function() { }; -var zi = !0; -Object.defineProperty(L, "kOnExecute", { +var ao = !0; +Object.defineProperty(ee, "kOnExecute", { get: function() { - return zi = !1, 99; + return ao = !1, 99; } }); -var Yi = L.methods = [ +var uo = ee.methods = [ "DELETE", "GET", "HEAD", @@ -4278,103 +5293,103 @@ var Yi = L.methods = [ "LINK", "UNLINK", "SOURCE" -], Vi = Yi.indexOf("CONNECT"); -L.prototype.reinitialize = L; -L.prototype.close = L.prototype.pause = L.prototype.resume = L.prototype.free = function() { +], co = uo.indexOf("CONNECT"); +ee.prototype.reinitialize = ee; +ee.prototype.close = ee.prototype.pause = ee.prototype.resume = ee.prototype.free = function() { }; -L.prototype._compatMode0_11 = !1; -L.prototype.getAsyncId = function() { +ee.prototype._compatMode0_11 = !1; +ee.prototype.getAsyncId = function() { return 0; }; -var Ca = { +var Ra = { REQUEST_LINE: !0, RESPONSE_LINE: !0, HEADER: !0 }; -L.prototype.execute = function(s, c, a) { - if (!(this instanceof L)) +ee.prototype.execute = function(u, l, f) { + if (!(this instanceof ee)) throw new TypeError("not a HTTPParser"); - c = c || 0, a = typeof a == "number" ? a : s.length, this.chunk = s, this.offset = c; - var l = this.end = c + a; + l = l || 0, f = typeof f == "number" ? f : u.length, this.chunk = u, this.offset = l; + var h = this.end = l + f; try { - for (; this.offset < l && !this[this.state](); ) + for (; this.offset < h && !this[this.state](); ) ; - } catch (E) { + } catch (T) { if (this.isUserCall) - throw E; - return this.hadError = !0, E; + throw T; + return this.hadError = !0, T; } - return this.chunk = null, a = this.offset - c, Ca[this.state] && (this.headerSize += a, this.headerSize > (this.maxHeaderSize || L.maxHeaderSize)) ? new Error("max header size exceeded") : a; + return this.chunk = null, f = this.offset - l, Ra[this.state] && (this.headerSize += f, this.headerSize > (this.maxHeaderSize || ee.maxHeaderSize)) ? new Error("max header size exceeded") : f; }; -var Ea = { +var Fa = { REQUEST_LINE: !0, RESPONSE_LINE: !0, BODY_RAW: !0 }; -L.prototype.finish = function() { +ee.prototype.finish = function() { if (!this.hadError) { - if (!Ea[this.state]) + if (!Fa[this.state]) return new Error("invalid state for EOF"); - this.state === "BODY_RAW" && this.userCall()(this[gr]()); + this.state === "BODY_RAW" && this.userCall()(this[qr]()); } }; -L.prototype.consume = L.prototype.unconsume = L.prototype.getCurrentBuffer = function() { +ee.prototype.consume = ee.prototype.unconsume = ee.prototype.getCurrentBuffer = function() { }; -L.prototype.userCall = function() { +ee.prototype.userCall = function() { this.isUserCall = !0; - var s = this; - return function(c) { - return s.isUserCall = !1, c; + var u = this; + return function(l) { + return u.isUserCall = !1, l; }; }; -L.prototype.nextRequest = function() { - this.userCall()(this[gr]()), this.reinitialize(this.type); +ee.prototype.nextRequest = function() { + this.userCall()(this[qr]()), this.reinitialize(this.type); }; -L.prototype.consumeLine = function() { - for (var s = this.end, c = this.chunk, a = this.offset; a < s; a++) - if (c[a] === 10) { - var l = this.line + c.toString(L.encoding, this.offset, a); - return l.charAt(l.length - 1) === "\r" && (l = l.substr(0, l.length - 1)), this.line = "", this.offset = a + 1, l; +ee.prototype.consumeLine = function() { + for (var u = this.end, l = this.chunk, f = this.offset; f < u; f++) + if (l[f] === 10) { + var h = this.line + l.toString(ee.encoding, this.offset, f); + return h.charAt(h.length - 1) === "\r" && (h = h.substr(0, h.length - 1)), this.line = "", this.offset = f + 1, h; } - this.line += c.toString(L.encoding, this.offset, this.end), this.offset = this.end; + this.line += l.toString(ee.encoding, this.offset, this.end), this.offset = this.end; }; -var Ia = /^([^: \t]+):[ \t]*((?:.*[^ \t])|)/, Oa = /^[ \t]+(.*[^ \t])/; -L.prototype.parseHeader = function(s, c) { - if (s.indexOf("\r") !== -1) - throw _n("HPE_LF_EXPECTED"); - var a = Ia.exec(s), l = a && a[1]; - if (l) - c.push(l), c.push(a[2]); +var Da = /^([^: \t]+):[ \t]*((?:.*[^ \t])|)/, Ka = /^[ \t]+(.*[^ \t])/; +ee.prototype.parseHeader = function(u, l) { + if (u.indexOf("\r") !== -1) + throw Yn("HPE_LF_EXPECTED"); + var f = Da.exec(u), h = f && f[1]; + if (h) + l.push(h), l.push(f[2]); else { - var E = Oa.exec(s); - E && c.length && (c[c.length - 1] && (c[c.length - 1] += " "), c[c.length - 1] += E[1]); + var T = Ka.exec(u); + T && l.length && (l[l.length - 1] && (l[l.length - 1] += " "), l[l.length - 1] += T[1]); } }; -var Aa = /^([A-Z-]+) ([^ ]+) HTTP\/(\d)\.(\d)$/; -L.prototype.REQUEST_LINE = function() { - var s = this.consumeLine(); - if (s) { - var c = Aa.exec(s); - if (c === null) - throw _n("HPE_INVALID_CONSTANT"); - if (this.info.method = this._compatMode0_11 ? c[1] : Yi.indexOf(c[1]), this.info.method === -1) +var Na = /^([A-Z-]+) ([^ ]+) HTTP\/(\d)\.(\d)$/; +ee.prototype.REQUEST_LINE = function() { + var u = this.consumeLine(); + if (u) { + var l = Na.exec(u); + if (l === null) + throw Yn("HPE_INVALID_CONSTANT"); + if (this.info.method = this._compatMode0_11 ? l[1] : uo.indexOf(l[1]), this.info.method === -1) throw new Error("invalid request method"); - this.info.url = c[2], this.info.versionMajor = +c[3], this.info.versionMinor = +c[4], this.body_bytes = 0, this.state = "HEADER"; + this.info.url = l[2], this.info.versionMajor = +l[3], this.info.versionMinor = +l[4], this.body_bytes = 0, this.state = "HEADER"; } }; -var Ma = /^HTTP\/(\d)\.(\d) (\d{3}) ?(.*)$/; -L.prototype.RESPONSE_LINE = function() { - var s = this.consumeLine(); - if (s) { - var c = Ma.exec(s); - if (c === null) - throw _n("HPE_INVALID_CONSTANT"); - this.info.versionMajor = +c[1], this.info.versionMinor = +c[2]; - var a = this.info.statusCode = +c[3]; - this.info.statusMessage = c[4], ((a / 100 | 0) === 1 || a === 204 || a === 304) && (this.body_bytes = 0), this.state = "HEADER"; +var qa = /^HTTP\/(\d)\.(\d) (\d{3}) ?(.*)$/; +ee.prototype.RESPONSE_LINE = function() { + var u = this.consumeLine(); + if (u) { + var l = qa.exec(u); + if (l === null) + throw Yn("HPE_INVALID_CONSTANT"); + this.info.versionMajor = +l[1], this.info.versionMinor = +l[2]; + var f = this.info.statusCode = +l[3]; + this.info.statusMessage = l[4], ((f / 100 | 0) === 1 || f === 204 || f === 304) && (this.body_bytes = 0), this.state = "HEADER"; } }; -L.prototype.shouldKeepAlive = function() { +ee.prototype.shouldKeepAlive = function() { if (this.info.versionMajor > 0 && this.info.versionMinor > 0) { if (this.connection.indexOf("close") !== -1) return !1; @@ -4382,104 +5397,104 @@ L.prototype.shouldKeepAlive = function() { return !1; return !!(this.body_bytes !== null || this.isChunked); }; -L.prototype.HEADER = function() { - var s = this.consumeLine(); - if (s !== void 0) { - var c = this.info; - if (s) - this.parseHeader(s, c.headers); +ee.prototype.HEADER = function() { + var u = this.consumeLine(); + if (u !== void 0) { + var l = this.info; + if (u) + this.parseHeader(u, l.headers); else { - for (var a = c.headers, l = !1, E, M = !1, C = 0; C < a.length; C += 2) - switch (a[C].toLowerCase()) { + for (var f = l.headers, h = !1, T, D = !1, O = 0; O < f.length; O += 2) + switch (f[O].toLowerCase()) { case "transfer-encoding": - this.isChunked = a[C + 1].toLowerCase() === "chunked"; + this.isChunked = f[O + 1].toLowerCase() === "chunked"; break; case "content-length": - if (E = +a[C + 1], l) { - if (E !== this.body_bytes) - throw _n("HPE_UNEXPECTED_CONTENT_LENGTH"); + if (T = +f[O + 1], h) { + if (T !== this.body_bytes) + throw Yn("HPE_UNEXPECTED_CONTENT_LENGTH"); } else - l = !0, this.body_bytes = E; + h = !0, this.body_bytes = T; break; case "connection": - this.connection += a[C + 1].toLowerCase(); + this.connection += f[O + 1].toLowerCase(); break; case "upgrade": - M = !0; + D = !0; break; } - this.isChunked && l && (l = !1, this.body_bytes = null), M && this.connection.indexOf("upgrade") != -1 ? c.upgrade = this.type === L.REQUEST || c.statusCode === 101 : c.upgrade = c.method === Vi, this.isChunked && c.upgrade && (this.isChunked = !1), c.shouldKeepAlive = this.shouldKeepAlive(); - var O; - if (zi ? O = this.userCall()(this[yr](c)) : O = this.userCall()(this[yr]( - c.versionMajor, - c.versionMinor, - c.headers, - c.method, - c.url, - c.statusCode, - c.statusMessage, - c.upgrade, - c.shouldKeepAlive - )), O === 2) + this.isChunked && h && (h = !1, this.body_bytes = null), D && this.connection.indexOf("upgrade") != -1 ? l.upgrade = this.type === ee.REQUEST || l.statusCode === 101 : l.upgrade = l.method === co, this.isChunked && l.upgrade && (this.isChunked = !1), l.shouldKeepAlive = this.shouldKeepAlive(); + var g; + if (ao ? g = this.userCall()(this[Dr](l)) : g = this.userCall()(this[Dr]( + l.versionMajor, + l.versionMinor, + l.headers, + l.method, + l.url, + l.statusCode, + l.statusMessage, + l.upgrade, + l.shouldKeepAlive + )), g === 2) return this.nextRequest(), !0; - if (this.isChunked && !O) + if (this.isChunked && !g) this.state = "BODY_CHUNKHEAD"; else { - if (O || this.body_bytes === 0) - return this.nextRequest(), c.upgrade; + if (g || this.body_bytes === 0) + return this.nextRequest(), l.upgrade; this.body_bytes === null ? this.state = "BODY_RAW" : this.state = "BODY_SIZED"; } } } }; -L.prototype.BODY_CHUNKHEAD = function() { - var s = this.consumeLine(); - s !== void 0 && (this.body_bytes = parseInt(s, 16), this.body_bytes ? this.state = "BODY_CHUNK" : this.state = "BODY_CHUNKTRAILERS"); +ee.prototype.BODY_CHUNKHEAD = function() { + var u = this.consumeLine(); + u !== void 0 && (this.body_bytes = parseInt(u, 16), this.body_bytes ? this.state = "BODY_CHUNK" : this.state = "BODY_CHUNKTRAILERS"); }; -L.prototype.BODY_CHUNK = function() { - var s = Math.min(this.end - this.offset, this.body_bytes); - this.userCall()(this[xn](this.chunk, this.offset, s)), this.offset += s, this.body_bytes -= s, this.body_bytes || (this.state = "BODY_CHUNKEMPTYLINE"); +ee.prototype.BODY_CHUNK = function() { + var u = Math.min(this.end - this.offset, this.body_bytes); + this.userCall()(this[Hn](this.chunk, this.offset, u)), this.offset += u, this.body_bytes -= u, this.body_bytes || (this.state = "BODY_CHUNKEMPTYLINE"); }; -L.prototype.BODY_CHUNKEMPTYLINE = function() { - var s = this.consumeLine(); - s !== void 0 && (this.state = "BODY_CHUNKHEAD"); +ee.prototype.BODY_CHUNKEMPTYLINE = function() { + var u = this.consumeLine(); + u !== void 0 && (this.state = "BODY_CHUNKHEAD"); }; -L.prototype.BODY_CHUNKTRAILERS = function() { - var s = this.consumeLine(); - s !== void 0 && (s ? this.parseHeader(s, this.trailers) : (this.trailers.length && this.userCall()(this[Ui](this.trailers, "")), this.nextRequest())); +ee.prototype.BODY_CHUNKTRAILERS = function() { + var u = this.consumeLine(); + u !== void 0 && (u ? this.parseHeader(u, this.trailers) : (this.trailers.length && this.userCall()(this[so](this.trailers, "")), this.nextRequest())); }; -L.prototype.BODY_RAW = function() { - var s = this.end - this.offset; - this.userCall()(this[xn](this.chunk, this.offset, s)), this.offset = this.end; +ee.prototype.BODY_RAW = function() { + var u = this.end - this.offset; + this.userCall()(this[Hn](this.chunk, this.offset, u)), this.offset = this.end; }; -L.prototype.BODY_SIZED = function() { - var s = Math.min(this.end - this.offset, this.body_bytes); - this.userCall()(this[xn](this.chunk, this.offset, s)), this.offset += s, this.body_bytes -= s, this.body_bytes || this.nextRequest(); +ee.prototype.BODY_SIZED = function() { + var u = Math.min(this.end - this.offset, this.body_bytes); + this.userCall()(this[Hn](this.chunk, this.offset, u)), this.offset += u, this.body_bytes -= u, this.body_bytes || this.nextRequest(); }; -["Headers", "HeadersComplete", "Body", "MessageComplete"].forEach(function(s) { - var c = L["kOn" + s]; - Object.defineProperty(L.prototype, "on" + s, { +["Headers", "HeadersComplete", "Body", "MessageComplete"].forEach(function(u) { + var l = ee["kOn" + u]; + Object.defineProperty(ee.prototype, "on" + u, { get: function() { - return this[c]; + return this[l]; }, - set: function(a) { - return this._compatMode0_11 = !0, Vi = "CONNECT", this[c] = a; + set: function(f) { + return this._compatMode0_11 = !0, co = "CONNECT", this[l] = f; } }); }); -function _n(s) { - var c = new Error("Parse Error"); - return c.code = s, c; +function Yn(u) { + var l = new Error("Parse Error"); + return l.code = u, l; } -function Ta(s) { - if (s === void 0) +function Ua(u) { + if (u === void 0) return { httpVersion: "1.0", headers: [], statusCode: 0 }; try { - return Ka(Sa.Buffer.from(s, "base64")); + return $a(Ma.Buffer.from(u, "base64")); } catch { return { httpVersion: "1.0", @@ -4488,128 +5503,128 @@ function Ta(s) { }; } } -function Ka(s) { - const c = new L(L.RESPONSE); - let a = !1, l = 0, E, M, C = [], O = []; - if (c[L.kOnHeadersComplete] = function(K) { - K.shouldKeepAlive, K.upgrade, l = K.statusCode, K.statusMessage, E = K.versionMajor, M = K.versionMinor, C = K.headers; - }, c[L.kOnBody] = function(K, B, H) { - O.push(K.slice(B, B + H)); - }, c[L.kOnHeaders] = function(K) { - }, c[L.kOnMessageComplete] = function() { - a = !0; - }, c.execute(s), c.finish(), !a) +function $a(u) { + const l = new ee(ee.RESPONSE); + let f = !1, h = 0, T, D, O = [], g = []; + if (l[ee.kOnHeadersComplete] = function(K) { + K.shouldKeepAlive, K.upgrade, h = K.statusCode, K.statusMessage, T = K.versionMajor, D = K.versionMinor, O = K.headers; + }, l[ee.kOnBody] = function(K, N, J) { + g.push(K.slice(N, N + J)); + }, l[ee.kOnHeaders] = function(K) { + }, l[ee.kOnMessageComplete] = function() { + f = !0; + }, l.execute(u), l.finish(), !f) throw new Error("Could not parse"); - let z = O.join(""); - const Y = []; - for (let K = 0; K < C.length - 1; K++) - K % 2 === 0 && Y.push([C[K], C[K + 1]]); + let G = g.join(""); + const Q = []; + for (let K = 0; K < O.length - 1; K++) + K % 2 === 0 && Q.push([O[K], O[K + 1]]); return { - headers: Y, - statusCode: l, - httpVersion: `${E}.${M}`, - body: z + headers: Q, + statusCode: h, + httpVersion: `${T}.${D}`, + body: G }; } -function Wi({ curl: s }) { - const c = _e(); - return /* @__PURE__ */ f.jsx(Ra, { children: /* @__PURE__ */ f.jsxs(Da, { style: { lineBreak: "anywhere", whiteSpace: "pre-line" }, children: [ - /* @__PURE__ */ f.jsx(rs, { children: /* @__PURE__ */ f.jsxs(is, { children: [ - /* @__PURE__ */ f.jsx(os, { asChild: !0, children: /* @__PURE__ */ f.jsx("span", { children: /* @__PURE__ */ f.jsx( - cs, +function lo({ curl: u }) { + const l = Ve(); + return /* @__PURE__ */ m.jsx(La, { children: /* @__PURE__ */ m.jsxs(Ha, { style: { lineBreak: "anywhere", whiteSpace: "pre-line" }, children: [ + /* @__PURE__ */ m.jsx(us, { children: /* @__PURE__ */ m.jsxs(cs, { children: [ + /* @__PURE__ */ m.jsx(ls, { asChild: !0, children: /* @__PURE__ */ m.jsx("span", { children: /* @__PURE__ */ m.jsx( + ps, { - onClick: (a) => { - a.preventDefault(), a.stopPropagation(), c(Di(s)); + onClick: (f) => { + f.preventDefault(), f.stopPropagation(), l(Xi(u)); } } ) }) }), - /* @__PURE__ */ f.jsx(ss, { children: /* @__PURE__ */ f.jsxs(Na, { sideOffset: 5, children: [ + /* @__PURE__ */ m.jsx(fs, { children: /* @__PURE__ */ m.jsxs(Ya, { sideOffset: 5, children: [ "Copy cURL command to the clipboard", - /* @__PURE__ */ f.jsx(qa, {}) + /* @__PURE__ */ m.jsx(za, {}) ] }) }) ] }) }), - s + u ] }) }); } -const Ra = V.div``, Da = V.div` +const La = te.div``, Ha = te.div` & > span { cursor: pointer; position: absolute; top: 6px; right: 6px; & > svg { - fill: var(${Q.foreground}); + fill: var(${re.foreground}); } } padding: 4px; padding-right: 24px; position: relative; font-family: monospace; - background-color: var(${Q.computedOne}); -`, Na = V(as)` - color: var(${Q.notificationsForeground}); - background-color: var(${Q.notificationsBackground}); - border: 1px solid var(${Q.notificationsBorder}); + background-color: var(${re.computedOne}); +`, Ya = te(hs)` + color: var(${re.notificationsForeground}); + background-color: var(${re.notificationsBackground}); + border: 1px solid var(${re.notificationsBorder}); border-radius: 4px; padding: 4px 8px; margin-right: 16px; -`, qa = V(us)` - fill: var(${Q.notificationsForeground}); +`, za = te(ds)` + fill: var(${re.notificationsForeground}); `; -function Ba({ report: s }) { - const { request: c, response: a, outcome: l, happyPath: E } = s; - let M = "N/A"; - const C = l?.status === "correct" ? "Yes" : "No"; - C === "Yes" && (M = l?.conformant ? "Yes" : "No"); - const O = l?.excessiveDataExposure, z = l?.apiResponseAnalysis || []; - return /* @__PURE__ */ f.jsxs(Fa, { children: [ - /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "HTTP code received" }), - /* @__PURE__ */ f.jsxs("div", { children: [ - a?.httpStatusCode, +function Va({ report: u }) { + const { request: l, response: f, outcome: h, happyPath: T } = u; + let D = "N/A"; + const O = h?.status === "correct" ? "Yes" : "No"; + O === "Yes" && (D = h?.conformant ? "Yes" : "No"); + const g = h?.excessiveDataExposure, G = h?.apiResponseAnalysis || []; + return /* @__PURE__ */ m.jsxs(Wa, { children: [ + /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "HTTP code received" }), + /* @__PURE__ */ m.jsxs("div", { children: [ + f?.httpStatusCode, " (Expected: ", - E?.httpStatusExpected?.join(", "), + T?.httpStatusExpected?.join(", "), ")" ] }) ] }), - /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Response code found in API Contract" }), - /* @__PURE__ */ f.jsx("div", { children: C }) + /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Response code found in API Contract" }), + /* @__PURE__ */ m.jsx("div", { children: O }) ] }), - /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Response matches API Contract" }), - /* @__PURE__ */ f.jsx("div", { children: M }) + /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Response matches API Contract" }), + /* @__PURE__ */ m.jsx("div", { children: D }) ] }), - /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Excessive data exposure found" }), - /* @__PURE__ */ f.jsx("div", { children: O ? "Yes" : "No" }) + /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Excessive data exposure found" }), + /* @__PURE__ */ m.jsx("div", { children: g ? "Yes" : "No" }) ] }), - z.length > 0 && /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Response Analysis" }), - /* @__PURE__ */ f.jsx("div", { children: z.map((Y, K) => /* @__PURE__ */ f.jsx("div", { children: Y.responseDescription }, K)) }) + G.length > 0 && /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Response Analysis" }), + /* @__PURE__ */ m.jsx("div", { children: G.map((Q, K) => /* @__PURE__ */ m.jsx("div", { children: Q.responseDescription }, K)) }) ] }), - c?.curl && /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Request" }), - /* @__PURE__ */ f.jsx("div", { children: /* @__PURE__ */ f.jsx(Wi, { curl: c?.curl }) }) + l?.curl && /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Request" }), + /* @__PURE__ */ m.jsx("div", { children: /* @__PURE__ */ m.jsx(lo, { curl: l?.curl }) }) ] }), - a?.rawPayload && /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Response" }), - /* @__PURE__ */ f.jsx("div", { children: /* @__PURE__ */ f.jsx(ns, { accented: !0, response: Ta(a.rawPayload) }) }) + f?.rawPayload && /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Response" }), + /* @__PURE__ */ m.jsx("div", { children: /* @__PURE__ */ m.jsx(as, { accented: !0, response: Ua(f.rawPayload) }) }) ] }), - l?.error && /* @__PURE__ */ f.jsxs(Be, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Error" }), - /* @__PURE__ */ f.jsx("div", { children: l?.error }) + h?.error && /* @__PURE__ */ m.jsxs(yt, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Error" }), + /* @__PURE__ */ m.jsx("div", { children: h?.error }) ] }) ] }); } -const Fa = V.div` +const Wa = te.div` margin: 8px; - border: 1px solid var(${Q.border}); + border: 1px solid var(${re.border}); `; -V.div` +te.div` margin: 16px; `; -const Be = V.div` +const yt = te.div` display: flex; padding: 8px; gap: 8px; @@ -4622,27 +5637,27 @@ const Be = V.div` flex: 3; } `; -function $a({ - report: s, - defaultCollapsed: c +function Ga({ + report: u, + defaultCollapsed: l }) { - const a = s.report.outcome?.testSuccessful, l = a !== void 0 ? a : s.operation.fuzzed; - return /* @__PURE__ */ f.jsx(La, { children: /* @__PURE__ */ f.jsxs(fs, { defaultCollapsed: c, children: [ - /* @__PURE__ */ f.jsxs(Ha, { children: [ - /* @__PURE__ */ f.jsx("span", { children: s.operationId }), - /* @__PURE__ */ f.jsx("span", { children: l ? "Passed" : "Failed" }) + const f = u.report.outcome?.testSuccessful, h = f !== void 0 ? f : u.operation.fuzzed; + return /* @__PURE__ */ m.jsx(Ja, { children: /* @__PURE__ */ m.jsxs(gs, { defaultCollapsed: l, children: [ + /* @__PURE__ */ m.jsxs(Qa, { children: [ + /* @__PURE__ */ m.jsx("span", { children: u.operationId }), + /* @__PURE__ */ m.jsx("span", { children: h ? "Passed" : "Failed" }) ] }), - /* @__PURE__ */ f.jsxs(Ua, { children: [ - /* @__PURE__ */ f.jsx(za, { children: s.operation.method }), - /* @__PURE__ */ f.jsx(Ya, { children: s.operation.path }), - l ? /* @__PURE__ */ f.jsx(Tt, {}) : /* @__PURE__ */ f.jsx(Lo, {}) + /* @__PURE__ */ m.jsxs(Xa, { children: [ + /* @__PURE__ */ m.jsx(Za, { children: u.operation.method }), + /* @__PURE__ */ m.jsx(eu, { children: u.operation.path }), + h ? /* @__PURE__ */ m.jsx(nn, {}) : /* @__PURE__ */ m.jsx(Wo, {}) ] }), - /* @__PURE__ */ f.jsx(Ba, { report: s.report }) + /* @__PURE__ */ m.jsx(Va, { report: u.report }) ] }) }); } -const La = V.div` - background-color: var(${Q.computedOne}); -`, Ha = V.div` +const Ja = te.div` + background-color: var(${re.computedOne}); +`, Qa = te.div` display: flex; gap: 4px; align-items: center; @@ -4654,7 +5669,7 @@ const La = V.div` flex: none; font-weight: 600; } -`, Ua = V.div` +`, Xa = te.div` display: flex; font-size: 90%; align-items: center; @@ -4664,11 +5679,11 @@ const La = V.div` margin-right: 2px; width: 14px; height: 14px; - fill: var(${Q.foreground}); + fill: var(${re.foreground}); } -`, za = V.div` - background-color: var(${Q.badgeBackground}); - color: var(${Q.badgeForeground}); +`, Za = te.div` + background-color: var(${re.badgeBackground}); + color: var(${re.badgeForeground}); border-radius: 4px; display: flex; justify-content: center; @@ -4677,88 +5692,88 @@ const La = V.div` height: 16px; text-transform: uppercase; font-size: 11px; -`, Ya = V.div` +`, eu = te.div` line-break: anywhere; `; -function Va({ report: s }) { - const c = _e(); - return /* @__PURE__ */ f.jsxs(Wa, { children: [ - /* @__PURE__ */ f.jsxs(Ga, { children: [ - /* @__PURE__ */ f.jsxs("div", { children: [ +function tu({ report: u }) { + const l = Ve(); + return /* @__PURE__ */ m.jsxs(nu, { children: [ + /* @__PURE__ */ m.jsxs(iu, { children: [ + /* @__PURE__ */ m.jsxs("div", { children: [ "Status: ", - /* @__PURE__ */ f.jsx("b", { children: s.summary.state }), + /* @__PURE__ */ m.jsx("b", { children: u.summary.state }), " (Exit code: ", - s.summary.exitCode, + u.summary.exitCode, ")" ] }), - /* @__PURE__ */ f.jsx("div", { children: hn.fromISO(s.summary.endDate).toLocaleString(hn.DATETIME_MED) }), - /* @__PURE__ */ f.jsxs("div", { children: [ + /* @__PURE__ */ m.jsx("div", { children: Fn.fromISO(u.summary.endDate).toLocaleString(Fn.DATETIME_MED) }), + /* @__PURE__ */ m.jsxs("div", { children: [ "Execution time:", " ", - hn.fromISO(s.summary.endDate).diff(hn.fromISO(s.summary.startDate)).toFormat("mm:ss.SSS") + Fn.fromISO(u.summary.endDate).diff(Fn.fromISO(u.summary.startDate)).toFormat("mm:ss.SSS") ] }), - /* @__PURE__ */ f.jsxs("div", { children: [ + /* @__PURE__ */ m.jsxs("div", { children: [ "Scan version: ", - s.scanVersion + u.scanVersion ] }) ] }), - /* @__PURE__ */ f.jsxs(Qa, { children: [ - /* @__PURE__ */ f.jsxs( + /* @__PURE__ */ m.jsxs(ru, { children: [ + /* @__PURE__ */ m.jsxs( "div", { - onClick: (a) => { - a.preventDefault(), a.stopPropagation(), c(mn("tests")), c(ye({})); + onClick: (f) => { + f.preventDefault(), f.stopPropagation(), l(qn("tests")), l(Fe({})); }, children: [ - /* @__PURE__ */ f.jsxs("div", { children: [ - s.stats.issues, + /* @__PURE__ */ m.jsxs("div", { children: [ + u.stats.issues, " ", - /* @__PURE__ */ f.jsx(ar, {}) + /* @__PURE__ */ m.jsx(Sr, {}) ] }), - /* @__PURE__ */ f.jsx("div", { children: "Executed" }) + /* @__PURE__ */ m.jsx("div", { children: "Executed" }) ] } ), - /* @__PURE__ */ f.jsxs( + /* @__PURE__ */ m.jsxs( "div", { - onClick: (a) => { - a.preventDefault(), a.stopPropagation(), c(mn("tests")), c(ye({ criticality: 2 })); + onClick: (f) => { + f.preventDefault(), f.stopPropagation(), l(qn("tests")), l(Fe({ criticality: 2 })); }, children: [ - /* @__PURE__ */ f.jsxs("div", { children: [ - s.stats.lowAndAbove, + /* @__PURE__ */ m.jsxs("div", { children: [ + u.stats.lowAndAbove, " ", - /* @__PURE__ */ f.jsx(ar, {}) + /* @__PURE__ */ m.jsx(Sr, {}) ] }), - /* @__PURE__ */ f.jsx("div", { children: "Issues Found" }) + /* @__PURE__ */ m.jsx("div", { children: "Issues Found" }) ] } ), - /* @__PURE__ */ f.jsxs( + /* @__PURE__ */ m.jsxs( "div", { - onClick: (a) => { - a.preventDefault(), a.stopPropagation(), c(mn("tests")), c(ye({ criticality: 4 })); + onClick: (f) => { + f.preventDefault(), f.stopPropagation(), l(qn("tests")), l(Fe({ criticality: 4 })); }, children: [ - /* @__PURE__ */ f.jsxs("div", { children: [ - s.stats.criticalAndHigh, + /* @__PURE__ */ m.jsxs("div", { children: [ + u.stats.criticalAndHigh, " ", - /* @__PURE__ */ f.jsx(ar, {}) + /* @__PURE__ */ m.jsx(Sr, {}) ] }), - /* @__PURE__ */ f.jsx("div", { children: "Critical/High" }) + /* @__PURE__ */ m.jsx("div", { children: "Critical/High" }) ] } ) ] }) ] }); } -const Wa = V.div` +const nu = te.div` display: flex; flex-direction: column; gap: 8px; -`, Qa = V.div` +`, ru = te.div` display: flex; gap: 8px; & > div { @@ -4768,170 +5783,170 @@ const Wa = V.div` flex-direction: column; align-items: center; padding: 12px 8px; - border: 1px solid var(${Q.border}); + border: 1px solid var(${re.border}); } -`, Ga = V.div` +`, iu = te.div` display: flex; - border: 1px solid var(${Q.border}); + border: 1px solid var(${re.border}); padding: 4px; & > div + div { - border-left: 2px solid var(${Q.border}); + border-left: 2px solid var(${re.border}); padding-left: 4px; margin-left: 4px; } `; -function Ja({ issue: s }) { - const c = _e(), [a, l] = pt.useState(!0), { request: E, response: M, test: C, outcome: O } = s.test, z = O?.status === "correct", Y = O?.conformant, K = O?.error, B = O?.excessiveDataExposure, H = O?.apiResponseAnalysis || [], w = O?.testSuccessful === !1 || !(z && Y); - let ie = "N/A", Se = "N/A"; - const Nt = O?.apiResponseAnalysis?.[0]?.responseKey === "response-http-status-scan" ? "No" : "Yes"; - return Nt === "Yes" && (ie = O?.apiResponseAnalysis?.[0]?.responseKey === "response-body-contenttype-scan" ? "No" : "Yes"), ie === "Yes" && (Se = O?.apiResponseAnalysis?.[0]?.responseKey === "response-body-badformat-scan" ? "No" : "Yes"), /* @__PURE__ */ f.jsxs(Xa, { children: [ - /* @__PURE__ */ f.jsxs(Za, { $collapsed: a, onClick: () => l(!a), children: [ - /* @__PURE__ */ f.jsx("div", { children: a ? /* @__PURE__ */ f.jsx(hs, {}) : /* @__PURE__ */ f.jsx(ps, {}) }), - /* @__PURE__ */ f.jsxs("div", { children: [ - /* @__PURE__ */ f.jsx(eu, { children: C?.description }), - /* @__PURE__ */ f.jsxs(tu, { children: [ - K && /* @__PURE__ */ f.jsxs(ht, { children: [ - /* @__PURE__ */ f.jsx(Mt, {}), +function ou({ issue: u }) { + const l = Ve(), [f, h] = Nt.useState(!0), { request: T, response: D, test: O, outcome: g } = u.test, G = g?.status === "correct", Q = g?.conformant, K = g?.error, N = g?.excessiveDataExposure, J = g?.apiResponseAnalysis || [], b = g?.testSuccessful === !1 || !(G && Q); + let Z = "N/A", ue = "N/A"; + const xe = g?.apiResponseAnalysis?.[0]?.responseKey === "response-http-status-scan" ? "No" : "Yes"; + return xe === "Yes" && (Z = g?.apiResponseAnalysis?.[0]?.responseKey === "response-body-contenttype-scan" ? "No" : "Yes"), Z === "Yes" && (ue = g?.apiResponseAnalysis?.[0]?.responseKey === "response-body-badformat-scan" ? "No" : "Yes"), /* @__PURE__ */ m.jsxs(su, { children: [ + /* @__PURE__ */ m.jsxs(au, { $collapsed: f, onClick: () => h(!f), children: [ + /* @__PURE__ */ m.jsx("div", { children: f ? /* @__PURE__ */ m.jsx(vs, {}) : /* @__PURE__ */ m.jsx(bs, {}) }), + /* @__PURE__ */ m.jsxs("div", { children: [ + /* @__PURE__ */ m.jsx(uu, { children: O?.description }), + /* @__PURE__ */ m.jsxs(cu, { children: [ + K && /* @__PURE__ */ m.jsxs(Kt, { children: [ + /* @__PURE__ */ m.jsx(en, {}), " Error: ", K ] }), - !K && w && /* @__PURE__ */ f.jsxs(ht, { children: [ - /* @__PURE__ */ f.jsx(Mt, {}), + !K && b && /* @__PURE__ */ m.jsxs(Kt, { children: [ + /* @__PURE__ */ m.jsx(en, {}), " Failed", - O.criticality > 0 && /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ + g.criticality > 0 && /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ "/", - /* @__PURE__ */ f.jsxs("span", { style: { fontWeight: iu[O.criticality] }, children: [ + /* @__PURE__ */ m.jsxs("span", { style: { fontWeight: hu[g.criticality] }, children: [ " ", - ru[O.criticality] + fu[g.criticality] ] }) ] }) ] }), - !K && !w && /* @__PURE__ */ f.jsxs(ht, { children: [ - /* @__PURE__ */ f.jsx(Tt, {}), + !K && !b && /* @__PURE__ */ m.jsxs(Kt, { children: [ + /* @__PURE__ */ m.jsx(nn, {}), " Passed" ] }), - !K && w && /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(ht, { children: z ? /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(Tt, {}), + !K && b && /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(Kt, { children: G ? /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(nn, {}), " Response code: Expected" - ] }) : /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(Mt, {}), + ] }) : /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(en, {}), " Response code: Unexpected" ] }) }), - /* @__PURE__ */ f.jsx(ht, { children: Y ? /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(Tt, {}), + /* @__PURE__ */ m.jsx(Kt, { children: Q ? /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(nn, {}), " Conforms to Contract: Yes" - ] }) : /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(Mt, {}), + ] }) : /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(en, {}), " Conforms to Contract: No" ] }) }), - /* @__PURE__ */ f.jsx(ht, { children: B ? /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(Mt, {}), + /* @__PURE__ */ m.jsx(Kt, { children: N ? /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(en, {}), " Excessive data exposure: Yes" - ] }) : /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsx(Tt, {}), + ] }) : /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsx(nn, {}), " Excessive data exposure: No" ] }) }) ] }) ] }) ] }) ] }), - !a && /* @__PURE__ */ f.jsxs(nu, { children: [ - K && /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Error" }), - /* @__PURE__ */ f.jsx("div", { children: K }) + !f && /* @__PURE__ */ m.jsxs(lu, { children: [ + K && /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Error" }), + /* @__PURE__ */ m.jsx("div", { children: K }) ] }), - !K && /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "HTTP code received" }), - /* @__PURE__ */ f.jsxs("div", { children: [ - M?.httpStatusCode, + !K && /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "HTTP code received" }), + /* @__PURE__ */ m.jsxs("div", { children: [ + D?.httpStatusCode, " (Expected: ", - C?.httpStatusExpected?.join(", "), + O?.httpStatusExpected?.join(", "), ")" ] }) ] }), - /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Response code found in API Contract" }), - /* @__PURE__ */ f.jsx("div", { children: Nt }) + /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Response code found in API Contract" }), + /* @__PURE__ */ m.jsx("div", { children: xe }) ] }), - /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Content-Type found in API Contract" }), - /* @__PURE__ */ f.jsx("div", { children: ie }) + /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Content-Type found in API Contract" }), + /* @__PURE__ */ m.jsx("div", { children: Z }) ] }), - /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Response matches API Contract" }), - /* @__PURE__ */ f.jsx("div", { children: Se }) + /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Response matches API Contract" }), + /* @__PURE__ */ m.jsx("div", { children: ue }) ] }), - /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Excessive data exposure found" }), - /* @__PURE__ */ f.jsx("div", { children: B ? "Yes" : "No" }) + /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Excessive data exposure found" }), + /* @__PURE__ */ m.jsx("div", { children: N ? "Yes" : "No" }) ] }), - H.length > 0 && /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Response Analysis" }), - /* @__PURE__ */ f.jsx("div", { children: H.map((et, tt) => /* @__PURE__ */ f.jsx("div", { children: et.responseDescription }, tt)) }) + J.length > 0 && /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Response Analysis" }), + /* @__PURE__ */ m.jsx("div", { children: J.map((ve, ye) => /* @__PURE__ */ m.jsx("div", { children: ve.responseDescription }, ye)) }) ] }), - /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "JSON Pointer" }), - /* @__PURE__ */ f.jsx("div", { children: C?.jsonPointer ? /* @__PURE__ */ f.jsx( + /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "JSON Pointer" }), + /* @__PURE__ */ m.jsx("div", { children: O?.jsonPointer ? /* @__PURE__ */ m.jsx( "a", { href: "#", - onClick: (et) => { - et.preventDefault(), et.stopPropagation(), c( - Ri(C?.jsonPointer + "") + onClick: (ve) => { + ve.preventDefault(), ve.stopPropagation(), l( + Qi(O?.jsonPointer + "") // FIXME support indexed reports ); }, - children: C?.jsonPointer + children: O?.jsonPointer } ) : "N/A" }) ] }), - E?.curl && /* @__PURE__ */ f.jsxs(Ae, { children: [ - /* @__PURE__ */ f.jsx("div", { children: "Request" }), - /* @__PURE__ */ f.jsx("div", { children: /* @__PURE__ */ f.jsx(Wi, { curl: E.curl }) }) + T?.curl && /* @__PURE__ */ m.jsxs(st, { children: [ + /* @__PURE__ */ m.jsx("div", { children: "Request" }), + /* @__PURE__ */ m.jsx("div", { children: /* @__PURE__ */ m.jsx(lo, { curl: T.curl }) }) ] }) ] }) ] }) ] }); } -const Xa = V.div` +const su = te.div` margin: 8px; - border: 1px solid var(${Q.border}); -`, Za = V.div` + border: 1px solid var(${re.border}); +`, au = te.div` display: flex; cursor: pointer; padding: 10px 10px 10px 0px; - background-color: var(${Q.computedOne}); + background-color: var(${re.computedOne}); & > div:first-child { padding-left: 4px; padding-right: 8px; > svg { - fill: var(${Q.foreground}); + fill: var(${re.foreground}); } } border-left: 5px solid transparent; - ${({ $collapsed: s }) => !s && `border-bottom: 1px solid var(${Q.border}); - border-left: 5px solid var(${Q.badgeBackground});`} -`, eu = V.div` + ${({ $collapsed: u }) => !u && `border-bottom: 1px solid var(${re.border}); + border-left: 5px solid var(${re.badgeBackground});`} +`, uu = te.div` font-weight: 600; -`, tu = V.div` +`, cu = te.div` margin-top: 8px; display: flex; font-size: 90%; align-items: center; gap: 16px; -`, ht = V.div` +`, Kt = te.div` display: flex; align-items: center; opacity: 0.8; & > svg { margin-right: 4px; - fill: var(${Q.foreground}); + fill: var(${re.foreground}); } -`, nu = V.div` - background-color: var(${Q.computedOne}); -`, Ae = V.div` +`, lu = te.div` + background-color: var(${re.computedOne}); +`, st = te.div` display: flex; padding: 8px; gap: 8px; @@ -4943,14 +5958,14 @@ const Xa = V.div` line-break: anywhere; flex: 3; } -`, ru = { +`, fu = { 0: "None", 1: "Info", 2: "Low", 3: "Medium", 4: "High", 5: "Critical" -}, iu = { +}, hu = { 0: 500, 1: 500, 2: 500, @@ -4958,42 +5973,42 @@ const Xa = V.div` 4: 700, 5: 700 }; -function ou({ - filters: s, - onClick: c +function du({ + filters: u, + onClick: l }) { - return /* @__PURE__ */ f.jsx( - su, + return /* @__PURE__ */ m.jsx( + pu, { - onClick: (a) => { - a.preventDefault(), a.stopPropagation(), c(); + onClick: (f) => { + f.preventDefault(), f.stopPropagation(), l(); }, - children: /* @__PURE__ */ f.jsxs(uu, { children: [ - /* @__PURE__ */ f.jsx("span", { children: "Filter" }), - /* @__PURE__ */ f.jsx(ls, {}), - /* @__PURE__ */ f.jsx(au, { $visible: s !== 0, children: s }) + children: /* @__PURE__ */ m.jsxs(mu, { children: [ + /* @__PURE__ */ m.jsx("span", { children: "Filter" }), + /* @__PURE__ */ m.jsx(ys, {}), + /* @__PURE__ */ m.jsx(yu, { $visible: u !== 0, children: u }) ] }) } ); } -const su = V.div``, au = V.div` +const pu = te.div``, yu = te.div` display: flex; - visibility: ${({ $visible: s }) => s ? "visible" : "hidden"}; + visibility: ${({ $visible: u }) => u ? "visible" : "hidden"}; align-items: center; justify-content: center; border-radius: 16px; width: 16px; height: 16px; - color: var(${Q.buttonForeground}); - background-color: var(${Q.buttonBackground}); + color: var(${re.buttonForeground}); + background-color: var(${re.buttonBackground}); font-size: 12px; -`, uu = V.button` +`, mu = te.button` display: flex; gap: 4px; align-items: center; cursor: pointer; background-color: transparent; - color: var(${Q.foreground}); + color: var(${re.foreground}); border: none; > span { @@ -5004,26 +6019,26 @@ const su = V.div``, au = V.div` > svg { height: 16px; width: 16px; - fill: var(${Q.foreground}); + fill: var(${re.foreground}); } `; -function cu({ onClick: s }) { - const c = _e(); - return /* @__PURE__ */ f.jsxs( - lu, +function gu({ onClick: u }) { + const l = Ve(); + return /* @__PURE__ */ m.jsxs( + vu, { - onClick: (a) => { - c(ye({})), a.preventDefault(), a.stopPropagation(), s?.(); + onClick: (f) => { + l(Fe({})), f.preventDefault(), f.stopPropagation(), u?.(); }, children: [ - /* @__PURE__ */ f.jsx(ds, {}), + /* @__PURE__ */ m.jsx(ms, {}), " ", - /* @__PURE__ */ f.jsx("span", { children: "Reset filters" }) + /* @__PURE__ */ m.jsx("span", { children: "Reset filters" }) ] } ); } -const lu = V.div` +const vu = te.div` width: 264px; height: 50px; display: flex; @@ -5035,8 +6050,8 @@ const lu = V.div` margin-right: 4px; } `; -function du() { - const s = be((l) => l.scan.filter), c = _e(), a = [ +function bu() { + const u = $e((h) => h.scan.filter), l = Ve(), f = [ { label: "All", value: "all" }, { label: "Critical", value: 5 }, { label: "High", value: 4 }, @@ -5044,42 +6059,42 @@ function du() { { label: "Low", value: 2 }, { label: "Info", value: 1 } ]; - return /* @__PURE__ */ f.jsx(fu, { children: /* @__PURE__ */ f.jsx( - Dt, + return /* @__PURE__ */ m.jsx(xu, { children: /* @__PURE__ */ m.jsx( + sn, { label: "Severity", - options: a, + options: f, placeholder: "All", - onSelectedItemChange: (l) => { - l && l.value !== "all" ? c(ye({ ...s, criticality: l?.value })) : c(ye({ ...s, criticality: void 0 })); + onSelectedItemChange: (h) => { + h && h.value !== "all" ? l(Fe({ ...u, criticality: h?.value })) : l(Fe({ ...u, criticality: void 0 })); }, - selected: s?.criticality || "all" + selected: u?.criticality || "all" } ) }); } -const fu = V.div` +const xu = te.div` width: 264px; `; -function hu() { - const s = _e(), c = be((E) => E.scan.filter), a = be((E) => E.scan.scanReport?.testKeys || []), l = []; - for (const { value: E, label: M } of a) - ki[M] && l.push({ label: ki[M], value: E }); - return /* @__PURE__ */ f.jsx(pu, { children: /* @__PURE__ */ f.jsx( - Dt, +function wu() { + const u = Ve(), l = $e((T) => T.scan.filter), f = $e((T) => T.scan.scanReport?.testKeys || []), h = []; + for (const { value: T, label: D } of f) + Ui[D] && h.push({ label: Ui[D], value: T }); + return /* @__PURE__ */ m.jsx(_u, { children: /* @__PURE__ */ m.jsx( + sn, { label: "Type", - options: l, + options: h, placeholder: "All", - onSelectedItemChange: (E) => { - E && E.value !== "all" ? s(ye({ ...c, testKey: E.value })) : s(ye({ ...c, testKey: void 0 })); + onSelectedItemChange: (T) => { + T && T.value !== "all" ? u(Fe({ ...l, testKey: T.value })) : u(Fe({ ...l, testKey: void 0 })); }, - selected: c.testKey ?? "all" + selected: l.testKey ?? "all" } ) }); } -const pu = V.div` +const _u = te.div` width: 264px; -`, ki = { +`, Ui = { "authentication-swapping-bfla": "Scan engine executes a business logic flow with wrong credentials", "authentication-swapping-bola": "Scan engine invokes an operation with wrong credentials", "custom-request": "Custom client request", @@ -5108,99 +6123,99 @@ const pu = V.div` "schema-type-wrong-string-scan": "Scan sends a request containing a string value instead of the expected type", "schema-uniqueitems-unique-scan": "Scan sends a request containing an array value that conflicts with 'uniqueItems'" }; -function yu() { - const s = be((l) => l.scan.scanReport?.paths || []), c = be((l) => l.scan.filter), a = _e(); - return /* @__PURE__ */ f.jsx(mu, { children: /* @__PURE__ */ f.jsx( - Dt, +function Eu() { + const u = $e((h) => h.scan.scanReport?.paths || []), l = $e((h) => h.scan.filter), f = Ve(); + return /* @__PURE__ */ m.jsx(Iu, { children: /* @__PURE__ */ m.jsx( + sn, { label: "Path", - options: s, + options: u, placeholder: "All", - onSelectedItemChange: (l) => { - l && l.value !== "all" ? a( - ye({ ...c, path: l.value, operationId: void 0 }) - ) : a(ye({ ...c, path: void 0, operationId: void 0 })); + onSelectedItemChange: (h) => { + h && h.value !== "all" ? f( + Fe({ ...l, path: h.value, operationId: void 0 }) + ) : f(Fe({ ...l, path: void 0, operationId: void 0 })); }, - selected: c.path ?? "all" + selected: l.path ?? "all" } ) }); } -const mu = V.div` +const Iu = te.div` width: 264px; `; -function vu() { - const s = be((l) => l.scan.scanReport?.operationIds || []), c = be((l) => l.scan.filter), a = _e(); - return /* @__PURE__ */ f.jsx(gu, { children: /* @__PURE__ */ f.jsx( - Dt, +function Pu() { + const u = $e((h) => h.scan.scanReport?.operationIds || []), l = $e((h) => h.scan.filter), f = Ve(); + return /* @__PURE__ */ m.jsx(ju, { children: /* @__PURE__ */ m.jsx( + sn, { label: "Operation ID", - options: s, + options: u, placeholder: "All", - onSelectedItemChange: (l) => { - l && l.value !== "all" ? a(ye({ ...c, operationId: l.value })) : a(ye({ ...c, operationId: void 0 })); + onSelectedItemChange: (h) => { + h && h.value !== "all" ? f(Fe({ ...l, operationId: h.value })) : f(Fe({ ...l, operationId: void 0 })); }, - selected: c.operationId ?? "all" + selected: l.operationId ?? "all" } ) }); } -const gu = V.div` +const ju = te.div` width: 264px; `; -function bu() { - const { filter: s } = be((l) => l.scan), c = _e(), a = Ai.map((l, E) => ({ - value: E, - label: l.toUpperCase() +function ku() { + const { filter: u } = $e((h) => h.scan), l = Ve(), f = Vi.map((h, T) => ({ + value: T, + label: h.toUpperCase() })); - return /* @__PURE__ */ f.jsx(xu, { children: /* @__PURE__ */ f.jsx( - Dt, + return /* @__PURE__ */ m.jsx(Su, { children: /* @__PURE__ */ m.jsx( + sn, { label: "Method", - options: a, + options: f, placeholder: "All", - onSelectedItemChange: (l) => { - l && l.value !== "all" ? c( - ye({ ...s, method: l.value, operationId: void 0 }) - ) : c(ye({ ...s, method: void 0, operationId: void 0 })); + onSelectedItemChange: (h) => { + h && h.value !== "all" ? l( + Fe({ ...u, method: h.value, operationId: void 0 }) + ) : l(Fe({ ...u, method: void 0, operationId: void 0 })); }, - selected: s.method ?? "all" + selected: u.method ?? "all" } ) }); } -const xu = V.div` +const Su = te.div` width: 264px; `; -function _u({ total: s }) { - const c = be((E) => E.scan.filter), [a, l] = pt.useState(!0); - return /* @__PURE__ */ f.jsxs(wu, { children: [ - /* @__PURE__ */ f.jsxs(Pu, { children: [ - /* @__PURE__ */ f.jsxs("div", { children: [ - s, +function Cu({ total: u }) { + const l = $e((T) => T.scan.filter), [f, h] = Nt.useState(!0); + return /* @__PURE__ */ m.jsxs(Au, { children: [ + /* @__PURE__ */ m.jsxs(Bu, { children: [ + /* @__PURE__ */ m.jsxs("div", { children: [ + u, " issue(s)" ] }), - /* @__PURE__ */ f.jsx( - ou, + /* @__PURE__ */ m.jsx( + du, { - filters: Object.entries(c).filter(([E, M]) => M !== void 0).length, - onClick: () => l(!a) + filters: Object.entries(l).filter(([T, D]) => D !== void 0).length, + onClick: () => h(!f) } ) ] }), - !a && /* @__PURE__ */ f.jsxs(ju, { children: [ - /* @__PURE__ */ f.jsx(du, {}), - /* @__PURE__ */ f.jsx(hu, {}), - /* @__PURE__ */ f.jsx(yu, {}), - /* @__PURE__ */ f.jsx(bu, {}), - /* @__PURE__ */ f.jsx(vu, {}), - /* @__PURE__ */ f.jsx(cu, { onClick: () => l(!0) }) + !f && /* @__PURE__ */ m.jsxs(Ou, { children: [ + /* @__PURE__ */ m.jsx(bu, {}), + /* @__PURE__ */ m.jsx(wu, {}), + /* @__PURE__ */ m.jsx(Eu, {}), + /* @__PURE__ */ m.jsx(ku, {}), + /* @__PURE__ */ m.jsx(Pu, {}), + /* @__PURE__ */ m.jsx(gu, { onClick: () => h(!0) }) ] }) ] }); } -const wu = V.div` +const Au = te.div` margin: 8px; display: flex; flex-direction: column; position: relative; -`, Pu = V.div` +`, Bu = te.div` margin: 6px; display: flex; flex-direction: row; @@ -5209,7 +6224,7 @@ const wu = V.div` > div:first-child { font-weight: 700; } -`, ju = V.div` +`, Ou = te.div` display: flex; flex-wrap: wrap; flex-direction: row; @@ -5218,36 +6233,36 @@ const wu = V.div` width: 264px; } `; -function Qi({ - current: s, - total: c, - onPageChange: a +function fo({ + current: u, + total: l, + onPageChange: f }) { - const l = () => { - s > 0 && a(s - 1); - }, E = () => { - s < c - 1 && a(s + 1); + const h = () => { + u > 0 && f(u - 1); + }, T = () => { + u < l - 1 && f(u + 1); }; - return /* @__PURE__ */ f.jsxs(ku, { children: [ - /* @__PURE__ */ f.jsx(Si, { onClick: l, disabled: s === 0, children: /* @__PURE__ */ f.jsx(ys, {}) }), + return /* @__PURE__ */ m.jsxs(Tu, { children: [ + /* @__PURE__ */ m.jsx($i, { onClick: h, disabled: u === 0, children: /* @__PURE__ */ m.jsx(xs, {}) }), "Page ", - s + 1, + u + 1, " of ", - c, - /* @__PURE__ */ f.jsx(Si, { onClick: E, disabled: s === c - 1, children: /* @__PURE__ */ f.jsx(ms, {}) }) + l, + /* @__PURE__ */ m.jsx($i, { onClick: T, disabled: u === l - 1, children: /* @__PURE__ */ m.jsx(ws, {}) }) ] }); } -const ku = V.div` +const Tu = te.div` padding: 8px; display: flex; align-items: center; gap: 8px; > svg { - fill: var(${Q.foreground}); + fill: var(${re.foreground}); height: 16px; width: 16px; } -`, Si = V.button` +`, $i = te.button` background: none; border: none; cursor: pointer; @@ -5260,54 +6275,54 @@ const ku = V.div` cursor: not-allowed; } `; -function Su() { - const { testsPage: s } = be((l) => l.scan), c = _e(), a = (l) => { - c(hr(l)); +function Mu() { + const { testsPage: u } = $e((h) => h.scan), l = Ve(), f = (h) => { + l(Rr(h)); }; - return /* @__PURE__ */ f.jsxs(Cu, { children: [ - /* @__PURE__ */ f.jsx(_u, { total: s.total }), - s.items.map((l, E) => /* @__PURE__ */ f.jsx(Ja, { issue: l }, `${s.current}-${E}`)), - /* @__PURE__ */ f.jsx( - Qi, + return /* @__PURE__ */ m.jsxs(Ru, { children: [ + /* @__PURE__ */ m.jsx(Cu, { total: u.total }), + u.items.map((h, T) => /* @__PURE__ */ m.jsx(ou, { issue: h }, `${u.current}-${T}`)), + /* @__PURE__ */ m.jsx( + fo, { - current: s.current, - total: s.pages, - onPageChange: a + current: u.current, + total: u.pages, + onPageChange: f } ) ] }); } -const Cu = V.div` +const Ru = te.div` margin-top: 8px; `; -V.div` +te.div` margin: 8px; padding: 4px; - border: 1px solid var(${Q.border}); + border: 1px solid var(${re.border}); `; -function Eu() { - const s = _e(), { scanReport: c, tab: a, happyPathPage: l } = be((M) => M.scan), E = (M) => { - s(fr(M)); +function Fu() { + const u = Ve(), { scanReport: l, tab: f, happyPathPage: h } = $e((D) => D.scan), T = (D) => { + u(Mr(D)); }; - return c === void 0 ? /* @__PURE__ */ f.jsx(Iu, { children: /* @__PURE__ */ f.jsx(Au, { children: "Report is not yet available" }) }) : /* @__PURE__ */ f.jsx( - ts, + return l === void 0 ? /* @__PURE__ */ m.jsx(Du, { children: /* @__PURE__ */ m.jsx(Nu, { children: "Report is not yet available" }) }) : /* @__PURE__ */ m.jsx( + ss, { - activeTab: a, - setActiveTab: (M) => s(mn(M)), + activeTab: f, + setActiveTab: (D) => u(qn(D)), tabs: [ { id: "summary", title: "Summary", - content: /* @__PURE__ */ f.jsxs(Ou, { children: [ - /* @__PURE__ */ f.jsx(Va, { report: c }), - /* @__PURE__ */ f.jsx("div", { style: { fontWeight: 600, margin: "8px" }, children: "Happy Path Testing results" }), - l.items.map((M, C) => /* @__PURE__ */ f.jsx($a, { defaultCollapsed: !0, report: M }, C)), - /* @__PURE__ */ f.jsx( - Qi, + content: /* @__PURE__ */ m.jsxs(Ku, { children: [ + /* @__PURE__ */ m.jsx(tu, { report: l }), + /* @__PURE__ */ m.jsx("div", { style: { fontWeight: 600, margin: "8px" }, children: "Happy Path Testing results" }), + h.items.map((D, O) => /* @__PURE__ */ m.jsx(Ga, { defaultCollapsed: !0, report: D }, O)), + /* @__PURE__ */ m.jsx( + fo, { - current: l.current, - total: l.pages, - onPageChange: E + current: h.current, + total: h.pages, + onPageChange: T } ) ] }) @@ -5315,55 +6330,55 @@ function Eu() { { id: "tests", title: "Tests", - content: /* @__PURE__ */ f.jsx(Su, {}) + content: /* @__PURE__ */ m.jsx(Mu, {}) }, - { id: "logs", title: "Logs", content: /* @__PURE__ */ f.jsx(wa, {}) } + { id: "logs", title: "Logs", content: /* @__PURE__ */ m.jsx(ka, {}) } ] } ); } -const Iu = V.div``, Ou = V.div` +const Du = te.div``, Ku = te.div` margin: 8px; display: flex; flex-direction: column; gap: 8px; -`, Au = V.div` +`, Nu = te.div` margin: 1em; padding: 10px; `; -function Mu() { - const { scanReport: s, waiting: c, error: a } = be((l) => l.scan); - return /* @__PURE__ */ f.jsxs(f.Fragment, { children: [ - s && /* @__PURE__ */ f.jsx(Eu, {}), - /* @__PURE__ */ f.jsx(ba, {}), - c && /* @__PURE__ */ f.jsx(pa, {}) +function qu() { + const { scanReport: u, waiting: l, error: f } = $e((h) => h.scan); + return /* @__PURE__ */ m.jsxs(m.Fragment, { children: [ + u && /* @__PURE__ */ m.jsx(Fu, {}), + /* @__PURE__ */ m.jsx(Ia, {}), + l && /* @__PURE__ */ m.jsx(ba, {}) ] }); } -const Ci = [ +const Li = [ { id: "starting", title: "", navigation: !1, - element: /* @__PURE__ */ f.jsx("div", {}) + element: /* @__PURE__ */ m.jsx("div", {}) }, { id: "scan", title: "Scan", - element: /* @__PURE__ */ f.jsx(Mu, {}), - when: mr + element: /* @__PURE__ */ m.jsx(qu, {}), + when: Kr } -], Tu = { - changeTheme: Wo, - showGeneralError: Ki, - showScanReport: Ti, - loadConfig: Zo, - showLogMessage: ws, - parseChunk: Ni +], Uu = { + changeTheme: es, + showGeneralError: Ji, + showScanReport: Gi, + loadConfig: is, + showLogMessage: ks, + parseChunk: Zi }; -function Ku(s, c) { - const a = ks(fa(s, Ci), c); - return Ho.createRoot(document.getElementById("root")).render( - /* @__PURE__ */ f.jsx(Uo.StrictMode, { children: /* @__PURE__ */ f.jsx(zo, { store: a, children: /* @__PURE__ */ f.jsx(Yo.Provider, { value: Ci, children: /* @__PURE__ */ f.jsx(ha, {}) }) }) }) - ), window.addEventListener("message", Vo(a, Tu)), { skipAutoStart: !0 }; +function $u(u, l) { + const f = As(ga(u, Li), l); + return Go.createRoot(document.getElementById("root")).render( + /* @__PURE__ */ m.jsx(Jo.StrictMode, { children: /* @__PURE__ */ m.jsx(Qo, { store: f, children: /* @__PURE__ */ m.jsx(Xo.Provider, { value: Li, children: /* @__PURE__ */ m.jsx(va, {}) }) }) }) + ), window.addEventListener("message", Zo(f, Uu)), { skipAutoStart: !0 }; } -window.renderWebView = Ku; +window.renderWebView = $u; diff --git a/openapi-plugin/resources/web/scanconf-graphql.js b/openapi-plugin/resources/web/scanconf-graphql.js index d765306b..fca349ed 100644 --- a/openapi-plugin/resources/web/scanconf-graphql.js +++ b/openapi-plugin/resources/web/scanconf-graphql.js @@ -1,9 +1,9 @@ import { H as w, c as K, i as me, a as Le, p as Ge, I as Ue, r as Ke, t as We, l as Je, u as Qe, b as Xe, e as f, j as a, T as y, f as z, w as $, d as Ze, s as Ye, B as et, g as tt, R as at, P as nt, h as st, N as ot, k as rt } from "./TriangleExclamation.BLKAXJ8l.js"; -import { aU as M, aV as it, M as V, aW as ct, aX as lt, p as oe, u as fe, w as ve, aG as dt, aY as ut, C as D, n as W, q as H, t as he, v as ye, Z as O, F as pt, B as mt, ad as ft, aZ as vt, ai as ht, aj as yt, al as J, ax as xt, ay as bt, a_ as xe, a$ as be, b0 as gt, c as St, b1 as jt, b2 as Ct, b3 as re, R as kt, b4 as qt, aC as Q, b5 as Rt, b6 as wt, E as Et, b7 as Tt, b8 as It, b9 as Dt, aA as ge, aB as Se, aN as Pt, aO as Ot, aQ as $t, aR as At, aS as Ft, aT as zt } from "./UpdatePrompt.BmnOlML_.js"; +import { aU as M, aV as it, M as V, aW as ct, aX as lt, p as oe, u as fe, w as ve, aG as dt, aY as ut, C as D, n as W, q as H, t as he, v as ye, Z as O, F as pt, B as mt, ad as ft, aZ as vt, ai as ht, aj as yt, al as J, ax as xt, ay as bt, a_ as xe, a$ as be, b0 as gt, c as St, b1 as jt, b2 as Ct, b3 as re, R as kt, b4 as qt, aC as Q, b5 as Rt, b6 as wt, E as Et, b7 as Tt, b8 as It, b9 as Dt, aA as ge, aB as Se, aN as Pt, aO as Ot, aQ as $t, aR as At, aS as Ft, aT as zt } from "./UpdatePrompt.DQlMOewA.js"; import { a as je } from "./SearchSidebar.CtwbvK_x.js"; -import { y as Nt, t as Mt, r as Vt, o as Ce, D as ke } from "./variables.-zE0Ry6h.js"; +import { x as Nt, r as Mt, q as Vt, D as Ce } from "./variables.CfsUBZ9t.js"; import { l as Bt, c as Ht } from "./slice.s4_w0CJL.js"; -import { l as _t, e as Lt, s as Gt } from "./index.CRy0HWMP.js"; +import { a as _t, e as Lt, s as Gt, l as ke } from "./index.BXf_Hj-1.js"; import { l as Ut, p as Kt, u as Wt, c as Jt, b as qe } from "./slice.CZpj5Zis.js"; import { s as A, g as Qt, M as L, a as G, G as Xt } from "./GeneralError.Dvjq_B8a.js"; import { c as Zt, o as Yt } from "./listener.BNWHQqef.js"; @@ -996,7 +996,7 @@ function an(e, t) { }), He; } function nn(e) { - return e = Ce.simpleClone(e), { + return e = ke.simpleClone(e), { path: e.request.path, method: e.request.method, parameters: e.request.parameters, @@ -1012,7 +1012,7 @@ function nn(e) { }; } function sn(e) { - return e = Ce.simpleClone(e), { + return e = ke.simpleClone(e), { url: e.request.url, method: e.request.method, parameters: e.request.parameters, @@ -1172,7 +1172,7 @@ function mn({ tryResult: s, mockResult: o, mockMissingVariables: d - } = b((v) => v.requests), l = P(), { playbook: p, servers: r } = b((v) => v.scanconf), c = b((v) => v.env.data), u = (v, i) => l(Be({ server: v, inputs: i })), h = (v) => l(ne({ ref: t, stage: v })), g = [...ke, ...qt([])], [k, S] = z.useState({}), E = Q(p, c, r); + } = b((v) => v.requests), l = P(), { playbook: p, servers: r } = b((v) => v.scanconf), c = b((v) => v.env.data), u = (v, i) => l(Be({ server: v, inputs: i })), h = (v) => l(ne({ ref: t, stage: v })), g = [...Ce, ...qt([])], [k, S] = z.useState({}), E = Q(p, c, r); return z.useEffect(() => { const v = { ...k }; for (const i of Object.keys(v)) @@ -1402,7 +1402,7 @@ function On({ tryResult: r, mockResult: c, mockMissingVariables: u - } = b((m) => m.requests), h = (m, C) => n(Be({ server: m, inputs: C })), g = (m) => n(ne({ ref: t, stage: m })), k = o?.authenticationDetails ? o?.authenticationDetails[0] : void 0, S = [...ke, ...Dt([])], [E, v] = z.useState({}), { simple: i } = ge(Se(o), l), j = Q(o, l, d); + } = b((m) => m.requests), h = (m, C) => n(Be({ server: m, inputs: C })), g = (m) => n(ne({ ref: t, stage: m })), k = o?.authenticationDetails ? o?.authenticationDetails[0] : void 0, S = [...Ce, ...Dt([])], [E, v] = z.useState({}), { simple: i } = ge(Se(o), l), j = Q(o, l, d); return z.useEffect(() => { const m = { ...E }; for (const C of Object.keys(m)) diff --git a/openapi-plugin/resources/web/scanconf.js b/openapi-plugin/resources/web/scanconf.js index fe0ccda5..0e76dbdb 100644 --- a/openapi-plugin/resources/web/scanconf.js +++ b/openapi-plugin/resources/web/scanconf.js @@ -1,5 +1,5 @@ import { j as t, v as Zt, f as w, e as h, T as u, S as it, R as at, w as T, i as oe, d as en, s as tn, x as ct, y as lt, z as dt, A as ut, D as pt, C as ht, O as ft, E as gt, F as nn, B as rn, G as on, g as sn, P as an, h as cn, N as ln, k as dn } from "./TriangleExclamation.BLKAXJ8l.js"; -import { i as E, D as un, p as Ge, u as mt, w as xt, S as pn, a as hn, b as fn, c as gn, d as mn, E as xn, R as vn, e as se, F as Ae, f as q, g as I, s as Oe, r as z, h as B, m as L, j as N, k as G, T as de, l as vt, C as R, n as ue, o as bt, q as pe, t as yt, v as jt, Z as W, B as re, x as Ee, y as St, M as be, z as wt, A as le, G as Ct, H as ge, I as It, J as Te, K as bn, L as yn, N as ye, O as jn, P as Sn, Q as wn, U as Me, V as Cn, W as kt, X as De, Y as Ot, _ as In, $ as kn, a0 as On, a1 as Tn, a2 as Dn, a3 as qn, a4 as $n, a5 as Pn, a6 as Rn, a7 as An, a8 as En, a9 as Mn, aa as Fn, ab as zn, ac as Bn, ad as Fe, ae as ze, af as Ln, ag as Nn, ah as Be, ai as Hn, aj as Gn, ak as Vn, al as Le, am as Tt, an as Un, ao as qe, ap as Dt, aq as qt, ar as $t, as as Pt, at as _n, au as Wn, av as Rt, aw as At, ax as Yn, ay as Jn, az as ne, aA as Et, aB as Mt, aC as Ft, aD as zt, aE as Xn, aF as Kn, aG as Qn, aH as Zn, aI as er, aJ as tr, aK as Bt, aL as Ve, aM as nr, aN as rr, aO as or, aP as sr, aQ as ir, aR as ar, aS as cr, aT as lr } from "./UpdatePrompt.BmnOlML_.js"; +import { i as E, D as un, p as Ge, u as mt, w as xt, S as pn, a as hn, b as fn, c as gn, d as mn, E as xn, R as vn, e as se, F as Ae, f as q, g as I, s as Oe, r as z, h as B, m as L, j as N, k as G, T as de, l as vt, C as R, n as ue, o as bt, q as pe, t as yt, v as jt, Z as W, B as re, x as Ee, y as St, M as be, z as wt, A as le, G as Ct, H as ge, I as It, J as Te, K as bn, L as yn, N as ye, O as jn, P as Sn, Q as wn, U as Me, V as Cn, W as kt, X as De, Y as Ot, _ as In, $ as kn, a0 as On, a1 as Tn, a2 as Dn, a3 as qn, a4 as $n, a5 as Pn, a6 as Rn, a7 as An, a8 as En, a9 as Mn, aa as Fn, ab as zn, ac as Bn, ad as Fe, ae as ze, af as Ln, ag as Nn, ah as Be, ai as Hn, aj as Gn, ak as Vn, al as Le, am as Tt, an as Un, ao as qe, ap as Dt, aq as qt, ar as $t, as as Pt, at as _n, au as Wn, av as Rt, aw as At, ax as Yn, ay as Jn, az as ne, aA as Et, aB as Mt, aC as Ft, aD as zt, aE as Xn, aF as Kn, aG as Qn, aH as Zn, aI as er, aJ as tr, aK as Bt, aL as Ve, aM as nr, aN as rr, aO as or, aP as sr, aQ as ir, aR as ar, aS as cr, aT as lr } from "./UpdatePrompt.DQlMOewA.js"; import { a as ie } from "./SearchSidebar.CtwbvK_x.js"; import { o as ae, d as dr, s as C, a as Ue, l as _e, F as ce, c as We } from "./schemas.BH6uGBRD.js"; import { u as Lt, b as Nt, c as ur, a as pr, d as hr, F as fr } from "./index.esm.MIM2ge_D.js"; @@ -8,7 +8,7 @@ import { T as Ne, C as gr } from "./Tabs.BfQDe6I2.js"; import { I as P } from "./Textarea.7FvXKGUa.js"; import { M, a as F, s as A, G as mr } from "./GeneralError.Dvjq_B8a.js"; import { P as xr, R as vr, T as br, a as yr, C as jr } from "./index.CduJ8u-z.js"; -import { D as Sr, t as he, r as fe, v as wr, x as Cr, i as Ir } from "./variables.-zE0Ry6h.js"; +import { D as Sr, r as he, q as fe, t as wr, v as Cr, i as Ir } from "./variables.CfsUBZ9t.js"; import { S as kr } from "./Switch.BqeA-dAP.js"; import { S as V } from "./TrashCan.DYWcjlk_.js"; import { C as Or } from "./CollapsibleCard.BWECYxhA.js"; @@ -17,7 +17,7 @@ import { S as Ye } from "./Select.Jkx8eZok.js"; import { o as Dr, s as qr } from "./listener.BM8yBkLB.js"; import { s as me, o as $r } from "./listener.BNWHQqef.js"; import { w as xe } from "./webapp-client.CEJRS8eu.js"; -import { c as X, s as Pr, H as Rr } from "./index.CRy0HWMP.js"; +import { l as X, s as Pr, H as Rr } from "./index.BXf_Hj-1.js"; import { b as Ar } from "./slice.CZpj5Zis.js"; import { E as je } from "./Banner.BZe2qI8d.js"; import { S as Er } from "./AngleDown.DBLEm0qt.js"; diff --git a/openapi-plugin/resources/web/tags.js b/openapi-plugin/resources/web/tags.js index 91fbd850..889a7c49 100644 --- a/openapi-plugin/resources/web/tags.js +++ b/openapi-plugin/resources/web/tags.js @@ -1,160 +1,161 @@ -import { j as o, c as re, d as te, s as ae, p as ne, a as se, t as ie, l as le, b as de, u as ce, e as d, T as g, R as j, f as D, g as ge, P as pe, n as ue, k as fe } from "./TriangleExclamation.BLKAXJ8l.js"; -import { o as he, c as xe } from "./listener.BNWHQqef.js"; -import { s as me } from "./rtk-query-react.modern.kJqw8Vn6.js"; -import { p as L, u as ve, r as k, a as be, I as ye, b as je, S as we, O as Ce, G as Ie, c as Te, d as Se, R as $e } from "./platform-api.xQ9SQy05.js"; -import { l as ke, c as Ae } from "./slice.s4_w0CJL.js"; -import { E as H } from "./Banner.BZe2qI8d.js"; -import { S as F } from "./TrashCan.DYWcjlk_.js"; -import { b as Le, u as y } from "./downshift.esm.CwBPPnfz.js"; -import { S as He } from "./AngleDown.DBLEm0qt.js"; -import { S as Oe } from "./Check.BVLcLyMb.js"; -import { M as De, I as Ne, a as Ee } from "./Checkbox.CtRxkpPH.js"; -const V = (e) => /* @__PURE__ */ o.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...e, children: /* @__PURE__ */ o.jsx("path", { d: "M345 39.1c-9.3-9.4-24.5-9.5-33.9-.2s-9.5 24.5-.2 33.9l127.7 129.3c33.9 34.3 33.9 89.4 0 123.7L326.7 439.1c-9.3 9.4-9.2 24.6.2 33.9s24.6 9.2 33.9-.2l112-113.2c52.4-53 52.4-138.2 0-191.2zM242.7 50.7c-12-12-28.3-18.7-45.3-18.7H48C21.5 32 0 53.5 0 80v149.5c0 17 6.7 33.3 18.7 45.3l168 168c25 25 65.5 25 90.5 0l133.5-133.5c25-25 25-65.5 0-90.5l-168-168zM48 80h149.5c4.2 0 8.3 1.7 11.3 4.7l168 168c6.2 6.2 6.2 16.4 0 22.6L243.3 408.8c-6.2 6.2-16.4 6.2-22.6 0l-168-168c-3-3-4.7-7.1-4.7-11.3zm96 64a32 32 0 1 0-64 0 32 32 0 1 0 64 0" }) }), Pe = { +import { j as e, c as se, d as ie, s as ce, p as de, a as le, t as ge, l as pe, b as ue, u as fe, e as d, T as g, R as C, f as $, g as he, P as xe, n as me, k as ve } from "./TriangleExclamation.BLKAXJ8l.js"; +import { o as ye, c as be } from "./listener.BNWHQqef.js"; +import { s as je, a as Ce } from "./rtk-query-react.modern.DVdYp0Is.js"; +import { p as N, u as we, r as L, a as Ie, b as Te, I as Se, c as $e, S as ke, O as Ae, G as Le, d as He, e as Ee, R as De } from "./platform-api.BtY3-lHu.js"; +import { l as Ne, c as Oe } from "./slice.s4_w0CJL.js"; +import { E } from "./Banner.BZe2qI8d.js"; +import { S as V } from "./TrashCan.DYWcjlk_.js"; +import { b as Pe, u as T } from "./downshift.esm.CwBPPnfz.js"; +import { S as Re } from "./AngleDown.DBLEm0qt.js"; +import { S as Be } from "./Check.BVLcLyMb.js"; +import { M as Fe, I as Me, a as Ve } from "./Checkbox.CtRxkpPH.js"; +const G = (o) => /* @__PURE__ */ e.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", width: "1em", height: "1em", ...o, children: /* @__PURE__ */ e.jsx("path", { d: "M345 39.1c-9.3-9.4-24.5-9.5-33.9-.2s-9.5 24.5-.2 33.9l127.7 129.3c33.9 34.3 33.9 89.4 0 123.7L326.7 439.1c-9.3 9.4-9.2 24.6.2 33.9s24.6 9.2 33.9-.2l112-113.2c52.4-53 52.4-138.2 0-191.2zM242.7 50.7c-12-12-28.3-18.7-45.3-18.7H48C21.5 32 0 53.5 0 80v149.5c0 17 6.7 33.3 18.7 45.3l168 168c25 25 65.5 25 90.5 0l133.5-133.5c25-25 25-65.5 0-90.5l-168-168zM48 80h149.5c4.2 0 8.3 1.7 11.3 4.7l168 168c6.2 6.2 6.2 16.4 0 22.6L243.3 408.8c-6.2 6.2-16.4 6.2-22.6 0l-168-168c-3-3-4.7-7.1-4.7-11.3zm96 64a32 32 0 1 0-64 0 32 32 0 1 0 64 0" }) }), Ge = { targetFileName: "", tagData: void 0, categories: [] -}, U = re({ +}, z = se({ name: "tags", - initialState: Pe, + initialState: Ge, reducers: { - loadTags: (e, t) => { - e.targetFileName = t.payload.targetFileName, e.tagData = t.payload.data; + loadTags: (o, t) => { + o.targetFileName = t.payload.targetFileName, o.tagData = t.payload.data; }, - saveTagsInStateOnly: (e, t) => { - e.tagData && (e.tagData[e.targetFileName] = t.payload[e.targetFileName]); + saveTagsInStateOnly: (o, t) => { + o.tagData && (o.tagData[o.targetFileName] = t.payload[o.targetFileName]); }, - saveTags: (e, t) => { - e.tagData && (e.tagData[e.targetFileName] = t.payload[e.targetFileName]); + saveTags: (o, t) => { + o.tagData && (o.tagData[o.targetFileName] = t.payload[o.targetFileName]); }, - sendHttpRequest: (e, t) => { + sendHttpRequest: (o, t) => { }, - showHttpResponse: (e, t) => { + showHttpResponse: (o, t) => { }, - showHttpError: (e, t) => { + showHttpError: (o, t) => { } } }), { - loadTags: Re, - saveTagsInStateOnly: Be, - saveTags: I, - sendHttpRequest: Ko, - showHttpResponse: Me, - showHttpError: Fe -} = U.actions, Ve = U.reducer, G = te(), N = G.startListening; -function Ue(e) { + loadTags: ze, + saveTagsInStateOnly: Ue, + saveTags: k, + sendHttpRequest: or, + showHttpResponse: qe, + showHttpError: Qe +} = z.actions, We = z.reducer, U = ie(), R = U.startListening; +function Ke(o) { const t = { - sendHttpRequest: he(N, e), - saveTags: () => N({ - actionCreator: I, - effect: async (n, a) => { - e.postMessage({ + sendHttpRequest: ye(R, o), + saveTags: () => R({ + actionCreator: k, + effect: async (a, n) => { + o.postMessage({ command: "saveTags", - payload: n.payload + payload: a.payload }); } }) }; - return ae(t), G; + return ce(t), U; } -const Ge = { - theme: ie, - config: Ae, - client: xe, - tags: Ve, - [L.reducerPath]: L.reducer -}, ze = { - changeTheme: ne, - loadTags: Re, - loadConfig: ke, - showHttpResponse: Me, - showHttpError: Fe -}, Qe = (e, t) => { - const n = se({ - reducer: Ge, - middleware: (a) => a().prepend(e.middleware).concat(le, L.middleware), +const _e = { + theme: ge, + config: Oe, + client: be, + tags: We, + [N.reducerPath]: N.reducer +}, Ye = { + changeTheme: de, + loadTags: ze, + loadConfig: Ne, + showHttpResponse: qe, + showHttpError: Qe +}, Je = (o, t) => { + const a = le({ + reducer: _e, + middleware: (n) => n().prepend(o.middleware).concat(pe, N.middleware), preloadedState: { theme: t } }); - return me(n.dispatch), n; -}, z = () => ce(), E = de; + return je(a.dispatch), a; +}, q = () => fe(), B = ue; function Q({ - options: e, + options: o, placeholder: t, - keepOpen: n, - applyHoverCss: a, + keepOpen: a, + applyHoverCss: n, filter: r, - renderer: s, - onItemSelected: i + renderer: c, + onItemSelected: s, + onInputValueChanged: i }) { - const [l, c] = j.useState(""), f = j.useMemo(() => r(e, l), [e, l]), { getDropdownProps: p } = Le({ - selectedItems: e - }), { isOpen: u, getToggleButtonProps: A, getMenuProps: b, getInputProps: S, getItemProps: $ } = y({ - items: f, - itemToString(m) { - return m ? m.label : "null"; + const [l, u] = C.useState(""), p = C.useMemo(() => r(o, l), [o, l]), { getDropdownProps: m } = Pe({ + selectedItems: o + }), { isOpen: v, getToggleButtonProps: y, getMenuProps: w, getInputProps: S, getItemProps: I } = T({ + items: p, + itemToString(h) { + return h ? h.label : "null"; }, inputValue: l, - stateReducer(m, h) { - const { changes: x, type: v } = h; - switch (v) { - case y.stateChangeTypes.InputKeyDownEnter: - case y.stateChangeTypes.ItemClick: + stateReducer(h, f) { + const { changes: x, type: D } = f; + switch (D) { + case T.stateChangeTypes.InputKeyDownEnter: + case T.stateChangeTypes.ItemClick: return { ...x, - isOpen: n + isOpen: a }; default: return x; } }, - onStateChange({ inputValue: m, type: h, selectedItem: x }) { - switch (h) { - case y.stateChangeTypes.InputKeyDownEnter: - case y.stateChangeTypes.ItemClick: - case y.stateChangeTypes.InputBlur: - x && (i(x), n || c("")); + onStateChange({ inputValue: h, type: f, selectedItem: x }) { + switch (f) { + case T.stateChangeTypes.InputKeyDownEnter: + case T.stateChangeTypes.ItemClick: + case T.stateChangeTypes.InputBlur: + x && (s(x), a || (u(""), i?.(""))); break; - case y.stateChangeTypes.InputChange: - c(m || ""); + case T.stateChangeTypes.InputChange: + u(h || ""), i?.(h || ""); break; } } - }), w = A(); - delete w.ref; - const C = a ? Je : q; - return /* @__PURE__ */ o.jsxs(We, { children: [ - /* @__PURE__ */ o.jsxs(Ke, { children: [ - /* @__PURE__ */ o.jsx( - _e, + }), b = y(); + delete b.ref; + const j = n ? ro : W; + return /* @__PURE__ */ e.jsxs(Ze, { children: [ + /* @__PURE__ */ e.jsxs(eo, { children: [ + /* @__PURE__ */ e.jsx( + oo, { placeholder: t, - ...S(p({ preventKeyAction: u })) + ...S(m({ preventKeyAction: v })) } ), - /* @__PURE__ */ o.jsx(He, { ...w }) + /* @__PURE__ */ e.jsx(Re, { ...b }) ] }), - /* @__PURE__ */ o.jsx(C, { ...b(), $isOpen: u, children: u && f.map((m, h) => /* @__PURE__ */ o.jsx(Xe, { ...$({ item: m, index: h }), children: s(m, h, l) }, `li-${h}`)) }) + /* @__PURE__ */ e.jsx(j, { ...w(), $isOpen: v, children: v && p.map((h, f) => /* @__PURE__ */ e.jsx(to, { ...I({ item: h, index: f }), children: c(h, f, l) }, `li-${f}`)) }) ] }); } -function T({ value: e, searchValue: t }) { - if (!t || !e) - return /* @__PURE__ */ o.jsx("span", { children: e }); - let n = -1, a = 0; - const r = e.toLowerCase(), s = t.toLocaleLowerCase(), i = []; - for (; (n = r.indexOf(s, n + 1)) != -1; ) - i.push({ text: e.substring(a, n), mark: !1 }), a = n + s.length, i.push({ text: e.substring(n, a), mark: !0 }); - return i.push({ text: e.substring(a), mark: !1 }), /* @__PURE__ */ o.jsx("span", { children: i.map((l, c) => l.mark ? /* @__PURE__ */ o.jsx(qe, { children: l.text }, c) : l.text) }); +function H({ value: o, searchValue: t }) { + if (!t || !o) + return /* @__PURE__ */ e.jsx("span", { children: o }); + let a = -1, n = 0; + const r = o.toLowerCase(), c = t.toLocaleLowerCase(), s = []; + for (; (a = r.indexOf(c, a + 1)) != -1; ) + s.push({ text: o.substring(n, a), mark: !1 }), n = a + c.length, s.push({ text: o.substring(a, n), mark: !0 }); + return s.push({ text: o.substring(n), mark: !1 }), /* @__PURE__ */ e.jsx("span", { children: s.map((i, l) => i.mark ? /* @__PURE__ */ e.jsx(Xe, { children: i.text }, l) : i.text) }); } -const qe = d.mark` +const Xe = d.mark` font-weight: bold; background-color: #cca700; border-radius: 3px; border: 1px solid #cca700; opacity: 0.5; -`, We = d.div` +`, Ze = d.div` position: relative; -`, Ke = d.div` +`, eo = d.div` display: flex; flex-direction: row; gap: 0.5rem; @@ -163,7 +164,7 @@ const qe = d.mark` margin-left: 3px; fill: var(${g.foreground}); } -`, _e = d.input` +`, oo = d.input` min-width: 540px; background-color: var(${g.inputBackground}); border-radius: 3px; @@ -171,7 +172,7 @@ const qe = d.mark` color: var(${g.inputForeground}); height: 25px; cursor: pointer; -`, q = d.ul` +`, W = d.ul` position: absolute; z-index: 1; left: 0; @@ -184,7 +185,7 @@ const qe = d.mark` background-color: var(${g.dropdownBackground}); color: var(${g.dropdownForeground}); - ${({ $isOpen: e }) => e && ` + ${({ $isOpen: o }) => o && ` border: 1px solid var(${g.dropdownBorder}); padding: 4px; `} @@ -200,7 +201,7 @@ const qe = d.mark` & > li[aria-disabled="true"]:hover { background-color: transparent; } -`, Je = d(q)` +`, ro = d(W)` & > li { border-width: 1px; border-style: solid; @@ -213,49 +214,53 @@ const qe = d.mark` background-color: var(${g.listHoverBackground}); border-color: var(${g.border}); } -`, Xe = d.li` +`, to = d.li` display: flex; gap: 5px; flex-direction: column; `; -function Ye({ - type: e, +function K({ + type: o, options: t, - onItemSelected: n + onItemSelected: a, + onInputValueChanged: n }) { - return /* @__PURE__ */ o.jsx( + return /* @__PURE__ */ e.jsx( Q, { options: t, - placeholder: (e === "collection" ? "Collection" : "API") + " name or UUID", + placeholder: (o === "collection" ? "Collection" : "API") + " name", keepOpen: !1, applyHoverCss: !0, - filter: (a, r) => { - const s = r.toLowerCase(); - return a.filter((i) => i.value.desc.name.toLocaleLowerCase().includes(s) || i.value.desc.id.toLocaleLowerCase().includes(s)); + filter: (r, c) => { + if (n !== void 0) + return r; + const s = c.toLowerCase(); + return r.filter((i) => i.value.desc.name.toLocaleLowerCase().includes(s) || i.value.desc.id.toLocaleLowerCase().includes(s)); }, - renderer: (a, r, s) => /* @__PURE__ */ o.jsxs(o.Fragment, { children: [ - /* @__PURE__ */ o.jsx(T, { value: a.label, searchValue: s }), - /* @__PURE__ */ o.jsx(Ze, { children: /* @__PURE__ */ o.jsx( - T, + renderer: (r, c, s) => /* @__PURE__ */ e.jsxs(e.Fragment, { children: [ + /* @__PURE__ */ e.jsx(H, { value: r.label, searchValue: s }), + /* @__PURE__ */ e.jsx(ao, { children: /* @__PURE__ */ e.jsx( + H, { - value: `UUID: ${a.value.desc.id}`, + value: `UUID: ${r.value.desc.id}`, searchValue: s } ) }), - e === "api" && a.value.tags.length > 0 && /* @__PURE__ */ o.jsxs(eo, { children: [ - a.value.tags.length > 0 && /* @__PURE__ */ o.jsx(V, {}), - a.value.tags.length > 0 && /* @__PURE__ */ o.jsx(oo, { children: `${a.value.tags.length} tags` }) + o === "api" && r.value.tags.length > 0 && /* @__PURE__ */ e.jsxs(no, { children: [ + r.value.tags.length > 0 && /* @__PURE__ */ e.jsx(G, {}), + r.value.tags.length > 0 && /* @__PURE__ */ e.jsx(so, { children: `${r.value.tags.length} tags` }) ] }) ] }), - onItemSelected: n + onItemSelected: a, + onInputValueChanged: n } ); } -const Ze = d.span` +const ao = d.span` font-weight: smaller; color: var(${g.disabledForeground}); -`, eo = d.div` +`, no = d.div` display: flex; flex-direction: row; align-items: flex-end; @@ -264,168 +269,238 @@ const Ze = d.span` margin-left: 3px; fill: var(${g.foreground}); } -`, oo = d.div` +`, so = d.div` font-size: 90%; `; -function ro({ - targetFileName: e, +function io(o, t) { + const [a, n] = $.useState(o); + return $.useEffect(() => { + const r = setTimeout(() => n(o), t); + return () => clearTimeout(r); + }, [o, t]), a; +} +const co = 300; +function lo({ + targetFileName: o, tagData: t }) { - const n = z(), a = t[e], r = a === null || Array.isArray(a) ? void 0 : a, [s, i] = j.useState(void 0), [l, c] = j.useState(void 0); - D.useEffect(() => { - i(void 0), c(void 0); - }, [e]); - const f = s || r?.collectionId; - return /* @__PURE__ */ o.jsxs(ao, { children: [ - /* @__PURE__ */ o.jsx( - P, + const a = q(), n = t[o], r = n === null || Array.isArray(n) ? void 0 : n, [c, s] = C.useState(void 0), [i, l] = C.useState(void 0); + $.useEffect(() => { + s(void 0), l(void 0); + }, [o]); + const u = c ? c.value.desc.id : r?.collectionId; + return /* @__PURE__ */ e.jsxs(uo, { children: [ + /* @__PURE__ */ e.jsx( + go, { - type: "collection", apiEntry: r, - selectedOptionId: s ? s.id : r?.collectionId, - getQueryParameter: () => "", + selectedOption: c, onOptionRemoved: () => { - c(void 0), i(void 0), n(I({ [e]: null })); + l(void 0), s(void 0), a(k({ [o]: null })); }, onOptionSelected: (p) => { - c(void 0), i(p), n(I({ [e]: null })); + l(void 0), s(p), a(k({ [o]: null })); } } ), - f && /* @__PURE__ */ o.jsx( - P, + u && /* @__PURE__ */ e.jsx( + po, { - type: "api", apiEntry: r, - selectedOptionId: l ? l.id : r?.apiId, - getQueryParameter: () => s ? s.value.desc.id : r?.collectionId, + collectionId: u, + selectedOptionId: i ? i.id : r?.apiId, onOptionRemoved: () => { - c(void 0); + l(void 0); const p = {}; - p[e] = { + p[o] = { apiId: "", apiName: "", - collectionId: s?.value.desc.id || r?.collectionId, - collectionName: s?.value.desc.name || r?.collectionName - }, n(Be(p)); + collectionId: c?.value.desc.id || r?.collectionId, + collectionName: c?.value.desc.name || r?.collectionName + }, a(Ue(p)); }, onOptionSelected: (p) => { - c(p); - const u = {}; - u[e] = { + l(p); + const m = {}; + m[o] = { apiId: p.value.desc.id, apiName: p.value.desc.name, - collectionId: s?.value.desc.id || r?.collectionId, - collectionName: s?.value.desc.name || r?.collectionName - }, n(I(u)); + collectionId: c?.value.desc.id || r?.collectionId, + collectionName: c?.value.desc.name || r?.collectionName + }, a(k(m)); } } ) ] }); } -function P({ - type: e, - apiEntry: t, - selectedOptionId: n, - getQueryParameter: a, - onOptionRemoved: r, - onOptionSelected: s +function go({ + apiEntry: o, + selectedOption: t, + onOptionRemoved: a, + onOptionSelected: n }) { - const { data: i, error: l, isLoading: c } = e === "collection" ? ve(void 0, k) : be(a(), k); - let f = []; - i && i.forEach( - (u) => f.push({ - id: u.desc.id, - value: u, - label: u.desc.name + const [r, c] = C.useState(""), s = io(r, co), { data: i, error: l, isFetching: u } = we(s, L), [p, m] = C.useState(void 0); + $.useEffect(() => { + i !== void 0 && m(i); + }, [i]); + const v = i ?? p, y = t === void 0 ? o?.collectionId : void 0, { + data: w, + error: S, + isFetching: I + } = Ie(y || Ce, L), b = (v?.collections || []).filter((f) => f.desc.id !== t?.id).map((f) => ({ + id: f.desc.id, + value: f, + label: f.desc.name + })), j = l || S, h = v !== void 0 && v.total > v.collections.length; + return /* @__PURE__ */ e.jsxs(_, { children: [ + /* @__PURE__ */ e.jsxs(Y, { children: [ + /* @__PURE__ */ e.jsx(O, { children: "Collection" }), + /* @__PURE__ */ e.jsxs(fo, { children: [ + /* @__PURE__ */ e.jsx( + K, + { + type: "collection", + options: b, + onItemSelected: n, + onInputValueChanged: c + } + ), + u && /* @__PURE__ */ e.jsx(F, { children: "Searching for collections..." }), + !u && h && /* @__PURE__ */ e.jsx(F, { children: `Showing ${v.collections.length} of ${v.total} matching collections, refine your search` }) + ] }) + ] }), + !j && t && /* @__PURE__ */ e.jsx( + A, + { + id: t.value.desc.id, + name: t.label, + isLoaded: !0, + onOptionRemoved: a + } + ), + !j && y && !I && (w ? /* @__PURE__ */ e.jsx( + A, + { + id: w.desc.id, + name: w.desc.name, + isLoaded: !0, + onOptionRemoved: a + } + ) : /* @__PURE__ */ e.jsx( + A, + { + id: y, + name: o?.collectionName, + error: "This collection is not found on the server", + isLoaded: !1, + onOptionRemoved: a + } + )), + /* @__PURE__ */ e.jsx(ee, { children: j && /* @__PURE__ */ e.jsxs(E, { message: "Failed to load collections", children: [ + "HTTPError: Response code ", + j.code, + " (", + j.message, + ")" + ] }) }) + ] }); +} +function po({ + apiEntry: o, + collectionId: t, + selectedOptionId: a, + onOptionRemoved: n, + onOptionSelected: r +}) { + const { data: c, error: s, isLoading: i } = Te(t, L); + let l = []; + c && c.forEach( + (p) => l.push({ + id: p.desc.id, + value: p, + label: p.desc.name }) ); - const p = f?.filter((u) => u.id === n)[0]; - return p && (f = f?.filter((u) => u.id !== p.id)), /* @__PURE__ */ o.jsxs(to, { children: [ - /* @__PURE__ */ o.jsxs(no, { children: [ - c && /* @__PURE__ */ o.jsx(B, { children: "Loading " + (e === "collection" ? "collections" : "APIs") + " from the server..." }), - !c && /* @__PURE__ */ o.jsx(B, { children: e === "collection" ? "Collection" : "API" }), - !c && /* @__PURE__ */ o.jsx( - Ye, + const u = l?.filter((p) => p.id === a)[0]; + return u && (l = l?.filter((p) => p.id !== u.id)), /* @__PURE__ */ e.jsxs(_, { children: [ + /* @__PURE__ */ e.jsxs(Y, { children: [ + i && /* @__PURE__ */ e.jsx(O, { children: "Loading APIs from the server..." }), + !i && /* @__PURE__ */ e.jsx(O, { children: "API" }), + !i && /* @__PURE__ */ e.jsx( + K, { - type: e, - options: f, - onItemSelected: s + type: "api", + options: l, + onItemSelected: r } ) ] }), - !c && !l && p && /* @__PURE__ */ o.jsx( - R, + !i && !s && u && /* @__PURE__ */ e.jsx( + A, { - id: `UUID: ${p.value.desc.id}`, - name: p.label, - tags: e === "collection" ? void 0 : p.value.tags, + id: u.value.desc.id, + name: u.label, + tags: u.value.tags, isLoaded: !0, - onOptionRemoved: r + onOptionRemoved: n } ), - !c && !l && !p && t && (e === "collection" && t.collectionId || e === "api" && t.apiId) && /* @__PURE__ */ o.jsx( - R, + !i && !s && !u && o && o.apiId && /* @__PURE__ */ e.jsx( + A, { - id: e === "collection" ? t.collectionId : t.apiId, - name: e === "collection" ? t.collectionName : t.apiName, - error: `This ${e} is not found on the server`, + id: o.apiId, + name: o.apiName, + error: "This api is not found on the server", isLoaded: !1, - onOptionRemoved: r + onOptionRemoved: n } ), - /* @__PURE__ */ o.jsx(so, { children: l && /* @__PURE__ */ o.jsxs( - H, - { - message: "Failed to load " + (e === "collection" ? "collections" : "APIs"), - children: [ - "HTTPError: Response code ", - l.code, - " (", - l.message, - ")" - ] - } - ) }) + /* @__PURE__ */ e.jsx(ee, { children: s && /* @__PURE__ */ e.jsxs(E, { message: "Failed to load APIs", children: [ + "HTTPError: Response code ", + s.code, + " (", + s.message, + ")" + ] }) }) ] }); } -function R({ - id: e, +function A({ + id: o, name: t, - error: n, - tags: a, + error: a, + tags: n, isLoaded: r, - onOptionRemoved: s + onOptionRemoved: c }) { - return /* @__PURE__ */ o.jsxs(W, { $isLoaded: r, children: [ - /* @__PURE__ */ o.jsxs(K, { children: [ - /* @__PURE__ */ o.jsx(J, { children: t }), - /* @__PURE__ */ o.jsxs(O, { children: [ + return /* @__PURE__ */ e.jsxs(J, { $isLoaded: r, children: [ + /* @__PURE__ */ e.jsxs(X, { children: [ + /* @__PURE__ */ e.jsx(oe, { children: t }), + /* @__PURE__ */ e.jsxs(P, { children: [ "UUID: ", - e + o ] }), - a && /* @__PURE__ */ o.jsxs(lo, { children: [ - a.length > 0 && /* @__PURE__ */ o.jsx(V, {}), - a.map((i, l) => /* @__PURE__ */ o.jsxs(co, { children: [ - i.categoryName, + n && /* @__PURE__ */ e.jsxs(xo, { children: [ + n.length > 0 && /* @__PURE__ */ e.jsx(G, {}), + n.map((s, i) => /* @__PURE__ */ e.jsxs(mo, { children: [ + s.categoryName, ": ", - i.tagName - ] }, `api-tag-${l}`)) + s.tagName + ] }, `api-tag-${i}`)) ] }), - !r && /* @__PURE__ */ o.jsx(io, { children: n }) + !r && /* @__PURE__ */ e.jsx(ho, { children: a }) ] }), - /* @__PURE__ */ o.jsx(_, { children: /* @__PURE__ */ o.jsx( - X, + /* @__PURE__ */ e.jsx(Z, { children: /* @__PURE__ */ e.jsx( + re, { - onClick: (i) => { - i.stopPropagation(), s(); + onClick: (s) => { + s.stopPropagation(), c(); }, - children: /* @__PURE__ */ o.jsx(F, {}) + children: /* @__PURE__ */ e.jsx(V, {}) } ) }) ] }); } -const to = d.div` +const _ = d.div` gap: 5px; display: flex; flex-direction: column; @@ -434,11 +509,11 @@ d.div` font-weight: 700; margin-bottom: 16px; `; -const ao = d.div` +const uo = d.div` display: flex; flex-direction: column; gap: 7px; -`, no = d.div` +`, Y = d.div` display: flex; flex-direction: row; gap: 20px; @@ -450,7 +525,7 @@ const ao = d.div` align-items: center; justify-content: space-between; padding: 16px; -`, W = d.div` +`, J = d.div` display: flex; flex-direction: row; min-height: 50px; @@ -459,40 +534,47 @@ const ao = d.div` border-width: 1px; border-style: solid; border-radius: 3px; - ${({ $isLoaded: e }) => !e && ` + ${({ $isLoaded: o }) => !o && ` border-color: var(${g.errorBorder}); `} -`, K = d.div` +`, X = d.div` display: flex; flex-direction: column; width: 97%; gap: 10px; padding: 16px; -`, _ = d.div` +`, Z = d.div` display: flex; flex-direction: column; justify-content: center; -`, so = d.div` +`, fo = d.div` + display: flex; + flex-direction: column; + gap: 5px; +`, F = d.span` + font-size: 90%; + color: var(${g.disabledForeground}); +`, ee = d.div` display: flex; flex-direction: column; gap: 7px; -`, B = d.span` +`, O = d.span` font-weight: bold; -`, J = d.span` +`, oe = d.span` font-weight: bold; -`, io = d.span` +`, ho = d.span` color: var(${g.errorForeground}); -`, O = d.span` +`, P = d.span` font-weight: smaller; color: var(${g.disabledForeground}); -`, X = d.span` +`, re = d.span` font-weight: bold; cursor: pointer; padding: 16px; > svg { fill: var(${g.foreground}); } -`, lo = d.div` +`, xo = d.div` display: flex; flex-direction: row; flex-wrap: wrap; @@ -502,7 +584,7 @@ const ao = d.div` margin-left: 3px; fill: var(${g.foreground}); } -`, co = d.div` +`, mo = d.div` border-color: var(${g.border}); border-width: 1px; border-style: solid; @@ -510,143 +592,143 @@ const ao = d.div` padding: 3px; font-size: 90%; `; -function go({ - categories: e, +function vo({ + categories: o, selectedTagIds: t, - onTagSelected: n + onTagSelected: a }) { - const a = []; - return e && (e.sort((r, s) => (r.onlyAdminCanTag ? 1 : 0) - (s.onlyAdminCanTag ? 1 : 0)), e.forEach( - (r) => a.push({ + const n = []; + return o && (o.sort((r, c) => (r.onlyAdminCanTag ? 1 : 0) - (c.onlyAdminCanTag ? 1 : 0)), o.forEach( + (r) => n.push({ id: r.categoryId, value: r, label: r.categoryId }) - )), /* @__PURE__ */ o.jsx( + )), /* @__PURE__ */ e.jsx( Q, { - options: a, + options: n, placeholder: "Tag or category name", keepOpen: !0, applyHoverCss: !1, - filter: (r, s) => { - const i = s.toLowerCase(); - return r.filter((l) => Y(l.value, i)); + filter: (r, c) => { + const s = c.toLowerCase(); + return r.filter((i) => te(i.value, s)); }, - renderer: (r, s, i) => /* @__PURE__ */ o.jsxs(o.Fragment, { children: [ - /* @__PURE__ */ o.jsx(vo, { children: /* @__PURE__ */ o.jsx(T, { value: r.value.categoryName, searchValue: i }) }), - r.value.tags.length > 0 && r.value.multipleChoicesAllowed && !r.value.onlyAdminCanTag && /* @__PURE__ */ o.jsx(bo, { children: "Multiple choices are allowed" }), - r.value.onlyAdminCanTag && /* @__PURE__ */ o.jsx(yo, { children: "Only admin can tag" }), - !r.value.onlyAdminCanTag && /* @__PURE__ */ o.jsxs(jo, { children: [ - !r.value.multipleChoicesAllowed && /* @__PURE__ */ o.jsx( - mo, + renderer: (r, c, s) => /* @__PURE__ */ e.jsxs(e.Fragment, { children: [ + /* @__PURE__ */ e.jsx(To, { children: /* @__PURE__ */ e.jsx(H, { value: r.value.categoryName, searchValue: s }) }), + r.value.tags.length > 0 && r.value.multipleChoicesAllowed && !r.value.onlyAdminCanTag && /* @__PURE__ */ e.jsx(So, { children: "Multiple choices are allowed" }), + r.value.onlyAdminCanTag && /* @__PURE__ */ e.jsx($o, { children: "Only admin can tag" }), + !r.value.onlyAdminCanTag && /* @__PURE__ */ e.jsxs(ko, { children: [ + !r.value.multipleChoicesAllowed && /* @__PURE__ */ e.jsx( + Io, { - value: po(r.value, t), - children: r.value.tags.filter((l) => M(r.value, l, i)).map((l, c) => /* @__PURE__ */ o.jsx( - fo, + value: yo(r.value, t), + children: r.value.tags.filter((i) => M(r.value, i, s)).map((i, l) => /* @__PURE__ */ e.jsx( + jo, { category: r.value, - tag: l, - checked: t.has(l.tagId), - inputValue: i, - onTagSelected: n + tag: i, + checked: t.has(i.tagId), + inputValue: s, + onTagSelected: a }, - `${l.tagId}${c}` + `${i.tagId}${l}` )) } ), - r.value.multipleChoicesAllowed && /* @__PURE__ */ o.jsx(o.Fragment, { children: r.value.tags.filter((l) => M(r.value, l, i)).map((l, c) => /* @__PURE__ */ o.jsx( - uo, + r.value.multipleChoicesAllowed && /* @__PURE__ */ e.jsx(e.Fragment, { children: r.value.tags.filter((i) => M(r.value, i, s)).map((i, l) => /* @__PURE__ */ e.jsx( + bo, { category: r.value, - tag: l, - checked: t.has(l.tagId), - inputValue: i, - onTagSelected: n + tag: i, + checked: t.has(i.tagId), + inputValue: s, + onTagSelected: a }, - `${l.tagId}${c}` + `${i.tagId}${l}` )) }) - ] }, `${r.value.categoryId}${s}`) + ] }, `${r.value.categoryId}${c}`) ] }), onItemSelected: (r) => { } } ); } -function po(e, t) { - for (const n of e.tags) - if (t.has(n.tagId)) - return n.tagId; +function yo(o, t) { + for (const a of o.tags) + if (t.has(a.tagId)) + return a.tagId; return ""; } -function M(e, t, n) { - const a = n.toLowerCase(); - return Y(e, a) || Z(t, a); +function M(o, t, a) { + const n = a.toLowerCase(); + return te(o, n) || ae(t, n); } -function Y(e, t) { - if (e.categoryName.toLocaleLowerCase().includes(t)) +function te(o, t) { + if (o.categoryName.toLocaleLowerCase().includes(t)) return !0; - for (const n of e.tags) - if (Z(n, t)) + for (const a of o.tags) + if (ae(a, t)) return !0; return !1; } -function Z(e, t) { - return e.tagName.toLocaleLowerCase().includes(t); +function ae(o, t) { + return o.tagName.toLocaleLowerCase().includes(t); } -function uo({ - category: e, +function bo({ + category: o, tag: t, - checked: n, - inputValue: a, + checked: a, + inputValue: n, onTagSelected: r }) { - return /* @__PURE__ */ o.jsxs( - ho, + return /* @__PURE__ */ e.jsxs( + Co, { - onClick: (s) => { + onClick: (c) => { if (t.onlyAdminCanTag) return; - const i = s.currentTarget.children[0]; - if (i) { - const l = i.dataset.state === "checked"; - r(e.categoryId, t.tagId, !l); + const s = c.currentTarget.children[0]; + if (s) { + const i = s.dataset.state === "checked"; + r(o.categoryId, t.tagId, !i); } }, children: [ - /* @__PURE__ */ o.jsx(De, { checked: n, children: /* @__PURE__ */ o.jsx(Ne, { children: /* @__PURE__ */ o.jsx(Oe, {}) }) }), - /* @__PURE__ */ o.jsx("label", { children: /* @__PURE__ */ o.jsx(T, { value: t.tagName, searchValue: a }) }) + /* @__PURE__ */ e.jsx(Fe, { checked: a, children: /* @__PURE__ */ e.jsx(Me, { children: /* @__PURE__ */ e.jsx(Be, {}) }) }), + /* @__PURE__ */ e.jsx("label", { children: /* @__PURE__ */ e.jsx(H, { value: t.tagName, searchValue: n }) }) ] } ); } -function fo({ - category: e, +function jo({ + category: o, tag: t, - checked: n, - inputValue: a, + checked: a, + inputValue: n, onTagSelected: r }) { - return /* @__PURE__ */ o.jsxs( - xo, + return /* @__PURE__ */ e.jsxs( + wo, { - onClick: (s) => { + onClick: (c) => { if (t.onlyAdminCanTag) return; - const i = s.currentTarget.children[0]; - if (i) { - const l = i.dataset.state === "checked"; - r(e.categoryId, t.tagId, !l); + const s = c.currentTarget.children[0]; + if (s) { + const i = s.dataset.state === "checked"; + r(o.categoryId, t.tagId, !i); } }, children: [ - !t.onlyAdminCanTag && /* @__PURE__ */ o.jsx(ye, { value: t.tagId, children: /* @__PURE__ */ o.jsx(je, { children: /* @__PURE__ */ o.jsx(we, {}) }) }), - /* @__PURE__ */ o.jsx("label", { children: /* @__PURE__ */ o.jsx(T, { value: t.tagName, searchValue: a }) }) + !t.onlyAdminCanTag && /* @__PURE__ */ e.jsx(Se, { value: t.tagId, children: /* @__PURE__ */ e.jsx($e, { children: /* @__PURE__ */ e.jsx(ke, {}) }) }), + /* @__PURE__ */ e.jsx("label", { children: /* @__PURE__ */ e.jsx(H, { value: t.tagName, searchValue: n }) }) ] } ); } -const ho = d(Ee)` +const Co = d(Ve)` padding: 2px; border-width: 1px; border-style: solid; @@ -663,7 +745,7 @@ const ho = d(Ee)` background-color: var(${g.listHoverBackground}); border-color: var(${g.border}); } -`, xo = d(Ce)` +`, wo = d(Ae)` padding: 2px; border-width: 1px; border-style: solid; @@ -680,177 +762,177 @@ const ho = d(Ee)` background-color: var(${g.listHoverBackground}); border-color: var(${g.border}); } -`, mo = d(Ie)` +`, Io = d(Le)` flex-direction: column; -`, vo = d.span` +`, To = d.span` font-weight: bold; -`, bo = d.span` +`, So = d.span` font-weight: smaller; color: var(${g.disabledForeground}); -`, yo = d.span` +`, $o = d.span` font-weight: smaller; color: var(${g.errorForeground}); -`, jo = d.div` +`, ko = d.div` display: flex; flex-direction: column; gap: 5px; `; -function wo({ - targetFileName: e, +function Ao({ + targetFileName: o, tagData: t }) { const { - data: n, - error: a, + data: a, + error: n, isLoading: r - } = Te(void 0, k), { - data: s, - error: i, - isLoading: l - } = Se(void 0, k), c = r || l, f = $o(n || [], s || []), p = /* @__PURE__ */ new Set(), u = t[e]; - if (t && u && Array.isArray(u)) - for (const w of u) - p.add(w.tagId); - const A = z(), [b, S] = j.useState(p); - D.useEffect(() => { - S(p); - }, [e]); - const $ = function(w, C, m) { - const h = new Set(b); - if (m) { - h.add(C); - for (const x of f) - if (x.categoryId === w && !x.multipleChoicesAllowed) { - for (const v of x.tags) - v.tagId !== C && h.delete(v.tagId); + } = He(void 0, L), { + data: c, + error: s, + isLoading: i + } = Ee(void 0, L), l = r || i, u = No(a || [], c || []), p = /* @__PURE__ */ new Set(), m = t[o]; + if (t && m && Array.isArray(m)) + for (const I of m) + p.add(I.tagId); + const v = q(), [y, w] = C.useState(p); + $.useEffect(() => { + w(p); + }, [o]); + const S = function(I, b, j) { + const h = new Set(y); + if (j) { + h.add(b); + for (const f of u) + if (f.categoryId === I && !f.multipleChoicesAllowed) { + for (const x of f.tags) + x.tagId !== b && h.delete(x.tagId); break; } - } else if (C === "") { - const x = /* @__PURE__ */ new Set(); - f.forEach( - (v) => v.tags.forEach((oe) => x.add(oe.tagId)) + } else if (b === "") { + const f = /* @__PURE__ */ new Set(); + u.forEach( + (x) => x.tags.forEach((D) => f.add(D.tagId)) ); - for (const v of b) - x.has(v) || h.delete(v); + for (const x of y) + f.has(x) || h.delete(x); } else - h.delete(C); - S(h), A(I(So(e, f, h))); + h.delete(b); + w(h), v(k(Do(o, u, h))); }; - return /* @__PURE__ */ o.jsxs("div", { children: [ - /* @__PURE__ */ o.jsxs(ko, { children: [ - /* @__PURE__ */ o.jsxs(Ao, { children: [ - c && /* @__PURE__ */ o.jsx(ee, { children: "Loading data from the server..." }), - !c && /* @__PURE__ */ o.jsx(Co, { selectedTagIds: b }), - !c && /* @__PURE__ */ o.jsx( - go, + return /* @__PURE__ */ e.jsxs("div", { children: [ + /* @__PURE__ */ e.jsxs(Oo, { children: [ + /* @__PURE__ */ e.jsxs(Po, { children: [ + l && /* @__PURE__ */ e.jsx(ne, { children: "Loading data from the server..." }), + !l && /* @__PURE__ */ e.jsx(Lo, { selectedTagIds: y }), + !l && /* @__PURE__ */ e.jsx( + vo, { - categories: f, - selectedTagIds: b, - onTagSelected: $ + categories: u, + selectedTagIds: y, + onTagSelected: S } ) ] }), - /* @__PURE__ */ o.jsxs(Lo, { children: [ - a && /* @__PURE__ */ o.jsxs(H, { message: "Failed to load categories", children: [ + /* @__PURE__ */ e.jsxs(Ro, { children: [ + n && /* @__PURE__ */ e.jsxs(E, { message: "Failed to load categories", children: [ "HTTPError: Response code ", - a.code, + n.code, " (", - a.message, + n.message, ")" ] }), - i && /* @__PURE__ */ o.jsxs(H, { message: "Failed to load tags", children: [ + s && /* @__PURE__ */ e.jsxs(E, { message: "Failed to load tags", children: [ "HTTPError: Response code ", - i.code, + s.code, " (", - i.message, + s.message, ")" ] }) ] }) ] }), - !c && !(i || a) && Array.isArray(u) && /* @__PURE__ */ o.jsx( - Io, + !l && !(s || n) && Array.isArray(m) && /* @__PURE__ */ e.jsx( + Ho, { - tagEntries: u, - categories: f, - selectedTagIds: b, - onTagSelected: $ + tagEntries: m, + categories: u, + selectedTagIds: y, + onTagSelected: S } ) ] }); } -function Co({ selectedTagIds: e }) { - const t = e.size; - return /* @__PURE__ */ o.jsxs(ee, { children: [ +function Lo({ selectedTagIds: o }) { + const t = o.size; + return /* @__PURE__ */ e.jsxs(ne, { children: [ t, " tags selected" ] }); } -function Io({ - tagEntries: e, +function Ho({ + tagEntries: o, categories: t, - selectedTagIds: n, - onTagSelected: a + selectedTagIds: a, + onTagSelected: n }) { - return /* @__PURE__ */ o.jsx(Ho, { children: To(e, t, n).map((r, s) => /* @__PURE__ */ o.jsxs(W, { $isLoaded: r.loaded, children: [ - /* @__PURE__ */ o.jsxs(K, { children: [ - /* @__PURE__ */ o.jsx(J, { children: r.loaded ? r.fullTagName : "These tags do not exist on the server, please remove them" }), - r.loaded && /* @__PURE__ */ o.jsxs(O, { children: [ + return /* @__PURE__ */ e.jsx(Bo, { children: Eo(o, t, a).map((r, c) => /* @__PURE__ */ e.jsxs(J, { $isLoaded: r.loaded, children: [ + /* @__PURE__ */ e.jsxs(X, { children: [ + /* @__PURE__ */ e.jsx(oe, { children: r.loaded ? r.fullTagName : "These tags do not exist on the server, please remove them" }), + r.loaded && /* @__PURE__ */ e.jsxs(P, { children: [ "UUID: ", r.tagId ] }), - !r.loaded && /* @__PURE__ */ o.jsx(O, { children: r.fullTagName }) + !r.loaded && /* @__PURE__ */ e.jsx(P, { children: r.fullTagName }) ] }), - /* @__PURE__ */ o.jsx(_, { children: /* @__PURE__ */ o.jsx( - X, + /* @__PURE__ */ e.jsx(Z, { children: /* @__PURE__ */ e.jsx( + re, { - onClick: (i) => { - i.stopPropagation(), a(r.categoryId, r.tagId, !1); + onClick: (s) => { + s.stopPropagation(), n(r.categoryId, r.tagId, !1); }, - children: /* @__PURE__ */ o.jsx(F, {}) + children: /* @__PURE__ */ e.jsx(V, {}) } ) }) - ] }, `${r.tagId}${s}`)) }); + ] }, `${r.tagId}${c}`)) }); } -function To(e, t, n) { - const a = [], r = /* @__PURE__ */ new Set(); - for (const l of t) - for (const c of l.tags) - r.add(c.tagId), n.has(c.tagId) && a.push({ - categoryId: l.categoryId, - tagId: c.tagId, - fullTagName: l.categoryName + ": " + c.tagName, +function Eo(o, t, a) { + const n = [], r = /* @__PURE__ */ new Set(); + for (const i of t) + for (const l of i.tags) + r.add(l.tagId), a.has(l.tagId) && n.push({ + categoryId: i.categoryId, + tagId: l.tagId, + fullTagName: i.categoryName + ": " + l.tagName, loaded: !0 }); - const s = [], i = /* @__PURE__ */ new Map(); - e.forEach((l) => i.set(l.tagId, l)); - for (const l of n) - if (!r.has(l)) { - const c = i.get(l); - c && s.push(c.categoryName + ": " + c.tagName); + const c = [], s = /* @__PURE__ */ new Map(); + o.forEach((i) => s.set(i.tagId, i)); + for (const i of a) + if (!r.has(i)) { + const l = s.get(i); + l && c.push(l.categoryName + ": " + l.tagName); } - return s.length > 0 && a.push({ + return c.length > 0 && n.push({ categoryId: "", tagId: "", - fullTagName: s.join(", "), + fullTagName: c.join(", "), loaded: !1 - }), a; + }), n; } -function So(e, t, n) { - const a = {}, r = []; - for (const s of t) - for (const i of s.tags) - n.has(i.tagId) && r.push({ - tagId: i.tagId, - tagName: i.tagName, - categoryName: s.categoryName +function Do(o, t, a) { + const n = {}, r = []; + for (const c of t) + for (const s of c.tags) + a.has(s.tagId) && r.push({ + tagId: s.tagId, + tagName: s.tagName, + categoryName: c.categoryName }); - return a[e] = r.length > 0 ? r : null, a; + return n[o] = r.length > 0 ? r : null, n; } -function $o(e, t) { +function No(o, t) { { - const n = [], a = {}; - for (const r of e) { - const s = { + const a = [], n = {}; + for (const r of o) { + const c = { categoryId: r.id, categoryName: r.name, categoryDescription: r.description, @@ -858,32 +940,32 @@ function $o(e, t) { multipleChoicesAllowed: !r.isExclusive, tags: [] }; - n.push(s), a[s.categoryId] = s; + a.push(c), n[c.categoryId] = c; } for (const r of t) { - const s = a[r.categoryId]; - if (s) { - const i = { + const c = n[r.categoryId]; + if (c) { + const s = { tagId: r.tagId, tagName: r.tagName, tagDescription: r.tagDescription, - onlyAdminCanTag: s.onlyAdminCanTag + onlyAdminCanTag: c.onlyAdminCanTag }; - s.tags.push(i); + c.tags.push(s); } } - return n.filter((r) => r.tags.length > 0); + return a.filter((r) => r.tags.length > 0); } } d.div` font-weight: 700; margin-bottom: 16px; `; -const ko = d.div` +const Oo = d.div` display: flex; flex-direction: column; gap: 7px; -`, Ao = d.div` +`, Po = d.div` display: flex; flex-direction: row; gap: 20px; @@ -895,13 +977,13 @@ const ko = d.div` align-items: center; justify-content: space-between; padding: 16px; -`, Lo = d.div` +`, Ro = d.div` display: flex; flex-direction: column; gap: 7px; -`, ee = d.span` +`, ne = d.span` font-weight: bold; -`, Ho = d.div` +`, Bo = d.div` display: flex; align-items: stretch; background-color: var(${g.computedOne}); @@ -910,59 +992,59 @@ const ko = d.div` justify-content: space-evenly; gap: 5px; `; -function Oo() { - const { targetFileName: e, tagData: t } = E((a) => a.tags), { platformApiToken: n } = E((a) => a.config.data); - return n && e && t ? /* @__PURE__ */ o.jsx(Do, { targetFileName: e, tagData: t }) : /* @__PURE__ */ o.jsx(o.Fragment, {}); +function Fo() { + const { targetFileName: o, tagData: t } = B((n) => n.tags), { platformApiToken: a } = B((n) => n.config.data); + return a && o && t ? /* @__PURE__ */ e.jsx(Mo, { targetFileName: o, tagData: t }) : /* @__PURE__ */ e.jsx(e.Fragment, {}); } -function Do({ - targetFileName: e, +function Mo({ + targetFileName: o, tagData: t }) { - const n = t[e], [a, r] = j.useState( - n === null || Array.isArray(n) ? "option-select-tag" : "option-bind-api" + const a = t[o], [n, r] = C.useState( + a === null || Array.isArray(a) ? "option-select-tag" : "option-bind-api" ); - return D.useEffect(() => { + return $.useEffect(() => { r( - n === null || Array.isArray(n) ? "option-select-tag" : "option-bind-api" + a === null || Array.isArray(a) ? "option-select-tag" : "option-bind-api" ); - }, [e]), /* @__PURE__ */ o.jsxs(Eo, { children: [ - /* @__PURE__ */ o.jsxs(No, { children: [ + }, [o]), /* @__PURE__ */ e.jsxs(Go, { children: [ + /* @__PURE__ */ e.jsxs(Vo, { children: [ "Specify tags, or link the platform API to ", - e + o ] }), - /* @__PURE__ */ o.jsx( - $e, + /* @__PURE__ */ e.jsx( + De, { - value: a, + value: n, options: [ { value: "option-select-tag", label: "Tags" }, { value: "option-bind-api", label: "Link to API" } ], - onValueChange: (s) => { - r(s); + onValueChange: (c) => { + r(c); } } ), - a === "option-select-tag" && /* @__PURE__ */ o.jsx(wo, { targetFileName: e, tagData: t }), - a === "option-bind-api" && /* @__PURE__ */ o.jsx(ro, { targetFileName: e, tagData: t }) + n === "option-select-tag" && /* @__PURE__ */ e.jsx(Ao, { targetFileName: o, tagData: t }), + n === "option-bind-api" && /* @__PURE__ */ e.jsx(lo, { targetFileName: o, tagData: t }) ] }); } -const No = d.div` +const Vo = d.div` font-weight: 700; margin-bottom: 16px; -`, Eo = d.div` +`, Go = d.div` display: flex; flex-direction: column; gap: 10px; padding: 16px; `; -function Po(e, t) { - const n = Qe(Ue(e), t); - ge.createRoot(document.getElementById("root")).render( - /* @__PURE__ */ o.jsx(j.StrictMode, { children: /* @__PURE__ */ o.jsxs(pe, { store: n, children: [ - /* @__PURE__ */ o.jsx(ue, {}), - /* @__PURE__ */ o.jsx(Oo, {}) +function zo(o, t) { + const a = Je(Ke(o), t); + he.createRoot(document.getElementById("root")).render( + /* @__PURE__ */ e.jsx(C.StrictMode, { children: /* @__PURE__ */ e.jsxs(xe, { store: a, children: [ + /* @__PURE__ */ e.jsx(me, {}), + /* @__PURE__ */ e.jsx(Fo, {}) ] }) }) - ), window.addEventListener("message", fe(n, ze)); + ), window.addEventListener("message", ve(a, Ye)); } -window.renderWebView = Po; +window.renderWebView = zo; diff --git a/openapi-plugin/resources/web/tryit.js b/openapi-plugin/resources/web/tryit.js index 515d4aec..4392a9c4 100644 --- a/openapi-plugin/resources/web/tryit.js +++ b/openapi-plugin/resources/web/tryit.js @@ -1,6 +1,6 @@ import { j as n, c as xe, a as ye, r as be, t as je, l as $e, b as Se, u as K, d as we, s as Ce, i as ke, e as u, T as c, f as h, S as V, g as Oe, R as Fe, P as Ee, h as Te, k as Re, p as Pe, n as Be, o as qe } from "./TriangleExclamation.BLKAXJ8l.js"; -import { i as I, c as Ne, a as Ve, e as O, d as T, s as A, p as M, b as L, g as Ie, f as De, h as He, j as Ae, k as Y, l as Me, m as Le, n as Z, o as Je, E as We, w as ze, q as ee, u as Ge } from "./variables.-zE0Ry6h.js"; -import { e as _e, s as re, u as Ue, l as Qe } from "./index.CRy0HWMP.js"; +import { i as I, c as Ne, a as Ve, e as O, d as T, s as A, p as M, b as L, g as Ie, f as De, h as He, j as Ae, k as Y, l as Me, m as Le, n as Z, E as Je, w as We, o as ee, u as ze } from "./variables.CfsUBZ9t.js"; +import { e as Ge, s as re, u as _e, l as Ue, a as Qe } from "./index.BXf_Hj-1.js"; import { p as Xe, s as te, a as ne, S as Ke, l as Ye } from "./slice.CZpj5Zis.js"; import { c as Ze, a as er, r as rr, l as tr } from "./slice.s4_w0CJL.js"; import { s as nr } from "./listener.BM8yBkLB.js"; @@ -77,7 +77,7 @@ const vr = (e) => /* @__PURE__ */ n.jsx("svg", { xmlns: "http://www.w3.org/2000/ theme: je, tryit: jr, router: be, - env: _e, + env: Ge, prefs: Xe, config: Ze }, Sr = (e, r) => ye({ @@ -590,7 +590,7 @@ function Yr(e) { return e.message; } function q({ name: e, placeholder: r }) { - const t = b((v) => v.env.data.secrets), o = Ue(), { control: s } = x(), { field: i } = S({ + const t = b((v) => v.env.data.secrets), o = _e(), { control: s } = x(), { field: i } = S({ name: e, control: s }); @@ -1093,11 +1093,11 @@ function ge(e, r) { return typeof e == "string" ? N(e, r) : e; } function me(e, r) { - return typeof e == "string" ? N(e, r) : typeof e == "object" ? Je.simpleClone(e, (t) => typeof t == "string" ? N(t, r) : t) : e; + return typeof e == "string" ? N(e, r) : typeof e == "object" ? Ue.simpleClone(e, (t) => typeof t == "string" ? N(t, r) : t) : e; } function N(e, r) { const t = "secrets."; - return e.replace(We(), (o, s) => { + return e.replace(Je(), (o, s) => { if (s.startsWith(t)) { const i = s.substring(t.length, s.length); return r.secrets.hasOwnProperty(i) ? r.secrets[i] : o; @@ -1268,7 +1268,7 @@ function Yt() { ...o, server: i, security: en(o.security, s.security) - }, d = ze(a); + }, d = We(a); return /* @__PURE__ */ n.jsx(Zt, { oas: t, method: r, path: e, values: d }); } function Zt({ @@ -1282,7 +1282,7 @@ function Zt({ g(a !== void 0); }, [a]); const f = async (C) => { - const F = Ge(C); + const F = ze(C); try { const [P, ve] = await wt( l, diff --git a/openapi-plugin/resources/web/variables.-zE0Ry6h.js b/openapi-plugin/resources/web/variables.-zE0Ry6h.js deleted file mode 100644 index 743752c3..00000000 --- a/openapi-plugin/resources/web/variables.-zE0Ry6h.js +++ /dev/null @@ -1,12158 +0,0 @@ -import { q as je } from "./TriangleExclamation.BLKAXJ8l.js"; -import { c as si, H as ai, r as ui, d as gn } from "./index.CRy0HWMP.js"; -function Ne(r, s) { - if (s != null) - return typeof s == "object" && "$ref" in s ? si.find(r, s.$ref) : s; -} -function Ct(r, s, n) { - return Ne(r, r.paths?.[s])?.[n]; -} -function li(r, s) { - return (s.parameters ?? []).map((o) => Ne(r, o)); -} -function fi(r, s) { - return (s?.parameters ?? []).map((o) => Ne(r, o)); -} -function yn(r) { - const s = (r.servers ?? []).filter((n) => n.url !== void 0 && n.url !== "").map((n) => n.url); - return s.length > 0 ? s : ["http://localhost/"]; -} -function ci(r, s, n) { - const o = { - query: {}, - header: {}, - path: {}, - cookie: {} - }; - for (const p of s) { - const i = Ne(r, p.schema); - o[p.in][p.name] = { ...p, schema: i }; - } - for (const p of n) { - const i = Ne(r, p.schema); - o[p.in][p.name] = { ...p, schema: i }; - } - return o; -} -function pi(r, s, n) { - const p = Ct(r, s, n)?.security ?? r.security ?? [], i = []; - for (const u of p) { - const a = {}; - for (const c of Object.keys(u)) - if (r?.components?.securitySchemes?.[c]) { - const l = Ne(r, r.components.securitySchemes[c]); - l && (a[c] = l); - } - i.push(a); - } - return i; -} -function Tt(r, s, n) { - if (n !== "trace") - return Ne(r, r.paths[s])?.[n]; -} -function hi(r, s) { - return (s.parameters ?? []).map((o) => Ne(r, o)); -} -function di(r, s) { - return (s?.parameters ?? []).map((o) => Ne(r, o)); -} -function mi(r, s, n) { - const o = { - query: {}, - header: {}, - path: {}, - formData: {}, - body: {} - }; - for (const p of s) { - const i = Ne(r, p.schema); - o[p.in][p.name] = { ...p, schema: i }; - } - for (const p of n) { - const i = Ne(r, p.schema); - o[p.in][p.name] = { ...p, schema: i }; - } - return o; -} -function vn(r) { - const s = r.schemes ?? ["http"], n = r.basePath ?? "", o = r.host ?? "localhost"; - return s.map((p) => `${p}://${o}${n}`); -} -function gi(r, s) { - return s?.consumes && s.consumes.length > 0 ? s.consumes : r?.consumes && r.consumes.length > 0 ? r.consumes : []; -} -function gr(r) { - return "openapi" in r; -} -function yi(r, s, n) { - return n === "trace" ? gr(r) ? Ne(r, r.paths?.[s])?.[n] : void 0 : Ne(r, r.paths?.[s])?.[n]; -} -function vi(r) { - const s = []; - for (const n of Object.keys(r.paths ?? {})) - for (const o of Object.keys(r.paths?.[n] ?? {})) - if (ai.includes(o)) { - const p = yi(r, n, o); - s.push([n, o, p]); - } - return s; -} -function bi(r, s, n) { - return r === void 0 || r === "" ? `${s}:${n}` : r; -} -function va(r, s) { - const n = vi(r); - for (const [o, p, i] of n) - if (bi(i.operationId, o, p) === s) - return { path: o, method: p, operation: i }; -} -function ba(r) { - return gr(r) ? yn(r) : vn(r); -} -function wa(r) { - if (r >= 100 && r <= 199) - return "1XX"; - if (r >= 200 && r <= 299) - return "2XX"; - if (r >= 300 && r <= 399) - return "3XX"; - if (r >= 400 && r <= 499) - return "4XX"; - if (r >= 500 && r <= 599) - return "5XX"; -} -function vt(r) { - throw new Error('Could not dynamically require "' + r + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.'); -} -var bt = { exports: {} }, wr; -function wi() { - return wr || (wr = 1, (function(r, s) { - (() => { - (function(n) { - r.exports = n(); - })(function() { - return (/* @__PURE__ */ (function() { - function n(o, p, i) { - function u(l, f) { - if (!p[l]) { - if (!o[l]) { - var d = typeof vt == "function" && vt; - if (!f && d) return d(l, !0); - if (a) return a(l, !0); - var E = new Error("Cannot find module '" + l + "'"); - throw E.code = "MODULE_NOT_FOUND", E; - } - var y = p[l] = { exports: {} }; - o[l][0].call(y.exports, function(S) { - var T = o[l][1][S]; - return u(T || S); - }, y, y.exports, n, o, p, i); - } - return p[l].exports; - } - for (var a = typeof vt == "function" && vt, c = 0; c < i.length; c++) u(i[c]); - return u; - } - return n; - })())({ 1: [function(n, o, p) { - var i = n("./ref"), u = n("./pointer"), a = n("./util/url"); - function c(S, T) { - var v = []; - l(S, "schema", S.$refs._root$Ref.path + "#", "#", 0, v, S.$refs, T), d(v); - } - function l(S, T, v, h, b, w, _, O) { - var P = T === null ? S : S[T]; - P && typeof P == "object" && (i.isAllowed$Ref(P) ? f(S, T, v, h, b, w, _, O) : Object.keys(P).sort(function(L, Y) { - return L === "definitions" ? -1 : Y === "definitions" ? 1 : L.length - Y.length; - }).forEach(function(L) { - var Y = u.join(v, L), H = u.join(h, L), V = P[L]; - i.isAllowed$Ref(V) ? f(P, L, v, H, b, w, _, O) : l(P, L, Y, H, b, w, _, O); - })); - } - function f(S, T, v, h, b, w, _, O) { - var P = T === null ? S : S[T], L = a.resolve(v, P.$ref), Y = _._resolve(L, O), H = u.parse(h).length, V = a.stripHash(Y.path), B = a.getHash(Y.path), ne = V !== _._root$Ref.path, I = i.isExtended$Ref(P); - b += Y.indirections; - var Z = E(w, S, T); - if (Z) { - if (!(H < Z.depth || b < Z.indirections)) return; - y(w, Z); - } - w.push({ $ref: P, parent: S, key: T, pathFromRoot: h, depth: H, file: V, hash: B, value: Y.value, circular: Y.circular, extended: I, external: ne, indirections: b }), l(Y.value, null, Y.path, h, b + 1, w, _, O); - } - function d(S) { - var T, v, h; - S.sort(function(b, w) { - if (b.file !== w.file) return b.file < w.file ? -1 : 1; - if (b.hash !== w.hash) return b.hash < w.hash ? -1 : 1; - if (b.circular !== w.circular) return b.circular ? -1 : 1; - if (b.extended !== w.extended) return b.extended ? 1 : -1; - if (b.indirections !== w.indirections) return b.indirections - w.indirections; - if (b.depth !== w.depth) return b.depth - w.depth; - var _ = b.pathFromRoot.lastIndexOf("/definitions"), O = w.pathFromRoot.lastIndexOf("/definitions"); - return _ !== O ? O - _ : b.pathFromRoot.length - w.pathFromRoot.length; - }), S.forEach(function(b) { - b.external ? b.file === T && b.hash === v ? b.$ref.$ref = h : b.file === T && b.hash.indexOf(v + "/") === 0 ? b.$ref.$ref = u.join(h, u.parse(b.hash.replace(v, "#"))) : (T = b.file, v = b.hash, h = b.pathFromRoot, b.$ref = b.parent[b.key] = i.dereference(b.$ref, b.value), b.circular && (b.$ref.$ref = b.pathFromRoot)) : b.$ref.$ref = b.hash; - }); - } - function E(S, T, v) { - for (var h = 0; h < S.length; h++) { - var b = S[h]; - if (b.parent === T && b.key === v) return b; - } - } - function y(S, T) { - var v = S.indexOf(T); - S.splice(v, 1); - } - o.exports = c; - }, { "./pointer": 11, "./ref": 12, "./util/url": 18 }], 2: [function(n, o, p) { - var i = n("./ref"), u = n("./pointer"), a = n("ono"), c = n("./util/url"); - function l(y, S) { - var T = f(y.schema, y.$refs._root$Ref.path, "#", [], y.$refs, S); - y.$refs.circular = T.circular, y.schema = T.value; - } - function f(y, S, T, v, h, b) { - var w, _ = { value: y, circular: !1 }; - return y && typeof y == "object" && (v.push(y), i.isAllowed$Ref(y, b) ? (w = d(y, S, T, v, h, b), _.circular = w.circular, _.value = w.value) : Object.keys(y).forEach(function(O) { - var P = u.join(S, O), L = u.join(T, O), Y = y[O], H = !1; - i.isAllowed$Ref(Y, b) ? (H = (w = d(Y, P, L, v, h, b)).circular, y[O] = w.value) : v.indexOf(Y) === -1 ? (H = (w = f(Y, P, L, v, h, b)).circular, y[O] = w.value) : H = E(P, h, b), _.circular = _.circular || H; - }), v.pop()), _; - } - function d(y, S, T, v, h, b) { - var w = c.resolve(S, y.$ref), _ = h._resolve(w, b), O = _.circular, P = O || v.indexOf(_.value) !== -1; - P && E(S, h, b); - var L = i.dereference(y, _.value); - if (!P) { - var Y = f(L, _.path, T, v, h, b); - P = Y.circular, L = Y.value; - } - return P && !O && b.dereference.circular === "ignore" && (L = y), O && (L.$ref = T), { circular: P, value: L }; - } - function E(y, S, T) { - if (S.circular = !0, !T.dereference.circular) throw a.reference("Circular $ref pointer found at %s", y); - return !0; - } - o.exports = l; - }, { "./pointer": 11, "./ref": 12, "./util/url": 18, ono: 64 }], 3: [function(n, o, p) { - (function(i) { - n("./options"); - var u = n("./refs"), a = n("./parse"), c = n("./normalize-args"), l = n("./resolve-external"), f = n("./bundle"), d = n("./dereference"), E = n("./util/url"), y = n("call-me-maybe"), S = n("ono"); - function T() { - this.schema = null, this.$refs = new u(); - } - o.exports = T, o.exports.YAML = n("./util/yaml"), T.parse = function(v, h, b, w) { - var _ = new this(); - return _.parse.apply(_, arguments); - }, T.prototype.parse = function(v, h, b, w) { - var _, O = c(arguments); - if (!O.path && !O.schema) { - var P = S("Expected a file path, URL, or object. Got %s", O.path || O.schema); - return y(O.callback, Promise.reject(P)); - } - this.schema = null, this.$refs = new u(); - var L = "http"; - if (E.isFileSystemPath(O.path) && (O.path = E.fromFileSystemPath(O.path), L = "file"), O.path = E.resolve(E.cwd(), O.path), O.schema && typeof O.schema == "object") { - var Y = this.$refs._add(O.path); - Y.value = O.schema, Y.pathType = L, _ = Promise.resolve(O.schema); - } else _ = a(O.path, this.$refs, O.options); - var H = this; - return _.then(function(V) { - if (!V || typeof V != "object" || i.isBuffer(V)) throw S.syntax('"%s" is not a valid JSON Schema', H.$refs._root$Ref.path || V); - return H.schema = V, y(O.callback, Promise.resolve(H.schema)); - }).catch(function(V) { - return y(O.callback, Promise.reject(V)); - }); - }, T.resolve = function(v, h, b, w) { - var _ = new this(); - return _.resolve.apply(_, arguments); - }, T.prototype.resolve = function(v, h, b, w) { - var _ = this, O = c(arguments); - return this.parse(O.path, O.schema, O.options).then(function() { - return l(_, O.options); - }).then(function() { - return y(O.callback, Promise.resolve(_.$refs)); - }).catch(function(P) { - return y(O.callback, Promise.reject(P)); - }); - }, T.bundle = function(v, h, b, w) { - var _ = new this(); - return _.bundle.apply(_, arguments); - }, T.prototype.bundle = function(v, h, b, w) { - var _ = this, O = c(arguments); - return this.resolve(O.path, O.schema, O.options).then(function() { - return f(_, O.options), y(O.callback, Promise.resolve(_.schema)); - }).catch(function(P) { - return y(O.callback, Promise.reject(P)); - }); - }, T.dereference = function(v, h, b, w) { - var _ = new this(); - return _.dereference.apply(_, arguments); - }, T.prototype.dereference = function(v, h, b, w) { - var _ = this, O = c(arguments); - return this.resolve(O.path, O.schema, O.options).then(function() { - return d(_, O.options), y(O.callback, Promise.resolve(_.schema)); - }).catch(function(P) { - return y(O.callback, Promise.reject(P)); - }); - }; - }).call(this, { isBuffer: n("../node_modules/is-buffer/index.js") }); - }, { "../node_modules/is-buffer/index.js": 32, "./bundle": 1, "./dereference": 2, "./normalize-args": 4, "./options": 5, "./parse": 6, "./refs": 13, "./resolve-external": 14, "./util/url": 18, "./util/yaml": 19, "call-me-maybe": 25, ono: 64 }], 4: [function(n, o, p) { - var i = n("./options"); - function u(a) { - var c, l, f, d; - return typeof (a = Array.prototype.slice.call(a))[a.length - 1] == "function" && (d = a.pop()), typeof a[0] == "string" ? (c = a[0], typeof a[2] == "object" ? (l = a[1], f = a[2]) : (l = void 0, f = a[1])) : (c = "", l = a[0], f = a[1]), f instanceof i || (f = new i(f)), { path: c, schema: l, options: f, callback: d }; - } - o.exports = u; - }, { "./options": 5 }], 5: [function(n, o, p) { - var i = n("./parsers/json"), u = n("./parsers/yaml"), a = n("./parsers/text"), c = n("./parsers/binary"), l = n("./resolvers/file"), f = n("./resolvers/http"); - function d(S) { - E(this, d.defaults), E(this, S); - } - function E(S, T) { - if (y(T)) for (var v = Object.keys(T), h = 0; h < v.length; h++) { - var b = v[h], w = T[b], _ = S[b]; - y(w) ? S[b] = E(_ || {}, w) : w !== void 0 && (S[b] = w); - } - return S; - } - function y(S) { - return S && typeof S == "object" && !Array.isArray(S) && !(S instanceof RegExp) && !(S instanceof Date); - } - o.exports = d, d.defaults = { parse: { json: i, yaml: u, text: a, binary: c }, resolve: { file: l, http: f, external: !0 }, dereference: { circular: !0 } }; - }, { "./parsers/binary": 7, "./parsers/json": 8, "./parsers/text": 9, "./parsers/yaml": 10, "./resolvers/file": 15, "./resolvers/http": 16 }], 6: [function(n, o, p) { - (function(i) { - var u = n("ono"), a = n("./util/url"), c = n("./util/plugins"); - function l(y, S, T) { - try { - y = a.stripHash(y); - var v = S._add(y), h = { url: y, extension: a.getExtension(y) }; - return f(h, T).then(function(b) { - return v.pathType = b.plugin.name, h.data = b.result, d(h, T); - }).then(function(b) { - return v.value = b.result, b.result; - }); - } catch (b) { - return Promise.reject(b); - } - } - function f(y, S) { - return new Promise(function(T, v) { - var h = c.all(S.resolve); - h = c.filter(h, "canRead", y), c.sort(h), c.run(h, "read", y).then(T, function(b) { - !b || b instanceof SyntaxError ? v(u.syntax('Unable to resolve $ref pointer "%s"', y.url)) : v(b); - }); - }); - } - function d(y, S) { - return new Promise(function(T, v) { - var h = c.all(S.parse), b = c.filter(h, "canParse", y), w = b.length > 0 ? b : h; - c.sort(w), c.run(w, "parse", y).then(function(_) { - !_.plugin.allowEmpty && E(_.result) ? v(u.syntax(`Error parsing "%s" as %s. -Parsed value is empty`, y.url, _.plugin.name)) : T(_); - }, function(_) { - _ ? (_ = _ instanceof Error ? _ : new Error(_), v(u.syntax(_, "Error parsing %s", y.url))) : v(u.syntax("Unable to parse %s", y.url)); - }); - }); - } - function E(y) { - return y === void 0 || typeof y == "object" && Object.keys(y).length === 0 || typeof y == "string" && y.trim().length === 0 || i.isBuffer(y) && y.length === 0; - } - o.exports = l; - }).call(this, { isBuffer: n("../node_modules/is-buffer/index.js") }); - }, { "../node_modules/is-buffer/index.js": 32, "./util/plugins": 17, "./util/url": 18, ono: 64 }], 7: [function(n, o, p) { - (function(i) { - var u = /\.(jpeg|jpg|gif|png|bmp|ico)$/i; - o.exports = { order: 400, allowEmpty: !0, canParse: function(a) { - return i.isBuffer(a.data) && u.test(a.url); - }, parse: function(a) { - return i.isBuffer(a.data) ? a.data : new i(a.data); - } }; - }).call(this, n("buffer").Buffer); - }, { buffer: 23 }], 8: [function(n, o, p) { - (function(i) { - o.exports = { order: 100, allowEmpty: !0, canParse: ".json", parse: function(u) { - return new Promise(function(a, c) { - var l = u.data; - i.isBuffer(l) && (l = l.toString()), typeof l == "string" ? l.trim().length === 0 ? a(void 0) : a(JSON.parse(l)) : a(l); - }); - } }; - }).call(this, { isBuffer: n("../../node_modules/is-buffer/index.js") }); - }, { "../../node_modules/is-buffer/index.js": 32 }], 9: [function(n, o, p) { - (function(i) { - var u = /\.(txt|htm|html|md|xml|js|min|map|css|scss|less|svg)$/i; - o.exports = { order: 300, allowEmpty: !0, encoding: "utf8", canParse: function(a) { - return (typeof a.data == "string" || i.isBuffer(a.data)) && u.test(a.url); - }, parse: function(a) { - if (typeof a.data == "string") return a.data; - if (i.isBuffer(a.data)) return a.data.toString(this.encoding); - throw new Error("data is not text"); - } }; - }).call(this, { isBuffer: n("../../node_modules/is-buffer/index.js") }); - }, { "../../node_modules/is-buffer/index.js": 32 }], 10: [function(n, o, p) { - (function(i) { - var u = n("../util/yaml"); - o.exports = { order: 200, allowEmpty: !0, canParse: [".yaml", ".yml", ".json"], parse: function(a) { - return new Promise(function(c, l) { - var f = a.data; - i.isBuffer(f) && (f = f.toString()), c(typeof f == "string" ? u.parse(f) : f); - }); - } }; - }).call(this, { isBuffer: n("../../node_modules/is-buffer/index.js") }); - }, { "../../node_modules/is-buffer/index.js": 32, "../util/yaml": 19 }], 11: [function(n, o, p) { - o.exports = E; - var i = n("./ref"), u = n("./util/url"), a = n("ono"), c = /\//g, l = /~/g, f = /~1/g, d = /~0/g; - function E(T, v, h) { - this.$ref = T, this.path = v, this.originalPath = h || v, this.value = void 0, this.circular = !1, this.indirections = 0; - } - function y(T, v) { - if (i.isAllowed$Ref(T.value, v)) { - var h = u.resolve(T.path, T.value.$ref); - if (h !== T.path) { - var b = T.$ref.$refs._resolve(h, v); - return T.indirections += b.indirections + 1, i.isExtended$Ref(T.value) ? (T.value = i.dereference(T.value, b.value), !1) : (T.$ref = b.$ref, T.path = b.path, T.value = b.value, !0); - } - T.circular = !0; - } - } - function S(T, v, h) { - if (!T.value || typeof T.value != "object") throw a.syntax(`Error assigning $ref pointer "%s". -Cannot set "%s" of a non-object.`, T.path, v); - return v === "-" && Array.isArray(T.value) ? T.value.push(h) : T.value[v] = h, h; - } - E.prototype.resolve = function(T, v) { - var h = E.parse(this.path); - this.value = T; - for (var b = 0; b < h.length; b++) { - y(this, v) && (this.path = E.join(this.path, h.slice(b))); - var w = h[b]; - if (this.value[w] === void 0) throw a.syntax(`Error resolving $ref pointer "%s". -Token "%s" does not exist.`, this.originalPath, w); - this.value = this.value[w]; - } - return y(this, v), this; - }, E.prototype.set = function(T, v, h) { - var b, w = E.parse(this.path); - if (w.length === 0) return this.value = v, v; - this.value = T; - for (var _ = 0; _ < w.length - 1; _++) y(this, h), b = w[_], this.value && this.value[b] !== void 0 ? this.value = this.value[b] : this.value = S(this, b, {}); - return y(this, h), S(this, b = w[w.length - 1], v), T; - }, E.parse = function(T) { - var v = u.getHash(T).substr(1); - if (!v) return []; - v = v.split("/"); - for (var h = 0; h < v.length; h++) v[h] = decodeURIComponent(v[h].replace(f, "/").replace(d, "~")); - if (v[0] !== "") throw a.syntax('Invalid $ref pointer "%s". Pointers must begin with "#/"', v); - return v.slice(1); - }, E.join = function(T, v) { - T.indexOf("#") === -1 && (T += "#"), v = Array.isArray(v) ? v : [v]; - for (var h = 0; h < v.length; h++) { - var b = v[h]; - T += "/" + encodeURIComponent(b.replace(l, "~0").replace(c, "~1")); - } - return T; - }; - }, { "./ref": 12, "./util/url": 18, ono: 64 }], 12: [function(n, o, p) { - o.exports = u; - var i = n("./pointer"); - function u() { - this.path = void 0, this.value = void 0, this.$refs = void 0, this.pathType = void 0; - } - u.prototype.exists = function(a, c) { - try { - return this.resolve(a, c), !0; - } catch { - return !1; - } - }, u.prototype.get = function(a, c) { - return this.resolve(a, c).value; - }, u.prototype.resolve = function(a, c, l) { - return new i(this, a, l).resolve(this.value, c); - }, u.prototype.set = function(a, c) { - var l = new i(this, a); - this.value = l.set(this.value, c); - }, u.is$Ref = function(a) { - return a && typeof a == "object" && typeof a.$ref == "string" && a.$ref.length > 0; - }, u.isExternal$Ref = function(a) { - return u.is$Ref(a) && a.$ref[0] !== "#"; - }, u.isAllowed$Ref = function(a, c) { - if (u.is$Ref(a) && (a.$ref.substr(0, 2) === "#/" || a.$ref === "#" || a.$ref[0] !== "#" && (!c || c.resolve.external))) - return !0; - }, u.isExtended$Ref = function(a) { - return u.is$Ref(a) && Object.keys(a).length > 1; - }, u.dereference = function(a, c) { - if (c && typeof c == "object" && u.isExtended$Ref(a)) { - var l = {}; - return Object.keys(a).forEach(function(f) { - f !== "$ref" && (l[f] = a[f]); - }), Object.keys(c).forEach(function(f) { - f in l || (l[f] = c[f]); - }), l; - } - return c; - }; - }, { "./pointer": 11 }], 13: [function(n, o, p) { - var i = n("ono"), u = n("./ref"), a = n("./util/url"); - function c() { - this.circular = !1, this._$refs = {}, this._root$Ref = null; - } - function l(f, d) { - var E = Object.keys(f); - return (d = Array.isArray(d[0]) ? d[0] : Array.prototype.slice.call(d)).length > 0 && d[0] && (E = E.filter(function(y) { - return d.indexOf(f[y].pathType) !== -1; - })), E.map(function(y) { - return { encoded: y, decoded: f[y].pathType === "file" ? a.toFileSystemPath(y, !0) : y }; - }); - } - o.exports = c, c.prototype.paths = function(f) { - return l(this._$refs, arguments).map(function(d) { - return d.decoded; - }); - }, c.prototype.values = function(f) { - var d = this._$refs; - return l(d, arguments).reduce(function(E, y) { - return E[y.decoded] = d[y.encoded].value, E; - }, {}); - }, c.prototype.toJSON = c.prototype.values, c.prototype.exists = function(f, d) { - try { - return this._resolve(f, d), !0; - } catch { - return !1; - } - }, c.prototype.get = function(f, d) { - return this._resolve(f, d).value; - }, c.prototype.set = function(f, d) { - var E = a.resolve(this._root$Ref.path, f), y = a.stripHash(E), S = this._$refs[y]; - if (!S) throw i(`Error resolving $ref pointer "%s". -"%s" not found.`, f, y); - S.set(E, d); - }, c.prototype._add = function(f) { - var d = a.stripHash(f), E = new u(); - return E.path = d, E.$refs = this, this._$refs[d] = E, this._root$Ref = this._root$Ref || E, E; - }, c.prototype._resolve = function(f, d) { - var E = a.resolve(this._root$Ref.path, f), y = a.stripHash(E), S = this._$refs[y]; - if (!S) throw i(`Error resolving $ref pointer "%s". -"%s" not found.`, f, y); - return S.resolve(E, d, f); - }, c.prototype._get$Ref = function(f) { - f = a.resolve(this._root$Ref.path, f); - var d = a.stripHash(f); - return this._$refs[d]; - }; - }, { "./ref": 12, "./util/url": 18, ono: 64 }], 14: [function(n, o, p) { - var i = n("./ref"), u = n("./pointer"), a = n("./parse"), c = n("./util/url"); - function l(E, y) { - if (!y.resolve.external) return Promise.resolve(); - try { - var S = f(E.schema, E.$refs._root$Ref.path + "#", E.$refs, y); - return Promise.all(S); - } catch (T) { - return Promise.reject(T); - } - } - function f(E, y, S, T) { - var v = []; - return E && typeof E == "object" && (i.isExternal$Ref(E) ? v.push(d(E, y, S, T)) : Object.keys(E).forEach(function(h) { - var b = u.join(y, h), w = E[h]; - i.isExternal$Ref(w) ? v.push(d(w, b, S, T)) : v = v.concat(f(w, b, S, T)); - })), v; - } - function d(E, y, S, T) { - var v = c.resolve(y, E.$ref), h = c.stripHash(v); - return (E = S._$refs[h]) ? Promise.resolve(E.value) : a(v, S, T).then(function(b) { - var w = f(b, h + "#", S, T); - return Promise.all(w); - }); - } - o.exports = l; - }, { "./parse": 6, "./pointer": 11, "./ref": 12, "./util/url": 18 }], 15: [function(n, o, p) { - var i = n("fs"), u = n("ono"), a = n("../util/url"); - o.exports = { order: 100, canRead: function(c) { - return a.isFileSystemPath(c.url); - }, read: function(c) { - return new Promise(function(l, f) { - var d; - try { - d = a.toFileSystemPath(c.url); - } catch (E) { - f(u.uri(E, "Malformed URI: %s", c.url)); - } - try { - i.readFile(d, function(E, y) { - E ? f(u(E, 'Error opening file "%s"', d)) : l(y); - }); - } catch (E) { - f(u(E, 'Error opening file "%s"', d)); - } - }); - } }; - }, { "../util/url": 18, fs: 21, ono: 64 }], 16: [function(n, o, p) { - (function(i, u) { - var a = n("http"), c = n("https"), l = n("ono"), f = n("../util/url"); - function d(y, S, T) { - return new Promise(function(v, h) { - y = f.parse(y), (T = T || []).push(y.href), E(y, S).then(function(b) { - if (b.statusCode >= 400) throw l({ status: b.statusCode }, "HTTP ERROR %d", b.statusCode); - if (b.statusCode >= 300) if (T.length > S.redirects) h(l({ status: b.statusCode }, `Error downloading %s. -Too many redirects: - %s`, T[0], T.join(` - `))); - else { - if (!b.headers.location) throw l({ status: b.statusCode }, "HTTP %d redirect with no location header", b.statusCode); - d(f.resolve(y, b.headers.location), S, T).then(v, h); - } - else v(b.body || new u(0)); - }).catch(function(b) { - h(l(b, "Error downloading", y.href)); - }); - }); - } - function E(y, S) { - return new Promise(function(T, v) { - var h = (y.protocol === "https:" ? c : a).get({ hostname: y.hostname, port: y.port, path: y.path, auth: y.auth, protocol: y.protocol, headers: S.headers || {}, withCredentials: S.withCredentials }); - typeof h.setTimeout == "function" && h.setTimeout(S.timeout), h.on("timeout", function() { - h.abort(); - }), h.on("error", v), h.once("response", function(b) { - b.body = new u(0), b.on("data", function(w) { - b.body = u.concat([b.body, new u(w)]); - }), b.on("error", v), b.on("end", function() { - T(b); - }); - }); - }); - } - o.exports = { order: 200, headers: null, timeout: 5e3, redirects: 5, withCredentials: !1, canRead: function(y) { - return f.isHttp(y.url); - }, read: function(y) { - var S = f.parse(y.url); - return i.browser && !S.protocol && (S.protocol = f.parse(location.href).protocol), d(S, this); - } }; - }).call(this, n("_process"), n("buffer").Buffer); - }, { "../util/url": 18, _process: 66, buffer: 23, http: 80, https: 29, ono: 64 }], 17: [function(n, o, p) { - function i(u, a, c, l) { - var f = u[a]; - if (typeof f == "function") return f.apply(u, [c, l]); - if (!l) { - if (f instanceof RegExp) return f.test(c.url); - if (typeof f == "string") return f === c.extension; - if (Array.isArray(f)) return f.indexOf(c.extension) !== -1; - } - return f; - } - p.all = function(u) { - return Object.keys(u).filter(function(a) { - return typeof u[a] == "object"; - }).map(function(a) { - return u[a].name = a, u[a]; - }); - }, p.filter = function(u, a, c) { - return u.filter(function(l) { - return !!i(l, a, c); - }); - }, p.sort = function(u) { - return u.forEach(function(a) { - a.order = a.order || Number.MAX_SAFE_INTEGER; - }), u.sort(function(a, c) { - return a.order - c.order; - }); - }, p.run = function(u, a, c) { - var l, f, d = 0; - return new Promise(function(E, y) { - function S() { - if (!(l = u[d++])) return y(f); - try { - var b = i(l, a, c, T); - b && typeof b.then == "function" ? b.then(v, h) : b !== void 0 && v(b); - } catch (w) { - h(w); - } - } - function T(b, w) { - b ? h(b) : v(w); - } - function v(b) { - E({ plugin: l, result: b }); - } - function h(b) { - f = b, S(); - } - S(); - }); - }; - }, {}], 18: [function(n, o, p) { - (function(i) { - var u = /^win/.test(i.platform), a = /\//g, c = /^(\w{2,}):\/\//i, l = o.exports, f = [/\?/g, "%3F", /\#/g, "%23"], d = [/\%23/g, "#", /\%24/g, "$", /\%26/g, "&", /\%2C/g, ",", /\%40/g, "@"]; - p.parse = n("url").parse, p.resolve = n("url").resolve, p.cwd = function() { - return i.browser ? location.href : i.cwd() + "/"; - }, p.getProtocol = function(E) { - var y = c.exec(E); - if (y) return y[1].toLowerCase(); - }, p.getExtension = function(E) { - var y = E.lastIndexOf("."); - return y >= 0 ? E.substr(y).toLowerCase() : ""; - }, p.getHash = function(E) { - var y = E.indexOf("#"); - return y >= 0 ? E.substr(y) : "#"; - }, p.stripHash = function(E) { - var y = E.indexOf("#"); - return y >= 0 && (E = E.substr(0, y)), E; - }, p.isHttp = function(E) { - var y = l.getProtocol(E); - return y === "http" || y === "https" || y === void 0 && i.browser; - }, p.isFileSystemPath = function(E) { - if (i.browser) return !1; - var y = l.getProtocol(E); - return y === void 0 || y === "file"; - }, p.fromFileSystemPath = function(E) { - u && (E = E.replace(/\\/g, "/")), E = encodeURI(E); - for (var y = 0; y < f.length; y += 2) E = E.replace(f[y], f[y + 1]); - return E; - }, p.toFileSystemPath = function(E, y) { - E = decodeURI(E); - for (var S = 0; S < d.length; S += 2) E = E.replace(d[S], d[S + 1]); - var T = E.substr(0, 7).toLowerCase() === "file://"; - return T && (E = E[7] === "/" ? E.substr(8) : E.substr(7), u && E[1] === "/" && (E = E[0] + ":" + E.substr(1)), y ? E = "file:///" + E : (T = !1, E = u ? E : "/" + E)), u && !T && (E = E.replace(a, "\\")).substr(1, 2) === ":\\" && (E = E[0].toUpperCase() + E.substr(1)), E; - }; - }).call(this, n("_process")); - }, { _process: 66, url: 87 }], 19: [function(n, o, p) { - var i = n("js-yaml"), u = n("ono"); - o.exports = { parse: function(a, c) { - try { - return i.safeLoad(a); - } catch (l) { - throw l instanceof Error ? l : u(l, l.message); - } - }, stringify: function(a, c, l) { - try { - var f = (typeof l == "string" ? l.length : l) || 2; - return i.safeDump(a, { indent: f }); - } catch (d) { - throw d instanceof Error ? d : u(d, d.message); - } - } }; - }, { "js-yaml": 34, ono: 64 }], 20: [function(n, o, p) { - p.byteLength = E, p.toByteArray = S, p.fromByteArray = h; - for (var i = [], u = [], a = typeof Uint8Array < "u" ? Uint8Array : Array, c = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", l = 0, f = c.length; l < f; ++l) i[l] = c[l], u[c.charCodeAt(l)] = l; - function d(b) { - var w = b.length; - if (w % 4 > 0) throw new Error("Invalid string. Length must be a multiple of 4"); - var _ = b.indexOf("="); - return _ === -1 && (_ = w), [_, _ === w ? 0 : 4 - _ % 4]; - } - function E(b) { - var w = d(b), _ = w[0], O = w[1]; - return 3 * (_ + O) / 4 - O; - } - function y(b, w, _) { - return 3 * (w + _) / 4 - _; - } - function S(b) { - for (var w, _ = d(b), O = _[0], P = _[1], L = new a(y(b, O, P)), Y = 0, H = P > 0 ? O - 4 : O, V = 0; V < H; V += 4) w = u[b.charCodeAt(V)] << 18 | u[b.charCodeAt(V + 1)] << 12 | u[b.charCodeAt(V + 2)] << 6 | u[b.charCodeAt(V + 3)], L[Y++] = w >> 16 & 255, L[Y++] = w >> 8 & 255, L[Y++] = 255 & w; - return P === 2 && (w = u[b.charCodeAt(V)] << 2 | u[b.charCodeAt(V + 1)] >> 4, L[Y++] = 255 & w), P === 1 && (w = u[b.charCodeAt(V)] << 10 | u[b.charCodeAt(V + 1)] << 4 | u[b.charCodeAt(V + 2)] >> 2, L[Y++] = w >> 8 & 255, L[Y++] = 255 & w), L; - } - function T(b) { - return i[b >> 18 & 63] + i[b >> 12 & 63] + i[b >> 6 & 63] + i[63 & b]; - } - function v(b, w, _) { - for (var O, P = [], L = w; L < _; L += 3) O = (b[L] << 16 & 16711680) + (b[L + 1] << 8 & 65280) + (255 & b[L + 2]), P.push(T(O)); - return P.join(""); - } - function h(b) { - for (var w, _ = b.length, O = _ % 3, P = [], L = 0, Y = _ - O; L < Y; L += 16383) P.push(v(b, L, L + 16383 > Y ? Y : L + 16383)); - return O === 1 ? (w = b[_ - 1], P.push(i[w >> 2] + i[w << 4 & 63] + "==")) : O === 2 && (w = (b[_ - 2] << 8) + b[_ - 1], P.push(i[w >> 10] + i[w >> 4 & 63] + i[w << 2 & 63] + "=")), P.join(""); - } - u[45] = 62, u[95] = 63; - }, {}], 21: [function(n, o, p) { - }, {}], 22: [function(n, o, p) { - (function(i) { - (function(u) { - var a = typeof p == "object" && p && !p.nodeType && p, c = typeof o == "object" && o && !o.nodeType && o, l = typeof i == "object" && i; - l.global !== l && l.window !== l && l.self !== l || (u = l); - var f, d, E = 2147483647, y = 36, S = 1, T = 26, v = 38, h = 700, b = 72, w = 128, _ = "-", O = /^xn--/, P = /[^\x20-\x7E]/, L = /[\x2E\u3002\uFF0E\uFF61]/g, Y = { overflow: "Overflow: input needs wider integers to process", "not-basic": "Illegal input >= 0x80 (not a basic code point)", "invalid-input": "Invalid input" }, H = y - S, V = Math.floor, B = String.fromCharCode; - function ne(j) { - throw new RangeError(Y[j]); - } - function I(j, ie) { - for (var pe = j.length, se = []; pe--; ) se[pe] = ie(j[pe]); - return se; - } - function Z(j, ie) { - var pe = j.split("@"), se = ""; - return pe.length > 1 && (se = pe[0] + "@", j = pe[1]), se + I((j = j.replace(L, ".")).split("."), ie).join("."); - } - function te(j) { - for (var ie, pe, se = [], W = 0, G = j.length; W < G; ) (ie = j.charCodeAt(W++)) >= 55296 && ie <= 56319 && W < G ? (64512 & (pe = j.charCodeAt(W++))) == 56320 ? se.push(((1023 & ie) << 10) + (1023 & pe) + 65536) : (se.push(ie), W--) : se.push(ie); - return se; - } - function he(j) { - return I(j, function(ie) { - var pe = ""; - return ie > 65535 && (pe += B((ie -= 65536) >>> 10 & 1023 | 55296), ie = 56320 | 1023 & ie), pe += B(ie); - }).join(""); - } - function le(j, ie) { - return j + 22 + 75 * (j < 26) - ((ie != 0) << 5); - } - function ve(j, ie, pe) { - var se = 0; - for (j = pe ? V(j / h) : j >> 1, j += V(j / ie); j > H * T >> 1; se += y) j = V(j / H); - return V(se + (H + 1) * j / (j + v)); - } - function oe(j) { - var ie, pe, se, W, G, ae, ge, Ee, ye, Oe, Ae, Te = [], U = j.length, q = 0, de = w, F = b; - for ((pe = j.lastIndexOf(_)) < 0 && (pe = 0), se = 0; se < pe; ++se) j.charCodeAt(se) >= 128 && ne("not-basic"), Te.push(j.charCodeAt(se)); - for (W = pe > 0 ? pe + 1 : 0; W < U; ) { - for (G = q, ae = 1, ge = y; W >= U && ne("invalid-input"), ((Ee = (Ae = j.charCodeAt(W++)) - 48 < 10 ? Ae - 22 : Ae - 65 < 26 ? Ae - 65 : Ae - 97 < 26 ? Ae - 97 : y) >= y || Ee > V((E - q) / ae)) && ne("overflow"), q += Ee * ae, !(Ee < (ye = ge <= F ? S : ge >= F + T ? T : ge - F)); ge += y) ae > V(E / (Oe = y - ye)) && ne("overflow"), ae *= Oe; - F = ve(q - G, ie = Te.length + 1, G == 0), V(q / ie) > E - de && ne("overflow"), de += V(q / ie), q %= ie, Te.splice(q++, 0, de); - } - return he(Te); - } - function fe(j) { - var ie, pe, se, W, G, ae, ge, Ee, ye, Oe, Ae, Te, U, q, de, F = []; - for (Te = (j = te(j)).length, ie = w, pe = 0, G = b, ae = 0; ae < Te; ++ae) (Ae = j[ae]) < 128 && F.push(B(Ae)); - for (se = W = F.length, W && F.push(_); se < Te; ) { - for (ge = E, ae = 0; ae < Te; ++ae) (Ae = j[ae]) >= ie && Ae < ge && (ge = Ae); - for (ge - ie > V((E - pe) / (U = se + 1)) && ne("overflow"), pe += (ge - ie) * U, ie = ge, ae = 0; ae < Te; ++ae) if ((Ae = j[ae]) < ie && ++pe > E && ne("overflow"), Ae == ie) { - for (Ee = pe, ye = y; !(Ee < (Oe = ye <= G ? S : ye >= G + T ? T : ye - G)); ye += y) de = Ee - Oe, q = y - Oe, F.push(B(le(Oe + de % q, 0))), Ee = V(de / q); - F.push(B(le(Ee, 0))), G = ve(pe, U, se == W), pe = 0, ++se; - } - ++pe, ++ie; - } - return F.join(""); - } - if (f = { version: "1.4.1", ucs2: { decode: te, encode: he }, decode: oe, encode: fe, toASCII: function(j) { - return Z(j, function(ie) { - return P.test(ie) ? "xn--" + fe(ie) : ie; - }); - }, toUnicode: function(j) { - return Z(j, function(ie) { - return O.test(ie) ? oe(ie.slice(4).toLowerCase()) : ie; - }); - } }, a && c) if (o.exports == a) c.exports = f; - else for (d in f) f.hasOwnProperty(d) && (a[d] = f[d]); - else u.punycode = f; - })(this); - }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); - }, {}], 23: [function(n, o, p) { - var i = n("base64-js"), u = n("ieee754"); - p.Buffer = f, p.SlowBuffer = _, p.INSPECT_MAX_BYTES = 50; - var a = 2147483647; - function c() { - try { - var m = new Uint8Array(1); - return m.__proto__ = { __proto__: Uint8Array.prototype, foo: function() { - return 42; - } }, m.foo() === 42; - } catch { - return !1; - } - } - function l(m) { - if (m > a) throw new RangeError('The value "' + m + '" is invalid for option "size"'); - var A = new Uint8Array(m); - return A.__proto__ = f.prototype, A; - } - function f(m, A, R) { - if (typeof m == "number") { - if (typeof A == "string") throw new TypeError('The "string" argument must be of type string. Received type number'); - return S(m); - } - return d(m, A, R); - } - function d(m, A, R) { - if (typeof m == "string") return T(m, A); - if (ArrayBuffer.isView(m)) return v(m); - if (m == null) throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof m); - if (F(m, ArrayBuffer) || m && F(m.buffer, ArrayBuffer)) return h(m, A, R); - if (typeof m == "number") throw new TypeError('The "value" argument must not be of type number. Received type number'); - var K = m.valueOf && m.valueOf(); - if (K != null && K !== m) return f.from(K, A, R); - var Q = b(m); - if (Q) return Q; - if (typeof Symbol < "u" && Symbol.toPrimitive != null && typeof m[Symbol.toPrimitive] == "function") return f.from(m[Symbol.toPrimitive]("string"), A, R); - throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof m); - } - function E(m) { - if (typeof m != "number") throw new TypeError('"size" argument must be of type number'); - if (m < 0) throw new RangeError('The value "' + m + '" is invalid for option "size"'); - } - function y(m, A, R) { - return E(m), m <= 0 ? l(m) : A !== void 0 ? typeof R == "string" ? l(m).fill(A, R) : l(m).fill(A) : l(m); - } - function S(m) { - return E(m), l(m < 0 ? 0 : 0 | w(m)); - } - function T(m, A) { - if (typeof A == "string" && A !== "" || (A = "utf8"), !f.isEncoding(A)) throw new TypeError("Unknown encoding: " + A); - var R = 0 | O(m, A), K = l(R), Q = K.write(m, A); - return Q !== R && (K = K.slice(0, Q)), K; - } - function v(m) { - for (var A = m.length < 0 ? 0 : 0 | w(m.length), R = l(A), K = 0; K < A; K += 1) R[K] = 255 & m[K]; - return R; - } - function h(m, A, R) { - if (A < 0 || m.byteLength < A) throw new RangeError('"offset" is outside of buffer bounds'); - if (m.byteLength < A + (R || 0)) throw new RangeError('"length" is outside of buffer bounds'); - var K; - return (K = A === void 0 && R === void 0 ? new Uint8Array(m) : R === void 0 ? new Uint8Array(m, A) : new Uint8Array(m, A, R)).__proto__ = f.prototype, K; - } - function b(m) { - if (f.isBuffer(m)) { - var A = 0 | w(m.length), R = l(A); - return R.length === 0 || m.copy(R, 0, 0, A), R; - } - return m.length !== void 0 ? typeof m.length != "number" || ce(m.length) ? l(0) : v(m) : m.type === "Buffer" && Array.isArray(m.data) ? v(m.data) : void 0; - } - function w(m) { - if (m >= a) throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + a.toString(16) + " bytes"); - return 0 | m; - } - function _(m) { - return +m != m && (m = 0), f.alloc(+m); - } - function O(m, A) { - if (f.isBuffer(m)) return m.length; - if (ArrayBuffer.isView(m) || F(m, ArrayBuffer)) return m.byteLength; - if (typeof m != "string") throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ' + typeof m); - var R = m.length, K = arguments.length > 2 && arguments[2] === !0; - if (!K && R === 0) return 0; - for (var Q = !1; ; ) switch (A) { - case "ascii": - case "latin1": - case "binary": - return R; - case "utf8": - case "utf-8": - return Ae(m).length; - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return 2 * R; - case "hex": - return R >>> 1; - case "base64": - return q(m).length; - default: - if (Q) return K ? -1 : Ae(m).length; - A = ("" + A).toLowerCase(), Q = !0; - } - } - function P(m, A, R) { - var K = !1; - if ((A === void 0 || A < 0) && (A = 0), A > this.length || ((R === void 0 || R > this.length) && (R = this.length), R <= 0) || (R >>>= 0) <= (A >>>= 0)) return ""; - for (m || (m = "utf8"); ; ) switch (m) { - case "hex": - return ie(this, A, R); - case "utf8": - case "utf-8": - return le(this, A, R); - case "ascii": - return fe(this, A, R); - case "latin1": - case "binary": - return j(this, A, R); - case "base64": - return he(this, A, R); - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return pe(this, A, R); - default: - if (K) throw new TypeError("Unknown encoding: " + m); - m = (m + "").toLowerCase(), K = !0; - } - } - function L(m, A, R) { - var K = m[A]; - m[A] = m[R], m[R] = K; - } - function Y(m, A, R, K, Q) { - if (m.length === 0) return -1; - if (typeof R == "string" ? (K = R, R = 0) : R > 2147483647 ? R = 2147483647 : R < -2147483648 && (R = -2147483648), ce(R = +R) && (R = Q ? 0 : m.length - 1), R < 0 && (R = m.length + R), R >= m.length) { - if (Q) return -1; - R = m.length - 1; - } else if (R < 0) { - if (!Q) return -1; - R = 0; - } - if (typeof A == "string" && (A = f.from(A, K)), f.isBuffer(A)) return A.length === 0 ? -1 : H(m, A, R, K, Q); - if (typeof A == "number") return A &= 255, typeof Uint8Array.prototype.indexOf == "function" ? Q ? Uint8Array.prototype.indexOf.call(m, A, R) : Uint8Array.prototype.lastIndexOf.call(m, A, R) : H(m, [A], R, K, Q); - throw new TypeError("val must be string, number or Buffer"); - } - function H(m, A, R, K, Q) { - var z, be = 1, N = m.length, e = A.length; - if (K !== void 0 && ((K = String(K).toLowerCase()) === "ucs2" || K === "ucs-2" || K === "utf16le" || K === "utf-16le")) { - if (m.length < 2 || A.length < 2) return -1; - be = 2, N /= 2, e /= 2, R /= 2; - } - function t(g, k) { - return be === 1 ? g[k] : g.readUInt16BE(k * be); - } - if (Q) { - var x = -1; - for (z = R; z < N; z++) if (t(m, z) === t(A, x === -1 ? 0 : z - x)) { - if (x === -1 && (x = z), z - x + 1 === e) return x * be; - } else x !== -1 && (z -= z - x), x = -1; - } else for (R + e > N && (R = N - e), z = R; z >= 0; z--) { - for (var C = !0, M = 0; M < e; M++) if (t(m, z + M) !== t(A, M)) { - C = !1; - break; - } - if (C) return z; - } - return -1; - } - function V(m, A, R, K) { - R = Number(R) || 0; - var Q = m.length - R; - K ? (K = Number(K)) > Q && (K = Q) : K = Q; - var z = A.length; - K > z / 2 && (K = z / 2); - for (var be = 0; be < K; ++be) { - var N = parseInt(A.substr(2 * be, 2), 16); - if (ce(N)) return be; - m[R + be] = N; - } - return be; - } - function B(m, A, R, K) { - return de(Ae(A, m.length - R), m, R, K); - } - function ne(m, A, R, K) { - return de(Te(A), m, R, K); - } - function I(m, A, R, K) { - return ne(m, A, R, K); - } - function Z(m, A, R, K) { - return de(q(A), m, R, K); - } - function te(m, A, R, K) { - return de(U(A, m.length - R), m, R, K); - } - function he(m, A, R) { - return A === 0 && R === m.length ? i.fromByteArray(m) : i.fromByteArray(m.slice(A, R)); - } - function le(m, A, R) { - R = Math.min(m.length, R); - for (var K = [], Q = A; Q < R; ) { - var z, be, N, e, t = m[Q], x = null, C = t > 239 ? 4 : t > 223 ? 3 : t > 191 ? 2 : 1; - if (Q + C <= R) switch (C) { - case 1: - t < 128 && (x = t); - break; - case 2: - (192 & (z = m[Q + 1])) == 128 && (e = (31 & t) << 6 | 63 & z) > 127 && (x = e); - break; - case 3: - z = m[Q + 1], be = m[Q + 2], (192 & z) == 128 && (192 & be) == 128 && (e = (15 & t) << 12 | (63 & z) << 6 | 63 & be) > 2047 && (e < 55296 || e > 57343) && (x = e); - break; - case 4: - z = m[Q + 1], be = m[Q + 2], N = m[Q + 3], (192 & z) == 128 && (192 & be) == 128 && (192 & N) == 128 && (e = (15 & t) << 18 | (63 & z) << 12 | (63 & be) << 6 | 63 & N) > 65535 && e < 1114112 && (x = e); - } - x === null ? (x = 65533, C = 1) : x > 65535 && (x -= 65536, K.push(x >>> 10 & 1023 | 55296), x = 56320 | 1023 & x), K.push(x), Q += C; - } - return oe(K); - } - p.kMaxLength = a, f.TYPED_ARRAY_SUPPORT = c(), f.TYPED_ARRAY_SUPPORT || typeof console > "u" || typeof console.error != "function" || console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."), Object.defineProperty(f.prototype, "parent", { enumerable: !0, get: function() { - if (f.isBuffer(this)) return this.buffer; - } }), Object.defineProperty(f.prototype, "offset", { enumerable: !0, get: function() { - if (f.isBuffer(this)) return this.byteOffset; - } }), typeof Symbol < "u" && Symbol.species != null && f[Symbol.species] === f && Object.defineProperty(f, Symbol.species, { value: null, configurable: !0, enumerable: !1, writable: !1 }), f.poolSize = 8192, f.from = function(m, A, R) { - return d(m, A, R); - }, f.prototype.__proto__ = Uint8Array.prototype, f.__proto__ = Uint8Array, f.alloc = function(m, A, R) { - return y(m, A, R); - }, f.allocUnsafe = function(m) { - return S(m); - }, f.allocUnsafeSlow = function(m) { - return S(m); - }, f.isBuffer = function(m) { - return m != null && m._isBuffer === !0 && m !== f.prototype; - }, f.compare = function(m, A) { - if (F(m, Uint8Array) && (m = f.from(m, m.offset, m.byteLength)), F(A, Uint8Array) && (A = f.from(A, A.offset, A.byteLength)), !f.isBuffer(m) || !f.isBuffer(A)) throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array'); - if (m === A) return 0; - for (var R = m.length, K = A.length, Q = 0, z = Math.min(R, K); Q < z; ++Q) if (m[Q] !== A[Q]) { - R = m[Q], K = A[Q]; - break; - } - return R < K ? -1 : K < R ? 1 : 0; - }, f.isEncoding = function(m) { - switch (String(m).toLowerCase()) { - case "hex": - case "utf8": - case "utf-8": - case "ascii": - case "latin1": - case "binary": - case "base64": - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return !0; - default: - return !1; - } - }, f.concat = function(m, A) { - if (!Array.isArray(m)) throw new TypeError('"list" argument must be an Array of Buffers'); - if (m.length === 0) return f.alloc(0); - var R; - if (A === void 0) for (A = 0, R = 0; R < m.length; ++R) A += m[R].length; - var K = f.allocUnsafe(A), Q = 0; - for (R = 0; R < m.length; ++R) { - var z = m[R]; - if (F(z, Uint8Array) && (z = f.from(z)), !f.isBuffer(z)) throw new TypeError('"list" argument must be an Array of Buffers'); - z.copy(K, Q), Q += z.length; - } - return K; - }, f.byteLength = O, f.prototype._isBuffer = !0, f.prototype.swap16 = function() { - var m = this.length; - if (m % 2 != 0) throw new RangeError("Buffer size must be a multiple of 16-bits"); - for (var A = 0; A < m; A += 2) L(this, A, A + 1); - return this; - }, f.prototype.swap32 = function() { - var m = this.length; - if (m % 4 != 0) throw new RangeError("Buffer size must be a multiple of 32-bits"); - for (var A = 0; A < m; A += 4) L(this, A, A + 3), L(this, A + 1, A + 2); - return this; - }, f.prototype.swap64 = function() { - var m = this.length; - if (m % 8 != 0) throw new RangeError("Buffer size must be a multiple of 64-bits"); - for (var A = 0; A < m; A += 8) L(this, A, A + 7), L(this, A + 1, A + 6), L(this, A + 2, A + 5), L(this, A + 3, A + 4); - return this; - }, f.prototype.toString = function() { - var m = this.length; - return m === 0 ? "" : arguments.length === 0 ? le(this, 0, m) : P.apply(this, arguments); - }, f.prototype.toLocaleString = f.prototype.toString, f.prototype.equals = function(m) { - if (!f.isBuffer(m)) throw new TypeError("Argument must be a Buffer"); - return this === m || f.compare(this, m) === 0; - }, f.prototype.inspect = function() { - var m = "", A = p.INSPECT_MAX_BYTES; - return m = this.toString("hex", 0, A).replace(/(.{2})/g, "$1 ").trim(), this.length > A && (m += " ... "), ""; - }, f.prototype.compare = function(m, A, R, K, Q) { - if (F(m, Uint8Array) && (m = f.from(m, m.offset, m.byteLength)), !f.isBuffer(m)) throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type ' + typeof m); - if (A === void 0 && (A = 0), R === void 0 && (R = m ? m.length : 0), K === void 0 && (K = 0), Q === void 0 && (Q = this.length), A < 0 || R > m.length || K < 0 || Q > this.length) throw new RangeError("out of range index"); - if (K >= Q && A >= R) return 0; - if (K >= Q) return -1; - if (A >= R) return 1; - if (this === m) return 0; - for (var z = (Q >>>= 0) - (K >>>= 0), be = (R >>>= 0) - (A >>>= 0), N = Math.min(z, be), e = this.slice(K, Q), t = m.slice(A, R), x = 0; x < N; ++x) if (e[x] !== t[x]) { - z = e[x], be = t[x]; - break; - } - return z < be ? -1 : be < z ? 1 : 0; - }, f.prototype.includes = function(m, A, R) { - return this.indexOf(m, A, R) !== -1; - }, f.prototype.indexOf = function(m, A, R) { - return Y(this, m, A, R, !0); - }, f.prototype.lastIndexOf = function(m, A, R) { - return Y(this, m, A, R, !1); - }, f.prototype.write = function(m, A, R, K) { - if (A === void 0) K = "utf8", R = this.length, A = 0; - else if (R === void 0 && typeof A == "string") K = A, R = this.length, A = 0; - else { - if (!isFinite(A)) throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported"); - A >>>= 0, isFinite(R) ? (R >>>= 0, K === void 0 && (K = "utf8")) : (K = R, R = void 0); - } - var Q = this.length - A; - if ((R === void 0 || R > Q) && (R = Q), m.length > 0 && (R < 0 || A < 0) || A > this.length) throw new RangeError("Attempt to write outside buffer bounds"); - K || (K = "utf8"); - for (var z = !1; ; ) switch (K) { - case "hex": - return V(this, m, A, R); - case "utf8": - case "utf-8": - return B(this, m, A, R); - case "ascii": - return ne(this, m, A, R); - case "latin1": - case "binary": - return I(this, m, A, R); - case "base64": - return Z(this, m, A, R); - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return te(this, m, A, R); - default: - if (z) throw new TypeError("Unknown encoding: " + K); - K = ("" + K).toLowerCase(), z = !0; - } - }, f.prototype.toJSON = function() { - return { type: "Buffer", data: Array.prototype.slice.call(this._arr || this, 0) }; - }; - var ve = 4096; - function oe(m) { - var A = m.length; - if (A <= ve) return String.fromCharCode.apply(String, m); - for (var R = "", K = 0; K < A; ) R += String.fromCharCode.apply(String, m.slice(K, K += ve)); - return R; - } - function fe(m, A, R) { - var K = ""; - R = Math.min(m.length, R); - for (var Q = A; Q < R; ++Q) K += String.fromCharCode(127 & m[Q]); - return K; - } - function j(m, A, R) { - var K = ""; - R = Math.min(m.length, R); - for (var Q = A; Q < R; ++Q) K += String.fromCharCode(m[Q]); - return K; - } - function ie(m, A, R) { - var K = m.length; - (!A || A < 0) && (A = 0), (!R || R < 0 || R > K) && (R = K); - for (var Q = "", z = A; z < R; ++z) Q += Oe(m[z]); - return Q; - } - function pe(m, A, R) { - for (var K = m.slice(A, R), Q = "", z = 0; z < K.length; z += 2) Q += String.fromCharCode(K[z] + 256 * K[z + 1]); - return Q; - } - function se(m, A, R) { - if (m % 1 != 0 || m < 0) throw new RangeError("offset is not uint"); - if (m + A > R) throw new RangeError("Trying to access beyond buffer length"); - } - function W(m, A, R, K, Q, z) { - if (!f.isBuffer(m)) throw new TypeError('"buffer" argument must be a Buffer instance'); - if (A > Q || A < z) throw new RangeError('"value" argument is out of bounds'); - if (R + K > m.length) throw new RangeError("Index out of range"); - } - function G(m, A, R, K, Q, z) { - if (R + K > m.length) throw new RangeError("Index out of range"); - if (R < 0) throw new RangeError("Index out of range"); - } - function ae(m, A, R, K, Q) { - return A = +A, R >>>= 0, Q || G(m, A, R, 4), u.write(m, A, R, K, 23, 4), R + 4; - } - function ge(m, A, R, K, Q) { - return A = +A, R >>>= 0, Q || G(m, A, R, 8), u.write(m, A, R, K, 52, 8), R + 8; - } - f.prototype.slice = function(m, A) { - var R = this.length; - (m = ~~m) < 0 ? (m += R) < 0 && (m = 0) : m > R && (m = R), (A = A === void 0 ? R : ~~A) < 0 ? (A += R) < 0 && (A = 0) : A > R && (A = R), A < m && (A = m); - var K = this.subarray(m, A); - return K.__proto__ = f.prototype, K; - }, f.prototype.readUIntLE = function(m, A, R) { - m >>>= 0, A >>>= 0, R || se(m, A, this.length); - for (var K = this[m], Q = 1, z = 0; ++z < A && (Q *= 256); ) K += this[m + z] * Q; - return K; - }, f.prototype.readUIntBE = function(m, A, R) { - m >>>= 0, A >>>= 0, R || se(m, A, this.length); - for (var K = this[m + --A], Q = 1; A > 0 && (Q *= 256); ) K += this[m + --A] * Q; - return K; - }, f.prototype.readUInt8 = function(m, A) { - return m >>>= 0, A || se(m, 1, this.length), this[m]; - }, f.prototype.readUInt16LE = function(m, A) { - return m >>>= 0, A || se(m, 2, this.length), this[m] | this[m + 1] << 8; - }, f.prototype.readUInt16BE = function(m, A) { - return m >>>= 0, A || se(m, 2, this.length), this[m] << 8 | this[m + 1]; - }, f.prototype.readUInt32LE = function(m, A) { - return m >>>= 0, A || se(m, 4, this.length), (this[m] | this[m + 1] << 8 | this[m + 2] << 16) + 16777216 * this[m + 3]; - }, f.prototype.readUInt32BE = function(m, A) { - return m >>>= 0, A || se(m, 4, this.length), 16777216 * this[m] + (this[m + 1] << 16 | this[m + 2] << 8 | this[m + 3]); - }, f.prototype.readIntLE = function(m, A, R) { - m >>>= 0, A >>>= 0, R || se(m, A, this.length); - for (var K = this[m], Q = 1, z = 0; ++z < A && (Q *= 256); ) K += this[m + z] * Q; - return K >= (Q *= 128) && (K -= Math.pow(2, 8 * A)), K; - }, f.prototype.readIntBE = function(m, A, R) { - m >>>= 0, A >>>= 0, R || se(m, A, this.length); - for (var K = A, Q = 1, z = this[m + --K]; K > 0 && (Q *= 256); ) z += this[m + --K] * Q; - return z >= (Q *= 128) && (z -= Math.pow(2, 8 * A)), z; - }, f.prototype.readInt8 = function(m, A) { - return m >>>= 0, A || se(m, 1, this.length), 128 & this[m] ? -1 * (255 - this[m] + 1) : this[m]; - }, f.prototype.readInt16LE = function(m, A) { - m >>>= 0, A || se(m, 2, this.length); - var R = this[m] | this[m + 1] << 8; - return 32768 & R ? 4294901760 | R : R; - }, f.prototype.readInt16BE = function(m, A) { - m >>>= 0, A || se(m, 2, this.length); - var R = this[m + 1] | this[m] << 8; - return 32768 & R ? 4294901760 | R : R; - }, f.prototype.readInt32LE = function(m, A) { - return m >>>= 0, A || se(m, 4, this.length), this[m] | this[m + 1] << 8 | this[m + 2] << 16 | this[m + 3] << 24; - }, f.prototype.readInt32BE = function(m, A) { - return m >>>= 0, A || se(m, 4, this.length), this[m] << 24 | this[m + 1] << 16 | this[m + 2] << 8 | this[m + 3]; - }, f.prototype.readFloatLE = function(m, A) { - return m >>>= 0, A || se(m, 4, this.length), u.read(this, m, !0, 23, 4); - }, f.prototype.readFloatBE = function(m, A) { - return m >>>= 0, A || se(m, 4, this.length), u.read(this, m, !1, 23, 4); - }, f.prototype.readDoubleLE = function(m, A) { - return m >>>= 0, A || se(m, 8, this.length), u.read(this, m, !0, 52, 8); - }, f.prototype.readDoubleBE = function(m, A) { - return m >>>= 0, A || se(m, 8, this.length), u.read(this, m, !1, 52, 8); - }, f.prototype.writeUIntLE = function(m, A, R, K) { - m = +m, A >>>= 0, R >>>= 0, K || W(this, m, A, R, Math.pow(2, 8 * R) - 1, 0); - var Q = 1, z = 0; - for (this[A] = 255 & m; ++z < R && (Q *= 256); ) this[A + z] = m / Q & 255; - return A + R; - }, f.prototype.writeUIntBE = function(m, A, R, K) { - m = +m, A >>>= 0, R >>>= 0, K || W(this, m, A, R, Math.pow(2, 8 * R) - 1, 0); - var Q = R - 1, z = 1; - for (this[A + Q] = 255 & m; --Q >= 0 && (z *= 256); ) this[A + Q] = m / z & 255; - return A + R; - }, f.prototype.writeUInt8 = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 1, 255, 0), this[A] = 255 & m, A + 1; - }, f.prototype.writeUInt16LE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 2, 65535, 0), this[A] = 255 & m, this[A + 1] = m >>> 8, A + 2; - }, f.prototype.writeUInt16BE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 2, 65535, 0), this[A] = m >>> 8, this[A + 1] = 255 & m, A + 2; - }, f.prototype.writeUInt32LE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 4, 4294967295, 0), this[A + 3] = m >>> 24, this[A + 2] = m >>> 16, this[A + 1] = m >>> 8, this[A] = 255 & m, A + 4; - }, f.prototype.writeUInt32BE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 4, 4294967295, 0), this[A] = m >>> 24, this[A + 1] = m >>> 16, this[A + 2] = m >>> 8, this[A + 3] = 255 & m, A + 4; - }, f.prototype.writeIntLE = function(m, A, R, K) { - if (m = +m, A >>>= 0, !K) { - var Q = Math.pow(2, 8 * R - 1); - W(this, m, A, R, Q - 1, -Q); - } - var z = 0, be = 1, N = 0; - for (this[A] = 255 & m; ++z < R && (be *= 256); ) m < 0 && N === 0 && this[A + z - 1] !== 0 && (N = 1), this[A + z] = (m / be >> 0) - N & 255; - return A + R; - }, f.prototype.writeIntBE = function(m, A, R, K) { - if (m = +m, A >>>= 0, !K) { - var Q = Math.pow(2, 8 * R - 1); - W(this, m, A, R, Q - 1, -Q); - } - var z = R - 1, be = 1, N = 0; - for (this[A + z] = 255 & m; --z >= 0 && (be *= 256); ) m < 0 && N === 0 && this[A + z + 1] !== 0 && (N = 1), this[A + z] = (m / be >> 0) - N & 255; - return A + R; - }, f.prototype.writeInt8 = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 1, 127, -128), m < 0 && (m = 255 + m + 1), this[A] = 255 & m, A + 1; - }, f.prototype.writeInt16LE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 2, 32767, -32768), this[A] = 255 & m, this[A + 1] = m >>> 8, A + 2; - }, f.prototype.writeInt16BE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 2, 32767, -32768), this[A] = m >>> 8, this[A + 1] = 255 & m, A + 2; - }, f.prototype.writeInt32LE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 4, 2147483647, -2147483648), this[A] = 255 & m, this[A + 1] = m >>> 8, this[A + 2] = m >>> 16, this[A + 3] = m >>> 24, A + 4; - }, f.prototype.writeInt32BE = function(m, A, R) { - return m = +m, A >>>= 0, R || W(this, m, A, 4, 2147483647, -2147483648), m < 0 && (m = 4294967295 + m + 1), this[A] = m >>> 24, this[A + 1] = m >>> 16, this[A + 2] = m >>> 8, this[A + 3] = 255 & m, A + 4; - }, f.prototype.writeFloatLE = function(m, A, R) { - return ae(this, m, A, !0, R); - }, f.prototype.writeFloatBE = function(m, A, R) { - return ae(this, m, A, !1, R); - }, f.prototype.writeDoubleLE = function(m, A, R) { - return ge(this, m, A, !0, R); - }, f.prototype.writeDoubleBE = function(m, A, R) { - return ge(this, m, A, !1, R); - }, f.prototype.copy = function(m, A, R, K) { - if (!f.isBuffer(m)) throw new TypeError("argument should be a Buffer"); - if (R || (R = 0), K || K === 0 || (K = this.length), A >= m.length && (A = m.length), A || (A = 0), K > 0 && K < R && (K = R), K === R || m.length === 0 || this.length === 0) return 0; - if (A < 0) throw new RangeError("targetStart out of bounds"); - if (R < 0 || R >= this.length) throw new RangeError("Index out of range"); - if (K < 0) throw new RangeError("sourceEnd out of bounds"); - K > this.length && (K = this.length), m.length - A < K - R && (K = m.length - A + R); - var Q = K - R; - if (this === m && typeof Uint8Array.prototype.copyWithin == "function") this.copyWithin(A, R, K); - else if (this === m && R < A && A < K) for (var z = Q - 1; z >= 0; --z) m[z + A] = this[z + R]; - else Uint8Array.prototype.set.call(m, this.subarray(R, K), A); - return Q; - }, f.prototype.fill = function(m, A, R, K) { - if (typeof m == "string") { - if (typeof A == "string" ? (K = A, A = 0, R = this.length) : typeof R == "string" && (K = R, R = this.length), K !== void 0 && typeof K != "string") throw new TypeError("encoding must be a string"); - if (typeof K == "string" && !f.isEncoding(K)) throw new TypeError("Unknown encoding: " + K); - if (m.length === 1) { - var Q = m.charCodeAt(0); - (K === "utf8" && Q < 128 || K === "latin1") && (m = Q); - } - } else typeof m == "number" && (m &= 255); - if (A < 0 || this.length < A || this.length < R) throw new RangeError("Out of range index"); - if (R <= A) return this; - var z; - if (A >>>= 0, R = R === void 0 ? this.length : R >>> 0, m || (m = 0), typeof m == "number") for (z = A; z < R; ++z) this[z] = m; - else { - var be = f.isBuffer(m) ? m : f.from(m, K), N = be.length; - if (N === 0) throw new TypeError('The value "' + m + '" is invalid for argument "value"'); - for (z = 0; z < R - A; ++z) this[z + A] = be[z % N]; - } - return this; - }; - var Ee = /[^+\/0-9A-Za-z-_]/g; - function ye(m) { - if ((m = (m = m.split("=")[0]).trim().replace(Ee, "")).length < 2) return ""; - for (; m.length % 4 != 0; ) m += "="; - return m; - } - function Oe(m) { - return m < 16 ? "0" + m.toString(16) : m.toString(16); - } - function Ae(m, A) { - var R; - A = A || 1 / 0; - for (var K = m.length, Q = null, z = [], be = 0; be < K; ++be) { - if ((R = m.charCodeAt(be)) > 55295 && R < 57344) { - if (!Q) { - if (R > 56319) { - (A -= 3) > -1 && z.push(239, 191, 189); - continue; - } - if (be + 1 === K) { - (A -= 3) > -1 && z.push(239, 191, 189); - continue; - } - Q = R; - continue; - } - if (R < 56320) { - (A -= 3) > -1 && z.push(239, 191, 189), Q = R; - continue; - } - R = 65536 + (Q - 55296 << 10 | R - 56320); - } else Q && (A -= 3) > -1 && z.push(239, 191, 189); - if (Q = null, R < 128) { - if ((A -= 1) < 0) break; - z.push(R); - } else if (R < 2048) { - if ((A -= 2) < 0) break; - z.push(R >> 6 | 192, 63 & R | 128); - } else if (R < 65536) { - if ((A -= 3) < 0) break; - z.push(R >> 12 | 224, R >> 6 & 63 | 128, 63 & R | 128); - } else { - if (!(R < 1114112)) throw new Error("Invalid code point"); - if ((A -= 4) < 0) break; - z.push(R >> 18 | 240, R >> 12 & 63 | 128, R >> 6 & 63 | 128, 63 & R | 128); - } - } - return z; - } - function Te(m) { - for (var A = [], R = 0; R < m.length; ++R) A.push(255 & m.charCodeAt(R)); - return A; - } - function U(m, A) { - for (var R, K, Q, z = [], be = 0; be < m.length && !((A -= 2) < 0); ++be) K = (R = m.charCodeAt(be)) >> 8, Q = R % 256, z.push(Q), z.push(K); - return z; - } - function q(m) { - return i.toByteArray(ye(m)); - } - function de(m, A, R, K) { - for (var Q = 0; Q < K && !(Q + R >= A.length || Q >= m.length); ++Q) A[Q + R] = m[Q]; - return Q; - } - function F(m, A) { - return m instanceof A || m != null && m.constructor != null && m.constructor.name != null && m.constructor.name === A.name; - } - function ce(m) { - return m != m; - } - }, { "base64-js": 20, ieee754: 30 }], 24: [function(n, o, p) { - o.exports = { 100: "Continue", 101: "Switching Protocols", 102: "Processing", 200: "OK", 201: "Created", 202: "Accepted", 203: "Non-Authoritative Information", 204: "No Content", 205: "Reset Content", 206: "Partial Content", 207: "Multi-Status", 208: "Already Reported", 226: "IM Used", 300: "Multiple Choices", 301: "Moved Permanently", 302: "Found", 303: "See Other", 304: "Not Modified", 305: "Use Proxy", 307: "Temporary Redirect", 308: "Permanent Redirect", 400: "Bad Request", 401: "Unauthorized", 402: "Payment Required", 403: "Forbidden", 404: "Not Found", 405: "Method Not Allowed", 406: "Not Acceptable", 407: "Proxy Authentication Required", 408: "Request Timeout", 409: "Conflict", 410: "Gone", 411: "Length Required", 412: "Precondition Failed", 413: "Payload Too Large", 414: "URI Too Long", 415: "Unsupported Media Type", 416: "Range Not Satisfiable", 417: "Expectation Failed", 418: "I'm a teapot", 421: "Misdirected Request", 422: "Unprocessable Entity", 423: "Locked", 424: "Failed Dependency", 425: "Unordered Collection", 426: "Upgrade Required", 428: "Precondition Required", 429: "Too Many Requests", 431: "Request Header Fields Too Large", 451: "Unavailable For Legal Reasons", 500: "Internal Server Error", 501: "Not Implemented", 502: "Bad Gateway", 503: "Service Unavailable", 504: "Gateway Timeout", 505: "HTTP Version Not Supported", 506: "Variant Also Negotiates", 507: "Insufficient Storage", 508: "Loop Detected", 509: "Bandwidth Limit Exceeded", 510: "Not Extended", 511: "Network Authentication Required" }; - }, {}], 25: [function(n, o, p) { - (function(i, u) { - var a = u.process && i.nextTick || u.setImmediate || function(c) { - setTimeout(c, 0); - }; - o.exports = function(c, l) { - return c ? void l.then(function(f) { - a(function() { - c(null, f); - }); - }, function(f) { - a(function() { - c(f); - }); - }) : l; - }; - }).call(this, n("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); - }, { _process: 66 }], 26: [function(n, o, p) { - (function(i) { - function u(O) { - return Array.isArray ? Array.isArray(O) : _(O) === "[object Array]"; - } - function a(O) { - return typeof O == "boolean"; - } - function c(O) { - return O === null; - } - function l(O) { - return O == null; - } - function f(O) { - return typeof O == "number"; - } - function d(O) { - return typeof O == "string"; - } - function E(O) { - return typeof O == "symbol"; - } - function y(O) { - return O === void 0; - } - function S(O) { - return _(O) === "[object RegExp]"; - } - function T(O) { - return typeof O == "object" && O !== null; - } - function v(O) { - return _(O) === "[object Date]"; - } - function h(O) { - return _(O) === "[object Error]" || O instanceof Error; - } - function b(O) { - return typeof O == "function"; - } - function w(O) { - return O === null || typeof O == "boolean" || typeof O == "number" || typeof O == "string" || typeof O == "symbol" || O === void 0; - } - function _(O) { - return Object.prototype.toString.call(O); - } - p.isArray = u, p.isBoolean = a, p.isNull = c, p.isNullOrUndefined = l, p.isNumber = f, p.isString = d, p.isSymbol = E, p.isUndefined = y, p.isRegExp = S, p.isObject = T, p.isDate = v, p.isError = h, p.isFunction = b, p.isPrimitive = w, p.isBuffer = i.isBuffer; - }).call(this, { isBuffer: n("../../is-buffer/index.js") }); - }, { "../../is-buffer/index.js": 32 }], 27: [function(n, o, p) { - var i = Object.create || V, u = Object.keys || B, a = Function.prototype.bind || ne; - function c() { - this._events && Object.prototype.hasOwnProperty.call(this, "_events") || (this._events = i(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0; - } - o.exports = c, c.EventEmitter = c, c.prototype._events = void 0, c.prototype._maxListeners = void 0; - var l, f = 10; - try { - var d = {}; - Object.defineProperty && Object.defineProperty(d, "x", { value: 0 }), l = d.x === 0; - } catch { - l = !1; - } - function E(I) { - return I._maxListeners === void 0 ? c.defaultMaxListeners : I._maxListeners; - } - function y(I, Z, te) { - if (Z) I.call(te); - else for (var he = I.length, le = Y(I, he), ve = 0; ve < he; ++ve) le[ve].call(te); - } - function S(I, Z, te, he) { - if (Z) I.call(te, he); - else for (var le = I.length, ve = Y(I, le), oe = 0; oe < le; ++oe) ve[oe].call(te, he); - } - function T(I, Z, te, he, le) { - if (Z) I.call(te, he, le); - else for (var ve = I.length, oe = Y(I, ve), fe = 0; fe < ve; ++fe) oe[fe].call(te, he, le); - } - function v(I, Z, te, he, le, ve) { - if (Z) I.call(te, he, le, ve); - else for (var oe = I.length, fe = Y(I, oe), j = 0; j < oe; ++j) fe[j].call(te, he, le, ve); - } - function h(I, Z, te, he) { - if (Z) I.apply(te, he); - else for (var le = I.length, ve = Y(I, le), oe = 0; oe < le; ++oe) ve[oe].apply(te, he); - } - function b(I, Z, te, he) { - var le, ve, oe; - if (typeof te != "function") throw new TypeError('"listener" argument must be a function'); - if ((ve = I._events) ? (ve.newListener && (I.emit("newListener", Z, te.listener ? te.listener : te), ve = I._events), oe = ve[Z]) : (ve = I._events = i(null), I._eventsCount = 0), oe) { - if (typeof oe == "function" ? oe = ve[Z] = he ? [te, oe] : [oe, te] : he ? oe.unshift(te) : oe.push(te), !oe.warned && (le = E(I)) && le > 0 && oe.length > le) { - oe.warned = !0; - var fe = new Error("Possible EventEmitter memory leak detected. " + oe.length + ' "' + String(Z) + '" listeners added. Use emitter.setMaxListeners() to increase limit.'); - fe.name = "MaxListenersExceededWarning", fe.emitter = I, fe.type = Z, fe.count = oe.length, typeof console == "object" && console.warn && console.warn("%s: %s", fe.name, fe.message); - } - } else oe = ve[Z] = te, ++I._eventsCount; - return I; - } - function w() { - if (!this.fired) switch (this.target.removeListener(this.type, this.wrapFn), this.fired = !0, arguments.length) { - case 0: - return this.listener.call(this.target); - case 1: - return this.listener.call(this.target, arguments[0]); - case 2: - return this.listener.call(this.target, arguments[0], arguments[1]); - case 3: - return this.listener.call(this.target, arguments[0], arguments[1], arguments[2]); - default: - for (var I = new Array(arguments.length), Z = 0; Z < I.length; ++Z) I[Z] = arguments[Z]; - this.listener.apply(this.target, I); - } - } - function _(I, Z, te) { - var he = { fired: !1, wrapFn: void 0, target: I, type: Z, listener: te }, le = a.call(w, he); - return le.listener = te, he.wrapFn = le, le; - } - function O(I, Z, te) { - var he = I._events; - if (!he) return []; - var le = he[Z]; - return le ? typeof le == "function" ? te ? [le.listener || le] : [le] : te ? H(le) : Y(le, le.length) : []; - } - function P(I) { - var Z = this._events; - if (Z) { - var te = Z[I]; - if (typeof te == "function") return 1; - if (te) return te.length; - } - return 0; - } - function L(I, Z) { - for (var te = Z, he = te + 1, le = I.length; he < le; te += 1, he += 1) I[te] = I[he]; - I.pop(); - } - function Y(I, Z) { - for (var te = new Array(Z), he = 0; he < Z; ++he) te[he] = I[he]; - return te; - } - function H(I) { - for (var Z = new Array(I.length), te = 0; te < Z.length; ++te) Z[te] = I[te].listener || I[te]; - return Z; - } - function V(I) { - var Z = function() { - }; - return Z.prototype = I, new Z(); - } - function B(I) { - var Z = []; - for (var te in I) Object.prototype.hasOwnProperty.call(I, te) && Z.push(te); - return te; - } - function ne(I) { - var Z = this; - return function() { - return Z.apply(I, arguments); - }; - } - l ? Object.defineProperty(c, "defaultMaxListeners", { enumerable: !0, get: function() { - return f; - }, set: function(I) { - if (typeof I != "number" || I < 0 || I != I) throw new TypeError('"defaultMaxListeners" must be a positive number'); - f = I; - } }) : c.defaultMaxListeners = f, c.prototype.setMaxListeners = function(I) { - if (typeof I != "number" || I < 0 || isNaN(I)) throw new TypeError('"n" argument must be a positive number'); - return this._maxListeners = I, this; - }, c.prototype.getMaxListeners = function() { - return E(this); - }, c.prototype.emit = function(I) { - var Z, te, he, le, ve, oe, fe = I === "error"; - if (oe = this._events) fe = fe && oe.error == null; - else if (!fe) return !1; - if (fe) { - if (arguments.length > 1 && (Z = arguments[1]), Z instanceof Error) throw Z; - var j = new Error('Unhandled "error" event. (' + Z + ")"); - throw j.context = Z, j; - } - if (!(te = oe[I])) return !1; - var ie = typeof te == "function"; - switch (he = arguments.length) { - case 1: - y(te, ie, this); - break; - case 2: - S(te, ie, this, arguments[1]); - break; - case 3: - T(te, ie, this, arguments[1], arguments[2]); - break; - case 4: - v(te, ie, this, arguments[1], arguments[2], arguments[3]); - break; - default: - for (le = new Array(he - 1), ve = 1; ve < he; ve++) le[ve - 1] = arguments[ve]; - h(te, ie, this, le); - } - return !0; - }, c.prototype.addListener = function(I, Z) { - return b(this, I, Z, !1); - }, c.prototype.on = c.prototype.addListener, c.prototype.prependListener = function(I, Z) { - return b(this, I, Z, !0); - }, c.prototype.once = function(I, Z) { - if (typeof Z != "function") throw new TypeError('"listener" argument must be a function'); - return this.on(I, _(this, I, Z)), this; - }, c.prototype.prependOnceListener = function(I, Z) { - if (typeof Z != "function") throw new TypeError('"listener" argument must be a function'); - return this.prependListener(I, _(this, I, Z)), this; - }, c.prototype.removeListener = function(I, Z) { - var te, he, le, ve, oe; - if (typeof Z != "function") throw new TypeError('"listener" argument must be a function'); - if (!(he = this._events)) return this; - if (!(te = he[I])) return this; - if (te === Z || te.listener === Z) --this._eventsCount == 0 ? this._events = i(null) : (delete he[I], he.removeListener && this.emit("removeListener", I, te.listener || Z)); - else if (typeof te != "function") { - for (le = -1, ve = te.length - 1; ve >= 0; ve--) if (te[ve] === Z || te[ve].listener === Z) { - oe = te[ve].listener, le = ve; - break; - } - if (le < 0) return this; - le === 0 ? te.shift() : L(te, le), te.length === 1 && (he[I] = te[0]), he.removeListener && this.emit("removeListener", I, oe || Z); - } - return this; - }, c.prototype.removeAllListeners = function(I) { - var Z, te, he; - if (!(te = this._events)) return this; - if (!te.removeListener) return arguments.length === 0 ? (this._events = i(null), this._eventsCount = 0) : te[I] && (--this._eventsCount == 0 ? this._events = i(null) : delete te[I]), this; - if (arguments.length === 0) { - var le, ve = u(te); - for (he = 0; he < ve.length; ++he) (le = ve[he]) !== "removeListener" && this.removeAllListeners(le); - return this.removeAllListeners("removeListener"), this._events = i(null), this._eventsCount = 0, this; - } - if (typeof (Z = te[I]) == "function") this.removeListener(I, Z); - else if (Z) for (he = Z.length - 1; he >= 0; he--) this.removeListener(I, Z[he]); - return this; - }, c.prototype.listeners = function(I) { - return O(this, I, !0); - }, c.prototype.rawListeners = function(I) { - return O(this, I, !1); - }, c.listenerCount = function(I, Z) { - return typeof I.listenerCount == "function" ? I.listenerCount(Z) : P.call(I, Z); - }, c.prototype.listenerCount = P, c.prototype.eventNames = function() { - return this._eventsCount > 0 ? Reflect.ownKeys(this._events) : []; - }; - }, {}], 28: [function(n, o, p) { - function i(u) { - var a = Array.prototype.slice.call(arguments, 1); - return a.length && (u = u.replace(/(%?)(%([jds]))/g, function(c, l, f, d) { - var E = a.shift(); - switch (d) { - case "s": - E = "" + E; - break; - case "d": - E = Number(E); - break; - case "j": - E = JSON.stringify(E); - } - return l ? (a.unshift(E), c) : E; - })), a.length && (u += " " + a.join(" ")), "" + (u = u.replace(/%{2,2}/g, "%")); - } - o.exports = i; - }, {}], 29: [function(n, o, p) { - var i = n("http"), u = n("url"), a = o.exports; - for (var c in i) i.hasOwnProperty(c) && (a[c] = i[c]); - function l(f) { - if (typeof f == "string" && (f = u.parse(f)), f.protocol || (f.protocol = "https:"), f.protocol !== "https:") throw new Error('Protocol "' + f.protocol + '" not supported. Expected "https:"'); - return f; - } - a.request = function(f, d) { - return f = l(f), i.request.call(this, f, d); - }, a.get = function(f, d) { - return f = l(f), i.get.call(this, f, d); - }; - }, { http: 80, url: 87 }], 30: [function(n, o, p) { - p.read = function(i, u, a, c, l) { - var f, d, E = 8 * l - c - 1, y = (1 << E) - 1, S = y >> 1, T = -7, v = a ? l - 1 : 0, h = a ? -1 : 1, b = i[u + v]; - for (v += h, f = b & (1 << -T) - 1, b >>= -T, T += E; T > 0; f = 256 * f + i[u + v], v += h, T -= 8) ; - for (d = f & (1 << -T) - 1, f >>= -T, T += c; T > 0; d = 256 * d + i[u + v], v += h, T -= 8) ; - if (f === 0) f = 1 - S; - else { - if (f === y) return d ? NaN : 1 / 0 * (b ? -1 : 1); - d += Math.pow(2, c), f -= S; - } - return (b ? -1 : 1) * d * Math.pow(2, f - c); - }, p.write = function(i, u, a, c, l, f) { - var d, E, y, S = 8 * f - l - 1, T = (1 << S) - 1, v = T >> 1, h = l === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, b = c ? 0 : f - 1, w = c ? 1 : -1, _ = u < 0 || u === 0 && 1 / u < 0 ? 1 : 0; - for (u = Math.abs(u), isNaN(u) || u === 1 / 0 ? (E = isNaN(u) ? 1 : 0, d = T) : (d = Math.floor(Math.log(u) / Math.LN2), u * (y = Math.pow(2, -d)) < 1 && (d--, y *= 2), (u += d + v >= 1 ? h / y : h * Math.pow(2, 1 - v)) * y >= 2 && (d++, y /= 2), d + v >= T ? (E = 0, d = T) : d + v >= 1 ? (E = (u * y - 1) * Math.pow(2, l), d += v) : (E = u * Math.pow(2, v - 1) * Math.pow(2, l), d = 0)); l >= 8; i[a + b] = 255 & E, b += w, E /= 256, l -= 8) ; - for (d = d << l | E, S += l; S > 0; i[a + b] = 255 & d, b += w, d /= 256, S -= 8) ; - i[a + b - w] |= 128 * _; - }; - }, {}], 31: [function(n, o, p) { - typeof Object.create == "function" ? o.exports = function(i, u) { - i.super_ = u, i.prototype = Object.create(u.prototype, { constructor: { value: i, enumerable: !1, writable: !0, configurable: !0 } }); - } : o.exports = function(i, u) { - i.super_ = u; - var a = function() { - }; - a.prototype = u.prototype, i.prototype = new a(), i.prototype.constructor = i; - }; - }, {}], 32: [function(n, o, p) { - function i(a) { - return !!a.constructor && typeof a.constructor.isBuffer == "function" && a.constructor.isBuffer(a); - } - function u(a) { - return typeof a.readFloatLE == "function" && typeof a.slice == "function" && i(a.slice(0, 0)); - } - o.exports = function(a) { - return a != null && (i(a) || u(a) || !!a._isBuffer); - }; - }, {}], 33: [function(n, o, p) { - var i = {}.toString; - o.exports = Array.isArray || function(u) { - return i.call(u) == "[object Array]"; - }; - }, {}], 34: [function(n, o, p) { - var i = n("./lib/js-yaml.js"); - o.exports = i; - }, { "./lib/js-yaml.js": 35 }], 35: [function(n, o, p) { - var i = n("./js-yaml/loader"), u = n("./js-yaml/dumper"); - function a(c) { - return function() { - throw new Error("Function " + c + " is deprecated and cannot be used."); - }; - } - o.exports.Type = n("./js-yaml/type"), o.exports.Schema = n("./js-yaml/schema"), o.exports.FAILSAFE_SCHEMA = n("./js-yaml/schema/failsafe"), o.exports.JSON_SCHEMA = n("./js-yaml/schema/json"), o.exports.CORE_SCHEMA = n("./js-yaml/schema/core"), o.exports.DEFAULT_SAFE_SCHEMA = n("./js-yaml/schema/default_safe"), o.exports.DEFAULT_FULL_SCHEMA = n("./js-yaml/schema/default_full"), o.exports.load = i.load, o.exports.loadAll = i.loadAll, o.exports.safeLoad = i.safeLoad, o.exports.safeLoadAll = i.safeLoadAll, o.exports.dump = u.dump, o.exports.safeDump = u.safeDump, o.exports.YAMLException = n("./js-yaml/exception"), o.exports.MINIMAL_SCHEMA = n("./js-yaml/schema/failsafe"), o.exports.SAFE_SCHEMA = n("./js-yaml/schema/default_safe"), o.exports.DEFAULT_SCHEMA = n("./js-yaml/schema/default_full"), o.exports.scan = a("scan"), o.exports.parse = a("parse"), o.exports.compose = a("compose"), o.exports.addConstructor = a("addConstructor"); - }, { "./js-yaml/dumper": 37, "./js-yaml/exception": 38, "./js-yaml/loader": 39, "./js-yaml/schema": 41, "./js-yaml/schema/core": 42, "./js-yaml/schema/default_full": 43, "./js-yaml/schema/default_safe": 44, "./js-yaml/schema/failsafe": 45, "./js-yaml/schema/json": 46, "./js-yaml/type": 47 }], 36: [function(n, o, p) { - function i(d) { - return d == null; - } - function u(d) { - return typeof d == "object" && d !== null; - } - function a(d) { - return Array.isArray(d) ? d : i(d) ? [] : [d]; - } - function c(d, E) { - var y, S, T, v; - if (E) for (y = 0, S = (v = Object.keys(E)).length; y < S; y += 1) d[T = v[y]] = E[T]; - return d; - } - function l(d, E) { - var y, S = ""; - for (y = 0; y < E; y += 1) S += d; - return S; - } - function f(d) { - return d === 0 && Number.NEGATIVE_INFINITY === 1 / d; - } - o.exports.isNothing = i, o.exports.isObject = u, o.exports.toArray = a, o.exports.repeat = l, o.exports.isNegativeZero = f, o.exports.extend = c; - }, {}], 37: [function(n, o, p) { - var i = n("./common"), u = n("./exception"), a = n("./schema/default_full"), c = n("./schema/default_safe"), l = Object.prototype.toString, f = Object.prototype.hasOwnProperty, d = 9, E = 10, y = 32, S = 33, T = 34, v = 35, h = 37, b = 38, w = 39, _ = 42, O = 44, P = 45, L = 58, Y = 62, H = 63, V = 64, B = 91, ne = 93, I = 96, Z = 123, te = 124, he = 125, le = { 0: "\\0", 7: "\\a", 8: "\\b", 9: "\\t", 10: "\\n", 11: "\\v", 12: "\\f", 13: "\\r", 27: "\\e", 34: '\\"', 92: "\\\\", 133: "\\N", 160: "\\_", 8232: "\\L", 8233: "\\P" }, ve = ["y", "Y", "yes", "Yes", "YES", "on", "On", "ON", "n", "N", "no", "No", "NO", "off", "Off", "OFF"]; - function oe(g, k) { - var $, D, X, J, ee, re, ue; - if (k === null) return {}; - for ($ = {}, X = 0, J = (D = Object.keys(k)).length; X < J; X += 1) ee = D[X], re = String(k[ee]), ee.slice(0, 2) === "!!" && (ee = "tag:yaml.org,2002:" + ee.slice(2)), (ue = g.compiledTypeMap.fallback[ee]) && f.call(ue.styleAliases, re) && (re = ue.styleAliases[re]), $[ee] = re; - return $; - } - function fe(g) { - var k, $, D; - if (k = g.toString(16).toUpperCase(), g <= 255) $ = "x", D = 2; - else if (g <= 65535) $ = "u", D = 4; - else { - if (!(g <= 4294967295)) throw new u("code point within a string may not be greater than 0xFFFFFFFF"); - $ = "U", D = 8; - } - return "\\" + $ + i.repeat("0", D - k.length) + k; - } - function j(g) { - this.schema = g.schema || a, this.indent = Math.max(1, g.indent || 2), this.noArrayIndent = g.noArrayIndent || !1, this.skipInvalid = g.skipInvalid || !1, this.flowLevel = i.isNothing(g.flowLevel) ? -1 : g.flowLevel, this.styleMap = oe(this.schema, g.styles || null), this.sortKeys = g.sortKeys || !1, this.lineWidth = g.lineWidth || 80, this.noRefs = g.noRefs || !1, this.noCompatMode = g.noCompatMode || !1, this.condenseFlow = g.condenseFlow || !1, this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null; - } - function ie(g, k) { - for (var $, D = i.repeat(" ", k), X = 0, J = -1, ee = "", re = g.length; X < re; ) (J = g.indexOf(` -`, X)) === -1 ? ($ = g.slice(X), X = re) : ($ = g.slice(X, J + 1), X = J + 1), $.length && $ !== ` -` && (ee += D), ee += $; - return ee; - } - function pe(g, k) { - return ` -` + i.repeat(" ", g.indent * k); - } - function se(g, k) { - var $, D; - for ($ = 0, D = g.implicitTypes.length; $ < D; $ += 1) if (g.implicitTypes[$].resolve(k)) return !0; - return !1; - } - function W(g) { - return g === y || g === d; - } - function G(g) { - return 32 <= g && g <= 126 || 161 <= g && g <= 55295 && g !== 8232 && g !== 8233 || 57344 <= g && g <= 65533 && g !== 65279 || 65536 <= g && g <= 1114111; - } - function ae(g) { - return G(g) && g !== 65279 && g !== O && g !== B && g !== ne && g !== Z && g !== he && g !== L && g !== v; - } - function ge(g) { - return G(g) && g !== 65279 && !W(g) && g !== P && g !== H && g !== L && g !== O && g !== B && g !== ne && g !== Z && g !== he && g !== v && g !== b && g !== _ && g !== S && g !== te && g !== Y && g !== w && g !== T && g !== h && g !== V && g !== I; - } - function Ee(g) { - return /^\n* /.test(g); - } - var ye = 1, Oe = 2, Ae = 3, Te = 4, U = 5; - function q(g, k, $, D, X) { - var J, ee, re = !1, ue = !1, me = D !== -1, we = -1, xe = ge(g.charCodeAt(0)) && !W(g.charCodeAt(g.length - 1)); - if (k) for (J = 0; J < g.length; J++) { - if (!G(ee = g.charCodeAt(J))) return U; - xe = xe && ae(ee); - } - else { - for (J = 0; J < g.length; J++) { - if ((ee = g.charCodeAt(J)) === E) re = !0, me && (ue = ue || J - we - 1 > D && g[we + 1] !== " ", we = J); - else if (!G(ee)) return U; - xe = xe && ae(ee); - } - ue = ue || me && J - we - 1 > D && g[we + 1] !== " "; - } - return re || ue ? $ > 9 && Ee(g) ? U : ue ? Te : Ae : xe && !X(g) ? ye : Oe; - } - function de(g, k, $, D) { - g.dump = (function() { - if (k.length === 0) return "''"; - if (!g.noCompatMode && ve.indexOf(k) !== -1) return "'" + k + "'"; - var X = g.indent * Math.max(1, $), J = g.lineWidth === -1 ? -1 : Math.max(Math.min(g.lineWidth, 40), g.lineWidth - X), ee = D || g.flowLevel > -1 && $ >= g.flowLevel; - switch (q(k, ee, g.indent, J, function(re) { - return se(g, re); - })) { - case ye: - return k; - case Oe: - return "'" + k.replace(/'/g, "''") + "'"; - case Ae: - return "|" + F(k, g.indent) + ce(ie(k, X)); - case Te: - return ">" + F(k, g.indent) + ce(ie(m(k, J), X)); - case U: - return '"' + R(k) + '"'; - default: - throw new u("impossible error: invalid scalar style"); - } - })(); - } - function F(g, k) { - var $ = Ee(g) ? String(k) : "", D = g[g.length - 1] === ` -`; - return $ + (D && (g[g.length - 2] === ` -` || g === ` -`) ? "+" : D ? "" : "-") + ` -`; - } - function ce(g) { - return g[g.length - 1] === ` -` ? g.slice(0, -1) : g; - } - function m(g, k) { - for (var $, D, X, J = /(\n+)([^\n]*)/g, ee = ($ = ($ = g.indexOf(` -`)) !== -1 ? $ : g.length, J.lastIndex = $, A(g.slice(0, $), k)), re = g[0] === ` -` || g[0] === " "; X = J.exec(g); ) { - var ue = X[1], me = X[2]; - D = me[0] === " ", ee += ue + (re || D || me === "" ? "" : ` -`) + A(me, k), re = D; - } - return ee; - } - function A(g, k) { - if (g === "" || g[0] === " ") return g; - for (var $, D, X = / [^ ]/g, J = 0, ee = 0, re = 0, ue = ""; $ = X.exec(g); ) (re = $.index) - J > k && (D = ee > J ? ee : re, ue += ` -` + g.slice(J, D), J = D + 1), ee = re; - return ue += ` -`, g.length - J > k && ee > J ? ue += g.slice(J, ee) + ` -` + g.slice(ee + 1) : ue += g.slice(J), ue.slice(1); - } - function R(g) { - for (var k, $, D, X = "", J = 0; J < g.length; J++) (k = g.charCodeAt(J)) >= 55296 && k <= 56319 && ($ = g.charCodeAt(J + 1)) >= 56320 && $ <= 57343 ? (X += fe(1024 * (k - 55296) + $ - 56320 + 65536), J++) : X += !(D = le[k]) && G(k) ? g[J] : D || fe(k); - return X; - } - function K(g, k, $) { - var D, X, J = "", ee = g.tag; - for (D = 0, X = $.length; D < X; D += 1) e(g, k, $[D], !1, !1) && (D !== 0 && (J += "," + (g.condenseFlow ? "" : " ")), J += g.dump); - g.tag = ee, g.dump = "[" + J + "]"; - } - function Q(g, k, $, D) { - var X, J, ee = "", re = g.tag; - for (X = 0, J = $.length; X < J; X += 1) e(g, k + 1, $[X], !0, !0) && (D && X === 0 || (ee += pe(g, k)), g.dump && E === g.dump.charCodeAt(0) ? ee += "-" : ee += "- ", ee += g.dump); - g.tag = re, g.dump = ee || "[]"; - } - function z(g, k, $) { - var D, X, J, ee, re, ue = "", me = g.tag, we = Object.keys($); - for (D = 0, X = we.length; D < X; D += 1) re = g.condenseFlow ? '"' : "", D !== 0 && (re += ", "), ee = $[J = we[D]], e(g, k, J, !1, !1) && (g.dump.length > 1024 && (re += "? "), re += g.dump + (g.condenseFlow ? '"' : "") + ":" + (g.condenseFlow ? "" : " "), e(g, k, ee, !1, !1) && (ue += re += g.dump)); - g.tag = me, g.dump = "{" + ue + "}"; - } - function be(g, k, $, D) { - var X, J, ee, re, ue, me, we = "", xe = g.tag, _e = Object.keys($); - if (g.sortKeys === !0) _e.sort(); - else if (typeof g.sortKeys == "function") _e.sort(g.sortKeys); - else if (g.sortKeys) throw new u("sortKeys must be a boolean or a function"); - for (X = 0, J = _e.length; X < J; X += 1) me = "", D && X === 0 || (me += pe(g, k)), re = $[ee = _e[X]], e(g, k + 1, ee, !0, !0, !0) && ((ue = g.tag !== null && g.tag !== "?" || g.dump && g.dump.length > 1024) && (g.dump && E === g.dump.charCodeAt(0) ? me += "?" : me += "? "), me += g.dump, ue && (me += pe(g, k)), e(g, k + 1, re, !0, ue) && (g.dump && E === g.dump.charCodeAt(0) ? me += ":" : me += ": ", we += me += g.dump)); - g.tag = xe, g.dump = we || "{}"; - } - function N(g, k, $) { - var D, X, J, ee, re, ue; - for (J = 0, ee = (X = $ ? g.explicitTypes : g.implicitTypes).length; J < ee; J += 1) if (((re = X[J]).instanceOf || re.predicate) && (!re.instanceOf || typeof k == "object" && k instanceof re.instanceOf) && (!re.predicate || re.predicate(k))) { - if (g.tag = $ ? re.tag : "?", re.represent) { - if (ue = g.styleMap[re.tag] || re.defaultStyle, l.call(re.represent) === "[object Function]") D = re.represent(k, ue); - else { - if (!f.call(re.represent, ue)) throw new u("!<" + re.tag + '> tag resolver accepts not "' + ue + '" style'); - D = re.represent[ue](k, ue); - } - g.dump = D; - } - return !0; - } - return !1; - } - function e(g, k, $, D, X, J) { - g.tag = null, g.dump = $, N(g, $, !1) || N(g, $, !0); - var ee = l.call(g.dump); - D && (D = g.flowLevel < 0 || g.flowLevel > k); - var re, ue, me = ee === "[object Object]" || ee === "[object Array]"; - if (me && (ue = (re = g.duplicates.indexOf($)) !== -1), (g.tag !== null && g.tag !== "?" || ue || g.indent !== 2 && k > 0) && (X = !1), ue && g.usedDuplicates[re]) g.dump = "*ref_" + re; - else { - if (me && ue && !g.usedDuplicates[re] && (g.usedDuplicates[re] = !0), ee === "[object Object]") D && Object.keys(g.dump).length !== 0 ? (be(g, k, g.dump, X), ue && (g.dump = "&ref_" + re + g.dump)) : (z(g, k, g.dump), ue && (g.dump = "&ref_" + re + " " + g.dump)); - else if (ee === "[object Array]") { - var we = g.noArrayIndent ? k - 1 : k; - D && g.dump.length !== 0 ? (Q(g, we, g.dump, X), ue && (g.dump = "&ref_" + re + g.dump)) : (K(g, we, g.dump), ue && (g.dump = "&ref_" + re + " " + g.dump)); - } else { - if (ee !== "[object String]") { - if (g.skipInvalid) return !1; - throw new u("unacceptable kind of an object to dump " + ee); - } - g.tag !== "?" && de(g, g.dump, k, J); - } - g.tag !== null && g.tag !== "?" && (g.dump = "!<" + g.tag + "> " + g.dump); - } - return !0; - } - function t(g, k) { - var $, D, X = [], J = []; - for (x(g, X, J), $ = 0, D = J.length; $ < D; $ += 1) k.duplicates.push(X[J[$]]); - k.usedDuplicates = new Array(D); - } - function x(g, k, $) { - var D, X, J; - if (g !== null && typeof g == "object") if ((X = k.indexOf(g)) !== -1) $.indexOf(X) === -1 && $.push(X); - else if (k.push(g), Array.isArray(g)) for (X = 0, J = g.length; X < J; X += 1) x(g[X], k, $); - else for (X = 0, J = (D = Object.keys(g)).length; X < J; X += 1) x(g[D[X]], k, $); - } - function C(g, k) { - var $ = new j(k = k || {}); - return $.noRefs || t(g, $), e($, 0, g, !0, !0) ? $.dump + ` -` : ""; - } - function M(g, k) { - return C(g, i.extend({ schema: c }, k)); - } - o.exports.dump = C, o.exports.safeDump = M; - }, { "./common": 36, "./exception": 38, "./schema/default_full": 43, "./schema/default_safe": 44 }], 38: [function(n, o, p) { - function i(u, a) { - Error.call(this), this.name = "YAMLException", this.reason = u, this.mark = a, this.message = (this.reason || "(unknown reason)") + (this.mark ? " " + this.mark.toString() : ""), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack || ""; - } - i.prototype = Object.create(Error.prototype), i.prototype.constructor = i, i.prototype.toString = function(u) { - var a = this.name + ": "; - return a += this.reason || "(unknown reason)", !u && this.mark && (a += " " + this.mark.toString()), a; - }, o.exports = i; - }, {}], 39: [function(n, o, p) { - var i = n("./common"), u = n("./exception"), a = n("./mark"), c = n("./schema/default_safe"), l = n("./schema/default_full"), f = Object.prototype.hasOwnProperty, d = 1, E = 2, y = 3, S = 4, T = 1, v = 2, h = 3, b = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, w = /[\x85\u2028\u2029]/, _ = /[,\[\]\{\}]/, O = /^(?:!|!!|![a-z\-]+!)$/i, P = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i; - function L(t) { - return t === 10 || t === 13; - } - function Y(t) { - return t === 9 || t === 32; - } - function H(t) { - return t === 9 || t === 32 || t === 10 || t === 13; - } - function V(t) { - return t === 44 || t === 91 || t === 93 || t === 123 || t === 125; - } - function B(t) { - var x; - return 48 <= t && t <= 57 ? t - 48 : 97 <= (x = 32 | t) && x <= 102 ? x - 97 + 10 : -1; - } - function ne(t) { - return t === 120 ? 2 : t === 117 ? 4 : t === 85 ? 8 : 0; - } - function I(t) { - return 48 <= t && t <= 57 ? t - 48 : -1; - } - function Z(t) { - return t === 48 ? "\0" : t === 97 ? "\x07" : t === 98 ? "\b" : t === 116 || t === 9 ? " " : t === 110 ? ` -` : t === 118 ? "\v" : t === 102 ? "\f" : t === 114 ? "\r" : t === 101 ? "\x1B" : t === 32 ? " " : t === 34 ? '"' : t === 47 ? "/" : t === 92 ? "\\" : t === 78 ? "…" : t === 95 ? " " : t === 76 ? "\u2028" : t === 80 ? "\u2029" : ""; - } - function te(t) { - return t <= 65535 ? String.fromCharCode(t) : String.fromCharCode(55296 + (t - 65536 >> 10), 56320 + (t - 65536 & 1023)); - } - for (var he = new Array(256), le = new Array(256), ve = 0; ve < 256; ve++) he[ve] = Z(ve) ? 1 : 0, le[ve] = Z(ve); - function oe(t, x) { - this.input = t, this.filename = x.filename || null, this.schema = x.schema || l, this.onWarning = x.onWarning || null, this.legacy = x.legacy || !1, this.json = x.json || !1, this.listener = x.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.documents = []; - } - function fe(t, x) { - return new u(x, new a(t.filename, t.input, t.position, t.line, t.position - t.lineStart)); - } - function j(t, x) { - throw fe(t, x); - } - function ie(t, x) { - t.onWarning && t.onWarning.call(null, fe(t, x)); - } - var pe = { YAML: function(t, x, C) { - var M, g, k; - t.version !== null && j(t, "duplication of %YAML directive"), C.length !== 1 && j(t, "YAML directive accepts exactly one argument"), (M = /^([0-9]+)\.([0-9]+)$/.exec(C[0])) === null && j(t, "ill-formed argument of the YAML directive"), g = parseInt(M[1], 10), k = parseInt(M[2], 10), g !== 1 && j(t, "unacceptable YAML version of the document"), t.version = C[0], t.checkLineBreaks = k < 2, k !== 1 && k !== 2 && ie(t, "unsupported YAML version of the document"); - }, TAG: function(t, x, C) { - var M, g; - C.length !== 2 && j(t, "TAG directive accepts exactly two arguments"), M = C[0], g = C[1], O.test(M) || j(t, "ill-formed tag handle (first argument) of the TAG directive"), f.call(t.tagMap, M) && j(t, 'there is a previously declared suffix for "' + M + '" tag handle'), P.test(g) || j(t, "ill-formed tag prefix (second argument) of the TAG directive"), t.tagMap[M] = g; - } }; - function se(t, x, C, M) { - var g, k, $, D; - if (x < C) { - if (D = t.input.slice(x, C), M) for (g = 0, k = D.length; g < k; g += 1) ($ = D.charCodeAt(g)) === 9 || 32 <= $ && $ <= 1114111 || j(t, "expected valid JSON character"); - else b.test(D) && j(t, "the stream contains non-printable characters"); - t.result += D; - } - } - function W(t, x, C, M) { - var g, k, $, D; - for (i.isObject(C) || j(t, "cannot merge mappings; the provided source object is unacceptable"), $ = 0, D = (g = Object.keys(C)).length; $ < D; $ += 1) k = g[$], f.call(x, k) || (x[k] = C[k], M[k] = !0); - } - function G(t, x, C, M, g, k, $, D) { - var X, J; - if (g = String(g), x === null && (x = {}), M === "tag:yaml.org,2002:merge") if (Array.isArray(k)) for (X = 0, J = k.length; X < J; X += 1) W(t, x, k[X], C); - else W(t, x, k, C); - else t.json || f.call(C, g) || !f.call(x, g) || (t.line = $ || t.line, t.position = D || t.position, j(t, "duplicated mapping key")), x[g] = k, delete C[g]; - return x; - } - function ae(t) { - var x; - (x = t.input.charCodeAt(t.position)) === 10 ? t.position++ : x === 13 ? (t.position++, t.input.charCodeAt(t.position) === 10 && t.position++) : j(t, "a line break is expected"), t.line += 1, t.lineStart = t.position; - } - function ge(t, x, C) { - for (var M = 0, g = t.input.charCodeAt(t.position); g !== 0; ) { - for (; Y(g); ) g = t.input.charCodeAt(++t.position); - if (x && g === 35) do - g = t.input.charCodeAt(++t.position); - while (g !== 10 && g !== 13 && g !== 0); - if (!L(g)) break; - for (ae(t), g = t.input.charCodeAt(t.position), M++, t.lineIndent = 0; g === 32; ) t.lineIndent++, g = t.input.charCodeAt(++t.position); - } - return C !== -1 && M !== 0 && t.lineIndent < C && ie(t, "deficient indentation"), M; - } - function Ee(t) { - var x, C = t.position; - return !((x = t.input.charCodeAt(C)) !== 45 && x !== 46 || x !== t.input.charCodeAt(C + 1) || x !== t.input.charCodeAt(C + 2) || (C += 3, (x = t.input.charCodeAt(C)) !== 0 && !H(x))); - } - function ye(t, x) { - x === 1 ? t.result += " " : x > 1 && (t.result += i.repeat(` -`, x - 1)); - } - function Oe(t, x, C) { - var M, g, k, $, D, X, J, ee, re = t.kind, ue = t.result; - if (H(ee = t.input.charCodeAt(t.position)) || V(ee) || ee === 35 || ee === 38 || ee === 42 || ee === 33 || ee === 124 || ee === 62 || ee === 39 || ee === 34 || ee === 37 || ee === 64 || ee === 96 || (ee === 63 || ee === 45) && (H(M = t.input.charCodeAt(t.position + 1)) || C && V(M))) return !1; - for (t.kind = "scalar", t.result = "", g = k = t.position, $ = !1; ee !== 0; ) { - if (ee === 58) { - if (H(M = t.input.charCodeAt(t.position + 1)) || C && V(M)) break; - } else if (ee === 35) { - if (H(t.input.charCodeAt(t.position - 1))) break; - } else { - if (t.position === t.lineStart && Ee(t) || C && V(ee)) break; - if (L(ee)) { - if (D = t.line, X = t.lineStart, J = t.lineIndent, ge(t, !1, -1), t.lineIndent >= x) { - $ = !0, ee = t.input.charCodeAt(t.position); - continue; - } - t.position = k, t.line = D, t.lineStart = X, t.lineIndent = J; - break; - } - } - $ && (se(t, g, k, !1), ye(t, t.line - D), g = k = t.position, $ = !1), Y(ee) || (k = t.position + 1), ee = t.input.charCodeAt(++t.position); - } - return se(t, g, k, !1), !!t.result || (t.kind = re, t.result = ue, !1); - } - function Ae(t, x) { - var C, M, g; - if ((C = t.input.charCodeAt(t.position)) !== 39) return !1; - for (t.kind = "scalar", t.result = "", t.position++, M = g = t.position; (C = t.input.charCodeAt(t.position)) !== 0; ) if (C === 39) { - if (se(t, M, t.position, !0), (C = t.input.charCodeAt(++t.position)) !== 39) return !0; - M = t.position, t.position++, g = t.position; - } else L(C) ? (se(t, M, g, !0), ye(t, ge(t, !1, x)), M = g = t.position) : t.position === t.lineStart && Ee(t) ? j(t, "unexpected end of the document within a single quoted scalar") : (t.position++, g = t.position); - j(t, "unexpected end of the stream within a single quoted scalar"); - } - function Te(t, x) { - var C, M, g, k, $, D; - if ((D = t.input.charCodeAt(t.position)) !== 34) return !1; - for (t.kind = "scalar", t.result = "", t.position++, C = M = t.position; (D = t.input.charCodeAt(t.position)) !== 0; ) { - if (D === 34) return se(t, C, t.position, !0), t.position++, !0; - if (D === 92) { - if (se(t, C, t.position, !0), L(D = t.input.charCodeAt(++t.position))) ge(t, !1, x); - else if (D < 256 && he[D]) t.result += le[D], t.position++; - else if (($ = ne(D)) > 0) { - for (g = $, k = 0; g > 0; g--) ($ = B(D = t.input.charCodeAt(++t.position))) >= 0 ? k = (k << 4) + $ : j(t, "expected hexadecimal character"); - t.result += te(k), t.position++; - } else j(t, "unknown escape sequence"); - C = M = t.position; - } else L(D) ? (se(t, C, M, !0), ye(t, ge(t, !1, x)), C = M = t.position) : t.position === t.lineStart && Ee(t) ? j(t, "unexpected end of the document within a double quoted scalar") : (t.position++, M = t.position); - } - j(t, "unexpected end of the stream within a double quoted scalar"); - } - function U(t, x) { - var C, M, g, k, $, D, X, J, ee, re, ue = !0, me = t.tag, we = t.anchor, xe = {}; - if ((re = t.input.charCodeAt(t.position)) === 91) g = 93, D = !1, M = []; - else { - if (re !== 123) return !1; - g = 125, D = !0, M = {}; - } - for (t.anchor !== null && (t.anchorMap[t.anchor] = M), re = t.input.charCodeAt(++t.position); re !== 0; ) { - if (ge(t, !0, x), (re = t.input.charCodeAt(t.position)) === g) return t.position++, t.tag = me, t.anchor = we, t.kind = D ? "mapping" : "sequence", t.result = M, !0; - ue || j(t, "missed comma between flow collection entries"), ee = null, k = $ = !1, re === 63 && H(t.input.charCodeAt(t.position + 1)) && (k = $ = !0, t.position++, ge(t, !0, x)), C = t.line, R(t, x, d, !1, !0), J = t.tag, X = t.result, ge(t, !0, x), re = t.input.charCodeAt(t.position), !$ && t.line !== C || re !== 58 || (k = !0, re = t.input.charCodeAt(++t.position), ge(t, !0, x), R(t, x, d, !1, !0), ee = t.result), D ? G(t, M, xe, J, X, ee) : k ? M.push(G(t, null, xe, J, X, ee)) : M.push(X), ge(t, !0, x), (re = t.input.charCodeAt(t.position)) === 44 ? (ue = !0, re = t.input.charCodeAt(++t.position)) : ue = !1; - } - j(t, "unexpected end of the stream within a flow collection"); - } - function q(t, x) { - var C, M, g, k, $ = T, D = !1, X = !1, J = x, ee = 0, re = !1; - if ((k = t.input.charCodeAt(t.position)) === 124) M = !1; - else { - if (k !== 62) return !1; - M = !0; - } - for (t.kind = "scalar", t.result = ""; k !== 0; ) if ((k = t.input.charCodeAt(++t.position)) === 43 || k === 45) T === $ ? $ = k === 43 ? h : v : j(t, "repeat of a chomping mode identifier"); - else { - if (!((g = I(k)) >= 0)) break; - g === 0 ? j(t, "bad explicit indentation width of a block scalar; it cannot be less than one") : X ? j(t, "repeat of an indentation width identifier") : (J = x + g - 1, X = !0); - } - if (Y(k)) { - do - k = t.input.charCodeAt(++t.position); - while (Y(k)); - if (k === 35) do - k = t.input.charCodeAt(++t.position); - while (!L(k) && k !== 0); - } - for (; k !== 0; ) { - for (ae(t), t.lineIndent = 0, k = t.input.charCodeAt(t.position); (!X || t.lineIndent < J) && k === 32; ) t.lineIndent++, k = t.input.charCodeAt(++t.position); - if (!X && t.lineIndent > J && (J = t.lineIndent), L(k)) ee++; - else { - if (t.lineIndent < J) { - $ === h ? t.result += i.repeat(` -`, D ? 1 + ee : ee) : $ === T && D && (t.result += ` -`); - break; - } - for (M ? Y(k) ? (re = !0, t.result += i.repeat(` -`, D ? 1 + ee : ee)) : re ? (re = !1, t.result += i.repeat(` -`, ee + 1)) : ee === 0 ? D && (t.result += " ") : t.result += i.repeat(` -`, ee) : t.result += i.repeat(` -`, D ? 1 + ee : ee), D = !0, X = !0, ee = 0, C = t.position; !L(k) && k !== 0; ) k = t.input.charCodeAt(++t.position); - se(t, C, t.position, !1); - } - } - return !0; - } - function de(t, x) { - var C, M, g = t.tag, k = t.anchor, $ = [], D = !1; - for (t.anchor !== null && (t.anchorMap[t.anchor] = $), M = t.input.charCodeAt(t.position); M !== 0 && M === 45 && H(t.input.charCodeAt(t.position + 1)); ) if (D = !0, t.position++, ge(t, !0, -1) && t.lineIndent <= x) $.push(null), M = t.input.charCodeAt(t.position); - else if (C = t.line, R(t, x, y, !1, !0), $.push(t.result), ge(t, !0, -1), M = t.input.charCodeAt(t.position), (t.line === C || t.lineIndent > x) && M !== 0) j(t, "bad indentation of a sequence entry"); - else if (t.lineIndent < x) break; - return !!D && (t.tag = g, t.anchor = k, t.kind = "sequence", t.result = $, !0); - } - function F(t, x, C) { - var M, g, k, $, D, X = t.tag, J = t.anchor, ee = {}, re = {}, ue = null, me = null, we = null, xe = !1, _e = !1; - for (t.anchor !== null && (t.anchorMap[t.anchor] = ee), D = t.input.charCodeAt(t.position); D !== 0; ) { - if (M = t.input.charCodeAt(t.position + 1), k = t.line, $ = t.position, D !== 63 && D !== 58 || !H(M)) { - if (!R(t, C, E, !1, !0)) break; - if (t.line === k) { - for (D = t.input.charCodeAt(t.position); Y(D); ) D = t.input.charCodeAt(++t.position); - if (D === 58) H(D = t.input.charCodeAt(++t.position)) || j(t, "a whitespace character is expected after the key-value separator within a block mapping"), xe && (G(t, ee, re, ue, me, null), ue = me = we = null), _e = !0, xe = !1, g = !1, ue = t.tag, me = t.result; - else { - if (!_e) return t.tag = X, t.anchor = J, !0; - j(t, "can not read an implicit mapping pair; a colon is missed"); - } - } else { - if (!_e) return t.tag = X, t.anchor = J, !0; - j(t, "can not read a block mapping entry; a multiline key may not be an implicit key"); - } - } else D === 63 ? (xe && (G(t, ee, re, ue, me, null), ue = me = we = null), _e = !0, xe = !0, g = !0) : xe ? (xe = !1, g = !0) : j(t, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), t.position += 1, D = M; - if ((t.line === k || t.lineIndent > x) && (R(t, x, S, !0, g) && (xe ? me = t.result : we = t.result), xe || (G(t, ee, re, ue, me, we, k, $), ue = me = we = null), ge(t, !0, -1), D = t.input.charCodeAt(t.position)), t.lineIndent > x && D !== 0) j(t, "bad indentation of a mapping entry"); - else if (t.lineIndent < x) break; - } - return xe && G(t, ee, re, ue, me, null), _e && (t.tag = X, t.anchor = J, t.kind = "mapping", t.result = ee), _e; - } - function ce(t) { - var x, C, M, g, k = !1, $ = !1; - if ((g = t.input.charCodeAt(t.position)) !== 33) return !1; - if (t.tag !== null && j(t, "duplication of a tag property"), (g = t.input.charCodeAt(++t.position)) === 60 ? (k = !0, g = t.input.charCodeAt(++t.position)) : g === 33 ? ($ = !0, C = "!!", g = t.input.charCodeAt(++t.position)) : C = "!", x = t.position, k) { - do - g = t.input.charCodeAt(++t.position); - while (g !== 0 && g !== 62); - t.position < t.length ? (M = t.input.slice(x, t.position), g = t.input.charCodeAt(++t.position)) : j(t, "unexpected end of the stream within a verbatim tag"); - } else { - for (; g !== 0 && !H(g); ) g === 33 && ($ ? j(t, "tag suffix cannot contain exclamation marks") : (C = t.input.slice(x - 1, t.position + 1), O.test(C) || j(t, "named tag handle cannot contain such characters"), $ = !0, x = t.position + 1)), g = t.input.charCodeAt(++t.position); - M = t.input.slice(x, t.position), _.test(M) && j(t, "tag suffix cannot contain flow indicator characters"); - } - return M && !P.test(M) && j(t, "tag name cannot contain such characters: " + M), k ? t.tag = M : f.call(t.tagMap, C) ? t.tag = t.tagMap[C] + M : C === "!" ? t.tag = "!" + M : C === "!!" ? t.tag = "tag:yaml.org,2002:" + M : j(t, 'undeclared tag handle "' + C + '"'), !0; - } - function m(t) { - var x, C; - if ((C = t.input.charCodeAt(t.position)) !== 38) return !1; - for (t.anchor !== null && j(t, "duplication of an anchor property"), C = t.input.charCodeAt(++t.position), x = t.position; C !== 0 && !H(C) && !V(C); ) C = t.input.charCodeAt(++t.position); - return t.position === x && j(t, "name of an anchor node must contain at least one character"), t.anchor = t.input.slice(x, t.position), !0; - } - function A(t) { - var x, C, M; - if ((M = t.input.charCodeAt(t.position)) !== 42) return !1; - for (M = t.input.charCodeAt(++t.position), x = t.position; M !== 0 && !H(M) && !V(M); ) M = t.input.charCodeAt(++t.position); - return t.position === x && j(t, "name of an alias node must contain at least one character"), C = t.input.slice(x, t.position), t.anchorMap.hasOwnProperty(C) || j(t, 'unidentified alias "' + C + '"'), t.result = t.anchorMap[C], ge(t, !0, -1), !0; - } - function R(t, x, C, M, g) { - var k, $, D, X, J, ee, re, ue, me = 1, we = !1, xe = !1; - if (t.listener !== null && t.listener("open", t), t.tag = null, t.anchor = null, t.kind = null, t.result = null, k = $ = D = S === C || y === C, M && ge(t, !0, -1) && (we = !0, t.lineIndent > x ? me = 1 : t.lineIndent === x ? me = 0 : t.lineIndent < x && (me = -1)), me === 1) for (; ce(t) || m(t); ) ge(t, !0, -1) ? (we = !0, D = k, t.lineIndent > x ? me = 1 : t.lineIndent === x ? me = 0 : t.lineIndent < x && (me = -1)) : D = !1; - if (D && (D = we || g), me !== 1 && S !== C || (re = d === C || E === C ? x : x + 1, ue = t.position - t.lineStart, me === 1 ? D && (de(t, ue) || F(t, ue, re)) || U(t, re) ? xe = !0 : ($ && q(t, re) || Ae(t, re) || Te(t, re) ? xe = !0 : A(t) ? (xe = !0, t.tag === null && t.anchor === null || j(t, "alias node should not have any properties")) : Oe(t, re, d === C) && (xe = !0, t.tag === null && (t.tag = "?")), t.anchor !== null && (t.anchorMap[t.anchor] = t.result)) : me === 0 && (xe = D && de(t, ue))), t.tag !== null && t.tag !== "!") if (t.tag === "?") { - for (X = 0, J = t.implicitTypes.length; X < J; X += 1) if ((ee = t.implicitTypes[X]).resolve(t.result)) { - t.result = ee.construct(t.result), t.tag = ee.tag, t.anchor !== null && (t.anchorMap[t.anchor] = t.result); - break; - } - } else f.call(t.typeMap[t.kind || "fallback"], t.tag) ? (ee = t.typeMap[t.kind || "fallback"][t.tag], t.result !== null && ee.kind !== t.kind && j(t, "unacceptable node kind for !<" + t.tag + '> tag; it should be "' + ee.kind + '", not "' + t.kind + '"'), ee.resolve(t.result) ? (t.result = ee.construct(t.result), t.anchor !== null && (t.anchorMap[t.anchor] = t.result)) : j(t, "cannot resolve a node with !<" + t.tag + "> explicit tag")) : j(t, "unknown tag !<" + t.tag + ">"); - return t.listener !== null && t.listener("close", t), t.tag !== null || t.anchor !== null || xe; - } - function K(t) { - var x, C, M, g, k = t.position, $ = !1; - for (t.version = null, t.checkLineBreaks = t.legacy, t.tagMap = {}, t.anchorMap = {}; (g = t.input.charCodeAt(t.position)) !== 0 && (ge(t, !0, -1), g = t.input.charCodeAt(t.position), !(t.lineIndent > 0 || g !== 37)); ) { - for ($ = !0, g = t.input.charCodeAt(++t.position), x = t.position; g !== 0 && !H(g); ) g = t.input.charCodeAt(++t.position); - for (M = [], (C = t.input.slice(x, t.position)).length < 1 && j(t, "directive name must not be less than one character in length"); g !== 0; ) { - for (; Y(g); ) g = t.input.charCodeAt(++t.position); - if (g === 35) { - do - g = t.input.charCodeAt(++t.position); - while (g !== 0 && !L(g)); - break; - } - if (L(g)) break; - for (x = t.position; g !== 0 && !H(g); ) g = t.input.charCodeAt(++t.position); - M.push(t.input.slice(x, t.position)); - } - g !== 0 && ae(t), f.call(pe, C) ? pe[C](t, C, M) : ie(t, 'unknown document directive "' + C + '"'); - } - ge(t, !0, -1), t.lineIndent === 0 && t.input.charCodeAt(t.position) === 45 && t.input.charCodeAt(t.position + 1) === 45 && t.input.charCodeAt(t.position + 2) === 45 ? (t.position += 3, ge(t, !0, -1)) : $ && j(t, "directives end mark is expected"), R(t, t.lineIndent - 1, S, !1, !0), ge(t, !0, -1), t.checkLineBreaks && w.test(t.input.slice(k, t.position)) && ie(t, "non-ASCII line breaks are interpreted as content"), t.documents.push(t.result), t.position === t.lineStart && Ee(t) ? t.input.charCodeAt(t.position) === 46 && (t.position += 3, ge(t, !0, -1)) : t.position < t.length - 1 && j(t, "end of the stream or a document separator is expected"); - } - function Q(t, x) { - x = x || {}, (t = String(t)).length !== 0 && (t.charCodeAt(t.length - 1) !== 10 && t.charCodeAt(t.length - 1) !== 13 && (t += ` -`), t.charCodeAt(0) === 65279 && (t = t.slice(1))); - var C = new oe(t, x); - for (C.input += "\0"; C.input.charCodeAt(C.position) === 32; ) C.lineIndent += 1, C.position += 1; - for (; C.position < C.length - 1; ) K(C); - return C.documents; - } - function z(t, x, C) { - var M, g, k = Q(t, C); - if (typeof x != "function") return k; - for (M = 0, g = k.length; M < g; M += 1) x(k[M]); - } - function be(t, x) { - var C = Q(t, x); - if (C.length !== 0) { - if (C.length === 1) return C[0]; - throw new u("expected a single document in the stream, but found more"); - } - } - function N(t, x, C) { - if (typeof x != "function") return z(t, i.extend({ schema: c }, C)); - z(t, x, i.extend({ schema: c }, C)); - } - function e(t, x) { - return be(t, i.extend({ schema: c }, x)); - } - o.exports.loadAll = z, o.exports.load = be, o.exports.safeLoadAll = N, o.exports.safeLoad = e; - }, { "./common": 36, "./exception": 38, "./mark": 40, "./schema/default_full": 43, "./schema/default_safe": 44 }], 40: [function(n, o, p) { - var i = n("./common"); - function u(a, c, l, f, d) { - this.name = a, this.buffer = c, this.position = l, this.line = f, this.column = d; - } - u.prototype.getSnippet = function(a, c) { - var l, f, d, E, y; - if (!this.buffer) return null; - for (a = a || 4, c = c || 75, l = "", f = this.position; f > 0 && `\0\r -…\u2028\u2029`.indexOf(this.buffer.charAt(f - 1)) === -1; ) if (f -= 1, this.position - f > c / 2 - 1) { - l = " ... ", f += 5; - break; - } - for (d = "", E = this.position; E < this.buffer.length && `\0\r -…\u2028\u2029`.indexOf(this.buffer.charAt(E)) === -1; ) if ((E += 1) - this.position > c / 2 - 1) { - d = " ... ", E -= 5; - break; - } - return y = this.buffer.slice(f, E), i.repeat(" ", a) + l + y + d + ` -` + i.repeat(" ", a + this.position - f + l.length) + "^"; - }, u.prototype.toString = function(a) { - var c, l = ""; - return this.name && (l += 'in "' + this.name + '" '), l += "at line " + (this.line + 1) + ", column " + (this.column + 1), a || (c = this.getSnippet()) && (l += `: -` + c), l; - }, o.exports = u; - }, { "./common": 36 }], 41: [function(n, o, p) { - var i = n("./common"), u = n("./exception"), a = n("./type"); - function c(d, E, y) { - var S = []; - return d.include.forEach(function(T) { - y = c(T, E, y); - }), d[E].forEach(function(T) { - y.forEach(function(v, h) { - v.tag === T.tag && v.kind === T.kind && S.push(h); - }), y.push(T); - }), y.filter(function(T, v) { - return S.indexOf(v) === -1; - }); - } - function l() { - var d, E, y = { scalar: {}, sequence: {}, mapping: {}, fallback: {} }; - function S(T) { - y[T.kind][T.tag] = y.fallback[T.tag] = T; - } - for (d = 0, E = arguments.length; d < E; d += 1) arguments[d].forEach(S); - return y; - } - function f(d) { - this.include = d.include || [], this.implicit = d.implicit || [], this.explicit = d.explicit || [], this.implicit.forEach(function(E) { - if (E.loadKind && E.loadKind !== "scalar") throw new u("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported."); - }), this.compiledImplicit = c(this, "implicit", []), this.compiledExplicit = c(this, "explicit", []), this.compiledTypeMap = l(this.compiledImplicit, this.compiledExplicit); - } - f.DEFAULT = null, f.create = function() { - var d, E; - switch (arguments.length) { - case 1: - d = f.DEFAULT, E = arguments[0]; - break; - case 2: - d = arguments[0], E = arguments[1]; - break; - default: - throw new u("Wrong number of arguments for Schema.create function"); - } - if (d = i.toArray(d), E = i.toArray(E), !d.every(function(y) { - return y instanceof f; - })) throw new u("Specified list of super schemas (or a single Schema object) contains a non-Schema object."); - if (!E.every(function(y) { - return y instanceof a; - })) throw new u("Specified list of YAML types (or a single Type object) contains a non-Type object."); - return new f({ include: d, explicit: E }); - }, o.exports = f; - }, { "./common": 36, "./exception": 38, "./type": 47 }], 42: [function(n, o, p) { - var i = n("../schema"); - o.exports = new i({ include: [n("./json")] }); - }, { "../schema": 41, "./json": 46 }], 43: [function(n, o, p) { - var i = n("../schema"); - o.exports = i.DEFAULT = new i({ include: [n("./default_safe")], explicit: [n("../type/js/undefined"), n("../type/js/regexp"), n("../type/js/function")] }); - }, { "../schema": 41, "../type/js/function": 52, "../type/js/regexp": 53, "../type/js/undefined": 54, "./default_safe": 44 }], 44: [function(n, o, p) { - var i = n("../schema"); - o.exports = new i({ include: [n("./core")], implicit: [n("../type/timestamp"), n("../type/merge")], explicit: [n("../type/binary"), n("../type/omap"), n("../type/pairs"), n("../type/set")] }); - }, { "../schema": 41, "../type/binary": 48, "../type/merge": 56, "../type/omap": 58, "../type/pairs": 59, "../type/set": 61, "../type/timestamp": 63, "./core": 42 }], 45: [function(n, o, p) { - var i = n("../schema"); - o.exports = new i({ explicit: [n("../type/str"), n("../type/seq"), n("../type/map")] }); - }, { "../schema": 41, "../type/map": 55, "../type/seq": 60, "../type/str": 62 }], 46: [function(n, o, p) { - var i = n("../schema"); - o.exports = new i({ include: [n("./failsafe")], implicit: [n("../type/null"), n("../type/bool"), n("../type/int"), n("../type/float")] }); - }, { "../schema": 41, "../type/bool": 49, "../type/float": 50, "../type/int": 51, "../type/null": 57, "./failsafe": 45 }], 47: [function(n, o, p) { - var i = n("./exception"), u = ["kind", "resolve", "construct", "instanceOf", "predicate", "represent", "defaultStyle", "styleAliases"], a = ["scalar", "sequence", "mapping"]; - function c(f) { - var d = {}; - return f !== null && Object.keys(f).forEach(function(E) { - f[E].forEach(function(y) { - d[String(y)] = E; - }); - }), d; - } - function l(f, d) { - if (d = d || {}, Object.keys(d).forEach(function(E) { - if (u.indexOf(E) === -1) throw new i('Unknown option "' + E + '" is met in definition of "' + f + '" YAML type.'); - }), this.tag = f, this.kind = d.kind || null, this.resolve = d.resolve || function() { - return !0; - }, this.construct = d.construct || function(E) { - return E; - }, this.instanceOf = d.instanceOf || null, this.predicate = d.predicate || null, this.represent = d.represent || null, this.defaultStyle = d.defaultStyle || null, this.styleAliases = c(d.styleAliases || null), a.indexOf(this.kind) === -1) throw new i('Unknown kind "' + this.kind + '" is specified for "' + f + '" YAML type.'); - } - o.exports = l; - }, { "./exception": 38 }], 48: [function(n, o, p) { - var i; - try { - var u = n; - i = u("buffer").Buffer; - } catch { - } - var a = n("../type"), c = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= -\r`; - function l(y) { - if (y === null) return !1; - var S, T, v = 0, h = y.length, b = c; - for (T = 0; T < h; T++) if (!((S = b.indexOf(y.charAt(T))) > 64)) { - if (S < 0) return !1; - v += 6; - } - return v % 8 == 0; - } - function f(y) { - var S, T, v = y.replace(/[\r\n=]/g, ""), h = v.length, b = c, w = 0, _ = []; - for (S = 0; S < h; S++) S % 4 == 0 && S && (_.push(w >> 16 & 255), _.push(w >> 8 & 255), _.push(255 & w)), w = w << 6 | b.indexOf(v.charAt(S)); - return (T = h % 4 * 6) === 0 ? (_.push(w >> 16 & 255), _.push(w >> 8 & 255), _.push(255 & w)) : T === 18 ? (_.push(w >> 10 & 255), _.push(w >> 2 & 255)) : T === 12 && _.push(w >> 4 & 255), i ? i.from ? i.from(_) : new i(_) : _; - } - function d(y) { - var S, T, v = "", h = 0, b = y.length, w = c; - for (S = 0; S < b; S++) S % 3 == 0 && S && (v += w[h >> 18 & 63], v += w[h >> 12 & 63], v += w[h >> 6 & 63], v += w[63 & h]), h = (h << 8) + y[S]; - return (T = b % 3) === 0 ? (v += w[h >> 18 & 63], v += w[h >> 12 & 63], v += w[h >> 6 & 63], v += w[63 & h]) : T === 2 ? (v += w[h >> 10 & 63], v += w[h >> 4 & 63], v += w[h << 2 & 63], v += w[64]) : T === 1 && (v += w[h >> 2 & 63], v += w[h << 4 & 63], v += w[64], v += w[64]), v; - } - function E(y) { - return i && i.isBuffer(y); - } - o.exports = new a("tag:yaml.org,2002:binary", { kind: "scalar", resolve: l, construct: f, predicate: E, represent: d }); - }, { "../type": 47 }], 49: [function(n, o, p) { - var i = n("../type"); - function u(l) { - if (l === null) return !1; - var f = l.length; - return f === 4 && (l === "true" || l === "True" || l === "TRUE") || f === 5 && (l === "false" || l === "False" || l === "FALSE"); - } - function a(l) { - return l === "true" || l === "True" || l === "TRUE"; - } - function c(l) { - return Object.prototype.toString.call(l) === "[object Boolean]"; - } - o.exports = new i("tag:yaml.org,2002:bool", { kind: "scalar", resolve: u, construct: a, predicate: c, represent: { lowercase: function(l) { - return l ? "true" : "false"; - }, uppercase: function(l) { - return l ? "TRUE" : "FALSE"; - }, camelcase: function(l) { - return l ? "True" : "False"; - } }, defaultStyle: "lowercase" }); - }, { "../type": 47 }], 50: [function(n, o, p) { - var i = n("../common"), u = n("../type"), a = new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"); - function c(y) { - return y !== null && !(!a.test(y) || y[y.length - 1] === "_"); - } - function l(y) { - var S, T, v, h; - return T = (S = y.replace(/_/g, "").toLowerCase())[0] === "-" ? -1 : 1, h = [], "+-".indexOf(S[0]) >= 0 && (S = S.slice(1)), S === ".inf" ? T === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : S === ".nan" ? NaN : S.indexOf(":") >= 0 ? (S.split(":").forEach(function(b) { - h.unshift(parseFloat(b, 10)); - }), S = 0, v = 1, h.forEach(function(b) { - S += b * v, v *= 60; - }), T * S) : T * parseFloat(S, 10); - } - var f = /^[-+]?[0-9]+e/; - function d(y, S) { - var T; - if (isNaN(y)) switch (S) { - case "lowercase": - return ".nan"; - case "uppercase": - return ".NAN"; - case "camelcase": - return ".NaN"; - } - else if (Number.POSITIVE_INFINITY === y) switch (S) { - case "lowercase": - return ".inf"; - case "uppercase": - return ".INF"; - case "camelcase": - return ".Inf"; - } - else if (Number.NEGATIVE_INFINITY === y) switch (S) { - case "lowercase": - return "-.inf"; - case "uppercase": - return "-.INF"; - case "camelcase": - return "-.Inf"; - } - else if (i.isNegativeZero(y)) return "-0.0"; - return T = y.toString(10), f.test(T) ? T.replace("e", ".e") : T; - } - function E(y) { - return Object.prototype.toString.call(y) === "[object Number]" && (y % 1 != 0 || i.isNegativeZero(y)); - } - o.exports = new u("tag:yaml.org,2002:float", { kind: "scalar", resolve: c, construct: l, predicate: E, represent: d, defaultStyle: "lowercase" }); - }, { "../common": 36, "../type": 47 }], 51: [function(n, o, p) { - var i = n("../common"), u = n("../type"); - function a(y) { - return 48 <= y && y <= 57 || 65 <= y && y <= 70 || 97 <= y && y <= 102; - } - function c(y) { - return 48 <= y && y <= 55; - } - function l(y) { - return 48 <= y && y <= 57; - } - function f(y) { - if (y === null) return !1; - var S, T = y.length, v = 0, h = !1; - if (!T) return !1; - if ((S = y[v]) !== "-" && S !== "+" || (S = y[++v]), S === "0") { - if (v + 1 === T) return !0; - if ((S = y[++v]) === "b") { - for (v++; v < T; v++) if ((S = y[v]) !== "_") { - if (S !== "0" && S !== "1") return !1; - h = !0; - } - return h && S !== "_"; - } - if (S === "x") { - for (v++; v < T; v++) if ((S = y[v]) !== "_") { - if (!a(y.charCodeAt(v))) return !1; - h = !0; - } - return h && S !== "_"; - } - for (; v < T; v++) if ((S = y[v]) !== "_") { - if (!c(y.charCodeAt(v))) return !1; - h = !0; - } - return h && S !== "_"; - } - if (S === "_") return !1; - for (; v < T; v++) if ((S = y[v]) !== "_") { - if (S === ":") break; - if (!l(y.charCodeAt(v))) return !1; - h = !0; - } - return !(!h || S === "_") && (S !== ":" || /^(:[0-5]?[0-9])+$/.test(y.slice(v))); - } - function d(y) { - var S, T, v = y, h = 1, b = []; - return v.indexOf("_") !== -1 && (v = v.replace(/_/g, "")), (S = v[0]) !== "-" && S !== "+" || (S === "-" && (h = -1), S = (v = v.slice(1))[0]), v === "0" ? 0 : S === "0" ? v[1] === "b" ? h * parseInt(v.slice(2), 2) : v[1] === "x" ? h * parseInt(v, 16) : h * parseInt(v, 8) : v.indexOf(":") !== -1 ? (v.split(":").forEach(function(w) { - b.unshift(parseInt(w, 10)); - }), v = 0, T = 1, b.forEach(function(w) { - v += w * T, T *= 60; - }), h * v) : h * parseInt(v, 10); - } - function E(y) { - return Object.prototype.toString.call(y) === "[object Number]" && y % 1 == 0 && !i.isNegativeZero(y); - } - o.exports = new u("tag:yaml.org,2002:int", { kind: "scalar", resolve: f, construct: d, predicate: E, represent: { binary: function(y) { - return y >= 0 ? "0b" + y.toString(2) : "-0b" + y.toString(2).slice(1); - }, octal: function(y) { - return y >= 0 ? "0" + y.toString(8) : "-0" + y.toString(8).slice(1); - }, decimal: function(y) { - return y.toString(10); - }, hexadecimal: function(y) { - return y >= 0 ? "0x" + y.toString(16).toUpperCase() : "-0x" + y.toString(16).toUpperCase().slice(1); - } }, defaultStyle: "decimal", styleAliases: { binary: [2, "bin"], octal: [8, "oct"], decimal: [10, "dec"], hexadecimal: [16, "hex"] } }); - }, { "../common": 36, "../type": 47 }], 52: [function(n, o, p) { - var i; - try { - var u = n; - i = u("esprima"); - } catch { - typeof window < "u" && (i = window.esprima); - } - var a = n("../../type"); - function c(E) { - if (E === null) return !1; - try { - var y = "(" + E + ")", S = i.parse(y, { range: !0 }); - return S.type === "Program" && S.body.length === 1 && S.body[0].type === "ExpressionStatement" && (S.body[0].expression.type === "ArrowFunctionExpression" || S.body[0].expression.type === "FunctionExpression"); - } catch { - return !1; - } - } - function l(E) { - var y, S = "(" + E + ")", T = i.parse(S, { range: !0 }), v = []; - if (T.type !== "Program" || T.body.length !== 1 || T.body[0].type !== "ExpressionStatement" || T.body[0].expression.type !== "ArrowFunctionExpression" && T.body[0].expression.type !== "FunctionExpression") throw new Error("Failed to resolve function"); - return T.body[0].expression.params.forEach(function(h) { - v.push(h.name); - }), y = T.body[0].expression.body.range, T.body[0].expression.body.type === "BlockStatement" ? new Function(v, S.slice(y[0] + 1, y[1] - 1)) : new Function(v, "return " + S.slice(y[0], y[1])); - } - function f(E) { - return E.toString(); - } - function d(E) { - return Object.prototype.toString.call(E) === "[object Function]"; - } - o.exports = new a("tag:yaml.org,2002:js/function", { kind: "scalar", resolve: c, construct: l, predicate: d, represent: f }); - }, { "../../type": 47 }], 53: [function(n, o, p) { - var i = n("../../type"); - function u(f) { - if (f === null || f.length === 0) return !1; - var d = f, E = /\/([gim]*)$/.exec(f), y = ""; - return !(d[0] === "/" && (E && (y = E[1]), y.length > 3 || d[d.length - y.length - 1] !== "/")); - } - function a(f) { - var d = f, E = /\/([gim]*)$/.exec(f), y = ""; - return d[0] === "/" && (E && (y = E[1]), d = d.slice(1, d.length - y.length - 1)), new RegExp(d, y); - } - function c(f) { - var d = "/" + f.source + "/"; - return f.global && (d += "g"), f.multiline && (d += "m"), f.ignoreCase && (d += "i"), d; - } - function l(f) { - return Object.prototype.toString.call(f) === "[object RegExp]"; - } - o.exports = new i("tag:yaml.org,2002:js/regexp", { kind: "scalar", resolve: u, construct: a, predicate: l, represent: c }); - }, { "../../type": 47 }], 54: [function(n, o, p) { - var i = n("../../type"); - function u() { - return !0; - } - function a() { - } - function c() { - return ""; - } - function l(f) { - return f === void 0; - } - o.exports = new i("tag:yaml.org,2002:js/undefined", { kind: "scalar", resolve: u, construct: a, predicate: l, represent: c }); - }, { "../../type": 47 }], 55: [function(n, o, p) { - var i = n("../type"); - o.exports = new i("tag:yaml.org,2002:map", { kind: "mapping", construct: function(u) { - return u !== null ? u : {}; - } }); - }, { "../type": 47 }], 56: [function(n, o, p) { - var i = n("../type"); - function u(a) { - return a === "<<" || a === null; - } - o.exports = new i("tag:yaml.org,2002:merge", { kind: "scalar", resolve: u }); - }, { "../type": 47 }], 57: [function(n, o, p) { - var i = n("../type"); - function u(l) { - if (l === null) return !0; - var f = l.length; - return f === 1 && l === "~" || f === 4 && (l === "null" || l === "Null" || l === "NULL"); - } - function a() { - return null; - } - function c(l) { - return l === null; - } - o.exports = new i("tag:yaml.org,2002:null", { kind: "scalar", resolve: u, construct: a, predicate: c, represent: { canonical: function() { - return "~"; - }, lowercase: function() { - return "null"; - }, uppercase: function() { - return "NULL"; - }, camelcase: function() { - return "Null"; - } }, defaultStyle: "lowercase" }); - }, { "../type": 47 }], 58: [function(n, o, p) { - var i = n("../type"), u = Object.prototype.hasOwnProperty, a = Object.prototype.toString; - function c(f) { - if (f === null) return !0; - var d, E, y, S, T, v = [], h = f; - for (d = 0, E = h.length; d < E; d += 1) { - if (y = h[d], T = !1, a.call(y) !== "[object Object]") return !1; - for (S in y) if (u.call(y, S)) { - if (T) return !1; - T = !0; - } - if (!T || v.indexOf(S) !== -1) return !1; - v.push(S); - } - return !0; - } - function l(f) { - return f !== null ? f : []; - } - o.exports = new i("tag:yaml.org,2002:omap", { kind: "sequence", resolve: c, construct: l }); - }, { "../type": 47 }], 59: [function(n, o, p) { - var i = n("../type"), u = Object.prototype.toString; - function a(l) { - if (l === null) return !0; - var f, d, E, y, S, T = l; - for (S = new Array(T.length), f = 0, d = T.length; f < d; f += 1) { - if (E = T[f], u.call(E) !== "[object Object]" || (y = Object.keys(E)).length !== 1) return !1; - S[f] = [y[0], E[y[0]]]; - } - return !0; - } - function c(l) { - if (l === null) return []; - var f, d, E, y, S, T = l; - for (S = new Array(T.length), f = 0, d = T.length; f < d; f += 1) E = T[f], y = Object.keys(E), S[f] = [y[0], E[y[0]]]; - return S; - } - o.exports = new i("tag:yaml.org,2002:pairs", { kind: "sequence", resolve: a, construct: c }); - }, { "../type": 47 }], 60: [function(n, o, p) { - var i = n("../type"); - o.exports = new i("tag:yaml.org,2002:seq", { kind: "sequence", construct: function(u) { - return u !== null ? u : []; - } }); - }, { "../type": 47 }], 61: [function(n, o, p) { - var i = n("../type"), u = Object.prototype.hasOwnProperty; - function a(l) { - if (l === null) return !0; - var f, d = l; - for (f in d) if (u.call(d, f) && d[f] !== null) return !1; - return !0; - } - function c(l) { - return l !== null ? l : {}; - } - o.exports = new i("tag:yaml.org,2002:set", { kind: "mapping", resolve: a, construct: c }); - }, { "../type": 47 }], 62: [function(n, o, p) { - var i = n("../type"); - o.exports = new i("tag:yaml.org,2002:str", { kind: "scalar", construct: function(u) { - return u !== null ? u : ""; - } }); - }, { "../type": 47 }], 63: [function(n, o, p) { - var i = n("../type"), u = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"), a = 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 c(d) { - return d !== null && (u.exec(d) !== null || a.exec(d) !== null); - } - function l(d) { - var E, y, S, T, v, h, b, w, _ = 0, O = null; - if ((E = u.exec(d)) === null && (E = a.exec(d)), E === null) throw new Error("Date resolve error"); - if (y = +E[1], S = +E[2] - 1, T = +E[3], !E[4]) return new Date(Date.UTC(y, S, T)); - if (v = +E[4], h = +E[5], b = +E[6], E[7]) { - for (_ = E[7].slice(0, 3); _.length < 3; ) _ += "0"; - _ = +_; - } - return E[9] && (O = 6e4 * (60 * +E[10] + +(E[11] || 0)), E[9] === "-" && (O = -O)), w = new Date(Date.UTC(y, S, T, v, h, b, _)), O && w.setTime(w.getTime() - O), w; - } - function f(d) { - return d.toISOString(); - } - o.exports = new i("tag:yaml.org,2002:timestamp", { kind: "scalar", resolve: c, construct: l, instanceOf: Date, represent: f }); - }, { "../type": 47 }], 64: [function(n, o, p) { - var i = n("format-util"), u = Array.prototype.slice, a = ["name", "message", "stack"], c = ["name", "message", "description", "number", "code", "fileName", "lineNumber", "columnNumber", "sourceURL", "line", "column", "stack"]; - function l(P) { - return function(L, Y, H, V) { - var B = [], ne = ""; - typeof L == "string" ? (B = u.call(arguments), L = Y = void 0) : typeof Y == "string" ? (B = u.call(arguments, 1), Y = void 0) : typeof H == "string" && (B = u.call(arguments, 2)), B.length > 0 && (ne = o.exports.formatter.apply(null, B)), L && L.message && (ne += (ne ? ` -` : "") + L.message); - var I = new P(ne); - return f(I, L), d(I), E(I, Y), I; - }; - } - function f(P, L) { - T(P, L), E(P, L); - } - function d(P) { - P.toJSON = y, P.inspect = S; - } - function E(P, L) { - if (L && typeof L == "object") for (var Y = Object.keys(L), H = 0; H < Y.length; H++) { - var V = Y[H]; - if (!(a.indexOf(V) >= 0)) try { - P[V] = L[V]; - } catch { - } - } - } - function y() { - var P = {}, L = Object.keys(this); - L = L.concat(c); - for (var Y = 0; Y < L.length; Y++) { - var H = L[Y], V = this[H], B = typeof V; - B !== "undefined" && B !== "function" && (P[H] = V); - } - return P; - } - function S() { - return JSON.stringify(this, null, 2).replace(/\\n/g, ` -`); - } - function T(P, L) { - w(P) ? L ? _(P, L) : O(P) : P.stack = L ? v(P.stack, L.stack) : h(P.stack); - } - function v(P, L) { - return (P = h(P)) && L ? P + ` - -` + L : P || L; - } - function h(P) { - if (P) { - var L = P.split(` -`); - if (L.length < 2) return P; - for (var Y = 0; Y < L.length; Y++) - if (L[Y].indexOf("onoFactory") >= 0) return L.splice(Y, 1), L.join(` -`); - return P; - } - } - o.exports = l(Error), o.exports.error = l(Error), o.exports.eval = l(EvalError), o.exports.range = l(RangeError), o.exports.reference = l(ReferenceError), o.exports.syntax = l(SyntaxError), o.exports.type = l(TypeError), o.exports.uri = l(URIError), o.exports.formatter = i; - var b = !(!Object.getOwnPropertyDescriptor || !Object.defineProperty || typeof navigator < "u" && /Android/.test(navigator.userAgent)); - function w(P) { - if (!b) return !1; - var L = Object.getOwnPropertyDescriptor(P, "stack"); - return !!L && typeof L.get == "function"; - } - function _(P, L) { - var Y = Object.getOwnPropertyDescriptor(P, "stack"); - Object.defineProperty(P, "stack", { get: function() { - return v(Y.get.apply(P), L.stack); - }, enumerable: !1, configurable: !0 }); - } - function O(P) { - var L = Object.getOwnPropertyDescriptor(P, "stack"); - Object.defineProperty(P, "stack", { get: function() { - return h(L.get.apply(P)); - }, enumerable: !1, configurable: !0 }); - } - }, { "format-util": 28 }], 65: [function(n, o, p) { - (function(i) { - function u(a, c, l, f) { - if (typeof a != "function") throw new TypeError('"callback" argument must be a function'); - var d, E, y = arguments.length; - switch (y) { - case 0: - case 1: - return i.nextTick(a); - case 2: - return i.nextTick(function() { - a.call(null, c); - }); - case 3: - return i.nextTick(function() { - a.call(null, c, l); - }); - case 4: - return i.nextTick(function() { - a.call(null, c, l, f); - }); - default: - for (d = new Array(y - 1), E = 0; E < d.length; ) d[E++] = arguments[E]; - return i.nextTick(function() { - a.apply(null, d); - }); - } - } - !i.version || i.version.indexOf("v0.") === 0 || i.version.indexOf("v1.") === 0 && i.version.indexOf("v1.8.") !== 0 ? o.exports = { nextTick: u } : o.exports = i; - }).call(this, n("_process")); - }, { _process: 66 }], 66: [function(n, o, p) { - var i, u, a = o.exports = {}; - function c() { - throw new Error("setTimeout has not been defined"); - } - function l() { - throw new Error("clearTimeout has not been defined"); - } - function f(_) { - if (i === setTimeout) return setTimeout(_, 0); - if ((i === c || !i) && setTimeout) return i = setTimeout, setTimeout(_, 0); - try { - return i(_, 0); - } catch { - try { - return i.call(null, _, 0); - } catch { - return i.call(this, _, 0); - } - } - } - function d(_) { - if (u === clearTimeout) return clearTimeout(_); - if ((u === l || !u) && clearTimeout) return u = clearTimeout, clearTimeout(_); - try { - return u(_); - } catch { - try { - return u.call(null, _); - } catch { - return u.call(this, _); - } - } - } - (function() { - try { - i = typeof setTimeout == "function" ? setTimeout : c; - } catch { - i = c; - } - try { - u = typeof clearTimeout == "function" ? clearTimeout : l; - } catch { - u = l; - } - })(); - var E, y = [], S = !1, T = -1; - function v() { - S && E && (S = !1, E.length ? y = E.concat(y) : T = -1, y.length && h()); - } - function h() { - if (!S) { - var _ = f(v); - S = !0; - for (var O = y.length; O; ) { - for (E = y, y = []; ++T < O; ) E && E[T].run(); - T = -1, O = y.length; - } - E = null, S = !1, d(_); - } - } - function b(_, O) { - this.fun = _, this.array = O; - } - function w() { - } - a.nextTick = function(_) { - var O = new Array(arguments.length - 1); - if (arguments.length > 1) for (var P = 1; P < arguments.length; P++) O[P - 1] = arguments[P]; - y.push(new b(_, O)), y.length !== 1 || S || f(h); - }, b.prototype.run = function() { - this.fun.apply(null, this.array); - }, a.title = "browser", a.browser = !0, a.env = {}, a.argv = [], a.version = "", a.versions = {}, a.on = w, a.addListener = w, a.once = w, a.off = w, a.removeListener = w, a.removeAllListeners = w, a.emit = w, a.prependListener = w, a.prependOnceListener = w, a.listeners = function(_) { - return []; - }, a.binding = function(_) { - throw new Error("process.binding is not supported"); - }, a.cwd = function() { - return "/"; - }, a.chdir = function(_) { - throw new Error("process.chdir is not supported"); - }, a.umask = function() { - return 0; - }; - }, {}], 67: [function(n, o, p) { - function i(a, c) { - return Object.prototype.hasOwnProperty.call(a, c); - } - o.exports = function(a, c, l, f) { - c = c || "&", l = l || "="; - var d = {}; - if (typeof a != "string" || a.length === 0) return d; - var E = /\+/g; - a = a.split(c); - var y = 1e3; - f && typeof f.maxKeys == "number" && (y = f.maxKeys); - var S = a.length; - y > 0 && S > y && (S = y); - for (var T = 0; T < S; ++T) { - var v, h, b, w, _ = a[T].replace(E, "%20"), O = _.indexOf(l); - O >= 0 ? (v = _.substr(0, O), h = _.substr(O + 1)) : (v = _, h = ""), b = decodeURIComponent(v), w = decodeURIComponent(h), i(d, b) ? u(d[b]) ? d[b].push(w) : d[b] = [d[b], w] : d[b] = w; - } - return d; - }; - var u = Array.isArray || function(a) { - return Object.prototype.toString.call(a) === "[object Array]"; - }; - }, {}], 68: [function(n, o, p) { - var i = function(l) { - switch (typeof l) { - case "string": - return l; - case "boolean": - return l ? "true" : "false"; - case "number": - return isFinite(l) ? l : ""; - default: - return ""; - } - }; - o.exports = function(l, f, d, E) { - return f = f || "&", d = d || "=", l === null && (l = void 0), typeof l == "object" ? a(c(l), function(y) { - var S = encodeURIComponent(i(y)) + d; - return u(l[y]) ? a(l[y], function(T) { - return S + encodeURIComponent(i(T)); - }).join(f) : S + encodeURIComponent(i(l[y])); - }).join(f) : E ? encodeURIComponent(i(E)) + d + encodeURIComponent(i(l)) : ""; - }; - var u = Array.isArray || function(l) { - return Object.prototype.toString.call(l) === "[object Array]"; - }; - function a(l, f) { - if (l.map) return l.map(f); - for (var d = [], E = 0; E < l.length; E++) d.push(f(l[E], E)); - return d; - } - var c = Object.keys || function(l) { - var f = []; - for (var d in l) Object.prototype.hasOwnProperty.call(l, d) && f.push(d); - return f; - }; - }, {}], 69: [function(n, o, p) { - p.decode = p.parse = n("./decode"), p.encode = p.stringify = n("./encode"); - }, { "./decode": 67, "./encode": 68 }], 70: [function(n, o, p) { - var i = n("process-nextick-args"), u = Object.keys || function(v) { - var h = []; - for (var b in v) h.push(b); - return h; - }; - o.exports = y; - var a = n("core-util-is"); - a.inherits = n("inherits"); - var c = n("./_stream_readable"), l = n("./_stream_writable"); - a.inherits(y, c); - for (var f = u(l.prototype), d = 0; d < f.length; d++) { - var E = f[d]; - y.prototype[E] || (y.prototype[E] = l.prototype[E]); - } - function y(v) { - if (!(this instanceof y)) return new y(v); - c.call(this, v), l.call(this, v), v && v.readable === !1 && (this.readable = !1), v && v.writable === !1 && (this.writable = !1), this.allowHalfOpen = !0, v && v.allowHalfOpen === !1 && (this.allowHalfOpen = !1), this.once("end", S); - } - function S() { - this.allowHalfOpen || this._writableState.ended || i.nextTick(T, this); - } - function T(v) { - v.end(); - } - Object.defineProperty(y.prototype, "writableHighWaterMark", { enumerable: !1, get: function() { - return this._writableState.highWaterMark; - } }), Object.defineProperty(y.prototype, "destroyed", { get: function() { - return this._readableState !== void 0 && this._writableState !== void 0 && this._readableState.destroyed && this._writableState.destroyed; - }, set: function(v) { - this._readableState !== void 0 && this._writableState !== void 0 && (this._readableState.destroyed = v, this._writableState.destroyed = v); - } }), y.prototype._destroy = function(v, h) { - this.push(null), this.end(), i.nextTick(h, v); - }; - }, { "./_stream_readable": 72, "./_stream_writable": 74, "core-util-is": 26, inherits: 31, "process-nextick-args": 65 }], 71: [function(n, o, p) { - o.exports = a; - var i = n("./_stream_transform"), u = n("core-util-is"); - function a(c) { - if (!(this instanceof a)) return new a(c); - i.call(this, c); - } - u.inherits = n("inherits"), u.inherits(a, i), a.prototype._transform = function(c, l, f) { - f(null, c); - }; - }, { "./_stream_transform": 73, "core-util-is": 26, inherits: 31 }], 72: [function(n, o, p) { - (function(i, u) { - var a = n("process-nextick-args"); - o.exports = H; - var c, l = n("isarray"); - H.ReadableState = Y, n("events").EventEmitter; - var f = function(U, q) { - return U.listeners(q).length; - }, d = n("./internal/streams/stream"), E = n("safe-buffer").Buffer, y = u.Uint8Array || function() { - }; - function S(U) { - return E.from(U); - } - function T(U) { - return E.isBuffer(U) || U instanceof y; - } - var v = n("core-util-is"); - v.inherits = n("inherits"); - var h = n("util"), b = void 0; - b = h && h.debuglog ? h.debuglog("stream") : function() { - }; - var w, _ = n("./internal/streams/BufferList"), O = n("./internal/streams/destroy"); - v.inherits(H, d); - var P = ["error", "close", "destroy", "pause", "resume"]; - function L(U, q, de) { - if (typeof U.prependListener == "function") return U.prependListener(q, de); - U._events && U._events[q] ? l(U._events[q]) ? U._events[q].unshift(de) : U._events[q] = [de, U._events[q]] : U.on(q, de); - } - function Y(U, q) { - U = U || {}; - var de = q instanceof (c = c || n("./_stream_duplex")); - this.objectMode = !!U.objectMode, de && (this.objectMode = this.objectMode || !!U.readableObjectMode); - var F = U.highWaterMark, ce = U.readableHighWaterMark, m = this.objectMode ? 16 : 16384; - this.highWaterMark = F || F === 0 ? F : de && (ce || ce === 0) ? ce : m, this.highWaterMark = Math.floor(this.highWaterMark), this.buffer = new _(), this.length = 0, this.pipes = null, this.pipesCount = 0, this.flowing = null, this.ended = !1, this.endEmitted = !1, this.reading = !1, this.sync = !0, this.needReadable = !1, this.emittedReadable = !1, this.readableListening = !1, this.resumeScheduled = !1, this.destroyed = !1, this.defaultEncoding = U.defaultEncoding || "utf8", this.awaitDrain = 0, this.readingMore = !1, this.decoder = null, this.encoding = null, U.encoding && (w || (w = n("string_decoder/").StringDecoder), this.decoder = new w(U.encoding), this.encoding = U.encoding); - } - function H(U) { - if (c = c || n("./_stream_duplex"), !(this instanceof H)) return new H(U); - this._readableState = new Y(U, this), this.readable = !0, U && (typeof U.read == "function" && (this._read = U.read), typeof U.destroy == "function" && (this._destroy = U.destroy)), d.call(this); - } - function V(U, q, de, F, ce) { - var m, A = U._readableState; - return q === null ? (A.reading = !1, le(U, A)) : (ce || (m = ne(A, q)), m ? U.emit("error", m) : A.objectMode || q && q.length > 0 ? (typeof q == "string" || A.objectMode || Object.getPrototypeOf(q) === E.prototype || (q = S(q)), F ? A.endEmitted ? U.emit("error", new Error("stream.unshift() after end event")) : B(U, A, q, !0) : A.ended ? U.emit("error", new Error("stream.push() after EOF")) : (A.reading = !1, A.decoder && !de ? (q = A.decoder.write(q), A.objectMode || q.length !== 0 ? B(U, A, q, !1) : fe(U, A)) : B(U, A, q, !1))) : F || (A.reading = !1)), I(A); - } - function B(U, q, de, F) { - q.flowing && q.length === 0 && !q.sync ? (U.emit("data", de), U.read(0)) : (q.length += q.objectMode ? 1 : de.length, F ? q.buffer.unshift(de) : q.buffer.push(de), q.needReadable && ve(U)), fe(U, q); - } - function ne(U, q) { - var de; - return T(q) || typeof q == "string" || q === void 0 || U.objectMode || (de = new TypeError("Invalid non-string/buffer chunk")), de; - } - function I(U) { - return !U.ended && (U.needReadable || U.length < U.highWaterMark || U.length === 0); - } - Object.defineProperty(H.prototype, "destroyed", { get: function() { - return this._readableState !== void 0 && this._readableState.destroyed; - }, set: function(U) { - this._readableState && (this._readableState.destroyed = U); - } }), H.prototype.destroy = O.destroy, H.prototype._undestroy = O.undestroy, H.prototype._destroy = function(U, q) { - this.push(null), q(U); - }, H.prototype.push = function(U, q) { - var de, F = this._readableState; - return F.objectMode ? de = !0 : typeof U == "string" && ((q = q || F.defaultEncoding) !== F.encoding && (U = E.from(U, q), q = ""), de = !0), V(this, U, q, !1, de); - }, H.prototype.unshift = function(U) { - return V(this, U, null, !0, !1); - }, H.prototype.isPaused = function() { - return this._readableState.flowing === !1; - }, H.prototype.setEncoding = function(U) { - return w || (w = n("string_decoder/").StringDecoder), this._readableState.decoder = new w(U), this._readableState.encoding = U, this; - }; - var Z = 8388608; - function te(U) { - return U >= Z ? U = Z : (U--, U |= U >>> 1, U |= U >>> 2, U |= U >>> 4, U |= U >>> 8, U |= U >>> 16, U++), U; - } - function he(U, q) { - return U <= 0 || q.length === 0 && q.ended ? 0 : q.objectMode ? 1 : U != U ? q.flowing && q.length ? q.buffer.head.data.length : q.length : (U > q.highWaterMark && (q.highWaterMark = te(U)), U <= q.length ? U : q.ended ? q.length : (q.needReadable = !0, 0)); - } - function le(U, q) { - if (!q.ended) { - if (q.decoder) { - var de = q.decoder.end(); - de && de.length && (q.buffer.push(de), q.length += q.objectMode ? 1 : de.length); - } - q.ended = !0, ve(U); - } - } - function ve(U) { - var q = U._readableState; - q.needReadable = !1, q.emittedReadable || (b("emitReadable", q.flowing), q.emittedReadable = !0, q.sync ? a.nextTick(oe, U) : oe(U)); - } - function oe(U) { - b("emit readable"), U.emit("readable"), G(U); - } - function fe(U, q) { - q.readingMore || (q.readingMore = !0, a.nextTick(j, U, q)); - } - function j(U, q) { - for (var de = q.length; !q.reading && !q.flowing && !q.ended && q.length < q.highWaterMark && (b("maybeReadMore read 0"), U.read(0), de !== q.length); ) de = q.length; - q.readingMore = !1; - } - function ie(U) { - return function() { - var q = U._readableState; - b("pipeOnDrain", q.awaitDrain), q.awaitDrain && q.awaitDrain--, q.awaitDrain === 0 && f(U, "data") && (q.flowing = !0, G(U)); - }; - } - function pe(U) { - b("readable nexttick read 0"), U.read(0); - } - function se(U, q) { - q.resumeScheduled || (q.resumeScheduled = !0, a.nextTick(W, U, q)); - } - function W(U, q) { - q.reading || (b("resume read 0"), U.read(0)), q.resumeScheduled = !1, q.awaitDrain = 0, U.emit("resume"), G(U), q.flowing && !q.reading && U.read(0); - } - function G(U) { - var q = U._readableState; - for (b("flow", q.flowing); q.flowing && U.read() !== null; ) ; - } - function ae(U, q) { - return q.length === 0 ? null : (q.objectMode ? de = q.buffer.shift() : !U || U >= q.length ? (de = q.decoder ? q.buffer.join("") : q.buffer.length === 1 ? q.buffer.head.data : q.buffer.concat(q.length), q.buffer.clear()) : de = ge(U, q.buffer, q.decoder), de); - var de; - } - function ge(U, q, de) { - var F; - return U < q.head.data.length ? (F = q.head.data.slice(0, U), q.head.data = q.head.data.slice(U)) : F = U === q.head.data.length ? q.shift() : de ? Ee(U, q) : ye(U, q), F; - } - function Ee(U, q) { - var de = q.head, F = 1, ce = de.data; - for (U -= ce.length; de = de.next; ) { - var m = de.data, A = U > m.length ? m.length : U; - if (A === m.length ? ce += m : ce += m.slice(0, U), (U -= A) === 0) { - A === m.length ? (++F, de.next ? q.head = de.next : q.head = q.tail = null) : (q.head = de, de.data = m.slice(A)); - break; - } - ++F; - } - return q.length -= F, ce; - } - function ye(U, q) { - var de = E.allocUnsafe(U), F = q.head, ce = 1; - for (F.data.copy(de), U -= F.data.length; F = F.next; ) { - var m = F.data, A = U > m.length ? m.length : U; - if (m.copy(de, de.length - U, 0, A), (U -= A) === 0) { - A === m.length ? (++ce, F.next ? q.head = F.next : q.head = q.tail = null) : (q.head = F, F.data = m.slice(A)); - break; - } - ++ce; - } - return q.length -= ce, de; - } - function Oe(U) { - var q = U._readableState; - if (q.length > 0) throw new Error('"endReadable()" called on non-empty stream'); - q.endEmitted || (q.ended = !0, a.nextTick(Ae, q, U)); - } - function Ae(U, q) { - U.endEmitted || U.length !== 0 || (U.endEmitted = !0, q.readable = !1, q.emit("end")); - } - function Te(U, q) { - for (var de = 0, F = U.length; de < F; de++) if (U[de] === q) return de; - return -1; - } - H.prototype.read = function(U) { - b("read", U), U = parseInt(U, 10); - var q = this._readableState, de = U; - if (U !== 0 && (q.emittedReadable = !1), U === 0 && q.needReadable && (q.length >= q.highWaterMark || q.ended)) return b("read: emitReadable", q.length, q.ended), q.length === 0 && q.ended ? Oe(this) : ve(this), null; - if ((U = he(U, q)) === 0 && q.ended) return q.length === 0 && Oe(this), null; - var F, ce = q.needReadable; - return b("need readable", ce), (q.length === 0 || q.length - U < q.highWaterMark) && b("length less than watermark", ce = !0), q.ended || q.reading ? b("reading or ended", ce = !1) : ce && (b("do read"), q.reading = !0, q.sync = !0, q.length === 0 && (q.needReadable = !0), this._read(q.highWaterMark), q.sync = !1, q.reading || (U = he(de, q))), (F = U > 0 ? ae(U, q) : null) === null ? (q.needReadable = !0, U = 0) : q.length -= U, q.length === 0 && (q.ended || (q.needReadable = !0), de !== U && q.ended && Oe(this)), F !== null && this.emit("data", F), F; - }, H.prototype._read = function(U) { - this.emit("error", new Error("_read() is not implemented")); - }, H.prototype.pipe = function(U, q) { - var de = this, F = this._readableState; - switch (F.pipesCount) { - case 0: - F.pipes = U; - break; - case 1: - F.pipes = [F.pipes, U]; - break; - default: - F.pipes.push(U); - } - F.pipesCount += 1, b("pipe count=%d opts=%j", F.pipesCount, q); - var ce = (!q || q.end !== !1) && U !== i.stdout && U !== i.stderr ? A : t; - function m(x, C) { - b("onunpipe"), x === de && C && C.hasUnpiped === !1 && (C.hasUnpiped = !0, b("cleanup"), U.removeListener("close", N), U.removeListener("finish", e), U.removeListener("drain", R), U.removeListener("error", be), U.removeListener("unpipe", m), de.removeListener("end", A), de.removeListener("end", t), de.removeListener("data", z), K = !0, !F.awaitDrain || U._writableState && !U._writableState.needDrain || R()); - } - function A() { - b("onend"), U.end(); - } - F.endEmitted ? a.nextTick(ce) : de.once("end", ce), U.on("unpipe", m); - var R = ie(de); - U.on("drain", R); - var K = !1, Q = !1; - function z(x) { - b("ondata"), Q = !1, U.write(x) !== !1 || Q || ((F.pipesCount === 1 && F.pipes === U || F.pipesCount > 1 && Te(F.pipes, U) !== -1) && !K && (b("false write response, pause", de._readableState.awaitDrain), de._readableState.awaitDrain++, Q = !0), de.pause()); - } - function be(x) { - b("onerror", x), t(), U.removeListener("error", be), f(U, "error") === 0 && U.emit("error", x); - } - function N() { - U.removeListener("finish", e), t(); - } - function e() { - b("onfinish"), U.removeListener("close", N), t(); - } - function t() { - b("unpipe"), de.unpipe(U); - } - return de.on("data", z), L(U, "error", be), U.once("close", N), U.once("finish", e), U.emit("pipe", de), F.flowing || (b("pipe resume"), de.resume()), U; - }, H.prototype.unpipe = function(U) { - var q = this._readableState, de = { hasUnpiped: !1 }; - if (q.pipesCount === 0) return this; - if (q.pipesCount === 1) return U && U !== q.pipes ? this : (U || (U = q.pipes), q.pipes = null, q.pipesCount = 0, q.flowing = !1, U && U.emit("unpipe", this, de), this); - if (!U) { - var F = q.pipes, ce = q.pipesCount; - q.pipes = null, q.pipesCount = 0, q.flowing = !1; - for (var m = 0; m < ce; m++) F[m].emit("unpipe", this, de); - return this; - } - var A = Te(q.pipes, U); - return A === -1 ? this : (q.pipes.splice(A, 1), q.pipesCount -= 1, q.pipesCount === 1 && (q.pipes = q.pipes[0]), U.emit("unpipe", this, de), this); - }, H.prototype.on = function(U, q) { - var de = d.prototype.on.call(this, U, q); - if (U === "data") this._readableState.flowing !== !1 && this.resume(); - else if (U === "readable") { - var F = this._readableState; - F.endEmitted || F.readableListening || (F.readableListening = F.needReadable = !0, F.emittedReadable = !1, F.reading ? F.length && ve(this) : a.nextTick(pe, this)); - } - return de; - }, H.prototype.addListener = H.prototype.on, H.prototype.resume = function() { - var U = this._readableState; - return U.flowing || (b("resume"), U.flowing = !0, se(this, U)), this; - }, H.prototype.pause = function() { - return b("call pause flowing=%j", this._readableState.flowing), this._readableState.flowing !== !1 && (b("pause"), this._readableState.flowing = !1, this.emit("pause")), this; - }, H.prototype.wrap = function(U) { - var q = this, de = this._readableState, F = !1; - for (var ce in U.on("end", function() { - if (b("wrapped end"), de.decoder && !de.ended) { - var A = de.decoder.end(); - A && A.length && q.push(A); - } - q.push(null); - }), U.on("data", function(A) { - b("wrapped data"), de.decoder && (A = de.decoder.write(A)), de.objectMode && A == null || (de.objectMode || A && A.length) && (q.push(A) || (F = !0, U.pause())); - }), U) this[ce] === void 0 && typeof U[ce] == "function" && (this[ce] = /* @__PURE__ */ (function(A) { - return function() { - return U[A].apply(U, arguments); - }; - })(ce)); - for (var m = 0; m < P.length; m++) U.on(P[m], this.emit.bind(this, P[m])); - return this._read = function(A) { - b("wrapped _read", A), F && (F = !1, U.resume()); - }, this; - }, Object.defineProperty(H.prototype, "readableHighWaterMark", { enumerable: !1, get: function() { - return this._readableState.highWaterMark; - } }), H._fromList = ae; - }).call(this, n("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); - }, { "./_stream_duplex": 70, "./internal/streams/BufferList": 75, "./internal/streams/destroy": 76, "./internal/streams/stream": 77, _process: 66, "core-util-is": 26, events: 27, inherits: 31, isarray: 33, "process-nextick-args": 65, "safe-buffer": 79, "string_decoder/": 84, util: 21 }], 73: [function(n, o, p) { - o.exports = c; - var i = n("./_stream_duplex"), u = n("core-util-is"); - function a(d, E) { - var y = this._transformState; - y.transforming = !1; - var S = y.writecb; - if (!S) return this.emit("error", new Error("write callback called multiple times")); - y.writechunk = null, y.writecb = null, E != null && this.push(E), S(d); - var T = this._readableState; - T.reading = !1, (T.needReadable || T.length < T.highWaterMark) && this._read(T.highWaterMark); - } - function c(d) { - if (!(this instanceof c)) return new c(d); - i.call(this, d), this._transformState = { afterTransform: a.bind(this), needTransform: !1, transforming: !1, writecb: null, writechunk: null, writeencoding: null }, this._readableState.needReadable = !0, this._readableState.sync = !1, d && (typeof d.transform == "function" && (this._transform = d.transform), typeof d.flush == "function" && (this._flush = d.flush)), this.on("prefinish", l); - } - function l() { - var d = this; - typeof this._flush == "function" ? this._flush(function(E, y) { - f(d, E, y); - }) : f(this, null, null); - } - function f(d, E, y) { - if (E) return d.emit("error", E); - if (y != null && d.push(y), d._writableState.length) throw new Error("Calling transform done when ws.length != 0"); - if (d._transformState.transforming) throw new Error("Calling transform done when still transforming"); - return d.push(null); - } - u.inherits = n("inherits"), u.inherits(c, i), c.prototype.push = function(d, E) { - return this._transformState.needTransform = !1, i.prototype.push.call(this, d, E); - }, c.prototype._transform = function(d, E, y) { - throw new Error("_transform() is not implemented"); - }, c.prototype._write = function(d, E, y) { - var S = this._transformState; - if (S.writecb = y, S.writechunk = d, S.writeencoding = E, !S.transforming) { - var T = this._readableState; - (S.needTransform || T.needReadable || T.length < T.highWaterMark) && this._read(T.highWaterMark); - } - }, c.prototype._read = function(d) { - var E = this._transformState; - E.writechunk !== null && E.writecb && !E.transforming ? (E.transforming = !0, this._transform(E.writechunk, E.writeencoding, E.afterTransform)) : E.needTransform = !0; - }, c.prototype._destroy = function(d, E) { - var y = this; - i.prototype._destroy.call(this, d, function(S) { - E(S), y.emit("close"); - }); - }; - }, { "./_stream_duplex": 70, "core-util-is": 26, inherits: 31 }], 74: [function(n, o, p) { - (function(i, u, a) { - var c = n("process-nextick-args"); - function l(W) { - var G = this; - this.next = null, this.entry = null, this.finish = function() { - se(G, W); - }; - } - o.exports = L; - var f, d = !i.browser && ["v0.10", "v0.9."].indexOf(i.version.slice(0, 5)) > -1 ? a : c.nextTick; - L.WritableState = P; - var E = n("core-util-is"); - E.inherits = n("inherits"); - var y = { deprecate: n("util-deprecate") }, S = n("./internal/streams/stream"), T = n("safe-buffer").Buffer, v = u.Uint8Array || function() { - }; - function h(W) { - return T.from(W); - } - function b(W) { - return T.isBuffer(W) || W instanceof v; - } - var w, _ = n("./internal/streams/destroy"); - function O() { - } - function P(W, G) { - f = f || n("./_stream_duplex"), W = W || {}; - var ae = G instanceof f; - this.objectMode = !!W.objectMode, ae && (this.objectMode = this.objectMode || !!W.writableObjectMode); - var ge = W.highWaterMark, Ee = W.writableHighWaterMark, ye = this.objectMode ? 16 : 16384; - this.highWaterMark = ge || ge === 0 ? ge : ae && (Ee || Ee === 0) ? Ee : ye, this.highWaterMark = Math.floor(this.highWaterMark), this.finalCalled = !1, this.needDrain = !1, this.ending = !1, this.ended = !1, this.finished = !1, this.destroyed = !1; - var Oe = W.decodeStrings === !1; - this.decodeStrings = !Oe, this.defaultEncoding = W.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = function(Ae) { - te(G, Ae); - }, this.writecb = null, this.writelen = 0, this.bufferedRequest = null, this.lastBufferedRequest = null, this.pendingcb = 0, this.prefinished = !1, this.errorEmitted = !1, this.bufferedRequestCount = 0, this.corkedRequestsFree = new l(this); - } - function L(W) { - if (f = f || n("./_stream_duplex"), !(w.call(L, this) || this instanceof f)) return new L(W); - this._writableState = new P(W, this), this.writable = !0, W && (typeof W.write == "function" && (this._write = W.write), typeof W.writev == "function" && (this._writev = W.writev), typeof W.destroy == "function" && (this._destroy = W.destroy), typeof W.final == "function" && (this._final = W.final)), S.call(this); - } - function Y(W, G) { - var ae = new Error("write after end"); - W.emit("error", ae), c.nextTick(G, ae); - } - function H(W, G, ae, ge) { - var Ee = !0, ye = !1; - return ae === null ? ye = new TypeError("May not write null values to stream") : typeof ae == "string" || ae === void 0 || G.objectMode || (ye = new TypeError("Invalid non-string/buffer chunk")), ye && (W.emit("error", ye), c.nextTick(ge, ye), Ee = !1), Ee; - } - function V(W, G, ae) { - return W.objectMode || W.decodeStrings === !1 || typeof G != "string" || (G = T.from(G, ae)), G; - } - function B(W, G, ae, ge, Ee, ye) { - if (!ae) { - var Oe = V(G, ge, Ee); - ge !== Oe && (ae = !0, Ee = "buffer", ge = Oe); - } - var Ae = G.objectMode ? 1 : ge.length; - G.length += Ae; - var Te = G.length < G.highWaterMark; - if (Te || (G.needDrain = !0), G.writing || G.corked) { - var U = G.lastBufferedRequest; - G.lastBufferedRequest = { chunk: ge, encoding: Ee, isBuf: ae, callback: ye, next: null }, U ? U.next = G.lastBufferedRequest : G.bufferedRequest = G.lastBufferedRequest, G.bufferedRequestCount += 1; - } else ne(W, G, !1, Ae, ge, Ee, ye); - return Te; - } - function ne(W, G, ae, ge, Ee, ye, Oe) { - G.writelen = ge, G.writecb = Oe, G.writing = !0, G.sync = !0, ae ? W._writev(Ee, G.onwrite) : W._write(Ee, ye, G.onwrite), G.sync = !1; - } - function I(W, G, ae, ge, Ee) { - --G.pendingcb, ae ? (c.nextTick(Ee, ge), c.nextTick(ie, W, G), W._writableState.errorEmitted = !0, W.emit("error", ge)) : (Ee(ge), W._writableState.errorEmitted = !0, W.emit("error", ge), ie(W, G)); - } - function Z(W) { - W.writing = !1, W.writecb = null, W.length -= W.writelen, W.writelen = 0; - } - function te(W, G) { - var ae = W._writableState, ge = ae.sync, Ee = ae.writecb; - if (Z(ae), G) I(W, ae, ge, G, Ee); - else { - var ye = oe(ae); - ye || ae.corked || ae.bufferProcessing || !ae.bufferedRequest || ve(W, ae), ge ? d(he, W, ae, ye, Ee) : he(W, ae, ye, Ee); - } - } - function he(W, G, ae, ge) { - ae || le(W, G), G.pendingcb--, ge(), ie(W, G); - } - function le(W, G) { - G.length === 0 && G.needDrain && (G.needDrain = !1, W.emit("drain")); - } - function ve(W, G) { - G.bufferProcessing = !0; - var ae = G.bufferedRequest; - if (W._writev && ae && ae.next) { - var ge = G.bufferedRequestCount, Ee = new Array(ge), ye = G.corkedRequestsFree; - ye.entry = ae; - for (var Oe = 0, Ae = !0; ae; ) Ee[Oe] = ae, ae.isBuf || (Ae = !1), ae = ae.next, Oe += 1; - Ee.allBuffers = Ae, ne(W, G, !0, G.length, Ee, "", ye.finish), G.pendingcb++, G.lastBufferedRequest = null, ye.next ? (G.corkedRequestsFree = ye.next, ye.next = null) : G.corkedRequestsFree = new l(G), G.bufferedRequestCount = 0; - } else { - for (; ae; ) { - var Te = ae.chunk, U = ae.encoding, q = ae.callback; - if (ne(W, G, !1, G.objectMode ? 1 : Te.length, Te, U, q), ae = ae.next, G.bufferedRequestCount--, G.writing) break; - } - ae === null && (G.lastBufferedRequest = null); - } - G.bufferedRequest = ae, G.bufferProcessing = !1; - } - function oe(W) { - return W.ending && W.length === 0 && W.bufferedRequest === null && !W.finished && !W.writing; - } - function fe(W, G) { - W._final(function(ae) { - G.pendingcb--, ae && W.emit("error", ae), G.prefinished = !0, W.emit("prefinish"), ie(W, G); - }); - } - function j(W, G) { - G.prefinished || G.finalCalled || (typeof W._final == "function" ? (G.pendingcb++, G.finalCalled = !0, c.nextTick(fe, W, G)) : (G.prefinished = !0, W.emit("prefinish"))); - } - function ie(W, G) { - var ae = oe(G); - return ae && (j(W, G), G.pendingcb === 0 && (G.finished = !0, W.emit("finish"))), ae; - } - function pe(W, G, ae) { - G.ending = !0, ie(W, G), ae && (G.finished ? c.nextTick(ae) : W.once("finish", ae)), G.ended = !0, W.writable = !1; - } - function se(W, G, ae) { - var ge = W.entry; - for (W.entry = null; ge; ) { - var Ee = ge.callback; - G.pendingcb--, Ee(ae), ge = ge.next; - } - G.corkedRequestsFree ? G.corkedRequestsFree.next = W : G.corkedRequestsFree = W; - } - E.inherits(L, S), P.prototype.getBuffer = function() { - for (var W = this.bufferedRequest, G = []; W; ) G.push(W), W = W.next; - return G; - }, (function() { - try { - Object.defineProperty(P.prototype, "buffer", { get: y.deprecate(function() { - return this.getBuffer(); - }, "_writableState.buffer is deprecated. Use _writableState.getBuffer instead.", "DEP0003") }); - } catch { - } - })(), typeof Symbol == "function" && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] == "function" ? (w = Function.prototype[Symbol.hasInstance], Object.defineProperty(L, Symbol.hasInstance, { value: function(W) { - return !!w.call(this, W) || this === L && W && W._writableState instanceof P; - } })) : w = function(W) { - return W instanceof this; - }, L.prototype.pipe = function() { - this.emit("error", new Error("Cannot pipe, not readable")); - }, L.prototype.write = function(W, G, ae) { - var ge = this._writableState, Ee = !1, ye = !ge.objectMode && b(W); - return ye && !T.isBuffer(W) && (W = h(W)), typeof G == "function" && (ae = G, G = null), ye ? G = "buffer" : G || (G = ge.defaultEncoding), typeof ae != "function" && (ae = O), ge.ended ? Y(this, ae) : (ye || H(this, ge, W, ae)) && (ge.pendingcb++, Ee = B(this, ge, ye, W, G, ae)), Ee; - }, L.prototype.cork = function() { - this._writableState.corked++; - }, L.prototype.uncork = function() { - var W = this._writableState; - W.corked && (W.corked--, W.writing || W.corked || W.finished || W.bufferProcessing || !W.bufferedRequest || ve(this, W)); - }, L.prototype.setDefaultEncoding = function(W) { - if (typeof W == "string" && (W = W.toLowerCase()), !(["hex", "utf8", "utf-8", "ascii", "binary", "base64", "ucs2", "ucs-2", "utf16le", "utf-16le", "raw"].indexOf((W + "").toLowerCase()) > -1)) throw new TypeError("Unknown encoding: " + W); - return this._writableState.defaultEncoding = W, this; - }, Object.defineProperty(L.prototype, "writableHighWaterMark", { enumerable: !1, get: function() { - return this._writableState.highWaterMark; - } }), L.prototype._write = function(W, G, ae) { - ae(new Error("_write() is not implemented")); - }, L.prototype._writev = null, L.prototype.end = function(W, G, ae) { - var ge = this._writableState; - typeof W == "function" ? (ae = W, W = null, G = null) : typeof G == "function" && (ae = G, G = null), W != null && this.write(W, G), ge.corked && (ge.corked = 1, this.uncork()), ge.ending || ge.finished || pe(this, ge, ae); - }, Object.defineProperty(L.prototype, "destroyed", { get: function() { - return this._writableState !== void 0 && this._writableState.destroyed; - }, set: function(W) { - this._writableState && (this._writableState.destroyed = W); - } }), L.prototype.destroy = _.destroy, L.prototype._undestroy = _.undestroy, L.prototype._destroy = function(W, G) { - this.end(), G(W); - }; - }).call(this, n("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}, n("timers").setImmediate); - }, { "./_stream_duplex": 70, "./internal/streams/destroy": 76, "./internal/streams/stream": 77, _process: 66, "core-util-is": 26, inherits: 31, "process-nextick-args": 65, "safe-buffer": 79, timers: 85, "util-deprecate": 89 }], 75: [function(n, o, p) { - function i(l, f) { - if (!(l instanceof f)) throw new TypeError("Cannot call a class as a function"); - } - var u = n("safe-buffer").Buffer, a = n("util"); - function c(l, f, d) { - l.copy(f, d); - } - o.exports = (function() { - function l() { - i(this, l), this.head = null, this.tail = null, this.length = 0; - } - return l.prototype.push = function(f) { - var d = { data: f, next: null }; - this.length > 0 ? this.tail.next = d : this.head = d, this.tail = d, ++this.length; - }, l.prototype.unshift = function(f) { - var d = { data: f, next: this.head }; - this.length === 0 && (this.tail = d), this.head = d, ++this.length; - }, l.prototype.shift = function() { - if (this.length !== 0) { - var f = this.head.data; - return this.length === 1 ? this.head = this.tail = null : this.head = this.head.next, --this.length, f; - } - }, l.prototype.clear = function() { - this.head = this.tail = null, this.length = 0; - }, l.prototype.join = function(f) { - if (this.length === 0) return ""; - for (var d = this.head, E = "" + d.data; d = d.next; ) E += f + d.data; - return E; - }, l.prototype.concat = function(f) { - if (this.length === 0) return u.alloc(0); - if (this.length === 1) return this.head.data; - for (var d = u.allocUnsafe(f >>> 0), E = this.head, y = 0; E; ) c(E.data, d, y), y += E.data.length, E = E.next; - return d; - }, l; - })(), a && a.inspect && a.inspect.custom && (o.exports.prototype[a.inspect.custom] = function() { - var l = a.inspect({ length: this.length }); - return this.constructor.name + " " + l; - }); - }, { "safe-buffer": 79, util: 21 }], 76: [function(n, o, p) { - var i = n("process-nextick-args"); - function u(l, f) { - var d = this, E = this._readableState && this._readableState.destroyed, y = this._writableState && this._writableState.destroyed; - return E || y ? (f ? f(l) : !l || this._writableState && this._writableState.errorEmitted || i.nextTick(c, this, l), this) : (this._readableState && (this._readableState.destroyed = !0), this._writableState && (this._writableState.destroyed = !0), this._destroy(l || null, function(S) { - !f && S ? (i.nextTick(c, d, S), d._writableState && (d._writableState.errorEmitted = !0)) : f && f(S); - }), this); - } - function a() { - this._readableState && (this._readableState.destroyed = !1, this._readableState.reading = !1, this._readableState.ended = !1, this._readableState.endEmitted = !1), this._writableState && (this._writableState.destroyed = !1, this._writableState.ended = !1, this._writableState.ending = !1, this._writableState.finished = !1, this._writableState.errorEmitted = !1); - } - function c(l, f) { - l.emit("error", f); - } - o.exports = { destroy: u, undestroy: a }; - }, { "process-nextick-args": 65 }], 77: [function(n, o, p) { - o.exports = n("events").EventEmitter; - }, { events: 27 }], 78: [function(n, o, p) { - p = o.exports = n("./lib/_stream_readable.js"), p.Stream = p, p.Readable = p, p.Writable = n("./lib/_stream_writable.js"), p.Duplex = n("./lib/_stream_duplex.js"), p.Transform = n("./lib/_stream_transform.js"), p.PassThrough = n("./lib/_stream_passthrough.js"); - }, { "./lib/_stream_duplex.js": 70, "./lib/_stream_passthrough.js": 71, "./lib/_stream_readable.js": 72, "./lib/_stream_transform.js": 73, "./lib/_stream_writable.js": 74 }], 79: [function(n, o, p) { - var i = n("buffer"), u = i.Buffer; - function a(l, f) { - for (var d in l) f[d] = l[d]; - } - function c(l, f, d) { - return u(l, f, d); - } - u.from && u.alloc && u.allocUnsafe && u.allocUnsafeSlow ? o.exports = i : (a(i, p), p.Buffer = c), a(u, c), c.from = function(l, f, d) { - if (typeof l == "number") throw new TypeError("Argument must not be a number"); - return u(l, f, d); - }, c.alloc = function(l, f, d) { - if (typeof l != "number") throw new TypeError("Argument must be a number"); - var E = u(l); - return f !== void 0 ? typeof d == "string" ? E.fill(f, d) : E.fill(f) : E.fill(0), E; - }, c.allocUnsafe = function(l) { - if (typeof l != "number") throw new TypeError("Argument must be a number"); - return u(l); - }, c.allocUnsafeSlow = function(l) { - if (typeof l != "number") throw new TypeError("Argument must be a number"); - return i.SlowBuffer(l); - }; - }, { buffer: 23 }], 80: [function(n, o, p) { - (function(i) { - var u = n("./lib/request"), a = n("./lib/response"), c = n("xtend"), l = n("builtin-status-codes"), f = n("url"), d = p; - d.request = function(E, y) { - E = typeof E == "string" ? f.parse(E) : c(E); - var S = i.location.protocol.search(/^https?:$/) === -1 ? "http:" : "", T = E.protocol || S, v = E.hostname || E.host, h = E.port, b = E.path || "/"; - v && v.indexOf(":") !== -1 && (v = "[" + v + "]"), E.url = (v ? T + "//" + v : "") + (h ? ":" + h : "") + b, E.method = (E.method || "GET").toUpperCase(), E.headers = E.headers || {}; - var w = new u(E); - return y && w.on("response", y), w; - }, d.get = function(E, y) { - var S = d.request(E, y); - return S.end(), S; - }, d.ClientRequest = u, d.IncomingMessage = a.IncomingMessage, d.Agent = function() { - }, d.Agent.defaultMaxSockets = 4, d.globalAgent = new d.Agent(), d.STATUS_CODES = l, d.METHODS = ["CHECKOUT", "CONNECT", "COPY", "DELETE", "GET", "HEAD", "LOCK", "M-SEARCH", "MERGE", "MKACTIVITY", "MKCOL", "MOVE", "NOTIFY", "OPTIONS", "PATCH", "POST", "PROPFIND", "PROPPATCH", "PURGE", "PUT", "REPORT", "SEARCH", "SUBSCRIBE", "TRACE", "UNLOCK", "UNSUBSCRIBE"]; - }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); - }, { "./lib/request": 82, "./lib/response": 83, "builtin-status-codes": 24, url: 87, xtend: 90 }], 81: [function(n, o, p) { - (function(i) { - p.fetch = d(i.fetch) && d(i.ReadableStream), p.writableStream = d(i.WritableStream), p.abortController = d(i.AbortController), p.blobConstructor = !1; - try { - new Blob([new ArrayBuffer(1)]), p.blobConstructor = !0; - } catch { - } - var u; - function a() { - if (u !== void 0) return u; - if (i.XMLHttpRequest) { - u = new i.XMLHttpRequest(); - try { - u.open("GET", i.XDomainRequest ? "/" : "https://example.com"); - } catch { - u = null; - } - } else u = null; - return u; - } - function c(E) { - var y = a(); - if (!y) return !1; - try { - return y.responseType = E, y.responseType === E; - } catch { - } - return !1; - } - var l = i.ArrayBuffer !== void 0, f = l && d(i.ArrayBuffer.prototype.slice); - function d(E) { - return typeof E == "function"; - } - p.arraybuffer = p.fetch || l && c("arraybuffer"), p.msstream = !p.fetch && f && c("ms-stream"), p.mozchunkedarraybuffer = !p.fetch && l && c("moz-chunked-arraybuffer"), p.overrideMimeType = p.fetch || !!a() && d(a().overrideMimeType), p.vbArray = d(i.VBArray), u = null; - }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); - }, {}], 82: [function(n, o, p) { - (function(i, u, a) { - var c = n("./capability"), l = n("inherits"), f = n("./response"), d = n("readable-stream"), E = n("to-arraybuffer"), y = f.IncomingMessage, S = f.readyStates; - function T(w, _) { - return c.fetch && _ ? "fetch" : c.mozchunkedarraybuffer ? "moz-chunked-arraybuffer" : c.msstream ? "ms-stream" : c.arraybuffer && w ? "arraybuffer" : c.vbArray && w ? "text:vbarray" : "text"; - } - var v = o.exports = function(w) { - var _, O = this; - d.Writable.call(O), O._opts = w, O._body = [], O._headers = {}, w.auth && O.setHeader("Authorization", "Basic " + new a(w.auth).toString("base64")), Object.keys(w.headers).forEach(function(L) { - O.setHeader(L, w.headers[L]); - }); - var P = !0; - if (w.mode === "disable-fetch" || "requestTimeout" in w && !c.abortController) P = !1, _ = !0; - else if (w.mode === "prefer-streaming") _ = !1; - else if (w.mode === "allow-wrong-content-type") _ = !c.overrideMimeType; - else { - if (w.mode && w.mode !== "default" && w.mode !== "prefer-fast") throw new Error("Invalid value for opts.mode"); - _ = !0; - } - O._mode = T(_, P), O._fetchTimer = null, O.on("finish", function() { - O._onFinish(); - }); - }; - function h(w) { - try { - var _ = w.status; - return _ !== null && _ !== 0; - } catch { - return !1; - } - } - l(v, d.Writable), v.prototype.setHeader = function(w, _) { - var O = w.toLowerCase(); - b.indexOf(O) === -1 && (this._headers[O] = { name: w, value: _ }); - }, v.prototype.getHeader = function(w) { - var _ = this._headers[w.toLowerCase()]; - return _ ? _.value : null; - }, v.prototype.removeHeader = function(w) { - delete this._headers[w.toLowerCase()]; - }, v.prototype._onFinish = function() { - var w = this; - if (!w._destroyed) { - var _ = w._opts, O = w._headers, P = null; - _.method !== "GET" && _.method !== "HEAD" && (P = c.arraybuffer ? E(a.concat(w._body)) : c.blobConstructor ? new u.Blob(w._body.map(function(B) { - return E(B); - }), { type: (O["content-type"] || {}).value || "" }) : a.concat(w._body).toString()); - var L = []; - if (Object.keys(O).forEach(function(B) { - var ne = O[B].name, I = O[B].value; - Array.isArray(I) ? I.forEach(function(Z) { - L.push([ne, Z]); - }) : L.push([ne, I]); - }), w._mode === "fetch") { - var Y = null; - if (c.abortController) { - var H = new AbortController(); - Y = H.signal, w._fetchAbortController = H, "requestTimeout" in _ && _.requestTimeout !== 0 && (w._fetchTimer = u.setTimeout(function() { - w.emit("requestTimeout"), w._fetchAbortController && w._fetchAbortController.abort(); - }, _.requestTimeout)); - } - u.fetch(w._opts.url, { method: w._opts.method, headers: L, body: P || void 0, mode: "cors", credentials: _.withCredentials ? "include" : "same-origin", signal: Y }).then(function(B) { - w._fetchResponse = B, w._connect(); - }, function(B) { - u.clearTimeout(w._fetchTimer), w._destroyed || w.emit("error", B); - }); - } else { - var V = w._xhr = new u.XMLHttpRequest(); - try { - V.open(w._opts.method, w._opts.url, !0); - } catch (B) { - return void i.nextTick(function() { - w.emit("error", B); - }); - } - "responseType" in V && (V.responseType = w._mode.split(":")[0]), "withCredentials" in V && (V.withCredentials = !!_.withCredentials), w._mode === "text" && "overrideMimeType" in V && V.overrideMimeType("text/plain; charset=x-user-defined"), "requestTimeout" in _ && (V.timeout = _.requestTimeout, V.ontimeout = function() { - w.emit("requestTimeout"); - }), L.forEach(function(B) { - V.setRequestHeader(B[0], B[1]); - }), w._response = null, V.onreadystatechange = function() { - switch (V.readyState) { - case S.LOADING: - case S.DONE: - w._onXHRProgress(); - } - }, w._mode === "moz-chunked-arraybuffer" && (V.onprogress = function() { - w._onXHRProgress(); - }), V.onerror = function() { - w._destroyed || w.emit("error", new Error("XHR error")); - }; - try { - V.send(P); - } catch (B) { - return void i.nextTick(function() { - w.emit("error", B); - }); - } - } - } - }, v.prototype._onXHRProgress = function() { - h(this._xhr) && !this._destroyed && (this._response || this._connect(), this._response._onXHRProgress()); - }, v.prototype._connect = function() { - var w = this; - w._destroyed || (w._response = new y(w._xhr, w._fetchResponse, w._mode, w._fetchTimer), w._response.on("error", function(_) { - w.emit("error", _); - }), w.emit("response", w._response)); - }, v.prototype._write = function(w, _, O) { - this._body.push(w), O(); - }, v.prototype.abort = v.prototype.destroy = function() { - this._destroyed = !0, u.clearTimeout(this._fetchTimer), this._response && (this._response._destroyed = !0), this._xhr ? this._xhr.abort() : this._fetchAbortController && this._fetchAbortController.abort(); - }, v.prototype.end = function(w, _, O) { - typeof w == "function" && (O = w, w = void 0), d.Writable.prototype.end.call(this, w, _, O); - }, v.prototype.flushHeaders = function() { - }, v.prototype.setTimeout = function() { - }, v.prototype.setNoDelay = function() { - }, v.prototype.setSocketKeepAlive = function() { - }; - var b = ["accept-charset", "accept-encoding", "access-control-request-headers", "access-control-request-method", "connection", "content-length", "cookie", "cookie2", "date", "dnt", "expect", "host", "keep-alive", "origin", "referer", "te", "trailer", "transfer-encoding", "upgrade", "via"]; - }).call(this, n("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}, n("buffer").Buffer); - }, { "./capability": 81, "./response": 83, _process: 66, buffer: 23, inherits: 31, "readable-stream": 78, "to-arraybuffer": 86 }], 83: [function(n, o, p) { - (function(i, u, a) { - var c = n("./capability"), l = n("inherits"), f = n("readable-stream"), d = p.readyStates = { UNSENT: 0, OPENED: 1, HEADERS_RECEIVED: 2, LOADING: 3, DONE: 4 }, E = p.IncomingMessage = function(y, S, T, v) { - var h = this; - if (f.Readable.call(h), h._mode = T, h.headers = {}, h.rawHeaders = [], h.trailers = {}, h.rawTrailers = [], h.on("end", function() { - i.nextTick(function() { - h.emit("close"); - }); - }), T === "fetch") { - if (h._fetchResponse = S, h.url = S.url, h.statusCode = S.status, h.statusMessage = S.statusText, S.headers.forEach(function(P, L) { - h.headers[L.toLowerCase()] = P, h.rawHeaders.push(L, P); - }), c.writableStream) { - var b = new WritableStream({ write: function(P) { - return new Promise(function(L, Y) { - h._destroyed ? Y() : h.push(new a(P)) ? L() : h._resumeFetch = L; - }); - }, close: function() { - u.clearTimeout(v), h._destroyed || h.push(null); - }, abort: function(P) { - h._destroyed || h.emit("error", P); - } }); - try { - return void S.body.pipeTo(b).catch(function(P) { - u.clearTimeout(v), h._destroyed || h.emit("error", P); - }); - } catch { - } - } - var w = S.body.getReader(); - (function P() { - w.read().then(function(L) { - if (!h._destroyed) { - if (L.done) return u.clearTimeout(v), void h.push(null); - h.push(new a(L.value)), P(); - } - }).catch(function(L) { - u.clearTimeout(v), h._destroyed || h.emit("error", L); - }); - })(); - } else if (h._xhr = y, h._pos = 0, h.url = y.responseURL, h.statusCode = y.status, h.statusMessage = y.statusText, y.getAllResponseHeaders().split(/\r?\n/).forEach(function(P) { - var L = P.match(/^([^:]+):\s*(.*)/); - if (L) { - var Y = L[1].toLowerCase(); - Y === "set-cookie" ? (h.headers[Y] === void 0 && (h.headers[Y] = []), h.headers[Y].push(L[2])) : h.headers[Y] !== void 0 ? h.headers[Y] += ", " + L[2] : h.headers[Y] = L[2], h.rawHeaders.push(L[1], L[2]); - } - }), h._charset = "x-user-defined", !c.overrideMimeType) { - var _ = h.rawHeaders["mime-type"]; - if (_) { - var O = _.match(/;\s*charset=([^;])(;|$)/); - O && (h._charset = O[1].toLowerCase()); - } - h._charset || (h._charset = "utf-8"); - } - }; - l(E, f.Readable), E.prototype._read = function() { - var y = this._resumeFetch; - y && (this._resumeFetch = null, y()); - }, E.prototype._onXHRProgress = function() { - var y = this, S = y._xhr, T = null; - switch (y._mode) { - case "text:vbarray": - if (S.readyState !== d.DONE) break; - try { - T = new u.VBArray(S.responseBody).toArray(); - } catch { - } - if (T !== null) { - y.push(new a(T)); - break; - } - case "text": - try { - T = S.responseText; - } catch { - y._mode = "text:vbarray"; - break; - } - if (T.length > y._pos) { - var v = T.substr(y._pos); - if (y._charset === "x-user-defined") { - for (var h = new a(v.length), b = 0; b < v.length; b++) h[b] = 255 & v.charCodeAt(b); - y.push(h); - } else y.push(v, y._charset); - y._pos = T.length; - } - break; - case "arraybuffer": - if (S.readyState !== d.DONE || !S.response) break; - T = S.response, y.push(new a(new Uint8Array(T))); - break; - case "moz-chunked-arraybuffer": - if (T = S.response, S.readyState !== d.LOADING || !T) break; - y.push(new a(new Uint8Array(T))); - break; - case "ms-stream": - if (T = S.response, S.readyState !== d.LOADING) break; - var w = new u.MSStreamReader(); - w.onprogress = function() { - w.result.byteLength > y._pos && (y.push(new a(new Uint8Array(w.result.slice(y._pos)))), y._pos = w.result.byteLength); - }, w.onload = function() { - y.push(null); - }, w.readAsArrayBuffer(T); - } - y._xhr.readyState === d.DONE && y._mode !== "ms-stream" && y.push(null); - }; - }).call(this, n("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}, n("buffer").Buffer); - }, { "./capability": 81, _process: 66, buffer: 23, inherits: 31, "readable-stream": 78 }], 84: [function(n, o, p) { - var i = n("safe-buffer").Buffer, u = i.isEncoding || function(P) { - switch ((P = "" + P) && P.toLowerCase()) { - case "hex": - case "utf8": - case "utf-8": - case "ascii": - case "binary": - case "base64": - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - case "raw": - return !0; - default: - return !1; - } - }; - function a(P) { - if (!P) return "utf8"; - for (var L; ; ) switch (P) { - case "utf8": - case "utf-8": - return "utf8"; - case "ucs2": - case "ucs-2": - case "utf16le": - case "utf-16le": - return "utf16le"; - case "latin1": - case "binary": - return "latin1"; - case "base64": - case "ascii": - case "hex": - return P; - default: - if (L) return; - P = ("" + P).toLowerCase(), L = !0; - } - } - function c(P) { - var L = a(P); - if (typeof L != "string" && (i.isEncoding === u || !u(P))) throw new Error("Unknown encoding: " + P); - return L || P; - } - function l(P) { - var L; - switch (this.encoding = c(P), this.encoding) { - case "utf16le": - this.text = v, this.end = h, L = 4; - break; - case "utf8": - this.fillLast = y, L = 4; - break; - case "base64": - this.text = b, this.end = w, L = 3; - break; - default: - return this.write = _, void (this.end = O); - } - this.lastNeed = 0, this.lastTotal = 0, this.lastChar = i.allocUnsafe(L); - } - function f(P) { - return P <= 127 ? 0 : P >> 5 == 6 ? 2 : P >> 4 == 14 ? 3 : P >> 3 == 30 ? 4 : P >> 6 == 2 ? -1 : -2; - } - function d(P, L, Y) { - var H = L.length - 1; - if (H < Y) return 0; - var V = f(L[H]); - return V >= 0 ? (V > 0 && (P.lastNeed = V - 1), V) : --H < Y || V === -2 ? 0 : (V = f(L[H])) >= 0 ? (V > 0 && (P.lastNeed = V - 2), V) : --H < Y || V === -2 ? 0 : (V = f(L[H])) >= 0 ? (V > 0 && (V === 2 ? V = 0 : P.lastNeed = V - 3), V) : 0; - } - function E(P, L, Y) { - if ((192 & L[0]) != 128) return P.lastNeed = 0, "�"; - if (P.lastNeed > 1 && L.length > 1) { - if ((192 & L[1]) != 128) return P.lastNeed = 1, "�"; - if (P.lastNeed > 2 && L.length > 2 && (192 & L[2]) != 128) return P.lastNeed = 2, "�"; - } - } - function y(P) { - var L = this.lastTotal - this.lastNeed, Y = E(this, P); - return Y !== void 0 ? Y : this.lastNeed <= P.length ? (P.copy(this.lastChar, L, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal)) : (P.copy(this.lastChar, L, 0, P.length), void (this.lastNeed -= P.length)); - } - function S(P, L) { - var Y = d(this, P, L); - if (!this.lastNeed) return P.toString("utf8", L); - this.lastTotal = Y; - var H = P.length - (Y - this.lastNeed); - return P.copy(this.lastChar, 0, H), P.toString("utf8", L, H); - } - function T(P) { - var L = P && P.length ? this.write(P) : ""; - return this.lastNeed ? L + "�" : L; - } - function v(P, L) { - if ((P.length - L) % 2 == 0) { - var Y = P.toString("utf16le", L); - if (Y) { - var H = Y.charCodeAt(Y.length - 1); - if (H >= 55296 && H <= 56319) return this.lastNeed = 2, this.lastTotal = 4, this.lastChar[0] = P[P.length - 2], this.lastChar[1] = P[P.length - 1], Y.slice(0, -1); - } - return Y; - } - return this.lastNeed = 1, this.lastTotal = 2, this.lastChar[0] = P[P.length - 1], P.toString("utf16le", L, P.length - 1); - } - function h(P) { - var L = P && P.length ? this.write(P) : ""; - if (this.lastNeed) { - var Y = this.lastTotal - this.lastNeed; - return L + this.lastChar.toString("utf16le", 0, Y); - } - return L; - } - function b(P, L) { - var Y = (P.length - L) % 3; - return Y === 0 ? P.toString("base64", L) : (this.lastNeed = 3 - Y, this.lastTotal = 3, Y === 1 ? this.lastChar[0] = P[P.length - 1] : (this.lastChar[0] = P[P.length - 2], this.lastChar[1] = P[P.length - 1]), P.toString("base64", L, P.length - Y)); - } - function w(P) { - var L = P && P.length ? this.write(P) : ""; - return this.lastNeed ? L + this.lastChar.toString("base64", 0, 3 - this.lastNeed) : L; - } - function _(P) { - return P.toString(this.encoding); - } - function O(P) { - return P && P.length ? this.write(P) : ""; - } - p.StringDecoder = l, l.prototype.write = function(P) { - if (P.length === 0) return ""; - var L, Y; - if (this.lastNeed) { - if ((L = this.fillLast(P)) === void 0) return ""; - Y = this.lastNeed, this.lastNeed = 0; - } else Y = 0; - return Y < P.length ? L ? L + this.text(P, Y) : this.text(P, Y) : L || ""; - }, l.prototype.end = T, l.prototype.text = S, l.prototype.fillLast = function(P) { - if (this.lastNeed <= P.length) return P.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal); - P.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, P.length), this.lastNeed -= P.length; - }; - }, { "safe-buffer": 79 }], 85: [function(n, o, p) { - (function(i, u) { - var a = n("process/browser.js").nextTick, c = Function.prototype.apply, l = Array.prototype.slice, f = {}, d = 0; - function E(y, S) { - this._id = y, this._clearFn = S; - } - p.setTimeout = function() { - return new E(c.call(setTimeout, window, arguments), clearTimeout); - }, p.setInterval = function() { - return new E(c.call(setInterval, window, arguments), clearInterval); - }, p.clearTimeout = p.clearInterval = function(y) { - y.close(); - }, E.prototype.unref = E.prototype.ref = function() { - }, E.prototype.close = function() { - this._clearFn.call(window, this._id); - }, p.enroll = function(y, S) { - clearTimeout(y._idleTimeoutId), y._idleTimeout = S; - }, p.unenroll = function(y) { - clearTimeout(y._idleTimeoutId), y._idleTimeout = -1; - }, p._unrefActive = p.active = function(y) { - clearTimeout(y._idleTimeoutId); - var S = y._idleTimeout; - S >= 0 && (y._idleTimeoutId = setTimeout(function() { - y._onTimeout && y._onTimeout(); - }, S)); - }, p.setImmediate = typeof i == "function" ? i : function(y) { - var S = d++, T = !(arguments.length < 2) && l.call(arguments, 1); - return f[S] = !0, a(function() { - f[S] && (T ? y.apply(null, T) : y.call(null), p.clearImmediate(S)); - }), S; - }, p.clearImmediate = typeof u == "function" ? u : function(y) { - delete f[y]; - }; - }).call(this, n("timers").setImmediate, n("timers").clearImmediate); - }, { "process/browser.js": 66, timers: 85 }], 86: [function(n, o, p) { - var i = n("buffer").Buffer; - o.exports = function(u) { - if (u instanceof Uint8Array) { - if (u.byteOffset === 0 && u.byteLength === u.buffer.byteLength) return u.buffer; - if (typeof u.buffer.slice == "function") return u.buffer.slice(u.byteOffset, u.byteOffset + u.byteLength); - } - if (i.isBuffer(u)) { - for (var a = new Uint8Array(u.length), c = u.length, l = 0; l < c; l++) a[l] = u[l]; - return a.buffer; - } - throw new Error("Argument must be a Buffer"); - }; - }, { buffer: 23 }], 87: [function(n, o, p) { - var i = n("punycode"), u = n("./util"); - function a() { - this.protocol = null, this.slashes = null, this.auth = null, this.host = null, this.port = null, this.hostname = null, this.hash = null, this.search = null, this.query = null, this.pathname = null, this.path = null, this.href = null; - } - p.parse = L, p.resolve = H, p.resolveObject = V, p.format = Y, p.Url = a; - var c = /^([a-z0-9.+-]+:)/i, l = /:[0-9]*$/, f = /^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/, d = ["<", ">", '"', "`", " ", "\r", ` -`, " "], E = ["{", "}", "|", "\\", "^", "`"].concat(d), y = ["'"].concat(E), S = ["%", "/", "?", ";", "#"].concat(y), T = ["/", "?", "#"], v = 255, h = /^[+a-z0-9A-Z_-]{0,63}$/, b = /^([+a-z0-9A-Z_-]{0,63})(.*)$/, w = { javascript: !0, "javascript:": !0 }, _ = { javascript: !0, "javascript:": !0 }, O = { http: !0, https: !0, ftp: !0, gopher: !0, file: !0, "http:": !0, "https:": !0, "ftp:": !0, "gopher:": !0, "file:": !0 }, P = n("querystring"); - function L(B, ne, I) { - if (B && u.isObject(B) && B instanceof a) return B; - var Z = new a(); - return Z.parse(B, ne, I), Z; - } - function Y(B) { - return u.isString(B) && (B = L(B)), B instanceof a ? B.format() : a.prototype.format.call(B); - } - function H(B, ne) { - return L(B, !1, !0).resolve(ne); - } - function V(B, ne) { - return B ? L(B, !1, !0).resolveObject(ne) : ne; - } - a.prototype.parse = function(B, ne, I) { - if (!u.isString(B)) throw new TypeError("Parameter 'url' must be a string, not " + typeof B); - var Z = B.indexOf("?"), te = Z !== -1 && Z < B.indexOf("#") ? "?" : "#", he = B.split(te); - he[0] = he[0].replace(/\\/g, "/"); - var le = B = he.join(te); - if (le = le.trim(), !I && B.split("#").length === 1) { - var ve = f.exec(le); - if (ve) return this.path = le, this.href = le, this.pathname = ve[1], ve[2] ? (this.search = ve[2], this.query = ne ? P.parse(this.search.substr(1)) : this.search.substr(1)) : ne && (this.search = "", this.query = {}), this; - } - var oe = c.exec(le); - if (oe) { - var fe = (oe = oe[0]).toLowerCase(); - this.protocol = fe, le = le.substr(oe.length); - } - if (I || oe || le.match(/^\/\/[^@\/]+@[^@\/]+/)) { - var j = le.substr(0, 2) === "//"; - !j || oe && _[oe] || (le = le.substr(2), this.slashes = !0); - } - if (!_[oe] && (j || oe && !O[oe])) { - for (var ie, pe, se = -1, W = 0; W < T.length; W++) - (G = le.indexOf(T[W])) !== -1 && (se === -1 || G < se) && (se = G); - for ((pe = se === -1 ? le.lastIndexOf("@") : le.lastIndexOf("@", se)) !== -1 && (ie = le.slice(0, pe), le = le.slice(pe + 1), this.auth = decodeURIComponent(ie)), se = -1, W = 0; W < S.length; W++) { - var G; - (G = le.indexOf(S[W])) !== -1 && (se === -1 || G < se) && (se = G); - } - se === -1 && (se = le.length), this.host = le.slice(0, se), le = le.slice(se), this.parseHost(), this.hostname = this.hostname || ""; - var ae = this.hostname[0] === "[" && this.hostname[this.hostname.length - 1] === "]"; - if (!ae) for (var ge = this.hostname.split(/\./), Ee = (W = 0, ge.length); W < Ee; W++) { - var ye = ge[W]; - if (ye && !ye.match(h)) { - for (var Oe = "", Ae = 0, Te = ye.length; Ae < Te; Ae++) ye.charCodeAt(Ae) > 127 ? Oe += "x" : Oe += ye[Ae]; - if (!Oe.match(h)) { - var U = ge.slice(0, W), q = ge.slice(W + 1), de = ye.match(b); - de && (U.push(de[1]), q.unshift(de[2])), q.length && (le = "/" + q.join(".") + le), this.hostname = U.join("."); - break; - } - } - } - this.hostname.length > v ? this.hostname = "" : this.hostname = this.hostname.toLowerCase(), ae || (this.hostname = i.toASCII(this.hostname)); - var F = this.port ? ":" + this.port : "", ce = this.hostname || ""; - this.host = ce + F, this.href += this.host, ae && (this.hostname = this.hostname.substr(1, this.hostname.length - 2), le[0] !== "/" && (le = "/" + le)); - } - if (!w[fe]) for (W = 0, Ee = y.length; W < Ee; W++) { - var m = y[W]; - if (le.indexOf(m) !== -1) { - var A = encodeURIComponent(m); - A === m && (A = escape(m)), le = le.split(m).join(A); - } - } - var R = le.indexOf("#"); - R !== -1 && (this.hash = le.substr(R), le = le.slice(0, R)); - var K = le.indexOf("?"); - if (K !== -1 ? (this.search = le.substr(K), this.query = le.substr(K + 1), ne && (this.query = P.parse(this.query)), le = le.slice(0, K)) : ne && (this.search = "", this.query = {}), le && (this.pathname = le), O[fe] && this.hostname && !this.pathname && (this.pathname = "/"), this.pathname || this.search) { - F = this.pathname || ""; - var Q = this.search || ""; - this.path = F + Q; - } - return this.href = this.format(), this; - }, a.prototype.format = function() { - var B = this.auth || ""; - B && (B = (B = encodeURIComponent(B)).replace(/%3A/i, ":"), B += "@"); - var ne = this.protocol || "", I = this.pathname || "", Z = this.hash || "", te = !1, he = ""; - this.host ? te = B + this.host : this.hostname && (te = B + (this.hostname.indexOf(":") === -1 ? this.hostname : "[" + this.hostname + "]"), this.port && (te += ":" + this.port)), this.query && u.isObject(this.query) && Object.keys(this.query).length && (he = P.stringify(this.query)); - var le = this.search || he && "?" + he || ""; - return ne && ne.substr(-1) !== ":" && (ne += ":"), this.slashes || (!ne || O[ne]) && te !== !1 ? (te = "//" + (te || ""), I && I.charAt(0) !== "/" && (I = "/" + I)) : te || (te = ""), Z && Z.charAt(0) !== "#" && (Z = "#" + Z), le && le.charAt(0) !== "?" && (le = "?" + le), ne + te + (I = I.replace(/[?#]/g, function(ve) { - return encodeURIComponent(ve); - })) + (le = le.replace("#", "%23")) + Z; - }, a.prototype.resolve = function(B) { - return this.resolveObject(L(B, !1, !0)).format(); - }, a.prototype.resolveObject = function(B) { - if (u.isString(B)) { - var ne = new a(); - ne.parse(B, !1, !0), B = ne; - } - for (var I = new a(), Z = Object.keys(this), te = 0; te < Z.length; te++) { - var he = Z[te]; - I[he] = this[he]; - } - if (I.hash = B.hash, B.href === "") return I.href = I.format(), I; - if (B.slashes && !B.protocol) { - for (var le = Object.keys(B), ve = 0; ve < le.length; ve++) { - var oe = le[ve]; - oe !== "protocol" && (I[oe] = B[oe]); - } - return O[I.protocol] && I.hostname && !I.pathname && (I.path = I.pathname = "/"), I.href = I.format(), I; - } - if (B.protocol && B.protocol !== I.protocol) { - if (!O[B.protocol]) { - for (var fe = Object.keys(B), j = 0; j < fe.length; j++) { - var ie = fe[j]; - I[ie] = B[ie]; - } - return I.href = I.format(), I; - } - if (I.protocol = B.protocol, B.host || _[B.protocol]) I.pathname = B.pathname; - else { - for (var pe = (B.pathname || "").split("/"); pe.length && !(B.host = pe.shift()); ) ; - B.host || (B.host = ""), B.hostname || (B.hostname = ""), pe[0] !== "" && pe.unshift(""), pe.length < 2 && pe.unshift(""), I.pathname = pe.join("/"); - } - if (I.search = B.search, I.query = B.query, I.host = B.host || "", I.auth = B.auth, I.hostname = B.hostname || B.host, I.port = B.port, I.pathname || I.search) { - var se = I.pathname || "", W = I.search || ""; - I.path = se + W; - } - return I.slashes = I.slashes || B.slashes, I.href = I.format(), I; - } - var G = I.pathname && I.pathname.charAt(0) === "/", ae = B.host || B.pathname && B.pathname.charAt(0) === "/", ge = ae || G || I.host && B.pathname, Ee = ge, ye = I.pathname && I.pathname.split("/") || [], Oe = (pe = B.pathname && B.pathname.split("/") || [], I.protocol && !O[I.protocol]); - if (Oe && (I.hostname = "", I.port = null, I.host && (ye[0] === "" ? ye[0] = I.host : ye.unshift(I.host)), I.host = "", B.protocol && (B.hostname = null, B.port = null, B.host && (pe[0] === "" ? pe[0] = B.host : pe.unshift(B.host)), B.host = null), ge = ge && (pe[0] === "" || ye[0] === "")), ae) I.host = B.host || B.host === "" ? B.host : I.host, I.hostname = B.hostname || B.hostname === "" ? B.hostname : I.hostname, I.search = B.search, I.query = B.query, ye = pe; - else if (pe.length) ye || (ye = []), ye.pop(), ye = ye.concat(pe), I.search = B.search, I.query = B.query; - else if (!u.isNullOrUndefined(B.search)) - return Oe && (I.hostname = I.host = ye.shift(), (de = !!(I.host && I.host.indexOf("@") > 0) && I.host.split("@")) && (I.auth = de.shift(), I.host = I.hostname = de.shift())), I.search = B.search, I.query = B.query, u.isNull(I.pathname) && u.isNull(I.search) || (I.path = (I.pathname ? I.pathname : "") + (I.search ? I.search : "")), I.href = I.format(), I; - if (!ye.length) return I.pathname = null, I.search ? I.path = "/" + I.search : I.path = null, I.href = I.format(), I; - for (var Ae = ye.slice(-1)[0], Te = (I.host || B.host || ye.length > 1) && (Ae === "." || Ae === "..") || Ae === "", U = 0, q = ye.length; q >= 0; q--) (Ae = ye[q]) === "." ? ye.splice(q, 1) : Ae === ".." ? (ye.splice(q, 1), U++) : U && (ye.splice(q, 1), U--); - if (!ge && !Ee) for (; U--; U) ye.unshift(".."); - !ge || ye[0] === "" || ye[0] && ye[0].charAt(0) === "/" || ye.unshift(""), Te && ye.join("/").substr(-1) !== "/" && ye.push(""); - var de, F = ye[0] === "" || ye[0] && ye[0].charAt(0) === "/"; - return Oe && (I.hostname = I.host = F ? "" : ye.length ? ye.shift() : "", (de = !!(I.host && I.host.indexOf("@") > 0) && I.host.split("@")) && (I.auth = de.shift(), I.host = I.hostname = de.shift())), (ge = ge || I.host && ye.length) && !F && ye.unshift(""), ye.length ? I.pathname = ye.join("/") : (I.pathname = null, I.path = null), u.isNull(I.pathname) && u.isNull(I.search) || (I.path = (I.pathname ? I.pathname : "") + (I.search ? I.search : "")), I.auth = B.auth || I.auth, I.slashes = I.slashes || B.slashes, I.href = I.format(), I; - }, a.prototype.parseHost = function() { - var B = this.host, ne = l.exec(B); - ne && ((ne = ne[0]) !== ":" && (this.port = ne.substr(1)), B = B.substr(0, B.length - ne.length)), B && (this.hostname = B); - }; - }, { "./util": 88, punycode: 22, querystring: 69 }], 88: [function(n, o, p) { - o.exports = { isString: function(i) { - return typeof i == "string"; - }, isObject: function(i) { - return typeof i == "object" && i !== null; - }, isNull: function(i) { - return i === null; - }, isNullOrUndefined: function(i) { - return i == null; - } }; - }, {}], 89: [function(n, o, p) { - (function(i) { - function u(c, l) { - if (a("noDeprecation")) return c; - var f = !1; - return function() { - if (!f) { - if (a("throwDeprecation")) throw new Error(l); - a("traceDeprecation") ? console.trace(l) : console.warn(l), f = !0; - } - return c.apply(this, arguments); - }; - } - function a(c) { - try { - if (!i.localStorage) return !1; - } catch { - return !1; - } - var l = i.localStorage[c]; - return l != null && String(l).toLowerCase() === "true"; - } - o.exports = u; - }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); - }, {}], 90: [function(n, o, p) { - o.exports = u; - var i = Object.prototype.hasOwnProperty; - function u() { - for (var a = {}, c = 0; c < arguments.length; c++) { - var l = arguments[c]; - for (var f in l) i.call(l, f) && (a[f] = l[f]); - } - return a; - } - }, {}] }, {}, [3])(3); - }), (function(n, o) { - o(s); - })(this, (function(n) { - class o { - static get version() { - return "1.4.0"; - } - static toString() { - return "JavaScript Expression Parser (JSEP) v" + o.version; - } - static addUnaryOp(h) { - return o.max_unop_len = Math.max(h.length, o.max_unop_len), o.unary_ops[h] = 1, o; - } - static addBinaryOp(h, b, w) { - return o.max_binop_len = Math.max(h.length, o.max_binop_len), o.binary_ops[h] = b, w ? o.right_associative.add(h) : o.right_associative.delete(h), o; - } - static addIdentifierChar(h) { - return o.additional_identifier_chars.add(h), o; - } - static addLiteral(h, b) { - return o.literals[h] = b, o; - } - static removeUnaryOp(h) { - return delete o.unary_ops[h], h.length === o.max_unop_len && (o.max_unop_len = o.getMaxKeyLen(o.unary_ops)), o; - } - static removeAllUnaryOps() { - return o.unary_ops = {}, o.max_unop_len = 0, o; - } - static removeIdentifierChar(h) { - return o.additional_identifier_chars.delete(h), o; - } - static removeBinaryOp(h) { - return delete o.binary_ops[h], h.length === o.max_binop_len && (o.max_binop_len = o.getMaxKeyLen(o.binary_ops)), o.right_associative.delete(h), o; - } - static removeAllBinaryOps() { - return o.binary_ops = {}, o.max_binop_len = 0, o; - } - static removeLiteral(h) { - return delete o.literals[h], o; - } - static removeAllLiterals() { - return o.literals = {}, o; - } - get char() { - return this.expr.charAt(this.index); - } - get code() { - return this.expr.charCodeAt(this.index); - } - constructor(h) { - this.expr = h, this.index = 0; - } - static parse(h) { - return new o(h).parse(); - } - static getMaxKeyLen(h) { - return Math.max(0, ...Object.keys(h).map(((b) => b.length))); - } - static isDecimalDigit(h) { - return h >= 48 && h <= 57; - } - static binaryPrecedence(h) { - return o.binary_ops[h] || 0; - } - static isIdentifierStart(h) { - return h >= 65 && h <= 90 || h >= 97 && h <= 122 || h >= 128 && !o.binary_ops[String.fromCharCode(h)] || o.additional_identifier_chars.has(String.fromCharCode(h)); - } - static isIdentifierPart(h) { - return o.isIdentifierStart(h) || o.isDecimalDigit(h); - } - throwError(h) { - const b = new Error(h + " at character " + this.index); - throw b.index = this.index, b.description = h, b; - } - runHook(h, b) { - if (o.hooks[h]) { - const w = { context: this, node: b }; - return o.hooks.run(h, w), w.node; - } - return b; - } - searchHook(h) { - if (o.hooks[h]) { - const b = { context: this }; - return o.hooks[h].find((function(w) { - return w.call(b.context, b), b.node; - })), b.node; - } - } - gobbleSpaces() { - let h = this.code; - for (; h === o.SPACE_CODE || h === o.TAB_CODE || h === o.LF_CODE || h === o.CR_CODE; ) h = this.expr.charCodeAt(++this.index); - this.runHook("gobble-spaces"); - } - parse() { - this.runHook("before-all"); - const h = this.gobbleExpressions(), b = h.length === 1 ? h[0] : { type: o.COMPOUND, body: h }; - return this.runHook("after-all", b); - } - gobbleExpressions(h) { - let b, w, _ = []; - for (; this.index < this.expr.length; ) if (b = this.code, b === o.SEMCOL_CODE || b === o.COMMA_CODE) this.index++; - else if (w = this.gobbleExpression()) _.push(w); - else if (this.index < this.expr.length) { - if (b === h) break; - this.throwError('Unexpected "' + this.char + '"'); - } - return _; - } - gobbleExpression() { - const h = this.searchHook("gobble-expression") || this.gobbleBinaryExpression(); - return this.gobbleSpaces(), this.runHook("after-expression", h); - } - gobbleBinaryOp() { - this.gobbleSpaces(); - let h = this.expr.substr(this.index, o.max_binop_len), b = h.length; - for (; b > 0; ) { - if (o.binary_ops.hasOwnProperty(h) && (!o.isIdentifierStart(this.code) || this.index + h.length < this.expr.length && !o.isIdentifierPart(this.expr.charCodeAt(this.index + h.length)))) return this.index += b, h; - h = h.substr(0, --b); - } - return !1; - } - gobbleBinaryExpression() { - let h, b, w, _, O, P, L, Y, H; - if (P = this.gobbleToken(), !P || (b = this.gobbleBinaryOp(), !b)) return P; - for (O = { value: b, prec: o.binaryPrecedence(b), right_a: o.right_associative.has(b) }, L = this.gobbleToken(), L || this.throwError("Expected expression after " + b), _ = [P, O, L]; b = this.gobbleBinaryOp(); ) { - if (w = o.binaryPrecedence(b), w === 0) { - this.index -= b.length; - break; - } - O = { value: b, prec: w, right_a: o.right_associative.has(b) }, H = b; - const V = (B) => O.right_a && B.right_a ? w > B.prec : w <= B.prec; - for (; _.length > 2 && V(_[_.length - 2]); ) L = _.pop(), b = _.pop().value, P = _.pop(), h = { type: o.BINARY_EXP, operator: b, left: P, right: L }, _.push(h); - h = this.gobbleToken(), h || this.throwError("Expected expression after " + H), _.push(O, h); - } - for (Y = _.length - 1, h = _[Y]; Y > 1; ) h = { type: o.BINARY_EXP, operator: _[Y - 1].value, left: _[Y - 2], right: h }, Y -= 2; - return h; - } - gobbleToken() { - let h, b, w, _; - if (this.gobbleSpaces(), _ = this.searchHook("gobble-token"), _) return this.runHook("after-token", _); - if (h = this.code, o.isDecimalDigit(h) || h === o.PERIOD_CODE) return this.gobbleNumericLiteral(); - if (h === o.SQUOTE_CODE || h === o.DQUOTE_CODE) _ = this.gobbleStringLiteral(); - else if (h === o.OBRACK_CODE) _ = this.gobbleArray(); - else { - for (b = this.expr.substr(this.index, o.max_unop_len), w = b.length; w > 0; ) { - if (o.unary_ops.hasOwnProperty(b) && (!o.isIdentifierStart(this.code) || this.index + b.length < this.expr.length && !o.isIdentifierPart(this.expr.charCodeAt(this.index + b.length)))) { - this.index += w; - const O = this.gobbleToken(); - return O || this.throwError("missing unaryOp argument"), this.runHook("after-token", { type: o.UNARY_EXP, operator: b, argument: O, prefix: !0 }); - } - b = b.substr(0, --w); - } - o.isIdentifierStart(h) ? (_ = this.gobbleIdentifier(), o.literals.hasOwnProperty(_.name) ? _ = { type: o.LITERAL, value: o.literals[_.name], raw: _.name } : _.name === o.this_str && (_ = { type: o.THIS_EXP })) : h === o.OPAREN_CODE && (_ = this.gobbleGroup()); - } - return _ ? (_ = this.gobbleTokenProperty(_), this.runHook("after-token", _)) : this.runHook("after-token", !1); - } - gobbleTokenProperty(h) { - this.gobbleSpaces(); - let b = this.code; - for (; b === o.PERIOD_CODE || b === o.OBRACK_CODE || b === o.OPAREN_CODE || b === o.QUMARK_CODE; ) { - let w; - if (b === o.QUMARK_CODE) { - if (this.expr.charCodeAt(this.index + 1) !== o.PERIOD_CODE) break; - w = !0, this.index += 2, this.gobbleSpaces(), b = this.code; - } - this.index++, b === o.OBRACK_CODE ? ((h = { type: o.MEMBER_EXP, computed: !0, object: h, property: this.gobbleExpression() }).property || this.throwError('Unexpected "' + this.char + '"'), this.gobbleSpaces(), b = this.code, b !== o.CBRACK_CODE && this.throwError("Unclosed ["), this.index++) : b === o.OPAREN_CODE ? h = { type: o.CALL_EXP, arguments: this.gobbleArguments(o.CPAREN_CODE), callee: h } : (b === o.PERIOD_CODE || w) && (w && this.index--, this.gobbleSpaces(), h = { type: o.MEMBER_EXP, computed: !1, object: h, property: this.gobbleIdentifier() }), w && (h.optional = !0), this.gobbleSpaces(), b = this.code; - } - return h; - } - gobbleNumericLiteral() { - let h, b, w = ""; - for (; o.isDecimalDigit(this.code); ) w += this.expr.charAt(this.index++); - if (this.code === o.PERIOD_CODE) for (w += this.expr.charAt(this.index++); o.isDecimalDigit(this.code); ) w += this.expr.charAt(this.index++); - if (h = this.char, h === "e" || h === "E") { - for (w += this.expr.charAt(this.index++), h = this.char, h !== "+" && h !== "-" || (w += this.expr.charAt(this.index++)); o.isDecimalDigit(this.code); ) w += this.expr.charAt(this.index++); - o.isDecimalDigit(this.expr.charCodeAt(this.index - 1)) || this.throwError("Expected exponent (" + w + this.char + ")"); - } - return b = this.code, o.isIdentifierStart(b) ? this.throwError("Variable names cannot start with a number (" + w + this.char + ")") : (b === o.PERIOD_CODE || w.length === 1 && w.charCodeAt(0) === o.PERIOD_CODE) && this.throwError("Unexpected period"), { type: o.LITERAL, value: parseFloat(w), raw: w }; - } - gobbleStringLiteral() { - let h = ""; - const b = this.index, w = this.expr.charAt(this.index++); - let _ = !1; - for (; this.index < this.expr.length; ) { - let O = this.expr.charAt(this.index++); - if (O === w) { - _ = !0; - break; - } - if (O === "\\") switch (O = this.expr.charAt(this.index++), O) { - case "n": - h += ` -`; - break; - case "r": - h += "\r"; - break; - case "t": - h += " "; - break; - case "b": - h += "\b"; - break; - case "f": - h += "\f"; - break; - case "v": - h += "\v"; - break; - default: - h += O; - } - else h += O; - } - return _ || this.throwError('Unclosed quote after "' + h + '"'), { type: o.LITERAL, value: h, raw: this.expr.substring(b, this.index) }; - } - gobbleIdentifier() { - let h = this.code, b = this.index; - for (o.isIdentifierStart(h) ? this.index++ : this.throwError("Unexpected " + this.char); this.index < this.expr.length && (h = this.code, o.isIdentifierPart(h)); ) this.index++; - return { type: o.IDENTIFIER, name: this.expr.slice(b, this.index) }; - } - gobbleArguments(h) { - const b = []; - let w = !1, _ = 0; - for (; this.index < this.expr.length; ) { - this.gobbleSpaces(); - let O = this.code; - if (O === h) { - w = !0, this.index++, h === o.CPAREN_CODE && _ && _ >= b.length && this.throwError("Unexpected token " + String.fromCharCode(h)); - break; - } - if (O === o.COMMA_CODE) { - if (this.index++, _++, _ !== b.length) { - if (h === o.CPAREN_CODE) this.throwError("Unexpected token ,"); - else if (h === o.CBRACK_CODE) for (let P = b.length; P < _; P++) b.push(null); - } - } else if (b.length !== _ && _ !== 0) this.throwError("Expected comma"); - else { - const P = this.gobbleExpression(); - P && P.type !== o.COMPOUND || this.throwError("Expected comma"), b.push(P); - } - } - return w || this.throwError("Expected " + String.fromCharCode(h)), b; - } - gobbleGroup() { - this.index++; - let h = this.gobbleExpressions(o.CPAREN_CODE); - if (this.code === o.CPAREN_CODE) return this.index++, h.length === 1 ? h[0] : !!h.length && { type: o.SEQUENCE_EXP, expressions: h }; - this.throwError("Unclosed ("); - } - gobbleArray() { - return this.index++, { type: o.ARRAY_EXP, elements: this.gobbleArguments(o.CBRACK_CODE) }; - } - } - const p = new class { - add(v, h, b) { - if (typeof arguments[0] != "string") for (let w in arguments[0]) this.add(w, arguments[0][w], arguments[1]); - else (Array.isArray(v) ? v : [v]).forEach((function(w) { - this[w] = this[w] || [], h && this[w][b ? "unshift" : "push"](h); - }), this); - } - run(v, h) { - this[v] = this[v] || [], this[v].forEach((function(b) { - b.call(h && h.context ? h.context : h, h); - })); - } - }(); - Object.assign(o, { hooks: p, plugins: new class { - constructor(v) { - this.jsep = v, this.registered = {}; - } - register() { - for (var v = arguments.length, h = new Array(v), b = 0; b < v; b++) h[b] = arguments[b]; - h.forEach(((w) => { - if (typeof w != "object" || !w.name || !w.init) throw new Error("Invalid JSEP plugin format"); - this.registered[w.name] || (w.init(this.jsep), this.registered[w.name] = w); - })); - } - }(o), COMPOUND: "Compound", SEQUENCE_EXP: "SequenceExpression", IDENTIFIER: "Identifier", MEMBER_EXP: "MemberExpression", LITERAL: "Literal", THIS_EXP: "ThisExpression", CALL_EXP: "CallExpression", UNARY_EXP: "UnaryExpression", BINARY_EXP: "BinaryExpression", ARRAY_EXP: "ArrayExpression", TAB_CODE: 9, LF_CODE: 10, CR_CODE: 13, SPACE_CODE: 32, PERIOD_CODE: 46, COMMA_CODE: 44, SQUOTE_CODE: 39, DQUOTE_CODE: 34, OPAREN_CODE: 40, CPAREN_CODE: 41, OBRACK_CODE: 91, CBRACK_CODE: 93, QUMARK_CODE: 63, SEMCOL_CODE: 59, COLON_CODE: 58, unary_ops: { "-": 1, "!": 1, "~": 1, "+": 1 }, binary_ops: { "||": 1, "??": 1, "&&": 2, "|": 3, "^": 4, "&": 5, "==": 6, "!=": 6, "===": 6, "!==": 6, "<": 7, ">": 7, "<=": 7, ">=": 7, "<<": 8, ">>": 8, ">>>": 8, "+": 9, "-": 9, "*": 10, "/": 10, "%": 10, "**": 11 }, right_associative: /* @__PURE__ */ new Set(["**"]), additional_identifier_chars: /* @__PURE__ */ new Set(["$", "_"]), literals: { true: !0, false: !1, null: null }, this_str: "this" }), o.max_unop_len = o.getMaxKeyLen(o.unary_ops), o.max_binop_len = o.getMaxKeyLen(o.binary_ops); - const i = (v) => new o(v).parse(), u = Object.getOwnPropertyNames(class { - }); - Object.getOwnPropertyNames(o).filter(((v) => !u.includes(v) && i[v] === void 0)).forEach(((v) => { - i[v] = o[v]; - })), i.Jsep = o; - var a = { name: "ternary", init(v) { - v.hooks.add("after-expression", (function(h) { - if (h.node && this.code === v.QUMARK_CODE) { - this.index++; - const b = h.node, w = this.gobbleExpression(); - if (w || this.throwError("Expected expression"), this.gobbleSpaces(), this.code === v.COLON_CODE) { - this.index++; - const _ = this.gobbleExpression(); - if (_ || this.throwError("Expected expression"), h.node = { type: "ConditionalExpression", test: b, consequent: w, alternate: _ }, b.operator && v.binary_ops[b.operator] <= 0.9) { - let O = b; - for (; O.right.operator && v.binary_ops[O.right.operator] <= 0.9; ) O = O.right; - h.node.test = O.right, O.right = h.node, h.node = b; - } - } else this.throwError("Expected :"); - } - })); - } }; - i.plugins.register(a); - var c = { name: "regex", init(v) { - v.hooks.add("gobble-token", (function(h) { - if (this.code === 47) { - const b = ++this.index; - let w = !1; - for (; this.index < this.expr.length; ) { - if (this.code === 47 && !w) { - const _ = this.expr.slice(b, this.index); - let O, P = ""; - for (; ++this.index < this.expr.length; ) { - const L = this.code; - if (!(L >= 97 && L <= 122 || L >= 65 && L <= 90 || L >= 48 && L <= 57)) break; - P += this.char; - } - try { - O = new RegExp(_, P); - } catch (L) { - this.throwError(L.message); - } - return h.node = { type: v.LITERAL, value: O, raw: this.expr.slice(b - 1, this.index) }, h.node = this.gobbleTokenProperty(h.node), h.node; - } - this.code === v.OBRACK_CODE ? w = !0 : w && this.code === v.CBRACK_CODE && (w = !1), this.index += this.code === 92 ? 2 : 1; - } - this.throwError("Unclosed Regex"); - } - })); - } }; - const l = { name: "assignment", assignmentOperators: /* @__PURE__ */ new Set(["=", "*=", "**=", "/=", "%=", "+=", "-=", "<<=", ">>=", ">>>=", "&=", "^=", "|=", "||=", "&&=", "??="]), updateOperators: [43, 45], assignmentPrecedence: 0.9, init(v) { - const h = [v.IDENTIFIER, v.MEMBER_EXP]; - function b(w) { - l.assignmentOperators.has(w.operator) ? (w.type = "AssignmentExpression", b(w.left), b(w.right)) : w.operator || Object.values(w).forEach(((_) => { - _ && typeof _ == "object" && b(_); - })); - } - l.assignmentOperators.forEach(((w) => v.addBinaryOp(w, l.assignmentPrecedence, !0))), v.hooks.add("gobble-token", (function(w) { - const _ = this.code; - l.updateOperators.some(((O) => O === _ && O === this.expr.charCodeAt(this.index + 1))) && (this.index += 2, w.node = { type: "UpdateExpression", operator: _ === 43 ? "++" : "--", argument: this.gobbleTokenProperty(this.gobbleIdentifier()), prefix: !0 }, w.node.argument && h.includes(w.node.argument.type) || this.throwError(`Unexpected ${w.node.operator}`)); - })), v.hooks.add("after-token", (function(w) { - if (w.node) { - const _ = this.code; - l.updateOperators.some(((O) => O === _ && O === this.expr.charCodeAt(this.index + 1))) && (h.includes(w.node.type) || this.throwError(`Unexpected ${w.node.operator}`), this.index += 2, w.node = { type: "UpdateExpression", operator: _ === 43 ? "++" : "--", argument: w.node, prefix: !1 }); - } - })), v.hooks.add("after-expression", (function(w) { - w.node && b(w.node); - })); - } }; - i.plugins.register(c, l), i.addUnaryOp("typeof"), i.addLiteral("null", null), i.addLiteral("undefined", void 0); - const f = /* @__PURE__ */ new Set(["constructor", "__proto__", "__defineGetter__", "__defineSetter__"]), d = { evalAst(v, h) { - switch (v.type) { - case "BinaryExpression": - case "LogicalExpression": - return d.evalBinaryExpression(v, h); - case "Compound": - return d.evalCompound(v, h); - case "ConditionalExpression": - return d.evalConditionalExpression(v, h); - case "Identifier": - return d.evalIdentifier(v, h); - case "Literal": - return d.evalLiteral(v, h); - case "MemberExpression": - return d.evalMemberExpression(v, h); - case "UnaryExpression": - return d.evalUnaryExpression(v, h); - case "ArrayExpression": - return d.evalArrayExpression(v, h); - case "CallExpression": - return d.evalCallExpression(v, h); - case "AssignmentExpression": - return d.evalAssignmentExpression(v, h); - default: - throw SyntaxError("Unexpected expression", v); - } - }, evalBinaryExpression: (v, h) => ({ "||": (b, w) => b || w(), "&&": (b, w) => b && w(), "|": (b, w) => b | w(), "^": (b, w) => b ^ w(), "&": (b, w) => b & w(), "==": (b, w) => b == w(), "!=": (b, w) => b != w(), "===": (b, w) => b === w(), "!==": (b, w) => b !== w(), "<": (b, w) => b < w(), ">": (b, w) => b > w(), "<=": (b, w) => b <= w(), ">=": (b, w) => b >= w(), "<<": (b, w) => b << w(), ">>": (b, w) => b >> w(), ">>>": (b, w) => b >>> w(), "+": (b, w) => b + w(), "-": (b, w) => b - w(), "*": (b, w) => b * w(), "/": (b, w) => b / w(), "%": (b, w) => b % w() })[v.operator](d.evalAst(v.left, h), (() => d.evalAst(v.right, h))), evalCompound(v, h) { - let b; - for (let w = 0; w < v.body.length; w++) { - v.body[w].type === "Identifier" && ["var", "let", "const"].includes(v.body[w].name) && v.body[w + 1] && v.body[w + 1].type === "AssignmentExpression" && (w += 1); - const _ = v.body[w]; - b = d.evalAst(_, h); - } - return b; - }, evalConditionalExpression: (v, h) => d.evalAst(v.test, h) ? d.evalAst(v.consequent, h) : d.evalAst(v.alternate, h), evalIdentifier(v, h) { - if (Object.hasOwn(h, v.name)) return h[v.name]; - throw ReferenceError(`${v.name} is not defined`); - }, evalLiteral: (v) => v.value, evalMemberExpression(v, h) { - const b = String(v.computed ? d.evalAst(v.property) : v.property.name), w = d.evalAst(v.object, h); - if (w == null) throw TypeError(`Cannot read properties of ${w} (reading '${b}')`); - if (!Object.hasOwn(w, b) && f.has(b)) throw TypeError(`Cannot read properties of ${w} (reading '${b}')`); - const _ = w[b]; - return typeof _ == "function" ? _.bind(w) : _; - }, evalUnaryExpression: (v, h) => ({ "-": (b) => -d.evalAst(b, h), "!": (b) => !d.evalAst(b, h), "~": (b) => ~d.evalAst(b, h), "+": (b) => +d.evalAst(b, h), typeof: (b) => typeof d.evalAst(b, h) })[v.operator](v.argument), evalArrayExpression: (v, h) => v.elements.map(((b) => d.evalAst(b, h))), evalCallExpression(v, h) { - const b = v.arguments.map(((w) => d.evalAst(w, h))); - return d.evalAst(v.callee, h)(...b); - }, evalAssignmentExpression(v, h) { - if (v.left.type !== "Identifier") throw SyntaxError("Invalid left-hand side in assignment"); - const b = v.left.name, w = d.evalAst(v.right, h); - return h[b] = w, h[b]; - } }; - function E(v, h) { - return (v = v.slice()).push(h), v; - } - function y(v, h) { - return (h = h.slice()).unshift(v), h; - } - class S extends Error { - constructor(h) { - super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'), this.avoidNew = !0, this.value = h, this.name = "NewError"; - } - } - function T(v, h, b, w, _) { - if (!(this instanceof T)) try { - return new T(v, h, b, w, _); - } catch (P) { - if (!P.avoidNew) throw P; - return P.value; - } - typeof v == "string" && (_ = w, w = b, b = h, h = v, v = null); - const O = v && typeof v == "object"; - if (v = v || {}, this.json = v.json || b, this.path = v.path || h, this.resultType = v.resultType || "value", this.flatten = v.flatten || !1, this.wrap = !Object.hasOwn(v, "wrap") || v.wrap, this.sandbox = v.sandbox || {}, this.eval = v.eval === void 0 ? "safe" : v.eval, this.ignoreEvalErrors = v.ignoreEvalErrors !== void 0 && v.ignoreEvalErrors, this.parent = v.parent || null, this.parentProperty = v.parentProperty || null, this.callback = v.callback || w || null, this.otherTypeCallback = v.otherTypeCallback || _ || function() { - throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator."); - }, v.autostart !== !1) { - const P = { path: O ? v.path : h }; - O ? "json" in v && (P.json = v.json) : P.json = b; - const L = this.evaluate(P); - if (!L || typeof L != "object") throw new S(L); - return L; - } - } - T.prototype.evaluate = function(v, h, b, w) { - let _ = this.parent, O = this.parentProperty, { flatten: P, wrap: L } = this; - if (this.currResultType = this.resultType, this.currEval = this.eval, this.currSandbox = this.sandbox, b = b || this.callback, this.currOtherTypeCallback = w || this.otherTypeCallback, h = h || this.json, (v = v || this.path) && typeof v == "object" && !Array.isArray(v)) { - if (!v.path && v.path !== "") throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().'); - if (!Object.hasOwn(v, "json")) throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().'); - ({ json: h } = v), P = Object.hasOwn(v, "flatten") ? v.flatten : P, this.currResultType = Object.hasOwn(v, "resultType") ? v.resultType : this.currResultType, this.currSandbox = Object.hasOwn(v, "sandbox") ? v.sandbox : this.currSandbox, L = Object.hasOwn(v, "wrap") ? v.wrap : L, this.currEval = Object.hasOwn(v, "eval") ? v.eval : this.currEval, b = Object.hasOwn(v, "callback") ? v.callback : b, this.currOtherTypeCallback = Object.hasOwn(v, "otherTypeCallback") ? v.otherTypeCallback : this.currOtherTypeCallback, _ = Object.hasOwn(v, "parent") ? v.parent : _, O = Object.hasOwn(v, "parentProperty") ? v.parentProperty : O, v = v.path; - } - if (_ = _ || null, O = O || null, Array.isArray(v) && (v = T.toPathString(v)), !v && v !== "" || !h) return; - const Y = T.toPathArray(v); - Y[0] === "$" && Y.length > 1 && Y.shift(), this._hasParentSelector = null; - const H = this._trace(Y, h, ["$"], _, O, b).filter((function(V) { - return V && !V.isParentSelector; - })); - return H.length ? L || H.length !== 1 || H[0].hasArrExpr ? H.reduce(((V, B) => { - const ne = this._getPreferredOutput(B); - return P && Array.isArray(ne) ? V = V.concat(ne) : V.push(ne), V; - }), []) : this._getPreferredOutput(H[0]) : L ? [] : void 0; - }, T.prototype._getPreferredOutput = function(v) { - const h = this.currResultType; - switch (h) { - case "all": { - const b = Array.isArray(v.path) ? v.path : T.toPathArray(v.path); - return v.pointer = T.toPointer(b), v.path = typeof v.path == "string" ? v.path : T.toPathString(v.path), v; - } - case "value": - case "parent": - case "parentProperty": - return v[h]; - case "path": - return T.toPathString(v[h]); - case "pointer": - return T.toPointer(v.path); - default: - throw new TypeError("Unknown result type"); - } - }, T.prototype._handleCallback = function(v, h, b) { - if (h) { - const w = this._getPreferredOutput(v); - v.path = typeof v.path == "string" ? v.path : T.toPathString(v.path), h(w, b, v); - } - }, T.prototype._trace = function(v, h, b, w, _, O, P, L) { - let Y; - if (!v.length) return Y = { path: b, value: h, parent: w, parentProperty: _, hasArrExpr: P }, this._handleCallback(Y, O, "value"), Y; - const H = v[0], V = v.slice(1), B = []; - function ne(I) { - Array.isArray(I) ? I.forEach(((Z) => { - B.push(Z); - })) : B.push(I); - } - if ((typeof H != "string" || L) && h && Object.hasOwn(h, H)) ne(this._trace(V, h[H], E(b, H), h, H, O, P)); - else if (H === "*") this._walk(h, ((I) => { - ne(this._trace(V, h[I], E(b, I), h, I, O, !0, !0)); - })); - else if (H === "..") ne(this._trace(V, h, b, w, _, O, P)), this._walk(h, ((I) => { - typeof h[I] == "object" && ne(this._trace(v.slice(), h[I], E(b, I), h, I, O, !0)); - })); - else { - if (H === "^") return this._hasParentSelector = !0, { path: b.slice(0, -1), expr: V, isParentSelector: !0 }; - if (H === "~") return Y = { path: E(b, H), value: _, parent: w, parentProperty: null }, this._handleCallback(Y, O, "property"), Y; - if (H === "$") ne(this._trace(V, h, b, null, null, O, P)); - else if (/^(-?\d*):(-?\d*):?(\d*)$/u.test(H)) ne(this._slice(H, V, h, b, w, _, O)); - else if (H.indexOf("?(") === 0) { - if (this.currEval === !1) throw new Error("Eval [?(expr)] prevented in JSONPath expression."); - const I = H.replace(/^\?\((.*?)\)$/u, "$1"), Z = /@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(I); - Z ? this._walk(h, ((te) => { - const he = [Z[2]], le = Z[1] ? h[te][Z[1]] : h[te]; - this._trace(he, le, b, w, _, O, !0).length > 0 && ne(this._trace(V, h[te], E(b, te), h, te, O, !0)); - })) : this._walk(h, ((te) => { - this._eval(I, h[te], te, b, w, _) && ne(this._trace(V, h[te], E(b, te), h, te, O, !0)); - })); - } else if (H[0] === "(") { - if (this.currEval === !1) throw new Error("Eval [(expr)] prevented in JSONPath expression."); - ne(this._trace(y(this._eval(H, h, b.at(-1), b.slice(0, -1), w, _), V), h, b, w, _, O, P)); - } else if (H[0] === "@") { - let I = !1; - const Z = H.slice(1, -2); - switch (Z) { - case "scalar": - h && ["object", "function"].includes(typeof h) || (I = !0); - break; - case "boolean": - case "string": - case "undefined": - case "function": - typeof h === Z && (I = !0); - break; - case "integer": - !Number.isFinite(h) || h % 1 || (I = !0); - break; - case "number": - Number.isFinite(h) && (I = !0); - break; - case "nonFinite": - typeof h != "number" || Number.isFinite(h) || (I = !0); - break; - case "object": - h && typeof h === Z && (I = !0); - break; - case "array": - Array.isArray(h) && (I = !0); - break; - case "other": - I = this.currOtherTypeCallback(h, b, w, _); - break; - case "null": - h === null && (I = !0); - break; - default: - throw new TypeError("Unknown value type " + Z); - } - if (I) return Y = { path: b, value: h, parent: w, parentProperty: _ }, this._handleCallback(Y, O, "value"), Y; - } else if (H[0] === "`" && h && Object.hasOwn(h, H.slice(1))) { - const I = H.slice(1); - ne(this._trace(V, h[I], E(b, I), h, I, O, P, !0)); - } else if (H.includes(",")) { - const I = H.split(","); - for (const Z of I) ne(this._trace(y(Z, V), h, b, w, _, O, !0)); - } else !L && h && Object.hasOwn(h, H) && ne(this._trace(V, h[H], E(b, H), h, H, O, P, !0)); - } - if (this._hasParentSelector) for (let I = 0; I < B.length; I++) { - const Z = B[I]; - if (Z && Z.isParentSelector) { - const te = this._trace(Z.expr, h, Z.path, w, _, O, P); - if (Array.isArray(te)) { - B[I] = te[0]; - const he = te.length; - for (let le = 1; le < he; le++) I++, B.splice(I, 0, te[le]); - } else B[I] = te; - } - } - return B; - }, T.prototype._walk = function(v, h) { - if (Array.isArray(v)) { - const b = v.length; - for (let w = 0; w < b; w++) h(w); - } else v && typeof v == "object" && Object.keys(v).forEach(((b) => { - h(b); - })); - }, T.prototype._slice = function(v, h, b, w, _, O, P) { - if (!Array.isArray(b)) return; - const L = b.length, Y = v.split(":"), H = Y[2] && Number.parseInt(Y[2]) || 1; - let V = Y[0] && Number.parseInt(Y[0]) || 0, B = Y[1] && Number.parseInt(Y[1]) || L; - V = V < 0 ? Math.max(0, V + L) : Math.min(L, V), B = B < 0 ? Math.max(0, B + L) : Math.min(L, B); - const ne = []; - for (let I = V; I < B; I += H) - this._trace(y(I, h), b, w, _, O, P, !0).forEach(((Z) => { - ne.push(Z); - })); - return ne; - }, T.prototype._eval = function(v, h, b, w, _, O) { - this.currSandbox._$_parentProperty = O, this.currSandbox._$_parent = _, this.currSandbox._$_property = b, this.currSandbox._$_root = this.json, this.currSandbox._$_v = h; - const P = v.includes("@path"); - P && (this.currSandbox._$_path = T.toPathString(w.concat([b]))); - const L = this.currEval + "Script:" + v; - if (!T.cache[L]) { - let Y = v.replaceAll("@parentProperty", "_$_parentProperty").replaceAll("@parent", "_$_parent").replaceAll("@property", "_$_property").replaceAll("@root", "_$_root").replaceAll(/@([.\s)[])/gu, "_$_v$1"); - if (P && (Y = Y.replaceAll("@path", "_$_path")), this.currEval === "safe" || this.currEval === !0 || this.currEval === void 0) T.cache[L] = new this.safeVm.Script(Y); - else if (this.currEval === "native") T.cache[L] = new this.vm.Script(Y); - else if (typeof this.currEval == "function" && this.currEval.prototype && Object.hasOwn(this.currEval.prototype, "runInNewContext")) { - const H = this.currEval; - T.cache[L] = new H(Y); - } else { - if (typeof this.currEval != "function") throw new TypeError(`Unknown "eval" property "${this.currEval}"`); - T.cache[L] = { runInNewContext: (H) => this.currEval(Y, H) }; - } - } - try { - return T.cache[L].runInNewContext(this.currSandbox); - } catch (Y) { - if (this.ignoreEvalErrors) return !1; - throw new Error("jsonPath: " + Y.message + ": " + v); - } - }, T.cache = {}, T.toPathString = function(v) { - const h = v, b = h.length; - let w = "$"; - for (let _ = 1; _ < b; _++) /^(~|\^|@.*?\(\))$/u.test(h[_]) || (w += /^[0-9*]+$/u.test(h[_]) ? "[" + h[_] + "]" : "['" + h[_] + "']"); - return w; - }, T.toPointer = function(v) { - const h = v, b = h.length; - let w = ""; - for (let _ = 1; _ < b; _++) /^(~|\^|@.*?\(\))$/u.test(h[_]) || (w += "/" + h[_].toString().replaceAll("~", "~0").replaceAll("/", "~1")); - return w; - }, T.toPathArray = function(v) { - const { cache: h } = T; - if (h[v]) return h[v].concat(); - const b = [], w = v.replaceAll(/@(?:null|boolean|number|string|integer|undefined|nonFinite|scalar|array|object|function|other)\(\)/gu, ";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu, (function(_, O) { - return "[#" + (b.push(O) - 1) + "]"; - })).replaceAll(/\[['"]([^'\]]*)['"]\]/gu, (function(_, O) { - return "['" + O.replaceAll(".", "%@%").replaceAll("~", "%%@@%%") + "']"; - })).replaceAll("~", ";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu, ";").replaceAll("%@%", ".").replaceAll("%%@@%%", "~").replaceAll(/(?:;)?(\^+)(?:;)?/gu, (function(_, O) { - return ";" + O.split("").join(";") + ";"; - })).replaceAll(/;;;|;;/gu, ";..;").replaceAll(/;$|'?\]|'$/gu, "").split(";").map((function(_) { - const O = _.match(/#(\d+)/u); - return O && O[1] ? b[O[1]] : _; - })); - return h[v] = w, h[v].concat(); - }, T.prototype.safeVm = { Script: class { - constructor(v) { - this.code = v, this.ast = i(this.code); - } - runInNewContext(v) { - const h = Object.assign(/* @__PURE__ */ Object.create(null), v); - return d.evalAst(this.ast, h); - } - } }, T.prototype.vm = { Script: class { - constructor(v) { - this.code = v; - } - runInNewContext(v) { - let h = this.code; - const b = Object.keys(v), w = []; - (function(L, Y, H) { - const V = L.length; - for (let B = 0; B < V; B++) H(L[B]) && Y.push(L.splice(B--, 1)[0]); - })(b, w, ((L) => typeof v[L] == "function")); - const _ = b.map(((L) => v[L])); - h = w.reduce(((L, Y) => { - let H = v[Y].toString(); - return /function/u.test(H) || (H = "function " + H), "var " + Y + "=" + H + ";" + L; - }), "") + h, /(['"])use strict\1/u.test(h) || b.includes("arguments") || (h = "var arguments = undefined;" + h), h = h.replace(/;\s*$/u, ""); - const O = h.lastIndexOf(";"), P = O !== -1 ? h.slice(0, O + 1) + " return " + h.slice(O + 1) : " return " + h; - return new Function(...b, P)(..._); - } - } }, n.JSONPath = T; - })); - })(); - })(bt, bt.exports)), bt.exports; -} -wi(); -var Ei = Object.create, bn = Object.defineProperty, Ai = Object.getOwnPropertyDescriptor, wn = Object.getOwnPropertyNames, xi = Object.getPrototypeOf, _i = Object.prototype.hasOwnProperty, Ue = (r, s) => function() { - return s || (0, r[wn(r)[0]])((s = { exports: {} }).exports, s), s.exports; -}, Oi = (r, s, n, o) => { - if (s && typeof s == "object" || typeof s == "function") - for (let p of wn(s)) - !_i.call(r, p) && p !== n && bn(r, p, { get: () => s[p], enumerable: !(o = Ai(s, p)) || o.enumerable }); - return r; -}, En = (r, s, n) => (n = r != null ? Ei(xi(r)) : {}, Oi( - // If the importer is in node compatibility mode or this is not an ESM - // file that has been converted to a CommonJS file using a Babel- - // compatible transform (i.e. "__esModule" has not been set), then set - // "default" to the CommonJS "module.exports" for node compatibility. - bn(n, "default", { value: r, enumerable: !0 }), - r -)), Pt = Ue({ - "node_modules/ret/lib/types.js"(r, s) { - s.exports = { - ROOT: 0, - GROUP: 1, - POSITION: 2, - SET: 3, - RANGE: 4, - REPETITION: 5, - REFERENCE: 6, - CHAR: 7 - }; - } -}), An = Ue({ - "node_modules/ret/lib/sets.js"(r) { - var s = Pt(), n = () => [{ type: s.RANGE, from: 48, to: 57 }], o = () => [ - { type: s.CHAR, value: 95 }, - { type: s.RANGE, from: 97, to: 122 }, - { type: s.RANGE, from: 65, to: 90 } - ].concat(n()), p = () => [ - { type: s.CHAR, value: 9 }, - { type: s.CHAR, value: 10 }, - { type: s.CHAR, value: 11 }, - { type: s.CHAR, value: 12 }, - { type: s.CHAR, value: 13 }, - { type: s.CHAR, value: 32 }, - { type: s.CHAR, value: 160 }, - { type: s.CHAR, value: 5760 }, - { type: s.RANGE, from: 8192, to: 8202 }, - { type: s.CHAR, value: 8232 }, - { type: s.CHAR, value: 8233 }, - { type: s.CHAR, value: 8239 }, - { type: s.CHAR, value: 8287 }, - { type: s.CHAR, value: 12288 }, - { type: s.CHAR, value: 65279 } - ], i = () => [ - { type: s.CHAR, value: 10 }, - { type: s.CHAR, value: 13 }, - { type: s.CHAR, value: 8232 }, - { type: s.CHAR, value: 8233 } - ]; - r.words = () => ({ type: s.SET, set: o(), not: !1 }), r.notWords = () => ({ type: s.SET, set: o(), not: !0 }), r.ints = () => ({ type: s.SET, set: n(), not: !1 }), r.notInts = () => ({ type: s.SET, set: n(), not: !0 }), r.whitespace = () => ({ type: s.SET, set: p(), not: !1 }), r.notWhitespace = () => ({ type: s.SET, set: p(), not: !0 }), r.anyChar = () => ({ type: s.SET, set: i(), not: !0 }); - } -}), Si = Ue({ - "node_modules/ret/lib/util.js"(r) { - var s = Pt(), n = An(), o = "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^ ?", p = { 0: 0, t: 9, n: 10, v: 11, f: 12, r: 13 }; - r.strToChars = function(i) { - var u = /(\[\\b\])|(\\)?\\(?:u([A-F0-9]{4})|x([A-F0-9]{2})|(0?[0-7]{2})|c([@A-Z[\\\]^?])|([0tnvfr]))/g; - return i = i.replace(u, function(a, c, l, f, d, E, y, S) { - if (l) - return a; - var T = c ? 8 : f ? parseInt(f, 16) : d ? parseInt(d, 16) : E ? parseInt(E, 8) : y ? o.indexOf(y) : p[S], v = String.fromCharCode(T); - return /[[\]{}^$.|?*+()]/.test(v) && (v = "\\" + v), v; - }), i; - }, r.tokenizeClass = (i, u) => { - for (var a = [], c = /\\(?:(w)|(d)|(s)|(W)|(D)|(S))|((?:(?:\\)(.)|([^\]\\]))-(?:\\)?([^\]]))|(\])|(?:\\)?([^])/g, l, f; (l = c.exec(i)) != null; ) - if (l[1]) - a.push(n.words()); - else if (l[2]) - a.push(n.ints()); - else if (l[3]) - a.push(n.whitespace()); - else if (l[4]) - a.push(n.notWords()); - else if (l[5]) - a.push(n.notInts()); - else if (l[6]) - a.push(n.notWhitespace()); - else if (l[7]) - a.push({ - type: s.RANGE, - from: (l[8] || l[9]).charCodeAt(0), - to: l[10].charCodeAt(0) - }); - else if (f = l[12]) - a.push({ - type: s.CHAR, - value: f.charCodeAt(0) - }); - else - return [a, c.lastIndex]; - r.error(u, "Unterminated character class"); - }, r.error = (i, u) => { - throw new SyntaxError("Invalid regular expression: /" + i + "/: " + u); - }; - } -}), Ci = Ue({ - "node_modules/ret/lib/positions.js"(r) { - var s = Pt(); - r.wordBoundary = () => ({ type: s.POSITION, value: "b" }), r.nonWordBoundary = () => ({ type: s.POSITION, value: "B" }), r.begin = () => ({ type: s.POSITION, value: "^" }), r.end = () => ({ type: s.POSITION, value: "$" }); - } -}), Ti = Ue({ - "node_modules/ret/lib/index.js"(r, s) { - var n = Si(), o = Pt(), p = An(), i = Ci(); - s.exports = (u) => { - var a = 0, c, l, f = { type: o.ROOT, stack: [] }, d = f, E = f.stack, y = [], S = (L) => { - n.error(u, `Nothing to repeat at column ${L - 1}`); - }, T = n.strToChars(u); - for (c = T.length; a < c; ) - switch (l = T[a++], l) { - case "\\": - switch (l = T[a++], l) { - case "b": - E.push(i.wordBoundary()); - break; - case "B": - E.push(i.nonWordBoundary()); - break; - case "w": - E.push(p.words()); - break; - case "W": - E.push(p.notWords()); - break; - case "d": - E.push(p.ints()); - break; - case "D": - E.push(p.notInts()); - break; - case "s": - E.push(p.whitespace()); - break; - case "S": - E.push(p.notWhitespace()); - break; - default: - /\d/.test(l) ? E.push({ type: o.REFERENCE, value: parseInt(l, 10) }) : E.push({ type: o.CHAR, value: l.charCodeAt(0) }); - } - break; - case "^": - E.push(i.begin()); - break; - case "$": - E.push(i.end()); - break; - case "[": - var v; - T[a] === "^" ? (v = !0, a++) : v = !1; - var h = n.tokenizeClass(T.slice(a), u); - a += h[1], E.push({ - type: o.SET, - set: h[0], - not: v - }); - break; - case ".": - E.push(p.anyChar()); - break; - case "(": - var b = { - type: o.GROUP, - stack: [], - remember: !0 - }; - l = T[a], l === "?" && (l = T[a + 1], a += 2, l === "=" ? b.followedBy = !0 : l === "!" ? b.notFollowedBy = !0 : l !== ":" && n.error( - u, - `Invalid group, character '${l}' after '?' at column ${a - 1}` - ), b.remember = !1), E.push(b), y.push(d), d = b, E = b.stack; - break; - case ")": - y.length === 0 && n.error(u, `Unmatched ) at column ${a - 1}`), d = y.pop(), E = d.options ? d.options[d.options.length - 1] : d.stack; - break; - case "|": - d.options || (d.options = [d.stack], delete d.stack); - var w = []; - d.options.push(w), E = w; - break; - case "{": - var _ = /^(\d+)(,(\d+)?)?\}/.exec(T.slice(a)), O, P; - _ !== null ? (E.length === 0 && S(a), O = parseInt(_[1], 10), P = _[2] ? _[3] ? parseInt(_[3], 10) : 1 / 0 : O, a += _[0].length, E.push({ - type: o.REPETITION, - min: O, - max: P, - value: E.pop() - })) : E.push({ - type: o.CHAR, - value: 123 - }); - break; - case "?": - E.length === 0 && S(a), E.push({ - type: o.REPETITION, - min: 0, - max: 1, - value: E.pop() - }); - break; - case "+": - E.length === 0 && S(a), E.push({ - type: o.REPETITION, - min: 1, - max: 1 / 0, - value: E.pop() - }); - break; - case "*": - E.length === 0 && S(a), E.push({ - type: o.REPETITION, - min: 0, - max: 1 / 0, - value: E.pop() - }); - break; - default: - E.push({ - type: o.CHAR, - value: l.charCodeAt(0) - }); - } - return y.length !== 0 && n.error(u, "Unterminated group"), f; - }, s.exports.types = o; - } -}), Pi = Ue({ - "node_modules/drange/lib/index.js"(r, s) { - var n = class tt { - constructor(i, u) { - this.low = i, this.high = u, this.length = 1 + u - i; - } - overlaps(i) { - return !(this.high < i.low || this.low > i.high); - } - touches(i) { - return !(this.high + 1 < i.low || this.low - 1 > i.high); - } - // Returns inclusive combination of SubRanges as a SubRange. - add(i) { - return new tt( - Math.min(this.low, i.low), - Math.max(this.high, i.high) - ); - } - // Returns subtraction of SubRanges as an array of SubRanges. - // (There's a case where subtraction divides it in 2) - subtract(i) { - return i.low <= this.low && i.high >= this.high ? [] : i.low > this.low && i.high < this.high ? [ - new tt(this.low, i.low - 1), - new tt(i.high + 1, this.high) - ] : i.low <= this.low ? [new tt(i.high + 1, this.high)] : [new tt(this.low, i.low - 1)]; - } - toString() { - return this.low == this.high ? this.low.toString() : this.low + "-" + this.high; - } - }, o = class dt { - constructor(i, u) { - this.ranges = [], this.length = 0, i != null && this.add(i, u); - } - _update_length() { - this.length = this.ranges.reduce((i, u) => i + u.length, 0); - } - add(i, u) { - var a = (c) => { - for (var l = 0; l < this.ranges.length && !c.touches(this.ranges[l]); ) - l++; - for (var f = this.ranges.slice(0, l); l < this.ranges.length && c.touches(this.ranges[l]); ) - c = c.add(this.ranges[l]), l++; - f.push(c), this.ranges = f.concat(this.ranges.slice(l)), this._update_length(); - }; - return i instanceof dt ? i.ranges.forEach(a) : (u == null && (u = i), a(new n(i, u))), this; - } - subtract(i, u) { - var a = (c) => { - for (var l = 0; l < this.ranges.length && !c.overlaps(this.ranges[l]); ) - l++; - for (var f = this.ranges.slice(0, l); l < this.ranges.length && c.overlaps(this.ranges[l]); ) - f = f.concat(this.ranges[l].subtract(c)), l++; - this.ranges = f.concat(this.ranges.slice(l)), this._update_length(); - }; - return i instanceof dt ? i.ranges.forEach(a) : (u == null && (u = i), a(new n(i, u))), this; - } - intersect(i, u) { - var a = [], c = (l) => { - for (var f = 0; f < this.ranges.length && !l.overlaps(this.ranges[f]); ) - f++; - for (; f < this.ranges.length && l.overlaps(this.ranges[f]); ) { - var d = Math.max(this.ranges[f].low, l.low), E = Math.min(this.ranges[f].high, l.high); - a.push(new n(d, E)), f++; - } - }; - return i instanceof dt ? i.ranges.forEach(c) : (u == null && (u = i), c(new n(i, u))), this.ranges = a, this._update_length(), this; - } - index(i) { - for (var u = 0; u < this.ranges.length && this.ranges[u].length <= i; ) - i -= this.ranges[u].length, u++; - return this.ranges[u].low + i; - } - toString() { - return "[ " + this.ranges.join(", ") + " ]"; - } - clone() { - return new dt(this); - } - numbers() { - return this.ranges.reduce((i, u) => { - for (var a = u.low; a <= u.high; ) - i.push(a), a++; - return i; - }, []); - } - subranges() { - return this.ranges.map((i) => ({ - low: i.low, - high: i.high, - length: 1 + i.high - i.low - })); - } - }; - s.exports = o; - } -}), Ri = Ue({ - "node_modules/randexp/lib/randexp.js"(r, s) { - var n = Ti(), o = Pi(), p = n.types; - s.exports = class mt { - /** - * @constructor - * @param {RegExp|String} regexp - * @param {String} m - */ - constructor(u, a) { - if (this._setDefaults(u), u instanceof RegExp) - this.ignoreCase = u.ignoreCase, this.multiline = u.multiline, u = u.source; - else if (typeof u == "string") - this.ignoreCase = a && a.indexOf("i") !== -1, this.multiline = a && a.indexOf("m") !== -1; - else - throw new Error("Expected a regexp or string"); - this.tokens = n(u); - } - /** - * Checks if some custom properties have been set for this regexp. - * - * @param {RandExp} randexp - * @param {RegExp} regexp - */ - _setDefaults(u) { - this.max = u.max != null ? u.max : mt.prototype.max != null ? mt.prototype.max : 100, this.defaultRange = u.defaultRange ? u.defaultRange : this.defaultRange.clone(), u.randInt && (this.randInt = u.randInt); - } - /** - * Generates the random string. - * - * @return {String} - */ - gen() { - return this._gen(this.tokens, []); - } - /** - * Generate random string modeled after given tokens. - * - * @param {Object} token - * @param {Array.} groups - * @return {String} - */ - _gen(u, a) { - var c, l, f, d, E; - switch (u.type) { - case p.ROOT: - case p.GROUP: - if (u.followedBy || u.notFollowedBy) - return ""; - for (u.remember && u.groupNumber === void 0 && (u.groupNumber = a.push(null) - 1), c = u.options ? this._randSelect(u.options) : u.stack, l = "", d = 0, E = c.length; d < E; d++) - l += this._gen(c[d], a); - return u.remember && (a[u.groupNumber] = l), l; - case p.POSITION: - return ""; - case p.SET: - var y = this._expand(u); - return y.length ? String.fromCharCode(this._randSelect(y)) : ""; - case p.REPETITION: - for (f = this.randInt( - u.min, - u.max === 1 / 0 ? u.min + this.max : u.max - ), l = "", d = 0; d < f; d++) - l += this._gen(u.value, a); - return l; - case p.REFERENCE: - return a[u.value - 1] || ""; - case p.CHAR: - var S = this.ignoreCase && this._randBool() ? this._toOtherCase(u.value) : u.value; - return String.fromCharCode(S); - } - } - /** - * If code is alphabetic, converts to other case. - * If not alphabetic, returns back code. - * - * @param {Number} code - * @return {Number} - */ - _toOtherCase(u) { - return u + (97 <= u && u <= 122 ? -32 : 65 <= u && u <= 90 ? 32 : 0); - } - /** - * Randomly returns a true or false value. - * - * @return {Boolean} - */ - _randBool() { - return !this.randInt(0, 1); - } - /** - * Randomly selects and returns a value from the array. - * - * @param {Array.} arr - * @return {Object} - */ - _randSelect(u) { - return u instanceof o ? u.index(this.randInt(0, u.length - 1)) : u[this.randInt(0, u.length - 1)]; - } - /** - * expands a token to a DiscontinuousRange of characters which has a - * length and an index function (for random selecting) - * - * @param {Object} token - * @return {DiscontinuousRange} - */ - _expand(u) { - if (u.type === n.types.CHAR) - return new o(u.value); - if (u.type === n.types.RANGE) - return new o(u.from, u.to); - { - let a = new o(); - for (let c = 0; c < u.set.length; c++) { - let l = this._expand(u.set[c]); - if (a.add(l), this.ignoreCase) - for (let f = 0; f < l.length; f++) { - let d = l.index(f), E = this._toOtherCase(d); - d !== E && a.add(E); - } - } - return u.not ? this.defaultRange.clone().subtract(a) : this.defaultRange.clone().intersect(a); - } - } - /** - * Randomly generates and returns a number between a and b (inclusive). - * - * @param {Number} a - * @param {Number} b - * @return {Number} - */ - randInt(u, a) { - return u + Math.floor(Math.random() * (1 + a - u)); - } - /** - * Default range of characters to generate from. - */ - get defaultRange() { - return this._range = this._range || new o(32, 126); - } - set defaultRange(u) { - this._range = u; - } - /** - * - * Enables use of randexp with a shorter call. - * - * @param {RegExp|String| regexp} - * @param {String} m - * @return {String} - */ - static randexp(u, a) { - var c; - return typeof u == "string" && (u = new RegExp(u, a)), u._randexp === void 0 ? (c = new mt(u, a), u._randexp = c) : (c = u._randexp, c._setDefaults(u)), c.gen(); - } - /** - * Enables sugary /regexp/.gen syntax. - */ - static sugar() { - RegExp.prototype.gen = function() { - return mt.randexp(this); - }; - } - }; - } -}), Rt = Ue({ - "node_modules/yaml/dist/PlainValue-ec8e588e.js"(r) { - var s = { - ANCHOR: "&", - COMMENT: "#", - TAG: "!", - DIRECTIVES_END: "-", - DOCUMENT_END: "." - }, n = { - ALIAS: "ALIAS", - BLANK_LINE: "BLANK_LINE", - BLOCK_FOLDED: "BLOCK_FOLDED", - BLOCK_LITERAL: "BLOCK_LITERAL", - COMMENT: "COMMENT", - DIRECTIVE: "DIRECTIVE", - DOCUMENT: "DOCUMENT", - FLOW_MAP: "FLOW_MAP", - FLOW_SEQ: "FLOW_SEQ", - MAP: "MAP", - MAP_KEY: "MAP_KEY", - MAP_VALUE: "MAP_VALUE", - PLAIN: "PLAIN", - QUOTE_DOUBLE: "QUOTE_DOUBLE", - QUOTE_SINGLE: "QUOTE_SINGLE", - SEQ: "SEQ", - SEQ_ITEM: "SEQ_ITEM" - }, o = "tag:yaml.org,2002:", p = { - MAP: "tag:yaml.org,2002:map", - SEQ: "tag:yaml.org,2002:seq", - STR: "tag:yaml.org,2002:str" - }; - function i(w) { - const _ = [0]; - let O = w.indexOf(` -`); - for (; O !== -1; ) - O += 1, _.push(O), O = w.indexOf(` -`, O); - return _; - } - function u(w) { - let _, O; - return typeof w == "string" ? (_ = i(w), O = w) : (Array.isArray(w) && (w = w[0]), w && w.context && (w.lineStarts || (w.lineStarts = i(w.context.src)), _ = w.lineStarts, O = w.context.src)), { - lineStarts: _, - src: O - }; - } - function a(w, _) { - if (typeof w != "number" || w < 0) - return null; - const { - lineStarts: O, - src: P - } = u(_); - if (!O || !P || w > P.length) - return null; - for (let Y = 0; Y < O.length; ++Y) { - const H = O[Y]; - if (w < H) - return { - line: Y, - col: w - O[Y - 1] + 1 - }; - if (w === H) - return { - line: Y + 1, - col: 1 - }; - } - const L = O.length; - return { - line: L, - col: w - O[L - 1] + 1 - }; - } - function c(w, _) { - const { - lineStarts: O, - src: P - } = u(_); - if (!O || !(w >= 1) || w > O.length) - return null; - const L = O[w - 1]; - let Y = O[w]; - for (; Y && Y > L && P[Y - 1] === ` -`; ) - --Y; - return P.slice(L, Y); - } - function l({ - start: w, - end: _ - }, O, P = 80) { - let L = c(w.line, O); - if (!L) - return null; - let { - col: Y - } = w; - if (L.length > P) - if (Y <= P - 10) - L = L.substr(0, P - 1) + "…"; - else { - const I = Math.round(P / 2); - L.length > Y + I && (L = L.substr(0, Y + I - 1) + "…"), Y -= L.length - P, L = "…" + L.substr(1 - P); - } - let H = 1, V = ""; - _ && (_.line === w.line && Y + (_.col - w.col) <= P + 1 ? H = _.col - w.col : (H = Math.min(L.length + 1, P) - Y, V = "…")); - const B = Y > 1 ? " ".repeat(Y - 1) : "", ne = "^".repeat(H); - return `${L} -${B}${ne}${V}`; - } - var f = class xn { - static copy(_) { - return new xn(_.start, _.end); - } - constructor(_, O) { - this.start = _, this.end = O || _; - } - isEmpty() { - return typeof this.start != "number" || !this.end || this.end <= this.start; - } - /** - * Set `origStart` and `origEnd` to point to the original source range for - * this node, which may differ due to dropped CR characters. - * - * @param {number[]} cr - Positions of dropped CR characters - * @param {number} offset - Starting index of `cr` from the last call - * @returns {number} - The next offset, matching the one found for `origStart` - */ - setOrigRange(_, O) { - const { - start: P, - end: L - } = this; - if (_.length === 0 || L <= _[0]) - return this.origStart = P, this.origEnd = L, O; - let Y = O; - for (; Y < _.length && !(_[Y] > P); ) - ++Y; - this.origStart = P + Y; - const H = Y; - for (; Y < _.length && !(_[Y] >= L); ) - ++Y; - return this.origEnd = L + Y, H; - } - }, d = class Je { - static addStringTerminator(_, O, P) { - if (P[P.length - 1] === ` -`) - return P; - const L = Je.endOfWhiteSpace(_, O); - return L >= _.length || _[L] === ` -` ? P + ` -` : P; - } - // ^(---|...) - static atDocumentBoundary(_, O, P) { - const L = _[O]; - if (!L) - return !0; - const Y = _[O - 1]; - if (Y && Y !== ` -`) - return !1; - if (P) { - if (L !== P) - return !1; - } else if (L !== s.DIRECTIVES_END && L !== s.DOCUMENT_END) - return !1; - const H = _[O + 1], V = _[O + 2]; - if (H !== L || V !== L) - return !1; - const B = _[O + 3]; - return !B || B === ` -` || B === " " || B === " "; - } - static endOfIdentifier(_, O) { - let P = _[O]; - const L = P === "<", Y = L ? [` -`, " ", " ", ">"] : [` -`, " ", " ", "[", "]", "{", "}", ","]; - for (; P && Y.indexOf(P) === -1; ) - P = _[O += 1]; - return L && P === ">" && (O += 1), O; - } - static endOfIndent(_, O) { - let P = _[O]; - for (; P === " "; ) - P = _[O += 1]; - return O; - } - static endOfLine(_, O) { - let P = _[O]; - for (; P && P !== ` -`; ) - P = _[O += 1]; - return O; - } - static endOfWhiteSpace(_, O) { - let P = _[O]; - for (; P === " " || P === " "; ) - P = _[O += 1]; - return O; - } - static startOfLine(_, O) { - let P = _[O - 1]; - if (P === ` -`) - return O; - for (; P && P !== ` -`; ) - P = _[O -= 1]; - return O + 1; - } - /** - * End of indentation, or null if the line's indent level is not more - * than `indent` - * - * @param {string} src - * @param {number} indent - * @param {number} lineStart - * @returns {?number} - */ - static endOfBlockIndent(_, O, P) { - const L = Je.endOfIndent(_, P); - if (L > P + O) - return L; - { - const Y = Je.endOfWhiteSpace(_, L), H = _[Y]; - if (!H || H === ` -`) - return Y; - } - return null; - } - static atBlank(_, O, P) { - const L = _[O]; - return L === ` -` || L === " " || L === " " || P && !L; - } - static nextNodeIsIndented(_, O, P) { - return !_ || O < 0 ? !1 : O > 0 ? !0 : P && _ === "-"; - } - // should be at line or string end, or at next non-whitespace char - static normalizeOffset(_, O) { - const P = _[O]; - return P ? P !== ` -` && _[O - 1] === ` -` ? O - 1 : Je.endOfWhiteSpace(_, O) : O; - } - // fold single newline into space, multiple newlines to N - 1 newlines - // presumes src[offset] === '\n' - static foldNewline(_, O, P) { - let L = 0, Y = !1, H = "", V = _[O + 1]; - for (; V === " " || V === " " || V === ` -`; ) { - switch (V) { - case ` -`: - L = 0, O += 1, H += ` -`; - break; - case " ": - L <= P && (Y = !0), O = Je.endOfWhiteSpace(_, O + 2) - 1; - break; - case " ": - L += 1, O += 1; - break; - } - V = _[O + 1]; - } - return H || (H = " "), V && L <= P && (Y = !0), { - fold: H, - offset: O, - error: Y - }; - } - constructor(_, O, P) { - Object.defineProperty(this, "context", { - value: P || null, - writable: !0 - }), this.error = null, this.range = null, this.valueRange = null, this.props = O || [], this.type = _, this.value = null; - } - getPropValue(_, O, P) { - if (!this.context) - return null; - const { - src: L - } = this.context, Y = this.props[_]; - return Y && L[Y.start] === O ? L.slice(Y.start + (P ? 1 : 0), Y.end) : null; - } - get anchor() { - for (let _ = 0; _ < this.props.length; ++_) { - const O = this.getPropValue(_, s.ANCHOR, !0); - if (O != null) - return O; - } - return null; - } - get comment() { - const _ = []; - for (let O = 0; O < this.props.length; ++O) { - const P = this.getPropValue(O, s.COMMENT, !0); - P != null && _.push(P); - } - return _.length > 0 ? _.join(` -`) : null; - } - commentHasRequiredWhitespace(_) { - const { - src: O - } = this.context; - if (this.header && _ === this.header.end || !this.valueRange) - return !1; - const { - end: P - } = this.valueRange; - return _ !== P || Je.atBlank(O, P - 1); - } - get hasComment() { - if (this.context) { - const { - src: _ - } = this.context; - for (let O = 0; O < this.props.length; ++O) - if (_[this.props[O].start] === s.COMMENT) - return !0; - } - return !1; - } - get hasProps() { - if (this.context) { - const { - src: _ - } = this.context; - for (let O = 0; O < this.props.length; ++O) - if (_[this.props[O].start] !== s.COMMENT) - return !0; - } - return !1; - } - get includesTrailingLines() { - return !1; - } - get jsonLike() { - return [n.FLOW_MAP, n.FLOW_SEQ, n.QUOTE_DOUBLE, n.QUOTE_SINGLE].indexOf(this.type) !== -1; - } - get rangeAsLinePos() { - if (!this.range || !this.context) - return; - const _ = a(this.range.start, this.context.root); - if (!_) - return; - const O = a(this.range.end, this.context.root); - return { - start: _, - end: O - }; - } - get rawValue() { - if (!this.valueRange || !this.context) - return null; - const { - start: _, - end: O - } = this.valueRange; - return this.context.src.slice(_, O); - } - get tag() { - for (let _ = 0; _ < this.props.length; ++_) { - const O = this.getPropValue(_, s.TAG, !1); - if (O != null) { - if (O[1] === "<") - return { - verbatim: O.slice(2, -1) - }; - { - const [P, L, Y] = O.match(/^(.*!)([^!]*)$/); - return { - handle: L, - suffix: Y - }; - } - } - } - return null; - } - get valueRangeContainsNewline() { - if (!this.valueRange || !this.context) - return !1; - const { - start: _, - end: O - } = this.valueRange, { - src: P - } = this.context; - for (let L = _; L < O; ++L) - if (P[L] === ` -`) - return !0; - return !1; - } - parseComment(_) { - const { - src: O - } = this.context; - if (O[_] === s.COMMENT) { - const P = Je.endOfLine(O, _ + 1), L = new f(_, P); - return this.props.push(L), P; - } - return _; - } - /** - * Populates the `origStart` and `origEnd` values of all ranges for this - * node. Extended by child classes to handle descendant nodes. - * - * @param {number[]} cr - Positions of dropped CR characters - * @param {number} offset - Starting index of `cr` from the last call - * @returns {number} - The next offset, matching the one found for `origStart` - */ - setOrigRanges(_, O) { - return this.range && (O = this.range.setOrigRange(_, O)), this.valueRange && this.valueRange.setOrigRange(_, O), this.props.forEach((P) => P.setOrigRange(_, O)), O; - } - toString() { - const { - context: { - src: _ - }, - range: O, - value: P - } = this; - if (P != null) - return P; - const L = _.slice(O.start, O.end); - return Je.addStringTerminator(_, O.end, L); - } - }, E = class extends Error { - constructor(w, _, O) { - if (!O || !(_ instanceof d)) - throw new Error(`Invalid arguments for new ${w}`); - super(), this.name = w, this.message = O, this.source = _; - } - makePretty() { - if (!this.source) - return; - this.nodeType = this.source.type; - const w = this.source.context && this.source.context.root; - if (typeof this.offset == "number") { - this.range = new f(this.offset, this.offset + 1); - const _ = w && a(this.offset, w); - if (_) { - const O = { - line: _.line, - col: _.col + 1 - }; - this.linePos = { - start: _, - end: O - }; - } - delete this.offset; - } else - this.range = this.source.range, this.linePos = this.source.rangeAsLinePos; - if (this.linePos) { - const { - line: _, - col: O - } = this.linePos.start; - this.message += ` at line ${_}, column ${O}`; - const P = w && l(this.linePos, w); - P && (this.message += `: - -${P} -`); - } - delete this.source; - } - }, y = class extends E { - constructor(w, _) { - super("YAMLReferenceError", w, _); - } - }, S = class extends E { - constructor(w, _) { - super("YAMLSemanticError", w, _); - } - }, T = class extends E { - constructor(w, _) { - super("YAMLSyntaxError", w, _); - } - }, v = class extends E { - constructor(w, _) { - super("YAMLWarning", w, _); - } - }; - function h(w, _, O) { - return _ in w ? Object.defineProperty(w, _, { - value: O, - enumerable: !0, - configurable: !0, - writable: !0 - }) : w[_] = O, w; - } - var b = class ur extends d { - static endOfLine(_, O, P) { - let L = _[O], Y = O; - for (; L && L !== ` -` && !(P && (L === "[" || L === "]" || L === "{" || L === "}" || L === ",")); ) { - const H = _[Y + 1]; - if (L === ":" && (!H || H === ` -` || H === " " || H === " " || P && H === ",") || (L === " " || L === " ") && H === "#") - break; - Y += 1, L = H; - } - return Y; - } - get strValue() { - if (!this.valueRange || !this.context) - return null; - let { - start: _, - end: O - } = this.valueRange; - const { - src: P - } = this.context; - let L = P[O - 1]; - for (; _ < O && (L === ` -` || L === " " || L === " "); ) - L = P[--O - 1]; - let Y = ""; - for (let V = _; V < O; ++V) { - const B = P[V]; - if (B === ` -`) { - const { - fold: ne, - offset: I - } = d.foldNewline(P, V, -1); - Y += ne, V = I; - } else if (B === " " || B === " ") { - const ne = V; - let I = P[V + 1]; - for (; V < O && (I === " " || I === " "); ) - V += 1, I = P[V + 1]; - I !== ` -` && (Y += V > ne ? P.slice(ne, V + 1) : B); - } else - Y += B; - } - const H = P[_]; - switch (H) { - case " ": { - const V = "Plain value cannot start with a tab character"; - return { - errors: [new S(this, V)], - str: Y - }; - } - case "@": - case "`": { - const V = `Plain value cannot start with reserved character ${H}`; - return { - errors: [new S(this, V)], - str: Y - }; - } - default: - return Y; - } - } - parseBlockValue(_) { - const { - indent: O, - inFlow: P, - src: L - } = this.context; - let Y = _, H = _; - for (let V = L[Y]; V === ` -` && !d.atDocumentBoundary(L, Y + 1); V = L[Y]) { - const B = d.endOfBlockIndent(L, O, Y + 1); - if (B === null || L[B] === "#") - break; - L[B] === ` -` ? Y = B : (H = ur.endOfLine(L, B, P), Y = H); - } - return this.valueRange.isEmpty() && (this.valueRange.start = _), this.valueRange.end = H, H; - } - /** - * Parses a plain value from the source - * - * Accepted forms are: - * ``` - * #comment - * - * first line - * - * first line #comment - * - * first line - * block - * lines - * - * #comment - * block - * lines - * ``` - * where block lines are empty or have an indent level greater than `indent`. - * - * @param {ParseContext} context - * @param {number} start - Index of first character - * @returns {number} - Index of the character after this scalar, may be `\n` - */ - parse(_, O) { - this.context = _; - const { - inFlow: P, - src: L - } = _; - let Y = O; - const H = L[Y]; - return H && H !== "#" && H !== ` -` && (Y = ur.endOfLine(L, O, P)), this.valueRange = new f(O, Y), Y = d.endOfWhiteSpace(L, Y), Y = this.parseComment(Y), (!this.hasComment || this.valueRange.isEmpty()) && (Y = this.parseBlockValue(Y)), Y; - } - }; - r.Char = s, r.Node = d, r.PlainValue = b, r.Range = f, r.Type = n, r.YAMLError = E, r.YAMLReferenceError = y, r.YAMLSemanticError = S, r.YAMLSyntaxError = T, r.YAMLWarning = v, r._defineProperty = h, r.defaultTagPrefix = o, r.defaultTags = p; - } -}), yr = Ue({ - "node_modules/yaml/dist/resolveSeq-d03cb037.js"(r) { - var s = Rt(); - function n(N, e, t) { - return t ? `#${t.replace(/[\s\S]^/gm, `$&${e}#`)} -${e}${N}` : N; - } - function o(N, e, t) { - return t ? t.indexOf(` -`) === -1 ? `${N} #${t}` : `${N} -` + t.replace(/^/gm, `${e || ""}#`) : N; - } - var p = class { - }; - function i(N, e, t) { - if (Array.isArray(N)) - return N.map((x, C) => i(x, String(C), t)); - if (N && typeof N.toJSON == "function") { - const x = t && t.anchors && t.anchors.get(N); - x && (t.onCreate = (M) => { - x.res = M, delete t.onCreate; - }); - const C = N.toJSON(e, t); - return x && t.onCreate && t.onCreate(C), C; - } - return (!t || !t.keep) && typeof N == "bigint" ? Number(N) : N; - } - var u = class extends p { - constructor(N) { - super(), this.value = N; - } - toJSON(N, e) { - return e && e.keep ? this.value : i(this.value, N, e); - } - toString() { - return String(this.value); - } - }; - function a(N, e, t) { - let x = t; - for (let C = e.length - 1; C >= 0; --C) { - const M = e[C]; - if (Number.isInteger(M) && M >= 0) { - const g = []; - g[M] = x, x = g; - } else { - const g = {}; - Object.defineProperty(g, M, { - value: x, - writable: !0, - enumerable: !0, - configurable: !0 - }), x = g; - } - } - return N.createNode(x, !1); - } - var c = (N) => N == null || typeof N == "object" && N[Symbol.iterator]().next().done, l = class et extends p { - constructor(e) { - super(), s._defineProperty(this, "items", []), this.schema = e; - } - addIn(e, t) { - if (c(e)) - this.add(t); - else { - const [x, ...C] = e, M = this.get(x, !0); - if (M instanceof et) - M.addIn(C, t); - else if (M === void 0 && this.schema) - this.set(x, a(this.schema, C, t)); - else - throw new Error(`Expected YAML collection at ${x}. Remaining path: ${C}`); - } - } - deleteIn([e, ...t]) { - if (t.length === 0) - return this.delete(e); - const x = this.get(e, !0); - if (x instanceof et) - return x.deleteIn(t); - throw new Error(`Expected YAML collection at ${e}. Remaining path: ${t}`); - } - getIn([e, ...t], x) { - const C = this.get(e, !0); - return t.length === 0 ? !x && C instanceof u ? C.value : C : C instanceof et ? C.getIn(t, x) : void 0; - } - hasAllNullValues() { - return this.items.every((e) => { - if (!e || e.type !== "PAIR") - return !1; - const t = e.value; - return t == null || t instanceof u && t.value == null && !t.commentBefore && !t.comment && !t.tag; - }); - } - hasIn([e, ...t]) { - if (t.length === 0) - return this.has(e); - const x = this.get(e, !0); - return x instanceof et ? x.hasIn(t) : !1; - } - setIn([e, ...t], x) { - if (t.length === 0) - this.set(e, x); - else { - const C = this.get(e, !0); - if (C instanceof et) - C.setIn(t, x); - else if (C === void 0 && this.schema) - this.set(e, a(this.schema, t, x)); - else - throw new Error(`Expected YAML collection at ${e}. Remaining path: ${t}`); - } - } - // overridden in implementations - /* istanbul ignore next */ - toJSON() { - return null; - } - toString(e, { - blockItem: t, - flowChars: x, - isMap: C, - itemIndent: M - }, g, k) { - const { - indent: $, - indentStep: D, - stringify: X - } = e, J = this.type === s.Type.FLOW_MAP || this.type === s.Type.FLOW_SEQ || e.inFlow; - J && (M += D); - const ee = C && this.hasAllNullValues(); - e = Object.assign({}, e, { - allNullValues: ee, - indent: M, - inFlow: J, - type: null - }); - let re = !1, ue = !1; - const me = this.items.reduce((xe, _e, Le) => { - let Pe; - _e && (!re && _e.spaceBefore && xe.push({ - type: "comment", - str: "" - }), _e.commentBefore && _e.commentBefore.match(/^.*$/gm).forEach((oi) => { - xe.push({ - type: "comment", - str: `#${oi}` - }); - }), _e.comment && (Pe = _e.comment), J && (!re && _e.spaceBefore || _e.commentBefore || _e.comment || _e.key && (_e.key.commentBefore || _e.key.comment) || _e.value && (_e.value.commentBefore || _e.value.comment)) && (ue = !0)), re = !1; - let De = X(_e, e, () => Pe = null, () => re = !0); - return J && !ue && De.includes(` -`) && (ue = !0), J && Le < this.items.length - 1 && (De += ","), De = o(De, M, Pe), re && (Pe || J) && (re = !1), xe.push({ - type: "item", - str: De - }), xe; - }, []); - let we; - if (me.length === 0) - we = x.start + x.end; - else if (J) { - const { - start: xe, - end: _e - } = x, Le = me.map((Pe) => Pe.str); - if (ue || Le.reduce((Pe, De) => Pe + De.length + 2, 2) > et.maxFlowStringSingleLineLength) { - we = xe; - for (const Pe of Le) - we += Pe ? ` -${D}${$}${Pe}` : ` -`; - we += ` -${$}${_e}`; - } else - we = `${xe} ${Le.join(" ")} ${_e}`; - } else { - const xe = me.map(t); - we = xe.shift(); - for (const _e of xe) - we += _e ? ` -${$}${_e}` : ` -`; - } - return this.comment ? (we += ` -` + this.comment.replace(/^/gm, `${$}#`), g && g()) : re && k && k(), we; - } - }; - s._defineProperty(l, "maxFlowStringSingleLineLength", 60); - function f(N) { - let e = N instanceof u ? N.value : N; - return e && typeof e == "string" && (e = Number(e)), Number.isInteger(e) && e >= 0 ? e : null; - } - var d = class extends l { - add(N) { - this.items.push(N); - } - delete(N) { - const e = f(N); - return typeof e != "number" ? !1 : this.items.splice(e, 1).length > 0; - } - get(N, e) { - const t = f(N); - if (typeof t != "number") - return; - const x = this.items[t]; - return !e && x instanceof u ? x.value : x; - } - has(N) { - const e = f(N); - return typeof e == "number" && e < this.items.length; - } - set(N, e) { - const t = f(N); - if (typeof t != "number") - throw new Error(`Expected a valid index, not ${N}.`); - this.items[t] = e; - } - toJSON(N, e) { - const t = []; - e && e.onCreate && e.onCreate(t); - let x = 0; - for (const C of this.items) - t.push(i(C, String(x++), e)); - return t; - } - toString(N, e, t) { - return N ? super.toString(N, { - blockItem: (x) => x.type === "comment" ? x.str : `- ${x.str}`, - flowChars: { - start: "[", - end: "]" - }, - isMap: !1, - itemIndent: (N.indent || "") + " " - }, e, t) : JSON.stringify(this); - } - }, E = (N, e, t) => e === null ? "" : typeof e != "object" ? String(e) : N instanceof p && t && t.doc ? N.toString({ - anchors: /* @__PURE__ */ Object.create(null), - doc: t.doc, - indent: "", - indentStep: t.indentStep, - inFlow: !0, - inStringifyKey: !0, - stringify: t.stringify - }) : JSON.stringify(e), y = class _n extends p { - constructor(e, t = null) { - super(), this.key = e, this.value = t, this.type = _n.Type.PAIR; - } - get commentBefore() { - return this.key instanceof p ? this.key.commentBefore : void 0; - } - set commentBefore(e) { - if (this.key == null && (this.key = new u(null)), this.key instanceof p) - this.key.commentBefore = e; - else { - const t = "Pair.commentBefore is an alias for Pair.key.commentBefore. To set it, the key must be a Node."; - throw new Error(t); - } - } - addToJSMap(e, t) { - const x = i(this.key, "", e); - if (t instanceof Map) { - const C = i(this.value, x, e); - t.set(x, C); - } else if (t instanceof Set) - t.add(x); - else { - const C = E(this.key, x, e), M = i(this.value, C, e); - C in t ? Object.defineProperty(t, C, { - value: M, - writable: !0, - enumerable: !0, - configurable: !0 - }) : t[C] = M; - } - return t; - } - toJSON(e, t) { - const x = t && t.mapAsMap ? /* @__PURE__ */ new Map() : {}; - return this.addToJSMap(t, x); - } - toString(e, t, x) { - if (!e || !e.doc) - return JSON.stringify(this); - const { - indent: C, - indentSeq: M, - simpleKeys: g - } = e.doc.options; - let { - key: k, - value: $ - } = this, D = k instanceof p && k.comment; - if (g) { - if (D) - throw new Error("With simple keys, key nodes cannot have comments"); - if (k instanceof l) { - const De = "With simple keys, collection cannot be used as a key value"; - throw new Error(De); - } - } - let X = !g && (!k || D || (k instanceof p ? k instanceof l || k.type === s.Type.BLOCK_FOLDED || k.type === s.Type.BLOCK_LITERAL : typeof k == "object")); - const { - doc: J, - indent: ee, - indentStep: re, - stringify: ue - } = e; - e = Object.assign({}, e, { - implicitKey: !X, - indent: ee + re - }); - let me = !1, we = ue(k, e, () => D = null, () => me = !0); - if (we = o(we, e.indent, D), !X && we.length > 1024) { - if (g) - throw new Error("With simple keys, single line scalar must not span more than 1024 characters"); - X = !0; - } - if (e.allNullValues && !g) - return this.comment ? (we = o(we, e.indent, this.comment), t && t()) : me && !D && x && x(), e.inFlow && !X ? we : `? ${we}`; - we = X ? `? ${we} -${ee}:` : `${we}:`, this.comment && (we = o(we, e.indent, this.comment), t && t()); - let xe = "", _e = null; - if ($ instanceof p) { - if ($.spaceBefore && (xe = ` -`), $.commentBefore) { - const De = $.commentBefore.replace(/^/gm, `${e.indent}#`); - xe += ` -${De}`; - } - _e = $.comment; - } else $ && typeof $ == "object" && ($ = J.schema.createNode($, !0)); - e.implicitKey = !1, !X && !this.comment && $ instanceof u && (e.indentAtStart = we.length + 1), me = !1, !M && C >= 2 && !e.inFlow && !X && $ instanceof d && $.type !== s.Type.FLOW_SEQ && !$.tag && !J.anchors.getName($) && (e.indent = e.indent.substr(2)); - const Le = ue($, e, () => _e = null, () => me = !0); - let Pe = " "; - return xe || this.comment ? Pe = `${xe} -${e.indent}` : !X && $ instanceof l ? (!(Le[0] === "[" || Le[0] === "{") || Le.includes(` -`)) && (Pe = ` -${e.indent}`) : Le[0] === ` -` && (Pe = ""), me && !_e && x && x(), o(we + Pe + Le, e.indent, _e); - } - }; - s._defineProperty(y, "Type", { - PAIR: "PAIR", - MERGE_PAIR: "MERGE_PAIR" - }); - var S = (N, e) => { - if (N instanceof T) { - const t = e.get(N.source); - return t.count * t.aliasCount; - } else if (N instanceof l) { - let t = 0; - for (const x of N.items) { - const C = S(x, e); - C > t && (t = C); - } - return t; - } else if (N instanceof y) { - const t = S(N.key, e), x = S(N.value, e); - return Math.max(t, x); - } - return 1; - }, T = class On extends p { - static stringify({ - range: e, - source: t - }, { - anchors: x, - doc: C, - implicitKey: M, - inStringifyKey: g - }) { - let k = Object.keys(x).find((D) => x[D] === t); - if (!k && g && (k = C.anchors.getName(t) || C.anchors.newName()), k) - return `*${k}${M ? " " : ""}`; - const $ = C.anchors.getName(t) ? "Alias node must be after source node" : "Source node not found for alias node"; - throw new Error(`${$} [${e}]`); - } - constructor(e) { - super(), this.source = e, this.type = s.Type.ALIAS; - } - set tag(e) { - throw new Error("Alias nodes cannot have tags"); - } - toJSON(e, t) { - if (!t) - return i(this.source, e, t); - const { - anchors: x, - maxAliasCount: C - } = t, M = x.get(this.source); - if (!M || M.res === void 0) { - const g = "This should not happen: Alias anchor was not resolved?"; - throw this.cstNode ? new s.YAMLReferenceError(this.cstNode, g) : new ReferenceError(g); - } - if (C >= 0 && (M.count += 1, M.aliasCount === 0 && (M.aliasCount = S(this.source, x)), M.count * M.aliasCount > C)) { - const g = "Excessive alias count indicates a resource exhaustion attack"; - throw this.cstNode ? new s.YAMLReferenceError(this.cstNode, g) : new ReferenceError(g); - } - return M.res; - } - // Only called when stringifying an alias mapping key while constructing - // Object output. - toString(e) { - return On.stringify(this, e); - } - }; - s._defineProperty(T, "default", !0); - function v(N, e) { - const t = e instanceof u ? e.value : e; - for (const x of N) - if (x instanceof y && (x.key === e || x.key === t || x.key && x.key.value === t)) - return x; - } - var h = class extends l { - add(N, e) { - N ? N instanceof y || (N = new y(N.key || N, N.value)) : N = new y(N); - const t = v(this.items, N.key), x = this.schema && this.schema.sortMapEntries; - if (t) - if (e) - t.value = N.value; - else - throw new Error(`Key ${N.key} already set`); - else if (x) { - const C = this.items.findIndex((M) => x(N, M) < 0); - C === -1 ? this.items.push(N) : this.items.splice(C, 0, N); - } else - this.items.push(N); - } - delete(N) { - const e = v(this.items, N); - return e ? this.items.splice(this.items.indexOf(e), 1).length > 0 : !1; - } - get(N, e) { - const t = v(this.items, N), x = t && t.value; - return !e && x instanceof u ? x.value : x; - } - has(N) { - return !!v(this.items, N); - } - set(N, e) { - this.add(new y(N, e), !0); - } - /** - * @param {*} arg ignored - * @param {*} ctx Conversion context, originally set in Document#toJSON() - * @param {Class} Type If set, forces the returned collection type - * @returns {*} Instance of Type, Map, or Object - */ - toJSON(N, e, t) { - const x = t ? new t() : e && e.mapAsMap ? /* @__PURE__ */ new Map() : {}; - e && e.onCreate && e.onCreate(x); - for (const C of this.items) - C.addToJSMap(e, x); - return x; - } - toString(N, e, t) { - if (!N) - return JSON.stringify(this); - for (const x of this.items) - if (!(x instanceof y)) - throw new Error(`Map items must all be pairs; found ${JSON.stringify(x)} instead`); - return super.toString(N, { - blockItem: (x) => x.str, - flowChars: { - start: "{", - end: "}" - }, - isMap: !0, - itemIndent: N.indent || "" - }, e, t); - } - }, b = "<<", w = class extends y { - constructor(N) { - if (N instanceof y) { - let e = N.value; - e instanceof d || (e = new d(), e.items.push(N.value), e.range = N.value.range), super(N.key, e), this.range = N.range; - } else - super(new u(b), new d()); - this.type = y.Type.MERGE_PAIR; - } - // If the value associated with a merge key is a single mapping node, each of - // its key/value pairs is inserted into the current mapping, unless the key - // already exists in it. If the value associated with the merge key is a - // sequence, then this sequence is expected to contain mapping nodes and each - // of these nodes is merged in turn according to its order in the sequence. - // Keys in mapping nodes earlier in the sequence override keys specified in - // later mapping nodes. -- http://yaml.org/type/merge.html - addToJSMap(N, e) { - for (const { - source: t - } of this.value.items) { - if (!(t instanceof h)) - throw new Error("Merge sources must be maps"); - const x = t.toJSON(null, N, Map); - for (const [C, M] of x) - e instanceof Map ? e.has(C) || e.set(C, M) : e instanceof Set ? e.add(C) : Object.prototype.hasOwnProperty.call(e, C) || Object.defineProperty(e, C, { - value: M, - writable: !0, - enumerable: !0, - configurable: !0 - }); - } - return e; - } - toString(N, e) { - const t = this.value; - if (t.items.length > 1) - return super.toString(N, e); - this.value = t.items[0]; - const x = super.toString(N, e); - return this.value = t, x; - } - }, _ = { - defaultType: s.Type.BLOCK_LITERAL, - lineWidth: 76 - }, O = { - trueStr: "true", - falseStr: "false" - }, P = { - asBigInt: !1 - }, L = { - nullStr: "null" - }, Y = { - defaultType: s.Type.PLAIN, - doubleQuoted: { - jsonEncoding: !1, - minMultiLineLength: 40 - }, - fold: { - lineWidth: 80, - minContentWidth: 20 - } - }; - function H(N, e, t) { - for (const { - format: x, - test: C, - resolve: M - } of e) - if (C) { - const g = N.match(C); - if (g) { - let k = M.apply(null, g); - return k instanceof u || (k = new u(k)), x && (k.format = x), k; - } - } - return t && (N = t(N)), new u(N); - } - var V = "flow", B = "block", ne = "quoted", I = (N, e) => { - let t = N[e + 1]; - for (; t === " " || t === " "; ) { - do - t = N[e += 1]; - while (t && t !== ` -`); - t = N[e + 1]; - } - return e; - }; - function Z(N, e, t, { - indentAtStart: x, - lineWidth: C = 80, - minContentWidth: M = 20, - onFold: g, - onOverflow: k - }) { - if (!C || C < 0) - return N; - const $ = Math.max(1 + M, 1 + C - e.length); - if (N.length <= $) - return N; - const D = [], X = {}; - let J = C - e.length; - typeof x == "number" && (x > C - Math.max(2, M) ? D.push(0) : J = C - x); - let ee, re, ue = !1, me = -1, we = -1, xe = -1; - t === B && (me = I(N, me), me !== -1 && (J = me + $)); - for (let Le; Le = N[me += 1]; ) { - if (t === ne && Le === "\\") { - switch (we = me, N[me + 1]) { - case "x": - me += 3; - break; - case "u": - me += 5; - break; - case "U": - me += 9; - break; - default: - me += 1; - } - xe = me; - } - if (Le === ` -`) - t === B && (me = I(N, me)), J = me + $, ee = void 0; - else { - if (Le === " " && re && re !== " " && re !== ` -` && re !== " ") { - const Pe = N[me + 1]; - Pe && Pe !== " " && Pe !== ` -` && Pe !== " " && (ee = me); - } - if (me >= J) - if (ee) - D.push(ee), J = ee + $, ee = void 0; - else if (t === ne) { - for (; re === " " || re === " "; ) - re = Le, Le = N[me += 1], ue = !0; - const Pe = me > xe + 1 ? me - 2 : we - 1; - if (X[Pe]) - return N; - D.push(Pe), X[Pe] = !0, J = Pe + $, ee = void 0; - } else - ue = !0; - } - re = Le; - } - if (ue && k && k(), D.length === 0) - return N; - g && g(); - let _e = N.slice(0, D[0]); - for (let Le = 0; Le < D.length; ++Le) { - const Pe = D[Le], De = D[Le + 1] || N.length; - Pe === 0 ? _e = ` -${e}${N.slice(0, De)}` : (t === ne && X[Pe] && (_e += `${N[Pe]}\\`), _e += ` -${e}${N.slice(Pe + 1, De)}`); - } - return _e; - } - var te = ({ - indentAtStart: N - }) => N ? Object.assign({ - indentAtStart: N - }, Y.fold) : Y.fold, he = (N) => /^(%|---|\.\.\.)/m.test(N); - function le(N, e, t) { - if (!e || e < 0) - return !1; - const x = e - t, C = N.length; - if (C <= x) - return !1; - for (let M = 0, g = 0; M < C; ++M) - if (N[M] === ` -`) { - if (M - g > x) - return !0; - if (g = M + 1, C - g <= x) - return !1; - } - return !0; - } - function ve(N, e) { - const { - implicitKey: t - } = e, { - jsonEncoding: x, - minMultiLineLength: C - } = Y.doubleQuoted, M = JSON.stringify(N); - if (x) - return M; - const g = e.indent || (he(N) ? " " : ""); - let k = "", $ = 0; - for (let D = 0, X = M[D]; X; X = M[++D]) - if (X === " " && M[D + 1] === "\\" && M[D + 2] === "n" && (k += M.slice($, D) + "\\ ", D += 1, $ = D, X = "\\"), X === "\\") - switch (M[D + 1]) { - case "u": - { - k += M.slice($, D); - const J = M.substr(D + 2, 4); - switch (J) { - case "0000": - k += "\\0"; - break; - case "0007": - k += "\\a"; - break; - case "000b": - k += "\\v"; - break; - case "001b": - k += "\\e"; - break; - case "0085": - k += "\\N"; - break; - case "00a0": - k += "\\_"; - break; - case "2028": - k += "\\L"; - break; - case "2029": - k += "\\P"; - break; - default: - J.substr(0, 2) === "00" ? k += "\\x" + J.substr(2) : k += M.substr(D, 6); - } - D += 5, $ = D + 1; - } - break; - case "n": - if (t || M[D + 2] === '"' || M.length < C) - D += 1; - else { - for (k += M.slice($, D) + ` - -`; M[D + 2] === "\\" && M[D + 3] === "n" && M[D + 4] !== '"'; ) - k += ` -`, D += 2; - k += g, M[D + 2] === " " && (k += "\\"), D += 1, $ = D + 1; - } - break; - default: - D += 1; - } - return k = $ ? k + M.slice($) : M, t ? k : Z(k, g, ne, te(e)); - } - function oe(N, e) { - if (e.implicitKey) { - if (/\n/.test(N)) - return ve(N, e); - } else if (/[ \t]\n|\n[ \t]/.test(N)) - return ve(N, e); - const t = e.indent || (he(N) ? " " : ""), x = "'" + N.replace(/'/g, "''").replace(/\n+/g, `$& -${t}`) + "'"; - return e.implicitKey ? x : Z(x, t, V, te(e)); - } - function fe({ - comment: N, - type: e, - value: t - }, x, C, M) { - if (/\n[\t ]+$/.test(t) || /^\s*$/.test(t)) - return ve(t, x); - const g = x.indent || (x.forceBlockIndent || he(t) ? " " : ""), k = g ? "2" : "1", $ = e === s.Type.BLOCK_FOLDED ? !1 : e === s.Type.BLOCK_LITERAL ? !0 : !le(t, Y.fold.lineWidth, g.length); - let D = $ ? "|" : ">"; - if (!t) - return D + ` -`; - let X = "", J = ""; - if (t = t.replace(/[\n\t ]*$/, (re) => { - const ue = re.indexOf(` -`); - return ue === -1 ? D += "-" : (t === re || ue !== re.length - 1) && (D += "+", M && M()), J = re.replace(/\n$/, ""), ""; - }).replace(/^[\n ]*/, (re) => { - re.indexOf(" ") !== -1 && (D += k); - const ue = re.match(/ +$/); - return ue ? (X = re.slice(0, -ue[0].length), ue[0]) : (X = re, ""); - }), J && (J = J.replace(/\n+(?!\n|$)/g, `$&${g}`)), X && (X = X.replace(/\n+/g, `$&${g}`)), N && (D += " #" + N.replace(/ ?[\r\n]+/g, " "), C && C()), !t) - return `${D}${k} -${g}${J}`; - if ($) - return t = t.replace(/\n+/g, `$&${g}`), `${D} -${g}${X}${t}${J}`; - t = t.replace(/\n+/g, ` -$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${g}`); - const ee = Z(`${X}${t}${J}`, g, B, Y.fold); - return `${D} -${g}${ee}`; - } - function j(N, e, t, x) { - const { - comment: C, - type: M, - value: g - } = N, { - actualString: k, - implicitKey: $, - indent: D, - inFlow: X - } = e; - if ($ && /[\n[\]{},]/.test(g) || X && /[[\]{},]/.test(g)) - return ve(g, e); - if (!g || /^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(g)) - return $ || X || g.indexOf(` -`) === -1 ? g.indexOf('"') !== -1 && g.indexOf("'") === -1 ? oe(g, e) : ve(g, e) : fe(N, e, t, x); - if (!$ && !X && M !== s.Type.PLAIN && g.indexOf(` -`) !== -1) - return fe(N, e, t, x); - if (D === "" && he(g)) - return e.forceBlockIndent = !0, fe(N, e, t, x); - const J = g.replace(/\n+/g, `$& -${D}`); - if (k) { - const { - tags: re - } = e.doc.schema; - if (typeof H(J, re, re.scalarFallback).value != "string") - return ve(g, e); - } - const ee = $ ? J : Z(J, D, V, te(e)); - return C && !X && (ee.indexOf(` -`) !== -1 || C.indexOf(` -`) !== -1) ? (t && t(), n(ee, D, C)) : ee; - } - function ie(N, e, t, x) { - const { - defaultType: C - } = Y, { - implicitKey: M, - inFlow: g - } = e; - let { - type: k, - value: $ - } = N; - typeof $ != "string" && ($ = String($), N = Object.assign({}, N, { - value: $ - })); - const D = (J) => { - switch (J) { - case s.Type.BLOCK_FOLDED: - case s.Type.BLOCK_LITERAL: - return fe(N, e, t, x); - case s.Type.QUOTE_DOUBLE: - return ve($, e); - case s.Type.QUOTE_SINGLE: - return oe($, e); - case s.Type.PLAIN: - return j(N, e, t, x); - default: - return null; - } - }; - (k !== s.Type.QUOTE_DOUBLE && /[\x00-\x08\x0b-\x1f\x7f-\x9f]/.test($) || (M || g) && (k === s.Type.BLOCK_FOLDED || k === s.Type.BLOCK_LITERAL)) && (k = s.Type.QUOTE_DOUBLE); - let X = D(k); - if (X === null && (X = D(C), X === null)) - throw new Error(`Unsupported default string type ${C}`); - return X; - } - function pe({ - format: N, - minFractionDigits: e, - tag: t, - value: x - }) { - if (typeof x == "bigint") - return String(x); - if (!isFinite(x)) - return isNaN(x) ? ".nan" : x < 0 ? "-.inf" : ".inf"; - let C = JSON.stringify(x); - if (!N && e && (!t || t === "tag:yaml.org,2002:float") && /^\d/.test(C)) { - let M = C.indexOf("."); - M < 0 && (M = C.length, C += "."); - let g = e - (C.length - M - 1); - for (; g-- > 0; ) - C += "0"; - } - return C; - } - function se(N, e) { - let t, x; - switch (e.type) { - case s.Type.FLOW_MAP: - t = "}", x = "flow map"; - break; - case s.Type.FLOW_SEQ: - t = "]", x = "flow sequence"; - break; - default: - N.push(new s.YAMLSemanticError(e, "Not a flow collection!?")); - return; - } - let C; - for (let M = e.items.length - 1; M >= 0; --M) { - const g = e.items[M]; - if (!g || g.type !== s.Type.COMMENT) { - C = g; - break; - } - } - if (C && C.char !== t) { - const M = `Expected ${x} to end with ${t}`; - let g; - typeof C.offset == "number" ? (g = new s.YAMLSemanticError(e, M), g.offset = C.offset + 1) : (g = new s.YAMLSemanticError(C, M), C.range && C.range.end && (g.offset = C.range.end - C.range.start)), N.push(g); - } - } - function W(N, e) { - const t = e.context.src[e.range.start - 1]; - if (t !== ` -` && t !== " " && t !== " ") { - const x = "Comments must be separated from other tokens by white space characters"; - N.push(new s.YAMLSemanticError(e, x)); - } - } - function G(N, e) { - const t = String(e), x = t.substr(0, 8) + "..." + t.substr(-8); - return new s.YAMLSemanticError(N, `The "${x}" key is too long`); - } - function ae(N, e) { - for (const { - afterKey: t, - before: x, - comment: C - } of e) { - let M = N.items[x]; - M ? (t && M.value && (M = M.value), C === void 0 ? (t || !M.commentBefore) && (M.spaceBefore = !0) : M.commentBefore ? M.commentBefore += ` -` + C : M.commentBefore = C) : C !== void 0 && (N.comment ? N.comment += ` -` + C : N.comment = C); - } - } - function ge(N, e) { - const t = e.strValue; - return t ? typeof t == "string" ? t : (t.errors.forEach((x) => { - x.source || (x.source = e), N.errors.push(x); - }), t.str) : ""; - } - function Ee(N, e) { - const { - handle: t, - suffix: x - } = e.tag; - let C = N.tagPrefixes.find((M) => M.handle === t); - if (!C) { - const M = N.getDefaults().tagPrefixes; - if (M && (C = M.find((g) => g.handle === t)), !C) - throw new s.YAMLSemanticError(e, `The ${t} tag handle is non-default and was not declared.`); - } - if (!x) - throw new s.YAMLSemanticError(e, `The ${t} tag has no suffix.`); - if (t === "!" && (N.version || N.options.version) === "1.0") { - if (x[0] === "^") - return N.warnings.push(new s.YAMLWarning(e, "YAML 1.0 ^ tag expansion is not supported")), x; - if (/[:/]/.test(x)) { - const M = x.match(/^([a-z0-9-]+)\/(.*)/i); - return M ? `tag:${M[1]}.yaml.org,2002:${M[2]}` : `tag:${x}`; - } - } - return C.prefix + decodeURIComponent(x); - } - function ye(N, e) { - const { - tag: t, - type: x - } = e; - let C = !1; - if (t) { - const { - handle: M, - suffix: g, - verbatim: k - } = t; - if (k) { - if (k !== "!" && k !== "!!") - return k; - const $ = `Verbatim tags aren't resolved, so ${k} is invalid.`; - N.errors.push(new s.YAMLSemanticError(e, $)); - } else if (M === "!" && !g) - C = !0; - else - try { - return Ee(N, e); - } catch ($) { - N.errors.push($); - } - } - switch (x) { - case s.Type.BLOCK_FOLDED: - case s.Type.BLOCK_LITERAL: - case s.Type.QUOTE_DOUBLE: - case s.Type.QUOTE_SINGLE: - return s.defaultTags.STR; - case s.Type.FLOW_MAP: - case s.Type.MAP: - return s.defaultTags.MAP; - case s.Type.FLOW_SEQ: - case s.Type.SEQ: - return s.defaultTags.SEQ; - case s.Type.PLAIN: - return C ? s.defaultTags.STR : null; - default: - return null; - } - } - function Oe(N, e, t) { - const { - tags: x - } = N.schema, C = []; - for (const g of x) - if (g.tag === t) - if (g.test) - C.push(g); - else { - const k = g.resolve(N, e); - return k instanceof l ? k : new u(k); - } - const M = ge(N, e); - return typeof M == "string" && C.length > 0 ? H(M, C, x.scalarFallback) : null; - } - function Ae({ - type: N - }) { - switch (N) { - case s.Type.FLOW_MAP: - case s.Type.MAP: - return s.defaultTags.MAP; - case s.Type.FLOW_SEQ: - case s.Type.SEQ: - return s.defaultTags.SEQ; - default: - return s.defaultTags.STR; - } - } - function Te(N, e, t) { - try { - const x = Oe(N, e, t); - if (x) - return t && e.tag && (x.tag = t), x; - } catch (x) { - return x.source || (x.source = e), N.errors.push(x), null; - } - try { - const x = Ae(e); - if (!x) - throw new Error(`The tag ${t} is unavailable`); - const C = `The tag ${t} is unavailable, falling back to ${x}`; - N.warnings.push(new s.YAMLWarning(e, C)); - const M = Oe(N, e, x); - return M.tag = t, M; - } catch (x) { - const C = new s.YAMLReferenceError(e, x.message); - return C.stack = x.stack, N.errors.push(C), null; - } - } - var U = (N) => { - if (!N) - return !1; - const { - type: e - } = N; - return e === s.Type.MAP_KEY || e === s.Type.MAP_VALUE || e === s.Type.SEQ_ITEM; - }; - function q(N, e) { - const t = { - before: [], - after: [] - }; - let x = !1, C = !1; - const M = U(e.context.parent) ? e.context.parent.props.concat(e.props) : e.props; - for (const { - start: g, - end: k - } of M) - switch (e.context.src[g]) { - case s.Char.COMMENT: { - if (!e.commentHasRequiredWhitespace(g)) { - const J = "Comments must be separated from other tokens by white space characters"; - N.push(new s.YAMLSemanticError(e, J)); - } - const { - header: $, - valueRange: D - } = e; - (D && (g > D.start || $ && g > $.start) ? t.after : t.before).push(e.context.src.slice(g + 1, k)); - break; - } - case s.Char.ANCHOR: - if (x) { - const $ = "A node can have at most one anchor"; - N.push(new s.YAMLSemanticError(e, $)); - } - x = !0; - break; - case s.Char.TAG: - if (C) { - const $ = "A node can have at most one tag"; - N.push(new s.YAMLSemanticError(e, $)); - } - C = !0; - break; - } - return { - comments: t, - hasAnchor: x, - hasTag: C - }; - } - function de(N, e) { - const { - anchors: t, - errors: x, - schema: C - } = N; - if (e.type === s.Type.ALIAS) { - const g = e.rawValue, k = t.getNode(g); - if (!k) { - const D = `Aliased anchor not found: ${g}`; - return x.push(new s.YAMLReferenceError(e, D)), null; - } - const $ = new T(k); - return t._cstAliases.push($), $; - } - const M = ye(N, e); - if (M) - return Te(N, e, M); - if (e.type !== s.Type.PLAIN) { - const g = `Failed to resolve ${e.type} node here`; - return x.push(new s.YAMLSyntaxError(e, g)), null; - } - try { - const g = ge(N, e); - return H(g, C.tags, C.tags.scalarFallback); - } catch (g) { - return g.source || (g.source = e), x.push(g), null; - } - } - function F(N, e) { - if (!e) - return null; - e.error && N.errors.push(e.error); - const { - comments: t, - hasAnchor: x, - hasTag: C - } = q(N.errors, e); - if (x) { - const { - anchors: g - } = N, k = e.anchor, $ = g.getNode(k); - $ && (g.map[g.newName(k)] = $), g.map[k] = e; - } - if (e.type === s.Type.ALIAS && (x || C)) { - const g = "An alias node must not specify any properties"; - N.errors.push(new s.YAMLSemanticError(e, g)); - } - const M = de(N, e); - if (M) { - M.range = [e.range.start, e.range.end], N.options.keepCstNodes && (M.cstNode = e), N.options.keepNodeTypes && (M.type = e.type); - const g = t.before.join(` -`); - g && (M.commentBefore = M.commentBefore ? `${M.commentBefore} -${g}` : g); - const k = t.after.join(` -`); - k && (M.comment = M.comment ? `${M.comment} -${k}` : k); - } - return e.resolved = M; - } - function ce(N, e) { - if (e.type !== s.Type.MAP && e.type !== s.Type.FLOW_MAP) { - const g = `A ${e.type} node cannot be resolved as a mapping`; - return N.errors.push(new s.YAMLSyntaxError(e, g)), null; - } - const { - comments: t, - items: x - } = e.type === s.Type.FLOW_MAP ? K(N, e) : R(N, e), C = new h(); - C.items = x, ae(C, t); - let M = !1; - for (let g = 0; g < x.length; ++g) { - const { - key: k - } = x[g]; - if (k instanceof l && (M = !0), N.schema.merge && k && k.value === b) { - x[g] = new w(x[g]); - const $ = x[g].value.items; - let D = null; - $.some((X) => { - if (X instanceof T) { - const { - type: J - } = X.source; - return J === s.Type.MAP || J === s.Type.FLOW_MAP ? !1 : D = "Merge nodes aliases can only point to maps"; - } - return D = "Merge nodes can only have Alias nodes as values"; - }), D && N.errors.push(new s.YAMLSemanticError(e, D)); - } else - for (let $ = g + 1; $ < x.length; ++$) { - const { - key: D - } = x[$]; - if (k === D || k && D && Object.prototype.hasOwnProperty.call(k, "value") && k.value === D.value) { - const X = `Map keys must be unique; "${k}" is repeated`; - N.errors.push(new s.YAMLSemanticError(e, X)); - break; - } - } - } - if (M && !N.options.mapAsMap) { - const g = "Keys with collection values will be stringified as YAML due to JS Object restrictions. Use mapAsMap: true to avoid this."; - N.warnings.push(new s.YAMLWarning(e, g)); - } - return e.resolved = C, C; - } - var m = ({ - context: { - lineStart: N, - node: e, - src: t - }, - props: x - }) => { - if (x.length === 0) - return !1; - const { - start: C - } = x[0]; - if (e && C > e.valueRange.start || t[C] !== s.Char.COMMENT) - return !1; - for (let M = N; M < C; ++M) - if (t[M] === ` -`) - return !1; - return !0; - }; - function A(N, e) { - if (!m(N)) - return; - const t = N.getPropValue(0, s.Char.COMMENT, !0); - let x = !1; - const C = e.value.commentBefore; - if (C && C.startsWith(t)) - e.value.commentBefore = C.substr(t.length + 1), x = !0; - else { - const M = e.value.comment; - !N.node && M && M.startsWith(t) && (e.value.comment = M.substr(t.length + 1), x = !0); - } - x && (e.comment = t); - } - function R(N, e) { - const t = [], x = []; - let C, M = null; - for (let g = 0; g < e.items.length; ++g) { - const k = e.items[g]; - switch (k.type) { - case s.Type.BLANK_LINE: - t.push({ - afterKey: !!C, - before: x.length - }); - break; - case s.Type.COMMENT: - t.push({ - afterKey: !!C, - before: x.length, - comment: k.comment - }); - break; - case s.Type.MAP_KEY: - C !== void 0 && x.push(new y(C)), k.error && N.errors.push(k.error), C = F(N, k.node), M = null; - break; - case s.Type.MAP_VALUE: - { - if (C === void 0 && (C = null), k.error && N.errors.push(k.error), !k.context.atLineStart && k.node && k.node.type === s.Type.MAP && !k.node.context.atLineStart) { - const X = "Nested mappings are not allowed in compact mappings"; - N.errors.push(new s.YAMLSemanticError(k.node, X)); - } - let $ = k.node; - if (!$ && k.props.length > 0) { - $ = new s.PlainValue(s.Type.PLAIN, []), $.context = { - parent: k, - src: k.context.src - }; - const X = k.range.start + 1; - if ($.range = { - start: X, - end: X - }, $.valueRange = { - start: X, - end: X - }, typeof k.range.origStart == "number") { - const J = k.range.origStart + 1; - $.range.origStart = $.range.origEnd = J, $.valueRange.origStart = $.valueRange.origEnd = J; - } - } - const D = new y(C, F(N, $)); - A(k, D), x.push(D), C && typeof M == "number" && k.range.start > M + 1024 && N.errors.push(G(e, C)), C = void 0, M = null; - } - break; - default: - C !== void 0 && x.push(new y(C)), C = F(N, k), M = k.range.start, k.error && N.errors.push(k.error); - e: - for (let $ = g + 1; ; ++$) { - const D = e.items[$]; - switch (D && D.type) { - case s.Type.BLANK_LINE: - case s.Type.COMMENT: - continue e; - case s.Type.MAP_VALUE: - break e; - default: { - const X = "Implicit map keys need to be followed by map values"; - N.errors.push(new s.YAMLSemanticError(k, X)); - break e; - } - } - } - if (k.valueRangeContainsNewline) { - const $ = "Implicit map keys need to be on a single line"; - N.errors.push(new s.YAMLSemanticError(k, $)); - } - } - } - return C !== void 0 && x.push(new y(C)), { - comments: t, - items: x - }; - } - function K(N, e) { - const t = [], x = []; - let C, M = !1, g = "{"; - for (let k = 0; k < e.items.length; ++k) { - const $ = e.items[k]; - if (typeof $.char == "string") { - const { - char: D, - offset: X - } = $; - if (D === "?" && C === void 0 && !M) { - M = !0, g = ":"; - continue; - } - if (D === ":") { - if (C === void 0 && (C = null), g === ":") { - g = ","; - continue; - } - } else if (M && (C === void 0 && D !== "," && (C = null), M = !1), C !== void 0 && (x.push(new y(C)), C = void 0, D === ",")) { - g = ":"; - continue; - } - if (D === "}") { - if (k === e.items.length - 1) - continue; - } else if (D === g) { - g = ":"; - continue; - } - const J = `Flow map contains an unexpected ${D}`, ee = new s.YAMLSyntaxError(e, J); - ee.offset = X, N.errors.push(ee); - } else $.type === s.Type.BLANK_LINE ? t.push({ - afterKey: !!C, - before: x.length - }) : $.type === s.Type.COMMENT ? (W(N.errors, $), t.push({ - afterKey: !!C, - before: x.length, - comment: $.comment - })) : C === void 0 ? (g === "," && N.errors.push(new s.YAMLSemanticError($, "Separator , missing in flow map")), C = F(N, $)) : (g !== "," && N.errors.push(new s.YAMLSemanticError($, "Indicator : missing in flow map entry")), x.push(new y(C, F(N, $))), C = void 0, M = !1); - } - return se(N.errors, e), C !== void 0 && x.push(new y(C)), { - comments: t, - items: x - }; - } - function Q(N, e) { - if (e.type !== s.Type.SEQ && e.type !== s.Type.FLOW_SEQ) { - const M = `A ${e.type} node cannot be resolved as a sequence`; - return N.errors.push(new s.YAMLSyntaxError(e, M)), null; - } - const { - comments: t, - items: x - } = e.type === s.Type.FLOW_SEQ ? be(N, e) : z(N, e), C = new d(); - if (C.items = x, ae(C, t), !N.options.mapAsMap && x.some((M) => M instanceof y && M.key instanceof l)) { - const M = "Keys with collection values will be stringified as YAML due to JS Object restrictions. Use mapAsMap: true to avoid this."; - N.warnings.push(new s.YAMLWarning(e, M)); - } - return e.resolved = C, C; - } - function z(N, e) { - const t = [], x = []; - for (let C = 0; C < e.items.length; ++C) { - const M = e.items[C]; - switch (M.type) { - case s.Type.BLANK_LINE: - t.push({ - before: x.length - }); - break; - case s.Type.COMMENT: - t.push({ - comment: M.comment, - before: x.length - }); - break; - case s.Type.SEQ_ITEM: - if (M.error && N.errors.push(M.error), x.push(F(N, M.node)), M.hasProps) { - const g = "Sequence items cannot have tags or anchors before the - indicator"; - N.errors.push(new s.YAMLSemanticError(M, g)); - } - break; - default: - M.error && N.errors.push(M.error), N.errors.push(new s.YAMLSyntaxError(M, `Unexpected ${M.type} node in sequence`)); - } - } - return { - comments: t, - items: x - }; - } - function be(N, e) { - const t = [], x = []; - let C = !1, M, g = null, k = "[", $ = null; - for (let D = 0; D < e.items.length; ++D) { - const X = e.items[D]; - if (typeof X.char == "string") { - const { - char: J, - offset: ee - } = X; - if (J !== ":" && (C || M !== void 0) && (C && M === void 0 && (M = k ? x.pop() : null), x.push(new y(M)), C = !1, M = void 0, g = null), J === k) - k = null; - else if (!k && J === "?") - C = !0; - else if (k !== "[" && J === ":" && M === void 0) { - if (k === ",") { - if (M = x.pop(), M instanceof y) { - const re = "Chaining flow sequence pairs is invalid", ue = new s.YAMLSemanticError(e, re); - ue.offset = ee, N.errors.push(ue); - } - if (!C && typeof g == "number") { - const re = X.range ? X.range.start : X.offset; - re > g + 1024 && N.errors.push(G(e, M)); - const { - src: ue - } = $.context; - for (let me = g; me < re; ++me) - if (ue[me] === ` -`) { - const we = "Implicit keys of flow sequence pairs need to be on a single line"; - N.errors.push(new s.YAMLSemanticError($, we)); - break; - } - } - } else - M = null; - g = null, C = !1, k = null; - } else if (k === "[" || J !== "]" || D < e.items.length - 1) { - const re = `Flow sequence contains an unexpected ${J}`, ue = new s.YAMLSyntaxError(e, re); - ue.offset = ee, N.errors.push(ue); - } - } else if (X.type === s.Type.BLANK_LINE) - t.push({ - before: x.length - }); - else if (X.type === s.Type.COMMENT) - W(N.errors, X), t.push({ - comment: X.comment, - before: x.length - }); - else { - if (k) { - const ee = `Expected a ${k} in flow sequence`; - N.errors.push(new s.YAMLSemanticError(X, ee)); - } - const J = F(N, X); - M === void 0 ? (x.push(J), $ = X) : (x.push(new y(M, J)), M = void 0), g = X.range.start, k = ","; - } - } - return se(N.errors, e), M !== void 0 && x.push(new y(M)), { - comments: t, - items: x - }; - } - r.Alias = T, r.Collection = l, r.Merge = w, r.Node = p, r.Pair = y, r.Scalar = u, r.YAMLMap = h, r.YAMLSeq = d, r.addComment = o, r.binaryOptions = _, r.boolOptions = O, r.findPair = v, r.intOptions = P, r.isEmptyPath = c, r.nullOptions = L, r.resolveMap = ce, r.resolveNode = F, r.resolveSeq = Q, r.resolveString = ge, r.strOptions = Y, r.stringifyNumber = pe, r.stringifyString = ie, r.toJSON = i; - } -}), Sn = Ue({ - "node_modules/yaml/dist/warnings-1000a372.js"(r) { - var s = Rt(), n = yr(), o = { - identify: (H) => H instanceof Uint8Array, - // Buffer inherits from Uint8Array - default: !1, - tag: "tag:yaml.org,2002:binary", - /** - * Returns a Buffer in node and an Uint8Array in browsers - * - * To use the resulting buffer as an image, you'll want to do something like: - * - * const blob = new Blob([buffer], { type: 'image/jpeg' }) - * document.querySelector('#photo').src = URL.createObjectURL(blob) - */ - resolve: (H, V) => { - const B = n.resolveString(H, V); - if (typeof Buffer == "function") - return Buffer.from(B, "base64"); - if (typeof atob == "function") { - const ne = atob(B.replace(/[\n\r]/g, "")), I = new Uint8Array(ne.length); - for (let Z = 0; Z < ne.length; ++Z) - I[Z] = ne.charCodeAt(Z); - return I; - } else { - const ne = "This environment does not support reading binary tags; either Buffer or atob is required"; - return H.errors.push(new s.YAMLReferenceError(V, ne)), null; - } - }, - options: n.binaryOptions, - stringify: ({ - comment: H, - type: V, - value: B - }, ne, I, Z) => { - let te; - if (typeof Buffer == "function") - te = B instanceof Buffer ? B.toString("base64") : Buffer.from(B.buffer).toString("base64"); - else if (typeof btoa == "function") { - let he = ""; - for (let le = 0; le < B.length; ++le) - he += String.fromCharCode(B[le]); - te = btoa(he); - } else - throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required"); - if (V || (V = n.binaryOptions.defaultType), V === s.Type.QUOTE_DOUBLE) - B = te; - else { - const { - lineWidth: he - } = n.binaryOptions, le = Math.ceil(te.length / he), ve = new Array(le); - for (let oe = 0, fe = 0; oe < le; ++oe, fe += he) - ve[oe] = te.substr(fe, he); - B = ve.join(V === s.Type.BLOCK_LITERAL ? ` -` : " "); - } - return n.stringifyString({ - comment: H, - type: V, - value: B - }, ne, I, Z); - } - }; - function p(H, V) { - const B = n.resolveSeq(H, V); - for (let ne = 0; ne < B.items.length; ++ne) { - let I = B.items[ne]; - if (!(I instanceof n.Pair)) { - if (I instanceof n.YAMLMap) { - if (I.items.length > 1) { - const te = "Each pair must have its own sequence indicator"; - throw new s.YAMLSemanticError(V, te); - } - const Z = I.items[0] || new n.Pair(); - I.commentBefore && (Z.commentBefore = Z.commentBefore ? `${I.commentBefore} -${Z.commentBefore}` : I.commentBefore), I.comment && (Z.comment = Z.comment ? `${I.comment} -${Z.comment}` : I.comment), I = Z; - } - B.items[ne] = I instanceof n.Pair ? I : new n.Pair(I); - } - } - return B; - } - function i(H, V, B) { - const ne = new n.YAMLSeq(H); - ne.tag = "tag:yaml.org,2002:pairs"; - for (const I of V) { - let Z, te; - if (Array.isArray(I)) - if (I.length === 2) - Z = I[0], te = I[1]; - else - throw new TypeError(`Expected [key, value] tuple: ${I}`); - else if (I && I instanceof Object) { - const le = Object.keys(I); - if (le.length === 1) - Z = le[0], te = I[Z]; - else - throw new TypeError(`Expected { key: value } tuple: ${I}`); - } else - Z = I; - const he = H.createPair(Z, te, B); - ne.items.push(he); - } - return ne; - } - var u = { - default: !1, - tag: "tag:yaml.org,2002:pairs", - resolve: p, - createNode: i - }, a = class Cn extends n.YAMLSeq { - constructor() { - super(), s._defineProperty(this, "add", n.YAMLMap.prototype.add.bind(this)), s._defineProperty(this, "delete", n.YAMLMap.prototype.delete.bind(this)), s._defineProperty(this, "get", n.YAMLMap.prototype.get.bind(this)), s._defineProperty(this, "has", n.YAMLMap.prototype.has.bind(this)), s._defineProperty(this, "set", n.YAMLMap.prototype.set.bind(this)), this.tag = Cn.tag; - } - toJSON(V, B) { - const ne = /* @__PURE__ */ new Map(); - B && B.onCreate && B.onCreate(ne); - for (const I of this.items) { - let Z, te; - if (I instanceof n.Pair ? (Z = n.toJSON(I.key, "", B), te = n.toJSON(I.value, Z, B)) : Z = n.toJSON(I, "", B), ne.has(Z)) - throw new Error("Ordered maps must not include duplicate keys"); - ne.set(Z, te); - } - return ne; - } - }; - s._defineProperty(a, "tag", "tag:yaml.org,2002:omap"); - function c(H, V) { - const B = p(H, V), ne = []; - for (const { - key: I - } of B.items) - if (I instanceof n.Scalar) - if (ne.includes(I.value)) { - const Z = "Ordered maps must not include duplicate keys"; - throw new s.YAMLSemanticError(V, Z); - } else - ne.push(I.value); - return Object.assign(new a(), B); - } - function l(H, V, B) { - const ne = i(H, V, B), I = new a(); - return I.items = ne.items, I; - } - var f = { - identify: (H) => H instanceof Map, - nodeClass: a, - default: !1, - tag: "tag:yaml.org,2002:omap", - resolve: c, - createNode: l - }, d = class Tn extends n.YAMLMap { - constructor() { - super(), this.tag = Tn.tag; - } - add(V) { - const B = V instanceof n.Pair ? V : new n.Pair(V); - n.findPair(this.items, B.key) || this.items.push(B); - } - get(V, B) { - const ne = n.findPair(this.items, V); - return !B && ne instanceof n.Pair ? ne.key instanceof n.Scalar ? ne.key.value : ne.key : ne; - } - set(V, B) { - if (typeof B != "boolean") - throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof B}`); - const ne = n.findPair(this.items, V); - ne && !B ? this.items.splice(this.items.indexOf(ne), 1) : !ne && B && this.items.push(new n.Pair(V)); - } - toJSON(V, B) { - return super.toJSON(V, B, Set); - } - toString(V, B, ne) { - if (!V) - return JSON.stringify(this); - if (this.hasAllNullValues()) - return super.toString(V, B, ne); - throw new Error("Set items must all have null values"); - } - }; - s._defineProperty(d, "tag", "tag:yaml.org,2002:set"); - function E(H, V) { - const B = n.resolveMap(H, V); - if (!B.hasAllNullValues()) - throw new s.YAMLSemanticError(V, "Set items must all have null values"); - return Object.assign(new d(), B); - } - function y(H, V, B) { - const ne = new d(); - for (const I of V) - ne.items.push(H.createPair(I, null, B)); - return ne; - } - var S = { - identify: (H) => H instanceof Set, - nodeClass: d, - default: !1, - tag: "tag:yaml.org,2002:set", - resolve: E, - createNode: y - }, T = (H, V) => { - const B = V.split(":").reduce((ne, I) => ne * 60 + Number(I), 0); - return H === "-" ? -B : B; - }, v = ({ - value: H - }) => { - if (isNaN(H) || !isFinite(H)) - return n.stringifyNumber(H); - let V = ""; - H < 0 && (V = "-", H = Math.abs(H)); - const B = [H % 60]; - return H < 60 ? B.unshift(0) : (H = Math.round((H - B[0]) / 60), B.unshift(H % 60), H >= 60 && (H = Math.round((H - B[0]) / 60), B.unshift(H))), V + B.map((ne) => ne < 10 ? "0" + String(ne) : String(ne)).join(":").replace(/000000\d*$/, ""); - }, h = { - identify: (H) => typeof H == "number", - default: !0, - tag: "tag:yaml.org,2002:int", - format: "TIME", - test: /^([-+]?)([0-9][0-9_]*(?::[0-5]?[0-9])+)$/, - resolve: (H, V, B) => T(V, B.replace(/_/g, "")), - stringify: v - }, b = { - identify: (H) => typeof H == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - format: "TIME", - test: /^([-+]?)([0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*)$/, - resolve: (H, V, B) => T(V, B.replace(/_/g, "")), - stringify: v - }, w = { - identify: (H) => H instanceof Date, - default: !0, - tag: "tag:yaml.org,2002:timestamp", - // If the time zone is omitted, the timestamp is assumed to be specified in UTC. The time part - // may be omitted altogether, resulting in a date format. In such a case, the time part is - // assumed to be 00:00:00Z (start of day, UTC). - test: RegExp("^(?:([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?)$"), - resolve: (H, V, B, ne, I, Z, te, he, le) => { - he && (he = (he + "00").substr(1, 3)); - let ve = Date.UTC(V, B - 1, ne, I || 0, Z || 0, te || 0, he || 0); - if (le && le !== "Z") { - let oe = T(le[0], le.slice(1)); - Math.abs(oe) < 30 && (oe *= 60), ve -= 6e4 * oe; - } - return new Date(ve); - }, - stringify: ({ - value: H - }) => H.toISOString().replace(/((T00:00)?:00)?\.000Z$/, "") - }; - function _(H) { - const V = typeof process < "u" && process.env || {}; - return H ? typeof YAML_SILENCE_DEPRECATION_WARNINGS < "u" ? !YAML_SILENCE_DEPRECATION_WARNINGS : !V.YAML_SILENCE_DEPRECATION_WARNINGS : typeof YAML_SILENCE_WARNINGS < "u" ? !YAML_SILENCE_WARNINGS : !V.YAML_SILENCE_WARNINGS; - } - function O(H, V) { - if (_(!1)) { - const B = typeof process < "u" && process.emitWarning; - B ? B(H, V) : console.warn(V ? `${V}: ${H}` : H); - } - } - function P(H) { - if (_(!0)) { - const V = H.replace(/.*yaml[/\\]/i, "").replace(/\.js$/, "").replace(/\\/g, "/"); - O(`The endpoint 'yaml/${V}' will be removed in a future release.`, "DeprecationWarning"); - } - } - var L = {}; - function Y(H, V) { - if (!L[H] && _(!0)) { - L[H] = !0; - let B = `The option '${H}' will be removed in a future release`; - B += V ? `, use '${V}' instead.` : ".", O(B, "DeprecationWarning"); - } - } - r.binary = o, r.floatTime = b, r.intTime = h, r.omap = f, r.pairs = u, r.set = S, r.timestamp = w, r.warn = O, r.warnFileDeprecation = P, r.warnOptionDeprecation = Y; - } -}), ki = Ue({ - "node_modules/yaml/dist/Schema-88e323a7.js"(r) { - var s = Rt(), n = yr(), o = Sn(); - function p(j, ie, pe) { - const se = new n.YAMLMap(j); - if (ie instanceof Map) - for (const [W, G] of ie) - se.items.push(j.createPair(W, G, pe)); - else if (ie && typeof ie == "object") - for (const W of Object.keys(ie)) - se.items.push(j.createPair(W, ie[W], pe)); - return typeof j.sortMapEntries == "function" && se.items.sort(j.sortMapEntries), se; - } - var i = { - createNode: p, - default: !0, - nodeClass: n.YAMLMap, - tag: "tag:yaml.org,2002:map", - resolve: n.resolveMap - }; - function u(j, ie, pe) { - const se = new n.YAMLSeq(j); - if (ie && ie[Symbol.iterator]) - for (const W of ie) { - const G = j.createNode(W, pe.wrapScalars, null, pe); - se.items.push(G); - } - return se; - } - var a = { - createNode: u, - default: !0, - nodeClass: n.YAMLSeq, - tag: "tag:yaml.org,2002:seq", - resolve: n.resolveSeq - }, c = { - identify: (j) => typeof j == "string", - default: !0, - tag: "tag:yaml.org,2002:str", - resolve: n.resolveString, - stringify(j, ie, pe, se) { - return ie = Object.assign({ - actualString: !0 - }, ie), n.stringifyString(j, ie, pe, se); - }, - options: n.strOptions - }, l = [i, a, c], f = (j) => typeof j == "bigint" || Number.isInteger(j), d = (j, ie, pe) => n.intOptions.asBigInt ? BigInt(j) : parseInt(ie, pe); - function E(j, ie, pe) { - const { - value: se - } = j; - return f(se) && se >= 0 ? pe + se.toString(ie) : n.stringifyNumber(j); - } - var y = { - identify: (j) => j == null, - createNode: (j, ie, pe) => pe.wrapScalars ? new n.Scalar(null) : null, - default: !0, - tag: "tag:yaml.org,2002:null", - test: /^(?:~|[Nn]ull|NULL)?$/, - resolve: () => null, - options: n.nullOptions, - stringify: () => n.nullOptions.nullStr - }, S = { - identify: (j) => typeof j == "boolean", - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/, - resolve: (j) => j[0] === "t" || j[0] === "T", - options: n.boolOptions, - stringify: ({ - value: j - }) => j ? n.boolOptions.trueStr : n.boolOptions.falseStr - }, T = { - identify: (j) => f(j) && j >= 0, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "OCT", - test: /^0o([0-7]+)$/, - resolve: (j, ie) => d(j, ie, 8), - options: n.intOptions, - stringify: (j) => E(j, 8, "0o") - }, v = { - identify: f, - default: !0, - tag: "tag:yaml.org,2002:int", - test: /^[-+]?[0-9]+$/, - resolve: (j) => d(j, j, 10), - options: n.intOptions, - stringify: n.stringifyNumber - }, h = { - identify: (j) => f(j) && j >= 0, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "HEX", - test: /^0x([0-9a-fA-F]+)$/, - resolve: (j, ie) => d(j, ie, 16), - options: n.intOptions, - stringify: (j) => E(j, 16, "0x") - }, b = { - identify: (j) => typeof j == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^(?:[-+]?\.inf|(\.nan))$/i, - resolve: (j, ie) => ie ? NaN : j[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, - stringify: n.stringifyNumber - }, w = { - identify: (j) => typeof j == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - format: "EXP", - test: /^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/, - resolve: (j) => parseFloat(j), - stringify: ({ - value: j - }) => Number(j).toExponential() - }, _ = { - identify: (j) => typeof j == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^[-+]?(?:\.([0-9]+)|[0-9]+\.([0-9]*))$/, - resolve(j, ie, pe) { - const se = ie || pe, W = new n.Scalar(parseFloat(j)); - return se && se[se.length - 1] === "0" && (W.minFractionDigits = se.length), W; - }, - stringify: n.stringifyNumber - }, O = l.concat([y, S, T, v, h, b, w, _]), P = (j) => typeof j == "bigint" || Number.isInteger(j), L = ({ - value: j - }) => JSON.stringify(j), Y = [i, a, { - identify: (j) => typeof j == "string", - default: !0, - tag: "tag:yaml.org,2002:str", - resolve: n.resolveString, - stringify: L - }, { - identify: (j) => j == null, - createNode: (j, ie, pe) => pe.wrapScalars ? new n.Scalar(null) : null, - default: !0, - tag: "tag:yaml.org,2002:null", - test: /^null$/, - resolve: () => null, - stringify: L - }, { - identify: (j) => typeof j == "boolean", - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^true|false$/, - resolve: (j) => j === "true", - stringify: L - }, { - identify: P, - default: !0, - tag: "tag:yaml.org,2002:int", - test: /^-?(?:0|[1-9][0-9]*)$/, - resolve: (j) => n.intOptions.asBigInt ? BigInt(j) : parseInt(j, 10), - stringify: ({ - value: j - }) => P(j) ? j.toString() : JSON.stringify(j) - }, { - identify: (j) => typeof j == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/, - resolve: (j) => parseFloat(j), - stringify: L - }]; - Y.scalarFallback = (j) => { - throw new SyntaxError(`Unresolved plain scalar ${JSON.stringify(j)}`); - }; - var H = ({ - value: j - }) => j ? n.boolOptions.trueStr : n.boolOptions.falseStr, V = (j) => typeof j == "bigint" || Number.isInteger(j); - function B(j, ie, pe) { - let se = ie.replace(/_/g, ""); - if (n.intOptions.asBigInt) { - switch (pe) { - case 2: - se = `0b${se}`; - break; - case 8: - se = `0o${se}`; - break; - case 16: - se = `0x${se}`; - break; - } - const G = BigInt(se); - return j === "-" ? BigInt(-1) * G : G; - } - const W = parseInt(se, pe); - return j === "-" ? -1 * W : W; - } - function ne(j, ie, pe) { - const { - value: se - } = j; - if (V(se)) { - const W = se.toString(ie); - return se < 0 ? "-" + pe + W.substr(1) : pe + W; - } - return n.stringifyNumber(j); - } - var I = l.concat([{ - identify: (j) => j == null, - createNode: (j, ie, pe) => pe.wrapScalars ? new n.Scalar(null) : null, - default: !0, - tag: "tag:yaml.org,2002:null", - test: /^(?:~|[Nn]ull|NULL)?$/, - resolve: () => null, - options: n.nullOptions, - stringify: () => n.nullOptions.nullStr - }, { - identify: (j) => typeof j == "boolean", - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/, - resolve: () => !0, - options: n.boolOptions, - stringify: H - }, { - identify: (j) => typeof j == "boolean", - default: !0, - tag: "tag:yaml.org,2002:bool", - test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/i, - resolve: () => !1, - options: n.boolOptions, - stringify: H - }, { - identify: V, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "BIN", - test: /^([-+]?)0b([0-1_]+)$/, - resolve: (j, ie, pe) => B(ie, pe, 2), - stringify: (j) => ne(j, 2, "0b") - }, { - identify: V, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "OCT", - test: /^([-+]?)0([0-7_]+)$/, - resolve: (j, ie, pe) => B(ie, pe, 8), - stringify: (j) => ne(j, 8, "0") - }, { - identify: V, - default: !0, - tag: "tag:yaml.org,2002:int", - test: /^([-+]?)([0-9][0-9_]*)$/, - resolve: (j, ie, pe) => B(ie, pe, 10), - stringify: n.stringifyNumber - }, { - identify: V, - default: !0, - tag: "tag:yaml.org,2002:int", - format: "HEX", - test: /^([-+]?)0x([0-9a-fA-F_]+)$/, - resolve: (j, ie, pe) => B(ie, pe, 16), - stringify: (j) => ne(j, 16, "0x") - }, { - identify: (j) => typeof j == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^(?:[-+]?\.inf|(\.nan))$/i, - resolve: (j, ie) => ie ? NaN : j[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, - stringify: n.stringifyNumber - }, { - identify: (j) => typeof j == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - format: "EXP", - test: /^[-+]?([0-9][0-9_]*)?(\.[0-9_]*)?[eE][-+]?[0-9]+$/, - resolve: (j) => parseFloat(j.replace(/_/g, "")), - stringify: ({ - value: j - }) => Number(j).toExponential() - }, { - identify: (j) => typeof j == "number", - default: !0, - tag: "tag:yaml.org,2002:float", - test: /^[-+]?(?:[0-9][0-9_]*)?\.([0-9_]*)$/, - resolve(j, ie) { - const pe = new n.Scalar(parseFloat(j.replace(/_/g, ""))); - if (ie) { - const se = ie.replace(/_/g, ""); - se[se.length - 1] === "0" && (pe.minFractionDigits = se.length); - } - return pe; - }, - stringify: n.stringifyNumber - }], o.binary, o.omap, o.pairs, o.set, o.intTime, o.floatTime, o.timestamp), Z = { - core: O, - failsafe: l, - json: Y, - yaml11: I - }, te = { - binary: o.binary, - bool: S, - float: _, - floatExp: w, - floatNaN: b, - floatTime: o.floatTime, - int: v, - intHex: h, - intOct: T, - intTime: o.intTime, - map: i, - null: y, - omap: o.omap, - pairs: o.pairs, - seq: a, - set: o.set, - timestamp: o.timestamp - }; - function he(j, ie, pe) { - if (ie) { - const se = pe.filter((G) => G.tag === ie), W = se.find((G) => !G.format) || se[0]; - if (!W) - throw new Error(`Tag ${ie} not found`); - return W; - } - return pe.find((se) => (se.identify && se.identify(j) || se.class && j instanceof se.class) && !se.format); - } - function le(j, ie, pe) { - if (j instanceof n.Node) - return j; - const { - defaultPrefix: se, - onTagObj: W, - prevObjects: G, - schema: ae, - wrapScalars: ge - } = pe; - ie && ie.startsWith("!!") && (ie = se + ie.slice(2)); - let Ee = he(j, ie, ae.tags); - if (!Ee) { - if (typeof j.toJSON == "function" && (j = j.toJSON()), !j || typeof j != "object") - return ge ? new n.Scalar(j) : j; - Ee = j instanceof Map ? i : j[Symbol.iterator] ? a : i; - } - W && (W(Ee), delete pe.onTagObj); - const ye = { - value: void 0, - node: void 0 - }; - if (j && typeof j == "object" && G) { - const Oe = G.get(j); - if (Oe) { - const Ae = new n.Alias(Oe); - return pe.aliasNodes.push(Ae), Ae; - } - ye.value = j, G.set(j, ye); - } - return ye.node = Ee.createNode ? Ee.createNode(pe.schema, j, pe) : ge ? new n.Scalar(j) : j, ie && ye.node instanceof n.Node && (ye.node.tag = ie), ye.node; - } - function ve(j, ie, pe, se) { - let W = j[se.replace(/\W/g, "")]; - if (!W) { - const G = Object.keys(j).map((ae) => JSON.stringify(ae)).join(", "); - throw new Error(`Unknown schema "${se}"; use one of ${G}`); - } - if (Array.isArray(pe)) - for (const G of pe) - W = W.concat(G); - else typeof pe == "function" && (W = pe(W.slice())); - for (let G = 0; G < W.length; ++G) { - const ae = W[G]; - if (typeof ae == "string") { - const ge = ie[ae]; - if (!ge) { - const Ee = Object.keys(ie).map((ye) => JSON.stringify(ye)).join(", "); - throw new Error(`Unknown custom tag "${ae}"; use one of ${Ee}`); - } - W[G] = ge; - } - } - return W; - } - var oe = (j, ie) => j.key < ie.key ? -1 : j.key > ie.key ? 1 : 0, fe = class Pn { - // TODO: remove in v2 - // TODO: remove in v2 - constructor({ - customTags: ie, - merge: pe, - schema: se, - sortMapEntries: W, - tags: G - }) { - this.merge = !!pe, this.name = se, this.sortMapEntries = W === !0 ? oe : W || null, !ie && G && o.warnOptionDeprecation("tags", "customTags"), this.tags = ve(Z, te, ie || G, se); - } - createNode(ie, pe, se, W) { - const G = { - defaultPrefix: Pn.defaultPrefix, - schema: this, - wrapScalars: pe - }, ae = W ? Object.assign(W, G) : G; - return le(ie, se, ae); - } - createPair(ie, pe, se) { - se || (se = { - wrapScalars: !0 - }); - const W = this.createNode(ie, se.wrapScalars, null, se), G = this.createNode(pe, se.wrapScalars, null, se); - return new n.Pair(W, G); - } - }; - s._defineProperty(fe, "defaultPrefix", s.defaultTagPrefix), s._defineProperty(fe, "defaultTags", s.defaultTags), r.Schema = fe; - } -}), Ii = Ue({ - "node_modules/yaml/dist/types.js"(r) { - var s = yr(), n = ki(); - Rt(), Sn(), r.Alias = s.Alias, r.Collection = s.Collection, r.Merge = s.Merge, r.Node = s.Node, r.Pair = s.Pair, r.Scalar = s.Scalar, r.YAMLMap = s.YAMLMap, r.YAMLSeq = s.YAMLSeq, r.binaryOptions = s.binaryOptions, r.boolOptions = s.boolOptions, r.intOptions = s.intOptions, r.nullOptions = s.nullOptions, r.strOptions = s.strOptions, r.Schema = n.Schema; - } -}), Rn = {}, kn = () => Rn, Li = (r) => { - Object.assign(Rn, r); -}, Mi = class { - constructor() { - this.data = {}; - } - /** - * Unregisters custom format(s) - * @param name - */ - unregister(r) { - r ? delete this.data[r] : this.data = {}; - } - /** - * Registers custom format - */ - register(r, s) { - this.data[r] = s; - } - /** - * Register many formats at one shot - */ - registerMany(r) { - Object.keys(r).forEach((s) => { - this.data[s] = r[s]; - }); - } - /** - * Returns element by registry key - */ - get(r) { - return this.data[r]; - } - /** - * Returns the whole registry content - */ - list() { - return this.data; - } -}, In = Mi, Re = {}, Er = Re; -Re.defaultInvalidTypeProduct = void 0; -Re.defaultRandExpMax = 10; -Re.maxRegexRetry = 100; -Re.pruneProperties = []; -Re.ignoreProperties = []; -Re.ignoreMissingRefs = !1; -Re.failOnInvalidTypes = !0; -Re.failOnInvalidFormat = !0; -Re.alwaysFakeOptionals = !1; -Re.optionalsProbability = null; -Re.fixedProbabilities = !1; -Re.useExamplesValue = !1; -Re.useDefaultValue = !1; -Re.requiredOnly = !1; -Re.omitNulls = !1; -Re.minItems = 0; -Re.maxItems = null; -Re.minLength = 0; -Re.maxLength = null; -Re.resolveJsonPath = !1; -Re.reuseProperties = !1; -Re.fillProperties = !0; -Re.sortProperties = !1; -Re.replaceEmptyByRandomValue = !1; -Re.random = Math.random; -Re.minDateTime = /* @__PURE__ */ new Date("1889-12-31T00:00:00.000Z"); -Re.maxDateTime = /* @__PURE__ */ new Date("1970-01-01T00:00:01.000Z"); -Re.renderTitle = !0; -Re.renderDescription = !0; -Re.renderComment = !1; -var Ni = class extends In { - constructor() { - super(), this.data = { ...Er }, this._defaults = Er; - } - get defaults() { - return { ...this._defaults }; - } -}, ji = Ni, xt = new ji(); -function Ln(r, s) { - return typeof r == "string" ? typeof s < "u" ? xt.register(r, s) : xt.get(r) : xt.registerMany(r); -} -Ln.getDefaults = () => xt.defaults; -var Ce = Ln, Mn = ["integer", "number", "string", "boolean"], Fi = Mn.concat(["null"]), $i = -1e8, Di = 1e8, Bi = -100, Ui = 100, Ge = { - ALLOWED_TYPES: Mn, - SCALAR_TYPES: Fi, - MIN_NUMBER: Bi, - MAX_NUMBER: Ui, - MIN_INTEGER: $i, - MAX_INTEGER: Di -}, Lt = En(Ri()); -function Yi(r, s) { - return r = typeof r > "u" ? Ge.MIN_INTEGER : r, s = typeof s > "u" ? Ge.MAX_INTEGER : s, Math.floor(Ce("random")() * (s - r + 1)) + r; -} -function Hi(r) { - return Lt.default.prototype.max = Ce("defaultRandExpMax"), Lt.default.prototype.randInt = (n, o) => n + Math.floor(Ce("random")() * (1 + (o - n))), new Lt.default(r).gen(); -} -function qi(r) { - return r[Math.floor(Ce("random")() * r.length)]; -} -function Ki(r) { - let s, n, o = r.length; - const p = r.slice(); - for (; o > 0; ) - n = Math.floor(Ce("random")() * o), o -= 1, s = p[o], p[o] = p[n], p[n] = s; - return p; -} -function Nn(r, s) { - return Ce("random")() * (s - r) + r; -} -function Xe(r, s, n, o, p = !1) { - return n = typeof n > "u" ? Ge.MIN_NUMBER : n, o = typeof o > "u" ? Ge.MAX_NUMBER : o, r = typeof r > "u" ? n : r, s = typeof s > "u" ? o : s, s < r && (s += r), p ? Nn(r, s) : Yi(r, s); -} -function Wi(r) { - switch (r) { - case "seconds": - return Xe(0, 60) * 60; - case "minutes": - return Xe(15, 50) * 612; - case "hours": - return Xe(12, 72) * 36123; - case "days": - return Xe(7, 30) * 86412345; - case "weeks": - return Xe(4, 52) * 604812345; - case "months": - return Xe(2, 13) * 2592012345; - case "years": - return Xe(1, 20) * 31104012345; - } -} -function Vi(r) { - if (r) - return Wi(r); - let s = Ce("minDateTime"), n = Ce("maxDateTime"); - typeof s == "string" && (s = new Date(s)), typeof n == "string" && (n = new Date(n)); - const o = (/* @__PURE__ */ new Date()).getTime(); - return typeof s == "number" && (s = new Date(o + s)), typeof n == "number" && (n = new Date(o + n)), new Date(Nn(s.getTime(), n.getTime())); -} -var Se = { - pick: qi, - date: Vi, - shuffle: Ki, - number: Xe, - randexp: Hi -}, Ji = /^(0|[1-9][0-9]*)$/; -function Gi(r, s, n) { - if (s = decodeURIComponent(s), n && n[s]) - return _t(n[s]); - const o = s.replace("#/", "/").split("/"); - let p = r.$ref && n && n[r.$ref] || r; - for (!p && !o[0] && (o[0] = r.$ref.split("#/")[0]), n && s.includes("#/") && n[o[0]] && (p = n[o.shift()]), o[0] || o.shift(); p && o.length > 0; ) { - const i = o.shift(); - if (!p[i]) - throw new Error(`Prop not found: ${i} (${s})`); - p = p[i]; - } - return p; -} -function Ar(r) { - return typeof r == "string" && Ji.test(r); -} -function Qi(r) { - return ["number", "boolean"].includes(typeof r); -} -function Xi(r, ...s) { - return s.filter((n) => typeof r[n] < "u").length > 0; -} -function jn(r) { - if (r.includes(" ")) - return new Date(r).toISOString().substr(0, 10); - let [s, n, o] = r.split("T")[0].split("-"); - return n = `0${Math.max(1, Math.min(12, n))}`.slice(-2), o = `0${Math.max(1, Math.min(31, o))}`.slice(-2), `${s}-${n}-${o}`; -} -function zi(r) { - if (r.includes(" ")) - return new Date(r).toISOString().substr(0, 10); - const [s, n] = r.split("T"); - let [o, p, i] = s.split("-"), [u, a, c] = n.substr(0, 8).split(":"); - return p = `0${Math.max(1, Math.min(12, p))}`.slice(-2), i = `0${Math.max(1, Math.min(31, i))}`.slice(-2), u = `0${Math.max(1, Math.min(23, u))}`.slice(-2), a = `0${Math.max(1, Math.min(59, a))}`.slice(-2), c = `0${Math.max(1, Math.min(59, c))}`.slice(-2), `${o}-${p}-${i}T${u}:${a}:${c}.000Z`; -} -function Zi(r, s, n) { - const o = {}; - switch (r || s.type) { - case "integer": - case "number": - if (typeof s.minimum < "u" && (o.minimum = s.minimum), typeof s.maximum < "u" && (o.maximum = s.maximum), s.enum) { - let i = Math.max(o.minimum || 0, 0), u = Math.min(o.maximum || 1 / 0, 1 / 0); - s.exclusiveMinimum && i === s.minimum && (i += s.multipleOf || 1), s.exclusiveMaximum && u === s.maximum && (u -= s.multipleOf || 1), (i || u !== 1 / 0) && (s.enum = s.enum.filter((a) => a >= i && a <= u)); - } - break; - case "string": { - o.minLength = Ce("minLength") || 0, o.maxLength = Ce("maxLength") || Number.MAX_SAFE_INTEGER, typeof s.minLength < "u" && (o.minLength = Math.max(o.minLength, s.minLength)), typeof s.maxLength < "u" && (o.maxLength = Math.min(o.maxLength, s.maxLength)); - break; - } - } - let p = n(o); - if (p == null) - return null; - switch (r || s.type) { - case "number": - p = Ar(p) ? parseFloat(p) : p; - break; - case "integer": - p = Ar(p) ? parseInt(p, 10) : p; - break; - case "boolean": - p = !!p; - break; - case "string": { - if (Qi(p)) - return p; - p = String(p); - const i = Math.max(o.minLength || 0, 0), u = Math.min(o.maxLength || 1 / 0, 1 / 0); - let a, c = 0; - for (; p.length < i; ) - if (a = p, s.pattern ? p += Se.randexp(s.pattern) : p += `${Se.pick([" ", "/", "_", "-", "+", "=", "@", "^"])}${p}`, p === a) { - if (c += 1, c === 3) - break; - } else - c = 0; - if (p.length > u) { - p = p.substr(0, u); - const l = s.pattern ? new RegExp(s.pattern) : null; - if (l && !l.test(p)) { - let f = p; - const d = Ce("maxRegexRetry"), E = Math.max(p.length - d, i); - for (; f.length > E && !l.test(f); ) - f = f.slice(0, -1), l.test(f) && (p = f); - } - } - switch (s.format) { - case "date-time": - case "datetime": - p = new Date(zi(p)).toISOString().replace(/([0-9])0+Z$/, "$1Z"); - break; - case "full-date": - case "date": - p = new Date(jn(p)).toISOString().substr(0, 10); - break; - case "time": - p = (/* @__PURE__ */ new Date(`1969-01-01 ${p}`)).toISOString().substr(11); - break; - } - break; - } - } - return p; -} -function nt(r, s) { - return Object.keys(s).forEach((n) => { - typeof s[n] != "object" || s[n] === null ? r[n] = s[n] : Array.isArray(s[n]) ? (r[n] = r[n] || [], s[n].forEach((o, p) => { - r.type === "array" && s.type === "array" ? r[n][p] = nt(r[n][p] || {}, o) : Array.isArray(r[n]) && r[n].indexOf(o) === -1 && r[n].push(o); - })) : typeof r[n] != "object" || r[n] === null || Array.isArray(r[n]) ? r[n] = nt({}, s[n]) : r[n] = nt(r[n], s[n]); - }), r; -} -function _t(r, s = /* @__PURE__ */ new Map()) { - if (!r || typeof r != "object") - return r; - if (s.has(r)) - return s.get(r); - if (Array.isArray(r)) { - const o = []; - return s.set(r, o), o.push(...r.map((p) => _t(p, s))), o; - } - const n = {}; - return s.set(r, n), Object.keys(r).reduce((o, p) => (o[p] = _t(r[p], s), o), n); -} -function eo(r) { - const s = JSON.stringify(r), n = JSON.stringify(r, null, 2); - return s.length > 400 ? `${n.substr(0, 400)}...` : n; -} -function Fn() { - return Se.pick([ - !1, - !0, - null, - -1, - NaN, - Math.PI, - 1 / 0, - void 0, - [], - {}, - // FIXME: use built-in random? - Math.random(), - Math.random().toString(36).substr(2) - ]); -} -function to(r, s) { - if (r.enum) - return r.enum.includes(s); - if (r.const) - return r.const === s; -} -function ro(r, s) { - const n = nt({}, s); - if (typeof r.minimum < "u" && (n.maximum = r.minimum, n.exclusiveMaximum = !0), typeof r.maximum < "u" && (n.minimum = r.maximum > n.maximum ? 0 : r.maximum, n.exclusiveMinimum = !0), typeof r.minLength < "u" && (n.maxLength = r.minLength), typeof r.maxLength < "u" && (n.minLength = r.maxLength > n.maxLength ? 0 : r.maxLength), r.type) - n.type = Se.pick(Ge.SCALAR_TYPES.filter((o) => (Array.isArray(r.type) ? r.type : [r.type]).every((i) => o === "number" || o === "integer" ? i !== "number" && i !== "integer" : o !== i))); - else if (r.enum) { - let o; - do - o = Fn(); - while (r.enum.indexOf(o) !== -1); - n.enum = [o]; - } - return r.required && n.properties && r.required.forEach((o) => { - delete n.properties[o]; - }), n; -} -function vr(r, s) { - const n = s.minimum !== void 0, o = s.maximum !== void 0; - return (n || o) && (!n || r >= s.minimum) && (!o || r <= s.maximum); -} -function no(r, s) { - return !s.every((n) => vr(r, n)); -} -function io(r, s) { - return s.reduce((o, p) => o + (vr(r, p) ? 1 : 0), 0) === 1; -} -function oo(r) { - return ["enum", "const", "default", "examples", "required", "definitions", "items", "properties"].includes(r); -} -function so(r, s) { - return Object.keys(r).filter((n) => !s.includes(n)).reduce((n, o) => (Array.isArray(r[o]) ? n[o] = r[o].slice() : n[o] = r[o] instanceof Object ? nt({}, r[o]) : r[o], n), {}); -} -function $n(r, s) { - return Array.isArray(r) ? r.map((n) => $n(n, s)) : (typeof r == "string" && (r = r.replace(/#\{([\w.-]+)\}/g, (n, o) => s[o])), r); -} -function lr(r) { - return Object.prototype.toString.call(r) === "[object Object]" && !Object.keys(r).length; -} -function Dn(r, s) { - s = s.items || s; - const n = Ce("alwaysFakeOptionals"), o = Array.isArray(s.required) && s.required.includes(r) || n, p = typeof s.thunk == "function" || s.additionalProperties && typeof s.additionalProperties.thunk == "function"; - return !o && !p; -} -function fr(r, s, n = !1) { - if (!r || typeof r != "object") - return r; - if (Array.isArray(r)) - return r.map((o) => fr(o, s?.items, !0)).filter((o) => typeof o < "u"); - if (Object.keys(r).forEach((o) => { - if (lr(r[o])) - Dn(o, s) && delete r[o]; - else { - let p = s; - s && s.properties && s.properties[o] && (p = s.properties[o]); - const i = fr(r[o], p); - lr(i) || (r[o] = i); - } - typeof r[o] > "u" && delete r[o]; - }), !(!Object.keys(r).length && n)) - return r; -} -var ke = { - hasProperties: Xi, - getLocalRef: Gi, - omitProps: so, - typecast: Zi, - merge: nt, - clone: _t, - short: eo, - hasValue: to, - notValue: ro, - anyValue: Fn, - validate: no, - validateValueForSchema: vr, - validateValueForOneOf: io, - isKey: oo, - template: $n, - shouldClean: Dn, - clean: fr, - isEmpty: lr, - clampDate: jn -}; -function ao(r) { - return (s, n, o, p) => { - let i = s, u = []; - typeof s == "object" && (i = Object.keys(s)[0], Array.isArray(s[i]) ? u = s[i] : u.push(s[i])); - const a = i.split("."); - let c = r(); - for (; a.length > 1; ) - c = c[a.shift()]; - return s = typeof c == "object" ? c[a[0]] : c, typeof s == "function" && (s = s.apply(c, u.map((l) => ke.template(l, p)))), Object.prototype.toString.call(s) === "[object Object]" && Object.keys(s).forEach((l) => { - if (typeof s[l] == "function") - throw new Error(`Cannot resolve value for '${o}: ${i}', given: ${s}`); - }), s; - }; -} -var uo = class { - constructor() { - this.registry = {}, this.support = {}; - } - /** - * Unregister extensions - * @param name - */ - reset(r) { - r ? (delete this.registry[r], delete this.support[r]) : (this.registry = {}, this.support = {}); - } - /** - * Override dependency given by name - * @param name - * @param callback - */ - extend(r, s) { - this.registry[r] = s(this.registry[r]), this.support[r] || (this.support[r] = ao(() => this.registry[r])); - } - /** - * Set keyword support by name - * @param name - * @param callback - */ - define(r, s) { - this.support[r] = s; - } - /** - * Returns dependency given by name - * @param name - * @returns {Dependency} - */ - get(r) { - if (typeof this.registry[r] > "u") - throw new ReferenceError(`'${r}' dependency doesn't exist.`); - return this.registry[r]; - } - /** - * Apply a custom keyword - * @param schema - */ - wrap(r) { - if (!("generate" in r)) { - const s = Object.keys(r), n = {}; - let o = s.length; - for (; o--; ) { - const p = s[o].replace(/^x-/, ""), i = this.support[p]; - if (typeof i == "function") { - Object.defineProperty(r, "generate", { - configurable: !1, - enumerable: !1, - writable: !1, - value: (u, a) => i.call(n, r[s[o]], r, s[o], u, a.slice()) - // eslint-disable-line - }); - break; - } - } - } - return r; - } -}, lo = uo, st = new In(); -function fo(r, s) { - if (typeof r > "u") - return st.list(); - if (typeof r == "string") - if (typeof s == "function") - st.register(r, s); - else if (s === null || s === !1) - st.unregister(r); - else - return st.get(r); - else - st.registerMany(r); -} -var Bn = fo, co = class extends Error { - constructor(r, s) { - super(), Error.captureStackTrace && Error.captureStackTrace(this, this.constructor), this.name = "ParseError", this.message = r, this.path = s; - } -}, cr = co, Ot = { - array: [ - "additionalItems", - "items", - "maxItems", - "minItems", - "uniqueItems" - ], - integer: [ - "exclusiveMaximum", - "exclusiveMinimum", - "maximum", - "minimum", - "multipleOf" - ], - object: [ - "additionalProperties", - "dependencies", - "maxProperties", - "minProperties", - "patternProperties", - "properties", - "required" - ], - string: [ - "maxLength", - "minLength", - "pattern", - "format" - ] -}; -Ot.number = Ot.integer; -var po = [ - "additionalItems", - "items", - "additionalProperties", - "dependencies", - "patternProperties", - "properties" -]; -function ho(r, s, n) { - return Object.keys(r).filter((o) => { - const p = po.indexOf(s) > -1; - return n.indexOf(o) > -1 && !p; - }).length > 0; -} -function mo(r, s) { - const n = Object.keys(Ot); - for (let o = 0; o < n.length; o += 1) { - const p = n[o], i = s[s.length - 1]; - if (ho(r, i, Ot[p])) - return p; - } -} -var go = mo; -function yo() { - return Ce("random")() > 0.5; -} -var vo = yo, bo = vo, wo = bo; -function Eo() { - return null; -} -var Ao = Eo, xo = Ao, _o = xo; -function Oo(r, s, n, o, p, i) { - const u = [], a = []; - function c(f) { - const d = JSON.stringify(f.value); - return a.indexOf(d) === -1 ? (a.push(d), u.push(f), !0) : !1; - } - s.forEach(c); - let l = 100; - for (; u.length !== s.length && (c(i(n.items || o, r, p)) || (l -= 1), !!l); ) - ; - return u; -} -function So(r, s, n, o) { - const p = []; - if (!(r.items || r.additionalItems)) { - if (ke.hasProperties(r, "minItems", "maxItems", "uniqueItems") && (r.minItems !== 0 || r.maxItems !== 0)) - throw new cr(`missing items for ${ke.short(r)}`, s); - return p; - } - if (Array.isArray(r.items)) - return r.items.map((y, S) => { - const T = s.concat(["items", S]); - return o(y, T, n); - }); - let i = r.minItems, u = r.maxItems; - const a = Ce("minItems"), c = Ce("maxItems"); - a && (i = typeof i > "u" ? a : Math.min(a, i)), c && (u = typeof u > "u" ? c : Math.min(c, u), u && u > c && (u = c), i && i > c && (i = u)); - const l = Ce("alwaysFakeOptionals") === !0 ? 1 : Ce("optionalsProbability"), f = Ce("alwaysFakeOptionals") || Ce("fixedProbabilities") || !1; - let d = Se.number(i, u, 0, 5); - l !== null && (d = Math.max(f ? Math.round((u || d) * l) : Math.abs(Se.number(i, u) * l), i || 0)); - const E = typeof r.additionalItems == "object" ? r.additionalItems : {}; - for (let y = p.length; y < d; y += 1) { - const S = s.concat(["items", y]), T = o(r.items || E, S, n); - p.push(T); - } - if (r.contains && d > 0) { - const y = Se.number(0, d - 1); - p[y] = o(r.contains, s.concat(["items", y]), n); - } - return r.uniqueItems ? Oo(s.concat(["items"]), p, r, E, n, o) : p; -} -var Co = So; -function To(r) { - let s = typeof r.minimum > "u" || r.minimum === -Number.MAX_VALUE ? Ge.MIN_INTEGER : r.minimum, n = typeof r.maximum > "u" || r.maximum === Number.MAX_VALUE ? Ge.MAX_INTEGER : r.maximum; - s > n && (n = Number.MAX_SAFE_INTEGER); - const o = r.multipleOf, p = o && String(o).match(/e-(\d)|\.(\d+)$/); - if (p) { - const i = (Math.random() * Se.number(0, 10) + 1) * o, u = p[1] || p[2].length, a = parseFloat(i.toFixed(u)), c = Se.number(s, n - 1); - return String(a).includes(".") ? c + a : (c + a).toExponential(); - } - if (o && (n = Math.floor(n / o) * o, s = Math.ceil(s / o) * o), r.exclusiveMinimum && s === r.minimum && (s += o || 1), r.exclusiveMaximum && n === r.maximum && (n -= o || 1), s > n) - return NaN; - if (o) { - let i = Se.number(Math.floor(s / o), Math.floor(n / o)) * o; - for (; i < s; ) - i += o; - return i; - } - return Se.number(s, n, void 0, void 0, r.type !== "integer"); -} -var Un = To; -function Po(r) { - return Math.floor(Un({ ...r })); -} -var Ro = Po, ko = `Lorem ipsum dolor sit amet consectetur adipisicing elit sed do eiusmod tempor incididunt ut labore -et dolore magna aliqua Ut enim ad minim veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea -commodo consequat Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla -pariatur Excepteur sint occaecat cupidatat non proident sunt in culpa qui officia deserunt mollit anim id est -laborum`.split(/\W/); -function Io(r) { - return Se.shuffle(ko).slice(0, r); -} -var pr = Io, Mt = { type: Ge.ALLOWED_TYPES }; -function Lo(r, s, n, o) { - const p = {}, i = r.properties || {}, u = r.patternProperties || {}, a = typeof r.required == "boolean" ? [] : (r.required || []).slice(), c = r.additionalProperties !== !1, l = Object.keys(i), f = Object.keys(u), d = l.concat(f).reduce((oe, fe) => (a.indexOf(fe) === -1 && oe.push(fe), oe), []), E = a.concat(d), y = c && r.additionalProperties === !0 ? Mt : r.additionalProperties; - if (!c && l.length === 0 && f.length === 0 && ke.hasProperties(r, "minProperties", "maxProperties", "dependencies", "required")) - return null; - if (Ce("requiredOnly") === !0) - return a.forEach((oe) => { - i[oe] && (p[oe] = i[oe]); - }), o(p, s.concat(["properties"]), n, r); - const S = Ce("alwaysFakeOptionals") === !0 ? 1 : Ce("optionalsProbability"), T = Ce("alwaysFakeOptionals") || Ce("fixedProbabilities") || !1, v = Ce("ignoreProperties") || [], h = Ce("reuseProperties"), b = Ce("fillProperties"), w = r.maxProperties || E.length + (c ? Se.number(1, 5) : 0); - let _ = Math.max(r.minProperties || 0, a.length), O = Math.max(0, E.length - _); - E.length === 1 && !a.length && (_ = Math.max(Se.number(b ? 1 : 0, w), _)), S !== null && (T === !0 ? O = Math.round(_ - a.length + S * (E.length - _)) : O = Se.number(_ - a.length, S * (E.length - _))); - const P = Se.shuffle(d).slice(0, O), L = d.filter((oe) => P.indexOf(oe) !== -1), Y = S !== null || a.length === w ? w : Se.number(0, w), H = a.concat(Se.shuffle(L).slice(0, Y)).slice(0, w), V = [], B = []; - if (r.dependencies && (Object.keys(r.dependencies).forEach((oe) => { - const fe = r.dependencies[oe]; - if (H.indexOf(oe) !== -1) - if (Array.isArray(fe)) - fe.forEach((j) => { - H.indexOf(j) === -1 && H.push(j); - }); - else if (Array.isArray(fe.oneOf || fe.anyOf)) { - const j = fe.oneOf || fe.anyOf; - B.push({ prop: oe, values: j }); - } else - V.push(fe); - }), V.length)) - return delete r.dependencies, o({ - allOf: V.concat(r) - }, s.concat(["properties"]), n, r); - const ne = []; - H.forEach((oe) => { - if (i[oe] && ["{}", "true"].includes(JSON.stringify(i[oe].not))) - return; - for (let j = 0; j < v.length; j += 1) - if (v[j] instanceof RegExp && v[j].test(oe) || typeof v[j] == "string" && v[j] === oe || typeof v[j] == "function" && v[j](i[oe], oe)) { - ne.push(oe); - return; - } - y === !1 && a.indexOf(oe) !== -1 && (p[oe] = i[oe]), i[oe] && (p[oe] = i[oe]); - let fe; - if (f.forEach((j) => { - oe.match(new RegExp(j)) && (fe = !0, p[oe] ? ke.merge(p[oe], u[j]) : p[Se.randexp(oe)] = u[j]); - }), !fe) { - const j = u[oe] || y; - j && y !== !1 && (p[u[oe] ? Se.randexp(oe) : oe] = i[oe] || j); - } - }); - let I = Object.keys(p).length + (b ? 0 : ne.length); - const Z = (oe) => Se.randexp(`_?[_a-f\\d]{1,3}${oe ? "\\$?" : ""}`); - function te(oe) { - let fe; - do { - if (!oe.length) - break; - fe = oe.shift(); - } while (p[fe]); - return fe; - } - let he = _; - if (c && !a.length && (he = Math.max(S === null || y ? Se.number(b ? 1 : 0, w) : 0, _)), !L.length && !O && c && T === !0 && b) { - const oe = Se.number(0, w); - for (let fe = 0; fe < oe; fe += 1) - p[pr(1) + Z(oe[fe])] = y || Mt; - } - for (; b && !(!(f.length || c) || I >= he); ) { - if (c) - if (h && l.length - I > he) { - let oe = 0, fe; - do { - if (oe += 1, oe > 1e3) - break; - fe = te(a) || Se.pick(l); - } while (typeof p[fe] < "u"); - typeof p[fe] > "u" && (p[fe] = i[fe], I += 1); - } else if (f.length && !y) { - const oe = Se.pick(f), fe = Se.randexp(oe); - p[fe] || (p[fe] = u[oe], I += 1); - } else { - const oe = te(a) || pr(1) + Z(); - p[oe] || (p[oe] = y || Mt, I += 1); - } - for (let oe = 0; I < _ && oe < f.length; oe += 1) { - const fe = f[oe], j = Se.randexp(fe); - p[j] || (p[j] = u[fe], I += 1); - } - } - if (a.length === 0 && (!c || S === !1)) { - const oe = Se.number(_, w); - for (; I < oe; ) { - const fe = te(l); - fe && (p[fe] = i[fe]), I += 1; - } - } - let le = p; - if (Ce("sortProperties") !== null) { - const oe = Object.keys(i); - le = Object.keys(p).sort((j, ie) => Ce("sortProperties") ? j.localeCompare(ie) : oe.indexOf(j) - oe.indexOf(ie)).reduce((j, ie) => (j[ie] = p[ie], j), {}); - } - const ve = o(le, s.concat(["properties"]), n, r); - return B.forEach((oe) => { - for (const fe of oe.values) - if (ke.hasValue(fe.properties[oe.prop], ve.value[oe.prop])) { - Object.keys(fe.properties).forEach((j) => { - j !== oe.prop && ke.merge(ve.value, o(fe.properties, s.concat(["properties"]), n, r).value); - }); - break; - } - }), ve; -} -var Mo = Lo; -function xr() { - const r = Se.number(1, 5); - return pr(r).join(" "); -} -function No(r = 0, s = 140) { - const n = Math.max(0, r), o = Se.number(n, s); - let p = xr(); - for (; p.length < n; ) - p += xr(); - return p.length > o && (p = p.substr(0, o)), p; -} -var _r = No; -function jo() { - return [0, 0, 0, 0].map(() => Se.number(0, 255)).join("."); -} -var Fo = jo; -function $o() { - return Se.date().toISOString(); -} -var br = $o; -function Do() { - return br().slice(0, 10); -} -var Bo = Do; -function Uo() { - return br().slice(11); -} -var Yo = Uo, Yn = "[a-zA-Z][a-zA-Z0-9+-.]*", Nt = `https?://{hostname}(?:${Yn})+`, Ho = "(?:\\?([a-z]{1,7}(=\\w{1,5})?&){0,3})?", qe = { - email: "[a-zA-Z\\d][a-zA-Z\\d-]{1,13}[a-zA-Z\\d]@{hostname}", - hostname: "[a-zA-Z]{1,33}\\.[a-z]{2,4}", - ipv6: "[a-f\\d]{4}(:[a-f\\d]{4}){7}", - uri: Nt, - slug: "[a-zA-Z\\d_-]+", - // types from draft-0[67] (?) - "uri-reference": `${Nt}${Ho}`, - "uri-template": Nt.replace("(?:", "(?:/\\{[a-z][:a-zA-Z0-9-]*\\}|"), - "json-pointer": `(/(?:${Yn.replace("]*", "/]*")}|~[01]))+`, - // some types from https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.1.md#data-types (?) - uuid: "^[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$", - duration: "^P(?!$)((\\d+Y)?(\\d+M)?(\\d+D)?(T(?=\\d)(\\d+H)?(\\d+M)?(\\d+S)?)?|(\\d+W)?)$" -}; -qe.iri = qe["uri-reference"]; -qe["iri-reference"] = qe["uri-reference"]; -qe["idn-email"] = qe.email; -qe["idn-hostname"] = qe.hostname; -var qo = new RegExp(`\\{(${Object.keys(qe).join("|")})\\}`); -function Ko(r) { - return Se.randexp(qe[r]).replace(qo, (s, n) => Se.randexp(qe[n])); -} -var Wo = Ko; -function Vo(r, s) { - const n = Bn(r.format); - if (typeof n == "function") - return n(r); - switch (r.format) { - case "date-time": - case "datetime": - return br(); - case "date": - return Bo(); - case "time": - return Yo(); - case "ipv4": - return Fo(); - case "regex": - return ".+?"; - case "email": - case "hostname": - case "ipv6": - case "uri": - case "uri-reference": - case "iri": - case "iri-reference": - case "idn-email": - case "idn-hostname": - case "json-pointer": - case "slug": - case "uri-template": - case "uuid": - case "duration": - return Wo(r.format); - default: - if (typeof n > "u") { - if (Ce("failOnInvalidFormat")) - throw new Error(`unknown registry key ${ke.short(r.format)}`); - return s(); - } - throw new Error(`unsupported format '${r.format}'`); - } -} -function Jo(r) { - return ke.typecast("string", r, (n) => r.format ? Vo(r, () => _r(n.minLength, n.maxLength)) : r.pattern ? Se.randexp(r.pattern) : _r(n.minLength, n.maxLength)); -} -var Go = Jo, Qo = { - boolean: wo, - null: _o, - array: Co, - integer: Ro, - number: Un, - object: Mo, - string: Go -}, wt = Qo; -function Xo({ $comment: r, title: s, description: n }) { - return Object.entries({ comment: r, title: s, description: n }).filter(([, o]) => o).reduce((o, [p, i]) => (o[p] = i, o), {}); -} -function rt(r, s, n, o) { - if (r = n(r, null, s), r && (r.oneOf || r.anyOf || r.allOf) && (r = n(r, null, s)), !r) - throw new Error(`Cannot traverse at '${s.join(".")}', given '${JSON.stringify(o)}'`); - const p = { - ...Xo(r), - schemaPath: s - }; - if (s[s.length - 1] !== "properties") { - if (Ce("useExamplesValue") && Array.isArray(r.examples)) { - const l = r.examples.concat("default" in r ? [r.default] : []); - return { value: ke.typecast(null, r, () => Se.pick(l)), context: p }; - } - if (Ce("useExamplesValue") && typeof r.example < "u") - return { value: ke.typecast(null, r, () => r.example), context: p }; - if (Ce("useDefaultValue") && "default" in r && (r.default !== "" || !Ce("replaceEmptyByRandomValue"))) - return { value: r.default, context: p }; - if ("template" in r) - return { value: ke.template(r.template, o), context: p }; - if ("const" in r) - return { value: r.const, context: p }; - } - if (r.not && typeof r.not == "object" && (r = ke.notValue(r.not, ke.omitProps(r, ["not"])), r.type && r.type === "object")) { - const { value: l, context: f } = rt(r, s.concat(["not"]), n, o); - return { value: ke.clean(l, r, !1), context: { ...p, items: f } }; - } - if (typeof r.thunk == "function") { - const { value: l, context: f } = rt(r.thunk(o), s, n); - return { value: l, context: { ...p, items: f } }; - } - if (r.jsonPath) - return { value: r, context: p }; - let i = r.type; - if (Array.isArray(i) ? i = Se.pick(i) : typeof i > "u" && (i = go(r, s) || i, i && (r.type = i)), typeof r.generate == "function") { - const l = ke.typecast(null, r, () => r.generate(o, s)), f = l === null ? "null" : typeof l; - if (f === i || f === "number" && i === "integer" || Array.isArray(l) && i === "array") - return { value: l, context: p }; - } - if (typeof r.pattern == "string") - return { value: ke.typecast("string", r, () => Se.randexp(r.pattern)), context: p }; - if (Array.isArray(r.enum)) - return { value: ke.typecast(null, r, () => Se.pick(r.enum)), context: p }; - if (typeof i == "string") - if (wt[i]) - try { - const l = wt[i](r, s, n, rt); - return i === "array" ? { - value: l.map(({ value: f }) => f), - context: { - ...p, - items: l.map( - Array.isArray(r.items) ? ({ context: f }) => f : ({ context: f }) => ({ - ...f, - // we have to remove the index from the path to get the real schema path - schemaPath: f.schemaPath.slice(0, -1) - }) - ) - } - } : i === "object" ? l !== null ? { value: l.value, context: { ...p, items: l.context } } : { value: {}, context: p } : { value: l, context: p }; - } catch (l) { - throw typeof l.path > "u" ? new cr(l.stack, s) : l; - } - else { - if (Ce("failOnInvalidTypes")) - throw new cr(`unknown primitive ${ke.short(i)}`, s.concat(["type"])); - { - const l = Ce("defaultInvalidTypeProduct"); - return typeof l == "string" && wt[l] ? { value: wt[l](r, s, n, rt), context: p } : { value: l, context: p }; - } - } - let u = {}, a = { ...p }; - Array.isArray(r) && (u = []); - const c = Ce("pruneProperties") || []; - return Object.keys(r).forEach((l) => { - if (!c.includes(l) && r[l] !== null) - if (typeof r[l] == "object" && l !== "definitions") { - const { value: f, context: d } = rt(r[l], s.concat([l]), n, u); - u[l] = ke.clean(f, r[l], !1), a[l] = d, u[l] === null && Ce("omitNulls") && (delete u[l], delete a[l]); - } else - u[l] = r[l]; - }), { value: u, context: a }; -} -var zo = rt, Zo = ({ - refs: r, - schema: s, - container: n, - synchronous: o, - refDepthMax: p, - refDepthMin: i -}) => { - const u = {}, a = {}; - let c = 0, l, f; - return u.resolveSchema = (d, E, y) => { - if (d == null) - return null; - if (typeof d.generate == "function") - return d; - if (typeof (d.$id || d.id) == "string" && (delete d.id, delete d.$id, delete d.$schema), typeof d.$ref == "string") { - const T = Math.max(i, p) - 1; - if (d.$ref === "#" || a[d.$ref] < 0 || l === d.$ref && ++c > T) - return d.$ref !== "#" && f && f.length === y.length ? ke.getLocalRef(s, d.$ref, o && r) : (delete d.$ref, d); - typeof a[d.$ref] > "u" && (a[d.$ref] = Se.number(i, p) - 1), f = y, l = d.$ref; - let v; - d.$ref.indexOf("#/") === -1 ? v = r[d.$ref] || null : v = ke.getLocalRef(s, d.$ref, o && r) || null; - let h; - if (typeof v < "u") { - if (!v && Ce("ignoreMissingRefs") !== !0) - throw new Error(`Reference not found: ${d.$ref}`); - a[d.$ref] -= 1, ke.merge(d, v || {}), h = o && v && v.$ref; - } - return h || delete d.$ref, d; - } - if (Array.isArray(d.allOf)) { - const T = d.allOf; - delete d.allOf, T.forEach((v) => { - const h = u.resolveSchema(v, null, y); - ke.merge(d, typeof h.thunk == "function" ? h.thunk(d) : h), Array.isArray(d.allOf) && u.resolveSchema(d, E, y); - }); - } - if (Array.isArray(d.oneOf || d.anyOf) && y[y.length - 2] !== "dependencies") { - const T = d.oneOf || d.anyOf; - return d.enum && d.oneOf && (d.enum = d.enum.filter((v) => ke.validate(v, T))), { - thunk(v) { - const h = ke.omitProps(d, ["anyOf", "oneOf"]), b = Se.pick(T); - return ke.merge(h, b), T.forEach((w) => { - w.required && w !== b && w.required.forEach((_) => { - if (b.required && b.required.includes(_)) - return; - const O = h.required && h.required.includes(_); - h.properties && !O && delete h.properties[_], v && v.properties && delete v.properties[_]; - }); - }), h; - } - }; - } - if (Object.keys(d).forEach((T) => { - (Array.isArray(d[T]) || typeof d[T] == "object") && !ke.isKey(T) && (d[T] = u.resolveSchema(d[T], T, y.concat(T))); - }), y) { - const T = y[y.length - 1]; - if (T === "properties" || T === "items") - return d; - } - return n.wrap(d); - }, u; -}, es = Zo; -function ts(r) { - return Array.isArray(r) ? Se.pick(r) : r; -} -function rs(r, s) { - if (!Array.isArray(r)) - return r; - const n = s ? r.pop() : r.shift(); - return s ? r.unshift(n) : r.push(n), n; -} -function hr(r, s, n, o) { - if (!r || typeof r != "object") - return r; - if (n || (n = {}), s || (s = r), Array.isArray(r)) - return r.map((p) => hr(p, s, n, o)); - if (r.jsonPath) { - const { JSONPath: p } = kn(), i = typeof r.jsonPath != "object" ? { path: r.jsonPath } : r.jsonPath; - i.group = r.group || i.group || o, i.cycle = r.cycle || i.cycle || !1, i.reverse = r.reverse || i.reverse || !1, i.count = r.count || i.count || 1; - const u = `${i.group}__${i.path}`; - return n[u] || (i.count > 1 ? n[u] = p(i.path, s).slice(0, i.count) : n[u] = p(i.path, s)), i.cycle || i.reverse ? rs(n[u], i.reverse) : ts(n[u]); - } - return Object.keys(r).forEach((p) => { - r[p] = hr(r[p], s, n, p); - }), r; -} -function ns(r, s, n, o) { - if (Object.prototype.toString.call(s) !== "[object Object]") - throw new Error(`Invalid input, expecting object but given ${typeof s}`); - const p = Ce("refDepthMin") || 0, i = Ce("refDepthMax") || 3; - try { - const { resolveSchema: u } = es({ - refs: r, - schema: s, - container: n, - synchronous: o, - refDepthMin: p, - refDepthMax: i - }), a = zo(ke.clone(s), [], u); - return Ce("resolveJsonPath") ? { - value: hr(a.value), - context: a.context - } : a; - } catch (u) { - throw u.path ? new Error(`${u.message} in /${u.path.join("/")}`) : u; - } -} -var Hn = ns; -function is(r) { - return r.value; -} -var qn = is, Be = En(Ii()); -Be.default.binaryOptions; -Be.default.boolOptions; -Be.default.intOptions; -Be.default.nullOptions; -Be.default.strOptions; -Be.default.Schema; -Be.default.Alias; -Be.default.Collection; -Be.default.Merge; -Be.default.Node; -Be.default.Pair; -Be.default.Scalar; -var os = Be.default.YAMLMap, ss = Be.default.YAMLSeq; -function as(r, s) { - return s.reduce((n, o) => o in n ? n[o] : {}, r); -} -function dr(r, s, n, o = n) { - const { title: p, description: i, comment: u } = as(r, s), a = []; - Ce("renderTitle") && p && a.push(` ${p}`, ""), Ce("renderDescription") && i && a.push(` ${i}`), Ce("renderComment") && u && a.push(` ${u}`), n.commentBefore = a.join(` -`), o instanceof os ? o.items.forEach((c) => { - dr(r, [...s, "items", c.key.value], c.key, c.value); - }) : o instanceof ss && o.items.forEach((c, l) => { - dr(r, [...s, "items", l], c); - }); -} -function us({ value: r, context: s }) { - const n = St.createNode(r); - dr(s, [], n); - const o = new St.Document(); - return o.contents = n, o.toString(); -} -var St = us, ze = new lo(); -function Kn() { - ze.define("autoIncrement", function(s, n) { - if (!this.offset) { - const o = n.minimum || 1, p = o + Ge.MAX_NUMBER, i = s.initialOffset || n.initialOffset; - this.offset = i || Se.number(o, p); - } - return s ? this.offset++ : n; - }), ze.define("sequentialDate", function(s, n) { - if (this.now || (this.now = Se.date()), s) { - if (n = this.now.toISOString(), s = s === !0 ? "days" : s, ["seconds", "minutes", "hours", "days", "weeks", "months", "years"].indexOf(s) === -1) - throw new Error(`Unsupported increment by ${ke.short(s)}`); - this.now.setTime(this.now.getTime() + Se.date(s)); - } - return n; - }); -} -function Wn(r, s) { - let n = {}; - Array.isArray(r) ? r.forEach((p) => { - n[p.$id || p.id] = p; - }) : n = r || {}; - function o(p) { - if (!p || typeof p != "object") - return; - if (Array.isArray(p)) - return p.forEach(o); - const i = p.$id || p.id; - typeof i == "string" && !n[i] && (n[i] = p), Object.keys(p).forEach((u) => { - o(p[u]); - }); - } - return o(r), o(s), n; -} -var Me = (r, s, n) => (console.debug("[json-schema-faker] calling JSONSchemaFaker() is deprecated, call either .generate() or .resolve()"), n && console.debug("[json-schema-faker] local references are only supported by calling .resolve()"), Me.generate(r, s)); -Me.generateWithContext = (r, s) => { - const n = Wn(s, r); - return Hn(n, r, ze, !0); -}; -Me.generate = (r, s) => qn( - Me.generateWithContext(r, s) -); -Me.generateYAML = (r, s) => St( - Me.generateWithContext(r, s) -); -Me.resolveWithContext = (r, s, n) => { - typeof s == "string" && (n = s, s = {}), n = n || (typeof process < "u" && typeof process.cwd == "function" ? process.cwd() : ""), n = `${n.replace(/\/+$/, "")}/`; - const o = Wn(s, r), p = { - order: 1, - canRead(u) { - const a = u.url.replace("/:", ":"); - return o[a] || o[a.split("/").pop()]; - }, - read(u, a) { - try { - a(null, this.canRead(u)); - } catch (c) { - a(c); - } - } - }, { $RefParser: i } = kn(); - return i.bundle(n, r, { - resolve: { - file: { order: 100 }, - http: { order: 200 }, - fixedRefs: p - }, - dereference: { - circular: "ignore" - } - }).then((u) => Hn(o, u, ze)).catch((u) => { - throw new Error(`Error while resolving schema (${u.message})`); - }); -}; -Me.resolve = (r, s, n) => Me.resolveWithContext(r, s, n).then(qn); -Me.resolveYAML = (r, s, n) => Me.resolveWithContext(r, s, n).then(St); -Kn(); -Me.format = Bn; -Me.option = Ce; -Me.random = Se; -Me.extend = (r, s) => (ze.extend(r, s), Me); -Me.define = (r, s) => (ze.define(r, s), Me); -Me.reset = (r) => (ze.reset(r), Kn(), Me); -Me.locate = (r) => ze.get(r); -Me.VERSION = "0.5.8"; -({ ...Me }); -var Ie = Me; -typeof $RefParser < "u" && typeof JSONPath < "u" && Li({ ...JSONPath, $RefParser }); -function ls(r, s, n, o) { - const p = cs(Ne(r, s?.requestBody), n); - return p ? fs(r, p[0], p[1], o) : { mediaType: "text/plain", value: "" }; -} -function fs(r, s, n, o) { - if (o !== void 0) - return { mediaType: s, value: o }; - if (n?.example) - return { - mediaType: s, - value: n.example - }; - if (n?.examples && Object.values(n.examples).length > 0) { - const p = Object.values(n.examples)[0]; - return { - mediaType: s, - value: Ne(r, p)?.value ?? {} - }; - } - if (kt.includes(s) && n?.schema) { - const p = Ne(r, n.schema); - if (p) { - Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); - try { - return { - mediaType: s, - value: Ie.generate({ ...p, components: r.components }) - }; - } catch { - return { mediaType: s, value: {} }; - } - } - } - return { - mediaType: s, - value: "" - }; -} -function Ea(r) { - return kt.includes(r.mediaType) ? JSON.stringify(r.value, null, 2) : r.value.toString(); -} -function Aa(r, s) { - if (kt.includes(r)) - try { - return JSON.parse(s); - } catch (n) { - return new Error(`failed to convert: ${n}`); - } - return s; -} -function cs(r, s) { - if (!r || !r.content) - return; - const n = [...kt]; - s && n.unshift(s); - for (const p of n) - if (r.content[p]) - return [p, r.content[p]]; - const o = Object.keys(r.content)[0]; - return [o, r.content[o]]; -} -const kt = [ - "application/json", - "application/x-www-form-urlencoded", - "multipart/form-data" -]; -function xa(r, s, n, o, p) { - const i = Ct(r, s, n), u = Vn(r, s, n), a = Jn(r, u), c = pi(r, s, n), l = ps(c), f = ls(r, i, o, p); - return { - server: yn(r)?.[0] || "", - parameters: a, - security: l, - securityIndex: 0, - body: f - }; -} -function Vn(r, s, n) { - const o = r.paths ? li(r, r.paths[s]) : [], p = Ct(r, s, n), i = fi(r, p); - return ci(r, o, i); -} -function _a(r, s, n) { - return (Ct(r, s, n)?.security ?? r.security ?? []).length > 0; -} -function Jn(r, s) { - const n = { - query: {}, - header: {}, - path: {}, - cookie: {} - }, o = Object.keys(s); - for (const p of o) - for (const i of Object.keys(s[p])) { - const u = s[p][i]; - if (u?.example !== void 0) - n[p][i] = u.example; - else if (u?.examples && Object.values(u.examples).length > 0) { - const a = Object.values(u.examples)[0], c = Ne(r, a)?.value; - n[p][i] = c === void 0 ? "" : c; - } else if (u.schema) { - Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); - try { - n[p][i] = Ie.generate({ - ...u.schema, - components: r.components - }); - } catch { - n[p][i] = ""; - } - } else - n[p][i] = ""; - } - return n; -} -function ps(r) { - const s = []; - for (const n of r) { - const o = {}; - for (const [p, i] of Object.entries(n)) - i && (o[p] = hs(i)); - s.push(o); - } - return s; -} -function hs(r) { - return r?.type === "http" && /^basic$/i.test(r?.scheme) ? { username: "", password: "" } : ""; -} -function Oa(r) { - const s = { - query: {}, - header: {}, - path: {}, - cookie: {} - }, n = Object.keys(r.parameters); - for (const p of n) - for (const i of Object.keys(r.parameters[p] ?? {})) { - const u = Or(i), a = r.parameters[p][i]; - s[p][u] = Array.isArray(a) ? gs(a) : a; - } - const o = []; - for (const p of r.security) { - const i = {}; - for (const [u, a] of Object.entries(p)) - i[Or(u)] = a; - o.push(i); - } - return { - parameters: s, - body: r.body, - server: r.server, - security: o, - securityIndex: r.securityIndex - }; -} -function Sa(r) { - return { - parameters: ms(r.parameters), - body: r.body, - server: r.server, - security: ds(r.security), - securityIndex: r.securityIndex - }; -} -function ds(r) { - const s = []; - for (const n of r) { - const o = {}; - for (const [p, i] of Object.entries(n)) - o[Gn(p)] = i; - s.push(o); - } - return s; -} -function ms(r) { - const s = { - query: {}, - header: {}, - path: {}, - cookie: {} - }, n = Object.keys(r); - for (const o of n) - for (const p of Object.keys(r[o])) { - const i = Gn(p), u = r[o][p]; - s[o][i] = Array.isArray(u) ? ys(u) : u; - } - return s; -} -function Ca(r) { - try { - const s = new URL(r), n = s.protocol === "https:", o = s.hostname.toLowerCase(); - return [n, o]; - } catch { - return [!1, ""]; - } -} -function gs(r) { - return r.map((s) => ({ value: s })); -} -function ys(r) { - return r.map((s) => s.value); -} -function Or(r) { - return "n-" + encodeURIComponent(r).replace(/\./g, "%2E"); -} -function Gn(r) { - return decodeURIComponent(r.substring(2, r.length)); -} -function vs(r, s, n, o, p) { - const i = ws(r, s, o); - if (i !== void 0 && p !== void 0) - return { mediaType: i, value: p }; - if (i !== void 0 && Es.includes(i)) - return bs(r, s, n, i); -} -function bs(r, s, n, o) { - if (As.includes(o)) - return { mediaType: o, value: {} }; - if (o == "application/json") { - const p = Object.values(n.body)?.[0], i = Ne(r, p?.schema); - if (i) { - Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); - try { - return { - mediaType: o, - value: Ie.generate({ ...i, definitions: r.definitions }) - }; - } catch { - return { mediaType: o, value: {} }; - } - } - return { mediaType: o, value: {} }; - } - return { - mediaType: o, - value: "" - }; -} -function ws(r, s, n) { - const o = gi(r, s); - if (n !== void 0 && o.includes(n)) - return n; - if (o.length > 0) - return o[0]; -} -const Es = [ - "application/json", - "application/x-www-form-urlencoded", - "multipart/form-data" -], As = ["application/x-www-form-urlencoded", "multipart/form-data"]; -function Ta(r, s, n, o, p) { - const i = Tt(r, s, n), u = Qn(r, s, n), a = Xn(r, u), c = xs(r, s, n), l = _s(c), f = vn(r), d = vs( - r, - i, - u, - o, - p - ); - return { - server: f?.[0] || "", - parameters: a, - security: l, - securityIndex: 0, - body: d - }; -} -function Qn(r, s, n) { - const o = hi(r, r.paths[s]), p = Tt(r, s, n), i = di(r, p); - return mi(r, o, i); -} -function Xn(r, s) { - const n = { - query: {}, - header: {}, - path: {}, - cookie: {} - }, o = Object.keys(s); - for (const p of o) - if (!(p === "body" || p === "formData")) - for (const i of Object.keys(s[p])) { - const u = s[p][i]; - if (u.type) { - Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); - try { - n[p][i] = Ie.generate({ - ...u, - definitions: r.definitions - }); - } catch { - n[p][i] = ""; - } - } else - n[p][i] = ""; - } - return n; -} -function Pa(r, s, n) { - return (Tt(r, s, n)?.security ?? r.security ?? []).length > 0; -} -function xs(r, s, n) { - const p = Tt(r, s, n)?.security ?? r.security ?? [], i = []; - for (const u of p) { - const a = {}; - for (const c of Object.keys(u)) - r?.securityDefinitions?.[c] && (a[c] = r?.securityDefinitions?.[c]); - i.push(a); - } - return i; -} -function _s(r) { - const s = []; - for (const n of r) { - const o = {}; - for (const [p, i] of Object.entries(n)) - i && (o[p] = Os(i)); - s.push(o); - } - return s; -} -function Os(r) { - return r?.type === "basic" ? { username: "", password: "" } : ""; -} -var jt = {}, at = {}, ut = {}, Fe = {}, Ke = {}, Sr; -function Ss() { - return Sr || (Sr = 1, Object.defineProperty(Ke, "__esModule", { value: !0 }), Ke.preserveLocationKey = Ke.preserveFormattingKey = Ke.preserveRootRangeKey = void 0, Ke.preserveRootRangeKey = /* @__PURE__ */ Symbol("preserve-root-location"), Ke.preserveFormattingKey = /* @__PURE__ */ Symbol("preserve-formatting"), Ke.preserveLocationKey = /* @__PURE__ */ Symbol("preserve-location")), Ke; -} -var Cr; -function gt() { - if (Cr) return Fe; - Cr = 1, Object.defineProperty(Fe, "__esModule", { value: !0 }), Fe.copyPreservedValues = Fe.setPreservedRootRange = Fe.getPreservedRootRange = Fe.setPreservedLocation = Fe.getPreservedLocation = Fe.setPreservedValue = Fe.getPreservedValue = void 0; - const r = Ss(); - function s(c, l) { - var f; - return (f = c?.[r.preserveFormattingKey]) === null || f === void 0 ? void 0 : f[l]; - } - Fe.getPreservedValue = s; - function n(c, l, f) { - c[r.preserveFormattingKey] === void 0 && Object.defineProperty(c, r.preserveFormattingKey, { enumerable: !1, value: {} }), c[r.preserveFormattingKey][l] = f; - } - Fe.setPreservedValue = n; - function o(c, l) { - var f; - return (f = c?.[r.preserveLocationKey]) === null || f === void 0 ? void 0 : f[l]; - } - Fe.getPreservedLocation = o; - function p(c, l, f) { - c[r.preserveLocationKey] === void 0 && Object.defineProperty(c, r.preserveLocationKey, { enumerable: !1, value: {} }), c[r.preserveLocationKey][l] = f; - } - Fe.setPreservedLocation = p; - function i(c) { - return c[r.preserveRootRangeKey]; - } - Fe.getPreservedRootRange = i; - function u(c, l) { - Object.defineProperty(c, r.preserveRootRangeKey, { enumerable: !1, value: l }); - } - Fe.setPreservedRootRange = u; - function a(c, l) { - c && c[r.preserveFormattingKey] !== void 0 && Object.defineProperty(l, r.preserveFormattingKey, { - enumerable: !1, - value: c[r.preserveFormattingKey] - }); - } - return Fe.copyPreservedValues = a, Fe; -} -var Tr; -function zn() { - if (Tr) return ut; - Tr = 1, Object.defineProperty(ut, "__esModule", { value: !0 }), ut.visitObject = void 0; - const r = gt(); - function s(o, p, i, u) { - const a = n(i); - if (a === "object") { - u.onObjectStart(o, p, i, (0, r.getPreservedLocation)(o, p)); - for (const c in i) - s(i, c, i[c], u); - u.onObjectEnd(); - } else a === "array" ? (u.onArrayStart(o, p, i, (0, r.getPreservedLocation)(o, p)), i.forEach((c, l) => { - s(i, l, c, u); - }), u.onArrayEnd()) : u.onValue(o, p, i, (0, r.getPreservedValue)(o, p), (0, r.getPreservedLocation)(o, p)); - } - ut.visitObject = s; - function n(o) { - return typeof o == "object" ? o === null || o instanceof Number || o instanceof String || o instanceof Boolean ? "value" : o instanceof Array ? "array" : "object" : "value"; - } - return ut; -} -var Pr; -function Cs() { - if (Pr) return at; - Pr = 1, Object.defineProperty(at, "__esModule", { value: !0 }), at.simpleClone = void 0; - const r = zn(), s = gt(); - function n(o, p) { - let i = {}, u = []; - const a = [i]; - return (0, r.visitObject)(void 0, "fakeroot", o, { - onObjectStart: (c, l, f) => { - u.push(l), a.push(i), i = i[l] = {}, (0, s.copyPreservedValues)(f, i); - }, - onObjectEnd: () => { - u.pop(), i = a.pop(); - }, - onArrayStart: (c, l, f) => { - u.push(l), a.push(i), i = i[l] = [], (0, s.copyPreservedValues)(f, i); - }, - onArrayEnd: () => { - u.pop(), i = a.pop(); - }, - onValue: (c, l, f, d) => { - i[l] = p ? p(f, [...u.slice(1), l]) : f; - } - }), a[0].fakeroot; - } - return at.simpleClone = n, at; -} -var Ze = {}, lt = {}, Ft = {}, Ye = {}, $t = {}, Rr; -function Qe() { - return Rr || (Rr = 1, (function(r) { - Object.defineProperty(r, "__esModule", { value: !0 }); - var s; - (function(f) { - f[f.SCALAR = 0] = "SCALAR", f[f.MAPPING = 1] = "MAPPING", f[f.MAP = 2] = "MAP", f[f.SEQ = 3] = "SEQ", f[f.ANCHOR_REF = 4] = "ANCHOR_REF", f[f.INCLUDE_REF = 5] = "INCLUDE_REF"; - })(s = r.Kind || (r.Kind = {})); - function n(f, d) { - var E = d ? d.endPosition : f.endPosition + 1, y = { - key: f, - value: d, - startPosition: f.startPosition, - endPosition: E, - kind: s.MAPPING, - parent: null, - errors: [] - }; - return y; - } - r.newMapping = n; - function o(f, d, E, y) { - return { - errors: [], - referencesAnchor: f, - value: y, - startPosition: d, - endPosition: E, - kind: s.ANCHOR_REF, - parent: null - }; - } - r.newAnchorRef = o; - function p(f = "") { - const d = { - errors: [], - startPosition: -1, - endPosition: -1, - value: "" + f, - kind: s.SCALAR, - parent: null, - doubleQuoted: !1, - rawValue: "" + f - }; - return typeof f != "string" && (d.valueObject = f), d; - } - r.newScalar = p; - function i() { - return { - errors: [], - startPosition: -1, - endPosition: -1, - items: [], - kind: s.SEQ, - parent: null - }; - } - r.newItems = i; - function u() { - return i(); - } - r.newSeq = u; - function a(f) { - return { - errors: [], - startPosition: -1, - endPosition: -1, - mappings: f || [], - kind: s.MAP, - parent: null - }; - } - r.newMap = a; - function c(f, d) { - if (!f || !d || f.kind !== d.kind) - return !1; - if (f.kind === s.SCALAR) - return f.value === d.value; - if (f.kind === s.SEQ) { - const E = f, y = d; - if (E.items.length !== y.items.length) - return !1; - for (let S = 0; S < E.items.length; S++) { - const T = E.items[S], v = y.items[S]; - if (!c(T, v)) - return !1; - } - return !0; - } - if (f.kind === s.MAP) { - const E = f, y = d; - if (E.mappings.length !== y.mappings.length) - return !1; - for (const S of E.mappings) { - const T = S.key, v = S.value, h = y.mappings.find((b) => c(T, b.key)); - if (h) { - if (!c(v, h.value)) - return !1; - } else - return !1; - } - return !0; - } - if (s.MAPPING === f.kind) { - const E = f, y = d; - return c(E.key, y.key); - } - return !1; - } - r.isNodesEqual = c; - function l(f) { - return f.startPosition !== void 0 && f.endPosition !== void 0 && f.kind !== void 0; - } - r.isYAMLNode = l; - })($t)), $t; -} -var We = {}, kr; -function it() { - if (kr) return We; - kr = 1, Object.defineProperty(We, "__esModule", { value: !0 }); - function r(u) { - return typeof u > "u" || u === null; - } - We.isNothing = r; - function s(u) { - return typeof u == "object" && u !== null; - } - We.isObject = s; - function n(u) { - return Array.isArray(u) ? u : r(u) ? [] : [u]; - } - We.toArray = n; - function o(u, a) { - var c, l, f, d; - if (a) - for (d = Object.keys(a), c = 0, l = d.length; c < l; c += 1) - f = d[c], u[f] = a[f]; - return u; - } - We.extend = o; - function p(u, a) { - var c = "", l; - for (l = 0; l < a; l += 1) - c += u; - return c; - } - We.repeat = p; - function i(u) { - return u === 0 && Number.NEGATIVE_INFINITY === 1 / u; - } - return We.isNegativeZero = i, We; -} -var Dt, Ir; -function yt() { - if (Ir) return Dt; - Ir = 1; - class r { - constructor(n, o = null, p = !1) { - this.name = "YAMLException", this.reason = n, this.mark = o, this.message = this.toString(!1), this.isWarning = p; - } - static isInstance(n) { - if (n != null && n.getClassIdentifier && typeof n.getClassIdentifier == "function") { - for (let o of n.getClassIdentifier()) - if (o == r.CLASS_IDENTIFIER) - return !0; - } - return !1; - } - getClassIdentifier() { - var n = []; - return n.concat(r.CLASS_IDENTIFIER); - } - toString(n = !1) { - var o; - return o = "JS-YAML: " + (this.reason || "(unknown reason)"), !n && this.mark && (o += " " + this.mark.toString()), o; - } - } - return r.CLASS_IDENTIFIER = "yaml-ast-parser.YAMLException", Dt = r, Dt; -} -var Bt, Lr; -function Ts() { - if (Lr) return Bt; - Lr = 1; - const r = it(); - class s { - constructor(o, p, i, u, a) { - this.name = o, this.buffer = p, this.position = i, this.line = u, this.column = a; - } - getSnippet(o = 0, p = 75) { - var i, u, a, c, l; - if (!this.buffer) - return null; - for (o = o || 4, p = p || 75, i = "", u = this.position; u > 0 && `\0\r -…\u2028\u2029`.indexOf(this.buffer.charAt(u - 1)) === -1; ) - if (u -= 1, this.position - u > p / 2 - 1) { - i = " ... ", u += 5; - break; - } - for (a = "", c = this.position; c < this.buffer.length && `\0\r -…\u2028\u2029`.indexOf(this.buffer.charAt(c)) === -1; ) - if (c += 1, c - this.position > p / 2 - 1) { - a = " ... ", c -= 5; - break; - } - return l = this.buffer.slice(u, c), r.repeat(" ", o) + i + l + a + ` -` + r.repeat(" ", o + this.position - u + i.length) + "^"; - } - toString(o = !0) { - var p, i = ""; - return this.name && (i += 'in "' + this.name + '" '), i += "at line " + (this.line + 1) + ", column " + (this.column + 1), o || (p = this.getSnippet(), p && (i += `: -` + p)), i; - } - } - return Bt = s, Bt; -} -var Et = {}, At = {}, Mr; -function $e() { - if (Mr) return At; - Mr = 1, Object.defineProperty(At, "__esModule", { value: !0 }); - const r = yt(); - var s = [ - "kind", - "resolve", - "construct", - "instanceOf", - "predicate", - "represent", - "defaultStyle", - "styleAliases" - ], n = [ - "scalar", - "sequence", - "mapping" - ]; - function o(i) { - var u = {}; - return i !== null && Object.keys(i).forEach(function(a) { - i[a].forEach(function(c) { - u[String(c)] = a; - }); - }), u; - } - class p { - constructor(u, a) { - if (a = a || {}, Object.keys(a).forEach(function(c) { - if (s.indexOf(c) === -1) - throw new r('Unknown option "' + c + '" is met in definition of "' + u + '" YAML type.'); - }), this.tag = u, this.kind = a.kind || null, this.resolve = a.resolve || function() { - return !0; - }, this.construct = a.construct || function(c) { - return c; - }, this.instanceOf = a.instanceOf || null, this.predicate = a.predicate || null, this.represent = a.represent || null, this.defaultStyle = a.defaultStyle || null, this.styleAliases = o(a.styleAliases || null), n.indexOf(this.kind) === -1) - throw new r('Unknown kind "' + this.kind + '" is specified for "' + u + '" YAML type.'); - } - } - return At.Type = p, At; -} -var Nr; -function ot() { - if (Nr) return Et; - Nr = 1, Object.defineProperty(Et, "__esModule", { value: !0 }); - const r = it(), s = yt(), n = $e(); - function o(u, a, c) { - var l = []; - return u.include.forEach(function(f) { - c = o(f, a, c); - }), u[a].forEach(function(f) { - c.forEach(function(d, E) { - d.tag === f.tag && l.push(E); - }), c.push(f); - }), c.filter(function(f, d) { - return l.indexOf(d) === -1; - }); - } - function p() { - var u = {}, a, c; - function l(f) { - u[f.tag] = f; - } - for (a = 0, c = arguments.length; a < c; a += 1) - arguments[a].forEach(l); - return u; - } - class i { - constructor(a) { - this.include = a.include || [], this.implicit = a.implicit || [], this.explicit = a.explicit || [], this.implicit.forEach(function(c) { - if (c.loadKind && c.loadKind !== "scalar") - throw new s("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported."); - }), this.compiledImplicit = o(this, "implicit", []), this.compiledExplicit = o(this, "explicit", []), this.compiledTypeMap = p(this.compiledImplicit, this.compiledExplicit); - } - } - return i.DEFAULT = null, i.create = function(...a) { - var c, l; - switch (a.length) { - case 1: - c = i.DEFAULT, l = a[0]; - break; - case 2: - c = a[0], l = a[1]; - break; - default: - throw new s("Wrong number of arguments for Schema.create function"); - } - if (c = r.toArray(c), l = r.toArray(l), !c.every(function(f) { - return f instanceof i; - })) - throw new s("Specified list of super schemas (or a single Schema object) contains a non-Schema object."); - if (!l.every(function(f) { - return f instanceof n.Type; - })) - throw new s("Specified list of YAML types (or a single Type object) contains a non-Type object."); - return new i({ - include: c, - explicit: l - }); - }, Et.Schema = i, Et; -} -var Ut, jr; -function Ps() { - if (jr) return Ut; - jr = 1; - const r = $e(); - return Ut = new r.Type("tag:yaml.org,2002:str", { - kind: "scalar", - construct: function(s) { - return s !== null ? s : ""; - } - }), Ut; -} -var Yt, Fr; -function Rs() { - if (Fr) return Yt; - Fr = 1; - const r = $e(); - return Yt = new r.Type("tag:yaml.org,2002:seq", { - kind: "sequence", - construct: function(s) { - return s !== null ? s : []; - } - }), Yt; -} -var Ht, $r; -function ks() { - if ($r) return Ht; - $r = 1; - const r = $e(); - return Ht = new r.Type("tag:yaml.org,2002:map", { - kind: "mapping", - construct: function(s) { - return s !== null ? s : {}; - } - }), Ht; -} -var qt, Dr; -function Is() { - if (Dr) return qt; - Dr = 1; - const r = ot(); - return qt = new r.Schema({ - explicit: [ - Ps(), - Rs(), - ks() - ] - }), qt; -} -var Kt, Br; -function Ls() { - if (Br) return Kt; - Br = 1; - const r = $e(), s = Qe(); - function n(i) { - const u = s.isYAMLNode(i) ? i.value : i; - if (u === null) - return !0; - var a = u.length; - return a === 1 && u === "~" || a === 4 && (u === "null" || u === "Null" || u === "NULL"); - } - function o(i) { - return s.isYAMLNode(i) ? i : null; - } - function p(i) { - return i === null; - } - return Kt = new r.Type("tag:yaml.org,2002:null", { - kind: "scalar", - resolve: n, - construct: o, - predicate: p, - represent: { - canonical: function() { - return "~"; - }, - lowercase: function() { - return "null"; - }, - uppercase: function() { - return "NULL"; - }, - camelcase: function() { - return "Null"; - } - }, - defaultStyle: "lowercase" - }), Kt; -} -var Wt, Ur; -function Ms() { - if (Ur) return Wt; - Ur = 1; - const r = $e(), s = Qe(); - function n(i) { - const u = s.isYAMLNode(i) ? i.value : i; - if (u === null) - return !1; - var a = u.length; - return a === 4 && (u === "true" || u === "True" || u === "TRUE") || a === 5 && (u === "false" || u === "False" || u === "FALSE"); - } - function o(i) { - return s.isYAMLNode(i) ? i : i === "true" || i === "True" || i === "TRUE"; - } - function p(i) { - return Object.prototype.toString.call(i) === "[object Boolean]"; - } - return Wt = new r.Type("tag:yaml.org,2002:bool", { - kind: "scalar", - resolve: n, - construct: o, - predicate: p, - represent: { - lowercase: function(i) { - return i ? "true" : "false"; - }, - uppercase: function(i) { - return i ? "TRUE" : "FALSE"; - }, - camelcase: function(i) { - return i ? "True" : "False"; - } - }, - defaultStyle: "lowercase" - }), Wt; -} -var Vt, Yr; -function Ns() { - if (Yr) return Vt; - Yr = 1; - const r = it(), s = $e(), n = Qe(); - function o(l) { - return 48 <= l && l <= 57 || 65 <= l && l <= 70 || 97 <= l && l <= 102; - } - function p(l) { - return 48 <= l && l <= 55; - } - function i(l) { - return 48 <= l && l <= 57; - } - function u(l) { - const f = n.isYAMLNode(l) ? l.value : l; - if (f === null) - return !1; - var d = f.length, E = 0, y = !1, S; - if (!d) - return !1; - if (S = f[E], (S === "-" || S === "+") && (S = f[++E]), S === "0") { - if (E + 1 === d) - return !0; - if (S = f[++E], S === "b") { - for (E++; E < d; E++) - if (S = f[E], S !== "_") { - if (S !== "0" && S !== "1") - return !1; - y = !0; - } - return y; - } - if (S === "x") { - for (E++; E < d; E++) - if (S = f[E], S !== "_") { - if (!o(f.charCodeAt(E))) - return !1; - y = !0; - } - return y; - } - for (; E < d; E++) - if (S = f[E], S !== "_") { - if (!p(f.charCodeAt(E))) - return !1; - y = !0; - } - return y; - } - for (; E < d; E++) - if (S = f[E], S !== "_") { - if (S === ":") - break; - if (!i(f.charCodeAt(E))) - return !1; - y = !0; - } - return y ? S !== ":" ? !0 : /^(:[0-5]?[0-9])+$/.test(f.slice(E)) : !1; - } - function a(l) { - if (n.isYAMLNode(l)) - return l; - var f = l, d = 1, E, y, S = []; - return f.indexOf("_") !== -1 && (f = f.replace(/_/g, "")), E = f[0], (E === "-" || E === "+") && (E === "-" && (d = -1), f = f.slice(1), E = f[0]), f === "0" ? 0 : E === "0" ? f[1] === "b" ? d * parseInt(f.slice(2), 2) : f[1] === "x" ? d * parseInt(f, 16) : d * parseInt(f, 8) : f.indexOf(":") !== -1 ? (f.split(":").forEach(function(T) { - S.unshift(parseInt(T, 10)); - }), f = 0, y = 1, S.forEach(function(T) { - f += T * y, y *= 60; - }), d * f) : d * parseInt(f, 10); - } - function c(l) { - return Object.prototype.toString.call(l) === "[object Number]" && l % 1 === 0 && !r.isNegativeZero(l); - } - return Vt = new s.Type("tag:yaml.org,2002:int", { - kind: "scalar", - resolve: u, - construct: a, - predicate: c, - represent: { - binary: function(l) { - return "0b" + l.toString(2); - }, - octal: function(l) { - return "0" + l.toString(8); - }, - decimal: function(l) { - return l.toString(10); - }, - hexadecimal: function(l) { - return "0x" + l.toString(16).toUpperCase(); - } - }, - defaultStyle: "decimal", - styleAliases: { - binary: [2, "bin"], - octal: [8, "oct"], - decimal: [10, "dec"], - hexadecimal: [16, "hex"] - } - }), Vt; -} -var Jt, Hr; -function js() { - if (Hr) return Jt; - Hr = 1; - const r = it(), s = $e(), n = Qe(); - var o = new RegExp("-?(0|[1-9][0-9]*)(.[0-9]*)?([eE][-+]?[0-9]+)?|^0$|^[-+]?.(inf|Inf|INF)$|^.(nan|NaN|NAN)$"); - function p(c) { - const l = n.isYAMLNode(c) ? c.value : c; - return !(l === null || !o.test(l)); - } - function i(c) { - if (n.isYAMLNode(c)) - return c; - var l, f, d, E; - return l = c.replace(/_/g, "").toLowerCase(), f = l[0] === "-" ? -1 : 1, E = [], 0 <= "+-".indexOf(l[0]) && (l = l.slice(1)), l === ".inf" ? f === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : l === ".nan" ? NaN : 0 <= l.indexOf(":") ? (l.split(":").forEach(function(y) { - E.unshift(parseFloat(y, 10)); - }), l = 0, d = 1, E.forEach(function(y) { - l += y * d, d *= 60; - }), f * l) : f * parseFloat(l, 10); - } - function u(c, l) { - if (isNaN(c)) - switch (l) { - case "lowercase": - return ".nan"; - case "uppercase": - return ".NAN"; - case "camelcase": - return ".NaN"; - } - else if (Number.POSITIVE_INFINITY === c) - switch (l) { - case "lowercase": - return ".inf"; - case "uppercase": - return ".INF"; - case "camelcase": - return ".Inf"; - } - else if (Number.NEGATIVE_INFINITY === c) - switch (l) { - case "lowercase": - return "-.inf"; - case "uppercase": - return "-.INF"; - case "camelcase": - return "-.Inf"; - } - else if (r.isNegativeZero(c)) - return "-0.0"; - return c.toString(10); - } - function a(c) { - return Object.prototype.toString.call(c) === "[object Number]" && (c % 1 !== 0 || r.isNegativeZero(c)); - } - return Jt = new s.Type("tag:yaml.org,2002:float", { - kind: "scalar", - resolve: p, - construct: i, - predicate: a, - represent: u, - defaultStyle: "lowercase" - }), Jt; -} -var Gt, qr; -function Fs() { - if (qr) return Gt; - qr = 1; - const r = ot(); - return Gt = new r.Schema({ - include: [ - Is() - ], - implicit: [ - Ls(), - Ms(), - Ns(), - js() - ] - }), Gt; -} -var Qt, Kr; -function $s() { - if (Kr) return Qt; - Kr = 1; - const r = ot(); - return Qt = new r.Schema({ - include: [ - Fs() - ] - }), Qt; -} -var Xt, Wr; -function Ds() { - if (Wr) return Xt; - Wr = 1; - const r = $e(); - var s = 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 n(i) { - if (i === null) - return !1; - var u; - return u = s.exec(i), u !== null; - } - function o(i) { - var u, a, c, l, f, d, E, y = 0, S = null, T, v, h; - if (u = s.exec(i), u === null) - throw new Error("Date resolve error"); - if (a = +u[1], c = +u[2] - 1, l = +u[3], !u[4]) - return new Date(Date.UTC(a, c, l)); - if (f = +u[4], d = +u[5], E = +u[6], u[7]) { - for (y = u[7].slice(0, 3); y.length < 3; ) - y = y + "0"; - y = +y; - } - return u[9] && (T = +u[10], v = +(u[11] || 0), S = (T * 60 + v) * 6e4, u[9] === "-" && (S = -S)), h = new Date(Date.UTC(a, c, l, f, d, E, y)), S && h.setTime(h.getTime() - S), h; - } - function p(i) { - return i.toISOString(); - } - return Xt = new r.Type("tag:yaml.org,2002:timestamp", { - kind: "scalar", - resolve: n, - construct: o, - instanceOf: Date, - represent: p - }), Xt; -} -var zt, Vr; -function Bs() { - if (Vr) return zt; - Vr = 1; - const r = $e(); - function s(n) { - return n === "<<" || n === null; - } - return zt = new r.Type("tag:yaml.org,2002:merge", { - kind: "scalar", - resolve: s - }), zt; -} -var Zt, Jr; -function Us() { - if (Jr) return Zt; - Jr = 1; - var r = ui().Buffer; - const s = $e(), n = Qe(); - var o = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= -\r`; - function p(c) { - if (c === null) - return !1; - var l, f, d = 0, E = c.length, y = o; - for (f = 0; f < E; f++) - if (l = y.indexOf(c.charAt(f)), !(l > 64)) { - if (l < 0) - return !1; - d += 6; - } - return d % 8 === 0; - } - function i(c) { - if (n.isYAMLNode(c)) - return c; - var l, f, d = c.replace(/[\r\n=]/g, ""), E = d.length, y = o, S = 0, T = []; - for (l = 0; l < E; l++) - l % 4 === 0 && l && (T.push(S >> 16 & 255), T.push(S >> 8 & 255), T.push(S & 255)), S = S << 6 | y.indexOf(d.charAt(l)); - return f = E % 4 * 6, f === 0 ? (T.push(S >> 16 & 255), T.push(S >> 8 & 255), T.push(S & 255)) : f === 18 ? (T.push(S >> 10 & 255), T.push(S >> 2 & 255)) : f === 12 && T.push(S >> 4 & 255), r ? new r(T) : T; - } - function u(c) { - var l = "", f = 0, d, E, y = c.length, S = o; - for (d = 0; d < y; d++) - d % 3 === 0 && d && (l += S[f >> 18 & 63], l += S[f >> 12 & 63], l += S[f >> 6 & 63], l += S[f & 63]), f = (f << 8) + c[d]; - return E = y % 3, E === 0 ? (l += S[f >> 18 & 63], l += S[f >> 12 & 63], l += S[f >> 6 & 63], l += S[f & 63]) : E === 2 ? (l += S[f >> 10 & 63], l += S[f >> 4 & 63], l += S[f << 2 & 63], l += S[64]) : E === 1 && (l += S[f >> 2 & 63], l += S[f << 4 & 63], l += S[64], l += S[64]), l; - } - function a(c) { - return r && r.isBuffer(c); - } - return Zt = new s.Type("tag:yaml.org,2002:binary", { - kind: "scalar", - resolve: p, - construct: i, - predicate: a, - represent: u - }), Zt; -} -var er, Gr; -function Ys() { - if (Gr) return er; - Gr = 1; - const r = $e(); - var s = Object.prototype.hasOwnProperty, n = Object.prototype.toString; - function o(i) { - if (i === null) - return !0; - var u = [], a, c, l, f, d, E = i; - for (a = 0, c = E.length; a < c; a += 1) { - if (l = E[a], d = !1, n.call(l) !== "[object Object]") - return !1; - for (f in l) - if (s.call(l, f)) - if (!d) - d = !0; - else - return !1; - if (!d) - return !1; - if (u.indexOf(f) === -1) - u.push(f); - else - return !1; - } - return !0; - } - function p(i) { - return i !== null ? i : []; - } - return er = new r.Type("tag:yaml.org,2002:omap", { - kind: "sequence", - resolve: o, - construct: p - }), er; -} -var tr, Qr; -function Hs() { - if (Qr) return tr; - Qr = 1; - const r = $e(), s = Qe(); - var n = Object.prototype.toString; - function o(i) { - if (i === null) - return !0; - if (i.kind != s.Kind.SEQ) - return !1; - var u, a, c, l = i.items; - for (u = 0, a = l.length; u < a; u += 1) - if (c = l[u], n.call(c) !== "[object Object]" || !Array.isArray(c.mappings) || c.mappings.length !== 1) - return !1; - return !0; - } - function p(i) { - if (i === null || !Array.isArray(i.items)) - return []; - let u, a, c, l = i.items; - for (c = s.newItems(), c.parent = i.parent, c.startPosition = i.startPosition, c.endPosition = i.endPosition, u = 0, a = l.length; u < a; u += 1) { - let d = l[u].mappings[0], E = s.newItems(); - E.parent = c, E.startPosition = d.key.startPosition, E.endPosition = d.value.startPosition, d.key.parent = E, d.value.parent = E, E.items = [d.key, d.value], c.items.push(E); - } - return c; - } - return tr = new r.Type("tag:yaml.org,2002:pairs", { - kind: "sequence", - resolve: o, - construct: p - }), tr; -} -var rr, Xr; -function qs() { - if (Xr) return rr; - Xr = 1; - const r = $e(), s = Qe(); - function n(p) { - return p === null ? !0 : p.kind == s.Kind.MAP; - } - function o(p) { - return p !== null ? p : {}; - } - return rr = new r.Type("tag:yaml.org,2002:set", { - kind: "mapping", - resolve: n, - construct: o - }), rr; -} -var nr, zr; -function It() { - if (zr) return nr; - zr = 1; - const r = ot(); - var s = new r.Schema({ - include: [ - $s() - ], - implicit: [ - Ds(), - Bs() - ], - explicit: [ - Us(), - Ys(), - Hs(), - qs() - ] - }); - return nr = s, nr; -} -var ir, Zr; -function Ks() { - if (Zr) return ir; - Zr = 1; - const r = $e(); - function s() { - return !0; - } - function n() { - } - function o() { - return ""; - } - function p(i) { - return typeof i > "u"; - } - return ir = new r.Type("tag:yaml.org,2002:js/undefined", { - kind: "scalar", - resolve: s, - construct: n, - predicate: p, - represent: o - }), ir; -} -var or, en; -function Ws() { - if (en) return or; - en = 1; - const r = $e(); - function s(i) { - if (i === null || i.length === 0) - return !1; - var u = i, a = /\/([gim]*)$/.exec(i), c = ""; - if (u[0] === "/") { - if (a && (c = a[1]), c.length > 3 || u[u.length - c.length - 1] !== "/") - return !1; - u = u.slice(1, u.length - c.length - 1); - } - try { - var l = new RegExp(u, c); - return !0; - } catch { - return !1; - } - } - function n(i) { - var u = i, a = /\/([gim]*)$/.exec(i), c = ""; - return u[0] === "/" && (a && (c = a[1]), u = u.slice(1, u.length - c.length - 1)), new RegExp(u, c); - } - function o(i) { - var u = "/" + i.source + "/"; - return i.global && (u += "g"), i.multiline && (u += "m"), i.ignoreCase && (u += "i"), u; - } - function p(i) { - return Object.prototype.toString.call(i) === "[object RegExp]"; - } - return or = new r.Type("tag:yaml.org,2002:js/regexp", { - kind: "scalar", - resolve: s, - construct: n, - predicate: p, - represent: o - }), or; -} -var sr, tn; -function Zn() { - if (tn) return sr; - tn = 1; - const r = ot(); - var s = new r.Schema({ - include: [ - It() - ], - explicit: [ - Ks(), - Ws() - ] - }); - return r.Schema.DEFAULT = s, sr = s, sr; -} -var rn; -function Vs() { - if (rn) return Ye; - rn = 1, Object.defineProperty(Ye, "__esModule", { value: !0 }); - const r = Qe(), s = it(), n = yt(), o = Ts(), p = It(), i = Zn(); - var u = Object.prototype.hasOwnProperty, a = 1, c = 2, l = 3, f = 4, d = 1, E = 2, y = 3, S = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, T = /[\x85\u2028\u2029]/, v = /[,\[\]\{\}]/, h = /^(?:!|!!|![a-z\-]+!)$/i, b = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i; - function w(e) { - return e === 10 || e === 13; - } - function _(e) { - return e === 9 || e === 32; - } - function O(e) { - return e === 9 || e === 32 || e === 10 || e === 13; - } - function P(e) { - return e === 44 || e === 91 || e === 93 || e === 123 || e === 125; - } - function L(e) { - var t; - return 48 <= e && e <= 57 ? e - 48 : (t = e | 32, 97 <= t && t <= 102 ? t - 97 + 10 : -1); - } - function Y(e) { - return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0; - } - function H(e) { - return 48 <= e && e <= 57 ? e - 48 : -1; - } - function V(e) { - return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? ` -` : e === 118 ? "\v" : e === 102 ? "\f" : e === 114 ? "\r" : e === 101 ? "\x1B" : e === 32 ? " " : e === 34 ? '"' : e === 47 ? "/" : e === 92 ? "\\" : e === 78 ? "…" : e === 95 ? " " : e === 76 ? "\u2028" : e === 80 ? "\u2029" : ""; - } - function B(e) { - return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode((e - 65536 >> 10) + 55296, (e - 65536 & 1023) + 56320); - } - for (var ne = new Array(256), I = new Array(256), Z = new Array(256), te = new Array(256), he = 0; he < 256; he++) - te[he] = I[he] = V(he), ne[he] = I[he] ? 1 : 0, Z[he] = 1, ne[he] || (te[he] = "\\" + String.fromCharCode(he)); - class le { - constructor(t, x) { - this.errorMap = {}, this.errors = [], this.lines = [], this.input = t, this.filename = x.filename || null, this.schema = x.schema || i, this.onWarning = x.onWarning || null, this.legacy = x.legacy || !1, this.allowAnyEscape = x.allowAnyEscape || !1, this.ignoreDuplicateKeys = x.ignoreDuplicateKeys || !1, 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.documents = []; - } - } - function ve(e, t, x = !1) { - return new n(t, new o(e.filename, e.input, e.position, e.line, e.position - e.lineStart), x); - } - function oe(e, t, x, C = !1, M = !1) { - var g = G(e, t); - if (g) { - var k = x + t; - if (!e.errorMap[k]) { - var $ = new o(e.filename, e.input, t, g.line, t - g.start); - M && ($.toLineEnd = !0); - var D = new n(x, $, C); - e.errors.push(D); - } - } - } - function fe(e, t) { - var x = ve(e, t), C = x.message + x.mark.position; - if (!e.errorMap[C]) { - e.errors.push(x), e.errorMap[C] = 1; - for (var M = e.position; ; ) { - if (e.position >= e.input.length - 1) - return; - var g = e.input.charAt(e.position); - if (g == ` -`) { - e.position--, e.position == M && (e.position += 1); - return; - } - if (g == "\r") { - e.position--, e.position == M && (e.position += 1); - return; - } - e.position++; - } - } - } - function j(e, t) { - var x = ve(e, t); - e.onWarning && e.onWarning.call(null, x); - } - var ie = { - YAML: function(t, x, C) { - var M, g, k; - t.version !== null && fe(t, "duplication of %YAML directive"), C.length !== 1 && fe(t, "YAML directive accepts exactly one argument"), M = /^([0-9]+)\.([0-9]+)$/.exec(C[0]), M === null && fe(t, "ill-formed argument of the YAML directive"), g = parseInt(M[1], 10), k = parseInt(M[2], 10), g !== 1 && fe(t, "found incompatible YAML document (version 1.2 is required)"), t.version = C[0], t.checkLineBreaks = k < 2, k !== 2 && fe(t, "found incompatible YAML document (version 1.2 is required)"); - }, - TAG: function(t, x, C) { - var M, g; - C.length !== 2 && fe(t, "TAG directive accepts exactly two arguments"), M = C[0], g = C[1], h.test(M) || fe(t, "ill-formed tag handle (first argument) of the TAG directive"), u.call(t.tagMap, M) && fe(t, 'there is a previously declared suffix for "' + M + '" tag handle'), b.test(g) || fe(t, "ill-formed tag prefix (second argument) of the TAG directive"), t.tagMap[M] = g; - } - }; - function pe(e, t, x, C) { - var M, g, k, $, D = e.result; - if (D.startPosition == -1 && (D.startPosition = t), t <= x) { - if ($ = e.input.slice(t, x), C) - for (M = 0, g = $.length; M < g; M += 1) - k = $.charCodeAt(M), k === 9 || 32 <= k && k <= 1114111 || fe(e, "expected valid JSON character"); - else S.test($) && fe(e, "the stream contains non-printable characters"); - D.value += $, D.endPosition = x; - } - } - function se(e, t, x, C, M) { - if (C != null) { - t === null && (t = { - startPosition: C.startPosition, - endPosition: M.endPosition, - parent: null, - errors: [], - mappings: [], - kind: r.Kind.MAP - }); - var g = r.newMapping(C, M); - return g.parent = t, C.parent = g, M != null && (M.parent = g), !e.ignoreDuplicateKeys && t.mappings.forEach((k) => { - r.isNodesEqual(k, g) && (oe(e, g.key.startPosition, "duplicate key"), oe(e, k.key.startPosition, "duplicate key")); - }), t.mappings.push(g), t.endPosition = M ? M.endPosition : C.endPosition + 1, t; - } - } - function W(e) { - var t; - t = e.input.charCodeAt(e.position), t === 10 ? e.position++ : t === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : fe(e, "a line break is expected"), e.line += 1, e.lineStart = e.position, e.lines.push({ - start: e.lineStart, - line: e.line - }); - } - function G(e, t) { - for (var x, C = 0; C < e.lines.length && !(e.lines[C].start > t); C++) - x = e.lines[C]; - return x || { - start: 0, - line: 0 - }; - } - function ae(e, t, x) { - for (var C = 0, M = e.input.charCodeAt(e.position); M !== 0; ) { - for (; _(M); ) - M === 9 && e.errors.push(ve(e, "Using tabs can lead to unpredictable results", !0)), M = e.input.charCodeAt(++e.position); - if (t && M === 35) - do - M = e.input.charCodeAt(++e.position); - while (M !== 10 && M !== 13 && M !== 0); - if (w(M)) - for (W(e), M = e.input.charCodeAt(e.position), C++, e.lineIndent = 0; M === 32; ) - e.lineIndent++, M = e.input.charCodeAt(++e.position); - else - break; - } - return x !== -1 && C !== 0 && e.lineIndent < x && j(e, "deficient indentation"), C; - } - function ge(e) { - var t = e.position, x; - return x = e.input.charCodeAt(t), !!((x === 45 || x === 46) && e.input.charCodeAt(t + 1) === x && e.input.charCodeAt(t + 2) === x && (t += 3, x = e.input.charCodeAt(t), x === 0 || O(x))); - } - function Ee(e, t, x) { - x === 1 ? t.value += " " : x > 1 && (t.value += s.repeat(` -`, x - 1)); - } - function ye(e, t, x) { - var C, M, g, k, $, D, X, J, ee = e.kind, re = e.result, ue, me = r.newScalar(); - if (me.plainScalar = !0, e.result = me, ue = e.input.charCodeAt(e.position), O(ue) || P(ue) || ue === 35 || ue === 38 || ue === 42 || ue === 33 || ue === 124 || ue === 62 || ue === 39 || ue === 34 || ue === 37 || ue === 64 || ue === 96) - return e.result.startPosition = e.position - 1, e.result.endPosition = e.position - 1, !1; - if ((ue === 63 || ue === 45) && (M = e.input.charCodeAt(e.position + 1), O(M) || x && P(M))) - return !1; - for (e.kind = "scalar", g = k = e.position, $ = !1; ue !== 0; ) { - if (ue === 58) { - if (M = e.input.charCodeAt(e.position + 1), O(M) || x && P(M)) - break; - } else if (ue === 35) { - if (C = e.input.charCodeAt(e.position - 1), O(C)) - break; - } else { - if (e.position === e.lineStart && ge(e) || x && P(ue)) - break; - if (w(ue)) - if (D = e.line, X = e.lineStart, J = e.lineIndent, ae(e, !1, -1), e.lineIndent >= t) { - $ = !0, ue = e.input.charCodeAt(e.position); - continue; - } else { - e.position = k, e.line = D, e.lineStart = X, e.lineIndent = J; - break; - } - } - if ($ && (pe(e, g, k, !1), Ee(e, me, e.line - D), g = k = e.position, $ = !1), _(ue) || (k = e.position + 1), ue = e.input.charCodeAt(++e.position), e.position >= e.input.length) - return !1; - } - return pe(e, g, k, !1), e.result.startPosition != -1 ? (me.rawValue = e.input.substring(me.startPosition, me.endPosition), !0) : (e.kind = ee, e.result = re, !1); - } - function Oe(e, t) { - var x, C, M; - if (x = e.input.charCodeAt(e.position), x !== 39) - return !1; - var g = r.newScalar(); - for (g.singleQuoted = !0, e.kind = "scalar", e.result = g, g.startPosition = e.position, e.position++, C = M = e.position; (x = e.input.charCodeAt(e.position)) !== 0; ) - if (x === 39) - if (pe(e, C, e.position, !0), x = e.input.charCodeAt(++e.position), g.endPosition = e.position, x === 39) - C = M = e.position, e.position++; - else - return !0; - else w(x) ? (pe(e, C, M, !0), Ee(e, g, ae(e, !1, t)), C = M = e.position) : e.position === e.lineStart && ge(e) ? fe(e, "unexpected end of the document within a single quoted scalar") : (e.position++, M = e.position, g.endPosition = e.position); - fe(e, "unexpected end of the stream within a single quoted scalar"); - } - function Ae(e, t) { - var x, C, M, g, k, $; - if ($ = e.input.charCodeAt(e.position), $ !== 34) - return !1; - e.kind = "scalar"; - var D = r.newScalar(); - for (D.doubleQuoted = !0, e.result = D, D.startPosition = e.position, e.position++, x = C = e.position; ($ = e.input.charCodeAt(e.position)) !== 0; ) { - if ($ === 34) - return pe(e, x, e.position, !0), e.position++, D.endPosition = e.position, D.rawValue = e.input.substring(D.startPosition, D.endPosition), !0; - if ($ === 92) { - if (pe(e, x, e.position, !0), $ = e.input.charCodeAt(++e.position), w($)) - ae(e, !1, t); - else if ($ < 256 && (e.allowAnyEscape ? Z[$] : ne[$])) - D.value += e.allowAnyEscape ? te[$] : I[$], e.position++; - else if ((k = Y($)) > 0) { - for (M = k, g = 0; M > 0; M--) - $ = e.input.charCodeAt(++e.position), (k = L($)) >= 0 ? g = (g << 4) + k : fe(e, "expected hexadecimal character"); - D.value += B(g), e.position++; - } else - fe(e, "unknown escape sequence"); - x = C = e.position; - } else w($) ? (pe(e, x, C, !0), Ee(e, D, ae(e, !1, t)), x = C = e.position) : e.position === e.lineStart && ge(e) ? fe(e, "unexpected end of the document within a double quoted scalar") : (e.position++, C = e.position); - } - fe(e, "unexpected end of the stream within a double quoted scalar"); - } - function Te(e, t) { - var x = !0, C, M = e.tag, g, k = e.anchor, $, D, X, J, ee, re, ue, me, we; - if (we = e.input.charCodeAt(e.position), we === 91) - D = 93, ee = !1, g = r.newItems(), g.startPosition = e.position; - else if (we === 123) - D = 125, ee = !0, g = r.newMap(), g.startPosition = e.position; - else - return !1; - for (e.anchor !== null && (g.anchorId = e.anchor, e.anchorMap[e.anchor] = g), we = e.input.charCodeAt(++e.position); we !== 0; ) { - if (ae(e, !0, t), we = e.input.charCodeAt(e.position), we === D) - return e.position++, e.tag = M, e.anchor = k, e.kind = ee ? "mapping" : "sequence", e.result = g, g.endPosition = e.position, !0; - if (!x) { - var xe = e.position; - fe(e, "missed comma between flow collection entries"), e.position = xe + 1; - } - if (ue = re = me = null, X = J = !1, we === 63 && ($ = e.input.charCodeAt(e.position + 1), O($) && (X = J = !0, e.position++, ae(e, !0, t))), C = e.line, A(e, t, a, !1, !0), ue = e.tag, re = e.result, ae(e, !0, t), we = e.input.charCodeAt(e.position), (J || e.line === C) && we === 58 && (X = !0, we = e.input.charCodeAt(++e.position), ae(e, !0, t), A(e, t, a, !1, !0), me = e.result), ee) - se(e, g, ue, re, me); - else if (X) { - var _e = se(e, null, ue, re, me); - _e.parent = g, g.items.push(_e); - } else - re && (re.parent = g), g.items.push(re); - g.endPosition = e.position + 1, ae(e, !0, t), we = e.input.charCodeAt(e.position), we === 44 ? (x = !0, we = e.input.charCodeAt(++e.position)) : x = !1; - } - fe(e, "unexpected end of the stream within a flow collection"); - } - function U(e, t) { - var x, C, M = d, g = !1, k = t, $ = 0, D = !1, X, J; - if (J = e.input.charCodeAt(e.position), J === 124) - C = !1; - else if (J === 62) - C = !0; - else - return !1; - var ee = r.newScalar(); - for (e.kind = "scalar", e.result = ee, ee.startPosition = e.position; J !== 0; ) - if (J = e.input.charCodeAt(++e.position), J === 43 || J === 45) - d === M ? M = J === 43 ? y : E : fe(e, "repeat of a chomping mode identifier"); - else if ((X = H(J)) >= 0) - X === 0 ? fe(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : g ? fe(e, "repeat of an indentation width identifier") : (k = t + X - 1, g = !0); - else - break; - if (_(J)) { - do - J = e.input.charCodeAt(++e.position); - while (_(J)); - if (J === 35) - do - J = e.input.charCodeAt(++e.position); - while (!w(J) && J !== 0); - } - for (; J !== 0; ) { - for (W(e), e.lineIndent = 0, J = e.input.charCodeAt(e.position); (!g || e.lineIndent < k) && J === 32; ) - e.lineIndent++, J = e.input.charCodeAt(++e.position); - if (!g && e.lineIndent > k && (k = e.lineIndent), w(J)) { - $++; - continue; - } - if (e.lineIndent < k) { - M === y ? ee.value += s.repeat(` -`, $) : M === d && g && (ee.value += ` -`); - break; - } - for (C ? _(J) ? (D = !0, ee.value += s.repeat(` -`, $ + 1)) : D ? (D = !1, ee.value += s.repeat(` -`, $ + 1)) : $ === 0 ? g && (ee.value += " ") : ee.value += s.repeat(` -`, $) : g && (ee.value += s.repeat(` -`, $ + 1)), g = !0, $ = 0, x = e.position; !w(J) && J !== 0; ) - J = e.input.charCodeAt(++e.position); - pe(e, x, e.position, !1); - } - ee.endPosition = e.position; - for (var re = e.position - 1; ; ) { - var ue = e.input[re]; - if (ue == "\r" || ue == ` -` || ue != " " && ue != " ") - break; - re--; - } - return ee.endPosition = re, ee.rawValue = e.input.substring(ee.startPosition, ee.endPosition), !0; - } - function q(e, t) { - var x, C = e.tag, M = e.anchor, g = r.newItems(), k, $ = !1, D; - for (e.anchor !== null && (g.anchorId = e.anchor, e.anchorMap[e.anchor] = g), g.startPosition = e.position, D = e.input.charCodeAt(e.position); D !== 0 && !(D !== 45 || (k = e.input.charCodeAt(e.position + 1), !O(k))); ) { - if ($ = !0, e.position++, ae(e, !0, -1) && e.lineIndent <= t) { - g.items.push(null), D = e.input.charCodeAt(e.position); - continue; - } - if (x = e.line, A(e, t, l, !1, !0), e.result && (e.result.parent = g, g.items.push(e.result)), ae(e, !0, -1), D = e.input.charCodeAt(e.position), (e.line === x || e.lineIndent > t) && D !== 0) - fe(e, "bad indentation of a sequence entry"); - else if (e.lineIndent < t) - break; - } - return g.endPosition = e.position, $ ? (e.tag = C, e.anchor = M, e.kind = "sequence", e.result = g, g.endPosition = e.position, !0) : !1; - } - function de(e, t, x) { - var C, M, g, k = e.tag, $ = e.anchor, D = r.newMap(), X = null, J = null, ee = null, re = !1, ue = !1, me; - for (D.startPosition = e.position, e.anchor !== null && (D.anchorId = e.anchor, e.anchorMap[e.anchor] = D), me = e.input.charCodeAt(e.position); me !== 0; ) { - if (C = e.input.charCodeAt(e.position + 1), g = e.line, (me === 63 || me === 58) && O(C)) - me === 63 ? (re && (se(e, D, X, J, null), X = J = ee = null), ue = !0, re = !0, M = !0) : re ? (re = !1, M = !0) : fe(e, "incomplete explicit mapping pair; a key node is missed"), e.position += 1, me = C; - else if (A(e, x, c, !1, !0)) - if (e.line === g) { - for (me = e.input.charCodeAt(e.position); _(me); ) - me = e.input.charCodeAt(++e.position); - if (me === 58) - me = e.input.charCodeAt(++e.position), O(me) || fe(e, "a whitespace character is expected after the key-value separator within a block mapping"), re && (se(e, D, X, J, null), X = J = ee = null), ue = !0, re = !1, M = !1, X = e.tag, J = e.result; - else { - if (e.position == e.lineStart && ge(e)) - break; - if (ue) - fe(e, "can not read an implicit mapping pair; a colon is missed"); - else - return e.tag = k, e.anchor = $, !0; - } - } else if (ue) { - for (fe(e, "can not read a block mapping entry; a multiline key may not be an implicit key"); e.position > 0; ) - if (me = e.input.charCodeAt(--e.position), w(me)) { - e.position++; - break; - } - } else - return e.tag = k, e.anchor = $, !0; - else - break; - if ((e.line === g || e.lineIndent > t) && (A(e, t, f, !0, M) && (re ? J = e.result : ee = e.result), re || (se(e, D, X, J, ee), X = J = ee = null), ae(e, !0, -1), me = e.input.charCodeAt(e.position)), e.lineIndent > t && me !== 0) - fe(e, "bad indentation of a mapping entry"); - else if (e.lineIndent < t) - break; - } - return re && se(e, D, X, J, null), ue && (e.tag = k, e.anchor = $, e.kind = "mapping", e.result = D), ue; - } - function F(e) { - var t, x = !1, C = !1, M, g, k; - if (k = e.input.charCodeAt(e.position), k !== 33) - return !1; - if (e.tag !== null && fe(e, "duplication of a tag property"), k = e.input.charCodeAt(++e.position), k === 60 ? (x = !0, k = e.input.charCodeAt(++e.position)) : k === 33 ? (C = !0, M = "!!", k = e.input.charCodeAt(++e.position)) : M = "!", t = e.position, x) { - do - k = e.input.charCodeAt(++e.position); - while (k !== 0 && k !== 62); - e.position < e.length ? (g = e.input.slice(t, e.position), k = e.input.charCodeAt(++e.position)) : fe(e, "unexpected end of the stream within a verbatim tag"); - } else { - for (; k !== 0 && !O(k); ) - k === 33 && (C ? fe(e, "tag suffix cannot contain exclamation marks") : (M = e.input.slice(t - 1, e.position + 1), h.test(M) || fe(e, "named tag handle cannot contain such characters"), C = !0, t = e.position + 1)), k = e.input.charCodeAt(++e.position); - g = e.input.slice(t, e.position), v.test(g) && fe(e, "tag suffix cannot contain flow indicator characters"); - } - return g && !b.test(g) && fe(e, "tag name cannot contain such characters: " + g), x ? e.tag = g : u.call(e.tagMap, M) ? e.tag = e.tagMap[M] + g : M === "!" ? e.tag = "!" + g : M === "!!" ? e.tag = "tag:yaml.org,2002:" + g : fe(e, 'undeclared tag handle "' + M + '"'), !0; - } - function ce(e) { - var t, x; - if (x = e.input.charCodeAt(e.position), x !== 38) - return !1; - for (e.anchor !== null && fe(e, "duplication of an anchor property"), x = e.input.charCodeAt(++e.position), t = e.position; x !== 0 && !O(x) && !P(x); ) - x = e.input.charCodeAt(++e.position); - return e.position === t && fe(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(t, e.position), !0; - } - function m(e) { - var t, x; - e.length, e.input; - var C; - if (C = e.input.charCodeAt(e.position), C !== 42) - return !1; - for (C = e.input.charCodeAt(++e.position), t = e.position; C !== 0 && !O(C) && !P(C); ) - C = e.input.charCodeAt(++e.position); - return e.position <= t && (fe(e, "name of an alias node must contain at least one character"), e.position = t + 1), x = e.input.slice(t, e.position), e.anchorMap.hasOwnProperty(x) || (fe(e, 'unidentified alias "' + x + '"'), e.position <= t && (e.position = t + 1)), e.result = r.newAnchorRef(x, t, e.position, e.anchorMap[x]), ae(e, !0, -1), !0; - } - function A(e, t, x, C, M) { - var g, k, $, D = 1, X = !1, J = !1, ee, re, ue, me, we; - e.tag = null, e.anchor = null, e.kind = null, e.result = null, g = k = $ = f === x || l === x, C && ae(e, !0, -1) && (X = !0, e.lineIndent > t ? D = 1 : e.lineIndent === t ? D = 0 : e.lineIndent < t && (D = -1)); - let xe = e.position; - if (e.position - e.lineStart, D === 1) - for (; F(e) || ce(e); ) - ae(e, !0, -1) ? (X = !0, $ = g, e.lineIndent > t ? D = 1 : e.lineIndent === t ? D = 0 : e.lineIndent < t && (D = -1)) : $ = !1; - if ($ && ($ = X || M), (D === 1 || f === x) && (a === x || c === x ? me = t : me = t + 1, we = e.position - e.lineStart, D === 1 ? $ && (q(e, we) || de(e, we, me)) || Te(e, me) ? J = !0 : (k && U(e, me) || Oe(e, me) || Ae(e, me) ? J = !0 : m(e) ? (J = !0, (e.tag !== null || e.anchor !== null) && fe(e, "alias node should not have any properties")) : ye(e, me, a === x) && (J = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result, e.result.anchorId = e.anchor)) : D === 0 && (J = $ && q(e, we))), e.tag !== null && e.tag !== "!") - if (e.tag == "!include") - e.result || (e.result = r.newScalar(), e.result.startPosition = e.position, e.result.endPosition = e.position, fe(e, "!include without value")), e.result.kind = r.Kind.INCLUDE_REF; - else if (e.tag === "?") - for (ee = 0, re = e.implicitTypes.length; ee < re; ee += 1) { - ue = e.implicitTypes[ee]; - var _e = e.result.value; - if (ue.resolve(_e)) { - e.result.valueObject = ue.construct(e.result.value), e.tag = ue.tag, e.anchor !== null && (e.result.anchorId = e.anchor, e.anchorMap[e.anchor] = e.result); - break; - } - } - else u.call(e.typeMap, e.tag) ? (ue = e.typeMap[e.tag], e.result !== null && ue.kind !== e.kind && (!ue.additionalKinds || ue.additionalKinds && ue.additionalKinds.indexOf(e.kind) === -1) && fe(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + ue.kind + '", not "' + e.kind + '"'), ue.resolve(e.result) ? (e.result = ue.construct(e.result), e.anchor !== null && (e.result.anchorId = e.anchor, e.anchorMap[e.anchor] = e.result)) : fe(e, "cannot resolve a node with !<" + e.tag + "> explicit tag")) : oe(e, xe, "unknown tag <" + e.tag + ">", !1, !0); - return e.tag !== null || e.anchor !== null || J; - } - function R(e) { - var t = e.position, x, C, M, g = !1, k; - for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = {}, e.anchorMap = {}; (k = e.input.charCodeAt(e.position)) !== 0 && (ae(e, !0, -1), k = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || k !== 37)); ) { - for (g = !0, k = e.input.charCodeAt(++e.position), x = e.position; k !== 0 && !O(k); ) - k = e.input.charCodeAt(++e.position); - for (C = e.input.slice(x, e.position), M = [], C.length < 1 && fe(e, "directive name must not be less than one character in length"); k !== 0; ) { - for (; _(k); ) - k = e.input.charCodeAt(++e.position); - if (k === 35) { - do - k = e.input.charCodeAt(++e.position); - while (k !== 0 && !w(k)); - break; - } - if (w(k)) - break; - for (x = e.position; k !== 0 && !O(k); ) - k = e.input.charCodeAt(++e.position); - M.push(e.input.slice(x, e.position)); - } - k !== 0 && W(e), u.call(ie, C) ? ie[C](e, C, M) : (j(e, 'unknown document directive "' + C + '"'), e.position++); - } - if (ae(e, !0, -1), e.lineIndent === 0 && e.input.charCodeAt(e.position) === 45 && e.input.charCodeAt(e.position + 1) === 45 && e.input.charCodeAt(e.position + 2) === 45 ? (e.position += 3, ae(e, !0, -1)) : g && fe(e, "directives end mark is expected"), A(e, e.lineIndent - 1, f, !1, !0), ae(e, !0, -1), e.checkLineBreaks && T.test(e.input.slice(t, e.position)) && j(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && ge(e)) { - e.input.charCodeAt(e.position) === 46 && (e.position += 3, ae(e, !0, -1)); - return; - } - if (e.position < e.length - 1) - fe(e, "end of the stream or a document separator is expected"); - else - return; - } - function K(e, t) { - e = String(e), t = t || {}; - let x = e.length; - x !== 0 && (e.charCodeAt(x - 1) !== 10 && e.charCodeAt(x - 1) !== 13 && (e += ` -`), e.charCodeAt(0) === 65279 && (e = e.slice(1))); - var C = new le(e, t); - for (C.input += "\0"; C.input.charCodeAt(C.position) === 32; ) - C.lineIndent += 1, C.position += 1; - for (; C.position < C.length - 1; ) { - var M = C.position; - if (R(C), C.position <= M) - for (; C.position < C.length - 1; C.position++) { - var g = C.input.charAt(C.position); - if (g == ` -`) - break; - } - } - let k = C.documents, $ = k.length; - $ > 0 && (k[$ - 1].endPosition = x); - for (let D of k) - D.errors = C.errors, D.startPosition > D.endPosition && (D.startPosition = D.endPosition); - return k; - } - function Q(e, t, x = {}) { - var C = K(e, x), M, g; - for (M = 0, g = C.length; M < g; M += 1) - t(C[M]); - } - Ye.loadAll = Q; - function z(e, t = {}) { - var x = K(e, t); - if (x.length !== 0) { - if (x.length === 1) - return x[0]; - var C = new n("expected a single document in the stream, but found more"); - return C.mark = new o("", "", 0, 0, 0), C.mark.position = x[0].endPosition, x[0].errors.push(C), x[0]; - } - } - Ye.load = z; - function be(e, t, x = {}) { - Q(e, t, s.extend({ schema: p }, x)); - } - Ye.safeLoadAll = be; - function N(e, t = {}) { - return z(e, s.extend({ schema: p }, t)); - } - return Ye.safeLoad = N, Ye.loadAll = Q, Ye.load = z, Ye.safeLoadAll = be, Ye.safeLoad = N, Ye; -} -var ft = {}, nn; -function Js() { - if (nn) return ft; - nn = 1, Object.defineProperty(ft, "__esModule", { value: !0 }); - var r = it(), s = yt(), n = Zn(), o = It(), p = Object.prototype.toString, i = Object.prototype.hasOwnProperty, u = 9, a = 10, c = 13, l = 32, f = 33, d = 34, E = 35, y = 37, S = 38, T = 39, v = 42, h = 44, b = 45, w = 58, _ = 62, O = 63, P = 64, L = 91, Y = 93, H = 96, V = 123, B = 124, ne = 125, I = {}; - I[0] = "\\0", I[7] = "\\a", I[8] = "\\b", I[9] = "\\t", I[10] = "\\n", I[11] = "\\v", I[12] = "\\f", I[13] = "\\r", I[27] = "\\e", I[34] = '\\"', I[92] = "\\\\", I[133] = "\\N", I[160] = "\\_", I[8232] = "\\L", I[8233] = "\\P"; - var Z = [ - "y", - "Y", - "yes", - "Yes", - "YES", - "on", - "On", - "ON", - "n", - "N", - "no", - "No", - "NO", - "off", - "Off", - "OFF" - ]; - function te(F, ce) { - var m, A, R, K, Q, z, be; - if (ce === null) - return {}; - for (m = {}, A = Object.keys(ce), R = 0, K = A.length; R < K; R += 1) - Q = A[R], z = String(ce[Q]), Q.slice(0, 2) === "!!" && (Q = "tag:yaml.org,2002:" + Q.slice(2)), be = F.compiledTypeMap[Q], be && i.call(be.styleAliases, z) && (z = be.styleAliases[z]), m[Q] = z; - return m; - } - function he(F) { - var ce, m, A; - if (ce = F.toString(16).toUpperCase(), F <= 255) - m = "x", A = 2; - else if (F <= 65535) - m = "u", A = 4; - else if (F <= 4294967295) - m = "U", A = 8; - else - throw new s("code point within a string may not be greater than 0xFFFFFFFF"); - return "\\" + m + r.repeat("0", A - ce.length) + ce; - } - function le(F) { - this.schema = F.schema || n, this.indent = Math.max(1, F.indent || 2), this.skipInvalid = F.skipInvalid || !1, this.flowLevel = r.isNothing(F.flowLevel) ? -1 : F.flowLevel, this.styleMap = te(this.schema, F.styles || null), this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null; - } - function ve(F, ce) { - for (var m = r.repeat(" ", ce), A = 0, R = -1, K = "", Q, z = F.length; A < z; ) - R = F.indexOf(` -`, A), R === -1 ? (Q = F.slice(A), A = z) : (Q = F.slice(A, R + 1), A = R + 1), Q.length && Q !== ` -` && (K += m), K += Q; - return K; - } - function oe(F, ce) { - return ` -` + r.repeat(" ", F.indent * ce); - } - function fe(F, ce) { - var m, A, R; - for (m = 0, A = F.implicitTypes.length; m < A; m += 1) - if (R = F.implicitTypes[m], R.resolve(ce)) - return !0; - return !1; - } - function j(F) { - this.source = F, this.result = "", this.checkpoint = 0; - } - j.prototype.takeUpTo = function(F) { - var ce; - if (F < this.checkpoint) - throw ce = new Error("position should be > checkpoint"), ce.position = F, ce.checkpoint = this.checkpoint, ce; - return this.result += this.source.slice(this.checkpoint, F), this.checkpoint = F, this; - }, j.prototype.escapeChar = function() { - var F, ce; - return F = this.source.charCodeAt(this.checkpoint), ce = I[F] || he(F), this.result += ce, this.checkpoint += 1, this; - }, j.prototype.finish = function() { - this.source.length > this.checkpoint && this.takeUpTo(this.source.length); - }; - function ie(F, ce, m) { - var A, R, K, Q, z, be, N, e, t, x, C, M, g, k, $, D, X, J, ee, re, ue; - if (ce.length === 0) { - F.dump = "''"; - return; - } - if (ce.indexOf("!include") == 0) { - F.dump = "" + ce; - return; - } - if (ce.indexOf("!$$$novalue") == 0) { - F.dump = ""; - return; - } - if (Z.indexOf(ce) !== -1) { - F.dump = "'" + ce + "'"; - return; - } - for (A = !0, R = ce.length ? ce.charCodeAt(0) : 0, K = l === R || l === ce.charCodeAt(ce.length - 1), (b === R || O === R || P === R || H === R) && (A = !1), K ? (A = !1, Q = !1, z = !1) : (Q = !0, z = !0), be = !0, N = new j(ce), e = !1, t = 0, x = 0, C = F.indent * m, M = 80, C < 40 ? M -= C : M = 40, k = 0; k < ce.length; k++) { - if (g = ce.charCodeAt(k), A) - if (!W(g)) - A = !1; - else - continue; - be && g === T && (be = !1), $ = I[g], D = G(g), !(!$ && !D) && (g !== a && g !== d && g !== T ? (Q = !1, z = !1) : g === a && (e = !0, be = !1, k > 0 && (X = ce.charCodeAt(k - 1), X === l && (z = !1, Q = !1)), Q && (J = k - t, t = k, J > x && (x = J))), g !== d && (be = !1), N.takeUpTo(k), N.escapeChar()); - } - if (A && fe(F, ce) && (A = !1), ee = "", (Q || z) && (re = 0, ce.charCodeAt(ce.length - 1) === a && (re += 1, ce.charCodeAt(ce.length - 2) === a && (re += 1)), re === 0 ? ee = "-" : re === 2 && (ee = "+")), z && x < M && (Q = !1), e || (z = !1), A) - F.dump = ce; - else if (be) - F.dump = "'" + ce + "'"; - else if (Q) - ue = pe(ce, M), F.dump = ">" + ee + ` -` + ve(ue, C); - else if (z) - ee || (ce = ce.replace(/\n$/, "")), F.dump = "|" + ee + ` -` + ve(ce, C); - else if (N) - N.finish(), F.dump = '"' + N.result + '"'; - else - throw new Error("Failed to dump scalar value"); - } - function pe(F, ce) { - var m = "", A = 0, R = F.length, K = /\n+$/.exec(F), Q; - for (K && (R = K.index + 1); A < R; ) - Q = F.indexOf(` -`, A), Q > R || Q === -1 ? (m && (m += ` - -`), m += se(F.slice(A, R), ce), A = R) : (m && (m += ` - -`), m += se(F.slice(A, Q), ce), A = Q + 1); - return K && K[0] !== ` -` && (m += K[0]), m; - } - function se(F, ce) { - if (F === "") - return F; - for (var m = /[^\s] [^\s]/g, A = "", R = 0, K = 0, Q = m.exec(F), z, be, N; Q; ) - z = Q.index, z - K > ce && (R !== K ? be = R : be = z, A && (A += ` -`), N = F.slice(K, be), A += N, K = be + 1), R = z + 1, Q = m.exec(F); - return A && (A += ` -`), K !== R && F.length - K > ce ? A += F.slice(K, R) + ` -` + F.slice(R + 1) : A += F.slice(K), A; - } - function W(F) { - return u !== F && a !== F && c !== F && h !== F && L !== F && Y !== F && V !== F && ne !== F && E !== F && S !== F && v !== F && f !== F && B !== F && _ !== F && T !== F && d !== F && y !== F && w !== F && !I[F] && !G(F); - } - function G(F) { - return !(32 <= F && F <= 126 || F === 133 || 160 <= F && F <= 55295 || 57344 <= F && F <= 65533 || 65536 <= F && F <= 1114111); - } - function ae(F, ce, m) { - var A = "", R = F.tag, K, Q; - for (K = 0, Q = m.length; K < Q; K += 1) - Ae(F, ce, m[K], !1, !1) && (K !== 0 && (A += ", "), A += F.dump); - F.tag = R, F.dump = "[" + A + "]"; - } - function ge(F, ce, m, A) { - var R = "", K = F.tag, Q, z; - for (Q = 0, z = m.length; Q < z; Q += 1) - Ae(F, ce + 1, m[Q], !0, !0) && ((!A || Q !== 0) && (R += oe(F, ce)), R += "- " + F.dump); - F.tag = K, F.dump = R || "[]"; - } - function Ee(F, ce, m) { - var A = "", R = F.tag, K = Object.keys(m), Q, z, be, N, e; - for (Q = 0, z = K.length; Q < z; Q += 1) - e = "", Q !== 0 && (e += ", "), be = K[Q], N = m[be], Ae(F, ce, be, !1, !1) && (F.dump.length > 1024 && (e += "? "), e += F.dump + ": ", Ae(F, ce, N, !1, !1) && (e += F.dump, A += e)); - F.tag = R, F.dump = "{" + A + "}"; - } - function ye(F, ce, m, A) { - var R = "", K = F.tag, Q = Object.keys(m), z, be, N, e, t, x; - for (z = 0, be = Q.length; z < be; z += 1) - x = "", (!A || z !== 0) && (x += oe(F, ce)), N = Q[z], e = m[N], Ae(F, ce + 1, N, !0, !0) && (t = F.tag !== null && F.tag !== "?" || F.dump && F.dump.length > 1024, t && (F.dump && a === F.dump.charCodeAt(0) ? x += "?" : x += "? "), x += F.dump, t && (x += oe(F, ce)), Ae(F, ce + 1, e, !0, t) && (F.dump && a === F.dump.charCodeAt(0) ? x += ":" : x += ": ", x += F.dump, R += x)); - F.tag = K, F.dump = R || "{}"; - } - function Oe(F, ce, m) { - var A, R, K, Q, z, be; - for (R = m ? F.explicitTypes : F.implicitTypes, K = 0, Q = R.length; K < Q; K += 1) - if (z = R[K], (z.instanceOf || z.predicate) && (!z.instanceOf || typeof ce == "object" && ce instanceof z.instanceOf) && (!z.predicate || z.predicate(ce))) { - if (F.tag = m ? z.tag : "?", z.represent) { - if (be = F.styleMap[z.tag] || z.defaultStyle, p.call(z.represent) === "[object Function]") - A = z.represent(ce, be); - else if (i.call(z.represent, be)) - A = z.represent[be](ce, be); - else - throw new s("!<" + z.tag + '> tag resolver accepts not "' + be + '" style'); - F.dump = A; - } - return !0; - } - return !1; - } - function Ae(F, ce, m, A, R) { - F.tag = null, F.dump = m, Oe(F, m, !1) || Oe(F, m, !0); - var K = p.call(F.dump); - A && (A = 0 > F.flowLevel || F.flowLevel > ce), (F.tag !== null && F.tag !== "?" || F.indent !== 2 && ce > 0) && (R = !1); - var Q = K === "[object Object]" || K === "[object Array]", z, be; - if (Q && (z = F.duplicates.indexOf(m), be = z !== -1), be && F.usedDuplicates[z]) - F.dump = "*ref_" + z; - else { - if (Q && be && !F.usedDuplicates[z] && (F.usedDuplicates[z] = !0), K === "[object Object]") - A && Object.keys(F.dump).length !== 0 ? (ye(F, ce, F.dump, R), be && (F.dump = "&ref_" + z + (ce === 0 ? ` -` : "") + F.dump)) : (Ee(F, ce, F.dump), be && (F.dump = "&ref_" + z + " " + F.dump)); - else if (K === "[object Array]") - A && F.dump.length !== 0 ? (ge(F, ce, F.dump, R), be && (F.dump = "&ref_" + z + (ce === 0 ? ` -` : "") + F.dump)) : (ae(F, ce, F.dump), be && (F.dump = "&ref_" + z + " " + F.dump)); - else if (K === "[object String]") - F.tag !== "?" && ie(F, F.dump, ce); - else { - if (F.skipInvalid) - return !1; - throw new s("unacceptable kind of an object to dump " + K); - } - F.tag !== null && F.tag !== "?" && (F.dump = "!<" + F.tag + "> " + F.dump); - } - return !0; - } - function Te(F, ce) { - var m = [], A = [], R, K; - for (U(F, m, A), R = 0, K = A.length; R < K; R += 1) - ce.duplicates.push(m[A[R]]); - ce.usedDuplicates = new Array(K); - } - function U(F, ce, m) { - p.call(F); - var A, R, K; - if (F !== null && typeof F == "object") - if (R = ce.indexOf(F), R !== -1) - m.indexOf(R) === -1 && m.push(R); - else if (ce.push(F), Array.isArray(F)) - for (R = 0, K = F.length; R < K; R += 1) - U(F[R], ce, m); - else - for (A = Object.keys(F), R = 0, K = A.length; R < K; R += 1) - U(F[A[R]], ce, m); - } - function q(F, ce) { - ce = ce || {}; - var m = new le(ce); - return Te(F, m), Ae(m, 0, F, !0, !0) ? m.dump + ` -` : ""; - } - ft.dump = q; - function de(F, ce) { - return q(F, r.extend({ schema: o }, ce)); - } - return ft.safeDump = de, ft; -} -var ar = {}, on; -function Gs() { - return on || (on = 1, (function(r) { - Object.defineProperty(r, "__esModule", { value: !0 }); - function s(a) { - if (["true", "True", "TRUE"].lastIndexOf(a) >= 0) - return !0; - if (["false", "False", "FALSE"].lastIndexOf(a) >= 0) - return !1; - throw `Invalid boolean "${a}"`; - } - r.parseYamlBoolean = s; - function n(a) { - return a.lastIndexOf("0o", 0) === 0 ? parseInt(a.substring(2), 8) : parseInt(a); - } - function o(a) { - const c = n(a); - if (isNaN(c)) - throw `Invalid integer "${a}"`; - return c; - } - r.parseYamlInteger = o; - function p(a) { - if ([".nan", ".NaN", ".NAN"].lastIndexOf(a) >= 0) - return NaN; - const l = /^([-+])?(?:\.inf|\.Inf|\.INF)$/.exec(a); - if (l) - return l[1] === "-" ? -1 / 0 : 1 / 0; - const f = parseFloat(a); - if (!isNaN(f)) - return f; - throw `Invalid float "${a}"`; - } - r.parseYamlFloat = p; - var i; - (function(a) { - a[a.null = 0] = "null", a[a.bool = 1] = "bool", a[a.int = 2] = "int", a[a.float = 3] = "float", a[a.string = 4] = "string"; - })(i = r.ScalarType || (r.ScalarType = {})); - function u(a) { - if (a === void 0) - return i.null; - if (a.doubleQuoted || !a.plainScalar || a.singleQuoted) - return i.string; - const c = a.value; - if (["null", "Null", "NULL", "~", ""].indexOf(c) >= 0 || c == null) - return i.null; - if (["true", "True", "TRUE", "false", "False", "FALSE"].indexOf(c) >= 0) - return i.bool; - const l = /^[-+]?[0-9]+$/, f = /^0o[0-7]+$/, d = /^0x[0-9a-fA-F]+$/; - if (l.test(c) || f.test(c) || d.test(c)) - return i.int; - const E = /^[-+]?(\.[0-9]+|[0-9]+(\.[0-9]*)?)([eE][-+]?[0-9]+)?$/, y = /^[-+]?(\.inf|\.Inf|\.INF)$/; - return E.test(c) || y.test(c) || [".nan", ".NaN", ".NAN"].indexOf(c) >= 0 ? i.float : i.string; - } - r.determineScalarType = u; - })(ar)), ar; -} -var sn; -function ei() { - return sn || (sn = 1, (function(r) { - function s(p) { - for (var i in p) r.hasOwnProperty(i) || (r[i] = p[i]); - } - Object.defineProperty(r, "__esModule", { value: !0 }); - var n = Vs(); - r.load = n.load, r.loadAll = n.loadAll, r.safeLoad = n.safeLoad, r.safeLoadAll = n.safeLoadAll; - var o = Js(); - r.dump = o.dump, r.safeDump = o.safeDump, r.YAMLException = yt(), s(Qe()), s(Gs()); - })(Ft)), Ft; -} -var an; -function Qs() { - if (an) return lt; - an = 1, Object.defineProperty(lt, "__esModule", { value: !0 }), lt.visitYaml = void 0; - const r = ei(); - function s(a, c, l, f) { - const d = o(a, l); - if (l == null) { - f.onValue(a, c, l, void 0, d); - return; - } - if (l.kind === r.Kind.MAP) { - f.onObjectStart(a, c, l, d); - for (const E of l.mappings) - s(E, E.key.value, E.value, f); - f.onObjectEnd(); - } else if (l.kind === r.Kind.SEQ) - f.onArrayStart(a, c, l, d), l.items.forEach((E, y) => { - s(l, y, E, f); - }), f.onArrayEnd(); - else if (l.kind === r.Kind.ANCHOR_REF) - s(a, c, l.value, f); - else if (l.kind === r.Kind.MAPPING) - s(a, c, l.value, f); - else if (l.kind === r.Kind.SCALAR) { - const [E, y] = n(l), S = p(E, l.value, y); - f.onValue(a, c, y, S, d); - } - } - lt.visitYaml = s; - function n(a) { - const c = (0, r.determineScalarType)(a); - return c === r.ScalarType.int ? [c, (0, r.parseYamlInteger)(a.value)] : c === r.ScalarType.float ? [c, (0, r.parseYamlFloat)(a.value)] : c === r.ScalarType.bool ? [c, (0, r.parseYamlBoolean)(a.value)] : c == r.ScalarType.null ? [c, null] : [c, a.value]; - } - function o(a, c) { - const l = a && a.kind === r.Kind.MAPPING ? { start: a.key.startPosition, end: a.key.endPosition } : void 0; - return c ? { key: l, value: { start: c.startPosition, end: c.endPosition } } : a && a.kind === r.Kind.MAPPING ? { key: l, value: { start: a.key.endPosition, end: a.key.endPosition } } : { key: l, value: { start: 0, end: 0 } }; - } - function p(a, c, l) { - return a === r.ScalarType.int ? i(c) : a === r.ScalarType.float ? u(l) : c; - } - function i(a) { - a.indexOf("_") !== -1 && (a = a.replace(/_/g, "")); - let c = BigInt(1); - return (a[0] === "-" || a[0] === "+") && (a[0] === "-" && (c = BigInt(-1)), a = a.slice(1)), (c * BigInt(a)).toString(); - } - function u(a) { - const c = JSON.stringify(a); - return c.includes("null") || c.includes("e") || c.includes("E") || c.includes(".") ? c : c + ".0"; - } - return lt; -} -var ct = {}, un; -function Xs() { - if (un) return ct; - un = 1, Object.defineProperty(ct, "__esModule", { value: !0 }), ct.visitJson = void 0; - function r(s, n, o, p) { - if (o === void 0) { - p.onValue(s, n, null, void 0, { value: { start: 0, end: 0 } }); - return; - } - const i = { value: { start: o.offset, end: o.offset + o.length } }; - if (s && s.type === "property") { - const u = s.children[0]; - i.key = { start: u.offset, end: u.offset + u.length }; - } - if (o.type === "object") { - p.onObjectStart(s, n, o, i); - for (const u of o.children) { - const [a, c] = u.children; - r(u, a.value, c, p); - } - p.onObjectEnd(); - } else o.type === "array" ? (p.onArrayStart(s, n, o, i), o.children.forEach((u, a) => { - r(o, a, u, p); - }), p.onArrayEnd()) : p.onValue(s, n, o.value, o.rawValue, i); - } - return ct.visitJson = r, ct; -} -var pt = {}, ln; -function zs() { - if (ln) return pt; - ln = 1, Object.defineProperty(pt, "__esModule", { value: !0 }), pt.parseTree = void 0; - const r = gn; - var s; - (function(i) { - i.DEFAULT = { - allowTrailingComma: !1 - }; - })(s || (s = {})); - function n(i) { - switch (typeof i) { - case "boolean": - return "boolean"; - case "number": - return "number"; - case "string": - return "string"; - case "object": { - if (i) { - if (Array.isArray(i)) - return "array"; - } else return "null"; - return "object"; - } - default: - return "null"; - } - } - function o(i) { - const u = []; - for (let a = 0; a < i.length; a++) { - const c = i[a]; - if (c.type === "property") - for (let l = 0; l < i.length; l++) { - const f = i[l]; - f.type === "property" && c.children[0].value === f.children[0].value && a !== l && u.push(i[a].children[0]); - } - } - return u; - } - function p(i, u = [], a = s.DEFAULT) { - let c = { - type: "array", - offset: -1, - length: -1, - children: [], - parent: void 0 - }; - function l(y) { - c.type === "property" && (c.length = y - c.offset, c = c.parent); - } - function f(y) { - return c.children.push(y), y; - } - const d = { - onObjectBegin: (y) => { - c = f({ - type: "object", - offset: y, - length: -1, - parent: c, - children: [] - }); - }, - onObjectProperty: (y, S, T) => { - c = f({ - type: "property", - offset: S, - length: -1, - parent: c, - children: [] - }), c.children.push({ - type: "string", - value: y, - offset: S, - length: T, - parent: c - }); - }, - onObjectEnd: (y, S) => { - if (l(y + S), c.type === "object" && c.children && c.children.length > 1) { - const T = o(c.children); - for (const { offset: v, length: h } of T) - u.push({ - error: 0, - extendedError: 1, - offset: v, - length: h - }); - } - c.length = y + S - c.offset, c = c.parent, l(y + S); - }, - onArrayBegin: (y, S) => { - c = f({ - type: "array", - offset: y, - length: -1, - parent: c, - children: [] - }); - }, - onArrayEnd: (y, S) => { - c.length = y + S - c.offset, c = c.parent, l(y + S); - }, - onLiteralValue: (y, S, T) => { - f({ - type: n(y), - offset: S, - length: T, - parent: c, - value: y, - rawValue: i.substring(S, S + T) - }), l(S + T); - }, - onSeparator: (y, S, T) => { - c.type === "property" && (y === ":" ? c.colonOffset = S : y === "," && l(S)); - }, - onError: (y, S, T) => { - u.push({ error: y, offset: S, length: T }); - } - }; - (0, r.visit)(i, d, a); - const E = c.children[0]; - return E && delete E.parent, E; - } - return pt.parseTree = p, pt; -} -var fn; -function Zs() { - if (fn) return Ze; - fn = 1, Object.defineProperty(Ze, "__esModule", { value: !0 }), Ze.parseYaml = Ze.parseJson = void 0; - const r = Qs(), s = Xs(), n = gt(), o = zs(), p = gn, i = ei(), u = ot(), a = $e(), c = It(); - function l(S) { - return S.extendedError ? S.extendedError === 1 ? "DuplicateKey" : "" : p.printParseErrorCode(S.error); - } - function f(S) { - const T = [], v = (0, o.parseTree)(S, T, { - disallowComments: !0, - allowTrailingComma: !1, - allowEmptyContent: !1 - }), h = T.map((b) => ({ - message: l(b), - offset: b.offset, - length: b.length - })); - return v ? [y(s.visitJson, v), h] : [void 0, h]; - } - Ze.parseJson = f; - function d(S, T) { - const v = []; - if (i.loadAll(S, (b) => { - v.push(b); - }, { schema: E(T) }), v.length !== 1) - return [void 0, []]; - const h = v[0].errors.map((b) => ({ - message: b.message, - offset: b.mark ? b.mark.position : 0 - })); - return v[0] ? [y(r.visitYaml, v[0]), h] : [void 0, h]; - } - Ze.parseYaml = d; - function E(S) { - if (!S) - return c; - const T = Object.entries(S).map(([v, h]) => new a.Type(v, { kind: h })); - return u.Schema.create(c, T); - } - function y(S, T) { - var v; - let h = {}; - const b = [h]; - if (S(null, "fakeroot", T, { - onObjectStart: (_, O, P, L) => { - L && (0, n.setPreservedLocation)(h, O, L), b.push(h), h = h[O] = {}; - }, - onObjectEnd: () => { - h = b.pop(); - }, - onArrayStart: (_, O, P, L) => { - L && (0, n.setPreservedLocation)(h, O, L), b.push(h), h = h[O] = []; - }, - onArrayEnd: () => { - h = b.pop(); - }, - onValue: (_, O, P, L, Y) => { - h[O] = P, typeof P == "number" && L !== void 0 && (0, n.setPreservedValue)(h, O, L), Y && (0, n.setPreservedLocation)(h, O, Y); - } - }), typeof b[0].fakeroot != "object") - return; - const w = (v = (0, n.getPreservedLocation)(b[0], "fakeroot")) === null || v === void 0 ? void 0 : v.value; - return (0, n.setPreservedRootRange)(b[0].fakeroot, w), b[0].fakeroot; - } - return Ze; -} -var ht = {}, cn; -function ea() { - if (cn) return ht; - cn = 1, Object.defineProperty(ht, "__esModule", { value: !0 }), ht.stringify = void 0; - const r = zn(); - function s(a, c = 0) { - return c === 0 ? n(a) : o(a, c); - } - ht.stringify = s; - function n(a) { - if (!a) - return JSON.stringify(a); - const c = []; - return (0, r.visitObject)(void 0, "fakeroot", a, { - onObjectStart: (l, f, d) => { - c.push(i(f, "{")); - }, - onObjectEnd: () => { - c[c.length - 1].endsWith(",") && p(c, 1), c.push("},"); - }, - onArrayStart: (l, f, d) => { - c.push(i(f, "[")); - }, - onArrayEnd: () => { - c[c.length - 1].endsWith(",") && p(c, 1), c.push("],"); - }, - onValue: (l, f, d, E) => { - E !== void 0 ? c.push(i(f, E) + ",") : c.push(i(f, JSON.stringify(d)) + ","); - } - }), c[0] = c[0].slice(11), p(c, 1), c.join(""); - } - function o(a, c) { - if (!a) - return JSON.stringify(a); - const l = []; - let f = 0; - const d = [!0]; - return (0, r.visitObject)(void 0, "fakeroot", a, { - onObjectStart: (E, y, S) => { - l.push(u(c, f) + i(y, `{ -`, !1)), d[d.length - 1] = !1, d.push(!0), f++; - }, - onObjectEnd: () => { - f--, d.pop() ? (p(l, 1), l.push(`}, -`)) : (p(l, 2), l.push(` -` + u(c, f) + `}, -`)); - }, - onArrayStart: (E, y, S) => { - l.push(u(c, f) + i(y, `[ -`, !1)), d[d.length - 1] = !1, d.push(!0), f++; - }, - onArrayEnd: () => { - f--, d.pop() ? (p(l, 1), l.push(`], -`)) : (p(l, 2), l.push(` -` + u(c, f) + `], -`)); - }, - onValue: (E, y, S, T) => { - d[d.length - 1] = !1, T !== void 0 ? l.push(u(c, f) + i(y, T, !1) + `, -`) : l.push(u(c, f) + i(y, JSON.stringify(S), !1) + `, -`); - } - }), l[0] = l[0].slice(12), p(l, 2), l.join(""); - } - function p(a, c) { - const l = a.length - 1; - a[l] = a[l].slice(0, -c); - } - function i(a, c, l = !0) { - const f = l ? ":" : ": "; - return typeof a == "string" ? JSON.stringify(a) + f + c : c; - } - function u(a, c) { - return " ".repeat(a * c); - } - return ht; -} -var Ve = {}, He = {}, pn; -function ti() { - if (pn) return He; - pn = 1, Object.defineProperty(He, "__esModule", { value: !0 }), He.find = He.findByPath = He.parseJsonPointer = He.joinJsonPointer = void 0; - const r = /\//g, s = /~/g; - function n(a) { - return typeof a == "number" ? String(a) : a.replace(s, "~0").replace(r, "~1"); - } - function o(a) { - return a.length == 0 ? "" : "/" + a.map((c) => n(c)).join("/"); - } - He.joinJsonPointer = o; - function p(a) { - const c = /~/, l = /~[01]/g; - function f(E) { - switch (E) { - case "~1": - return "/"; - case "~0": - return "~"; - } - throw new Error("Invalid tilde escape: " + E); - } - function d(E) { - return c.test(E) ? E.replace(l, f) : E; - } - return a.split("/").slice(1).map(d).map(decodeURIComponent); - } - He.parseJsonPointer = p; - function i(a, c) { - let l = a; - for (const f of c) - if (typeof l == "object" && l !== null) - if (Array.isArray(l)) { - const d = typeof f == "string" ? parseInt(f, 10) : f; - if (isNaN(d)) - return; - l = l[d]; - } else if (l.hasOwnProperty(f)) - l = l[f]; - else - return; - else - return; - return l; - } - He.findByPath = i; - function u(a, c) { - return i(a, p(c)); - } - return He.find = u, He; -} -var hn; -function ta() { - if (hn) return Ve; - hn = 1, Object.defineProperty(Ve, "__esModule", { value: !0 }), Ve.findLocationForJsonPointer = Ve.findLocationForPath = Ve.findNodeAtOffset = void 0; - const r = gt(), s = ti(); - function n(a, c) { - return c >= a.start && c <= a.end; - } - function o(a, c) { - const l = { value: (0, r.getPreservedRootRange)(a) }; - return p(a, c, [], l); - } - Ve.findNodeAtOffset = o; - function p(a, c, l, f) { - const d = Array.isArray(a) ? a.keys() : Object.keys(a); - for (const E of d) { - const y = (0, r.getPreservedLocation)(a, E); - if (y && n(y.value, c)) { - const S = a[E]; - return l.push(E), S !== null && typeof S == "object" ? p(S, c, l, y) : [S, l, y]; - } - } - return [a, l, f]; - } - function i(a, c) { - if (c.length === 0) - return { value: (0, r.getPreservedRootRange)(a) }; - let l = a, f = 0; - for (; f < c.length - 1 && l; ) - l = l[c[f]], f++; - if (l) - return (0, r.getPreservedLocation)(l, c[f]); - } - Ve.findLocationForPath = i; - function u(a, c) { - return i(a, (0, s.parseJsonPointer)(c)); - } - return Ve.findLocationForJsonPointer = u, Ve; -} -var dn; -function ra() { - return dn || (dn = 1, (function(r) { - Object.defineProperty(r, "__esModule", { value: !0 }), r.parseJsonPointer = r.joinJsonPointer = r.findLocationForPath = r.findByPath = r.findLocationForJsonPointer = r.find = r.findNodeAtOffset = r.getRootRange = r.getLocation = r.simpleClone = r.stringify = r.parseYaml = r.parseJson = r.parse = void 0; - const s = Cs(); - Object.defineProperty(r, "simpleClone", { enumerable: !0, get: function() { - return s.simpleClone; - } }); - const n = Zs(); - Object.defineProperty(r, "parseJson", { enumerable: !0, get: function() { - return n.parseJson; - } }), Object.defineProperty(r, "parseYaml", { enumerable: !0, get: function() { - return n.parseYaml; - } }); - const o = ea(); - Object.defineProperty(r, "stringify", { enumerable: !0, get: function() { - return o.stringify; - } }); - const p = gt(); - Object.defineProperty(r, "getLocation", { enumerable: !0, get: function() { - return p.getPreservedLocation; - } }), Object.defineProperty(r, "getRootRange", { enumerable: !0, get: function() { - return p.getPreservedRootRange; - } }); - const i = ta(); - Object.defineProperty(r, "findLocationForJsonPointer", { enumerable: !0, get: function() { - return i.findLocationForJsonPointer; - } }), Object.defineProperty(r, "findLocationForPath", { enumerable: !0, get: function() { - return i.findLocationForPath; - } }), Object.defineProperty(r, "findNodeAtOffset", { enumerable: !0, get: function() { - return i.findNodeAtOffset; - } }); - const u = ti(); - Object.defineProperty(r, "find", { enumerable: !0, get: function() { - return u.find; - } }), Object.defineProperty(r, "joinJsonPointer", { enumerable: !0, get: function() { - return u.joinJsonPointer; - } }), Object.defineProperty(r, "parseJsonPointer", { enumerable: !0, get: function() { - return u.parseJsonPointer; - } }), Object.defineProperty(r, "findByPath", { enumerable: !0, get: function() { - return u.findByPath; - } }); - function a(c, l, f) { - var d; - return l === "yaml" ? (0, n.parseYaml)(c, (d = f?.yaml) === null || d === void 0 ? void 0 : d.customTags) : (0, n.parseJson)(c); - } - r.parse = a; - })(jt)), jt; -} -var mr = ra(); -function na(r, s) { - for (let n = r.length - 1; n >= 0; n--) { - const { id: o, env: p } = r[n]; - if (p.hasOwnProperty(s)) - return { context: o, value: p[s], name: s }; - } -} -const ia = [ - "$randomString", - "$randomuint", - "$uuid", - "$timestamp", - "$timestamp3339", - "$randomFromSchema" -], oa = { - $randomString: () => aa(20), - $randomuint: () => fa(), - $uuid: () => crypto.randomUUID(), - $timestamp: () => ua(), - $timestamp3339: () => la(), - $randomFromSchema: sa -}; -function sa(r, s, n) { - const o = n(); - if (s.path[0] == "body" && s.path[1] === "value") - return mr.findByPath(o.body, s.path.slice(2)); - if (s.path[0] === "parameters") { - const p = mr.findByPath(r, [...s.path.slice(0, -1), "key"]); - return o.parameters[s.path[1]][p]; - } -} -function aa(r) { - const s = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789", n = new Uint32Array(r); - crypto.getRandomValues(n); - let o = ""; - for (let p = 0; p < r; p++) - o += s.charAt(n[p] % s.length); - return o; -} -function ua() { - return Math.floor((/* @__PURE__ */ new Date()).getTime() / 1e3); -} -function la() { - return (/* @__PURE__ */ new Date()).toISOString(); -} -function fa() { - const r = new Uint32Array(1); - return crypto.getRandomValues(r), r[0]; -} -const Ra = () => /^([\w\-]+)$/g, ka = "Only the alphanumeric characters, minus or underscore", ca = () => /{{([\w\-$]+)}}/g, pa = () => /^{{([\w\-$]+)}}$/; -function Ia(r, s, n) { - return ri(r, s, n, () => ({ - body: void 0, - parameters: void 0 - })); -} -function La(r, s, n, o) { - let p; - return ri("request", s, o, () => (p === void 0 && (p = ma(r, n, s.path, s.method)), p)); -} -function Ma(r, s) { - return ni(r, s, {}, { type: "credential", path: [] }, () => ({ - body: void 0, - parameters: void 0 - })); -} -function ri(r, s, n, o) { - const p = [], i = [], u = mr.simpleClone(s, (a, c) => { - if (typeof a == "string") { - const l = ha( - a, - n, - s, - { type: r, path: c }, - o - ); - return p.push(...l.missing), i.push(...l.found), l.value; - } else - return a; - }); - return { - missing: p, - found: i, - value: u - }; -} -function ha(r, s, n, o, p) { - const i = r.match(pa()); - if (i && i.length === 2) { - const u = i[1]; - return da(u, r, s, n, o, p); - } else - return ni(r, s, n, o, p); -} -function da(r, s, n, o, p, i) { - const u = ii(n, r, o, p, i); - return u !== void 0 ? { found: [{ ...u, offset: 0, location: p }], missing: [], value: u.value } : { found: [], missing: [{ name: r, location: p }], value: s }; -} -function ni(r, s, n, o, p) { - const i = [], u = [], a = r.replace( - ca(), - (c, l, f) => { - const d = ii(s, l, n, o, p); - return d !== void 0 ? (u.push({ ...d, offset: f, location: o }), `${d.value}`) : (i.push({ name: l, location: o }), c); - } - ); - return { - found: u, - missing: i, - value: a - }; -} -function ii(r, s, n, o, p) { - if (ia.includes(s)) { - const i = oa[s](n, o, p); - return { context: { type: "built-in" }, value: i, name: s }; - } else - return na(r, s); -} -function ma(r, s, n, o) { - const p = { body: void 0, parameters: void 0 }; - if (s === void 0) - return p; - if (gr(r)) { - const i = Ne( - r, - s.requestBody - ), u = Ne(r, i?.content["application/json"]?.schema); - u && (p.body = mn({ ...u, components: r.components })); - const a = Vn(r, n, o); - p.parameters = Jn(r, a); - } else { - const i = Qn(r, n, o); - if (i.body) { - const u = Object.values(i.body)?.[0], a = Ne(r, u?.schema); - a && (p.body = mn({ ...a, definitions: r.definitions })); - } - p.parameters = Xn(r, i); - } - return p; -} -function mn(r) { - try { - return Ie.option("useExamplesValue", !1), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0), Ie.generate(r); - } catch { - return; - } -} -function Na(r) { - return r.map((s) => s.name).join(", "); -} -export { - hi as A, - Tt as B, - di as C, - ia as D, - ca as E, - mi as F, - Ma as G, - Ia as H, - va as I, - La as J, - Na as K, - Ta as a, - fs as b, - xa as c, - Ne as d, - Or as e, - Ct as f, - Vn as g, - _a as h, - gr as i, - pi as j, - Qn as k, - Pa as l, - xs as m, - Ca as n, - mr as o, - Aa as p, - ba as q, - ka as r, - Ea as s, - Ra as t, - Sa as u, - vi as v, - Oa as w, - bi as x, - wa as y, - yi as z -}; diff --git a/openapi-plugin/resources/web/variables.CfsUBZ9t.js b/openapi-plugin/resources/web/variables.CfsUBZ9t.js new file mode 100644 index 00000000..f11afd01 --- /dev/null +++ b/openapi-plugin/resources/web/variables.CfsUBZ9t.js @@ -0,0 +1,9842 @@ +import { q as je } from "./TriangleExclamation.BLKAXJ8l.js"; +import { l as rt, H as yr } from "./index.BXf_Hj-1.js"; +function Ne(r, i) { + if (i != null) + return typeof i == "object" && "$ref" in i ? rt.find(r, i.$ref) : i; +} +function ot(r, i, t) { + return Ne(r, r.paths?.[i])?.[t]; +} +function vr(r, i) { + return (i.parameters ?? []).map((n) => Ne(r, n)); +} +function br(r, i) { + return (i?.parameters ?? []).map((n) => Ne(r, n)); +} +function It(r) { + const i = (r.servers ?? []).filter((t) => t.url !== void 0 && t.url !== "").map((t) => t.url); + return i.length > 0 ? i : ["http://localhost/"]; +} +function wr(r, i, t) { + const n = { + query: {}, + header: {}, + path: {}, + cookie: {} + }; + for (const p of i) { + const s = Ne(r, p.schema); + n[p.in][p.name] = { ...p, schema: s }; + } + for (const p of t) { + const s = Ne(r, p.schema); + n[p.in][p.name] = { ...p, schema: s }; + } + return n; +} +function Er(r, i, t) { + const p = ot(r, i, t)?.security ?? r.security ?? [], s = []; + for (const a of p) { + const d = {}; + for (const x of Object.keys(a)) + if (r?.components?.securitySchemes?.[x]) { + const m = Ne(r, r.components.securitySchemes[x]); + m && (d[x] = m); + } + s.push(d); + } + return s; +} +function at(r, i, t) { + if (t !== "trace") + return Ne(r, r.paths[i])?.[t]; +} +function Ar(r, i) { + return (i.parameters ?? []).map((n) => Ne(r, n)); +} +function xr(r, i) { + return (i?.parameters ?? []).map((n) => Ne(r, n)); +} +function _r(r, i, t) { + const n = { + query: {}, + header: {}, + path: {}, + formData: {}, + body: {} + }; + for (const p of i) { + const s = Ne(r, p.schema); + n[p.in][p.name] = { ...p, schema: s }; + } + for (const p of t) { + const s = Ne(r, p.schema); + n[p.in][p.name] = { ...p, schema: s }; + } + return n; +} +function Pt(r) { + const i = r.schemes ?? ["http"], t = r.basePath ?? "", n = r.host ?? "localhost"; + return i.map((p) => `${p}://${n}${t}`); +} +function Or(r, i) { + return i?.consumes && i.consumes.length > 0 ? i.consumes : r?.consumes && r.consumes.length > 0 ? r.consumes : []; +} +function Et(r) { + return "openapi" in r; +} +function Sr(r, i, t) { + return t === "trace" ? Et(r) ? Ne(r, r.paths?.[i])?.[t] : void 0 : Ne(r, r.paths?.[i])?.[t]; +} +function Tr(r) { + const i = []; + for (const t of Object.keys(r.paths ?? {})) + for (const n of Object.keys(r.paths?.[t] ?? {})) + if (yr.includes(n)) { + const p = Sr(r, t, n); + i.push([t, n, p]); + } + return i; +} +function Cr(r, i, t) { + return r === void 0 || r === "" ? `${i}:${t}` : r; +} +function Xi(r, i) { + const t = Tr(r); + for (const [n, p, s] of t) + if (Cr(s.operationId, n, p) === i) + return { path: n, method: p, operation: s }; +} +function Qi(r) { + return Et(r) ? It(r) : Pt(r); +} +function zi(r) { + if (r >= 100 && r <= 199) + return "1XX"; + if (r >= 200 && r <= 299) + return "2XX"; + if (r >= 300 && r <= 399) + return "3XX"; + if (r >= 400 && r <= 499) + return "4XX"; + if (r >= 500 && r <= 599) + return "5XX"; +} +function ze(r) { + throw new Error('Could not dynamically require "' + r + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.'); +} +var Ze = { exports: {} }, Ot; +function Rr() { + return Ot || (Ot = 1, (function(r, i) { + (() => { + (function(t) { + r.exports = t(); + })(function() { + return (/* @__PURE__ */ (function() { + function t(n, p, s) { + function a(m, h) { + if (!p[m]) { + if (!n[m]) { + var y = typeof ze == "function" && ze; + if (!h && y) return y(m, !0); + if (d) return d(m, !0); + var E = new Error("Cannot find module '" + m + "'"); + throw E.code = "MODULE_NOT_FOUND", E; + } + var g = p[m] = { exports: {} }; + n[m][0].call(g.exports, function(M) { + var R = n[m][1][M]; + return a(R || M); + }, g, g.exports, t, n, p, s); + } + return p[m].exports; + } + for (var d = typeof ze == "function" && ze, x = 0; x < s.length; x++) a(s[x]); + return a; + } + return t; + })())({ 1: [function(t, n, p) { + var s = t("./ref"), a = t("./pointer"), d = t("./util/url"); + function x(M, R) { + var l = []; + m(M, "schema", M.$refs._root$Ref.path + "#", "#", 0, l, M.$refs, R), y(l); + } + function m(M, R, l, o, c, f, b, A) { + var _ = R === null ? M : M[R]; + _ && typeof _ == "object" && (s.isAllowed$Ref(_) ? h(M, R, l, o, c, f, b, A) : Object.keys(_).sort(function(S, F) { + return S === "definitions" ? -1 : F === "definitions" ? 1 : S.length - F.length; + }).forEach(function(S) { + var F = a.join(l, S), D = a.join(o, S), H = _[S]; + s.isAllowed$Ref(H) ? h(_, S, l, D, c, f, b, A) : m(_, S, F, D, c, f, b, A); + })); + } + function h(M, R, l, o, c, f, b, A) { + var _ = R === null ? M : M[R], S = d.resolve(l, _.$ref), F = b._resolve(S, A), D = a.parse(o).length, H = d.stripHash(F.path), j = d.getHash(F.path), Q = H !== b._root$Ref.path, T = s.isExtended$Ref(_); + c += F.indirections; + var G = E(f, M, R); + if (G) { + if (!(D < G.depth || c < G.indirections)) return; + g(f, G); + } + f.push({ $ref: _, parent: M, key: R, pathFromRoot: o, depth: D, file: H, hash: j, value: F.value, circular: F.circular, extended: T, external: Q, indirections: c }), m(F.value, null, F.path, o, c + 1, f, b, A); + } + function y(M) { + var R, l, o; + M.sort(function(c, f) { + if (c.file !== f.file) return c.file < f.file ? -1 : 1; + if (c.hash !== f.hash) return c.hash < f.hash ? -1 : 1; + if (c.circular !== f.circular) return c.circular ? -1 : 1; + if (c.extended !== f.extended) return c.extended ? 1 : -1; + if (c.indirections !== f.indirections) return c.indirections - f.indirections; + if (c.depth !== f.depth) return c.depth - f.depth; + var b = c.pathFromRoot.lastIndexOf("/definitions"), A = f.pathFromRoot.lastIndexOf("/definitions"); + return b !== A ? A - b : c.pathFromRoot.length - f.pathFromRoot.length; + }), M.forEach(function(c) { + c.external ? c.file === R && c.hash === l ? c.$ref.$ref = o : c.file === R && c.hash.indexOf(l + "/") === 0 ? c.$ref.$ref = a.join(o, a.parse(c.hash.replace(l, "#"))) : (R = c.file, l = c.hash, o = c.pathFromRoot, c.$ref = c.parent[c.key] = s.dereference(c.$ref, c.value), c.circular && (c.$ref.$ref = c.pathFromRoot)) : c.$ref.$ref = c.hash; + }); + } + function E(M, R, l) { + for (var o = 0; o < M.length; o++) { + var c = M[o]; + if (c.parent === R && c.key === l) return c; + } + } + function g(M, R) { + var l = M.indexOf(R); + M.splice(l, 1); + } + n.exports = x; + }, { "./pointer": 11, "./ref": 12, "./util/url": 18 }], 2: [function(t, n, p) { + var s = t("./ref"), a = t("./pointer"), d = t("ono"), x = t("./util/url"); + function m(g, M) { + var R = h(g.schema, g.$refs._root$Ref.path, "#", [], g.$refs, M); + g.$refs.circular = R.circular, g.schema = R.value; + } + function h(g, M, R, l, o, c) { + var f, b = { value: g, circular: !1 }; + return g && typeof g == "object" && (l.push(g), s.isAllowed$Ref(g, c) ? (f = y(g, M, R, l, o, c), b.circular = f.circular, b.value = f.value) : Object.keys(g).forEach(function(A) { + var _ = a.join(M, A), S = a.join(R, A), F = g[A], D = !1; + s.isAllowed$Ref(F, c) ? (D = (f = y(F, _, S, l, o, c)).circular, g[A] = f.value) : l.indexOf(F) === -1 ? (D = (f = h(F, _, S, l, o, c)).circular, g[A] = f.value) : D = E(_, o, c), b.circular = b.circular || D; + }), l.pop()), b; + } + function y(g, M, R, l, o, c) { + var f = x.resolve(M, g.$ref), b = o._resolve(f, c), A = b.circular, _ = A || l.indexOf(b.value) !== -1; + _ && E(M, o, c); + var S = s.dereference(g, b.value); + if (!_) { + var F = h(S, b.path, R, l, o, c); + _ = F.circular, S = F.value; + } + return _ && !A && c.dereference.circular === "ignore" && (S = g), A && (S.$ref = R), { circular: _, value: S }; + } + function E(g, M, R) { + if (M.circular = !0, !R.dereference.circular) throw d.reference("Circular $ref pointer found at %s", g); + return !0; + } + n.exports = m; + }, { "./pointer": 11, "./ref": 12, "./util/url": 18, ono: 64 }], 3: [function(t, n, p) { + (function(s) { + t("./options"); + var a = t("./refs"), d = t("./parse"), x = t("./normalize-args"), m = t("./resolve-external"), h = t("./bundle"), y = t("./dereference"), E = t("./util/url"), g = t("call-me-maybe"), M = t("ono"); + function R() { + this.schema = null, this.$refs = new a(); + } + n.exports = R, n.exports.YAML = t("./util/yaml"), R.parse = function(l, o, c, f) { + var b = new this(); + return b.parse.apply(b, arguments); + }, R.prototype.parse = function(l, o, c, f) { + var b, A = x(arguments); + if (!A.path && !A.schema) { + var _ = M("Expected a file path, URL, or object. Got %s", A.path || A.schema); + return g(A.callback, Promise.reject(_)); + } + this.schema = null, this.$refs = new a(); + var S = "http"; + if (E.isFileSystemPath(A.path) && (A.path = E.fromFileSystemPath(A.path), S = "file"), A.path = E.resolve(E.cwd(), A.path), A.schema && typeof A.schema == "object") { + var F = this.$refs._add(A.path); + F.value = A.schema, F.pathType = S, b = Promise.resolve(A.schema); + } else b = d(A.path, this.$refs, A.options); + var D = this; + return b.then(function(H) { + if (!H || typeof H != "object" || s.isBuffer(H)) throw M.syntax('"%s" is not a valid JSON Schema', D.$refs._root$Ref.path || H); + return D.schema = H, g(A.callback, Promise.resolve(D.schema)); + }).catch(function(H) { + return g(A.callback, Promise.reject(H)); + }); + }, R.resolve = function(l, o, c, f) { + var b = new this(); + return b.resolve.apply(b, arguments); + }, R.prototype.resolve = function(l, o, c, f) { + var b = this, A = x(arguments); + return this.parse(A.path, A.schema, A.options).then(function() { + return m(b, A.options); + }).then(function() { + return g(A.callback, Promise.resolve(b.$refs)); + }).catch(function(_) { + return g(A.callback, Promise.reject(_)); + }); + }, R.bundle = function(l, o, c, f) { + var b = new this(); + return b.bundle.apply(b, arguments); + }, R.prototype.bundle = function(l, o, c, f) { + var b = this, A = x(arguments); + return this.resolve(A.path, A.schema, A.options).then(function() { + return h(b, A.options), g(A.callback, Promise.resolve(b.schema)); + }).catch(function(_) { + return g(A.callback, Promise.reject(_)); + }); + }, R.dereference = function(l, o, c, f) { + var b = new this(); + return b.dereference.apply(b, arguments); + }, R.prototype.dereference = function(l, o, c, f) { + var b = this, A = x(arguments); + return this.resolve(A.path, A.schema, A.options).then(function() { + return y(b, A.options), g(A.callback, Promise.resolve(b.schema)); + }).catch(function(_) { + return g(A.callback, Promise.reject(_)); + }); + }; + }).call(this, { isBuffer: t("../node_modules/is-buffer/index.js") }); + }, { "../node_modules/is-buffer/index.js": 32, "./bundle": 1, "./dereference": 2, "./normalize-args": 4, "./options": 5, "./parse": 6, "./refs": 13, "./resolve-external": 14, "./util/url": 18, "./util/yaml": 19, "call-me-maybe": 25, ono: 64 }], 4: [function(t, n, p) { + var s = t("./options"); + function a(d) { + var x, m, h, y; + return typeof (d = Array.prototype.slice.call(d))[d.length - 1] == "function" && (y = d.pop()), typeof d[0] == "string" ? (x = d[0], typeof d[2] == "object" ? (m = d[1], h = d[2]) : (m = void 0, h = d[1])) : (x = "", m = d[0], h = d[1]), h instanceof s || (h = new s(h)), { path: x, schema: m, options: h, callback: y }; + } + n.exports = a; + }, { "./options": 5 }], 5: [function(t, n, p) { + var s = t("./parsers/json"), a = t("./parsers/yaml"), d = t("./parsers/text"), x = t("./parsers/binary"), m = t("./resolvers/file"), h = t("./resolvers/http"); + function y(M) { + E(this, y.defaults), E(this, M); + } + function E(M, R) { + if (g(R)) for (var l = Object.keys(R), o = 0; o < l.length; o++) { + var c = l[o], f = R[c], b = M[c]; + g(f) ? M[c] = E(b || {}, f) : f !== void 0 && (M[c] = f); + } + return M; + } + function g(M) { + return M && typeof M == "object" && !Array.isArray(M) && !(M instanceof RegExp) && !(M instanceof Date); + } + n.exports = y, y.defaults = { parse: { json: s, yaml: a, text: d, binary: x }, resolve: { file: m, http: h, external: !0 }, dereference: { circular: !0 } }; + }, { "./parsers/binary": 7, "./parsers/json": 8, "./parsers/text": 9, "./parsers/yaml": 10, "./resolvers/file": 15, "./resolvers/http": 16 }], 6: [function(t, n, p) { + (function(s) { + var a = t("ono"), d = t("./util/url"), x = t("./util/plugins"); + function m(g, M, R) { + try { + g = d.stripHash(g); + var l = M._add(g), o = { url: g, extension: d.getExtension(g) }; + return h(o, R).then(function(c) { + return l.pathType = c.plugin.name, o.data = c.result, y(o, R); + }).then(function(c) { + return l.value = c.result, c.result; + }); + } catch (c) { + return Promise.reject(c); + } + } + function h(g, M) { + return new Promise(function(R, l) { + var o = x.all(M.resolve); + o = x.filter(o, "canRead", g), x.sort(o), x.run(o, "read", g).then(R, function(c) { + !c || c instanceof SyntaxError ? l(a.syntax('Unable to resolve $ref pointer "%s"', g.url)) : l(c); + }); + }); + } + function y(g, M) { + return new Promise(function(R, l) { + var o = x.all(M.parse), c = x.filter(o, "canParse", g), f = c.length > 0 ? c : o; + x.sort(f), x.run(f, "parse", g).then(function(b) { + !b.plugin.allowEmpty && E(b.result) ? l(a.syntax(`Error parsing "%s" as %s. +Parsed value is empty`, g.url, b.plugin.name)) : R(b); + }, function(b) { + b ? (b = b instanceof Error ? b : new Error(b), l(a.syntax(b, "Error parsing %s", g.url))) : l(a.syntax("Unable to parse %s", g.url)); + }); + }); + } + function E(g) { + return g === void 0 || typeof g == "object" && Object.keys(g).length === 0 || typeof g == "string" && g.trim().length === 0 || s.isBuffer(g) && g.length === 0; + } + n.exports = m; + }).call(this, { isBuffer: t("../node_modules/is-buffer/index.js") }); + }, { "../node_modules/is-buffer/index.js": 32, "./util/plugins": 17, "./util/url": 18, ono: 64 }], 7: [function(t, n, p) { + (function(s) { + var a = /\.(jpeg|jpg|gif|png|bmp|ico)$/i; + n.exports = { order: 400, allowEmpty: !0, canParse: function(d) { + return s.isBuffer(d.data) && a.test(d.url); + }, parse: function(d) { + return s.isBuffer(d.data) ? d.data : new s(d.data); + } }; + }).call(this, t("buffer").Buffer); + }, { buffer: 23 }], 8: [function(t, n, p) { + (function(s) { + n.exports = { order: 100, allowEmpty: !0, canParse: ".json", parse: function(a) { + return new Promise(function(d, x) { + var m = a.data; + s.isBuffer(m) && (m = m.toString()), typeof m == "string" ? m.trim().length === 0 ? d(void 0) : d(JSON.parse(m)) : d(m); + }); + } }; + }).call(this, { isBuffer: t("../../node_modules/is-buffer/index.js") }); + }, { "../../node_modules/is-buffer/index.js": 32 }], 9: [function(t, n, p) { + (function(s) { + var a = /\.(txt|htm|html|md|xml|js|min|map|css|scss|less|svg)$/i; + n.exports = { order: 300, allowEmpty: !0, encoding: "utf8", canParse: function(d) { + return (typeof d.data == "string" || s.isBuffer(d.data)) && a.test(d.url); + }, parse: function(d) { + if (typeof d.data == "string") return d.data; + if (s.isBuffer(d.data)) return d.data.toString(this.encoding); + throw new Error("data is not text"); + } }; + }).call(this, { isBuffer: t("../../node_modules/is-buffer/index.js") }); + }, { "../../node_modules/is-buffer/index.js": 32 }], 10: [function(t, n, p) { + (function(s) { + var a = t("../util/yaml"); + n.exports = { order: 200, allowEmpty: !0, canParse: [".yaml", ".yml", ".json"], parse: function(d) { + return new Promise(function(x, m) { + var h = d.data; + s.isBuffer(h) && (h = h.toString()), x(typeof h == "string" ? a.parse(h) : h); + }); + } }; + }).call(this, { isBuffer: t("../../node_modules/is-buffer/index.js") }); + }, { "../../node_modules/is-buffer/index.js": 32, "../util/yaml": 19 }], 11: [function(t, n, p) { + n.exports = E; + var s = t("./ref"), a = t("./util/url"), d = t("ono"), x = /\//g, m = /~/g, h = /~1/g, y = /~0/g; + function E(R, l, o) { + this.$ref = R, this.path = l, this.originalPath = o || l, this.value = void 0, this.circular = !1, this.indirections = 0; + } + function g(R, l) { + if (s.isAllowed$Ref(R.value, l)) { + var o = a.resolve(R.path, R.value.$ref); + if (o !== R.path) { + var c = R.$ref.$refs._resolve(o, l); + return R.indirections += c.indirections + 1, s.isExtended$Ref(R.value) ? (R.value = s.dereference(R.value, c.value), !1) : (R.$ref = c.$ref, R.path = c.path, R.value = c.value, !0); + } + R.circular = !0; + } + } + function M(R, l, o) { + if (!R.value || typeof R.value != "object") throw d.syntax(`Error assigning $ref pointer "%s". +Cannot set "%s" of a non-object.`, R.path, l); + return l === "-" && Array.isArray(R.value) ? R.value.push(o) : R.value[l] = o, o; + } + E.prototype.resolve = function(R, l) { + var o = E.parse(this.path); + this.value = R; + for (var c = 0; c < o.length; c++) { + g(this, l) && (this.path = E.join(this.path, o.slice(c))); + var f = o[c]; + if (this.value[f] === void 0) throw d.syntax(`Error resolving $ref pointer "%s". +Token "%s" does not exist.`, this.originalPath, f); + this.value = this.value[f]; + } + return g(this, l), this; + }, E.prototype.set = function(R, l, o) { + var c, f = E.parse(this.path); + if (f.length === 0) return this.value = l, l; + this.value = R; + for (var b = 0; b < f.length - 1; b++) g(this, o), c = f[b], this.value && this.value[c] !== void 0 ? this.value = this.value[c] : this.value = M(this, c, {}); + return g(this, o), M(this, c = f[f.length - 1], l), R; + }, E.parse = function(R) { + var l = a.getHash(R).substr(1); + if (!l) return []; + l = l.split("/"); + for (var o = 0; o < l.length; o++) l[o] = decodeURIComponent(l[o].replace(h, "/").replace(y, "~")); + if (l[0] !== "") throw d.syntax('Invalid $ref pointer "%s". Pointers must begin with "#/"', l); + return l.slice(1); + }, E.join = function(R, l) { + R.indexOf("#") === -1 && (R += "#"), l = Array.isArray(l) ? l : [l]; + for (var o = 0; o < l.length; o++) { + var c = l[o]; + R += "/" + encodeURIComponent(c.replace(m, "~0").replace(x, "~1")); + } + return R; + }; + }, { "./ref": 12, "./util/url": 18, ono: 64 }], 12: [function(t, n, p) { + n.exports = a; + var s = t("./pointer"); + function a() { + this.path = void 0, this.value = void 0, this.$refs = void 0, this.pathType = void 0; + } + a.prototype.exists = function(d, x) { + try { + return this.resolve(d, x), !0; + } catch { + return !1; + } + }, a.prototype.get = function(d, x) { + return this.resolve(d, x).value; + }, a.prototype.resolve = function(d, x, m) { + return new s(this, d, m).resolve(this.value, x); + }, a.prototype.set = function(d, x) { + var m = new s(this, d); + this.value = m.set(this.value, x); + }, a.is$Ref = function(d) { + return d && typeof d == "object" && typeof d.$ref == "string" && d.$ref.length > 0; + }, a.isExternal$Ref = function(d) { + return a.is$Ref(d) && d.$ref[0] !== "#"; + }, a.isAllowed$Ref = function(d, x) { + if (a.is$Ref(d) && (d.$ref.substr(0, 2) === "#/" || d.$ref === "#" || d.$ref[0] !== "#" && (!x || x.resolve.external))) + return !0; + }, a.isExtended$Ref = function(d) { + return a.is$Ref(d) && Object.keys(d).length > 1; + }, a.dereference = function(d, x) { + if (x && typeof x == "object" && a.isExtended$Ref(d)) { + var m = {}; + return Object.keys(d).forEach(function(h) { + h !== "$ref" && (m[h] = d[h]); + }), Object.keys(x).forEach(function(h) { + h in m || (m[h] = x[h]); + }), m; + } + return x; + }; + }, { "./pointer": 11 }], 13: [function(t, n, p) { + var s = t("ono"), a = t("./ref"), d = t("./util/url"); + function x() { + this.circular = !1, this._$refs = {}, this._root$Ref = null; + } + function m(h, y) { + var E = Object.keys(h); + return (y = Array.isArray(y[0]) ? y[0] : Array.prototype.slice.call(y)).length > 0 && y[0] && (E = E.filter(function(g) { + return y.indexOf(h[g].pathType) !== -1; + })), E.map(function(g) { + return { encoded: g, decoded: h[g].pathType === "file" ? d.toFileSystemPath(g, !0) : g }; + }); + } + n.exports = x, x.prototype.paths = function(h) { + return m(this._$refs, arguments).map(function(y) { + return y.decoded; + }); + }, x.prototype.values = function(h) { + var y = this._$refs; + return m(y, arguments).reduce(function(E, g) { + return E[g.decoded] = y[g.encoded].value, E; + }, {}); + }, x.prototype.toJSON = x.prototype.values, x.prototype.exists = function(h, y) { + try { + return this._resolve(h, y), !0; + } catch { + return !1; + } + }, x.prototype.get = function(h, y) { + return this._resolve(h, y).value; + }, x.prototype.set = function(h, y) { + var E = d.resolve(this._root$Ref.path, h), g = d.stripHash(E), M = this._$refs[g]; + if (!M) throw s(`Error resolving $ref pointer "%s". +"%s" not found.`, h, g); + M.set(E, y); + }, x.prototype._add = function(h) { + var y = d.stripHash(h), E = new a(); + return E.path = y, E.$refs = this, this._$refs[y] = E, this._root$Ref = this._root$Ref || E, E; + }, x.prototype._resolve = function(h, y) { + var E = d.resolve(this._root$Ref.path, h), g = d.stripHash(E), M = this._$refs[g]; + if (!M) throw s(`Error resolving $ref pointer "%s". +"%s" not found.`, h, g); + return M.resolve(E, y, h); + }, x.prototype._get$Ref = function(h) { + h = d.resolve(this._root$Ref.path, h); + var y = d.stripHash(h); + return this._$refs[y]; + }; + }, { "./ref": 12, "./util/url": 18, ono: 64 }], 14: [function(t, n, p) { + var s = t("./ref"), a = t("./pointer"), d = t("./parse"), x = t("./util/url"); + function m(E, g) { + if (!g.resolve.external) return Promise.resolve(); + try { + var M = h(E.schema, E.$refs._root$Ref.path + "#", E.$refs, g); + return Promise.all(M); + } catch (R) { + return Promise.reject(R); + } + } + function h(E, g, M, R) { + var l = []; + return E && typeof E == "object" && (s.isExternal$Ref(E) ? l.push(y(E, g, M, R)) : Object.keys(E).forEach(function(o) { + var c = a.join(g, o), f = E[o]; + s.isExternal$Ref(f) ? l.push(y(f, c, M, R)) : l = l.concat(h(f, c, M, R)); + })), l; + } + function y(E, g, M, R) { + var l = x.resolve(g, E.$ref), o = x.stripHash(l); + return (E = M._$refs[o]) ? Promise.resolve(E.value) : d(l, M, R).then(function(c) { + var f = h(c, o + "#", M, R); + return Promise.all(f); + }); + } + n.exports = m; + }, { "./parse": 6, "./pointer": 11, "./ref": 12, "./util/url": 18 }], 15: [function(t, n, p) { + var s = t("fs"), a = t("ono"), d = t("../util/url"); + n.exports = { order: 100, canRead: function(x) { + return d.isFileSystemPath(x.url); + }, read: function(x) { + return new Promise(function(m, h) { + var y; + try { + y = d.toFileSystemPath(x.url); + } catch (E) { + h(a.uri(E, "Malformed URI: %s", x.url)); + } + try { + s.readFile(y, function(E, g) { + E ? h(a(E, 'Error opening file "%s"', y)) : m(g); + }); + } catch (E) { + h(a(E, 'Error opening file "%s"', y)); + } + }); + } }; + }, { "../util/url": 18, fs: 21, ono: 64 }], 16: [function(t, n, p) { + (function(s, a) { + var d = t("http"), x = t("https"), m = t("ono"), h = t("../util/url"); + function y(g, M, R) { + return new Promise(function(l, o) { + g = h.parse(g), (R = R || []).push(g.href), E(g, M).then(function(c) { + if (c.statusCode >= 400) throw m({ status: c.statusCode }, "HTTP ERROR %d", c.statusCode); + if (c.statusCode >= 300) if (R.length > M.redirects) o(m({ status: c.statusCode }, `Error downloading %s. +Too many redirects: + %s`, R[0], R.join(` + `))); + else { + if (!c.headers.location) throw m({ status: c.statusCode }, "HTTP %d redirect with no location header", c.statusCode); + y(h.resolve(g, c.headers.location), M, R).then(l, o); + } + else l(c.body || new a(0)); + }).catch(function(c) { + o(m(c, "Error downloading", g.href)); + }); + }); + } + function E(g, M) { + return new Promise(function(R, l) { + var o = (g.protocol === "https:" ? x : d).get({ hostname: g.hostname, port: g.port, path: g.path, auth: g.auth, protocol: g.protocol, headers: M.headers || {}, withCredentials: M.withCredentials }); + typeof o.setTimeout == "function" && o.setTimeout(M.timeout), o.on("timeout", function() { + o.abort(); + }), o.on("error", l), o.once("response", function(c) { + c.body = new a(0), c.on("data", function(f) { + c.body = a.concat([c.body, new a(f)]); + }), c.on("error", l), c.on("end", function() { + R(c); + }); + }); + }); + } + n.exports = { order: 200, headers: null, timeout: 5e3, redirects: 5, withCredentials: !1, canRead: function(g) { + return h.isHttp(g.url); + }, read: function(g) { + var M = h.parse(g.url); + return s.browser && !M.protocol && (M.protocol = h.parse(location.href).protocol), y(M, this); + } }; + }).call(this, t("_process"), t("buffer").Buffer); + }, { "../util/url": 18, _process: 66, buffer: 23, http: 80, https: 29, ono: 64 }], 17: [function(t, n, p) { + function s(a, d, x, m) { + var h = a[d]; + if (typeof h == "function") return h.apply(a, [x, m]); + if (!m) { + if (h instanceof RegExp) return h.test(x.url); + if (typeof h == "string") return h === x.extension; + if (Array.isArray(h)) return h.indexOf(x.extension) !== -1; + } + return h; + } + p.all = function(a) { + return Object.keys(a).filter(function(d) { + return typeof a[d] == "object"; + }).map(function(d) { + return a[d].name = d, a[d]; + }); + }, p.filter = function(a, d, x) { + return a.filter(function(m) { + return !!s(m, d, x); + }); + }, p.sort = function(a) { + return a.forEach(function(d) { + d.order = d.order || Number.MAX_SAFE_INTEGER; + }), a.sort(function(d, x) { + return d.order - x.order; + }); + }, p.run = function(a, d, x) { + var m, h, y = 0; + return new Promise(function(E, g) { + function M() { + if (!(m = a[y++])) return g(h); + try { + var c = s(m, d, x, R); + c && typeof c.then == "function" ? c.then(l, o) : c !== void 0 && l(c); + } catch (f) { + o(f); + } + } + function R(c, f) { + c ? o(c) : l(f); + } + function l(c) { + E({ plugin: m, result: c }); + } + function o(c) { + h = c, M(); + } + M(); + }); + }; + }, {}], 18: [function(t, n, p) { + (function(s) { + var a = /^win/.test(s.platform), d = /\//g, x = /^(\w{2,}):\/\//i, m = n.exports, h = [/\?/g, "%3F", /\#/g, "%23"], y = [/\%23/g, "#", /\%24/g, "$", /\%26/g, "&", /\%2C/g, ",", /\%40/g, "@"]; + p.parse = t("url").parse, p.resolve = t("url").resolve, p.cwd = function() { + return s.browser ? location.href : s.cwd() + "/"; + }, p.getProtocol = function(E) { + var g = x.exec(E); + if (g) return g[1].toLowerCase(); + }, p.getExtension = function(E) { + var g = E.lastIndexOf("."); + return g >= 0 ? E.substr(g).toLowerCase() : ""; + }, p.getHash = function(E) { + var g = E.indexOf("#"); + return g >= 0 ? E.substr(g) : "#"; + }, p.stripHash = function(E) { + var g = E.indexOf("#"); + return g >= 0 && (E = E.substr(0, g)), E; + }, p.isHttp = function(E) { + var g = m.getProtocol(E); + return g === "http" || g === "https" || g === void 0 && s.browser; + }, p.isFileSystemPath = function(E) { + if (s.browser) return !1; + var g = m.getProtocol(E); + return g === void 0 || g === "file"; + }, p.fromFileSystemPath = function(E) { + a && (E = E.replace(/\\/g, "/")), E = encodeURI(E); + for (var g = 0; g < h.length; g += 2) E = E.replace(h[g], h[g + 1]); + return E; + }, p.toFileSystemPath = function(E, g) { + E = decodeURI(E); + for (var M = 0; M < y.length; M += 2) E = E.replace(y[M], y[M + 1]); + var R = E.substr(0, 7).toLowerCase() === "file://"; + return R && (E = E[7] === "/" ? E.substr(8) : E.substr(7), a && E[1] === "/" && (E = E[0] + ":" + E.substr(1)), g ? E = "file:///" + E : (R = !1, E = a ? E : "/" + E)), a && !R && (E = E.replace(d, "\\")).substr(1, 2) === ":\\" && (E = E[0].toUpperCase() + E.substr(1)), E; + }; + }).call(this, t("_process")); + }, { _process: 66, url: 87 }], 19: [function(t, n, p) { + var s = t("js-yaml"), a = t("ono"); + n.exports = { parse: function(d, x) { + try { + return s.safeLoad(d); + } catch (m) { + throw m instanceof Error ? m : a(m, m.message); + } + }, stringify: function(d, x, m) { + try { + var h = (typeof m == "string" ? m.length : m) || 2; + return s.safeDump(d, { indent: h }); + } catch (y) { + throw y instanceof Error ? y : a(y, y.message); + } + } }; + }, { "js-yaml": 34, ono: 64 }], 20: [function(t, n, p) { + p.byteLength = E, p.toByteArray = M, p.fromByteArray = o; + for (var s = [], a = [], d = typeof Uint8Array < "u" ? Uint8Array : Array, x = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/", m = 0, h = x.length; m < h; ++m) s[m] = x[m], a[x.charCodeAt(m)] = m; + function y(c) { + var f = c.length; + if (f % 4 > 0) throw new Error("Invalid string. Length must be a multiple of 4"); + var b = c.indexOf("="); + return b === -1 && (b = f), [b, b === f ? 0 : 4 - b % 4]; + } + function E(c) { + var f = y(c), b = f[0], A = f[1]; + return 3 * (b + A) / 4 - A; + } + function g(c, f, b) { + return 3 * (f + b) / 4 - b; + } + function M(c) { + for (var f, b = y(c), A = b[0], _ = b[1], S = new d(g(c, A, _)), F = 0, D = _ > 0 ? A - 4 : A, H = 0; H < D; H += 4) f = a[c.charCodeAt(H)] << 18 | a[c.charCodeAt(H + 1)] << 12 | a[c.charCodeAt(H + 2)] << 6 | a[c.charCodeAt(H + 3)], S[F++] = f >> 16 & 255, S[F++] = f >> 8 & 255, S[F++] = 255 & f; + return _ === 2 && (f = a[c.charCodeAt(H)] << 2 | a[c.charCodeAt(H + 1)] >> 4, S[F++] = 255 & f), _ === 1 && (f = a[c.charCodeAt(H)] << 10 | a[c.charCodeAt(H + 1)] << 4 | a[c.charCodeAt(H + 2)] >> 2, S[F++] = f >> 8 & 255, S[F++] = 255 & f), S; + } + function R(c) { + return s[c >> 18 & 63] + s[c >> 12 & 63] + s[c >> 6 & 63] + s[63 & c]; + } + function l(c, f, b) { + for (var A, _ = [], S = f; S < b; S += 3) A = (c[S] << 16 & 16711680) + (c[S + 1] << 8 & 65280) + (255 & c[S + 2]), _.push(R(A)); + return _.join(""); + } + function o(c) { + for (var f, b = c.length, A = b % 3, _ = [], S = 0, F = b - A; S < F; S += 16383) _.push(l(c, S, S + 16383 > F ? F : S + 16383)); + return A === 1 ? (f = c[b - 1], _.push(s[f >> 2] + s[f << 4 & 63] + "==")) : A === 2 && (f = (c[b - 2] << 8) + c[b - 1], _.push(s[f >> 10] + s[f >> 4 & 63] + s[f << 2 & 63] + "=")), _.join(""); + } + a[45] = 62, a[95] = 63; + }, {}], 21: [function(t, n, p) { + }, {}], 22: [function(t, n, p) { + (function(s) { + (function(a) { + var d = typeof p == "object" && p && !p.nodeType && p, x = typeof n == "object" && n && !n.nodeType && n, m = typeof s == "object" && s; + m.global !== m && m.window !== m && m.self !== m || (a = m); + var h, y, E = 2147483647, g = 36, M = 1, R = 26, l = 38, o = 700, c = 72, f = 128, b = "-", A = /^xn--/, _ = /[^\x20-\x7E]/, S = /[\x2E\u3002\uFF0E\uFF61]/g, F = { overflow: "Overflow: input needs wider integers to process", "not-basic": "Illegal input >= 0x80 (not a basic code point)", "invalid-input": "Invalid input" }, D = g - M, H = Math.floor, j = String.fromCharCode; + function Q(P) { + throw new RangeError(F[P]); + } + function T(P, z) { + for (var ae = P.length, re = []; ae--; ) re[ae] = z(P[ae]); + return re; + } + function G(P, z) { + var ae = P.split("@"), re = ""; + return ae.length > 1 && (re = ae[0] + "@", P = ae[1]), re + T((P = P.replace(S, ".")).split("."), z).join("."); + } + function X(P) { + for (var z, ae, re = [], Y = 0, K = P.length; Y < K; ) (z = P.charCodeAt(Y++)) >= 55296 && z <= 56319 && Y < K ? (64512 & (ae = P.charCodeAt(Y++))) == 56320 ? re.push(((1023 & z) << 10) + (1023 & ae) + 65536) : (re.push(z), Y--) : re.push(z); + return re; + } + function fe(P) { + return T(P, function(z) { + var ae = ""; + return z > 65535 && (ae += j((z -= 65536) >>> 10 & 1023 | 55296), z = 56320 | 1023 & z), ae += j(z); + }).join(""); + } + function te(P, z) { + return P + 22 + 75 * (P < 26) - ((z != 0) << 5); + } + function me(P, z, ae) { + var re = 0; + for (P = ae ? H(P / o) : P >> 1, P += H(P / z); P > D * R >> 1; re += g) P = H(P / D); + return H(re + (D + 1) * P / (P + l)); + } + function ee(P) { + var z, ae, re, Y, K, se, ce, ve, pe, Se, Ee, Ce = [], B = P.length, U = 0, le = f, he = c; + for ((ae = P.lastIndexOf(b)) < 0 && (ae = 0), re = 0; re < ae; ++re) P.charCodeAt(re) >= 128 && Q("not-basic"), Ce.push(P.charCodeAt(re)); + for (Y = ae > 0 ? ae + 1 : 0; Y < B; ) { + for (K = U, se = 1, ce = g; Y >= B && Q("invalid-input"), ((ve = (Ee = P.charCodeAt(Y++)) - 48 < 10 ? Ee - 22 : Ee - 65 < 26 ? Ee - 65 : Ee - 97 < 26 ? Ee - 97 : g) >= g || ve > H((E - U) / se)) && Q("overflow"), U += ve * se, !(ve < (pe = ce <= he ? M : ce >= he + R ? R : ce - he)); ce += g) se > H(E / (Se = g - pe)) && Q("overflow"), se *= Se; + he = me(U - K, z = Ce.length + 1, K == 0), H(U / z) > E - le && Q("overflow"), le += H(U / z), U %= z, Ce.splice(U++, 0, le); + } + return fe(Ce); + } + function de(P) { + var z, ae, re, Y, K, se, ce, ve, pe, Se, Ee, Ce, B, U, le, he = []; + for (Ce = (P = X(P)).length, z = f, ae = 0, K = c, se = 0; se < Ce; ++se) (Ee = P[se]) < 128 && he.push(j(Ee)); + for (re = Y = he.length, Y && he.push(b); re < Ce; ) { + for (ce = E, se = 0; se < Ce; ++se) (Ee = P[se]) >= z && Ee < ce && (ce = Ee); + for (ce - z > H((E - ae) / (B = re + 1)) && Q("overflow"), ae += (ce - z) * B, z = ce, se = 0; se < Ce; ++se) if ((Ee = P[se]) < z && ++ae > E && Q("overflow"), Ee == z) { + for (ve = ae, pe = g; !(ve < (Se = pe <= K ? M : pe >= K + R ? R : pe - K)); pe += g) le = ve - Se, U = g - Se, he.push(j(te(Se + le % U, 0))), ve = H(le / U); + he.push(j(te(ve, 0))), K = me(ae, B, re == Y), ae = 0, ++re; + } + ++ae, ++z; + } + return he.join(""); + } + if (h = { version: "1.4.1", ucs2: { decode: X, encode: fe }, decode: ee, encode: de, toASCII: function(P) { + return G(P, function(z) { + return _.test(z) ? "xn--" + de(z) : z; + }); + }, toUnicode: function(P) { + return G(P, function(z) { + return A.test(z) ? ee(z.slice(4).toLowerCase()) : z; + }); + } }, d && x) if (n.exports == d) x.exports = h; + else for (y in h) h.hasOwnProperty(y) && (d[y] = h[y]); + else a.punycode = h; + })(this); + }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); + }, {}], 23: [function(t, n, p) { + var s = t("base64-js"), a = t("ieee754"); + p.Buffer = h, p.SlowBuffer = b, p.INSPECT_MAX_BYTES = 50; + var d = 2147483647; + function x() { + try { + var u = new Uint8Array(1); + return u.__proto__ = { __proto__: Uint8Array.prototype, foo: function() { + return 42; + } }, u.foo() === 42; + } catch { + return !1; + } + } + function m(u) { + if (u > d) throw new RangeError('The value "' + u + '" is invalid for option "size"'); + var w = new Uint8Array(u); + return w.__proto__ = h.prototype, w; + } + function h(u, w, k) { + if (typeof u == "number") { + if (typeof w == "string") throw new TypeError('The "string" argument must be of type string. Received type number'); + return M(u); + } + return y(u, w, k); + } + function y(u, w, k) { + if (typeof u == "string") return R(u, w); + if (ArrayBuffer.isView(u)) return l(u); + if (u == null) throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof u); + if (he(u, ArrayBuffer) || u && he(u.buffer, ArrayBuffer)) return o(u, w, k); + if (typeof u == "number") throw new TypeError('The "value" argument must not be of type number. Received type number'); + var q = u.valueOf && u.valueOf(); + if (q != null && q !== u) return h.from(q, w, k); + var ne = c(u); + if (ne) return ne; + if (typeof Symbol < "u" && Symbol.toPrimitive != null && typeof u[Symbol.toPrimitive] == "function") return h.from(u[Symbol.toPrimitive]("string"), w, k); + throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type " + typeof u); + } + function E(u) { + if (typeof u != "number") throw new TypeError('"size" argument must be of type number'); + if (u < 0) throw new RangeError('The value "' + u + '" is invalid for option "size"'); + } + function g(u, w, k) { + return E(u), u <= 0 ? m(u) : w !== void 0 ? typeof k == "string" ? m(u).fill(w, k) : m(u).fill(w) : m(u); + } + function M(u) { + return E(u), m(u < 0 ? 0 : 0 | f(u)); + } + function R(u, w) { + if (typeof w == "string" && w !== "" || (w = "utf8"), !h.isEncoding(w)) throw new TypeError("Unknown encoding: " + w); + var k = 0 | A(u, w), q = m(k), ne = q.write(u, w); + return ne !== k && (q = q.slice(0, ne)), q; + } + function l(u) { + for (var w = u.length < 0 ? 0 : 0 | f(u.length), k = m(w), q = 0; q < w; q += 1) k[q] = 255 & u[q]; + return k; + } + function o(u, w, k) { + if (w < 0 || u.byteLength < w) throw new RangeError('"offset" is outside of buffer bounds'); + if (u.byteLength < w + (k || 0)) throw new RangeError('"length" is outside of buffer bounds'); + var q; + return (q = w === void 0 && k === void 0 ? new Uint8Array(u) : k === void 0 ? new Uint8Array(u, w) : new Uint8Array(u, w, k)).__proto__ = h.prototype, q; + } + function c(u) { + if (h.isBuffer(u)) { + var w = 0 | f(u.length), k = m(w); + return k.length === 0 || u.copy(k, 0, 0, w), k; + } + return u.length !== void 0 ? typeof u.length != "number" || Te(u.length) ? m(0) : l(u) : u.type === "Buffer" && Array.isArray(u.data) ? l(u.data) : void 0; + } + function f(u) { + if (u >= d) throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x" + d.toString(16) + " bytes"); + return 0 | u; + } + function b(u) { + return +u != u && (u = 0), h.alloc(+u); + } + function A(u, w) { + if (h.isBuffer(u)) return u.length; + if (ArrayBuffer.isView(u) || he(u, ArrayBuffer)) return u.byteLength; + if (typeof u != "string") throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type ' + typeof u); + var k = u.length, q = arguments.length > 2 && arguments[2] === !0; + if (!q && k === 0) return 0; + for (var ne = !1; ; ) switch (w) { + case "ascii": + case "latin1": + case "binary": + return k; + case "utf8": + case "utf-8": + return Ee(u).length; + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return 2 * k; + case "hex": + return k >>> 1; + case "base64": + return U(u).length; + default: + if (ne) return q ? -1 : Ee(u).length; + w = ("" + w).toLowerCase(), ne = !0; + } + } + function _(u, w, k) { + var q = !1; + if ((w === void 0 || w < 0) && (w = 0), w > this.length || ((k === void 0 || k > this.length) && (k = this.length), k <= 0) || (k >>>= 0) <= (w >>>= 0)) return ""; + for (u || (u = "utf8"); ; ) switch (u) { + case "hex": + return z(this, w, k); + case "utf8": + case "utf-8": + return te(this, w, k); + case "ascii": + return de(this, w, k); + case "latin1": + case "binary": + return P(this, w, k); + case "base64": + return fe(this, w, k); + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return ae(this, w, k); + default: + if (q) throw new TypeError("Unknown encoding: " + u); + u = (u + "").toLowerCase(), q = !0; + } + } + function S(u, w, k) { + var q = u[w]; + u[w] = u[k], u[k] = q; + } + function F(u, w, k, q, ne) { + if (u.length === 0) return -1; + if (typeof k == "string" ? (q = k, k = 0) : k > 2147483647 ? k = 2147483647 : k < -2147483648 && (k = -2147483648), Te(k = +k) && (k = ne ? 0 : u.length - 1), k < 0 && (k = u.length + k), k >= u.length) { + if (ne) return -1; + k = u.length - 1; + } else if (k < 0) { + if (!ne) return -1; + k = 0; + } + if (typeof w == "string" && (w = h.from(w, q)), h.isBuffer(w)) return w.length === 0 ? -1 : D(u, w, k, q, ne); + if (typeof w == "number") return w &= 255, typeof Uint8Array.prototype.indexOf == "function" ? ne ? Uint8Array.prototype.indexOf.call(u, w, k) : Uint8Array.prototype.lastIndexOf.call(u, w, k) : D(u, [w], k, q, ne); + throw new TypeError("val must be string, number or Buffer"); + } + function D(u, w, k, q, ne) { + var ue, we = 1, L = u.length, C = w.length; + if (q !== void 0 && ((q = String(q).toLowerCase()) === "ucs2" || q === "ucs-2" || q === "utf16le" || q === "utf-16le")) { + if (u.length < 2 || w.length < 2) return -1; + we = 2, L /= 2, C /= 2, k /= 2; + } + function e(v, N) { + return we === 1 ? v[N] : v.readUInt16BE(N * we); + } + if (ne) { + var O = -1; + for (ue = k; ue < L; ue++) if (e(u, ue) === e(w, O === -1 ? 0 : ue - O)) { + if (O === -1 && (O = ue), ue - O + 1 === C) return O * we; + } else O !== -1 && (ue -= ue - O), O = -1; + } else for (k + C > L && (k = L - C), ue = k; ue >= 0; ue--) { + for (var I = !0, $ = 0; $ < C; $++) if (e(u, ue + $) !== e(w, $)) { + I = !1; + break; + } + if (I) return ue; + } + return -1; + } + function H(u, w, k, q) { + k = Number(k) || 0; + var ne = u.length - k; + q ? (q = Number(q)) > ne && (q = ne) : q = ne; + var ue = w.length; + q > ue / 2 && (q = ue / 2); + for (var we = 0; we < q; ++we) { + var L = parseInt(w.substr(2 * we, 2), 16); + if (Te(L)) return we; + u[k + we] = L; + } + return we; + } + function j(u, w, k, q) { + return le(Ee(w, u.length - k), u, k, q); + } + function Q(u, w, k, q) { + return le(Ce(w), u, k, q); + } + function T(u, w, k, q) { + return Q(u, w, k, q); + } + function G(u, w, k, q) { + return le(U(w), u, k, q); + } + function X(u, w, k, q) { + return le(B(w, u.length - k), u, k, q); + } + function fe(u, w, k) { + return w === 0 && k === u.length ? s.fromByteArray(u) : s.fromByteArray(u.slice(w, k)); + } + function te(u, w, k) { + k = Math.min(u.length, k); + for (var q = [], ne = w; ne < k; ) { + var ue, we, L, C, e = u[ne], O = null, I = e > 239 ? 4 : e > 223 ? 3 : e > 191 ? 2 : 1; + if (ne + I <= k) switch (I) { + case 1: + e < 128 && (O = e); + break; + case 2: + (192 & (ue = u[ne + 1])) == 128 && (C = (31 & e) << 6 | 63 & ue) > 127 && (O = C); + break; + case 3: + ue = u[ne + 1], we = u[ne + 2], (192 & ue) == 128 && (192 & we) == 128 && (C = (15 & e) << 12 | (63 & ue) << 6 | 63 & we) > 2047 && (C < 55296 || C > 57343) && (O = C); + break; + case 4: + ue = u[ne + 1], we = u[ne + 2], L = u[ne + 3], (192 & ue) == 128 && (192 & we) == 128 && (192 & L) == 128 && (C = (15 & e) << 18 | (63 & ue) << 12 | (63 & we) << 6 | 63 & L) > 65535 && C < 1114112 && (O = C); + } + O === null ? (O = 65533, I = 1) : O > 65535 && (O -= 65536, q.push(O >>> 10 & 1023 | 55296), O = 56320 | 1023 & O), q.push(O), ne += I; + } + return ee(q); + } + p.kMaxLength = d, h.TYPED_ARRAY_SUPPORT = x(), h.TYPED_ARRAY_SUPPORT || typeof console > "u" || typeof console.error != "function" || console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."), Object.defineProperty(h.prototype, "parent", { enumerable: !0, get: function() { + if (h.isBuffer(this)) return this.buffer; + } }), Object.defineProperty(h.prototype, "offset", { enumerable: !0, get: function() { + if (h.isBuffer(this)) return this.byteOffset; + } }), typeof Symbol < "u" && Symbol.species != null && h[Symbol.species] === h && Object.defineProperty(h, Symbol.species, { value: null, configurable: !0, enumerable: !1, writable: !1 }), h.poolSize = 8192, h.from = function(u, w, k) { + return y(u, w, k); + }, h.prototype.__proto__ = Uint8Array.prototype, h.__proto__ = Uint8Array, h.alloc = function(u, w, k) { + return g(u, w, k); + }, h.allocUnsafe = function(u) { + return M(u); + }, h.allocUnsafeSlow = function(u) { + return M(u); + }, h.isBuffer = function(u) { + return u != null && u._isBuffer === !0 && u !== h.prototype; + }, h.compare = function(u, w) { + if (he(u, Uint8Array) && (u = h.from(u, u.offset, u.byteLength)), he(w, Uint8Array) && (w = h.from(w, w.offset, w.byteLength)), !h.isBuffer(u) || !h.isBuffer(w)) throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array'); + if (u === w) return 0; + for (var k = u.length, q = w.length, ne = 0, ue = Math.min(k, q); ne < ue; ++ne) if (u[ne] !== w[ne]) { + k = u[ne], q = w[ne]; + break; + } + return k < q ? -1 : q < k ? 1 : 0; + }, h.isEncoding = function(u) { + switch (String(u).toLowerCase()) { + case "hex": + case "utf8": + case "utf-8": + case "ascii": + case "latin1": + case "binary": + case "base64": + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return !0; + default: + return !1; + } + }, h.concat = function(u, w) { + if (!Array.isArray(u)) throw new TypeError('"list" argument must be an Array of Buffers'); + if (u.length === 0) return h.alloc(0); + var k; + if (w === void 0) for (w = 0, k = 0; k < u.length; ++k) w += u[k].length; + var q = h.allocUnsafe(w), ne = 0; + for (k = 0; k < u.length; ++k) { + var ue = u[k]; + if (he(ue, Uint8Array) && (ue = h.from(ue)), !h.isBuffer(ue)) throw new TypeError('"list" argument must be an Array of Buffers'); + ue.copy(q, ne), ne += ue.length; + } + return q; + }, h.byteLength = A, h.prototype._isBuffer = !0, h.prototype.swap16 = function() { + var u = this.length; + if (u % 2 != 0) throw new RangeError("Buffer size must be a multiple of 16-bits"); + for (var w = 0; w < u; w += 2) S(this, w, w + 1); + return this; + }, h.prototype.swap32 = function() { + var u = this.length; + if (u % 4 != 0) throw new RangeError("Buffer size must be a multiple of 32-bits"); + for (var w = 0; w < u; w += 4) S(this, w, w + 3), S(this, w + 1, w + 2); + return this; + }, h.prototype.swap64 = function() { + var u = this.length; + if (u % 8 != 0) throw new RangeError("Buffer size must be a multiple of 64-bits"); + for (var w = 0; w < u; w += 8) S(this, w, w + 7), S(this, w + 1, w + 6), S(this, w + 2, w + 5), S(this, w + 3, w + 4); + return this; + }, h.prototype.toString = function() { + var u = this.length; + return u === 0 ? "" : arguments.length === 0 ? te(this, 0, u) : _.apply(this, arguments); + }, h.prototype.toLocaleString = h.prototype.toString, h.prototype.equals = function(u) { + if (!h.isBuffer(u)) throw new TypeError("Argument must be a Buffer"); + return this === u || h.compare(this, u) === 0; + }, h.prototype.inspect = function() { + var u = "", w = p.INSPECT_MAX_BYTES; + return u = this.toString("hex", 0, w).replace(/(.{2})/g, "$1 ").trim(), this.length > w && (u += " ... "), ""; + }, h.prototype.compare = function(u, w, k, q, ne) { + if (he(u, Uint8Array) && (u = h.from(u, u.offset, u.byteLength)), !h.isBuffer(u)) throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type ' + typeof u); + if (w === void 0 && (w = 0), k === void 0 && (k = u ? u.length : 0), q === void 0 && (q = 0), ne === void 0 && (ne = this.length), w < 0 || k > u.length || q < 0 || ne > this.length) throw new RangeError("out of range index"); + if (q >= ne && w >= k) return 0; + if (q >= ne) return -1; + if (w >= k) return 1; + if (this === u) return 0; + for (var ue = (ne >>>= 0) - (q >>>= 0), we = (k >>>= 0) - (w >>>= 0), L = Math.min(ue, we), C = this.slice(q, ne), e = u.slice(w, k), O = 0; O < L; ++O) if (C[O] !== e[O]) { + ue = C[O], we = e[O]; + break; + } + return ue < we ? -1 : we < ue ? 1 : 0; + }, h.prototype.includes = function(u, w, k) { + return this.indexOf(u, w, k) !== -1; + }, h.prototype.indexOf = function(u, w, k) { + return F(this, u, w, k, !0); + }, h.prototype.lastIndexOf = function(u, w, k) { + return F(this, u, w, k, !1); + }, h.prototype.write = function(u, w, k, q) { + if (w === void 0) q = "utf8", k = this.length, w = 0; + else if (k === void 0 && typeof w == "string") q = w, k = this.length, w = 0; + else { + if (!isFinite(w)) throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported"); + w >>>= 0, isFinite(k) ? (k >>>= 0, q === void 0 && (q = "utf8")) : (q = k, k = void 0); + } + var ne = this.length - w; + if ((k === void 0 || k > ne) && (k = ne), u.length > 0 && (k < 0 || w < 0) || w > this.length) throw new RangeError("Attempt to write outside buffer bounds"); + q || (q = "utf8"); + for (var ue = !1; ; ) switch (q) { + case "hex": + return H(this, u, w, k); + case "utf8": + case "utf-8": + return j(this, u, w, k); + case "ascii": + return Q(this, u, w, k); + case "latin1": + case "binary": + return T(this, u, w, k); + case "base64": + return G(this, u, w, k); + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return X(this, u, w, k); + default: + if (ue) throw new TypeError("Unknown encoding: " + q); + q = ("" + q).toLowerCase(), ue = !0; + } + }, h.prototype.toJSON = function() { + return { type: "Buffer", data: Array.prototype.slice.call(this._arr || this, 0) }; + }; + var me = 4096; + function ee(u) { + var w = u.length; + if (w <= me) return String.fromCharCode.apply(String, u); + for (var k = "", q = 0; q < w; ) k += String.fromCharCode.apply(String, u.slice(q, q += me)); + return k; + } + function de(u, w, k) { + var q = ""; + k = Math.min(u.length, k); + for (var ne = w; ne < k; ++ne) q += String.fromCharCode(127 & u[ne]); + return q; + } + function P(u, w, k) { + var q = ""; + k = Math.min(u.length, k); + for (var ne = w; ne < k; ++ne) q += String.fromCharCode(u[ne]); + return q; + } + function z(u, w, k) { + var q = u.length; + (!w || w < 0) && (w = 0), (!k || k < 0 || k > q) && (k = q); + for (var ne = "", ue = w; ue < k; ++ue) ne += Se(u[ue]); + return ne; + } + function ae(u, w, k) { + for (var q = u.slice(w, k), ne = "", ue = 0; ue < q.length; ue += 2) ne += String.fromCharCode(q[ue] + 256 * q[ue + 1]); + return ne; + } + function re(u, w, k) { + if (u % 1 != 0 || u < 0) throw new RangeError("offset is not uint"); + if (u + w > k) throw new RangeError("Trying to access beyond buffer length"); + } + function Y(u, w, k, q, ne, ue) { + if (!h.isBuffer(u)) throw new TypeError('"buffer" argument must be a Buffer instance'); + if (w > ne || w < ue) throw new RangeError('"value" argument is out of bounds'); + if (k + q > u.length) throw new RangeError("Index out of range"); + } + function K(u, w, k, q, ne, ue) { + if (k + q > u.length) throw new RangeError("Index out of range"); + if (k < 0) throw new RangeError("Index out of range"); + } + function se(u, w, k, q, ne) { + return w = +w, k >>>= 0, ne || K(u, w, k, 4), a.write(u, w, k, q, 23, 4), k + 4; + } + function ce(u, w, k, q, ne) { + return w = +w, k >>>= 0, ne || K(u, w, k, 8), a.write(u, w, k, q, 52, 8), k + 8; + } + h.prototype.slice = function(u, w) { + var k = this.length; + (u = ~~u) < 0 ? (u += k) < 0 && (u = 0) : u > k && (u = k), (w = w === void 0 ? k : ~~w) < 0 ? (w += k) < 0 && (w = 0) : w > k && (w = k), w < u && (w = u); + var q = this.subarray(u, w); + return q.__proto__ = h.prototype, q; + }, h.prototype.readUIntLE = function(u, w, k) { + u >>>= 0, w >>>= 0, k || re(u, w, this.length); + for (var q = this[u], ne = 1, ue = 0; ++ue < w && (ne *= 256); ) q += this[u + ue] * ne; + return q; + }, h.prototype.readUIntBE = function(u, w, k) { + u >>>= 0, w >>>= 0, k || re(u, w, this.length); + for (var q = this[u + --w], ne = 1; w > 0 && (ne *= 256); ) q += this[u + --w] * ne; + return q; + }, h.prototype.readUInt8 = function(u, w) { + return u >>>= 0, w || re(u, 1, this.length), this[u]; + }, h.prototype.readUInt16LE = function(u, w) { + return u >>>= 0, w || re(u, 2, this.length), this[u] | this[u + 1] << 8; + }, h.prototype.readUInt16BE = function(u, w) { + return u >>>= 0, w || re(u, 2, this.length), this[u] << 8 | this[u + 1]; + }, h.prototype.readUInt32LE = function(u, w) { + return u >>>= 0, w || re(u, 4, this.length), (this[u] | this[u + 1] << 8 | this[u + 2] << 16) + 16777216 * this[u + 3]; + }, h.prototype.readUInt32BE = function(u, w) { + return u >>>= 0, w || re(u, 4, this.length), 16777216 * this[u] + (this[u + 1] << 16 | this[u + 2] << 8 | this[u + 3]); + }, h.prototype.readIntLE = function(u, w, k) { + u >>>= 0, w >>>= 0, k || re(u, w, this.length); + for (var q = this[u], ne = 1, ue = 0; ++ue < w && (ne *= 256); ) q += this[u + ue] * ne; + return q >= (ne *= 128) && (q -= Math.pow(2, 8 * w)), q; + }, h.prototype.readIntBE = function(u, w, k) { + u >>>= 0, w >>>= 0, k || re(u, w, this.length); + for (var q = w, ne = 1, ue = this[u + --q]; q > 0 && (ne *= 256); ) ue += this[u + --q] * ne; + return ue >= (ne *= 128) && (ue -= Math.pow(2, 8 * w)), ue; + }, h.prototype.readInt8 = function(u, w) { + return u >>>= 0, w || re(u, 1, this.length), 128 & this[u] ? -1 * (255 - this[u] + 1) : this[u]; + }, h.prototype.readInt16LE = function(u, w) { + u >>>= 0, w || re(u, 2, this.length); + var k = this[u] | this[u + 1] << 8; + return 32768 & k ? 4294901760 | k : k; + }, h.prototype.readInt16BE = function(u, w) { + u >>>= 0, w || re(u, 2, this.length); + var k = this[u + 1] | this[u] << 8; + return 32768 & k ? 4294901760 | k : k; + }, h.prototype.readInt32LE = function(u, w) { + return u >>>= 0, w || re(u, 4, this.length), this[u] | this[u + 1] << 8 | this[u + 2] << 16 | this[u + 3] << 24; + }, h.prototype.readInt32BE = function(u, w) { + return u >>>= 0, w || re(u, 4, this.length), this[u] << 24 | this[u + 1] << 16 | this[u + 2] << 8 | this[u + 3]; + }, h.prototype.readFloatLE = function(u, w) { + return u >>>= 0, w || re(u, 4, this.length), a.read(this, u, !0, 23, 4); + }, h.prototype.readFloatBE = function(u, w) { + return u >>>= 0, w || re(u, 4, this.length), a.read(this, u, !1, 23, 4); + }, h.prototype.readDoubleLE = function(u, w) { + return u >>>= 0, w || re(u, 8, this.length), a.read(this, u, !0, 52, 8); + }, h.prototype.readDoubleBE = function(u, w) { + return u >>>= 0, w || re(u, 8, this.length), a.read(this, u, !1, 52, 8); + }, h.prototype.writeUIntLE = function(u, w, k, q) { + u = +u, w >>>= 0, k >>>= 0, q || Y(this, u, w, k, Math.pow(2, 8 * k) - 1, 0); + var ne = 1, ue = 0; + for (this[w] = 255 & u; ++ue < k && (ne *= 256); ) this[w + ue] = u / ne & 255; + return w + k; + }, h.prototype.writeUIntBE = function(u, w, k, q) { + u = +u, w >>>= 0, k >>>= 0, q || Y(this, u, w, k, Math.pow(2, 8 * k) - 1, 0); + var ne = k - 1, ue = 1; + for (this[w + ne] = 255 & u; --ne >= 0 && (ue *= 256); ) this[w + ne] = u / ue & 255; + return w + k; + }, h.prototype.writeUInt8 = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 1, 255, 0), this[w] = 255 & u, w + 1; + }, h.prototype.writeUInt16LE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 2, 65535, 0), this[w] = 255 & u, this[w + 1] = u >>> 8, w + 2; + }, h.prototype.writeUInt16BE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 2, 65535, 0), this[w] = u >>> 8, this[w + 1] = 255 & u, w + 2; + }, h.prototype.writeUInt32LE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 4, 4294967295, 0), this[w + 3] = u >>> 24, this[w + 2] = u >>> 16, this[w + 1] = u >>> 8, this[w] = 255 & u, w + 4; + }, h.prototype.writeUInt32BE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 4, 4294967295, 0), this[w] = u >>> 24, this[w + 1] = u >>> 16, this[w + 2] = u >>> 8, this[w + 3] = 255 & u, w + 4; + }, h.prototype.writeIntLE = function(u, w, k, q) { + if (u = +u, w >>>= 0, !q) { + var ne = Math.pow(2, 8 * k - 1); + Y(this, u, w, k, ne - 1, -ne); + } + var ue = 0, we = 1, L = 0; + for (this[w] = 255 & u; ++ue < k && (we *= 256); ) u < 0 && L === 0 && this[w + ue - 1] !== 0 && (L = 1), this[w + ue] = (u / we >> 0) - L & 255; + return w + k; + }, h.prototype.writeIntBE = function(u, w, k, q) { + if (u = +u, w >>>= 0, !q) { + var ne = Math.pow(2, 8 * k - 1); + Y(this, u, w, k, ne - 1, -ne); + } + var ue = k - 1, we = 1, L = 0; + for (this[w + ue] = 255 & u; --ue >= 0 && (we *= 256); ) u < 0 && L === 0 && this[w + ue + 1] !== 0 && (L = 1), this[w + ue] = (u / we >> 0) - L & 255; + return w + k; + }, h.prototype.writeInt8 = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 1, 127, -128), u < 0 && (u = 255 + u + 1), this[w] = 255 & u, w + 1; + }, h.prototype.writeInt16LE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 2, 32767, -32768), this[w] = 255 & u, this[w + 1] = u >>> 8, w + 2; + }, h.prototype.writeInt16BE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 2, 32767, -32768), this[w] = u >>> 8, this[w + 1] = 255 & u, w + 2; + }, h.prototype.writeInt32LE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 4, 2147483647, -2147483648), this[w] = 255 & u, this[w + 1] = u >>> 8, this[w + 2] = u >>> 16, this[w + 3] = u >>> 24, w + 4; + }, h.prototype.writeInt32BE = function(u, w, k) { + return u = +u, w >>>= 0, k || Y(this, u, w, 4, 2147483647, -2147483648), u < 0 && (u = 4294967295 + u + 1), this[w] = u >>> 24, this[w + 1] = u >>> 16, this[w + 2] = u >>> 8, this[w + 3] = 255 & u, w + 4; + }, h.prototype.writeFloatLE = function(u, w, k) { + return se(this, u, w, !0, k); + }, h.prototype.writeFloatBE = function(u, w, k) { + return se(this, u, w, !1, k); + }, h.prototype.writeDoubleLE = function(u, w, k) { + return ce(this, u, w, !0, k); + }, h.prototype.writeDoubleBE = function(u, w, k) { + return ce(this, u, w, !1, k); + }, h.prototype.copy = function(u, w, k, q) { + if (!h.isBuffer(u)) throw new TypeError("argument should be a Buffer"); + if (k || (k = 0), q || q === 0 || (q = this.length), w >= u.length && (w = u.length), w || (w = 0), q > 0 && q < k && (q = k), q === k || u.length === 0 || this.length === 0) return 0; + if (w < 0) throw new RangeError("targetStart out of bounds"); + if (k < 0 || k >= this.length) throw new RangeError("Index out of range"); + if (q < 0) throw new RangeError("sourceEnd out of bounds"); + q > this.length && (q = this.length), u.length - w < q - k && (q = u.length - w + k); + var ne = q - k; + if (this === u && typeof Uint8Array.prototype.copyWithin == "function") this.copyWithin(w, k, q); + else if (this === u && k < w && w < q) for (var ue = ne - 1; ue >= 0; --ue) u[ue + w] = this[ue + k]; + else Uint8Array.prototype.set.call(u, this.subarray(k, q), w); + return ne; + }, h.prototype.fill = function(u, w, k, q) { + if (typeof u == "string") { + if (typeof w == "string" ? (q = w, w = 0, k = this.length) : typeof k == "string" && (q = k, k = this.length), q !== void 0 && typeof q != "string") throw new TypeError("encoding must be a string"); + if (typeof q == "string" && !h.isEncoding(q)) throw new TypeError("Unknown encoding: " + q); + if (u.length === 1) { + var ne = u.charCodeAt(0); + (q === "utf8" && ne < 128 || q === "latin1") && (u = ne); + } + } else typeof u == "number" && (u &= 255); + if (w < 0 || this.length < w || this.length < k) throw new RangeError("Out of range index"); + if (k <= w) return this; + var ue; + if (w >>>= 0, k = k === void 0 ? this.length : k >>> 0, u || (u = 0), typeof u == "number") for (ue = w; ue < k; ++ue) this[ue] = u; + else { + var we = h.isBuffer(u) ? u : h.from(u, q), L = we.length; + if (L === 0) throw new TypeError('The value "' + u + '" is invalid for argument "value"'); + for (ue = 0; ue < k - w; ++ue) this[ue + w] = we[ue % L]; + } + return this; + }; + var ve = /[^+\/0-9A-Za-z-_]/g; + function pe(u) { + if ((u = (u = u.split("=")[0]).trim().replace(ve, "")).length < 2) return ""; + for (; u.length % 4 != 0; ) u += "="; + return u; + } + function Se(u) { + return u < 16 ? "0" + u.toString(16) : u.toString(16); + } + function Ee(u, w) { + var k; + w = w || 1 / 0; + for (var q = u.length, ne = null, ue = [], we = 0; we < q; ++we) { + if ((k = u.charCodeAt(we)) > 55295 && k < 57344) { + if (!ne) { + if (k > 56319) { + (w -= 3) > -1 && ue.push(239, 191, 189); + continue; + } + if (we + 1 === q) { + (w -= 3) > -1 && ue.push(239, 191, 189); + continue; + } + ne = k; + continue; + } + if (k < 56320) { + (w -= 3) > -1 && ue.push(239, 191, 189), ne = k; + continue; + } + k = 65536 + (ne - 55296 << 10 | k - 56320); + } else ne && (w -= 3) > -1 && ue.push(239, 191, 189); + if (ne = null, k < 128) { + if ((w -= 1) < 0) break; + ue.push(k); + } else if (k < 2048) { + if ((w -= 2) < 0) break; + ue.push(k >> 6 | 192, 63 & k | 128); + } else if (k < 65536) { + if ((w -= 3) < 0) break; + ue.push(k >> 12 | 224, k >> 6 & 63 | 128, 63 & k | 128); + } else { + if (!(k < 1114112)) throw new Error("Invalid code point"); + if ((w -= 4) < 0) break; + ue.push(k >> 18 | 240, k >> 12 & 63 | 128, k >> 6 & 63 | 128, 63 & k | 128); + } + } + return ue; + } + function Ce(u) { + for (var w = [], k = 0; k < u.length; ++k) w.push(255 & u.charCodeAt(k)); + return w; + } + function B(u, w) { + for (var k, q, ne, ue = [], we = 0; we < u.length && !((w -= 2) < 0); ++we) q = (k = u.charCodeAt(we)) >> 8, ne = k % 256, ue.push(ne), ue.push(q); + return ue; + } + function U(u) { + return s.toByteArray(pe(u)); + } + function le(u, w, k, q) { + for (var ne = 0; ne < q && !(ne + k >= w.length || ne >= u.length); ++ne) w[ne + k] = u[ne]; + return ne; + } + function he(u, w) { + return u instanceof w || u != null && u.constructor != null && u.constructor.name != null && u.constructor.name === w.name; + } + function Te(u) { + return u != u; + } + }, { "base64-js": 20, ieee754: 30 }], 24: [function(t, n, p) { + n.exports = { 100: "Continue", 101: "Switching Protocols", 102: "Processing", 200: "OK", 201: "Created", 202: "Accepted", 203: "Non-Authoritative Information", 204: "No Content", 205: "Reset Content", 206: "Partial Content", 207: "Multi-Status", 208: "Already Reported", 226: "IM Used", 300: "Multiple Choices", 301: "Moved Permanently", 302: "Found", 303: "See Other", 304: "Not Modified", 305: "Use Proxy", 307: "Temporary Redirect", 308: "Permanent Redirect", 400: "Bad Request", 401: "Unauthorized", 402: "Payment Required", 403: "Forbidden", 404: "Not Found", 405: "Method Not Allowed", 406: "Not Acceptable", 407: "Proxy Authentication Required", 408: "Request Timeout", 409: "Conflict", 410: "Gone", 411: "Length Required", 412: "Precondition Failed", 413: "Payload Too Large", 414: "URI Too Long", 415: "Unsupported Media Type", 416: "Range Not Satisfiable", 417: "Expectation Failed", 418: "I'm a teapot", 421: "Misdirected Request", 422: "Unprocessable Entity", 423: "Locked", 424: "Failed Dependency", 425: "Unordered Collection", 426: "Upgrade Required", 428: "Precondition Required", 429: "Too Many Requests", 431: "Request Header Fields Too Large", 451: "Unavailable For Legal Reasons", 500: "Internal Server Error", 501: "Not Implemented", 502: "Bad Gateway", 503: "Service Unavailable", 504: "Gateway Timeout", 505: "HTTP Version Not Supported", 506: "Variant Also Negotiates", 507: "Insufficient Storage", 508: "Loop Detected", 509: "Bandwidth Limit Exceeded", 510: "Not Extended", 511: "Network Authentication Required" }; + }, {}], 25: [function(t, n, p) { + (function(s, a) { + var d = a.process && s.nextTick || a.setImmediate || function(x) { + setTimeout(x, 0); + }; + n.exports = function(x, m) { + return x ? void m.then(function(h) { + d(function() { + x(null, h); + }); + }, function(h) { + d(function() { + x(h); + }); + }) : m; + }; + }).call(this, t("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); + }, { _process: 66 }], 26: [function(t, n, p) { + (function(s) { + function a(A) { + return Array.isArray ? Array.isArray(A) : b(A) === "[object Array]"; + } + function d(A) { + return typeof A == "boolean"; + } + function x(A) { + return A === null; + } + function m(A) { + return A == null; + } + function h(A) { + return typeof A == "number"; + } + function y(A) { + return typeof A == "string"; + } + function E(A) { + return typeof A == "symbol"; + } + function g(A) { + return A === void 0; + } + function M(A) { + return b(A) === "[object RegExp]"; + } + function R(A) { + return typeof A == "object" && A !== null; + } + function l(A) { + return b(A) === "[object Date]"; + } + function o(A) { + return b(A) === "[object Error]" || A instanceof Error; + } + function c(A) { + return typeof A == "function"; + } + function f(A) { + return A === null || typeof A == "boolean" || typeof A == "number" || typeof A == "string" || typeof A == "symbol" || A === void 0; + } + function b(A) { + return Object.prototype.toString.call(A); + } + p.isArray = a, p.isBoolean = d, p.isNull = x, p.isNullOrUndefined = m, p.isNumber = h, p.isString = y, p.isSymbol = E, p.isUndefined = g, p.isRegExp = M, p.isObject = R, p.isDate = l, p.isError = o, p.isFunction = c, p.isPrimitive = f, p.isBuffer = s.isBuffer; + }).call(this, { isBuffer: t("../../is-buffer/index.js") }); + }, { "../../is-buffer/index.js": 32 }], 27: [function(t, n, p) { + var s = Object.create || H, a = Object.keys || j, d = Function.prototype.bind || Q; + function x() { + this._events && Object.prototype.hasOwnProperty.call(this, "_events") || (this._events = s(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0; + } + n.exports = x, x.EventEmitter = x, x.prototype._events = void 0, x.prototype._maxListeners = void 0; + var m, h = 10; + try { + var y = {}; + Object.defineProperty && Object.defineProperty(y, "x", { value: 0 }), m = y.x === 0; + } catch { + m = !1; + } + function E(T) { + return T._maxListeners === void 0 ? x.defaultMaxListeners : T._maxListeners; + } + function g(T, G, X) { + if (G) T.call(X); + else for (var fe = T.length, te = F(T, fe), me = 0; me < fe; ++me) te[me].call(X); + } + function M(T, G, X, fe) { + if (G) T.call(X, fe); + else for (var te = T.length, me = F(T, te), ee = 0; ee < te; ++ee) me[ee].call(X, fe); + } + function R(T, G, X, fe, te) { + if (G) T.call(X, fe, te); + else for (var me = T.length, ee = F(T, me), de = 0; de < me; ++de) ee[de].call(X, fe, te); + } + function l(T, G, X, fe, te, me) { + if (G) T.call(X, fe, te, me); + else for (var ee = T.length, de = F(T, ee), P = 0; P < ee; ++P) de[P].call(X, fe, te, me); + } + function o(T, G, X, fe) { + if (G) T.apply(X, fe); + else for (var te = T.length, me = F(T, te), ee = 0; ee < te; ++ee) me[ee].apply(X, fe); + } + function c(T, G, X, fe) { + var te, me, ee; + if (typeof X != "function") throw new TypeError('"listener" argument must be a function'); + if ((me = T._events) ? (me.newListener && (T.emit("newListener", G, X.listener ? X.listener : X), me = T._events), ee = me[G]) : (me = T._events = s(null), T._eventsCount = 0), ee) { + if (typeof ee == "function" ? ee = me[G] = fe ? [X, ee] : [ee, X] : fe ? ee.unshift(X) : ee.push(X), !ee.warned && (te = E(T)) && te > 0 && ee.length > te) { + ee.warned = !0; + var de = new Error("Possible EventEmitter memory leak detected. " + ee.length + ' "' + String(G) + '" listeners added. Use emitter.setMaxListeners() to increase limit.'); + de.name = "MaxListenersExceededWarning", de.emitter = T, de.type = G, de.count = ee.length, typeof console == "object" && console.warn && console.warn("%s: %s", de.name, de.message); + } + } else ee = me[G] = X, ++T._eventsCount; + return T; + } + function f() { + if (!this.fired) switch (this.target.removeListener(this.type, this.wrapFn), this.fired = !0, arguments.length) { + case 0: + return this.listener.call(this.target); + case 1: + return this.listener.call(this.target, arguments[0]); + case 2: + return this.listener.call(this.target, arguments[0], arguments[1]); + case 3: + return this.listener.call(this.target, arguments[0], arguments[1], arguments[2]); + default: + for (var T = new Array(arguments.length), G = 0; G < T.length; ++G) T[G] = arguments[G]; + this.listener.apply(this.target, T); + } + } + function b(T, G, X) { + var fe = { fired: !1, wrapFn: void 0, target: T, type: G, listener: X }, te = d.call(f, fe); + return te.listener = X, fe.wrapFn = te, te; + } + function A(T, G, X) { + var fe = T._events; + if (!fe) return []; + var te = fe[G]; + return te ? typeof te == "function" ? X ? [te.listener || te] : [te] : X ? D(te) : F(te, te.length) : []; + } + function _(T) { + var G = this._events; + if (G) { + var X = G[T]; + if (typeof X == "function") return 1; + if (X) return X.length; + } + return 0; + } + function S(T, G) { + for (var X = G, fe = X + 1, te = T.length; fe < te; X += 1, fe += 1) T[X] = T[fe]; + T.pop(); + } + function F(T, G) { + for (var X = new Array(G), fe = 0; fe < G; ++fe) X[fe] = T[fe]; + return X; + } + function D(T) { + for (var G = new Array(T.length), X = 0; X < G.length; ++X) G[X] = T[X].listener || T[X]; + return G; + } + function H(T) { + var G = function() { + }; + return G.prototype = T, new G(); + } + function j(T) { + var G = []; + for (var X in T) Object.prototype.hasOwnProperty.call(T, X) && G.push(X); + return X; + } + function Q(T) { + var G = this; + return function() { + return G.apply(T, arguments); + }; + } + m ? Object.defineProperty(x, "defaultMaxListeners", { enumerable: !0, get: function() { + return h; + }, set: function(T) { + if (typeof T != "number" || T < 0 || T != T) throw new TypeError('"defaultMaxListeners" must be a positive number'); + h = T; + } }) : x.defaultMaxListeners = h, x.prototype.setMaxListeners = function(T) { + if (typeof T != "number" || T < 0 || isNaN(T)) throw new TypeError('"n" argument must be a positive number'); + return this._maxListeners = T, this; + }, x.prototype.getMaxListeners = function() { + return E(this); + }, x.prototype.emit = function(T) { + var G, X, fe, te, me, ee, de = T === "error"; + if (ee = this._events) de = de && ee.error == null; + else if (!de) return !1; + if (de) { + if (arguments.length > 1 && (G = arguments[1]), G instanceof Error) throw G; + var P = new Error('Unhandled "error" event. (' + G + ")"); + throw P.context = G, P; + } + if (!(X = ee[T])) return !1; + var z = typeof X == "function"; + switch (fe = arguments.length) { + case 1: + g(X, z, this); + break; + case 2: + M(X, z, this, arguments[1]); + break; + case 3: + R(X, z, this, arguments[1], arguments[2]); + break; + case 4: + l(X, z, this, arguments[1], arguments[2], arguments[3]); + break; + default: + for (te = new Array(fe - 1), me = 1; me < fe; me++) te[me - 1] = arguments[me]; + o(X, z, this, te); + } + return !0; + }, x.prototype.addListener = function(T, G) { + return c(this, T, G, !1); + }, x.prototype.on = x.prototype.addListener, x.prototype.prependListener = function(T, G) { + return c(this, T, G, !0); + }, x.prototype.once = function(T, G) { + if (typeof G != "function") throw new TypeError('"listener" argument must be a function'); + return this.on(T, b(this, T, G)), this; + }, x.prototype.prependOnceListener = function(T, G) { + if (typeof G != "function") throw new TypeError('"listener" argument must be a function'); + return this.prependListener(T, b(this, T, G)), this; + }, x.prototype.removeListener = function(T, G) { + var X, fe, te, me, ee; + if (typeof G != "function") throw new TypeError('"listener" argument must be a function'); + if (!(fe = this._events)) return this; + if (!(X = fe[T])) return this; + if (X === G || X.listener === G) --this._eventsCount == 0 ? this._events = s(null) : (delete fe[T], fe.removeListener && this.emit("removeListener", T, X.listener || G)); + else if (typeof X != "function") { + for (te = -1, me = X.length - 1; me >= 0; me--) if (X[me] === G || X[me].listener === G) { + ee = X[me].listener, te = me; + break; + } + if (te < 0) return this; + te === 0 ? X.shift() : S(X, te), X.length === 1 && (fe[T] = X[0]), fe.removeListener && this.emit("removeListener", T, ee || G); + } + return this; + }, x.prototype.removeAllListeners = function(T) { + var G, X, fe; + if (!(X = this._events)) return this; + if (!X.removeListener) return arguments.length === 0 ? (this._events = s(null), this._eventsCount = 0) : X[T] && (--this._eventsCount == 0 ? this._events = s(null) : delete X[T]), this; + if (arguments.length === 0) { + var te, me = a(X); + for (fe = 0; fe < me.length; ++fe) (te = me[fe]) !== "removeListener" && this.removeAllListeners(te); + return this.removeAllListeners("removeListener"), this._events = s(null), this._eventsCount = 0, this; + } + if (typeof (G = X[T]) == "function") this.removeListener(T, G); + else if (G) for (fe = G.length - 1; fe >= 0; fe--) this.removeListener(T, G[fe]); + return this; + }, x.prototype.listeners = function(T) { + return A(this, T, !0); + }, x.prototype.rawListeners = function(T) { + return A(this, T, !1); + }, x.listenerCount = function(T, G) { + return typeof T.listenerCount == "function" ? T.listenerCount(G) : _.call(T, G); + }, x.prototype.listenerCount = _, x.prototype.eventNames = function() { + return this._eventsCount > 0 ? Reflect.ownKeys(this._events) : []; + }; + }, {}], 28: [function(t, n, p) { + function s(a) { + var d = Array.prototype.slice.call(arguments, 1); + return d.length && (a = a.replace(/(%?)(%([jds]))/g, function(x, m, h, y) { + var E = d.shift(); + switch (y) { + case "s": + E = "" + E; + break; + case "d": + E = Number(E); + break; + case "j": + E = JSON.stringify(E); + } + return m ? (d.unshift(E), x) : E; + })), d.length && (a += " " + d.join(" ")), "" + (a = a.replace(/%{2,2}/g, "%")); + } + n.exports = s; + }, {}], 29: [function(t, n, p) { + var s = t("http"), a = t("url"), d = n.exports; + for (var x in s) s.hasOwnProperty(x) && (d[x] = s[x]); + function m(h) { + if (typeof h == "string" && (h = a.parse(h)), h.protocol || (h.protocol = "https:"), h.protocol !== "https:") throw new Error('Protocol "' + h.protocol + '" not supported. Expected "https:"'); + return h; + } + d.request = function(h, y) { + return h = m(h), s.request.call(this, h, y); + }, d.get = function(h, y) { + return h = m(h), s.get.call(this, h, y); + }; + }, { http: 80, url: 87 }], 30: [function(t, n, p) { + p.read = function(s, a, d, x, m) { + var h, y, E = 8 * m - x - 1, g = (1 << E) - 1, M = g >> 1, R = -7, l = d ? m - 1 : 0, o = d ? -1 : 1, c = s[a + l]; + for (l += o, h = c & (1 << -R) - 1, c >>= -R, R += E; R > 0; h = 256 * h + s[a + l], l += o, R -= 8) ; + for (y = h & (1 << -R) - 1, h >>= -R, R += x; R > 0; y = 256 * y + s[a + l], l += o, R -= 8) ; + if (h === 0) h = 1 - M; + else { + if (h === g) return y ? NaN : 1 / 0 * (c ? -1 : 1); + y += Math.pow(2, x), h -= M; + } + return (c ? -1 : 1) * y * Math.pow(2, h - x); + }, p.write = function(s, a, d, x, m, h) { + var y, E, g, M = 8 * h - m - 1, R = (1 << M) - 1, l = R >> 1, o = m === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0, c = x ? 0 : h - 1, f = x ? 1 : -1, b = a < 0 || a === 0 && 1 / a < 0 ? 1 : 0; + for (a = Math.abs(a), isNaN(a) || a === 1 / 0 ? (E = isNaN(a) ? 1 : 0, y = R) : (y = Math.floor(Math.log(a) / Math.LN2), a * (g = Math.pow(2, -y)) < 1 && (y--, g *= 2), (a += y + l >= 1 ? o / g : o * Math.pow(2, 1 - l)) * g >= 2 && (y++, g /= 2), y + l >= R ? (E = 0, y = R) : y + l >= 1 ? (E = (a * g - 1) * Math.pow(2, m), y += l) : (E = a * Math.pow(2, l - 1) * Math.pow(2, m), y = 0)); m >= 8; s[d + c] = 255 & E, c += f, E /= 256, m -= 8) ; + for (y = y << m | E, M += m; M > 0; s[d + c] = 255 & y, c += f, y /= 256, M -= 8) ; + s[d + c - f] |= 128 * b; + }; + }, {}], 31: [function(t, n, p) { + typeof Object.create == "function" ? n.exports = function(s, a) { + s.super_ = a, s.prototype = Object.create(a.prototype, { constructor: { value: s, enumerable: !1, writable: !0, configurable: !0 } }); + } : n.exports = function(s, a) { + s.super_ = a; + var d = function() { + }; + d.prototype = a.prototype, s.prototype = new d(), s.prototype.constructor = s; + }; + }, {}], 32: [function(t, n, p) { + function s(d) { + return !!d.constructor && typeof d.constructor.isBuffer == "function" && d.constructor.isBuffer(d); + } + function a(d) { + return typeof d.readFloatLE == "function" && typeof d.slice == "function" && s(d.slice(0, 0)); + } + n.exports = function(d) { + return d != null && (s(d) || a(d) || !!d._isBuffer); + }; + }, {}], 33: [function(t, n, p) { + var s = {}.toString; + n.exports = Array.isArray || function(a) { + return s.call(a) == "[object Array]"; + }; + }, {}], 34: [function(t, n, p) { + var s = t("./lib/js-yaml.js"); + n.exports = s; + }, { "./lib/js-yaml.js": 35 }], 35: [function(t, n, p) { + var s = t("./js-yaml/loader"), a = t("./js-yaml/dumper"); + function d(x) { + return function() { + throw new Error("Function " + x + " is deprecated and cannot be used."); + }; + } + n.exports.Type = t("./js-yaml/type"), n.exports.Schema = t("./js-yaml/schema"), n.exports.FAILSAFE_SCHEMA = t("./js-yaml/schema/failsafe"), n.exports.JSON_SCHEMA = t("./js-yaml/schema/json"), n.exports.CORE_SCHEMA = t("./js-yaml/schema/core"), n.exports.DEFAULT_SAFE_SCHEMA = t("./js-yaml/schema/default_safe"), n.exports.DEFAULT_FULL_SCHEMA = t("./js-yaml/schema/default_full"), n.exports.load = s.load, n.exports.loadAll = s.loadAll, n.exports.safeLoad = s.safeLoad, n.exports.safeLoadAll = s.safeLoadAll, n.exports.dump = a.dump, n.exports.safeDump = a.safeDump, n.exports.YAMLException = t("./js-yaml/exception"), n.exports.MINIMAL_SCHEMA = t("./js-yaml/schema/failsafe"), n.exports.SAFE_SCHEMA = t("./js-yaml/schema/default_safe"), n.exports.DEFAULT_SCHEMA = t("./js-yaml/schema/default_full"), n.exports.scan = d("scan"), n.exports.parse = d("parse"), n.exports.compose = d("compose"), n.exports.addConstructor = d("addConstructor"); + }, { "./js-yaml/dumper": 37, "./js-yaml/exception": 38, "./js-yaml/loader": 39, "./js-yaml/schema": 41, "./js-yaml/schema/core": 42, "./js-yaml/schema/default_full": 43, "./js-yaml/schema/default_safe": 44, "./js-yaml/schema/failsafe": 45, "./js-yaml/schema/json": 46, "./js-yaml/type": 47 }], 36: [function(t, n, p) { + function s(y) { + return y == null; + } + function a(y) { + return typeof y == "object" && y !== null; + } + function d(y) { + return Array.isArray(y) ? y : s(y) ? [] : [y]; + } + function x(y, E) { + var g, M, R, l; + if (E) for (g = 0, M = (l = Object.keys(E)).length; g < M; g += 1) y[R = l[g]] = E[R]; + return y; + } + function m(y, E) { + var g, M = ""; + for (g = 0; g < E; g += 1) M += y; + return M; + } + function h(y) { + return y === 0 && Number.NEGATIVE_INFINITY === 1 / y; + } + n.exports.isNothing = s, n.exports.isObject = a, n.exports.toArray = d, n.exports.repeat = m, n.exports.isNegativeZero = h, n.exports.extend = x; + }, {}], 37: [function(t, n, p) { + var s = t("./common"), a = t("./exception"), d = t("./schema/default_full"), x = t("./schema/default_safe"), m = Object.prototype.toString, h = Object.prototype.hasOwnProperty, y = 9, E = 10, g = 32, M = 33, R = 34, l = 35, o = 37, c = 38, f = 39, b = 42, A = 44, _ = 45, S = 58, F = 62, D = 63, H = 64, j = 91, Q = 93, T = 96, G = 123, X = 124, fe = 125, te = { 0: "\\0", 7: "\\a", 8: "\\b", 9: "\\t", 10: "\\n", 11: "\\v", 12: "\\f", 13: "\\r", 27: "\\e", 34: '\\"', 92: "\\\\", 133: "\\N", 160: "\\_", 8232: "\\L", 8233: "\\P" }, me = ["y", "Y", "yes", "Yes", "YES", "on", "On", "ON", "n", "N", "no", "No", "NO", "off", "Off", "OFF"]; + function ee(v, N) { + var W, V, J, Z, ie, oe, ge; + if (N === null) return {}; + for (W = {}, J = 0, Z = (V = Object.keys(N)).length; J < Z; J += 1) ie = V[J], oe = String(N[ie]), ie.slice(0, 2) === "!!" && (ie = "tag:yaml.org,2002:" + ie.slice(2)), (ge = v.compiledTypeMap.fallback[ie]) && h.call(ge.styleAliases, oe) && (oe = ge.styleAliases[oe]), W[ie] = oe; + return W; + } + function de(v) { + var N, W, V; + if (N = v.toString(16).toUpperCase(), v <= 255) W = "x", V = 2; + else if (v <= 65535) W = "u", V = 4; + else { + if (!(v <= 4294967295)) throw new a("code point within a string may not be greater than 0xFFFFFFFF"); + W = "U", V = 8; + } + return "\\" + W + s.repeat("0", V - N.length) + N; + } + function P(v) { + this.schema = v.schema || d, this.indent = Math.max(1, v.indent || 2), this.noArrayIndent = v.noArrayIndent || !1, this.skipInvalid = v.skipInvalid || !1, this.flowLevel = s.isNothing(v.flowLevel) ? -1 : v.flowLevel, this.styleMap = ee(this.schema, v.styles || null), this.sortKeys = v.sortKeys || !1, this.lineWidth = v.lineWidth || 80, this.noRefs = v.noRefs || !1, this.noCompatMode = v.noCompatMode || !1, this.condenseFlow = v.condenseFlow || !1, this.implicitTypes = this.schema.compiledImplicit, this.explicitTypes = this.schema.compiledExplicit, this.tag = null, this.result = "", this.duplicates = [], this.usedDuplicates = null; + } + function z(v, N) { + for (var W, V = s.repeat(" ", N), J = 0, Z = -1, ie = "", oe = v.length; J < oe; ) (Z = v.indexOf(` +`, J)) === -1 ? (W = v.slice(J), J = oe) : (W = v.slice(J, Z + 1), J = Z + 1), W.length && W !== ` +` && (ie += V), ie += W; + return ie; + } + function ae(v, N) { + return ` +` + s.repeat(" ", v.indent * N); + } + function re(v, N) { + var W, V; + for (W = 0, V = v.implicitTypes.length; W < V; W += 1) if (v.implicitTypes[W].resolve(N)) return !0; + return !1; + } + function Y(v) { + return v === g || v === y; + } + function K(v) { + return 32 <= v && v <= 126 || 161 <= v && v <= 55295 && v !== 8232 && v !== 8233 || 57344 <= v && v <= 65533 && v !== 65279 || 65536 <= v && v <= 1114111; + } + function se(v) { + return K(v) && v !== 65279 && v !== A && v !== j && v !== Q && v !== G && v !== fe && v !== S && v !== l; + } + function ce(v) { + return K(v) && v !== 65279 && !Y(v) && v !== _ && v !== D && v !== S && v !== A && v !== j && v !== Q && v !== G && v !== fe && v !== l && v !== c && v !== b && v !== M && v !== X && v !== F && v !== f && v !== R && v !== o && v !== H && v !== T; + } + function ve(v) { + return /^\n* /.test(v); + } + var pe = 1, Se = 2, Ee = 3, Ce = 4, B = 5; + function U(v, N, W, V, J) { + var Z, ie, oe = !1, ge = !1, ye = V !== -1, be = -1, Ae = ce(v.charCodeAt(0)) && !Y(v.charCodeAt(v.length - 1)); + if (N) for (Z = 0; Z < v.length; Z++) { + if (!K(ie = v.charCodeAt(Z))) return B; + Ae = Ae && se(ie); + } + else { + for (Z = 0; Z < v.length; Z++) { + if ((ie = v.charCodeAt(Z)) === E) oe = !0, ye && (ge = ge || Z - be - 1 > V && v[be + 1] !== " ", be = Z); + else if (!K(ie)) return B; + Ae = Ae && se(ie); + } + ge = ge || ye && Z - be - 1 > V && v[be + 1] !== " "; + } + return oe || ge ? W > 9 && ve(v) ? B : ge ? Ce : Ee : Ae && !J(v) ? pe : Se; + } + function le(v, N, W, V) { + v.dump = (function() { + if (N.length === 0) return "''"; + if (!v.noCompatMode && me.indexOf(N) !== -1) return "'" + N + "'"; + var J = v.indent * Math.max(1, W), Z = v.lineWidth === -1 ? -1 : Math.max(Math.min(v.lineWidth, 40), v.lineWidth - J), ie = V || v.flowLevel > -1 && W >= v.flowLevel; + switch (U(N, ie, v.indent, Z, function(oe) { + return re(v, oe); + })) { + case pe: + return N; + case Se: + return "'" + N.replace(/'/g, "''") + "'"; + case Ee: + return "|" + he(N, v.indent) + Te(z(N, J)); + case Ce: + return ">" + he(N, v.indent) + Te(z(u(N, Z), J)); + case B: + return '"' + k(N) + '"'; + default: + throw new a("impossible error: invalid scalar style"); + } + })(); + } + function he(v, N) { + var W = ve(v) ? String(N) : "", V = v[v.length - 1] === ` +`; + return W + (V && (v[v.length - 2] === ` +` || v === ` +`) ? "+" : V ? "" : "-") + ` +`; + } + function Te(v) { + return v[v.length - 1] === ` +` ? v.slice(0, -1) : v; + } + function u(v, N) { + for (var W, V, J, Z = /(\n+)([^\n]*)/g, ie = (W = (W = v.indexOf(` +`)) !== -1 ? W : v.length, Z.lastIndex = W, w(v.slice(0, W), N)), oe = v[0] === ` +` || v[0] === " "; J = Z.exec(v); ) { + var ge = J[1], ye = J[2]; + V = ye[0] === " ", ie += ge + (oe || V || ye === "" ? "" : ` +`) + w(ye, N), oe = V; + } + return ie; + } + function w(v, N) { + if (v === "" || v[0] === " ") return v; + for (var W, V, J = / [^ ]/g, Z = 0, ie = 0, oe = 0, ge = ""; W = J.exec(v); ) (oe = W.index) - Z > N && (V = ie > Z ? ie : oe, ge += ` +` + v.slice(Z, V), Z = V + 1), ie = oe; + return ge += ` +`, v.length - Z > N && ie > Z ? ge += v.slice(Z, ie) + ` +` + v.slice(ie + 1) : ge += v.slice(Z), ge.slice(1); + } + function k(v) { + for (var N, W, V, J = "", Z = 0; Z < v.length; Z++) (N = v.charCodeAt(Z)) >= 55296 && N <= 56319 && (W = v.charCodeAt(Z + 1)) >= 56320 && W <= 57343 ? (J += de(1024 * (N - 55296) + W - 56320 + 65536), Z++) : J += !(V = te[N]) && K(N) ? v[Z] : V || de(N); + return J; + } + function q(v, N, W) { + var V, J, Z = "", ie = v.tag; + for (V = 0, J = W.length; V < J; V += 1) C(v, N, W[V], !1, !1) && (V !== 0 && (Z += "," + (v.condenseFlow ? "" : " ")), Z += v.dump); + v.tag = ie, v.dump = "[" + Z + "]"; + } + function ne(v, N, W, V) { + var J, Z, ie = "", oe = v.tag; + for (J = 0, Z = W.length; J < Z; J += 1) C(v, N + 1, W[J], !0, !0) && (V && J === 0 || (ie += ae(v, N)), v.dump && E === v.dump.charCodeAt(0) ? ie += "-" : ie += "- ", ie += v.dump); + v.tag = oe, v.dump = ie || "[]"; + } + function ue(v, N, W) { + var V, J, Z, ie, oe, ge = "", ye = v.tag, be = Object.keys(W); + for (V = 0, J = be.length; V < J; V += 1) oe = v.condenseFlow ? '"' : "", V !== 0 && (oe += ", "), ie = W[Z = be[V]], C(v, N, Z, !1, !1) && (v.dump.length > 1024 && (oe += "? "), oe += v.dump + (v.condenseFlow ? '"' : "") + ":" + (v.condenseFlow ? "" : " "), C(v, N, ie, !1, !1) && (ge += oe += v.dump)); + v.tag = ye, v.dump = "{" + ge + "}"; + } + function we(v, N, W, V) { + var J, Z, ie, oe, ge, ye, be = "", Ae = v.tag, Oe = Object.keys(W); + if (v.sortKeys === !0) Oe.sort(); + else if (typeof v.sortKeys == "function") Oe.sort(v.sortKeys); + else if (v.sortKeys) throw new a("sortKeys must be a boolean or a function"); + for (J = 0, Z = Oe.length; J < Z; J += 1) ye = "", V && J === 0 || (ye += ae(v, N)), oe = W[ie = Oe[J]], C(v, N + 1, ie, !0, !0, !0) && ((ge = v.tag !== null && v.tag !== "?" || v.dump && v.dump.length > 1024) && (v.dump && E === v.dump.charCodeAt(0) ? ye += "?" : ye += "? "), ye += v.dump, ge && (ye += ae(v, N)), C(v, N + 1, oe, !0, ge) && (v.dump && E === v.dump.charCodeAt(0) ? ye += ":" : ye += ": ", be += ye += v.dump)); + v.tag = Ae, v.dump = be || "{}"; + } + function L(v, N, W) { + var V, J, Z, ie, oe, ge; + for (Z = 0, ie = (J = W ? v.explicitTypes : v.implicitTypes).length; Z < ie; Z += 1) if (((oe = J[Z]).instanceOf || oe.predicate) && (!oe.instanceOf || typeof N == "object" && N instanceof oe.instanceOf) && (!oe.predicate || oe.predicate(N))) { + if (v.tag = W ? oe.tag : "?", oe.represent) { + if (ge = v.styleMap[oe.tag] || oe.defaultStyle, m.call(oe.represent) === "[object Function]") V = oe.represent(N, ge); + else { + if (!h.call(oe.represent, ge)) throw new a("!<" + oe.tag + '> tag resolver accepts not "' + ge + '" style'); + V = oe.represent[ge](N, ge); + } + v.dump = V; + } + return !0; + } + return !1; + } + function C(v, N, W, V, J, Z) { + v.tag = null, v.dump = W, L(v, W, !1) || L(v, W, !0); + var ie = m.call(v.dump); + V && (V = v.flowLevel < 0 || v.flowLevel > N); + var oe, ge, ye = ie === "[object Object]" || ie === "[object Array]"; + if (ye && (ge = (oe = v.duplicates.indexOf(W)) !== -1), (v.tag !== null && v.tag !== "?" || ge || v.indent !== 2 && N > 0) && (J = !1), ge && v.usedDuplicates[oe]) v.dump = "*ref_" + oe; + else { + if (ye && ge && !v.usedDuplicates[oe] && (v.usedDuplicates[oe] = !0), ie === "[object Object]") V && Object.keys(v.dump).length !== 0 ? (we(v, N, v.dump, J), ge && (v.dump = "&ref_" + oe + v.dump)) : (ue(v, N, v.dump), ge && (v.dump = "&ref_" + oe + " " + v.dump)); + else if (ie === "[object Array]") { + var be = v.noArrayIndent ? N - 1 : N; + V && v.dump.length !== 0 ? (ne(v, be, v.dump, J), ge && (v.dump = "&ref_" + oe + v.dump)) : (q(v, be, v.dump), ge && (v.dump = "&ref_" + oe + " " + v.dump)); + } else { + if (ie !== "[object String]") { + if (v.skipInvalid) return !1; + throw new a("unacceptable kind of an object to dump " + ie); + } + v.tag !== "?" && le(v, v.dump, N, Z); + } + v.tag !== null && v.tag !== "?" && (v.dump = "!<" + v.tag + "> " + v.dump); + } + return !0; + } + function e(v, N) { + var W, V, J = [], Z = []; + for (O(v, J, Z), W = 0, V = Z.length; W < V; W += 1) N.duplicates.push(J[Z[W]]); + N.usedDuplicates = new Array(V); + } + function O(v, N, W) { + var V, J, Z; + if (v !== null && typeof v == "object") if ((J = N.indexOf(v)) !== -1) W.indexOf(J) === -1 && W.push(J); + else if (N.push(v), Array.isArray(v)) for (J = 0, Z = v.length; J < Z; J += 1) O(v[J], N, W); + else for (J = 0, Z = (V = Object.keys(v)).length; J < Z; J += 1) O(v[V[J]], N, W); + } + function I(v, N) { + var W = new P(N = N || {}); + return W.noRefs || e(v, W), C(W, 0, v, !0, !0) ? W.dump + ` +` : ""; + } + function $(v, N) { + return I(v, s.extend({ schema: x }, N)); + } + n.exports.dump = I, n.exports.safeDump = $; + }, { "./common": 36, "./exception": 38, "./schema/default_full": 43, "./schema/default_safe": 44 }], 38: [function(t, n, p) { + function s(a, d) { + Error.call(this), this.name = "YAMLException", this.reason = a, this.mark = d, this.message = (this.reason || "(unknown reason)") + (this.mark ? " " + this.mark.toString() : ""), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack || ""; + } + s.prototype = Object.create(Error.prototype), s.prototype.constructor = s, s.prototype.toString = function(a) { + var d = this.name + ": "; + return d += this.reason || "(unknown reason)", !a && this.mark && (d += " " + this.mark.toString()), d; + }, n.exports = s; + }, {}], 39: [function(t, n, p) { + var s = t("./common"), a = t("./exception"), d = t("./mark"), x = t("./schema/default_safe"), m = t("./schema/default_full"), h = Object.prototype.hasOwnProperty, y = 1, E = 2, g = 3, M = 4, R = 1, l = 2, o = 3, c = /[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/, f = /[\x85\u2028\u2029]/, b = /[,\[\]\{\}]/, A = /^(?:!|!!|![a-z\-]+!)$/i, _ = /^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i; + function S(e) { + return e === 10 || e === 13; + } + function F(e) { + return e === 9 || e === 32; + } + function D(e) { + return e === 9 || e === 32 || e === 10 || e === 13; + } + function H(e) { + return e === 44 || e === 91 || e === 93 || e === 123 || e === 125; + } + function j(e) { + var O; + return 48 <= e && e <= 57 ? e - 48 : 97 <= (O = 32 | e) && O <= 102 ? O - 97 + 10 : -1; + } + function Q(e) { + return e === 120 ? 2 : e === 117 ? 4 : e === 85 ? 8 : 0; + } + function T(e) { + return 48 <= e && e <= 57 ? e - 48 : -1; + } + function G(e) { + return e === 48 ? "\0" : e === 97 ? "\x07" : e === 98 ? "\b" : e === 116 || e === 9 ? " " : e === 110 ? ` +` : e === 118 ? "\v" : e === 102 ? "\f" : e === 114 ? "\r" : e === 101 ? "\x1B" : e === 32 ? " " : e === 34 ? '"' : e === 47 ? "/" : e === 92 ? "\\" : e === 78 ? "…" : e === 95 ? " " : e === 76 ? "\u2028" : e === 80 ? "\u2029" : ""; + } + function X(e) { + return e <= 65535 ? String.fromCharCode(e) : String.fromCharCode(55296 + (e - 65536 >> 10), 56320 + (e - 65536 & 1023)); + } + for (var fe = new Array(256), te = new Array(256), me = 0; me < 256; me++) fe[me] = G(me) ? 1 : 0, te[me] = G(me); + function ee(e, O) { + this.input = e, this.filename = O.filename || null, this.schema = O.schema || m, this.onWarning = O.onWarning || null, this.legacy = O.legacy || !1, this.json = O.json || !1, this.listener = O.listener || null, this.implicitTypes = this.schema.compiledImplicit, this.typeMap = this.schema.compiledTypeMap, this.length = e.length, this.position = 0, this.line = 0, this.lineStart = 0, this.lineIndent = 0, this.documents = []; + } + function de(e, O) { + return new a(O, new d(e.filename, e.input, e.position, e.line, e.position - e.lineStart)); + } + function P(e, O) { + throw de(e, O); + } + function z(e, O) { + e.onWarning && e.onWarning.call(null, de(e, O)); + } + var ae = { YAML: function(e, O, I) { + var $, v, N; + e.version !== null && P(e, "duplication of %YAML directive"), I.length !== 1 && P(e, "YAML directive accepts exactly one argument"), ($ = /^([0-9]+)\.([0-9]+)$/.exec(I[0])) === null && P(e, "ill-formed argument of the YAML directive"), v = parseInt($[1], 10), N = parseInt($[2], 10), v !== 1 && P(e, "unacceptable YAML version of the document"), e.version = I[0], e.checkLineBreaks = N < 2, N !== 1 && N !== 2 && z(e, "unsupported YAML version of the document"); + }, TAG: function(e, O, I) { + var $, v; + I.length !== 2 && P(e, "TAG directive accepts exactly two arguments"), $ = I[0], v = I[1], A.test($) || P(e, "ill-formed tag handle (first argument) of the TAG directive"), h.call(e.tagMap, $) && P(e, 'there is a previously declared suffix for "' + $ + '" tag handle'), _.test(v) || P(e, "ill-formed tag prefix (second argument) of the TAG directive"), e.tagMap[$] = v; + } }; + function re(e, O, I, $) { + var v, N, W, V; + if (O < I) { + if (V = e.input.slice(O, I), $) for (v = 0, N = V.length; v < N; v += 1) (W = V.charCodeAt(v)) === 9 || 32 <= W && W <= 1114111 || P(e, "expected valid JSON character"); + else c.test(V) && P(e, "the stream contains non-printable characters"); + e.result += V; + } + } + function Y(e, O, I, $) { + var v, N, W, V; + for (s.isObject(I) || P(e, "cannot merge mappings; the provided source object is unacceptable"), W = 0, V = (v = Object.keys(I)).length; W < V; W += 1) N = v[W], h.call(O, N) || (O[N] = I[N], $[N] = !0); + } + function K(e, O, I, $, v, N, W, V) { + var J, Z; + if (v = String(v), O === null && (O = {}), $ === "tag:yaml.org,2002:merge") if (Array.isArray(N)) for (J = 0, Z = N.length; J < Z; J += 1) Y(e, O, N[J], I); + else Y(e, O, N, I); + else e.json || h.call(I, v) || !h.call(O, v) || (e.line = W || e.line, e.position = V || e.position, P(e, "duplicated mapping key")), O[v] = N, delete I[v]; + return O; + } + function se(e) { + var O; + (O = e.input.charCodeAt(e.position)) === 10 ? e.position++ : O === 13 ? (e.position++, e.input.charCodeAt(e.position) === 10 && e.position++) : P(e, "a line break is expected"), e.line += 1, e.lineStart = e.position; + } + function ce(e, O, I) { + for (var $ = 0, v = e.input.charCodeAt(e.position); v !== 0; ) { + for (; F(v); ) v = e.input.charCodeAt(++e.position); + if (O && v === 35) do + v = e.input.charCodeAt(++e.position); + while (v !== 10 && v !== 13 && v !== 0); + if (!S(v)) break; + for (se(e), v = e.input.charCodeAt(e.position), $++, e.lineIndent = 0; v === 32; ) e.lineIndent++, v = e.input.charCodeAt(++e.position); + } + return I !== -1 && $ !== 0 && e.lineIndent < I && z(e, "deficient indentation"), $; + } + function ve(e) { + var O, I = e.position; + return !((O = e.input.charCodeAt(I)) !== 45 && O !== 46 || O !== e.input.charCodeAt(I + 1) || O !== e.input.charCodeAt(I + 2) || (I += 3, (O = e.input.charCodeAt(I)) !== 0 && !D(O))); + } + function pe(e, O) { + O === 1 ? e.result += " " : O > 1 && (e.result += s.repeat(` +`, O - 1)); + } + function Se(e, O, I) { + var $, v, N, W, V, J, Z, ie, oe = e.kind, ge = e.result; + if (D(ie = e.input.charCodeAt(e.position)) || H(ie) || ie === 35 || ie === 38 || ie === 42 || ie === 33 || ie === 124 || ie === 62 || ie === 39 || ie === 34 || ie === 37 || ie === 64 || ie === 96 || (ie === 63 || ie === 45) && (D($ = e.input.charCodeAt(e.position + 1)) || I && H($))) return !1; + for (e.kind = "scalar", e.result = "", v = N = e.position, W = !1; ie !== 0; ) { + if (ie === 58) { + if (D($ = e.input.charCodeAt(e.position + 1)) || I && H($)) break; + } else if (ie === 35) { + if (D(e.input.charCodeAt(e.position - 1))) break; + } else { + if (e.position === e.lineStart && ve(e) || I && H(ie)) break; + if (S(ie)) { + if (V = e.line, J = e.lineStart, Z = e.lineIndent, ce(e, !1, -1), e.lineIndent >= O) { + W = !0, ie = e.input.charCodeAt(e.position); + continue; + } + e.position = N, e.line = V, e.lineStart = J, e.lineIndent = Z; + break; + } + } + W && (re(e, v, N, !1), pe(e, e.line - V), v = N = e.position, W = !1), F(ie) || (N = e.position + 1), ie = e.input.charCodeAt(++e.position); + } + return re(e, v, N, !1), !!e.result || (e.kind = oe, e.result = ge, !1); + } + function Ee(e, O) { + var I, $, v; + if ((I = e.input.charCodeAt(e.position)) !== 39) return !1; + for (e.kind = "scalar", e.result = "", e.position++, $ = v = e.position; (I = e.input.charCodeAt(e.position)) !== 0; ) if (I === 39) { + if (re(e, $, e.position, !0), (I = e.input.charCodeAt(++e.position)) !== 39) return !0; + $ = e.position, e.position++, v = e.position; + } else S(I) ? (re(e, $, v, !0), pe(e, ce(e, !1, O)), $ = v = e.position) : e.position === e.lineStart && ve(e) ? P(e, "unexpected end of the document within a single quoted scalar") : (e.position++, v = e.position); + P(e, "unexpected end of the stream within a single quoted scalar"); + } + function Ce(e, O) { + var I, $, v, N, W, V; + if ((V = e.input.charCodeAt(e.position)) !== 34) return !1; + for (e.kind = "scalar", e.result = "", e.position++, I = $ = e.position; (V = e.input.charCodeAt(e.position)) !== 0; ) { + if (V === 34) return re(e, I, e.position, !0), e.position++, !0; + if (V === 92) { + if (re(e, I, e.position, !0), S(V = e.input.charCodeAt(++e.position))) ce(e, !1, O); + else if (V < 256 && fe[V]) e.result += te[V], e.position++; + else if ((W = Q(V)) > 0) { + for (v = W, N = 0; v > 0; v--) (W = j(V = e.input.charCodeAt(++e.position))) >= 0 ? N = (N << 4) + W : P(e, "expected hexadecimal character"); + e.result += X(N), e.position++; + } else P(e, "unknown escape sequence"); + I = $ = e.position; + } else S(V) ? (re(e, I, $, !0), pe(e, ce(e, !1, O)), I = $ = e.position) : e.position === e.lineStart && ve(e) ? P(e, "unexpected end of the document within a double quoted scalar") : (e.position++, $ = e.position); + } + P(e, "unexpected end of the stream within a double quoted scalar"); + } + function B(e, O) { + var I, $, v, N, W, V, J, Z, ie, oe, ge = !0, ye = e.tag, be = e.anchor, Ae = {}; + if ((oe = e.input.charCodeAt(e.position)) === 91) v = 93, V = !1, $ = []; + else { + if (oe !== 123) return !1; + v = 125, V = !0, $ = {}; + } + for (e.anchor !== null && (e.anchorMap[e.anchor] = $), oe = e.input.charCodeAt(++e.position); oe !== 0; ) { + if (ce(e, !0, O), (oe = e.input.charCodeAt(e.position)) === v) return e.position++, e.tag = ye, e.anchor = be, e.kind = V ? "mapping" : "sequence", e.result = $, !0; + ge || P(e, "missed comma between flow collection entries"), ie = null, N = W = !1, oe === 63 && D(e.input.charCodeAt(e.position + 1)) && (N = W = !0, e.position++, ce(e, !0, O)), I = e.line, k(e, O, y, !1, !0), Z = e.tag, J = e.result, ce(e, !0, O), oe = e.input.charCodeAt(e.position), !W && e.line !== I || oe !== 58 || (N = !0, oe = e.input.charCodeAt(++e.position), ce(e, !0, O), k(e, O, y, !1, !0), ie = e.result), V ? K(e, $, Ae, Z, J, ie) : N ? $.push(K(e, null, Ae, Z, J, ie)) : $.push(J), ce(e, !0, O), (oe = e.input.charCodeAt(e.position)) === 44 ? (ge = !0, oe = e.input.charCodeAt(++e.position)) : ge = !1; + } + P(e, "unexpected end of the stream within a flow collection"); + } + function U(e, O) { + var I, $, v, N, W = R, V = !1, J = !1, Z = O, ie = 0, oe = !1; + if ((N = e.input.charCodeAt(e.position)) === 124) $ = !1; + else { + if (N !== 62) return !1; + $ = !0; + } + for (e.kind = "scalar", e.result = ""; N !== 0; ) if ((N = e.input.charCodeAt(++e.position)) === 43 || N === 45) R === W ? W = N === 43 ? o : l : P(e, "repeat of a chomping mode identifier"); + else { + if (!((v = T(N)) >= 0)) break; + v === 0 ? P(e, "bad explicit indentation width of a block scalar; it cannot be less than one") : J ? P(e, "repeat of an indentation width identifier") : (Z = O + v - 1, J = !0); + } + if (F(N)) { + do + N = e.input.charCodeAt(++e.position); + while (F(N)); + if (N === 35) do + N = e.input.charCodeAt(++e.position); + while (!S(N) && N !== 0); + } + for (; N !== 0; ) { + for (se(e), e.lineIndent = 0, N = e.input.charCodeAt(e.position); (!J || e.lineIndent < Z) && N === 32; ) e.lineIndent++, N = e.input.charCodeAt(++e.position); + if (!J && e.lineIndent > Z && (Z = e.lineIndent), S(N)) ie++; + else { + if (e.lineIndent < Z) { + W === o ? e.result += s.repeat(` +`, V ? 1 + ie : ie) : W === R && V && (e.result += ` +`); + break; + } + for ($ ? F(N) ? (oe = !0, e.result += s.repeat(` +`, V ? 1 + ie : ie)) : oe ? (oe = !1, e.result += s.repeat(` +`, ie + 1)) : ie === 0 ? V && (e.result += " ") : e.result += s.repeat(` +`, ie) : e.result += s.repeat(` +`, V ? 1 + ie : ie), V = !0, J = !0, ie = 0, I = e.position; !S(N) && N !== 0; ) N = e.input.charCodeAt(++e.position); + re(e, I, e.position, !1); + } + } + return !0; + } + function le(e, O) { + var I, $, v = e.tag, N = e.anchor, W = [], V = !1; + for (e.anchor !== null && (e.anchorMap[e.anchor] = W), $ = e.input.charCodeAt(e.position); $ !== 0 && $ === 45 && D(e.input.charCodeAt(e.position + 1)); ) if (V = !0, e.position++, ce(e, !0, -1) && e.lineIndent <= O) W.push(null), $ = e.input.charCodeAt(e.position); + else if (I = e.line, k(e, O, g, !1, !0), W.push(e.result), ce(e, !0, -1), $ = e.input.charCodeAt(e.position), (e.line === I || e.lineIndent > O) && $ !== 0) P(e, "bad indentation of a sequence entry"); + else if (e.lineIndent < O) break; + return !!V && (e.tag = v, e.anchor = N, e.kind = "sequence", e.result = W, !0); + } + function he(e, O, I) { + var $, v, N, W, V, J = e.tag, Z = e.anchor, ie = {}, oe = {}, ge = null, ye = null, be = null, Ae = !1, Oe = !1; + for (e.anchor !== null && (e.anchorMap[e.anchor] = ie), V = e.input.charCodeAt(e.position); V !== 0; ) { + if ($ = e.input.charCodeAt(e.position + 1), N = e.line, W = e.position, V !== 63 && V !== 58 || !D($)) { + if (!k(e, I, E, !1, !0)) break; + if (e.line === N) { + for (V = e.input.charCodeAt(e.position); F(V); ) V = e.input.charCodeAt(++e.position); + if (V === 58) D(V = e.input.charCodeAt(++e.position)) || P(e, "a whitespace character is expected after the key-value separator within a block mapping"), Ae && (K(e, ie, oe, ge, ye, null), ge = ye = be = null), Oe = !0, Ae = !1, v = !1, ge = e.tag, ye = e.result; + else { + if (!Oe) return e.tag = J, e.anchor = Z, !0; + P(e, "can not read an implicit mapping pair; a colon is missed"); + } + } else { + if (!Oe) return e.tag = J, e.anchor = Z, !0; + P(e, "can not read a block mapping entry; a multiline key may not be an implicit key"); + } + } else V === 63 ? (Ae && (K(e, ie, oe, ge, ye, null), ge = ye = be = null), Oe = !0, Ae = !0, v = !0) : Ae ? (Ae = !1, v = !0) : P(e, "incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"), e.position += 1, V = $; + if ((e.line === N || e.lineIndent > O) && (k(e, O, M, !0, v) && (Ae ? ye = e.result : be = e.result), Ae || (K(e, ie, oe, ge, ye, be, N, W), ge = ye = be = null), ce(e, !0, -1), V = e.input.charCodeAt(e.position)), e.lineIndent > O && V !== 0) P(e, "bad indentation of a mapping entry"); + else if (e.lineIndent < O) break; + } + return Ae && K(e, ie, oe, ge, ye, null), Oe && (e.tag = J, e.anchor = Z, e.kind = "mapping", e.result = ie), Oe; + } + function Te(e) { + var O, I, $, v, N = !1, W = !1; + if ((v = e.input.charCodeAt(e.position)) !== 33) return !1; + if (e.tag !== null && P(e, "duplication of a tag property"), (v = e.input.charCodeAt(++e.position)) === 60 ? (N = !0, v = e.input.charCodeAt(++e.position)) : v === 33 ? (W = !0, I = "!!", v = e.input.charCodeAt(++e.position)) : I = "!", O = e.position, N) { + do + v = e.input.charCodeAt(++e.position); + while (v !== 0 && v !== 62); + e.position < e.length ? ($ = e.input.slice(O, e.position), v = e.input.charCodeAt(++e.position)) : P(e, "unexpected end of the stream within a verbatim tag"); + } else { + for (; v !== 0 && !D(v); ) v === 33 && (W ? P(e, "tag suffix cannot contain exclamation marks") : (I = e.input.slice(O - 1, e.position + 1), A.test(I) || P(e, "named tag handle cannot contain such characters"), W = !0, O = e.position + 1)), v = e.input.charCodeAt(++e.position); + $ = e.input.slice(O, e.position), b.test($) && P(e, "tag suffix cannot contain flow indicator characters"); + } + return $ && !_.test($) && P(e, "tag name cannot contain such characters: " + $), N ? e.tag = $ : h.call(e.tagMap, I) ? e.tag = e.tagMap[I] + $ : I === "!" ? e.tag = "!" + $ : I === "!!" ? e.tag = "tag:yaml.org,2002:" + $ : P(e, 'undeclared tag handle "' + I + '"'), !0; + } + function u(e) { + var O, I; + if ((I = e.input.charCodeAt(e.position)) !== 38) return !1; + for (e.anchor !== null && P(e, "duplication of an anchor property"), I = e.input.charCodeAt(++e.position), O = e.position; I !== 0 && !D(I) && !H(I); ) I = e.input.charCodeAt(++e.position); + return e.position === O && P(e, "name of an anchor node must contain at least one character"), e.anchor = e.input.slice(O, e.position), !0; + } + function w(e) { + var O, I, $; + if (($ = e.input.charCodeAt(e.position)) !== 42) return !1; + for ($ = e.input.charCodeAt(++e.position), O = e.position; $ !== 0 && !D($) && !H($); ) $ = e.input.charCodeAt(++e.position); + return e.position === O && P(e, "name of an alias node must contain at least one character"), I = e.input.slice(O, e.position), e.anchorMap.hasOwnProperty(I) || P(e, 'unidentified alias "' + I + '"'), e.result = e.anchorMap[I], ce(e, !0, -1), !0; + } + function k(e, O, I, $, v) { + var N, W, V, J, Z, ie, oe, ge, ye = 1, be = !1, Ae = !1; + if (e.listener !== null && e.listener("open", e), e.tag = null, e.anchor = null, e.kind = null, e.result = null, N = W = V = M === I || g === I, $ && ce(e, !0, -1) && (be = !0, e.lineIndent > O ? ye = 1 : e.lineIndent === O ? ye = 0 : e.lineIndent < O && (ye = -1)), ye === 1) for (; Te(e) || u(e); ) ce(e, !0, -1) ? (be = !0, V = N, e.lineIndent > O ? ye = 1 : e.lineIndent === O ? ye = 0 : e.lineIndent < O && (ye = -1)) : V = !1; + if (V && (V = be || v), ye !== 1 && M !== I || (oe = y === I || E === I ? O : O + 1, ge = e.position - e.lineStart, ye === 1 ? V && (le(e, ge) || he(e, ge, oe)) || B(e, oe) ? Ae = !0 : (W && U(e, oe) || Ee(e, oe) || Ce(e, oe) ? Ae = !0 : w(e) ? (Ae = !0, e.tag === null && e.anchor === null || P(e, "alias node should not have any properties")) : Se(e, oe, y === I) && (Ae = !0, e.tag === null && (e.tag = "?")), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : ye === 0 && (Ae = V && le(e, ge))), e.tag !== null && e.tag !== "!") if (e.tag === "?") { + for (J = 0, Z = e.implicitTypes.length; J < Z; J += 1) if ((ie = e.implicitTypes[J]).resolve(e.result)) { + e.result = ie.construct(e.result), e.tag = ie.tag, e.anchor !== null && (e.anchorMap[e.anchor] = e.result); + break; + } + } else h.call(e.typeMap[e.kind || "fallback"], e.tag) ? (ie = e.typeMap[e.kind || "fallback"][e.tag], e.result !== null && ie.kind !== e.kind && P(e, "unacceptable node kind for !<" + e.tag + '> tag; it should be "' + ie.kind + '", not "' + e.kind + '"'), ie.resolve(e.result) ? (e.result = ie.construct(e.result), e.anchor !== null && (e.anchorMap[e.anchor] = e.result)) : P(e, "cannot resolve a node with !<" + e.tag + "> explicit tag")) : P(e, "unknown tag !<" + e.tag + ">"); + return e.listener !== null && e.listener("close", e), e.tag !== null || e.anchor !== null || Ae; + } + function q(e) { + var O, I, $, v, N = e.position, W = !1; + for (e.version = null, e.checkLineBreaks = e.legacy, e.tagMap = {}, e.anchorMap = {}; (v = e.input.charCodeAt(e.position)) !== 0 && (ce(e, !0, -1), v = e.input.charCodeAt(e.position), !(e.lineIndent > 0 || v !== 37)); ) { + for (W = !0, v = e.input.charCodeAt(++e.position), O = e.position; v !== 0 && !D(v); ) v = e.input.charCodeAt(++e.position); + for ($ = [], (I = e.input.slice(O, e.position)).length < 1 && P(e, "directive name must not be less than one character in length"); v !== 0; ) { + for (; F(v); ) v = e.input.charCodeAt(++e.position); + if (v === 35) { + do + v = e.input.charCodeAt(++e.position); + while (v !== 0 && !S(v)); + break; + } + if (S(v)) break; + for (O = e.position; v !== 0 && !D(v); ) v = e.input.charCodeAt(++e.position); + $.push(e.input.slice(O, e.position)); + } + v !== 0 && se(e), h.call(ae, I) ? ae[I](e, I, $) : z(e, 'unknown document directive "' + I + '"'); + } + ce(e, !0, -1), e.lineIndent === 0 && e.input.charCodeAt(e.position) === 45 && e.input.charCodeAt(e.position + 1) === 45 && e.input.charCodeAt(e.position + 2) === 45 ? (e.position += 3, ce(e, !0, -1)) : W && P(e, "directives end mark is expected"), k(e, e.lineIndent - 1, M, !1, !0), ce(e, !0, -1), e.checkLineBreaks && f.test(e.input.slice(N, e.position)) && z(e, "non-ASCII line breaks are interpreted as content"), e.documents.push(e.result), e.position === e.lineStart && ve(e) ? e.input.charCodeAt(e.position) === 46 && (e.position += 3, ce(e, !0, -1)) : e.position < e.length - 1 && P(e, "end of the stream or a document separator is expected"); + } + function ne(e, O) { + O = O || {}, (e = String(e)).length !== 0 && (e.charCodeAt(e.length - 1) !== 10 && e.charCodeAt(e.length - 1) !== 13 && (e += ` +`), e.charCodeAt(0) === 65279 && (e = e.slice(1))); + var I = new ee(e, O); + for (I.input += "\0"; I.input.charCodeAt(I.position) === 32; ) I.lineIndent += 1, I.position += 1; + for (; I.position < I.length - 1; ) q(I); + return I.documents; + } + function ue(e, O, I) { + var $, v, N = ne(e, I); + if (typeof O != "function") return N; + for ($ = 0, v = N.length; $ < v; $ += 1) O(N[$]); + } + function we(e, O) { + var I = ne(e, O); + if (I.length !== 0) { + if (I.length === 1) return I[0]; + throw new a("expected a single document in the stream, but found more"); + } + } + function L(e, O, I) { + if (typeof O != "function") return ue(e, s.extend({ schema: x }, I)); + ue(e, O, s.extend({ schema: x }, I)); + } + function C(e, O) { + return we(e, s.extend({ schema: x }, O)); + } + n.exports.loadAll = ue, n.exports.load = we, n.exports.safeLoadAll = L, n.exports.safeLoad = C; + }, { "./common": 36, "./exception": 38, "./mark": 40, "./schema/default_full": 43, "./schema/default_safe": 44 }], 40: [function(t, n, p) { + var s = t("./common"); + function a(d, x, m, h, y) { + this.name = d, this.buffer = x, this.position = m, this.line = h, this.column = y; + } + a.prototype.getSnippet = function(d, x) { + var m, h, y, E, g; + if (!this.buffer) return null; + for (d = d || 4, x = x || 75, m = "", h = this.position; h > 0 && `\0\r +…\u2028\u2029`.indexOf(this.buffer.charAt(h - 1)) === -1; ) if (h -= 1, this.position - h > x / 2 - 1) { + m = " ... ", h += 5; + break; + } + for (y = "", E = this.position; E < this.buffer.length && `\0\r +…\u2028\u2029`.indexOf(this.buffer.charAt(E)) === -1; ) if ((E += 1) - this.position > x / 2 - 1) { + y = " ... ", E -= 5; + break; + } + return g = this.buffer.slice(h, E), s.repeat(" ", d) + m + g + y + ` +` + s.repeat(" ", d + this.position - h + m.length) + "^"; + }, a.prototype.toString = function(d) { + var x, m = ""; + return this.name && (m += 'in "' + this.name + '" '), m += "at line " + (this.line + 1) + ", column " + (this.column + 1), d || (x = this.getSnippet()) && (m += `: +` + x), m; + }, n.exports = a; + }, { "./common": 36 }], 41: [function(t, n, p) { + var s = t("./common"), a = t("./exception"), d = t("./type"); + function x(y, E, g) { + var M = []; + return y.include.forEach(function(R) { + g = x(R, E, g); + }), y[E].forEach(function(R) { + g.forEach(function(l, o) { + l.tag === R.tag && l.kind === R.kind && M.push(o); + }), g.push(R); + }), g.filter(function(R, l) { + return M.indexOf(l) === -1; + }); + } + function m() { + var y, E, g = { scalar: {}, sequence: {}, mapping: {}, fallback: {} }; + function M(R) { + g[R.kind][R.tag] = g.fallback[R.tag] = R; + } + for (y = 0, E = arguments.length; y < E; y += 1) arguments[y].forEach(M); + return g; + } + function h(y) { + this.include = y.include || [], this.implicit = y.implicit || [], this.explicit = y.explicit || [], this.implicit.forEach(function(E) { + if (E.loadKind && E.loadKind !== "scalar") throw new a("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported."); + }), this.compiledImplicit = x(this, "implicit", []), this.compiledExplicit = x(this, "explicit", []), this.compiledTypeMap = m(this.compiledImplicit, this.compiledExplicit); + } + h.DEFAULT = null, h.create = function() { + var y, E; + switch (arguments.length) { + case 1: + y = h.DEFAULT, E = arguments[0]; + break; + case 2: + y = arguments[0], E = arguments[1]; + break; + default: + throw new a("Wrong number of arguments for Schema.create function"); + } + if (y = s.toArray(y), E = s.toArray(E), !y.every(function(g) { + return g instanceof h; + })) throw new a("Specified list of super schemas (or a single Schema object) contains a non-Schema object."); + if (!E.every(function(g) { + return g instanceof d; + })) throw new a("Specified list of YAML types (or a single Type object) contains a non-Type object."); + return new h({ include: y, explicit: E }); + }, n.exports = h; + }, { "./common": 36, "./exception": 38, "./type": 47 }], 42: [function(t, n, p) { + var s = t("../schema"); + n.exports = new s({ include: [t("./json")] }); + }, { "../schema": 41, "./json": 46 }], 43: [function(t, n, p) { + var s = t("../schema"); + n.exports = s.DEFAULT = new s({ include: [t("./default_safe")], explicit: [t("../type/js/undefined"), t("../type/js/regexp"), t("../type/js/function")] }); + }, { "../schema": 41, "../type/js/function": 52, "../type/js/regexp": 53, "../type/js/undefined": 54, "./default_safe": 44 }], 44: [function(t, n, p) { + var s = t("../schema"); + n.exports = new s({ include: [t("./core")], implicit: [t("../type/timestamp"), t("../type/merge")], explicit: [t("../type/binary"), t("../type/omap"), t("../type/pairs"), t("../type/set")] }); + }, { "../schema": 41, "../type/binary": 48, "../type/merge": 56, "../type/omap": 58, "../type/pairs": 59, "../type/set": 61, "../type/timestamp": 63, "./core": 42 }], 45: [function(t, n, p) { + var s = t("../schema"); + n.exports = new s({ explicit: [t("../type/str"), t("../type/seq"), t("../type/map")] }); + }, { "../schema": 41, "../type/map": 55, "../type/seq": 60, "../type/str": 62 }], 46: [function(t, n, p) { + var s = t("../schema"); + n.exports = new s({ include: [t("./failsafe")], implicit: [t("../type/null"), t("../type/bool"), t("../type/int"), t("../type/float")] }); + }, { "../schema": 41, "../type/bool": 49, "../type/float": 50, "../type/int": 51, "../type/null": 57, "./failsafe": 45 }], 47: [function(t, n, p) { + var s = t("./exception"), a = ["kind", "resolve", "construct", "instanceOf", "predicate", "represent", "defaultStyle", "styleAliases"], d = ["scalar", "sequence", "mapping"]; + function x(h) { + var y = {}; + return h !== null && Object.keys(h).forEach(function(E) { + h[E].forEach(function(g) { + y[String(g)] = E; + }); + }), y; + } + function m(h, y) { + if (y = y || {}, Object.keys(y).forEach(function(E) { + if (a.indexOf(E) === -1) throw new s('Unknown option "' + E + '" is met in definition of "' + h + '" YAML type.'); + }), this.tag = h, this.kind = y.kind || null, this.resolve = y.resolve || function() { + return !0; + }, this.construct = y.construct || function(E) { + return E; + }, this.instanceOf = y.instanceOf || null, this.predicate = y.predicate || null, this.represent = y.represent || null, this.defaultStyle = y.defaultStyle || null, this.styleAliases = x(y.styleAliases || null), d.indexOf(this.kind) === -1) throw new s('Unknown kind "' + this.kind + '" is specified for "' + h + '" YAML type.'); + } + n.exports = m; + }, { "./exception": 38 }], 48: [function(t, n, p) { + var s; + try { + var a = t; + s = a("buffer").Buffer; + } catch { + } + var d = t("../type"), x = `ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= +\r`; + function m(g) { + if (g === null) return !1; + var M, R, l = 0, o = g.length, c = x; + for (R = 0; R < o; R++) if (!((M = c.indexOf(g.charAt(R))) > 64)) { + if (M < 0) return !1; + l += 6; + } + return l % 8 == 0; + } + function h(g) { + var M, R, l = g.replace(/[\r\n=]/g, ""), o = l.length, c = x, f = 0, b = []; + for (M = 0; M < o; M++) M % 4 == 0 && M && (b.push(f >> 16 & 255), b.push(f >> 8 & 255), b.push(255 & f)), f = f << 6 | c.indexOf(l.charAt(M)); + return (R = o % 4 * 6) === 0 ? (b.push(f >> 16 & 255), b.push(f >> 8 & 255), b.push(255 & f)) : R === 18 ? (b.push(f >> 10 & 255), b.push(f >> 2 & 255)) : R === 12 && b.push(f >> 4 & 255), s ? s.from ? s.from(b) : new s(b) : b; + } + function y(g) { + var M, R, l = "", o = 0, c = g.length, f = x; + for (M = 0; M < c; M++) M % 3 == 0 && M && (l += f[o >> 18 & 63], l += f[o >> 12 & 63], l += f[o >> 6 & 63], l += f[63 & o]), o = (o << 8) + g[M]; + return (R = c % 3) === 0 ? (l += f[o >> 18 & 63], l += f[o >> 12 & 63], l += f[o >> 6 & 63], l += f[63 & o]) : R === 2 ? (l += f[o >> 10 & 63], l += f[o >> 4 & 63], l += f[o << 2 & 63], l += f[64]) : R === 1 && (l += f[o >> 2 & 63], l += f[o << 4 & 63], l += f[64], l += f[64]), l; + } + function E(g) { + return s && s.isBuffer(g); + } + n.exports = new d("tag:yaml.org,2002:binary", { kind: "scalar", resolve: m, construct: h, predicate: E, represent: y }); + }, { "../type": 47 }], 49: [function(t, n, p) { + var s = t("../type"); + function a(m) { + if (m === null) return !1; + var h = m.length; + return h === 4 && (m === "true" || m === "True" || m === "TRUE") || h === 5 && (m === "false" || m === "False" || m === "FALSE"); + } + function d(m) { + return m === "true" || m === "True" || m === "TRUE"; + } + function x(m) { + return Object.prototype.toString.call(m) === "[object Boolean]"; + } + n.exports = new s("tag:yaml.org,2002:bool", { kind: "scalar", resolve: a, construct: d, predicate: x, represent: { lowercase: function(m) { + return m ? "true" : "false"; + }, uppercase: function(m) { + return m ? "TRUE" : "FALSE"; + }, camelcase: function(m) { + return m ? "True" : "False"; + } }, defaultStyle: "lowercase" }); + }, { "../type": 47 }], 50: [function(t, n, p) { + var s = t("../common"), a = t("../type"), d = new RegExp("^(?:[-+]?(?:0|[1-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\.[0-9_]*|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$"); + function x(g) { + return g !== null && !(!d.test(g) || g[g.length - 1] === "_"); + } + function m(g) { + var M, R, l, o; + return R = (M = g.replace(/_/g, "").toLowerCase())[0] === "-" ? -1 : 1, o = [], "+-".indexOf(M[0]) >= 0 && (M = M.slice(1)), M === ".inf" ? R === 1 ? Number.POSITIVE_INFINITY : Number.NEGATIVE_INFINITY : M === ".nan" ? NaN : M.indexOf(":") >= 0 ? (M.split(":").forEach(function(c) { + o.unshift(parseFloat(c, 10)); + }), M = 0, l = 1, o.forEach(function(c) { + M += c * l, l *= 60; + }), R * M) : R * parseFloat(M, 10); + } + var h = /^[-+]?[0-9]+e/; + function y(g, M) { + var R; + if (isNaN(g)) switch (M) { + case "lowercase": + return ".nan"; + case "uppercase": + return ".NAN"; + case "camelcase": + return ".NaN"; + } + else if (Number.POSITIVE_INFINITY === g) switch (M) { + case "lowercase": + return ".inf"; + case "uppercase": + return ".INF"; + case "camelcase": + return ".Inf"; + } + else if (Number.NEGATIVE_INFINITY === g) switch (M) { + case "lowercase": + return "-.inf"; + case "uppercase": + return "-.INF"; + case "camelcase": + return "-.Inf"; + } + else if (s.isNegativeZero(g)) return "-0.0"; + return R = g.toString(10), h.test(R) ? R.replace("e", ".e") : R; + } + function E(g) { + return Object.prototype.toString.call(g) === "[object Number]" && (g % 1 != 0 || s.isNegativeZero(g)); + } + n.exports = new a("tag:yaml.org,2002:float", { kind: "scalar", resolve: x, construct: m, predicate: E, represent: y, defaultStyle: "lowercase" }); + }, { "../common": 36, "../type": 47 }], 51: [function(t, n, p) { + var s = t("../common"), a = t("../type"); + function d(g) { + return 48 <= g && g <= 57 || 65 <= g && g <= 70 || 97 <= g && g <= 102; + } + function x(g) { + return 48 <= g && g <= 55; + } + function m(g) { + return 48 <= g && g <= 57; + } + function h(g) { + if (g === null) return !1; + var M, R = g.length, l = 0, o = !1; + if (!R) return !1; + if ((M = g[l]) !== "-" && M !== "+" || (M = g[++l]), M === "0") { + if (l + 1 === R) return !0; + if ((M = g[++l]) === "b") { + for (l++; l < R; l++) if ((M = g[l]) !== "_") { + if (M !== "0" && M !== "1") return !1; + o = !0; + } + return o && M !== "_"; + } + if (M === "x") { + for (l++; l < R; l++) if ((M = g[l]) !== "_") { + if (!d(g.charCodeAt(l))) return !1; + o = !0; + } + return o && M !== "_"; + } + for (; l < R; l++) if ((M = g[l]) !== "_") { + if (!x(g.charCodeAt(l))) return !1; + o = !0; + } + return o && M !== "_"; + } + if (M === "_") return !1; + for (; l < R; l++) if ((M = g[l]) !== "_") { + if (M === ":") break; + if (!m(g.charCodeAt(l))) return !1; + o = !0; + } + return !(!o || M === "_") && (M !== ":" || /^(:[0-5]?[0-9])+$/.test(g.slice(l))); + } + function y(g) { + var M, R, l = g, o = 1, c = []; + return l.indexOf("_") !== -1 && (l = l.replace(/_/g, "")), (M = l[0]) !== "-" && M !== "+" || (M === "-" && (o = -1), M = (l = l.slice(1))[0]), l === "0" ? 0 : M === "0" ? l[1] === "b" ? o * parseInt(l.slice(2), 2) : l[1] === "x" ? o * parseInt(l, 16) : o * parseInt(l, 8) : l.indexOf(":") !== -1 ? (l.split(":").forEach(function(f) { + c.unshift(parseInt(f, 10)); + }), l = 0, R = 1, c.forEach(function(f) { + l += f * R, R *= 60; + }), o * l) : o * parseInt(l, 10); + } + function E(g) { + return Object.prototype.toString.call(g) === "[object Number]" && g % 1 == 0 && !s.isNegativeZero(g); + } + n.exports = new a("tag:yaml.org,2002:int", { kind: "scalar", resolve: h, construct: y, predicate: E, represent: { binary: function(g) { + return g >= 0 ? "0b" + g.toString(2) : "-0b" + g.toString(2).slice(1); + }, octal: function(g) { + return g >= 0 ? "0" + g.toString(8) : "-0" + g.toString(8).slice(1); + }, decimal: function(g) { + return g.toString(10); + }, hexadecimal: function(g) { + return g >= 0 ? "0x" + g.toString(16).toUpperCase() : "-0x" + g.toString(16).toUpperCase().slice(1); + } }, defaultStyle: "decimal", styleAliases: { binary: [2, "bin"], octal: [8, "oct"], decimal: [10, "dec"], hexadecimal: [16, "hex"] } }); + }, { "../common": 36, "../type": 47 }], 52: [function(t, n, p) { + var s; + try { + var a = t; + s = a("esprima"); + } catch { + typeof window < "u" && (s = window.esprima); + } + var d = t("../../type"); + function x(E) { + if (E === null) return !1; + try { + var g = "(" + E + ")", M = s.parse(g, { range: !0 }); + return M.type === "Program" && M.body.length === 1 && M.body[0].type === "ExpressionStatement" && (M.body[0].expression.type === "ArrowFunctionExpression" || M.body[0].expression.type === "FunctionExpression"); + } catch { + return !1; + } + } + function m(E) { + var g, M = "(" + E + ")", R = s.parse(M, { range: !0 }), l = []; + if (R.type !== "Program" || R.body.length !== 1 || R.body[0].type !== "ExpressionStatement" || R.body[0].expression.type !== "ArrowFunctionExpression" && R.body[0].expression.type !== "FunctionExpression") throw new Error("Failed to resolve function"); + return R.body[0].expression.params.forEach(function(o) { + l.push(o.name); + }), g = R.body[0].expression.body.range, R.body[0].expression.body.type === "BlockStatement" ? new Function(l, M.slice(g[0] + 1, g[1] - 1)) : new Function(l, "return " + M.slice(g[0], g[1])); + } + function h(E) { + return E.toString(); + } + function y(E) { + return Object.prototype.toString.call(E) === "[object Function]"; + } + n.exports = new d("tag:yaml.org,2002:js/function", { kind: "scalar", resolve: x, construct: m, predicate: y, represent: h }); + }, { "../../type": 47 }], 53: [function(t, n, p) { + var s = t("../../type"); + function a(h) { + if (h === null || h.length === 0) return !1; + var y = h, E = /\/([gim]*)$/.exec(h), g = ""; + return !(y[0] === "/" && (E && (g = E[1]), g.length > 3 || y[y.length - g.length - 1] !== "/")); + } + function d(h) { + var y = h, E = /\/([gim]*)$/.exec(h), g = ""; + return y[0] === "/" && (E && (g = E[1]), y = y.slice(1, y.length - g.length - 1)), new RegExp(y, g); + } + function x(h) { + var y = "/" + h.source + "/"; + return h.global && (y += "g"), h.multiline && (y += "m"), h.ignoreCase && (y += "i"), y; + } + function m(h) { + return Object.prototype.toString.call(h) === "[object RegExp]"; + } + n.exports = new s("tag:yaml.org,2002:js/regexp", { kind: "scalar", resolve: a, construct: d, predicate: m, represent: x }); + }, { "../../type": 47 }], 54: [function(t, n, p) { + var s = t("../../type"); + function a() { + return !0; + } + function d() { + } + function x() { + return ""; + } + function m(h) { + return h === void 0; + } + n.exports = new s("tag:yaml.org,2002:js/undefined", { kind: "scalar", resolve: a, construct: d, predicate: m, represent: x }); + }, { "../../type": 47 }], 55: [function(t, n, p) { + var s = t("../type"); + n.exports = new s("tag:yaml.org,2002:map", { kind: "mapping", construct: function(a) { + return a !== null ? a : {}; + } }); + }, { "../type": 47 }], 56: [function(t, n, p) { + var s = t("../type"); + function a(d) { + return d === "<<" || d === null; + } + n.exports = new s("tag:yaml.org,2002:merge", { kind: "scalar", resolve: a }); + }, { "../type": 47 }], 57: [function(t, n, p) { + var s = t("../type"); + function a(m) { + if (m === null) return !0; + var h = m.length; + return h === 1 && m === "~" || h === 4 && (m === "null" || m === "Null" || m === "NULL"); + } + function d() { + return null; + } + function x(m) { + return m === null; + } + n.exports = new s("tag:yaml.org,2002:null", { kind: "scalar", resolve: a, construct: d, predicate: x, represent: { canonical: function() { + return "~"; + }, lowercase: function() { + return "null"; + }, uppercase: function() { + return "NULL"; + }, camelcase: function() { + return "Null"; + } }, defaultStyle: "lowercase" }); + }, { "../type": 47 }], 58: [function(t, n, p) { + var s = t("../type"), a = Object.prototype.hasOwnProperty, d = Object.prototype.toString; + function x(h) { + if (h === null) return !0; + var y, E, g, M, R, l = [], o = h; + for (y = 0, E = o.length; y < E; y += 1) { + if (g = o[y], R = !1, d.call(g) !== "[object Object]") return !1; + for (M in g) if (a.call(g, M)) { + if (R) return !1; + R = !0; + } + if (!R || l.indexOf(M) !== -1) return !1; + l.push(M); + } + return !0; + } + function m(h) { + return h !== null ? h : []; + } + n.exports = new s("tag:yaml.org,2002:omap", { kind: "sequence", resolve: x, construct: m }); + }, { "../type": 47 }], 59: [function(t, n, p) { + var s = t("../type"), a = Object.prototype.toString; + function d(m) { + if (m === null) return !0; + var h, y, E, g, M, R = m; + for (M = new Array(R.length), h = 0, y = R.length; h < y; h += 1) { + if (E = R[h], a.call(E) !== "[object Object]" || (g = Object.keys(E)).length !== 1) return !1; + M[h] = [g[0], E[g[0]]]; + } + return !0; + } + function x(m) { + if (m === null) return []; + var h, y, E, g, M, R = m; + for (M = new Array(R.length), h = 0, y = R.length; h < y; h += 1) E = R[h], g = Object.keys(E), M[h] = [g[0], E[g[0]]]; + return M; + } + n.exports = new s("tag:yaml.org,2002:pairs", { kind: "sequence", resolve: d, construct: x }); + }, { "../type": 47 }], 60: [function(t, n, p) { + var s = t("../type"); + n.exports = new s("tag:yaml.org,2002:seq", { kind: "sequence", construct: function(a) { + return a !== null ? a : []; + } }); + }, { "../type": 47 }], 61: [function(t, n, p) { + var s = t("../type"), a = Object.prototype.hasOwnProperty; + function d(m) { + if (m === null) return !0; + var h, y = m; + for (h in y) if (a.call(y, h) && y[h] !== null) return !1; + return !0; + } + function x(m) { + return m !== null ? m : {}; + } + n.exports = new s("tag:yaml.org,2002:set", { kind: "mapping", resolve: d, construct: x }); + }, { "../type": 47 }], 62: [function(t, n, p) { + var s = t("../type"); + n.exports = new s("tag:yaml.org,2002:str", { kind: "scalar", construct: function(a) { + return a !== null ? a : ""; + } }); + }, { "../type": 47 }], 63: [function(t, n, p) { + var s = t("../type"), a = new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"), d = 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 x(y) { + return y !== null && (a.exec(y) !== null || d.exec(y) !== null); + } + function m(y) { + var E, g, M, R, l, o, c, f, b = 0, A = null; + if ((E = a.exec(y)) === null && (E = d.exec(y)), E === null) throw new Error("Date resolve error"); + if (g = +E[1], M = +E[2] - 1, R = +E[3], !E[4]) return new Date(Date.UTC(g, M, R)); + if (l = +E[4], o = +E[5], c = +E[6], E[7]) { + for (b = E[7].slice(0, 3); b.length < 3; ) b += "0"; + b = +b; + } + return E[9] && (A = 6e4 * (60 * +E[10] + +(E[11] || 0)), E[9] === "-" && (A = -A)), f = new Date(Date.UTC(g, M, R, l, o, c, b)), A && f.setTime(f.getTime() - A), f; + } + function h(y) { + return y.toISOString(); + } + n.exports = new s("tag:yaml.org,2002:timestamp", { kind: "scalar", resolve: x, construct: m, instanceOf: Date, represent: h }); + }, { "../type": 47 }], 64: [function(t, n, p) { + var s = t("format-util"), a = Array.prototype.slice, d = ["name", "message", "stack"], x = ["name", "message", "description", "number", "code", "fileName", "lineNumber", "columnNumber", "sourceURL", "line", "column", "stack"]; + function m(_) { + return function(S, F, D, H) { + var j = [], Q = ""; + typeof S == "string" ? (j = a.call(arguments), S = F = void 0) : typeof F == "string" ? (j = a.call(arguments, 1), F = void 0) : typeof D == "string" && (j = a.call(arguments, 2)), j.length > 0 && (Q = n.exports.formatter.apply(null, j)), S && S.message && (Q += (Q ? ` +` : "") + S.message); + var T = new _(Q); + return h(T, S), y(T), E(T, F), T; + }; + } + function h(_, S) { + R(_, S), E(_, S); + } + function y(_) { + _.toJSON = g, _.inspect = M; + } + function E(_, S) { + if (S && typeof S == "object") for (var F = Object.keys(S), D = 0; D < F.length; D++) { + var H = F[D]; + if (!(d.indexOf(H) >= 0)) try { + _[H] = S[H]; + } catch { + } + } + } + function g() { + var _ = {}, S = Object.keys(this); + S = S.concat(x); + for (var F = 0; F < S.length; F++) { + var D = S[F], H = this[D], j = typeof H; + j !== "undefined" && j !== "function" && (_[D] = H); + } + return _; + } + function M() { + return JSON.stringify(this, null, 2).replace(/\\n/g, ` +`); + } + function R(_, S) { + f(_) ? S ? b(_, S) : A(_) : _.stack = S ? l(_.stack, S.stack) : o(_.stack); + } + function l(_, S) { + return (_ = o(_)) && S ? _ + ` + +` + S : _ || S; + } + function o(_) { + if (_) { + var S = _.split(` +`); + if (S.length < 2) return _; + for (var F = 0; F < S.length; F++) + if (S[F].indexOf("onoFactory") >= 0) return S.splice(F, 1), S.join(` +`); + return _; + } + } + n.exports = m(Error), n.exports.error = m(Error), n.exports.eval = m(EvalError), n.exports.range = m(RangeError), n.exports.reference = m(ReferenceError), n.exports.syntax = m(SyntaxError), n.exports.type = m(TypeError), n.exports.uri = m(URIError), n.exports.formatter = s; + var c = !(!Object.getOwnPropertyDescriptor || !Object.defineProperty || typeof navigator < "u" && /Android/.test(navigator.userAgent)); + function f(_) { + if (!c) return !1; + var S = Object.getOwnPropertyDescriptor(_, "stack"); + return !!S && typeof S.get == "function"; + } + function b(_, S) { + var F = Object.getOwnPropertyDescriptor(_, "stack"); + Object.defineProperty(_, "stack", { get: function() { + return l(F.get.apply(_), S.stack); + }, enumerable: !1, configurable: !0 }); + } + function A(_) { + var S = Object.getOwnPropertyDescriptor(_, "stack"); + Object.defineProperty(_, "stack", { get: function() { + return o(S.get.apply(_)); + }, enumerable: !1, configurable: !0 }); + } + }, { "format-util": 28 }], 65: [function(t, n, p) { + (function(s) { + function a(d, x, m, h) { + if (typeof d != "function") throw new TypeError('"callback" argument must be a function'); + var y, E, g = arguments.length; + switch (g) { + case 0: + case 1: + return s.nextTick(d); + case 2: + return s.nextTick(function() { + d.call(null, x); + }); + case 3: + return s.nextTick(function() { + d.call(null, x, m); + }); + case 4: + return s.nextTick(function() { + d.call(null, x, m, h); + }); + default: + for (y = new Array(g - 1), E = 0; E < y.length; ) y[E++] = arguments[E]; + return s.nextTick(function() { + d.apply(null, y); + }); + } + } + !s.version || s.version.indexOf("v0.") === 0 || s.version.indexOf("v1.") === 0 && s.version.indexOf("v1.8.") !== 0 ? n.exports = { nextTick: a } : n.exports = s; + }).call(this, t("_process")); + }, { _process: 66 }], 66: [function(t, n, p) { + var s, a, d = n.exports = {}; + function x() { + throw new Error("setTimeout has not been defined"); + } + function m() { + throw new Error("clearTimeout has not been defined"); + } + function h(b) { + if (s === setTimeout) return setTimeout(b, 0); + if ((s === x || !s) && setTimeout) return s = setTimeout, setTimeout(b, 0); + try { + return s(b, 0); + } catch { + try { + return s.call(null, b, 0); + } catch { + return s.call(this, b, 0); + } + } + } + function y(b) { + if (a === clearTimeout) return clearTimeout(b); + if ((a === m || !a) && clearTimeout) return a = clearTimeout, clearTimeout(b); + try { + return a(b); + } catch { + try { + return a.call(null, b); + } catch { + return a.call(this, b); + } + } + } + (function() { + try { + s = typeof setTimeout == "function" ? setTimeout : x; + } catch { + s = x; + } + try { + a = typeof clearTimeout == "function" ? clearTimeout : m; + } catch { + a = m; + } + })(); + var E, g = [], M = !1, R = -1; + function l() { + M && E && (M = !1, E.length ? g = E.concat(g) : R = -1, g.length && o()); + } + function o() { + if (!M) { + var b = h(l); + M = !0; + for (var A = g.length; A; ) { + for (E = g, g = []; ++R < A; ) E && E[R].run(); + R = -1, A = g.length; + } + E = null, M = !1, y(b); + } + } + function c(b, A) { + this.fun = b, this.array = A; + } + function f() { + } + d.nextTick = function(b) { + var A = new Array(arguments.length - 1); + if (arguments.length > 1) for (var _ = 1; _ < arguments.length; _++) A[_ - 1] = arguments[_]; + g.push(new c(b, A)), g.length !== 1 || M || h(o); + }, c.prototype.run = function() { + this.fun.apply(null, this.array); + }, d.title = "browser", d.browser = !0, d.env = {}, d.argv = [], d.version = "", d.versions = {}, d.on = f, d.addListener = f, d.once = f, d.off = f, d.removeListener = f, d.removeAllListeners = f, d.emit = f, d.prependListener = f, d.prependOnceListener = f, d.listeners = function(b) { + return []; + }, d.binding = function(b) { + throw new Error("process.binding is not supported"); + }, d.cwd = function() { + return "/"; + }, d.chdir = function(b) { + throw new Error("process.chdir is not supported"); + }, d.umask = function() { + return 0; + }; + }, {}], 67: [function(t, n, p) { + function s(d, x) { + return Object.prototype.hasOwnProperty.call(d, x); + } + n.exports = function(d, x, m, h) { + x = x || "&", m = m || "="; + var y = {}; + if (typeof d != "string" || d.length === 0) return y; + var E = /\+/g; + d = d.split(x); + var g = 1e3; + h && typeof h.maxKeys == "number" && (g = h.maxKeys); + var M = d.length; + g > 0 && M > g && (M = g); + for (var R = 0; R < M; ++R) { + var l, o, c, f, b = d[R].replace(E, "%20"), A = b.indexOf(m); + A >= 0 ? (l = b.substr(0, A), o = b.substr(A + 1)) : (l = b, o = ""), c = decodeURIComponent(l), f = decodeURIComponent(o), s(y, c) ? a(y[c]) ? y[c].push(f) : y[c] = [y[c], f] : y[c] = f; + } + return y; + }; + var a = Array.isArray || function(d) { + return Object.prototype.toString.call(d) === "[object Array]"; + }; + }, {}], 68: [function(t, n, p) { + var s = function(m) { + switch (typeof m) { + case "string": + return m; + case "boolean": + return m ? "true" : "false"; + case "number": + return isFinite(m) ? m : ""; + default: + return ""; + } + }; + n.exports = function(m, h, y, E) { + return h = h || "&", y = y || "=", m === null && (m = void 0), typeof m == "object" ? d(x(m), function(g) { + var M = encodeURIComponent(s(g)) + y; + return a(m[g]) ? d(m[g], function(R) { + return M + encodeURIComponent(s(R)); + }).join(h) : M + encodeURIComponent(s(m[g])); + }).join(h) : E ? encodeURIComponent(s(E)) + y + encodeURIComponent(s(m)) : ""; + }; + var a = Array.isArray || function(m) { + return Object.prototype.toString.call(m) === "[object Array]"; + }; + function d(m, h) { + if (m.map) return m.map(h); + for (var y = [], E = 0; E < m.length; E++) y.push(h(m[E], E)); + return y; + } + var x = Object.keys || function(m) { + var h = []; + for (var y in m) Object.prototype.hasOwnProperty.call(m, y) && h.push(y); + return h; + }; + }, {}], 69: [function(t, n, p) { + p.decode = p.parse = t("./decode"), p.encode = p.stringify = t("./encode"); + }, { "./decode": 67, "./encode": 68 }], 70: [function(t, n, p) { + var s = t("process-nextick-args"), a = Object.keys || function(l) { + var o = []; + for (var c in l) o.push(c); + return o; + }; + n.exports = g; + var d = t("core-util-is"); + d.inherits = t("inherits"); + var x = t("./_stream_readable"), m = t("./_stream_writable"); + d.inherits(g, x); + for (var h = a(m.prototype), y = 0; y < h.length; y++) { + var E = h[y]; + g.prototype[E] || (g.prototype[E] = m.prototype[E]); + } + function g(l) { + if (!(this instanceof g)) return new g(l); + x.call(this, l), m.call(this, l), l && l.readable === !1 && (this.readable = !1), l && l.writable === !1 && (this.writable = !1), this.allowHalfOpen = !0, l && l.allowHalfOpen === !1 && (this.allowHalfOpen = !1), this.once("end", M); + } + function M() { + this.allowHalfOpen || this._writableState.ended || s.nextTick(R, this); + } + function R(l) { + l.end(); + } + Object.defineProperty(g.prototype, "writableHighWaterMark", { enumerable: !1, get: function() { + return this._writableState.highWaterMark; + } }), Object.defineProperty(g.prototype, "destroyed", { get: function() { + return this._readableState !== void 0 && this._writableState !== void 0 && this._readableState.destroyed && this._writableState.destroyed; + }, set: function(l) { + this._readableState !== void 0 && this._writableState !== void 0 && (this._readableState.destroyed = l, this._writableState.destroyed = l); + } }), g.prototype._destroy = function(l, o) { + this.push(null), this.end(), s.nextTick(o, l); + }; + }, { "./_stream_readable": 72, "./_stream_writable": 74, "core-util-is": 26, inherits: 31, "process-nextick-args": 65 }], 71: [function(t, n, p) { + n.exports = d; + var s = t("./_stream_transform"), a = t("core-util-is"); + function d(x) { + if (!(this instanceof d)) return new d(x); + s.call(this, x); + } + a.inherits = t("inherits"), a.inherits(d, s), d.prototype._transform = function(x, m, h) { + h(null, x); + }; + }, { "./_stream_transform": 73, "core-util-is": 26, inherits: 31 }], 72: [function(t, n, p) { + (function(s, a) { + var d = t("process-nextick-args"); + n.exports = D; + var x, m = t("isarray"); + D.ReadableState = F, t("events").EventEmitter; + var h = function(B, U) { + return B.listeners(U).length; + }, y = t("./internal/streams/stream"), E = t("safe-buffer").Buffer, g = a.Uint8Array || function() { + }; + function M(B) { + return E.from(B); + } + function R(B) { + return E.isBuffer(B) || B instanceof g; + } + var l = t("core-util-is"); + l.inherits = t("inherits"); + var o = t("util"), c = void 0; + c = o && o.debuglog ? o.debuglog("stream") : function() { + }; + var f, b = t("./internal/streams/BufferList"), A = t("./internal/streams/destroy"); + l.inherits(D, y); + var _ = ["error", "close", "destroy", "pause", "resume"]; + function S(B, U, le) { + if (typeof B.prependListener == "function") return B.prependListener(U, le); + B._events && B._events[U] ? m(B._events[U]) ? B._events[U].unshift(le) : B._events[U] = [le, B._events[U]] : B.on(U, le); + } + function F(B, U) { + B = B || {}; + var le = U instanceof (x = x || t("./_stream_duplex")); + this.objectMode = !!B.objectMode, le && (this.objectMode = this.objectMode || !!B.readableObjectMode); + var he = B.highWaterMark, Te = B.readableHighWaterMark, u = this.objectMode ? 16 : 16384; + this.highWaterMark = he || he === 0 ? he : le && (Te || Te === 0) ? Te : u, this.highWaterMark = Math.floor(this.highWaterMark), this.buffer = new b(), this.length = 0, this.pipes = null, this.pipesCount = 0, this.flowing = null, this.ended = !1, this.endEmitted = !1, this.reading = !1, this.sync = !0, this.needReadable = !1, this.emittedReadable = !1, this.readableListening = !1, this.resumeScheduled = !1, this.destroyed = !1, this.defaultEncoding = B.defaultEncoding || "utf8", this.awaitDrain = 0, this.readingMore = !1, this.decoder = null, this.encoding = null, B.encoding && (f || (f = t("string_decoder/").StringDecoder), this.decoder = new f(B.encoding), this.encoding = B.encoding); + } + function D(B) { + if (x = x || t("./_stream_duplex"), !(this instanceof D)) return new D(B); + this._readableState = new F(B, this), this.readable = !0, B && (typeof B.read == "function" && (this._read = B.read), typeof B.destroy == "function" && (this._destroy = B.destroy)), y.call(this); + } + function H(B, U, le, he, Te) { + var u, w = B._readableState; + return U === null ? (w.reading = !1, te(B, w)) : (Te || (u = Q(w, U)), u ? B.emit("error", u) : w.objectMode || U && U.length > 0 ? (typeof U == "string" || w.objectMode || Object.getPrototypeOf(U) === E.prototype || (U = M(U)), he ? w.endEmitted ? B.emit("error", new Error("stream.unshift() after end event")) : j(B, w, U, !0) : w.ended ? B.emit("error", new Error("stream.push() after EOF")) : (w.reading = !1, w.decoder && !le ? (U = w.decoder.write(U), w.objectMode || U.length !== 0 ? j(B, w, U, !1) : de(B, w)) : j(B, w, U, !1))) : he || (w.reading = !1)), T(w); + } + function j(B, U, le, he) { + U.flowing && U.length === 0 && !U.sync ? (B.emit("data", le), B.read(0)) : (U.length += U.objectMode ? 1 : le.length, he ? U.buffer.unshift(le) : U.buffer.push(le), U.needReadable && me(B)), de(B, U); + } + function Q(B, U) { + var le; + return R(U) || typeof U == "string" || U === void 0 || B.objectMode || (le = new TypeError("Invalid non-string/buffer chunk")), le; + } + function T(B) { + return !B.ended && (B.needReadable || B.length < B.highWaterMark || B.length === 0); + } + Object.defineProperty(D.prototype, "destroyed", { get: function() { + return this._readableState !== void 0 && this._readableState.destroyed; + }, set: function(B) { + this._readableState && (this._readableState.destroyed = B); + } }), D.prototype.destroy = A.destroy, D.prototype._undestroy = A.undestroy, D.prototype._destroy = function(B, U) { + this.push(null), U(B); + }, D.prototype.push = function(B, U) { + var le, he = this._readableState; + return he.objectMode ? le = !0 : typeof B == "string" && ((U = U || he.defaultEncoding) !== he.encoding && (B = E.from(B, U), U = ""), le = !0), H(this, B, U, !1, le); + }, D.prototype.unshift = function(B) { + return H(this, B, null, !0, !1); + }, D.prototype.isPaused = function() { + return this._readableState.flowing === !1; + }, D.prototype.setEncoding = function(B) { + return f || (f = t("string_decoder/").StringDecoder), this._readableState.decoder = new f(B), this._readableState.encoding = B, this; + }; + var G = 8388608; + function X(B) { + return B >= G ? B = G : (B--, B |= B >>> 1, B |= B >>> 2, B |= B >>> 4, B |= B >>> 8, B |= B >>> 16, B++), B; + } + function fe(B, U) { + return B <= 0 || U.length === 0 && U.ended ? 0 : U.objectMode ? 1 : B != B ? U.flowing && U.length ? U.buffer.head.data.length : U.length : (B > U.highWaterMark && (U.highWaterMark = X(B)), B <= U.length ? B : U.ended ? U.length : (U.needReadable = !0, 0)); + } + function te(B, U) { + if (!U.ended) { + if (U.decoder) { + var le = U.decoder.end(); + le && le.length && (U.buffer.push(le), U.length += U.objectMode ? 1 : le.length); + } + U.ended = !0, me(B); + } + } + function me(B) { + var U = B._readableState; + U.needReadable = !1, U.emittedReadable || (c("emitReadable", U.flowing), U.emittedReadable = !0, U.sync ? d.nextTick(ee, B) : ee(B)); + } + function ee(B) { + c("emit readable"), B.emit("readable"), K(B); + } + function de(B, U) { + U.readingMore || (U.readingMore = !0, d.nextTick(P, B, U)); + } + function P(B, U) { + for (var le = U.length; !U.reading && !U.flowing && !U.ended && U.length < U.highWaterMark && (c("maybeReadMore read 0"), B.read(0), le !== U.length); ) le = U.length; + U.readingMore = !1; + } + function z(B) { + return function() { + var U = B._readableState; + c("pipeOnDrain", U.awaitDrain), U.awaitDrain && U.awaitDrain--, U.awaitDrain === 0 && h(B, "data") && (U.flowing = !0, K(B)); + }; + } + function ae(B) { + c("readable nexttick read 0"), B.read(0); + } + function re(B, U) { + U.resumeScheduled || (U.resumeScheduled = !0, d.nextTick(Y, B, U)); + } + function Y(B, U) { + U.reading || (c("resume read 0"), B.read(0)), U.resumeScheduled = !1, U.awaitDrain = 0, B.emit("resume"), K(B), U.flowing && !U.reading && B.read(0); + } + function K(B) { + var U = B._readableState; + for (c("flow", U.flowing); U.flowing && B.read() !== null; ) ; + } + function se(B, U) { + return U.length === 0 ? null : (U.objectMode ? le = U.buffer.shift() : !B || B >= U.length ? (le = U.decoder ? U.buffer.join("") : U.buffer.length === 1 ? U.buffer.head.data : U.buffer.concat(U.length), U.buffer.clear()) : le = ce(B, U.buffer, U.decoder), le); + var le; + } + function ce(B, U, le) { + var he; + return B < U.head.data.length ? (he = U.head.data.slice(0, B), U.head.data = U.head.data.slice(B)) : he = B === U.head.data.length ? U.shift() : le ? ve(B, U) : pe(B, U), he; + } + function ve(B, U) { + var le = U.head, he = 1, Te = le.data; + for (B -= Te.length; le = le.next; ) { + var u = le.data, w = B > u.length ? u.length : B; + if (w === u.length ? Te += u : Te += u.slice(0, B), (B -= w) === 0) { + w === u.length ? (++he, le.next ? U.head = le.next : U.head = U.tail = null) : (U.head = le, le.data = u.slice(w)); + break; + } + ++he; + } + return U.length -= he, Te; + } + function pe(B, U) { + var le = E.allocUnsafe(B), he = U.head, Te = 1; + for (he.data.copy(le), B -= he.data.length; he = he.next; ) { + var u = he.data, w = B > u.length ? u.length : B; + if (u.copy(le, le.length - B, 0, w), (B -= w) === 0) { + w === u.length ? (++Te, he.next ? U.head = he.next : U.head = U.tail = null) : (U.head = he, he.data = u.slice(w)); + break; + } + ++Te; + } + return U.length -= Te, le; + } + function Se(B) { + var U = B._readableState; + if (U.length > 0) throw new Error('"endReadable()" called on non-empty stream'); + U.endEmitted || (U.ended = !0, d.nextTick(Ee, U, B)); + } + function Ee(B, U) { + B.endEmitted || B.length !== 0 || (B.endEmitted = !0, U.readable = !1, U.emit("end")); + } + function Ce(B, U) { + for (var le = 0, he = B.length; le < he; le++) if (B[le] === U) return le; + return -1; + } + D.prototype.read = function(B) { + c("read", B), B = parseInt(B, 10); + var U = this._readableState, le = B; + if (B !== 0 && (U.emittedReadable = !1), B === 0 && U.needReadable && (U.length >= U.highWaterMark || U.ended)) return c("read: emitReadable", U.length, U.ended), U.length === 0 && U.ended ? Se(this) : me(this), null; + if ((B = fe(B, U)) === 0 && U.ended) return U.length === 0 && Se(this), null; + var he, Te = U.needReadable; + return c("need readable", Te), (U.length === 0 || U.length - B < U.highWaterMark) && c("length less than watermark", Te = !0), U.ended || U.reading ? c("reading or ended", Te = !1) : Te && (c("do read"), U.reading = !0, U.sync = !0, U.length === 0 && (U.needReadable = !0), this._read(U.highWaterMark), U.sync = !1, U.reading || (B = fe(le, U))), (he = B > 0 ? se(B, U) : null) === null ? (U.needReadable = !0, B = 0) : U.length -= B, U.length === 0 && (U.ended || (U.needReadable = !0), le !== B && U.ended && Se(this)), he !== null && this.emit("data", he), he; + }, D.prototype._read = function(B) { + this.emit("error", new Error("_read() is not implemented")); + }, D.prototype.pipe = function(B, U) { + var le = this, he = this._readableState; + switch (he.pipesCount) { + case 0: + he.pipes = B; + break; + case 1: + he.pipes = [he.pipes, B]; + break; + default: + he.pipes.push(B); + } + he.pipesCount += 1, c("pipe count=%d opts=%j", he.pipesCount, U); + var Te = (!U || U.end !== !1) && B !== s.stdout && B !== s.stderr ? w : e; + function u(O, I) { + c("onunpipe"), O === le && I && I.hasUnpiped === !1 && (I.hasUnpiped = !0, c("cleanup"), B.removeListener("close", L), B.removeListener("finish", C), B.removeListener("drain", k), B.removeListener("error", we), B.removeListener("unpipe", u), le.removeListener("end", w), le.removeListener("end", e), le.removeListener("data", ue), q = !0, !he.awaitDrain || B._writableState && !B._writableState.needDrain || k()); + } + function w() { + c("onend"), B.end(); + } + he.endEmitted ? d.nextTick(Te) : le.once("end", Te), B.on("unpipe", u); + var k = z(le); + B.on("drain", k); + var q = !1, ne = !1; + function ue(O) { + c("ondata"), ne = !1, B.write(O) !== !1 || ne || ((he.pipesCount === 1 && he.pipes === B || he.pipesCount > 1 && Ce(he.pipes, B) !== -1) && !q && (c("false write response, pause", le._readableState.awaitDrain), le._readableState.awaitDrain++, ne = !0), le.pause()); + } + function we(O) { + c("onerror", O), e(), B.removeListener("error", we), h(B, "error") === 0 && B.emit("error", O); + } + function L() { + B.removeListener("finish", C), e(); + } + function C() { + c("onfinish"), B.removeListener("close", L), e(); + } + function e() { + c("unpipe"), le.unpipe(B); + } + return le.on("data", ue), S(B, "error", we), B.once("close", L), B.once("finish", C), B.emit("pipe", le), he.flowing || (c("pipe resume"), le.resume()), B; + }, D.prototype.unpipe = function(B) { + var U = this._readableState, le = { hasUnpiped: !1 }; + if (U.pipesCount === 0) return this; + if (U.pipesCount === 1) return B && B !== U.pipes ? this : (B || (B = U.pipes), U.pipes = null, U.pipesCount = 0, U.flowing = !1, B && B.emit("unpipe", this, le), this); + if (!B) { + var he = U.pipes, Te = U.pipesCount; + U.pipes = null, U.pipesCount = 0, U.flowing = !1; + for (var u = 0; u < Te; u++) he[u].emit("unpipe", this, le); + return this; + } + var w = Ce(U.pipes, B); + return w === -1 ? this : (U.pipes.splice(w, 1), U.pipesCount -= 1, U.pipesCount === 1 && (U.pipes = U.pipes[0]), B.emit("unpipe", this, le), this); + }, D.prototype.on = function(B, U) { + var le = y.prototype.on.call(this, B, U); + if (B === "data") this._readableState.flowing !== !1 && this.resume(); + else if (B === "readable") { + var he = this._readableState; + he.endEmitted || he.readableListening || (he.readableListening = he.needReadable = !0, he.emittedReadable = !1, he.reading ? he.length && me(this) : d.nextTick(ae, this)); + } + return le; + }, D.prototype.addListener = D.prototype.on, D.prototype.resume = function() { + var B = this._readableState; + return B.flowing || (c("resume"), B.flowing = !0, re(this, B)), this; + }, D.prototype.pause = function() { + return c("call pause flowing=%j", this._readableState.flowing), this._readableState.flowing !== !1 && (c("pause"), this._readableState.flowing = !1, this.emit("pause")), this; + }, D.prototype.wrap = function(B) { + var U = this, le = this._readableState, he = !1; + for (var Te in B.on("end", function() { + if (c("wrapped end"), le.decoder && !le.ended) { + var w = le.decoder.end(); + w && w.length && U.push(w); + } + U.push(null); + }), B.on("data", function(w) { + c("wrapped data"), le.decoder && (w = le.decoder.write(w)), le.objectMode && w == null || (le.objectMode || w && w.length) && (U.push(w) || (he = !0, B.pause())); + }), B) this[Te] === void 0 && typeof B[Te] == "function" && (this[Te] = /* @__PURE__ */ (function(w) { + return function() { + return B[w].apply(B, arguments); + }; + })(Te)); + for (var u = 0; u < _.length; u++) B.on(_[u], this.emit.bind(this, _[u])); + return this._read = function(w) { + c("wrapped _read", w), he && (he = !1, B.resume()); + }, this; + }, Object.defineProperty(D.prototype, "readableHighWaterMark", { enumerable: !1, get: function() { + return this._readableState.highWaterMark; + } }), D._fromList = se; + }).call(this, t("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); + }, { "./_stream_duplex": 70, "./internal/streams/BufferList": 75, "./internal/streams/destroy": 76, "./internal/streams/stream": 77, _process: 66, "core-util-is": 26, events: 27, inherits: 31, isarray: 33, "process-nextick-args": 65, "safe-buffer": 79, "string_decoder/": 84, util: 21 }], 73: [function(t, n, p) { + n.exports = x; + var s = t("./_stream_duplex"), a = t("core-util-is"); + function d(y, E) { + var g = this._transformState; + g.transforming = !1; + var M = g.writecb; + if (!M) return this.emit("error", new Error("write callback called multiple times")); + g.writechunk = null, g.writecb = null, E != null && this.push(E), M(y); + var R = this._readableState; + R.reading = !1, (R.needReadable || R.length < R.highWaterMark) && this._read(R.highWaterMark); + } + function x(y) { + if (!(this instanceof x)) return new x(y); + s.call(this, y), this._transformState = { afterTransform: d.bind(this), needTransform: !1, transforming: !1, writecb: null, writechunk: null, writeencoding: null }, this._readableState.needReadable = !0, this._readableState.sync = !1, y && (typeof y.transform == "function" && (this._transform = y.transform), typeof y.flush == "function" && (this._flush = y.flush)), this.on("prefinish", m); + } + function m() { + var y = this; + typeof this._flush == "function" ? this._flush(function(E, g) { + h(y, E, g); + }) : h(this, null, null); + } + function h(y, E, g) { + if (E) return y.emit("error", E); + if (g != null && y.push(g), y._writableState.length) throw new Error("Calling transform done when ws.length != 0"); + if (y._transformState.transforming) throw new Error("Calling transform done when still transforming"); + return y.push(null); + } + a.inherits = t("inherits"), a.inherits(x, s), x.prototype.push = function(y, E) { + return this._transformState.needTransform = !1, s.prototype.push.call(this, y, E); + }, x.prototype._transform = function(y, E, g) { + throw new Error("_transform() is not implemented"); + }, x.prototype._write = function(y, E, g) { + var M = this._transformState; + if (M.writecb = g, M.writechunk = y, M.writeencoding = E, !M.transforming) { + var R = this._readableState; + (M.needTransform || R.needReadable || R.length < R.highWaterMark) && this._read(R.highWaterMark); + } + }, x.prototype._read = function(y) { + var E = this._transformState; + E.writechunk !== null && E.writecb && !E.transforming ? (E.transforming = !0, this._transform(E.writechunk, E.writeencoding, E.afterTransform)) : E.needTransform = !0; + }, x.prototype._destroy = function(y, E) { + var g = this; + s.prototype._destroy.call(this, y, function(M) { + E(M), g.emit("close"); + }); + }; + }, { "./_stream_duplex": 70, "core-util-is": 26, inherits: 31 }], 74: [function(t, n, p) { + (function(s, a, d) { + var x = t("process-nextick-args"); + function m(Y) { + var K = this; + this.next = null, this.entry = null, this.finish = function() { + re(K, Y); + }; + } + n.exports = S; + var h, y = !s.browser && ["v0.10", "v0.9."].indexOf(s.version.slice(0, 5)) > -1 ? d : x.nextTick; + S.WritableState = _; + var E = t("core-util-is"); + E.inherits = t("inherits"); + var g = { deprecate: t("util-deprecate") }, M = t("./internal/streams/stream"), R = t("safe-buffer").Buffer, l = a.Uint8Array || function() { + }; + function o(Y) { + return R.from(Y); + } + function c(Y) { + return R.isBuffer(Y) || Y instanceof l; + } + var f, b = t("./internal/streams/destroy"); + function A() { + } + function _(Y, K) { + h = h || t("./_stream_duplex"), Y = Y || {}; + var se = K instanceof h; + this.objectMode = !!Y.objectMode, se && (this.objectMode = this.objectMode || !!Y.writableObjectMode); + var ce = Y.highWaterMark, ve = Y.writableHighWaterMark, pe = this.objectMode ? 16 : 16384; + this.highWaterMark = ce || ce === 0 ? ce : se && (ve || ve === 0) ? ve : pe, this.highWaterMark = Math.floor(this.highWaterMark), this.finalCalled = !1, this.needDrain = !1, this.ending = !1, this.ended = !1, this.finished = !1, this.destroyed = !1; + var Se = Y.decodeStrings === !1; + this.decodeStrings = !Se, this.defaultEncoding = Y.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = function(Ee) { + X(K, Ee); + }, this.writecb = null, this.writelen = 0, this.bufferedRequest = null, this.lastBufferedRequest = null, this.pendingcb = 0, this.prefinished = !1, this.errorEmitted = !1, this.bufferedRequestCount = 0, this.corkedRequestsFree = new m(this); + } + function S(Y) { + if (h = h || t("./_stream_duplex"), !(f.call(S, this) || this instanceof h)) return new S(Y); + this._writableState = new _(Y, this), this.writable = !0, Y && (typeof Y.write == "function" && (this._write = Y.write), typeof Y.writev == "function" && (this._writev = Y.writev), typeof Y.destroy == "function" && (this._destroy = Y.destroy), typeof Y.final == "function" && (this._final = Y.final)), M.call(this); + } + function F(Y, K) { + var se = new Error("write after end"); + Y.emit("error", se), x.nextTick(K, se); + } + function D(Y, K, se, ce) { + var ve = !0, pe = !1; + return se === null ? pe = new TypeError("May not write null values to stream") : typeof se == "string" || se === void 0 || K.objectMode || (pe = new TypeError("Invalid non-string/buffer chunk")), pe && (Y.emit("error", pe), x.nextTick(ce, pe), ve = !1), ve; + } + function H(Y, K, se) { + return Y.objectMode || Y.decodeStrings === !1 || typeof K != "string" || (K = R.from(K, se)), K; + } + function j(Y, K, se, ce, ve, pe) { + if (!se) { + var Se = H(K, ce, ve); + ce !== Se && (se = !0, ve = "buffer", ce = Se); + } + var Ee = K.objectMode ? 1 : ce.length; + K.length += Ee; + var Ce = K.length < K.highWaterMark; + if (Ce || (K.needDrain = !0), K.writing || K.corked) { + var B = K.lastBufferedRequest; + K.lastBufferedRequest = { chunk: ce, encoding: ve, isBuf: se, callback: pe, next: null }, B ? B.next = K.lastBufferedRequest : K.bufferedRequest = K.lastBufferedRequest, K.bufferedRequestCount += 1; + } else Q(Y, K, !1, Ee, ce, ve, pe); + return Ce; + } + function Q(Y, K, se, ce, ve, pe, Se) { + K.writelen = ce, K.writecb = Se, K.writing = !0, K.sync = !0, se ? Y._writev(ve, K.onwrite) : Y._write(ve, pe, K.onwrite), K.sync = !1; + } + function T(Y, K, se, ce, ve) { + --K.pendingcb, se ? (x.nextTick(ve, ce), x.nextTick(z, Y, K), Y._writableState.errorEmitted = !0, Y.emit("error", ce)) : (ve(ce), Y._writableState.errorEmitted = !0, Y.emit("error", ce), z(Y, K)); + } + function G(Y) { + Y.writing = !1, Y.writecb = null, Y.length -= Y.writelen, Y.writelen = 0; + } + function X(Y, K) { + var se = Y._writableState, ce = se.sync, ve = se.writecb; + if (G(se), K) T(Y, se, ce, K, ve); + else { + var pe = ee(se); + pe || se.corked || se.bufferProcessing || !se.bufferedRequest || me(Y, se), ce ? y(fe, Y, se, pe, ve) : fe(Y, se, pe, ve); + } + } + function fe(Y, K, se, ce) { + se || te(Y, K), K.pendingcb--, ce(), z(Y, K); + } + function te(Y, K) { + K.length === 0 && K.needDrain && (K.needDrain = !1, Y.emit("drain")); + } + function me(Y, K) { + K.bufferProcessing = !0; + var se = K.bufferedRequest; + if (Y._writev && se && se.next) { + var ce = K.bufferedRequestCount, ve = new Array(ce), pe = K.corkedRequestsFree; + pe.entry = se; + for (var Se = 0, Ee = !0; se; ) ve[Se] = se, se.isBuf || (Ee = !1), se = se.next, Se += 1; + ve.allBuffers = Ee, Q(Y, K, !0, K.length, ve, "", pe.finish), K.pendingcb++, K.lastBufferedRequest = null, pe.next ? (K.corkedRequestsFree = pe.next, pe.next = null) : K.corkedRequestsFree = new m(K), K.bufferedRequestCount = 0; + } else { + for (; se; ) { + var Ce = se.chunk, B = se.encoding, U = se.callback; + if (Q(Y, K, !1, K.objectMode ? 1 : Ce.length, Ce, B, U), se = se.next, K.bufferedRequestCount--, K.writing) break; + } + se === null && (K.lastBufferedRequest = null); + } + K.bufferedRequest = se, K.bufferProcessing = !1; + } + function ee(Y) { + return Y.ending && Y.length === 0 && Y.bufferedRequest === null && !Y.finished && !Y.writing; + } + function de(Y, K) { + Y._final(function(se) { + K.pendingcb--, se && Y.emit("error", se), K.prefinished = !0, Y.emit("prefinish"), z(Y, K); + }); + } + function P(Y, K) { + K.prefinished || K.finalCalled || (typeof Y._final == "function" ? (K.pendingcb++, K.finalCalled = !0, x.nextTick(de, Y, K)) : (K.prefinished = !0, Y.emit("prefinish"))); + } + function z(Y, K) { + var se = ee(K); + return se && (P(Y, K), K.pendingcb === 0 && (K.finished = !0, Y.emit("finish"))), se; + } + function ae(Y, K, se) { + K.ending = !0, z(Y, K), se && (K.finished ? x.nextTick(se) : Y.once("finish", se)), K.ended = !0, Y.writable = !1; + } + function re(Y, K, se) { + var ce = Y.entry; + for (Y.entry = null; ce; ) { + var ve = ce.callback; + K.pendingcb--, ve(se), ce = ce.next; + } + K.corkedRequestsFree ? K.corkedRequestsFree.next = Y : K.corkedRequestsFree = Y; + } + E.inherits(S, M), _.prototype.getBuffer = function() { + for (var Y = this.bufferedRequest, K = []; Y; ) K.push(Y), Y = Y.next; + return K; + }, (function() { + try { + Object.defineProperty(_.prototype, "buffer", { get: g.deprecate(function() { + return this.getBuffer(); + }, "_writableState.buffer is deprecated. Use _writableState.getBuffer instead.", "DEP0003") }); + } catch { + } + })(), typeof Symbol == "function" && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] == "function" ? (f = Function.prototype[Symbol.hasInstance], Object.defineProperty(S, Symbol.hasInstance, { value: function(Y) { + return !!f.call(this, Y) || this === S && Y && Y._writableState instanceof _; + } })) : f = function(Y) { + return Y instanceof this; + }, S.prototype.pipe = function() { + this.emit("error", new Error("Cannot pipe, not readable")); + }, S.prototype.write = function(Y, K, se) { + var ce = this._writableState, ve = !1, pe = !ce.objectMode && c(Y); + return pe && !R.isBuffer(Y) && (Y = o(Y)), typeof K == "function" && (se = K, K = null), pe ? K = "buffer" : K || (K = ce.defaultEncoding), typeof se != "function" && (se = A), ce.ended ? F(this, se) : (pe || D(this, ce, Y, se)) && (ce.pendingcb++, ve = j(this, ce, pe, Y, K, se)), ve; + }, S.prototype.cork = function() { + this._writableState.corked++; + }, S.prototype.uncork = function() { + var Y = this._writableState; + Y.corked && (Y.corked--, Y.writing || Y.corked || Y.finished || Y.bufferProcessing || !Y.bufferedRequest || me(this, Y)); + }, S.prototype.setDefaultEncoding = function(Y) { + if (typeof Y == "string" && (Y = Y.toLowerCase()), !(["hex", "utf8", "utf-8", "ascii", "binary", "base64", "ucs2", "ucs-2", "utf16le", "utf-16le", "raw"].indexOf((Y + "").toLowerCase()) > -1)) throw new TypeError("Unknown encoding: " + Y); + return this._writableState.defaultEncoding = Y, this; + }, Object.defineProperty(S.prototype, "writableHighWaterMark", { enumerable: !1, get: function() { + return this._writableState.highWaterMark; + } }), S.prototype._write = function(Y, K, se) { + se(new Error("_write() is not implemented")); + }, S.prototype._writev = null, S.prototype.end = function(Y, K, se) { + var ce = this._writableState; + typeof Y == "function" ? (se = Y, Y = null, K = null) : typeof K == "function" && (se = K, K = null), Y != null && this.write(Y, K), ce.corked && (ce.corked = 1, this.uncork()), ce.ending || ce.finished || ae(this, ce, se); + }, Object.defineProperty(S.prototype, "destroyed", { get: function() { + return this._writableState !== void 0 && this._writableState.destroyed; + }, set: function(Y) { + this._writableState && (this._writableState.destroyed = Y); + } }), S.prototype.destroy = b.destroy, S.prototype._undestroy = b.undestroy, S.prototype._destroy = function(Y, K) { + this.end(), K(Y); + }; + }).call(this, t("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}, t("timers").setImmediate); + }, { "./_stream_duplex": 70, "./internal/streams/destroy": 76, "./internal/streams/stream": 77, _process: 66, "core-util-is": 26, inherits: 31, "process-nextick-args": 65, "safe-buffer": 79, timers: 85, "util-deprecate": 89 }], 75: [function(t, n, p) { + function s(m, h) { + if (!(m instanceof h)) throw new TypeError("Cannot call a class as a function"); + } + var a = t("safe-buffer").Buffer, d = t("util"); + function x(m, h, y) { + m.copy(h, y); + } + n.exports = (function() { + function m() { + s(this, m), this.head = null, this.tail = null, this.length = 0; + } + return m.prototype.push = function(h) { + var y = { data: h, next: null }; + this.length > 0 ? this.tail.next = y : this.head = y, this.tail = y, ++this.length; + }, m.prototype.unshift = function(h) { + var y = { data: h, next: this.head }; + this.length === 0 && (this.tail = y), this.head = y, ++this.length; + }, m.prototype.shift = function() { + if (this.length !== 0) { + var h = this.head.data; + return this.length === 1 ? this.head = this.tail = null : this.head = this.head.next, --this.length, h; + } + }, m.prototype.clear = function() { + this.head = this.tail = null, this.length = 0; + }, m.prototype.join = function(h) { + if (this.length === 0) return ""; + for (var y = this.head, E = "" + y.data; y = y.next; ) E += h + y.data; + return E; + }, m.prototype.concat = function(h) { + if (this.length === 0) return a.alloc(0); + if (this.length === 1) return this.head.data; + for (var y = a.allocUnsafe(h >>> 0), E = this.head, g = 0; E; ) x(E.data, y, g), g += E.data.length, E = E.next; + return y; + }, m; + })(), d && d.inspect && d.inspect.custom && (n.exports.prototype[d.inspect.custom] = function() { + var m = d.inspect({ length: this.length }); + return this.constructor.name + " " + m; + }); + }, { "safe-buffer": 79, util: 21 }], 76: [function(t, n, p) { + var s = t("process-nextick-args"); + function a(m, h) { + var y = this, E = this._readableState && this._readableState.destroyed, g = this._writableState && this._writableState.destroyed; + return E || g ? (h ? h(m) : !m || this._writableState && this._writableState.errorEmitted || s.nextTick(x, this, m), this) : (this._readableState && (this._readableState.destroyed = !0), this._writableState && (this._writableState.destroyed = !0), this._destroy(m || null, function(M) { + !h && M ? (s.nextTick(x, y, M), y._writableState && (y._writableState.errorEmitted = !0)) : h && h(M); + }), this); + } + function d() { + this._readableState && (this._readableState.destroyed = !1, this._readableState.reading = !1, this._readableState.ended = !1, this._readableState.endEmitted = !1), this._writableState && (this._writableState.destroyed = !1, this._writableState.ended = !1, this._writableState.ending = !1, this._writableState.finished = !1, this._writableState.errorEmitted = !1); + } + function x(m, h) { + m.emit("error", h); + } + n.exports = { destroy: a, undestroy: d }; + }, { "process-nextick-args": 65 }], 77: [function(t, n, p) { + n.exports = t("events").EventEmitter; + }, { events: 27 }], 78: [function(t, n, p) { + p = n.exports = t("./lib/_stream_readable.js"), p.Stream = p, p.Readable = p, p.Writable = t("./lib/_stream_writable.js"), p.Duplex = t("./lib/_stream_duplex.js"), p.Transform = t("./lib/_stream_transform.js"), p.PassThrough = t("./lib/_stream_passthrough.js"); + }, { "./lib/_stream_duplex.js": 70, "./lib/_stream_passthrough.js": 71, "./lib/_stream_readable.js": 72, "./lib/_stream_transform.js": 73, "./lib/_stream_writable.js": 74 }], 79: [function(t, n, p) { + var s = t("buffer"), a = s.Buffer; + function d(m, h) { + for (var y in m) h[y] = m[y]; + } + function x(m, h, y) { + return a(m, h, y); + } + a.from && a.alloc && a.allocUnsafe && a.allocUnsafeSlow ? n.exports = s : (d(s, p), p.Buffer = x), d(a, x), x.from = function(m, h, y) { + if (typeof m == "number") throw new TypeError("Argument must not be a number"); + return a(m, h, y); + }, x.alloc = function(m, h, y) { + if (typeof m != "number") throw new TypeError("Argument must be a number"); + var E = a(m); + return h !== void 0 ? typeof y == "string" ? E.fill(h, y) : E.fill(h) : E.fill(0), E; + }, x.allocUnsafe = function(m) { + if (typeof m != "number") throw new TypeError("Argument must be a number"); + return a(m); + }, x.allocUnsafeSlow = function(m) { + if (typeof m != "number") throw new TypeError("Argument must be a number"); + return s.SlowBuffer(m); + }; + }, { buffer: 23 }], 80: [function(t, n, p) { + (function(s) { + var a = t("./lib/request"), d = t("./lib/response"), x = t("xtend"), m = t("builtin-status-codes"), h = t("url"), y = p; + y.request = function(E, g) { + E = typeof E == "string" ? h.parse(E) : x(E); + var M = s.location.protocol.search(/^https?:$/) === -1 ? "http:" : "", R = E.protocol || M, l = E.hostname || E.host, o = E.port, c = E.path || "/"; + l && l.indexOf(":") !== -1 && (l = "[" + l + "]"), E.url = (l ? R + "//" + l : "") + (o ? ":" + o : "") + c, E.method = (E.method || "GET").toUpperCase(), E.headers = E.headers || {}; + var f = new a(E); + return g && f.on("response", g), f; + }, y.get = function(E, g) { + var M = y.request(E, g); + return M.end(), M; + }, y.ClientRequest = a, y.IncomingMessage = d.IncomingMessage, y.Agent = function() { + }, y.Agent.defaultMaxSockets = 4, y.globalAgent = new y.Agent(), y.STATUS_CODES = m, y.METHODS = ["CHECKOUT", "CONNECT", "COPY", "DELETE", "GET", "HEAD", "LOCK", "M-SEARCH", "MERGE", "MKACTIVITY", "MKCOL", "MOVE", "NOTIFY", "OPTIONS", "PATCH", "POST", "PROPFIND", "PROPPATCH", "PURGE", "PUT", "REPORT", "SEARCH", "SUBSCRIBE", "TRACE", "UNLOCK", "UNSUBSCRIBE"]; + }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); + }, { "./lib/request": 82, "./lib/response": 83, "builtin-status-codes": 24, url: 87, xtend: 90 }], 81: [function(t, n, p) { + (function(s) { + p.fetch = y(s.fetch) && y(s.ReadableStream), p.writableStream = y(s.WritableStream), p.abortController = y(s.AbortController), p.blobConstructor = !1; + try { + new Blob([new ArrayBuffer(1)]), p.blobConstructor = !0; + } catch { + } + var a; + function d() { + if (a !== void 0) return a; + if (s.XMLHttpRequest) { + a = new s.XMLHttpRequest(); + try { + a.open("GET", s.XDomainRequest ? "/" : "https://example.com"); + } catch { + a = null; + } + } else a = null; + return a; + } + function x(E) { + var g = d(); + if (!g) return !1; + try { + return g.responseType = E, g.responseType === E; + } catch { + } + return !1; + } + var m = s.ArrayBuffer !== void 0, h = m && y(s.ArrayBuffer.prototype.slice); + function y(E) { + return typeof E == "function"; + } + p.arraybuffer = p.fetch || m && x("arraybuffer"), p.msstream = !p.fetch && h && x("ms-stream"), p.mozchunkedarraybuffer = !p.fetch && m && x("moz-chunked-arraybuffer"), p.overrideMimeType = p.fetch || !!d() && y(d().overrideMimeType), p.vbArray = y(s.VBArray), a = null; + }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); + }, {}], 82: [function(t, n, p) { + (function(s, a, d) { + var x = t("./capability"), m = t("inherits"), h = t("./response"), y = t("readable-stream"), E = t("to-arraybuffer"), g = h.IncomingMessage, M = h.readyStates; + function R(f, b) { + return x.fetch && b ? "fetch" : x.mozchunkedarraybuffer ? "moz-chunked-arraybuffer" : x.msstream ? "ms-stream" : x.arraybuffer && f ? "arraybuffer" : x.vbArray && f ? "text:vbarray" : "text"; + } + var l = n.exports = function(f) { + var b, A = this; + y.Writable.call(A), A._opts = f, A._body = [], A._headers = {}, f.auth && A.setHeader("Authorization", "Basic " + new d(f.auth).toString("base64")), Object.keys(f.headers).forEach(function(S) { + A.setHeader(S, f.headers[S]); + }); + var _ = !0; + if (f.mode === "disable-fetch" || "requestTimeout" in f && !x.abortController) _ = !1, b = !0; + else if (f.mode === "prefer-streaming") b = !1; + else if (f.mode === "allow-wrong-content-type") b = !x.overrideMimeType; + else { + if (f.mode && f.mode !== "default" && f.mode !== "prefer-fast") throw new Error("Invalid value for opts.mode"); + b = !0; + } + A._mode = R(b, _), A._fetchTimer = null, A.on("finish", function() { + A._onFinish(); + }); + }; + function o(f) { + try { + var b = f.status; + return b !== null && b !== 0; + } catch { + return !1; + } + } + m(l, y.Writable), l.prototype.setHeader = function(f, b) { + var A = f.toLowerCase(); + c.indexOf(A) === -1 && (this._headers[A] = { name: f, value: b }); + }, l.prototype.getHeader = function(f) { + var b = this._headers[f.toLowerCase()]; + return b ? b.value : null; + }, l.prototype.removeHeader = function(f) { + delete this._headers[f.toLowerCase()]; + }, l.prototype._onFinish = function() { + var f = this; + if (!f._destroyed) { + var b = f._opts, A = f._headers, _ = null; + b.method !== "GET" && b.method !== "HEAD" && (_ = x.arraybuffer ? E(d.concat(f._body)) : x.blobConstructor ? new a.Blob(f._body.map(function(j) { + return E(j); + }), { type: (A["content-type"] || {}).value || "" }) : d.concat(f._body).toString()); + var S = []; + if (Object.keys(A).forEach(function(j) { + var Q = A[j].name, T = A[j].value; + Array.isArray(T) ? T.forEach(function(G) { + S.push([Q, G]); + }) : S.push([Q, T]); + }), f._mode === "fetch") { + var F = null; + if (x.abortController) { + var D = new AbortController(); + F = D.signal, f._fetchAbortController = D, "requestTimeout" in b && b.requestTimeout !== 0 && (f._fetchTimer = a.setTimeout(function() { + f.emit("requestTimeout"), f._fetchAbortController && f._fetchAbortController.abort(); + }, b.requestTimeout)); + } + a.fetch(f._opts.url, { method: f._opts.method, headers: S, body: _ || void 0, mode: "cors", credentials: b.withCredentials ? "include" : "same-origin", signal: F }).then(function(j) { + f._fetchResponse = j, f._connect(); + }, function(j) { + a.clearTimeout(f._fetchTimer), f._destroyed || f.emit("error", j); + }); + } else { + var H = f._xhr = new a.XMLHttpRequest(); + try { + H.open(f._opts.method, f._opts.url, !0); + } catch (j) { + return void s.nextTick(function() { + f.emit("error", j); + }); + } + "responseType" in H && (H.responseType = f._mode.split(":")[0]), "withCredentials" in H && (H.withCredentials = !!b.withCredentials), f._mode === "text" && "overrideMimeType" in H && H.overrideMimeType("text/plain; charset=x-user-defined"), "requestTimeout" in b && (H.timeout = b.requestTimeout, H.ontimeout = function() { + f.emit("requestTimeout"); + }), S.forEach(function(j) { + H.setRequestHeader(j[0], j[1]); + }), f._response = null, H.onreadystatechange = function() { + switch (H.readyState) { + case M.LOADING: + case M.DONE: + f._onXHRProgress(); + } + }, f._mode === "moz-chunked-arraybuffer" && (H.onprogress = function() { + f._onXHRProgress(); + }), H.onerror = function() { + f._destroyed || f.emit("error", new Error("XHR error")); + }; + try { + H.send(_); + } catch (j) { + return void s.nextTick(function() { + f.emit("error", j); + }); + } + } + } + }, l.prototype._onXHRProgress = function() { + o(this._xhr) && !this._destroyed && (this._response || this._connect(), this._response._onXHRProgress()); + }, l.prototype._connect = function() { + var f = this; + f._destroyed || (f._response = new g(f._xhr, f._fetchResponse, f._mode, f._fetchTimer), f._response.on("error", function(b) { + f.emit("error", b); + }), f.emit("response", f._response)); + }, l.prototype._write = function(f, b, A) { + this._body.push(f), A(); + }, l.prototype.abort = l.prototype.destroy = function() { + this._destroyed = !0, a.clearTimeout(this._fetchTimer), this._response && (this._response._destroyed = !0), this._xhr ? this._xhr.abort() : this._fetchAbortController && this._fetchAbortController.abort(); + }, l.prototype.end = function(f, b, A) { + typeof f == "function" && (A = f, f = void 0), y.Writable.prototype.end.call(this, f, b, A); + }, l.prototype.flushHeaders = function() { + }, l.prototype.setTimeout = function() { + }, l.prototype.setNoDelay = function() { + }, l.prototype.setSocketKeepAlive = function() { + }; + var c = ["accept-charset", "accept-encoding", "access-control-request-headers", "access-control-request-method", "connection", "content-length", "cookie", "cookie2", "date", "dnt", "expect", "host", "keep-alive", "origin", "referer", "te", "trailer", "transfer-encoding", "upgrade", "via"]; + }).call(this, t("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}, t("buffer").Buffer); + }, { "./capability": 81, "./response": 83, _process: 66, buffer: 23, inherits: 31, "readable-stream": 78, "to-arraybuffer": 86 }], 83: [function(t, n, p) { + (function(s, a, d) { + var x = t("./capability"), m = t("inherits"), h = t("readable-stream"), y = p.readyStates = { UNSENT: 0, OPENED: 1, HEADERS_RECEIVED: 2, LOADING: 3, DONE: 4 }, E = p.IncomingMessage = function(g, M, R, l) { + var o = this; + if (h.Readable.call(o), o._mode = R, o.headers = {}, o.rawHeaders = [], o.trailers = {}, o.rawTrailers = [], o.on("end", function() { + s.nextTick(function() { + o.emit("close"); + }); + }), R === "fetch") { + if (o._fetchResponse = M, o.url = M.url, o.statusCode = M.status, o.statusMessage = M.statusText, M.headers.forEach(function(_, S) { + o.headers[S.toLowerCase()] = _, o.rawHeaders.push(S, _); + }), x.writableStream) { + var c = new WritableStream({ write: function(_) { + return new Promise(function(S, F) { + o._destroyed ? F() : o.push(new d(_)) ? S() : o._resumeFetch = S; + }); + }, close: function() { + a.clearTimeout(l), o._destroyed || o.push(null); + }, abort: function(_) { + o._destroyed || o.emit("error", _); + } }); + try { + return void M.body.pipeTo(c).catch(function(_) { + a.clearTimeout(l), o._destroyed || o.emit("error", _); + }); + } catch { + } + } + var f = M.body.getReader(); + (function _() { + f.read().then(function(S) { + if (!o._destroyed) { + if (S.done) return a.clearTimeout(l), void o.push(null); + o.push(new d(S.value)), _(); + } + }).catch(function(S) { + a.clearTimeout(l), o._destroyed || o.emit("error", S); + }); + })(); + } else if (o._xhr = g, o._pos = 0, o.url = g.responseURL, o.statusCode = g.status, o.statusMessage = g.statusText, g.getAllResponseHeaders().split(/\r?\n/).forEach(function(_) { + var S = _.match(/^([^:]+):\s*(.*)/); + if (S) { + var F = S[1].toLowerCase(); + F === "set-cookie" ? (o.headers[F] === void 0 && (o.headers[F] = []), o.headers[F].push(S[2])) : o.headers[F] !== void 0 ? o.headers[F] += ", " + S[2] : o.headers[F] = S[2], o.rawHeaders.push(S[1], S[2]); + } + }), o._charset = "x-user-defined", !x.overrideMimeType) { + var b = o.rawHeaders["mime-type"]; + if (b) { + var A = b.match(/;\s*charset=([^;])(;|$)/); + A && (o._charset = A[1].toLowerCase()); + } + o._charset || (o._charset = "utf-8"); + } + }; + m(E, h.Readable), E.prototype._read = function() { + var g = this._resumeFetch; + g && (this._resumeFetch = null, g()); + }, E.prototype._onXHRProgress = function() { + var g = this, M = g._xhr, R = null; + switch (g._mode) { + case "text:vbarray": + if (M.readyState !== y.DONE) break; + try { + R = new a.VBArray(M.responseBody).toArray(); + } catch { + } + if (R !== null) { + g.push(new d(R)); + break; + } + case "text": + try { + R = M.responseText; + } catch { + g._mode = "text:vbarray"; + break; + } + if (R.length > g._pos) { + var l = R.substr(g._pos); + if (g._charset === "x-user-defined") { + for (var o = new d(l.length), c = 0; c < l.length; c++) o[c] = 255 & l.charCodeAt(c); + g.push(o); + } else g.push(l, g._charset); + g._pos = R.length; + } + break; + case "arraybuffer": + if (M.readyState !== y.DONE || !M.response) break; + R = M.response, g.push(new d(new Uint8Array(R))); + break; + case "moz-chunked-arraybuffer": + if (R = M.response, M.readyState !== y.LOADING || !R) break; + g.push(new d(new Uint8Array(R))); + break; + case "ms-stream": + if (R = M.response, M.readyState !== y.LOADING) break; + var f = new a.MSStreamReader(); + f.onprogress = function() { + f.result.byteLength > g._pos && (g.push(new d(new Uint8Array(f.result.slice(g._pos)))), g._pos = f.result.byteLength); + }, f.onload = function() { + g.push(null); + }, f.readAsArrayBuffer(R); + } + g._xhr.readyState === y.DONE && g._mode !== "ms-stream" && g.push(null); + }; + }).call(this, t("_process"), typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}, t("buffer").Buffer); + }, { "./capability": 81, _process: 66, buffer: 23, inherits: 31, "readable-stream": 78 }], 84: [function(t, n, p) { + var s = t("safe-buffer").Buffer, a = s.isEncoding || function(_) { + switch ((_ = "" + _) && _.toLowerCase()) { + case "hex": + case "utf8": + case "utf-8": + case "ascii": + case "binary": + case "base64": + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + case "raw": + return !0; + default: + return !1; + } + }; + function d(_) { + if (!_) return "utf8"; + for (var S; ; ) switch (_) { + case "utf8": + case "utf-8": + return "utf8"; + case "ucs2": + case "ucs-2": + case "utf16le": + case "utf-16le": + return "utf16le"; + case "latin1": + case "binary": + return "latin1"; + case "base64": + case "ascii": + case "hex": + return _; + default: + if (S) return; + _ = ("" + _).toLowerCase(), S = !0; + } + } + function x(_) { + var S = d(_); + if (typeof S != "string" && (s.isEncoding === a || !a(_))) throw new Error("Unknown encoding: " + _); + return S || _; + } + function m(_) { + var S; + switch (this.encoding = x(_), this.encoding) { + case "utf16le": + this.text = l, this.end = o, S = 4; + break; + case "utf8": + this.fillLast = g, S = 4; + break; + case "base64": + this.text = c, this.end = f, S = 3; + break; + default: + return this.write = b, void (this.end = A); + } + this.lastNeed = 0, this.lastTotal = 0, this.lastChar = s.allocUnsafe(S); + } + function h(_) { + return _ <= 127 ? 0 : _ >> 5 == 6 ? 2 : _ >> 4 == 14 ? 3 : _ >> 3 == 30 ? 4 : _ >> 6 == 2 ? -1 : -2; + } + function y(_, S, F) { + var D = S.length - 1; + if (D < F) return 0; + var H = h(S[D]); + return H >= 0 ? (H > 0 && (_.lastNeed = H - 1), H) : --D < F || H === -2 ? 0 : (H = h(S[D])) >= 0 ? (H > 0 && (_.lastNeed = H - 2), H) : --D < F || H === -2 ? 0 : (H = h(S[D])) >= 0 ? (H > 0 && (H === 2 ? H = 0 : _.lastNeed = H - 3), H) : 0; + } + function E(_, S, F) { + if ((192 & S[0]) != 128) return _.lastNeed = 0, "�"; + if (_.lastNeed > 1 && S.length > 1) { + if ((192 & S[1]) != 128) return _.lastNeed = 1, "�"; + if (_.lastNeed > 2 && S.length > 2 && (192 & S[2]) != 128) return _.lastNeed = 2, "�"; + } + } + function g(_) { + var S = this.lastTotal - this.lastNeed, F = E(this, _); + return F !== void 0 ? F : this.lastNeed <= _.length ? (_.copy(this.lastChar, S, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal)) : (_.copy(this.lastChar, S, 0, _.length), void (this.lastNeed -= _.length)); + } + function M(_, S) { + var F = y(this, _, S); + if (!this.lastNeed) return _.toString("utf8", S); + this.lastTotal = F; + var D = _.length - (F - this.lastNeed); + return _.copy(this.lastChar, 0, D), _.toString("utf8", S, D); + } + function R(_) { + var S = _ && _.length ? this.write(_) : ""; + return this.lastNeed ? S + "�" : S; + } + function l(_, S) { + if ((_.length - S) % 2 == 0) { + var F = _.toString("utf16le", S); + if (F) { + var D = F.charCodeAt(F.length - 1); + if (D >= 55296 && D <= 56319) return this.lastNeed = 2, this.lastTotal = 4, this.lastChar[0] = _[_.length - 2], this.lastChar[1] = _[_.length - 1], F.slice(0, -1); + } + return F; + } + return this.lastNeed = 1, this.lastTotal = 2, this.lastChar[0] = _[_.length - 1], _.toString("utf16le", S, _.length - 1); + } + function o(_) { + var S = _ && _.length ? this.write(_) : ""; + if (this.lastNeed) { + var F = this.lastTotal - this.lastNeed; + return S + this.lastChar.toString("utf16le", 0, F); + } + return S; + } + function c(_, S) { + var F = (_.length - S) % 3; + return F === 0 ? _.toString("base64", S) : (this.lastNeed = 3 - F, this.lastTotal = 3, F === 1 ? this.lastChar[0] = _[_.length - 1] : (this.lastChar[0] = _[_.length - 2], this.lastChar[1] = _[_.length - 1]), _.toString("base64", S, _.length - F)); + } + function f(_) { + var S = _ && _.length ? this.write(_) : ""; + return this.lastNeed ? S + this.lastChar.toString("base64", 0, 3 - this.lastNeed) : S; + } + function b(_) { + return _.toString(this.encoding); + } + function A(_) { + return _ && _.length ? this.write(_) : ""; + } + p.StringDecoder = m, m.prototype.write = function(_) { + if (_.length === 0) return ""; + var S, F; + if (this.lastNeed) { + if ((S = this.fillLast(_)) === void 0) return ""; + F = this.lastNeed, this.lastNeed = 0; + } else F = 0; + return F < _.length ? S ? S + this.text(_, F) : this.text(_, F) : S || ""; + }, m.prototype.end = R, m.prototype.text = M, m.prototype.fillLast = function(_) { + if (this.lastNeed <= _.length) return _.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, this.lastNeed), this.lastChar.toString(this.encoding, 0, this.lastTotal); + _.copy(this.lastChar, this.lastTotal - this.lastNeed, 0, _.length), this.lastNeed -= _.length; + }; + }, { "safe-buffer": 79 }], 85: [function(t, n, p) { + (function(s, a) { + var d = t("process/browser.js").nextTick, x = Function.prototype.apply, m = Array.prototype.slice, h = {}, y = 0; + function E(g, M) { + this._id = g, this._clearFn = M; + } + p.setTimeout = function() { + return new E(x.call(setTimeout, window, arguments), clearTimeout); + }, p.setInterval = function() { + return new E(x.call(setInterval, window, arguments), clearInterval); + }, p.clearTimeout = p.clearInterval = function(g) { + g.close(); + }, E.prototype.unref = E.prototype.ref = function() { + }, E.prototype.close = function() { + this._clearFn.call(window, this._id); + }, p.enroll = function(g, M) { + clearTimeout(g._idleTimeoutId), g._idleTimeout = M; + }, p.unenroll = function(g) { + clearTimeout(g._idleTimeoutId), g._idleTimeout = -1; + }, p._unrefActive = p.active = function(g) { + clearTimeout(g._idleTimeoutId); + var M = g._idleTimeout; + M >= 0 && (g._idleTimeoutId = setTimeout(function() { + g._onTimeout && g._onTimeout(); + }, M)); + }, p.setImmediate = typeof s == "function" ? s : function(g) { + var M = y++, R = !(arguments.length < 2) && m.call(arguments, 1); + return h[M] = !0, d(function() { + h[M] && (R ? g.apply(null, R) : g.call(null), p.clearImmediate(M)); + }), M; + }, p.clearImmediate = typeof a == "function" ? a : function(g) { + delete h[g]; + }; + }).call(this, t("timers").setImmediate, t("timers").clearImmediate); + }, { "process/browser.js": 66, timers: 85 }], 86: [function(t, n, p) { + var s = t("buffer").Buffer; + n.exports = function(a) { + if (a instanceof Uint8Array) { + if (a.byteOffset === 0 && a.byteLength === a.buffer.byteLength) return a.buffer; + if (typeof a.buffer.slice == "function") return a.buffer.slice(a.byteOffset, a.byteOffset + a.byteLength); + } + if (s.isBuffer(a)) { + for (var d = new Uint8Array(a.length), x = a.length, m = 0; m < x; m++) d[m] = a[m]; + return d.buffer; + } + throw new Error("Argument must be a Buffer"); + }; + }, { buffer: 23 }], 87: [function(t, n, p) { + var s = t("punycode"), a = t("./util"); + function d() { + this.protocol = null, this.slashes = null, this.auth = null, this.host = null, this.port = null, this.hostname = null, this.hash = null, this.search = null, this.query = null, this.pathname = null, this.path = null, this.href = null; + } + p.parse = S, p.resolve = D, p.resolveObject = H, p.format = F, p.Url = d; + var x = /^([a-z0-9.+-]+:)/i, m = /:[0-9]*$/, h = /^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/, y = ["<", ">", '"', "`", " ", "\r", ` +`, " "], E = ["{", "}", "|", "\\", "^", "`"].concat(y), g = ["'"].concat(E), M = ["%", "/", "?", ";", "#"].concat(g), R = ["/", "?", "#"], l = 255, o = /^[+a-z0-9A-Z_-]{0,63}$/, c = /^([+a-z0-9A-Z_-]{0,63})(.*)$/, f = { javascript: !0, "javascript:": !0 }, b = { javascript: !0, "javascript:": !0 }, A = { http: !0, https: !0, ftp: !0, gopher: !0, file: !0, "http:": !0, "https:": !0, "ftp:": !0, "gopher:": !0, "file:": !0 }, _ = t("querystring"); + function S(j, Q, T) { + if (j && a.isObject(j) && j instanceof d) return j; + var G = new d(); + return G.parse(j, Q, T), G; + } + function F(j) { + return a.isString(j) && (j = S(j)), j instanceof d ? j.format() : d.prototype.format.call(j); + } + function D(j, Q) { + return S(j, !1, !0).resolve(Q); + } + function H(j, Q) { + return j ? S(j, !1, !0).resolveObject(Q) : Q; + } + d.prototype.parse = function(j, Q, T) { + if (!a.isString(j)) throw new TypeError("Parameter 'url' must be a string, not " + typeof j); + var G = j.indexOf("?"), X = G !== -1 && G < j.indexOf("#") ? "?" : "#", fe = j.split(X); + fe[0] = fe[0].replace(/\\/g, "/"); + var te = j = fe.join(X); + if (te = te.trim(), !T && j.split("#").length === 1) { + var me = h.exec(te); + if (me) return this.path = te, this.href = te, this.pathname = me[1], me[2] ? (this.search = me[2], this.query = Q ? _.parse(this.search.substr(1)) : this.search.substr(1)) : Q && (this.search = "", this.query = {}), this; + } + var ee = x.exec(te); + if (ee) { + var de = (ee = ee[0]).toLowerCase(); + this.protocol = de, te = te.substr(ee.length); + } + if (T || ee || te.match(/^\/\/[^@\/]+@[^@\/]+/)) { + var P = te.substr(0, 2) === "//"; + !P || ee && b[ee] || (te = te.substr(2), this.slashes = !0); + } + if (!b[ee] && (P || ee && !A[ee])) { + for (var z, ae, re = -1, Y = 0; Y < R.length; Y++) + (K = te.indexOf(R[Y])) !== -1 && (re === -1 || K < re) && (re = K); + for ((ae = re === -1 ? te.lastIndexOf("@") : te.lastIndexOf("@", re)) !== -1 && (z = te.slice(0, ae), te = te.slice(ae + 1), this.auth = decodeURIComponent(z)), re = -1, Y = 0; Y < M.length; Y++) { + var K; + (K = te.indexOf(M[Y])) !== -1 && (re === -1 || K < re) && (re = K); + } + re === -1 && (re = te.length), this.host = te.slice(0, re), te = te.slice(re), this.parseHost(), this.hostname = this.hostname || ""; + var se = this.hostname[0] === "[" && this.hostname[this.hostname.length - 1] === "]"; + if (!se) for (var ce = this.hostname.split(/\./), ve = (Y = 0, ce.length); Y < ve; Y++) { + var pe = ce[Y]; + if (pe && !pe.match(o)) { + for (var Se = "", Ee = 0, Ce = pe.length; Ee < Ce; Ee++) pe.charCodeAt(Ee) > 127 ? Se += "x" : Se += pe[Ee]; + if (!Se.match(o)) { + var B = ce.slice(0, Y), U = ce.slice(Y + 1), le = pe.match(c); + le && (B.push(le[1]), U.unshift(le[2])), U.length && (te = "/" + U.join(".") + te), this.hostname = B.join("."); + break; + } + } + } + this.hostname.length > l ? this.hostname = "" : this.hostname = this.hostname.toLowerCase(), se || (this.hostname = s.toASCII(this.hostname)); + var he = this.port ? ":" + this.port : "", Te = this.hostname || ""; + this.host = Te + he, this.href += this.host, se && (this.hostname = this.hostname.substr(1, this.hostname.length - 2), te[0] !== "/" && (te = "/" + te)); + } + if (!f[de]) for (Y = 0, ve = g.length; Y < ve; Y++) { + var u = g[Y]; + if (te.indexOf(u) !== -1) { + var w = encodeURIComponent(u); + w === u && (w = escape(u)), te = te.split(u).join(w); + } + } + var k = te.indexOf("#"); + k !== -1 && (this.hash = te.substr(k), te = te.slice(0, k)); + var q = te.indexOf("?"); + if (q !== -1 ? (this.search = te.substr(q), this.query = te.substr(q + 1), Q && (this.query = _.parse(this.query)), te = te.slice(0, q)) : Q && (this.search = "", this.query = {}), te && (this.pathname = te), A[de] && this.hostname && !this.pathname && (this.pathname = "/"), this.pathname || this.search) { + he = this.pathname || ""; + var ne = this.search || ""; + this.path = he + ne; + } + return this.href = this.format(), this; + }, d.prototype.format = function() { + var j = this.auth || ""; + j && (j = (j = encodeURIComponent(j)).replace(/%3A/i, ":"), j += "@"); + var Q = this.protocol || "", T = this.pathname || "", G = this.hash || "", X = !1, fe = ""; + this.host ? X = j + this.host : this.hostname && (X = j + (this.hostname.indexOf(":") === -1 ? this.hostname : "[" + this.hostname + "]"), this.port && (X += ":" + this.port)), this.query && a.isObject(this.query) && Object.keys(this.query).length && (fe = _.stringify(this.query)); + var te = this.search || fe && "?" + fe || ""; + return Q && Q.substr(-1) !== ":" && (Q += ":"), this.slashes || (!Q || A[Q]) && X !== !1 ? (X = "//" + (X || ""), T && T.charAt(0) !== "/" && (T = "/" + T)) : X || (X = ""), G && G.charAt(0) !== "#" && (G = "#" + G), te && te.charAt(0) !== "?" && (te = "?" + te), Q + X + (T = T.replace(/[?#]/g, function(me) { + return encodeURIComponent(me); + })) + (te = te.replace("#", "%23")) + G; + }, d.prototype.resolve = function(j) { + return this.resolveObject(S(j, !1, !0)).format(); + }, d.prototype.resolveObject = function(j) { + if (a.isString(j)) { + var Q = new d(); + Q.parse(j, !1, !0), j = Q; + } + for (var T = new d(), G = Object.keys(this), X = 0; X < G.length; X++) { + var fe = G[X]; + T[fe] = this[fe]; + } + if (T.hash = j.hash, j.href === "") return T.href = T.format(), T; + if (j.slashes && !j.protocol) { + for (var te = Object.keys(j), me = 0; me < te.length; me++) { + var ee = te[me]; + ee !== "protocol" && (T[ee] = j[ee]); + } + return A[T.protocol] && T.hostname && !T.pathname && (T.path = T.pathname = "/"), T.href = T.format(), T; + } + if (j.protocol && j.protocol !== T.protocol) { + if (!A[j.protocol]) { + for (var de = Object.keys(j), P = 0; P < de.length; P++) { + var z = de[P]; + T[z] = j[z]; + } + return T.href = T.format(), T; + } + if (T.protocol = j.protocol, j.host || b[j.protocol]) T.pathname = j.pathname; + else { + for (var ae = (j.pathname || "").split("/"); ae.length && !(j.host = ae.shift()); ) ; + j.host || (j.host = ""), j.hostname || (j.hostname = ""), ae[0] !== "" && ae.unshift(""), ae.length < 2 && ae.unshift(""), T.pathname = ae.join("/"); + } + if (T.search = j.search, T.query = j.query, T.host = j.host || "", T.auth = j.auth, T.hostname = j.hostname || j.host, T.port = j.port, T.pathname || T.search) { + var re = T.pathname || "", Y = T.search || ""; + T.path = re + Y; + } + return T.slashes = T.slashes || j.slashes, T.href = T.format(), T; + } + var K = T.pathname && T.pathname.charAt(0) === "/", se = j.host || j.pathname && j.pathname.charAt(0) === "/", ce = se || K || T.host && j.pathname, ve = ce, pe = T.pathname && T.pathname.split("/") || [], Se = (ae = j.pathname && j.pathname.split("/") || [], T.protocol && !A[T.protocol]); + if (Se && (T.hostname = "", T.port = null, T.host && (pe[0] === "" ? pe[0] = T.host : pe.unshift(T.host)), T.host = "", j.protocol && (j.hostname = null, j.port = null, j.host && (ae[0] === "" ? ae[0] = j.host : ae.unshift(j.host)), j.host = null), ce = ce && (ae[0] === "" || pe[0] === "")), se) T.host = j.host || j.host === "" ? j.host : T.host, T.hostname = j.hostname || j.hostname === "" ? j.hostname : T.hostname, T.search = j.search, T.query = j.query, pe = ae; + else if (ae.length) pe || (pe = []), pe.pop(), pe = pe.concat(ae), T.search = j.search, T.query = j.query; + else if (!a.isNullOrUndefined(j.search)) + return Se && (T.hostname = T.host = pe.shift(), (le = !!(T.host && T.host.indexOf("@") > 0) && T.host.split("@")) && (T.auth = le.shift(), T.host = T.hostname = le.shift())), T.search = j.search, T.query = j.query, a.isNull(T.pathname) && a.isNull(T.search) || (T.path = (T.pathname ? T.pathname : "") + (T.search ? T.search : "")), T.href = T.format(), T; + if (!pe.length) return T.pathname = null, T.search ? T.path = "/" + T.search : T.path = null, T.href = T.format(), T; + for (var Ee = pe.slice(-1)[0], Ce = (T.host || j.host || pe.length > 1) && (Ee === "." || Ee === "..") || Ee === "", B = 0, U = pe.length; U >= 0; U--) (Ee = pe[U]) === "." ? pe.splice(U, 1) : Ee === ".." ? (pe.splice(U, 1), B++) : B && (pe.splice(U, 1), B--); + if (!ce && !ve) for (; B--; B) pe.unshift(".."); + !ce || pe[0] === "" || pe[0] && pe[0].charAt(0) === "/" || pe.unshift(""), Ce && pe.join("/").substr(-1) !== "/" && pe.push(""); + var le, he = pe[0] === "" || pe[0] && pe[0].charAt(0) === "/"; + return Se && (T.hostname = T.host = he ? "" : pe.length ? pe.shift() : "", (le = !!(T.host && T.host.indexOf("@") > 0) && T.host.split("@")) && (T.auth = le.shift(), T.host = T.hostname = le.shift())), (ce = ce || T.host && pe.length) && !he && pe.unshift(""), pe.length ? T.pathname = pe.join("/") : (T.pathname = null, T.path = null), a.isNull(T.pathname) && a.isNull(T.search) || (T.path = (T.pathname ? T.pathname : "") + (T.search ? T.search : "")), T.auth = j.auth || T.auth, T.slashes = T.slashes || j.slashes, T.href = T.format(), T; + }, d.prototype.parseHost = function() { + var j = this.host, Q = m.exec(j); + Q && ((Q = Q[0]) !== ":" && (this.port = Q.substr(1)), j = j.substr(0, j.length - Q.length)), j && (this.hostname = j); + }; + }, { "./util": 88, punycode: 22, querystring: 69 }], 88: [function(t, n, p) { + n.exports = { isString: function(s) { + return typeof s == "string"; + }, isObject: function(s) { + return typeof s == "object" && s !== null; + }, isNull: function(s) { + return s === null; + }, isNullOrUndefined: function(s) { + return s == null; + } }; + }, {}], 89: [function(t, n, p) { + (function(s) { + function a(x, m) { + if (d("noDeprecation")) return x; + var h = !1; + return function() { + if (!h) { + if (d("throwDeprecation")) throw new Error(m); + d("traceDeprecation") ? console.trace(m) : console.warn(m), h = !0; + } + return x.apply(this, arguments); + }; + } + function d(x) { + try { + if (!s.localStorage) return !1; + } catch { + return !1; + } + var m = s.localStorage[x]; + return m != null && String(m).toLowerCase() === "true"; + } + n.exports = a; + }).call(this, typeof je < "u" ? je : typeof self < "u" ? self : typeof window < "u" ? window : {}); + }, {}], 90: [function(t, n, p) { + n.exports = a; + var s = Object.prototype.hasOwnProperty; + function a() { + for (var d = {}, x = 0; x < arguments.length; x++) { + var m = arguments[x]; + for (var h in m) s.call(m, h) && (d[h] = m[h]); + } + return d; + } + }, {}] }, {}, [3])(3); + }), (function(t, n) { + n(i); + })(this, (function(t) { + class n { + static get version() { + return "1.4.0"; + } + static toString() { + return "JavaScript Expression Parser (JSEP) v" + n.version; + } + static addUnaryOp(o) { + return n.max_unop_len = Math.max(o.length, n.max_unop_len), n.unary_ops[o] = 1, n; + } + static addBinaryOp(o, c, f) { + return n.max_binop_len = Math.max(o.length, n.max_binop_len), n.binary_ops[o] = c, f ? n.right_associative.add(o) : n.right_associative.delete(o), n; + } + static addIdentifierChar(o) { + return n.additional_identifier_chars.add(o), n; + } + static addLiteral(o, c) { + return n.literals[o] = c, n; + } + static removeUnaryOp(o) { + return delete n.unary_ops[o], o.length === n.max_unop_len && (n.max_unop_len = n.getMaxKeyLen(n.unary_ops)), n; + } + static removeAllUnaryOps() { + return n.unary_ops = {}, n.max_unop_len = 0, n; + } + static removeIdentifierChar(o) { + return n.additional_identifier_chars.delete(o), n; + } + static removeBinaryOp(o) { + return delete n.binary_ops[o], o.length === n.max_binop_len && (n.max_binop_len = n.getMaxKeyLen(n.binary_ops)), n.right_associative.delete(o), n; + } + static removeAllBinaryOps() { + return n.binary_ops = {}, n.max_binop_len = 0, n; + } + static removeLiteral(o) { + return delete n.literals[o], n; + } + static removeAllLiterals() { + return n.literals = {}, n; + } + get char() { + return this.expr.charAt(this.index); + } + get code() { + return this.expr.charCodeAt(this.index); + } + constructor(o) { + this.expr = o, this.index = 0; + } + static parse(o) { + return new n(o).parse(); + } + static getMaxKeyLen(o) { + return Math.max(0, ...Object.keys(o).map(((c) => c.length))); + } + static isDecimalDigit(o) { + return o >= 48 && o <= 57; + } + static binaryPrecedence(o) { + return n.binary_ops[o] || 0; + } + static isIdentifierStart(o) { + return o >= 65 && o <= 90 || o >= 97 && o <= 122 || o >= 128 && !n.binary_ops[String.fromCharCode(o)] || n.additional_identifier_chars.has(String.fromCharCode(o)); + } + static isIdentifierPart(o) { + return n.isIdentifierStart(o) || n.isDecimalDigit(o); + } + throwError(o) { + const c = new Error(o + " at character " + this.index); + throw c.index = this.index, c.description = o, c; + } + runHook(o, c) { + if (n.hooks[o]) { + const f = { context: this, node: c }; + return n.hooks.run(o, f), f.node; + } + return c; + } + searchHook(o) { + if (n.hooks[o]) { + const c = { context: this }; + return n.hooks[o].find((function(f) { + return f.call(c.context, c), c.node; + })), c.node; + } + } + gobbleSpaces() { + let o = this.code; + for (; o === n.SPACE_CODE || o === n.TAB_CODE || o === n.LF_CODE || o === n.CR_CODE; ) o = this.expr.charCodeAt(++this.index); + this.runHook("gobble-spaces"); + } + parse() { + this.runHook("before-all"); + const o = this.gobbleExpressions(), c = o.length === 1 ? o[0] : { type: n.COMPOUND, body: o }; + return this.runHook("after-all", c); + } + gobbleExpressions(o) { + let c, f, b = []; + for (; this.index < this.expr.length; ) if (c = this.code, c === n.SEMCOL_CODE || c === n.COMMA_CODE) this.index++; + else if (f = this.gobbleExpression()) b.push(f); + else if (this.index < this.expr.length) { + if (c === o) break; + this.throwError('Unexpected "' + this.char + '"'); + } + return b; + } + gobbleExpression() { + const o = this.searchHook("gobble-expression") || this.gobbleBinaryExpression(); + return this.gobbleSpaces(), this.runHook("after-expression", o); + } + gobbleBinaryOp() { + this.gobbleSpaces(); + let o = this.expr.substr(this.index, n.max_binop_len), c = o.length; + for (; c > 0; ) { + if (n.binary_ops.hasOwnProperty(o) && (!n.isIdentifierStart(this.code) || this.index + o.length < this.expr.length && !n.isIdentifierPart(this.expr.charCodeAt(this.index + o.length)))) return this.index += c, o; + o = o.substr(0, --c); + } + return !1; + } + gobbleBinaryExpression() { + let o, c, f, b, A, _, S, F, D; + if (_ = this.gobbleToken(), !_ || (c = this.gobbleBinaryOp(), !c)) return _; + for (A = { value: c, prec: n.binaryPrecedence(c), right_a: n.right_associative.has(c) }, S = this.gobbleToken(), S || this.throwError("Expected expression after " + c), b = [_, A, S]; c = this.gobbleBinaryOp(); ) { + if (f = n.binaryPrecedence(c), f === 0) { + this.index -= c.length; + break; + } + A = { value: c, prec: f, right_a: n.right_associative.has(c) }, D = c; + const H = (j) => A.right_a && j.right_a ? f > j.prec : f <= j.prec; + for (; b.length > 2 && H(b[b.length - 2]); ) S = b.pop(), c = b.pop().value, _ = b.pop(), o = { type: n.BINARY_EXP, operator: c, left: _, right: S }, b.push(o); + o = this.gobbleToken(), o || this.throwError("Expected expression after " + D), b.push(A, o); + } + for (F = b.length - 1, o = b[F]; F > 1; ) o = { type: n.BINARY_EXP, operator: b[F - 1].value, left: b[F - 2], right: o }, F -= 2; + return o; + } + gobbleToken() { + let o, c, f, b; + if (this.gobbleSpaces(), b = this.searchHook("gobble-token"), b) return this.runHook("after-token", b); + if (o = this.code, n.isDecimalDigit(o) || o === n.PERIOD_CODE) return this.gobbleNumericLiteral(); + if (o === n.SQUOTE_CODE || o === n.DQUOTE_CODE) b = this.gobbleStringLiteral(); + else if (o === n.OBRACK_CODE) b = this.gobbleArray(); + else { + for (c = this.expr.substr(this.index, n.max_unop_len), f = c.length; f > 0; ) { + if (n.unary_ops.hasOwnProperty(c) && (!n.isIdentifierStart(this.code) || this.index + c.length < this.expr.length && !n.isIdentifierPart(this.expr.charCodeAt(this.index + c.length)))) { + this.index += f; + const A = this.gobbleToken(); + return A || this.throwError("missing unaryOp argument"), this.runHook("after-token", { type: n.UNARY_EXP, operator: c, argument: A, prefix: !0 }); + } + c = c.substr(0, --f); + } + n.isIdentifierStart(o) ? (b = this.gobbleIdentifier(), n.literals.hasOwnProperty(b.name) ? b = { type: n.LITERAL, value: n.literals[b.name], raw: b.name } : b.name === n.this_str && (b = { type: n.THIS_EXP })) : o === n.OPAREN_CODE && (b = this.gobbleGroup()); + } + return b ? (b = this.gobbleTokenProperty(b), this.runHook("after-token", b)) : this.runHook("after-token", !1); + } + gobbleTokenProperty(o) { + this.gobbleSpaces(); + let c = this.code; + for (; c === n.PERIOD_CODE || c === n.OBRACK_CODE || c === n.OPAREN_CODE || c === n.QUMARK_CODE; ) { + let f; + if (c === n.QUMARK_CODE) { + if (this.expr.charCodeAt(this.index + 1) !== n.PERIOD_CODE) break; + f = !0, this.index += 2, this.gobbleSpaces(), c = this.code; + } + this.index++, c === n.OBRACK_CODE ? ((o = { type: n.MEMBER_EXP, computed: !0, object: o, property: this.gobbleExpression() }).property || this.throwError('Unexpected "' + this.char + '"'), this.gobbleSpaces(), c = this.code, c !== n.CBRACK_CODE && this.throwError("Unclosed ["), this.index++) : c === n.OPAREN_CODE ? o = { type: n.CALL_EXP, arguments: this.gobbleArguments(n.CPAREN_CODE), callee: o } : (c === n.PERIOD_CODE || f) && (f && this.index--, this.gobbleSpaces(), o = { type: n.MEMBER_EXP, computed: !1, object: o, property: this.gobbleIdentifier() }), f && (o.optional = !0), this.gobbleSpaces(), c = this.code; + } + return o; + } + gobbleNumericLiteral() { + let o, c, f = ""; + for (; n.isDecimalDigit(this.code); ) f += this.expr.charAt(this.index++); + if (this.code === n.PERIOD_CODE) for (f += this.expr.charAt(this.index++); n.isDecimalDigit(this.code); ) f += this.expr.charAt(this.index++); + if (o = this.char, o === "e" || o === "E") { + for (f += this.expr.charAt(this.index++), o = this.char, o !== "+" && o !== "-" || (f += this.expr.charAt(this.index++)); n.isDecimalDigit(this.code); ) f += this.expr.charAt(this.index++); + n.isDecimalDigit(this.expr.charCodeAt(this.index - 1)) || this.throwError("Expected exponent (" + f + this.char + ")"); + } + return c = this.code, n.isIdentifierStart(c) ? this.throwError("Variable names cannot start with a number (" + f + this.char + ")") : (c === n.PERIOD_CODE || f.length === 1 && f.charCodeAt(0) === n.PERIOD_CODE) && this.throwError("Unexpected period"), { type: n.LITERAL, value: parseFloat(f), raw: f }; + } + gobbleStringLiteral() { + let o = ""; + const c = this.index, f = this.expr.charAt(this.index++); + let b = !1; + for (; this.index < this.expr.length; ) { + let A = this.expr.charAt(this.index++); + if (A === f) { + b = !0; + break; + } + if (A === "\\") switch (A = this.expr.charAt(this.index++), A) { + case "n": + o += ` +`; + break; + case "r": + o += "\r"; + break; + case "t": + o += " "; + break; + case "b": + o += "\b"; + break; + case "f": + o += "\f"; + break; + case "v": + o += "\v"; + break; + default: + o += A; + } + else o += A; + } + return b || this.throwError('Unclosed quote after "' + o + '"'), { type: n.LITERAL, value: o, raw: this.expr.substring(c, this.index) }; + } + gobbleIdentifier() { + let o = this.code, c = this.index; + for (n.isIdentifierStart(o) ? this.index++ : this.throwError("Unexpected " + this.char); this.index < this.expr.length && (o = this.code, n.isIdentifierPart(o)); ) this.index++; + return { type: n.IDENTIFIER, name: this.expr.slice(c, this.index) }; + } + gobbleArguments(o) { + const c = []; + let f = !1, b = 0; + for (; this.index < this.expr.length; ) { + this.gobbleSpaces(); + let A = this.code; + if (A === o) { + f = !0, this.index++, o === n.CPAREN_CODE && b && b >= c.length && this.throwError("Unexpected token " + String.fromCharCode(o)); + break; + } + if (A === n.COMMA_CODE) { + if (this.index++, b++, b !== c.length) { + if (o === n.CPAREN_CODE) this.throwError("Unexpected token ,"); + else if (o === n.CBRACK_CODE) for (let _ = c.length; _ < b; _++) c.push(null); + } + } else if (c.length !== b && b !== 0) this.throwError("Expected comma"); + else { + const _ = this.gobbleExpression(); + _ && _.type !== n.COMPOUND || this.throwError("Expected comma"), c.push(_); + } + } + return f || this.throwError("Expected " + String.fromCharCode(o)), c; + } + gobbleGroup() { + this.index++; + let o = this.gobbleExpressions(n.CPAREN_CODE); + if (this.code === n.CPAREN_CODE) return this.index++, o.length === 1 ? o[0] : !!o.length && { type: n.SEQUENCE_EXP, expressions: o }; + this.throwError("Unclosed ("); + } + gobbleArray() { + return this.index++, { type: n.ARRAY_EXP, elements: this.gobbleArguments(n.CBRACK_CODE) }; + } + } + const p = new class { + add(l, o, c) { + if (typeof arguments[0] != "string") for (let f in arguments[0]) this.add(f, arguments[0][f], arguments[1]); + else (Array.isArray(l) ? l : [l]).forEach((function(f) { + this[f] = this[f] || [], o && this[f][c ? "unshift" : "push"](o); + }), this); + } + run(l, o) { + this[l] = this[l] || [], this[l].forEach((function(c) { + c.call(o && o.context ? o.context : o, o); + })); + } + }(); + Object.assign(n, { hooks: p, plugins: new class { + constructor(l) { + this.jsep = l, this.registered = {}; + } + register() { + for (var l = arguments.length, o = new Array(l), c = 0; c < l; c++) o[c] = arguments[c]; + o.forEach(((f) => { + if (typeof f != "object" || !f.name || !f.init) throw new Error("Invalid JSEP plugin format"); + this.registered[f.name] || (f.init(this.jsep), this.registered[f.name] = f); + })); + } + }(n), COMPOUND: "Compound", SEQUENCE_EXP: "SequenceExpression", IDENTIFIER: "Identifier", MEMBER_EXP: "MemberExpression", LITERAL: "Literal", THIS_EXP: "ThisExpression", CALL_EXP: "CallExpression", UNARY_EXP: "UnaryExpression", BINARY_EXP: "BinaryExpression", ARRAY_EXP: "ArrayExpression", TAB_CODE: 9, LF_CODE: 10, CR_CODE: 13, SPACE_CODE: 32, PERIOD_CODE: 46, COMMA_CODE: 44, SQUOTE_CODE: 39, DQUOTE_CODE: 34, OPAREN_CODE: 40, CPAREN_CODE: 41, OBRACK_CODE: 91, CBRACK_CODE: 93, QUMARK_CODE: 63, SEMCOL_CODE: 59, COLON_CODE: 58, unary_ops: { "-": 1, "!": 1, "~": 1, "+": 1 }, binary_ops: { "||": 1, "??": 1, "&&": 2, "|": 3, "^": 4, "&": 5, "==": 6, "!=": 6, "===": 6, "!==": 6, "<": 7, ">": 7, "<=": 7, ">=": 7, "<<": 8, ">>": 8, ">>>": 8, "+": 9, "-": 9, "*": 10, "/": 10, "%": 10, "**": 11 }, right_associative: /* @__PURE__ */ new Set(["**"]), additional_identifier_chars: /* @__PURE__ */ new Set(["$", "_"]), literals: { true: !0, false: !1, null: null }, this_str: "this" }), n.max_unop_len = n.getMaxKeyLen(n.unary_ops), n.max_binop_len = n.getMaxKeyLen(n.binary_ops); + const s = (l) => new n(l).parse(), a = Object.getOwnPropertyNames(class { + }); + Object.getOwnPropertyNames(n).filter(((l) => !a.includes(l) && s[l] === void 0)).forEach(((l) => { + s[l] = n[l]; + })), s.Jsep = n; + var d = { name: "ternary", init(l) { + l.hooks.add("after-expression", (function(o) { + if (o.node && this.code === l.QUMARK_CODE) { + this.index++; + const c = o.node, f = this.gobbleExpression(); + if (f || this.throwError("Expected expression"), this.gobbleSpaces(), this.code === l.COLON_CODE) { + this.index++; + const b = this.gobbleExpression(); + if (b || this.throwError("Expected expression"), o.node = { type: "ConditionalExpression", test: c, consequent: f, alternate: b }, c.operator && l.binary_ops[c.operator] <= 0.9) { + let A = c; + for (; A.right.operator && l.binary_ops[A.right.operator] <= 0.9; ) A = A.right; + o.node.test = A.right, A.right = o.node, o.node = c; + } + } else this.throwError("Expected :"); + } + })); + } }; + s.plugins.register(d); + var x = { name: "regex", init(l) { + l.hooks.add("gobble-token", (function(o) { + if (this.code === 47) { + const c = ++this.index; + let f = !1; + for (; this.index < this.expr.length; ) { + if (this.code === 47 && !f) { + const b = this.expr.slice(c, this.index); + let A, _ = ""; + for (; ++this.index < this.expr.length; ) { + const S = this.code; + if (!(S >= 97 && S <= 122 || S >= 65 && S <= 90 || S >= 48 && S <= 57)) break; + _ += this.char; + } + try { + A = new RegExp(b, _); + } catch (S) { + this.throwError(S.message); + } + return o.node = { type: l.LITERAL, value: A, raw: this.expr.slice(c - 1, this.index) }, o.node = this.gobbleTokenProperty(o.node), o.node; + } + this.code === l.OBRACK_CODE ? f = !0 : f && this.code === l.CBRACK_CODE && (f = !1), this.index += this.code === 92 ? 2 : 1; + } + this.throwError("Unclosed Regex"); + } + })); + } }; + const m = { name: "assignment", assignmentOperators: /* @__PURE__ */ new Set(["=", "*=", "**=", "/=", "%=", "+=", "-=", "<<=", ">>=", ">>>=", "&=", "^=", "|=", "||=", "&&=", "??="]), updateOperators: [43, 45], assignmentPrecedence: 0.9, init(l) { + const o = [l.IDENTIFIER, l.MEMBER_EXP]; + function c(f) { + m.assignmentOperators.has(f.operator) ? (f.type = "AssignmentExpression", c(f.left), c(f.right)) : f.operator || Object.values(f).forEach(((b) => { + b && typeof b == "object" && c(b); + })); + } + m.assignmentOperators.forEach(((f) => l.addBinaryOp(f, m.assignmentPrecedence, !0))), l.hooks.add("gobble-token", (function(f) { + const b = this.code; + m.updateOperators.some(((A) => A === b && A === this.expr.charCodeAt(this.index + 1))) && (this.index += 2, f.node = { type: "UpdateExpression", operator: b === 43 ? "++" : "--", argument: this.gobbleTokenProperty(this.gobbleIdentifier()), prefix: !0 }, f.node.argument && o.includes(f.node.argument.type) || this.throwError(`Unexpected ${f.node.operator}`)); + })), l.hooks.add("after-token", (function(f) { + if (f.node) { + const b = this.code; + m.updateOperators.some(((A) => A === b && A === this.expr.charCodeAt(this.index + 1))) && (o.includes(f.node.type) || this.throwError(`Unexpected ${f.node.operator}`), this.index += 2, f.node = { type: "UpdateExpression", operator: b === 43 ? "++" : "--", argument: f.node, prefix: !1 }); + } + })), l.hooks.add("after-expression", (function(f) { + f.node && c(f.node); + })); + } }; + s.plugins.register(x, m), s.addUnaryOp("typeof"), s.addLiteral("null", null), s.addLiteral("undefined", void 0); + const h = /* @__PURE__ */ new Set(["constructor", "__proto__", "__defineGetter__", "__defineSetter__"]), y = { evalAst(l, o) { + switch (l.type) { + case "BinaryExpression": + case "LogicalExpression": + return y.evalBinaryExpression(l, o); + case "Compound": + return y.evalCompound(l, o); + case "ConditionalExpression": + return y.evalConditionalExpression(l, o); + case "Identifier": + return y.evalIdentifier(l, o); + case "Literal": + return y.evalLiteral(l, o); + case "MemberExpression": + return y.evalMemberExpression(l, o); + case "UnaryExpression": + return y.evalUnaryExpression(l, o); + case "ArrayExpression": + return y.evalArrayExpression(l, o); + case "CallExpression": + return y.evalCallExpression(l, o); + case "AssignmentExpression": + return y.evalAssignmentExpression(l, o); + default: + throw SyntaxError("Unexpected expression", l); + } + }, evalBinaryExpression: (l, o) => ({ "||": (c, f) => c || f(), "&&": (c, f) => c && f(), "|": (c, f) => c | f(), "^": (c, f) => c ^ f(), "&": (c, f) => c & f(), "==": (c, f) => c == f(), "!=": (c, f) => c != f(), "===": (c, f) => c === f(), "!==": (c, f) => c !== f(), "<": (c, f) => c < f(), ">": (c, f) => c > f(), "<=": (c, f) => c <= f(), ">=": (c, f) => c >= f(), "<<": (c, f) => c << f(), ">>": (c, f) => c >> f(), ">>>": (c, f) => c >>> f(), "+": (c, f) => c + f(), "-": (c, f) => c - f(), "*": (c, f) => c * f(), "/": (c, f) => c / f(), "%": (c, f) => c % f() })[l.operator](y.evalAst(l.left, o), (() => y.evalAst(l.right, o))), evalCompound(l, o) { + let c; + for (let f = 0; f < l.body.length; f++) { + l.body[f].type === "Identifier" && ["var", "let", "const"].includes(l.body[f].name) && l.body[f + 1] && l.body[f + 1].type === "AssignmentExpression" && (f += 1); + const b = l.body[f]; + c = y.evalAst(b, o); + } + return c; + }, evalConditionalExpression: (l, o) => y.evalAst(l.test, o) ? y.evalAst(l.consequent, o) : y.evalAst(l.alternate, o), evalIdentifier(l, o) { + if (Object.hasOwn(o, l.name)) return o[l.name]; + throw ReferenceError(`${l.name} is not defined`); + }, evalLiteral: (l) => l.value, evalMemberExpression(l, o) { + const c = String(l.computed ? y.evalAst(l.property) : l.property.name), f = y.evalAst(l.object, o); + if (f == null) throw TypeError(`Cannot read properties of ${f} (reading '${c}')`); + if (!Object.hasOwn(f, c) && h.has(c)) throw TypeError(`Cannot read properties of ${f} (reading '${c}')`); + const b = f[c]; + return typeof b == "function" ? b.bind(f) : b; + }, evalUnaryExpression: (l, o) => ({ "-": (c) => -y.evalAst(c, o), "!": (c) => !y.evalAst(c, o), "~": (c) => ~y.evalAst(c, o), "+": (c) => +y.evalAst(c, o), typeof: (c) => typeof y.evalAst(c, o) })[l.operator](l.argument), evalArrayExpression: (l, o) => l.elements.map(((c) => y.evalAst(c, o))), evalCallExpression(l, o) { + const c = l.arguments.map(((f) => y.evalAst(f, o))); + return y.evalAst(l.callee, o)(...c); + }, evalAssignmentExpression(l, o) { + if (l.left.type !== "Identifier") throw SyntaxError("Invalid left-hand side in assignment"); + const c = l.left.name, f = y.evalAst(l.right, o); + return o[c] = f, o[c]; + } }; + function E(l, o) { + return (l = l.slice()).push(o), l; + } + function g(l, o) { + return (o = o.slice()).unshift(l), o; + } + class M extends Error { + constructor(o) { + super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'), this.avoidNew = !0, this.value = o, this.name = "NewError"; + } + } + function R(l, o, c, f, b) { + if (!(this instanceof R)) try { + return new R(l, o, c, f, b); + } catch (_) { + if (!_.avoidNew) throw _; + return _.value; + } + typeof l == "string" && (b = f, f = c, c = o, o = l, l = null); + const A = l && typeof l == "object"; + if (l = l || {}, this.json = l.json || c, this.path = l.path || o, this.resultType = l.resultType || "value", this.flatten = l.flatten || !1, this.wrap = !Object.hasOwn(l, "wrap") || l.wrap, this.sandbox = l.sandbox || {}, this.eval = l.eval === void 0 ? "safe" : l.eval, this.ignoreEvalErrors = l.ignoreEvalErrors !== void 0 && l.ignoreEvalErrors, this.parent = l.parent || null, this.parentProperty = l.parentProperty || null, this.callback = l.callback || f || null, this.otherTypeCallback = l.otherTypeCallback || b || function() { + throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator."); + }, l.autostart !== !1) { + const _ = { path: A ? l.path : o }; + A ? "json" in l && (_.json = l.json) : _.json = c; + const S = this.evaluate(_); + if (!S || typeof S != "object") throw new M(S); + return S; + } + } + R.prototype.evaluate = function(l, o, c, f) { + let b = this.parent, A = this.parentProperty, { flatten: _, wrap: S } = this; + if (this.currResultType = this.resultType, this.currEval = this.eval, this.currSandbox = this.sandbox, c = c || this.callback, this.currOtherTypeCallback = f || this.otherTypeCallback, o = o || this.json, (l = l || this.path) && typeof l == "object" && !Array.isArray(l)) { + if (!l.path && l.path !== "") throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().'); + if (!Object.hasOwn(l, "json")) throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().'); + ({ json: o } = l), _ = Object.hasOwn(l, "flatten") ? l.flatten : _, this.currResultType = Object.hasOwn(l, "resultType") ? l.resultType : this.currResultType, this.currSandbox = Object.hasOwn(l, "sandbox") ? l.sandbox : this.currSandbox, S = Object.hasOwn(l, "wrap") ? l.wrap : S, this.currEval = Object.hasOwn(l, "eval") ? l.eval : this.currEval, c = Object.hasOwn(l, "callback") ? l.callback : c, this.currOtherTypeCallback = Object.hasOwn(l, "otherTypeCallback") ? l.otherTypeCallback : this.currOtherTypeCallback, b = Object.hasOwn(l, "parent") ? l.parent : b, A = Object.hasOwn(l, "parentProperty") ? l.parentProperty : A, l = l.path; + } + if (b = b || null, A = A || null, Array.isArray(l) && (l = R.toPathString(l)), !l && l !== "" || !o) return; + const F = R.toPathArray(l); + F[0] === "$" && F.length > 1 && F.shift(), this._hasParentSelector = null; + const D = this._trace(F, o, ["$"], b, A, c).filter((function(H) { + return H && !H.isParentSelector; + })); + return D.length ? S || D.length !== 1 || D[0].hasArrExpr ? D.reduce(((H, j) => { + const Q = this._getPreferredOutput(j); + return _ && Array.isArray(Q) ? H = H.concat(Q) : H.push(Q), H; + }), []) : this._getPreferredOutput(D[0]) : S ? [] : void 0; + }, R.prototype._getPreferredOutput = function(l) { + const o = this.currResultType; + switch (o) { + case "all": { + const c = Array.isArray(l.path) ? l.path : R.toPathArray(l.path); + return l.pointer = R.toPointer(c), l.path = typeof l.path == "string" ? l.path : R.toPathString(l.path), l; + } + case "value": + case "parent": + case "parentProperty": + return l[o]; + case "path": + return R.toPathString(l[o]); + case "pointer": + return R.toPointer(l.path); + default: + throw new TypeError("Unknown result type"); + } + }, R.prototype._handleCallback = function(l, o, c) { + if (o) { + const f = this._getPreferredOutput(l); + l.path = typeof l.path == "string" ? l.path : R.toPathString(l.path), o(f, c, l); + } + }, R.prototype._trace = function(l, o, c, f, b, A, _, S) { + let F; + if (!l.length) return F = { path: c, value: o, parent: f, parentProperty: b, hasArrExpr: _ }, this._handleCallback(F, A, "value"), F; + const D = l[0], H = l.slice(1), j = []; + function Q(T) { + Array.isArray(T) ? T.forEach(((G) => { + j.push(G); + })) : j.push(T); + } + if ((typeof D != "string" || S) && o && Object.hasOwn(o, D)) Q(this._trace(H, o[D], E(c, D), o, D, A, _)); + else if (D === "*") this._walk(o, ((T) => { + Q(this._trace(H, o[T], E(c, T), o, T, A, !0, !0)); + })); + else if (D === "..") Q(this._trace(H, o, c, f, b, A, _)), this._walk(o, ((T) => { + typeof o[T] == "object" && Q(this._trace(l.slice(), o[T], E(c, T), o, T, A, !0)); + })); + else { + if (D === "^") return this._hasParentSelector = !0, { path: c.slice(0, -1), expr: H, isParentSelector: !0 }; + if (D === "~") return F = { path: E(c, D), value: b, parent: f, parentProperty: null }, this._handleCallback(F, A, "property"), F; + if (D === "$") Q(this._trace(H, o, c, null, null, A, _)); + else if (/^(-?\d*):(-?\d*):?(\d*)$/u.test(D)) Q(this._slice(D, H, o, c, f, b, A)); + else if (D.indexOf("?(") === 0) { + if (this.currEval === !1) throw new Error("Eval [?(expr)] prevented in JSONPath expression."); + const T = D.replace(/^\?\((.*?)\)$/u, "$1"), G = /@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(T); + G ? this._walk(o, ((X) => { + const fe = [G[2]], te = G[1] ? o[X][G[1]] : o[X]; + this._trace(fe, te, c, f, b, A, !0).length > 0 && Q(this._trace(H, o[X], E(c, X), o, X, A, !0)); + })) : this._walk(o, ((X) => { + this._eval(T, o[X], X, c, f, b) && Q(this._trace(H, o[X], E(c, X), o, X, A, !0)); + })); + } else if (D[0] === "(") { + if (this.currEval === !1) throw new Error("Eval [(expr)] prevented in JSONPath expression."); + Q(this._trace(g(this._eval(D, o, c.at(-1), c.slice(0, -1), f, b), H), o, c, f, b, A, _)); + } else if (D[0] === "@") { + let T = !1; + const G = D.slice(1, -2); + switch (G) { + case "scalar": + o && ["object", "function"].includes(typeof o) || (T = !0); + break; + case "boolean": + case "string": + case "undefined": + case "function": + typeof o === G && (T = !0); + break; + case "integer": + !Number.isFinite(o) || o % 1 || (T = !0); + break; + case "number": + Number.isFinite(o) && (T = !0); + break; + case "nonFinite": + typeof o != "number" || Number.isFinite(o) || (T = !0); + break; + case "object": + o && typeof o === G && (T = !0); + break; + case "array": + Array.isArray(o) && (T = !0); + break; + case "other": + T = this.currOtherTypeCallback(o, c, f, b); + break; + case "null": + o === null && (T = !0); + break; + default: + throw new TypeError("Unknown value type " + G); + } + if (T) return F = { path: c, value: o, parent: f, parentProperty: b }, this._handleCallback(F, A, "value"), F; + } else if (D[0] === "`" && o && Object.hasOwn(o, D.slice(1))) { + const T = D.slice(1); + Q(this._trace(H, o[T], E(c, T), o, T, A, _, !0)); + } else if (D.includes(",")) { + const T = D.split(","); + for (const G of T) Q(this._trace(g(G, H), o, c, f, b, A, !0)); + } else !S && o && Object.hasOwn(o, D) && Q(this._trace(H, o[D], E(c, D), o, D, A, _, !0)); + } + if (this._hasParentSelector) for (let T = 0; T < j.length; T++) { + const G = j[T]; + if (G && G.isParentSelector) { + const X = this._trace(G.expr, o, G.path, f, b, A, _); + if (Array.isArray(X)) { + j[T] = X[0]; + const fe = X.length; + for (let te = 1; te < fe; te++) T++, j.splice(T, 0, X[te]); + } else j[T] = X; + } + } + return j; + }, R.prototype._walk = function(l, o) { + if (Array.isArray(l)) { + const c = l.length; + for (let f = 0; f < c; f++) o(f); + } else l && typeof l == "object" && Object.keys(l).forEach(((c) => { + o(c); + })); + }, R.prototype._slice = function(l, o, c, f, b, A, _) { + if (!Array.isArray(c)) return; + const S = c.length, F = l.split(":"), D = F[2] && Number.parseInt(F[2]) || 1; + let H = F[0] && Number.parseInt(F[0]) || 0, j = F[1] && Number.parseInt(F[1]) || S; + H = H < 0 ? Math.max(0, H + S) : Math.min(S, H), j = j < 0 ? Math.max(0, j + S) : Math.min(S, j); + const Q = []; + for (let T = H; T < j; T += D) + this._trace(g(T, o), c, f, b, A, _, !0).forEach(((G) => { + Q.push(G); + })); + return Q; + }, R.prototype._eval = function(l, o, c, f, b, A) { + this.currSandbox._$_parentProperty = A, this.currSandbox._$_parent = b, this.currSandbox._$_property = c, this.currSandbox._$_root = this.json, this.currSandbox._$_v = o; + const _ = l.includes("@path"); + _ && (this.currSandbox._$_path = R.toPathString(f.concat([c]))); + const S = this.currEval + "Script:" + l; + if (!R.cache[S]) { + let F = l.replaceAll("@parentProperty", "_$_parentProperty").replaceAll("@parent", "_$_parent").replaceAll("@property", "_$_property").replaceAll("@root", "_$_root").replaceAll(/@([.\s)[])/gu, "_$_v$1"); + if (_ && (F = F.replaceAll("@path", "_$_path")), this.currEval === "safe" || this.currEval === !0 || this.currEval === void 0) R.cache[S] = new this.safeVm.Script(F); + else if (this.currEval === "native") R.cache[S] = new this.vm.Script(F); + else if (typeof this.currEval == "function" && this.currEval.prototype && Object.hasOwn(this.currEval.prototype, "runInNewContext")) { + const D = this.currEval; + R.cache[S] = new D(F); + } else { + if (typeof this.currEval != "function") throw new TypeError(`Unknown "eval" property "${this.currEval}"`); + R.cache[S] = { runInNewContext: (D) => this.currEval(F, D) }; + } + } + try { + return R.cache[S].runInNewContext(this.currSandbox); + } catch (F) { + if (this.ignoreEvalErrors) return !1; + throw new Error("jsonPath: " + F.message + ": " + l); + } + }, R.cache = {}, R.toPathString = function(l) { + const o = l, c = o.length; + let f = "$"; + for (let b = 1; b < c; b++) /^(~|\^|@.*?\(\))$/u.test(o[b]) || (f += /^[0-9*]+$/u.test(o[b]) ? "[" + o[b] + "]" : "['" + o[b] + "']"); + return f; + }, R.toPointer = function(l) { + const o = l, c = o.length; + let f = ""; + for (let b = 1; b < c; b++) /^(~|\^|@.*?\(\))$/u.test(o[b]) || (f += "/" + o[b].toString().replaceAll("~", "~0").replaceAll("/", "~1")); + return f; + }, R.toPathArray = function(l) { + const { cache: o } = R; + if (o[l]) return o[l].concat(); + const c = [], f = l.replaceAll(/@(?:null|boolean|number|string|integer|undefined|nonFinite|scalar|array|object|function|other)\(\)/gu, ";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu, (function(b, A) { + return "[#" + (c.push(A) - 1) + "]"; + })).replaceAll(/\[['"]([^'\]]*)['"]\]/gu, (function(b, A) { + return "['" + A.replaceAll(".", "%@%").replaceAll("~", "%%@@%%") + "']"; + })).replaceAll("~", ";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu, ";").replaceAll("%@%", ".").replaceAll("%%@@%%", "~").replaceAll(/(?:;)?(\^+)(?:;)?/gu, (function(b, A) { + return ";" + A.split("").join(";") + ";"; + })).replaceAll(/;;;|;;/gu, ";..;").replaceAll(/;$|'?\]|'$/gu, "").split(";").map((function(b) { + const A = b.match(/#(\d+)/u); + return A && A[1] ? c[A[1]] : b; + })); + return o[l] = f, o[l].concat(); + }, R.prototype.safeVm = { Script: class { + constructor(l) { + this.code = l, this.ast = s(this.code); + } + runInNewContext(l) { + const o = Object.assign(/* @__PURE__ */ Object.create(null), l); + return y.evalAst(this.ast, o); + } + } }, R.prototype.vm = { Script: class { + constructor(l) { + this.code = l; + } + runInNewContext(l) { + let o = this.code; + const c = Object.keys(l), f = []; + (function(S, F, D) { + const H = S.length; + for (let j = 0; j < H; j++) D(S[j]) && F.push(S.splice(j--, 1)[0]); + })(c, f, ((S) => typeof l[S] == "function")); + const b = c.map(((S) => l[S])); + o = f.reduce(((S, F) => { + let D = l[F].toString(); + return /function/u.test(D) || (D = "function " + D), "var " + F + "=" + D + ";" + S; + }), "") + o, /(['"])use strict\1/u.test(o) || c.includes("arguments") || (o = "var arguments = undefined;" + o), o = o.replace(/;\s*$/u, ""); + const A = o.lastIndexOf(";"), _ = A !== -1 ? o.slice(0, A + 1) + " return " + o.slice(A + 1) : " return " + o; + return new Function(...c, _)(...b); + } + } }, t.JSONPath = R; + })); + })(); + })(Ze, Ze.exports)), Ze.exports; +} +Rr(); +var Mr = Object.create, Lt = Object.defineProperty, kr = Object.getOwnPropertyDescriptor, Nt = Object.getOwnPropertyNames, Ir = Object.getPrototypeOf, Pr = Object.prototype.hasOwnProperty, De = (r, i) => function() { + return i || (0, r[Nt(r)[0]])((i = { exports: {} }).exports, i), i.exports; +}, Lr = (r, i, t, n) => { + if (i && typeof i == "object" || typeof i == "function") + for (let p of Nt(i)) + !Pr.call(r, p) && p !== t && Lt(r, p, { get: () => i[p], enumerable: !(n = kr(i, p)) || n.enumerable }); + return r; +}, jt = (r, i, t) => (t = r != null ? Mr(Ir(r)) : {}, Lr( + // If the importer is in node compatibility mode or this is not an ESM + // file that has been converted to a CommonJS file using a Babel- + // compatible transform (i.e. "__esModule" has not been set), then set + // "default" to the CommonJS "module.exports" for node compatibility. + Lt(t, "default", { value: r, enumerable: !0 }), + r +)), ut = De({ + "node_modules/ret/lib/types.js"(r, i) { + i.exports = { + ROOT: 0, + GROUP: 1, + POSITION: 2, + SET: 3, + RANGE: 4, + REPETITION: 5, + REFERENCE: 6, + CHAR: 7 + }; + } +}), $t = De({ + "node_modules/ret/lib/sets.js"(r) { + var i = ut(), t = () => [{ type: i.RANGE, from: 48, to: 57 }], n = () => [ + { type: i.CHAR, value: 95 }, + { type: i.RANGE, from: 97, to: 122 }, + { type: i.RANGE, from: 65, to: 90 } + ].concat(t()), p = () => [ + { type: i.CHAR, value: 9 }, + { type: i.CHAR, value: 10 }, + { type: i.CHAR, value: 11 }, + { type: i.CHAR, value: 12 }, + { type: i.CHAR, value: 13 }, + { type: i.CHAR, value: 32 }, + { type: i.CHAR, value: 160 }, + { type: i.CHAR, value: 5760 }, + { type: i.RANGE, from: 8192, to: 8202 }, + { type: i.CHAR, value: 8232 }, + { type: i.CHAR, value: 8233 }, + { type: i.CHAR, value: 8239 }, + { type: i.CHAR, value: 8287 }, + { type: i.CHAR, value: 12288 }, + { type: i.CHAR, value: 65279 } + ], s = () => [ + { type: i.CHAR, value: 10 }, + { type: i.CHAR, value: 13 }, + { type: i.CHAR, value: 8232 }, + { type: i.CHAR, value: 8233 } + ]; + r.words = () => ({ type: i.SET, set: n(), not: !1 }), r.notWords = () => ({ type: i.SET, set: n(), not: !0 }), r.ints = () => ({ type: i.SET, set: t(), not: !1 }), r.notInts = () => ({ type: i.SET, set: t(), not: !0 }), r.whitespace = () => ({ type: i.SET, set: p(), not: !1 }), r.notWhitespace = () => ({ type: i.SET, set: p(), not: !0 }), r.anyChar = () => ({ type: i.SET, set: s(), not: !0 }); + } +}), Nr = De({ + "node_modules/ret/lib/util.js"(r) { + var i = ut(), t = $t(), n = "@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^ ?", p = { 0: 0, t: 9, n: 10, v: 11, f: 12, r: 13 }; + r.strToChars = function(s) { + var a = /(\[\\b\])|(\\)?\\(?:u([A-F0-9]{4})|x([A-F0-9]{2})|(0?[0-7]{2})|c([@A-Z[\\\]^?])|([0tnvfr]))/g; + return s = s.replace(a, function(d, x, m, h, y, E, g, M) { + if (m) + return d; + var R = x ? 8 : h ? parseInt(h, 16) : y ? parseInt(y, 16) : E ? parseInt(E, 8) : g ? n.indexOf(g) : p[M], l = String.fromCharCode(R); + return /[[\]{}^$.|?*+()]/.test(l) && (l = "\\" + l), l; + }), s; + }, r.tokenizeClass = (s, a) => { + for (var d = [], x = /\\(?:(w)|(d)|(s)|(W)|(D)|(S))|((?:(?:\\)(.)|([^\]\\]))-(?:\\)?([^\]]))|(\])|(?:\\)?([^])/g, m, h; (m = x.exec(s)) != null; ) + if (m[1]) + d.push(t.words()); + else if (m[2]) + d.push(t.ints()); + else if (m[3]) + d.push(t.whitespace()); + else if (m[4]) + d.push(t.notWords()); + else if (m[5]) + d.push(t.notInts()); + else if (m[6]) + d.push(t.notWhitespace()); + else if (m[7]) + d.push({ + type: i.RANGE, + from: (m[8] || m[9]).charCodeAt(0), + to: m[10].charCodeAt(0) + }); + else if (h = m[12]) + d.push({ + type: i.CHAR, + value: h.charCodeAt(0) + }); + else + return [d, x.lastIndex]; + r.error(a, "Unterminated character class"); + }, r.error = (s, a) => { + throw new SyntaxError("Invalid regular expression: /" + s + "/: " + a); + }; + } +}), jr = De({ + "node_modules/ret/lib/positions.js"(r) { + var i = ut(); + r.wordBoundary = () => ({ type: i.POSITION, value: "b" }), r.nonWordBoundary = () => ({ type: i.POSITION, value: "B" }), r.begin = () => ({ type: i.POSITION, value: "^" }), r.end = () => ({ type: i.POSITION, value: "$" }); + } +}), $r = De({ + "node_modules/ret/lib/index.js"(r, i) { + var t = Nr(), n = ut(), p = $t(), s = jr(); + i.exports = (a) => { + var d = 0, x, m, h = { type: n.ROOT, stack: [] }, y = h, E = h.stack, g = [], M = (S) => { + t.error(a, `Nothing to repeat at column ${S - 1}`); + }, R = t.strToChars(a); + for (x = R.length; d < x; ) + switch (m = R[d++], m) { + case "\\": + switch (m = R[d++], m) { + case "b": + E.push(s.wordBoundary()); + break; + case "B": + E.push(s.nonWordBoundary()); + break; + case "w": + E.push(p.words()); + break; + case "W": + E.push(p.notWords()); + break; + case "d": + E.push(p.ints()); + break; + case "D": + E.push(p.notInts()); + break; + case "s": + E.push(p.whitespace()); + break; + case "S": + E.push(p.notWhitespace()); + break; + default: + /\d/.test(m) ? E.push({ type: n.REFERENCE, value: parseInt(m, 10) }) : E.push({ type: n.CHAR, value: m.charCodeAt(0) }); + } + break; + case "^": + E.push(s.begin()); + break; + case "$": + E.push(s.end()); + break; + case "[": + var l; + R[d] === "^" ? (l = !0, d++) : l = !1; + var o = t.tokenizeClass(R.slice(d), a); + d += o[1], E.push({ + type: n.SET, + set: o[0], + not: l + }); + break; + case ".": + E.push(p.anyChar()); + break; + case "(": + var c = { + type: n.GROUP, + stack: [], + remember: !0 + }; + m = R[d], m === "?" && (m = R[d + 1], d += 2, m === "=" ? c.followedBy = !0 : m === "!" ? c.notFollowedBy = !0 : m !== ":" && t.error( + a, + `Invalid group, character '${m}' after '?' at column ${d - 1}` + ), c.remember = !1), E.push(c), g.push(y), y = c, E = c.stack; + break; + case ")": + g.length === 0 && t.error(a, `Unmatched ) at column ${d - 1}`), y = g.pop(), E = y.options ? y.options[y.options.length - 1] : y.stack; + break; + case "|": + y.options || (y.options = [y.stack], delete y.stack); + var f = []; + y.options.push(f), E = f; + break; + case "{": + var b = /^(\d+)(,(\d+)?)?\}/.exec(R.slice(d)), A, _; + b !== null ? (E.length === 0 && M(d), A = parseInt(b[1], 10), _ = b[2] ? b[3] ? parseInt(b[3], 10) : 1 / 0 : A, d += b[0].length, E.push({ + type: n.REPETITION, + min: A, + max: _, + value: E.pop() + })) : E.push({ + type: n.CHAR, + value: 123 + }); + break; + case "?": + E.length === 0 && M(d), E.push({ + type: n.REPETITION, + min: 0, + max: 1, + value: E.pop() + }); + break; + case "+": + E.length === 0 && M(d), E.push({ + type: n.REPETITION, + min: 1, + max: 1 / 0, + value: E.pop() + }); + break; + case "*": + E.length === 0 && M(d), E.push({ + type: n.REPETITION, + min: 0, + max: 1 / 0, + value: E.pop() + }); + break; + default: + E.push({ + type: n.CHAR, + value: m.charCodeAt(0) + }); + } + return g.length !== 0 && t.error(a, "Unterminated group"), h; + }, i.exports.types = n; + } +}), Br = De({ + "node_modules/drange/lib/index.js"(r, i) { + var t = class Ke { + constructor(s, a) { + this.low = s, this.high = a, this.length = 1 + a - s; + } + overlaps(s) { + return !(this.high < s.low || this.low > s.high); + } + touches(s) { + return !(this.high + 1 < s.low || this.low - 1 > s.high); + } + // Returns inclusive combination of SubRanges as a SubRange. + add(s) { + return new Ke( + Math.min(this.low, s.low), + Math.max(this.high, s.high) + ); + } + // Returns subtraction of SubRanges as an array of SubRanges. + // (There's a case where subtraction divides it in 2) + subtract(s) { + return s.low <= this.low && s.high >= this.high ? [] : s.low > this.low && s.high < this.high ? [ + new Ke(this.low, s.low - 1), + new Ke(s.high + 1, this.high) + ] : s.low <= this.low ? [new Ke(s.high + 1, this.high)] : [new Ke(this.low, s.low - 1)]; + } + toString() { + return this.low == this.high ? this.low.toString() : this.low + "-" + this.high; + } + }, n = class Xe { + constructor(s, a) { + this.ranges = [], this.length = 0, s != null && this.add(s, a); + } + _update_length() { + this.length = this.ranges.reduce((s, a) => s + a.length, 0); + } + add(s, a) { + var d = (x) => { + for (var m = 0; m < this.ranges.length && !x.touches(this.ranges[m]); ) + m++; + for (var h = this.ranges.slice(0, m); m < this.ranges.length && x.touches(this.ranges[m]); ) + x = x.add(this.ranges[m]), m++; + h.push(x), this.ranges = h.concat(this.ranges.slice(m)), this._update_length(); + }; + return s instanceof Xe ? s.ranges.forEach(d) : (a == null && (a = s), d(new t(s, a))), this; + } + subtract(s, a) { + var d = (x) => { + for (var m = 0; m < this.ranges.length && !x.overlaps(this.ranges[m]); ) + m++; + for (var h = this.ranges.slice(0, m); m < this.ranges.length && x.overlaps(this.ranges[m]); ) + h = h.concat(this.ranges[m].subtract(x)), m++; + this.ranges = h.concat(this.ranges.slice(m)), this._update_length(); + }; + return s instanceof Xe ? s.ranges.forEach(d) : (a == null && (a = s), d(new t(s, a))), this; + } + intersect(s, a) { + var d = [], x = (m) => { + for (var h = 0; h < this.ranges.length && !m.overlaps(this.ranges[h]); ) + h++; + for (; h < this.ranges.length && m.overlaps(this.ranges[h]); ) { + var y = Math.max(this.ranges[h].low, m.low), E = Math.min(this.ranges[h].high, m.high); + d.push(new t(y, E)), h++; + } + }; + return s instanceof Xe ? s.ranges.forEach(x) : (a == null && (a = s), x(new t(s, a))), this.ranges = d, this._update_length(), this; + } + index(s) { + for (var a = 0; a < this.ranges.length && this.ranges[a].length <= s; ) + s -= this.ranges[a].length, a++; + return this.ranges[a].low + s; + } + toString() { + return "[ " + this.ranges.join(", ") + " ]"; + } + clone() { + return new Xe(this); + } + numbers() { + return this.ranges.reduce((s, a) => { + for (var d = a.low; d <= a.high; ) + s.push(d), d++; + return s; + }, []); + } + subranges() { + return this.ranges.map((s) => ({ + low: s.low, + high: s.high, + length: 1 + s.high - s.low + })); + } + }; + i.exports = n; + } +}), Dr = De({ + "node_modules/randexp/lib/randexp.js"(r, i) { + var t = $r(), n = Br(), p = t.types; + i.exports = class Qe { + /** + * @constructor + * @param {RegExp|String} regexp + * @param {String} m + */ + constructor(a, d) { + if (this._setDefaults(a), a instanceof RegExp) + this.ignoreCase = a.ignoreCase, this.multiline = a.multiline, a = a.source; + else if (typeof a == "string") + this.ignoreCase = d && d.indexOf("i") !== -1, this.multiline = d && d.indexOf("m") !== -1; + else + throw new Error("Expected a regexp or string"); + this.tokens = t(a); + } + /** + * Checks if some custom properties have been set for this regexp. + * + * @param {RandExp} randexp + * @param {RegExp} regexp + */ + _setDefaults(a) { + this.max = a.max != null ? a.max : Qe.prototype.max != null ? Qe.prototype.max : 100, this.defaultRange = a.defaultRange ? a.defaultRange : this.defaultRange.clone(), a.randInt && (this.randInt = a.randInt); + } + /** + * Generates the random string. + * + * @return {String} + */ + gen() { + return this._gen(this.tokens, []); + } + /** + * Generate random string modeled after given tokens. + * + * @param {Object} token + * @param {Array.} groups + * @return {String} + */ + _gen(a, d) { + var x, m, h, y, E; + switch (a.type) { + case p.ROOT: + case p.GROUP: + if (a.followedBy || a.notFollowedBy) + return ""; + for (a.remember && a.groupNumber === void 0 && (a.groupNumber = d.push(null) - 1), x = a.options ? this._randSelect(a.options) : a.stack, m = "", y = 0, E = x.length; y < E; y++) + m += this._gen(x[y], d); + return a.remember && (d[a.groupNumber] = m), m; + case p.POSITION: + return ""; + case p.SET: + var g = this._expand(a); + return g.length ? String.fromCharCode(this._randSelect(g)) : ""; + case p.REPETITION: + for (h = this.randInt( + a.min, + a.max === 1 / 0 ? a.min + this.max : a.max + ), m = "", y = 0; y < h; y++) + m += this._gen(a.value, d); + return m; + case p.REFERENCE: + return d[a.value - 1] || ""; + case p.CHAR: + var M = this.ignoreCase && this._randBool() ? this._toOtherCase(a.value) : a.value; + return String.fromCharCode(M); + } + } + /** + * If code is alphabetic, converts to other case. + * If not alphabetic, returns back code. + * + * @param {Number} code + * @return {Number} + */ + _toOtherCase(a) { + return a + (97 <= a && a <= 122 ? -32 : 65 <= a && a <= 90 ? 32 : 0); + } + /** + * Randomly returns a true or false value. + * + * @return {Boolean} + */ + _randBool() { + return !this.randInt(0, 1); + } + /** + * Randomly selects and returns a value from the array. + * + * @param {Array.} arr + * @return {Object} + */ + _randSelect(a) { + return a instanceof n ? a.index(this.randInt(0, a.length - 1)) : a[this.randInt(0, a.length - 1)]; + } + /** + * expands a token to a DiscontinuousRange of characters which has a + * length and an index function (for random selecting) + * + * @param {Object} token + * @return {DiscontinuousRange} + */ + _expand(a) { + if (a.type === t.types.CHAR) + return new n(a.value); + if (a.type === t.types.RANGE) + return new n(a.from, a.to); + { + let d = new n(); + for (let x = 0; x < a.set.length; x++) { + let m = this._expand(a.set[x]); + if (d.add(m), this.ignoreCase) + for (let h = 0; h < m.length; h++) { + let y = m.index(h), E = this._toOtherCase(y); + y !== E && d.add(E); + } + } + return a.not ? this.defaultRange.clone().subtract(d) : this.defaultRange.clone().intersect(d); + } + } + /** + * Randomly generates and returns a number between a and b (inclusive). + * + * @param {Number} a + * @param {Number} b + * @return {Number} + */ + randInt(a, d) { + return a + Math.floor(Math.random() * (1 + d - a)); + } + /** + * Default range of characters to generate from. + */ + get defaultRange() { + return this._range = this._range || new n(32, 126); + } + set defaultRange(a) { + this._range = a; + } + /** + * + * Enables use of randexp with a shorter call. + * + * @param {RegExp|String| regexp} + * @param {String} m + * @return {String} + */ + static randexp(a, d) { + var x; + return typeof a == "string" && (a = new RegExp(a, d)), a._randexp === void 0 ? (x = new Qe(a, d), a._randexp = x) : (x = a._randexp, x._setDefaults(a)), x.gen(); + } + /** + * Enables sugary /regexp/.gen syntax. + */ + static sugar() { + RegExp.prototype.gen = function() { + return Qe.randexp(this); + }; + } + }; + } +}), lt = De({ + "node_modules/yaml/dist/PlainValue-ec8e588e.js"(r) { + var i = { + ANCHOR: "&", + COMMENT: "#", + TAG: "!", + DIRECTIVES_END: "-", + DOCUMENT_END: "." + }, t = { + ALIAS: "ALIAS", + BLANK_LINE: "BLANK_LINE", + BLOCK_FOLDED: "BLOCK_FOLDED", + BLOCK_LITERAL: "BLOCK_LITERAL", + COMMENT: "COMMENT", + DIRECTIVE: "DIRECTIVE", + DOCUMENT: "DOCUMENT", + FLOW_MAP: "FLOW_MAP", + FLOW_SEQ: "FLOW_SEQ", + MAP: "MAP", + MAP_KEY: "MAP_KEY", + MAP_VALUE: "MAP_VALUE", + PLAIN: "PLAIN", + QUOTE_DOUBLE: "QUOTE_DOUBLE", + QUOTE_SINGLE: "QUOTE_SINGLE", + SEQ: "SEQ", + SEQ_ITEM: "SEQ_ITEM" + }, n = "tag:yaml.org,2002:", p = { + MAP: "tag:yaml.org,2002:map", + SEQ: "tag:yaml.org,2002:seq", + STR: "tag:yaml.org,2002:str" + }; + function s(f) { + const b = [0]; + let A = f.indexOf(` +`); + for (; A !== -1; ) + A += 1, b.push(A), A = f.indexOf(` +`, A); + return b; + } + function a(f) { + let b, A; + return typeof f == "string" ? (b = s(f), A = f) : (Array.isArray(f) && (f = f[0]), f && f.context && (f.lineStarts || (f.lineStarts = s(f.context.src)), b = f.lineStarts, A = f.context.src)), { + lineStarts: b, + src: A + }; + } + function d(f, b) { + if (typeof f != "number" || f < 0) + return null; + const { + lineStarts: A, + src: _ + } = a(b); + if (!A || !_ || f > _.length) + return null; + for (let F = 0; F < A.length; ++F) { + const D = A[F]; + if (f < D) + return { + line: F, + col: f - A[F - 1] + 1 + }; + if (f === D) + return { + line: F + 1, + col: 1 + }; + } + const S = A.length; + return { + line: S, + col: f - A[S - 1] + 1 + }; + } + function x(f, b) { + const { + lineStarts: A, + src: _ + } = a(b); + if (!A || !(f >= 1) || f > A.length) + return null; + const S = A[f - 1]; + let F = A[f]; + for (; F && F > S && _[F - 1] === ` +`; ) + --F; + return _.slice(S, F); + } + function m({ + start: f, + end: b + }, A, _ = 80) { + let S = x(f.line, A); + if (!S) + return null; + let { + col: F + } = f; + if (S.length > _) + if (F <= _ - 10) + S = S.substr(0, _ - 1) + "…"; + else { + const T = Math.round(_ / 2); + S.length > F + T && (S = S.substr(0, F + T - 1) + "…"), F -= S.length - _, S = "…" + S.substr(1 - _); + } + let D = 1, H = ""; + b && (b.line === f.line && F + (b.col - f.col) <= _ + 1 ? D = b.col - f.col : (D = Math.min(S.length + 1, _) - F, H = "…")); + const j = F > 1 ? " ".repeat(F - 1) : "", Q = "^".repeat(D); + return `${S} +${j}${Q}${H}`; + } + var h = class Bt { + static copy(b) { + return new Bt(b.start, b.end); + } + constructor(b, A) { + this.start = b, this.end = A || b; + } + isEmpty() { + return typeof this.start != "number" || !this.end || this.end <= this.start; + } + /** + * Set `origStart` and `origEnd` to point to the original source range for + * this node, which may differ due to dropped CR characters. + * + * @param {number[]} cr - Positions of dropped CR characters + * @param {number} offset - Starting index of `cr` from the last call + * @returns {number} - The next offset, matching the one found for `origStart` + */ + setOrigRange(b, A) { + const { + start: _, + end: S + } = this; + if (b.length === 0 || S <= b[0]) + return this.origStart = _, this.origEnd = S, A; + let F = A; + for (; F < b.length && !(b[F] > _); ) + ++F; + this.origStart = _ + F; + const D = F; + for (; F < b.length && !(b[F] >= S); ) + ++F; + return this.origEnd = S + F, D; + } + }, y = class Ue { + static addStringTerminator(b, A, _) { + if (_[_.length - 1] === ` +`) + return _; + const S = Ue.endOfWhiteSpace(b, A); + return S >= b.length || b[S] === ` +` ? _ + ` +` : _; + } + // ^(---|...) + static atDocumentBoundary(b, A, _) { + const S = b[A]; + if (!S) + return !0; + const F = b[A - 1]; + if (F && F !== ` +`) + return !1; + if (_) { + if (S !== _) + return !1; + } else if (S !== i.DIRECTIVES_END && S !== i.DOCUMENT_END) + return !1; + const D = b[A + 1], H = b[A + 2]; + if (D !== S || H !== S) + return !1; + const j = b[A + 3]; + return !j || j === ` +` || j === " " || j === " "; + } + static endOfIdentifier(b, A) { + let _ = b[A]; + const S = _ === "<", F = S ? [` +`, " ", " ", ">"] : [` +`, " ", " ", "[", "]", "{", "}", ","]; + for (; _ && F.indexOf(_) === -1; ) + _ = b[A += 1]; + return S && _ === ">" && (A += 1), A; + } + static endOfIndent(b, A) { + let _ = b[A]; + for (; _ === " "; ) + _ = b[A += 1]; + return A; + } + static endOfLine(b, A) { + let _ = b[A]; + for (; _ && _ !== ` +`; ) + _ = b[A += 1]; + return A; + } + static endOfWhiteSpace(b, A) { + let _ = b[A]; + for (; _ === " " || _ === " "; ) + _ = b[A += 1]; + return A; + } + static startOfLine(b, A) { + let _ = b[A - 1]; + if (_ === ` +`) + return A; + for (; _ && _ !== ` +`; ) + _ = b[A -= 1]; + return A + 1; + } + /** + * End of indentation, or null if the line's indent level is not more + * than `indent` + * + * @param {string} src + * @param {number} indent + * @param {number} lineStart + * @returns {?number} + */ + static endOfBlockIndent(b, A, _) { + const S = Ue.endOfIndent(b, _); + if (S > _ + A) + return S; + { + const F = Ue.endOfWhiteSpace(b, S), D = b[F]; + if (!D || D === ` +`) + return F; + } + return null; + } + static atBlank(b, A, _) { + const S = b[A]; + return S === ` +` || S === " " || S === " " || _ && !S; + } + static nextNodeIsIndented(b, A, _) { + return !b || A < 0 ? !1 : A > 0 ? !0 : _ && b === "-"; + } + // should be at line or string end, or at next non-whitespace char + static normalizeOffset(b, A) { + const _ = b[A]; + return _ ? _ !== ` +` && b[A - 1] === ` +` ? A - 1 : Ue.endOfWhiteSpace(b, A) : A; + } + // fold single newline into space, multiple newlines to N - 1 newlines + // presumes src[offset] === '\n' + static foldNewline(b, A, _) { + let S = 0, F = !1, D = "", H = b[A + 1]; + for (; H === " " || H === " " || H === ` +`; ) { + switch (H) { + case ` +`: + S = 0, A += 1, D += ` +`; + break; + case " ": + S <= _ && (F = !0), A = Ue.endOfWhiteSpace(b, A + 2) - 1; + break; + case " ": + S += 1, A += 1; + break; + } + H = b[A + 1]; + } + return D || (D = " "), H && S <= _ && (F = !0), { + fold: D, + offset: A, + error: F + }; + } + constructor(b, A, _) { + Object.defineProperty(this, "context", { + value: _ || null, + writable: !0 + }), this.error = null, this.range = null, this.valueRange = null, this.props = A || [], this.type = b, this.value = null; + } + getPropValue(b, A, _) { + if (!this.context) + return null; + const { + src: S + } = this.context, F = this.props[b]; + return F && S[F.start] === A ? S.slice(F.start + (_ ? 1 : 0), F.end) : null; + } + get anchor() { + for (let b = 0; b < this.props.length; ++b) { + const A = this.getPropValue(b, i.ANCHOR, !0); + if (A != null) + return A; + } + return null; + } + get comment() { + const b = []; + for (let A = 0; A < this.props.length; ++A) { + const _ = this.getPropValue(A, i.COMMENT, !0); + _ != null && b.push(_); + } + return b.length > 0 ? b.join(` +`) : null; + } + commentHasRequiredWhitespace(b) { + const { + src: A + } = this.context; + if (this.header && b === this.header.end || !this.valueRange) + return !1; + const { + end: _ + } = this.valueRange; + return b !== _ || Ue.atBlank(A, _ - 1); + } + get hasComment() { + if (this.context) { + const { + src: b + } = this.context; + for (let A = 0; A < this.props.length; ++A) + if (b[this.props[A].start] === i.COMMENT) + return !0; + } + return !1; + } + get hasProps() { + if (this.context) { + const { + src: b + } = this.context; + for (let A = 0; A < this.props.length; ++A) + if (b[this.props[A].start] !== i.COMMENT) + return !0; + } + return !1; + } + get includesTrailingLines() { + return !1; + } + get jsonLike() { + return [t.FLOW_MAP, t.FLOW_SEQ, t.QUOTE_DOUBLE, t.QUOTE_SINGLE].indexOf(this.type) !== -1; + } + get rangeAsLinePos() { + if (!this.range || !this.context) + return; + const b = d(this.range.start, this.context.root); + if (!b) + return; + const A = d(this.range.end, this.context.root); + return { + start: b, + end: A + }; + } + get rawValue() { + if (!this.valueRange || !this.context) + return null; + const { + start: b, + end: A + } = this.valueRange; + return this.context.src.slice(b, A); + } + get tag() { + for (let b = 0; b < this.props.length; ++b) { + const A = this.getPropValue(b, i.TAG, !1); + if (A != null) { + if (A[1] === "<") + return { + verbatim: A.slice(2, -1) + }; + { + const [_, S, F] = A.match(/^(.*!)([^!]*)$/); + return { + handle: S, + suffix: F + }; + } + } + } + return null; + } + get valueRangeContainsNewline() { + if (!this.valueRange || !this.context) + return !1; + const { + start: b, + end: A + } = this.valueRange, { + src: _ + } = this.context; + for (let S = b; S < A; ++S) + if (_[S] === ` +`) + return !0; + return !1; + } + parseComment(b) { + const { + src: A + } = this.context; + if (A[b] === i.COMMENT) { + const _ = Ue.endOfLine(A, b + 1), S = new h(b, _); + return this.props.push(S), _; + } + return b; + } + /** + * Populates the `origStart` and `origEnd` values of all ranges for this + * node. Extended by child classes to handle descendant nodes. + * + * @param {number[]} cr - Positions of dropped CR characters + * @param {number} offset - Starting index of `cr` from the last call + * @returns {number} - The next offset, matching the one found for `origStart` + */ + setOrigRanges(b, A) { + return this.range && (A = this.range.setOrigRange(b, A)), this.valueRange && this.valueRange.setOrigRange(b, A), this.props.forEach((_) => _.setOrigRange(b, A)), A; + } + toString() { + const { + context: { + src: b + }, + range: A, + value: _ + } = this; + if (_ != null) + return _; + const S = b.slice(A.start, A.end); + return Ue.addStringTerminator(b, A.end, S); + } + }, E = class extends Error { + constructor(f, b, A) { + if (!A || !(b instanceof y)) + throw new Error(`Invalid arguments for new ${f}`); + super(), this.name = f, this.message = A, this.source = b; + } + makePretty() { + if (!this.source) + return; + this.nodeType = this.source.type; + const f = this.source.context && this.source.context.root; + if (typeof this.offset == "number") { + this.range = new h(this.offset, this.offset + 1); + const b = f && d(this.offset, f); + if (b) { + const A = { + line: b.line, + col: b.col + 1 + }; + this.linePos = { + start: b, + end: A + }; + } + delete this.offset; + } else + this.range = this.source.range, this.linePos = this.source.rangeAsLinePos; + if (this.linePos) { + const { + line: b, + col: A + } = this.linePos.start; + this.message += ` at line ${b}, column ${A}`; + const _ = f && m(this.linePos, f); + _ && (this.message += `: + +${_} +`); + } + delete this.source; + } + }, g = class extends E { + constructor(f, b) { + super("YAMLReferenceError", f, b); + } + }, M = class extends E { + constructor(f, b) { + super("YAMLSemanticError", f, b); + } + }, R = class extends E { + constructor(f, b) { + super("YAMLSyntaxError", f, b); + } + }, l = class extends E { + constructor(f, b) { + super("YAMLWarning", f, b); + } + }; + function o(f, b, A) { + return b in f ? Object.defineProperty(f, b, { + value: A, + enumerable: !0, + configurable: !0, + writable: !0 + }) : f[b] = A, f; + } + var c = class dt extends y { + static endOfLine(b, A, _) { + let S = b[A], F = A; + for (; S && S !== ` +` && !(_ && (S === "[" || S === "]" || S === "{" || S === "}" || S === ",")); ) { + const D = b[F + 1]; + if (S === ":" && (!D || D === ` +` || D === " " || D === " " || _ && D === ",") || (S === " " || S === " ") && D === "#") + break; + F += 1, S = D; + } + return F; + } + get strValue() { + if (!this.valueRange || !this.context) + return null; + let { + start: b, + end: A + } = this.valueRange; + const { + src: _ + } = this.context; + let S = _[A - 1]; + for (; b < A && (S === ` +` || S === " " || S === " "); ) + S = _[--A - 1]; + let F = ""; + for (let H = b; H < A; ++H) { + const j = _[H]; + if (j === ` +`) { + const { + fold: Q, + offset: T + } = y.foldNewline(_, H, -1); + F += Q, H = T; + } else if (j === " " || j === " ") { + const Q = H; + let T = _[H + 1]; + for (; H < A && (T === " " || T === " "); ) + H += 1, T = _[H + 1]; + T !== ` +` && (F += H > Q ? _.slice(Q, H + 1) : j); + } else + F += j; + } + const D = _[b]; + switch (D) { + case " ": { + const H = "Plain value cannot start with a tab character"; + return { + errors: [new M(this, H)], + str: F + }; + } + case "@": + case "`": { + const H = `Plain value cannot start with reserved character ${D}`; + return { + errors: [new M(this, H)], + str: F + }; + } + default: + return F; + } + } + parseBlockValue(b) { + const { + indent: A, + inFlow: _, + src: S + } = this.context; + let F = b, D = b; + for (let H = S[F]; H === ` +` && !y.atDocumentBoundary(S, F + 1); H = S[F]) { + const j = y.endOfBlockIndent(S, A, F + 1); + if (j === null || S[j] === "#") + break; + S[j] === ` +` ? F = j : (D = dt.endOfLine(S, j, _), F = D); + } + return this.valueRange.isEmpty() && (this.valueRange.start = b), this.valueRange.end = D, D; + } + /** + * Parses a plain value from the source + * + * Accepted forms are: + * ``` + * #comment + * + * first line + * + * first line #comment + * + * first line + * block + * lines + * + * #comment + * block + * lines + * ``` + * where block lines are empty or have an indent level greater than `indent`. + * + * @param {ParseContext} context + * @param {number} start - Index of first character + * @returns {number} - Index of the character after this scalar, may be `\n` + */ + parse(b, A) { + this.context = b; + const { + inFlow: _, + src: S + } = b; + let F = A; + const D = S[F]; + return D && D !== "#" && D !== ` +` && (F = dt.endOfLine(S, A, _)), this.valueRange = new h(A, F), F = y.endOfWhiteSpace(S, F), F = this.parseComment(F), (!this.hasComment || this.valueRange.isEmpty()) && (F = this.parseBlockValue(F)), F; + } + }; + r.Char = i, r.Node = y, r.PlainValue = c, r.Range = h, r.Type = t, r.YAMLError = E, r.YAMLReferenceError = g, r.YAMLSemanticError = M, r.YAMLSyntaxError = R, r.YAMLWarning = l, r._defineProperty = o, r.defaultTagPrefix = n, r.defaultTags = p; + } +}), At = De({ + "node_modules/yaml/dist/resolveSeq-d03cb037.js"(r) { + var i = lt(); + function t(L, C, e) { + return e ? `#${e.replace(/[\s\S]^/gm, `$&${C}#`)} +${C}${L}` : L; + } + function n(L, C, e) { + return e ? e.indexOf(` +`) === -1 ? `${L} #${e}` : `${L} +` + e.replace(/^/gm, `${C || ""}#`) : L; + } + var p = class { + }; + function s(L, C, e) { + if (Array.isArray(L)) + return L.map((O, I) => s(O, String(I), e)); + if (L && typeof L.toJSON == "function") { + const O = e && e.anchors && e.anchors.get(L); + O && (e.onCreate = ($) => { + O.res = $, delete e.onCreate; + }); + const I = L.toJSON(C, e); + return O && e.onCreate && e.onCreate(I), I; + } + return (!e || !e.keep) && typeof L == "bigint" ? Number(L) : L; + } + var a = class extends p { + constructor(L) { + super(), this.value = L; + } + toJSON(L, C) { + return C && C.keep ? this.value : s(this.value, L, C); + } + toString() { + return String(this.value); + } + }; + function d(L, C, e) { + let O = e; + for (let I = C.length - 1; I >= 0; --I) { + const $ = C[I]; + if (Number.isInteger($) && $ >= 0) { + const v = []; + v[$] = O, O = v; + } else { + const v = {}; + Object.defineProperty(v, $, { + value: O, + writable: !0, + enumerable: !0, + configurable: !0 + }), O = v; + } + } + return L.createNode(O, !1); + } + var x = (L) => L == null || typeof L == "object" && L[Symbol.iterator]().next().done, m = class Ve extends p { + constructor(C) { + super(), i._defineProperty(this, "items", []), this.schema = C; + } + addIn(C, e) { + if (x(C)) + this.add(e); + else { + const [O, ...I] = C, $ = this.get(O, !0); + if ($ instanceof Ve) + $.addIn(I, e); + else if ($ === void 0 && this.schema) + this.set(O, d(this.schema, I, e)); + else + throw new Error(`Expected YAML collection at ${O}. Remaining path: ${I}`); + } + } + deleteIn([C, ...e]) { + if (e.length === 0) + return this.delete(C); + const O = this.get(C, !0); + if (O instanceof Ve) + return O.deleteIn(e); + throw new Error(`Expected YAML collection at ${C}. Remaining path: ${e}`); + } + getIn([C, ...e], O) { + const I = this.get(C, !0); + return e.length === 0 ? !O && I instanceof a ? I.value : I : I instanceof Ve ? I.getIn(e, O) : void 0; + } + hasAllNullValues() { + return this.items.every((C) => { + if (!C || C.type !== "PAIR") + return !1; + const e = C.value; + return e == null || e instanceof a && e.value == null && !e.commentBefore && !e.comment && !e.tag; + }); + } + hasIn([C, ...e]) { + if (e.length === 0) + return this.has(C); + const O = this.get(C, !0); + return O instanceof Ve ? O.hasIn(e) : !1; + } + setIn([C, ...e], O) { + if (e.length === 0) + this.set(C, O); + else { + const I = this.get(C, !0); + if (I instanceof Ve) + I.setIn(e, O); + else if (I === void 0 && this.schema) + this.set(C, d(this.schema, e, O)); + else + throw new Error(`Expected YAML collection at ${C}. Remaining path: ${e}`); + } + } + // overridden in implementations + /* istanbul ignore next */ + toJSON() { + return null; + } + toString(C, { + blockItem: e, + flowChars: O, + isMap: I, + itemIndent: $ + }, v, N) { + const { + indent: W, + indentStep: V, + stringify: J + } = C, Z = this.type === i.Type.FLOW_MAP || this.type === i.Type.FLOW_SEQ || C.inFlow; + Z && ($ += V); + const ie = I && this.hasAllNullValues(); + C = Object.assign({}, C, { + allNullValues: ie, + indent: $, + inFlow: Z, + type: null + }); + let oe = !1, ge = !1; + const ye = this.items.reduce((Ae, Oe, Pe) => { + let Re; + Oe && (!oe && Oe.spaceBefore && Ae.push({ + type: "comment", + str: "" + }), Oe.commentBefore && Oe.commentBefore.match(/^.*$/gm).forEach((gr) => { + Ae.push({ + type: "comment", + str: `#${gr}` + }); + }), Oe.comment && (Re = Oe.comment), Z && (!oe && Oe.spaceBefore || Oe.commentBefore || Oe.comment || Oe.key && (Oe.key.commentBefore || Oe.key.comment) || Oe.value && (Oe.value.commentBefore || Oe.value.comment)) && (ge = !0)), oe = !1; + let $e = J(Oe, C, () => Re = null, () => oe = !0); + return Z && !ge && $e.includes(` +`) && (ge = !0), Z && Pe < this.items.length - 1 && ($e += ","), $e = n($e, $, Re), oe && (Re || Z) && (oe = !1), Ae.push({ + type: "item", + str: $e + }), Ae; + }, []); + let be; + if (ye.length === 0) + be = O.start + O.end; + else if (Z) { + const { + start: Ae, + end: Oe + } = O, Pe = ye.map((Re) => Re.str); + if (ge || Pe.reduce((Re, $e) => Re + $e.length + 2, 2) > Ve.maxFlowStringSingleLineLength) { + be = Ae; + for (const Re of Pe) + be += Re ? ` +${V}${W}${Re}` : ` +`; + be += ` +${W}${Oe}`; + } else + be = `${Ae} ${Pe.join(" ")} ${Oe}`; + } else { + const Ae = ye.map(e); + be = Ae.shift(); + for (const Oe of Ae) + be += Oe ? ` +${W}${Oe}` : ` +`; + } + return this.comment ? (be += ` +` + this.comment.replace(/^/gm, `${W}#`), v && v()) : oe && N && N(), be; + } + }; + i._defineProperty(m, "maxFlowStringSingleLineLength", 60); + function h(L) { + let C = L instanceof a ? L.value : L; + return C && typeof C == "string" && (C = Number(C)), Number.isInteger(C) && C >= 0 ? C : null; + } + var y = class extends m { + add(L) { + this.items.push(L); + } + delete(L) { + const C = h(L); + return typeof C != "number" ? !1 : this.items.splice(C, 1).length > 0; + } + get(L, C) { + const e = h(L); + if (typeof e != "number") + return; + const O = this.items[e]; + return !C && O instanceof a ? O.value : O; + } + has(L) { + const C = h(L); + return typeof C == "number" && C < this.items.length; + } + set(L, C) { + const e = h(L); + if (typeof e != "number") + throw new Error(`Expected a valid index, not ${L}.`); + this.items[e] = C; + } + toJSON(L, C) { + const e = []; + C && C.onCreate && C.onCreate(e); + let O = 0; + for (const I of this.items) + e.push(s(I, String(O++), C)); + return e; + } + toString(L, C, e) { + return L ? super.toString(L, { + blockItem: (O) => O.type === "comment" ? O.str : `- ${O.str}`, + flowChars: { + start: "[", + end: "]" + }, + isMap: !1, + itemIndent: (L.indent || "") + " " + }, C, e) : JSON.stringify(this); + } + }, E = (L, C, e) => C === null ? "" : typeof C != "object" ? String(C) : L instanceof p && e && e.doc ? L.toString({ + anchors: /* @__PURE__ */ Object.create(null), + doc: e.doc, + indent: "", + indentStep: e.indentStep, + inFlow: !0, + inStringifyKey: !0, + stringify: e.stringify + }) : JSON.stringify(C), g = class Dt extends p { + constructor(C, e = null) { + super(), this.key = C, this.value = e, this.type = Dt.Type.PAIR; + } + get commentBefore() { + return this.key instanceof p ? this.key.commentBefore : void 0; + } + set commentBefore(C) { + if (this.key == null && (this.key = new a(null)), this.key instanceof p) + this.key.commentBefore = C; + else { + const e = "Pair.commentBefore is an alias for Pair.key.commentBefore. To set it, the key must be a Node."; + throw new Error(e); + } + } + addToJSMap(C, e) { + const O = s(this.key, "", C); + if (e instanceof Map) { + const I = s(this.value, O, C); + e.set(O, I); + } else if (e instanceof Set) + e.add(O); + else { + const I = E(this.key, O, C), $ = s(this.value, I, C); + I in e ? Object.defineProperty(e, I, { + value: $, + writable: !0, + enumerable: !0, + configurable: !0 + }) : e[I] = $; + } + return e; + } + toJSON(C, e) { + const O = e && e.mapAsMap ? /* @__PURE__ */ new Map() : {}; + return this.addToJSMap(e, O); + } + toString(C, e, O) { + if (!C || !C.doc) + return JSON.stringify(this); + const { + indent: I, + indentSeq: $, + simpleKeys: v + } = C.doc.options; + let { + key: N, + value: W + } = this, V = N instanceof p && N.comment; + if (v) { + if (V) + throw new Error("With simple keys, key nodes cannot have comments"); + if (N instanceof m) { + const $e = "With simple keys, collection cannot be used as a key value"; + throw new Error($e); + } + } + let J = !v && (!N || V || (N instanceof p ? N instanceof m || N.type === i.Type.BLOCK_FOLDED || N.type === i.Type.BLOCK_LITERAL : typeof N == "object")); + const { + doc: Z, + indent: ie, + indentStep: oe, + stringify: ge + } = C; + C = Object.assign({}, C, { + implicitKey: !J, + indent: ie + oe + }); + let ye = !1, be = ge(N, C, () => V = null, () => ye = !0); + if (be = n(be, C.indent, V), !J && be.length > 1024) { + if (v) + throw new Error("With simple keys, single line scalar must not span more than 1024 characters"); + J = !0; + } + if (C.allNullValues && !v) + return this.comment ? (be = n(be, C.indent, this.comment), e && e()) : ye && !V && O && O(), C.inFlow && !J ? be : `? ${be}`; + be = J ? `? ${be} +${ie}:` : `${be}:`, this.comment && (be = n(be, C.indent, this.comment), e && e()); + let Ae = "", Oe = null; + if (W instanceof p) { + if (W.spaceBefore && (Ae = ` +`), W.commentBefore) { + const $e = W.commentBefore.replace(/^/gm, `${C.indent}#`); + Ae += ` +${$e}`; + } + Oe = W.comment; + } else W && typeof W == "object" && (W = Z.schema.createNode(W, !0)); + C.implicitKey = !1, !J && !this.comment && W instanceof a && (C.indentAtStart = be.length + 1), ye = !1, !$ && I >= 2 && !C.inFlow && !J && W instanceof y && W.type !== i.Type.FLOW_SEQ && !W.tag && !Z.anchors.getName(W) && (C.indent = C.indent.substr(2)); + const Pe = ge(W, C, () => Oe = null, () => ye = !0); + let Re = " "; + return Ae || this.comment ? Re = `${Ae} +${C.indent}` : !J && W instanceof m ? (!(Pe[0] === "[" || Pe[0] === "{") || Pe.includes(` +`)) && (Re = ` +${C.indent}`) : Pe[0] === ` +` && (Re = ""), ye && !Oe && O && O(), n(be + Re + Pe, C.indent, Oe); + } + }; + i._defineProperty(g, "Type", { + PAIR: "PAIR", + MERGE_PAIR: "MERGE_PAIR" + }); + var M = (L, C) => { + if (L instanceof R) { + const e = C.get(L.source); + return e.count * e.aliasCount; + } else if (L instanceof m) { + let e = 0; + for (const O of L.items) { + const I = M(O, C); + I > e && (e = I); + } + return e; + } else if (L instanceof g) { + const e = M(L.key, C), O = M(L.value, C); + return Math.max(e, O); + } + return 1; + }, R = class Ft extends p { + static stringify({ + range: C, + source: e + }, { + anchors: O, + doc: I, + implicitKey: $, + inStringifyKey: v + }) { + let N = Object.keys(O).find((V) => O[V] === e); + if (!N && v && (N = I.anchors.getName(e) || I.anchors.newName()), N) + return `*${N}${$ ? " " : ""}`; + const W = I.anchors.getName(e) ? "Alias node must be after source node" : "Source node not found for alias node"; + throw new Error(`${W} [${C}]`); + } + constructor(C) { + super(), this.source = C, this.type = i.Type.ALIAS; + } + set tag(C) { + throw new Error("Alias nodes cannot have tags"); + } + toJSON(C, e) { + if (!e) + return s(this.source, C, e); + const { + anchors: O, + maxAliasCount: I + } = e, $ = O.get(this.source); + if (!$ || $.res === void 0) { + const v = "This should not happen: Alias anchor was not resolved?"; + throw this.cstNode ? new i.YAMLReferenceError(this.cstNode, v) : new ReferenceError(v); + } + if (I >= 0 && ($.count += 1, $.aliasCount === 0 && ($.aliasCount = M(this.source, O)), $.count * $.aliasCount > I)) { + const v = "Excessive alias count indicates a resource exhaustion attack"; + throw this.cstNode ? new i.YAMLReferenceError(this.cstNode, v) : new ReferenceError(v); + } + return $.res; + } + // Only called when stringifying an alias mapping key while constructing + // Object output. + toString(C) { + return Ft.stringify(this, C); + } + }; + i._defineProperty(R, "default", !0); + function l(L, C) { + const e = C instanceof a ? C.value : C; + for (const O of L) + if (O instanceof g && (O.key === C || O.key === e || O.key && O.key.value === e)) + return O; + } + var o = class extends m { + add(L, C) { + L ? L instanceof g || (L = new g(L.key || L, L.value)) : L = new g(L); + const e = l(this.items, L.key), O = this.schema && this.schema.sortMapEntries; + if (e) + if (C) + e.value = L.value; + else + throw new Error(`Key ${L.key} already set`); + else if (O) { + const I = this.items.findIndex(($) => O(L, $) < 0); + I === -1 ? this.items.push(L) : this.items.splice(I, 0, L); + } else + this.items.push(L); + } + delete(L) { + const C = l(this.items, L); + return C ? this.items.splice(this.items.indexOf(C), 1).length > 0 : !1; + } + get(L, C) { + const e = l(this.items, L), O = e && e.value; + return !C && O instanceof a ? O.value : O; + } + has(L) { + return !!l(this.items, L); + } + set(L, C) { + this.add(new g(L, C), !0); + } + /** + * @param {*} arg ignored + * @param {*} ctx Conversion context, originally set in Document#toJSON() + * @param {Class} Type If set, forces the returned collection type + * @returns {*} Instance of Type, Map, or Object + */ + toJSON(L, C, e) { + const O = e ? new e() : C && C.mapAsMap ? /* @__PURE__ */ new Map() : {}; + C && C.onCreate && C.onCreate(O); + for (const I of this.items) + I.addToJSMap(C, O); + return O; + } + toString(L, C, e) { + if (!L) + return JSON.stringify(this); + for (const O of this.items) + if (!(O instanceof g)) + throw new Error(`Map items must all be pairs; found ${JSON.stringify(O)} instead`); + return super.toString(L, { + blockItem: (O) => O.str, + flowChars: { + start: "{", + end: "}" + }, + isMap: !0, + itemIndent: L.indent || "" + }, C, e); + } + }, c = "<<", f = class extends g { + constructor(L) { + if (L instanceof g) { + let C = L.value; + C instanceof y || (C = new y(), C.items.push(L.value), C.range = L.value.range), super(L.key, C), this.range = L.range; + } else + super(new a(c), new y()); + this.type = g.Type.MERGE_PAIR; + } + // If the value associated with a merge key is a single mapping node, each of + // its key/value pairs is inserted into the current mapping, unless the key + // already exists in it. If the value associated with the merge key is a + // sequence, then this sequence is expected to contain mapping nodes and each + // of these nodes is merged in turn according to its order in the sequence. + // Keys in mapping nodes earlier in the sequence override keys specified in + // later mapping nodes. -- http://yaml.org/type/merge.html + addToJSMap(L, C) { + for (const { + source: e + } of this.value.items) { + if (!(e instanceof o)) + throw new Error("Merge sources must be maps"); + const O = e.toJSON(null, L, Map); + for (const [I, $] of O) + C instanceof Map ? C.has(I) || C.set(I, $) : C instanceof Set ? C.add(I) : Object.prototype.hasOwnProperty.call(C, I) || Object.defineProperty(C, I, { + value: $, + writable: !0, + enumerable: !0, + configurable: !0 + }); + } + return C; + } + toString(L, C) { + const e = this.value; + if (e.items.length > 1) + return super.toString(L, C); + this.value = e.items[0]; + const O = super.toString(L, C); + return this.value = e, O; + } + }, b = { + defaultType: i.Type.BLOCK_LITERAL, + lineWidth: 76 + }, A = { + trueStr: "true", + falseStr: "false" + }, _ = { + asBigInt: !1 + }, S = { + nullStr: "null" + }, F = { + defaultType: i.Type.PLAIN, + doubleQuoted: { + jsonEncoding: !1, + minMultiLineLength: 40 + }, + fold: { + lineWidth: 80, + minContentWidth: 20 + } + }; + function D(L, C, e) { + for (const { + format: O, + test: I, + resolve: $ + } of C) + if (I) { + const v = L.match(I); + if (v) { + let N = $.apply(null, v); + return N instanceof a || (N = new a(N)), O && (N.format = O), N; + } + } + return e && (L = e(L)), new a(L); + } + var H = "flow", j = "block", Q = "quoted", T = (L, C) => { + let e = L[C + 1]; + for (; e === " " || e === " "; ) { + do + e = L[C += 1]; + while (e && e !== ` +`); + e = L[C + 1]; + } + return C; + }; + function G(L, C, e, { + indentAtStart: O, + lineWidth: I = 80, + minContentWidth: $ = 20, + onFold: v, + onOverflow: N + }) { + if (!I || I < 0) + return L; + const W = Math.max(1 + $, 1 + I - C.length); + if (L.length <= W) + return L; + const V = [], J = {}; + let Z = I - C.length; + typeof O == "number" && (O > I - Math.max(2, $) ? V.push(0) : Z = I - O); + let ie, oe, ge = !1, ye = -1, be = -1, Ae = -1; + e === j && (ye = T(L, ye), ye !== -1 && (Z = ye + W)); + for (let Pe; Pe = L[ye += 1]; ) { + if (e === Q && Pe === "\\") { + switch (be = ye, L[ye + 1]) { + case "x": + ye += 3; + break; + case "u": + ye += 5; + break; + case "U": + ye += 9; + break; + default: + ye += 1; + } + Ae = ye; + } + if (Pe === ` +`) + e === j && (ye = T(L, ye)), Z = ye + W, ie = void 0; + else { + if (Pe === " " && oe && oe !== " " && oe !== ` +` && oe !== " ") { + const Re = L[ye + 1]; + Re && Re !== " " && Re !== ` +` && Re !== " " && (ie = ye); + } + if (ye >= Z) + if (ie) + V.push(ie), Z = ie + W, ie = void 0; + else if (e === Q) { + for (; oe === " " || oe === " "; ) + oe = Pe, Pe = L[ye += 1], ge = !0; + const Re = ye > Ae + 1 ? ye - 2 : be - 1; + if (J[Re]) + return L; + V.push(Re), J[Re] = !0, Z = Re + W, ie = void 0; + } else + ge = !0; + } + oe = Pe; + } + if (ge && N && N(), V.length === 0) + return L; + v && v(); + let Oe = L.slice(0, V[0]); + for (let Pe = 0; Pe < V.length; ++Pe) { + const Re = V[Pe], $e = V[Pe + 1] || L.length; + Re === 0 ? Oe = ` +${C}${L.slice(0, $e)}` : (e === Q && J[Re] && (Oe += `${L[Re]}\\`), Oe += ` +${C}${L.slice(Re + 1, $e)}`); + } + return Oe; + } + var X = ({ + indentAtStart: L + }) => L ? Object.assign({ + indentAtStart: L + }, F.fold) : F.fold, fe = (L) => /^(%|---|\.\.\.)/m.test(L); + function te(L, C, e) { + if (!C || C < 0) + return !1; + const O = C - e, I = L.length; + if (I <= O) + return !1; + for (let $ = 0, v = 0; $ < I; ++$) + if (L[$] === ` +`) { + if ($ - v > O) + return !0; + if (v = $ + 1, I - v <= O) + return !1; + } + return !0; + } + function me(L, C) { + const { + implicitKey: e + } = C, { + jsonEncoding: O, + minMultiLineLength: I + } = F.doubleQuoted, $ = JSON.stringify(L); + if (O) + return $; + const v = C.indent || (fe(L) ? " " : ""); + let N = "", W = 0; + for (let V = 0, J = $[V]; J; J = $[++V]) + if (J === " " && $[V + 1] === "\\" && $[V + 2] === "n" && (N += $.slice(W, V) + "\\ ", V += 1, W = V, J = "\\"), J === "\\") + switch ($[V + 1]) { + case "u": + { + N += $.slice(W, V); + const Z = $.substr(V + 2, 4); + switch (Z) { + case "0000": + N += "\\0"; + break; + case "0007": + N += "\\a"; + break; + case "000b": + N += "\\v"; + break; + case "001b": + N += "\\e"; + break; + case "0085": + N += "\\N"; + break; + case "00a0": + N += "\\_"; + break; + case "2028": + N += "\\L"; + break; + case "2029": + N += "\\P"; + break; + default: + Z.substr(0, 2) === "00" ? N += "\\x" + Z.substr(2) : N += $.substr(V, 6); + } + V += 5, W = V + 1; + } + break; + case "n": + if (e || $[V + 2] === '"' || $.length < I) + V += 1; + else { + for (N += $.slice(W, V) + ` + +`; $[V + 2] === "\\" && $[V + 3] === "n" && $[V + 4] !== '"'; ) + N += ` +`, V += 2; + N += v, $[V + 2] === " " && (N += "\\"), V += 1, W = V + 1; + } + break; + default: + V += 1; + } + return N = W ? N + $.slice(W) : $, e ? N : G(N, v, Q, X(C)); + } + function ee(L, C) { + if (C.implicitKey) { + if (/\n/.test(L)) + return me(L, C); + } else if (/[ \t]\n|\n[ \t]/.test(L)) + return me(L, C); + const e = C.indent || (fe(L) ? " " : ""), O = "'" + L.replace(/'/g, "''").replace(/\n+/g, `$& +${e}`) + "'"; + return C.implicitKey ? O : G(O, e, H, X(C)); + } + function de({ + comment: L, + type: C, + value: e + }, O, I, $) { + if (/\n[\t ]+$/.test(e) || /^\s*$/.test(e)) + return me(e, O); + const v = O.indent || (O.forceBlockIndent || fe(e) ? " " : ""), N = v ? "2" : "1", W = C === i.Type.BLOCK_FOLDED ? !1 : C === i.Type.BLOCK_LITERAL ? !0 : !te(e, F.fold.lineWidth, v.length); + let V = W ? "|" : ">"; + if (!e) + return V + ` +`; + let J = "", Z = ""; + if (e = e.replace(/[\n\t ]*$/, (oe) => { + const ge = oe.indexOf(` +`); + return ge === -1 ? V += "-" : (e === oe || ge !== oe.length - 1) && (V += "+", $ && $()), Z = oe.replace(/\n$/, ""), ""; + }).replace(/^[\n ]*/, (oe) => { + oe.indexOf(" ") !== -1 && (V += N); + const ge = oe.match(/ +$/); + return ge ? (J = oe.slice(0, -ge[0].length), ge[0]) : (J = oe, ""); + }), Z && (Z = Z.replace(/\n+(?!\n|$)/g, `$&${v}`)), J && (J = J.replace(/\n+/g, `$&${v}`)), L && (V += " #" + L.replace(/ ?[\r\n]+/g, " "), I && I()), !e) + return `${V}${N} +${v}${Z}`; + if (W) + return e = e.replace(/\n+/g, `$&${v}`), `${V} +${v}${J}${e}${Z}`; + e = e.replace(/\n+/g, ` +$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g, "$1$2").replace(/\n+/g, `$&${v}`); + const ie = G(`${J}${e}${Z}`, v, j, F.fold); + return `${V} +${v}${ie}`; + } + function P(L, C, e, O) { + const { + comment: I, + type: $, + value: v + } = L, { + actualString: N, + implicitKey: W, + indent: V, + inFlow: J + } = C; + if (W && /[\n[\]{},]/.test(v) || J && /[[\]{},]/.test(v)) + return me(v, C); + if (!v || /^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(v)) + return W || J || v.indexOf(` +`) === -1 ? v.indexOf('"') !== -1 && v.indexOf("'") === -1 ? ee(v, C) : me(v, C) : de(L, C, e, O); + if (!W && !J && $ !== i.Type.PLAIN && v.indexOf(` +`) !== -1) + return de(L, C, e, O); + if (V === "" && fe(v)) + return C.forceBlockIndent = !0, de(L, C, e, O); + const Z = v.replace(/\n+/g, `$& +${V}`); + if (N) { + const { + tags: oe + } = C.doc.schema; + if (typeof D(Z, oe, oe.scalarFallback).value != "string") + return me(v, C); + } + const ie = W ? Z : G(Z, V, H, X(C)); + return I && !J && (ie.indexOf(` +`) !== -1 || I.indexOf(` +`) !== -1) ? (e && e(), t(ie, V, I)) : ie; + } + function z(L, C, e, O) { + const { + defaultType: I + } = F, { + implicitKey: $, + inFlow: v + } = C; + let { + type: N, + value: W + } = L; + typeof W != "string" && (W = String(W), L = Object.assign({}, L, { + value: W + })); + const V = (Z) => { + switch (Z) { + case i.Type.BLOCK_FOLDED: + case i.Type.BLOCK_LITERAL: + return de(L, C, e, O); + case i.Type.QUOTE_DOUBLE: + return me(W, C); + case i.Type.QUOTE_SINGLE: + return ee(W, C); + case i.Type.PLAIN: + return P(L, C, e, O); + default: + return null; + } + }; + (N !== i.Type.QUOTE_DOUBLE && /[\x00-\x08\x0b-\x1f\x7f-\x9f]/.test(W) || ($ || v) && (N === i.Type.BLOCK_FOLDED || N === i.Type.BLOCK_LITERAL)) && (N = i.Type.QUOTE_DOUBLE); + let J = V(N); + if (J === null && (J = V(I), J === null)) + throw new Error(`Unsupported default string type ${I}`); + return J; + } + function ae({ + format: L, + minFractionDigits: C, + tag: e, + value: O + }) { + if (typeof O == "bigint") + return String(O); + if (!isFinite(O)) + return isNaN(O) ? ".nan" : O < 0 ? "-.inf" : ".inf"; + let I = JSON.stringify(O); + if (!L && C && (!e || e === "tag:yaml.org,2002:float") && /^\d/.test(I)) { + let $ = I.indexOf("."); + $ < 0 && ($ = I.length, I += "."); + let v = C - (I.length - $ - 1); + for (; v-- > 0; ) + I += "0"; + } + return I; + } + function re(L, C) { + let e, O; + switch (C.type) { + case i.Type.FLOW_MAP: + e = "}", O = "flow map"; + break; + case i.Type.FLOW_SEQ: + e = "]", O = "flow sequence"; + break; + default: + L.push(new i.YAMLSemanticError(C, "Not a flow collection!?")); + return; + } + let I; + for (let $ = C.items.length - 1; $ >= 0; --$) { + const v = C.items[$]; + if (!v || v.type !== i.Type.COMMENT) { + I = v; + break; + } + } + if (I && I.char !== e) { + const $ = `Expected ${O} to end with ${e}`; + let v; + typeof I.offset == "number" ? (v = new i.YAMLSemanticError(C, $), v.offset = I.offset + 1) : (v = new i.YAMLSemanticError(I, $), I.range && I.range.end && (v.offset = I.range.end - I.range.start)), L.push(v); + } + } + function Y(L, C) { + const e = C.context.src[C.range.start - 1]; + if (e !== ` +` && e !== " " && e !== " ") { + const O = "Comments must be separated from other tokens by white space characters"; + L.push(new i.YAMLSemanticError(C, O)); + } + } + function K(L, C) { + const e = String(C), O = e.substr(0, 8) + "..." + e.substr(-8); + return new i.YAMLSemanticError(L, `The "${O}" key is too long`); + } + function se(L, C) { + for (const { + afterKey: e, + before: O, + comment: I + } of C) { + let $ = L.items[O]; + $ ? (e && $.value && ($ = $.value), I === void 0 ? (e || !$.commentBefore) && ($.spaceBefore = !0) : $.commentBefore ? $.commentBefore += ` +` + I : $.commentBefore = I) : I !== void 0 && (L.comment ? L.comment += ` +` + I : L.comment = I); + } + } + function ce(L, C) { + const e = C.strValue; + return e ? typeof e == "string" ? e : (e.errors.forEach((O) => { + O.source || (O.source = C), L.errors.push(O); + }), e.str) : ""; + } + function ve(L, C) { + const { + handle: e, + suffix: O + } = C.tag; + let I = L.tagPrefixes.find(($) => $.handle === e); + if (!I) { + const $ = L.getDefaults().tagPrefixes; + if ($ && (I = $.find((v) => v.handle === e)), !I) + throw new i.YAMLSemanticError(C, `The ${e} tag handle is non-default and was not declared.`); + } + if (!O) + throw new i.YAMLSemanticError(C, `The ${e} tag has no suffix.`); + if (e === "!" && (L.version || L.options.version) === "1.0") { + if (O[0] === "^") + return L.warnings.push(new i.YAMLWarning(C, "YAML 1.0 ^ tag expansion is not supported")), O; + if (/[:/]/.test(O)) { + const $ = O.match(/^([a-z0-9-]+)\/(.*)/i); + return $ ? `tag:${$[1]}.yaml.org,2002:${$[2]}` : `tag:${O}`; + } + } + return I.prefix + decodeURIComponent(O); + } + function pe(L, C) { + const { + tag: e, + type: O + } = C; + let I = !1; + if (e) { + const { + handle: $, + suffix: v, + verbatim: N + } = e; + if (N) { + if (N !== "!" && N !== "!!") + return N; + const W = `Verbatim tags aren't resolved, so ${N} is invalid.`; + L.errors.push(new i.YAMLSemanticError(C, W)); + } else if ($ === "!" && !v) + I = !0; + else + try { + return ve(L, C); + } catch (W) { + L.errors.push(W); + } + } + switch (O) { + case i.Type.BLOCK_FOLDED: + case i.Type.BLOCK_LITERAL: + case i.Type.QUOTE_DOUBLE: + case i.Type.QUOTE_SINGLE: + return i.defaultTags.STR; + case i.Type.FLOW_MAP: + case i.Type.MAP: + return i.defaultTags.MAP; + case i.Type.FLOW_SEQ: + case i.Type.SEQ: + return i.defaultTags.SEQ; + case i.Type.PLAIN: + return I ? i.defaultTags.STR : null; + default: + return null; + } + } + function Se(L, C, e) { + const { + tags: O + } = L.schema, I = []; + for (const v of O) + if (v.tag === e) + if (v.test) + I.push(v); + else { + const N = v.resolve(L, C); + return N instanceof m ? N : new a(N); + } + const $ = ce(L, C); + return typeof $ == "string" && I.length > 0 ? D($, I, O.scalarFallback) : null; + } + function Ee({ + type: L + }) { + switch (L) { + case i.Type.FLOW_MAP: + case i.Type.MAP: + return i.defaultTags.MAP; + case i.Type.FLOW_SEQ: + case i.Type.SEQ: + return i.defaultTags.SEQ; + default: + return i.defaultTags.STR; + } + } + function Ce(L, C, e) { + try { + const O = Se(L, C, e); + if (O) + return e && C.tag && (O.tag = e), O; + } catch (O) { + return O.source || (O.source = C), L.errors.push(O), null; + } + try { + const O = Ee(C); + if (!O) + throw new Error(`The tag ${e} is unavailable`); + const I = `The tag ${e} is unavailable, falling back to ${O}`; + L.warnings.push(new i.YAMLWarning(C, I)); + const $ = Se(L, C, O); + return $.tag = e, $; + } catch (O) { + const I = new i.YAMLReferenceError(C, O.message); + return I.stack = O.stack, L.errors.push(I), null; + } + } + var B = (L) => { + if (!L) + return !1; + const { + type: C + } = L; + return C === i.Type.MAP_KEY || C === i.Type.MAP_VALUE || C === i.Type.SEQ_ITEM; + }; + function U(L, C) { + const e = { + before: [], + after: [] + }; + let O = !1, I = !1; + const $ = B(C.context.parent) ? C.context.parent.props.concat(C.props) : C.props; + for (const { + start: v, + end: N + } of $) + switch (C.context.src[v]) { + case i.Char.COMMENT: { + if (!C.commentHasRequiredWhitespace(v)) { + const Z = "Comments must be separated from other tokens by white space characters"; + L.push(new i.YAMLSemanticError(C, Z)); + } + const { + header: W, + valueRange: V + } = C; + (V && (v > V.start || W && v > W.start) ? e.after : e.before).push(C.context.src.slice(v + 1, N)); + break; + } + case i.Char.ANCHOR: + if (O) { + const W = "A node can have at most one anchor"; + L.push(new i.YAMLSemanticError(C, W)); + } + O = !0; + break; + case i.Char.TAG: + if (I) { + const W = "A node can have at most one tag"; + L.push(new i.YAMLSemanticError(C, W)); + } + I = !0; + break; + } + return { + comments: e, + hasAnchor: O, + hasTag: I + }; + } + function le(L, C) { + const { + anchors: e, + errors: O, + schema: I + } = L; + if (C.type === i.Type.ALIAS) { + const v = C.rawValue, N = e.getNode(v); + if (!N) { + const V = `Aliased anchor not found: ${v}`; + return O.push(new i.YAMLReferenceError(C, V)), null; + } + const W = new R(N); + return e._cstAliases.push(W), W; + } + const $ = pe(L, C); + if ($) + return Ce(L, C, $); + if (C.type !== i.Type.PLAIN) { + const v = `Failed to resolve ${C.type} node here`; + return O.push(new i.YAMLSyntaxError(C, v)), null; + } + try { + const v = ce(L, C); + return D(v, I.tags, I.tags.scalarFallback); + } catch (v) { + return v.source || (v.source = C), O.push(v), null; + } + } + function he(L, C) { + if (!C) + return null; + C.error && L.errors.push(C.error); + const { + comments: e, + hasAnchor: O, + hasTag: I + } = U(L.errors, C); + if (O) { + const { + anchors: v + } = L, N = C.anchor, W = v.getNode(N); + W && (v.map[v.newName(N)] = W), v.map[N] = C; + } + if (C.type === i.Type.ALIAS && (O || I)) { + const v = "An alias node must not specify any properties"; + L.errors.push(new i.YAMLSemanticError(C, v)); + } + const $ = le(L, C); + if ($) { + $.range = [C.range.start, C.range.end], L.options.keepCstNodes && ($.cstNode = C), L.options.keepNodeTypes && ($.type = C.type); + const v = e.before.join(` +`); + v && ($.commentBefore = $.commentBefore ? `${$.commentBefore} +${v}` : v); + const N = e.after.join(` +`); + N && ($.comment = $.comment ? `${$.comment} +${N}` : N); + } + return C.resolved = $; + } + function Te(L, C) { + if (C.type !== i.Type.MAP && C.type !== i.Type.FLOW_MAP) { + const v = `A ${C.type} node cannot be resolved as a mapping`; + return L.errors.push(new i.YAMLSyntaxError(C, v)), null; + } + const { + comments: e, + items: O + } = C.type === i.Type.FLOW_MAP ? q(L, C) : k(L, C), I = new o(); + I.items = O, se(I, e); + let $ = !1; + for (let v = 0; v < O.length; ++v) { + const { + key: N + } = O[v]; + if (N instanceof m && ($ = !0), L.schema.merge && N && N.value === c) { + O[v] = new f(O[v]); + const W = O[v].value.items; + let V = null; + W.some((J) => { + if (J instanceof R) { + const { + type: Z + } = J.source; + return Z === i.Type.MAP || Z === i.Type.FLOW_MAP ? !1 : V = "Merge nodes aliases can only point to maps"; + } + return V = "Merge nodes can only have Alias nodes as values"; + }), V && L.errors.push(new i.YAMLSemanticError(C, V)); + } else + for (let W = v + 1; W < O.length; ++W) { + const { + key: V + } = O[W]; + if (N === V || N && V && Object.prototype.hasOwnProperty.call(N, "value") && N.value === V.value) { + const J = `Map keys must be unique; "${N}" is repeated`; + L.errors.push(new i.YAMLSemanticError(C, J)); + break; + } + } + } + if ($ && !L.options.mapAsMap) { + const v = "Keys with collection values will be stringified as YAML due to JS Object restrictions. Use mapAsMap: true to avoid this."; + L.warnings.push(new i.YAMLWarning(C, v)); + } + return C.resolved = I, I; + } + var u = ({ + context: { + lineStart: L, + node: C, + src: e + }, + props: O + }) => { + if (O.length === 0) + return !1; + const { + start: I + } = O[0]; + if (C && I > C.valueRange.start || e[I] !== i.Char.COMMENT) + return !1; + for (let $ = L; $ < I; ++$) + if (e[$] === ` +`) + return !1; + return !0; + }; + function w(L, C) { + if (!u(L)) + return; + const e = L.getPropValue(0, i.Char.COMMENT, !0); + let O = !1; + const I = C.value.commentBefore; + if (I && I.startsWith(e)) + C.value.commentBefore = I.substr(e.length + 1), O = !0; + else { + const $ = C.value.comment; + !L.node && $ && $.startsWith(e) && (C.value.comment = $.substr(e.length + 1), O = !0); + } + O && (C.comment = e); + } + function k(L, C) { + const e = [], O = []; + let I, $ = null; + for (let v = 0; v < C.items.length; ++v) { + const N = C.items[v]; + switch (N.type) { + case i.Type.BLANK_LINE: + e.push({ + afterKey: !!I, + before: O.length + }); + break; + case i.Type.COMMENT: + e.push({ + afterKey: !!I, + before: O.length, + comment: N.comment + }); + break; + case i.Type.MAP_KEY: + I !== void 0 && O.push(new g(I)), N.error && L.errors.push(N.error), I = he(L, N.node), $ = null; + break; + case i.Type.MAP_VALUE: + { + if (I === void 0 && (I = null), N.error && L.errors.push(N.error), !N.context.atLineStart && N.node && N.node.type === i.Type.MAP && !N.node.context.atLineStart) { + const J = "Nested mappings are not allowed in compact mappings"; + L.errors.push(new i.YAMLSemanticError(N.node, J)); + } + let W = N.node; + if (!W && N.props.length > 0) { + W = new i.PlainValue(i.Type.PLAIN, []), W.context = { + parent: N, + src: N.context.src + }; + const J = N.range.start + 1; + if (W.range = { + start: J, + end: J + }, W.valueRange = { + start: J, + end: J + }, typeof N.range.origStart == "number") { + const Z = N.range.origStart + 1; + W.range.origStart = W.range.origEnd = Z, W.valueRange.origStart = W.valueRange.origEnd = Z; + } + } + const V = new g(I, he(L, W)); + w(N, V), O.push(V), I && typeof $ == "number" && N.range.start > $ + 1024 && L.errors.push(K(C, I)), I = void 0, $ = null; + } + break; + default: + I !== void 0 && O.push(new g(I)), I = he(L, N), $ = N.range.start, N.error && L.errors.push(N.error); + e: + for (let W = v + 1; ; ++W) { + const V = C.items[W]; + switch (V && V.type) { + case i.Type.BLANK_LINE: + case i.Type.COMMENT: + continue e; + case i.Type.MAP_VALUE: + break e; + default: { + const J = "Implicit map keys need to be followed by map values"; + L.errors.push(new i.YAMLSemanticError(N, J)); + break e; + } + } + } + if (N.valueRangeContainsNewline) { + const W = "Implicit map keys need to be on a single line"; + L.errors.push(new i.YAMLSemanticError(N, W)); + } + } + } + return I !== void 0 && O.push(new g(I)), { + comments: e, + items: O + }; + } + function q(L, C) { + const e = [], O = []; + let I, $ = !1, v = "{"; + for (let N = 0; N < C.items.length; ++N) { + const W = C.items[N]; + if (typeof W.char == "string") { + const { + char: V, + offset: J + } = W; + if (V === "?" && I === void 0 && !$) { + $ = !0, v = ":"; + continue; + } + if (V === ":") { + if (I === void 0 && (I = null), v === ":") { + v = ","; + continue; + } + } else if ($ && (I === void 0 && V !== "," && (I = null), $ = !1), I !== void 0 && (O.push(new g(I)), I = void 0, V === ",")) { + v = ":"; + continue; + } + if (V === "}") { + if (N === C.items.length - 1) + continue; + } else if (V === v) { + v = ":"; + continue; + } + const Z = `Flow map contains an unexpected ${V}`, ie = new i.YAMLSyntaxError(C, Z); + ie.offset = J, L.errors.push(ie); + } else W.type === i.Type.BLANK_LINE ? e.push({ + afterKey: !!I, + before: O.length + }) : W.type === i.Type.COMMENT ? (Y(L.errors, W), e.push({ + afterKey: !!I, + before: O.length, + comment: W.comment + })) : I === void 0 ? (v === "," && L.errors.push(new i.YAMLSemanticError(W, "Separator , missing in flow map")), I = he(L, W)) : (v !== "," && L.errors.push(new i.YAMLSemanticError(W, "Indicator : missing in flow map entry")), O.push(new g(I, he(L, W))), I = void 0, $ = !1); + } + return re(L.errors, C), I !== void 0 && O.push(new g(I)), { + comments: e, + items: O + }; + } + function ne(L, C) { + if (C.type !== i.Type.SEQ && C.type !== i.Type.FLOW_SEQ) { + const $ = `A ${C.type} node cannot be resolved as a sequence`; + return L.errors.push(new i.YAMLSyntaxError(C, $)), null; + } + const { + comments: e, + items: O + } = C.type === i.Type.FLOW_SEQ ? we(L, C) : ue(L, C), I = new y(); + if (I.items = O, se(I, e), !L.options.mapAsMap && O.some(($) => $ instanceof g && $.key instanceof m)) { + const $ = "Keys with collection values will be stringified as YAML due to JS Object restrictions. Use mapAsMap: true to avoid this."; + L.warnings.push(new i.YAMLWarning(C, $)); + } + return C.resolved = I, I; + } + function ue(L, C) { + const e = [], O = []; + for (let I = 0; I < C.items.length; ++I) { + const $ = C.items[I]; + switch ($.type) { + case i.Type.BLANK_LINE: + e.push({ + before: O.length + }); + break; + case i.Type.COMMENT: + e.push({ + comment: $.comment, + before: O.length + }); + break; + case i.Type.SEQ_ITEM: + if ($.error && L.errors.push($.error), O.push(he(L, $.node)), $.hasProps) { + const v = "Sequence items cannot have tags or anchors before the - indicator"; + L.errors.push(new i.YAMLSemanticError($, v)); + } + break; + default: + $.error && L.errors.push($.error), L.errors.push(new i.YAMLSyntaxError($, `Unexpected ${$.type} node in sequence`)); + } + } + return { + comments: e, + items: O + }; + } + function we(L, C) { + const e = [], O = []; + let I = !1, $, v = null, N = "[", W = null; + for (let V = 0; V < C.items.length; ++V) { + const J = C.items[V]; + if (typeof J.char == "string") { + const { + char: Z, + offset: ie + } = J; + if (Z !== ":" && (I || $ !== void 0) && (I && $ === void 0 && ($ = N ? O.pop() : null), O.push(new g($)), I = !1, $ = void 0, v = null), Z === N) + N = null; + else if (!N && Z === "?") + I = !0; + else if (N !== "[" && Z === ":" && $ === void 0) { + if (N === ",") { + if ($ = O.pop(), $ instanceof g) { + const oe = "Chaining flow sequence pairs is invalid", ge = new i.YAMLSemanticError(C, oe); + ge.offset = ie, L.errors.push(ge); + } + if (!I && typeof v == "number") { + const oe = J.range ? J.range.start : J.offset; + oe > v + 1024 && L.errors.push(K(C, $)); + const { + src: ge + } = W.context; + for (let ye = v; ye < oe; ++ye) + if (ge[ye] === ` +`) { + const be = "Implicit keys of flow sequence pairs need to be on a single line"; + L.errors.push(new i.YAMLSemanticError(W, be)); + break; + } + } + } else + $ = null; + v = null, I = !1, N = null; + } else if (N === "[" || Z !== "]" || V < C.items.length - 1) { + const oe = `Flow sequence contains an unexpected ${Z}`, ge = new i.YAMLSyntaxError(C, oe); + ge.offset = ie, L.errors.push(ge); + } + } else if (J.type === i.Type.BLANK_LINE) + e.push({ + before: O.length + }); + else if (J.type === i.Type.COMMENT) + Y(L.errors, J), e.push({ + comment: J.comment, + before: O.length + }); + else { + if (N) { + const ie = `Expected a ${N} in flow sequence`; + L.errors.push(new i.YAMLSemanticError(J, ie)); + } + const Z = he(L, J); + $ === void 0 ? (O.push(Z), W = J) : (O.push(new g($, Z)), $ = void 0), v = J.range.start, N = ","; + } + } + return re(L.errors, C), $ !== void 0 && O.push(new g($)), { + comments: e, + items: O + }; + } + r.Alias = R, r.Collection = m, r.Merge = f, r.Node = p, r.Pair = g, r.Scalar = a, r.YAMLMap = o, r.YAMLSeq = y, r.addComment = n, r.binaryOptions = b, r.boolOptions = A, r.findPair = l, r.intOptions = _, r.isEmptyPath = x, r.nullOptions = S, r.resolveMap = Te, r.resolveNode = he, r.resolveSeq = ne, r.resolveString = ce, r.strOptions = F, r.stringifyNumber = ae, r.stringifyString = z, r.toJSON = s; + } +}), Ut = De({ + "node_modules/yaml/dist/warnings-1000a372.js"(r) { + var i = lt(), t = At(), n = { + identify: (D) => D instanceof Uint8Array, + // Buffer inherits from Uint8Array + default: !1, + tag: "tag:yaml.org,2002:binary", + /** + * Returns a Buffer in node and an Uint8Array in browsers + * + * To use the resulting buffer as an image, you'll want to do something like: + * + * const blob = new Blob([buffer], { type: 'image/jpeg' }) + * document.querySelector('#photo').src = URL.createObjectURL(blob) + */ + resolve: (D, H) => { + const j = t.resolveString(D, H); + if (typeof Buffer == "function") + return Buffer.from(j, "base64"); + if (typeof atob == "function") { + const Q = atob(j.replace(/[\n\r]/g, "")), T = new Uint8Array(Q.length); + for (let G = 0; G < Q.length; ++G) + T[G] = Q.charCodeAt(G); + return T; + } else { + const Q = "This environment does not support reading binary tags; either Buffer or atob is required"; + return D.errors.push(new i.YAMLReferenceError(H, Q)), null; + } + }, + options: t.binaryOptions, + stringify: ({ + comment: D, + type: H, + value: j + }, Q, T, G) => { + let X; + if (typeof Buffer == "function") + X = j instanceof Buffer ? j.toString("base64") : Buffer.from(j.buffer).toString("base64"); + else if (typeof btoa == "function") { + let fe = ""; + for (let te = 0; te < j.length; ++te) + fe += String.fromCharCode(j[te]); + X = btoa(fe); + } else + throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required"); + if (H || (H = t.binaryOptions.defaultType), H === i.Type.QUOTE_DOUBLE) + j = X; + else { + const { + lineWidth: fe + } = t.binaryOptions, te = Math.ceil(X.length / fe), me = new Array(te); + for (let ee = 0, de = 0; ee < te; ++ee, de += fe) + me[ee] = X.substr(de, fe); + j = me.join(H === i.Type.BLOCK_LITERAL ? ` +` : " "); + } + return t.stringifyString({ + comment: D, + type: H, + value: j + }, Q, T, G); + } + }; + function p(D, H) { + const j = t.resolveSeq(D, H); + for (let Q = 0; Q < j.items.length; ++Q) { + let T = j.items[Q]; + if (!(T instanceof t.Pair)) { + if (T instanceof t.YAMLMap) { + if (T.items.length > 1) { + const X = "Each pair must have its own sequence indicator"; + throw new i.YAMLSemanticError(H, X); + } + const G = T.items[0] || new t.Pair(); + T.commentBefore && (G.commentBefore = G.commentBefore ? `${T.commentBefore} +${G.commentBefore}` : T.commentBefore), T.comment && (G.comment = G.comment ? `${T.comment} +${G.comment}` : T.comment), T = G; + } + j.items[Q] = T instanceof t.Pair ? T : new t.Pair(T); + } + } + return j; + } + function s(D, H, j) { + const Q = new t.YAMLSeq(D); + Q.tag = "tag:yaml.org,2002:pairs"; + for (const T of H) { + let G, X; + if (Array.isArray(T)) + if (T.length === 2) + G = T[0], X = T[1]; + else + throw new TypeError(`Expected [key, value] tuple: ${T}`); + else if (T && T instanceof Object) { + const te = Object.keys(T); + if (te.length === 1) + G = te[0], X = T[G]; + else + throw new TypeError(`Expected { key: value } tuple: ${T}`); + } else + G = T; + const fe = D.createPair(G, X, j); + Q.items.push(fe); + } + return Q; + } + var a = { + default: !1, + tag: "tag:yaml.org,2002:pairs", + resolve: p, + createNode: s + }, d = class Yt extends t.YAMLSeq { + constructor() { + super(), i._defineProperty(this, "add", t.YAMLMap.prototype.add.bind(this)), i._defineProperty(this, "delete", t.YAMLMap.prototype.delete.bind(this)), i._defineProperty(this, "get", t.YAMLMap.prototype.get.bind(this)), i._defineProperty(this, "has", t.YAMLMap.prototype.has.bind(this)), i._defineProperty(this, "set", t.YAMLMap.prototype.set.bind(this)), this.tag = Yt.tag; + } + toJSON(H, j) { + const Q = /* @__PURE__ */ new Map(); + j && j.onCreate && j.onCreate(Q); + for (const T of this.items) { + let G, X; + if (T instanceof t.Pair ? (G = t.toJSON(T.key, "", j), X = t.toJSON(T.value, G, j)) : G = t.toJSON(T, "", j), Q.has(G)) + throw new Error("Ordered maps must not include duplicate keys"); + Q.set(G, X); + } + return Q; + } + }; + i._defineProperty(d, "tag", "tag:yaml.org,2002:omap"); + function x(D, H) { + const j = p(D, H), Q = []; + for (const { + key: T + } of j.items) + if (T instanceof t.Scalar) + if (Q.includes(T.value)) { + const G = "Ordered maps must not include duplicate keys"; + throw new i.YAMLSemanticError(H, G); + } else + Q.push(T.value); + return Object.assign(new d(), j); + } + function m(D, H, j) { + const Q = s(D, H, j), T = new d(); + return T.items = Q.items, T; + } + var h = { + identify: (D) => D instanceof Map, + nodeClass: d, + default: !1, + tag: "tag:yaml.org,2002:omap", + resolve: x, + createNode: m + }, y = class Ht extends t.YAMLMap { + constructor() { + super(), this.tag = Ht.tag; + } + add(H) { + const j = H instanceof t.Pair ? H : new t.Pair(H); + t.findPair(this.items, j.key) || this.items.push(j); + } + get(H, j) { + const Q = t.findPair(this.items, H); + return !j && Q instanceof t.Pair ? Q.key instanceof t.Scalar ? Q.key.value : Q.key : Q; + } + set(H, j) { + if (typeof j != "boolean") + throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof j}`); + const Q = t.findPair(this.items, H); + Q && !j ? this.items.splice(this.items.indexOf(Q), 1) : !Q && j && this.items.push(new t.Pair(H)); + } + toJSON(H, j) { + return super.toJSON(H, j, Set); + } + toString(H, j, Q) { + if (!H) + return JSON.stringify(this); + if (this.hasAllNullValues()) + return super.toString(H, j, Q); + throw new Error("Set items must all have null values"); + } + }; + i._defineProperty(y, "tag", "tag:yaml.org,2002:set"); + function E(D, H) { + const j = t.resolveMap(D, H); + if (!j.hasAllNullValues()) + throw new i.YAMLSemanticError(H, "Set items must all have null values"); + return Object.assign(new y(), j); + } + function g(D, H, j) { + const Q = new y(); + for (const T of H) + Q.items.push(D.createPair(T, null, j)); + return Q; + } + var M = { + identify: (D) => D instanceof Set, + nodeClass: y, + default: !1, + tag: "tag:yaml.org,2002:set", + resolve: E, + createNode: g + }, R = (D, H) => { + const j = H.split(":").reduce((Q, T) => Q * 60 + Number(T), 0); + return D === "-" ? -j : j; + }, l = ({ + value: D + }) => { + if (isNaN(D) || !isFinite(D)) + return t.stringifyNumber(D); + let H = ""; + D < 0 && (H = "-", D = Math.abs(D)); + const j = [D % 60]; + return D < 60 ? j.unshift(0) : (D = Math.round((D - j[0]) / 60), j.unshift(D % 60), D >= 60 && (D = Math.round((D - j[0]) / 60), j.unshift(D))), H + j.map((Q) => Q < 10 ? "0" + String(Q) : String(Q)).join(":").replace(/000000\d*$/, ""); + }, o = { + identify: (D) => typeof D == "number", + default: !0, + tag: "tag:yaml.org,2002:int", + format: "TIME", + test: /^([-+]?)([0-9][0-9_]*(?::[0-5]?[0-9])+)$/, + resolve: (D, H, j) => R(H, j.replace(/_/g, "")), + stringify: l + }, c = { + identify: (D) => typeof D == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + format: "TIME", + test: /^([-+]?)([0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*)$/, + resolve: (D, H, j) => R(H, j.replace(/_/g, "")), + stringify: l + }, f = { + identify: (D) => D instanceof Date, + default: !0, + tag: "tag:yaml.org,2002:timestamp", + // If the time zone is omitted, the timestamp is assumed to be specified in UTC. The time part + // may be omitted altogether, resulting in a date format. In such a case, the time part is + // assumed to be 00:00:00Z (start of day, UTC). + test: RegExp("^(?:([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?)$"), + resolve: (D, H, j, Q, T, G, X, fe, te) => { + fe && (fe = (fe + "00").substr(1, 3)); + let me = Date.UTC(H, j - 1, Q, T || 0, G || 0, X || 0, fe || 0); + if (te && te !== "Z") { + let ee = R(te[0], te.slice(1)); + Math.abs(ee) < 30 && (ee *= 60), me -= 6e4 * ee; + } + return new Date(me); + }, + stringify: ({ + value: D + }) => D.toISOString().replace(/((T00:00)?:00)?\.000Z$/, "") + }; + function b(D) { + const H = typeof process < "u" && process.env || {}; + return D ? typeof YAML_SILENCE_DEPRECATION_WARNINGS < "u" ? !YAML_SILENCE_DEPRECATION_WARNINGS : !H.YAML_SILENCE_DEPRECATION_WARNINGS : typeof YAML_SILENCE_WARNINGS < "u" ? !YAML_SILENCE_WARNINGS : !H.YAML_SILENCE_WARNINGS; + } + function A(D, H) { + if (b(!1)) { + const j = typeof process < "u" && process.emitWarning; + j ? j(D, H) : console.warn(H ? `${H}: ${D}` : D); + } + } + function _(D) { + if (b(!0)) { + const H = D.replace(/.*yaml[/\\]/i, "").replace(/\.js$/, "").replace(/\\/g, "/"); + A(`The endpoint 'yaml/${H}' will be removed in a future release.`, "DeprecationWarning"); + } + } + var S = {}; + function F(D, H) { + if (!S[D] && b(!0)) { + S[D] = !0; + let j = `The option '${D}' will be removed in a future release`; + j += H ? `, use '${H}' instead.` : ".", A(j, "DeprecationWarning"); + } + } + r.binary = n, r.floatTime = c, r.intTime = o, r.omap = h, r.pairs = a, r.set = M, r.timestamp = f, r.warn = A, r.warnFileDeprecation = _, r.warnOptionDeprecation = F; + } +}), Fr = De({ + "node_modules/yaml/dist/Schema-88e323a7.js"(r) { + var i = lt(), t = At(), n = Ut(); + function p(P, z, ae) { + const re = new t.YAMLMap(P); + if (z instanceof Map) + for (const [Y, K] of z) + re.items.push(P.createPair(Y, K, ae)); + else if (z && typeof z == "object") + for (const Y of Object.keys(z)) + re.items.push(P.createPair(Y, z[Y], ae)); + return typeof P.sortMapEntries == "function" && re.items.sort(P.sortMapEntries), re; + } + var s = { + createNode: p, + default: !0, + nodeClass: t.YAMLMap, + tag: "tag:yaml.org,2002:map", + resolve: t.resolveMap + }; + function a(P, z, ae) { + const re = new t.YAMLSeq(P); + if (z && z[Symbol.iterator]) + for (const Y of z) { + const K = P.createNode(Y, ae.wrapScalars, null, ae); + re.items.push(K); + } + return re; + } + var d = { + createNode: a, + default: !0, + nodeClass: t.YAMLSeq, + tag: "tag:yaml.org,2002:seq", + resolve: t.resolveSeq + }, x = { + identify: (P) => typeof P == "string", + default: !0, + tag: "tag:yaml.org,2002:str", + resolve: t.resolveString, + stringify(P, z, ae, re) { + return z = Object.assign({ + actualString: !0 + }, z), t.stringifyString(P, z, ae, re); + }, + options: t.strOptions + }, m = [s, d, x], h = (P) => typeof P == "bigint" || Number.isInteger(P), y = (P, z, ae) => t.intOptions.asBigInt ? BigInt(P) : parseInt(z, ae); + function E(P, z, ae) { + const { + value: re + } = P; + return h(re) && re >= 0 ? ae + re.toString(z) : t.stringifyNumber(P); + } + var g = { + identify: (P) => P == null, + createNode: (P, z, ae) => ae.wrapScalars ? new t.Scalar(null) : null, + default: !0, + tag: "tag:yaml.org,2002:null", + test: /^(?:~|[Nn]ull|NULL)?$/, + resolve: () => null, + options: t.nullOptions, + stringify: () => t.nullOptions.nullStr + }, M = { + identify: (P) => typeof P == "boolean", + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/, + resolve: (P) => P[0] === "t" || P[0] === "T", + options: t.boolOptions, + stringify: ({ + value: P + }) => P ? t.boolOptions.trueStr : t.boolOptions.falseStr + }, R = { + identify: (P) => h(P) && P >= 0, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "OCT", + test: /^0o([0-7]+)$/, + resolve: (P, z) => y(P, z, 8), + options: t.intOptions, + stringify: (P) => E(P, 8, "0o") + }, l = { + identify: h, + default: !0, + tag: "tag:yaml.org,2002:int", + test: /^[-+]?[0-9]+$/, + resolve: (P) => y(P, P, 10), + options: t.intOptions, + stringify: t.stringifyNumber + }, o = { + identify: (P) => h(P) && P >= 0, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "HEX", + test: /^0x([0-9a-fA-F]+)$/, + resolve: (P, z) => y(P, z, 16), + options: t.intOptions, + stringify: (P) => E(P, 16, "0x") + }, c = { + identify: (P) => typeof P == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^(?:[-+]?\.inf|(\.nan))$/i, + resolve: (P, z) => z ? NaN : P[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, + stringify: t.stringifyNumber + }, f = { + identify: (P) => typeof P == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + format: "EXP", + test: /^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/, + resolve: (P) => parseFloat(P), + stringify: ({ + value: P + }) => Number(P).toExponential() + }, b = { + identify: (P) => typeof P == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^[-+]?(?:\.([0-9]+)|[0-9]+\.([0-9]*))$/, + resolve(P, z, ae) { + const re = z || ae, Y = new t.Scalar(parseFloat(P)); + return re && re[re.length - 1] === "0" && (Y.minFractionDigits = re.length), Y; + }, + stringify: t.stringifyNumber + }, A = m.concat([g, M, R, l, o, c, f, b]), _ = (P) => typeof P == "bigint" || Number.isInteger(P), S = ({ + value: P + }) => JSON.stringify(P), F = [s, d, { + identify: (P) => typeof P == "string", + default: !0, + tag: "tag:yaml.org,2002:str", + resolve: t.resolveString, + stringify: S + }, { + identify: (P) => P == null, + createNode: (P, z, ae) => ae.wrapScalars ? new t.Scalar(null) : null, + default: !0, + tag: "tag:yaml.org,2002:null", + test: /^null$/, + resolve: () => null, + stringify: S + }, { + identify: (P) => typeof P == "boolean", + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^true|false$/, + resolve: (P) => P === "true", + stringify: S + }, { + identify: _, + default: !0, + tag: "tag:yaml.org,2002:int", + test: /^-?(?:0|[1-9][0-9]*)$/, + resolve: (P) => t.intOptions.asBigInt ? BigInt(P) : parseInt(P, 10), + stringify: ({ + value: P + }) => _(P) ? P.toString() : JSON.stringify(P) + }, { + identify: (P) => typeof P == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/, + resolve: (P) => parseFloat(P), + stringify: S + }]; + F.scalarFallback = (P) => { + throw new SyntaxError(`Unresolved plain scalar ${JSON.stringify(P)}`); + }; + var D = ({ + value: P + }) => P ? t.boolOptions.trueStr : t.boolOptions.falseStr, H = (P) => typeof P == "bigint" || Number.isInteger(P); + function j(P, z, ae) { + let re = z.replace(/_/g, ""); + if (t.intOptions.asBigInt) { + switch (ae) { + case 2: + re = `0b${re}`; + break; + case 8: + re = `0o${re}`; + break; + case 16: + re = `0x${re}`; + break; + } + const K = BigInt(re); + return P === "-" ? BigInt(-1) * K : K; + } + const Y = parseInt(re, ae); + return P === "-" ? -1 * Y : Y; + } + function Q(P, z, ae) { + const { + value: re + } = P; + if (H(re)) { + const Y = re.toString(z); + return re < 0 ? "-" + ae + Y.substr(1) : ae + Y; + } + return t.stringifyNumber(P); + } + var T = m.concat([{ + identify: (P) => P == null, + createNode: (P, z, ae) => ae.wrapScalars ? new t.Scalar(null) : null, + default: !0, + tag: "tag:yaml.org,2002:null", + test: /^(?:~|[Nn]ull|NULL)?$/, + resolve: () => null, + options: t.nullOptions, + stringify: () => t.nullOptions.nullStr + }, { + identify: (P) => typeof P == "boolean", + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/, + resolve: () => !0, + options: t.boolOptions, + stringify: D + }, { + identify: (P) => typeof P == "boolean", + default: !0, + tag: "tag:yaml.org,2002:bool", + test: /^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/i, + resolve: () => !1, + options: t.boolOptions, + stringify: D + }, { + identify: H, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "BIN", + test: /^([-+]?)0b([0-1_]+)$/, + resolve: (P, z, ae) => j(z, ae, 2), + stringify: (P) => Q(P, 2, "0b") + }, { + identify: H, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "OCT", + test: /^([-+]?)0([0-7_]+)$/, + resolve: (P, z, ae) => j(z, ae, 8), + stringify: (P) => Q(P, 8, "0") + }, { + identify: H, + default: !0, + tag: "tag:yaml.org,2002:int", + test: /^([-+]?)([0-9][0-9_]*)$/, + resolve: (P, z, ae) => j(z, ae, 10), + stringify: t.stringifyNumber + }, { + identify: H, + default: !0, + tag: "tag:yaml.org,2002:int", + format: "HEX", + test: /^([-+]?)0x([0-9a-fA-F_]+)$/, + resolve: (P, z, ae) => j(z, ae, 16), + stringify: (P) => Q(P, 16, "0x") + }, { + identify: (P) => typeof P == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^(?:[-+]?\.inf|(\.nan))$/i, + resolve: (P, z) => z ? NaN : P[0] === "-" ? Number.NEGATIVE_INFINITY : Number.POSITIVE_INFINITY, + stringify: t.stringifyNumber + }, { + identify: (P) => typeof P == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + format: "EXP", + test: /^[-+]?([0-9][0-9_]*)?(\.[0-9_]*)?[eE][-+]?[0-9]+$/, + resolve: (P) => parseFloat(P.replace(/_/g, "")), + stringify: ({ + value: P + }) => Number(P).toExponential() + }, { + identify: (P) => typeof P == "number", + default: !0, + tag: "tag:yaml.org,2002:float", + test: /^[-+]?(?:[0-9][0-9_]*)?\.([0-9_]*)$/, + resolve(P, z) { + const ae = new t.Scalar(parseFloat(P.replace(/_/g, ""))); + if (z) { + const re = z.replace(/_/g, ""); + re[re.length - 1] === "0" && (ae.minFractionDigits = re.length); + } + return ae; + }, + stringify: t.stringifyNumber + }], n.binary, n.omap, n.pairs, n.set, n.intTime, n.floatTime, n.timestamp), G = { + core: A, + failsafe: m, + json: F, + yaml11: T + }, X = { + binary: n.binary, + bool: M, + float: b, + floatExp: f, + floatNaN: c, + floatTime: n.floatTime, + int: l, + intHex: o, + intOct: R, + intTime: n.intTime, + map: s, + null: g, + omap: n.omap, + pairs: n.pairs, + seq: d, + set: n.set, + timestamp: n.timestamp + }; + function fe(P, z, ae) { + if (z) { + const re = ae.filter((K) => K.tag === z), Y = re.find((K) => !K.format) || re[0]; + if (!Y) + throw new Error(`Tag ${z} not found`); + return Y; + } + return ae.find((re) => (re.identify && re.identify(P) || re.class && P instanceof re.class) && !re.format); + } + function te(P, z, ae) { + if (P instanceof t.Node) + return P; + const { + defaultPrefix: re, + onTagObj: Y, + prevObjects: K, + schema: se, + wrapScalars: ce + } = ae; + z && z.startsWith("!!") && (z = re + z.slice(2)); + let ve = fe(P, z, se.tags); + if (!ve) { + if (typeof P.toJSON == "function" && (P = P.toJSON()), !P || typeof P != "object") + return ce ? new t.Scalar(P) : P; + ve = P instanceof Map ? s : P[Symbol.iterator] ? d : s; + } + Y && (Y(ve), delete ae.onTagObj); + const pe = { + value: void 0, + node: void 0 + }; + if (P && typeof P == "object" && K) { + const Se = K.get(P); + if (Se) { + const Ee = new t.Alias(Se); + return ae.aliasNodes.push(Ee), Ee; + } + pe.value = P, K.set(P, pe); + } + return pe.node = ve.createNode ? ve.createNode(ae.schema, P, ae) : ce ? new t.Scalar(P) : P, z && pe.node instanceof t.Node && (pe.node.tag = z), pe.node; + } + function me(P, z, ae, re) { + let Y = P[re.replace(/\W/g, "")]; + if (!Y) { + const K = Object.keys(P).map((se) => JSON.stringify(se)).join(", "); + throw new Error(`Unknown schema "${re}"; use one of ${K}`); + } + if (Array.isArray(ae)) + for (const K of ae) + Y = Y.concat(K); + else typeof ae == "function" && (Y = ae(Y.slice())); + for (let K = 0; K < Y.length; ++K) { + const se = Y[K]; + if (typeof se == "string") { + const ce = z[se]; + if (!ce) { + const ve = Object.keys(z).map((pe) => JSON.stringify(pe)).join(", "); + throw new Error(`Unknown custom tag "${se}"; use one of ${ve}`); + } + Y[K] = ce; + } + } + return Y; + } + var ee = (P, z) => P.key < z.key ? -1 : P.key > z.key ? 1 : 0, de = class Wt { + // TODO: remove in v2 + // TODO: remove in v2 + constructor({ + customTags: z, + merge: ae, + schema: re, + sortMapEntries: Y, + tags: K + }) { + this.merge = !!ae, this.name = re, this.sortMapEntries = Y === !0 ? ee : Y || null, !z && K && n.warnOptionDeprecation("tags", "customTags"), this.tags = me(G, X, z || K, re); + } + createNode(z, ae, re, Y) { + const K = { + defaultPrefix: Wt.defaultPrefix, + schema: this, + wrapScalars: ae + }, se = Y ? Object.assign(Y, K) : K; + return te(z, re, se); + } + createPair(z, ae, re) { + re || (re = { + wrapScalars: !0 + }); + const Y = this.createNode(z, re.wrapScalars, null, re), K = this.createNode(ae, re.wrapScalars, null, re); + return new t.Pair(Y, K); + } + }; + i._defineProperty(de, "defaultPrefix", i.defaultTagPrefix), i._defineProperty(de, "defaultTags", i.defaultTags), r.Schema = de; + } +}), Ur = De({ + "node_modules/yaml/dist/types.js"(r) { + var i = At(), t = Fr(); + lt(), Ut(), r.Alias = i.Alias, r.Collection = i.Collection, r.Merge = i.Merge, r.Node = i.Node, r.Pair = i.Pair, r.Scalar = i.Scalar, r.YAMLMap = i.YAMLMap, r.YAMLSeq = i.YAMLSeq, r.binaryOptions = i.binaryOptions, r.boolOptions = i.boolOptions, r.intOptions = i.intOptions, r.nullOptions = i.nullOptions, r.strOptions = i.strOptions, r.Schema = t.Schema; + } +}), Vt = {}, Kt = () => Vt, Yr = (r) => { + Object.assign(Vt, r); +}, Hr = class { + constructor() { + this.data = {}; + } + /** + * Unregisters custom format(s) + * @param name + */ + unregister(r) { + r ? delete this.data[r] : this.data = {}; + } + /** + * Registers custom format + */ + register(r, i) { + this.data[r] = i; + } + /** + * Register many formats at one shot + */ + registerMany(r) { + Object.keys(r).forEach((i) => { + this.data[i] = r[i]; + }); + } + /** + * Returns element by registry key + */ + get(r) { + return this.data[r]; + } + /** + * Returns the whole registry content + */ + list() { + return this.data; + } +}, qt = Hr, Me = {}, St = Me; +Me.defaultInvalidTypeProduct = void 0; +Me.defaultRandExpMax = 10; +Me.maxRegexRetry = 100; +Me.pruneProperties = []; +Me.ignoreProperties = []; +Me.ignoreMissingRefs = !1; +Me.failOnInvalidTypes = !0; +Me.failOnInvalidFormat = !0; +Me.alwaysFakeOptionals = !1; +Me.optionalsProbability = null; +Me.fixedProbabilities = !1; +Me.useExamplesValue = !1; +Me.useDefaultValue = !1; +Me.requiredOnly = !1; +Me.omitNulls = !1; +Me.minItems = 0; +Me.maxItems = null; +Me.minLength = 0; +Me.maxLength = null; +Me.resolveJsonPath = !1; +Me.reuseProperties = !1; +Me.fillProperties = !0; +Me.sortProperties = !1; +Me.replaceEmptyByRandomValue = !1; +Me.random = Math.random; +Me.minDateTime = /* @__PURE__ */ new Date("1889-12-31T00:00:00.000Z"); +Me.maxDateTime = /* @__PURE__ */ new Date("1970-01-01T00:00:01.000Z"); +Me.renderTitle = !0; +Me.renderDescription = !0; +Me.renderComment = !1; +var Wr = class extends qt { + constructor() { + super(), this.data = { ...St }, this._defaults = St; + } + get defaults() { + return { ...this._defaults }; + } +}, Vr = Wr, tt = new Vr(); +function Gt(r, i) { + return typeof r == "string" ? typeof i < "u" ? tt.register(r, i) : tt.get(r) : tt.registerMany(r); +} +Gt.getDefaults = () => tt.defaults; +var _e = Gt, Jt = ["integer", "number", "string", "boolean"], Kr = Jt.concat(["null"]), qr = -1e8, Gr = 1e8, Jr = -100, Xr = 100, Ye = { + ALLOWED_TYPES: Jt, + SCALAR_TYPES: Kr, + MIN_NUMBER: Jr, + MAX_NUMBER: Xr, + MIN_INTEGER: qr, + MAX_INTEGER: Gr +}, ct = jt(Dr()); +function Qr(r, i) { + return r = typeof r > "u" ? Ye.MIN_INTEGER : r, i = typeof i > "u" ? Ye.MAX_INTEGER : i, Math.floor(_e("random")() * (i - r + 1)) + r; +} +function zr(r) { + return ct.default.prototype.max = _e("defaultRandExpMax"), ct.default.prototype.randInt = (t, n) => t + Math.floor(_e("random")() * (1 + (n - t))), new ct.default(r).gen(); +} +function Zr(r) { + return r[Math.floor(_e("random")() * r.length)]; +} +function en(r) { + let i, t, n = r.length; + const p = r.slice(); + for (; n > 0; ) + t = Math.floor(_e("random")() * n), n -= 1, i = p[n], p[n] = p[t], p[t] = i; + return p; +} +function Xt(r, i) { + return _e("random")() * (i - r) + r; +} +function He(r, i, t, n, p = !1) { + return t = typeof t > "u" ? Ye.MIN_NUMBER : t, n = typeof n > "u" ? Ye.MAX_NUMBER : n, r = typeof r > "u" ? t : r, i = typeof i > "u" ? n : i, i < r && (i += r), p ? Xt(r, i) : Qr(r, i); +} +function tn(r) { + switch (r) { + case "seconds": + return He(0, 60) * 60; + case "minutes": + return He(15, 50) * 612; + case "hours": + return He(12, 72) * 36123; + case "days": + return He(7, 30) * 86412345; + case "weeks": + return He(4, 52) * 604812345; + case "months": + return He(2, 13) * 2592012345; + case "years": + return He(1, 20) * 31104012345; + } +} +function rn(r) { + if (r) + return tn(r); + let i = _e("minDateTime"), t = _e("maxDateTime"); + typeof i == "string" && (i = new Date(i)), typeof t == "string" && (t = new Date(t)); + const n = (/* @__PURE__ */ new Date()).getTime(); + return typeof i == "number" && (i = new Date(n + i)), typeof t == "number" && (t = new Date(n + t)), new Date(Xt(i.getTime(), t.getTime())); +} +var xe = { + pick: Zr, + date: rn, + shuffle: en, + number: He, + randexp: zr +}, nn = /^(0|[1-9][0-9]*)$/; +function sn(r, i, t) { + if (i = decodeURIComponent(i), t && t[i]) + return nt(t[i]); + const n = i.replace("#/", "/").split("/"); + let p = r.$ref && t && t[r.$ref] || r; + for (!p && !n[0] && (n[0] = r.$ref.split("#/")[0]), t && i.includes("#/") && t[n[0]] && (p = t[n.shift()]), n[0] || n.shift(); p && n.length > 0; ) { + const s = n.shift(); + if (!p[s]) + throw new Error(`Prop not found: ${s} (${i})`); + p = p[s]; + } + return p; +} +function Tt(r) { + return typeof r == "string" && nn.test(r); +} +function on(r) { + return ["number", "boolean"].includes(typeof r); +} +function an(r, ...i) { + return i.filter((t) => typeof r[t] < "u").length > 0; +} +function Qt(r) { + if (r.includes(" ")) + return new Date(r).toISOString().substr(0, 10); + let [i, t, n] = r.split("T")[0].split("-"); + return t = `0${Math.max(1, Math.min(12, t))}`.slice(-2), n = `0${Math.max(1, Math.min(31, n))}`.slice(-2), `${i}-${t}-${n}`; +} +function un(r) { + if (r.includes(" ")) + return new Date(r).toISOString().substr(0, 10); + const [i, t] = r.split("T"); + let [n, p, s] = i.split("-"), [a, d, x] = t.substr(0, 8).split(":"); + return p = `0${Math.max(1, Math.min(12, p))}`.slice(-2), s = `0${Math.max(1, Math.min(31, s))}`.slice(-2), a = `0${Math.max(1, Math.min(23, a))}`.slice(-2), d = `0${Math.max(1, Math.min(59, d))}`.slice(-2), x = `0${Math.max(1, Math.min(59, x))}`.slice(-2), `${n}-${p}-${s}T${a}:${d}:${x}.000Z`; +} +function ln(r, i, t) { + const n = {}; + switch (r || i.type) { + case "integer": + case "number": + if (typeof i.minimum < "u" && (n.minimum = i.minimum), typeof i.maximum < "u" && (n.maximum = i.maximum), i.enum) { + let s = Math.max(n.minimum || 0, 0), a = Math.min(n.maximum || 1 / 0, 1 / 0); + i.exclusiveMinimum && s === i.minimum && (s += i.multipleOf || 1), i.exclusiveMaximum && a === i.maximum && (a -= i.multipleOf || 1), (s || a !== 1 / 0) && (i.enum = i.enum.filter((d) => d >= s && d <= a)); + } + break; + case "string": { + n.minLength = _e("minLength") || 0, n.maxLength = _e("maxLength") || Number.MAX_SAFE_INTEGER, typeof i.minLength < "u" && (n.minLength = Math.max(n.minLength, i.minLength)), typeof i.maxLength < "u" && (n.maxLength = Math.min(n.maxLength, i.maxLength)); + break; + } + } + let p = t(n); + if (p == null) + return null; + switch (r || i.type) { + case "number": + p = Tt(p) ? parseFloat(p) : p; + break; + case "integer": + p = Tt(p) ? parseInt(p, 10) : p; + break; + case "boolean": + p = !!p; + break; + case "string": { + if (on(p)) + return p; + p = String(p); + const s = Math.max(n.minLength || 0, 0), a = Math.min(n.maxLength || 1 / 0, 1 / 0); + let d, x = 0; + for (; p.length < s; ) + if (d = p, i.pattern ? p += xe.randexp(i.pattern) : p += `${xe.pick([" ", "/", "_", "-", "+", "=", "@", "^"])}${p}`, p === d) { + if (x += 1, x === 3) + break; + } else + x = 0; + if (p.length > a) { + p = p.substr(0, a); + const m = i.pattern ? new RegExp(i.pattern) : null; + if (m && !m.test(p)) { + let h = p; + const y = _e("maxRegexRetry"), E = Math.max(p.length - y, s); + for (; h.length > E && !m.test(h); ) + h = h.slice(0, -1), m.test(h) && (p = h); + } + } + switch (i.format) { + case "date-time": + case "datetime": + p = new Date(un(p)).toISOString().replace(/([0-9])0+Z$/, "$1Z"); + break; + case "full-date": + case "date": + p = new Date(Qt(p)).toISOString().substr(0, 10); + break; + case "time": + p = (/* @__PURE__ */ new Date(`1969-01-01 ${p}`)).toISOString().substr(11); + break; + } + break; + } + } + return p; +} +function Ge(r, i) { + return Object.keys(i).forEach((t) => { + typeof i[t] != "object" || i[t] === null ? r[t] = i[t] : Array.isArray(i[t]) ? (r[t] = r[t] || [], i[t].forEach((n, p) => { + r.type === "array" && i.type === "array" ? r[t][p] = Ge(r[t][p] || {}, n) : Array.isArray(r[t]) && r[t].indexOf(n) === -1 && r[t].push(n); + })) : typeof r[t] != "object" || r[t] === null || Array.isArray(r[t]) ? r[t] = Ge({}, i[t]) : r[t] = Ge(r[t], i[t]); + }), r; +} +function nt(r, i = /* @__PURE__ */ new Map()) { + if (!r || typeof r != "object") + return r; + if (i.has(r)) + return i.get(r); + if (Array.isArray(r)) { + const n = []; + return i.set(r, n), n.push(...r.map((p) => nt(p, i))), n; + } + const t = {}; + return i.set(r, t), Object.keys(r).reduce((n, p) => (n[p] = nt(r[p], i), n), t); +} +function fn(r) { + const i = JSON.stringify(r), t = JSON.stringify(r, null, 2); + return i.length > 400 ? `${t.substr(0, 400)}...` : t; +} +function zt() { + return xe.pick([ + !1, + !0, + null, + -1, + NaN, + Math.PI, + 1 / 0, + void 0, + [], + {}, + // FIXME: use built-in random? + Math.random(), + Math.random().toString(36).substr(2) + ]); +} +function cn(r, i) { + if (r.enum) + return r.enum.includes(i); + if (r.const) + return r.const === i; +} +function hn(r, i) { + const t = Ge({}, i); + if (typeof r.minimum < "u" && (t.maximum = r.minimum, t.exclusiveMaximum = !0), typeof r.maximum < "u" && (t.minimum = r.maximum > t.maximum ? 0 : r.maximum, t.exclusiveMinimum = !0), typeof r.minLength < "u" && (t.maxLength = r.minLength), typeof r.maxLength < "u" && (t.minLength = r.maxLength > t.maxLength ? 0 : r.maxLength), r.type) + t.type = xe.pick(Ye.SCALAR_TYPES.filter((n) => (Array.isArray(r.type) ? r.type : [r.type]).every((s) => n === "number" || n === "integer" ? s !== "number" && s !== "integer" : n !== s))); + else if (r.enum) { + let n; + do + n = zt(); + while (r.enum.indexOf(n) !== -1); + t.enum = [n]; + } + return r.required && t.properties && r.required.forEach((n) => { + delete t.properties[n]; + }), t; +} +function xt(r, i) { + const t = i.minimum !== void 0, n = i.maximum !== void 0; + return (t || n) && (!t || r >= i.minimum) && (!n || r <= i.maximum); +} +function pn(r, i) { + return !i.every((t) => xt(r, t)); +} +function dn(r, i) { + return i.reduce((n, p) => n + (xt(r, p) ? 1 : 0), 0) === 1; +} +function mn(r) { + return ["enum", "const", "default", "examples", "required", "definitions", "items", "properties"].includes(r); +} +function gn(r, i) { + return Object.keys(r).filter((t) => !i.includes(t)).reduce((t, n) => (Array.isArray(r[n]) ? t[n] = r[n].slice() : t[n] = r[n] instanceof Object ? Ge({}, r[n]) : r[n], t), {}); +} +function Zt(r, i) { + return Array.isArray(r) ? r.map((t) => Zt(t, i)) : (typeof r == "string" && (r = r.replace(/#\{([\w.-]+)\}/g, (t, n) => i[n])), r); +} +function mt(r) { + return Object.prototype.toString.call(r) === "[object Object]" && !Object.keys(r).length; +} +function er(r, i) { + i = i.items || i; + const t = _e("alwaysFakeOptionals"), n = Array.isArray(i.required) && i.required.includes(r) || t, p = typeof i.thunk == "function" || i.additionalProperties && typeof i.additionalProperties.thunk == "function"; + return !n && !p; +} +function gt(r, i, t = !1) { + if (!r || typeof r != "object") + return r; + if (Array.isArray(r)) + return r.map((n) => gt(n, i?.items, !0)).filter((n) => typeof n < "u"); + if (Object.keys(r).forEach((n) => { + if (mt(r[n])) + er(n, i) && delete r[n]; + else { + let p = i; + i && i.properties && i.properties[n] && (p = i.properties[n]); + const s = gt(r[n], p); + mt(s) || (r[n] = s); + } + typeof r[n] > "u" && delete r[n]; + }), !(!Object.keys(r).length && t)) + return r; +} +var ke = { + hasProperties: an, + getLocalRef: sn, + omitProps: gn, + typecast: ln, + merge: Ge, + clone: nt, + short: fn, + hasValue: cn, + notValue: hn, + anyValue: zt, + validate: pn, + validateValueForSchema: xt, + validateValueForOneOf: dn, + isKey: mn, + template: Zt, + shouldClean: er, + clean: gt, + isEmpty: mt, + clampDate: Qt +}; +function yn(r) { + return (i, t, n, p) => { + let s = i, a = []; + typeof i == "object" && (s = Object.keys(i)[0], Array.isArray(i[s]) ? a = i[s] : a.push(i[s])); + const d = s.split("."); + let x = r(); + for (; d.length > 1; ) + x = x[d.shift()]; + return i = typeof x == "object" ? x[d[0]] : x, typeof i == "function" && (i = i.apply(x, a.map((m) => ke.template(m, p)))), Object.prototype.toString.call(i) === "[object Object]" && Object.keys(i).forEach((m) => { + if (typeof i[m] == "function") + throw new Error(`Cannot resolve value for '${n}: ${s}', given: ${i}`); + }), i; + }; +} +var vn = class { + constructor() { + this.registry = {}, this.support = {}; + } + /** + * Unregister extensions + * @param name + */ + reset(r) { + r ? (delete this.registry[r], delete this.support[r]) : (this.registry = {}, this.support = {}); + } + /** + * Override dependency given by name + * @param name + * @param callback + */ + extend(r, i) { + this.registry[r] = i(this.registry[r]), this.support[r] || (this.support[r] = yn(() => this.registry[r])); + } + /** + * Set keyword support by name + * @param name + * @param callback + */ + define(r, i) { + this.support[r] = i; + } + /** + * Returns dependency given by name + * @param name + * @returns {Dependency} + */ + get(r) { + if (typeof this.registry[r] > "u") + throw new ReferenceError(`'${r}' dependency doesn't exist.`); + return this.registry[r]; + } + /** + * Apply a custom keyword + * @param schema + */ + wrap(r) { + if (!("generate" in r)) { + const i = Object.keys(r), t = {}; + let n = i.length; + for (; n--; ) { + const p = i[n].replace(/^x-/, ""), s = this.support[p]; + if (typeof s == "function") { + Object.defineProperty(r, "generate", { + configurable: !1, + enumerable: !1, + writable: !1, + value: (a, d) => s.call(t, r[i[n]], r, i[n], a, d.slice()) + // eslint-disable-line + }); + break; + } + } + } + return r; + } +}, bn = vn, Je = new qt(); +function wn(r, i) { + if (typeof r > "u") + return Je.list(); + if (typeof r == "string") + if (typeof i == "function") + Je.register(r, i); + else if (i === null || i === !1) + Je.unregister(r); + else + return Je.get(r); + else + Je.registerMany(r); +} +var tr = wn, En = class extends Error { + constructor(r, i) { + super(), Error.captureStackTrace && Error.captureStackTrace(this, this.constructor), this.name = "ParseError", this.message = r, this.path = i; + } +}, yt = En, it = { + array: [ + "additionalItems", + "items", + "maxItems", + "minItems", + "uniqueItems" + ], + integer: [ + "exclusiveMaximum", + "exclusiveMinimum", + "maximum", + "minimum", + "multipleOf" + ], + object: [ + "additionalProperties", + "dependencies", + "maxProperties", + "minProperties", + "patternProperties", + "properties", + "required" + ], + string: [ + "maxLength", + "minLength", + "pattern", + "format" + ] +}; +it.number = it.integer; +var An = [ + "additionalItems", + "items", + "additionalProperties", + "dependencies", + "patternProperties", + "properties" +]; +function xn(r, i, t) { + return Object.keys(r).filter((n) => { + const p = An.indexOf(i) > -1; + return t.indexOf(n) > -1 && !p; + }).length > 0; +} +function _n(r, i) { + const t = Object.keys(it); + for (let n = 0; n < t.length; n += 1) { + const p = t[n], s = i[i.length - 1]; + if (xn(r, s, it[p])) + return p; + } +} +var On = _n; +function Sn() { + return _e("random")() > 0.5; +} +var Tn = Sn, Cn = Tn, Rn = Cn; +function Mn() { + return null; +} +var kn = Mn, In = kn, Pn = In; +function Ln(r, i, t, n, p, s) { + const a = [], d = []; + function x(h) { + const y = JSON.stringify(h.value); + return d.indexOf(y) === -1 ? (d.push(y), a.push(h), !0) : !1; + } + i.forEach(x); + let m = 100; + for (; a.length !== i.length && (x(s(t.items || n, r, p)) || (m -= 1), !!m); ) + ; + return a; +} +function Nn(r, i, t, n) { + const p = []; + if (!(r.items || r.additionalItems)) { + if (ke.hasProperties(r, "minItems", "maxItems", "uniqueItems") && (r.minItems !== 0 || r.maxItems !== 0)) + throw new yt(`missing items for ${ke.short(r)}`, i); + return p; + } + if (Array.isArray(r.items)) + return r.items.map((g, M) => { + const R = i.concat(["items", M]); + return n(g, R, t); + }); + let s = r.minItems, a = r.maxItems; + const d = _e("minItems"), x = _e("maxItems"); + d && (s = typeof s > "u" ? d : Math.min(d, s)), x && (a = typeof a > "u" ? x : Math.min(x, a), a && a > x && (a = x), s && s > x && (s = a)); + const m = _e("alwaysFakeOptionals") === !0 ? 1 : _e("optionalsProbability"), h = _e("alwaysFakeOptionals") || _e("fixedProbabilities") || !1; + let y = xe.number(s, a, 0, 5); + m !== null && (y = Math.max(h ? Math.round((a || y) * m) : Math.abs(xe.number(s, a) * m), s || 0)); + const E = typeof r.additionalItems == "object" ? r.additionalItems : {}; + for (let g = p.length; g < y; g += 1) { + const M = i.concat(["items", g]), R = n(r.items || E, M, t); + p.push(R); + } + if (r.contains && y > 0) { + const g = xe.number(0, y - 1); + p[g] = n(r.contains, i.concat(["items", g]), t); + } + return r.uniqueItems ? Ln(i.concat(["items"]), p, r, E, t, n) : p; +} +var jn = Nn; +function $n(r) { + let i = typeof r.minimum > "u" || r.minimum === -Number.MAX_VALUE ? Ye.MIN_INTEGER : r.minimum, t = typeof r.maximum > "u" || r.maximum === Number.MAX_VALUE ? Ye.MAX_INTEGER : r.maximum; + i > t && (t = Number.MAX_SAFE_INTEGER); + const n = r.multipleOf, p = n && String(n).match(/e-(\d)|\.(\d+)$/); + if (p) { + const s = (Math.random() * xe.number(0, 10) + 1) * n, a = p[1] || p[2].length, d = parseFloat(s.toFixed(a)), x = xe.number(i, t - 1); + return String(d).includes(".") ? x + d : (x + d).toExponential(); + } + if (n && (t = Math.floor(t / n) * n, i = Math.ceil(i / n) * n), r.exclusiveMinimum && i === r.minimum && (i += n || 1), r.exclusiveMaximum && t === r.maximum && (t -= n || 1), i > t) + return NaN; + if (n) { + let s = xe.number(Math.floor(i / n), Math.floor(t / n)) * n; + for (; s < i; ) + s += n; + return s; + } + return xe.number(i, t, void 0, void 0, r.type !== "integer"); +} +var rr = $n; +function Bn(r) { + return Math.floor(rr({ ...r })); +} +var Dn = Bn, Fn = `Lorem ipsum dolor sit amet consectetur adipisicing elit sed do eiusmod tempor incididunt ut labore +et dolore magna aliqua Ut enim ad minim veniam quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea +commodo consequat Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla +pariatur Excepteur sint occaecat cupidatat non proident sunt in culpa qui officia deserunt mollit anim id est +laborum`.split(/\W/); +function Un(r) { + return xe.shuffle(Fn).slice(0, r); +} +var vt = Un, ht = { type: Ye.ALLOWED_TYPES }; +function Yn(r, i, t, n) { + const p = {}, s = r.properties || {}, a = r.patternProperties || {}, d = typeof r.required == "boolean" ? [] : (r.required || []).slice(), x = r.additionalProperties !== !1, m = Object.keys(s), h = Object.keys(a), y = m.concat(h).reduce((ee, de) => (d.indexOf(de) === -1 && ee.push(de), ee), []), E = d.concat(y), g = x && r.additionalProperties === !0 ? ht : r.additionalProperties; + if (!x && m.length === 0 && h.length === 0 && ke.hasProperties(r, "minProperties", "maxProperties", "dependencies", "required")) + return null; + if (_e("requiredOnly") === !0) + return d.forEach((ee) => { + s[ee] && (p[ee] = s[ee]); + }), n(p, i.concat(["properties"]), t, r); + const M = _e("alwaysFakeOptionals") === !0 ? 1 : _e("optionalsProbability"), R = _e("alwaysFakeOptionals") || _e("fixedProbabilities") || !1, l = _e("ignoreProperties") || [], o = _e("reuseProperties"), c = _e("fillProperties"), f = r.maxProperties || E.length + (x ? xe.number(1, 5) : 0); + let b = Math.max(r.minProperties || 0, d.length), A = Math.max(0, E.length - b); + E.length === 1 && !d.length && (b = Math.max(xe.number(c ? 1 : 0, f), b)), M !== null && (R === !0 ? A = Math.round(b - d.length + M * (E.length - b)) : A = xe.number(b - d.length, M * (E.length - b))); + const _ = xe.shuffle(y).slice(0, A), S = y.filter((ee) => _.indexOf(ee) !== -1), F = M !== null || d.length === f ? f : xe.number(0, f), D = d.concat(xe.shuffle(S).slice(0, F)).slice(0, f), H = [], j = []; + if (r.dependencies && (Object.keys(r.dependencies).forEach((ee) => { + const de = r.dependencies[ee]; + if (D.indexOf(ee) !== -1) + if (Array.isArray(de)) + de.forEach((P) => { + D.indexOf(P) === -1 && D.push(P); + }); + else if (Array.isArray(de.oneOf || de.anyOf)) { + const P = de.oneOf || de.anyOf; + j.push({ prop: ee, values: P }); + } else + H.push(de); + }), H.length)) + return delete r.dependencies, n({ + allOf: H.concat(r) + }, i.concat(["properties"]), t, r); + const Q = []; + D.forEach((ee) => { + if (s[ee] && ["{}", "true"].includes(JSON.stringify(s[ee].not))) + return; + for (let P = 0; P < l.length; P += 1) + if (l[P] instanceof RegExp && l[P].test(ee) || typeof l[P] == "string" && l[P] === ee || typeof l[P] == "function" && l[P](s[ee], ee)) { + Q.push(ee); + return; + } + g === !1 && d.indexOf(ee) !== -1 && (p[ee] = s[ee]), s[ee] && (p[ee] = s[ee]); + let de; + if (h.forEach((P) => { + ee.match(new RegExp(P)) && (de = !0, p[ee] ? ke.merge(p[ee], a[P]) : p[xe.randexp(ee)] = a[P]); + }), !de) { + const P = a[ee] || g; + P && g !== !1 && (p[a[ee] ? xe.randexp(ee) : ee] = s[ee] || P); + } + }); + let T = Object.keys(p).length + (c ? 0 : Q.length); + const G = (ee) => xe.randexp(`_?[_a-f\\d]{1,3}${ee ? "\\$?" : ""}`); + function X(ee) { + let de; + do { + if (!ee.length) + break; + de = ee.shift(); + } while (p[de]); + return de; + } + let fe = b; + if (x && !d.length && (fe = Math.max(M === null || g ? xe.number(c ? 1 : 0, f) : 0, b)), !S.length && !A && x && R === !0 && c) { + const ee = xe.number(0, f); + for (let de = 0; de < ee; de += 1) + p[vt(1) + G(ee[de])] = g || ht; + } + for (; c && !(!(h.length || x) || T >= fe); ) { + if (x) + if (o && m.length - T > fe) { + let ee = 0, de; + do { + if (ee += 1, ee > 1e3) + break; + de = X(d) || xe.pick(m); + } while (typeof p[de] < "u"); + typeof p[de] > "u" && (p[de] = s[de], T += 1); + } else if (h.length && !g) { + const ee = xe.pick(h), de = xe.randexp(ee); + p[de] || (p[de] = a[ee], T += 1); + } else { + const ee = X(d) || vt(1) + G(); + p[ee] || (p[ee] = g || ht, T += 1); + } + for (let ee = 0; T < b && ee < h.length; ee += 1) { + const de = h[ee], P = xe.randexp(de); + p[P] || (p[P] = a[de], T += 1); + } + } + if (d.length === 0 && (!x || M === !1)) { + const ee = xe.number(b, f); + for (; T < ee; ) { + const de = X(m); + de && (p[de] = s[de]), T += 1; + } + } + let te = p; + if (_e("sortProperties") !== null) { + const ee = Object.keys(s); + te = Object.keys(p).sort((P, z) => _e("sortProperties") ? P.localeCompare(z) : ee.indexOf(P) - ee.indexOf(z)).reduce((P, z) => (P[z] = p[z], P), {}); + } + const me = n(te, i.concat(["properties"]), t, r); + return j.forEach((ee) => { + for (const de of ee.values) + if (ke.hasValue(de.properties[ee.prop], me.value[ee.prop])) { + Object.keys(de.properties).forEach((P) => { + P !== ee.prop && ke.merge(me.value, n(de.properties, i.concat(["properties"]), t, r).value); + }); + break; + } + }), me; +} +var Hn = Yn; +function Ct() { + const r = xe.number(1, 5); + return vt(r).join(" "); +} +function Wn(r = 0, i = 140) { + const t = Math.max(0, r), n = xe.number(t, i); + let p = Ct(); + for (; p.length < t; ) + p += Ct(); + return p.length > n && (p = p.substr(0, n)), p; +} +var Rt = Wn; +function Vn() { + return [0, 0, 0, 0].map(() => xe.number(0, 255)).join("."); +} +var Kn = Vn; +function qn() { + return xe.date().toISOString(); +} +var _t = qn; +function Gn() { + return _t().slice(0, 10); +} +var Jn = Gn; +function Xn() { + return _t().slice(11); +} +var Qn = Xn, nr = "[a-zA-Z][a-zA-Z0-9+-.]*", pt = `https?://{hostname}(?:${nr})+`, zn = "(?:\\?([a-z]{1,7}(=\\w{1,5})?&){0,3})?", Fe = { + email: "[a-zA-Z\\d][a-zA-Z\\d-]{1,13}[a-zA-Z\\d]@{hostname}", + hostname: "[a-zA-Z]{1,33}\\.[a-z]{2,4}", + ipv6: "[a-f\\d]{4}(:[a-f\\d]{4}){7}", + uri: pt, + slug: "[a-zA-Z\\d_-]+", + // types from draft-0[67] (?) + "uri-reference": `${pt}${zn}`, + "uri-template": pt.replace("(?:", "(?:/\\{[a-z][:a-zA-Z0-9-]*\\}|"), + "json-pointer": `(/(?:${nr.replace("]*", "/]*")}|~[01]))+`, + // some types from https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.1.md#data-types (?) + uuid: "^[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$", + duration: "^P(?!$)((\\d+Y)?(\\d+M)?(\\d+D)?(T(?=\\d)(\\d+H)?(\\d+M)?(\\d+S)?)?|(\\d+W)?)$" +}; +Fe.iri = Fe["uri-reference"]; +Fe["iri-reference"] = Fe["uri-reference"]; +Fe["idn-email"] = Fe.email; +Fe["idn-hostname"] = Fe.hostname; +var Zn = new RegExp(`\\{(${Object.keys(Fe).join("|")})\\}`); +function ei(r) { + return xe.randexp(Fe[r]).replace(Zn, (i, t) => xe.randexp(Fe[t])); +} +var ti = ei; +function ri(r, i) { + const t = tr(r.format); + if (typeof t == "function") + return t(r); + switch (r.format) { + case "date-time": + case "datetime": + return _t(); + case "date": + return Jn(); + case "time": + return Qn(); + case "ipv4": + return Kn(); + case "regex": + return ".+?"; + case "email": + case "hostname": + case "ipv6": + case "uri": + case "uri-reference": + case "iri": + case "iri-reference": + case "idn-email": + case "idn-hostname": + case "json-pointer": + case "slug": + case "uri-template": + case "uuid": + case "duration": + return ti(r.format); + default: + if (typeof t > "u") { + if (_e("failOnInvalidFormat")) + throw new Error(`unknown registry key ${ke.short(r.format)}`); + return i(); + } + throw new Error(`unsupported format '${r.format}'`); + } +} +function ni(r) { + return ke.typecast("string", r, (t) => r.format ? ri(r, () => Rt(t.minLength, t.maxLength)) : r.pattern ? xe.randexp(r.pattern) : Rt(t.minLength, t.maxLength)); +} +var ii = ni, si = { + boolean: Rn, + null: Pn, + array: jn, + integer: Dn, + number: rr, + object: Hn, + string: ii +}, et = si; +function oi({ $comment: r, title: i, description: t }) { + return Object.entries({ comment: r, title: i, description: t }).filter(([, n]) => n).reduce((n, [p, s]) => (n[p] = s, n), {}); +} +function qe(r, i, t, n) { + if (r = t(r, null, i), r && (r.oneOf || r.anyOf || r.allOf) && (r = t(r, null, i)), !r) + throw new Error(`Cannot traverse at '${i.join(".")}', given '${JSON.stringify(n)}'`); + const p = { + ...oi(r), + schemaPath: i + }; + if (i[i.length - 1] !== "properties") { + if (_e("useExamplesValue") && Array.isArray(r.examples)) { + const m = r.examples.concat("default" in r ? [r.default] : []); + return { value: ke.typecast(null, r, () => xe.pick(m)), context: p }; + } + if (_e("useExamplesValue") && typeof r.example < "u") + return { value: ke.typecast(null, r, () => r.example), context: p }; + if (_e("useDefaultValue") && "default" in r && (r.default !== "" || !_e("replaceEmptyByRandomValue"))) + return { value: r.default, context: p }; + if ("template" in r) + return { value: ke.template(r.template, n), context: p }; + if ("const" in r) + return { value: r.const, context: p }; + } + if (r.not && typeof r.not == "object" && (r = ke.notValue(r.not, ke.omitProps(r, ["not"])), r.type && r.type === "object")) { + const { value: m, context: h } = qe(r, i.concat(["not"]), t, n); + return { value: ke.clean(m, r, !1), context: { ...p, items: h } }; + } + if (typeof r.thunk == "function") { + const { value: m, context: h } = qe(r.thunk(n), i, t); + return { value: m, context: { ...p, items: h } }; + } + if (r.jsonPath) + return { value: r, context: p }; + let s = r.type; + if (Array.isArray(s) ? s = xe.pick(s) : typeof s > "u" && (s = On(r, i) || s, s && (r.type = s)), typeof r.generate == "function") { + const m = ke.typecast(null, r, () => r.generate(n, i)), h = m === null ? "null" : typeof m; + if (h === s || h === "number" && s === "integer" || Array.isArray(m) && s === "array") + return { value: m, context: p }; + } + if (typeof r.pattern == "string") + return { value: ke.typecast("string", r, () => xe.randexp(r.pattern)), context: p }; + if (Array.isArray(r.enum)) + return { value: ke.typecast(null, r, () => xe.pick(r.enum)), context: p }; + if (typeof s == "string") + if (et[s]) + try { + const m = et[s](r, i, t, qe); + return s === "array" ? { + value: m.map(({ value: h }) => h), + context: { + ...p, + items: m.map( + Array.isArray(r.items) ? ({ context: h }) => h : ({ context: h }) => ({ + ...h, + // we have to remove the index from the path to get the real schema path + schemaPath: h.schemaPath.slice(0, -1) + }) + ) + } + } : s === "object" ? m !== null ? { value: m.value, context: { ...p, items: m.context } } : { value: {}, context: p } : { value: m, context: p }; + } catch (m) { + throw typeof m.path > "u" ? new yt(m.stack, i) : m; + } + else { + if (_e("failOnInvalidTypes")) + throw new yt(`unknown primitive ${ke.short(s)}`, i.concat(["type"])); + { + const m = _e("defaultInvalidTypeProduct"); + return typeof m == "string" && et[m] ? { value: et[m](r, i, t, qe), context: p } : { value: m, context: p }; + } + } + let a = {}, d = { ...p }; + Array.isArray(r) && (a = []); + const x = _e("pruneProperties") || []; + return Object.keys(r).forEach((m) => { + if (!x.includes(m) && r[m] !== null) + if (typeof r[m] == "object" && m !== "definitions") { + const { value: h, context: y } = qe(r[m], i.concat([m]), t, a); + a[m] = ke.clean(h, r[m], !1), d[m] = y, a[m] === null && _e("omitNulls") && (delete a[m], delete d[m]); + } else + a[m] = r[m]; + }), { value: a, context: d }; +} +var ai = qe, ui = ({ + refs: r, + schema: i, + container: t, + synchronous: n, + refDepthMax: p, + refDepthMin: s +}) => { + const a = {}, d = {}; + let x = 0, m, h; + return a.resolveSchema = (y, E, g) => { + if (y == null) + return null; + if (typeof y.generate == "function") + return y; + if (typeof (y.$id || y.id) == "string" && (delete y.id, delete y.$id, delete y.$schema), typeof y.$ref == "string") { + const R = Math.max(s, p) - 1; + if (y.$ref === "#" || d[y.$ref] < 0 || m === y.$ref && ++x > R) + return y.$ref !== "#" && h && h.length === g.length ? ke.getLocalRef(i, y.$ref, n && r) : (delete y.$ref, y); + typeof d[y.$ref] > "u" && (d[y.$ref] = xe.number(s, p) - 1), h = g, m = y.$ref; + let l; + y.$ref.indexOf("#/") === -1 ? l = r[y.$ref] || null : l = ke.getLocalRef(i, y.$ref, n && r) || null; + let o; + if (typeof l < "u") { + if (!l && _e("ignoreMissingRefs") !== !0) + throw new Error(`Reference not found: ${y.$ref}`); + d[y.$ref] -= 1, ke.merge(y, l || {}), o = n && l && l.$ref; + } + return o || delete y.$ref, y; + } + if (Array.isArray(y.allOf)) { + const R = y.allOf; + delete y.allOf, R.forEach((l) => { + const o = a.resolveSchema(l, null, g); + ke.merge(y, typeof o.thunk == "function" ? o.thunk(y) : o), Array.isArray(y.allOf) && a.resolveSchema(y, E, g); + }); + } + if (Array.isArray(y.oneOf || y.anyOf) && g[g.length - 2] !== "dependencies") { + const R = y.oneOf || y.anyOf; + return y.enum && y.oneOf && (y.enum = y.enum.filter((l) => ke.validate(l, R))), { + thunk(l) { + const o = ke.omitProps(y, ["anyOf", "oneOf"]), c = xe.pick(R); + return ke.merge(o, c), R.forEach((f) => { + f.required && f !== c && f.required.forEach((b) => { + if (c.required && c.required.includes(b)) + return; + const A = o.required && o.required.includes(b); + o.properties && !A && delete o.properties[b], l && l.properties && delete l.properties[b]; + }); + }), o; + } + }; + } + if (Object.keys(y).forEach((R) => { + (Array.isArray(y[R]) || typeof y[R] == "object") && !ke.isKey(R) && (y[R] = a.resolveSchema(y[R], R, g.concat(R))); + }), g) { + const R = g[g.length - 1]; + if (R === "properties" || R === "items") + return y; + } + return t.wrap(y); + }, a; +}, li = ui; +function fi(r) { + return Array.isArray(r) ? xe.pick(r) : r; +} +function ci(r, i) { + if (!Array.isArray(r)) + return r; + const t = i ? r.pop() : r.shift(); + return i ? r.unshift(t) : r.push(t), t; +} +function bt(r, i, t, n) { + if (!r || typeof r != "object") + return r; + if (t || (t = {}), i || (i = r), Array.isArray(r)) + return r.map((p) => bt(p, i, t, n)); + if (r.jsonPath) { + const { JSONPath: p } = Kt(), s = typeof r.jsonPath != "object" ? { path: r.jsonPath } : r.jsonPath; + s.group = r.group || s.group || n, s.cycle = r.cycle || s.cycle || !1, s.reverse = r.reverse || s.reverse || !1, s.count = r.count || s.count || 1; + const a = `${s.group}__${s.path}`; + return t[a] || (s.count > 1 ? t[a] = p(s.path, i).slice(0, s.count) : t[a] = p(s.path, i)), s.cycle || s.reverse ? ci(t[a], s.reverse) : fi(t[a]); + } + return Object.keys(r).forEach((p) => { + r[p] = bt(r[p], i, t, p); + }), r; +} +function hi(r, i, t, n) { + if (Object.prototype.toString.call(i) !== "[object Object]") + throw new Error(`Invalid input, expecting object but given ${typeof i}`); + const p = _e("refDepthMin") || 0, s = _e("refDepthMax") || 3; + try { + const { resolveSchema: a } = li({ + refs: r, + schema: i, + container: t, + synchronous: n, + refDepthMin: p, + refDepthMax: s + }), d = ai(ke.clone(i), [], a); + return _e("resolveJsonPath") ? { + value: bt(d.value), + context: d.context + } : d; + } catch (a) { + throw a.path ? new Error(`${a.message} in /${a.path.join("/")}`) : a; + } +} +var ir = hi; +function pi(r) { + return r.value; +} +var sr = pi, Be = jt(Ur()); +Be.default.binaryOptions; +Be.default.boolOptions; +Be.default.intOptions; +Be.default.nullOptions; +Be.default.strOptions; +Be.default.Schema; +Be.default.Alias; +Be.default.Collection; +Be.default.Merge; +Be.default.Node; +Be.default.Pair; +Be.default.Scalar; +var di = Be.default.YAMLMap, mi = Be.default.YAMLSeq; +function gi(r, i) { + return i.reduce((t, n) => n in t ? t[n] : {}, r); +} +function wt(r, i, t, n = t) { + const { title: p, description: s, comment: a } = gi(r, i), d = []; + _e("renderTitle") && p && d.push(` ${p}`, ""), _e("renderDescription") && s && d.push(` ${s}`), _e("renderComment") && a && d.push(` ${a}`), t.commentBefore = d.join(` +`), n instanceof di ? n.items.forEach((x) => { + wt(r, [...i, "items", x.key.value], x.key, x.value); + }) : n instanceof mi && n.items.forEach((x, m) => { + wt(r, [...i, "items", m], x); + }); +} +function yi({ value: r, context: i }) { + const t = st.createNode(r); + wt(i, [], t); + const n = new st.Document(); + return n.contents = t, n.toString(); +} +var st = yi, We = new bn(); +function or() { + We.define("autoIncrement", function(i, t) { + if (!this.offset) { + const n = t.minimum || 1, p = n + Ye.MAX_NUMBER, s = i.initialOffset || t.initialOffset; + this.offset = s || xe.number(n, p); + } + return i ? this.offset++ : t; + }), We.define("sequentialDate", function(i, t) { + if (this.now || (this.now = xe.date()), i) { + if (t = this.now.toISOString(), i = i === !0 ? "days" : i, ["seconds", "minutes", "hours", "days", "weeks", "months", "years"].indexOf(i) === -1) + throw new Error(`Unsupported increment by ${ke.short(i)}`); + this.now.setTime(this.now.getTime() + xe.date(i)); + } + return t; + }); +} +function ar(r, i) { + let t = {}; + Array.isArray(r) ? r.forEach((p) => { + t[p.$id || p.id] = p; + }) : t = r || {}; + function n(p) { + if (!p || typeof p != "object") + return; + if (Array.isArray(p)) + return p.forEach(n); + const s = p.$id || p.id; + typeof s == "string" && !t[s] && (t[s] = p), Object.keys(p).forEach((a) => { + n(p[a]); + }); + } + return n(r), n(i), t; +} +var Le = (r, i, t) => (console.debug("[json-schema-faker] calling JSONSchemaFaker() is deprecated, call either .generate() or .resolve()"), t && console.debug("[json-schema-faker] local references are only supported by calling .resolve()"), Le.generate(r, i)); +Le.generateWithContext = (r, i) => { + const t = ar(i, r); + return ir(t, r, We, !0); +}; +Le.generate = (r, i) => sr( + Le.generateWithContext(r, i) +); +Le.generateYAML = (r, i) => st( + Le.generateWithContext(r, i) +); +Le.resolveWithContext = (r, i, t) => { + typeof i == "string" && (t = i, i = {}), t = t || (typeof process < "u" && typeof process.cwd == "function" ? process.cwd() : ""), t = `${t.replace(/\/+$/, "")}/`; + const n = ar(i, r), p = { + order: 1, + canRead(a) { + const d = a.url.replace("/:", ":"); + return n[d] || n[d.split("/").pop()]; + }, + read(a, d) { + try { + d(null, this.canRead(a)); + } catch (x) { + d(x); + } + } + }, { $RefParser: s } = Kt(); + return s.bundle(t, r, { + resolve: { + file: { order: 100 }, + http: { order: 200 }, + fixedRefs: p + }, + dereference: { + circular: "ignore" + } + }).then((a) => ir(n, a, We)).catch((a) => { + throw new Error(`Error while resolving schema (${a.message})`); + }); +}; +Le.resolve = (r, i, t) => Le.resolveWithContext(r, i, t).then(sr); +Le.resolveYAML = (r, i, t) => Le.resolveWithContext(r, i, t).then(st); +or(); +Le.format = tr; +Le.option = _e; +Le.random = xe; +Le.extend = (r, i) => (We.extend(r, i), Le); +Le.define = (r, i) => (We.define(r, i), Le); +Le.reset = (r) => (We.reset(r), or(), Le); +Le.locate = (r) => We.get(r); +Le.VERSION = "0.5.8"; +({ ...Le }); +var Ie = Le; +typeof $RefParser < "u" && typeof JSONPath < "u" && Yr({ ...JSONPath, $RefParser }); +function vi(r, i, t, n) { + const p = wi(Ne(r, i?.requestBody), t); + return p ? bi(r, p[0], p[1], n) : { mediaType: "text/plain", value: "" }; +} +function bi(r, i, t, n) { + if (n !== void 0) + return { mediaType: i, value: n }; + if (t?.example) + return { + mediaType: i, + value: t.example + }; + if (t?.examples && Object.values(t.examples).length > 0) { + const p = Object.values(t.examples)[0]; + return { + mediaType: i, + value: Ne(r, p)?.value ?? {} + }; + } + if (ft.includes(i) && t?.schema) { + const p = Ne(r, t.schema); + if (p) { + Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); + try { + return { + mediaType: i, + value: Ie.generate({ ...p, components: r.components }) + }; + } catch { + return { mediaType: i, value: {} }; + } + } + } + return { + mediaType: i, + value: "" + }; +} +function Zi(r) { + return ft.includes(r.mediaType) ? JSON.stringify(r.value, null, 2) : r.value.toString(); +} +function es(r, i) { + if (ft.includes(r)) + try { + return JSON.parse(i); + } catch (t) { + return new Error(`failed to convert: ${t}`); + } + return i; +} +function wi(r, i) { + if (!r || !r.content) + return; + const t = [...ft]; + i && t.unshift(i); + for (const p of t) + if (r.content[p]) + return [p, r.content[p]]; + const n = Object.keys(r.content)[0]; + return [n, r.content[n]]; +} +const ft = [ + "application/json", + "application/x-www-form-urlencoded", + "multipart/form-data" +]; +function ts(r, i, t, n, p) { + const s = ot(r, i, t), a = ur(r, i, t), d = lr(r, a), x = Er(r, i, t), m = Ei(x), h = vi(r, s, n, p); + return { + server: It(r)?.[0] || "", + parameters: d, + security: m, + securityIndex: 0, + body: h + }; +} +function ur(r, i, t) { + const n = r.paths ? vr(r, r.paths[i]) : [], p = ot(r, i, t), s = br(r, p); + return wr(r, n, s); +} +function rs(r, i, t) { + return (ot(r, i, t)?.security ?? r.security ?? []).length > 0; +} +function lr(r, i) { + const t = { + query: {}, + header: {}, + path: {}, + cookie: {} + }, n = Object.keys(i); + for (const p of n) + for (const s of Object.keys(i[p])) { + const a = i[p][s]; + if (a?.example !== void 0) + t[p][s] = a.example; + else if (a?.examples && Object.values(a.examples).length > 0) { + const d = Object.values(a.examples)[0], x = Ne(r, d)?.value; + t[p][s] = x === void 0 ? "" : x; + } else if (a.schema) { + Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); + try { + t[p][s] = Ie.generate({ + ...a.schema, + components: r.components + }); + } catch { + t[p][s] = ""; + } + } else + t[p][s] = ""; + } + return t; +} +function Ei(r) { + const i = []; + for (const t of r) { + const n = {}; + for (const [p, s] of Object.entries(t)) + s && (n[p] = Ai(s)); + i.push(n); + } + return i; +} +function Ai(r) { + return r?.type === "http" && /^basic$/i.test(r?.scheme) ? { username: "", password: "" } : ""; +} +function ns(r) { + const i = { + query: {}, + header: {}, + path: {}, + cookie: {} + }, t = Object.keys(r.parameters); + for (const p of t) + for (const s of Object.keys(r.parameters[p] ?? {})) { + const a = Mt(s), d = r.parameters[p][s]; + i[p][a] = Array.isArray(d) ? Oi(d) : d; + } + const n = []; + for (const p of r.security) { + const s = {}; + for (const [a, d] of Object.entries(p)) + s[Mt(a)] = d; + n.push(s); + } + return { + parameters: i, + body: r.body, + server: r.server, + security: n, + securityIndex: r.securityIndex + }; +} +function is(r) { + return { + parameters: _i(r.parameters), + body: r.body, + server: r.server, + security: xi(r.security), + securityIndex: r.securityIndex + }; +} +function xi(r) { + const i = []; + for (const t of r) { + const n = {}; + for (const [p, s] of Object.entries(t)) + n[fr(p)] = s; + i.push(n); + } + return i; +} +function _i(r) { + const i = { + query: {}, + header: {}, + path: {}, + cookie: {} + }, t = Object.keys(r); + for (const n of t) + for (const p of Object.keys(r[n])) { + const s = fr(p), a = r[n][p]; + i[n][s] = Array.isArray(a) ? Si(a) : a; + } + return i; +} +function ss(r) { + try { + const i = new URL(r), t = i.protocol === "https:", n = i.hostname.toLowerCase(); + return [t, n]; + } catch { + return [!1, ""]; + } +} +function Oi(r) { + return r.map((i) => ({ value: i })); +} +function Si(r) { + return r.map((i) => i.value); +} +function Mt(r) { + return "n-" + encodeURIComponent(r).replace(/\./g, "%2E"); +} +function fr(r) { + return decodeURIComponent(r.substring(2, r.length)); +} +function Ti(r, i, t, n, p) { + const s = Ri(r, i, n); + if (s !== void 0 && p !== void 0) + return { mediaType: s, value: p }; + if (s !== void 0 && Mi.includes(s)) + return Ci(r, i, t, s); +} +function Ci(r, i, t, n) { + if (ki.includes(n)) + return { mediaType: n, value: {} }; + if (n == "application/json") { + const p = Object.values(t.body)?.[0], s = Ne(r, p?.schema); + if (s) { + Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); + try { + return { + mediaType: n, + value: Ie.generate({ ...s, definitions: r.definitions }) + }; + } catch { + return { mediaType: n, value: {} }; + } + } + return { mediaType: n, value: {} }; + } + return { + mediaType: n, + value: "" + }; +} +function Ri(r, i, t) { + const n = Or(r, i); + if (t !== void 0 && n.includes(t)) + return t; + if (n.length > 0) + return n[0]; +} +const Mi = [ + "application/json", + "application/x-www-form-urlencoded", + "multipart/form-data" +], ki = ["application/x-www-form-urlencoded", "multipart/form-data"]; +function os(r, i, t, n, p) { + const s = at(r, i, t), a = cr(r, i, t), d = hr(r, a), x = Ii(r, i, t), m = Pi(x), h = Pt(r), y = Ti( + r, + s, + a, + n, + p + ); + return { + server: h?.[0] || "", + parameters: d, + security: m, + securityIndex: 0, + body: y + }; +} +function cr(r, i, t) { + const n = Ar(r, r.paths[i]), p = at(r, i, t), s = xr(r, p); + return _r(r, n, s); +} +function hr(r, i) { + const t = { + query: {}, + header: {}, + path: {}, + cookie: {} + }, n = Object.keys(i); + for (const p of n) + if (!(p === "body" || p === "formData")) + for (const s of Object.keys(i[p])) { + const a = i[p][s]; + if (a.type) { + Ie.option("useExamplesValue", !0), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0); + try { + t[p][s] = Ie.generate({ + ...a, + definitions: r.definitions + }); + } catch { + t[p][s] = ""; + } + } else + t[p][s] = ""; + } + return t; +} +function as(r, i, t) { + return (at(r, i, t)?.security ?? r.security ?? []).length > 0; +} +function Ii(r, i, t) { + const p = at(r, i, t)?.security ?? r.security ?? [], s = []; + for (const a of p) { + const d = {}; + for (const x of Object.keys(a)) + r?.securityDefinitions?.[x] && (d[x] = r?.securityDefinitions?.[x]); + s.push(d); + } + return s; +} +function Pi(r) { + const i = []; + for (const t of r) { + const n = {}; + for (const [p, s] of Object.entries(t)) + s && (n[p] = Li(s)); + i.push(n); + } + return i; +} +function Li(r) { + return r?.type === "basic" ? { username: "", password: "" } : ""; +} +function Ni(r, i) { + for (let t = r.length - 1; t >= 0; t--) { + const { id: n, env: p } = r[t]; + if (p.hasOwnProperty(i)) + return { context: n, value: p[i], name: i }; + } +} +const ji = [ + "$randomString", + "$randomuint", + "$uuid", + "$timestamp", + "$timestamp3339", + "$randomFromSchema" +], $i = { + $randomString: () => Di(20), + $randomuint: () => Yi(), + $uuid: () => crypto.randomUUID(), + $timestamp: () => Fi(), + $timestamp3339: () => Ui(), + $randomFromSchema: Bi +}; +function Bi(r, i, t) { + const n = t(); + if (i.path[0] == "body" && i.path[1] === "value") + return rt.findByPath(n.body, i.path.slice(2)); + if (i.path[0] === "parameters") { + const p = rt.findByPath(r, [...i.path.slice(0, -1), "key"]); + return n.parameters[i.path[1]][p]; + } +} +function Di(r) { + const i = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789", t = new Uint32Array(r); + crypto.getRandomValues(t); + let n = ""; + for (let p = 0; p < r; p++) + n += i.charAt(t[p] % i.length); + return n; +} +function Fi() { + return Math.floor((/* @__PURE__ */ new Date()).getTime() / 1e3); +} +function Ui() { + return (/* @__PURE__ */ new Date()).toISOString(); +} +function Yi() { + const r = new Uint32Array(1); + return crypto.getRandomValues(r), r[0]; +} +const us = () => /^([\w\-]+)$/g, ls = "Only the alphanumeric characters, minus or underscore", Hi = () => /{{([\w\-$]+)}}/g, Wi = () => /^{{([\w\-$]+)}}$/; +function fs(r, i, t) { + return pr(r, i, t, () => ({ + body: void 0, + parameters: void 0 + })); +} +function cs(r, i, t, n) { + let p; + return pr("request", i, n, () => (p === void 0 && (p = qi(r, t, i.path, i.method)), p)); +} +function hs(r, i) { + return dr(r, i, {}, { type: "credential", path: [] }, () => ({ + body: void 0, + parameters: void 0 + })); +} +function pr(r, i, t, n) { + const p = [], s = [], a = rt.simpleClone(i, (d, x) => { + if (typeof d == "string") { + const m = Vi( + d, + t, + i, + { type: r, path: x }, + n + ); + return p.push(...m.missing), s.push(...m.found), m.value; + } else + return d; + }); + return { + missing: p, + found: s, + value: a + }; +} +function Vi(r, i, t, n, p) { + const s = r.match(Wi()); + if (s && s.length === 2) { + const a = s[1]; + return Ki(a, r, i, t, n, p); + } else + return dr(r, i, t, n, p); +} +function Ki(r, i, t, n, p, s) { + const a = mr(t, r, n, p, s); + return a !== void 0 ? { found: [{ ...a, offset: 0, location: p }], missing: [], value: a.value } : { found: [], missing: [{ name: r, location: p }], value: i }; +} +function dr(r, i, t, n, p) { + const s = [], a = [], d = r.replace( + Hi(), + (x, m, h) => { + const y = mr(i, m, t, n, p); + return y !== void 0 ? (a.push({ ...y, offset: h, location: n }), `${y.value}`) : (s.push({ name: m, location: n }), x); + } + ); + return { + found: a, + missing: s, + value: d + }; +} +function mr(r, i, t, n, p) { + if (ji.includes(i)) { + const s = $i[i](t, n, p); + return { context: { type: "built-in" }, value: s, name: i }; + } else + return Ni(r, i); +} +function qi(r, i, t, n) { + const p = { body: void 0, parameters: void 0 }; + if (i === void 0) + return p; + if (Et(r)) { + const s = Ne( + r, + i.requestBody + ), a = Ne(r, s?.content["application/json"]?.schema); + a && (p.body = kt({ ...a, components: r.components })); + const d = ur(r, t, n); + p.parameters = lr(r, d); + } else { + const s = cr(r, t, n); + if (s.body) { + const a = Object.values(s.body)?.[0], d = Ne(r, a?.schema); + d && (p.body = kt({ ...d, definitions: r.definitions })); + } + p.parameters = hr(r, s); + } + return p; +} +function kt(r) { + try { + return Ie.option("useExamplesValue", !1), Ie.option("failOnInvalidFormat", !1), Ie.option("maxLength", 4096), Ie.option("alwaysFakeOptionals", !0), Ie.generate(r); + } catch { + return; + } +} +function ps(r) { + return r.map((i) => i.name).join(", "); +} +export { + at as A, + xr as B, + _r as C, + ji as D, + Hi as E, + hs as F, + fs as G, + Xi as H, + cs as I, + ps as J, + os as a, + bi as b, + ts as c, + Ne as d, + Mt as e, + ot as f, + ur as g, + rs as h, + Et as i, + Er as j, + cr as k, + as as l, + Ii as m, + ss as n, + Qi as o, + es as p, + ls as q, + us as r, + Zi as s, + Tr as t, + is as u, + Cr as v, + ns as w, + zi as x, + Sr as y, + Ar as z +}; diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/graphql/GraphQlService.java b/openapi-plugin/src/main/java/com/xliic/openapi/graphql/GraphQlService.java index a60d8d31..6d5c2d4b 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/graphql/GraphQlService.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/graphql/GraphQlService.java @@ -20,7 +20,6 @@ import com.xliic.core.vfs.VirtualFile; import com.xliic.openapi.cli.CliService; import com.xliic.openapi.graphql.task.GraphQlCliTask; -import com.xliic.openapi.graphql.task.PlatformGraphQlAuditTask; import com.xliic.openapi.inlined.AnnotationService; import com.xliic.openapi.parser.ast.node.Node; import com.xliic.openapi.services.AuditService; diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/PlatformAPIs.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/PlatformAPIs.java index 9772e73c..ce1d2b68 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/PlatformAPIs.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/PlatformAPIs.java @@ -12,6 +12,7 @@ import org.jetbrains.annotations.NotNull; import com.xliic.openapi.platform.callback.EnqueueCallback; +import com.xliic.openapi.platform.tree.PlatformFavoriteCollectionsHandler; import com.xliic.openapi.utils.Utils; import okhttp3.Request; @@ -97,9 +98,28 @@ public static Response getCategories() throws IOException { } } - public static void listCollections(@NotNull EnqueueCallback callback) { + public static void readCollections(@NotNull PlatformFavoriteCollectionsHandler handler, @NotNull Set collectionIds) { + for (String collectionId : collectionIds) { + readCollection(handler.getEnqueueCallback(collectionId), collectionId); + } + } + + private static void readCollection(@NotNull EnqueueCallback callback, @NotNull String collectionId) { + try { + Request request = getRequestBuilder(String.format("api/v1/collections/%s?readOwner=true", collectionId)).build(); + getHttpClient().newCall(request).enqueue(callback); + } catch (IOException e) { + callback.onFailure(e.toString()); + } + } + + public static void listCollections(@NotNull EnqueueCallback callback, int page, int perPage, @NotNull String name) { try { - Request request = getRequestBuilder(String.format("api/v2/collections?listOption=%s&perPage=%d", "ALL", 0)).build(); + String url = String.format("api/v1/search/collections?page=%d&perPage=%d&order=default&sort=default", page, perPage); + if (!name.isBlank()) { + url += String.format("&collectionName=%s", name); + } + Request request = getRequestBuilder(url).build(); getHttpClient().newCall(request).enqueue(callback); } catch (IOException e) { callback.onFailure(e.toString()); diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/callback/PlatformCollectionCallback.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/callback/PlatformCollectionCallback.java index df46d334..f58f8ba3 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/callback/PlatformCollectionCallback.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/callback/PlatformCollectionCallback.java @@ -15,6 +15,8 @@ import com.xliic.openapi.platform.tree.node.PlatformCollection; import com.xliic.openapi.platform.tree.utils.PlatformCollectionUtils; +import static com.xliic.openapi.platform.tree.utils.PlatformCollectionUtils.getApiCount; + public class PlatformCollectionCallback extends SuccessASTResponseWithFailureDecoratorCallback { public PlatformCollectionCallback(@NotNull Project project, @NotNull Tree tree, @NotNull DefaultMutableTreeNode parentDMTN) { @@ -34,19 +36,22 @@ public static List getCollections(@NotNull Node node) { for (Node item : list.getChildren()) { String id, name, technicalName; Node desc = item.getChild("desc"); + int apiCount; if (desc == null) { id = item.getChildValueRequireNonNull("id"); name = item.getChildValueRequireNonNull("name"); technicalName = item.getChildValueRequireNonNull("technicalName"); + apiCount = getApiCount(item); } else { id = desc.getChildValueRequireNonNull("id"); name = desc.getChildValueRequireNonNull("name"); technicalName = desc.getChildValueRequireNonNull("technicalName"); + apiCount = getApiCount(item); } Node summary = item.getChild("summary"); Permissions permissions = Permissions.get(summary == null ? item : summary); boolean locked = !permissions.isWriteApis(); - collections.add(new PlatformCollection(id, name, locked, technicalName, permissions)); + collections.add(new PlatformCollection(id, name, locked, technicalName, permissions, apiCount)); } } return collections; diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformAsyncTreeModel.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformAsyncTreeModel.java index 654e80e7..1cd00d7e 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformAsyncTreeModel.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformAsyncTreeModel.java @@ -1,6 +1,7 @@ package com.xliic.openapi.platform.tree; import java.util.Map; +import java.util.*; import javax.swing.tree.DefaultMutableTreeNode; @@ -17,6 +18,7 @@ import com.xliic.openapi.platform.tree.node.PlatformDataDictionary; import com.xliic.openapi.platform.tree.node.PlatformRootCloud; import com.xliic.openapi.platform.tree.node.PlatformRootFavorite; +import com.xliic.openapi.platform.tree.node.core.Paginator; import com.xliic.openapi.platform.tree.node.decorator.PlatformLoadingDecorator; import com.xliic.openapi.platform.tree.utils.PlatformUtils; import com.xliic.openapi.services.PlatformService; @@ -35,6 +37,9 @@ public class PlatformAsyncTreeModel extends DefaultTreeModel { private final DefaultMutableTreeNode favoriteCollections; private final DefaultMutableTreeNode dataDictionary; + private final PlatformRootCloud cachedRoot = new PlatformRootCloud(); + private final List cachedNodes = new LinkedList<>(); + public PlatformAsyncTreeModel(@NotNull Project project, @NotNull Tree tree, @NotNull DefaultMutableTreeNode root) { super(tree.getViewer(), root, false); this.project = project; @@ -66,6 +71,30 @@ public Object getChild(Object parent, int index) { return PlatformUtils.getVisibleChildren(parent).get(index); } + public void cacheCollections() { + cachedRoot.setFrom((PlatformRootCloud) cloudCollections.getUserObject()); + cachedNodes.clear(); + for (int i = 0; i < cloudCollections.getChildCount(); i++) { + cachedNodes.add((DefaultMutableTreeNode) cloudCollections.getChildAt(i)); + } + } + + public void restoreCollections() { + ((PlatformRootCloud) cloudCollections.getUserObject()).setFrom(cachedRoot); + cloudCollections.removeAllChildren(); + for (DefaultMutableTreeNode node : cachedNodes) { + cloudCollections.add(node); + } + cachedNodes.clear(); + } + + public void clearCachedCollections() { + cachedRoot.resetPage(); + cachedRoot.resetFilter(); + cachedRoot.setChildrenUnavailable(true); + cachedNodes.clear(); + } + @Override public int getChildCount(Object parent) { DefaultMutableTreeNode parentDMTN = (DefaultMutableTreeNode) parent; @@ -75,27 +104,40 @@ public int getChildCount(Object parent) { PlatformService platformService = PlatformService.getInstance(project); Map callbacks = platformService.getTreeAsyncCallbacks(); if (rco.isChildrenUnavailable() && !callbacks.containsKey(parentDMTN)) { - EnqueueCallback callback = new PlatformCollectionCallback(project, tree, parentDMTN); - PlatformAPIs.listCollections(callback); + EnqueueCallback callback = new PlatformCollectionCallback(project, tree, parentDMTN); callbacks.put(parentDMTN, callback); - parentDMTN.removeAllChildren(); + PlatformAPIs.listCollections(callback, rco.getPage(), Paginator.PAGE_SIZE, rco.getFilter()); parentDMTN.add(LOADING_DECORATOR); - return 1; + // If filter is active there is one more filter node which is not in the parent, but returned by this model + return parentDMTN.getChildCount() + (rco.isFilterActive() ? 1 : 0); } } else if (parentObj instanceof PlatformRootFavorite) { - PlatformRootCloud rco = (PlatformRootCloud) (cloudCollections.getUserObject()); - if (rco.isChildrenUnavailable()) { - parentDMTN.removeAllChildren(); + PlatformRootFavorite rfo = (PlatformRootFavorite) parentObj; + PlatformService platformService = PlatformService.getInstance(project); + Set collectionIds = new HashSet<>(platformService.getState().collectionIds); + if (collectionIds.isEmpty()) { + rfo.setChildrenUnavailable(false); return 0; } + Map callbacks = platformService.getTreeAsyncCallbacks(); + if (rfo.isChildrenUnavailable() && !callbacks.containsKey(parentDMTN)) { + PlatformFavoriteCollectionsHandler handler = new PlatformFavoriteCollectionsHandler(project, tree, parentDMTN, collectionIds); + callbacks.put(parentDMTN, handler); + PlatformAPIs.readCollections(handler, collectionIds); + parentDMTN.add(LOADING_DECORATOR); + return parentDMTN.getChildCount(); + } } else if (parentObj instanceof PlatformCollection) { PlatformCollection pco = (PlatformCollection) parentObj; + if (pco.getApiCount() == 0) { + return 0; + } PlatformService platformService = PlatformService.getInstance(project); Map callbacks = platformService.getTreeAsyncCallbacks(); if (pco.isChildrenUnavailable() && !callbacks.containsKey(parentDMTN)) { - EnqueueCallback callback = new PlatformAPICallback(project, tree, parentDMTN); - PlatformAPIs.listApis(pco.getId(), callback); + EnqueueCallback callback = new PlatformAPICallback(project, tree, parentDMTN); callbacks.put(parentDMTN, callback); + PlatformAPIs.listApis(pco.getId(), callback); parentDMTN.removeAllChildren(); parentDMTN.add(LOADING_DECORATOR); return 1; @@ -122,7 +164,9 @@ public boolean isLeaf(Object node) { } } else if (nodeObj instanceof PlatformCollection) { PlatformCollection pro = (PlatformCollection) nodeObj; - if (pro.isChildrenUnavailable()) { + if (pro.getApiCount() == 0) { + return true; + } else if (pro.isChildrenUnavailable()) { return false; } } else if (nodeObj instanceof PlatformDataDictionary) { diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformFavoriteCollectionsHandler.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformFavoriteCollectionsHandler.java new file mode 100644 index 00000000..85edb9e8 --- /dev/null +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/PlatformFavoriteCollectionsHandler.java @@ -0,0 +1,106 @@ +package com.xliic.openapi.platform.tree; + +import com.xliic.core.project.Project; +import com.xliic.core.ui.treeStructure.Tree; +import com.xliic.core.util.SwingUtilities; +import com.xliic.openapi.parser.ast.node.Node; +import com.xliic.openapi.platform.Permissions; +import com.xliic.openapi.platform.callback.EnqueueCallback; +import com.xliic.openapi.platform.callback.SuccessASTResponseCallback; +import com.xliic.openapi.platform.tree.node.PlatformCollection; +import com.xliic.openapi.platform.tree.utils.PlatformCollectionUtils; +import okhttp3.Call; +import okhttp3.Callback; +import okhttp3.Response; +import org.jetbrains.annotations.NotNull; + +import javax.swing.tree.DefaultMutableTreeNode; +import java.io.IOException; +import java.util.*; +import java.util.concurrent.ConcurrentHashMap; + +import static com.xliic.openapi.platform.tree.utils.PlatformCollectionUtils.getApiCount; + +// Implement interface just to use its type to put in callbacks map for convenience +public class PlatformFavoriteCollectionsHandler implements Callback { + + @NotNull + private final Project project; + @NotNull + private final Tree tree; + @NotNull + private final DefaultMutableTreeNode parentDMTN; + @NotNull + private final Set collectionIds; + @NotNull + private final Map collections = new ConcurrentHashMap<>(); + @NotNull + private final Map errors = new ConcurrentHashMap<>(); + + public PlatformFavoriteCollectionsHandler(@NotNull Project project, + @NotNull Tree tree, + @NotNull DefaultMutableTreeNode parentDMTN, + @NotNull Set collectionIds) { + this.project = project; + this.tree = tree; + this.parentDMTN = parentDMTN; + this.collectionIds = collectionIds; + } + + private synchronized void checkIfReady() { + if (collections.size() + errors.size() == collectionIds.size()) { + List myCollections = new LinkedList<>(collections.values()); + myCollections.sort(Comparator.comparing(PlatformCollection::getName, String.CASE_INSENSITIVE_ORDER)); + SwingUtilities.invokeLater(() -> { + PlatformCollectionUtils.addAll(project, tree, parentDMTN, myCollections); + collectionIds.clear(); + collections.clear(); + errors.clear(); + }); + } + } + + public EnqueueCallback getEnqueueCallback(@NotNull String collectionId) { + return new SuccessASTResponseCallback(project, false) { + + @Override + public void onCode200ASTResponse(@NotNull Node item) { + String id, name, technicalName; + Node desc = item.getChild("desc"); + int apiCount; + if (desc == null) { + id = item.getChildValueRequireNonNull("id"); + name = item.getChildValueRequireNonNull("name"); + technicalName = item.getChildValueRequireNonNull("technicalName"); + apiCount = getApiCount(item); + } else { + id = desc.getChildValueRequireNonNull("id"); + name = desc.getChildValueRequireNonNull("name"); + technicalName = desc.getChildValueRequireNonNull("technicalName"); + apiCount = getApiCount(desc); + } + Node summary = item.getChild("summary"); + Permissions permissions = Permissions.get(summary == null ? item : summary); + boolean locked = !permissions.isWriteApis(); + collections.put(collectionId, new PlatformCollection(id, name, locked, technicalName, permissions, apiCount)); + checkIfReady(); + } + + @Override + public void onFailure(@NotNull String reason) { + errors.put(collectionId, reason); + checkIfReady(); + } + }; + } + + @Override + public void onFailure(@NotNull Call call, @NotNull IOException e) { + // Not used + } + + @Override + public void onResponse(@NotNull Call call, @NotNull Response response) { + // Not used + } +} diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterAPIAction.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterAPIAction.java index f5bf73dd..098f54f6 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterAPIAction.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterAPIAction.java @@ -55,7 +55,7 @@ public void actionPerformed(@NotNull AnJActionEvent event) { Object filterObj = filterDMTN.getUserObject(); if (filterObj instanceof Filter) { Filter filter = (Filter) filterObj; - filter.setFilterName(chooser.getValue()); + filter.setFilter(chooser.getValue()); PlatformAsyncTreeModel model = (PlatformAsyncTreeModel) tree.getModel(); List expandedPaths = TreeUtil.collectExpandedPaths(tree); model.reload(filterDMTN); diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterCollectionAction.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterCollectionAction.java index 65e6a8ab..7d7e360f 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterCollectionAction.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterCollectionAction.java @@ -18,6 +18,7 @@ import com.xliic.openapi.platform.tree.PlatformAsyncTreeModel; import com.xliic.openapi.platform.tree.filter.PlatformTreeFilter; import com.xliic.openapi.platform.tree.node.core.Filter; +import com.xliic.openapi.platform.tree.node.PlatformRootCloud; public class PlatformFilterCollectionAction extends AnJAction implements DumbAware { @@ -46,9 +47,18 @@ public void actionPerformed(@NotNull AnJActionEvent event) { Object filterObj = filterDMTN.getUserObject(); if (filterObj instanceof Filter) { Filter filter = (Filter) filterObj; - filter.setFilterName(chooser.getValue()); + boolean wasFilterActive = filter.isFilterActive(); + filter.setFilter(chooser.getValue()); PlatformAsyncTreeModel model = (PlatformAsyncTreeModel) tree.getModel(); List expandedPaths = TreeUtil.collectExpandedPaths(tree); + if (!wasFilterActive) { + // Cache only nodes without filtering + model.cacheCollections(); + } + PlatformRootCloud root = (PlatformRootCloud) filterObj; + root.setChildrenUnavailable(true); + root.resetPage(); + filterDMTN.removeAllChildren(); model.reload(filterDMTN); TreeUtil.restoreExpandedPaths(tree, expandedPaths); } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterRemoveAction.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterRemoveAction.java index 0a3851c0..6ba73dea 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterRemoveAction.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/actions/PlatformFilterRemoveAction.java @@ -17,6 +17,7 @@ import com.xliic.openapi.platform.tree.PlatformAsyncTreeModel; import com.xliic.openapi.platform.tree.node.core.Filter; import com.xliic.openapi.platform.tree.node.decorator.PlatformFilterDecorator; +import com.xliic.openapi.platform.tree.node.PlatformRootCloud; public class PlatformFilterRemoveAction extends AnJAction implements DumbAware { @@ -44,9 +45,12 @@ public void actionPerformed(@NotNull AnJActionEvent event) { Object parentObj = parentDMTN.getUserObject(); if (parentObj instanceof Filter) { Filter filter = (Filter) parentObj; - filter.reset(); + filter.resetFilter(); PlatformAsyncTreeModel model = (PlatformAsyncTreeModel) tree.getModel(); List expandedPaths = TreeUtil.collectExpandedPaths(tree); + if (parentObj instanceof PlatformRootCloud) { + model.restoreCollections(); + } model.reload(parentDMTN); TreeUtil.restoreExpandedPaths(tree, expandedPaths); } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/mouse/PlatformLeftMouseClickHandler.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/mouse/PlatformLeftMouseClickHandler.java index e5353c62..1110f77f 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/mouse/PlatformLeftMouseClickHandler.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/mouse/PlatformLeftMouseClickHandler.java @@ -14,6 +14,7 @@ import com.xliic.openapi.platform.tree.node.core.Paginator; import com.xliic.openapi.platform.tree.node.decorator.PlatformLoadMoreDecorator; import com.xliic.openapi.platform.tree.ui.PlatformPanel; +import com.xliic.openapi.platform.tree.node.PlatformRootCloud; public class PlatformLeftMouseClickHandler { @@ -33,7 +34,10 @@ public void handle(MouseEvent event) { if (clickedObj instanceof PlatformLoadMoreDecorator) { DefaultMutableTreeNode parentDMTN = ((PlatformLoadMoreDecorator) clickedObj).getParent(); Paginator paginator = (Paginator) parentDMTN.getUserObject(); - paginator.increasePageSize(); + paginator.increasePage(); + if (parentDMTN.getUserObject() instanceof PlatformRootCloud) { + paginator.setChildrenUnavailable(true); + } List expandedPaths = TreeUtil.collectExpandedPaths(tree); model.reload(parentDMTN); TreeUtil.restoreExpandedPaths(tree, expandedPaths); diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformCollection.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformCollection.java index b62bf6b1..145a43bb 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformCollection.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformCollection.java @@ -19,19 +19,35 @@ public class PlatformCollection implements Paginator, Filter { @NotNull private final Permissions permissions; private volatile boolean childrenUnavailable; + private volatile boolean fullChildrenLoaded; @NotNull - private final String techName; - private int pageSize = Paginator.PAGE_SIZE; + private final String technicalName; + private int page = DEFAULT_PAGE; private String filterName; - - public PlatformCollection(@NotNull String id, @NotNull String name, boolean locked, @NotNull String techName, @NotNull Permissions permissions) { - this.id = id; - this.name = name; - this.locked = locked; - this.techName = techName; - childrenUnavailable = true; - this.permissions = permissions; - } + private final int apiCount; + + public PlatformCollection(@NotNull String id, + @NotNull String name, + boolean locked, + @NotNull String techName, + @NotNull Permissions permissions, + int apiCount) { + this.id = id; + this.name = name; + this.locked = locked; + this.technicalName = techName; + this.permissions = permissions; + childrenUnavailable = true; + this.apiCount = apiCount; + } + + public PlatformCollection(@NotNull String id, + @NotNull String name, + boolean locked, + @NotNull String techName, + @NotNull Permissions permissions) { + this(id, name, locked, techName, permissions, -1); + } public @NotNull String getName() { return name; @@ -50,13 +66,17 @@ public boolean isLocked() { } public @NotNull String getTechnicalName() { - return techName; + return technicalName; } public @NotNull Permissions getPermissions() { return permissions; } + public int getApiCount() { + return apiCount; + } + public boolean isChildrenUnavailable() { return childrenUnavailable; } @@ -66,7 +86,19 @@ public void setChildrenUnavailable(boolean childrenUnavailable) { } @Override - public boolean pass(@NotNull DefaultMutableTreeNode childDMTN) { + public boolean isFullChildrenLoaded() + { + return fullChildrenLoaded; + } + + @Override + public void setFullChildrenLoaded(boolean fullChildrenLoaded) + { + this.fullChildrenLoaded = fullChildrenLoaded; + } + + @Override + public boolean passFilter(@NotNull DefaultMutableTreeNode childDMTN) { if (!StringUtils.isEmpty(filterName)) { Object obj = childDMTN.getUserObject(); if (obj instanceof PlatformAPI) { @@ -78,32 +110,32 @@ public boolean pass(@NotNull DefaultMutableTreeNode childDMTN) { } @Override - public void setFilterName(@NotNull String name) { + public void setFilter(@NotNull String name) { filterName = name; } @Override - public void reset() { + public void resetFilter() { filterName = ""; } @Override - public boolean isActive() { + public boolean isFilterActive() { return !StringUtils.isEmpty(filterName); } @Override - public int getPageSize() { - return pageSize; + public int getPage() { + return page; } @Override - public void increasePageSize() { - this.pageSize += PAGE_SIZE; + public void increasePage() { + this.page += 1; } @Override - public void resetPageSize() { - this.pageSize = PAGE_SIZE; + public void resetPage() { + this.page = DEFAULT_PAGE; } } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootCloud.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootCloud.java index 5b60722d..8715519e 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootCloud.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootCloud.java @@ -12,28 +12,51 @@ public class PlatformRootCloud implements Paginator, Filter { private final static String NAME = "API Collections"; private volatile boolean childrenUnavailable; + private volatile boolean fullChildrenLoaded; - private int pageSize = Paginator.PAGE_SIZE; + private int page = DEFAULT_PAGE; private String filterName; public PlatformRootCloud() { childrenUnavailable = true; + resetFilter(); + } + + public void setFrom(PlatformRootCloud node) { + childrenUnavailable = node.isChildrenUnavailable(); + fullChildrenLoaded = node.isFullChildrenLoaded(); + page = node.getPage(); + resetFilter(); // Do not copy the filter value } public String getName() { return NAME; } + @Override public boolean isChildrenUnavailable() { return childrenUnavailable; } + @Override public void setChildrenUnavailable(boolean childrenUnavailable) { this.childrenUnavailable = childrenUnavailable; } @Override - public boolean pass(@NotNull DefaultMutableTreeNode childDMTN) { + public boolean isFullChildrenLoaded() + { + return fullChildrenLoaded; + } + + @Override + public void setFullChildrenLoaded(boolean fullChildrenLoaded) + { + this.fullChildrenLoaded = fullChildrenLoaded; + } + + @Override + public boolean passFilter(@NotNull DefaultMutableTreeNode childDMTN) { if (!StringUtils.isEmpty(filterName)) { Object obj = childDMTN.getUserObject(); if (obj instanceof PlatformCollection) { @@ -44,33 +67,37 @@ public boolean pass(@NotNull DefaultMutableTreeNode childDMTN) { return true; } + public String getFilter() { + return filterName; + } + @Override - public void setFilterName(@NotNull String name) { + public void setFilter(@NotNull String name) { filterName = name; } @Override - public void reset() { + public void resetFilter() { filterName = ""; } @Override - public boolean isActive() { + public boolean isFilterActive() { return !StringUtils.isEmpty(filterName); } @Override - public int getPageSize() { - return pageSize; + public int getPage() { + return page; } @Override - public void increasePageSize() { - this.pageSize += PAGE_SIZE; + public void increasePage() { + this.page += 1; } @Override - public void resetPageSize() { - this.pageSize = PAGE_SIZE; + public void resetPage() { + this.page = DEFAULT_PAGE; } } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootFavorite.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootFavorite.java index b2ecd7fa..231f6d15 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootFavorite.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/PlatformRootFavorite.java @@ -4,6 +4,16 @@ public class PlatformRootFavorite { private final static String NAME = "My Favorite Collections"; + private volatile boolean childrenUnavailable = true; + + public boolean isChildrenUnavailable() { + return childrenUnavailable; + } + + public void setChildrenUnavailable(boolean childrenUnavailable) { + this.childrenUnavailable = childrenUnavailable; + } + public String getName() { return NAME; } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Filter.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Filter.java index a033914c..ce7dd977 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Filter.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Filter.java @@ -6,11 +6,11 @@ public interface Filter { - void reset(); + void resetFilter(); - boolean isActive(); + boolean isFilterActive(); - void setFilterName(@NotNull String name); + void setFilter(@NotNull String name); - boolean pass(@NotNull DefaultMutableTreeNode childDMTN); + boolean passFilter(@NotNull DefaultMutableTreeNode childDMTN); } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Paginator.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Paginator.java index ec1f710d..d2d00b36 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Paginator.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/core/Paginator.java @@ -3,10 +3,19 @@ public interface Paginator { int PAGE_SIZE = 100; + int DEFAULT_PAGE = 1; + + int getPage(); - int getPageSize(); + void increasePage(); - void increasePageSize(); + void resetPage(); + + boolean isChildrenUnavailable(); - void resetPageSize(); + void setChildrenUnavailable(boolean childrenUnavailable); + + boolean isFullChildrenLoaded(); + + void setFullChildrenLoaded(boolean fullChildrenLoaded); } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformDecorator.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformDecorator.java new file mode 100644 index 00000000..aafbc385 --- /dev/null +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformDecorator.java @@ -0,0 +1,4 @@ +package com.xliic.openapi.platform.tree.node.decorator; + +public interface PlatformDecorator { +} diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformErrorDecorator.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformErrorDecorator.java index 127842da..43dc591b 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformErrorDecorator.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformErrorDecorator.java @@ -1,6 +1,6 @@ package com.xliic.openapi.platform.tree.node.decorator; -public class PlatformErrorDecorator { +public class PlatformErrorDecorator implements PlatformDecorator { private final String name; diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformFilterDecorator.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformFilterDecorator.java index faaaeeb9..dceca590 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformFilterDecorator.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformFilterDecorator.java @@ -4,7 +4,7 @@ import org.jetbrains.annotations.NotNull; -public class PlatformFilterDecorator { +public class PlatformFilterDecorator implements PlatformDecorator { private final String name; private final DefaultMutableTreeNode parent; diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadMoreDecorator.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadMoreDecorator.java index 7dd41689..6813461f 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadMoreDecorator.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadMoreDecorator.java @@ -4,7 +4,7 @@ import org.jetbrains.annotations.NotNull; -public class PlatformLoadMoreDecorator { +public class PlatformLoadMoreDecorator implements PlatformDecorator { private static final String NAME = "Load More..."; diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadingDecorator.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadingDecorator.java index b086c644..e61f8eb8 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadingDecorator.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/node/decorator/PlatformLoadingDecorator.java @@ -1,4 +1,4 @@ package com.xliic.openapi.platform.tree.node.decorator; -public class PlatformLoadingDecorator { +public class PlatformLoadingDecorator implements PlatformDecorator { } diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformCollectionUtils.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformCollectionUtils.java index de01972f..7ad49e90 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformCollectionUtils.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformCollectionUtils.java @@ -14,42 +14,60 @@ import com.xliic.core.ui.tree.TreePathUtil; import com.xliic.core.ui.treeStructure.Tree; import com.xliic.core.util.ui.tree.TreeUtil; +import com.xliic.openapi.parser.ast.node.Node; import com.xliic.openapi.platform.tree.PlatformAsyncTreeModel; import com.xliic.openapi.platform.tree.node.PlatformCollection; import com.xliic.openapi.platform.tree.node.PlatformRootCloud; import com.xliic.openapi.services.PlatformService; +import com.xliic.openapi.platform.tree.node.PlatformRootFavorite; +import com.xliic.openapi.platform.tree.node.core.Paginator; + +import static com.xliic.openapi.platform.tree.utils.PlatformUtils.removeLoadingDecorator; public class PlatformCollectionUtils { - public static void addAll(@NotNull Project project, - @NotNull Tree tree, - @NotNull DefaultMutableTreeNode parentDMTN, - @NotNull List collections) { - PlatformAsyncTreeModel model = ((PlatformAsyncTreeModel) tree.getModel()); - DefaultMutableTreeNode favoriteCollections = model.getFavoriteCollections(); - parentDMTN.removeAllChildren(); - favoriteCollections.removeAllChildren(); - PlatformService platformService = PlatformService.getInstance(project); - Set collectionIds = platformService.getState().collectionIds; - for (PlatformCollection pco : collections) { - DefaultMutableTreeNode pcoDMTN = new DefaultMutableTreeNode(pco); - parentDMTN.add(pcoDMTN); - if (collectionIds.contains(pco.getId())) { - favoriteCollections.add(getCollectionSubTreeCopy(pcoDMTN)); - } - } - PlatformRootCloud rco = (PlatformRootCloud) parentDMTN.getUserObject(); - rco.setChildrenUnavailable(false); - platformService.getTreeAsyncCallbacks().remove(parentDMTN); - List expandedPaths = TreeUtil.collectExpandedPaths(tree); - // Eclipse Development Note - // Expansion state is ignored if node has no children, restore it here - if (favoriteCollections.getChildCount() > 0) { - expandedPaths.add(TreePathUtil.pathToTreeNode(favoriteCollections)); - } - model.reload(); - TreeUtil.restoreExpandedPaths(tree, expandedPaths); - } + public static void addAll(@NotNull Project project, + @NotNull Tree tree, + @NotNull DefaultMutableTreeNode parentDMTN, + @NotNull List collections) { + PlatformAsyncTreeModel model = ((PlatformAsyncTreeModel) tree.getModel()); + // Do not delete all children as they may be from previously added pages + removeLoadingDecorator(parentDMTN); + // Add collections + for (PlatformCollection pco : collections) { + DefaultMutableTreeNode pcoDMTN = new DefaultMutableTreeNode(pco); + parentDMTN.add(pcoDMTN); + } + // Mark parent node that everything is loaded and ready + Object parentObj = parentDMTN.getUserObject(); + if (parentObj instanceof PlatformRootCloud) { + PlatformRootCloud rco = (PlatformRootCloud) parentDMTN.getUserObject(); + rco.setChildrenUnavailable(false); + rco.setFullChildrenLoaded(collections.size() < Paginator.PAGE_SIZE); + } else if (parentObj instanceof PlatformRootFavorite) { + PlatformRootFavorite rfo = (PlatformRootFavorite) parentDMTN.getUserObject(); + rfo.setChildrenUnavailable(false); + } + // Sometimes expanded parent nodes are not returned below + List expandedPaths = TreeUtil.collectExpandedPaths(tree); + TreePath parentTreePath = TreePathUtil.pathToTreeNode(parentDMTN); + if (!isFoundInTreePaths(parentTreePath, expandedPaths)) { + // Add it here if not + expandedPaths.add(parentTreePath); + } + model.reload(); + TreeUtil.restoreExpandedPaths(tree, expandedPaths); + PlatformService.getInstance(project).getTreeAsyncCallbacks().remove(parentDMTN); + } + + private static boolean isFoundInTreePaths(TreePath targetTreePath, List paths) { + for (TreePath treePath : paths) { + if (targetTreePath.equals(treePath)) { + return true; + } + } + return false; + } public static void addToFavoriteCollection(@NotNull Project project, @NotNull Tree tree, @NotNull String collectionId) { PlatformAsyncTreeModel model = ((PlatformAsyncTreeModel) tree.getModel()); @@ -141,6 +159,19 @@ public static void delete(@NotNull Tree tree, @NotNull String collectionId) { } } + public static int getApiCount(@NotNull Node node) { + String value = node.getChildValue("apiCount"); + if (value != null) { + try { + return Integer.parseInt(value); + } catch (NumberFormatException ignored) { + return -1; + } + } + // Means there is no api counter available + return -1; + } + private static DefaultMutableTreeNode getCollectionSubTreeCopy(DefaultMutableTreeNode colDMTN) { DefaultMutableTreeNode resultDMTN = PlatformUtils.getCopyDMTN(colDMTN); for (int i = 0; i < colDMTN.getChildCount(); i++) { diff --git a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformUtils.java b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformUtils.java index ae99b4d3..2a6f2934 100644 --- a/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformUtils.java +++ b/openapi-plugin/src/main/java/com/xliic/openapi/platform/tree/utils/PlatformUtils.java @@ -38,11 +38,15 @@ import com.xliic.openapi.platform.tree.node.PlatformAPI; import com.xliic.openapi.platform.tree.node.PlatformCollection; import com.xliic.openapi.platform.tree.node.PlatformRootCloud; +import com.xliic.openapi.platform.tree.node.PlatformRootFavorite; import com.xliic.openapi.platform.tree.node.core.Filter; import com.xliic.openapi.platform.tree.node.core.Paginator; import com.xliic.openapi.platform.tree.node.core.ProgressAware; +import com.xliic.openapi.platform.tree.node.decorator.PlatformDecorator; +import com.xliic.openapi.platform.tree.node.decorator.PlatformErrorDecorator; import com.xliic.openapi.platform.tree.node.decorator.PlatformFilterDecorator; import com.xliic.openapi.platform.tree.node.decorator.PlatformLoadMoreDecorator; +import com.xliic.openapi.platform.tree.node.decorator.PlatformLoadingDecorator; import com.xliic.openapi.services.PlatformService; import com.xliic.openapi.utils.NetUtils; import com.xliic.openapi.utils.Utils; @@ -81,12 +85,12 @@ public static List getVisibleChildren(Object parent) { if (parentObj instanceof PlatformRootCloud) { Filter filter = (Filter) parentObj; - boolean active = filter.isActive(); + boolean active = filter.isFilterActive(); for (int i = 0; i < parentDMTN.getChildCount(); i++) { DefaultMutableTreeNode collectionDMTN = (DefaultMutableTreeNode) parentDMTN.getChildAt(i); Object obj = collectionDMTN.getUserObject(); if (active && obj instanceof PlatformCollection) { - if (filter.pass(collectionDMTN)) { + if (filter.passFilter(collectionDMTN)) { result.add(collectionDMTN); } } else { @@ -95,12 +99,12 @@ public static List getVisibleChildren(Object parent) { } } else if (parentObj instanceof PlatformCollection) { Filter filter = (Filter) parentObj; - boolean active = filter.isActive(); + boolean active = filter.isFilterActive(); for (int i = 0; i < parentDMTN.getChildCount(); i++) { DefaultMutableTreeNode apiDMTN = (DefaultMutableTreeNode) parentDMTN.getChildAt(i); Object obj = apiDMTN.getUserObject(); if (active && obj instanceof PlatformAPI) { - if (filter.pass(apiDMTN)) { + if (filter.passFilter(apiDMTN)) { result.add(apiDMTN); } } else { @@ -112,26 +116,50 @@ public static List getVisibleChildren(Object parent) { result.add((DefaultMutableTreeNode) parentDMTN.getChildAt(i)); } } + if (hasErrorDMTN(result)) { + return result; + } final int size = result.size(); // Apply pagination if (parentObj instanceof Paginator) { - Paginator paginator = (Paginator) parentDMTN.getUserObject(); - int pageSize = paginator.getPageSize(); - if (size > pageSize) { - result = new LinkedList<>(result.subList(0, pageSize)); - result.add(new DefaultMutableTreeNode(new PlatformLoadMoreDecorator(parentDMTN), false)); + if (parentObj instanceof PlatformRootCloud) { + if (!((PlatformRootCloud) parentObj).isFullChildrenLoaded()) + { + result.add(new DefaultMutableTreeNode(new PlatformLoadMoreDecorator(parentDMTN), false)); + } + } else { + Paginator paginator = (Paginator) parentDMTN.getUserObject(); + int pageSize = paginator.getPage() * Paginator.PAGE_SIZE; + if (size > pageSize) { + result = new LinkedList<>(result.subList(0, pageSize)); + result.add(new DefaultMutableTreeNode(new PlatformLoadMoreDecorator(parentDMTN), false)); + } } } // Apply filter decorator if (parentObj instanceof Filter) { Filter filter = (Filter) parentObj; - if (filter.isActive()) { - result.addFirst(new DefaultMutableTreeNode(new PlatformFilterDecorator("Found " + size, parentDMTN), false)); + if (filter.isFilterActive()) { + result.addFirst(new DefaultMutableTreeNode( + new PlatformFilterDecorator("Found " + getFoundItemsCount(result), parentDMTN), false)); } } return result; } + private static long getFoundItemsCount(List result) { + return result.stream().filter(node -> !(node.getUserObject() instanceof PlatformDecorator)).count(); + } + + public static boolean hasErrorDMTN(List nodes) { + for (DefaultMutableTreeNode node : nodes) { + if (node.getUserObject() instanceof PlatformErrorDecorator) { + return true; + } + } + return false; + } + public static void reloadAll(@NotNull Project project, @NotNull Tree tree) { DefaultMutableTreeNode treeRoot = (DefaultMutableTreeNode) tree.getModel().getRoot(); for (int i = 0; i < treeRoot.getChildCount(); i++) { @@ -139,10 +167,13 @@ public static void reloadAll(@NotNull Project project, @NotNull Tree tree) { childDMTN.removeAllChildren(); Object obj = childDMTN.getUserObject(); if (obj instanceof PlatformRootCloud) { - PlatformRootCloud root = (PlatformRootCloud) childDMTN.getUserObject(); - root.setChildrenUnavailable(true); - root.resetPageSize(); - root.reset(); + PlatformRootCloud rco = (PlatformRootCloud) obj; + rco.setChildrenUnavailable(true); + rco.resetPage(); + rco.resetFilter(); + } else if (obj instanceof PlatformRootFavorite) { + PlatformRootFavorite rfo = (PlatformRootFavorite) obj; + rfo.setChildrenUnavailable(true); } } PlatformAsyncTreeModel model = ((PlatformAsyncTreeModel) tree.getModel()); @@ -151,12 +182,10 @@ public static void reloadAll(@NotNull Project project, @NotNull Tree tree) { PlatformService platformService = PlatformService.getInstance(project); Map callbacks = platformService.getTreeAsyncCallbacks(); callbacks.clear(); - // Eclipse Development Note - // If node in collapsed state its children will be ignored by the model - // Set it before reload to ask model to take care of non leaf children + model.clearCachedCollections(); + model.reload(); tree.expandPath(TreePathUtil.pathToTreeNode(favoriteCollections)); tree.expandPath(TreePathUtil.pathToTreeNode(cloudCollections)); - model.reload(); } public static boolean hasCollectionsLoaded(@NotNull Project project, @NotNull Tree tree) { @@ -322,9 +351,19 @@ public static void targetTreeNode(@NotNull Tree tree, onTargetCb.run(); return; } else { - paginator.increasePageSize(); + paginator.increasePage(); reloadMe = true; } } } + + public static void removeLoadingDecorator(@NotNull DefaultMutableTreeNode parentDMTN) { + // Iterate backwards to safely remove items by index + for (int i = parentDMTN.getChildCount() - 1; i >= 0; i--) { + DefaultMutableTreeNode childDMTN = (DefaultMutableTreeNode) parentDMTN.getChildAt(i); + if (childDMTN.getUserObject() instanceof PlatformLoadingDecorator) { + parentDMTN.remove(i); + } + } + } } From eac17416803a36e37f5b4ff6b78d944928573e81 Mon Sep 17 00:00:00 2001 From: Viacheslav Fateev Date: Thu, 20 Aug 2026 17:52:03 +0300 Subject: [PATCH 2/2] Bump version to 5.9.0 --- openapi-feature/feature.xml | 4 ++-- openapi-feature/pom.xml | 2 +- openapi-plugin/META-INF/MANIFEST.MF | 2 +- openapi-plugin/pom.xml | 2 +- openapi-repository/pom.xml | 2 +- pom.xml | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/openapi-feature/feature.xml b/openapi-feature/feature.xml index 58615a90..0b739f3d 100644 --- a/openapi-feature/feature.xml +++ b/openapi-feature/feature.xml @@ -2,7 +2,7 @@ @@ -705,7 +705,7 @@ For more information on this, and how to apply and follow the GNU AGPL, see id="openapi-plugin" download-size="0" install-size="0" - version="5.8.0" + version="5.9.0" unpack="false"/> com.xliic.openapi openapi-parent - 5.8.0 + 5.9.0 com.xliic.openapi diff --git a/openapi-plugin/META-INF/MANIFEST.MF b/openapi-plugin/META-INF/MANIFEST.MF index 9445e924..c9dfe807 100644 --- a/openapi-plugin/META-INF/MANIFEST.MF +++ b/openapi-plugin/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Eclipse-openapi Bundle-SymbolicName: openapi-plugin;singleton:=true -Bundle-Version: 5.8.0 +Bundle-Version: 5.9.0 Require-Bundle: org.eclipse.ui, org.eclipse.core.runtime, org.eclipse.core.resources;bundle-version="3.13.700", diff --git a/openapi-plugin/pom.xml b/openapi-plugin/pom.xml index 887b25b4..15e8bc9f 100644 --- a/openapi-plugin/pom.xml +++ b/openapi-plugin/pom.xml @@ -5,7 +5,7 @@ com.xliic.openapi openapi-parent - 5.8.0 + 5.9.0 openapi-plugin diff --git a/openapi-repository/pom.xml b/openapi-repository/pom.xml index b7ddd763..2de4e478 100644 --- a/openapi-repository/pom.xml +++ b/openapi-repository/pom.xml @@ -6,7 +6,7 @@ com.xliic.openapi openapi-parent - 5.8.0 + 5.9.0 openapi-repository diff --git a/pom.xml b/pom.xml index c4d06cb0..8f970372 100644 --- a/pom.xml +++ b/pom.xml @@ -5,7 +5,7 @@ 4.0.0 com.xliic.openapi openapi-parent - 5.8.0 + 5.9.0 pom