@sebgroup/green-angular 5.1.2 → 5.2.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 (434) hide show
  1. package/esm2022/src/v-angular/account-number/account-number.module.mjs +18 -0
  2. package/esm2022/src/v-angular/account-number/account-number.pipe.mjs +54 -0
  3. package/esm2022/src/v-angular/account-number/index.mjs +3 -0
  4. package/esm2022/src/v-angular/account-number/sebgroup-green-angular-src-v-angular-account-number.mjs +5 -0
  5. package/esm2022/src/v-angular/alert/alert.component.mjs +47 -0
  6. package/esm2022/src/v-angular/alert/alert.models.mjs +8 -0
  7. package/esm2022/src/v-angular/alert/alert.module.mjs +18 -0
  8. package/esm2022/src/v-angular/alert/index.mjs +4 -0
  9. package/esm2022/src/v-angular/alert/sebgroup-green-angular-src-v-angular-alert.mjs +5 -0
  10. package/esm2022/src/v-angular/base-control-value-accessor/base-control-value-accessor.component.mjs +16 -6
  11. package/esm2022/src/v-angular/base-control-value-accessor/base-control-value-accessor.module.mjs +9 -9
  12. package/esm2022/src/v-angular/breadcrumbs/breadcrumbs.component.mjs +5 -5
  13. package/esm2022/src/v-angular/breadcrumbs/breadcrumbs.module.mjs +11 -11
  14. package/esm2022/src/v-angular/button/button.component.mjs +9 -9
  15. package/esm2022/src/v-angular/button/button.module.mjs +11 -11
  16. package/esm2022/src/v-angular/card/card.component.mjs +6 -6
  17. package/esm2022/src/v-angular/card/card.module.mjs +9 -9
  18. package/esm2022/src/v-angular/character-countdown/character-countdown.module.mjs +6 -6
  19. package/esm2022/src/v-angular/checkbox/checkbox.component.mjs +9 -7
  20. package/esm2022/src/v-angular/checkbox/checkbox.module.mjs +14 -12
  21. package/esm2022/src/v-angular/core/core.utils.mjs +35 -1
  22. package/esm2022/src/v-angular/datepicker/components/calendar/calendar.component.mjs +200 -0
  23. package/esm2022/src/v-angular/datepicker/components/calendar-control/calendar-control.component.mjs +115 -0
  24. package/esm2022/src/v-angular/datepicker/components/date-input/date-input.component.mjs +203 -0
  25. package/esm2022/src/v-angular/datepicker/components/datepicker/datepicker.component.mjs +135 -0
  26. package/esm2022/src/v-angular/datepicker/date-control-value-accessor/date-control-value-accessor.component.mjs +408 -0
  27. package/esm2022/src/v-angular/datepicker/datepicker.globals.mjs +20 -0
  28. package/esm2022/src/v-angular/datepicker/datepicker.models.mjs +56 -0
  29. package/esm2022/src/v-angular/datepicker/datepicker.module.mjs +63 -0
  30. package/esm2022/src/v-angular/datepicker/datepicker.utils.mjs +196 -0
  31. package/esm2022/src/v-angular/datepicker/directives/calendar-date.directive.mjs +47 -0
  32. package/esm2022/src/v-angular/datepicker/index.mjs +17 -0
  33. package/esm2022/src/v-angular/datepicker/models/dates.mjs +291 -0
  34. package/esm2022/src/v-angular/datepicker/pipes/date-thook.pipe.mjs +30 -0
  35. package/esm2022/src/v-angular/datepicker/pipes/is-disabled.pipe.mjs +37 -0
  36. package/esm2022/src/v-angular/datepicker/pipes/matches.pipe.mjs +17 -0
  37. package/esm2022/src/v-angular/datepicker/sebgroup-green-angular-src-v-angular-datepicker.mjs +5 -0
  38. package/esm2022/src/v-angular/drag-drop/drag-drop.component.mjs +497 -0
  39. package/esm2022/src/v-angular/drag-drop/drag-drop.models.mjs +2 -0
  40. package/esm2022/src/v-angular/drag-drop/drag-drop.module.mjs +49 -0
  41. package/esm2022/src/v-angular/drag-drop/drag-drop.pipes.mjs +70 -0
  42. package/esm2022/src/v-angular/drag-drop/drag-drop.utils.mjs +76 -0
  43. package/esm2022/src/v-angular/drag-drop/index.mjs +5 -0
  44. package/esm2022/src/v-angular/drag-drop/sebgroup-green-angular-src-v-angular-drag-drop.mjs +5 -0
  45. package/esm2022/src/v-angular/dropdown/dropdown-list/dropdown-list.component.mjs +24 -9
  46. package/esm2022/src/v-angular/dropdown/dropdown.component.mjs +16 -9
  47. package/esm2022/src/v-angular/dropdown/dropdown.module.mjs +31 -15
  48. package/esm2022/src/v-angular/dropdown/typeahead/typeahead-dropdown-list/typeahead-dropdown-list.component.mjs +8 -8
  49. package/esm2022/src/v-angular/dropdown/typeahead/typeahead-highlight/typeahead-highlight.component.mjs +5 -5
  50. package/esm2022/src/v-angular/dropdown/typeahead/typeahead-input/typeahead-input.component.mjs +17 -10
  51. package/esm2022/src/v-angular/dropdown/typeahead/typeahead.directive.mjs +27 -20
  52. package/esm2022/src/v-angular/dropdown/typeahead/typeahead.module.mjs +21 -21
  53. package/esm2022/src/v-angular/external-link/external-link.directive.mjs +5 -5
  54. package/esm2022/src/v-angular/external-link/external-link.module.mjs +9 -9
  55. package/esm2022/src/v-angular/i18n/i18n.module.mjs +12 -12
  56. package/esm2022/src/v-angular/i18n/i18n.test.module.mjs +6 -6
  57. package/esm2022/src/v-angular/info-circle/info-circle.component.mjs +6 -6
  58. package/esm2022/src/v-angular/info-circle/info-circle.module.mjs +11 -11
  59. package/esm2022/src/v-angular/input/input.component.mjs +11 -15
  60. package/esm2022/src/v-angular/input/input.module.mjs +27 -22
  61. package/esm2022/src/v-angular/input-mask/input-mask.directive.mjs +6 -6
  62. package/esm2022/src/v-angular/input-mask/input-mask.module.mjs +10 -10
  63. package/esm2022/src/v-angular/modal/dialog/dialog.component.mjs +53 -31
  64. package/esm2022/src/v-angular/modal/fold-out/fold-out.component.mjs +116 -16
  65. package/esm2022/src/v-angular/modal/fold-out/fold-out.directive.mjs +5 -5
  66. package/esm2022/src/v-angular/modal/fold-out/keyboard-key.enum.mjs +9 -0
  67. package/esm2022/src/v-angular/modal/modal.module.mjs +38 -27
  68. package/esm2022/src/v-angular/modal/slide-out/slide-out.component.mjs +35 -12
  69. package/esm2022/src/v-angular/pagination/index.mjs +3 -0
  70. package/esm2022/src/v-angular/pagination/pagination.component.mjs +144 -0
  71. package/esm2022/src/v-angular/pagination/pagination.module.mjs +37 -0
  72. package/esm2022/src/v-angular/pagination/sebgroup-green-angular-src-v-angular-pagination.mjs +5 -0
  73. package/esm2022/src/v-angular/radio/radio.component.mjs +14 -12
  74. package/esm2022/src/v-angular/radio/radio.module.mjs +12 -11
  75. package/esm2022/src/v-angular/slug/slug.module.mjs +6 -6
  76. package/esm2022/src/v-angular/table/index.mjs +9 -0
  77. package/esm2022/src/v-angular/table/sebgroup-green-angular-src-v-angular-table.mjs +5 -0
  78. package/esm2022/src/v-angular/table/table.component.mjs +387 -0
  79. package/esm2022/src/v-angular/table/table.directive.mjs +110 -0
  80. package/esm2022/src/v-angular/table/table.models.mjs +2 -0
  81. package/esm2022/src/v-angular/table/table.module.mjs +40 -0
  82. package/esm2022/src/v-angular/table/table.tools.mjs +29 -0
  83. package/esm2022/src/v-angular/table/tr-thook.pipe.mjs +22 -0
  84. package/esm2022/src/v-angular/tabs/index.mjs +8 -0
  85. package/esm2022/src/v-angular/tabs/sebgroup-green-angular-src-v-angular-tabs.mjs +5 -0
  86. package/esm2022/src/v-angular/tabs/tab.directive.mjs +81 -0
  87. package/esm2022/src/v-angular/tabs/tabs.component.mjs +262 -0
  88. package/esm2022/src/v-angular/tabs/tabs.models.mjs +2 -0
  89. package/esm2022/src/v-angular/tabs/tabs.module.mjs +21 -0
  90. package/esm2022/src/v-angular/textarea/textarea.component.mjs +9 -7
  91. package/esm2022/src/v-angular/textarea/textarea.module.mjs +27 -13
  92. package/esm2022/src/v-angular/toast/index.mjs +8 -0
  93. package/esm2022/src/v-angular/toast/sebgroup-green-angular-src-v-angular-toast.mjs +5 -0
  94. package/esm2022/src/v-angular/toast/toast-message.service.mjs +63 -0
  95. package/esm2022/src/v-angular/toast/toast.component.mjs +70 -0
  96. package/esm2022/src/v-angular/toast/toast.models.mjs +8 -0
  97. package/esm2022/src/v-angular/toast/toast.module.mjs +21 -0
  98. package/esm2022/src/v-angular/tooltip/tooltip.directive.mjs +35 -15
  99. package/esm2022/src/v-angular/tooltip/tooltip.module.mjs +11 -11
  100. package/esm2022/src/v-angular/tooltip/tooltip.styles.mjs +60 -0
  101. package/esm2022/v-angular/alert/alert.component.mjs +47 -0
  102. package/esm2022/v-angular/alert/alert.models.mjs +8 -0
  103. package/esm2022/v-angular/alert/alert.module.mjs +18 -0
  104. package/esm2022/v-angular/alert/index.mjs +4 -0
  105. package/esm2022/v-angular/base-control-value-accessor/base-control-value-accessor.component.mjs +16 -6
  106. package/esm2022/v-angular/base-control-value-accessor/base-control-value-accessor.module.mjs +9 -9
  107. package/esm2022/v-angular/breadcrumbs/breadcrumbs.component.mjs +5 -5
  108. package/esm2022/v-angular/breadcrumbs/breadcrumbs.module.mjs +11 -11
  109. package/esm2022/v-angular/button/button.component.mjs +9 -9
  110. package/esm2022/v-angular/button/button.module.mjs +11 -11
  111. package/esm2022/v-angular/card/card.component.mjs +6 -6
  112. package/esm2022/v-angular/card/card.module.mjs +9 -9
  113. package/esm2022/v-angular/character-countdown/character-countdown.module.mjs +6 -6
  114. package/esm2022/v-angular/checkbox/checkbox.component.mjs +9 -7
  115. package/esm2022/v-angular/checkbox/checkbox.module.mjs +14 -12
  116. package/esm2022/v-angular/datepicker/components/calendar/calendar.component.mjs +200 -0
  117. package/esm2022/v-angular/datepicker/components/calendar-control/calendar-control.component.mjs +115 -0
  118. package/esm2022/v-angular/datepicker/components/date-input/date-input.component.mjs +203 -0
  119. package/esm2022/v-angular/datepicker/components/datepicker/datepicker.component.mjs +135 -0
  120. package/esm2022/v-angular/datepicker/date-control-value-accessor/date-control-value-accessor.component.mjs +408 -0
  121. package/esm2022/v-angular/datepicker/datepicker.globals.mjs +20 -0
  122. package/esm2022/v-angular/datepicker/datepicker.models.mjs +56 -0
  123. package/esm2022/v-angular/datepicker/datepicker.module.mjs +63 -0
  124. package/esm2022/v-angular/datepicker/datepicker.utils.mjs +196 -0
  125. package/esm2022/v-angular/datepicker/directives/calendar-date.directive.mjs +47 -0
  126. package/esm2022/v-angular/datepicker/index.mjs +17 -0
  127. package/esm2022/v-angular/datepicker/models/dates.mjs +291 -0
  128. package/esm2022/v-angular/datepicker/pipes/date-thook.pipe.mjs +30 -0
  129. package/esm2022/v-angular/datepicker/pipes/is-disabled.pipe.mjs +37 -0
  130. package/esm2022/v-angular/datepicker/pipes/matches.pipe.mjs +17 -0
  131. package/esm2022/v-angular/drag-drop/drag-drop.component.mjs +497 -0
  132. package/esm2022/v-angular/drag-drop/drag-drop.models.mjs +2 -0
  133. package/esm2022/v-angular/drag-drop/drag-drop.module.mjs +49 -0
  134. package/esm2022/v-angular/drag-drop/drag-drop.pipes.mjs +70 -0
  135. package/esm2022/v-angular/drag-drop/drag-drop.utils.mjs +76 -0
  136. package/esm2022/v-angular/drag-drop/index.mjs +5 -0
  137. package/esm2022/v-angular/dropdown/dropdown-list/dropdown-list.component.mjs +24 -9
  138. package/esm2022/v-angular/dropdown/dropdown.component.mjs +16 -9
  139. package/esm2022/v-angular/dropdown/dropdown.module.mjs +31 -15
  140. package/esm2022/v-angular/dropdown/typeahead/typeahead-dropdown-list/typeahead-dropdown-list.component.mjs +8 -8
  141. package/esm2022/v-angular/dropdown/typeahead/typeahead-highlight/typeahead-highlight.component.mjs +5 -5
  142. package/esm2022/v-angular/dropdown/typeahead/typeahead-input/typeahead-input.component.mjs +17 -10
  143. package/esm2022/v-angular/dropdown/typeahead/typeahead.directive.mjs +27 -20
  144. package/esm2022/v-angular/dropdown/typeahead/typeahead.module.mjs +21 -21
  145. package/esm2022/v-angular/external-link/external-link.directive.mjs +37 -0
  146. package/esm2022/v-angular/external-link/external-link.module.mjs +18 -0
  147. package/esm2022/v-angular/external-link/index.mjs +3 -0
  148. package/esm2022/v-angular/i18n/i18n.module.mjs +12 -12
  149. package/esm2022/v-angular/i18n/i18n.test.module.mjs +6 -6
  150. package/esm2022/v-angular/index.mjs +10 -1
  151. package/esm2022/v-angular/info-circle/info-circle.component.mjs +6 -6
  152. package/esm2022/v-angular/info-circle/info-circle.module.mjs +11 -11
  153. package/esm2022/v-angular/input/input.component.mjs +11 -15
  154. package/esm2022/v-angular/input/input.module.mjs +27 -22
  155. package/esm2022/v-angular/input-mask/input-mask.directive.mjs +6 -6
  156. package/esm2022/v-angular/input-mask/input-mask.module.mjs +10 -10
  157. package/esm2022/v-angular/modal/dialog/dialog.component.mjs +53 -31
  158. package/esm2022/v-angular/modal/fold-out/fold-out.component.mjs +116 -16
  159. package/esm2022/v-angular/modal/fold-out/fold-out.directive.mjs +5 -5
  160. package/esm2022/v-angular/modal/fold-out/keyboard-key.enum.mjs +9 -0
  161. package/esm2022/v-angular/modal/modal.module.mjs +38 -27
  162. package/esm2022/v-angular/modal/slide-out/slide-out.component.mjs +35 -12
  163. package/esm2022/v-angular/pagination/index.mjs +3 -0
  164. package/esm2022/v-angular/pagination/pagination.component.mjs +144 -0
  165. package/esm2022/v-angular/pagination/pagination.module.mjs +37 -0
  166. package/esm2022/v-angular/radio/radio.component.mjs +14 -12
  167. package/esm2022/v-angular/radio/radio.module.mjs +12 -11
  168. package/esm2022/v-angular/slug/index.mjs +3 -0
  169. package/esm2022/v-angular/slug/slug.module.mjs +18 -0
  170. package/esm2022/v-angular/slug/slug.pipe.mjs +27 -0
  171. package/esm2022/v-angular/table/index.mjs +9 -0
  172. package/esm2022/v-angular/table/table.component.mjs +387 -0
  173. package/esm2022/v-angular/table/table.directive.mjs +110 -0
  174. package/esm2022/v-angular/table/table.models.mjs +2 -0
  175. package/esm2022/v-angular/table/table.module.mjs +40 -0
  176. package/esm2022/v-angular/table/table.tools.mjs +29 -0
  177. package/esm2022/v-angular/table/tr-thook.pipe.mjs +22 -0
  178. package/esm2022/v-angular/tabs/index.mjs +8 -0
  179. package/esm2022/v-angular/tabs/tab.directive.mjs +81 -0
  180. package/esm2022/v-angular/tabs/tabs.component.mjs +262 -0
  181. package/esm2022/v-angular/tabs/tabs.models.mjs +2 -0
  182. package/esm2022/v-angular/tabs/tabs.module.mjs +21 -0
  183. package/esm2022/v-angular/textarea/textarea.component.mjs +9 -7
  184. package/esm2022/v-angular/textarea/textarea.module.mjs +27 -13
  185. package/esm2022/v-angular/toast/index.mjs +8 -0
  186. package/esm2022/v-angular/toast/toast-message.service.mjs +63 -0
  187. package/esm2022/v-angular/toast/toast.component.mjs +70 -0
  188. package/esm2022/v-angular/toast/toast.models.mjs +8 -0
  189. package/esm2022/v-angular/toast/toast.module.mjs +21 -0
  190. package/esm2022/v-angular/tooltip/tooltip.directive.mjs +35 -15
  191. package/esm2022/v-angular/tooltip/tooltip.module.mjs +11 -11
  192. package/esm2022/v-angular/tooltip/tooltip.styles.mjs +60 -0
  193. package/esm2022/v-angular/v-angular.module.mjs +104 -68
  194. package/fesm2022/sebgroup-green-angular-src-v-angular-account-number.mjs +76 -0
  195. package/fesm2022/sebgroup-green-angular-src-v-angular-account-number.mjs.map +1 -0
  196. package/fesm2022/sebgroup-green-angular-src-v-angular-alert.mjs +76 -0
  197. package/fesm2022/sebgroup-green-angular-src-v-angular-alert.mjs.map +1 -0
  198. package/fesm2022/sebgroup-green-angular-src-v-angular-base-control-value-accessor.mjs +23 -13
  199. package/fesm2022/sebgroup-green-angular-src-v-angular-base-control-value-accessor.mjs.map +1 -1
  200. package/fesm2022/sebgroup-green-angular-src-v-angular-breadcrumbs.mjs +14 -14
  201. package/fesm2022/sebgroup-green-angular-src-v-angular-breadcrumbs.mjs.map +1 -1
  202. package/fesm2022/sebgroup-green-angular-src-v-angular-button.mjs +18 -18
  203. package/fesm2022/sebgroup-green-angular-src-v-angular-button.mjs.map +1 -1
  204. package/fesm2022/sebgroup-green-angular-src-v-angular-card.mjs +13 -13
  205. package/fesm2022/sebgroup-green-angular-src-v-angular-card.mjs.map +1 -1
  206. package/fesm2022/sebgroup-green-angular-src-v-angular-character-countdown.mjs +6 -6
  207. package/fesm2022/sebgroup-green-angular-src-v-angular-character-countdown.mjs.map +1 -1
  208. package/fesm2022/sebgroup-green-angular-src-v-angular-checkbox.mjs +21 -17
  209. package/fesm2022/sebgroup-green-angular-src-v-angular-checkbox.mjs.map +1 -1
  210. package/fesm2022/sebgroup-green-angular-src-v-angular-core.mjs +34 -0
  211. package/fesm2022/sebgroup-green-angular-src-v-angular-core.mjs.map +1 -1
  212. package/fesm2022/sebgroup-green-angular-src-v-angular-datepicker.mjs +1759 -0
  213. package/fesm2022/sebgroup-green-angular-src-v-angular-datepicker.mjs.map +1 -0
  214. package/fesm2022/sebgroup-green-angular-src-v-angular-drag-drop.mjs +687 -0
  215. package/fesm2022/sebgroup-green-angular-src-v-angular-drag-drop.mjs.map +1 -0
  216. package/fesm2022/sebgroup-green-angular-src-v-angular-dropdown.mjs +126 -74
  217. package/fesm2022/sebgroup-green-angular-src-v-angular-dropdown.mjs.map +1 -1
  218. package/fesm2022/sebgroup-green-angular-src-v-angular-external-link.mjs +12 -12
  219. package/fesm2022/sebgroup-green-angular-src-v-angular-external-link.mjs.map +1 -1
  220. package/fesm2022/sebgroup-green-angular-src-v-angular-i18n.mjs +17 -17
  221. package/fesm2022/sebgroup-green-angular-src-v-angular-i18n.mjs.map +1 -1
  222. package/fesm2022/sebgroup-green-angular-src-v-angular-info-circle.mjs +15 -15
  223. package/fesm2022/sebgroup-green-angular-src-v-angular-info-circle.mjs.map +1 -1
  224. package/fesm2022/sebgroup-green-angular-src-v-angular-input-mask.mjs +14 -14
  225. package/fesm2022/sebgroup-green-angular-src-v-angular-input-mask.mjs.map +1 -1
  226. package/fesm2022/sebgroup-green-angular-src-v-angular-input.mjs +36 -35
  227. package/fesm2022/sebgroup-green-angular-src-v-angular-input.mjs.map +1 -1
  228. package/fesm2022/sebgroup-green-angular-src-v-angular-modal.mjs +246 -81
  229. package/fesm2022/sebgroup-green-angular-src-v-angular-modal.mjs.map +1 -1
  230. package/fesm2022/sebgroup-green-angular-src-v-angular-pagination.mjs +185 -0
  231. package/fesm2022/sebgroup-green-angular-src-v-angular-pagination.mjs.map +1 -0
  232. package/fesm2022/sebgroup-green-angular-src-v-angular-radio.mjs +24 -21
  233. package/fesm2022/sebgroup-green-angular-src-v-angular-radio.mjs.map +1 -1
  234. package/fesm2022/sebgroup-green-angular-src-v-angular-slug.mjs +6 -6
  235. package/fesm2022/sebgroup-green-angular-src-v-angular-slug.mjs.map +1 -1
  236. package/fesm2022/sebgroup-green-angular-src-v-angular-table.mjs +585 -0
  237. package/fesm2022/sebgroup-green-angular-src-v-angular-table.mjs.map +1 -0
  238. package/fesm2022/sebgroup-green-angular-src-v-angular-tabs.mjs +367 -0
  239. package/fesm2022/sebgroup-green-angular-src-v-angular-tabs.mjs.map +1 -0
  240. package/fesm2022/sebgroup-green-angular-src-v-angular-textarea.mjs +33 -18
  241. package/fesm2022/sebgroup-green-angular-src-v-angular-textarea.mjs.map +1 -1
  242. package/fesm2022/sebgroup-green-angular-src-v-angular-toast.mjs +166 -0
  243. package/fesm2022/sebgroup-green-angular-src-v-angular-toast.mjs.map +1 -0
  244. package/fesm2022/sebgroup-green-angular-src-v-angular-tooltip.mjs +103 -24
  245. package/fesm2022/sebgroup-green-angular-src-v-angular-tooltip.mjs.map +1 -1
  246. package/fesm2022/sebgroup-green-angular-v-angular.mjs +6295 -2165
  247. package/fesm2022/sebgroup-green-angular-v-angular.mjs.map +1 -1
  248. package/package.json +51 -3
  249. package/src/v-angular/account-number/README.md +70 -0
  250. package/src/v-angular/account-number/account-number.module.d.ts +8 -0
  251. package/src/v-angular/account-number/account-number.pipe.d.ts +32 -0
  252. package/src/v-angular/account-number/index.d.ts +2 -0
  253. package/src/v-angular/alert/alert.component.d.ts +19 -0
  254. package/src/v-angular/alert/alert.models.d.ts +13 -0
  255. package/src/v-angular/alert/alert.module.d.ts +8 -0
  256. package/src/v-angular/alert/index.d.ts +3 -0
  257. package/src/v-angular/base-control-value-accessor/base-control-value-accessor.component.d.ts +10 -4
  258. package/src/v-angular/base-control-value-accessor/base-control-value-accessor.module.d.ts +4 -4
  259. package/src/v-angular/breadcrumbs/breadcrumbs.component.d.ts +4 -4
  260. package/src/v-angular/breadcrumbs/breadcrumbs.module.d.ts +4 -4
  261. package/src/v-angular/button/button.component.d.ts +5 -5
  262. package/src/v-angular/button/button.module.d.ts +4 -4
  263. package/src/v-angular/card/card.component.d.ts +3 -3
  264. package/src/v-angular/card/card.module.d.ts +4 -4
  265. package/src/v-angular/character-countdown/character-countdown.module.d.ts +4 -4
  266. package/src/v-angular/checkbox/checkbox.component.d.ts +6 -5
  267. package/src/v-angular/checkbox/checkbox.module.d.ts +5 -4
  268. package/src/v-angular/core/core.utils.d.ts +1 -0
  269. package/src/v-angular/datepicker/components/calendar/calendar.component.d.ts +36 -0
  270. package/src/v-angular/datepicker/components/calendar-control/calendar-control.component.d.ts +30 -0
  271. package/src/v-angular/datepicker/components/date-input/date-input.component.d.ts +102 -0
  272. package/src/v-angular/datepicker/components/datepicker/datepicker.component.d.ts +62 -0
  273. package/src/v-angular/datepicker/date-control-value-accessor/date-control-value-accessor.component.d.ts +165 -0
  274. package/src/v-angular/datepicker/datepicker.globals.d.ts +13 -0
  275. package/src/v-angular/datepicker/datepicker.models.d.ts +50 -0
  276. package/src/v-angular/datepicker/datepicker.module.d.ts +19 -0
  277. package/src/v-angular/datepicker/datepicker.utils.d.ts +39 -0
  278. package/src/v-angular/datepicker/directives/calendar-date.directive.d.ts +21 -0
  279. package/src/v-angular/datepicker/index.d.ts +13 -0
  280. package/src/v-angular/datepicker/models/dates.d.ts +15 -0
  281. package/src/v-angular/datepicker/pipes/date-thook.pipe.d.ts +8 -0
  282. package/src/v-angular/datepicker/pipes/is-disabled.pipe.d.ts +8 -0
  283. package/src/v-angular/datepicker/pipes/matches.pipe.d.ts +7 -0
  284. package/src/v-angular/drag-drop/drag-drop.component.d.ts +131 -0
  285. package/src/v-angular/drag-drop/drag-drop.models.d.ts +49 -0
  286. package/src/v-angular/drag-drop/drag-drop.module.d.ts +13 -0
  287. package/src/v-angular/drag-drop/drag-drop.pipes.d.ts +40 -0
  288. package/src/v-angular/drag-drop/drag-drop.utils.d.ts +33 -0
  289. package/src/v-angular/drag-drop/index.d.ts +4 -0
  290. package/src/v-angular/dropdown/dropdown-list/dropdown-list.component.d.ts +11 -4
  291. package/src/v-angular/dropdown/dropdown.component.d.ts +10 -6
  292. package/src/v-angular/dropdown/dropdown.module.d.ts +8 -7
  293. package/src/v-angular/dropdown/typeahead/typeahead-dropdown-list/typeahead-dropdown-list.component.d.ts +6 -6
  294. package/src/v-angular/dropdown/typeahead/typeahead-highlight/typeahead-highlight.component.d.ts +3 -3
  295. package/src/v-angular/dropdown/typeahead/typeahead-input/typeahead-input.component.d.ts +8 -6
  296. package/src/v-angular/dropdown/typeahead/typeahead.directive.d.ts +14 -12
  297. package/src/v-angular/dropdown/typeahead/typeahead.module.d.ts +4 -4
  298. package/src/v-angular/external-link/external-link.directive.d.ts +3 -3
  299. package/src/v-angular/external-link/external-link.module.d.ts +4 -4
  300. package/src/v-angular/i18n/i18n.module.d.ts +7 -7
  301. package/src/v-angular/i18n/i18n.test.module.d.ts +4 -4
  302. package/src/v-angular/info-circle/info-circle.component.d.ts +4 -4
  303. package/src/v-angular/info-circle/info-circle.module.d.ts +4 -4
  304. package/src/v-angular/input/input.component.d.ts +5 -10
  305. package/src/v-angular/input/input.module.d.ts +5 -4
  306. package/src/v-angular/input-mask/input-mask.directive.d.ts +3 -3
  307. package/src/v-angular/input-mask/input-mask.module.d.ts +5 -5
  308. package/src/v-angular/modal/dialog/dialog.component.d.ts +16 -7
  309. package/src/v-angular/modal/fold-out/fold-out.component.d.ts +34 -11
  310. package/src/v-angular/modal/fold-out/fold-out.directive.d.ts +3 -3
  311. package/src/v-angular/modal/fold-out/keyboard-key.enum.d.ts +7 -0
  312. package/src/v-angular/modal/modal.module.d.ts +4 -4
  313. package/src/v-angular/modal/slide-out/slide-out.component.d.ts +13 -6
  314. package/src/v-angular/pagination/index.d.ts +2 -0
  315. package/src/v-angular/pagination/pagination.component.d.ts +64 -0
  316. package/src/v-angular/pagination/pagination.module.d.ts +12 -0
  317. package/src/v-angular/radio/radio.component.d.ts +14 -13
  318. package/src/v-angular/radio/radio.module.d.ts +5 -4
  319. package/src/v-angular/slug/slug.module.d.ts +4 -4
  320. package/src/v-angular/table/index.d.ts +5 -0
  321. package/src/v-angular/table/table.component.d.ts +229 -0
  322. package/src/v-angular/table/table.directive.d.ts +36 -0
  323. package/src/v-angular/table/table.models.d.ts +62 -0
  324. package/src/v-angular/table/table.module.d.ts +12 -0
  325. package/src/v-angular/table/table.tools.d.ts +5 -0
  326. package/src/v-angular/table/tr-thook.pipe.d.ts +7 -0
  327. package/src/v-angular/tabs/index.d.ts +4 -0
  328. package/src/v-angular/tabs/tab.directive.d.ts +37 -0
  329. package/src/v-angular/tabs/tabs.component.d.ts +65 -0
  330. package/src/v-angular/tabs/tabs.models.d.ts +25 -0
  331. package/src/v-angular/tabs/tabs.module.d.ts +11 -0
  332. package/src/v-angular/textarea/textarea.component.d.ts +6 -5
  333. package/src/v-angular/textarea/textarea.module.d.ts +6 -4
  334. package/src/v-angular/toast/index.d.ts +4 -0
  335. package/src/v-angular/toast/toast-message.service.d.ts +17 -0
  336. package/src/v-angular/toast/toast.component.d.ts +22 -0
  337. package/src/v-angular/toast/toast.models.d.ts +15 -0
  338. package/src/v-angular/toast/toast.module.d.ts +10 -0
  339. package/src/v-angular/tooltip/tooltip.directive.d.ts +5 -3
  340. package/src/v-angular/tooltip/tooltip.module.d.ts +4 -4
  341. package/src/v-angular/tooltip/tooltip.styles.d.ts +11 -0
  342. package/v-angular/alert/alert.component.d.ts +19 -0
  343. package/v-angular/alert/alert.models.d.ts +13 -0
  344. package/v-angular/alert/alert.module.d.ts +8 -0
  345. package/v-angular/alert/index.d.ts +3 -0
  346. package/v-angular/base-control-value-accessor/base-control-value-accessor.component.d.ts +10 -4
  347. package/v-angular/base-control-value-accessor/base-control-value-accessor.module.d.ts +4 -4
  348. package/v-angular/breadcrumbs/breadcrumbs.component.d.ts +4 -4
  349. package/v-angular/breadcrumbs/breadcrumbs.module.d.ts +4 -4
  350. package/v-angular/button/button.component.d.ts +5 -5
  351. package/v-angular/button/button.module.d.ts +4 -4
  352. package/v-angular/card/card.component.d.ts +3 -3
  353. package/v-angular/card/card.module.d.ts +4 -4
  354. package/v-angular/character-countdown/character-countdown.module.d.ts +4 -4
  355. package/v-angular/checkbox/checkbox.component.d.ts +6 -5
  356. package/v-angular/checkbox/checkbox.module.d.ts +5 -4
  357. package/v-angular/datepicker/components/calendar/calendar.component.d.ts +36 -0
  358. package/v-angular/datepicker/components/calendar-control/calendar-control.component.d.ts +30 -0
  359. package/v-angular/datepicker/components/date-input/date-input.component.d.ts +102 -0
  360. package/v-angular/datepicker/components/datepicker/datepicker.component.d.ts +62 -0
  361. package/v-angular/datepicker/date-control-value-accessor/date-control-value-accessor.component.d.ts +165 -0
  362. package/v-angular/datepicker/datepicker.globals.d.ts +13 -0
  363. package/v-angular/datepicker/datepicker.models.d.ts +50 -0
  364. package/v-angular/datepicker/datepicker.module.d.ts +19 -0
  365. package/v-angular/datepicker/datepicker.utils.d.ts +39 -0
  366. package/v-angular/datepicker/directives/calendar-date.directive.d.ts +21 -0
  367. package/v-angular/datepicker/index.d.ts +13 -0
  368. package/v-angular/datepicker/models/dates.d.ts +15 -0
  369. package/v-angular/datepicker/pipes/date-thook.pipe.d.ts +8 -0
  370. package/v-angular/datepicker/pipes/is-disabled.pipe.d.ts +8 -0
  371. package/v-angular/datepicker/pipes/matches.pipe.d.ts +7 -0
  372. package/v-angular/drag-drop/drag-drop.component.d.ts +131 -0
  373. package/v-angular/drag-drop/drag-drop.models.d.ts +49 -0
  374. package/v-angular/drag-drop/drag-drop.module.d.ts +13 -0
  375. package/v-angular/drag-drop/drag-drop.pipes.d.ts +40 -0
  376. package/v-angular/drag-drop/drag-drop.utils.d.ts +33 -0
  377. package/v-angular/drag-drop/index.d.ts +4 -0
  378. package/v-angular/dropdown/dropdown-list/dropdown-list.component.d.ts +11 -4
  379. package/v-angular/dropdown/dropdown.component.d.ts +10 -6
  380. package/v-angular/dropdown/dropdown.module.d.ts +8 -7
  381. package/v-angular/dropdown/typeahead/typeahead-dropdown-list/typeahead-dropdown-list.component.d.ts +6 -6
  382. package/v-angular/dropdown/typeahead/typeahead-highlight/typeahead-highlight.component.d.ts +3 -3
  383. package/v-angular/dropdown/typeahead/typeahead-input/typeahead-input.component.d.ts +8 -6
  384. package/v-angular/dropdown/typeahead/typeahead.directive.d.ts +14 -12
  385. package/v-angular/dropdown/typeahead/typeahead.module.d.ts +4 -4
  386. package/v-angular/external-link/external-link.directive.d.ts +17 -0
  387. package/v-angular/external-link/external-link.module.d.ts +8 -0
  388. package/v-angular/external-link/index.d.ts +2 -0
  389. package/v-angular/i18n/i18n.module.d.ts +7 -7
  390. package/v-angular/i18n/i18n.test.module.d.ts +4 -4
  391. package/v-angular/index.d.ts +9 -0
  392. package/v-angular/info-circle/info-circle.component.d.ts +4 -4
  393. package/v-angular/info-circle/info-circle.module.d.ts +4 -4
  394. package/v-angular/input/input.component.d.ts +5 -10
  395. package/v-angular/input/input.module.d.ts +5 -4
  396. package/v-angular/input-mask/input-mask.directive.d.ts +3 -3
  397. package/v-angular/input-mask/input-mask.module.d.ts +5 -5
  398. package/v-angular/modal/dialog/dialog.component.d.ts +16 -7
  399. package/v-angular/modal/fold-out/fold-out.component.d.ts +34 -11
  400. package/v-angular/modal/fold-out/fold-out.directive.d.ts +3 -3
  401. package/v-angular/modal/fold-out/keyboard-key.enum.d.ts +7 -0
  402. package/v-angular/modal/modal.module.d.ts +4 -4
  403. package/v-angular/modal/slide-out/slide-out.component.d.ts +13 -6
  404. package/v-angular/pagination/index.d.ts +2 -0
  405. package/v-angular/pagination/pagination.component.d.ts +64 -0
  406. package/v-angular/pagination/pagination.module.d.ts +12 -0
  407. package/v-angular/radio/radio.component.d.ts +14 -13
  408. package/v-angular/radio/radio.module.d.ts +5 -4
  409. package/v-angular/slug/index.d.ts +2 -0
  410. package/v-angular/slug/slug.module.d.ts +8 -0
  411. package/v-angular/slug/slug.pipe.d.ts +12 -0
  412. package/v-angular/table/index.d.ts +5 -0
  413. package/v-angular/table/table.component.d.ts +229 -0
  414. package/v-angular/table/table.directive.d.ts +36 -0
  415. package/v-angular/table/table.models.d.ts +62 -0
  416. package/v-angular/table/table.module.d.ts +12 -0
  417. package/v-angular/table/table.tools.d.ts +5 -0
  418. package/v-angular/table/tr-thook.pipe.d.ts +7 -0
  419. package/v-angular/tabs/index.d.ts +4 -0
  420. package/v-angular/tabs/tab.directive.d.ts +37 -0
  421. package/v-angular/tabs/tabs.component.d.ts +65 -0
  422. package/v-angular/tabs/tabs.models.d.ts +25 -0
  423. package/v-angular/tabs/tabs.module.d.ts +11 -0
  424. package/v-angular/textarea/textarea.component.d.ts +6 -5
  425. package/v-angular/textarea/textarea.module.d.ts +6 -4
  426. package/v-angular/toast/index.d.ts +4 -0
  427. package/v-angular/toast/toast-message.service.d.ts +17 -0
  428. package/v-angular/toast/toast.component.d.ts +22 -0
  429. package/v-angular/toast/toast.models.d.ts +15 -0
  430. package/v-angular/toast/toast.module.d.ts +10 -0
  431. package/v-angular/tooltip/tooltip.directive.d.ts +5 -3
  432. package/v-angular/tooltip/tooltip.module.d.ts +4 -4
  433. package/v-angular/tooltip/tooltip.styles.d.ts +11 -0
  434. package/v-angular/v-angular.module.d.ts +27 -18
