@intlayer/engine 9.4.3 → 9.5.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 (336) hide show
  1. package/README.md +0 -2
  2. package/dist/cjs/createDictionaryEntryPoint/generateDictionaryListContent.cjs +1 -2
  3. package/dist/cjs/createDictionaryEntryPoint/generateDictionaryListContent.cjs.map +1 -1
  4. package/dist/cjs/init/index.cjs +14 -11
  5. package/dist/cjs/init/index.cjs.map +1 -1
  6. package/dist/cjs/init/utils/devScript.cjs +57 -0
  7. package/dist/cjs/init/utils/devScript.cjs.map +1 -0
  8. package/dist/cjs/init/utils/index.cjs +3 -0
  9. package/dist/cjs/loadDictionaries/loadContentDeclaration.cjs +1 -1
  10. package/dist/cjs/loadDictionaries/loadContentDeclaration.cjs.map +1 -1
  11. package/dist/cjs/loadDictionaries/loadMarkdownContentDeclaration.cjs +6 -5
  12. package/dist/cjs/loadDictionaries/loadMarkdownContentDeclaration.cjs.map +1 -1
  13. package/dist/cjs/syncPluginKit/createSyncPlugin.cjs +51 -3
  14. package/dist/cjs/syncPluginKit/createSyncPlugin.cjs.map +1 -1
  15. package/dist/cjs/utils/contentWatcherLock.cjs +173 -0
  16. package/dist/cjs/utils/contentWatcherLock.cjs.map +1 -0
  17. package/dist/cjs/utils/index.cjs +13 -1
  18. package/dist/cjs/utils/parseContentDeclarationFileName.cjs +35 -0
  19. package/dist/cjs/utils/parseContentDeclarationFileName.cjs.map +1 -0
  20. package/dist/cjs/utils/withFileLock.cjs +133 -0
  21. package/dist/cjs/utils/withFileLock.cjs.map +1 -0
  22. package/dist/cjs/watcher.cjs +7 -3
  23. package/dist/cjs/watcher.cjs.map +1 -1
  24. package/dist/esm/createDictionaryEntryPoint/generateDictionaryListContent.mjs +1 -2
  25. package/dist/esm/createDictionaryEntryPoint/generateDictionaryListContent.mjs.map +1 -1
  26. package/dist/esm/init/index.mjs +14 -11
  27. package/dist/esm/init/index.mjs.map +1 -1
  28. package/dist/esm/init/utils/devScript.mjs +55 -0
  29. package/dist/esm/init/utils/devScript.mjs.map +1 -0
  30. package/dist/esm/init/utils/index.mjs +2 -1
  31. package/dist/esm/loadDictionaries/loadContentDeclaration.mjs +1 -1
  32. package/dist/esm/loadDictionaries/loadContentDeclaration.mjs.map +1 -1
  33. package/dist/esm/loadDictionaries/loadMarkdownContentDeclaration.mjs +6 -5
  34. package/dist/esm/loadDictionaries/loadMarkdownContentDeclaration.mjs.map +1 -1
  35. package/dist/esm/syncPluginKit/createSyncPlugin.mjs +51 -3
  36. package/dist/esm/syncPluginKit/createSyncPlugin.mjs.map +1 -1
  37. package/dist/esm/utils/contentWatcherLock.mjs +164 -0
  38. package/dist/esm/utils/contentWatcherLock.mjs.map +1 -0
  39. package/dist/esm/utils/index.mjs +4 -1
  40. package/dist/esm/utils/parseContentDeclarationFileName.mjs +34 -0
  41. package/dist/esm/utils/parseContentDeclarationFileName.mjs.map +1 -0
  42. package/dist/esm/utils/withFileLock.mjs +132 -0
  43. package/dist/esm/utils/withFileLock.mjs.map +1 -0
  44. package/dist/esm/watcher.mjs +8 -4
  45. package/dist/esm/watcher.mjs.map +1 -1
  46. package/dist/types/buildIntlayerDictionary/buildIntlayerDictionary.d.ts +2 -3
  47. package/dist/types/buildIntlayerDictionary/buildIntlayerDictionary.d.ts.map +1 -1
  48. package/dist/types/buildIntlayerDictionary/processContentDeclaration.d.ts +1 -2
  49. package/dist/types/buildIntlayerDictionary/processContentDeclaration.d.ts.map +1 -1
  50. package/dist/types/buildIntlayerDictionary/writeDynamicDictionary.d.ts +10 -11
  51. package/dist/types/buildIntlayerDictionary/writeDynamicDictionary.d.ts.map +1 -1
  52. package/dist/types/buildIntlayerDictionary/writeFetchDictionary.d.ts +2 -3
  53. package/dist/types/buildIntlayerDictionary/writeFetchDictionary.d.ts.map +1 -1
  54. package/dist/types/buildIntlayerDictionary/writeMergedDictionary.d.ts +5 -6
  55. package/dist/types/buildIntlayerDictionary/writeMergedDictionary.d.ts.map +1 -1
  56. package/dist/types/buildIntlayerDictionary/writeNestedDictionary.d.ts +4 -5
  57. package/dist/types/buildIntlayerDictionary/writeNestedDictionary.d.ts.map +1 -1
  58. package/dist/types/buildIntlayerDictionary/writeRemoteDictionary.d.ts +3 -4
  59. package/dist/types/buildIntlayerDictionary/writeRemoteDictionary.d.ts.map +1 -1
  60. package/dist/types/buildIntlayerDictionary/writeUnmergedDictionary.d.ts +4 -5
  61. package/dist/types/buildIntlayerDictionary/writeUnmergedDictionary.d.ts.map +1 -1
  62. package/dist/types/cleanOutputDir.d.ts +1 -2
  63. package/dist/types/cleanOutputDir.d.ts.map +1 -1
  64. package/dist/types/cleanRemovedContentDeclaration.d.ts +1 -2
  65. package/dist/types/cleanRemovedContentDeclaration.d.ts.map +1 -1
  66. package/dist/types/createDictionaryEntryPoint/createDictionaryEntryPoint.d.ts +2 -3
  67. package/dist/types/createDictionaryEntryPoint/createDictionaryEntryPoint.d.ts.map +1 -1
  68. package/dist/types/createDictionaryEntryPoint/generateDictionaryListContent.d.ts +1 -2
  69. package/dist/types/createDictionaryEntryPoint/generateDictionaryListContent.d.ts.map +1 -1
  70. package/dist/types/createDictionaryEntryPoint/getBuiltDictionariesPath.d.ts +1 -2
  71. package/dist/types/createDictionaryEntryPoint/getBuiltDictionariesPath.d.ts.map +1 -1
  72. package/dist/types/createDictionaryEntryPoint/getBuiltDynamicDictionariesPath.d.ts +1 -2
  73. package/dist/types/createDictionaryEntryPoint/getBuiltDynamicDictionariesPath.d.ts.map +1 -1
  74. package/dist/types/createDictionaryEntryPoint/getBuiltFetchDictionariesPath.d.ts +1 -2
  75. package/dist/types/createDictionaryEntryPoint/getBuiltFetchDictionariesPath.d.ts.map +1 -1
  76. package/dist/types/createDictionaryEntryPoint/getBuiltRemoteDictionariesPath.d.ts +1 -2
  77. package/dist/types/createDictionaryEntryPoint/getBuiltRemoteDictionariesPath.d.ts.map +1 -1
  78. package/dist/types/createDictionaryEntryPoint/getBuiltUnmergedDictionariesPath.d.ts +1 -2
  79. package/dist/types/createDictionaryEntryPoint/getBuiltUnmergedDictionariesPath.d.ts.map +1 -1
  80. package/dist/types/createType/createModuleAugmentation.d.ts +4 -5
  81. package/dist/types/createType/createModuleAugmentation.d.ts.map +1 -1
  82. package/dist/types/createType/createType.d.ts +2 -3
  83. package/dist/types/createType/createType.d.ts.map +1 -1
  84. package/dist/types/detectFormatCommand.d.ts +1 -2
  85. package/dist/types/detectFormatCommand.d.ts.map +1 -1
  86. package/dist/types/docReview/alignBlocks.d.ts +1 -2
  87. package/dist/types/docReview/alignBlocks.d.ts.map +1 -1
  88. package/dist/types/docReview/computeSimilarity.d.ts +2 -3
  89. package/dist/types/docReview/computeSimilarity.d.ts.map +1 -1
  90. package/dist/types/docReview/fingerprintBlock.d.ts +1 -2
  91. package/dist/types/docReview/fingerprintBlock.d.ts.map +1 -1
  92. package/dist/types/docReview/mapChangedLinesToBlocks.d.ts +1 -2
  93. package/dist/types/docReview/mapChangedLinesToBlocks.d.ts.map +1 -1
  94. package/dist/types/docReview/normalizeBlock.d.ts +1 -2
  95. package/dist/types/docReview/normalizeBlock.d.ts.map +1 -1
  96. package/dist/types/docReview/pipeline.d.ts +4 -4
  97. package/dist/types/docReview/pipeline.d.ts.map +1 -1
  98. package/dist/types/docReview/planActions.d.ts +1 -2
  99. package/dist/types/docReview/planActions.d.ts.map +1 -1
  100. package/dist/types/docReview/rebuildDocument.d.ts +5 -6
  101. package/dist/types/docReview/rebuildDocument.d.ts.map +1 -1
  102. package/dist/types/docReview/reviewReport.d.ts +8 -9
  103. package/dist/types/docReview/reviewReport.d.ts.map +1 -1
  104. package/dist/types/docReview/segmentDocument.d.ts +2 -3
  105. package/dist/types/docReview/segmentDocument.d.ts.map +1 -1
  106. package/dist/types/docReview/types.d.ts +9 -10
  107. package/dist/types/docReview/types.d.ts.map +1 -1
  108. package/dist/types/fetchDistantDictionaries.d.ts +1 -2
  109. package/dist/types/fetchDistantDictionaries.d.ts.map +1 -1
  110. package/dist/types/filterInvalidDictionaries.d.ts +2 -3
  111. package/dist/types/filterInvalidDictionaries.d.ts.map +1 -1
  112. package/dist/types/formatDictionary.d.ts +6 -8
  113. package/dist/types/formatDictionary.d.ts.map +1 -1
  114. package/dist/types/getContentDeclarationFileTemplate/getContentDeclarationFileTemplate.d.ts +1 -2
  115. package/dist/types/getContentDeclarationFileTemplate/getContentDeclarationFileTemplate.d.ts.map +1 -1
  116. package/dist/types/handleAdditionalContentDeclarationFile.d.ts +1 -2
  117. package/dist/types/handleAdditionalContentDeclarationFile.d.ts.map +1 -1
  118. package/dist/types/handleContentDeclarationFileChange.d.ts +1 -2
  119. package/dist/types/handleContentDeclarationFileChange.d.ts.map +1 -1
  120. package/dist/types/handleContentDeclarationFileMoved.d.ts +1 -2
  121. package/dist/types/handleContentDeclarationFileMoved.d.ts.map +1 -1
  122. package/dist/types/handleUnlinkedContentDeclarationFile.d.ts +1 -2
  123. package/dist/types/handleUnlinkedContentDeclarationFile.d.ts.map +1 -1
  124. package/dist/types/init/cms.d.ts +8 -9
  125. package/dist/types/init/cms.d.ts.map +1 -1
  126. package/dist/types/init/frameworkSetup/index.d.ts +2 -2
  127. package/dist/types/init/frameworkSetup/index.d.ts.map +1 -1
  128. package/dist/types/init/frameworkSetup/nextAppRouter/detect.d.ts +4 -4
  129. package/dist/types/init/frameworkSetup/nextAppRouter/detect.d.ts.map +1 -1
  130. package/dist/types/init/frameworkSetup/nextAppRouter/index.d.ts +1 -2
  131. package/dist/types/init/frameworkSetup/nextAppRouter/index.d.ts.map +1 -1
  132. package/dist/types/init/frameworkSetup/nextAppRouter/restructure.d.ts +5 -6
  133. package/dist/types/init/frameworkSetup/nextAppRouter/restructure.d.ts.map +1 -1
  134. package/dist/types/init/frameworkSetup/nextAppRouter/templates.d.ts +8 -9
  135. package/dist/types/init/frameworkSetup/nextAppRouter/templates.d.ts.map +1 -1
  136. package/dist/types/init/frameworkSetup/nextAppRouter/transforms.d.ts +2 -3
  137. package/dist/types/init/frameworkSetup/nextAppRouter/transforms.d.ts.map +1 -1
  138. package/dist/types/init/frameworkSetup/tanstackStart/detect.d.ts +3 -4
  139. package/dist/types/init/frameworkSetup/tanstackStart/detect.d.ts.map +1 -1
  140. package/dist/types/init/frameworkSetup/tanstackStart/index.d.ts +1 -2
  141. package/dist/types/init/frameworkSetup/tanstackStart/index.d.ts.map +1 -1
  142. package/dist/types/init/frameworkSetup/tanstackStart/restructure.d.ts +7 -8
  143. package/dist/types/init/frameworkSetup/tanstackStart/restructure.d.ts.map +1 -1
  144. package/dist/types/init/frameworkSetup/tanstackStart/templates.d.ts +3 -4
  145. package/dist/types/init/frameworkSetup/tanstackStart/templates.d.ts.map +1 -1
  146. package/dist/types/init/frameworkSetup/tanstackStart/transforms.d.ts +2 -3
  147. package/dist/types/init/frameworkSetup/tanstackStart/transforms.d.ts.map +1 -1
  148. package/dist/types/init/frameworkSetup/types.d.ts +2 -3
  149. package/dist/types/init/frameworkSetup/types.d.ts.map +1 -1
  150. package/dist/types/init/index.d.ts +4 -5
  151. package/dist/types/init/index.d.ts.map +1 -1
  152. package/dist/types/init/utils/astImports.d.ts +3 -4
  153. package/dist/types/init/utils/astImports.d.ts.map +1 -1
  154. package/dist/types/init/utils/configManipulation.d.ts +19 -20
  155. package/dist/types/init/utils/configManipulation.d.ts.map +1 -1
  156. package/dist/types/init/utils/devScript.d.ts +49 -0
  157. package/dist/types/init/utils/devScript.d.ts.map +1 -0
  158. package/dist/types/init/utils/fileSystem.d.ts +11 -12
  159. package/dist/types/init/utils/fileSystem.d.ts.map +1 -1
  160. package/dist/types/init/utils/githubActions.d.ts +7 -8
  161. package/dist/types/init/utils/githubActions.d.ts.map +1 -1
  162. package/dist/types/init/utils/index.d.ts +2 -1
  163. package/dist/types/init/utils/jsonParser.d.ts +1 -2
  164. package/dist/types/init/utils/jsonParser.d.ts.map +1 -1
  165. package/dist/types/init/utils/nextCompilerBabel.d.ts +2 -3
  166. package/dist/types/init/utils/nextCompilerBabel.d.ts.map +1 -1
  167. package/dist/types/init/utils/packageManager.d.ts +17 -18
  168. package/dist/types/init/utils/packageManager.d.ts.map +1 -1
  169. package/dist/types/init/utils/tsConfig.d.ts +1 -2
  170. package/dist/types/init/utils/tsConfig.d.ts.map +1 -1
  171. package/dist/types/init/utils/version.d.ts +1 -2
  172. package/dist/types/init/utils/version.d.ts.map +1 -1
  173. package/dist/types/initConfig/index.d.ts +2 -3
  174. package/dist/types/initConfig/index.d.ts.map +1 -1
  175. package/dist/types/installLSP.d.ts +1 -2
  176. package/dist/types/installLSP.d.ts.map +1 -1
  177. package/dist/types/installMCP/installMCP.d.ts +2 -3
  178. package/dist/types/installMCP/installMCP.d.ts.map +1 -1
  179. package/dist/types/installSkills/index.d.ts +9 -10
  180. package/dist/types/installSkills/index.d.ts.map +1 -1
  181. package/dist/types/listDictionariesPath.d.ts +2 -3
  182. package/dist/types/listDictionariesPath.d.ts.map +1 -1
  183. package/dist/types/listGitFiles.d.ts +5 -6
  184. package/dist/types/listGitFiles.d.ts.map +1 -1
  185. package/dist/types/listProjects.d.ts +3 -4
  186. package/dist/types/listProjects.d.ts.map +1 -1
  187. package/dist/types/loadDictionaries/getIntlayerBundle.d.ts +1 -2
  188. package/dist/types/loadDictionaries/getIntlayerBundle.d.ts.map +1 -1
  189. package/dist/types/loadDictionaries/loadContentDeclaration.d.ts +4 -5
  190. package/dist/types/loadDictionaries/loadContentDeclaration.d.ts.map +1 -1
  191. package/dist/types/loadDictionaries/loadDictionaries.d.ts +2 -3
  192. package/dist/types/loadDictionaries/loadDictionaries.d.ts.map +1 -1
  193. package/dist/types/loadDictionaries/loadLocalDictionaries.d.ts +1 -2
  194. package/dist/types/loadDictionaries/loadLocalDictionaries.d.ts.map +1 -1
  195. package/dist/types/loadDictionaries/loadMarkdownContentDeclaration.d.ts +2 -2
  196. package/dist/types/loadDictionaries/loadMarkdownContentDeclaration.d.ts.map +1 -1
  197. package/dist/types/loadDictionaries/loadRemoteDictionaries.d.ts +2 -3
  198. package/dist/types/loadDictionaries/loadRemoteDictionaries.d.ts.map +1 -1
  199. package/dist/types/loadDictionaries/loadYamlContentDeclaration.d.ts +1 -2
  200. package/dist/types/loadDictionaries/loadYamlContentDeclaration.d.ts.map +1 -1
  201. package/dist/types/loadDictionaries/log.d.ts +1 -2
  202. package/dist/types/loadDictionaries/log.d.ts.map +1 -1
  203. package/dist/types/loadDictionaries/logTypeScriptErrors.d.ts +1 -2
  204. package/dist/types/loadDictionaries/logTypeScriptErrors.d.ts.map +1 -1
  205. package/dist/types/logConfigDetails.d.ts +1 -2
  206. package/dist/types/logConfigDetails.d.ts.map +1 -1
  207. package/dist/types/prepareIntlayer.d.ts +1 -2
  208. package/dist/types/prepareIntlayer.d.ts.map +1 -1
  209. package/dist/types/reduceDictionaryContent/applyMask.d.ts +1 -2
  210. package/dist/types/reduceDictionaryContent/applyMask.d.ts.map +1 -1
  211. package/dist/types/reduceDictionaryContent/reduceDictionaryContent.d.ts +1 -2
  212. package/dist/types/reduceDictionaryContent/reduceDictionaryContent.d.ts.map +1 -1
  213. package/dist/types/scan/analyzeBundleContent.d.ts +1 -2
  214. package/dist/types/scan/analyzeBundleContent.d.ts.map +1 -1
  215. package/dist/types/scan/calculateScore.d.ts +6 -7
  216. package/dist/types/scan/calculateScore.d.ts.map +1 -1
  217. package/dist/types/scan/checks.d.ts +8 -9
  218. package/dist/types/scan/checks.d.ts.map +1 -1
  219. package/dist/types/scan/parseHtml.d.ts +13 -14
  220. package/dist/types/scan/parseHtml.d.ts.map +1 -1
  221. package/dist/types/scan/scanWebsite.d.ts +1 -2
  222. package/dist/types/scan/scanWebsite.d.ts.map +1 -1
  223. package/dist/types/scan/types.d.ts +9 -10
  224. package/dist/types/scan/types.d.ts.map +1 -1
  225. package/dist/types/syncPluginKit/createFileAdapter.d.ts +4 -5
  226. package/dist/types/syncPluginKit/createFileAdapter.d.ts.map +1 -1
  227. package/dist/types/syncPluginKit/createSyncPlugin.d.ts +1 -2
  228. package/dist/types/syncPluginKit/createSyncPlugin.d.ts.map +1 -1
  229. package/dist/types/syncPluginKit/extractKeyAndLocaleFromPath.d.ts +1 -2
  230. package/dist/types/syncPluginKit/extractKeyAndLocaleFromPath.d.ts.map +1 -1
  231. package/dist/types/syncPluginKit/filePathPatternHelpers.d.ts +1 -2
  232. package/dist/types/syncPluginKit/filePathPatternHelpers.d.ts.map +1 -1
  233. package/dist/types/syncPluginKit/index.d.ts +2 -2
  234. package/dist/types/syncPluginKit/types.d.ts +28 -15
  235. package/dist/types/syncPluginKit/types.d.ts.map +1 -1
  236. package/dist/types/utils/autoDecorateContent.d.ts +1 -2
  237. package/dist/types/utils/autoDecorateContent.d.ts.map +1 -1
  238. package/dist/types/utils/babelParser.d.ts +3 -3
  239. package/dist/types/utils/babelParser.d.ts.map +1 -1
  240. package/dist/types/utils/buildComponentFilesList.d.ts +1 -2
  241. package/dist/types/utils/buildComponentFilesList.d.ts.map +1 -1
  242. package/dist/types/utils/buildFilesList.d.ts +3 -4
  243. package/dist/types/utils/buildFilesList.d.ts.map +1 -1
  244. package/dist/types/utils/chunkArray.d.ts +1 -2
  245. package/dist/types/utils/chunkArray.d.ts.map +1 -1
  246. package/dist/types/utils/chunkJSON.d.ts +5 -6
  247. package/dist/types/utils/chunkJSON.d.ts.map +1 -1
  248. package/dist/types/utils/contentWatcherLock.d.ts +113 -0
  249. package/dist/types/utils/contentWatcherLock.d.ts.map +1 -0
  250. package/dist/types/utils/formatter.d.ts +2 -3
  251. package/dist/types/utils/formatter.d.ts.map +1 -1
  252. package/dist/types/utils/getChunk.d.ts +1 -2
  253. package/dist/types/utils/getChunk.d.ts.map +1 -1
  254. package/dist/types/utils/getContentExtension.d.ts +1 -2
  255. package/dist/types/utils/getContentExtension.d.ts.map +1 -1
  256. package/dist/types/utils/getFormatFromExtension.d.ts +4 -5
  257. package/dist/types/utils/getFormatFromExtension.d.ts.map +1 -1
  258. package/dist/types/utils/getPathHash.d.ts +1 -2
  259. package/dist/types/utils/getPathHash.d.ts.map +1 -1
  260. package/dist/types/utils/index.d.ts +4 -1
  261. package/dist/types/utils/mergeChunks.d.ts +1 -2
  262. package/dist/types/utils/mergeChunks.d.ts.map +1 -1
  263. package/dist/types/utils/pLimit.d.ts +2 -3
  264. package/dist/types/utils/pLimit.d.ts.map +1 -1
  265. package/dist/types/utils/parallelize.d.ts +1 -2
  266. package/dist/types/utils/parallelize.d.ts.map +1 -1
  267. package/dist/types/utils/parallelizeGlobal.d.ts +3 -4
  268. package/dist/types/utils/parallelizeGlobal.d.ts.map +1 -1
  269. package/dist/types/utils/parseContentDeclarationFileName.d.ts +23 -0
  270. package/dist/types/utils/parseContentDeclarationFileName.d.ts.map +1 -0
  271. package/dist/types/utils/readDictionariesFromDisk.d.ts +1 -2
  272. package/dist/types/utils/readDictionariesFromDisk.d.ts.map +1 -1
  273. package/dist/types/utils/reduceObjectFormat.d.ts +4 -5
  274. package/dist/types/utils/reduceObjectFormat.d.ts.map +1 -1
  275. package/dist/types/utils/resolveObjectPromises.d.ts +1 -2
  276. package/dist/types/utils/resolveObjectPromises.d.ts.map +1 -1
  277. package/dist/types/utils/resolveRelativePath.d.ts +1 -2
  278. package/dist/types/utils/resolveRelativePath.d.ts.map +1 -1
  279. package/dist/types/utils/runOnce.d.ts +2 -3
  280. package/dist/types/utils/runOnce.d.ts.map +1 -1
  281. package/dist/types/utils/runParallel/bin.d.ts +1 -2
  282. package/dist/types/utils/runParallel/bin.d.ts.map +1 -1
  283. package/dist/types/utils/runParallel/bootstrap.d.ts +1 -2
  284. package/dist/types/utils/runParallel/bootstrap.d.ts.map +1 -1
  285. package/dist/types/utils/runParallel/index.d.ts +2 -3
  286. package/dist/types/utils/runParallel/index.d.ts.map +1 -1
  287. package/dist/types/utils/runParallel/pidTree.d.ts +1 -2
  288. package/dist/types/utils/runParallel/pidTree.d.ts.map +1 -1
  289. package/dist/types/utils/runParallel/ps.d.ts +1 -2
  290. package/dist/types/utils/runParallel/ps.d.ts.map +1 -1
  291. package/dist/types/utils/runParallel/runTask.d.ts +1 -2
  292. package/dist/types/utils/runParallel/runTask.d.ts.map +1 -1
  293. package/dist/types/utils/runParallel/spawnPosix.d.ts +1 -2
  294. package/dist/types/utils/runParallel/spawnPosix.d.ts.map +1 -1
  295. package/dist/types/utils/runParallel/spawnWin32.d.ts +1 -2
  296. package/dist/types/utils/runParallel/spawnWin32.d.ts.map +1 -1
  297. package/dist/types/utils/runParallel/wmic.d.ts +1 -2
  298. package/dist/types/utils/runParallel/wmic.d.ts.map +1 -1
  299. package/dist/types/utils/sortAlphabetically.d.ts +1 -2
  300. package/dist/types/utils/sortAlphabetically.d.ts.map +1 -1
  301. package/dist/types/utils/splitTextByLine.d.ts +1 -2
  302. package/dist/types/utils/splitTextByLine.d.ts.map +1 -1
  303. package/dist/types/utils/verifyIdenticObjectFormat.d.ts +1 -2
  304. package/dist/types/utils/verifyIdenticObjectFormat.d.ts.map +1 -1
  305. package/dist/types/utils/withFileLock.d.ts +44 -0
  306. package/dist/types/utils/withFileLock.d.ts.map +1 -0
  307. package/dist/types/watcher.d.ts +2 -3
  308. package/dist/types/watcher.d.ts.map +1 -1
  309. package/dist/types/writeConfiguration/generateConfigurationContent.d.ts +1 -2
  310. package/dist/types/writeConfiguration/generateConfigurationContent.d.ts.map +1 -1
  311. package/dist/types/writeConfiguration/index.d.ts +2 -3
  312. package/dist/types/writeConfiguration/index.d.ts.map +1 -1
  313. package/dist/types/writeContentDeclaration/detectExportedComponentName.d.ts +1 -2
  314. package/dist/types/writeContentDeclaration/detectExportedComponentName.d.ts.map +1 -1
  315. package/dist/types/writeContentDeclaration/dictionaryStatus.d.ts +1 -2
  316. package/dist/types/writeContentDeclaration/dictionaryStatus.d.ts.map +1 -1
  317. package/dist/types/writeContentDeclaration/processContentDeclarationContent.d.ts +1 -2
  318. package/dist/types/writeContentDeclaration/processContentDeclarationContent.d.ts.map +1 -1
  319. package/dist/types/writeContentDeclaration/transformJSFile.d.ts +1 -2
  320. package/dist/types/writeContentDeclaration/transformJSFile.d.ts.map +1 -1
  321. package/dist/types/writeContentDeclaration/transformJSONFile.d.ts +1 -2
  322. package/dist/types/writeContentDeclaration/transformJSONFile.d.ts.map +1 -1
  323. package/dist/types/writeContentDeclaration/writeContentDeclaration.d.ts +1 -2
  324. package/dist/types/writeContentDeclaration/writeContentDeclaration.d.ts.map +1 -1
  325. package/dist/types/writeContentDeclaration/writeJSFile.d.ts +1 -2
  326. package/dist/types/writeContentDeclaration/writeJSFile.d.ts.map +1 -1
  327. package/dist/types/writeContentDeclaration/writeMarkdownFile.d.ts +1 -2
  328. package/dist/types/writeContentDeclaration/writeMarkdownFile.d.ts.map +1 -1
  329. package/dist/types/writeContentDeclaration/writeYamlFile.d.ts +1 -2
  330. package/dist/types/writeContentDeclaration/writeYamlFile.d.ts.map +1 -1
  331. package/dist/types/writeFileIfChanged.d.ts +2 -3
  332. package/dist/types/writeFileIfChanged.d.ts.map +1 -1
  333. package/dist/types/writeJsonIfChanged.d.ts +1 -2
  334. package/dist/types/writeJsonIfChanged.d.ts.map +1 -1
  335. package/package.json +12 -12
  336. package/dist/types/intlayer/dist/types/index.d.ts +0 -14
