@dereekb/dbx-web 11.1.8 → 12.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (742) hide show
  1. package/calendar/lib/calendar.base.component.d.ts +10 -1
  2. package/calendar/lib/calendar.component.d.ts +8 -5
  3. package/calendar/lib/calendar.module.d.ts +4 -16
  4. package/calendar/lib/calendar.provider.d.ts +5 -0
  5. package/calendar/lib/calendar.store.d.ts +13 -9
  6. package/calendar/lib/index.d.ts +1 -0
  7. package/esm2022/calendar/lib/calendar.base.component.mjs +26 -12
  8. package/esm2022/calendar/lib/calendar.component.mjs +19 -17
  9. package/esm2022/calendar/lib/calendar.mjs +1 -1
  10. package/esm2022/calendar/lib/calendar.module.mjs +10 -76
  11. package/esm2022/calendar/lib/calendar.provider.mjs +11 -0
  12. package/esm2022/calendar/lib/calendar.store.mjs +19 -19
  13. package/esm2022/calendar/lib/index.mjs +2 -1
  14. package/esm2022/lib/action/action.confirm.directive.mjs +10 -12
  15. package/esm2022/lib/action/action.module.mjs +12 -16
  16. package/esm2022/lib/action/key.trigger.directive.mjs +6 -5
  17. package/esm2022/lib/action/snackbar/action.snackbar.component.mjs +29 -36
  18. package/esm2022/lib/action/snackbar/action.snackbar.directive.mjs +14 -27
  19. package/esm2022/lib/action/snackbar/action.snackbar.generator.mjs +1 -1
  20. package/esm2022/lib/action/snackbar/action.snackbar.module.mjs +8 -14
  21. package/esm2022/lib/action/snackbar/action.snackbar.service.mjs +4 -4
  22. package/esm2022/lib/action/transition/action.transition.module.mjs +14 -13
  23. package/esm2022/lib/action/transition/transition.safety.dialog.component.mjs +18 -24
  24. package/esm2022/lib/action/transition/transition.safety.directive.mjs +30 -33
  25. package/esm2022/lib/button/button.component.mjs +71 -104
  26. package/esm2022/lib/button/button.module.mjs +44 -12
  27. package/esm2022/lib/button/button.spacer.directive.mjs +20 -0
  28. package/esm2022/lib/button/icon/icon.button.component.mjs +48 -32
  29. package/esm2022/lib/button/icon/icon.button.module.mjs +10 -24
  30. package/esm2022/lib/button/index.mjs +2 -2
  31. package/esm2022/lib/button/progress/abstract.progress.button.directive.mjs +103 -0
  32. package/esm2022/lib/button/progress/bar.button.component.mjs +15 -11
  33. package/esm2022/lib/button/progress/button.progress.config.mjs +2 -2
  34. package/esm2022/lib/button/progress/button.progress.module.mjs +13 -28
  35. package/esm2022/lib/button/progress/button.progress.providers.mjs +18 -0
  36. package/esm2022/lib/button/progress/index.mjs +2 -1
  37. package/esm2022/lib/button/progress/spinner.button.component.mjs +66 -38
  38. package/esm2022/lib/dbx-web.module.mjs +4 -4
  39. package/esm2022/lib/error/default.error.widget.component.mjs +22 -15
  40. package/esm2022/lib/error/error.action.directive.mjs +9 -8
  41. package/esm2022/lib/error/error.api.mjs +1 -1
  42. package/esm2022/lib/error/error.component.mjs +56 -94
  43. package/esm2022/lib/error/error.details.component.mjs +15 -14
  44. package/esm2022/lib/error/error.loading.directive.mjs +20 -20
  45. package/esm2022/lib/error/error.module.mjs +21 -18
  46. package/esm2022/lib/error/error.popover.component.mjs +14 -17
  47. package/esm2022/lib/error/error.snackbar.action.directive.mjs +6 -5
  48. package/esm2022/lib/error/error.snackbar.component.mjs +57 -39
  49. package/esm2022/lib/error/error.snackbar.service.mjs +11 -10
  50. package/esm2022/lib/error/error.view.component.mjs +40 -33
  51. package/esm2022/lib/error/error.widget.component.mjs +19 -25
  52. package/esm2022/lib/error/error.widget.directive.mjs +3 -3
  53. package/esm2022/lib/error/error.widget.service.mjs +7 -7
  54. package/esm2022/lib/error/state.mjs +1 -1
  55. package/esm2022/lib/extension/download/text/download.text.component.mjs +46 -56
  56. package/esm2022/lib/extension/download/text/download.text.module.mjs +11 -33
  57. package/esm2022/lib/extension/model/index.mjs +2 -2
  58. package/esm2022/lib/extension/model/model.providers.mjs +42 -0
  59. package/esm2022/lib/extension/model/model.state.service.mjs +5 -8
  60. package/esm2022/lib/extension/model/model.tracker.mjs +1 -1
  61. package/esm2022/lib/extension/model/model.tracker.service.mjs +5 -8
  62. package/esm2022/lib/extension/model/model.tracker.view.storage.mjs +8 -8
  63. package/esm2022/lib/extension/model/model.types.mjs +1 -1
  64. package/esm2022/lib/extension/model/model.types.service.mjs +5 -5
  65. package/esm2022/lib/extension/model/state/actions/model.actions.mjs +1 -1
  66. package/esm2022/lib/extension/model/state/effects/tracker.effects.mjs +3 -3
  67. package/esm2022/lib/extension/structure/structure.body.directive.mjs +6 -5
  68. package/esm2022/lib/extension/structure/structure.module.mjs +11 -17
  69. package/esm2022/lib/extension/structure/structure.structure.directive.mjs +10 -6
  70. package/esm2022/lib/extension/widget/widget.component.mjs +32 -37
  71. package/esm2022/lib/extension/widget/widget.directive.mjs +3 -3
  72. package/esm2022/lib/extension/widget/widget.list.component.mjs +31 -20
  73. package/esm2022/lib/extension/widget/widget.module.mjs +15 -24
  74. package/esm2022/lib/extension/widget/widget.service.mjs +4 -4
  75. package/esm2022/lib/index.mjs +2 -2
  76. package/esm2022/lib/interaction/dialog/abstract.dialog.directive.mjs +3 -3
  77. package/esm2022/lib/interaction/dialog/dialog.action.directive.mjs +19 -23
  78. package/esm2022/lib/interaction/dialog/dialog.content.close.component.mjs +23 -22
  79. package/esm2022/lib/interaction/dialog/dialog.content.directive.mjs +23 -0
  80. package/esm2022/lib/interaction/dialog/dialog.content.footer.component.mjs +21 -29
  81. package/esm2022/lib/interaction/dialog/dialog.module.mjs +9 -16
  82. package/esm2022/lib/interaction/dialog/index.mjs +2 -2
  83. package/esm2022/lib/interaction/filter/filter.config.mjs +2 -0
  84. package/esm2022/lib/interaction/filter/filter.menu.mjs +1 -1
  85. package/esm2022/lib/interaction/filter/filter.module.mjs +9 -54
  86. package/esm2022/lib/interaction/filter/filter.partial.list.component.mjs +13 -11
  87. package/esm2022/lib/interaction/filter/filter.partial.menu.component.mjs +22 -29
  88. package/esm2022/lib/interaction/filter/filter.partial.mjs +13 -24
  89. package/esm2022/lib/interaction/filter/filter.popover.button.component.mjs +17 -31
  90. package/esm2022/lib/interaction/filter/filter.popover.button.directive.mjs +10 -12
  91. package/esm2022/lib/interaction/filter/filter.popover.component.mjs +25 -30
  92. package/esm2022/lib/interaction/filter/filter.preset.directive.mjs +17 -29
  93. package/esm2022/lib/interaction/filter/filter.preset.list.component.mjs +13 -11
  94. package/esm2022/lib/interaction/filter/filter.preset.menu.component.mjs +22 -29
  95. package/esm2022/lib/interaction/filter/filter.wrapper.component.mjs +23 -29
  96. package/esm2022/lib/interaction/filter/index.mjs +2 -1
  97. package/esm2022/lib/interaction/interaction.module.mjs +17 -6
  98. package/esm2022/lib/interaction/popover/abstract.popover.directive.mjs +3 -3
  99. package/esm2022/lib/interaction/popover/abstract.popover.ref.directive.mjs +13 -22
  100. package/esm2022/lib/interaction/popover/index.mjs +2 -2
  101. package/esm2022/lib/interaction/popover/popover.action.directive.mjs +20 -23
  102. package/esm2022/lib/interaction/popover/popover.close.component.mjs +12 -8
  103. package/esm2022/lib/interaction/popover/popover.component.mjs +15 -13
  104. package/esm2022/lib/interaction/popover/popover.content.component.mjs +20 -13
  105. package/esm2022/lib/interaction/popover/popover.content.module.mjs +9 -19
  106. package/esm2022/lib/interaction/popover/popover.controls.directive.mjs +7 -6
  107. package/esm2022/lib/interaction/popover/popover.coordinator.component.mjs +17 -15
  108. package/esm2022/lib/interaction/popover/popover.coordinator.service.mjs +4 -4
  109. package/esm2022/lib/interaction/popover/popover.header.component.mjs +25 -22
  110. package/esm2022/lib/interaction/popover/popover.module.mjs +8 -18
  111. package/esm2022/lib/interaction/popover/popover.scroll.content.directive.mjs +41 -0
  112. package/esm2022/lib/interaction/popover/popover.service.mjs +4 -4
  113. package/esm2022/lib/interaction/popup/abstract.popup.directive.mjs +3 -3
  114. package/esm2022/lib/interaction/popup/popup.component.mjs +20 -23
  115. package/esm2022/lib/interaction/popup/popup.content.component.mjs +21 -14
  116. package/esm2022/lib/interaction/popup/popup.controls.buttons.component.mjs +49 -26
  117. package/esm2022/lib/interaction/popup/popup.controls.component.mjs +15 -14
  118. package/esm2022/lib/interaction/popup/popup.coordinator.component.mjs +15 -12
  119. package/esm2022/lib/interaction/popup/popup.coordinator.service.mjs +4 -4
  120. package/esm2022/lib/interaction/popup/popup.mjs +6 -7
  121. package/esm2022/lib/interaction/popup/popup.module.mjs +8 -19
  122. package/esm2022/lib/interaction/popup/popup.position.strategy.mjs +1 -1
  123. package/esm2022/lib/interaction/popup/popup.service.mjs +8 -5
  124. package/esm2022/lib/interaction/prompt/index.mjs +2 -2
  125. package/esm2022/lib/interaction/prompt/prompt.box.directive.mjs +19 -0
  126. package/esm2022/lib/interaction/prompt/prompt.button.confirm.directive.mjs +6 -5
  127. package/esm2022/lib/interaction/prompt/prompt.component.mjs +16 -17
  128. package/esm2022/lib/interaction/prompt/prompt.confirm.component.mjs +35 -35
  129. package/esm2022/lib/interaction/prompt/prompt.confirm.dialog.component.mjs +14 -13
  130. package/esm2022/lib/interaction/prompt/prompt.confirm.directive.mjs +28 -23
  131. package/esm2022/lib/interaction/prompt/prompt.module.mjs +9 -18
  132. package/esm2022/lib/interaction/prompt/prompt.page.component.mjs +11 -8
  133. package/esm2022/lib/keypress/keydown.listener.directive.mjs +6 -5
  134. package/esm2022/lib/keypress/keypress.module.mjs +9 -8
  135. package/esm2022/lib/layout/bar/bar.directive.mjs +14 -11
  136. package/esm2022/lib/layout/bar/bar.header.component.mjs +31 -26
  137. package/esm2022/lib/layout/bar/bar.layout.module.mjs +9 -12
  138. package/esm2022/lib/layout/bar/pagebar.component.mjs +33 -12
  139. package/esm2022/lib/layout/block/block.layout.module.mjs +10 -12
  140. package/esm2022/lib/layout/block/two.block.component.mjs +25 -32
  141. package/esm2022/lib/layout/card/card.box.component.mjs +27 -20
  142. package/esm2022/lib/layout/card/card.box.container.directive.mjs +20 -0
  143. package/esm2022/lib/layout/card/card.box.layout.module.mjs +10 -12
  144. package/esm2022/lib/layout/card/index.mjs +2 -2
  145. package/esm2022/lib/layout/column/column.layout.module.mjs +9 -7
  146. package/esm2022/lib/layout/column/one/one.column.component.mjs +16 -15
  147. package/esm2022/lib/layout/column/one/one.column.module.mjs +9 -9
  148. package/esm2022/lib/layout/column/two/index.mjs +2 -2
  149. package/esm2022/lib/layout/column/two/two.column.back.directive.mjs +10 -12
  150. package/esm2022/lib/layout/column/two/two.column.component.mjs +77 -51
  151. package/esm2022/lib/layout/column/two/two.column.context.directive.mjs +14 -21
  152. package/esm2022/lib/layout/column/two/two.column.full.left.directive.mjs +13 -28
  153. package/esm2022/lib/layout/column/two/two.column.head.directive.mjs +24 -0
  154. package/esm2022/lib/layout/column/two/two.column.module.mjs +9 -15
  155. package/esm2022/lib/layout/column/two/two.column.right.component.mjs +90 -49
  156. package/esm2022/lib/layout/column/two/two.column.sref.directive.mjs +13 -13
  157. package/esm2022/lib/layout/column/two/two.column.sref.showright.directive.mjs +9 -7
  158. package/esm2022/lib/layout/column/two/two.column.store.mjs +15 -11
  159. package/esm2022/lib/layout/compact/compact.directive.mjs +3 -3
  160. package/esm2022/lib/layout/compact/compact.layout.module.mjs +4 -4
  161. package/esm2022/lib/layout/compact/compact.mjs +1 -1
  162. package/esm2022/lib/layout/compact/compact.store.mjs +4 -4
  163. package/esm2022/lib/layout/content/content.border.directive.mjs +11 -11
  164. package/esm2022/lib/layout/content/content.box.directive.mjs +12 -15
  165. package/esm2022/lib/layout/content/content.container.directive.mjs +16 -17
  166. package/esm2022/lib/layout/content/content.directive.mjs +6 -5
  167. package/esm2022/lib/layout/content/content.elevate.directive.mjs +10 -11
  168. package/esm2022/lib/layout/content/content.layout.module.mjs +9 -11
  169. package/esm2022/lib/layout/content/content.page.directive.mjs +6 -5
  170. package/esm2022/lib/layout/content/content.pit.directive.mjs +10 -11
  171. package/esm2022/lib/layout/flag/flag.component.mjs +15 -14
  172. package/esm2022/lib/layout/flag/flag.layout.module.mjs +8 -13
  173. package/esm2022/lib/layout/flag/flag.prompt.component.mjs +18 -20
  174. package/esm2022/lib/layout/flex/flex.group.directive.mjs +21 -47
  175. package/esm2022/lib/layout/flex/flex.layout.module.mjs +11 -9
  176. package/esm2022/lib/layout/flex/flex.size.directive.mjs +11 -12
  177. package/esm2022/lib/layout/item/index.mjs +1 -2
  178. package/esm2022/lib/layout/item/item.icon.component.mjs +31 -24
  179. package/esm2022/lib/layout/layout.module.mjs +6 -8
  180. package/esm2022/lib/layout/list/grid/index.mjs +3 -0
  181. package/esm2022/lib/layout/list/grid/list.grid.view.component.mjs +98 -0
  182. package/esm2022/lib/layout/list/grid/list.grid.view.directive.mjs +34 -0
  183. package/esm2022/lib/layout/list/group/index.mjs +4 -0
  184. package/esm2022/lib/layout/list/group/list.view.value.group.mjs +32 -0
  185. package/esm2022/lib/layout/list/group/list.view.value.group.title.directive.mjs +70 -0
  186. package/esm2022/lib/layout/list/group/list.view.value.group.title.header.component.mjs +60 -0
  187. package/esm2022/lib/layout/list/group/list.view.value.group.title.mjs +2 -0
  188. package/esm2022/lib/layout/list/index.mjs +6 -10
  189. package/esm2022/lib/layout/list/list.component.mjs +109 -135
  190. package/esm2022/lib/layout/list/list.content.empty.component.mjs +9 -7
  191. package/esm2022/lib/layout/list/list.directive.mjs +70 -56
  192. package/esm2022/lib/layout/list/list.layout.module.mjs +59 -49
  193. package/esm2022/lib/layout/list/list.module.mjs +40 -0
  194. package/esm2022/lib/layout/list/list.view.directive.mjs +35 -28
  195. package/esm2022/lib/layout/list/list.view.mjs +1 -1
  196. package/esm2022/lib/layout/list/list.view.selection.directive.mjs +26 -10
  197. package/esm2022/lib/layout/list/list.view.value.component.mjs +135 -143
  198. package/esm2022/lib/layout/list/list.view.value.directive.mjs +12 -18
  199. package/esm2022/lib/layout/list/list.view.value.item.directive.mjs +3 -3
  200. package/esm2022/lib/layout/list/list.view.value.mjs +1 -1
  201. package/esm2022/lib/layout/list/list.view.value.modifier.mjs +1 -1
  202. package/esm2022/lib/layout/list/list.view.value.selection.component.mjs +80 -68
  203. package/esm2022/lib/layout/list/list.wrapper.mjs +1 -3
  204. package/esm2022/lib/layout/list/meta/index.mjs +2 -0
  205. package/esm2022/lib/layout/list/meta/list.view.meta.icon.component.mjs +39 -0
  206. package/esm2022/lib/layout/list/modifier/index.mjs +5 -0
  207. package/esm2022/lib/layout/list/modifier/list.modifier.module.mjs +22 -0
  208. package/esm2022/lib/layout/list/modifier/list.view.value.modifier.directive.mjs +75 -0
  209. package/esm2022/lib/layout/list/modifier/list.view.value.modifier.ripple.directive.mjs +37 -0
  210. package/esm2022/lib/layout/list/modifier/list.view.value.modifier.selection.directive.mjs +35 -0
  211. package/esm2022/lib/layout/section/section.component.mjs +18 -15
  212. package/esm2022/lib/layout/section/section.header.component.mjs +123 -106
  213. package/esm2022/lib/layout/section/section.intro.component.mjs +53 -51
  214. package/esm2022/lib/layout/section/section.layout.module.mjs +9 -15
  215. package/esm2022/lib/layout/section/section.mjs +1 -1
  216. package/esm2022/lib/layout/section/section.page.component.mjs +22 -18
  217. package/esm2022/lib/layout/section/subsection.component.mjs +13 -10
  218. package/esm2022/lib/layout/step/step.component.mjs +56 -21
  219. package/esm2022/lib/layout/step/step.layout.module.mjs +11 -10
  220. package/esm2022/lib/layout/style/index.mjs +2 -1
  221. package/esm2022/lib/layout/style/spacer.directive.mjs +6 -5
  222. package/esm2022/lib/layout/style/style.body.directive.mjs +22 -17
  223. package/esm2022/lib/layout/style/style.color.directive.mjs +11 -14
  224. package/esm2022/lib/layout/style/style.directive.mjs +13 -17
  225. package/esm2022/lib/layout/style/style.layout.module.mjs +8 -10
  226. package/esm2022/lib/layout/style/style.mjs +4 -1
  227. package/esm2022/lib/layout/style/style.providers.mjs +21 -0
  228. package/esm2022/lib/layout/style/style.service.mjs +54 -32
  229. package/esm2022/lib/layout/style/style.set.directive.mjs +31 -47
  230. package/esm2022/lib/layout/text/address.component.mjs +43 -22
  231. package/esm2022/lib/layout/text/compat/form.description.component.mjs +3 -3
  232. package/esm2022/lib/layout/text/compat/hint.component.mjs +3 -3
  233. package/esm2022/lib/layout/text/compat/label.component.mjs +3 -3
  234. package/esm2022/lib/layout/text/compat/note.component.mjs +3 -3
  235. package/esm2022/lib/layout/text/compat/notice.component.mjs +3 -3
  236. package/esm2022/lib/layout/text/compat/ok.component.mjs +3 -3
  237. package/esm2022/lib/layout/text/compat/success.component.mjs +3 -3
  238. package/esm2022/lib/layout/text/compat/text.compat.module.mjs +4 -4
  239. package/esm2022/lib/layout/text/compat/warn.component.mjs +3 -3
  240. package/esm2022/lib/layout/text/detail.block.component.mjs +11 -8
  241. package/esm2022/lib/layout/text/detail.block.header.component.mjs +24 -13
  242. package/esm2022/lib/layout/text/icon.spacer.component.mjs +6 -5
  243. package/esm2022/lib/layout/text/label.block.component.mjs +9 -7
  244. package/esm2022/lib/layout/text/linkify.component.mjs +13 -10
  245. package/esm2022/lib/layout/text/text.chip.directive.mjs +6 -5
  246. package/esm2022/lib/layout/text/text.chips.component.mjs +34 -29
  247. package/esm2022/lib/layout/text/text.module.mjs +8 -13
  248. package/esm2022/lib/loading/basic-loading.component.mjs +31 -97
  249. package/esm2022/lib/loading/loading-progress.component.mjs +47 -54
  250. package/esm2022/lib/loading/loading.action.directive.mjs +9 -11
  251. package/esm2022/lib/loading/loading.component.mjs +60 -81
  252. package/esm2022/lib/loading/loading.module.mjs +8 -13
  253. package/esm2022/lib/router/layout/anchor/anchor.component.mjs +86 -36
  254. package/esm2022/lib/router/layout/anchor/anchor.content.component.mjs +26 -14
  255. package/esm2022/lib/router/layout/anchor/anchor.icon.component.mjs +10 -6
  256. package/esm2022/lib/router/layout/anchor/anchor.link.component.mjs +9 -7
  257. package/esm2022/lib/router/layout/anchor/anchor.module.mjs +17 -13
  258. package/esm2022/lib/router/layout/anchor/anchor.segue.directive.mjs +11 -13
  259. package/esm2022/lib/router/layout/anchorlist/anchorlist.component.mjs +22 -28
  260. package/esm2022/lib/router/layout/anchorlist/anchorlist.module.mjs +9 -15
  261. package/esm2022/lib/router/layout/layout.module.mjs +4 -4
  262. package/esm2022/lib/router/layout/list/list.module.mjs +9 -7
  263. package/esm2022/lib/router/layout/list/router.list.directive.mjs +16 -20
  264. package/esm2022/lib/router/layout/navbar/navbar.component.mjs +41 -87
  265. package/esm2022/lib/router/layout/navbar/navbar.module.mjs +9 -43
  266. package/esm2022/lib/router/layout/sidenav/sidenav.button.component.mjs +28 -24
  267. package/esm2022/lib/router/layout/sidenav/sidenav.component.mjs +91 -71
  268. package/esm2022/lib/router/layout/sidenav/sidenav.ifdisplaymode.directive.mjs +18 -23
  269. package/esm2022/lib/router/layout/sidenav/sidenav.module.mjs +8 -22
  270. package/esm2022/lib/router/layout/sidenav/sidenav.page.component.mjs +37 -46
  271. package/esm2022/lib/router/layout/sidenav/sidenav.pagebar.component.mjs +18 -18
  272. package/esm2022/lib/router/provider/ngrouter/anchor.component.mjs +6 -7
  273. package/esm2022/lib/router/provider/ngrouter/angular.router.providers.mjs +23 -0
  274. package/esm2022/lib/router/provider/ngrouter/index.mjs +2 -2
  275. package/esm2022/lib/router/provider/router.provider.config.mjs +8 -1
  276. package/esm2022/lib/router/provider/uirouter/anchor.component.mjs +14 -12
  277. package/esm2022/lib/router/provider/uirouter/index.mjs +2 -2
  278. package/esm2022/lib/router/provider/uirouter/uirouter.router.providers.mjs +23 -0
  279. package/esm2022/lib/screen/index.mjs +2 -2
  280. package/esm2022/lib/screen/screen.providers.mjs +22 -0
  281. package/esm2022/lib/screen/screen.service.mjs +6 -6
  282. package/esm2022/lib/util/cdk.mjs +1 -1
  283. package/esm2022/mapbox/lib/index.mjs +3 -2
  284. package/esm2022/mapbox/lib/mapbox.change.service.mjs +4 -4
  285. package/esm2022/mapbox/lib/mapbox.injection.component.mjs +13 -12
  286. package/esm2022/mapbox/lib/mapbox.injection.store.mjs +5 -5
  287. package/esm2022/mapbox/lib/mapbox.injection.store.provide.mjs +9 -8
  288. package/esm2022/mapbox/lib/mapbox.layout.component.mjs +93 -117
  289. package/esm2022/mapbox/lib/mapbox.layout.drawer.component.mjs +8 -8
  290. package/esm2022/mapbox/lib/mapbox.layout.resize.sync.directive.mjs +9 -8
  291. package/esm2022/mapbox/lib/mapbox.marker.component.mjs +69 -72
  292. package/esm2022/mapbox/lib/mapbox.marker.mjs +2 -2
  293. package/esm2022/mapbox/lib/mapbox.markers.component.mjs +22 -36
  294. package/esm2022/mapbox/lib/mapbox.menu.component.mjs +33 -31
  295. package/esm2022/mapbox/lib/mapbox.mjs +1 -1
  296. package/esm2022/mapbox/lib/mapbox.module.mjs +24 -61
  297. package/esm2022/mapbox/lib/mapbox.options.mjs +2 -0
  298. package/esm2022/mapbox/lib/mapbox.providers.mjs +25 -0
  299. package/esm2022/mapbox/lib/mapbox.rxjs.mjs +1 -1
  300. package/esm2022/mapbox/lib/mapbox.service.mjs +5 -8
  301. package/esm2022/mapbox/lib/mapbox.store.map.directive.mjs +7 -6
  302. package/esm2022/mapbox/lib/mapbox.store.mjs +39 -15
  303. package/esm2022/mapbox/lib/mapbox.store.provide.mjs +9 -8
  304. package/esm2022/table/lib/date/date.table.column.header.component.mjs +27 -21
  305. package/esm2022/table/lib/date/daterange.table.cell.input.component.mjs +39 -46
  306. package/esm2022/table/lib/date/table.date.module.mjs +8 -58
  307. package/esm2022/table/lib/table.cell.action.component.mjs +13 -10
  308. package/esm2022/table/lib/table.cell.input.component.mjs +13 -10
  309. package/esm2022/table/lib/table.cell.summaryend.component.mjs +13 -10
  310. package/esm2022/table/lib/table.cell.summarystart.component.mjs +13 -10
  311. package/esm2022/table/lib/table.column.directive.mjs +10 -17
  312. package/esm2022/table/lib/table.column.footer.component.mjs +13 -10
  313. package/esm2022/table/lib/table.column.header.component.mjs +13 -10
  314. package/esm2022/table/lib/table.component.mjs +31 -24
  315. package/esm2022/table/lib/table.directive.mjs +16 -22
  316. package/esm2022/table/lib/table.item.action.component.mjs +20 -17
  317. package/esm2022/table/lib/table.item.cell.component.mjs +19 -26
  318. package/esm2022/table/lib/table.item.directive.mjs +10 -17
  319. package/esm2022/table/lib/table.item.header.component.mjs +15 -11
  320. package/esm2022/table/lib/table.module.mjs +11 -55
  321. package/esm2022/table/lib/table.store.mjs +8 -8
  322. package/fesm2022/dereekb-dbx-web-calendar.mjs +69 -110
  323. package/fesm2022/dereekb-dbx-web-calendar.mjs.map +1 -1
  324. package/fesm2022/dereekb-dbx-web-mapbox.mjs +340 -365
  325. package/fesm2022/dereekb-dbx-web-mapbox.mjs.map +1 -1
  326. package/fesm2022/dereekb-dbx-web-table.mjs +230 -317
  327. package/fesm2022/dereekb-dbx-web-table.mjs.map +1 -1
  328. package/fesm2022/dereekb-dbx-web.mjs +8063 -8083
  329. package/fesm2022/dereekb-dbx-web.mjs.map +1 -1
  330. package/lib/action/action.confirm.directive.d.ts +4 -5
  331. package/lib/action/action.module.d.ts +7 -10
  332. package/lib/action/key.trigger.directive.d.ts +1 -1
  333. package/lib/action/snackbar/_snackbar.scss +3 -3
  334. package/lib/action/snackbar/action.snackbar.component.d.ts +15 -14
  335. package/lib/action/snackbar/action.snackbar.directive.d.ts +5 -7
  336. package/lib/action/snackbar/action.snackbar.generator.d.ts +9 -9
  337. package/lib/action/snackbar/action.snackbar.module.d.ts +1 -6
  338. package/lib/action/transition/action.transition.module.d.ts +7 -6
  339. package/lib/action/transition/transition.safety.dialog.component.d.ts +5 -9
  340. package/lib/action/transition/transition.safety.directive.d.ts +10 -7
  341. package/lib/button/_button.scss +3 -3
  342. package/lib/button/button.component.d.ts +16 -21
  343. package/lib/button/button.module.d.ts +10 -7
  344. package/lib/button/{button.spacer.component.d.ts → button.spacer.directive.d.ts} +1 -1
  345. package/lib/button/icon/icon.button.component.d.ts +1 -1
  346. package/lib/button/icon/icon.button.module.d.ts +4 -4
  347. package/lib/button/index.d.ts +1 -1
  348. package/lib/button/progress/abstract.progress.button.directive.d.ts +25 -0
  349. package/lib/button/progress/bar.button.component.d.ts +5 -4
  350. package/lib/button/progress/bar.button.component.scss +1 -1
  351. package/lib/button/progress/button.progress.config.d.ts +62 -34
  352. package/lib/button/progress/button.progress.module.d.ts +4 -10
  353. package/lib/button/progress/button.progress.providers.d.ts +9 -0
  354. package/lib/button/progress/index.d.ts +1 -0
  355. package/lib/button/progress/spinner.button.component.d.ts +18 -7
  356. package/lib/button/progress/spinner.button.component.scss +34 -7
  357. package/lib/error/_error.scss +3 -3
  358. package/lib/error/default.error.widget.component.d.ts +3 -3
  359. package/lib/error/error.action.directive.d.ts +3 -3
  360. package/lib/error/error.component.d.ts +21 -28
  361. package/lib/error/error.details.component.d.ts +2 -2
  362. package/lib/error/error.loading.directive.d.ts +8 -8
  363. package/lib/error/error.module.d.ts +4 -7
  364. package/lib/error/error.popover.component.d.ts +6 -6
  365. package/lib/error/error.snackbar.action.directive.d.ts +1 -1
  366. package/lib/error/error.snackbar.component.d.ts +12 -23
  367. package/lib/error/error.snackbar.service.d.ts +1 -0
  368. package/lib/error/error.view.component.d.ts +10 -12
  369. package/lib/error/error.widget.component.d.ts +4 -8
  370. package/lib/error/error.widget.service.d.ts +1 -1
  371. package/lib/error/state.d.ts +3 -2
  372. package/lib/extension/calendar/_calendar.scss +20 -20
  373. package/lib/extension/download/text/download.text.component.d.ts +16 -14
  374. package/lib/extension/download/text/download.text.module.d.ts +4 -6
  375. package/lib/extension/model/index.d.ts +1 -1
  376. package/lib/extension/model/model.providers.d.ts +13 -0
  377. package/lib/extension/model/model.tracker.d.ts +7 -7
  378. package/lib/extension/model/model.tracker.service.d.ts +2 -2
  379. package/lib/extension/model/model.tracker.view.storage.d.ts +4 -1
  380. package/lib/extension/model/model.types.d.ts +6 -6
  381. package/lib/extension/model/model.types.service.d.ts +1 -1
  382. package/lib/extension/model/state/actions/actions.d.ts +1 -1
  383. package/lib/extension/model/state/actions/model.actions.d.ts +5 -5
  384. package/lib/extension/model/state/effects/tracker.effects.d.ts +1 -1
  385. package/lib/extension/model/state/reducers/model.module.config.d.ts +1 -1
  386. package/lib/extension/structure/structure.body.directive.d.ts +1 -1
  387. package/lib/extension/structure/structure.module.d.ts +4 -2
  388. package/lib/extension/structure/structure.structure.directive.d.ts +5 -2
  389. package/lib/extension/table/_table.scss +3 -3
  390. package/lib/extension/widget/widget.component.d.ts +5 -9
  391. package/lib/extension/widget/widget.list.component.d.ts +8 -4
  392. package/lib/extension/widget/widget.module.d.ts +8 -4
  393. package/lib/index.d.ts +1 -1
  394. package/lib/interaction/dialog/_dialog.scss +3 -3
  395. package/lib/interaction/dialog/dialog.action.directive.d.ts +7 -6
  396. package/lib/interaction/dialog/dialog.content.close.component.d.ts +4 -6
  397. package/lib/interaction/dialog/{dialog.content.component.d.ts → dialog.content.directive.d.ts} +3 -2
  398. package/lib/interaction/dialog/dialog.content.footer.component.d.ts +10 -10
  399. package/lib/interaction/dialog/dialog.module.d.ts +2 -9
  400. package/lib/interaction/dialog/index.d.ts +1 -1
  401. package/lib/interaction/filter/_filter.scss +3 -3
  402. package/lib/interaction/filter/filter.config.d.ts +62 -0
  403. package/lib/interaction/filter/filter.menu.d.ts +3 -3
  404. package/lib/interaction/filter/filter.module.d.ts +2 -11
  405. package/lib/interaction/filter/filter.partial.d.ts +5 -7
  406. package/lib/interaction/filter/filter.partial.list.component.d.ts +1 -1
  407. package/lib/interaction/filter/filter.partial.menu.component.d.ts +5 -5
  408. package/lib/interaction/filter/filter.popover.button.component.d.ts +5 -7
  409. package/lib/interaction/filter/filter.popover.button.directive.d.ts +7 -6
  410. package/lib/interaction/filter/filter.popover.component.d.ts +15 -71
  411. package/lib/interaction/filter/filter.preset.directive.d.ts +7 -11
  412. package/lib/interaction/filter/filter.preset.list.component.d.ts +1 -1
  413. package/lib/interaction/filter/filter.preset.menu.component.d.ts +5 -5
  414. package/lib/interaction/filter/filter.wrapper.component.d.ts +5 -5
  415. package/lib/interaction/filter/index.d.ts +1 -0
  416. package/lib/interaction/interaction.module.d.ts +13 -4
  417. package/lib/interaction/popover/_popover.scss +3 -3
  418. package/lib/interaction/popover/abstract.popover.ref.directive.d.ts +3 -4
  419. package/lib/interaction/popover/index.d.ts +1 -1
  420. package/lib/interaction/popover/popover.action.directive.d.ts +7 -6
  421. package/lib/interaction/popover/popover.close.component.d.ts +1 -1
  422. package/lib/interaction/popover/popover.component.d.ts +15 -9
  423. package/lib/interaction/popover/popover.content.component.d.ts +6 -4
  424. package/lib/interaction/popover/popover.content.module.d.ts +2 -11
  425. package/lib/interaction/popover/popover.controls.directive.d.ts +3 -2
  426. package/lib/interaction/popover/popover.coordinator.component.d.ts +2 -2
  427. package/lib/interaction/popover/popover.header.component.d.ts +4 -3
  428. package/lib/interaction/popover/popover.module.d.ts +2 -11
  429. package/lib/interaction/popover/popover.scroll.content.directive.d.ts +13 -0
  430. package/lib/interaction/popover/popover.service.d.ts +4 -4
  431. package/lib/interaction/popup/_popup.scss +6 -6
  432. package/lib/interaction/popup/popup.component.d.ts +19 -19
  433. package/lib/interaction/popup/popup.content.component.d.ts +2 -1
  434. package/lib/interaction/popup/popup.controls.buttons.component.d.ts +3 -1
  435. package/lib/interaction/popup/popup.controls.component.d.ts +2 -2
  436. package/lib/interaction/popup/popup.coordinator.component.d.ts +3 -2
  437. package/lib/interaction/popup/popup.coordinator.service.d.ts +1 -1
  438. package/lib/interaction/popup/popup.d.ts +7 -6
  439. package/lib/interaction/popup/popup.module.d.ts +1 -10
  440. package/lib/interaction/popup/popup.position.strategy.d.ts +2 -2
  441. package/lib/interaction/popup/popup.service.d.ts +4 -4
  442. package/lib/interaction/prompt/_prompt.scss +4 -4
  443. package/lib/interaction/prompt/index.d.ts +1 -1
  444. package/lib/interaction/prompt/prompt.box.directive.d.ts +6 -0
  445. package/lib/interaction/prompt/prompt.button.confirm.directive.d.ts +1 -1
  446. package/lib/interaction/prompt/prompt.component.d.ts +3 -3
  447. package/lib/interaction/prompt/prompt.confirm.component.d.ts +11 -23
  448. package/lib/interaction/prompt/prompt.confirm.dialog.component.d.ts +2 -3
  449. package/lib/interaction/prompt/prompt.confirm.directive.d.ts +9 -5
  450. package/lib/interaction/prompt/prompt.module.d.ts +2 -11
  451. package/lib/interaction/prompt/prompt.page.component.d.ts +1 -1
  452. package/lib/interaction/style/_style.scss +6 -6
  453. package/lib/keypress/keydown.listener.directive.d.ts +1 -1
  454. package/lib/keypress/keypress.module.d.ts +4 -2
  455. package/lib/layout/bar/_bar.scss +8 -12
  456. package/lib/layout/bar/bar.directive.d.ts +3 -3
  457. package/lib/layout/bar/bar.header.component.d.ts +4 -5
  458. package/lib/layout/bar/bar.layout.module.d.ts +2 -5
  459. package/lib/layout/bar/pagebar.component.d.ts +3 -3
  460. package/lib/layout/block/_block.scss +3 -3
  461. package/lib/layout/block/block.layout.module.d.ts +3 -4
  462. package/lib/layout/block/two.block.component.d.ts +8 -8
  463. package/lib/layout/card/_card.scss +3 -3
  464. package/lib/layout/card/card.box.component.d.ts +3 -3
  465. package/lib/layout/card/card.box.container.directive.d.ts +8 -0
  466. package/lib/layout/card/card.box.layout.module.d.ts +2 -4
  467. package/lib/layout/card/index.d.ts +1 -1
  468. package/lib/layout/column/_column.scss +3 -3
  469. package/lib/layout/column/column.layout.module.d.ts +2 -2
  470. package/lib/layout/column/one/one.column.component.d.ts +3 -3
  471. package/lib/layout/column/one/one.column.module.d.ts +4 -3
  472. package/lib/layout/column/two/index.d.ts +1 -1
  473. package/lib/layout/column/two/two.column.back.directive.d.ts +3 -3
  474. package/lib/layout/column/two/two.column.component.d.ts +37 -20
  475. package/lib/layout/column/two/two.column.context.directive.d.ts +4 -7
  476. package/lib/layout/column/two/two.column.full.left.directive.d.ts +4 -8
  477. package/lib/layout/column/two/two.column.head.directive.d.ts +11 -0
  478. package/lib/layout/column/two/two.column.module.d.ts +2 -8
  479. package/lib/layout/column/two/two.column.right.component.d.ts +12 -14
  480. package/lib/layout/column/two/two.column.sref.directive.d.ts +3 -2
  481. package/lib/layout/column/two/two.column.sref.showright.directive.d.ts +3 -4
  482. package/lib/layout/column/two/two.column.store.d.ts +17 -9
  483. package/lib/layout/content/_content.scss +10 -10
  484. package/lib/layout/content/content.border.directive.d.ts +3 -2
  485. package/lib/layout/content/content.box.directive.d.ts +3 -3
  486. package/lib/layout/content/content.container.directive.d.ts +5 -4
  487. package/lib/layout/content/content.directive.d.ts +1 -1
  488. package/lib/layout/content/content.elevate.directive.d.ts +2 -2
  489. package/lib/layout/content/content.layout.module.d.ts +1 -2
  490. package/lib/layout/content/content.page.directive.d.ts +1 -1
  491. package/lib/layout/content/content.pit.directive.d.ts +2 -2
  492. package/lib/layout/flag/_flag.scss +3 -3
  493. package/lib/layout/flag/flag.component.d.ts +2 -2
  494. package/lib/layout/flag/flag.layout.module.d.ts +1 -6
  495. package/lib/layout/flag/flag.prompt.component.d.ts +4 -3
  496. package/lib/layout/flex/_flex.scss +3 -3
  497. package/lib/layout/flex/flex.group.directive.d.ts +7 -14
  498. package/lib/layout/flex/flex.layout.module.d.ts +4 -2
  499. package/lib/layout/flex/flex.size.directive.d.ts +3 -2
  500. package/lib/layout/item/_item.scss +3 -3
  501. package/lib/layout/item/index.d.ts +0 -1
  502. package/lib/layout/item/item.icon.component.d.ts +3 -3
  503. package/lib/layout/layout.module.d.ts +5 -7
  504. package/lib/layout/list/_list.scss +19 -6
  505. package/lib/layout/list/grid/index.d.ts +2 -0
  506. package/lib/layout/list/{list.grid.view.component.d.ts → grid/list.grid.view.component.d.ts} +23 -31
  507. package/lib/layout/list/grid/list.grid.view.directive.d.ts +24 -0
  508. package/lib/layout/list/group/index.d.ts +3 -0
  509. package/lib/layout/list/{list.view.value.group.d.ts → group/list.view.value.group.d.ts} +2 -2
  510. package/lib/layout/list/{list.view.value.group.title.d.ts → group/list.view.value.group.title.d.ts} +1 -1
  511. package/lib/layout/list/group/list.view.value.group.title.directive.d.ts +15 -0
  512. package/lib/layout/list/group/list.view.value.group.title.header.component.d.ts +21 -0
  513. package/lib/layout/list/index.d.ts +5 -9
  514. package/lib/layout/list/list.component.d.ts +54 -50
  515. package/lib/layout/list/list.content.empty.component.d.ts +1 -1
  516. package/lib/layout/list/list.directive.d.ts +35 -15
  517. package/lib/layout/list/list.layout.module.d.ts +27 -18
  518. package/lib/layout/list/list.module.d.ts +13 -0
  519. package/lib/layout/list/list.view.d.ts +8 -8
  520. package/lib/layout/list/list.view.directive.d.ts +14 -9
  521. package/lib/layout/list/list.view.selection.directive.d.ts +12 -3
  522. package/lib/layout/list/list.view.value.component.d.ts +32 -39
  523. package/lib/layout/list/list.view.value.d.ts +4 -1
  524. package/lib/layout/list/list.view.value.directive.d.ts +5 -7
  525. package/lib/layout/list/list.view.value.selection.component.d.ts +14 -13
  526. package/lib/layout/list/list.wrapper.d.ts +13 -4
  527. package/lib/layout/list/meta/index.d.ts +1 -0
  528. package/lib/layout/list/{list.view.meta.icon.component.d.ts → meta/list.view.meta.icon.component.d.ts} +2 -2
  529. package/lib/layout/list/modifier/index.d.ts +4 -0
  530. package/lib/layout/list/modifier/list.modifier.module.d.ts +12 -0
  531. package/lib/layout/list/{list.view.value.modifier.directive.d.ts → modifier/list.view.value.modifier.directive.d.ts} +13 -12
  532. package/lib/layout/list/{list.view.value.modifier.ripple.directive.d.ts → modifier/list.view.value.modifier.ripple.directive.d.ts} +5 -6
  533. package/lib/layout/list/{list.view.value.modifier.selection.directive.d.ts → modifier/list.view.value.modifier.selection.directive.d.ts} +5 -6
  534. package/lib/layout/section/_section.scss +3 -3
  535. package/lib/layout/section/section.component.d.ts +3 -2
  536. package/lib/layout/section/section.d.ts +28 -6
  537. package/lib/layout/section/section.header.component.d.ts +12 -11
  538. package/lib/layout/section/section.intro.component.d.ts +7 -8
  539. package/lib/layout/section/section.layout.module.d.ts +2 -7
  540. package/lib/layout/section/section.page.component.d.ts +4 -3
  541. package/lib/layout/section/subsection.component.d.ts +1 -1
  542. package/lib/layout/step/_step.scss +3 -3
  543. package/lib/layout/step/step.component.d.ts +6 -5
  544. package/lib/layout/step/step.layout.module.d.ts +4 -3
  545. package/lib/layout/style/_style.scss +20 -3
  546. package/lib/layout/style/index.d.ts +1 -0
  547. package/lib/layout/style/spacer.directive.d.ts +1 -1
  548. package/lib/layout/style/style.body.directive.d.ts +8 -8
  549. package/lib/layout/style/style.color.directive.d.ts +3 -3
  550. package/lib/layout/style/style.d.ts +48 -1
  551. package/lib/layout/style/style.directive.d.ts +5 -5
  552. package/lib/layout/style/style.layout.module.d.ts +1 -2
  553. package/lib/layout/style/style.providers.d.ts +19 -0
  554. package/lib/layout/style/style.service.d.ts +28 -18
  555. package/lib/layout/style/style.set.directive.d.ts +18 -16
  556. package/lib/layout/text/_text.scss +8 -8
  557. package/lib/layout/text/address.component.d.ts +2 -2
  558. package/lib/layout/text/detail.block.component.d.ts +1 -1
  559. package/lib/layout/text/detail.block.header.component.d.ts +1 -1
  560. package/lib/layout/text/icon.spacer.component.d.ts +1 -1
  561. package/lib/layout/text/label.block.component.d.ts +1 -1
  562. package/lib/layout/text/linkify.component.d.ts +3 -2
  563. package/lib/layout/text/text.chip.directive.d.ts +1 -1
  564. package/lib/layout/text/text.chips.component.d.ts +3 -4
  565. package/lib/layout/text/text.module.d.ts +1 -5
  566. package/lib/loading/_loading.scss +3 -3
  567. package/lib/loading/basic-loading.component.d.ts +17 -36
  568. package/lib/loading/loading-progress.component.d.ts +12 -14
  569. package/lib/loading/loading.action.directive.d.ts +2 -4
  570. package/lib/loading/loading.component.d.ts +31 -29
  571. package/lib/loading/loading.module.d.ts +1 -5
  572. package/lib/router/layout/anchor/_anchor.scss +3 -3
  573. package/lib/router/layout/anchor/anchor.component.d.ts +7 -12
  574. package/lib/router/layout/anchor/anchor.content.component.d.ts +4 -3
  575. package/lib/router/layout/anchor/anchor.icon.component.d.ts +1 -1
  576. package/lib/router/layout/anchor/anchor.link.component.d.ts +3 -3
  577. package/lib/router/layout/anchor/anchor.module.d.ts +14 -5
  578. package/lib/router/layout/anchor/anchor.segue.directive.d.ts +5 -6
  579. package/lib/router/layout/anchorlist/_anchorlist.scss +6 -6
  580. package/lib/router/layout/anchorlist/anchorlist.component.d.ts +6 -9
  581. package/lib/router/layout/anchorlist/anchorlist.module.d.ts +4 -9
  582. package/lib/router/layout/list/list.module.d.ts +4 -1
  583. package/lib/router/layout/list/router.list.directive.d.ts +6 -8
  584. package/lib/router/layout/navbar/_navbar.scss +3 -3
  585. package/lib/router/layout/navbar/navbar.component.d.ts +22 -29
  586. package/lib/router/layout/navbar/navbar.module.d.ts +4 -9
  587. package/lib/router/layout/sidenav/_sidenav.scss +8 -8
  588. package/lib/router/layout/sidenav/sidenav.button.component.d.ts +3 -4
  589. package/lib/router/layout/sidenav/sidenav.component.d.ts +19 -18
  590. package/lib/router/layout/sidenav/sidenav.ifdisplaymode.directive.d.ts +7 -7
  591. package/lib/router/layout/sidenav/sidenav.module.d.ts +1 -14
  592. package/lib/router/layout/sidenav/sidenav.page.component.d.ts +7 -10
  593. package/lib/router/layout/sidenav/sidenav.pagebar.component.d.ts +2 -2
  594. package/lib/router/provider/ngrouter/anchor.component.d.ts +1 -1
  595. package/lib/router/provider/ngrouter/angular.router.providers.d.ts +7 -0
  596. package/lib/router/provider/ngrouter/index.d.ts +1 -1
  597. package/lib/router/provider/router.provider.config.d.ts +7 -0
  598. package/lib/router/provider/uirouter/anchor.component.d.ts +6 -5
  599. package/lib/router/provider/uirouter/index.d.ts +1 -1
  600. package/lib/router/provider/uirouter/uirouter.router.providers.d.ts +7 -0
  601. package/lib/screen/index.d.ts +1 -1
  602. package/lib/screen/screen.providers.d.ts +15 -0
  603. package/lib/screen/screen.service.d.ts +7 -7
  604. package/lib/style/_all-typography.scss +1 -1
  605. package/lib/style/_root-variables.scss +13 -13
  606. package/lib/style/_theming.scss +4 -2
  607. package/mapbox/lib/index.d.ts +2 -1
  608. package/mapbox/lib/mapbox.change.service.d.ts +3 -3
  609. package/mapbox/lib/mapbox.d.ts +33 -19
  610. package/mapbox/lib/mapbox.injection.component.d.ts +2 -4
  611. package/mapbox/lib/mapbox.injection.store.provide.d.ts +1 -1
  612. package/mapbox/lib/mapbox.layout.component.d.ts +36 -34
  613. package/mapbox/lib/mapbox.layout.drawer.component.d.ts +2 -2
  614. package/mapbox/lib/mapbox.layout.resize.sync.directive.d.ts +1 -1
  615. package/mapbox/lib/mapbox.marker.component.d.ts +6 -11
  616. package/mapbox/lib/mapbox.marker.d.ts +13 -13
  617. package/mapbox/lib/mapbox.markers.component.d.ts +5 -11
  618. package/mapbox/lib/mapbox.menu.component.d.ts +9 -11
  619. package/mapbox/lib/mapbox.module.d.ts +2 -12
  620. package/mapbox/lib/mapbox.options.d.ts +11 -0
  621. package/mapbox/lib/mapbox.providers.d.ts +17 -0
  622. package/mapbox/lib/mapbox.rxjs.d.ts +6 -6
  623. package/mapbox/lib/mapbox.service.d.ts +1 -1
  624. package/mapbox/lib/mapbox.store.d.ts +28 -6
  625. package/mapbox/lib/mapbox.store.map.directive.d.ts +1 -1
  626. package/mapbox/lib/mapbox.store.provide.d.ts +1 -1
  627. package/package.json +14 -16
  628. package/table/lib/date/date.table.column.header.component.d.ts +3 -3
  629. package/table/lib/date/daterange.table.cell.input.component.d.ts +14 -12
  630. package/table/lib/date/table.date.module.d.ts +1 -9
  631. package/table/lib/table.cell.action.component.d.ts +2 -1
  632. package/table/lib/table.cell.input.component.d.ts +2 -1
  633. package/table/lib/table.cell.summaryend.component.d.ts +2 -1
  634. package/table/lib/table.cell.summarystart.component.d.ts +2 -1
  635. package/table/lib/table.column.directive.d.ts +3 -6
  636. package/table/lib/table.column.footer.component.d.ts +3 -3
  637. package/table/lib/table.column.header.component.d.ts +3 -3
  638. package/table/lib/table.component.d.ts +13 -8
  639. package/table/lib/table.directive.d.ts +5 -4
  640. package/table/lib/table.item.action.component.d.ts +4 -2
  641. package/table/lib/table.item.cell.component.d.ts +3 -5
  642. package/table/lib/table.item.directive.d.ts +3 -6
  643. package/table/lib/table.item.header.component.d.ts +2 -1
  644. package/table/lib/table.module.d.ts +4 -6
  645. package/calendar/esm2022/dereekb-dbx-web-calendar.mjs +0 -5
  646. package/calendar/esm2022/index.mjs +0 -2
  647. package/calendar/esm2022/lib/calendar.base.component.mjs +0 -54
  648. package/calendar/esm2022/lib/calendar.component.mjs +0 -54
  649. package/calendar/esm2022/lib/calendar.mjs +0 -30
  650. package/calendar/esm2022/lib/calendar.module.mjs +0 -87
  651. package/calendar/esm2022/lib/calendar.store.mjs +0 -174
  652. package/calendar/esm2022/lib/index.mjs +0 -6
  653. package/calendar/fesm2022/dereekb-dbx-web-calendar.mjs +0 -385
  654. package/calendar/fesm2022/dereekb-dbx-web-calendar.mjs.map +0 -1
  655. package/calendar/package.json +0 -21
  656. package/esm2022/lib/button/button.spacer.component.mjs +0 -19
  657. package/esm2022/lib/button/progress/base.progress.button.directive.mjs +0 -107
  658. package/esm2022/lib/extension/model/model.module.mjs +0 -66
  659. package/esm2022/lib/interaction/dialog/dialog.content.component.mjs +0 -23
  660. package/esm2022/lib/interaction/popover/popover.scroll.content.component.mjs +0 -48
  661. package/esm2022/lib/interaction/prompt/prompt.box.component.mjs +0 -25
  662. package/esm2022/lib/layout/card/card.box.container.component.mjs +0 -25
  663. package/esm2022/lib/layout/column/two/two.column.head.component.mjs +0 -32
  664. package/esm2022/lib/layout/item/item.layout.module.mjs +0 -19
  665. package/esm2022/lib/layout/list/list.grid.view.component.mjs +0 -112
  666. package/esm2022/lib/layout/list/list.grid.view.directive.mjs +0 -15
  667. package/esm2022/lib/layout/list/list.view.meta.icon.component.mjs +0 -35
  668. package/esm2022/lib/layout/list/list.view.value.group.mjs +0 -32
  669. package/esm2022/lib/layout/list/list.view.value.group.title.directive.mjs +0 -131
  670. package/esm2022/lib/layout/list/list.view.value.group.title.mjs +0 -2
  671. package/esm2022/lib/layout/list/list.view.value.modifier.directive.mjs +0 -77
  672. package/esm2022/lib/layout/list/list.view.value.modifier.ripple.directive.mjs +0 -41
  673. package/esm2022/lib/layout/list/list.view.value.modifier.selection.directive.mjs +0 -39
  674. package/esm2022/lib/router/provider/ngrouter/angular.router.module.mjs +0 -36
  675. package/esm2022/lib/router/provider/uirouter/uirouter.router.module.mjs +0 -36
  676. package/esm2022/lib/screen/screen.module.mjs +0 -24
  677. package/esm2022/mapbox/lib/options.mjs +0 -2
  678. package/lib/button/progress/base.progress.button.directive.d.ts +0 -32
  679. package/lib/extension/model/model.module.d.ts +0 -19
  680. package/lib/interaction/popover/popover.scroll.content.component.d.ts +0 -13
  681. package/lib/interaction/prompt/prompt.box.component.d.ts +0 -6
  682. package/lib/layout/card/card.box.container.component.d.ts +0 -8
  683. package/lib/layout/column/two/two.column.head.component.d.ts +0 -10
  684. package/lib/layout/item/item.layout.module.d.ts +0 -9
  685. package/lib/layout/list/list.grid.view.directive.d.ts +0 -10
  686. package/lib/layout/list/list.view.value.group.title.directive.d.ts +0 -35
  687. package/lib/router/provider/ngrouter/angular.router.module.d.ts +0 -12
  688. package/lib/router/provider/uirouter/uirouter.router.module.d.ts +0 -12
  689. package/lib/screen/screen.module.d.ts +0 -9
  690. package/mapbox/esm2022/dereekb-dbx-web-mapbox.mjs +0 -5
  691. package/mapbox/esm2022/index.mjs +0 -2
  692. package/mapbox/esm2022/lib/index.mjs +0 -21
  693. package/mapbox/esm2022/lib/mapbox.change.service.mjs +0 -40
  694. package/mapbox/esm2022/lib/mapbox.injection.component.mjs +0 -28
  695. package/mapbox/esm2022/lib/mapbox.injection.store.mjs +0 -39
  696. package/mapbox/esm2022/lib/mapbox.injection.store.provide.mjs +0 -47
  697. package/mapbox/esm2022/lib/mapbox.layout.component.mjs +0 -185
  698. package/mapbox/esm2022/lib/mapbox.layout.drawer.component.mjs +0 -21
  699. package/mapbox/esm2022/lib/mapbox.layout.resize.sync.directive.mjs +0 -32
  700. package/mapbox/esm2022/lib/mapbox.marker.component.mjs +0 -135
  701. package/mapbox/esm2022/lib/mapbox.marker.mjs +0 -16
  702. package/mapbox/esm2022/lib/mapbox.markers.component.mjs +0 -58
  703. package/mapbox/esm2022/lib/mapbox.menu.component.mjs +0 -91
  704. package/mapbox/esm2022/lib/mapbox.mjs +0 -19
  705. package/mapbox/esm2022/lib/mapbox.module.mjs +0 -108
  706. package/mapbox/esm2022/lib/mapbox.rxjs.mjs +0 -53
  707. package/mapbox/esm2022/lib/mapbox.service.mjs +0 -36
  708. package/mapbox/esm2022/lib/mapbox.store.map.directive.mjs +0 -33
  709. package/mapbox/esm2022/lib/mapbox.store.mjs +0 -525
  710. package/mapbox/esm2022/lib/mapbox.store.provide.mjs +0 -47
  711. package/mapbox/esm2022/lib/mapbox.util.mjs +0 -15
  712. package/mapbox/esm2022/lib/options.mjs +0 -2
  713. package/mapbox/fesm2022/dereekb-dbx-web-mapbox.mjs +0 -1449
  714. package/mapbox/fesm2022/dereekb-dbx-web-mapbox.mjs.map +0 -1
  715. package/mapbox/lib/options.d.ts +0 -7
  716. package/mapbox/package.json +0 -21
  717. package/table/esm2022/dereekb-dbx-web-table.mjs +0 -5
  718. package/table/esm2022/index.mjs +0 -2
  719. package/table/esm2022/lib/date/date.table.column.header.component.mjs +0 -49
  720. package/table/esm2022/lib/date/daterange.table.cell.input.component.mjs +0 -161
  721. package/table/esm2022/lib/date/index.mjs +0 -4
  722. package/table/esm2022/lib/date/table.date.module.mjs +0 -68
  723. package/table/esm2022/lib/index.mjs +0 -18
  724. package/table/esm2022/lib/table.cell.action.component.mjs +0 -25
  725. package/table/esm2022/lib/table.cell.input.component.mjs +0 -28
  726. package/table/esm2022/lib/table.cell.summaryend.component.mjs +0 -25
  727. package/table/esm2022/lib/table.cell.summarystart.component.mjs +0 -28
  728. package/table/esm2022/lib/table.column.directive.mjs +0 -27
  729. package/table/esm2022/lib/table.column.footer.component.mjs +0 -32
  730. package/table/esm2022/lib/table.column.header.component.mjs +0 -32
  731. package/table/esm2022/lib/table.component.mjs +0 -55
  732. package/table/esm2022/lib/table.directive.mjs +0 -34
  733. package/table/esm2022/lib/table.item.action.component.mjs +0 -32
  734. package/table/esm2022/lib/table.item.cell.component.mjs +0 -36
  735. package/table/esm2022/lib/table.item.directive.mjs +0 -27
  736. package/table/esm2022/lib/table.item.header.component.mjs +0 -24
  737. package/table/esm2022/lib/table.mjs +0 -2
  738. package/table/esm2022/lib/table.module.mjs +0 -74
  739. package/table/esm2022/lib/table.store.mjs +0 -53
  740. package/table/fesm2022/dereekb-dbx-web-table.mjs +0 -704
  741. package/table/fesm2022/dereekb-dbx-web-table.mjs.map +0 -1
  742. package/table/package.json +0 -21
