@ptsecurity/mosaic 14.7.1 → 15.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (727) hide show
  1. package/_index.scss +3 -0
  2. package/_theming.scss +1559 -1685
  3. package/_visual.scss +84 -64
  4. package/autocomplete/_autocomplete-theme.scss +21 -0
  5. package/autocomplete/autocomplete-origin.directive.d.ts +1 -1
  6. package/autocomplete/autocomplete-trigger.directive.d.ts +1 -1
  7. package/autocomplete/autocomplete.component.d.ts +1 -1
  8. package/autocomplete/autocomplete.scss +63 -0
  9. package/button/_button-base.scss +63 -0
  10. package/button/_button-theme.scss +154 -0
  11. package/button/button.component.d.ts +2 -2
  12. package/button/button.scss +45 -0
  13. package/button-toggle/button-toggle.component.d.ts +2 -2
  14. package/button-toggle/button-toggle.scss +135 -0
  15. package/card/_card-theme.scss +61 -0
  16. package/card/card.component.d.ts +1 -1
  17. package/card/card.component.scss +40 -0
  18. package/checkbox/_checkbox-theme.scss +103 -0
  19. package/checkbox/checkbox-required-validator.d.ts +1 -1
  20. package/checkbox/checkbox.d.ts +1 -1
  21. package/checkbox/checkbox.scss +144 -0
  22. package/code-block/_code-block-theme.scss +329 -0
  23. package/code-block/actionbar.component.d.ts +1 -1
  24. package/code-block/actionbar.component.scss +27 -0
  25. package/code-block/code-block.component.d.ts +1 -1
  26. package/code-block/code-block.scss +128 -0
  27. package/core/_index.scss +1 -0
  28. package/core/common-behaviors/color.d.ts +2 -2
  29. package/core/datetime/date-adapter.d.ts +12 -0
  30. package/core/datetime/date-formats.d.ts +4 -0
  31. package/core/datetime/index.d.ts +2 -0
  32. package/core/formatters/date/formatter.d.ts +4 -265
  33. package/core/formatters/date/formatter.pipe.d.ts +3 -2
  34. package/core/forms/_forms-theme.scss +32 -0
  35. package/core/forms/_forms.scss +109 -0
  36. package/core/forms/forms.directive.d.ts +2 -2
  37. package/core/highlight/_highlight-theme.scss +10 -0
  38. package/core/line/line.d.ts +1 -1
  39. package/core/option/_optgroup-theme.scss +26 -0
  40. package/core/option/_option-action-theme.scss +41 -0
  41. package/core/option/_option-theme.scss +46 -0
  42. package/core/option/action.d.ts +1 -1
  43. package/core/option/action.scss +28 -0
  44. package/core/option/optgroup.d.ts +1 -1
  45. package/core/option/optgroup.scss +16 -0
  46. package/core/option/option.d.ts +1 -1
  47. package/core/option/option.scss +62 -0
  48. package/core/pop-up/_pop-up.scss +129 -0
  49. package/core/pop-up/pop-up-trigger.d.ts +1 -1
  50. package/core/pop-up/pop-up.d.ts +1 -1
  51. package/core/public-api.d.ts +11 -10
  52. package/core/selection/pseudo-checkbox/_pseudo-checkbox-theme.scss +48 -0
  53. package/core/selection/pseudo-checkbox/pseudo-checkbox.d.ts +1 -1
  54. package/core/selection/pseudo-checkbox/pseudo-checkbox.scss +57 -0
  55. package/core/styles/_core.scss +11 -0
  56. package/core/styles/_mosaic-theme.scss +147 -0
  57. package/core/styles/_tokens.scss +6 -0
  58. package/core/styles/_variables.scss +9 -0
  59. package/core/styles/common/_animation.scss +35 -0
  60. package/core/styles/common/_button.scss +10 -0
  61. package/core/styles/common/_clearfix.scss +13 -0
  62. package/core/styles/common/_groups.scss +116 -0
  63. package/core/styles/common/_index.scss +13 -0
  64. package/core/styles/common/_input.scss +28 -0
  65. package/core/styles/common/_layout.scss +8 -0
  66. package/core/styles/common/_list.scss +46 -0
  67. package/core/styles/common/_overlay.scss +173 -0
  68. package/core/styles/common/_popup.scss +11 -0
  69. package/core/styles/common/_rtl.scss +33 -0
  70. package/core/styles/common/_size.scss +8 -0
  71. package/core/styles/common/_vendor-prefixes.scss +24 -0
  72. package/core/styles/common/_visually-hidden.scss +36 -0
  73. package/core/styles/functions/_index.scss +3 -0
  74. package/core/styles/functions/_number.scss +65 -0
  75. package/core/styles/functions/_string.scss +19 -0
  76. package/core/styles/functions/_timing.scss +30 -0
  77. package/core/styles/theming/_alerts.scss +166 -0
  78. package/core/styles/theming/_badges.scss +142 -0
  79. package/core/styles/theming/_components-theming.scss +721 -0
  80. package/core/styles/theming/_index.scss +2 -0
  81. package/core/styles/theming/_scrollbars.scss +133 -0
  82. package/core/styles/theming/_theming.scss +155 -0
  83. package/core/styles/typography/_index.scss +2 -0
  84. package/core/styles/typography/_typography-utils.scss +78 -0
  85. package/core/styles/typography/_typography.scss +180 -0
  86. package/core/styles/visual/_body.scss +35 -0
  87. package/core/styles/visual/_index.scss +3 -0
  88. package/core/styles/visual/_layout-media.scss +7 -0
  89. package/core/styles/visual/_layout.scss +527 -0
  90. package/datepicker/_datepicker-theme.scss +103 -0
  91. package/datepicker/calendar-body.component.d.ts +1 -1
  92. package/datepicker/calendar-body.scss +61 -0
  93. package/datepicker/calendar-header.component.d.ts +2 -2
  94. package/datepicker/calendar-header.scss +69 -0
  95. package/datepicker/calendar.component.d.ts +2 -2
  96. package/datepicker/calendar.scss +68 -0
  97. package/datepicker/datepicker-content.scss +32 -0
  98. package/datepicker/datepicker-input.directive.d.ts +2 -2
  99. package/datepicker/datepicker-input.scss +15 -0
  100. package/datepicker/datepicker-toggle.component.d.ts +2 -2
  101. package/datepicker/datepicker-toggle.scss +41 -0
  102. package/datepicker/datepicker.component.d.ts +3 -3
  103. package/datepicker/month-view.component.d.ts +2 -2
  104. package/divider/_divider-theme.scss +13 -0
  105. package/divider/divider.component.d.ts +1 -1
  106. package/divider/divider.scss +47 -0
  107. package/dl/_dl-theme.scss +44 -0
  108. package/dl/dl.component.d.ts +3 -3
  109. package/dl/dl.scss +66 -0
  110. package/dropdown/_dropdown-theme.scss +87 -0
  111. package/dropdown/dropdown-content.directive.d.ts +1 -1
  112. package/dropdown/dropdown-item.component.d.ts +1 -1
  113. package/dropdown/dropdown-item.scss +82 -0
  114. package/dropdown/dropdown-trigger.directive.d.ts +1 -1
  115. package/dropdown/dropdown.component.d.ts +1 -1
  116. package/dropdown/dropdown.scss +79 -0
  117. package/esm2020/autocomplete/autocomplete-origin.directive.mjs +4 -4
  118. package/esm2020/autocomplete/autocomplete-trigger.directive.mjs +4 -4
  119. package/esm2020/autocomplete/autocomplete.component.mjs +6 -6
  120. package/esm2020/autocomplete/autocomplete.module.mjs +5 -5
  121. package/esm2020/button/button.component.mjs +8 -8
  122. package/esm2020/button/button.module.mjs +5 -5
  123. package/esm2020/button-toggle/button-toggle.component.mjs +9 -9
  124. package/esm2020/button-toggle/button-toggle.module.mjs +5 -5
  125. package/esm2020/card/card.component.mjs +5 -5
  126. package/esm2020/card/card.module.mjs +5 -5
  127. package/esm2020/checkbox/checkbox-module.mjs +5 -5
  128. package/esm2020/checkbox/checkbox-required-validator.mjs +4 -4
  129. package/esm2020/checkbox/checkbox.mjs +5 -5
  130. package/esm2020/code-block/actionbar.component.mjs +4 -4
  131. package/esm2020/code-block/code-block.component.mjs +5 -5
  132. package/esm2020/code-block/code-block.module.mjs +5 -5
  133. package/esm2020/core/common-behaviors/color.mjs +3 -3
  134. package/esm2020/core/common-behaviors/common-module.mjs +5 -5
  135. package/esm2020/core/datetime/date-adapter.mjs +15 -0
  136. package/esm2020/core/datetime/date-formats.mjs +3 -0
  137. package/esm2020/core/datetime/index.mjs +3 -0
  138. package/esm2020/core/error/error-options.mjs +7 -7
  139. package/esm2020/core/formatters/date/formatter.mjs +10 -434
  140. package/esm2020/core/formatters/date/formatter.pipe.mjs +42 -42
  141. package/esm2020/core/formatters/index.mjs +5 -5
  142. package/esm2020/core/formatters/number/formatter.mjs +5 -5
  143. package/esm2020/core/forms/forms-module.mjs +5 -5
  144. package/esm2020/core/forms/forms.directive.mjs +7 -7
  145. package/esm2020/core/highlight/highlight.pipe.mjs +4 -4
  146. package/esm2020/core/highlight/index.mjs +5 -5
  147. package/esm2020/core/line/line.mjs +8 -8
  148. package/esm2020/core/option/action.mjs +6 -6
  149. package/esm2020/core/option/optgroup.mjs +5 -5
  150. package/esm2020/core/option/option-module.mjs +5 -5
  151. package/esm2020/core/option/option.mjs +5 -5
  152. package/esm2020/core/pop-up/pop-up-trigger.mjs +4 -4
  153. package/esm2020/core/pop-up/pop-up.mjs +4 -4
  154. package/esm2020/core/public-api.mjs +12 -11
  155. package/esm2020/core/selection/pseudo-checkbox/pseudo-checkbox.mjs +5 -5
  156. package/esm2020/core/selection/pseudo-checkbox/pseudo-checkbox.module.mjs +5 -5
  157. package/esm2020/core/services/measure-scrollbar.service.mjs +4 -4
  158. package/esm2020/core/version.mjs +2 -2
  159. package/esm2020/datepicker/calendar-body.component.mjs +5 -5
  160. package/esm2020/datepicker/calendar-header.component.mjs +8 -9
  161. package/esm2020/datepicker/calendar.component.mjs +7 -7
  162. package/esm2020/datepicker/datepicker-input.directive.mjs +6 -7
  163. package/esm2020/datepicker/datepicker-intl.mjs +4 -4
  164. package/esm2020/datepicker/datepicker-module.mjs +5 -5
  165. package/esm2020/datepicker/datepicker-toggle.component.mjs +8 -8
  166. package/esm2020/datepicker/datepicker.component.mjs +10 -10
  167. package/esm2020/datepicker/month-view.component.mjs +6 -6
  168. package/esm2020/divider/divider.component.mjs +5 -5
  169. package/esm2020/divider/divider.module.mjs +5 -5
  170. package/esm2020/dl/dl.component.mjs +11 -11
  171. package/esm2020/dl/dl.module.mjs +5 -5
  172. package/esm2020/dropdown/dropdown-content.directive.mjs +4 -4
  173. package/esm2020/dropdown/dropdown-item.component.mjs +5 -5
  174. package/esm2020/dropdown/dropdown-trigger.directive.mjs +4 -4
  175. package/esm2020/dropdown/dropdown.component.mjs +6 -6
  176. package/esm2020/dropdown/dropdown.module.mjs +5 -5
  177. package/esm2020/form-field/cleaner.mjs +5 -5
  178. package/esm2020/form-field/form-field.mjs +11 -11
  179. package/esm2020/form-field/form-field.module.mjs +5 -5
  180. package/esm2020/form-field/hint.mjs +4 -4
  181. package/esm2020/form-field/password-hint.mjs +4 -4
  182. package/esm2020/form-field/prefix.mjs +4 -4
  183. package/esm2020/form-field/stepper.mjs +8 -8
  184. package/esm2020/form-field/suffix.mjs +4 -4
  185. package/esm2020/form-field/validate.directive.mjs +4 -4
  186. package/esm2020/icon/icon.component.mjs +7 -7
  187. package/esm2020/icon/icon.module.mjs +5 -5
  188. package/esm2020/input/input-number-validators.mjs +7 -7
  189. package/esm2020/input/input-number.mjs +4 -4
  190. package/esm2020/input/input-password.mjs +7 -7
  191. package/esm2020/input/input.mjs +7 -7
  192. package/esm2020/input/input.module.mjs +5 -5
  193. package/esm2020/link/link.component.mjs +4 -4
  194. package/esm2020/link/link.module.mjs +5 -5
  195. package/esm2020/list/list-selection.component.mjs +9 -9
  196. package/esm2020/list/list.component.mjs +8 -8
  197. package/esm2020/list/list.module.mjs +5 -5
  198. package/esm2020/loader-overlay/loader-overlay.component.mjs +14 -14
  199. package/esm2020/loader-overlay/loader-overlay.module.mjs +5 -5
  200. package/esm2020/markdown/markdown.component.mjs +6 -6
  201. package/esm2020/markdown/markdown.module.mjs +5 -5
  202. package/esm2020/markdown/markdown.service.mjs +4 -4
  203. package/esm2020/modal/css-unit.pipe.mjs +4 -4
  204. package/esm2020/modal/modal-control.service.mjs +4 -4
  205. package/esm2020/modal/modal.component.mjs +5 -5
  206. package/esm2020/modal/modal.directive.mjs +13 -13
  207. package/esm2020/modal/modal.module.mjs +5 -5
  208. package/esm2020/modal/modal.service.mjs +4 -4
  209. package/esm2020/navbar/navbar-item.component.mjs +31 -31
  210. package/esm2020/navbar/navbar.component.mjs +11 -11
  211. package/esm2020/navbar/navbar.module.mjs +5 -5
  212. package/esm2020/navbar/vertical-navbar.animation.mjs +2 -2
  213. package/esm2020/navbar/vertical-navbar.component.mjs +6 -6
  214. package/esm2020/popover/popover-confirm.component.mjs +8 -8
  215. package/esm2020/popover/popover.component.mjs +8 -8
  216. package/esm2020/popover/popover.module.mjs +5 -5
  217. package/esm2020/progress-bar/progress-bar.component.mjs +5 -5
  218. package/esm2020/progress-bar/progress-bar.module.mjs +5 -5
  219. package/esm2020/progress-spinner/progress-spinner.component.mjs +6 -6
  220. package/esm2020/progress-spinner/progress-spinner.module.mjs +5 -5
  221. package/esm2020/radio/radio.component.mjs +8 -8
  222. package/esm2020/radio/radio.module.mjs +5 -5
  223. package/esm2020/select/select-option.directive.mjs +4 -4
  224. package/esm2020/select/select.component.mjs +18 -18
  225. package/esm2020/select/select.module.mjs +5 -5
  226. package/esm2020/sidebar/sidebar.component.mjs +10 -10
  227. package/esm2020/sidebar/sidebar.module.mjs +5 -5
  228. package/esm2020/sidepanel/sidepanel-container.component.mjs +5 -5
  229. package/esm2020/sidepanel/sidepanel-directives.mjs +18 -18
  230. package/esm2020/sidepanel/sidepanel.module.mjs +5 -5
  231. package/esm2020/sidepanel/sidepanel.service.mjs +4 -4
  232. package/esm2020/splitter/splitter.component.mjs +13 -13
  233. package/esm2020/splitter/splitter.module.mjs +5 -5
  234. package/esm2020/table/table.component.mjs +5 -5
  235. package/esm2020/table/table.module.mjs +5 -5
  236. package/esm2020/tabs/paginated-tab-header.mjs +4 -4
  237. package/esm2020/tabs/tab-body.component.mjs +7 -7
  238. package/esm2020/tabs/tab-content.directive.mjs +4 -4
  239. package/esm2020/tabs/tab-group.component.mjs +20 -20
  240. package/esm2020/tabs/tab-header.component.mjs +5 -5
  241. package/esm2020/tabs/tab-label-wrapper.directive.mjs +4 -4
  242. package/esm2020/tabs/tab-label.directive.mjs +4 -4
  243. package/esm2020/tabs/tab-nav-bar/tab-nav-bar.mjs +8 -8
  244. package/esm2020/tabs/tab.component.mjs +4 -4
  245. package/esm2020/tabs/tabs.module.mjs +5 -5
  246. package/esm2020/tags/tag-input.mjs +4 -4
  247. package/esm2020/tags/tag-list.component.mjs +5 -5
  248. package/esm2020/tags/tag.component.mjs +14 -14
  249. package/esm2020/tags/tag.module.mjs +5 -5
  250. package/esm2020/textarea/textarea.component.mjs +4 -4
  251. package/esm2020/textarea/textarea.module.mjs +5 -5
  252. package/esm2020/timepicker/timepicker.directive.mjs +6 -7
  253. package/esm2020/timepicker/timepicker.module.mjs +5 -5
  254. package/esm2020/timezone/cities-by-filter.pipe.mjs +4 -4
  255. package/esm2020/timezone/timezone-option.component.mjs +6 -6
  256. package/esm2020/timezone/timezone-option.directive.mjs +4 -4
  257. package/esm2020/timezone/timezone-select.component.mjs +9 -9
  258. package/esm2020/timezone/timezone.module.mjs +5 -5
  259. package/esm2020/timezone/utc-offset.pipe.mjs +4 -4
  260. package/esm2020/toast/toast-container.component.mjs +5 -5
  261. package/esm2020/toast/toast.component.mjs +5 -5
  262. package/esm2020/toast/toast.module.mjs +5 -5
  263. package/esm2020/toast/toast.service.mjs +4 -4
  264. package/esm2020/toggle/toggle.component.mjs +6 -6
  265. package/esm2020/toggle/toggle.module.mjs +5 -5
  266. package/esm2020/tooltip/tooltip.component.mjs +14 -14
  267. package/esm2020/tooltip/tooltip.module.mjs +5 -5
  268. package/esm2020/tree/node.mjs +4 -4
  269. package/esm2020/tree/outlet.mjs +4 -4
  270. package/esm2020/tree/padding.directive.mjs +5 -5
  271. package/esm2020/tree/toggle.mjs +11 -11
  272. package/esm2020/tree/tree-base.mjs +7 -7
  273. package/esm2020/tree/tree-option.component.mjs +6 -6
  274. package/esm2020/tree/tree-selection.component.mjs +4 -4
  275. package/esm2020/tree/tree.mjs +4 -4
  276. package/esm2020/tree/tree.module.mjs +5 -5
  277. package/esm2020/tree-select/tree-select.component.mjs +12 -12
  278. package/esm2020/tree-select/tree-select.module.mjs +5 -5
  279. package/fesm2015/ptsecurity-mosaic-autocomplete.mjs +15 -15
  280. package/fesm2015/ptsecurity-mosaic-autocomplete.mjs.map +1 -1
  281. package/fesm2015/ptsecurity-mosaic-button-toggle.mjs +12 -12
  282. package/fesm2015/ptsecurity-mosaic-button-toggle.mjs.map +1 -1
  283. package/fesm2015/ptsecurity-mosaic-button.mjs +11 -11
  284. package/fesm2015/ptsecurity-mosaic-button.mjs.map +1 -1
  285. package/fesm2015/ptsecurity-mosaic-card.mjs +8 -8
  286. package/fesm2015/ptsecurity-mosaic-card.mjs.map +1 -1
  287. package/fesm2015/ptsecurity-mosaic-checkbox.mjs +11 -11
  288. package/fesm2015/ptsecurity-mosaic-checkbox.mjs.map +1 -1
  289. package/fesm2015/ptsecurity-mosaic-code-block.mjs +11 -11
  290. package/fesm2015/ptsecurity-mosaic-code-block.mjs.map +1 -1
  291. package/fesm2015/ptsecurity-mosaic-core.mjs +789 -1877
  292. package/fesm2015/ptsecurity-mosaic-core.mjs.map +1 -1
  293. package/fesm2015/ptsecurity-mosaic-datepicker.mjs +42 -44
  294. package/fesm2015/ptsecurity-mosaic-datepicker.mjs.map +1 -1
  295. package/fesm2015/ptsecurity-mosaic-divider.mjs +8 -8
  296. package/fesm2015/ptsecurity-mosaic-divider.mjs.map +1 -1
  297. package/fesm2015/ptsecurity-mosaic-dl.mjs +14 -14
  298. package/fesm2015/ptsecurity-mosaic-dl.mjs.map +1 -1
  299. package/fesm2015/ptsecurity-mosaic-dropdown.mjs +19 -19
  300. package/fesm2015/ptsecurity-mosaic-dropdown.mjs.map +1 -1
  301. package/fesm2015/ptsecurity-mosaic-form-field.mjs +40 -40
  302. package/fesm2015/ptsecurity-mosaic-form-field.mjs.map +1 -1
  303. package/fesm2015/ptsecurity-mosaic-icon.mjs +10 -10
  304. package/fesm2015/ptsecurity-mosaic-icon.mjs.map +1 -1
  305. package/fesm2015/ptsecurity-mosaic-input.mjs +25 -25
  306. package/fesm2015/ptsecurity-mosaic-input.mjs.map +1 -1
  307. package/fesm2015/ptsecurity-mosaic-link.mjs +7 -7
  308. package/fesm2015/ptsecurity-mosaic-link.mjs.map +1 -1
  309. package/fesm2015/ptsecurity-mosaic-list.mjs +19 -19
  310. package/fesm2015/ptsecurity-mosaic-list.mjs.map +1 -1
  311. package/fesm2015/ptsecurity-mosaic-loader-overlay.mjs +17 -17
  312. package/fesm2015/ptsecurity-mosaic-loader-overlay.mjs.map +1 -1
  313. package/fesm2015/ptsecurity-mosaic-markdown.mjs +12 -12
  314. package/fesm2015/ptsecurity-mosaic-markdown.mjs.map +1 -1
  315. package/fesm2015/ptsecurity-mosaic-modal.mjs +29 -29
  316. package/fesm2015/ptsecurity-mosaic-modal.mjs.map +1 -1
  317. package/fesm2015/ptsecurity-mosaic-navbar.mjs +50 -50
  318. package/fesm2015/ptsecurity-mosaic-navbar.mjs.map +1 -1
  319. package/fesm2015/ptsecurity-mosaic-popover.mjs +18 -18
  320. package/fesm2015/ptsecurity-mosaic-popover.mjs.map +1 -1
  321. package/fesm2015/ptsecurity-mosaic-progress-bar.mjs +8 -8
  322. package/fesm2015/ptsecurity-mosaic-progress-bar.mjs.map +1 -1
  323. package/fesm2015/ptsecurity-mosaic-progress-spinner.mjs +9 -9
  324. package/fesm2015/ptsecurity-mosaic-progress-spinner.mjs.map +1 -1
  325. package/fesm2015/ptsecurity-mosaic-radio.mjs +11 -11
  326. package/fesm2015/ptsecurity-mosaic-radio.mjs.map +1 -1
  327. package/fesm2015/ptsecurity-mosaic-select.mjs +24 -24
  328. package/fesm2015/ptsecurity-mosaic-select.mjs.map +1 -1
  329. package/fesm2015/ptsecurity-mosaic-sidebar.mjs +13 -13
  330. package/fesm2015/ptsecurity-mosaic-sidebar.mjs.map +1 -1
  331. package/fesm2015/ptsecurity-mosaic-sidepanel.mjs +28 -28
  332. package/fesm2015/ptsecurity-mosaic-sidepanel.mjs.map +1 -1
  333. package/fesm2015/ptsecurity-mosaic-splitter.mjs +16 -16
  334. package/fesm2015/ptsecurity-mosaic-splitter.mjs.map +1 -1
  335. package/fesm2015/ptsecurity-mosaic-table.mjs +8 -8
  336. package/fesm2015/ptsecurity-mosaic-table.mjs.map +1 -1
  337. package/fesm2015/ptsecurity-mosaic-tabs.mjs +55 -55
  338. package/fesm2015/ptsecurity-mosaic-tabs.mjs.map +1 -1
  339. package/fesm2015/ptsecurity-mosaic-tags.mjs +24 -24
  340. package/fesm2015/ptsecurity-mosaic-tags.mjs.map +1 -1
  341. package/fesm2015/ptsecurity-mosaic-textarea.mjs +7 -7
  342. package/fesm2015/ptsecurity-mosaic-textarea.mjs.map +1 -1
  343. package/fesm2015/ptsecurity-mosaic-timepicker.mjs +8 -8
  344. package/fesm2015/ptsecurity-mosaic-timepicker.mjs.map +1 -1
  345. package/fesm2015/ptsecurity-mosaic-timezone.mjs +26 -26
  346. package/fesm2015/ptsecurity-mosaic-timezone.mjs.map +1 -1
  347. package/fesm2015/ptsecurity-mosaic-toast.mjs +15 -15
  348. package/fesm2015/ptsecurity-mosaic-toast.mjs.map +1 -1
  349. package/fesm2015/ptsecurity-mosaic-toggle.mjs +9 -9
  350. package/fesm2015/ptsecurity-mosaic-toggle.mjs.map +1 -1
  351. package/fesm2015/ptsecurity-mosaic-tooltip.mjs +17 -17
  352. package/fesm2015/ptsecurity-mosaic-tooltip.mjs.map +1 -1
  353. package/fesm2015/ptsecurity-mosaic-tree-select.mjs +15 -15
  354. package/fesm2015/ptsecurity-mosaic-tree-select.mjs.map +1 -1
  355. package/fesm2015/ptsecurity-mosaic-tree.mjs +41 -41
  356. package/fesm2015/ptsecurity-mosaic-tree.mjs.map +1 -1
  357. package/fesm2020/ptsecurity-mosaic-autocomplete.mjs +15 -15
  358. package/fesm2020/ptsecurity-mosaic-autocomplete.mjs.map +1 -1
  359. package/fesm2020/ptsecurity-mosaic-button-toggle.mjs +12 -12
  360. package/fesm2020/ptsecurity-mosaic-button-toggle.mjs.map +1 -1
  361. package/fesm2020/ptsecurity-mosaic-button.mjs +11 -11
  362. package/fesm2020/ptsecurity-mosaic-button.mjs.map +1 -1
  363. package/fesm2020/ptsecurity-mosaic-card.mjs +8 -8
  364. package/fesm2020/ptsecurity-mosaic-card.mjs.map +1 -1
  365. package/fesm2020/ptsecurity-mosaic-checkbox.mjs +11 -11
  366. package/fesm2020/ptsecurity-mosaic-checkbox.mjs.map +1 -1
  367. package/fesm2020/ptsecurity-mosaic-code-block.mjs +11 -11
  368. package/fesm2020/ptsecurity-mosaic-code-block.mjs.map +1 -1
  369. package/fesm2020/ptsecurity-mosaic-core.mjs +785 -1900
  370. package/fesm2020/ptsecurity-mosaic-core.mjs.map +1 -1
  371. package/fesm2020/ptsecurity-mosaic-datepicker.mjs +42 -44
  372. package/fesm2020/ptsecurity-mosaic-datepicker.mjs.map +1 -1
  373. package/fesm2020/ptsecurity-mosaic-divider.mjs +8 -8
  374. package/fesm2020/ptsecurity-mosaic-divider.mjs.map +1 -1
  375. package/fesm2020/ptsecurity-mosaic-dl.mjs +14 -14
  376. package/fesm2020/ptsecurity-mosaic-dl.mjs.map +1 -1
  377. package/fesm2020/ptsecurity-mosaic-dropdown.mjs +19 -19
  378. package/fesm2020/ptsecurity-mosaic-dropdown.mjs.map +1 -1
  379. package/fesm2020/ptsecurity-mosaic-form-field.mjs +40 -40
  380. package/fesm2020/ptsecurity-mosaic-form-field.mjs.map +1 -1
  381. package/fesm2020/ptsecurity-mosaic-icon.mjs +10 -10
  382. package/fesm2020/ptsecurity-mosaic-icon.mjs.map +1 -1
  383. package/fesm2020/ptsecurity-mosaic-input.mjs +25 -25
  384. package/fesm2020/ptsecurity-mosaic-input.mjs.map +1 -1
  385. package/fesm2020/ptsecurity-mosaic-link.mjs +7 -7
  386. package/fesm2020/ptsecurity-mosaic-link.mjs.map +1 -1
  387. package/fesm2020/ptsecurity-mosaic-list.mjs +19 -19
  388. package/fesm2020/ptsecurity-mosaic-list.mjs.map +1 -1
  389. package/fesm2020/ptsecurity-mosaic-loader-overlay.mjs +17 -17
  390. package/fesm2020/ptsecurity-mosaic-loader-overlay.mjs.map +1 -1
  391. package/fesm2020/ptsecurity-mosaic-markdown.mjs +12 -12
  392. package/fesm2020/ptsecurity-mosaic-markdown.mjs.map +1 -1
  393. package/fesm2020/ptsecurity-mosaic-modal.mjs +29 -29
  394. package/fesm2020/ptsecurity-mosaic-modal.mjs.map +1 -1
  395. package/fesm2020/ptsecurity-mosaic-navbar.mjs +50 -50
  396. package/fesm2020/ptsecurity-mosaic-navbar.mjs.map +1 -1
  397. package/fesm2020/ptsecurity-mosaic-popover.mjs +18 -18
  398. package/fesm2020/ptsecurity-mosaic-popover.mjs.map +1 -1
  399. package/fesm2020/ptsecurity-mosaic-progress-bar.mjs +8 -8
  400. package/fesm2020/ptsecurity-mosaic-progress-bar.mjs.map +1 -1
  401. package/fesm2020/ptsecurity-mosaic-progress-spinner.mjs +9 -9
  402. package/fesm2020/ptsecurity-mosaic-progress-spinner.mjs.map +1 -1
  403. package/fesm2020/ptsecurity-mosaic-radio.mjs +11 -11
  404. package/fesm2020/ptsecurity-mosaic-radio.mjs.map +1 -1
  405. package/fesm2020/ptsecurity-mosaic-select.mjs +24 -24
  406. package/fesm2020/ptsecurity-mosaic-select.mjs.map +1 -1
  407. package/fesm2020/ptsecurity-mosaic-sidebar.mjs +13 -13
  408. package/fesm2020/ptsecurity-mosaic-sidebar.mjs.map +1 -1
  409. package/fesm2020/ptsecurity-mosaic-sidepanel.mjs +28 -28
  410. package/fesm2020/ptsecurity-mosaic-sidepanel.mjs.map +1 -1
  411. package/fesm2020/ptsecurity-mosaic-splitter.mjs +16 -16
  412. package/fesm2020/ptsecurity-mosaic-splitter.mjs.map +1 -1
  413. package/fesm2020/ptsecurity-mosaic-table.mjs +8 -8
  414. package/fesm2020/ptsecurity-mosaic-table.mjs.map +1 -1
  415. package/fesm2020/ptsecurity-mosaic-tabs.mjs +55 -55
  416. package/fesm2020/ptsecurity-mosaic-tabs.mjs.map +1 -1
  417. package/fesm2020/ptsecurity-mosaic-tags.mjs +24 -24
  418. package/fesm2020/ptsecurity-mosaic-tags.mjs.map +1 -1
  419. package/fesm2020/ptsecurity-mosaic-textarea.mjs +7 -7
  420. package/fesm2020/ptsecurity-mosaic-textarea.mjs.map +1 -1
  421. package/fesm2020/ptsecurity-mosaic-timepicker.mjs +8 -8
  422. package/fesm2020/ptsecurity-mosaic-timepicker.mjs.map +1 -1
  423. package/fesm2020/ptsecurity-mosaic-timezone.mjs +26 -26
  424. package/fesm2020/ptsecurity-mosaic-timezone.mjs.map +1 -1
  425. package/fesm2020/ptsecurity-mosaic-toast.mjs +15 -15
  426. package/fesm2020/ptsecurity-mosaic-toast.mjs.map +1 -1
  427. package/fesm2020/ptsecurity-mosaic-toggle.mjs +9 -9
  428. package/fesm2020/ptsecurity-mosaic-toggle.mjs.map +1 -1
  429. package/fesm2020/ptsecurity-mosaic-tooltip.mjs +17 -17
  430. package/fesm2020/ptsecurity-mosaic-tooltip.mjs.map +1 -1
  431. package/fesm2020/ptsecurity-mosaic-tree-select.mjs +15 -15
  432. package/fesm2020/ptsecurity-mosaic-tree-select.mjs.map +1 -1
  433. package/fesm2020/ptsecurity-mosaic-tree.mjs +41 -41
  434. package/fesm2020/ptsecurity-mosaic-tree.mjs.map +1 -1
  435. package/form-field/_form-field-theme.scss +133 -0
  436. package/form-field/cleaner.d.ts +1 -1
  437. package/form-field/form-field.d.ts +3 -3
  438. package/form-field/form-field.scss +163 -0
  439. package/form-field/hint.d.ts +1 -1
  440. package/form-field/password-hint.d.ts +1 -1
  441. package/form-field/prefix.d.ts +1 -1
  442. package/form-field/stepper.d.ts +1 -1
  443. package/form-field/suffix.d.ts +1 -1
  444. package/form-field/validate.directive.d.ts +1 -1
  445. package/icon/_icon-theme.scss +152 -0
  446. package/icon/icon.component.d.ts +2 -2
  447. package/icon/icon.scss +30 -0
  448. package/input/_input-base.scss +21 -0
  449. package/input/_input-theme.scss +58 -0
  450. package/input/input-number-validators.d.ts +2 -2
  451. package/input/input-number.d.ts +1 -1
  452. package/input/input-password.d.ts +2 -2
  453. package/input/input.d.ts +2 -2
  454. package/input/input.scss +62 -0
  455. package/link/_link-theme.scss +172 -0
  456. package/link/link.component.d.ts +1 -1
  457. package/list/_list-base.scss +50 -0
  458. package/list/_list-theme.scss +49 -0
  459. package/list/list-selection.component.d.ts +2 -2
  460. package/list/list.component.d.ts +2 -2
  461. package/list/list.scss +52 -0
  462. package/loader-overlay/_loader-overlay-theme.scss +36 -0
  463. package/loader-overlay/loader-overlay.component.d.ts +4 -4
  464. package/loader-overlay/loader-overlay.scss +64 -0
  465. package/markdown/_markdown-theme.scss +142 -0
  466. package/markdown/markdown.component.d.ts +1 -1
  467. package/markdown/markdown.scss +240 -0
  468. package/modal/_modal-animation.scss +114 -0
  469. package/modal/_modal-confirm.scss +53 -0
  470. package/modal/_modal-theme.scss +90 -0
  471. package/modal/modal.component.d.ts +1 -1
  472. package/modal/modal.directive.d.ts +4 -4
  473. package/modal/modal.scss +143 -0
  474. package/navbar/_navbar-theme.scss +125 -0
  475. package/navbar/navbar-brand.scss +70 -0
  476. package/navbar/navbar-divider.scss +18 -0
  477. package/navbar/navbar-item.component.d.ts +10 -10
  478. package/navbar/navbar-item.scss +159 -0
  479. package/navbar/navbar.component.d.ts +3 -3
  480. package/navbar/navbar.scss +20 -0
  481. package/navbar/vertical-navbar.component.d.ts +1 -1
  482. package/navbar/vertical-navbar.scss +46 -0
  483. package/package.json +28 -27
  484. package/popover/_popover-theme.scss +113 -0
  485. package/popover/popover-confirm.component.d.ts +2 -2
  486. package/popover/popover.component.d.ts +2 -2
  487. package/popover/popover.scss +114 -0
  488. package/prebuilt-themes/dark-theme.css +1 -1
  489. package/prebuilt-themes/default-theme.css +1 -1
  490. package/prebuilt-visual/default-visual.css +1 -1
  491. package/progress-bar/_progress-bar-theme.scss +28 -0
  492. package/progress-bar/progress-bar.component.d.ts +1 -1
  493. package/progress-bar/progress-bar.scss +42 -0
  494. package/progress-spinner/_progress-spinner-theme.scss +24 -0
  495. package/progress-spinner/progress-spinner.component.d.ts +1 -1
  496. package/progress-spinner/progress-spinner.scss +70 -0
  497. package/radio/_radio-theme.scss +99 -0
  498. package/radio/radio.component.d.ts +2 -2
  499. package/radio/radio.scss +110 -0
  500. package/select/_select-theme.scss +57 -0
  501. package/select/select-option.directive.d.ts +1 -1
  502. package/select/select.component.d.ts +5 -5
  503. package/select/select.scss +197 -0
  504. package/sidebar/sidebar.component.d.ts +3 -3
  505. package/sidebar/sidebar.scss +12 -0
  506. package/sidepanel/_sidepanel-theme.scss +69 -0
  507. package/sidepanel/sidepanel-container.component.d.ts +1 -1
  508. package/sidepanel/sidepanel-directives.d.ts +5 -5
  509. package/sidepanel/sidepanel.scss +190 -0
  510. package/splitter/_splitter-theme.scss +31 -0
  511. package/splitter/splitter.component.d.ts +4 -4
  512. package/splitter/splitter.scss +48 -0
  513. package/table/_table-theme.scss +67 -0
  514. package/table/table.component.d.ts +1 -1
  515. package/table/table.scss +76 -0
  516. package/tabs/_tabs-common.scss +197 -0
  517. package/tabs/_tabs-theme.scss +241 -0
  518. package/tabs/paginated-tab-header.d.ts +1 -1
  519. package/tabs/tab-body.component.d.ts +2 -2
  520. package/tabs/tab-body.scss +8 -0
  521. package/tabs/tab-content.directive.d.ts +1 -1
  522. package/tabs/tab-group.component.d.ts +6 -6
  523. package/tabs/tab-group.scss +63 -0
  524. package/tabs/tab-header.component.d.ts +1 -1
  525. package/tabs/tab-header.scss +106 -0
  526. package/tabs/tab-label-wrapper.directive.d.ts +1 -1
  527. package/tabs/tab-label.directive.d.ts +1 -1
  528. package/tabs/tab-nav-bar/tab-nav-bar.d.ts +2 -2
  529. package/tabs/tab-nav-bar/tab-nav-bar.scss +54 -0
  530. package/tabs/tab.component.d.ts +1 -1
  531. package/tags/_tag-theme.scss +122 -0
  532. package/tags/tag-input.d.ts +1 -1
  533. package/tags/tag-list.component.d.ts +1 -1
  534. package/tags/tag-list.scss +52 -0
  535. package/tags/tag.component.d.ts +4 -4
  536. package/tags/tag.scss +115 -0
  537. package/textarea/_textarea-base.scss +22 -0
  538. package/textarea/_textarea-theme.scss +40 -0
  539. package/textarea/textarea.component.d.ts +1 -1
  540. package/textarea/textarea.scss +32 -0
  541. package/timepicker/timepicker.directive.d.ts +2 -2
  542. package/timepicker/timepicker.scss +18 -0
  543. package/timezone/_timezone-option-theme.scss +36 -0
  544. package/timezone/timezone-option.component.d.ts +1 -1
  545. package/timezone/timezone-option.component.scss +35 -0
  546. package/timezone/timezone-option.directive.d.ts +1 -1
  547. package/timezone/timezone-select.component.d.ts +2 -2
  548. package/toast/_toast-theme.scss +64 -0
  549. package/toast/toast-container.component.d.ts +1 -1
  550. package/toast/toast-container.component.scss +23 -0
  551. package/toast/toast.component.d.ts +1 -1
  552. package/toast/toast.component.scss +76 -0
  553. package/toggle/_toggle-theme.scss +82 -0
  554. package/toggle/toggle.component.d.ts +1 -1
  555. package/toggle/toggle.scss +124 -0
  556. package/tooltip/_tooltip-theme.scss +104 -0
  557. package/tooltip/tooltip.component.d.ts +4 -4
  558. package/tooltip/tooltip.scss +75 -0
  559. package/tree/_tree-theme.scss +70 -0
  560. package/tree/node.d.ts +1 -1
  561. package/tree/outlet.d.ts +1 -1
  562. package/tree/padding.directive.d.ts +1 -1
  563. package/tree/toggle.d.ts +3 -3
  564. package/tree/toggle.scss +35 -0
  565. package/tree/tree-base.d.ts +2 -2
  566. package/tree/tree-option.component.d.ts +1 -1
  567. package/tree/tree-option.scss +67 -0
  568. package/tree/tree-selection.component.d.ts +1 -1
  569. package/tree/tree-selection.scss +3 -0
  570. package/tree/tree.d.ts +1 -1
  571. package/tree/tree.scss +3 -0
  572. package/tree-select/_tree-select-theme.scss +44 -0
  573. package/tree-select/tree-select.component.d.ts +3 -3
  574. package/tree-select/tree-select.scss +212 -0
  575. package/core/formatters/date/templates/en-US.d.ts +0 -2
  576. package/core/formatters/date/templates/ru-RU.d.ts +0 -2
  577. package/design-tokens/index.d.ts +0 -1
  578. package/design-tokens/legacy-2017/tokens/components/alert.json5 +0 -83
  579. package/design-tokens/legacy-2017/tokens/components/autocomplete.json5 +0 -11
  580. package/design-tokens/legacy-2017/tokens/components/badge.json5 +0 -174
  581. package/design-tokens/legacy-2017/tokens/components/button-toggle.json5 +0 -11
  582. package/design-tokens/legacy-2017/tokens/components/button.json5 +0 -142
  583. package/design-tokens/legacy-2017/tokens/components/card.json5 +0 -51
  584. package/design-tokens/legacy-2017/tokens/components/checkbox.json5 +0 -106
  585. package/design-tokens/legacy-2017/tokens/components/code-block.json5 +0 -704
  586. package/design-tokens/legacy-2017/tokens/components/datepicker.json5 +0 -73
  587. package/design-tokens/legacy-2017/tokens/components/divider.json5 +0 -14
  588. package/design-tokens/legacy-2017/tokens/components/dl.json5 +0 -38
  589. package/design-tokens/legacy-2017/tokens/components/dropdown.json5 +0 -48
  590. package/design-tokens/legacy-2017/tokens/components/form-field.json5 +0 -92
  591. package/design-tokens/legacy-2017/tokens/components/forms.json5 +0 -48
  592. package/design-tokens/legacy-2017/tokens/components/icon.json5 +0 -104
  593. package/design-tokens/legacy-2017/tokens/components/input.json5 +0 -12
  594. package/design-tokens/legacy-2017/tokens/components/link.json5 +0 -50
  595. package/design-tokens/legacy-2017/tokens/components/list.json5 +0 -13
  596. package/design-tokens/legacy-2017/tokens/components/loader-overlay.json5 +0 -23
  597. package/design-tokens/legacy-2017/tokens/components/markdown.json5 +0 -294
  598. package/design-tokens/legacy-2017/tokens/components/modal.json5 +0 -81
  599. package/design-tokens/legacy-2017/tokens/components/navbar.json5 +0 -70
  600. package/design-tokens/legacy-2017/tokens/components/optgroup.json5 +0 -10
  601. package/design-tokens/legacy-2017/tokens/components/option.json5 +0 -12
  602. package/design-tokens/legacy-2017/tokens/components/popover.json5 +0 -69
  603. package/design-tokens/legacy-2017/tokens/components/popup.json5 +0 -16
  604. package/design-tokens/legacy-2017/tokens/components/progress-bar.json5 +0 -13
  605. package/design-tokens/legacy-2017/tokens/components/progress-spinner.json5 +0 -16
  606. package/design-tokens/legacy-2017/tokens/components/radio.json5 +0 -47
  607. package/design-tokens/legacy-2017/tokens/components/scrollbars.json5 +0 -52
  608. package/design-tokens/legacy-2017/tokens/components/select.json5 +0 -24
  609. package/design-tokens/legacy-2017/tokens/components/sidepanel.json5 +0 -44
  610. package/design-tokens/legacy-2017/tokens/components/table.json5 +0 -15
  611. package/design-tokens/legacy-2017/tokens/components/tabs.json5 +0 -101
  612. package/design-tokens/legacy-2017/tokens/components/tags.json5 +0 -134
  613. package/design-tokens/legacy-2017/tokens/components/textarea.json5 +0 -12
  614. package/design-tokens/legacy-2017/tokens/components/timepicker.json5 +0 -7
  615. package/design-tokens/legacy-2017/tokens/components/timezone.json5 +0 -23
  616. package/design-tokens/legacy-2017/tokens/components/toast.json5 +0 -54
  617. package/design-tokens/legacy-2017/tokens/components/toggle.json5 +0 -79
  618. package/design-tokens/legacy-2017/tokens/components/tooltip.json5 +0 -83
  619. package/design-tokens/legacy-2017/tokens/components/tree.json5 +0 -15
  620. package/design-tokens/legacy-2017/tokens/properties/aliases.json5 +0 -3
  621. package/design-tokens/legacy-2017/tokens/properties/colors.json5 +0 -119
  622. package/design-tokens/legacy-2017/tokens/properties/font.json5 +0 -12
  623. package/design-tokens/legacy-2017/tokens/properties/globals.json5 +0 -49
  624. package/design-tokens/legacy-2017/tokens/properties/md-typography.json5 +0 -103
  625. package/design-tokens/legacy-2017/tokens/properties/padding.json5 +0 -3
  626. package/design-tokens/legacy-2017/tokens/properties/palette.json5 +0 -163
  627. package/design-tokens/legacy-2017/tokens/properties/typography.json5 +0 -184
  628. package/design-tokens/legacy-2017/tokens.d.ts +0 -8520
  629. package/design-tokens/pt-2022/tokens/components/alert.json5 +0 -83
  630. package/design-tokens/pt-2022/tokens/components/autocomplete.json5 +0 -11
  631. package/design-tokens/pt-2022/tokens/components/badge.json5 +0 -174
  632. package/design-tokens/pt-2022/tokens/components/button-toggle.json5 +0 -11
  633. package/design-tokens/pt-2022/tokens/components/button.json5 +0 -142
  634. package/design-tokens/pt-2022/tokens/components/card.json5 +0 -51
  635. package/design-tokens/pt-2022/tokens/components/checkbox.json5 +0 -106
  636. package/design-tokens/pt-2022/tokens/components/code-block.json5 +0 -697
  637. package/design-tokens/pt-2022/tokens/components/datepicker.json5 +0 -73
  638. package/design-tokens/pt-2022/tokens/components/divider.json5 +0 -14
  639. package/design-tokens/pt-2022/tokens/components/dl.json5 +0 -38
  640. package/design-tokens/pt-2022/tokens/components/dropdown.json5 +0 -48
  641. package/design-tokens/pt-2022/tokens/components/form-field.json5 +0 -92
  642. package/design-tokens/pt-2022/tokens/components/forms.json5 +0 -48
  643. package/design-tokens/pt-2022/tokens/components/icon.json5 +0 -104
  644. package/design-tokens/pt-2022/tokens/components/input.json5 +0 -12
  645. package/design-tokens/pt-2022/tokens/components/link.json5 +0 -50
  646. package/design-tokens/pt-2022/tokens/components/list.json5 +0 -13
  647. package/design-tokens/pt-2022/tokens/components/loader-overlay.json5 +0 -23
  648. package/design-tokens/pt-2022/tokens/components/markdown.json5 +0 -294
  649. package/design-tokens/pt-2022/tokens/components/modal.json5 +0 -81
  650. package/design-tokens/pt-2022/tokens/components/navbar.json5 +0 -70
  651. package/design-tokens/pt-2022/tokens/components/optgroup.json5 +0 -10
  652. package/design-tokens/pt-2022/tokens/components/option.json5 +0 -12
  653. package/design-tokens/pt-2022/tokens/components/popover.json5 +0 -69
  654. package/design-tokens/pt-2022/tokens/components/popup.json5 +0 -16
  655. package/design-tokens/pt-2022/tokens/components/progress-bar.json5 +0 -13
  656. package/design-tokens/pt-2022/tokens/components/progress-spinner.json5 +0 -16
  657. package/design-tokens/pt-2022/tokens/components/radio.json5 +0 -48
  658. package/design-tokens/pt-2022/tokens/components/scrollbars.json5 +0 -52
  659. package/design-tokens/pt-2022/tokens/components/select.json5 +0 -24
  660. package/design-tokens/pt-2022/tokens/components/sidepanel.json5 +0 -43
  661. package/design-tokens/pt-2022/tokens/components/table.json5 +0 -15
  662. package/design-tokens/pt-2022/tokens/components/tabs.json5 +0 -101
  663. package/design-tokens/pt-2022/tokens/components/tags.json5 +0 -137
  664. package/design-tokens/pt-2022/tokens/components/textarea.json5 +0 -12
  665. package/design-tokens/pt-2022/tokens/components/timepicker.json5 +0 -7
  666. package/design-tokens/pt-2022/tokens/components/timezone.json5 +0 -23
  667. package/design-tokens/pt-2022/tokens/components/toast.json5 +0 -54
  668. package/design-tokens/pt-2022/tokens/components/toggle.json5 +0 -79
  669. package/design-tokens/pt-2022/tokens/components/tooltip.json5 +0 -83
  670. package/design-tokens/pt-2022/tokens/components/tree.json5 +0 -15
  671. package/design-tokens/pt-2022/tokens/properties/aliases.json5 +0 -3
  672. package/design-tokens/pt-2022/tokens/properties/colors.json5 +0 -122
  673. package/design-tokens/pt-2022/tokens/properties/font.json5 +0 -15
  674. package/design-tokens/pt-2022/tokens/properties/globals.json5 +0 -49
  675. package/design-tokens/pt-2022/tokens/properties/md-typography.json5 +0 -103
  676. package/design-tokens/pt-2022/tokens/properties/padding.json5 +0 -3
  677. package/design-tokens/pt-2022/tokens/properties/palette.json5 +0 -233
  678. package/design-tokens/pt-2022/tokens/properties/typography.json5 +0 -184
  679. package/design-tokens/pt-2022/tokens.d.ts +0 -9851
  680. package/design-tokens/public-api.d.ts +0 -3
  681. package/design-tokens/style-dictionary/build.js +0 -78
  682. package/design-tokens/style-dictionary/configs/css.js +0 -13
  683. package/design-tokens/style-dictionary/configs/figma.js +0 -11
  684. package/design-tokens/style-dictionary/configs/index.js +0 -46
  685. package/design-tokens/style-dictionary/configs/js.js +0 -9
  686. package/design-tokens/style-dictionary/configs/scss.js +0 -29
  687. package/design-tokens/style-dictionary/figma-types.js +0 -41
  688. package/design-tokens/style-dictionary/filters/color.js +0 -9
  689. package/design-tokens/style-dictionary/filters/md-typography.js +0 -7
  690. package/design-tokens/style-dictionary/filters/palette.js +0 -7
  691. package/design-tokens/style-dictionary/filters/size.js +0 -7
  692. package/design-tokens/style-dictionary/filters/typography.js +0 -7
  693. package/design-tokens/style-dictionary/formats/figma.js +0 -104
  694. package/design-tokens/style-dictionary/formats/palette.js +0 -25
  695. package/design-tokens/style-dictionary/formats/typography.js +0 -52
  696. package/design-tokens/style-dictionary/transformGroups/css.js +0 -13
  697. package/design-tokens/style-dictionary/transformGroups/figma.js +0 -21
  698. package/design-tokens/style-dictionary/transformGroups/scss.js +0 -13
  699. package/design-tokens/style-dictionary/transformGroups/ts.js +0 -11
  700. package/design-tokens/style-dictionary/transforms/attribute/figma-border.js +0 -18
  701. package/design-tokens/style-dictionary/transforms/attribute/figma-color.js +0 -25
  702. package/design-tokens/style-dictionary/transforms/attribute/figma-default.js +0 -10
  703. package/design-tokens/style-dictionary/transforms/attribute/figma-font.js +0 -31
  704. package/design-tokens/style-dictionary/transforms/attribute/figma-group.js +0 -17
  705. package/design-tokens/style-dictionary/transforms/attribute/figma-opacity.js +0 -10
  706. package/design-tokens/style-dictionary/transforms/attribute/figma-shadow.js +0 -66
  707. package/design-tokens/style-dictionary/transforms/attribute/figma-sizing.js +0 -16
  708. package/design-tokens/style-dictionary/transforms/attribute/figma-spacing.js +0 -15
  709. package/design-tokens/style-dictionary/transforms/attribute/figma-typography.js +0 -24
  710. package/design-tokens/style-dictionary/transforms/attribute/md-typography.js +0 -9
  711. package/design-tokens/style-dictionary/transforms/attribute/palette.js +0 -9
  712. package/design-tokens/style-dictionary/transforms/attribute/prefix.js +0 -11
  713. package/design-tokens/style-dictionary/transforms/attribute/size.js +0 -8
  714. package/design-tokens/style-dictionary/transforms/attribute/typography.js +0 -9
  715. package/design-tokens/style-dictionary/transforms/value/figma-values.js +0 -7
  716. package/esm2020/core/formatters/date/templates/en-US.mjs +0 -336
  717. package/esm2020/core/formatters/date/templates/ru-RU.mjs +0 -372
  718. package/esm2020/design-tokens/index.mjs +0 -2
  719. package/esm2020/design-tokens/legacy-2017/tokens.mjs +0 -1814
  720. package/esm2020/design-tokens/pt-2022/tokens.mjs +0 -1883
  721. package/esm2020/design-tokens/ptsecurity-mosaic-design-tokens.mjs +0 -5
  722. package/esm2020/design-tokens/public-api.mjs +0 -4
  723. package/fesm2015/ptsecurity-mosaic-design-tokens.mjs +0 -5517
  724. package/fesm2015/ptsecurity-mosaic-design-tokens.mjs.map +0 -1
  725. package/fesm2020/ptsecurity-mosaic-design-tokens.mjs +0 -5517
  726. package/fesm2020/ptsecurity-mosaic-design-tokens.mjs.map +0 -1
  727. package/schematics/README.md +0 -35
