@intlayer/engine 9.5.2 → 9.5.4-canary.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 (132) hide show
  1. package/README.md +9 -9
  2. package/dist/assets/initConfig/templates/cjs.txt +0 -4
  3. package/dist/assets/initConfig/templates/json.txt +0 -4
  4. package/dist/assets/initConfig/templates/mjs.txt +0 -4
  5. package/dist/assets/initConfig/templates/ts.txt +0 -4
  6. package/dist/cjs/_virtual/_utils_asset.cjs +1 -1
  7. package/dist/cjs/build.cjs +2 -2
  8. package/dist/cjs/cleanOutputDir.cjs +1 -1
  9. package/dist/cjs/cleanRemovedContentDeclaration.cjs +37 -20
  10. package/dist/cjs/cleanRemovedContentDeclaration.cjs.map +1 -1
  11. package/dist/cjs/cli.cjs +2 -2
  12. package/dist/cjs/createDictionaryEntryPoint/getBuiltDictionariesPath.cjs +2 -2
  13. package/dist/cjs/createDictionaryEntryPoint/getBuiltDynamicDictionariesPath.cjs +2 -2
  14. package/dist/cjs/createDictionaryEntryPoint/getBuiltFetchDictionariesPath.cjs +2 -2
  15. package/dist/cjs/createDictionaryEntryPoint/getBuiltRemoteDictionariesPath.cjs +2 -2
  16. package/dist/cjs/createDictionaryEntryPoint/getBuiltUnmergedDictionariesPath.cjs +2 -2
  17. package/dist/cjs/createType/createModuleAugmentation.cjs +2 -2
  18. package/dist/cjs/docReview/index.cjs +4 -4
  19. package/dist/cjs/docReview/pipeline.cjs +2 -2
  20. package/dist/cjs/docReview/reviewReport.cjs +1 -1
  21. package/dist/cjs/filterInvalidDictionaries.cjs +1 -1
  22. package/dist/cjs/handleAdditionalContentDeclarationFile.cjs +1 -1
  23. package/dist/cjs/handleContentDeclarationFileChange.cjs +4 -4
  24. package/dist/cjs/handleContentDeclarationFileMoved.cjs +1 -1
  25. package/dist/cjs/handleUnlinkedContentDeclarationFile.cjs +1 -1
  26. package/dist/cjs/init/cms.cjs +2 -2
  27. package/dist/cjs/init/frameworkSetup/nextAppRouter/index.cjs +1 -1
  28. package/dist/cjs/init/frameworkSetup/tanstackStart/index.cjs +1 -1
  29. package/dist/cjs/init/index.cjs +2 -2
  30. package/dist/cjs/init/utils/fileSystem.cjs +1 -1
  31. package/dist/cjs/init/utils/githubActions.cjs +1 -1
  32. package/dist/cjs/init/utils/nextCompilerBabel.cjs +1 -1
  33. package/dist/cjs/init/utils/packageManager.cjs +1 -1
  34. package/dist/cjs/installLSP.cjs +1 -1
  35. package/dist/cjs/installMCP/installMCP.cjs +1 -1
  36. package/dist/cjs/installSkills/index.cjs +1 -1
  37. package/dist/cjs/listDictionariesPath.cjs +1 -1
  38. package/dist/cjs/listGitFiles.cjs +2 -2
  39. package/dist/cjs/listProjects.cjs +1 -1
  40. package/dist/cjs/loadDictionaries/getIntlayerBundle.cjs +1 -1
  41. package/dist/cjs/loadDictionaries/loadContentDeclaration.cjs +1 -1
  42. package/dist/cjs/loadDictionaries/loadDictionaries.cjs +1 -1
  43. package/dist/cjs/loadDictionaries/loadRemoteDictionaries.cjs +2 -2
  44. package/dist/cjs/loadDictionaries/loadRemoteDictionaries.cjs.map +1 -1
  45. package/dist/cjs/loadDictionaries/log.cjs +2 -2
  46. package/dist/cjs/logConfigDetails.cjs +3 -3
  47. package/dist/cjs/logConfigDetails.cjs.map +1 -1
  48. package/dist/cjs/prepareIntlayer.cjs +3 -3
  49. package/dist/cjs/scan/index.cjs +1 -1
  50. package/dist/cjs/scan/scanWebsite.cjs +2 -2
  51. package/dist/cjs/syncPluginKit/createFileAdapter.cjs +1 -1
  52. package/dist/cjs/utils/autoDecorateContent.cjs +5 -5
  53. package/dist/cjs/utils/autoDecorateContent.cjs.map +1 -1
  54. package/dist/cjs/utils/buildComponentFilesList.cjs +2 -2
  55. package/dist/cjs/utils/contentWatcherLock.cjs +2 -2
  56. package/dist/cjs/utils/formatter.cjs +1 -1
  57. package/dist/cjs/utils/readDictionariesFromDisk.cjs +1 -1
  58. package/dist/cjs/utils/runOnce.cjs +1 -1
  59. package/dist/cjs/utils/runParallel/pidTree.cjs +1 -1
  60. package/dist/cjs/utils/withFileLock.cjs +1 -1
  61. package/dist/cjs/watcher.cjs +5 -5
  62. package/dist/cjs/writeContentDeclaration/processContentDeclarationContent.cjs +1 -1
  63. package/dist/cjs/writeContentDeclaration/writeContentDeclaration.cjs +1 -1
  64. package/dist/cjs/writeContentDeclaration/writeJSFile.cjs +1 -1
  65. package/dist/cjs/writeFileIfChanged.cjs +1 -1
  66. package/dist/esm/_virtual/_utils_asset.mjs +1 -1
  67. package/dist/esm/build.mjs +2 -2
  68. package/dist/esm/cleanOutputDir.mjs +1 -1
  69. package/dist/esm/cleanRemovedContentDeclaration.mjs +37 -20
  70. package/dist/esm/cleanRemovedContentDeclaration.mjs.map +1 -1
  71. package/dist/esm/cli.mjs +2 -2
  72. package/dist/esm/createDictionaryEntryPoint/getBuiltDictionariesPath.mjs +2 -2
  73. package/dist/esm/createDictionaryEntryPoint/getBuiltDynamicDictionariesPath.mjs +2 -2
  74. package/dist/esm/createDictionaryEntryPoint/getBuiltFetchDictionariesPath.mjs +2 -2
  75. package/dist/esm/createDictionaryEntryPoint/getBuiltRemoteDictionariesPath.mjs +2 -2
  76. package/dist/esm/createDictionaryEntryPoint/getBuiltUnmergedDictionariesPath.mjs +2 -2
  77. package/dist/esm/createType/createModuleAugmentation.mjs +1 -1
  78. package/dist/esm/docReview/index.mjs +4 -4
  79. package/dist/esm/docReview/pipeline.mjs +2 -2
  80. package/dist/esm/docReview/reviewReport.mjs +1 -1
  81. package/dist/esm/filterInvalidDictionaries.mjs +1 -1
  82. package/dist/esm/handleAdditionalContentDeclarationFile.mjs +1 -1
  83. package/dist/esm/handleContentDeclarationFileChange.mjs +4 -4
  84. package/dist/esm/handleContentDeclarationFileMoved.mjs +1 -1
  85. package/dist/esm/handleUnlinkedContentDeclarationFile.mjs +1 -1
  86. package/dist/esm/init/cms.mjs +1 -1
  87. package/dist/esm/init/frameworkSetup/nextAppRouter/index.mjs +1 -1
  88. package/dist/esm/init/frameworkSetup/tanstackStart/index.mjs +1 -1
  89. package/dist/esm/init/index.mjs +1 -1
  90. package/dist/esm/init/utils/fileSystem.mjs +1 -1
  91. package/dist/esm/init/utils/githubActions.mjs +1 -1
  92. package/dist/esm/init/utils/nextCompilerBabel.mjs +1 -1
  93. package/dist/esm/init/utils/packageManager.mjs +1 -1
  94. package/dist/esm/installLSP.mjs +1 -1
  95. package/dist/esm/installMCP/installMCP.mjs +1 -1
  96. package/dist/esm/installSkills/index.mjs +1 -1
  97. package/dist/esm/listDictionariesPath.mjs +1 -1
  98. package/dist/esm/listGitFiles.mjs +2 -2
  99. package/dist/esm/listProjects.mjs +1 -1
  100. package/dist/esm/loadDictionaries/getIntlayerBundle.mjs +1 -1
  101. package/dist/esm/loadDictionaries/loadContentDeclaration.mjs +1 -1
  102. package/dist/esm/loadDictionaries/loadDictionaries.mjs +1 -1
  103. package/dist/esm/loadDictionaries/loadRemoteDictionaries.mjs +1 -1
  104. package/dist/esm/loadDictionaries/loadRemoteDictionaries.mjs.map +1 -1
  105. package/dist/esm/loadDictionaries/log.mjs +1 -1
  106. package/dist/esm/logConfigDetails.mjs +3 -3
  107. package/dist/esm/logConfigDetails.mjs.map +1 -1
  108. package/dist/esm/prepareIntlayer.mjs +2 -2
  109. package/dist/esm/scan/index.mjs +1 -1
  110. package/dist/esm/scan/scanWebsite.mjs +2 -2
  111. package/dist/esm/syncPluginKit/createFileAdapter.mjs +1 -1
  112. package/dist/esm/utils/autoDecorateContent.mjs +5 -5
  113. package/dist/esm/utils/autoDecorateContent.mjs.map +1 -1
  114. package/dist/esm/utils/buildComponentFilesList.mjs +1 -1
  115. package/dist/esm/utils/contentWatcherLock.mjs +2 -2
  116. package/dist/esm/utils/formatter.mjs +1 -1
  117. package/dist/esm/utils/readDictionariesFromDisk.mjs +1 -1
  118. package/dist/esm/utils/runOnce.mjs +1 -1
  119. package/dist/esm/utils/runParallel/pidTree.mjs +1 -1
  120. package/dist/esm/utils/withFileLock.mjs +1 -1
  121. package/dist/esm/watcher.mjs +4 -4
  122. package/dist/esm/writeContentDeclaration/processContentDeclarationContent.mjs +1 -1
  123. package/dist/esm/writeContentDeclaration/writeContentDeclaration.mjs +1 -1
  124. package/dist/esm/writeContentDeclaration/writeJSFile.mjs +1 -1
  125. package/dist/esm/writeFileIfChanged.mjs +1 -1
  126. package/dist/types/cleanRemovedContentDeclaration.d.ts.map +1 -1
  127. package/dist/types/formatDictionary.d.ts +2 -3
  128. package/dist/types/formatDictionary.d.ts.map +1 -1
  129. package/dist/types/logConfigDetails.d.ts.map +1 -1
  130. package/dist/types/utils/autoDecorateContent.d.ts.map +1 -1
  131. package/package.json +10 -11
  132. package/dist/types/intlayer/dist/types/index.d.ts +0 -14
