@skyux/list-builder 5.0.0-beta.0 → 5.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (232) hide show
  1. package/LICENSE +21 -0
  2. package/bundles/skyux-list-builder.umd.js +1308 -1130
  3. package/bundles/skyux-list-builder.umd.js.map +1 -1
  4. package/documentation.json +6679 -0
  5. package/esm2015/modules/list/list-data-request.model.js +1 -1
  6. package/esm2015/modules/list/list-data-response.model.js +1 -1
  7. package/esm2015/modules/list/list-data.provider.js +1 -1
  8. package/esm2015/modules/list/list-paging.component.js +1 -1
  9. package/esm2015/modules/list/list-view.component.js +9 -8
  10. package/esm2015/modules/list/list.component.js +81 -87
  11. package/esm2015/modules/list/list.module.js +15 -18
  12. package/esm2015/modules/list/state/filters/filters.orchestrator.js +2 -3
  13. package/esm2015/modules/list/state/filters/update.action.js +1 -1
  14. package/esm2015/modules/list/state/items/items.orchestrator.js +12 -9
  15. package/esm2015/modules/list/state/items/load.action.js +1 -1
  16. package/esm2015/modules/list/state/items/set-items-selected.action.js +4 -2
  17. package/esm2015/modules/list/state/items/set-loading.action.js +1 -1
  18. package/esm2015/modules/list/state/list-state-action.type.js +2 -1
  19. package/esm2015/modules/list/state/list-state.model.js +1 -1
  20. package/esm2015/modules/list/state/list-state.rxstate.js +10 -8
  21. package/esm2015/modules/list/state/list-state.state-node.js +11 -14
  22. package/esm2015/modules/list/state/paging/paging.model.js +1 -1
  23. package/esm2015/modules/list/state/paging/paging.orchestrator.js +2 -3
  24. package/esm2015/modules/list/state/paging/set-items-per-page.action.js +1 -1
  25. package/esm2015/modules/list/state/paging/set-max-pages.action.js +1 -1
  26. package/esm2015/modules/list/state/paging/set-page-number.action.js +1 -1
  27. package/esm2015/modules/list/state/search/search.model.js +1 -1
  28. package/esm2015/modules/list/state/search/search.orchestrator.js +5 -4
  29. package/esm2015/modules/list/state/search/set-field-selectors.action.js +1 -1
  30. package/esm2015/modules/list/state/search/set-functions.action.js +1 -1
  31. package/esm2015/modules/list/state/search/set-options.action.js +1 -1
  32. package/esm2015/modules/list/state/search/set-search-text.action.js +1 -1
  33. package/esm2015/modules/list/state/selected/load.action.js +1 -1
  34. package/esm2015/modules/list/state/selected/selected.model.js +1 -1
  35. package/esm2015/modules/list/state/selected/selected.orchestrator.js +9 -10
  36. package/esm2015/modules/list/state/selected/set-item-selected.action.js +1 -1
  37. package/esm2015/modules/list/state/selected/set-items-selected.action.js +1 -1
  38. package/esm2015/modules/list/state/selected/set-loading.action.js +1 -1
  39. package/esm2015/modules/list/state/sort/label.model.js +1 -1
  40. package/esm2015/modules/list/state/sort/set-available.action.js +1 -1
  41. package/esm2015/modules/list/state/sort/set-field-selectors.action.js +1 -1
  42. package/esm2015/modules/list/state/sort/set-global.action.js +1 -1
  43. package/esm2015/modules/list/state/sort/sort.model.js +1 -1
  44. package/esm2015/modules/list/state/sort/sort.orchestrator.js +4 -5
  45. package/esm2015/modules/list/state/toolbar/disable.action.js +1 -1
  46. package/esm2015/modules/list/state/toolbar/load.action.js +1 -1
  47. package/esm2015/modules/list/state/toolbar/remove.action.js +1 -1
  48. package/esm2015/modules/list/state/toolbar/set-exists.action.js +1 -1
  49. package/esm2015/modules/list/state/toolbar/set-type.action.js +1 -1
  50. package/esm2015/modules/list/state/toolbar/show-multiselect-toolbar.action.js +1 -1
  51. package/esm2015/modules/list/state/toolbar/toolbar-item.model.js +1 -1
  52. package/esm2015/modules/list/state/toolbar/toolbar.model.js +1 -1
  53. package/esm2015/modules/list/state/toolbar/toolbar.orchestrator.js +3 -4
  54. package/esm2015/modules/list/state/views/load.action.js +1 -1
  55. package/esm2015/modules/list/state/views/set-active.action.js +1 -1
  56. package/esm2015/modules/list/state/views/view.model.js +1 -1
  57. package/esm2015/modules/list/state/views/views.model.js +1 -1
  58. package/esm2015/modules/list/state/views/views.orchestrator.js +2 -4
  59. package/esm2015/modules/list-data-provider-in-memory/list-data-in-memory.provider.js +25 -14
  60. package/esm2015/modules/list-filters/filter.model.js +1 -1
  61. package/esm2015/modules/list-filters/list-filter-button.component.js +23 -24
  62. package/esm2015/modules/list-filters/list-filter-inline-item-renderer.component.js +24 -24
  63. package/esm2015/modules/list-filters/list-filter-inline-item.component.js +32 -32
  64. package/esm2015/modules/list-filters/list-filter-inline.component.js +28 -26
  65. package/esm2015/modules/list-filters/list-filter-inline.model.js +1 -1
  66. package/esm2015/modules/list-filters/list-filter-summary.component.js +22 -23
  67. package/esm2015/modules/list-filters/list-filters.module.js +33 -27
  68. package/esm2015/modules/list-paging/list-paging.component.js +37 -40
  69. package/esm2015/modules/list-paging/list-paging.module.js +15 -19
  70. package/esm2015/modules/list-toolbar/list-multiselect-toolbar.component.js +45 -41
  71. package/esm2015/modules/list-toolbar/list-secondary-actions/list-secondary-action.component.js +22 -23
  72. package/esm2015/modules/list-toolbar/list-secondary-actions/list-secondary-action.js +2 -1
  73. package/esm2015/modules/list-toolbar/list-secondary-actions/list-secondary-actions-host.component.js +22 -20
  74. package/esm2015/modules/list-toolbar/list-secondary-actions/list-secondary-actions.component.js +26 -30
  75. package/esm2015/modules/list-toolbar/list-secondary-actions/list-secondary-actions.module.js +34 -23
  76. package/esm2015/modules/list-toolbar/list-secondary-actions/list-secondary-actions.service.js +10 -9
  77. package/esm2015/modules/list-toolbar/list-toolbar-item-renderer.component.js +22 -21
  78. package/esm2015/modules/list-toolbar/list-toolbar-item.component.js +23 -24
  79. package/esm2015/modules/list-toolbar/list-toolbar-search-actions.component.js +15 -13
  80. package/esm2015/modules/list-toolbar/list-toolbar-sort.component.js +21 -23
  81. package/esm2015/modules/list-toolbar/list-toolbar-view-actions.component.js +14 -12
  82. package/esm2015/modules/list-toolbar/list-toolbar.component.js +142 -139
  83. package/esm2015/modules/list-toolbar/list-toolbar.module.js +62 -31
  84. package/esm2015/modules/list-toolbar/state/config/config.model.js +1 -1
  85. package/esm2015/modules/list-toolbar/state/config/config.orchestrator.js +2 -4
  86. package/esm2015/modules/list-toolbar/state/config/set-search-enabled.action.js +1 -1
  87. package/esm2015/modules/list-toolbar/state/config/set-sort-selector-enabled.action.js +1 -1
  88. package/esm2015/modules/list-toolbar/state/toolbar-state-action.type.js +2 -1
  89. package/esm2015/modules/list-toolbar/state/toolbar-state.model.js +1 -1
  90. package/esm2015/modules/list-toolbar/state/toolbar-state.rxstate.js +9 -8
  91. package/esm2015/modules/list-toolbar/state/toolbar-state.state-node.js +12 -17
  92. package/esm2015/modules/shared/sky-list-builder-resources.module.js +53 -0
  93. package/esm2015/public-api.js +78 -0
  94. package/esm2015/skyux-list-builder.js +2 -23
  95. package/fesm2015/skyux-list-builder.js +992 -915
  96. package/fesm2015/skyux-list-builder.js.map +1 -1
  97. package/modules/list/list.component.d.ts +3 -0
  98. package/modules/list/list.module.d.ts +6 -0
  99. package/modules/list/state/list-state.rxstate.d.ts +3 -0
  100. package/modules/list/state/list-state.state-node.d.ts +3 -0
  101. package/modules/list-filters/list-filter-button.component.d.ts +3 -0
  102. package/modules/list-filters/list-filter-inline-item-renderer.component.d.ts +3 -0
  103. package/modules/list-filters/list-filter-inline-item.component.d.ts +3 -0
  104. package/modules/list-filters/list-filter-inline.component.d.ts +3 -0
  105. package/modules/list-filters/list-filter-summary.component.d.ts +3 -0
  106. package/modules/list-filters/list-filters.module.d.ts +11 -0
  107. package/modules/list-paging/list-paging.component.d.ts +3 -0
  108. package/modules/list-paging/list-paging.module.d.ts +7 -0
  109. package/modules/list-toolbar/list-multiselect-toolbar.component.d.ts +3 -0
  110. package/modules/list-toolbar/list-secondary-actions/list-secondary-action.component.d.ts +3 -0
  111. package/modules/list-toolbar/list-secondary-actions/list-secondary-actions-host.component.d.ts +3 -0
  112. package/modules/list-toolbar/list-secondary-actions/list-secondary-actions.component.d.ts +3 -0
  113. package/modules/list-toolbar/list-secondary-actions/list-secondary-actions.module.d.ts +12 -0
  114. package/modules/list-toolbar/list-secondary-actions/list-secondary-actions.service.d.ts +3 -0
  115. package/modules/list-toolbar/list-toolbar-item-renderer.component.d.ts +3 -0
  116. package/modules/list-toolbar/list-toolbar-item.component.d.ts +3 -0
  117. package/modules/list-toolbar/list-toolbar-search-actions.component.d.ts +3 -0
  118. package/modules/list-toolbar/list-toolbar-sort.component.d.ts +3 -0
  119. package/modules/list-toolbar/list-toolbar-view-actions.component.d.ts +3 -0
  120. package/modules/list-toolbar/list-toolbar.component.d.ts +3 -0
  121. package/modules/list-toolbar/list-toolbar.module.d.ts +20 -0
  122. package/modules/list-toolbar/state/toolbar-state.rxstate.d.ts +3 -0
  123. package/modules/list-toolbar/state/toolbar-state.state-node.d.ts +3 -0
  124. package/modules/shared/sky-list-builder-resources.module.d.ts +14 -0
  125. package/package.json +16 -31
  126. package/{public_api.d.ts → public-api.d.ts} +11 -0
  127. package/skyux-list-builder.d.ts +2 -22
  128. package/CHANGELOG.md +0 -161
  129. package/bundles/skyux-list-builder.umd.min.js +0 -16
  130. package/bundles/skyux-list-builder.umd.min.js.map +0 -1
  131. package/esm2015/modules/shared/list-builder-resources.module.js +0 -17
  132. package/esm2015/plugin-resources/list-builder-resources-provider.js +0 -16
  133. package/esm2015/public_api.js +0 -63
  134. package/esm5/modules/list/list-data-request.model.js +0 -20
  135. package/esm5/modules/list/list-data-response.model.js +0 -11
  136. package/esm5/modules/list/list-data.provider.js +0 -10
  137. package/esm5/modules/list/list-paging.component.js +0 -15
  138. package/esm5/modules/list/list-view.component.js +0 -38
  139. package/esm5/modules/list/list.component.js +0 -337
  140. package/esm5/modules/list/list.module.js +0 -24
  141. package/esm5/modules/list/state/filters/filters.orchestrator.js +0 -22
  142. package/esm5/modules/list/state/filters/update.action.js +0 -11
  143. package/esm5/modules/list/state/items/items.orchestrator.js +0 -55
  144. package/esm5/modules/list/state/items/load.action.js +0 -16
  145. package/esm5/modules/list/state/items/set-items-selected.action.js +0 -15
  146. package/esm5/modules/list/state/items/set-loading.action.js +0 -12
  147. package/esm5/modules/list/state/list-state-action.type.js +0 -1
  148. package/esm5/modules/list/state/list-state.model.js +0 -26
  149. package/esm5/modules/list/state/list-state.rxstate.js +0 -91
  150. package/esm5/modules/list/state/list-state.state-node.js +0 -42
  151. package/esm5/modules/list/state/paging/paging.model.js +0 -16
  152. package/esm5/modules/list/state/paging/paging.orchestrator.js +0 -33
  153. package/esm5/modules/list/state/paging/set-items-per-page.action.js +0 -11
  154. package/esm5/modules/list/state/paging/set-max-pages.action.js +0 -11
  155. package/esm5/modules/list/state/paging/set-page-number.action.js +0 -11
  156. package/esm5/modules/list/state/search/search.model.js +0 -34
  157. package/esm5/modules/list/state/search/search.orchestrator.js +0 -51
  158. package/esm5/modules/list/state/search/set-field-selectors.action.js +0 -12
  159. package/esm5/modules/list/state/search/set-functions.action.js +0 -12
  160. package/esm5/modules/list/state/search/set-options.action.js +0 -13
  161. package/esm5/modules/list/state/search/set-search-text.action.js +0 -11
  162. package/esm5/modules/list/state/selected/load.action.js +0 -11
  163. package/esm5/modules/list/state/selected/selected.model.js +0 -11
  164. package/esm5/modules/list/state/selected/selected.orchestrator.js +0 -62
  165. package/esm5/modules/list/state/selected/set-item-selected.action.js +0 -12
  166. package/esm5/modules/list/state/selected/set-items-selected.action.js +0 -15
  167. package/esm5/modules/list/state/selected/set-loading.action.js +0 -12
  168. package/esm5/modules/list/state/sort/label.model.js +0 -27
  169. package/esm5/modules/list/state/sort/set-available.action.js +0 -11
  170. package/esm5/modules/list/state/sort/set-field-selectors.action.js +0 -11
  171. package/esm5/modules/list/state/sort/set-global.action.js +0 -11
  172. package/esm5/modules/list/state/sort/sort.model.js +0 -29
  173. package/esm5/modules/list/state/sort/sort.orchestrator.js +0 -36
  174. package/esm5/modules/list/state/toolbar/disable.action.js +0 -11
  175. package/esm5/modules/list/state/toolbar/load.action.js +0 -13
  176. package/esm5/modules/list/state/toolbar/remove.action.js +0 -11
  177. package/esm5/modules/list/state/toolbar/set-exists.action.js +0 -11
  178. package/esm5/modules/list/state/toolbar/set-type.action.js +0 -11
  179. package/esm5/modules/list/state/toolbar/show-multiselect-toolbar.action.js +0 -11
  180. package/esm5/modules/list/state/toolbar/toolbar-item.model.js +0 -18
  181. package/esm5/modules/list/state/toolbar/toolbar.model.js +0 -19
  182. package/esm5/modules/list/state/toolbar/toolbar.orchestrator.js +0 -86
  183. package/esm5/modules/list/state/views/load.action.js +0 -11
  184. package/esm5/modules/list/state/views/set-active.action.js +0 -11
  185. package/esm5/modules/list/state/views/view.model.js +0 -12
  186. package/esm5/modules/list/state/views/views.model.js +0 -15
  187. package/esm5/modules/list/state/views/views.orchestrator.js +0 -28
  188. package/esm5/modules/list-data-provider-in-memory/list-data-in-memory.provider.js +0 -157
  189. package/esm5/modules/list-filters/filter.model.js +0 -20
  190. package/esm5/modules/list-filters/list-filter-button.component.js +0 -45
  191. package/esm5/modules/list-filters/list-filter-inline-item-renderer.component.js +0 -37
  192. package/esm5/modules/list-filters/list-filter-inline-item.component.js +0 -50
  193. package/esm5/modules/list-filters/list-filter-inline.component.js +0 -73
  194. package/esm5/modules/list-filters/list-filter-inline.model.js +0 -23
  195. package/esm5/modules/list-filters/list-filter-summary.component.js +0 -62
  196. package/esm5/modules/list-filters/list-filters.module.js +0 -38
  197. package/esm5/modules/list-paging/list-paging.component.js +0 -102
  198. package/esm5/modules/list-paging/list-paging.module.js +0 -26
  199. package/esm5/modules/list-toolbar/list-multiselect-toolbar.component.js +0 -153
  200. package/esm5/modules/list-toolbar/list-secondary-actions/list-secondary-action.component.js +0 -34
  201. package/esm5/modules/list-toolbar/list-secondary-actions/list-secondary-action.js +0 -1
  202. package/esm5/modules/list-toolbar/list-secondary-actions/list-secondary-actions-host.component.js +0 -49
  203. package/esm5/modules/list-toolbar/list-secondary-actions/list-secondary-actions.component.js +0 -49
  204. package/esm5/modules/list-toolbar/list-secondary-actions/list-secondary-actions.module.js +0 -38
  205. package/esm5/modules/list-toolbar/list-secondary-actions/list-secondary-actions.service.js +0 -36
  206. package/esm5/modules/list-toolbar/list-toolbar-item-renderer.component.js +0 -32
  207. package/esm5/modules/list-toolbar/list-toolbar-item.component.js +0 -53
  208. package/esm5/modules/list-toolbar/list-toolbar-search-actions.component.js +0 -20
  209. package/esm5/modules/list-toolbar/list-toolbar-sort.component.js +0 -30
  210. package/esm5/modules/list-toolbar/list-toolbar-view-actions.component.js +0 -22
  211. package/esm5/modules/list-toolbar/list-toolbar.component.js +0 -375
  212. package/esm5/modules/list-toolbar/list-toolbar.module.js +0 -59
  213. package/esm5/modules/list-toolbar/state/config/config.model.js +0 -16
  214. package/esm5/modules/list-toolbar/state/config/config.orchestrator.js +0 -28
  215. package/esm5/modules/list-toolbar/state/config/set-search-enabled.action.js +0 -11
  216. package/esm5/modules/list-toolbar/state/config/set-sort-selector-enabled.action.js +0 -13
  217. package/esm5/modules/list-toolbar/state/toolbar-state-action.type.js +0 -1
  218. package/esm5/modules/list-toolbar/state/toolbar-state.model.js +0 -12
  219. package/esm5/modules/list-toolbar/state/toolbar-state.rxstate.js +0 -29
  220. package/esm5/modules/list-toolbar/state/toolbar-state.state-node.js +0 -29
  221. package/esm5/modules/shared/list-builder-resources.module.js +0 -20
  222. package/esm5/plugin-resources/list-builder-resources-provider.js +0 -17
  223. package/esm5/public_api.js +0 -63
  224. package/esm5/skyux-list-builder.js +0 -26
  225. package/fesm5/skyux-list-builder.js +0 -2884
  226. package/fesm5/skyux-list-builder.js.map +0 -1
  227. package/modules/shared/list-builder-resources.module.d.ts +0 -2
  228. package/plugin-resources/list-builder-resources-provider.d.ts +0 -5
  229. package/skyux-list-builder.metadata.json +0 -1
  230. package/src/assets/img/list-toolbar-context.png +0 -0
  231. package/src/assets/img/toolbar-anatomy.png +0 -0
  232. package/src/assets/locales/resources_en_US.json +0 -22