@@ -1,28 +1,81 @@
1
- import * as i0 from '@angular/core';
2
- import { Version, InjectionToken, isDevMode, NgModule, Optional, Inject, Directive, Injectable, Pipe, Component, ChangeDetectionStrategy, ViewEncapsulation, Input, EventEmitter, ViewChild, Output, ContentChild, ContentChildren, TemplateRef } from '@angular/core';
1
+ import { trigger, state, style, transition, animate, group } from '@angular/animations';
3
2
  import * as i2$1 from '@angular/cdk/bidi';
4
3
  import { BidiModule } from '@angular/cdk/bidi';
4
+ import * as i0 from '@angular/core';
5
+ import { InjectionToken, isDevMode, NgModule, Optional, Inject, inject, LOCALE_ID, Injectable, Pipe, Directive, ContentChildren, Component, ViewEncapsulation, ChangeDetectionStrategy, Input, EventEmitter, ViewChild, Output, ContentChild, TemplateRef, Version } from '@angular/core';
5
6
  import { coerceBooleanProperty, coerceNumberProperty } from '@angular/cdk/coercion';
6
- import MessageFormat from '@messageformat/core';
7
- import * as i1 from '@ptsecurity/cdk/datetime';
8
- import { MC_DATE_LOCALE } from '@ptsecurity/cdk/datetime';
7
+ import * as i1 from '@mosaic-design/date-adapter';
8
+ import { DateAdapter as DateAdapter$1 } from '@mosaic-design/date-adapter';
9
+ import { DateFormatter as DateFormatter$1 } from '@mosaic-design/date-formatter';
9
10
  import * as i2 from '@angular/common';
