@let-value/translate-loader 1.0.11 → 1.0.13

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.
package/dist/bun.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"bun.js","names":[],"sources":["../src/bun.ts"],"sourcesContent":["import { type BunPlugin, file } from \"bun\";\nimport * as gettextParser from \"gettext-parser\";\n\nexport default {\n name: \"@let-value/translate-loader\",\n setup(build) {\n build.onLoad({ filter: /\\.po$/ }, async ({ path }) => {\n const raw = await file(path).text();\n const po = gettextParser.po.parse(raw);\n return {\n contents: `export default ${JSON.stringify(po)};`,\n loader: \"js\",\n };\n });\n },\n} satisfies BunPlugin;\n"],"mappings":";;;;AAGA,kBAAe;CACX,MAAM;CACN,MAAM,OAAO;AACT,QAAM,OAAO,EAAE,QAAQ,WAAW,OAAO,EAAE,WAAW;GAClD,MAAM,MAAM,MAAM,KAAK,MAAM;GAC7B,MAAM,KAAK,cAAc,GAAG,MAAM;AAClC,UAAO;IACH,UAAU,kBAAkB,KAAK,UAAU,IAAI;IAC/C,QAAQ"}
1
+ {"version":3,"file":"bun.js","names":[],"sources":["../src/bun.ts"],"sourcesContent":["import { type BunPlugin, file } from \"bun\";\nimport * as gettextParser from \"gettext-parser\";\n\nexport default {\n name: \"@let-value/translate-loader\",\n setup(build) {\n build.onLoad({ filter: /\\.po$/ }, async ({ path }) => {\n const raw = await file(path).text();\n const po = gettextParser.po.parse(raw);\n return {\n contents: `export default ${JSON.stringify(po)};`,\n loader: \"js\",\n };\n });\n },\n} satisfies BunPlugin;\n"],"mappings":";;;;AAGA,kBAAe;CACX,MAAM;CACN,MAAM,OAAO;AACT,QAAM,OAAO,EAAE,QAAQ,SAAS,EAAE,OAAO,EAAE,WAAW;GAClD,MAAM,MAAM,MAAM,KAAK,KAAK,CAAC,MAAM;GACnC,MAAM,KAAK,cAAc,GAAG,MAAM,IAAI;AACtC,UAAO;IACH,UAAU,kBAAkB,KAAK,UAAU,GAAG,CAAC;IAC/C,QAAQ;IACX;IACH;;CAET"}
@@ -1 +1 @@
1
- {"version":3,"file":"src-CYgFATZU.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["import { readFileSync } from \"node:fs\";\nimport * as gettextParser from \"gettext-parser\";\nimport { createUnplugin } from \"unplugin\";\n\nexport const unplugin = createUnplugin(() => ({\n name: \"@let-value/translate-loader\",\n resolveId(id) {\n if (id.endsWith(\".po\")) {\n return id;\n }\n return null;\n },\n load(id) {\n if (!id.endsWith(\".po\")) {\n return null;\n }\n const raw = readFileSync(id);\n const po = gettextParser.po.parse(raw);\n return `export default ${JSON.stringify(po)};`;\n },\n}));\n\nexport const { rollup, vite, webpack, esbuild, rspack } = unplugin;\nexport default unplugin;\n"],"mappings":";;;;;AAIA,MAAa,WAAW,sBAAsB;CAC1C,MAAM;CACN,UAAU,IAAI;AACV,MAAI,GAAG,SAAS,OACZ,QAAO;AAEX,SAAO;;CAEX,KAAK,IAAI;AACL,MAAI,CAAC,GAAG,SAAS,OACb,QAAO;EAEX,MAAM,MAAM,aAAa;EACzB,MAAM,KAAK,cAAc,GAAG,MAAM;AAClC,SAAO,kBAAkB,KAAK,UAAU,IAAI;;;AAIpD,MAAa,EAAE,QAAQ,MAAM,SAAS,SAAS,WAAW;AAC1D,kBAAe"}
1
+ {"version":3,"file":"src-CYgFATZU.js","names":[],"sources":["../src/index.ts"],"sourcesContent":["import { readFileSync } from \"node:fs\";\nimport * as gettextParser from \"gettext-parser\";\nimport { createUnplugin } from \"unplugin\";\n\nexport const unplugin = createUnplugin(() => ({\n name: \"@let-value/translate-loader\",\n resolveId(id) {\n if (id.endsWith(\".po\")) {\n return id;\n }\n return null;\n },\n load(id) {\n if (!id.endsWith(\".po\")) {\n return null;\n }\n const raw = readFileSync(id);\n const po = gettextParser.po.parse(raw);\n return `export default ${JSON.stringify(po)};`;\n },\n}));\n\nexport const { rollup, vite, webpack, esbuild, rspack } = unplugin;\nexport default unplugin;\n"],"mappings":";;;;;AAIA,MAAa,WAAW,sBAAsB;CAC1C,MAAM;CACN,UAAU,IAAI;AACV,MAAI,GAAG,SAAS,MAAM,CAClB,QAAO;AAEX,SAAO;;CAEX,KAAK,IAAI;AACL,MAAI,CAAC,GAAG,SAAS,MAAM,CACnB,QAAO;EAEX,MAAM,MAAM,aAAa,GAAG;EAC5B,MAAM,KAAK,cAAc,GAAG,MAAM,IAAI;AACtC,SAAO,kBAAkB,KAAK,UAAU,GAAG,CAAC;;CAEnD,EAAE;AAEH,MAAa,EAAE,QAAQ,MAAM,SAAS,SAAS,WAAW;AAC1D,kBAAe"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@let-value/translate-loader",
3
- "version": "1.0.11",
3
+ "version": "1.0.13",
4
4
  "type": "module",
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.js",
@@ -58,7 +58,7 @@
58
58
  },
59
59
  "devDependencies": {
60
60
  "@types/gettext-parser": "8.0.0",
61
- "tsdown": "0.14.2",
61
+ "tsdown": "0.15.2",
62
62
  "typescript": "5.9.2"
63
63
  },
64
64
  "scripts": {