@ng-nest/ui 12.0.5 → 12.0.10

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 (794) hide show
  1. package/auto-complete/auto-complete-portal.component.d.ts +3 -3
  2. package/auto-complete/auto-complete.component.d.ts +6 -2
  3. package/auto-complete/auto-complete.property.d.ts +17 -2
  4. package/back-top/back-top.component.d.ts +1 -2
  5. package/base-form/base-form.component.d.ts +1 -1
  6. package/base-form/base-form.property.d.ts +48 -3
  7. package/bundles/ng-nest-ui-affix.umd.js +25 -21
  8. package/bundles/ng-nest-ui-affix.umd.js.map +1 -1
  9. package/bundles/ng-nest-ui-alert.umd.js +25 -21
  10. package/bundles/ng-nest-ui-alert.umd.js.map +1 -1
  11. package/bundles/ng-nest-ui-anchor.umd.js +26 -22
  12. package/bundles/ng-nest-ui-anchor.umd.js.map +1 -1
  13. package/bundles/ng-nest-ui-api.umd.js +12 -14
  14. package/bundles/ng-nest-ui-api.umd.js.map +1 -1
  15. package/bundles/ng-nest-ui-auto-complete.umd.js +74 -36
  16. package/bundles/ng-nest-ui-auto-complete.umd.js.map +1 -1
  17. package/bundles/ng-nest-ui-avatar.umd.js +25 -21
  18. package/bundles/ng-nest-ui-avatar.umd.js.map +1 -1
  19. package/bundles/ng-nest-ui-back-top.umd.js +27 -23
  20. package/bundles/ng-nest-ui-back-top.umd.js.map +1 -1
  21. package/bundles/ng-nest-ui-badge.umd.js +27 -22
  22. package/bundles/ng-nest-ui-badge.umd.js.map +1 -1
  23. package/bundles/ng-nest-ui-base-form.umd.js +67 -22
  24. package/bundles/ng-nest-ui-base-form.umd.js.map +1 -1
  25. package/bundles/ng-nest-ui-border.umd.js +12 -14
  26. package/bundles/ng-nest-ui-border.umd.js.map +1 -1
  27. package/bundles/ng-nest-ui-button.umd.js +36 -29
  28. package/bundles/ng-nest-ui-button.umd.js.map +1 -1
  29. package/bundles/ng-nest-ui-calendar.umd.js +29 -24
  30. package/bundles/ng-nest-ui-calendar.umd.js.map +1 -1
  31. package/bundles/ng-nest-ui-card.umd.js +25 -21
  32. package/bundles/ng-nest-ui-card.umd.js.map +1 -1
  33. package/bundles/ng-nest-ui-carousel.umd.js +35 -30
  34. package/bundles/ng-nest-ui-carousel.umd.js.map +1 -1
  35. package/bundles/ng-nest-ui-cascade.umd.js +94 -36
  36. package/bundles/ng-nest-ui-cascade.umd.js.map +1 -1
  37. package/bundles/ng-nest-ui-checkbox.umd.js +28 -23
  38. package/bundles/ng-nest-ui-checkbox.umd.js.map +1 -1
  39. package/bundles/ng-nest-ui-collapse.umd.js +31 -27
  40. package/bundles/ng-nest-ui-collapse.umd.js.map +1 -1
  41. package/bundles/ng-nest-ui-color-picker.umd.js +79 -44
  42. package/bundles/ng-nest-ui-color-picker.umd.js.map +1 -1
  43. package/bundles/ng-nest-ui-color.umd.js +26 -22
  44. package/bundles/ng-nest-ui-color.umd.js.map +1 -1
  45. package/bundles/ng-nest-ui-comment.umd.js +34 -29
  46. package/bundles/ng-nest-ui-comment.umd.js.map +1 -1
  47. package/bundles/ng-nest-ui-container.umd.js +46 -42
  48. package/bundles/ng-nest-ui-container.umd.js.map +1 -1
  49. package/bundles/ng-nest-ui-core.umd.js +136 -35
  50. package/bundles/ng-nest-ui-core.umd.js.map +1 -1
  51. package/bundles/ng-nest-ui-crumb.umd.js +28 -23
  52. package/bundles/ng-nest-ui-crumb.umd.js.map +1 -1
  53. package/bundles/ng-nest-ui-date-picker.umd.js +923 -176
  54. package/bundles/ng-nest-ui-date-picker.umd.js.map +1 -1
  55. package/bundles/ng-nest-ui-description.umd.js +35 -32
  56. package/bundles/ng-nest-ui-description.umd.js.map +1 -1
  57. package/bundles/ng-nest-ui-dialog.umd.js +27 -22
  58. package/bundles/ng-nest-ui-dialog.umd.js.map +1 -1
  59. package/bundles/ng-nest-ui-doc.umd.js +12 -14
  60. package/bundles/ng-nest-ui-doc.umd.js.map +1 -1
  61. package/bundles/ng-nest-ui-drawer.umd.js +27 -22
  62. package/bundles/ng-nest-ui-drawer.umd.js.map +1 -1
  63. package/bundles/ng-nest-ui-dropdown.umd.js +32 -27
  64. package/bundles/ng-nest-ui-dropdown.umd.js.map +1 -1
  65. package/bundles/ng-nest-ui-empty.umd.js +25 -21
  66. package/bundles/ng-nest-ui-empty.umd.js.map +1 -1
  67. package/bundles/ng-nest-ui-examples.umd.js +12 -14
  68. package/bundles/ng-nest-ui-examples.umd.js.map +1 -1
  69. package/bundles/ng-nest-ui-find.umd.js +45 -27
  70. package/bundles/ng-nest-ui-find.umd.js.map +1 -1
  71. package/bundles/ng-nest-ui-form.umd.js +36 -36
  72. package/bundles/ng-nest-ui-form.umd.js.map +1 -1
  73. package/bundles/ng-nest-ui-highlight.umd.js +27 -22
  74. package/bundles/ng-nest-ui-highlight.umd.js.map +1 -1
  75. package/bundles/ng-nest-ui-i18n.umd.js +545 -140
  76. package/bundles/ng-nest-ui-i18n.umd.js.map +1 -1
  77. package/bundles/ng-nest-ui-icon.umd.js +34 -29
  78. package/bundles/ng-nest-ui-icon.umd.js.map +1 -1
  79. package/bundles/ng-nest-ui-inner.umd.js +26 -22
  80. package/bundles/ng-nest-ui-inner.umd.js.map +1 -1
  81. package/bundles/ng-nest-ui-input-number.umd.js +44 -24
  82. package/bundles/ng-nest-ui-input-number.umd.js.map +1 -1
  83. package/bundles/ng-nest-ui-input.umd.js +208 -50
  84. package/bundles/ng-nest-ui-input.umd.js.map +1 -1
  85. package/bundles/ng-nest-ui-layout.umd.js +31 -27
  86. package/bundles/ng-nest-ui-layout.umd.js.map +1 -1
  87. package/bundles/ng-nest-ui-link.umd.js +25 -21
  88. package/bundles/ng-nest-ui-link.umd.js.map +1 -1
  89. package/bundles/ng-nest-ui-list.umd.js +35 -30
  90. package/bundles/ng-nest-ui-list.umd.js.map +1 -1
  91. package/bundles/ng-nest-ui-loading.umd.js +27 -22
  92. package/bundles/ng-nest-ui-loading.umd.js.map +1 -1
  93. package/bundles/ng-nest-ui-menu.umd.js +38 -31
  94. package/bundles/ng-nest-ui-menu.umd.js.map +1 -1
  95. package/bundles/ng-nest-ui-message-box.umd.js +53 -47
  96. package/bundles/ng-nest-ui-message-box.umd.js.map +1 -1
  97. package/bundles/ng-nest-ui-message.umd.js +26 -22
  98. package/bundles/ng-nest-ui-message.umd.js.map +1 -1
  99. package/bundles/ng-nest-ui-notification.umd.js +26 -22
  100. package/bundles/ng-nest-ui-notification.umd.js.map +1 -1
  101. package/bundles/ng-nest-ui-outlet.umd.js +22 -18
  102. package/bundles/ng-nest-ui-outlet.umd.js.map +1 -1
  103. package/bundles/ng-nest-ui-page-header.umd.js +25 -21
  104. package/bundles/ng-nest-ui-page-header.umd.js.map +1 -1
  105. package/bundles/ng-nest-ui-pagination.umd.js +115 -26
  106. package/bundles/ng-nest-ui-pagination.umd.js.map +1 -1
  107. package/bundles/ng-nest-ui-pattern.umd.js +12 -14
  108. package/bundles/ng-nest-ui-pattern.umd.js.map +1 -1
  109. package/bundles/ng-nest-ui-popconfirm.umd.js +25 -21
  110. package/bundles/ng-nest-ui-popconfirm.umd.js.map +1 -1
  111. package/bundles/ng-nest-ui-popover.umd.js +31 -26
  112. package/bundles/ng-nest-ui-popover.umd.js.map +1 -1
  113. package/bundles/ng-nest-ui-portal.umd.js +22 -18
  114. package/bundles/ng-nest-ui-portal.umd.js.map +1 -1
  115. package/bundles/ng-nest-ui-progress.umd.js +28 -23
  116. package/bundles/ng-nest-ui-progress.umd.js.map +1 -1
  117. package/bundles/ng-nest-ui-radio.umd.js +28 -23
  118. package/bundles/ng-nest-ui-radio.umd.js.map +1 -1
  119. package/bundles/ng-nest-ui-rate.umd.js +30 -26
  120. package/bundles/ng-nest-ui-rate.umd.js.map +1 -1
  121. package/bundles/ng-nest-ui-result.umd.js +25 -21
  122. package/bundles/ng-nest-ui-result.umd.js.map +1 -1
  123. package/bundles/ng-nest-ui-ripple.umd.js +25 -21
  124. package/bundles/ng-nest-ui-ripple.umd.js.map +1 -1
  125. package/bundles/ng-nest-ui-select.umd.js +53 -34
  126. package/bundles/ng-nest-ui-select.umd.js.map +1 -1
  127. package/bundles/ng-nest-ui-skeleton.umd.js +27 -22
  128. package/bundles/ng-nest-ui-skeleton.umd.js.map +1 -1
  129. package/bundles/ng-nest-ui-slider-select.umd.js +25 -21
  130. package/bundles/ng-nest-ui-slider-select.umd.js.map +1 -1
  131. package/bundles/ng-nest-ui-slider.umd.js +32 -29
  132. package/bundles/ng-nest-ui-slider.umd.js.map +1 -1
  133. package/bundles/ng-nest-ui-statistic.umd.js +37 -31
  134. package/bundles/ng-nest-ui-statistic.umd.js.map +1 -1
  135. package/bundles/ng-nest-ui-steps.umd.js +35 -27
  136. package/bundles/ng-nest-ui-steps.umd.js.map +1 -1
  137. package/bundles/ng-nest-ui-switch.umd.js +25 -21
  138. package/bundles/ng-nest-ui-switch.umd.js.map +1 -1
  139. package/bundles/ng-nest-ui-table.umd.js +58 -51
  140. package/bundles/ng-nest-ui-table.umd.js.map +1 -1
  141. package/bundles/ng-nest-ui-tabs.umd.js +39 -34
  142. package/bundles/ng-nest-ui-tabs.umd.js.map +1 -1
  143. package/bundles/ng-nest-ui-tag.umd.js +36 -21
  144. package/bundles/ng-nest-ui-tag.umd.js.map +1 -1
  145. package/bundles/ng-nest-ui-text-retract.umd.js +27 -22
  146. package/bundles/ng-nest-ui-text-retract.umd.js.map +1 -1
  147. package/bundles/ng-nest-ui-textarea.umd.js +27 -32
  148. package/bundles/ng-nest-ui-textarea.umd.js.map +1 -1
  149. package/bundles/ng-nest-ui-theme.umd.js +26 -22
  150. package/bundles/ng-nest-ui-theme.umd.js.map +1 -1
  151. package/bundles/ng-nest-ui-time-ago.umd.js +12 -14
  152. package/bundles/ng-nest-ui-time-ago.umd.js.map +1 -1
  153. package/bundles/ng-nest-ui-time-picker.umd.js +87 -46
  154. package/bundles/ng-nest-ui-time-picker.umd.js.map +1 -1
  155. package/bundles/ng-nest-ui-time-range.umd.js +22 -18
  156. package/bundles/ng-nest-ui-time-range.umd.js.map +1 -1
  157. package/bundles/ng-nest-ui-timeline.umd.js +28 -23
  158. package/bundles/ng-nest-ui-timeline.umd.js.map +1 -1
  159. package/bundles/ng-nest-ui-tooltip.umd.js +31 -26
  160. package/bundles/ng-nest-ui-tooltip.umd.js.map +1 -1
  161. package/bundles/ng-nest-ui-transfer.umd.js +28 -23
  162. package/bundles/ng-nest-ui-transfer.umd.js.map +1 -1
  163. package/bundles/ng-nest-ui-tree-file.umd.js +25 -21
  164. package/bundles/ng-nest-ui-tree-file.umd.js.map +1 -1
  165. package/bundles/ng-nest-ui-tree.umd.js +39 -34
  166. package/bundles/ng-nest-ui-tree.umd.js.map +1 -1
  167. package/bundles/ng-nest-ui-typography.umd.js +25 -21
  168. package/bundles/ng-nest-ui-typography.umd.js.map +1 -1
  169. package/bundles/ng-nest-ui-upload.umd.js +32 -27
  170. package/bundles/ng-nest-ui-upload.umd.js.map +1 -1
  171. package/bundles/ng-nest-ui.umd.js +83 -243
  172. package/bundles/ng-nest-ui.umd.js.map +1 -1
  173. package/button/buttons.component.d.ts +1 -1
  174. package/calendar/calendar.component.d.ts +2 -2
  175. package/carousel/carousel.component.d.ts +1 -1
  176. package/cascade/cascade-portal.component.d.ts +13 -7
  177. package/cascade/cascade.component.d.ts +7 -1
  178. package/cascade/cascade.property.d.ts +33 -3
  179. package/checkbox/checkbox.component.d.ts +1 -1
  180. package/color/color.component.d.ts +2 -2
  181. package/color-picker/color-picker-portal.component.d.ts +3 -3
  182. package/color-picker/color-picker.component.d.ts +10 -4
  183. package/color-picker/color-picker.property.d.ts +12 -2
  184. package/comment/comment.component.d.ts +1 -1
  185. package/core/config/config.d.ts +39 -0
  186. package/core/functions/clone-deep.d.ts +1 -0
  187. package/core/functions/drop.d.ts +1 -0
  188. package/core/functions/flex.d.ts +1 -1
  189. package/core/functions/has-in.d.ts +1 -0
  190. package/core/functions/order-by.d.ts +1 -0
  191. package/core/functions/public-api.d.ts +5 -0
  192. package/core/functions/remove.d.ts +1 -0
  193. package/core/services/reuse-strategy.service.d.ts +1 -1
  194. package/crumb/crumb.component.d.ts +1 -1
  195. package/date-picker/date-picker-portal.component.d.ts +10 -12
  196. package/date-picker/date-picker.component.d.ts +5 -5
  197. package/date-picker/date-picker.module.d.ts +12 -10
  198. package/date-picker/date-picker.property.d.ts +169 -8
  199. package/date-picker/date-range-portal.component.d.ts +65 -0
  200. package/date-picker/date-range.component.d.ts +74 -0
  201. package/date-picker/picker-date.component.d.ts +13 -4
  202. package/date-picker/picker-month.component.d.ts +6 -3
  203. package/date-picker/picker-year.component.d.ts +4 -2
  204. package/date-picker/public-api.d.ts +2 -0
  205. package/description/description.component.d.ts +2 -4
  206. package/dropdown/dropdown-portal.component.d.ts +1 -3
  207. package/dropdown/dropdown.component.d.ts +2 -2
  208. package/esm2015/affix/affix.component.js +3 -3
  209. package/esm2015/affix/affix.module.js +4 -4
  210. package/esm2015/affix/affix.property.js +3 -3
  211. package/esm2015/alert/alert.component.js +4 -4
  212. package/esm2015/alert/alert.module.js +4 -4
  213. package/esm2015/alert/alert.property.js +3 -3
  214. package/esm2015/anchor/anchor.component.js +5 -5
  215. package/esm2015/anchor/anchor.module.js +4 -4
  216. package/esm2015/anchor/anchor.property.js +4 -4
  217. package/esm2015/api/api.component.js +3 -3
  218. package/esm2015/api/api.module.js +4 -4
  219. package/esm2015/auto-complete/auto-complete-portal.component.js +6 -6
  220. package/esm2015/auto-complete/auto-complete.component.js +29 -12
  221. package/esm2015/auto-complete/auto-complete.module.js +4 -4
  222. package/esm2015/auto-complete/auto-complete.property.js +22 -5
  223. package/esm2015/avatar/avatar.component.js +3 -3
  224. package/esm2015/avatar/avatar.module.js +4 -4
  225. package/esm2015/avatar/avatar.property.js +3 -3
  226. package/esm2015/back-top/back-top.component.js +6 -6
  227. package/esm2015/back-top/back-top.module.js +4 -4
  228. package/esm2015/back-top/back-top.property.js +3 -3
  229. package/esm2015/badge/badge.component.js +6 -5
  230. package/esm2015/badge/badge.module.js +4 -4
  231. package/esm2015/badge/badge.property.js +3 -3
  232. package/esm2015/base-form/base-form.component.js +5 -5
  233. package/esm2015/base-form/base-form.module.js +4 -4
  234. package/esm2015/base-form/base-form.property.js +46 -5
  235. package/esm2015/border/border.component.js +3 -3
  236. package/esm2015/border/border.module.js +4 -4
  237. package/esm2015/button/button.component.js +10 -7
  238. package/esm2015/button/button.module.js +4 -4
  239. package/esm2015/button/button.property.js +6 -6
  240. package/esm2015/button/buttons.component.js +4 -4
  241. package/esm2015/calendar/calendar.component.js +8 -7
  242. package/esm2015/calendar/calendar.module.js +4 -4
  243. package/esm2015/calendar/calendar.property.js +3 -3
  244. package/esm2015/card/card.component.js +3 -3
  245. package/esm2015/card/card.module.js +4 -4
  246. package/esm2015/card/card.property.js +3 -3
  247. package/esm2015/carousel/carousel-panel.component.js +4 -4
  248. package/esm2015/carousel/carousel.component.js +8 -7
  249. package/esm2015/carousel/carousel.module.js +4 -4
  250. package/esm2015/carousel/carousel.property.js +6 -6
  251. package/esm2015/cascade/cascade-portal.component.js +23 -11
  252. package/esm2015/cascade/cascade.component.js +25 -9
  253. package/esm2015/cascade/cascade.module.js +4 -4
  254. package/esm2015/cascade/cascade.property.js +28 -5
  255. package/esm2015/checkbox/checkbox.component.js +7 -6
  256. package/esm2015/checkbox/checkbox.module.js +4 -4
  257. package/esm2015/checkbox/checkbox.property.js +4 -4
  258. package/esm2015/collapse/collapse-panel.component.js +4 -4
  259. package/esm2015/collapse/collapse.component.js +3 -3
  260. package/esm2015/collapse/collapse.module.js +4 -4
  261. package/esm2015/collapse/collapse.property.js +6 -6
  262. package/esm2015/color/color.component.js +5 -5
  263. package/esm2015/color/color.module.js +4 -4
  264. package/esm2015/color/color.property.js +3 -3
  265. package/esm2015/color-picker/color-picker-portal.component.js +5 -5
  266. package/esm2015/color-picker/color-picker.component.js +33 -14
  267. package/esm2015/color-picker/color-picker.module.js +4 -4
  268. package/esm2015/color-picker/color-picker.property.js +16 -5
  269. package/esm2015/comment/comment-reply.component.js +3 -3
  270. package/esm2015/comment/comment.component.js +7 -6
  271. package/esm2015/comment/comment.module.js +4 -4
  272. package/esm2015/comment/comment.property.js +6 -6
  273. package/esm2015/container/aside.component.js +3 -3
  274. package/esm2015/container/container.component.js +5 -5
  275. package/esm2015/container/container.module.js +4 -4
  276. package/esm2015/container/container.property.js +12 -12
  277. package/esm2015/container/footer.component.js +3 -3
  278. package/esm2015/container/header.component.js +3 -3
  279. package/esm2015/container/main.component.js +3 -3
  280. package/esm2015/core/animation/fade.js +1 -1
  281. package/esm2015/core/config/config.js +1 -1
  282. package/esm2015/core/config/config.service.js +3 -3
  283. package/esm2015/core/functions/clone-deep.js +12 -0
  284. package/esm2015/core/functions/drop.js +8 -0
  285. package/esm2015/core/functions/flex.js +18 -7
  286. package/esm2015/core/functions/has-in.js +4 -0
  287. package/esm2015/core/functions/order-by.js +31 -0
  288. package/esm2015/core/functions/public-api.js +6 -1
  289. package/esm2015/core/functions/remove.js +15 -0
  290. package/esm2015/core/services/http.service.js +5 -5
  291. package/esm2015/core/services/preloading-strategy.service.js +5 -5
  292. package/esm2015/core/services/reuse-strategy.service.js +2 -2
  293. package/esm2015/core/services/storage.service.js +3 -3
  294. package/esm2015/core/theme/theme.service.js +3 -3
  295. package/esm2015/crumb/crumb.component.js +7 -6
  296. package/esm2015/crumb/crumb.module.js +4 -4
  297. package/esm2015/crumb/crumb.property.js +3 -3
  298. package/esm2015/date-picker/date-picker-portal.component.js +24 -43
  299. package/esm2015/date-picker/date-picker.component.js +24 -23
  300. package/esm2015/date-picker/date-picker.module.js +31 -11
  301. package/esm2015/date-picker/date-picker.property.js +190 -19
  302. package/esm2015/date-picker/date-range-portal.component.js +208 -0
  303. package/esm2015/date-picker/date-range.component.js +307 -0
  304. package/esm2015/date-picker/picker-date.component.js +50 -15
  305. package/esm2015/date-picker/picker-month.component.js +25 -9
  306. package/esm2015/date-picker/picker-year.component.js +21 -9
  307. package/esm2015/date-picker/public-api.js +3 -1
  308. package/esm2015/description/description-item.component.js +4 -4
  309. package/esm2015/description/description.component.js +8 -9
  310. package/esm2015/description/description.module.js +4 -4
  311. package/esm2015/description/description.property.js +6 -6
  312. package/esm2015/dialog/dialog.component.js +6 -5
  313. package/esm2015/dialog/dialog.module.js +4 -4
  314. package/esm2015/dialog/dialog.property.js +4 -4
  315. package/esm2015/doc/doc.component.js +3 -3
  316. package/esm2015/doc/doc.module.js +4 -4
  317. package/esm2015/drawer/drawer.component.js +6 -5
  318. package/esm2015/drawer/drawer.module.js +4 -4
  319. package/esm2015/drawer/drawer.property.js +3 -3
  320. package/esm2015/dropdown/dropdown-portal.component.js +5 -5
  321. package/esm2015/dropdown/dropdown.component.js +7 -6
  322. package/esm2015/dropdown/dropdown.module.js +4 -4
  323. package/esm2015/dropdown/dropdown.property.js +3 -3
  324. package/esm2015/empty/empty.component.js +3 -3
  325. package/esm2015/empty/empty.module.js +4 -4
  326. package/esm2015/empty/empty.property.js +3 -3
  327. package/esm2015/examples/examples.component.js +3 -3
  328. package/esm2015/examples/examples.module.js +4 -4
  329. package/esm2015/find/find.component.js +13 -10
  330. package/esm2015/find/find.module.js +4 -4
  331. package/esm2015/find/find.property.js +16 -5
  332. package/esm2015/form/control.component.js +4 -4
  333. package/esm2015/form/form.component.js +9 -8
  334. package/esm2015/form/form.module.js +4 -4
  335. package/esm2015/form/form.property.js +8 -13
  336. package/esm2015/highlight/highlight.component.js +6 -5
  337. package/esm2015/highlight/highlight.module.js +4 -4
  338. package/esm2015/highlight/highlight.property.js +4 -4
  339. package/esm2015/i18n/i18n.directive.js +6 -5
  340. package/esm2015/i18n/i18n.module.js +4 -4
  341. package/esm2015/i18n/i18n.pipe.js +3 -3
  342. package/esm2015/i18n/i18n.property.js +1 -1
  343. package/esm2015/i18n/i18n.service.js +3 -3
  344. package/esm2015/i18n/languages/ar_EG.js +11 -3
  345. package/esm2015/i18n/languages/bg_BG.js +11 -3
  346. package/esm2015/i18n/languages/ca_ES.js +11 -3
  347. package/esm2015/i18n/languages/cs_CZ.js +11 -3
  348. package/esm2015/i18n/languages/da_DK.js +11 -3
  349. package/esm2015/i18n/languages/de_DE.js +11 -3
  350. package/esm2015/i18n/languages/el_GR.js +11 -3
  351. package/esm2015/i18n/languages/en_GB.js +11 -3
  352. package/esm2015/i18n/languages/en_US.js +11 -3
  353. package/esm2015/i18n/languages/es_ES.js +11 -3
  354. package/esm2015/i18n/languages/et_EE.js +11 -3
  355. package/esm2015/i18n/languages/fa_IR.js +11 -3
  356. package/esm2015/i18n/languages/fi_FI.js +11 -3
  357. package/esm2015/i18n/languages/fr_BE.js +10 -2
  358. package/esm2015/i18n/languages/fr_FR.js +11 -3
  359. package/esm2015/i18n/languages/he_IL.js +11 -3
  360. package/esm2015/i18n/languages/hi_IN.js +11 -3
  361. package/esm2015/i18n/languages/hr_HR.js +11 -3
  362. package/esm2015/i18n/languages/hu_HU.js +11 -3
  363. package/esm2015/i18n/languages/hy_AM.js +11 -3
  364. package/esm2015/i18n/languages/id_ID.js +11 -3
  365. package/esm2015/i18n/languages/is_IS.js +11 -3
  366. package/esm2015/i18n/languages/it_IT.js +11 -3
  367. package/esm2015/i18n/languages/ja_JP.js +11 -3
  368. package/esm2015/i18n/languages/ka_GE.js +11 -3
  369. package/esm2015/i18n/languages/kn_IN.js +11 -3
  370. package/esm2015/i18n/languages/ko_KR.js +11 -3
  371. package/esm2015/i18n/languages/ku_IQ.js +11 -3
  372. package/esm2015/i18n/languages/lv_LV.js +11 -3
  373. package/esm2015/i18n/languages/mn_MN.js +11 -3
  374. package/esm2015/i18n/languages/ms_MY.js +11 -3
  375. package/esm2015/i18n/languages/nb_NO.js +11 -3
  376. package/esm2015/i18n/languages/ne_NP.js +11 -3
  377. package/esm2015/i18n/languages/nl_BE.js +11 -3
  378. package/esm2015/i18n/languages/nl_NL.js +11 -3
  379. package/esm2015/i18n/languages/pl_PL.js +11 -3
  380. package/esm2015/i18n/languages/pt_BR.js +11 -3
  381. package/esm2015/i18n/languages/pt_PT.js +11 -3
  382. package/esm2015/i18n/languages/ro_RO.js +11 -3
  383. package/esm2015/i18n/languages/ru_RU.js +11 -3
  384. package/esm2015/i18n/languages/sk_SK.js +11 -3
  385. package/esm2015/i18n/languages/sl_SI.js +11 -3
  386. package/esm2015/i18n/languages/sr_RS.js +11 -3
  387. package/esm2015/i18n/languages/sv_SE.js +11 -3
  388. package/esm2015/i18n/languages/ta_IN.js +11 -3
  389. package/esm2015/i18n/languages/th_TH.js +29 -21
  390. package/esm2015/i18n/languages/tr_TR.js +11 -3
  391. package/esm2015/i18n/languages/uk_UA.js +11 -3
  392. package/esm2015/i18n/languages/vi_VN.js +11 -3
  393. package/esm2015/i18n/languages/zh_CN.js +10 -3
  394. package/esm2015/i18n/languages/zh_TW.js +10 -3
  395. package/esm2015/icon/icon.component.js +7 -6
  396. package/esm2015/icon/icon.module.js +4 -4
  397. package/esm2015/icon/icon.property.js +3 -3
  398. package/esm2015/icon/icon.service.js +6 -6
  399. package/esm2015/inner/inner.component.js +5 -5
  400. package/esm2015/inner/inner.module.js +4 -4
  401. package/esm2015/inner/inner.property.js +3 -3
  402. package/esm2015/input/input-group.component.js +26 -0
  403. package/esm2015/input/input.component.js +60 -15
  404. package/esm2015/input/input.module.js +11 -9
  405. package/esm2015/input/input.property.js +77 -22
  406. package/esm2015/input/public-api.js +2 -1
  407. package/esm2015/input-number/input-number.component.js +9 -5
  408. package/esm2015/input-number/input-number.module.js +7 -6
  409. package/esm2015/input-number/input-number.property.js +17 -5
  410. package/esm2015/layout/col.component.js +3 -3
  411. package/esm2015/layout/layout.module.js +4 -4
  412. package/esm2015/layout/layout.property.js +6 -6
  413. package/esm2015/layout/row.component.js +3 -3
  414. package/esm2015/link/link.component.js +3 -3
  415. package/esm2015/link/link.module.js +4 -4
  416. package/esm2015/link/link.property.js +3 -3
  417. package/esm2015/list/list-option.component.js +3 -3
  418. package/esm2015/list/list.component.js +8 -7
  419. package/esm2015/list/list.module.js +4 -4
  420. package/esm2015/list/list.property.js +7 -7
  421. package/esm2015/loading/loading.component.js +6 -5
  422. package/esm2015/loading/loading.module.js +4 -4
  423. package/esm2015/loading/loading.property.js +3 -3
  424. package/esm2015/menu/menu-node.component.js +4 -4
  425. package/esm2015/menu/menu.component.js +11 -8
  426. package/esm2015/menu/menu.module.js +4 -4
  427. package/esm2015/menu/menu.property.js +6 -6
  428. package/esm2015/message/message.component.js +5 -5
  429. package/esm2015/message/message.module.js +4 -4
  430. package/esm2015/message/message.service.js +3 -3
  431. package/esm2015/message-box/message-box.component.js +20 -24
  432. package/esm2015/message-box/message-box.module.js +4 -4
  433. package/esm2015/message-box/message-box.service.js +10 -8
  434. package/esm2015/notification/notification.component.js +5 -5
  435. package/esm2015/notification/notification.module.js +4 -4
  436. package/esm2015/notification/notification.property.js +1 -1
  437. package/esm2015/notification/notification.service.js +3 -3
  438. package/esm2015/outlet/outlet.directive.js +3 -3
  439. package/esm2015/outlet/outlet.module.js +4 -4
  440. package/esm2015/page-header/page-header.component.js +3 -3
  441. package/esm2015/page-header/page-header.module.js +4 -4
  442. package/esm2015/page-header/page-header.property.js +3 -3
  443. package/esm2015/pagination/pagination.component.js +45 -7
  444. package/esm2015/pagination/pagination.module.js +10 -6
  445. package/esm2015/pagination/pagination.property.js +52 -4
  446. package/esm2015/pattern/pattern.component.js +3 -3
  447. package/esm2015/pattern/pattern.module.js +4 -4
  448. package/esm2015/popconfirm/popconfirm.component.js +3 -3
  449. package/esm2015/popconfirm/popconfirm.module.js +4 -4
  450. package/esm2015/popconfirm/popconfirm.property.js +3 -3
  451. package/esm2015/popover/popover-portal.component.js +4 -4
  452. package/esm2015/popover/popover.directive.js +7 -6
  453. package/esm2015/popover/popover.module.js +4 -4
  454. package/esm2015/popover/popover.property.js +3 -3
  455. package/esm2015/portal/portal.module.js +4 -4
  456. package/esm2015/portal/portal.service.js +3 -3
  457. package/esm2015/progress/progress.component.js +7 -6
  458. package/esm2015/progress/progress.module.js +4 -4
  459. package/esm2015/progress/progress.property.js +3 -3
  460. package/esm2015/radio/radio.component.js +7 -6
  461. package/esm2015/radio/radio.module.js +4 -4
  462. package/esm2015/radio/radio.property.js +4 -4
  463. package/esm2015/rate/rate.component.js +9 -9
  464. package/esm2015/rate/rate.module.js +4 -4
  465. package/esm2015/rate/rate.property.js +3 -3
  466. package/esm2015/result/result.component.js +3 -3
  467. package/esm2015/result/result.module.js +4 -4
  468. package/esm2015/result/result.property.js +3 -3
  469. package/esm2015/ripple/ripple.directive.js +4 -4
  470. package/esm2015/ripple/ripple.module.js +4 -4
  471. package/esm2015/ripple/ripple.property.js +4 -4
  472. package/esm2015/select/select-portal.component.js +6 -6
  473. package/esm2015/select/select.component.js +15 -11
  474. package/esm2015/select/select.module.js +4 -4
  475. package/esm2015/select/select.property.js +15 -4
  476. package/esm2015/skeleton/skeleton.component.js +6 -5
  477. package/esm2015/skeleton/skeleton.module.js +4 -4
  478. package/esm2015/skeleton/skeleton.property.js +3 -3
  479. package/esm2015/slider/slider.component.js +11 -12
  480. package/esm2015/slider/slider.module.js +4 -4
  481. package/esm2015/slider/slider.property.js +3 -3
  482. package/esm2015/slider-select/slider-select.component.js +3 -3
  483. package/esm2015/slider-select/slider-select.module.js +4 -4
  484. package/esm2015/slider-select/slider-select.property.js +3 -3
  485. package/esm2015/statistic/countdown.component.js +8 -7
  486. package/esm2015/statistic/statistic.component.js +6 -5
  487. package/esm2015/statistic/statistic.module.js +4 -4
  488. package/esm2015/statistic/statistic.property.js +6 -6
  489. package/esm2015/steps/steps.component.js +9 -7
  490. package/esm2015/steps/steps.module.js +7 -6
  491. package/esm2015/steps/steps.property.js +6 -4
  492. package/esm2015/switch/switch.component.js +3 -3
  493. package/esm2015/switch/switch.module.js +4 -4
  494. package/esm2015/switch/switch.property.js +3 -3
  495. package/esm2015/table/drag.directive.js +5 -5
  496. package/esm2015/table/table-body.component.js +7 -6
  497. package/esm2015/table/table-foot.component.js +4 -4
  498. package/esm2015/table/table-head.component.js +7 -6
  499. package/esm2015/table/table.component.js +9 -8
  500. package/esm2015/table/table.module.js +4 -4
  501. package/esm2015/table/table.property.js +13 -13
  502. package/esm2015/tabs/tab-content.component.js +3 -3
  503. package/esm2015/tabs/tab.component.js +4 -4
  504. package/esm2015/tabs/tabs.component.js +9 -8
  505. package/esm2015/tabs/tabs.module.js +4 -4
  506. package/esm2015/tabs/tabs.property.js +6 -6
  507. package/esm2015/tag/tag.component.js +10 -5
  508. package/esm2015/tag/tag.module.js +4 -4
  509. package/esm2015/tag/tag.property.js +10 -4
  510. package/esm2015/text-retract/text-retract.component.js +6 -5
  511. package/esm2015/text-retract/text-retract.module.js +4 -4
  512. package/esm2015/text-retract/text-retract.property.js +3 -3
  513. package/esm2015/textarea/textarea.component.js +6 -5
  514. package/esm2015/textarea/textarea.module.js +4 -4
  515. package/esm2015/textarea/textarea.property.js +4 -14
  516. package/esm2015/theme/theme.component.js +5 -5
  517. package/esm2015/theme/theme.module.js +4 -4
  518. package/esm2015/theme/theme.property.js +4 -4
  519. package/esm2015/time-ago/time-ago.module.js +4 -4
  520. package/esm2015/time-ago/time-ago.pipe.js +3 -3
  521. package/esm2015/time-picker/time-picker-frame.component.js +22 -12
  522. package/esm2015/time-picker/time-picker-portal.component.js +5 -5
  523. package/esm2015/time-picker/time-picker.component.js +31 -15
  524. package/esm2015/time-picker/time-picker.module.js +4 -4
  525. package/esm2015/time-picker/time-picker.property.js +16 -5
  526. package/esm2015/time-range/time-range.module.js +4 -4
  527. package/esm2015/time-range/time-range.pipe.js +3 -3
  528. package/esm2015/timeline/timeline.component.js +7 -6
  529. package/esm2015/timeline/timeline.module.js +4 -4
  530. package/esm2015/timeline/timeline.property.js +3 -3
  531. package/esm2015/tooltip/tooltip-portal.component.js +4 -4
  532. package/esm2015/tooltip/tooltip.directive.js +7 -6
  533. package/esm2015/tooltip/tooltip.module.js +4 -4
  534. package/esm2015/tooltip/tooltip.property.js +4 -4
  535. package/esm2015/transfer/transfer.component.js +7 -6
  536. package/esm2015/transfer/transfer.module.js +4 -4
  537. package/esm2015/transfer/transfer.property.js +3 -3
  538. package/esm2015/tree/tree-node.component.js +5 -5
  539. package/esm2015/tree/tree.component.js +11 -10
  540. package/esm2015/tree/tree.module.js +4 -4
  541. package/esm2015/tree/tree.property.js +7 -7
  542. package/esm2015/tree-file/tree-file.component.js +3 -3
  543. package/esm2015/tree-file/tree-file.module.js +4 -4
  544. package/esm2015/tree-file/tree-file.property.js +3 -3
  545. package/esm2015/typography/typography.component.js +3 -3
  546. package/esm2015/typography/typography.module.js +4 -4
  547. package/esm2015/typography/typography.property.js +3 -3
  548. package/esm2015/upload/upload-portal.component.js +5 -5
  549. package/esm2015/upload/upload.component.js +7 -6
  550. package/esm2015/upload/upload.module.js +4 -4
  551. package/esm2015/upload/upload.property.js +3 -3
  552. package/fesm2015/ng-nest-ui-affix.js +10 -10
  553. package/fesm2015/ng-nest-ui-alert.js +10 -10
  554. package/fesm2015/ng-nest-ui-alert.js.map +1 -1
  555. package/fesm2015/ng-nest-ui-anchor.js +11 -11
  556. package/fesm2015/ng-nest-ui-anchor.js.map +1 -1
  557. package/fesm2015/ng-nest-ui-api.js +7 -7
  558. package/fesm2015/ng-nest-ui-auto-complete.js +59 -25
  559. package/fesm2015/ng-nest-ui-auto-complete.js.map +1 -1
  560. package/fesm2015/ng-nest-ui-avatar.js +10 -10
  561. package/fesm2015/ng-nest-ui-back-top.js +12 -12
  562. package/fesm2015/ng-nest-ui-back-top.js.map +1 -1
  563. package/fesm2015/ng-nest-ui-badge.js +12 -11
  564. package/fesm2015/ng-nest-ui-badge.js.map +1 -1
  565. package/fesm2015/ng-nest-ui-base-form.js +53 -12
  566. package/fesm2015/ng-nest-ui-base-form.js.map +1 -1
  567. package/fesm2015/ng-nest-ui-border.js +7 -7
  568. package/fesm2015/ng-nest-ui-button.js +22 -19
  569. package/fesm2015/ng-nest-ui-button.js.map +1 -1
  570. package/fesm2015/ng-nest-ui-calendar.js +14 -13
  571. package/fesm2015/ng-nest-ui-calendar.js.map +1 -1
  572. package/fesm2015/ng-nest-ui-card.js +10 -10
  573. package/fesm2015/ng-nest-ui-carousel.js +20 -19
  574. package/fesm2015/ng-nest-ui-carousel.js.map +1 -1
  575. package/fesm2015/ng-nest-ui-cascade.js +80 -28
  576. package/fesm2015/ng-nest-ui-cascade.js.map +1 -1
  577. package/fesm2015/ng-nest-ui-checkbox.js +13 -12
  578. package/fesm2015/ng-nest-ui-checkbox.js.map +1 -1
  579. package/fesm2015/ng-nest-ui-collapse.js +16 -16
  580. package/fesm2015/ng-nest-ui-collapse.js.map +1 -1
  581. package/fesm2015/ng-nest-ui-color-picker.js +55 -24
  582. package/fesm2015/ng-nest-ui-color-picker.js.map +1 -1
  583. package/fesm2015/ng-nest-ui-color.js +11 -11
  584. package/fesm2015/ng-nest-ui-color.js.map +1 -1
  585. package/fesm2015/ng-nest-ui-comment.js +19 -18
  586. package/fesm2015/ng-nest-ui-comment.js.map +1 -1
  587. package/fesm2015/ng-nest-ui-container.js +32 -32
  588. package/fesm2015/ng-nest-ui-container.js.map +1 -1
  589. package/fesm2015/ng-nest-ui-core.js +106 -25
  590. package/fesm2015/ng-nest-ui-core.js.map +1 -1
  591. package/fesm2015/ng-nest-ui-crumb.js +13 -12
  592. package/fesm2015/ng-nest-ui-crumb.js.map +1 -1
  593. package/fesm2015/ng-nest-ui-date-picker.js +876 -156
  594. package/fesm2015/ng-nest-ui-date-picker.js.map +1 -1
  595. package/fesm2015/ng-nest-ui-description.js +21 -22
  596. package/fesm2015/ng-nest-ui-description.js.map +1 -1
  597. package/fesm2015/ng-nest-ui-dialog.js +12 -11
  598. package/fesm2015/ng-nest-ui-dialog.js.map +1 -1
  599. package/fesm2015/ng-nest-ui-doc.js +7 -7
  600. package/fesm2015/ng-nest-ui-drawer.js +12 -11
  601. package/fesm2015/ng-nest-ui-drawer.js.map +1 -1
  602. package/fesm2015/ng-nest-ui-dropdown.js +17 -16
  603. package/fesm2015/ng-nest-ui-dropdown.js.map +1 -1
  604. package/fesm2015/ng-nest-ui-empty.js +10 -10
  605. package/fesm2015/ng-nest-ui-examples.js +7 -7
  606. package/fesm2015/ng-nest-ui-find.js +31 -17
  607. package/fesm2015/ng-nest-ui-find.js.map +1 -1
  608. package/fesm2015/ng-nest-ui-form.js +22 -26
  609. package/fesm2015/ng-nest-ui-form.js.map +1 -1
  610. package/fesm2015/ng-nest-ui-highlight.js +12 -11
  611. package/fesm2015/ng-nest-ui-highlight.js.map +1 -1
  612. package/fesm2015/ng-nest-ui-i18n.js +540 -133
  613. package/fesm2015/ng-nest-ui-i18n.js.map +1 -1
  614. package/fesm2015/ng-nest-ui-icon.js +18 -18
  615. package/fesm2015/ng-nest-ui-icon.js.map +1 -1
  616. package/fesm2015/ng-nest-ui-inner.js +11 -11
  617. package/fesm2015/ng-nest-ui-inner.js.map +1 -1
  618. package/fesm2015/ng-nest-ui-input-number.js +31 -14
  619. package/fesm2015/ng-nest-ui-input-number.js.map +1 -1
  620. package/fesm2015/ng-nest-ui-input.js +164 -42
  621. package/fesm2015/ng-nest-ui-input.js.map +1 -1
  622. package/fesm2015/ng-nest-ui-layout.js +16 -16
  623. package/fesm2015/ng-nest-ui-link.js +10 -10
  624. package/fesm2015/ng-nest-ui-list.js +20 -19
  625. package/fesm2015/ng-nest-ui-list.js.map +1 -1
  626. package/fesm2015/ng-nest-ui-loading.js +12 -11
  627. package/fesm2015/ng-nest-ui-loading.js.map +1 -1
  628. package/fesm2015/ng-nest-ui-menu.js +23 -20
  629. package/fesm2015/ng-nest-ui-menu.js.map +1 -1
  630. package/fesm2015/ng-nest-ui-message-box.js +32 -34
  631. package/fesm2015/ng-nest-ui-message-box.js.map +1 -1
  632. package/fesm2015/ng-nest-ui-message.js +11 -11
  633. package/fesm2015/ng-nest-ui-message.js.map +1 -1
  634. package/fesm2015/ng-nest-ui-notification.js +11 -11
  635. package/fesm2015/ng-nest-ui-notification.js.map +1 -1
  636. package/fesm2015/ng-nest-ui-outlet.js +7 -7
  637. package/fesm2015/ng-nest-ui-page-header.js +10 -10
  638. package/fesm2015/ng-nest-ui-pagination.js +104 -14
  639. package/fesm2015/ng-nest-ui-pagination.js.map +1 -1
  640. package/fesm2015/ng-nest-ui-pattern.js +7 -7
  641. package/fesm2015/ng-nest-ui-popconfirm.js +10 -10
  642. package/fesm2015/ng-nest-ui-popover.js +16 -15
  643. package/fesm2015/ng-nest-ui-popover.js.map +1 -1
  644. package/fesm2015/ng-nest-ui-portal.js +7 -7
  645. package/fesm2015/ng-nest-ui-progress.js +13 -12
  646. package/fesm2015/ng-nest-ui-progress.js.map +1 -1
  647. package/fesm2015/ng-nest-ui-radio.js +13 -12
  648. package/fesm2015/ng-nest-ui-radio.js.map +1 -1
  649. package/fesm2015/ng-nest-ui-rate.js +15 -15
  650. package/fesm2015/ng-nest-ui-rate.js.map +1 -1
  651. package/fesm2015/ng-nest-ui-result.js +10 -10
  652. package/fesm2015/ng-nest-ui-ripple.js +10 -10
  653. package/fesm2015/ng-nest-ui-ripple.js.map +1 -1
  654. package/fesm2015/ng-nest-ui-select.js +37 -22
  655. package/fesm2015/ng-nest-ui-select.js.map +1 -1
  656. package/fesm2015/ng-nest-ui-skeleton.js +12 -11
  657. package/fesm2015/ng-nest-ui-skeleton.js.map +1 -1
  658. package/fesm2015/ng-nest-ui-slider-select.js +10 -10
  659. package/fesm2015/ng-nest-ui-slider.js +17 -18
  660. package/fesm2015/ng-nest-ui-slider.js.map +1 -1
  661. package/fesm2015/ng-nest-ui-statistic.js +22 -20
  662. package/fesm2015/ng-nest-ui-statistic.js.map +1 -1
  663. package/fesm2015/ng-nest-ui-steps.js +19 -14
  664. package/fesm2015/ng-nest-ui-steps.js.map +1 -1
  665. package/fesm2015/ng-nest-ui-switch.js +10 -10
  666. package/fesm2015/ng-nest-ui-table.js +43 -40
  667. package/fesm2015/ng-nest-ui-table.js.map +1 -1
  668. package/fesm2015/ng-nest-ui-tabs.js +24 -23
  669. package/fesm2015/ng-nest-ui-tabs.js.map +1 -1
  670. package/fesm2015/ng-nest-ui-tag.js +22 -11
  671. package/fesm2015/ng-nest-ui-tag.js.map +1 -1
  672. package/fesm2015/ng-nest-ui-text-retract.js +12 -11
  673. package/fesm2015/ng-nest-ui-text-retract.js.map +1 -1
  674. package/fesm2015/ng-nest-ui-textarea.js +12 -21
  675. package/fesm2015/ng-nest-ui-textarea.js.map +1 -1
  676. package/fesm2015/ng-nest-ui-theme.js +11 -11
  677. package/fesm2015/ng-nest-ui-theme.js.map +1 -1
  678. package/fesm2015/ng-nest-ui-time-ago.js +7 -7
  679. package/fesm2015/ng-nest-ui-time-picker.js +73 -36
  680. package/fesm2015/ng-nest-ui-time-picker.js.map +1 -1
  681. package/fesm2015/ng-nest-ui-time-range.js +7 -7
  682. package/fesm2015/ng-nest-ui-timeline.js +13 -12
  683. package/fesm2015/ng-nest-ui-timeline.js.map +1 -1
  684. package/fesm2015/ng-nest-ui-tooltip.js +16 -15
  685. package/fesm2015/ng-nest-ui-tooltip.js.map +1 -1
  686. package/fesm2015/ng-nest-ui-transfer.js +13 -12
  687. package/fesm2015/ng-nest-ui-transfer.js.map +1 -1
  688. package/fesm2015/ng-nest-ui-tree-file.js +10 -10
  689. package/fesm2015/ng-nest-ui-tree.js +24 -23
  690. package/fesm2015/ng-nest-ui-tree.js.map +1 -1
  691. package/fesm2015/ng-nest-ui-typography.js +10 -10
  692. package/fesm2015/ng-nest-ui-upload.js +17 -16
  693. package/fesm2015/ng-nest-ui-upload.js.map +1 -1
  694. package/find/find.component.d.ts +1 -1
  695. package/find/find.property.d.ts +22 -2
  696. package/form/control.component.d.ts +1 -1
  697. package/form/form.component.d.ts +1 -1
  698. package/form/form.property.d.ts +6 -6
  699. package/i18n/i18n.property.d.ts +3 -0
  700. package/i18n/languages/ar_EG.d.ts +8 -0
  701. package/i18n/languages/bg_BG.d.ts +8 -0
  702. package/i18n/languages/ca_ES.d.ts +8 -0
  703. package/i18n/languages/cs_CZ.d.ts +8 -0
  704. package/i18n/languages/da_DK.d.ts +8 -0
  705. package/i18n/languages/de_DE.d.ts +8 -0
  706. package/i18n/languages/el_GR.d.ts +8 -0
  707. package/i18n/languages/en_GB.d.ts +8 -0
  708. package/i18n/languages/en_US.d.ts +8 -0
  709. package/i18n/languages/es_ES.d.ts +8 -0
  710. package/i18n/languages/et_EE.d.ts +8 -0
  711. package/i18n/languages/fa_IR.d.ts +8 -0
  712. package/i18n/languages/fi_FI.d.ts +8 -0
  713. package/i18n/languages/fr_BE.d.ts +8 -0
  714. package/i18n/languages/fr_FR.d.ts +8 -0
  715. package/i18n/languages/he_IL.d.ts +8 -0
  716. package/i18n/languages/hi_IN.d.ts +8 -0
  717. package/i18n/languages/hr_HR.d.ts +8 -0
  718. package/i18n/languages/hu_HU.d.ts +8 -0
  719. package/i18n/languages/hy_AM.d.ts +8 -0
  720. package/i18n/languages/id_ID.d.ts +8 -0
  721. package/i18n/languages/is_IS.d.ts +8 -0
  722. package/i18n/languages/it_IT.d.ts +8 -0
  723. package/i18n/languages/ja_JP.d.ts +8 -0
  724. package/i18n/languages/ka_GE.d.ts +8 -0
  725. package/i18n/languages/kn_IN.d.ts +8 -0
  726. package/i18n/languages/ko_KR.d.ts +8 -0
  727. package/i18n/languages/ku_IQ.d.ts +8 -0
  728. package/i18n/languages/lv_LV.d.ts +8 -0
  729. package/i18n/languages/mn_MN.d.ts +8 -0
  730. package/i18n/languages/ms_MY.d.ts +8 -0
  731. package/i18n/languages/nb_NO.d.ts +8 -0
  732. package/i18n/languages/ne_NP.d.ts +8 -0
  733. package/i18n/languages/nl_BE.d.ts +8 -0
  734. package/i18n/languages/nl_NL.d.ts +8 -0
  735. package/i18n/languages/pl_PL.d.ts +8 -0
  736. package/i18n/languages/pt_BR.d.ts +8 -0
  737. package/i18n/languages/pt_PT.d.ts +8 -0
  738. package/i18n/languages/ro_RO.d.ts +8 -0
  739. package/i18n/languages/ru_RU.d.ts +8 -0
  740. package/i18n/languages/sk_SK.d.ts +8 -0
  741. package/i18n/languages/sl_SI.d.ts +8 -0
  742. package/i18n/languages/sr_RS.d.ts +8 -0
  743. package/i18n/languages/sv_SE.d.ts +8 -0
  744. package/i18n/languages/ta_IN.d.ts +8 -0
  745. package/i18n/languages/th_TH.d.ts +8 -0
  746. package/i18n/languages/tr_TR.d.ts +8 -0
  747. package/i18n/languages/uk_UA.d.ts +8 -0
  748. package/i18n/languages/vi_VN.d.ts +8 -0
  749. package/i18n/languages/zh_CN.d.ts +7 -0
  750. package/i18n/languages/zh_TW.d.ts +7 -0
  751. package/inner/inner.component.d.ts +1 -1
  752. package/input/input-group.component.d.ts +13 -0
  753. package/input/input.component.d.ts +10 -3
  754. package/input/input.module.d.ts +7 -5
  755. package/input/input.property.d.ts +79 -14
  756. package/input/public-api.d.ts +1 -0
  757. package/input-number/input-number.component.d.ts +3 -0
  758. package/input-number/input-number.module.d.ts +4 -3
  759. package/input-number/input-number.property.d.ts +12 -2
  760. package/list/list.component.d.ts +2 -2
  761. package/menu/menu.component.d.ts +1 -1
  762. package/message/message.component.d.ts +1 -1
  763. package/message-box/message-box.component.d.ts +2 -1
  764. package/notification/notification.component.d.ts +1 -1
  765. package/package.json +1 -1
  766. package/pagination/pagination.component.d.ts +5 -1
  767. package/pagination/pagination.module.d.ts +7 -3
  768. package/pagination/pagination.property.d.ts +49 -3
  769. package/radio/radio.component.d.ts +1 -1
  770. package/rate/rate.component.d.ts +5 -5
  771. package/select/select-portal.component.d.ts +3 -3
  772. package/select/select.component.d.ts +1 -1
  773. package/select/select.property.d.ts +12 -2
  774. package/slider/slider.component.d.ts +1 -1
  775. package/steps/steps.component.d.ts +1 -1
  776. package/steps/steps.module.d.ts +2 -1
  777. package/steps/steps.property.d.ts +7 -2
  778. package/table/table-body.component.d.ts +1 -1
  779. package/table/table-head.component.d.ts +1 -1
  780. package/table/table.component.d.ts +1 -1
  781. package/table/table.property.d.ts +10 -0
  782. package/tag/tag.component.d.ts +2 -1
  783. package/tag/tag.property.d.ts +6 -1
  784. package/textarea/textarea.property.d.ts +1 -6
  785. package/theme/theme.component.d.ts +1 -1
  786. package/time-picker/time-picker-frame.component.d.ts +4 -0
  787. package/time-picker/time-picker-portal.component.d.ts +3 -3
  788. package/time-picker/time-picker.component.d.ts +5 -3
  789. package/time-picker/time-picker.property.d.ts +12 -2
  790. package/timeline/timeline.component.d.ts +1 -1
  791. package/transfer/transfer.component.d.ts +1 -1
  792. package/tree/tree-node.component.d.ts +1 -1
  793. package/tree/tree.component.d.ts +1 -1
  794. package/upload/upload.component.d.ts +3 -3