10
11
  import { CommonModule, DOCUMENT } from '@angular/common';
11
- import * as i1$2 from '@angular/cdk/overlay';
12
- import { Overlay } from '@angular/cdk/overlay';
13
- import { trigger, state, style, transition, animate, group } from '@angular/animations';
14
12
  import { ENTER, SPACE, TAB, ESCAPE } from '@ptsecurity/cdk/keycodes';
15
13
  import { Subject } from 'rxjs';
16
14
  import { takeUntil, distinctUntilChanged, delay } from 'rxjs/operators';
17
15
  import * as i1$1 from '@angular/cdk/a11y';
18
16
  import { ComponentPortal } from '@angular/cdk/portal';
17
+ import * as i1$2 from '@angular/cdk/overlay';
18
+ import { Overlay } from '@angular/cdk/overlay';
19
19
 
20
- const VERSION = new Version('14.7.1+sha-dad4a73');
20
+ const fadeAnimation = trigger('fadeAnimation', [
21
+ state('void', style({ opacity: 0 })),
22
+ state('true', style({ opacity: 1 })),
23
+ state('false', style({ opacity: 0 })),
24
+ transition('* => true', animate('150ms cubic-bezier(0.0, 0.0, 0.2, 1)')),
25
+ transition('* => void', animate('150ms cubic-bezier(0.4, 0.0, 1, 1)'))
26
+ ]);
21
27
 
22
- function isBoolean(val) { return typeof val === 'boolean'; }
23
- function toBoolean(value) {
24
- return value != null && `${value}` !== 'false';
25
- }
28
+ var AnimationCurves;
29
+ (function (AnimationCurves) {
30
+ AnimationCurves["StandardCurve"] = "cubic-bezier(0.4,0.0,0.2,1)";
31
+ AnimationCurves["DecelerationCurve"] = "cubic-bezier(0.0,0.0,0.2,1)";
32
+ AnimationCurves["AccelerationCurve"] = "cubic-bezier(0.4,0.0,1,1)";
33
+ AnimationCurves["SharpCurve"] = "cubic-bezier(0.4,0.0,0.6,1)";
34
+ })(AnimationCurves || (AnimationCurves = {}));
35
+
36
+ /**
37
+ * The following are all the animations for the mc-select component, with each
38
+ * const containing the metadata for one animation.
39
+ *
40
+ */
41
+ const mcSelectAnimations = {
42
+ /**
43
+ * This animation transforms the select's overlay panel on and off the page.
44
+ *
45
+ * When the panel is attached to the DOM, it expands its width by the amount of padding, scales it
46
+ * up to 100% on the Y axis, fades in its border, and translates slightly up and to the
47
+ * side to ensure the option text correctly overlaps the trigger text.
48
+ *
49
+ * When the panel is removed from the DOM, it simply fades out linearly.
50
+ */
51
+ transformPanel: trigger('transformPanel', [
52
+ state('void', style({
53
+ transform: 'scaleY(0)',
54
+ minWidth: '100%',
55
+ opacity: 0
56
+ })),
57
+ transition('void => *', group([
58
+ animate('150ms cubic-bezier(0.25, 0.8, 0.25, 1)')
59
+ ])),
60
+ transition('* => void', [
61
+ animate('250ms 100ms linear', style({ opacity: 0 }))
62
+ ])
63
+ ]),
64
+ /**
65
+ * This animation fades in the background color and text content of the
66
+ * select's options. It is time delayed to occur 100ms after the overlay
67
+ * panel has transformed in.
68
+ */
69
+ fadeInContent: trigger('fadeInContent', [
70
+ state('showing', style({ opacity: 1 })),
71
+ transition('void => showing', [
72
+ style({ opacity: 0 }),
73
+ animate('150ms 100ms cubic-bezier(0.55, 0, 0.55, 0.2)')
74
+ ])
75
+ ])
76
+ };
77
+ const transformPanel = mcSelectAnimations.transformPanel;
78
+ const fadeInContent = mcSelectAnimations.fadeInContent;
26
79
 
27
80
  // Injection token that configures whether the Mosaic sanity checks are enabled.
28
81
  const MC_SANITY_CHECKS = new InjectionToken('mc-sanity-checks', {
@@ -88,10 +141,10 @@ class McCommonModule {
88
141
  }
89
142
  }
90
143
  }
91
- /** @nocollapse */ McCommonModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McCommonModule, deps: [{ token: MC_SANITY_CHECKS, optional: true }], target: i0.ɵɵFactoryTarget.NgModule });
92
- /** @nocollapse */ McCommonModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McCommonModule, imports: [BidiModule], exports: [BidiModule] });
93
- /** @nocollapse */ McCommonModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McCommonModule, imports: [BidiModule, BidiModule] });
94
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McCommonModule, decorators: [{
144
+ /** @nocollapse */ McCommonModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McCommonModule, deps: [{ token: MC_SANITY_CHECKS, optional: true }], target: i0.ɵɵFactoryTarget.NgModule });
145
+ /** @nocollapse */ McCommonModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McCommonModule, imports: [BidiModule], exports: [BidiModule] });
146
+ /** @nocollapse */ McCommonModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McCommonModule, imports: [BidiModule, BidiModule] });
147
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McCommonModule, decorators: [{
95
148
  type: NgModule,
96
149
  args: [{
97
150
  imports: [BidiModule],
@@ -125,12 +178,12 @@ function mixinDisabled(base) {
125
178
  var ThemePalette;
126
179
  (function (ThemePalette) {
127
180
  ThemePalette["Primary"] = "primary";
128
- ThemePalette["Second"] = "second";
181
+ ThemePalette["Secondary"] = "secondary";
129
182
  ThemePalette["Error"] = "error";
130
183
  ThemePalette["Info"] = "info";
131
184
  ThemePalette["Warning"] = "warning";
132
185
  ThemePalette["Success"] = "success";
133
- ThemePalette["Default"] = "second";
186
+ ThemePalette["Default"] = "secondary";
134
187
  ThemePalette["Empty"] = "";
135
188
  })(ThemePalette || (ThemePalette = {}));
136
189
  function mixinColor(base, defaultColor = ThemePalette.Default) {
@@ -193,73 +246,20 @@ function mixinErrorState(base) {
193
246
  };
194
247
  }
195
248
 
196
- /**
197
- * Shared directive to count lines inside a text area, such as a list item.
198
- * Line elements can be extracted with a @ContentChildren(McLine) query, then
199
- * counted by checking the query list's length.
200
- */
201
- class McLine {
202
- }
203
- /** @nocollapse */ McLine.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McLine, deps: [], target: i0.ɵɵFactoryTarget.Directive });
204
- /** @nocollapse */ McLine.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: McLine, selector: "[mc-line], [mcLine]", host: { classAttribute: "mc-line" }, ngImport: i0 });
205
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McLine, decorators: [{
206
- type: Directive,
207
- args: [{
208
- selector: '[mc-line], [mcLine]',
209
- host: { class: 'mc-line' }
210
- }]
211
- }] });
212
- /**
213
- * Helper that takes a query list of lines and sets the correct class on the host.
214
- * @docs-private
215
- */
216
- class McLineSetter {
217
- constructor(_lines, _element) {
218
- this._lines = _lines;
219
- this._element = _element;
220
- this.setLineClass(this._lines.length);
221
- this._lines.changes.subscribe(() => {
222
- this.setLineClass(this._lines.length);
223
- });
224
- }
225
- setLineClass(count) {
226
- const minLineClassNumber = 2;
227
- const maxLineClassNumber = 3;
228
- this.resetClasses();
229
- if (count === minLineClassNumber || count === maxLineClassNumber) {
230
- this.setClass(`mc-${count}-line`, true);
231
- }
232
- else if (count > maxLineClassNumber) {
233
- this.setClass(`mc-multi-line`, true);
234
- }
235
- }
236
- resetClasses() {
237
- this.setClass('mc-2-line', false);
238
- this.setClass('mc-3-line', false);
239
- this.setClass('mc-multi-line', false);
240
- }
241
- setClass(className, isAdd) {
242
- if (isAdd) {
243
- this._element.nativeElement.classList.add(className);
244
- }
245
- else {
246
- this._element.nativeElement.classList.remove(className);
247
- }
248
- }
249
+ const MC_DATE_FORMATS = new InjectionToken('mc-date-formats');
250
+
251
+ /** InjectionToken for datepicker that can be used to override default locale code. */
252
+ const MC_DATE_LOCALE = new InjectionToken('MC_DATE_LOCALE', {
253
+ providedIn: 'root',
254
+ factory: MC_DATE_LOCALE_FACTORY
255
+ });
256
+ /** @docs-private */
257
+ // tslint:disable-next-line:naming-convention
258
+ function MC_DATE_LOCALE_FACTORY() {
259
+ return inject(LOCALE_ID);
249
260
  }
250
- class McLineModule {
261
+ class DateAdapter extends DateAdapter$1 {
251
262
  }
252
- /** @nocollapse */ McLineModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McLineModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
253
- /** @nocollapse */ McLineModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McLineModule, declarations: [McLine], exports: [McLine] });
254
- /** @nocollapse */ McLineModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McLineModule });
255
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McLineModule, decorators: [{
256
- type: NgModule,
257
- args: [{
258
- imports: [],
259
- exports: [McLine],
260
- declarations: [McLine]
261
- }]
262
- }] });
263
263
 
264
264
  /** Error state matcher that matches when a control is invalid and dirty. */
265
265
  class ShowOnDirtyErrorStateMatcher {
@@ -267,9 +267,9 @@ class ShowOnDirtyErrorStateMatcher {
267
267
  return !!(control && control.invalid && (control.dirty || (form && form.submitted)));
268
268
  }
269
269
  }
270
- /** @nocollapse */ ShowOnDirtyErrorStateMatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: ShowOnDirtyErrorStateMatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
271
- /** @nocollapse */ ShowOnDirtyErrorStateMatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: ShowOnDirtyErrorStateMatcher });
272
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: ShowOnDirtyErrorStateMatcher, decorators: [{
270
+ /** @nocollapse */ ShowOnDirtyErrorStateMatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ShowOnDirtyErrorStateMatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
271
+ /** @nocollapse */ ShowOnDirtyErrorStateMatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ShowOnDirtyErrorStateMatcher });
272
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ShowOnDirtyErrorStateMatcher, decorators: [{
273
273
  type: Injectable
274
274
  }] });
275
275
  /** Provider that defines how form controls behave with regards to displaying error messages. */
@@ -278,1229 +278,126 @@ class ErrorStateMatcher {
278
278
  return !!(control && control.invalid && (control.touched || (form && form.submitted)));
279
279
  }
280
280
  }
281
- /** @nocollapse */ ErrorStateMatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: ErrorStateMatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
282
- /** @nocollapse */ ErrorStateMatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: ErrorStateMatcher, providedIn: 'root' });
283
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: ErrorStateMatcher, decorators: [{
281
+ /** @nocollapse */ ErrorStateMatcher.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ErrorStateMatcher, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
282
+ /** @nocollapse */ ErrorStateMatcher.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ErrorStateMatcher, providedIn: 'root' });
283
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: ErrorStateMatcher, decorators: [{
284
284
  type: Injectable,
285
285
  args: [{ providedIn: 'root' }]
286
286
  }] });
287
287
 