@@ -1,9 +1,9 @@
1
1
  import { formatPath } from "./utils/formatter.mjs";
2
2
  import { runOnce } from "./utils/runOnce.mjs";
3
3
  import { join, relative } from "node:path";
4
- import { colorize, colorizePath, getAppLogger, x } from "@intlayer/config/logger";
5
- import { getConfigurationAndFilePath, intlayerConfigSchema } from "@intlayer/config/node";
6
4
  import * as ANSIColors from "@intlayer/config/colors";
5
+ import { colorize, colorizePath, getAppLogger, x } from "@intlayer/config/logger";
6
+ import { getConfigurationAndFilePath, intlayerConfigSchema, intlayerConfigSchemaParseContext } from "@intlayer/config/node";
7
7
  import { getEnvFilePath } from "@intlayer/config/env";
8
8
 
9
9
  //#region src/logConfigDetails.ts
@@ -21,7 +21,7 @@ const logConfigDetails = (options) => {
21
21
  } else appLogger(`Multiple configuration files found, using ${formatPath(relativeOutputPath)}.`, { isVerbose: true });
22
22
  }
23
23
  if (customConfiguration) {
24
- const validation = intlayerConfigSchema.safeParse(customConfiguration);
24
+ const validation = intlayerConfigSchema.safeParse(customConfiguration, intlayerConfigSchemaParseContext);
25
25
  if (!validation.success) {
26
26
  const errorMessages = validation.error.issues.map((error) => {
27
27
  return `${colorizePath(` - ${error.path.join(".")}:`)} ${colorize(error.message, ANSIColors.GREY_DARK)}`;
@@ -1 +1 @@
1
- {"version":3,"file":"logConfigDetails.mjs","names":[],"sources":["../../src/logConfigDetails.ts"],"sourcesContent":["import { join, relative } from 'node:path';\nimport * as ANSIColors from '@intlayer/config/colors';\nimport { getEnvFilePath } from '@intlayer/config/env';\nimport {\n colorize,\n colorizePath,\n getAppLogger,\n x,\n} from '@intlayer/config/logger';\nimport {\n type GetConfigurationOptions,\n getConfigurationAndFilePath,\n intlayerConfigSchema,\n} from '@intlayer/config/node';\nimport { formatPath, runOnce } from './utils';\n\nexport const logConfigDetails = (options?: GetConfigurationOptions) => {\n const {\n configuration,\n customConfiguration,\n numCustomConfiguration,\n configurationFilePath,\n } = getConfigurationAndFilePath(options);\n const appLogger = getAppLogger(configuration);\n\n runOnce(\n join(\n configuration.system.baseDir,\n '.intlayer',\n 'cache',\n 'intlayer-config-locaded.lock'\n ),\n () => {\n if (numCustomConfiguration === 0) {\n appLogger(\n 'Configuration file not found, using default configuration.',\n {\n isVerbose: true,\n }\n );\n } else {\n const baseDir = configuration.system.baseDir;\n const relativeOutputPath = relative(baseDir, configurationFilePath!);\n\n if (numCustomConfiguration === 1) {\n const dotEnvFilePath = getEnvFilePath(options?.env, options?.envFile);\n\n appLogger(\n `Configuration loaded ${formatPath(relativeOutputPath)}${dotEnvFilePath ? ` - Env: ${formatPath(dotEnvFilePath)}` : ''}`,\n {\n isVerbose: true,\n }\n );\n } else {\n appLogger(\n `Multiple configuration files found, using ${formatPath(relativeOutputPath)}.`,\n {\n isVerbose: true,\n }\n );\n }\n }\n\n if (customConfiguration) {\n const validation = intlayerConfigSchema.safeParse(customConfiguration);\n\n if (!validation.success) {\n const errorMessages = validation.error.issues\n .map((error) => {\n const path = colorizePath(` - ${error.path.join('.')}:`);\n const message = colorize(error.message, ANSIColors.GREY_DARK);\n return `${path} ${message}`;\n })\n .join('\\n');\n const errorMessage = `${x} Invalid configuration:\\n${errorMessages}`;\n\n appLogger(errorMessage);\n }\n\n if (customConfiguration.build?.importMode) {\n appLogger(\n `${colorize('build.importMode', ANSIColors.BLUE)} is deprecated, use ${colorize('dictionary.importMode', ANSIColors.BLUE)} instead`\n );\n }\n if (customConfiguration.compiler?.transformPattern) {\n appLogger(\n `${colorize('compiler.transformPattern', ANSIColors.BLUE)} is deprecated, use ${colorize('build.traversePattern', ANSIColors.BLUE)} instead`\n );\n }\n if (customConfiguration.compiler?.excludePattern) {\n appLogger(\n `${colorize('compiler.excludePattern', ANSIColors.BLUE)} is deprecated, use ${colorize('build.traversePattern', ANSIColors.BLUE)} instead`\n );\n }\n }\n },\n {\n cacheTimeoutMs: 1000 * 60, // 1 minute\n }\n );\n};\n"],"mappings":";;;;;;;;;AAgBA,MAAa,oBAAoB,YAAsC;CACrE,MAAM,EACJ,eACA,qBACA,wBACA,0BACE,4BAA4B,OAAO;CACvC,MAAM,YAAY,aAAa,aAAa;CAE5C,QACE,KACE,cAAc,OAAO,SACrB,aACA,SACA,8BACF,SACM;EACJ,IAAI,2BAA2B,GAC7B,UACE,8DACA,EACE,WAAW,KACb,CACF;OACK;GACL,MAAM,UAAU,cAAc,OAAO;GACrC,MAAM,qBAAqB,SAAS,SAAS,qBAAsB;GAEnE,IAAI,2BAA2B,GAAG;IAChC,MAAM,iBAAiB,eAAe,SAAS,KAAK,SAAS,OAAO;IAEpE,UACE,wBAAwB,WAAW,kBAAkB,IAAI,iBAAiB,WAAW,WAAW,cAAc,MAAM,MACpH,EACE,WAAW,KACb,CACF;GACF,OACE,UACE,6CAA6C,WAAW,kBAAkB,EAAE,IAC5E,EACE,WAAW,KACb,CACF;EAEJ;EAEA,IAAI,qBAAqB;GACvB,MAAM,aAAa,qBAAqB,UAAU,mBAAmB;GAErE,IAAI,CAAC,WAAW,SAAS;IACvB,MAAM,gBAAgB,WAAW,MAAM,OACpC,KAAK,UAAU;KAGd,OAAO,GAFM,aAAa,MAAM,MAAM,KAAK,KAAK,GAAG,EAAE,EAExC,EAAE,GADC,SAAS,MAAM,SAAS,WAAW,SAC3B;IAC1B,CAAC,CAAC,CACD,KAAK,IAAI;IACZ,MAAM,eAAe,GAAG,EAAE,2BAA2B;IAErD,UAAU,YAAY;GACxB;GAEA,IAAI,oBAAoB,OAAO,YAC7B,UACE,GAAG,SAAS,oBAAoB,WAAW,IAAI,EAAE,sBAAsB,SAAS,yBAAyB,WAAW,IAAI,EAAE,SAC5H;GAEF,IAAI,oBAAoB,UAAU,kBAChC,UACE,GAAG,SAAS,6BAA6B,WAAW,IAAI,EAAE,sBAAsB,SAAS,yBAAyB,WAAW,IAAI,EAAE,SACrI;GAEF,IAAI,oBAAoB,UAAU,gBAChC,UACE,GAAG,SAAS,2BAA2B,WAAW,IAAI,EAAE,sBAAsB,SAAS,yBAAyB,WAAW,IAAI,EAAE,SACnI;EAEJ;CACF,GACA,EACE,gBAAgB,IAClB,CACF;AACF"}
1
+ {"version":3,"file":"logConfigDetails.mjs","names":[],"sources":["../../src/logConfigDetails.ts"],"sourcesContent":["import { join, relative } from 'node:path';\nimport * as ANSIColors from '@intlayer/config/colors';\nimport { getEnvFilePath } from '@intlayer/config/env';\nimport {\n colorize,\n colorizePath,\n getAppLogger,\n x,\n} from '@intlayer/config/logger';\nimport {\n type GetConfigurationOptions,\n getConfigurationAndFilePath,\n intlayerConfigSchema,\n intlayerConfigSchemaParseContext,\n} from '@intlayer/config/node';\nimport { formatPath, runOnce } from './utils';\n\nexport const logConfigDetails = (options?: GetConfigurationOptions) => {\n const {\n configuration,\n customConfiguration,\n numCustomConfiguration,\n configurationFilePath,\n } = getConfigurationAndFilePath(options);\n const appLogger = getAppLogger(configuration);\n\n runOnce(\n join(\n configuration.system.baseDir,\n '.intlayer',\n 'cache',\n 'intlayer-config-locaded.lock'\n ),\n () => {\n if (numCustomConfiguration === 0) {\n appLogger(\n 'Configuration file not found, using default configuration.',\n {\n isVerbose: true,\n }\n );\n } else {\n const baseDir = configuration.system.baseDir;\n const relativeOutputPath = relative(baseDir, configurationFilePath!);\n\n if (numCustomConfiguration === 1) {\n const dotEnvFilePath = getEnvFilePath(options?.env, options?.envFile);\n\n appLogger(\n `Configuration loaded ${formatPath(relativeOutputPath)}${dotEnvFilePath ? ` - Env: ${formatPath(dotEnvFilePath)}` : ''}`,\n {\n isVerbose: true,\n }\n );\n } else {\n appLogger(\n `Multiple configuration files found, using ${formatPath(relativeOutputPath)}.`,\n {\n isVerbose: true,\n }\n );\n }\n }\n\n if (customConfiguration) {\n const validation = intlayerConfigSchema.safeParse(\n customConfiguration,\n intlayerConfigSchemaParseContext\n );\n\n if (!validation.success) {\n const errorMessages = validation.error.issues\n .map((error) => {\n const path = colorizePath(` - ${error.path.join('.')}:`);\n const message = colorize(error.message, ANSIColors.GREY_DARK);\n return `${path} ${message}`;\n })\n .join('\\n');\n const errorMessage = `${x} Invalid configuration:\\n${errorMessages}`;\n\n appLogger(errorMessage);\n }\n\n if (customConfiguration.build?.importMode) {\n appLogger(\n `${colorize('build.importMode', ANSIColors.BLUE)} is deprecated, use ${colorize('dictionary.importMode', ANSIColors.BLUE)} instead`\n );\n }\n if (customConfiguration.compiler?.transformPattern) {\n appLogger(\n `${colorize('compiler.transformPattern', ANSIColors.BLUE)} is deprecated, use ${colorize('build.traversePattern', ANSIColors.BLUE)} instead`\n );\n }\n if (customConfiguration.compiler?.excludePattern) {\n appLogger(\n `${colorize('compiler.excludePattern', ANSIColors.BLUE)} is deprecated, use ${colorize('build.traversePattern', ANSIColors.BLUE)} instead`\n );\n }\n }\n },\n {\n cacheTimeoutMs: 1000 * 60, // 1 minute\n }\n );\n};\n"],"mappings":";;;;;;;;;AAiBA,MAAa,oBAAoB,YAAsC;CACrE,MAAM,EACJ,eACA,qBACA,wBACA,0BACE,4BAA4B,OAAO;CACvC,MAAM,YAAY,aAAa,aAAa;CAE5C,QACE,KACE,cAAc,OAAO,SACrB,aACA,SACA,8BACF,SACM;EACJ,IAAI,2BAA2B,GAC7B,UACE,8DACA,EACE,WAAW,KACb,CACF;OACK;GACL,MAAM,UAAU,cAAc,OAAO;GACrC,MAAM,qBAAqB,SAAS,SAAS,qBAAsB;GAEnE,IAAI,2BAA2B,GAAG;IAChC,MAAM,iBAAiB,eAAe,SAAS,KAAK,SAAS,OAAO;IAEpE,UACE,wBAAwB,WAAW,kBAAkB,IAAI,iBAAiB,WAAW,WAAW,cAAc,MAAM,MACpH,EACE,WAAW,KACb,CACF;GACF,OACE,UACE,6CAA6C,WAAW,kBAAkB,EAAE,IAC5E,EACE,WAAW,KACb,CACF;EAEJ;EAEA,IAAI,qBAAqB;GACvB,MAAM,aAAa,qBAAqB,UACtC,qBACA,gCACF;GAEA,IAAI,CAAC,WAAW,SAAS;IACvB,MAAM,gBAAgB,WAAW,MAAM,OACpC,KAAK,UAAU;KAGd,OAAO,GAFM,aAAa,MAAM,MAAM,KAAK,KAAK,GAAG,EAAE,EAExC,EAAE,GADC,SAAS,MAAM,SAAS,WAAW,SAC3B;IAC1B,CAAC,CAAC,CACD,KAAK,IAAI;IACZ,MAAM,eAAe,GAAG,EAAE,2BAA2B;IAErD,UAAU,YAAY;GACxB;GAEA,IAAI,oBAAoB,OAAO,YAC7B,UACE,GAAG,SAAS,oBAAoB,WAAW,IAAI,EAAE,sBAAsB,SAAS,yBAAyB,WAAW,IAAI,EAAE,SAC5H;GAEF,IAAI,oBAAoB,UAAU,kBAChC,UACE,GAAG,SAAS,6BAA6B,WAAW,IAAI,EAAE,sBAAsB,SAAS,yBAAyB,WAAW,IAAI,EAAE,SACrI;GAEF,IAAI,oBAAoB,UAAU,gBAChC,UACE,GAAG,SAAS,2BAA2B,WAAW,IAAI,EAAE,sBAAsB,SAAS,yBAAyB,WAAW,IAAI,EAAE,SACnI;EAEJ;CACF,GACA,EACE,gBAAgB,IAClB,CACF;AACF"}
@@ -1,5 +1,5 @@
1
- import { createDictionaryEntryPoint } from "./createDictionaryEntryPoint/createDictionaryEntryPoint.mjs";
2
1
  import { buildDictionary } from "./buildIntlayerDictionary/buildIntlayerDictionary.mjs";
2
+ import { createDictionaryEntryPoint } from "./createDictionaryEntryPoint/createDictionaryEntryPoint.mjs";
3
3
  import { runOnce } from "./utils/runOnce.mjs";
4
4
  import { createModuleAugmentation } from "./createType/createModuleAugmentation.mjs";
5
5
  import { createTypes } from "./createType/createType.mjs";
@@ -10,9 +10,9 @@ import { cleanOutputDir } from "./cleanOutputDir.mjs";
10
10
  import { isCachedConfigurationUpToDate, writeConfiguration } from "./writeConfiguration/index.mjs";
11
11
  import { stat } from "node:fs/promises";
12
12
  import { join } from "node:path";
13
+ import * as ANSIColors from "@intlayer/config/colors";
13
14
  import { colorize, getAppLogger } from "@intlayer/config/logger";
14
15
  import { cacheDisk } from "@intlayer/config/utils";
15
- import * as ANSIColors from "@intlayer/config/colors";
16
16
  import packageJson from "@intlayer/config/package.json" with { type: "json" };
17
17
 
18
18
  //#region src/prepareIntlayer.ts
@@ -1,5 +1,5 @@
1
- import { mutateScore, scoreRecord, toScorePercent } from "./calculateScore.mjs";
2
1
  import { byteLength, extractAnchors, extractHreflangs, extractHtmlDir, extractHtmlLang, extractMetaDescription, extractOgImage, extractScriptUrls, extractTitle, extractVisibleTextStrings, hasCanonical } from "./parseHtml.mjs";
2
+ import { mutateScore, scoreRecord, toScorePercent } from "./calculateScore.mjs";
3
3
  import { analyzeBundleContent } from "./analyzeBundleContent.mjs";
4
4
  import { checkBundleContent, checkCanonical, checkHtmlAttributes, checkLinguisticStructure, checkRobots, checkSitemap, checkUrlStructure, formatSize } from "./checks.mjs";
5
5
  import { scanWebsite } from "./scanWebsite.mjs";
@@ -1,8 +1,8 @@
1
- import { mutateScore, toScorePercent } from "./calculateScore.mjs";
2
1
  import { byteLength, extractAnchors, extractScriptUrls } from "./parseHtml.mjs";
2
+ import { mutateScore, toScorePercent } from "./calculateScore.mjs";
3
3
  import { checkBundleContent, checkCanonical, checkHtmlAttributes, checkLinguisticStructure, checkRobots, checkSitemap, checkUrlStructure } from "./checks.mjs";
4
- import { colorize, logger } from "@intlayer/config/logger";
5
4
  import { GREY, GREY_LIGHT } from "@intlayer/config/colors";
5
+ import { colorize, logger } from "@intlayer/config/logger";
6
6
 
7
7
  //#region src/scan/scanWebsite.ts
8
8
  const DEFAULT_USER_AGENT = "Mozilla/5.0 (compatible; IntlayerScanBot/1.0; +https://intlayer.org)";
@@ -3,8 +3,8 @@ import { extractKeyAndLocaleFromPath } from "./extractKeyAndLocaleFromPath.mjs";
3
3
  import { buildFilePathPatternContext } from "./filePathPatternHelpers.mjs";
4
4
  import { mkdir, readFile } from "node:fs/promises";
5
5
  import { dirname, isAbsolute, resolve } from "node:path";
6
- import fg from "fast-glob";
7
6
  import { parseFilePathPattern } from "@intlayer/config/utils";
7
+ import fg from "fast-glob";
8
8
 
9
9
  //#region src/syncPluginKit/createFileAdapter.ts
10
10
  /**
@@ -56,13 +56,13 @@ const autoDecorateContent = (content, options = true) => {
56
56
  if (options === false) return content;
57
57
  const { markdown = true, html: htmlOption = true, insertion = true } = typeof options === "object" ? options : {};
58
58
  if (typeof content === "string") {
59
- if (markdown && isMarkdown(content)) return {
59
+ const withInsertion = (node) => insertion && isInsertion(content) ? insert(node) : node;
60
+ if (markdown && isMarkdown(content)) return withInsertion({
60
61
  ...md(content),
61
62
  metadata: getMarkdownMetadata(content)
62
- };
63
- if (htmlOption && isHTML(content)) return html(content);
64
- if (insertion && isInsertion(content)) return insert(content);
65
- return content;
63
+ });
64
+ if (htmlOption && isHTML(content)) return withInsertion(html(content));
65
+ return withInsertion(content);
66
66
  }
67
67
  if (Array.isArray(content)) return content.map((item) => autoDecorateContent(item, options));
68
68
  if (content && typeof content === "object") {
@@ -1 +1 @@
1
- {"version":3,"file":"autoDecorateContent.mjs","names":[],"sources":["../../../src/utils/autoDecorateContent.ts"],"sourcesContent":["import { getMarkdownMetadata } from '@intlayer/core/markdown';\nimport {\n getInsertionValues,\n html,\n insert,\n md,\n} from '@intlayer/core/transpiler';\nimport * as NodeTypes from '@intlayer/types/nodeType';\n\n/**\n * Check if a string is a markdown string\n */\nconst isMarkdown = (str: string): boolean => {\n // Check for common markdown indicators\n const patterns = [\n /^\\s*---/m, // Front Matter\n /^\\s*#+\\s/m, // Headers: # Title\n /^\\s*[-*+]\\s/m, // Unordered lists: - Item or * Item\n /^\\s*\\d+\\.\\s/m, // Ordered lists: 1. Item\n /^\\s*>\\s/m, // Blockquotes: > Quote\n /\\[.+\\]\\(.+\\)/, // Links: [text](url)\n /!\\[.+\\]\\(.+\\)/, // Images: ![alt](url)\n /`{1,3}.+`{1,3}/, // Code blocks or inline code: `code` or ```code```\n /\\*\\*.+\\*\\*/, // Bold: **text**\n /__.+__/, // Bold: __text__\n /<(https?:\\/\\/[^\\s>]+)>/, // Autolinks: <http://...>\n ];\n\n return patterns.some((pattern) => pattern.test(str));\n};\n\n/**\n * Check if a string is an insertion string\n */\nconst isInsertion = (str: string): boolean =>\n getInsertionValues(str).length > 0;\n\n/**\n * Check if a string is an HTML/JSX string\n * Matches:\n * - <Tag>\n * - </Tag>\n * - <Tag />\n * - <Tag attribute=\"value\">\n * - <Component.SubComponent>\n */\nconst isHTML = (str: string): boolean => {\n // 1. Matches opening or self-closing tags: <Tag ... > or <Tag ... />\n // - Must start with < followed by a letter (to avoid math comparisons like a < b)\n // - Allows alphanumeric, hyphens, and dots (for Namespaced components) in tag name\n // - Allows attributes until the closing >\n const openTagRegex = /<[a-zA-Z][a-zA-Z0-9\\-.]*(\\s+[^>]*)?\\/?>/;\n\n // 2. Matches closing tags: </Tag>\n const closeTagRegex = /<\\/[a-zA-Z][a-zA-Z0-9\\-.]*\\s*>/;\n\n return openTagRegex.test(str) || closeTagRegex.test(str);\n};\n\nconst leafNodeTypes: string[] = [\n NodeTypes.HTML,\n NodeTypes.MARKDOWN,\n NodeTypes.INSERTION,\n NodeTypes.FILE,\n NodeTypes.REACT_NODE,\n NodeTypes.TEXT,\n NodeTypes.NUMBER,\n NodeTypes.BOOLEAN,\n NodeTypes.NULL,\n NodeTypes.UNKNOWN,\n];\n\ntype AutoTransformationOptions = {\n markdown?: boolean;\n html?: boolean;\n insertion?: boolean;\n};\n\n/**\n * Automatically decorate content strings with md() or insert() if they match\n */\nexport const autoDecorateContent = (\n content: any,\n options: boolean | AutoTransformationOptions = true\n): any => {\n if (options === false) {\n return content;\n }\n\n const {\n markdown = true,\n html: htmlOption = true,\n insertion = true,\n } = typeof options === 'object' ? options : {};\n\n if (typeof content === 'string') {\n if (markdown && isMarkdown(content)) {\n const markdownNode = md(content);\n\n return {\n ...markdownNode,\n metadata: getMarkdownMetadata(content),\n };\n }\n\n if (htmlOption && isHTML(content)) {\n return html(content);\n }\n\n if (insertion && isInsertion(content)) {\n return insert(content);\n }\n\n return content;\n }\n\n if (Array.isArray(content)) {\n return content.map((item) => autoDecorateContent(item, options));\n }\n\n if (content && typeof content === 'object') {\n // If it's already a decorated node (has nodeType)\n if ('nodeType' in content) {\n const nodeType = content.nodeType;\n\n // If it's a leaf node type, don't re-decorate its content\n if (leafNodeTypes.includes(nodeType)) {\n return content;\n }\n\n // If it's a container node type (like translation, enumeration, etc.), recurse into its content field\n if (nodeType in content) {\n return {\n ...content,\n [nodeType]: autoDecorateContent(content[nodeType], options),\n };\n }\n\n return content;\n }\n\n // Plain object, recurse into all keys\n const result: Record<string, any> = {};\n for (const key of Object.keys(content)) {\n result[key] = autoDecorateContent(content[key], options);\n }\n return result;\n }\n\n return content;\n};\n"],"mappings":";;;;;;;;AAYA,MAAM,cAAc,QAAyB;CAgB3C,OAAO;EAbL;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;CAGY,CAAC,CAAC,MAAM,YAAY,QAAQ,KAAK,GAAG,CAAC;AACrD;;;;AAKA,MAAM,eAAe,QACnB,mBAAmB,GAAG,CAAC,CAAC,SAAS;;;;;;;;;;AAWnC,MAAM,UAAU,QAAyB;CAUvC,OAAO,0CAAa,KAAK,GAAG,KAAK,iCAAc,KAAK,GAAG;AACzD;AAEA,MAAM,gBAA0B;CAC9B,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;AACZ;;;;AAWA,MAAa,uBACX,SACA,UAA+C,SACvC;CACR,IAAI,YAAY,OACd,OAAO;CAGT,MAAM,EACJ,WAAW,MACX,MAAM,aAAa,MACnB,YAAY,SACV,OAAO,YAAY,WAAW,UAAU,CAAC;CAE7C,IAAI,OAAO,YAAY,UAAU;EAC/B,IAAI,YAAY,WAAW,OAAO,GAGhC,OAAO;GACL,GAHmB,GAAG,OAGR;GACd,UAAU,oBAAoB,OAAO;EACvC;EAGF,IAAI,cAAc,OAAO,OAAO,GAC9B,OAAO,KAAK,OAAO;EAGrB,IAAI,aAAa,YAAY,OAAO,GAClC,OAAO,OAAO,OAAO;EAGvB,OAAO;CACT;CAEA,IAAI,MAAM,QAAQ,OAAO,GACvB,OAAO,QAAQ,KAAK,SAAS,oBAAoB,MAAM,OAAO,CAAC;CAGjE,IAAI,WAAW,OAAO,YAAY,UAAU;EAE1C,IAAI,cAAc,SAAS;GACzB,MAAM,WAAW,QAAQ;GAGzB,IAAI,cAAc,SAAS,QAAQ,GACjC,OAAO;GAIT,IAAI,YAAY,SACd,OAAO;IACL,GAAG;KACF,WAAW,oBAAoB,QAAQ,WAAW,OAAO;GAC5D;GAGF,OAAO;EACT;EAGA,MAAM,SAA8B,CAAC;EACrC,KAAK,MAAM,OAAO,OAAO,KAAK,OAAO,GACnC,OAAO,OAAO,oBAAoB,QAAQ,MAAM,OAAO;EAEzD,OAAO;CACT;CAEA,OAAO;AACT"}
1
+ {"version":3,"file":"autoDecorateContent.mjs","names":[],"sources":["../../../src/utils/autoDecorateContent.ts"],"sourcesContent":["import { getMarkdownMetadata } from '@intlayer/core/markdown';\nimport {\n getInsertionValues,\n html,\n type InsertionContent,\n insert,\n md,\n} from '@intlayer/core/transpiler';\nimport * as NodeTypes from '@intlayer/types/nodeType';\n\n/**\n * Check if a string is a markdown string\n */\nconst isMarkdown = (str: string): boolean => {\n // Check for common markdown indicators\n const patterns = [\n /^\\s*---/m, // Front Matter\n /^\\s*#+\\s/m, // Headers: # Title\n /^\\s*[-*+]\\s/m, // Unordered lists: - Item or * Item\n /^\\s*\\d+\\.\\s/m, // Ordered lists: 1. Item\n /^\\s*>\\s/m, // Blockquotes: > Quote\n /\\[.+\\]\\(.+\\)/, // Links: [text](url)\n /!\\[.+\\]\\(.+\\)/, // Images: ![alt](url)\n /`{1,3}.+`{1,3}/, // Code blocks or inline code: `code` or ```code```\n /\\*\\*.+\\*\\*/, // Bold: **text**\n /__.+__/, // Bold: __text__\n /<(https?:\\/\\/[^\\s>]+)>/, // Autolinks: <http://...>\n ];\n\n return patterns.some((pattern) => pattern.test(str));\n};\n\n/**\n * Check if a string is an insertion string\n */\nconst isInsertion = (str: string): boolean =>\n getInsertionValues(str).length > 0;\n\n/**\n * Check if a string is an HTML/JSX string\n * Matches:\n * - <Tag>\n * - </Tag>\n * - <Tag />\n * - <Tag attribute=\"value\">\n * - <Component.SubComponent>\n */\nconst isHTML = (str: string): boolean => {\n // 1. Matches opening or self-closing tags: <Tag ... > or <Tag ... />\n // - Must start with < followed by a letter (to avoid math comparisons like a < b)\n // - Allows alphanumeric, hyphens, and dots (for Namespaced components) in tag name\n // - Allows attributes until the closing >\n const openTagRegex = /<[a-zA-Z][a-zA-Z0-9\\-.]*(\\s+[^>]*)?\\/?>/;\n\n // 2. Matches closing tags: </Tag>\n const closeTagRegex = /<\\/[a-zA-Z][a-zA-Z0-9\\-.]*\\s*>/;\n\n return openTagRegex.test(str) || closeTagRegex.test(str);\n};\n\nconst leafNodeTypes: string[] = [\n NodeTypes.HTML,\n NodeTypes.MARKDOWN,\n NodeTypes.INSERTION,\n NodeTypes.FILE,\n NodeTypes.REACT_NODE,\n NodeTypes.TEXT,\n NodeTypes.NUMBER,\n NodeTypes.BOOLEAN,\n NodeTypes.NULL,\n NodeTypes.UNKNOWN,\n];\n\ntype AutoTransformationOptions = {\n markdown?: boolean;\n html?: boolean;\n insertion?: boolean;\n};\n\n/**\n * Automatically decorate content strings with md() or insert() if they match\n */\nexport const autoDecorateContent = (\n content: any,\n options: boolean | AutoTransformationOptions = true\n): any => {\n if (options === false) {\n return content;\n }\n\n const {\n markdown = true,\n html: htmlOption = true,\n insertion = true,\n } = typeof options === 'object' ? options : {};\n\n if (typeof content === 'string') {\n // `html()`/`markdown()` content may itself carry `{{ … }}` placeholders.\n // Wrap the node in `insert()` so it stays callable with the values.\n const withInsertion = <Node>(node: Node): Node | InsertionContent<Node> =>\n insertion && isInsertion(content) ? insert(node) : node;\n\n if (markdown && isMarkdown(content)) {\n const markdownNode = md(content);\n\n return withInsertion({\n ...markdownNode,\n metadata: getMarkdownMetadata(content),\n });\n }\n\n if (htmlOption && isHTML(content)) {\n return withInsertion(html(content));\n }\n\n return withInsertion(content);\n }\n\n if (Array.isArray(content)) {\n return content.map((item) => autoDecorateContent(item, options));\n }\n\n if (content && typeof content === 'object') {\n // If it's already a decorated node (has nodeType)\n if ('nodeType' in content) {\n const nodeType = content.nodeType;\n\n // If it's a leaf node type, don't re-decorate its content\n if (leafNodeTypes.includes(nodeType)) {\n return content;\n }\n\n // If it's a container node type (like translation, enumeration, etc.), recurse into its content field\n if (nodeType in content) {\n return {\n ...content,\n [nodeType]: autoDecorateContent(content[nodeType], options),\n };\n }\n\n return content;\n }\n\n // Plain object, recurse into all keys\n const result: Record<string, any> = {};\n for (const key of Object.keys(content)) {\n result[key] = autoDecorateContent(content[key], options);\n }\n return result;\n }\n\n return content;\n};\n"],"mappings":";;;;;;;;AAaA,MAAM,cAAc,QAAyB;CAgB3C,OAAO;EAbL;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;EACA;CAGY,CAAC,CAAC,MAAM,YAAY,QAAQ,KAAK,GAAG,CAAC;AACrD;;;;AAKA,MAAM,eAAe,QACnB,mBAAmB,GAAG,CAAC,CAAC,SAAS;;;;;;;;;;AAWnC,MAAM,UAAU,QAAyB;CAUvC,OAAO,0CAAa,KAAK,GAAG,KAAK,iCAAc,KAAK,GAAG;AACzD;AAEA,MAAM,gBAA0B;CAC9B,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;CACV,UAAU;AACZ;;;;AAWA,MAAa,uBACX,SACA,UAA+C,SACvC;CACR,IAAI,YAAY,OACd,OAAO;CAGT,MAAM,EACJ,WAAW,MACX,MAAM,aAAa,MACnB,YAAY,SACV,OAAO,YAAY,WAAW,UAAU,CAAC;CAE7C,IAAI,OAAO,YAAY,UAAU;EAG/B,MAAM,iBAAuB,SAC3B,aAAa,YAAY,OAAO,IAAI,OAAO,IAAI,IAAI;EAErD,IAAI,YAAY,WAAW,OAAO,GAGhC,OAAO,cAAc;GACnB,GAHmB,GAAG,OAGR;GACd,UAAU,oBAAoB,OAAO;EACvC,CAAC;EAGH,IAAI,cAAc,OAAO,OAAO,GAC9B,OAAO,cAAc,KAAK,OAAO,CAAC;EAGpC,OAAO,cAAc,OAAO;CAC9B;CAEA,IAAI,MAAM,QAAQ,OAAO,GACvB,OAAO,QAAQ,KAAK,SAAS,oBAAoB,MAAM,OAAO,CAAC;CAGjE,IAAI,WAAW,OAAO,YAAY,UAAU;EAE1C,IAAI,cAAc,SAAS;GACzB,MAAM,WAAW,QAAQ;GAGzB,IAAI,cAAc,SAAS,QAAQ,GACjC,OAAO;GAIT,IAAI,YAAY,SACd,OAAO;IACL,GAAG;KACF,WAAW,oBAAoB,QAAQ,WAAW,OAAO;GAC5D;GAGF,OAAO;EACT;EAGA,MAAM,SAA8B,CAAC;EACrC,KAAK,MAAM,OAAO,OAAO,KAAK,OAAO,GACnC,OAAO,OAAO,oBAAoB,QAAQ,MAAM,OAAO;EAEzD,OAAO;CACT;CAEA,OAAO;AACT"}
@@ -1,7 +1,7 @@
1
1
  import { isAbsolute, relative, resolve, sep } from "node:path";
2
- import fg from "fast-glob";
3
2
  import { normalizePath } from "@intlayer/config/utils";
4
3
  import { TRAVERSE_PATTERN } from "@intlayer/config/defaultValues";
4
+ import fg from "fast-glob";
5
5
 
6
6
  //#region src/utils/buildComponentFilesList.ts
7
7
  /**
@@ -1,8 +1,8 @@
1
+ import { rmSync } from "node:fs";
1
2
  import { mkdir, readFile, rm, writeFile } from "node:fs/promises";
2
3
  import { dirname, join } from "node:path";
3
- import { colorize, getAppLogger } from "@intlayer/config/logger";
4
- import { rmSync } from "node:fs";
5
4
  import * as ANSIColors from "@intlayer/config/colors";
5
+ import { colorize, getAppLogger } from "@intlayer/config/logger";
6
6
 
7
7
  //#region src/utils/contentWatcherLock.ts
8
8
  /**
@@ -1,6 +1,6 @@
1
1
  import { relative } from "node:path";
2
- import { colorize, colorizePath } from "@intlayer/config/logger";
3
2
  import * as ANSIColors from "@intlayer/config/colors";
3
+ import { colorize, colorizePath } from "@intlayer/config/logger";
4
4
  import { system } from "@intlayer/config/built";
5
5
  import { getLocaleName } from "@intlayer/core/localization";
6
6
  import { ENGLISH } from "@intlayer/types/locales";
@@ -1,5 +1,5 @@
1
- import { basename, extname, join } from "node:path";
2
1
  import { existsSync, readFileSync, readdirSync } from "node:fs";
2
+ import { basename, extname, join } from "node:path";
3
3
 
4
4
  //#region src/utils/readDictionariesFromDisk.ts
5
5
  /**
@@ -1,6 +1,6 @@
1
+ import { rmSync } from "node:fs";
1
2
  import { mkdir, readFile, stat, unlink, writeFile } from "node:fs/promises";
2
3
  import { dirname } from "node:path";
3
- import { rmSync } from "node:fs";
4
4
  import packageJson from "@intlayer/core/package.json" with { type: "json" };
5
5
 
6
6
  //#region src/utils/runOnce.ts
@@ -1,5 +1,5 @@
1
- import { ps } from "./ps.mjs";
2
1
  import { wmic } from "./wmic.mjs";
2
+ import { ps } from "./ps.mjs";
3
3
  import * as os$1 from "node:os";
4
4
 
5
5
  //#region src/utils/runParallel/pidTree.ts
@@ -1,6 +1,6 @@
1
+ import { rmSync } from "node:fs";
1
2
  import { mkdir, readFile, unlink, writeFile } from "node:fs/promises";
2
3
  import { dirname } from "node:path";
3
- import { rmSync } from "node:fs";
4
4
 
5
5
  //#region src/utils/withFileLock.ts
6
6
  const DEFAULT_OPTIONS = {
@@ -1,20 +1,20 @@
1
1
  import { formatPath } from "./utils/formatter.mjs";
2
2
  import { getFormatFromExtension } from "./utils/getFormatFromExtension.mjs";
3
3
  import { parseContentDeclarationFileName } from "./utils/parseContentDeclarationFileName.mjs";
4
+ import { handleAdditionalContentDeclarationFile } from "./handleAdditionalContentDeclarationFile.mjs";
4
5
  import { handleContentDeclarationFileChange } from "./handleContentDeclarationFileChange.mjs";
5
6
  import { handleContentDeclarationFileMoved } from "./handleContentDeclarationFileMoved.mjs";
6
- import { handleAdditionalContentDeclarationFile } from "./handleAdditionalContentDeclarationFile.mjs";
7
7
  import { handleUnlinkedContentDeclarationFile } from "./handleUnlinkedContentDeclarationFile.mjs";
8
8
  import { prepareIntlayer } from "./prepareIntlayer.mjs";
9
9
  import { writeContentDeclaration } from "./writeContentDeclaration/writeContentDeclaration.mjs";
10
+ import { existsSync, watch as watch$1 } from "node:fs";
10
11
  import { readFile } from "node:fs/promises";
11
12
  import { basename, dirname, extname, resolve } from "node:path";
13
+ import * as ANSIColor from "@intlayer/config/colors";
14
+ import { transpileTSToCJS } from "@intlayer/config/file";
12
15
  import { colorize, getAppLogger } from "@intlayer/config/logger";
13
16
  import { getConfiguration, getConfigurationAndFilePath } from "@intlayer/config/node";
14
- import { existsSync, watch as watch$1 } from "node:fs";
15
17
  import { clearAllCache, clearDiskCacheMemory, clearModuleCache, normalizePath } from "@intlayer/config/utils";
16
- import * as ANSIColor from "@intlayer/config/colors";
17
- import { transpileTSToCJS } from "@intlayer/config/file";
18
18
 
19
19
  //#region src/watcher.ts
20
20
  const pendingUnlinks = /* @__PURE__ */ new Map();
@@ -1,6 +1,6 @@
1
+ import { existsSync, mkdirSync, writeFileSync } from "node:fs";
1
2
  import { dirname, join } from "node:path";
2
3
  import { colorizePath, x } from "@intlayer/config/logger";
3
- import { existsSync, mkdirSync, writeFileSync } from "node:fs";
4
4
  import { deepTransformNode } from "@intlayer/core/interpreter";
5
5
  import * as NodeTypes from "@intlayer/types/nodeType";
6
6
 
@@ -6,9 +6,9 @@ import { transformJSONFile } from "./transformJSONFile.mjs";
6
6
  import { writeJSFile } from "./writeJSFile.mjs";
7
7
  import { writeMarkdownFile } from "./writeMarkdownFile.mjs";
8
8
  import { writeYamlFile } from "./writeYamlFile.mjs";
9
+ import { existsSync } from "node:fs";
9
10
  import { mkdir, readFile, rename, rm, writeFile } from "node:fs/promises";
10
11
  import { basename, dirname, extname, join, resolve } from "node:path";
11
- import { existsSync } from "node:fs";
12
12
  import { COMPILER_NO_METADATA } from "@intlayer/config/defaultValues";
13
13
  import { getFilteredLocalesDictionary, getPerLocaleDictionary } from "@intlayer/core/plugins";
14
14
  import { execSync } from "node:child_process";
@@ -2,10 +2,10 @@ import { getFormatFromExtension } from "../utils/getFormatFromExtension.mjs";
2
2
  import { transformJSFile } from "./transformJSFile.mjs";
3
3
  import { detectFormatCommand } from "../detectFormatCommand.mjs";
4
4
  import { getContentDeclarationFileTemplate } from "../getContentDeclarationFileTemplate/getContentDeclarationFileTemplate.mjs";
5
+ import { existsSync } from "node:fs";
5
6
  import { mkdir, readFile, rename, rm, writeFile } from "node:fs/promises";
6
7
  import { basename, extname, join } from "node:path";
7
8
  import { getAppLogger, logger } from "@intlayer/config/logger";
8
- import { existsSync } from "node:fs";
9
9
  import { execSync } from "node:child_process";
10
10
 
11
11
  //#region src/writeContentDeclaration/writeJSFile.ts
@@ -1,7 +1,7 @@
1
+ import { rmSync } from "node:fs";
1
2
  import { chmod, mkdir, readFile, rename, rm, stat, writeFile } from "node:fs/promises";
2
3
  import { basename, dirname, join } from "node:path";
3
4
  import { randomBytes } from "node:crypto";
4
- import { rmSync } from "node:fs";
5
5
 
6
6
  //#region src/writeFileIfChanged.ts
7
7
  const activeTempFiles = /* @__PURE__ */ new Set();
@@ -1 +1 @@
1
- {"version":3,"file":"cleanRemovedContentDeclaration.d.ts","names":[],"sources":["../../src/cleanRemovedContentDeclaration.ts"],"mappings":";;qBAea,iCAA8B,kBACzB,sBACI,eACL,mBACd;EACD;EACA;EACA"}
1
+ {"version":3,"file":"cleanRemovedContentDeclaration.d.ts","names":[],"sources":["../../src/cleanRemovedContentDeclaration.ts"],"mappings":";;qBAmDa,iCAA8B,kBACzB,sBACI,eACL,mBACd;EACD;EACA;EACA"}
@@ -1,4 +1,3 @@
1
- import { LocalesValues } from "./intlayer/dist/types/index.js";
2
1
  import { Dictionary } from "@intlayer/types/dictionary";
3
2
  //#region src/formatDictionary.d.ts
4
3
  export declare const formatDictionary: (dictionary: Dictionary) => Dictionary;
@@ -19,7 +18,7 @@ export declare const formatDictionaryOutput: (dictionary: Dictionary, format: Di
19
18
  tags?: string[];
20
19
  item?: number;
21
20
  variant?: import("@intlayer/types").DictionaryVariantValue | import("@intlayer/types").DictionaryVariantValue[];
22
- locale?: LocalesValues;
21
+ locale?: import("@intlayer/types").LocalesValues;
23
22
  contentAutoTransformation?: import("@intlayer/types").ContentAutoTransformation;
24
23
  fill?: import("@intlayer/types").Fill;
25
24
  filled?: true;
@@ -46,7 +45,7 @@ export declare const formatDictionariesOutput: (dictionaries: Dictionary[], form
46
45
  tags?: string[];
47
46
  item?: number;
48
47
  variant?: import("@intlayer/types").DictionaryVariantValue | import("@intlayer/types").DictionaryVariantValue[];
49
- locale?: LocalesValues;
48
+ locale?: import("@intlayer/types").LocalesValues;
50
49
  contentAutoTransformation?: import("@intlayer/types").ContentAutoTransformation;
51
50
  fill?: import("@intlayer/types").Fill;
52
51
  filled?: true;
@@ -1 +1 @@
1
- {"version":3,"file":"formatDictionary.d.ts","names":[],"sources":["../../src/formatDictionary.ts"],"mappings":";;;qBAYa,mBAAgB,YAAgB,eAAa;qBAoC7C,qBAAkB,cACf,iBACb,QAAQ;qBAEE,yBAAsB,YACrB,YAAU,QACd;;;;;;;;;;;;;;;;;;;;;;;;;;IAmCT;qBAEY,2BAAwB,cACrB,cAAY,QAClB;;;;;;;;;;;;;;;;;;;;;;;;;;IAEoE"}
1
+ {"version":3,"file":"formatDictionary.d.ts","names":[],"sources":["../../src/formatDictionary.ts"],"mappings":";;qBAYa,mBAAgB,YAAgB,eAAa;qBAoC7C,qBAAkB,cACf,iBACb,QAAQ;qBAEE,yBAAsB,YACrB,YAAU,QACd;;;;;;;;;;;;;;;;;;;;;;;;;;IAmCT;qBAEY,2BAAwB,cACrB,cAAY,QAClB;;;;;;;;;;;;;;;;;;;;;;;;;;IAEoE"}
@@ -1 +1 @@
1
- {"version":3,"file":"logConfigDetails.d.ts","names":[],"sources":["../../src/logConfigDetails.ts"],"mappings":";;qBAgBa,mBAAgB,UAAc"}
1
+ {"version":3,"file":"logConfigDetails.d.ts","names":[],"sources":["../../src/logConfigDetails.ts"],"mappings":";;qBAiBa,mBAAgB,UAAc"}
@@ -1 +1 @@
1
- {"version":3,"file":"autoDecorateContent.d.ts","names":[],"sources":["../../../src/utils/autoDecorateContent.ts"],"mappings":";KAwEK;EACH;EACA;EACA;;;;;qBAMW,sBAAmB,cAClB,oBACO"}
1
+ {"version":3,"file":"autoDecorateContent.d.ts","names":[],"sources":["../../../src/utils/autoDecorateContent.ts"],"mappings":";KAyEK;EACH;EACA;EACA;;;;;qBAMW,sBAAmB,cAClB,oBACO"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@intlayer/engine",
3
- "version": "9.5.2",
3
+ "version": "9.5.4-canary.0",
4
4
  "private": false,
5
5
  "description": "Scans and builds Intlayer declaration files into dictionaries based on Intlayer configuration.",
6
6
  "keywords": [
@@ -135,19 +135,18 @@
135
135
  "prepublish": "cp -f ../../../README.md ./README.md",
136
136
  "publish": "bun publish || true",
137
137
  "publish:canary": "bun publish --access public --tag canary || true",
138
+ "publish:ci": "bun ../../../scripts/publish-package.mjs",
138
139
  "publish:latest": "bun publish --access public --tag latest || true",
139
140
  "test": "bun --bun vitest run",
140
141
  "test:watch": "bun --bun vitest",
141
142
  "typecheck": "tsc --noEmit --project tsconfig.types.json"
142
143
  },
143
144
  "dependencies": {
144
- "@intlayer/api": "9.5.2",
145
- "@intlayer/config": "9.5.2",
146
- "@intlayer/core": "9.5.2",
147
- "@intlayer/dictionaries-entry": "9.5.2",
148
- "@intlayer/remote-dictionaries-entry": "9.5.2",
149
- "@intlayer/types": "9.5.2",
150
- "@intlayer/unmerged-dictionaries-entry": "9.5.2",
145
+ "@intlayer/api": "9.5.4-canary.0",
146
+ "@intlayer/config": "9.5.4-canary.0",
147
+ "@intlayer/core": "9.5.4-canary.0",
148
+ "@intlayer/dictionaries-entry": "9.5.4-canary.0",
149
+ "@intlayer/types": "9.5.4-canary.0",
151
150
  "@parcel/watcher": "2.6.0",
152
151
  "defu": "6.1.7",
153
152
  "fast-glob": "3.3.3",
@@ -163,11 +162,11 @@
163
162
  "rimraf": "6.1.3",
164
163
  "tsdown": "0.23.0",
165
164
  "typescript": "7.0.2",
166
- "vitest": "5.0.0",
167
- "zod": "4.6.2"
165
+ "vitest": "5.0.1",
166
+ "zod": "4.6.5"
168
167
  },
169
168
  "peerDependencies": {
170
- "@intlayer/babel": "9.5.2"
169
+ "@intlayer/babel": "9.5.4-canary.0"
171
170
  },
172
171
  "peerDependenciesMeta": {
173
172
  "@intlayer/babel": {
@@ -1,14 +0,0 @@
1
- import { IntlayerConfig } from "@intlayer/types/config";
2
- import { Dictionary } from "@intlayer/types/dictionary";
3
- import "@intlayer/types/allLocales";
4
- import { LocalesValues as LocalesValues$1 } from "@intlayer/types/module_augmentation";
5
- import "@intlayer/types/locales";
6
- import "@intlayer/config/built";
7
- import "@intlayer/core/file";
8
- import "@intlayer/core/formatters";
9
- import "@intlayer/core/interpreter";
10
- import "@intlayer/core/localization";
11
- import "@intlayer/core/markdown";
12
- import "@intlayer/core/transpiler";
13
- import "@intlayer/core/utils";
14
- export type { LocalesValues$1 as LocalesValues };