import { __exports as M } from "../../../../../../_virtual/index27.js";
import { __require as H } from "./decode.js";
import { __require as m } from "./encode.js";
import { __require as l } from "./escape.js";
var y;
function S() {
  return y ? M : (y = 1, function(e) {
    Object.defineProperty(e, "__esModule", { value: !0 }), e.decodeXMLStrict = e.decodeHTML5Strict = e.decodeHTML4Strict = e.decodeHTML5 = e.decodeHTML4 = e.decodeHTMLAttribute = e.decodeHTMLStrict = e.decodeHTML = e.decodeXML = e.DecodingMode = e.EntityDecoder = e.encodeHTML5 = e.encodeHTML4 = e.encodeNonAsciiHTML = e.encodeHTML = e.escapeText = e.escapeAttribute = e.escapeUTF8 = e.escape = e.encodeXML = e.encode = e.decodeStrict = e.decode = e.EncodingMode = e.EntityLevel = void 0;
    var b = /* @__PURE__ */ H(), T = /* @__PURE__ */ m(), o = /* @__PURE__ */ l(), d;
    (function(r) {
      r[r.XML = 0] = "XML", r[r.HTML = 1] = "HTML";
    })(d = e.EntityLevel || (e.EntityLevel = {}));
    var u;
    (function(r) {
      r[r.UTF8 = 0] = "UTF8", r[r.ASCII = 1] = "ASCII", r[r.Extensive = 2] = "Extensive", r[r.Attribute = 3] = "Attribute", r[r.Text = 4] = "Text";
    })(u = e.EncodingMode || (e.EncodingMode = {}));
    function a(r, t) {
      t === void 0 && (t = d.XML);
      var n = typeof t == "number" ? t : t.level;
      if (n === d.HTML) {
        var f = typeof t == "object" ? t.mode : void 0;
        return (0, b.decodeHTML)(r, f);
      }
      return (0, b.decodeXML)(r);
    }
    e.decode = a;
    function j(r, t) {
      var n;
      t === void 0 && (t = d.XML);
      var f = typeof t == "number" ? { level: t } : t;
      return (n = f.mode) !== null && n !== void 0 || (f.mode = b.DecodingMode.Strict), a(r, f);
    }
    e.decodeStrict = j;
    function v(r, t) {
      t === void 0 && (t = d.XML);
      var n = typeof t == "number" ? { level: t } : t;
      return n.mode === u.UTF8 ? (0, o.escapeUTF8)(r) : n.mode === u.Attribute ? (0, o.escapeAttribute)(r) : n.mode === u.Text ? (0, o.escapeText)(r) : n.level === d.HTML ? n.mode === u.ASCII ? (0, T.encodeNonAsciiHTML)(r) : (0, T.encodeHTML)(r) : (0, o.encodeXML)(r);
    }
    e.encode = v;
    var i = /* @__PURE__ */ l();
    Object.defineProperty(e, "encodeXML", { enumerable: !0, get: function() {
      return i.encodeXML;
    } }), Object.defineProperty(e, "escape", { enumerable: !0, get: function() {
      return i.escape;
    } }), Object.defineProperty(e, "escapeUTF8", { enumerable: !0, get: function() {
      return i.escapeUTF8;
    } }), Object.defineProperty(e, "escapeAttribute", { enumerable: !0, get: function() {
      return i.escapeAttribute;
    } }), Object.defineProperty(e, "escapeText", { enumerable: !0, get: function() {
      return i.escapeText;
    } });
    var L = /* @__PURE__ */ m();
    Object.defineProperty(e, "encodeHTML", { enumerable: !0, get: function() {
      return L.encodeHTML;
    } }), Object.defineProperty(e, "encodeNonAsciiHTML", { enumerable: !0, get: function() {
      return L.encodeNonAsciiHTML;
    } }), Object.defineProperty(e, "encodeHTML4", { enumerable: !0, get: function() {
      return L.encodeHTML;
    } }), Object.defineProperty(e, "encodeHTML5", { enumerable: !0, get: function() {
      return L.encodeHTML;
    } });
    var c = /* @__PURE__ */ H();
    Object.defineProperty(e, "EntityDecoder", { enumerable: !0, get: function() {
      return c.EntityDecoder;
    } }), Object.defineProperty(e, "DecodingMode", { enumerable: !0, get: function() {
      return c.DecodingMode;
    } }), Object.defineProperty(e, "decodeXML", { enumerable: !0, get: function() {
      return c.decodeXML;
    } }), Object.defineProperty(e, "decodeHTML", { enumerable: !0, get: function() {
      return c.decodeHTML;
    } }), Object.defineProperty(e, "decodeHTMLStrict", { enumerable: !0, get: function() {
      return c.decodeHTMLStrict;
    } }), Object.defineProperty(e, "decodeHTMLAttribute", { enumerable: !0, get: function() {
      return c.decodeHTMLAttribute;
    } }), Object.defineProperty(e, "decodeHTML4", { enumerable: !0, get: function() {
      return c.decodeHTML;
    } }), Object.defineProperty(e, "decodeHTML5", { enumerable: !0, get: function() {
      return c.decodeHTML;
    } }), Object.defineProperty(e, "decodeHTML4Strict", { enumerable: !0, get: function() {
      return c.decodeHTMLStrict;
    } }), Object.defineProperty(e, "decodeHTML5Strict", { enumerable: !0, get: function() {
      return c.decodeHTMLStrict;
    } }), Object.defineProperty(e, "decodeXMLStrict", { enumerable: !0, get: function() {
      return c.decodeXML;
    } });
  }(M), M);
}
export {
  S as __require
};
//# sourceMappingURL=index.js.map