288
- const SECONDS_TEMPLATE$1 = `{
289
- SHOW_MILLISECONDS,
290
- select,
291
- yes{:{SECONDS}{MILLISECONDS}}
292
- other{{
293
- SHOW_SECONDS,
294
- select,
295
- yes{:{SECONDS}}
296
- other{}
297
- }}
298
- }`;
299
- const enUS = {
300
- relativeTemplates: {
301
- short: {
302
- BEFORE_YESTERDAY: `{CURRENT_YEAR, select, yes{{SHORT_DATE}, {TIME}} other{{SHORT_DATE}, {YEAR}}}${SECONDS_TEMPLATE$1}`,
303
- YESTERDAY: `Yesterday, {TIME}${SECONDS_TEMPLATE$1}`,
304
- TODAY: `Today, {TIME}${SECONDS_TEMPLATE$1}`,
305
- TOMORROW: `Tomorrow, {TIME}${SECONDS_TEMPLATE$1}`,
306
- AFTER_TOMORROW: `{CURRENT_YEAR, select, yes{{SHORT_DATE}, {TIME}} other{{SHORT_DATE}, {YEAR}}}${SECONDS_TEMPLATE$1}`
307
- },
308
- long: {
309
- BEFORE_YESTERDAY: `{CURRENT_YEAR, select, yes{{DATE}, {TIME}} other{{DATE}, {YEAR}}}${SECONDS_TEMPLATE$1}`,
310
- YESTERDAY: `Yesterday, {TIME}${SECONDS_TEMPLATE$1}`,
311
- TODAY: `Today, {TIME}${SECONDS_TEMPLATE$1}`,
312
- TOMORROW: `Tomorrow, {TIME}${SECONDS_TEMPLATE$1}`,
313
- AFTER_TOMORROW: `{CURRENT_YEAR, select, yes{{DATE}, {TIME}} other{{DATE}, {YEAR}}}${SECONDS_TEMPLATE$1}`
314
- }
315
- },
316
- absoluteTemplates: {
317
- short: {
318
- DATE: '{CURRENT_YEAR, select, yes{{SHORT_DATE}} other{{SHORT_DATE}, {YEAR}}}',
319
- DATETIME: `{
320
- CURRENT_YEAR,
321
- select,
322
- yes{{SHORT_DATE}, {TIME}}
323
- other{{SHORT_DATE}, {YEAR}, {TIME}}
324
- }${SECONDS_TEMPLATE$1}`
325
- },
326
- long: {
327
- DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE}, {YEAR}}}',
328
- DATETIME: `{
329
- CURRENT_YEAR,
330
- select,
331
- yes{{DATE}, {TIME}}
332
- other{{DATE}, {YEAR}, {TIME}}
333
- }${SECONDS_TEMPLATE$1}`
334
- }
335
- },
336
- rangeTemplates: {
337
- closedRange: {
338
- short: {
339
- START_DATE: '{CURRENT_YEAR, select, yes{{SHORT_DATE}} other{{SHORT_DATE}, {YEAR}}}',
340
- END_DATE: `{
341
- SAME_MONTH,
342
- select,
343
- yes{{DAY}}
344
- other{{
345
- CURRENT_YEAR,
346
- select,
347
- yes{{SHORT_DATE}}
348
- other{{SHORT_DATE}, {YEAR}}
349
- }}
350
- }`,
351
- DATE: `{
352
- SAME_MONTH,
353
- select,
354
- yes{{START_DATE}{DASH}{END_DATE}}
355
- other{{START_DATE}{LONG_DASH}{END_DATE}}
356
- }`,
357
- START_DATETIME: `{
358
- SAME_DAY,
359
- select,
360
- yes{{TIME}}
361
- other{{
362
- CURRENT_YEAR,
363
- select,
364
- yes{{SHORT_DATE}, {TIME}}
365
- other{{SHORT_DATE}, {YEAR}, {TIME}}
366
- }}
367
- }${SECONDS_TEMPLATE$1}`,
368
- END_DATETIME: `{
369
- SAME_DAY,
370
- select,
371
- yes{{
372
- CURRENT_YEAR,
373
- select,
374
- yes{{TIME}${SECONDS_TEMPLATE$1}, {SHORT_DATE}}
375
- other{{TIME}${SECONDS_TEMPLATE$1}, {SHORT_DATE}, {YEAR}}
376
- }}
377
- other{{
378
- CURRENT_YEAR,
379
- select,
380
- yes{{SHORT_DATE}, {TIME}}
381
- other{{SHORT_DATE}, {YEAR}, {TIME}}
382
- }${SECONDS_TEMPLATE$1}}
383
- }`,
384
- DATETIME: `{
385
- SAME_DAY,
386
- select,
387
- yes{{START_DATETIME}{DASH}{END_DATETIME}}
388
- other{{START_DATETIME}{LONG_DASH}{END_DATETIME}}
389
- }`
390
- },
391
- middle: {
392
- START_DATE: `{
393
- SAME_MONTH,
394
- select,
395
- yes{{DAY}}
396
- other{{
397
- CURRENT_YEAR,
398
- select,
399
- yes{{DATE}}
400
- other{{DATE}, {YEAR}}
401
- }}
402
- }`,
403
- END_DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE}, {YEAR}}}',
404
- DATE: `{
405
- SAME_MONTH,
406
- select,
407
- yes{{START_DATE}{DASH}{END_DATE}}
408
- other{{START_DATE}{LONG_DASH}{END_DATE}}
409
- }`,
410
- START_DATETIME: `{
411
- SAME_DAY,
412
- select,
413
- yes{{TIME}}
414
- other{{
415
- CURRENT_YEAR,
416
- select,
417
- yes{{DATE}, {TIME}}
418
- other{{DATE}, {YEAR}, {TIME}}
419
- }}
420
- }${SECONDS_TEMPLATE$1}`,
421
- END_DATETIME: `{
422
- SAME_DAY,
423
- select,
424
- yes{{
425
- CURRENT_YEAR,
426
- select,
427
- yes{{TIME}${SECONDS_TEMPLATE$1}, {DATE}}
428
- other{{TIME}${SECONDS_TEMPLATE$1}, {DATE}, {YEAR}}
429
- }}
430
- other{{
431
- CURRENT_YEAR,
432
- select,
433
- yes{{DATE}, {TIME}}
434
- other{{DATE}, {YEAR}, {TIME}}
435
- }${SECONDS_TEMPLATE$1}}
436
- }`,
437
- DATETIME: `{
438
- SAME_DAY,
439
- select,
440
- yes{{START_DATETIME}{DASH}{END_DATETIME}}
441
- other{{START_DATETIME}{LONG_DASH}{END_DATETIME}}
442
- }`
443
- },
444
- long: {
445
- START_DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE}, {YEAR}}}',
446
- END_DATE: `{
447
- SAME_MONTH,
448
- select,
449
- yes{{DAY}}
450
- other{{
451
- CURRENT_YEAR,
452
- select,
453
- yes{{DATE}}
454
- other{{DATE}, {YEAR}}
455
- }}
456
- }`,
457
- DATE: `{
458
- SAME_MONTH,
459
- select,
460
- yes{{START_DATE}{DASH}{END_DATE}}
461
- other{{START_DATE}{LONG_DASH}{END_DATE}}
462
- }`,
463
- START_DATETIME: `{
464
- SAME_DAY,
465
- select,
466
- yes{{
467
- CURRENT_YEAR,
468
- select,
469
- yes{{DATE}, from{NBSP}{TIME}}
470
- other{{DATE}, {YEAR}, from{NBSP}{TIME}}
471
- }}
472
- other{{
473
- CURRENT_YEAR,
474
- select,
475
- yes{{DATE}, {TIME}}
476
- other{{DATE}, {YEAR}, {TIME}}
477
- }}
478
- }${SECONDS_TEMPLATE$1}`,
479
- END_DATETIME: `{
480
- SAME_DAY,
481
- select,
482
- yes{to{NBSP}{TIME}}
483
- other{{
484
- CURRENT_YEAR,
485
- select,
486
- yes{{DATE}, {TIME}}
487
- other{{DATE}, {YEAR}, {TIME}}
488
- }}
489
- }${SECONDS_TEMPLATE$1}`,
490
- DATETIME: `{
491
- SAME_DAY,
492
- select,
493
- yes{{START_DATETIME} {END_DATETIME}}
494
- other{From {START_DATETIME} to{NBSP}{END_DATETIME}}
495
- }`
496
- }
497
- },
498
- openedRange: {
499
- short: {
500
- START_DATE: `{
501
- CURRENT_YEAR,
502
- select,
503
- yes{{SHORT_DATE}}
504
- other{{SHORT_DATE} {YEAR}}
505
- }`,
506
- END_DATE: '{CURRENT_YEAR, select, yes{{SHORT_DATE}} other{{SHORT_DATE} {YEAR}}}',
507
- DATE: `{
508
- RANGE_TYPE,
509
- select,
510
- onlyStart{From{NBSP}{START_DATE}}
511
- other{Until{NBSP}{END_DATE}}
512
- }`,
513
- START_DATETIME: `{
514
- CURRENT_YEAR,
515
- select,
516
- yes{{SHORT_DATE}, {TIME}}
517
- other{{SHORT_DATE} {YEAR}, {TIME}}
518
- }${SECONDS_TEMPLATE$1}`,
519
- END_DATETIME: `{
520
- CURRENT_YEAR,
521
- select,
522
- yes{{SHORT_DATE}, {TIME}}
523
- other{{SHORT_DATE} {YEAR}, {TIME}}
524
- }${SECONDS_TEMPLATE$1}`,
525
- DATETIME: `{
526
- RANGE_TYPE,
527
- select,
528
- onlyStart{From{NBSP}{START_DATETIME}}
529
- other{Until{NBSP}{END_DATETIME}}
530
- }`
531
- },
532
- long: {
533
- START_DATE: `{
534
- CURRENT_YEAR,
535
- select,
536
- yes{{DATE}}
537
- other{{DATE} {YEAR}}
538
- }`,
539
- END_DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE} {YEAR}}}',
540
- DATE: `{
541
- RANGE_TYPE,
542
- select,
543
- onlyStart{From{NBSP}{START_DATE}}
544
- other{Until{NBSP}{END_DATE}}
545
- }`,
546
- START_DATETIME: `{
547
- CURRENT_YEAR,
548
- select,
549
- yes{{DATE}, {TIME}}
550
- other{{DATE} {YEAR}, {TIME}}
551
- }${SECONDS_TEMPLATE$1}`,
552
- END_DATETIME: `{
553
- CURRENT_YEAR,
554
- select,
555
- yes{{DATE}, {TIME}}
556
- other{{DATE} {YEAR}, {TIME}}
557
- }${SECONDS_TEMPLATE$1}`,
558
- DATETIME: `{
559
- RANGE_TYPE,
560
- select,
561
- onlyStart{From{NBSP}{START_DATETIME}}
562
- other{Until{NBSP}{END_DATETIME}}
563
- }`
564
- }
565
- }
566
- },
567
- durationTemplates: {
568
- shortest: {
569
- FULL: '{D, duration}{SHOW_MILLISECONDS, select, yes{,{MILLISECONDS}} other {}}',
570
- ONLY_MINUTES: '{HOURS}:{MINUTES, number, ::integer-width/00}'
571
- },
572
- long: {
573
- SEPARATOR: '',
574
- YEARS: `{years, plural,
575
- =1 {# year}
576
- other {# years}
577
- }`,
578
- MONTHS: `{months, plural,
579
- =1 {# month}
580
- other {# months}
581
- }`,
582
- WEEKS: `{weeks, plural,
583
- =1 {# week}
584
- other {# weeks}
585
- }`,
586
- DAYS: `{days, plural,
587
- =1 {# day}
588
- other {# days}
589
- }`,
590
- HOURS: `{hours, plural,
591
- =1 {# hour}
592
- other {# hours}
593
- }`,
594
- MINUTES: `{minutes, plural,
595
- =1 {# minute}
596
- other {# minutes}
597
- }`,
598
- SECONDS: `{seconds, plural,
599
- =1 {# second}
600
- other {# seconds}
601
- }`,
602
- YEARS_FRACTION: `{years} years`,
603
- MONTHS_FRACTION: `{months} months`
604
- },
605
- short: {
606
- SEPARATOR: '',
607
- YEARS: `{years} y`,
608
- MONTHS: `{months} mo`,
609
- WEEKS: `{weeks} w`,
610
- DAYS: `{days} d`,
611
- HOURS: `{hours} h`,
612
- MINUTES: `{minutes} min`,
613
- SECONDS: `{SHOW_MILLISECONDS, select, yes
614
- {{seconds}.{milliseconds} s}
615
- other
616
- {{seconds} s}
617
- }`,
618
- YEARS_FRACTION: '{years} y',
619
- MONTHS_FRACTION: '{months} mo'
620
- }
621
- }
622
- };
623
-
624
- const SECONDS_TEMPLATE = `{
625
- SHOW_MILLISECONDS,
626
- select,
627
- yes{:{SECONDS}{MILLISECONDS}}
628
- other{{
629
- SHOW_SECONDS,
630
- select,
631
- yes{:{SECONDS}}
632
- other{}
633
- }}
634
- }`;
635
- const ruRU = {
636
- relativeTemplates: {
637
- short: {
638
- BEFORE_YESTERDAY: `{CURRENT_YEAR, select, yes{{SHORT_DATE}, {TIME}} other{{SHORT_DATE} {YEAR}}}${SECONDS_TEMPLATE}`,
639
- YESTERDAY: `Вчера, {TIME}${SECONDS_TEMPLATE}`,
640
- TODAY: `Сегодня, {TIME}${SECONDS_TEMPLATE}`,
641
- TOMORROW: `Завтра, {TIME}${SECONDS_TEMPLATE}`,
642
- AFTER_TOMORROW: `{CURRENT_YEAR, select, yes{{SHORT_DATE}, {TIME}} other{{SHORT_DATE} {YEAR}}}${SECONDS_TEMPLATE}`
643
- },
644
- long: {
645
- BEFORE_YESTERDAY: `{CURRENT_YEAR, select, yes{{DATE}, {TIME}} other{{DATE} {YEAR}}}${SECONDS_TEMPLATE}`,
646
- YESTERDAY: `Вчера, {TIME}${SECONDS_TEMPLATE}`,
647
- TODAY: `Сегодня, {TIME}${SECONDS_TEMPLATE}`,
648
- TOMORROW: `Завтра, {TIME}${SECONDS_TEMPLATE}`,
649
- AFTER_TOMORROW: `{CURRENT_YEAR, select, yes{{DATE}, {TIME}} other{{DATE} {YEAR}}}${SECONDS_TEMPLATE}`
650
- }
651
- },
652
- absoluteTemplates: {
653
- short: {
654
- DATE: '{CURRENT_YEAR, select, yes{{SHORT_DATE}} other{{SHORT_DATE} {YEAR}}}',
655
- DATETIME: `{
656
- CURRENT_YEAR,
657
- select,
658
- yes{{SHORT_DATE}, {TIME}}
659
- other{{SHORT_DATE} {YEAR}, {TIME}}
660
- }${SECONDS_TEMPLATE}`
661
- },
662
- long: {
663
- DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE} {YEAR}}}',
664
- DATETIME: `{
665
- CURRENT_YEAR,
666
- select,
667
- yes{{DATE}, {TIME}}
668
- other{{DATE} {YEAR}, {TIME}}
669
- }${SECONDS_TEMPLATE}`
670
- }
671
- },
672
- rangeTemplates: {
673
- closedRange: {
674
- short: {
675
- START_DATE: `{
676
- SAME_MONTH,
677
- select,
678
- yes{{DAY}}
679
- other{{
680
- CURRENT_YEAR,
681
- select,
682
- yes{{SHORT_DATE}}
683
- other{{SHORT_DATE} {YEAR}}
684
- }}
685
- }`,
686
- END_DATE: '{CURRENT_YEAR, select, yes{{SHORT_DATE}} other{{SHORT_DATE} {YEAR}}}',
687
- DATE: `{
688
- SAME_MONTH,
689
- select,
690
- yes{{START_DATE}{DASH}{END_DATE}}
691
- other{{START_DATE}{LONG_DASH}{END_DATE}}
692
- }`,
693
- START_DATETIME: `{
694
- SAME_DAY,
695
- select,
696
- yes{{TIME}}
697
- other{{
698
- CURRENT_YEAR,
699
- select,
700
- yes{{SHORT_DATE}, {TIME}}
701
- other{{SHORT_DATE} {YEAR}, {TIME}}
702
- }}
703
- }${SECONDS_TEMPLATE}`,
704
- END_DATETIME: `{
705
- SAME_DAY,
706
- select,
707
- yes{{
708
- CURRENT_YEAR,
709
- select,
710
- yes{{TIME}${SECONDS_TEMPLATE}, {SHORT_DATE}}
711
- other{{TIME}${SECONDS_TEMPLATE}, {SHORT_DATE} {YEAR}}
712
- }}
713
- other{{
714
- CURRENT_YEAR,
715
- select,
716
- yes{{SHORT_DATE}, {TIME}}
717
- other{{SHORT_DATE} {YEAR}, {TIME}}
718
- }${SECONDS_TEMPLATE}}
719
- }`,
720
- DATETIME: `{
721
- SAME_DAY,
722
- select,
723
- yes{{START_DATETIME}{DASH}{END_DATETIME}}
724
- other{{START_DATETIME}{LONG_DASH}{END_DATETIME}}
725
- }`
726
- },
727
- middle: {
728
- START_DATE: `{
729
- SAME_MONTH,
730
- select,
731
- yes{{DAY}}
732
- other{{
733
- CURRENT_YEAR,
734
- select,
735
- yes{{DATE}}
736
- other{{DATE} {YEAR}}
737
- }}
738
- }`,
739
- END_DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE} {YEAR}}}',
740
- DATE: `{
741
- SAME_MONTH,
742
- select,
743
- yes{{START_DATE}{DASH}{END_DATE}}
744
- other{{START_DATE}{LONG_DASH}{END_DATE}}
745
- }`,
746
- START_DATETIME: `{
747
- SAME_DAY,
748
- select,
749
- yes{{TIME}}
750
- other{{
751
- CURRENT_YEAR,
752
- select,
753
- yes{{DATE}, {TIME}}
754
- other{{DATE} {YEAR}, {TIME}}
755
- }}
756
- }${SECONDS_TEMPLATE}`,
757
- END_DATETIME: `{
758
- SAME_DAY,
759
- select,
760
- yes{{
761
- CURRENT_YEAR,
762
- select,
763
- yes{{TIME}${SECONDS_TEMPLATE}, {DATE}}
764
- other{{TIME}${SECONDS_TEMPLATE}, {DATE} {YEAR}}
765
- }}
766
- other{{
767
- CURRENT_YEAR,
768
- select,
769
- yes{{DATE}, {TIME}}
770
- other{{DATE} {YEAR}, {TIME}}
771
- }${SECONDS_TEMPLATE}}
772
- }`,
773
- DATETIME: `{
774
- SAME_DAY,
775
- select,
776
- yes{{START_DATETIME}{DASH}{END_DATETIME}}
777
- other{{START_DATETIME}{LONG_DASH}{END_DATETIME}}
778
- }`
779
- },
780
- long: {
781
- START_DATE: `{
782
- SAME_MONTH,
783
- select,
784
- yes{{DAY}}
785
- other{{
786
- CURRENT_YEAR,
787
- select,
788
- yes{{DATE}}
789
- other{{DATE} {YEAR}}
790
- }}
791
- }`,
792
- END_DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE} {YEAR}}}',
793
- DATE: `{
794
- SAME_MONTH,
795
- select,
796
- yes{{START_DATE}{DASH}{END_DATE}}
797
- other{{START_DATE}{LONG_DASH}{END_DATE}}
798
- }`,
799
- START_DATETIME: `{
800
- SAME_DAY,
801
- select,
802
- yes{{
803
- CURRENT_YEAR,
804
- select,
805
- yes{{DATE}, с{NBSP}{TIME}}
806
- other{{DATE} {YEAR}, с{NBSP}{TIME}}
807
- }}
808
- other{{
809
- CURRENT_YEAR,
810
- select,
811
- yes{{DATE}, {TIME}}
812
- other{{DATE} {YEAR}, {TIME}}
813
- }}
814
- }${SECONDS_TEMPLATE}`,
815
- END_DATETIME: `{
816
- SAME_DAY,
817
- select,
818
- yes{по{NBSP}{TIME}}
819
- other{{
820
- CURRENT_YEAR,
821
- select,
822
- yes{{DATE}, {TIME}}
823
- other{{DATE} {YEAR}, {TIME}}
824
- }}
825
- }${SECONDS_TEMPLATE}`,
826
- DATETIME: `{
827
- SAME_DAY,
828
- select,
829
- yes{{START_DATETIME} {END_DATETIME}}
830
- other{С{NBSP}{START_DATETIME} по{NBSP}{END_DATETIME}}
831
- }`
832
- }
833
- },
834
- openedRange: {
835
- short: {
836
- START_DATE: `{
837
- CURRENT_YEAR,
838
- select,
839
- yes{{SHORT_DATE}}
840
- other{{SHORT_DATE} {YEAR}}
841
- }`,
842
- END_DATE: '{CURRENT_YEAR, select, yes{{SHORT_DATE}} other{{SHORT_DATE} {YEAR}}}',
843
- DATE: `{
844
- RANGE_TYPE,
845
- select,
846
- onlyStart{С{NBSP}{START_DATE}}
847
- other{По{NBSP}{END_DATE}}
848
- }`,
849
- START_DATETIME: `{
850
- CURRENT_YEAR,
851
- select,
852
- yes{{SHORT_DATE}, {TIME}}
853
- other{{SHORT_DATE} {YEAR}, {TIME}}
854
- }${SECONDS_TEMPLATE}`,
855
- END_DATETIME: `{
856
- CURRENT_YEAR,
857
- select,
858
- yes{{SHORT_DATE}, {TIME}}
859
- other{{SHORT_DATE} {YEAR}, {TIME}}
860
- }${SECONDS_TEMPLATE}`,
861
- DATETIME: `{
862
- RANGE_TYPE,
863
- select,
864
- onlyStart{С{NBSP}{START_DATETIME}}
865
- other{По{NBSP}{END_DATETIME}}
866
- }`
867
- },
868
- long: {
869
- START_DATE: `{
870
- CURRENT_YEAR,
871
- select,
872
- yes{{DATE}}
873
- other{{DATE} {YEAR}}
874
- }`,
875
- END_DATE: '{CURRENT_YEAR, select, yes{{DATE}} other{{DATE} {YEAR}}}',
876
- DATE: `{
877
- RANGE_TYPE,
878
- select,
879
- onlyStart{С{NBSP}{START_DATE}}
880
- other{По{NBSP}{END_DATE}}
881
- }`,
882
- START_DATETIME: `{
883
- CURRENT_YEAR,
884
- select,
885
- yes{{DATE}, {TIME}}
886
- other{{DATE} {YEAR}, {TIME}}
887
- }${SECONDS_TEMPLATE}`,
888
- END_DATETIME: `{
889
- CURRENT_YEAR,
890
- select,
891
- yes{{DATE}, {TIME}}
892
- other{{DATE} {YEAR}, {TIME}}
893
- }${SECONDS_TEMPLATE}`,
894
- DATETIME: `{
895
- RANGE_TYPE,
896
- select,
897
- onlyStart{С{NBSP}{START_DATETIME}}
898
- other{По{NBSP}{END_DATETIME}}
899
- }`
900
- }
901
- }
902
- },
903
- durationTemplates: {
904
- shortest: {
905
- FULL: '{D, duration}{SHOW_MILLISECONDS, select, yes{,{MILLISECONDS}} other {}}',
906
- ONLY_MINUTES: '{HOURS}:{MINUTES, number, ::integer-width/00}'
907
- },
908
- long: {
909
- SEPARATOR: 'и',
910
- YEARS: `{years, plural,
911
- one {# год}
912
- few {# года}
913
- many {# лет}
914
- other {}
915
- }`,
916
- MONTHS: `{months, plural,
917
- one {# месяц}
918
- few {# месяца}
919
- many {# месяцев}
920
- other {}
921
- }`,
922
- WEEKS: `{weeks, plural,
923
- one {# неделя}
924
- few {# недели}
925
- many {# недель}
926
- other {}
927
- }`,
928
- DAYS: `{days, plural,
929
- one {# день}
930
- few {# дня}
931
- many {# дней}
932
- other {}
933
- }`,
934
- HOURS: `{hours, plural,
935
- one {# час}
936
- few {# часа}
937
- many {# часов}
938
- other {}
939
- }`,
940
- MINUTES: `{minutes, plural,
941
- one {# минута}
942
- few {# минуты}
943
- many {# минут}
944
- other {}
945
- }`,
946
- SECONDS: `{seconds, plural,
947
- one {# секунда}
948
- few {# секунды}
949
- many {# секунд}
950
- other {}
951
- }`,
952
- YEARS_FRACTION: `{floorValue, plural,
953
- =1 {{years, number, ::#,#} года}
954
- one {{years, number, ::#,#} год}
955
- few {{years, number, ::#,#} года}
956
- other {{years, number, ::#,#} лет}
957
- }`,
958
- MONTHS_FRACTION: `{floorValue, plural,
959
- =1 {{months, number, ::#,#} месяца}
960
- one {{months, number, ::#,#} месяц}
961
- few {{months, number, ::#,#} месяца}
962
- other {{months, number, ::#,#} месяцев}
963
- }`
964
- },
965
- short: {
966
- SEPARATOR: '',
967
- YEARS: `{years, plural,
968
- one {# г}
969
- few {# г}
970
- many {# л}
971
- other {}
972
- }`,
973
- MONTHS: `{months} мес`,
974
- WEEKS: `{weeks} нед`,
975
- DAYS: `{days} д`,
976
- HOURS: `{hours} ч`,
977
- MINUTES: `{minutes} мин`,
978
- SECONDS: `{SHOW_MILLISECONDS, select, yes
979
- {{seconds},{milliseconds} с}
980
- other
981
- {{seconds} с}
982
- }`,
983
- YEARS_FRACTION: `{floorValue, plural,
984
- one {{years, number, ::#,#} г}
985
- few {{years, number, ::#,#} г}
986
- other {{years, number, ::#,#} л}
987
- }`,
988
- MONTHS_FRACTION: `{floorValue, plural,
989
- =1 {{months, number, ::#,#} мес}
990
- other {{months, number, ::#,#} мес}
991
- }`
992
- }
993
- }
994
- };
995
-
996
- // tslint:disable:no-magic-numbers
997
- class DateFormatter {
288
+ class DateFormatter extends DateFormatter$1 {
998
289
  constructor(adapter, locale) {
290
+ super(adapter, locale);
999
291
  this.adapter = adapter;
1000
- this.invalidDateErrorText = 'Invalid date';
1001
- this.config = locale === 'en' ? enUS : ruRU;
1002
- this.messageFormat = new MessageFormat(locale);
1003
292
  }
1004
- setLocale(locale) {
1005
- this.config = locale === 'en' ? enUS : ruRU;
1006
- this.adapter.setLocale(locale);
293
+ }
294
+ /** @nocollapse */ DateFormatter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: DateFormatter, deps: [{ token: i1.DateAdapter }, { token: MC_DATE_LOCALE }], target: i0.ɵɵFactoryTarget.Injectable });
295
+ /** @nocollapse */ DateFormatter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: DateFormatter });
296
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: DateFormatter, decorators: [{
297
+ type: Injectable
298
+ }], ctorParameters: function () {
299
+ return [{ type: i1.DateAdapter }, { type: undefined, decorators: [{
300
+ type: Inject,
301
+ args: [MC_DATE_LOCALE]
302
+ }] }];
303
+ } });
304
+
305
+ class AbsoluteDateFormatterPipe {
306
+ constructor(adapter, formatter) {
307
+ this.adapter = adapter;
308
+ this.formatter = formatter;
1007
309
  }
1008
- /**
1009
- * @param date - date
1010
- * @param template - template
1011
- * @param seconds - use seconds
1012
- * @param milliseconds - use milliseconds
1013
- * @returns relative date by template
1014
- */
1015
- relativeDate(date, template, seconds = false, milliseconds = false) {
1016
- if (!this.adapter.isDateInstance(date)) {
1017
- throw new Error(this.invalidDateErrorText);
1018
- }
1019
- let newTemplate;
1020
- const templateVariables = Object.assign(Object.assign({}, this.adapter.config.variables), template.variables);
1021
- if (this.isBeforeYesterday(date)) {
1022
- newTemplate = template.BEFORE_YESTERDAY;
1023
- }
1024
- else if (this.isYesterday(date)) {
1025
- newTemplate = template.YESTERDAY;
1026
- }
1027
- else if (this.isToday(date)) {
1028
- newTemplate = template.TODAY;
1029
- }
1030
- else if (this.isTomorrow(date)) {
1031
- newTemplate = template.TOMORROW;
1032
- }
1033
- else if (this.isAfterTomorrow(date)) {
1034
- newTemplate = template.AFTER_TOMORROW;
1035
- }
1036
- const variables = this.compileVariables(date, templateVariables);
1037
- variables.SHOW_SECONDS = seconds ? 'yes' : 'no';
1038
- variables.SHOW_MILLISECONDS = milliseconds ? 'yes' : 'no';
1039
- return this.messageFormat.compile(newTemplate)(variables);
310
+ transform(value, currYear) {
311
+ const date = this.adapter.deserialize(value);
312
+ return date ? this.formatter.absoluteLongDate(date, currYear) : '';
1040
313
  }
1041
- /**
1042
- * @param date - date
1043
- * @returns relative date in short format
1044
- */
1045
- relativeShortDate(date) {
1046
- return this.relativeDate(date, this.config.relativeTemplates.short);
314
+ }
315
+ /** @nocollapse */ AbsoluteDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
316
+ /** @nocollapse */ AbsoluteDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateFormatterPipe, name: "absoluteLongDate" });
317
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateFormatterPipe, decorators: [{
318
+ type: Pipe,
319
+ args: [{ name: 'absoluteLongDate' }]
320
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
321
+ class AbsoluteDateTimeFormatterPipe {
322
+ constructor(adapter, formatter) {
323
+ this.adapter = adapter;
324
+ this.formatter = formatter;
1047
325
  }
1048
- /**
1049
- * @param date - date
1050
- * @returns relative date in long format
1051
- */
1052
- relativeLongDate(date) {
1053
- return this.relativeDate(date, this.config.relativeTemplates.long);
326
+ transform(value, options) {
327
+ const date = this.adapter.deserialize(value);
328
+ return date ? this.formatter.absoluteLongDateTime(date, options) : '';
1054
329
  }
1055
- /**
1056
- * @param date - date
1057
- * @param options - DateTimeOptions
1058
- * @returns relative date in short format with time
1059
- */
1060
- relativeShortDateTime(date, options) {
1061
- return this.relativeDate(date, this.config.relativeTemplates.short, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds);
330
+ }
331
+ /** @nocollapse */ AbsoluteDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateTimeFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
332
+ /** @nocollapse */ AbsoluteDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateTimeFormatterPipe, name: "absoluteLongDateTime" });
333
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateTimeFormatterPipe, decorators: [{
334
+ type: Pipe,
335
+ args: [{ name: 'absoluteLongDateTime' }]
336
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
337
+ class AbsoluteDateShortFormatterPipe {
338
+ constructor(adapter, formatter) {
339
+ this.adapter = adapter;
340
+ this.formatter = formatter;
1062
341
  }
1063
- /**
1064
- * @param date - date
1065
- * @param options - DateTimeOptions
1066
- * @returns relative date in long format with time
1067
- */
1068
- relativeLongDateTime(date, options) {
1069
- return this.relativeDate(date, this.config.relativeTemplates.long, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds);
342
+ transform(value, currYear) {
343
+ const date = this.adapter.deserialize(value);
344
+ return date ? this.formatter.absoluteShortDate(date, currYear) : '';
1070
345
  }
1071
- /**
1072
- * @param date - date
1073
- * @param params - parameters
1074
- * @param datetime - should time be shown as well
1075
- * @param seconds - should time with seconds be shown as well
1076
- * @param milliseconds - should time with milliseconds be shown as well
1077
- * @param currYear - should current year be shown as well
1078
- */
1079
- absoluteDate(date, params, datetime = false, seconds = false, milliseconds = false, currYear = false) {
1080
- if (!this.adapter.isDateInstance(date)) {
1081
- throw new Error(this.invalidDateErrorText);
1082
- }
1083
- const variables = this.compileVariables(date, Object.assign(Object.assign({}, this.adapter.config.variables), params.variables), currYear);
1084
- variables.SHOW_SECONDS = seconds ? 'yes' : 'no';
1085
- variables.SHOW_MILLISECONDS = milliseconds ? 'yes' : 'no';
1086
- const template = datetime ? params.DATETIME : params.DATE;
1087
- return this.messageFormat.compile(template)(variables);
346
+ }
347
+ /** @nocollapse */ AbsoluteDateShortFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateShortFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
348
+ /** @nocollapse */ AbsoluteDateShortFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateShortFormatterPipe, name: "absoluteShortDate" });
349
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteDateShortFormatterPipe, decorators: [{
350
+ type: Pipe,
351
+ args: [{ name: 'absoluteShortDate' }]
352
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
353
+ class AbsoluteShortDateTimeFormatterPipe {
354
+ constructor(adapter, formatter) {
355
+ this.adapter = adapter;
356
+ this.formatter = formatter;
1088
357
  }
1089
- /**
1090
- * @param date - date
1091
- * @param currYear - should the year be shown forced
1092
- * @returns absolute date in short format
1093
- */
1094
- absoluteShortDate(date, currYear = false) {
1095
- return this.absoluteDate(date, this.config.absoluteTemplates.short, false, false, false, currYear);
358
+ transform(value, options) {
359
+ const date = this.adapter.deserialize(value);
360
+ return date ? this.formatter.absoluteShortDateTime(date, options) : '';
1096
361
  }
1097
- /**
1098
- * @param date - date
1099
- * @param options - DateTimeOptions
1100
- * @returns absolute date in short format with time
1101
- */
1102
- absoluteShortDateTime(date, options) {
1103
- return this.absoluteDate(date, this.config.absoluteTemplates.short, true, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds, options === null || options === void 0 ? void 0 : options.currYear);
362
+ }
363
+ /** @nocollapse */ AbsoluteShortDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteShortDateTimeFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
364
+ /** @nocollapse */ AbsoluteShortDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteShortDateTimeFormatterPipe, name: "absoluteShortDateTime" });
365
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: AbsoluteShortDateTimeFormatterPipe, decorators: [{
366
+ type: Pipe,
367
+ args: [{ name: 'absoluteShortDateTime' }]
368
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
369
+ class RelativeDateFormatterPipe {
370
+ constructor(adapter, formatter) {
371
+ this.adapter = adapter;
372
+ this.formatter = formatter;
1104
373
  }
1105
- /**
1106
- * @param date - date
1107
- * @param currYear - should the year be shown forced
1108
- * @returns absolute date in long format
1109
- */
1110
- absoluteLongDate(date, currYear = false) {
1111
- return this.absoluteDate(date, this.config.absoluteTemplates.long, false, false, false, currYear);
374
+ transform(value) {
375
+ const date = this.adapter.deserialize(value);
376
+ return date ? this.formatter.relativeLongDate(date) : '';
1112
377
  }
1113
- /**
1114
- * @param date - date
1115
- * @param options - DateTimeOptions
1116
- * @returns absolute date in long format with time
1117
- */
1118
- absoluteLongDateTime(date, options) {
1119
- return this.absoluteDate(date, this.config.absoluteTemplates.long, true, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds, options === null || options === void 0 ? void 0 : options.currYear);
378
+ }
379
+ /** @nocollapse */ RelativeDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeDateFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
380
+ /** @nocollapse */ RelativeDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RelativeDateFormatterPipe, name: "relativeLongDate" });
381
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeDateFormatterPipe, decorators: [{
382
+ type: Pipe,
383
+ args: [{ name: 'relativeLongDate' }]
384
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
385
+ class RelativeDateTimeFormatterPipe {
386
+ constructor(adapter, formatter) {
387
+ this.adapter = adapter;
388
+ this.formatter = formatter;
1120
389
  }
1121
- /**
1122
- * @param startDate - start date
1123
- * @param endDate - end date
1124
- * @param template - template
1125
- * @returns opened date
1126
- */
1127
- openedRangeDate(startDate, endDate, template) {
1128
- if (!this.adapter.isDateInstance(startDate) && !this.adapter.isDateInstance(endDate)) {
1129
- throw new Error(this.invalidDateErrorText);
1130
- }
1131
- const variables = Object.assign(Object.assign({}, this.adapter.config.variables), template.variables);
1132
- let params = {};
1133
- if (startDate) {
1134
- const startDateVariables = this.compileVariables(startDate, variables);
1135
- params = Object.assign(Object.assign({}, variables), { START_DATE: this.messageFormat.compile(template.START_DATE)(startDateVariables), RANGE_TYPE: 'onlyStart' });
1136
- }
1137
- else if (endDate) {
1138
- const endDateVariables = this.compileVariables(endDate, variables);
1139
- params = Object.assign(Object.assign({}, variables), { END_DATE: this.messageFormat.compile(template.END_DATE)(endDateVariables), RANGE_TYPE: 'onlyEnd' });
1140
- }
1141
- return this.messageFormat.compile(template.DATE)(params);
1142
- }
1143
- /**
1144
- * @param startDate - start date
1145
- * @param endDate - end date
1146
- * @param template - template
1147
- * @param seconds - should time with seconds be shown as well
1148
- * @param milliseconds - should time with milliseconds be shown as well
1149
- * @returns opened date
1150
- */
1151
- openedRangeDateTime(startDate, endDate, template, seconds = false, milliseconds = false) {
1152
- if (!this.adapter.isDateInstance(startDate) && !this.adapter.isDateInstance(endDate)) {
1153
- throw new Error(this.invalidDateErrorText);
1154
- }
1155
- const variables = Object.assign(Object.assign({}, this.adapter.config.variables), template.variables);
1156
- let params = {};
1157
- if (startDate) {
1158
- const startDateVariables = this.compileVariables(startDate, variables);
1159
- startDateVariables.SHOW_SECONDS = seconds ? 'yes' : 'no';
1160
- startDateVariables.SHOW_MILLISECONDS = milliseconds ? 'yes' : 'no';
1161
- params = Object.assign(Object.assign({}, variables), { START_DATETIME: this.messageFormat.compile(template.START_DATETIME)(startDateVariables), RANGE_TYPE: 'onlyStart' });
1162
- }
1163
- else if (endDate) {
1164
- const endDateVariables = this.compileVariables(endDate, variables);
1165
- endDateVariables.SHOW_SECONDS = seconds ? 'yes' : 'no';
1166
- endDateVariables.SHOW_MILLISECONDS = milliseconds ? 'yes' : 'no';
1167
- params = Object.assign(Object.assign({}, variables), { END_DATETIME: this.messageFormat.compile(template.END_DATETIME)(endDateVariables), RANGE_TYPE: 'onlyEnd' });
1168
- }
1169
- return this.messageFormat.compile(template.DATETIME)(params);
1170
- }
1171
- /**
1172
- * @param startDate - start date
1173
- * @param endDate - end date
1174
- * @param template - template
1175
- * @returns range date in template format
1176
- */
1177
- rangeDate(startDate, endDate, template) {
1178
- if (!this.adapter.isDateInstance(startDate) || !this.adapter.isDateInstance(endDate)) {
1179
- throw new Error(this.invalidDateErrorText);
1180
- }
1181
- const variables = Object.assign(Object.assign({}, this.adapter.config.variables), template.variables);
1182
- const sameMonth = this.hasSame(startDate, endDate, 'month');
1183
- const startDateVariables = this.compileVariables(startDate, variables);
1184
- startDateVariables.SAME_MONTH = sameMonth;
1185
- const endDateVariables = this.compileVariables(endDate, variables);
1186
- endDateVariables.SAME_MONTH = sameMonth;
1187
- const bothCurrentYear = startDateVariables.CURRENT_YEAR === 'yes' && endDateVariables.CURRENT_YEAR === 'yes';
1188
- startDateVariables.CURRENT_YEAR = bothCurrentYear ? 'yes' : 'no';
1189
- endDateVariables.CURRENT_YEAR = bothCurrentYear ? 'yes' : 'no';
1190
- const params = Object.assign(Object.assign({}, variables), { START_DATE: this.messageFormat.compile(template.START_DATE)(startDateVariables), END_DATE: this.messageFormat.compile(template.END_DATE)(endDateVariables), SAME_MONTH: sameMonth });
1191
- return this.messageFormat.compile(template.DATE)(params);
1192
- }
1193
- /**
1194
- * @param startDate - start date
1195
- * @param endDate - end date
1196
- * @param template - template
1197
- * @param seconds - use seconds
1198
- * @param milliseconds - use milliseconds
1199
- * @returns range date in template format with time
1200
- */
1201
- rangeDateTime(startDate, endDate, template, seconds = false, milliseconds = false) {
1202
- if (!this.adapter.isDateInstance(startDate) || !this.adapter.isDateInstance(endDate)) {
1203
- throw new Error(this.invalidDateErrorText);
1204
- }
1205
- const variables = Object.assign(Object.assign({}, this.adapter.config.variables), template.variables);
1206
- const sameMonth = this.hasSame(startDate, endDate, 'month');
1207
- const sameDay = this.hasSame(startDate, endDate, 'day');
1208
- const startDateVariables = this.compileVariables(startDate, variables);
1209
- startDateVariables.SAME_MONTH = sameMonth;
1210
- startDateVariables.SAME_DAY = sameDay;
1211
- startDateVariables.SHOW_SECONDS = seconds ? 'yes' : 'no';
1212
- startDateVariables.SHOW_MILLISECONDS = milliseconds ? 'yes' : 'no';
1213
- const endDateVariables = this.compileVariables(endDate, variables);
1214
- endDateVariables.SAME_MONTH = sameMonth;
1215
- endDateVariables.SAME_DAY = sameDay;
1216
- endDateVariables.SHOW_SECONDS = seconds ? 'yes' : 'no';
1217
- endDateVariables.SHOW_MILLISECONDS = milliseconds ? 'yes' : 'no';
1218
- const bothCurrentYear = startDateVariables.CURRENT_YEAR === 'yes' && endDateVariables.CURRENT_YEAR === 'yes';
1219
- startDateVariables.CURRENT_YEAR = bothCurrentYear ? 'yes' : 'no';
1220
- endDateVariables.CURRENT_YEAR = bothCurrentYear ? 'yes' : 'no';
1221
- const params = Object.assign(Object.assign({}, variables), { START_DATETIME: this.messageFormat.compile(template.START_DATETIME)(startDateVariables), END_DATETIME: this.messageFormat.compile(template.END_DATETIME)(endDateVariables), SAME_MONTH: sameMonth, SAME_DAY: sameDay });
1222
- return this.messageFormat.compile(template.DATETIME)(params);
1223
- }
1224
- /**
1225
- * @param startDate - start date
1226
- * @param endDate - end date
1227
- * @returns range date in short format
1228
- */
1229
- rangeShortDate(startDate, endDate) {
1230
- const rangeTemplates = this.config.rangeTemplates;
1231
- if (startDate && endDate) {
1232
- return this.rangeDate(startDate, endDate, rangeTemplates.closedRange.short);
1233
- }
1234
- return this.openedRangeDate(startDate, endDate || null, rangeTemplates.openedRange.short);
1235
- }
1236
- /**
1237
- * @param startDate - start date
1238
- * @param endDate - end date
1239
- * @param options - DateTimeOptions
1240
- * @returns range date in short format with time
1241
- */
1242
- rangeShortDateTime(startDate, endDate, options) {
1243
- const rangeTemplates = this.config.rangeTemplates;
1244
- if (startDate && endDate) {
1245
- return this.rangeDateTime(startDate, endDate, rangeTemplates.closedRange.short, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds);
1246
- }
1247
- return this.openedRangeDateTime(startDate, endDate || null, rangeTemplates.openedRange.short, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds);
1248
- }
1249
- /**
1250
- * @param startDate - start date
1251
- * @param endDate - end date
1252
- * @returns range date in long format
1253
- */
1254
- rangeLongDate(startDate, endDate) {
1255
- const rangeTemplates = this.config.rangeTemplates;
1256
- if (startDate && endDate) {
1257
- return this.rangeDate(startDate, endDate, rangeTemplates.closedRange.long);
1258
- }
1259
- return this.openedRangeDate(startDate, endDate || null, rangeTemplates.openedRange.long);
1260
- }
1261
- /**
1262
- * @param startDate - start date
1263
- * @param endDate - end date
1264
- * @param options - DateTimeOptions
1265
- * @returns range date in long format with time
1266
- */
1267
- rangeLongDateTime(startDate, endDate, options) {
1268
- const rangeTemplates = this.config.rangeTemplates;
1269
- if (startDate && endDate) {
1270
- return this.rangeDateTime(startDate, endDate, rangeTemplates.closedRange.long, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds);
1271
- }
1272
- return this.openedRangeDateTime(startDate, endDate || null, rangeTemplates.openedRange.long);
1273
- }
1274
- /**
1275
- * @param startDate - start date
1276
- * @param endDate - end date
1277
- * @param options - DateTimeOptions
1278
- * @returns range middle date with time
1279
- */
1280
- rangeMiddleDateTime(startDate, endDate, options) {
1281
- return this.rangeDateTime(startDate, endDate, this.config.rangeTemplates.closedRange.middle, options === null || options === void 0 ? void 0 : options.seconds, options === null || options === void 0 ? void 0 : options.milliseconds);
1282
- }
1283
- /**
1284
- * @param startDate - start date
1285
- * @param endDate - end date
1286
- * @param seconds - add seconds to formatted value
1287
- * @param milliseconds - add milliseconds to formatted value
1288
- * @returns formatted duration as string like 48:02:25
1289
- */
1290
- durationShortest(startDate, endDate, seconds = true, milliseconds = false) {
1291
- this.checkDates(startDate, endDate);
1292
- if (startDate > endDate) {
1293
- throw new Error(this.invalidDateErrorText);
1294
- }
1295
- const durationObject = this.adapter.durationObjectFromDates(startDate, endDate, ['hours', 'minutes', 'seconds', 'milliseconds']);
1296
- const roundedSeconds = Math.floor(this.adapter.durationAs(durationObject, 'seconds'));
1297
- if (seconds) {
1298
- return this.compileMessage(this.config.durationTemplates.shortest.FULL, {
1299
- D: roundedSeconds,
1300
- SHOW_MILLISECONDS: milliseconds ? 'yes' : 'no',
1301
- MILLISECONDS: durationObject.milliseconds
1302
- });
1303
- }
1304
- return roundedSeconds - (roundedSeconds % 60) ? this.compileMessage(this.config.durationTemplates.shortest.ONLY_MINUTES, {
1305
- HOURS: durationObject.hours,
1306
- MINUTES: durationObject.minutes
1307
- }) : '';
1308
- }
1309
- /**
1310
- * @param startDate - start date
1311
- * @param endDate - end date
1312
- * @param units - if defined, units to show will be specified
1313
- * @param fraction - shows fraction part for years and months
1314
- * @param template - specify template
1315
- * @returns formatted duration as string
1316
- */
1317
- duration(startDate, endDate, units, fraction, template) {
1318
- this.checkDates(startDate, endDate);
1319
- if (startDate > endDate) {
1320
- throw new Error(this.invalidDateErrorText);
1321
- }
1322
- const values = this.adapter.durationObjectFromDates(startDate, endDate, units, fraction);
1323
- const variables = Object.assign({}, values);
1324
- variables.SHOW_MILLISECONDS = values.milliseconds ? 'yes' : 'no';
1325
- return Object
1326
- .keys(values)
1327
- .reduce((acc, unit, index, arr) => {
1328
- if (fraction) {
1329
- variables.floorValue = Math.floor(values[unit]);
1330
- acc.push(this.compileMessage(template[`${unit.toUpperCase()}_FRACTION`], variables));
1331
- }
1332
- else {
1333
- if (arr.length > 1 && index === arr.length - 1) {
1334
- acc.push(this.compileMessage(template.SEPARATOR, variables));
1335
- }
1336
- acc.push(this.compileMessage(template[unit.toUpperCase()], variables));
1337
- }
1338
- return acc;
1339
- }, [])
1340
- .filter((text) => !!text)
1341
- .join(' ');
1342
- }
1343
- durationLong(startDate, endDate, units = [], fraction = false) {
1344
- return this.duration(startDate, endDate, units, fraction, this.config.durationTemplates.long);
1345
- }
1346
- durationShort(startDate, endDate, units = [], fraction = false) {
1347
- return this.duration(startDate, endDate, units, fraction, this.config.durationTemplates.short);
1348
- }
1349
- checkDates(...args) {
1350
- args.forEach((date) => {
1351
- if (!this.adapter.isDateInstance(date) || !this.adapter.isValid(date)) {
1352
- throw new Error(this.invalidDateErrorText);
1353
- }
1354
- });
1355
- }
1356
- compileMessage(message, variables) {
1357
- return this.messageFormat.compile(message)(variables);
1358
- }
1359
- /**
1360
- * @param date - date for compile
1361
- * @param variables - date template variables
1362
- * @param currYearForced - param for absolute days formatting
1363
- * @returns compiledVariables
1364
- */
1365
- compileVariables(date, variables, currYearForced = false) {
1366
- const compiledVariables = {};
1367
- // tslint:disable-next-line:no-for-in
1368
- for (const key in variables) {
1369
- if (!variables.hasOwnProperty(key)) {
1370
- continue;
1371
- }
1372
- const value = variables[key];
1373
- compiledVariables[key] = this.adapter.format(date, value);
1374
- }
1375
- compiledVariables.CURRENT_YEAR = (currYearForced && 'no') || this.hasSame(date, this.adapter.today(), 'year');
1376
- return compiledVariables;
1377
- }
1378
- isBeforeYesterday(date) {
1379
- return this.adapter.daysFromToday(date) <= -2;
1380
- }
1381
- isYesterday(date) {
1382
- return this.adapter.daysFromToday(date) === -1;
1383
- }
1384
- isToday(date) {
1385
- return this.adapter.daysFromToday(date) === 0;
1386
- }
1387
- isTomorrow(date) {
1388
- return this.adapter.daysFromToday(date) === 1;
1389
- }
1390
- isAfterTomorrow(date) {
1391
- return this.adapter.daysFromToday(date) >= 2;
1392
- }
1393
- hasSame(startDate, endDate, unit) {
1394
- return this.adapter.hasSame(startDate, endDate, unit) ? 'yes' : 'no';
1395
- }
1396
- }
1397
- /** @nocollapse */ DateFormatter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DateFormatter, deps: [{ token: i1.DateAdapter }, { token: MC_DATE_LOCALE }], target: i0.ɵɵFactoryTarget.Injectable });
1398
- /** @nocollapse */ DateFormatter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DateFormatter });
1399
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: DateFormatter, decorators: [{
1400
- type: Injectable
1401
- }], ctorParameters: function () {
1402
- return [{ type: i1.DateAdapter }, { type: undefined, decorators: [{
1403
- type: Inject,
1404
- args: [MC_DATE_LOCALE]
1405
- }] }];
1406
- } });
1407
-
1408
- class AbsoluteDateFormatterPipe {
1409
- constructor(adapter, formatter) {
1410
- this.adapter = adapter;
1411
- this.formatter = formatter;
1412
- }
1413
- transform(value, currYear) {
1414
- const date = this.adapter.deserialize(value);
1415
- return date ? this.formatter.absoluteLongDate(date, currYear) : '';
1416
- }
1417
- }
1418
- /** @nocollapse */ AbsoluteDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1419
- /** @nocollapse */ AbsoluteDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateFormatterPipe, name: "absoluteLongDate" });
1420
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateFormatterPipe, decorators: [{
1421
- type: Pipe,
1422
- args: [{ name: 'absoluteLongDate' }]
1423
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
1424
- class AbsoluteDateTimeFormatterPipe {
1425
- constructor(adapter, formatter) {
1426
- this.adapter = adapter;
1427
- this.formatter = formatter;
1428
- }
1429
- transform(value, options) {
1430
- const date = this.adapter.deserialize(value);
1431
- return date ? this.formatter.absoluteLongDateTime(date, options) : '';
1432
- }
1433
- }
1434
- /** @nocollapse */ AbsoluteDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateTimeFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1435
- /** @nocollapse */ AbsoluteDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateTimeFormatterPipe, name: "absoluteLongDateTime" });
1436
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateTimeFormatterPipe, decorators: [{
1437
- type: Pipe,
1438
- args: [{ name: 'absoluteLongDateTime' }]
1439
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
1440
- class AbsoluteDateShortFormatterPipe {
1441
- constructor(adapter, formatter) {
1442
- this.adapter = adapter;
1443
- this.formatter = formatter;
1444
- }
1445
- transform(value, currYear) {
1446
- const date = this.adapter.deserialize(value);
1447
- return date ? this.formatter.absoluteShortDate(date, currYear) : '';
1448
- }
1449
- }
1450
- /** @nocollapse */ AbsoluteDateShortFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateShortFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1451
- /** @nocollapse */ AbsoluteDateShortFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateShortFormatterPipe, name: "absoluteShortDate" });
1452
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteDateShortFormatterPipe, decorators: [{
1453
- type: Pipe,
1454
- args: [{ name: 'absoluteShortDate' }]
1455
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
1456
- class AbsoluteShortDateTimeFormatterPipe {
1457
- constructor(adapter, formatter) {
1458
- this.adapter = adapter;
1459
- this.formatter = formatter;
1460
- }
1461
- transform(value, options) {
1462
- const date = this.adapter.deserialize(value);
1463
- return date ? this.formatter.absoluteShortDateTime(date, options) : '';
1464
- }
1465
- }
1466
- /** @nocollapse */ AbsoluteShortDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteShortDateTimeFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1467
- /** @nocollapse */ AbsoluteShortDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteShortDateTimeFormatterPipe, name: "absoluteShortDateTime" });
1468
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: AbsoluteShortDateTimeFormatterPipe, decorators: [{
1469
- type: Pipe,
1470
- args: [{ name: 'absoluteShortDateTime' }]
1471
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
1472
- class RelativeDateFormatterPipe {
1473
- constructor(adapter, formatter) {
1474
- this.adapter = adapter;
1475
- this.formatter = formatter;
1476
- }
1477
- transform(value) {
1478
- const date = this.adapter.deserialize(value);
1479
- return date ? this.formatter.relativeLongDate(date) : '';
1480
- }
1481
- }
1482
- /** @nocollapse */ RelativeDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeDateFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1483
- /** @nocollapse */ RelativeDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RelativeDateFormatterPipe, name: "relativeLongDate" });
1484
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeDateFormatterPipe, decorators: [{
1485
- type: Pipe,
1486
- args: [{ name: 'relativeLongDate' }]
1487
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
1488
- class RelativeDateTimeFormatterPipe {
1489
- constructor(adapter, formatter) {
1490
- this.adapter = adapter;
1491
- this.formatter = formatter;
1492
- }
1493
- transform(value, options) {
1494
- const date = this.adapter.deserialize(value);
1495
- return date ? this.formatter.relativeLongDateTime(date, options) : '';
390
+ transform(value, options) {
391
+ const date = this.adapter.deserialize(value);
392
+ return date ? this.formatter.relativeLongDateTime(date, options) : '';
1496
393
  }
1497
394
  }
1498
- /** @nocollapse */ RelativeDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeDateTimeFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1499
- /** @nocollapse */ RelativeDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RelativeDateTimeFormatterPipe, name: "relativeLongDateTime" });
1500
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeDateTimeFormatterPipe, decorators: [{
395
+ /** @nocollapse */ RelativeDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeDateTimeFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
396
+ /** @nocollapse */ RelativeDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RelativeDateTimeFormatterPipe, name: "relativeLongDateTime" });
397
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeDateTimeFormatterPipe, decorators: [{
1501
398
  type: Pipe,
1502
399
  args: [{ name: 'relativeLongDateTime' }]
1503
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
400
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1504
401
  class RelativeShortDateFormatterPipe {
1505
402
  constructor(adapter, formatter) {
1506
403
  this.adapter = adapter;
@@ -1511,12 +408,12 @@ class RelativeShortDateFormatterPipe {
1511
408
  return date ? this.formatter.relativeShortDate(date) : '';
1512
409
  }
1513
410
  }
1514
- /** @nocollapse */ RelativeShortDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeShortDateFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1515
- /** @nocollapse */ RelativeShortDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RelativeShortDateFormatterPipe, name: "relativeShortDate" });
1516
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeShortDateFormatterPipe, decorators: [{
411
+ /** @nocollapse */ RelativeShortDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeShortDateFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
412
+ /** @nocollapse */ RelativeShortDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RelativeShortDateFormatterPipe, name: "relativeShortDate" });
413
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeShortDateFormatterPipe, decorators: [{
1517
414
  type: Pipe,
1518
415
  args: [{ name: 'relativeShortDate' }]
1519
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
416
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1520
417
  class RelativeShortDateTimeFormatterPipe {
1521
418
  constructor(adapter, formatter) {
1522
419
  this.adapter = adapter;
@@ -1527,12 +424,12 @@ class RelativeShortDateTimeFormatterPipe {
1527
424
  return date ? this.formatter.relativeShortDateTime(date, options) : '';
1528
425
  }
1529
426
  }
1530
- /** @nocollapse */ RelativeShortDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeShortDateTimeFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1531
- /** @nocollapse */ RelativeShortDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RelativeShortDateTimeFormatterPipe, name: "relativeShortDateTime" });
1532
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RelativeShortDateTimeFormatterPipe, decorators: [{
427
+ /** @nocollapse */ RelativeShortDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeShortDateTimeFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
428
+ /** @nocollapse */ RelativeShortDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RelativeShortDateTimeFormatterPipe, name: "relativeShortDateTime" });
429
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RelativeShortDateTimeFormatterPipe, decorators: [{
1533
430
  type: Pipe,
1534
431
  args: [{ name: 'relativeShortDateTime' }]
1535
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
432
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1536
433
  class RangeDateFormatterPipe {
1537
434
  constructor(adapter, formatter) {
1538
435
  this.adapter = adapter;
@@ -1544,12 +441,12 @@ class RangeDateFormatterPipe {
1544
441
  return this.formatter.rangeLongDate(date1, date2);
1545
442
  }
1546
443
  }
1547
- /** @nocollapse */ RangeDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeDateFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1548
- /** @nocollapse */ RangeDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RangeDateFormatterPipe, name: "rangeLongDate" });
1549
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeDateFormatterPipe, decorators: [{
444
+ /** @nocollapse */ RangeDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeDateFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
445
+ /** @nocollapse */ RangeDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RangeDateFormatterPipe, name: "rangeLongDate" });
446
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeDateFormatterPipe, decorators: [{
1550
447
  type: Pipe,
1551
448
  args: [{ name: 'rangeLongDate' }]
1552
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
449
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1553
450
  class RangeShortDateFormatterPipe {
1554
451
  constructor(adapter, formatter) {
1555
452
  this.adapter = adapter;
@@ -1561,12 +458,12 @@ class RangeShortDateFormatterPipe {
1561
458
  return this.formatter.rangeShortDate(date1, date2);
1562
459
  }
1563
460
  }
1564
- /** @nocollapse */ RangeShortDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeShortDateFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1565
- /** @nocollapse */ RangeShortDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RangeShortDateFormatterPipe, name: "rangeShortDate" });
1566
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeShortDateFormatterPipe, decorators: [{
461
+ /** @nocollapse */ RangeShortDateFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeShortDateFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
462
+ /** @nocollapse */ RangeShortDateFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RangeShortDateFormatterPipe, name: "rangeShortDate" });
463
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeShortDateFormatterPipe, decorators: [{
1567
464
  type: Pipe,
1568
465
  args: [{ name: 'rangeShortDate' }]
1569
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
466
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1570
467
  class RangeDateTimeFormatterPipe {
1571
468
  constructor(adapter, formatter) {
1572
469
  this.adapter = adapter;
@@ -1578,12 +475,12 @@ class RangeDateTimeFormatterPipe {
1578
475
  return this.formatter.rangeLongDateTime(date1, date2, options);
1579
476
  }
1580
477
  }
1581
- /** @nocollapse */ RangeDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeDateTimeFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1582
- /** @nocollapse */ RangeDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RangeDateTimeFormatterPipe, name: "rangeLongDateTime" });
1583
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeDateTimeFormatterPipe, decorators: [{
478
+ /** @nocollapse */ RangeDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeDateTimeFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
479
+ /** @nocollapse */ RangeDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RangeDateTimeFormatterPipe, name: "rangeLongDateTime" });
480
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeDateTimeFormatterPipe, decorators: [{
1584
481
  type: Pipe,
1585
482
  args: [{ name: 'rangeLongDateTime' }]
1586
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
483
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1587
484
  class RangeMiddleDateTimeFormatterPipe {
1588
485
  constructor(adapter, formatter) {
1589
486
  this.adapter = adapter;
@@ -1595,12 +492,12 @@ class RangeMiddleDateTimeFormatterPipe {
1595
492
  return this.formatter.rangeMiddleDateTime(date1, date2, options);
1596
493
  }
1597
494
  }
1598
- /** @nocollapse */ RangeMiddleDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeMiddleDateTimeFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1599
- /** @nocollapse */ RangeMiddleDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RangeMiddleDateTimeFormatterPipe, name: "rangeMiddleDateTime" });
1600
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeMiddleDateTimeFormatterPipe, decorators: [{
495
+ /** @nocollapse */ RangeMiddleDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeMiddleDateTimeFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
496
+ /** @nocollapse */ RangeMiddleDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RangeMiddleDateTimeFormatterPipe, name: "rangeMiddleDateTime" });
497
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeMiddleDateTimeFormatterPipe, decorators: [{
1601
498
  type: Pipe,
1602
499
  args: [{ name: 'rangeMiddleDateTime' }]
1603
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
500
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1604
501
  class RangeShortDateTimeFormatterPipe {
1605
502
  constructor(adapter, formatter) {
1606
503
  this.adapter = adapter;
@@ -1612,12 +509,12 @@ class RangeShortDateTimeFormatterPipe {
1612
509
  return this.formatter.rangeShortDateTime(date1, date2, options);
1613
510
  }
1614
511
  }
1615
- /** @nocollapse */ RangeShortDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeShortDateTimeFormatterPipe, deps: [{ token: i1.DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
1616
- /** @nocollapse */ RangeShortDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: RangeShortDateTimeFormatterPipe, name: "rangeShortDateTime" });
1617
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: RangeShortDateTimeFormatterPipe, decorators: [{
512
+ /** @nocollapse */ RangeShortDateTimeFormatterPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeShortDateTimeFormatterPipe, deps: [{ token: DateAdapter }, { token: DateFormatter }], target: i0.ɵɵFactoryTarget.Pipe });
513
+ /** @nocollapse */ RangeShortDateTimeFormatterPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: RangeShortDateTimeFormatterPipe, name: "rangeShortDateTime" });
514
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: RangeShortDateTimeFormatterPipe, decorators: [{
1618
515
  type: Pipe,
1619
516
  args: [{ name: 'rangeShortDateTime' }]
1620
- }], ctorParameters: function () { return [{ type: i1.DateAdapter }, { type: DateFormatter }]; } });
517
+ }], ctorParameters: function () { return [{ type: DateAdapter }, { type: DateFormatter }]; } });
1621
518
 
1622
519
  /* tslint:disable:naming-convention */
1623
520
  const MC_LOCALE_ID = new InjectionToken('McLocaleId');
@@ -1714,10 +611,10 @@ class McDecimalPipe {
1714
611
  }
1715
612
  }
1716
613
  }
1717
- /** @nocollapse */ McDecimalPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McDecimalPipe, deps: [{ token: MC_LOCALE_ID, optional: true }, { token: MC_NUMBER_FORMATTER_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Pipe });
1718
- /** @nocollapse */ McDecimalPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McDecimalPipe, name: "mcNumber" });
1719
- /** @nocollapse */ McDecimalPipe.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McDecimalPipe, providedIn: 'root' });
1720
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McDecimalPipe, decorators: [{
614
+ /** @nocollapse */ McDecimalPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McDecimalPipe, deps: [{ token: MC_LOCALE_ID, optional: true }, { token: MC_NUMBER_FORMATTER_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Pipe });
615
+ /** @nocollapse */ McDecimalPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McDecimalPipe, name: "mcNumber" });
616
+ /** @nocollapse */ McDecimalPipe.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McDecimalPipe, providedIn: 'root' });
617
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McDecimalPipe, decorators: [{
1721
618
  type: Injectable,
1722
619
  args: [{ providedIn: 'root' }]
1723
620
  }, {
@@ -1739,8 +636,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1739
636
 
1740
637
  class McFormattersModule {
1741
638
  }
1742
- /** @nocollapse */ McFormattersModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormattersModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1743
- /** @nocollapse */ McFormattersModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McFormattersModule, declarations: [McDecimalPipe,
639
+ /** @nocollapse */ McFormattersModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormattersModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
640
+ /** @nocollapse */ McFormattersModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McFormattersModule, declarations: [McDecimalPipe,
1744
641
  AbsoluteDateFormatterPipe,
1745
642
  AbsoluteDateTimeFormatterPipe,
1746
643
  AbsoluteDateShortFormatterPipe,
@@ -1767,8 +664,8 @@ class McFormattersModule {
1767
664
  RangeDateTimeFormatterPipe,
1768
665
  RangeShortDateTimeFormatterPipe,
1769
666
  RangeMiddleDateTimeFormatterPipe] });
1770
- /** @nocollapse */ McFormattersModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormattersModule, providers: [DateFormatter] });
1771
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormattersModule, decorators: [{
667
+ /** @nocollapse */ McFormattersModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormattersModule, providers: [DateFormatter] });
668
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormattersModule, decorators: [{
1772
669
  type: NgModule,
1773
670
  args: [{
1774
671
  declarations: [
@@ -1807,9 +704,90 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1807
704
  }]
1808
705
  }] });
