@o3r/core 10.0.0-next.8 → 11.0.0-next.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 (497) hide show
  1. package/README.md +38 -13
  2. package/builders/app-version/index.d.ts.map +1 -1
  3. package/builders/app-version/index.js +1 -1
  4. package/builders/app-version/index.js.map +1 -1
  5. package/builders/app-version/schema.json +1 -1
  6. package/builders/lib-build/schema.json +1 -1
  7. package/builders/multi-watcher/schema.json +1 -1
  8. package/builders/ngc/schema.json +1 -1
  9. package/builders/pattern-replacement/index.d.ts.map +1 -1
  10. package/builders/pattern-replacement/index.js +5 -5
  11. package/builders/pattern-replacement/index.js.map +1 -1
  12. package/builders/pattern-replacement/schema.json +1 -1
  13. package/builders/run-script/index.d.ts +4 -0
  14. package/builders/run-script/index.d.ts.map +1 -0
  15. package/builders/run-script/index.js +34 -0
  16. package/builders/run-script/index.js.map +1 -0
  17. package/builders/run-script/schema.d.ts +6 -0
  18. package/builders/run-script/schema.d.ts.map +1 -0
  19. package/{schematics/library → builders/run-script}/schema.js.map +1 -1
  20. package/builders/run-script/schema.json +15 -0
  21. package/builders.json +5 -0
  22. package/collection.json +0 -23
  23. package/core/application/dgp.interfaces.d.ts +6 -3
  24. package/core/application/dgp.interfaces.d.ts.map +1 -1
  25. package/core/devkit/devtools.interface.d.ts +16 -2
  26. package/core/devkit/devtools.interface.d.ts.map +1 -1
  27. package/core/index.d.ts +1 -0
  28. package/core/index.d.ts.map +1 -1
  29. package/core/index.js +1 -0
  30. package/core/index.js.map +1 -1
  31. package/core/interfaces/configuration.d.ts +39 -17
  32. package/core/interfaces/configuration.d.ts.map +1 -1
  33. package/core/interfaces/index.d.ts +0 -3
  34. package/core/interfaces/index.d.ts.map +1 -1
  35. package/core/interfaces/index.js +0 -3
  36. package/core/interfaces/index.js.map +1 -1
  37. package/core/metadata/component.decorator.d.ts +0 -1
  38. package/core/metadata/component.decorator.d.ts.map +1 -1
  39. package/core/metadata/component.decorator.js +0 -1
  40. package/core/metadata/component.decorator.js.map +1 -1
  41. package/core/metadata/component.identifier.d.ts +7 -0
  42. package/core/metadata/component.identifier.d.ts.map +1 -0
  43. package/core/metadata/component.identifier.js +9 -0
  44. package/core/metadata/component.identifier.js.map +1 -0
  45. package/core/metadata/index.d.ts +1 -0
  46. package/core/metadata/index.d.ts.map +1 -1
  47. package/core/metadata/index.js +1 -0
  48. package/core/metadata/index.js.map +1 -1
  49. package/core/rules-engine/index.d.ts +2 -0
  50. package/core/rules-engine/index.d.ts.map +1 -0
  51. package/core/rules-engine/index.js +2 -0
  52. package/core/rules-engine/index.js.map +1 -0
  53. package/core/rules-engine/rules-engine.interfaces.d.ts +24 -0
  54. package/core/rules-engine/rules-engine.interfaces.d.ts.map +1 -0
  55. package/core/rules-engine/rules-engine.interfaces.js +2 -0
  56. package/core/rules-engine/rules-engine.interfaces.js.map +1 -0
  57. package/esm2022/core/application/dgp.interfaces.mjs +1 -1
  58. package/esm2022/core/devkit/devtools.interface.mjs +1 -1
  59. package/esm2022/core/index.mjs +2 -1
  60. package/esm2022/core/interfaces/configuration.mjs +1 -1
  61. package/esm2022/core/interfaces/index.mjs +1 -4
  62. package/esm2022/core/metadata/component.decorator.mjs +1 -2
  63. package/esm2022/core/metadata/component.identifier.mjs +9 -0
  64. package/esm2022/core/metadata/index.mjs +2 -1
  65. package/esm2022/core/rules-engine/index.mjs +2 -0
  66. package/esm2022/core/rules-engine/rules-engine.interfaces.mjs +2 -0
  67. package/esm2022/log/logger.mjs +1 -1
  68. package/esm2022/messages/message.helpers.mjs +1 -5
  69. package/esm2022/store/async/async-entity.adapter.mjs +1 -2
  70. package/esm2022/store/async/async.adapter.mjs +1 -1
  71. package/esm2022/store/async/async.helpers.mjs +1 -4
  72. package/esm2022/store/async/async.operators.mjs +3 -4
  73. package/esm2022/store/async/async.serializer.mjs +1 -4
  74. package/esm2022/store/index.mjs +1 -2
  75. package/esm2022/utils/debug/debug.helper.mjs +1 -3
  76. package/esm2022/utils/deep-fill/deep-fill.mjs +23 -28
  77. package/esm2022/utils/rendering/rendering.helpers.mjs +1 -2
  78. package/fesm2022/o3r-core.mjs +47 -169
  79. package/fesm2022/o3r-core.mjs.map +1 -1
  80. package/log/logger.d.ts +0 -5
  81. package/log/logger.d.ts.map +1 -1
  82. package/messages/message.helpers.d.ts +0 -3
  83. package/messages/message.helpers.d.ts.map +1 -1
  84. package/messages/message.helpers.js +0 -4
  85. package/messages/message.helpers.js.map +1 -1
  86. package/migration.json +5 -0
  87. package/package.json +46 -39
  88. package/schematics/add-modules/index.d.ts +1 -2
  89. package/schematics/add-modules/index.d.ts.map +1 -1
  90. package/schematics/add-modules/index.js +16 -9
  91. package/schematics/add-modules/index.js.map +1 -1
  92. package/schematics/add-modules/schema.d.ts +5 -1
  93. package/schematics/add-modules/schema.d.ts.map +1 -1
  94. package/schematics/add-modules/schema.json +14 -4
  95. package/schematics/component/container/index.d.ts +0 -1
  96. package/schematics/component/container/index.d.ts.map +1 -1
  97. package/schematics/component/container/index.js +1 -3
  98. package/schematics/component/container/index.js.map +1 -1
  99. package/schematics/component/container/schema.json +1 -1
  100. package/schematics/component/index.d.ts.map +1 -1
  101. package/schematics/component/index.js +5 -2
  102. package/schematics/component/index.js.map +1 -1
  103. package/schematics/component/presenter/index.d.ts +0 -1
  104. package/schematics/component/presenter/index.d.ts.map +1 -1
  105. package/schematics/component/presenter/index.js +9 -9
  106. package/schematics/component/presenter/index.js.map +1 -1
  107. package/schematics/component/presenter/schema.json +4 -3
  108. package/schematics/component/schema.json +4 -4
  109. package/schematics/component/structures.types.d.ts +3 -2
  110. package/schematics/component/structures.types.d.ts.map +1 -1
  111. package/schematics/component/structures.types.js +1 -0
  112. package/schematics/component/structures.types.js.map +1 -1
  113. package/schematics/context-to-component/index.d.ts.map +1 -1
  114. package/schematics/context-to-component/index.js +1 -1
  115. package/schematics/context-to-component/index.js.map +1 -1
  116. package/schematics/context-to-component/schema.json +1 -1
  117. package/schematics/convert-component/index.js +2 -2
  118. package/schematics/convert-component/index.js.map +1 -1
  119. package/schematics/convert-component/schema.json +1 -1
  120. package/schematics/ng-add/index.d.ts.map +1 -1
  121. package/schematics/ng-add/index.js +30 -31
  122. package/schematics/ng-add/index.js.map +1 -1
  123. package/schematics/ng-add/project-setup/index.d.ts +0 -1
  124. package/schematics/ng-add/project-setup/index.d.ts.map +1 -1
  125. package/schematics/ng-add/project-setup/index.js +16 -65
  126. package/schematics/ng-add/project-setup/index.js.map +1 -1
  127. package/schematics/ng-add/schema.d.ts +7 -46
  128. package/schematics/ng-add/schema.d.ts.map +1 -1
  129. package/schematics/ng-add/schema.json +16 -86
  130. package/schematics/ng-add/updates-for-v8/cms-adapters/update-builders-names.d.ts.map +1 -1
  131. package/schematics/ng-add/updates-for-v8/cms-adapters/update-builders-names.js +7 -3
  132. package/schematics/ng-add/updates-for-v8/cms-adapters/update-builders-names.js.map +1 -1
  133. package/schematics/ng-add/updates-for-v8/generators/update-generators-names.d.ts.map +1 -1
  134. package/schematics/ng-add/updates-for-v8/generators/update-generators-names.js +7 -2
  135. package/schematics/ng-add/updates-for-v8/generators/update-generators-names.js.map +1 -1
  136. package/schematics/ng-add-create/schema.json +1 -1
  137. package/schematics/ng-add-create/templates/schematics/ng-add/schema.json.template +2 -2
  138. package/schematics/ng-update/index.d.ts +4 -0
  139. package/schematics/ng-update/index.d.ts.map +1 -1
  140. package/schematics/ng-update/index.js +14 -1
  141. package/schematics/ng-update/index.js.map +1 -1
  142. package/schematics/ng-update/v10.0/configuration.d.ts +9 -0
  143. package/schematics/ng-update/v10.0/configuration.d.ts.map +1 -0
  144. package/schematics/ng-update/v10.0/configuration.js +23 -0
  145. package/schematics/ng-update/v10.0/configuration.js.map +1 -0
  146. package/schematics/page/index.d.ts +0 -1
  147. package/schematics/page/index.d.ts.map +1 -1
  148. package/schematics/page/index.js +6 -11
  149. package/schematics/page/index.js.map +1 -1
  150. package/schematics/page/schema.json +1 -1
  151. package/schematics/renovate/schema.json +1 -1
  152. package/schematics/renovate/templates/azure-pipelines.ugrade.yml +1 -1
  153. package/schematics/rule-factories/additional-modules/index.d.ts +0 -1
  154. package/schematics/rule-factories/additional-modules/index.d.ts.map +1 -1
  155. package/schematics/rule-factories/additional-modules/index.js +14 -18
  156. package/schematics/rule-factories/additional-modules/index.js.map +1 -1
  157. package/schematics/rule-factories/component/common.js +2 -2
  158. package/schematics/rule-factories/component/common.js.map +1 -1
  159. package/schematics/rule-factories/customization-environment/index.d.ts +0 -1
  160. package/schematics/rule-factories/customization-environment/index.d.ts.map +1 -1
  161. package/schematics/rule-factories/customization-environment/index.js +9 -30
  162. package/schematics/rule-factories/customization-environment/index.js.map +1 -1
  163. package/schematics/rule-factories/index.d.ts +0 -3
  164. package/schematics/rule-factories/index.d.ts.map +1 -1
  165. package/schematics/rule-factories/index.js +0 -3
  166. package/schematics/rule-factories/index.js.map +1 -1
  167. package/schematics/rule-factories/o3r-basic-updates/index.d.ts +1 -2
  168. package/schematics/rule-factories/o3r-basic-updates/index.d.ts.map +1 -1
  169. package/schematics/rule-factories/o3r-basic-updates/index.js +7 -4
  170. package/schematics/rule-factories/o3r-basic-updates/index.js.map +1 -1
  171. package/schematics/rule-factories/otter-environment/index.d.ts +0 -1
  172. package/schematics/rule-factories/otter-environment/index.d.ts.map +1 -1
  173. package/schematics/rule-factories/otter-environment/index.js +8 -13
  174. package/schematics/rule-factories/otter-environment/index.js.map +1 -1
  175. package/schematics/rule-factories/store/index.d.ts.map +1 -1
  176. package/schematics/rule-factories/store/index.js +30 -13
  177. package/schematics/rule-factories/store/index.js.map +1 -1
  178. package/schematics/schematics-update/schema.json +1 -1
  179. package/schematics/service/index.d.ts +0 -1
  180. package/schematics/service/index.d.ts.map +1 -1
  181. package/schematics/service/index.js +1 -2
  182. package/schematics/service/index.js.map +1 -1
  183. package/schematics/service/schema.json +1 -1
  184. package/schematics/shared/presets/all.preset.d.ts +10 -0
  185. package/schematics/shared/presets/all.preset.d.ts.map +1 -0
  186. package/schematics/shared/presets/all.preset.js +40 -0
  187. package/schematics/shared/presets/all.preset.js.map +1 -0
  188. package/schematics/shared/presets/external.preset.d.ts +10 -0
  189. package/schematics/shared/presets/external.preset.d.ts.map +1 -0
  190. package/schematics/shared/presets/external.preset.js +25 -0
  191. package/schematics/shared/presets/external.preset.js.map +1 -0
  192. package/schematics/shared/presets/helpers.js +1 -1
  193. package/schematics/shared/presets/helpers.js.map +1 -1
  194. package/schematics/shared/presets/index.d.ts +1 -0
  195. package/schematics/shared/presets/index.d.ts.map +1 -1
  196. package/schematics/shared/presets/index.js +4 -1
  197. package/schematics/shared/presets/index.js.map +1 -1
  198. package/schematics/show-modules/index.d.ts +1 -2
  199. package/schematics/show-modules/index.d.ts.map +1 -1
  200. package/schematics/show-modules/index.js +3 -5
  201. package/schematics/show-modules/index.js.map +1 -1
  202. package/schematics/show-modules/schema.json +1 -1
  203. package/schematics/store/entity-async/index.d.ts.map +1 -1
  204. package/schematics/store/entity-async/index.js +4 -0
  205. package/schematics/store/entity-async/index.js.map +1 -1
  206. package/schematics/store/entity-async/schema.json +1 -1
  207. package/schematics/store/entity-async/templates/__storeName@dasherize__.state.ts +1 -1
  208. package/schematics/store/entity-sync/index.d.ts.map +1 -1
  209. package/schematics/store/entity-sync/index.js +4 -0
  210. package/schematics/store/entity-sync/index.js.map +1 -1
  211. package/schematics/store/entity-sync/schema.json +1 -1
  212. package/schematics/store/entity-sync/templates/__storeName@dasherize__.state.ts +1 -1
  213. package/schematics/store/schema.json +1 -1
  214. package/schematics/store/simple-async/index.d.ts.map +1 -1
  215. package/schematics/store/simple-async/index.js +2 -0
  216. package/schematics/store/simple-async/index.js.map +1 -1
  217. package/schematics/store/simple-async/schema.json +1 -1
  218. package/schematics/store/simple-sync/index.d.ts.map +1 -1
  219. package/schematics/store/simple-sync/index.js +1 -0
  220. package/schematics/store/simple-sync/index.js.map +1 -1
  221. package/schematics/store/simple-sync/schema.json +1 -1
  222. package/schematics/store-action/schema.json +1 -1
  223. package/store/async/async-entity.adapter.d.ts +0 -8
  224. package/store/async/async-entity.adapter.d.ts.map +1 -1
  225. package/store/async/async-entity.adapter.js +0 -1
  226. package/store/async/async-entity.adapter.js.map +1 -1
  227. package/store/async/async.adapter.d.ts +0 -13
  228. package/store/async/async.adapter.d.ts.map +1 -1
  229. package/store/async/async.adapter.js.map +1 -1
  230. package/store/async/async.helpers.d.ts +0 -3
  231. package/store/async/async.helpers.d.ts.map +1 -1
  232. package/store/async/async.helpers.js +0 -3
  233. package/store/async/async.helpers.js.map +1 -1
  234. package/store/async/async.operators.d.ts +2 -3
  235. package/store/async/async.operators.d.ts.map +1 -1
  236. package/store/async/async.operators.js +2 -3
  237. package/store/async/async.operators.js.map +1 -1
  238. package/store/async/async.serializer.d.ts +0 -3
  239. package/store/async/async.serializer.d.ts.map +1 -1
  240. package/store/async/async.serializer.js +0 -3
  241. package/store/async/async.serializer.js.map +1 -1
  242. package/store/index.d.ts +0 -1
  243. package/store/index.d.ts.map +1 -1
  244. package/store/index.js +0 -1
  245. package/store/index.js.map +1 -1
  246. package/utils/debug/debug.helper.d.ts +0 -2
  247. package/utils/debug/debug.helper.d.ts.map +1 -1
  248. package/utils/debug/debug.helper.js +0 -2
  249. package/utils/debug/debug.helper.js.map +1 -1
  250. package/utils/deep-fill/deep-fill.d.ts +17 -12
  251. package/utils/deep-fill/deep-fill.d.ts.map +1 -1
  252. package/utils/deep-fill/deep-fill.js +22 -27
  253. package/utils/deep-fill/deep-fill.js.map +1 -1
  254. package/utils/rendering/rendering.helpers.d.ts +0 -1
  255. package/utils/rendering/rendering.helpers.d.ts.map +1 -1
  256. package/utils/rendering/rendering.helpers.js +0 -1
  257. package/utils/rendering/rendering.helpers.js.map +1 -1
  258. package/builders/package.json +0 -3
  259. package/core/interfaces/block.d.ts +0 -9
  260. package/core/interfaces/block.d.ts.map +0 -1
  261. package/core/interfaces/block.js +0 -2
  262. package/core/interfaces/block.js.map +0 -1
  263. package/core/interfaces/exposed-component.d.ts +0 -10
  264. package/core/interfaces/exposed-component.d.ts.map +0 -1
  265. package/core/interfaces/exposed-component.js +0 -2
  266. package/core/interfaces/exposed-component.js.map +0 -1
  267. package/core/interfaces/page.d.ts +0 -9
  268. package/core/interfaces/page.d.ts.map +0 -1
  269. package/core/interfaces/page.js +0 -2
  270. package/core/interfaces/page.js.map +0 -1
  271. package/esm2022/core/interfaces/block.mjs +0 -2
  272. package/esm2022/core/interfaces/exposed-component.mjs +0 -2
  273. package/esm2022/core/interfaces/page.mjs +0 -2
  274. package/esm2022/store/storage/index.mjs +0 -2
  275. package/esm2022/store/storage/store-sync.mjs +0 -111
  276. package/schematics/application/index.d.ts +0 -9
  277. package/schematics/application/index.d.ts.map +0 -1
  278. package/schematics/application/index.js +0 -68
  279. package/schematics/application/index.js.map +0 -1
  280. package/schematics/application/schema.d.ts +0 -14
  281. package/schematics/application/schema.d.ts.map +0 -1
  282. package/schematics/application/schema.js.map +0 -1
  283. package/schematics/application/schema.json +0 -38
  284. package/schematics/application/templates/package.json.template +0 -29
  285. package/schematics/library/index.d.ts +0 -9
  286. package/schematics/library/index.d.ts.map +0 -1
  287. package/schematics/library/index.js +0 -41
  288. package/schematics/library/index.js.map +0 -1
  289. package/schematics/library/rules/rules.ng.d.ts +0 -11
  290. package/schematics/library/rules/rules.ng.d.ts.map +0 -1
  291. package/schematics/library/rules/rules.ng.js +0 -113
  292. package/schematics/library/rules/rules.ng.js.map +0 -1
  293. package/schematics/library/rules/rules.nx.d.ts +0 -10
  294. package/schematics/library/rules/rules.nx.d.ts.map +0 -1
  295. package/schematics/library/rules/rules.nx.js +0 -126
  296. package/schematics/library/rules/rules.nx.js.map +0 -1
  297. package/schematics/library/rules/shared.d.ts +0 -19
  298. package/schematics/library/rules/shared.d.ts.map +0 -1
  299. package/schematics/library/rules/shared.js +0 -84
  300. package/schematics/library/rules/shared.js.map +0 -1
  301. package/schematics/library/schema.d.ts +0 -18
  302. package/schematics/library/schema.d.ts.map +0 -1
  303. package/schematics/library/schema.js +0 -3
  304. package/schematics/library/schema.json +0 -51
  305. package/schematics/library/templates/ng/.eslintrc.js.template +0 -19
  306. package/schematics/library/templates/ng/.gitignore.template +0 -2
  307. package/schematics/library/templates/ng/.npmignore.template +0 -0
  308. package/schematics/library/templates/ng/jest.config.js.template +0 -37
  309. package/schematics/library/templates/ng/testing/setup-jest.ts.template +0 -2
  310. package/schematics/library/templates/ng/tsconfig.builders.json.template +0 -22
  311. package/schematics/library/templates/ng/tsconfig.eslint.json.template +0 -8
  312. package/schematics/library/templates/ng/tsconfig.json.template +0 -12
  313. package/schematics/library/templates/ng/tsconfig.spec.json.template +0 -17
  314. package/schematics/library/templates/nx/.eslintrc.js.template +0 -19
  315. package/schematics/library/templates/nx/.gitignore.template +0 -2
  316. package/schematics/library/templates/nx/.npmignore.template +0 -0
  317. package/schematics/library/templates/nx/jest.config.js.template +0 -37
  318. package/schematics/library/templates/nx/project.json.template +0 -66
  319. package/schematics/library/templates/nx/testing/setup-jest.ts.template +0 -2
  320. package/schematics/library/templates/nx/tsconfig.eslint.json.template +0 -8
  321. package/schematics/package.json +0 -3
  322. package/schematics/rule-factories/azure-pipeline/index.d.ts +0 -14
  323. package/schematics/rule-factories/azure-pipeline/index.d.ts.map +0 -1
  324. package/schematics/rule-factories/azure-pipeline/index.js +0 -64
  325. package/schematics/rule-factories/azure-pipeline/index.js.map +0 -1
  326. package/schematics/rule-factories/azure-pipeline/templates/azure/scripts/e2e/attach-files-to-test-results.js.template +0 -147
  327. package/schematics/rule-factories/azure-pipeline/templates/azure/scripts/e2e/compute-deployment-service-url.js.template +0 -20
  328. package/schematics/rule-factories/azure-pipeline/templates/azure/scripts/e2e/gen-pckg-json-e2e.js.template +0 -15
  329. package/schematics/rule-factories/azure-pipeline/templates/azure/scripts/e2e/get-app-version.js.template +0 -36
  330. package/schematics/rule-factories/azure-pipeline/templates/azure/scripts/e2e/get-major-minor.js.template +0 -8
  331. package/schematics/rule-factories/azure-pipeline/templates/azure/templates/steps/allure.yml.template +0 -24
  332. package/schematics/rule-factories/azure-pipeline/templates/azure/templates/steps/cascading.yml.template +0 -8
  333. package/schematics/rule-factories/azure-pipeline/templates/azure/templates/steps/publish.yml.template +0 -14
  334. package/schematics/rule-factories/azure-pipeline/templates/azure/templates/steps/set-version-tag.yml.template +0 -13
  335. package/schematics/rule-factories/azure-pipeline/templates/azure/templates/steps/setup.yml.template +0 -21
  336. package/schematics/rule-factories/azure-pipeline/templates/azure/templates/steps/versioning.yml.template +0 -8
  337. package/schematics/rule-factories/azure-pipeline/templates/azure-pipelines.yml.template +0 -252
  338. package/schematics/rule-factories/module-list/index.d.ts +0 -11
  339. package/schematics/rule-factories/module-list/index.d.ts.map +0 -1
  340. package/schematics/rule-factories/module-list/index.js +0 -45
  341. package/schematics/rule-factories/module-list/index.js.map +0 -1
  342. package/schematics/rule-factories/monorepo/index.d.ts +0 -16
  343. package/schematics/rule-factories/monorepo/index.d.ts.map +0 -1
  344. package/schematics/rule-factories/monorepo/index.js +0 -65
  345. package/schematics/rule-factories/monorepo/index.js.map +0 -1
  346. package/schematics/rule-factories/renovate/index.d.ts +0 -8
  347. package/schematics/rule-factories/renovate/index.d.ts.map +0 -1
  348. package/schematics/rule-factories/renovate/index.js +0 -27
  349. package/schematics/rule-factories/renovate/index.js.map +0 -1
  350. package/schematics/rule-factories/renovate/templates/__dot__renovaterc.json.template +0 -61
  351. package/schematics/sdk/index.d.ts +0 -8
  352. package/schematics/sdk/index.d.ts.map +0 -1
  353. package/schematics/sdk/index.js +0 -62
  354. package/schematics/sdk/index.js.map +0 -1
  355. package/schematics/sdk/rules/clean-standalone.rule.d.ts +0 -7
  356. package/schematics/sdk/rules/clean-standalone.rule.d.ts.map +0 -1
  357. package/schematics/sdk/rules/clean-standalone.rule.js +0 -28
  358. package/schematics/sdk/rules/clean-standalone.rule.js.map +0 -1
  359. package/schematics/sdk/rules/rules.ng.d.ts +0 -11
  360. package/schematics/sdk/rules/rules.ng.d.ts.map +0 -1
  361. package/schematics/sdk/rules/rules.ng.js +0 -38
  362. package/schematics/sdk/rules/rules.ng.js.map +0 -1
  363. package/schematics/sdk/rules/rules.nx.d.ts +0 -11
  364. package/schematics/sdk/rules/rules.nx.d.ts.map +0 -1
  365. package/schematics/sdk/rules/rules.nx.js +0 -60
  366. package/schematics/sdk/rules/rules.nx.js.map +0 -1
  367. package/schematics/sdk/rules/update-ts-paths.rule.d.ts +0 -10
  368. package/schematics/sdk/rules/update-ts-paths.rule.d.ts.map +0 -1
  369. package/schematics/sdk/rules/update-ts-paths.rule.js +0 -41
  370. package/schematics/sdk/rules/update-ts-paths.rule.js.map +0 -1
  371. package/schematics/sdk/schema.d.ts +0 -19
  372. package/schematics/sdk/schema.d.ts.map +0 -1
  373. package/schematics/sdk/schema.js +0 -3
  374. package/schematics/sdk/schema.js.map +0 -1
  375. package/schematics/sdk/schema.json +0 -46
  376. package/schematics/sdk/templates/jest.config.js.template +0 -12
  377. package/schematics/store/common/mocks/example-module.d.ts +0 -2
  378. package/schematics/store/common/mocks/example-module.d.ts.map +0 -1
  379. package/schematics/store/common/mocks/example-module.js +0 -40
  380. package/schematics/store/common/mocks/example-module.js.map +0 -1
  381. package/schematics/store/common/mocks/index.d.ts +0 -2
  382. package/schematics/store/common/mocks/index.d.ts.map +0 -1
  383. package/schematics/store/common/mocks/index.js +0 -12
  384. package/schematics/store/common/mocks/index.js.map +0 -1
  385. package/schematics/store/entity-async/mocks/example-actions.d.ts +0 -2
  386. package/schematics/store/entity-async/mocks/example-actions.d.ts.map +0 -1
  387. package/schematics/store/entity-async/mocks/example-actions.js +0 -82
  388. package/schematics/store/entity-async/mocks/example-actions.js.map +0 -1
  389. package/schematics/store/entity-async/mocks/example-effect-spec.d.ts +0 -2
  390. package/schematics/store/entity-async/mocks/example-effect-spec.d.ts.map +0 -1
  391. package/schematics/store/entity-async/mocks/example-effect-spec.js +0 -45
  392. package/schematics/store/entity-async/mocks/example-effect-spec.js.map +0 -1
  393. package/schematics/store/entity-async/mocks/example-effect.d.ts +0 -2
  394. package/schematics/store/entity-async/mocks/example-effect.d.ts.map +0 -1
  395. package/schematics/store/entity-async/mocks/example-effect.js +0 -72
  396. package/schematics/store/entity-async/mocks/example-effect.js.map +0 -1
  397. package/schematics/store/entity-async/mocks/example-reducer-spec.d.ts +0 -2
  398. package/schematics/store/entity-async/mocks/example-reducer-spec.d.ts.map +0 -1
  399. package/schematics/store/entity-async/mocks/example-reducer-spec.js +0 -127
  400. package/schematics/store/entity-async/mocks/example-reducer-spec.js.map +0 -1
  401. package/schematics/store/entity-async/mocks/example-reducer.d.ts +0 -2
  402. package/schematics/store/entity-async/mocks/example-reducer.d.ts.map +0 -1
  403. package/schematics/store/entity-async/mocks/example-reducer.js +0 -69
  404. package/schematics/store/entity-async/mocks/example-reducer.js.map +0 -1
  405. package/schematics/store/entity-async/mocks/example-selectors-spec.d.ts +0 -2
  406. package/schematics/store/entity-async/mocks/example-selectors-spec.d.ts.map +0 -1
  407. package/schematics/store/entity-async/mocks/example-selectors-spec.js +0 -16
  408. package/schematics/store/entity-async/mocks/example-selectors-spec.js.map +0 -1
  409. package/schematics/store/entity-async/mocks/example-selectors.d.ts +0 -2
  410. package/schematics/store/entity-async/mocks/example-selectors.d.ts.map +0 -1
  411. package/schematics/store/entity-async/mocks/example-selectors.js +0 -28
  412. package/schematics/store/entity-async/mocks/example-selectors.js.map +0 -1
  413. package/schematics/store/entity-async/mocks/example-state.d.ts +0 -2
  414. package/schematics/store/entity-async/mocks/example-state.d.ts.map +0 -1
  415. package/schematics/store/entity-async/mocks/example-state.js +0 -39
  416. package/schematics/store/entity-async/mocks/example-state.js.map +0 -1
  417. package/schematics/store/entity-async/mocks/example-sync.d.ts +0 -2
  418. package/schematics/store/entity-async/mocks/example-sync.d.ts.map +0 -1
  419. package/schematics/store/entity-async/mocks/example-sync.js +0 -29
  420. package/schematics/store/entity-async/mocks/example-sync.js.map +0 -1
  421. package/schematics/store/entity-sync/mocks/example-actions.d.ts +0 -2
  422. package/schematics/store/entity-sync/mocks/example-actions.d.ts.map +0 -1
  423. package/schematics/store/entity-sync/mocks/example-actions.js +0 -56
  424. package/schematics/store/entity-sync/mocks/example-actions.js.map +0 -1
  425. package/schematics/store/entity-sync/mocks/example-reducer-spec.d.ts +0 -2
  426. package/schematics/store/entity-sync/mocks/example-reducer-spec.d.ts.map +0 -1
  427. package/schematics/store/entity-sync/mocks/example-reducer-spec.js +0 -85
  428. package/schematics/store/entity-sync/mocks/example-reducer-spec.js.map +0 -1
  429. package/schematics/store/entity-sync/mocks/example-reducer.d.ts +0 -2
  430. package/schematics/store/entity-sync/mocks/example-reducer.d.ts.map +0 -1
  431. package/schematics/store/entity-sync/mocks/example-reducer.js +0 -51
  432. package/schematics/store/entity-sync/mocks/example-reducer.js.map +0 -1
  433. package/schematics/store/entity-sync/mocks/example-selectors-spec.d.ts +0 -2
  434. package/schematics/store/entity-sync/mocks/example-selectors-spec.d.ts.map +0 -1
  435. package/schematics/store/entity-sync/mocks/example-selectors-spec.js +0 -10
  436. package/schematics/store/entity-sync/mocks/example-selectors-spec.js.map +0 -1
  437. package/schematics/store/entity-sync/mocks/example-selectors.d.ts +0 -2
  438. package/schematics/store/entity-sync/mocks/example-selectors.d.ts.map +0 -1
  439. package/schematics/store/entity-sync/mocks/example-selectors.js +0 -25
  440. package/schematics/store/entity-sync/mocks/example-selectors.js.map +0 -1
  441. package/schematics/store/entity-sync/mocks/example-state.d.ts +0 -2
  442. package/schematics/store/entity-sync/mocks/example-state.d.ts.map +0 -1
  443. package/schematics/store/entity-sync/mocks/example-state.js +0 -37
  444. package/schematics/store/entity-sync/mocks/example-state.js.map +0 -1
  445. package/schematics/store/simple-async/mocks/example-actions.d.ts +0 -2
  446. package/schematics/store/simple-async/mocks/example-actions.d.ts.map +0 -1
  447. package/schematics/store/simple-async/mocks/example-actions.js +0 -56
  448. package/schematics/store/simple-async/mocks/example-actions.js.map +0 -1
  449. package/schematics/store/simple-async/mocks/example-effect-spec.d.ts +0 -2
  450. package/schematics/store/simple-async/mocks/example-effect-spec.d.ts.map +0 -1
  451. package/schematics/store/simple-async/mocks/example-effect-spec.js +0 -45
  452. package/schematics/store/simple-async/mocks/example-effect-spec.js.map +0 -1
  453. package/schematics/store/simple-async/mocks/example-effect.d.ts +0 -2
  454. package/schematics/store/simple-async/mocks/example-effect.d.ts.map +0 -1
  455. package/schematics/store/simple-async/mocks/example-effect.js +0 -54
  456. package/schematics/store/simple-async/mocks/example-effect.js.map +0 -1
  457. package/schematics/store/simple-async/mocks/example-reducer-spec.d.ts +0 -2
  458. package/schematics/store/simple-async/mocks/example-reducer-spec.d.ts.map +0 -1
  459. package/schematics/store/simple-async/mocks/example-reducer-spec.js +0 -58
  460. package/schematics/store/simple-async/mocks/example-reducer-spec.js.map +0 -1
  461. package/schematics/store/simple-async/mocks/example-reducer.d.ts +0 -2
  462. package/schematics/store/simple-async/mocks/example-reducer.d.ts.map +0 -1
  463. package/schematics/store/simple-async/mocks/example-reducer.js +0 -46
  464. package/schematics/store/simple-async/mocks/example-reducer.js.map +0 -1
  465. package/schematics/store/simple-async/mocks/example-state.d.ts +0 -2
  466. package/schematics/store/simple-async/mocks/example-state.d.ts.map +0 -1
  467. package/schematics/store/simple-async/mocks/example-state.js +0 -39
  468. package/schematics/store/simple-async/mocks/example-state.js.map +0 -1
  469. package/schematics/store/simple-async/mocks/example-sync.d.ts +0 -2
  470. package/schematics/store/simple-async/mocks/example-sync.d.ts.map +0 -1
  471. package/schematics/store/simple-async/mocks/example-sync.js +0 -22
  472. package/schematics/store/simple-async/mocks/example-sync.js.map +0 -1
  473. package/schematics/store/simple-sync/mocks/example-actions.d.ts +0 -2
  474. package/schematics/store/simple-sync/mocks/example-actions.d.ts.map +0 -1
  475. package/schematics/store/simple-sync/mocks/example-actions.js +0 -28
  476. package/schematics/store/simple-sync/mocks/example-actions.js.map +0 -1
  477. package/schematics/store/simple-sync/mocks/example-reducer-spec.d.ts +0 -2
  478. package/schematics/store/simple-sync/mocks/example-reducer-spec.d.ts.map +0 -1
  479. package/schematics/store/simple-sync/mocks/example-reducer-spec.js +0 -38
  480. package/schematics/store/simple-sync/mocks/example-reducer-spec.js.map +0 -1
  481. package/schematics/store/simple-sync/mocks/example-reducer.d.ts +0 -2
  482. package/schematics/store/simple-sync/mocks/example-reducer.d.ts.map +0 -1
  483. package/schematics/store/simple-sync/mocks/example-reducer.js +0 -32
  484. package/schematics/store/simple-sync/mocks/example-reducer.js.map +0 -1
  485. package/schematics/store/simple-sync/mocks/example-state.d.ts +0 -2
  486. package/schematics/store/simple-sync/mocks/example-state.d.ts.map +0 -1
  487. package/schematics/store/simple-sync/mocks/example-state.js +0 -22
  488. package/schematics/store/simple-sync/mocks/example-state.js.map +0 -1
  489. package/store/storage/index.d.ts +0 -2
  490. package/store/storage/index.d.ts.map +0 -1
  491. package/store/storage/index.js +0 -2
  492. package/store/storage/index.js.map +0 -1
  493. package/store/storage/store-sync.d.ts +0 -113
  494. package/store/storage/store-sync.d.ts.map +0 -1
  495. package/store/storage/store-sync.js +0 -111
  496. package/store/storage/store-sync.js.map +0 -1
  497. /package/{schematics/application → builders/run-script}/schema.js +0 -0
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  <h1 align="center">Otter core</h1>
2
2
  <p align="center">
