mis-crystal-design-system 2.5.0 → 2.5.3

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 (306) hide show
  1. package/action-list/action-list.component.d.ts +0 -1
  2. package/action-list/index.d.ts +1 -1
  3. package/action-list/mis-crystal-design-system-action-list.metadata.json +1 -1
  4. package/action-list/public_api.d.ts +2 -2
  5. package/async-search-dropdown/async-dropdown.component.d.ts +4 -4
  6. package/async-search-dropdown/index.d.ts +1 -1
  7. package/async-search-dropdown/mis-crystal-design-system-async-search-dropdown.metadata.json +1 -1
  8. package/async-search-dropdown/public_api.d.ts +2 -2
  9. package/bundles/mis-crystal-design-system-action-list.umd.js +3 -11
  10. package/bundles/mis-crystal-design-system-action-list.umd.js.map +1 -1
  11. package/bundles/mis-crystal-design-system-action-list.umd.min.js +1 -1
  12. package/bundles/mis-crystal-design-system-action-list.umd.min.js.map +1 -1
  13. package/bundles/mis-crystal-design-system-async-search-dropdown.umd.js +15 -15
  14. package/bundles/mis-crystal-design-system-async-search-dropdown.umd.js.map +1 -1
  15. package/bundles/mis-crystal-design-system-async-search-dropdown.umd.min.js +1 -1
  16. package/bundles/mis-crystal-design-system-async-search-dropdown.umd.min.js.map +1 -1
  17. package/bundles/mis-crystal-design-system-button.umd.js +25 -25
  18. package/bundles/mis-crystal-design-system-button.umd.js.map +1 -1
  19. package/bundles/mis-crystal-design-system-button.umd.min.js +1 -1
  20. package/bundles/mis-crystal-design-system-button.umd.min.js.map +1 -1
  21. package/bundles/mis-crystal-design-system-checkbox.umd.js +5 -6
  22. package/bundles/mis-crystal-design-system-checkbox.umd.js.map +1 -1
  23. package/bundles/mis-crystal-design-system-checkbox.umd.min.js.map +1 -1
  24. package/bundles/mis-crystal-design-system-chip.umd.js +6 -7
  25. package/bundles/mis-crystal-design-system-chip.umd.js.map +1 -1
  26. package/bundles/mis-crystal-design-system-chip.umd.min.js +1 -1
  27. package/bundles/mis-crystal-design-system-chip.umd.min.js.map +1 -1
  28. package/bundles/mis-crystal-design-system-datepicker_v2.umd.js +27 -24
  29. package/bundles/mis-crystal-design-system-datepicker_v2.umd.js.map +1 -1
  30. package/bundles/mis-crystal-design-system-datepicker_v2.umd.min.js +2 -2
  31. package/bundles/mis-crystal-design-system-datepicker_v2.umd.min.js.map +1 -1
  32. package/bundles/mis-crystal-design-system-daterangepicker_v2.umd.js +27 -50
  33. package/bundles/mis-crystal-design-system-daterangepicker_v2.umd.js.map +1 -1
  34. package/bundles/mis-crystal-design-system-daterangepicker_v2.umd.min.js +1 -1
  35. package/bundles/mis-crystal-design-system-daterangepicker_v2.umd.min.js.map +1 -1
  36. package/bundles/mis-crystal-design-system-drawer.umd.js +9 -12
  37. package/bundles/mis-crystal-design-system-drawer.umd.js.map +1 -1
  38. package/bundles/mis-crystal-design-system-drawer.umd.min.js.map +1 -1
  39. package/bundles/mis-crystal-design-system-dropdown.umd.js +2 -9
  40. package/bundles/mis-crystal-design-system-dropdown.umd.js.map +1 -1
  41. package/bundles/mis-crystal-design-system-dropdown.umd.min.js +1 -1
  42. package/bundles/mis-crystal-design-system-dropdown.umd.min.js.map +1 -1
  43. package/bundles/mis-crystal-design-system-fab.umd.js +11 -14
  44. package/bundles/mis-crystal-design-system-fab.umd.js.map +1 -1
  45. package/bundles/mis-crystal-design-system-fab.umd.min.js.map +1 -1
  46. package/bundles/mis-crystal-design-system-input.umd.js +7 -7
  47. package/bundles/mis-crystal-design-system-input.umd.js.map +1 -1
  48. package/bundles/mis-crystal-design-system-input.umd.min.js +1 -1
  49. package/bundles/mis-crystal-design-system-input.umd.min.js.map +1 -1
  50. package/bundles/mis-crystal-design-system-loader.umd.js +3 -4
  51. package/bundles/mis-crystal-design-system-loader.umd.js.map +1 -1
  52. package/bundles/mis-crystal-design-system-loader.umd.min.js +1 -1
  53. package/bundles/mis-crystal-design-system-loader.umd.min.js.map +1 -1
  54. package/bundles/mis-crystal-design-system-modal.umd.js +8 -12
  55. package/bundles/mis-crystal-design-system-modal.umd.js.map +1 -1
  56. package/bundles/mis-crystal-design-system-modal.umd.min.js.map +1 -1
  57. package/bundles/mis-crystal-design-system-multi-select-dropdown.umd.js +2 -9
  58. package/bundles/mis-crystal-design-system-multi-select-dropdown.umd.js.map +1 -1
  59. package/bundles/mis-crystal-design-system-multi-select-dropdown.umd.min.js +1 -1
  60. package/bundles/mis-crystal-design-system-multi-select-dropdown.umd.min.js.map +1 -1
  61. package/bundles/mis-crystal-design-system-nested-multi-select-dropdown.umd.js +2 -9
  62. package/bundles/mis-crystal-design-system-nested-multi-select-dropdown.umd.js.map +1 -1
  63. package/bundles/mis-crystal-design-system-nested-multi-select-dropdown.umd.min.js +1 -1
  64. package/bundles/mis-crystal-design-system-nested-multi-select-dropdown.umd.min.js.map +1 -1
  65. package/bundles/mis-crystal-design-system-radio-button.umd.js +6 -7
  66. package/bundles/mis-crystal-design-system-radio-button.umd.js.map +1 -1
  67. package/bundles/mis-crystal-design-system-radio-button.umd.min.js +1 -1
  68. package/bundles/mis-crystal-design-system-radio-button.umd.min.js.map +1 -1
  69. package/bundles/mis-crystal-design-system-switch.umd.js +3 -4
  70. package/bundles/mis-crystal-design-system-switch.umd.js.map +1 -1
  71. package/bundles/mis-crystal-design-system-switch.umd.min.js +1 -1
  72. package/bundles/mis-crystal-design-system-switch.umd.min.js.map +1 -1
  73. package/bundles/mis-crystal-design-system-table.umd.js +40 -58
  74. package/bundles/mis-crystal-design-system-table.umd.js.map +1 -1
  75. package/bundles/mis-crystal-design-system-table.umd.min.js +1 -1
  76. package/bundles/mis-crystal-design-system-table.umd.min.js.map +1 -1
  77. package/bundles/mis-crystal-design-system-toast.umd.js +28 -33
  78. package/bundles/mis-crystal-design-system-toast.umd.js.map +1 -1
  79. package/bundles/mis-crystal-design-system-toast.umd.min.js +1 -1
  80. package/bundles/mis-crystal-design-system-toast.umd.min.js.map +1 -1
  81. package/bundles/mis-crystal-design-system-tooltip.umd.js +1 -1
  82. package/bundles/mis-crystal-design-system-tooltip.umd.js.map +1 -1
  83. package/bundles/mis-crystal-design-system-tooltip.umd.min.js +1 -1
  84. package/bundles/mis-crystal-design-system-tooltip.umd.min.js.map +1 -1
  85. package/bundles/mis-crystal-design-system.umd.js.map +1 -1
  86. package/button/button.component.d.ts +4 -4
  87. package/button/button.directive.d.ts +3 -3
  88. package/button/button.directive.scss +1 -1
  89. package/button/button.module.d.ts +1 -1
  90. package/button/index.d.ts +1 -1
  91. package/button/mis-crystal-design-system-button.metadata.json +1 -1
  92. package/button/public_api.d.ts +2 -2
  93. package/checkbox/checkbox.component.d.ts +3 -3
  94. package/checkbox/checkbox.module.d.ts +1 -1
  95. package/checkbox/index.d.ts +1 -1
  96. package/checkbox/mis-crystal-design-system-checkbox.metadata.json +1 -1
  97. package/checkbox/public_api.d.ts +2 -2
  98. package/chip/chip.component.d.ts +2 -2
  99. package/chip/chip.module.d.ts +1 -1
  100. package/chip/index.d.ts +1 -1
  101. package/chip/mis-crystal-design-system-chip.metadata.json +1 -1
  102. package/chip/public_api.d.ts +2 -2
  103. package/datepicker_v2/index.d.ts +1 -1
  104. package/datepicker_v2/mis-crystal-design-system-datepicker_v2.metadata.json +1 -1
  105. package/datepicker_v2/public_api.d.ts +3 -3
  106. package/daterangepicker_v2/index.d.ts +1 -1
  107. package/daterangepicker_v2/mis-crystal-design-system-daterangepicker_v2.metadata.json +1 -1
  108. package/daterangepicker_v2/public_api.d.ts +3 -3
  109. package/drawer/index.d.ts +1 -1
  110. package/drawer/mis-crystal-design-system-drawer.metadata.json +1 -1
  111. package/drawer/public_api.d.ts +4 -4
  112. package/dropdown/dropdown.component.d.ts +0 -1
  113. package/dropdown/dropdown.module.d.ts +1 -1
  114. package/dropdown/index.d.ts +1 -1
  115. package/dropdown/mis-crystal-design-system-dropdown.metadata.json +1 -1
  116. package/dropdown/public_api.d.ts +2 -2
  117. package/esm2015/action-list/action-list.component.js +4 -12
  118. package/esm2015/action-list/action-list.module.js +3 -2
  119. package/esm2015/action-list/index.js +2 -2
  120. package/esm2015/action-list/public_api.js +3 -3
  121. package/esm2015/async-search-dropdown/async-dropdown.component.js +25 -25
  122. package/esm2015/async-search-dropdown/async-dropdown.module.js +7 -7
  123. package/esm2015/async-search-dropdown/index.js +2 -2
  124. package/esm2015/async-search-dropdown/public_api.js +3 -3
  125. package/esm2015/button/button.component.js +10 -10
  126. package/esm2015/button/button.directive.js +19 -19
  127. package/esm2015/button/button.module.js +5 -5
  128. package/esm2015/button/index.js +2 -2
  129. package/esm2015/button/public_api.js +3 -3
  130. package/esm2015/checkbox/checkbox.component.js +8 -9
  131. package/esm2015/checkbox/checkbox.module.js +5 -5
  132. package/esm2015/checkbox/index.js +2 -2
  133. package/esm2015/checkbox/public_api.js +3 -3
  134. package/esm2015/chip/chip.component.js +8 -9
  135. package/esm2015/chip/chip.module.js +4 -4
  136. package/esm2015/chip/index.js +2 -2
  137. package/esm2015/chip/public_api.js +3 -3
  138. package/esm2015/datepicker_v2/datepicker-constants.js +2 -2
  139. package/esm2015/datepicker_v2/datepicker.module.js +5 -4
  140. package/esm2015/datepicker_v2/index.js +2 -2
  141. package/esm2015/datepicker_v2/models/dp-config.model.js +1 -1
  142. package/esm2015/datepicker_v2/public_api.js +3 -3
  143. package/esm2015/datepicker_v2/tz-datepicker.directive.js +1 -1
  144. package/esm2015/datepicker_v2/tz-dp-container/tz-dp-container.component.js +12 -9
  145. package/esm2015/datepicker_v2/utils/index.js +13 -13
  146. package/esm2015/daterangepicker_v2/daterangepicker-constants.js +2 -2
  147. package/esm2015/daterangepicker_v2/daterangepicker.module.js +4 -3
  148. package/esm2015/daterangepicker_v2/index.js +2 -2
  149. package/esm2015/daterangepicker_v2/public_api.js +3 -3
  150. package/esm2015/daterangepicker_v2/tz-daterangepicker.directive.js +1 -1
  151. package/esm2015/daterangepicker_v2/tz-drp-container/tz-drp-container.component.js +15 -38
  152. package/esm2015/daterangepicker_v2/utils/index.js +13 -13
  153. package/esm2015/drawer/drawer-body/drawer-body.component.js +4 -7
  154. package/esm2015/drawer/drawer.module.js +4 -4
  155. package/esm2015/drawer/drawer.service.js +4 -4
  156. package/esm2015/drawer/index.js +2 -2
  157. package/esm2015/drawer/public_api.js +5 -5
  158. package/esm2015/dropdown/dropdown.component.js +3 -10
  159. package/esm2015/dropdown/dropdown.module.js +7 -6
  160. package/esm2015/dropdown/index.js +2 -2
  161. package/esm2015/dropdown/public_api.js +3 -3
  162. package/esm2015/fab/fab.component.js +11 -14
  163. package/esm2015/fab/fab.module.js +3 -3
  164. package/esm2015/fab/index.js +2 -2
  165. package/esm2015/fab/public_api.js +3 -3
  166. package/esm2015/index.js +2 -2
  167. package/esm2015/input/directives/input/input.directive.js +7 -7
  168. package/esm2015/input/index.js +2 -2
  169. package/esm2015/input/mis-input.component.js +8 -8
  170. package/esm2015/input/mis-input.module.js +7 -7
  171. package/esm2015/input/public_api.js +4 -4
  172. package/esm2015/loader/index.js +2 -2
  173. package/esm2015/loader/loader.component.js +5 -6
  174. package/esm2015/loader/loader.module.js +4 -4
  175. package/esm2015/loader/public_api.js +3 -3
  176. package/esm2015/menu/index.js +2 -2
  177. package/esm2015/modal/index.js +2 -2
  178. package/esm2015/modal/modal.module.js +10 -14
  179. package/esm2015/modal/modal.service.js +3 -3
  180. package/esm2015/modal/module-wrapper/module-wrapper.component.js +4 -4
  181. package/esm2015/modal/public_api.js +5 -5
  182. package/esm2015/multi-select-dropdown/index.js +2 -2
  183. package/esm2015/multi-select-dropdown/multi-select-dropdown.component.js +3 -10
  184. package/esm2015/multi-select-dropdown/multi-select-dropdown.module.js +9 -8
  185. package/esm2015/multi-select-dropdown/public_api.js +3 -3
  186. package/esm2015/nested-multi-select-dropdown/index.js +2 -2
  187. package/esm2015/nested-multi-select-dropdown/nested-multi-select-dropdown.component.js +3 -10
  188. package/esm2015/nested-multi-select-dropdown/nested-multi-select-dropdown.module.js +9 -8
  189. package/esm2015/nested-multi-select-dropdown/public_api.js +3 -3
  190. package/esm2015/public-api.js +1 -1
  191. package/esm2015/radio-button/index.js +2 -2
  192. package/esm2015/radio-button/public_api.js +3 -3
  193. package/esm2015/radio-button/radio-button.component.js +9 -10
  194. package/esm2015/radio-button/radio-button.module.js +5 -5
  195. package/esm2015/switch/index.js +2 -2
  196. package/esm2015/switch/public_api.js +3 -3
  197. package/esm2015/switch/switch.component.js +6 -7
  198. package/esm2015/switch/switch.module.js +5 -5
  199. package/esm2015/table/custom-table-cell.directive.js +3 -3
  200. package/esm2015/table/filter/filter.component.js +11 -13
  201. package/esm2015/table/index.js +2 -2
  202. package/esm2015/table/public_api.js +5 -5
  203. package/esm2015/table/sub-table/sub-table.component.js +12 -13
  204. package/esm2015/table/table.component.js +21 -22
  205. package/esm2015/table/table.module.js +7 -21
  206. package/esm2015/toast/index.js +2 -2
  207. package/esm2015/toast/toast.component.js +12 -14
  208. package/esm2015/toast/toast.data.service.js +3 -3
  209. package/esm2015/toast/toast.module.js +9 -9
  210. package/esm2015/toast/toast.service.js +23 -26
  211. package/esm2015/tooltip/tooltip.directive.js +1 -1
  212. package/esm2015/tooltip/tooltip.module.js +3 -2
  213. package/fab/index.d.ts +1 -1
  214. package/fab/mis-crystal-design-system-fab.metadata.json +1 -1
  215. package/fab/public_api.d.ts +2 -2
  216. package/fesm2015/mis-crystal-design-system-action-list.js +5 -13
  217. package/fesm2015/mis-crystal-design-system-action-list.js.map +1 -1
  218. package/fesm2015/mis-crystal-design-system-async-search-dropdown.js +20 -20
  219. package/fesm2015/mis-crystal-design-system-async-search-dropdown.js.map +1 -1
  220. package/fesm2015/mis-crystal-design-system-button.js +25 -25
  221. package/fesm2015/mis-crystal-design-system-button.js.map +1 -1
  222. package/fesm2015/mis-crystal-design-system-checkbox.js +5 -6
  223. package/fesm2015/mis-crystal-design-system-checkbox.js.map +1 -1
  224. package/fesm2015/mis-crystal-design-system-chip.js +6 -7
  225. package/fesm2015/mis-crystal-design-system-chip.js.map +1 -1
  226. package/fesm2015/mis-crystal-design-system-datepicker_v2.js +26 -23
  227. package/fesm2015/mis-crystal-design-system-datepicker_v2.js.map +1 -1
  228. package/fesm2015/mis-crystal-design-system-daterangepicker_v2.js +30 -53
  229. package/fesm2015/mis-crystal-design-system-daterangepicker_v2.js.map +1 -1
  230. package/fesm2015/mis-crystal-design-system-drawer.js +9 -12
  231. package/fesm2015/mis-crystal-design-system-drawer.js.map +1 -1
  232. package/fesm2015/mis-crystal-design-system-dropdown.js +4 -11
  233. package/fesm2015/mis-crystal-design-system-dropdown.js.map +1 -1
  234. package/fesm2015/mis-crystal-design-system-fab.js +11 -14
  235. package/fesm2015/mis-crystal-design-system-fab.js.map +1 -1
  236. package/fesm2015/mis-crystal-design-system-input.js +8 -8
  237. package/fesm2015/mis-crystal-design-system-input.js.map +1 -1
  238. package/fesm2015/mis-crystal-design-system-loader.js +3 -4
  239. package/fesm2015/mis-crystal-design-system-loader.js.map +1 -1
  240. package/fesm2015/mis-crystal-design-system-modal.js +8 -12
  241. package/fesm2015/mis-crystal-design-system-modal.js.map +1 -1
  242. package/fesm2015/mis-crystal-design-system-multi-select-dropdown.js +4 -11
  243. package/fesm2015/mis-crystal-design-system-multi-select-dropdown.js.map +1 -1
  244. package/fesm2015/mis-crystal-design-system-nested-multi-select-dropdown.js +4 -11
  245. package/fesm2015/mis-crystal-design-system-nested-multi-select-dropdown.js.map +1 -1
  246. package/fesm2015/mis-crystal-design-system-radio-button.js +6 -7
  247. package/fesm2015/mis-crystal-design-system-radio-button.js.map +1 -1
  248. package/fesm2015/mis-crystal-design-system-switch.js +3 -4
  249. package/fesm2015/mis-crystal-design-system-switch.js.map +1 -1
  250. package/fesm2015/mis-crystal-design-system-table.js +42 -60
  251. package/fesm2015/mis-crystal-design-system-table.js.map +1 -1
  252. package/fesm2015/mis-crystal-design-system-toast.js +28 -33
  253. package/fesm2015/mis-crystal-design-system-toast.js.map +1 -1
  254. package/fesm2015/mis-crystal-design-system-tooltip.js +2 -2
  255. package/fesm2015/mis-crystal-design-system-tooltip.js.map +1 -1
  256. package/fesm2015/mis-crystal-design-system.js.map +1 -1
  257. package/index.d.ts +1 -1
  258. package/input/directives/input/input.directive.d.ts +3 -3
  259. package/input/index.d.ts +1 -1
  260. package/input/mis-crystal-design-system-input.metadata.json +1 -1
  261. package/input/mis-input.component.d.ts +4 -4
  262. package/input/public_api.d.ts +3 -3
  263. package/loader/index.d.ts +1 -1
  264. package/loader/loader.component.d.ts +1 -1
  265. package/loader/loader.module.d.ts +1 -1
  266. package/loader/mis-crystal-design-system-loader.metadata.json +1 -1
  267. package/loader/public_api.d.ts +2 -2
  268. package/menu/index.d.ts +1 -1
  269. package/modal/index.d.ts +1 -1
  270. package/modal/mis-crystal-design-system-modal.metadata.json +1 -1
  271. package/modal/modal.module.d.ts +1 -1
  272. package/modal/public_api.d.ts +4 -4
  273. package/multi-select-dropdown/index.d.ts +1 -1
  274. package/multi-select-dropdown/mis-crystal-design-system-multi-select-dropdown.metadata.json +1 -1
  275. package/multi-select-dropdown/multi-select-dropdown.component.d.ts +0 -1
  276. package/multi-select-dropdown/multi-select-dropdown.module.d.ts +1 -1
  277. package/multi-select-dropdown/public_api.d.ts +2 -2
  278. package/nested-multi-select-dropdown/index.d.ts +1 -1
  279. package/nested-multi-select-dropdown/mis-crystal-design-system-nested-multi-select-dropdown.metadata.json +1 -1
  280. package/nested-multi-select-dropdown/nested-multi-select-dropdown.component.d.ts +0 -1
  281. package/nested-multi-select-dropdown/nested-multi-select-dropdown.module.d.ts +1 -1
  282. package/nested-multi-select-dropdown/public_api.d.ts +2 -2
  283. package/package.json +1 -1
  284. package/radio-button/index.d.ts +1 -1
  285. package/radio-button/mis-crystal-design-system-radio-button.metadata.json +1 -1
  286. package/radio-button/public_api.d.ts +2 -2
  287. package/radio-button/radio-button.component.d.ts +2 -2
  288. package/radio-button/radio-button.module.d.ts +1 -1
  289. package/switch/index.d.ts +1 -1
  290. package/switch/mis-crystal-design-system-switch.metadata.json +1 -1
  291. package/switch/public_api.d.ts +2 -2
  292. package/switch/switch.component.d.ts +2 -2
  293. package/switch/switch.module.d.ts +1 -1
  294. package/table/custom-table-cell.directive.d.ts +1 -1
  295. package/table/filter/filter.component.d.ts +1 -1
  296. package/table/index.d.ts +1 -1
  297. package/table/mis-crystal-design-system-table.metadata.json +1 -1
  298. package/table/public_api.d.ts +7 -7
  299. package/table/sub-table/sub-table.component.d.ts +6 -6
  300. package/table/table.component.d.ts +6 -6
  301. package/toast/index.d.ts +1 -1
  302. package/toast/mis-crystal-design-system-toast.metadata.json +1 -1
  303. package/toast/toast.component.d.ts +1 -1
  304. package/toast/toast.module.d.ts +1 -1
  305. package/toast/toast.service.d.ts +3 -3
  306. package/tooltip/mis-crystal-design-system-tooltip.metadata.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"mis-crystal-design-system-input.umd.js","sources":["../../../projects/mis-components/input/directives/input/input.directive.ts","../../../projects/mis-components/input/mis-input.component.ts","../../../projects/mis-components/input/mis-input.module.ts","../../../projects/mis-components/input/mis-crystal-design-system-input.ts"],"sourcesContent":["import {\n Directive,\n ElementRef,\n OnDestroy,\n OnInit,\n Optional,\n Self,\n} from '@angular/core';\nimport { NgControl } from '@angular/forms';\nimport { ReplaySubject, Subject, Subscription } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\n\n@Directive({\n // tslint:disable-next-line\n selector: 'input[misInput]',\n})\nexport class MisInputDirective implements OnInit, OnDestroy {\n constructor(\n public el: ElementRef,\n @Self() @Optional() private control: NgControl\n ) {}\n private validityChange: ReplaySubject<boolean> = new ReplaySubject(1);\n validity = this.validityChange.asObservable();\n endObs: Subject<void> = new Subject();\n focus = false;\n hasValue = false;\n\n ngOnInit(): void {\n this.control?.control?.statusChanges\n .pipe(takeUntil(this.endObs))\n .subscribe(() => {\n if(!this.control.control?.disabled){\n this.validityChange.next(!this.control.control?.invalid);\n }\n });\n this.el.nativeElement.placeholder += ' ';\n }\n ngOnDestroy(): void {\n this.endObs.next();\n this.endObs.complete();\n }\n}\n","import {\n Component,\n ContentChild,\n Input,\n OnDestroy,\n OnInit,\n ViewEncapsulation,\n} from '@angular/core';\nimport { Subscription } from 'rxjs';\nimport { MisInputDirective } from './directives/input/input.directive';\n\n@Component({\n selector: 'mis-input',\n templateUrl: './mis-input.component.html',\n styleUrls: ['./mis-input.component.scss'],\n})\nexport class MisInputComponent implements OnInit, OnDestroy {\n @Input() type: 'rounded' | 'floating' = 'floating';\n @Input() placeholder: string; // floating placeholder text\n @Input() noHints = false;\n @Input() hasError = false; // show input in error state\n @ContentChild(MisInputDirective) set formInput(input: MisInputDirective) {\n if (!this.placeholder) {\n this.placeholder = input.el.nativeElement.placeholder;\n }\n this.inputSubscription?.unsubscribe();\n this.inputSubscription = input?.validity.subscribe(\n (res) => (this.inputValidity = res)\n );\n this.placeholder += ' ';\n }\n inputSubscription: Subscription | undefined;\n inputValidity: boolean = true;\n constructor() {}\n\n ngOnInit(): void {}\n ngOnDestroy(): void {\n this.inputSubscription?.unsubscribe();\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { MisInputDirective } from './directives/input/input.directive';\nimport { MisInputComponent } from './mis-input.component';\n\n@NgModule({\n declarations: [MisInputComponent, MisInputDirective],\n imports: [CommonModule, FormsModule],\n exports: [MisInputComponent, MisInputDirective],\n})\nexport class MisInputModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["ReplaySubject","Subject","takeUntil","Directive","ElementRef","NgControl","Self","Optional","Component","Input","ContentChild","NgModule","CommonModule","FormsModule"],"mappings":";;;;;;;QAiBE,2BACS,EAAc,EACO,OAAkB;YADvC,OAAE,GAAF,EAAE,CAAY;YACO,YAAO,GAAP,OAAO,CAAW;YAExC,mBAAc,GAA2B,IAAIA,kBAAa,CAAC,CAAC,CAAC,CAAC;YACtE,aAAQ,GAAG,IAAI,CAAC,cAAc,CAAC,YAAY,EAAE,CAAC;YAC9C,WAAM,GAAkB,IAAIC,YAAO,EAAE,CAAC;YACt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C,GAAG,IAAK,QAAC,KAAI,CAAC,aAAa,GAAG,GAAG,IAAC,CACpC,CAAC;gBACF,IAAI,CAAC,WAAW,IAAI,GAAG,CAAC;aACzB;;;WAAA;QAKD,oCAAQ,GAAR,eAAmB;QACnB,uCAAW,GAAX;;YACE,MAAA,IAAI,CAAC,iBAAiB,0CAAE,WAAW,GAAG;SACvC;;;;gBA3BFC,cAAS,SAAC;oBACT,QAAQ,EAAE,WAAW;oBACrB,6mBAAyC;;iBAE1C;;;;uBAEEC,UAAK;8BACLA,UAAK;0BACLA,UAAK;2BACLA,UAAK;4BACLC,iBAAY,SAAC,iBAAiB;;;;QCVjC;;;;;gBALCC,aAAQ,SAAC;oBACR,YAAY,EAAE,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;oBACpD,OAAO,EAAE,CAACC,mBAAY,EAAEC,iBAAW,CAAC;oBACpC,OAAO,EAAE,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;iBAChD;;;ICVD;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"mis-crystal-design-system-input.umd.js","sources":["../../../projects/mis-components/input/directives/input/input.directive.ts","../../../projects/mis-components/input/mis-input.component.ts","../../../projects/mis-components/input/mis-input.module.ts","../../../projects/mis-components/input/mis-crystal-design-system-input.ts"],"sourcesContent":["import { Directive, ElementRef, OnDestroy, OnInit, Optional, Self } from \"@angular/core\";\nimport { NgControl } from \"@angular/forms\";\nimport { ReplaySubject, Subject, Subscription } from \"rxjs\";\nimport { takeUntil } from \"rxjs/operators\";\n\n@Directive({\n // tslint:disable-next-line\n selector: \"input[misInput]\"\n})\nexport class MisInputDirective implements OnInit, OnDestroy {\n constructor(public el: ElementRef, @Self() @Optional() private control: NgControl) {}\n private validityChange: ReplaySubject<boolean> = new ReplaySubject(1);\n validity = this.validityChange.asObservable();\n endObs: Subject<void> = new Subject();\n focus = false;\n hasValue = false;\n\n ngOnInit(): void {\n this.control?.control?.statusChanges.pipe(takeUntil(this.endObs)).subscribe(() => {\n if (!this.control.control?.disabled) {\n this.validityChange.next(!this.control.control?.invalid);\n }\n });\n this.el.nativeElement.placeholder += \" \";\n }\n ngOnDestroy(): void {\n this.endObs.next();\n this.endObs.complete();\n }\n}\n","import { Component, ContentChild, Input, OnDestroy, OnInit, ViewEncapsulation } from \"@angular/core\";\nimport { Subscription } from \"rxjs\";\nimport { MisInputDirective } from \"./directives/input/input.directive\";\n\n@Component({\n selector: \"mis-input\",\n templateUrl: \"./mis-input.component.html\",\n styleUrls: [\"./mis-input.component.scss\"]\n})\nexport class MisInputComponent implements OnInit, OnDestroy {\n @Input() type: \"rounded\" | \"floating\" = \"floating\";\n @Input() placeholder: string; // floating placeholder text\n @Input() noHints = false;\n @Input() hasError = false; // show input in error state\n @ContentChild(MisInputDirective) set formInput(input: MisInputDirective) {\n if (!this.placeholder) {\n this.placeholder = input.el.nativeElement.placeholder;\n }\n this.inputSubscription?.unsubscribe();\n this.inputSubscription = input?.validity.subscribe(res => (this.inputValidity = res));\n this.placeholder += \" \";\n }\n inputSubscription: Subscription | undefined;\n inputValidity: boolean = true;\n constructor() {}\n\n ngOnInit(): void {}\n ngOnDestroy(): void {\n this.inputSubscription?.unsubscribe();\n }\n}\n","import { CommonModule } from \"@angular/common\";\nimport { NgModule } from \"@angular/core\";\nimport { FormsModule } from \"@angular/forms\";\nimport { MisInputDirective } from \"./directives/input/input.directive\";\nimport { MisInputComponent } from \"./mis-input.component\";\n\n@NgModule({\n declarations: [MisInputComponent, MisInputDirective],\n imports: [CommonModule, FormsModule],\n exports: [MisInputComponent, MisInputDirective]\n})\nexport class MisInputModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["ReplaySubject","Subject","takeUntil","Directive","ElementRef","NgControl","Self","Optional","Component","Input","ContentChild","NgModule","CommonModule","FormsModule"],"mappings":";;;;;;;QAUE,2BAAmB,EAAc,EAA8B,OAAkB;YAA9D,OAAE,GAAF,EAAE,CAAY;YAA8B,YAAO,GAAP,OAAO,CA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CAAC,WAAW,CAAC;iBACvD;gBACD,MAAA,IAAI,CAAC,iBAAiB,0CAAE,WAAW,GAAG;gBACtC,IAAI,CAAC,iBAAiB,GAAG,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,QAAQ,CAAC,SAAS,CAAC,UAAA,GAAG,IAAI,QAAC,KAAI,CAAC,aAAa,GAAG,GAAG,IAAC,CAAC,CAAC;gBACtF,IAAI,CAAC,WAAW,IAAI,GAAG,CAAC;aACzB;;;WAAA;QAKD,oCAAQ,GAAR,eAAmB;QACnB,uCAAW,GAAX;;YACE,MAAA,IAAI,CAAC,iBAAiB,0CAAE,WAAW,GAAG;SACvC;;;;gBAzBFC,cAAS,SAAC;oBACT,QAAQ,EAAE,WAAW;oBACrB,unBAAyC;;iBAE1C;;;;uBAEEC,UAAK;8BACLA,UAAK;0BACLA,UAAK;2BACLA,UAAK;4BACLC,iBAAY,SAAC,iBAAiB;;;;QCHjC;;;;;gBALCC,aAAQ,SAAC;oBACR,YAAY,EAAE,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;oBACpD,OAAO,EAAE,CAACC,mBAAY,EAAEC,iBAAW,CAAC;oBACpC,OAAO,EAAE,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;iBAChD;;;ICVD;;;;;;;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- !function(n,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/forms"),require("rxjs"),require("rxjs/operators"),require("@angular/common")):"function"==typeof define&&define.amd?define("mis-crystal-design-system/input",["exports","@angular/core","@angular/forms","rxjs","rxjs/operators","@angular/common"],t):t(((n="undefined"!=typeof globalThis?globalThis:n||self)["mis-crystal-design-system"]=n["mis-crystal-design-system"]||{},n["mis-crystal-design-system"].input={}),n.ng.core,n.ng.forms,n.rxjs,n.rxjs.operators,n.ng.common)}(this,(function(n,t,i,e,o,r){"use strict";var p=function(){function n(n,t){this.el=n,this.control=t,this.validityChange=new e.ReplaySubject(1),this.validity=this.validityChange.asObservable(),this.endObs=new e.Subject,this.focus=!1,this.hasValue=!1}return n.prototype.ngOnInit=function(){var n,t,i=this;null===(t=null===(n=this.control)||void 0===n?void 0:n.control)||void 0===t||t.statusChanges.pipe(o.takeUntil(this.endObs)).subscribe((function(){var n,t;(null===(n=i.control.control)||void 0===n?void 0:n.disabled)||i.validityChange.next(!(null===(t=i.control.control)||void 0===t?void 0:t.invalid))})),this.el.nativeElement.placeholder+=" "},n.prototype.ngOnDestroy=function(){this.endObs.next(),this.endObs.complete()},n}();p.decorators=[{type:t.Directive,args:[{selector:"input[misInput]"}]}],p.ctorParameters=function(){return[{type:t.ElementRef},{type:i.NgControl,decorators:[{type:t.Self},{type:t.Optional}]}]};var a=function(){function n(){this.type="floating",this.noHints=!1,this.hasError=!1,this.inputValidity=!0}return Object.defineProperty(n.prototype,"formInput",{set:function(n){var t,i=this;this.placeholder||(this.placeholder=n.el.nativeElement.placeholder),null===(t=this.inputSubscription)||void 0===t||t.unsubscribe(),this.inputSubscription=null==n?void 0:n.validity.subscribe((function(n){return i.inputValidity=n})),this.placeholder+=" "},enumerable:!1,configurable:!0}),n.prototype.ngOnInit=function(){},n.prototype.ngOnDestroy=function(){var n;null===(n=this.inputSubscription)||void 0===n||n.unsubscribe()},n}();a.decorators=[{type:t.Component,args:[{selector:"mis-input",template:'<div class="input-container" [ngClass]="{\'rounded\': type === \'rounded\', \'floating\': type === \'floating\', \'has-error\': !inputValidity || hasError, \'no-hint\': noHints}">\n <div class="input-wrapper">\n <ng-content select="[mis-input-icon]"></ng-content>\n <div class="mis-input">\n <ng-content select="input"></ng-content>\n <span class="mis-placeholder">{{placeholder}}</span>\n </div>\n <ng-content select="[mis-input-act]"></ng-content>\n </div>\n <ng-content select="[mis-input-hint]"></ng-content>\n <ng-content select="[mis-input-error]"></ng-content>\n</div>',styles:[".input-container{position:relative;padding-bottom:24px}.input-container .input-wrapper{box-sizing:border-box;display:flex;align-items:center;flex-direction:row;flex-wrap:nowrap;transition:all 60ms ease-in;background-color:#fff;padding:3px 16px}.input-container .input-wrapper>:not(:last-child){margin-right:16px}.input-container .input-wrapper .mis-input{flex:1 1 auto;z-index:0;position:relative;display:flex;align-items:center}.input-container .input-wrapper input{flex:1 1 auto;border:none;outline:none;height:100%;padding:0;font-family:Lato;font-style:normal;font-weight:400;font-size:16px;height:24px;color:#181f33;background-color:transparent;width:100%;vertical-align:middle}.input-container .input-wrapper input::-moz-placeholder{-moz-transition:all .1s ease-in;transition:all .1s ease-in;opacity:0;transform-origin:left center;color:transparent}.input-container .input-wrapper input:-ms-input-placeholder{-ms-transition:all .1s ease-in;transition:all .1s ease-in;opacity:0;transform-origin:left center;color:transparent}.input-container .input-wrapper input::placeholder{transition:all .1s ease-in;opacity:0;transform-origin:left center;color:transparent}.input-container .input-wrapper .mis-placeholder{position:absolute;font-family:Lato;font-style:normal;font-weight:400;font-size:16px;line-height:24px;color:#6a737d;z-index:-1;transition:all .15s ease-in}.input-container .input-wrapper:focus-within{background-color:#f5f5f5}.input-container .input-wrapper:focus-within{border:1px solid #0937b2}.input-container .input-wrapper [mis-input-act],.input-container .input-wrapper [mis-input-icon]{width:18px;height:18px;color:#6a737d;font-size:24px;line-height:18px}.input-container .input-wrapper [mis-input-act]{cursor:pointer}.input-container.no-hint{padding-bottom:0}.input-container.rounded .input-wrapper{border-radius:4px;border:1px solid #e0e0e0}.input-container.rounded .input-wrapper:focus-within,.input-container.rounded .input-wrapper:hover{background-color:#f5f5f5}.input-container.rounded .input-wrapper input:not(:-moz-placeholder-shown)+.mis-placeholder{color:transparent!important}.input-container.rounded .input-wrapper input:not(:-ms-input-placeholder)+.mis-placeholder{color:transparent!important}.input-container.rounded .input-wrapper input:not(:placeholder-shown)+.mis-placeholder{color:transparent!important}.input-container.rounded .input-wrapper .mis-placeholder{transition-duration:50ms}.input-container.rounded.has-error .input-wrapper{border:1px solid #b00020!important}.input-container.floating .input-wrapper{padding-top:24px;padding-bottom:7px;border-bottom:1px solid #e0e0e0}.input-container.floating .input-wrapper input:focus+.mis-placeholder{color:#0937b2!important}.input-container.floating .input-wrapper input:not(:-moz-placeholder-shown)+.mis-placeholder{transform:translateY(calc(-100% + 6px))!important;font-size:12px!important;letter-spacing:.2px!important}.input-container.floating .input-wrapper input:not(:-ms-input-placeholder)+.mis-placeholder{transform:translateY(calc(-100% + 6px))!important;font-size:12px!important;letter-spacing:.2px!important}.input-container.floating .input-wrapper input:focus+.mis-placeholder,.input-container.floating .input-wrapper input:not(:placeholder-shown)+.mis-placeholder{transform:translateY(calc(-100% + 6px))!important;font-size:12px!important;letter-spacing:.2px!important}.input-container.floating .input-wrapper:focus-within{border:none;border-bottom:1px solid #0937b2}.input-container.floating .input-wrapper:focus-within input::-moz-placeholder{color:#6a737d;opacity:1;font-size:16px}.input-container.floating .input-wrapper:focus-within input:-ms-input-placeholder{color:#6a737d;opacity:1;font-size:16px}.input-container.floating .input-wrapper:focus-within input::placeholder{color:#6a737d;opacity:1;font-size:16px}.input-container.floating.has-error .input-wrapper{border-bottom:1px solid #b00020!important}.input-container.floating.has-error .input-wrapper .mis-placeholder{color:#b00020!important}.input-container [mis-input-error],.input-container [mis-input-hint]{position:absolute;left:0;right:0;bottom:0;line-height:24px;height:24px;font-size:12px;color:#6a737d;letter-spacing:.2px}.input-container [mis-input-error]{color:#b00020}"]}]}],a.ctorParameters=function(){return[]},a.propDecorators={type:[{type:t.Input}],placeholder:[{type:t.Input}],noHints:[{type:t.Input}],hasError:[{type:t.Input}],formInput:[{type:t.ContentChild,args:[p]}]};var s=function(){};s.decorators=[{type:t.NgModule,args:[{declarations:[a,p],imports:[r.CommonModule,i.FormsModule],exports:[a,p]}]}],n.MisInputComponent=a,n.MisInputDirective=p,n.MisInputModule=s,Object.defineProperty(n,"__esModule",{value:!0})}));