@@ -1,1449 +0,0 @@
1
- import * as i0 from '@angular/core';
2
- import { inject, Injectable, Component, ChangeDetectionStrategy, Directive, Injector, Optional, SkipSelf, EventEmitter, ElementRef, Output, ViewChild, Input, NgZone, ChangeDetectorRef, NgModule } from '@angular/core';
3
- import { asObservable, cleanup, filterMaybe, onTrueToFalse, SubscriptionObject, distinctUntilMapHasDifferentKeys } from '@dereekb/rxjs';
4
- import { distinctUntilChanged, switchMap, map, combineLatestWith, shareReplay, NEVER, defaultIfEmpty, tap, EMPTY, interval, of, first, combineLatest, filter, startWith, throttleTime, Subject, merge, BehaviorSubject } from 'rxjs';
5
- import { LAT_LONG_10M_PRECISION, latLngPointFunction, roundNumberToStepFunction, latLngBoundFunction, latLngBoundFromInput, filterUndefinedValues, diffLatLngBoundPoints, latLngBoundCenterPoint, addLatLngPoints, isSameLatLngPoint, isSameVector, vectorMinimumSizeResizeFunction, isSameLatLngBound, isDefaultLatLngPoint, swMostLatLngPoint, neMostLatLngPoint, latLngBoundWrapsMap, isWithinLatLngBoundFunction, overlapsLatLngBoundFunction, latLngPoint, DestroyFunctionObject, getValueFromGetter } from '@dereekb/util';
6
- import { ComponentStore } from '@ngrx/component-store';
7
- import * as MapboxGl from 'mapbox-gl';
8
- import { bounds } from '@placemarkio/geo-viewport';
9
- import * as i1 from '@dereekb/dbx-core';
10
- import { AbstractSubscriptionDirective, safeMarkForCheck, DbxInjectionComponentModule } from '@dereekb/dbx-core';
11
- import * as i1$1 from '@angular/common';
12
- import { CommonModule } from '@angular/common';
13
- import * as i4$1 from 'ngx-mapbox-gl';
14
- import { MapService, MapComponent, NgxMapboxGLModule } from 'ngx-mapbox-gl';
15
- import * as i2 from '@angular/material/sidenav';
16
- import { MatDrawerContainer, MatSidenavModule } from '@angular/material/sidenav';
17
- import * as i3 from '@dereekb/dbx-web';
18
- import { disableRightClickInCdkBackdrop, DbxStyleLayoutModule, DbxRouterAnchorModule } from '@dereekb/dbx-web';
19
- import * as i4 from '@angular/material/button';
20
- import { MatButtonModule } from '@angular/material/button';
21
- import * as i5 from '@angular/material/icon';
22
- import { MatIconModule } from '@angular/material/icon';
23
- import * as i6 from 'angular-resize-event';
24
- import { AngularResizeEventModule } from 'angular-resize-event';
25
- import { MatMenuTrigger } from '@angular/material/menu';
26
-
27
- class DbxMapboxConfig {
28
- defaultStyle;
29
- defaultZoom;
30
- defaultCenter;
31
- defaultStoreRefreshPeriod;
32
- }
33
- const DEFAULT_MAPBOX_STYLE = 'mapbox://styles/mapbox/streets-v12';
34
- const DEFAULT_MAPBOX_CENTER = [30.2690138665, -97.7408297965];
35
- const DEFAULT_MAPBOX_ZOOM = 8;
36
- const DEFAULT_MAPBOX_MAP_STORE_TIMER_REFRESH_PERIOD = 200;
37
- class DbxMapboxService {
38
- _config = inject(DbxMapboxConfig, { optional: true }) ?? {};
39
- get defaultStyle() {
40
- return this._config.defaultStyle ?? DEFAULT_MAPBOX_STYLE;
41
- }
42
- get defaultZoom() {
43
- return this._config.defaultZoom ?? DEFAULT_MAPBOX_ZOOM;
44
- }
45
- get defaultCenter() {
46
- return this._config.defaultCenter ?? DEFAULT_MAPBOX_CENTER;
47
- }
48
- get mapboxMapStoreTimerRefreshPeriod() {
49
- return this._config.defaultStoreRefreshPeriod ?? DEFAULT_MAPBOX_MAP_STORE_TIMER_REFRESH_PERIOD;
50
- }
51
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
52
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxService, providedIn: 'root' });
53
- }
54
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxService, decorators: [{
55
- type: Injectable,
56
- args: [{
57
- providedIn: 'root'
58
- }]
59
- }] });
60
-
61
- function mapboxViewportBoundFunction(config) {
62
- const { mapCanvasSize, tileSize = 512 } = config;
63
- const dimensions = [mapCanvasSize.x, mapCanvasSize.y];
64
- return ({ center, zoom }) => {
65
- const boundingBox = bounds([center.lng, center.lat], zoom, dimensions, tileSize);
66
- const [swLng, swLat, neLng, neLat] = boundingBox;
67
- const result = {
68
- sw: { lat: swLat, lng: swLng },
69
- ne: { lat: neLat, lng: neLng }
70
- };
71
- return result;
72
- };
73
- }
74
-
75
- /**
76
- * Filters the input objects based on their center and zoom values.
77
- *
78
- * This function caches the bounds computations for each of the input values.
79
- *
80
- * @param config
81
- * @returns
82
- */
83
- function filterByMapboxViewportBound(config) {
84
- const { boundDecisionObs: inputBoundDecisionObs, boundFunctionObs: inputBoundFunctionObs, defaultZoom: inputDefaultZoom = 17, readValue, zoomRounding, precision = LAT_LONG_10M_PRECISION } = config;
85
- const _latLngPoint = latLngPointFunction({ wrap: false, validate: false, precision });
86
- const _roundZoom = roundNumberToStepFunction(zoomRounding || { step: 0.5, round: 'floor' });
87
- const boundDecisionObs = asObservable(inputBoundDecisionObs);
88
- const boundFunctionObs = asObservable(inputBoundFunctionObs);
89
- return (input) => {
90
- return boundFunctionObs.pipe(distinctUntilChanged(), switchMap((viewportBoundFunction) => {
91
- const cache = new Map();
92
- return input.pipe(map((values) => {
93
- return values.map((value) => {
94
- const item = readValue(value);
95
- const centerLatLng = _latLngPoint(item.center);
96
- const zoomStep = _roundZoom(item.zoom || inputDefaultZoom);
97
- const cacheKey = `${zoomStep}_${centerLatLng.lat}_${centerLatLng.lng}`;
98
- const cachedValue = cache.get(cacheKey);
99
- let bound;
100
- if (!cachedValue) {
101
- bound = viewportBoundFunction({ center: centerLatLng, zoom: zoomStep });
102
- cache.set(cacheKey, bound);
103
- }
104
- else {
105
- bound = cachedValue;
106
- }
107
- return {
108
- value,
109
- bound
110
- };
111
- });
112
- }), combineLatestWith(boundDecisionObs), map(([items, boundFunction]) => {
113
- const valuesInBounds = [];
114
- items.forEach((item) => {
115
- if (boundFunction(item.bound)) {
116
- valuesInBounds.push(item.value);
117
- }
118
- });
119
- return valuesInBounds;
120
- }));
121
- }), shareReplay(1));
122
- };
123
- }
124
-
125
- /**
126
- * Store used for retrieving information.
127
- */
128
- class DbxMapboxMapStore extends ComponentStore {
129
- dbxMapboxService = inject(DbxMapboxService);
130
- safeLatLngPoint = latLngPointFunction({ wrap: true });
131
- latLngPoint = latLngPointFunction({ wrap: false, validate: false });
132
- latLngBound = latLngBoundFunction({ pointFunction: this.latLngPoint });
133
- constructor() {
134
- super({
135
- lifecycleState: 'init',
136
- moveState: 'init',
137
- zoomState: 'init',
138
- rotateState: 'init',
139
- retainContent: true,
140
- useVirtualBound: true,
141
- boundRefreshSettings: {
142
- throttle: 300,
143
- refreshType: 'always'
144
- }
145
- });
146
- }
147
- // MARK: Effects
148
- setMapService = this.effect((input) => {
149
- return input.pipe(switchMap((service) => {
150
- this._setMapService(service);
151
- if (!service) {
152
- return NEVER;
153
- }
154
- else {
155
- return service.mapLoaded$.pipe(defaultIfEmpty(undefined), map(() => {
156
- this._setLifecycleState('idle');
157
- this._setMoveState('idle');
158
- this._setZoomState('idle');
159
- this._setRotateState('idle');
160
- const map = service.mapInstance;
161
- const listenerPairs = [];
162
- function addListener(type, listener) {
163
- map.on(type, listener);
164
- listenerPairs.push({ type, listener });
165
- }
166
- addListener('idle', () => this._setLifecycleState('idle'));
167
- addListener('render', () => this._setLifecycleState('render'));
168
- addListener('error', (x) => {
169
- this._setError(x.error);
170
- });
171
- addListener('movestart', () => this._setMoveState('moving'));
172
- addListener('moveend', () => this._setMoveState('idle'));
173
- addListener('zoomstart', () => this._setZoomState('zooming'));
174
- addListener('zoomend', () => this._setZoomState('idle'));
175
- addListener('rotatestart', () => this._setRotateState('rotating'));
176
- addListener('rotateend', () => this._setRotateState('idle'));
177
- addListener('click', (x) => this._setClickEvent(x));
178
- addListener('dblclick', (x) => this._setDoubleClickEvent(x));
179
- addListener('contextmenu', (x) => this._setRightClickEvent(x));
180
- const refreshForResize = () => {
181
- const { clientWidth: x, clientHeight: y } = map.getCanvas();
182
- this._setMapCanvasSize({ x, y });
183
- };
184
- addListener('resize', refreshForResize);
185
- refreshForResize();
186
- const subs = [];
187
- return {
188
- service,
189
- listenerPairs,
190
- subs
191
- };
192
- }));
193
- }
194
- }), cleanup(({ service, listenerPairs, subs }) => {
195
- const map = service.mapInstance;
196
- if (map) {
197
- listenerPairs.forEach((x) => {
198
- map.off(x.type, x.listener);
199
- });
200
- }
201
- subs.forEach((sub) => sub.unsubscribe());
202
- }));
203
- });
204
- setStyle = this.effect((input) => {
205
- return input.pipe(switchMap((style) => {
206
- return this.mapInstance$.pipe(tap((map) => {
207
- if (typeof style === 'string') {
208
- map.setStyle(style);
209
- }
210
- else {
211
- map.setStyle(style.style, style.options);
212
- }
213
- }));
214
- }));
215
- });
216
- setCenter = this.effect((input) => {
217
- return input.pipe(switchMap((center) => {
218
- const centerPoint = this.safeLatLngPoint(center);
219
- return this.mapInstance$.pipe(tap((map) => map.setCenter(centerPoint)));
220
- }));
221
- });
222
- setZoom = this.effect((input) => {
223
- return input.pipe(switchMap((zoom) => {
224
- return this.mapInstance$.pipe(tap((map) => map.setZoom(zoom)));
225
- }));
226
- });
227
- setZoomRange = this.effect((input) => {
228
- return input.pipe(switchMap((zoomRange) => {
229
- return this.mapInstance$.pipe(tap((map) => {
230
- map.setMinZoom(zoomRange.min || null);
231
- map.setMaxZoom(zoomRange.max || null);
232
- }));
233
- }));
234
- });
235
- setMinZoom = this.effect((input) => {
236
- return input.pipe(switchMap((zoom) => {
237
- return this.mapInstance$.pipe(tap((map) => map.setMinZoom(zoom)));
238
- }));
239
- });
240
- setMaxZoom = this.effect((input) => {
241
- return input.pipe(switchMap((zoom) => {
242
- return this.mapInstance$.pipe(tap((map) => map.setMaxZoom(zoom)));
243
- }));
244
- });
245
- setKeyboardDisabled = this.effect((input) => {
246
- return input.pipe(switchMap((disabled) => {
247
- return this.mapInstance$.pipe(tap((map) => {
248
- if (disabled === false) {
249
- map.keyboard.enable();
250
- }
251
- else {
252
- map.keyboard.disable();
253
- }
254
- }));
255
- }));
256
- });
257
- setDragRotateDisabled = this.effect((input) => {
258
- return input.pipe(switchMap((disabled) => {
259
- return this.mapInstance$.pipe(tap((map) => {
260
- if (disabled === false) {
261
- map.dragRotate.enable();
262
- }
263
- else {
264
- map.dragRotate.disable();
265
- }
266
- }));
267
- }));
268
- });
269
- setDragPanDisabled = this.effect((input) => {
270
- return input.pipe(switchMap((disabled) => {
271
- return this.mapInstance$.pipe(tap((map) => {
272
- if (disabled === false) {
273
- map.dragPan.enable();
274
- }
275
- else {
276
- map.dragPan.disable();
277
- }
278
- }));
279
- }));
280
- });
281
- setZoomDisabled = this.effect((input) => {
282
- return input.pipe(switchMap((disabled) => {
283
- return this.mapInstance$.pipe(tap((map) => {
284
- if (disabled === false) {
285
- map.scrollZoom.enable();
286
- map.doubleClickZoom.enable();
287
- }
288
- else {
289
- map.scrollZoom.disable();
290
- map.doubleClickZoom.disable();
291
- }
292
- }));
293
- }));
294
- });
295
- setPitch = this.effect((input) => {
296
- return input.pipe(switchMap((pitch) => {
297
- return this.mapInstance$.pipe(tap((map) => map.setPitch(pitch)));
298
- }));
299
- });
300
- setMinPitch = this.effect((input) => {
301
- return input.pipe(switchMap((pitch) => {
302
- return this.mapInstance$.pipe(tap((map) => map.setMinPitch(pitch)));
303
- }));
304
- });
305
- setMaxPitch = this.effect((input) => {
306
- return input.pipe(switchMap((pitch) => {
307
- return this.mapInstance$.pipe(tap((map) => map.setMaxPitch(pitch)));
308
- }));
309
- });
310
- setBearing = this.effect((input) => {
311
- return input.pipe(switchMap((bearing) => {
312
- return this.mapInstance$.pipe(tap((map) => map.setBearing(bearing)));
313
- }));
314
- });
315
- rotateTo = this.effect((input) => {
316
- return input.pipe(switchMap((rotateInput) => {
317
- const rotate = typeof rotateInput === 'number' ? { bearing: rotateInput } : rotateInput;
318
- return this.mapInstance$.pipe(tap((map) => map.rotateTo(rotate.bearing, rotate.options, rotate?.eventData)));
319
- }));
320
- });
321
- resetNorth = this.effect((input) => {
322
- return input.pipe(switchMap((reset) => {
323
- return this.mapInstance$.pipe(tap((map) => map.resetNorth(reset?.options, reset?.eventData)));
324
- }));
325
- });
326
- resetNorthPitch = this.effect((input) => {
327
- return input.pipe(switchMap((reset) => {
328
- return this.mapInstance$.pipe(tap((map) => map.resetNorthPitch(reset?.options, reset?.eventData)));
329
- }));
330
- });
331
- snapToNorth = this.effect((input) => {
332
- return input.pipe(switchMap((snap) => {
333
- return this.mapInstance$.pipe(tap((map) => map.snapToNorth(snap?.options, snap?.eventData)));
334
- }));
335
- });
336
- fitPositions = this.effect((input) => {
337
- return input.pipe(switchMap((x) => {
338
- const boundFromInput = latLngBoundFromInput(x.positions);
339
- if (boundFromInput) {
340
- const bound = this.latLngBound(boundFromInput);
341
- return this.mapInstance$.pipe(tap((map) => map.fitBounds(new MapboxGl.LngLatBounds(bound.sw, bound.ne), x.options, x.eventData)));
342
- }
343
- else {
344
- return EMPTY;
345
- }
346
- }));
347
- });
348
- fitBounds = this.effect((input) => {
349
- return input.pipe(switchMap((x) => {
350
- const bound = this.latLngBound(x.bounds);
351
- return this.mapInstance$.pipe(tap((map) => map.fitBounds(new MapboxGl.LngLatBounds(bound.sw, bound.ne), x.options, x.eventData)));
352
- }));
353
- });
354
- jumpTo = this.effect((input) => {
355
- return input.pipe(switchMap((x) => {
356
- const inputCenter = x.center ?? x.to?.center;
357
- const center = inputCenter ? this.safeLatLngPoint(inputCenter) : undefined;
358
- return this.mapInstance$.pipe(tap((map) => map.jumpTo(filterUndefinedValues({ ...x.to, center }), x.eventData)));
359
- }));
360
- });
361
- easeTo = this.effect((input) => {
362
- return input.pipe(switchMap((x) => {
363
- const inputCenter = x.center ?? x.to?.center;
364
- const center = inputCenter ? this.safeLatLngPoint(inputCenter) : undefined;
365
- return this.mapInstance$.pipe(tap((map) => map.easeTo(filterUndefinedValues({ ...x.to, center }), x.eventData)));
366
- }));
367
- });
368
- flyTo = this.effect((input) => {
369
- return input.pipe(switchMap((x) => {
370
- const inputCenter = x.center ?? x.to?.center;
371
- const center = inputCenter ? this.safeLatLngPoint(inputCenter) : undefined;
372
- return this.mapInstance$.pipe(tap((map) => map.flyTo(filterUndefinedValues({ ...x.to, center }), x.eventData)));
373
- }));
374
- });
375
- resetPitchAndBearing = this.effect((input) => {
376
- return input.pipe(switchMap(() => {
377
- return this.mapInstance$.pipe(tap((map) => {
378
- map.setPitch(0);
379
- map.setBearing(0);
380
- }));
381
- }));
382
- });
383
- // MARK: Accessors
384
- get timerRefreshPeriod() {
385
- return this.dbxMapboxService.mapboxMapStoreTimerRefreshPeriod;
386
- }
387
- movingTimer(period = this.timerRefreshPeriod) {
388
- return this.moveState$.pipe(switchMap((x) => {
389
- if (x === 'moving') {
390
- return interval(period);
391
- }
392
- else {
393
- return of(0);
394
- }
395
- }), shareReplay(1));
396
- }
397
- lifecycleRenderTimer(period = this.timerRefreshPeriod) {
398
- return this.lifecycleState$.pipe(switchMap((x) => {
399
- if (x === 'render') {
400
- return interval(period);
401
- }
402
- else {
403
- return of(0);
404
- }
405
- }), shareReplay(1));
406
- }
407
- atNextIdle() {
408
- return this.moveState$.pipe(map((x) => x === 'idle'), first());
409
- }
410
- calculateNextCenterWithOffset(inputOffset) {
411
- const offset = this.latLngPoint(inputOffset);
412
- return this.atNextIdle().pipe(switchMap(() => this.center$.pipe(first(), map((center) => {
413
- const newCenter = {
414
- lat: offset.lat + center.lat,
415
- lng: offset.lng + center.lng
416
- };
417
- return newCenter;
418
- }))));
419
- }
420
- calculateNextCenterOffsetWithScreenMarginChange(sizing) {
421
- // TODO: Consider calculating this using the viewport() function from @placemarkio/geo-viewport
422
- return this.atNextIdle().pipe(switchMap(() => this.bound$.pipe(first(), map((bounds) => {
423
- const diff = diffLatLngBoundPoints(bounds, true);
424
- const center = latLngBoundCenterPoint(bounds);
425
- const offsetWidth = sizing.leftMargin + sizing.rightMargin; // 300 + 0
426
- const newWidth = sizing.fullWidth - offsetWidth; // 1000 - 300 - 0
427
- const newWidthRatio = newWidth / sizing.fullWidth; // 700 / 1000
428
- const newCenterLongitudeWidth = diff.lng * newWidthRatio; // 70% offset
429
- const effectiveOffset = {
430
- lat: 0,
431
- lng: newCenterLongitudeWidth / 2
432
- };
433
- const newCenter = addLatLngPoints(bounds.sw, effectiveOffset);
434
- newCenter.lat = center.lat; // retain center position
435
- // console.log({ sizing, bounds, effectiveOffset, newWidth, offsetWidth, diff, center, newCenter });
436
- return newCenter;
437
- }))));
438
- }
439
- filterByViewportBound(input) {
440
- const config = typeof input === 'function' ? { readValue: input } : input;
441
- return filterByMapboxViewportBound({
442
- ...config,
443
- boundFunctionObs: this.viewportBoundFunction$,
444
- boundDecisionObs: this.overlapsBoundFunction$
445
- });
446
- }
447
- currentMapService$ = this.state$.pipe(map((x) => x.mapService), distinctUntilChanged(), shareReplay(1));
448
- mapService$ = this.currentMapService$.pipe(filterMaybe());
449
- currentMapInstance$ = this.currentMapService$.pipe(switchMap((currentMapService) => {
450
- if (currentMapService) {
451
- return currentMapService.mapLoaded$.pipe(defaultIfEmpty(undefined), map(() => currentMapService.mapInstance));
452
- }
453
- else {
454
- return of(undefined);
455
- }
456
- }), distinctUntilChanged(), shareReplay(1));
457
- mapInstance$ = this.currentMapInstance$.pipe(filterMaybe());
458
- boundRefreshSettings$ = this.state$.pipe(map((x) => x.boundRefreshSettings), shareReplay(1));
459
- moveState$ = this.state$.pipe(map((x) => x.moveState), distinctUntilChanged(), shareReplay(1));
460
- lifecycleState$ = this.state$.pipe(map((x) => x.lifecycleState), distinctUntilChanged(), shareReplay(1));
461
- zoomState$ = this.state$.pipe(map((x) => x.zoomState), distinctUntilChanged(), shareReplay(1));
462
- rotateState$ = this.state$.pipe(map((x) => x.rotateState), distinctUntilChanged(), shareReplay(1));
463
- isInitialized$ = this.currentMapInstance$.pipe(switchMap((x) => {
464
- if (!x) {
465
- return of(false);
466
- }
467
- else {
468
- return combineLatest([this.moveState$.pipe(map((x) => x === 'idle')), this.lifecycleState$.pipe(map((x) => x === 'idle'))]).pipe(filter(([m, l]) => m && l), first(), map(() => true));
469
- }
470
- }), shareReplay(1));
471
- whenInitialized$ = this.isInitialized$.pipe(filter((x) => true), shareReplay(1));
472
- isRendering$ = this.whenInitialized$.pipe(switchMap(() => this.lifecycleState$.pipe(map((x) => x === 'render'), distinctUntilChanged(), shareReplay(1))));
473
- isMoving$ = this.whenInitialized$.pipe(switchMap(() => this.moveState$.pipe(map((x) => x === 'moving'), distinctUntilChanged(), shareReplay(1))));
474
- isZooming$ = this.whenInitialized$.pipe(switchMap(() => this.zoomState$.pipe(map((x) => x === 'zooming'), distinctUntilChanged(), shareReplay(1))));
475
- isRotating$ = this.whenInitialized$.pipe(switchMap(() => this.rotateState$.pipe(map((x) => x === 'rotating'), distinctUntilChanged(), shareReplay(1))));
476
- _movingTimer = this.movingTimer();
477
- _renderingTimer = this.lifecycleRenderTimer();
478
- centerNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._movingTimer.pipe(map(() => this.latLngPoint(x.getCenter())))), shareReplay(1))), shareReplay(1));
479
- center$ = this.whenInitialized$.pipe(switchMap(() => {
480
- return this.isMoving$.pipe(onTrueToFalse(), startWith(undefined), switchMap(() => this.centerNow$.pipe(first())), distinctUntilChanged(isSameLatLngPoint), shareReplay(1));
481
- }), shareReplay(1));
482
- minimumVirtualViewportSize$ = this.state$.pipe(map((x) => x.minimumVirtualViewportSize), distinctUntilChanged(isSameVector), shareReplay(1));
483
- currentMapCanvasSize$ = this.state$.pipe(map((x) => x.mapCanvasSize), distinctUntilChanged(isSameVector), shareReplay(1));
484
- /**
485
- * The map canvas size with consideration to the virtual viewport size.
486
- */
487
- mapCanvasSize$ = this.currentMapCanvasSize$.pipe(filterMaybe());
488
- minimumMapCanvasSize(minVector) {
489
- const resizeFn = vectorMinimumSizeResizeFunction(minVector);
490
- return this.mapCanvasSize$.pipe(map((x) => resizeFn(x)), distinctUntilChanged(isSameVector), shareReplay(1));
491
- }
492
- /**
493
- * The map canvas size with consideration to the virtual viewport size.
494
- */
495
- virtualMapCanvasSize$ = this.minimumVirtualViewportSize$.pipe(switchMap((minimumVirtualViewportSize) => {
496
- if (minimumVirtualViewportSize) {
497
- return this.minimumMapCanvasSize(minimumVirtualViewportSize);
498
- }
499
- else {
500
- return this.mapCanvasSize$;
501
- }
502
- }), distinctUntilChanged(isSameVector), shareReplay(1));
503
- rawViewportBoundFunction$ = this.mapCanvasSize$.pipe(map((mapCanvasSize) => mapboxViewportBoundFunction({ mapCanvasSize })), shareReplay(1));
504
- /**
505
- * Creates a MapboxViewportBoundFunction observable that returns the minimum viewport size.
506
- *
507
- * @param minVector
508
- * @returns
509
- */
510
- viewportBoundFunctionWithMinimumSize(minVector) {
511
- const resizeFn = vectorMinimumSizeResizeFunction(minVector);
512
- return this.mapCanvasSize$.pipe(map((x) => resizeFn(x)), distinctUntilChanged(isSameVector), map((mapCanvasSize) => mapboxViewportBoundFunction({ mapCanvasSize })), shareReplay(1));
513
- }
514
- viewportBoundFunction$ = this.minimumVirtualViewportSize$.pipe(switchMap((minimumVirtualViewportSize) => {
515
- if (minimumVirtualViewportSize) {
516
- return this.viewportBoundFunctionWithMinimumSize(minimumVirtualViewportSize);
517
- }
518
- else {
519
- return this.rawViewportBoundFunction$;
520
- }
521
- }), shareReplay(1));
522
- virtualBound$ = this.viewportBoundFunction$.pipe(switchMap((fn) => {
523
- return this.boundRefreshSettings$.pipe(switchMap((settings) => {
524
- const { throttle: throttleMs, refreshType } = settings;
525
- let obs;
526
- switch (refreshType) {
527
- case 'always':
528
- obs = combineLatest([this.centerNow$, this.zoomNow$]);
529
- break;
530
- case 'when_not_rendering':
531
- case 'only_after_render_finishes':
532
- obs = this.bound$.pipe(switchMap(() => combineLatest([this.centerNow$, this.zoomNow$]))); // refresh whenever the bound refreshes
533
- break;
534
- }
535
- return obs.pipe(throttleTime(throttleMs, undefined, { leading: true, trailing: true }), map(([center, zoom]) => fn({
536
- center,
537
- zoom
538
- })));
539
- }));
540
- }), distinctUntilChanged(isSameLatLngBound), shareReplay(1));
541
- margin$ = this.state$.pipe(map((x) => x.margin), distinctUntilChanged((a, b) => a != null && b != null && a.fullWidth === b.fullWidth && a.leftMargin === b.leftMargin && a.rightMargin === b.rightMargin), shareReplay(1));
542
- reverseMargin$ = this.margin$.pipe(map((x) => {
543
- if (x) {
544
- return { leftMargin: -x.leftMargin, rightMargin: -x.rightMargin, fullWidth: x.fullWidth };
545
- }
546
- else {
547
- return x;
548
- }
549
- }));
550
- centerGivenMargin$ = this.whenInitialized$.pipe(switchMap(() => {
551
- return this.reverseMargin$.pipe(switchMap((x) => {
552
- if (x) {
553
- return this.center$.pipe(switchMap((_) => this.calculateNextCenterOffsetWithScreenMarginChange(x)));
554
- }
555
- else {
556
- return this.isMoving$.pipe(filter((x) => !x), switchMap(() => this.center$));
557
- }
558
- }));
559
- }), shareReplay(1));
560
- rawBoundNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._renderingTimer.pipe(map(() => {
561
- const bound = x.getBounds();
562
- const boundSw = bound.getSouthWest();
563
- const boundNe = bound.getNorthEast();
564
- const sw = isDefaultLatLngPoint(boundSw) ? swMostLatLngPoint() : { lat: boundSw.lat, lng: boundSw.lng };
565
- const ne = isDefaultLatLngPoint(boundNe) ? neMostLatLngPoint() : { lat: boundNe.lat, lng: boundNe.lng };
566
- return this.latLngBound(sw, ne);
567
- }))))), distinctUntilChanged(isSameLatLngBound), shareReplay(1));
568
- rawBound$ = this.whenInitialized$.pipe(switchMap(() => {
569
- return this.boundRefreshSettings$.pipe(switchMap((settings) => {
570
- const { throttle: throttleMs, refreshType } = settings;
571
- let obs;
572
- switch (refreshType) {
573
- case 'always':
574
- obs = this.rawBoundNow$;
575
- break;
576
- case 'when_not_rendering':
577
- obs = this.isRendering$.pipe(switchMap((x) => (x ? EMPTY : this.rawBoundNow$)));
578
- break;
579
- case 'only_after_render_finishes':
580
- obs = this.isRendering$.pipe(onTrueToFalse(), switchMap((x) => this.rawBoundNow$.pipe(first())));
581
- break;
582
- }
583
- return obs.pipe(throttleTime(throttleMs, undefined, { leading: true, trailing: true }));
584
- }));
585
- }), distinctUntilChanged(isSameLatLngBound), shareReplay(1));
586
- useVirtualBound$ = this.state$.pipe(map((x) => x.useVirtualBound), distinctUntilChanged(), shareReplay(1));
587
- bound$ = this.useVirtualBound$.pipe(switchMap((useVirtualBound) => {
588
- if (useVirtualBound) {
589
- return this.virtualBound$;
590
- }
591
- else {
592
- return this.rawBound$;
593
- }
594
- }), shareReplay(1));
595
- boundSizing$ = this.bound$.pipe(map((x) => diffLatLngBoundPoints(x)), shareReplay(1));
596
- boundWrapsAroundWorld$ = this.bound$.pipe(map((x) => latLngBoundWrapsMap(x)), distinctUntilChanged(), shareReplay(1));
597
- isWithinBoundFunction$ = this.bound$.pipe(map((x) => isWithinLatLngBoundFunction(x)), shareReplay(1));
598
- overlapsBoundFunction$ = this.virtualBound$.pipe(map((x) => overlapsLatLngBoundFunction(x)), shareReplay(1));
599
- zoomNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._renderingTimer.pipe(map(() => x.getZoom()))), shareReplay(1))));
600
- zoom$ = this.whenInitialized$.pipe(switchMap(() => {
601
- return this.isZooming$.pipe(onTrueToFalse(), startWith(undefined), switchMap(() => this.zoomNow$.pipe(first())), distinctUntilChanged(), shareReplay(1));
602
- }));
603
- pitchNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._movingTimer.pipe(map(() => x.getPitch()))), shareReplay(1))));
604
- pitch$ = this.whenInitialized$.pipe(switchMap(() => {
605
- return this.isRotating$.pipe(onTrueToFalse(), startWith(undefined), switchMap(() => this.pitchNow$.pipe(first())), distinctUntilChanged(), shareReplay(1));
606
- }));
607
- bearingNow$ = this.whenInitialized$.pipe(switchMap(() => this.mapInstance$.pipe(switchMap((x) => this._movingTimer.pipe(map(() => x.getBearing()))), shareReplay(1))));
608
- bearing$ = this.whenInitialized$.pipe(switchMap(() => {
609
- return this.isRotating$.pipe(onTrueToFalse(), startWith(undefined), switchMap(() => this.bearingNow$.pipe(first())), distinctUntilChanged(), shareReplay(1));
610
- }));
611
- content$ = this.state$.pipe(map((x) => x.content), distinctUntilChanged(), shareReplay(1));
612
- hasContent$ = this.content$.pipe(map(Boolean));
613
- clickEvent$ = this.state$.pipe(map((x) => x.clickEvent), distinctUntilChanged(), shareReplay(1));
614
- doubleClickEvent$ = this.state$.pipe(map((x) => x.doubleClickEvent), distinctUntilChanged(), shareReplay(1));
615
- rightClickEvent$ = this.state$.pipe(map((x) => x.rightClickEvent), distinctUntilChanged(), shareReplay(1));
616
- // MARK: State Changes
617
- setMargin = this.updater((state, margin) => ({ ...state, margin: margin && (margin.rightMargin !== 0 || margin.leftMargin !== 0) ? margin : undefined }));
618
- setMinimumVirtualViewportSize = this.updater((state, minimumVirtualViewportSize) => ({ ...state, minimumVirtualViewportSize }));
619
- setUseVirtualBound = this.updater((state, useVirtualBound) => ({ ...state, useVirtualBound }));
620
- setBoundRefreshSettings = this.updater((state, boundRefreshSettings) => ({ ...state, boundRefreshSettings: { ...state.boundRefreshSettings, ...boundRefreshSettings } }));
621
- _setMapService = this.updater((state, mapService) => ({ mapService, moveState: 'init', lifecycleState: 'init', zoomState: 'init', rotateState: 'init', retainContent: state.retainContent, content: state.retainContent ? state.content : undefined, useVirtualBound: state.useVirtualBound, boundRefreshSettings: state.boundRefreshSettings }));
622
- _setLifecycleState = this.updater((state, lifecycleState) => ({ ...state, lifecycleState }));
623
- _setMoveState = this.updater((state, moveState) => ({ ...state, moveState }));
624
- _setZoomState = this.updater((state, zoomState) => ({ ...state, zoomState }));
625
- _setRotateState = this.updater((state, rotateState) => ({ ...state, rotateState }));
626
- _setMapCanvasSize = this.updater((state, mapCanvasSize) => ({ ...state, mapCanvasSize }));
627
- _setClickEvent = this.updater((state, clickEvent) => ({ ...state, clickEvent }));
628
- _setDoubleClickEvent = this.updater((state, doubleClickEvent) => ({ ...state, doubleClickEvent }));
629
- _setRightClickEvent = this.updater((state, rightClickEvent) => ({ ...state, rightClickEvent }));
630
- _setError = this.updater((state, error) => ({ ...state, error }));
631
- clearContent = this.updater((state) => ({ ...state, content: undefined }));
632
- setContent = this.updater((state, content) => ({ ...state, content }));
633
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStore, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
634
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStore });
635
- }
636
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStore, decorators: [{
637
- type: Injectable
638
- }], ctorParameters: function () { return []; } });
639
-
640
- /**
641
- * Provided in the parent component that allows children to emit events related to their lifecycles.
642
- */
643
- class DbxMapboxChangeService {
644
- dbxMapboxMapStore = inject(DbxMapboxMapStore);
645
- _markerDestroyed = new Subject();
646
- _applyChanges = new Subject();
647
- markerDestroyed$ = this._markerDestroyed;
648
- applyChanges$ = merge(this._applyChanges, this.markerDestroyed$).pipe(throttleTime(100, undefined, { leading: false, trailing: true }));
649
- _applyChangesSub = new SubscriptionObject(this.dbxMapboxMapStore.mapService$
650
- .pipe(switchMap((mapService) => this.applyChanges$.pipe(tap(() => {
651
- mapService.applyChanges();
652
- }))))
653
- .subscribe());
654
- applyChanges() {
655
- this._applyChanges.next();
656
- }
657
- emitMarkerDestroyed() {
658
- this._markerDestroyed.next();
659
- }
660
- ngOnDestroy() {
661
- this._markerDestroyed.complete();
662
- this._applyChanges.complete();
663
- this._applyChangesSub.destroy();
664
- }
665
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxChangeService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
666
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxChangeService, providedIn: null });
667
- }
668
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxChangeService, decorators: [{
669
- type: Injectable,
670
- args: [{
671
- providedIn: null
672
- }]
673
- }] });
674
-
675
- /**
676
- * Store used for storing injectable content into the map.
677
- */
678
- class DbxMapboxInjectionStore extends ComponentStore {
679
- constructor() {
680
- super({
681
- map: new Map()
682
- });
683
- }
684
- map$ = this.state$.pipe(map((x) => x.map), distinctUntilMapHasDifferentKeys(), shareReplay(1));
685
- allInjectionConfigs$ = this.map$.pipe(map((x) => Array.from(x.values())), shareReplay(1));
686
- // MARK: State Changes
687
- addInjectionConfig = this.updater(updateDbxMapboxMapInjectionStoreStateWithInjectionConfig);
688
- removeInjectionConfigWithKey = this.updater(updateDbxMapboxMapInjectionStoreStateWithRemovedKey);
689
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStore, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
690
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStore });
691
- }
692
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStore, decorators: [{
693
- type: Injectable
694
- }], ctorParameters: function () { return []; } });
695
- function updateDbxMapboxMapInjectionStoreStateWithInjectionConfig(state, config) {
696
- const map = new Map(state.map).set(config.key, config);
697
- return { ...state, map };
698
- }
699
- function updateDbxMapboxMapInjectionStoreStateWithRemovedKey(state, key) {
700
- // only create a new state if the key is going to get removed
701
- if (state.map.has(key)) {
702
- const map = new Map(state.map);
703
- map.delete(key);
704
- state = { ...state, map };
705
- }
706
- return state;
707
- }
708
-
709
- /**
710
- * Injects the components configured in the DbxMapboxInjectionStore into the view.
711
- */
712
- class DbxMapboxInjectionComponent {
713
- dbxMapboxMapKeyInjectionStore = inject(DbxMapboxInjectionStore);
714
- entries$ = this.dbxMapboxMapKeyInjectionStore.allInjectionConfigs$.pipe(shareReplay(1));
715
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
716
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxInjectionComponent, selector: "dbx-mapbox-injection", ngImport: i0, template: `
717
- <dbx-injection-array [entries]="entries$ | async"></dbx-injection-array>
718
- `, isInline: true, dependencies: [{ kind: "component", type: i1.DbxInjectionArrayComponent, selector: "dbx-injection-array", inputs: ["entries"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
719
- }
720
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionComponent, decorators: [{
721
- type: Component,
722
- args: [{
723
- selector: 'dbx-mapbox-injection',
724
- template: `
725
- <dbx-injection-array [entries]="entries$ | async"></dbx-injection-array>
726
- `,
727
- changeDetection: ChangeDetectionStrategy.OnPush
728
- }]
729
- }] });
730
-
731
- /**
732
- * Token used by provideMapboxInjectionStoreIfDoesNotExist() to prevent injecting a parent DbxMapboxInjectionStore into the child view.
733
- */
734
- class DbxMapboxInjectionStoreProviderBlock {
735
- dbxMapboxInjectionStore = inject(DbxMapboxInjectionStore, { skipSelf: true });
736
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStoreProviderBlock, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
737
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStoreProviderBlock });
738
- }
739
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStoreProviderBlock, decorators: [{
740
- type: Injectable
741
- }] });
742
- class DbxMapboxInjectionStoreInjectionBlockDirective {
743
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStoreInjectionBlockDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
744
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxInjectionStoreInjectionBlockDirective, selector: "[dbxMapboxInjectionStoreParentBlocker]", providers: [DbxMapboxInjectionStoreProviderBlock], ngImport: i0 });
745
- }
746
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxInjectionStoreInjectionBlockDirective, decorators: [{
747
- type: Directive,
748
- args: [{
749
- selector: '[dbxMapboxInjectionStoreParentBlocker]',
750
- providers: [DbxMapboxInjectionStoreProviderBlock]
751
- }]
752
- }] });
753
- /**
754
- * Creates a Provider that initializes a new DbxMapboxInjectionStore if a parent does not exist.
755
- *
756
- * If a DbxMapboxInjectionStoreInjectionBlock is available in the context, and references the same dbxMapboxInjectionStore that is attempting to be injected, a new DbxMapboxInjectionStore is created.
757
- *
758
- * @returns
759
- */
760
- function provideMapboxInjectionStoreIfParentIsUnavailable() {
761
- return {
762
- provide: DbxMapboxInjectionStore,
763
- useFactory: (parentInjector, dbxMapboxInjectionStoreInjectionBlock, dbxMapboxInjectionStore) => {
764
- if (!dbxMapboxInjectionStore || (dbxMapboxInjectionStore && dbxMapboxInjectionStoreInjectionBlock != null && dbxMapboxInjectionStoreInjectionBlock.dbxMapboxInjectionStore === dbxMapboxInjectionStore)) {
765
- // create a new dbxMapboxInjectionStore to use
766
- const injector = Injector.create({ providers: [{ provide: DbxMapboxInjectionStore }], parent: parentInjector });
767
- dbxMapboxInjectionStore = injector.get(DbxMapboxInjectionStore);
768
- }
769
- return dbxMapboxInjectionStore;
770
- },
771
- deps: [Injector, [new Optional(), DbxMapboxInjectionStoreProviderBlock], [new Optional(), new SkipSelf(), DbxMapboxInjectionStore]]
772
- };
773
- }
774
-
775
- /**
776
- * Directive that configures a MapComponent with content from DbxMapboxService. Connects a host MapService to a parent DbxMapboxMapStore if available.
777
- */
778
- class DbxMapboxMapDirective {
779
- mapService = inject(MapService, { host: true });
780
- mapboxMap = inject(MapComponent, { host: true });
781
- dbxMapboxService = inject(DbxMapboxService);
782
- dbxMapboxMapStore = inject(DbxMapboxMapStore, { optional: true });
783
- ngOnInit() {
784
- // style must be provided first before the map will load.
785
- this.mapboxMap.style = this.dbxMapboxService.defaultStyle;
786
- this.mapboxMap.zoom = [this.dbxMapboxService.defaultZoom];
787
- this.mapboxMap.center = latLngPoint(this.dbxMapboxService.defaultCenter);
788
- if (this.dbxMapboxMapStore) {
789
- this.dbxMapboxMapStore.setMapService(this.mapService);
790
- }
791
- }
792
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
793
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxMapDirective, selector: "[dbxMapboxMap]", ngImport: i0 });
794
- }
795
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapDirective, decorators: [{
796
- type: Directive,
797
- args: [{
798
- selector: '[dbxMapboxMap]'
799
- }]
800
- }] });
801
-
802
- /**
803
- * Content drawer that connects with DbxMapboxMapStore to show the content.
804
- */
805
- class DbxMapboxLayoutDrawerComponent {
806
- dbxMapboxMapStore = inject(DbxMapboxMapStore);
807
- config$ = this.dbxMapboxMapStore.content$;
808
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxLayoutDrawerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
809
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxLayoutDrawerComponent, selector: "dbx-mapbox-layout-drawer", host: { classAttribute: "dbx-mapbox-layout-drawer" }, ngImport: i0, template: "<div>\n <dbx-injection [config]=\"config$ | async\"></dbx-injection>\n</div>\n", dependencies: [{ kind: "component", type: i1.DbxInjectionComponent, selector: "dbx-injection, [dbxInjection], [dbx-injection]", inputs: ["config", "template"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }] });
810
- }
811
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxLayoutDrawerComponent, decorators: [{
812
- type: Component,
813
- args: [{ selector: 'dbx-mapbox-layout-drawer', host: {
814
- class: 'dbx-mapbox-layout-drawer'
815
- }, template: "<div>\n <dbx-injection [config]=\"config$ | async\"></dbx-injection>\n</div>\n" }]
816
- }] });
817
-
818
- /**
819
- * Responsive component meant to split a left and right column.
820
- *
821
- * The left column is smaller than the right column, which contains the primary content.
822
- *
823
- * Requires a TwoColumnsContextStore to be provided.
824
- */
825
- class DbxMapboxLayoutComponent extends AbstractSubscriptionDirective {
826
- dbxMapboxMapStore = inject(DbxMapboxMapStore);
827
- openedChange = new EventEmitter();
828
- containerElement;
829
- drawerContainer;
830
- content;
831
- _resized = new Subject();
832
- _updateMargins = new Subject();
833
- _forceHasContent = new BehaviorSubject(false);
834
- _mode = new BehaviorSubject('side');
835
- _side = new BehaviorSubject('right');
836
- _isOpen = new BehaviorSubject(true);
837
- _color = new BehaviorSubject('background');
838
- _toggleSub = new SubscriptionObject();
839
- resized$ = this._resized.asObservable();
840
- side$ = this._side.pipe(distinctUntilChanged(), shareReplay(1));
841
- mode$ = this._mode.pipe(distinctUntilChanged(), shareReplay(1));
842
- hasContent$ = combineLatest([this._forceHasContent, this.dbxMapboxMapStore.hasContent$]).pipe(map(([hasContent, forceHasContent]) => hasContent || forceHasContent), distinctUntilChanged(), shareReplay(1));
843
- isOpen$ = this._isOpen.asObservable();
844
- isOpenAndHasContent$ = combineLatest([this.hasContent$, this._isOpen]).pipe(map(([hasContent, open]) => hasContent && open), distinctUntilChanged(), shareReplay(1));
845
- position$ = this.side$.pipe(map((x) => (x === 'right' ? 'end' : 'start')), distinctUntilChanged(), shareReplay(1));
846
- drawerClasses$ = combineLatest([this.side$, this.dbxMapboxMapStore.hasContent$, this.isOpenAndHasContent$]).pipe(
847
- //
848
- map(([side, hasContent, open]) => (hasContent ? 'has-drawer-content' : 'no-drawer-content') + ` ${side}-drawer ` + (open ? 'open-drawer' : '')), distinctUntilChanged(), shareReplay(1));
849
- drawerButtonColor$ = this._color.pipe(distinctUntilChanged(), shareReplay(1));
850
- buttonIcon$ = combineLatest([this.side$, this.isOpenAndHasContent$]).pipe(map(([side, opened]) => {
851
- let icons = ['chevron_right', 'chevron_left'];
852
- if (side === 'left') {
853
- icons = icons.reverse();
854
- }
855
- return opened ? icons[0] : icons[1];
856
- }));
857
- ngOnInit() {
858
- this.sub = this.side$.pipe(switchMap(() => this._resized.pipe(throttleTime(100, undefined, { leading: true, trailing: true }), map(() => 'r'), startWith('s')))).subscribe((reason) => {
859
- this.dbxMapboxMapStore.mapInstance$.subscribe((x) => {
860
- x.resize();
861
- // side changed
862
- if (reason === 's') {
863
- setTimeout(() => {
864
- this._updateMargins.next();
865
- });
866
- }
867
- });
868
- });
869
- let init = false;
870
- this._toggleSub.subscription = this.mode$
871
- .pipe(switchMap((mode) => {
872
- let obs;
873
- if (mode === 'push') {
874
- obs = combineLatest([this.isOpenAndHasContent$.pipe(distinctUntilChanged()), this._updateMargins]).pipe(tap(([opened]) => {
875
- let { right } = this.drawerContainer._contentMargins;
876
- this.drawerContainer.updateContentMargins();
877
- setTimeout(() => {
878
- const flip = opened ? 1 : -1;
879
- if (opened) {
880
- right = this.drawerContainer._contentMargins.right;
881
- }
882
- right = (right || 0) * flip;
883
- const element = this.content.nativeElement;
884
- const width = element.clientWidth;
885
- const margin = {
886
- leftMargin: 0,
887
- rightMargin: right,
888
- fullWidth: width
889
- };
890
- const easeTo = this.dbxMapboxMapStore.calculateNextCenterOffsetWithScreenMarginChange(margin).pipe(first(), map((center) => ({ to: { center, duration: 3200, essential: false } })));
891
- this.dbxMapboxMapStore.setMargin(opened ? margin : undefined);
892
- if (!init) {
893
- this.dbxMapboxMapStore.easeTo(easeTo);
894
- }
895
- else {
896
- init = true;
897
- }
898
- });
899
- }));
900
- }
901
- else {
902
- obs = combineLatest([this.isOpenAndHasContent$.pipe(distinctUntilChanged()), this._updateMargins]).pipe(switchMap((_) => this.dbxMapboxMapStore.mapInstance$), tap((x) => {
903
- this.drawerContainer.updateContentMargins();
904
- x.triggerRepaint();
905
- }));
906
- }
907
- return obs;
908
- }))
909
- .subscribe();
910
- }
911
- ngOnDestroy() {
912
- super.ngOnDestroy();
913
- this.openedChange.complete();
914
- this._resized.complete();
915
- this._updateMargins.complete();
916
- this._side.complete();
917
- this._isOpen.complete();
918
- this._color.complete();
919
- this._toggleSub.destroy();
920
- this._forceHasContent.complete();
921
- }
922
- toggleDrawer(open) {
923
- if (open == null) {
924
- open = !this._isOpen.value;
925
- }
926
- this._isOpen.next(open);
927
- }
928
- set side(side) {
929
- if (side != null) {
930
- this._side.next(side);
931
- }
932
- }
933
- set mode(mode) {
934
- if (mode != null) {
935
- this._mode.next(mode);
936
- }
937
- }
938
- set opened(opened) {
939
- if (opened != null) {
940
- this._isOpen.next(opened);
941
- }
942
- }
943
- set hasContent(hasContent) {
944
- if (hasContent != null) {
945
- this._forceHasContent.next(hasContent);
946
- }
947
- }
948
- set drawerButtonColor(color) {
949
- this._color.next(color);
950
- }
951
- onResized(event) {
952
- this._resized.next(event);
953
- }
954
- onOpened(opened) {
955
- this.openedChange.next(opened);
956
- if (this._isOpen.value !== opened) {
957
- this.openedChange.next(opened);
958
- }
959
- }
960
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxLayoutComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
961
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxLayoutComponent, selector: "dbx-mapbox-layout", inputs: { side: "side", mode: "mode", opened: "opened", hasContent: "hasContent", drawerButtonColor: "drawerButtonColor" }, outputs: { openedChange: "openedChange" }, viewQueries: [{ propertyName: "containerElement", first: true, predicate: MatDrawerContainer, descendants: true, read: ElementRef }, { propertyName: "drawerContainer", first: true, predicate: MatDrawerContainer, descendants: true }, { propertyName: "content", first: true, predicate: ["content"], descendants: true, read: ElementRef, static: true }], usesInheritance: true, ngImport: i0, template: "<mat-drawer-container #containerElement class=\"dbx-mapbox-layout-container\" [ngClass]=\"(drawerClasses$ | async) || ''\" [hasBackdrop]=\"false\">\n <mat-drawer class=\"dbx-mapbox-layout-drawer\" #drawer (openedChange)=\"onOpened($event)\" [opened]=\"isOpenAndHasContent$ | async\" [mode]=\"(mode$ | async) || 'side'\" [position]=\"(position$ | async) || 'end'\">\n <div class=\"dbx-mapbox-layout-drawer-content\" [ngClass]=\"(drawerClasses$ | async) || ''\">\n <ng-content select=\"[drawer]\"></ng-content>\n <dbx-mapbox-layout-drawer></dbx-mapbox-layout-drawer>\n </div>\n </mat-drawer>\n <mat-drawer-content #content class=\"dbx-mapbox-layout-content\" (resized)=\"onResized($event)\">\n <button mat-icon-button (click)=\"toggleDrawer()\" class=\"dbx-mapbox-layout-drawer-button\" [dbxColor]=\"drawerButtonColor$ | async\">\n <mat-icon>{{ buttonIcon$ | async }}</mat-icon>\n </button>\n <ng-content></ng-content>\n </mat-drawer-content>\n</mat-drawer-container>\n", styles: [".dbx-mapbox-layout-container{height:100%;max-width:100%}.dbx-mapbox-layout-container .mat-drawer-container{height:100%}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer{max-width:calc(100% - var(--dbx-mapbox-min-width-var, 33px))}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer-content{height:100%;width:100%;overflow:hidden}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{position:absolute;z-index:2;top:40%;border:none;display:flex;overflow:hidden}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button.mat-mdc-icon-button{padding-left:0}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button.mat-mdc-icon-button ::ng-deep>.mat-mdc-button-persistent-ripple{border-radius:unset}.left-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{left:0;border-radius:0 20px 20px 0}.right-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{right:0;border-radius:20px 0 0 20px}.has-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.has-drawer-content.open-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.no-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:0px}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button mat-icon{padding-left:8px}\n"], dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: i2.MatDrawer, selector: "mat-drawer", inputs: ["position", "mode", "disableClose", "autoFocus", "opened"], outputs: ["openedChange", "opened", "openedStart", "closed", "closedStart", "positionChanged"], exportAs: ["matDrawer"] }, { kind: "component", type: i2.MatDrawerContainer, selector: "mat-drawer-container", inputs: ["autosize", "hasBackdrop"], outputs: ["backdropClick"], exportAs: ["matDrawerContainer"] }, { kind: "component", type: i2.MatDrawerContent, selector: "mat-drawer-content" }, { kind: "directive", type: i3.DbxColorDirective, selector: "[dbxColor]", inputs: ["dbxColor"] }, { kind: "component", type: i4.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i6.ResizedDirective, selector: "[resized]", outputs: ["resized"] }, { kind: "component", type: DbxMapboxLayoutDrawerComponent, selector: "dbx-mapbox-layout-drawer" }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }] });
962
- }
963
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxLayoutComponent, decorators: [{
964
- type: Component,
965
- args: [{ selector: 'dbx-mapbox-layout', template: "<mat-drawer-container #containerElement class=\"dbx-mapbox-layout-container\" [ngClass]=\"(drawerClasses$ | async) || ''\" [hasBackdrop]=\"false\">\n <mat-drawer class=\"dbx-mapbox-layout-drawer\" #drawer (openedChange)=\"onOpened($event)\" [opened]=\"isOpenAndHasContent$ | async\" [mode]=\"(mode$ | async) || 'side'\" [position]=\"(position$ | async) || 'end'\">\n <div class=\"dbx-mapbox-layout-drawer-content\" [ngClass]=\"(drawerClasses$ | async) || ''\">\n <ng-content select=\"[drawer]\"></ng-content>\n <dbx-mapbox-layout-drawer></dbx-mapbox-layout-drawer>\n </div>\n </mat-drawer>\n <mat-drawer-content #content class=\"dbx-mapbox-layout-content\" (resized)=\"onResized($event)\">\n <button mat-icon-button (click)=\"toggleDrawer()\" class=\"dbx-mapbox-layout-drawer-button\" [dbxColor]=\"drawerButtonColor$ | async\">\n <mat-icon>{{ buttonIcon$ | async }}</mat-icon>\n </button>\n <ng-content></ng-content>\n </mat-drawer-content>\n</mat-drawer-container>\n", styles: [".dbx-mapbox-layout-container{height:100%;max-width:100%}.dbx-mapbox-layout-container .mat-drawer-container{height:100%}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer{max-width:calc(100% - var(--dbx-mapbox-min-width-var, 33px))}.dbx-mapbox-layout-container .dbx-mapbox-layout-drawer-content{height:100%;width:100%;overflow:hidden}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{position:absolute;z-index:2;top:40%;border:none;display:flex;overflow:hidden}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button.mat-mdc-icon-button{padding-left:0}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button.mat-mdc-icon-button ::ng-deep>.mat-mdc-button-persistent-ripple{border-radius:unset}.left-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{left:0;border-radius:0 20px 20px 0}.right-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{right:0;border-radius:20px 0 0 20px}.has-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.has-drawer-content.open-drawer .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:35px}.no-drawer-content .dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button{width:0px}.dbx-mapbox-layout-content>.dbx-mapbox-layout-drawer-button mat-icon{padding-left:8px}\n"] }]
966
- }], propDecorators: { openedChange: [{
967
- type: Output
968
- }], containerElement: [{
969
- type: ViewChild,
970
- args: [MatDrawerContainer, { read: ElementRef }]
971
- }], drawerContainer: [{
972
- type: ViewChild,
973
- args: [MatDrawerContainer]
974
- }], content: [{
975
- type: ViewChild,
976
- args: ['content', { read: ElementRef, static: true }]
977
- }], side: [{
978
- type: Input
979
- }], mode: [{
980
- type: Input
981
- }], opened: [{
982
- type: Input
983
- }], hasContent: [{
984
- type: Input
985
- }], drawerButtonColor: [{
986
- type: Input
987
- }] } });
988
-
989
- /**
990
- * Directive that connects a host MatMenuTrigger to a DbxMapboxMapStore and listens for right-clicks on the map.
991
- *
992
- * The map dissapears if the mouse scrolls anywhere else on the map.
993
- */
994
- class DbxMapboxMenuComponent extends AbstractSubscriptionDirective {
995
- dbxMapboxMapStore = inject(DbxMapboxMapStore);
996
- matMenuTrigger = inject(MatMenuTrigger, { host: true });
997
- ngZone = inject(NgZone);
998
- cdRef = inject(ChangeDetectorRef);
999
- _pos = { x: `0`, y: `0` };
1000
- _active = new BehaviorSubject(true);
1001
- _menuCloseSub = new SubscriptionObject();
1002
- _preventRightClick = new DestroyFunctionObject();
1003
- get pos() {
1004
- return this._pos;
1005
- }
1006
- set active(active) {
1007
- this._active.next(active ?? true);
1008
- }
1009
- ngOnInit() {
1010
- this.sub = this._active
1011
- .pipe(switchMap((active) => {
1012
- if (active) {
1013
- return this.dbxMapboxMapStore.rightClickEvent$;
1014
- }
1015
- else {
1016
- return of();
1017
- }
1018
- }), filter(Boolean))
1019
- .subscribe((event) => {
1020
- const menu = this.matMenuTrigger.menu;
1021
- const buttonEvent = event.originalEvent;
1022
- if (menu && buttonEvent) {
1023
- buttonEvent.preventDefault();
1024
- // update position of this component for menu to open at
1025
- this._pos = {
1026
- x: `${buttonEvent.x}px`,
1027
- y: `${buttonEvent.y}px`
1028
- };
1029
- safeMarkForCheck(this.cdRef);
1030
- // open menu
1031
- this.ngZone.run(() => this.matMenuTrigger.openMenu());
1032
- // prevent right clicks in the cdkOverlay while the menu is open
1033
- this._preventRightClick.destroy = disableRightClickInCdkBackdrop(undefined, () => {
1034
- this.ngZone.run(() => this.matMenuTrigger.closeMenu());
1035
- });
1036
- }
1037
- });
1038
- this._menuCloseSub.subscription = this.matMenuTrigger.menuClosed.subscribe(() => {
1039
- // destroy prevention when the menu is closed.
1040
- this._preventRightClick.destroy();
1041
- });
1042
- }
1043
- ngOnDestroy() {
1044
- super.ngOnDestroy();
1045
- this._active.complete();
1046
- this._menuCloseSub.destroy();
1047
- this._preventRightClick.destroy();
1048
- if (this.matMenuTrigger) {
1049
- this.matMenuTrigger.closeMenu();
1050
- }
1051
- }
1052
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMenuComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
1053
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxMenuComponent, selector: "dbx-mapbox-menu", inputs: { active: "active" }, host: { properties: { "style.top": "pos.y", "style.left": "pos.x" }, styleAttribute: "visibility: hidden; position: fixed" }, usesInheritance: true, ngImport: i0, template: '', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
1054
- }
1055
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMenuComponent, decorators: [{
1056
- type: Component,
1057
- args: [{
1058
- selector: 'dbx-mapbox-menu',
1059
- template: '',
1060
- host: {
1061
- style: 'visibility: hidden; position: fixed',
1062
- '[style.top]': 'pos.y',
1063
- '[style.left]': 'pos.x'
1064
- },
1065
- changeDetection: ChangeDetectionStrategy.OnPush
1066
- }]
1067
- }], propDecorators: { active: [{
1068
- type: Input
1069
- }] } });
1070
-
1071
- /**
1072
- * Token used by provideMapboxStoreIfDoesNotExist() to prevent injecting a parent DbxMapboxMapStore into the child view.
1073
- */
1074
- class DbxMapboxMapStoreProviderBlock {
1075
- dbxMapboxMapStore = inject(DbxMapboxMapStore, { skipSelf: true });
1076
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStoreProviderBlock, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
1077
- static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStoreProviderBlock });
1078
- }
1079
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStoreProviderBlock, decorators: [{
1080
- type: Injectable
1081
- }] });
1082
- class DbxMapboxMapStoreInjectionBlockDirective {
1083
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStoreInjectionBlockDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
1084
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxMapStoreInjectionBlockDirective, selector: "[dbxMapboxStoreParentBlocker]", providers: [DbxMapboxMapStoreProviderBlock], ngImport: i0 });
1085
- }
1086
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMapStoreInjectionBlockDirective, decorators: [{
1087
- type: Directive,
1088
- args: [{
1089
- selector: '[dbxMapboxStoreParentBlocker]',
1090
- providers: [DbxMapboxMapStoreProviderBlock]
1091
- }]
1092
- }] });
1093
- /**
1094
- * Creates a Provider that initializes a new DbxMapboxMapStore if a parent does not exist.
1095
- *
1096
- * If a DbxMapboxMapStoreInjectionBlock is available in the context, and references the same dbxMapboxMapStore that is attempting to be injected, a new DbxMapboxMapStore is created.
1097
- *
1098
- * @returns
1099
- */
1100
- function provideMapboxStoreIfParentIsUnavailable() {
1101
- return {
1102
- provide: DbxMapboxMapStore,
1103
- useFactory: (parentInjector, dbxMapboxMapStoreInjectionBlock, dbxMapboxMapStore) => {
1104
- if (!dbxMapboxMapStore || (dbxMapboxMapStore && dbxMapboxMapStoreInjectionBlock != null && dbxMapboxMapStoreInjectionBlock.dbxMapboxMapStore === dbxMapboxMapStore)) {
1105
- // create a new dbxMapboxMapStore to use
1106
- const injector = Injector.create({ providers: [{ provide: DbxMapboxMapStore }], parent: parentInjector });
1107
- dbxMapboxMapStore = injector.get(DbxMapboxMapStore);
1108
- }
1109
- return dbxMapboxMapStore;
1110
- },
1111
- deps: [Injector, [new Optional(), DbxMapboxMapStoreProviderBlock], [new Optional(), new SkipSelf(), DbxMapboxMapStore]]
1112
- };
1113
- }
1114
-
1115
- class DbxMapboxMarkerComponent {
1116
- _dbxMapboxChangeService = inject(DbxMapboxChangeService, { optional: true });
1117
- static _latLngPoint = latLngPointFunction({ wrap: true });
1118
- _marker;
1119
- get marker() {
1120
- return this._marker;
1121
- }
1122
- set marker(marker) {
1123
- this._marker = marker;
1124
- }
1125
- get latLng() {
1126
- const input = this._marker?.latLng;
1127
- return input ? DbxMapboxMarkerComponent._latLngPoint(input) : undefined;
1128
- }
1129
- get anchor() {
1130
- return this._marker?.anchor;
1131
- }
1132
- get label() {
1133
- return this._marker?.label;
1134
- }
1135
- get icon() {
1136
- return this._marker?.icon;
1137
- }
1138
- get style() {
1139
- let width = 0;
1140
- let height = 0;
1141
- const size = this._marker?.size || 'medium';
1142
- switch (this.presentation) {
1143
- case 'normal':
1144
- if (typeof size === 'number') {
1145
- width = size;
1146
- }
1147
- else {
1148
- switch (size) {
1149
- case 'small':
1150
- width = 18;
1151
- break;
1152
- case 'medium':
1153
- width = 24;
1154
- break;
1155
- case 'large':
1156
- width = 32;
1157
- break;
1158
- case 'tall':
1159
- width = 24;
1160
- height = 32;
1161
- break;
1162
- }
1163
- break;
1164
- }
1165
- break;
1166
- }
1167
- if (!height) {
1168
- height = width;
1169
- }
1170
- const imageInput = this._marker?.image;
1171
- const image = imageInput ? (typeof imageInput === 'string' ? imageInput : getValueFromGetter(imageInput, width)) : undefined;
1172
- const style = {
1173
- ...this._marker?.style,
1174
- 'background-image': image
1175
- };
1176
- if (width && height) {
1177
- style.width = width + 'px';
1178
- style.height = height + 'px';
1179
- style['font-size'] = width + 'px';
1180
- }
1181
- return style;
1182
- }
1183
- get presentation() {
1184
- return this._marker?.presentation ?? 'normal';
1185
- }
1186
- get presentationClasses() {
1187
- const presentation = this.presentation;
1188
- const markerClasses = this._marker?.markerClasses;
1189
- let cssClasses = '';
1190
- switch (presentation) {
1191
- case 'chip':
1192
- case 'chip-small':
1193
- cssClasses = 'dbx-mapbox-marker-chip dbx-chip mat-standard-chip dbx-bg';
1194
- if (presentation === 'chip-small') {
1195
- cssClasses += ' dbx-chip-small';
1196
- }
1197
- break;
1198
- }
1199
- if (!this.icon) {
1200
- cssClasses += ' dbx-mapbox-marker-no-icon';
1201
- }
1202
- if (markerClasses) {
1203
- cssClasses += ` ${markerClasses}`;
1204
- }
1205
- return cssClasses;
1206
- }
1207
- ngOnDestroy() {
1208
- this._dbxMapboxChangeService?.emitMarkerDestroyed();
1209
- }
1210
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMarkerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1211
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxMarkerComponent, selector: "dbx-mapbox-marker", inputs: { marker: "marker" }, ngImport: i0, template: `
1212
- <mgl-marker *ngIf="marker" [lngLat]="latLng">
1213
- <dbx-anchor [anchor]="anchor">
1214
- <div class="dbx-mapbox-marker" [ngClass]="presentationClasses">
1215
- <div class="dbx-mapbox-marker-icon-content" [ngStyle]="style">
1216
- <mat-icon *ngIf="icon">{{ icon }}</mat-icon>
1217
- </div>
1218
- <div class="dbx-mapbox-marker-label dbx-outlined-text" *ngIf="label">{{ label }}</div>
1219
- </div>
1220
- </dbx-anchor>
1221
- </mgl-marker>
1222
- `, isInline: true, styles: [".dbx-mapbox-marker{display:flex;align-items:center;flex-direction:column}.dbx-mapbox-marker .dbx-mapbox-marker-icon-content{display:flex;align-items:center;justify-content:center}.dbx-mapbox-marker .dbx-mapbox-marker-icon-content mat-icon{width:100%;height:100%;font-size:inherit}.dbx-mapbox-marker .dbx-mapbox-marker-label{font-size:.9em}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip{flex-direction:row;font-size:1em}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip .dbx-mapbox-marker-icon-content{width:18px;height:18px;font-size:18px}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-chip-small .dbx-mapbox-marker-label{padding-left:3px}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-chip-small .dbx-mapbox-marker-icon-content{padding:0!important;width:16px;height:16px;font-size:16px}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-mapbox-marker-no-icon>.dbx-mapbox-marker-icon-content{display:none}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-mapbox-marker-no-icon>.dbx-mapbox-marker-icon-content .dbx-mapbox-marker-label{padding-left:0}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip .dbx-mapbox-marker-label{padding-left:4px}\n"], dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: i3.DbxAnchorComponent, selector: "dbx-anchor, [dbx-anchor]", inputs: ["block"] }, { kind: "component", type: i4$1.MarkerComponent, selector: "mgl-marker", inputs: ["offset", "anchor", "clickTolerance", "feature", "lngLat", "draggable", "popupShown", "className", "pitchAlignment", "rotationAlignment"], outputs: ["markerDragStart", "markerDragEnd", "markerDrag", "dragStart", "dragEnd", "drag"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1223
- }
1224
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMarkerComponent, decorators: [{
1225
- type: Component,
1226
- args: [{ selector: 'dbx-mapbox-marker', template: `
1227
- <mgl-marker *ngIf="marker" [lngLat]="latLng">
1228
- <dbx-anchor [anchor]="anchor">
1229
- <div class="dbx-mapbox-marker" [ngClass]="presentationClasses">
1230
- <div class="dbx-mapbox-marker-icon-content" [ngStyle]="style">
1231
- <mat-icon *ngIf="icon">{{ icon }}</mat-icon>
1232
- </div>
1233
- <div class="dbx-mapbox-marker-label dbx-outlined-text" *ngIf="label">{{ label }}</div>
1234
- </div>
1235
- </dbx-anchor>
1236
- </mgl-marker>
1237
- `, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".dbx-mapbox-marker{display:flex;align-items:center;flex-direction:column}.dbx-mapbox-marker .dbx-mapbox-marker-icon-content{display:flex;align-items:center;justify-content:center}.dbx-mapbox-marker .dbx-mapbox-marker-icon-content mat-icon{width:100%;height:100%;font-size:inherit}.dbx-mapbox-marker .dbx-mapbox-marker-label{font-size:.9em}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip{flex-direction:row;font-size:1em}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip .dbx-mapbox-marker-icon-content{width:18px;height:18px;font-size:18px}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-chip-small .dbx-mapbox-marker-label{padding-left:3px}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-chip-small .dbx-mapbox-marker-icon-content{padding:0!important;width:16px;height:16px;font-size:16px}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-mapbox-marker-no-icon>.dbx-mapbox-marker-icon-content{display:none}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip.dbx-mapbox-marker-no-icon>.dbx-mapbox-marker-icon-content .dbx-mapbox-marker-label{padding-left:0}.dbx-mapbox-marker.dbx-mapbox-marker-chip.dbx-chip .dbx-mapbox-marker-label{padding-left:4px}\n"] }]
1238
- }], propDecorators: { marker: [{
1239
- type: Input
1240
- }] } });
1241
-
1242
- /**
1243
- * Component used to render a set of DbxMapboxMarker values from the input data and marker factory.
1244
- */
1245
- class DbxMapboxMarkersComponent {
1246
- _data = new BehaviorSubject(undefined);
1247
- _markerFactory = new BehaviorSubject(undefined);
1248
- markers$ = combineLatest([this._data.pipe(distinctUntilChanged()), this._markerFactory.pipe(distinctUntilChanged())]).pipe(map(([data, markerFactory]) => {
1249
- if (data?.length && markerFactory) {
1250
- return data.map(markerFactory);
1251
- }
1252
- else {
1253
- return [];
1254
- }
1255
- }), shareReplay(1));
1256
- trackMarkerById(index, marker) {
1257
- return marker.id;
1258
- }
1259
- get data() {
1260
- return this._data.value;
1261
- }
1262
- set data(data) {
1263
- this._data.next(data || []);
1264
- }
1265
- get markerFactory() {
1266
- return this._markerFactory.value;
1267
- }
1268
- set markerFactory(markerFactory) {
1269
- this._markerFactory.next(markerFactory);
1270
- }
1271
- ngOnDestroy() {
1272
- this._data.complete();
1273
- this._markerFactory.complete();
1274
- }
1275
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMarkersComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1276
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxMarkersComponent, selector: "dbx-mapbox-markers", inputs: { data: "data", markerFactory: "markerFactory" }, ngImport: i0, template: `
1277
- <dbx-mapbox-marker *ngFor="let marker of markers$ | async; trackBy: trackMarkerById" [marker]="marker"></dbx-mapbox-marker>
1278
- `, isInline: true, dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: DbxMapboxMarkerComponent, selector: "dbx-mapbox-marker", inputs: ["marker"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1279
- }
1280
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxMarkersComponent, decorators: [{
1281
- type: Component,
1282
- args: [{
1283
- selector: 'dbx-mapbox-markers',
1284
- template: `
1285
- <dbx-mapbox-marker *ngFor="let marker of markers$ | async; trackBy: trackMarkerById" [marker]="marker"></dbx-mapbox-marker>
1286
- `,
1287
- changeDetection: ChangeDetectionStrategy.OnPush
1288
- }]
1289
- }], propDecorators: { data: [{
1290
- type: Input
1291
- }], markerFactory: [{
1292
- type: Input
1293
- }] } });
1294
-
1295
- /**
1296
- * Directive that synchronizes a map's virtual size with the size of the element.
1297
- */
1298
- class DbxMapboxLayoutVirtualResizeSyncComponent extends AbstractSubscriptionDirective {
1299
- dbxMapboxLayoutComponent = inject(DbxMapboxLayoutComponent, { host: true });
1300
- resizedVector$ = this.dbxMapboxLayoutComponent.resized$.pipe(map(() => {
1301
- const element = this.dbxMapboxLayoutComponent.containerElement.nativeElement;
1302
- const { clientWidth, clientHeight } = element;
1303
- return {
1304
- x: clientWidth,
1305
- y: clientHeight
1306
- };
1307
- }), distinctUntilChanged(isSameVector), shareReplay(1));
1308
- ngOnInit() {
1309
- this.sub = this.dbxMapboxLayoutComponent.dbxMapboxMapStore.setMinimumVirtualViewportSize(this.resizedVector$) ?? undefined;
1310
- }
1311
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxLayoutVirtualResizeSyncComponent, deps: null, target: i0.ɵɵFactoryTarget.Directive });
1312
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.2.12", type: DbxMapboxLayoutVirtualResizeSyncComponent, selector: "[dbxMapboxLayoutVirtualResizeSync]", usesInheritance: true, ngImport: i0 });
1313
- }
1314
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxLayoutVirtualResizeSyncComponent, decorators: [{
1315
- type: Directive,
1316
- args: [{
1317
- selector: '[dbxMapboxLayoutVirtualResizeSync]'
1318
- }]
1319
- }] });
1320
-
1321
- const declarations = [
1322
- //
1323
- DbxMapboxLayoutVirtualResizeSyncComponent,
1324
- DbxMapboxMapDirective,
1325
- DbxMapboxLayoutComponent,
1326
- DbxMapboxLayoutDrawerComponent,
1327
- DbxMapboxInjectionComponent,
1328
- DbxMapboxMenuComponent,
1329
- DbxMapboxMarkerComponent,
1330
- DbxMapboxMarkersComponent,
1331
- DbxMapboxMapStoreInjectionBlockDirective
1332
- ];
1333
- class DbxMapboxModule {
1334
- static forRoot(config) {
1335
- return {
1336
- ngModule: DbxMapboxModule,
1337
- providers: [
1338
- {
1339
- provide: DbxMapboxConfig,
1340
- useValue: config
1341
- }
1342
- ]
1343
- };
1344
- }
1345
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1346
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxModule, declarations: [
1347
- //
1348
- DbxMapboxLayoutVirtualResizeSyncComponent,
1349
- DbxMapboxMapDirective,
1350
- DbxMapboxLayoutComponent,
1351
- DbxMapboxLayoutDrawerComponent,
1352
- DbxMapboxInjectionComponent,
1353
- DbxMapboxMenuComponent,
1354
- DbxMapboxMarkerComponent,
1355
- DbxMapboxMarkersComponent,
1356
- DbxMapboxMapStoreInjectionBlockDirective], imports: [
1357
- //
1358
- CommonModule,
1359
- MatSidenavModule,
1360
- DbxStyleLayoutModule,
1361
- DbxInjectionComponentModule,
1362
- MatButtonModule,
1363
- MatIconModule,
1364
- AngularResizeEventModule,
1365
- DbxRouterAnchorModule,
1366
- NgxMapboxGLModule], exports: [
1367
- //
1368
- DbxMapboxLayoutVirtualResizeSyncComponent,
1369
- DbxMapboxMapDirective,
1370
- DbxMapboxLayoutComponent,
1371
- DbxMapboxLayoutDrawerComponent,
1372
- DbxMapboxInjectionComponent,
1373
- DbxMapboxMenuComponent,
1374
- DbxMapboxMarkerComponent,
1375
- DbxMapboxMarkersComponent,
1376
- DbxMapboxMapStoreInjectionBlockDirective] });
1377
- static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxModule, imports: [
1378
- //
1379
- CommonModule,
1380
- MatSidenavModule,
1381
- DbxStyleLayoutModule,
1382
- DbxInjectionComponentModule,
1383
- MatButtonModule,
1384
- MatIconModule,
1385
- AngularResizeEventModule,
1386
- DbxRouterAnchorModule,
1387
- NgxMapboxGLModule] });
1388
- }
1389
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImport: i0, type: DbxMapboxModule, decorators: [{
1390
- type: NgModule,
1391
- args: [{
1392
- imports: [
1393
- //
1394
- CommonModule,
1395
- MatSidenavModule,
1396
- DbxStyleLayoutModule,
1397
- DbxInjectionComponentModule,
1398
- MatButtonModule,
1399
- MatIconModule,
1400
- AngularResizeEventModule,
1401
- DbxRouterAnchorModule,
1402
- NgxMapboxGLModule
1403
- ],
1404
- declarations,
1405
- exports: declarations
1406
- }]
1407
- }] });
1408
-
1409
- /**
1410
- * Creates the styling for rendering a dot.
1411
- *
1412
- * @param background
1413
- * @param color
1414
- * @returns
1415
- */
1416
- function dbxMapboxColoredDotStyle(background, color) {
1417
- return {
1418
- background,
1419
- padding: '2px',
1420
- color: color ?? background ? 'white' : undefined,
1421
- 'border-radius': '50%'
1422
- };
1423
- }
1424
-
1425
- const KNOWN_MAPBOX_STYLES = [
1426
- // standard
1427
- 'mapbox://styles/mapbox/standard',
1428
- // classic
1429
- 'mapbox://styles/mapbox/streets-v12',
1430
- 'mapbox://styles/mapbox/outdoors-v12',
1431
- 'mapbox://styles/mapbox/light-v11',
1432
- 'mapbox://styles/mapbox/dark-v11',
1433
- 'mapbox://styles/mapbox/satellite-v9',
1434
- 'mapbox://styles/mapbox/satellite-streets-v12',
1435
- 'mapbox://styles/mapbox/navigation-day-v1',
1436
- 'mapbox://styles/mapbox/navigation-night-v1'
1437
- ];
1438
- const MAPBOX_MIN_ZOOM_LEVEL = 0;
1439
- const MAPBOX_MAX_ZOOM_LEVEL = 22;
1440
- function mapboxZoomLevel(input) {
1441
- return Math.min(Math.max(input, MAPBOX_MIN_ZOOM_LEVEL), MAPBOX_MAX_ZOOM_LEVEL);
1442
- }
1443
-
1444
- /**
1445
- * Generated bundle index. Do not edit.
1446
- */
1447
-
1448
- export { DEFAULT_MAPBOX_CENTER, DEFAULT_MAPBOX_MAP_STORE_TIMER_REFRESH_PERIOD, DEFAULT_MAPBOX_STYLE, DEFAULT_MAPBOX_ZOOM, DbxMapboxChangeService, DbxMapboxConfig, DbxMapboxInjectionComponent, DbxMapboxInjectionStore, DbxMapboxInjectionStoreInjectionBlockDirective, DbxMapboxInjectionStoreProviderBlock, DbxMapboxLayoutComponent, DbxMapboxLayoutDrawerComponent, DbxMapboxLayoutVirtualResizeSyncComponent, DbxMapboxMapDirective, DbxMapboxMapStore, DbxMapboxMapStoreInjectionBlockDirective, DbxMapboxMapStoreProviderBlock, DbxMapboxMarkerComponent, DbxMapboxMarkersComponent, DbxMapboxMenuComponent, DbxMapboxModule, DbxMapboxService, KNOWN_MAPBOX_STYLES, MAPBOX_MAX_ZOOM_LEVEL, MAPBOX_MIN_ZOOM_LEVEL, dbxMapboxColoredDotStyle, filterByMapboxViewportBound, mapboxViewportBoundFunction, mapboxZoomLevel, provideMapboxInjectionStoreIfParentIsUnavailable, provideMapboxStoreIfParentIsUnavailable, updateDbxMapboxMapInjectionStoreStateWithInjectionConfig, updateDbxMapboxMapInjectionStoreStateWithRemovedKey };
1449
- //# sourceMappingURL=dereekb-dbx-web-mapbox.mjs.map