@c8y/ngx-components 1023.76.0 → 1023.78.1

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 (265) hide show
  1. package/alarms/cockpit/index.d.ts.map +1 -1
  2. package/alarms/devicemanagement/index.d.ts.map +1 -1
  3. package/alarms/index.d.ts +2 -25
  4. package/alarms/index.d.ts.map +1 -1
  5. package/asset-properties/index.d.ts +63 -0
  6. package/asset-properties/index.d.ts.map +1 -1
  7. package/assets-navigator/index.d.ts +4 -0
  8. package/assets-navigator/index.d.ts.map +1 -1
  9. package/exports/list/index.d.ts +7 -4
  10. package/exports/list/index.d.ts.map +1 -1
  11. package/fesm2022/c8y-ngx-components-actility-device-registration.mjs +16 -16
  12. package/fesm2022/c8y-ngx-components-advanced-software-management.mjs +7 -7
  13. package/fesm2022/c8y-ngx-components-ai-agent-chat.mjs +12 -12
  14. package/fesm2022/c8y-ngx-components-ai-ai-chat.mjs +21 -21
  15. package/fesm2022/c8y-ngx-components-ai.mjs +3 -3
  16. package/fesm2022/c8y-ngx-components-alarm-event-selector.mjs +40 -40
  17. package/fesm2022/c8y-ngx-components-alarms-cockpit.mjs +15 -10
  18. package/fesm2022/c8y-ngx-components-alarms-cockpit.mjs.map +1 -1
  19. package/fesm2022/c8y-ngx-components-alarms-devicemanagement.mjs +11 -37
  20. package/fesm2022/c8y-ngx-components-alarms-devicemanagement.mjs.map +1 -1
  21. package/fesm2022/c8y-ngx-components-alarms.mjs +91 -132
  22. package/fesm2022/c8y-ngx-components-alarms.mjs.map +1 -1
  23. package/fesm2022/c8y-ngx-components-api.mjs +7 -7
  24. package/fesm2022/c8y-ngx-components-app-logs.mjs +10 -10
  25. package/fesm2022/c8y-ngx-components-application-access-list.mjs +12 -12
  26. package/fesm2022/c8y-ngx-components-application-access-user-application-access-user-details-wrapper.mjs +3 -3
  27. package/fesm2022/c8y-ngx-components-asset-properties.mjs +223 -69
  28. package/fesm2022/c8y-ngx-components-asset-properties.mjs.map +1 -1
  29. package/fesm2022/{c8y-ngx-components-asset-property-grid.component-CEphJoqx.mjs → c8y-ngx-components-asset-property-grid.component-BJOPTjF1.mjs} +13 -13
  30. package/fesm2022/{c8y-ngx-components-asset-property-grid.component-CEphJoqx.mjs.map → c8y-ngx-components-asset-property-grid.component-BJOPTjF1.mjs.map} +1 -1
  31. package/fesm2022/c8y-ngx-components-assets-navigator.mjs +36 -32
  32. package/fesm2022/c8y-ngx-components-assets-navigator.mjs.map +1 -1
  33. package/fesm2022/c8y-ngx-components-auth-configuration.mjs +120 -120
  34. package/fesm2022/c8y-ngx-components-binary-file-download.mjs +7 -7
  35. package/fesm2022/c8y-ngx-components-bookmarks.mjs +13 -13
  36. package/fesm2022/c8y-ngx-components-branding-base-branding.mjs +4 -4
  37. package/fesm2022/c8y-ngx-components-branding-dark-theme.mjs +7 -7
  38. package/fesm2022/c8y-ngx-components-branding-extra-css-branding-editor.mjs +7 -7
  39. package/fesm2022/c8y-ngx-components-branding-plain-branding-editor-lazy.mjs +3 -3
  40. package/fesm2022/c8y-ngx-components-branding-plain-branding-editor.mjs +7 -7
  41. package/fesm2022/c8y-ngx-components-branding-shared-data.mjs +15 -15
  42. package/fesm2022/c8y-ngx-components-branding-shared-lazy-add-branding-modal.mjs +6 -6
  43. package/fesm2022/c8y-ngx-components-branding-shared-lazy.mjs +36 -36
  44. package/fesm2022/c8y-ngx-components-branding-shared.mjs +13 -13
  45. package/fesm2022/c8y-ngx-components-child-devices.mjs +13 -13
  46. package/fesm2022/c8y-ngx-components-cockpit-config.mjs +40 -40
  47. package/fesm2022/{c8y-ngx-components-computed-asset-properties-alarm-count-config.component-DX9Rgjgl.mjs → c8y-ngx-components-computed-asset-properties-alarm-count-config.component-tP8yUdy3.mjs} +4 -4
  48. package/fesm2022/{c8y-ngx-components-computed-asset-properties-alarm-count-config.component-DX9Rgjgl.mjs.map → c8y-ngx-components-computed-asset-properties-alarm-count-config.component-tP8yUdy3.mjs.map} +1 -1
  49. package/fesm2022/{c8y-ngx-components-computed-asset-properties-c8y-ngx-components-computed-asset-properties-CRpLJ5H7.mjs → c8y-ngx-components-computed-asset-properties-c8y-ngx-components-computed-asset-properties-wNQ45CJ1.mjs} +11 -11
  50. package/fesm2022/{c8y-ngx-components-computed-asset-properties-c8y-ngx-components-computed-asset-properties-CRpLJ5H7.mjs.map → c8y-ngx-components-computed-asset-properties-c8y-ngx-components-computed-asset-properties-wNQ45CJ1.mjs.map} +1 -1
  51. package/fesm2022/{c8y-ngx-components-computed-asset-properties-configuration-snapshot-config.component-2rDsrxcs.mjs → c8y-ngx-components-computed-asset-properties-configuration-snapshot-config.component-BrYcCHYL.mjs} +4 -4
  52. package/fesm2022/{c8y-ngx-components-computed-asset-properties-configuration-snapshot-config.component-2rDsrxcs.mjs.map → c8y-ngx-components-computed-asset-properties-configuration-snapshot-config.component-BrYcCHYL.mjs.map} +1 -1
  53. package/fesm2022/{c8y-ngx-components-computed-asset-properties-event-count-config.component-BJNoqWZf.mjs → c8y-ngx-components-computed-asset-properties-event-count-config.component-BBKuA2rZ.mjs} +4 -4
  54. package/fesm2022/{c8y-ngx-components-computed-asset-properties-event-count-config.component-BJNoqWZf.mjs.map → c8y-ngx-components-computed-asset-properties-event-count-config.component-BBKuA2rZ.mjs.map} +1 -1
  55. package/fesm2022/{c8y-ngx-components-computed-asset-properties-fieldbus-item-status-config.component-DYac6foX.mjs → c8y-ngx-components-computed-asset-properties-fieldbus-item-status-config.component-uEdtPWC0.mjs} +5 -5
  56. package/fesm2022/{c8y-ngx-components-computed-asset-properties-fieldbus-item-status-config.component-DYac6foX.mjs.map → c8y-ngx-components-computed-asset-properties-fieldbus-item-status-config.component-uEdtPWC0.mjs.map} +1 -1
  57. package/fesm2022/{c8y-ngx-components-computed-asset-properties-last-measurement-config.component-3yTe6lIr.mjs → c8y-ngx-components-computed-asset-properties-last-measurement-config.component-BGhex-OP.mjs} +5 -5
  58. package/fesm2022/{c8y-ngx-components-computed-asset-properties-last-measurement-config.component-3yTe6lIr.mjs.map → c8y-ngx-components-computed-asset-properties-last-measurement-config.component-BGhex-OP.mjs.map} +1 -1
  59. package/fesm2022/c8y-ngx-components-computed-asset-properties.mjs +1 -1
  60. package/fesm2022/c8y-ngx-components-connectivity.mjs +53 -53
  61. package/fesm2022/c8y-ngx-components-context-dashboard-asset-add.mjs +10 -10
  62. package/fesm2022/c8y-ngx-components-context-dashboard-asset-view.mjs +7 -7
  63. package/fesm2022/c8y-ngx-components-context-dashboard-cockpit-home-dashboard.mjs +11 -11
  64. package/fesm2022/{c8y-ngx-components-context-dashboard-dashboard-appearance-settings.component-C7yXSDYC.mjs → c8y-ngx-components-context-dashboard-dashboard-appearance-settings.component-BkwPfkeK.mjs} +4 -4
  65. package/fesm2022/{c8y-ngx-components-context-dashboard-dashboard-appearance-settings.component-C7yXSDYC.mjs.map → c8y-ngx-components-context-dashboard-dashboard-appearance-settings.component-BkwPfkeK.mjs.map} +1 -1
  66. package/fesm2022/{c8y-ngx-components-context-dashboard-dashboard-general-settings.component-w8N16Z3t.mjs → c8y-ngx-components-context-dashboard-dashboard-general-settings.component-4aO0U4qs.mjs} +10 -10
  67. package/fesm2022/{c8y-ngx-components-context-dashboard-dashboard-general-settings.component-w8N16Z3t.mjs.map → c8y-ngx-components-context-dashboard-dashboard-general-settings.component-4aO0U4qs.mjs.map} +1 -1
  68. package/fesm2022/{c8y-ngx-components-context-dashboard-dashboard-version-history.component--1OYYpR2.mjs → c8y-ngx-components-context-dashboard-dashboard-version-history.component-1xx4pGiq.mjs} +4 -4
  69. package/fesm2022/{c8y-ngx-components-context-dashboard-dashboard-version-history.component--1OYYpR2.mjs.map → c8y-ngx-components-context-dashboard-dashboard-version-history.component-1xx4pGiq.mjs.map} +1 -1
  70. package/fesm2022/c8y-ngx-components-context-dashboard-device-add.mjs +10 -10
  71. package/fesm2022/c8y-ngx-components-context-dashboard-device-view.mjs +7 -7
  72. package/fesm2022/c8y-ngx-components-context-dashboard-devicemanagement.mjs +3 -3
  73. package/fesm2022/c8y-ngx-components-context-dashboard-state.mjs +3 -3
  74. package/fesm2022/c8y-ngx-components-context-dashboard.mjs +108 -108
  75. package/fesm2022/{c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DVEnCRzW.mjs → c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DFytXNdc.mjs} +16 -16
  76. package/fesm2022/{c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DVEnCRzW.mjs.map → c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DFytXNdc.mjs.map} +1 -1
  77. package/fesm2022/c8y-ngx-components-dashboard-details-advanced-tab.mjs +12 -12
  78. package/fesm2022/c8y-ngx-components-dashboard-manager-devicemanagement.mjs +6 -6
  79. package/fesm2022/c8y-ngx-components-dashboard-manager.mjs +22 -22
  80. package/fesm2022/c8y-ngx-components-data-broker.mjs +7 -7
  81. package/fesm2022/c8y-ngx-components-data-grid-columns-asset-type.mjs +3 -3
  82. package/fesm2022/c8y-ngx-components-data-grid-columns.mjs +3 -3
  83. package/fesm2022/c8y-ngx-components-datapoint-explorer-view.mjs +24 -24
  84. package/fesm2022/c8y-ngx-components-datapoint-explorer.mjs +13 -13
  85. package/fesm2022/c8y-ngx-components-datapoint-library-details.mjs +3 -3
  86. package/fesm2022/c8y-ngx-components-datapoint-library-list.mjs +3 -3
  87. package/fesm2022/c8y-ngx-components-datapoint-library-services.mjs +3 -3
  88. package/fesm2022/c8y-ngx-components-datapoint-library.mjs +4 -4
  89. package/fesm2022/c8y-ngx-components-datapoint-selector.mjs +43 -43
  90. package/fesm2022/c8y-ngx-components-datapoints-export-selector.mjs +36 -36
  91. package/fesm2022/c8y-ngx-components-default-subscriptions.mjs +16 -16
  92. package/fesm2022/c8y-ngx-components-device-enrolment-modal.mjs +9 -9
  93. package/fesm2022/c8y-ngx-components-device-enrolment.mjs +6 -6
  94. package/fesm2022/c8y-ngx-components-device-grid.mjs +43 -43
  95. package/fesm2022/c8y-ngx-components-device-list.mjs +22 -22
  96. package/fesm2022/c8y-ngx-components-device-map.mjs +12 -12
  97. package/fesm2022/c8y-ngx-components-device-profile.mjs +34 -34
  98. package/fesm2022/c8y-ngx-components-device-protocol-object-mappings.mjs +3 -3
  99. package/fesm2022/c8y-ngx-components-device-protocols.mjs +16 -16
  100. package/fesm2022/c8y-ngx-components-device-provisioned-certificates.mjs +13 -13
  101. package/fesm2022/c8y-ngx-components-device-shell.mjs +31 -31
  102. package/fesm2022/c8y-ngx-components-diagnostics.mjs +13 -13
  103. package/fesm2022/c8y-ngx-components-echart.mjs +32 -32
  104. package/fesm2022/c8y-ngx-components-echart.mjs.map +1 -1
  105. package/fesm2022/c8y-ngx-components-ecosystem-application-plugins.mjs +43 -43
  106. package/fesm2022/c8y-ngx-components-ecosystem-archived-confirm.mjs +7 -7
  107. package/fesm2022/c8y-ngx-components-ecosystem-license-confirm.mjs +10 -10
  108. package/fesm2022/c8y-ngx-components-ecosystem-plugin-setup-stepper.mjs +7 -7
  109. package/fesm2022/c8y-ngx-components-ecosystem-shared.mjs +46 -46
  110. package/fesm2022/c8y-ngx-components-ecosystem.mjs +82 -82
  111. package/fesm2022/c8y-ngx-components-editor.mjs +6 -6
  112. package/fesm2022/c8y-ngx-components-events-events-timeline.mjs +3 -3
  113. package/fesm2022/c8y-ngx-components-events.mjs +33 -33
  114. package/fesm2022/c8y-ngx-components-exports-list.mjs +39 -14
  115. package/fesm2022/c8y-ngx-components-exports-list.mjs.map +1 -1
  116. package/fesm2022/c8y-ngx-components-feature-toggles-list.mjs +6 -6
  117. package/fesm2022/c8y-ngx-components-file-preview.mjs +7 -7
  118. package/fesm2022/c8y-ngx-components-files-repository.mjs +19 -19
  119. package/fesm2022/c8y-ngx-components-global-context.mjs +170 -130
  120. package/fesm2022/c8y-ngx-components-global-context.mjs.map +1 -1
  121. package/fesm2022/c8y-ngx-components-group-breadcrumbs.mjs +6 -6
  122. package/fesm2022/c8y-ngx-components-icon-selector.mjs +19 -19
  123. package/fesm2022/c8y-ngx-components-interval-picker.mjs +3 -3
  124. package/fesm2022/c8y-ngx-components-location.mjs +28 -28
  125. package/fesm2022/c8y-ngx-components-loriot-device-registration.mjs +16 -16
  126. package/fesm2022/c8y-ngx-components-map.mjs +39 -51
  127. package/fesm2022/c8y-ngx-components-map.mjs.map +1 -1
  128. package/fesm2022/c8y-ngx-components-messaging-management.mjs +55 -55
  129. package/fesm2022/c8y-ngx-components-operation-picker.mjs +9 -9
  130. package/fesm2022/c8y-ngx-components-operations-bulk-operation-from-single.mjs +7 -7
  131. package/fesm2022/c8y-ngx-components-operations-bulk-operation-list-item.mjs +19 -19
  132. package/fesm2022/c8y-ngx-components-operations-bulk-operation-scheduler.mjs +7 -7
  133. package/fesm2022/c8y-ngx-components-operations-bulk-operation-stepper.mjs +13 -13
  134. package/fesm2022/c8y-ngx-components-operations-bulk-operations-list.mjs +13 -13
  135. package/fesm2022/c8y-ngx-components-operations-bulk-operations-service.mjs +7 -7
  136. package/fesm2022/c8y-ngx-components-operations-bulk-operations-stepper-container.mjs +7 -7
  137. package/fesm2022/c8y-ngx-components-operations-bulk-single-operations-list.mjs +3 -3
  138. package/fesm2022/c8y-ngx-components-operations-create-bulk-operation-details.mjs +7 -7
  139. package/fesm2022/c8y-ngx-components-operations-device-selector.mjs +7 -7
  140. package/fesm2022/c8y-ngx-components-operations-grid-columns.mjs +12 -12
  141. package/fesm2022/c8y-ngx-components-operations-operation-details.mjs +13 -13
  142. package/fesm2022/c8y-ngx-components-operations-operation-summary.mjs +7 -7
  143. package/fesm2022/c8y-ngx-components-operations-operations-list-item-details.mjs +10 -10
  144. package/fesm2022/c8y-ngx-components-operations-operations-list.mjs +12 -12
  145. package/fesm2022/c8y-ngx-components-operations-operations-timeline.mjs +7 -7
  146. package/fesm2022/c8y-ngx-components-operations-shared.mjs +10 -10
  147. package/fesm2022/c8y-ngx-components-operations-status-filter.mjs +7 -7
  148. package/fesm2022/c8y-ngx-components-operations-stepper-bulk-type-configuration.mjs +7 -7
  149. package/fesm2022/c8y-ngx-components-operations-stepper-bulk-type-device-profile.mjs +13 -13
  150. package/fesm2022/c8y-ngx-components-operations-stepper-bulk-type-firmware.mjs +13 -13
  151. package/fesm2022/c8y-ngx-components-operations-stepper-bulk-type-software.mjs +13 -13
  152. package/fesm2022/c8y-ngx-components-operations-stepper-frames.mjs +13 -13
  153. package/fesm2022/c8y-ngx-components-operations.mjs +7 -7
  154. package/fesm2022/c8y-ngx-components-pending-mo-request.mjs +7 -7
  155. package/fesm2022/c8y-ngx-components-platform-configuration.mjs +10 -10
  156. package/fesm2022/c8y-ngx-components-protocol-lpwan.mjs +38 -38
  157. package/fesm2022/c8y-ngx-components-protocol-opcua.mjs +58 -58
  158. package/fesm2022/c8y-ngx-components-register-device.mjs +58 -58
  159. package/fesm2022/c8y-ngx-components-remote-access-configurations.mjs +9 -9
  160. package/fesm2022/c8y-ngx-components-remote-access-data.mjs +3 -3
  161. package/fesm2022/c8y-ngx-components-remote-access-passthrough.mjs +3 -3
  162. package/fesm2022/c8y-ngx-components-remote-access-shared.mjs +6 -6
  163. package/fesm2022/c8y-ngx-components-remote-access-ssh-remote-access-ssh-endpoint-modal.mjs +3 -3
  164. package/fesm2022/c8y-ngx-components-remote-access-ssh.mjs +3 -3
  165. package/fesm2022/c8y-ngx-components-remote-access-telnet.mjs +3 -3
  166. package/fesm2022/c8y-ngx-components-remote-access-terminal-viewer.mjs +3 -3
  167. package/fesm2022/c8y-ngx-components-remote-access-vnc-remote-access-vnc-endpoint-modal.mjs +3 -3
  168. package/fesm2022/c8y-ngx-components-remote-access-vnc-vnc-viewer.mjs +6 -6
  169. package/fesm2022/c8y-ngx-components-remote-access-vnc.mjs +3 -3
  170. package/fesm2022/c8y-ngx-components-replace-device-replace-device-wizard.mjs +6 -6
  171. package/fesm2022/c8y-ngx-components-replace-device.mjs +10 -10
  172. package/fesm2022/c8y-ngx-components-report-dashboard.mjs +16 -16
  173. package/fesm2022/c8y-ngx-components-reports.mjs +19 -19
  174. package/fesm2022/c8y-ngx-components-repository-configuration.mjs +48 -48
  175. package/fesm2022/c8y-ngx-components-repository-firmware.mjs +33 -33
  176. package/fesm2022/c8y-ngx-components-repository-shared.mjs +34 -34
  177. package/fesm2022/c8y-ngx-components-repository-software.mjs +42 -42
  178. package/fesm2022/c8y-ngx-components-repository.mjs +4 -4
  179. package/fesm2022/c8y-ngx-components-search.mjs +19 -19
  180. package/fesm2022/c8y-ngx-components-sensor-phone-sensor-phone-modal.mjs +6 -6
  181. package/fesm2022/c8y-ngx-components-sensor-phone.mjs +7 -7
  182. package/fesm2022/c8y-ngx-components-services-service-command-tab.mjs +3 -3
  183. package/fesm2022/c8y-ngx-components-services-shared.mjs +3 -3
  184. package/fesm2022/c8y-ngx-components-services.mjs +29 -29
  185. package/fesm2022/c8y-ngx-components-sigfox-device-registration.mjs +16 -16
  186. package/fesm2022/c8y-ngx-components-sms-gateway.mjs +7 -7
  187. package/fesm2022/c8y-ngx-components-static-assets-data.mjs +3 -3
  188. package/fesm2022/c8y-ngx-components-static-assets-modal.mjs +9 -9
  189. package/fesm2022/c8y-ngx-components-static-assets.mjs +6 -6
  190. package/fesm2022/c8y-ngx-components-sub-assets.mjs +64 -60
  191. package/fesm2022/c8y-ngx-components-sub-assets.mjs.map +1 -1
  192. package/fesm2022/c8y-ngx-components-tenants.mjs +40 -40
  193. package/fesm2022/c8y-ngx-components-time-context.mjs +6 -6
  194. package/fesm2022/c8y-ngx-components-tracking.mjs +12 -12
  195. package/fesm2022/c8y-ngx-components-translation-editor-data.mjs +3 -3
  196. package/fesm2022/c8y-ngx-components-translation-editor-lazy.mjs +12 -12
  197. package/fesm2022/c8y-ngx-components-translation-editor.mjs +6 -6
  198. package/fesm2022/c8y-ngx-components-trusted-certificates.mjs +33 -33
  199. package/fesm2022/c8y-ngx-components-upgrade-upgraded-services.mjs +4 -4
  200. package/fesm2022/c8y-ngx-components-upgrade.mjs +41 -41
  201. package/fesm2022/c8y-ngx-components-user-roles.mjs +10 -10
  202. package/fesm2022/c8y-ngx-components-widgets-definitions-asset-table.mjs +6 -6
  203. package/fesm2022/c8y-ngx-components-widgets-definitions-datapoints-graph.mjs +3 -3
  204. package/fesm2022/c8y-ngx-components-widgets-definitions-datapoints-table.mjs +3 -5
  205. package/fesm2022/c8y-ngx-components-widgets-definitions-datapoints-table.mjs.map +1 -1
  206. package/fesm2022/c8y-ngx-components-widgets-definitions-html-widget-ai-config.mjs +3 -3
  207. package/fesm2022/c8y-ngx-components-widgets-definitions-html-widget.mjs +6 -6
  208. package/fesm2022/c8y-ngx-components-widgets-implementations-alarms.mjs +27 -24
  209. package/fesm2022/c8y-ngx-components-widgets-implementations-alarms.mjs.map +1 -1
  210. package/fesm2022/c8y-ngx-components-widgets-implementations-asset-notes.mjs +3 -3
  211. package/fesm2022/c8y-ngx-components-widgets-implementations-asset-table.mjs +111 -40
  212. package/fesm2022/c8y-ngx-components-widgets-implementations-asset-table.mjs.map +1 -1
  213. package/fesm2022/c8y-ngx-components-widgets-implementations-cockpit-legacy-welcome.mjs +3 -3
  214. package/fesm2022/c8y-ngx-components-widgets-implementations-cockpit-welcome.mjs +3 -3
  215. package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-graph.mjs +13 -11
  216. package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-graph.mjs.map +1 -1
  217. package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-list.mjs +13 -13
  218. package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-list.mjs.map +1 -1
  219. package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-table.mjs +75 -60
  220. package/fesm2022/c8y-ngx-components-widgets-implementations-datapoints-table.mjs.map +1 -1
  221. package/fesm2022/c8y-ngx-components-widgets-implementations-device-control-message.mjs +3 -3
  222. package/fesm2022/c8y-ngx-components-widgets-implementations-device-management-welcome.mjs +10 -10
  223. package/fesm2022/c8y-ngx-components-widgets-implementations-events.mjs +6 -6
  224. package/fesm2022/c8y-ngx-components-widgets-implementations-help-and-service-widget.mjs +3 -3
  225. package/fesm2022/c8y-ngx-components-widgets-implementations-html-widget.mjs +24 -24
  226. package/fesm2022/c8y-ngx-components-widgets-implementations-image.mjs +9 -9
  227. package/fesm2022/c8y-ngx-components-widgets-implementations-info-gauge.mjs +18 -18
  228. package/fesm2022/c8y-ngx-components-widgets-implementations-kpi.mjs +6 -6
  229. package/fesm2022/c8y-ngx-components-widgets-implementations-linear-gauge.mjs +6 -6
  230. package/fesm2022/c8y-ngx-components-widgets-implementations-map.mjs +9 -9
  231. package/fesm2022/c8y-ngx-components-widgets-implementations-markdown.mjs +9 -9
  232. package/fesm2022/c8y-ngx-components-widgets-implementations-pie-chart.mjs +9 -9
  233. package/fesm2022/c8y-ngx-components-widgets-implementations-quick-links.mjs +18 -18
  234. package/fesm2022/c8y-ngx-components-widgets-implementations-three-d-rotation.mjs +9 -9
  235. package/fesm2022/c8y-ngx-components.mjs +1398 -1398
  236. package/global-context/index.d.ts +2 -0
  237. package/global-context/index.d.ts.map +1 -1
  238. package/index.d.ts +2 -0
  239. package/index.d.ts.map +1 -1
  240. package/locales/de.po +0 -6
  241. package/locales/es.po +0 -6
  242. package/locales/fr.po +0 -6
  243. package/locales/ja_JP.po +0 -6
  244. package/locales/ko.po +0 -6
  245. package/locales/locales.pot +3 -6
  246. package/locales/nl.po +0 -6
  247. package/locales/pl.po +0 -6
  248. package/locales/pt_BR.po +0 -6
  249. package/locales/zh_CN.po +0 -6
  250. package/locales/zh_TW.po +0 -6
  251. package/map/index.d.ts +12 -1
  252. package/map/index.d.ts.map +1 -1
  253. package/package.json +1 -1
  254. package/sub-assets/index.d.ts +4 -0
  255. package/sub-assets/index.d.ts.map +1 -1
  256. package/widgets/definitions/datapoints-table/index.d.ts +1 -2
  257. package/widgets/definitions/datapoints-table/index.d.ts.map +1 -1
  258. package/widgets/implementations/alarms/index.d.ts +2 -0
  259. package/widgets/implementations/alarms/index.d.ts.map +1 -1
  260. package/widgets/implementations/datapoints-graph/index.d.ts +1 -0
  261. package/widgets/implementations/datapoints-graph/index.d.ts.map +1 -1
  262. package/widgets/implementations/datapoints-table/index.d.ts +16 -8
  263. package/widgets/implementations/datapoints-table/index.d.ts.map +1 -1
  264. package/widgets/implementations/html-widget/index.d.ts +2 -0
  265. package/widgets/implementations/html-widget/index.d.ts.map +1 -1