1
+ !function(n,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/core"),require("@angular/forms"),require("rxjs"),require("rxjs/operators"),require("@angular/common")):"function"==typeof define&&define.amd?define("mis-crystal-design-system/input",["exports","@angular/core","@angular/forms","rxjs","rxjs/operators","@angular/common"],t):t(((n="undefined"!=typeof globalThis?globalThis:n||self)["mis-crystal-design-system"]=n["mis-crystal-design-system"]||{},n["mis-crystal-design-system"].input={}),n.ng.core,n.ng.forms,n.rxjs,n.rxjs.operators,n.ng.common)}(this,(function(n,t,i,e,o,r){"use strict";var p=function(){function n(n,t){this.el=n,this.control=t,this.validityChange=new e.ReplaySubject(1),this.validity=this.validityChange.asObservable(),this.endObs=new e.Subject,this.focus=!1,this.hasValue=!1}return n.prototype.ngOnInit=function(){var n,t,i=this;null===(t=null===(n=this.control)||void 0===n?void 0:n.control)||void 0===t||t.statusChanges.pipe(o.takeUntil(this.endObs)).subscribe((function(){var n,t;(null===(n=i.control.control)||void 0===n?void 0:n.disabled)||i.validityChange.next(!(null===(t=i.control.control)||void 0===t?void 0:t.invalid))})),this.el.nativeElement.placeholder+=" "},n.prototype.ngOnDestroy=function(){this.endObs.next(),this.endObs.complete()},n}();p.decorators=[{type:t.Directive,args:[{selector:"input[misInput]"}]}],p.ctorParameters=function(){return[{type:t.ElementRef},{type:i.NgControl,decorators:[{type:t.Self},{type:t.Optional}]}]};var a=function(){function n(){this.type="floating",this.noHints=!1,this.hasError=!1,this.inputValidity=!0}return Object.defineProperty(n.prototype,"formInput",{set:function(n){var t,i=this;this.placeholder||(this.placeholder=n.el.nativeElement.placeholder),null===(t=this.inputSubscription)||void 0===t||t.unsubscribe(),this.inputSubscription=null==n?void 0:n.validity.subscribe((function(n){return i.inputValidity=n})),this.placeholder+=" "},enumerable:!1,configurable:!0}),n.prototype.ngOnInit=function(){},n.prototype.ngOnDestroy=function(){var n;null===(n=this.inputSubscription)||void 0===n||n.unsubscribe()},n}();a.decorators=[{type:t.Component,args:[{selector:"mis-input",template:'<div\n class="input-container"\n [ngClass]="{ rounded: type === \'rounded\', floating: type === \'floating\', \'has-error\': !inputValidity || hasError, \'no-hint\': noHints }"\n>\n <div class="input-wrapper">\n <ng-content select="[mis-input-icon]"></ng-content>\n <div class="mis-input">\n <ng-content select="input"></ng-content>\n <span class="mis-placeholder">{{ placeholder }}</span>\n </div>\n <ng-content select="[mis-input-act]"></ng-content>\n </div>\n <ng-content select="[mis-input-hint]"></ng-content>\n <ng-content select="[mis-input-error]"></ng-content>\n</div>\n',styles:[".input-container{position:relative;padding-bottom:24px}.input-container .input-wrapper{box-sizing:border-box;display:flex;align-items:center;flex-direction:row;flex-wrap:nowrap;transition:all 60ms ease-in;background-color:#fff;padding:3px 16px}.input-container .input-wrapper>:not(:last-child){margin-right:16px}.input-container .input-wrapper .mis-input{flex:1 1 auto;z-index:0;position:relative;display:flex;align-items:center}.input-container .input-wrapper input{flex:1 1 auto;border:none;outline:none;height:100%;padding:0;font-family:Lato;font-style:normal;font-weight:400;font-size:16px;height:24px;color:#181f33;background-color:transparent;width:100%;vertical-align:middle}.input-container .input-wrapper input::-moz-placeholder{-moz-transition:all .1s ease-in;transition:all .1s ease-in;opacity:0;transform-origin:left center;color:transparent}.input-container .input-wrapper input:-ms-input-placeholder{-ms-transition:all .1s ease-in;transition:all .1s ease-in;opacity:0;transform-origin:left center;color:transparent}.input-container .input-wrapper input::placeholder{transition:all .1s ease-in;opacity:0;transform-origin:left center;color:transparent}.input-container .input-wrapper .mis-placeholder{position:absolute;font-family:Lato;font-style:normal;font-weight:400;font-size:16px;line-height:24px;color:#6a737d;z-index:-1;transition:all .15s ease-in}.input-container .input-wrapper:focus-within{background-color:#f5f5f5}.input-container .input-wrapper:focus-within{border:1px solid #0937b2}.input-container .input-wrapper [mis-input-act],.input-container .input-wrapper [mis-input-icon]{width:18px;height:18px;color:#6a737d;font-size:24px;line-height:18px}.input-container .input-wrapper [mis-input-act]{cursor:pointer}.input-container.no-hint{padding-bottom:0}.input-container.rounded .input-wrapper{border-radius:4px;border:1px solid #e0e0e0}.input-container.rounded .input-wrapper:focus-within,.input-container.rounded .input-wrapper:hover{background-color:#f5f5f5}.input-container.rounded .input-wrapper input:not(:-moz-placeholder-shown)+.mis-placeholder{color:transparent!important}.input-container.rounded .input-wrapper input:not(:-ms-input-placeholder)+.mis-placeholder{color:transparent!important}.input-container.rounded .input-wrapper input:not(:placeholder-shown)+.mis-placeholder{color:transparent!important}.input-container.rounded .input-wrapper .mis-placeholder{transition-duration:50ms}.input-container.rounded.has-error .input-wrapper{border:1px solid #b00020!important}.input-container.floating .input-wrapper{padding-top:24px;padding-bottom:7px;border-bottom:1px solid #e0e0e0}.input-container.floating .input-wrapper input:focus+.mis-placeholder{color:#0937b2!important}.input-container.floating .input-wrapper input:not(:-moz-placeholder-shown)+.mis-placeholder{transform:translateY(calc(-100% + 6px))!important;font-size:12px!important;letter-spacing:.2px!important}.input-container.floating .input-wrapper input:not(:-ms-input-placeholder)+.mis-placeholder{transform:translateY(calc(-100% + 6px))!important;font-size:12px!important;letter-spacing:.2px!important}.input-container.floating .input-wrapper input:focus+.mis-placeholder,.input-container.floating .input-wrapper input:not(:placeholder-shown)+.mis-placeholder{transform:translateY(calc(-100% + 6px))!important;font-size:12px!important;letter-spacing:.2px!important}.input-container.floating .input-wrapper:focus-within{border:none;border-bottom:1px solid #0937b2}.input-container.floating .input-wrapper:focus-within input::-moz-placeholder{color:#6a737d;opacity:1;font-size:16px}.input-container.floating .input-wrapper:focus-within input:-ms-input-placeholder{color:#6a737d;opacity:1;font-size:16px}.input-container.floating .input-wrapper:focus-within input::placeholder{color:#6a737d;opacity:1;font-size:16px}.input-container.floating.has-error .input-wrapper{border-bottom:1px solid #b00020!important}.input-container.floating.has-error .input-wrapper .mis-placeholder{color:#b00020!important}.input-container [mis-input-error],.input-container [mis-input-hint]{position:absolute;left:0;right:0;bottom:0;line-height:24px;height:24px;font-size:12px;color:#6a737d;letter-spacing:.2px}.input-container [mis-input-error]{color:#b00020}"]}]}],a.ctorParameters=function(){return[]},a.propDecorators={type:[{type:t.Input}],placeholder:[{type:t.Input}],noHints:[{type:t.Input}],hasError:[{type:t.Input}],formInput:[{type:t.ContentChild,args:[p]}]};var s=function(){};s.decorators=[{type:t.NgModule,args:[{declarations:[a,p],imports:[r.CommonModule,i.FormsModule],exports:[a,p]}]}],n.MisInputComponent=a,n.MisInputDirective=p,n.MisInputModule=s,Object.defineProperty(n,"__esModule",{value:!0})}));
2
2
  //# sourceMappingURL=mis-crystal-design-system-input.umd.min.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../projects/mis-components/input/directives/input/input.directive.ts","../../../projects/mis-components/input/mis-input.component.ts","../../../projects/mis-components/input/mis-input.module.ts"],"names":["MisInputDirective","el","control","this","validityChange","ReplaySubject","validity","asObservable","endObs","Subject","focus","hasValue","prototype","ngOnInit","_this","_b","_a","statusChanges","pipe","takeUntil","subscribe","disabled","next","invalid","nativeElement","placeholder","ngOnDestroy","complete","Directive","args","selector","ElementRef","NgControl","decorators","type","Self","Optional","MisInputComponent","noHints","hasError","inputValidity","Object","defineProperty","input","inputSubscription","unsubscribe","res","Component","template","Input","ContentChild","NgModule","declarations","imports","CommonModule","FormsModule","exports"],"mappings":"uoBAiBE,SAAAA,EACSC,EACqBC,GADrBC,KAAAF,GAAAA,EACqBE,KAAAD,QAAAA,EAEtBC,KAAAC,eAAyC,IAAIC,EAAAA,cAAc,GACnEF,KAAAG,SAAWH,KAAKC,eAAeG,eAC/BJ,KAAAK,OAAwB,IAAIC,EAAAA,QAC5BN,KAAAO,OAAQ,EACRP,KAAAQ,UAAW,SAEXX,EAAAY,UAAAC,SAAA,WAAA,QAAAC,EAAAX,KACuB,QAArBY,EAAY,QAAZC,EAAAb,KAAKD,eAAO,IAAAc,OAAA,EAAAA,EAAEd,eAAO,IAAAa,GAAAA,EAAEE,cACpBC,KAAKC,EAAAA,UAAUhB,KAAKK,SACpBY,WAAU,oBACe,QAArBJ,EAACF,EAAKZ,QAAQA,eAAO,IAAAc,OAAA,EAAAA,EAAEK,WACxBP,EAAKV,eAAekB,OAA0B,QAArBP,EAACD,EAAKZ,QAAQA,eAAO,IAAAa,OAAA,EAAA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} from '@angular/forms';\nimport { ReplaySubject, Subject, Subscription } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\n\n@Directive({\n // tslint:disable-next-line\n selector: 'input[misInput]',\n})\nexport class MisInputDirective implements OnInit, OnDestroy {\n constructor(\n public el: ElementRef,\n @Self() @Optional() private control: NgControl\n ) {}\n private validityChange: ReplaySubject<boolean> = new ReplaySubject(1);\n validity = this.validityChange.asObservable();\n endObs: Subject<void> = new Subject();\n focus = false;\n hasValue = false;\n\n ngOnInit(): void {\n this.control?.control?.statusChanges\n .pipe(takeUntil(this.endObs))\n .subscribe(() => {\n if(!this.control.control?.disabled){\n this.validityChange.next(!this.control.control?.invalid);\n }\n });\n this.el.nativeElement.placeholder += ' ';\n }\n ngOnDestroy(): void {\n this.endObs.next();\n this.endObs.complete();\n }\n}\n","import {\n Component,\n ContentChild,\n Input,\n OnDestroy,\n OnInit,\n ViewEncapsulation,\n} from '@angular/core';\nimport { Subscription } from 'rxjs';\nimport { MisInputDirective } from './directives/input/input.directive';\n\n@Component({\n selector: 'mis-input',\n templateUrl: './mis-input.component.html',\n styleUrls: ['./mis-input.component.scss'],\n})\nexport class MisInputComponent implements OnInit, OnDestroy {\n @Input() type: 'rounded' | 'floating' = 'floating';\n @Input() placeholder: string; // floating placeholder text\n @Input() noHints = false;\n @Input() hasError = false; // show input in error state\n @ContentChild(MisInputDirective) set formInput(input: MisInputDirective) {\n if (!this.placeholder) {\n this.placeholder = input.el.nativeElement.placeholder;\n }\n this.inputSubscription?.unsubscribe();\n this.inputSubscription = input?.validity.subscribe(\n (res) => (this.inputValidity = res)\n );\n this.placeholder += ' ';\n }\n inputSubscription: Subscription | undefined;\n inputValidity: boolean = true;\n constructor() {}\n\n ngOnInit(): void {}\n ngOnDestroy(): void {\n this.inputSubscription?.unsubscribe();\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { MisInputDirective } from './directives/input/input.directive';\nimport { MisInputComponent } from './mis-input.component';\n\n@NgModule({\n declarations: [MisInputComponent, MisInputDirective],\n imports: [CommonModule, FormsModule],\n exports: [MisInputComponent, MisInputDirective],\n})\nexport class MisInputModule {}\n"]}