1809
706
 
1810
- const validationTooltipShowDelay = 10;
1811
- const validationTooltipHideDelay = 3000;
1812
- const MC_VALIDATION = new InjectionToken('McUseValidation', { factory: () => ({ useValidation: true }) });
707
+ class McFormElement {
708
+ constructor(element) {
709
+ this.element = element;
710
+ this.margin = false;
711
+ this.isRow = false;
712
+ this.isFieldSet = false;
713
+ this.hasLegend = false;
714
+ this.isHorizontal = false;
715
+ }
716
+ ngAfterContentInit() {
717
+ const classList = this.element.nativeElement.classList;
718
+ this.isRow = classList.contains('mc-form__row');
719
+ this.isHorizontal = classList.contains('mc-horizontal');
720
+ this.isFieldSet = classList.contains('mc-form__fieldset');
721
+ if (this.isFieldSet && this.element.nativeElement.firstElementChild) {
722
+ this.hasLegend = this.element.nativeElement.firstElementChild.classList.contains('mc-form__legend');
723
+ }
724
+ }
725
+ }
726
+ /** @nocollapse */ McFormElement.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormElement, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
727
+ /** @nocollapse */ McFormElement.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: McFormElement, selector: ".mc-form__row, .mc-form__fieldset, .mc-form__legend", host: { properties: { "class.mc-form-row_margin": "margin" } }, queries: [{ propertyName: "elements", predicate: McFormElement }], exportAs: ["mcFormElement"], ngImport: i0 });
728
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormElement, decorators: [{
729
+ type: Directive,
730
+ args: [{
731
+ selector: '.mc-form__row, .mc-form__fieldset, .mc-form__legend',
732
+ exportAs: 'mcFormElement',
733
+ host: {
734
+ '[class.mc-form-row_margin]': 'margin'
735
+ }
736
+ }]
737
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { elements: [{
738
+ type: ContentChildren,
739
+ args: [McFormElement]
740
+ }] } });
741
+ class McForm {
742
+ ngAfterContentInit() {
743
+ this.handleElements(this.elements);
744
+ }
745
+ handleElements(elements) {
746
+ elements.forEach((element, index) => {
747
+ const nextElement = elements.get(index + 1);
748
+ if (element.isFieldSet && !element.isHorizontal) {
749
+ this.handleElements(element.elements);
750
+ }
751
+ element.margin = !!(nextElement && !nextElement.hasLegend);
752
+ });
753
+ }
754
+ }
755
+ /** @nocollapse */ McForm.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McForm, deps: [], target: i0.ɵɵFactoryTarget.Directive });
756
+ /** @nocollapse */ McForm.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: McForm, selector: ".mc-form-vertical, .mc-form-horizontal", host: { classAttribute: "mc-form" }, queries: [{ propertyName: "elements", predicate: McFormElement }], exportAs: ["mcForm"], ngImport: i0 });
757
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McForm, decorators: [{
758
+ type: Directive,
759
+ args: [{
760
+ selector: '.mc-form-vertical, .mc-form-horizontal',
761
+ exportAs: 'mcForm',
762
+ host: {
763
+ class: 'mc-form'
764
+ }
765
+ }]
766
+ }], propDecorators: { elements: [{
767
+ type: ContentChildren,
768
+ args: [McFormElement]
769
+ }] } });
770
+
771
+ class McFormsModule {
772
+ }
773
+ /** @nocollapse */ McFormsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
774
+ /** @nocollapse */ McFormsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McFormsModule, declarations: [McForm,
775
+ McFormElement], exports: [McForm,
776
+ McFormElement] });
777
+ /** @nocollapse */ McFormsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormsModule });
778
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McFormsModule, decorators: [{
779
+ type: NgModule,
780
+ args: [{
781
+ exports: [
782
+ McForm,
783
+ McFormElement
784
+ ],
785
+ declarations: [
786
+ McForm,
787
+ McFormElement
788
+ ]
789
+ }]
790
+ }] });
1813
791
 