@@ -0,0 +1,585 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Directive, Input, HostBinding, Pipe, EventEmitter, Component, ContentChildren, ContentChild, Output, NgModule } from '@angular/core';
3
+ import * as i2 from '@angular/forms';
4
+ import { UntypedFormGroup, UntypedFormControl, ReactiveFormsModule } from '@angular/forms';
5
+ import { debounceTime, map } from 'rxjs/operators';
6
+ import * as i1 from '@angular/common';
7
+ import { CommonModule } from '@angular/common';
8
+ import * as i3 from '@jsverse/transloco';
9
+ import { TranslocoModule } from '@jsverse/transloco';
10
+
11
+ class TableDirective {
12
+ constructor() {
13
+ this.columnType = 'text';
14
+ this.thook = 'table';
15
+ }
16
+ get numericColumn() {
17
+ return this.columnType === 'numeric';
18
+ }
19
+ get isSortable() {
20
+ return !!this.sortable;
21
+ }
22
+ get orderAscending() {
23
+ return this.sortOrder === 'asc' && !!this.sortable;
24
+ }
25
+ get orderDescending() {
26
+ return this.sortOrder === 'desc' && !!this.sortable;
27
+ }
28
+ get negativeValue() {
29
+ if (!isNaN(this.value))
30
+ return +this.value < 0;
31
+ return false;
32
+ }
33
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
34
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.12", type: TableDirective, selector: "[columnType]", inputs: { columnType: "columnType", sortable: "sortable", sortOrder: "sortOrder", value: "value", thook: "thook" }, host: { properties: { "attr.data-thook": "this.thook", "class.gds-table__numeric-col": "this.numericColumn", "class.gds-table__sortable-col": "this.isSortable", "class.gds-table__sortable-col--asc": "this.orderAscending", "class.gds-table__sortable-col--desc": "this.orderDescending", "class.gds-table__negative-col": "this.negativeValue" } }, ngImport: i0 }); }
35
+ }
36
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableDirective, decorators: [{
37
+ type: Directive,
38
+ args: [{
39
+ // eslint-disable-next-line @angular-eslint/directive-selector
40
+ selector: '[columnType]',
41
+ }]
42
+ }], propDecorators: { columnType: [{
43
+ type: Input
44
+ }], sortable: [{
45
+ type: Input
46
+ }], sortOrder: [{
47
+ type: Input
48
+ }], value: [{
49
+ type: Input
50
+ }], thook: [{
51
+ type: HostBinding,
52
+ args: ['attr.data-thook']
53
+ }, {
54
+ type: Input
55
+ }], numericColumn: [{
56
+ type: HostBinding,
57
+ args: ['class.' + "gds-table__numeric-col" /* ColumnCSSClass.Numeric */]
58
+ }], isSortable: [{
59
+ type: HostBinding,
60
+ args: ['class.' + "gds-table__sortable-col" /* ColumnCSSClass.Sortable */]
61
+ }], orderAscending: [{
62
+ type: HostBinding,
63
+ args: ['class.' + "gds-table__sortable-col--asc" /* ColumnCSSClass.Ascending */]
64
+ }], orderDescending: [{
65
+ type: HostBinding,
66
+ args: ['class.' + "gds-table__sortable-col--desc" /* ColumnCSSClass.Descending */]
67
+ }], negativeValue: [{
68
+ type: HostBinding,
69
+ args: ['class.' + "gds-table__negative-col" /* ColumnCSSClass.Negative */]
70
+ }] } });
71
+ class TableTemplateDirective {
72
+ constructor(templateRef) {
73
+ this.templateRef = templateRef;
74
+ this.tableColumnTarget = 'both';
75
+ }
76
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableTemplateDirective, deps: [{ token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive }); }
77
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.12", type: TableTemplateDirective, selector: "[tableColumn]", inputs: { tableColumn: "tableColumn", tableColumnTarget: "tableColumnTarget" }, ngImport: i0 }); }
78
+ }
79
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableTemplateDirective, decorators: [{
80
+ type: Directive,
81
+ args: [{
82
+ // eslint-disable-next-line @angular-eslint/directive-selector
83
+ selector: '[tableColumn]',
84
+ }]
85
+ }], ctorParameters: () => [{ type: i0.TemplateRef }], propDecorators: { tableColumn: [{
86
+ type: Input
87
+ }], tableColumnTarget: [{
88
+ type: Input
89
+ }] } });
90
+ class TableFooterTemplateDirective {
91
+ constructor(templateRef) {
92
+ this.templateRef = templateRef;
93
+ }
94
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableFooterTemplateDirective, deps: [{ token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive }); }
95
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.12", type: TableFooterTemplateDirective, selector: "[tableFooter]", ngImport: i0 }); }
96
+ }
97
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableFooterTemplateDirective, decorators: [{
98
+ type: Directive,
99
+ args: [{
100
+ // eslint-disable-next-line @angular-eslint/directive-selector
101
+ selector: '[tableFooter]',
102
+ }]
103
+ }], ctorParameters: () => [{ type: i0.TemplateRef }] });
104
+ class TableAppendableRowsTemplateDirective {
105
+ constructor(templateRef) {
106
+ this.templateRef = templateRef;
107
+ }
108
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableAppendableRowsTemplateDirective, deps: [{ token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive }); }
109
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.12", type: TableAppendableRowsTemplateDirective, selector: "[tableAppendableRows]", ngImport: i0 }); }
110
+ }
111
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableAppendableRowsTemplateDirective, decorators: [{
112
+ type: Directive,
113
+ args: [{
114
+ // eslint-disable-next-line @angular-eslint/directive-selector
115
+ selector: '[tableAppendableRows]',
116
+ }]
117
+ }], ctorParameters: () => [{ type: i0.TemplateRef }] });
118
+
119
+ const getKeyValue = (obj, key) => obj[key];
120
+ const pick = (propertyArray, object) => {
121
+ if (object instanceof Object) {
122
+ return propertyArray.reduce((acc, curr) => ({
123
+ ...acc,
124
+ [curr]: getKeyValue(object, curr),
125
+ }), {});
126
+ }
127
+ throw Error('The value for argument "object" must be an object');
128
+ };
129
+ const orderByDescending = (property) => {
130
+ return (a, b) => {
131
+ if (a[property] > b[property])
132
+ return -1;
133
+ if (a[property] < b[property])
134
+ return 1;
135
+ return 0;
136
+ };
137
+ };
138
+ const orderByAscending = (property) => {
139
+ return (a, b) => {
140
+ if (a[property] < b[property])
141
+ return -1;
142
+ if (a[property] > b[property])
143
+ return 1;
144
+ return 0;
145
+ };
146
+ };
147
+
148
+ class TrThookPipe {
149
+ transform(value, index, thookFn) {
150
+ // call thook fn to set thook for active row
151
+ if (thookFn != null) {
152
+ return thookFn(value);
153
+ }
154
+ // default thook
155
+ return `table-row-${index}`;
156
+ }
157
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TrThookPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
158
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "17.3.12", ngImport: i0, type: TrThookPipe, isStandalone: true, name: "trThook" }); }
159
+ }
160
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TrThookPipe, decorators: [{
161
+ type: Pipe,
162
+ args: [{
163
+ name: 'trThook',
164
+ standalone: true,
165
+ }]
166
+ }] });
167
+
168
+ let staticInitId = 0;
169
+ function objectFromEntries(entryMap) {
170
+ const fromEntries = {};
171
+ for (const [key, value] of entryMap) {
172
+ fromEntries[key] = value;
173
+ }
174
+ return fromEntries;
175
+ }
176
+ /**
177
+ * A table component with built-in sorting and selecting functionality.
178
+ * By default, table cells (i.e. `<td>` elements) and table headers (i.e. `<th>` elements) are populated with text only values.
179
+ *
180
+ * To customize the contents of either the `<td>` or `<th>` elements (like adding color, icons, form fields, extra padding etc.), provide
181
+ * the customized content within a `<ng-template>`-tag, and place the ng-template in the html between the start and ending tag of
182
+ * the `<nggv-table>`. Add a `tableColumn`-attribute to the `<ng-template>`-element, and set the value to the specific column property.
183
+ * Set `tableColumnTarget` to either `th`, `td` or `both` (default) depending on target element type.
184
+ * The entire row from the `@Input() tableData` is available from the context `$implicit` variable.
185
+ *
186
+ * @example
187
+ * <!-- for table cells i.e. td-elements -->
188
+ * <ng-template tableColumn="status" tableColumnTarget="td" let-myDataVar="$implicit" let-status="$implicit.status">
189
+ * <!-- my custom status element -->
190
+ * </ng-template>
191
+ *
192
+ * @example
193
+ * <!-- for table headers i.e. th-elements -->
194
+ * <ng-template tableColumn="status" tableColumnTarget="th" let-myDataVar="$implicit" let-status="$implicit.status">
195
+ * <!-- my custom status element -->
196
+ * </ng-template>
197
+ *
198
+ * It is possible to add custom rows that are appended below data row. Use `<ng-template>`-tag and place the ng-template in the html between the start and ending tag of
199
+ * the `<nggv-table>`. Add a `tableAppendableRows`-attribute to the `<ng-template>`-element. Any `tr` elements that exist within `<ng-template tableAppendableRows>` and `</ng-template>` tags will be put below data row's `tr` element in the table.
200
+ *
201
+ * @example
202
+ * <!-- custom appended rows -->
203
+ * <ng-template tableAppendableRows let-myDataVar="$implicit" let-status="$implicit.status">
204
+ * <tr>
205
+ * <!-- first row's columns -->
206
+ * </tr>
207
+ * <!-- more rows if needed -->
208
+ * </ng-template>
209
+ *
210
+ * If custom styling is needed for data row that has appended rows, you can use data attribute `data-hasrowspan` to distinguish it from data row without appended rows.
211
+ * You can pass your own custom method with conditional logic to define what value will be passed to data-hasrowspan.
212
+ * In addition, hasRowSpan function accepts item from `@Input() tableData` as argument which is of the same type as value passed to context `$implicit` variable.
213
+ * IMPORTANT: use arrow function style for defining function inside component, i.e. `hasRowSpan = (value) => output;`. If regular function will be defined, i.e. `hasRowSpan(value) { return output; }`, binding will not work.
214
+ *
215
+ * @example
216
+ * <!-- inside component
217
+ * class CustomComponent {
218
+ * customHasRowSpanFunction = (item: CustomDataType) => item.appendedRowsData.length > 0 ? true : false;
219
+ * }
220
+ * -->
221
+ * <!-- inside stylesheets
222
+ * [data-hasrowspan="true"] {
223
+ * color: blue;
224
+ * }
225
+ * .appended-row {
226
+ * color: blue;
227
+ * }
228
+ * -->
229
+ * <nggv-table [hasRowSpan]="customHasRowSpanFunction">
230
+ * <!-- custom appended rows -->
231
+ * <ng-template tableAppendableRows let-appendedRowsData="$implicit.appendedRowsData">
232
+ * <tr *ngFor="let appendedRowItem of appendedRowsData" class="appended-row">
233
+ * <td>{{ appendedRowItem }}</td>
234
+ * <!-- other row's columns -->
235
+ * </tr>
236
+ * </ng-template>
237
+ * </nggv-table>
238
+ *
239
+ * In addition, it is possible to add footer for the table. Similarly to adding custom columns, use `<ng-template>`-tag and place the ng-template in the html between the start and ending tag of
240
+ * the `<nggv-table>`. Add a `tableFooter`-attribute to the `<ng-template>`-element. Any elements that exist within `<ng-template tableFooter>` and `</ng-template>` tags will be put to tfoot element inside the table.
241
+ *
242
+ * @example
243
+ * <!-- for table footer i.e. tfoot-element -->
244
+ * <ng-template tableFooter>
245
+ * <tr>
246
+ * <!-- first row's columns -->
247
+ * </tr>
248
+ * <!-- more rows if needed -->
249
+ * </ng-template>
250
+ *
251
+ */
252
+ class TableComponent {
253
+ constructor() {
254
+ /** Emits the table row that was clicked. Works on all columns if not preventDefaultEmit is set for that column. */
255
+ this.ngvRowClick = new EventEmitter();
256
+ /**
257
+ * Emits currently selected and deselected items in the table as key-value pairs.
258
+ * Uses each item`s itemId as key, and a boolean value to describe selected status.
259
+ */
260
+ this.ngvRowSelect = new EventEmitter();
261
+ /**
262
+ * Emits event to signal that the table should be reordered.
263
+ */
264
+ this.ngvOrderBy = new EventEmitter();
265
+ /**
266
+ * Property name used to uniquely describe each item (i.e. row) in the data table.
267
+ * Defaults to \'id\'.
268
+ * Is required if selectable is true.
269
+ */
270
+ this.rowId = 'id';
271
+ /**
272
+ * Function's return value is used for data attribute \'data-hasrowspan\'.
273
+ * If custom hasRowSpan function is not passed to the table,
274
+ * then this function returns undefined value by default which results in \'data-hasrowspan\' attribute being omitted in html
275
+ * (angular omits attributes that contain null or undefined value).
276
+ * IMPORTANT: use arrow function style for defining function inside component, i.e. `hasRowSpan = (value) => output;`. If regular function will be defined, i.e. `hasRowSpan(value) { return output; }`, binding will not work.
277
+ */
278
+ this.hasRowSpan = (_) => undefined;
279
+ /**
280
+ * Used to enable/disable the left-side checkbox column.
281
+ * Defaults to true.
282
+ */
283
+ this.selectable = true;
284
+ /**
285
+ * Allow nggv-table to attempt sorting the data in the table. Not recommended if only a subset is loaded or if the dataset is very large.
286
+ * Disabled by default.
287
+ */
288
+ this.allowLocalSort = false;
289
+ /** Special property used for selecting DOM elements during automated UI testing. */
290
+ this.thook = 'table-select-all';
291
+ /**
292
+ * @internal
293
+ * Internal data structure used to keep track of added content templates used in td elements.
294
+ */
295
+ this.customRowTemplates = new Map();
296
+ /**
297
+ * @internal
298
+ * Internal data structure used to keep track of added content templates used in th elements.
299
+ */
300
+ this.customHeaderTemplates = new Map();
301
+ /**
302
+ * @internal
303
+ * FormGroup containing all row id\'s as controls, and whether these are selected or not as values.
304
+ */
305
+ this.rowSelectors = new UntypedFormGroup({});
306
+ /**
307
+ * @internal
308
+ * Master selector for selecting or deselecting all row selectors.
309
+ */
310
+ this.groupSelector = new UntypedFormControl(false);
311
+ this.selected = [];
312
+ this.subs = [];
313
+ }
314
+ ngOnChanges(changes) {
315
+ // table data was updated and the rows should be selectable
316
+ if ((changes.tableData?.currentValue && this.selectable) ||
317
+ (changes.selectable?.currentValue === true && this.tableData)) {
318
+ const wasChanged = this.registerSelectableRows(changes.tableData.currentValue);
319
+ if (wasChanged && !this.subs.length) {
320
+ // first time this is run
321
+ const groupSelectorSub = this.groupValueSubscription;
322
+ const rowSelectorSub = this.rowValueSubscription;
323
+ this.subs.push(groupSelectorSub, rowSelectorSub);
324
+ }
325
+ else if (wasChanged) {
326
+ this.rowSelectors.updateValueAndValidity();
327
+ }
328
+ }
329
+ // sort any incoming data
330
+ if (this.allowLocalSort &&
331
+ (changes.tableData?.currentValue || changes.tableColumns?.currentValue)) {
332
+ const orderedByColumn = this.tableColumns?.find((el) => el.order !== undefined);
333
+ if (orderedByColumn)
334
+ this.sortItemsBy(orderedByColumn);
335
+ }
336
+ }
337
+ ngOnInit() {
338
+ this.initId = staticInitId++;
339
+ }
340
+ ngAfterContentInit() {
341
+ // if any custom templates were defined in the template
342
+ if (this.customTemplates.length) {
343
+ // for each template found
344
+ this.customTemplates.map((tableTemplate) => {
345
+ // if target is either 'td' or 'both'
346
+ if (['td', 'both'].includes(tableTemplate.tableColumnTarget)) {
347
+ // add to custom row templates
348
+ this.customRowTemplates.set(tableTemplate.tableColumn, tableTemplate.templateRef);
349
+ }
350
+ // if target is either 'th' or 'both'
351
+ if (['th', 'both'].includes(tableTemplate.tableColumnTarget)) {
352
+ // add to custom header templates
353
+ this.customHeaderTemplates.set(tableTemplate.tableColumn, tableTemplate.templateRef);
354
+ }
355
+ });
356
+ }
357
+ // if appended rows' template is defined in the template
358
+ if (this.appendedRowsTemplate) {
359
+ // set templateRef of appended rows' template to variable
360
+ this.appendedRowsTemplateRef = this.appendedRowsTemplate.templateRef;
361
+ }
362
+ // if custom footer template is defined in the template
363
+ if (this.customFooterTemplate) {
364
+ // set templateRef of table footer to variable
365
+ this.customFooterTemplateRef = this.customFooterTemplate.templateRef;
366
+ }
367
+ }
368
+ ngOnDestroy() {
369
+ this.subs.forEach((sub) => sub.unsubscribe());
370
+ }
371
+ /**
372
+ * @internal
373
+ * Returns a subscription to the master selector control that either selects or deselects all row controls.
374
+ */
375
+ get groupValueSubscription() {
376
+ return this.groupSelector.valueChanges.subscribe({
377
+ next: (value) => {
378
+ const selectMap = new Map(Object.entries(this.rowSelectorsValue));
379
+ selectMap.forEach((_, key) => selectMap.set(key, value));
380
+ const patchValue = objectFromEntries(selectMap);
381
+ this.rowSelectors.patchValue(patchValue);
382
+ },
383
+ });
384
+ }
385
+ /**
386
+ * @internal
387
+ * Returns a subscription to all individual row selectors and update the master selector if all are selected.
388
+ */
389
+ get rowValueSubscription() {
390
+ return this.rowSelectors.valueChanges
391
+ .pipe(debounceTime(0), // to limit the number of events and to wait for all sub controls to update
392
+ map((val) => {
393
+ // get a filtered array of keys for all rows that are selected
394
+ const selected = Object.keys(val).filter((key) => {
395
+ return val[key] === true && this.rowSelectors.get(key)?.enabled;
396
+ });
397
+ // returns an object containing only the filtered keys
398
+ return pick(selected, val);
399
+ }))
400
+ .subscribe({
401
+ next: (value) => {
402
+ // the number of selected keys compared to the total number of keys available
403
+ const numberOfSelected = Object.keys(value).length;
404
+ const allSelected = numberOfSelected > 0
405
+ ? numberOfSelected === Object.keys(this.rowSelectorsValue).length
406
+ : false;
407
+ // update the master selector control
408
+ this.groupSelector.setValue(allSelected, { emitEvent: false });
409
+ // update the array of currently selected id's
410
+ this.selected = Object.keys(value);
411
+ // and emit the updated value
412
+ this.ngvRowSelect.emit(this.selected);
413
+ },
414
+ });
415
+ }
416
+ /**
417
+ * @internal
418
+ * Registers or disables row controls for new or removed rows.
419
+ */
420
+ registerSelectableRows(tableData) {
421
+ if (!tableData)
422
+ return false;
423
+ // Array containing only the id's for each row
424
+ const dataRowIds = tableData.map((data) => data[this.rowId]);
425
+ // Array containing the id's that have registered controls
426
+ const currentIds = Object.keys(this.rowSelectorsValue);
427
+ // Array containing all ids that lacks a corresponding control (i.e. new rows)
428
+ const newIds = dataRowIds.filter((id) => currentIds.indexOf(id) === -1);
429
+ // Array containing all ids that has a control but is no longer in the data set (i.e. removed rows)
430
+ const removedIds = currentIds.filter((id) => dataRowIds.indexOf(id) === -1);
431
+ // Register new controls for added rows
432
+ if (newIds.length) {
433
+ newIds.forEach((id) => {
434
+ const ctrl = this.rowSelectors.registerControl(id, new UntypedFormControl(false));
435
+ if (ctrl.disabled)
436
+ ctrl.enable();
437
+ });
438
+ }
439
+ // Set already registered controls to disabled for removed rows
440
+ if (removedIds.length)
441
+ removedIds.forEach((id) => this.rowSelectors.get(id)?.disable());
442
+ return newIds.length > 0 || removedIds.length > 0;
443
+ }
444
+ /**
445
+ * @internal
446
+ * Returns all enabled values unless all rows are disabled.
447
+ */
448
+ get rowSelectorsValue() {
449
+ return this.rowSelectors.enabled ? this.rowSelectors.value : {};
450
+ }
451
+ toggleSortOrderWithSpace(event, column) {
452
+ if (column.sortable) {
453
+ event.preventDefault();
454
+ this.toggleSortOrder(column);
455
+ }
456
+ }
457
+ /**
458
+ * @internal
459
+ * Switches sorting order between ascending and descending order for a column.
460
+ * @param column the column to sort rows after.
461
+ */
462
+ toggleSortOrder(column) {
463
+ // check if the table is already sorted by another column than the one provided
464
+ const currentlyOrderedBy = this.tableColumns?.find((el) => el !== column && el.order !== undefined);
465
+ if (currentlyOrderedBy)
466
+ delete currentlyOrderedBy.order;
467
+ column.order = column.order === 'desc' ? 'asc' : 'desc';
468
+ this.sortItemsBy(column);
469
+ }
470
+ /** If sortable, reorders the table data using the specified column as ordering attribute. */
471
+ sortItemsBy(column) {
472
+ if (!column.sortable)
473
+ return;
474
+ // emit re-order event
475
+ this.ngvOrderBy.emit({ property: column.property, order: column.order });
476
+ // if local sort is allowed, reorder data
477
+ if (!this.allowLocalSort || !this.tableData)
478
+ return;
479
+ return this.tableData.sort(column.order === 'desc'
480
+ ? orderByDescending(column.property)
481
+ : orderByAscending(column.property));
482
+ }
483
+ /**
484
+ * @internal
485
+ * Emits row data for what row was clicked if defaultEmit is allowed.
486
+ */
487
+ propagateItemClick(item, preventDefaultEmit) {
488
+ if (!preventDefaultEmit)
489
+ this.ngvRowClick.emit(item);
490
+ }
491
+ getAriaLabel(column) {
492
+ const sortOrder = column.order === 'asc'
493
+ ? this.ariaLabelsOrderBy?.desc
494
+ : this.ariaLabelsOrderBy?.asc;
495
+ if (!sortOrder)
496
+ return; // no aria labels defined
497
+ return column.ariaLabelSortable?.replace('{{sortOrder}}', sortOrder);
498
+ }
499
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
500
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: TableComponent, selector: "nggv-table", inputs: { tableColumns: "tableColumns", tableData: "tableData", rowId: "rowId", hasRowSpan: "hasRowSpan", selectable: "selectable", allowLocalSort: "allowLocalSort", thook: "thook", trThookFn: "trThookFn", ariaLabelCheckboxTh: "ariaLabelCheckboxTh", ariaLabelCheckboxTr: "ariaLabelCheckboxTr", ariaLabelsOrderBy: "ariaLabelsOrderBy" }, outputs: { ngvRowClick: "ngvRowClick", ngvRowSelect: "ngvRowSelect", ngvOrderBy: "ngvOrderBy" }, queries: [{ propertyName: "appendedRowsTemplate", first: true, predicate: TableAppendableRowsTemplateDirective, descendants: true }, { propertyName: "customFooterTemplate", first: true, predicate: TableFooterTemplateDirective, descendants: true }, { propertyName: "customTemplates", predicate: TableTemplateDirective, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<ng-template #sortableThTemplate let-column>\n <button class=\"sg-table-sort\" *transloco=\"let t\">\n <ng-template #thButtonTemplate>\n {{ t(column.label ?? '') }}\n </ng-template>\n <ng-container\n *ngIf=\"\n customHeaderTemplates.get(column.property) as thTemplate;\n else thButtonTemplate\n \"\n >\n <ng-template\n *ngTemplateOutlet=\"thTemplate || null; context: { $implicit: column }\"\n >\n </ng-template>\n </ng-container>\n </button>\n</ng-template>\n\n<ng-template #notSortableThTemplate let-column>\n <ng-template #defaultThTemplate>\n <ng-container *transloco=\"let t\">\n {{ t(column.label ?? '') }}\n </ng-container>\n </ng-template>\n <ng-container\n *ngIf=\"\n customHeaderTemplates.get(column.property) as thTemplate;\n else defaultThTemplate\n \"\n >\n <ng-template\n *ngTemplateOutlet=\"thTemplate || null; context: { $implicit: column }\"\n >\n </ng-template>\n </ng-container>\n</ng-template>\n\n<table class=\"gds-table\" *transloco=\"let t\">\n <!-- Table header -->\n <thead>\n <tr>\n <!-- Checkbox column for header -->\n <th *ngIf=\"selectable\" class=\"column__check\">\n <div class=\"gds-field-checkbox-wrap\">\n <input\n type=\"checkbox\"\n [formControl]=\"groupSelector\"\n [attr.aria-label]=\"ariaLabelCheckboxTh\"\n [attr.id]=\"'cb_header__' + initId\"\n [attr.data-thook]=\"thook\"\n />\n <label [attr.for]=\"'cb_header__' + initId\"></label>\n </div>\n </th>\n\n <!-- Other columns -->\n <th\n *ngFor=\"let column of tableColumns\"\n [columnType]=\"column.valueType\"\n [sortable]=\"column.sortable\"\n [sortOrder]=\"column.order\"\n [thook]=\"'column-header-' + !!column.property\"\n (click)=\"toggleSortOrder(column)\"\n (keydown.space)=\"toggleSortOrderWithSpace($event, column)\"\n [attr.aria-label]=\"getAriaLabel(column)\"\n [attr.aria-sort]=\"column.order + 'ending'\"\n >\n <ng-container *ngIf=\"column.sortable\">\n <ng-container\n *ngTemplateOutlet=\"\n sortableThTemplate;\n context: { $implicit: column, column: column }\n \"\n >\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"!column.sortable\">\n <ng-container\n *ngTemplateOutlet=\"\n notSortableThTemplate;\n context: { $implicit: column, column: column }\n \"\n >\n </ng-container>\n </ng-container>\n </th>\n </tr>\n </thead>\n\n <!-- Table body -->\n <tbody [formGroup]=\"rowSelectors\">\n <ng-container *ngFor=\"let item of tableData; let i = index\">\n <tr\n [attr.data-thook]=\"item | trThook: i : trThookFn\"\n [attr.data-hasrowspan]=\"hasRowSpan(item)\"\n >\n <!-- Checkbox column for row -->\n <td *ngIf=\"selectable\" class=\"column__check\">\n <div class=\"gds-field-checkbox-wrap\">\n <input\n *ngIf=\"rowSelectors.get(item[rowId])\"\n type=\"checkbox\"\n [formControlName]=\"item[rowId]\"\n [attr.aria-label]=\"ariaLabelCheckboxTr\"\n [attr.id]=\"'cb_row__' + initId + '_' + i\"\n [attr.data-thook]=\"'row-select-' + i\"\n />\n <label [attr.for]=\"'cb_row__' + initId + '_' + i\"></label>\n </div>\n </td>\n\n <!-- Other columns -->\n <td\n *ngFor=\"let column of tableColumns\"\n (click)=\"propagateItemClick(item, column.preventDefaultClickEvent)\"\n [columnType]=\"column.valueType\"\n [value]=\"item[column.property]\"\n >\n <ng-container\n *ngIf=\"\n customRowTemplates.get(column.property) as tdTemplate;\n else defaultTdTemplate\n \"\n >\n <!-- Cannot infer tdTemplate as TemplateRef therefore null -->\n <ng-template\n *ngTemplateOutlet=\"\n tdTemplate || null;\n context: { $implicit: item }\n \"\n >\n </ng-template>\n </ng-container>\n\n <ng-template #defaultTdTemplate>\n {{ item[column.property] }}\n </ng-template>\n </td>\n </tr>\n\n <!-- custom appended rows -->\n <ng-container *ngIf=\"appendedRowsTemplateRef as trTemplate\">\n <!-- Cannot infer trTemplate as TemplateRef therefore null -->\n <ng-container\n *ngTemplateOutlet=\"trTemplate || null; context: { $implicit: item }\"\n >\n </ng-container>\n </ng-container>\n </ng-container>\n </tbody>\n\n <!-- Table footer -->\n <tfoot *ngIf=\"customFooterTemplateRef as trTemplate\">\n <!-- Cannot infer trTemplate as TemplateRef therefore null -->\n <ng-container *ngTemplateOutlet=\"trTemplate || null\"> </ng-container>\n </tfoot>\n</table>\n", styles: ["::ng-deep .gds-table{--gds-ref-pallet-base600: hsl(0, 0%, 53%);--sg-table-header-background: #1a1a1a;--sg-table-header-color: #fff;--sg-table-cell-padding-x: .5rem;--sg-table-cell-padding-y: .6875rem;--sg-table-border-width: 1px;--sg-table-border-color: var(--gds-ref-pallet-base600);--sg-table-sort-icon-color: var(--gds-ref-pallet-base600);--gds-ref-pallet-base500: hsl(0, 0%, 68%);--sg-table-sort-icon-color-active: #fff;border-collapse:collapse;border-bottom:var(--sg-table-border-width) solid var(--sg-table-border-color);width:100%;border-bottom:none}::ng-deep .gds-table thead tr th{border-top:var(--sg-table-border-width) solid var(--sg-table-border-color);background:#333;color:var(--sg-table-header-color);padding:.3rem var(--sg-table-cell-padding-x);text-align:left;font-weight:500}::ng-deep .gds-table thead tr th.icon-invert.sg-sortable .sg-table-sort:after{margin-left:0;margin-right:.3rem;order:-1}::ng-deep .gds-table thead tr th .sg-table-sort{color:inherit;width:100%;text-align:left;display:flex;align-items:center;border-radius:.125rem;--gds-sys-color-focus-outline: $_header-color}::ng-deep .gds-table thead tr th .sg-table-sort:focus:not(:focus-visible){box-shadow:none;outline:0}::ng-deep .gds-table thead tr th .sg-table-sort:focus,::ng-deep .gds-table thead tr th .sg-table-sort:focus-visible{outline-color:var(--gds-sys-color-focus-outline);outline-style:solid;outline-width:.125rem;outline-offset:.125rem}::ng-deep .gds-table thead tr th[aria-sort] .sg-table-sort:after,::ng-deep .gds-table thead tr th.sg-sortable .sg-table-sort:after{content:\"\";background:var(--gds-ref-pallet-base500);-webkit-mask-image:url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='12'%20height='12'%20viewBox='0%200%2012%2012'%20fill='none'%3E%3Cpath%20d='M11.107%205.86147L10.6429%205.39741C10.5328%205.28726%2010.3546%205.28726%2010.2445%205.39741L6.60933%209.03257V1.03101C6.60933%200.876318%206.48276%200.749756%206.32808%200.749756H5.67183C5.51714%200.749756%205.39058%200.876318%205.39058%201.03101V9.03257L1.75542%205.39741C1.64526%205.28726%201.46714%205.28726%201.35698%205.39741L0.89292%205.86147C0.782764%205.97163%200.782764%206.14976%200.89292%206.25991L5.80073%2011.1677C5.91089%2011.2779%206.08901%2011.2779%206.19917%2011.1677L11.107%206.25991C11.2171%206.14976%2011.2171%205.97163%2011.107%205.86147Z'%20fill='%23ADADAD'/%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='12'%20height='12'%20viewBox='0%200%2012%2012'%20fill='none'%3E%3Cpath%20d='M11.107%205.86147L10.6429%205.39741C10.5328%205.28726%2010.3546%205.28726%2010.2445%205.39741L6.60933%209.03257V1.03101C6.60933%200.876318%206.48276%200.749756%206.32808%200.749756H5.67183C5.51714%200.749756%205.39058%200.876318%205.39058%201.03101V9.03257L1.75542%205.39741C1.64526%205.28726%201.46714%205.28726%201.35698%205.39741L0.89292%205.86147C0.782764%205.97163%200.782764%206.14976%200.89292%206.25991L5.80073%2011.1677C5.91089%2011.2779%206.08901%2011.2779%206.19917%2011.1677L11.107%206.25991C11.2171%206.14976%2011.2171%205.97163%2011.107%205.86147Z'%20fill='%23ADADAD'/%3E%3C/svg%3E\");-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-position:right;mask-position:right;width:12px;height:12px;margin-left:.3rem}::ng-deep .gds-table thead tr th[aria-sort=ascending] .sg-table-sort:after{background:var(--sg-table-sort-icon-color-active);transform:rotate(180deg)}::ng-deep .gds-table thead tr th[aria-sort=descending] .sg-table-sort:after{background:var(--sg-table-sort-icon-color-active)}::ng-deep .gds-table tbody tr td,::ng-deep .gds-table tbody tr th{border-top:var(--sg-table-border-width) solid var(--sg-table-border-color);padding:var(--sg-table-cell-padding-y) var(--sg-table-cell-padding-x);vertical-align:top}::ng-deep .gds-table tbody tr.collapsible~.sub-row{display:none}::ng-deep .gds-table tbody tr.collapsible.expanded~.sub-row.show{display:table-row}::ng-deep .gds-table tbody tr td.collapse-control,::ng-deep .gds-table tbody tr td.select-control{width:15px}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn{min-height:unset;padding:0;background:transparent}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn>.icon-holder{cursor:pointer;width:12px}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn>.icon-holder svg{width:12px;fill:#868686}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn>.icon-holder svg[name=angle-right]{width:9px}@media (max-width: 36em){::ng-deep .gds-table.table-mobile{width:100%;table-layout:fixed;border-bottom:none}::ng-deep .gds-table.table-mobile thead{position:sticky;top:0;display:block;background:#333}}@media (max-width: 36em) and (hover: none) and (pointer: coarse){::ng-deep .gds-table.table-mobile thead{display:table-header-group}}@media (max-width: 36em){::ng-deep .gds-table.table-mobile thead tr{display:flex;overflow:auto}::ng-deep .gds-table.table-mobile thead tr::-webkit-scrollbar{display:none}::ng-deep .gds-table.table-mobile thead tr th{flex:auto;text-align:left!important;white-space:nowrap}::ng-deep .gds-table.table-mobile tbody tr{display:flex;flex-direction:column;border-bottom:var(--sg-table-border-width) solid var(--sg-table-border-color)}::ng-deep .gds-table.table-mobile tbody tr td{display:flex;justify-content:space-between;align-items:center;border-top:none!important}::ng-deep .gds-table.table-mobile tbody tr td:before{content:attr(data-label);font-weight:700}}::ng-deep .gds-table tr:hover td{background-color:#f8f8f8}::ng-deep .gds-table .gds-table__numeric-col{text-align:right}::ng-deep .gds-table thead tr th.gds-table__numeric-col .sg-table-sort{justify-content:end}::ng-deep .gds-table th.gds-table__numeric-col+:not(.gds-table__numeric-col),::ng-deep .gds-table td.gds-table__numeric-col+:not(.gds-table__numeric-col){padding-left:1rem}::ng-deep .gds-table th button{background-color:#0000;border:0;font-family:inherit;font-size:inherit;font-weight:inherit;padding:0;cursor:pointer}::ng-deep .gds-table td{cursor:pointer}::ng-deep .gds-table tfoot{border-top:1px solid;border-bottom:none;font-weight:500}::ng-deep .gds-table tfoot ::ng-deep td{padding:var(--sg-table-cell-padding-y) var(--sg-table-cell-padding-x)}::ng-deep .gds-table th.column__check{height:vanilla-px-to-rem(32px);width:vanilla-px-to-rem(40px)}::ng-deep .gds-table th.column__check div{min-height:100%}::ng-deep .gds-table th.column__check input:checked+label:after{top:.6rem;display:inline}::ng-deep .gds-table th.column__check label{display:inline;padding:0}::ng-deep .gds-table th.column__check label:before{top:.55rem}::ng-deep .gds-table td.column__check{width:vanilla-px-to-rem(40px)}::ng-deep .gds-table td.column__check div{min-height:unset}::ng-deep .gds-table td.column__check label{padding:0}::ng-deep .gds-table td.column__check label:before{margin:0}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i3.TranslocoDirective, selector: "[transloco]", inputs: ["transloco", "translocoParams", "translocoScope", "translocoRead", "translocoPrefix", "translocoLang", "translocoLoadingTpl"] }, { kind: "directive", type: TableDirective, selector: "[columnType]", inputs: ["columnType", "sortable", "sortOrder", "value", "thook"] }, { kind: "pipe", type: TrThookPipe, name: "trThook" }] }); }
501
+ }
502
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: TableComponent, decorators: [{
503
+ type: Component,
504
+ args: [{ selector: 'nggv-table', template: "<ng-template #sortableThTemplate let-column>\n <button class=\"sg-table-sort\" *transloco=\"let t\">\n <ng-template #thButtonTemplate>\n {{ t(column.label ?? '') }}\n </ng-template>\n <ng-container\n *ngIf=\"\n customHeaderTemplates.get(column.property) as thTemplate;\n else thButtonTemplate\n \"\n >\n <ng-template\n *ngTemplateOutlet=\"thTemplate || null; context: { $implicit: column }\"\n >\n </ng-template>\n </ng-container>\n </button>\n</ng-template>\n\n<ng-template #notSortableThTemplate let-column>\n <ng-template #defaultThTemplate>\n <ng-container *transloco=\"let t\">\n {{ t(column.label ?? '') }}\n </ng-container>\n </ng-template>\n <ng-container\n *ngIf=\"\n customHeaderTemplates.get(column.property) as thTemplate;\n else defaultThTemplate\n \"\n >\n <ng-template\n *ngTemplateOutlet=\"thTemplate || null; context: { $implicit: column }\"\n >\n </ng-template>\n </ng-container>\n</ng-template>\n\n<table class=\"gds-table\" *transloco=\"let t\">\n <!-- Table header -->\n <thead>\n <tr>\n <!-- Checkbox column for header -->\n <th *ngIf=\"selectable\" class=\"column__check\">\n <div class=\"gds-field-checkbox-wrap\">\n <input\n type=\"checkbox\"\n [formControl]=\"groupSelector\"\n [attr.aria-label]=\"ariaLabelCheckboxTh\"\n [attr.id]=\"'cb_header__' + initId\"\n [attr.data-thook]=\"thook\"\n />\n <label [attr.for]=\"'cb_header__' + initId\"></label>\n </div>\n </th>\n\n <!-- Other columns -->\n <th\n *ngFor=\"let column of tableColumns\"\n [columnType]=\"column.valueType\"\n [sortable]=\"column.sortable\"\n [sortOrder]=\"column.order\"\n [thook]=\"'column-header-' + !!column.property\"\n (click)=\"toggleSortOrder(column)\"\n (keydown.space)=\"toggleSortOrderWithSpace($event, column)\"\n [attr.aria-label]=\"getAriaLabel(column)\"\n [attr.aria-sort]=\"column.order + 'ending'\"\n >\n <ng-container *ngIf=\"column.sortable\">\n <ng-container\n *ngTemplateOutlet=\"\n sortableThTemplate;\n context: { $implicit: column, column: column }\n \"\n >\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"!column.sortable\">\n <ng-container\n *ngTemplateOutlet=\"\n notSortableThTemplate;\n context: { $implicit: column, column: column }\n \"\n >\n </ng-container>\n </ng-container>\n </th>\n </tr>\n </thead>\n\n <!-- Table body -->\n <tbody [formGroup]=\"rowSelectors\">\n <ng-container *ngFor=\"let item of tableData; let i = index\">\n <tr\n [attr.data-thook]=\"item | trThook: i : trThookFn\"\n [attr.data-hasrowspan]=\"hasRowSpan(item)\"\n >\n <!-- Checkbox column for row -->\n <td *ngIf=\"selectable\" class=\"column__check\">\n <div class=\"gds-field-checkbox-wrap\">\n <input\n *ngIf=\"rowSelectors.get(item[rowId])\"\n type=\"checkbox\"\n [formControlName]=\"item[rowId]\"\n [attr.aria-label]=\"ariaLabelCheckboxTr\"\n [attr.id]=\"'cb_row__' + initId + '_' + i\"\n [attr.data-thook]=\"'row-select-' + i\"\n />\n <label [attr.for]=\"'cb_row__' + initId + '_' + i\"></label>\n </div>\n </td>\n\n <!-- Other columns -->\n <td\n *ngFor=\"let column of tableColumns\"\n (click)=\"propagateItemClick(item, column.preventDefaultClickEvent)\"\n [columnType]=\"column.valueType\"\n [value]=\"item[column.property]\"\n >\n <ng-container\n *ngIf=\"\n customRowTemplates.get(column.property) as tdTemplate;\n else defaultTdTemplate\n \"\n >\n <!-- Cannot infer tdTemplate as TemplateRef therefore null -->\n <ng-template\n *ngTemplateOutlet=\"\n tdTemplate || null;\n context: { $implicit: item }\n \"\n >\n </ng-template>\n </ng-container>\n\n <ng-template #defaultTdTemplate>\n {{ item[column.property] }}\n </ng-template>\n </td>\n </tr>\n\n <!-- custom appended rows -->\n <ng-container *ngIf=\"appendedRowsTemplateRef as trTemplate\">\n <!-- Cannot infer trTemplate as TemplateRef therefore null -->\n <ng-container\n *ngTemplateOutlet=\"trTemplate || null; context: { $implicit: item }\"\n >\n </ng-container>\n </ng-container>\n </ng-container>\n </tbody>\n\n <!-- Table footer -->\n <tfoot *ngIf=\"customFooterTemplateRef as trTemplate\">\n <!-- Cannot infer trTemplate as TemplateRef therefore null -->\n <ng-container *ngTemplateOutlet=\"trTemplate || null\"> </ng-container>\n </tfoot>\n</table>\n", styles: ["::ng-deep .gds-table{--gds-ref-pallet-base600: hsl(0, 0%, 53%);--sg-table-header-background: #1a1a1a;--sg-table-header-color: #fff;--sg-table-cell-padding-x: .5rem;--sg-table-cell-padding-y: .6875rem;--sg-table-border-width: 1px;--sg-table-border-color: var(--gds-ref-pallet-base600);--sg-table-sort-icon-color: var(--gds-ref-pallet-base600);--gds-ref-pallet-base500: hsl(0, 0%, 68%);--sg-table-sort-icon-color-active: #fff;border-collapse:collapse;border-bottom:var(--sg-table-border-width) solid var(--sg-table-border-color);width:100%;border-bottom:none}::ng-deep .gds-table thead tr th{border-top:var(--sg-table-border-width) solid var(--sg-table-border-color);background:#333;color:var(--sg-table-header-color);padding:.3rem var(--sg-table-cell-padding-x);text-align:left;font-weight:500}::ng-deep .gds-table thead tr th.icon-invert.sg-sortable .sg-table-sort:after{margin-left:0;margin-right:.3rem;order:-1}::ng-deep .gds-table thead tr th .sg-table-sort{color:inherit;width:100%;text-align:left;display:flex;align-items:center;border-radius:.125rem;--gds-sys-color-focus-outline: $_header-color}::ng-deep .gds-table thead tr th .sg-table-sort:focus:not(:focus-visible){box-shadow:none;outline:0}::ng-deep .gds-table thead tr th .sg-table-sort:focus,::ng-deep .gds-table thead tr th .sg-table-sort:focus-visible{outline-color:var(--gds-sys-color-focus-outline);outline-style:solid;outline-width:.125rem;outline-offset:.125rem}::ng-deep .gds-table thead tr th[aria-sort] .sg-table-sort:after,::ng-deep .gds-table thead tr th.sg-sortable .sg-table-sort:after{content:\"\";background:var(--gds-ref-pallet-base500);-webkit-mask-image:url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='12'%20height='12'%20viewBox='0%200%2012%2012'%20fill='none'%3E%3Cpath%20d='M11.107%205.86147L10.6429%205.39741C10.5328%205.28726%2010.3546%205.28726%2010.2445%205.39741L6.60933%209.03257V1.03101C6.60933%200.876318%206.48276%200.749756%206.32808%200.749756H5.67183C5.51714%200.749756%205.39058%200.876318%205.39058%201.03101V9.03257L1.75542%205.39741C1.64526%205.28726%201.46714%205.28726%201.35698%205.39741L0.89292%205.86147C0.782764%205.97163%200.782764%206.14976%200.89292%206.25991L5.80073%2011.1677C5.91089%2011.2779%206.08901%2011.2779%206.19917%2011.1677L11.107%206.25991C11.2171%206.14976%2011.2171%205.97163%2011.107%205.86147Z'%20fill='%23ADADAD'/%3E%3C/svg%3E\");mask-image:url(\"data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='12'%20height='12'%20viewBox='0%200%2012%2012'%20fill='none'%3E%3Cpath%20d='M11.107%205.86147L10.6429%205.39741C10.5328%205.28726%2010.3546%205.28726%2010.2445%205.39741L6.60933%209.03257V1.03101C6.60933%200.876318%206.48276%200.749756%206.32808%200.749756H5.67183C5.51714%200.749756%205.39058%200.876318%205.39058%201.03101V9.03257L1.75542%205.39741C1.64526%205.28726%201.46714%205.28726%201.35698%205.39741L0.89292%205.86147C0.782764%205.97163%200.782764%206.14976%200.89292%206.25991L5.80073%2011.1677C5.91089%2011.2779%206.08901%2011.2779%206.19917%2011.1677L11.107%206.25991C11.2171%206.14976%2011.2171%205.97163%2011.107%205.86147Z'%20fill='%23ADADAD'/%3E%3C/svg%3E\");-webkit-mask-repeat:no-repeat;mask-repeat:no-repeat;-webkit-mask-position:right;mask-position:right;width:12px;height:12px;margin-left:.3rem}::ng-deep .gds-table thead tr th[aria-sort=ascending] .sg-table-sort:after{background:var(--sg-table-sort-icon-color-active);transform:rotate(180deg)}::ng-deep .gds-table thead tr th[aria-sort=descending] .sg-table-sort:after{background:var(--sg-table-sort-icon-color-active)}::ng-deep .gds-table tbody tr td,::ng-deep .gds-table tbody tr th{border-top:var(--sg-table-border-width) solid var(--sg-table-border-color);padding:var(--sg-table-cell-padding-y) var(--sg-table-cell-padding-x);vertical-align:top}::ng-deep .gds-table tbody tr.collapsible~.sub-row{display:none}::ng-deep .gds-table tbody tr.collapsible.expanded~.sub-row.show{display:table-row}::ng-deep .gds-table tbody tr td.collapse-control,::ng-deep .gds-table tbody tr td.select-control{width:15px}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn{min-height:unset;padding:0;background:transparent}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn>.icon-holder{cursor:pointer;width:12px}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn>.icon-holder svg{width:12px;fill:#868686}::ng-deep .gds-table tbody tr td.collapse-control>.collapse-btn>.icon-holder svg[name=angle-right]{width:9px}@media (max-width: 36em){::ng-deep .gds-table.table-mobile{width:100%;table-layout:fixed;border-bottom:none}::ng-deep .gds-table.table-mobile thead{position:sticky;top:0;display:block;background:#333}}@media (max-width: 36em) and (hover: none) and (pointer: coarse){::ng-deep .gds-table.table-mobile thead{display:table-header-group}}@media (max-width: 36em){::ng-deep .gds-table.table-mobile thead tr{display:flex;overflow:auto}::ng-deep .gds-table.table-mobile thead tr::-webkit-scrollbar{display:none}::ng-deep .gds-table.table-mobile thead tr th{flex:auto;text-align:left!important;white-space:nowrap}::ng-deep .gds-table.table-mobile tbody tr{display:flex;flex-direction:column;border-bottom:var(--sg-table-border-width) solid var(--sg-table-border-color)}::ng-deep .gds-table.table-mobile tbody tr td{display:flex;justify-content:space-between;align-items:center;border-top:none!important}::ng-deep .gds-table.table-mobile tbody tr td:before{content:attr(data-label);font-weight:700}}::ng-deep .gds-table tr:hover td{background-color:#f8f8f8}::ng-deep .gds-table .gds-table__numeric-col{text-align:right}::ng-deep .gds-table thead tr th.gds-table__numeric-col .sg-table-sort{justify-content:end}::ng-deep .gds-table th.gds-table__numeric-col+:not(.gds-table__numeric-col),::ng-deep .gds-table td.gds-table__numeric-col+:not(.gds-table__numeric-col){padding-left:1rem}::ng-deep .gds-table th button{background-color:#0000;border:0;font-family:inherit;font-size:inherit;font-weight:inherit;padding:0;cursor:pointer}::ng-deep .gds-table td{cursor:pointer}::ng-deep .gds-table tfoot{border-top:1px solid;border-bottom:none;font-weight:500}::ng-deep .gds-table tfoot ::ng-deep td{padding:var(--sg-table-cell-padding-y) var(--sg-table-cell-padding-x)}::ng-deep .gds-table th.column__check{height:vanilla-px-to-rem(32px);width:vanilla-px-to-rem(40px)}::ng-deep .gds-table th.column__check div{min-height:100%}::ng-deep .gds-table th.column__check input:checked+label:after{top:.6rem;display:inline}::ng-deep .gds-table th.column__check label{display:inline;padding:0}::ng-deep .gds-table th.column__check label:before{top:.55rem}::ng-deep .gds-table td.column__check{width:vanilla-px-to-rem(40px)}::ng-deep .gds-table td.column__check div{min-height:unset}::ng-deep .gds-table td.column__check label{padding:0}::ng-deep .gds-table td.column__check label:before{margin:0}\n"] }]
505
+ }], propDecorators: { customTemplates: [{
506
+ type: ContentChildren,
507
+ args: [TableTemplateDirective, { descendants: true }]
508
+ }], appendedRowsTemplate: [{
509
+ type: ContentChild,
510
+ args: [TableAppendableRowsTemplateDirective]
511
+ }], customFooterTemplate: [{
512
+ type: ContentChild,
513
+ args: [TableFooterTemplateDirective]
514
+ }], ngvRowClick: [{
515
+ type: Output
516
+ }], ngvRowSelect: [{
517
+ type: Output
518
+ }], ngvOrderBy: [{
519
+ type: Output
520
+ }], tableColumns: [{
521
+ type: Input
522
+ }], tableData: [{
523
+ type: Input
524
+ }], rowId: [{
525
+ type: Input
526
+ }], hasRowSpan: [{
527
+ type: Input
528
+ }], selectable: [{
529
+ type: Input
530
+ }], allowLocalSort: [{
531
+ type: Input
532
+ }], thook: [{
533
+ type: Input
534
+ }], trThookFn: [{
535
+ type: Input
536
+ }], ariaLabelCheckboxTh: [{
537
+ type: Input
538
+ }], ariaLabelCheckboxTr: [{
539
+ type: Input
540
+ }], ariaLabelsOrderBy: [{
541
+ type: Input
542
+ }] } });
543
+
544
+ class NggvTableModule {
545
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: NggvTableModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
546
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "17.3.12", ngImport: i0, type: NggvTableModule, declarations: [TableComponent,
547
+ TableDirective,
548
+ TableTemplateDirective,
549
+ TableFooterTemplateDirective,
550
+ TableAppendableRowsTemplateDirective], imports: [CommonModule, ReactiveFormsModule, TranslocoModule, TrThookPipe], exports: [TableComponent,
551
+ TableTemplateDirective,
552
+ TableFooterTemplateDirective,
553
+ TableAppendableRowsTemplateDirective] }); }
554
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: NggvTableModule, imports: [CommonModule, ReactiveFormsModule, TranslocoModule] }); }
555
+ }
556
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: NggvTableModule, decorators: [{
557
+ type: NgModule,
558
+ args: [{
559
+ declarations: [
560
+ TableComponent,
561
+ TableDirective,
562
+ TableTemplateDirective,
563
+ TableFooterTemplateDirective,
564
+ TableAppendableRowsTemplateDirective,
565
+ ],
566
+ imports: [CommonModule, ReactiveFormsModule, TranslocoModule, TrThookPipe],
567
+ exports: [
568
+ TableComponent,
569
+ TableTemplateDirective,
570
+ TableFooterTemplateDirective,
571
+ TableAppendableRowsTemplateDirective,
572
+ ],
573
+ }]
574
+ }] });
575
+
576
+ /*
577
+ * Public API Surface of table
578
+ */
579
+
580
+ /**
581
+ * Generated bundle index. Do not edit.
582
+ */
583
+
584
+ export { NggvTableModule, TableAppendableRowsTemplateDirective, TableComponent, TableDirective, TableFooterTemplateDirective, TableTemplateDirective, TrThookPipe };
585
+ //# sourceMappingURL=sebgroup-green-angular-src-v-angular-table.mjs.map