@tuki-io/tuki-widgets 0.0.219-dev.6 → 0.0.219-dev.62

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 (261) hide show
  1. package/contact-center/cc-import/cc-import.module.d.ts +13 -0
  2. package/contact-center/cc-import/cc-import.service.d.ts +85 -0
  3. package/contact-center/cc-import/components/import-contact-center-panel/import-contact-center-panel.component.d.ts +56 -0
  4. package/contact-center/cc-import/components/import-contact-center-wizard/import-contact-center-wizard.component.d.ts +77 -0
  5. package/contact-center/cc-import/components/import-contact-center-wizard/import-contact-center-wizard.types.d.ts +3 -0
  6. package/contact-center/cc-import/constants/cc-import.constants.d.ts +37 -0
  7. package/contact-center/cc-import/mock/cc-import.mock.d.ts +4 -0
  8. package/contact-center/cc-import/types/cc-import.d.ts +73 -0
  9. package/contact-center/cc-import/types/uccx.d.ts +109 -0
  10. package/contact-center/cc-readiness/cc-readiness.module.d.ts +3 -3
  11. package/contact-center/public-api.d.ts +8 -0
  12. package/contact-center/shared/api.endpoints.d.ts +25 -0
  13. package/contact-center/shared/api.service.d.ts +3 -1
  14. package/contact-center/shared/components/card/card.component.d.ts +13 -0
  15. package/contact-center/shared/dcp-api.service.d.ts +15 -0
  16. package/contact-center/shared/shared.module.d.ts +11 -5
  17. package/di2mt/api/api.endpoints.d.ts +3 -0
  18. package/esm2020/contact-center/cc-import/cc-import.module.mjs +45 -0
  19. package/esm2020/contact-center/cc-import/cc-import.service.mjs +228 -0
  20. package/esm2020/contact-center/cc-import/components/import-contact-center-panel/import-contact-center-panel.component.mjs +144 -0
  21. package/esm2020/contact-center/cc-import/components/import-contact-center-wizard/import-contact-center-wizard.component.mjs +243 -0
  22. package/esm2020/contact-center/cc-import/components/import-contact-center-wizard/import-contact-center-wizard.types.mjs +3 -0
  23. package/esm2020/contact-center/cc-import/constants/cc-import.constants.mjs +62 -0
  24. package/esm2020/contact-center/cc-import/mock/cc-import.mock.mjs +78 -0
  25. package/esm2020/contact-center/cc-import/types/cc-import.mjs +2 -0
  26. package/esm2020/contact-center/cc-import/types/uccx.mjs +24 -0
  27. package/esm2020/contact-center/cc-readiness/cc-readiness.module.mjs +7 -6
  28. package/esm2020/contact-center/cc-readiness/widgets/licences-requirement/licences-requirement.component.mjs +5 -5
  29. package/esm2020/contact-center/cc-readiness/widgets/summary-grid/summary-grid.component.mjs +2 -2
  30. package/esm2020/contact-center/public-api.mjs +9 -1
  31. package/esm2020/contact-center/shared/api.endpoints.mjs +26 -1
  32. package/esm2020/contact-center/shared/api.service.mjs +8 -3
  33. package/esm2020/contact-center/shared/components/card/card.component.mjs +24 -0
  34. package/esm2020/contact-center/shared/dcp-api.service.mjs +26 -0
  35. package/esm2020/contact-center/shared/shared.module.mjs +15 -5
  36. package/esm2020/di2mt/api/api.endpoints.mjs +4 -1
  37. package/esm2020/locations/public-api.mjs +8 -0
  38. package/esm2020/locations/src/app.constants.mjs +18 -0
  39. package/esm2020/locations/src/location-confirm-dialog/location-confirm-dialog.component.mjs +23 -0
  40. package/esm2020/locations/src/locations.component.mjs +398 -0
  41. package/esm2020/locations/src/locations.module.mjs +42 -0
  42. package/esm2020/locations/src/material.module.mjs +55 -0
  43. package/esm2020/locations/src/services/api.service.mjs +67 -0
  44. package/esm2020/locations/src/services/locations.service.mjs +69 -0
  45. package/esm2020/locations/src/types/location.mjs +2 -0
  46. package/esm2020/locations/src/utils/app-loader/app-loader.mjs +14 -0
  47. package/esm2020/locations/tuki-io-tuki-widgets-locations.mjs +5 -0
  48. package/esm2020/meetings/public-api.mjs +8 -0
  49. package/esm2020/meetings/src/app.constants.mjs +9 -0
  50. package/esm2020/meetings/src/components/live-meetings/live-meeting/live-meeting.component.mjs +107 -0
  51. package/esm2020/meetings/src/components/live-meetings/live-meetings.component.mjs +98 -0
  52. package/esm2020/meetings/src/components/meeting-spaces/meeting-space/meeting-space.component.mjs +110 -0
  53. package/esm2020/meetings/src/components/meeting-spaces/meeting-spaces.component.mjs +65 -0
  54. package/esm2020/meetings/src/material.module.mjs +76 -0
  55. package/esm2020/meetings/src/meetings.component.mjs +65 -0
  56. package/esm2020/meetings/src/meetings.module.mjs +51 -0
  57. package/esm2020/meetings/src/services/api.service.mjs +67 -0
  58. package/esm2020/meetings/src/services/live-meetings.service.mjs +178 -0
  59. package/esm2020/meetings/src/services/meeting-spaces.service.mjs +102 -0
  60. package/esm2020/meetings/src/types/live-meeting.mjs +2 -0
  61. package/esm2020/meetings/src/types/meeting-space.mjs +2 -0
  62. package/esm2020/meetings/src/utils/app-loader/app-loader.mjs +14 -0
  63. package/esm2020/meetings/tuki-io-tuki-widgets-meetings.mjs +5 -0
  64. package/esm2020/shared/public-api.mjs +4 -0
  65. package/esm2020/shared/src/ui/material.module.mjs +188 -0
  66. package/esm2020/shared/src/ui/shared.module.mjs +36 -0
  67. package/esm2020/shared/src/ui/tk-page-section/tk-page-section.component.mjs +13 -0
  68. package/esm2020/shared/src/ui/tk-page-section-row/tk-page-section-row.component.mjs +13 -0
  69. package/esm2020/shared/src/ui/ui.module.mjs +37 -0
  70. package/esm2020/shared/tuki-io-tuki-widgets-shared.mjs +5 -0
  71. package/esm2020/user-creation/src/utils/device-default-prefix.mjs +19 -2
  72. package/esm2020/user-creation/src/utils/device-name-dynamic-tokens.mjs +4 -0
  73. package/esm2020/user-creation/src/utils/parse-device-name-rule.mjs +6 -3
  74. package/esm2020/user-creation/src/widgets/user-creation-wizard/components/user-details-step/user-details-step.component.mjs +60 -13
  75. package/esm2020/user-creation/src/widgets/user-creation-wizard/components/user-template-step/user-template-step.component.mjs +2 -1
  76. package/esm2020/user-creation/src/widgets/user-creation-wizard/user-creation-wizard.component.mjs +8 -6
  77. package/esm2020/user-creation/src/widgets/user-creation-wizard/user-creation-wizard.service.mjs +13 -9
  78. package/esm2020/user-device-manage/public-api.mjs +4 -1
  79. package/esm2020/user-device-manage/src/app.constants.mjs +9 -3
  80. package/esm2020/user-device-manage/src/associate-lines/associate-lines.component.mjs +311 -0
  81. package/esm2020/user-device-manage/src/classes/device.mjs +1 -1
  82. package/esm2020/user-device-manage/src/classes/deviceProfile.mjs +1 -1
  83. package/esm2020/user-device-manage/src/classes/simplified-user.mjs +1 -1
  84. package/esm2020/user-device-manage/src/confirm-dialog/info-dialog.component.mjs +2 -2
  85. package/esm2020/user-device-manage/src/device-manage-widget.component.mjs +34 -17
  86. package/esm2020/user-device-manage/src/device-settings/device-settings.component.mjs +207 -0
  87. package/esm2020/user-device-manage/src/line-key-config/line-key-config.component.mjs +401 -0
  88. package/esm2020/user-device-manage/src/services/device.service.mjs +32 -2
  89. package/esm2020/user-device-manage/src/services/user.service.mjs +34 -6
  90. package/esm2020/user-device-manage/src/user-device-manage.module.mjs +19 -7
  91. package/esm2020/user-manage/src/app.constants.mjs +8 -1
  92. package/esm2020/user-manage/src/classes/simplified-user.mjs +19 -4
  93. package/esm2020/user-manage/src/device-list/device-list.component.mjs +7 -4
  94. package/esm2020/user-manage/src/device-list/device-row/device-row.component.mjs +6 -3
  95. package/esm2020/user-manage/src/lazy-loading-select/lazy-loading-select.component.mjs +9 -5
  96. package/esm2020/user-manage/src/material.module.mjs +21 -7
  97. package/esm2020/user-manage/src/services/dcp-api.service.mjs +79 -0
  98. package/esm2020/user-manage/src/services/site-settings.service.mjs +11 -4
  99. package/esm2020/user-manage/src/services/user.service.mjs +94 -19
  100. package/esm2020/user-manage/src/user-calling/user-calling.component.mjs +12 -7
  101. package/esm2020/user-manage/src/user-manage-widget.component.mjs +90 -39
  102. package/esm2020/user-manage/src/user-manage.module.mjs +14 -4
  103. package/esm2020/user-manage/src/user-summary/user-summary.component.mjs +30 -0
  104. package/esm2020/users-list/src/app.constants.mjs +2 -1
  105. package/esm2020/users-list/src/classes/simlified-user.mjs +1 -1
  106. package/esm2020/users-list/src/classes/user-list.mjs +2 -1
  107. package/esm2020/users-list/src/components/table-toolbar/table-toolbar.component.mjs +3 -3
  108. package/esm2020/users-list/src/move-user-wizard/move-user-stepper/move-user-stepper.component.mjs +14 -3
  109. package/esm2020/users-list/src/move-user-wizard/move-user-wizard.component.mjs +5 -3
  110. package/esm2020/users-list/src/users-list.component.mjs +100 -17
  111. package/esm2020/workspaces/public-api.mjs +8 -0
  112. package/esm2020/workspaces/src/app.constants.mjs +27 -0
  113. package/esm2020/workspaces/src/components/workspace-confirm-dialog/workspace-confirm-dialog.component.mjs +32 -0
  114. package/esm2020/workspaces/src/components/workspace-detail/workspace-detail.component.mjs +96 -0
  115. package/esm2020/workspaces/src/components/workspace-device-detail/workspace-device-detail.component.mjs +66 -0
  116. package/esm2020/workspaces/src/components/workspaces-filters/workspaces-filters.component.mjs +56 -0
  117. package/esm2020/workspaces/src/components/workspaces-table/workspaces-table.component.mjs +130 -0
  118. package/esm2020/workspaces/src/material.module.mjs +83 -0
  119. package/esm2020/workspaces/src/services/api-webex.service.mjs +14 -0
  120. package/esm2020/workspaces/src/services/api.service.mjs +67 -0
  121. package/esm2020/workspaces/src/services/workspace-detail.service.mjs +169 -0
  122. package/esm2020/workspaces/src/services/workspaces-migration.service.mjs +59 -0
  123. package/esm2020/workspaces/src/services/workspaces.service.mjs +152 -0
  124. package/esm2020/workspaces/src/types/workspace.mjs +4 -0
  125. package/esm2020/workspaces/src/utils/app-loader/app-loader.mjs +14 -0
  126. package/esm2020/workspaces/src/utils/device-icon.mjs +13 -0
  127. package/esm2020/workspaces/src/utils/workspace-name.mjs +8 -0
  128. package/esm2020/workspaces/src/workspaces.component.mjs +322 -0
  129. package/esm2020/workspaces/src/workspaces.module.mjs +54 -0
  130. package/esm2020/workspaces/tuki-io-tuki-widgets-workspaces.mjs +5 -0
  131. package/fesm2015/tuki-io-tuki-widgets-contact-center.mjs +998 -127
  132. package/fesm2015/tuki-io-tuki-widgets-contact-center.mjs.map +1 -1
  133. package/fesm2015/tuki-io-tuki-widgets-di2mt.mjs +3 -0
  134. package/fesm2015/tuki-io-tuki-widgets-di2mt.mjs.map +1 -1
  135. package/fesm2015/tuki-io-tuki-widgets-locations.mjs +679 -0
  136. package/fesm2015/tuki-io-tuki-widgets-locations.mjs.map +1 -0
  137. package/fesm2015/tuki-io-tuki-widgets-meetings.mjs +894 -0
  138. package/fesm2015/tuki-io-tuki-widgets-meetings.mjs.map +1 -0
  139. package/fesm2015/tuki-io-tuki-widgets-shared.mjs +280 -0
  140. package/fesm2015/tuki-io-tuki-widgets-shared.mjs.map +1 -0
  141. package/fesm2015/tuki-io-tuki-widgets-user-creation.mjs +111 -32
  142. package/fesm2015/tuki-io-tuki-widgets-user-creation.mjs.map +1 -1
  143. package/fesm2015/tuki-io-tuki-widgets-user-device-manage.mjs +1013 -48
  144. package/fesm2015/tuki-io-tuki-widgets-user-device-manage.mjs.map +1 -1
  145. package/fesm2015/tuki-io-tuki-widgets-user-manage.mjs +380 -89
  146. package/fesm2015/tuki-io-tuki-widgets-user-manage.mjs.map +1 -1
  147. package/fesm2015/tuki-io-tuki-widgets-users-list.mjs +121 -22
  148. package/fesm2015/tuki-io-tuki-widgets-users-list.mjs.map +1 -1
  149. package/fesm2015/tuki-io-tuki-widgets-workspaces.mjs +1292 -0
  150. package/fesm2015/tuki-io-tuki-widgets-workspaces.mjs.map +1 -0
  151. package/fesm2020/tuki-io-tuki-widgets-contact-center.mjs +989 -127
  152. package/fesm2020/tuki-io-tuki-widgets-contact-center.mjs.map +1 -1
  153. package/fesm2020/tuki-io-tuki-widgets-di2mt.mjs +3 -0
  154. package/fesm2020/tuki-io-tuki-widgets-di2mt.mjs.map +1 -1
  155. package/fesm2020/tuki-io-tuki-widgets-locations.mjs +672 -0
  156. package/fesm2020/tuki-io-tuki-widgets-locations.mjs.map +1 -0
  157. package/fesm2020/tuki-io-tuki-widgets-meetings.mjs +902 -0
  158. package/fesm2020/tuki-io-tuki-widgets-meetings.mjs.map +1 -0
  159. package/fesm2020/tuki-io-tuki-widgets-shared.mjs +280 -0
  160. package/fesm2020/tuki-io-tuki-widgets-shared.mjs.map +1 -0
  161. package/fesm2020/tuki-io-tuki-widgets-user-creation.mjs +104 -28
  162. package/fesm2020/tuki-io-tuki-widgets-user-creation.mjs.map +1 -1
  163. package/fesm2020/tuki-io-tuki-widgets-user-device-manage.mjs +996 -47
  164. package/fesm2020/tuki-io-tuki-widgets-user-device-manage.mjs.map +1 -1
  165. package/fesm2020/tuki-io-tuki-widgets-user-manage.mjs +366 -82
  166. package/fesm2020/tuki-io-tuki-widgets-user-manage.mjs.map +1 -1
  167. package/fesm2020/tuki-io-tuki-widgets-users-list.mjs +120 -22
  168. package/fesm2020/tuki-io-tuki-widgets-users-list.mjs.map +1 -1
  169. package/fesm2020/tuki-io-tuki-widgets-workspaces.mjs +1294 -0
  170. package/fesm2020/tuki-io-tuki-widgets-workspaces.mjs.map +1 -0
  171. package/locations/index.d.ts +5 -0
  172. package/locations/public-api.d.ts +2 -0
  173. package/locations/src/app.constants.d.ts +10 -0
  174. package/locations/src/location-confirm-dialog/location-confirm-dialog.component.d.ts +15 -0
  175. package/locations/src/locations.component.d.ts +92 -0
  176. package/locations/src/locations.module.d.ts +13 -0
  177. package/locations/src/material.module.d.ts +12 -0
  178. package/locations/src/services/api.service.d.ts +18 -0
  179. package/locations/src/services/locations.service.d.ts +25 -0
  180. package/locations/src/types/location.d.ts +30 -0
  181. package/locations/src/utils/app-loader/app-loader.d.ts +6 -0
  182. package/meetings/index.d.ts +5 -0
  183. package/meetings/public-api.d.ts +2 -0
  184. package/meetings/src/app.constants.d.ts +8 -0
  185. package/meetings/src/components/live-meetings/live-meeting/live-meeting.component.d.ts +34 -0
  186. package/meetings/src/components/live-meetings/live-meetings.component.d.ts +43 -0
  187. package/meetings/src/components/meeting-spaces/meeting-space/meeting-space.component.d.ts +39 -0
  188. package/meetings/src/components/meeting-spaces/meeting-spaces.component.d.ts +27 -0
  189. package/meetings/src/material.module.d.ts +15 -0
  190. package/meetings/src/meetings.component.d.ts +29 -0
  191. package/meetings/src/meetings.module.d.ts +16 -0
  192. package/meetings/src/services/api.service.d.ts +18 -0
  193. package/meetings/src/services/live-meetings.service.d.ts +9 -0
  194. package/meetings/src/services/meeting-spaces.service.d.ts +16 -0
  195. package/meetings/src/types/live-meeting.d.ts +71 -0
  196. package/meetings/src/types/meeting-space.d.ts +52 -0
  197. package/meetings/src/utils/app-loader/app-loader.d.ts +6 -0
  198. package/package.json +33 -1
  199. package/shared/index.d.ts +5 -0
  200. package/shared/public-api.d.ts +3 -0
  201. package/shared/src/ui/material.module.d.ts +28 -0
  202. package/shared/src/ui/shared.module.d.ts +10 -0
  203. package/{user-device-manage/src/shared/tk-page-section/page-section.component.d.ts → shared/src/ui/tk-page-section/tk-page-section.component.d.ts} +1 -1
  204. package/shared/src/ui/tk-page-section-row/tk-page-section-row.component.d.ts +6 -0
  205. package/shared/src/ui/ui.module.d.ts +11 -0
  206. package/user-creation/src/utils/device-default-prefix.d.ts +7 -2
  207. package/user-creation/src/utils/device-name-dynamic-tokens.d.ts +1 -0
  208. package/user-creation/src/utils/parse-device-name-rule.d.ts +1 -0
  209. package/user-creation/src/widgets/user-creation-wizard/components/user-details-step/user-details-step.component.d.ts +2 -0
  210. package/user-device-manage/public-api.d.ts +3 -0
  211. package/user-device-manage/src/app.constants.d.ts +6 -0
  212. package/user-device-manage/src/associate-lines/associate-lines.component.d.ts +95 -0
  213. package/user-device-manage/src/classes/device.d.ts +15 -0
  214. package/user-device-manage/src/classes/deviceProfile.d.ts +5 -0
  215. package/user-device-manage/src/classes/simplified-user.d.ts +1 -1
  216. package/user-device-manage/src/device-associated-line/device-associated-line.component.d.ts +1 -0
  217. package/user-device-manage/src/device-manage-widget.component.d.ts +6 -1
  218. package/user-device-manage/src/device-settings/device-settings.component.d.ts +53 -0
  219. package/user-device-manage/src/line-key-config/line-key-config.component.d.ts +84 -0
  220. package/user-device-manage/src/services/device.service.d.ts +6 -1
  221. package/user-device-manage/src/services/user.service.d.ts +2 -1
  222. package/user-device-manage/src/user-device-manage.module.d.ts +12 -10
  223. package/user-manage/src/app.constants.d.ts +7 -0
  224. package/user-manage/src/classes/simplified-user.d.ts +17 -1
  225. package/user-manage/src/device-list/device-list.component.d.ts +2 -0
  226. package/user-manage/src/material.module.d.ts +3 -1
  227. package/user-manage/src/services/dcp-api.service.d.ts +21 -0
  228. package/user-manage/src/services/user.service.d.ts +19 -1
  229. package/user-manage/src/user-calling/user-calling.component.d.ts +3 -2
  230. package/user-manage/src/user-manage-widget.component.d.ts +14 -2
  231. package/user-manage/src/user-manage.module.d.ts +9 -7
  232. package/user-manage/src/user-summary/user-summary.component.d.ts +10 -0
  233. package/users-list/src/app.constants.d.ts +1 -0
  234. package/users-list/src/classes/simlified-user.d.ts +1 -1
  235. package/users-list/src/classes/user-list.d.ts +4 -0
  236. package/users-list/src/move-user-wizard/move-user-stepper/move-user-stepper.component.d.ts +3 -1
  237. package/users-list/src/move-user-wizard/move-user-wizard.component.d.ts +2 -1
  238. package/users-list/src/users-list.component.d.ts +6 -1
  239. package/workspaces/index.d.ts +5 -0
  240. package/workspaces/public-api.d.ts +2 -0
  241. package/workspaces/src/app.constants.d.ts +25 -0
  242. package/workspaces/src/components/workspace-confirm-dialog/workspace-confirm-dialog.component.d.ts +20 -0
  243. package/workspaces/src/components/workspace-detail/workspace-detail.component.d.ts +34 -0
  244. package/workspaces/src/components/workspace-device-detail/workspace-device-detail.component.d.ts +25 -0
  245. package/workspaces/src/components/workspaces-filters/workspaces-filters.component.d.ts +20 -0
  246. package/workspaces/src/components/workspaces-table/workspaces-table.component.d.ts +43 -0
  247. package/workspaces/src/material.module.d.ts +16 -0
  248. package/workspaces/src/services/api-webex.service.d.ts +6 -0
  249. package/workspaces/src/services/api.service.d.ts +18 -0
  250. package/workspaces/src/services/workspace-detail.service.d.ts +22 -0
  251. package/workspaces/src/services/workspaces-migration.service.d.ts +18 -0
  252. package/workspaces/src/services/workspaces.service.d.ts +11 -0
  253. package/workspaces/src/types/workspace.d.ts +439 -0
  254. package/workspaces/src/utils/app-loader/app-loader.d.ts +6 -0
  255. package/workspaces/src/utils/device-icon.d.ts +1 -0
  256. package/workspaces/src/utils/workspace-name.d.ts +1 -0
  257. package/workspaces/src/workspaces.component.d.ts +75 -0
  258. package/workspaces/src/workspaces.module.d.ts +17 -0
  259. package/contact-center/cc-readiness/components/card/card.component.d.ts +0 -6
  260. package/esm2020/contact-center/cc-readiness/components/card/card.component.mjs +0 -13
  261. package/esm2020/user-device-manage/src/shared/tk-page-section/page-section.component.mjs +0 -13