1814
792
  function escapeRegExp(value) {
1815
793
  if (value) {
@@ -1825,19 +803,19 @@ class McHighlightPipe {
1825
803
  return value.replace(new RegExp(`(${escapeRegExp(args)})`, 'gi'), '<mark class="mc-highlight">$1</mark>');
1826
804
  }
1827
805
  }
1828
- /** @nocollapse */ McHighlightPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McHighlightPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
1829
- /** @nocollapse */ McHighlightPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McHighlightPipe, name: "mcHighlight" });
1830
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McHighlightPipe, decorators: [{
806
+ /** @nocollapse */ McHighlightPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McHighlightPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
807
+ /** @nocollapse */ McHighlightPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McHighlightPipe, name: "mcHighlight" });
808
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McHighlightPipe, decorators: [{
1831
809
  type: Pipe,
1832
810
  args: [{ name: 'mcHighlight' }]
1833
811
  }] });
1834
812
 
1835
813
  class McHighlightModule {
1836
814
  }
1837
- /** @nocollapse */ McHighlightModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McHighlightModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1838
- /** @nocollapse */ McHighlightModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McHighlightModule, declarations: [McHighlightPipe], imports: [CommonModule], exports: [McHighlightPipe] });
1839
- /** @nocollapse */ McHighlightModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McHighlightModule, imports: [CommonModule] });
1840
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McHighlightModule, decorators: [{
815
+ /** @nocollapse */ McHighlightModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McHighlightModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
816
+ /** @nocollapse */ McHighlightModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McHighlightModule, declarations: [McHighlightPipe], imports: [CommonModule], exports: [McHighlightPipe] });
817
+ /** @nocollapse */ McHighlightModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McHighlightModule, imports: [CommonModule] });
818
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McHighlightModule, decorators: [{
1841
819
  type: NgModule,
1842
820
  args: [{
1843
821
  imports: [CommonModule],
@@ -1846,371 +824,104 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
1846
824
  }]
1847
825
  }] });
1848
826
 
1849
- const selectEvents = 'selectEvents';
827
+ /** InjectionToken that can be used to specify the global label options. */
828
+ const MC_LABEL_GLOBAL_OPTIONS = new InjectionToken('mc-label-global-options');
1850
829
 
1851
830
  /**
1852
- * Returns an exception to be thrown when attempting to change a select's `multiple` option
1853
- * after initialization.
1854
- * @docs-private
831
+ * Shared directive to count lines inside a text area, such as a list item.
832
+ * Line elements can be extracted with a @ContentChildren(McLine) query, then
833
+ * counted by checking the query list's length.
1855
834
  */
1856
- function getMcSelectDynamicMultipleError() {
1857
- return Error('Cannot change `multiple` mode of select after initialization.');
835
+ class McLine {
1858
836
  }
837
+ /** @nocollapse */ McLine.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McLine, deps: [], target: i0.ɵɵFactoryTarget.Directive });
838
+ /** @nocollapse */ McLine.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: McLine, selector: "[mc-line], [mcLine]", host: { classAttribute: "mc-line" }, ngImport: i0 });
839
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McLine, decorators: [{
840
+ type: Directive,
841
+ args: [{
842
+ selector: '[mc-line], [mcLine]',
843
+ host: { class: 'mc-line' }
844
+ }]
845
+ }] });
1859
846
  /**
1860
- * Returns an exception to be thrown when attempting to assign a non-array value to a select
1861
- * in `multiple` mode. Note that `undefined` and `null` are still valid values to allow for
1862
- * resetting the value.
847
+ * Helper that takes a query list of lines and sets the correct class on the host.
1863
848
  * @docs-private
1864
849
  */
1865
- function getMcSelectNonArrayValueError() {
1866
- return Error('Value must be an array in multiple-selection mode.');
1867
- }
1868
- /**
1869
- * Returns an exception to be thrown when assigning a non-function value to the comparator
1870
- * used to determine if a value corresponds to an option. Note that whether the function
1871
- * actually takes two values and returns a boolean is not checked.
1872
- */
1873
- function getMcSelectNonFunctionValueError() {
1874
- return Error('`compareWith` must be a function.');
1875
- }
1876
-
1877
- /** The max height of the select's overlay panel */
1878
- const SELECT_PANEL_MAX_HEIGHT = 224;
1879
- /** The panel's padding on the x-axis */
1880
- const SELECT_PANEL_PADDING_X = 1;
1881
- /** The panel's x axis padding if it is indented (e.g. there is an option group). */
1882
- /* tslint:disable-next-line:no-magic-numbers */
1883
- const SELECT_PANEL_INDENT_PADDING_X = SELECT_PANEL_PADDING_X * 2;
1884
- /**
1885
- * The select panel will only "fit" inside the viewport if it is positioned at
1886
- * this value or more away from the viewport boundary.
1887
- */
1888
- const SELECT_PANEL_VIEWPORT_PADDING = 8;
1889
- /** Injection token that determines the scroll handling while a select is open. */
1890
- const MC_SELECT_SCROLL_STRATEGY = new InjectionToken('mc-select-scroll-strategy');
1891
- /** @docs-private */
1892
- function mcSelectScrollStrategyProviderFactory(overlay) {
1893
- return () => overlay.scrollStrategies.reposition();
1894
- }
1895
- /** @docs-private */
1896
- const MC_SELECT_SCROLL_STRATEGY_PROVIDER = {
1897
- provide: MC_SELECT_SCROLL_STRATEGY,
1898
- deps: [Overlay],
1899
- useFactory: mcSelectScrollStrategyProviderFactory
1900
- };
1901
-
1902
- const POSITION_MAP = {
1903
- top: {
1904
- originX: 'center',
1905
- originY: 'top',
1906
- overlayX: 'center',
1907
- overlayY: 'bottom'
1908
- },
1909
- topCenter: {
1910
- originX: 'center',
1911
- originY: 'top',
1912
- overlayX: 'center',
1913
- overlayY: 'bottom'
1914
- },
1915
- topLeft: {
1916
- originX: 'start',
1917
- originY: 'top',
1918
- overlayX: 'start',
1919
- overlayY: 'bottom'
1920
- },
1921
- topRight: {
1922
- originX: 'end',
1923
- originY: 'top',
1924
- overlayX: 'end',
1925
- overlayY: 'bottom'
1926
- },
1927
- right: {
1928
- originX: 'end',
1929
- originY: 'center',
1930
- overlayX: 'start',
1931
- overlayY: 'center'
1932
- },
1933
- rightTop: {
1934
- originX: 'end',
1935
- originY: 'top',
1936
- overlayX: 'start',
1937
- overlayY: 'top'
1938
- },
1939
- rightBottom: {
1940
- originX: 'end',
1941
- originY: 'bottom',
1942
- overlayX: 'start',
1943
- overlayY: 'bottom'
1944
- },
1945
- bottom: {
1946
- originX: 'center',
1947
- originY: 'bottom',
1948
- overlayX: 'center',
1949
- overlayY: 'top'
1950
- },
1951
- bottomCenter: {
1952
- originX: 'center',
1953
- originY: 'bottom',
1954
- overlayX: 'center',
1955
- overlayY: 'top'
1956
- },
1957
- bottomLeft: {
1958
- originX: 'start',
1959
- originY: 'bottom',
1960
- overlayX: 'start',
1961
- overlayY: 'top'
1962
- },
1963
- bottomRight: {
1964
- originX: 'end',
1965
- originY: 'bottom',
1966
- overlayX: 'end',
1967
- overlayY: 'top'
1968
- },
1969
- left: {
1970
- originX: 'start',
1971
- originY: 'center',
1972
- overlayX: 'end',
1973
- overlayY: 'center'
1974
- },
1975
- leftTop: {
1976
- originX: 'start',
1977
- originY: 'top',
1978
- overlayX: 'end',
1979
- overlayY: 'top'
1980
- },
1981
- leftBottom: {
1982
- originX: 'start',
1983
- originY: 'bottom',
1984
- overlayX: 'end',
1985
- overlayY: 'bottom'
850
+ class McLineSetter {
851
+ constructor(_lines, _element) {
852
+ this._lines = _lines;
853
+ this._element = _element;
854
+ this.setLineClass(this._lines.length);
855
+ this._lines.changes.subscribe(() => {
856
+ this.setLineClass(this._lines.length);
857
+ });
1986
858
  }
1987
- };
1988
- const EXTENDED_OVERLAY_POSITIONS = objectValues([
1989
- POSITION_MAP.top,
1990
- POSITION_MAP.topLeft,
1991
- POSITION_MAP.topRight,
1992
- POSITION_MAP.right,
1993
- POSITION_MAP.rightTop,
1994
- POSITION_MAP.rightBottom,
1995
- POSITION_MAP.bottom,
1996
- POSITION_MAP.bottomLeft,
1997
- POSITION_MAP.bottomRight,
1998
- POSITION_MAP.left,
1999
- POSITION_MAP.leftTop,
2000
- POSITION_MAP.leftBottom
2001
- ]);
2002
- const TOP_POSITION_PRIORITY = objectValues([
2003
- POSITION_MAP.top,
2004
- POSITION_MAP.bottom,
2005
- POSITION_MAP.rightBottom,
2006
- POSITION_MAP.leftBottom,
2007
- POSITION_MAP.bottomLeft,
2008
- POSITION_MAP.bottomRight
2009
- ]);
2010
- const BOTTOM_POSITION_PRIORITY = objectValues([
2011
- POSITION_MAP.bottom,
2012
- POSITION_MAP.top,
2013
- POSITION_MAP.topLeft,
2014
- POSITION_MAP.topRight,
2015
- POSITION_MAP.rightBottom,
2016
- POSITION_MAP.leftBottom
2017
- ]);
2018
- const RIGHT_POSITION_PRIORITY = objectValues([
2019
- POSITION_MAP.right,
2020
- POSITION_MAP.left,
2021
- POSITION_MAP.leftTop,
2022
- POSITION_MAP.leftBottom,
2023
- POSITION_MAP.top,
2024
- POSITION_MAP.bottom
2025
- ]);
2026
- const LEFT_POSITION_PRIORITY = objectValues([
2027
- POSITION_MAP.left,
2028
- POSITION_MAP.right,
2029
- POSITION_MAP.rightTop,
2030
- POSITION_MAP.rightBottom,
2031
- POSITION_MAP.top,
2032
- POSITION_MAP.bottom
2033
- ]);
2034
- const RIGHT_TOP_POSITION_PRIORITY = objectValues([
2035
- POSITION_MAP.rightTop,
2036
- POSITION_MAP.leftTop,
2037
- POSITION_MAP.left,
2038
- POSITION_MAP.leftBottom,
2039
- POSITION_MAP.topLeft,
2040
- POSITION_MAP.bottomLeft
2041
- ]);
2042
- const RIGHT_BOTTOM_POSITION_PRIORITY = objectValues([
2043
- POSITION_MAP.rightBottom,
2044
- POSITION_MAP.leftBottom,
2045
- POSITION_MAP.left,
2046
- POSITION_MAP.leftTop,
2047
- POSITION_MAP.topLeft,
2048
- POSITION_MAP.bottomLeft
2049
- ]);
2050
- const LEFT_TOP_POSITION_PRIORITY = objectValues([
2051
- POSITION_MAP.leftTop,
2052
- POSITION_MAP.rightTop,
2053
- POSITION_MAP.right,
2054
- POSITION_MAP.rightBottom,
2055
- POSITION_MAP.topRight,
2056
- POSITION_MAP.bottomRight
2057
- ]);
2058
- const LEFT_BOTTOM_POSITION_PRIORITY = objectValues([
2059
- POSITION_MAP.leftBottom,
2060
- POSITION_MAP.rightBottom,
2061
- POSITION_MAP.right,
2062
- POSITION_MAP.rightTop,
2063
- POSITION_MAP.topRight,
2064
- POSITION_MAP.bottomRight
2065
- ]);
2066
- const TOP_LEFT_POSITION_PRIORITY = objectValues([
2067
- POSITION_MAP.topLeft,
2068
- POSITION_MAP.topRight,
2069
- POSITION_MAP.bottomLeft,
2070
- POSITION_MAP.bottom,
2071
- POSITION_MAP.bottomRight,
2072
- POSITION_MAP.leftBottom,
2073
- POSITION_MAP.rightBottom
2074
- ]);
2075
- const TOP_RIGHT_POSITION_PRIORITY = objectValues([
2076
- POSITION_MAP.topRight,
2077
- POSITION_MAP.topLeft,
2078
- POSITION_MAP.bottomRight,
2079
- POSITION_MAP.bottom,
2080
- POSITION_MAP.bottomLeft,
2081
- POSITION_MAP.leftBottom,
2082
- POSITION_MAP.rightBottom
2083
- ]);
2084
- const BOTTOM_RIGHT_POSITION_PRIORITY = objectValues([
2085
- POSITION_MAP.bottomRight,
2086
- POSITION_MAP.bottomLeft,
2087
- POSITION_MAP.topRight,
2088
- POSITION_MAP.top,
2089
- POSITION_MAP.topLeft,
2090
- POSITION_MAP.leftTop,
2091
- POSITION_MAP.rightTop
2092
- ]);
2093
- const BOTTOM_LEFT_POSITION_PRIORITY = objectValues([
2094
- POSITION_MAP.bottomLeft,
2095
- POSITION_MAP.bottomRight,
2096
- POSITION_MAP.topLeft,
2097
- POSITION_MAP.top,
2098
- POSITION_MAP.topRight,
2099
- POSITION_MAP.rightTop,
2100
- POSITION_MAP.leftTop
2101
- ]);
2102
- const POSITION_PRIORITY_STRATEGY = {
2103
- top: TOP_POSITION_PRIORITY,
2104
- topLeft: TOP_LEFT_POSITION_PRIORITY,
2105
- topRight: TOP_RIGHT_POSITION_PRIORITY,
2106
- bottom: BOTTOM_POSITION_PRIORITY,
2107
- bottomLeft: BOTTOM_LEFT_POSITION_PRIORITY,
2108
- bottomRight: BOTTOM_RIGHT_POSITION_PRIORITY,
2109
- left: LEFT_POSITION_PRIORITY,
2110
- leftTop: LEFT_TOP_POSITION_PRIORITY,
2111
- leftBottom: LEFT_BOTTOM_POSITION_PRIORITY,
2112
- right: RIGHT_POSITION_PRIORITY,
2113
- rightTop: RIGHT_TOP_POSITION_PRIORITY,
2114
- rightBottom: RIGHT_BOTTOM_POSITION_PRIORITY
2115
- };
2116
- const POSITION_TO_CSS_MAP = {
2117
- top: 'top',
2118
- topLeft: 'top-left',
2119
- topRight: 'top-right',
2120
- right: 'right',
2121
- rightTop: 'right-top',
2122
- rightBottom: 'right-bottom',
2123
- left: 'left',
2124
- leftTop: 'left-top',
2125
- leftBottom: 'left-bottom',
2126
- bottom: 'bottom',
2127
- bottomLeft: 'bottom-left',
2128
- bottomRight: 'bottom-right'
2129
- };
2130
- function arrayMap(array, iteratee) {
2131
- let index = -1;
2132
- const length = array === null ? 0 : array.length;
2133
- const result = Array(length);
2134
- while (++index < length) {
2135
- result[index] = iteratee(array[index], index, array);
859
+ setLineClass(count) {
860
+ const minLineClassNumber = 2;
861
+ const maxLineClassNumber = 3;
862
+ this.resetClasses();
863
+ if (count === minLineClassNumber || count === maxLineClassNumber) {
864
+ this.setClass(`mc-${count}-line`, true);
865
+ }
866
+ else if (count > maxLineClassNumber) {
867
+ this.setClass(`mc-multi-line`, true);
868
+ }
869
+ }
870
+ resetClasses() {
871
+ this.setClass('mc-2-line', false);
872
+ this.setClass('mc-3-line', false);
873
+ this.setClass('mc-multi-line', false);
874
+ }
875
+ setClass(className, isAdd) {
876
+ if (isAdd) {
877
+ this._element.nativeElement.classList.add(className);
878
+ }
879
+ else {
880
+ this._element.nativeElement.classList.remove(className);
881
+ }
2136
882
  }
2137
- return result;
2138
- }
2139
- function baseValues(object, props) {
2140
- return arrayMap(props, (key) => object[key]);
2141
883
  }
2142
- function objectValues(object) {
2143
- return object === null ? [] : baseValues(object, Object.keys(object));
884
+ class McLineModule {
2144
885
  }
886
+ /** @nocollapse */ McLineModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McLineModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
887
+ /** @nocollapse */ McLineModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McLineModule, declarations: [McLine], exports: [McLine] });
888
+ /** @nocollapse */ McLineModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McLineModule });
889
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McLineModule, decorators: [{
890
+ type: NgModule,
891
+ args: [{
892
+ imports: [],
893
+ exports: [McLine],
894
+ declarations: [McLine]
895
+ }]
896
+ }] });
2145
897
 
2146
- const fadeAnimation = trigger('fadeAnimation', [
2147
- state('void', style({ opacity: 0 })),
2148
- state('true', style({ opacity: 1 })),
2149
- state('false', style({ opacity: 0 })),
2150
- transition('* => true', animate('150ms cubic-bezier(0.0, 0.0, 0.2, 1)')),
2151
- transition('* => void', animate('150ms cubic-bezier(0.4, 0.0, 1, 1)'))
2152
- ]);
2153
-
2154
- var AnimationCurves;
2155
- (function (AnimationCurves) {
2156
- AnimationCurves["StandardCurve"] = "cubic-bezier(0.4,0.0,0.2,1)";
2157
- AnimationCurves["DecelerationCurve"] = "cubic-bezier(0.0,0.0,0.2,1)";
2158
- AnimationCurves["AccelerationCurve"] = "cubic-bezier(0.4,0.0,1,1)";
2159
- AnimationCurves["SharpCurve"] = "cubic-bezier(0.4,0.0,0.6,1)";
2160
- })(AnimationCurves || (AnimationCurves = {}));
2161
-
898
+ /** @docs-private */
899
+ class McOptgroupBase {
900
+ }
901
+ // tslint:disable-next-line: naming-convention
902
+ const McOptgroupMixinBase = mixinDisabled(McOptgroupBase);
903
+ let uniqueOptgroupIdCounter = 0;
2162
904
  /**
2163
- * The following are all the animations for the mc-select component, with each
2164
- * const containing the metadata for one animation.
2165
- *
905
+ * Component that is used to group instances of `mc-option`.
2166
906
  */
2167
- const mcSelectAnimations = {
2168
- /**
2169
- * This animation transforms the select's overlay panel on and off the page.
2170
- *
2171
- * When the panel is attached to the DOM, it expands its width by the amount of padding, scales it
2172
- * up to 100% on the Y axis, fades in its border, and translates slightly up and to the
2173
- * side to ensure the option text correctly overlaps the trigger text.
2174
- *
2175
- * When the panel is removed from the DOM, it simply fades out linearly.
2176
- */
2177
- transformPanel: trigger('transformPanel', [
2178
- state('void', style({
2179
- transform: 'scaleY(0)',
2180
- minWidth: '100%',
2181
- opacity: 0
2182
- })),
2183
- transition('void => *', group([
2184
- animate('150ms cubic-bezier(0.25, 0.8, 0.25, 1)')
2185
- ])),
2186
- transition('* => void', [
2187
- animate('250ms 100ms linear', style({ opacity: 0 }))
2188
- ])
2189
- ]),
2190
- /**
2191
- * This animation fades in the background color and text content of the
2192
- * select's options. It is time delayed to occur 100ms after the overlay
2193
- * panel has transformed in.
2194
- */
2195
- fadeInContent: trigger('fadeInContent', [
2196
- state('showing', style({ opacity: 1 })),
2197
- transition('void => showing', [
2198
- style({ opacity: 0 }),
2199
- animate('150ms 100ms cubic-bezier(0.55, 0, 0.55, 0.2)')
2200
- ])
2201
- ])
2202
- };
2203
- const transformPanel = mcSelectAnimations.transformPanel;
2204
- const fadeInContent = mcSelectAnimations.fadeInContent;
2205
-
2206
- /** InjectionToken that can be used to specify the global label options. */
2207
- const MC_LABEL_GLOBAL_OPTIONS = new InjectionToken('mc-label-global-options');
2208
-
2209
- var MultipleMode;
2210
- (function (MultipleMode) {
2211
- MultipleMode["CHECKBOX"] = "checkbox";
2212
- MultipleMode["KEYBOARD"] = "keyboard";
2213
- })(MultipleMode || (MultipleMode = {}));
907
+ class McOptgroup extends McOptgroupMixinBase {
908
+ constructor() {
909
+ super(...arguments);
910
+ /** Unique id for the underlying label. */
911
+ this.labelId = `mc-optgroup-label-${uniqueOptgroupIdCounter++}`;
912
+ }
913
+ }
914
+ /** @nocollapse */ McOptgroup.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOptgroup, deps: null, target: i0.ɵɵFactoryTarget.Component });
915
+ /** @nocollapse */ McOptgroup.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: McOptgroup, selector: "mc-optgroup", inputs: { disabled: "disabled", label: "label" }, host: { properties: { "class.mc-disabled": "disabled" }, classAttribute: "mc-optgroup" }, exportAs: ["mcOptgroup"], usesInheritance: true, ngImport: i0, template: "<label class=\"mc-optgroup-label\" [id]=\"labelId\">{{ label }}</label>\n<ng-content select=\"mc-option, mc-list-option, mc-timezone-option, ng-container\"></ng-content>\n", styles: [".mc-optgroup-label{padding-left:var(--mc-optgroup-size-padding-left, 17px);-webkit-user-select:none;user-select:none;cursor:default}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
916
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOptgroup, decorators: [{
917
+ type: Component,
918
+ args: [{ selector: 'mc-optgroup', exportAs: 'mcOptgroup', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, inputs: ['disabled'], host: {
919
+ class: 'mc-optgroup',
920
+ '[class.mc-disabled]': 'disabled'
921
+ }, template: "<label class=\"mc-optgroup-label\" [id]=\"labelId\">{{ label }}</label>\n<ng-content select=\"mc-option, mc-list-option, mc-timezone-option, ng-container\"></ng-content>\n", styles: [".mc-optgroup-label{padding-left:var(--mc-optgroup-size-padding-left, 17px);-webkit-user-select:none;user-select:none;cursor:default}\n"] }]
922
+ }], propDecorators: { label: [{
923
+ type: Input
924
+ }] } });
2214
925
 
2215
926
  // Boilerplate for applying mixins to McPseudoCheckbox.
2216
927
  /** @docs-private */
@@ -2241,111 +952,22 @@ class McPseudoCheckbox extends McPseudoCheckboxMixinBase {
2241
952
  this.disabled = false;
2242
953
  }
2243
954
  }