3
- <img src="https://raw.githubusercontent.com/AmadeusITGroup/otter/main/.attachments/otter.png" alt="Super cute Otter!" width="40%"/>
3
+ <img src="https://raw.githubusercontent.com/AmadeusITGroup/otter/main/assets/logo/otter.png" alt="Super cute Otter!" width="40%"/>
4
4
  </p>
5
5
 
6
6
  ## Description
@@ -19,19 +19,19 @@ during the installation of the `@o3r/core`.
19
19
  ### Required environment
20
20
 
21
21
  * **Git** : [https://gitforwindows.org/](https://gitforwindows.org/)
22
- * **NodeJs 16.x** : [NodeJS LTS](https://nodejs.org/)
22
+ * **NodeJs 18.x** : [NodeJS LTS](https://nodejs.org/)
23
23
  * **Yarn** : [https://yarnpkg.com/lang/en/](https://yarnpkg.com/)
24
24
 
25
25
  **Yarn** can be installed directly using NPM:
26
26
 
27
- ```bash
27
+ ```shell
28
28
  # Installing yarn
29
29
  npm install --global yarn
30
30
  ```
31
31
 
32
32
  ### Creating a new Otter application
33
33
 
34
- ```bash
34
+ ```shell
35
35
  # Create new application
36
36
  npm create @o3r my-project
37
37
  # Or
@@ -40,7 +40,7 @@ yarn create @o3r my-project
40
40
 
41
41
  ### Adding Material design theming
42
42
 
43
- ```bash
43
+ ```shell
44
44
  # Add Material Design
45
45
  yarn ng add @angular/material
46
46
  # ? Choose a prebuilt theme name, or "custom" for a custom theme: Indigo/Pink
@@ -84,14 +84,6 @@ Otter framework provides a set of code generators based on [angular schematics](
84
84
  | convert-component | Convert an Angular component into an Otter component | `ng g convert-component` |
85
85
  | context-to-component | Add Otter Context to an existing component | `ng g context-to-component` |
86
86
 
87
- ### Package generators
88
-
89
- | Schematics | Description | How to use |
90
- | -------------------------- | ----------------------------------------------------------------------------- | --------------------------------- |
91
- | library | Add a new Library to the current Otter project | `ng g library` |
92
- | sdk | Add a new SDK to the current Otter project | `ng g sdk` |
93
- | application | Add a new Application to the current Otter project | `ng g application` |
94
-
95
87
  ## Create your own Otter compatible module
96
88
 
97
89
  You can refer to the [module documentation](https://github.com/AmadeusITGroup/otter/tree/main/docs/core/MODULE.md) to create an Otter compatible module.
@@ -116,3 +108,36 @@ It includes the following modules:
116
108
  * @o3r/configuration
117
109
  * @o3r/dynamic-content
118
110
  * @o3r/rules-engine
111
+
112
+ ### Preset All
113
+
114
+ Will add all official modules provided by the Otter Framework.
115
+ Currently the list of modules is the following:
116
+
117
+ * @o3r/analytics
118
+ * @o3r/apis-manager
119
+ * @o3r/application
120
+ * @o3r/components
121
+ * @o3r/configuration
122
+ * @o3r/dynamic-content
123
+ * @o3r/eslint-config-otter
124
+ * @o3r/eslint-plugin
125
+ * @o3r/forms
126
+ * @o3r/localization
127
+ * @o3r/logger
128
+ * @o3r/rules-engine
129
+ * @o3r/store-sync
130
+ * @o3r/stylelint-plugin
131
+ * @o3r/styling
132
+
133
+ ## External (Custom) Preset
134
+
135
+ The preset mechanism is supporting, via the `--external-preset` option, presets defined by module providers themself.
136
+
137
+ The modules can be regrouped in custom Presets by following the next steps:
138
+
139
+ * Adding a **keyword**, in the module *package.json*'s `keywords` field, following the pattern `otter-preset-<my-preset>`.
140
+ * The module needs to be published to public (or private) NPM Registry.
141
+ * The package's scope should be whitelisted, via a Pull Request, in the following [OTTER_MODULE_SUPPORTED_SCOPES constant](https://github.com/AmadeusITGroup/otter/blob/main/packages/@o3r/schematics/src/modules/modules.constants.ts).
142
+
143
+ > **Note**: Get more information regarding the **Otter Modules** in the [Module Documentation](https://github.com/AmadeusITGroup/otter/blob/main/docs/core/MODULE.md).
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/app-version/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAEnD,cAAc,UAAU,CAAC;;AAezB,wBAmCG"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/app-version/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,uBAAuB,EAAE,MAAM,UAAU,CAAC;AAEnD,cAAc,UAAU,CAAC;;AAezB,wBA6BG"}
@@ -22,7 +22,7 @@ exports.default = (0, architect_1.createBuilder)(async (options, context) => {
22
22
  if (!fs.existsSync(packageJsonFile)) {
23
23
  return PACKAGE_JSON_NOT_FOUND;
24
24
  }
25
- const packageJson = await new Promise((resolve, reject) => fs.readFile(packageJsonFile, { encoding: 'utf-8' }, (err, data) => err ? reject(err) : resolve(data)));
25
+ const packageJson = await fs.promises.readFile(packageJsonFile, { encoding: 'utf-8' });
26
26
  let version;
27
27
  try {
28
28
  version = JSON.parse(packageJson).version;
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../builders/app-version/index.ts"],"names":[],"mappings":";;;AAAA,yDAAyE;AACzE,8BAA8B;AAC9B,kCAAkC;AAIlC,mDAAyB;AAEzB,MAAM,sBAAsB,GAAkB;IAC5C,KAAK,EAAE,wBAAwB;IAC/B,OAAO,EAAE,KAAK;CACf,CAAC;AAEF,MAAM,sBAAsB,GAAkB;IAC5C,KAAK,EAAE,wBAAwB;IAC/B,OAAO,EAAE,KAAK;CACf,CAAC;AAEF,8BAA8B;AAC9B,MAAM,WAAW,GAAG,CAAC,CAAC;AAEtB,kBAAe,IAAA,yBAAa,EAA0B,KAAK,EAAE,OAAO,EAAE,OAAO,EAA0B,EAAE;IACvG,OAAO,CAAC,aAAa,EAAE,CAAC;IACxB,OAAO,CAAC,cAAc,CAAC,CAAC,EAAE,WAAW,EAAE,sBAAsB,CAAC,CAAC;IAC/D,MAAM,eAAe,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,aAAa,EAAE,cAAc,CAAC,CAAC;IAC5E,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,eAAe,CAAC,EAAE;QACnC,OAAO,sBAAsB,CAAC;KAC/B;IACD,MAAM,WAAW,GAAG,MAAM,IAAI,OAAO,CAAS,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,CAChE,EAAE,CAAC,QAAQ,CACT,eAAe,EACf,EAAC,QAAQ,EAAE,OAAO,EAAC,EACnB,CAAC,GAAG,EAAE,IAAI,EAAE,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC,CACjD,CACF,CAAC;IACF,IAAI,OAAe,CAAC;IACpB,IAAI;QACF,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,OAAO,CAAC;QAC1C,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,oBAAoB,OAAO,EAAE,CAAC,CAAC;KACpD;IAAC,MAAM;QACN,OAAO,sBAAsB,CAAC;KAC/B;IAED,OAAO,CAAC,cAAc,CAAC,CAAC,EAAE,WAAW,EAAE,uCAAuC,CAAC,CAAC;IAChF,MAAM,WAAW,GAAG,+BAA+B,CAAC;IACpD,MAAM,YAAY,GAAG,MAAM,OAAO,CAAC,eAAe,CAAC;QACjD,KAAK,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;QACrB,WAAW,EAAE,OAAO,CAAC,gBAAgB;QACrC,YAAY,EAAE,OAAO;KACtB,EAAE,WAAW,CAAC,CAAC;IAChB,MAAM,KAAK,GAAG,MAAM,OAAO,CAAC,eAAe,CAAC,WAAW,EAAE,YAAY,CAAC,CAAC;IAEvE,sDAAsD;IACtD,OAAO,CAAC,WAAW,CAAC,KAAK,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;IAEpD,OAAO,KAAK,CAAC,MAAM,CAAC;AACtB,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../builders/app-version/index.ts"],"names":[],"mappings":";;;AAAA,yDAAyE;AACzE,8BAA8B;AAC9B,kCAAkC;AAIlC,mDAAyB;AAEzB,MAAM,sBAAsB,GAAkB;IAC5C,KAAK,EAAE,wBAAwB;IAC/B,OAAO,EAAE,KAAK;CACf,CAAC;AAEF,MAAM,sBAAsB,GAAkB;IAC5C,KAAK,EAAE,wBAAwB;IAC/B,OAAO,EAAE,KAAK;CACf,CAAC;AAEF,8BAA8B;AAC9B,MAAM,WAAW,GAAG,CAAC,CAAC;AAEtB,kBAAe,IAAA,yBAAa,EAA0B,KAAK,EAAE,OAAO,EAAE,OAAO,EAA0B,EAAE;IACvG,OAAO,CAAC,aAAa,EAAE,CAAC;IACxB,OAAO,CAAC,cAAc,CAAC,CAAC,EAAE,WAAW,EAAE,sBAAsB,CAAC,CAAC;IAC/D,MAAM,eAAe,GAAG,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,aAAa,EAAE,cAAc,CAAC,CAAC;IAC5E,IAAI,CAAC,EAAE,CAAC,UAAU,CAAC,eAAe,CAAC,EAAE;QACnC,OAAO,sBAAsB,CAAC;KAC/B;IACD,MAAM,WAAW,GAAG,MAAM,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,eAAe,EAAE,EAAC,QAAQ,EAAE,OAAO,EAAC,CAAC,CAAC;IACrF,IAAI,OAAe,CAAC;IACpB,IAAI;QACF,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,OAAO,CAAC;QAC1C,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,oBAAoB,OAAO,EAAE,CAAC,CAAC;KACpD;IAAC,MAAM;QACN,OAAO,sBAAsB,CAAC;KAC/B;IAED,OAAO,CAAC,cAAc,CAAC,CAAC,EAAE,WAAW,EAAE,uCAAuC,CAAC,CAAC;IAChF,MAAM,WAAW,GAAG,+BAA+B,CAAC;IACpD,MAAM,YAAY,GAAG,MAAM,OAAO,CAAC,eAAe,CAAC;QACjD,KAAK,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;QACrB,WAAW,EAAE,OAAO,CAAC,gBAAgB;QACrC,YAAY,EAAE,OAAO;KACtB,EAAE,WAAW,CAAC,CAAC;IAChB,MAAM,KAAK,GAAG,MAAM,OAAO,CAAC,eAAe,CAAC,WAAW,EAAE,YAAY,CAAC,CAAC;IAEvE,sDAAsD;IACtD,OAAO,CAAC,WAAW,CAAC,KAAK,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC,IAAI,EAAE,CAAC,CAAC;IAEpD,OAAO,KAAK,CAAC,MAAM,CAAC;AACtB,CAAC,CAAC,CAAC"}
@@ -1,5 +1,5 @@
1
1
  {
2
- "$schema": "http://json-schema.org/schema",
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
3
  "type": "object",
4
4
  "$id": "AppVersionBuilderSchema",
5
5
  "title": "App version builder",
@@ -1,5 +1,5 @@
1
1
  {
2
- "$schema": "http://json-schema.org/schema",
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
3
  "type": "object",
4
4
  "$id": "LibBuilderSchema",
5
5
  "title": "Library builder",
@@ -1,5 +1,5 @@
1
1
  {
2
- "$schema": "http://json-schema.org/schema",
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
3
  "$id": "MultiWatcherBuilderSchema",
4
4
  "title": "Multi Watcher builder",
5
5
  "description": "Multi Watcher builder options",
@@ -1,5 +1,5 @@
1
1
  {
2
- "$schema": "http://json-schema.org/schema",
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
3
  "type": "object",
4
4
  "$id": "NgcBuilderSchema",
5
5
  "title": "Ngc builder",
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/pattern-replacement/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAC,+BAA+B,EAAC,MAAM,UAAU,CAAC;;AAEzD,wBAqCG"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/pattern-replacement/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAC,+BAA+B,EAAC,MAAM,UAAU,CAAC;;AAEzD,wBAyBG"}
@@ -8,19 +8,19 @@ exports.default = (0, architect_1.createBuilder)(async (options, context) => {
8
8
  const STEP_NUMBER = options.files.length + 1;
9
9
  context.reportProgress(1, STEP_NUMBER, 'Checking that all files exist');
10
10
  const fileNames = options.files.map((fileName) => path.resolve(context.workspaceRoot, fileName));
11
- const inexistingFile = fileNames.find((filePath) => !fs.existsSync(filePath));
12
- if (inexistingFile) {
11
+ const unexistingFile = fileNames.find((filePath) => !fs.existsSync(filePath));
12
+ if (unexistingFile) {
13
13
  return {
14
14
  success: false,
15
- error: `${inexistingFile} not found`
15
+ error: `${unexistingFile} not found`
16
16
  };
17
17
  }
18
18
  for (let i = 0; i < fileNames.length; i++) {
19
19
  const filePath = fileNames[i];
20
20
  context.reportProgress(i + 1, STEP_NUMBER, `Modifying ${filePath}`);
21
- const fileContent = await new Promise((resolve, reject) => fs.readFile(filePath, { encoding: 'utf-8' }, (err, data) => err ? reject(err) : resolve(data)));
21
+ const fileContent = await fs.promises.readFile(filePath, { encoding: 'utf-8' });
22
22
  const newContent = fileContent.replace(new RegExp(options.searchValue, 'g'), options.replaceValue);
23
- await new Promise((resolve, reject) => fs.writeFile(filePath, newContent, (err) => err ? reject(err) : resolve()));
23
+ await fs.promises.writeFile(filePath, newContent);
24
24
  }
25
25
  return {
26
26
  success: true
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../builders/pattern-replacement/index.ts"],"names":[],"mappings":";;AAAA,yDAAuE;AACvE,8BAA8B;AAC9B,kCAAkC;AAIlC,kBAAe,IAAA,yBAAa,EAAkC,KAAK,EAAE,OAAO,EAAE,OAAO,EAA0B,EAAE;IAC/G,OAAO,CAAC,aAAa,EAAE,CAAC;IACxB,MAAM,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;IAC7C,OAAO,CAAC,cAAc,CAAC,CAAC,EAAE,WAAW,EAAE,+BAA+B,CAAC,CAAC;IAExE,MAAM,SAAS,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC;IACjG,MAAM,cAAc,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC9E,IAAI,cAAc,EAAE;QAClB,OAAO;YACL,OAAO,EAAE,KAAK;YACd,KAAK,EAAE,GAAG,cAAc,YAAY;SACrC,CAAC;KACH;IACD,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;QACzC,MAAM,QAAQ,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC;QAC9B,OAAO,CAAC,cAAc,CAAC,CAAC,GAAG,CAAC,EAAE,WAAW,EAAE,aAAa,QAAQ,EAAE,CAAC,CAAC;QACpE,MAAM,WAAW,GAAG,MAAM,IAAI,OAAO,CAAS,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,CAChE,EAAE,CAAC,QAAQ,CACT,QAAQ,EACR,EAAC,QAAQ,EAAE,OAAO,EAAC,EACnB,CAAC,GAAG,EAAE,IAAI,EAAE,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC,CACjD,CACF,CAAC;QACF,MAAM,UAAU,GAAG,WAAW,CAAC,OAAO,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,WAAW,EAAE,GAAG,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC;QAEnG,MAAM,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,CAC1C,EAAE,CAAC,SAAS,CACV,QAAQ,EACR,UAAU,EACV,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,EAAE,CACvC,CACF,CAAC;KACH;IAED,OAAO;QACL,OAAO,EAAE,IAAI;KACd,CAAC;AACJ,CAAC,CAAC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../builders/pattern-replacement/index.ts"],"names":[],"mappings":";;AAAA,yDAAuE;AACvE,8BAA8B;AAC9B,kCAAkC;AAIlC,kBAAe,IAAA,yBAAa,EAAkC,KAAK,EAAE,OAAO,EAAE,OAAO,EAA0B,EAAE;IAC/G,OAAO,CAAC,aAAa,EAAE,CAAC;IACxB,MAAM,WAAW,GAAG,OAAO,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;IAC7C,OAAO,CAAC,cAAc,CAAC,CAAC,EAAE,WAAW,EAAE,+BAA+B,CAAC,CAAC;IAExE,MAAM,SAAS,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC;IACjG,MAAM,cAAc,GAAG,SAAS,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAC,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC9E,IAAI,cAAc,EAAE;QAClB,OAAO;YACL,OAAO,EAAE,KAAK;YACd,KAAK,EAAE,GAAG,cAAc,YAAY;SACrC,CAAC;KACH;IACD,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,SAAS,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;QACzC,MAAM,QAAQ,GAAG,SAAS,CAAC,CAAC,CAAC,CAAC;QAC9B,OAAO,CAAC,cAAc,CAAC,CAAC,GAAG,CAAC,EAAE,WAAW,EAAE,aAAa,QAAQ,EAAE,CAAC,CAAC;QACpE,MAAM,WAAW,GAAG,MAAM,EAAE,CAAC,QAAQ,CAAC,QAAQ,CAAC,QAAQ,EAAE,EAAC,QAAQ,EAAE,OAAO,EAAC,CAAC,CAAC;QAC9E,MAAM,UAAU,GAAG,WAAW,CAAC,OAAO,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,WAAW,EAAE,GAAG,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC;QAEnG,MAAM,EAAE,CAAC,QAAQ,CAAC,SAAS,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC;KACnD;IAED,OAAO;QACL,OAAO,EAAE,IAAI;KACd,CAAC;AACJ,CAAC,CAAC,CAAC"}
@@ -1,5 +1,5 @@
1
1
  {
2
- "$schema": "http://json-schema.org/schema",
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
3
  "type": "object",
4
4
  "$id": "PatternReplacementBuilderSchema",
5
5
  "title": "Pattern replacement builder",
@@ -0,0 +1,4 @@
1
+ import type { RunScriptBuilderSchema } from './schema';
2
+ declare const _default: import("@angular-devkit/architect/src/internal").Builder<RunScriptBuilderSchema & import("@angular-devkit/core").JsonObject>;
3
+ export default _default;
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../builders/run-script/index.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,UAAU,CAAC;;AAEvD,wBA0BG"}
@@ -0,0 +1,34 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const architect_1 = require("@angular-devkit/architect");
4
+ const schematics_1 = require("@o3r/schematics");
5
+ const node_child_process_1 = require("node:child_process");
6
+ const node_path_1 = require("node:path");
7
+ const fs = require("node:fs");
8
+ exports.default = (0, architect_1.createBuilder)(async (options, context) => {
9
+ context.reportRunning();
10
+ context.reportProgress(1, 1, `Running ${options.script} !!!`);
11
+ const specifiedRoot = context.target?.project && (await context.getProjectMetadata(context.target.project)).root?.toString();
12
+ const projectRoot = specifiedRoot ? (0, node_path_1.resolve)(context.workspaceRoot, specifiedRoot) : context.currentDirectory;
13
+ const angularJsonPath = (0, node_path_1.join)(context.workspaceRoot, 'angular.json');
14
+ const angularJson = fs.existsSync(angularJsonPath) ? JSON.parse(fs.readFileSync(angularJsonPath, { encoding: 'utf8' }).toString()) : undefined;
15
+ if (!angularJson) {
16
+ context.logger.warn(`angular.json file cannot be found by @o3r/core:${context.builder.builderName} builder.
17
+ Detection of package manager runner will fallback on the one used to execute the actual command.`);
18
+ }
19
+ const pmr = (0, schematics_1.getPackageManagerRunner)(angularJson);
20
+ try {
21
+ (0, node_child_process_1.execSync)(`${pmr} ${options.script}`, {
22
+ stdio: ['inherit', 'inherit', 'inherit'],
23
+ cwd: projectRoot,
24
+ env: {
25
+ ...process.env
26
+ }
27
+ });
28
+ return { success: true };
29
+ }
30
+ catch (e) {
31
+ return { success: false, error: e.message || e.toString() };
32
+ }
33
+ });
34
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../builders/run-script/index.ts"],"names":[],"mappings":";;AACA,yDAAyE;AACzE,gDAA0D;AAC1D,2DAA8C;AAC9C,yCAA0C;AAC1C,8BAA8B;AAG9B,kBAAe,IAAA,yBAAa,EAAyB,KAAK,EAAE,OAAO,EAAE,OAAO,EAA0B,EAAE;IACtG,OAAO,CAAC,aAAa,EAAE,CAAC;IACxB,OAAO,CAAC,cAAc,CAAC,CAAC,EAAE,CAAC,EAAE,WAAW,OAAO,CAAC,MAAM,MAAM,CAAC,CAAC;IAC9D,MAAM,aAAa,GAAG,OAAO,CAAC,MAAM,EAAE,OAAO,IAAI,CAAC,MAAM,OAAO,CAAC,kBAAkB,CAAC,OAAO,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,EAAE,QAAQ,EAAE,CAAC;IAC7H,MAAM,WAAW,GAAG,aAAa,CAAC,CAAC,CAAC,IAAA,mBAAO,EAAC,OAAO,CAAC,aAAa,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,gBAAgB,CAAC;IAE7G,MAAM,eAAe,GAAG,IAAA,gBAAI,EAAC,OAAO,CAAC,aAAa,EAAE,cAAc,CAAC,CAAC;IACpE,MAAM,WAAW,GAAG,EAAE,CAAC,UAAU,CAAC,eAAe,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,YAAY,CAAC,eAAe,EAAE,EAAC,QAAQ,EAAE,MAAM,EAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;IAC7I,IAAI,CAAC,WAAW,EAAE;QAChB,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC,kDAAkD,OAAO,CAAC,OAAO,CAAC,WAAW;iGACJ,CAAC,CAAC;KAChG;IACD,MAAM,GAAG,GAAG,IAAA,oCAAuB,EAAC,WAAW,CAAC,CAAC;IAEjD,IAAI;QACF,IAAA,6BAAQ,EAAC,GAAG,GAAG,IAAI,OAAO,CAAC,MAAM,EAAE,EAAE;YACnC,KAAK,EAAE,CAAC,SAAS,EAAE,SAAS,EAAE,SAAS,CAAC;YACxC,GAAG,EAAE,WAAW;YAChB,GAAG,EAAE;gBACH,GAAG,OAAO,CAAC,GAAG;aACf;SACF,CAAC,CAAC;QACH,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;KAC1B;IAAC,OAAO,CAAM,EAAE;QACf,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,CAAC,OAAO,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC;KAC7D;AACH,CAAC,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ /** Run a package.json script builder schema */
2
+ export interface RunScriptBuilderSchema {
3
+ /** A script name in the `package.json` file of the project. */
4
+ script: string;
5
+ }
6
+ //# sourceMappingURL=schema.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../../../builders/run-script/schema.ts"],"names":[],"mappings":"AAAA,+CAA+C;AAC/C,MAAM,WAAW,sBAAsB;IACrC,+DAA+D;IAC/D,MAAM,EAAE,MAAM,CAAC;CAChB"}
@@ -1 +1 @@
1
- {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../schematics/library/schema.ts"],"names":[],"mappings":""}
1
+ {"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../builders/run-script/schema.ts"],"names":[],"mappings":""}
@@ -0,0 +1,15 @@
1
+ {
2
+ "$schema": "http://json-schema.org/draft-07/schema",
3
+ "type": "object",
4
+ "$id": "RunScriptBuilderSchema",
5
+ "title": "Run script builder",
6
+ "description": "Run a script defined in package.json",
7
+ "properties": {
8
+ "script": {
9
+ "type": "string",
10
+ "description": "A script name in the project's `package.json` file."
11
+ }
12
+ },
13
+ "additionalProperties": false,
14
+ "required": ["script"]
15
+ }
package/builders.json CHANGED
@@ -25,6 +25,11 @@
25
25
  "implementation": "./builders/ngc/",
26
26
  "schema": "./builders/ngc/schema.json",
27
27
  "description": "Perform a ngc build"
28
+ },
29
+ "run-script": {
30
+ "implementation": "./builders/run-script/",
31
+ "schema": "./builders/run-script/schema.json",
32
+ "description": "Run a script from package.json"
28
33
  }
29
34
  }
30
35
  }
package/collection.json CHANGED
@@ -83,29 +83,6 @@
83
83
  "factory": "./schematics/renovate/index#ngGenerateRenovateBotComponent",
84
84
  "schema": "./schematics/renovate/schema.json"
85
85
  },
86
- "library": {
87
- "description": "Generate a new Otter compatible module",
88
- "factory": "./schematics/library/index#generateModule",
89
- "schema": "./schematics/library/schema.json",
90
- "aliases": [
91
- "new-module",
92
- "module",
93
- "libs"
94
- ]
95
- },
96
- "application": {
97
- "description": "Generate a new Otter Application",
98
- "factory": "./schematics/application/index#generateApplication",
99
- "schema": "./schematics/application/schema.json",
100
- "aliases": [
101
- "new-application", "app"
102
- ]
103
- },
104
- "sdk": {
105
- "description": "Generate a new SDK package in an Otter project",
106
- "factory": "./schematics/sdk/index#generateSdk",
107
- "schema": "./schematics/sdk/schema.json"
108
- },
109
86
  "show-modules": {
110
87
  "description": "Show available Otter modules",
111
88
  "factory": "./schematics/show-modules/index#ngShowModules",
@@ -9,23 +9,26 @@ export interface BootstrapConfig {
9
9
  export interface Dataset {
10
10
  /**
11
11
  * Bootstrap configuration
12
- *
13
12
  * @example
13
+ * ```typescript
14
14
  * '{ environment: 'prod' }'
15
+ * ```
15
16
  */
16
17
  bootstrapconfig?: string;
17
18
  /**
18
19
  * Dynamic content path
19
- *
20
20
  * @example
21
+ * ```typescript
21
22
  * 'my/dynamic/path'
23
+ * ```
22
24
  */
23
25
  dynamiccontentpath?: string;
24
26
  /**
25
27
  * Application basehref url
26
- *
27
28
  * @example
29
+ * ```typescript
28
30
  * '/my/base/href'
31
+ * ```
29
32
  */
30
33
  appbasehref?: string;
31
34
  }
@@ -1 +1 @@
1
- {"version":3,"file":"dgp.interfaces.d.ts","sourceRoot":"","sources":["../../../src/core/application/dgp.interfaces.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAE9B;;;OAGG;IACH,WAAW,EAAE,MAAM,GAAG,KAAK,CAAC;CAE7B;AAED,4DAA4D;AAC5D,MAAM,WAAW,OAAO;IACtB;;;;;OAKG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;;;OAKG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAE5B;;;;;OAKG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CAEtB"}
1
+ {"version":3,"file":"dgp.interfaces.d.ts","sourceRoot":"","sources":["../../../src/core/application/dgp.interfaces.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAE9B;;;OAGG;IACH,WAAW,EAAE,MAAM,GAAG,KAAK,CAAC;CAE7B;AAED,4DAA4D;AAC5D,MAAM,WAAW,OAAO;IACtB;;;;;;OAMG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;;;;OAMG;IACH,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAE5B;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CAEtB"}
@@ -6,12 +6,26 @@ export interface WindowWithDevtools extends Window {
6
6
  /** Common option used by the different DevKit services */
7
7
  export interface DevtoolsCommonOptions {
8
8
  /**
9
- * Activated the application bootstrap
10
- *
9
+ * Activated on the application bootstrap
11
10
  * @default false
12
11
  */
13
12
  isActivatedOnBootstrap: boolean;
14
13
  }
14
+ /** Common option used by the different Contextualization DevKit services */
15
+ export interface ContextualizationDevtoolsCommonOptions {
16
+ /**
17
+ * Activated on the application bootstrap when integrated in CMS context
18
+ * @default true
19
+ */
20
+ isActivatedOnBootstrapWhenCMSContext: boolean;
21
+ }
22
+ /**
23
+ * Dataset injected on the page when in CMS context
24
+ */
25
+ export interface ContextualizationDataset {
26
+ /** `"true"` when in CMS context */
27
+ cmscontext?: string;
28
+ }
15
29
  /** Interface describing an Otter Devtools service */
16
30
  export interface DevtoolsServiceInterface {
17
31
  /** Activate the devtools service */
@@ -1 +1 @@
1
- {"version":3,"file":"devtools.interface.d.ts","sourceRoot":"","sources":["../../../src/core/devkit/devtools.interface.ts"],"names":[],"mappings":"AAAA,8DAA8D;AAC9D,MAAM,WAAW,kBAAmB,SAAQ,MAAM;IAChD,8BAA8B;IAE9B,gBAAgB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CACxC;AAED,0DAA0D;AAC1D,MAAM,WAAW,qBAAqB;IACpC;;;;OAIG;IACH,sBAAsB,EAAE,OAAO,CAAC;CACjC;AAED,qDAAqD;AACrD,MAAM,WAAW,wBAAwB;IACvC,oCAAoC;IACpC,QAAQ,IAAI,IAAI,CAAC;CAClB"}
1
+ {"version":3,"file":"devtools.interface.d.ts","sourceRoot":"","sources":["../../../src/core/devkit/devtools.interface.ts"],"names":[],"mappings":"AAAA,8DAA8D;AAC9D,MAAM,WAAW,kBAAmB,SAAQ,MAAM;IAChD,8BAA8B;IAE9B,gBAAgB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;CACxC;AAED,0DAA0D;AAC1D,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,sBAAsB,EAAE,OAAO,CAAC;CACjC;AAED,4EAA4E;AAC5E,MAAM,WAAW,sCAAsC;IACrD;;;OAGG;IACH,oCAAoC,EAAE,OAAO,CAAC;CAC/C;AAED;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,mCAAmC;IACnC,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,qDAAqD;AACrD,MAAM,WAAW,wBAAwB;IACvC,oCAAoC;IACpC,QAAQ,IAAI,IAAI,CAAC;CAClB"}
package/core/index.d.ts CHANGED
@@ -3,4 +3,5 @@ export * from './common/index';
3
3
  export * from './devkit/index';
4
4
  export * from './interfaces/index';
5
5
  export * from './metadata/index';
6
+ export * from './rules-engine/index';
6
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC"}
package/core/index.js CHANGED
@@ -3,4 +3,5 @@ export * from './common/index';
3
3
  export * from './devkit/index';
4
4
  export * from './interfaces/index';
5
5
  export * from './metadata/index';
6
+ export * from './rules-engine/index';
6
7
  //# sourceMappingURL=index.js.map
package/core/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/core/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC"}
@@ -1,3 +1,4 @@
1
+ import type { Observable } from 'rxjs';
1
2
  /**
2
3
  * Types available for configuration
3
4
  */
@@ -9,28 +10,12 @@ export type ConfigurationValueType = string | number | boolean;
9
10
  export interface NestedConfiguration {
10
11
  [key: string]: ConfigurationValueType;
11
12
  }
12
- /**
13
- * @Deprecated will be removed in v10. Please use Configuration instead
14
- * Generic configuration
15
- */
16
- export interface LegacyConfiguration {
17
- [key: string]: ConfigurationValueType | Partial<LegacyConfiguration> | (ConfigurationValueType | Partial<LegacyConfiguration>)[] | undefined;
18
- }
19
13
  /**
20
14
  * Interface of configuration that is supported by the cms
21
15
  */
22
- export interface StrictConfiguration {
16
+ export interface Configuration {
23
17
  [key: string]: ConfigurationValueType | (string | NestedConfiguration)[];
24
18
  }
25
- /**
26
- * Configuration mode
27
- */
28
- export type ConfigurationMode = 'legacy' | 'strict';
29
- /**
30
- * Interface of configuration that is supported by the cms
31
- * NOTE: specify "legacy" as parameter type to disable strict mode and allow values not supported by the CMS. This option is strongly not recommended and deprecated.
32
- */
33
- export type Configuration<T extends ConfigurationMode = 'strict'> = T extends 'strict' ? StrictConfiguration : LegacyConfiguration;
34
19
  /** Configuration model exported by the CMS */
35
20
  export interface CustomConfig<T extends Partial<Configuration> = Partial<Configuration>> {
36
21
  /** Component name */
@@ -40,6 +25,28 @@ export interface CustomConfig<T extends Partial<Configuration> = Partial<Configu
40
25
  /** Component configuration as key value pairs */
41
26
  config: T;
42
27
  }
28
+ /**
29
+ * Dynamically Configurable item
30
+ */
31
+ export interface DynamicConfigurable<T extends Configuration> {
32
+ /**
33
+ * Configuration override
34
+ */
35
+ config: Partial<T> | undefined;
36
+ /**
37
+ * Configuration stream
38
+ */
39
+ config$: Observable<T>;
40
+ }
41
+ /**
42
+ * Configurable item
43
+ */
44
+ export interface Configurable<T extends {}> {
45
+ /**
46
+ * Configuration
47
+ */
48
+ config: T;
49
+ }
43
50
  /**
44
51
  * Description of a configuration property extracted to the CMS
45
52
  */
@@ -51,4 +58,19 @@ export interface CategoryDescription {
51
58
  }
52
59
  /** Types of components config */
53
60
  export type ConfigType = 'Block' | 'Page' | 'AppRuntimeConfiguration' | 'AppBuildConfiguration' | 'ExposedComponent';
61
+ /**
62
+ * Interface to define widget parameter to be used on CMS side
63
+ */
64
+ export interface ConfigPropertyWidgetParameters {
65
+ [parameterName: string]: string | boolean | number | string[] | boolean[] | number[];
66
+ }
67
+ /**
68
+ * Interface to define the widget to be used on CMS side
69
+ */
70
+ export interface ConfigPropertyWidget {
71
+ /** Type of the CMS widget */
72
+ type: string;
73
+ /** Parameters provided to the CMS widget */
74
+ parameters?: ConfigPropertyWidgetParameters;
75
+ }
54
76
  //# sourceMappingURL=configuration.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"configuration.d.ts","sourceRoot":"","sources":["../../../src/core/interfaces/configuration.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC;AAE/D;;;GAGG;AACH,MAAM,WAAW,mBAAmB;IAClC,CAAC,GAAG,EAAE,MAAM,GAAG,sBAAsB,CAAC;CACvC;AAED;;;GAGG;AACH,MAAM,WAAW,mBAAmB;IAClC,CAAC,GAAG,EAAE,MAAM,GAAG,sBAAsB,GAAG,OAAO,CAAC,mBAAmB,CAAC,GAAG,CAAC,sBAAsB,GAAG,OAAO,CAAC,mBAAmB,CAAC,CAAC,EAAE,GAAG,SAAS,CAAC;CAC9I;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,CAAC,GAAG,EAAE,MAAM,GAAG,sBAAsB,GAAG,CAAC,MAAM,GAAG,mBAAmB,CAAC,EAAE,CAAC;CAC1E;AAED;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAEpD;;;GAGG;AACH,MAAM,MAAM,aAAa,CAAC,CAAC,SAAS,iBAAiB,GAAG,QAAQ,IAAI,CAAC,SAAS,QAAQ,GAAG,mBAAmB,GAAG,mBAAmB,CAAC;AAEnI,8CAA8C;AAC9C,MAAM,WAAW,YAAY,CAAC,CAAC,SAAS,OAAO,CAAC,aAAa,CAAC,GAAG,OAAO,CAAC,aAAa,CAAC;IAErF,qBAAqB;IACrB,IAAI,EAAE,MAAM,CAAC;IAEb,kEAAkE;IAClE,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,iDAAiD;IACjD,MAAM,EAAE,CAAC,CAAC;CACX;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,oBAAoB;IACpB,IAAI,EAAE,MAAM,CAAC;IAEb,2BAA2B;IAC3B,KAAK,EAAE,MAAM,CAAC;CACf;AAED,iCAAiC;AACjC,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,MAAM,GAAG,yBAAyB,GAAG,uBAAuB,GAAG,kBAAkB,CAAC"}
1
+ {"version":3,"file":"configuration.d.ts","sourceRoot":"","sources":["../../../src/core/interfaces/configuration.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAEvC;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC;AAE/D;;;GAGG;AACH,MAAM,WAAW,mBAAmB;IAClC,CAAC,GAAG,EAAE,MAAM,GAAG,sBAAsB,CAAC;CACvC;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,CAAC,GAAG,EAAE,MAAM,GAAG,sBAAsB,GAAG,CAAC,MAAM,GAAG,mBAAmB,CAAC,EAAE,CAAC;CAC1E;AAED,8CAA8C;AAC9C,MAAM,WAAW,YAAY,CAAC,CAAC,SAAS,OAAO,CAAC,aAAa,CAAC,GAAG,OAAO,CAAC,aAAa,CAAC;IAErF,qBAAqB;IACrB,IAAI,EAAE,MAAM,CAAC;IAEb,kEAAkE;IAClE,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,iDAAiD;IACjD,MAAM,EAAE,CAAC,CAAC;CACX;AAED;;GAEG;AAEH,MAAM,WAAW,mBAAmB,CAAC,CAAC,SAAS,aAAa;IAC1D;;OAEG;IACH,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,GAAG,SAAS,CAAC;IAE/B;;OAEG;IACH,OAAO,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC;CACxB;AAED;;GAEG;AAEH,MAAM,WAAW,YAAY,CAAC,CAAC,SAAS,EAAE;IACxC;;OAEG;IACH,MAAM,EAAE,CAAC,CAAC;CACX;AAGD;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,oBAAoB;IACpB,IAAI,EAAE,MAAM,CAAC;IAEb,2BAA2B;IAC3B,KAAK,EAAE,MAAM,CAAC;CACf;AAED,iCAAiC;AACjC,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,MAAM,GAAG,yBAAyB,GAAG,uBAAuB,GAAG,kBAAkB,CAAC;AAErH;;GAEG;AACH,MAAM,WAAW,8BAA8B;IAC7C,CAAC,aAAa,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,EAAE,GAAG,OAAO,EAAE,GAAG,MAAM,EAAE,CAAC;CACtF;AAED;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC,6BAA6B;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,4CAA4C;IAC5C,UAAU,CAAC,EAAE,8BAA8B,CAAC;CAC7C"}
@@ -1,7 +1,4 @@
1
- export * from './block';
2
1
  export * from './configuration';
3
2
  export * from './context';
4
- export * from './exposed-component';
5
- export * from './page';
6
3
  export * from './translation';
7
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/interfaces/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC;AAC1B,cAAc,qBAAqB,CAAC;AACpC,cAAc,QAAQ,CAAC;AACvB,cAAc,eAAe,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/interfaces/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC"}
@@ -1,7 +1,4 @@
1
- export * from './block';
2
1
  export * from './configuration';
3
2
  export * from './context';
4
- export * from './exposed-component';
5
- export * from './page';
6
3
  export * from './translation';
7
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/core/interfaces/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAC;AACxB,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC;AAC1B,cAAc,qBAAqB,CAAC;AACpC,cAAc,QAAQ,CAAC;AACvB,cAAc,eAAe,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/core/interfaces/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC"}
@@ -25,7 +25,6 @@ export interface OtterComponentInfo extends OtterComponentInfoToProvide {
25
25
  export declare const otterComponentInfoPropertyName = "__otter-info__";
26
26
  /**
27
27
  * Decorates an Angular component to provide Otter information
28
- *
29
28
  * @param info Information to define the Otter component
30
29
  * @returns the component with the information
31
30
  */
@@ -1 +1 @@
1
- {"version":3,"file":"component.decorator.d.ts","sourceRoot":"","sources":["../../../src/core/metadata/component.decorator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAE/C,wBAAwB;AACxB,MAAM,MAAM,aAAa,GAAG,OAAO,GAAG,MAAM,GAAG,kBAAkB,GAAG,WAAW,CAAC;AAEhF;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C,wBAAwB;IACxB,aAAa,EAAE,aAAa,CAAC;CAC9B;AAED;;GAEG;AACH,MAAM,WAAW,kBAAmB,SAAQ,2BAA2B;IACrE,uBAAuB;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,uBAAuB;IACvB,YAAY,CAAC,EAAE,WAAW,CAAC;IAC3B,qBAAqB;IACrB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED;;GAEG;AACH,eAAO,MAAM,8BAA8B,mBAAmB,CAAC;AAE/D;;;;;GAKG;AAEH,wBAAgB,YAAY,CAAC,IAAI,EAAE,2BAA2B,4BAC5B,GAAG,EAAE,KAAK,MAAM,uBAKjD"}
1
+ {"version":3,"file":"component.decorator.d.ts","sourceRoot":"","sources":["../../../src/core/metadata/component.decorator.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,WAAW,EAAC,MAAM,eAAe,CAAC;AAE/C,wBAAwB;AACxB,MAAM,MAAM,aAAa,GAAG,OAAO,GAAG,MAAM,GAAG,kBAAkB,GAAG,WAAW,CAAC;AAEhF;;GAEG;AACH,MAAM,WAAW,2BAA2B;IAC1C,wBAAwB;IACxB,aAAa,EAAE,aAAa,CAAC;CAC9B;AAED;;GAEG;AACH,MAAM,WAAW,kBAAmB,SAAQ,2BAA2B;IACrE,uBAAuB;IACvB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,uBAAuB;IACvB,YAAY,CAAC,EAAE,WAAW,CAAC;IAC3B,qBAAqB;IACrB,aAAa,EAAE,MAAM,CAAC;CACvB;AAED;;GAEG;AACH,eAAO,MAAM,8BAA8B,mBAAmB,CAAC;AAE/D;;;;GAIG;AAEH,wBAAgB,YAAY,CAAC,IAAI,EAAE,2BAA2B,4BAC5B,GAAG,EAAE,KAAK,MAAM,uBAKjD"}
@@ -4,7 +4,6 @@
4
4
  export const otterComponentInfoPropertyName = '__otter-info__';
5
5
  /**
6
6
  * Decorates an Angular component to provide Otter information
7
- *
8
7
  * @param info Information to define the Otter component
9
8
  * @returns the component with the information
10
9
  */
@@ -1 +1 @@
1
- {"version":3,"file":"component.decorator.js","sourceRoot":"","sources":["../../../src/core/metadata/component.decorator.ts"],"names":[],"mappings":"AAyBA;;GAEG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG,gBAAgB,CAAC;AAE/D;;;;;GAKG;AACH,gEAAgE;AAChE,MAAM,UAAU,YAAY,CAAC,IAAiC;IAC5D,OAAO,CAA2C,WAAc,EAAE,EAAE;QAClE,MAAM,aAAa,GAAG,WAAW,CAAC,IAAI,CAAC;QACvC,WAAW,CAAC,SAAS,CAAC,8BAA8B,CAAC,GAAG,EAAC,GAAG,IAAI,EAAE,aAAa,EAAC,CAAC;QACjF,OAAO,WAAW,CAAC;IACrB,CAAC,CAAC;AACJ,CAAC"}
1
+ {"version":3,"file":"component.decorator.js","sourceRoot":"","sources":["../../../src/core/metadata/component.decorator.ts"],"names":[],"mappings":"AAyBA;;GAEG;AACH,MAAM,CAAC,MAAM,8BAA8B,GAAG,gBAAgB,CAAC;AAE/D;;;;GAIG;AACH,gEAAgE;AAChE,MAAM,UAAU,YAAY,CAAC,IAAiC;IAC5D,OAAO,CAA2C,WAAc,EAAE,EAAE;QAClE,MAAM,aAAa,GAAG,WAAW,CAAC,IAAI,CAAC;QACvC,WAAW,CAAC,SAAS,CAAC,8BAA8B,CAAC,GAAG,EAAC,GAAG,IAAI,EAAE,aAAa,EAAC,CAAC;QACjF,OAAO,WAAW,CAAC;IACrB,CAAC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Compute the name of the component with the library's name to generate unique component identifier used in metadata and different modules
3
+ * @param componentName Name of the component to get the configuration
4
+ * @param libraryName Name of the library the component is coming from
5
+ */
6
+ export declare function computeItemIdentifier(componentName: string, libraryName?: string): string;
7
+ //# sourceMappingURL=component.identifier.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"component.identifier.d.ts","sourceRoot":"","sources":["../../../src/core/metadata/component.identifier.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,MAAM,EAAE,WAAW,CAAC,EAAE,MAAM,UAEhF"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Compute the name of the component with the library's name to generate unique component identifier used in metadata and different modules
3
+ * @param componentName Name of the component to get the configuration
4
+ * @param libraryName Name of the library the component is coming from
5
+ */
6
+ export function computeItemIdentifier(componentName, libraryName) {
7
+ return (libraryName ? libraryName + '#' : '') + componentName;
8
+ }
9
+ //# sourceMappingURL=component.identifier.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"component.identifier.js","sourceRoot":"","sources":["../../../src/core/metadata/component.identifier.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,MAAM,UAAU,qBAAqB,CAAC,aAAqB,EAAE,WAAoB;IAC/E,OAAO,CAAC,WAAW,CAAC,CAAC,CAAC,WAAW,GAAG,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,aAAa,CAAC;AAChE,CAAC"}
@@ -1,3 +1,4 @@
1
1
  export * from './component.decorator';
2
2
  export * from './metadata.interface';
3
+ export * from './component.identifier';
3
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/metadata/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/core/metadata/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,wBAAwB,CAAC"}