1
+ {"version":3,"sources":["../../../projects/mis-components/input/directives/input/input.directive.ts","../../../projects/mis-components/input/mis-input.component.ts","../../../projects/mis-components/input/mis-input.module.ts"],"names":["MisInputDirective","el","control","this","validityChange","ReplaySubject","validity","asObservable","endObs","Subject","focus","hasValue","prototype","ngOnInit","_this","_b","_a","statusChanges","pipe","takeUntil","subscribe","disabled","next","invalid","nativeElement","placeholder","ngOnDestroy","complete","Directive","args","selector","ElementRef","NgControl","decorators","type","Self","Optional","MisInputComponent","noHints","hasError","inputValidity","Object","defineProperty","input","inputSubscription","unsubscribe","res","Component","template","Input","ContentChild","NgModule","declarations","imports","CommonModule","FormsModule","exports"],"mappings":"uoBAUE,SAAAA,EAAmBC,EAA4CC,GAA5CC,KAAAF,GAAAA,EAA4CE,KAAAD,QAAAA,EACvDC,KAAAC,eAAyC,IAAIC,EAAAA,cAAc,GACnEF,KAAAG,SAAWH,KAAKC,eAAeG,eAC/BJ,KAAAK,OAAwB,IAAIC,EAAAA,QAC5BN,KAAAO,OAAQ,EACRP,KAAAQ,UAAW,SAEXX,EAAAY,UAAAC,SAAA,WAAA,QAAAC,EAAAX,KACuB,QAArBY,EAAY,QAAZC,EAAAb,KAAKD,eAAO,IAAAc,OAAA,EAAAA,EAAEd,eAAO,IAAAa,GAAAA,EAAEE,cAAcC,KAAKC,EAAAA,UAAUhB,KAAKK,SAASY,WAAU,oBACjD,QAArBJ,EAACF,EAAKZ,QAAQA,eAAO,IAAAc,OAAA,EAAAA,EAAEK,WACzBP,EAAKV,eAAekB,OAA0B,QAArBP,EAACD,EAAKZ,QAAQA,eAAO,IAAAa,OAAA,EAAAA,EAAEQ,aAGpDpB,KAAKF,GAAGuB,cAAcC,aAAe,KAEvCzB,EAAAY,UAAAc,YAAA,WACEvB,KAAKK,OAAOc,OACZnB,KAAKK,OAAOmB,qCAtBfC,EAAAA,UAASC,KAAA,CAAC,CAETC,SAAU,+DAPQC,EAAAA,kBACXC,EAAAA,UAASC,WAAA,CAAA,CAAAC,KASoBC,EAAAA,MAAI,CAAAD,KAAIE,EAAAA,+BCc5C,SAAAC,IAdSlC,KAAA+B,KAA+B,WAE/B/B,KAAAmC,SAAU,EACVnC,KAAAoC,UAAW,EAUpBpC,KAAAqC,eAAyB,SATzBC,OAAAC,eAAqCL,EAAAzB,UAAA,YAAS,KAA9C,SAA+C+B,GAA/C,MAAA7B,EAAAX,KACOA,KAAKsB,cACRtB,KAAKsB,YAAckB,EAAM1C,GAAGuB,cAAcC,aAEtB,QAAtBT,EAAAb,KAAKyC,yBAAiB,IAAA5B,GAAAA,EAAE6B,cACxB1C,KAAKyC,kBAAoBD,MAAAA,OAAK,EAALA,EAAOrC,SAASc,WAAU,SAAA0B,GAAO,OAAChC,EAAK0B,cAAgBM,KAChF3C,KAAKsB,aAAe,qCAMtBY,EAAAzB,UAAAC,SAAA,aACAwB,EAAAzB,UAAAc,YAAA,iBACwB,QAAtBV,EAAAb,KAAKyC,yBAAiB,IAAA5B,GAAAA,EAAE6B,wCAxB3BE,EAAAA,UAASlB,KAAA,CAAC,CACTC,SAAU,YACVkB,SAAA,o0JAICC,EAAAA,2BACAA,EAAAA,uBACAA,EAAAA,wBACAA,EAAAA,yBACAC,EAAAA,aAAYrB,KAAA,CAAC7B,YCHhB,iCALCmD,EAAAA,SAAQtB,KAAA,CAAC,CACRuB,aAAc,CAACf,EAAmBrC,GAClCqD,QAAS,CAACC,EAAAA,aAAcC,EAAAA,aACxBC,QAAS,CAACnB,EAAmBrC","sourcesContent":["import { Directive, ElementRef, OnDestroy, OnInit, Optional, Self } from \"@angular/core\";\nimport { NgControl } from \"@angular/forms\";\nimport { ReplaySubject, Subject, Subscription } from \"rxjs\";\nimport { takeUntil } from \"rxjs/operators\";\n\n@Directive({\n // tslint:disable-next-line\n selector: \"input[misInput]\"\n})\nexport class MisInputDirective implements OnInit, OnDestroy {\n constructor(public el: ElementRef, @Self() @Optional() private control: NgControl) {}\n private validityChange: ReplaySubject<boolean> = new ReplaySubject(1);\n validity = this.validityChange.asObservable();\n endObs: Subject<void> = new Subject();\n focus = false;\n hasValue = false;\n\n ngOnInit(): void {\n this.control?.control?.statusChanges.pipe(takeUntil(this.endObs)).subscribe(() => {\n if (!this.control.control?.disabled) {\n this.validityChange.next(!this.control.control?.invalid);\n }\n });\n this.el.nativeElement.placeholder += \" \";\n }\n ngOnDestroy(): void {\n this.endObs.next();\n this.endObs.complete();\n }\n}\n","import { Component, ContentChild, Input, OnDestroy, OnInit, ViewEncapsulation } from \"@angular/core\";\nimport { Subscription } from \"rxjs\";\nimport { MisInputDirective } from \"./directives/input/input.directive\";\n\n@Component({\n selector: \"mis-input\",\n templateUrl: \"./mis-input.component.html\",\n styleUrls: [\"./mis-input.component.scss\"]\n})\nexport class MisInputComponent implements OnInit, OnDestroy {\n @Input() type: \"rounded\" | \"floating\" = \"floating\";\n @Input() placeholder: string; // floating placeholder text\n @Input() noHints = false;\n @Input() hasError = false; // show input in error state\n @ContentChild(MisInputDirective) set formInput(input: MisInputDirective) {\n if (!this.placeholder) {\n this.placeholder = input.el.nativeElement.placeholder;\n }\n this.inputSubscription?.unsubscribe();\n this.inputSubscription = input?.validity.subscribe(res => (this.inputValidity = res));\n this.placeholder += \" \";\n }\n inputSubscription: Subscription | undefined;\n inputValidity: boolean = true;\n constructor() {}\n\n ngOnInit(): void {}\n ngOnDestroy(): void {\n this.inputSubscription?.unsubscribe();\n }\n}\n","import { CommonModule } from \"@angular/common\";\nimport { NgModule } from \"@angular/core\";\nimport { FormsModule } from \"@angular/forms\";\nimport { MisInputDirective } from \"./directives/input/input.directive\";\nimport { MisInputComponent } from \"./mis-input.component\";\n\n@NgModule({\n declarations: [MisInputComponent, MisInputDirective],\n imports: [CommonModule, FormsModule],\n exports: [MisInputComponent, MisInputDirective]\n})\nexport class MisInputModule {}\n"]}
@@ -9,14 +9,13 @@
9
9
  /** Controls loader size */