@@ -191,10 +191,10 @@ class JsonValidationService {
191
191
  };
192
192
  return [...schemasPart, defaultPart];
193
193
  }
194
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: JsonValidationService, deps: [{ token: i1.DynamicComponentService }], target: i0.ɵɵFactoryTarget.Injectable }); }
195
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: JsonValidationService }); }
194
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: JsonValidationService, deps: [{ token: i1.DynamicComponentService }], target: i0.ɵɵFactoryTarget.Injectable }); }
195
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: JsonValidationService }); }
196
196
  }
197
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: JsonValidationService, decorators: [{
197
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: JsonValidationService, decorators: [{
198
198
  type: Injectable
199
199
  }], ctorParameters: () => [{ type: i1.DynamicComponentService }] });
200
200
 
@@ -256,10 +256,10 @@ class AssignWidgetAssetModalComponent {
256
256
  selectionChange($event, widgetAsset) {
257
257
  widgetAsset.selectedAsset = $event.change.item;
258
258
  }
259
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: AssignWidgetAssetModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
260
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.18", type: AssignWidgetAssetModalComponent, isStandalone: true, selector: "c8y-assign-widget-asset-modal", inputs: { assetsToAlign: "assetsToAlign", contextAsset: "contextAsset", notSupportedWidgets: "notSupportedWidgets" }, ngImport: i0, template: "<div class=\"viewport-modal has-asset-selector\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'th-large'\"></i>\n <div\n class=\"modal-title\"\n id=\"modal-title\"\n translate\n >\n Select and confirm widget assets mapping\n </div>\n </div>\n <div\n class=\"inner-scroll\"\n id=\"modal-body\"\n >\n <div class=\"p-16\">\n <p class=\"text-center text-balance\">\n {{ modalTitle | translate }}\n </p>\n </div>\n @if (notSupportedWidgets.length) {\n <div class=\"d-flex fit-w j-c-center p-16 p-t-0\">\n <div class=\"alert alert-warning\">\n {{ 'Widgets not supported for asset mapping: {{ notSupportedWidgets }}' | translate: {\n notSupportedWidgets: notSupportedWidgets.join(', ') } }}\n </div>\n </div>\n }\n @if (!assetsToAlign.length) {\n <div class=\"p-16 d-flex j-c-center\">\n <c8y-ui-empty-state\n class=\"\"\n [icon]=\"'empty-box'\"\n [title]=\"'No assets to assign' | translate\"\n ></c8y-ui-empty-state>\n </div>\n }\n @if (assetsToAlign.length) {\n <div>\n <c8y-list-group class=\"separator-top no-border-last\">\n <c8y-li class=\"sticky-top bg-level-1 hidden-sm hidden-xs\">\n <c8y-li-icon></c8y-li-icon>\n <div class=\"d-flex\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium\"\n translate\n >\n Widget\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-r-0\">\n <p\n class=\"text-medium\"\n translate\n >\n Original source\n </p>\n </div>\n <div class=\"col-md-1 text-center\">\n <button\n class=\"btn btn-default btn-sm\"\n [attr.aria-label]=\"'Accept all suggested' | translate\"\n [tooltip]=\"'Accept all suggested' | translate\"\n placement=\"right\"\n (click)=\"acceptAllSuggested()\"\n [disabled]=\"!hasSuggestedAssets\"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div class=\"col-md-7 p-l-8\">\n <p\n class=\"text-medium\"\n translate\n >\n Selected source\n </p>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n @for (widgetAsset of updatedWidgetAssets; track widgetAsset; let i = $index) {\n <c8y-li class=\"c8y-list__item--overflow-visible\">\n <c8y-li-icon\n class=\"p-r-0 p-t-16\"\n icon=\"th-large\"\n ></c8y-li-icon>\n <div class=\"d-flex-md\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium boxed-label p-l-0\"\n title=\"{{ widgetAsset.title }}\"\n >\n {{ widgetAsset.title }}\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-l-md-0 p-r-0\">\n <!-- origin device -->\n <p class=\"visible-sm visible-xs text-label-small\">\n {{ 'Original source' | translate }}\n </p>\n <div class=\"d-flex gap-4 boxed-label\">\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.name }}\"\n >\n {{ widgetAsset.deviceRef.value.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.deviceRef.value.id }\n }}\n </small>\n </span>\n </div>\n </div>\n <div\n class=\"col-md-1 col-xs-1 p-l-xs-0 p-l-sm-0 p-r-sm-0 p-r-xs-0 text-center p-t-16\"\n >\n <i\n class=\"icon-20\"\n [c8yIcon]=\"\n widgetAsset.selectedAsset !== undefined ? 'ok' : 'inactive-state'\n \"\n [title]=\"\n widgetAsset.selectedAsset !== undefined\n ? (assetSelectedLabel | translate)\n : (assetNotSelectedLabel | translate)\n \"\n [ngClass]=\"{\n 'text-success': widgetAsset.selectedAsset !== undefined,\n 'text-muted': widgetAsset.selectedAsset === undefined\n }\"\n ></i>\n @if (\n widgetAsset.selectedAsset === undefined && userClickedAcceptAllSuggested\n ) {\n <span\n class=\"c8y-icon-badge\"\n [tooltip]=\"\n 'No suggestion available- widget will not be imported' | translate\n \"\n placement=\"right\"\n >\n <i\n class=\"status major stroked-icon\"\n c8yIcon=\"warning\"\n ></i>\n </span>\n }\n </div>\n <div class=\"col-md-4 col-xs-11 p-l-md-0\">\n <!-- Suggested/Selected source -->\n <p class=\"visible-sm visible-xs text-label-small m-t-16 m-b-8\">\n {{ 'Selected source' | translate }}\n </p>\n @if (\n widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div\n class=\"d-flex gap-4 text-muted boxed-label\"\n [attr.data-label]=\"'Suggested' | translate\"\n >\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value.suggestedDevice }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\"\n >\n {{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo\n | translate\n : { assetId: widgetAsset.deviceRef.value.suggestedDevice?.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (widgetAsset.selectedAsset) {\n <div class=\"d-flex gap-4 boxed-label\">\n <!-- selectedAsset icon -->\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.selectedAsset }\n \"\n ></ng-container>\n <!-- selectedAsset Name and ID -->\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.selectedAsset?.name }}\"\n >\n {{ widgetAsset.selectedAsset?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.selectedAsset.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (\n !widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div class=\"text-muted boxed-label\">\n <em>{{ 'No suggestion available' | translate }}</em>\n </div>\n }\n </div>\n <div class=\"col-md-3 p-0 flex-grow\">\n <div class=\"d-flex a-i-center j-c-end-md gap-8 boxed-label p-l-md-0 p-r-0\">\n <div class=\"input-group max-width-fit\">\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n [tooltip]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset ===\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n [disabled]=\"!widgetAsset.deviceRef.value.suggestedDevice\"\n (click)=\"\n widgetAsset.selectedAsset =\n widgetAsset.deviceRef.value.suggestedDevice\n \"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div\n class=\"dropdown input-group-btn\"\n container=\"body\"\n dropdown\n [insideClick]=\"true\"\n #dropdown=\"bs-dropdown\"\n >\n <button\n class=\"btn btn-default dropdown-toggle c8y-dropdown\"\n [attr.aria-label]=\"'Select asset' | translate\"\n tooltip=\"{{ 'Select asset' | translate }}\"\n placement=\"top\"\n container=\"body\"\n type=\"button\"\n dropdownToggle\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset !==\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n >\n <i [c8yIcon]=\"'card-exchange'\"></i>\n </button>\n <div\n class=\"dropdown-menu dropdown-menu-right--md\"\n style=\"width: 300px\"\n *dropdownMenu\n >\n @if (dropdown.isOpen) {\n <c8y-asset-selector-miller\n (onSelected)=\"\n selectionChange($event, widgetAsset); dropdown.hide()\n \"\n [asset]=\"contextAsset\"\n [config]=\"{\n groupsSelectable: true,\n showChildDevices: true,\n showFilter: true,\n showSelected: false,\n columnHeaders: true,\n singleColumn: true,\n preventInitialSelect: true\n }\"\n ></c8y-asset-selector-miller>\n }\n </div>\n </div>\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"'Configure later' | translate\"\n tooltip=\"{{ 'Configure later' | translate }}\"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{ active: widgetAsset.selectedAsset === null }\"\n (click)=\"widgetAsset.selectedAsset = null\"\n >\n <i [c8yIcon]=\"'link-off'\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n }\n </c8y-list-group>\n </div>\n }\n </div>\n <div class=\"modal-footer\">\n <button\n class=\"btn btn-default\"\n [title]=\"'Cancel' | translate\"\n type=\"button\"\n (click)=\"cancel()\"\n >\n {{ 'Cancel' | translate }}\n </button>\n <button\n class=\"btn btn-primary\"\n [title]=\"'Apply' | translate\"\n type=\"button\"\n (click)=\"apply()\"\n >\n {{ 'Apply' | translate }}\n </button>\n </div>\n</div>\n\n<ng-template\n #assetIcon\n let-device\n>\n @if (device.c8y_IsDevice) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'data-transfer'\"\n ></i>\n }\n @if (device.c8y_IsDeviceGroup && !device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'c8y-group'\"\n ></i>\n }\n @if (device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"device.icon?.name || 'c8y-group'\"\n ></i>\n }\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CoreModule }, { kind: "component", type: i1.EmptyStateComponent, selector: "c8y-ui-empty-state", inputs: ["icon", "title", "subtitle", "horizontal"] }, { kind: "directive", type: i1.IconDirective, selector: "[c8yIcon]", inputs: ["c8yIcon"] }, { kind: "directive", type: i1.C8yTranslateDirective, selector: "[translate],[ngx-translate]" }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i1.ListGroupComponent, selector: "c8y-list-group" }, { kind: "component", type: i1.ListItemComponent, selector: "c8y-list-item, c8y-li", inputs: ["active", "highlighted", "emptyActions", "dense", "collapsed", "selectable"], outputs: ["collapsedChange"] }, { kind: "component", type: i1.ListItemIconComponent, selector: "c8y-list-item-icon, c8y-li-icon", inputs: ["icon", "status"] }, { kind: "ngmodule", type: AssetSelectorModule }, { kind: "component", type: i3.MillerViewComponent, selector: "c8y-asset-selector-miller", inputs: ["config", "asset", "selectedDevice", "rootNode", "container"], outputs: ["onSelected", "onClearSelected"] }, { kind: "ngmodule", type: BsDropdownModule }, { kind: "directive", type: i4.BsDropdownMenuDirective, selector: "[bsDropdownMenu],[dropdownMenu]", exportAs: ["bs-dropdown-menu"] }, { kind: "directive", type: i4.BsDropdownToggleDirective, selector: "[bsDropdownToggle],[dropdownToggle]", exportAs: ["bs-dropdown-toggle"] }, { kind: "directive", type: i4.BsDropdownDirective, selector: "[bsDropdown], [dropdown]", inputs: ["placement", "triggers", "container", "dropup", "autoClose", "isAnimated", "insideClick", "isDisabled", "isOpen"], outputs: ["isOpenChange", "onShown", "onHidden"], exportAs: ["bs-dropdown"] }, { kind: "ngmodule", type: TooltipModule }, { kind: "directive", type: i5.TooltipDirective, selector: "[tooltip], [tooltipHtml]", inputs: ["adaptivePosition", "tooltip", "placement", "triggers", "container", "containerClass", "boundariesElement", "isOpen", "isDisabled", "delay", "tooltipHtml", "tooltipPlacement", "tooltipIsOpen", "tooltipEnable", "tooltipAppendToBody", "tooltipAnimation", "tooltipClass", "tooltipContext", "tooltipPopupDelay", "tooltipFadeDuration", "tooltipTrigger"], outputs: ["tooltipChange", "onShown", "onHidden", "tooltipStateChanged"], exportAs: ["bs-tooltip"] }, { kind: "pipe", type: i1.C8yTranslatePipe, name: "translate" }] }); }
259
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: AssignWidgetAssetModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
260
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.19", type: AssignWidgetAssetModalComponent, isStandalone: true, selector: "c8y-assign-widget-asset-modal", inputs: { assetsToAlign: "assetsToAlign", contextAsset: "contextAsset", notSupportedWidgets: "notSupportedWidgets" }, ngImport: i0, template: "<div class=\"viewport-modal has-asset-selector\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'th-large'\"></i>\n <div\n class=\"modal-title\"\n id=\"modal-title\"\n translate\n >\n Select and confirm widget assets mapping\n </div>\n </div>\n <div\n class=\"inner-scroll\"\n id=\"modal-body\"\n >\n <div class=\"p-16\">\n <p class=\"text-center text-balance\">\n {{ modalTitle | translate }}\n </p>\n </div>\n @if (notSupportedWidgets.length) {\n <div class=\"d-flex fit-w j-c-center p-16 p-t-0\">\n <div class=\"alert alert-warning\">\n {{ 'Widgets not supported for asset mapping: {{ notSupportedWidgets }}' | translate: {\n notSupportedWidgets: notSupportedWidgets.join(', ') } }}\n </div>\n </div>\n }\n @if (!assetsToAlign.length) {\n <div class=\"p-16 d-flex j-c-center\">\n <c8y-ui-empty-state\n class=\"\"\n [icon]=\"'empty-box'\"\n [title]=\"'No assets to assign' | translate\"\n ></c8y-ui-empty-state>\n </div>\n }\n @if (assetsToAlign.length) {\n <div>\n <c8y-list-group class=\"separator-top no-border-last\">\n <c8y-li class=\"sticky-top bg-level-1 hidden-sm hidden-xs\">\n <c8y-li-icon></c8y-li-icon>\n <div class=\"d-flex\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium\"\n translate\n >\n Widget\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-r-0\">\n <p\n class=\"text-medium\"\n translate\n >\n Original source\n </p>\n </div>\n <div class=\"col-md-1 text-center\">\n <button\n class=\"btn btn-default btn-sm\"\n [attr.aria-label]=\"'Accept all suggested' | translate\"\n [tooltip]=\"'Accept all suggested' | translate\"\n placement=\"right\"\n (click)=\"acceptAllSuggested()\"\n [disabled]=\"!hasSuggestedAssets\"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div class=\"col-md-7 p-l-8\">\n <p\n class=\"text-medium\"\n translate\n >\n Selected source\n </p>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n @for (widgetAsset of updatedWidgetAssets; track widgetAsset; let i = $index) {\n <c8y-li class=\"c8y-list__item--overflow-visible\">\n <c8y-li-icon\n class=\"p-r-0 p-t-16\"\n icon=\"th-large\"\n ></c8y-li-icon>\n <div class=\"d-flex-md\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium boxed-label p-l-0\"\n title=\"{{ widgetAsset.title }}\"\n >\n {{ widgetAsset.title }}\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-l-md-0 p-r-0\">\n <!-- origin device -->\n <p class=\"visible-sm visible-xs text-label-small\">\n {{ 'Original source' | translate }}\n </p>\n <div class=\"d-flex gap-4 boxed-label\">\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.name }}\"\n >\n {{ widgetAsset.deviceRef.value.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.deviceRef.value.id }\n }}\n </small>\n </span>\n </div>\n </div>\n <div\n class=\"col-md-1 col-xs-1 p-l-xs-0 p-l-sm-0 p-r-sm-0 p-r-xs-0 text-center p-t-16\"\n >\n <i\n class=\"icon-20\"\n [c8yIcon]=\"\n widgetAsset.selectedAsset !== undefined ? 'ok' : 'inactive-state'\n \"\n [title]=\"\n widgetAsset.selectedAsset !== undefined\n ? (assetSelectedLabel | translate)\n : (assetNotSelectedLabel | translate)\n \"\n [ngClass]=\"{\n 'text-success': widgetAsset.selectedAsset !== undefined,\n 'text-muted': widgetAsset.selectedAsset === undefined\n }\"\n ></i>\n @if (\n widgetAsset.selectedAsset === undefined && userClickedAcceptAllSuggested\n ) {\n <span\n class=\"c8y-icon-badge\"\n [tooltip]=\"\n 'No suggestion available- widget will not be imported' | translate\n \"\n placement=\"right\"\n >\n <i\n class=\"status major stroked-icon\"\n c8yIcon=\"warning\"\n ></i>\n </span>\n }\n </div>\n <div class=\"col-md-4 col-xs-11 p-l-md-0\">\n <!-- Suggested/Selected source -->\n <p class=\"visible-sm visible-xs text-label-small m-t-16 m-b-8\">\n {{ 'Selected source' | translate }}\n </p>\n @if (\n widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div\n class=\"d-flex gap-4 text-muted boxed-label\"\n [attr.data-label]=\"'Suggested' | translate\"\n >\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value.suggestedDevice }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\"\n >\n {{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo\n | translate\n : { assetId: widgetAsset.deviceRef.value.suggestedDevice?.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (widgetAsset.selectedAsset) {\n <div class=\"d-flex gap-4 boxed-label\">\n <!-- selectedAsset icon -->\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.selectedAsset }\n \"\n ></ng-container>\n <!-- selectedAsset Name and ID -->\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.selectedAsset?.name }}\"\n >\n {{ widgetAsset.selectedAsset?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.selectedAsset.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (\n !widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div class=\"text-muted boxed-label\">\n <em>{{ 'No suggestion available' | translate }}</em>\n </div>\n }\n </div>\n <div class=\"col-md-3 p-0 flex-grow\">\n <div class=\"d-flex a-i-center j-c-end-md gap-8 boxed-label p-l-md-0 p-r-0\">\n <div class=\"input-group max-width-fit\">\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n [tooltip]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset ===\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n [disabled]=\"!widgetAsset.deviceRef.value.suggestedDevice\"\n (click)=\"\n widgetAsset.selectedAsset =\n widgetAsset.deviceRef.value.suggestedDevice\n \"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div\n class=\"dropdown input-group-btn\"\n container=\"body\"\n dropdown\n [insideClick]=\"true\"\n #dropdown=\"bs-dropdown\"\n >\n <button\n class=\"btn btn-default dropdown-toggle c8y-dropdown\"\n [attr.aria-label]=\"'Select asset' | translate\"\n tooltip=\"{{ 'Select asset' | translate }}\"\n placement=\"top\"\n container=\"body\"\n type=\"button\"\n dropdownToggle\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset !==\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n >\n <i [c8yIcon]=\"'card-exchange'\"></i>\n </button>\n <div\n class=\"dropdown-menu dropdown-menu-right--md\"\n style=\"width: 300px\"\n *dropdownMenu\n >\n @if (dropdown.isOpen) {\n <c8y-asset-selector-miller\n (onSelected)=\"\n selectionChange($event, widgetAsset); dropdown.hide()\n \"\n [asset]=\"contextAsset\"\n [config]=\"{\n groupsSelectable: true,\n showChildDevices: true,\n showFilter: true,\n showSelected: false,\n columnHeaders: true,\n singleColumn: true,\n preventInitialSelect: true\n }\"\n ></c8y-asset-selector-miller>\n }\n </div>\n </div>\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"'Configure later' | translate\"\n tooltip=\"{{ 'Configure later' | translate }}\"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{ active: widgetAsset.selectedAsset === null }\"\n (click)=\"widgetAsset.selectedAsset = null\"\n >\n <i [c8yIcon]=\"'link-off'\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n }\n </c8y-list-group>\n </div>\n }\n </div>\n <div class=\"modal-footer\">\n <button\n class=\"btn btn-default\"\n [title]=\"'Cancel' | translate\"\n type=\"button\"\n (click)=\"cancel()\"\n >\n {{ 'Cancel' | translate }}\n </button>\n <button\n class=\"btn btn-primary\"\n [title]=\"'Apply' | translate\"\n type=\"button\"\n (click)=\"apply()\"\n >\n {{ 'Apply' | translate }}\n </button>\n </div>\n</div>\n\n<ng-template\n #assetIcon\n let-device\n>\n @if (device.c8y_IsDevice) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'data-transfer'\"\n ></i>\n }\n @if (device.c8y_IsDeviceGroup && !device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'c8y-group'\"\n ></i>\n }\n @if (device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"device.icon?.name || 'c8y-group'\"\n ></i>\n }\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CoreModule }, { kind: "component", type: i1.EmptyStateComponent, selector: "c8y-ui-empty-state", inputs: ["icon", "title", "subtitle", "horizontal"] }, { kind: "directive", type: i1.IconDirective, selector: "[c8yIcon]", inputs: ["c8yIcon"] }, { kind: "directive", type: i1.C8yTranslateDirective, selector: "[translate],[ngx-translate]" }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: i1.ListGroupComponent, selector: "c8y-list-group" }, { kind: "component", type: i1.ListItemComponent, selector: "c8y-list-item, c8y-li", inputs: ["active", "highlighted", "emptyActions", "dense", "collapsed", "selectable"], outputs: ["collapsedChange"] }, { kind: "component", type: i1.ListItemIconComponent, selector: "c8y-list-item-icon, c8y-li-icon", inputs: ["icon", "status"] }, { kind: "ngmodule", type: AssetSelectorModule }, { kind: "component", type: i3.MillerViewComponent, selector: "c8y-asset-selector-miller", inputs: ["config", "asset", "selectedDevice", "rootNode", "container"], outputs: ["onSelected", "onClearSelected"] }, { kind: "ngmodule", type: BsDropdownModule }, { kind: "directive", type: i4.BsDropdownMenuDirective, selector: "[bsDropdownMenu],[dropdownMenu]", exportAs: ["bs-dropdown-menu"] }, { kind: "directive", type: i4.BsDropdownToggleDirective, selector: "[bsDropdownToggle],[dropdownToggle]", exportAs: ["bs-dropdown-toggle"] }, { kind: "directive", type: i4.BsDropdownDirective, selector: "[bsDropdown], [dropdown]", inputs: ["placement", "triggers", "container", "dropup", "autoClose", "isAnimated", "insideClick", "isDisabled", "isOpen"], outputs: ["isOpenChange", "onShown", "onHidden"], exportAs: ["bs-dropdown"] }, { kind: "ngmodule", type: TooltipModule }, { kind: "directive", type: i5.TooltipDirective, selector: "[tooltip], [tooltipHtml]", inputs: ["adaptivePosition", "tooltip", "placement", "triggers", "container", "containerClass", "boundariesElement", "isOpen", "isDisabled", "delay", "tooltipHtml", "tooltipPlacement", "tooltipIsOpen", "tooltipEnable", "tooltipAppendToBody", "tooltipAnimation", "tooltipClass", "tooltipContext", "tooltipPopupDelay", "tooltipFadeDuration", "tooltipTrigger"], outputs: ["tooltipChange", "onShown", "onHidden", "tooltipStateChanged"], exportAs: ["bs-tooltip"] }, { kind: "pipe", type: i1.C8yTranslatePipe, name: "translate" }] }); }
261
261
  }