2244
- /** @nocollapse */ McPseudoCheckbox.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPseudoCheckbox, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
2245
- /** @nocollapse */ McPseudoCheckbox.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: McPseudoCheckbox, selector: "mc-pseudo-checkbox", inputs: { color: "color", state: "state", disabled: "disabled" }, host: { properties: { "class.mc-indeterminate": "state === \"indeterminate\"", "class.mc-checked": "state === \"checked\"", "class.mc-disabled": "disabled" }, classAttribute: "mc-pseudo-checkbox" }, usesInheritance: true, ngImport: i0, template: "<i class=\"mc-checkbox-checkmark mc mc-check_16\"></i>\n<i class=\"mc-checkbox-mixedmark mc mc-minus_16\"></i>\n", styles: [".mc-pseudo-checkbox{position:relative;display:inline-block;box-sizing:border-box;width:16px;width:var(--mc-checkbox-size-width, 16px);height:16px;height:var(--mc-checkbox-size-width, 16px);border-radius:3px;border-width:1px;border-width:var(--mc-checkbox-size-border-width, 1px);border-style:solid;cursor:pointer;vertical-align:middle;flex-shrink:0}.mc-pseudo-checkbox .mc-checkbox-checkmark,.mc-pseudo-checkbox .mc-checkbox-mixedmark{display:none;position:absolute;top:-1px;top:calc(-1 * var(--mc-checkbox-size-border-width, 1px));left:-1px;left:calc(-1 * var(--mc-checkbox-size-border-width, 1px))}.mc-pseudo-checkbox.mc-pseudo-checkbox-checked,.mc-pseudo-checkbox.mc-pseudo-checkbox-indeterminate{border-color:transparent}.mc-pseudo-checkbox.mc-checked .mc-checkbox-checkmark,.mc-pseudo-checkbox.mc-indeterminate .mc-checkbox-mixedmark{display:inline-block}.mc-pseudo-checkbox.mc-disabled{cursor:default}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
2246
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPseudoCheckbox, decorators: [{
955
+ /** @nocollapse */ McPseudoCheckbox.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPseudoCheckbox, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
956
+ /** @nocollapse */ McPseudoCheckbox.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: McPseudoCheckbox, selector: "mc-pseudo-checkbox", inputs: { color: "color", state: "state", disabled: "disabled" }, host: { properties: { "class.mc-indeterminate": "state === \"indeterminate\"", "class.mc-checked": "state === \"checked\"", "class.mc-disabled": "disabled" }, classAttribute: "mc-pseudo-checkbox" }, usesInheritance: true, ngImport: i0, template: "<i class=\"mc-checkbox-checkmark mc mc-check_16\"></i>\n<i class=\"mc-checkbox-mixedmark mc mc-minus_16\"></i>\n", styles: [".mc-pseudo-checkbox{position:relative;display:inline-block;box-sizing:border-box;width:var(--mc-checkbox-size-width, 16px);height:var(--mc-checkbox-size-width, 16px);border-radius:3px;border-width:var(--mc-checkbox-size-border-width, 1px);border-style:solid;cursor:pointer;vertical-align:middle;flex-shrink:0}.mc-pseudo-checkbox .mc-checkbox-checkmark,.mc-pseudo-checkbox .mc-checkbox-mixedmark{display:none;position:absolute;top:calc(-1 * var(--mc-checkbox-size-border-width, 1px));left:calc(-1 * var(--mc-checkbox-size-border-width, 1px))}.mc-pseudo-checkbox.mc-pseudo-checkbox-checked,.mc-pseudo-checkbox.mc-pseudo-checkbox-indeterminate{border-color:transparent}.mc-pseudo-checkbox.mc-checked .mc-checkbox-checkmark,.mc-pseudo-checkbox.mc-indeterminate .mc-checkbox-mixedmark{display:inline-block}.mc-pseudo-checkbox.mc-disabled{cursor:default}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
957
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPseudoCheckbox, decorators: [{
2247
958
  type: Component,
2248
959
  args: [{ selector: 'mc-pseudo-checkbox', host: {
2249
960
  class: 'mc-pseudo-checkbox',
2250
961
  '[class.mc-indeterminate]': 'state === "indeterminate"',
2251
962
  '[class.mc-checked]': 'state === "checked"',
2252
963
  '[class.mc-disabled]': 'disabled'
2253
- }, preserveWhitespaces: false, inputs: ['color'], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<i class=\"mc-checkbox-checkmark mc mc-check_16\"></i>\n<i class=\"mc-checkbox-mixedmark mc mc-minus_16\"></i>\n", styles: [".mc-pseudo-checkbox{position:relative;display:inline-block;box-sizing:border-box;width:16px;width:var(--mc-checkbox-size-width, 16px);height:16px;height:var(--mc-checkbox-size-width, 16px);border-radius:3px;border-width:1px;border-width:var(--mc-checkbox-size-border-width, 1px);border-style:solid;cursor:pointer;vertical-align:middle;flex-shrink:0}.mc-pseudo-checkbox .mc-checkbox-checkmark,.mc-pseudo-checkbox .mc-checkbox-mixedmark{display:none;position:absolute;top:-1px;top:calc(-1 * var(--mc-checkbox-size-border-width, 1px));left:-1px;left:calc(-1 * var(--mc-checkbox-size-border-width, 1px))}.mc-pseudo-checkbox.mc-pseudo-checkbox-checked,.mc-pseudo-checkbox.mc-pseudo-checkbox-indeterminate{border-color:transparent}.mc-pseudo-checkbox.mc-checked .mc-checkbox-checkmark,.mc-pseudo-checkbox.mc-indeterminate .mc-checkbox-mixedmark{display:inline-block}.mc-pseudo-checkbox.mc-disabled{cursor:default}\n"] }]
964
+ }, preserveWhitespaces: false, inputs: ['color'], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, template: "<i class=\"mc-checkbox-checkmark mc mc-check_16\"></i>\n<i class=\"mc-checkbox-mixedmark mc mc-minus_16\"></i>\n", styles: [".mc-pseudo-checkbox{position:relative;display:inline-block;box-sizing:border-box;width:var(--mc-checkbox-size-width, 16px);height:var(--mc-checkbox-size-width, 16px);border-radius:3px;border-width:var(--mc-checkbox-size-border-width, 1px);border-style:solid;cursor:pointer;vertical-align:middle;flex-shrink:0}.mc-pseudo-checkbox .mc-checkbox-checkmark,.mc-pseudo-checkbox .mc-checkbox-mixedmark{display:none;position:absolute;top:calc(-1 * var(--mc-checkbox-size-border-width, 1px));left:calc(-1 * var(--mc-checkbox-size-border-width, 1px))}.mc-pseudo-checkbox.mc-pseudo-checkbox-checked,.mc-pseudo-checkbox.mc-pseudo-checkbox-indeterminate{border-color:transparent}.mc-pseudo-checkbox.mc-checked .mc-checkbox-checkmark,.mc-pseudo-checkbox.mc-indeterminate .mc-checkbox-mixedmark{display:inline-block}.mc-pseudo-checkbox.mc-disabled{cursor:default}\n"] }]
2254
965
  }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { state: [{
2255
966
  type: Input
2256
967
  }], disabled: [{
2257
968
  type: Input
2258
969
  }] } });
2259
970
 
2260
- class McPseudoCheckboxModule {
2261
- }
2262
- /** @nocollapse */ McPseudoCheckboxModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPseudoCheckboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2263
- /** @nocollapse */ McPseudoCheckboxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McPseudoCheckboxModule, declarations: [McPseudoCheckbox], imports: [CommonModule], exports: [McPseudoCheckbox] });
2264
- /** @nocollapse */ McPseudoCheckboxModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPseudoCheckboxModule, imports: [CommonModule] });
2265
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPseudoCheckboxModule, decorators: [{
2266
- type: NgModule,
2267
- args: [{
2268
- imports: [CommonModule],
2269
- exports: [McPseudoCheckbox],
2270
- declarations: [McPseudoCheckbox]
2271
- }]
2272
- }] });
2273
-
2274
- class McMeasureScrollbarService {
2275
- constructor(document) {
2276
- this.document = document;
2277
- this.scrollbarMeasure = {
2278
- position: 'absolute',
2279
- top: '-9999px',
2280
- width: '50px',
2281
- height: '50px',
2282
- overflow: 'scroll'
2283
- };
2284
- this.initScrollBarWidth();
2285
- }
2286
- get scrollBarWidth() {
2287
- if (this._scrollBarWidth) {
2288
- return this._scrollBarWidth;
2289
- }
2290
- this.initScrollBarWidth();
2291
- return this._scrollBarWidth;
2292
- }
2293
- initScrollBarWidth() {
2294
- const scrollDiv = this.document.createElement('div');
2295
- // tslint:disable-next-line
2296
- for (const scrollProp in this.scrollbarMeasure) {
2297
- if (this.scrollbarMeasure.hasOwnProperty(scrollProp)) {
2298
- scrollDiv.style[scrollProp] = this.scrollbarMeasure[scrollProp];
2299
- }
2300
- }
2301
- this.document.body.appendChild(scrollDiv);
2302
- const width = scrollDiv.offsetWidth - scrollDiv.clientWidth;
2303
- this.document.body.removeChild(scrollDiv);
2304
- this._scrollBarWidth = width;
2305
- }
2306
- }
2307
- /** @nocollapse */ McMeasureScrollbarService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McMeasureScrollbarService, deps: [{ token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
2308
- /** @nocollapse */ McMeasureScrollbarService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McMeasureScrollbarService, providedIn: 'root' });
2309
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McMeasureScrollbarService, decorators: [{
2310
- type: Injectable,
2311
- args: [{
2312
- providedIn: 'root'
2313
- }]
2314
- }], ctorParameters: function () {
2315
- return [{ type: undefined, decorators: [{
2316
- type: Inject,
2317
- args: [DOCUMENT]
2318
- }] }];
2319
- } });
2320
-
2321
- /** @docs-private */
2322
- class McOptgroupBase {
2323
- }
2324
- // tslint:disable-next-line: naming-convention
2325
- const McOptgroupMixinBase = mixinDisabled(McOptgroupBase);
2326
- let uniqueOptgroupIdCounter = 0;
2327
- /**
2328
- * Component that is used to group instances of `mc-option`.
2329
- */
2330
- class McOptgroup extends McOptgroupMixinBase {
2331
- constructor() {
2332
- super(...arguments);
2333
- /** Unique id for the underlying label. */
2334
- this.labelId = `mc-optgroup-label-${uniqueOptgroupIdCounter++}`;
2335
- }
2336
- }
2337
- /** @nocollapse */ McOptgroup.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOptgroup, deps: null, target: i0.ɵɵFactoryTarget.Component });
2338
- /** @nocollapse */ McOptgroup.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: McOptgroup, selector: "mc-optgroup", inputs: { disabled: "disabled", label: "label" }, host: { properties: { "class.mc-disabled": "disabled" }, classAttribute: "mc-optgroup" }, exportAs: ["mcOptgroup"], usesInheritance: true, ngImport: i0, template: "<label class=\"mc-optgroup-label\" [id]=\"labelId\">{{ label }}</label>\n<ng-content select=\"mc-option, mc-list-option, mc-timezone-option, ng-container\"></ng-content>\n", styles: [".mc-optgroup-label{padding-left:17px;padding-left:var(--mc-optgroup-size-padding-left, 17px);-webkit-user-select:none;user-select:none;cursor:default}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
2339
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOptgroup, decorators: [{
2340
- type: Component,
2341
- args: [{ selector: 'mc-optgroup', exportAs: 'mcOptgroup', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, inputs: ['disabled'], host: {
2342
- class: 'mc-optgroup',
2343
- '[class.mc-disabled]': 'disabled'
2344
- }, template: "<label class=\"mc-optgroup-label\" [id]=\"labelId\">{{ label }}</label>\n<ng-content select=\"mc-option, mc-list-option, mc-timezone-option, ng-container\"></ng-content>\n", styles: [".mc-optgroup-label{padding-left:17px;padding-left:var(--mc-optgroup-size-padding-left, 17px);-webkit-user-select:none;user-select:none;cursor:default}\n"] }]
2345
- }], propDecorators: { label: [{
2346
- type: Input
2347
- }] } });
2348
-
2349
971
  /**
2350
972
  * Option IDs need to be unique across components, so this counter exists outside of
2351
973
  * the component definition.
@@ -2520,9 +1142,9 @@ class McOption {
2520
1142
  this.onSelectionChange.emit(new McOptionSelectionChange(this, isUserInput));
2521
1143
  }
2522
1144
  }
2523
- /** @nocollapse */ McOption.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOption, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: MC_OPTION_PARENT_COMPONENT, optional: true }, { token: McOptgroup, optional: true }], target: i0.ɵɵFactoryTarget.Component });
2524
- /** @nocollapse */ McOption.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: McOption, selector: "mc-option", inputs: { value: "value", showCheckbox: "showCheckbox", disabled: "disabled" }, outputs: { onSelectionChange: "onSelectionChange" }, host: { listeners: { "click": "selectViaInteraction()", "keydown": "handleKeydown($event)" }, properties: { "attr.tabindex": "getTabIndex()", "class.mc-selected": "selected", "class.mc-option-multiple": "multiple", "class.mc-active": "active", "class.mc-disabled": "disabled", "id": "id" }, classAttribute: "mc-option" }, viewQueries: [{ propertyName: "textElement", first: true, predicate: ["mcTextElement"], descendants: true }], exportAs: ["mcOption"], ngImport: i0, template: "<mc-pseudo-checkbox\n *ngIf=\"showCheckbox\"\n [state]=\"selected ? 'checked' : 'unchecked'\"\n [disabled]=\"disabled\">\n</mc-pseudo-checkbox>\n\n<span #mcTextElement class=\"mc-option-text\"><ng-content></ng-content></span>\n\n<div class=\"mc-option-overlay\"></div>\n", styles: [".mc-option{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;position:relative;max-width:100%;height:32px;height:var(--mc-option-size-height, 32px);border:2px solid transparent;border:var(--mc-option-size-border-width, 2px) solid transparent;cursor:pointer;outline:none;padding-left:12px;padding-left:var(--mc-option-size-horizontal-padding, 12px);padding-right:12px;padding-right:var(--mc-option-size-horizontal-padding, 12px);-webkit-tap-highlight-color:transparent}.mc-option.mc-disabled{cursor:default}.mc-option .mc-pseudo-checkbox{margin-right:8px}.mc-option .mc-option-overlay{position:absolute;top:-2px;top:calc(-1 * var(--mc-option-size-border-width, 2px));left:-2px;left:calc(-1 * var(--mc-option-size-border-width, 2px));right:-2px;right:calc(-1 * var(--mc-option-size-border-width, 2px));bottom:-2px;bottom:calc(-1 * var(--mc-option-size-border-width, 2px));pointer-events:none;border-radius:inherit}.mc-option-text{display:inline-block;flex-grow:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: McPseudoCheckbox, selector: "mc-pseudo-checkbox", inputs: ["color", "state", "disabled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
2525
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOption, decorators: [{
1145
+ /** @nocollapse */ McOption.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOption, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: MC_OPTION_PARENT_COMPONENT, optional: true }, { token: McOptgroup, optional: true }], target: i0.ɵɵFactoryTarget.Component });
1146
+ /** @nocollapse */ McOption.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: McOption, selector: "mc-option", inputs: { value: "value", showCheckbox: "showCheckbox", disabled: "disabled" }, outputs: { onSelectionChange: "onSelectionChange" }, host: { listeners: { "click": "selectViaInteraction()", "keydown": "handleKeydown($event)" }, properties: { "attr.tabindex": "getTabIndex()", "class.mc-selected": "selected", "class.mc-option-multiple": "multiple", "class.mc-active": "active", "class.mc-disabled": "disabled", "id": "id" }, classAttribute: "mc-option" }, viewQueries: [{ propertyName: "textElement", first: true, predicate: ["mcTextElement"], descendants: true }], exportAs: ["mcOption"], ngImport: i0, template: "<mc-pseudo-checkbox\n *ngIf=\"showCheckbox\"\n [state]=\"selected ? 'checked' : 'unchecked'\"\n [disabled]=\"disabled\">\n</mc-pseudo-checkbox>\n\n<span #mcTextElement class=\"mc-option-text\"><ng-content></ng-content></span>\n\n<div class=\"mc-option-overlay\"></div>\n", styles: [".mc-option{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;position:relative;max-width:100%;height:var(--mc-option-size-height, 32px);border:var(--mc-option-size-border-width, 2px) solid transparent;cursor:pointer;outline:none;padding-left:var(--mc-option-size-horizontal-padding, 12px);padding-right:var(--mc-option-size-horizontal-padding, 12px);-webkit-tap-highlight-color:transparent}.mc-option.mc-disabled{cursor:default}.mc-option .mc-pseudo-checkbox{margin-right:8px}.mc-option .mc-option-overlay{position:absolute;top:calc(-1 * var(--mc-option-size-border-width, 2px));left:calc(-1 * var(--mc-option-size-border-width, 2px));right:calc(-1 * var(--mc-option-size-border-width, 2px));bottom:calc(-1 * var(--mc-option-size-border-width, 2px));pointer-events:none;border-radius:inherit}.mc-option-text{display:inline-block;flex-grow:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: McPseudoCheckbox, selector: "mc-pseudo-checkbox", inputs: ["color", "state", "disabled"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
1147
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOption, decorators: [{
2526
1148
  type: Component,
2527
1149
  args: [{ selector: 'mc-option', exportAs: 'mcOption', host: {
2528
1150
  '[attr.tabindex]': 'getTabIndex()',
@@ -2534,7 +1156,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
2534
1156
  '[id]': 'id',
2535
1157
  '(click)': 'selectViaInteraction()',
2536
1158
  '(keydown)': 'handleKeydown($event)'
2537
- }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<mc-pseudo-checkbox\n *ngIf=\"showCheckbox\"\n [state]=\"selected ? 'checked' : 'unchecked'\"\n [disabled]=\"disabled\">\n</mc-pseudo-checkbox>\n\n<span #mcTextElement class=\"mc-option-text\"><ng-content></ng-content></span>\n\n<div class=\"mc-option-overlay\"></div>\n", styles: [".mc-option{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;position:relative;max-width:100%;height:32px;height:var(--mc-option-size-height, 32px);border:2px solid transparent;border:var(--mc-option-size-border-width, 2px) solid transparent;cursor:pointer;outline:none;padding-left:12px;padding-left:var(--mc-option-size-horizontal-padding, 12px);padding-right:12px;padding-right:var(--mc-option-size-horizontal-padding, 12px);-webkit-tap-highlight-color:transparent}.mc-option.mc-disabled{cursor:default}.mc-option .mc-pseudo-checkbox{margin-right:8px}.mc-option .mc-option-overlay{position:absolute;top:-2px;top:calc(-1 * var(--mc-option-size-border-width, 2px));left:-2px;left:calc(-1 * var(--mc-option-size-border-width, 2px));right:-2px;right:calc(-1 * var(--mc-option-size-border-width, 2px));bottom:-2px;bottom:calc(-1 * var(--mc-option-size-border-width, 2px));pointer-events:none;border-radius:inherit}.mc-option-text{display:inline-block;flex-grow:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"] }]
1159
+ }, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<mc-pseudo-checkbox\n *ngIf=\"showCheckbox\"\n [state]=\"selected ? 'checked' : 'unchecked'\"\n [disabled]=\"disabled\">\n</mc-pseudo-checkbox>\n\n<span #mcTextElement class=\"mc-option-text\"><ng-content></ng-content></span>\n\n<div class=\"mc-option-overlay\"></div>\n", styles: [".mc-option{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;position:relative;max-width:100%;height:var(--mc-option-size-height, 32px);border:var(--mc-option-size-border-width, 2px) solid transparent;cursor:pointer;outline:none;padding-left:var(--mc-option-size-horizontal-padding, 12px);padding-right:var(--mc-option-size-horizontal-padding, 12px);-webkit-tap-highlight-color:transparent}.mc-option.mc-disabled{cursor:default}.mc-option .mc-pseudo-checkbox{margin-right:8px}.mc-option .mc-option-overlay{position:absolute;top:calc(-1 * var(--mc-option-size-border-width, 2px));left:calc(-1 * var(--mc-option-size-border-width, 2px));right:calc(-1 * var(--mc-option-size-border-width, 2px));bottom:calc(-1 * var(--mc-option-size-border-width, 2px));pointer-events:none;border-radius:inherit}.mc-option-text{display:inline-block;flex-grow:1;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}\n"] }]
2538
1160
  }], ctorParameters: function () {
2539
1161
  return [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: undefined, decorators: [{
2540
1162
  type: Optional
@@ -2678,14 +1300,14 @@ class McOptionActionComponent extends McOptionActionMixinBase {
2678
1300
  setTimeout(() => this.option.tooltipTrigger.disabled = false);
2679
1301
  }
2680
1302
  }
2681
- /** @nocollapse */ McOptionActionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOptionActionComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.FocusMonitor }, { token: MC_OPTION_ACTION_PARENT }], target: i0.ɵɵFactoryTarget.Component });
2682
- /** @nocollapse */ McOptionActionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.12", type: McOptionActionComponent, selector: "mc-option-action", inputs: { disabled: "disabled" }, host: { listeners: { "focus": "onFocus($event)", "blur": "onBlur()", "click": "onClick($event)", "keydown": "onKeyDown($event)" }, properties: { "class.mc-expanded": "false", "attr.disabled": "disabled || null", "attr.tabIndex": "-1" }, classAttribute: "mc-option-action" }, queries: [{ propertyName: "customIcon", first: true, predicate: ["customIcon"], descendants: true }], exportAs: ["mcOptionAction"], usesInheritance: true, ngImport: i0, template: `
1303
+ /** @nocollapse */ McOptionActionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOptionActionComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.FocusMonitor }, { token: MC_OPTION_ACTION_PARENT }], target: i0.ɵɵFactoryTarget.Component });
1304
+ /** @nocollapse */ McOptionActionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.2", type: McOptionActionComponent, selector: "mc-option-action", inputs: { disabled: "disabled" }, host: { listeners: { "focus": "onFocus($event)", "blur": "onBlur()", "click": "onClick($event)", "keydown": "onKeyDown($event)" }, properties: { "class.mc-expanded": "false", "attr.disabled": "disabled || null", "attr.tabIndex": "-1" }, classAttribute: "mc-option-action" }, queries: [{ propertyName: "customIcon", first: true, predicate: ["customIcon"], descendants: true }], exportAs: ["mcOptionAction"], usesInheritance: true, ngImport: i0, template: `
2683
1305
  <ng-container [ngSwitch]="!!customIcon">
2684
1306
  <i class="mc mc-icon mc-ellipsis_16" *ngSwitchCase="false"></i>
2685
1307
  <ng-content select="[mc-icon]" *ngSwitchCase="true"></ng-content>
2686
1308
  </ng-container>