10
10
  this.mobileView = false;
11
11
  }
12
- LoaderComponent.prototype.ngOnInit = function () {
13
- };
12
+ LoaderComponent.prototype.ngOnInit = function () { };
14
13
  return LoaderComponent;
15
14
  }());
16
15
  LoaderComponent.decorators = [
17
16
  { type: core.Component, args: [{
18
- selector: 'mis-loader',
19
- template: "<div id=\"spinner\" [ngClass]=\"{\n 'mobile': mobileView\n}\"></div>\n",
17
+ selector: "mis-loader",
18
+ template: "<div\n id=\"spinner\"\n [ngClass]=\"{\n mobile: mobileView\n }\"\n></div>\n",
20
19
  styles: ["#spinner{-webkit-animation:frames 1s linear infinite;animation:frames 1s linear infinite;background:transparent;border-radius:100%;border:4px solid #e0e0e0;border-top-color:#6200ee;width:40px;height:40px;padding:0;position:absolute}@-webkit-keyframes frames{0%{transform:rotate(0deg)}to{transform:rotate(359deg)}}@keyframes frames{0%{transform:rotate(0deg)}to{transform:rotate(359deg)}}.mobile{height:20px!important;width:20px!important;border:2px solid #e0e0e0!important;border-top-color:#6200ee!important}"]
21
20
  },] }
22
21
  ];
