@veloceapps/sdk 8.0.0-17 → 8.0.0-171

Sign up to get free protection for your applications and to get access to all the features.
Files changed (347) hide show
  1. package/README.md +0 -1
  2. package/cms/README.md +0 -20
  3. package/cms/cms.actions.d.ts +7 -1
  4. package/cms/components/preview/preview.component.d.ts +2 -3
  5. package/cms/components/preview/preview.types.d.ts +4 -0
  6. package/cms/index.d.ts +1 -0
  7. package/cms/modules/runtime/services/runtime.service.d.ts +1 -1
  8. package/cms/services/index.d.ts +0 -1
  9. package/cms/types/index.d.ts +0 -1
  10. package/cms/utils/element-metadata-worker.d.ts +11 -0
  11. package/cms/utils/elements-resolver.d.ts +0 -2
  12. package/cms/utils/index.d.ts +3 -0
  13. package/cms/utils/transpilation-worker.d.ts +13 -0
  14. package/cms/vendor-map.d.ts +26 -15
  15. package/core/README.md +20 -0
  16. package/core/modules/configuration/configuration.module.d.ts +2 -1
  17. package/core/modules/configuration/helpers.d.ts +4 -3
  18. package/core/modules/configuration/index.d.ts +1 -1
  19. package/core/modules/configuration/services/configuration-runtime.service.d.ts +1 -1
  20. package/core/modules/configuration/services/configuration-state.service.d.ts +51 -0
  21. package/core/modules/configuration/services/configuration.service.d.ts +10 -5
  22. package/core/modules/configuration/types/configuration.types.d.ts +4 -0
  23. package/core/modules/flow-configuration/flow-configuration.module.d.ts +2 -1
  24. package/core/modules/flow-configuration/services/flow-configuration.service.d.ts +5 -0
  25. package/core/pipes/action-code.pipe.d.ts +8 -0
  26. package/core/pipes/date.pipe.d.ts +2 -1
  27. package/core/pipes/index.d.ts +1 -0
  28. package/core/pipes/pipes.module.d.ts +2 -1
  29. package/core/services/context.service.d.ts +4 -0
  30. package/core/services/flow-info.service.d.ts +29 -0
  31. package/core/services/flow-state-configuration.service.d.ts +19 -0
  32. package/core/services/flow-state.service.d.ts +79 -0
  33. package/core/services/index.d.ts +4 -1
  34. package/core/services/quote-draft.service.d.ts +8 -1
  35. package/core/services/runtime-settings.service.d.ts +4 -1
  36. package/core/types/flow-customization.types.d.ts +22 -0
  37. package/core/types/flow-state.types.d.ts +6 -0
  38. package/core/types/formatting-settings.types.d.ts +2 -0
  39. package/core/types/index.d.ts +3 -0
  40. package/{cms → core}/types/integration.types.d.ts +1 -0
  41. package/core/types/pipe.types.d.ts +1 -0
  42. package/core/utils/line-item.utils.d.ts +0 -1
  43. package/esm2020/cms/cms.actions.mjs +15 -1
  44. package/esm2020/cms/components/element-children/element-children.component.mjs +3 -3
  45. package/esm2020/cms/components/element-children/element-children.module.mjs +4 -4
  46. package/esm2020/cms/components/element-drop-handle/element-drop-handle.component.mjs +3 -3
  47. package/esm2020/cms/components/element-drop-handle/element-drop-handle.module.mjs +4 -4
  48. package/esm2020/cms/components/element-renderer/element-renderer.component.mjs +6 -6
  49. package/esm2020/cms/components/element-renderer/element-renderer.module.mjs +4 -4
  50. package/esm2020/cms/components/element-tools-panel/element-tools-panel.component.mjs +5 -5
  51. package/esm2020/cms/components/plugin.component.mjs +3 -3
  52. package/esm2020/cms/components/preview/preview.component.mjs +11 -11
  53. package/esm2020/cms/components/preview/preview.module.mjs +6 -6
  54. package/esm2020/cms/components/preview/preview.types.mjs +1 -1
  55. package/esm2020/cms/directives/custom-template.directive.mjs +7 -7
  56. package/esm2020/cms/index.mjs +2 -1
  57. package/esm2020/cms/launcher.module.mjs +7 -7
  58. package/esm2020/cms/modules/federated/federated-host.directive.mjs +3 -3
  59. package/esm2020/cms/modules/federated/federated.component.mjs +3 -3
  60. package/esm2020/cms/modules/federated/federated.module.mjs +4 -4
  61. package/esm2020/cms/modules/migrations/migrations.mjs +2 -2
  62. package/esm2020/cms/modules/migrations/migrations.module.mjs +4 -4
  63. package/esm2020/cms/modules/migrations/services/migrations.service.mjs +9 -5
  64. package/esm2020/cms/modules/runtime/runtime.module.mjs +4 -4
  65. package/esm2020/cms/modules/runtime/services/compilation.service.mjs +14 -10
  66. package/esm2020/cms/modules/runtime/services/runtime-editor.service.mjs +3 -3
  67. package/esm2020/cms/modules/runtime/services/runtime.service.mjs +7 -7
  68. package/esm2020/cms/plugins/configuration.plugin.mjs +11 -7
  69. package/esm2020/cms/plugins/element-hover.plugin.mjs +3 -3
  70. package/esm2020/cms/plugins/io.plugin.mjs +3 -3
  71. package/esm2020/cms/plugins/page.plugin.mjs +3 -3
  72. package/esm2020/cms/plugins/region.plugin.mjs +3 -3
  73. package/esm2020/cms/plugins/script.plugin.mjs +3 -3
  74. package/esm2020/cms/services/element-context.service.mjs +3 -3
  75. package/esm2020/cms/services/index.mjs +1 -2
  76. package/esm2020/cms/services/io-provider.service.mjs +13 -12
  77. package/esm2020/cms/services/resources.service.mjs +3 -3
  78. package/esm2020/cms/services/templates.service.mjs +13 -12
  79. package/esm2020/cms/types/index.mjs +1 -2
  80. package/esm2020/cms/utils/element-metadata-worker.mjs +31 -0
  81. package/esm2020/cms/utils/elements-resolver.mjs +14 -28
  82. package/esm2020/cms/utils/index.mjs +4 -1
  83. package/esm2020/cms/utils/path.utils.mjs +3 -3
  84. package/esm2020/cms/utils/transpilation-worker.mjs +52 -0
  85. package/esm2020/cms/vendor-map.mjs +18 -6
  86. package/esm2020/core/core.module.mjs +16 -9
  87. package/esm2020/core/directives/directives.module.mjs +4 -4
  88. package/esm2020/core/directives/primeng-calendar.directive.mjs +3 -3
  89. package/esm2020/core/modules/configuration/configuration.module.mjs +9 -25
  90. package/esm2020/core/modules/configuration/helpers.mjs +28 -3
  91. package/esm2020/core/modules/configuration/index.mjs +2 -2
  92. package/esm2020/core/modules/configuration/services/configuration-runtime.service.mjs +11 -14
  93. package/esm2020/core/modules/configuration/services/configuration-state.service.mjs +299 -0
  94. package/esm2020/core/modules/configuration/services/configuration.service.mjs +70 -47
  95. package/esm2020/core/modules/configuration/services/runtime-context.service.mjs +9 -9
  96. package/esm2020/core/modules/configuration/types/configuration.types.mjs +1 -1
  97. package/esm2020/core/modules/flow-configuration/flow-configuration.module.mjs +8 -8
  98. package/esm2020/core/modules/flow-configuration/services/flow-configuration.service.mjs +13 -10
  99. package/esm2020/core/modules/flow-configuration/services/flow-update.service.mjs +3 -3
  100. package/esm2020/core/pipes/action-code.pipe.mjs +20 -0
  101. package/esm2020/core/pipes/date.pipe.mjs +13 -7
  102. package/esm2020/core/pipes/index.mjs +2 -1
  103. package/esm2020/core/pipes/number.pipe.mjs +3 -3
  104. package/esm2020/core/pipes/pipes.module.mjs +8 -7
  105. package/esm2020/core/pipes/price.pipe.mjs +3 -3
  106. package/esm2020/core/services/context.service.mjs +34 -7
  107. package/esm2020/core/services/flow-info.service.mjs +99 -0
  108. package/esm2020/core/services/flow-state-configuration.service.mjs +53 -0
  109. package/esm2020/core/services/flow-state.service.mjs +502 -0
  110. package/esm2020/core/services/index.mjs +5 -2
  111. package/esm2020/core/services/integration.state.mjs +36 -0
  112. package/esm2020/core/services/product-images.service.mjs +6 -7
  113. package/esm2020/core/services/quote-draft.service.mjs +33 -9
  114. package/esm2020/core/services/runtime-settings.service.mjs +21 -7
  115. package/esm2020/core/types/flow-customization.types.mjs +3 -0
  116. package/esm2020/core/types/flow-state.types.mjs +2 -0
  117. package/esm2020/core/types/formatting-settings.types.mjs +1 -1
  118. package/esm2020/core/types/index.mjs +4 -1
  119. package/esm2020/core/types/integration.types.mjs +2 -0
  120. package/esm2020/core/types/pipe.types.mjs +2 -0
  121. package/esm2020/core/utils/line-item.utils.mjs +30 -15
  122. package/esm2020/src/components/dialog/dialog.component.mjs +3 -3
  123. package/esm2020/src/components/dialog/dialog.module.mjs +4 -4
  124. package/esm2020/src/components/doc-gen/doc-gen.component.mjs +51 -51
  125. package/esm2020/src/components/doc-gen/doc-gen.module.mjs +4 -4
  126. package/esm2020/src/components/flow-header/flow-header.component.mjs +108 -0
  127. package/esm2020/src/components/flow-header/flow-header.module.mjs +19 -0
  128. package/esm2020/src/components/flow-header/index.mjs +2 -0
  129. package/esm2020/src/components/guided-selling/guided-selling.component.mjs +39 -45
  130. package/esm2020/src/components/guided-selling/guided-selling.module.mjs +4 -4
  131. package/esm2020/src/configure-primeng.mjs +33 -0
  132. package/esm2020/src/flow-routing.module.mjs +66 -75
  133. package/esm2020/src/flow.component.mjs +24 -33
  134. package/esm2020/src/flow.module.mjs +11 -9
  135. package/esm2020/src/guards/context.guard.mjs +9 -14
  136. package/esm2020/src/guards/flow.guard.mjs +37 -0
  137. package/esm2020/src/guards/product-unload.guard.mjs +7 -4
  138. package/esm2020/src/guards/root.guard.mjs +17 -13
  139. package/esm2020/src/pages/assets/assets.component.mjs +34 -38
  140. package/esm2020/src/pages/assets/assets.module.mjs +4 -4
  141. package/esm2020/src/pages/catalog/catalog.component.mjs +34 -38
  142. package/esm2020/src/pages/catalog/catalog.module.mjs +4 -4
  143. package/esm2020/src/pages/debug/debug.component.mjs +12 -16
  144. package/esm2020/src/pages/debug/debug.module.mjs +4 -4
  145. package/esm2020/src/pages/empty-account/empty-account.component.mjs +3 -3
  146. package/esm2020/src/pages/empty-account/empty-account.module.mjs +4 -4
  147. package/esm2020/src/pages/product/product.component.mjs +24 -14
  148. package/esm2020/src/pages/product/product.module.mjs +4 -4
  149. package/esm2020/src/pages/record-not-found/record-not-found.component.mjs +8 -5
  150. package/esm2020/src/pages/record-not-found/record-not-found.module.mjs +4 -4
  151. package/esm2020/src/pages/remote/remote.component.mjs +20 -20
  152. package/esm2020/src/pages/remote/remote.module.mjs +4 -4
  153. package/esm2020/src/pages/shopping-cart/shopping-cart.component.mjs +35 -39
  154. package/esm2020/src/pages/shopping-cart/shopping-cart.module.mjs +4 -4
  155. package/esm2020/src/resolvers/flow.resolver.mjs +39 -51
  156. package/esm2020/src/resolvers/quote.resolver.mjs +57 -65
  157. package/esm2020/src/services/doc-gen.service.mjs +7 -6
  158. package/esm2020/src/services/flow-dialog.service.mjs +23 -8
  159. package/esm2020/src/services/flow-router.service.mjs +59 -18
  160. package/esm2020/src/services/flow.service.mjs +72 -25
  161. package/esm2020/src/services/guided-selling.service.mjs +8 -7
  162. package/esm2020/src/services/index.mjs +3 -1
  163. package/esm2020/src/types/index.mjs +1 -2
  164. package/esm2020/src/utils/flow.utils.mjs +6 -2
  165. package/fesm2015/veloceapps-sdk-cms.mjs +355 -271
  166. package/fesm2015/veloceapps-sdk-cms.mjs.map +1 -1
  167. package/fesm2015/veloceapps-sdk-core.mjs +1639 -781
  168. package/fesm2015/veloceapps-sdk-core.mjs.map +1 -1
  169. package/fesm2015/veloceapps-sdk.mjs +828 -1541
  170. package/fesm2015/veloceapps-sdk.mjs.map +1 -1
  171. package/fesm2020/veloceapps-sdk-cms.mjs +357 -283
  172. package/fesm2020/veloceapps-sdk-cms.mjs.map +1 -1
  173. package/fesm2020/veloceapps-sdk-core.mjs +1780 -958
  174. package/fesm2020/veloceapps-sdk-core.mjs.map +1 -1
  175. package/fesm2020/veloceapps-sdk.mjs +888 -1599
  176. package/fesm2020/veloceapps-sdk.mjs.map +1 -1
  177. package/package.json +7 -14
  178. package/src/components/doc-gen/doc-gen.component.d.ts +8 -9
  179. package/src/components/flow-header/flow-header.component.d.ts +25 -0
  180. package/src/components/flow-header/flow-header.module.d.ts +9 -0
  181. package/src/components/flow-header/index.d.ts +1 -0
  182. package/src/components/guided-selling/guided-selling.component.d.ts +6 -8
  183. package/src/configure-primeng.d.ts +1 -0
  184. package/src/flow-routing.module.d.ts +6 -7
  185. package/src/flow.component.d.ts +7 -11
  186. package/src/flow.module.d.ts +2 -2
  187. package/src/guards/context.guard.d.ts +4 -5
  188. package/src/guards/flow.guard.d.ts +2 -0
  189. package/src/guards/product-unload.guard.d.ts +2 -2
  190. package/src/guards/root.guard.d.ts +0 -1
  191. package/src/pages/assets/assets.component.d.ts +5 -7
  192. package/src/pages/catalog/catalog.component.d.ts +5 -7
  193. package/src/pages/debug/debug.component.d.ts +5 -8
  194. package/src/pages/product/product.component.d.ts +7 -6
  195. package/src/pages/record-not-found/record-not-found.component.d.ts +2 -0
  196. package/src/pages/remote/remote.component.d.ts +2 -3
  197. package/src/pages/shopping-cart/shopping-cart.component.d.ts +5 -7
  198. package/src/resolvers/flow.resolver.d.ts +6 -7
  199. package/src/resolvers/quote.resolver.d.ts +7 -12
  200. package/src/services/doc-gen.service.d.ts +1 -1
  201. package/src/services/flow-dialog.service.d.ts +5 -2
  202. package/src/services/flow-router.service.d.ts +7 -3
  203. package/src/services/flow.service.d.ts +10 -4
  204. package/src/services/guided-selling.service.d.ts +1 -1
  205. package/src/services/index.d.ts +2 -0
  206. package/src/types/index.d.ts +0 -1
  207. package/core/modules/configuration/services/configuration.state.d.ts +0 -30
  208. package/core/services/metric-calculation/metric-calculation.service.d.ts +0 -25
  209. package/core/services/metric-calculation/metric-calculation.types.d.ts +0 -1
  210. package/core/services/metric-calculation/metric-calculation.utils.d.ts +0 -5
  211. package/esm2020/cms/services/integration.state.mjs +0 -37
  212. package/esm2020/cms/types/integration.types.mjs +0 -2
  213. package/esm2020/core/modules/configuration/services/configuration.state.mjs +0 -142
  214. package/esm2020/core/services/metric-calculation/metric-calculation.service.mjs +0 -85
  215. package/esm2020/core/services/metric-calculation/metric-calculation.types.mjs +0 -2
  216. package/esm2020/core/services/metric-calculation/metric-calculation.utils.mjs +0 -42
  217. package/esm2020/runtime/components/component-preview/component-preview.component.mjs +0 -125
  218. package/esm2020/runtime/components/index.mjs +0 -5
  219. package/esm2020/runtime/components/section-renderer/section-renderer.component.mjs +0 -67
  220. package/esm2020/runtime/components/ui-runtime/runtime.component.mjs +0 -440
  221. package/esm2020/runtime/components/ui-runtime-preview/runtime-preview.component.mjs +0 -108
  222. package/esm2020/runtime/execution/components/children-placeholder/children-placeholder.component.mjs +0 -60
  223. package/esm2020/runtime/execution/components/context-provider/context-provider.component.mjs +0 -39
  224. package/esm2020/runtime/execution/components/execution-section-renderer/execution-section-renderer.component.mjs +0 -67
  225. package/esm2020/runtime/execution/components/federated/federated.component.mjs +0 -74
  226. package/esm2020/runtime/execution/components/velo-attribute/velo-attribute.component.mjs +0 -60
  227. package/esm2020/runtime/execution/components/velo-multiselect/velo-multiselect.component.mjs +0 -130
  228. package/esm2020/runtime/execution/components/velo-port-checkbox/velo-port-checkbox.component.mjs +0 -72
  229. package/esm2020/runtime/execution/components/velo-port-dropdown/velo-port-dropdown.component.mjs +0 -97
  230. package/esm2020/runtime/execution/components/velo-port-radio/velo-port-radio.component.mjs +0 -142
  231. package/esm2020/runtime/execution/components/velo-type/velo-type.component.mjs +0 -119
  232. package/esm2020/runtime/execution/directives/section-script.directive.mjs +0 -247
  233. package/esm2020/runtime/execution/directives/sf-query.directive.mjs +0 -35
  234. package/esm2020/runtime/execution/directives/velo-attribute.directive.mjs +0 -88
  235. package/esm2020/runtime/execution/directives/velo-port.directive.mjs +0 -376
  236. package/esm2020/runtime/execution/directives/vl-approval.directive.mjs +0 -23
  237. package/esm2020/runtime/execution/directives/vl-document-attachments.directive.mjs +0 -36
  238. package/esm2020/runtime/execution/directives/vl-document-templates.directive.mjs +0 -60
  239. package/esm2020/runtime/execution/directives/vl-quote.directive.mjs +0 -42
  240. package/esm2020/runtime/execution/directives/vl-ramp.directive.mjs +0 -55
  241. package/esm2020/runtime/execution/runtime-execution.module.mjs +0 -133
  242. package/esm2020/runtime/execution/utils/federated.util.mjs +0 -32
  243. package/esm2020/runtime/index.mjs +0 -5
  244. package/esm2020/runtime/runtime.module.mjs +0 -74
  245. package/esm2020/runtime/services/cart.service.mjs +0 -29
  246. package/esm2020/runtime/services/collapsible-state.service.mjs +0 -34
  247. package/esm2020/runtime/services/configuration.service.mjs +0 -119
  248. package/esm2020/runtime/services/current-state.service.mjs +0 -17
  249. package/esm2020/runtime/services/form-scope.service.mjs +0 -30
  250. package/esm2020/runtime/services/index.mjs +0 -4
  251. package/esm2020/runtime/services/product-model-cache.service.mjs +0 -31
  252. package/esm2020/runtime/services/runtime-context.service.mjs +0 -60
  253. package/esm2020/runtime/services/runtime-form.service.mjs +0 -219
  254. package/esm2020/runtime/services/runtime.service.mjs +0 -115
  255. package/esm2020/runtime/services/section-helper.service.mjs +0 -27
  256. package/esm2020/runtime/services/section-scope.service.mjs +0 -36
  257. package/esm2020/runtime/services/section-store.service.mjs +0 -22
  258. package/esm2020/runtime/services/section.service.mjs +0 -117
  259. package/esm2020/runtime/types/bound-data.types.mjs +0 -7
  260. package/esm2020/runtime/types/index.mjs +0 -3
  261. package/esm2020/runtime/types/quote-states.types.mjs +0 -2
  262. package/esm2020/runtime/types/runtime.types.mjs +0 -2
  263. package/esm2020/runtime/types/script-registry.types.mjs +0 -51
  264. package/esm2020/runtime/utils/line-item.util.mjs +0 -270
  265. package/esm2020/runtime/utils/section.utils.mjs +0 -26
  266. package/esm2020/runtime/utils/sections-binder.helper.mjs +0 -105
  267. package/esm2020/runtime/veloceapps-sdk-runtime.mjs +0 -5
  268. package/esm2020/src/components/header/cart-overlay/cart-preview.component.mjs +0 -119
  269. package/esm2020/src/components/header/cart-overlay/cart-preview.module.mjs +0 -47
  270. package/esm2020/src/components/header/header.component.mjs +0 -355
  271. package/esm2020/src/components/header/header.module.mjs +0 -52
  272. package/esm2020/src/components/header/header.types.mjs +0 -2
  273. package/esm2020/src/components/header/metrics/index.mjs +0 -2
  274. package/esm2020/src/components/header/metrics/metrics.component.mjs +0 -255
  275. package/esm2020/src/components/header/metrics/metrics.definitions.mjs +0 -2
  276. package/esm2020/src/components/header/metrics/metrics.module.mjs +0 -69
  277. package/esm2020/src/pages/legacy-product/legacy-product.component.mjs +0 -137
  278. package/esm2020/src/pages/legacy-product/legacy-product.module.mjs +0 -19
  279. package/esm2020/src/types/flow-customization.types.mjs +0 -3
  280. package/fesm2015/veloceapps-sdk-runtime.mjs +0 -3770
  281. package/fesm2015/veloceapps-sdk-runtime.mjs.map +0 -1
  282. package/fesm2020/veloceapps-sdk-runtime.mjs +0 -3767
  283. package/fesm2020/veloceapps-sdk-runtime.mjs.map +0 -1
  284. package/runtime/README.md +0 -5
  285. package/runtime/components/component-preview/component-preview.component.d.ts +0 -27
  286. package/runtime/components/index.d.ts +0 -4
  287. package/runtime/components/section-renderer/section-renderer.component.d.ts +0 -25
  288. package/runtime/components/ui-runtime/runtime.component.d.ts +0 -53
  289. package/runtime/components/ui-runtime-preview/runtime-preview.component.d.ts +0 -27
  290. package/runtime/execution/components/children-placeholder/children-placeholder.component.d.ts +0 -30
  291. package/runtime/execution/components/context-provider/context-provider.component.d.ts +0 -14
  292. package/runtime/execution/components/execution-section-renderer/execution-section-renderer.component.d.ts +0 -25
  293. package/runtime/execution/components/federated/federated.component.d.ts +0 -36
  294. package/runtime/execution/components/velo-attribute/velo-attribute.component.d.ts +0 -19
  295. package/runtime/execution/components/velo-multiselect/velo-multiselect.component.d.ts +0 -35
  296. package/runtime/execution/components/velo-port-checkbox/velo-port-checkbox.component.d.ts +0 -22
  297. package/runtime/execution/components/velo-port-dropdown/velo-port-dropdown.component.d.ts +0 -22
  298. package/runtime/execution/components/velo-port-radio/velo-port-radio.component.d.ts +0 -28
  299. package/runtime/execution/components/velo-type/velo-type.component.d.ts +0 -31
  300. package/runtime/execution/directives/section-script.directive.d.ts +0 -59
  301. package/runtime/execution/directives/sf-query.directive.d.ts +0 -15
  302. package/runtime/execution/directives/velo-attribute.directive.d.ts +0 -26
  303. package/runtime/execution/directives/velo-port.directive.d.ts +0 -74
  304. package/runtime/execution/directives/vl-approval.directive.d.ts +0 -10
  305. package/runtime/execution/directives/vl-document-attachments.directive.d.ts +0 -15
  306. package/runtime/execution/directives/vl-document-templates.directive.d.ts +0 -33
  307. package/runtime/execution/directives/vl-quote.directive.d.ts +0 -14
  308. package/runtime/execution/directives/vl-ramp.directive.d.ts +0 -15
  309. package/runtime/execution/runtime-execution.module.d.ts +0 -25
  310. package/runtime/execution/utils/federated.util.d.ts +0 -6
  311. package/runtime/index.d.ts +0 -4
  312. package/runtime/runtime.module.d.ts +0 -16
  313. package/runtime/services/cart.service.d.ts +0 -15
  314. package/runtime/services/collapsible-state.service.d.ts +0 -15
  315. package/runtime/services/configuration.service.d.ts +0 -20
  316. package/runtime/services/current-state.service.d.ts +0 -8
  317. package/runtime/services/form-scope.service.d.ts +0 -20
  318. package/runtime/services/index.d.ts +0 -3
  319. package/runtime/services/product-model-cache.service.d.ts +0 -14
  320. package/runtime/services/runtime-context.service.d.ts +0 -16
  321. package/runtime/services/runtime-form.service.d.ts +0 -24
  322. package/runtime/services/runtime.service.d.ts +0 -44
  323. package/runtime/services/section-helper.service.d.ts +0 -8
  324. package/runtime/services/section-scope.service.d.ts +0 -14
  325. package/runtime/services/section-store.service.d.ts +0 -11
  326. package/runtime/services/section.service.d.ts +0 -30
  327. package/runtime/types/bound-data.types.d.ts +0 -13
  328. package/runtime/types/index.d.ts +0 -2
  329. package/runtime/types/quote-states.types.d.ts +0 -6
  330. package/runtime/types/runtime.types.d.ts +0 -19
  331. package/runtime/types/script-registry.types.d.ts +0 -13
  332. package/runtime/utils/line-item.util.d.ts +0 -34
  333. package/runtime/utils/section.utils.d.ts +0 -2
  334. package/runtime/utils/sections-binder.helper.d.ts +0 -16
  335. package/src/components/header/cart-overlay/cart-preview.component.d.ts +0 -36
  336. package/src/components/header/cart-overlay/cart-preview.module.d.ts +0 -14
  337. package/src/components/header/header.component.d.ts +0 -70
  338. package/src/components/header/header.module.d.ts +0 -16
  339. package/src/components/header/header.types.d.ts +0 -20
  340. package/src/components/header/metrics/index.d.ts +0 -1
  341. package/src/components/header/metrics/metrics.component.d.ts +0 -67
  342. package/src/components/header/metrics/metrics.definitions.d.ts +0 -1
  343. package/src/components/header/metrics/metrics.module.d.ts +0 -18
  344. package/src/pages/legacy-product/legacy-product.component.d.ts +0 -37
  345. package/src/pages/legacy-product/legacy-product.module.d.ts +0 -9
  346. package/src/types/flow-customization.types.d.ts +0 -12
  347. /package/{cms → core}/services/integration.state.d.ts +0 -0