262
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: AssignWidgetAssetModalComponent, decorators: [{
262
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: AssignWidgetAssetModalComponent, decorators: [{
263
263
  type: Component,
264
264
  args: [{ selector: 'c8y-assign-widget-asset-modal', standalone: true, imports: [CoreModule, AssetSelectorModule, BsDropdownModule, TooltipModule], template: "<div class=\"viewport-modal has-asset-selector\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'th-large'\"></i>\n <div\n class=\"modal-title\"\n id=\"modal-title\"\n translate\n >\n Select and confirm widget assets mapping\n </div>\n </div>\n <div\n class=\"inner-scroll\"\n id=\"modal-body\"\n >\n <div class=\"p-16\">\n <p class=\"text-center text-balance\">\n {{ modalTitle | translate }}\n </p>\n </div>\n @if (notSupportedWidgets.length) {\n <div class=\"d-flex fit-w j-c-center p-16 p-t-0\">\n <div class=\"alert alert-warning\">\n {{ 'Widgets not supported for asset mapping: {{ notSupportedWidgets }}' | translate: {\n notSupportedWidgets: notSupportedWidgets.join(', ') } }}\n </div>\n </div>\n }\n @if (!assetsToAlign.length) {\n <div class=\"p-16 d-flex j-c-center\">\n <c8y-ui-empty-state\n class=\"\"\n [icon]=\"'empty-box'\"\n [title]=\"'No assets to assign' | translate\"\n ></c8y-ui-empty-state>\n </div>\n }\n @if (assetsToAlign.length) {\n <div>\n <c8y-list-group class=\"separator-top no-border-last\">\n <c8y-li class=\"sticky-top bg-level-1 hidden-sm hidden-xs\">\n <c8y-li-icon></c8y-li-icon>\n <div class=\"d-flex\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium\"\n translate\n >\n Widget\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-r-0\">\n <p\n class=\"text-medium\"\n translate\n >\n Original source\n </p>\n </div>\n <div class=\"col-md-1 text-center\">\n <button\n class=\"btn btn-default btn-sm\"\n [attr.aria-label]=\"'Accept all suggested' | translate\"\n [tooltip]=\"'Accept all suggested' | translate\"\n placement=\"right\"\n (click)=\"acceptAllSuggested()\"\n [disabled]=\"!hasSuggestedAssets\"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div class=\"col-md-7 p-l-8\">\n <p\n class=\"text-medium\"\n translate\n >\n Selected source\n </p>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n @for (widgetAsset of updatedWidgetAssets; track widgetAsset; let i = $index) {\n <c8y-li class=\"c8y-list__item--overflow-visible\">\n <c8y-li-icon\n class=\"p-r-0 p-t-16\"\n icon=\"th-large\"\n ></c8y-li-icon>\n <div class=\"d-flex-md\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium boxed-label p-l-0\"\n title=\"{{ widgetAsset.title }}\"\n >\n {{ widgetAsset.title }}\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-l-md-0 p-r-0\">\n <!-- origin device -->\n <p class=\"visible-sm visible-xs text-label-small\">\n {{ 'Original source' | translate }}\n </p>\n <div class=\"d-flex gap-4 boxed-label\">\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.name }}\"\n >\n {{ widgetAsset.deviceRef.value.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.deviceRef.value.id }\n }}\n </small>\n </span>\n </div>\n </div>\n <div\n class=\"col-md-1 col-xs-1 p-l-xs-0 p-l-sm-0 p-r-sm-0 p-r-xs-0 text-center p-t-16\"\n >\n <i\n class=\"icon-20\"\n [c8yIcon]=\"\n widgetAsset.selectedAsset !== undefined ? 'ok' : 'inactive-state'\n \"\n [title]=\"\n widgetAsset.selectedAsset !== undefined\n ? (assetSelectedLabel | translate)\n : (assetNotSelectedLabel | translate)\n \"\n [ngClass]=\"{\n 'text-success': widgetAsset.selectedAsset !== undefined,\n 'text-muted': widgetAsset.selectedAsset === undefined\n }\"\n ></i>\n @if (\n widgetAsset.selectedAsset === undefined && userClickedAcceptAllSuggested\n ) {\n <span\n class=\"c8y-icon-badge\"\n [tooltip]=\"\n 'No suggestion available- widget will not be imported' | translate\n \"\n placement=\"right\"\n >\n <i\n class=\"status major stroked-icon\"\n c8yIcon=\"warning\"\n ></i>\n </span>\n }\n </div>\n <div class=\"col-md-4 col-xs-11 p-l-md-0\">\n <!-- Suggested/Selected source -->\n <p class=\"visible-sm visible-xs text-label-small m-t-16 m-b-8\">\n {{ 'Selected source' | translate }}\n </p>\n @if (\n widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div\n class=\"d-flex gap-4 text-muted boxed-label\"\n [attr.data-label]=\"'Suggested' | translate\"\n >\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value.suggestedDevice }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\"\n >\n {{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo\n | translate\n : { assetId: widgetAsset.deviceRef.value.suggestedDevice?.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (widgetAsset.selectedAsset) {\n <div class=\"d-flex gap-4 boxed-label\">\n <!-- selectedAsset icon -->\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.selectedAsset }\n \"\n ></ng-container>\n <!-- selectedAsset Name and ID -->\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.selectedAsset?.name }}\"\n >\n {{ widgetAsset.selectedAsset?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.selectedAsset.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (\n !widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div class=\"text-muted boxed-label\">\n <em>{{ 'No suggestion available' | translate }}</em>\n </div>\n }\n </div>\n <div class=\"col-md-3 p-0 flex-grow\">\n <div class=\"d-flex a-i-center j-c-end-md gap-8 boxed-label p-l-md-0 p-r-0\">\n <div class=\"input-group max-width-fit\">\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n [tooltip]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset ===\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n [disabled]=\"!widgetAsset.deviceRef.value.suggestedDevice\"\n (click)=\"\n widgetAsset.selectedAsset =\n widgetAsset.deviceRef.value.suggestedDevice\n \"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div\n class=\"dropdown input-group-btn\"\n container=\"body\"\n dropdown\n [insideClick]=\"true\"\n #dropdown=\"bs-dropdown\"\n >\n <button\n class=\"btn btn-default dropdown-toggle c8y-dropdown\"\n [attr.aria-label]=\"'Select asset' | translate\"\n tooltip=\"{{ 'Select asset' | translate }}\"\n placement=\"top\"\n container=\"body\"\n type=\"button\"\n dropdownToggle\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset !==\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n >\n <i [c8yIcon]=\"'card-exchange'\"></i>\n </button>\n <div\n class=\"dropdown-menu dropdown-menu-right--md\"\n style=\"width: 300px\"\n *dropdownMenu\n >\n @if (dropdown.isOpen) {\n <c8y-asset-selector-miller\n (onSelected)=\"\n selectionChange($event, widgetAsset); dropdown.hide()\n \"\n [asset]=\"contextAsset\"\n [config]=\"{\n groupsSelectable: true,\n showChildDevices: true,\n showFilter: true,\n showSelected: false,\n columnHeaders: true,\n singleColumn: true,\n preventInitialSelect: true\n }\"\n ></c8y-asset-selector-miller>\n }\n </div>\n </div>\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"'Configure later' | translate\"\n tooltip=\"{{ 'Configure later' | translate }}\"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{ active: widgetAsset.selectedAsset === null }\"\n (click)=\"widgetAsset.selectedAsset = null\"\n >\n <i [c8yIcon]=\"'link-off'\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n }\n </c8y-list-group>\n </div>\n }\n </div>\n <div class=\"modal-footer\">\n <button\n class=\"btn btn-default\"\n [title]=\"'Cancel' | translate\"\n type=\"button\"\n (click)=\"cancel()\"\n >\n {{ 'Cancel' | translate }}\n </button>\n <button\n class=\"btn btn-primary\"\n [title]=\"'Apply' | translate\"\n type=\"button\"\n (click)=\"apply()\"\n >\n {{ 'Apply' | translate }}\n </button>\n </div>\n</div>\n\n<ng-template\n #assetIcon\n let-device\n>\n @if (device.c8y_IsDevice) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'data-transfer'\"\n ></i>\n }\n @if (device.c8y_IsDeviceGroup && !device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'c8y-group'\"\n ></i>\n }\n @if (device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"device.icon?.name || 'c8y-group'\"\n ></i>\n }\n</ng-template>\n" }]
265
265
  }], propDecorators: { assetsToAlign: [{
@@ -432,10 +432,10 @@ class ImportExportWidgetsService {
432
432
  });
433
433
  return result;
434
434
  }
435
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: ImportExportWidgetsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
436
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: ImportExportWidgetsService }); }
435
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: ImportExportWidgetsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
436
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: ImportExportWidgetsService }); }
437
437
  }