package/CHANGELOG.md DELETED
@@ -1,161 +0,0 @@
1
- # 5.0.0-beta.0 (2021-07-12)
2
-
3
- - Initial beta release.
4
- - Added support for `5.0.0-beta.*` versions of SKY UX component libraries. [#129](https://github.com/blackbaud/skyux-list-builder/pull/129)
5
- - Added support for `@angular/core@^12`. [#129](https://github.com/blackbaud/skyux-list-builder/pull/129)
6
-
7
- # 4.0.4 (2021-01-26)
8
-
9
- - Fixed the filter summary component to not error when an unapplied filter exists upon creation. [#126](https://github.com/blackbaud/skyux-list-builder/pull/126)
10
-
11
- # 4.0.3 (2020-12-18)
12
-
13
- - Fixed the filter summary component to only show filters which are being applied. [#123](https://github.com/blackbaud/skyux-list-builder/pull/123)
14
-
15
- # 4.0.2 (2020-08-21)
16
-
17
- - Fixed the `selectedIds` property on the list component to handle observable values. [#109](https://github.com/blackbaud/skyux-list-builder/pull/109)
18
-
19
- # 4.0.1 (2020-08-06)
20
-
21
- - Added support for `@skyux/theme@4.8.0` and `@skyux-sdk/builder@4.3.0`. [#103](https://github.com/blackbaud/skyux-list-builder/pull/103)
22
-
23
- # 4.0.0 (2020-05-14)
24
-
25
- ### New features
26
-
27
- - Updated the pipeline to transpile to the [Angular Package Format](https://docs.google.com/document/d/1CZC2rcpxffTDfRDs6p1cfbmKNLA6x5O-NtkJglDaBVs/preview). [#87](https://github.com/blackbaud/skyux-list-builder/pull/87)
28
-
29
- # 3.8.1 (2020-05-06)
30
-
31
- - Fixed the list component to return to the first page after applying a filter or sorting a list. [#89](https://github.com/blackbaud/skyux-list-builder/pull/89)
32
- - Fixed the list toolbar item component to honor item indexing. [#88](https://github.com/blackbaud/skyux-list-builder/pull/88)
33
-
34
- # 4.0.0-rc.2 (2020-04-17)
35
-
36
- ### Bug fixes
37
-
38
- - Added `SkyListSecondaryActionsComponent` and `SkyListToolbarComponent` to the exports API.
39
-
40
- # 4.0.0-rc.1 (2020-04-17)
41
-
42
- ### Bug fixes
43
-
44
- - Added `SkyListViewComponent` and `SkyListComponent` to the exports API.
45
-
46
- # 4.0.0-rc.0 (2020-04-17)
47
-
48
- ### New features
49
-
50
- - Updated the pipeline to transpile to the [Angular Package Format](https://docs.google.com/document/d/1CZC2rcpxffTDfRDs6p1cfbmKNLA6x5O-NtkJglDaBVs/preview). [#87](https://github.com/blackbaud/skyux-list-builder/pull/87)
51
-
52
- # 3.8.0 (2020-04-15)
53
-
54
- - Upgraded the package development dependencies. [#85](https://github.com/blackbaud/skyux-list-builder/pull/85)
55
-
56
- # 3.7.1 (2020-03-11)
57
-
58
- - Fixed the list toolbar component to not display an empty toolbar when search is disabled. [#76](https://github.com/blackbaud/skyux-list-builder/pull/76)
59
-
60
- # 3.7.0 (2020-03-05)
61
-
62
- - Added the `inMemorySearchEnabled` and `searchApplied` properties to the list toolbar component to enable consuming SKY UX components to run searches remotely. [#82](https://github.com/blackbaud/skyux-list-builder/pull/82)
63
-
64
- # 3.6.4 (2020-02-07)
65
-
66
- - Fixed the package's primary entrypoint to include the list state types and removed an invalid import in the multiselect toolbar component. [#79](https://github.com/blackbaud/skyux-list-builder/pull/79)
67
-
68
- # 3.6.3 (2020-02-06)
69
-
70
- - Fixed `ListStateDispatcher` to prevent redundant updates to `ListItemModel` and improve performance for the list view grid component. [#77](https://github.com/blackbaud/skyux-list-builder/pull/77)
71
-
72
- # 3.6.2 (2019-12-06)
73
-
74
- - Fixed the list component to properly retain selections after removing filters. [#72](https://github.com/blackbaud/skyux-list-builder/pull/72)
75
-
76
- # 3.6.1 (2019-11-07)
77
-
78
- - Fixed the list component to properly return data when calling `refreshDisplayedItems()`. [#69](https://github.com/blackbaud/skyux-list-builder/pull/69)
79
-
80
- # 3.6.0 (2019-10-30)
81
-
82
- - Added the list view switcher component to provide toolbar buttons to switch between list views. [#32](https://github.com/blackbaud/skyux-list-builder/pull/32)
83
-
84
- # 3.5.2 (2019-09-11)
85
-
86
- - Fixed the list component to properly display results when searching pages other than the first page. [#61](https://github.com/blackbaud/skyux-list-builder/pull/61)
87
- - Fixed the list builder component to load properly when `selectedIds` are undefined. [#63](https://github.com/blackbaud/skyux-list-builder/pull/63)
88
-
89
- # 3.5.1 (2019-08-02)
90
-
91
- - Fixed the list component to properly notify consumers when filters are removed. [#60](https://github.com/blackbaud/skyux-list-builder/pull/60)
92
-
93
- # 3.5.0 (2019-07-19)
94
-
95
- - Updated the list component to programmatically select rows when the `selectedIds` input property is used in conjunction with the list view grids component. [#57](https://github.com/blackbaud/skyux-list-builder/pull/57)
96
-
97
- # 3.4.0 (2019-07-01)
98
-
99
- - Added `sky-list-toolbar-search-actions` to the list toolbar's child components. [#52](https://github.com/blackbaud/skyux-list-builder/pull/52) (Thanks [@blackbaud-vimal-kumar](https://github.com/blackbaud-vimal-kumar)!)
100
-
101
- # 3.3.0 (2019-06-07)
102
-
103
- - Added the ability to trigger responsive styles based on a parent component. [#43](https://github.com/blackbaud/skyux-list-builder/pull/43)
104
-
105
- # 3.2.4 (2019-05-28)
106
-
107
- - Fixed the list toolbar component to properly display items when they are dynamically shown or hidden. [#45](https://github.com/blackbaud/skyux-list-builder/pull/45)
108
-
109
- # 3.2.3 (2019-04-16)
110
-
111
- - Fixed visual styles for the list toolbar view actions component. [#41](https://github.com/blackbaud/skyux-list-builder/pull/41)
112
-
113
- # 3.2.2 (2019-04-12)
114
-
115
- - Fixed missing model exports. [#39](https://github.com/blackbaud/skyux-list-builder/pull/39)
116
-
117
- # 3.2.1 (2019-03-20)
118
-
119
- - Fixed `SkyListToolbarModule` to properly import `SkyListBuilderResourcesModule`. [#37](https://github.com/blackbaud/skyux-list-builder/pull/37/)
120
-
121
- # 3.2.0 (2019-03-19)
122
-
123
- - Added support for the multiselect toolbar. [#18](https://github.com/blackbaud/skyux-list-builder/pull/18/)
124
-
125
- # 3.1.0 (2019-03-19)
126
-
127
- - Added support for `microedge-rxstate@>=2.0.2`. [#33](https://github.com/blackbaud/skyux-list-builder/pull/33)
128
- - Fixed `ListPagingComponent` to properly import the `scan` RxJS operator. [#33](https://github.com/blackbaud/skyux-list-builder/pull/33)
129
-
130
- # 3.0.1 (2019-03-07)
131
-
132
- - Fixed the list paging component to update after the list items change. [#25](https://github.com/blackbaud/skyux-list-builder/pull/25)
133
-
134
- # 3.0.0 (2019-01-14)
135
-
136
- - Major version release.
137
-
138
- # 3.0.0-rc.4 (2018-11-20)
139
-
140
- - Added support for `@skyux/list-builder-common@3.0.0-rc.1`. [#9](https://github.com/blackbaud/skyux-list-builder/pull/9)
141
- - Updated peer dependencies to support Angular versions greater than `4.3.6`. [#10](https://github.com/blackbaud/skyux-list-builder/pull/10)
142
-
143
- # 3.0.0-rc.3 (2018-11-12)
144
-
145
- - Fixed the `isObservable` utility function to work with RxJS 6. [#8](https://github.com/blackbaud/skyux-list-builder/pull/8)
146
-
147
- # 3.0.0-rc.2 (2018-11-08)
148
-
149
- - Added support for `@skyux/i18n@3.3.0`, which addresses some internationalization issues. [#7](https://github.com/blackbaud/skyux-list-builder/pull/7)
150
-
151
- # 3.0.0-rc.1 (2018-10-30)
152
-
153
- - Added support for `@skyux/i18n@3.2.0`. [#5](https://github.com/blackbaud/skyux-list-builder/pull/5)
154
-
155
- # 3.0.0-rc.0 (2018-10-24)
156
-
157
- - Initial release candidate.
158
-
159
- # 3.0.0-alpha.0 (2018-10-10)
160
-
161
- - Initial alpha release.
@@ -1,16 +0,0 @@
1
- !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@angular/core"),require("@angular/common"),require("rxjs"),require("rxjs/operators"),require("@skyux/list-builder-common"),require("@skyux/lists"),require("@skyux/i18n"),require("@skyux/indicators"),require("@skyux/popovers"),require("@skyux/layout"),require("@skyux/lookup"),require("@skyux/forms")):"function"==typeof define&&define.amd?define("@skyux/list-builder",["exports","@angular/core","@angular/common","rxjs","rxjs/operators","@skyux/list-builder-common","@skyux/lists","@skyux/i18n","@skyux/indicators","@skyux/popovers","@skyux/layout","@skyux/lookup","@skyux/forms"],e):e(((t=t||self).skyux=t.skyux||{},t.skyux["list-builder"]={}),t.ng.core,t.ng.common,t.rxjs,t.rxjs.operators,t.listBuilderCommon,t.lists,t.i18n,t.indicators,t.popovers,t.layout,t.lookup,t.forms)}(this,(function(t,e,n,i,s,o,r,a,l,c,p,u,d){"use strict";
2
- /*! *****************************************************************************
3
- Copyright (c) Microsoft Corporation.
4
-
5
- Permission to use, copy, modify, and/or distribute this software for any
6
- purpose with or without fee is hereby granted.
7
-
8
- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
9
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
10
- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
11
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
12
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
13
- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14
- PERFORMANCE OF THIS SOFTWARE.
15
- ***************************************************************************** */var h=function(t,e){return(h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n])})(t,e)};function m(t,e){function n(){this.constructor=t}h(t,e),t.prototype=null===e?Object.create(e):(n.prototype=e.prototype,new n)}function f(t,e,n,i){var s,o=arguments.length,r=o<3?e:null===i?i=Object.getOwnPropertyDescriptor(e,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,n,i);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(o<3?s(r):o>3?s(e,n,r):s(e,n))||r);return o>3&&r&&Object.defineProperty(e,n,r),r}function y(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var i,s,o=n.call(t),r=[];try{for(;(void 0===e||e-- >0)&&!(i=o.next()).done;)r.push(i.value)}catch(t){s={error:t}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(s)throw s.error}}return r}function b(){for(var t=[],e=0;e<arguments.length;e++)t=t.concat(y(arguments[e]));return t}var g=function(t){this.isToolbarDisabled=!1,void 0!==t&&(this.filters=t.filters,this.pageSize=t.pageSize,this.pageNumber=t.pageNumber,this.search=t.search,this.sort=t.sort,this.isToolbarDisabled=t.isToolbarDisabled)},v=function(t){void 0!==t&&(this.count=t.count,this.items=t.items)},k=function(t){},S=function(t,e,n,i){void 0===e&&(e=!1),void 0===n&&(n=!0),this.items=t,this.refresh=e,this.dataChanged=n,this.count=i},w=function(t){void 0===t&&(t=!0),this.loading=t},x=function(t){this.items=t},I=function(t){void 0===t&&(t=!0),this.loading=t},C=function(t){this.available=[],this.global=[],this.fieldSelectors=[],t&&(this.available=t.available,this.global=t.global,this.fieldSelectors=t.fieldSelectors)},F=function(t){this.fieldSelectors=t},T=function(t){this.searchText="",this.functions=[],this.fieldSelectors=[],t&&(this.searchText=t.searchText,this.functions=b(t.functions),this.fieldSelectors=t.fieldSelectors)},A=0,U=function(t){function e(e,n){var s=t.call(this,e)||this;return s.items=new i.BehaviorSubject([]),s.searchFunction=n,e&&e.subscribe((function(t){s.items.next(t.map((function(t){return new o.ListItemModel(t.id||"sky-list-data-in-memory-provider-item-"+ ++A,t)})))})),s}return m(e,t),e.prototype.count=function(){return this.items.pipe(s.map((function(t){return t.length})))},e.prototype.get=function(t){return this.filteredItems(t).pipe(s.map((function(e){if(t.pageNumber&&t.pageSize){var n=(t.pageNumber-1)*t.pageSize,i=e.slice(n,n+t.pageSize);return new v({count:e.length,items:i})}return new v({count:e.length,items:e})})))},e.prototype.filteredItems=function(t){var e=this,n=["show-selected"];return this.items.pipe(s.map((function(i){var s=!1,r=t.search,a=t.sort,l=t.filters;void 0!==e.lastItems&&e.lastItems===i||(s=!0,e.lastItems=i);var c=!1,p=!1;t.isToolbarDisabled?(c=!0,r=new T,l=l.filter((function(t){return n.indexOf(t.name)>=0})),p=!0):(void 0!==e.lastSearch&&e.lastSearch===r||(c=!0),void 0!==e.lastFilters&&e.lastFilters===l||(p=!0)),e.lastSearch=r,e.lastFilters=l;var u=i;if(s||p||void 0===e.lastFilterResults?l&&l.length>0?(u=u.filter((function(t){for(var e=0;e<l.length;e++){var n=l[e];if(void 0!==n.value&&""!==n.value&&!1!==n.value&&n.value!==n.defaultValue&&!n.filterFunction(t,n.value))return!1}return!0})),e.lastFilterResults=u):e.lastFilterResults=void 0:u=e.lastFilterResults,s||c||void 0===e.lastSearchResults||p)if(r&&void 0!==r.searchText&&r.searchText.length>0){var d,h=r.searchText.toLowerCase();d=void 0!==e.searchFunction?[e.searchFunction]:r.functions,u=u.filter((function(t){for(var e=!1,n=0;n<d.length;n++){var i=(0,d[n])(t.data,h);if("string"==typeof i&&-1!==i.indexOf(h)||!0===i){e=!0;break}}return e})),e.lastSearchResults=u}else e.lastSearchResults=void 0;else u=e.lastSearchResults;return a&&a.fieldSelectors.length>0&&(u=u.slice().sort((function(t,e){for(var n=0,i=0;i<a.fieldSelectors.length;i++){var s=a.fieldSelectors[i],r=o.getData(t.data,s.fieldSelector),l=o.getData(e.data,s.fieldSelector);if(n=o.compare(r,l),s.descending&&0!==n&&(n*=-1),0!==n)break}return n}))),u})))},e}(k),L=function(t){void 0!==t&&(this.itemsPerPage=t.itemsPerPage||10,this.maxDisplayedPages=t.maxDisplayedPages||5,this.pageCount=t.pageCount||0,this.pageNumber=t.pageNumber||1)},M=function(){this.selectedIdMap=new Map},P=function(t){this.items=[],this.showMultiselectToolbar=!1,t&&(this.exists=t.exists,this.disabled=t.disabled,this.items=t.items,this.type=t.type,this.showMultiselectToolbar=t.showMultiselectToolbar)},O=function(t){this.views=[],t&&(this.active=t.active,this.views=t.views)},E=function(){this.filters=[],this.items=new o.AsyncList,this.paging=new L,this.search=new T,this.selected=new o.AsyncItem,this.sort=new C,this.toolbar=new P,this.views=new O,this.selected.item=new M},D=function(t){this.filters=t},V=function(t){void 0===t&&(t=[]),this.functions=t},_=function(t){this.searchText=t},j=function(t){void 0===t&&(t=[]),this.fieldSelectors=t},N=function(t,e,n){this.searchTextAction=t,this.setFieldSelectorsAction=e,this.setFunctionsAction=n},R=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0),this.items=t,this.selected=e,this.refresh=n},B=function(t){this.available=t},q=function(t){this.global=t},z=function(t){this.disable=t},G=function(t,e){void 0===e&&(e=-1),this.items=t,this.index=e},$=function(t){this.ids=t},H=function(t){this.exists=t},K=function(t){this.exists=t},Y=function(t){this.view=t},J=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return m(e,t),e}(o.StateOrchestrator),Q=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return m(n,t),n.prototype.viewsSetActive=function(t){this.next(new Y(t))},n.prototype.toolbarExists=function(t){this.next(new H(t))},n.prototype.toolbarSetDisabled=function(t){this.next(new z(t))},n.prototype.toolbarAddItems=function(t,e){void 0===e&&(e=-1),this.next(new G(t,e))},n.prototype.toolbarRemoveItems=function(t){this.next(new $(t))},n.prototype.toolbarShowMultiselectToolbar=function(t){this.next(new K(t))},n.prototype.searchSetFunctions=function(t){this.next(new V(t))},n.prototype.searchSetFieldSelectors=function(t){this.next(new j(t))},n.prototype.searchSetText=function(t){this.next(new _(t))},n.prototype.searchSetOptions=function(t){this.next(new N(new _(t.searchText),new j(t.fieldSelectors),new V(t.functions)))},n.prototype.sortSetAvailable=function(t){this.next(new B(t))},n.prototype.sortSetFieldSelectors=function(t){this.next(new F(t))},n.prototype.sortSetGlobal=function(t){this.next(new q(t))},n.prototype.filtersUpdate=function(t){this.next(new D(t))},n.prototype.setSelected=function(t,e,n){void 0===n&&(n=!1),this.next(new R(t,e,n))},n=f([e.Injectable()],n)}(o.StateDispatcher),W=function(t){function e(){var e=t.call(this)||this;return e.register(D,e.update),e}return m(e,t),e.prototype.update=function(t,e){return b(e.filters)},e}(J),X=function(t,e,n){void 0===e&&(e=!1),void 0===n&&(n=!0),this.items=t,this.selected=e,this.refresh=n},Z=function(t){function e(){var e=t.call(this)||this;return e.register(w,e.setLoading).register(S,e.load).register(X,e.setItemsSelected),e}return m(e,t),e.prototype.setLoading=function(t,e){return new o.AsyncList(t.items,t.lastUpdate,e.loading,t.count)},e.prototype.load=function(t,e){var n=e.items.map((function(t){return new o.ListItemModel(t.id,t.data,t.isSelected)})),i=e.refresh?b(n):b(t.items,n),s=void 0===e.count?i.length:e.count;return new o.AsyncList(i,e.dataChanged?Date.now():t.lastUpdate,!1,s)},e.prototype.setItemsSelected=function(t,e){var n=e.items||[],i=this.cloneListItemModelArray(t.items);return e.refresh&&i.forEach((function(t){return t.isSelected=void 0})),n.map((function(t){var n=i.find((function(e){return e.id===t}));n&&(n.isSelected=e.selected)})),new o.AsyncList(i,Date.now(),t.loading,t.count)},e.prototype.cloneListItemModelArray=function(t){var e=[];return t.forEach((function(t){e.push(new o.ListItemModel(t.id,Object.assign({},t.data),t.isSelected))})),e},e}(J),tt=function(t){this.maxPages=t},et=function(t){this.itemsPerPage=t},nt=function(t){this.pageNumber=t},it=function(t){function e(){var e=t.call(this)||this;return e.register(tt,e.setMaxPages).register(et,e.setItemsPerPage).register(nt,e.setPageNumber),e}return m(e,t),e.prototype.setMaxPages=function(t,e){return new L(Object.assign({},t,{maxDisplayedPages:Number(e.maxPages)}))},e.prototype.setItemsPerPage=function(t,e){return new L(Object.assign({},t,{itemsPerPage:Number(e.itemsPerPage)}))},e.prototype.setPageNumber=function(t,e){return new L(Object.assign({},t,{pageNumber:Number(e.pageNumber)}))},e}(J),st=function(t){this.views=t},ot=function(t){function e(){var e=t.call(this)||this;return e.register(Y,e.setActive).register(st,e.load),e}return m(e,t),e.prototype.setActive=function(t,e){return new O(Object.assign({},t,{active:e.view}))},e.prototype.load=function(t,e){return new O(Object.assign({},t,{views:e.views}))},e}(J),rt=function(t){this.index=-1,t&&(this.index=t.index,this.template=t.template,this.location=t.location,this.view=t.view,this.id=t.id)},at=function(t){this.type=t},lt=function(t){function e(){var e=t.call(this)||this;return e.register(H,e.setExists).register(z,e.setDisabled).register(G,e.load).register(at,e.setType).register($,e.remove).register(K,e.showMultiselectToolbar),e}return m(e,t),e.prototype.setExists=function(t,e){var n=new P(t);return n.exists=e.exists,n},e.prototype.setDisabled=function(t,e){var n=new P(t);return n.disabled=e.disable,n},e.prototype.setType=function(t,e){var n=new P(t);return n.type=e.type,n},e.prototype.load=function(t,e){var n=new P(t),i=e.items.map((function(t){return t.index||(t.index=e.index),new rt(t)})),s=b(t.items,i);return s=s.sort((function(t,e){return t.index<e.index?-1:t.index>e.index?1:0})),n.items=s,n},e.prototype.remove=function(t,e){var n=new P(t);return n.items=n.items.filter((function(t){return-1===e.ids.indexOf(t.id)})),n},e.prototype.showMultiselectToolbar=function(t,e){var n=new P(t);return n.showMultiselectToolbar=e.exists,n},e}(J),ct=function(t){function e(){var e=t.call(this)||this;return e.register(_,e.setSearchText).register(V,e.setFunctions).register(j,e.setFieldSelectors).register(N,e.setOptions),e}return m(e,t),e.prototype.setSearchText=function(t,e){return new T(Object.assign({},t,{searchText:e.searchText?e.searchText:""}))},e.prototype.setFunctions=function(t,e){return new T(Object.assign({},t,{functions:b(e.functions)}))},e.prototype.setFieldSelectors=function(t,e){return new T(Object.assign({},t,{fieldSelectors:b(e.fieldSelectors)}))},e.prototype.setOptions=function(t,e){var n=t;return e.searchTextAction&&(n=this.setSearchText(n,e.searchTextAction)),e.setFieldSelectorsAction&&(n=this.setFieldSelectors(n,e.setFieldSelectorsAction)),e.setFunctionsAction&&(n=this.setFunctions(n,e.setFunctionsAction)),n},e}(J),pt=function(t,e){this.id=t,this.selected=e},ut=function(t){function e(){var e=t.call(this)||this;return e.register(I,e.setLoading).register(pt,e.setItemSelected).register(R,e.setItemsSelected).register(x,e.load),e}return m(e,t),e.prototype.setLoading=function(t,e){return new o.AsyncItem(t.item,t.lastUpdate,e.loading)},e.prototype.load=function(t,e){var n=new M;return e.items.map((function(t){return n.selectedIdMap.set(t,!0)})),new o.AsyncItem(Object.assign({},t.item,n),Date.now(),!1)},e.prototype.setItemSelected=function(t,e){var n=this.cloneListSelectedModel(t.item);return n.selectedIdMap.set(e.id,e.selected),new o.AsyncItem(n,t.lastUpdate,t.loading)},e.prototype.setItemsSelected=function(t,e){var n=e.items||[],r=e.refresh?new M:this.cloneListSelectedModel(t.item);return n instanceof i.Observable?n.pipe(s.take(1)).subscribe((function(t){t.map((function(t){return r.selectedIdMap.set(t,e.selected)}))})):n.map((function(t){return r.selectedIdMap.set(t,e.selected)})),new o.AsyncItem(r,t.lastUpdate,t.loading)},e.prototype.cloneListSelectedModel=function(t){var e=new M;return e.selectedIdMap=new Map(t.selectedIdMap),e},e}(J),dt=function(t){this.global=!1,this.descending=!1,t&&(this.text=t.text,this.fieldType=t.fieldType,this.fieldSelector=t.fieldSelector,this.global=t.global,this.descending=t.descending)},ht=function(t){function e(){var e=t.call(this)||this;return e.register(F,e.setFieldSelectors).register(B,e.setAvailable).register(q,e.setGlobal),e}return m(e,t),e.prototype.setFieldSelectors=function(t,e){return new C(Object.assign({},t,{fieldSelectors:e.fieldSelectors}))},e.prototype.setAvailable=function(t,e){var n=e.available.map((function(t){return new dt(t)}));return new C(Object.assign({},t,{available:n}))},e.prototype.setGlobal=function(t,e){var n=e.global.map((function(t){return new dt(t)}));return new C(Object.assign({},t,{global:n}))},e}(J),mt=function(t){function n(e){var n=t.call(this,new E,e)||this;return n.register("filters",W).register("items",Z).register("paging",it).register("search",ct).register("sort",ht).register("toolbar",lt).register("views",ot).register("selected",ut).begin(),n}return m(n,t),n.ctorParameters=function(){return[{type:Q}]},n=f([e.Injectable()],n)}(o.StateNode),ft=0,yt=function(){function t(t,e){var n=this;this.viewId="sky-list-view-cmp-"+ ++ft,this.state=t,this.viewName=e,this.hasToolbar=this.state.pipe(s.map((function(t){return t.toolbar.exists}))),this.active=this.state.pipe(s.map((function(t){return t.views.active===n.viewId}))),this.active.pipe(s.distinctUntilChanged()).subscribe((function(t){return t?n.onViewActive():n.onViewInactive()}))}return Object.defineProperty(t.prototype,"id",{get:function(){return this.viewId},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"label",{get:function(){return this.viewName},enumerable:!0,configurable:!0}),t.prototype.onViewActive=function(){},t.prototype.onViewInactive=function(){},t}(),bt=function(t,e){this.id=t,this.name=e},gt=0,vt=function(){function t(t,n){this.state=t,this.dispatcher=n,this.id="sky-list-cmp-"+ ++gt,this.data=[],this.appliedFilters=[],this.selectedIdsChange=new e.EventEmitter,this.appliedFiltersChange=new e.EventEmitter,this.dataFirstLoad=!1,this.lastSelectedIds=[],this.lastFilters=[],this.ngUnsubscribe=new i.Subject}return t.prototype.ngAfterContentInit=function(){var t=this;if(this.data&&this.dataProvider&&this.initialTotal&&(this.dataFirstLoad=!0),this.listViews.length>0){var e=void 0===this.defaultView?this.listViews.first:this.defaultView;this.dispatcher.next(new st(this.listViews.map((function(t){return new bt(t.id,t.label)})))),this.dispatcher.next(new Y(e.id)),o.getValue(this.sortFields,(function(e){var n;n=!Array.isArray(e)&&e?[e]:e,t.dispatcher.next(new F(n||[]))})),this.displayedItems.subscribe((function(e){t.dispatcher.next(new w),t.dispatcher.next(new S(e.items,!0,!0,e.count))})),this.state.pipe(s.map((function(t){return t.selected})),s.takeUntil(this.ngUnsubscribe),s.distinctUntilChanged()).subscribe((function(e){var n=[];e.item.selectedIdMap.forEach((function(t,e){!0===t&&n.push(e)}));var i=!t.arraysEqual(t.lastSelectedIds,n);t.selectedIdsChange.observers.length>0&&i&&t.selectedIdsChange.emit(e.item.selectedIdMap),t.lastSelectedIds=n})),this.appliedFiltersChange.observers.length>0&&this.state.pipe(s.map((function(t){return t.filters})),s.takeUntil(this.ngUnsubscribe),s.skip(1)).subscribe((function(e){t.arraysEqual(e,t.lastFilters)||(t.lastFilters=e.slice(0),t.appliedFiltersChange.emit(e))}))}},t.prototype.ngOnChanges=function(t){var e=this;if(t.appliedFilters&&t.appliedFilters.currentValue!==t.appliedFilters.previousValue&&this.state.pipe(s.take(1)).subscribe((function(t){t.paging.pageNumber&&1!==t.paging.pageNumber&&e.dispatcher.next(new nt(Number(1))),e.dispatcher.filtersUpdate(e.appliedFilters)})),t.selectedIds){var n=t.selectedIds.currentValue;this.arraysEqual(n,this.lastSelectedIds)||this.dispatcher.setSelected(n,!0,!0)}},t.prototype.ngOnDestroy=function(){this.ngUnsubscribe.next(),this.ngUnsubscribe.complete()},t.prototype.refreshDisplayedItems=function(){var t=this;this.displayedItems.pipe(s.take(1)).subscribe((function(e){t.dispatcher.next(new w),t.dispatcher.next(new S(e.items,!0,!0,e.count))}))},Object.defineProperty(t.prototype,"displayedItems",{get:function(){var t=this;if(!this.data&&!this.dataProvider)throw new Error("List requires data or dataProvider to be set.");var e=this.data;o.isObservable(e)||(e=i.of(this.data)),this.dataProvider||(this.dataProvider=new U(e,this.searchFunction));var n=this.selectedIds||i.of([]);o.isObservable(n)||(n=i.of(n));var r=!1,a=new i.Subject;return i.combineLatest([this.state.pipe(s.map((function(t){return t.filters})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.search})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.sort.fieldSelectors})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.paging.itemsPerPage})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.paging.pageNumber})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.toolbar.disabled})),s.distinctUntilChanged()),n.pipe(s.distinctUntilChanged(),s.map((function(t){return r=!0,t}))),e.pipe(s.distinctUntilChanged())],(function(e,n,l,c,p,u,d,h){var m;if(a.next(),a.complete(),r&&(t.dispatcher.next(new I),t.dispatcher.next(new x(d)),t.dispatcher.next(new I(!1)),r=!1),t.dataFirstLoad){t.dataFirstLoad=!1;var f=h.map((function(t){return new o.ListItemModel(t.id||"sky-list-item-model-"+ ++gt,t)}));m=i.of(new v({count:t.initialTotal,items:f})).pipe(s.takeUntil(a))}else m=t.dataProvider.get(new g({filters:e,pageSize:c,pageNumber:p,search:n,sort:new C({fieldSelectors:l}),isToolbarDisabled:u})).pipe(s.takeUntil(a));return m})).pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(e){return e.pipe(s.map((function(e){return new v({count:e.count,items:t.getItemsAndRetainSelections(e.items,t.lastSelectedIds)})})))})),s.flatMap((function(t){return t})))},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"selectedItems",{get:function(){return i.combineLatest(this.state.pipe(s.map((function(t){return t.items.items})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.selected})),s.distinctUntilChanged()),(function(t,e){return t.filter((function(t){return e.item.selectedIdMap.get(t.id)}))})).pipe(s.takeUntil(this.ngUnsubscribe))},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"lastUpdate",{get:function(){return this.state.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.items.lastUpdate?new Date(t.items.lastUpdate):void 0})))},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"views",{get:function(){return this.listViews.toArray()},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"itemCount",{get:function(){return this.dataProvider.count()},enumerable:!0,configurable:!0}),t.prototype.getItemsAndRetainSelections=function(t,e){var n=t.slice();return n.forEach((function(t){t.isSelected=e.indexOf(t.id)>-1})),n},t.prototype.arraysEqual=function(t,e){if(t===e)return!0;if(void 0===t||void 0===e)return!1;if(t.length!==e.length)return!1;for(var n=0;n<t.length;++n)if(t[n]!==e[n])return!1;return!0},t.ctorParameters=function(){return[{type:mt},{type:Q}]},f([e.Input()],t.prototype,"data",void 0),f([e.Input()],t.prototype,"dataProvider",void 0),f([e.Input()],t.prototype,"defaultView",void 0),f([e.Input()],t.prototype,"initialTotal",void 0),f([e.Input()],t.prototype,"selectedIds",void 0),f([e.Input()],t.prototype,"sortFields",void 0),f([e.Input()],t.prototype,"appliedFilters",void 0),f([e.Output()],t.prototype,"selectedIdsChange",void 0),f([e.Output()],t.prototype,"appliedFiltersChange",void 0),f([e.Input("search")],t.prototype,"searchFunction",void 0),f([e.ContentChildren(yt)],t.prototype,"listViews",void 0),t=f([e.Component({selector:"sky-list",template:"<ng-content></ng-content>",providers:[mt,Q],changeDetection:e.ChangeDetectionStrategy.OnPush})],t)}(),kt=function(){function t(){}return t=f([e.NgModule({declarations:[vt],imports:[n.CommonModule],exports:[vt]})],t)}(),St=function(t){this.dismissible=!0,t&&(this.name=t.name,this.label=t.label,this.filterFunction=t.filterFunction,this.value=t.value,this.dismissible=t.dismissible,this.defaultValue=t.defaultValue)},wt=function(){function t(t){this.onChange=new e.EventEmitter,t&&(this.name=t.name,this.filterFunction=t.filterFunction,this.value=t.value,this.template=t.template,this.defaultValue=t.defaultValue)}return t.prototype.changed=function(t){this.value=t,this.onChange.emit(t)},t}(),xt=function(){function t(t){this.dispatcher=t,this.filterButtonItemToolbarIndex=5e3}return t.prototype.ngAfterViewInit=function(){this.dispatcher.toolbarAddItems([new rt({template:this.filterButtonTemplate,location:"left",index:this.filterButtonItemToolbarIndex})])},t.ctorParameters=function(){return[{type:Q}]},f([e.ViewChild("filterButton",{read:e.TemplateRef,static:!0})],t.prototype,"filterButtonTemplate",void 0),t=f([e.Component({selector:"sky-list-filter-button",template:"<ng-template #filterButton>\n <ng-content></ng-content>\n</ng-template>\n"})],t)}(),It=function(){function t(t,n){this.state=t,this.dispatcher=n,this.summaryItemClick=new e.EventEmitter}return t.prototype.ngAfterContentInit=function(){var t=this;setTimeout((function(){t.appliedFilters=t.state.pipe(s.map((function(t){return t.filters.filter((function(t){return""!==t.value&&void 0!==t.value&&!1!==t.value&&t.value!==t.defaultValue}))})))}))},t.prototype.filterSummaryItemDismiss=function(t){var e=this;this.appliedFilters.pipe(s.take(1)).subscribe((function(n){n.splice(t,1),e.dispatcher.filtersUpdate(n.slice())}))},t.prototype.filterSummaryItemClick=function(t){this.summaryItemClick.emit(t)},t.ctorParameters=function(){return[{type:mt},{type:Q}]},f([e.Output()],t.prototype,"summaryItemClick",void 0),t=f([e.Component({selector:"sky-list-filter-summary",template:'<sky-filter-summary>\n <sky-filter-summary-item\n *ngFor="let item of appliedFilters | async; let i = index"\n (dismiss)="filterSummaryItemDismiss(i)"\n (itemClick)="filterSummaryItemClick(item)"\n [dismissible]="item.dismissible"\n >\n {{item.label || item.value}}\n </sky-filter-summary-item>\n</sky-filter-summary>\n'})],t)}(),Ct=function(){function t(){this.onChange=new e.EventEmitter}return t.prototype.ngOnInit=function(){if(void 0===this.name||0===this.name.length)throw new Error("Inline filter requires a name.")},Object.defineProperty(t.prototype,"template",{get:function(){return this.templates.length>0?this.templates.first:this.templateInput},enumerable:!0,configurable:!0}),f([e.Input()],t.prototype,"name",void 0),f([e.Input()],t.prototype,"value",void 0),f([e.Input()],t.prototype,"defaultValue",void 0),f([e.Input("filter")],t.prototype,"filterFunction",void 0),f([e.Input("template")],t.prototype,"templateInput",void 0),f([e.ContentChildren(e.TemplateRef)],t.prototype,"templates",void 0),t=f([e.Component({selector:"sky-list-filter-inline-item",template:"<ng-content></ng-content>"})],t)}(),Ft=function(){function t(t,e){this.dispatcher=t,this.state=e,this.inlineFilters=[]}return t.prototype.ngAfterContentInit=function(){var t=this;this.inlineFilters=this.filters.map((function(t){return new wt({name:t.name,filterFunction:t.filterFunction,template:t.template,value:t.value,defaultValue:t.defaultValue})})),this.inlineFilters.forEach((function(e){e.onChange.subscribe((function(e){t.applyFilters()}))})),this.dispatcher.filtersUpdate(this.getFilterModelFromInline(this.inlineFilters))},t.prototype.applyFilters=function(){var t=this;this.state.pipe(s.take(1)).subscribe((function(e){e.paging.pageNumber&&1!==e.paging.pageNumber&&t.dispatcher.next(new nt(Number(1))),t.dispatcher.filtersUpdate(t.getFilterModelFromInline(t.inlineFilters))}))},t.prototype.getFilterModelFromInline=function(t){return t.map((function(t){return new St({name:t.name,value:t.value,filterFunction:t.filterFunction,defaultValue:t.defaultValue})}))},t.ctorParameters=function(){return[{type:Q},{type:mt}]},f([e.ContentChildren(Ct)],t.prototype,"filters",void 0),t=f([e.Component({selector:"sky-list-filter-inline",template:'<ng-content></ng-content>\n\n<sky-filter-inline>\n <sky-filter-inline-item\n *ngFor="let filter of inlineFilters">\n <sky-list-filter-inline-item-renderer\n [template]="filter.template"\n [filter]="filter">\n </sky-list-filter-inline-item-renderer>\n </sky-filter-inline-item>\n</sky-filter-inline>\n'})],t)}(),Tt=function(){function t(){}return t.prototype.ngOnInit=function(){void 0!==this.template&&this.container.createEmbeddedView(this.template,this)},f([e.Input()],t.prototype,"template",void 0),f([e.Input()],t.prototype,"filter",void 0),f([e.ViewChild("container",{read:e.ViewContainerRef,static:!0})],t.prototype,"container",void 0),t=f([e.Component({selector:"sky-list-filter-inline-item-renderer",template:"<ng-template #container></ng-template>"})],t)}(),At=function(){function t(){}return t=f([e.NgModule({declarations:[xt,It,Ct,Ft,Tt],imports:[n.CommonModule,r.SkyFilterModule],exports:[xt,It,Ct,Ft,Tt]})],t)}(),Ut=function(t,e){this.initialized=new i.BehaviorSubject(!1),this.state=t,this.dispatcher=e},Lt=function(t){function n(e,n){var i=t.call(this,e,n)||this;return i.pageSize=10,i.maxPages=5,i.pageNumber=1,i}var i;return m(n,t),i=n,n.prototype.ngOnInit=function(){var t=this;this.currentPageNumber=this.state.pipe(s.map((function(t){return t.paging.pageNumber}))),this.maxDisplayedPages=this.state.pipe(s.map((function(t){return t.paging.maxDisplayedPages}))),this.itemsPerPage=this.state.pipe(s.map((function(t){return t.paging.itemsPerPage}))),this.itemCount=this.state.pipe(s.map((function(t){return t.items})),s.scan((function(t,e){return t.lastUpdate>e.lastUpdate?t:e})),s.map((function(t){return t.count})),s.distinctUntilChanged()),o.getValue(this.pageSize,(function(e){return t.dispatcher.next(new et(Number(e)))})),o.getValue(this.maxPages,(function(e){return t.dispatcher.next(new tt(Number(e)))})),o.getValue(this.pageNumber,(function(e){return t.dispatcher.next(new nt(Number(e)))}))},n.prototype.pageChange=function(t){var e=this;setTimeout((function(){e.dispatcher.next(new nt(Number(t)))}))},n.ctorParameters=function(){return[{type:mt},{type:Q}]},f([e.Input()],n.prototype,"pageSize",void 0),f([e.Input()],n.prototype,"maxPages",void 0),f([e.Input()],n.prototype,"pageNumber",void 0),n=i=f([e.Component({selector:"sky-list-paging",template:'<sky-paging\n [pageSize]="itemsPerPage | async"\n [maxPages]="maxDisplayedPages | async"\n [currentPage]="currentPageNumber | async"\n [itemCount]="itemCount | async"\n (currentPageChange)="pageChange($event)"\n >\n</sky-paging>\n',providers:[{provide:Ut,useExisting:e.forwardRef((function(){return i}))}],changeDetection:e.ChangeDetectionStrategy.OnPush})],n)}(Ut),Mt=function(){function t(){}return t=f([e.NgModule({declarations:[Lt],imports:[n.CommonModule,r.SkyPagingModule],exports:[Lt]})],t)}(),Pt=function(){function t(){this.resources={"EN-US":{skyux_list_show_secondary_actions_button:"More",skyux_list_multiselect_clear_all:"Clear all",skyux_list_mutliselect_select_all:"Select all",skyux_list_mutliselect_show_selected:"Only show selected items",skyux_list_view_switcher_dropdown_title:"Select view"}}}return t.prototype.getString=function(t,e){return a.getStringForLocale(this.resources,t.locale,e)},t=f([e.Injectable()],t)}(),Ot=function(){function t(){}return t=f([e.NgModule({providers:[{provide:a.SKY_LIB_RESOURCES_PROVIDERS,useClass:Pt,multi:!0}]})],t)}(),Et=function(){function t(){this.secondaryActionsCount=0,this.secondaryActionsSubject=new i.BehaviorSubject(0),this.actionsStream=new i.BehaviorSubject([]),this.actions=[]}return t.prototype.addSecondaryAction=function(t){this.secondaryActionsCount++,this.secondaryActionsSubject.next(this.secondaryActionsCount),this.actions.push(t),this.actionsStream.next(this.actions)},t.prototype.removeSecondaryAction=function(t){this.secondaryActionsCount--,this.secondaryActionsSubject.next(this.secondaryActionsCount),this.actions=this.actions.filter((function(e){return e!==t})),this.actionsStream.next(this.actions)},t.prototype.ngOnDestroy=function(){this.secondaryActionsSubject.complete(),this.actionsStream.complete()},t=f([e.Injectable()],t)}(),Dt=function(){function t(t){this.dispatcher=t,this.actions=[],this.secondaryActionsItemToolbarIndex=5e3}return t.prototype.ngAfterViewInit=function(){var t=new rt({id:"secondary-actions",template:this.secondaryActionsTemplate,location:"center",index:this.secondaryActionsItemToolbarIndex});this.dispatcher.toolbarAddItems([t])},t.ctorParameters=function(){return[{type:Q}]},f([e.ViewChild("secondaryActions",{read:e.TemplateRef,static:!0})],t.prototype,"secondaryActionsTemplate",void 0),t=f([e.Component({selector:"sky-list-secondary-actions",template:"<ng-template #secondaryActions>\n <sky-list-secondary-actions-host>\n <ng-content></ng-content>\n </sky-list-secondary-actions-host>\n</ng-template>\n",providers:[Et],changeDetection:e.ChangeDetectionStrategy.OnPush})],t)}(),Vt=function(){function t(t){this.actionService=t}return t.prototype.ngAfterContentInit=function(){this.actionService.addSecondaryAction({template:this.templateRef})},t.ctorParameters=function(){return[{type:Et}]},f([e.ViewChild("listSecondaryAction",{read:e.TemplateRef,static:!0})],t.prototype,"templateRef",void 0),t=f([e.Component({selector:"sky-list-secondary-action",template:"<ng-template #listSecondaryAction>\n <ng-content></ng-content>\n</ng-template>\n"})],t)}(),_t=function(){function t(t,e){this.changeDetector=t,this.actionService=e,this.dropdownHidden=!1,this.actions=[],this.ngUnsubscribe=new i.Subject}return t.prototype.ngOnInit=function(){var t=this;this.actionService.actionsStream.pipe(s.takeUntil(this.ngUnsubscribe),s.distinctUntilChanged()).subscribe((function(e){var n=e.length>0;t.dropdownHidden=!n,t.actions=e,t.changeDetector.detectChanges()}))},t.prototype.ngOnDestroy=function(){this.ngUnsubscribe.next(),this.ngUnsubscribe.complete()},t.ctorParameters=function(){return[{type:e.ChangeDetectorRef},{type:Et}]},t=f([e.Component({selector:"sky-list-secondary-actions-host",template:'<div\n class="sky-list-secondary-actions"\n [ngClass]="{ \'sky-list-secondary-actions-hidden\': dropdownHidden }"\n>\n <sky-dropdown\n [attr.title]="\'skyux_list_show_secondary_actions_button\' | skyLibResources"\n [label]="\'skyux_list_show_secondary_actions_button\' | skyLibResources"\n >\n <sky-dropdown-button>\n <sky-icon\n icon="ellipsis-h"\n >\n </sky-icon>\n <span\n class="sky-list-secondary-actions-btn-text"\n >\n {{ \'skyux_list_show_secondary_actions_button\' | skyLibResources }}\n </span>\n </sky-dropdown-button>\n <sky-dropdown-menu>\n <sky-dropdown-item *ngFor="let action of actions">\n <ng-container *ngTemplateOutlet="action.template">\n </ng-container>\n </sky-dropdown-item>\n </sky-dropdown-menu>\n </sky-dropdown>\n</div>\n<ng-content>\n</ng-content>\n',changeDetection:e.ChangeDetectionStrategy.OnPush,styles:[".sky-list-secondary-actions ::ng-deep .sky-dropdown-button-type-select{padding:6px 12px}.sky-list-secondary-actions ::ng-deep .sky-dropdown-button-type-select sky-icon[icon=ellipsis-h]{font-size:1.33333em;line-height:.75em;vertical-align:-15%}.sky-list-secondary-actions-hidden{display:none}:host .sky-list-secondary-actions-btn-text{display:none}:host .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret{display:none}:host-context(.sky-responsive-container-lg) .sky-list-secondary-actions-btn-text,:host-context(.sky-responsive-container-md) .sky-list-secondary-actions-btn-text,:host-context(.sky-responsive-container-sm) .sky-list-secondary-actions-btn-text,:host-context(.sky-responsive-container-xs) .sky-list-secondary-actions-btn-text{display:none}:host-context(.sky-responsive-container-lg) .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret,:host-context(.sky-responsive-container-md) .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret,:host-context(.sky-responsive-container-sm) .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret,:host-context(.sky-responsive-container-xs) .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret{display:none}@media (min-width:768px){:host .sky-list-secondary-actions-btn-text{display:inline}:host .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret{display:inline-block}}:host-context(.sky-responsive-container-lg) .sky-list-secondary-actions-btn-text,:host-context(.sky-responsive-container-md) .sky-list-secondary-actions-btn-text,:host-context(.sky-responsive-container-sm) .sky-list-secondary-actions-btn-text{display:inline}:host-context(.sky-responsive-container-lg) .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret,:host-context(.sky-responsive-container-md) .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret,:host-context(.sky-responsive-container-sm) .sky-list-secondary-actions ::ng-deep .sky-dropdown-caret{display:inline-block}"]})],t)}(),jt=function(){function t(){}return t=f([e.NgModule({declarations:[Dt,_t,Vt],imports:[n.CommonModule,c.SkyDropdownModule,a.SkyI18nModule,l.SkyIconModule,Ot],exports:[Dt,_t,Vt]})],t)}(),Nt=0,Rt=function(){function t(){this.id="sky-list-toolbar-item-"+ ++Nt,this.index=-1,this.location="left"}return Object.defineProperty(t.prototype,"template",{get:function(){return this.templates.length>0?this.templates.first:void 0},enumerable:!0,configurable:!0}),f([e.Input()],t.prototype,"id",void 0),f([e.Input()],t.prototype,"index",void 0),f([e.Input()],t.prototype,"location",void 0),f([e.ContentChildren(e.TemplateRef)],t.prototype,"templates",void 0),t=f([e.Component({selector:"sky-list-toolbar-item",template:"<ng-content></ng-content>"})],t)}(),Bt=function(){function t(){}return f([e.Input()],t.prototype,"label",void 0),f([e.Input()],t.prototype,"field",void 0),f([e.Input()],t.prototype,"type",void 0),f([e.Input()],t.prototype,"descending",void 0),t=f([e.Component({selector:"sky-list-toolbar-sort",template:""})],t)}(),qt=function(){function t(){}return t=f([e.Component({selector:"sky-list-toolbar-view-actions",template:"<ng-content></ng-content>\n",styles:[":host{display:flex;align-items:center}:host::ng-deep>:not(:last-child){margin-right:5px}.sky-list-toolbar-view-actions ::ng-deep>:not(:last-child){margin-right:5px}"]})],t)}(),zt=function(t){this.enabled=t},Gt=function(t){void 0===t&&(t=!0),this.enabled=t},$t=function(t){this.searchEnabled=!0,this.sortSelectorEnabled=!0,t&&(this.searchEnabled=t.searchEnabled,this.sortSelectorEnabled=t.sortSelectorEnabled)},Ht=function(){this.config=new $t},Kt=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return m(n,t),n=f([e.Injectable()],n)}(o.StateDispatcher),Yt=function(t){function e(){var e=t.call(this)||this;return e.register(zt,e.setSearchEnabled).register(Gt,e.setSortSelectorEnabled),e}return m(e,t),e.prototype.setSearchEnabled=function(t,e){return new $t(Object.assign({},t,{searchEnabled:e.enabled}))},e.prototype.setSortSelectorEnabled=function(t,e){return new $t(Object.assign({},t,{sortSelectorEnabled:e.enabled}))},e}(function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return m(e,t),e}(o.StateOrchestrator)),Jt=function(t){function n(e,n){var i=t.call(this,e,n)||this;return i.register("config",Yt).begin(),i}return m(n,t),n.ctorParameters=function(){return[{type:Ht},{type:Kt}]},n=f([e.Injectable()],n)}(o.StateNode),Qt=0,Wt=function(){function t(t,e,n,s,o){this.changeDetector=t,this.state=e,this.dispatcher=n,this.toolbarState=s,this.toolbarDispatcher=o,this.toolbarType="standard",this.isToolbarDisabled=!1,this.inlineFilterBarExpanded=!1,this.hasAdditionalToolbarSection=!1,this.hasViewActions=!1,this.filterButtonId="sky-list-toolbar-filter-button-"+ ++Qt,this.listFilterInlineId="sky-list-toolbar-filter-inline-"+ ++Qt,this.searchApplied=new i.Subject,this.customItemIds=[],this.hasSortSelectors=!1,this.inlineFiltersItemToolbarIndex=5e3,this.sortSelectorItemToolbarIndex=6e3,this.ngUnsubscribe=new i.Subject}return Object.defineProperty(t.prototype,"inMemorySearchEnabled",{get:function(){return void 0===this._inMemorySearchEnabled||this._inMemorySearchEnabled},set:function(t){this._inMemorySearchEnabled=t},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"isFilterBarDisplayed",{get:function(){return!this.isToolbarDisabled&&this.hasInlineFilters&&this.inlineFilterBarExpanded},enumerable:!0,configurable:!0}),Object.defineProperty(t.prototype,"filterButtonAriaControls",{get:function(){return this.isFilterBarDisplayed?this.listFilterInlineId:void 0},enumerable:!0,configurable:!0}),t.prototype.ngOnInit=function(){var t=this;this.dispatcher.toolbarExists(!0),o.getValue(this.searchText,(function(e){t.updateSearchText(e)})),o.getValue(this.searchEnabled,(function(e){t.toolbarDispatcher.next(new zt(void 0===e||e))})),o.getValue(this.toolbarType,(function(e){t.dispatcher.next(new at(t.toolbarType))})),o.getValue(this.sortSelectorEnabled,(function(e){t.toolbarDispatcher.next(new Gt(void 0===e||e))})),this.sortSelectors=this.getSortSelectors(),this.sortSelectors.pipe(s.takeUntil(this.ngUnsubscribe),s.distinctUntilChanged()).subscribe((function(e){e.length>0&&!t.hasSortSelectors?(t.hasSortSelectors=!0,t.dispatcher.toolbarAddItems([new rt({id:"sort-selector",template:t.sortSelectorTemplate,location:"left",index:t.sortSelectorItemToolbarIndex})])):e.length<1&&t.hasSortSelectors&&(t.hasSortSelectors=!1,t.dispatcher.toolbarRemoveItems(["sort-selector"]))})),this.searchTextInput=this.state.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.search.searchText})),s.distinctUntilChanged()),this.view=this.state.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.views.active})),s.distinctUntilChanged()),this.watchTemplates(),this.type=this.state.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.toolbar.type})),s.distinctUntilChanged()),this.type.pipe(s.takeUntil(this.ngUnsubscribe)).subscribe((function(e){"search"===e?t.dispatcher.toolbarRemoveItems(["search"]):t.dispatcher.toolbarAddItems([new rt({id:"search",template:t.searchTemplate,location:"right"})])})),this.isSearchEnabled=this.toolbarState.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.config})),s.distinctUntilChanged(),s.map((function(t){return t.searchEnabled}))),this.state.pipe(s.map((function(t){return t.toolbar})),s.takeUntil(this.ngUnsubscribe),s.distinctUntilChanged(),s.map((function(t){return t.disabled}))).subscribe((function(e){return t.isToolbarDisabled=e})),this.isSortSelectorEnabled=this.toolbarState.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.config})),s.distinctUntilChanged(),s.map((function(t){return t.sortSelectorEnabled}))),this.isMultiselectEnabled=this.state.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.toolbar})),s.distinctUntilChanged(),s.map((function(t){return t.showMultiselectToolbar}))),this.hasAppliedFilters=this.state.pipe(s.takeUntil(this.ngUnsubscribe),s.map((function(t){return t.filters})),s.distinctUntilChanged(),s.map((function(t){return t.filter((function(t){return""!==t.value&&void 0!==t.value&&!1!==t.value&&t.value!==t.defaultValue})).length>0}))),this.state.pipe(s.takeUntil(this.ngUnsubscribe)).subscribe((function(e){t.hasAdditionalToolbarSection=e.toolbar.items.length>0,t.changeDetector.detectChanges()}))},t.prototype.ngAfterContentInit=function(){var t=this;this.toolbarItems.forEach((function(e){t.dispatcher.toolbarAddItems([new rt(e)]),t.customItemIds.push(e.id)})),this.toolbarItems.changes.pipe(s.takeUntil(this.ngUnsubscribe)).subscribe((function(e){e.forEach((function(e){t.customItemIds.indexOf(e.id)<0&&(t.dispatcher.toolbarAddItems([new rt(e)]),t.customItemIds.push(e.id))}));var n=[];t.customItemIds.forEach((function(i,s){e.find((function(t){return t.id===i}))||(n.push(i),t.customItemIds.splice(s,1))})),t.dispatcher.toolbarRemoveItems(n)}));var e=this.toolbarSorts.map((function(t){return new dt({text:t.label,fieldSelector:t.field,fieldType:t.type,global:!0,descending:t.descending})}));this.dispatcher.sortSetGlobal(e),this.showFilterSummary=this.filterSummary.length>0,this.hasInlineFilters=this.inlineFilter.length>0,this.hasInlineFilters&&this.dispatcher.toolbarAddItems([new rt({template:this.inlineFilterButtonTemplate,location:"left",index:this.inlineFiltersItemToolbarIndex})]),this.hasViewActions=this.viewActions.length>0},t.prototype.ngOnDestroy=function(){this.searchApplied.complete(),this.ngUnsubscribe.next(),this.ngUnsubscribe.complete()},t.prototype.setSort=function(t){var e=this;this.state.pipe(s.take(1)).subscribe((function(n){n.paging.pageNumber&&1!==n.paging.pageNumber&&e.dispatcher.next(new nt(Number(1))),e.dispatcher.sortSetFieldSelectors([{fieldSelector:t.fieldSelector,descending:t.descending}])}))},t.prototype.inlineFilterButtonClick=function(){this.inlineFilterBarExpanded=!this.inlineFilterBarExpanded},t.prototype.updateSearchText=function(t){var e=this;this.searchApplied.next(t),this.inMemorySearchEnabled&&this.state.pipe(s.take(1)).subscribe((function(n){n.paging.pageNumber&&1!==n.paging.pageNumber&&e.dispatcher.next(new nt(Number(1))),e.dispatcher.searchSetText(t)}))},t.prototype.itemIsInView=function(t,e){return void 0===t||t===e},t.prototype.getSortSelectors=function(){return i.combineLatest(this.state.pipe(s.map((function(t){return t.sort.available})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.sort.global})),s.distinctUntilChanged()),this.state.pipe(s.map((function(t){return t.sort.fieldSelectors})),s.distinctUntilChanged()),(function(t,e,n){return b(e.filter((function(e){return 0===t.filter((function(t){return t.fieldSelector===e.fieldSelector})).length})),t).map((function(t){var e=!1;return n.filter((function(e){return e.fieldSelector===t.fieldSelector&&e.descending===t.descending})).length>0&&(e=!0),{sort:t,selected:e}}))})).pipe(s.takeUntil(this.ngUnsubscribe))},t.prototype.watchTemplates=function(){var t=this;i.combineLatest(this.state.pipe(s.map((function(t){return t.toolbar})),s.distinctUntilChanged()),this.view.pipe(s.distinctUntilChanged()),(function(e,n){var i=e.items.filter((function(e){return t.itemIsInView(e.view,n)})),s={};return i.forEach((function(t){s[t.location]=s[t.location]||[],s[t.location].push(t)})),s})).pipe(s.takeUntil(this.ngUnsubscribe)).subscribe((function(e){t.leftTemplates=e.left,t.centerTemplates=e.center,t.rightTemplates=e.right,t.changeDetector.markForCheck()}))},t.ctorParameters=function(){return[{type:e.ChangeDetectorRef},{type:mt},{type:Q},{type:Jt},{type:Kt}]},f([e.Input()],t.prototype,"inMemorySearchEnabled",null),f([e.Input()],t.prototype,"placeholder",void 0),f([e.Input()],t.prototype,"searchEnabled",void 0),f([e.ViewChild(u.SkySearchComponent,{read:u.SkySearchComponent,static:!1})],t.prototype,"searchComponent",void 0),f([e.Input()],t.prototype,"sortSelectorEnabled",void 0),f([e.Input()],t.prototype,"toolbarType",void 0),f([e.Input()],t.prototype,"searchText",void 0),f([e.ContentChildren(Rt)],t.prototype,"toolbarItems",void 0),f([e.ContentChildren(Bt)],t.prototype,"toolbarSorts",void 0),f([e.ContentChildren(It)],t.prototype,"filterSummary",void 0),f([e.ContentChildren(Ft)],t.prototype,"inlineFilter",void 0),f([e.ContentChildren(qt)],t.prototype,"viewActions",void 0),f([e.ViewChild("search",{read:e.TemplateRef,static:!0})],t.prototype,"searchTemplate",void 0),f([e.ViewChild("sortSelector",{read:e.TemplateRef,static:!0})],t.prototype,"sortSelectorTemplate",void 0),f([e.ViewChild("inlineFilterButton",{read:e.TemplateRef,static:!0})],t.prototype,"inlineFilterButtonTemplate",void 0),t=f([e.Component({selector:"sky-list-toolbar",template:'<div class="sky-list-toolbar-container">\n <sky-toolbar *ngIf="(type | async) !== \'search\'">\n\n <sky-toolbar-section>\n <sky-toolbar-item *ngFor="let item of leftTemplates">\n <sky-list-toolbar-item-renderer\n [attr.sky-cmp-id]="item.id"\n [template]="item.template"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n <sky-toolbar-item *ngFor="let item of centerTemplates">\n <sky-list-toolbar-item-renderer\n [attr.sky-cmp-id]="item.id"\n [template]="item.template"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n <sky-toolbar-item *ngFor="let item of rightTemplates"\n [attr.sky-toolbar-id]="item.id"\n >\n <sky-list-toolbar-item-renderer\n [attr.sky-cmp-id]="item.id"\n [template]="item.template"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n\n <ng-content></ng-content>\n\n <sky-toolbar-view-actions *ngIf="hasViewActions">\n <ng-content\n select="sky-list-toolbar-view-actions"\n >\n </ng-content>\n </sky-toolbar-view-actions>\n </sky-toolbar-section>\n\n <sky-toolbar-section *ngIf="showFilterSummary && (hasAppliedFilters | async)">\n <ng-content select="sky-list-filter-summary">\n </ng-content>\n </sky-toolbar-section>\n </sky-toolbar>\n\n <div *ngIf="(type | async) === \'search\' &&\n ((isSearchEnabled | async) || hasAdditionalToolbarSection)"\n class="sky-list-toolbar-search"\n >\n <sky-toolbar>\n <sky-toolbar-section *ngIf="(isSearchEnabled | async)">\n <sky-toolbar-item>\n <sky-list-toolbar-item-renderer\n sky-cmp-id="search"\n [template]="search"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n </sky-toolbar-section>\n <sky-toolbar-section [hidden]="!hasAdditionalToolbarSection">\n <sky-toolbar-item *ngFor="let item of leftTemplates">\n <sky-list-toolbar-item-renderer\n [attr.sky-cmp-id]="item.id"\n [template]="item.template"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n <sky-toolbar-item *ngFor="let item of centerTemplates">\n <sky-list-toolbar-item-renderer\n [attr.sky-cmp-id]="item.id"\n [template]="item.template"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n <sky-toolbar-item *ngFor="let item of rightTemplates"\n [attr.sky-toolbar-id]="item.id"\n >\n <sky-list-toolbar-item-renderer *ngIf="item.id !== \'search\'"\n [attr.sky-cmp-id]="item.id"\n [template]="item.template"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n <ng-content></ng-content>\n\n <sky-toolbar-view-actions *ngIf="hasViewActions">\n <ng-content\n select="sky-list-toolbar-view-actions"\n >\n </ng-content>\n </sky-toolbar-view-actions>\n </sky-toolbar-section>\n </sky-toolbar>\n </div>\n <div\n *ngIf="isFilterBarDisplayed"\n [attr.aria-labelledby]="filterButtonId"\n [id]="listFilterInlineId"\n >\n <ng-content select="sky-list-filter-inline">\n </ng-content>\n </div>\n <sky-list-multiselect-toolbar *ngIf="isMultiselectEnabled | async">\n </sky-list-multiselect-toolbar>\n</div>\n\n<ng-template #search>\n <div *ngIf="isSearchEnabled | async"\n class="sky-list-toolbar-search-wrapper"\n >\n <sky-search\n [disabled]="isToolbarDisabled"\n [expandMode]="(type | async) === \'search\' ? \'fit\' : \'responsive\'"\n [placeholderText]="placeholder"\n [searchText]="searchTextInput | async"\n (searchApply)="updateSearchText($event)"\n >\n </sky-search>\n <ng-content\n select="sky-list-toolbar-search-actions"\n ></ng-content>\n </div>\n</ng-template>\n\n<ng-template #sortSelector>\n <div *ngIf="(isSortSelectorEnabled | async) && (sortSelectors | async).length > 0"\n class="sky-toolbar-item-sort-container"\n >\n <sky-sort [showButtonText]="true">\n <sky-sort-item *ngFor="let item of sortSelectors | async"\n [active]="item.selected"\n (itemSelect)="setSort(item.sort)"\n >\n {{ item.sort.text }}\n </sky-sort-item>\n </sky-sort>\n </div>\n</ng-template>\n\n<ng-template #inlineFilterButton>\n <sky-filter-button\n [active]="hasAppliedFilters | async"\n [ariaControls]="filterButtonAriaControls"\n [ariaExpanded]="inlineFilterBarExpanded"\n [disabled]="isToolbarDisabled"\n [filterButtonId]="filterButtonId"\n [showButtonText]="true"\n (filterButtonClick)="inlineFilterButtonClick()"\n >\n </sky-filter-button>\n</ng-template>\n',providers:[Jt,Kt,Ht],changeDetection:e.ChangeDetectionStrategy.OnPush,styles:[".sky-list-toolbar-search-wrapper{display:flex}.sky-list-toolbar-search-wrapper ::ng-deep .sky-search-dismiss-absolute{padding:0;position:static}.sky-list-toolbar-search-wrapper ::ng-deep .sky-search-container{position:relative;height:100%}.sky-list-toolbar-search-wrapper ::ng-deep sky-search{flex:1 1 auto}.sky-list-toolbar-search-wrapper ::ng-deep sky-list-toolbar-search-actions{flex:0 0 auto;z-index:1}.sky-list-toolbar-container ::ng-deep .sky-toolbar-section-items sky-toolbar-item{flex:0 1 auto;align-self:flex-start}.sky-list-toolbar-search ::ng-deep .sky-toolbar-section{padding-top:0}.sky-list-toolbar-search ::ng-deep .sky-toolbar-section-items{display:block;width:100%}.sky-list-toolbar-search ::ng-deep .sky-toolbar-item{margin:0}.sky-list-toolbar-search ::ng-deep .sky-search-dismiss-absolute,.sky-list-toolbar-search ::ng-deep .sky-toolbar-container{background-color:#eeeeef}.sky-list-toolbar-search ::ng-deep .sky-search-btn:disabled,.sky-list-toolbar-search ::ng-deep input[type=text]:disabled{background-color:#cdcfd2;opacity:1}.sky-list-toolbar-container ::ng-deep sky-toolbar-item[sky-toolbar-id=sort-selector] .sky-toolbar-item{margin-right:0}.sky-list-toolbar-container ::ng-deep sky-checkbox{position:relative;top:-2px}"]})],t)}(),Xt=function(){function t(){}return t.prototype.ngOnInit=function(){void 0!==this.template&&this.container.createEmbeddedView(this.template,this)},f([e.Input()],t.prototype,"template",void 0),f([e.ViewChild("container",{read:e.ViewContainerRef,static:!0})],t.prototype,"container",void 0),t=f([e.Component({selector:"sky-list-toolbar-item-renderer",template:"<ng-template #container></ng-template>"})],t)}(),Zt=0,te=function(){function t(t,e){this.state=t,this.dispatcher=e,this.showOnlySelected=!1,this.multiselectToolbarId="sky-list-multiselect-toolbar-"+Zt++,this.selectedIdMap=new Map,this.ngUnsubscribe=new i.Subject}return t.prototype.ngOnInit=function(){var t=this;this.state.pipe(s.map((function(t){return t.selected.item})),s.takeUntil(this.ngUnsubscribe),s.distinctUntilChanged(this.selectedMapEqual)).subscribe((function(e){t.selectedIdMap=e.selectedIdMap,t.showOnlySelected&&t.reapplyFilter(!0)})),this.state.pipe(s.map((function(t){return t.filters})),s.takeUntil(this.ngUnsubscribe),s.distinctUntilChanged(this.showSelectedValuesEqual)).subscribe((function(e){var n=e.find((function(t){return"show-selected"===t.name}));n&&(t.showOnlySelected="true"===n.value)}))},t.prototype.ngOnDestroy=function(){this.ngUnsubscribe.next(),this.ngUnsubscribe.complete()},t.prototype.selectAll=function(){var t=this;this.state.pipe(s.map((function(t){return t.items.items})),s.take(1)).subscribe((function(e){t.dispatcher.setSelected(e.map((function(t){return t.id})),!0),t.showOnlySelected&&t.reapplyFilter(t.showOnlySelected)}))},t.prototype.clearSelections=function(){var t=this;this.state.pipe(s.map((function(t){return t.items.items})),s.take(1)).subscribe((function(e){t.dispatcher.setSelected(e.map((function(t){return t.id})),!1),t.showOnlySelected&&t.reapplyFilter(t.showOnlySelected)}))},t.prototype.changeVisibleItems=function(t){this.showOnlySelected=t.checked,this.reapplyFilter(t.checked)},t.prototype.reapplyFilter=function(t){var e=this,n=this;this.state.pipe(s.map((function(t){return t.filters})),s.take(1)).subscribe((function(i){(i=i.filter((function(t){return"show-selected"!==t.name}))).push(n.getShowSelectedFilter(t)),e.dispatcher.filtersUpdate(i)})),t&&this.state.pipe(s.take(1)).subscribe((function(t){t.paging.pageNumber&&1!==t.paging.pageNumber&&e.dispatcher.next(new nt(Number(1)))})),this.dispatcher.toolbarSetDisabled(t)},t.prototype.getShowSelectedFilter=function(t){var e=this;return new St({name:"show-selected",value:t.toString(),filterFunction:function(t,n){if(n.toString()!==(!1).toString())return e.selectedIdMap.get(t.id)},defaultValue:(!1).toString()})},t.prototype.showSelectedValuesEqual=function(t,e){var n=t.find((function(t){return"show-selected"===t.name})),i=e.find((function(t){return"show-selected"===t.name}));return!n&&!i||!(n&&!i||!n&&i)&&n.value===i.value},t.prototype.selectedMapEqual=function(t,e){if(t.selectedIdMap.size!==e.selectedIdMap.size)return!1;for(var n=0;n<e.selectedIdMap.size;n++){var i=Array.from(e.selectedIdMap.keys())[n];if(e.selectedIdMap.get(i)!==t.selectedIdMap.get(i))return!1}return!0},t.ctorParameters=function(){return[{type:mt},{type:Q}]},f([e.Input()],t.prototype,"showOnlySelected",void 0),t=f([e.Component({selector:"sky-list-multiselect-toolbar",template:'<sky-toolbar\n class="sky-list-multiselect-toolbar"\n>\n <sky-toolbar-section>\n <sky-toolbar-item>\n <sky-list-toolbar-item-renderer\n [template]="selectAllTemplate"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n <sky-toolbar-item>\n <sky-list-toolbar-item-renderer\n [template]="clearSelectionsTemplate"\n >\n </sky-list-toolbar-item-renderer>\n </sky-toolbar-item>\n <sky-toolbar-view-actions>\n <ng-container *ngTemplateOutlet="showSelectedTemplate"></ng-container>\n </sky-toolbar-view-actions>\n </sky-toolbar-section>\n</sky-toolbar>\n\n<ng-template #selectAllTemplate>\n <button\n class="sky-btn sky-btn-link"\n type="button"\n [attr.id]="multiselectToolbarId + \'-select-all\'"\n (click)="selectAll();$event.preventDefault();"\n >\n {{ \'skyux_list_mutliselect_select_all\' | skyLibResources }}\n </button>\n</ng-template>\n\n<ng-template #clearSelectionsTemplate>\n <button\n class="sky-btn sky-btn-link"\n type="button"\n [attr.id]="multiselectToolbarId + \'-clear-all\'"\n (click)="clearSelections();$event.preventDefault();"\n >\n {{ \'skyux_list_multiselect_clear_all\' | skyLibResources }}\n </button>\n</ng-template>\n\n<ng-template #showSelectedTemplate>\n <sky-checkbox\n [attr.id]="multiselectToolbarId + \'-show-selected\'"\n [checked]="showOnlySelected"\n (change)="changeVisibleItems($event)"\n >\n <sky-checkbox-label>\n {{ \'skyux_list_mutliselect_show_selected\' | skyLibResources }}\n </sky-checkbox-label>\n </sky-checkbox>\n</ng-template>\n',styles:[":host-context(.sky-list-toolbar-search+) .sky-list-multiselect-toolbar ::ng-deep .sky-toolbar-container,:host-context(sky-toolbar+) .sky-list-multiselect-toolbar ::ng-deep .sky-toolbar-container{border-top:none}"]})],t)}(),ee=function(){function t(){}return t=f([e.Component({selector:"sky-list-toolbar-search-actions",template:'<div\n class="sky-list-toolbar-search-actions"\n>\n <ng-content></ng-content>\n</div>\n',changeDetection:e.ChangeDetectionStrategy.OnPush,styles:[".sky-list-toolbar-search-actions{margin-left:10px}"]})],t)}(),ne=function(){function t(){}return t=f([e.NgModule({declarations:[Wt,Rt,Xt,te,ee,Bt,qt],imports:[n.CommonModule,d.SkyCheckboxModule,a.SkyI18nModule,p.SkyToolbarModule,u.SkySearchModule,r.SkySortModule,r.SkyFilterModule,At,l.SkyIconModule,Ot],exports:[Wt,Rt,Xt,te,ee,Bt,qt]})],t)}();t.ListDataProvider=k,t.ListDataRequestModel=g,t.ListDataResponseModel=v,t.ListFilterModel=St,t.ListFiltersOrchestrator=W,t.ListFiltersUpdateAction=D,t.ListItemsLoadAction=S,t.ListItemsOrchestrator=Z,t.ListItemsSetLoadingAction=w,t.ListItemsSetSelectedAction=X,t.ListPagingModel=L,t.ListPagingOrchestrator=it,t.ListPagingSetItemsPerPageAction=et,t.ListPagingSetMaxPagesAction=tt,t.ListPagingSetPageNumberAction=nt,t.ListSearchModel=T,t.ListSearchOrchestrator=ct,t.ListSearchSetFieldSelectorsAction=j,t.ListSearchSetFunctionsAction=V,t.ListSearchSetOptionsAction=N,t.ListSearchSetSearchTextAction=_,t.ListSelectedLoadAction=x,t.ListSelectedModel=M,t.ListSelectedOrchestrator=ut,t.ListSelectedSetItemSelectedAction=pt,t.ListSelectedSetItemsSelectedAction=R,t.ListSelectedSetLoadingAction=I,t.ListSortLabelModel=dt,t.ListSortModel=C,t.ListSortOrchestrator=ht,t.ListSortSetAvailableAction=B,t.ListSortSetFieldSelectorsAction=F,t.ListSortSetGlobalAction=q,t.ListState=mt,t.ListStateDispatcher=Q,t.ListStateModel=E,t.ListStateOrchestrator=J,t.ListToolbarItemModel=rt,t.ListToolbarItemsDisableAction=z,t.ListToolbarItemsLoadAction=G,t.ListToolbarItemsRemoveAction=$,t.ListToolbarModel=P,t.ListToolbarOrchestrator=lt,t.ListToolbarSetExistsAction=H,t.ListToolbarSetTypeAction=at,t.ListToolbarShowMultiselectToolbarAction=K,t.ListViewComponent=yt,t.ListViewModel=bt,t.ListViewsLoadAction=st,t.ListViewsModel=O,t.ListViewsOrchestrator=ot,t.ListViewsSetActiveAction=Y,t.SkyListComponent=vt,t.SkyListFilterInlineModel=wt,t.SkyListFiltersModule=At,t.SkyListInMemoryDataProvider=U,t.SkyListModule=kt,t.SkyListPagingModule=Mt,t.SkyListSecondaryActionsComponent=Dt,t.SkyListSecondaryActionsModule=jt,t.SkyListToolbarComponent=Wt,t.SkyListToolbarModule=ne,t.ɵa=xt,t.ɵb=It,t.ɵc=Ct,t.ɵd=Ft,t.ɵe=Tt,t.ɵf=Lt,t.ɵg=Ut,t.ɵh=Et,t.ɵi=_t,t.ɵj=Vt,t.ɵk=Ot,t.ɵl=Pt,t.ɵm=Jt,t.ɵn=Ht,t.ɵo=Kt,t.ɵp=Rt,t.ɵq=Bt,t.ɵr=qt,t.ɵs=Xt,t.ɵt=te,t.ɵu=ee,Object.defineProperty(t,"__esModule",{value:!0})}));
16
- //# sourceMappingURL=skyux-list-builder.umd.min.js.map