msgai-cli 1.0.1 → 1.0.2

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 (2) hide show
  1. package/dist/src/po.js +3 -3
  2. package/package.json +1 -1
package/dist/src/po.js CHANGED
@@ -52,7 +52,7 @@ function parsePoContent(poContent) {
52
52
  return gettext_parser_1.po.parse(Buffer.from(poContent, 'utf8'));
53
53
  }
54
54
  /**
55
- * Returns untranslated entries and their keys in stable order (contexts and msgids sorted).
55
+ * Returns untranslated entries and their keys in the order they appear in the original PO file (parser order).
56
56
  * Skips the header (msgid "").
57
57
  * By default skips fuzzy entries; set includeFuzzy to include them (with empty msgstr for the request).
58
58
  */
@@ -61,12 +61,12 @@ function getEntriesToTranslate(parsedPo, options) {
61
61
  const entries = [];
62
62
  const keys = [];
63
63
  const translations = parsedPo.translations;
64
- const contextNames = Object.keys(translations).sort();
64
+ const contextNames = Object.keys(translations);
65
65
  for (const context of contextNames) {
66
66
  const contextEntries = translations[context];
67
67
  if (contextEntries == null)
68
68
  continue;
69
- const msgids = Object.keys(contextEntries).sort();
69
+ const msgids = Object.keys(contextEntries);
70
70
  for (const msgid of msgids) {
71
71
  if (msgid === '')
72
72
  continue;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "msgai-cli",
3
- "version": "1.0.1",
3
+ "version": "1.0.2",
4
4
  "description": "CLI that automatically translates all untranslated strings in gettext (.po) files using AI (LLM)",
5
5
  "main": "dist/src/cli/index.js",
6
6
  "bin": {