import {
  a,
  c as t
} from "./chunk-IO47FP3U.js";

// ../node_modules/highlight.js/lib/languages/nginx.js
var E = t((c, i) => {
  function s(e) {
    let n = {
      className: "variable",
      variants: [
        {
          begin: /\$\d+/
        },
        {
          begin: /\$\{/,
          end: /\}/
        },
        {
          begin: /[$@]/ + e.UNDERSCORE_IDENT_RE
        }
      ]
    }, r = {
      endsWithParent: !0,
      keywords: {
        $pattern: "[a-z/_]+",
        literal: "on off yes no true false none blocked debug info notice warn error crit select break last permanent redirect kqueue rtsig epoll poll /dev/poll"
      },
      relevance: 0,
      illegal: "=>",
      contains: [
        e.HASH_COMMENT_MODE,
        {
          className: "string",
          contains: [
            e.BACKSLASH_ESCAPE,
            n
          ],
          variants: [
            {
              begin: /"/,
              end: /"/
            },
            {
              begin: /'/,
              end: /'/
            }
          ]
        },
        // this swallows entire URLs to avoid detecting numbers within
        {
          begin: "([a-z]+):/",
          end: "\\s",
          endsWithParent: !0,
          excludeEnd: !0,
          contains: [n]
        },
        {
          className: "regexp",
          contains: [
            e.BACKSLASH_ESCAPE,
            n
          ],
          variants: [
            {
              begin: "\\s\\^",
              end: "\\s|\\{|;",
              returnEnd: !0
            },
            // regexp locations (~, ~*)
            {
              begin: "~\\*?\\s+",
              end: "\\s|\\{|;",
              returnEnd: !0
            },
            // *.example.com
            {
              begin: "\\*(\\.[a-z\\-]+)+"
            },
            // sub.example.*
            {
              begin: "([a-z\\-]+\\.)+\\*"
            }
          ]
        },
        // IP
        {
          className: "number",
          begin: "\\b\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}(:\\d{1,5})?\\b"
        },
        // units
        {
          className: "number",
          begin: "\\b\\d+[kKmMgGdshdwy]*\\b",
          relevance: 0
        },
        n
      ]
    };
    return {
      name: "Nginx config",
      aliases: ["nginxconf"],
      contains: [
        e.HASH_COMMENT_MODE,
        {
          begin: e.UNDERSCORE_IDENT_RE + "\\s+\\{",
          returnBegin: !0,
          end: /\{/,
          contains: [
            {
              className: "section",
              begin: e.UNDERSCORE_IDENT_RE
            }
          ],
          relevance: 0
        },
        {
          begin: e.UNDERSCORE_IDENT_RE + "\\s",
          end: ";|\\{",
          returnBegin: !0,
          contains: [
            {
              className: "attribute",
              begin: e.UNDERSCORE_IDENT_RE,
              starts: r
            }
          ],
          relevance: 0
        }
      ],
      illegal: "[^\\s\\}]"
    };
  }
  a(s, "nginx");
  i.exports = s;
});

export {
  E as a
};
