var x = Object.defineProperty;
var n = (e, a) => x(e, "name", { value: a, configurable: !0 });
const A = /* @__PURE__ */ n((e, ...a) => ({
  strTag: !0,
  strings: e,
  values: a
}), "_str"), i = A, F = /* @__PURE__ */ n((e) => typeof e != "string" && "strTag" in e, "isStrTagged"), M = /* @__PURE__ */ n((e, a, s) => {
  let r = e[0];
  for (let t = 1; t < e.length; t++)
    r += a[s ? s[t - 1] : t - 1], r += e[t];
  return r;
}, "joinStringsAndValues");
const R = /* @__PURE__ */ n((e) => F(e) ? M(e.strings, e.values) : e, "defaultMsg");
const S = "lit-localize-status";
const T = class T {
  constructor(a) {
    this.__litLocalizeEventHandler = (s) => {
      s.detail.status === "ready" && this.host.requestUpdate();
    }, this.host = a;
  }
  hostConnected() {
    window.addEventListener(S, this.__litLocalizeEventHandler);
  }
  hostDisconnected() {
    window.removeEventListener(S, this.__litLocalizeEventHandler);
  }
};
n(T, "LocalizeController");
let L = T;
const P = /* @__PURE__ */ n((e) => e.addController(new L(e)), "_updateWhenLocaleChanges"), V = P;
const X = /* @__PURE__ */ n(() => (e, a) => (e.addInitializer(V), e), "localized");
const _ = class _ {
  constructor() {
    this.settled = !1, this.promise = new Promise((a, s) => {
      this._resolve = a, this._reject = s;
    });
  }
  resolve(a) {
    this.settled = !0, this._resolve(a);
  }
  reject(a) {
    this.settled = !0, this._reject(a);
  }
};
n(_, "Deferred");
let g = _;
const c = [];
for (let e = 0; e < 256; e++)
  c[e] = (e >> 4 & 15).toString(16) + (e & 15).toString(16);