438
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: ImportExportWidgetsService, decorators: [{
438
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: ImportExportWidgetsService, decorators: [{
439
439
  type: Injectable
440
440
  }] });
441
441
 
@@ -554,10 +554,10 @@ class DashboardJsonEditorComponent {
554
554
  }
555
555
  return null;
556
556
  }
557
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: DashboardJsonEditorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
558
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.18", type: DashboardJsonEditorComponent, isStandalone: true, selector: "c8y-dashboard-json-editor", providers: [JsonValidationService, ImportExportWidgetsService], viewQueries: [{ propertyName: "editorComponent", first: true, predicate: EditorComponent, descendants: true }], ngImport: i0, template: "<div class=\"card-block\">\n<div\n class=\"d-flex d-col\"\n [ngStyle]=\"{ height: '410px' }\"\n>\n <ng-container *ngIf=\"!isExporting && !isImporting; else loading\">\n <div class=\"d-flex gap-16 flex-grow min-height-0\">\n <div class=\"d-col col-md-8 col-xs-6\">\n <label class=\"d-flex a-i-center\">{{ 'Dashboard configuration' | translate }} \n <button \n type=\"button\"\n [attr.aria-label]=\"'Help' | translate\"\n class=\"btn-help \" \n placement=\"right\"\n triggers=\"focus\"\n containerClass=\"text-pre-wrap\"\n [popover]=\"infoText | translate\"\n ></button>\n </label>\n <c8y-editor\n class=\"flex-grow min-height-0\"\n [ngModel]=\"valueString\"\n (ngModelChange)=\"dashboardJSONChange($event)\"\n (editorInit)=\"assignSchema()\"\n [theme]=\"editorTheme\"\n monacoEditorMarkerValidator\n [editorOptions]=\"editorOptions\"\n ></c8y-editor>\n </div>\n <div class=\"col-md-4 d-col col-xs-6\">\n <label translate>Validation</label>\n <div\n class=\"c8y-messages has-error m-b-24 inner-scroll flex-grow\"\n *ngIf=\"errors().length > 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n *ngFor=\"let error of errors()\"\n >\n <span\n class=\"error-path\"\n *ngIf=\"error.path\"\n >\n {{ error.path }}:\n </span>\n <span class=\"error-message\">{{ error.message }}</span>\n </div>\n </div>\n <div\n class=\"c8y-messages has-success m-b-24\"\n *ngIf=\"errors().length === 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n >\n <span class=\"error-message\">{{ 'No errors found' | translate }}</span>\n </div>\n </div>\n <div class=\"d-flex gap-16 a-i-center flex-no-shrink min-height-0 m-t-auto\">\n <c8y-drop-area\n class=\"drop-area-sm min-width-0\"\n [icon]=\"'upload'\"\n *ngIf=\"!isExporting\"\n [accept]=\"'.json'\"\n [maxAllowedFiles]=\"1\"\n [message]=\"'Import JSON' | translate\"\n (dropped)=\"import($event)\"\n [loading]=\"isImporting\"\n ></c8y-drop-area>\n <button\n class=\"btn btn-primary\"\n (click)=\"export()\"\n [disabled]=\"isExporting || isImporting\"\n [ngClass]=\"{\n 'btn-pending': isExporting\n }\"\n >\n {{'Export JSON' | translate}}\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n\n</div>\n\n<ng-template #loading>\n <c8y-loading></c8y-loading>\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.C8yTranslateDirective, selector: "[translate],[ngx-translate]" }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: i1.LoadingComponent, selector: "c8y-loading", inputs: ["layout", "progress", "message"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "ngmodule", type: CoreModule }, { kind: "component", type: i1.DropAreaComponent, selector: "c8y-drop-area", inputs: ["formControl", "title", "message", "icon", "loadingMessage", "forceHideList", "alwaysShow", "clickToOpen", "loading", "progress", "maxAllowedFiles", "files", "maxFileSizeInMegaBytes", "accept"], outputs: ["dropped"] }, { kind: "ngmodule", type: PopoverModule }, { kind: "directive", type: i4$1.PopoverDirective, selector: "[popover]", inputs: ["adaptivePosition", "boundariesElement", "popover", "popoverContext", "popoverTitle", "placement", "outsideClick", "triggers", "container", "containerClass", "isOpen", "delay"], outputs: ["onShown", "onHidden"], exportAs: ["bs-popover"] }, { kind: "component", type: EditorComponent, selector: "c8y-editor", inputs: ["editorOptions", "theme"], outputs: ["editorInit"] }, { kind: "pipe", type: i1.C8yTranslatePipe, name: "translate" }] }); }
557
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: DashboardJsonEditorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
558
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.19", type: DashboardJsonEditorComponent, isStandalone: true, selector: "c8y-dashboard-json-editor", providers: [JsonValidationService, ImportExportWidgetsService], viewQueries: [{ propertyName: "editorComponent", first: true, predicate: EditorComponent, descendants: true }], ngImport: i0, template: "<div class=\"card-block\">\n<div\n class=\"d-flex d-col\"\n [ngStyle]=\"{ height: '410px' }\"\n>\n <ng-container *ngIf=\"!isExporting && !isImporting; else loading\">\n <div class=\"d-flex gap-16 flex-grow min-height-0\">\n <div class=\"d-col col-md-8 col-xs-6\">\n <label class=\"d-flex a-i-center\">{{ 'Dashboard configuration' | translate }} \n <button \n type=\"button\"\n [attr.aria-label]=\"'Help' | translate\"\n class=\"btn-help \" \n placement=\"right\"\n triggers=\"focus\"\n containerClass=\"text-pre-wrap\"\n [popover]=\"infoText | translate\"\n ></button>\n </label>\n <c8y-editor\n class=\"flex-grow min-height-0\"\n [ngModel]=\"valueString\"\n (ngModelChange)=\"dashboardJSONChange($event)\"\n (editorInit)=\"assignSchema()\"\n [theme]=\"editorTheme\"\n monacoEditorMarkerValidator\n [editorOptions]=\"editorOptions\"\n ></c8y-editor>\n </div>\n <div class=\"col-md-4 d-col col-xs-6\">\n <label translate>Validation</label>\n <div\n class=\"c8y-messages has-error m-b-24 inner-scroll flex-grow\"\n *ngIf=\"errors().length > 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n *ngFor=\"let error of errors()\"\n >\n <span\n class=\"error-path\"\n *ngIf=\"error.path\"\n >\n {{ error.path }}:\n </span>\n <span class=\"error-message\">{{ error.message }}</span>\n </div>\n </div>\n <div\n class=\"c8y-messages has-success m-b-24\"\n *ngIf=\"errors().length === 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n >\n <span class=\"error-message\">{{ 'No errors found' | translate }}</span>\n </div>\n </div>\n <div class=\"d-flex gap-16 a-i-center flex-no-shrink min-height-0 m-t-auto\">\n <c8y-drop-area\n class=\"drop-area-sm min-width-0\"\n [icon]=\"'upload'\"\n *ngIf=\"!isExporting\"\n [accept]=\"'.json'\"\n [maxAllowedFiles]=\"1\"\n [message]=\"'Import JSON' | translate\"\n (dropped)=\"import($event)\"\n [loading]=\"isImporting\"\n ></c8y-drop-area>\n <button\n class=\"btn btn-primary\"\n (click)=\"export()\"\n [disabled]=\"isExporting || isImporting\"\n [ngClass]=\"{\n 'btn-pending': isExporting\n }\"\n >\n {{'Export JSON' | translate}}\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n\n</div>\n\n<ng-template #loading>\n <c8y-loading></c8y-loading>\n</ng-template>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.C8yTranslateDirective, selector: "[translate],[ngx-translate]" }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: i1.LoadingComponent, selector: "c8y-loading", inputs: ["layout", "progress", "message"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i3$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "ngmodule", type: CoreModule }, { kind: "component", type: i1.DropAreaComponent, selector: "c8y-drop-area", inputs: ["formControl", "title", "message", "icon", "loadingMessage", "forceHideList", "alwaysShow", "clickToOpen", "loading", "progress", "maxAllowedFiles", "files", "maxFileSizeInMegaBytes", "accept"], outputs: ["dropped"] }, { kind: "ngmodule", type: PopoverModule }, { kind: "directive", type: i4$1.PopoverDirective, selector: "[popover]", inputs: ["adaptivePosition", "boundariesElement", "popover", "popoverContext", "popoverTitle", "placement", "outsideClick", "triggers", "container", "containerClass", "isOpen", "delay"], outputs: ["onShown", "onHidden"], exportAs: ["bs-popover"] }, { kind: "component", type: EditorComponent, selector: "c8y-editor", inputs: ["editorOptions", "theme"], outputs: ["editorInit"] }, { kind: "pipe", type: i1.C8yTranslatePipe, name: "translate" }] }); }
559
559
  }