@@ -0,0 +1,679 @@
1
+ import * as i4 from '@angular/common';
2
+ import { CommonModule } from '@angular/common';
3
+ import * as i0 from '@angular/core';
4
+ import { NgModule, Component, ViewEncapsulation, Inject, Injectable, EventEmitter, Input, Output } from '@angular/core';
5
+ import * as i1$1 from '@angular/common/http';
6
+ import { HttpHeaders, HttpClientModule } from '@angular/common/http';
7
+ import * as i5 from '@angular/forms';
8
+ import { FormsModule } from '@angular/forms';
9
+ import * as i6 from '@angular/material/button';
10
+ import { MatButtonModule } from '@angular/material/button';
11
+ import * as i1 from '@angular/material/dialog';
12
+ import { MatDialogModule, MAT_DIALOG_DATA } from '@angular/material/dialog';
13
+ import * as i7 from '@angular/material/icon';
14
+ import { MatIconModule } from '@angular/material/icon';
15
+ import * as i8 from '@angular/material/menu';
16
+ import { MatMenuModule } from '@angular/material/menu';
17
+ import * as i1$2 from '@angular/material/progress-spinner';
18
+ import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
19
+ import * as i10 from '@angular/material/tooltip';
20
+ import { MatTooltipModule } from '@angular/material/tooltip';
21
+ import { map } from 'rxjs/operators';
22
+
23
+ class MaterialModule {
24
+ }
25
+ MaterialModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: MaterialModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
26
+ MaterialModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: MaterialModule, imports: [MatButtonModule,
27
+ MatDialogModule,
28
+ MatIconModule,
29
+ MatMenuModule,
30
+ MatProgressSpinnerModule,
31
+ MatTooltipModule], exports: [MatButtonModule,
32
+ MatDialogModule,
33
+ MatIconModule,
34
+ MatMenuModule,
35
+ MatProgressSpinnerModule,
36
+ MatTooltipModule] });
37
+ MaterialModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: MaterialModule, imports: [MatButtonModule,
38
+ MatDialogModule,
39
+ MatIconModule,
40
+ MatMenuModule,
41
+ MatProgressSpinnerModule,
42
+ MatTooltipModule, MatButtonModule,
43
+ MatDialogModule,
44
+ MatIconModule,
45
+ MatMenuModule,
46
+ MatProgressSpinnerModule,
47
+ MatTooltipModule] });
48
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: MaterialModule, decorators: [{
49
+ type: NgModule,
50
+ args: [{
51
+ imports: [
52
+ MatButtonModule,
53
+ MatDialogModule,
54
+ MatIconModule,
55
+ MatMenuModule,
56
+ MatProgressSpinnerModule,
57
+ MatTooltipModule,
58
+ ],
59
+ exports: [
60
+ MatButtonModule,
61
+ MatDialogModule,
62
+ MatIconModule,
63
+ MatMenuModule,
64
+ MatProgressSpinnerModule,
65
+ MatTooltipModule,
66
+ ]
67
+ }]
68
+ }] });
69
+
70
+ class LocationConfirmDialogComponent {
71
+ constructor(dialogRef, data) {
72
+ this.dialogRef = dialogRef;
73
+ this.data = data;
74
+ }
75
+ onClose(result) {
76
+ this.dialogRef.close(result);
77
+ }
78
+ }
79
+ LocationConfirmDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationConfirmDialogComponent, deps: [{ token: i1.MatDialogRef }, { token: MAT_DIALOG_DATA }], target: i0.ɵɵFactoryTarget.Component });
80
+ LocationConfirmDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: LocationConfirmDialogComponent, selector: "tk-location-confirm-dialog", ngImport: i0, template: "<div class=\"tk-location-confirm-dialog\" role=\"dialog\" aria-labelledby=\"tk-location-confirm-dialog-title\">\r\n <h3 id=\"tk-location-confirm-dialog-title\" class=\"tk-location-confirm-dialog__title\">{{ data.title }}</h3>\r\n <div mat-dialog-content class=\"tk-location-confirm-dialog__content\" [innerHTML]=\"data.message\"></div>\r\n <div mat-dialog-actions class=\"tk-location-confirm-dialog__actions\">\r\n <button type=\"button\" class=\"tk-location-confirm-dialog__button tk-location-confirm-dialog__button--cancel\" (click)=\"onClose(false)\">\r\n Cancel\r\n </button>\r\n <button type=\"button\" class=\"tk-location-confirm-dialog__button tk-location-confirm-dialog__button--confirm\" (click)=\"onClose(true)\">\r\n {{ data.confirmButtonText }}\r\n </button>\r\n </div>\r\n</div>\r\n", styles: [".tk-location-confirm-dialog-panel .mat-dialog-container{padding:24px;border-radius:8px;background:#fff;box-shadow:0 11px 15px -7px #0003,0 24px 38px 3px #00000024,0 9px 46px 8px #0000001f}.tk-location-confirm-dialog-backdrop{background:rgba(0,0,0,.32)}.tk-location-confirm-dialog{font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;width:400px;box-sizing:border-box;padding:0 0 16px}.tk-location-confirm-dialog__title{text-align:left;font-weight:600;font-size:16px;margin:0 0 20px}.tk-location-confirm-dialog__content{color:#000000b3;font-size:14px}.tk-location-confirm-dialog__content p{margin:0 0 12px}.tk-location-confirm-dialog__actions{display:flex;justify-content:flex-end;gap:12px;padding:0}.tk-location-confirm-dialog__button{height:32px;padding:0 16px;border-radius:50px;box-shadow:none;border:none;font-size:14px;font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;cursor:pointer}.tk-location-confirm-dialog__button--cancel{border:1px solid rgba(0,0,0,.5);color:#000;background:#fff}.tk-location-confirm-dialog__button--confirm{background:#000;color:#fff}\n"], dependencies: [{ kind: "directive", type: i1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { kind: "directive", type: i1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]", inputs: ["align"] }], encapsulation: i0.ViewEncapsulation.None });
81
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationConfirmDialogComponent, decorators: [{
82
+ type: Component,
83
+ args: [{ selector: 'tk-location-confirm-dialog', encapsulation: ViewEncapsulation.None, template: "<div class=\"tk-location-confirm-dialog\" role=\"dialog\" aria-labelledby=\"tk-location-confirm-dialog-title\">\r\n <h3 id=\"tk-location-confirm-dialog-title\" class=\"tk-location-confirm-dialog__title\">{{ data.title }}</h3>\r\n <div mat-dialog-content class=\"tk-location-confirm-dialog__content\" [innerHTML]=\"data.message\"></div>\r\n <div mat-dialog-actions class=\"tk-location-confirm-dialog__actions\">\r\n <button type=\"button\" class=\"tk-location-confirm-dialog__button tk-location-confirm-dialog__button--cancel\" (click)=\"onClose(false)\">\r\n Cancel\r\n </button>\r\n <button type=\"button\" class=\"tk-location-confirm-dialog__button tk-location-confirm-dialog__button--confirm\" (click)=\"onClose(true)\">\r\n {{ data.confirmButtonText }}\r\n </button>\r\n </div>\r\n</div>\r\n", styles: [".tk-location-confirm-dialog-panel .mat-dialog-container{padding:24px;border-radius:8px;background:#fff;box-shadow:0 11px 15px -7px #0003,0 24px 38px 3px #00000024,0 9px 46px 8px #0000001f}.tk-location-confirm-dialog-backdrop{background:rgba(0,0,0,.32)}.tk-location-confirm-dialog{font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;width:400px;box-sizing:border-box;padding:0 0 16px}.tk-location-confirm-dialog__title{text-align:left;font-weight:600;font-size:16px;margin:0 0 20px}.tk-location-confirm-dialog__content{color:#000000b3;font-size:14px}.tk-location-confirm-dialog__content p{margin:0 0 12px}.tk-location-confirm-dialog__actions{display:flex;justify-content:flex-end;gap:12px;padding:0}.tk-location-confirm-dialog__button{height:32px;padding:0 16px;border-radius:50px;box-shadow:none;border:none;font-size:14px;font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;cursor:pointer}.tk-location-confirm-dialog__button--cancel{border:1px solid rgba(0,0,0,.5);color:#000;background:#fff}.tk-location-confirm-dialog__button--confirm{background:#000;color:#fff}\n"] }]
84
+ }], ctorParameters: function () {
85
+ return [{ type: i1.MatDialogRef }, { type: undefined, decorators: [{
86
+ type: Inject,
87
+ args: [MAT_DIALOG_DATA]
88
+ }] }];
89
+ } });
90
+
91
+ class APIService {
92
+ constructor(httpClient) {
93
+ this.httpClient = httpClient;
94
+ }
95
+ fetch(url, params, cache) {
96
+ const headers = this.getHeaders(cache);
97
+ params = params || {};
98
+ return this.httpClient.get(this.apiUrl + url, { params: this.prepareEncodedParams(params), headers });
99
+ }
100
+ post(url, body, params = {}) {
101
+ body = body || null;
102
+ const headers = this.getHeaders();
103
+ return this.httpClient.post(this.apiUrl + url, body, { params: this.prepareEncodedParams(params), headers });
104
+ }
105
+ put(url, body = null, params = {}) {
106
+ const headers = this.getHeaders();
107
+ return this.httpClient.put(this.apiUrl + url, body, { headers, params: this.prepareEncodedParams(params) });
108
+ }
109
+ delete(url, params = {}) {
110
+ const headers = this.getHeaders();
111
+ return this.httpClient.delete(this.apiUrl + url, { headers, params: this.prepareEncodedParams(params) });
112
+ }
113
+ prepareEncodedParams(params) {
114
+ const result = {};
115
+ if (!params) {
116
+ return {};
117
+ }
118
+ for (const key of Object.keys(params)) {
119
+ if (params[key]) {
120
+ const stringParam = params[key].toString();
121
+ result[key] = stringParam.includes('+') ? encodeURIComponent(stringParam) : stringParam;
122
+ }
123
+ }
124
+ return result;
125
+ }
126
+ getHeaders(cache) {
127
+ let headers = new HttpHeaders();
128
+ if (cache) {
129
+ headers = headers.append('_Cache', 'true ');
130
+ }
131
+ const token = this.token || this.getParameterByName('token');
132
+ headers = headers.append('Authorization', 'Bearer ' + token);
133
+ return headers;
134
+ }
135
+ getParameterByName(name, url = window.location.href) {
136
+ name = name.replace(/[\[\]]/g, '\\$&');
137
+ var regex = new RegExp('[?&]' + name + '(=([^&#]*)|&|#|$)'), results = regex.exec(url);
138
+ if (!results)
139
+ return null;
140
+ if (!results[2])
141
+ return '';
142
+ return decodeURIComponent(results[2].replace(/\+/g, ' '));
143
+ }
144
+ }
145
+ APIService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: APIService, deps: [{ token: i1$1.HttpClient }], target: i0.ɵɵFactoryTarget.Injectable });
146
+ APIService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: APIService, providedIn: 'root' });
147
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: APIService, decorators: [{
148
+ type: Injectable,
149
+ args: [{
150
+ providedIn: 'root'
151
+ }]
152
+ }], ctorParameters: function () { return [{ type: i1$1.HttpClient }]; } });
153
+
154
+ const API = {
155
+ SITES_LOCATIONS: {
156
+ // Returns every site for the customer paired with its mapped Control Hub
157
+ // location (or null when the site hasn't been migrated yet) — this is the
158
+ // source of truth for siteId, superseding the old LOCATIONS.GET_ALL
159
+ // endpoint, which only listed already-mapped locations and exposed no siteId.
160
+ GET_ALL: "/api/webex/configuration/customers/:customerId/siteslocations",
161
+ },
162
+ SITE_MIGRATION: {
163
+ MIGRATE_SITE: "/api/migration/WEBEX/sites/:siteId/migrate",
164
+ BATCH_STATUS: "/api/migration/webex/customer/:customerId/batchesstatus",
165
+ // Pre-existing migration batches for the customer, matched to a site by
166
+ // siteId. Reachable through the same exHost/webex gateway as everything
167
+ // else in this service — no separate host needed.
168
+ GET_BATCH_SITES: "/api/e2emigration/batch/:customerId/Sites",
169
+ },
170
+ };
171
+
172
+ function toLocationAddress(raw) {
173
+ return {
174
+ address1: (raw === null || raw === void 0 ? void 0 : raw.address1) || '',
175
+ address2: (raw === null || raw === void 0 ? void 0 : raw.address2) || '',
176
+ city: (raw === null || raw === void 0 ? void 0 : raw.city) || '',
177
+ state: (raw === null || raw === void 0 ? void 0 : raw.state) || '',
178
+ postalCode: (raw === null || raw === void 0 ? void 0 : raw.postalCode) || '',
179
+ country: (raw === null || raw === void 0 ? void 0 : raw.country) || '',
180
+ countryName: (raw === null || raw === void 0 ? void 0 : raw.countryName) || (raw === null || raw === void 0 ? void 0 : raw.country) || '',
181
+ };
182
+ }
183
+ function toLocation(raw) {
184
+ var _a;
185
+ return {
186
+ id: String((_a = raw === null || raw === void 0 ? void 0 : raw.id) !== null && _a !== void 0 ? _a : ''),
187
+ name: (raw === null || raw === void 0 ? void 0 : raw.name) || '',
188
+ timeZone: (raw === null || raw === void 0 ? void 0 : raw.timeZone) || '',
189
+ address: toLocationAddress(raw === null || raw === void 0 ? void 0 : raw.address),
190
+ // Every location returned by this endpoint is a Webex Control Hub location.
191
+ provisioningType: (raw === null || raw === void 0 ? void 0 : raw.provisioningType) || 'WEBEX',
192
+ hasPendingActions: !!(raw === null || raw === void 0 ? void 0 : raw.hasPendingActions),
193
+ };
194
+ }
195
+ function toSite(raw) {
196
+ return {
197
+ id: Number(raw === null || raw === void 0 ? void 0 : raw.id),
198
+ name: (raw === null || raw === void 0 ? void 0 : raw.name) || '',
199
+ };
200
+ }
201
+ function toSiteLocation(raw) {
202
+ return {
203
+ site: toSite(raw === null || raw === void 0 ? void 0 : raw.site),
204
+ location: (raw === null || raw === void 0 ? void 0 : raw.location) ? toLocation(raw.location) : null,
205
+ };
206
+ }
207
+ class LocationsService {
208
+ constructor(apiService) {
209
+ this.apiService = apiService;
210
+ }
211
+ fetchSiteLocations(customerId) {
212
+ const url = API.SITES_LOCATIONS.GET_ALL.replace(':customerId', String(customerId));
213
+ return this.apiService.fetch(url).pipe(map((response) => (Array.isArray(response) ? response : []).map(toSiteLocation)));
214
+ }
215
+ migrateSite(siteId, batchId) {
216
+ const url = API.SITE_MIGRATION.MIGRATE_SITE.replace(':siteId', String(siteId));
217
+ return this.apiService.post(url, {}, batchId != null ? { batchId } : {});
218
+ }
219
+ getBatchSites(customerId) {
220
+ const url = API.SITE_MIGRATION.GET_BATCH_SITES.replace(':customerId', String(customerId));
221
+ return this.apiService.fetch(url).pipe(map((response) => (Array.isArray(response) ? response : [])));
222
+ }
223
+ getMigrationBatchStatuses(customerId, batchIds) {
224
+ const url = API.SITE_MIGRATION.BATCH_STATUS.replace(':customerId', String(customerId));
225
+ return this.apiService.post(url, batchIds);
226
+ }
227
+ }
228
+ LocationsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsService, deps: [{ token: APIService }], target: i0.ɵɵFactoryTarget.Injectable });
229
+ LocationsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsService, providedIn: 'root' });
230
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsService, decorators: [{
231
+ type: Injectable,
232
+ args: [{
233
+ providedIn: 'root'
234
+ }]
235
+ }], ctorParameters: function () { return [{ type: APIService }]; } });
236
+
237
+ class AppLoaderComponent {
238
+ constructor() {
239
+ }
240
+ }
241
+ AppLoaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppLoaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
242
+ AppLoaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: AppLoaderComponent, selector: "app-loader", ngImport: i0, template: "<div class=\"overlay\">\r\n <mat-progress-spinner\r\n class=\"page-spinner\"\r\n mode=\"indeterminate\"\r\n [diameter]=\"70\"\r\n strokeWidth=\"3\"></mat-progress-spinner>\r\n</div>\r\n", styles: [".overlay{position:fixed;width:100%;height:100%;inset:0;background-color:#fff3;z-index:200}.mat-progress-spinner circle,.mat-spinner circle{stroke:#000!important}\n"], dependencies: [{ kind: "component", type: i1$2.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "diameter", "strokeWidth", "mode", "value"], exportAs: ["matProgressSpinner"] }], encapsulation: i0.ViewEncapsulation.None });
243
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppLoaderComponent, decorators: [{
244
+ type: Component,
245
+ args: [{ selector: 'app-loader', encapsulation: ViewEncapsulation.None, template: "<div class=\"overlay\">\r\n <mat-progress-spinner\r\n class=\"page-spinner\"\r\n mode=\"indeterminate\"\r\n [diameter]=\"70\"\r\n strokeWidth=\"3\"></mat-progress-spinner>\r\n</div>\r\n", styles: [".overlay{position:fixed;width:100%;height:100%;inset:0;background-color:#fff3;z-index:200}.mat-progress-spinner circle,.mat-spinner circle{stroke:#000!important}\n"] }]
246
+ }], ctorParameters: function () { return []; } });
247
+
248
+ const MIGRATION_POLL_INTERVAL_MS = 10000;
249
+ const PAGE_SIZE_OPTIONS = [10, 25, 50];
250
+ class LocationsComponent {
251
+ constructor(apiService, locationsService, dialog) {
252
+ this.apiService = apiService;
253
+ this.locationsService = locationsService;
254
+ this.dialog = dialog;
255
+ this.openLocation = new EventEmitter();
256
+ this.editLocation = new EventEmitter();
257
+ this.removeLocation = new EventEmitter();
258
+ this.addLocation = new EventEmitter();
259
+ this.importLocations = new EventEmitter();
260
+ // Every site for the customer, each paired with its mapped Control Hub
261
+ // location or null — the siteslocations API returns the full, unpaged list,
262
+ // so search/filter/sort/pagination below all run client-side over this.
263
+ this.siteLocations = [];
264
+ this.isLoading = false;
265
+ this.searchTerm = '';
266
+ this.sortDirection = 'asc';
267
+ this.isBannerDismissed = false;
268
+ this.pageSizeOptions = PAGE_SIZE_OPTIONS;
269
+ this.pageIndex = 0;
270
+ this.pageSize = PAGE_SIZE_OPTIONS[0];
271
+ this.isFilterPanelOpen = false;
272
+ this.filters = {
273
+ country: '',
274
+ pendingActions: '',
275
+ status: '',
276
+ };
277
+ this.countryDisplayNames = typeof Intl !== 'undefined' && 'DisplayNames' in Intl
278
+ ? new Intl.DisplayNames(['en'], { type: 'region' })
279
+ : null;
280
+ this.migrationIntervals = new Map();
281
+ this.batchInfoBySiteId = new Map();
282
+ // Same icon set as users-list's "Provisioning Type" column (assets/icons/webex.svg,
283
+ // local_24.svg, di_cloud_24.svg).
284
+ this.provisioningTypeIcons = {
285
+ WEBEX: { src: 'assets/icons/webex.svg', tooltip: 'Webex Calling' },
286
+ UCM: { src: 'assets/icons/local_24.svg', tooltip: 'UCM' },
287
+ DI: { src: 'assets/icons/di_cloud_24.svg', tooltip: 'Webex Calling DI' },
288
+ };
289
+ }
290
+ ngOnInit() {
291
+ this.apiService.token = this.token;
292
+ this.apiService.apiUrl = this.exHost + '/webex';
293
+ this.loadSiteLocations();
294
+ this.loadBatchSites();
295
+ }
296
+ ngOnDestroy() {
297
+ this.migrationIntervals.forEach(interval => clearInterval(interval));
298
+ this.migrationIntervals.clear();
299
+ }
300
+ loadSiteLocations() {
301
+ this.isLoading = true;
302
+ this.locationsService.fetchSiteLocations(this.customerId).subscribe({
303
+ next: (siteLocations) => {
304
+ this.siteLocations = this.applyBatchIds(siteLocations);
305
+ this.isLoading = false;
306
+ },
307
+ error: () => {
308
+ this.isLoading = false;
309
+ },
310
+ });
311
+ }
312
+ // Runs independently of loadSiteLocations() — whichever resolves second
313
+ // re-applies the merge, so batchId ends up set regardless of load order.
314
+ loadBatchSites() {
315
+ this.locationsService.getBatchSites(this.customerId).subscribe({
316
+ next: (batches) => {
317
+ this.batchInfoBySiteId = new Map(batches.map(batch => [batch.siteId, { batchId: batch.id, status: batch.status }]));
318
+ this.siteLocations = this.applyBatchIds(this.siteLocations);
319
+ },
320
+ });
321
+ }
322
+ applyBatchIds(rows) {
323
+ return rows.map(row => {
324
+ var _a;
325
+ const info = this.batchInfoBySiteId.get(row.site.id);
326
+ return Object.assign(Object.assign({}, row), { batchId: info === null || info === void 0 ? void 0 : info.batchId, batchStatus: (_a = info === null || info === void 0 ? void 0 : info.status) !== null && _a !== void 0 ? _a : null });
327
+ });
328
+ }
329
+ get pendingLocations() {
330
+ return this.siteLocations.filter(row => { var _a; return !!((_a = row.location) === null || _a === void 0 ? void 0 : _a.hasPendingActions); });
331
+ }
332
+ get showPendingBanner() {
333
+ return !this.isBannerDismissed && this.pendingLocations.length > 0;
334
+ }
335
+ get countries() {
336
+ return Array.from(new Set(this.siteLocations.map(row => this.countryLabel(row)).filter(Boolean))).sort();
337
+ }
338
+ get statuses() {
339
+ return Array.from(new Set(this.siteLocations.map(row => row.batchStatus).filter((v) => !!v))).sort();
340
+ }
341
+ get filteredRows() {
342
+ const term = this.searchTerm.trim().toLowerCase();
343
+ const filtered = this.siteLocations.filter(row => {
344
+ var _a, _b, _c, _d, _e;
345
+ return (!term ||
346
+ this.rowName(row).toLowerCase().includes(term) ||
347
+ this.addressLine(row).toLowerCase().includes(term) ||
348
+ (((_b = (_a = row.location) === null || _a === void 0 ? void 0 : _a.address) === null || _b === void 0 ? void 0 : _b.city) || '').toLowerCase().includes(term) ||
349
+ (((_d = (_c = row.location) === null || _c === void 0 ? void 0 : _c.address) === null || _d === void 0 ? void 0 : _d.state) || '').toLowerCase().includes(term) ||
350
+ this.countryLabel(row).toLowerCase().includes(term)) &&
351
+ (!this.filters.country || this.countryLabel(row) === this.filters.country) &&
352
+ (!this.filters.pendingActions || String(!!((_e = row.location) === null || _e === void 0 ? void 0 : _e.hasPendingActions)) === this.filters.pendingActions) &&
353
+ (!this.filters.status || row.batchStatus === this.filters.status);
354
+ });
355
+ return filtered.sort((a, b) => {
356
+ const comparison = this.rowName(a).localeCompare(this.rowName(b));
357
+ return this.sortDirection === 'asc' ? comparison : -comparison;
358
+ });
359
+ }
360
+ get pagedRows() {
361
+ const start = this.pageIndex * this.pageSize;
362
+ return this.filteredRows.slice(start, start + this.pageSize);
363
+ }
364
+ get totalElements() {
365
+ return this.filteredRows.length;
366
+ }
367
+ get pageRangeLabel() {
368
+ if (!this.totalElements) {
369
+ return '0 of 0';
370
+ }
371
+ const start = this.pageIndex * this.pageSize + 1;
372
+ const end = Math.min(this.totalElements, start + this.pagedRows.length - 1);
373
+ return `${start} – ${end} of ${this.totalElements}`;
374
+ }
375
+ get hasPreviousPage() {
376
+ return this.pageIndex > 0;
377
+ }
378
+ get hasNextPage() {
379
+ return (this.pageIndex + 1) * this.pageSize < this.totalElements;
380
+ }
381
+ rowName(row) {
382
+ return row.site.name;
383
+ }
384
+ // Categorizes the free-text batch status into the three states the status
385
+ // dot can show — matched by keyword since the backend uses inconsistent
386
+ // casing/wording ("Finished Successfully", "COMPLETED", "collecting with
387
+ // fixes", "New", "FAILED", ...).
388
+ batchStatusCategory(row) {
389
+ const value = (row.batchStatus || '').toLowerCase();
390
+ if (!value) {
391
+ return '';
392
+ }
393
+ if (value.includes('fail')) {
394
+ return 'failed';
395
+ }
396
+ if (value.includes('complet') || value.includes('finished') || value.includes('success')) {
397
+ return 'success';
398
+ }
399
+ return 'in-progress';
400
+ }
401
+ isSuccessStatus(row) {
402
+ return this.batchStatusCategory(row) === 'success';
403
+ }
404
+ isInProgressStatus(row) {
405
+ return this.batchStatusCategory(row) === 'in-progress';
406
+ }
407
+ isFailedStatus(row) {
408
+ return this.batchStatusCategory(row) === 'failed';
409
+ }
410
+ addressLine(row) {
411
+ if (!row.location) {
412
+ return '';
413
+ }
414
+ return [row.location.address.address1, row.location.address.address2, row.location.address.city]
415
+ .filter(Boolean)
416
+ .join(' - ');
417
+ }
418
+ countryLabel(row) {
419
+ var _a;
420
+ if (!row.location) {
421
+ return '';
422
+ }
423
+ const { countryName, country } = row.location.address;
424
+ if (countryName) {
425
+ return countryName;
426
+ }
427
+ if (!country) {
428
+ return '';
429
+ }
430
+ return ((_a = this.countryDisplayNames) === null || _a === void 0 ? void 0 : _a.of(country)) || country;
431
+ }
432
+ provisioningTypeIcon(row) {
433
+ if (!row.location) {
434
+ return null;
435
+ }
436
+ return this.provisioningTypeIcons[row.location.provisioningType] || null;
437
+ }
438
+ onSearchInputChange(event) {
439
+ this.searchTerm = event.target.value;
440
+ this.pageIndex = 0;
441
+ }
442
+ toggleNameSort() {
443
+ this.sortDirection = this.sortDirection === 'asc' ? 'desc' : 'asc';
444
+ }
445
+ dismissBanner() {
446
+ this.isBannerDismissed = true;
447
+ }
448
+ toggleFilterPanel() {
449
+ this.isFilterPanelOpen = !this.isFilterPanelOpen;
450
+ }
451
+ closeFilterPanel() {
452
+ this.isFilterPanelOpen = false;
453
+ }
454
+ onFilterChange() {
455
+ this.pageIndex = 0;
456
+ }
457
+ clearFilters() {
458
+ this.filters = { country: '', pendingActions: '', status: '' };
459
+ this.pageIndex = 0;
460
+ }
461
+ onPageSizeChange(event) {
462
+ this.pageSize = Number(event.target.value);
463
+ this.pageIndex = 0;
464
+ }
465
+ goToPreviousPage() {
466
+ if (this.hasPreviousPage) {
467
+ this.pageIndex--;
468
+ }
469
+ }
470
+ goToNextPage() {
471
+ if (this.hasNextPage) {
472
+ this.pageIndex++;
473
+ }
474
+ }
475
+ onOpenLocation(row) {
476
+ if (row.location) {
477
+ this.openLocation.emit(row.location.id);
478
+ }
479
+ }
480
+ onEditLocation(row) {
481
+ if (row.location) {
482
+ this.editLocation.emit(row.location.id);
483
+ }
484
+ }
485
+ onRemoveLocation(row) {
486
+ if (row.location) {
487
+ this.removeLocation.emit(row.location.id);
488
+ }
489
+ }
490
+ canMigrateSite(row) {
491
+ return row.migrationStatus !== 'IN_PROGRESS';
492
+ }
493
+ onMigrateSite(row) {
494
+ const dialogRef = this.dialog.open(LocationConfirmDialogComponent, {
495
+ panelClass: 'tk-location-confirm-dialog-panel',
496
+ backdropClass: 'tk-location-confirm-dialog-backdrop',
497
+ data: {
498
+ title: `Migrate ${row.site.name}?`,
499
+ message: `<p>Are you sure you want to migrate <em>${row.site.name}</em> site?</p>`,
500
+ confirmButtonText: 'Yes, migrate',
501
+ },
502
+ });
503
+ dialogRef.afterClosed().subscribe(confirmed => {
504
+ if (confirmed) {
505
+ this.migrateSite(row);
506
+ }
507
+ });
508
+ }
509
+ migrateSite(row) {
510
+ const siteId = row.site.id;
511
+ row.migrationStatus = 'IN_PROGRESS';
512
+ this.locationsService.migrateSite(siteId, row.batchId).subscribe({
513
+ next: (batchId) => {
514
+ if (batchId) {
515
+ this.pollMigrationStatus(siteId, batchId);
516
+ }
517
+ else {
518
+ this.onMigrationComplete(siteId);
519
+ }
520
+ },
521
+ error: () => {
522
+ this.setMigrationStatus(siteId, 'FAILED');
523
+ },
524
+ });
525
+ }
526
+ pollMigrationStatus(siteId, batchId) {
527
+ this.clearMigrationInterval(siteId);
528
+ const poll = () => {
529
+ this.locationsService.getMigrationBatchStatuses(this.customerId, [batchId]).subscribe({
530
+ next: (statuses) => {
531
+ const status = statuses.find(item => item.id === batchId);
532
+ // The batch stops being returned once it's done processing, so its
533
+ // absence here means completion — only its presence with an
534
+ // in-progress status means we should keep polling.
535
+ if (status && status.status === 'In Progress') {
536
+ return;
537
+ }
538
+ this.clearMigrationInterval(siteId);
539
+ if (!status || status.status === 'Completed') {
540
+ this.onMigrationComplete(siteId);
541
+ }
542
+ else {
543
+ this.setMigrationStatus(siteId, 'FAILED');
544
+ }
545
+ },
546
+ error: () => {
547
+ this.clearMigrationInterval(siteId);
548
+ this.setMigrationStatus(siteId, 'FAILED');
549
+ },
550
+ });
551
+ };
552
+ poll();
553
+ this.migrationIntervals.set(siteId, setInterval(poll, MIGRATION_POLL_INTERVAL_MS));
554
+ }
555
+ // Looks the row up by siteId (rather than closing over a row reference) so
556
+ // status updates still land on whatever object is currently in
557
+ // siteLocations, even after loadSiteLocations()/mergeSiteLocations() below
558
+ // have replaced the array with freshly-fetched row objects.
559
+ setMigrationStatus(siteId, status) {
560
+ const row = this.siteLocations.find(item => item.site.id === siteId);
561
+ if (row) {
562
+ row.migrationStatus = status;
563
+ }
564
+ }
565
+ // The migrate/batch-status APIs don't return the newly created location's
566
+ // details, so re-fetch to pick up its mapping, address, timezone, etc.
567
+ onMigrationComplete(siteId) {
568
+ this.setMigrationStatus(siteId, 'COMPLETED');
569
+ this.locationsService.fetchSiteLocations(this.customerId).subscribe({
570
+ next: (fresh) => this.mergeSiteLocations(fresh),
571
+ });
572
+ }
573
+ // Preserves the IN_PROGRESS status of any other site still migrating so a
574
+ // concurrent poll's next tick doesn't land on a row that briefly lost it.
575
+ mergeSiteLocations(fresh) {
576
+ const inProgressSiteIds = new Set(this.siteLocations.filter(row => row.migrationStatus === 'IN_PROGRESS').map(row => row.site.id));
577
+ this.siteLocations = this.applyBatchIds(fresh).map(row => inProgressSiteIds.has(row.site.id) && !row.location
578
+ ? Object.assign(Object.assign({}, row), { migrationStatus: 'IN_PROGRESS' }) : row);
579
+ }
580
+ clearMigrationInterval(siteId) {
581
+ const interval = this.migrationIntervals.get(siteId);
582
+ if (interval) {
583
+ clearInterval(interval);
584
+ this.migrationIntervals.delete(siteId);
585
+ }
586
+ }
587
+ onAddLocation() {
588
+ this.addLocation.emit();
589
+ }
590
+ onImportLocations() {
591
+ this.importLocations.emit();
592
+ }
593
+ exportLocations() {
594
+ const rows = this.filteredRows.map(row => [
595
+ row.site.name,
596
+ this.addressLine(row),
597
+ this.countryLabel(row),
598
+ row.batchStatus || 'Not migrated',
599
+ ]);
600
+ const csvLines = [
601
+ ['Location Name', 'Address', 'Country/Region', 'Status'],
602
+ ...rows,
603
+ ].map(row => row.map(cell => `"${String(cell).replace(/"/g, '""')}"`).join(','));
604
+ const blob = new Blob([csvLines.join('\n')], { type: 'text/csv;charset=utf-8;' });
605
+ const url = URL.createObjectURL(blob);
606
+ const link = document.createElement('a');
607
+ link.href = url;
608
+ link.download = 'locations.csv';
609
+ link.click();
610
+ URL.revokeObjectURL(url);
611
+ }
612
+ }
613
+ LocationsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsComponent, deps: [{ token: APIService }, { token: LocationsService }, { token: i1.MatDialog }], target: i0.ɵɵFactoryTarget.Component });
614
+ LocationsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: LocationsComponent, selector: "tk-locations", inputs: { exHost: "exHost", token: "token", customerId: "customerId" }, outputs: { openLocation: "openLocation", editLocation: "editLocation", removeLocation: "removeLocation", addLocation: "addLocation", importLocations: "importLocations" }, ngImport: i0, template: "<div class=\"tk-locations\">\r\n <app-loader *ngIf=\"isLoading\"></app-loader>\r\n\r\n <div class=\"tk-locations__view-toggle\">\r\n <button type=\"button\" class=\"tk-locations__view-button tk-locations__view-button--active\">\r\n <mat-icon class=\"tk-locations__view-icon\">menu</mat-icon>\r\n List\r\n </button>\r\n <button type=\"button\" class=\"tk-locations__view-button\" disabled title=\"Map view coming soon\">\r\n <mat-icon class=\"tk-locations__view-icon\">place</mat-icon>\r\n Map\r\n </button>\r\n </div>\r\n\r\n <div class=\"tk-locations__banner\" *ngIf=\"showPendingBanner\">\r\n <mat-icon class=\"tk-locations__banner-icon\">warning</mat-icon>\r\n <span class=\"tk-locations__banner-text\">\r\n View location(s) with pending action items to resume your calling service in {{ pendingLocations.length }} or more locations.\r\n </span>\r\n <button type=\"button\" class=\"tk-locations__banner-close\" aria-label=\"Dismiss\" (click)=\"dismissBanner()\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n\r\n <div class=\"tk-locations__toolbar\">\r\n <div style=\"position: relative; width: fit-content; min-width: 200px\">\r\n <input\r\n [value]=\"searchTerm\"\r\n class=\"blue-input\"\r\n (input)=\"onSearchInputChange($event)\"\r\n type=\"text\"\r\n placeholder=\"Search by name, city, state, country\"\r\n style=\"\r\n width: 100%;\r\n height: 34px;\r\n border-radius: 0.5rem;\r\n font-size: 16px;\r\n padding: 6px 12px 6px 44px;\r\n border: 1px solid #00000080;\r\n background: #fff;\r\n color: #222;\r\n outline: none;\r\n box-sizing: border-box;\r\n min-width: 280px;\r\n \"\r\n />\r\n <span\r\n style=\"\r\n position: absolute;\r\n left: 12px;\r\n top: 50%;\r\n transform: translateY(-50%);\r\n color: #757575;\r\n font-size: 18px;\r\n font-weight: normal;\r\n pointer-events: none;\r\n \"\r\n >\r\n <i\r\n class=\"material-icons\"\r\n style=\"font-size: 18px; font-weight: normal\"\r\n >search</i\r\n >\r\n </span>\r\n </div>\r\n\r\n <button type=\"button\" class=\"tk-locations__filter-button\" (click)=\"toggleFilterPanel()\">\r\n <img class=\"tk-locations__filter-icon\" src=\"assets/icons/filter-regular.svg\" alt=\"filter_list\" title=\"filter_list\">\r\n Filter\r\n </button>\r\n\r\n <span class=\"tk-locations__count\">{{ totalElements }} locations</span>\r\n\r\n <button type=\"button\" class=\"tk-locations__download-button\" aria-label=\"Download locations\" title=\"Download locations\" (click)=\"exportLocations()\">\r\n <mat-icon>file_download</mat-icon>\r\n </button>\r\n\r\n <button type=\"button\" class=\"tk-locations__manage-button\" [matMenuTriggerFor]=\"manageMenu\">\r\n Manage locations\r\n <mat-icon class=\"tk-locations__manage-chevron\">expand_more</mat-icon>\r\n </button>\r\n <mat-menu #manageMenu=\"matMenu\" xPosition=\"before\">\r\n <button mat-menu-item type=\"button\" (click)=\"onAddLocation()\">Add location</button>\r\n <button mat-menu-item type=\"button\" (click)=\"onImportLocations()\">Import locations</button>\r\n </mat-menu>\r\n </div>\r\n\r\n <table class=\"tk-locations__table\">\r\n <thead>\r\n <tr>\r\n <th (click)=\"toggleNameSort()\">\r\n Location Name\r\n <mat-icon class=\"tk-locations__sort-icon\">{{ sortDirection === 'asc' ? 'arrow_upward' : 'arrow_downward' }}</mat-icon>\r\n </th>\r\n <th>Address</th>\r\n <th>Country/Region</th>\r\n <th>Status</th>\r\n <th>Provisioning Type</th>\r\n <th class=\"tk-locations__actions-col\"></th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <tr *ngFor=\"let row of pagedRows\" (click)=\"onOpenLocation(row)\">\r\n <td class=\"tk-locations__name-cell\">\r\n <a href=\"javascript:void(0)\" class=\"tk-locations__name-link\" (click)=\"$event.stopPropagation(); onOpenLocation(row)\">{{ row.site.name }}</a>\r\n </td>\r\n <td>{{ addressLine(row) || '\u2014' }}</td>\r\n <td>{{ countryLabel(row) || '\u2014' }}</td>\r\n <td>\r\n <span class=\"tk-locations__status\" *ngIf=\"row.batchStatus; else noStatus\">\r\n <span\r\n class=\"tk-locations__status-dot\"\r\n [class.tk-locations__status-dot--success]=\"isSuccessStatus(row)\"\r\n [class.tk-locations__status-dot--in-progress]=\"isInProgressStatus(row)\"\r\n [class.tk-locations__status-dot--failed]=\"isFailedStatus(row)\"></span>\r\n {{ row.batchStatus }}\r\n </span>\r\n <ng-template #noStatus>\u2014</ng-template>\r\n </td>\r\n <td>\r\n <span class=\"tk-locations__icon-wrapper\" *ngIf=\"provisioningTypeIcon(row) as pt; else noProvisioningType\">\r\n <img [src]=\"pt.src\" [matTooltip]=\"pt.tooltip\" matTooltipPosition=\"right\" width=\"20\" alt=\"\">\r\n </span>\r\n <ng-template #noProvisioningType>\u2014</ng-template>\r\n </td>\r\n <td class=\"tk-locations__actions-col\">\r\n <mat-progress-spinner\r\n *ngIf=\"row.migrationStatus === 'IN_PROGRESS'\"\r\n class=\"tk-locations__row-action-spinner\"\r\n [diameter]=\"20\"\r\n strokeWidth=\"2\"\r\n mode=\"indeterminate\"\r\n matTooltip=\"Migrating site\u2026\">\r\n </mat-progress-spinner>\r\n <button\r\n *ngIf=\"row.migrationStatus !== 'IN_PROGRESS'\"\r\n mat-icon-button\r\n class=\"tk-locations__row-action-button\"\r\n [matMenuTriggerFor]=\"rowMenu\"\r\n (click)=\"$event.stopPropagation()\"\r\n aria-label=\"Open location actions\">\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n <mat-menu #rowMenu=\"matMenu\" yPosition=\"below\">\r\n <button *ngIf=\"row.location\" mat-menu-item type=\"button\" (click)=\"onOpenLocation(row)\">View details</button>\r\n <button *ngIf=\"row.location\" mat-menu-item type=\"button\" (click)=\"onEditLocation(row)\">Edit location</button>\r\n <button\r\n *ngIf=\"canMigrateSite(row)\"\r\n mat-menu-item\r\n type=\"button\"\r\n (click)=\"onMigrateSite(row)\">Migrate site</button>\r\n <button *ngIf=\"row.location\" mat-menu-item type=\"button\" (click)=\"onRemoveLocation(row)\">Remove location</button>\r\n </mat-menu>\r\n </td>\r\n </tr>\r\n <tr *ngIf=\"!pagedRows.length\">\r\n <td colspan=\"6\" class=\"tk-locations__empty\">No locations match your search.</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n\r\n <div class=\"tk-locations__footer\">\r\n <div class=\"tk-locations__rows-per-page\">\r\n <label for=\"tk-locations-page-size\">Rows per page:</label>\r\n <select id=\"tk-locations-page-size\" class=\"tk-locations__rows-per-page-select\" [ngModel]=\"pageSize\" (change)=\"onPageSizeChange($event)\">\r\n <option *ngFor=\"let size of pageSizeOptions\" [value]=\"size\">{{ size }}</option>\r\n </select>\r\n </div>\r\n <span class=\"tk-locations__footer-text\">{{ pageRangeLabel }}</span>\r\n <div class=\"tk-locations__pagination\">\r\n <button type=\"button\" class=\"tk-locations__pagination-button\" [disabled]=\"!hasPreviousPage\" (click)=\"goToPreviousPage()\" aria-label=\"Previous page\">\r\n <mat-icon>chevron_left</mat-icon>\r\n </button>\r\n <button type=\"button\" class=\"tk-locations__pagination-button\" [disabled]=\"!hasNextPage\" (click)=\"goToNextPage()\" aria-label=\"Next page\">\r\n <mat-icon>chevron_right</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n\r\n <div\r\n class=\"tk-locations__filter-backdrop\"\r\n *ngIf=\"isFilterPanelOpen\"\r\n (click)=\"closeFilterPanel()\">\r\n </div>\r\n\r\n <aside class=\"tk-locations__filter-panel\" [class.tk-locations__filter-panel--open]=\"isFilterPanelOpen\">\r\n <div class=\"tk-locations__filter-panel-header\">\r\n <h3 class=\"tk-locations__filter-panel-title\">Filter locations</h3>\r\n <button\r\n type=\"button\"\r\n class=\"tk-locations__filter-panel-close\"\r\n aria-label=\"Close filter panel\"\r\n (click)=\"closeFilterPanel()\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-panel-body\">\r\n <div class=\"tk-locations__filter-field\">\r\n <label class=\"tk-locations__filter-label\" for=\"tk-locations-filter-status\">Status</label>\r\n <div class=\"tk-locations__filter-select-wrap\">\r\n <select id=\"tk-locations-filter-status\" class=\"tk-locations__filter-select\" [(ngModel)]=\"filters.status\" (change)=\"onFilterChange()\">\r\n <option value=\"\">All</option>\r\n <option *ngFor=\"let status of statuses\" [value]=\"status\">{{ status }}</option>\r\n </select>\r\n <mat-icon class=\"tk-locations__filter-select-icon\">expand_more</mat-icon>\r\n </div>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-field\">\r\n <label class=\"tk-locations__filter-label\" for=\"tk-locations-filter-country\">Country/Region</label>\r\n <div class=\"tk-locations__filter-select-wrap\">\r\n <select id=\"tk-locations-filter-country\" class=\"tk-locations__filter-select\" [(ngModel)]=\"filters.country\" (change)=\"onFilterChange()\">\r\n <option value=\"\">All countries</option>\r\n <option *ngFor=\"let country of countries\" [value]=\"country\">{{ country }}</option>\r\n </select>\r\n <mat-icon class=\"tk-locations__filter-select-icon\">expand_more</mat-icon>\r\n </div>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-field\">\r\n <label class=\"tk-locations__filter-label\" for=\"tk-locations-filter-pending\">Pending action items</label>\r\n <div class=\"tk-locations__filter-select-wrap\">\r\n <select id=\"tk-locations-filter-pending\" class=\"tk-locations__filter-select\" [(ngModel)]=\"filters.pendingActions\" (change)=\"onFilterChange()\">\r\n <option value=\"\">All</option>\r\n <option value=\"true\">Yes</option>\r\n <option value=\"false\">No</option>\r\n </select>\r\n <mat-icon class=\"tk-locations__filter-select-icon\">expand_more</mat-icon>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-panel-footer\">\r\n <button type=\"button\" class=\"tk-locations__filter-clear\" (click)=\"clearFilters()\">Clear all</button>\r\n <button type=\"button\" class=\"tk-locations__filter-done\" (click)=\"closeFilterPanel()\">Done</button>\r\n </div>\r\n </aside>\r\n</div>\r\n", styles: ["@import\"https://fonts.googleapis.com/css2?family=Inter:wght@300;400&display=swap\";.tk-locations{font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;color:#000000f2;padding-top:0}.tk-locations__view-toggle{display:flex;align-items:center;gap:.25rem;margin-bottom:1rem;width:-moz-fit-content;width:fit-content}.tk-locations__view-button{display:inline-flex;align-items:center;gap:.375rem;padding:.5rem .875rem;background:none;border:none;border-radius:6.25rem;font-family:inherit;font-size:1rem;font-weight:500;color:#000000b3;cursor:pointer}.tk-locations__view-button:hover:not(:disabled){background:rgba(0,0,0,.0705882353)}.tk-locations__view-button--active{background:#C1C1C1;color:#000000f2}.tk-locations__view-button--active:hover{background:rgba(0,0,0,.3019607843)}.tk-locations__view-button:disabled{cursor:default;opacity:.5}.tk-locations__view-button:disabled:hover{background:none}.tk-locations__view-icon{height:1.125rem;width:1.125rem;opacity:.6}.tk-locations__view-button--active .tk-locations__view-icon{opacity:1}.tk-locations__banner{display:flex;align-items:center;gap:.5rem;margin-bottom:1rem;padding:.75rem 1rem;background:#fdf1d6;border:1px solid #f0d9a6;border-radius:.5rem;color:#7a5b0a}.tk-locations__banner-icon{font-size:1.125rem;height:1.125rem;width:1.125rem;color:#b5860b;flex-shrink:0}.tk-locations__banner-text{flex:1;font-size:.8125rem}.tk-locations__banner-close{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;padding:0;color:#7a5b0a;cursor:pointer}.tk-locations__banner-close:hover{color:#000000f2}.tk-locations__toolbar{display:flex;align-items:center;gap:.75rem;margin:.5rem .5rem 1rem}.tk-locations__filter-button{display:inline-flex;align-items:center;gap:.375rem;height:34px;padding:.5rem .875rem;background:#fff;border:1px solid rgba(0,0,0,.5019607843);border-radius:.5rem;font-family:inherit;font-size:.8125rem;font-weight:500;color:#000000f2;cursor:pointer}.tk-locations__filter-button:hover{background:rgba(0,0,0,.03)}.tk-locations__filter-icon{font-size:1rem;height:1rem;width:1rem;opacity:.6}.tk-locations__count{font-size:.8125rem;color:#0009;white-space:nowrap}.tk-locations__download-button{display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;margin-left:auto;background:none;border:none;color:#0009;cursor:pointer}.tk-locations__download-button:hover{color:#000000f2}.tk-locations__manage-button{display:inline-flex;align-items:center;gap:.375rem;height:34px;padding:.5rem 1rem;background:#000;color:#fff;border:none;border-radius:6.25rem;font-family:inherit;font-size:.8125rem;font-weight:500;cursor:pointer}.tk-locations__manage-button:hover{background:#222}.tk-locations__manage-icon,.tk-locations__manage-chevron{font-size:1.125rem;height:1.125rem;width:1.125rem}.tk-locations__table{width:100%;border-collapse:collapse;font-family:Inter,sans-serif}.tk-locations__table th{height:39px;padding:.5rem 1.5rem .5rem .75rem;background-color:#ededed;text-align:start;font-size:.75rem;font-weight:500;color:#000000b3;word-break:break-all;max-inline-size:100%;cursor:pointer}.tk-locations__table th:hover{background-color:#dedede}.tk-locations__table td{height:49px;padding:.5rem 1.5rem .5rem .75rem;box-shadow:inset 0 -1px #0003;background-color:#fff;text-align:start;font-size:.875rem;color:#000000f2;word-break:break-all;cursor:pointer;transition:background-color .2s,box-shadow .2s}.tk-locations__table tbody tr:hover td{background:#ededed}.tk-locations__sort-icon{font-size:1rem;height:1rem;width:1rem;vertical-align:middle;margin-left:.25rem;color:#00000080}.tk-locations__name-cell{min-width:0}.tk-locations__name-link{color:#000000de;font-weight:500;text-decoration:none}.tk-locations__actions-col{width:3rem;text-align:center!important;position:relative}.tk-locations__row-action-spinner{display:inline-block;margin:0 auto}.tk-locations__icon-wrapper{display:inline-flex;align-items:center}.tk-locations__status{display:inline-flex;align-items:center;gap:.375rem;white-space:nowrap}.tk-locations__status-dot{width:.5rem;height:.5rem;border-radius:50%;background:rgba(0,0,0,.3);flex-shrink:0}.tk-locations__status-dot--success{background:#1d805f}.tk-locations__status-dot--in-progress{background:#639fff}.tk-locations__status-dot--failed{background:#c73636}.tk-locations__row-action-button{color:#0009}.tk-locations__row-action-button:hover{color:#000000f2}.tk-locations__empty{padding:1.5rem;text-align:center;color:#0009}.tk-locations__footer{display:flex;align-items:center;justify-content:flex-end;gap:1.5rem;margin-top:1rem;font-size:.8125rem;color:#0009}.tk-locations__rows-per-page{display:flex;align-items:center;gap:.5rem}.tk-locations__rows-per-page-select{padding:.25rem .5rem;background:#fff;border:1px solid rgba(0,0,0,.12);border-radius:6px;font-family:inherit;font-size:.8125rem;color:#000000f2;cursor:pointer}.tk-locations__pagination{display:flex;align-items:center;gap:.25rem}.tk-locations__pagination-button{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;padding:0;color:#0009;cursor:pointer}.tk-locations__pagination-button:hover:not(:disabled){color:#000000f2}.tk-locations__pagination-button:disabled{color:#00000040;cursor:default}.tk-locations__filter-backdrop{position:fixed;inset:0;z-index:1000;background-color:oklch(18% .01 260/20%)}.tk-locations__filter-panel{position:fixed;top:0;right:0;bottom:0;z-index:1001;display:flex;flex-direction:column;width:22rem;max-width:100vw;background:#fff;border-left:1px solid rgba(0,0,0,.12);box-shadow:-4px 0 16px #00000014;font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;transform:translate(100%);transition:transform .1s ease;will-change:transform}.tk-locations__filter-panel--open{transform:translate(0)}.tk-locations__filter-panel-header{display:flex;align-items:center;justify-content:space-between;padding:1.25rem 1.5rem;border-bottom:1px solid rgba(0,0,0,.12)}.tk-locations__filter-panel-title{margin:0;font-size:1rem;font-weight:600;color:#000000f2}.tk-locations__filter-panel-close{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;padding:0;color:#0009;cursor:pointer}.tk-locations__filter-panel-close:hover{color:#000000f2}.tk-locations__filter-panel-body{padding:1.5rem 1.5rem 0;overflow-y:auto}.tk-locations__filter-field{display:flex;flex-direction:column;gap:.5rem;margin-bottom:1.5rem}.tk-locations__filter-label{font-size:.8125rem;font-weight:500;color:#000000f2}.tk-locations__filter-select-wrap{position:relative;display:flex;align-items:center}.tk-locations__filter-select{width:100%;appearance:none;padding:.625rem 2rem .625rem .75rem;background:#fff;border:1px solid rgba(0,0,0,.12);border-radius:6px;font-family:inherit;font-size:.8125rem;color:#000000f2;cursor:pointer}.tk-locations__filter-select:focus{outline:none;border-color:#0006}.tk-locations__filter-select-icon{position:absolute;right:.5rem;font-size:1.125rem;height:1.125rem;width:1.125rem;color:#0006;pointer-events:none}.tk-locations__filter-panel-footer{display:flex;align-items:center;justify-content:space-between;padding:0 1.5rem 1.5rem}.tk-locations__filter-clear{background:none;border:none;padding:0;font-family:inherit;font-size:.813rem;font-weight:500;color:#000000f2;cursor:pointer;padding-inline:.75rem;height:2rem;border-radius:6px}.tk-locations__filter-clear:hover{background-color:oklch(95.5% .005 260)}.tk-locations__filter-done{background-color:#fff;border-radius:6px;font-weight:500;font-family:inherit;font-size:.813rem;cursor:pointer;border:1px solid oklch(92% .003 260);padding-inline:.75rem;height:2rem}.tk-locations__filter-done:hover{background-color:oklch(95.5% .005 260)}::ng-deep input.blue-input{border:solid .0625rem rgba(0,0,0,.5019607843)!important}::ng-deep input.blue-input:focus{color:#000000b3;background-color:#ededed;border:solid .0625rem rgba(0,0,0,.5019607843);font-weight:500;cursor:pointer;box-shadow:0 0 0 .12rem #fff,0 0 0 .25rem #1170cf,0 0 0 .3rem #1170cf59;background-color:#fff!important}::ng-deep input.blue-input:focus:focus-visible{outline:none}::ng-deep input.blue-input:hover{background-color:#00000012!important}\n"], dependencies: [{ kind: "directive", type: i4.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i5.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i5.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i5.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i7.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i8.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i8.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i8.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "component", type: i1$2.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "diameter", "strokeWidth", "mode", "value"], exportAs: ["matProgressSpinner"] }, { kind: "directive", type: i10.MatTooltip, selector: "[matTooltip]", exportAs: ["matTooltip"] }, { kind: "component", type: AppLoaderComponent, selector: "app-loader" }] });
615
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsComponent, decorators: [{
616
+ type: Component,
617
+ args: [{ selector: 'tk-locations', template: "<div class=\"tk-locations\">\r\n <app-loader *ngIf=\"isLoading\"></app-loader>\r\n\r\n <div class=\"tk-locations__view-toggle\">\r\n <button type=\"button\" class=\"tk-locations__view-button tk-locations__view-button--active\">\r\n <mat-icon class=\"tk-locations__view-icon\">menu</mat-icon>\r\n List\r\n </button>\r\n <button type=\"button\" class=\"tk-locations__view-button\" disabled title=\"Map view coming soon\">\r\n <mat-icon class=\"tk-locations__view-icon\">place</mat-icon>\r\n Map\r\n </button>\r\n </div>\r\n\r\n <div class=\"tk-locations__banner\" *ngIf=\"showPendingBanner\">\r\n <mat-icon class=\"tk-locations__banner-icon\">warning</mat-icon>\r\n <span class=\"tk-locations__banner-text\">\r\n View location(s) with pending action items to resume your calling service in {{ pendingLocations.length }} or more locations.\r\n </span>\r\n <button type=\"button\" class=\"tk-locations__banner-close\" aria-label=\"Dismiss\" (click)=\"dismissBanner()\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n\r\n <div class=\"tk-locations__toolbar\">\r\n <div style=\"position: relative; width: fit-content; min-width: 200px\">\r\n <input\r\n [value]=\"searchTerm\"\r\n class=\"blue-input\"\r\n (input)=\"onSearchInputChange($event)\"\r\n type=\"text\"\r\n placeholder=\"Search by name, city, state, country\"\r\n style=\"\r\n width: 100%;\r\n height: 34px;\r\n border-radius: 0.5rem;\r\n font-size: 16px;\r\n padding: 6px 12px 6px 44px;\r\n border: 1px solid #00000080;\r\n background: #fff;\r\n color: #222;\r\n outline: none;\r\n box-sizing: border-box;\r\n min-width: 280px;\r\n \"\r\n />\r\n <span\r\n style=\"\r\n position: absolute;\r\n left: 12px;\r\n top: 50%;\r\n transform: translateY(-50%);\r\n color: #757575;\r\n font-size: 18px;\r\n font-weight: normal;\r\n pointer-events: none;\r\n \"\r\n >\r\n <i\r\n class=\"material-icons\"\r\n style=\"font-size: 18px; font-weight: normal\"\r\n >search</i\r\n >\r\n </span>\r\n </div>\r\n\r\n <button type=\"button\" class=\"tk-locations__filter-button\" (click)=\"toggleFilterPanel()\">\r\n <img class=\"tk-locations__filter-icon\" src=\"assets/icons/filter-regular.svg\" alt=\"filter_list\" title=\"filter_list\">\r\n Filter\r\n </button>\r\n\r\n <span class=\"tk-locations__count\">{{ totalElements }} locations</span>\r\n\r\n <button type=\"button\" class=\"tk-locations__download-button\" aria-label=\"Download locations\" title=\"Download locations\" (click)=\"exportLocations()\">\r\n <mat-icon>file_download</mat-icon>\r\n </button>\r\n\r\n <button type=\"button\" class=\"tk-locations__manage-button\" [matMenuTriggerFor]=\"manageMenu\">\r\n Manage locations\r\n <mat-icon class=\"tk-locations__manage-chevron\">expand_more</mat-icon>\r\n </button>\r\n <mat-menu #manageMenu=\"matMenu\" xPosition=\"before\">\r\n <button mat-menu-item type=\"button\" (click)=\"onAddLocation()\">Add location</button>\r\n <button mat-menu-item type=\"button\" (click)=\"onImportLocations()\">Import locations</button>\r\n </mat-menu>\r\n </div>\r\n\r\n <table class=\"tk-locations__table\">\r\n <thead>\r\n <tr>\r\n <th (click)=\"toggleNameSort()\">\r\n Location Name\r\n <mat-icon class=\"tk-locations__sort-icon\">{{ sortDirection === 'asc' ? 'arrow_upward' : 'arrow_downward' }}</mat-icon>\r\n </th>\r\n <th>Address</th>\r\n <th>Country/Region</th>\r\n <th>Status</th>\r\n <th>Provisioning Type</th>\r\n <th class=\"tk-locations__actions-col\"></th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <tr *ngFor=\"let row of pagedRows\" (click)=\"onOpenLocation(row)\">\r\n <td class=\"tk-locations__name-cell\">\r\n <a href=\"javascript:void(0)\" class=\"tk-locations__name-link\" (click)=\"$event.stopPropagation(); onOpenLocation(row)\">{{ row.site.name }}</a>\r\n </td>\r\n <td>{{ addressLine(row) || '\u2014' }}</td>\r\n <td>{{ countryLabel(row) || '\u2014' }}</td>\r\n <td>\r\n <span class=\"tk-locations__status\" *ngIf=\"row.batchStatus; else noStatus\">\r\n <span\r\n class=\"tk-locations__status-dot\"\r\n [class.tk-locations__status-dot--success]=\"isSuccessStatus(row)\"\r\n [class.tk-locations__status-dot--in-progress]=\"isInProgressStatus(row)\"\r\n [class.tk-locations__status-dot--failed]=\"isFailedStatus(row)\"></span>\r\n {{ row.batchStatus }}\r\n </span>\r\n <ng-template #noStatus>\u2014</ng-template>\r\n </td>\r\n <td>\r\n <span class=\"tk-locations__icon-wrapper\" *ngIf=\"provisioningTypeIcon(row) as pt; else noProvisioningType\">\r\n <img [src]=\"pt.src\" [matTooltip]=\"pt.tooltip\" matTooltipPosition=\"right\" width=\"20\" alt=\"\">\r\n </span>\r\n <ng-template #noProvisioningType>\u2014</ng-template>\r\n </td>\r\n <td class=\"tk-locations__actions-col\">\r\n <mat-progress-spinner\r\n *ngIf=\"row.migrationStatus === 'IN_PROGRESS'\"\r\n class=\"tk-locations__row-action-spinner\"\r\n [diameter]=\"20\"\r\n strokeWidth=\"2\"\r\n mode=\"indeterminate\"\r\n matTooltip=\"Migrating site\u2026\">\r\n </mat-progress-spinner>\r\n <button\r\n *ngIf=\"row.migrationStatus !== 'IN_PROGRESS'\"\r\n mat-icon-button\r\n class=\"tk-locations__row-action-button\"\r\n [matMenuTriggerFor]=\"rowMenu\"\r\n (click)=\"$event.stopPropagation()\"\r\n aria-label=\"Open location actions\">\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n <mat-menu #rowMenu=\"matMenu\" yPosition=\"below\">\r\n <button *ngIf=\"row.location\" mat-menu-item type=\"button\" (click)=\"onOpenLocation(row)\">View details</button>\r\n <button *ngIf=\"row.location\" mat-menu-item type=\"button\" (click)=\"onEditLocation(row)\">Edit location</button>\r\n <button\r\n *ngIf=\"canMigrateSite(row)\"\r\n mat-menu-item\r\n type=\"button\"\r\n (click)=\"onMigrateSite(row)\">Migrate site</button>\r\n <button *ngIf=\"row.location\" mat-menu-item type=\"button\" (click)=\"onRemoveLocation(row)\">Remove location</button>\r\n </mat-menu>\r\n </td>\r\n </tr>\r\n <tr *ngIf=\"!pagedRows.length\">\r\n <td colspan=\"6\" class=\"tk-locations__empty\">No locations match your search.</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n\r\n <div class=\"tk-locations__footer\">\r\n <div class=\"tk-locations__rows-per-page\">\r\n <label for=\"tk-locations-page-size\">Rows per page:</label>\r\n <select id=\"tk-locations-page-size\" class=\"tk-locations__rows-per-page-select\" [ngModel]=\"pageSize\" (change)=\"onPageSizeChange($event)\">\r\n <option *ngFor=\"let size of pageSizeOptions\" [value]=\"size\">{{ size }}</option>\r\n </select>\r\n </div>\r\n <span class=\"tk-locations__footer-text\">{{ pageRangeLabel }}</span>\r\n <div class=\"tk-locations__pagination\">\r\n <button type=\"button\" class=\"tk-locations__pagination-button\" [disabled]=\"!hasPreviousPage\" (click)=\"goToPreviousPage()\" aria-label=\"Previous page\">\r\n <mat-icon>chevron_left</mat-icon>\r\n </button>\r\n <button type=\"button\" class=\"tk-locations__pagination-button\" [disabled]=\"!hasNextPage\" (click)=\"goToNextPage()\" aria-label=\"Next page\">\r\n <mat-icon>chevron_right</mat-icon>\r\n </button>\r\n </div>\r\n </div>\r\n\r\n <div\r\n class=\"tk-locations__filter-backdrop\"\r\n *ngIf=\"isFilterPanelOpen\"\r\n (click)=\"closeFilterPanel()\">\r\n </div>\r\n\r\n <aside class=\"tk-locations__filter-panel\" [class.tk-locations__filter-panel--open]=\"isFilterPanelOpen\">\r\n <div class=\"tk-locations__filter-panel-header\">\r\n <h3 class=\"tk-locations__filter-panel-title\">Filter locations</h3>\r\n <button\r\n type=\"button\"\r\n class=\"tk-locations__filter-panel-close\"\r\n aria-label=\"Close filter panel\"\r\n (click)=\"closeFilterPanel()\">\r\n <mat-icon>close</mat-icon>\r\n </button>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-panel-body\">\r\n <div class=\"tk-locations__filter-field\">\r\n <label class=\"tk-locations__filter-label\" for=\"tk-locations-filter-status\">Status</label>\r\n <div class=\"tk-locations__filter-select-wrap\">\r\n <select id=\"tk-locations-filter-status\" class=\"tk-locations__filter-select\" [(ngModel)]=\"filters.status\" (change)=\"onFilterChange()\">\r\n <option value=\"\">All</option>\r\n <option *ngFor=\"let status of statuses\" [value]=\"status\">{{ status }}</option>\r\n </select>\r\n <mat-icon class=\"tk-locations__filter-select-icon\">expand_more</mat-icon>\r\n </div>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-field\">\r\n <label class=\"tk-locations__filter-label\" for=\"tk-locations-filter-country\">Country/Region</label>\r\n <div class=\"tk-locations__filter-select-wrap\">\r\n <select id=\"tk-locations-filter-country\" class=\"tk-locations__filter-select\" [(ngModel)]=\"filters.country\" (change)=\"onFilterChange()\">\r\n <option value=\"\">All countries</option>\r\n <option *ngFor=\"let country of countries\" [value]=\"country\">{{ country }}</option>\r\n </select>\r\n <mat-icon class=\"tk-locations__filter-select-icon\">expand_more</mat-icon>\r\n </div>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-field\">\r\n <label class=\"tk-locations__filter-label\" for=\"tk-locations-filter-pending\">Pending action items</label>\r\n <div class=\"tk-locations__filter-select-wrap\">\r\n <select id=\"tk-locations-filter-pending\" class=\"tk-locations__filter-select\" [(ngModel)]=\"filters.pendingActions\" (change)=\"onFilterChange()\">\r\n <option value=\"\">All</option>\r\n <option value=\"true\">Yes</option>\r\n <option value=\"false\">No</option>\r\n </select>\r\n <mat-icon class=\"tk-locations__filter-select-icon\">expand_more</mat-icon>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <div class=\"tk-locations__filter-panel-footer\">\r\n <button type=\"button\" class=\"tk-locations__filter-clear\" (click)=\"clearFilters()\">Clear all</button>\r\n <button type=\"button\" class=\"tk-locations__filter-done\" (click)=\"closeFilterPanel()\">Done</button>\r\n </div>\r\n </aside>\r\n</div>\r\n", styles: ["@import\"https://fonts.googleapis.com/css2?family=Inter:wght@300;400&display=swap\";.tk-locations{font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;color:#000000f2;padding-top:0}.tk-locations__view-toggle{display:flex;align-items:center;gap:.25rem;margin-bottom:1rem;width:-moz-fit-content;width:fit-content}.tk-locations__view-button{display:inline-flex;align-items:center;gap:.375rem;padding:.5rem .875rem;background:none;border:none;border-radius:6.25rem;font-family:inherit;font-size:1rem;font-weight:500;color:#000000b3;cursor:pointer}.tk-locations__view-button:hover:not(:disabled){background:rgba(0,0,0,.0705882353)}.tk-locations__view-button--active{background:#C1C1C1;color:#000000f2}.tk-locations__view-button--active:hover{background:rgba(0,0,0,.3019607843)}.tk-locations__view-button:disabled{cursor:default;opacity:.5}.tk-locations__view-button:disabled:hover{background:none}.tk-locations__view-icon{height:1.125rem;width:1.125rem;opacity:.6}.tk-locations__view-button--active .tk-locations__view-icon{opacity:1}.tk-locations__banner{display:flex;align-items:center;gap:.5rem;margin-bottom:1rem;padding:.75rem 1rem;background:#fdf1d6;border:1px solid #f0d9a6;border-radius:.5rem;color:#7a5b0a}.tk-locations__banner-icon{font-size:1.125rem;height:1.125rem;width:1.125rem;color:#b5860b;flex-shrink:0}.tk-locations__banner-text{flex:1;font-size:.8125rem}.tk-locations__banner-close{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;padding:0;color:#7a5b0a;cursor:pointer}.tk-locations__banner-close:hover{color:#000000f2}.tk-locations__toolbar{display:flex;align-items:center;gap:.75rem;margin:.5rem .5rem 1rem}.tk-locations__filter-button{display:inline-flex;align-items:center;gap:.375rem;height:34px;padding:.5rem .875rem;background:#fff;border:1px solid rgba(0,0,0,.5019607843);border-radius:.5rem;font-family:inherit;font-size:.8125rem;font-weight:500;color:#000000f2;cursor:pointer}.tk-locations__filter-button:hover{background:rgba(0,0,0,.03)}.tk-locations__filter-icon{font-size:1rem;height:1rem;width:1rem;opacity:.6}.tk-locations__count{font-size:.8125rem;color:#0009;white-space:nowrap}.tk-locations__download-button{display:inline-flex;align-items:center;justify-content:center;width:34px;height:34px;margin-left:auto;background:none;border:none;color:#0009;cursor:pointer}.tk-locations__download-button:hover{color:#000000f2}.tk-locations__manage-button{display:inline-flex;align-items:center;gap:.375rem;height:34px;padding:.5rem 1rem;background:#000;color:#fff;border:none;border-radius:6.25rem;font-family:inherit;font-size:.8125rem;font-weight:500;cursor:pointer}.tk-locations__manage-button:hover{background:#222}.tk-locations__manage-icon,.tk-locations__manage-chevron{font-size:1.125rem;height:1.125rem;width:1.125rem}.tk-locations__table{width:100%;border-collapse:collapse;font-family:Inter,sans-serif}.tk-locations__table th{height:39px;padding:.5rem 1.5rem .5rem .75rem;background-color:#ededed;text-align:start;font-size:.75rem;font-weight:500;color:#000000b3;word-break:break-all;max-inline-size:100%;cursor:pointer}.tk-locations__table th:hover{background-color:#dedede}.tk-locations__table td{height:49px;padding:.5rem 1.5rem .5rem .75rem;box-shadow:inset 0 -1px #0003;background-color:#fff;text-align:start;font-size:.875rem;color:#000000f2;word-break:break-all;cursor:pointer;transition:background-color .2s,box-shadow .2s}.tk-locations__table tbody tr:hover td{background:#ededed}.tk-locations__sort-icon{font-size:1rem;height:1rem;width:1rem;vertical-align:middle;margin-left:.25rem;color:#00000080}.tk-locations__name-cell{min-width:0}.tk-locations__name-link{color:#000000de;font-weight:500;text-decoration:none}.tk-locations__actions-col{width:3rem;text-align:center!important;position:relative}.tk-locations__row-action-spinner{display:inline-block;margin:0 auto}.tk-locations__icon-wrapper{display:inline-flex;align-items:center}.tk-locations__status{display:inline-flex;align-items:center;gap:.375rem;white-space:nowrap}.tk-locations__status-dot{width:.5rem;height:.5rem;border-radius:50%;background:rgba(0,0,0,.3);flex-shrink:0}.tk-locations__status-dot--success{background:#1d805f}.tk-locations__status-dot--in-progress{background:#639fff}.tk-locations__status-dot--failed{background:#c73636}.tk-locations__row-action-button{color:#0009}.tk-locations__row-action-button:hover{color:#000000f2}.tk-locations__empty{padding:1.5rem;text-align:center;color:#0009}.tk-locations__footer{display:flex;align-items:center;justify-content:flex-end;gap:1.5rem;margin-top:1rem;font-size:.8125rem;color:#0009}.tk-locations__rows-per-page{display:flex;align-items:center;gap:.5rem}.tk-locations__rows-per-page-select{padding:.25rem .5rem;background:#fff;border:1px solid rgba(0,0,0,.12);border-radius:6px;font-family:inherit;font-size:.8125rem;color:#000000f2;cursor:pointer}.tk-locations__pagination{display:flex;align-items:center;gap:.25rem}.tk-locations__pagination-button{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;padding:0;color:#0009;cursor:pointer}.tk-locations__pagination-button:hover:not(:disabled){color:#000000f2}.tk-locations__pagination-button:disabled{color:#00000040;cursor:default}.tk-locations__filter-backdrop{position:fixed;inset:0;z-index:1000;background-color:oklch(18% .01 260/20%)}.tk-locations__filter-panel{position:fixed;top:0;right:0;bottom:0;z-index:1001;display:flex;flex-direction:column;width:22rem;max-width:100vw;background:#fff;border-left:1px solid rgba(0,0,0,.12);box-shadow:-4px 0 16px #00000014;font-family:Inter,Helvetica Neue,Helvetica,Arial,sans-serif;transform:translate(100%);transition:transform .1s ease;will-change:transform}.tk-locations__filter-panel--open{transform:translate(0)}.tk-locations__filter-panel-header{display:flex;align-items:center;justify-content:space-between;padding:1.25rem 1.5rem;border-bottom:1px solid rgba(0,0,0,.12)}.tk-locations__filter-panel-title{margin:0;font-size:1rem;font-weight:600;color:#000000f2}.tk-locations__filter-panel-close{display:inline-flex;align-items:center;justify-content:center;background:none;border:none;padding:0;color:#0009;cursor:pointer}.tk-locations__filter-panel-close:hover{color:#000000f2}.tk-locations__filter-panel-body{padding:1.5rem 1.5rem 0;overflow-y:auto}.tk-locations__filter-field{display:flex;flex-direction:column;gap:.5rem;margin-bottom:1.5rem}.tk-locations__filter-label{font-size:.8125rem;font-weight:500;color:#000000f2}.tk-locations__filter-select-wrap{position:relative;display:flex;align-items:center}.tk-locations__filter-select{width:100%;appearance:none;padding:.625rem 2rem .625rem .75rem;background:#fff;border:1px solid rgba(0,0,0,.12);border-radius:6px;font-family:inherit;font-size:.8125rem;color:#000000f2;cursor:pointer}.tk-locations__filter-select:focus{outline:none;border-color:#0006}.tk-locations__filter-select-icon{position:absolute;right:.5rem;font-size:1.125rem;height:1.125rem;width:1.125rem;color:#0006;pointer-events:none}.tk-locations__filter-panel-footer{display:flex;align-items:center;justify-content:space-between;padding:0 1.5rem 1.5rem}.tk-locations__filter-clear{background:none;border:none;padding:0;font-family:inherit;font-size:.813rem;font-weight:500;color:#000000f2;cursor:pointer;padding-inline:.75rem;height:2rem;border-radius:6px}.tk-locations__filter-clear:hover{background-color:oklch(95.5% .005 260)}.tk-locations__filter-done{background-color:#fff;border-radius:6px;font-weight:500;font-family:inherit;font-size:.813rem;cursor:pointer;border:1px solid oklch(92% .003 260);padding-inline:.75rem;height:2rem}.tk-locations__filter-done:hover{background-color:oklch(95.5% .005 260)}::ng-deep input.blue-input{border:solid .0625rem rgba(0,0,0,.5019607843)!important}::ng-deep input.blue-input:focus{color:#000000b3;background-color:#ededed;border:solid .0625rem rgba(0,0,0,.5019607843);font-weight:500;cursor:pointer;box-shadow:0 0 0 .12rem #fff,0 0 0 .25rem #1170cf,0 0 0 .3rem #1170cf59;background-color:#fff!important}::ng-deep input.blue-input:focus:focus-visible{outline:none}::ng-deep input.blue-input:hover{background-color:#00000012!important}\n"] }]
618
+ }], ctorParameters: function () { return [{ type: APIService }, { type: LocationsService }, { type: i1.MatDialog }]; }, propDecorators: { exHost: [{
619
+ type: Input
620
+ }], token: [{
621
+ type: Input
622
+ }], customerId: [{
623
+ type: Input
624
+ }], openLocation: [{
625
+ type: Output
626
+ }], editLocation: [{
627
+ type: Output
628
+ }], removeLocation: [{
629
+ type: Output
630
+ }], addLocation: [{
631
+ type: Output
632
+ }], importLocations: [{
633
+ type: Output
634
+ }] } });
635
+
636
+ class LocationsModule {
637
+ }
638
+ LocationsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
639
+ LocationsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: LocationsModule, declarations: [LocationsComponent,
640
+ LocationConfirmDialogComponent,
641
+ AppLoaderComponent], imports: [CommonModule,
642
+ HttpClientModule,
643
+ FormsModule,
644
+ MaterialModule], exports: [LocationsComponent] });
645
+ LocationsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsModule, imports: [CommonModule,
646
+ HttpClientModule,
647
+ FormsModule,
648
+ MaterialModule] });
649
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LocationsModule, decorators: [{
650
+ type: NgModule,
651
+ args: [{
652
+ declarations: [
653
+ LocationsComponent,
654
+ LocationConfirmDialogComponent,
655
+ AppLoaderComponent,
656
+ ],
657
+ imports: [
658
+ CommonModule,
659
+ HttpClientModule,
660
+ FormsModule,
661
+ MaterialModule,
662
+ ],
663
+ exports: [
664
+ LocationsComponent,
665
+ ],
666
+ }]
667
+ }] });
668
+
669
+ /*
670
+ * Public API Surface of @tuki-io/tuki-widgets
671
+ */
672
+ // Widget Modules
673
+
674
+ /**
675
+ * Generated bundle index. Do not edit.
676
+ */
677
+
678
+ export { LocationsComponent, LocationsModule };
679
+ //# sourceMappingURL=tuki-io-tuki-widgets-locations.mjs.map