@@ -1 +1 @@
1
- {"version":3,"file":"mis-crystal-design-system-loader.umd.js","sources":["../../../projects/mis-components/loader/loader.component.ts","../../../projects/mis-components/loader/loader.module.ts","../../../projects/mis-components/loader/mis-crystal-design-system-loader.ts"],"sourcesContent":["import {Component, Input, OnInit} from '@angular/core';\n\n@Component({\n selector: 'mis-loader',\n templateUrl: './loader.component.html',\n styleUrls: ['./loader.component.scss']\n})\nexport class LoaderComponent implements OnInit{\n\n /** Controls loader size */\n @Input() mobileView: boolean = false\n\n constructor() {\n }\n ngOnInit(){\n }\n}\n","import { NgModule, ModuleWithProviders } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { LoaderComponent } from './loader.component';\n\n@NgModule({\n declarations: [LoaderComponent],\n imports: [CommonModule],\n exports: [LoaderComponent]\n})\nexport class LoaderModule {\n static forRoot(): ModuleWithProviders<LoaderModule> {\n return { ngModule: LoaderModule, providers: [] };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["Component","Input","NgModule","CommonModule"],"mappings":";;;;;;;QAYE;;YAFS,eAAU,GAAY,KAAK,CAAA;SAGnC;QACD,kCAAQ,GAAR;SACC;;;;gBAbFA,cAAS,SAAC;oBACT,QAAQ,EAAE,YAAY;oBACtB,mFAAsC;;iBAEvC;;;;6BAIEC,UAAK;;;;QCAR;;QACS,oBAAO,GAAd;YACE,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,SAAS,EAAE,EAAE,EAAE,CAAC;SAClD;;;;gBARFC,aAAQ,SAAC;oBACR,YAAY,EAAE,CAAC,eAAe,CAAC;oBAC/B,OAAO,EAAE,CAACC,mBAAY,CAAC;oBACvB,OAAO,EAAE,CAAC,eAAe,CAAC;iBAC3B;;;ICTD;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"mis-crystal-design-system-loader.umd.js","sources":["../../../projects/mis-components/loader/loader.component.ts","../../../projects/mis-components/loader/loader.module.ts","../../../projects/mis-components/loader/mis-crystal-design-system-loader.ts"],"sourcesContent":["import { Component, Input, OnInit } from \"@angular/core\";\n\n@Component({\n selector: \"mis-loader\",\n templateUrl: \"./loader.component.html\",\n styleUrls: [\"./loader.component.scss\"]\n})\nexport class LoaderComponent implements OnInit {\n /** Controls loader size */\n @Input() mobileView: boolean = false;\n\n constructor() {}\n ngOnInit() {}\n}\n","import { NgModule, ModuleWithProviders } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\n\nimport { LoaderComponent } from \"./loader.component\";\n\n@NgModule({\n declarations: [LoaderComponent],\n imports: [CommonModule],\n exports: [LoaderComponent]\n})\nexport class LoaderModule {\n static forRoot(): ModuleWithProviders<LoaderModule> {\n return { ngModule: LoaderModule, providers: [] };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["Component","Input","NgModule","CommonModule"],"mappings":";;;;;;;QAWE;;YAFS,eAAU,GAAY,KAAK,CAAC;SAErB;QAChB,kCAAQ,GAAR,eAAa;;;;gBAVdA,cAAS,SAAC;oBACT,QAAQ,EAAE,YAAY;oBACtB,6FAAsC;;iBAEvC;;;;6BAGEC,UAAK;;;;QCCR;;QACS,oBAAO,GAAd;YACE,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAE,SAAS,EAAE,EAAE,EAAE,CAAC;SAClD;;;;gBARFC,aAAQ,SAAC;oBACR,YAAY,EAAE,CAAC,eAAe,CAAC;oBAC/B,OAAO,EAAE,CAACC,mBAAY,CAAC;oBACvB,OAAO,EAAE,CAAC,eAAe,CAAC;iBAC3B;;;ICTD;;;;;;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- !function(e,o){"object"==typeof exports&&"undefined"!=typeof module?o(exports,require("@angular/core"),require("@angular/common")):"function"==typeof define&&define.amd?define("mis-crystal-design-system/loader",["exports","@angular/core","@angular/common"],o):o(((e="undefined"!=typeof globalThis?globalThis:e||self)["mis-crystal-design-system"]=e["mis-crystal-design-system"]||{},e["mis-crystal-design-system"].loader={}),e.ng.core,e.ng.common)}(this,(function(e,o,r){"use strict";var t=function(){function e(){this.mobileView=!1}return e.prototype.ngOnInit=function(){},e}();t.decorators=[{type:o.Component,args:[{selector:"mis-loader",template:'<div id="spinner" [ngClass]="{\n \'mobile\': mobileView\n}"></div>\n',styles:["#spinner{-webkit-animation:frames 1s linear infinite;animation:frames 1s linear infinite;background:transparent;border-radius:100%;border:4px solid #e0e0e0;border-top-color:#6200ee;width:40px;height:40px;padding:0;position:absolute}@-webkit-keyframes frames{0%{transform:rotate(0deg)}to{transform:rotate(359deg)}}@keyframes frames{0%{transform:rotate(0deg)}to{transform:rotate(359deg)}}.mobile{height:20px!important;width:20px!important;border:2px solid #e0e0e0!important;border-top-color:#6200ee!important}"]}]}],t.ctorParameters=function(){return[]},t.propDecorators={mobileView:[{type:o.Input}]};var n=function(){function e(){}return e.forRoot=function(){return{ngModule:e,providers:[]}},e}();n.decorators=[{type:o.NgModule,args:[{declarations:[t],imports:[r.CommonModule],exports:[t]}]}],e.LoaderComponent=t,e.LoaderModule=n,Object.defineProperty(e,"__esModule",{value:!0})}));
1
+ !function(e,o){"object"==typeof exports&&"undefined"!=typeof module?o(exports,require("@angular/core"),require("@angular/common")):"function"==typeof define&&define.amd?define("mis-crystal-design-system/loader",["exports","@angular/core","@angular/common"],o):o(((e="undefined"!=typeof globalThis?globalThis:e||self)["mis-crystal-design-system"]=e["mis-crystal-design-system"]||{},e["mis-crystal-design-system"].loader={}),e.ng.core,e.ng.common)}(this,(function(e,o,r){"use strict";var t=function(){function e(){this.mobileView=!1}return e.prototype.ngOnInit=function(){},e}();t.decorators=[{type:o.Component,args:[{selector:"mis-loader",template:'<div\n id="spinner"\n [ngClass]="{\n mobile: mobileView\n }"\n></div>\n',styles:["#spinner{-webkit-animation:frames 1s linear infinite;animation:frames 1s linear infinite;background:transparent;border-radius:100%;border:4px solid #e0e0e0;border-top-color:#6200ee;width:40px;height:40px;padding:0;position:absolute}@-webkit-keyframes frames{0%{transform:rotate(0deg)}to{transform:rotate(359deg)}}@keyframes frames{0%{transform:rotate(0deg)}to{transform:rotate(359deg)}}.mobile{height:20px!important;width:20px!important;border:2px solid #e0e0e0!important;border-top-color:#6200ee!important}"]}]}],t.ctorParameters=function(){return[]},t.propDecorators={mobileView:[{type:o.Input}]};var n=function(){function e(){}return e.forRoot=function(){return{ngModule:e,providers:[]}},e}();n.decorators=[{type:o.NgModule,args:[{declarations:[t],imports:[r.CommonModule],exports:[t]}]}],e.LoaderComponent=t,e.LoaderModule=n,Object.defineProperty(e,"__esModule",{value:!0})}));
2
2
  //# sourceMappingURL=mis-crystal-design-system-loader.umd.min.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../projects/mis-components/loader/loader.component.ts","../../../projects/mis-components/loader/loader.module.ts"],"names":["LoaderComponent","this","mobileView","prototype","ngOnInit","Component","args","selector","template","Input","LoaderModule","forRoot","ngModule","providers","NgModule","declarations","imports","CommonModule","exports"],"mappings":"mfAYE,SAAAA,IAFSC,KAAAC,YAAsB,SAI/BF,EAAAG,UAAAC,SAAA,sCAZDC,EAAAA,UAASC,KAAA,CAAC,CACTC,SAAU,aACVC,SAAA,6pBAMCC,EAAAA,0BCAH,SAAAC,YACSA,EAAAC,QAAP,WACE,MAAO,CAAEC,SAAUF,EAAcG,UAAW,8BAP/CC,EAAAA,SAAQR,KAAA,CAAC,CACRS,aAAc,CAACf,GACfgB,QAAS,CAACC,EAAAA,cACVC,QAAS,CAAClB","sourcesContent":["import {Component, Input, OnInit} from '@angular/core';\n\n@Component({\n selector: 'mis-loader',\n templateUrl: './loader.component.html',\n styleUrls: ['./loader.component.scss']\n})\nexport class LoaderComponent implements OnInit{\n\n /** Controls loader size */\n @Input() mobileView: boolean = false\n\n constructor() {\n }\n ngOnInit(){\n }\n}\n","import { NgModule, ModuleWithProviders } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { LoaderComponent } from './loader.component';\n\n@NgModule({\n declarations: [LoaderComponent],\n imports: [CommonModule],\n exports: [LoaderComponent]\n})\nexport class LoaderModule {\n static forRoot(): ModuleWithProviders<LoaderModule> {\n return { ngModule: LoaderModule, providers: [] };\n }\n}\n"]}
1
+ {"version":3,"sources":["../../../projects/mis-components/loader/loader.component.ts","../../../projects/mis-components/loader/loader.module.ts"],"names":["LoaderComponent","this","mobileView","prototype","ngOnInit","Component","args","selector","template","Input","LoaderModule","forRoot","ngModule","providers","NgModule","declarations","imports","CommonModule","exports"],"mappings":"mfAWE,SAAAA,IAFSC,KAAAC,YAAsB,SAG/BF,EAAAG,UAAAC,SAAA,sCAVDC,EAAAA,UAASC,KAAA,CAAC,CACTC,SAAU,aACVC,SAAA,qqBAKCC,EAAAA,0BCCH,SAAAC,YACSA,EAAAC,QAAP,WACE,MAAO,CAAEC,SAAUF,EAAcG,UAAW,8BAP/CC,EAAAA,SAAQR,KAAA,CAAC,CACRS,aAAc,CAACf,GACfgB,QAAS,CAACC,EAAAA,cACVC,QAAS,CAAClB","sourcesContent":["import { Component, Input, OnInit } from \"@angular/core\";\n\n@Component({\n selector: \"mis-loader\",\n templateUrl: \"./loader.component.html\",\n styleUrls: [\"./loader.component.scss\"]\n})\nexport class LoaderComponent implements OnInit {\n /** Controls loader size */\n @Input() mobileView: boolean = false;\n\n constructor() {}\n ngOnInit() {}\n}\n","import { NgModule, ModuleWithProviders } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\n\nimport { LoaderComponent } from \"./loader.component\";\n\n@NgModule({\n declarations: [LoaderComponent],\n imports: [CommonModule],\n exports: [LoaderComponent]\n})\nexport class LoaderModule {\n static forRoot(): ModuleWithProviders<LoaderModule> {\n return { ngModule: LoaderModule, providers: [] };\n }\n}\n"]}
@@ -42,10 +42,10 @@
42
42
  animations.trigger("slideInOut", [
43
43
  animations.transition(":enter", [
44
44
  animations.style({ transform: "translateY(-30%)", opacity: 0 }),
45
- animations.animate("200ms ease-out", animations.style({ transform: "translatey(0%)", opacity: 1 })),
45
+ animations.animate("200ms ease-out", animations.style({ transform: "translatey(0%)", opacity: 1 }))
46
46
  ]),
47
- animations.transition(":leave", [animations.animate("200ms ease-out", animations.style({ transform: "translatey(-30%)", opacity: 0 }))]),
48
- ]),
47
+ animations.transition(":leave", [animations.animate("200ms ease-out", animations.style({ transform: "translatey(-30%)", opacity: 0 }))])
48
+ ])
49
49
  ],
