@lingo.dev/_compiler 0.7.18 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/build/{acorn-U6XNAJW3.cjs → acorn-QFXI4BEA.cjs} +1 -1
  2. package/build/{angular-VRWVFJ3P.cjs → angular-OXTGJOFJ.cjs} +1 -1
  3. package/build/{babel-XUIPTQVD.cjs → babel-EJ7OIZP4.cjs} +1 -1
  4. package/build/{chunk-253QCR45.cjs → chunk-AKFJBAG4.cjs} +2 -2
  5. package/build/{chunk-SRWLOKRJ.mjs → chunk-K3VLB5BY.mjs} +6 -6
  6. package/build/{chunk-77OA7KVH.cjs → chunk-NMKWLVJK.cjs} +20 -20
  7. package/build/{estree-4GAWSYZ3.cjs → estree-NGS2AYBH.cjs} +1 -1
  8. package/build/{flow-E755VYYN.mjs → flow-DHPXOK5S.mjs} +8 -8
  9. package/build/{flow-Q7PWYY7R.cjs → flow-RDDDCZAV.cjs} +9 -9
  10. package/build/{glimmer-CMYCELEM.cjs → glimmer-CAMUE4OK.cjs} +35 -35
  11. package/build/{glimmer-E47Q6F77.mjs → glimmer-E3TJQSQ4.mjs} +34 -34
  12. package/build/{graphql-ATU26IOQ.cjs → graphql-YJNPH5D2.cjs} +1 -1
  13. package/build/{html-L366VYHK.cjs → html-TYMOOA3H.cjs} +1 -1
  14. package/build/index.cjs +57 -57
  15. package/build/index.mjs +35 -35
  16. package/build/lingo-turbopack-loader.cjs +4 -4
  17. package/build/lingo-turbopack-loader.mjs +1 -1
  18. package/build/{markdown-VRQCW4QH.cjs → markdown-EW4GGIPV.cjs} +5 -5
  19. package/build/{markdown-5YN6HSRL.mjs → markdown-WJTZKU3V.mjs} +4 -4
  20. package/build/{meriyah-QKHCCSUI.cjs → meriyah-OWUHWYCU.cjs} +1 -1
  21. package/build/{postcss-NNGTIRRJ.mjs → postcss-3TJJTQXP.mjs} +42 -42
  22. package/build/{postcss-PVIIR2IT.cjs → postcss-MQS25GNZ.cjs} +43 -43
  23. package/build/{typescript-VKODJRCW.cjs → typescript-Z5DYTVQY.cjs} +1 -1
  24. package/build/{yaml-6I36QTON.cjs → yaml-FHNA2CVI.cjs} +1 -1
  25. package/package.json +34 -34
@@ -578,7 +578,7 @@ var ps = console;
578
578
  function ms(e5, t = "unexpected unreachable branch") {
579
579
  throw ps.log("unreachable", e5), ps.log(`${t} :: ${JSON.stringify(e5)} (${e5})`), new Error("code reached unreachable");
580
580
  }