560
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: DashboardJsonEditorComponent, decorators: [{
560
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: DashboardJsonEditorComponent, decorators: [{
561
561
  type: Component,
562
562
  args: [{ selector: 'c8y-dashboard-json-editor', standalone: true, imports: [
563
563
  CommonModule,
@@ -573,10 +573,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImpo
573
573
  }] } });
574
574
 
575
575
  class DashboardDetailsAdvancedTabComponent {
576
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: DashboardDetailsAdvancedTabComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
577
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.18", type: DashboardDetailsAdvancedTabComponent, isStandalone: true, selector: "app-dashboard-details-advanced-tab", ngImport: i0, template: `<c8y-dashboard-json-editor></c8y-dashboard-json-editor>`, isInline: true, dependencies: [{ kind: "component", type: DashboardJsonEditorComponent, selector: "c8y-dashboard-json-editor" }] }); }
576
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: DashboardDetailsAdvancedTabComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
577
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.19", type: DashboardDetailsAdvancedTabComponent, isStandalone: true, selector: "app-dashboard-details-advanced-tab", ngImport: i0, template: `<c8y-dashboard-json-editor></c8y-dashboard-json-editor>`, isInline: true, dependencies: [{ kind: "component", type: DashboardJsonEditorComponent, selector: "c8y-dashboard-json-editor" }] }); }
578
578
  }
579
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImport: i0, type: DashboardDetailsAdvancedTabComponent, decorators: [{
579
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: DashboardDetailsAdvancedTabComponent, decorators: [{
580
580
  type: Component,
581
581
  args: [{
582
582
  selector: 'app-dashboard-details-advanced-tab',
@@ -587,4 +587,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.18", ngImpo
587
587
  }] });
588
588
 
589
589
  export { DashboardDetailsAdvancedTabComponent };
590
- //# sourceMappingURL=c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DVEnCRzW.mjs.map
590
+ //# sourceMappingURL=c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DFytXNdc.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DVEnCRzW.mjs","sources":["../../dashboard-details-advanced-tab/dashboard-json-editor/json-validation.service.ts","../../dashboard-details-advanced-tab/assign-widget-assets/assign-widget-asset-modal.component.ts","../../dashboard-details-advanced-tab/assign-widget-assets/assign-widget-asset-modal.component.html","../../dashboard-details-advanced-tab/dashboard-json-editor/import-export-widgets.service.ts","../../dashboard-details-advanced-tab/dashboard-json-editor/dashboard-json-editor.component.ts","../../dashboard-details-advanced-tab/dashboard-json-editor/dashboard-json-editor.component.html","../../dashboard-details-advanced-tab/dashboard-details-advanced-tab.component.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { ContextDashboard } from '@c8y/ngx-components/context-dashboard';\nimport { DynamicComponentService } from '@c8y/ngx-components';\nimport Ajv from 'ajv';\nimport addFormats from 'ajv-formats';\nimport { JSONSchema7 } from 'json-schema';\n\nexport type JSONValidationError = {\n message: string;\n path: string;\n};\n\n@Injectable()\nexport class JsonValidationService {\n ajv: Ajv;\n private OMIT_ERRORS = ['must NOT be valid', 'must match exactly one schema in oneOf'];\n\n constructor(private dynamicComponentService: DynamicComponentService) {\n this.ajv = new Ajv({ verbose: true, allErrors: true });\n addFormats(this.ajv as any);\n }\n\n async validateDashboard(dashboardJson: string, schemas?: any[]): Promise<JSONValidationError[]> {\n try {\n // Parse JSON string to object\n const dashboard: ContextDashboard = JSON.parse(dashboardJson);\n\n // Get or use provided schemas\n const validationSchemas = schemas || (await this.getJsonSchemas(dashboard));\n\n // Create a new Ajv instance\n const validator = new Ajv({\n verbose: true,\n allErrors: true\n });\n\n addFormats(validator as any);\n\n // Add all component schemas individually\n validationSchemas.forEach(({ uri, schema }) => {\n validator.addSchema(schema, uri);\n });\n\n const errorsMap = new Map<string, JSONValidationError>();\n\n // Validate main dashboard structure first (without children)\n const mainSchema = validationSchemas.find(\n s => s.uri === 'context-dashboard.c8y-schema-loader'\n )?.schema;\n\n if (!mainSchema) {\n throw new Error('Dashboard schema not found');\n }\n\n // Create a copy without children for main validation\n const dashboardWithoutChildren = { ...dashboard };\n delete dashboardWithoutChildren.children;\n\n const mainValidate = validator.compile(mainSchema);\n mainValidate(dashboardWithoutChildren);\n\n // Now validate each widget with its specific schema\n if (dashboard.children) {\n Object.entries(dashboard.children).forEach(([widgetId, widget]) => {\n const componentId = widget.componentId;\n // Find the correct schema for this widget type\n const widgetSchema = validationSchemas.find(s => s.uri === componentId)?.schema;\n\n if (widgetSchema) {\n // Validate this widget's config against its specific schema\n const validateWidgetConfig = validator.compile(widgetSchema);\n const isValid = validateWidgetConfig(widget.config);\n\n if (!isValid && validateWidgetConfig.errors) {\n validateWidgetConfig.errors.forEach(error => {\n const message = error.message || 'Unknown error';\n const basePath = `/children/${widgetId}/config`;\n const relativePath = error.instancePath;\n const fullPath = basePath + relativePath;\n\n if (!this.OMIT_ERRORS.includes(message)) {\n errorsMap.set(`${message}::${fullPath}`, {\n message,\n path: fullPath\n });\n }\n });\n }\n }\n });\n }\n\n // Process any errors from main validation\n if (mainValidate.errors) {\n mainValidate.errors.forEach(error => {\n const message = error.message || 'Unknown error';\n const path = error.instancePath;\n\n // Skip children validation errors as we handled them separately\n if (!path.includes('/children/') && !this.OMIT_ERRORS.includes(message)) {\n errorsMap.set(`${message}::${path}`, { message, path });\n }\n });\n }\n\n return Array.from(errorsMap.values());\n } catch (error) {\n if (error instanceof SyntaxError) {\n return [{ message: 'Invalid JSON syntax', path: '' }];\n }\n throw error;\n }\n }\n\n /**\n * Returns JSON schema for dashboard and all its children.\n * Children are referenced by their componentId. Dashboard schema is enriched with references to children schemas.\n * @param dashboard Context dashboard object.\n */\n async getJsonSchemas(dashboard: ContextDashboard) {\n try {\n const dashboardChildrenIds = [\n ...new Set(Object.entries(dashboard.children || {}).map(([_, value]) => value.componentId))\n ];\n\n const widgetSchemasPromises = dashboardChildrenIds.map(id => this.getSchemaForWidget(id));\n const widgetSchemasResults = await Promise.allSettled(widgetSchemasPromises);\n\n // Filter out failed or null schemas\n const validWidgetSchemas = widgetSchemasResults\n .filter(\n (result): result is PromiseFulfilledResult<{ id: string; schema: any }> =>\n result.status === 'fulfilled' && result.value !== null\n )\n .map(result => result.value);\n\n const { schema: dashboardSchemaOriginal }: { schema: JSONSchema7 } = await import(\n 'c8y-schema-loader?interfaceName=ContextDashboard&type=dashboarding!@c8y/ngx-components/context-dashboard'\n );\n const dashboardSchema = JSON.parse(JSON.stringify(dashboardSchemaOriginal));\n\n // Modify Widget definition with proper schema structure\n if (validWidgetSchemas.length > 0) {\n // Remove any existing allOf or oneOf conditions that might interfere\n if (dashboardSchema.definitions.Widget.allOf) {\n delete dashboardSchema.definitions.Widget.allOf;\n }\n\n // Set up the oneOf condition\n dashboardSchema.definitions.Widget.oneOf = this.getWidgetSchemasReferences(\n validWidgetSchemas.map(({ id }) => id)\n );\n }\n\n return [\n {\n uri: 'context-dashboard.c8y-schema-loader',\n fileMatch: ['*'],\n schema: dashboardSchema\n },\n ...validWidgetSchemas.map(({ id, schema }) => ({\n uri: id,\n schema: schema\n }))\n ];\n } catch (error) {\n console.error('Error processing dashboard schemas:', error);\n throw error;\n }\n }\n\n private async getSchemaForWidget(id: string) {\n try {\n const def = await this.dynamicComponentService.getById(id);\n if (def?.data?.schema && typeof def.data.schema === 'function') {\n const { schema }: { schema: JSONSchema7 } = await def.data.schema();\n return { id, schema };\n }\n return null;\n } catch (error) {\n console.warn(`Failed to fetch schema for widget ${id}:`, error);\n return null;\n }\n }\n\n private getWidgetSchemasReferences(widgetIds: string[]) {\n // provide references to all children schemas\n const schemasPart = widgetIds.map(id => {\n return {\n properties: {\n componentId: { const: id },\n config: { $ref: `${id}#` } // Ensure proper URI reference format\n },\n required: ['componentId'] // Only require componentId\n };\n });\n\n // provide default schema for object if component has no schema definition\n const defaultPart = {\n not: {\n properties: {\n componentId: {\n enum: widgetIds\n }\n }\n },\n properties: {\n config: {\n type: 'object',\n additionalProperties: true\n }\n }\n };\n\n return [...schemasPart, defaultPart];\n }\n}\n","import { Component, inject, Input, OnInit } from '@angular/core';\nimport { gettext } from '@c8y/ngx-components/gettext';\nimport { CoreModule } from '@c8y/ngx-components';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { IManagedObject } from '@c8y/client';\nimport {\n AssetSelectionChangeEvent,\n AssetSelectorModule\n} from '@c8y/ngx-components/assets-navigator';\nimport { WidgetAssetToAlign } from '../advanced-tab.model';\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\n\n@Component({\n selector: 'c8y-assign-widget-asset-modal',\n templateUrl: './assign-widget-asset-modal.component.html',\n standalone: true,\n imports: [CoreModule, AssetSelectorModule, BsDropdownModule, TooltipModule]\n})\nexport class AssignWidgetAssetModalComponent implements OnInit {\n @Input() assetsToAlign: WidgetAssetToAlign[];\n @Input() contextAsset: IManagedObject;\n @Input() notSupportedWidgets: string[] = [];\n\n modalTitle = gettext(`\n For each asset in the widgets, we suggest a source based on the original configuration. \n You can accept it, choose another asset, or configure it later. If you don’t choose any option,\n the widget will not be imported.\n `);\n assetIdInfo = gettext('id: {{ assetId }}');\n acceptSuggestedLabel = gettext('Accept suggested asset');\n noSuggestedAssetLabel = gettext('No suggestion available');\n updatedWidgetAssets: (WidgetAssetToAlign & { selectedAsset?: IManagedObject | null })[] = [];\n hasSuggestedAssets: boolean;\n userClickedAcceptAllSuggested = false;\n assetSelectedLabel = gettext('Asset selected');\n assetNotSelectedLabel = gettext('Asset not selected');\n result: Promise<WidgetAssetToAlign[]> = new Promise((resolve, reject) => {\n this._close = resolve;\n this._cancel = reject;\n });\n private _close: (value: WidgetAssetToAlign[]) => void;\n private _cancel: (reason?: any) => void;\n private bsModalRef = inject(BsModalRef);\n\n ngOnInit() {\n this.updatedWidgetAssets = this.assetsToAlign.map(asset => ({\n ...asset\n }));\n this.hasSuggestedAssets = this.updatedWidgetAssets.some(\n asset => !!asset.deviceRef.value.suggestedDevice\n );\n }\n\n apply(): void {\n const alignedAssets: WidgetAssetToAlign[] = this.updatedWidgetAssets.map(asset => {\n return {\n widgetId: asset.widgetId,\n title: asset.title,\n deviceRef: {\n path: asset.deviceRef.path,\n value:\n asset.selectedAsset == null\n ? asset.selectedAsset\n : { ...asset.selectedAsset, suggestedDevice: null }\n }\n };\n });\n this._close(alignedAssets);\n this.bsModalRef.hide();\n }\n\n acceptAllSuggested() {\n this.userClickedAcceptAllSuggested = true;\n this.updatedWidgetAssets.forEach(asset => {\n if (asset.deviceRef.value.suggestedDevice) {\n asset.selectedAsset = asset.deviceRef.value.suggestedDevice;\n }\n });\n }\n\n cancel() {\n this.bsModalRef.hide();\n this._cancel();\n }\n\n selectionChange(\n $event: AssetSelectionChangeEvent,\n widgetAsset: WidgetAssetToAlign & { selectedAsset?: IManagedObject | null }\n ) {\n widgetAsset.selectedAsset = $event.change.item;\n }\n}\n","<div class=\"viewport-modal has-asset-selector\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'th-large'\"></i>\n <div\n class=\"modal-title\"\n id=\"modal-title\"\n translate\n >\n Select and confirm widget assets mapping\n </div>\n </div>\n <div\n class=\"inner-scroll\"\n id=\"modal-body\"\n >\n <div class=\"p-16\">\n <p class=\"text-center text-balance\">\n {{ modalTitle | translate }}\n </p>\n </div>\n @if (notSupportedWidgets.length) {\n <div class=\"d-flex fit-w j-c-center p-16 p-t-0\">\n <div class=\"alert alert-warning\">\n {{ 'Widgets not supported for asset mapping: {{ notSupportedWidgets }}' | translate: {\n notSupportedWidgets: notSupportedWidgets.join(', ') } }}\n </div>\n </div>\n }\n @if (!assetsToAlign.length) {\n <div class=\"p-16 d-flex j-c-center\">\n <c8y-ui-empty-state\n class=\"\"\n [icon]=\"'empty-box'\"\n [title]=\"'No assets to assign' | translate\"\n ></c8y-ui-empty-state>\n </div>\n }\n @if (assetsToAlign.length) {\n <div>\n <c8y-list-group class=\"separator-top no-border-last\">\n <c8y-li class=\"sticky-top bg-level-1 hidden-sm hidden-xs\">\n <c8y-li-icon></c8y-li-icon>\n <div class=\"d-flex\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium\"\n translate\n >\n Widget\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-r-0\">\n <p\n class=\"text-medium\"\n translate\n >\n Original source\n </p>\n </div>\n <div class=\"col-md-1 text-center\">\n <button\n class=\"btn btn-default btn-sm\"\n [attr.aria-label]=\"'Accept all suggested' | translate\"\n [tooltip]=\"'Accept all suggested' | translate\"\n placement=\"right\"\n (click)=\"acceptAllSuggested()\"\n [disabled]=\"!hasSuggestedAssets\"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div class=\"col-md-7 p-l-8\">\n <p\n class=\"text-medium\"\n translate\n >\n Selected source\n </p>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n @for (widgetAsset of updatedWidgetAssets; track widgetAsset; let i = $index) {\n <c8y-li class=\"c8y-list__item--overflow-visible\">\n <c8y-li-icon\n class=\"p-r-0 p-t-16\"\n icon=\"th-large\"\n ></c8y-li-icon>\n <div class=\"d-flex-md\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium boxed-label p-l-0\"\n title=\"{{ widgetAsset.title }}\"\n >\n {{ widgetAsset.title }}\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-l-md-0 p-r-0\">\n <!-- origin device -->\n <p class=\"visible-sm visible-xs text-label-small\">\n {{ 'Original source' | translate }}\n </p>\n <div class=\"d-flex gap-4 boxed-label\">\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.name }}\"\n >\n {{ widgetAsset.deviceRef.value.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.deviceRef.value.id }\n }}\n </small>\n </span>\n </div>\n </div>\n <div\n class=\"col-md-1 col-xs-1 p-l-xs-0 p-l-sm-0 p-r-sm-0 p-r-xs-0 text-center p-t-16\"\n >\n <i\n class=\"icon-20\"\n [c8yIcon]=\"\n widgetAsset.selectedAsset !== undefined ? 'ok' : 'inactive-state'\n \"\n [title]=\"\n widgetAsset.selectedAsset !== undefined\n ? (assetSelectedLabel | translate)\n : (assetNotSelectedLabel | translate)\n \"\n [ngClass]=\"{\n 'text-success': widgetAsset.selectedAsset !== undefined,\n 'text-muted': widgetAsset.selectedAsset === undefined\n }\"\n ></i>\n @if (\n widgetAsset.selectedAsset === undefined && userClickedAcceptAllSuggested\n ) {\n <span\n class=\"c8y-icon-badge\"\n [tooltip]=\"\n 'No suggestion available- widget will not be imported' | translate\n \"\n placement=\"right\"\n >\n <i\n class=\"status major stroked-icon\"\n c8yIcon=\"warning\"\n ></i>\n </span>\n }\n </div>\n <div class=\"col-md-4 col-xs-11 p-l-md-0\">\n <!-- Suggested/Selected source -->\n <p class=\"visible-sm visible-xs text-label-small m-t-16 m-b-8\">\n {{ 'Selected source' | translate }}\n </p>\n @if (\n widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div\n class=\"d-flex gap-4 text-muted boxed-label\"\n [attr.data-label]=\"'Suggested' | translate\"\n >\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value.suggestedDevice }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\"\n >\n {{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo\n | translate\n : { assetId: widgetAsset.deviceRef.value.suggestedDevice?.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (widgetAsset.selectedAsset) {\n <div class=\"d-flex gap-4 boxed-label\">\n <!-- selectedAsset icon -->\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.selectedAsset }\n \"\n ></ng-container>\n <!-- selectedAsset Name and ID -->\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.selectedAsset?.name }}\"\n >\n {{ widgetAsset.selectedAsset?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.selectedAsset.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (\n !widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div class=\"text-muted boxed-label\">\n <em>{{ 'No suggestion available' | translate }}</em>\n </div>\n }\n </div>\n <div class=\"col-md-3 p-0 flex-grow\">\n <div class=\"d-flex a-i-center j-c-end-md gap-8 boxed-label p-l-md-0 p-r-0\">\n <div class=\"input-group max-width-fit\">\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n [tooltip]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset ===\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n [disabled]=\"!widgetAsset.deviceRef.value.suggestedDevice\"\n (click)=\"\n widgetAsset.selectedAsset =\n widgetAsset.deviceRef.value.suggestedDevice\n \"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div\n class=\"dropdown input-group-btn\"\n container=\"body\"\n dropdown\n [insideClick]=\"true\"\n #dropdown=\"bs-dropdown\"\n >\n <button\n class=\"btn btn-default dropdown-toggle c8y-dropdown\"\n [attr.aria-label]=\"'Select asset' | translate\"\n tooltip=\"{{ 'Select asset' | translate }}\"\n placement=\"top\"\n container=\"body\"\n type=\"button\"\n dropdownToggle\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset !==\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n >\n <i [c8yIcon]=\"'card-exchange'\"></i>\n </button>\n <div\n class=\"dropdown-menu dropdown-menu-right--md\"\n style=\"width: 300px\"\n *dropdownMenu\n >\n @if (dropdown.isOpen) {\n <c8y-asset-selector-miller\n (onSelected)=\"\n selectionChange($event, widgetAsset); dropdown.hide()\n \"\n [asset]=\"contextAsset\"\n [config]=\"{\n groupsSelectable: true,\n showChildDevices: true,\n showFilter: true,\n showSelected: false,\n columnHeaders: true,\n singleColumn: true,\n preventInitialSelect: true\n }\"\n ></c8y-asset-selector-miller>\n }\n </div>\n </div>\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"'Configure later' | translate\"\n tooltip=\"{{ 'Configure later' | translate }}\"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{ active: widgetAsset.selectedAsset === null }\"\n (click)=\"widgetAsset.selectedAsset = null\"\n >\n <i [c8yIcon]=\"'link-off'\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n }\n </c8y-list-group>\n </div>\n }\n </div>\n <div class=\"modal-footer\">\n <button\n class=\"btn btn-default\"\n [title]=\"'Cancel' | translate\"\n type=\"button\"\n (click)=\"cancel()\"\n >\n {{ 'Cancel' | translate }}\n </button>\n <button\n class=\"btn btn-primary\"\n [title]=\"'Apply' | translate\"\n type=\"button\"\n (click)=\"apply()\"\n >\n {{ 'Apply' | translate }}\n </button>\n </div>\n</div>\n\n<ng-template\n #assetIcon\n let-device\n>\n @if (device.c8y_IsDevice) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'data-transfer'\"\n ></i>\n }\n @if (device.c8y_IsDeviceGroup && !device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'c8y-group'\"\n ></i>\n }\n @if (device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"device.icon?.name || 'c8y-group'\"\n ></i>\n }\n</ng-template>\n","import { inject, Injectable, Injector, runInInjectionContext } from '@angular/core';\nimport { ContextDashboard, DashboardDetailService } from '@c8y/ngx-components/context-dashboard';\nimport { gettext } from '@c8y/ngx-components/gettext';\nimport { cloneDeep } from 'lodash-es';\nimport { saveAs } from 'file-saver';\nimport {\n AlertService,\n DroppedFile,\n DynamicComponentService,\n Widget,\n WidgetDataType\n} from '@c8y/ngx-components';\nimport { IManagedObject } from '@c8y/client';\nimport { BsModalService } from 'ngx-bootstrap/modal';\nimport { AssignWidgetAssetModalComponent } from '../assign-widget-assets/assign-widget-asset-modal.component';\nimport { WidgetAssetToAlign } from '../advanced-tab.model';\n\n@Injectable()\nexport class ImportExportWidgetsService {\n private dynamicComponentService = inject(DynamicComponentService);\n private injector = inject(Injector);\n private alertService = inject(AlertService);\n private dashboardDetailService = inject(DashboardDetailService);\n private modal = inject(BsModalService);\n\n /**\n * Export the dashboard to a JSON file. If the widget has an export method, it will be called to export\n * the widget's configuration.\n * @param dashboard Context dashboard to be exported\n */\n async export(dashboard: ContextDashboard) {\n const copiedDashboard: ContextDashboard = cloneDeep(dashboard);\n\n for (const [id, child] of Object.entries(copiedDashboard.children || {})) {\n try {\n const definition = await this.dynamicComponentService.getById(child.componentId);\n\n if (definition && typeof definition.data.export === 'function') {\n const widgetData: WidgetDataType = definition.data;\n const pluginInjector = definition.injector || this.injector;\n await runInInjectionContext(pluginInjector, async () => {\n const exportedConfig = await widgetData.export(\n child.config,\n this.dashboardDetailService.details,\n { pluginInjector, injector: this.injector }\n );\n copiedDashboard.children[id].config = exportedConfig;\n });\n }\n } catch (error) {\n this.alertService.addServerFailure(error);\n }\n }\n const dateStr = new Date().toISOString().replace(/[:.]/g, '-');\n const filename = `dashboard_${dateStr}.json`;\n const blob = new Blob([JSON.stringify(copiedDashboard)], { type: 'application/json' });\n saveAs(blob, filename);\n this.alertService.success(gettext('Dashboard exported.'));\n }\n\n /**\n * Import the dashboard from a JSON file. If the widget has an import method, it will be called to import\n * widget's configuration.\n * @param file JSON file with context dashboard configuration\n */\n async import(file: DroppedFile[]) {\n if (!file || file.length === 0) {\n return;\n }\n const dashboard: ContextDashboard = await file[0].readAsJson();\n const notSupportedWidgets: string[] = [];\n\n for (const [id, child] of Object.entries(dashboard.children)) {\n try {\n const definition = await this.dynamicComponentService.getById(child.componentId);\n\n if (definition && typeof definition.data.import === 'function') {\n const widgetData: WidgetDataType = definition.data;\n const pluginInjector = definition.injector || this.injector;\n await runInInjectionContext(pluginInjector, async () => {\n const importedConfig = await widgetData.import(\n child.config,\n this.dashboardDetailService.details,\n { pluginInjector, injector: this.injector }\n );\n dashboard.children[id].config = importedConfig;\n });\n } else {\n notSupportedWidgets.push(child.title);\n }\n } catch (error) {\n console.error(`Error importing widget with id ${id}:`, error);\n }\n }\n if (Object.entries(dashboard.children).length) {\n dashboard.children = await this.assignWidgetAssets(dashboard.children, notSupportedWidgets);\n if (!dashboard.children) {\n return;\n }\n }\n\n return JSON.stringify(dashboard, null, 2);\n }\n\n private async assignWidgetAssets(\n widgets: {\n [id: string]: Widget;\n },\n notSupportedWidgets: string[]\n ): Promise<{ [id: string]: Widget }> {\n const assetsToAlign = this.findWidgetsWithSuggestedDevice(widgets);\n const contextAsset = this.dashboardDetailService.details.context;\n\n try {\n const modalRef = this.modal.show(AssignWidgetAssetModalComponent, {\n class: 'modal-lg',\n ariaDescribedby: 'modal-body',\n ariaLabelledBy: 'modal-title',\n ignoreBackdropClick: true,\n keyboard: false,\n initialState: { assetsToAlign, contextAsset, notSupportedWidgets }\n }).content;\n const result = await modalRef.result;\n\n return this.updateWidgets(widgets, result);\n } catch (_) {\n // cancel clicked\n return null;\n }\n }\n\n private findWidgetsWithSuggestedDevice(widgets: Record<string, Widget>): WidgetAssetToAlign[] {\n const results: WidgetAssetToAlign[] = [];\n\n const searchObject = (obj: any, path: string[] = []): void => {\n if (!obj || typeof obj !== 'object') return;\n\n for (const [key, value] of Object.entries(obj)) {\n const currentPath = [...path, key];\n\n if (key === 'suggestedDevice') {\n // Find the nearest device/__target reference\n let deviceRef: (IManagedObject & { suggestedDevice: IManagedObject }) | null = null;\n let devicePath: string[] = [];\n\n // Search for __target or device in parent objects\n let currentObj = obj;\n const currentSearchPath = [...path];\n while (currentObj && !deviceRef) {\n if (currentObj.__target) {\n deviceRef = currentObj.__target;\n devicePath = [...currentSearchPath, '__target'];\n break;\n }\n if (currentObj.device) {\n deviceRef = currentObj.device;\n devicePath = [...currentSearchPath, 'device'];\n break;\n }\n // Move up one level\n currentSearchPath.pop();\n currentObj = this.getObjectByPath(widgets, currentSearchPath);\n }\n\n if (deviceRef) {\n const widgetId = path[0]; // First element in path should be widget ID\n results.push({\n widgetId,\n title: widgets[widgetId].title,\n deviceRef: { path: devicePath, value: deviceRef }\n });\n }\n } else if (typeof value === 'object') {\n searchObject(value, currentPath);\n }\n }\n };\n\n searchObject(widgets);\n return results;\n }\n\n private getObjectByPath(obj: any, path: string[]): any {\n return path.reduce((curr, key) => curr && curr[key], obj);\n }\n\n private updateWidgets(\n originalWidgets: Record<string, Widget>,\n processedReferences: Array<{\n widgetId: string;\n deviceRef: { path: string[]; value: IManagedObject };\n }>\n ): Record<string, Widget> {\n const result = JSON.parse(JSON.stringify(originalWidgets));\n\n // remove widgets that were no aligned\n processedReferences.forEach(ref => {\n if (ref.deviceRef.value === undefined) {\n delete result[ref.widgetId];\n return;\n }\n\n // apply selected assets to widgets\n const obj = this.getObjectByPath(result, ref.deviceRef.path.slice(0, -1));\n const lastKey = ref.deviceRef.path[ref.deviceRef.path.length - 1];\n if (obj && lastKey) {\n obj[lastKey] = ref.deviceRef.value;\n delete obj[lastKey]?.suggestedDevice;\n }\n });\n\n return result;\n }\n}\n","import { ContextDashboard, DashboardDetailService } from '@c8y/ngx-components/context-dashboard';\nimport { Component, inject, OnInit, signal, ViewChild } from '@angular/core';\nimport { PopoverModule } from 'ngx-bootstrap/popover';\nimport { gettext } from '@c8y/ngx-components/gettext';\nimport {\n CommonModule,\n CoreModule,\n DroppedFile,\n FormsModule,\n ThemeOptions\n} from '@c8y/ngx-components';\nimport { EditorComponent } from '@c8y/ngx-components/editor';\nimport { JSONValidationError, JsonValidationService } from './json-validation.service';\nimport { debounceTime, Subject, takeUntil } from 'rxjs';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { ImportExportWidgetsService } from './import-export-widgets.service';\n\n@Component({\n selector: 'c8y-dashboard-json-editor',\n templateUrl: 'dashboard-json-editor.component.html',\n standalone: true,\n imports: [\n CommonModule,\n FormsModule,\n ReactiveFormsModule,\n CoreModule,\n PopoverModule,\n EditorComponent\n ],\n providers: [JsonValidationService, ImportExportWidgetsService]\n})\nexport class DashboardJsonEditorComponent implements OnInit {\n infoText = gettext(\n \"Import / Export allows copying dashboard configurations between assets using JSON files. You can export a dashboard's setup and import it to another asset.\\n\\nNote: Basic knowledge of dashboard JSON structure is required.\"\n );\n @ViewChild(EditorComponent) editorComponent!: EditorComponent;\n dashboard: ContextDashboard;\n\n valueString = '';\n errors = signal<JSONValidationError[]>([]);\n editorDirty: boolean;\n editorTheme: ThemeOptions;\n isExporting = false;\n isImporting = false;\n editorOptions: EditorComponent['editorOptions'] = {\n hover: {\n above: false\n }\n };\n\n private dashboardDetailService = inject(DashboardDetailService);\n private jsonValidationService = inject(JsonValidationService);\n private importExportWidgetsService = inject(ImportExportWidgetsService);\n\n private valueChange = new Subject<void>();\n private destroy$ = new Subject<void>();\n private currentSchemas: any[] | null = null;\n\n ngOnInit() {\n this.dashboard = this.dashboardDetailService.details.dashboard;\n this.editorTheme = this.getEditorTheme();\n\n this.valueString = JSON.stringify(this.dashboard, null, 2);\n this.valueChange.pipe(debounceTime(500), takeUntil(this.destroy$)).subscribe(() => {\n this.applyChanges();\n this.validate();\n });\n }\n\n ngOnDestroy() {\n this.destroy$.next();\n this.destroy$.complete();\n }\n\n dashboardJSONChange(value: string) {\n this.valueString = value;\n this.valueChange.next();\n }\n\n async assignSchema() {\n this.currentSchemas = await this.jsonValidationService.getJsonSchemas(this.dashboard);\n this.editorComponent.monaco.languages.json.jsonDefaults.setDiagnosticsOptions({\n validate: true,\n schemas: this.currentSchemas,\n enableSchemaRequest: false,\n allowComments: false\n });\n this.validate();\n }\n\n async validate() {\n this.editorDirty = this.valueString !== JSON.stringify(this.dashboard, null, 2);\n try {\n const validationResult = await this.jsonValidationService.validateDashboard(\n this.valueString,\n this.currentSchemas\n );\n this.errors.set(validationResult);\n } catch (error) {\n console.error('Validation error:', error);\n this.errors.set([\n {\n message: 'An error occurred during validation',\n path: ''\n }\n ]);\n }\n }\n\n applyChanges() {\n try {\n const newDashboard = JSON.parse(this.valueString);\n this.dashboardDetailService.details.dashboard = newDashboard;\n this.dashboardDetailService.generalSettingsForm.patchValue(newDashboard);\n this.dashboardDetailService.appearanceSettingsForm.patchValue(newDashboard);\n this.dashboardDetailService.widgetsForm.patchValue(newDashboard);\n this.dashboardDetailService.previewChangedFn({\n classes: newDashboard.classes,\n widgetClasses: newDashboard.widgetClasses\n });\n this.dashboardDetailService.dashboardDetailsForm.markAsDirty();\n this.dashboardDetailService.saveButtonDisabled = false;\n } catch (error) {\n // disable save button if JSON is invalid and don't apply value to form\n this.dashboardDetailService.saveButtonDisabled = true;\n }\n }\n\n async export() {\n this.isExporting = true;\n try {\n await this.importExportWidgetsService.export(this.dashboard);\n } finally {\n this.isExporting = false;\n }\n }\n\n async import(file: DroppedFile[]) {\n this.isImporting = true;\n try {\n if (file && file.length !== 0) {\n const importedValue = await this.importExportWidgetsService.import(file);\n if (importedValue) {\n this.valueString = importedValue;\n this.valueChange.next();\n }\n }\n } finally {\n this.isImporting = false;\n }\n }\n\n private getEditorTheme(): ThemeOptions | null {\n const dashboardClasses =\n this.dashboardDetailService.appearanceSettingsForm.get('classes').value;\n\n if (dashboardClasses['dashboard-theme-dark']) {\n return 'dark';\n } else if (dashboardClasses['dashboard-theme-white']) {\n return 'light';\n }\n return null;\n }\n}\n","<div class=\"card-block\">\n<div\n class=\"d-flex d-col\"\n [ngStyle]=\"{ height: '410px' }\"\n>\n <ng-container *ngIf=\"!isExporting && !isImporting; else loading\">\n <div class=\"d-flex gap-16 flex-grow min-height-0\">\n <div class=\"d-col col-md-8 col-xs-6\">\n <label class=\"d-flex a-i-center\">{{ 'Dashboard configuration' | translate }} \n <button \n type=\"button\"\n [attr.aria-label]=\"'Help' | translate\"\n class=\"btn-help \" \n placement=\"right\"\n triggers=\"focus\"\n containerClass=\"text-pre-wrap\"\n [popover]=\"infoText | translate\"\n ></button>\n </label>\n <c8y-editor\n class=\"flex-grow min-height-0\"\n [ngModel]=\"valueString\"\n (ngModelChange)=\"dashboardJSONChange($event)\"\n (editorInit)=\"assignSchema()\"\n [theme]=\"editorTheme\"\n monacoEditorMarkerValidator\n [editorOptions]=\"editorOptions\"\n ></c8y-editor>\n </div>\n <div class=\"col-md-4 d-col col-xs-6\">\n <label translate>Validation</label>\n <div\n class=\"c8y-messages has-error m-b-24 inner-scroll flex-grow\"\n *ngIf=\"errors().length > 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n *ngFor=\"let error of errors()\"\n >\n <span\n class=\"error-path\"\n *ngIf=\"error.path\"\n >\n {{ error.path }}:\n </span>\n <span class=\"error-message\">{{ error.message }}</span>\n </div>\n </div>\n <div\n class=\"c8y-messages has-success m-b-24\"\n *ngIf=\"errors().length === 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n >\n <span class=\"error-message\">{{ 'No errors found' | translate }}</span>\n </div>\n </div>\n <div class=\"d-flex gap-16 a-i-center flex-no-shrink min-height-0 m-t-auto\">\n <c8y-drop-area\n class=\"drop-area-sm min-width-0\"\n [icon]=\"'upload'\"\n *ngIf=\"!isExporting\"\n [accept]=\"'.json'\"\n [maxAllowedFiles]=\"1\"\n [message]=\"'Import JSON' | translate\"\n (dropped)=\"import($event)\"\n [loading]=\"isImporting\"\n ></c8y-drop-area>\n <button\n class=\"btn btn-primary\"\n (click)=\"export()\"\n [disabled]=\"isExporting || isImporting\"\n [ngClass]=\"{\n 'btn-pending': isExporting\n }\"\n >\n {{'Export JSON' | translate}}\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n\n</div>\n\n<ng-template #loading>\n <c8y-loading></c8y-loading>\n</ng-template>\n","import { Component } from '@angular/core';\nimport { DashboardJsonEditorComponent } from './dashboard-json-editor/dashboard-json-editor.component';\n\n@Component({\n selector: 'app-dashboard-details-advanced-tab',\n template: `<c8y-dashboard-json-editor></c8y-dashboard-json-editor>`,\n standalone: true,\n imports: [DashboardJsonEditorComponent]\n})\nexport class DashboardDetailsAdvancedTabComponent {}\n"],"names":["i3","i4"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;MAaa,qBAAqB,CAAA;AAIhC,IAAA,WAAA,CAAoB,uBAAgD,EAAA;QAAhD,IAAA,CAAA,uBAAuB,GAAvB,uBAAuB;AAFnC,QAAA,IAAA,CAAA,WAAW,GAAG,CAAC,mBAAmB,EAAE,wCAAwC,CAAC;AAGnF,QAAA,IAAI,CAAC,GAAG,GAAG,IAAI,GAAG,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;AACtD,QAAA,UAAU,CAAC,IAAI,CAAC,GAAU,CAAC;IAC7B;AAEA,IAAA,MAAM,iBAAiB,CAAC,aAAqB,EAAE,OAAe,EAAA;AAC5D,QAAA,IAAI;;YAEF,MAAM,SAAS,GAAqB,IAAI,CAAC,KAAK,CAAC,aAAa,CAAC;;AAG7D,YAAA,MAAM,iBAAiB,GAAG,OAAO,KAAK,MAAM,IAAI,CAAC,cAAc,CAAC,SAAS,CAAC,CAAC;;AAG3E,YAAA,MAAM,SAAS,GAAG,IAAI,GAAG,CAAC;AACxB,gBAAA,OAAO,EAAE,IAAI;AACb,gB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AA,2BAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;4FAE3B,oCAAoC,EAAA,UAAA,EAAA,CAAA;kBANhD,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,oCAAoC;AAC9C,oBAAA,QAAQ,EAAE,CAAA,uDAAA,CAAyD;AACnE,oBAAA,UAAU,EAAE,IAAI;oBAChB,OAAO,EAAE,CAAC,4BAA4B;AACvC,iBAAA;;;;;"}
1
+ {"version":3,"file":"c8y-ngx-components-dashboard-details-advanced-tab-dashboard-details-advanced-tab.component-DFytXNdc.mjs","sources":["../../dashboard-details-advanced-tab/dashboard-json-editor/json-validation.service.ts","../../dashboard-details-advanced-tab/assign-widget-assets/assign-widget-asset-modal.component.ts","../../dashboard-details-advanced-tab/assign-widget-assets/assign-widget-asset-modal.component.html","../../dashboard-details-advanced-tab/dashboard-json-editor/import-export-widgets.service.ts","../../dashboard-details-advanced-tab/dashboard-json-editor/dashboard-json-editor.component.ts","../../dashboard-details-advanced-tab/dashboard-json-editor/dashboard-json-editor.component.html","../../dashboard-details-advanced-tab/dashboard-details-advanced-tab.component.ts"],"sourcesContent":["import { Injectable } from '@angular/core';\nimport { ContextDashboard } from '@c8y/ngx-components/context-dashboard';\nimport { DynamicComponentService } from '@c8y/ngx-components';\nimport Ajv from 'ajv';\nimport addFormats from 'ajv-formats';\nimport { JSONSchema7 } from 'json-schema';\n\nexport type JSONValidationError = {\n message: string;\n path: string;\n};\n\n@Injectable()\nexport class JsonValidationService {\n ajv: Ajv;\n private OMIT_ERRORS = ['must NOT be valid', 'must match exactly one schema in oneOf'];\n\n constructor(private dynamicComponentService: DynamicComponentService) {\n this.ajv = new Ajv({ verbose: true, allErrors: true });\n addFormats(this.ajv as any);\n }\n\n async validateDashboard(dashboardJson: string, schemas?: any[]): Promise<JSONValidationError[]> {\n try {\n // Parse JSON string to object\n const dashboard: ContextDashboard = JSON.parse(dashboardJson);\n\n // Get or use provided schemas\n const validationSchemas = schemas || (await this.getJsonSchemas(dashboard));\n\n // Create a new Ajv instance\n const validator = new Ajv({\n verbose: true,\n allErrors: true\n });\n\n addFormats(validator as any);\n\n // Add all component schemas individually\n validationSchemas.forEach(({ uri, schema }) => {\n validator.addSchema(schema, uri);\n });\n\n const errorsMap = new Map<string, JSONValidationError>();\n\n // Validate main dashboard structure first (without children)\n const mainSchema = validationSchemas.find(\n s => s.uri === 'context-dashboard.c8y-schema-loader'\n )?.schema;\n\n if (!mainSchema) {\n throw new Error('Dashboard schema not found');\n }\n\n // Create a copy without children for main validation\n const dashboardWithoutChildren = { ...dashboard };\n delete dashboardWithoutChildren.children;\n\n const mainValidate = validator.compile(mainSchema);\n mainValidate(dashboardWithoutChildren);\n\n // Now validate each widget with its specific schema\n if (dashboard.children) {\n Object.entries(dashboard.children).forEach(([widgetId, widget]) => {\n const componentId = widget.componentId;\n // Find the correct schema for this widget type\n const widgetSchema = validationSchemas.find(s => s.uri === componentId)?.schema;\n\n if (widgetSchema) {\n // Validate this widget's config against its specific schema\n const validateWidgetConfig = validator.compile(widgetSchema);\n const isValid = validateWidgetConfig(widget.config);\n\n if (!isValid && validateWidgetConfig.errors) {\n validateWidgetConfig.errors.forEach(error => {\n const message = error.message || 'Unknown error';\n const basePath = `/children/${widgetId}/config`;\n const relativePath = error.instancePath;\n const fullPath = basePath + relativePath;\n\n if (!this.OMIT_ERRORS.includes(message)) {\n errorsMap.set(`${message}::${fullPath}`, {\n message,\n path: fullPath\n });\n }\n });\n }\n }\n });\n }\n\n // Process any errors from main validation\n if (mainValidate.errors) {\n mainValidate.errors.forEach(error => {\n const message = error.message || 'Unknown error';\n const path = error.instancePath;\n\n // Skip children validation errors as we handled them separately\n if (!path.includes('/children/') && !this.OMIT_ERRORS.includes(message)) {\n errorsMap.set(`${message}::${path}`, { message, path });\n }\n });\n }\n\n return Array.from(errorsMap.values());\n } catch (error) {\n if (error instanceof SyntaxError) {\n return [{ message: 'Invalid JSON syntax', path: '' }];\n }\n throw error;\n }\n }\n\n /**\n * Returns JSON schema for dashboard and all its children.\n * Children are referenced by their componentId. Dashboard schema is enriched with references to children schemas.\n * @param dashboard Context dashboard object.\n */\n async getJsonSchemas(dashboard: ContextDashboard) {\n try {\n const dashboardChildrenIds = [\n ...new Set(Object.entries(dashboard.children || {}).map(([_, value]) => value.componentId))\n ];\n\n const widgetSchemasPromises = dashboardChildrenIds.map(id => this.getSchemaForWidget(id));\n const widgetSchemasResults = await Promise.allSettled(widgetSchemasPromises);\n\n // Filter out failed or null schemas\n const validWidgetSchemas = widgetSchemasResults\n .filter(\n (result): result is PromiseFulfilledResult<{ id: string; schema: any }> =>\n result.status === 'fulfilled' && result.value !== null\n )\n .map(result => result.value);\n\n const { schema: dashboardSchemaOriginal }: { schema: JSONSchema7 } = await import(\n 'c8y-schema-loader?interfaceName=ContextDashboard&type=dashboarding!@c8y/ngx-components/context-dashboard'\n );\n const dashboardSchema = JSON.parse(JSON.stringify(dashboardSchemaOriginal));\n\n // Modify Widget definition with proper schema structure\n if (validWidgetSchemas.length > 0) {\n // Remove any existing allOf or oneOf conditions that might interfere\n if (dashboardSchema.definitions.Widget.allOf) {\n delete dashboardSchema.definitions.Widget.allOf;\n }\n\n // Set up the oneOf condition\n dashboardSchema.definitions.Widget.oneOf = this.getWidgetSchemasReferences(\n validWidgetSchemas.map(({ id }) => id)\n );\n }\n\n return [\n {\n uri: 'context-dashboard.c8y-schema-loader',\n fileMatch: ['*'],\n schema: dashboardSchema\n },\n ...validWidgetSchemas.map(({ id, schema }) => ({\n uri: id,\n schema: schema\n }))\n ];\n } catch (error) {\n console.error('Error processing dashboard schemas:', error);\n throw error;\n }\n }\n\n private async getSchemaForWidget(id: string) {\n try {\n const def = await this.dynamicComponentService.getById(id);\n if (def?.data?.schema && typeof def.data.schema === 'function') {\n const { schema }: { schema: JSONSchema7 } = await def.data.schema();\n return { id, schema };\n }\n return null;\n } catch (error) {\n console.warn(`Failed to fetch schema for widget ${id}:`, error);\n return null;\n }\n }\n\n private getWidgetSchemasReferences(widgetIds: string[]) {\n // provide references to all children schemas\n const schemasPart = widgetIds.map(id => {\n return {\n properties: {\n componentId: { const: id },\n config: { $ref: `${id}#` } // Ensure proper URI reference format\n },\n required: ['componentId'] // Only require componentId\n };\n });\n\n // provide default schema for object if component has no schema definition\n const defaultPart = {\n not: {\n properties: {\n componentId: {\n enum: widgetIds\n }\n }\n },\n properties: {\n config: {\n type: 'object',\n additionalProperties: true\n }\n }\n };\n\n return [...schemasPart, defaultPart];\n }\n}\n","import { Component, inject, Input, OnInit } from '@angular/core';\nimport { gettext } from '@c8y/ngx-components/gettext';\nimport { CoreModule } from '@c8y/ngx-components';\nimport { BsModalRef } from 'ngx-bootstrap/modal';\nimport { IManagedObject } from '@c8y/client';\nimport {\n AssetSelectionChangeEvent,\n AssetSelectorModule\n} from '@c8y/ngx-components/assets-navigator';\nimport { WidgetAssetToAlign } from '../advanced-tab.model';\nimport { BsDropdownModule } from 'ngx-bootstrap/dropdown';\nimport { TooltipModule } from 'ngx-bootstrap/tooltip';\n\n@Component({\n selector: 'c8y-assign-widget-asset-modal',\n templateUrl: './assign-widget-asset-modal.component.html',\n standalone: true,\n imports: [CoreModule, AssetSelectorModule, BsDropdownModule, TooltipModule]\n})\nexport class AssignWidgetAssetModalComponent implements OnInit {\n @Input() assetsToAlign: WidgetAssetToAlign[];\n @Input() contextAsset: IManagedObject;\n @Input() notSupportedWidgets: string[] = [];\n\n modalTitle = gettext(`\n For each asset in the widgets, we suggest a source based on the original configuration. \n You can accept it, choose another asset, or configure it later. If you don’t choose any option,\n the widget will not be imported.\n `);\n assetIdInfo = gettext('id: {{ assetId }}');\n acceptSuggestedLabel = gettext('Accept suggested asset');\n noSuggestedAssetLabel = gettext('No suggestion available');\n updatedWidgetAssets: (WidgetAssetToAlign & { selectedAsset?: IManagedObject | null })[] = [];\n hasSuggestedAssets: boolean;\n userClickedAcceptAllSuggested = false;\n assetSelectedLabel = gettext('Asset selected');\n assetNotSelectedLabel = gettext('Asset not selected');\n result: Promise<WidgetAssetToAlign[]> = new Promise((resolve, reject) => {\n this._close = resolve;\n this._cancel = reject;\n });\n private _close: (value: WidgetAssetToAlign[]) => void;\n private _cancel: (reason?: any) => void;\n private bsModalRef = inject(BsModalRef);\n\n ngOnInit() {\n this.updatedWidgetAssets = this.assetsToAlign.map(asset => ({\n ...asset\n }));\n this.hasSuggestedAssets = this.updatedWidgetAssets.some(\n asset => !!asset.deviceRef.value.suggestedDevice\n );\n }\n\n apply(): void {\n const alignedAssets: WidgetAssetToAlign[] = this.updatedWidgetAssets.map(asset => {\n return {\n widgetId: asset.widgetId,\n title: asset.title,\n deviceRef: {\n path: asset.deviceRef.path,\n value:\n asset.selectedAsset == null\n ? asset.selectedAsset\n : { ...asset.selectedAsset, suggestedDevice: null }\n }\n };\n });\n this._close(alignedAssets);\n this.bsModalRef.hide();\n }\n\n acceptAllSuggested() {\n this.userClickedAcceptAllSuggested = true;\n this.updatedWidgetAssets.forEach(asset => {\n if (asset.deviceRef.value.suggestedDevice) {\n asset.selectedAsset = asset.deviceRef.value.suggestedDevice;\n }\n });\n }\n\n cancel() {\n this.bsModalRef.hide();\n this._cancel();\n }\n\n selectionChange(\n $event: AssetSelectionChangeEvent,\n widgetAsset: WidgetAssetToAlign & { selectedAsset?: IManagedObject | null }\n ) {\n widgetAsset.selectedAsset = $event.change.item;\n }\n}\n","<div class=\"viewport-modal has-asset-selector\">\n <div class=\"modal-header dialog-header\">\n <i [c8yIcon]=\"'th-large'\"></i>\n <div\n class=\"modal-title\"\n id=\"modal-title\"\n translate\n >\n Select and confirm widget assets mapping\n </div>\n </div>\n <div\n class=\"inner-scroll\"\n id=\"modal-body\"\n >\n <div class=\"p-16\">\n <p class=\"text-center text-balance\">\n {{ modalTitle | translate }}\n </p>\n </div>\n @if (notSupportedWidgets.length) {\n <div class=\"d-flex fit-w j-c-center p-16 p-t-0\">\n <div class=\"alert alert-warning\">\n {{ 'Widgets not supported for asset mapping: {{ notSupportedWidgets }}' | translate: {\n notSupportedWidgets: notSupportedWidgets.join(', ') } }}\n </div>\n </div>\n }\n @if (!assetsToAlign.length) {\n <div class=\"p-16 d-flex j-c-center\">\n <c8y-ui-empty-state\n class=\"\"\n [icon]=\"'empty-box'\"\n [title]=\"'No assets to assign' | translate\"\n ></c8y-ui-empty-state>\n </div>\n }\n @if (assetsToAlign.length) {\n <div>\n <c8y-list-group class=\"separator-top no-border-last\">\n <c8y-li class=\"sticky-top bg-level-1 hidden-sm hidden-xs\">\n <c8y-li-icon></c8y-li-icon>\n <div class=\"d-flex\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium\"\n translate\n >\n Widget\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-r-0\">\n <p\n class=\"text-medium\"\n translate\n >\n Original source\n </p>\n </div>\n <div class=\"col-md-1 text-center\">\n <button\n class=\"btn btn-default btn-sm\"\n [attr.aria-label]=\"'Accept all suggested' | translate\"\n [tooltip]=\"'Accept all suggested' | translate\"\n placement=\"right\"\n (click)=\"acceptAllSuggested()\"\n [disabled]=\"!hasSuggestedAssets\"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div class=\"col-md-7 p-l-8\">\n <p\n class=\"text-medium\"\n translate\n >\n Selected source\n </p>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n @for (widgetAsset of updatedWidgetAssets; track widgetAsset; let i = $index) {\n <c8y-li class=\"c8y-list__item--overflow-visible\">\n <c8y-li-icon\n class=\"p-r-0 p-t-16\"\n icon=\"th-large\"\n ></c8y-li-icon>\n <div class=\"d-flex-md\">\n <div class=\"col-md-2\">\n <!-- title -->\n <p\n class=\"text-truncate text-medium boxed-label p-l-0\"\n title=\"{{ widgetAsset.title }}\"\n >\n {{ widgetAsset.title }}\n </p>\n </div>\n <div class=\"col-md-10\">\n <div class=\"row\">\n <div class=\"col-md-4 p-l-md-0 p-r-0\">\n <!-- origin device -->\n <p class=\"visible-sm visible-xs text-label-small\">\n {{ 'Original source' | translate }}\n </p>\n <div class=\"d-flex gap-4 boxed-label\">\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.name }}\"\n >\n {{ widgetAsset.deviceRef.value.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.deviceRef.value.id }\n }}\n </small>\n </span>\n </div>\n </div>\n <div\n class=\"col-md-1 col-xs-1 p-l-xs-0 p-l-sm-0 p-r-sm-0 p-r-xs-0 text-center p-t-16\"\n >\n <i\n class=\"icon-20\"\n [c8yIcon]=\"\n widgetAsset.selectedAsset !== undefined ? 'ok' : 'inactive-state'\n \"\n [title]=\"\n widgetAsset.selectedAsset !== undefined\n ? (assetSelectedLabel | translate)\n : (assetNotSelectedLabel | translate)\n \"\n [ngClass]=\"{\n 'text-success': widgetAsset.selectedAsset !== undefined,\n 'text-muted': widgetAsset.selectedAsset === undefined\n }\"\n ></i>\n @if (\n widgetAsset.selectedAsset === undefined && userClickedAcceptAllSuggested\n ) {\n <span\n class=\"c8y-icon-badge\"\n [tooltip]=\"\n 'No suggestion available- widget will not be imported' | translate\n \"\n placement=\"right\"\n >\n <i\n class=\"status major stroked-icon\"\n c8yIcon=\"warning\"\n ></i>\n </span>\n }\n </div>\n <div class=\"col-md-4 col-xs-11 p-l-md-0\">\n <!-- Suggested/Selected source -->\n <p class=\"visible-sm visible-xs text-label-small m-t-16 m-b-8\">\n {{ 'Selected source' | translate }}\n </p>\n @if (\n widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div\n class=\"d-flex gap-4 text-muted boxed-label\"\n [attr.data-label]=\"'Suggested' | translate\"\n >\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.deviceRef.value.suggestedDevice }\n \"\n ></ng-container>\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\"\n >\n {{ widgetAsset.deviceRef.value.suggestedDevice?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo\n | translate\n : { assetId: widgetAsset.deviceRef.value.suggestedDevice?.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (widgetAsset.selectedAsset) {\n <div class=\"d-flex gap-4 boxed-label\">\n <!-- selectedAsset icon -->\n <ng-container\n *ngTemplateOutlet=\"\n assetIcon;\n context: { $implicit: widgetAsset.selectedAsset }\n \"\n ></ng-container>\n <!-- selectedAsset Name and ID -->\n <span class=\"text-truncate\">\n <span\n class=\"text-truncate\"\n title=\"{{ widgetAsset.selectedAsset?.name }}\"\n >\n {{ widgetAsset.selectedAsset?.name }}\n </span>\n <small class=\"text-muted\">\n {{\n assetIdInfo | translate: { assetId: widgetAsset.selectedAsset.id }\n }}\n </small>\n </span>\n </div>\n }\n @if (\n !widgetAsset.deviceRef.value.suggestedDevice && !widgetAsset.selectedAsset\n ) {\n <div class=\"text-muted boxed-label\">\n <em>{{ 'No suggestion available' | translate }}</em>\n </div>\n }\n </div>\n <div class=\"col-md-3 p-0 flex-grow\">\n <div class=\"d-flex a-i-center j-c-end-md gap-8 boxed-label p-l-md-0 p-r-0\">\n <div class=\"input-group max-width-fit\">\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n [tooltip]=\"\n (widgetAsset.deviceRef.value.suggestedDevice\n ? acceptSuggestedLabel\n : noSuggestedAssetLabel\n ) | translate\n \"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset ===\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n [disabled]=\"!widgetAsset.deviceRef.value.suggestedDevice\"\n (click)=\"\n widgetAsset.selectedAsset =\n widgetAsset.deviceRef.value.suggestedDevice\n \"\n >\n <i [c8yIcon]=\"'check'\"></i>\n </button>\n </div>\n <div\n class=\"dropdown input-group-btn\"\n container=\"body\"\n dropdown\n [insideClick]=\"true\"\n #dropdown=\"bs-dropdown\"\n >\n <button\n class=\"btn btn-default dropdown-toggle c8y-dropdown\"\n [attr.aria-label]=\"'Select asset' | translate\"\n tooltip=\"{{ 'Select asset' | translate }}\"\n placement=\"top\"\n container=\"body\"\n type=\"button\"\n dropdownToggle\n [ngClass]=\"{\n active:\n widgetAsset.selectedAsset &&\n widgetAsset.selectedAsset !==\n widgetAsset.deviceRef.value.suggestedDevice\n }\"\n >\n <i [c8yIcon]=\"'card-exchange'\"></i>\n </button>\n <div\n class=\"dropdown-menu dropdown-menu-right--md\"\n style=\"width: 300px\"\n *dropdownMenu\n >\n @if (dropdown.isOpen) {\n <c8y-asset-selector-miller\n (onSelected)=\"\n selectionChange($event, widgetAsset); dropdown.hide()\n \"\n [asset]=\"contextAsset\"\n [config]=\"{\n groupsSelectable: true,\n showChildDevices: true,\n showFilter: true,\n showSelected: false,\n columnHeaders: true,\n singleColumn: true,\n preventInitialSelect: true\n }\"\n ></c8y-asset-selector-miller>\n }\n </div>\n </div>\n <div class=\"input-group-btn\">\n <button\n class=\"btn btn-default\"\n [attr.aria-label]=\"'Configure later' | translate\"\n tooltip=\"{{ 'Configure later' | translate }}\"\n placement=\"top\"\n container=\"body\"\n [ngClass]=\"{ active: widgetAsset.selectedAsset === null }\"\n (click)=\"widgetAsset.selectedAsset = null\"\n >\n <i [c8yIcon]=\"'link-off'\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </c8y-li>\n }\n </c8y-list-group>\n </div>\n }\n </div>\n <div class=\"modal-footer\">\n <button\n class=\"btn btn-default\"\n [title]=\"'Cancel' | translate\"\n type=\"button\"\n (click)=\"cancel()\"\n >\n {{ 'Cancel' | translate }}\n </button>\n <button\n class=\"btn btn-primary\"\n [title]=\"'Apply' | translate\"\n type=\"button\"\n (click)=\"apply()\"\n >\n {{ 'Apply' | translate }}\n </button>\n </div>\n</div>\n\n<ng-template\n #assetIcon\n let-device\n>\n @if (device.c8y_IsDevice) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'data-transfer'\"\n ></i>\n }\n @if (device.c8y_IsDeviceGroup && !device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"'c8y-group'\"\n ></i>\n }\n @if (device.c8y_IsAsset) {\n <i\n class=\"l-h-inherit\"\n [c8yIcon]=\"device.icon?.name || 'c8y-group'\"\n ></i>\n }\n</ng-template>\n","import { inject, Injectable, Injector, runInInjectionContext } from '@angular/core';\nimport { ContextDashboard, DashboardDetailService } from '@c8y/ngx-components/context-dashboard';\nimport { gettext } from '@c8y/ngx-components/gettext';\nimport { cloneDeep } from 'lodash-es';\nimport { saveAs } from 'file-saver';\nimport {\n AlertService,\n DroppedFile,\n DynamicComponentService,\n Widget,\n WidgetDataType\n} from '@c8y/ngx-components';\nimport { IManagedObject } from '@c8y/client';\nimport { BsModalService } from 'ngx-bootstrap/modal';\nimport { AssignWidgetAssetModalComponent } from '../assign-widget-assets/assign-widget-asset-modal.component';\nimport { WidgetAssetToAlign } from '../advanced-tab.model';\n\n@Injectable()\nexport class ImportExportWidgetsService {\n private dynamicComponentService = inject(DynamicComponentService);\n private injector = inject(Injector);\n private alertService = inject(AlertService);\n private dashboardDetailService = inject(DashboardDetailService);\n private modal = inject(BsModalService);\n\n /**\n * Export the dashboard to a JSON file. If the widget has an export method, it will be called to export\n * the widget's configuration.\n * @param dashboard Context dashboard to be exported\n */\n async export(dashboard: ContextDashboard) {\n const copiedDashboard: ContextDashboard = cloneDeep(dashboard);\n\n for (const [id, child] of Object.entries(copiedDashboard.children || {})) {\n try {\n const definition = await this.dynamicComponentService.getById(child.componentId);\n\n if (definition && typeof definition.data.export === 'function') {\n const widgetData: WidgetDataType = definition.data;\n const pluginInjector = definition.injector || this.injector;\n await runInInjectionContext(pluginInjector, async () => {\n const exportedConfig = await widgetData.export(\n child.config,\n this.dashboardDetailService.details,\n { pluginInjector, injector: this.injector }\n );\n copiedDashboard.children[id].config = exportedConfig;\n });\n }\n } catch (error) {\n this.alertService.addServerFailure(error);\n }\n }\n const dateStr = new Date().toISOString().replace(/[:.]/g, '-');\n const filename = `dashboard_${dateStr}.json`;\n const blob = new Blob([JSON.stringify(copiedDashboard)], { type: 'application/json' });\n saveAs(blob, filename);\n this.alertService.success(gettext('Dashboard exported.'));\n }\n\n /**\n * Import the dashboard from a JSON file. If the widget has an import method, it will be called to import\n * widget's configuration.\n * @param file JSON file with context dashboard configuration\n */\n async import(file: DroppedFile[]) {\n if (!file || file.length === 0) {\n return;\n }\n const dashboard: ContextDashboard = await file[0].readAsJson();\n const notSupportedWidgets: string[] = [];\n\n for (const [id, child] of Object.entries(dashboard.children)) {\n try {\n const definition = await this.dynamicComponentService.getById(child.componentId);\n\n if (definition && typeof definition.data.import === 'function') {\n const widgetData: WidgetDataType = definition.data;\n const pluginInjector = definition.injector || this.injector;\n await runInInjectionContext(pluginInjector, async () => {\n const importedConfig = await widgetData.import(\n child.config,\n this.dashboardDetailService.details,\n { pluginInjector, injector: this.injector }\n );\n dashboard.children[id].config = importedConfig;\n });\n } else {\n notSupportedWidgets.push(child.title);\n }\n } catch (error) {\n console.error(`Error importing widget with id ${id}:`, error);\n }\n }\n if (Object.entries(dashboard.children).length) {\n dashboard.children = await this.assignWidgetAssets(dashboard.children, notSupportedWidgets);\n if (!dashboard.children) {\n return;\n }\n }\n\n return JSON.stringify(dashboard, null, 2);\n }\n\n private async assignWidgetAssets(\n widgets: {\n [id: string]: Widget;\n },\n notSupportedWidgets: string[]\n ): Promise<{ [id: string]: Widget }> {\n const assetsToAlign = this.findWidgetsWithSuggestedDevice(widgets);\n const contextAsset = this.dashboardDetailService.details.context;\n\n try {\n const modalRef = this.modal.show(AssignWidgetAssetModalComponent, {\n class: 'modal-lg',\n ariaDescribedby: 'modal-body',\n ariaLabelledBy: 'modal-title',\n ignoreBackdropClick: true,\n keyboard: false,\n initialState: { assetsToAlign, contextAsset, notSupportedWidgets }\n }).content;\n const result = await modalRef.result;\n\n return this.updateWidgets(widgets, result);\n } catch (_) {\n // cancel clicked\n return null;\n }\n }\n\n private findWidgetsWithSuggestedDevice(widgets: Record<string, Widget>): WidgetAssetToAlign[] {\n const results: WidgetAssetToAlign[] = [];\n\n const searchObject = (obj: any, path: string[] = []): void => {\n if (!obj || typeof obj !== 'object') return;\n\n for (const [key, value] of Object.entries(obj)) {\n const currentPath = [...path, key];\n\n if (key === 'suggestedDevice') {\n // Find the nearest device/__target reference\n let deviceRef: (IManagedObject & { suggestedDevice: IManagedObject }) | null = null;\n let devicePath: string[] = [];\n\n // Search for __target or device in parent objects\n let currentObj = obj;\n const currentSearchPath = [...path];\n while (currentObj && !deviceRef) {\n if (currentObj.__target) {\n deviceRef = currentObj.__target;\n devicePath = [...currentSearchPath, '__target'];\n break;\n }\n if (currentObj.device) {\n deviceRef = currentObj.device;\n devicePath = [...currentSearchPath, 'device'];\n break;\n }\n // Move up one level\n currentSearchPath.pop();\n currentObj = this.getObjectByPath(widgets, currentSearchPath);\n }\n\n if (deviceRef) {\n const widgetId = path[0]; // First element in path should be widget ID\n results.push({\n widgetId,\n title: widgets[widgetId].title,\n deviceRef: { path: devicePath, value: deviceRef }\n });\n }\n } else if (typeof value === 'object') {\n searchObject(value, currentPath);\n }\n }\n };\n\n searchObject(widgets);\n return results;\n }\n\n private getObjectByPath(obj: any, path: string[]): any {\n return path.reduce((curr, key) => curr && curr[key], obj);\n }\n\n private updateWidgets(\n originalWidgets: Record<string, Widget>,\n processedReferences: Array<{\n widgetId: string;\n deviceRef: { path: string[]; value: IManagedObject };\n }>\n ): Record<string, Widget> {\n const result = JSON.parse(JSON.stringify(originalWidgets));\n\n // remove widgets that were no aligned\n processedReferences.forEach(ref => {\n if (ref.deviceRef.value === undefined) {\n delete result[ref.widgetId];\n return;\n }\n\n // apply selected assets to widgets\n const obj = this.getObjectByPath(result, ref.deviceRef.path.slice(0, -1));\n const lastKey = ref.deviceRef.path[ref.deviceRef.path.length - 1];\n if (obj && lastKey) {\n obj[lastKey] = ref.deviceRef.value;\n delete obj[lastKey]?.suggestedDevice;\n }\n });\n\n return result;\n }\n}\n","import { ContextDashboard, DashboardDetailService } from '@c8y/ngx-components/context-dashboard';\nimport { Component, inject, OnInit, signal, ViewChild } from '@angular/core';\nimport { PopoverModule } from 'ngx-bootstrap/popover';\nimport { gettext } from '@c8y/ngx-components/gettext';\nimport {\n CommonModule,\n CoreModule,\n DroppedFile,\n FormsModule,\n ThemeOptions\n} from '@c8y/ngx-components';\nimport { EditorComponent } from '@c8y/ngx-components/editor';\nimport { JSONValidationError, JsonValidationService } from './json-validation.service';\nimport { debounceTime, Subject, takeUntil } from 'rxjs';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { ImportExportWidgetsService } from './import-export-widgets.service';\n\n@Component({\n selector: 'c8y-dashboard-json-editor',\n templateUrl: 'dashboard-json-editor.component.html',\n standalone: true,\n imports: [\n CommonModule,\n FormsModule,\n ReactiveFormsModule,\n CoreModule,\n PopoverModule,\n EditorComponent\n ],\n providers: [JsonValidationService, ImportExportWidgetsService]\n})\nexport class DashboardJsonEditorComponent implements OnInit {\n infoText = gettext(\n \"Import / Export allows copying dashboard configurations between assets using JSON files. You can export a dashboard's setup and import it to another asset.\\n\\nNote: Basic knowledge of dashboard JSON structure is required.\"\n );\n @ViewChild(EditorComponent) editorComponent!: EditorComponent;\n dashboard: ContextDashboard;\n\n valueString = '';\n errors = signal<JSONValidationError[]>([]);\n editorDirty: boolean;\n editorTheme: ThemeOptions;\n isExporting = false;\n isImporting = false;\n editorOptions: EditorComponent['editorOptions'] = {\n hover: {\n above: false\n }\n };\n\n private dashboardDetailService = inject(DashboardDetailService);\n private jsonValidationService = inject(JsonValidationService);\n private importExportWidgetsService = inject(ImportExportWidgetsService);\n\n private valueChange = new Subject<void>();\n private destroy$ = new Subject<void>();\n private currentSchemas: any[] | null = null;\n\n ngOnInit() {\n this.dashboard = this.dashboardDetailService.details.dashboard;\n this.editorTheme = this.getEditorTheme();\n\n this.valueString = JSON.stringify(this.dashboard, null, 2);\n this.valueChange.pipe(debounceTime(500), takeUntil(this.destroy$)).subscribe(() => {\n this.applyChanges();\n this.validate();\n });\n }\n\n ngOnDestroy() {\n this.destroy$.next();\n this.destroy$.complete();\n }\n\n dashboardJSONChange(value: string) {\n this.valueString = value;\n this.valueChange.next();\n }\n\n async assignSchema() {\n this.currentSchemas = await this.jsonValidationService.getJsonSchemas(this.dashboard);\n this.editorComponent.monaco.languages.json.jsonDefaults.setDiagnosticsOptions({\n validate: true,\n schemas: this.currentSchemas,\n enableSchemaRequest: false,\n allowComments: false\n });\n this.validate();\n }\n\n async validate() {\n this.editorDirty = this.valueString !== JSON.stringify(this.dashboard, null, 2);\n try {\n const validationResult = await this.jsonValidationService.validateDashboard(\n this.valueString,\n this.currentSchemas\n );\n this.errors.set(validationResult);\n } catch (error) {\n console.error('Validation error:', error);\n this.errors.set([\n {\n message: 'An error occurred during validation',\n path: ''\n }\n ]);\n }\n }\n\n applyChanges() {\n try {\n const newDashboard = JSON.parse(this.valueString);\n this.dashboardDetailService.details.dashboard = newDashboard;\n this.dashboardDetailService.generalSettingsForm.patchValue(newDashboard);\n this.dashboardDetailService.appearanceSettingsForm.patchValue(newDashboard);\n this.dashboardDetailService.widgetsForm.patchValue(newDashboard);\n this.dashboardDetailService.previewChangedFn({\n classes: newDashboard.classes,\n widgetClasses: newDashboard.widgetClasses\n });\n this.dashboardDetailService.dashboardDetailsForm.markAsDirty();\n this.dashboardDetailService.saveButtonDisabled = false;\n } catch (error) {\n // disable save button if JSON is invalid and don't apply value to form\n this.dashboardDetailService.saveButtonDisabled = true;\n }\n }\n\n async export() {\n this.isExporting = true;\n try {\n await this.importExportWidgetsService.export(this.dashboard);\n } finally {\n this.isExporting = false;\n }\n }\n\n async import(file: DroppedFile[]) {\n this.isImporting = true;\n try {\n if (file && file.length !== 0) {\n const importedValue = await this.importExportWidgetsService.import(file);\n if (importedValue) {\n this.valueString = importedValue;\n this.valueChange.next();\n }\n }\n } finally {\n this.isImporting = false;\n }\n }\n\n private getEditorTheme(): ThemeOptions | null {\n const dashboardClasses =\n this.dashboardDetailService.appearanceSettingsForm.get('classes').value;\n\n if (dashboardClasses['dashboard-theme-dark']) {\n return 'dark';\n } else if (dashboardClasses['dashboard-theme-white']) {\n return 'light';\n }\n return null;\n }\n}\n","<div class=\"card-block\">\n<div\n class=\"d-flex d-col\"\n [ngStyle]=\"{ height: '410px' }\"\n>\n <ng-container *ngIf=\"!isExporting && !isImporting; else loading\">\n <div class=\"d-flex gap-16 flex-grow min-height-0\">\n <div class=\"d-col col-md-8 col-xs-6\">\n <label class=\"d-flex a-i-center\">{{ 'Dashboard configuration' | translate }} \n <button \n type=\"button\"\n [attr.aria-label]=\"'Help' | translate\"\n class=\"btn-help \" \n placement=\"right\"\n triggers=\"focus\"\n containerClass=\"text-pre-wrap\"\n [popover]=\"infoText | translate\"\n ></button>\n </label>\n <c8y-editor\n class=\"flex-grow min-height-0\"\n [ngModel]=\"valueString\"\n (ngModelChange)=\"dashboardJSONChange($event)\"\n (editorInit)=\"assignSchema()\"\n [theme]=\"editorTheme\"\n monacoEditorMarkerValidator\n [editorOptions]=\"editorOptions\"\n ></c8y-editor>\n </div>\n <div class=\"col-md-4 d-col col-xs-6\">\n <label translate>Validation</label>\n <div\n class=\"c8y-messages has-error m-b-24 inner-scroll flex-grow\"\n *ngIf=\"errors().length > 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n *ngFor=\"let error of errors()\"\n >\n <span\n class=\"error-path\"\n *ngIf=\"error.path\"\n >\n {{ error.path }}:\n </span>\n <span class=\"error-message\">{{ error.message }}</span>\n </div>\n </div>\n <div\n class=\"c8y-messages has-success m-b-24\"\n *ngIf=\"errors().length === 0\"\n >\n <div\n class=\"form-control-feedback-message\"\n >\n <span class=\"error-message\">{{ 'No errors found' | translate }}</span>\n </div>\n </div>\n <div class=\"d-flex gap-16 a-i-center flex-no-shrink min-height-0 m-t-auto\">\n <c8y-drop-area\n class=\"drop-area-sm min-width-0\"\n [icon]=\"'upload'\"\n *ngIf=\"!isExporting\"\n [accept]=\"'.json'\"\n [maxAllowedFiles]=\"1\"\n [message]=\"'Import JSON' | translate\"\n (dropped)=\"import($event)\"\n [loading]=\"isImporting\"\n ></c8y-drop-area>\n <button\n class=\"btn btn-primary\"\n (click)=\"export()\"\n [disabled]=\"isExporting || isImporting\"\n [ngClass]=\"{\n 'btn-pending': isExporting\n }\"\n >\n {{'Export JSON' | translate}}\n </button>\n </div>\n </div>\n </div>\n </ng-container>\n\n</div>\n\n<ng-template #loading>\n <c8y-loading></c8y-loading>\n</ng-template>\n","import { Component } from '@angular/core';\nimport { DashboardJsonEditorComponent } from './dashboard-json-editor/dashboard-json-editor.component';\n\n@Component({\n selector: 'app-dashboard-details-advanced-tab',\n template: `<c8y-dashboard-json-editor></c8y-dashboard-json-editor>`,\n standalone: true,\n imports: [DashboardJsonEditorComponent]\n})\nexport class DashboardDetailsAdvancedTabComponent {}\n"],"names":["i3","i4"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;MAaa,qBAAqB,CAAA;AAIhC,IAAA,WAAA,CAAoB,uBAAgD,EAAA;QAAhD,IAAA,CAAA,uBAAuB,GAAvB,uBAAuB;AAFnC,QAAA,IAAA,CAAA,WAAW,GAAG,CAAC,mBAAmB,EAAE,wCAAwC,CAAC;AAGnF,QAAA,IAAI,CAAC,GAAG,GAAG,IAAI,GAAG,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;AACtD,QAAA,UAAU,CAAC,IAAI,CAAC,GAAU,CAAC;IAC7B;AAEA,IAAA,MAAM,iBAAiB,C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