function C(e) {
  let a = 0, s = 8997, r = 0, t = 33826, d = 0, f = 40164, v = 0, l = 52210;
  for (let h = 0; h < e.length; h++)
    s ^= e.charCodeAt(h), a = s * 435, r = t * 435, d = f * 435, v = l * 435, d += s << 8, v += t << 8, r += a >>> 16, s = a & 65535, d += r >>> 16, t = r & 65535, l = v + (d >>> 16) & 65535, f = d & 65535;
  return c[l >> 8] + c[l & 255] + c[f >> 8] + c[f & 255] + c[t >> 8] + c[t & 255] + c[s >> 8] + c[s & 255];
}
n(C, "fnv1a64");
const H = "", N = "h", z = "s";
function D(e, a) {
  return (a ? N : z) + C(typeof e == "string" ? e : e.join(H));
}
n(D, "generateMsgId");
const y = /* @__PURE__ */ new WeakMap(), j = /* @__PURE__ */ new Map();
function O(e, a, s) {
  if (e) {
    const r = (s == null ? void 0 : s.id) ?? U(a), t = e[r];
    if (t) {
      if (typeof t == "string")
        return t;
      if ("strTag" in t)
        return M(
          t.strings,
          // Cast `template` because its type wasn't automatically narrowed (but
          // we know it must be the same type as `localized`).
          a.values,
          t.values
        );
      {
        let d = y.get(t);
        return d === void 0 && (d = t.values, y.set(t, d)), {
          ...t,
          values: d.map((f) => a.values[f])
        };
      }
    }
  }
  return R(a);
}
n(O, "runtimeMsg");
function U(e) {
  const a = typeof e == "string" ? e : e.strings;
  let s = j.get(a);
  return s === void 0 && (s = D(a, typeof e != "string" && !("strTag" in e)), j.set(a, s)), s;
}
n(U, "generateId");
function p(e) {
  window.dispatchEvent(new CustomEvent(S, { detail: e }));
}
n(p, "dispatchStatusEvent");
let u = "", k, w, m, E, $, o = new g();
o.resolve();
let b = 0;
const J = /* @__PURE__ */ n((e) => (W((a, s) => O($, a, s)), u = w = e.sourceLocale, m = new Set(e.targetLocales), m.add(e.sourceLocale), E = e.loadLocale, { getLocale: q, setLocale: G }), "configureLocalization"), q = /* @__PURE__ */ n(() => u, "getLocale"), G = /* @__PURE__ */ n((e) => {
  if (e === (k ?? u))
    return o.promise;
  if (!m || !E)
    throw new Error("Internal error");
  if (!m.has(e))
    throw new Error("Invalid locale code");
  b++;
  const a = b;
  return k = e, o.settled && (o = new g()), p({ status: "loading", loadingLocale: e }), (e === w ? (
    // We could switch to the source locale synchronously, but we prefer to
    // queue it on a microtask so that switching locales is consistently
    // asynchronous.
    Promise.resolve({ templates: void 0 })
  ) : E(e)).then((r) => {
    b === a && (u = e, k = void 0, $ = r.templates, p({ status: "ready", readyLocale: e }), o.resolve());
  }, (r) => {
    b === a && (p({
      status: "error",
      errorLocale: e,
      errorMessage: r.toString()
    }), o.reject(r));
  }), o.promise;
}, "setLocale");
let K = R, I = !1;
function W(e) {
  if (I)
    throw new Error("lit-localize can only be configured once");
  K = e, I = !0;
}
n(W, "_installMsgImplementation");
const Z = {
  s0058d65423075c1c: "Ny konversation",
  s0204546ecda4bd3f: "Namnlös konversation",
  s03844c0e2397a948: "Ta bort som admin",
  s08313776ae04f67f: "Ta bort bild",
  s0b3525368392bc8b: "Filkonflikt",
  s0d7fcbf8f03c7116: "Avprenumerera",
  s12b57a05d9905236: "Din sökning hade inga träffar.",
  s15bdec250a4a55fb: "Fallande",
  s16430e1864d70df9: "Skriv ett meddelande...",
  s1a60287b81ec038c: "Sök efter konversationer...",
  s1d2863ddb9533fcc: "Från molnlagring",
  s1ea911617f4bf7e7: i`Öppna i ${0}?`,
  s215e54ddbbcc5f07: "Lämna konversation",
  s2359515613fb2d9a: "Kommentaren togs bort.",
  s236ae937cbcd6a39: "Zooma in",
  s251a18781c6a3625: "+ lägg till alternativ",
  s2662796b3275bb5b: "Skapa en konversation för att komma igång.",
  s26f91b6796e33111: "Återställ",
  s275e39c24f663f7e: "Starta en konversation!",
  s2a200f62cfdb269c: "Molnlagring",
  s2a8434b16dc214a3: "Ersätt",
  s2b85774393f15042: "Göm borttagna",
  s2cc555789d54845c: i`${0} skriver${1}`,
  s2ea30e6262e90c5b: "Fyll skärm",
  s343f95633406dc81: "1 kommentar",
  s355b21b89ce5d9c5: "Detaljer",
  s382a2aa3984474dd: "Skapa",
  s3bdfdd0bd23b0c44: "Servern är offline, försök igen om några minuter...",
  s3c1bff8f22445f9e: "Här finns inget att se ännu.",
  s4020ae71422bf3cd: "Namn",
  s417b90913e05bc17: "Förhandsvisning",
  s426827ed0daf0c4f: "Visa borttagna",
  s45a359a3fa397256: "Lista",
  s46cbf33973ae5386: "Återställ sidopanel",
  s473ac9da86ea91f9: "Anpassa sidbredd",
  s48287bbcb6ba7b8d: i`Slutade ${0}`,
  s4854cd48f30ff8ee: "Personer",
  s49360e6ce199180f: "Ändring av namnet på ett chattrum ändrar det för alla.",
  s4e53b5a018b324d9: "Redigera inlägg...",
  s515e890f5b7dece7: "Lägg till medlemmar",
  s527d43090df3bdb7: "Du är just nu offline.",
  s52caf8c8abd32779: i`Röster på ${0}`,
  s57a6b59f8e17ed4b: "Ersätt befintlig?",
  s57adf424d57c8a0f: "Skicka",
  s588f3ded8091c8c0: "Spela upp inspelning",
  s58aac558ddaa15a3: "Prenumerera",
  s5bb4026da28b7914: "Markera som läst",
  s60320a18282b2b33: "Byt namn",
  s6271883e61d007c2: "Uppladdningsfel",
  s64ef2a6c2dd1d3d1: "Redigera",
  s6acd68c5d25381a5: i`${0} kommentarer`,
  s6e68e284db76e5b4: i`Sedd av ${0} vid ${1}`,
  s70af97de3ad8fb23: "Typ",
  s728c109d24cb2252: "Ladda ner filer",
  s737d13effc0cee9d: "Ingen förhandsvisning tillgänglig :(",
  s78636b92c1a3909c: "Väntande",
  s78789724e789221c: "Storlek",
  s79145f82d32504e5: "Från enhet",
  s7f47cec3e840a432: "Ändrad",
  s8ad15eeb66d528ff: "Välj ett utrymme i Confluence",
  s8b0432eecbd8b034: "Uppdatera",
  s8b4c8439803b5b65: "Redigera inlägg",
  s8db89619f41917b4: "Fäst",
  s8f4be9f086eb530f: "Ångra",
  s9252c3f0ce55297b: "Lägg till filer",
  s94c650bef124bd01: "Stigande",
  s96cf128ca399b6fc: "Gå med i möte",
  s9bfc95548d124b1c: "Reagera",
  s9c4d64a06ba60af0: "Maximera sidopanel",
  s9ebb630d372e4145: "Ta bort",
  s9f5a5f23312798f0: "Medlemmar",
  s9fb1c9e781c38ec2: i` Öppna i ${0}
        `,
  s9ff2ac475c7b07db: "Reaktioner",
  sa51cfa5b38f02434: "Confluence sidväljare",
  sa667dd9e4a8a6750: "Lägg till filer för att komma igång!",
  saae1c70e168b45b4: "Admin",
  sab28965d6b550459: "Inlägget togs bort.",
  saf84ec86139d349e: "Kommentera",
  sb206d032da78e466: "Rutnät",
  sb33fd019a70e1a18: "Omröstning",
  sb357ea19a722d827: "Publicera",
  sb38253b7012e60c5: "Ta bort medlem",
  sb5d079518d9b14e2: "Ta bort stjärna",
  sb5d1c3e0fa747687: "Markera som oläst",
  sbc0cd0b4dfb7dde1: "Lossa",
  sbcf612e1db77bcec: "Sätt som admin",
  sbe2dba1939d68a7a: "Redigera kommentar...",
  sbed0d484327fe0c8: "redigerad",
  sc00a88b90cd60661: "Släng",
  sc16e00a7a8b2fde2: "Tillbaka",
  sc374276841a6c39e: "Versioner är inte tillgängliga för externa filer från molnet.",
  sc65ea2cf2f21a13a: "Zooma ut",
  scb6a9c1a1757adbc: "Du",
  scd9d7826cea1fd2d: "Välj en konversation",
  sd3386a2ef42e80b9: "Ladda ner",
  sd3b60ec2f9fb421b: "Nya meddelanden",
  sd7c7478edbbcced8: "Filhändelser",
  sd98b59251f065471: "Stjärnmärk",
  sdc12d4d35420eeb7: "Kommentarer",
  sdc673e73b5c13aea: "Radera",
  se19e2ed58cd65d6c: "Versioner",
  se2afa9653ced894f: "Välj bild",
  se323ece17b96a4df: "Inga fler personer funna.",
  se725f4eac532d6d0: "Alla uppladningar klara",
  se9beb5e1e43f9764: "Redigera kommentar",
  sea4f08110bb8f15d: "Ta bort",
  sed073ac6112070e7: "Skriv en kommentar...",
  sef49aec68fd1dc66: "Namn",
  sf001ba58cf846564: "Meddelanden",
  sf59f359396914fa2: "Ta bort alla",
  sf60480d4fe3a8e08: i`${0} skriver${1}`,
  sf7a5eea7c80c2137: "Bottar",
  sf863f06a8efefe1e: "Skapa ett inlägg...",
  sf993bb199fefbe04: "Alla",
  sfaacc9c26728c711: "Släpp filer här för att ladda upp.",
  sfef95f1ec987bff3: "Zoom-möte",
  sffa721bb6aa3128d: "Sök..."
}, Q = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
  __proto__: null,
  templates: Z
}, Symbol.toStringTag, { value: "Module" }));
export {
  J as configureLocalization,
  X as localized,
  K as msg,
  i as str,
  Q as svSE
};