2687
- `, isInline: true, styles: [".mc-option-action{box-sizing:content-box;box-sizing:initial;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:28px;height:100%;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.mc-option-action[disabled]{cursor:default}\n"], dependencies: [{ kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
2688
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOptionActionComponent, decorators: [{
1309
+ `, isInline: true, styles: [".mc-option-action{box-sizing:unset;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:28px;height:100%;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.mc-option-action[disabled]{cursor:default}\n"], dependencies: [{ kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
1310
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOptionActionComponent, decorators: [{
2689
1311
  type: Component,
2690
1312
  args: [{ selector: 'mc-option-action', exportAs: 'mcOptionAction', template: `
2691
1313
  <ng-container [ngSwitch]="!!customIcon">
@@ -2701,7 +1323,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
2701
1323
  '(blur)': 'onBlur()',
2702
1324
  '(click)': 'onClick($event)',
2703
1325
  '(keydown)': 'onKeyDown($event)'
2704
- }, inputs: ['disabled'], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".mc-option-action{box-sizing:content-box;box-sizing:initial;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:28px;height:100%;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.mc-option-action[disabled]{cursor:default}\n"] }]
1326
+ }, inputs: ['disabled'], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".mc-option-action{box-sizing:unset;position:relative;display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:-2px;width:28px;height:100%;cursor:pointer;outline:none;border:2px solid transparent;background:transparent}.mc-option-action[disabled]{cursor:default}\n"] }]
2705
1327
  }], ctorParameters: function () {
2706
1328
  return [{ type: i0.ElementRef }, { type: i1$1.FocusMonitor }, { type: undefined, decorators: [{
2707
1329
  type: Inject,
@@ -2712,12 +1334,32 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
2712
1334
  args: ['customIcon']
2713
1335
  }] } });
2714
1336
 
1337
+ var MultipleMode;
1338
+ (function (MultipleMode) {
1339
+ MultipleMode["CHECKBOX"] = "checkbox";
1340
+ MultipleMode["KEYBOARD"] = "keyboard";
1341
+ })(MultipleMode || (MultipleMode = {}));
1342
+
1343
+ class McPseudoCheckboxModule {
1344
+ }
1345
+ /** @nocollapse */ McPseudoCheckboxModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPseudoCheckboxModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1346
+ /** @nocollapse */ McPseudoCheckboxModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McPseudoCheckboxModule, declarations: [McPseudoCheckbox], imports: [CommonModule], exports: [McPseudoCheckbox] });
1347
+ /** @nocollapse */ McPseudoCheckboxModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPseudoCheckboxModule, imports: [CommonModule] });
1348
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPseudoCheckboxModule, decorators: [{
1349
+ type: NgModule,
1350
+ args: [{
1351
+ imports: [CommonModule],
1352
+ exports: [McPseudoCheckbox],
1353
+ declarations: [McPseudoCheckbox]
1354
+ }]
1355
+ }] });
1356
+
2715
1357
  class McOptionModule {
2716
1358
  }
2717
- /** @nocollapse */ McOptionModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOptionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2718
- /** @nocollapse */ McOptionModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McOptionModule, declarations: [McOption, McOptgroup, McOptionActionComponent], imports: [CommonModule, McPseudoCheckboxModule], exports: [McOption, McOptgroup, McOptionActionComponent] });
2719
- /** @nocollapse */ McOptionModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOptionModule, imports: [CommonModule, McPseudoCheckboxModule] });
2720
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McOptionModule, decorators: [{
1359
+ /** @nocollapse */ McOptionModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOptionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1360
+ /** @nocollapse */ McOptionModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.2", ngImport: i0, type: McOptionModule, declarations: [McOption, McOptgroup, McOptionActionComponent], imports: [CommonModule, McPseudoCheckboxModule], exports: [McOption, McOptgroup, McOptionActionComponent] });
1361
+ /** @nocollapse */ McOptionModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOptionModule, imports: [CommonModule, McPseudoCheckboxModule] });
1362
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McOptionModule, decorators: [{
2721
1363
  type: NgModule,
2722
1364
  args: [{
2723
1365
  imports: [CommonModule, McPseudoCheckboxModule],
@@ -2726,90 +1368,249 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImpo
2726
1368
  }]
2727
1369
  }] });
2728
1370
 
2729
- class McFormElement {
2730
- constructor(element) {
2731
- this.element = element;
2732
- this.margin = false;
2733
- this.isRow = false;
2734
- this.isFieldSet = false;
2735
- this.hasLegend = false;
2736
- this.isHorizontal = false;
1371
+ const POSITION_MAP = {
1372
+ top: {
1373
+ originX: 'center',
1374
+ originY: 'top',
1375
+ overlayX: 'center',
1376
+ overlayY: 'bottom'
1377
+ },
1378
+ topCenter: {
1379
+ originX: 'center',
1380
+ originY: 'top',
1381
+ overlayX: 'center',
1382
+ overlayY: 'bottom'
1383
+ },
1384
+ topLeft: {
1385
+ originX: 'start',
1386
+ originY: 'top',
1387
+ overlayX: 'start',
1388
+ overlayY: 'bottom'
1389
+ },
1390
+ topRight: {
1391
+ originX: 'end',
1392
+ originY: 'top',
1393
+ overlayX: 'end',
1394
+ overlayY: 'bottom'
1395
+ },
1396
+ right: {
1397
+ originX: 'end',
1398
+ originY: 'center',
1399
+ overlayX: 'start',
1400
+ overlayY: 'center'
1401
+ },
1402
+ rightTop: {
1403
+ originX: 'end',
1404
+ originY: 'top',
1405
+ overlayX: 'start',
1406
+ overlayY: 'top'
1407
+ },
1408
+ rightBottom: {
1409
+ originX: 'end',
1410
+ originY: 'bottom',
1411
+ overlayX: 'start',
1412
+ overlayY: 'bottom'
1413
+ },
1414
+ bottom: {
1415
+ originX: 'center',
1416
+ originY: 'bottom',
1417
+ overlayX: 'center',
1418
+ overlayY: 'top'
1419
+ },
1420
+ bottomCenter: {
1421
+ originX: 'center',
1422
+ originY: 'bottom',
1423
+ overlayX: 'center',
1424
+ overlayY: 'top'
1425
+ },
1426
+ bottomLeft: {
1427
+ originX: 'start',
1428
+ originY: 'bottom',
1429
+ overlayX: 'start',
1430
+ overlayY: 'top'
1431
+ },
1432
+ bottomRight: {
1433
+ originX: 'end',
1434
+ originY: 'bottom',
1435
+ overlayX: 'end',
1436
+ overlayY: 'top'
1437
+ },
1438
+ left: {
1439
+ originX: 'start',
1440
+ originY: 'center',
1441
+ overlayX: 'end',
1442
+ overlayY: 'center'
1443
+ },
1444
+ leftTop: {
1445
+ originX: 'start',
1446
+ originY: 'top',
1447
+ overlayX: 'end',
1448
+ overlayY: 'top'
1449
+ },
1450
+ leftBottom: {
1451
+ originX: 'start',
1452
+ originY: 'bottom',
1453
+ overlayX: 'end',
1454
+ overlayY: 'bottom'
2737
1455
  }
2738
- ngAfterContentInit() {
2739
- const classList = this.element.nativeElement.classList;
2740
- this.isRow = classList.contains('mc-form__row');
2741
- this.isHorizontal = classList.contains('mc-horizontal');
2742
- this.isFieldSet = classList.contains('mc-form__fieldset');
2743
- if (this.isFieldSet && this.element.nativeElement.firstElementChild) {
2744
- this.hasLegend = this.element.nativeElement.firstElementChild.classList.contains('mc-form__legend');
2745
- }
1456
+ };
1457
+ const EXTENDED_OVERLAY_POSITIONS = objectValues([
1458
+ POSITION_MAP.top,
1459
+ POSITION_MAP.topLeft,
1460
+ POSITION_MAP.topRight,
1461
+ POSITION_MAP.right,
1462
+ POSITION_MAP.rightTop,
1463
+ POSITION_MAP.rightBottom,
1464
+ POSITION_MAP.bottom,
1465
+ POSITION_MAP.bottomLeft,
1466
+ POSITION_MAP.bottomRight,
1467
+ POSITION_MAP.left,
1468
+ POSITION_MAP.leftTop,
1469
+ POSITION_MAP.leftBottom
1470
+ ]);
1471
+ const TOP_POSITION_PRIORITY = objectValues([
1472
+ POSITION_MAP.top,
1473
+ POSITION_MAP.bottom,
1474
+ POSITION_MAP.rightBottom,
1475
+ POSITION_MAP.leftBottom,
1476
+ POSITION_MAP.bottomLeft,
1477
+ POSITION_MAP.bottomRight
1478
+ ]);
1479
+ const BOTTOM_POSITION_PRIORITY = objectValues([
1480
+ POSITION_MAP.bottom,
1481
+ POSITION_MAP.top,
1482
+ POSITION_MAP.topLeft,
1483
+ POSITION_MAP.topRight,
1484
+ POSITION_MAP.rightBottom,
1485
+ POSITION_MAP.leftBottom
1486
+ ]);
1487
+ const RIGHT_POSITION_PRIORITY = objectValues([
1488
+ POSITION_MAP.right,
1489
+ POSITION_MAP.left,
1490
+ POSITION_MAP.leftTop,
1491
+ POSITION_MAP.leftBottom,
1492
+ POSITION_MAP.top,
1493
+ POSITION_MAP.bottom
1494
+ ]);
1495
+ const LEFT_POSITION_PRIORITY = objectValues([
1496
+ POSITION_MAP.left,
1497
+ POSITION_MAP.right,
1498
+ POSITION_MAP.rightTop,
1499
+ POSITION_MAP.rightBottom,
1500
+ POSITION_MAP.top,
1501
+ POSITION_MAP.bottom
1502
+ ]);
1503
+ const RIGHT_TOP_POSITION_PRIORITY = objectValues([
1504
+ POSITION_MAP.rightTop,
1505
+ POSITION_MAP.leftTop,
1506
+ POSITION_MAP.left,
1507
+ POSITION_MAP.leftBottom,
1508
+ POSITION_MAP.topLeft,
1509
+ POSITION_MAP.bottomLeft
1510
+ ]);
1511
+ const RIGHT_BOTTOM_POSITION_PRIORITY = objectValues([
1512
+ POSITION_MAP.rightBottom,
1513
+ POSITION_MAP.leftBottom,
1514
+ POSITION_MAP.left,
1515
+ POSITION_MAP.leftTop,
1516
+ POSITION_MAP.topLeft,
1517
+ POSITION_MAP.bottomLeft
1518
+ ]);
1519
+ const LEFT_TOP_POSITION_PRIORITY = objectValues([
1520
+ POSITION_MAP.leftTop,
1521
+ POSITION_MAP.rightTop,
1522
+ POSITION_MAP.right,
1523
+ POSITION_MAP.rightBottom,
1524
+ POSITION_MAP.topRight,
1525
+ POSITION_MAP.bottomRight
1526
+ ]);
1527
+ const LEFT_BOTTOM_POSITION_PRIORITY = objectValues([
1528
+ POSITION_MAP.leftBottom,
1529
+ POSITION_MAP.rightBottom,
1530
+ POSITION_MAP.right,
1531
+ POSITION_MAP.rightTop,
1532
+ POSITION_MAP.topRight,
1533
+ POSITION_MAP.bottomRight
1534
+ ]);
1535
+ const TOP_LEFT_POSITION_PRIORITY = objectValues([
1536
+ POSITION_MAP.topLeft,
1537
+ POSITION_MAP.topRight,
1538
+ POSITION_MAP.bottomLeft,
1539
+ POSITION_MAP.bottom,
1540
+ POSITION_MAP.bottomRight,
1541
+ POSITION_MAP.leftBottom,
1542
+ POSITION_MAP.rightBottom
1543
+ ]);
1544
+ const TOP_RIGHT_POSITION_PRIORITY = objectValues([
1545
+ POSITION_MAP.topRight,
1546
+ POSITION_MAP.topLeft,
1547
+ POSITION_MAP.bottomRight,
1548
+ POSITION_MAP.bottom,
1549
+ POSITION_MAP.bottomLeft,
1550
+ POSITION_MAP.leftBottom,
1551
+ POSITION_MAP.rightBottom
1552
+ ]);
1553
+ const BOTTOM_RIGHT_POSITION_PRIORITY = objectValues([
1554
+ POSITION_MAP.bottomRight,
1555
+ POSITION_MAP.bottomLeft,
1556
+ POSITION_MAP.topRight,
1557
+ POSITION_MAP.top,
1558
+ POSITION_MAP.topLeft,
1559
+ POSITION_MAP.leftTop,
1560
+ POSITION_MAP.rightTop
1561
+ ]);
1562
+ const BOTTOM_LEFT_POSITION_PRIORITY = objectValues([
1563
+ POSITION_MAP.bottomLeft,
1564
+ POSITION_MAP.bottomRight,
1565
+ POSITION_MAP.topLeft,
1566
+ POSITION_MAP.top,
1567
+ POSITION_MAP.topRight,
1568
+ POSITION_MAP.rightTop,
1569
+ POSITION_MAP.leftTop
1570
+ ]);
1571
+ const POSITION_PRIORITY_STRATEGY = {
1572
+ top: TOP_POSITION_PRIORITY,
1573
+ topLeft: TOP_LEFT_POSITION_PRIORITY,
1574
+ topRight: TOP_RIGHT_POSITION_PRIORITY,
1575
+ bottom: BOTTOM_POSITION_PRIORITY,
1576
+ bottomLeft: BOTTOM_LEFT_POSITION_PRIORITY,
1577
+ bottomRight: BOTTOM_RIGHT_POSITION_PRIORITY,
1578
+ left: LEFT_POSITION_PRIORITY,
1579
+ leftTop: LEFT_TOP_POSITION_PRIORITY,
1580
+ leftBottom: LEFT_BOTTOM_POSITION_PRIORITY,
1581
+ right: RIGHT_POSITION_PRIORITY,
1582
+ rightTop: RIGHT_TOP_POSITION_PRIORITY,
1583
+ rightBottom: RIGHT_BOTTOM_POSITION_PRIORITY
1584
+ };
1585
+ const POSITION_TO_CSS_MAP = {
1586
+ top: 'top',
1587
+ topLeft: 'top-left',
1588
+ topRight: 'top-right',
1589
+ right: 'right',
1590
+ rightTop: 'right-top',
1591
+ rightBottom: 'right-bottom',
1592
+ left: 'left',
1593
+ leftTop: 'left-top',
1594
+ leftBottom: 'left-bottom',
1595
+ bottom: 'bottom',
1596
+ bottomLeft: 'bottom-left',
1597
+ bottomRight: 'bottom-right'
1598
+ };
1599
+ function arrayMap(array, iteratee) {
1600
+ let index = -1;
1601
+ const length = array === null ? 0 : array.length;
1602
+ const result = Array(length);
1603
+ while (++index < length) {
1604
+ result[index] = iteratee(array[index], index, array);
2746
1605
  }
1606
+ return result;
2747
1607
  }
2748
- /** @nocollapse */ McFormElement.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormElement, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
2749
- /** @nocollapse */ McFormElement.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: McFormElement, selector: ".mc-form__row, .mc-form__fieldset, .mc-form__legend", host: { properties: { "class.mc-form-row_margin": "margin" } }, queries: [{ propertyName: "elements", predicate: McFormElement }], exportAs: ["mcFormElement"], ngImport: i0 });
2750
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormElement, decorators: [{
2751
- type: Directive,
2752
- args: [{
2753
- selector: '.mc-form__row, .mc-form__fieldset, .mc-form__legend',
2754
- exportAs: 'mcFormElement',
2755
- host: {
2756
- '[class.mc-form-row_margin]': 'margin'
2757
- }
2758
- }]
2759
- }], ctorParameters: function () { return [{ type: i0.ElementRef }]; }, propDecorators: { elements: [{
2760
- type: ContentChildren,
2761
- args: [McFormElement]
2762
- }] } });
2763
- class McForm {
2764
- ngAfterContentInit() {
2765
- this.handleElements(this.elements);
2766
- }
2767
- handleElements(elements) {
2768
- elements.forEach((element, index) => {
2769
- const nextElement = elements.get(index + 1);
2770
- if (element.isFieldSet && !element.isHorizontal) {
2771
- this.handleElements(element.elements);
2772
- }
2773
- element.margin = !!(nextElement && !nextElement.hasLegend);
2774
- });
2775
- }
1608
+ function baseValues(object, props) {
1609
+ return arrayMap(props, (key) => object[key]);
2776
1610
  }
2777
- /** @nocollapse */ McForm.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McForm, deps: [], target: i0.ɵɵFactoryTarget.Directive });
2778
- /** @nocollapse */ McForm.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: McForm, selector: ".mc-form-vertical, .mc-form-horizontal", host: { classAttribute: "mc-form" }, queries: [{ propertyName: "elements", predicate: McFormElement }], exportAs: ["mcForm"], ngImport: i0 });
2779
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McForm, decorators: [{
2780
- type: Directive,
2781
- args: [{
2782
- selector: '.mc-form-vertical, .mc-form-horizontal',
2783
- exportAs: 'mcForm',
2784
- host: {
2785
- class: 'mc-form'
2786
- }
2787
- }]
2788
- }], propDecorators: { elements: [{
2789
- type: ContentChildren,
2790
- args: [McFormElement]
2791
- }] } });
2792
-
2793
- class McFormsModule {
1611
+ function objectValues(object) {
1612
+ return object === null ? [] : baseValues(object, Object.keys(object));
2794
1613
  }
2795
- /** @nocollapse */ McFormsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
2796
- /** @nocollapse */ McFormsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.12", ngImport: i0, type: McFormsModule, declarations: [McForm,
2797
- McFormElement], exports: [McForm,
2798
- McFormElement] });
2799
- /** @nocollapse */ McFormsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormsModule });
2800
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McFormsModule, decorators: [{
2801
- type: NgModule,
2802
- args: [{
2803
- exports: [
2804
- McForm,
2805
- McFormElement
2806
- ],
2807
- declarations: [
2808
- McForm,
2809
- McFormElement
2810
- ]
2811
- }]
2812
- }] });
2813
1614
 
2814
1615
  var PopUpPlacements;
2815
1616
  (function (PopUpPlacements) {
@@ -2925,9 +1726,9 @@ class McPopUp {
2925
1726
  }
2926
1727
  }
2927
1728
  }
2928
- /** @nocollapse */ McPopUp.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPopUp, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive });
2929
- /** @nocollapse */ McPopUp.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: McPopUp, ngImport: i0 });
2930
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPopUp, decorators: [{
1729
+ /** @nocollapse */ McPopUp.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPopUp, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive });
1730
+ /** @nocollapse */ McPopUp.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: McPopUp, ngImport: i0 });
1731
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPopUp, decorators: [{
2931
1732
  type: Directive
2932
1733
  }], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; } });
2933
1734
 
@@ -3156,15 +1957,126 @@ class McPopUpTrigger {
3156
1957
  });
3157
1958
  }
3158
1959
  }
3159
- /** @nocollapse */ McPopUpTrigger.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPopUpTrigger, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive });
3160
- /** @nocollapse */ McPopUpTrigger.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.12", type: McPopUpTrigger, ngImport: i0 });
3161
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.12", ngImport: i0, type: McPopUpTrigger, decorators: [{
1960
+ /** @nocollapse */ McPopUpTrigger.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPopUpTrigger, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive });
1961
+ /** @nocollapse */ McPopUpTrigger.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.2", type: McPopUpTrigger, ngImport: i0 });
1962
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McPopUpTrigger, decorators: [{
3162
1963
  type: Directive
3163
1964
  }], ctorParameters: function () { return [{ type: i1$2.Overlay }, { type: i0.ElementRef }, { type: i0.NgZone }, { type: i1$2.ScrollDispatcher }, { type: i0.ViewContainerRef }, { type: undefined }, { type: i2$1.Directionality }]; } });
3164
1965
 
1966
+ const selectEvents = 'selectEvents';
1967
+
1968
+ /**
1969
+ * Returns an exception to be thrown when attempting to change a select's `multiple` option
1970
+ * after initialization.
1971
+ * @docs-private
1972
+ */
1973
+ function getMcSelectDynamicMultipleError() {
1974
+ return Error('Cannot change `multiple` mode of select after initialization.');
1975
+ }
1976
+ /**
1977
+ * Returns an exception to be thrown when attempting to assign a non-array value to a select
1978
+ * in `multiple` mode. Note that `undefined` and `null` are still valid values to allow for
1979
+ * resetting the value.
1980
+ * @docs-private
1981
+ */
1982
+ function getMcSelectNonArrayValueError() {
1983
+ return Error('Value must be an array in multiple-selection mode.');
1984
+ }
1985
+ /**
1986
+ * Returns an exception to be thrown when assigning a non-function value to the comparator
1987
+ * used to determine if a value corresponds to an option. Note that whether the function
1988
+ * actually takes two values and returns a boolean is not checked.
1989
+ */
1990
+ function getMcSelectNonFunctionValueError() {
1991
+ return Error('`compareWith` must be a function.');
1992
+ }
1993
+
1994
+ /** The max height of the select's overlay panel */
1995
+ const SELECT_PANEL_MAX_HEIGHT = 224;
1996
+ /** The panel's padding on the x-axis */
1997
+ const SELECT_PANEL_PADDING_X = 1;
1998
+ /** The panel's x axis padding if it is indented (e.g. there is an option group). */
1999
+ /* tslint:disable-next-line:no-magic-numbers */
2000
+ const SELECT_PANEL_INDENT_PADDING_X = SELECT_PANEL_PADDING_X * 2;
2001
+ /**
2002
+ * The select panel will only "fit" inside the viewport if it is positioned at
2003
+ * this value or more away from the viewport boundary.
2004
+ */
2005
+ const SELECT_PANEL_VIEWPORT_PADDING = 8;
2006
+ /** Injection token that determines the scroll handling while a select is open. */
2007
+ const MC_SELECT_SCROLL_STRATEGY = new InjectionToken('mc-select-scroll-strategy');
2008
+ /** @docs-private */
2009
+ function mcSelectScrollStrategyProviderFactory(overlay) {
2010
+ return () => overlay.scrollStrategies.reposition();
2011
+ }
2012
+ /** @docs-private */
2013
+ const MC_SELECT_SCROLL_STRATEGY_PROVIDER = {
2014
+ provide: MC_SELECT_SCROLL_STRATEGY,
2015
+ deps: [Overlay],
2016
+ useFactory: mcSelectScrollStrategyProviderFactory
2017
+ };
2018
+
2019
+ class McMeasureScrollbarService {
2020
+ constructor(document) {
2021
+ this.document = document;
2022
+ this.scrollbarMeasure = {
2023
+ position: 'absolute',
2024
+ top: '-9999px',
2025
+ width: '50px',
2026
+ height: '50px',
2027
+ overflow: 'scroll'
2028
+ };
2029
+ this.initScrollBarWidth();
2030
+ }
2031
+ get scrollBarWidth() {
2032
+ if (this._scrollBarWidth) {
2033
+ return this._scrollBarWidth;
2034
+ }
2035
+ this.initScrollBarWidth();
2036
+ return this._scrollBarWidth;
2037
+ }
2038
+ initScrollBarWidth() {
2039
+ const scrollDiv = this.document.createElement('div');
2040
+ // tslint:disable-next-line
2041
+ for (const scrollProp in this.scrollbarMeasure) {
2042
+ if (this.scrollbarMeasure.hasOwnProperty(scrollProp)) {
2043
+ scrollDiv.style[scrollProp] = this.scrollbarMeasure[scrollProp];
2044
+ }
2045
+ }
2046
+ this.document.body.appendChild(scrollDiv);
2047
+ const width = scrollDiv.offsetWidth - scrollDiv.clientWidth;
2048
+ this.document.body.removeChild(scrollDiv);
2049
+ this._scrollBarWidth = width;
2050
+ }
2051
+ }
2052
+ /** @nocollapse */ McMeasureScrollbarService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McMeasureScrollbarService, deps: [{ token: DOCUMENT }], target: i0.ɵɵFactoryTarget.Injectable });
2053
+ /** @nocollapse */ McMeasureScrollbarService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McMeasureScrollbarService, providedIn: 'root' });
2054
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.2", ngImport: i0, type: McMeasureScrollbarService, decorators: [{
2055
+ type: Injectable,
2056
+ args: [{
2057
+ providedIn: 'root'
2058
+ }]
2059
+ }], ctorParameters: function () {
2060
+ return [{ type: undefined, decorators: [{
2061
+ type: Inject,
2062
+ args: [DOCUMENT]
2063
+ }] }];
2064
+ } });
2065
+
2066
+ function isBoolean(val) { return typeof val === 'boolean'; }
2067
+ function toBoolean(value) {
2068
+ return value != null && `${value}` !== 'false';
2069
+ }
2070
+
2071
+ const validationTooltipShowDelay = 10;
2072
+ const validationTooltipHideDelay = 3000;
2073
+ const MC_VALIDATION = new InjectionToken('McUseValidation', { factory: () => ({ useValidation: true }) });
2074
+
2075
+ const VERSION = new Version('15.0.0+sha-e73ad01');
2076
+
3165
2077
  /**
3166
2078
  * Generated bundle index. Do not edit.
3167
2079
  */
3168
2080
 
3169
- export { AbsoluteDateFormatterPipe, AbsoluteDateShortFormatterPipe, AbsoluteDateTimeFormatterPipe, AbsoluteShortDateTimeFormatterPipe, AnimationCurves, BOTTOM_LEFT_POSITION_PRIORITY, BOTTOM_POSITION_PRIORITY, BOTTOM_RIGHT_POSITION_PRIORITY, DEFAULT_MC_LOCALE_ID, DateFormatter, EXTENDED_OVERLAY_POSITIONS, ErrorStateMatcher, LEFT_BOTTOM_POSITION_PRIORITY, LEFT_POSITION_PRIORITY, LEFT_TOP_POSITION_PRIORITY, MC_LABEL_GLOBAL_OPTIONS, MC_LOCALE_ID, MC_NUMBER_FORMATTER_DEFAULT_OPTIONS, MC_NUMBER_FORMATTER_OPTIONS, MC_OPTION_ACTION_PARENT, MC_OPTION_PARENT_COMPONENT, MC_SANITY_CHECKS, MC_SELECT_SCROLL_STRATEGY, MC_SELECT_SCROLL_STRATEGY_PROVIDER, MC_VALIDATION, McCommonModule, McDecimalPipe, McForm, McFormElement, McFormattersModule, McFormsModule, McHighlightModule, McHighlightPipe, McLine, McLineModule, McLineSetter, McMeasureScrollbarService, McOptgroup, McOptgroupBase, McOptgroupMixinBase, McOption, McOptionActionBase, McOptionActionComponent, McOptionActionMixinBase, McOptionModule, McOptionSelectionChange, McPopUp, McPopUpTrigger, McPseudoCheckbox, McPseudoCheckboxBase, McPseudoCheckboxMixinBase, McPseudoCheckboxModule, MultipleMode, NUMBER_FORMAT_REGEXP, POSITION_MAP, POSITION_PRIORITY_STRATEGY, POSITION_TO_CSS_MAP, PopUpPlacements, PopUpSizes, PopUpTriggers, PopUpVisibility, RIGHT_BOTTOM_POSITION_PRIORITY, RIGHT_POSITION_PRIORITY, RIGHT_TOP_POSITION_PRIORITY, RangeDateFormatterPipe, RangeDateTimeFormatterPipe, RangeMiddleDateTimeFormatterPipe, RangeShortDateFormatterPipe, RangeShortDateTimeFormatterPipe, RelativeDateFormatterPipe, RelativeDateTimeFormatterPipe, RelativeShortDateFormatterPipe, RelativeShortDateTimeFormatterPipe, SELECT_PANEL_INDENT_PADDING_X, SELECT_PANEL_MAX_HEIGHT, SELECT_PANEL_PADDING_X, SELECT_PANEL_VIEWPORT_PADDING, ShowOnDirtyErrorStateMatcher, TOP_LEFT_POSITION_PRIORITY, TOP_POSITION_PRIORITY, TOP_RIGHT_POSITION_PRIORITY, ThemePalette, VERSION, countGroupLabelsBeforeOption, escapeRegExp, fadeAnimation, getMcSelectDynamicMultipleError, getMcSelectNonArrayValueError, getMcSelectNonFunctionValueError, getOptionScrollPosition, isBoolean, mcSelectAnimations, mcSelectScrollStrategyProviderFactory, mixinColor, mixinDisabled, mixinErrorState, mixinTabIndex, selectEvents, toBoolean, validationTooltipHideDelay, validationTooltipShowDelay };
2081
+ export { AbsoluteDateFormatterPipe, AbsoluteDateShortFormatterPipe, AbsoluteDateTimeFormatterPipe, AbsoluteShortDateTimeFormatterPipe, AnimationCurves, BOTTOM_LEFT_POSITION_PRIORITY, BOTTOM_POSITION_PRIORITY, BOTTOM_RIGHT_POSITION_PRIORITY, DEFAULT_MC_LOCALE_ID, DateAdapter, DateFormatter, EXTENDED_OVERLAY_POSITIONS, ErrorStateMatcher, LEFT_BOTTOM_POSITION_PRIORITY, LEFT_POSITION_PRIORITY, LEFT_TOP_POSITION_PRIORITY, MC_DATE_FORMATS, MC_DATE_LOCALE, MC_DATE_LOCALE_FACTORY, MC_LABEL_GLOBAL_OPTIONS, MC_LOCALE_ID, MC_NUMBER_FORMATTER_DEFAULT_OPTIONS, MC_NUMBER_FORMATTER_OPTIONS, MC_OPTION_ACTION_PARENT, MC_OPTION_PARENT_COMPONENT, MC_SANITY_CHECKS, MC_SELECT_SCROLL_STRATEGY, MC_SELECT_SCROLL_STRATEGY_PROVIDER, MC_VALIDATION, McCommonModule, McDecimalPipe, McForm, McFormElement, McFormattersModule, McFormsModule, McHighlightModule, McHighlightPipe, McLine, McLineModule, McLineSetter, McMeasureScrollbarService, McOptgroup, McOptgroupBase, McOptgroupMixinBase, McOption, McOptionActionBase, McOptionActionComponent, McOptionActionMixinBase, McOptionModule, McOptionSelectionChange, McPopUp, McPopUpTrigger, McPseudoCheckbox, McPseudoCheckboxBase, McPseudoCheckboxMixinBase, McPseudoCheckboxModule, MultipleMode, NUMBER_FORMAT_REGEXP, POSITION_MAP, POSITION_PRIORITY_STRATEGY, POSITION_TO_CSS_MAP, PopUpPlacements, PopUpSizes, PopUpTriggers, PopUpVisibility, RIGHT_BOTTOM_POSITION_PRIORITY, RIGHT_POSITION_PRIORITY, RIGHT_TOP_POSITION_PRIORITY, RangeDateFormatterPipe, RangeDateTimeFormatterPipe, RangeMiddleDateTimeFormatterPipe, RangeShortDateFormatterPipe, RangeShortDateTimeFormatterPipe, RelativeDateFormatterPipe, RelativeDateTimeFormatterPipe, RelativeShortDateFormatterPipe, RelativeShortDateTimeFormatterPipe, SELECT_PANEL_INDENT_PADDING_X, SELECT_PANEL_MAX_HEIGHT, SELECT_PANEL_PADDING_X, SELECT_PANEL_VIEWPORT_PADDING, ShowOnDirtyErrorStateMatcher, TOP_LEFT_POSITION_PRIORITY, TOP_POSITION_PRIORITY, TOP_RIGHT_POSITION_PRIORITY, ThemePalette, VERSION, countGroupLabelsBeforeOption, escapeRegExp, fadeAnimation, getMcSelectDynamicMultipleError, getMcSelectNonArrayValueError, getMcSelectNonFunctionValueError, getOptionScrollPosition, isBoolean, mcSelectAnimations, mcSelectScrollStrategyProviderFactory, mixinColor, mixinDisabled, mixinErrorState, mixinTabIndex, selectEvents, toBoolean, validationTooltipHideDelay, validationTooltipShowDelay };
3170
2082
  //# sourceMappingURL=ptsecurity-mosaic-core.mjs.map