@@ -50,13 +50,13 @@ class XMessageComponent {
50
50
  .subscribe(() => this.onClose(item));
51
51
  }
52
52
  }
53
- trackByNode(index, item) {
53
+ trackByNode(_index, item) {
54
54
  return `${item.title}-${item.content}`;
55
55
  }
56
56
  }
57
- /** @nocollapse */ XMessageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageComponent, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
58
- /** @nocollapse */ XMessageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.3", type: XMessageComponent, selector: "x-message", ngImport: i0, template: "<div class=\"x-message\">\r\n <ng-container *ngFor=\"let item of message.list; trackBy: trackByNode\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n", styles: [".x-message{margin:0;padding:0}.x-message>x-alert{padding:.25rem 0}.x-message>x-alert>.x-alert{box-shadow:var(--x-box-shadow) var(--x-box-shadow-light-color)}.x-message-portal x-message{width:100%}"], components: [{ type: i1.XAlertComponent, selector: "x-alert" }], directives: [{ type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], animations: [XMoveAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
59
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageComponent, decorators: [{
57
+ /** @nocollapse */ XMessageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageComponent, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
58
+ /** @nocollapse */ XMessageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: XMessageComponent, selector: "x-message", ngImport: i0, template: "<div class=\"x-message\">\r\n <ng-container *ngFor=\"let item of message.list; trackBy: trackByNode\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n", styles: [".x-message{margin:0;padding:0}.x-message>x-alert{padding:.25rem 0}.x-message>x-alert>.x-alert{box-shadow:var(--x-box-shadow) var(--x-box-shadow-light-color)}.x-message-portal x-message{width:100%}\n"], components: [{ type: i1.XAlertComponent, selector: "x-alert" }], directives: [{ type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], animations: [XMoveAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
59
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageComponent, decorators: [{
60
60
  type: Component,
61
61
  args: [{
62
62
  selector: `${XMessagePrefix}`,
@@ -177,18 +177,18 @@ class XMessageService {
177
177
  (_b = (_a = this.messages[option.placement].ref) === null || _a === void 0 ? void 0 : _a.componentRef) === null || _b === void 0 ? void 0 : _b.instance.onClose(option);
178
178
  }
179
179
  }
180
- /** @nocollapse */ XMessageService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageService, deps: [{ token: i1$1.XPortalService }, { token: i2$1.XConfigService }], target: i0.ɵɵFactoryTarget.Injectable });
181
- /** @nocollapse */ XMessageService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageService });
182
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageService, decorators: [{
180
+ /** @nocollapse */ XMessageService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageService, deps: [{ token: i1$1.XPortalService }, { token: i2$1.XConfigService }], target: i0.ɵɵFactoryTarget.Injectable });
181
+ /** @nocollapse */ XMessageService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageService });
182
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageService, decorators: [{
183
183
  type: Injectable
184
184
  }], ctorParameters: function () { return [{ type: i1$1.XPortalService }, { type: i2$1.XConfigService }]; } });
185
185
 
186
186
  class XMessageModule {
187
187
  }
188
- /** @nocollapse */ XMessageModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
189
- /** @nocollapse */ XMessageModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageModule, declarations: [XMessageComponent], imports: [CommonModule, XPortalModule, XAlertModule], exports: [XMessageComponent] });
190
- /** @nocollapse */ XMessageModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageModule, providers: [XMessageService], imports: [[CommonModule, XPortalModule, XAlertModule]] });
191
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XMessageModule, decorators: [{
188
+ /** @nocollapse */ XMessageModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
189
+ /** @nocollapse */ XMessageModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageModule, declarations: [XMessageComponent], imports: [CommonModule, XPortalModule, XAlertModule], exports: [XMessageComponent] });
190
+ /** @nocollapse */ XMessageModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageModule, providers: [XMessageService], imports: [[CommonModule, XPortalModule, XAlertModule]] });
191
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XMessageModule, decorators: [{
192
192
  type: NgModule,
193
193
  args: [{
194
194
  declarations: [XMessageComponent],
@@ -1 +1 @@
1
- {"version":3,"file":"ng-nest-ui-message.js","sources":["../../../../lib/ng-nest/ui/message/message.property.ts","../../../../lib/ng-nest/ui/message/message.component.ts","../../../../lib/ng-nest/ui/message/message.component.html","../../../../lib/ng-nest/ui/message/message.service.ts","../../../../lib/ng-nest/ui/message/message.module.ts","../../../../lib/ng-nest/ui/message/ng-nest-ui-message.ts"],"sourcesContent":["import { XStatus, XPlace } from '@ng-nest/ui/core';\r\nimport { XAlertOption } from '@ng-nest/ui/alert';\r\nimport { Subscription, Subject } from 'rxjs';\r\nimport { XPortalOverlayRef } from '@ng-nest/ui/portal';\r\nimport { XMessageComponent } from './message.component';\r\n\r\n/**\r\n * Message\r\n * @selector x-message\r\n * @decorator component\r\n */\r\nexport const XMessagePrefix = 'x-message';\r\n\r\nexport const XMessagePortal = 'x-message-portal';\r\nexport const X_CONFIG_NAME = 'message';\r\n\r\n/**\r\n * Message Option\r\n */\r\nexport interface XMessageOption extends XAlertOption {\r\n /**\r\n * @zh_CN 方位,九宫格\r\n * @en_US Direction, nine grid\r\n * @default 'top'\r\n * @withConfig true\r\n */\r\n placement?: XPlace;\r\n /**\r\n * @zh_CN 偏移距离\r\n * @en_US Offset distance\r\n * @default '2rem'\r\n * @withConfig true\r\n */\r\n offset?: string | string[];\r\n /**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n * @default 'info'\r\n * @withConfig true\r\n */\r\n type?: XMessageType;\r\n /**\r\n * @zh_CN 多个消息的时候,显示类型\r\n * @en_US When multiple messages, the display type\r\n * @default 'list'\r\n * @withConfig true\r\n */\r\n displayType?: XMessageDisplayType;\r\n /**\r\n * @zh_CN 宽度\r\n * @en_US Width\r\n * @default '16rem'\r\n * @withConfig true\r\n */\r\n width?: string;\r\n /**\r\n * @zh_CN 高度\r\n * @en_US Height\r\n */\r\n height?: string;\r\n /**\r\n * @zh_CN 延迟关闭时间\r\n * @en_US Delay off time\r\n * @default 3000\r\n * @withConfig true\r\n */\r\n duration?: number;\r\n /**\r\n * @zh_CN 隐藏关闭按钮\r\n * @en_US Hide close button\r\n * @default true\r\n * @withConfig true\r\n */\r\n hideClose?: boolean;\r\n /**\r\n * @zh_CN 显示图标\r\n * @en_US Show icon\r\n * @default true\r\n * @withConfig true\r\n */\r\n showIcon?: boolean;\r\n /**\r\n * @zh_CN 延迟关闭订阅后的对象,用来释放或取消\r\n * @en_US Delayed closing the subscribed object, used to release or cancel\r\n */\r\n duration$?: Subscription | null;\r\n /**\r\n * @zh_CN 延迟关闭订阅对象\r\n * @en_US Delay in closing the subscription object\r\n */\r\n durationSub?: Subject<any>;\r\n}\r\n\r\n/**\r\n * @zh_CN 创建的消息对象\r\n * @en_US Message object created\r\n */\r\nexport interface XMessageOverlayRef extends XPortalOverlayRef<XMessageComponent> {}\r\n\r\n/**\r\n * @zh_CN 九宫格中的消息对象\r\n * @en_US Message object in Jiugongge\r\n */\r\nexport interface XMessagePlacement {\r\n [property: string]: XMessageRef;\r\n}\r\n\r\nexport interface XMessageRef {\r\n ref: XMessageOverlayRef;\r\n list: XMessageOption[];\r\n currentClose: () => void;\r\n closeAll: () => void;\r\n}\r\n\r\n/**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n */\r\nexport type XMessageType = XStatus;\r\n\r\n/**\r\n * @zh_CN 多个消息的时候,显示类型\r\n * @en_US When multiple messages, the display type\r\n */\r\nexport type XMessageDisplayType = 'list' | 'single';\r\n","import { Component, ViewEncapsulation, Renderer2, ElementRef, ChangeDetectorRef, ChangeDetectionStrategy } from '@angular/core';\r\nimport { XMoveAnimation, XIsEmpty } from '@ng-nest/ui/core';\r\nimport { XMessagePrefix, XMessageOption, XMessageRef } from './message.property';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: `${XMessagePrefix}`,\r\n templateUrl: './message.component.html',\r\n styleUrls: ['./message.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n animations: [XMoveAnimation]\r\n})\r\nexport class XMessageComponent {\r\n message: XMessageRef = { ref: {}, list: [], currentClose: () => {}, closeAll: () => {} };\r\n\r\n constructor(public renderer: Renderer2, public elementRef: ElementRef, public cdr: ChangeDetectorRef) {}\r\n\r\n onClose(item: XMessageOption) {\r\n this.message.list?.splice(this.message.list.indexOf(item), 1);\r\n item.duration$?.unsubscribe();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n moveDone($event: { toState: string }) {\r\n if ($event.toState === 'void' && XIsEmpty(this.message.list)) {\r\n this.message.ref?.overlayRef?.detach();\r\n }\r\n }\r\n\r\n onEnter(item: XMessageOption) {\r\n item.duration$?.unsubscribe();\r\n }\r\n\r\n onLeave(item: XMessageOption) {\r\n if (item.duration) {\r\n item.duration$ = of(true)\r\n .pipe(delay(item.duration))\r\n .subscribe(() => this.onClose(item));\r\n }\r\n }\r\n\r\n trackByNode(index: number, item: XMessageOption) {\r\n return `${item.title}-${item.content}`;\r\n }\r\n}\r\n","<div class=\"x-message\">\r\n <ng-container *ngFor=\"let item of message.list; trackBy: trackByNode\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n","import { Injectable } from '@angular/core';\r\nimport { XTemplate, XIsXTemplate, XIsEmpty, fillDefault, XIsString, XConfigService, XMessageConfig } from '@ng-nest/ui/core';\r\nimport {\r\n XMessageOverlayRef,\r\n XMessageType,\r\n XMessagePlacement,\r\n XMessageRef,\r\n XMessagePortal,\r\n XMessageOption,\r\n X_CONFIG_NAME\r\n} from './message.property';\r\nimport { XMessageComponent } from './message.component';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\nimport { XPortalService } from '@ng-nest/ui/portal';\r\n\r\n@Injectable()\r\nexport class XMessageService {\r\n messages: XMessagePlacement = {};\r\n\r\n default: XMessageOption = {\r\n type: 'info',\r\n width: '16rem',\r\n placement: 'top',\r\n offset: '2rem',\r\n effect: 'white',\r\n displayType: 'list',\r\n duration: 3000,\r\n hideClose: true,\r\n showIcon: true,\r\n hide: false\r\n };\r\n\r\n configDefault?: XMessageConfig;\r\n\r\n constructor(public portal: XPortalService, public configService: XConfigService) {\r\n this.configDefault = this.configService.getConfigForComponent(X_CONFIG_NAME);\r\n Object.assign(this.default, this.configDefault);\r\n }\r\n\r\n info(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'info');\r\n }\r\n\r\n success(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'success');\r\n }\r\n\r\n warning(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'warning');\r\n }\r\n\r\n error(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'error');\r\n }\r\n\r\n create(option: XMessageOption): XMessageOverlayRef {\r\n const offset = XIsString(option.offset) ? [option.offset as string] : (option.offset as string[]);\r\n\r\n return this.portal.attach({\r\n content: XMessageComponent,\r\n overlayConfig: {\r\n panelClass: XMessagePortal,\r\n positionStrategy: this.portal.setPlace(option.placement, option.width, option.height, ...offset)\r\n }\r\n });\r\n }\r\n\r\n private createMessage(option: XTemplate | XMessageOption, type: XMessageType): XMessageRef {\r\n let opt: XMessageOption;\r\n if (XIsXTemplate(option)) {\r\n opt = { title: option as XTemplate, type: type };\r\n } else {\r\n opt = option as XMessageOption;\r\n opt.type = type;\r\n }\r\n fillDefault(opt, this.default);\r\n return this.createMessagePlacement(opt);\r\n }\r\n\r\n private closeAll(excludeOption?: XMessageOption) {\r\n for (let key in this.messages) {\r\n for (let option of this.messages[key].list) {\r\n option !== excludeOption && this.removeMessage(option);\r\n }\r\n }\r\n }\r\n\r\n private createMessagePlacement(option: XMessageOption): XMessageRef {\r\n if (typeof option.placement === 'undefined') return { ref: {}, list: [], currentClose: () => {}, closeAll: () => {} };\r\n let msgPlacement = this.messages[option.placement];\r\n this.setDuration(option);\r\n if (XIsEmpty(msgPlacement) || !msgPlacement.ref?.overlayRef?.hasAttached()) {\r\n this.messages[option.placement] = {\r\n ref: this.create(option),\r\n list: [option],\r\n currentClose: () => {\r\n this.removeMessage(option);\r\n },\r\n closeAll: () => {\r\n this.closeAll();\r\n }\r\n };\r\n } else {\r\n this.messages[option.placement].list = [...(this.messages[option.placement].list as XMessageOption[]), option];\r\n }\r\n this.messageChange(this.messages[option.placement]);\r\n\r\n option.displayType === 'single' && this.closeAll(option);\r\n\r\n return this.messages[option.placement];\r\n }\r\n\r\n private messageChange(message: XMessageRef) {\r\n if (!message.ref?.overlayRef?.hasAttached() || !message?.ref?.componentRef?.instance) return;\r\n message.ref.componentRef.instance.message = message;\r\n message.ref.componentRef.instance.cdr.detectChanges();\r\n }\r\n\r\n private setDuration(option: XMessageOption) {\r\n if (option.duration) {\r\n option.duration$ = of(true)\r\n .pipe(delay(option.duration))\r\n .subscribe(() => {\r\n this.removeMessage(option);\r\n });\r\n }\r\n }\r\n\r\n private removeMessage(option: XMessageOption) {\r\n if (typeof option.placement === 'undefined') return;\r\n this.messages[option.placement].ref?.componentRef?.instance.onClose(option);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XMessageComponent } from './message.component';\r\nimport { XAlertModule } from '@ng-nest/ui/alert';\r\nimport { XMessageService } from './message.service';\r\nimport { XPortalModule } from '@ng-nest/ui/portal';\r\n\r\n@NgModule({\r\n declarations: [XMessageComponent],\r\n exports: [XMessageComponent],\r\n imports: [CommonModule, XPortalModule, XAlertModule],\r\n providers: [XMessageService]\r\n})\r\nexport class XMessageModule {}\r\n","/**\n * Generated bundle index. Do not ed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,CAAC,eAAe,CAAC,YADnB,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;2FAGzC,cAAc;kBAN1B,QAAQ;mBAAC;oBACR,YAAY,EAAE,CAAC,iBAAiB,CAAC;oBACjC,OAAO,EAAE,CAAC,iBAAiB,CAAC;oBAC5B,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;oBACpD,SAAS,EAAE,CAAC,eAAe,CAAC;iBAC7B;;;ACZD;;;;;;"}
1
+ {"version":3,"file":"ng-nest-ui-message.js","sources":["../../../../lib/ng-nest/ui/message/message.property.ts","../../../../lib/ng-nest/ui/message/message.component.ts","../../../../lib/ng-nest/ui/message/message.component.html","../../../../lib/ng-nest/ui/message/message.service.ts","../../../../lib/ng-nest/ui/message/message.module.ts","../../../../lib/ng-nest/ui/message/ng-nest-ui-message.ts"],"sourcesContent":["import { XStatus, XPlace } from '@ng-nest/ui/core';\r\nimport { XAlertOption } from '@ng-nest/ui/alert';\r\nimport { Subscription, Subject } from 'rxjs';\r\nimport { XPortalOverlayRef } from '@ng-nest/ui/portal';\r\nimport { XMessageComponent } from './message.component';\r\n\r\n/**\r\n * Message\r\n * @selector x-message\r\n * @decorator component\r\n */\r\nexport const XMessagePrefix = 'x-message';\r\n\r\nexport const XMessagePortal = 'x-message-portal';\r\nexport const X_CONFIG_NAME = 'message';\r\n\r\n/**\r\n * Message Option\r\n */\r\nexport interface XMessageOption extends XAlertOption {\r\n /**\r\n * @zh_CN 方位,九宫格\r\n * @en_US Direction, nine grid\r\n * @default 'top'\r\n * @withConfig true\r\n */\r\n placement?: XPlace;\r\n /**\r\n * @zh_CN 偏移距离\r\n * @en_US Offset distance\r\n * @default '2rem'\r\n * @withConfig true\r\n */\r\n offset?: string | string[];\r\n /**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n * @default 'info'\r\n * @withConfig true\r\n */\r\n type?: XMessageType;\r\n /**\r\n * @zh_CN 多个消息的时候,显示类型\r\n * @en_US When multiple messages, the display type\r\n * @default 'list'\r\n * @withConfig true\r\n */\r\n displayType?: XMessageDisplayType;\r\n /**\r\n * @zh_CN 宽度\r\n * @en_US Width\r\n * @default '16rem'\r\n * @withConfig true\r\n */\r\n width?: string;\r\n /**\r\n * @zh_CN 高度\r\n * @en_US Height\r\n */\r\n height?: string;\r\n /**\r\n * @zh_CN 延迟关闭时间\r\n * @en_US Delay off time\r\n * @default 3000\r\n * @withConfig true\r\n */\r\n duration?: number;\r\n /**\r\n * @zh_CN 隐藏关闭按钮\r\n * @en_US Hide close button\r\n * @default true\r\n * @withConfig true\r\n */\r\n hideClose?: boolean;\r\n /**\r\n * @zh_CN 显示图标\r\n * @en_US Show icon\r\n * @default true\r\n * @withConfig true\r\n */\r\n showIcon?: boolean;\r\n /**\r\n * @zh_CN 延迟关闭订阅后的对象,用来释放或取消\r\n * @en_US Delayed closing the subscribed object, used to release or cancel\r\n */\r\n duration$?: Subscription | null;\r\n /**\r\n * @zh_CN 延迟关闭订阅对象\r\n * @en_US Delay in closing the subscription object\r\n */\r\n durationSub?: Subject<any>;\r\n}\r\n\r\n/**\r\n * @zh_CN 创建的消息对象\r\n * @en_US Message object created\r\n */\r\nexport interface XMessageOverlayRef extends XPortalOverlayRef<XMessageComponent> {}\r\n\r\n/**\r\n * @zh_CN 九宫格中的消息对象\r\n * @en_US Message object in Jiugongge\r\n */\r\nexport interface XMessagePlacement {\r\n [property: string]: XMessageRef;\r\n}\r\n\r\nexport interface XMessageRef {\r\n ref: XMessageOverlayRef;\r\n list: XMessageOption[];\r\n currentClose: () => void;\r\n closeAll: () => void;\r\n}\r\n\r\n/**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n */\r\nexport type XMessageType = XStatus;\r\n\r\n/**\r\n * @zh_CN 多个消息的时候,显示类型\r\n * @en_US When multiple messages, the display type\r\n */\r\nexport type XMessageDisplayType = 'list' | 'single';\r\n","import { Component, ViewEncapsulation, Renderer2, ElementRef, ChangeDetectorRef, ChangeDetectionStrategy } from '@angular/core';\r\nimport { XMoveAnimation, XIsEmpty } from '@ng-nest/ui/core';\r\nimport { XMessagePrefix, XMessageOption, XMessageRef } from './message.property';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: `${XMessagePrefix}`,\r\n templateUrl: './message.component.html',\r\n styleUrls: ['./message.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n animations: [XMoveAnimation]\r\n})\r\nexport class XMessageComponent {\r\n message: XMessageRef = { ref: {}, list: [], currentClose: () => {}, closeAll: () => {} };\r\n\r\n constructor(public renderer: Renderer2, public elementRef: ElementRef, public cdr: ChangeDetectorRef) {}\r\n\r\n onClose(item: XMessageOption) {\r\n this.message.list?.splice(this.message.list.indexOf(item), 1);\r\n item.duration$?.unsubscribe();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n moveDone($event: { toState: string }) {\r\n if ($event.toState === 'void' && XIsEmpty(this.message.list)) {\r\n this.message.ref?.overlayRef?.detach();\r\n }\r\n }\r\n\r\n onEnter(item: XMessageOption) {\r\n item.duration$?.unsubscribe();\r\n }\r\n\r\n onLeave(item: XMessageOption) {\r\n if (item.duration) {\r\n item.duration$ = of(true)\r\n .pipe(delay(item.duration))\r\n .subscribe(() => this.onClose(item));\r\n }\r\n }\r\n\r\n trackByNode(_index: number, item: XMessageOption) {\r\n return `${item.title}-${item.content}`;\r\n }\r\n}\r\n","<div class=\"x-message\">\r\n <ng-container *ngFor=\"let item of message.list; trackBy: trackByNode\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n","import { Injectable } from '@angular/core';\r\nimport { XTemplate, XIsXTemplate, XIsEmpty, fillDefault, XIsString, XConfigService, XMessageConfig } from '@ng-nest/ui/core';\r\nimport {\r\n XMessageOverlayRef,\r\n XMessageType,\r\n XMessagePlacement,\r\n XMessageRef,\r\n XMessagePortal,\r\n XMessageOption,\r\n X_CONFIG_NAME\r\n} from './message.property';\r\nimport { XMessageComponent } from './message.component';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\nimport { XPortalService } from '@ng-nest/ui/portal';\r\n\r\n@Injectable()\r\nexport class XMessageService {\r\n messages: XMessagePlacement = {};\r\n\r\n default: XMessageOption = {\r\n type: 'info',\r\n width: '16rem',\r\n placement: 'top',\r\n offset: '2rem',\r\n effect: 'white',\r\n displayType: 'list',\r\n duration: 3000,\r\n hideClose: true,\r\n showIcon: true,\r\n hide: false\r\n };\r\n\r\n configDefault?: XMessageConfig;\r\n\r\n constructor(public portal: XPortalService, public configService: XConfigService) {\r\n this.configDefault = this.configService.getConfigForComponent(X_CONFIG_NAME);\r\n Object.assign(this.default, this.configDefault);\r\n }\r\n\r\n info(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'info');\r\n }\r\n\r\n success(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'success');\r\n }\r\n\r\n warning(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'warning');\r\n }\r\n\r\n error(option: XTemplate | XMessageOption): XMessageRef {\r\n return this.createMessage(option, 'error');\r\n }\r\n\r\n create(option: XMessageOption): XMessageOverlayRef {\r\n const offset = XIsString(option.offset) ? [option.offset as string] : (option.offset as string[]);\r\n\r\n return this.portal.attach({\r\n content: XMessageComponent,\r\n overlayConfig: {\r\n panelClass: XMessagePortal,\r\n positionStrategy: this.portal.setPlace(option.placement, option.width, option.height, ...offset)\r\n }\r\n });\r\n }\r\n\r\n private createMessage(option: XTemplate | XMessageOption, type: XMessageType): XMessageRef {\r\n let opt: XMessageOption;\r\n if (XIsXTemplate(option)) {\r\n opt = { title: option as XTemplate, type: type };\r\n } else {\r\n opt = option as XMessageOption;\r\n opt.type = type;\r\n }\r\n fillDefault(opt, this.default);\r\n return this.createMessagePlacement(opt);\r\n }\r\n\r\n private closeAll(excludeOption?: XMessageOption) {\r\n for (let key in this.messages) {\r\n for (let option of this.messages[key].list) {\r\n option !== excludeOption && this.removeMessage(option);\r\n }\r\n }\r\n }\r\n\r\n private createMessagePlacement(option: XMessageOption): XMessageRef {\r\n if (typeof option.placement === 'undefined') return { ref: {}, list: [], currentClose: () => {}, closeAll: () => {} };\r\n let msgPlacement = this.messages[option.placement];\r\n this.setDuration(option);\r\n if (XIsEmpty(msgPlacement) || !msgPlacement.ref?.overlayRef?.hasAttached()) {\r\n this.messages[option.placement] = {\r\n ref: this.create(option),\r\n list: [option],\r\n currentClose: () => {\r\n this.removeMessage(option);\r\n },\r\n closeAll: () => {\r\n this.closeAll();\r\n }\r\n };\r\n } else {\r\n this.messages[option.placement].list = [...(this.messages[option.placement].list as XMessageOption[]), option];\r\n }\r\n this.messageChange(this.messages[option.placement]);\r\n\r\n option.displayType === 'single' && this.closeAll(option);\r\n\r\n return this.messages[option.placement];\r\n }\r\n\r\n private messageChange(message: XMessageRef) {\r\n if (!message.ref?.overlayRef?.hasAttached() || !message?.ref?.componentRef?.instance) return;\r\n message.ref.componentRef.instance.message = message;\r\n message.ref.componentRef.instance.cdr.detectChanges();\r\n }\r\n\r\n private setDuration(option: XMessageOption) {\r\n if (option.duration) {\r\n option.duration$ = of(true)\r\n .pipe(delay(option.duration))\r\n .subscribe(() => {\r\n this.removeMessage(option);\r\n });\r\n }\r\n }\r\n\r\n private removeMessage(option: XMessageOption) {\r\n if (typeof option.placement === 'undefined') return;\r\n this.messages[option.placement].ref?.componentRef?.instance.onClose(option);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XMessageComponent } from './message.component';\r\nimport { XAlertModule } from '@ng-nest/ui/alert';\r\nimport { XMessageService } from './message.service';\r\nimport { XPortalModule } from '@ng-nest/ui/portal';\r\n\r\n@NgModule({\r\n declarations: [XMessageComponent],\r\n exports: [XMessageComponent],\r\n imports: [CommonModule, XPortalModule, XAlertModule],\r\n providers: [XMessageService]\r\n})\r\nexport class XMessageModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;AAMA;;;;;MAKa,cAAc,GAAG,YAAY;MAE7B,cAAc,GAAG,mBAAmB;MACpC,aAAa,GAAG;;MCAhB,iBAAiB;IAG5B,YAAmB,QAAmB,EAAS,UAAsB,EAAS,GAAsB;QAAjF,aAAQ,GAAR,QAAQ,CAAW;QAAS,eAAU,GAAV,UAAU,CAAY;QAAS,QAAG,GAAH,GAAG,CAAmB;QAFpG,YAAO,GAAgB,EAAE,GAAG,EAAE,EAAE,EAAE,IAAI,EAAE,EAAE,EAAE,YAAY,EAAE,SAAQ,EAAE,QAAQ,EAAE,SAAQ,EAAE,CAAC;KAEe;IAExG,OAAO,CAAC,IAAoB;;QAC1B,MAAA,IAAI,CAAC,OAAO,CAAC,IAAI,0CAAE,MAAM,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC;QAC9D,MAAA,IAAI,CAAC,SAAS,0CAAE,WAAW,EAAE,CAAC;QAC9B,IAAI,CAAC,GAAG,CAAC,aAAa,EAAE,CAAC;KAC1B;IAED,QAAQ,CAAC,MAA2B;;QAClC,IAAI,MAAM,CAAC,OAAO,KAAK,MAAM,IAAI,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE;YAC5D,MAAA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,CAAC,SAAS,KAAK,WAAW;YAAE,OAAO;QACpD,MAAA,MAAA,IAAI,CAAC,QAAQ,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,GAAG,0CAAE,YAAY,0CAAE,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;KAC7E;;+HAnHU,eAAe;mIAAf,eAAe;2FAAf,eAAe;kBAD3B,UAAU;;;MCHE,cAAc;;8HAAd,cAAc;+HAAd,cAAc,iBALV,iBAAiB,aAEtB,YAAY,EAAE,aAAa,EAAE,YAAY,aADzC,iBAAiB;+HAIhB,cAAc,aAFd,CAAC,eAAe,CAAC,YADnB,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;2FAGzC,cAAc;kBAN1B,QAAQ;mBAAC;oBACR,YAAY,EAAE,CAAC,iBAAiB,CAAC;oBACjC,OAAO,EAAE,CAAC,iBAAiB,CAAC;oBAC5B,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;oBACpD,SAAS,EAAE,CAAC,eAAe,CAAC;iBAC7B;;;ACZD;;;;;;"}
@@ -49,13 +49,13 @@ class XNotificationComponent {
49
49
  });
50
50
  }
51
51
  }
52
- trackByItem(index, item) {
52
+ trackByItem(_index, item) {
53
53
  return `${item.title}-${item.content}`;
54
54
  }
55
55
  }
56
- /** @nocollapse */ XNotificationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationComponent, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
57
- /** @nocollapse */ XNotificationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.3", type: XNotificationComponent, selector: "x-notification", ngImport: i0, template: "<div class=\"x-notification\">\r\n <ng-container *ngFor=\"let item of notification.list; trackBy: trackByItem\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n", styles: [".x-notification{margin:0;padding:0}.x-notification>x-alert{padding:.25rem}.x-notification>x-alert>.x-alert{box-shadow:var(--x-box-shadow) var(--x-box-shadow-light-color)}.x-notification>x-alert .x-alert-icon.x-icon{margin-top:.125rem;font-size:1.25rem;align-self:flex-start}.x-notification-portal x-notification{width:100%}"], components: [{ type: i1.XAlertComponent, selector: "x-alert" }], directives: [{ type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], animations: [XMoveAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
58
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationComponent, decorators: [{
56
+ /** @nocollapse */ XNotificationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationComponent, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
57
+ /** @nocollapse */ XNotificationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: XNotificationComponent, selector: "x-notification", ngImport: i0, template: "<div class=\"x-notification\">\r\n <ng-container *ngFor=\"let item of notification.list; trackBy: trackByItem\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n", styles: [".x-notification{margin:0;padding:0}.x-notification>x-alert{padding:.25rem}.x-notification>x-alert>.x-alert{box-shadow:var(--x-box-shadow) var(--x-box-shadow-light-color)}.x-notification>x-alert .x-alert-icon.x-icon{margin-top:.125rem;font-size:1.25rem;align-self:flex-start}.x-notification-portal x-notification{width:100%}\n"], components: [{ type: i1.XAlertComponent, selector: "x-alert" }], directives: [{ type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], animations: [XMoveAnimation], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
58
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationComponent, decorators: [{
59
59
  type: Component,
60
60
  args: [{
61
61
  selector: `${XNotificationPrefix}`,
@@ -157,18 +157,18 @@ class XNotificationService {
157
157
  (_b = (_a = this.notifications[option.placement].ref) === null || _a === void 0 ? void 0 : _a.componentRef) === null || _b === void 0 ? void 0 : _b.instance.onClose(option);
158
158
  }
159
159
  }
160
- /** @nocollapse */ XNotificationService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationService, deps: [{ token: i1$1.XPortalService }], target: i0.ɵɵFactoryTarget.Injectable });
161
- /** @nocollapse */ XNotificationService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationService });
162
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationService, decorators: [{
160
+ /** @nocollapse */ XNotificationService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationService, deps: [{ token: i1$1.XPortalService }], target: i0.ɵɵFactoryTarget.Injectable });
161
+ /** @nocollapse */ XNotificationService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationService });
162
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationService, decorators: [{
163
163
  type: Injectable
164
164
  }], ctorParameters: function () { return [{ type: i1$1.XPortalService }]; } });
165
165
 
166
166
  class XNotificationModule {
167
167
  }
168
- /** @nocollapse */ XNotificationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
169
- /** @nocollapse */ XNotificationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationModule, declarations: [XNotificationComponent], imports: [CommonModule, XPortalModule, XAlertModule], exports: [XNotificationComponent] });
170
- /** @nocollapse */ XNotificationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationModule, providers: [XNotificationService], imports: [[CommonModule, XPortalModule, XAlertModule]] });
171
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XNotificationModule, decorators: [{
168
+ /** @nocollapse */ XNotificationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
169
+ /** @nocollapse */ XNotificationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationModule, declarations: [XNotificationComponent], imports: [CommonModule, XPortalModule, XAlertModule], exports: [XNotificationComponent] });
170
+ /** @nocollapse */ XNotificationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationModule, providers: [XNotificationService], imports: [[CommonModule, XPortalModule, XAlertModule]] });
171
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XNotificationModule, decorators: [{
172
172
  type: NgModule,
173
173
  args: [{
174
174
  declarations: [XNotificationComponent],
@@ -1 +1 @@
1
- {"version":3,"file":"ng-nest-ui-notification.js","sources":["../../../../lib/ng-nest/ui/notification/notification.property.ts","../../../../lib/ng-nest/ui/notification/notification.component.ts","../../../../lib/ng-nest/ui/notification/notification.component.html","../../../../lib/ng-nest/ui/notification/notification.service.ts","../../../../lib/ng-nest/ui/notification/notification.module.ts","../../../../lib/ng-nest/ui/notification/ng-nest-ui-notification.ts"],"sourcesContent":["import { ComponentRef } from '@angular/core';\r\nimport { XStatus, XCorner } from '@ng-nest/ui/core';\r\nimport { XAlertOption } from '@ng-nest/ui/alert';\r\nimport { ComponentPortal } from '@angular/cdk/portal';\r\nimport { XNotificationComponent } from './notification.component';\r\nimport { XPortalOverlayRef } from '@ng-nest/ui/portal';\r\nimport { Subscription, Subject } from 'rxjs';\r\n\r\n/**\r\n * Notification\r\n * @selector x-notification\r\n * @decorator component\r\n */\r\nexport const XNotificationPrefix = 'x-notification';\r\n\r\nexport const XNotificationPortal = 'x-notification-portal';\r\n\r\n/**\r\n * Notification Option\r\n */\r\nexport interface XNotificationOption extends XAlertOption {\r\n /**\r\n * @zh_CN 方位\r\n * @en_US Placement\r\n * @default 'top-end'\r\n */\r\n placement?: XCorner;\r\n /**\r\n * @zh_CN 偏移距离\r\n * @en_US Offset distance\r\n * @default '0.5rem'\r\n */\r\n offset?: string | string[];\r\n /**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n * @default 'info'\r\n */\r\n type?: XNotificationType;\r\n /**\r\n * @zh_CN 宽度\r\n * @en_US Width\r\n * @default '20rem'\r\n */\r\n width?: string;\r\n /**\r\n * @zh_CN 高度\r\n * @en_US Height\r\n */\r\n height?: string;\r\n /**\r\n * @zh_CN 延迟关闭时间\r\n * @en_US Delay off time\r\n * @default 4500\r\n */\r\n duration?: number;\r\n /**\r\n * @zh_CN 隐藏关闭按钮\r\n * @en_US Hide close button\r\n * @default true\r\n */\r\n hideClose?: boolean;\r\n /**\r\n * @zh_CN 显示图标\r\n * @en_US Show icon\r\n * @default true\r\n */\r\n showIcon?: boolean;\r\n /**\r\n * @zh_CN 延迟关闭订阅后的对象,用来释放或取消\r\n * @en_US Delayed closing the subscribed object, used to release or cancel\r\n */\r\n duration$?: Subscription | null;\r\n /**\r\n * @zh_CN 延迟关闭订阅对象\r\n * @en_US Delay in closing the subscription object\r\n */\r\n durationSub?: Subject<any>;\r\n}\r\n\r\n/**\r\n * @zh_CN 创建的消息对象\r\n * @en_US Message object created\r\n */\r\nexport interface XNotificationOverlayRef extends XPortalOverlayRef<XNotificationComponent> {}\r\n\r\n/**\r\n * @zh_CN 九宫格中的消息对象\r\n * @en_US Message object in nine grid\r\n */\r\nexport interface XNotificationPlacement {\r\n [property: string]: XNotificationRef;\r\n}\r\n\r\nexport interface XNotificationRef {\r\n ref?: XNotificationOverlayRef;\r\n list?: XNotificationOption[];\r\n}\r\n\r\n/**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n */\r\nexport type XNotificationType = XStatus;\r\n","import { Component, ViewEncapsulation, Renderer2, ElementRef, ChangeDetectorRef, ChangeDetectionStrategy } from '@angular/core';\r\nimport { XMoveAnimation, XIsEmpty } from '@ng-nest/ui/core';\r\nimport { XNotificationPrefix, XNotificationOption, XNotificationRef } from './notification.property';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: `${XNotificationPrefix}`,\r\n templateUrl: './notification.component.html',\r\n styleUrls: ['./notification.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n animations: [XMoveAnimation]\r\n})\r\nexport class XNotificationComponent {\r\n notification: XNotificationRef = { list: [] };\r\n\r\n constructor(public renderer: Renderer2, public elementRef: ElementRef, public cdr: ChangeDetectorRef) {}\r\n\r\n onClose(item: XNotificationOption) {\r\n this.notification.list?.splice(this.notification.list.indexOf(item), 1);\r\n item.duration$ && item.duration$.unsubscribe();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n moveDone($event: { toState: string }) {\r\n if ($event.toState === 'void' && XIsEmpty(this.notification.list)) {\r\n this.notification.ref?.overlayRef?.detach();\r\n }\r\n }\r\n\r\n onEnter(item: XNotificationOption) {\r\n item.duration$ && item.duration$.unsubscribe();\r\n }\r\n\r\n onLeave(item: XNotificationOption) {\r\n if (item.duration) {\r\n item.duration$ = of(true)\r\n .pipe(delay(item.duration))\r\n .subscribe(() => {\r\n this.onClose(item);\r\n });\r\n }\r\n }\r\n\r\n trackByItem(index: number, item: XNotificationOption) {\r\n return `${item.title}-${item.content}`;\r\n }\r\n}\r\n","<div class=\"x-notification\">\r\n <ng-container *ngFor=\"let item of notification.list; trackBy: trackByItem\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n","import { Injectable } from '@angular/core';\r\nimport { XTemplate, XIsXTemplate, fillDefault, XIsEmpty, XIsString } from '@ng-nest/ui/core';\r\nimport {\r\n XNotificationOption,\r\n XNotificationOverlayRef,\r\n XNotificationType,\r\n XNotificationPlacement,\r\n XNotificationRef,\r\n XNotificationPortal\r\n} from './notification.property';\r\nimport { XNotificationComponent } from './notification.component';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\nimport { XPortalService } from '@ng-nest/ui/portal';\r\n\r\n@Injectable()\r\nexport class XNotificationService {\r\n notifications: XNotificationPlacement = {};\r\n\r\n default: XNotificationOption = {\r\n type: 'info',\r\n width: '20rem',\r\n placement: 'top-end',\r\n offset: '0.5rem',\r\n effect: 'white',\r\n duration: 4500,\r\n showIcon: true\r\n };\r\n\r\n constructor(public portal: XPortalService) {}\r\n\r\n info(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'info');\r\n }\r\n\r\n success(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'success');\r\n }\r\n\r\n warning(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'warning');\r\n }\r\n\r\n error(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'error');\r\n }\r\n\r\n create(option: XNotificationOption): XNotificationOverlayRef {\r\n const offset = XIsString(option.offset) ? [option.offset as string] : (option.offset as string[]);\r\n return this.portal.attach({\r\n content: XNotificationComponent,\r\n overlayConfig: {\r\n panelClass: XNotificationPortal,\r\n positionStrategy: this.portal.setPlace(option.placement, option.width, option.height, ...offset)\r\n }\r\n });\r\n }\r\n\r\n private createNotification(option: XTemplate | XNotificationOption, type: XNotificationType): XNotificationRef {\r\n let opt: XNotificationOption;\r\n if (XIsXTemplate(option)) {\r\n opt = { title: option as XTemplate, type: type };\r\n } else {\r\n opt = option as XNotificationOption;\r\n opt.type = type;\r\n }\r\n fillDefault(opt, this.default);\r\n return this.createNotificationPlacement(opt);\r\n }\r\n\r\n private createNotificationPlacement(option: XNotificationOption): XNotificationRef {\r\n if (typeof option.placement === 'undefined') return {};\r\n let msgPlacement = this.notifications[option.placement];\r\n this.setDuration(option);\r\n if (XIsEmpty(msgPlacement) || !msgPlacement.ref?.overlayRef?.hasAttached()) {\r\n this.notifications[option.placement] = {\r\n ref: this.create(option),\r\n list: [option]\r\n };\r\n } else {\r\n this.notifications[option.placement].list = [...(this.notifications[option.placement].list as XNotificationOption[]), option];\r\n }\r\n this.notificationChange(this.notifications[option.placement]);\r\n\r\n return this.notifications[option.placement];\r\n }\r\n\r\n private notificationChange(notification: XNotificationRef) {\r\n if (!notification.ref?.overlayRef?.hasAttached() || !notification?.ref?.componentRef?.instance) return;\r\n notification.ref.componentRef.instance.notification = notification;\r\n notification.ref.componentRef.instance.cdr.detectChanges();\r\n }\r\n\r\n private setDuration(option: XNotificationOption) {\r\n if (option.duration) {\r\n option.duration$ = of(true)\r\n .pipe(delay(option.duration))\r\n .subscribe(() => {\r\n this.removeNotification(option);\r\n option.duration$ && option.duration$.unsubscribe();\r\n });\r\n }\r\n }\r\n\r\n private removeNotification(option: XNotificationOption) {\r\n if (typeof option.placement === 'undefined') return;\r\n this.notifications[option.placement].ref?.componentRef?.instance.onClose(option);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XNotificationComponent } from './notification.component';\r\nimport { XAlertModule } from '@ng-nest/ui/alert';\r\nimport { XPortalModule } from '@ng-nest/ui/portal';\r\nimport { XNotificationService } from './notification.service';\r\n\r\n@NgModule({\r\n declarations: [XNotificationComponent],\r\n exports: [XNotificationComponent],\r\n imports: [CommonModule, XPortalModule, XAlertModule],\r\n providers: [XNotificationService]\r\n})\r\nexport class XNotificationModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;AAQA;;;;;MAKa,mBAAmB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MAAA,MAAA,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,GAAG,0CAAE,YAAY,0CAAE,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;KAClF;;oIA3FU,oBAAoB;wIAApB,oBAAoB;2FAApB,oBAAoB;kBADhC,UAAU;;;MCFE,mBAAmB;;mIAAnB,mBAAmB;oIAAnB,mBAAmB,iBALf,sBAAsB,aAE3B,YAAY,EAAE,aAAa,EAAE,YAAY,aADzC,sBAAsB;oIAIrB,mBAAmB,aAFnB,CAAC,oBAAoB,CAAC,YADxB,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;2FAGzC,mBAAmB;kBAN/B,QAAQ;mBAAC;oBACR,YAAY,EAAE,CAAC,sBAAsB,CAAC;oBACtC,OAAO,EAAE,CAAC,sBAAsB,CAAC;oBACjC,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;oBACpD,SAAS,EAAE,CAAC,oBAAoB,CAAC;iBAClC;;;ACZD;;;;;;"}
1
+ {"version":3,"file":"ng-nest-ui-notification.js","sources":["../../../../lib/ng-nest/ui/notification/notification.property.ts","../../../../lib/ng-nest/ui/notification/notification.component.ts","../../../../lib/ng-nest/ui/notification/notification.component.html","../../../../lib/ng-nest/ui/notification/notification.service.ts","../../../../lib/ng-nest/ui/notification/notification.module.ts","../../../../lib/ng-nest/ui/notification/ng-nest-ui-notification.ts"],"sourcesContent":["import { XStatus, XCorner } from '@ng-nest/ui/core';\r\nimport { XAlertOption } from '@ng-nest/ui/alert';\r\nimport { XNotificationComponent } from './notification.component';\r\nimport { XPortalOverlayRef } from '@ng-nest/ui/portal';\r\nimport { Subscription, Subject } from 'rxjs';\r\n\r\n/**\r\n * Notification\r\n * @selector x-notification\r\n * @decorator component\r\n */\r\nexport const XNotificationPrefix = 'x-notification';\r\n\r\nexport const XNotificationPortal = 'x-notification-portal';\r\n\r\n/**\r\n * Notification Option\r\n */\r\nexport interface XNotificationOption extends XAlertOption {\r\n /**\r\n * @zh_CN 方位\r\n * @en_US Placement\r\n * @default 'top-end'\r\n */\r\n placement?: XCorner;\r\n /**\r\n * @zh_CN 偏移距离\r\n * @en_US Offset distance\r\n * @default '0.5rem'\r\n */\r\n offset?: string | string[];\r\n /**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n * @default 'info'\r\n */\r\n type?: XNotificationType;\r\n /**\r\n * @zh_CN 宽度\r\n * @en_US Width\r\n * @default '20rem'\r\n */\r\n width?: string;\r\n /**\r\n * @zh_CN 高度\r\n * @en_US Height\r\n */\r\n height?: string;\r\n /**\r\n * @zh_CN 延迟关闭时间\r\n * @en_US Delay off time\r\n * @default 4500\r\n */\r\n duration?: number;\r\n /**\r\n * @zh_CN 隐藏关闭按钮\r\n * @en_US Hide close button\r\n * @default true\r\n */\r\n hideClose?: boolean;\r\n /**\r\n * @zh_CN 显示图标\r\n * @en_US Show icon\r\n * @default true\r\n */\r\n showIcon?: boolean;\r\n /**\r\n * @zh_CN 延迟关闭订阅后的对象,用来释放或取消\r\n * @en_US Delayed closing the subscribed object, used to release or cancel\r\n */\r\n duration$?: Subscription | null;\r\n /**\r\n * @zh_CN 延迟关闭订阅对象\r\n * @en_US Delay in closing the subscription object\r\n */\r\n durationSub?: Subject<any>;\r\n}\r\n\r\n/**\r\n * @zh_CN 创建的消息对象\r\n * @en_US Message object created\r\n */\r\nexport interface XNotificationOverlayRef extends XPortalOverlayRef<XNotificationComponent> {}\r\n\r\n/**\r\n * @zh_CN 九宫格中的消息对象\r\n * @en_US Message object in nine grid\r\n */\r\nexport interface XNotificationPlacement {\r\n [property: string]: XNotificationRef;\r\n}\r\n\r\nexport interface XNotificationRef {\r\n ref?: XNotificationOverlayRef;\r\n list?: XNotificationOption[];\r\n}\r\n\r\n/**\r\n * @zh_CN 类型\r\n * @en_US Types of\r\n */\r\nexport type XNotificationType = XStatus;\r\n","import { Component, ViewEncapsulation, Renderer2, ElementRef, ChangeDetectorRef, ChangeDetectionStrategy } from '@angular/core';\r\nimport { XMoveAnimation, XIsEmpty } from '@ng-nest/ui/core';\r\nimport { XNotificationPrefix, XNotificationOption, XNotificationRef } from './notification.property';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: `${XNotificationPrefix}`,\r\n templateUrl: './notification.component.html',\r\n styleUrls: ['./notification.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n animations: [XMoveAnimation]\r\n})\r\nexport class XNotificationComponent {\r\n notification: XNotificationRef = { list: [] };\r\n\r\n constructor(public renderer: Renderer2, public elementRef: ElementRef, public cdr: ChangeDetectorRef) {}\r\n\r\n onClose(item: XNotificationOption) {\r\n this.notification.list?.splice(this.notification.list.indexOf(item), 1);\r\n item.duration$ && item.duration$.unsubscribe();\r\n this.cdr.detectChanges();\r\n }\r\n\r\n moveDone($event: { toState: string }) {\r\n if ($event.toState === 'void' && XIsEmpty(this.notification.list)) {\r\n this.notification.ref?.overlayRef?.detach();\r\n }\r\n }\r\n\r\n onEnter(item: XNotificationOption) {\r\n item.duration$ && item.duration$.unsubscribe();\r\n }\r\n\r\n onLeave(item: XNotificationOption) {\r\n if (item.duration) {\r\n item.duration$ = of(true)\r\n .pipe(delay(item.duration))\r\n .subscribe(() => {\r\n this.onClose(item);\r\n });\r\n }\r\n }\r\n\r\n trackByItem(_index: number, item: XNotificationOption) {\r\n return `${item.title}-${item.content}`;\r\n }\r\n}\r\n","<div class=\"x-notification\">\r\n <ng-container *ngFor=\"let item of notification.list; trackBy: trackByItem\">\r\n <x-alert\r\n [@x-move-animation]=\"item.placement\"\r\n (@x-move-animation.done)=\"moveDone($event)\"\r\n (mouseenter)=\"onEnter(item)\"\r\n (mouseleave)=\"onLeave(item)\"\r\n (close)=\"onClose(item)\"\r\n [hide]=\"item.hide\"\r\n [title]=\"item.title\"\r\n [content]=\"item.content\"\r\n [type]=\"item.type\"\r\n [effect]=\"item.effect\"\r\n [hideClose]=\"item.hideClose\"\r\n [closeText]=\"item.closeText\"\r\n [showIcon]=\"item.showIcon\"\r\n duration=\"0\"\r\n manual\r\n disabledAnimation\r\n ></x-alert>\r\n </ng-container>\r\n</div>\r\n","import { Injectable } from '@angular/core';\r\nimport { XTemplate, XIsXTemplate, fillDefault, XIsEmpty, XIsString } from '@ng-nest/ui/core';\r\nimport {\r\n XNotificationOption,\r\n XNotificationOverlayRef,\r\n XNotificationType,\r\n XNotificationPlacement,\r\n XNotificationRef,\r\n XNotificationPortal\r\n} from './notification.property';\r\nimport { XNotificationComponent } from './notification.component';\r\nimport { of } from 'rxjs';\r\nimport { delay } from 'rxjs/operators';\r\nimport { XPortalService } from '@ng-nest/ui/portal';\r\n\r\n@Injectable()\r\nexport class XNotificationService {\r\n notifications: XNotificationPlacement = {};\r\n\r\n default: XNotificationOption = {\r\n type: 'info',\r\n width: '20rem',\r\n placement: 'top-end',\r\n offset: '0.5rem',\r\n effect: 'white',\r\n duration: 4500,\r\n showIcon: true\r\n };\r\n\r\n constructor(public portal: XPortalService) {}\r\n\r\n info(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'info');\r\n }\r\n\r\n success(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'success');\r\n }\r\n\r\n warning(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'warning');\r\n }\r\n\r\n error(option: XTemplate | XNotificationOption): XNotificationRef {\r\n return this.createNotification(option, 'error');\r\n }\r\n\r\n create(option: XNotificationOption): XNotificationOverlayRef {\r\n const offset = XIsString(option.offset) ? [option.offset as string] : (option.offset as string[]);\r\n return this.portal.attach({\r\n content: XNotificationComponent,\r\n overlayConfig: {\r\n panelClass: XNotificationPortal,\r\n positionStrategy: this.portal.setPlace(option.placement, option.width, option.height, ...offset)\r\n }\r\n });\r\n }\r\n\r\n private createNotification(option: XTemplate | XNotificationOption, type: XNotificationType): XNotificationRef {\r\n let opt: XNotificationOption;\r\n if (XIsXTemplate(option)) {\r\n opt = { title: option as XTemplate, type: type };\r\n } else {\r\n opt = option as XNotificationOption;\r\n opt.type = type;\r\n }\r\n fillDefault(opt, this.default);\r\n return this.createNotificationPlacement(opt);\r\n }\r\n\r\n private createNotificationPlacement(option: XNotificationOption): XNotificationRef {\r\n if (typeof option.placement === 'undefined') return {};\r\n let msgPlacement = this.notifications[option.placement];\r\n this.setDuration(option);\r\n if (XIsEmpty(msgPlacement) || !msgPlacement.ref?.overlayRef?.hasAttached()) {\r\n this.notifications[option.placement] = {\r\n ref: this.create(option),\r\n list: [option]\r\n };\r\n } else {\r\n this.notifications[option.placement].list = [...(this.notifications[option.placement].list as XNotificationOption[]), option];\r\n }\r\n this.notificationChange(this.notifications[option.placement]);\r\n\r\n return this.notifications[option.placement];\r\n }\r\n\r\n private notificationChange(notification: XNotificationRef) {\r\n if (!notification.ref?.overlayRef?.hasAttached() || !notification?.ref?.componentRef?.instance) return;\r\n notification.ref.componentRef.instance.notification = notification;\r\n notification.ref.componentRef.instance.cdr.detectChanges();\r\n }\r\n\r\n private setDuration(option: XNotificationOption) {\r\n if (option.duration) {\r\n option.duration$ = of(true)\r\n .pipe(delay(option.duration))\r\n .subscribe(() => {\r\n this.removeNotification(option);\r\n option.duration$ && option.duration$.unsubscribe();\r\n });\r\n }\r\n }\r\n\r\n private removeNotification(option: XNotificationOption) {\r\n if (typeof option.placement === 'undefined') return;\r\n this.notifications[option.placement].ref?.componentRef?.instance.onClose(option);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { XNotificationComponent } from './notification.component';\r\nimport { XAlertModule } from '@ng-nest/ui/alert';\r\nimport { XPortalModule } from '@ng-nest/ui/portal';\r\nimport { XNotificationService } from './notification.service';\r\n\r\n@NgModule({\r\n declarations: [XNotificationComponent],\r\n exports: [XNotificationComponent],\r\n imports: [CommonModule, XPortalModule, XAlertModule],\r\n providers: [XNotificationService]\r\n})\r\nexport class XNotificationModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;AAMA;;;;;MAKa,mBAAmB,GAAG,iBAAiB;MAEvC,mBAAmB,GAAG;;MCCtB,sBAAsB;IAGjC,YAAmB,QAAmB,EAAS,UAAsB,EAAS,GAAsB;QAAjF,aAAQ,GAAR,QAAQ,CAAW;QAAS,eAAU,GAAV,UAAU,CAAY;QAAS,QAAG,GAAH,GAAG,CAAmB;QAFpG,iBAAY,GAAqB,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC;KAE0D;IAExG,OAAO,CAAC,IAAyB;;QAC/B,MAAA,IAAI,CAAC,YAAY,CAAC,IAAI,0CAAE,MAAM,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC;QACxE,IAAI,CAAC,SAAS,IAAI,IAAI,CAAC,SAAS,CAAC,WAAW,EAAE,CAAC;QAC/C,IAAI,CAAC,GAAG,CAAC,aAAa,EAAE,CAAC;KAC1B;IAED,QAAQ,CAAC,MAA2B;;QAClC,IAAI,MAAM,CAAC,OAAO,KAAK,MAAM,IAAI,QAAQ,CAAC,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,EAAE;YACjE,MAAA,MAAA,IAAI,CAAC,YAAY,CAAC,GAAG,0CAAE,UAAU,0CAAE,MAAM,EAAE,CAAC;SAC7C;KACF;IAED,OAAO,CAAC,IAAyB;QAC/B,IAAI,CAAC,SAAS,IAAI,IAAI,CAAC,SAAS,CAAC,WAAW,EAAE,CAAC;KAChD;IAED,OAAO,CAAC,IAAyB;QAC/B,IAAI,IAAI,CAAC,QAAQ,EAAE;YACjB,IAAI,CAAC,SAAS,GAAG,EAAE,CAAC,IAAI,CAAC;iBACtB,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;iBAC1B,SAAS,CAAC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AW,EAAE,CAAC;aACpD,CAAC,CAAC;SACN;KACF;IAEO,kBAAkB,CAAC,MAA2B;;QACpD,IAAI,OAAO,MAAM,CAAC,SAAS,KAAK,WAAW;YAAE,OAAO;QACpD,MAAA,MAAA,IAAI,CAAC,aAAa,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,GAAG,0CAAE,YAAY,0CAAE,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;KAClF;;oIA3FU,oBAAoB;wIAApB,oBAAoB;2FAApB,oBAAoB;kBADhC,UAAU;;;MCFE,mBAAmB;;mIAAnB,mBAAmB;oIAAnB,mBAAmB,iBALf,sBAAsB,aAE3B,YAAY,EAAE,aAAa,EAAE,YAAY,aADzC,sBAAsB;oIAIrB,mBAAmB,aAFnB,CAAC,oBAAoB,CAAC,YADxB,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;2FAGzC,mBAAmB;kBAN/B,QAAQ;mBAAC;oBACR,YAAY,EAAE,CAAC,sBAAsB,CAAC;oBACtC,OAAO,EAAE,CAAC,sBAAsB,CAAC;oBACjC,OAAO,EAAE,CAAC,YAAY,EAAE,aAAa,EAAE,YAAY,CAAC;oBACpD,SAAS,EAAE,CAAC,oBAAoB,CAAC;iBAClC;;;ACZD;;;;;;"}
@@ -63,9 +63,9 @@ class XOutletDirective {
63
63
  }
64
64
  }
65
65
  }
66
- /** @nocollapse */ XOutletDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XOutletDirective, deps: [{ token: i0.ViewContainerRef }, { token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
67
- /** @nocollapse */ XOutletDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.0.3", type: XOutletDirective, selector: "[xOutlet]", inputs: { xOutletContext: "xOutletContext", xOutlet: "xOutlet" }, usesOnChanges: true, ngImport: i0 });
68
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XOutletDirective, decorators: [{
66
+ /** @nocollapse */ XOutletDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XOutletDirective, deps: [{ token: i0.ViewContainerRef }, { token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive });
67
+ /** @nocollapse */ XOutletDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.0.5", type: XOutletDirective, selector: "[xOutlet]", inputs: { xOutletContext: "xOutletContext", xOutlet: "xOutlet" }, usesOnChanges: true, ngImport: i0 });
68
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XOutletDirective, decorators: [{
69
69
  type: Directive,
70
70
  args: [{ selector: '[xOutlet]' }]
71
71
  }], ctorParameters: function () { return [{ type: i0.ViewContainerRef }, { type: i0.TemplateRef }]; }, propDecorators: { xOutletContext: [{
@@ -76,10 +76,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImpor
76
76
 
77
77
  class XOutletModule {
78
78
  }
79
- /** @nocollapse */ XOutletModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XOutletModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
80
- /** @nocollapse */ XOutletModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XOutletModule, declarations: [XOutletDirective], imports: [CommonModule], exports: [XOutletDirective] });
81
- /** @nocollapse */ XOutletModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XOutletModule, imports: [[CommonModule]] });
82
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XOutletModule, decorators: [{
79
+ /** @nocollapse */ XOutletModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XOutletModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
80
+ /** @nocollapse */ XOutletModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XOutletModule, declarations: [XOutletDirective], imports: [CommonModule], exports: [XOutletDirective] });
81
+ /** @nocollapse */ XOutletModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XOutletModule, imports: [[CommonModule]] });
82
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XOutletModule, decorators: [{
83
83
  type: NgModule,
84
84
  args: [{
85
85
  declarations: [XOutletDirective],
@@ -30,15 +30,15 @@ class XPageHeaderProperty {
30
30
  this.backClick = new EventEmitter();
31
31
  }
32
32
  }
33
- /** @nocollapse */ XPageHeaderProperty.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderProperty, deps: [], target: i0.ɵɵFactoryTarget.Component });
34
- /** @nocollapse */ XPageHeaderProperty.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.3", type: XPageHeaderProperty, selector: "ng-component", inputs: { backIcon: "backIcon", backText: "backText", title: "title", subTitle: "subTitle" }, outputs: { backClick: "backClick" }, ngImport: i0, template: '', isInline: true });
33
+ /** @nocollapse */ XPageHeaderProperty.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderProperty, deps: [], target: i0.ɵɵFactoryTarget.Component });
34
+ /** @nocollapse */ XPageHeaderProperty.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: XPageHeaderProperty, selector: "ng-component", inputs: { backIcon: "backIcon", backText: "backText", title: "title", subTitle: "subTitle" }, outputs: { backClick: "backClick" }, ngImport: i0, template: '', isInline: true });
35
35
  __decorate([
36
36
  XWithConfig(X_CONFIG_NAME, 'fto-arrow-left')
37
37
  ], XPageHeaderProperty.prototype, "backIcon", void 0);
38
38
  __decorate([
39
39
  XWithConfig(X_CONFIG_NAME)
40
40
  ], XPageHeaderProperty.prototype, "backText", void 0);
41
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderProperty, decorators: [{
41
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderProperty, decorators: [{
42
42
  type: Component,
43
43
  args: [{ template: '' }]
44
44
  }], propDecorators: { backIcon: [{
@@ -78,9 +78,9 @@ class XPageHeaderComponent extends XPageHeaderProperty {
78
78
  this._unSubject.unsubscribe();
79
79
  }
80
80
  }
81
- /** @nocollapse */ XPageHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderComponent, deps: [{ token: i1.XConfigService }, { token: i0.ChangeDetectorRef }, { token: i2.XI18nService }], target: i0.ɵɵFactoryTarget.Component });
82
- /** @nocollapse */ XPageHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.3", type: XPageHeaderComponent, selector: "x-page-header", usesInheritance: true, ngImport: i0, template: "<div class=\"x-page-header\">\r\n <x-button class=\"x-page-header-backIcon\" [icon]=\"backIcon\" type=\"text\" (click)=\"backClick.emit()\">{{ getBackText }}</x-button>\r\n <span class=\"x-page-header-divided\"></span>\r\n <span class=\"x-page-header-title\" *ngIf=\"title\">{{ title }}</span>\r\n <span class=\"x-page-header-subTitle\" *ngIf=\"subTitle\">{{ subTitle }}</span>\r\n</div>\r\n", styles: [".x-page-header{margin:0;padding:0;display:inline-flex;align-items:center;height:var(--x-height-large)}.x-page-header-backIcon .x-button{font-size:.875rem}.x-page-header-divided{margin:0 .875rem 0 .25rem;height:1rem;border-right:var(--x-border-width) var(--x-border-style) var(--x-border)}.x-page-header-title{font-size:1rem}.x-page-header-subTitle{font-size:.75rem;color:var(--x-text-400);margin-left:.5rem}"], components: [{ type: i3.XButtonComponent, selector: "x-button" }], directives: [{ type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
83
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderComponent, decorators: [{
81
+ /** @nocollapse */ XPageHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderComponent, deps: [{ token: i1.XConfigService }, { token: i0.ChangeDetectorRef }, { token: i2.XI18nService }], target: i0.ɵɵFactoryTarget.Component });
82
+ /** @nocollapse */ XPageHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: XPageHeaderComponent, selector: "x-page-header", usesInheritance: true, ngImport: i0, template: "<div class=\"x-page-header\">\r\n <x-button class=\"x-page-header-backIcon\" [icon]=\"backIcon\" type=\"text\" (click)=\"backClick.emit()\">{{ getBackText }}</x-button>\r\n <span class=\"x-page-header-divided\"></span>\r\n <span class=\"x-page-header-title\" *ngIf=\"title\">{{ title }}</span>\r\n <span class=\"x-page-header-subTitle\" *ngIf=\"subTitle\">{{ subTitle }}</span>\r\n</div>\r\n", styles: [".x-page-header{margin:0;padding:0;display:inline-flex;align-items:center;height:var(--x-height-large)}.x-page-header-backIcon .x-button{font-size:.875rem}.x-page-header-divided{margin:0 .875rem 0 .25rem;height:1rem;border-right:var(--x-border-width) var(--x-border-style) var(--x-border)}.x-page-header-title{font-size:1rem}.x-page-header-subTitle{font-size:.75rem;color:var(--x-text-400);margin-left:.5rem}\n"], components: [{ type: i3.XButtonComponent, selector: "x-button" }], directives: [{ type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
83
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderComponent, decorators: [{
84
84
  type: Component,
85
85
  args: [{
86
86
  selector: `${XPageHeaderPrefix}`,
@@ -93,10 +93,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImpor
93
93
 
94
94
  class XPageHeaderModule {
95
95
  }
96
- /** @nocollapse */ XPageHeaderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
97
- /** @nocollapse */ XPageHeaderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderModule, declarations: [XPageHeaderComponent, XPageHeaderProperty], imports: [CommonModule, XButtonModule], exports: [XPageHeaderComponent] });
98
- /** @nocollapse */ XPageHeaderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderModule, imports: [[CommonModule, XButtonModule]] });
99
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPageHeaderModule, decorators: [{
96
+ /** @nocollapse */ XPageHeaderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
97
+ /** @nocollapse */ XPageHeaderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderModule, declarations: [XPageHeaderComponent, XPageHeaderProperty], imports: [CommonModule, XButtonModule], exports: [XPageHeaderComponent] });
98
+ /** @nocollapse */ XPageHeaderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderModule, imports: [[CommonModule, XButtonModule]] });
99
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPageHeaderModule, decorators: [{
100
100
  type: NgModule,
101
101
  args: [{
102
102
  declarations: [XPageHeaderComponent, XPageHeaderProperty],
@@ -5,12 +5,21 @@ import * as i1 from '@ng-nest/ui/core';
5
5
  import { XProperty, XWithConfig, XInputNumber, XInputBoolean, XIsChange } from '@ng-nest/ui/core';
6
6
  import { Subject } from 'rxjs';
7
7
  import { takeUntil } from 'rxjs/operators';
8
+ import { ENTER } from '@angular/cdk/keycodes';
8
9
  import * as i2 from '@ng-nest/ui/i18n';
9
10
  import { XI18nModule } from '@ng-nest/ui/i18n';
10
11
  import * as i3 from '@ng-nest/ui/button';
11
12
  import { XButtonModule } from '@ng-nest/ui/button';
12
- import * as i4 from '@angular/common';
13
+ import * as i4 from '@ng-nest/ui/input';
14
+ import { XInputModule } from '@ng-nest/ui/input';
15
+ import * as i5 from '@ng-nest/ui/select';
16
+ import { XSelectModule } from '@ng-nest/ui/select';
17
+ import * as i6 from '@angular/common';
13
18
  import { CommonModule } from '@angular/common';
19
+ import * as i7 from '@ng-nest/ui/outlet';
20
+ import { XOutletModule } from '@ng-nest/ui/outlet';
21
+ import * as i8 from '@angular/forms';
22
+ import { FormsModule } from '@angular/forms';
14
23
 
15
24
  /**
16
25
  * Pagination
@@ -52,8 +61,8 @@ class XPaginationProperty extends XProperty {
52
61
  this.sizeChange = new EventEmitter();
53
62
  }
54
63
  }
55
- /** @nocollapse */ XPaginationProperty.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationProperty, deps: null, target: i0.ɵɵFactoryTarget.Component });
56
- /** @nocollapse */ XPaginationProperty.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.3", type: XPaginationProperty, selector: "ng-component", inputs: { index: "index", size: "size", total: "total", query: "query", pageLinkSize: "pageLinkSize", showEllipsis: "showEllipsis", showTotal: "showTotal", space: "space", hiddenBorder: "hiddenBorder" }, outputs: { queryChange: "queryChange", indexChange: "indexChange", sizeChange: "sizeChange" }, usesInheritance: true, ngImport: i0, template: '', isInline: true });
64
+ /** @nocollapse */ XPaginationProperty.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationProperty, deps: null, target: i0.ɵɵFactoryTarget.Component });
65
+ /** @nocollapse */ XPaginationProperty.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: XPaginationProperty, selector: "ng-component", inputs: { index: "index", size: "size", total: "total", query: "query", pageLinkSize: "pageLinkSize", showEllipsis: "showEllipsis", showTotal: "showTotal", space: "space", hiddenBorder: "hiddenBorder", showSize: "showSize", sizeWidth: "sizeWidth", sizeData: "sizeData", disabled: "disabled", showJump: "showJump", jumpWidth: "jumpWidth", totalTpl: "totalTpl", simple: "simple", simpleIndexWidth: "simpleIndexWidth" }, outputs: { queryChange: "queryChange", indexChange: "indexChange", sizeChange: "sizeChange" }, usesInheritance: true, ngImport: i0, template: '', isInline: true });
57
66
  __decorate([
58
67
  XWithConfig(X_CONFIG_NAME, 1),
59
68
  XInputNumber()
@@ -85,7 +94,37 @@ __decorate([
85
94
  XWithConfig(X_CONFIG_NAME, false),
86
95
  XInputBoolean()
87
96
  ], XPaginationProperty.prototype, "hiddenBorder", void 0);
88
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationProperty, decorators: [{
97
+ __decorate([
98
+ XWithConfig(X_CONFIG_NAME, false),
99
+ XInputBoolean()
100
+ ], XPaginationProperty.prototype, "showSize", void 0);
101
+ __decorate([
102
+ XWithConfig(X_CONFIG_NAME, 100),
103
+ XInputNumber()
104
+ ], XPaginationProperty.prototype, "sizeWidth", void 0);
105
+ __decorate([
106
+ XWithConfig(X_CONFIG_NAME, [10, 20, 50, 100])
107
+ ], XPaginationProperty.prototype, "sizeData", void 0);
108
+ __decorate([
109
+ XInputBoolean()
110
+ ], XPaginationProperty.prototype, "disabled", void 0);
111
+ __decorate([
112
+ XWithConfig(X_CONFIG_NAME, false),
113
+ XInputBoolean()
114
+ ], XPaginationProperty.prototype, "showJump", void 0);
115
+ __decorate([
116
+ XWithConfig(X_CONFIG_NAME, 50),
117
+ XInputNumber()
118
+ ], XPaginationProperty.prototype, "jumpWidth", void 0);
119
+ __decorate([
120
+ XWithConfig(X_CONFIG_NAME, false),
121
+ XInputBoolean()
122
+ ], XPaginationProperty.prototype, "simple", void 0);
123
+ __decorate([
124
+ XWithConfig(X_CONFIG_NAME, 130),
125
+ XInputNumber()
126
+ ], XPaginationProperty.prototype, "simpleIndexWidth", void 0);
127
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationProperty, decorators: [{
89
128
  type: Component,
90
129
  args: [{ template: '' }]
91
130
  }], propDecorators: { index: [{
@@ -106,6 +145,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImpor
106
145
  type: Input
107
146
  }], hiddenBorder: [{
108
147
  type: Input
148
+ }], showSize: [{
149
+ type: Input
150
+ }], sizeWidth: [{
151
+ type: Input
152
+ }], sizeData: [{
153
+ type: Input
154
+ }], disabled: [{
155
+ type: Input
156
+ }], showJump: [{
157
+ type: Input
158
+ }], jumpWidth: [{
159
+ type: Input
160
+ }], totalTpl: [{
161
+ type: Input
162
+ }], simple: [{
163
+ type: Input
164
+ }], simpleIndexWidth: [{
165
+ type: Input
109
166
  }], queryChange: [{
110
167
  type: Output
111
168
  }], indexChange: [{
@@ -125,6 +182,7 @@ class XPaginationComponent extends XPaginationProperty {
125
182
  this.indexes = [];
126
183
  this.indexFirst = 1;
127
184
  this.indexLast = 1;
185
+ this.jumpPage = null;
128
186
  this._unSubject = new Subject();
129
187
  this.renderer.addClass(this.elementRef.nativeElement, XPaginationPrefix);
130
188
  }
@@ -144,12 +202,17 @@ class XPaginationComponent extends XPaginationProperty {
144
202
  this.i18n.localeChange.pipe(takeUntil(this._unSubject)).subscribe(() => this.cdr.markForCheck());
145
203
  }
146
204
  ngOnChanges(changes) {
147
- XIsChange(changes.total, changes.size, changes.index) && this.setIndexes();
205
+ const { total, size, index } = changes;
206
+ XIsChange(total, size, index) && this.setIndexes();
148
207
  }
149
208
  ngOnDestory() {
150
209
  this._unSubject.next();
151
210
  this._unSubject.unsubscribe();
152
211
  }
212
+ sizeChanged() {
213
+ this.setIndexes();
214
+ this.sizeChange.emit(this.size);
215
+ }
153
216
  setIndexes() {
154
217
  this.lastIndex = Math.ceil(Number(this.total) / Number(this.size)) || 1;
155
218
  const indexes = [];
@@ -173,6 +236,33 @@ class XPaginationComponent extends XPaginationProperty {
173
236
  this.indexChange.emit(this.index);
174
237
  }
175
238
  }
239
+ onKeydown(event) {
240
+ if (this.jumpPage !== null && event.keyCode === ENTER) {
241
+ if (this.jumpPage <= this.indexFirst) {
242
+ this.jump(this.indexFirst);
243
+ }
244
+ else if (this.jumpPage >= this.lastIndex) {
245
+ this.jump(this.lastIndex);
246
+ }
247
+ else {
248
+ this.jump(this.jumpPage);
249
+ }
250
+ this.jumpPage = null;
251
+ this.cdr.detectChanges();
252
+ }
253
+ }
254
+ onSimpleKeydown(event) {
255
+ if (this.index !== null && event.keyCode === ENTER) {
256
+ if (this.index <= this.indexFirst) {
257
+ this.index = this.indexFirst;
258
+ }
259
+ else if (this.index >= this.lastIndex) {
260
+ this.index = this.lastIndex;
261
+ }
262
+ this.jump(this.index);
263
+ this.cdr.detectChanges();
264
+ }
265
+ }
176
266
  validateIndex(value) {
177
267
  if (value > this.lastIndex) {
178
268
  return this.lastIndex;
@@ -187,13 +277,13 @@ class XPaginationComponent extends XPaginationProperty {
187
277
  getActivated(index) {
188
278
  return Number(this.index) === index;
189
279
  }
190
- trackByItem(index, item) {
280
+ trackByItem(_index, item) {
191
281
  return item;
192
282
  }
193
283
  }
194
- /** @nocollapse */ XPaginationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationComponent, deps: [{ token: i1.XConfigService }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i2.XI18nService }], target: i0.ɵɵFactoryTarget.Component });
195
- /** @nocollapse */ XPaginationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.3", type: XPaginationComponent, selector: "x-pagination", usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<x-buttons [space]=\"space\" [hiddenBorder]=\"hiddenBorder\">\r\n <x-button *ngIf=\"showEllipsis\" [icon]=\"'fto-chevrons-left'\" [disabled]=\"firstActivated\" (click)=\"jump(1)\"></x-button>\r\n <x-button\r\n [icon]=\"'fto-chevron-left'\"\r\n [title]=\"'pagination.previous' | xI18n\"\r\n [disabled]=\"leftDisabled\"\r\n (click)=\"jump(-1, true)\"\r\n ></x-button>\r\n <x-button *ngFor=\"let item of indexes; trackBy: trackByItem\" [activated]=\"getActivated(item)\" (click)=\"jump(item)\">{{ item }}</x-button>\r\n <x-button [icon]=\"'fto-chevron-right'\" [title]=\"'pagination.next' | xI18n\" [disabled]=\"rightDisabled\" (click)=\"jump(1, true)\"></x-button>\r\n <x-button *ngIf=\"showEllipsis\" [icon]=\"'fto-chevrons-right'\" [disabled]=\"lastActivated\" (click)=\"jump(lastIndex)\"></x-button>\r\n</x-buttons>\r\n<x-button *ngIf=\"showTotal\" class=\"x-pagination-total\" [type]=\"hiddenBorder === true ? 'text' : 'initial'\"\r\n >{{ 'pagination.total' | xI18n }} {{ total }} {{ 'pagination.item' | xI18n }}</x-button\r\n>\r\n", styles: [".x-pagination{margin:0;padding:0;display:inline-flex}.x-pagination>.x-buttons.x-buttons-hiddenBorder>x-button>.x-button{min-width:1.75rem}.x-pagination>.x-buttons.x-buttons-hiddenBorder>x-button>.x-button-activated{background-color:#0000000d}.x-pagination-total{margin-left:.5rem}"], components: [{ type: i3.XButtonsComponent, selector: "x-buttons" }, { type: i3.XButtonComponent, selector: "x-button" }], directives: [{ type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "xI18n": i2.XI18nPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
196
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationComponent, decorators: [{
284
+ /** @nocollapse */ XPaginationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationComponent, deps: [{ token: i1.XConfigService }, { token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i2.XI18nService }], target: i0.ɵɵFactoryTarget.Component });
285
+ /** @nocollapse */ XPaginationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: XPaginationComponent, selector: "x-pagination", usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<x-buttons *ngIf=\"!simple; else simpleTpl\" [space]=\"space\" [hiddenBorder]=\"hiddenBorder\">\r\n <x-button\r\n *ngIf=\"showEllipsis\"\r\n [icon]=\"'fto-chevrons-left'\"\r\n [title]=\"'pagination.first' | xI18n\"\r\n [disabled]=\"disabled || firstActivated\"\r\n (click)=\"jump(1)\"\r\n ></x-button>\r\n <ng-container *xOutlet=\"previousTpl\"></ng-container>\r\n <x-button\r\n *ngFor=\"let item of indexes; trackBy: trackByItem\"\r\n [disabled]=\"disabled\"\r\n [activated]=\"getActivated(item)\"\r\n (click)=\"jump(item)\"\r\n >{{ item }}</x-button\r\n >\r\n <ng-container *xOutlet=\"nextTpl\"></ng-container>\r\n <x-button\r\n *ngIf=\"showEllipsis && !simple\"\r\n [icon]=\"'fto-chevrons-right'\"\r\n [title]=\"'pagination.last' | xI18n\"\r\n [disabled]=\"disabled || lastActivated\"\r\n (click)=\"jump(lastIndex)\"\r\n ></x-button>\r\n</x-buttons>\r\n<ng-template #simpleTpl>\r\n <div class=\"x-pagination-simple\">\r\n <x-input\r\n [bordered]=\"!hiddenBorder\"\r\n [before]=\"previousTpl\"\r\n [after]=\"nextTpl\"\r\n [style.width.px]=\"simpleIndexWidth\"\r\n [(ngModel)]=\"index\"\r\n (xKeydown)=\"onSimpleKeydown($event)\"\r\n ></x-input>\r\n <span>/</span>\r\n <span>{{ lastIndex }}</span>\r\n </div>\r\n</ng-template>\r\n<x-select\r\n *ngIf=\"showSize\"\r\n [style.width.px]=\"sizeWidth\"\r\n class=\"x-pagination-size\"\r\n [data]=\"sizeData\"\r\n clearable=\"false\"\r\n [disabled]=\"disabled\"\r\n [bordered]=\"!hiddenBorder\"\r\n [nodeTpl]=\"nodeTpl\"\r\n [(ngModel)]=\"size\"\r\n (ngModelChange)=\"sizeChanged()\"\r\n></x-select>\r\n<div *ngIf=\"showJump && !simple\" class=\"x-pagination-jump\">\r\n <span>{{ 'pagination.jump' | xI18n }}</span>\r\n <x-input [bordered]=\"!hiddenBorder\" [style.width.px]=\"jumpWidth\" [(ngModel)]=\"jumpPage\" (xKeydown)=\"onKeydown($event)\"></x-input>\r\n</div>\r\n<x-button *ngIf=\"showTotal\" [disabled]=\"disabled\" class=\"x-pagination-total\" [type]=\"hiddenBorder === true ? 'text' : 'initial'\"\r\n ><ng-container *xOutlet=\"totalTpl; context: { $total: total }\"\r\n >{{ 'pagination.total' | xI18n }} {{ total }} {{ 'pagination.item' | xI18n }}</ng-container\r\n ></x-button\r\n>\r\n\r\n<ng-template #previousTpl>\r\n <x-button\r\n [icon]=\"'fto-chevron-left'\"\r\n [title]=\"'pagination.previous' | xI18n\"\r\n [disabled]=\"disabled || leftDisabled\"\r\n (click)=\"jump(-1, true)\"\r\n ></x-button>\r\n</ng-template>\r\n\r\n<ng-template #nextTpl>\r\n <x-button\r\n [icon]=\"'fto-chevron-right'\"\r\n [title]=\"'pagination.next' | xI18n\"\r\n [disabled]=\"disabled || rightDisabled\"\r\n (click)=\"jump(1, true)\"\r\n ></x-button>\r\n</ng-template>\r\n\r\n<ng-template #nodeTpl let-node=\"$node\">\r\n <ng-container *ngIf=\"node\"> {{ node?.label }} {{ 'pagination.sizePage' | xI18n }} </ng-container>\r\n</ng-template>\r\n", styles: [".x-pagination{margin:0;padding:0;display:inline-flex}.x-pagination>.x-buttons.x-buttons-hiddenBorder>x-button>.x-button{min-width:1.75rem}.x-pagination>.x-buttons.x-buttons-hiddenBorder>x-button>.x-button-activated{background-color:#0000000d}.x-pagination-size{margin-left:.5rem}.x-pagination-total{margin-left:.5rem}.x-pagination-jump{margin-left:.5rem;display:inline-flex;align-items:center}.x-pagination-jump x-input{margin-left:.5rem}.x-pagination-simple{margin:0 .5rem;display:inline-flex;align-items:center}.x-pagination-simple>x-input input{text-align:center}.x-pagination-simple>span{margin-left:.5rem}\n"], components: [{ type: i3.XButtonsComponent, selector: "x-buttons" }, { type: i3.XButtonComponent, selector: "x-button" }, { type: i4.XInputComponent, selector: "x-input" }, { type: i5.XSelectComponent, selector: "x-select" }], directives: [{ type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i7.XOutletDirective, selector: "[xOutlet]", inputs: ["xOutletContext", "xOutlet"] }, { type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i8.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i8.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], pipes: { "xI18n": i2.XI18nPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
286
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationComponent, decorators: [{
197
287
  type: Component,
198
288
  args: [{
199
289
  selector: `${XPaginationPrefix}`,
@@ -206,15 +296,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImpor
206
296
 
207
297
  class XPaginationModule {
208
298
  }
209
- /** @nocollapse */ XPaginationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
210
- /** @nocollapse */ XPaginationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationModule, declarations: [XPaginationComponent, XPaginationProperty], imports: [CommonModule, XButtonModule, XI18nModule], exports: [XPaginationComponent] });
211
- /** @nocollapse */ XPaginationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationModule, imports: [[CommonModule, XButtonModule, XI18nModule]] });
212
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.3", ngImport: i0, type: XPaginationModule, decorators: [{
299
+ /** @nocollapse */ XPaginationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
300
+ /** @nocollapse */ XPaginationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationModule, declarations: [XPaginationComponent, XPaginationProperty], imports: [CommonModule, FormsModule, XButtonModule, XI18nModule, XSelectModule, XInputModule, XOutletModule], exports: [XPaginationComponent] });
301
+ /** @nocollapse */ XPaginationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationModule, imports: [[CommonModule, FormsModule, XButtonModule, XI18nModule, XSelectModule, XInputModule, XOutletModule]] });
302
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: XPaginationModule, decorators: [{
213
303
  type: NgModule,
214
304
  args: [{
215
305
  declarations: [XPaginationComponent, XPaginationProperty],
216
306
  exports: [XPaginationComponent],
217
- imports: [CommonModule, XButtonModule, XI18nModule]
307
+ imports: [CommonModule, FormsModule, XButtonModule, XI18nModule, XSelectModule, XInputModule, XOutletModule]
218
308
  }]
219
309
  }] });
220
310