@@ -0,0 +1,53 @@
1
+ import { Injectable } from '@angular/core';
2
+ import { FlowStateApiService } from '@veloceapps/api';
3
+ import { BehaviorSubject, map, noop, of, switchMap, tap } from 'rxjs';
4
+ import { generateConfigurationLineItem } from '../modules/configuration';
5
+ import { FlowConfigurationService } from '../modules/flow-configuration';
6
+ import { FlowInfoService } from './flow-info.service';
7
+ import { FlowStateService } from './flow-state.service';
8
+ import * as i0 from "@angular/core";
9
+ import * as i1 from "./flow-info.service";
10
+ import * as i2 from "../modules/flow-configuration";
11
+ import * as i3 from "@veloceapps/api";
12
+ import * as i4 from "./flow-state.service";
13
+ export class FlowStateConfigurationService {
14
+ constructor(flowInfoService, flowConfigurationService, flowStateApiService, flowStateService) {
15
+ this.flowInfoService = flowInfoService;
16
+ this.flowConfigurationService = flowConfigurationService;
17
+ this.flowStateApiService = flowStateApiService;
18
+ this.flowStateService = flowStateService;
19
+ this.configurationStateId$ = new BehaviorSubject(null);
20
+ }
21
+ get configurationStateId() {
22
+ return this.configurationStateId$.value;
23
+ }
24
+ addToCart$(props) {
25
+ let request$;
26
+ const stateful = this.flowInfoService.flow?.properties.stateful;
27
+ if (stateful) {
28
+ const stateId = this.flowStateService.stateId;
29
+ if (!stateId) {
30
+ request$ = of();
31
+ }
32
+ else {
33
+ const lineItem = generateConfigurationLineItem(props, props.qty);
34
+ request$ = this.flowStateApiService.newConfiguration(stateId, { lineItem }).pipe(tap(r => this.configurationStateId$.next(r.stateId)), switchMap(() => {
35
+ if (!this.configurationStateId) {
36
+ return of();
37
+ }
38
+ return this.flowStateApiService.saveConfiguration(stateId, this.configurationStateId).pipe(tap(() => this.configurationStateId$.next(null)), map(noop));
39
+ }));
40
+ }
41
+ }
42
+ else {
43
+ request$ = this.flowConfigurationService.addToCart$(props).pipe(map(noop));
44
+ }
45
+ return request$.pipe(switchMap(() => this.flowStateService.executeRequest$({}, true)), map(noop));
46
+ }
47
+ }
48
+ FlowStateConfigurationService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FlowStateConfigurationService, deps: [{ token: i1.FlowInfoService }, { token: i2.FlowConfigurationService }, { token: i3.FlowStateApiService }, { token: i4.FlowStateService }], target: i0.ɵɵFactoryTarget.Injectable });
49
+ FlowStateConfigurationService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FlowStateConfigurationService });
50
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.9", ngImport: i0, type: FlowStateConfigurationService, decorators: [{
51
+ type: Injectable
52
+ }], ctorParameters: function () { return [{ type: i1.FlowInfoService }, { type: i2.FlowConfigurationService }, { type: i3.FlowStateApiService }, { type: i4.FlowStateService }]; } });
53
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZmxvdy1zdGF0ZS1jb25maWd1cmF0aW9uLnNlcnZpY2UuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9saWJzL3Nkay9jb3JlL3NlcnZpY2VzL2Zsb3ctc3RhdGUtY29uZmlndXJhdGlvbi5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxVQUFVLEVBQUUsTUFBTSxlQUFlLENBQUM7QUFDM0MsT0FBTyxFQUFFLG1CQUFtQixFQUFFLE1BQU0saUJBQWlCLENBQUM7QUFDdEQsT0FBTyxFQUFFLGVBQWUsRUFBRSxHQUFHLEVBQUUsSUFBSSxFQUFjLEVBQUUsRUFBRSxTQUFTLEVBQUUsR0FBRyxFQUFFLE1BQU0sTUFBTSxDQUFDO0FBQ2xGLE9BQU8sRUFBRSw2QkFBNkIsRUFBeUIsTUFBTSwwQkFBMEIsQ0FBQztBQUNoRyxPQUFPLEVBQUUsd0JBQXdCLEVBQUUsTUFBTSwrQkFBK0IsQ0FBQztBQUN6RSxPQUFPLEVBQUUsZUFBZSxFQUFFLE1BQU0scUJBQXFCLENBQUM7QUFDdEQsT0FBTyxFQUFFLGdCQUFnQixFQUFFLE1BQU0sc0JBQXNCLENBQUM7Ozs7OztBQUd4RCxNQUFNLE9BQU8sNkJBQTZCO0lBR3hDLFlBQ1UsZUFBZ0MsRUFDaEMsd0JBQWtELEVBQ2xELG1CQ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