const require_runtime = require("../_virtual/_rolldown/runtime.js"); const require_index = require("../utils/index.js"); const require_casing = require("../utils/casing.js"); const require_regexp = require("../utils/regexp.js"); //#region lib/rules/no-bare-strings-in-template.ts var import_utils = /* @__PURE__ */ require_runtime.__toESM(require_index.default); const DEFAULT_ALLOWLIST = [ "(", ")", ",", ".", "&", "+", "-", "=", "*", "/", "#", "%", "!", "?", ":", "[", "]", "{", "}", "<", ">", "·", "•", "‐", "–", "—", "−", "|" ]; const DEFAULT_ATTRIBUTES = { "/.+/": [ "title", "aria-label", "aria-placeholder", "aria-roledescription", "aria-valuetext" ], input: ["placeholder"], img: ["alt"] }; const DEFAULT_DIRECTIVES = ["v-text"]; /** * Parse attributes option */ function parseTargetAttrs(options) { const result = { names: {}, regexps: [], cache: {} }; for (const [tagName, tagAttrs] of Object.entries(options)) { const attrs = new Set(tagAttrs); if (require_regexp.isRegExp(tagName)) result.regexps.push({ name: require_regexp.toRegExp(tagName), attrs }); else result.names[tagName] = attrs; } return result; } /** * Get a string from given expression container node */ function getStringValue(value) { const expression = value.expression; if (!expression) return null; if (expression.type !== "Literal") return null; if (typeof expression.value === "string") return expression.value; return null; } var no_bare_strings_in_template_default = { meta: { type: "suggestion", docs: { description: "disallow the use of bare strings in `