50
50
  styles: [".mis-modal-body{display:block;width:100%;height:100%;background-color:transparent;border-radius:12px;box-shadow:0 12px 24px rgba(0,0,0,.12),0 4px 8px rgba(0,0,0,.12);overflow:hidden}"]
51
51
  },] }
@@ -70,7 +70,7 @@
70
70
  width: width,
71
71
  height: height,
72
72
  panelClass: "mis-modal",
73
- backdropClass: "mis-modal-overlay",
73
+ backdropClass: "mis-modal-overlay"
74
74
  });
75
75
  var overlayRef = this.overlay.create(config);
76
76
  var modalRef = new ModalRef(overlayRef);
@@ -112,7 +112,7 @@
112
112
  ModalService.ɵprov = i0.ɵɵdefineInjectable({ factory: function ModalService_Factory() { return new ModalService(i0.ɵɵinject(i1.Overlay), i0.ɵɵinject(i0.INJECTOR)); }, token: ModalService, providedIn: "root" });
113
113
  ModalService.decorators = [
114
114
  { type: i0.Injectable, args: [{
115
- providedIn: "root",
115
+ providedIn: "root"
116
116
  },] }
117
117
  ];
118
118
  ModalService.ctorParameters = function () { return [
@@ -126,13 +126,13 @@
126
126
  ModalModule.forRoot = function () {
127
127
  return {
128
128
  ngModule: ModalModule,
129
- providers: [ModalService],
129
+ providers: [ModalService]
130
130
  };
131
131
  };
132
132
  ModalModule.forChild = function () {
133
133
  return {
134
134
  ngModule: ModalModule,
135
- providers: [ModalService],
135
+ providers: [ModalService]
136
136
  };
137
137
  };
138
138
  return ModalModule;
@@ -140,11 +140,7 @@
140
140
  ModalModule.decorators = [
141
141
  { type: i0.NgModule, args: [{
142
142
  declarations: [ModuleWrapperComponent],
143
- imports: [
144
- common.CommonModule,
145
- i1.OverlayModule,
146
- portal.PortalModule
147
- ],
143
+ imports: [common.CommonModule, i1.OverlayModule, portal.PortalModule],
148
144
  entryComponents: [ModuleWrapperComponent]
149
145
  },] }
150
146
  ];
@@ -1 +1 @@
1
- {"version":3,"file":"mis-crystal-design-system-modal.umd.js","sources":["../../../projects/mis-components/modal/modal-constants.ts","../../../projects/mis-components/modal/modal-ref.ts","../../../projects/mis-components/modal/module-wrapper/module-wrapper.component.ts","../../../projects/mis-components/modal/modal.service.ts","../../../projects/mis-components/modal/modal.module.ts","../../../projects/mis-components/modal/mis-crystal-design-system-modal.ts"],"sourcesContent":["/** @format */\n\nimport { InjectionToken } from \"@angular/core\";\n\nexport const MODAL_DATA_VAR = new InjectionToken<any>(\"MISModalDataInjectionToken\");\n","/** @format */\n\nimport { OverlayRef } from \"@angular/cdk/overlay\";\nimport { Injectable } from \"@angular/core\";\nimport { Subject } from \"rxjs\";\n\nexport class ModalRef {\n private afterClosed$ = new Subject<unknown>();\n afterClosed = this.afterClosed$.asObservable();\n\n constructor(public overlay: OverlayRef) {}\n\n close(data?: unknown): void {\n this.overlay.detach();\n this.overlay.dispose();\n this.afterClosed$.next(data);\n this.afterClosed$.complete();\n }\n}\n","import { trigger, transition, style, animate } from \"@angular/animations\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { Component, Injector, OnInit, ViewChild, ViewContainerRef } from \"@angular/core\";\nimport { ModalRef } from \"../modal-ref\";\n\n@Component({\n selector: \"mis-module-wrapper\",\n templateUrl: \"./module-wrapper.component.html\",\n styleUrls: [\"./module-wrapper.component.scss\"],\n animations: [\n trigger(\"slideInOut\", [\n transition(\":enter\", [\n style({ transform: \"translateY(-30%)\", opacity: 0 }),\n animate(\"200ms ease-out\", style({ transform: \"translatey(0%)\", opacity: 1 })),\n ]),\n transition(\":leave\", [animate(\"200ms ease-out\", style({ transform: \"translatey(-30%)\", opacity: 0 }))]),\n ]),\n ],\n})\nexport class ModuleWrapperComponent {\n modalPortal: ComponentPortal<any>;\n constructor() {}\n\n @ViewChild(\"place\", { static: false, read: ViewContainerRef }) place: ViewContainerRef;\n\n bindComponent(type: any, injector: PortalInjector) {\n this.initComponent(type, injector);\n }\n\n private initComponent(type: any, injector: PortalInjector) {\n this.modalPortal = new ComponentPortal(type, this.place, injector);\n }\n}\n","import { ComponentType, Overlay, OverlayConfig } from \"@angular/cdk/overlay\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { ComponentRef, Injectable, Injector } from \"@angular/core\";\nimport { MODAL_DATA_VAR } from \"./modal-constants\";\nimport { ModalRef } from \"./modal-ref\";\nimport { ModuleWrapperComponent } from \"./module-wrapper/module-wrapper.component\";\n\ninterface IModalOptions {\n width?: string;\n height?: string;\n top?: string;\n right?: string;\n bottom?: string;\n left?: string;\n closeOnBackdropClick?: boolean;\n}\n@Injectable({\n providedIn: \"root\",\n})\nexport class ModalService {\n private componentInstance: ComponentRef<ModuleWrapperComponent>;\n\n constructor(private overlay: Overlay, private injector: Injector) {}\n\n show<T, D>(component: ComponentType<T>, data?: D, options?: IModalOptions): ModalRef {\n const positionStrategy = this.calculatePosition(options);\n const { width, height } = options || {};\n const config = new OverlayConfig({\n hasBackdrop: true,\n positionStrategy,\n scrollStrategy: this.overlay.scrollStrategies.noop(),\n width: width,\n height,\n panelClass: \"mis-modal\",\n backdropClass: \"mis-modal-overlay\",\n });\n const overlayRef = this.overlay.create(config);\n const modalRef = new ModalRef(overlayRef);\n const injector = this.createInjector(modalRef, this.injector, data);\n const portal = new ComponentPortal(ModuleWrapperComponent, null);\n this.componentInstance = overlayRef.attach(portal);\n if (options?.closeOnBackdropClick) {\n overlayRef.backdropClick().subscribe(() => modalRef.close());\n }\n this.componentInstance.instance.bindComponent(component, injector);\n return modalRef;\n }\n private createInjector<D>(ref: ModalRef, inj: Injector, data?: D): PortalInjector {\n const injectorTokens = new WeakMap();\n injectorTokens.set(ModalRef, ref);\n injectorTokens.set(MODAL_DATA_VAR, data);\n return new PortalInjector(inj, injectorTokens);\n }\n\n private calculatePosition(options: IModalOptions) {\n const position = this.overlay.position().global().centerHorizontally().centerVertically();\n if (options && screen.width > 600) {\n if (options.top) {\n position.top(options.top);\n }\n if (options.left) {\n position.left(options.left);\n }\n if (options.right) {\n position.right(options.right);\n }\n if (options.bottom) {\n position.bottom(options.bottom);\n }\n }\n return position;\n }\n}\n","import { ModuleWithProviders, NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { OverlayModule } from '@angular/cdk/overlay';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { ModuleWrapperComponent } from './module-wrapper/module-wrapper.component';\nimport { ModalService } from './modal.service';\n\n\n\n@NgModule({\n declarations: [ModuleWrapperComponent],\n imports: [\n CommonModule,\n OverlayModule, \n PortalModule\n ],\n entryComponents: [ModuleWrapperComponent]\n})\nexport class ModalModule { \n static forRoot(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService],\n };\n }\n\n static forChild(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService],\n };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n\nexport {ModuleWrapperComponent as ɵa} from './module-wrapper/module-wrapper.component';"],"names":["InjectionToken","Subject","ComponentPortal","Component","trigger","transition","style","animate","ViewChild","ViewContainerRef","OverlayConfig","portal","PortalInjector","Injectable","Overlay","Injector","NgModule","CommonModule","OverlayModule","PortalModule"],"mappings":";;;;;;IAAA;QAIa,cAAc,GAAG,IAAIA,iBAAc,CAAM,4BAA4B;;ICJlF;;QAUE,kBAAmB,OAAmB;YAAnB,YAAO,GAAP,OAAO,CAAY;YAH9B,iBAAY,GAAG,IAAIC,YAAO,EAAW,CAAC;YAC9C,gBAAW,GAAG,IAAI,CAAC,YAAY,CAAC,YAAY,EAAE,CAAC;SAEL;QAE1C,wBAAK,GAAL,UAAM,IAAc;YAClB,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC;YACtB,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC;YACvB,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YAC7B,IAAI,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC;SAC9B;uBACF;KAAA;;;QCGC;SAAgB;QAIhB,8CAAa,GAAb,UAAc,IAAS,EAAE,QAAwB;YAC/C,IAAI,CAAC,aAAa,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;SACpC;QAEO,8CAAa,GAAb,UAAc,IAAS,EAAE,QAAwB;YACvD,IAAI,CAAC,WAAW,GAAG,IAAIC,sBAAe,CAAC,IAAI,EAAE,IAAI,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;SACpE;;;;gBA1BFC,YAAS,SAAC;oBACT,QAAQ,EAAE,oBAAoB;oBAC9B,wIAA8C;oBAE9C,UAAU,EAAE;wBACVC,kBAAO,CAAC,YAAY,EAAE;4BACpBC,qB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O,CAAC,IAAI,EAAE;oBAChB,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;iBAC7B;gBACD,IAAI,OAAO,CAAC,KAAK,EAAE;oBACjB,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;iBAC/B;gBACD,IAAI,OAAO,CAAC,MAAM,EAAE;oBAClB,QAAQ,CAAC,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;iBACjC;aACF;YACD,OAAO,QAAQ,CAAC;SACjB;;;;;gBAvDFC,aAAU,SAAC;oBACV,UAAU,EAAE,MAAM;iBACnB;;;gBAlBuBC,UAAO;gBAEIC,WAAQ;;;;QCgB3C;;QACS,mBAAO,GAAd;YACE,OAAO;gBACL,QAAQ,EAAE,WAAW;gBACrB,SAAS,EAAE,CAAC,YAAY,CAAC;aAC1B,CAAC;SACH;QAEM,oBAAQ,GAAf;YACE,OAAO;gBACL,QAAQ,EAAE,WAAW;gBACrB,SAAS,EAAE,CAAC,YAAY,CAAC;aAC1B,CAAC;SACH;;;;gBAtBFC,WAAQ,SAAC;oBACR,YAAY,EAAE,CAAC,sBAAsB,CAAC;oBACtC,OAAO,EAAE;wBACPC,mBAAY;wBACZC,gBAAa;wBACbC,mBAAY;qBACb;oBACD,eAAe,EAAE,CAAC,sBAAsB,CAAC;iBAC1C;;;ICjBD;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"mis-crystal-design-system-modal.umd.js","sources":["../../../projects/mis-components/modal/modal-constants.ts","../../../projects/mis-components/modal/modal-ref.ts","../../../projects/mis-components/modal/module-wrapper/module-wrapper.component.ts","../../../projects/mis-components/modal/modal.service.ts","../../../projects/mis-components/modal/modal.module.ts","../../../projects/mis-components/modal/mis-crystal-design-system-modal.ts"],"sourcesContent":["/** @format */\n\nimport { InjectionToken } from \"@angular/core\";\n\nexport const MODAL_DATA_VAR = new InjectionToken<any>(\"MISModalDataInjectionToken\");\n","/** @format */\n\nimport { OverlayRef } from \"@angular/cdk/overlay\";\nimport { Injectable } from \"@angular/core\";\nimport { Subject } from \"rxjs\";\n\nexport class ModalRef {\n private afterClosed$ = new Subject<unknown>();\n afterClosed = this.afterClosed$.asObservable();\n\n constructor(public overlay: OverlayRef) {}\n\n close(data?: unknown): void {\n this.overlay.detach();\n this.overlay.dispose();\n this.afterClosed$.next(data);\n this.afterClosed$.complete();\n }\n}\n","import { trigger, transition, style, animate } from \"@angular/animations\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { Component, Injector, OnInit, ViewChild, ViewContainerRef } from \"@angular/core\";\nimport { ModalRef } from \"../modal-ref\";\n\n@Component({\n selector: \"mis-module-wrapper\",\n templateUrl: \"./module-wrapper.component.html\",\n styleUrls: [\"./module-wrapper.component.scss\"],\n animations: [\n trigger(\"slideInOut\", [\n transition(\":enter\", [\n style({ transform: \"translateY(-30%)\", opacity: 0 }),\n animate(\"200ms ease-out\", style({ transform: \"translatey(0%)\", opacity: 1 }))\n ]),\n transition(\":leave\", [animate(\"200ms ease-out\", style({ transform: \"translatey(-30%)\", opacity: 0 }))])\n ])\n ]\n})\nexport class ModuleWrapperComponent {\n modalPortal: ComponentPortal<any>;\n constructor() {}\n\n @ViewChild(\"place\", { static: false, read: ViewContainerRef }) place: ViewContainerRef;\n\n bindComponent(type: any, injector: PortalInjector) {\n this.initComponent(type, injector);\n }\n\n private initComponent(type: any, injector: PortalInjector) {\n this.modalPortal = new ComponentPortal(type, this.place, injector);\n }\n}\n","import { ComponentType, Overlay, OverlayConfig } from \"@angular/cdk/overlay\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { ComponentRef, Injectable, Injector } from \"@angular/core\";\nimport { MODAL_DATA_VAR } from \"./modal-constants\";\nimport { ModalRef } from \"./modal-ref\";\nimport { ModuleWrapperComponent } from \"./module-wrapper/module-wrapper.component\";\n\ninterface IModalOptions {\n width?: string;\n height?: string;\n top?: string;\n right?: string;\n bottom?: string;\n left?: string;\n closeOnBackdropClick?: boolean;\n}\n@Injectable({\n providedIn: \"root\"\n})\nexport class ModalService {\n private componentInstance: ComponentRef<ModuleWrapperComponent>;\n\n constructor(private overlay: Overlay, private injector: Injector) {}\n\n show<T, D>(component: ComponentType<T>, data?: D, options?: IModalOptions): ModalRef {\n const positionStrategy = this.calculatePosition(options);\n const { width, height } = options || {};\n const config = new OverlayConfig({\n hasBackdrop: true,\n positionStrategy,\n scrollStrategy: this.overlay.scrollStrategies.noop(),\n width: width,\n height,\n panelClass: \"mis-modal\",\n backdropClass: \"mis-modal-overlay\"\n });\n const overlayRef = this.overlay.create(config);\n const modalRef = new ModalRef(overlayRef);\n const injector = this.createInjector(modalRef, this.injector, data);\n const portal = new ComponentPortal(ModuleWrapperComponent, null);\n this.componentInstance = overlayRef.attach(portal);\n if (options?.closeOnBackdropClick) {\n overlayRef.backdropClick().subscribe(() => modalRef.close());\n }\n this.componentInstance.instance.bindComponent(component, injector);\n return modalRef;\n }\n private createInjector<D>(ref: ModalRef, inj: Injector, data?: D): PortalInjector {\n const injectorTokens = new WeakMap();\n injectorTokens.set(ModalRef, ref);\n injectorTokens.set(MODAL_DATA_VAR, data);\n return new PortalInjector(inj, injectorTokens);\n }\n\n private calculatePosition(options: IModalOptions) {\n const position = this.overlay.position().global().centerHorizontally().centerVertically();\n if (options && screen.width > 600) {\n if (options.top) {\n position.top(options.top);\n }\n if (options.left) {\n position.left(options.left);\n }\n if (options.right) {\n position.right(options.right);\n }\n if (options.bottom) {\n position.bottom(options.bottom);\n }\n }\n return position;\n }\n}\n","import { ModuleWithProviders, NgModule } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\nimport { OverlayModule } from \"@angular/cdk/overlay\";\nimport { PortalModule } from \"@angular/cdk/portal\";\nimport { ModuleWrapperComponent } from \"./module-wrapper/module-wrapper.component\";\nimport { ModalService } from \"./modal.service\";\n\n@NgModule({\n declarations: [ModuleWrapperComponent],\n imports: [CommonModule, OverlayModule, PortalModule],\n entryComponents: [ModuleWrapperComponent]\n})\nexport class ModalModule {\n static forRoot(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService]\n };\n }\n\n static forChild(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService]\n };\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n\nexport {ModuleWrapperComponent as ɵa} from './module-wrapper/module-wrapper.component';"],"names":["InjectionToken","Subject","ComponentPortal","Component","trigger","transition","style","animate","ViewChild","ViewContainerRef","OverlayConfig","portal","PortalInjector","Injectable","Overlay","Injector","NgModule","CommonModule","OverlayModule","PortalModule"],"mappings":";;;;;;IAAA;QAIa,cAAc,GAAG,IAAIA,iBAAc,CAAM,4BAA4B;;ICJlF;;QAUE,kBAAmB,OAAmB;YAAnB,YAAO,GAAP,OAAO,CAAY;YAH9B,iBAAY,GAAG,IAAIC,YAAO,EAAW,CAAC;YAC9C,gBAAW,GAAG,IAAI,CAAC,YAAY,CAAC,YAAY,EAAE,CAAC;SAEL;QAE1C,wBAAK,GAAL,UAAM,IAAc;YAClB,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC;YACtB,IAAI,CAAC,OAAO,CAAC,OAAO,EAAE,CAAC;YACvB,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;YAC7B,IAAI,CAAC,YAAY,CAAC,QAAQ,EAAE,CAAC;SAC9B;uBACF;KAAA;;;QCGC;SAAgB;QAIhB,8CAAa,GAAb,UAAc,IAAS,EAAE,QAAwB;YAC/C,IAAI,CAAC,aAAa,CAAC,IAAI,EAAE,QAAQ,CAAC,CAAC;SACpC;QAEO,8CAAa,GAAb,UAAc,IAAS,EAAE,QAAwB;YACvD,IAAI,CAAC,WAAW,GAAG,IAAIC,sBAAe,CAAC,IAAI,EAAE,IAAI,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC;SACpE;;;;gBA1BFC,YAAS,SAAC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OAAO,CAAC,GAAG,EAAE;oBACf,QAAQ,CAAC,GAAG,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;iBAC3B;gBACD,IAAI,OAAO,CAAC,IAAI,EAAE;oBAChB,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;iBAC7B;gBACD,IAAI,OAAO,CAAC,KAAK,EAAE;oBACjB,QAAQ,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;iBAC/B;gBACD,IAAI,OAAO,CAAC,MAAM,EAAE;oBAClB,QAAQ,CAAC,MAAM,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;iBACjC;aACF;YACD,OAAO,QAAQ,CAAC;SACjB;;;;;gBAvDFC,aAAU,SAAC;oBACV,UAAU,EAAE,MAAM;iBACnB;;;gBAlBuBC,UAAO;gBAEIC,WAAQ;;;;QCU3C;;QACS,mBAAO,GAAd;YACE,OAAO;gBACL,QAAQ,EAAE,WAAW;gBACrB,SAAS,EAAE,CAAC,YAAY,CAAC;aAC1B,CAAC;SACH;QAEM,oBAAQ,GAAf;YACE,OAAO;gBACL,QAAQ,EAAE,WAAW;gBACrB,SAAS,EAAE,CAAC,YAAY,CAAC;aAC1B,CAAC;SACH;;;;gBAlBFC,WAAQ,SAAC;oBACR,YAAY,EAAE,CAAC,sBAAsB,CAAC;oBACtC,OAAO,EAAE,CAACC,mBAAY,EAAEC,gBAAa,EAAEC,mBAAY,CAAC;oBACpD,eAAe,EAAE,CAAC,sBAAsB,CAAC;iBAC1C;;;ICXD;;;;;;;;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../projects/mis-components/modal/modal-constants.ts","../../../projects/mis-components/modal/modal-ref.ts","../../../projects/mis-components/modal/module-wrapper/module-wrapper.component.ts","../../../projects/mis-components/modal/modal.service.ts","../../../projects/mis-components/modal/modal.module.ts"],"names":["MODAL_DATA_VAR","InjectionToken","ModalRef","overlay","this","afterClosed$","Subject","afterClosed","asObservable","prototype","close","data","detach","dispose","next","complete","ModuleWrapperComponent","bindComponent","type","injector","initComponent","modalPortal","ComponentPortal","place","Component","args","selector","template","animations","trigger","transition","style","transform","opacity","animate","ViewChild","static","read","ViewContainerRef","ModalService","show","component","options","positionStrategy","calculatePosition","_a","width","height","config","OverlayConfig","hasBackdrop","scrollStrategy","scrollStrategies","noop","panelClass","backdropClass","overlayRef","create","modalRef","createInjector","portal","componentInstance","attach","closeOnBackdropClick","backdropClick","subscribe","instance","ref","inj","injectorTokens","WeakMap","set","PortalInjector","position","global","centerHorizontally","centerVertically","screen","top","left","right","bottom","Injectable","providedIn","Overlay","Injector","ModalModule","forRoot","ngModule","providers","forChild","NgModule","declarations","imports","CommonModule","OverlayModule","PortalModule","entryComponents"],"mappings":"4tBAIaA,EAAiB,IAAIC,EAAAA,eAAoB,2CCMpD,SAAAC,EAAmBC,GAAAC,KAAAD,QAAAA,EAHXC,KAAAC,aAAe,IAAIC,EAAAA,QAC3BF,KAAAG,YAAcH,KAAKC,aAAaG,sBAIhCN,EAAAO,UAAAC,MAAA,SAAMC,GACJP,KAAKD,QAAQS,SACbR,KAAKD,QAAQU,UACbT,KAAKC,aAAaS,KAAKH,GACvBP,KAAKC,aAAaU,8BCKpB,SAAAC,YAIAA,EAAAP,UAAAQ,cAAA,SAAcC,EAAWC,GACvBf,KAAKgB,cAAcF,EAAMC,IAGnBH,EAAAP,UAAAW,cAAA,SAAcF,EAAWC,GAC/Bf,KAAKiB,YAAc,IAAIC,EAAAA,gBAAgBJ,EAAMd,KAAKmB,MAAOJ,6BAzB5DK,EAAAA,UAASC,KAAA,CAAC,CACTC,SAAU,qBACVC,SAAA,2HAEAC,WAAY,CACVC,EAAAA,QAAQ,aAAc,CACpBC,EAAAA,WAAW,SAAU,CACnBC,EAAAA,MAAM,CAAEC,UAAW,mBAAoBC,QAAS,IAChDC,EAAAA,QAAQ,iBAAkBH,EAAAA,MAAM,CAAEC,UAAW,iBAAkBC,QAAS,OAE1EH,EAA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evE,OAdIlC,GAAWmC,OAAO/B,MAAQ,MACxBJ,EAAQoC,KACVL,EAASK,IAAIpC,EAAQoC,KAEnBpC,EAAQqC,MACVN,EAASM,KAAKrC,EAAQqC,MAEpBrC,EAAQsC,OACVP,EAASO,MAAMtC,EAAQsC,OAErBtC,EAAQuC,QACVR,EAASQ,OAAOvC,EAAQuC,SAGrBR,qKAtDVS,EAAAA,WAAUzD,KAAA,CAAC,CACV0D,WAAY,oDAjBUC,EAAAA,eAEWC,EAAAA,6BCgBnC,SAAAC,YACSA,EAAAC,QAAP,WACE,MAAO,CACLC,SAAUF,EACVG,UAAW,CAAClD,KAIT+C,EAAAI,SAAP,WACE,MAAO,CACLF,SAAUF,EACVG,UAAW,CAAClD,8BApBjBoD,EAAAA,SAAQlE,KAAA,CAAC,CACRmE,aAAc,CAAC5E,GACf6E,QAAS,CACPC,EAAAA,aACAC,EAAAA,cACAC,EAAAA,cAEFC,gBAAiB,CAACjF","sourcesContent":["/** @format */\n\nimport { InjectionToken } from \"@angular/core\";\n\nexport const MODAL_DATA_VAR = new InjectionToken<any>(\"MISModalDataInjectionToken\");\n","/** @format */\n\nimport { OverlayRef } from \"@angular/cdk/overlay\";\nimport { Injectable } from \"@angular/core\";\nimport { Subject } from \"rxjs\";\n\nexport class ModalRef {\n private afterClosed$ = new Subject<unknown>();\n afterClosed = this.afterClosed$.asObservable();\n\n constructor(public overlay: OverlayRef) {}\n\n close(data?: unknown): void {\n this.overlay.detach();\n this.overlay.dispose();\n this.afterClosed$.next(data);\n this.afterClosed$.complete();\n }\n}\n","import { trigger, transition, style, animate } from \"@angular/animations\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { Component, Injector, OnInit, ViewChild, ViewContainerRef } from \"@angular/core\";\nimport { ModalRef } from \"../modal-ref\";\n\n@Component({\n selector: \"mis-module-wrapper\",\n templateUrl: \"./module-wrapper.component.html\",\n styleUrls: [\"./module-wrapper.component.scss\"],\n animations: [\n trigger(\"slideInOut\", [\n transition(\":enter\", [\n style({ transform: \"translateY(-30%)\", opacity: 0 }),\n animate(\"200ms ease-out\", style({ transform: \"translatey(0%)\", opacity: 1 })),\n ]),\n transition(\":leave\", [animate(\"200ms ease-out\", style({ transform: \"translatey(-30%)\", opacity: 0 }))]),\n ]),\n ],\n})\nexport class ModuleWrapperComponent {\n modalPortal: ComponentPortal<any>;\n constructor() {}\n\n @ViewChild(\"place\", { static: false, read: ViewContainerRef }) place: ViewContainerRef;\n\n bindComponent(type: any, injector: PortalInjector) {\n this.initComponent(type, injector);\n }\n\n private initComponent(type: any, injector: PortalInjector) {\n this.modalPortal = new ComponentPortal(type, this.place, injector);\n }\n}\n","import { ComponentType, Overlay, OverlayConfig } from \"@angular/cdk/overlay\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { ComponentRef, Injectable, Injector } from \"@angular/core\";\nimport { MODAL_DATA_VAR } from \"./modal-constants\";\nimport { ModalRef } from \"./modal-ref\";\nimport { ModuleWrapperComponent } from \"./module-wrapper/module-wrapper.component\";\n\ninterface IModalOptions {\n width?: string;\n height?: string;\n top?: string;\n right?: string;\n bottom?: string;\n left?: string;\n closeOnBackdropClick?: boolean;\n}\n@Injectable({\n providedIn: \"root\",\n})\nexport class ModalService {\n private componentInstance: ComponentRef<ModuleWrapperComponent>;\n\n constructor(private overlay: Overlay, private injector: Injector) {}\n\n show<T, D>(component: ComponentType<T>, data?: D, options?: IModalOptions): ModalRef {\n const positionStrategy = this.calculatePosition(options);\n const { width, height } = options || {};\n const config = new OverlayConfig({\n hasBackdrop: true,\n positionStrategy,\n scrollStrategy: this.overlay.scrollStrategies.noop(),\n width: width,\n height,\n panelClass: \"mis-modal\",\n backdropClass: \"mis-modal-overlay\",\n });\n const overlayRef = this.overlay.create(config);\n const modalRef = new ModalRef(overlayRef);\n const injector = this.createInjector(modalRef, this.injector, data);\n const portal = new ComponentPortal(ModuleWrapperComponent, null);\n this.componentInstance = overlayRef.attach(portal);\n if (options?.closeOnBackdropClick) {\n overlayRef.backdropClick().subscribe(() => modalRef.close());\n }\n this.componentInstance.instance.bindComponent(component, injector);\n return modalRef;\n }\n private createInjector<D>(ref: ModalRef, inj: Injector, data?: D): PortalInjector {\n const injectorTokens = new WeakMap();\n injectorTokens.set(ModalRef, ref);\n injectorTokens.set(MODAL_DATA_VAR, data);\n return new PortalInjector(inj, injectorTokens);\n }\n\n private calculatePosition(options: IModalOptions) {\n const position = this.overlay.position().global().centerHorizontally().centerVertically();\n if (options && screen.width > 600) {\n if (options.top) {\n position.top(options.top);\n }\n if (options.left) {\n position.left(options.left);\n }\n if (options.right) {\n position.right(options.right);\n }\n if (options.bottom) {\n position.bottom(options.bottom);\n }\n }\n return position;\n }\n}\n","import { ModuleWithProviders, NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { OverlayModule } from '@angular/cdk/overlay';\nimport { PortalModule } from '@angular/cdk/portal';\nimport { ModuleWrapperComponent } from './module-wrapper/module-wrapper.component';\nimport { ModalService } from './modal.service';\n\n\n\n@NgModule({\n declarations: [ModuleWrapperComponent],\n imports: [\n CommonModule,\n OverlayModule, \n PortalModule\n ],\n entryComponents: [ModuleWrapperComponent]\n})\nexport class ModalModule { \n static forRoot(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService],\n };\n }\n\n static forChild(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService],\n };\n }\n}\n"]}
1
+ {"version":3,"sources":["../../../projects/mis-components/modal/modal-constants.ts","../../../projects/mis-components/modal/modal-ref.ts","../../../projects/mis-components/modal/module-wrapper/module-wrapper.component.ts","../../../projects/mis-components/modal/modal.service.ts","../../../projects/mis-components/modal/modal.module.ts"],"names":["MODAL_DATA_VAR","InjectionToken","ModalRef","overlay","this","afterClosed$","Subject","afterClosed","asObservable","prototype","close","data","detach","dispose","next","complete","ModuleWrapperComponent","bindComponent","type","injector","initComponent","modalPortal","ComponentPortal","place","Component","args","selector","template","animations","trigger","transition","style","transform","opacity","animate","ViewChild","static","read","ViewContainerRef","ModalService","show","component","options","positionStrategy","calculatePosition","_a","width","height","config","OverlayConfig","hasBackdrop","scrollStrategy","scrollStrategies","noop","panelClass","backdropClass","overlayRef","create","modalRef","createInjector","portal","componentInstance","attach","closeOnBackdropClick","backdropClick","subscribe","instance","ref","inj","injectorTokens","WeakMap","set","PortalInjector","position","global","centerHorizontally","centerVertically","screen","top","left","right","bottom","Injectable","providedIn","Overlay","Injector","ModalModule","forRoot","ngModule","providers","forChild","NgModule","declarations","imports","CommonModule","OverlayModule","PortalModule","entryComponents"],"mappings":"4tBAIaA,EAAiB,IAAIC,EAAAA,eAAoB,2CCMpD,SAAAC,EAAmBC,GAAAC,KAAAD,QAAAA,EAHXC,KAAAC,aAAe,IAAIC,EAAAA,QAC3BF,KAAAG,YAAcH,KAAKC,aAAaG,sBAIhCN,EAAAO,UAAAC,MAAA,SAAMC,GACJP,KAAKD,QAAQS,SACbR,KAAKD,QAAQU,UACbT,KAAKC,aAAaS,KAAKH,GACvBP,KAAKC,aAAaU,8BCKpB,SAAAC,YAIAA,EAAAP,UAAAQ,cAAA,SAAcC,EAAWC,GACvBf,KAAKgB,cAAcF,EAAMC,IAGnBH,EAAAP,UAAAW,cAAA,SAAcF,EAAWC,GAC/Bf,KAAKiB,YAAc,IAAIC,EAAAA,gBAAgBJ,EAAMd,KAAKmB,MAAOJ,6BAzB5DK,EAAAA,UAASC,KAAA,CAAC,CACTC,SAAU,qBACVC,SAAA,2HAEAC,WAAY,CACVC,EAAAA,QAAQ,aAAc,CACpBC,EAAAA,WAAW,SAAU,CACnBC,EAAAA,MAAM,CAAEC,UAAW,mBAAoBC,QAAS,IAChDC,EAAAA,QAAQ,iBAAkBH,EAAAA,MAAM,CAAEC,UAAW,iBAAkBC,QAAS,OAE1EH,EAAAA,WAAW,SAAU,CAACI,EAAAA,QAAQ,iBAAkBH,EAAAA,MAAM,CAAEC,UAAW,mBAAoBC,QA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EnBpC,EAAQqC,MACVN,EAASM,KAAKrC,EAAQqC,MAEpBrC,EAAQsC,OACVP,EAASO,MAAMtC,EAAQsC,OAErBtC,EAAQuC,QACVR,EAASQ,OAAOvC,EAAQuC,SAGrBR,qKAtDVS,EAAAA,WAAUzD,KAAA,CAAC,CACV0D,WAAY,oDAjBUC,EAAAA,eAEWC,EAAAA,6BCUnC,SAAAC,YACSA,EAAAC,QAAP,WACE,MAAO,CACLC,SAAUF,EACVG,UAAW,CAAClD,KAIT+C,EAAAI,SAAP,WACE,MAAO,CACLF,SAAUF,EACVG,UAAW,CAAClD,8BAhBjBoD,EAAAA,SAAQlE,KAAA,CAAC,CACRmE,aAAc,CAAC5E,GACf6E,QAAS,CAACC,EAAAA,aAAcC,EAAAA,cAAeC,EAAAA,cACvCC,gBAAiB,CAACjF","sourcesContent":["/** @format */\n\nimport { InjectionToken } from \"@angular/core\";\n\nexport const MODAL_DATA_VAR = new InjectionToken<any>(\"MISModalDataInjectionToken\");\n","/** @format */\n\nimport { OverlayRef } from \"@angular/cdk/overlay\";\nimport { Injectable } from \"@angular/core\";\nimport { Subject } from \"rxjs\";\n\nexport class ModalRef {\n private afterClosed$ = new Subject<unknown>();\n afterClosed = this.afterClosed$.asObservable();\n\n constructor(public overlay: OverlayRef) {}\n\n close(data?: unknown): void {\n this.overlay.detach();\n this.overlay.dispose();\n this.afterClosed$.next(data);\n this.afterClosed$.complete();\n }\n}\n","import { trigger, transition, style, animate } from \"@angular/animations\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { Component, Injector, OnInit, ViewChild, ViewContainerRef } from \"@angular/core\";\nimport { ModalRef } from \"../modal-ref\";\n\n@Component({\n selector: \"mis-module-wrapper\",\n templateUrl: \"./module-wrapper.component.html\",\n styleUrls: [\"./module-wrapper.component.scss\"],\n animations: [\n trigger(\"slideInOut\", [\n transition(\":enter\", [\n style({ transform: \"translateY(-30%)\", opacity: 0 }),\n animate(\"200ms ease-out\", style({ transform: \"translatey(0%)\", opacity: 1 }))\n ]),\n transition(\":leave\", [animate(\"200ms ease-out\", style({ transform: \"translatey(-30%)\", opacity: 0 }))])\n ])\n ]\n})\nexport class ModuleWrapperComponent {\n modalPortal: ComponentPortal<any>;\n constructor() {}\n\n @ViewChild(\"place\", { static: false, read: ViewContainerRef }) place: ViewContainerRef;\n\n bindComponent(type: any, injector: PortalInjector) {\n this.initComponent(type, injector);\n }\n\n private initComponent(type: any, injector: PortalInjector) {\n this.modalPortal = new ComponentPortal(type, this.place, injector);\n }\n}\n","import { ComponentType, Overlay, OverlayConfig } from \"@angular/cdk/overlay\";\nimport { ComponentPortal, PortalInjector } from \"@angular/cdk/portal\";\nimport { ComponentRef, Injectable, Injector } from \"@angular/core\";\nimport { MODAL_DATA_VAR } from \"./modal-constants\";\nimport { ModalRef } from \"./modal-ref\";\nimport { ModuleWrapperComponent } from \"./module-wrapper/module-wrapper.component\";\n\ninterface IModalOptions {\n width?: string;\n height?: string;\n top?: string;\n right?: string;\n bottom?: string;\n left?: string;\n closeOnBackdropClick?: boolean;\n}\n@Injectable({\n providedIn: \"root\"\n})\nexport class ModalService {\n private componentInstance: ComponentRef<ModuleWrapperComponent>;\n\n constructor(private overlay: Overlay, private injector: Injector) {}\n\n show<T, D>(component: ComponentType<T>, data?: D, options?: IModalOptions): ModalRef {\n const positionStrategy = this.calculatePosition(options);\n const { width, height } = options || {};\n const config = new OverlayConfig({\n hasBackdrop: true,\n positionStrategy,\n scrollStrategy: this.overlay.scrollStrategies.noop(),\n width: width,\n height,\n panelClass: \"mis-modal\",\n backdropClass: \"mis-modal-overlay\"\n });\n const overlayRef = this.overlay.create(config);\n const modalRef = new ModalRef(overlayRef);\n const injector = this.createInjector(modalRef, this.injector, data);\n const portal = new ComponentPortal(ModuleWrapperComponent, null);\n this.componentInstance = overlayRef.attach(portal);\n if (options?.closeOnBackdropClick) {\n overlayRef.backdropClick().subscribe(() => modalRef.close());\n }\n this.componentInstance.instance.bindComponent(component, injector);\n return modalRef;\n }\n private createInjector<D>(ref: ModalRef, inj: Injector, data?: D): PortalInjector {\n const injectorTokens = new WeakMap();\n injectorTokens.set(ModalRef, ref);\n injectorTokens.set(MODAL_DATA_VAR, data);\n return new PortalInjector(inj, injectorTokens);\n }\n\n private calculatePosition(options: IModalOptions) {\n const position = this.overlay.position().global().centerHorizontally().centerVertically();\n if (options && screen.width > 600) {\n if (options.top) {\n position.top(options.top);\n }\n if (options.left) {\n position.left(options.left);\n }\n if (options.right) {\n position.right(options.right);\n }\n if (options.bottom) {\n position.bottom(options.bottom);\n }\n }\n return position;\n }\n}\n","import { ModuleWithProviders, NgModule } from \"@angular/core\";\nimport { CommonModule } from \"@angular/common\";\nimport { OverlayModule } from \"@angular/cdk/overlay\";\nimport { PortalModule } from \"@angular/cdk/portal\";\nimport { ModuleWrapperComponent } from \"./module-wrapper/module-wrapper.component\";\nimport { ModalService } from \"./modal.service\";\n\n@NgModule({\n declarations: [ModuleWrapperComponent],\n imports: [CommonModule, OverlayModule, PortalModule],\n entryComponents: [ModuleWrapperComponent]\n})\nexport class ModalModule {\n static forRoot(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService]\n };\n }\n\n static forChild(): ModuleWithProviders<ModalModule> {\n return {\n ngModule: ModalModule,\n providers: [ModalService]\n };\n }\n}\n"]}
@@ -367,12 +367,6 @@
367
367
  configurable: true