@@ -1,9 +1,9 @@
1
1
  import { Score } from "./calculateScore.js";
2
2
  //#region src/scan/types.d.ts
3
3
  /** Status of an individual scan check. */
4
- type ScanCheckStatus = 'success' | 'warning' | 'error';
4
+ export type ScanCheckStatus = 'success' | 'warning' | 'error';
5
5
  /** Per-status human-readable details attached to a {@link ScanEvent}. */
6
- type ScanEventDetails = {
6
+ export type ScanEventDetails = {
7
7
  success?: unknown;
8
8
  warning?: unknown;
9
9
  error?: unknown;
@@ -12,22 +12,22 @@ type ScanEventDetails = {
12
12
  * A single check produced while scanning a page. The `type` matches a key of
13
13
  * the score table (optionally suffixed with the URL for URL-scoped checks).
14
14
  */
15
- type ScanEvent = {
15
+ export type ScanEvent = {
16
16
  type: string;
17
17
  status: ScanCheckStatus;
18
18
  details?: ScanEventDetails;
19
19
  };
20
20
  /** How the scan was performed. */
21
- type ScanMode = 'basic' | 'deep';
21
+ export type ScanMode = 'basic' | 'deep';
22
22
  /** A single JavaScript chunk fetched while scanning. */
23
- type BundleChunkInput = {
23
+ export type BundleChunkInput = {
24
24
  url: string;
25
25
  /** Whether the chunk is eagerly loaded on the initial page load. */
26
26
  isMainBundle: boolean;
27
27
  content: string;
28
28
  };
29
29
  /** Locale-weight analysis of a single bundle chunk. */
30
- type ChunkAnalysis = {
30
+ export type ChunkAnalysis = {
31
31
  url: string;
32
32
  fileSize: number;
33
33
  totalLocaleSize: number;
@@ -38,7 +38,7 @@ type ChunkAnalysis = {
38
38
  unusedPercent: number;
39
39
  };
40
40
  /** Aggregated locale-weight analysis across every fetched chunk. */
41
- type BundleContentAnalysis = {
41
+ export type BundleContentAnalysis = {
42
42
  currentLocale: string;
43
43
  totalPageSize: number;
44
44
  renderedContentSize: number;
@@ -54,7 +54,7 @@ type BundleContentAnalysis = {
54
54
  lazyBundleChunks: ChunkAnalysis[];
55
55
  };
56
56
  /** Options controlling how a website is scanned. */
57
- type ScanOptions = {
57
+ export type ScanOptions = {
58
58
  /**
59
59
  * Attempt a deeper, render-based scan using a locally installed `puppeteer`.
60
60
  * When `puppeteer` is not installed, the scan transparently falls back to the
@@ -67,7 +67,7 @@ type ScanOptions = {
67
67
  userAgent?: string;
68
68
  };
69
69
  /** Result of scanning a single page. */
70
- type ScanResult = {
70
+ export type ScanResult = {
71
71
  url: string;
72
72
  /** Whether the scan ran in `basic` or `deep` mode. */
73
73
  mode: ScanMode;
@@ -87,5 +87,4 @@ type ScanResult = {
87
87
  bundle?: BundleContentAnalysis;
88
88
  };
89
89
  //#endregion
90
- export { BundleChunkInput, BundleContentAnalysis, ChunkAnalysis, ScanCheckStatus, ScanEvent, ScanEventDetails, ScanMode, ScanOptions, ScanResult };
91
90
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","names":[],"sources":["../../../src/scan/types.ts"],"mappings":";;;KAGY;;KAGA;EACV;EACA;EACA;;;;;;KAOU;EACV;EACA,QAAQ;EACR,UAAU;;;KAIA;;KAGA;EACV;;EAEA;EACA;;;KAIU;EACV;EACA;EACA;EACA;EACA;EACA;;EAEA;;;KAIU;EACV;EACA;EACA;;EAEA;;EAEA;;EAEA;;EAEA;EACA,kBAAkB;EAClB,kBAAkB;;;KAIR;;;;;;EAMV;;EAEA;;EAEA;;;KAIU;EACV;;EAEA,MAAM;;EAEN;;EAEA;;EAEA;;EAEA,UAAU;;EAEV,QAAQ;;EAER;;EAEA,SAAS"}
1
+ {"version":3,"file":"types.d.ts","names":[],"sources":["../../../src/scan/types.ts"],"mappings":";;;YAGY;;YAGA;EACV;EACA;EACA;;;;;;YAOU;EACV;EACA,QAAQ;EACR,UAAU;;;YAIA;;YAGA;EACV;;EAEA;EACA;;;YAIU;EACV;EACA;EACA;EACA;EACA;EACA;;EAEA;;;YAIU;EACV;EACA;EACA;;EAEA;;EAEA;;EAEA;;EAEA;EACA,kBAAkB;EAClB,kBAAkB;;;YAIR;;;;;;EAMV;;EAEA;;EAEA;;;YAIU;EACV;;EAEA,MAAM;;EAEN;;EAEA;;EAEA;;EAEA,UAAU;;EAEV,QAAQ;;EAER;;EAEA,SAAS"}
@@ -9,8 +9,8 @@ import { FilePathPattern } from "@intlayer/types/filePathPattern";
9
9
  * - `inclusive`: keep every glob match without fabricating missing entries
10
10
  * (read-only load plugins, whose patterns may contain free `**` globs).
11
11
  */
12
- type FileAdapterDiscovery = 'strict' | 'inclusive';
13
- type CreateFileAdapterOptions = {
12
+ export type FileAdapterDiscovery = 'strict' | 'inclusive';
13
+ export type CreateFileAdapterOptions = {
14
14
  /**
15
15
  * Location of the files, as a static string, a templated string
16
16
  * (e.g. `./messages/{{locale}}/{{key}}.json`) or a function building the
@@ -39,12 +39,11 @@ type CreateFileAdapterOptions = {
39
39
  * Handles glob discovery of the source pattern, key/locale extraction from
40
40
  * paths, base-directory resolution, and change-detected atomic writes.
41
41
  */
42
- declare const createFileAdapter: (options: CreateFileAdapterOptions) => ContentAdapter;
42
+ export declare const createFileAdapter: (options: CreateFileAdapterOptions) => ContentAdapter;
43
43
  /**
44
44
  * Default `readEntry` implementation: plain utf-8 read followed by the given
45
45
  * parser. Returns `undefined` for missing or unreadable files.
46
46
  */
47
- declare const createFileReader: (parse: (raw: string) => SyncContent) => (absoluteFilePath: string) => Promise<SyncContent | undefined>;
47
+ export declare const createFileReader: (parse: (raw: string) => SyncContent) => (absoluteFilePath: string) => Promise<SyncContent | undefined>;
48
48
  //#endregion
49
- export { CreateFileAdapterOptions, FileAdapterDiscovery, createFileAdapter, createFileReader };
50
49
  //# sourceMappingURL=createFileAdapter.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"createFileAdapter.d.ts","names":[],"sources":["../../../src/syncPluginKit/createFileAdapter.ts"],"mappings":";;;;;;;;;;;KAyBY;KAEA;;;;;;EAMV,QAAQ;;;;EAKR,OAAO;;;;;;;EAQP,aACE,0BACA,SAAS,sBACN,QAAQ;;;;EAKb,YAAY;;;;;;;;cAYD,oBAAiB,SACnB,6BACR;;;;;cAwNU,mBAAgB,QAClB,gBAAgB,iBAAW,6BACF,QAAQ"}
1
+ {"version":3,"file":"createFileAdapter.d.ts","names":[],"sources":["../../../src/syncPluginKit/createFileAdapter.ts"],"mappings":";;;;;;;;;;;YAyBY;YAEA;;;;;;EAMV,QAAQ;;;;EAKR,OAAO;;;;;;;EAQP,aACE,0BACA,SAAS,sBACN,QAAQ;;;;EAKb,YAAY;;;;;;;;qBAYD,oBAAiB,SACnB,6BACR;;;;;qBAwNU,mBAAgB,QAClB,gBAAgB,iBAAW,6BACF,QAAQ"}
@@ -11,7 +11,6 @@ import { Plugin } from "@intlayer/types/plugin";
11
11
  * payload format. Write-back only processes dictionaries whose `location`
12
12
  * matches this plugin instance, so adapters never see foreign content.
13
13
  */
14
- declare const createSyncPlugin: (options: CreateSyncPluginOptions) => Plugin;
14
+ export declare const createSyncPlugin: (options: CreateSyncPluginOptions) => Plugin;
15
15
  //#endregion
16
- export { createSyncPlugin };
17
16
  //# sourceMappingURL=createSyncPlugin.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"createSyncPlugin.d.ts","names":[],"sources":["../../../src/syncPluginKit/createSyncPlugin.ts"],"mappings":";;;;;;;;;;;;;cAuCa,mBAAgB,SAAa,4BAA0B"}
1
+ {"version":3,"file":"createSyncPlugin.d.ts","names":[],"sources":["../../../src/syncPluginKit/createSyncPlugin.ts"],"mappings":";;;;;;;;;;;;;qBA4Ga,mBAAgB,SAAa,4BAA0B"}
@@ -10,10 +10,9 @@ import { Locale } from "@intlayer/types/allLocales";
10
10
  * Missing placeholders fall back to `'index'` for the key and to
11
11
  * `defaultLocale` for the locale.
12
12
  */
13
- declare const extractKeyAndLocaleFromPath: (filePath: string, maskPattern: string, locales: Locale[], defaultLocale: Locale) => {
13
+ export declare const extractKeyAndLocaleFromPath: (filePath: string, maskPattern: string, locales: Locale[], defaultLocale: Locale) => {
14
14
  key: string;
15
15
  locale: Locale;
16
16
  } | null;
17
17
  //#endregion
18
- export { extractKeyAndLocaleFromPath };
19
18
  //# sourceMappingURL=extractKeyAndLocaleFromPath.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"extractKeyAndLocaleFromPath.d.ts","names":[],"sources":["../../../src/syncPluginKit/extractKeyAndLocaleFromPath.ts"],"mappings":";;;;;;;;;;;;cAea,8BAA2B,kBACtB,qBACG,SACV,UAAQ,eACF;EACZ;EAAa,QAAQ"}
1
+ {"version":3,"file":"extractKeyAndLocaleFromPath.d.ts","names":[],"sources":["../../../src/syncPluginKit/extractKeyAndLocaleFromPath.ts"],"mappings":";;;;;;;;;;;;qBAea,8BAA2B,kBACtB,qBACG,SACV,UAAQ,eACF;EACZ;EAAa,QAAQ"}
@@ -9,7 +9,6 @@ import { FilePathPatternContext } from "@intlayer/types/filePathPattern";
9
9
  * patterns never reference them, so this single cast keeps the partial
10
10
  * context in one audited place instead of scattering `as any` at call sites.
11
11
  */
12
- declare const buildFilePathPatternContext: (key: string, locale?: string) => FilePathPatternContext;
12
+ export declare const buildFilePathPatternContext: (key: string, locale?: string) => FilePathPatternContext;
13
13
  //#endregion
14
- export { buildFilePathPatternContext };
15
14
  //# sourceMappingURL=filePathPatternHelpers.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"filePathPatternHelpers.d.ts","names":[],"sources":["../../../src/syncPluginKit/filePathPatternHelpers.ts"],"mappings":";;;;;;;;;;;cAWa,8BAA2B,aAC3B,oBAEV"}
1
+ {"version":3,"file":"filePathPatternHelpers.d.ts","names":[],"sources":["../../../src/syncPluginKit/filePathPatternHelpers.ts"],"mappings":";;;;;;;;;;;qBAWa,8BAA2B,aAC3B,oBAEV"}
@@ -1,6 +1,6 @@
1
- import { ContentAdapter, ContentEntry, ContentTarget, CreateSyncPluginOptions, FormatCodec, SyncContent, SyncDirection, SyncPluginContext } from "./types.js";
1
+ import { ContentAdapter, ContentEntry, ContentTarget, CreateSyncPluginOptions, FormatCodec, SplitKeysMode, SyncContent, SyncDirection, SyncPluginContext } from "./types.js";
2
2
  import { CreateFileAdapterOptions, FileAdapterDiscovery, createFileAdapter, createFileReader } from "./createFileAdapter.js";
3
3
  import { createSyncPlugin } from "./createSyncPlugin.js";
4
4
  import { extractKeyAndLocaleFromPath } from "./extractKeyAndLocaleFromPath.js";
5
5
  import { buildFilePathPatternContext } from "./filePathPatternHelpers.js";
6
- export { type ContentAdapter, type ContentEntry, type ContentTarget, type CreateFileAdapterOptions, type CreateSyncPluginOptions, type FileAdapterDiscovery, type FormatCodec, type SyncContent, type SyncDirection, type SyncPluginContext, buildFilePathPatternContext, createFileAdapter, createFileReader, createSyncPlugin, extractKeyAndLocaleFromPath };
6
+ export { type ContentAdapter, type ContentEntry, type ContentTarget, type CreateFileAdapterOptions, type CreateSyncPluginOptions, type FileAdapterDiscovery, type FormatCodec, type SplitKeysMode, type SyncContent, type SyncDirection, type SyncPluginContext, buildFilePathPatternContext, createFileAdapter, createFileReader, createSyncPlugin, extractKeyAndLocaleFromPath };
@@ -5,17 +5,17 @@ import { Locale } from "@intlayer/types/allLocales";
5
5
  /**
6
6
  * Structured dictionary content handled by sync plugins.
7
7
  */
8
- type SyncContent = Record<string, unknown>;
8
+ export type SyncContent = Record<string, unknown>;
9
9
  /**
10
10
  * Context handed to every {@link ContentAdapter} call.
11
11
  */
12
- type SyncPluginContext = {
12
+ export type SyncPluginContext = {
13
13
  configuration: IntlayerConfig;
14
14
  };
15
15
  /**
16
16
  * One translatable resource discovered in the external system.
17
17
  */
18
- type ContentEntry = {
18
+ export type ContentEntry = {
19
19
  /** Dictionary key the entry maps to. */
20
20
  key: string;
21
21
  /** Locale of the entry content. */
@@ -35,7 +35,7 @@ type ContentEntry = {
35
35
  /**
36
36
  * Identifies where content must be written back by a {@link ContentAdapter}.
37
37
  */
38
- type ContentTarget = {
38
+ export type ContentTarget = {
39
39
  key: string;
40
40
  locale: Locale;
41
41
  };
@@ -45,7 +45,7 @@ type ContentTarget = {
45
45
  * CMS…). Format concerns belong to {@link FormatCodec}, orchestration to
46
46
  * `createSyncPlugin`.
47
47
  */
48
- type ContentAdapter = {
48
+ export type ContentAdapter = {
49
49
  /**
50
50
  * Enumerate every entry available in the external system.
51
51
  */
@@ -84,13 +84,28 @@ type ContentAdapter = {
84
84
  * set it explicitly (e.g. the file adapter splits when the source pattern
85
85
  * has no `{{key}}` segment).
86
86
  */
87
- detectSplitKeys?: () => Promise<boolean>;
87
+ detectSplitKeys?: () => Promise<SplitKeysMode>;
88
88
  };
89
+ /**
90
+ * How an entry's keys map onto dictionaries.
91
+ *
92
+ * - `false` — one dictionary holds the whole entry.
93
+ * - `true` — each *top-level* key becomes its own dictionary. The
94
+ * `next-intl` / `react-intl` namespace model, where a single
95
+ * `messages/{locale}.json` groups namespaces by first-level key.
96
+ * - `'key-prefix'` — the entry is a *flat* map whose keys are dotted ids
97
+ * (`'footer.github'`); each id's first dot-segment becomes a
98
+ * dictionary and the remainder becomes the key inside it. The
99
+ * single-catalog model of `lingui` and of i18next's default
100
+ * `translation` namespace, where the namespace lives in the id
101
+ * rather than in the file layout.
102
+ */
103
+ export type SplitKeysMode = boolean | 'key-prefix';
89
104
  /**
90
105
  * Format layer of a sync plugin: how a raw string payload maps to structured
91
106
  * dictionary content and back (JSON, PO, XLIFF…).
92
107
  */
93
- type FormatCodec = {
108
+ export type FormatCodec = {
94
109
  /**
95
110
  * Parse a raw payload into dictionary content.
96
111
  * May throw on malformed payloads — callers treat a throw as empty content.
@@ -108,11 +123,11 @@ type FormatCodec = {
108
123
  * - `pull`: only ingest external content as dictionaries (read-only).
109
124
  * - `both`: ingest and write the merged build output back to the source.
110
125
  */
111
- type SyncDirection = 'pull' | 'both';
126
+ export type SyncDirection = 'pull' | 'both';
112
127
  /**
113
128
  * Options of `createSyncPlugin`.
114
129
  */
115
- type CreateSyncPluginOptions = {
130
+ export type CreateSyncPluginOptions = {
116
131
  /** Plugin name reported to the Intlayer engine (e.g. `sync-json`). */
117
132
  name: string;
118
133
  /** Transport used to enumerate, read and write entries. */
@@ -136,12 +151,11 @@ type CreateSyncPluginOptions = {
136
151
  /** Content format of the dictionaries (e.g. `'icu'`, `'po'`). */
137
152
  format?: DictionaryFormat;
138
153
  /**
139
- * Whether each top-level key of an entry becomes its own dictionary instead
140
- * of a single dictionary holding the whole entry (the `next-intl` /
141
- * `react-intl` namespace model). When omitted, falls back to
142
- * {@link ContentAdapter.detectSplitKeys}, then to `false`.
154
+ * How the entry's keys map onto dictionaries — see {@link SplitKeysMode}.
155
+ * When omitted, falls back to {@link ContentAdapter.detectSplitKeys}, then
156
+ * to `false`.
143
157
  */
144
- splitKeys?: boolean;
158
+ splitKeys?: SplitKeysMode;
145
159
  /**
146
160
  * Fixed locale applied to every generated dictionary, overriding the locale
147
161
  * discovered per entry.
@@ -149,5 +163,4 @@ type CreateSyncPluginOptions = {
149
163
  localeOverride?: Locale;
150
164
  };
151
165
  //#endregion
152
- export { ContentAdapter, ContentEntry, ContentTarget, CreateSyncPluginOptions, FormatCodec, SyncContent, SyncDirection, SyncPluginContext };
153
166
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","names":[],"sources":["../../../src/syncPluginKit/types.ts"],"mappings":";;;;;;;KAOY,cAAc;;;;KAKd;EACV,eAAe;;;;;KAML;;EAEV;;EAEA,QAAQ;;;;;EAKR;;;;;;EAMA;;;;;KAMU;EACV;EACA,QAAQ;;;;;;;;KASE;;;;EAIV,OAAO,SAAS,sBAAsB,QAAQ;;;;;;EAO9C,OACE,OAAO,cACP,SAAS,sBACN,QAAQ;;;;;EAMb,QACE,QAAQ,eACR,SAAS,aACT,SAAS,sBACN;;;;;;;EAQL,cACE,QAAQ,eACR,SAAS,sBACN;;;;;;EAOL,kBAAkB,SAAS,sBAAsB;;;;;EAMjD,kBAAkB,SAAS,sBAAsB;;;;;;EAOjD,wBAAwB;;;;;;KAOd;;;;;EAKV,QAAQ,gBAAgB;;;;EAKxB,YAAY,SAAS,aAAa;IAAW,QAAQ;;;;;;;;KAQ3C;;;;KAKA;;EAEV;;EAGA,SAAS;;;;;EAMT,YAAY;;;;;;EAOZ;;;;;EAMA;;EAGA,SAAS;;;;;;;EAQT;;;;;EAMA,iBAAiB"}
1
+ {"version":3,"file":"types.d.ts","names":[],"sources":["../../../src/syncPluginKit/types.ts"],"mappings":";;;;;;;YAOY,cAAc;;;;YAKd;EACV,eAAe;;;;;YAML;;EAEV;;EAEA,QAAQ;;;;;EAKR;;;;;;EAMA;;;;;YAMU;EACV;EACA,QAAQ;;;;;;;;YASE;;;;EAIV,OAAO,SAAS,sBAAsB,QAAQ;;;;;;EAO9C,OACE,OAAO,cACP,SAAS,sBACN,QAAQ;;;;;EAMb,QACE,QAAQ,eACR,SAAS,aACT,SAAS,sBACN;;;;;;;EAQL,cACE,QAAQ,eACR,SAAS,sBACN;;;;;;EAOL,kBAAkB,SAAS,sBAAsB;;;;;EAMjD,kBAAkB,SAAS,sBAAsB;;;;;;EAOjD,wBAAwB,QAAQ;;;;;;;;;;;;;;;;YAiBtB;;;;;YAMA;;;;;EAKV,QAAQ,gBAAgB;;;;EAKxB,YAAY,SAAS,aAAa;IAAW,QAAQ;;;;;;;;YAQ3C;;;;YAKA;;EAEV;;EAGA,SAAS;;;;;EAMT,YAAY;;;;;;EAOZ;;;;;EAMA;;EAGA,SAAS;;;;;;EAOT,YAAY;;;;;EAMZ,iBAAiB"}
@@ -7,7 +7,6 @@ type AutoTransformationOptions = {
7
7
  /**
8
8
  * Automatically decorate content strings with md() or insert() if they match
9
9
  */
10
- declare const autoDecorateContent: (content: any, options?: boolean | AutoTransformationOptions) => any;
10
+ export declare const autoDecorateContent: (content: any, options?: boolean | AutoTransformationOptions) => any;
11
11
  //#endregion
12
- export { autoDecorateContent };
13
12
  //# sourceMappingURL=autoDecorateContent.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"autoDecorateContent.d.ts","names":[],"sources":["../../../src/utils/autoDecorateContent.ts"],"mappings":";KAwEK;EACH;EACA;EACA;;;;;cAMW,sBAAmB,cAClB,oBACO"}
1
+ {"version":3,"file":"autoDecorateContent.d.ts","names":[],"sources":["../../../src/utils/autoDecorateContent.ts"],"mappings":";KAwEK;EACH;EACA;EACA;;;;;qBAMW,sBAAmB,cAClB,oBACO"}
@@ -1,9 +1,9 @@
1
1
  import { RecastParser } from "@intlayer/babel/babelParser";
2
2
  //#region src/utils/babelParser.d.ts
3
3
  /** Drop-in replacement for `recast/parsers/typescript` (TS without JSX). */
4
- declare const typescriptParser: RecastParser;
4
+ export declare const typescriptParser: RecastParser;
5
5
  /** Drop-in replacement for `recast/parsers/babel-ts` (TS *and* JSX). */
6
- declare const babelTsParser: RecastParser;
6
+ export declare const babelTsParser: RecastParser;
7
7
  //#endregion
8
- export { type RecastParser, babelTsParser, typescriptParser };
8
+ export type { RecastParser };
9
9
  //# sourceMappingURL=babelParser.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"babelParser.d.ts","names":[],"sources":["../../../src/utils/babelParser.ts"],"mappings":";;;cA6Da,kBAAkB;;cAKlB,eAAe"}
1
+ {"version":3,"file":"babelParser.d.ts","names":[],"sources":["../../../src/utils/babelParser.ts"],"mappings":";;;qBA6Da,kBAAkB;;qBAKlB,eAAe"}
@@ -21,7 +21,6 @@ import { IntlayerConfig } from "@intlayer/types/config";
21
21
  * // intlayer.config.ts: { content: { codeDir: ['node_modules/my-ds/src'] } }
22
22
  * const files = buildComponentFilesList(config);
23
23
  */
24
- declare const buildComponentFilesList: (config: IntlayerConfig, excludePattern?: string[]) => string[];
24
+ export declare const buildComponentFilesList: (config: IntlayerConfig, excludePattern?: string[]) => string[];
25
25
  //#endregion
26
- export { buildComponentFilesList };
27
26
  //# sourceMappingURL=buildComponentFilesList.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"buildComponentFilesList.d.ts","names":[],"sources":["../../../src/utils/buildComponentFilesList.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;cAqEa,0BAAuB,QAC1B,gBAAc"}
1
+ {"version":3,"file":"buildComponentFilesList.d.ts","names":[],"sources":["../../../src/utils/buildComponentFilesList.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;qBAqEa,0BAAuB,QAC1B,gBAAc"}
@@ -3,7 +3,7 @@ import { IntlayerConfig } from "@intlayer/types/config";
3
3
  /**
4
4
  * Options for building the files list
5
5
  */
6
- type BuildComponentFilesListOptions = {
6
+ export type BuildComponentFilesListOptions = {
7
7
  /**
8
8
  * Glob patterns to match files
9
9
  */
@@ -46,7 +46,7 @@ type BuildComponentFilesListOptions = {
46
46
  * dot: true,
47
47
  * });
48
48
  */
49
- declare const buildComponentFilesList: (config: BuildComponentFilesListOptions) => string[];
49
+ export declare const buildComponentFilesList: (config: BuildComponentFilesListOptions) => string[];
50
50
  /**
51
51
  * Convenience wrapper that derives all file-list options directly from an
52
52
  * `IntlayerConfig` object.
@@ -55,7 +55,6 @@ declare const buildComponentFilesList: (config: BuildComponentFilesListOptions)
55
55
  * content declaration file extensions and any `compiler.excludePattern`
56
56
  * entries defined in the configuration, and includes dot files.
57
57
  */
58
- declare const buildComponentFilesListFromConfig: (intlayerConfig: IntlayerConfig) => string[];
58
+ export declare const buildComponentFilesListFromConfig: (intlayerConfig: IntlayerConfig) => string[];
59
59
  //#endregion
60
- export { BuildComponentFilesListOptions, buildComponentFilesList, buildComponentFilesListFromConfig };
61
60
  //# sourceMappingURL=buildFilesList.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"buildFilesList.d.ts","names":[],"sources":["../../../src/utils/buildFilesList.ts"],"mappings":";;;;;KAOY;;;;EAIV;;;;EAIA;;;;;;EAMA;;;;EAIA;;;;;;;;;;;;;;;;;;;;;;;;;cAmDW,0BAAuB,QAC1B;;;;;;;;;cAqDG,oCAAiC,gBAC5B"}
1
+ {"version":3,"file":"buildFilesList.d.ts","names":[],"sources":["../../../src/utils/buildFilesList.ts"],"mappings":";;;;;YAOY;;;;EAIV;;;;EAIA;;;;;;EAMA;;;;EAIA;;;;;;;;;;;;;;;;;;;;;;;;;qBAmDW,0BAAuB,QAC1B;;;;;;;;;qBAqDG,oCAAiC,gBAC5B"}
@@ -10,7 +10,6 @@
10
10
  * chunkArray(['a', 'b', 'c', 'd', 'e'], 2); // [['a', 'b'], ['c', 'd'], ['e']]
11
11
  * ```
12
12
  */
13
- declare const chunkArray: <T>(items: T[], chunkSize: number) => T[][];
13
+ export declare const chunkArray: <T>(items: T[], chunkSize: number) => T[][];
14
14
  //#endregion
15
- export { chunkArray };
16
15
  //# sourceMappingURL=chunkArray.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"chunkArray.d.ts","names":[],"sources":["../../../src/utils/chunkArray.ts"],"mappings":";;;;;;;;;;;;cAWa,aAAc,GAAC,OAAS,KAAG,sBAAsB"}
1
+ {"version":3,"file":"chunkArray.d.ts","names":[],"sources":["../../../src/utils/chunkArray.ts"],"mappings":";;;;;;;;;;;;qBAWa,aAAc,GAAC,OAAS,KAAG,sBAAsB"}
@@ -8,7 +8,7 @@
8
8
  */
9
9
  type JSONPrimitive = string | number | boolean | null;
10
10
  type JSONValue = JSONPrimitive | JSONObject | JSONArray;
11
- type JSONObject = {
11
+ export type JSONObject = {
12
12
  [k: string]: JSONValue;
13
13
  };
14
14
  type JSONArray = JSONValue[];
@@ -27,7 +27,7 @@ type StrAppendPatch = {
27
27
  };
28
28
  type Patch = SetPatch | StrAppendPatch;
29
29
  type RootType = 'object' | 'array';
30
- type JsonChunk = {
30
+ export type JsonChunk = {
31
31
  schemaVersion: 1;
32
32
  index: number;
33
33
  total: number;
@@ -38,7 +38,7 @@ type JsonChunk = {
38
38
  /**
39
39
  * Split JSON into chunks constrained by character count of serialized chunk.
40
40
  */
41
- declare const chunkJSON: (value: JSONObject | JSONArray, maxChars: number) => JsonChunk[];
41
+ export declare const chunkJSON: (value: JSONObject | JSONArray, maxChars: number) => JsonChunk[];
42
42
  /**
43
43
  * Reassemble JSON from chunks.
44
44
  * - Validates checksums and indices.
@@ -49,8 +49,7 @@ declare const chunkJSON: (value: JSONObject | JSONArray, maxChars: number) => Js
49
49
  * Useful for processing individual chunks in a pipeline where you don't have all chunks yet.
50
50
  * Note: This will only reconstruct the partial content contained in this chunk.
51
51
  */
52
- declare const reconstructFromSingleChunk: (chunk: JsonChunk) => JSONObject | JSONArray;
53
- declare const assembleJSON: (chunks: JsonChunk[]) => JSONObject | JSONArray;
52
+ export declare const reconstructFromSingleChunk: (chunk: JsonChunk) => JSONObject | JSONArray;
53
+ export declare const assembleJSON: (chunks: JsonChunk[]) => JSONObject | JSONArray;
54
54
  //#endregion
55
- export { JSONObject, JsonChunk, assembleJSON, chunkJSON, reconstructFromSingleChunk };
56
55
  //# sourceMappingURL=chunkJSON.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"chunkJSON.d.ts","names":[],"sources":["../../../src/utils/chunkJSON.ts"],"mappings":";;;;;;;;KAUK;KACA,YAAY,gBAAgB,aAAa;KAElC;GACT,YAAY;;KAGV,YAAY;KAEZ,OAAO;KAEP;EAAa;EAAW,MAAM;EAAM,OAAO;;KAC3C;EACH;EACA,MAAM;EACN;EACA;EACA;;KAEG,QAAQ,WAAW;KAEnB;KAEO;EACV;EACA;EACA;EACA,UAAU;EACV;EACA,SAAS;;;;;cAiME,YAAS,OACb,aAAa,WAAS,qBAE5B;;;;;;;;;;;cAsHU,6BAA0B,OAC9B,cACN,aAAa;cAiGH,eAAY,QAAY,gBAAc,aAAa"}
1
+ {"version":3,"file":"chunkJSON.d.ts","names":[],"sources":["../../../src/utils/chunkJSON.ts"],"mappings":";;;;;;;;KAUK;KACA,YAAY,gBAAgB,aAAa;YAElC;GACT,YAAY;;KAGV,YAAY;KAEZ,OAAO;KAEP;EAAa;EAAW,MAAM;EAAM,OAAO;;KAC3C;EACH;EACA,MAAM;EACN;EACA;EACA;;KAEG,QAAQ,WAAW;KAEnB;YAEO;EACV;EACA;EACA;EACA,UAAU;EACV;EACA,SAAS;;;;;qBAiME,YAAS,OACb,aAAa,WAAS,qBAE5B;;;;;;;;;;;qBAsHU,6BAA0B,OAC9B,cACN,aAAa;qBAiGH,eAAY,QAAY,gBAAc,aAAa"}
@@ -0,0 +1,113 @@
1
+ import { IntlayerConfig } from "@intlayer/types/config";
2
+ //#region src/utils/contentWatcherLock.d.ts
3
+ /**
4
+ * What kind of process is watching the content declarations.
5
+ *
6
+ * - `cli` — the `intlayer watch` / `intlayer build --watch` command.
7
+ * - `bundler` — an Intlayer bundler plugin (e.g. `withIntlayer` on Next.js).
8
+ */
9
+ export type ContentWatcherSource = 'cli' | 'bundler';
10
+ export type ContentWatcherOwner = {
11
+ /** PID of the process holding the watcher. */
12
+ pid: number;
13
+ source: ContentWatcherSource;
14
+ /**
15
+ * How the owner should be named in a message, e.g. `intlayer watch` or
16
+ * `next-intlayer`.
17
+ */
18
+ label: string;
19
+ /**
20
+ * Release from which a `bundler` owner watches the content declarations on
21
+ * its own, so a CLI watcher finding it can name the version that made the
22
+ * parallel command redundant without keeping a table of its own.
23
+ */
24
+ since?: string;
25
+ };
26
+ /**
27
+ * Set on every process spawned by `intlayer watch --with` (and
28
+ * `intlayer build --watch --with`), so a bundler plugin running as that child
29
+ * knows a CLI watcher is already covering the project — without having to
30
+ * depend on the two processes reaching the lock file in a given order.
31
+ *
32
+ * Holds the label of the command that set it.
33
+ */
34
+ export declare const CLI_CONTENT_WATCHER_ENV_VAR = "INTLAYER_CLI_CONTENT_WATCHER";
35
+ /**
36
+ * Path of the lock coordinating every content watcher of one project.
37
+ *
38
+ * Deliberately at the root of `.intlayer` rather than in its `cache`
39
+ * subdirectory: `cleanOutputDir` wipes every subdirectory of `.intlayer`, so a
40
+ * lock kept in `cache` would be erased by any `prepareIntlayer` that cleans —
41
+ * after which a bundler plugin would see no owner and start a second watcher
42
+ * next to the `intlayer watch` still running. The root itself is never removed.
43
+ *
44
+ * @param configuration - The resolved Intlayer configuration.
45
+ */
46
+ export declare const getContentWatcherLockFilePath: (configuration: IntlayerConfig) => string;
47
+ /**
48
+ * Reads the lock, removing it when it describes a process that has since died.
49
+ *
50
+ * An unreadable or malformed lock is treated as abandoned: a corrupted file
51
+ * must never block the watcher for a whole dev session.
52
+ *
53
+ * @returns The live owner, or `null` when nothing is watching.
54
+ */
55
+ export declare const getContentWatcherOwner: (configuration: IntlayerConfig) => Promise<ContentWatcherOwner | null>;
56
+ /**
57
+ * Tries to become the process that watches this project's content
58
+ * declarations.
59
+ *
60
+ * Creating the file with `wx` is atomic, so exactly one process wins even when
61
+ * several try at the same moment — which is the normal case on Next.js, where
62
+ * `next.config.*` is evaluated in more than one process.
63
+ *
64
+ * @param configuration - The resolved Intlayer configuration.
65
+ * @param owner - How this process should describe itself to the others.
66
+ * @returns `true` when this process now owns the watcher.
67
+ */
68
+ export declare const acquireContentWatcherLock: (configuration: IntlayerConfig, owner: Omit<ContentWatcherOwner, 'pid'>) => Promise<boolean>;
69
+ /**
70
+ * The CLI watcher command this process was spawned by, or `null` when it was
71
+ * not started through `intlayer watch --with`.
72
+ */
73
+ export declare const getCliContentWatcherLabel: () => string | null;
74
+ /**
75
+ * Registers a CLI command as the content watcher of this project.
76
+ *
77
+ * Call it *before* spawning a `--with` child: taking the lock first means the
78
+ * bundler plugin inside that child never races the command for it, and the
79
+ * environment marker makes the child's decision independent of the filesystem
80
+ * altogether.
81
+ *
82
+ * @param configuration - The resolved Intlayer configuration.
83
+ * @param label - How the command should be named in a message.
84
+ * @returns The bundler already watching this project, or `null` when the
85
+ * command took the watcher for itself. A CLI watcher never stands down on that
86
+ * answer — watching is what it was asked to do — but reporting it lets the user
87
+ * know the parallel command has become redundant.
88
+ */
89
+ export declare const claimCliContentWatcher: (configuration: IntlayerConfig, label: string) => Promise<ContentWatcherOwner | null>;
90
+ type RedundantWatcherReport = {
91
+ /** Name of the CLI command watching, e.g. `intlayer watch`. */
92
+ cliLabel: string;
93
+ /** Name of the bundler integration watching, e.g. `next-intlayer`. */
94
+ bundlerLabel: string;
95
+ /**
96
+ * Release from which the bundler integration watches on its own. Omitted when
97
+ * the integration did not report one.
98
+ */
99
+ since?: string;
100
+ };
101
+ /**
102
+ * Reports a CLI watcher running alongside a bundler integration that watches
103
+ * on its own, and points at the parallel command as the part to drop.
104
+ *
105
+ * Emitted at most once per process: a bundler config is evaluated several times
106
+ * per command, and callers may re-enter this on a retry loop.
107
+ *
108
+ * @param configuration - The resolved Intlayer configuration.
109
+ * @param report - Who is watching, and from which release it became redundant.
110
+ */
111
+ export declare const reportRedundantContentWatcher: (configuration: IntlayerConfig, { cliLabel, bundlerLabel, since }: RedundantWatcherReport) => void;
112
+ //#endregion
113
+ //# sourceMappingURL=contentWatcherLock.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contentWatcherLock.d.ts","names":[],"sources":["../../../src/utils/contentWatcherLock.ts"],"mappings":";;;;;;;;YAaY;YAEA;;EAEV;EACA,QAAQ;;;;;EAKR;;;;;;EAMA;;;;;;;;;;qBAWW;;;;;;;;;;;;qBAkCA,gCAA6B,eACzB;;;;;;;;;qBA2BJ,yBAAsB,eAClB,mBACd,QAAQ;;;;;;;;;;;;;qBAuCE,4BAAyB,eACrB,gBAAc,OACtB,KAAK,gCACX;;;;;qBAkCU;;;;;;;;;;;;;;;;qBAkBA,yBAAsB,eAClB,gBAAc,kBAE5B,QAAQ;KAoBN;;EAEH;;EAEA;;;;;EAKA;;;;;;;;;;;;qBAaW,gCAA6B,eACzB,kBAAc,UAAA,cAAA,SACM"}
@@ -1,8 +1,7 @@
1
1
  import { LocalesValues } from "@intlayer/types/module_augmentation";
2
2
  import { ANSIColorsType } from "@intlayer/config/logger";
3
3
  //#region src/utils/formatter.d.ts
4
- declare const formatPath: (path: string | string[], color?: ANSIColorsType | false) => string;
5
- declare const formatLocale: (locale: LocalesValues | LocalesValues[], color?: ANSIColorsType | false) => string;
4
+ export declare const formatPath: (path: string | string[], color?: ANSIColorsType | false) => string;
5
+ export declare const formatLocale: (locale: LocalesValues | LocalesValues[], color?: ANSIColorsType | false) => string;
6
6
  //#endregion
7
- export { formatLocale, formatPath };
8
7
  //# sourceMappingURL=formatter.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"formatter.d.ts","names":[],"sources":["../../../src/utils/formatter.ts"],"mappings":";;;cAYa,aAAU,yBACE,QACf;cAYG,eAAY,QACf,gBAAgB,iBAAe,QAChC"}
1
+ {"version":3,"file":"formatter.d.ts","names":[],"sources":["../../../src/utils/formatter.ts"],"mappings":";;;qBAYa,aAAU,yBACE,QACf;qBAYG,eAAY,QACf,gBAAgB,iBAAe,QAChC"}
@@ -5,7 +5,6 @@ type TrunkOptions = {
5
5
  charStart?: number;
6
6
  charLength?: number;
7
7
  };
8
- declare const getChunk: (text: string, options?: TrunkOptions) => string;
8
+ export declare const getChunk: (text: string, options?: TrunkOptions) => string;
9
9
  //#endregion
10
- export { getChunk };
11
10
  //# sourceMappingURL=getChunk.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getChunk.d.ts","names":[],"sources":["../../../src/utils/getChunk.ts"],"mappings":";KAEK;EACH;EACA;EACA;EACA;;cAGW,WAAQ,cAAgB,UAAW"}
1
+ {"version":3,"file":"getChunk.d.ts","names":[],"sources":["../../../src/utils/getChunk.ts"],"mappings":";KAEK;EACH;EACA;EACA;EACA;;qBAGW,WAAQ,cAAgB,UAAW"}
@@ -8,7 +8,6 @@ import { IntlayerConfig } from "@intlayer/types/config";
8
8
  * format 'ts' -> '.content.ts'
9
9
  * format 'esm' -> '.content.js' (if matching .content.js is found in config)
10
10
  */
11
- declare const getContentExtension: (format: 'ts' | 'esm' | 'cjs' | 'json' | 'jsonc' | 'json5' | (string & {}), configuration: IntlayerConfig) => string;
11
+ export declare const getContentExtension: (format: 'ts' | 'esm' | 'cjs' | 'json' | 'jsonc' | 'json5' | (string & {}), configuration: IntlayerConfig) => string;
12
12
  //#endregion
13
- export { getContentExtension };
14
13
  //# sourceMappingURL=getContentExtension.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getContentExtension.d.ts","names":[],"sources":["../../../src/utils/getContentExtension.ts"],"mappings":";;;;;;;;;;cAUa,sBAAmB,2EAC2C,eAC1D"}
1
+ {"version":3,"file":"getContentExtension.d.ts","names":[],"sources":["../../../src/utils/getContentExtension.ts"],"mappings":";;;;;;;;;;qBAUa,sBAAmB,2EAC2C,eAC1D"}
@@ -1,8 +1,7 @@
1
1
  //#region src/utils/getFormatFromExtension.d.ts
2
- type Format = 'ts' | 'cjs' | 'esm' | 'json' | 'jsonc' | 'json5' | 'md' | 'yaml';
3
- type Extension = '.ts' | '.tsx' | '.js' | '.jsx' | '.cjs' | '.cjsx' | '.mjs' | '.mjsx' | '.json' | '.jsonc' | '.json5' | '.md' | '.mdx' | '.yaml' | '.yml';
4
- declare const getFormatFromExtension: (extension: Extension | (string & {})) => Format;
5
- declare const getExtensionFromFormat: (format: Format | (string & {})) => Extension;
2
+ export type Format = 'ts' | 'cjs' | 'esm' | 'json' | 'jsonc' | 'json5' | 'md' | 'yaml';
3
+ export type Extension = '.ts' | '.tsx' | '.js' | '.jsx' | '.cjs' | '.cjsx' | '.mjs' | '.mjsx' | '.json' | '.jsonc' | '.json5' | '.md' | '.mdx' | '.yaml' | '.yml';
4
+ export declare const getFormatFromExtension: (extension: Extension | (string & {})) => Format;
5
+ export declare const getExtensionFromFormat: (format: Format | (string & {})) => Extension;
6
6
  //#endregion
7
- export { Extension, Format, getExtensionFromFormat, getFormatFromExtension };
8
7
  //# sourceMappingURL=getFormatFromExtension.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getFormatFromExtension.d.ts","names":[],"sources":["../../../src/utils/getFormatFromExtension.ts"],"mappings":";KAAY;KAUA;cAiBC,yBAAsB,WACtB,8BACV;cA4BU,yBAAsB,QACzB,2BACP"}
1
+ {"version":3,"file":"getFormatFromExtension.d.ts","names":[],"sources":["../../../src/utils/getFormatFromExtension.ts"],"mappings":";YAAY;YAUA;qBAiBC,yBAAsB,WACtB,8BACV;qBA4BU,yBAAsB,QACzB,2BACP"}
@@ -2,7 +2,6 @@
2
2
  /**
3
3
  * Fast hashing using cyrb53 algorithm for small unique strings with low collisions risk
4
4
  */
5
- declare const getPathHash: (filePath: string) => string;
5
+ export declare const getPathHash: (filePath: string) => string;
6
6
  //#endregion
7
- export { getPathHash };
8
7
  //# sourceMappingURL=getPathHash.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"getPathHash.d.ts","names":[],"sources":["../../../src/utils/getPathHash.ts"],"mappings":";;;;cAGa,cAAW"}
1
+ {"version":3,"file":"getPathHash.d.ts","names":[],"sources":["../../../src/utils/getPathHash.ts"],"mappings":";;;;qBAGa,cAAW"}