581
- var In = function() {
581
+ var In = (function() {
582
582
  var e5 = function(it, d, k, g) {
583
583
  for (k = k || {}, g = it.length; g--; k[it[g]] = d) ;
584
584
  return k;
@@ -767,7 +767,7 @@ Expecting ` + pe.join(", ") + ", got '" + (this.terminals_[O] || O) + "'" : qe =
767
767
  }
768
768
  }
769
769
  return true;
770
- } }, Vs = /* @__PURE__ */ function() {
770
+ } }, Vs = /* @__PURE__ */ (function() {
771
771
  var it = { EOF: 1, parseError: function(k, g) {
772
772
  if (this.yy.parser) this.yy.parser.parseError(k, g);
773
773
  else throw new Error(k);
@@ -957,13 +957,13 @@ Expecting ` + pe.join(", ") + ", got '" + (this.terminals_[O] || O) + "'" : qe =
957
957
  }
958
958
  }, rules: [/^(?:[^\x00]*?(?=(\{\{)))/, /^(?:[^\x00]+)/, /^(?:[^\x00]{2,}?(?=(\{\{|\\\{\{|\\\\\{\{|$)))/, /^(?:\{\{\{\{(?=[^/]))/, /^(?:\{\{\{\{\/[^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=[=}\s\/.])\}\}\}\})/, /^(?:[^\x00]+?(?=(\{\{\{\{)))/, /^(?:[\s\S]*?--(~)?\}\})/, /^(?:\()/, /^(?:\))/, /^(?:\{\{\{\{)/, /^(?:\}\}\}\})/, /^(?:\{\{(~)?>)/, /^(?:\{\{(~)?#>)/, /^(?:\{\{(~)?#\*?)/, /^(?:\{\{(~)?\/)/, /^(?:\{\{(~)?\^\s*(~)?\}\})/, /^(?:\{\{(~)?\s*else\s*(~)?\}\})/, /^(?:\{\{(~)?\^)/, /^(?:\{\{(~)?\s*else\b)/, /^(?:\{\{(~)?\{)/, /^(?:\{\{(~)?&)/, /^(?:\{\{(~)?!--)/, /^(?:\{\{(~)?![\s\S]*?\}\})/, /^(?:\{\{(~)?\*?)/, /^(?:=)/, /^(?:\.\.)/, /^(?:\.(?=([=~}\s\/.)|])))/, /^(?:[\/.])/, /^(?:\s+)/, /^(?:\}(~)?\}\})/, /^(?:(~)?\}\})/, /^(?:"(\\["]|[^"])*")/, /^(?:'(\\[']|[^'])*')/, /^(?:@)/, /^(?:true(?=([~}\s)])))/, /^(?:false(?=([~}\s)])))/, /^(?:undefined(?=([~}\s)])))/, /^(?:null(?=([~}\s)])))/, /^(?:-?[0-9]+(?:\.[0-9]+)?(?=([~}\s)])))/, /^(?:as\s+\|)/, /^(?:\|)/, /^(?:([^\s!"#%-,\.\/;->@\[-\^`\{-~]+(?=([=~}\s\/.)|]))))/, /^(?:\[(\\\]|[^\]])*\])/, /^(?:.)/, /^(?:$)/], conditions: { mu: { rules: [7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44], inclusive: false }, emu: { rules: [2], inclusive: false }, com: { rules: [6], inclusive: false }, raw: { rules: [3, 4, 5], inclusive: false }, INITIAL: { rules: [0, 1, 44], inclusive: true } } };
959
959
  return it;
960
- }();
960
+ })();
961
961
  De.lexer = Vs;
962
962
  function _e() {
963
963
  this.yy = {};
964
964
  }
965
965
  return _e.prototype = De, De.Parser = _e, new _e();
966
- }();
966
+ })();
967
967
  var Se = In;
968
968
  var tr = ["description", "fileName", "lineNumber", "endLineNumber", "message", "name", "number", "stack"];
969
969
  function er(e5, t) {
@@ -1168,7 +1168,7 @@ var Es = { Aacute: "\xC1", aacute: "\xE1", Abreve: "\u0102", abreve: "\u0103", a
1168
1168
  var Gn = /^#[xX]([A-Fa-f0-9]+)$/;
1169
1169
  var Kn = /^#([0-9]+)$/;
1170
1170
  var Wn = /^([A-Za-z0-9]+)$/;
1171
- var or = function() {
1171
+ var or = (function() {
1172
1172
  function e5(t) {
1173
1173
  this.named = t;
1174
1174
  }
@@ -1180,7 +1180,7 @@ var or = function() {
1180
1180
  if (r = t.match(Wn), r) return this.named[r[1]];
1181
1181
  }
1182
1182
  }, e5;
1183
- }();
1183
+ })();
1184
1184
  var jn = /[\t\n\f ]/;
1185
1185
  var Qn = /[A-Za-z]/;
1186
1186
  var Jn = /\r\n?/g;
@@ -1194,7 +1194,7 @@ function $n(e5) {
1194
1194
  return e5.replace(Jn, `
1195
1195
  `);
1196
1196
  }
1197
- var lr = function() {
1197
+ var lr = (function() {
1198
1198
  function e5(t, r, s) {
1199
1199
  s === void 0 && (s = "precompile"), this.delegate = t, this.entityParser = r, this.mode = s, this.state = "beforeData", this.line = -1, this.column = -1, this.input = "", this.index = -1, this.tagNameBuffer = "", this.states = { beforeData: function() {
1200
1200
  var n = this.peek();
@@ -1358,8 +1358,8 @@ var lr = function() {
1358
1358
  var t = this.tagNameBuffer;
1359
1359
  return t === "title" && this.input.substring(this.index, this.index + 8) !== "</title>" || t === "style" && this.input.substring(this.index, this.index + 8) !== "</style>" || t === "script" && this.input.substring(this.index, this.index + 9) !== "</script>";
1360
1360
  }, e5;
1361
- }();
1362
- var so = function() {
1361
+ })();
1362
+ var so = (function() {
1363
1363
  function e5(t, r) {
1364
1364
  r === void 0 && (r = {}), this.options = r, this.token = null, this.startLine = 1, this.startColumn = 0, this.tokens = [], this.tokenizer = new lr(this, t, r.mode), this._currentAttribute = void 0;
1365
1365
  }
@@ -1431,7 +1431,7 @@ var so = function() {
1431
1431
  }, e5.prototype.reportSyntaxError = function(t) {
1432
1432
  this.current().syntaxError = t;
1433
1433
  }, e5;
1434
- }();
1434
+ })();
1435
1435
  var Ne = { Append: 1, TrustingAppend: 2, Comment: 3, Modifier: 4, StrictModifier: 5, Block: 6, StrictBlock: 7, Component: 8, OpenElement: 10, OpenElementWithSplat: 11, FlushElement: 12, CloseElement: 13, StaticAttr: 14, DynamicAttr: 15, ComponentAttr: 16, AttrSplat: 17, Yield: 18, DynamicArg: 20, StaticArg: 21, TrustingDynamicAttr: 22, TrustingComponentAttr: 23, StaticComponentAttr: 24, Debugger: 26, Undefined: 27, Call: 28, Concat: 29, GetSymbol: 30, GetLexicalSymbol: 32, GetStrictKeyword: 31, GetFreeAsComponentOrHelperHead: 35, GetFreeAsHelperHead: 37, GetFreeAsModifierHead: 38, GetFreeAsComponentHead: 39, InElement: 40, If: 41, Each: 42, Let: 44, WithDynamicVars: 45, InvokeComponent: 46, HasBlock: 48, HasBlockParams: 49, Curry: 50, Not: 51, IfInline: 52, GetDynamicVar: 53, Log: 54 };
1436
1436
  function vs(e5) {
1437
1437
  return function(t) {
@@ -1484,7 +1484,7 @@ var Pe = class {
1484
1484
  this._map.set(t, r);
1485
1485
  }
1486
1486
  match(t) {
1487
- let r = function(a) {
1487
+ let r = (function(a) {
1488
1488
  switch (a) {
1489
1489
  case "Broken":
1490
1490
  case "InternalsSynthetic":
@@ -1493,7 +1493,7 @@ var Pe = class {
1493
1493
  default:
1494
1494
  return a;
1495
1495
  }
1496
- }(t), s = [], n = this._map.get(r), i = this._map.get("MATCH_ANY");
1496
+ })(t), s = [], n = this._map.get(r), i = this._map.get("MATCH_ANY");
1497
1497
  return n && s.push(n), i && s.push(i), s;
1498
1498
  }
1499
1499
  constructor() {
@@ -1944,13 +1944,13 @@ function E(e5, t) {
1944
1944
  return c.name = "SyntaxError", c.location = t, c.code = a, c;
1945
1945
  }
1946
1946
  var ii = { Template: ["body"], Block: ["body"], MustacheStatement: ["path", "params", "hash"], BlockStatement: ["path", "params", "hash", "program", "inverse"], ElementModifierStatement: ["path", "params", "hash"], CommentStatement: [], MustacheCommentStatement: [], ElementNode: ["attributes", "modifiers", "children", "comments"], AttrNode: ["value"], TextNode: [], ConcatStatement: ["parts"], SubExpression: ["path", "params", "hash"], PathExpression: [], StringLiteral: [], BooleanLiteral: [], NumberLiteral: [], NullLiteral: [], UndefinedLiteral: [], Hash: ["pairs"], HashPair: ["value"] };
1947
- var Nr = function() {
1947
+ var Nr = (function() {
1948
1948
  function e5(t, r, s, n) {
1949
1949
  let i = Error.call(this, t);
1950
1950
  this.key = n, this.message = t, this.node = r, this.parent = s, i.stack && (this.stack = i.stack);
1951
1951
  }
1952
1952
  return e5.prototype = Object.create(Error.prototype), e5.prototype.constructor = e5, e5;
1953
- }();
1953
+ })();
1954
1954
  function ws(e5, t, r) {
1955
1955
  return new Nr("Cannot remove a node unless it is part of an array", e5, t, r);
1956
1956
  }
@@ -1986,11 +1986,11 @@ function _s(e5) {
1986
1986
  return typeof e5 == "function" ? void 0 : e5.exit;
1987
1987
  }
1988
1988
  function Ae(e5, t) {
1989
- let r, s, n, { node: i, parent: a, parentKey: o } = t, c = function(h, p) {
1989
+ let r, s, n, { node: i, parent: a, parentKey: o } = t, c = (function(h, p) {
1990
1990
  if (h.Program && (p === "Template" && !h.Template || p === "Block" && !h.Block)) return h.Program;
1991
1991
  let m = h[p];
1992
1992
  return m !== void 0 ? m : h.All;
1993
- }(e5, i.type);
1993
+ })(e5, i.type);
1994
1994
  if (c !== void 0 && (r = Ds(c), s = _s(c)), r !== void 0 && (n = r(i, t)), n != null) {
1995
1995
  if (JSON.stringify(i) !== JSON.stringify(n)) return Array.isArray(n) ? (Os(e5, n, a, o), n) : Ae(e5, new zt(n, a, o)) || n;
1996
1996
  n = void 0;
@@ -2006,30 +2006,30 @@ function Ns(e5, t, r) {
2006
2006
  e5[t] = r;
2007
2007
  }
2008
2008
  function oi(e5, t, r, s) {
2009
- let n, i, { node: a } = r, o = function(c, h) {
2009
+ let n, i, { node: a } = r, o = (function(c, h) {
2010
2010
  return c[h];
2011
- }(a, s);
2011
+ })(a, s);
2012
2012
  if (o) {
2013
2013
  if (t !== void 0) {
2014
- let c = function(h, p) {
2014
+ let c = (function(h, p) {
2015
2015
  let m = typeof h != "function" ? h.keys : void 0;
2016
2016
  if (m === void 0) return;
2017
2017
  let S = m[p];
2018
2018
  return S !== void 0 ? S : m.All;
2019
- }(t, s);
2019
+ })(t, s);
2020
2020
  c !== void 0 && (n = Ds(c), i = _s(c));
2021
2021
  }
2022
2022
  if (n !== void 0 && n(a, s) !== void 0) throw Ts(a, s);
2023
2023
  if (Array.isArray(o)) Os(e5, o, r, s);
2024
2024
  else {
2025
2025
  let c = Ae(e5, new zt(o, r, s));
2026
- c !== void 0 && function(h, p, m, S) {
2026
+ c !== void 0 && (function(h, p, m, S) {
2027
2027
  if (S === null) throw ws(m, h, p);
2028
2028
  if (Array.isArray(S)) {
2029
2029
  if (S.length !== 1) throw S.length === 0 ? ws(m, h, p) : ai(m, h, p);
2030
2030
  Ns(h, p, S[0]);
2031
2031
  } else Ns(h, p, S);
2032
- }(a, s, o, c);
2032
+ })(a, s, o, c);
2033
2033
  }
2034
2034
  if (i !== void 0 && i(a, s) !== void 0) throw Ts(a, s);
2035
2035
  }
@@ -2077,10 +2077,10 @@ function ct(e5, t) {
2077
2077
  return f.path({ head: f.head({ original: i, loc: r.sliceStartChars({ chars: i.length }) }), tail: a, loc: T(t || null) });
2078
2078
  }
2079
2079
  }
2080
- let { head: s, tail: n } = function(i, a) {
2080
+ let { head: s, tail: n } = (function(i, a) {
2081
2081
  let [o, ...c] = i.split("."), h = f.head({ original: o, loc: T(a || null) });
2082
2082
  return f.path({ head: h, tail: c, loc: T(a || null) });
2083
- }(e5, r);
2083
+ })(e5, r);
2084
2084
  return f.path({ head: s, tail: n, loc: r });
2085
2085
  }
2086
2086
  function xe(e5, t, r) {
@@ -2169,14 +2169,14 @@ var f = new class {
2169
2169
  return { type: "Template", body: e5, blockParams: t, loc: r };
2170
2170
  }
2171
2171
  mustache({ path: e5, params: t, hash: r, trusting: s, loc: n, strip: i = Ce }) {
2172
- return function({ path: a, params: o, hash: c, trusting: h, strip: p, loc: m }) {
2172
+ return (function({ path: a, params: o, hash: c, trusting: h, strip: p, loc: m }) {
2173
2173
  let S = { type: "MustacheStatement", path: a, params: o, hash: c, trusting: h, strip: p, loc: m };
2174
2174
  return Object.defineProperty(S, "escaped", { enumerable: false, get() {
2175
2175
  return !this.trusting;
2176
2176
  }, set(y) {
2177
2177
  this.trusting = !y;
2178
2178
  } }), S;
2179
- }({ path: e5, params: t, hash: r, trusting: s, strip: i, loc: n });
2179
+ })({ path: e5, params: t, hash: r, trusting: s, strip: i, loc: n });
2180
2180
  }
2181
2181
  block({ path: e5, params: t, hash: r, defaultBlock: s, elseBlock: n = null, loc: i, openStrip: a = Ce, inverseStrip: o = Ce, closeStrip: c = Ce }) {
2182
2182
  return { type: "BlockStatement", path: e5, params: t, hash: r, program: s, inverse: n, loc: i, openStrip: a, inverseStrip: o, closeStrip: c };
@@ -2219,7 +2219,7 @@ var f = new class {
2219
2219
  return { type: "SubExpression", path: e5, params: t, hash: r, loc: s };
2220
2220
  }
2221
2221
  path({ head: e5, tail: t, loc: r }) {
2222
- return function({ head: s, tail: n, loc: i }) {
2222
+ return (function({ head: s, tail: n, loc: i }) {
2223
2223
  let a = { type: "PathExpression", head: s, tail: n, get original() {
2224
2224
  return [this.head.original, ...this.tail].join(".");
2225
2225
  }, set original(o) {
@@ -2238,7 +2238,7 @@ var f = new class {
2238
2238
  } }), Object.defineProperty(a, "data", { enumerable: false, get() {
2239
2239
  return this.head.type === "AtHead";
2240
2240
  } }), a;
2241
- }({ head: e5, tail: t, loc: r });
2241
+ })({ head: e5, tail: t, loc: r });
2242
2242
  }
2243
2243
  head({ original: e5, loc: t }) {
2244
2244
  return e5 === "this" ? this.this({ loc: t }) : e5[0] === "@" ? this.atName({ name: e5, loc: t }) : this.var({ name: e5, loc: t });
@@ -2279,14 +2279,14 @@ var f = new class {
2279
2279
  return { type: "HashPair", key: e5, value: t, loc: r };
2280
2280
  }
2281
2281
  literal({ type: e5, value: t, loc: r }) {
2282
- return function({ type: s, value: n, loc: i }) {
2282
+ return (function({ type: s, value: n, loc: i }) {
2283
2283
  let a = { type: s, value: n, loc: i };
2284
2284
  return Object.defineProperty(a, "original", { enumerable: false, get() {
2285
2285
  return this.value;
2286
2286
  }, set(o) {
2287
2287
  this.value = o;
2288
2288
  } }), a;
2289
- }({ type: e5, value: t, loc: r });
2289
+ })({ type: e5, value: t, loc: r });
2290
2290
  }
2291
2291
  }();
2292
2292
  var Sr = class {
@@ -2436,12 +2436,12 @@ var Er = class extends Sr {
2436
2436
  }
2437
2437
  ContentStatement(t) {
2438
2438
  (function(r, s) {
2439
- let n = s.loc.start.line, i = s.loc.start.column, a = function(o, c) {
2439
+ let n = s.loc.start.line, i = s.loc.start.column, a = (function(o, c) {
2440
2440
  if (c === "") return { lines: o.split(`
2441
2441
  `).length - 1, columns: 0 };
2442
2442
  let [h] = o.split(c), p = h.split(/\n/u), m = p.length - 1;
2443
2443
  return { lines: m, columns: p[m].length };
2444
- }(s.original, s.value);
2444
+ })(s.original, s.value);
2445
2445
  n += a.lines, a.lines ? i = a.columns : i += a.columns, r.line = n, r.column = i;
2446
2446
  })(this.tokenizer, t), this.tokenizer.tokenizePart(t.value), this.tokenizer.flushData();
2447
2447
  }
@@ -2550,9 +2550,9 @@ function pr(e5, t) {
2550
2550
  function fr(e5, t) {
2551
2551
  let { path: r, params: s, hash: n, loc: i } = t;
2552
2552
  if (Bs(r)) {
2553
- let o = `{{${function(c) {
2553
+ let o = `{{${(function(c) {
2554
2554
  return c.type === "UndefinedLiteral" ? "undefined" : JSON.stringify(c.value);
2555
- }(r)}}}`;
2555
+ })(r)}}}`;
2556
2556
  throw E(`In <${e5.name} ... ${o} ..., ${o} is not a valid modifier`, t.loc);
2557
2557
  }
2558
2558
  let a = f.elementModifier({ path: r, params: s, hash: n, loc: i });
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } var _class;require('./chunk-253QCR45.cjs');
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } var _class;require('./chunk-AKFJBAG4.cjs');
2
2
 
3
3
  // ../../node_modules/.pnpm/prettier@3.6.2/node_modules/prettier/plugins/graphql.mjs
4
4
  var Et = Object.defineProperty;
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } var _class; var _class2;require('./chunk-253QCR45.cjs');
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } var _class; var _class2;require('./chunk-AKFJBAG4.cjs');
2
2
 
3
3
  // ../../node_modules/.pnpm/prettier@3.6.2/node_modules/prettier/plugins/html.mjs
4
4
  var on = Object.defineProperty;
package/build/index.cjs CHANGED
@@ -16,10 +16,10 @@
16
16
 
17
17
 
18
18
 
19
- var _chunk77OA7KVHcjs = require('./chunk-77OA7KVH.cjs');
19
+ var _chunkNMKWLVJKcjs = require('./chunk-NMKWLVJK.cjs');
20
20
 
21
21
 
22
- var _chunk253QCR45cjs = require('./chunk-253QCR45.cjs');
22
+ var _chunkAKFJBAG4cjs = require('./chunk-AKFJBAG4.cjs');
23
23
 
24
24
  // src/index.ts
25
25
  var _unplugin = require('unplugin');
@@ -27,7 +27,7 @@ var _unplugin = require('unplugin');
27
27
  // package.json
28
28
  var package_default = {
29
29
  name: "@lingo.dev/_compiler",
30
- version: "0.7.18",
30
+ version: "0.8.0",
31
31
  description: "Lingo.dev Compiler",
32
32
  private: false,
33
33
  publishConfig: {
@@ -60,42 +60,42 @@ var package_default = {
60
60
  author: "",
61
61
  license: "ISC",
62
62
  devDependencies: {
63
- "@types/babel__generator": "^7.6.8",
64
- "@types/babel__traverse": "^7.20.6",
65
- "@types/ini": "^4.1.1",
66
- "@types/lodash": "^4.17.4",
67
- "@types/object-hash": "^3.0.6",
68
- "@types/react": "^18.3.18",
63
+ "@types/babel__generator": "7.27.0",
64
+ "@types/babel__traverse": "7.28.0",
65
+ "@types/ini": "4.1.1",
66
+ "@types/lodash": "4.17.21",
67
+ "@types/object-hash": "3.0.6",
68
+ "@types/react": "19.2.7",
69
69
  next: "15.2.4",
70
- tsup: "^8.3.5",
71
- typescript: "^5.4.5",
72
- vitest: "^2.1.4"
70
+ tsup: "8.5.1",
71
+ typescript: "5.9.3",
72
+ vitest: "4.0.13"
73
73
  },
74
74
  dependencies: {
75
- "@ai-sdk/anthropic": "^1.0.11",
76
- "@ai-sdk/google": "^1.2.19",
77
- "@ai-sdk/groq": "^1.2.3",
78
- "@ai-sdk/mistral": "^1.2.8",
79
- "@ai-sdk/openai": "^1.3.22",
80
- "@babel/generator": "^7.26.5",
81
- "@babel/parser": "^7.26.7",
82
- "@babel/traverse": "^7.27.4",
83
- "@babel/types": "^7.26.7",
75
+ "@ai-sdk/anthropic": "1.2.11",
76
+ "@ai-sdk/google": "1.2.19",
77
+ "@ai-sdk/groq": "1.2.3",
78
+ "@ai-sdk/mistral": "1.2.8",
79
+ "@ai-sdk/openai": "1.3.22",
80
+ "@babel/generator": "7.28.5",
81
+ "@babel/parser": "7.28.5",
82
+ "@babel/traverse": "7.28.5",
83
+ "@babel/types": "7.28.5",
84
84
  "@lingo.dev/_sdk": "workspace:*",
85
85
  "@lingo.dev/_spec": "workspace:*",
86
- "@openrouter/ai-sdk-provider": "^0.7.1",
87
- ai: "^4.2.10",
88
- dedent: "^1.6.0",
89
- dotenv: "^16.4.5",
90
- "fast-xml-parser": "^5.0.8",
91
- ini: "^5.0.0",
92
- lodash: "^4.17.21",
93
- "object-hash": "^3.0.0",
94
- "ollama-ai-provider": "^1.2.0",
95
- unplugin: "^2.1.2",
96
- zod: "^3.25.76",
97
- "posthog-node": "^5.5.1",
98
- "node-machine-id": "^1.1.12"
86
+ "@openrouter/ai-sdk-provider": "0.7.1",
87
+ ai: "4.2.10",
88
+ dedent: "1.7.0",
89
+ dotenv: "16.4.5",
90
+ "fast-xml-parser": "5.3.2",
91
+ ini: "5.0.0",
92
+ lodash: "4.17.21",
93
+ "node-machine-id": "1.1.12",
94
+ "object-hash": "3.0.0",
95
+ "ollama-ai-provider": "1.2.0",
96
+ "posthog-node": "5.14.0",
97
+ unplugin: "2.3.11",
98
+ zod: "3.25.76"
99
99
  },
100
100
  packageManager: "pnpm@9.12.3"
101
101
  };
@@ -141,7 +141,7 @@ async function trackEvent(event, properties) {
141
141
  }
142
142
  }
143
143
  async function getActualId() {
144
- const rc = _chunk77OA7KVHcjs.getRc.call(void 0, );
144
+ const rc = _chunkNMKWLVJKcjs.getRc.call(void 0, );
145
145
  const apiKey = process.env.LINGODOTDEV_API_KEY || _optionalChain([rc, 'optionalAccess', _3 => _3.auth, 'optionalAccess', _4 => _4.apiKey]);
146
146
  const apiUrl = process.env.LINGODOTDEV_API_URL || _optionalChain([rc, 'optionalAccess', _5 => _5.auth, 'optionalAccess', _6 => _6.apiUrl]) || "https://engine.lingo.dev";
147
147
  if (apiKey) {
@@ -169,20 +169,20 @@ async function getActualId() {
169
169
  // src/index.ts
170
170
  var keyCheckers = {
171
171
  groq: {
172
- checkEnv: _chunk77OA7KVHcjs.getGroqKeyFromEnv,
173
- checkRc: _chunk77OA7KVHcjs.getGroqKeyFromRc
172
+ checkEnv: _chunkNMKWLVJKcjs.getGroqKeyFromEnv,
173
+ checkRc: _chunkNMKWLVJKcjs.getGroqKeyFromRc
174
174
  },
175
175
  google: {
176
- checkEnv: _chunk77OA7KVHcjs.getGoogleKeyFromEnv,
177
- checkRc: _chunk77OA7KVHcjs.getGoogleKeyFromRc
176
+ checkEnv: _chunkNMKWLVJKcjs.getGoogleKeyFromEnv,
177
+ checkRc: _chunkNMKWLVJKcjs.getGoogleKeyFromRc
178
178
  },
179
179
  mistral: {
180
- checkEnv: _chunk77OA7KVHcjs.getMistralKeyFromEnv,
181
- checkRc: _chunk77OA7KVHcjs.getMistralKeyFromRc
180
+ checkEnv: _chunkNMKWLVJKcjs.getMistralKeyFromEnv,
181
+ checkRc: _chunkNMKWLVJKcjs.getMistralKeyFromRc
182
182
  },
183
183
  "lingo.dev": {
184
- checkEnv: _chunk77OA7KVHcjs.getLingoDotDevKeyFromEnv,
185
- checkRc: _chunk77OA7KVHcjs.getLingoDotDevKeyFromRc
184
+ checkEnv: _chunkNMKWLVJKcjs.getLingoDotDevKeyFromEnv,
185
+ checkRc: _chunkNMKWLVJKcjs.getLingoDotDevKeyFromRc
186
186
  }
187
187
  };
188
188
  var alreadySentBuildEvent = { value: false };
@@ -198,14 +198,14 @@ function sendBuildEvent(framework, config, isDev) {
198
198
  var unplugin = _unplugin.createUnplugin.call(void 0,
199
199
  (_params, _meta) => {
200
200
  console.log("\u2139\uFE0F Starting Lingo.dev compiler...");
201
- const params = _lodash2.default.defaults(_params, _chunk77OA7KVHcjs.defaultParams);
202
- if (!_chunk77OA7KVHcjs.isRunningInCIOrDocker.call(void 0, )) {
201
+ const params = _lodash2.default.defaults(_params, _chunkNMKWLVJKcjs.defaultParams);
202
+ if (!_chunkNMKWLVJKcjs.isRunningInCIOrDocker.call(void 0, )) {
203
203
  if (params.models === "lingo.dev") {
204
204
  validateLLMKeyDetails(["lingo.dev"]);
205
205
  } else {
206
206
  const configuredProviders = getConfiguredProviders(params.models);
207
207
  validateLLMKeyDetails(configuredProviders);
208
- const invalidLocales = _chunk77OA7KVHcjs.getInvalidLocales.call(void 0,
208
+ const invalidLocales = _chunkNMKWLVJKcjs.getInvalidLocales.call(void 0,
209
209
  params.models,
210
210
  params.sourceLocale,
211
211
  params.targetLocales
@@ -224,7 +224,7 @@ var unplugin = _unplugin.createUnplugin.call(void 0,
224
224
  }
225
225
  }
226
226
  }
227
- _chunk77OA7KVHcjs.LCPCache.ensureDictionaryFile({
227
+ _chunkNMKWLVJKcjs.LCPCache.ensureDictionaryFile({
228
228
  sourceRoot: params.sourceRoot,
229
229
  lingoDir: params.lingoDir
230
230
  });
@@ -232,9 +232,9 @@ var unplugin = _unplugin.createUnplugin.call(void 0,
232
232
  sendBuildEvent("unplugin", params, isDev);
233
233
  return {
234
234
  name: package_default.name,
235
- loadInclude: (id) => !!id.match(_chunk77OA7KVHcjs.LCP_DICTIONARY_FILE_NAME),
235
+ loadInclude: (id) => !!id.match(_chunkNMKWLVJKcjs.LCP_DICTIONARY_FILE_NAME),
236
236
  async load(id) {
237
- const dictionary = await _chunk77OA7KVHcjs.loadDictionary.call(void 0, {
237
+ const dictionary = await _chunkNMKWLVJKcjs.loadDictionary.call(void 0, {
238
238
  resourcePath: id,
239
239
  resourceQuery: "",
240
240
  params: {
@@ -258,7 +258,7 @@ var unplugin = _unplugin.createUnplugin.call(void 0,
258
258
  enforce: "pre",
259
259
  transform(code, id) {
260
260
  try {
261
- const result = _chunk77OA7KVHcjs.transformComponent.call(void 0, {
261
+ const result = _chunkNMKWLVJKcjs.transformComponent.call(void 0, {
262
262
  code,
263
263
  params,
264
264
  resourcePath: id,
@@ -274,7 +274,7 @@ var unplugin = _unplugin.createUnplugin.call(void 0,
274
274
  };
275
275
  }
276
276
  );
277
- var src_default = {
277
+ var index_default = {
278
278
  /**
279
279
  * Initializes Lingo.dev Compiler for Next.js (App Router).
280
280
  *
@@ -300,7 +300,7 @@ var src_default = {
300
300
  next: (compilerParams) => (nextConfig = {}) => {
301
301
  const mergedParams = _lodash2.default.merge(
302
302
  {},
303
- _chunk77OA7KVHcjs.defaultParams,
303
+ _chunkNMKWLVJKcjs.defaultParams,
304
304
  {
305
305
  rsc: true,
306
306
  turbopack: {
@@ -351,7 +351,7 @@ var src_default = {
351
351
  turbopackConfigPath.rules ??= {};
352
352
  const rules = turbopackConfigPath.rules;
353
353
  const lingoGlob = `**/*.{ts,tsx,js,jsx}`;
354
- const lingoLoaderPath = _chunk253QCR45cjs.__require.resolve("./lingo-turbopack-loader.cjs");
354
+ const lingoLoaderPath = _chunkAKFJBAG4cjs.__require.resolve("./lingo-turbopack-loader.cjs");
355
355
  rules[lingoGlob] = {
356
356
  loaders: [
357
357
  {
@@ -411,7 +411,7 @@ var src_default = {
411
411
  vite: (compilerParams) => (config) => {
412
412
  const mergedParams = _lodash2.default.merge(
413
413
  {},
414
- _chunk77OA7KVHcjs.defaultParams,
414
+ _chunkNMKWLVJKcjs.defaultParams,
415
415
  { rsc: false },
416
416
  compilerParams
417
417
  );
@@ -425,7 +425,7 @@ var src_default = {
425
425
  };
426
426
  function getConfiguredProviders(models) {
427
427
  return _lodash2.default.chain(Object.values(models)).map((modelString) => modelString.split(":")[0]).filter(Boolean).uniq().filter(
428
- (providerId) => _chunk77OA7KVHcjs.providerDetails.hasOwnProperty(providerId) && keyCheckers.hasOwnProperty(providerId)
428
+ (providerId) => _chunkNMKWLVJKcjs.providerDetails.hasOwnProperty(providerId) && keyCheckers.hasOwnProperty(providerId)
429
429
  ).value();
430
430
  }
431
431
  function validateLLMKeyDetails(configuredProviders) {
@@ -436,7 +436,7 @@ function validateLLMKeyDetails(configuredProviders) {
436
436
  const missingProviders = [];
437
437
  const foundProviders = [];
438
438
  for (const providerId of configuredProviders) {
439
- const details = _chunk77OA7KVHcjs.providerDetails[providerId];
439
+ const details = _chunkNMKWLVJKcjs.providerDetails[providerId];
440
440
  const checkers = keyCheckers[providerId];
441
441
  if (!details || !checkers) continue;
442
442
  const foundInEnv = !!checkers.checkEnv();
@@ -507,4 +507,4 @@ function validateLLMKeyDetails(configuredProviders) {
507
507
  }
508
508
 
509
509
 
510
- exports.default = src_default;
510
+ exports.default = index_default;
package/build/index.mjs CHANGED
@@ -16,7 +16,7 @@ import {
16
16
  loadDictionary,
17
17
  providerDetails,
18
18
  transformComponent
19
- } from "./chunk-SRWLOKRJ.mjs";
19
+ } from "./chunk-K3VLB5BY.mjs";
20
20
  import {
21
21
  __require
22
22
  } from "./chunk-6BWS3CLP.mjs";
@@ -27,7 +27,7 @@ import { createUnplugin } from "unplugin";
27
27
  // package.json
28
28
  var package_default = {
29
29
  name: "@lingo.dev/_compiler",
30
- version: "0.7.18",
30
+ version: "0.8.0",
31
31
  description: "Lingo.dev Compiler",
32
32
  private: false,
33
33
  publishConfig: {
@@ -60,42 +60,42 @@ var package_default = {
60
60
  author: "",
61
61
  license: "ISC",
62
62
  devDependencies: {
63
- "@types/babel__generator": "^7.6.8",
64
- "@types/babel__traverse": "^7.20.6",
65
- "@types/ini": "^4.1.1",
66
- "@types/lodash": "^4.17.4",
67
- "@types/object-hash": "^3.0.6",
68
- "@types/react": "^18.3.18",
63
+ "@types/babel__generator": "7.27.0",
64
+ "@types/babel__traverse": "7.28.0",
65
+ "@types/ini": "4.1.1",
66
+ "@types/lodash": "4.17.21",
67
+ "@types/object-hash": "3.0.6",
68
+ "@types/react": "19.2.7",
69
69
  next: "15.2.4",
70
- tsup: "^8.3.5",
71
- typescript: "^5.4.5",
72
- vitest: "^2.1.4"
70
+ tsup: "8.5.1",
71
+ typescript: "5.9.3",
72
+ vitest: "4.0.13"
73
73
  },
74
74
  dependencies: {
75
- "@ai-sdk/anthropic": "^1.0.11",
76
- "@ai-sdk/google": "^1.2.19",
77
- "@ai-sdk/groq": "^1.2.3",
78
- "@ai-sdk/mistral": "^1.2.8",
79
- "@ai-sdk/openai": "^1.3.22",
80
- "@babel/generator": "^7.26.5",
81
- "@babel/parser": "^7.26.7",
82
- "@babel/traverse": "^7.27.4",
83
- "@babel/types": "^7.26.7",
75
+ "@ai-sdk/anthropic": "1.2.11",
76
+ "@ai-sdk/google": "1.2.19",
77
+ "@ai-sdk/groq": "1.2.3",
78
+ "@ai-sdk/mistral": "1.2.8",
79
+ "@ai-sdk/openai": "1.3.22",
80
+ "@babel/generator": "7.28.5",
81
+ "@babel/parser": "7.28.5",
82
+ "@babel/traverse": "7.28.5",
83
+ "@babel/types": "7.28.5",
84
84
  "@lingo.dev/_sdk": "workspace:*",
85
85
  "@lingo.dev/_spec": "workspace:*",
86
- "@openrouter/ai-sdk-provider": "^0.7.1",
87
- ai: "^4.2.10",
88
- dedent: "^1.6.0",
89
- dotenv: "^16.4.5",
90
- "fast-xml-parser": "^5.0.8",
91
- ini: "^5.0.0",
92
- lodash: "^4.17.21",
93
- "object-hash": "^3.0.0",
94
- "ollama-ai-provider": "^1.2.0",
95
- unplugin: "^2.1.2",
96
- zod: "^3.25.76",
97
- "posthog-node": "^5.5.1",
98
- "node-machine-id": "^1.1.12"
86
+ "@openrouter/ai-sdk-provider": "0.7.1",
87
+ ai: "4.2.10",
88
+ dedent: "1.7.0",
89
+ dotenv: "16.4.5",
90
+ "fast-xml-parser": "5.3.2",
91
+ ini: "5.0.0",
92
+ lodash: "4.17.21",
93
+ "node-machine-id": "1.1.12",
94
+ "object-hash": "3.0.0",
95
+ "ollama-ai-provider": "1.2.0",
96
+ "posthog-node": "5.14.0",
97
+ unplugin: "2.3.11",
98
+ zod: "3.25.76"
99
99
  },
100
100
  packageManager: "pnpm@9.12.3"
101
101
  };
@@ -274,7 +274,7 @@ var unplugin = createUnplugin(
274
274
  };
275
275
  }
276
276
  );
277
- var src_default = {
277
+ var index_default = {
278
278
  /**
279
279
  * Initializes Lingo.dev Compiler for Next.js (App Router).
280
280
  *
@@ -506,5 +506,5 @@ function validateLLMKeyDetails(configuredProviders) {
506
506
  }
507
507
  }
508
508
  export {
509
- src_default as default
509
+ index_default as default
510
510
  };
@@ -1,8 +1,8 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
3
 
4
- var _chunk77OA7KVHcjs = require('./chunk-77OA7KVH.cjs');
5
- require('./chunk-253QCR45.cjs');
4
+ var _chunkNMKWLVJKcjs = require('./chunk-NMKWLVJK.cjs');
5
+ require('./chunk-AKFJBAG4.cjs');
6
6
 
7
7
  // src/lingo-turbopack-loader.ts
8
8
  async function lingo_turbopack_loader_default(source) {
@@ -10,7 +10,7 @@ async function lingo_turbopack_loader_default(source) {
10
10
  const params = this.getOptions();
11
11
  const isDev = process.env.NODE_ENV !== "production";
12
12
  try {
13
- const dictionary = await _chunk77OA7KVHcjs.loadDictionary.call(void 0, {
13
+ const dictionary = await _chunkNMKWLVJKcjs.loadDictionary.call(void 0, {
14
14
  resourcePath: this.resourcePath,
15
15
  resourceQuery: this.resourceQuery,
16
16
  params,
@@ -22,7 +22,7 @@ async function lingo_turbopack_loader_default(source) {
22
22
  const code = `export default ${JSON.stringify(dictionary, null, 2)};`;
23
23
  return callback(null, code);
24
24
  }
25
- const result = _chunk77OA7KVHcjs.transformComponent.call(void 0, {
25
+ const result = _chunkNMKWLVJKcjs.transformComponent.call(void 0, {
26
26
  code: source,
27
27
  params,
28
28
  resourcePath: this.resourcePath,
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  loadDictionary,
3
3
  transformComponent
4
- } from "./chunk-SRWLOKRJ.mjs";
4
+ } from "./chunk-K3VLB5BY.mjs";
5
5
  import "./chunk-6BWS3CLP.mjs";
6
6
 
7
7
  // src/lingo-turbopack-loader.ts