368
368
  });
369
369
  MultiSelectDropdownComponent.prototype.ngOnInit = function () { };
370
- MultiSelectDropdownComponent.prototype.clickout = function (event) {
371
- var isClickedOutside = !this.eRef.nativeElement.contains(event.target);
372
- if (isClickedOutside) {
373
- this.onCancel();
374
- }
375
- };
376
370
  MultiSelectDropdownComponent.prototype.handlerSetLocalSelectedItems = function (values) {
377
371
  var _this = this;
378
372
  this.localSelectedItems = values;
@@ -583,8 +577,7 @@
583
577
  hideApplyButton: [{ type: core.Input }],
584
578
  onChange: [{ type: core.Output }],
585
579
  selectElement: [{ type: core.ViewChild, args: ["select", { static: false },] }],
586
- popupContainer: [{ type: core.ViewChild, args: ["popupContainer", { static: false },] }],
587
- clickout: [{ type: core.HostListener, args: ["document:click", ["$event"],] }]
580
+ popupContainer: [{ type: core.ViewChild, args: ["popupContainer", { static: false },] }]
588
581
  };
589
582
 
590
583
  var MultiSelectDropdownModule = /** @class */ (function () {
@@ -598,7 +591,7 @@
598
591
  MultiSelectDropdownModule.decorators = [
599
592
  { type: core.NgModule, args: [{
600
593
  declarations: [MultiSelectDropdownComponent],
601
- imports: [common.CommonModule, forms.FormsModule, checkbox.CheckboxModule, button.ButtonModule],
594
+ imports: [common.CommonModule, forms.FormsModule, overlay.OverlayModule, checkbox.CheckboxModule, button.ButtonModule],
602
595
  exports: [MultiSelectDropdownComponent]
603
596
  },] }
604
597
  ];