@acorex/platform 1.0.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 (561) hide show
  1. package/README.md +7 -0
  2. package/auth/README.md +3 -0
  3. package/auth/index.d.ts +16 -0
  4. package/auth/lib/application/application.loader.d.ts +9 -0
  5. package/auth/lib/application/application.types.d.ts +10 -0
  6. package/auth/lib/auth-registry.service.d.ts +12 -0
  7. package/auth/lib/auth.guard.d.ts +2 -0
  8. package/auth/lib/auth.module.d.ts +20 -0
  9. package/auth/lib/auth.strategy.d.ts +28 -0
  10. package/auth/lib/errors.types.d.ts +6 -0
  11. package/auth/lib/feature/feature.loader.d.ts +7 -0
  12. package/auth/lib/feature/feature.types.d.ts +6 -0
  13. package/auth/lib/permission/permission.directive.d.ts +16 -0
  14. package/auth/lib/permission/permission.guard.d.ts +2 -0
  15. package/auth/lib/permission/permission.loader.d.ts +7 -0
  16. package/auth/lib/permission/permission.types.d.ts +1 -0
  17. package/auth/lib/session.service.d.ts +51 -0
  18. package/auth/lib/tenant/tenant.loader.d.ts +9 -0
  19. package/auth/lib/tenant/tenant.types.d.ts +8 -0
  20. package/auth/lib/user/user.types.d.ts +6 -0
  21. package/common/README.md +3 -0
  22. package/common/index.d.ts +11 -0
  23. package/common/lib/common.module.d.ts +21 -0
  24. package/common/lib/configs/app.config.d.ts +19 -0
  25. package/common/lib/data/data-provider.types.d.ts +11 -0
  26. package/common/lib/data/index.d.ts +1 -0
  27. package/common/lib/errors/error-handler-registry.service.d.ts +12 -0
  28. package/common/lib/errors/error-handler.types.d.ts +3 -0
  29. package/common/lib/errors/global-error-handler.d.ts +11 -0
  30. package/common/lib/errors/index.d.ts +3 -0
  31. package/common/lib/layout/component-slot/component-slot-loader.service.d.ts +11 -0
  32. package/common/lib/layout/component-slot/component-slot-registery.service.d.ts +9 -0
  33. package/common/lib/layout/component-slot/component-slot.directive.d.ts +12 -0
  34. package/common/lib/layout/component-slot/component-slot.module.d.ts +15 -0
  35. package/common/lib/layout/component-slot/component-slot.types.d.ts +14 -0
  36. package/common/lib/layout/component-slot/index.d.ts +5 -0
  37. package/common/lib/menu/index.d.ts +2 -0
  38. package/common/lib/menu/menu.loader.d.ts +17 -0
  39. package/common/lib/menu/menu.types.d.ts +13 -0
  40. package/common/lib/settings/index.d.ts +3 -0
  41. package/common/lib/settings/settings.loader.d.ts +8 -0
  42. package/common/lib/settings/settings.service.d.ts +9 -0
  43. package/common/lib/settings/settings.types.d.ts +5 -0
  44. package/common/lib/shared/logo.types.d.ts +19 -0
  45. package/common/lib/shared/state-persistence/index.d.ts +3 -0
  46. package/common/lib/shared/state-persistence/state-persistence.actions.d.ts +1 -0
  47. package/common/lib/shared/state-persistence/state-persistence.module.d.ts +8 -0
  48. package/common/lib/shared/state-persistence/state-persistence.reducers.d.ts +3 -0
  49. package/common/lib/store/common.actions.d.ts +14 -0
  50. package/common/lib/store/common.effects.d.ts +11 -0
  51. package/common/lib/store/index.d.ts +2 -0
  52. package/common/lib/utils/clipboard-service.d.ts +7 -0
  53. package/common/lib/utils/index.d.ts +3 -0
  54. package/common/lib/utils/router-util.service.d.ts +12 -0
  55. package/common/lib/utils/sticky.directive.d.ts +24 -0
  56. package/esm2022/acorex-platform.mjs +5 -0
  57. package/esm2022/auth/acorex-platform-auth.mjs +5 -0
  58. package/esm2022/auth/index.mjs +17 -0
  59. package/esm2022/auth/lib/application/application.loader.mjs +26 -0
  60. package/esm2022/auth/lib/application/application.types.mjs +2 -0
  61. package/esm2022/auth/lib/auth-registry.service.mjs +29 -0
  62. package/esm2022/auth/lib/auth.guard.mjs +18 -0
  63. package/esm2022/auth/lib/auth.module.mjs +84 -0
  64. package/esm2022/auth/lib/auth.strategy.mjs +2 -0
  65. package/esm2022/auth/lib/errors.types.mjs +13 -0
  66. package/esm2022/auth/lib/feature/feature.loader.mjs +14 -0
  67. package/esm2022/auth/lib/feature/feature.types.mjs +2 -0
  68. package/esm2022/auth/lib/permission/permission.directive.mjs +51 -0
  69. package/esm2022/auth/lib/permission/permission.guard.mjs +16 -0
  70. package/esm2022/auth/lib/permission/permission.loader.mjs +14 -0
  71. package/esm2022/auth/lib/permission/permission.types.mjs +2 -0
  72. package/esm2022/auth/lib/session.service.mjs +240 -0
  73. package/esm2022/auth/lib/tenant/tenant.loader.mjs +23 -0
  74. package/esm2022/auth/lib/tenant/tenant.types.mjs +2 -0
  75. package/esm2022/auth/lib/user/user.types.mjs +2 -0
  76. package/esm2022/common/acorex-platform-common.mjs +5 -0
  77. package/esm2022/common/index.mjs +12 -0
  78. package/esm2022/common/lib/common.module.mjs +123 -0
  79. package/esm2022/common/lib/configs/app.config.mjs +27 -0
  80. package/esm2022/common/lib/data/data-provider.types.mjs +3 -0
  81. package/esm2022/common/lib/data/index.mjs +2 -0
  82. package/esm2022/common/lib/errors/error-handler-registry.service.mjs +29 -0
  83. package/esm2022/common/lib/errors/error-handler.types.mjs +2 -0
  84. package/esm2022/common/lib/errors/global-error-handler.mjs +36 -0
  85. package/esm2022/common/lib/errors/index.mjs +4 -0
  86. package/esm2022/common/lib/layout/component-slot/component-slot-loader.service.mjs +56 -0
  87. package/esm2022/common/lib/layout/component-slot/component-slot-registery.service.mjs +28 -0
  88. package/esm2022/common/lib/layout/component-slot/component-slot.directive.mjs +24 -0
  89. package/esm2022/common/lib/layout/component-slot/component-slot.module.mjs +72 -0
  90. package/esm2022/common/lib/layout/component-slot/component-slot.types.mjs +2 -0
  91. package/esm2022/common/lib/layout/component-slot/index.mjs +6 -0
  92. package/esm2022/common/lib/menu/index.mjs +3 -0
  93. package/esm2022/common/lib/menu/menu.loader.mjs +39 -0
  94. package/esm2022/common/lib/menu/menu.types.mjs +2 -0
  95. package/esm2022/common/lib/settings/index.mjs +4 -0
  96. package/esm2022/common/lib/settings/settings.loader.mjs +17 -0
  97. package/esm2022/common/lib/settings/settings.service.mjs +20 -0
  98. package/esm2022/common/lib/settings/settings.types.mjs +2 -0
  99. package/esm2022/common/lib/shared/logo.types.mjs +21 -0
  100. package/esm2022/common/lib/shared/state-persistence/index.mjs +4 -0
  101. package/esm2022/common/lib/shared/state-persistence/state-persistence.actions.mjs +3 -0
  102. package/esm2022/common/lib/shared/state-persistence/state-persistence.module.mjs +36 -0
  103. package/esm2022/common/lib/shared/state-persistence/state-persistence.reducers.mjs +30 -0
  104. package/esm2022/common/lib/store/common.actions.mjs +5 -0
  105. package/esm2022/common/lib/store/common.effects.mjs +31 -0
  106. package/esm2022/common/lib/store/index.mjs +3 -0
  107. package/esm2022/common/lib/utils/clipboard-service.mjs +26 -0
  108. package/esm2022/common/lib/utils/index.mjs +4 -0
  109. package/esm2022/common/lib/utils/router-util.service.mjs +43 -0
  110. package/esm2022/common/lib/utils/sticky.directive.mjs +74 -0
  111. package/esm2022/index.mjs +2 -0
  112. package/esm2022/layouts/acorex-platform-layouts.mjs +5 -0
  113. package/esm2022/layouts/index.mjs +5 -0
  114. package/esm2022/layouts/lib/admin/admin-child-layout/admin-child-features-list.component.mjs +58 -0
  115. package/esm2022/layouts/lib/admin/admin-child-layout/admin-child-layout.component.mjs +50 -0
  116. package/esm2022/layouts/lib/admin/admin-child-layout/admin-child-layout.module.mjs +57 -0
  117. package/esm2022/layouts/lib/admin/admin-child-layout/index.mjs +4 -0
  118. package/esm2022/layouts/lib/admin/admin-root-layout/admin-root-layout.component.mjs +74 -0
  119. package/esm2022/layouts/lib/admin/admin-root-layout/admin-root-layout.module.mjs +92 -0
  120. package/esm2022/layouts/lib/admin/admin-root-layout/components/admin-footer/admin-footer.component.mjs +14 -0
  121. package/esm2022/layouts/lib/admin/admin-root-layout/components/admin-header/admin-header.component.mjs +29 -0
  122. package/esm2022/layouts/lib/admin/admin-root-layout/index.mjs +5 -0
  123. package/esm2022/layouts/lib/admin/admin.module.mjs +75 -0
  124. package/esm2022/layouts/lib/admin/admin.routes.mjs +37 -0
  125. package/esm2022/layouts/lib/admin/custom-reuse.strategy.mjs +20 -0
  126. package/esm2022/layouts/lib/admin/entity-layout/entity-create-view/entity-create-view.component.mjs +105 -0
  127. package/esm2022/layouts/lib/admin/entity-layout/entity-create-view/entity-create-view.config.mjs +137 -0
  128. package/esm2022/layouts/lib/admin/entity-layout/entity-details-view/detail-view.config.mjs +125 -0
  129. package/esm2022/layouts/lib/admin/entity-layout/entity-details-view/entity-details-view.component.mjs +180 -0
  130. package/esm2022/layouts/lib/admin/entity-layout/entity-details-view/index.mjs +3 -0
  131. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/components/entity-custom-view/entity-custom-view.component.mjs +200 -0
  132. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/components/index.mjs +6 -0
  133. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-columns/list-view-option-columns.component.mjs +56 -0
  134. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-conditions/list-view-option-conditions.component.mjs +108 -0
  135. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-conditions/list-view-option-filter-operator.component.mjs +76 -0
  136. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-sorting/list-view-option-sorting.component.mjs +57 -0
  137. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/entity-list-view.component.mjs +283 -0
  138. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/index.mjs +5 -0
  139. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/list-view.config.mjs +333 -0
  140. package/esm2022/layouts/lib/admin/entity-layout/entity-list-view/list-view.module.mjs +156 -0
  141. package/esm2022/layouts/lib/admin/entity-layout/entity-modify-view/entity-modify-view.component.mjs +86 -0
  142. package/esm2022/layouts/lib/admin/entity-layout/entity-modify-view/entity-modify-view.config.mjs +66 -0
  143. package/esm2022/layouts/lib/admin/entity-layout/entity-quick-view/entity-quick-view.component.mjs +82 -0
  144. package/esm2022/layouts/lib/admin/entity-layout/entity-quick-view/index.mjs +2 -0
  145. package/esm2022/layouts/lib/admin/entity-layout/index.mjs +4 -0
  146. package/esm2022/layouts/lib/admin/entity-layout/store/entity.actions.mjs +18 -0
  147. package/esm2022/layouts/lib/admin/entity-layout/store/entity.effects.mjs +76 -0
  148. package/esm2022/layouts/lib/admin/entity-layout/workflows/create-entity.workflow.mjs +91 -0
  149. package/esm2022/layouts/lib/admin/entity-layout/workflows/delete-entity.workflow.mjs +153 -0
  150. package/esm2022/layouts/lib/admin/entity-layout/workflows/modify-entity.workflow.mjs +98 -0
  151. package/esm2022/layouts/lib/admin/entity.resolver.mjs +21 -0
  152. package/esm2022/layouts/lib/admin/index.mjs +8 -0
  153. package/esm2022/layouts/lib/admin/store/admin-layout.actions.mjs +12 -0
  154. package/esm2022/layouts/lib/admin/store/admin-layout.effects.mjs +29 -0
  155. package/esm2022/layouts/lib/admin/store/admin-layout.reducers.mjs +60 -0
  156. package/esm2022/layouts/lib/admin/store/admin-layout.selectors.mjs +8 -0
  157. package/esm2022/layouts/lib/admin/store/admin-layout.state.mjs +16 -0
  158. package/esm2022/layouts/lib/admin/store/index.mjs +6 -0
  159. package/esm2022/layouts/lib/layout.module.mjs +63 -0
  160. package/esm2022/layouts/lib/layout.routes.mjs +15 -0
  161. package/esm2022/layouts/lib/shared/components/content-view/content-view.page.mjs +64 -0
  162. package/esm2022/layouts/lib/shared/components/content-view/content-view.type.mjs +2 -0
  163. package/esm2022/layouts/lib/shared/components/error-401/error-401.component.mjs +29 -0
  164. package/esm2022/layouts/lib/shared/components/error-404/error-404.component.mjs +22 -0
  165. package/esm2022/layouts/lib/shared/components/error-offline/error-offline.component.mjs +16 -0
  166. package/esm2022/layouts/lib/shared/components/index.mjs +9 -0
  167. package/esm2022/layouts/lib/shared/components/logo/logo.component.mjs +38 -0
  168. package/esm2022/layouts/lib/shared/components/slots/footer-text-slot.component.mjs +20 -0
  169. package/esm2022/layouts/lib/shared/components/slots/navbar-slot.component.mjs +36 -0
  170. package/esm2022/layouts/lib/shared/components/slots/theme-slot.component.mjs +48 -0
  171. package/esm2022/layouts/lib/shared/entity/entity-registery.service.mjs +70 -0
  172. package/esm2022/layouts/lib/shared/entity/entity.class.mjs +32 -0
  173. package/esm2022/layouts/lib/shared/entity/entity.loader.mjs +13 -0
  174. package/esm2022/layouts/lib/shared/entity/index.mjs +4 -0
  175. package/esm2022/layouts/lib/shared/index.mjs +5 -0
  176. package/esm2022/layouts/lib/shared/services/index.mjs +2 -0
  177. package/esm2022/layouts/lib/shared/services/layout.service.mjs +79 -0
  178. package/esm2022/layouts/lib/shared/workflows/common.workflow.mjs +110 -0
  179. package/esm2022/layouts/lib/shared/workflows/error-handler.mjs +24 -0
  180. package/esm2022/layouts/lib/shared/workflows/index.mjs +3 -0
  181. package/esm2022/layouts/lib/widgets/avatar/avatar-widget-edit.component.mjs +102 -0
  182. package/esm2022/layouts/lib/widgets/avatar/avatar-widget-view.component.mjs +33 -0
  183. package/esm2022/layouts/lib/widgets/checkbox/checkbox-widget-column.component.mjs +53 -0
  184. package/esm2022/layouts/lib/widgets/checkbox/checkbox-widget-edit.component.mjs +22 -0
  185. package/esm2022/layouts/lib/widgets/checkbox/checkbox-widget-view.component.mjs +47 -0
  186. package/esm2022/layouts/lib/widgets/common-widget-filter/boolean-widget-filter.component.mjs +147 -0
  187. package/esm2022/layouts/lib/widgets/common-widget-filter/number-widget-filter.component.mjs +135 -0
  188. package/esm2022/layouts/lib/widgets/common-widget-filter/string-widget-filter.component.mjs +125 -0
  189. package/esm2022/layouts/lib/widgets/common-widgets.module.mjs +479 -0
  190. package/esm2022/layouts/lib/widgets/dateTime/dateTime-widget-column.component.mjs +44 -0
  191. package/esm2022/layouts/lib/widgets/dateTime/dateTime-widget-edit.component.mjs +175 -0
  192. package/esm2022/layouts/lib/widgets/dateTime/dateTime-widget-filter.component.mjs +230 -0
  193. package/esm2022/layouts/lib/widgets/dateTime/dateTime-widget-view.component.mjs +71 -0
  194. package/esm2022/layouts/lib/widgets/email/email-widget-column.component.mjs +73 -0
  195. package/esm2022/layouts/lib/widgets/email/email-widget-edit.component.mjs +249 -0
  196. package/esm2022/layouts/lib/widgets/email/email-widget-view.component.mjs +108 -0
  197. package/esm2022/layouts/lib/widgets/file/file-widget-column.component.mjs +27 -0
  198. package/esm2022/layouts/lib/widgets/file/file-widget-edit.component.mjs +200 -0
  199. package/esm2022/layouts/lib/widgets/file/file-widget-filter.component.mjs +27 -0
  200. package/esm2022/layouts/lib/widgets/file/file-widget-view.component.mjs +153 -0
  201. package/esm2022/layouts/lib/widgets/gallery/gallery-widget-edit.component.mjs +189 -0
  202. package/esm2022/layouts/lib/widgets/gallery/gallery-widget-filter.component.mjs +27 -0
  203. package/esm2022/layouts/lib/widgets/gallery/gallery-widget-types.mjs +2 -0
  204. package/esm2022/layouts/lib/widgets/gallery/gallery-widget-view.component.mjs +173 -0
  205. package/esm2022/layouts/lib/widgets/index.mjs +2 -0
  206. package/esm2022/layouts/lib/widgets/lookup/lookup-widget-column.component.mjs +43 -0
  207. package/esm2022/layouts/lib/widgets/lookup/lookup-widget-edit.component.mjs +74 -0
  208. package/esm2022/layouts/lib/widgets/lookup/lookup-widget-filter.component.mjs +139 -0
  209. package/esm2022/layouts/lib/widgets/lookup/lookup-widget-view.component.mjs +54 -0
  210. package/esm2022/layouts/lib/widgets/map/map-widget-edit.component.mjs +91 -0
  211. package/esm2022/layouts/lib/widgets/map/map-widget-view.component.mjs +63 -0
  212. package/esm2022/layouts/lib/widgets/messenger/messenger-widget-column.component.mjs +71 -0
  213. package/esm2022/layouts/lib/widgets/messenger/messenger-widget-edit.component.mjs +136 -0
  214. package/esm2022/layouts/lib/widgets/messenger/messenger-widget-view.component.mjs +132 -0
  215. package/esm2022/layouts/lib/widgets/number/number-widget-edit.component.mjs +46 -0
  216. package/esm2022/layouts/lib/widgets/number/number-widget-view.component.mjs +30 -0
  217. package/esm2022/layouts/lib/widgets/password/change-password.component.mjs +175 -0
  218. package/esm2022/layouts/lib/widgets/password/password-widget-column.component.mjs +77 -0
  219. package/esm2022/layouts/lib/widgets/password/password-widget-edit.component.mjs +34 -0
  220. package/esm2022/layouts/lib/widgets/password/password-widget-view.component.mjs +109 -0
  221. package/esm2022/layouts/lib/widgets/phone/phone-widget-column.component.mjs +91 -0
  222. package/esm2022/layouts/lib/widgets/phone/phone-widget-edit.component.mjs +315 -0
  223. package/esm2022/layouts/lib/widgets/phone/phone-widget-view.component.mjs +123 -0
  224. package/esm2022/layouts/lib/widgets/rich-text/rich-text-widget-column.component.mjs +69 -0
  225. package/esm2022/layouts/lib/widgets/rich-text/rich-text-widget-edit.component.mjs +67 -0
  226. package/esm2022/layouts/lib/widgets/rich-text/rich-text-widget-view.component.mjs +34 -0
  227. package/esm2022/layouts/lib/widgets/selection-list/selection-list-widget-column.component.mjs +43 -0
  228. package/esm2022/layouts/lib/widgets/selection-list/selection-list-widget-edit.component.mjs +53 -0
  229. package/esm2022/layouts/lib/widgets/selection-list/selection-list-widget-filter.component.mjs +41 -0
  230. package/esm2022/layouts/lib/widgets/selection-list/selection-list-widget-view.component.mjs +45 -0
  231. package/esm2022/layouts/lib/widgets/signature-pad/signature-pad-widget-edit.component.mjs +128 -0
  232. package/esm2022/layouts/lib/widgets/signature-pad/signature-pad-widget-view.component.mjs +41 -0
  233. package/esm2022/layouts/lib/widgets/text/largetext-widget-edit.component.mjs +37 -0
  234. package/esm2022/layouts/lib/widgets/text/text-widget-column.component.mjs +47 -0
  235. package/esm2022/layouts/lib/widgets/text/text-widget-edit.component.mjs +162 -0
  236. package/esm2022/layouts/lib/widgets/text/text-widget-view.component.mjs +66 -0
  237. package/esm2022/layouts/lib/widgets/toggle/toggle-widget-column.component.mjs +57 -0
  238. package/esm2022/layouts/lib/widgets/toggle/toggle-widget-edit.component.mjs +25 -0
  239. package/esm2022/layouts/lib/widgets/toggle/toggle-widget-view.component.mjs +49 -0
  240. package/esm2022/mocks/acorex-platform-mocks.mjs +5 -0
  241. package/esm2022/mocks/index.mjs +7 -0
  242. package/esm2022/mocks/lib/mocks.module.mjs +15 -0
  243. package/esm2022/mocks/lib/services/mocker.service.mjs +124 -0
  244. package/esm2022/mocks/lib/storage/storage.mock.service.mjs +186 -0
  245. package/esm2022/native/acorex-platform-native.mjs +5 -0
  246. package/esm2022/native/index.mjs +3 -0
  247. package/esm2022/native/lib/native.module.mjs +16 -0
  248. package/esm2022/native/lib/native.service.mjs +133 -0
  249. package/esm2022/schema/acorex-platform-schema.mjs +5 -0
  250. package/esm2022/schema/index.mjs +14 -0
  251. package/esm2022/schema/lib/component-loader.mjs +2 -0
  252. package/esm2022/schema/lib/formats.mjs +2 -0
  253. package/esm2022/schema/lib/operators.mjs +50 -0
  254. package/esm2022/schema/lib/schema-registery.service.mjs +33 -0
  255. package/esm2022/schema/lib/schema.mjs +2 -0
  256. package/esm2022/schema/lib/schema.module.mjs +23 -0
  257. package/esm2022/schema/lib/widget/widget-base.mjs +110 -0
  258. package/esm2022/schema/lib/widget/widget-column-renderer.mjs +99 -0
  259. package/esm2022/schema/lib/widget/widget-filter-renderer.mjs +133 -0
  260. package/esm2022/schema/lib/widget/widget-renderer.mjs +144 -0
  261. package/esm2022/schema/lib/widget/widget-token.mjs +3 -0
  262. package/esm2022/workflow/acorex-platform-workflow.mjs +5 -0
  263. package/esm2022/workflow/index.mjs +7 -0
  264. package/esm2022/workflow/lib/errors.types.mjs +8 -0
  265. package/esm2022/workflow/lib/workflow-event-dispatcher.service.mjs +23 -0
  266. package/esm2022/workflow/lib/workflow-registery.service.mjs +39 -0
  267. package/esm2022/workflow/lib/workflow.module.mjs +96 -0
  268. package/esm2022/workflow/lib/workflow.service.mjs +141 -0
  269. package/esm2022/workflow/lib/workflow.types.mjs +52 -0
  270. package/fesm2022/acorex-platform-auth.mjs +502 -0
  271. package/fesm2022/acorex-platform-auth.mjs.map +1 -0
  272. package/fesm2022/acorex-platform-common.mjs +699 -0
  273. package/fesm2022/acorex-platform-common.mjs.map +1 -0
  274. package/fesm2022/acorex-platform-layouts-avatar-widget-edit.component-PZr1lXj-.mjs +104 -0
  275. package/fesm2022/acorex-platform-layouts-avatar-widget-edit.component-PZr1lXj-.mjs.map +1 -0
  276. package/fesm2022/acorex-platform-layouts-avatar-widget-view.component-pJJYkvdH.mjs +36 -0
  277. package/fesm2022/acorex-platform-layouts-avatar-widget-view.component-pJJYkvdH.mjs.map +1 -0
  278. package/fesm2022/acorex-platform-layouts-boolean-widget-filter.component-H056Q5Gz.mjs +150 -0
  279. package/fesm2022/acorex-platform-layouts-boolean-widget-filter.component-H056Q5Gz.mjs.map +1 -0
  280. package/fesm2022/acorex-platform-layouts-change-password.component-QMAm6dxN.mjs +178 -0
  281. package/fesm2022/acorex-platform-layouts-change-password.component-QMAm6dxN.mjs.map +1 -0
  282. package/fesm2022/acorex-platform-layouts-checkbox-widget-column.component-vRJI5S-w.mjs +56 -0
  283. package/fesm2022/acorex-platform-layouts-checkbox-widget-column.component-vRJI5S-w.mjs.map +1 -0
  284. package/fesm2022/acorex-platform-layouts-checkbox-widget-edit.component-P4cD_Nwg.mjs +25 -0
  285. package/fesm2022/acorex-platform-layouts-checkbox-widget-edit.component-P4cD_Nwg.mjs.map +1 -0
  286. package/fesm2022/acorex-platform-layouts-checkbox-widget-view.component-m6bF8XFR.mjs +50 -0
  287. package/fesm2022/acorex-platform-layouts-checkbox-widget-view.component-m6bF8XFR.mjs.map +1 -0
  288. package/fesm2022/acorex-platform-layouts-dateTime-widget-column.component-qeQRJePy.mjs +47 -0
  289. package/fesm2022/acorex-platform-layouts-dateTime-widget-column.component-qeQRJePy.mjs.map +1 -0
  290. package/fesm2022/acorex-platform-layouts-dateTime-widget-edit.component-zeJXGXY8.mjs +178 -0
  291. package/fesm2022/acorex-platform-layouts-dateTime-widget-edit.component-zeJXGXY8.mjs.map +1 -0
  292. package/fesm2022/acorex-platform-layouts-dateTime-widget-filter.component-DJ6esclU.mjs +233 -0
  293. package/fesm2022/acorex-platform-layouts-dateTime-widget-filter.component-DJ6esclU.mjs.map +1 -0
  294. package/fesm2022/acorex-platform-layouts-dateTime-widget-view.component-BrwycTWz.mjs +74 -0
  295. package/fesm2022/acorex-platform-layouts-dateTime-widget-view.component-BrwycTWz.mjs.map +1 -0
  296. package/fesm2022/acorex-platform-layouts-email-widget-column.component-ac8gqsFT.mjs +76 -0
  297. package/fesm2022/acorex-platform-layouts-email-widget-column.component-ac8gqsFT.mjs.map +1 -0
  298. package/fesm2022/acorex-platform-layouts-email-widget-edit.component-m2dI7y9X.mjs +252 -0
  299. package/fesm2022/acorex-platform-layouts-email-widget-edit.component-m2dI7y9X.mjs.map +1 -0
  300. package/fesm2022/acorex-platform-layouts-email-widget-view.component-XrV8va7z.mjs +111 -0
  301. package/fesm2022/acorex-platform-layouts-email-widget-view.component-XrV8va7z.mjs.map +1 -0
  302. package/fesm2022/acorex-platform-layouts-entity-create-view.component-8rtifIvM.mjs +108 -0
  303. package/fesm2022/acorex-platform-layouts-entity-create-view.component-8rtifIvM.mjs.map +1 -0
  304. package/fesm2022/acorex-platform-layouts-entity-modify-view.component-VeTkP3-n.mjs +89 -0
  305. package/fesm2022/acorex-platform-layouts-entity-modify-view.component-VeTkP3-n.mjs.map +1 -0
  306. package/fesm2022/acorex-platform-layouts-file-widget-column.component-v7kAdIQ9.mjs +30 -0
  307. package/fesm2022/acorex-platform-layouts-file-widget-column.component-v7kAdIQ9.mjs.map +1 -0
  308. package/fesm2022/acorex-platform-layouts-file-widget-edit.component-Wrq7ZL9R.mjs +203 -0
  309. package/fesm2022/acorex-platform-layouts-file-widget-edit.component-Wrq7ZL9R.mjs.map +1 -0
  310. package/fesm2022/acorex-platform-layouts-file-widget-filter.component-1-NJh38j.mjs +30 -0
  311. package/fesm2022/acorex-platform-layouts-file-widget-filter.component-1-NJh38j.mjs.map +1 -0
  312. package/fesm2022/acorex-platform-layouts-file-widget-view.component-mXBrKX0K.mjs +156 -0
  313. package/fesm2022/acorex-platform-layouts-file-widget-view.component-mXBrKX0K.mjs.map +1 -0
  314. package/fesm2022/acorex-platform-layouts-gallery-widget-edit.component-cWNvVwum.mjs +192 -0
  315. package/fesm2022/acorex-platform-layouts-gallery-widget-edit.component-cWNvVwum.mjs.map +1 -0
  316. package/fesm2022/acorex-platform-layouts-gallery-widget-filter.component-OCz0hj5i.mjs +30 -0
  317. package/fesm2022/acorex-platform-layouts-gallery-widget-filter.component-OCz0hj5i.mjs.map +1 -0
  318. package/fesm2022/acorex-platform-layouts-gallery-widget-view.component-xU52uaP0.mjs +176 -0
  319. package/fesm2022/acorex-platform-layouts-gallery-widget-view.component-xU52uaP0.mjs.map +1 -0
  320. package/fesm2022/acorex-platform-layouts-largetext-widget-edit.component-Um_eBRFi.mjs +40 -0
  321. package/fesm2022/acorex-platform-layouts-largetext-widget-edit.component-Um_eBRFi.mjs.map +1 -0
  322. package/fesm2022/acorex-platform-layouts-lookup-widget-column.component-Ts0MJe8O.mjs +46 -0
  323. package/fesm2022/acorex-platform-layouts-lookup-widget-column.component-Ts0MJe8O.mjs.map +1 -0
  324. package/fesm2022/acorex-platform-layouts-lookup-widget-edit.component-l5nSr9Cm.mjs +119 -0
  325. package/fesm2022/acorex-platform-layouts-lookup-widget-edit.component-l5nSr9Cm.mjs.map +1 -0
  326. package/fesm2022/acorex-platform-layouts-lookup-widget-filter.component-gp5skvmz.mjs +181 -0
  327. package/fesm2022/acorex-platform-layouts-lookup-widget-filter.component-gp5skvmz.mjs.map +1 -0
  328. package/fesm2022/acorex-platform-layouts-lookup-widget-view.component-ftFXFj6k.mjs +57 -0
  329. package/fesm2022/acorex-platform-layouts-lookup-widget-view.component-ftFXFj6k.mjs.map +1 -0
  330. package/fesm2022/acorex-platform-layouts-map-widget-edit.component-SOQvPhmX.mjs +94 -0
  331. package/fesm2022/acorex-platform-layouts-map-widget-edit.component-SOQvPhmX.mjs.map +1 -0
  332. package/fesm2022/acorex-platform-layouts-map-widget-view.component-1Lj9efbd.mjs +66 -0
  333. package/fesm2022/acorex-platform-layouts-map-widget-view.component-1Lj9efbd.mjs.map +1 -0
  334. package/fesm2022/acorex-platform-layouts-messenger-widget-column.component-W7ZY-W84.mjs +74 -0
  335. package/fesm2022/acorex-platform-layouts-messenger-widget-column.component-W7ZY-W84.mjs.map +1 -0
  336. package/fesm2022/acorex-platform-layouts-messenger-widget-edit.component-dAX8nirB.mjs +139 -0
  337. package/fesm2022/acorex-platform-layouts-messenger-widget-edit.component-dAX8nirB.mjs.map +1 -0
  338. package/fesm2022/acorex-platform-layouts-messenger-widget-view.component-9TJiFdq-.mjs +135 -0
  339. package/fesm2022/acorex-platform-layouts-messenger-widget-view.component-9TJiFdq-.mjs.map +1 -0
  340. package/fesm2022/acorex-platform-layouts-number-widget-edit.component-DDi-o_Zn.mjs +49 -0
  341. package/fesm2022/acorex-platform-layouts-number-widget-edit.component-DDi-o_Zn.mjs.map +1 -0
  342. package/fesm2022/acorex-platform-layouts-number-widget-filter.component-DPGSzdNm.mjs +138 -0
  343. package/fesm2022/acorex-platform-layouts-number-widget-filter.component-DPGSzdNm.mjs.map +1 -0
  344. package/fesm2022/acorex-platform-layouts-number-widget-view.component-hqkAR0LG.mjs +33 -0
  345. package/fesm2022/acorex-platform-layouts-number-widget-view.component-hqkAR0LG.mjs.map +1 -0
  346. package/fesm2022/acorex-platform-layouts-password-widget-column.component-ic1jykZL.mjs +80 -0
  347. package/fesm2022/acorex-platform-layouts-password-widget-column.component-ic1jykZL.mjs.map +1 -0
  348. package/fesm2022/acorex-platform-layouts-password-widget-edit.component-D8xI17yk.mjs +37 -0
  349. package/fesm2022/acorex-platform-layouts-password-widget-edit.component-D8xI17yk.mjs.map +1 -0
  350. package/fesm2022/acorex-platform-layouts-password-widget-view.component-E2vtPKRO.mjs +112 -0
  351. package/fesm2022/acorex-platform-layouts-password-widget-view.component-E2vtPKRO.mjs.map +1 -0
  352. package/fesm2022/acorex-platform-layouts-phone-widget-column.component-s04WZfzv.mjs +94 -0
  353. package/fesm2022/acorex-platform-layouts-phone-widget-column.component-s04WZfzv.mjs.map +1 -0
  354. package/fesm2022/acorex-platform-layouts-phone-widget-edit.component-MKzlZ0_B.mjs +318 -0
  355. package/fesm2022/acorex-platform-layouts-phone-widget-edit.component-MKzlZ0_B.mjs.map +1 -0
  356. package/fesm2022/acorex-platform-layouts-phone-widget-view.component-NEO22XO7.mjs +126 -0
  357. package/fesm2022/acorex-platform-layouts-phone-widget-view.component-NEO22XO7.mjs.map +1 -0
  358. package/fesm2022/acorex-platform-layouts-rich-text-widget-column.component-P0YzXTIB.mjs +72 -0
  359. package/fesm2022/acorex-platform-layouts-rich-text-widget-column.component-P0YzXTIB.mjs.map +1 -0
  360. package/fesm2022/acorex-platform-layouts-rich-text-widget-edit.component-ro2yg7PR.mjs +70 -0
  361. package/fesm2022/acorex-platform-layouts-rich-text-widget-edit.component-ro2yg7PR.mjs.map +1 -0
  362. package/fesm2022/acorex-platform-layouts-rich-text-widget-view.component--Rzxm2a6.mjs +37 -0
  363. package/fesm2022/acorex-platform-layouts-rich-text-widget-view.component--Rzxm2a6.mjs.map +1 -0
  364. package/fesm2022/acorex-platform-layouts-selection-list-widget-column.component-9FTkDGmq.mjs +46 -0
  365. package/fesm2022/acorex-platform-layouts-selection-list-widget-column.component-9FTkDGmq.mjs.map +1 -0
  366. package/fesm2022/acorex-platform-layouts-selection-list-widget-edit.component-FpOQ12Ie.mjs +56 -0
  367. package/fesm2022/acorex-platform-layouts-selection-list-widget-edit.component-FpOQ12Ie.mjs.map +1 -0
  368. package/fesm2022/acorex-platform-layouts-selection-list-widget-filter.component-hGk-ZZ78.mjs +44 -0
  369. package/fesm2022/acorex-platform-layouts-selection-list-widget-filter.component-hGk-ZZ78.mjs.map +1 -0
  370. package/fesm2022/acorex-platform-layouts-selection-list-widget-view.component-s9xq___Y.mjs +48 -0
  371. package/fesm2022/acorex-platform-layouts-selection-list-widget-view.component-s9xq___Y.mjs.map +1 -0
  372. package/fesm2022/acorex-platform-layouts-signature-pad-widget-edit.component-W28Uk9zO.mjs +131 -0
  373. package/fesm2022/acorex-platform-layouts-signature-pad-widget-edit.component-W28Uk9zO.mjs.map +1 -0
  374. package/fesm2022/acorex-platform-layouts-signature-pad-widget-view.component-R40Ml757.mjs +44 -0
  375. package/fesm2022/acorex-platform-layouts-signature-pad-widget-view.component-R40Ml757.mjs.map +1 -0
  376. package/fesm2022/acorex-platform-layouts-string-widget-filter.component-4oZ6BVis.mjs +128 -0
  377. package/fesm2022/acorex-platform-layouts-string-widget-filter.component-4oZ6BVis.mjs.map +1 -0
  378. package/fesm2022/acorex-platform-layouts-text-widget-column.component-qhh6MT79.mjs +50 -0
  379. package/fesm2022/acorex-platform-layouts-text-widget-column.component-qhh6MT79.mjs.map +1 -0
  380. package/fesm2022/acorex-platform-layouts-text-widget-edit.component-TC127Dq8.mjs +165 -0
  381. package/fesm2022/acorex-platform-layouts-text-widget-edit.component-TC127Dq8.mjs.map +1 -0
  382. package/fesm2022/acorex-platform-layouts-text-widget-view.component-65eOj0qR.mjs +69 -0
  383. package/fesm2022/acorex-platform-layouts-text-widget-view.component-65eOj0qR.mjs.map +1 -0
  384. package/fesm2022/acorex-platform-layouts-toggle-widget-column.component-uxOXR-bL.mjs +60 -0
  385. package/fesm2022/acorex-platform-layouts-toggle-widget-column.component-uxOXR-bL.mjs.map +1 -0
  386. package/fesm2022/acorex-platform-layouts-toggle-widget-edit.component-R44L1pgJ.mjs +28 -0
  387. package/fesm2022/acorex-platform-layouts-toggle-widget-edit.component-R44L1pgJ.mjs.map +1 -0
  388. package/fesm2022/acorex-platform-layouts-toggle-widget-view.component-DTOeAUiy.mjs +52 -0
  389. package/fesm2022/acorex-platform-layouts-toggle-widget-view.component-DTOeAUiy.mjs.map +1 -0
  390. package/fesm2022/acorex-platform-layouts.mjs +3732 -0
  391. package/fesm2022/acorex-platform-layouts.mjs.map +1 -0
  392. package/fesm2022/acorex-platform-mocks.mjs +332 -0
  393. package/fesm2022/acorex-platform-mocks.mjs.map +1 -0
  394. package/fesm2022/acorex-platform-native.mjs +154 -0
  395. package/fesm2022/acorex-platform-native.mjs.map +1 -0
  396. package/fesm2022/acorex-platform-schema.mjs +572 -0
  397. package/fesm2022/acorex-platform-schema.mjs.map +1 -0
  398. package/fesm2022/acorex-platform-workflow.mjs +350 -0
  399. package/fesm2022/acorex-platform-workflow.mjs.map +1 -0
  400. package/fesm2022/acorex-platform.mjs +6 -0
  401. package/fesm2022/acorex-platform.mjs.map +1 -0
  402. package/index.d.ts +2 -0
  403. package/layouts/README.md +3 -0
  404. package/layouts/index.d.ts +4 -0
  405. package/layouts/lib/admin/admin-child-layout/admin-child-features-list.component.d.ts +22 -0
  406. package/layouts/lib/admin/admin-child-layout/admin-child-layout.component.d.ts +21 -0
  407. package/layouts/lib/admin/admin-child-layout/admin-child-layout.module.d.ts +17 -0
  408. package/layouts/lib/admin/admin-child-layout/index.d.ts +3 -0
  409. package/layouts/lib/admin/admin-root-layout/admin-root-layout.component.d.ts +30 -0
  410. package/layouts/lib/admin/admin-root-layout/admin-root-layout.module.d.ts +25 -0
  411. package/layouts/lib/admin/admin-root-layout/components/admin-footer/admin-footer.component.d.ts +5 -0
  412. package/layouts/lib/admin/admin-root-layout/components/admin-header/admin-header.component.d.ts +10 -0
  413. package/layouts/lib/admin/admin-root-layout/index.d.ts +4 -0
  414. package/layouts/lib/admin/admin.module.d.ts +11 -0
  415. package/layouts/lib/admin/admin.routes.d.ts +2 -0
  416. package/layouts/lib/admin/custom-reuse.strategy.d.ts +8 -0
  417. package/layouts/lib/admin/entity-layout/entity-create-view/entity-create-view.component.d.ts +20 -0
  418. package/layouts/lib/admin/entity-layout/entity-create-view/entity-create-view.config.d.ts +54 -0
  419. package/layouts/lib/admin/entity-layout/entity-details-view/detail-view.config.d.ts +48 -0
  420. package/layouts/lib/admin/entity-layout/entity-details-view/entity-details-view.component.d.ts +41 -0
  421. package/layouts/lib/admin/entity-layout/entity-details-view/index.d.ts +2 -0
  422. package/layouts/lib/admin/entity-layout/entity-list-view/components/entity-custom-view/entity-custom-view.component.d.ts +47 -0
  423. package/layouts/lib/admin/entity-layout/entity-list-view/components/index.d.ts +5 -0
  424. package/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-columns/list-view-option-columns.component.d.ts +22 -0
  425. package/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-conditions/list-view-option-conditions.component.d.ts +35 -0
  426. package/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-conditions/list-view-option-filter-operator.component.d.ts +18 -0
  427. package/layouts/lib/admin/entity-layout/entity-list-view/components/list-view-option-sorting/list-view-option-sorting.component.d.ts +22 -0
  428. package/layouts/lib/admin/entity-layout/entity-list-view/entity-list-view.component.d.ts +63 -0
  429. package/layouts/lib/admin/entity-layout/entity-list-view/index.d.ts +4 -0
  430. package/layouts/lib/admin/entity-layout/entity-list-view/list-view.config.d.ts +110 -0
  431. package/layouts/lib/admin/entity-layout/entity-list-view/list-view.module.d.ts +41 -0
  432. package/layouts/lib/admin/entity-layout/entity-modify-view/entity-modify-view.component.d.ts +25 -0
  433. package/layouts/lib/admin/entity-layout/entity-modify-view/entity-modify-view.config.d.ts +31 -0
  434. package/layouts/lib/admin/entity-layout/entity-quick-view/entity-quick-view.component.d.ts +22 -0
  435. package/layouts/lib/admin/entity-layout/entity-quick-view/index.d.ts +1 -0
  436. package/layouts/lib/admin/entity-layout/index.d.ts +3 -0
  437. package/layouts/lib/admin/entity-layout/store/entity.actions.d.ts +48 -0
  438. package/layouts/lib/admin/entity-layout/store/entity.effects.d.ts +22 -0
  439. package/layouts/lib/admin/entity-layout/workflows/create-entity.workflow.d.ts +28 -0
  440. package/layouts/lib/admin/entity-layout/workflows/delete-entity.workflow.d.ts +33 -0
  441. package/layouts/lib/admin/entity-layout/workflows/modify-entity.workflow.d.ts +31 -0
  442. package/layouts/lib/admin/entity.resolver.d.ts +4 -0
  443. package/layouts/lib/admin/index.d.ts +7 -0
  444. package/layouts/lib/admin/store/admin-layout.actions.d.ts +8 -0
  445. package/layouts/lib/admin/store/admin-layout.effects.d.ts +10 -0
  446. package/layouts/lib/admin/store/admin-layout.reducers.d.ts +24 -0
  447. package/layouts/lib/admin/store/admin-layout.selectors.d.ts +5 -0
  448. package/layouts/lib/admin/store/admin-layout.state.d.ts +14 -0
  449. package/layouts/lib/admin/store/index.d.ts +5 -0
  450. package/layouts/lib/layout.module.d.ts +9 -0
  451. package/layouts/lib/layout.routes.d.ts +2 -0
  452. package/layouts/lib/shared/components/content-view/content-view.page.d.ts +23 -0
  453. package/layouts/lib/shared/components/content-view/content-view.type.d.ts +16 -0
  454. package/layouts/lib/shared/components/error-401/error-401.component.d.ts +13 -0
  455. package/layouts/lib/shared/components/error-404/error-404.component.d.ts +8 -0
  456. package/layouts/lib/shared/components/error-offline/error-offline.component.d.ts +9 -0
  457. package/layouts/lib/shared/components/index.d.ts +8 -0
  458. package/layouts/lib/shared/components/logo/logo.component.d.ts +8 -0
  459. package/layouts/lib/shared/components/slots/footer-text-slot.component.d.ts +6 -0
  460. package/layouts/lib/shared/components/slots/navbar-slot.component.d.ts +10 -0
  461. package/layouts/lib/shared/components/slots/theme-slot.component.d.ts +8 -0
  462. package/layouts/lib/shared/entity/entity-registery.service.d.ts +34 -0
  463. package/layouts/lib/shared/entity/entity.class.d.ts +145 -0
  464. package/layouts/lib/shared/entity/entity.loader.d.ts +9 -0
  465. package/layouts/lib/shared/entity/index.d.ts +3 -0
  466. package/layouts/lib/shared/index.d.ts +4 -0
  467. package/layouts/lib/shared/services/index.d.ts +1 -0
  468. package/layouts/lib/shared/services/layout.service.d.ts +19 -0
  469. package/layouts/lib/shared/workflows/common.workflow.d.ts +52 -0
  470. package/layouts/lib/shared/workflows/error-handler.d.ts +8 -0
  471. package/layouts/lib/shared/workflows/index.d.ts +2 -0
  472. package/layouts/lib/widgets/avatar/avatar-widget-edit.component.d.ts +10 -0
  473. package/layouts/lib/widgets/avatar/avatar-widget-view.component.d.ts +8 -0
  474. package/layouts/lib/widgets/checkbox/checkbox-widget-column.component.d.ts +11 -0
  475. package/layouts/lib/widgets/checkbox/checkbox-widget-edit.component.d.ts +6 -0
  476. package/layouts/lib/widgets/checkbox/checkbox-widget-view.component.d.ts +11 -0
  477. package/layouts/lib/widgets/common-widget-filter/boolean-widget-filter.component.d.ts +17 -0
  478. package/layouts/lib/widgets/common-widget-filter/number-widget-filter.component.d.ts +11 -0
  479. package/layouts/lib/widgets/common-widget-filter/string-widget-filter.component.d.ts +11 -0
  480. package/layouts/lib/widgets/common-widgets.module.d.ts +32 -0
  481. package/layouts/lib/widgets/dateTime/dateTime-widget-column.component.d.ts +11 -0
  482. package/layouts/lib/widgets/dateTime/dateTime-widget-edit.component.d.ts +24 -0
  483. package/layouts/lib/widgets/dateTime/dateTime-widget-filter.component.d.ts +16 -0
  484. package/layouts/lib/widgets/dateTime/dateTime-widget-view.component.d.ts +11 -0
  485. package/layouts/lib/widgets/email/email-widget-column.component.d.ts +16 -0
  486. package/layouts/lib/widgets/email/email-widget-edit.component.d.ts +28 -0
  487. package/layouts/lib/widgets/email/email-widget-view.component.d.ts +16 -0
  488. package/layouts/lib/widgets/file/file-widget-column.component.d.ts +8 -0
  489. package/layouts/lib/widgets/file/file-widget-edit.component.d.ts +17 -0
  490. package/layouts/lib/widgets/file/file-widget-filter.component.d.ts +6 -0
  491. package/layouts/lib/widgets/file/file-widget-view.component.d.ts +17 -0
  492. package/layouts/lib/widgets/gallery/gallery-widget-edit.component.d.ts +15 -0
  493. package/layouts/lib/widgets/gallery/gallery-widget-filter.component.d.ts +6 -0
  494. package/layouts/lib/widgets/gallery/gallery-widget-types.d.ts +10 -0
  495. package/layouts/lib/widgets/gallery/gallery-widget-view.component.d.ts +16 -0
  496. package/layouts/lib/widgets/index.d.ts +1 -0
  497. package/layouts/lib/widgets/lookup/lookup-widget-column.component.d.ts +16 -0
  498. package/layouts/lib/widgets/lookup/lookup-widget-edit.component.d.ts +15 -0
  499. package/layouts/lib/widgets/lookup/lookup-widget-filter.component.d.ts +16 -0
  500. package/layouts/lib/widgets/lookup/lookup-widget-view.component.d.ts +17 -0
  501. package/layouts/lib/widgets/map/map-widget-edit.component.d.ts +15 -0
  502. package/layouts/lib/widgets/map/map-widget-view.component.d.ts +17 -0
  503. package/layouts/lib/widgets/messenger/messenger-widget-column.component.d.ts +15 -0
  504. package/layouts/lib/widgets/messenger/messenger-widget-edit.component.d.ts +14 -0
  505. package/layouts/lib/widgets/messenger/messenger-widget-view.component.d.ts +17 -0
  506. package/layouts/lib/widgets/number/number-widget-edit.component.d.ts +7 -0
  507. package/layouts/lib/widgets/number/number-widget-view.component.d.ts +8 -0
  508. package/layouts/lib/widgets/password/change-password.component.d.ts +16 -0
  509. package/layouts/lib/widgets/password/password-widget-column.component.d.ts +14 -0
  510. package/layouts/lib/widgets/password/password-widget-edit.component.d.ts +6 -0
  511. package/layouts/lib/widgets/password/password-widget-view.component.d.ts +18 -0
  512. package/layouts/lib/widgets/phone/phone-widget-column.component.d.ts +15 -0
  513. package/layouts/lib/widgets/phone/phone-widget-edit.component.d.ts +29 -0
  514. package/layouts/lib/widgets/phone/phone-widget-view.component.d.ts +18 -0
  515. package/layouts/lib/widgets/rich-text/rich-text-widget-column.component.d.ts +11 -0
  516. package/layouts/lib/widgets/rich-text/rich-text-widget-edit.component.d.ts +33 -0
  517. package/layouts/lib/widgets/rich-text/rich-text-widget-view.component.d.ts +10 -0
  518. package/layouts/lib/widgets/selection-list/selection-list-widget-column.component.d.ts +16 -0
  519. package/layouts/lib/widgets/selection-list/selection-list-widget-edit.component.d.ts +10 -0
  520. package/layouts/lib/widgets/selection-list/selection-list-widget-filter.component.d.ts +9 -0
  521. package/layouts/lib/widgets/selection-list/selection-list-widget-view.component.d.ts +15 -0
  522. package/layouts/lib/widgets/signature-pad/signature-pad-widget-edit.component.d.ts +19 -0
  523. package/layouts/lib/widgets/signature-pad/signature-pad-widget-view.component.d.ts +8 -0
  524. package/layouts/lib/widgets/text/largetext-widget-edit.component.d.ts +6 -0
  525. package/layouts/lib/widgets/text/text-widget-column.component.d.ts +11 -0
  526. package/layouts/lib/widgets/text/text-widget-edit.component.d.ts +23 -0
  527. package/layouts/lib/widgets/text/text-widget-view.component.d.ts +11 -0
  528. package/layouts/lib/widgets/toggle/toggle-widget-column.component.d.ts +11 -0
  529. package/layouts/lib/widgets/toggle/toggle-widget-edit.component.d.ts +6 -0
  530. package/layouts/lib/widgets/toggle/toggle-widget-view.component.d.ts +11 -0
  531. package/mocks/README.md +3 -0
  532. package/mocks/index.d.ts +3 -0
  533. package/mocks/lib/mocks.module.d.ts +7 -0
  534. package/mocks/lib/services/mocker.service.d.ts +29 -0
  535. package/mocks/lib/storage/storage.mock.service.d.ts +25 -0
  536. package/native/README.md +4 -0
  537. package/native/index.d.ts +2 -0
  538. package/native/lib/native.module.d.ts +6 -0
  539. package/native/lib/native.service.d.ts +26 -0
  540. package/package.json +67 -0
  541. package/schema/README.md +3 -0
  542. package/schema/index.d.ts +11 -0
  543. package/schema/lib/component-loader.d.ts +24 -0
  544. package/schema/lib/formats.d.ts +8 -0
  545. package/schema/lib/operators.d.ts +22 -0
  546. package/schema/lib/schema-registery.service.d.ts +20 -0
  547. package/schema/lib/schema.d.ts +21 -0
  548. package/schema/lib/schema.module.d.ts +12 -0
  549. package/schema/lib/widget/widget-base.d.ts +43 -0
  550. package/schema/lib/widget/widget-column-renderer.d.ts +27 -0
  551. package/schema/lib/widget/widget-filter-renderer.d.ts +30 -0
  552. package/schema/lib/widget/widget-renderer.d.ts +26 -0
  553. package/schema/lib/widget/widget-token.d.ts +15 -0
  554. package/workflow/README.md +4 -0
  555. package/workflow/index.d.ts +6 -0
  556. package/workflow/lib/errors.types.d.ts +4 -0
  557. package/workflow/lib/workflow-event-dispatcher.service.d.ts +10 -0
  558. package/workflow/lib/workflow-registery.service.d.ts +17 -0
  559. package/workflow/lib/workflow.module.d.ts +25 -0
  560. package/workflow/lib/workflow.service.d.ts +23 -0
  561. package/workflow/lib/workflow.types.d.ts +61 -0
@@ -0,0 +1,3732 @@
1
+ import * as i0 from '@angular/core';
2
+ import { inject, Injectable, Component, ChangeDetectorRef, NgModule, ViewEncapsulation, signal, computed, Input, HostListener, InjectionToken, ViewChild, ChangeDetectionStrategy, EventEmitter, Output } from '@angular/core';
3
+ import * as i2$4 from '@ngrx/store';
4
+ import { createAction, createFeature, createReducer, on, createSelector, Store, props, StoreModule } from '@ngrx/store';
5
+ import { fromEvent, debounceTime, map, withLatestFrom, mergeMap, of, filter, first, BehaviorSubject, timer, defaultIfEmpty, switchMap } from 'rxjs';
6
+ import * as i2 from '@acorex/platform/common';
7
+ import { AXPNavigateAction as AXPNavigateAction$1, AXPLoadInitState, AXP_MENU_LOADER, AXPRouteUtilityService, AXPComponentLogoConfig, AXPFontIconLogoConfig, AXPImageUrlLogoConfig, AXPTextLogoConfig, AXP_PLATFORM_CONFIG_TOKEN, AXPComponentSlotModule, AXPStickyDirective, AXPCommonModule } from '@acorex/platform/common';
8
+ import * as i3$2 from '@acorex/core/platform';
9
+ import { AXPlatform } from '@acorex/core/platform';
10
+ import * as i1$5 from '@ngrx/effects';
11
+ import { Actions, createEffect, ofType, EffectsModule } from '@ngrx/effects';
12
+ import * as i1 from '@angular/router';
13
+ import { ActivatedRoute, Router, RouterModule, RouteReuseStrategy } from '@angular/router';
14
+ import * as i1$1 from '@angular/common';
15
+ import { CommonModule, Location } from '@angular/common';
16
+ import * as i1$2 from '@acorex/components/badge';
17
+ import { AXBadgeModule } from '@acorex/components/badge';
18
+ import * as i4 from '@acorex/components/button';
19
+ import { AXButtonModule } from '@acorex/components/button';
20
+ import * as i3 from '@acorex/components/decorators';
21
+ import { AXDecoratorModule } from '@acorex/components/decorators';
22
+ import { AXDialogModule, AXDialogService } from '@acorex/components/dialog';
23
+ import * as i4$1 from '@acorex/components/drawer';
24
+ import { AXDrawerModule } from '@acorex/components/drawer';
25
+ import * as i4$2 from '@acorex/components/loading';
26
+ import { AXLoadingModule } from '@acorex/components/loading';
27
+ import * as i9 from '@acorex/components/tabs';
28
+ import { AXTabsModule } from '@acorex/components/tabs';
29
+ import * as i2$3 from '@acorex/core/utils';
30
+ import { AXUnsubscriber } from '@acorex/core/utils';
31
+ import { AXCollapseModule } from '@acorex/components/collapse';
32
+ import * as i3$1 from '@acorex/components/nav';
33
+ import { AXNavModule } from '@acorex/components/nav';
34
+ import * as i8 from '@acorex/platform/auth';
35
+ import { AXPSessionService, AXPAuthModule, AXPAuthGuard } from '@acorex/platform/auth';
36
+ import * as i2$1 from '@acorex/components/image';
37
+ import { AXImageModule } from '@acorex/components/image';
38
+ import { merge, cloneDeep, assign } from 'lodash-es';
39
+ import { AXToastService, AXToastModule } from '@acorex/components/toast';
40
+ import * as i3$4 from '@acorex/platform/workflow';
41
+ import { createWorkFlowEvent, AXPWorkflowAction, AXPWorkflowError, AXPWorkflowFunction, AXPWorkflowService, ofType as ofType$1, AXPWorkflowModule } from '@acorex/platform/workflow';
42
+ import * as i5 from '@acorex/components/side-menu';
43
+ import { AXSideMenuModule } from '@acorex/components/side-menu';
44
+ import { AXAvatarModule } from '@acorex/components/avatar';
45
+ import * as i10 from '@acorex/components/dropdown';
46
+ import { AXDropdownModule } from '@acorex/components/dropdown';
47
+ import * as i5$1 from '@acorex/components/popover';
48
+ import { AXPopoverModule } from '@acorex/components/popover';
49
+ import { AXBasePageComponent } from '@acorex/components/page';
50
+ import * as i1$3 from '@acorex/platform/schema';
51
+ import { AXPSchemaRegistryService, EQ_OPER, STRING_OPERATORS, CONTAINS_OPER, NUMBER_OPERATORS, BETWEEN_OPER, DATE_OPERATORS, AXPSchemaModule } from '@acorex/platform/schema';
52
+ import * as i15 from '@angular/cdk/drag-drop';
53
+ import { moveItemInArray, CdkDropList, CdkDrag, CdkDragPlaceholder, CdkDragHandle } from '@angular/cdk/drag-drop';
54
+ import * as i2$2 from '@angular/forms';
55
+ import { FormsModule } from '@angular/forms';
56
+ import * as i8$1 from '@acorex/components/switch';
57
+ import { AXSwitchModule } from '@acorex/components/switch';
58
+ import * as i6 from '@acorex/components/select-box';
59
+ import { AXSelectBoxComponent, AXSelectBoxModule } from '@acorex/components/select-box';
60
+ import * as i4$3 from '@acorex/components/text-box';
61
+ import { AXTextBoxModule } from '@acorex/components/text-box';
62
+ import * as i7 from '@acorex/components/label';
63
+ import { AXLabelModule } from '@acorex/components/label';
64
+ import * as i4$4 from '@acorex/components/selection-list';
65
+ import { AXSelectionListModule } from '@acorex/components/selection-list';
66
+ import * as i14 from '@acorex/components/dropdown-button';
67
+ import { AXDropdownButtonModule } from '@acorex/components/dropdown-button';
68
+ import { AXPopupService } from '@acorex/components/popup';
69
+ import * as i1$4 from '@acorex/components/action-sheet';
70
+ import { AXActionSheetModule } from '@acorex/components/action-sheet';
71
+ import * as i6$1 from '@acorex/components/data-table';
72
+ import { AXDataTableModule } from '@acorex/components/data-table';
73
+ import { AXFormatService } from '@acorex/core/format';
74
+ import { AXLoadingDialogService } from '@acorex/components/loading-dialog';
75
+ import * as i12 from '@acorex/components/search-box';
76
+ import { AXSearchBoxModule } from '@acorex/components/search-box';
77
+ import { AXCommonModule, AXDataSource } from '@acorex/components/common';
78
+ import * as i3$3 from '@acorex/components/form';
79
+ import { AXFormModule } from '@acorex/components/form';
80
+ import { AXListModule } from '@acorex/components/list';
81
+ import { PortalModule } from '@angular/cdk/portal';
82
+ import { AXBreadcrumbsModule } from '@acorex/components/breadcrumbs';
83
+ import * as i11 from '@acorex/components/tooltip';
84
+ import { AXTooltipModule } from '@acorex/components/tooltip';
85
+
86
+ const AXPWindowResizeAction = createAction('[Layout] Resize');
87
+ //
88
+ const AXPLayoutRootDrawerClose = createAction('[Root Drawer] Close');
89
+ const AXPLayoutRootDrawerToggle = createAction('[Root Drawer] Toggle');
90
+ const AXPLayoutChildDrawerClose = createAction('[Child Drawer] Close');
91
+ const AXPLayoutChildDrawerToggle = createAction('[Child Drawer] Toggle');
92
+ //
93
+ const AXPLayoutThemeDarkToggleAction = createAction('[Theme] Toggle Dark');
94
+ const AXPLoadingShowAction = createAction('[Theme] Loading Show');
95
+ const AXPLoadingHideAction = createAction('[Theme] Loading Hide');
96
+
97
+ const platform$1 = new AXPlatform();
98
+ const initialState = {
99
+ theme: {
100
+ dark: false,
101
+ },
102
+ screen: {
103
+ small: platform$1.is('SM') || platform$1.is('MD'),
104
+ },
105
+ drawer: {
106
+ root: !(platform$1.is('SM') || platform$1.is('MD')),
107
+ child: !(platform$1.is('SM') || platform$1.is('MD'))
108
+ },
109
+ loading: false
110
+ };
111
+
112
+ const platform = new AXPlatform();
113
+ const AXPLayoutFeature = createFeature({
114
+ name: 'layout',
115
+ reducer: createReducer(initialState,
116
+ // close drawers on navigatin
117
+ on(AXPNavigateAction$1, (state, action) => ({
118
+ ...state,
119
+ drawer: { ...state.drawer, root: platform.is('SM') ? false : state.drawer.root, child: platform.is('SM') ? false : state.drawer.child },
120
+ })),
121
+ // toggle root drawers
122
+ on(AXPLayoutRootDrawerToggle, (state, action) => ({
123
+ ...state,
124
+ drawer: { ...state.drawer, root: !state.drawer.root, child: (!state.drawer.root && platform.is('SM')) ? false : state.drawer.child },
125
+ })),
126
+ // close root drawers
127
+ on(AXPLayoutRootDrawerClose, (state) => ({
128
+ ...state,
129
+ drawer: { ...state.drawer, root: false },
130
+ })),
131
+ // toggle second level child drawers
132
+ on(AXPLayoutChildDrawerToggle, (state) => ({
133
+ ...state,
134
+ drawer: { ...state.drawer, child: !state.drawer.child },
135
+ })),
136
+ // close second level child drawers
137
+ on(AXPLayoutChildDrawerClose, (state) => ({
138
+ ...state,
139
+ drawer: { ...state.drawer, child: false },
140
+ })),
141
+ // close drawers on window resize event
142
+ on(AXPWindowResizeAction, (state) => ({
143
+ ...state,
144
+ screen: { small: platform.is('SM') || platform.is('MD') },
145
+ drawer: {
146
+ ...state.drawer,
147
+ root: platform.is('SM') || platform.is('MD') ? false : state.drawer.root,
148
+ child: platform.is('SM') || platform.is('MD') ? false : state.drawer.child
149
+ },
150
+ })),
151
+ // toggle dark mode of theme
152
+ on(AXPLayoutThemeDarkToggleAction, (state) => ({
153
+ ...state,
154
+ theme: { dark: !state.theme?.dark },
155
+ })),
156
+ // Admin Root layout loading
157
+ on(AXPLoadingShowAction, (state) => ({
158
+ ...state,
159
+ loading: true,
160
+ })), on(AXPLoadingHideAction, (state) => ({
161
+ ...state,
162
+ loading: false,
163
+ }))),
164
+ });
165
+ const { name, reducer, selectLayoutState, } = AXPLayoutFeature;
166
+
167
+ const getRootDrawer = () => createSelector(selectLayoutState, (value) => value.drawer.root);
168
+ const getChildDrawer = () => createSelector(selectLayoutState, (value) => value.drawer.child);
169
+ const isSmallScreen = () => createSelector(selectLayoutState, (value) => value.screen.small);
170
+ const isDarkTheme = () => createSelector(selectLayoutState, (value) => value.theme.dark);
171
+ const isLoading = () => createSelector(selectLayoutState, (value) => value.loading);
172
+
173
+ class AXPLayoutEffects {
174
+ constructor() {
175
+ this.platform = inject(AXPlatform);
176
+ this.actions$ = inject(Actions);
177
+ this.store$ = inject(Store);
178
+ this.resize$ = createEffect(() => fromEvent(window, 'resize').pipe(debounceTime(300), map(() => AXPWindowResizeAction())));
179
+ this.switchDark$ = createEffect(() => this.actions$.pipe(ofType(AXPLayoutThemeDarkToggleAction, AXPLoadInitState), withLatestFrom(this.store$.select(isDarkTheme())), mergeMap(([action, dark]) => {
180
+ //TODO: replace with platform function;
181
+ const html = document.getElementsByTagName('html')[0];
182
+ dark ? html.classList.add('ax-dark') : html.classList.remove('ax-dark');
183
+ return of();
184
+ })), { dispatch: false });
185
+ }
186
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutEffects, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
187
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutEffects }); }
188
+ }
189
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutEffects, decorators: [{
190
+ type: Injectable
191
+ }] });
192
+
193
+ class AXPAdminChildLayoutComponent {
194
+ constructor() {
195
+ this.manuLoader = inject(AXP_MENU_LOADER);
196
+ this.activeRoute = inject(ActivatedRoute);
197
+ this.title = "";
198
+ this.store = inject((Store));
199
+ this.isSM = this.store.select(isSmallScreen());
200
+ this.isOpen = this.store.select(getChildDrawer());
201
+ this.menuItems$ = of();
202
+ this.routeUtilService = inject(AXPRouteUtilityService);
203
+ this.isActiveRoute = (item) => this.routeUtilService.isRouteActive(item);
204
+ this.routeParamSub = this.activeRoute.params.subscribe(val => {
205
+ const menu = this.manuLoader.currentMenuItem();
206
+ if (menu?.parent) {
207
+ this.title = menu.parent.text;
208
+ this.menuItems$ = of(menu.parent.children ?? []);
209
+ }
210
+ });
211
+ }
212
+ handleMenuClick(e, item) {
213
+ if (item.command) {
214
+ this.store.dispatch(item.command);
215
+ }
216
+ else if (item.path) {
217
+ this.store.dispatch(AXPNavigateAction$1({ payload: { commands: item.path } }));
218
+ }
219
+ }
220
+ handleCollapsedChange(value) {
221
+ if (value)
222
+ this.store.dispatch(AXPLayoutChildDrawerClose());
223
+ }
224
+ ngOnDestroy() {
225
+ this.routeParamSub?.unsubscribe();
226
+ }
227
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildLayoutComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
228
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPAdminChildLayoutComponent, selector: "ng-component", ngImport: i0, template: "<!-- <ax-drawer-container>\n <ax-drawer location=\"start\" [collapsed]=\"!(isOpen | async)\" [mode]=\" (isSM | async) ? 'overlay' : 'push'\"\n (collapsedChange)=\"handleCollapsedChange($event)\">\n <ax-content class=\" ax-border-e ax-p-6 ax-w-64\">\n <p class=\"ax-text-xl ax-font-bold ax-mb-6\">{{title}}</p>\n <ax-tabs look=\"with-line\" location=\"start\">\n <ax-tab-item [text]=\"tab.text\" *ngFor=\"let tab of menuItems$ | async\" [active]=\"isActiveRoute(tab)\"\n (onClick)=\"handleMenuClick($event,tab)\">\n </ax-tab-item>\n </ax-tabs>\n </ax-content>\n </ax-drawer>\n <ax-content>\n <router-outlet></router-outlet>\n </ax-content>\n</ax-drawer-container> -->\n<router-outlet></router-outlet>", dependencies: [{ kind: "directive", type: i1.RouterOutlet, selector: "router-outlet", inputs: ["name"], outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }] }); }
229
+ }
230
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildLayoutComponent, decorators: [{
231
+ type: Component,
232
+ args: [{ template: "<!-- <ax-drawer-container>\n <ax-drawer location=\"start\" [collapsed]=\"!(isOpen | async)\" [mode]=\" (isSM | async) ? 'overlay' : 'push'\"\n (collapsedChange)=\"handleCollapsedChange($event)\">\n <ax-content class=\" ax-border-e ax-p-6 ax-w-64\">\n <p class=\"ax-text-xl ax-font-bold ax-mb-6\">{{title}}</p>\n <ax-tabs look=\"with-line\" location=\"start\">\n <ax-tab-item [text]=\"tab.text\" *ngFor=\"let tab of menuItems$ | async\" [active]=\"isActiveRoute(tab)\"\n (onClick)=\"handleMenuClick($event,tab)\">\n </ax-tab-item>\n </ax-tabs>\n </ax-content>\n </ax-drawer>\n <ax-content>\n <router-outlet></router-outlet>\n </ax-content>\n</ax-drawer-container> -->\n<router-outlet></router-outlet>" }]
233
+ }], ctorParameters: () => [] });
234
+
235
+ class AXPAdminChildFeaturesListComponent {
236
+ constructor() {
237
+ this.manuLoader = inject(AXP_MENU_LOADER);
238
+ this.router = inject(Router);
239
+ this.activeRoute = inject(ActivatedRoute);
240
+ this.cdr = inject(ChangeDetectorRef);
241
+ this.store = inject((Store));
242
+ this.isSM = this.store.select(isSmallScreen());
243
+ this.isOpen = this.store.select(getChildDrawer());
244
+ this.menuItems$ = of();
245
+ this.title = "";
246
+ this.routeParamSub = this.activeRoute.params.subscribe(val => {
247
+ this.loadMenuItems();
248
+ });
249
+ }
250
+ loadMenuItems() {
251
+ const menu = this.manuLoader.currentMenuItem();
252
+ if (menu) {
253
+ this.title = menu.text;
254
+ }
255
+ this.menuItems$ = of(this.manuLoader.currentMenuItem()?.children ?? []);
256
+ this.firstMenuSub?.unsubscribe();
257
+ this.firstMenuSub = this.menuItems$
258
+ .pipe(withLatestFrom(this.isSM), filter(([_, isSM]) => !isSM), map(([menuItems, _]) => menuItems.find(c => c.path)), first())
259
+ .subscribe(c => {
260
+ if (c?.path) {
261
+ this.store.dispatch(AXPNavigateAction$1({ payload: { commands: c.path, extras: { replaceUrl: true } } }));
262
+ }
263
+ });
264
+ }
265
+ handleMenuClick(e, item) {
266
+ if (item.command) {
267
+ this.store.dispatch(item.command);
268
+ }
269
+ else if (item.path) {
270
+ this.store.dispatch(AXPNavigateAction$1({ payload: { commands: item.path } }));
271
+ }
272
+ }
273
+ ngOnDestroy() {
274
+ this.routeParamSub?.unsubscribe();
275
+ this.firstMenuSub?.unsubscribe();
276
+ }
277
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildFeaturesListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
278
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPAdminChildFeaturesListComponent, selector: "ng-component", ngImport: i0, template: "<div class=\"ax-flex ax-flex-col ax-overflow-hidden\">\n <div\n class=\"ax-flex md:ax-flex-col ax-gap-4 ax-justify-between ax-px-4 ax-py-3 md:ax-py-4 md:ax-px-6 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\">\n <div class=\"ax-flex ax-items-center ax-gap-3\">\n <div class=\"ax-text-xl ax-font-bold\">{{title}}</div>\n </div>\n </div>\n <div class=\"ax-flex-1 ax-px-6 ax-py-4 ax-flex ax-flex-col ax-gap-2 ax-divide-y ax-divide-solid\">\n <div *ngFor=\"let item of menuItems$ | async\"\n class=\"ax-py-2 ax-font-semibold ax-flex ax-justify-between ax-cursor-pointer ax-items-center\"\n (click)=\"handleMenuClick($event,item)\">\n <span>{{item.text}}</span>\n <i class=\"fa-solid fa-chevron-right ax-text-md ax-text-slate-400 \"></i>\n </div>\n\n </div>\n</div>", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }] }); }
279
+ }
280
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildFeaturesListComponent, decorators: [{
281
+ type: Component,
282
+ args: [{ template: "<div class=\"ax-flex ax-flex-col ax-overflow-hidden\">\n <div\n class=\"ax-flex md:ax-flex-col ax-gap-4 ax-justify-between ax-px-4 ax-py-3 md:ax-py-4 md:ax-px-6 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\">\n <div class=\"ax-flex ax-items-center ax-gap-3\">\n <div class=\"ax-text-xl ax-font-bold\">{{title}}</div>\n </div>\n </div>\n <div class=\"ax-flex-1 ax-px-6 ax-py-4 ax-flex ax-flex-col ax-gap-2 ax-divide-y ax-divide-solid\">\n <div *ngFor=\"let item of menuItems$ | async\"\n class=\"ax-py-2 ax-font-semibold ax-flex ax-justify-between ax-cursor-pointer ax-items-center\"\n (click)=\"handleMenuClick($event,item)\">\n <span>{{item.text}}</span>\n <i class=\"fa-solid fa-chevron-right ax-text-md ax-text-slate-400 \"></i>\n </div>\n\n </div>\n</div>" }]
283
+ }], ctorParameters: () => [] });
284
+
285
+ class AXPAdminChildLayoutModule {
286
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildLayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
287
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildLayoutModule, declarations: [AXPAdminChildLayoutComponent, AXPAdminChildFeaturesListComponent], imports: [CommonModule,
288
+ RouterModule,
289
+ AXButtonModule,
290
+ AXDecoratorModule,
291
+ AXBadgeModule,
292
+ AXDrawerModule,
293
+ AXDialogModule,
294
+ AXLoadingModule,
295
+ AXTabsModule,
296
+ AXButtonModule] }); }
297
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildLayoutModule, imports: [CommonModule,
298
+ RouterModule,
299
+ AXButtonModule,
300
+ AXDecoratorModule,
301
+ AXBadgeModule,
302
+ AXDrawerModule,
303
+ AXDialogModule,
304
+ AXLoadingModule,
305
+ AXTabsModule,
306
+ AXButtonModule] }); }
307
+ }
308
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminChildLayoutModule, decorators: [{
309
+ type: NgModule,
310
+ args: [{
311
+ imports: [
312
+ CommonModule,
313
+ RouterModule,
314
+ AXButtonModule,
315
+ AXDecoratorModule,
316
+ AXBadgeModule,
317
+ AXDrawerModule,
318
+ AXDialogModule,
319
+ AXLoadingModule,
320
+ AXTabsModule,
321
+ AXButtonModule,
322
+ ],
323
+ exports: [],
324
+ declarations: [AXPAdminChildLayoutComponent, AXPAdminChildFeaturesListComponent],
325
+ providers: [],
326
+ }]
327
+ }] });
328
+
329
+ class AXPAdminHeaderComponent {
330
+ constructor() {
331
+ this.store = inject((Store));
332
+ this.router = inject(Router);
333
+ this.isOpen = this.store.select(getRootDrawer());
334
+ }
335
+ menuClick() {
336
+ this.store.dispatch(AXPLayoutRootDrawerToggle());
337
+ }
338
+ logoClick() {
339
+ this.router.navigate(['/']);
340
+ }
341
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
342
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPAdminHeaderComponent, selector: "axp-dashboard-admin-header", host: { classAttribute: "ax-h-16 ax-flex ax-justify-between ax-px-4 md:ax-px-0 md:ax-pe-6 ax-py-4 ax-bg-surface ax-border-b" }, ngImport: i0, template: "<div class=\"ax-w-full ax-flex ax-justify-between\">\n <div class=\"ax-flex ax-items-center md:ax-hidden\">\n <i class=\"fa-solid fa-bars ax-text-lg ax-me-3\" (click)=\"menuClick()\"></i>\n </div>\n <div class=\"ax-flex ax-items-center\">\n <div\n class=\"ax-hidden md:ax-flex ax-items-center ax-justify-center ax-w-8 ax-h-8 ax-bg-on-surface ax-rounded ax-rounded-s-none ax-me-8 ax-cursor-pointer\"\n (click)=\"menuClick()\">\n <i class=\"fa-solid fa-chevrons-left ax-text-sm\" [ngClass]=\"{ 'ax-rotate-180': !(isOpen | async) }\"> </i>\n </div>\n <axp-component-slot name=\"header-start\"></axp-component-slot>\n </div>\n <div class=\"ax-flex ax-items-center\">\n <axp-component-slot name=\"header-end\"></axp-component-slot>\n </div>\n</div>", styles: [".profile-menus ul{margin-top:.5rem;border-bottom-width:1px;--tw-border-opacity: 1;border-color:rgba(var(--ax-color-border-default),var(--tw-border-opacity));padding-left:.5rem;padding-right:.5rem}.profile-menus ul:last-child{border-width:0px}.profile-menus ul li{display:flex;cursor:pointer;border-radius:.375rem;padding:.5rem}.profile-menus ul li:last-child{margin-bottom:.5rem}.profile-menus ul li:hover{--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity))}:is(.ax-dark .profile-menus ul li:hover){--tw-bg-opacity: 1;background-color:rgb(30 41 59 / var(--tw-bg-opacity))}.profile-menus ul li i{margin-inline-end:.75rem;display:grid;height:1.5rem;width:1.5rem;place-items:center;font-size:1.25rem;line-height:1.75rem}\n"], dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.AXPComponentSlotDirective, selector: "axp-component-slot", inputs: ["name"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], encapsulation: i0.ViewEncapsulation.None }); }
343
+ }
344
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminHeaderComponent, decorators: [{
345
+ type: Component,
346
+ args: [{ selector: 'axp-dashboard-admin-header', encapsulation: ViewEncapsulation.None, host: {
347
+ class: 'ax-h-16 ax-flex ax-justify-between ax-px-4 md:ax-px-0 md:ax-pe-6 ax-py-4 ax-bg-surface ax-border-b',
348
+ }, template: "<div class=\"ax-w-full ax-flex ax-justify-between\">\n <div class=\"ax-flex ax-items-center md:ax-hidden\">\n <i class=\"fa-solid fa-bars ax-text-lg ax-me-3\" (click)=\"menuClick()\"></i>\n </div>\n <div class=\"ax-flex ax-items-center\">\n <div\n class=\"ax-hidden md:ax-flex ax-items-center ax-justify-center ax-w-8 ax-h-8 ax-bg-on-surface ax-rounded ax-rounded-s-none ax-me-8 ax-cursor-pointer\"\n (click)=\"menuClick()\">\n <i class=\"fa-solid fa-chevrons-left ax-text-sm\" [ngClass]=\"{ 'ax-rotate-180': !(isOpen | async) }\"> </i>\n </div>\n <axp-component-slot name=\"header-start\"></axp-component-slot>\n </div>\n <div class=\"ax-flex ax-items-center\">\n <axp-component-slot name=\"header-end\"></axp-component-slot>\n </div>\n</div>", styles: [".profile-menus ul{margin-top:.5rem;border-bottom-width:1px;--tw-border-opacity: 1;border-color:rgba(var(--ax-color-border-default),var(--tw-border-opacity));padding-left:.5rem;padding-right:.5rem}.profile-menus ul:last-child{border-width:0px}.profile-menus ul li{display:flex;cursor:pointer;border-radius:.375rem;padding:.5rem}.profile-menus ul li:last-child{margin-bottom:.5rem}.profile-menus ul li:hover{--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity))}:is(.ax-dark .profile-menus ul li:hover){--tw-bg-opacity: 1;background-color:rgb(30 41 59 / var(--tw-bg-opacity))}.profile-menus ul li i{margin-inline-end:.75rem;display:grid;height:1.5rem;width:1.5rem;place-items:center;font-size:1.25rem;line-height:1.75rem}\n"] }]
349
+ }] });
350
+
351
+ class AXPContentViewComponent {
352
+ constructor() {
353
+ this.hasSidebar = true;
354
+ this.router = inject(Router);
355
+ this.route = inject(ActivatedRoute);
356
+ this.isOpen = true;
357
+ this.activeFragment = signal('');
358
+ this.windowWidth = signal(window.innerWidth);
359
+ this.isSM = computed(() => (this.windowWidth() < 768 ? true : false));
360
+ }
361
+ onResize() {
362
+ this.windowWidth.set(window.innerWidth);
363
+ }
364
+ ngOnInit() {
365
+ this.fragmentSubscription = this.route.fragment.subscribe((fragment) => {
366
+ if (fragment) {
367
+ const element = document.getElementById(fragment);
368
+ if (element)
369
+ element.scrollIntoView({ behavior: 'smooth' });
370
+ this.activeFragment.set(fragment);
371
+ }
372
+ });
373
+ }
374
+ toggleCollapse(collapsed) {
375
+ this.isOpen = !collapsed;
376
+ }
377
+ itemClick(fragment) {
378
+ if (fragment) {
379
+ this.router.navigate([], {
380
+ relativeTo: this.route,
381
+ fragment: fragment,
382
+ });
383
+ }
384
+ }
385
+ ngOnDestroy() {
386
+ this.fragmentSubscription.unsubscribe();
387
+ }
388
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPContentViewComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
389
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPContentViewComponent, isStandalone: true, selector: "axp-content-view", inputs: { dataSource: "dataSource", hasSidebar: ["hasSideBar", "hasSidebar"] }, host: { listeners: { "window:resize": "onResize($event)" } }, ngImport: i0, template: "<div class=\"ax-relative ax-grid\" [class.ax-grid-cols-12]=\"hasSidebar\">\n @if(hasSidebar){\n <div class=\"ax-hidden ax-fixed lg:ax-block ax-w-72 ax-right-0\">\n <ax-nav class=\"ax-h-[calc(100vh-120px)] ax-px-2 ax-py-4\">\n @for (section of dataSource.sections; track $index) {\n <ng-container [ngTemplateOutlet]=\"navTemplate\" [ngTemplateOutletContext]=\"{ $implicit: section }\"> </ng-container>\n }\n <ng-template #navTemplate let-item>\n <ax-nav-item [active]=\"activeFragment()==item.fragment\" (onClick)=\"itemClick(item.fragment)\">\n <span>{{item.title}}</span>\n <ax-prefix>\n <ax-icon [class]=\"item.icon\"></ax-icon>\n </ax-prefix>\n @if(item.children){\n <ng-container>\n @for (child of item.children; track $index) {\n <ng-container [ngTemplateOutlet]=\"navTemplate\" [ngTemplateOutletContext]=\"{ $implicit: child }\">\n </ng-container>\n }\n </ng-container>\n }\n </ax-nav-item>\n </ng-template>\n </ax-nav>\n </div>\n }\n <div\n class=\"ax-col-start-1 ax-col-end-13 lg:ax-col-end-9 2xl:ax-col-end-11 ax-flex ax-flex-col ax-gap-0 md:ax-gap-4 ax-px-6 ax-py-4 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\"\n >\n <span class=\"ax-text-xl md:ax-text-3xl ax-font-bold\">{{dataSource.title}}</span>\n @if(dataSource.subTitle){\n <span>{{dataSource.subTitle}}</span>\n } @for (section of dataSource.sections; track $index) {\n <ng-container\n [ngTemplateOutlet]=\"contentTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: section }\"\n ></ng-container>\n }\n <ng-template #contentTemplate let-section>\n @if(section.title){\n <h1 [id]=\"section.fragment\" class=\"ax-font-bold ax-text-lg\">{{section.title}}</h1>\n } @if(section.children){ @for (subSection of section.children; track $index) {\n <ng-container\n [ngTemplateOutlet]=\"contentTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: subSection }\"\n ></ng-container>\n } }@else { @for (item of section.content; track $index){ @if(item.type===\"paragraph\"){\n\n <p>{{item.text}}</p>\n }@else {\n <ul class=\"ax-list-disc ax-ps-10\">\n @for (option of item.text; track $index) {\n <li>{{option}}</li>\n }\n </ul>\n } } }\n </ng-template>\n </div>\n</div>\n", dependencies: [{ kind: "ngmodule", type: AXCollapseModule }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "ngmodule", type: AXNavModule }, { kind: "component", type: i3$1.AXNavComponent, selector: "ax-nav" }, { kind: "component", type: i3$1.AXNavItemComponent, selector: "ax-nav-item", inputs: ["disabled", "color", "active"], outputs: ["onClick", "activeChange"] }] }); }
390
+ }
391
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPContentViewComponent, decorators: [{
392
+ type: Component,
393
+ args: [{ selector: 'axp-content-view', standalone: true, imports: [AXCollapseModule, AXDecoratorModule, CommonModule, AXNavModule], template: "<div class=\"ax-relative ax-grid\" [class.ax-grid-cols-12]=\"hasSidebar\">\n @if(hasSidebar){\n <div class=\"ax-hidden ax-fixed lg:ax-block ax-w-72 ax-right-0\">\n <ax-nav class=\"ax-h-[calc(100vh-120px)] ax-px-2 ax-py-4\">\n @for (section of dataSource.sections; track $index) {\n <ng-container [ngTemplateOutlet]=\"navTemplate\" [ngTemplateOutletContext]=\"{ $implicit: section }\"> </ng-container>\n }\n <ng-template #navTemplate let-item>\n <ax-nav-item [active]=\"activeFragment()==item.fragment\" (onClick)=\"itemClick(item.fragment)\">\n <span>{{item.title}}</span>\n <ax-prefix>\n <ax-icon [class]=\"item.icon\"></ax-icon>\n </ax-prefix>\n @if(item.children){\n <ng-container>\n @for (child of item.children; track $index) {\n <ng-container [ngTemplateOutlet]=\"navTemplate\" [ngTemplateOutletContext]=\"{ $implicit: child }\">\n </ng-container>\n }\n </ng-container>\n }\n </ax-nav-item>\n </ng-template>\n </ax-nav>\n </div>\n }\n <div\n class=\"ax-col-start-1 ax-col-end-13 lg:ax-col-end-9 2xl:ax-col-end-11 ax-flex ax-flex-col ax-gap-0 md:ax-gap-4 ax-px-6 ax-py-4 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\"\n >\n <span class=\"ax-text-xl md:ax-text-3xl ax-font-bold\">{{dataSource.title}}</span>\n @if(dataSource.subTitle){\n <span>{{dataSource.subTitle}}</span>\n } @for (section of dataSource.sections; track $index) {\n <ng-container\n [ngTemplateOutlet]=\"contentTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: section }\"\n ></ng-container>\n }\n <ng-template #contentTemplate let-section>\n @if(section.title){\n <h1 [id]=\"section.fragment\" class=\"ax-font-bold ax-text-lg\">{{section.title}}</h1>\n } @if(section.children){ @for (subSection of section.children; track $index) {\n <ng-container\n [ngTemplateOutlet]=\"contentTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: subSection }\"\n ></ng-container>\n } }@else { @for (item of section.content; track $index){ @if(item.type===\"paragraph\"){\n\n <p>{{item.text}}</p>\n }@else {\n <ul class=\"ax-list-disc ax-ps-10\">\n @for (option of item.text; track $index) {\n <li>{{option}}</li>\n }\n </ul>\n } } }\n </ng-template>\n </div>\n</div>\n" }]
394
+ }], propDecorators: { dataSource: [{
395
+ type: Input,
396
+ args: ['dataSource']
397
+ }], hasSidebar: [{
398
+ type: Input,
399
+ args: ['hasSideBar']
400
+ }], onResize: [{
401
+ type: HostListener,
402
+ args: ['window:resize', ['$event']]
403
+ }] } });
404
+
405
+ class AXPError401Component {
406
+ constructor() {
407
+ this.sessionService = inject(AXPSessionService);
408
+ this.router = inject(Router);
409
+ this.isAuthorized$ = this.sessionService.isAuthorized$;
410
+ }
411
+ ngOnInit() { }
412
+ handleHomeClick() {
413
+ this.router.navigate([`/${this.sessionService.application?.name}/home`]);
414
+ }
415
+ handleSignInClick() {
416
+ this.router.navigate([`/auth/login`]);
417
+ }
418
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPError401Component, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
419
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPError401Component, isStandalone: true, selector: "axp-error-401", ngImport: i0, template: "<div class=\"ax-h-full ax-flex ax-flex-col ax-gap-8 ax-items-center ax-justify-center\">\n <img class=\"ax-w-3/4 md:ax-w-1/2 lg:ax-w-1/3 xl:ax-w-1/4\" src=\"/assets/images/error/error-401.svg\"\n alt=\"Oops! Error 404. No result found.\">\n <div class=\"ax-flex ax-flex-col ax-items-center ax-gap-2 md:ax-gap-4\">\n <h1 class=\"ax-font-bold ax-text-2xl md:ax-text-4xl\">Hold on a second!</h1>\n <p class=\"md:ax-text-lg ax-text-neutral-400\">Sorry, but you are not authorized to view this page.</p>\n </div>\n <div class=\"ax-flex ax-flex-col ax-gap-2 md:ax-gap-4 md:ax-flex-row\">\n @if((isAuthorized$ | async))\n {\n <ax-button (onClick)=\"handleHomeClick()\" class=\"ax-px-4\" color=\"primary\" text=\"Go back to home\"></ax-button>\n } @else {\n <ax-button (onClick)=\"handleSignInClick()\" class=\"ax-px-4\" color=\"primary\" text=\"Sign Up / Sign In\"></ax-button>\n }\n <ax-button class=\"ax-px-4\" color=\"ghost\" text=\"Contact us\"></ax-button>\n </div>\n</div>", dependencies: [{ kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }] }); }
420
+ }
421
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPError401Component, decorators: [{
422
+ type: Component,
423
+ args: [{ selector: 'axp-error-401', imports: [AXButtonModule, CommonModule], standalone: true, template: "<div class=\"ax-h-full ax-flex ax-flex-col ax-gap-8 ax-items-center ax-justify-center\">\n <img class=\"ax-w-3/4 md:ax-w-1/2 lg:ax-w-1/3 xl:ax-w-1/4\" src=\"/assets/images/error/error-401.svg\"\n alt=\"Oops! Error 404. No result found.\">\n <div class=\"ax-flex ax-flex-col ax-items-center ax-gap-2 md:ax-gap-4\">\n <h1 class=\"ax-font-bold ax-text-2xl md:ax-text-4xl\">Hold on a second!</h1>\n <p class=\"md:ax-text-lg ax-text-neutral-400\">Sorry, but you are not authorized to view this page.</p>\n </div>\n <div class=\"ax-flex ax-flex-col ax-gap-2 md:ax-gap-4 md:ax-flex-row\">\n @if((isAuthorized$ | async))\n {\n <ax-button (onClick)=\"handleHomeClick()\" class=\"ax-px-4\" color=\"primary\" text=\"Go back to home\"></ax-button>\n } @else {\n <ax-button (onClick)=\"handleSignInClick()\" class=\"ax-px-4\" color=\"primary\" text=\"Sign Up / Sign In\"></ax-button>\n }\n <ax-button class=\"ax-px-4\" color=\"ghost\" text=\"Contact us\"></ax-button>\n </div>\n</div>" }]
424
+ }], ctorParameters: () => [] });
425
+
426
+ var error401_component = /*#__PURE__*/Object.freeze({
427
+ __proto__: null,
428
+ AXPError401Component: AXPError401Component
429
+ });
430
+
431
+ class AXPError404Component {
432
+ constructor() {
433
+ this.sessionService = inject(AXPSessionService);
434
+ this.router = inject(Router);
435
+ }
436
+ goHome() {
437
+ this.router.navigate([`/${this.sessionService.application?.name}/home`]);
438
+ }
439
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPError404Component, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
440
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPError404Component, isStandalone: true, selector: "axp-error-404", ngImport: i0, template: "<div class=\"ax-h-full ax-flex ax-flex-col ax-gap-8 ax-items-center ax-justify-center\">\n <img class=\"ax-w-3/4 md:ax-w-1/2 lg:ax-w-1/3 xl:ax-w-1/3\" src=\" /assets/images/error/error-404.svg\"\n alt=\"Oops! Error 404. No result found.\">\n <div class=\"ax-flex ax-flex-col ax-items-center ax-gap-2 md:ax-gap-4\">\n <h1 class=\"ax-font-bold ax-text-2xl md:ax-text-4xl\">No Result Found.</h1>\n <p class=\"md:ax-text-lg ax-text-neutral-400\">Whoops! Looks like that page doesn't exist.</p>\n </div>\n <div class=\"ax-flex ax-flex-col ax-gap-2 md:ax-gap-4 md:ax-flex-row\">\n <ax-button (onClick)=\"goHome()\" class=\"ax-px-4\" color=\"primary\" text=\"Go back to home\"></ax-button>\n <ax-button class=\"ax-px-4\" color=\"ghost\" text=\"Contact us\"></ax-button>\n </div>\n</div>", styles: [""], dependencies: [{ kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }] }); }
441
+ }
442
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPError404Component, decorators: [{
443
+ type: Component,
444
+ args: [{ selector: 'axp-error-404', imports: [AXButtonModule], standalone: true, template: "<div class=\"ax-h-full ax-flex ax-flex-col ax-gap-8 ax-items-center ax-justify-center\">\n <img class=\"ax-w-3/4 md:ax-w-1/2 lg:ax-w-1/3 xl:ax-w-1/3\" src=\" /assets/images/error/error-404.svg\"\n alt=\"Oops! Error 404. No result found.\">\n <div class=\"ax-flex ax-flex-col ax-items-center ax-gap-2 md:ax-gap-4\">\n <h1 class=\"ax-font-bold ax-text-2xl md:ax-text-4xl\">No Result Found.</h1>\n <p class=\"md:ax-text-lg ax-text-neutral-400\">Whoops! Looks like that page doesn't exist.</p>\n </div>\n <div class=\"ax-flex ax-flex-col ax-gap-2 md:ax-gap-4 md:ax-flex-row\">\n <ax-button (onClick)=\"goHome()\" class=\"ax-px-4\" color=\"primary\" text=\"Go back to home\"></ax-button>\n <ax-button class=\"ax-px-4\" color=\"ghost\" text=\"Contact us\"></ax-button>\n </div>\n</div>" }]
445
+ }] });
446
+
447
+ var error404_component = /*#__PURE__*/Object.freeze({
448
+ __proto__: null,
449
+ AXPError404Component: AXPError404Component
450
+ });
451
+
452
+ class AXPErrorOfflineComponent {
453
+ constructor() { }
454
+ ngOnInit() { }
455
+ goHome() { }
456
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPErrorOfflineComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
457
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPErrorOfflineComponent, isStandalone: true, selector: "axp-error-offline", ngImport: i0, template: "<div class=\"ax-h-full ax-flex ax-flex-col ax-gap-8 ax-items-center ax-justify-center\">\n <img class=\"ax-w-3/4 md:ax-w-1/2 lg:ax-w-1/3 xl:ax-w-1/4\" src=\"/assets/images/error/error-offline.png\"\n alt=\"Oops! Error 404. No result found.\">\n <div class=\"ax-flex ax-flex-col ax-items-center ax-gap-2 md:ax-gap-4\">\n <h1 class=\"ax-font-bold ax-text-2xl md:ax-text-4xl\">Please check your connectivity!</h1>\n <p class=\"md:ax-text-lg ax-text-neutral-400\">Sorry, it seems you don't have access to the internet.</p>\n\n </div>\n <div class=\"ax-flex ax-flex-col ax-gap-2 md:ax-gap-4 md:ax-flex-row\">\n <ax-button (onClick)=\"goHome()\" class=\"ax-px-4\" color=\"primary\" text=\"Go back to home\"></ax-button>\n <ax-button class=\"ax-px-4\" color=\"ghost\" text=\"Contact us\"></ax-button>\n </div>\n</div>", styles: [""], dependencies: [{ kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }] }); }
458
+ }
459
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPErrorOfflineComponent, decorators: [{
460
+ type: Component,
461
+ args: [{ selector: 'axp-error-offline', imports: [AXButtonModule], standalone: true, template: "<div class=\"ax-h-full ax-flex ax-flex-col ax-gap-8 ax-items-center ax-justify-center\">\n <img class=\"ax-w-3/4 md:ax-w-1/2 lg:ax-w-1/3 xl:ax-w-1/4\" src=\"/assets/images/error/error-offline.png\"\n alt=\"Oops! Error 404. No result found.\">\n <div class=\"ax-flex ax-flex-col ax-items-center ax-gap-2 md:ax-gap-4\">\n <h1 class=\"ax-font-bold ax-text-2xl md:ax-text-4xl\">Please check your connectivity!</h1>\n <p class=\"md:ax-text-lg ax-text-neutral-400\">Sorry, it seems you don't have access to the internet.</p>\n\n </div>\n <div class=\"ax-flex ax-flex-col ax-gap-2 md:ax-gap-4 md:ax-flex-row\">\n <ax-button (onClick)=\"goHome()\" class=\"ax-px-4\" color=\"primary\" text=\"Go back to home\"></ax-button>\n <ax-button class=\"ax-px-4\" color=\"ghost\" text=\"Contact us\"></ax-button>\n </div>\n</div>" }]
462
+ }], ctorParameters: () => [] });
463
+
464
+ var errorOffline_component = /*#__PURE__*/Object.freeze({
465
+ __proto__: null,
466
+ AXPErrorOfflineComponent: AXPErrorOfflineComponent
467
+ });
468
+
469
+ class AXPLogoComponent {
470
+ ngOnInit() {
471
+ switch (true) {
472
+ case this.source instanceof AXPTextLogoConfig:
473
+ this.logoType = 'text';
474
+ break;
475
+ case this.source instanceof AXPImageUrlLogoConfig:
476
+ this.logoType = 'url';
477
+ break;
478
+ case this.source instanceof AXPFontIconLogoConfig:
479
+ this.logoType = 'iconClass';
480
+ break;
481
+ case this.source instanceof AXPComponentLogoConfig:
482
+ this.logoType = 'component';
483
+ break;
484
+ default:
485
+ break;
486
+ }
487
+ }
488
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLogoComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
489
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPLogoComponent, isStandalone: true, selector: "axp-logo", inputs: { source: "source" }, host: { styleAttribute: "display:block" }, ngImport: i0, template: "@switch (logoType) {\n@case ('text') {\n<span class=\"ax-font-bold ax-text-lg ax-select-none\">{{ source.text }}</span>\n}\n@case ('url') {\n<ax-image [src]=\"source.url\"></ax-image>\n} @case ('iconClass') {\n<ax-icon class=\"{{ source.classIcon }}\"></ax-icon>\n} @case ('component') {\n<ng-container *ngComponentOutlet=\"source.component\"></ng-container>\n}\n}", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInputs", "ngComponentOutletInjector", "ngComponentOutletContent", "ngComponentOutletNgModule", "ngComponentOutletNgModuleFactory"] }, { kind: "ngmodule", type: AXImageModule }, { kind: "component", type: i2$1.AXImageComponent, selector: "ax-image", inputs: ["overlayMode", "src", "alt", "priority", "lazy"], outputs: ["onLoad", "onError"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }] }); }
490
+ }
491
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLogoComponent, decorators: [{
492
+ type: Component,
493
+ args: [{ selector: 'axp-logo', standalone: true, imports: [CommonModule, AXImageModule, AXDecoratorModule], host: { 'style': 'display:block' }, template: "@switch (logoType) {\n@case ('text') {\n<span class=\"ax-font-bold ax-text-lg ax-select-none\">{{ source.text }}</span>\n}\n@case ('url') {\n<ax-image [src]=\"source.url\"></ax-image>\n} @case ('iconClass') {\n<ax-icon class=\"{{ source.classIcon }}\"></ax-icon>\n} @case ('component') {\n<ng-container *ngComponentOutlet=\"source.component\"></ng-container>\n}\n}" }]
494
+ }], propDecorators: { source: [{
495
+ type: Input
496
+ }] } });
497
+
498
+ class AXPFooterTextSlotComponent {
499
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPFooterTextSlotComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
500
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPFooterTextSlotComponent, isStandalone: true, selector: "ng-component", inputs: { text: "text" }, ngImport: i0, template: `
501
+ <small class="ax-text-sm ax-text-neutral-400" [innerHTML]="text"></small>
502
+ `, isInline: true }); }
503
+ }
504
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPFooterTextSlotComponent, decorators: [{
505
+ type: Component,
506
+ args: [{
507
+ template: `
508
+ <small class="ax-text-sm ax-text-neutral-400" [innerHTML]="text"></small>
509
+ `,
510
+ standalone: true
511
+ }]
512
+ }], propDecorators: { text: [{
513
+ type: Input
514
+ }] } });
515
+
516
+ class AXPNavBarSlotComponent {
517
+ constructor() {
518
+ this.store = inject(Store);
519
+ }
520
+ handleCommand(action) {
521
+ if (action)
522
+ this.store.dispatch(action);
523
+ }
524
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPNavBarSlotComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
525
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPNavBarSlotComponent, isStandalone: true, selector: "ng-component", inputs: { items: "items" }, ngImport: i0, template: `
526
+ <div class="ax-flex ax-items-center ax-justify-between ax-gap-5">
527
+ <a *ngFor="let link of items" (click)="handleCommand(link.command)" >{{ link.text }}</a>
528
+ </div>
529
+ `, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], encapsulation: i0.ViewEncapsulation.None }); }
530
+ }
531
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPNavBarSlotComponent, decorators: [{
532
+ type: Component,
533
+ args: [{
534
+ template: `
535
+ <div class="ax-flex ax-items-center ax-justify-between ax-gap-5">
536
+ <a *ngFor="let link of items" (click)="handleCommand(link.command)" >{{ link.text }}</a>
537
+ </div>
538
+ `,
539
+ standalone: true,
540
+ imports: [CommonModule],
541
+ encapsulation: ViewEncapsulation.None
542
+ }]
543
+ }], propDecorators: { items: [{
544
+ type: Input
545
+ }] } });
546
+
547
+ const AXPEntityListViewConfigEmpty = {
548
+ fixed: false,
549
+ columns: [],
550
+ conditions: [],
551
+ sorts: [],
552
+ name: 'empty',
553
+ title: 'Empty',
554
+ };
555
+ function convertPropertyToColumn(property) {
556
+ return {
557
+ //TODO: merge format function
558
+ schema: property.schema,
559
+ name: property.name,
560
+ title: property.title,
561
+ visible: true,
562
+ displayFormat: property.formats?.list ?? property.formats?.default,
563
+ sortOptions: {
564
+ enabled: property.canSort,
565
+ property: property.name,
566
+ },
567
+ filterOptions: {
568
+ enabled: property.canFilter,
569
+ property: property.name,
570
+ },
571
+ options: merge(cloneDeep(property.component?.common?.options), property.component?.column?.options),
572
+ };
573
+ }
574
+ function convertPropertiesToColumns(...propertis) {
575
+ return propertis.map((p) => convertPropertyToColumn(p));
576
+ }
577
+
578
+ class AXEntityLoaderDefault {
579
+ async get(moduleName, entityName) {
580
+ return null;
581
+ }
582
+ }
583
+ const AXP_ENTITY_LOADER = new InjectionToken('AXP_ENTITY_LOADER', {
584
+ providedIn: 'root',
585
+ factory: () => {
586
+ return new AXEntityLoaderDefault();
587
+ },
588
+ });
589
+
590
+ class AXPEntityRegistryService {
591
+ constructor() {
592
+ // Stores AXPEntityConfig objects, keyed by a combination of module and entity name.
593
+ this.entities = new Map();
594
+ // Entity loader service for dynamically loading entity configurations.
595
+ this.loader = inject(AXP_ENTITY_LOADER); // Assuming AXPEntityLoader is the correct type
596
+ }
597
+ /**
598
+ * Registers a new entity configuration. Entities are identified uniquely by a combination
599
+ * of their module and name.
600
+ *
601
+ * @param config The configuration object of the entity to be registered.
602
+ */
603
+ register(config) {
604
+ const key = this.createEntityKey(config.module, config.name);
605
+ this.entities.set(key, config);
606
+ }
607
+ /**
608
+ * Resolves an entity configuration based on module and entity name. If the configuration
609
+ * is not already registered, attempts to load it dynamically. Throws an error if the
610
+ * entity cannot be found or loaded.
611
+ *
612
+ * @param moduleName The module name of the entity.
613
+ * @param entityName The name of the entity.
614
+ * @returns A promise resolving to the entity configuration.
615
+ * @throws Error if the entity configuration cannot be resolved.
616
+ */
617
+ async resolve(moduleName, entityName) {
618
+ const key = this.createEntityKey(moduleName, entityName);
619
+ let config = this.entities.get(key) ?? null;
620
+ if (!config) {
621
+ try {
622
+ config = await this.loader.get(moduleName, entityName);
623
+ if (config) {
624
+ this.register(config);
625
+ }
626
+ }
627
+ catch (error) {
628
+ console.error(`Error loading entity '${key}':`, error);
629
+ throw error; // Rethrow to allow error handling by caller
630
+ }
631
+ if (!config) {
632
+ throw new Error(`Invalid Entity name: ${key}`);
633
+ }
634
+ }
635
+ return config;
636
+ }
637
+ /**
638
+ * Creates a unique key for an entity based on its module and name.
639
+ *
640
+ * @param moduleName The module name of the entity.
641
+ * @param entityName The name of the entity.
642
+ * @returns The unique key for the entity.
643
+ */
644
+ createEntityKey(moduleName, entityName) {
645
+ return `${moduleName}.${entityName}`;
646
+ }
647
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityRegistryService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
648
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityRegistryService, providedIn: 'root' }); }
649
+ }
650
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityRegistryService, decorators: [{
651
+ type: Injectable,
652
+ args: [{
653
+ providedIn: 'root',
654
+ }]
655
+ }] });
656
+
657
+ class AXPLayoutService {
658
+ constructor() {
659
+ this.minimumDisplayTime = 500; // milliseconds
660
+ //
661
+ this.navigationLoadingSubject = new BehaviorSubject(false);
662
+ this.navigationLoadingTaskCount = 0;
663
+ this.navigationLoadingStateActive = false;
664
+ //
665
+ this.overlayLoadingSubject = new BehaviorSubject(false);
666
+ this.overlayLoadingTaskCount = 0;
667
+ this.overlayLoadingStateActive = false;
668
+ }
669
+ get navigationLoading$() {
670
+ return this.navigationLoadingSubject.asObservable();
671
+ }
672
+ setNavigationLoading(value) {
673
+ if (value) {
674
+ this.navigationLoadingTaskCount++;
675
+ this.updateNavigationLoadingState(true);
676
+ }
677
+ else {
678
+ if (this.navigationLoadingTaskCount > 0) {
679
+ this.navigationLoadingTaskCount--;
680
+ }
681
+ if (this.navigationLoadingTaskCount === 0) {
682
+ // Start timer to keep loading state for minimum display time
683
+ timer(this.minimumDisplayTime).subscribe(() => {
684
+ if (this.navigationLoadingTaskCount === 0) {
685
+ this.updateNavigationLoadingState(false);
686
+ }
687
+ });
688
+ }
689
+ }
690
+ }
691
+ updateNavigationLoadingState(state) {
692
+ if (state !== this.navigationLoadingStateActive) {
693
+ this.navigationLoadingStateActive = state;
694
+ this.navigationLoadingSubject.next(state);
695
+ }
696
+ }
697
+ get overlayLoading$() {
698
+ return this.overlayLoadingSubject.asObservable();
699
+ }
700
+ setOverlayLoading(value) {
701
+ if (value) {
702
+ this.overlayLoadingTaskCount++;
703
+ this.updateOverlayLoadingState(true);
704
+ }
705
+ else {
706
+ if (this.overlayLoadingTaskCount > 0) {
707
+ this.overlayLoadingTaskCount--;
708
+ }
709
+ if (this.overlayLoadingTaskCount === 0) {
710
+ // Start timer to keep loading state for minimum display time
711
+ timer(this.minimumDisplayTime).subscribe(() => {
712
+ if (this.overlayLoadingTaskCount === 0) {
713
+ this.updateOverlayLoadingState(false);
714
+ }
715
+ });
716
+ }
717
+ }
718
+ }
719
+ updateOverlayLoadingState(state) {
720
+ if (state !== this.overlayLoadingStateActive) {
721
+ this.overlayLoadingStateActive = state;
722
+ this.overlayLoadingSubject.next(state);
723
+ }
724
+ }
725
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
726
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutService, providedIn: 'root' }); }
727
+ }
728
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutService, decorators: [{
729
+ type: Injectable,
730
+ args: [{ providedIn: 'root' }]
731
+ }] });
732
+
733
+ //TODO Loading, Redirect, Drawer, Show toast
734
+ const AXPRedirectEvent = createWorkFlowEvent('Redirect Event Fired');
735
+ class AXPNavigateAction extends AXPWorkflowAction {
736
+ constructor() {
737
+ super(...arguments);
738
+ this.router = inject(Router);
739
+ }
740
+ async execute(context) {
741
+ const payload = context.getVariable('payload');
742
+ if (Array.isArray(payload.commands))
743
+ this.router.navigate(payload.commands, payload.extras);
744
+ else {
745
+ if (payload.commands.toLowerCase().startsWith('http'))
746
+ window.open(payload.commands, '_blank');
747
+ else
748
+ this.router.navigate([payload.commands], payload.extras);
749
+ }
750
+ }
751
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPNavigateAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
752
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPNavigateAction }); }
753
+ }
754
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPNavigateAction, decorators: [{
755
+ type: Injectable
756
+ }] });
757
+ class AXPDialogConfirmAction extends AXPWorkflowAction {
758
+ constructor() {
759
+ super(...arguments);
760
+ this.dialogService = inject(AXDialogService);
761
+ }
762
+ async execute(context) {
763
+ context.setOutput('deleteConfirmed', false);
764
+ const dialogResult = await this.dialogService.confirm(this.title, this.message, this.type);
765
+ context.setOutput('deleteConfirmed', dialogResult.result);
766
+ }
767
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPDialogConfirmAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
768
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPDialogConfirmAction }); }
769
+ }
770
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPDialogConfirmAction, decorators: [{
771
+ type: Injectable
772
+ }] });
773
+ class AXPToastAction extends AXPWorkflowAction {
774
+ constructor() {
775
+ super(...arguments);
776
+ this.toastService = inject(AXToastService);
777
+ }
778
+ async execute(context) {
779
+ this.toastService.show({
780
+ color: this.color,
781
+ title: this.title,
782
+ content: this.content,
783
+ closeButton: true,
784
+ timeOut: 3000,
785
+ timeOutProgress: true,
786
+ });
787
+ }
788
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPToastAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
789
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPToastAction }); }
790
+ }
791
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPToastAction, decorators: [{
792
+ type: Injectable
793
+ }] });
794
+ class AXPShowDetailViewAction extends AXPWorkflowAction {
795
+ constructor() {
796
+ super(...arguments);
797
+ this.navigation = inject(AXPNavigateAction);
798
+ this.sessionService = inject(AXPSessionService);
799
+ }
800
+ async execute(context) {
801
+ const payload = context.getVariable('payload');
802
+ const id = context.getVariable('id');
803
+ const newPayload = {
804
+ commands: `/${this.sessionService.application?.name}/${payload.entity.module}/e/${payload.entity}/${id}/view`,
805
+ };
806
+ context.setVariable('payload', newPayload);
807
+ this.navigation.execute(context);
808
+ }
809
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPShowDetailViewAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
810
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPShowDetailViewAction }); }
811
+ }
812
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPShowDetailViewAction, decorators: [{
813
+ type: Injectable
814
+ }] });
815
+ class AXPShowListViewAction extends AXPWorkflowAction {
816
+ constructor() {
817
+ super(...arguments);
818
+ this.navigation = inject(AXPNavigateAction);
819
+ this.sessionService = inject(AXPSessionService);
820
+ }
821
+ async execute(context) {
822
+ const payload = context.getVariable('payload');
823
+ const newPayload = {
824
+ commands: `/${this.sessionService.application?.name}/${payload.entity.module}/e/${payload.entity}/list`,
825
+ };
826
+ context.setVariable('payload', newPayload);
827
+ this.navigation.execute(context);
828
+ }
829
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPShowListViewAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
830
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPShowListViewAction }); }
831
+ }
832
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPShowListViewAction, decorators: [{
833
+ type: Injectable
834
+ }] });
835
+
836
+ class AXMWorkflowErrorHandler {
837
+ constructor() {
838
+ this.dialog = inject(AXDialogService);
839
+ }
840
+ handleError(error, next) {
841
+ if (error instanceof AXPWorkflowError) {
842
+ this.dialog.alert("Somthing is wrong!", error.inner ? error.inner.message : error.message, 'danger');
843
+ next(error);
844
+ }
845
+ else {
846
+ next(error);
847
+ }
848
+ }
849
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXMWorkflowErrorHandler, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
850
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXMWorkflowErrorHandler }); }
851
+ }
852
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXMWorkflowErrorHandler, decorators: [{
853
+ type: Injectable
854
+ }] });
855
+
856
+ class AXPAdminFooterComponent {
857
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminFooterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
858
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPAdminFooterComponent, selector: "axp-dashboard-admin-footer", host: { classAttribute: "ax-h-10 ax-flex ax-item-center ax-justify-between ax-bg-surface ax-px-6 ax-border-t" }, providers: [], ngImport: i0, template: "<div class=\"ax-flex ax-items-center ax-justify-start ax-gap-1\">\n <axp-component-slot name=\"footer-start\"></axp-component-slot>\n</div>\n<div class=\"ax-flex ax-items-center ax-justify-end ax-gap-1\">\n <axp-component-slot name=\"footer-end\"></axp-component-slot>\n</div>", dependencies: [{ kind: "directive", type: i2.AXPComponentSlotDirective, selector: "axp-component-slot", inputs: ["name"] }], encapsulation: i0.ViewEncapsulation.None }); }
859
+ }
860
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminFooterComponent, decorators: [{
861
+ type: Component,
862
+ args: [{ selector: 'axp-dashboard-admin-footer', encapsulation: ViewEncapsulation.None, providers: [], host: {
863
+ class: 'ax-h-10 ax-flex ax-item-center ax-justify-between ax-bg-surface ax-px-6 ax-border-t',
864
+ }, template: "<div class=\"ax-flex ax-items-center ax-justify-start ax-gap-1\">\n <axp-component-slot name=\"footer-start\"></axp-component-slot>\n</div>\n<div class=\"ax-flex ax-items-center ax-justify-end ax-gap-1\">\n <axp-component-slot name=\"footer-end\"></axp-component-slot>\n</div>" }]
865
+ }] });
866
+
867
+ class AXPAdminLayoutComponent {
868
+ constructor() {
869
+ this.manuLoader = inject(AXP_MENU_LOADER);
870
+ this.config = inject(AXP_PLATFORM_CONFIG_TOKEN);
871
+ this.layoutService = inject(AXPLayoutService);
872
+ this.subscriber = inject(AXUnsubscriber);
873
+ this.store = inject((Store));
874
+ this.routeUtilService = inject(AXPRouteUtilityService);
875
+ this.isActiveRoute = (item) => this.routeUtilService.isRouteActive(item);
876
+ this.logo = this.config.logo;
877
+ this.isOpen = this.store.select(getRootDrawer());
878
+ this.isSM = this.store.select(isSmallScreen());
879
+ this.isLoading = signal(false);
880
+ this.showNavigationProgress = signal(false);
881
+ this.menuItems$ = this.manuLoader.getItems(1);
882
+ this.layoutService.navigationLoading$.pipe(this.subscriber.takeUntilDestroy).subscribe((value) => {
883
+ this.showNavigationProgress.set(value);
884
+ });
885
+ //
886
+ this.layoutService.overlayLoading$.pipe(this.subscriber.takeUntilDestroy).subscribe((value) => {
887
+ this.isLoading.set(value);
888
+ });
889
+ }
890
+ handleMenuClick(e, item) {
891
+ if (item.path && item.children?.length)
892
+ return;
893
+ if (item.command) {
894
+ this.store.dispatch(item.command);
895
+ }
896
+ else if (item.path) {
897
+ this.store.dispatch(AXPNavigateAction$1({ payload: { commands: item.path } }));
898
+ }
899
+ }
900
+ handleCollapsedChange(value) {
901
+ if (value)
902
+ this.store.dispatch(AXPLayoutRootDrawerClose());
903
+ }
904
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminLayoutComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
905
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPAdminLayoutComponent, selector: "ng-component", providers: [
906
+ {
907
+ provide: AXUnsubscriber,
908
+ },
909
+ ], viewQueries: [{ propertyName: "drawer", first: true, predicate: ["drawer"], descendants: true }], ngImport: i0, template: "<ax-drawer-container>\n <ax-drawer #drawer location=\"start\" [collapsed]=\"!(isOpen | async)\" [mode]=\"(isSM | async) ? 'overlay' : 'push'\"\n (collapsedChange)=\"handleCollapsedChange($event)\">\n <ax-content\n class=\"ax-w-64 ax-h-full ax-flex ax-flex-col ax-bg-secondary-600 dark:ax-bg-surface ax-text-primary-fore ax-border-e ax-border-primary-700 dark:ax-border-default\">\n <header class=\"ax-px-7 ax-h-16 ax-flex ax-items-center ax-border-b ax-border-white/10\">\n <axp-logo [source]=\"logo?.light\"></axp-logo>\n </header>\n <div class=\"ax-px-2 ax-py-4 ax-overflow-y-auto ax-flex-1 ax-h-full\">\n <ax-side-menu>\n <ng-container *ngFor=\"let node of this.menuItems$ | async\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: node }\">\n </ng-container>\n </ax-side-menu>\n <ng-template #sideMenu let-item>\n @if(item.type=='group') {\n <ax-title *permission=\"item.data?.requiredPermission\">{{ item.text }}</ax-title>\n } @else {\n <ax-side-menu-item *permission=\"item.data?.requiredPermission\" (onClick)=\"handleMenuClick($event, item)\"\n [active]=\"isActiveRoute(item) && !item.children?.length\" [isCollapsed]=\"item.opened == true ? false : true\">\n <ax-prefix>\n <ax-icon [class]=\"item.icon\"></ax-icon>\n </ax-prefix>\n {{ item.text }}\n <ng-container *ngIf=\"item.children\">\n <ng-container *ngFor=\"let child of item.children\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: child }\">\n </ng-container>\n </ng-container>\n </ax-side-menu-item>\n }\n </ng-template>\n </div>\n </ax-content>\n </ax-drawer>\n <ax-content class=\"ax-flex ax-flex-col ax-relative\">\n @if(showNavigationProgress())\n {\n <div class=\"axp-navigating-progress\">\n <div></div>\n </div>\n }\n <axp-dashboard-admin-header></axp-dashboard-admin-header>\n <div class=\"ax-flex-1 ax-overflow-auto ax-relative\" [axIsLoading]=\"isLoading()\">\n <router-outlet></router-outlet>\n </div>\n <axp-dashboard-admin-footer></axp-dashboard-admin-footer>\n </ax-content>\n</ax-drawer-container>", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.RouterOutlet, selector: "router-outlet", inputs: ["name"], outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "component", type: i4$1.AXDrawerComponent, selector: "ax-drawer", inputs: ["location", "showBackdrop", "mode", "collapsed"], outputs: ["locationChange", "modeChange", "collapsedChange"] }, { kind: "component", type: i4$1.AXDrawerContainerComponent, selector: "ax-drawer-container" }, { kind: "component", type: i5.AXSideMenuComponent, selector: "ax-side-menu" }, { kind: "component", type: i5.AXSideMenuItemComponent, selector: "ax-side-menu-item", inputs: ["disabled", "color", "text", "isCollapsed", "active"], outputs: ["textChange", "isCollapsedChange", "activeChange", "onClick"] }, { kind: "directive", type: i4$2.AXLoadingDirective, selector: "[axIsLoading]", inputs: ["axIsLoading"] }, { kind: "component", type: AXPLogoComponent, selector: "axp-logo", inputs: ["source"] }, { kind: "directive", type: i8.AXPPermissionDirective, selector: "[permission]", inputs: ["permission"] }, { kind: "component", type: AXPAdminFooterComponent, selector: "axp-dashboard-admin-footer" }, { kind: "component", type: AXPAdminHeaderComponent, selector: "axp-dashboard-admin-header" }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], encapsulation: i0.ViewEncapsulation.None }); }
910
+ }
911
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminLayoutComponent, decorators: [{
912
+ type: Component,
913
+ args: [{ encapsulation: ViewEncapsulation.None, providers: [
914
+ {
915
+ provide: AXUnsubscriber,
916
+ },
917
+ ], template: "<ax-drawer-container>\n <ax-drawer #drawer location=\"start\" [collapsed]=\"!(isOpen | async)\" [mode]=\"(isSM | async) ? 'overlay' : 'push'\"\n (collapsedChange)=\"handleCollapsedChange($event)\">\n <ax-content\n class=\"ax-w-64 ax-h-full ax-flex ax-flex-col ax-bg-secondary-600 dark:ax-bg-surface ax-text-primary-fore ax-border-e ax-border-primary-700 dark:ax-border-default\">\n <header class=\"ax-px-7 ax-h-16 ax-flex ax-items-center ax-border-b ax-border-white/10\">\n <axp-logo [source]=\"logo?.light\"></axp-logo>\n </header>\n <div class=\"ax-px-2 ax-py-4 ax-overflow-y-auto ax-flex-1 ax-h-full\">\n <ax-side-menu>\n <ng-container *ngFor=\"let node of this.menuItems$ | async\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: node }\">\n </ng-container>\n </ax-side-menu>\n <ng-template #sideMenu let-item>\n @if(item.type=='group') {\n <ax-title *permission=\"item.data?.requiredPermission\">{{ item.text }}</ax-title>\n } @else {\n <ax-side-menu-item *permission=\"item.data?.requiredPermission\" (onClick)=\"handleMenuClick($event, item)\"\n [active]=\"isActiveRoute(item) && !item.children?.length\" [isCollapsed]=\"item.opened == true ? false : true\">\n <ax-prefix>\n <ax-icon [class]=\"item.icon\"></ax-icon>\n </ax-prefix>\n {{ item.text }}\n <ng-container *ngIf=\"item.children\">\n <ng-container *ngFor=\"let child of item.children\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: child }\">\n </ng-container>\n </ng-container>\n </ax-side-menu-item>\n }\n </ng-template>\n </div>\n </ax-content>\n </ax-drawer>\n <ax-content class=\"ax-flex ax-flex-col ax-relative\">\n @if(showNavigationProgress())\n {\n <div class=\"axp-navigating-progress\">\n <div></div>\n </div>\n }\n <axp-dashboard-admin-header></axp-dashboard-admin-header>\n <div class=\"ax-flex-1 ax-overflow-auto ax-relative\" [axIsLoading]=\"isLoading()\">\n <router-outlet></router-outlet>\n </div>\n <axp-dashboard-admin-footer></axp-dashboard-admin-footer>\n </ax-content>\n</ax-drawer-container>" }]
918
+ }], ctorParameters: () => [], propDecorators: { drawer: [{
919
+ type: ViewChild,
920
+ args: ['drawer']
921
+ }] } });
922
+
923
+ class AXPAdminRootLayoutModule {
924
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminRootLayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
925
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminRootLayoutModule, declarations: [AXPAdminFooterComponent,
926
+ AXPAdminHeaderComponent,
927
+ AXPAdminLayoutComponent], imports: [CommonModule,
928
+ RouterModule,
929
+ AXButtonModule,
930
+ AXDecoratorModule,
931
+ AXDropdownModule,
932
+ AXAvatarModule,
933
+ AXImageModule,
934
+ AXImageModule,
935
+ AXPopoverModule,
936
+ AXBadgeModule,
937
+ AXTabsModule,
938
+ AXDrawerModule,
939
+ AXSideMenuModule,
940
+ AXLoadingModule,
941
+ AXPLogoComponent,
942
+ AXPAuthModule,
943
+ AXPComponentSlotModule] }); }
944
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminRootLayoutModule, imports: [CommonModule,
945
+ RouterModule,
946
+ AXButtonModule,
947
+ AXDecoratorModule,
948
+ AXDropdownModule,
949
+ AXAvatarModule,
950
+ AXImageModule,
951
+ AXImageModule,
952
+ AXPopoverModule,
953
+ AXBadgeModule,
954
+ AXTabsModule,
955
+ AXDrawerModule,
956
+ AXSideMenuModule,
957
+ AXLoadingModule,
958
+ AXPLogoComponent,
959
+ AXPAuthModule,
960
+ AXPComponentSlotModule] }); }
961
+ }
962
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminRootLayoutModule, decorators: [{
963
+ type: NgModule,
964
+ args: [{
965
+ imports: [
966
+ CommonModule,
967
+ RouterModule,
968
+ AXButtonModule,
969
+ AXDecoratorModule,
970
+ AXDropdownModule,
971
+ AXAvatarModule,
972
+ AXImageModule,
973
+ AXImageModule,
974
+ AXPopoverModule,
975
+ AXBadgeModule,
976
+ AXTabsModule,
977
+ AXDrawerModule,
978
+ AXSideMenuModule,
979
+ AXLoadingModule,
980
+ AXPLogoComponent,
981
+ AXPAuthModule,
982
+ AXPComponentSlotModule
983
+ ],
984
+ exports: [],
985
+ declarations: [
986
+ AXPAdminFooterComponent,
987
+ AXPAdminHeaderComponent,
988
+ AXPAdminLayoutComponent,
989
+ ],
990
+ providers: [],
991
+ }]
992
+ }] });
993
+
994
+ class AXPEntityCreateCustomViewComponent extends AXBasePageComponent {
995
+ constructor() {
996
+ super(...arguments);
997
+ this.schemaRegistry = inject(AXPSchemaRegistryService);
998
+ this.toastService = inject(AXToastService);
999
+ this.dialogService = inject(AXDialogService);
1000
+ this.subscriber = inject(AXUnsubscriber);
1001
+ this.mode = 'create';
1002
+ this.selectedView = {};
1003
+ this.showNameInput = signal(false);
1004
+ this.props = signal([]);
1005
+ this.columns = signal([]);
1006
+ this.visibleColumns = computed(() => this.columns().filter((c) => c.visible));
1007
+ this.conditions = signal([]);
1008
+ this.sorts = signal([]);
1009
+ this.selectedConditionNames = [];
1010
+ this.viewNames = [];
1011
+ }
1012
+ ngOnInit() {
1013
+ this.props.set(cloneDeep(this.loader.entity.properties));
1014
+ this.columns.set(cloneDeep(this.selectedView.columns));
1015
+ this.conditions.set(cloneDeep(this.selectedView.conditions));
1016
+ this.sorts.set(cloneDeep(this.selectedView.sorts));
1017
+ this.loader.views$.pipe(this.subscriber.takeUntilDestroy).subscribe((views) => {
1018
+ this.viewNames = views.map((v) => v.name);
1019
+ });
1020
+ }
1021
+ //****************** Columns ******************//
1022
+ updateColumnItem(event, colName) {
1023
+ if (event.isUserInteraction) {
1024
+ this.columns.update((prevCols) => prevCols.map((col) => (col.name === colName ? { ...col, visible: event.value } : col)));
1025
+ }
1026
+ }
1027
+ //****************** Sorts ******************//
1028
+ updateSortItem(item) {
1029
+ this.sorts.update((prevSorts) => prevSorts.map((sort) => (sort.name === item.name ? { ...sort, dir: sort.dir == 'asc' ? 'desc' : 'asc' } : sort)));
1030
+ }
1031
+ addSortItem() {
1032
+ const sortNames = this.sorts().map((p) => p.name);
1033
+ console.log(this.props(), sortNames);
1034
+ const name = this.props().find((c) => !sortNames.includes(c.name))?.name || this.props()[0].name;
1035
+ this.sorts.update((prevSorts) => [...prevSorts, { name, dir: 'asc' }]);
1036
+ }
1037
+ removeSortItem(item) {
1038
+ this.sorts.update((prevSorts) => prevSorts.filter((sort) => item.name != sort.name));
1039
+ }
1040
+ //****************** Conditions ******************//
1041
+ getSchema(name) {
1042
+ return this.props().find((c) => c.name == name)?.schema ?? '';
1043
+ }
1044
+ getOperators(name) {
1045
+ const schemaName = this.props().find((c) => c.name == name)?.schema ?? '';
1046
+ return this.schemaRegistry.resolve(schemaName)?.filterOptions?.operators ?? [];
1047
+ }
1048
+ getDefaultOperator(name) {
1049
+ const schemaName = this.props().find((c) => c.name == name)?.schema ?? '';
1050
+ return this.schemaRegistry.resolve(schemaName)?.filterOptions?.default ?? EQ_OPER;
1051
+ }
1052
+ getOperatorTitle(schemaName, oprName) {
1053
+ return this.getOperators(schemaName).find((c) => c.name == oprName)?.title || '';
1054
+ }
1055
+ resetSelectedFieldNames() {
1056
+ this.selectedConditionNames = this.conditions().map((c) => c.name);
1057
+ }
1058
+ addCondition() {
1059
+ const conditions = this.selectedConditionNames.map((c) => {
1060
+ const opr = this.getDefaultOperator(c);
1061
+ return {
1062
+ name: c,
1063
+ operator: opr.name,
1064
+ };
1065
+ });
1066
+ this.conditions.set(conditions);
1067
+ }
1068
+ removeCondition(item) {
1069
+ this.conditions.update((prevConditions) => prevConditions.filter((con) => con.name != item.name));
1070
+ }
1071
+ //****************** Common ******************//
1072
+ drop(type, event) {
1073
+ switch (type) {
1074
+ case 'columns':
1075
+ this.columns.update((prevCols) => {
1076
+ const columns = prevCols;
1077
+ moveItemInArray(columns, event.previousIndex, event.currentIndex);
1078
+ return columns;
1079
+ });
1080
+ break;
1081
+ case 'sorts':
1082
+ this.sorts.update((prevSorts) => {
1083
+ const sorts = prevSorts;
1084
+ moveItemInArray(sorts, event.previousIndex, event.currentIndex);
1085
+ return sorts;
1086
+ });
1087
+ break;
1088
+ case 'conditions':
1089
+ this.conditions.update((prevConditions) => {
1090
+ const conditions = prevConditions;
1091
+ moveItemInArray(conditions, event.previousIndex, event.currentIndex);
1092
+ return conditions;
1093
+ });
1094
+ break;
1095
+ default:
1096
+ break;
1097
+ }
1098
+ }
1099
+ changeViewNameToggle() {
1100
+ this.showNameInput.update((prev) => !prev);
1101
+ }
1102
+ generateViewName(title) {
1103
+ return title.replace(/\s+/g, '-').toLowerCase();
1104
+ }
1105
+ handleApplyClick() {
1106
+ const updatedView = {
1107
+ ...this.selectedView,
1108
+ name: this.generateViewName(this.selectedView.title),
1109
+ conditions: this.conditions(),
1110
+ columns: this.columns(),
1111
+ sorts: this.sorts(),
1112
+ };
1113
+ if (this.viewNames.includes(updatedView.name) && this.mode == 'create') {
1114
+ this.toastService.show({
1115
+ title: 'Invalid Title',
1116
+ content: 'The title you have chosen already exists. Please choose a different title for your custom view.',
1117
+ color: 'danger',
1118
+ location: 'bottom-center',
1119
+ closeButton: true,
1120
+ timeOut: 3000,
1121
+ });
1122
+ }
1123
+ else {
1124
+ this.close({ save: true, updatedView });
1125
+ }
1126
+ }
1127
+ handleResetClick() {
1128
+ this.conditions.set(cloneDeep(this.selectedView.conditions));
1129
+ this.columns.set(cloneDeep(this.selectedView.columns));
1130
+ this.sorts.set(cloneDeep(this.selectedView.sorts));
1131
+ }
1132
+ handleDiscardClick() {
1133
+ this.close({ save: false });
1134
+ }
1135
+ handleCancelClick() {
1136
+ this.close({ save: false });
1137
+ }
1138
+ handleDeleteClick() {
1139
+ this.dialogService
1140
+ .confirm('Warning', 'Are you sure want to delete this view?', 'danger', 'horizontal')
1141
+ .then((data) => {
1142
+ if (data.result) {
1143
+ this.close({ delete: true, viewName: this.selectedView.name });
1144
+ }
1145
+ });
1146
+ }
1147
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreateCustomViewComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
1148
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPEntityCreateCustomViewComponent, selector: "ng-component", inputs: { loader: "loader", mode: "mode", selectedView: "selectedView" }, providers: [
1149
+ {
1150
+ provide: AXUnsubscriber,
1151
+ },
1152
+ ], usesInheritance: true, ngImport: i0, template: "<ax-header class=\"ax-p-4 ax-flex ax-justify-between ax-border-b\">\n <div class=\"ax-flex ax-items-center\">\n @if (showNameInput() && mode==='create') {\n <div class=\"ax-w-60\">\n <ax-text-box class=\"ax-sm\" [(ngModel)]=\"selectedView.title\">\n @if(showNameInput()){\n <ax-suffix>\n <ax-button (onClick)=\"changeViewNameToggle()\" look=\"default\">\n <ax-icon class=\"fa-sodild fas fa-check ax-text-sm\"> </ax-icon>\n </ax-button>\n </ax-suffix>\n }\n </ax-text-box>\n </div>\n }@else {\n <span class=\"ax-text-lg ax-font-semibold\">{{ selectedView.title }}</span>\n } @if (mode===\"create\") {\n <ax-button class=\"ax-xs\" (onClick)=\"changeViewNameToggle()\" color=\"default\">\n @if(!showNameInput() ){\n <ax-icon class=\"fa-regular fa-pen ax-text-sm ax-text-neutral-600\"> </ax-icon>\n }\n </ax-button>\n }\n </div>\n <ax-close-button></ax-close-button>\n</ax-header>\n<div class=\"ax-p-4\">\n <ax-tabs [content]=\"contents\" look=\"with-line\">\n <ax-tab-item text=\"Columns\">\n <ax-suffix>\n <ax-badge [text]=\"visibleColumns().length.toString()\" color=\"primary\"> </ax-badge>\n </ax-suffix>\n <ax-content>\n <div\n class=\"ax-flex ax-flex-col ax-gap-4 ax-p-4 ax-select-none ax-h-[400px]\"\n cdkDropList\n (cdkDropListDropped)=\"drop('columns', $event)\"\n >\n <div class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-overflow-auto ax-pe-2\">\n <ng-container *ngFor=\"let item of columns()\">\n <div class=\"ax-flex ax-py-1 ax-items-center ax-justify-between\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-flex ax-items-center ax-gap-3\" cdkDragHandle>\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\"></ax-icon>\n <p class=\"ax-font-medium ax-text-sm\">{{ item.title }}</p>\n </div>\n <ax-switch\n class=\"ax-sm\"\n [(ngModel)]=\"item.visible\"\n (onValueChanged)=\"updateColumnItem($event, item.name)\"\n ></ax-switch>\n </div>\n </ng-container>\n </div>\n </div>\n </ax-content>\n </ax-tab-item>\n <ax-tab-item text=\"Conditions\">\n <ax-suffix>\n <ax-badge [text]=\"conditions().length.toString()\" color=\"primary\"> </ax-badge>\n </ax-suffix>\n <ax-content>\n <div\n class=\"ax-flex ax-flex-col ax-justify-start ax-gap-4 ax-py-4 ax-select-none ax-h-[400px]\"\n [class.ax-justify-center]=\"!conditions().length\"\n >\n @if(!conditions().length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Filters Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\"\n >Please select field(s) that you want to filter</span\n >\n </div>\n } @else {\n <div class=\"ax-sorted-list ax-px-4 ax-py-1 ax-overflow-auto\">\n <div cdkDropList (cdkDropListDropped)=\"drop('conditions', $event)\" class=\"ax-flex ax-flex-col ax-gap-2\">\n @for(item of conditions(); track item.name ){\n <div cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-ms-4 ax-flex ax-items-start ax-gap-2\">\n <ax-label>{{ loader.getProp(item.name)?.title }}</ax-label>\n @if(getOperatorTitle(item.name,item.operator)){\n <ax-badge\n class=\"ax-text-xs\"\n color=\"primary\"\n [look]=\"'twotone'\"\n [text]=\"getOperatorTitle(item.name, item.operator)\"\n ></ax-badge>\n }\n </div>\n <div class=\"ax-flex ax-group ax-items-center ax-gap-2\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <div class=\"ax-w-full\">\n <axp-widget-filter-renderer\n [schema]=\"getSchema(item.name)\"\n [prop]=\"loader.getProp(item.name)\"\n [(value)]=\"item.value\"\n [(operator)]=\"item.operator\"\n >\n </axp-widget-filter-renderer>\n </div>\n <ax-button look=\"blank\" color=\"danger\" class=\"ax-sm\" (onClick)=\"removeCondition(item)\">\n <ax-icon class=\"fa-solid fa-trash-can\"></ax-icon>\n </ax-button>\n </div>\n </div>\n }\n </div>\n </div>\n }\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if(conditions().length){\n <ax-button color=\"primary\" text=\"Add field\" look=\"blank\" class=\"ax-sm\"></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button color=\"primary\" text=\"Add field\" look=\"outline\" class=\"ax-md ax-w-56\"></ax-button>\n </div>\n }\n <ax-popover\n #conditionsPopover\n [target]=\"addField\"\n [placement]=\"conditions().length ? 'bottom-start' : 'bottom'\"\n [offsetY]=\"8\"\n [openOn]=\"'toggle'\"\n [closeOn]=\"'clickOut'\"\n [adaptivityEnabled]=\"true\"\n (onOpened)=\"resetSelectedFieldNames()\"\n >\n <div\n class=\"ax-bg-surface ax-border ax-border-default ax-rounded-md ax-shadow-md ax-w-full ax-min-w-[250px]\"\n >\n <div class=\"ax-border-b-[1px] ax-pb-2 ax-mb-2 ax-p-3\">\n <ax-title class=\"ax-font-bold\">Fields</ax-title>\n </div>\n <div class=\"ax-max-h-48 ax-overflow-auto\">\n <ax-selection-list\n [valueField]=\"'name'\"\n [textField]=\"'title'\"\n [(ngModel)]=\"selectedConditionNames\"\n [direction]=\"'vertical'\"\n [items]=\"props()\"\n [multiple]=\"true\"\n ></ax-selection-list>\n </div>\n <div class=\"ax-flex ax-justify-end ax-border-t-[1px] ax-p-3\">\n <ax-button\n (onClick)=\"addCondition(); conditionsPopover.close()\"\n class=\"ax-sm\"\n text=\"Confirm\"\n color=\"primary\"\n >\n </ax-button>\n </div>\n </div>\n </ax-popover>\n </div>\n </div>\n </div>\n </ax-content>\n </ax-tab-item>\n <ax-tab-item text=\"Sorting\">\n <ax-suffix>\n <ax-badge [text]=\"sorts().length.toString()\" color=\"primary\"> </ax-badge>\n </ax-suffix>\n <ax-content>\n <div\n class=\"ax-flex ax-p-4 ax-flex-col ax-justify-start ax-gap-4 ax-select-none ax-overflow-auto ax-h-[400px]\"\n [class.ax-justify-center]=\"!sorts().length\"\n >\n @if(!sorts().length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Sorts Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\"\n >Please select field(s) that you want to sort</span\n >\n </div>\n }@else {\n <div\n cdkDropList\n (cdkDropListDropped)=\"drop('sorts', $event)\"\n class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-py-1 ax-overflow-auto\"\n >\n <ng-container *ngFor=\"let item of sorts()\">\n <div class=\"ax-flex ax-gap-2 ax-items-center\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <ax-select-box [dataSource]=\"props()\" valueField=\"name\" textField=\"title\" [(ngModel)]=\"item.name\">\n </ax-select-box>\n <ax-button [color]=\"'default'\" class=\"ax-sm\" (click)=\"updateSortItem(item)\">\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'asc'\"\n class=\"fa-solid fa-arrow-up-long ax-text-neutral-400\"\n ></ax-icon>\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'desc'\"\n class=\"fa-solid fa-arrow-down-long ax-text-neutral-400\"\n ></ax-icon>\n </ax-button>\n\n <ax-button look=\"blank\" (onClick)=\"removeSortItem(item)\">\n <ax-icon class=\"fa-solid fa-trash-can ax-text-danger-500\"></ax-icon>\n </ax-button>\n </div>\n </ng-container>\n </div>\n }\n\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if(sorts().length){\n <ax-button\n (onClick)=\"addSortItem()\"\n color=\"primary\"\n text=\"Add field\"\n look=\"blank\"\n class=\"ax-sm\"\n ></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button\n (onClick)=\"addSortItem()\"\n color=\"primary\"\n text=\"Add field\"\n look=\"outline\"\n class=\"ax-md ax-w-56\"\n ></ax-button>\n </div>\n }\n </div>\n </div>\n </div>\n </ax-content>\n </ax-tab-item>\n </ax-tabs>\n <ng-template [axTabContent] #contents=\"axTabContent\"> </ng-template>\n</div>\n<ax-footer class=\"!ax-justify-end\">\n @if (mode===\"edit\") {\n <ax-dropdown-button text=\"Discard\" (onClick)=\"handleDiscardClick()\">\n <ax-button-item-list>\n <ax-button-item text=\"Reset\" (onClick)=\"handleResetClick()\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-rotate-left fa-flip-horizontal\"></ax-icon>\n </ax-prefix>\n </ax-button-item>\n <ax-button-item class=\"ax-text-danger\" text=\"Delete\" (onClick)=\"handleDeleteClick()\">\n <ax-prefix> <ax-icon icon=\"fas fa-trash fa-flip-horizontal\"></ax-icon> </ax-prefix\n ></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-button>\n } @else {\n <ax-button text=\"Cancel\" look=\"outline\" (onClick)=\"handleCancelClick()\"></ax-button>\n }\n <ax-button\n [text]=\"mode === 'create' ? 'Save' : 'Save Changes'\"\n color=\"primary\"\n (onClick)=\"handleApplyClick()\"\n ></ax-button>\n</ax-footer>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: i4.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i4.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items"], outputs: ["onItemClick"] }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorCloseButtonComponent, selector: "ax-close-button", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "component", type: i1$2.AXBadgeComponent, selector: "ax-badge", inputs: ["color", "look", "text"] }, { kind: "component", type: i5$1.AXPopoverComponent, selector: "ax-popover", inputs: ["offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "backdropClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "component", type: i2$1.AXImageComponent, selector: "ax-image", inputs: ["overlayMode", "src", "alt", "priority", "lazy"], outputs: ["onLoad", "onError"] }, { kind: "component", type: i8$1.AXSwitchComponent, selector: "ax-switch", inputs: ["disabled", "readonly", "color", "tabIndex", "value", "name", "isLoading"], outputs: ["onBlur", "onFocus", "valueChange", "onValueChanged", "readonlyChange", "disabledChange"] }, { kind: "component", type: i9.AXTabsComponent, selector: "ax-tabs", inputs: ["look", "location", "fitParent", "minWidth", "content"], outputs: ["onActiveTabChanged"] }, { kind: "component", type: i9.AXTabItemComponent, selector: "ax-tab-item", inputs: ["disabled", "text", "key", "headerTemplate", "active"], outputs: ["disabledChange", "onClick", "onBlur", "onFocus", "activeChange"] }, { kind: "directive", type: i9.AXTabContentDirective, selector: "[axTabContent]", inputs: ["axTabContent"], exportAs: ["axTabContent"] }, { kind: "component", type: i6.AXSelectBoxComponent, selector: "ax-select-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "minValue", "maxValue", "value", "state", "name", "id", "type", "look", "multiple", "valueField", "textField", "dataSource", "itemTemplate", "emptyTemplate", "loadingTemplate"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange"] }, { kind: "component", type: i4$3.AXTextBoxComponent, selector: "ax-text-box", inputs: ["disabled", "tabIndex", "readonly", "value", "state", "name", "id", "placeholder", "maxLength", "allowNull", "type", "autoComplete", "look", "mask-options", "class"], outputs: ["onBlur", "onFocus", "valueChange", "stateChange", "onValueChanged", "readonlyChange", "disabledChange", "onKeyDown", "onKeyUp", "onKeyPress"] }, { kind: "component", type: i7.AXLabelComponent, selector: "ax-label", inputs: ["required", "for"], outputs: ["requiredChange"] }, { kind: "component", type: i4$4.AXSelectionListComponent, selector: "ax-selection-list", inputs: ["id", "name", "disabled", "readonly", "tabIndex", "size", "value", "valueField", "textField", "hintField", "disabledField", "readonlyField", "multiple", "direction", "customTemplate", "showControl", "items", "look"], outputs: ["onValueChanged", "onBlur", "onFocus"] }, { kind: "component", type: i14.AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "type", "mode"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "directive", type: i15.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i15.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i15.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "component", type: i1$3.AXPWidgetFilterRendererComponent, selector: "axp-widget-filter-renderer", inputs: ["value", "operator", "prop", "schema"], outputs: ["valueChange", "operatorChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1153
+ }
1154
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreateCustomViewComponent, decorators: [{
1155
+ type: Component,
1156
+ args: [{ changeDetection: ChangeDetectionStrategy.OnPush, providers: [
1157
+ {
1158
+ provide: AXUnsubscriber,
1159
+ },
1160
+ ], template: "<ax-header class=\"ax-p-4 ax-flex ax-justify-between ax-border-b\">\n <div class=\"ax-flex ax-items-center\">\n @if (showNameInput() && mode==='create') {\n <div class=\"ax-w-60\">\n <ax-text-box class=\"ax-sm\" [(ngModel)]=\"selectedView.title\">\n @if(showNameInput()){\n <ax-suffix>\n <ax-button (onClick)=\"changeViewNameToggle()\" look=\"default\">\n <ax-icon class=\"fa-sodild fas fa-check ax-text-sm\"> </ax-icon>\n </ax-button>\n </ax-suffix>\n }\n </ax-text-box>\n </div>\n }@else {\n <span class=\"ax-text-lg ax-font-semibold\">{{ selectedView.title }}</span>\n } @if (mode===\"create\") {\n <ax-button class=\"ax-xs\" (onClick)=\"changeViewNameToggle()\" color=\"default\">\n @if(!showNameInput() ){\n <ax-icon class=\"fa-regular fa-pen ax-text-sm ax-text-neutral-600\"> </ax-icon>\n }\n </ax-button>\n }\n </div>\n <ax-close-button></ax-close-button>\n</ax-header>\n<div class=\"ax-p-4\">\n <ax-tabs [content]=\"contents\" look=\"with-line\">\n <ax-tab-item text=\"Columns\">\n <ax-suffix>\n <ax-badge [text]=\"visibleColumns().length.toString()\" color=\"primary\"> </ax-badge>\n </ax-suffix>\n <ax-content>\n <div\n class=\"ax-flex ax-flex-col ax-gap-4 ax-p-4 ax-select-none ax-h-[400px]\"\n cdkDropList\n (cdkDropListDropped)=\"drop('columns', $event)\"\n >\n <div class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-overflow-auto ax-pe-2\">\n <ng-container *ngFor=\"let item of columns()\">\n <div class=\"ax-flex ax-py-1 ax-items-center ax-justify-between\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-flex ax-items-center ax-gap-3\" cdkDragHandle>\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\"></ax-icon>\n <p class=\"ax-font-medium ax-text-sm\">{{ item.title }}</p>\n </div>\n <ax-switch\n class=\"ax-sm\"\n [(ngModel)]=\"item.visible\"\n (onValueChanged)=\"updateColumnItem($event, item.name)\"\n ></ax-switch>\n </div>\n </ng-container>\n </div>\n </div>\n </ax-content>\n </ax-tab-item>\n <ax-tab-item text=\"Conditions\">\n <ax-suffix>\n <ax-badge [text]=\"conditions().length.toString()\" color=\"primary\"> </ax-badge>\n </ax-suffix>\n <ax-content>\n <div\n class=\"ax-flex ax-flex-col ax-justify-start ax-gap-4 ax-py-4 ax-select-none ax-h-[400px]\"\n [class.ax-justify-center]=\"!conditions().length\"\n >\n @if(!conditions().length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Filters Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\"\n >Please select field(s) that you want to filter</span\n >\n </div>\n } @else {\n <div class=\"ax-sorted-list ax-px-4 ax-py-1 ax-overflow-auto\">\n <div cdkDropList (cdkDropListDropped)=\"drop('conditions', $event)\" class=\"ax-flex ax-flex-col ax-gap-2\">\n @for(item of conditions(); track item.name ){\n <div cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-ms-4 ax-flex ax-items-start ax-gap-2\">\n <ax-label>{{ loader.getProp(item.name)?.title }}</ax-label>\n @if(getOperatorTitle(item.name,item.operator)){\n <ax-badge\n class=\"ax-text-xs\"\n color=\"primary\"\n [look]=\"'twotone'\"\n [text]=\"getOperatorTitle(item.name, item.operator)\"\n ></ax-badge>\n }\n </div>\n <div class=\"ax-flex ax-group ax-items-center ax-gap-2\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <div class=\"ax-w-full\">\n <axp-widget-filter-renderer\n [schema]=\"getSchema(item.name)\"\n [prop]=\"loader.getProp(item.name)\"\n [(value)]=\"item.value\"\n [(operator)]=\"item.operator\"\n >\n </axp-widget-filter-renderer>\n </div>\n <ax-button look=\"blank\" color=\"danger\" class=\"ax-sm\" (onClick)=\"removeCondition(item)\">\n <ax-icon class=\"fa-solid fa-trash-can\"></ax-icon>\n </ax-button>\n </div>\n </div>\n }\n </div>\n </div>\n }\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if(conditions().length){\n <ax-button color=\"primary\" text=\"Add field\" look=\"blank\" class=\"ax-sm\"></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button color=\"primary\" text=\"Add field\" look=\"outline\" class=\"ax-md ax-w-56\"></ax-button>\n </div>\n }\n <ax-popover\n #conditionsPopover\n [target]=\"addField\"\n [placement]=\"conditions().length ? 'bottom-start' : 'bottom'\"\n [offsetY]=\"8\"\n [openOn]=\"'toggle'\"\n [closeOn]=\"'clickOut'\"\n [adaptivityEnabled]=\"true\"\n (onOpened)=\"resetSelectedFieldNames()\"\n >\n <div\n class=\"ax-bg-surface ax-border ax-border-default ax-rounded-md ax-shadow-md ax-w-full ax-min-w-[250px]\"\n >\n <div class=\"ax-border-b-[1px] ax-pb-2 ax-mb-2 ax-p-3\">\n <ax-title class=\"ax-font-bold\">Fields</ax-title>\n </div>\n <div class=\"ax-max-h-48 ax-overflow-auto\">\n <ax-selection-list\n [valueField]=\"'name'\"\n [textField]=\"'title'\"\n [(ngModel)]=\"selectedConditionNames\"\n [direction]=\"'vertical'\"\n [items]=\"props()\"\n [multiple]=\"true\"\n ></ax-selection-list>\n </div>\n <div class=\"ax-flex ax-justify-end ax-border-t-[1px] ax-p-3\">\n <ax-button\n (onClick)=\"addCondition(); conditionsPopover.close()\"\n class=\"ax-sm\"\n text=\"Confirm\"\n color=\"primary\"\n >\n </ax-button>\n </div>\n </div>\n </ax-popover>\n </div>\n </div>\n </div>\n </ax-content>\n </ax-tab-item>\n <ax-tab-item text=\"Sorting\">\n <ax-suffix>\n <ax-badge [text]=\"sorts().length.toString()\" color=\"primary\"> </ax-badge>\n </ax-suffix>\n <ax-content>\n <div\n class=\"ax-flex ax-p-4 ax-flex-col ax-justify-start ax-gap-4 ax-select-none ax-overflow-auto ax-h-[400px]\"\n [class.ax-justify-center]=\"!sorts().length\"\n >\n @if(!sorts().length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Sorts Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\"\n >Please select field(s) that you want to sort</span\n >\n </div>\n }@else {\n <div\n cdkDropList\n (cdkDropListDropped)=\"drop('sorts', $event)\"\n class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-py-1 ax-overflow-auto\"\n >\n <ng-container *ngFor=\"let item of sorts()\">\n <div class=\"ax-flex ax-gap-2 ax-items-center\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <ax-select-box [dataSource]=\"props()\" valueField=\"name\" textField=\"title\" [(ngModel)]=\"item.name\">\n </ax-select-box>\n <ax-button [color]=\"'default'\" class=\"ax-sm\" (click)=\"updateSortItem(item)\">\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'asc'\"\n class=\"fa-solid fa-arrow-up-long ax-text-neutral-400\"\n ></ax-icon>\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'desc'\"\n class=\"fa-solid fa-arrow-down-long ax-text-neutral-400\"\n ></ax-icon>\n </ax-button>\n\n <ax-button look=\"blank\" (onClick)=\"removeSortItem(item)\">\n <ax-icon class=\"fa-solid fa-trash-can ax-text-danger-500\"></ax-icon>\n </ax-button>\n </div>\n </ng-container>\n </div>\n }\n\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if(sorts().length){\n <ax-button\n (onClick)=\"addSortItem()\"\n color=\"primary\"\n text=\"Add field\"\n look=\"blank\"\n class=\"ax-sm\"\n ></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button\n (onClick)=\"addSortItem()\"\n color=\"primary\"\n text=\"Add field\"\n look=\"outline\"\n class=\"ax-md ax-w-56\"\n ></ax-button>\n </div>\n }\n </div>\n </div>\n </div>\n </ax-content>\n </ax-tab-item>\n </ax-tabs>\n <ng-template [axTabContent] #contents=\"axTabContent\"> </ng-template>\n</div>\n<ax-footer class=\"!ax-justify-end\">\n @if (mode===\"edit\") {\n <ax-dropdown-button text=\"Discard\" (onClick)=\"handleDiscardClick()\">\n <ax-button-item-list>\n <ax-button-item text=\"Reset\" (onClick)=\"handleResetClick()\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-rotate-left fa-flip-horizontal\"></ax-icon>\n </ax-prefix>\n </ax-button-item>\n <ax-button-item class=\"ax-text-danger\" text=\"Delete\" (onClick)=\"handleDeleteClick()\">\n <ax-prefix> <ax-icon icon=\"fas fa-trash fa-flip-horizontal\"></ax-icon> </ax-prefix\n ></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-button>\n } @else {\n <ax-button text=\"Cancel\" look=\"outline\" (onClick)=\"handleCancelClick()\"></ax-button>\n }\n <ax-button\n [text]=\"mode === 'create' ? 'Save' : 'Save Changes'\"\n color=\"primary\"\n (onClick)=\"handleApplyClick()\"\n ></ax-button>\n</ax-footer>\n" }]
1161
+ }], propDecorators: { loader: [{
1162
+ type: Input
1163
+ }], mode: [{
1164
+ type: Input
1165
+ }], selectedView: [{
1166
+ type: Input
1167
+ }] } });
1168
+
1169
+ class AXPListViewOptionsColumnsComponent {
1170
+ constructor() {
1171
+ this.store = inject((Store));
1172
+ this.isSM = this.store.select(isSmallScreen());
1173
+ this.columns$ = of([]);
1174
+ this.onClosed = new EventEmitter();
1175
+ }
1176
+ ngOnInit() {
1177
+ this.columns$ = this.loader.displayColumns$;
1178
+ }
1179
+ handleVisibilityChange(e, name) {
1180
+ if (e.isUserInteraction) {
1181
+ this.loader.setColumnVisibility(name, e.value);
1182
+ }
1183
+ }
1184
+ drop(event) {
1185
+ this.columns$.pipe(first()).subscribe((columns) => {
1186
+ moveItemInArray(columns, event.previousIndex, event.currentIndex);
1187
+ });
1188
+ }
1189
+ handleClose() {
1190
+ this.onClosed.emit();
1191
+ }
1192
+ handleResetClick() {
1193
+ this.loader.resetColumns();
1194
+ }
1195
+ handleApplyClick() {
1196
+ this.columns$.pipe(first()).subscribe((data) => {
1197
+ this.loader.updateColumns(data);
1198
+ });
1199
+ this.onClosed.emit();
1200
+ }
1201
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionsColumnsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1202
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPListViewOptionsColumnsComponent, selector: "axp-list-view-option-columns", inputs: { loader: "loader" }, outputs: { onClosed: "onClosed" }, ngImport: i0, template: "<ax-header class=\"ax-flex ax-items-center\">\n <h2 class=\"ax-text-xl ax-font-bold\">Columns</h2>\n <ax-button (onClick)=\"handleClose()\" [look]=\"'blank'\">\n <ax-icon class=\"fa-solid fa-close ax-text-neutral-400 ax-text-xl\"> </ax-icon>\n </ax-button>\n</ax-header>\n<div class=\"ax-flex ax-flex-col ax-gap-4 ax-p-4 ax-select-none\" cdkDropList (cdkDropListDropped)=\"drop($event)\">\n <div class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-max-h-[calc(100vh-280px)] ax-overflow-auto\">\n <ng-container *ngFor=\"let item of columns$ | async\">\n <div class=\"ax-flex ax-py-1 ax-items-center ax-justify-between\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-flex ax-items-center ax-gap-3\" cdkDragHandle>\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\"></ax-icon>\n <p class=\"ax-font-medium ax-text-sm\">{{ item.title }}</p>\n </div>\n <ax-switch\n class=\"ax-sm\"\n [ngModel]=\"item.visible\"\n (onValueChanged)=\"handleVisibilityChange($event, item.name)\"\n ></ax-switch>\n </div>\n </ng-container>\n </div>\n</div>\n<ax-footer class=\"!ax-justify-start ax-absolute ax-bottom-0 ax-w-full\">\n <ax-button text=\"Apply\" color=\"primary\" (onClick)=\"handleApplyClick()\"></ax-button>\n <ax-button text=\"Reset\" color=\"ghost\" (onClick)=\"handleResetClick()\"></ax-button>\n</ax-footer>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "component", type: i8$1.AXSwitchComponent, selector: "ax-switch", inputs: ["disabled", "readonly", "color", "tabIndex", "value", "name", "isLoading"], outputs: ["onBlur", "onFocus", "valueChange", "onValueChanged", "readonlyChange", "disabledChange"] }, { kind: "directive", type: i15.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i15.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i15.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }] }); }
1203
+ }
1204
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionsColumnsComponent, decorators: [{
1205
+ type: Component,
1206
+ args: [{ selector: 'axp-list-view-option-columns', template: "<ax-header class=\"ax-flex ax-items-center\">\n <h2 class=\"ax-text-xl ax-font-bold\">Columns</h2>\n <ax-button (onClick)=\"handleClose()\" [look]=\"'blank'\">\n <ax-icon class=\"fa-solid fa-close ax-text-neutral-400 ax-text-xl\"> </ax-icon>\n </ax-button>\n</ax-header>\n<div class=\"ax-flex ax-flex-col ax-gap-4 ax-p-4 ax-select-none\" cdkDropList (cdkDropListDropped)=\"drop($event)\">\n <div class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-max-h-[calc(100vh-280px)] ax-overflow-auto\">\n <ng-container *ngFor=\"let item of columns$ | async\">\n <div class=\"ax-flex ax-py-1 ax-items-center ax-justify-between\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-flex ax-items-center ax-gap-3\" cdkDragHandle>\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\"></ax-icon>\n <p class=\"ax-font-medium ax-text-sm\">{{ item.title }}</p>\n </div>\n <ax-switch\n class=\"ax-sm\"\n [ngModel]=\"item.visible\"\n (onValueChanged)=\"handleVisibilityChange($event, item.name)\"\n ></ax-switch>\n </div>\n </ng-container>\n </div>\n</div>\n<ax-footer class=\"!ax-justify-start ax-absolute ax-bottom-0 ax-w-full\">\n <ax-button text=\"Apply\" color=\"primary\" (onClick)=\"handleApplyClick()\"></ax-button>\n <ax-button text=\"Reset\" color=\"ghost\" (onClick)=\"handleResetClick()\"></ax-button>\n</ax-footer>\n" }]
1207
+ }], propDecorators: { loader: [{
1208
+ type: Input
1209
+ }], onClosed: [{
1210
+ type: Output
1211
+ }] } });
1212
+
1213
+ class AXPListViewOptionConditionsComponent {
1214
+ constructor() {
1215
+ this.onClosed = new EventEmitter();
1216
+ this.schemaRegistery = inject(AXPSchemaRegistryService);
1217
+ this.popopService = inject(AXPopupService);
1218
+ this.store = inject((Store));
1219
+ this.isSM = this.store.select(isSmallScreen());
1220
+ this.props$ = of([]);
1221
+ this.props = [];
1222
+ this.conditions$ = of([]);
1223
+ this.selectedFieldNames = [];
1224
+ }
1225
+ onNameChange(item) {
1226
+ console.log('onName changed!', item);
1227
+ }
1228
+ ngOnInit() {
1229
+ this.props$ = this.loader.properties$.pipe(map((sorts) => sorts.filter((s) => s.canFilter != false)));
1230
+ this.conditions$ = this.loader.conditions$;
1231
+ this.conditions$.pipe(first()).subscribe((initialConditions) => {
1232
+ this.selectedFieldNames = initialConditions.map((i) => i.name);
1233
+ });
1234
+ this.props$.pipe(first()).subscribe((data) => {
1235
+ this.props = data;
1236
+ });
1237
+ }
1238
+ getOperators(name) {
1239
+ const schemaName = this.props.find((c) => c.name == name)?.schema ?? '';
1240
+ return this.schemaRegistery.resolve(schemaName)?.filterOptions?.operators ?? [];
1241
+ }
1242
+ getDefaultOperator(name) {
1243
+ const schemaName = this.props.find((c) => c.name == name)?.schema ?? '';
1244
+ return this.schemaRegistery.resolve(schemaName)?.filterOptions?.default ?? EQ_OPER;
1245
+ }
1246
+ getOperatorTitle(schemaName, oprName) {
1247
+ return this.getOperators(schemaName).find((c) => c.name == oprName)?.title || '';
1248
+ }
1249
+ getSchema(name) {
1250
+ return this.props.find((c) => c.name == name)?.schema ?? '';
1251
+ }
1252
+ drop(event) {
1253
+ this.conditions$.pipe(first()).subscribe((conditions) => {
1254
+ console.log('conditions: ', conditions);
1255
+ moveItemInArray(conditions, event.previousIndex, event.currentIndex);
1256
+ });
1257
+ }
1258
+ handleClose() {
1259
+ this.onClosed.emit();
1260
+ }
1261
+ handleRemoveCondition(item) {
1262
+ this.selectedFieldNames = this.selectedFieldNames.filter((i) => i !== item.name);
1263
+ this.loader.removeCondition(item);
1264
+ }
1265
+ resetSelectedFieldNames() {
1266
+ this.conditions$.pipe(first()).subscribe((initialConditions) => {
1267
+ this.selectedFieldNames = initialConditions.map((i) => i.name);
1268
+ });
1269
+ }
1270
+ handleResetClick() {
1271
+ this.loader.resetConditions();
1272
+ }
1273
+ onConfirmFields() {
1274
+ const fileds = this.selectedFieldNames.map((c) => {
1275
+ const opr = this.getDefaultOperator(c);
1276
+ return {
1277
+ name: c,
1278
+ opr: opr.name,
1279
+ };
1280
+ });
1281
+ this.loader.addCondition(fileds);
1282
+ }
1283
+ handleApplyClick() {
1284
+ this.conditions$.pipe(first()).subscribe((data) => {
1285
+ console.log(data);
1286
+ this.loader.updateConditions(data);
1287
+ });
1288
+ this.onClosed.emit();
1289
+ }
1290
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionConditionsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1291
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPListViewOptionConditionsComponent, selector: "axp-list-view-option-conditions", inputs: { loader: "loader" }, outputs: { onClosed: "onClosed" }, ngImport: i0, template: "<ax-header class=\"ax-flex ax-items-center\">\n <h2 class=\"ax-text-xl ax-font-bold\">Filters</h2>\n <ax-button (onClick)=\"handleClose()\" [look]=\"'blank'\">\n <ax-icon class=\"fa-solid fa-close ax-text-neutral-400 ax-text-xl\"> </ax-icon>\n </ax-button>\n</ax-header>\n<div\n class=\"ax-flex ax-flex-col ax-justify-center ax-gap-4 ax-py-4 ax-select-none\"\n [class.ax-h-[calc(100vh-310px)]]=\"!(conditions$ | async)?.length\"\n>\n @if(!(conditions$ | async)?.length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Filters Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\">Please select field(s) that you want to filter</span>\n </div>\n } @else {\n <div class=\"ax-sorted-list ax-max-h-[calc(100vh-310px)] ax-px-4 ax-py-1 ax-overflow-auto\">\n <div cdkDropList (cdkDropListDropped)=\"drop($event)\" class=\"ax-flex ax-flex-col ax-gap-2\">\n @for(item of conditions$ | async; track item.name ){\n <div cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-ms-4 ax-flex ax-items-start ax-gap-2\">\n <ax-label>{{ loader.getProp(item.name)?.title }}</ax-label>\n @if(getOperatorTitle(item.name,item.operator)){\n <ax-badge\n class=\"ax-text-xs\"\n color=\"primary\"\n [look]=\"'twotone'\"\n [text]=\"getOperatorTitle(item.name, item.operator)\"\n ></ax-badge>\n }\n </div>\n <div class=\"ax-flex ax-group ax-items-center ax-gap-2\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <div class=\"ax-w-full\">\n <!-- <ax-text-box [(ngModel)]=\"item.value\"></ax-text-box> -->\n <axp-widget-filter-renderer\n [schema]=\"getSchema(item.name)\"\n [prop]=\"loader.getProp(item.name)\"\n [(value)]=\"item.value\"\n [(operator)]=\"item.operator\"\n >\n </axp-widget-filter-renderer>\n </div>\n <ax-button look=\"blank\" color=\"danger\" class=\"ax-sm\" (onClick)=\"handleRemoveCondition(item)\">\n <ax-icon class=\"fa-solid fa-trash-can\"></ax-icon>\n </ax-button>\n </div>\n </div>\n }\n </div>\n </div>\n }\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if((conditions$ | async)?.length){\n <ax-button color=\"primary\" text=\"Add field\" look=\"blank\" class=\"ax-sm\"></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button color=\"primary\" text=\"Add field\" look=\"outline\" class=\"ax-md ax-w-56\"></ax-button>\n </div>\n }\n </div>\n <ax-popover\n #fieldsPopover\n [target]=\"addField\"\n [openOn]=\"'toggle'\"\n [closeOn]=\"'clickOut'\"\n [adaptivityEnabled]=\"true\"\n (onOpened)=\"resetSelectedFieldNames()\"\n [offsetX]=\"15\"\n >\n <div class=\"ax-bg-surface ax-border ax-border-default ax-rounded-md ax-shadow-md ax-w-full ax-min-w-[250px]\">\n <div class=\"ax-border-b-[1px] ax-pb-2 ax-mb-2 ax-p-3\">\n <ax-title class=\"ax-font-bold\">Fields</ax-title>\n </div>\n <div class=\"ax-max-h-72 2xl:ax-max-h-80 ax-overflow-auto\">\n <ax-selection-list\n [valueField]=\"'name'\"\n [textField]=\"'title'\"\n [(ngModel)]=\"selectedFieldNames\"\n [direction]=\"'vertical'\"\n [items]=\"props\"\n [multiple]=\"true\"\n ></ax-selection-list>\n </div>\n <div class=\"ax-flex ax-justify-end ax-border-t-[1px] ax-p-3\">\n <ax-button (onClick)=\"onConfirmFields(); fieldsPopover.close()\" class=\"ax-sm\" text=\"Confirm\" color=\"primary\">\n </ax-button>\n </div>\n </div>\n </ax-popover>\n </div>\n</div>\n<ax-footer class=\"!ax-justify-start ax-absolute ax-bottom-0 ax-w-full\">\n <ax-button text=\"Apply\" color=\"primary\" (onClick)=\"handleApplyClick()\"></ax-button>\n <ax-button text=\"Reset\" color=\"ghost\" (onClick)=\"handleResetClick()\"></ax-button>\n</ax-footer>\n", dependencies: [{ kind: "directive", type: i2$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "component", type: i1$2.AXBadgeComponent, selector: "ax-badge", inputs: ["color", "look", "text"] }, { kind: "component", type: i5$1.AXPopoverComponent, selector: "ax-popover", inputs: ["offsetX", "offsetY", "target", "placement", "content", "openOn", "closeOn", "hasBackdrop", "openAfter", "closeAfter", "backdropClass", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "component", type: i2$1.AXImageComponent, selector: "ax-image", inputs: ["overlayMode", "src", "alt", "priority", "lazy"], outputs: ["onLoad", "onError"] }, { kind: "component", type: i7.AXLabelComponent, selector: "ax-label", inputs: ["required", "for"], outputs: ["requiredChange"] }, { kind: "component", type: i4$4.AXSelectionListComponent, selector: "ax-selection-list", inputs: ["id", "name", "disabled", "readonly", "tabIndex", "size", "value", "valueField", "textField", "hintField", "disabledField", "readonlyField", "multiple", "direction", "customTemplate", "showControl", "items", "look"], outputs: ["onValueChanged", "onBlur", "onFocus"] }, { kind: "directive", type: i15.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i15.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i15.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "component", type: i1$3.AXPWidgetFilterRendererComponent, selector: "axp-widget-filter-renderer", inputs: ["value", "operator", "prop", "schema"], outputs: ["valueChange", "operatorChange"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1292
+ }
1293
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionConditionsComponent, decorators: [{
1294
+ type: Component,
1295
+ args: [{ selector: 'axp-list-view-option-conditions', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<ax-header class=\"ax-flex ax-items-center\">\n <h2 class=\"ax-text-xl ax-font-bold\">Filters</h2>\n <ax-button (onClick)=\"handleClose()\" [look]=\"'blank'\">\n <ax-icon class=\"fa-solid fa-close ax-text-neutral-400 ax-text-xl\"> </ax-icon>\n </ax-button>\n</ax-header>\n<div\n class=\"ax-flex ax-flex-col ax-justify-center ax-gap-4 ax-py-4 ax-select-none\"\n [class.ax-h-[calc(100vh-310px)]]=\"!(conditions$ | async)?.length\"\n>\n @if(!(conditions$ | async)?.length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Filters Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\">Please select field(s) that you want to filter</span>\n </div>\n } @else {\n <div class=\"ax-sorted-list ax-max-h-[calc(100vh-310px)] ax-px-4 ax-py-1 ax-overflow-auto\">\n <div cdkDropList (cdkDropListDropped)=\"drop($event)\" class=\"ax-flex ax-flex-col ax-gap-2\">\n @for(item of conditions$ | async; track item.name ){\n <div cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <div class=\"ax-ms-4 ax-flex ax-items-start ax-gap-2\">\n <ax-label>{{ loader.getProp(item.name)?.title }}</ax-label>\n @if(getOperatorTitle(item.name,item.operator)){\n <ax-badge\n class=\"ax-text-xs\"\n color=\"primary\"\n [look]=\"'twotone'\"\n [text]=\"getOperatorTitle(item.name, item.operator)\"\n ></ax-badge>\n }\n </div>\n <div class=\"ax-flex ax-group ax-items-center ax-gap-2\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <div class=\"ax-w-full\">\n <!-- <ax-text-box [(ngModel)]=\"item.value\"></ax-text-box> -->\n <axp-widget-filter-renderer\n [schema]=\"getSchema(item.name)\"\n [prop]=\"loader.getProp(item.name)\"\n [(value)]=\"item.value\"\n [(operator)]=\"item.operator\"\n >\n </axp-widget-filter-renderer>\n </div>\n <ax-button look=\"blank\" color=\"danger\" class=\"ax-sm\" (onClick)=\"handleRemoveCondition(item)\">\n <ax-icon class=\"fa-solid fa-trash-can\"></ax-icon>\n </ax-button>\n </div>\n </div>\n }\n </div>\n </div>\n }\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if((conditions$ | async)?.length){\n <ax-button color=\"primary\" text=\"Add field\" look=\"blank\" class=\"ax-sm\"></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button color=\"primary\" text=\"Add field\" look=\"outline\" class=\"ax-md ax-w-56\"></ax-button>\n </div>\n }\n </div>\n <ax-popover\n #fieldsPopover\n [target]=\"addField\"\n [openOn]=\"'toggle'\"\n [closeOn]=\"'clickOut'\"\n [adaptivityEnabled]=\"true\"\n (onOpened)=\"resetSelectedFieldNames()\"\n [offsetX]=\"15\"\n >\n <div class=\"ax-bg-surface ax-border ax-border-default ax-rounded-md ax-shadow-md ax-w-full ax-min-w-[250px]\">\n <div class=\"ax-border-b-[1px] ax-pb-2 ax-mb-2 ax-p-3\">\n <ax-title class=\"ax-font-bold\">Fields</ax-title>\n </div>\n <div class=\"ax-max-h-72 2xl:ax-max-h-80 ax-overflow-auto\">\n <ax-selection-list\n [valueField]=\"'name'\"\n [textField]=\"'title'\"\n [(ngModel)]=\"selectedFieldNames\"\n [direction]=\"'vertical'\"\n [items]=\"props\"\n [multiple]=\"true\"\n ></ax-selection-list>\n </div>\n <div class=\"ax-flex ax-justify-end ax-border-t-[1px] ax-p-3\">\n <ax-button (onClick)=\"onConfirmFields(); fieldsPopover.close()\" class=\"ax-sm\" text=\"Confirm\" color=\"primary\">\n </ax-button>\n </div>\n </div>\n </ax-popover>\n </div>\n</div>\n<ax-footer class=\"!ax-justify-start ax-absolute ax-bottom-0 ax-w-full\">\n <ax-button text=\"Apply\" color=\"primary\" (onClick)=\"handleApplyClick()\"></ax-button>\n <ax-button text=\"Reset\" color=\"ghost\" (onClick)=\"handleResetClick()\"></ax-button>\n</ax-footer>\n" }]
1296
+ }], ctorParameters: () => [], propDecorators: { onClosed: [{
1297
+ type: Output
1298
+ }], loader: [{
1299
+ type: Input
1300
+ }] } });
1301
+
1302
+ class AXPListViewOptionFilterOperatorComponent {
1303
+ constructor() {
1304
+ this.visible = false;
1305
+ this.cdr = inject(ChangeDetectorRef);
1306
+ this._items = [];
1307
+ this.valueChange = new EventEmitter();
1308
+ }
1309
+ get items() {
1310
+ return this._items;
1311
+ }
1312
+ set items(v) {
1313
+ this.visible = false;
1314
+ this._items = v;
1315
+ setTimeout(() => {
1316
+ this.visible = true;
1317
+ this.cdr.markForCheck();
1318
+ setTimeout(() => {
1319
+ if (this.selectBox) {
1320
+ this.selectBox.defaultValue = this.items[0]?.name;
1321
+ }
1322
+ });
1323
+ });
1324
+ }
1325
+ get value() {
1326
+ return this._value;
1327
+ }
1328
+ set value(v) {
1329
+ this._value = v;
1330
+ this.valueChange.emit(v);
1331
+ }
1332
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionFilterOperatorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1333
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPListViewOptionFilterOperatorComponent, selector: "axp-list-view-option-filter-operator", inputs: { items: "items", value: "value" }, outputs: { valueChange: "valueChange" }, host: { styleAttribute: "display: contents;" }, viewQueries: [{ propertyName: "selectBox", first: true, predicate: AXSelectBoxComponent, descendants: true }], ngImport: i0, template: `
1334
+ <ax-select-box
1335
+ valueField="name"
1336
+ [dataSource]="items"
1337
+ textField="title"
1338
+ [(ngModel)]="value"
1339
+ *ngIf="visible"
1340
+ >
1341
+ </ax-select-box>
1342
+ `, isInline: true, dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.AXSelectBoxComponent, selector: "ax-select-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "minValue", "maxValue", "value", "state", "name", "id", "type", "look", "multiple", "valueField", "textField", "dataSource", "itemTemplate", "emptyTemplate", "loadingTemplate"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
1343
+ }
1344
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionFilterOperatorComponent, decorators: [{
1345
+ type: Component,
1346
+ args: [{
1347
+ selector: 'axp-list-view-option-filter-operator',
1348
+ template: `
1349
+ <ax-select-box
1350
+ valueField="name"
1351
+ [dataSource]="items"
1352
+ textField="title"
1353
+ [(ngModel)]="value"
1354
+ *ngIf="visible"
1355
+ >
1356
+ </ax-select-box>
1357
+ `,
1358
+ changeDetection: ChangeDetectionStrategy.OnPush,
1359
+ host: { style: 'display: contents;' },
1360
+ }]
1361
+ }], propDecorators: { selectBox: [{
1362
+ type: ViewChild,
1363
+ args: [AXSelectBoxComponent]
1364
+ }], items: [{
1365
+ type: Input
1366
+ }], valueChange: [{
1367
+ type: Output
1368
+ }], value: [{
1369
+ type: Input
1370
+ }] } });
1371
+
1372
+ class AXPListViewOptionSortingComponent {
1373
+ constructor() {
1374
+ this.store = inject((Store));
1375
+ this.isSM = this.store.select(isSmallScreen());
1376
+ this.onClosed = new EventEmitter();
1377
+ this.props$ = of([]);
1378
+ this.sorts$ = of([]);
1379
+ }
1380
+ ngOnInit() {
1381
+ this.props$ = this.loader.properties$.pipe(map((sorts) => sorts.filter((s) => s.canSort != false)));
1382
+ this.sorts$ = this.loader.sorts$;
1383
+ }
1384
+ drop(event) {
1385
+ this.sorts$.pipe(first()).subscribe((sorts) => {
1386
+ moveItemInArray(sorts, event.previousIndex, event.currentIndex);
1387
+ });
1388
+ }
1389
+ changeItemSort(item) {
1390
+ item.dir = item.dir == 'asc' ? 'desc' : 'asc';
1391
+ }
1392
+ handleClose() {
1393
+ this.onClosed.emit();
1394
+ }
1395
+ handleResetClick() {
1396
+ this.loader.resetSort();
1397
+ }
1398
+ handleApplyClick() {
1399
+ this.sorts$.pipe(first()).subscribe((data) => {
1400
+ this.loader.updateSort(data);
1401
+ });
1402
+ this.onClosed.emit();
1403
+ }
1404
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionSortingComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1405
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPListViewOptionSortingComponent, selector: "axp-list-view-option-sorting", inputs: { loader: "loader" }, outputs: { onClosed: "onClosed" }, ngImport: i0, template: "<ax-header class=\"ax-flex ax-items-center\">\n <h2 class=\"ax-text-xl ax-font-bold\">Sorts</h2>\n <ax-button (onClick)=\"handleClose()\" [look]=\"'blank'\">\n <ax-icon class=\"fa-solid fa-close ax-text-neutral-400 ax-text-xl\"> </ax-icon>\n </ax-button>\n</ax-header>\n<div\n class=\"ax-flex ax-p-4 ax-flex-col ax-justify-center ax-gap-4 ax-select-none\"\n [class.ax-h-[calc(100vh-310px)]]=\"!(sorts$ | async)?.length\"\n>\n @if(!(sorts$ | async)?.length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Sorts Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\">Please select field(s) that you want to sort</span>\n </div>\n }\n <div\n cdkDropList\n (cdkDropListDropped)=\"drop($event)\"\n class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-py-1 ax-max-h-[calc(100vh-310px)] ax-overflow-auto\"\n >\n <ng-container *ngFor=\"let item of sorts$ | async\">\n <div class=\"ax-flex ax-gap-2 ax-items-center\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <ax-select-box\n [dataSource]=\"(props$ | async) ?? []\"\n valueField=\"name\"\n textField=\"title\"\n [(ngModel)]=\"item.name\"\n >\n </ax-select-box>\n <ax-button [color]=\"'default'\" class=\"ax-sm\" (click)=\"changeItemSort(item)\">\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'asc'\"\n class=\"fa-solid fa-arrow-up-long ax-text-neutral-400\"\n ></ax-icon>\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'desc'\"\n class=\"fa-solid fa-arrow-down-long ax-text-neutral-400\"\n ></ax-icon>\n </ax-button>\n\n <ax-button look=\"blank\" (onClick)=\"loader.removeSort(item)\">\n <ax-icon class=\"fa-solid fa-trash-can ax-text-danger-500\"></ax-icon>\n </ax-button>\n </div>\n </ng-container>\n </div>\n\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if((sorts$ | async)?.length){\n <ax-button (onClick)=\"loader.addSort()\" color=\"primary\" text=\"Add field\" look=\"blank\" class=\"ax-sm\"></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button\n (onClick)=\"loader.addSort()\"\n color=\"primary\"\n text=\"Add field\"\n look=\"outline\"\n class=\"ax-md ax-w-56\"\n ></ax-button>\n </div>\n }\n </div>\n </div>\n</div>\n<ax-footer class=\"!ax-justify-start ax-absolute ax-bottom-0 ax-w-full\">\n <ax-button text=\"Apply\" color=\"primary\" (onClick)=\"handleApplyClick()\"></ax-button>\n <ax-button text=\"Reset\" color=\"ghost\" (onClick)=\"handleResetClick()\"></ax-button>\n</ax-footer>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "component", type: i2$1.AXImageComponent, selector: "ax-image", inputs: ["overlayMode", "src", "alt", "priority", "lazy"], outputs: ["onLoad", "onError"] }, { kind: "component", type: i6.AXSelectBoxComponent, selector: "ax-select-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "minValue", "maxValue", "value", "state", "name", "id", "type", "look", "multiple", "valueField", "textField", "dataSource", "itemTemplate", "emptyTemplate", "loadingTemplate"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange"] }, { kind: "directive", type: i15.CdkDropList, selector: "[cdkDropList], cdk-drop-list", inputs: ["cdkDropListConnectedTo", "cdkDropListData", "cdkDropListOrientation", "id", "cdkDropListLockAxis", "cdkDropListDisabled", "cdkDropListSortingDisabled", "cdkDropListEnterPredicate", "cdkDropListSortPredicate", "cdkDropListAutoScrollDisabled", "cdkDropListAutoScrollStep"], outputs: ["cdkDropListDropped", "cdkDropListEntered", "cdkDropListExited", "cdkDropListSorted"], exportAs: ["cdkDropList"] }, { kind: "directive", type: i15.CdkDrag, selector: "[cdkDrag]", inputs: ["cdkDragData", "cdkDragLockAxis", "cdkDragRootElement", "cdkDragBoundary", "cdkDragStartDelay", "cdkDragFreeDragPosition", "cdkDragDisabled", "cdkDragConstrainPosition", "cdkDragPreviewClass", "cdkDragPreviewContainer"], outputs: ["cdkDragStarted", "cdkDragReleased", "cdkDragEnded", "cdkDragEntered", "cdkDragExited", "cdkDragDropped", "cdkDragMoved"], exportAs: ["cdkDrag"] }, { kind: "directive", type: i15.CdkDragHandle, selector: "[cdkDragHandle]", inputs: ["cdkDragHandleDisabled"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }] }); }
1406
+ }
1407
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewOptionSortingComponent, decorators: [{
1408
+ type: Component,
1409
+ args: [{ selector: 'axp-list-view-option-sorting', template: "<ax-header class=\"ax-flex ax-items-center\">\n <h2 class=\"ax-text-xl ax-font-bold\">Sorts</h2>\n <ax-button (onClick)=\"handleClose()\" [look]=\"'blank'\">\n <ax-icon class=\"fa-solid fa-close ax-text-neutral-400 ax-text-xl\"> </ax-icon>\n </ax-button>\n</ax-header>\n<div\n class=\"ax-flex ax-p-4 ax-flex-col ax-justify-center ax-gap-4 ax-select-none\"\n [class.ax-h-[calc(100vh-310px)]]=\"!(sorts$ | async)?.length\"\n>\n @if(!(sorts$ | async)?.length){\n <div class=\"ax-flex ax-flex-col ax-items-center ax-justify-center\">\n <ax-image src=\"assets/documents.svg\"></ax-image>\n <p class=\"ax-mt-6 ax-mb-1 ax-font-bold\">No Sorts Selected</p>\n <span class=\"ax-text-neutral-400 ax-text-sm md:ax-text-md\">Please select field(s) that you want to sort</span>\n </div>\n }\n <div\n cdkDropList\n (cdkDropListDropped)=\"drop($event)\"\n class=\"ax-flex ax-flex-col ax-gap-3 ax-w-full ax-sorted-list ax-py-1 ax-max-h-[calc(100vh-310px)] ax-overflow-auto\"\n >\n <ng-container *ngFor=\"let item of sorts$ | async\">\n <div class=\"ax-flex ax-gap-2 ax-items-center\" cdkDrag cdkDragBoundary=\".ax-sorted-list\">\n <ax-icon class=\"fa-solid fa-grip-dots-vertical ax-cursor-move\" cdkDragHandle></ax-icon>\n <ax-select-box\n [dataSource]=\"(props$ | async) ?? []\"\n valueField=\"name\"\n textField=\"title\"\n [(ngModel)]=\"item.name\"\n >\n </ax-select-box>\n <ax-button [color]=\"'default'\" class=\"ax-sm\" (click)=\"changeItemSort(item)\">\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'asc'\"\n class=\"fa-solid fa-arrow-up-long ax-text-neutral-400\"\n ></ax-icon>\n <ax-icon\n [class.ax-text-primary]=\"item.dir == 'desc'\"\n class=\"fa-solid fa-arrow-down-long ax-text-neutral-400\"\n ></ax-icon>\n </ax-button>\n\n <ax-button look=\"blank\" (onClick)=\"loader.removeSort(item)\">\n <ax-icon class=\"fa-solid fa-trash-can ax-text-danger-500\"></ax-icon>\n </ax-button>\n </div>\n </ng-container>\n </div>\n\n <div class=\"ax-flex ax-gap-2\">\n <div class=\"ax-w-full\" #addField>\n @if((sorts$ | async)?.length){\n <ax-button (onClick)=\"loader.addSort()\" color=\"primary\" text=\"Add field\" look=\"blank\" class=\"ax-sm\"></ax-button>\n }@else {\n <div class=\"ax-flex ax-justify-center ax-w-full\">\n <ax-button\n (onClick)=\"loader.addSort()\"\n color=\"primary\"\n text=\"Add field\"\n look=\"outline\"\n class=\"ax-md ax-w-56\"\n ></ax-button>\n </div>\n }\n </div>\n </div>\n</div>\n<ax-footer class=\"!ax-justify-start ax-absolute ax-bottom-0 ax-w-full\">\n <ax-button text=\"Apply\" color=\"primary\" (onClick)=\"handleApplyClick()\"></ax-button>\n <ax-button text=\"Reset\" color=\"ghost\" (onClick)=\"handleResetClick()\"></ax-button>\n</ax-footer>\n" }]
1410
+ }], propDecorators: { onClosed: [{
1411
+ type: Output
1412
+ }], loader: [{
1413
+ type: Input
1414
+ }] } });
1415
+
1416
+ const AXPEntityQuickViewAction = createAction('[Entity] QuickView', props());
1417
+ //
1418
+ const AXPEntityListViewAction = createAction('[Entity] ListView', props());
1419
+ //
1420
+ const AXPEntityDetailViewAction = createAction('[Entity] DetailView', props());
1421
+ const AXPEntityReloadAction = createAction('[Entity] Reload', props());
1422
+ //
1423
+ //
1424
+ // export const AXPEntityCreateAction = createAction('[Entity] Create', props<{ payload: { module: string, entity: string } }>());
1425
+ // export const AXPEntityCreatedAction = createAction('[Entity] Created', props<{ payload: { module: string, entity: string, id: string } }>());
1426
+ //
1427
+ // export const AXPEntityDeleteAction = createAction('[Entity] Delete', props<{ payload: { module: string, entity: string, ids: string[] } }>());
1428
+ // export const AXPEntityDeletedAction = createAction('[Entity] Deleted', props<{ payload: { module: string, entity: string, id: string } }>());
1429
+ // export const AXPEntityBulkDeletedAction = createAction('[Entity] Bulk Deleted', props<{ payload: { module: string, entity: string } }>());
1430
+ // export const AXPEntityModifyAction = createAction('[Entity] Modify', props<{ payload: { module: string, entity: string, context:any, properties:any } }>());
1431
+ // export const AXPEntityModifiedAction = createAction('[Entity] Modified', props<{ payload: { module: string, entity: string, id:string } }>());
1432
+
1433
+ class AXPEntityCreateLoaderDefault {
1434
+ constructor(config, store, formatService) {
1435
+ this.config = config;
1436
+ this.store = store;
1437
+ this.formatService = formatService;
1438
+ this._data = {};
1439
+ this._currentSection = 'default';
1440
+ this._sections$ = new BehaviorSubject(this.sections);
1441
+ //****************** Properties ******************//
1442
+ this.getProp = (name) => this.entity.properties.find((c) => c.name == name);
1443
+ this.isRequired = (name) => this.getProp(name)?.validationRules?.some(c => c.rule == 'required') || false;
1444
+ this._currentSection = this.sections[0]?.name || 'default';
1445
+ }
1446
+ get entity() {
1447
+ if (!this._config) {
1448
+ this._config = cloneDeep(this.config);
1449
+ }
1450
+ return this._config;
1451
+ }
1452
+ get data() {
1453
+ return this._data;
1454
+ }
1455
+ get view() {
1456
+ return this.entity.views.createView;
1457
+ }
1458
+ //****************** Sections ******************//
1459
+ get sections() {
1460
+ return this.view.root.sections?.length
1461
+ ? this.view.root.sections
1462
+ : [
1463
+ {
1464
+ name: 'default',
1465
+ title: 'Default',
1466
+ properties: this.view.root.properties,
1467
+ },
1468
+ ];
1469
+ }
1470
+ get sections$() {
1471
+ return this._sections$.pipe(defaultIfEmpty([]));
1472
+ }
1473
+ get section$() {
1474
+ return this.sections$.pipe(switchMap((sections) => {
1475
+ const section = sections.find((c) => c.name === this._currentSection) ?? this.sections[0];
1476
+ if (!section.sections?.length) {
1477
+ section.sections = [
1478
+ {
1479
+ name: 'default',
1480
+ title: 'Details',
1481
+ properties: section.properties,
1482
+ },
1483
+ ];
1484
+ }
1485
+ return of(section);
1486
+ }));
1487
+ }
1488
+ get hasSections$() {
1489
+ return this.sections$.pipe(map((c) => c.length > 1));
1490
+ }
1491
+ get isLast$() {
1492
+ return this.sections$.pipe(map((c) => this.sections.length - this.sections.findIndex((c) => c.name == this._currentSection) == 1));
1493
+ }
1494
+ get isFirst$() {
1495
+ return this.sections$.pipe(map((c) => this.sections.findIndex((c) => c.name == this._currentSection) == 0));
1496
+ }
1497
+ get currentIndex$() {
1498
+ return this.sections$.pipe(map((c) => this.sections.findIndex((c) => c.name == this._currentSection)));
1499
+ }
1500
+ setSection(name) {
1501
+ this._currentSection = name ?? 'default';
1502
+ const updatedSection = this.sections.find((c) => c.name === this._currentSection) || {
1503
+ name: 'default',
1504
+ title: 'Default',
1505
+ properties: this.view.root.properties,
1506
+ };
1507
+ const currentSections = this._sections$.value;
1508
+ const updatedSections = currentSections.map((section) => {
1509
+ if (section.name === updatedSection.name) {
1510
+ return updatedSection;
1511
+ }
1512
+ else {
1513
+ return section;
1514
+ }
1515
+ });
1516
+ this._sections$.next(updatedSections);
1517
+ }
1518
+ next() {
1519
+ const nextIndex = this.sections.findIndex((c) => c.name == this._currentSection) + 1;
1520
+ if (nextIndex >= this.sections.length) {
1521
+ return Promise.resolve();
1522
+ }
1523
+ else {
1524
+ this.setSection(this.sections[nextIndex].name);
1525
+ return Promise.resolve();
1526
+ }
1527
+ }
1528
+ back() {
1529
+ const prevIndex = this.sections.findIndex((c) => c.name == this._currentSection) - 1;
1530
+ if (prevIndex < 0) {
1531
+ return Promise.resolve();
1532
+ }
1533
+ else {
1534
+ this.setSection(this.sections[prevIndex].name);
1535
+ return Promise.resolve();
1536
+ }
1537
+ }
1538
+ }
1539
+ class AXPEntityCreateViewLoaderFactory {
1540
+ constructor() {
1541
+ this.entityService = inject(AXPEntityRegistryService);
1542
+ this.formatService = inject(AXFormatService);
1543
+ this.layout = inject(AXPLayoutService);
1544
+ this.store = inject(Store);
1545
+ }
1546
+ async create(moduleName, entityName) {
1547
+ const config = await this.entityService.resolve(moduleName, entityName);
1548
+ this.layout.setNavigationLoading(true);
1549
+ if (config.dataSource.byKey) {
1550
+ this.layout.setNavigationLoading(false);
1551
+ return new AXPEntityCreateLoaderDefault(config, this.store, this.formatService);
1552
+ }
1553
+ return Promise.reject('cannot fetch ');
1554
+ }
1555
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreateViewLoaderFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1556
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreateViewLoaderFactory, providedIn: 'root' }); }
1557
+ }
1558
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreateViewLoaderFactory, decorators: [{
1559
+ type: Injectable,
1560
+ args: [{ providedIn: 'root' }]
1561
+ }] });
1562
+
1563
+ const AXPEntityCreateEvent = createWorkFlowEvent('[Entity] Created!');
1564
+ class AXPEntityCreatePopupAction extends AXPWorkflowAction {
1565
+ constructor() {
1566
+ super(...arguments);
1567
+ this.entityRegistery = inject(AXPEntityRegistryService);
1568
+ this.popupService = inject(AXPopupService);
1569
+ this.platform = inject(AXPlatform);
1570
+ this.entityCreateFactory = inject(AXPEntityCreateViewLoaderFactory);
1571
+ }
1572
+ async execute(context) {
1573
+ const { module, entity: entityName } = context.getVariable('payload');
1574
+ const entity = await this.entityRegistery.resolve(module, entityName);
1575
+ const com = await import('./acorex-platform-layouts-entity-create-view.component-8rtifIvM.mjs');
1576
+ const result = await this.popupService.open(com.AXPEntityCreateViewComponent, {
1577
+ title: `Create New ${entity.title}`,
1578
+ size: this.platform.is('Mobile') || this.platform.is('SM') ? 'full' : 'md',
1579
+ data: {
1580
+ loader: await this.entityCreateFactory.create(module, entityName),
1581
+ entity,
1582
+ },
1583
+ });
1584
+ if (result.data?.save) {
1585
+ context.setOutput('popupResult', true);
1586
+ context.setVariable('redirect', result.data.redirect);
1587
+ context.setVariable('id', result.data.recordId);
1588
+ }
1589
+ }
1590
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreatePopupAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
1591
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreatePopupAction }); }
1592
+ }
1593
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityCreatePopupAction, decorators: [{
1594
+ type: Injectable
1595
+ }] });
1596
+ class AXPEntityCreateSubmittedAction extends AXPWorkflowAction {
1597
+ async execute(context) {
1598
+ const { module, entity: entity } = context.getVariable('payload');
1599
+ this.dispatch(AXPEntityCreateEvent({ entity, module }));
1600
+ }
1601
+ }
1602
+ const AXPCreateEntityWorkflow = {
1603
+ startStepId: 'createPopup',
1604
+ steps: {
1605
+ createPopup: {
1606
+ id: 'createPopup',
1607
+ action: 'AXPEntityCreatePopupAction',
1608
+ nextSteps: [
1609
+ {
1610
+ conditions: [{ type: 'SINGLE', expression: 'context.getOutput("popupResult") == true' }],
1611
+ nextStepId: 'successToast',
1612
+ },
1613
+ ],
1614
+ },
1615
+ successToast: {
1616
+ id: 'successToast',
1617
+ action: 'AXPToastAction',
1618
+ input: {
1619
+ color: 'success',
1620
+ title: 'Entity Created',
1621
+ content: 'New Record has been successfully created.',
1622
+ },
1623
+ nextSteps: [
1624
+ {
1625
+ conditions: [],
1626
+ nextStepId: 'createSubmitted',
1627
+ },
1628
+ ],
1629
+ },
1630
+ createSubmitted: {
1631
+ id: 'createSubmitted',
1632
+ action: 'AXPEntityCreateSubmittedAction',
1633
+ nextSteps: [
1634
+ {
1635
+ conditions: [{ type: 'SINGLE', expression: 'context.getVariable("redirect") == true' }],
1636
+ nextStepId: 'showDetailView',
1637
+ },
1638
+ ],
1639
+ },
1640
+ showDetailView: {
1641
+ id: 'showDetailView',
1642
+ action: 'AXPShowDetailViewAction',
1643
+ },
1644
+ },
1645
+ };
1646
+
1647
+ const AXPEntityDeletedEvent = createWorkFlowEvent('[Entity] Deleted');
1648
+ class AXPEntityPerformDeleteAction extends AXPWorkflowAction {
1649
+ constructor() {
1650
+ super(...arguments);
1651
+ this.entityRegistery = inject(AXPEntityRegistryService);
1652
+ this.dialogService = inject(AXDialogService);
1653
+ this.loadingDialog = inject(AXLoadingDialogService);
1654
+ }
1655
+ async execute(context) {
1656
+ const moduleName = context.getVariable('module');
1657
+ const entityName = context.getVariable('entity');
1658
+ const ids = context.getVariable('ids');
1659
+ const entity = await this.entityRegistery.resolve(moduleName, entityName);
1660
+ let deletedCount = 0;
1661
+ context.setVariable('deleteSuccessful', false);
1662
+ const dialog = this.loadingDialog.show({
1663
+ title: 'Deleting Record...',
1664
+ mode: 'determinate',
1665
+ status: 'Deleting...',
1666
+ progressValue: 0,
1667
+ text: `0/${ids.length}`,
1668
+ buttons: [
1669
+ {
1670
+ text: 'Cancel',
1671
+ color: 'danger',
1672
+ onClick: () => {
1673
+ dialog.close();
1674
+ },
1675
+ },
1676
+ ],
1677
+ });
1678
+ if (entity.commands?.delete != null) {
1679
+ const wrappedPromises = ids
1680
+ .map((id, i) => {
1681
+ return new Promise((resolve) => {
1682
+ setTimeout(() => {
1683
+ resolve(entity.commands?.delete?.(id));
1684
+ }, i * 200);
1685
+ });
1686
+ })
1687
+ .map((p) => p?.then((value) => {
1688
+ deletedCount++;
1689
+ dialog.setProgressText(`${deletedCount}/${ids.length}`);
1690
+ dialog.setProgressValue((deletedCount / ids.length) * 100);
1691
+ return { status: 'fulfilled', value };
1692
+ }, (reason) => ({ status: 'rejected', reason })));
1693
+ const results = await Promise.all(wrappedPromises);
1694
+ const successfulPromises = results.filter((result) => result?.status === 'fulfilled').length;
1695
+ const failedPromises = results.filter((result) => result?.status === 'rejected').length;
1696
+ setTimeout(() => {
1697
+ dialog.close();
1698
+ }, 300);
1699
+ // Handle different scenarios for alerts
1700
+ if (successfulPromises > 0 && failedPromises === 0) {
1701
+ // All items deleted successfully
1702
+ await this.dialogService.alert('Deletion Successful', `${successfulPromises} item(s) has been deleted.`, 'success');
1703
+ // Dispatch actions
1704
+ this.dispatch(AXPEntityDeletedEvent({ module: moduleName, entity: entityName, id: ids }));
1705
+ }
1706
+ else if (successfulPromises > 0 && failedPromises > 0) {
1707
+ // Some items deleted successfully, some failed
1708
+ await this.dialogService.alert('Partial Deletion Completed', `${successfulPromises} item(s) deleted successfully. However, ${failedPromises} item(s) could not be deleted.`, 'warning');
1709
+ // Dispatch actions
1710
+ this.dispatch(AXPEntityDeletedEvent({ module: moduleName, entity: entityName, id: ids }));
1711
+ }
1712
+ else if (successfulPromises === 0 && failedPromises > 0) {
1713
+ // No items deleted, all failed
1714
+ await this.dialogService.alert('Deletion Failed', `No items were deleted. ${failedPromises} item(s) failed to delete.`, 'danger');
1715
+ }
1716
+ else {
1717
+ // No items to delete (no successful or failed promises)
1718
+ await this.dialogService.alert('No Deletion Needed', 'No items were available to delete.', 'info');
1719
+ }
1720
+ }
1721
+ else {
1722
+ throw new Error(`The delete operation cannot be performed on ${entity.title}. This action might be restricted or not applicable for the selected item.`);
1723
+ }
1724
+ }
1725
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityPerformDeleteAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
1726
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityPerformDeleteAction }); }
1727
+ }
1728
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityPerformDeleteAction, decorators: [{
1729
+ type: Injectable
1730
+ }] });
1731
+ class AXPMyCustomFunc extends AXPWorkflowFunction {
1732
+ constructor() {
1733
+ super(...arguments);
1734
+ this.entityRegistery = inject(AXPEntityRegistryService);
1735
+ this.dialogService = inject(AXDialogService);
1736
+ }
1737
+ async execute(val) {
1738
+ return val == 'abc';
1739
+ }
1740
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPMyCustomFunc, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
1741
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPMyCustomFunc }); }
1742
+ }
1743
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPMyCustomFunc, decorators: [{
1744
+ type: Injectable
1745
+ }] });
1746
+ const AXPDeleteEntityWorkflow = {
1747
+ startStepId: 'confirmDelete',
1748
+ steps: {
1749
+ confirmDelete: {
1750
+ id: 'confirmDelete',
1751
+ action: 'AXPDialogConfirmAction',
1752
+ input: {
1753
+ title: 'Warning',
1754
+ message: `Are you sure want to delete selected item(s)?`,
1755
+ type: 'danger',
1756
+ },
1757
+ nextSteps: [
1758
+ {
1759
+ conditions: [
1760
+ {
1761
+ type: 'AND',
1762
+ conditions: [
1763
+ { type: 'SINGLE', expression: 'context.getOutput("deleteConfirmed") == true' },
1764
+ { type: 'SINGLE', expression: 'await test("abc")' },
1765
+ ],
1766
+ },
1767
+ ],
1768
+ nextStepId: 'performDelete',
1769
+ },
1770
+ ],
1771
+ },
1772
+ // loadingDialog: {
1773
+ // id: 'loadingDialog',
1774
+ // action: 'AXPDeleteLoadingDialogAction',
1775
+ // input: {
1776
+ // title: 'Warning',
1777
+ // message: `Are you sure want to delete selected item(s)?`,
1778
+ // type: 'danger',
1779
+ // },
1780
+ // nextSteps: [
1781
+ // {
1782
+ // conditions: [{ type: 'SINGLE', expression: 'context.getOutput("deleteDone") == true' }],
1783
+ // nextStepId: 'performDelete',
1784
+ // },
1785
+ // ],
1786
+ // },
1787
+ performDelete: {
1788
+ id: 'performDelete',
1789
+ action: 'AXPEntityPerformDeleteAction',
1790
+ },
1791
+ },
1792
+ };
1793
+
1794
+ class AXPEntityListViewComponent {
1795
+ constructor(actionSheetService, unsubscriber, platform, cdr) {
1796
+ this.actionSheetService = actionSheetService;
1797
+ this.unsubscriber = unsubscriber;
1798
+ this.platform = platform;
1799
+ this.cdr = cdr;
1800
+ this.store = inject((Store));
1801
+ this.workflow = inject(AXPWorkflowService);
1802
+ this.layout = inject(AXPLayoutService);
1803
+ this.route = inject(ActivatedRoute);
1804
+ this.manuLoader = inject(AXP_MENU_LOADER);
1805
+ this.loader = this.route.snapshot.data['loader'];
1806
+ this.title = '';
1807
+ this.searchValue = '';
1808
+ this.searchBoxPlaceholder = '';
1809
+ this.searchBoxTitle = '';
1810
+ this.searchBoxCollapsed = true;
1811
+ this.publicViews$ = this.loader.publicViews$;
1812
+ this.customViews$ = this.loader.customViews$;
1813
+ this.hasCustomViews$ = this.loader.hasCustomViews$;
1814
+ this.view$ = this.loader.view$;
1815
+ //
1816
+ this.conditions$ = this.loader.conditions$;
1817
+ this.conditionsCount$ = this.loader.conditionsCount$;
1818
+ //
1819
+ this.columns$ = this.loader.displayColumns$;
1820
+ this.columnsCount$ = this.loader.displayColumnsCount$;
1821
+ //
1822
+ this.sort$ = this.loader.sorts$;
1823
+ this.sortCount$ = this.loader.sortsCount$;
1824
+ //
1825
+ this.dataSource = this.loader.dataSource;
1826
+ this.popupService = inject(AXPopupService);
1827
+ this.dropdownRowItems = [
1828
+ {
1829
+ text: 'Edit',
1830
+ icon: 'fa-solid fa-floppy-disk',
1831
+ name: 'edit',
1832
+ divided: true,
1833
+ },
1834
+ {
1835
+ text: 'Delete',
1836
+ icon: 'fa-solid fa-trash-can',
1837
+ name: 'delete',
1838
+ color: 'danger',
1839
+ },
1840
+ ];
1841
+ this.inlineRowItems = [
1842
+ {
1843
+ text: 'View',
1844
+ icon: 'fa-solid fa-eye',
1845
+ name: 'view',
1846
+ divided: true,
1847
+ },
1848
+ ];
1849
+ this.getDropdownRowItems = (rowData) => {
1850
+ return Promise.resolve(this.dropdownRowItems);
1851
+ };
1852
+ this.getInlineRowItems = (rowData) => {
1853
+ return this.inlineRowItems;
1854
+ };
1855
+ this.log = () => console.log('abc');
1856
+ //TODO: namespace, module name issues
1857
+ this.title = this.manuLoader.currentMenuItem()?.text ?? '';
1858
+ this.loader.views$.pipe(this.unsubscriber.takeUntilDestroy).subscribe(() => {
1859
+ this.grid?.render();
1860
+ });
1861
+ //
1862
+ this.workflow.events$
1863
+ .pipe(ofType$1(AXPEntityDeletedEvent, AXPEntityCreateEvent), this.unsubscriber.takeUntilDestroy)
1864
+ .subscribe((event) => {
1865
+ if (event.payload.entity == this.loader.entity.name && event.payload.module == this.loader.entity.module) {
1866
+ this.grid.selectedRows = [];
1867
+ this.grid?.refresh();
1868
+ }
1869
+ });
1870
+ //
1871
+ this.dataSource.onLoadingChanged.pipe(this.unsubscriber.takeUntilDestroy).subscribe((value) => {
1872
+ this.layout.setNavigationLoading(value);
1873
+ });
1874
+ this._getInlineConditionTitles();
1875
+ }
1876
+ _getInlineConditionTitles() {
1877
+ const titles = this.loader.getInlineFilterTitles();
1878
+ this.searchBoxTitle = titles.join(', ');
1879
+ if (titles.length > 2)
1880
+ this.searchBoxPlaceholder = titles.slice(0, 2).join(', ') + ' ...';
1881
+ else
1882
+ this.searchBoxPlaceholder = titles.join(', ');
1883
+ }
1884
+ _handleViewsPopover() {
1885
+ this.actionSheetService.open({ content: this.viewsTemplate });
1886
+ }
1887
+ handleDrawerClick() {
1888
+ this.store.dispatch(AXPLayoutChildDrawerToggle());
1889
+ }
1890
+ toggleSearchBox() {
1891
+ this.searchBoxCollapsed = !this.searchBoxCollapsed;
1892
+ }
1893
+ handleRowDbClick(e) {
1894
+ const d = {
1895
+ component: e.component,
1896
+ name: this.dropdownRowItems[0].name,
1897
+ data: e.data,
1898
+ };
1899
+ this.handleRowCommandClick(d);
1900
+ }
1901
+ async handleRowCommandClick(e) {
1902
+ switch (e.name) {
1903
+ case 'view': {
1904
+ this.store.dispatch(AXPEntityQuickViewAction({
1905
+ payload: {
1906
+ module: this.loader.entity.module,
1907
+ entity: this.loader.entity.name,
1908
+ data: e.data,
1909
+ },
1910
+ }));
1911
+ break;
1912
+ }
1913
+ case 'edit': {
1914
+ this.store.dispatch(AXPEntityDetailViewAction({
1915
+ payload: {
1916
+ module: this.loader.entity.module,
1917
+ entity: this.loader.entity.name,
1918
+ id: e.data.id,
1919
+ },
1920
+ }));
1921
+ break;
1922
+ }
1923
+ case 'delete': {
1924
+ await this.workflow.execute('delete-entity', {
1925
+ module: this.loader.entity.module,
1926
+ entity: this.loader.entity.name,
1927
+ ids: [e.data.id],
1928
+ });
1929
+ break;
1930
+ }
1931
+ }
1932
+ }
1933
+ handleCreateClick() {
1934
+ this.workflow.execute('create-entity', {
1935
+ payload: {
1936
+ module: this.loader.entity.module,
1937
+ entity: this.loader.entity.name,
1938
+ },
1939
+ });
1940
+ }
1941
+ handleCommandClick(command) {
1942
+ switch (command) {
1943
+ case 'delete':
1944
+ this.workflow.execute('delete-entity', {
1945
+ module: this.loader.entity.module,
1946
+ entity: this.loader.entity.name,
1947
+ ids: this.grid.selectedRows.map((c) => c['id']),
1948
+ });
1949
+ break;
1950
+ default:
1951
+ break;
1952
+ }
1953
+ }
1954
+ clearSelectedItems() {
1955
+ this.grid.selectedRows = [];
1956
+ this.grid?.render();
1957
+ }
1958
+ closeDrawer(name, collapsed) {
1959
+ if (collapsed != false) {
1960
+ switch (name) {
1961
+ case 'conditions':
1962
+ this.loader.resetConditions();
1963
+ break;
1964
+ case 'columns':
1965
+ this.loader.resetColumns();
1966
+ break;
1967
+ case 'sorts':
1968
+ this.loader.resetSort();
1969
+ break;
1970
+ default:
1971
+ break;
1972
+ }
1973
+ }
1974
+ }
1975
+ handleChangeSearchValue(e) {
1976
+ if (e.isUserInteraction) {
1977
+ this.loader.handleInlineSearch(e.value);
1978
+ }
1979
+ }
1980
+ async addCustomViewPopup() {
1981
+ const newView = {
1982
+ name: 'custom-view',
1983
+ title: 'Custom View',
1984
+ fixed: false,
1985
+ sorts: [],
1986
+ columns: convertPropertiesToColumns(...this.loader.entity.properties),
1987
+ conditions: [],
1988
+ };
1989
+ const popup = await this.popupService.open(AXPEntityCreateCustomViewComponent, {
1990
+ title: 'Create Custom View',
1991
+ size: this.platform.is('Mobile') || this.platform.is('SM') ? 'full' : 'md',
1992
+ closeOnBackdropClick: true,
1993
+ draggable: false,
1994
+ data: {
1995
+ loader: this.loader,
1996
+ selectedView: newView,
1997
+ mode: 'create',
1998
+ },
1999
+ });
2000
+ if (popup.data?.save == true) {
2001
+ console.log('updatedView: ', popup.data.updatedView);
2002
+ this.loader.createView(popup.data.updatedView);
2003
+ }
2004
+ }
2005
+ async updateViewPopup(e, selectedView) {
2006
+ // (e.nativeEvent as UIEvent).stopPropagation();
2007
+ const popup = await this.popupService.open(AXPEntityCreateCustomViewComponent, {
2008
+ title: 'Modify Custom View',
2009
+ size: this.platform.is('Mobile') || this.platform.is('SM') ? 'full' : 'md',
2010
+ closeOnBackdropClick: true,
2011
+ draggable: false,
2012
+ data: {
2013
+ loader: this.loader,
2014
+ selectedView,
2015
+ mode: 'edit',
2016
+ },
2017
+ });
2018
+ if (popup.data?.delete == true) {
2019
+ this.loader.deleteView(popup.data.viewName);
2020
+ }
2021
+ if (popup.data?.save == true) {
2022
+ console.log('updatedView: ', popup.data.updatedView);
2023
+ this.loader.updateView(popup.data.updatedView);
2024
+ }
2025
+ }
2026
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityListViewComponent, deps: [{ token: i1$4.AXActionSheetService }, { token: i2$3.AXUnsubscriber }, { token: i3$2.AXPlatform }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component }); }
2027
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPEntityListViewComponent, selector: "ng-component", providers: [AXUnsubscriber], viewQueries: [{ propertyName: "viewsTemplate", first: true, predicate: ["viewsTemplate"], descendants: true }, { propertyName: "grid", first: true, predicate: ["grid"], descendants: true }, { propertyName: "entityViewDrawer", first: true, predicate: ["entityViewDrawer"], descendants: true }], ngImport: i0, template: "<ax-drawer-container>\n <!-- <ax-drawer #drawer location=\"start\" [collapsed]=\"true\" [mode]=\"platform.is('SM') ? 'overlay' : 'push'\">\n <ax-content class=\"ax-w-64 ax-border-e\">\n <div class=\"ax-p-6 ax-py-4 ax-gap-6 ax-flex ax-flex-col\">\n <p class=\"ax-text-2xl ax-font-bold\">Folders</p>\n <ax-side-menu>\n <ng-container *ngFor=\"let node of menuItems\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: node }\">\n </ng-container>\n </ax-side-menu>\n <ng-template #sideMenu let-item>\n <ax-side-menu-item [text]=\"item.text\">\n <ax-prefix>\n <ax-icon class=\"fa-solid fa-folder ax-text-warning-500\"></ax-icon>\n </ax-prefix>\n <ng-container *ngIf=\"item.children\">\n <ng-container *ngFor=\"let child of item.children\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: child }\">\n </ng-container>\n </ng-container>\n </ax-side-menu-item>\n </ng-template>\n </div>\n </ax-content>\n </ax-drawer> -->\n <ax-content class=\"ax-flex ax-flex-col ax-overflow-hidden\">\n <div\n class=\"ax-flex ax-flex-col ax-gap-0 md:ax-gap-4 ax-px-4 ax-py-3 md:ax-py-4 md:ax-px-6 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\">\n @if(platform.is('MD')){\n <div class=\"ax-flex ax-justify-between ax-mb-4\">\n @if(this.grid?.selectedRows?.length==0){\n <div class=\"ax-text-xl ax-font-bold\">{{ title }}</div>\n <div class=\"ax-flex ax-items-center ax-gap-2\">\n <ax-button color=\"primary\" class=\"ax-sm\" (onClick)=\"handleCreateClick()\">\n <ax-icon class=\"fa-solid fa-add\"></ax-icon>\n </ax-button>\n <ax-button color=\"ghost\" class=\"ax-sm\" #more>\n <ax-icon class=\"fa-solid fa-ellipsis-vertical\"> </ax-icon>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list>\n <ax-button-item text=\"Export\" class=\"ax-font-semibold\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-file-export\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n </div>\n }@else {\n <div class=\"ax-flex ax-items-center ax-gap-3\">\n <span class=\"ax-text-xl ax-font-bold\"> {{ this.grid?.selectedRows?.length }} Items Selected </span>\n <span (click)=\"clearSelectedItems()\"\n class=\"ax-text-sm ax-text-primary dark:ax-text-primary-300 ax-underline ax-cursor-pointer\">Clear\n Items</span>\n </div>\n <div class=\"ax-flex ax-items-center ax-gap-2\">\n <ax-button color=\"danger\" class=\"ax-sm\" (onClick)=\"handleCommandClick('delete')\">\n <ax-icon class=\"fa-solid fa-trash\"> </ax-icon>\n </ax-button>\n <ax-button color=\"ghost\" class=\"ax-sm\" #more>\n <ax-icon class=\"fa-solid fa-ellipsis-vertical\"> </ax-icon>\n </ax-button>\n </div>\n }\n </div>\n\n <div class=\"ax-flex ax-items-center ax-justify-between\">\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" [text]=\"(view$ | async)?.title\" color=\"ghost\">\n <ax-icon class=\"fa-solid fa-eye ax-text-neutral-400\"> </ax-icon>\n <ax-suffix>\n <i class=\"fa-solid fa-caret-down\"></i>\n </ax-suffix>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list class=\"ax-bg-surface\">\n <ax-title class=\"ax-font-bold ax-opacity-100\">Public Views</ax-title>\n <ax-button-item *ngFor=\"let v of publicViews$ | async\" [text]=\"v.title\"\n [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\"></ax-button-item>\n <ax-title class=\"ax-font-bold ax-opacity-100\" *ngIf=\"hasCustomViews$ | async\">Created by me</ax-title>\n <ax-button-item *ngFor=\"let v of customViews$ | async\" [text]=\"v.title\"\n [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\"></ax-button-item>\n <ax-divider></ax-divider>\n <ax-button-item (onClick)=\"addCustomViewPopup()\" text=\"Add Custom View\"\n class=\"ax-font-semibold ax-text-primary\"></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n <div class=\"ax-flex ax-gap-2\">\n @if(searchBoxTitle){\n <ax-button (onClick)=\"toggleSearchBox()\" [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\">\n <ax-icon class=\"fa-solid fa-search ax-text-neutral-400\"> </ax-icon>\n </ax-button>\n }\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\" (onClick)=\"columnsDrawer.open()\">\n <ax-icon class=\"fa-solid fa-bars ax-text-neutral-400\"> </ax-icon>\n </ax-button>\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\"\n (onClick)=\"conditionsDrawer.open()\">\n <ax-icon class=\"fa-solid fa-sliders ax-text-neutral-400\"> </ax-icon>\n @if ((conditionsCount$ | async)) {\n <ax-suffix>\n <ax-badge [color]=\"'primary'\"></ax-badge>\n </ax-suffix>\n }\n </ax-button>\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\" (onClick)=\"sortsDrawer.open()\">\n <ax-icon class=\"fa-solid fa-bars-sort ax-text-neutral-400\"> </ax-icon>\n @if ((sortCount$ | async)) {\n <ax-suffix>\n <ax-badge [color]=\"'primary'\"></ax-badge>\n </ax-suffix>\n }\n </ax-button>\n </div>\n </div>\n <div [class.collapsed-search-box]=\"searchBoxCollapsed\" class=\"ax-transition-all ax-mt-4\">\n <ax-search-box [title]=\"searchBoxTitle\"\n [placeholder]=\"'Search on ' + searchBoxPlaceholder\"><ax-clear-button></ax-clear-button></ax-search-box>\n </div>\n } @else {\n <div class=\"ax-flex ax-items-center ax-justify-between ax-gap-3\">\n <div class=\"ax-text-xl md:ax-text-3xl ax-font-bold ax-mb-2\">{{ title }}</div>\n @if(this.grid?.selectedRows?.length==0){\n <div class=\"ax-flex ax-gap-3\">\n <ax-button text=\"Create New\" color=\"primary\" (onClick)=\"handleCreateClick()\">\n <ax-prefix>\n <i class=\"fa-solid fa-add\"></i>\n </ax-prefix>\n </ax-button>\n <ax-button text=\"Actions\" color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis-vertical\"></i>\n </ax-prefix>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list>\n <ax-button-item text=\"Export\" class=\"ax-font-semibold\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-file-export\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n </div>\n }@else {\n <div class=\"ax-flex ax-gap-3\">\n <ax-button text=\"Delete Items\" color=\"danger\" (onClick)=\"handleCommandClick('delete')\">\n <ax-prefix>\n <i class=\"fa-solid fa-trash\"></i>\n </ax-prefix>\n </ax-button>\n <ax-button text=\"Actions\" color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis-vertical\"></i>\n </ax-prefix>\n </ax-button>\n </div>\n }\n </div>\n <div class=\"ax-flex ax-items-center ax-justify-between\">\n <!----------------------- View Mode --------------------->\n @if(this.grid?.selectedRows?.length==0) {\n <div class=\"ax-flex ax-w-full ax-justify-between ax-gap-3\">\n <div class=\"ax-flex ax-gap-3\">\n <ax-button [text]=\"(view$ | async)?.title\" #views color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-eye\"></i>\n </ax-prefix>\n <ax-suffix>\n <i class=\"fa-solid fa-caret-down\"></i>\n </ax-suffix>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list class=\"ax-bg-surface\">\n <ax-title class=\"ax-font-bold ax-opacity-100\">Public Views</ax-title>\n <ax-button-item *ngFor=\"let v of publicViews$ | async\" [text]=\"v.title\"\n [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\"></ax-button-item>\n <ax-title class=\"ax-font-bold ax-opacity-100\" *ngIf=\"hasCustomViews$ | async\">Created by me</ax-title>\n <ax-button-item class=\"ax-pe-4 ax-flex ax-justify-between\" *ngFor=\"let v of customViews$ | async\"\n [text]=\"v.title\" [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\">\n <ax-suffix>\n <ax-button (onClick)=\"updateViewPopup($event, v)\" class=\"ax-xs\" look=\"none\">\n <ax-icon class=\"far fa-edit\"> </ax-icon>\n </ax-button>\n </ax-suffix>\n </ax-button-item>\n <ax-divider></ax-divider>\n <ax-button-item text=\"Add Custom View\" (onClick)=\"addCustomViewPopup()\"\n class=\"ax-font-semibold ax-text-primary\"></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n @if(searchBoxTitle){\n <div class=\"ax-w-72\">\n <ax-search-box [title]=\"searchBoxTitle\" [(ngModel)]=\"searchValue\"\n (onValueChanged)=\"handleChangeSearchValue($event)\"\n [placeholder]=\"'Search on ' + searchBoxPlaceholder\"><ax-clear-button></ax-clear-button></ax-search-box>\n </div>\n }\n </div>\n\n <div class=\"ax-flex ax-gap-3\">\n <ax-button text=\"Columns\" color=\"ghost\" #columns (onClick)=\"columnsDrawer.open()\">\n <ax-prefix>\n <i class=\"fa-solid fa-bars\"></i>\n </ax-prefix>\n <ax-suffix>\n <ax-badge text=\"{{ columnsCount$ | async }}\" color=\"primary\"></ax-badge>\n </ax-suffix>\n </ax-button>\n <ax-button text=\"Conditions\" color=\"ghost\" (onClick)=\"conditionsDrawer.open()\" #conditions>\n <ax-prefix>\n <i class=\"fa-solid fa-sliders\"></i>\n </ax-prefix>\n <ax-suffix>\n <ax-badge text=\"{{ conditionsCount$ | async }}\" color=\"primary\"></ax-badge>\n </ax-suffix>\n </ax-button>\n <ax-button text=\"Sort\" color=\"ghost\" (onClick)=\"sortsDrawer.open()\">\n <ax-prefix>\n <i class=\"fa-solid fa-bars-sort\"></i>\n </ax-prefix>\n <ax-suffix *ngIf=\"(sortCount$ | async)! > 0\">\n <ax-badge text=\"{{ sortCount$ | async }}\" color=\"primary\"></ax-badge>\n </ax-suffix>\n </ax-button>\n </div>\n </div>\n\n } @else{\n <!----------------------- Selection Mode --------------------->\n <div>\n <div class=\"ax-flex ax-gap-3 ax-items-center\">\n <span class=\"ax-text-xl ax-font-bold\"> {{ this.grid?.selectedRows?.length }} Items Selected </span>\n <span (click)=\"clearSelectedItems()\"\n class=\"ax-text-sm ax-text-primary dark:ax-text-primary-300 ax-underline ax-cursor-pointer\">Clear\n Items</span>\n </div>\n </div>\n }\n </div>\n }\n </div>\n <div class=\"ax-flex-1 ax-px-6 ax-py-4 ax-flex\">\n <ax-data-table class=\"ax-flex-1\" #grid [dataSource]=\"dataSource\" (onRowDbClick)=\"handleRowDbClick($event)\">\n <!-- <ax-index-column *ngIf=\"!platform.is('SM')\" [width]=\"'85px'\"></ax-index-column> -->\n <ax-select-column [width]=\"'50px'\"></ax-select-column>\n @for(col of (columns$ | async);track col.name) {\n <axp-widget-column-renderer [schema]=\"col.schema\" [dataField]=\"col.name\" [caption]=\"col.title\"\n *ngIf=\"col.visible\" width=\"180px\" [allowSorting]=\"false\" [options]=\"col.options\"\n [displayFormat]=\"col.displayFormat\">\n </axp-widget-column-renderer>\n }\n <ax-dropdown-command-column [width]=\"'60px'\" [items]=\"getDropdownRowItems\"\n (onItemClick)=\"handleRowCommandClick($event)\"></ax-dropdown-command-column>\n <ax-command-column [width]=\"'60px'\" [items]=\"getInlineRowItems\"\n (onItemClick)=\"handleRowCommandClick($event)\"></ax-command-column>\n </ax-data-table>\n </div>\n </ax-content>\n <ax-drawer (collapsedChange)=\"closeDrawer('columns', $event)\" #columnsDrawer location=\"end\" [mode]=\"'overlay'\">\n <ax-content class=\"ax-w-[85vw] md:ax-w-[45vw] lg:ax-w-[35vw] 2xl:ax-w-[20vw] ax-border-e\">\n <axp-list-view-option-columns [loader]=\"loader\" (onClosed)=\"columnsDrawer.close()\"></axp-list-view-option-columns>\n </ax-content>\n </ax-drawer>\n <ax-drawer (collapsedChange)=\"closeDrawer('conditions', $event)\" #conditionsDrawer location=\"end\" [mode]=\"'overlay'\">\n <ax-content class=\"ax-w-[85vw] md:ax-w-[45vw] lg:ax-w-[35vw] 2xl:ax-w-[25vw] ax-border-e\">\n <axp-list-view-option-conditions [loader]=\"loader\"\n (onClosed)=\"conditionsDrawer.close()\"></axp-list-view-option-conditions>\n </ax-content>\n </ax-drawer>\n <ax-drawer (collapsedChange)=\"closeDrawer('sorts', $event)\" #sortsDrawer location=\"end\" [mode]=\"'overlay'\">\n <ax-content class=\"ax-w-[85vw] md:ax-w-[45vw] lg:ax-w-[35vw] 2xl:ax-w-[20vw] ax-border-e\">\n <axp-list-view-option-sorting (onClosed)=\"sortsDrawer.close()\" [loader]=\"loader\"></axp-list-view-option-sorting>\n </ax-content>\n </ax-drawer>\n</ax-drawer-container>", styles: [".cdk-drag-preview{border-radius:.375rem;border-width:1px;--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);background:rgba(var(--ax-color-on-surface));padding:.5rem;height:max-content!important}.collapsed-search-box{margin-top:0;height:0px;opacity:0}\n"], dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6$1.AXDataTableComponent, selector: "ax-data-table", inputs: ["rowTemplate", "emptyTemplate", "showHeader", "fetchDataMode", "dataSource", "loading", "focusedRow", "selectedRows", "itemHeight"], outputs: ["onPageChanged", "onRowClick", "onRowDbClick", "focusedRowChange", "selectedRowsChange", "onScrolledIndexChanged"] }, { kind: "component", type: i6$1.AXRowSelectColumnComponent, selector: "ax-select-column", inputs: ["width", "caption", "fixed"] }, { kind: "component", type: i6$1.AXRowCommandColumnComponent, selector: "ax-command-column", inputs: ["width", "caption", "fixed", "items"], outputs: ["onItemClick"] }, { kind: "component", type: i6$1.AXRowDropdownCommandColumnComponent, selector: "ax-dropdown-command-column", inputs: ["width", "caption", "fixed", "items"], outputs: ["onItemClick"] }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: i4.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i4.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items"], outputs: ["onItemClick"] }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorClearButtonComponent, selector: "ax-clear-button", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "component", type: i1$2.AXBadgeComponent, selector: "ax-badge", inputs: ["color", "look", "text"] }, { kind: "component", type: i10.AXDropdownPanelComponent, selector: "ax-dropdown-panel", inputs: ["isOpen", "fitParent", "dropdownWidth", "position", "_target", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "component", type: i4$1.AXDrawerComponent, selector: "ax-drawer", inputs: ["location", "showBackdrop", "mode", "collapsed"], outputs: ["locationChange", "modeChange", "collapsedChange"] }, { kind: "component", type: i4$1.AXDrawerContainerComponent, selector: "ax-drawer-container" }, { kind: "component", type: i12.AXSearchBoxComponent, selector: "ax-search-box", inputs: ["disabled", "readonly", "tabIndex", "placeholder", "value", "state", "name", "id", "look", "delayTime"], outputs: ["valueChange", "stateChange", "onValueChanged", "onBlur", "onFocus", "readonlyChange", "disabledChange", "onKeyDown", "onKeyUp", "onKeyPress"] }, { kind: "component", type: i1$3.AXPWidgetColumnRendererComponent, selector: "axp-widget-column-renderer", inputs: ["width", "caption", "headerTemplate", "allowSorting", "fixed", "options", "dataField", "displayFormat", "schema"] }, { kind: "component", type: AXPListViewOptionsColumnsComponent, selector: "axp-list-view-option-columns", inputs: ["loader"], outputs: ["onClosed"] }, { kind: "component", type: AXPListViewOptionConditionsComponent, selector: "axp-list-view-option-conditions", inputs: ["loader"], outputs: ["onClosed"] }, { kind: "component", type: AXPListViewOptionSortingComponent, selector: "axp-list-view-option-sorting", inputs: ["loader"], outputs: ["onClosed"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
2028
+ }
2029
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityListViewComponent, decorators: [{
2030
+ type: Component,
2031
+ args: [{ encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, providers: [AXUnsubscriber], template: "<ax-drawer-container>\n <!-- <ax-drawer #drawer location=\"start\" [collapsed]=\"true\" [mode]=\"platform.is('SM') ? 'overlay' : 'push'\">\n <ax-content class=\"ax-w-64 ax-border-e\">\n <div class=\"ax-p-6 ax-py-4 ax-gap-6 ax-flex ax-flex-col\">\n <p class=\"ax-text-2xl ax-font-bold\">Folders</p>\n <ax-side-menu>\n <ng-container *ngFor=\"let node of menuItems\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: node }\">\n </ng-container>\n </ax-side-menu>\n <ng-template #sideMenu let-item>\n <ax-side-menu-item [text]=\"item.text\">\n <ax-prefix>\n <ax-icon class=\"fa-solid fa-folder ax-text-warning-500\"></ax-icon>\n </ax-prefix>\n <ng-container *ngIf=\"item.children\">\n <ng-container *ngFor=\"let child of item.children\" [ngTemplateOutlet]=\"sideMenu\"\n [ngTemplateOutletContext]=\"{ $implicit: child }\">\n </ng-container>\n </ng-container>\n </ax-side-menu-item>\n </ng-template>\n </div>\n </ax-content>\n </ax-drawer> -->\n <ax-content class=\"ax-flex ax-flex-col ax-overflow-hidden\">\n <div\n class=\"ax-flex ax-flex-col ax-gap-0 md:ax-gap-4 ax-px-4 ax-py-3 md:ax-py-4 md:ax-px-6 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\">\n @if(platform.is('MD')){\n <div class=\"ax-flex ax-justify-between ax-mb-4\">\n @if(this.grid?.selectedRows?.length==0){\n <div class=\"ax-text-xl ax-font-bold\">{{ title }}</div>\n <div class=\"ax-flex ax-items-center ax-gap-2\">\n <ax-button color=\"primary\" class=\"ax-sm\" (onClick)=\"handleCreateClick()\">\n <ax-icon class=\"fa-solid fa-add\"></ax-icon>\n </ax-button>\n <ax-button color=\"ghost\" class=\"ax-sm\" #more>\n <ax-icon class=\"fa-solid fa-ellipsis-vertical\"> </ax-icon>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list>\n <ax-button-item text=\"Export\" class=\"ax-font-semibold\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-file-export\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n </div>\n }@else {\n <div class=\"ax-flex ax-items-center ax-gap-3\">\n <span class=\"ax-text-xl ax-font-bold\"> {{ this.grid?.selectedRows?.length }} Items Selected </span>\n <span (click)=\"clearSelectedItems()\"\n class=\"ax-text-sm ax-text-primary dark:ax-text-primary-300 ax-underline ax-cursor-pointer\">Clear\n Items</span>\n </div>\n <div class=\"ax-flex ax-items-center ax-gap-2\">\n <ax-button color=\"danger\" class=\"ax-sm\" (onClick)=\"handleCommandClick('delete')\">\n <ax-icon class=\"fa-solid fa-trash\"> </ax-icon>\n </ax-button>\n <ax-button color=\"ghost\" class=\"ax-sm\" #more>\n <ax-icon class=\"fa-solid fa-ellipsis-vertical\"> </ax-icon>\n </ax-button>\n </div>\n }\n </div>\n\n <div class=\"ax-flex ax-items-center ax-justify-between\">\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" [text]=\"(view$ | async)?.title\" color=\"ghost\">\n <ax-icon class=\"fa-solid fa-eye ax-text-neutral-400\"> </ax-icon>\n <ax-suffix>\n <i class=\"fa-solid fa-caret-down\"></i>\n </ax-suffix>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list class=\"ax-bg-surface\">\n <ax-title class=\"ax-font-bold ax-opacity-100\">Public Views</ax-title>\n <ax-button-item *ngFor=\"let v of publicViews$ | async\" [text]=\"v.title\"\n [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\"></ax-button-item>\n <ax-title class=\"ax-font-bold ax-opacity-100\" *ngIf=\"hasCustomViews$ | async\">Created by me</ax-title>\n <ax-button-item *ngFor=\"let v of customViews$ | async\" [text]=\"v.title\"\n [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\"></ax-button-item>\n <ax-divider></ax-divider>\n <ax-button-item (onClick)=\"addCustomViewPopup()\" text=\"Add Custom View\"\n class=\"ax-font-semibold ax-text-primary\"></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n <div class=\"ax-flex ax-gap-2\">\n @if(searchBoxTitle){\n <ax-button (onClick)=\"toggleSearchBox()\" [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\">\n <ax-icon class=\"fa-solid fa-search ax-text-neutral-400\"> </ax-icon>\n </ax-button>\n }\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\" (onClick)=\"columnsDrawer.open()\">\n <ax-icon class=\"fa-solid fa-bars ax-text-neutral-400\"> </ax-icon>\n </ax-button>\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\"\n (onClick)=\"conditionsDrawer.open()\">\n <ax-icon class=\"fa-solid fa-sliders ax-text-neutral-400\"> </ax-icon>\n @if ((conditionsCount$ | async)) {\n <ax-suffix>\n <ax-badge [color]=\"'primary'\"></ax-badge>\n </ax-suffix>\n }\n </ax-button>\n <ax-button [disabled]=\"this.grid?.selectedRows?.length != 0\" color=\"ghost\" (onClick)=\"sortsDrawer.open()\">\n <ax-icon class=\"fa-solid fa-bars-sort ax-text-neutral-400\"> </ax-icon>\n @if ((sortCount$ | async)) {\n <ax-suffix>\n <ax-badge [color]=\"'primary'\"></ax-badge>\n </ax-suffix>\n }\n </ax-button>\n </div>\n </div>\n <div [class.collapsed-search-box]=\"searchBoxCollapsed\" class=\"ax-transition-all ax-mt-4\">\n <ax-search-box [title]=\"searchBoxTitle\"\n [placeholder]=\"'Search on ' + searchBoxPlaceholder\"><ax-clear-button></ax-clear-button></ax-search-box>\n </div>\n } @else {\n <div class=\"ax-flex ax-items-center ax-justify-between ax-gap-3\">\n <div class=\"ax-text-xl md:ax-text-3xl ax-font-bold ax-mb-2\">{{ title }}</div>\n @if(this.grid?.selectedRows?.length==0){\n <div class=\"ax-flex ax-gap-3\">\n <ax-button text=\"Create New\" color=\"primary\" (onClick)=\"handleCreateClick()\">\n <ax-prefix>\n <i class=\"fa-solid fa-add\"></i>\n </ax-prefix>\n </ax-button>\n <ax-button text=\"Actions\" color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis-vertical\"></i>\n </ax-prefix>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list>\n <ax-button-item text=\"Export\" class=\"ax-font-semibold\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-file-export\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n </div>\n }@else {\n <div class=\"ax-flex ax-gap-3\">\n <ax-button text=\"Delete Items\" color=\"danger\" (onClick)=\"handleCommandClick('delete')\">\n <ax-prefix>\n <i class=\"fa-solid fa-trash\"></i>\n </ax-prefix>\n </ax-button>\n <ax-button text=\"Actions\" color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis-vertical\"></i>\n </ax-prefix>\n </ax-button>\n </div>\n }\n </div>\n <div class=\"ax-flex ax-items-center ax-justify-between\">\n <!----------------------- View Mode --------------------->\n @if(this.grid?.selectedRows?.length==0) {\n <div class=\"ax-flex ax-w-full ax-justify-between ax-gap-3\">\n <div class=\"ax-flex ax-gap-3\">\n <ax-button [text]=\"(view$ | async)?.title\" #views color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-eye\"></i>\n </ax-prefix>\n <ax-suffix>\n <i class=\"fa-solid fa-caret-down\"></i>\n </ax-suffix>\n <ax-dropdown-panel [adaptivityEnabled]=\"true\">\n <ax-button-item-list class=\"ax-bg-surface\">\n <ax-title class=\"ax-font-bold ax-opacity-100\">Public Views</ax-title>\n <ax-button-item *ngFor=\"let v of publicViews$ | async\" [text]=\"v.title\"\n [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\"></ax-button-item>\n <ax-title class=\"ax-font-bold ax-opacity-100\" *ngIf=\"hasCustomViews$ | async\">Created by me</ax-title>\n <ax-button-item class=\"ax-pe-4 ax-flex ax-justify-between\" *ngFor=\"let v of customViews$ | async\"\n [text]=\"v.title\" [class.ax-bg-on-surface]=\"(view$ | async) == v\" (onClick)=\"loader.setView(v.name)\">\n <ax-suffix>\n <ax-button (onClick)=\"updateViewPopup($event, v)\" class=\"ax-xs\" look=\"none\">\n <ax-icon class=\"far fa-edit\"> </ax-icon>\n </ax-button>\n </ax-suffix>\n </ax-button-item>\n <ax-divider></ax-divider>\n <ax-button-item text=\"Add Custom View\" (onClick)=\"addCustomViewPopup()\"\n class=\"ax-font-semibold ax-text-primary\"></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n @if(searchBoxTitle){\n <div class=\"ax-w-72\">\n <ax-search-box [title]=\"searchBoxTitle\" [(ngModel)]=\"searchValue\"\n (onValueChanged)=\"handleChangeSearchValue($event)\"\n [placeholder]=\"'Search on ' + searchBoxPlaceholder\"><ax-clear-button></ax-clear-button></ax-search-box>\n </div>\n }\n </div>\n\n <div class=\"ax-flex ax-gap-3\">\n <ax-button text=\"Columns\" color=\"ghost\" #columns (onClick)=\"columnsDrawer.open()\">\n <ax-prefix>\n <i class=\"fa-solid fa-bars\"></i>\n </ax-prefix>\n <ax-suffix>\n <ax-badge text=\"{{ columnsCount$ | async }}\" color=\"primary\"></ax-badge>\n </ax-suffix>\n </ax-button>\n <ax-button text=\"Conditions\" color=\"ghost\" (onClick)=\"conditionsDrawer.open()\" #conditions>\n <ax-prefix>\n <i class=\"fa-solid fa-sliders\"></i>\n </ax-prefix>\n <ax-suffix>\n <ax-badge text=\"{{ conditionsCount$ | async }}\" color=\"primary\"></ax-badge>\n </ax-suffix>\n </ax-button>\n <ax-button text=\"Sort\" color=\"ghost\" (onClick)=\"sortsDrawer.open()\">\n <ax-prefix>\n <i class=\"fa-solid fa-bars-sort\"></i>\n </ax-prefix>\n <ax-suffix *ngIf=\"(sortCount$ | async)! > 0\">\n <ax-badge text=\"{{ sortCount$ | async }}\" color=\"primary\"></ax-badge>\n </ax-suffix>\n </ax-button>\n </div>\n </div>\n\n } @else{\n <!----------------------- Selection Mode --------------------->\n <div>\n <div class=\"ax-flex ax-gap-3 ax-items-center\">\n <span class=\"ax-text-xl ax-font-bold\"> {{ this.grid?.selectedRows?.length }} Items Selected </span>\n <span (click)=\"clearSelectedItems()\"\n class=\"ax-text-sm ax-text-primary dark:ax-text-primary-300 ax-underline ax-cursor-pointer\">Clear\n Items</span>\n </div>\n </div>\n }\n </div>\n }\n </div>\n <div class=\"ax-flex-1 ax-px-6 ax-py-4 ax-flex\">\n <ax-data-table class=\"ax-flex-1\" #grid [dataSource]=\"dataSource\" (onRowDbClick)=\"handleRowDbClick($event)\">\n <!-- <ax-index-column *ngIf=\"!platform.is('SM')\" [width]=\"'85px'\"></ax-index-column> -->\n <ax-select-column [width]=\"'50px'\"></ax-select-column>\n @for(col of (columns$ | async);track col.name) {\n <axp-widget-column-renderer [schema]=\"col.schema\" [dataField]=\"col.name\" [caption]=\"col.title\"\n *ngIf=\"col.visible\" width=\"180px\" [allowSorting]=\"false\" [options]=\"col.options\"\n [displayFormat]=\"col.displayFormat\">\n </axp-widget-column-renderer>\n }\n <ax-dropdown-command-column [width]=\"'60px'\" [items]=\"getDropdownRowItems\"\n (onItemClick)=\"handleRowCommandClick($event)\"></ax-dropdown-command-column>\n <ax-command-column [width]=\"'60px'\" [items]=\"getInlineRowItems\"\n (onItemClick)=\"handleRowCommandClick($event)\"></ax-command-column>\n </ax-data-table>\n </div>\n </ax-content>\n <ax-drawer (collapsedChange)=\"closeDrawer('columns', $event)\" #columnsDrawer location=\"end\" [mode]=\"'overlay'\">\n <ax-content class=\"ax-w-[85vw] md:ax-w-[45vw] lg:ax-w-[35vw] 2xl:ax-w-[20vw] ax-border-e\">\n <axp-list-view-option-columns [loader]=\"loader\" (onClosed)=\"columnsDrawer.close()\"></axp-list-view-option-columns>\n </ax-content>\n </ax-drawer>\n <ax-drawer (collapsedChange)=\"closeDrawer('conditions', $event)\" #conditionsDrawer location=\"end\" [mode]=\"'overlay'\">\n <ax-content class=\"ax-w-[85vw] md:ax-w-[45vw] lg:ax-w-[35vw] 2xl:ax-w-[25vw] ax-border-e\">\n <axp-list-view-option-conditions [loader]=\"loader\"\n (onClosed)=\"conditionsDrawer.close()\"></axp-list-view-option-conditions>\n </ax-content>\n </ax-drawer>\n <ax-drawer (collapsedChange)=\"closeDrawer('sorts', $event)\" #sortsDrawer location=\"end\" [mode]=\"'overlay'\">\n <ax-content class=\"ax-w-[85vw] md:ax-w-[45vw] lg:ax-w-[35vw] 2xl:ax-w-[20vw] ax-border-e\">\n <axp-list-view-option-sorting (onClosed)=\"sortsDrawer.close()\" [loader]=\"loader\"></axp-list-view-option-sorting>\n </ax-content>\n </ax-drawer>\n</ax-drawer-container>", styles: [".cdk-drag-preview{border-radius:.375rem;border-width:1px;--tw-shadow: 0 10px 15px -3px rgb(0 0 0 / .1), 0 4px 6px -4px rgb(0 0 0 / .1);--tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);background:rgba(var(--ax-color-on-surface));padding:.5rem;height:max-content!important}.collapsed-search-box{margin-top:0;height:0px;opacity:0}\n"] }]
2032
+ }], ctorParameters: () => [{ type: i1$4.AXActionSheetService }, { type: i2$3.AXUnsubscriber }, { type: i3$2.AXPlatform }, { type: i0.ChangeDetectorRef }], propDecorators: { viewsTemplate: [{
2033
+ type: ViewChild,
2034
+ args: ['viewsTemplate']
2035
+ }], grid: [{
2036
+ type: ViewChild,
2037
+ args: ['grid']
2038
+ }], entityViewDrawer: [{
2039
+ type: ViewChild,
2040
+ args: ['entityViewDrawer']
2041
+ }] } });
2042
+
2043
+ const widgetSchemas = {
2044
+ //*Sharing schema list with other modules
2045
+ text: 'text',
2046
+ largetext: 'largetext',
2047
+ number: 'number',
2048
+ currency: 'currency',
2049
+ phone: 'phone',
2050
+ email: 'email',
2051
+ dateTime: 'dateTime',
2052
+ date: 'date',
2053
+ time: 'time',
2054
+ toggle: 'toggle',
2055
+ checkbox: 'checkbox',
2056
+ password: 'password',
2057
+ file: 'file',
2058
+ lookup: 'lookup',
2059
+ selectionList: 'selection-list',
2060
+ richText: 'rich-text',
2061
+ map: 'map',
2062
+ avatar: 'avatar',
2063
+ messenger: 'messenger',
2064
+ gallery: 'gallery',
2065
+ signaturePad: 'signature-pad',
2066
+ };
2067
+ class AXPCommonWidgetModule {
2068
+ constructor(service) {
2069
+ //text
2070
+ service.register({
2071
+ component: {
2072
+ view: {
2073
+ component: () => import('./acorex-platform-layouts-text-widget-view.component-65eOj0qR.mjs').then((c) => c.AXPTextWidgetViewComponent),
2074
+ },
2075
+ filter: {
2076
+ component: () => import('./acorex-platform-layouts-string-widget-filter.component-4oZ6BVis.mjs').then((c) => c.AXPStringWidgetFilterComponent),
2077
+ },
2078
+ edit: {
2079
+ component: () => import('./acorex-platform-layouts-text-widget-edit.component-TC127Dq8.mjs').then((c) => c.AXPTextWidgetEditComponent),
2080
+ },
2081
+ column: {
2082
+ component: () => import('./acorex-platform-layouts-text-widget-column.component-qhh6MT79.mjs').then((c) => c.AXPTextWidgetColumnComponent),
2083
+ },
2084
+ },
2085
+ filterOptions: {
2086
+ operators: [...STRING_OPERATORS],
2087
+ default: CONTAINS_OPER,
2088
+ },
2089
+ name: widgetSchemas.text,
2090
+ dataType: 'string',
2091
+ });
2092
+ service.extend('text', {
2093
+ name: widgetSchemas.largetext,
2094
+ component: {
2095
+ edit: {
2096
+ component: () => import('./acorex-platform-layouts-largetext-widget-edit.component-Um_eBRFi.mjs').then((c) => c.AXPLargeTextWidgetEditComponent),
2097
+ },
2098
+ column: {
2099
+ options: {
2100
+ width: '400px',
2101
+ },
2102
+ },
2103
+ },
2104
+ });
2105
+ //
2106
+ service.register({
2107
+ component: {
2108
+ view: {
2109
+ component: () => import('./acorex-platform-layouts-number-widget-view.component-hqkAR0LG.mjs').then((c) => c.AXPNumberWidgetViewComponent),
2110
+ },
2111
+ filter: {
2112
+ component: () => import('./acorex-platform-layouts-number-widget-filter.component-DPGSzdNm.mjs').then((c) => c.AXPNumberWidgetFilterComponent),
2113
+ },
2114
+ edit: {
2115
+ component: () => import('./acorex-platform-layouts-number-widget-edit.component-DDi-o_Zn.mjs').then((c) => c.AXPNumberWidgetEditComponent),
2116
+ },
2117
+ column: {
2118
+ component: () => import('./acorex-platform-layouts-number-widget-view.component-hqkAR0LG.mjs').then((c) => c.AXPNumberWidgetViewComponent),
2119
+ },
2120
+ },
2121
+ name: widgetSchemas.number,
2122
+ filterOptions: {
2123
+ operators: [...NUMBER_OPERATORS],
2124
+ default: BETWEEN_OPER,
2125
+ },
2126
+ dataType: 'number',
2127
+ });
2128
+ service.extend('number', {
2129
+ name: widgetSchemas.currency,
2130
+ formats: {
2131
+ default: 'EN-GB',
2132
+ },
2133
+ component: {
2134
+ edit: {
2135
+ options: {
2136
+ clearButton: false,
2137
+ },
2138
+ },
2139
+ },
2140
+ });
2141
+ //phone
2142
+ service.register({
2143
+ component: {
2144
+ view: {
2145
+ component: () => import('./acorex-platform-layouts-phone-widget-view.component-NEO22XO7.mjs').then((c) => c.AXPPhoneWidgetViewComponent),
2146
+ },
2147
+ column: {
2148
+ component: () => import('./acorex-platform-layouts-phone-widget-column.component-s04WZfzv.mjs').then((c) => c.AXPPhoneWidgetColumnComponent),
2149
+ },
2150
+ edit: {
2151
+ component: () => import('./acorex-platform-layouts-phone-widget-edit.component-MKzlZ0_B.mjs').then((c) => c.AXPPhoneWidgetEditComponent),
2152
+ },
2153
+ filter: {
2154
+ component: () => import('./acorex-platform-layouts-string-widget-filter.component-4oZ6BVis.mjs').then((c) => c.AXPStringWidgetFilterComponent),
2155
+ },
2156
+ },
2157
+ name: widgetSchemas.phone,
2158
+ filterOptions: {
2159
+ operators: [...STRING_OPERATORS],
2160
+ default: CONTAINS_OPER,
2161
+ },
2162
+ dataType: 'object',
2163
+ });
2164
+ //email
2165
+ service.register({
2166
+ component: {
2167
+ view: {
2168
+ component: () => import('./acorex-platform-layouts-email-widget-view.component-XrV8va7z.mjs').then((c) => c.AXPEmailWidgetViewComponent),
2169
+ },
2170
+ edit: {
2171
+ component: () => import('./acorex-platform-layouts-email-widget-edit.component-m2dI7y9X.mjs').then((c) => c.AXPEmailWidgetEditComponent),
2172
+ },
2173
+ filter: {
2174
+ component: () => import('./acorex-platform-layouts-string-widget-filter.component-4oZ6BVis.mjs').then((c) => c.AXPStringWidgetFilterComponent),
2175
+ },
2176
+ column: {
2177
+ component: () => import('./acorex-platform-layouts-email-widget-column.component-ac8gqsFT.mjs').then((c) => c.AXPEmailWidgetColumnComponent),
2178
+ },
2179
+ },
2180
+ name: widgetSchemas.email,
2181
+ filterOptions: {
2182
+ operators: [...STRING_OPERATORS],
2183
+ default: CONTAINS_OPER,
2184
+ },
2185
+ dataType: 'object',
2186
+ });
2187
+ // dateTime
2188
+ service.register({
2189
+ component: {
2190
+ view: {
2191
+ component: () => import('./acorex-platform-layouts-dateTime-widget-view.component-BrwycTWz.mjs').then((c) => c.AXPDateTimeWidgetViewComponent),
2192
+ },
2193
+ edit: {
2194
+ component: () => import('./acorex-platform-layouts-dateTime-widget-edit.component-zeJXGXY8.mjs').then((c) => c.AXPDateTimeWidgetEditComponent),
2195
+ },
2196
+ filter: {
2197
+ component: () => import('./acorex-platform-layouts-dateTime-widget-filter.component-DJ6esclU.mjs').then((c) => c.AXPDateTimeWidgetFilterComponent),
2198
+ },
2199
+ column: {
2200
+ component: () => import('./acorex-platform-layouts-dateTime-widget-column.component-qeQRJePy.mjs').then((c) => c.AXPDateTimeWidgetColumnComponent),
2201
+ options: {
2202
+ width: '150px',
2203
+ },
2204
+ },
2205
+ },
2206
+ formats: {
2207
+ default: 'date time',
2208
+ },
2209
+ filterOptions: {
2210
+ operators: [...DATE_OPERATORS],
2211
+ default: BETWEEN_OPER,
2212
+ },
2213
+ name: widgetSchemas.dateTime,
2214
+ dataType: 'date',
2215
+ });
2216
+ service.extend(widgetSchemas.dateTime, {
2217
+ name: widgetSchemas.date,
2218
+ formats: {
2219
+ default: 'date',
2220
+ },
2221
+ component: {
2222
+ column: {
2223
+ options: {
2224
+ width: '120px',
2225
+ },
2226
+ },
2227
+ },
2228
+ });
2229
+ service.extend(widgetSchemas.dateTime, {
2230
+ name: widgetSchemas.time,
2231
+ formats: {
2232
+ default: 'time',
2233
+ },
2234
+ component: {
2235
+ column: {
2236
+ options: {
2237
+ width: '80px',
2238
+ },
2239
+ },
2240
+ },
2241
+ });
2242
+ //toggle
2243
+ service.register({
2244
+ component: {
2245
+ view: {
2246
+ component: () => import('./acorex-platform-layouts-toggle-widget-view.component-DTOeAUiy.mjs').then((c) => c.AXPToggleWidgetViewComponent),
2247
+ },
2248
+ edit: {
2249
+ component: () => import('./acorex-platform-layouts-toggle-widget-edit.component-R44L1pgJ.mjs').then((c) => c.AXPToggleWidgetEditComponent),
2250
+ },
2251
+ filter: {
2252
+ component: () => import('./acorex-platform-layouts-boolean-widget-filter.component-H056Q5Gz.mjs').then((c) => c.AXPBooleanWidgetFilterComponent),
2253
+ },
2254
+ column: {
2255
+ component: () => import('./acorex-platform-layouts-toggle-widget-column.component-uxOXR-bL.mjs').then((c) => c.AXPToggleWidgetColumnComponent),
2256
+ options: {
2257
+ width: '100px',
2258
+ },
2259
+ },
2260
+ },
2261
+ filterOptions: {
2262
+ operators: [],
2263
+ default: EQ_OPER,
2264
+ },
2265
+ name: widgetSchemas.toggle,
2266
+ dataType: 'boolean',
2267
+ });
2268
+ //checkbox
2269
+ service.register({
2270
+ component: {
2271
+ view: {
2272
+ component: () => import('./acorex-platform-layouts-checkbox-widget-view.component-m6bF8XFR.mjs').then((c) => c.AXPCheckboxWidgetViewComponent),
2273
+ },
2274
+ edit: {
2275
+ component: () => import('./acorex-platform-layouts-checkbox-widget-edit.component-P4cD_Nwg.mjs').then((c) => c.AXPCheckboxWidgetEditComponent),
2276
+ },
2277
+ filter: {
2278
+ component: () => import('./acorex-platform-layouts-boolean-widget-filter.component-H056Q5Gz.mjs').then((c) => c.AXPBooleanWidgetFilterComponent),
2279
+ },
2280
+ column: {
2281
+ component: () => import('./acorex-platform-layouts-checkbox-widget-column.component-vRJI5S-w.mjs').then((c) => c.AXPCheckboxWidgetColumnComponent),
2282
+ options: {
2283
+ width: '100px',
2284
+ },
2285
+ },
2286
+ },
2287
+ filterOptions: {
2288
+ operators: [],
2289
+ default: EQ_OPER,
2290
+ },
2291
+ name: widgetSchemas.checkbox,
2292
+ dataType: 'boolean',
2293
+ });
2294
+ //password
2295
+ service.register({
2296
+ component: {
2297
+ view: {
2298
+ component: () => import('./acorex-platform-layouts-password-widget-view.component-E2vtPKRO.mjs').then((c) => c.AXPPasswordWidgetViewComponent),
2299
+ },
2300
+ column: {
2301
+ component: () => import('./acorex-platform-layouts-password-widget-column.component-ic1jykZL.mjs').then((c) => c.AXPPasswordWidgetColumnComponent),
2302
+ },
2303
+ edit: {
2304
+ component: () => import('./acorex-platform-layouts-password-widget-edit.component-D8xI17yk.mjs').then((c) => c.AXPPasswordWidgetEditComponent),
2305
+ },
2306
+ },
2307
+ filterOptions: {
2308
+ operators: [],
2309
+ default: EQ_OPER,
2310
+ },
2311
+ name: widgetSchemas.password,
2312
+ dataType: 'string',
2313
+ });
2314
+ //file
2315
+ service.register({
2316
+ component: {
2317
+ view: {
2318
+ component: () => import('./acorex-platform-layouts-file-widget-view.component-mXBrKX0K.mjs').then((c) => c.AXPFileWidgetViewComponent),
2319
+ },
2320
+ column: {
2321
+ component: () => import('./acorex-platform-layouts-file-widget-column.component-v7kAdIQ9.mjs').then((c) => c.AXPFileWidgetColumnComponent),
2322
+ },
2323
+ edit: {
2324
+ component: () => import('./acorex-platform-layouts-file-widget-edit.component-Wrq7ZL9R.mjs').then((c) => c.AXPFileWidgetEditComponent),
2325
+ },
2326
+ filter: {
2327
+ component: () => import('./acorex-platform-layouts-file-widget-filter.component-1-NJh38j.mjs').then((c) => c.AXPFileWidgetFilterComponent),
2328
+ },
2329
+ },
2330
+ filterOptions: {
2331
+ operators: [],
2332
+ default: EQ_OPER,
2333
+ },
2334
+ name: widgetSchemas.file,
2335
+ dataType: 'object',
2336
+ });
2337
+ // look up
2338
+ service.register({
2339
+ component: {
2340
+ view: {
2341
+ component: () => import('./acorex-platform-layouts-lookup-widget-view.component-ftFXFj6k.mjs').then((c) => c.AXPLookupWidgetViewComponent),
2342
+ },
2343
+ edit: {
2344
+ component: () => import('./acorex-platform-layouts-lookup-widget-edit.component-l5nSr9Cm.mjs').then((c) => c.AXPLookupWidgetEditComponent),
2345
+ },
2346
+ filter: {
2347
+ component: () => import('./acorex-platform-layouts-lookup-widget-filter.component-gp5skvmz.mjs').then((c) => c.AXPLookupWidgetFilterComponent),
2348
+ },
2349
+ column: {
2350
+ component: () => import('./acorex-platform-layouts-lookup-widget-column.component-Ts0MJe8O.mjs').then((c) => c.AXPLookupWidgetColumnComponent),
2351
+ },
2352
+ },
2353
+ filterOptions: {
2354
+ operators: [],
2355
+ default: CONTAINS_OPER,
2356
+ },
2357
+ name: widgetSchemas.lookup,
2358
+ dataType: 'object',
2359
+ });
2360
+ // selection list
2361
+ service.register({
2362
+ component: {
2363
+ view: {
2364
+ component: () => import('./acorex-platform-layouts-selection-list-widget-view.component-s9xq___Y.mjs').then((c) => c.AXPSelectionListWidgetViewComponent),
2365
+ },
2366
+ edit: {
2367
+ component: () => import('./acorex-platform-layouts-selection-list-widget-edit.component-FpOQ12Ie.mjs').then((c) => c.AXPSelectionListWidgetEditComponent),
2368
+ },
2369
+ column: {
2370
+ component: () => import('./acorex-platform-layouts-selection-list-widget-column.component-9FTkDGmq.mjs').then((c) => c.AXPSelectionListWidgetColumnComponent),
2371
+ },
2372
+ filter: {
2373
+ component: () => import('./acorex-platform-layouts-selection-list-widget-filter.component-hGk-ZZ78.mjs').then((c) => c.AXPSelectionListWidgetFilterComponent),
2374
+ },
2375
+ },
2376
+ filterOptions: {
2377
+ operators: [],
2378
+ default: CONTAINS_OPER,
2379
+ },
2380
+ name: widgetSchemas.selectionList,
2381
+ dataType: 'object',
2382
+ });
2383
+ // rich text
2384
+ service.register({
2385
+ component: {
2386
+ view: {
2387
+ component: () => import('./acorex-platform-layouts-rich-text-widget-view.component--Rzxm2a6.mjs').then((c) => c.AXPRichTextWidgetViewComponent),
2388
+ },
2389
+ edit: {
2390
+ component: () => import('./acorex-platform-layouts-rich-text-widget-edit.component-ro2yg7PR.mjs').then((c) => c.AXPRichTextWidgetEditComponent),
2391
+ },
2392
+ column: {
2393
+ component: () => import('./acorex-platform-layouts-rich-text-widget-column.component-P0YzXTIB.mjs').then((c) => c.AXPRichTextWidgetColumnComponent),
2394
+ options: {
2395
+ width: '400px',
2396
+ },
2397
+ },
2398
+ filter: {
2399
+ component: () => import('./acorex-platform-layouts-string-widget-filter.component-4oZ6BVis.mjs').then((c) => c.AXPStringWidgetFilterComponent),
2400
+ },
2401
+ },
2402
+ filterOptions: {
2403
+ operators: [...STRING_OPERATORS],
2404
+ default: CONTAINS_OPER,
2405
+ },
2406
+ name: widgetSchemas.richText,
2407
+ dataType: 'object',
2408
+ });
2409
+ // map
2410
+ service.register({
2411
+ component: {
2412
+ view: {
2413
+ component: () => import('./acorex-platform-layouts-map-widget-view.component-1Lj9efbd.mjs').then((c) => c.AXPMapWidgetViewComponent),
2414
+ },
2415
+ edit: {
2416
+ component: () => import('./acorex-platform-layouts-map-widget-edit.component-SOQvPhmX.mjs').then((c) => c.AXPMapWidgetEditComponent),
2417
+ },
2418
+ },
2419
+ filterOptions: {
2420
+ operators: [],
2421
+ default: EQ_OPER,
2422
+ },
2423
+ name: widgetSchemas.map,
2424
+ dataType: 'object',
2425
+ });
2426
+ // avatar
2427
+ service.register({
2428
+ component: {
2429
+ view: {
2430
+ component: () => import('./acorex-platform-layouts-avatar-widget-view.component-pJJYkvdH.mjs').then((c) => c.AXPAvatarWidgetViewComponent),
2431
+ },
2432
+ edit: {
2433
+ component: () => import('./acorex-platform-layouts-avatar-widget-edit.component-PZr1lXj-.mjs').then((c) => c.AXPAvatarWidgetEditComponent),
2434
+ },
2435
+ },
2436
+ filterOptions: {
2437
+ operators: [],
2438
+ default: EQ_OPER,
2439
+ },
2440
+ name: widgetSchemas.avatar,
2441
+ dataType: 'object',
2442
+ });
2443
+ // messenger
2444
+ service.register({
2445
+ component: {
2446
+ view: {
2447
+ component: () => import('./acorex-platform-layouts-messenger-widget-view.component-9TJiFdq-.mjs').then((c) => c.AXPMessengerWidgetViewComponent),
2448
+ },
2449
+ edit: {
2450
+ component: () => import('./acorex-platform-layouts-messenger-widget-edit.component-dAX8nirB.mjs').then((c) => c.AXPMessengerWidgetEditComponent),
2451
+ },
2452
+ column: {
2453
+ component: () => import('./acorex-platform-layouts-messenger-widget-column.component-W7ZY-W84.mjs').then((c) => c.AXPMessengerWidgetColumnComponent),
2454
+ },
2455
+ },
2456
+ filterOptions: {
2457
+ operators: [],
2458
+ default: EQ_OPER,
2459
+ },
2460
+ name: widgetSchemas.messenger,
2461
+ dataType: 'object',
2462
+ });
2463
+ //
2464
+ // gallery
2465
+ service.register({
2466
+ component: {
2467
+ view: {
2468
+ component: () => import('./acorex-platform-layouts-gallery-widget-view.component-xU52uaP0.mjs').then((c) => c.AXPGalleryWidgetViewComponent),
2469
+ },
2470
+ edit: {
2471
+ component: () => import('./acorex-platform-layouts-gallery-widget-edit.component-cWNvVwum.mjs').then((c) => c.AXPGalleryWidgetEditComponent),
2472
+ },
2473
+ filter: {
2474
+ component: () => import('./acorex-platform-layouts-gallery-widget-filter.component-OCz0hj5i.mjs').then((c) => c.AXPGalleryWidgetFilterComponent),
2475
+ },
2476
+ },
2477
+ filterOptions: {
2478
+ operators: [],
2479
+ default: EQ_OPER,
2480
+ },
2481
+ name: widgetSchemas.gallery,
2482
+ dataType: 'object',
2483
+ });
2484
+ // signature-pad
2485
+ service.register({
2486
+ component: {
2487
+ view: {
2488
+ component: () => import('./acorex-platform-layouts-signature-pad-widget-view.component-R40Ml757.mjs').then((c) => c.AXPSignaturePadWidgetViewComponent),
2489
+ },
2490
+ edit: {
2491
+ component: () => import('./acorex-platform-layouts-signature-pad-widget-edit.component-W28Uk9zO.mjs').then((c) => c.AXPSignaturePadWidgetEditComponent),
2492
+ },
2493
+ },
2494
+ filterOptions: {
2495
+ operators: [],
2496
+ default: EQ_OPER,
2497
+ },
2498
+ name: widgetSchemas.signaturePad,
2499
+ dataType: 'object',
2500
+ });
2501
+ //
2502
+ }
2503
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPCommonWidgetModule, deps: [{ token: i1$3.AXPSchemaRegistryService }], target: i0.ɵɵFactoryTarget.NgModule }); }
2504
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.1.2", ngImport: i0, type: AXPCommonWidgetModule, imports: [AXToastModule] }); }
2505
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPCommonWidgetModule, imports: [AXToastModule] }); }
2506
+ }
2507
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPCommonWidgetModule, decorators: [{
2508
+ type: NgModule,
2509
+ args: [{
2510
+ imports: [AXToastModule],
2511
+ exports: [],
2512
+ declarations: [],
2513
+ providers: [],
2514
+ }]
2515
+ }], ctorParameters: () => [{ type: i1$3.AXPSchemaRegistryService }] });
2516
+
2517
+ class AXPListViewModule {
2518
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
2519
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewModule, declarations: [AXPEntityListViewComponent,
2520
+ AXPEntityCreateCustomViewComponent,
2521
+ AXPListViewOptionsColumnsComponent,
2522
+ AXPListViewOptionConditionsComponent,
2523
+ AXPListViewOptionFilterOperatorComponent,
2524
+ AXPListViewOptionSortingComponent], imports: [CommonModule,
2525
+ FormsModule,
2526
+ AXCommonModule,
2527
+ AXDataTableModule,
2528
+ AXButtonModule,
2529
+ AXDecoratorModule,
2530
+ AXBadgeModule,
2531
+ AXDropdownModule,
2532
+ AXPopoverModule,
2533
+ AXImageModule,
2534
+ AXSwitchModule,
2535
+ AXDrawerModule,
2536
+ AXLoadingModule,
2537
+ AXTabsModule,
2538
+ AXSelectBoxModule,
2539
+ AXFormModule,
2540
+ AXListModule,
2541
+ AXTextBoxModule,
2542
+ AXSearchBoxModule,
2543
+ AXLabelModule,
2544
+ AXCollapseModule,
2545
+ AXActionSheetModule,
2546
+ AXSelectionListModule,
2547
+ AXImageModule,
2548
+ AXDialogModule,
2549
+ AXDropdownButtonModule,
2550
+ //
2551
+ CdkDropList,
2552
+ CdkDrag,
2553
+ CdkDragPlaceholder,
2554
+ CdkDragHandle,
2555
+ PortalModule,
2556
+ AXPSchemaModule,
2557
+ AXPCommonWidgetModule] }); }
2558
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewModule, imports: [CommonModule,
2559
+ FormsModule,
2560
+ AXCommonModule,
2561
+ AXDataTableModule,
2562
+ AXButtonModule,
2563
+ AXDecoratorModule,
2564
+ AXBadgeModule,
2565
+ AXDropdownModule,
2566
+ AXPopoverModule,
2567
+ AXImageModule,
2568
+ AXSwitchModule,
2569
+ AXDrawerModule,
2570
+ AXLoadingModule,
2571
+ AXTabsModule,
2572
+ AXSelectBoxModule,
2573
+ AXFormModule,
2574
+ AXListModule,
2575
+ AXTextBoxModule,
2576
+ AXSearchBoxModule,
2577
+ AXLabelModule,
2578
+ AXCollapseModule,
2579
+ AXActionSheetModule,
2580
+ AXSelectionListModule,
2581
+ AXImageModule,
2582
+ AXDialogModule,
2583
+ AXDropdownButtonModule,
2584
+ PortalModule,
2585
+ AXPSchemaModule,
2586
+ AXPCommonWidgetModule] }); }
2587
+ }
2588
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewModule, decorators: [{
2589
+ type: NgModule,
2590
+ args: [{
2591
+ imports: [
2592
+ CommonModule,
2593
+ FormsModule,
2594
+ AXCommonModule,
2595
+ AXDataTableModule,
2596
+ AXButtonModule,
2597
+ AXDecoratorModule,
2598
+ AXBadgeModule,
2599
+ AXDropdownModule,
2600
+ AXPopoverModule,
2601
+ AXImageModule,
2602
+ AXSwitchModule,
2603
+ AXDrawerModule,
2604
+ AXLoadingModule,
2605
+ AXTabsModule,
2606
+ AXSelectBoxModule,
2607
+ AXFormModule,
2608
+ AXListModule,
2609
+ AXTextBoxModule,
2610
+ AXSearchBoxModule,
2611
+ AXLabelModule,
2612
+ AXCollapseModule,
2613
+ AXActionSheetModule,
2614
+ AXSelectionListModule,
2615
+ AXImageModule,
2616
+ AXDialogModule,
2617
+ AXDropdownButtonModule,
2618
+ //
2619
+ CdkDropList,
2620
+ CdkDrag,
2621
+ CdkDragPlaceholder,
2622
+ CdkDragHandle,
2623
+ PortalModule,
2624
+ AXPSchemaModule,
2625
+ AXPCommonWidgetModule,
2626
+ ],
2627
+ declarations: [
2628
+ AXPEntityListViewComponent,
2629
+ AXPEntityCreateCustomViewComponent,
2630
+ AXPListViewOptionsColumnsComponent,
2631
+ AXPListViewOptionConditionsComponent,
2632
+ AXPListViewOptionFilterOperatorComponent,
2633
+ AXPListViewOptionSortingComponent,
2634
+ ],
2635
+ providers: [],
2636
+ }]
2637
+ }] });
2638
+
2639
+ class AXPListViewLoaderDefault {
2640
+ constructor(config, schemaService) {
2641
+ this.config = config;
2642
+ this.schemaService = schemaService;
2643
+ this._dataSource = new AXDataSource(this.entity.dataSource);
2644
+ this._inlineFilterItems = [];
2645
+ this._props$ = new BehaviorSubject(this.props);
2646
+ this.getProp = (name) => this.entity.properties.find((c) => c.name == name);
2647
+ //****************** Views ******************//
2648
+ this._currentView = 'default';
2649
+ this._views$ = new BehaviorSubject(this.views);
2650
+ //****************** Columns ******************//
2651
+ this._currentDisplayColumns$ = new BehaviorSubject([]);
2652
+ this._columns$ = new BehaviorSubject(this.columns);
2653
+ //****************** Sort ******************//
2654
+ this._currentSorts$ = new BehaviorSubject([]);
2655
+ //****************** Conditions ******************//
2656
+ this._currentConditions$ = new BehaviorSubject([]);
2657
+ this.setView(this.views[0].name);
2658
+ this._inlineFilterItems = this.entity.properties
2659
+ .filter((property) => property.canInlineFilter)
2660
+ .map((item) => {
2661
+ const schema = this.schemaService.resolve(item.schema);
2662
+ return { name: item.name, dataType: schema?.dataType, title: item.title };
2663
+ });
2664
+ }
2665
+ get entity() {
2666
+ if (!this._config) {
2667
+ this._config = cloneDeep(this.config);
2668
+ }
2669
+ return this._config;
2670
+ }
2671
+ get dataSource() {
2672
+ return this._dataSource;
2673
+ }
2674
+ //****************** Properties ******************//
2675
+ get props() {
2676
+ return this.entity.properties;
2677
+ }
2678
+ get properties$() {
2679
+ return this._props$;
2680
+ }
2681
+ get views() {
2682
+ return this.entity.views.list.views;
2683
+ }
2684
+ get views$() {
2685
+ return this._views$;
2686
+ }
2687
+ get view$() {
2688
+ return this.views$.pipe(switchMap((views) => {
2689
+ const view = views.find((c) => c.name === this._currentView);
2690
+ if (view) {
2691
+ return of(view);
2692
+ }
2693
+ else if (this.views.length > 0) {
2694
+ return of(this.views[0]);
2695
+ }
2696
+ else {
2697
+ return of(AXPEntityListViewConfigEmpty);
2698
+ }
2699
+ }));
2700
+ }
2701
+ get publicViews$() {
2702
+ return this.views$.pipe(map((c) => c.filter((v) => v.fixed)));
2703
+ }
2704
+ get customViews$() {
2705
+ return this.views$.pipe(map((c) => c.filter((v) => !v.fixed)));
2706
+ }
2707
+ get hasCustomViews$() {
2708
+ return this.customViews$.pipe(map((c) => c.length > 0));
2709
+ }
2710
+ setView(name) {
2711
+ let propNames = [];
2712
+ this.properties$.pipe(first()).subscribe((properties) => {
2713
+ propNames = properties.map((p) => p.name);
2714
+ });
2715
+ this._currentView = name;
2716
+ const updatedView = this._views$.value.find((c) => c.name === this._currentView) || AXPEntityListViewConfigEmpty;
2717
+ const currentViews = this._views$.value;
2718
+ const updatedViews = currentViews.map((view) => {
2719
+ if (view.name === updatedView.name) {
2720
+ return updatedView;
2721
+ }
2722
+ else {
2723
+ return view;
2724
+ }
2725
+ });
2726
+ this._currentConditions$.next(cloneDeep(updatedView.conditions.filter((c) => propNames.includes(c.name))));
2727
+ this._currentSorts$.next(cloneDeep(updatedView.sorts.filter((s) => propNames.includes(s.name))));
2728
+ // this._columns$.next(updatedView.columns);
2729
+ this._currentDisplayColumns$.next(cloneDeep(updatedView.columns.filter((c) => propNames.includes(c.name))));
2730
+ this._views$.next(updatedViews);
2731
+ //apply conditions and sorts:
2732
+ this.dataSource.filter({
2733
+ field: null,
2734
+ logic: 'and',
2735
+ operator: null,
2736
+ filters: updatedView.conditions.map((c) => ({
2737
+ field: c.name,
2738
+ value: c.value,
2739
+ operator: { type: c.operator },
2740
+ })),
2741
+ });
2742
+ const convertedSortItems = updatedView.sorts.map((s) => ({
2743
+ field: s.name,
2744
+ dir: s.dir,
2745
+ }));
2746
+ this.dataSource.sort(...convertedSortItems);
2747
+ this.dataSource.refresh();
2748
+ }
2749
+ createView(newView) {
2750
+ const currentViews = this._views$.getValue();
2751
+ currentViews.push(newView);
2752
+ this._views$.next(currentViews);
2753
+ this.setView(newView.name);
2754
+ }
2755
+ updateView(updatedView) {
2756
+ const currentViews = this._views$.getValue().map((view) => (view.name === updatedView.name ? updatedView : view));
2757
+ this._views$.next(currentViews);
2758
+ this.setView(updatedView.name);
2759
+ }
2760
+ deleteView(viewName) {
2761
+ const currentViews = this._views$.getValue().filter((view) => view.name !== viewName);
2762
+ this._views$.next(currentViews);
2763
+ this.setView(this.views[0].name);
2764
+ }
2765
+ get columns() {
2766
+ return this.entity.properties.map((p) => ({
2767
+ name: p.name,
2768
+ title: p.title,
2769
+ schema: p.schema,
2770
+ }));
2771
+ }
2772
+ get columns$() {
2773
+ return this._columns$.pipe(defaultIfEmpty([]));
2774
+ }
2775
+ get displayColumns$() {
2776
+ return this._currentDisplayColumns$.pipe(defaultIfEmpty([]));
2777
+ }
2778
+ get displayColumnsCount$() {
2779
+ return this.view$.pipe(map((view) => {
2780
+ return view.columns.filter((column) => column.visible).length;
2781
+ }));
2782
+ }
2783
+ updateColumns(items) {
2784
+ this.view$.pipe(first()).subscribe((view) => {
2785
+ view.columns = cloneDeep(items);
2786
+ this._views$.next(this._views$.value.map((v) => (v.name === this._currentView ? view : v)));
2787
+ });
2788
+ }
2789
+ resetColumns() {
2790
+ this.view$.pipe(first()).subscribe((view) => {
2791
+ this._currentDisplayColumns$.next(cloneDeep(view.columns));
2792
+ });
2793
+ }
2794
+ setColumnVisibility(name, visible) {
2795
+ const updatedColumns = this._currentDisplayColumns$.getValue().map((column) => {
2796
+ if (column.name === name) {
2797
+ return { ...column, visible };
2798
+ }
2799
+ else {
2800
+ return column;
2801
+ }
2802
+ });
2803
+ this._currentDisplayColumns$.next(updatedColumns);
2804
+ }
2805
+ get sorts$() {
2806
+ return this._currentSorts$.pipe(defaultIfEmpty([]));
2807
+ }
2808
+ get sortsCount$() {
2809
+ return this.view$.pipe(map((c) => c.sorts.length));
2810
+ }
2811
+ addSort() {
2812
+ this.view$.pipe(first()).subscribe((view) => {
2813
+ const currentSorts = this._currentSorts$.getValue();
2814
+ const name = view.columns.find((c) => !currentSorts.some((s) => s.name == c.name))?.name ?? '';
2815
+ if (name) {
2816
+ const sorts = [...currentSorts, { name, dir: 'asc' }];
2817
+ this._currentSorts$.next(sorts);
2818
+ }
2819
+ });
2820
+ }
2821
+ removeSort(item) {
2822
+ const currentSorts = this._currentSorts$.getValue();
2823
+ const sorts = currentSorts.filter((c) => c != item);
2824
+ this._currentSorts$.next(sorts);
2825
+ }
2826
+ resetSort() {
2827
+ this.view$.pipe(first()).subscribe((view) => {
2828
+ this._currentSorts$.next(cloneDeep(view.sorts));
2829
+ });
2830
+ }
2831
+ updateSort(items) {
2832
+ this.view$.pipe(first()).subscribe((view) => {
2833
+ view.sorts = cloneDeep(items);
2834
+ this._views$.next(this._views$.value.map((v) => (v.name === this._currentView ? view : v)));
2835
+ const convertedSortItems = items.map((s) => ({
2836
+ field: s.name,
2837
+ dir: s.dir,
2838
+ }));
2839
+ this.dataSource.sort(...convertedSortItems);
2840
+ this.dataSource.refresh();
2841
+ });
2842
+ }
2843
+ get conditions$() {
2844
+ return this._currentConditions$.pipe(defaultIfEmpty([]));
2845
+ }
2846
+ get conditionsCount$() {
2847
+ return this.view$.pipe(map((c) => c.conditions.length));
2848
+ }
2849
+ getInlineFilterTitles() {
2850
+ return this._inlineFilterItems.map((item) => item.title);
2851
+ }
2852
+ addCondition(selectedFields) {
2853
+ const prevConditions = this._currentConditions$.getValue();
2854
+ const conditionsMap = new Map(prevConditions.map((item) => [item.name, item]));
2855
+ const newFields = selectedFields.map((field) => conditionsMap.get(field.name) || { name: field.name, operator: field.opr });
2856
+ this._currentConditions$.next(newFields);
2857
+ }
2858
+ removeCondition(item) {
2859
+ const currentConditions = this._currentConditions$.getValue();
2860
+ const conditions = currentConditions.filter((c) => c != item);
2861
+ this._currentConditions$.next(conditions);
2862
+ }
2863
+ updateConditions(items) {
2864
+ this.view$.pipe(first()).subscribe((view) => {
2865
+ view.conditions = cloneDeep(items);
2866
+ this._views$.next(this._views$.value.map((v) => (v.name === this._currentView ? view : v)));
2867
+ });
2868
+ this.applyAllConditions();
2869
+ }
2870
+ handleInlineSearch(value) {
2871
+ const inlineConditions = [];
2872
+ this._inlineFilterItems?.forEach((property) => {
2873
+ if (property?.dataType == 'string' || property?.dataType == 'number') {
2874
+ inlineConditions.push({
2875
+ name: property.name,
2876
+ value: property.dataType == 'number' ? parseFloat(value) : value,
2877
+ operator: property.dataType == 'string' ? 'contains' : 'equal',
2878
+ });
2879
+ }
2880
+ });
2881
+ this.view$.pipe(first()).subscribe((view) => {
2882
+ view.inlineConditions = cloneDeep(inlineConditions);
2883
+ });
2884
+ this.applyAllConditions();
2885
+ }
2886
+ applyAllConditions() {
2887
+ const inlineConditions = {
2888
+ field: null,
2889
+ operator: null,
2890
+ logic: 'or',
2891
+ filters: [],
2892
+ };
2893
+ const mainConditions = {
2894
+ field: null,
2895
+ operator: null,
2896
+ logic: 'and',
2897
+ filters: [],
2898
+ };
2899
+ this.view$.pipe(first()).subscribe((view) => {
2900
+ if (view.inlineConditions && view.inlineConditions.length) {
2901
+ view.inlineConditions?.forEach((c) => {
2902
+ if (c.value) {
2903
+ inlineConditions.filters?.push({
2904
+ field: c.name,
2905
+ operator: { type: c.operator },
2906
+ value: c.value,
2907
+ });
2908
+ }
2909
+ });
2910
+ }
2911
+ if (view.conditions.length) {
2912
+ view.conditions.forEach((c) => {
2913
+ mainConditions.filters?.push({
2914
+ field: c.name,
2915
+ operator: { type: c.operator },
2916
+ value: c.value,
2917
+ });
2918
+ });
2919
+ }
2920
+ this.dataSource.filter({
2921
+ field: null,
2922
+ logic: 'and',
2923
+ operator: null,
2924
+ filters: [mainConditions, inlineConditions],
2925
+ });
2926
+ this.dataSource.refresh();
2927
+ this._views$.next(this._views$.value.map((v) => (v.name === this._currentView ? view : v)));
2928
+ });
2929
+ }
2930
+ resetConditions() {
2931
+ this.view$.pipe(first()).subscribe((view) => {
2932
+ this._currentConditions$.next(cloneDeep(view.conditions));
2933
+ });
2934
+ }
2935
+ }
2936
+ const AXP_LISTVIEW_LOADER = new InjectionToken('AXP_LISTVIEW_LOADER');
2937
+ class AXPListViewLoaderFactory {
2938
+ constructor() {
2939
+ this.cache = new Map();
2940
+ this.entityService = inject(AXPEntityRegistryService);
2941
+ this.schemaService = inject(AXPSchemaRegistryService);
2942
+ this.layout = inject(AXPLayoutService);
2943
+ }
2944
+ async create(moduleName, entityName) {
2945
+ this.layout.setNavigationLoading(true);
2946
+ const config = await this.entityService.resolve(moduleName, entityName);
2947
+ let result = this.cache.get(config.name);
2948
+ if (result) {
2949
+ this.layout.setNavigationLoading(false);
2950
+ return result;
2951
+ }
2952
+ result = new AXPListViewLoaderDefault(config, this.schemaService);
2953
+ this.cache.set(config.name, result);
2954
+ this.layout.setNavigationLoading(false);
2955
+ return result;
2956
+ }
2957
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewLoaderFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
2958
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewLoaderFactory, providedIn: 'root' }); }
2959
+ }
2960
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPListViewLoaderFactory, decorators: [{
2961
+ type: Injectable,
2962
+ args: [{ providedIn: 'root' }]
2963
+ }] });
2964
+
2965
+ class AXPEntityQuickViewComponent extends AXBasePageComponent {
2966
+ /**
2967
+ *
2968
+ */
2969
+ constructor(actions$) {
2970
+ super();
2971
+ this.actions$ = actions$;
2972
+ this.store = inject((Store));
2973
+ this.workflow = inject(AXPWorkflowService);
2974
+ }
2975
+ ngOnInit() {
2976
+ super.ngOnInit();
2977
+ //
2978
+ if (this.entity.views.quickView)
2979
+ this.root = this.entity.views.quickView?.root;
2980
+ }
2981
+ getProperties(names) {
2982
+ return this.entity.properties.filter((c) => names.includes(c.name));
2983
+ }
2984
+ handleCloseClick() {
2985
+ this.close();
2986
+ }
2987
+ handleCommandClick(command) {
2988
+ switch (command) {
2989
+ case 'delete':
2990
+ this.workflow.execute('delete-entity', {
2991
+ module: this.entity.module,
2992
+ entity: this.entity.name,
2993
+ ids: [this.data.id],
2994
+ });
2995
+ this.close();
2996
+ break;
2997
+ case 'details':
2998
+ this.store.dispatch(AXPEntityDetailViewAction({
2999
+ payload: {
3000
+ module: this.entity.module,
3001
+ entity: this.entity.name,
3002
+ id: this.data.id,
3003
+ },
3004
+ }));
3005
+ this.close();
3006
+ break;
3007
+ default:
3008
+ break;
3009
+ }
3010
+ }
3011
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityQuickViewComponent, deps: [{ token: i1$5.Actions }], target: i0.ɵɵFactoryTarget.Component }); }
3012
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPEntityQuickViewComponent, isStandalone: true, selector: "ng-component", usesInheritance: true, ngImport: i0, template: "<div class=\"ax-flex ax-flex-col ax-gap-6 ax-p-4\">\n <div class=\"ax-flex ax-flex-col ax-gap-2\" *ngIf=\"root.properties?.length\">\n <div\n *ngFor=\"let p of getProperties(root.properties)\"\n class=\"ax-flex ax-p-4 odd:ax-bg-on-surface odd:ax-border-t odd:ax-border-b\"\n >\n <div class=\"ax-min-w-[10rem] ax-text-gray-500\">\n <span>{{ p.title }}</span>\n </div>\n <div class=\"ax-min-w-[30rem]\">\n <axp-widget-renderer [schema]=\"p.schema\" [context]=\"data\" [prop]=\"p\"></axp-widget-renderer>\n </div>\n </div>\n </div>\n <div\n *ngFor=\"let s of root.sections\"\n class=\"ax-flex ax-flex-col ax-pb-3 last-of-type:ax-border-none last-of-type:ax-pb-3\"\n >\n <div class=\"ax-pb-4\">\n <span class=\"ax-font-bold\">{{ s.title }}</span>\n </div>\n <div class=\"ax-flex ax-flex-col\">\n <div\n *ngFor=\"let p of getProperties(s.properties)\"\n class=\"ax-flex ax-flex-col md:ax-flex-row ax-p-3 odd:ax-bg-on-surface odd:ax-border-t odd:ax-border-b\"\n >\n @if (s.options?.showPropTitle!=false) {\n <div class=\"ax-min-w-[10rem] ax-text-neutral-500 dark:ax-text-neutral-300 ax-mb-2 md:ax-mb-0\">\n <span>{{ p.title }}</span>\n </div>\n }\n <div class=\"md:ax-min-w-[30rem]\">\n <axp-widget-renderer [schema]=\"p.schema\" [context]=\"data\" [prop]=\"p\" [mode]=\"'view'\"></axp-widget-renderer>\n </div>\n </div>\n </div>\n </div>\n</div>\n<ax-footer>\n <ax-prefix> </ax-prefix>\n <ax-suffix>\n <ax-dropdown-button text=\"Close\" (onClick)=\"handleCloseClick()\">\n <ax-button-item-list>\n <ax-button-item text=\"View Details\" (onClick)=\"handleCommandClick('details')\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-info-circle\"></ax-icon>\n </ax-prefix>\n </ax-button-item>\n <ax-button-item class=\"ax-text-danger\" text=\"Delete\" (onClick)=\"handleCommandClick('delete')\">\n <ax-prefix> <ax-icon icon=\"fas fa-trash fa-flip-horizontal\"></ax-icon> </ax-prefix\n ></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-button>\n </ax-suffix>\n</ax-footer>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: AXPSchemaModule }, { kind: "component", type: i1$3.AXPWidgetRendererComponent, selector: "axp-widget-renderer", inputs: ["context", "prop", "mode", "schema"] }, { kind: "ngmodule", type: AXPCommonWidgetModule }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i4.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i4.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items"], outputs: ["onItemClick"] }, { kind: "ngmodule", type: AXDropdownModule }, { kind: "ngmodule", type: AXDropdownButtonModule }, { kind: "component", type: i14.AXDropdownButtonComponent, selector: "ax-dropdown-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "type", "mode"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "lookChange", "colorChange", "disabledChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
3013
+ }
3014
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityQuickViewComponent, decorators: [{
3015
+ type: Component,
3016
+ args: [{ encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [
3017
+ CommonModule,
3018
+ AXPSchemaModule,
3019
+ AXPCommonWidgetModule,
3020
+ AXDecoratorModule,
3021
+ AXButtonModule,
3022
+ AXDropdownModule,
3023
+ AXDropdownButtonModule,
3024
+ ], template: "<div class=\"ax-flex ax-flex-col ax-gap-6 ax-p-4\">\n <div class=\"ax-flex ax-flex-col ax-gap-2\" *ngIf=\"root.properties?.length\">\n <div\n *ngFor=\"let p of getProperties(root.properties)\"\n class=\"ax-flex ax-p-4 odd:ax-bg-on-surface odd:ax-border-t odd:ax-border-b\"\n >\n <div class=\"ax-min-w-[10rem] ax-text-gray-500\">\n <span>{{ p.title }}</span>\n </div>\n <div class=\"ax-min-w-[30rem]\">\n <axp-widget-renderer [schema]=\"p.schema\" [context]=\"data\" [prop]=\"p\"></axp-widget-renderer>\n </div>\n </div>\n </div>\n <div\n *ngFor=\"let s of root.sections\"\n class=\"ax-flex ax-flex-col ax-pb-3 last-of-type:ax-border-none last-of-type:ax-pb-3\"\n >\n <div class=\"ax-pb-4\">\n <span class=\"ax-font-bold\">{{ s.title }}</span>\n </div>\n <div class=\"ax-flex ax-flex-col\">\n <div\n *ngFor=\"let p of getProperties(s.properties)\"\n class=\"ax-flex ax-flex-col md:ax-flex-row ax-p-3 odd:ax-bg-on-surface odd:ax-border-t odd:ax-border-b\"\n >\n @if (s.options?.showPropTitle!=false) {\n <div class=\"ax-min-w-[10rem] ax-text-neutral-500 dark:ax-text-neutral-300 ax-mb-2 md:ax-mb-0\">\n <span>{{ p.title }}</span>\n </div>\n }\n <div class=\"md:ax-min-w-[30rem]\">\n <axp-widget-renderer [schema]=\"p.schema\" [context]=\"data\" [prop]=\"p\" [mode]=\"'view'\"></axp-widget-renderer>\n </div>\n </div>\n </div>\n </div>\n</div>\n<ax-footer>\n <ax-prefix> </ax-prefix>\n <ax-suffix>\n <ax-dropdown-button text=\"Close\" (onClick)=\"handleCloseClick()\">\n <ax-button-item-list>\n <ax-button-item text=\"View Details\" (onClick)=\"handleCommandClick('details')\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-info-circle\"></ax-icon>\n </ax-prefix>\n </ax-button-item>\n <ax-button-item class=\"ax-text-danger\" text=\"Delete\" (onClick)=\"handleCommandClick('delete')\">\n <ax-prefix> <ax-icon icon=\"fas fa-trash fa-flip-horizontal\"></ax-icon> </ax-prefix\n ></ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-button>\n </ax-suffix>\n</ax-footer>\n" }]
3025
+ }], ctorParameters: () => [{ type: i1$5.Actions }] });
3026
+
3027
+ var entityQuickView_component = /*#__PURE__*/Object.freeze({
3028
+ __proto__: null,
3029
+ AXPEntityQuickViewComponent: AXPEntityQuickViewComponent
3030
+ });
3031
+
3032
+ class AXPEntityModifyLoaderDefault {
3033
+ constructor(config, selectedData, selectedSection) {
3034
+ this.config = config;
3035
+ this.selectedData = selectedData;
3036
+ this.selectedSection = selectedSection;
3037
+ this._data = {};
3038
+ //****************** Properties ******************//
3039
+ this.getProp = (name) => this.entity.properties.find((c) => c.name == name);
3040
+ this._data = this.selectedData;
3041
+ this._currentSection = this.selectedSection;
3042
+ }
3043
+ get entity() {
3044
+ if (!this._config) {
3045
+ this._config = cloneDeep(this.config);
3046
+ }
3047
+ return this._config;
3048
+ }
3049
+ get data() {
3050
+ return this._data;
3051
+ }
3052
+ get section() {
3053
+ return this._currentSection;
3054
+ }
3055
+ get view() {
3056
+ return this.entity.views.detailView;
3057
+ }
3058
+ //****************** update ******************//
3059
+ async update(values) {
3060
+ if (this._config.commands?.update) {
3061
+ const updated = await this._config.commands?.update(this._data.id, values);
3062
+ Object.assign(this._data, updated);
3063
+ return Promise.resolve();
3064
+ }
3065
+ else {
3066
+ return Promise.reject(`There is not any update commands for '${this.config.name}'`);
3067
+ }
3068
+ }
3069
+ }
3070
+ class AXPEntityModifyViewLoaderFactory {
3071
+ constructor() {
3072
+ this.entityService = inject(AXPEntityRegistryService);
3073
+ this.layout = inject(AXPLayoutService);
3074
+ }
3075
+ async create(moduleName, entityName, id, section) {
3076
+ this.layout.setNavigationLoading(true);
3077
+ const config = await this.entityService.resolve(moduleName, entityName);
3078
+ if (config.dataSource.byKey) {
3079
+ const data = await config.dataSource.byKey(id);
3080
+ this.layout.setNavigationLoading(false);
3081
+ return new AXPEntityModifyLoaderDefault(config, data, section);
3082
+ }
3083
+ this.layout.setNavigationLoading(false);
3084
+ return Promise.reject('cannot fetch ');
3085
+ }
3086
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityModifyViewLoaderFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
3087
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityModifyViewLoaderFactory, providedIn: 'root' }); }
3088
+ }
3089
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityModifyViewLoaderFactory, decorators: [{
3090
+ type: Injectable,
3091
+ args: [{ providedIn: 'root' }]
3092
+ }] });
3093
+
3094
+ const AXPEntityModifyEvent = createWorkFlowEvent('[Entity] Modified');
3095
+ class AXPEntityModifyPopupAction extends AXPWorkflowAction {
3096
+ constructor() {
3097
+ super(...arguments);
3098
+ this.popupService = inject(AXPopupService);
3099
+ this.platform = inject(AXPlatform);
3100
+ this.entityRegistery = inject(AXPEntityRegistryService);
3101
+ this.entityCreateFactory = inject(AXPEntityModifyViewLoaderFactory);
3102
+ }
3103
+ async execute(context) {
3104
+ const payload = context.getVariable('payload');
3105
+ const { module, entity: entityName, section, id } = payload;
3106
+ const entity = await this.entityRegistery.resolve(module, entityName);
3107
+ const loader = await this.entityCreateFactory.create(module, entityName, id, section);
3108
+ const com = await import('./acorex-platform-layouts-entity-modify-view.component-VeTkP3-n.mjs');
3109
+ const popup = await this.popupService.open(com.AXPEntityModifyViewComponent, {
3110
+ title: `Modify ${payload.section.title}`,
3111
+ size: this.platform.is('Mobile') || this.platform.is('SM') ? 'full' : 'md',
3112
+ data: {
3113
+ context: loader.data,
3114
+ loader: loader,
3115
+ properties: payload.section.properties,
3116
+ entity,
3117
+ },
3118
+ });
3119
+ context.setOutput('popupResult', false);
3120
+ if (popup.data?.result == true) {
3121
+ context.setOutput('popupResult', true);
3122
+ context.setVariable('updatedData', cloneDeep(popup.data.context));
3123
+ }
3124
+ }
3125
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityModifyPopupAction, deps: null, target: i0.ɵɵFactoryTarget.Injectable }); }
3126
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityModifyPopupAction }); }
3127
+ }
3128
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityModifyPopupAction, decorators: [{
3129
+ type: Injectable
3130
+ }] });
3131
+ class AXPEntityModifyConfirmedAction extends AXPWorkflowAction {
3132
+ constructor() {
3133
+ super(...arguments);
3134
+ this.entityRegistery = inject(AXPEntityRegistryService);
3135
+ }
3136
+ async execute(context) {
3137
+ const payload = context.getVariable('payload');
3138
+ const updatedData = context.getVariable('updatedData');
3139
+ const entity = await this.entityRegistery.resolve(payload.module, payload.entity);
3140
+ this.dispatch(AXPEntityModifyEvent({ module: entity.module, entity: entity.name, updateValues: updatedData }));
3141
+ }
3142
+ }
3143
+ const AXPModifyEntityWorkflow = {
3144
+ startStepId: 'modifyPopup',
3145
+ steps: {
3146
+ modifyPopup: {
3147
+ id: 'modifyPopup',
3148
+ action: 'AXPEntityModifyPopupAction',
3149
+ nextSteps: [
3150
+ {
3151
+ conditions: [{ type: 'SINGLE', expression: 'context.getOutput("popupResult") == true' }],
3152
+ nextStepId: 'successToast',
3153
+ },
3154
+ ],
3155
+ },
3156
+ successToast: {
3157
+ id: 'successToast',
3158
+ action: 'AXPToastAction',
3159
+ input: {
3160
+ color: 'success',
3161
+ title: 'Entity Modified',
3162
+ content: 'Record has been successfully updated.',
3163
+ },
3164
+ nextSteps: [
3165
+ {
3166
+ conditions: [],
3167
+ nextStepId: 'modifyConfirmed',
3168
+ },
3169
+ ],
3170
+ },
3171
+ modifyConfirmed: {
3172
+ id: 'modifyConfirmed',
3173
+ action: 'AXPEntityModifyConfirmedAction',
3174
+ nextSteps: [
3175
+ {
3176
+ conditions: [],
3177
+ nextStepId: '',
3178
+ },
3179
+ ],
3180
+ },
3181
+ },
3182
+ };
3183
+
3184
+ class AXPEntityDetailsViewComponent {
3185
+ constructor(actions$, unsubscriber) {
3186
+ this.actions$ = actions$;
3187
+ this.unsubscriber = unsubscriber;
3188
+ this.popupService = inject(AXPopupService);
3189
+ this.sessionService = inject(AXPSessionService);
3190
+ this.activeRoute = inject(ActivatedRoute);
3191
+ this.router = inject(Router);
3192
+ this.location = inject(Location);
3193
+ this.cdr = inject(ChangeDetectorRef);
3194
+ this.platform = inject(AXPlatform);
3195
+ this.workflow = inject(AXPWorkflowService);
3196
+ this.loader = this.activeRoute.snapshot.data['loader'];
3197
+ this.store = inject((Store));
3198
+ this.isSM = this.store.select(isSmallScreen());
3199
+ this.isOpen = this.store.select(getChildDrawer());
3200
+ this.editForm = {};
3201
+ this.context = signal(cloneDeep(this.loader.data));
3202
+ this.activeRoute.paramMap.pipe(first()).subscribe((c) => {
3203
+ this.setSection(c.get('section'));
3204
+ });
3205
+ //
3206
+ this.workflow.events$.pipe(ofType(AXPEntityDeletedEvent), this.unsubscriber.takeUntilDestroy).subscribe((event) => {
3207
+ if (event.payload.entity == this.loader.entity.name &&
3208
+ event.payload.module == this.loader.entity.module &&
3209
+ event.payload.id.includes(this.loader.data.id)) {
3210
+ this.store.dispatch(AXPEntityListViewAction({
3211
+ payload: {
3212
+ module: this.loader.entity.module,
3213
+ entity: this.loader.entity.name,
3214
+ },
3215
+ }));
3216
+ }
3217
+ });
3218
+ this.workflow.events$
3219
+ .pipe(ofType(AXPEntityModifyEvent), this.unsubscriber.takeUntilDestroy)
3220
+ .subscribe(async (event) => {
3221
+ if (event.payload.entity == this.loader.entity.name &&
3222
+ event.payload.module == this.loader.entity.module &&
3223
+ event.payload.updateValues.id === this.loader.data.id) {
3224
+ await this.loader.update(event.payload.updateValues);
3225
+ this.context.set(cloneDeep(this.loader.data));
3226
+ }
3227
+ });
3228
+ }
3229
+ handleMenuClick(e, item) {
3230
+ const entity = this.loader.entity;
3231
+ const path = `/${this.sessionService.application?.name}/${entity.module}/e/${entity.name}/${this.loader.data?.id}/view/${item.name}`;
3232
+ this.location.go(path);
3233
+ this.setSection(item.name);
3234
+ }
3235
+ handleCollapsedChange(value) {
3236
+ if (value)
3237
+ this.store.dispatch(AXPLayoutChildDrawerClose());
3238
+ }
3239
+ handleDrawerClick() {
3240
+ this.store.dispatch(AXPLayoutChildDrawerToggle());
3241
+ }
3242
+ setSection(name) {
3243
+ this.loader.setSection(name);
3244
+ }
3245
+ async handleSectionEdit(section) {
3246
+ this.workflow.execute('modify-entity', {
3247
+ payload: {
3248
+ module: this.loader.entity.module,
3249
+ entity: this.loader.entity.name,
3250
+ id: this.loader.data.id,
3251
+ section: section,
3252
+ },
3253
+ });
3254
+ }
3255
+ isActive(item) {
3256
+ return item.name == window.location.pathname.split('/').pop();
3257
+ }
3258
+ handleCommandClick(command) {
3259
+ switch (command) {
3260
+ case 'delete':
3261
+ this.workflow.execute('delete-entity', {
3262
+ module: this.loader.entity.module,
3263
+ entity: this.loader.entity.name,
3264
+ ids: [this.loader.data.id],
3265
+ });
3266
+ break;
3267
+ case 'create': {
3268
+ this.workflow.execute('create-entity', {
3269
+ payload: {
3270
+ module: this.loader.entity.module,
3271
+ entity: this.loader.entity.name,
3272
+ },
3273
+ });
3274
+ break;
3275
+ }
3276
+ default:
3277
+ break;
3278
+ }
3279
+ }
3280
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityDetailsViewComponent, deps: [{ token: i1$5.Actions }, { token: i2$3.AXUnsubscriber }], target: i0.ɵɵFactoryTarget.Component }); }
3281
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "17.1.2", type: AXPEntityDetailsViewComponent, isStandalone: true, selector: "ng-component", providers: [AXUnsubscriber], viewQueries: [{ propertyName: "drawer", first: true, predicate: ["drawer"], descendants: true }], ngImport: i0, template: "<ax-drawer-container>\n <!-- <ax-drawer #drawer location=\"start\" [collapsed]=\"!(isOpen | async)\" [mode]=\" (isSM | async) ? 'overlay' : 'push'\"\n *ngIf=\"loader.hasSections$ | async\" (collapsedChange)=\"handleCollapsedChange($event)\">\n <ax-content class=\"ax-border-e ax-p-6 ax-w-64\">\n <p class=\"ax-text-xl ax-font-bold ax-mb-6\">{{loader.sectionTitle}}</p>\n <ax-tabs look=\"with-line\" location=\"start\">\n @for(tab of (loader.sections$ | async); track tab.name)\n {\n <ax-tab-item [text]=\"tab.title\" [active]=\"isActive(tab)\" (onClick)=\"handleMenuClick($event,tab)\"\n [disabled]=\"editForm.context\">\n </ax-tab-item>\n }\n </ax-tabs>\n </ax-content>\n </ax-drawer> -->\n <ax-content #content class=\"ax-overflow-x-hidden\">\n <div\n class=\"ax-flex ax-flex-col ax-gap-4 ax-min-h-full ax-px-4 ax-pb-4 md:ax-px-6 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\"\n >\n <div\n class=\"ax-flex ax-flex-col ax-pt-4 ax-sticky ax-top-0 ax-z-10\"\n #sticky=\"axpSticky\"\n [axpSticky]=\"'ax-bg-surface ax-px-6 ax-pt-3 -ax-mx-6'\"\n [stickyParent]=\"content.getHostElement()\"\n >\n <!-------- Begin Toolbar -------->\n <div class=\"ax-flex ax-justify-between ax-items-center\">\n <!-------- Begin Title -------->\n <div class=\"ax-flex ax-gap-1 ax-items-center\">\n <!-- <ax-button class=\"lg:ax-hidden\">\n <ax-icon class=\"fa-solid fa-chevron-left\"></ax-icon>\n </ax-button> -->\n <div class=\"ax-flex ax-flex-col ax-gap-2\">\n <div class=\"ax-text-xl md:ax-text-3xl ax-font-bold\">{{ loader.title }}</div>\n <!-- <ax-breadcrumbs class=\"child:ax-font-normal child:ax-text-neutral-400\">\n <ng-template #divider>\n <i class=\"fa-solid fa-chevron-right ax-text-xs ax-mx-2\"></i>\n </ng-template>\n <ax-breadcrumbs-item>\n <a>Home</a>\n </ax-breadcrumbs-item>\n <ax-breadcrumbs-item>\n <a>{{ loader.entity.title }}</a>\n </ax-breadcrumbs-item>\n <ax-breadcrumbs-item [active]=\"true\" class=\"!ax-font-semibold !ax-text-neutral-600\">\n {{ loader.title }}\n </ax-breadcrumbs-item>\n </ax-breadcrumbs> -->\n </div>\n </div>\n <!-------- Finish Title -------->\n <!--------------------------------------------------------------->\n <!-- Begin Action Menu -->\n <div class=\"ax-flex ax-items-center ax-gap-3\">\n <ax-button [text]=\"(isSM | async) ? null : 'Actions'\" color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis-vertical\"></i>\n </ax-prefix>\n <ax-dropdown-panel>\n <ax-button-item-list>\n <!-- <ax-button-item text=\"Share\" class=\"ax-font-semibold\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-share\"> </ax-icon>\n </ax-prefix>\n </ax-button-item> \n <ax-divider></ax-divider>-->\n <ax-button-item\n text=\"Create New One\"\n class=\"ax-font-semibold ax-text-primary\"\n (onClick)=\"handleCommandClick('create')\"\n >\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-add\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n <ax-button-item\n text=\"Delete\"\n class=\"ax-font-semibold ax-text-danger\"\n (onClick)=\"handleCommandClick('delete')\"\n >\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-trash\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n </div>\n <!-- Finish Action Menu -->\n </div>\n <!----- Finish Toolbar ----->\n <!--------------------------------------------------------------->\n <!-- Begin Section Tab Items -->\n @if((loader.hasSections$| async)) {\n <ax-tabs look=\"with-line\" location=\"bottom\" class=\"ax-mt-2\">\n @for(tab of (loader.sections$ | async); track tab.name) {\n <ax-tab-item\n [text]=\"tab.title\"\n [active]=\"isActive(tab)\"\n (onClick)=\"handleMenuClick($event, tab)\"\n class=\"first:!ax-ms-0\"\n >\n </ax-tab-item>\n }\n </ax-tabs>\n }\n <!-- Finish Section Tab Items -->\n </div>\n @for(section of (loader.section$ | async)?.sections; track section.name) {\n <ax-form #form>\n <div class=\"ax-card ax-shadow-md\">\n <div class=\"ax-card-header\">\n <p>{{ section.title }}</p>\n <ax-button text=\"Modify\" class=\"ax-sm\" color=\"primary\" (onClick)=\"handleSectionEdit(section)\">\n <ax-icon class=\"fa-solid fa-pen\"> </ax-icon>\n </ax-button>\n </div>\n <div class=\"ax-card-body ax-divide-y ax-divide-gray-100 dark:ax-divide-gray-700 !ax-gap-0\">\n <ng-container *ngFor=\"let name of section.properties\">\n <ng-container *ngIf=\"loader.getProp(name) as prop\">\n <div class=\"ax-grid md:ax-grid-cols-12 ax-gap-2 ax-py-4 first:ax-pt-0 last:ax-pb-0\">\n @if(section.options?.showPropTitle!=false){\n <div\n class=\"ax-col-span-12 md:ax-col-span-3 lg:ax-col-span-2 ax-flex ax-items-center md:ax-items-start ax-justify-between\"\n >\n <div class=\"ax-flex ax-gap-2 ax-items-center\">\n <span class=\"ax-font-semibold\">{{ prop.title }}</span>\n @if(prop.description) {\n <i\n class=\"fa-solid fa-circle-info fa-sm ax-text-neutral-500 dark:ax-text-neutral-400 ax-cursor-pointer\"\n [axTooltip]=\"prop.description\"\n [axTooltipPlacement]=\"'end'\"\n ></i>\n }\n </div>\n </div>\n }\n <div\n [class]=\"\n section.options?.showPropTitle == false\n ? 'ax-col-span-12'\n : 'ax-col-span-12 md:ax-col-span-9 lg:ax-col-span-10'\n \"\n >\n <axp-widget-renderer\n [schema]=\"prop.schema\"\n [context]=\"context()\"\n [prop]=\"prop\"\n [mode]=\"'view'\"\n ></axp-widget-renderer>\n </div>\n </div>\n </ng-container>\n </ng-container>\n </div>\n </div>\n </ax-form>\n }\n </div>\n </ax-content>\n</ax-drawer-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "ngmodule", type: RouterModule }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "component", type: i4.AXButtonItemComponent, selector: "ax-button-item", inputs: ["color", "disabled", "text", "selected", "divided", "data", "name"], outputs: ["onClick", "onFocus", "onBlur", "disabledChange"] }, { kind: "component", type: i4.AXButtonItemListComponent, selector: "ax-button-item-list", inputs: ["items"], outputs: ["onItemClick"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }, { kind: "component", type: i3.AXDecoratorGenericComponent, selector: "ax-footer, ax-header, ax-content, ax-divider, ax-form-hint, ax-prefix, ax-suffix, ax-text, ax-title , ax-sub-title, ax-placeholder, ax-overlay" }, { kind: "ngmodule", type: AXBadgeModule }, { kind: "ngmodule", type: AXDropdownModule }, { kind: "component", type: i10.AXDropdownPanelComponent, selector: "ax-dropdown-panel", inputs: ["isOpen", "fitParent", "dropdownWidth", "position", "_target", "adaptivityEnabled"], outputs: ["onOpened", "onClosed"] }, { kind: "ngmodule", type: AXPopoverModule }, { kind: "ngmodule", type: AXFormModule }, { kind: "component", type: i3$3.AXFormComponent, selector: "ax-form", inputs: ["messageStyle", "updateOn"], outputs: ["onValidate", "updateOnChange"] }, { kind: "ngmodule", type: AXImageModule }, { kind: "ngmodule", type: AXActionSheetModule }, { kind: "ngmodule", type: AXSwitchModule }, { kind: "ngmodule", type: AXDrawerModule }, { kind: "component", type: i4$1.AXDrawerContainerComponent, selector: "ax-drawer-container" }, { kind: "ngmodule", type: AXDialogModule }, { kind: "ngmodule", type: AXLoadingModule }, { kind: "ngmodule", type: AXTabsModule }, { kind: "component", type: i9.AXTabsComponent, selector: "ax-tabs", inputs: ["look", "location", "fitParent", "minWidth", "content"], outputs: ["onActiveTabChanged"] }, { kind: "component", type: i9.AXTabItemComponent, selector: "ax-tab-item", inputs: ["disabled", "text", "key", "headerTemplate", "active"], outputs: ["disabledChange", "onClick", "onBlur", "onFocus", "activeChange"] }, { kind: "ngmodule", type: AXPSchemaModule }, { kind: "component", type: i1$3.AXPWidgetRendererComponent, selector: "axp-widget-renderer", inputs: ["context", "prop", "mode", "schema"] }, { kind: "ngmodule", type: AXTooltipModule }, { kind: "directive", type: i11.AXTooltipDirective, selector: "[axTooltip]", inputs: ["axTooltip", "axTooltipPlacement", "axTooltipOpenAfter", "axTooltipCloseAfter"] }, { kind: "ngmodule", type: AXBreadcrumbsModule }, { kind: "ngmodule", type:
3282
+ //
3283
+ AXPCommonWidgetModule }, { kind: "directive", type: AXPStickyDirective, selector: "[axpSticky]", inputs: ["axpSticky", "stickyParent", "stickyTarget"], outputs: ["isStickyChange"], exportAs: ["axpSticky"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
3284
+ }
3285
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityDetailsViewComponent, decorators: [{
3286
+ type: Component,
3287
+ args: [{ imports: [
3288
+ CommonModule,
3289
+ RouterModule,
3290
+ AXButtonModule,
3291
+ AXDecoratorModule,
3292
+ AXBadgeModule,
3293
+ AXDropdownModule,
3294
+ AXPopoverModule,
3295
+ AXFormModule,
3296
+ AXImageModule,
3297
+ AXActionSheetModule,
3298
+ AXSwitchModule,
3299
+ AXDrawerModule,
3300
+ AXDialogModule,
3301
+ AXLoadingModule,
3302
+ AXTabsModule,
3303
+ AXBadgeModule,
3304
+ AXButtonModule,
3305
+ AXSwitchModule,
3306
+ AXPSchemaModule,
3307
+ AXTooltipModule,
3308
+ AXBreadcrumbsModule,
3309
+ //
3310
+ AXPCommonWidgetModule,
3311
+ AXPStickyDirective,
3312
+ ], standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, providers: [AXUnsubscriber], template: "<ax-drawer-container>\n <!-- <ax-drawer #drawer location=\"start\" [collapsed]=\"!(isOpen | async)\" [mode]=\" (isSM | async) ? 'overlay' : 'push'\"\n *ngIf=\"loader.hasSections$ | async\" (collapsedChange)=\"handleCollapsedChange($event)\">\n <ax-content class=\"ax-border-e ax-p-6 ax-w-64\">\n <p class=\"ax-text-xl ax-font-bold ax-mb-6\">{{loader.sectionTitle}}</p>\n <ax-tabs look=\"with-line\" location=\"start\">\n @for(tab of (loader.sections$ | async); track tab.name)\n {\n <ax-tab-item [text]=\"tab.title\" [active]=\"isActive(tab)\" (onClick)=\"handleMenuClick($event,tab)\"\n [disabled]=\"editForm.context\">\n </ax-tab-item>\n }\n </ax-tabs>\n </ax-content>\n </ax-drawer> -->\n <ax-content #content class=\"ax-overflow-x-hidden\">\n <div\n class=\"ax-flex ax-flex-col ax-gap-4 ax-min-h-full ax-px-4 ax-pb-4 md:ax-px-6 ax-bg-surface ax-border-b md:ax-border-0 md:ax-bg-default\"\n >\n <div\n class=\"ax-flex ax-flex-col ax-pt-4 ax-sticky ax-top-0 ax-z-10\"\n #sticky=\"axpSticky\"\n [axpSticky]=\"'ax-bg-surface ax-px-6 ax-pt-3 -ax-mx-6'\"\n [stickyParent]=\"content.getHostElement()\"\n >\n <!-------- Begin Toolbar -------->\n <div class=\"ax-flex ax-justify-between ax-items-center\">\n <!-------- Begin Title -------->\n <div class=\"ax-flex ax-gap-1 ax-items-center\">\n <!-- <ax-button class=\"lg:ax-hidden\">\n <ax-icon class=\"fa-solid fa-chevron-left\"></ax-icon>\n </ax-button> -->\n <div class=\"ax-flex ax-flex-col ax-gap-2\">\n <div class=\"ax-text-xl md:ax-text-3xl ax-font-bold\">{{ loader.title }}</div>\n <!-- <ax-breadcrumbs class=\"child:ax-font-normal child:ax-text-neutral-400\">\n <ng-template #divider>\n <i class=\"fa-solid fa-chevron-right ax-text-xs ax-mx-2\"></i>\n </ng-template>\n <ax-breadcrumbs-item>\n <a>Home</a>\n </ax-breadcrumbs-item>\n <ax-breadcrumbs-item>\n <a>{{ loader.entity.title }}</a>\n </ax-breadcrumbs-item>\n <ax-breadcrumbs-item [active]=\"true\" class=\"!ax-font-semibold !ax-text-neutral-600\">\n {{ loader.title }}\n </ax-breadcrumbs-item>\n </ax-breadcrumbs> -->\n </div>\n </div>\n <!-------- Finish Title -------->\n <!--------------------------------------------------------------->\n <!-- Begin Action Menu -->\n <div class=\"ax-flex ax-items-center ax-gap-3\">\n <ax-button [text]=\"(isSM | async) ? null : 'Actions'\" color=\"ghost\">\n <ax-prefix>\n <i class=\"fa-solid fa-ellipsis-vertical\"></i>\n </ax-prefix>\n <ax-dropdown-panel>\n <ax-button-item-list>\n <!-- <ax-button-item text=\"Share\" class=\"ax-font-semibold\">\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-share\"> </ax-icon>\n </ax-prefix>\n </ax-button-item> \n <ax-divider></ax-divider>-->\n <ax-button-item\n text=\"Create New One\"\n class=\"ax-font-semibold ax-text-primary\"\n (onClick)=\"handleCommandClick('create')\"\n >\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-add\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n <ax-button-item\n text=\"Delete\"\n class=\"ax-font-semibold ax-text-danger\"\n (onClick)=\"handleCommandClick('delete')\"\n >\n <ax-prefix>\n <ax-icon icon=\"fa-solid fa-trash\"> </ax-icon>\n </ax-prefix>\n </ax-button-item>\n </ax-button-item-list>\n </ax-dropdown-panel>\n </ax-button>\n </div>\n <!-- Finish Action Menu -->\n </div>\n <!----- Finish Toolbar ----->\n <!--------------------------------------------------------------->\n <!-- Begin Section Tab Items -->\n @if((loader.hasSections$| async)) {\n <ax-tabs look=\"with-line\" location=\"bottom\" class=\"ax-mt-2\">\n @for(tab of (loader.sections$ | async); track tab.name) {\n <ax-tab-item\n [text]=\"tab.title\"\n [active]=\"isActive(tab)\"\n (onClick)=\"handleMenuClick($event, tab)\"\n class=\"first:!ax-ms-0\"\n >\n </ax-tab-item>\n }\n </ax-tabs>\n }\n <!-- Finish Section Tab Items -->\n </div>\n @for(section of (loader.section$ | async)?.sections; track section.name) {\n <ax-form #form>\n <div class=\"ax-card ax-shadow-md\">\n <div class=\"ax-card-header\">\n <p>{{ section.title }}</p>\n <ax-button text=\"Modify\" class=\"ax-sm\" color=\"primary\" (onClick)=\"handleSectionEdit(section)\">\n <ax-icon class=\"fa-solid fa-pen\"> </ax-icon>\n </ax-button>\n </div>\n <div class=\"ax-card-body ax-divide-y ax-divide-gray-100 dark:ax-divide-gray-700 !ax-gap-0\">\n <ng-container *ngFor=\"let name of section.properties\">\n <ng-container *ngIf=\"loader.getProp(name) as prop\">\n <div class=\"ax-grid md:ax-grid-cols-12 ax-gap-2 ax-py-4 first:ax-pt-0 last:ax-pb-0\">\n @if(section.options?.showPropTitle!=false){\n <div\n class=\"ax-col-span-12 md:ax-col-span-3 lg:ax-col-span-2 ax-flex ax-items-center md:ax-items-start ax-justify-between\"\n >\n <div class=\"ax-flex ax-gap-2 ax-items-center\">\n <span class=\"ax-font-semibold\">{{ prop.title }}</span>\n @if(prop.description) {\n <i\n class=\"fa-solid fa-circle-info fa-sm ax-text-neutral-500 dark:ax-text-neutral-400 ax-cursor-pointer\"\n [axTooltip]=\"prop.description\"\n [axTooltipPlacement]=\"'end'\"\n ></i>\n }\n </div>\n </div>\n }\n <div\n [class]=\"\n section.options?.showPropTitle == false\n ? 'ax-col-span-12'\n : 'ax-col-span-12 md:ax-col-span-9 lg:ax-col-span-10'\n \"\n >\n <axp-widget-renderer\n [schema]=\"prop.schema\"\n [context]=\"context()\"\n [prop]=\"prop\"\n [mode]=\"'view'\"\n ></axp-widget-renderer>\n </div>\n </div>\n </ng-container>\n </ng-container>\n </div>\n </div>\n </ax-form>\n }\n </div>\n </ax-content>\n</ax-drawer-container>\n" }]
3313
+ }], ctorParameters: () => [{ type: i1$5.Actions }, { type: i2$3.AXUnsubscriber }], propDecorators: { drawer: [{
3314
+ type: ViewChild,
3315
+ args: ['drawer']
3316
+ }] } });
3317
+
3318
+ class AXPEntityDetailLoaderDefault {
3319
+ constructor(config, store, entityData, formatService) {
3320
+ this.config = config;
3321
+ this.store = store;
3322
+ this.entityData = entityData;
3323
+ this.formatService = formatService;
3324
+ this._currentSection = 'default';
3325
+ this._sections$ = new BehaviorSubject(this.sections);
3326
+ //****************** Properties ******************//
3327
+ this.getProp = (name) => this.entity.properties.find((c) => c.name == name);
3328
+ }
3329
+ get entity() {
3330
+ if (!this._config) {
3331
+ this._config = cloneDeep(this.config);
3332
+ }
3333
+ return this._config;
3334
+ }
3335
+ get data() {
3336
+ return this.entityData;
3337
+ }
3338
+ get view() {
3339
+ return (this.entity.views.detailView ?? this.entity.views.quickView);
3340
+ }
3341
+ //****************** Titles ******************//
3342
+ get title() {
3343
+ const suggestedProps = this.entity.properties.find((c) => ['title', 'name', 'code'].includes(c.name));
3344
+ let suggestedFormat = 'Item #{{id}}';
3345
+ if (suggestedProps)
3346
+ suggestedFormat = `{{${suggestedProps.name}}}`;
3347
+ const title = this.formatService.format(this.entity.formats?.header ?? this.entity.formats?.default ?? suggestedFormat, 'string', this.data);
3348
+ return title;
3349
+ }
3350
+ get sectionTitle() {
3351
+ return `${this.entity.title}`;
3352
+ }
3353
+ //****************** Sections ******************//
3354
+ get sections() {
3355
+ return this.view.root.sections?.length
3356
+ ? this.view.root.sections
3357
+ : [
3358
+ {
3359
+ name: 'default',
3360
+ title: 'Default',
3361
+ properties: this.view.root.properties,
3362
+ },
3363
+ ];
3364
+ }
3365
+ get sections$() {
3366
+ return this._sections$.pipe(defaultIfEmpty([]));
3367
+ }
3368
+ get section$() {
3369
+ return this.sections$.pipe(switchMap((sections) => {
3370
+ const section = sections.find((c) => c.name === this._currentSection) ?? this.sections[0];
3371
+ if (!section.sections?.length) {
3372
+ section.sections = [
3373
+ {
3374
+ name: 'default',
3375
+ title: 'Details',
3376
+ properties: section.properties,
3377
+ },
3378
+ ];
3379
+ }
3380
+ return of(section);
3381
+ }));
3382
+ }
3383
+ get hasSections$() {
3384
+ return this.sections$.pipe(map((c) => c.length > 1));
3385
+ }
3386
+ setSection(name) {
3387
+ this._currentSection = name ?? 'default';
3388
+ const updatedSection = this.sections.find((c) => c.name === this._currentSection) || {
3389
+ name: 'default',
3390
+ title: 'Default',
3391
+ properties: this.view.root.properties,
3392
+ };
3393
+ const currentSections = this._sections$.value;
3394
+ const updatedSections = currentSections.map((section) => {
3395
+ if (section.name === updatedSection.name) {
3396
+ return updatedSection;
3397
+ }
3398
+ else {
3399
+ return section;
3400
+ }
3401
+ });
3402
+ this._sections$.next(updatedSections);
3403
+ }
3404
+ //****************** Update ******************//
3405
+ async update(values) {
3406
+ assign(this.data, values);
3407
+ this.setSection(this._currentSection);
3408
+ }
3409
+ }
3410
+ class AXPEntityDetailViewLoaderFactory {
3411
+ constructor() {
3412
+ this.entityService = inject(AXPEntityRegistryService);
3413
+ this.formatService = inject(AXFormatService);
3414
+ this.layout = inject(AXPLayoutService);
3415
+ this.store = inject(Store);
3416
+ }
3417
+ async create(moduleName, entityName, id) {
3418
+ const config = await this.entityService.resolve(moduleName, entityName);
3419
+ this.layout.setNavigationLoading(true);
3420
+ if (config.dataSource.byKey) {
3421
+ const data = await config.dataSource.byKey(id);
3422
+ this.layout.setNavigationLoading(false);
3423
+ return new AXPEntityDetailLoaderDefault(config, this.store, data, this.formatService);
3424
+ }
3425
+ this.layout.setNavigationLoading(false);
3426
+ return Promise.reject('cannot fetch ');
3427
+ }
3428
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityDetailViewLoaderFactory, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
3429
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityDetailViewLoaderFactory, providedIn: 'root' }); }
3430
+ }
3431
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityDetailViewLoaderFactory, decorators: [{
3432
+ type: Injectable,
3433
+ args: [{ providedIn: 'root' }]
3434
+ }] });
3435
+
3436
+ class AXPCustomReuseStrategy {
3437
+ shouldDetach(route) {
3438
+ return false;
3439
+ }
3440
+ store(route, detachedTree) { }
3441
+ shouldAttach(route) {
3442
+ return false;
3443
+ }
3444
+ retrieve(route) {
3445
+ return null;
3446
+ }
3447
+ shouldReuseRoute(future, curr) {
3448
+ if (future.component === AXPEntityListViewComponent || future.component === AXPEntityDetailsViewComponent) {
3449
+ return false;
3450
+ }
3451
+ return future.routeConfig === curr.routeConfig;
3452
+ }
3453
+ }
3454
+
3455
+ class AXPEntityEffects {
3456
+ constructor(actions$, store) {
3457
+ this.actions$ = actions$;
3458
+ this.store = store;
3459
+ this.sessionService = inject(AXPSessionService);
3460
+ this.entityRegistery = inject(AXPEntityRegistryService);
3461
+ this.entityCreateFactory = inject(AXPEntityCreateViewLoaderFactory);
3462
+ this.entityModifyFactory = inject(AXPEntityModifyViewLoaderFactory);
3463
+ this.popupService = inject(AXPopupService);
3464
+ this.dialogService = inject(AXDialogService);
3465
+ this.toastService = inject(AXToastService);
3466
+ this.formatService = inject(AXFormatService);
3467
+ this.platform = inject(AXPlatform);
3468
+ this.quickView$ = createEffect(() => this.actions$.pipe(ofType(AXPEntityQuickViewAction), switchMap(async (action) => {
3469
+ const entity = await this.entityRegistery.resolve(action.payload.module, action.payload.entity);
3470
+ const suggestedProps = entity.properties.find((c) => ['title', 'name', 'code'].includes(c.name));
3471
+ let suggestedFormat = 'Item #{{id}}';
3472
+ if (suggestedProps)
3473
+ suggestedFormat = `{{${suggestedProps.name}}}`;
3474
+ const title = this.formatService.format(entity.formats?.header ?? entity.formats?.default ?? suggestedFormat, 'string', action.payload.data);
3475
+ //
3476
+ const com = await Promise.resolve().then(function () { return entityQuickView_component; });
3477
+ this.popupService.open(com.AXPEntityQuickViewComponent, {
3478
+ title: `${title} - Quick View`,
3479
+ size: this.platform.is('Mobile') || this.platform.is('SM') ? 'full' : 'md',
3480
+ data: {
3481
+ entity: entity,
3482
+ data: action.payload.data,
3483
+ },
3484
+ });
3485
+ return of();
3486
+ })), { dispatch: false });
3487
+ this.detailView$ = createEffect(() => this.actions$.pipe(ofType(AXPEntityDetailViewAction), switchMap(async (action) => {
3488
+ const entity = await this.entityRegistery.resolve(action.payload.module, action.payload.entity);
3489
+ this.store.dispatch(AXPNavigateAction$1({
3490
+ payload: {
3491
+ commands: `/${this.sessionService.application?.name}/${entity.module}/e/${entity.name}/${action.payload.id}/view`,
3492
+ },
3493
+ }));
3494
+ return of();
3495
+ })), { dispatch: false });
3496
+ this.listView$ = createEffect(() => this.actions$.pipe(ofType(AXPEntityListViewAction), switchMap(async (action) => {
3497
+ const entity = await this.entityRegistery.resolve(action.payload.module, action.payload.entity);
3498
+ this.store.dispatch(AXPNavigateAction$1({
3499
+ payload: {
3500
+ commands: `/${this.sessionService.application?.name}/${entity.module}/e/${entity.name}/list`,
3501
+ },
3502
+ }));
3503
+ return of();
3504
+ })), { dispatch: false });
3505
+ }
3506
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityEffects, deps: [{ token: i1$5.Actions }, { token: i2$4.Store }], target: i0.ɵɵFactoryTarget.Injectable }); }
3507
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityEffects }); }
3508
+ }
3509
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPEntityEffects, decorators: [{
3510
+ type: Injectable
3511
+ }], ctorParameters: () => [{ type: i1$5.Actions }, { type: i2$4.Store }] });
3512
+
3513
+ class AXPAdminLayoutModule {
3514
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminLayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
3515
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminLayoutModule, imports: [i2$4.StoreFeatureModule, i1$5.EffectsFeatureModule, AXPAdminRootLayoutModule,
3516
+ AXPListViewModule, i3$4.AXPWorkflowModule] }); }
3517
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminLayoutModule, providers: [{ provide: RouteReuseStrategy, useClass: AXPCustomReuseStrategy }], imports: [StoreModule.forFeature(AXPLayoutFeature),
3518
+ EffectsModule.forFeature([AXPLayoutEffects, AXPEntityEffects]),
3519
+ AXPAdminRootLayoutModule,
3520
+ AXPListViewModule,
3521
+ AXPWorkflowModule.forChild({
3522
+ actions: {
3523
+ AXPEntityPerformDeleteAction,
3524
+ AXPEntityModifyPopupAction,
3525
+ AXPEntityModifyConfirmedAction,
3526
+ AXPEntityCreatePopupAction,
3527
+ AXPEntityCreateSubmittedAction,
3528
+ },
3529
+ workflows: {
3530
+ 'delete-entity': AXPDeleteEntityWorkflow,
3531
+ 'modify-entity': AXPModifyEntityWorkflow,
3532
+ 'create-entity': AXPCreateEntityWorkflow,
3533
+ },
3534
+ functions: {
3535
+ test: AXPMyCustomFunc,
3536
+ },
3537
+ })] }); }
3538
+ }
3539
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPAdminLayoutModule, decorators: [{
3540
+ type: NgModule,
3541
+ args: [{
3542
+ imports: [
3543
+ StoreModule.forFeature(AXPLayoutFeature),
3544
+ EffectsModule.forFeature([AXPLayoutEffects, AXPEntityEffects]),
3545
+ AXPAdminRootLayoutModule,
3546
+ AXPListViewModule,
3547
+ AXPWorkflowModule.forChild({
3548
+ actions: {
3549
+ AXPEntityPerformDeleteAction,
3550
+ AXPEntityModifyPopupAction,
3551
+ AXPEntityModifyConfirmedAction,
3552
+ AXPEntityCreatePopupAction,
3553
+ AXPEntityCreateSubmittedAction,
3554
+ },
3555
+ workflows: {
3556
+ 'delete-entity': AXPDeleteEntityWorkflow,
3557
+ 'modify-entity': AXPModifyEntityWorkflow,
3558
+ 'create-entity': AXPCreateEntityWorkflow,
3559
+ },
3560
+ functions: {
3561
+ test: AXPMyCustomFunc,
3562
+ },
3563
+ }),
3564
+ ],
3565
+ exports: [],
3566
+ declarations: [],
3567
+ providers: [{ provide: RouteReuseStrategy, useClass: AXPCustomReuseStrategy }],
3568
+ }]
3569
+ }] });
3570
+
3571
+ const AXPListViewLoaderResolver = (route, state, service = inject(AXPListViewLoaderFactory)) => {
3572
+ const appName = route.parent?.paramMap.get('app');
3573
+ const moduleName = route.parent?.paramMap.get('module');
3574
+ const entityName = route.paramMap.get('entity');
3575
+ // console.log(appName, moduleName, entityName);
3576
+ //
3577
+ return service.create(moduleName, entityName);
3578
+ };
3579
+ const AXPEntityDetailViewLoaderResolver = (route, state, service = inject(AXPEntityDetailViewLoaderFactory)) => {
3580
+ const appName = route.parent?.paramMap.get('app');
3581
+ const moduleName = route.parent?.paramMap.get('module');
3582
+ const entityName = route.paramMap.get('entity');
3583
+ const id = route.paramMap.get('id');
3584
+ // console.log(appName, moduleName, entityName, id);
3585
+ //
3586
+ return service.create(moduleName, entityName, id);
3587
+ };
3588
+
3589
+ const AX_ADMIN_ROUTES = [
3590
+ {
3591
+ path: ':app',
3592
+ canActivate: [AXPAuthGuard],
3593
+ children: [
3594
+ {
3595
+ path: ':module',
3596
+ children: [
3597
+ {
3598
+ path: 'e/:entity/:id/view/:section',
3599
+ resolve: { loader: AXPEntityDetailViewLoaderResolver },
3600
+ component: AXPEntityDetailsViewComponent,
3601
+ },
3602
+ {
3603
+ path: 'e/:entity/:id/view',
3604
+ resolve: { loader: AXPEntityDetailViewLoaderResolver },
3605
+ component: AXPEntityDetailsViewComponent,
3606
+ },
3607
+ {
3608
+ path: 'e/:entity',
3609
+ redirectTo: ':entity/list',
3610
+ pathMatch: 'full',
3611
+ },
3612
+ {
3613
+ path: 'e/:entity/list',
3614
+ component: AXPEntityListViewComponent,
3615
+ resolve: { loader: AXPListViewLoaderResolver },
3616
+ },
3617
+ ],
3618
+ },
3619
+ ],
3620
+ },
3621
+ ];
3622
+
3623
+ const routes = [
3624
+ {
3625
+ path: 'offline',
3626
+ loadComponent: () => Promise.resolve().then(function () { return errorOffline_component; }).then(c => c.AXPErrorOfflineComponent),
3627
+ },
3628
+ {
3629
+ path: '404',
3630
+ loadComponent: () => Promise.resolve().then(function () { return error404_component; }).then(c => c.AXPError404Component),
3631
+ },
3632
+ {
3633
+ path: '401',
3634
+ loadComponent: () => Promise.resolve().then(function () { return error401_component; }).then(c => c.AXPError401Component),
3635
+ },
3636
+ ];
3637
+
3638
+ class AXPThemeSlotComponent {
3639
+ constructor() {
3640
+ this.store = inject((Store));
3641
+ this.isDark = this.store.select(isDarkTheme());
3642
+ }
3643
+ switchMode() {
3644
+ this.store.dispatch(AXPLayoutThemeDarkToggleAction());
3645
+ }
3646
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPThemeSlotComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
3647
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.1.2", type: AXPThemeSlotComponent, isStandalone: true, selector: "ng-component", ngImport: i0, template: `
3648
+ <ax-button color="default" look="blank" (onClick)="switchMode()">
3649
+ <ax-icon>
3650
+ <i class="fa-solid fa-brightness ax-text-slate-400 dark:ax-text-slate-200" *ngIf="isDark | async"></i>
3651
+ <i class="fa-solid fa-moon ax-text-slate-400 dark:ax-text-slate-200" *ngIf="!(isDark | async)"></i>
3652
+ </ax-icon>
3653
+ </ax-button>
3654
+ `, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "ngmodule", type: AXButtonModule }, { kind: "component", type: i4.AXButtonComponent, selector: "ax-button", inputs: ["disabled", "size", "tabIndex", "color", "look", "text", "toggleable", "selected", "type"], outputs: ["onBlur", "onFocus", "onClick", "selectedChange", "toggleableChange", "lookChange", "colorChange", "disabledChange"] }, { kind: "ngmodule", type: AXDecoratorModule }, { kind: "component", type: i3.AXDecoratorIconComponent, selector: "ax-icon", inputs: ["icon"] }] }); }
3655
+ }
3656
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPThemeSlotComponent, decorators: [{
3657
+ type: Component,
3658
+ args: [{
3659
+ template: `
3660
+ <ax-button color="default" look="blank" (onClick)="switchMode()">
3661
+ <ax-icon>
3662
+ <i class="fa-solid fa-brightness ax-text-slate-400 dark:ax-text-slate-200" *ngIf="isDark | async"></i>
3663
+ <i class="fa-solid fa-moon ax-text-slate-400 dark:ax-text-slate-200" *ngIf="!(isDark | async)"></i>
3664
+ </ax-icon>
3665
+ </ax-button>
3666
+ `,
3667
+ standalone: true,
3668
+ imports: [
3669
+ CommonModule,
3670
+ AXButtonModule,
3671
+ AXDecoratorModule
3672
+ ]
3673
+ }]
3674
+ }] });
3675
+
3676
+ class AXPLayoutModule {
3677
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
3678
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutModule, imports: [i1.RouterModule, i2.AXPCommonModule, i2.AXPComponentSlotModule, i3$4.AXPWorkflowModule], exports: [RouterModule] }); }
3679
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutModule, imports: [RouterModule.forChild(routes),
3680
+ AXPCommonModule.forChild({ errorHandlers: [AXMWorkflowErrorHandler] }),
3681
+ AXPComponentSlotModule.forChild({
3682
+ 'header-end': [
3683
+ {
3684
+ name: 'theme',
3685
+ component: AXPThemeSlotComponent,
3686
+ },
3687
+ ],
3688
+ }),
3689
+ AXPWorkflowModule.forChild({
3690
+ actions: {
3691
+ AXPNavigateAction,
3692
+ AXPDialogConfirmAction,
3693
+ AXPToastAction,
3694
+ AXPShowDetailViewAction,
3695
+ AXPShowListViewAction,
3696
+ },
3697
+ }), RouterModule] }); }
3698
+ }
3699
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.1.2", ngImport: i0, type: AXPLayoutModule, decorators: [{
3700
+ type: NgModule,
3701
+ args: [{
3702
+ imports: [
3703
+ RouterModule.forChild(routes),
3704
+ AXPCommonModule.forChild({ errorHandlers: [AXMWorkflowErrorHandler] }),
3705
+ AXPComponentSlotModule.forChild({
3706
+ 'header-end': [
3707
+ {
3708
+ name: 'theme',
3709
+ component: AXPThemeSlotComponent,
3710
+ },
3711
+ ],
3712
+ }),
3713
+ AXPWorkflowModule.forChild({
3714
+ actions: {
3715
+ AXPNavigateAction,
3716
+ AXPDialogConfirmAction,
3717
+ AXPToastAction,
3718
+ AXPShowDetailViewAction,
3719
+ AXPShowListViewAction,
3720
+ },
3721
+ }),
3722
+ ],
3723
+ exports: [RouterModule],
3724
+ }]
3725
+ }] });
3726
+
3727
+ /**
3728
+ * Generated bundle index. Do not edit.
3729
+ */
3730
+
3731
+ export { AXEntityLoaderDefault, AXMWorkflowErrorHandler, AXPAdminChildFeaturesListComponent, AXPAdminChildLayoutComponent, AXPAdminChildLayoutModule, AXPAdminHeaderComponent, AXPAdminLayoutComponent, AXPAdminLayoutModule, AXPAdminRootLayoutModule, AXPCommonWidgetModule, AXPContentViewComponent, AXPCustomReuseStrategy, AXPDialogConfirmAction, AXPEntityCreateCustomViewComponent, AXPEntityDetailLoaderDefault, AXPEntityDetailViewLoaderFactory, AXPEntityDetailViewLoaderResolver, AXPEntityDetailsViewComponent, AXPEntityListViewComponent, AXPEntityListViewConfigEmpty, AXPEntityQuickViewComponent, AXPEntityRegistryService, AXPError401Component, AXPError404Component, AXPErrorOfflineComponent, AXPFooterTextSlotComponent, AXPLayoutModule, AXPLayoutService, AXPListViewLoaderDefault, AXPListViewLoaderFactory, AXPListViewLoaderResolver, AXPListViewModule, AXPListViewOptionConditionsComponent, AXPListViewOptionFilterOperatorComponent, AXPListViewOptionSortingComponent, AXPListViewOptionsColumnsComponent, AXPLogoComponent, AXPNavBarSlotComponent, AXPNavigateAction, AXPRedirectEvent, AXPShowDetailViewAction, AXPShowListViewAction, AXPToastAction, AXP_ENTITY_LOADER, AXP_LISTVIEW_LOADER, AX_ADMIN_ROUTES, convertPropertiesToColumns, convertPropertyToColumn, widgetSchemas };
3732
+ //# sourceMappingURL=acorex-platform-layouts.mjs.map