primeng 0.0.0-watch

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 (507) hide show
  1. package/LICENSE.md +77 -0
  2. package/README.md +11 -0
  3. package/accordion/index.d.ts +255 -0
  4. package/animateonscroll/index.d.ts +71 -0
  5. package/api/index.d.ts +1820 -0
  6. package/autocomplete/index.d.ts +925 -0
  7. package/autofocus/index.d.ts +31 -0
  8. package/avatar/index.d.ts +115 -0
  9. package/avatargroup/index.d.ts +60 -0
  10. package/badge/index.d.ts +156 -0
  11. package/base/index.d.ts +63 -0
  12. package/basecomponent/index.d.ts +54 -0
  13. package/baseeditableholder/index.d.ts +45 -0
  14. package/baseinput/index.d.ts +73 -0
  15. package/basemodelholder/index.d.ts +12 -0
  16. package/blockui/index.d.ts +114 -0
  17. package/breadcrumb/index.d.ts +179 -0
  18. package/button/index.d.ts +478 -0
  19. package/buttongroup/index.d.ts +43 -0
  20. package/card/index.d.ts +154 -0
  21. package/carousel/index.d.ts +443 -0
  22. package/cascadeselect/index.d.ts +729 -0
  23. package/chart/index.d.ts +128 -0
  24. package/checkbox/index.d.ts +248 -0
  25. package/chip/index.d.ts +165 -0
  26. package/colorpicker/index.d.ts +329 -0
  27. package/config/index.d.ts +89 -0
  28. package/confirmdialog/index.d.ts +358 -0
  29. package/confirmpopup/index.d.ts +218 -0
  30. package/contextmenu/index.d.ts +356 -0
  31. package/dataview/index.d.ts +539 -0
  32. package/datepicker/index.d.ts +1191 -0
  33. package/dialog/index.d.ts +531 -0
  34. package/divider/index.d.ts +114 -0
  35. package/dock/index.d.ts +201 -0
  36. package/dom/index.d.ts +109 -0
  37. package/dragdrop/index.d.ts +121 -0
  38. package/drawer/index.d.ts +309 -0
  39. package/dynamicdialog/index.d.ts +544 -0
  40. package/editor/index.d.ts +306 -0
  41. package/fesm2022/primeng-accordion.mjs +593 -0
  42. package/fesm2022/primeng-accordion.mjs.map +1 -0
  43. package/fesm2022/primeng-animateonscroll.mjs +178 -0
  44. package/fesm2022/primeng-animateonscroll.mjs.map +1 -0
  45. package/fesm2022/primeng-api.mjs +836 -0
  46. package/fesm2022/primeng-api.mjs.map +1 -0
  47. package/fesm2022/primeng-autocomplete.mjs +2073 -0
  48. package/fesm2022/primeng-autocomplete.mjs.map +1 -0
  49. package/fesm2022/primeng-autofocus.mjs +83 -0
  50. package/fesm2022/primeng-autofocus.mjs.map +1 -0
  51. package/fesm2022/primeng-avatar.mjs +181 -0
  52. package/fesm2022/primeng-avatar.mjs.map +1 -0
  53. package/fesm2022/primeng-avatargroup.mjs +103 -0
  54. package/fesm2022/primeng-avatargroup.mjs.map +1 -0
  55. package/fesm2022/primeng-badge.mjs +366 -0
  56. package/fesm2022/primeng-badge.mjs.map +1 -0
  57. package/fesm2022/primeng-base.mjs +127 -0
  58. package/fesm2022/primeng-base.mjs.map +1 -0
  59. package/fesm2022/primeng-basecomponent.mjs +173 -0
  60. package/fesm2022/primeng-basecomponent.mjs.map +1 -0
  61. package/fesm2022/primeng-baseeditableholder.mjs +67 -0
  62. package/fesm2022/primeng-baseeditableholder.mjs.map +1 -0
  63. package/fesm2022/primeng-baseinput.mjs +85 -0
  64. package/fesm2022/primeng-baseinput.mjs.map +1 -0
  65. package/fesm2022/primeng-basemodelholder.mjs +25 -0
  66. package/fesm2022/primeng-basemodelholder.mjs.map +1 -0
  67. package/fesm2022/primeng-blockui.mjs +237 -0
  68. package/fesm2022/primeng-blockui.mjs.map +1 -0
  69. package/fesm2022/primeng-breadcrumb.mjs +457 -0
  70. package/fesm2022/primeng-breadcrumb.mjs.map +1 -0
  71. package/fesm2022/primeng-button.mjs +864 -0
  72. package/fesm2022/primeng-button.mjs.map +1 -0
  73. package/fesm2022/primeng-buttongroup.mjs +109 -0
  74. package/fesm2022/primeng-buttongroup.mjs.map +1 -0
  75. package/fesm2022/primeng-card.mjs +271 -0
  76. package/fesm2022/primeng-card.mjs.map +1 -0
  77. package/fesm2022/primeng-carousel.mjs +1101 -0
  78. package/fesm2022/primeng-carousel.mjs.map +1 -0
  79. package/fesm2022/primeng-cascadeselect.mjs +1778 -0
  80. package/fesm2022/primeng-cascadeselect.mjs.map +1 -0
  81. package/fesm2022/primeng-chart.mjs +246 -0
  82. package/fesm2022/primeng-chart.mjs.map +1 -0
  83. package/fesm2022/primeng-checkbox.mjs +441 -0
  84. package/fesm2022/primeng-checkbox.mjs.map +1 -0
  85. package/fesm2022/primeng-chip.mjs +323 -0
  86. package/fesm2022/primeng-chip.mjs.map +1 -0
  87. package/fesm2022/primeng-colorpicker.mjs +865 -0
  88. package/fesm2022/primeng-colorpicker.mjs.map +1 -0
  89. package/fesm2022/primeng-config.mjs +289 -0
  90. package/fesm2022/primeng-config.mjs.map +1 -0
  91. package/fesm2022/primeng-confirmdialog.mjs +823 -0
  92. package/fesm2022/primeng-confirmdialog.mjs.map +1 -0
  93. package/fesm2022/primeng-confirmpopup.mjs +630 -0
  94. package/fesm2022/primeng-confirmpopup.mjs.map +1 -0
  95. package/fesm2022/primeng-contextmenu.mjs +1410 -0
  96. package/fesm2022/primeng-contextmenu.mjs.map +1 -0
  97. package/fesm2022/primeng-dataview.mjs +812 -0
  98. package/fesm2022/primeng-dataview.mjs.map +1 -0
  99. package/fesm2022/primeng-datepicker.mjs +4373 -0
  100. package/fesm2022/primeng-datepicker.mjs.map +1 -0
  101. package/fesm2022/primeng-dialog.mjs +1278 -0
  102. package/fesm2022/primeng-dialog.mjs.map +1 -0
  103. package/fesm2022/primeng-divider.mjs +145 -0
  104. package/fesm2022/primeng-divider.mjs.map +1 -0
  105. package/fesm2022/primeng-dock.mjs +540 -0
  106. package/fesm2022/primeng-dock.mjs.map +1 -0
  107. package/fesm2022/primeng-dom.mjs +775 -0
  108. package/fesm2022/primeng-dom.mjs.map +1 -0
  109. package/fesm2022/primeng-dragdrop.mjs +336 -0
  110. package/fesm2022/primeng-dragdrop.mjs.map +1 -0
  111. package/fesm2022/primeng-drawer.mjs +738 -0
  112. package/fesm2022/primeng-drawer.mjs.map +1 -0
  113. package/fesm2022/primeng-dynamicdialog.mjs +1242 -0
  114. package/fesm2022/primeng-dynamicdialog.mjs.map +1 -0
  115. package/fesm2022/primeng-editor.mjs +511 -0
  116. package/fesm2022/primeng-editor.mjs.map +1 -0
  117. package/fesm2022/primeng-fieldset.mjs +417 -0
  118. package/fesm2022/primeng-fieldset.mjs.map +1 -0
  119. package/fesm2022/primeng-fileupload.mjs +1561 -0
  120. package/fesm2022/primeng-fileupload.mjs.map +1 -0
  121. package/fesm2022/primeng-floatlabel.mjs +103 -0
  122. package/fesm2022/primeng-floatlabel.mjs.map +1 -0
  123. package/fesm2022/primeng-fluid.mjs +80 -0
  124. package/fesm2022/primeng-fluid.mjs.map +1 -0
  125. package/fesm2022/primeng-focustrap.mjs +110 -0
  126. package/fesm2022/primeng-focustrap.mjs.map +1 -0
  127. package/fesm2022/primeng-galleria.mjs +1874 -0
  128. package/fesm2022/primeng-galleria.mjs.map +1 -0
  129. package/fesm2022/primeng-iconfield.mjs +101 -0
  130. package/fesm2022/primeng-iconfield.mjs.map +1 -0
  131. package/fesm2022/primeng-icons-angledoubledown.mjs +37 -0
  132. package/fesm2022/primeng-icons-angledoubledown.mjs.map +1 -0
  133. package/fesm2022/primeng-icons-angledoubleleft.mjs +37 -0
  134. package/fesm2022/primeng-icons-angledoubleleft.mjs.map +1 -0
  135. package/fesm2022/primeng-icons-angledoubleright.mjs +37 -0
  136. package/fesm2022/primeng-icons-angledoubleright.mjs.map +1 -0
  137. package/fesm2022/primeng-icons-angledoubleup.mjs +37 -0
  138. package/fesm2022/primeng-icons-angledoubleup.mjs.map +1 -0
  139. package/fesm2022/primeng-icons-angledown.mjs +33 -0
  140. package/fesm2022/primeng-icons-angledown.mjs.map +1 -0
  141. package/fesm2022/primeng-icons-angleleft.mjs +33 -0
  142. package/fesm2022/primeng-icons-angleleft.mjs.map +1 -0
  143. package/fesm2022/primeng-icons-angleright.mjs +33 -0
  144. package/fesm2022/primeng-icons-angleright.mjs.map +1 -0
  145. package/fesm2022/primeng-icons-angleup.mjs +33 -0
  146. package/fesm2022/primeng-icons-angleup.mjs.map +1 -0
  147. package/fesm2022/primeng-icons-arrowdown.mjs +57 -0
  148. package/fesm2022/primeng-icons-arrowdown.mjs.map +1 -0
  149. package/fesm2022/primeng-icons-arrowdownleft.mjs +33 -0
  150. package/fesm2022/primeng-icons-arrowdownleft.mjs.map +1 -0
  151. package/fesm2022/primeng-icons-arrowdownright.mjs +33 -0
  152. package/fesm2022/primeng-icons-arrowdownright.mjs.map +1 -0
  153. package/fesm2022/primeng-icons-arrowleft.mjs +57 -0
  154. package/fesm2022/primeng-icons-arrowleft.mjs.map +1 -0
  155. package/fesm2022/primeng-icons-arrowright.mjs +37 -0
  156. package/fesm2022/primeng-icons-arrowright.mjs.map +1 -0
  157. package/fesm2022/primeng-icons-arrowup.mjs +57 -0
  158. package/fesm2022/primeng-icons-arrowup.mjs.map +1 -0
  159. package/fesm2022/primeng-icons-ban.mjs +53 -0
  160. package/fesm2022/primeng-icons-ban.mjs.map +1 -0
  161. package/fesm2022/primeng-icons-bars.mjs +37 -0
  162. package/fesm2022/primeng-icons-bars.mjs.map +1 -0
  163. package/fesm2022/primeng-icons-baseicon.mjs +102 -0
  164. package/fesm2022/primeng-icons-baseicon.mjs.map +1 -0
  165. package/fesm2022/primeng-icons-blank.mjs +23 -0
  166. package/fesm2022/primeng-icons-blank.mjs.map +1 -0
  167. package/fesm2022/primeng-icons-calendar.mjs +33 -0
  168. package/fesm2022/primeng-icons-calendar.mjs.map +1 -0
  169. package/fesm2022/primeng-icons-caretleft.mjs +33 -0
  170. package/fesm2022/primeng-icons-caretleft.mjs.map +1 -0
  171. package/fesm2022/primeng-icons-caretright.mjs +33 -0
  172. package/fesm2022/primeng-icons-caretright.mjs.map +1 -0
  173. package/fesm2022/primeng-icons-check.mjs +33 -0
  174. package/fesm2022/primeng-icons-check.mjs.map +1 -0
  175. package/fesm2022/primeng-icons-chevrondown.mjs +33 -0
  176. package/fesm2022/primeng-icons-chevrondown.mjs.map +1 -0
  177. package/fesm2022/primeng-icons-chevronleft.mjs +33 -0
  178. package/fesm2022/primeng-icons-chevronleft.mjs.map +1 -0
  179. package/fesm2022/primeng-icons-chevronright.mjs +33 -0
  180. package/fesm2022/primeng-icons-chevronright.mjs.map +1 -0
  181. package/fesm2022/primeng-icons-chevronup.mjs +33 -0
  182. package/fesm2022/primeng-icons-chevronup.mjs.map +1 -0
  183. package/fesm2022/primeng-icons-exclamationtriangle.mjs +69 -0
  184. package/fesm2022/primeng-icons-exclamationtriangle.mjs.map +1 -0
  185. package/fesm2022/primeng-icons-eye.mjs +37 -0
  186. package/fesm2022/primeng-icons-eye.mjs.map +1 -0
  187. package/fesm2022/primeng-icons-eyeslash.mjs +57 -0
  188. package/fesm2022/primeng-icons-eyeslash.mjs.map +1 -0
  189. package/fesm2022/primeng-icons-filter.mjs +53 -0
  190. package/fesm2022/primeng-icons-filter.mjs.map +1 -0
  191. package/fesm2022/primeng-icons-filterfill.mjs +33 -0
  192. package/fesm2022/primeng-icons-filterfill.mjs.map +1 -0
  193. package/fesm2022/primeng-icons-filterslash.mjs +57 -0
  194. package/fesm2022/primeng-icons-filterslash.mjs.map +1 -0
  195. package/fesm2022/primeng-icons-home.mjs +57 -0
  196. package/fesm2022/primeng-icons-home.mjs.map +1 -0
  197. package/fesm2022/primeng-icons-infocircle.mjs +57 -0
  198. package/fesm2022/primeng-icons-infocircle.mjs.map +1 -0
  199. package/fesm2022/primeng-icons-minus.mjs +33 -0
  200. package/fesm2022/primeng-icons-minus.mjs.map +1 -0
  201. package/fesm2022/primeng-icons-pencil.mjs +53 -0
  202. package/fesm2022/primeng-icons-pencil.mjs.map +1 -0
  203. package/fesm2022/primeng-icons-plus.mjs +53 -0
  204. package/fesm2022/primeng-icons-plus.mjs.map +1 -0
  205. package/fesm2022/primeng-icons-refresh.mjs +57 -0
  206. package/fesm2022/primeng-icons-refresh.mjs.map +1 -0
  207. package/fesm2022/primeng-icons-search.mjs +57 -0
  208. package/fesm2022/primeng-icons-search.mjs.map +1 -0
  209. package/fesm2022/primeng-icons-searchminus.mjs +57 -0
  210. package/fesm2022/primeng-icons-searchminus.mjs.map +1 -0
  211. package/fesm2022/primeng-icons-searchplus.mjs +57 -0
  212. package/fesm2022/primeng-icons-searchplus.mjs.map +1 -0
  213. package/fesm2022/primeng-icons-sortalt.mjs +65 -0
  214. package/fesm2022/primeng-icons-sortalt.mjs.map +1 -0
  215. package/fesm2022/primeng-icons-sortamountdown.mjs +53 -0
  216. package/fesm2022/primeng-icons-sortamountdown.mjs.map +1 -0
  217. package/fesm2022/primeng-icons-sortamountupalt.mjs +53 -0
  218. package/fesm2022/primeng-icons-sortamountupalt.mjs.map +1 -0
  219. package/fesm2022/primeng-icons-spinner.mjs +53 -0
  220. package/fesm2022/primeng-icons-spinner.mjs.map +1 -0
  221. package/fesm2022/primeng-icons-star.mjs +53 -0
  222. package/fesm2022/primeng-icons-star.mjs.map +1 -0
  223. package/fesm2022/primeng-icons-starfill.mjs +53 -0
  224. package/fesm2022/primeng-icons-starfill.mjs.map +1 -0
  225. package/fesm2022/primeng-icons-thlarge.mjs +57 -0
  226. package/fesm2022/primeng-icons-thlarge.mjs.map +1 -0
  227. package/fesm2022/primeng-icons-times.mjs +33 -0
  228. package/fesm2022/primeng-icons-times.mjs.map +1 -0
  229. package/fesm2022/primeng-icons-timescircle.mjs +57 -0
  230. package/fesm2022/primeng-icons-timescircle.mjs.map +1 -0
  231. package/fesm2022/primeng-icons-trash.mjs +57 -0
  232. package/fesm2022/primeng-icons-trash.mjs.map +1 -0
  233. package/fesm2022/primeng-icons-undo.mjs +57 -0
  234. package/fesm2022/primeng-icons-undo.mjs.map +1 -0
  235. package/fesm2022/primeng-icons-upload.mjs +57 -0
  236. package/fesm2022/primeng-icons-upload.mjs.map +1 -0
  237. package/fesm2022/primeng-icons-windowmaximize.mjs +57 -0
  238. package/fesm2022/primeng-icons-windowmaximize.mjs.map +1 -0
  239. package/fesm2022/primeng-icons-windowminimize.mjs +57 -0
  240. package/fesm2022/primeng-icons-windowminimize.mjs.map +1 -0
  241. package/fesm2022/primeng-icons.mjs +63 -0
  242. package/fesm2022/primeng-icons.mjs.map +1 -0
  243. package/fesm2022/primeng-iftalabel.mjs +89 -0
  244. package/fesm2022/primeng-iftalabel.mjs.map +1 -0
  245. package/fesm2022/primeng-image.mjs +705 -0
  246. package/fesm2022/primeng-image.mjs.map +1 -0
  247. package/fesm2022/primeng-imagecompare.mjs +192 -0
  248. package/fesm2022/primeng-imagecompare.mjs.map +1 -0
  249. package/fesm2022/primeng-inplace.mjs +319 -0
  250. package/fesm2022/primeng-inplace.mjs.map +1 -0
  251. package/fesm2022/primeng-inputgroup.mjs +128 -0
  252. package/fesm2022/primeng-inputgroup.mjs.map +1 -0
  253. package/fesm2022/primeng-inputgroupaddon.mjs +83 -0
  254. package/fesm2022/primeng-inputgroupaddon.mjs.map +1 -0
  255. package/fesm2022/primeng-inputicon.mjs +71 -0
  256. package/fesm2022/primeng-inputicon.mjs.map +1 -0
  257. package/fesm2022/primeng-inputmask.mjs +926 -0
  258. package/fesm2022/primeng-inputmask.mjs.map +1 -0
  259. package/fesm2022/primeng-inputnumber.mjs +1621 -0
  260. package/fesm2022/primeng-inputnumber.mjs.map +1 -0
  261. package/fesm2022/primeng-inputotp.mjs +443 -0
  262. package/fesm2022/primeng-inputotp.mjs.map +1 -0
  263. package/fesm2022/primeng-inputtext.mjs +145 -0
  264. package/fesm2022/primeng-inputtext.mjs.map +1 -0
  265. package/fesm2022/primeng-keyfilter.mjs +267 -0
  266. package/fesm2022/primeng-keyfilter.mjs.map +1 -0
  267. package/fesm2022/primeng-knob.mjs +491 -0
  268. package/fesm2022/primeng-knob.mjs.map +1 -0
  269. package/fesm2022/primeng-listbox.mjs +1925 -0
  270. package/fesm2022/primeng-listbox.mjs.map +1 -0
  271. package/fesm2022/primeng-megamenu.mjs +1493 -0
  272. package/fesm2022/primeng-megamenu.mjs.map +1 -0
  273. package/fesm2022/primeng-menu.mjs +1069 -0
  274. package/fesm2022/primeng-menu.mjs.map +1 -0
  275. package/fesm2022/primeng-menubar.mjs +1391 -0
  276. package/fesm2022/primeng-menubar.mjs.map +1 -0
  277. package/fesm2022/primeng-message.mjs +420 -0
  278. package/fesm2022/primeng-message.mjs.map +1 -0
  279. package/fesm2022/primeng-metergroup.mjs +393 -0
  280. package/fesm2022/primeng-metergroup.mjs.map +1 -0
  281. package/fesm2022/primeng-multiselect.mjs +2519 -0
  282. package/fesm2022/primeng-multiselect.mjs.map +1 -0
  283. package/fesm2022/primeng-orderlist.mjs +890 -0
  284. package/fesm2022/primeng-orderlist.mjs.map +1 -0
  285. package/fesm2022/primeng-organizationchart.mjs +520 -0
  286. package/fesm2022/primeng-organizationchart.mjs.map +1 -0
  287. package/fesm2022/primeng-overlay.mjs +776 -0
  288. package/fesm2022/primeng-overlay.mjs.map +1 -0
  289. package/fesm2022/primeng-overlaybadge.mjs +151 -0
  290. package/fesm2022/primeng-overlaybadge.mjs.map +1 -0
  291. package/fesm2022/primeng-paginator.mjs +802 -0
  292. package/fesm2022/primeng-paginator.mjs.map +1 -0
  293. package/fesm2022/primeng-panel.mjs +595 -0
  294. package/fesm2022/primeng-panel.mjs.map +1 -0
  295. package/fesm2022/primeng-panelmenu.mjs +1442 -0
  296. package/fesm2022/primeng-panelmenu.mjs.map +1 -0
  297. package/fesm2022/primeng-password.mjs +1156 -0
  298. package/fesm2022/primeng-password.mjs.map +1 -0
  299. package/fesm2022/primeng-picklist.mjs +2057 -0
  300. package/fesm2022/primeng-picklist.mjs.map +1 -0
  301. package/fesm2022/primeng-popover.mjs +611 -0
  302. package/fesm2022/primeng-popover.mjs.map +1 -0
  303. package/fesm2022/primeng-progressbar.mjs +196 -0
  304. package/fesm2022/primeng-progressbar.mjs.map +1 -0
  305. package/fesm2022/primeng-progressspinner.mjs +140 -0
  306. package/fesm2022/primeng-progressspinner.mjs.map +1 -0
  307. package/fesm2022/primeng-radiobutton.mjs +358 -0
  308. package/fesm2022/primeng-radiobutton.mjs.map +1 -0
  309. package/fesm2022/primeng-rating.mjs +388 -0
  310. package/fesm2022/primeng-rating.mjs.map +1 -0
  311. package/fesm2022/primeng-ripple.mjs +190 -0
  312. package/fesm2022/primeng-ripple.mjs.map +1 -0
  313. package/fesm2022/primeng-scroller.mjs +1306 -0
  314. package/fesm2022/primeng-scroller.mjs.map +1 -0
  315. package/fesm2022/primeng-scrollpanel.mjs +560 -0
  316. package/fesm2022/primeng-scrollpanel.mjs.map +1 -0
  317. package/fesm2022/primeng-scrolltop.mjs +339 -0
  318. package/fesm2022/primeng-scrolltop.mjs.map +1 -0
  319. package/fesm2022/primeng-select.mjs +2250 -0
  320. package/fesm2022/primeng-select.mjs.map +1 -0
  321. package/fesm2022/primeng-selectbutton.mjs +413 -0
  322. package/fesm2022/primeng-selectbutton.mjs.map +1 -0
  323. package/fesm2022/primeng-skeleton.mjs +154 -0
  324. package/fesm2022/primeng-skeleton.mjs.map +1 -0
  325. package/fesm2022/primeng-slider.mjs +843 -0
  326. package/fesm2022/primeng-slider.mjs.map +1 -0
  327. package/fesm2022/primeng-speeddial.mjs +901 -0
  328. package/fesm2022/primeng-speeddial.mjs.map +1 -0
  329. package/fesm2022/primeng-splitbutton.mjs +598 -0
  330. package/fesm2022/primeng-splitbutton.mjs.map +1 -0
  331. package/fesm2022/primeng-splitter.mjs +587 -0
  332. package/fesm2022/primeng-splitter.mjs.map +1 -0
  333. package/fesm2022/primeng-stepper.mjs +683 -0
  334. package/fesm2022/primeng-stepper.mjs.map +1 -0
  335. package/fesm2022/primeng-steps.mjs +424 -0
  336. package/fesm2022/primeng-steps.mjs.map +1 -0
  337. package/fesm2022/primeng-styleclass.mjs +354 -0
  338. package/fesm2022/primeng-styleclass.mjs.map +1 -0
  339. package/fesm2022/primeng-table.mjs +7540 -0
  340. package/fesm2022/primeng-table.mjs.map +1 -0
  341. package/fesm2022/primeng-tabs.mjs +794 -0
  342. package/fesm2022/primeng-tabs.mjs.map +1 -0
  343. package/fesm2022/primeng-tag.mjs +176 -0
  344. package/fesm2022/primeng-tag.mjs.map +1 -0
  345. package/fesm2022/primeng-terminal.mjs +254 -0
  346. package/fesm2022/primeng-terminal.mjs.map +1 -0
  347. package/fesm2022/primeng-textarea.mjs +197 -0
  348. package/fesm2022/primeng-textarea.mjs.map +1 -0
  349. package/fesm2022/primeng-tieredmenu.mjs +1457 -0
  350. package/fesm2022/primeng-tieredmenu.mjs.map +1 -0
  351. package/fesm2022/primeng-timeline.mjs +228 -0
  352. package/fesm2022/primeng-timeline.mjs.map +1 -0
  353. package/fesm2022/primeng-toast.mjs +751 -0
  354. package/fesm2022/primeng-toast.mjs.map +1 -0
  355. package/fesm2022/primeng-togglebutton.mjs +361 -0
  356. package/fesm2022/primeng-togglebutton.mjs.map +1 -0
  357. package/fesm2022/primeng-toggleswitch.mjs +330 -0
  358. package/fesm2022/primeng-toggleswitch.mjs.map +1 -0
  359. package/fesm2022/primeng-toolbar.mjs +189 -0
  360. package/fesm2022/primeng-toolbar.mjs.map +1 -0
  361. package/fesm2022/primeng-tooltip.mjs +757 -0
  362. package/fesm2022/primeng-tooltip.mjs.map +1 -0
  363. package/fesm2022/primeng-tree.mjs +2188 -0
  364. package/fesm2022/primeng-tree.mjs.map +1 -0
  365. package/fesm2022/primeng-treeselect.mjs +1328 -0
  366. package/fesm2022/primeng-treeselect.mjs.map +1 -0
  367. package/fesm2022/primeng-treetable.mjs +5080 -0
  368. package/fesm2022/primeng-treetable.mjs.map +1 -0
  369. package/fesm2022/primeng-ts-helpers.mjs +4 -0
  370. package/fesm2022/primeng-ts-helpers.mjs.map +1 -0
  371. package/fesm2022/primeng-usestyle.mjs +52 -0
  372. package/fesm2022/primeng-usestyle.mjs.map +1 -0
  373. package/fesm2022/primeng-utils.mjs +332 -0
  374. package/fesm2022/primeng-utils.mjs.map +1 -0
  375. package/fesm2022/primeng.mjs +6 -0
  376. package/fesm2022/primeng.mjs.map +1 -0
  377. package/fieldset/index.d.ts +217 -0
  378. package/fileupload/index.d.ts +786 -0
  379. package/floatlabel/index.d.ts +59 -0
  380. package/fluid/index.d.ts +48 -0
  381. package/focustrap/index.d.ts +36 -0
  382. package/galleria/index.d.ts +710 -0
  383. package/iconfield/index.d.ts +64 -0
  384. package/icons/angledoubledown/index.d.ts +9 -0
  385. package/icons/angledoubleleft/index.d.ts +9 -0
  386. package/icons/angledoubleright/index.d.ts +9 -0
  387. package/icons/angledoubleup/index.d.ts +9 -0
  388. package/icons/angledown/index.d.ts +9 -0
  389. package/icons/angleleft/index.d.ts +9 -0
  390. package/icons/angleright/index.d.ts +9 -0
  391. package/icons/angleup/index.d.ts +9 -0
  392. package/icons/arrowdown/index.d.ts +12 -0
  393. package/icons/arrowdownleft/index.d.ts +9 -0
  394. package/icons/arrowdownright/index.d.ts +9 -0
  395. package/icons/arrowleft/index.d.ts +11 -0
  396. package/icons/arrowright/index.d.ts +9 -0
  397. package/icons/arrowup/index.d.ts +11 -0
  398. package/icons/ban/index.d.ts +11 -0
  399. package/icons/bars/index.d.ts +9 -0
  400. package/icons/baseicon/index.d.ts +33 -0
  401. package/icons/blank/index.d.ts +9 -0
  402. package/icons/calendar/index.d.ts +9 -0
  403. package/icons/caretleft/index.d.ts +9 -0
  404. package/icons/caretright/index.d.ts +9 -0
  405. package/icons/check/index.d.ts +9 -0
  406. package/icons/chevrondown/index.d.ts +9 -0
  407. package/icons/chevronleft/index.d.ts +9 -0
  408. package/icons/chevronright/index.d.ts +9 -0
  409. package/icons/chevronup/index.d.ts +9 -0
  410. package/icons/exclamationtriangle/index.d.ts +12 -0
  411. package/icons/eye/index.d.ts +9 -0
  412. package/icons/eyeslash/index.d.ts +11 -0
  413. package/icons/filter/index.d.ts +11 -0
  414. package/icons/filterfill/index.d.ts +9 -0
  415. package/icons/filterslash/index.d.ts +11 -0
  416. package/icons/home/index.d.ts +11 -0
  417. package/icons/index.d.ts +53 -0
  418. package/icons/infocircle/index.d.ts +11 -0
  419. package/icons/minus/index.d.ts +9 -0
  420. package/icons/pencil/index.d.ts +11 -0
  421. package/icons/plus/index.d.ts +11 -0
  422. package/icons/refresh/index.d.ts +11 -0
  423. package/icons/search/index.d.ts +11 -0
  424. package/icons/searchminus/index.d.ts +11 -0
  425. package/icons/searchplus/index.d.ts +11 -0
  426. package/icons/sortalt/index.d.ts +11 -0
  427. package/icons/sortamountdown/index.d.ts +11 -0
  428. package/icons/sortamountupalt/index.d.ts +11 -0
  429. package/icons/spinner/index.d.ts +11 -0
  430. package/icons/star/index.d.ts +11 -0
  431. package/icons/starfill/index.d.ts +11 -0
  432. package/icons/thlarge/index.d.ts +11 -0
  433. package/icons/times/index.d.ts +9 -0
  434. package/icons/timescircle/index.d.ts +11 -0
  435. package/icons/trash/index.d.ts +11 -0
  436. package/icons/undo/index.d.ts +11 -0
  437. package/icons/upload/index.d.ts +11 -0
  438. package/icons/windowmaximize/index.d.ts +11 -0
  439. package/icons/windowminimize/index.d.ts +11 -0
  440. package/iftalabel/index.d.ts +50 -0
  441. package/image/index.d.ts +376 -0
  442. package/imagecompare/index.d.ts +93 -0
  443. package/index.d.ts +2 -0
  444. package/inplace/index.d.ts +183 -0
  445. package/inputgroup/index.d.ts +58 -0
  446. package/inputgroupaddon/index.d.ts +45 -0
  447. package/inputicon/index.d.ts +36 -0
  448. package/inputmask/index.d.ts +282 -0
  449. package/inputnumber/index.d.ts +466 -0
  450. package/inputotp/index.d.ts +209 -0
  451. package/inputtext/index.d.ts +89 -0
  452. package/keyfilter/index.d.ts +66 -0
  453. package/knob/index.d.ts +206 -0
  454. package/listbox/index.d.ts +802 -0
  455. package/megamenu/index.d.ts +408 -0
  456. package/menu/index.d.ts +341 -0
  457. package/menubar/index.d.ts +418 -0
  458. package/message/index.d.ts +195 -0
  459. package/metergroup/index.d.ts +291 -0
  460. package/multiselect/index.d.ts +1060 -0
  461. package/orderlist/index.d.ts +464 -0
  462. package/organizationchart/index.d.ts +285 -0
  463. package/overlay/index.d.ts +255 -0
  464. package/overlaybadge/index.d.ts +73 -0
  465. package/package.json +725 -0
  466. package/paginator/index.d.ts +393 -0
  467. package/panel/index.d.ts +266 -0
  468. package/panelmenu/index.d.ts +380 -0
  469. package/password/index.d.ts +436 -0
  470. package/picklist/index.d.ts +906 -0
  471. package/popover/index.d.ts +176 -0
  472. package/progressbar/index.d.ts +112 -0
  473. package/progressspinner/index.d.ts +85 -0
  474. package/radiobutton/index.d.ts +201 -0
  475. package/rating/index.d.ts +218 -0
  476. package/ripple/index.d.ts +62 -0
  477. package/scroller/index.d.ts +614 -0
  478. package/scrollpanel/index.d.ts +161 -0
  479. package/scrolltop/index.d.ts +158 -0
  480. package/select/index.d.ts +923 -0
  481. package/selectbutton/index.d.ts +221 -0
  482. package/skeleton/index.d.ts +96 -0
  483. package/slider/index.d.ts +255 -0
  484. package/speeddial/index.d.ts +454 -0
  485. package/splitbutton/index.d.ts +306 -0
  486. package/splitter/index.d.ts +239 -0
  487. package/stepper/index.d.ts +297 -0
  488. package/steps/index.d.ts +152 -0
  489. package/styleclass/index.d.ts +115 -0
  490. package/table/index.d.ts +2700 -0
  491. package/tabs/index.d.ts +321 -0
  492. package/tag/index.d.ts +114 -0
  493. package/terminal/index.d.ts +134 -0
  494. package/textarea/index.d.ts +108 -0
  495. package/tieredmenu/index.d.ts +430 -0
  496. package/timeline/index.d.ts +170 -0
  497. package/toast/index.d.ts +320 -0
  498. package/togglebutton/index.d.ts +243 -0
  499. package/toggleswitch/index.d.ts +188 -0
  500. package/toolbar/index.d.ts +118 -0
  501. package/tooltip/index.d.ts +247 -0
  502. package/tree/index.d.ts +847 -0
  503. package/treeselect/index.d.ts +655 -0
  504. package/treetable/index.d.ts +1727 -0
  505. package/ts-helpers/index.d.ts +6 -0
  506. package/usestyle/index.d.ts +15 -0
  507. package/utils/index.d.ts +43 -0
@@ -0,0 +1,1621 @@
1
+ import * as i1 from '@angular/common';
2
+ import { CommonModule } from '@angular/common';
3
+ import * as i0 from '@angular/core';
4
+ import { Injectable, forwardRef, EventEmitter, inject, booleanAttribute, numberAttribute, ViewChild, ContentChildren, ContentChild, Output, Input, ViewEncapsulation, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
5
+ import { NG_VALUE_ACCESSOR, NgControl } from '@angular/forms';
6
+ import { getSelection } from '@primeuix/utils';
7
+ import { SharedModule, PrimeTemplate } from 'primeng/api';
8
+ import { AutoFocus } from 'primeng/autofocus';
9
+ import { BaseInput } from 'primeng/baseinput';
10
+ import { TimesIcon, AngleUpIcon, AngleDownIcon } from 'primeng/icons';
11
+ import { InputText } from 'primeng/inputtext';
12
+ import { style } from '@primeuix/styles/inputnumber';
13
+ import { BaseStyle } from 'primeng/base';
14
+
15
+ const theme = /*css*/ `
16
+ ${style}
17
+
18
+ /* For PrimeNG */
19
+ p-inputNumber.ng-invalid.ng-dirty > .p-inputtext,
20
+ p-input-number.ng-invalid.ng-dirty > .p-inputtext,
21
+ p-inputnumber.ng-invalid.ng-dirty > .p-inputtext {
22
+ border-color: dt('inputtext.invalid.border.color');
23
+ }
24
+
25
+ p-inputNumber.ng-invalid.ng-dirty > .p-inputtext:enabled:focus,
26
+ p-input-number.ng-invalid.ng-dirty > .p-inputtext:enabled:focus,
27
+ p-inputnumber.ng-invalid.ng-dirty > .p-inputtext:enabled:focus {
28
+ border-color: dt('inputtext.focus.border.color');
29
+ }
30
+
31
+ p-inputNumber.ng-invalid.ng-dirty > .p-inputtext::placeholder,
32
+ p-input-number.ng-invalid.ng-dirty > .p-inputtext::placeholder,
33
+ p-inputnumber.ng-invalid.ng-dirty > .p-inputtext::placeholder {
34
+ color: dt('inputtext.invalid.placeholder.color');
35
+ }
36
+ `;
37
+ const classes = {
38
+ root: ({ instance }) => [
39
+ 'p-inputnumber p-component p-inputwrapper',
40
+ {
41
+ 'p-inputwrapper-filled': instance.$filled() || instance.allowEmpty === false,
42
+ 'p-inputwrapper-focus': instance.focused,
43
+ 'p-inputnumber-stacked': instance.showButtons && instance.buttonLayout === 'stacked',
44
+ 'p-inputnumber-horizontal': instance.showButtons && instance.buttonLayout === 'horizontal',
45
+ 'p-inputnumber-vertical': instance.showButtons && instance.buttonLayout === 'vertical',
46
+ 'p-inputnumber-fluid': instance.hasFluid,
47
+ 'p-invalid': instance.invalid()
48
+ }
49
+ ],
50
+ pcInputText: 'p-inputnumber-input',
51
+ buttonGroup: 'p-inputnumber-button-group',
52
+ incrementButton: ({ instance }) => [
53
+ 'p-inputnumber-button p-inputnumber-increment-button',
54
+ {
55
+ 'p-disabled': instance.showButtons && instance.max() != null && instance.maxlength()
56
+ }
57
+ ],
58
+ decrementButton: ({ instance }) => [
59
+ 'p-inputnumber-button p-inputnumber-decrement-button',
60
+ {
61
+ 'p-disabled': instance.showButtons && instance.min() != null && instance.minlength()
62
+ }
63
+ ],
64
+ clearIcon: 'p-inputnumber-clear-icon'
65
+ };
66
+ class InputNumberStyle extends BaseStyle {
67
+ name = 'inputnumber';
68
+ theme = theme;
69
+ classes = classes;
70
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumberStyle, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
71
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumberStyle });
72
+ }
73
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumberStyle, decorators: [{
74
+ type: Injectable
75
+ }] });
76
+ /**
77
+ *
78
+ * InputNumber is an input component to provide numerical input.
79
+ *
80
+ * [Live Demo](https://www.primeng.org/inputnumber/)
81
+ *
82
+ * @module inputnumberstyle
83
+ *
84
+ */
85
+ var InputNumberClasses;
86
+ (function (InputNumberClasses) {
87
+ /**
88
+ * Class name of the root element
89
+ */
90
+ InputNumberClasses["root"] = "p-inputnumber";
91
+ /**
92
+ * Class name of the input element
93
+ */
94
+ InputNumberClasses["pcInputText"] = "p-inputnumber-input";
95
+ /**
96
+ * Class name of the button group element
97
+ */
98
+ InputNumberClasses["buttonGroup"] = "p-inputnumber-button-group";
99
+ /**
100
+ * Class name of the increment button element
101
+ */
102
+ InputNumberClasses["incrementButton"] = "p-inputnumber-increment-button";
103
+ /**
104
+ * Class name of the decrement button element
105
+ */
106
+ InputNumberClasses["decrementButton"] = "p-inputnumber-decrement-button";
107
+ /**
108
+ * Class name of the clear icon
109
+ */
110
+ InputNumberClasses["clearIcon"] = "p-autocomplete-clear-icon";
111
+ })(InputNumberClasses || (InputNumberClasses = {}));
112
+
113
+ const INPUTNUMBER_VALUE_ACCESSOR = {
114
+ provide: NG_VALUE_ACCESSOR,
115
+ useExisting: forwardRef(() => InputNumber),
116
+ multi: true
117
+ };
118
+ /**
119
+ * InputNumber is an input component to provide numerical input.
120
+ * @group Components
121
+ */
122
+ class InputNumber extends BaseInput {
123
+ injector;
124
+ /**
125
+ * Displays spinner buttons.
126
+ * @group Props
127
+ */
128
+ showButtons = false;
129
+ /**
130
+ * Whether to format the value.
131
+ * @group Props
132
+ */
133
+ format = true;
134
+ /**
135
+ * Layout of the buttons, valid values are "stacked" (default), "horizontal" and "vertical".
136
+ * @group Props
137
+ */
138
+ buttonLayout = 'stacked';
139
+ /**
140
+ * Identifier of the focus input to match a label defined for the component.
141
+ * @group Props
142
+ */
143
+ inputId;
144
+ /**
145
+ * Style class of the component.
146
+ * @deprecated since v20.0.0, use `class` instead.
147
+ * @group Props
148
+ */
149
+ styleClass;
150
+ /**
151
+ * Advisory information to display on input.
152
+ * @group Props
153
+ */
154
+ placeholder;
155
+ /**
156
+ * Specifies tab order of the element.
157
+ * @group Props
158
+ */
159
+ tabindex;
160
+ /**
161
+ * Title text of the input text.
162
+ * @group Props
163
+ */
164
+ title;
165
+ /**
166
+ * Specifies one or more IDs in the DOM that labels the input field.
167
+ * @group Props
168
+ */
169
+ ariaLabelledBy;
170
+ /**
171
+ * Specifies one or more IDs in the DOM that describes the input field.
172
+ * @group Props
173
+ */
174
+ ariaDescribedBy;
175
+ /**
176
+ * Used to define a string that labels the input element.
177
+ * @group Props
178
+ */
179
+ ariaLabel;
180
+ /**
181
+ * Used to indicate that user input is required on an element before a form can be submitted.
182
+ * @group Props
183
+ */
184
+ ariaRequired;
185
+ /**
186
+ * Used to define a string that autocomplete attribute the current element.
187
+ * @group Props
188
+ */
189
+ autocomplete;
190
+ /**
191
+ * Style class of the increment button.
192
+ * @group Props
193
+ */
194
+ incrementButtonClass;
195
+ /**
196
+ * Style class of the decrement button.
197
+ * @group Props
198
+ */
199
+ decrementButtonClass;
200
+ /**
201
+ * Style class of the increment button.
202
+ * @group Props
203
+ */
204
+ incrementButtonIcon;
205
+ /**
206
+ * Style class of the decrement button.
207
+ * @group Props
208
+ */
209
+ decrementButtonIcon;
210
+ /**
211
+ * When present, it specifies that an input field is read-only.
212
+ * @group Props
213
+ */
214
+ readonly;
215
+ /**
216
+ * Determines whether the input field is empty.
217
+ * @group Props
218
+ */
219
+ allowEmpty = true;
220
+ /**
221
+ * Locale to be used in formatting.
222
+ * @group Props
223
+ */
224
+ locale;
225
+ /**
226
+ * The locale matching algorithm to use. Possible values are "lookup" and "best fit"; the default is "best fit". See Locale Negotiation for details.
227
+ * @group Props
228
+ */
229
+ localeMatcher;
230
+ /**
231
+ * Defines the behavior of the component, valid values are "decimal" and "currency".
232
+ * @group Props
233
+ */
234
+ mode = 'decimal';
235
+ /**
236
+ * The currency to use in currency formatting. Possible values are the ISO 4217 currency codes, such as "USD" for the US dollar, "EUR" for the euro, or "CNY" for the Chinese RMB. There is no default value; if the style is "currency", the currency property must be provided.
237
+ * @group Props
238
+ */
239
+ currency;
240
+ /**
241
+ * How to display the currency in currency formatting. Possible values are "symbol" to use a localized currency symbol such as €, ü"code" to use the ISO currency code, "name" to use a localized currency name such as "dollar"; the default is "symbol".
242
+ * @group Props
243
+ */
244
+ currencyDisplay;
245
+ /**
246
+ * Whether to use grouping separators, such as thousands separators or thousand/lakh/crore separators.
247
+ * @group Props
248
+ */
249
+ useGrouping = true;
250
+ /**
251
+ * The minimum number of fraction digits to use. Possible values are from 0 to 20; the default for plain number and percent formatting is 0; the default for currency formatting is the number of minor unit digits provided by the ISO 4217 currency code list (2 if the list doesn't provide that information).
252
+ * @group Props
253
+ */
254
+ minFractionDigits;
255
+ /**
256
+ * The maximum number of fraction digits to use. Possible values are from 0 to 20; the default for plain number formatting is the larger of minimumFractionDigits and 3; the default for currency formatting is the larger of minimumFractionDigits and the number of minor unit digits provided by the ISO 4217 currency code list (2 if the list doesn't provide that information).
257
+ * @group Props
258
+ */
259
+ maxFractionDigits;
260
+ /**
261
+ * Text to display before the value.
262
+ * @group Props
263
+ */
264
+ prefix;
265
+ /**
266
+ * Text to display after the value.
267
+ * @group Props
268
+ */
269
+ suffix;
270
+ /**
271
+ * Inline style of the input field.
272
+ * @group Props
273
+ */
274
+ inputStyle;
275
+ /**
276
+ * Style class of the input field.
277
+ * @group Props
278
+ */
279
+ inputStyleClass;
280
+ /**
281
+ * When enabled, a clear icon is displayed to clear the value.
282
+ * @group Props
283
+ */
284
+ showClear = false;
285
+ /**
286
+ * When present, it specifies that the component should automatically get focus on load.
287
+ * @group Props
288
+ */
289
+ autofocus;
290
+ /**
291
+ * Callback to invoke on input.
292
+ * @param {InputNumberInputEvent} event - Custom input event.
293
+ * @group Emits
294
+ */
295
+ onInput = new EventEmitter();
296
+ /**
297
+ * Callback to invoke when the component receives focus.
298
+ * @param {Event} event - Browser event.
299
+ * @group Emits
300
+ */
301
+ onFocus = new EventEmitter();
302
+ /**
303
+ * Callback to invoke when the component loses focus.
304
+ * @param {Event} event - Browser event.
305
+ * @group Emits
306
+ */
307
+ onBlur = new EventEmitter();
308
+ /**
309
+ * Callback to invoke on input key press.
310
+ * @param {KeyboardEvent} event - Keyboard event.
311
+ * @group Emits
312
+ */
313
+ onKeyDown = new EventEmitter();
314
+ /**
315
+ * Callback to invoke when clear token is clicked.
316
+ * @group Emits
317
+ */
318
+ onClear = new EventEmitter();
319
+ /**
320
+ * Template of the clear icon.
321
+ * @group Templates
322
+ */
323
+ clearIconTemplate;
324
+ /**
325
+ * Template of the increment button icon.
326
+ * @group Templates
327
+ */
328
+ incrementButtonIconTemplate;
329
+ /**
330
+ * Template of the decrement button icon.
331
+ * @group Templates
332
+ */
333
+ decrementButtonIconTemplate;
334
+ templates;
335
+ input;
336
+ _clearIconTemplate;
337
+ _incrementButtonIconTemplate;
338
+ _decrementButtonIconTemplate;
339
+ value;
340
+ focused;
341
+ initialized;
342
+ groupChar = '';
343
+ prefixChar = '';
344
+ suffixChar = '';
345
+ isSpecialChar;
346
+ timer;
347
+ lastValue;
348
+ _numeral;
349
+ numberFormat;
350
+ _decimal;
351
+ _decimalChar;
352
+ _group;
353
+ _minusSign;
354
+ _currency;
355
+ _prefix;
356
+ _suffix;
357
+ _index;
358
+ _componentStyle = inject(InputNumberStyle);
359
+ ngControl = null;
360
+ constructor(injector) {
361
+ super();
362
+ this.injector = injector;
363
+ }
364
+ ngOnChanges(simpleChange) {
365
+ super.ngOnChanges(simpleChange);
366
+ const props = ['locale', 'localeMatcher', 'mode', 'currency', 'currencyDisplay', 'useGrouping', 'minFractionDigits', 'maxFractionDigits', 'prefix', 'suffix'];
367
+ if (props.some((p) => !!simpleChange[p])) {
368
+ this.updateConstructParser();
369
+ }
370
+ }
371
+ ngOnInit() {
372
+ super.ngOnInit();
373
+ this.ngControl = this.injector.get(NgControl, null, { optional: true });
374
+ this.constructParser();
375
+ this.initialized = true;
376
+ }
377
+ ngAfterContentInit() {
378
+ this.templates.forEach((item) => {
379
+ switch (item.getType()) {
380
+ case 'clearicon':
381
+ this._clearIconTemplate = item.template;
382
+ break;
383
+ case 'incrementbuttonicon':
384
+ this._incrementButtonIconTemplate = item.template;
385
+ break;
386
+ case 'decrementbuttonicon':
387
+ this._decrementButtonIconTemplate = item.template;
388
+ break;
389
+ }
390
+ });
391
+ }
392
+ getOptions() {
393
+ return {
394
+ localeMatcher: this.localeMatcher,
395
+ style: this.mode,
396
+ currency: this.currency,
397
+ currencyDisplay: this.currencyDisplay,
398
+ useGrouping: this.useGrouping,
399
+ minimumFractionDigits: this.minFractionDigits ?? undefined,
400
+ maximumFractionDigits: this.maxFractionDigits ?? undefined
401
+ };
402
+ }
403
+ constructParser() {
404
+ this.numberFormat = new Intl.NumberFormat(this.locale, this.getOptions());
405
+ const numerals = [...new Intl.NumberFormat(this.locale, { useGrouping: false }).format(9876543210)].reverse();
406
+ const index = new Map(numerals.map((d, i) => [d, i]));
407
+ this._numeral = new RegExp(`[${numerals.join('')}]`, 'g');
408
+ this._group = this.getGroupingExpression();
409
+ this._minusSign = this.getMinusSignExpression();
410
+ this._currency = this.getCurrencyExpression();
411
+ this._decimal = this.getDecimalExpression();
412
+ this._decimalChar = this.getDecimalChar();
413
+ this._suffix = this.getSuffixExpression();
414
+ this._prefix = this.getPrefixExpression();
415
+ this._index = (d) => index.get(d);
416
+ }
417
+ updateConstructParser() {
418
+ if (this.initialized) {
419
+ this.constructParser();
420
+ }
421
+ }
422
+ escapeRegExp(text) {
423
+ return text.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, '\\$&');
424
+ }
425
+ getDecimalExpression() {
426
+ const decimalChar = this.getDecimalChar();
427
+ return new RegExp(`[${decimalChar}]`, 'g');
428
+ }
429
+ getDecimalChar() {
430
+ const formatter = new Intl.NumberFormat(this.locale, { ...this.getOptions(), useGrouping: false });
431
+ return formatter
432
+ .format(1.1)
433
+ .replace(this._currency, '')
434
+ .trim()
435
+ .replace(this._numeral, '');
436
+ }
437
+ getGroupingExpression() {
438
+ const formatter = new Intl.NumberFormat(this.locale, { useGrouping: true });
439
+ this.groupChar = formatter.format(1000000).trim().replace(this._numeral, '').charAt(0);
440
+ return new RegExp(`[${this.groupChar}]`, 'g');
441
+ }
442
+ getMinusSignExpression() {
443
+ const formatter = new Intl.NumberFormat(this.locale, { useGrouping: false });
444
+ return new RegExp(`[${formatter.format(-1).trim().replace(this._numeral, '')}]`, 'g');
445
+ }
446
+ getCurrencyExpression() {
447
+ if (this.currency) {
448
+ const formatter = new Intl.NumberFormat(this.locale, {
449
+ style: 'currency',
450
+ currency: this.currency,
451
+ currencyDisplay: this.currencyDisplay,
452
+ minimumFractionDigits: 0,
453
+ maximumFractionDigits: 0
454
+ });
455
+ return new RegExp(`[${formatter.format(1).replace(/\s/g, '').replace(this._numeral, '').replace(this._group, '')}]`, 'g');
456
+ }
457
+ return new RegExp(`[]`, 'g');
458
+ }
459
+ getPrefixExpression() {
460
+ if (this.prefix) {
461
+ this.prefixChar = this.prefix;
462
+ }
463
+ else {
464
+ const formatter = new Intl.NumberFormat(this.locale, {
465
+ style: this.mode,
466
+ currency: this.currency,
467
+ currencyDisplay: this.currencyDisplay
468
+ });
469
+ this.prefixChar = formatter.format(1).split('1')[0];
470
+ }
471
+ return new RegExp(`${this.escapeRegExp(this.prefixChar || '')}`, 'g');
472
+ }
473
+ getSuffixExpression() {
474
+ if (this.suffix) {
475
+ this.suffixChar = this.suffix;
476
+ }
477
+ else {
478
+ const formatter = new Intl.NumberFormat(this.locale, {
479
+ style: this.mode,
480
+ currency: this.currency,
481
+ currencyDisplay: this.currencyDisplay,
482
+ minimumFractionDigits: 0,
483
+ maximumFractionDigits: 0
484
+ });
485
+ this.suffixChar = formatter.format(1).split('1')[1];
486
+ }
487
+ return new RegExp(`${this.escapeRegExp(this.suffixChar || '')}`, 'g');
488
+ }
489
+ formatValue(value) {
490
+ if (value != null) {
491
+ if (value === '-') {
492
+ // Minus sign
493
+ return value;
494
+ }
495
+ if (this.format) {
496
+ let formatter = new Intl.NumberFormat(this.locale, this.getOptions());
497
+ let formattedValue = formatter.format(value);
498
+ if (this.prefix && value != this.prefix) {
499
+ formattedValue = this.prefix + formattedValue;
500
+ }
501
+ if (this.suffix && value != this.suffix) {
502
+ formattedValue = formattedValue + this.suffix;
503
+ }
504
+ return formattedValue;
505
+ }
506
+ return value.toString();
507
+ }
508
+ return '';
509
+ }
510
+ parseValue(text) {
511
+ const suffixRegex = new RegExp(this._suffix, '');
512
+ const prefixRegex = new RegExp(this._prefix, '');
513
+ const currencyRegex = new RegExp(this._currency, '');
514
+ let filteredText = text
515
+ .replace(suffixRegex, '')
516
+ .replace(prefixRegex, '')
517
+ .trim()
518
+ .replace(/\s/g, '')
519
+ .replace(currencyRegex, '')
520
+ .replace(this._group, '')
521
+ .replace(this._minusSign, '-')
522
+ .replace(this._decimal, '.')
523
+ .replace(this._numeral, this._index);
524
+ if (filteredText) {
525
+ if (filteredText === '-')
526
+ // Minus sign
527
+ return filteredText;
528
+ let parsedValue = +filteredText;
529
+ return isNaN(parsedValue) ? null : parsedValue;
530
+ }
531
+ return null;
532
+ }
533
+ repeat(event, interval, dir) {
534
+ if (this.readonly) {
535
+ return;
536
+ }
537
+ let i = interval || 500;
538
+ this.clearTimer();
539
+ this.timer = setTimeout(() => {
540
+ this.repeat(event, 40, dir);
541
+ }, i);
542
+ this.spin(event, dir);
543
+ }
544
+ spin(event, dir) {
545
+ let step = (this.step() ?? 1) * dir;
546
+ let currentValue = this.parseValue(this.input?.nativeElement.value) || 0;
547
+ let newValue = this.validateValue(currentValue + step);
548
+ if (this.maxlength() && this.maxlength() < this.formatValue(newValue).length) {
549
+ return;
550
+ }
551
+ this.updateInput(newValue, null, 'spin', null);
552
+ this.updateModel(event, newValue);
553
+ this.handleOnInput(event, currentValue, newValue);
554
+ }
555
+ clear() {
556
+ this.value = null;
557
+ this.onModelChange(this.value);
558
+ this.onClear.emit();
559
+ }
560
+ onUpButtonMouseDown(event) {
561
+ if (event.button === 2) {
562
+ this.clearTimer();
563
+ return;
564
+ }
565
+ if (!this.$disabled()) {
566
+ this.input?.nativeElement.focus();
567
+ this.repeat(event, null, 1);
568
+ event.preventDefault();
569
+ }
570
+ }
571
+ onUpButtonMouseUp() {
572
+ if (!this.$disabled()) {
573
+ this.clearTimer();
574
+ }
575
+ }
576
+ onUpButtonMouseLeave() {
577
+ if (!this.$disabled()) {
578
+ this.clearTimer();
579
+ }
580
+ }
581
+ onUpButtonKeyDown(event) {
582
+ if (event.keyCode === 32 || event.keyCode === 13) {
583
+ this.repeat(event, null, 1);
584
+ }
585
+ }
586
+ onUpButtonKeyUp() {
587
+ if (!this.$disabled()) {
588
+ this.clearTimer();
589
+ }
590
+ }
591
+ onDownButtonMouseDown(event) {
592
+ if (event.button === 2) {
593
+ this.clearTimer();
594
+ return;
595
+ }
596
+ if (!this.$disabled()) {
597
+ this.input?.nativeElement.focus();
598
+ this.repeat(event, null, -1);
599
+ event.preventDefault();
600
+ }
601
+ }
602
+ onDownButtonMouseUp() {
603
+ if (!this.$disabled()) {
604
+ this.clearTimer();
605
+ }
606
+ }
607
+ onDownButtonMouseLeave() {
608
+ if (!this.$disabled()) {
609
+ this.clearTimer();
610
+ }
611
+ }
612
+ onDownButtonKeyUp() {
613
+ if (!this.$disabled()) {
614
+ this.clearTimer();
615
+ }
616
+ }
617
+ onDownButtonKeyDown(event) {
618
+ if (event.keyCode === 32 || event.keyCode === 13) {
619
+ this.repeat(event, null, -1);
620
+ }
621
+ }
622
+ onUserInput(event) {
623
+ if (this.readonly) {
624
+ return;
625
+ }
626
+ if (this.isSpecialChar) {
627
+ event.target.value = this.lastValue;
628
+ }
629
+ this.isSpecialChar = false;
630
+ }
631
+ onInputKeyDown(event) {
632
+ if (this.readonly) {
633
+ return;
634
+ }
635
+ this.lastValue = event.target.value;
636
+ if (event.shiftKey || event.altKey) {
637
+ this.isSpecialChar = true;
638
+ return;
639
+ }
640
+ let selectionStart = event.target.selectionStart;
641
+ let selectionEnd = event.target.selectionEnd;
642
+ let inputValue = event.target.value;
643
+ let newValueStr = null;
644
+ if (event.altKey) {
645
+ event.preventDefault();
646
+ }
647
+ switch (event.key) {
648
+ case 'ArrowUp':
649
+ this.spin(event, 1);
650
+ event.preventDefault();
651
+ break;
652
+ case 'ArrowDown':
653
+ this.spin(event, -1);
654
+ event.preventDefault();
655
+ break;
656
+ case 'ArrowLeft':
657
+ for (let index = selectionStart; index <= inputValue.length; index++) {
658
+ const previousCharIndex = index === 0 ? 0 : index - 1;
659
+ if (this.isNumeralChar(inputValue.charAt(previousCharIndex))) {
660
+ this.input.nativeElement.setSelectionRange(index, index);
661
+ break;
662
+ }
663
+ }
664
+ break;
665
+ case 'ArrowRight':
666
+ for (let index = selectionEnd; index >= 0; index--) {
667
+ if (this.isNumeralChar(inputValue.charAt(index))) {
668
+ this.input.nativeElement.setSelectionRange(index, index);
669
+ break;
670
+ }
671
+ }
672
+ break;
673
+ case 'Tab':
674
+ case 'Enter':
675
+ newValueStr = this.validateValue(this.parseValue(this.input.nativeElement.value));
676
+ this.input.nativeElement.value = this.formatValue(newValueStr);
677
+ this.input.nativeElement.setAttribute('aria-valuenow', newValueStr);
678
+ this.updateModel(event, newValueStr);
679
+ break;
680
+ case 'Backspace': {
681
+ event.preventDefault();
682
+ if (selectionStart === selectionEnd) {
683
+ if ((selectionStart == 1 && this.prefix) || (selectionStart == inputValue.length && this.suffix)) {
684
+ break;
685
+ }
686
+ const deleteChar = inputValue.charAt(selectionStart - 1);
687
+ const { decimalCharIndex, decimalCharIndexWithoutPrefix } = this.getDecimalCharIndexes(inputValue);
688
+ if (this.isNumeralChar(deleteChar)) {
689
+ const decimalLength = this.getDecimalLength(inputValue);
690
+ if (this._group.test(deleteChar)) {
691
+ this._group.lastIndex = 0;
692
+ newValueStr = inputValue.slice(0, selectionStart - 2) + inputValue.slice(selectionStart - 1);
693
+ }
694
+ else if (this._decimal.test(deleteChar)) {
695
+ this._decimal.lastIndex = 0;
696
+ if (decimalLength) {
697
+ this.input?.nativeElement.setSelectionRange(selectionStart - 1, selectionStart - 1);
698
+ }
699
+ else {
700
+ newValueStr = inputValue.slice(0, selectionStart - 1) + inputValue.slice(selectionStart);
701
+ }
702
+ }
703
+ else if (decimalCharIndex > 0 && selectionStart > decimalCharIndex) {
704
+ const insertedText = this.isDecimalMode() && (this.minFractionDigits || 0) < decimalLength ? '' : '0';
705
+ newValueStr = inputValue.slice(0, selectionStart - 1) + insertedText + inputValue.slice(selectionStart);
706
+ }
707
+ else if (decimalCharIndexWithoutPrefix === 1) {
708
+ newValueStr = inputValue.slice(0, selectionStart - 1) + '0' + inputValue.slice(selectionStart);
709
+ newValueStr = this.parseValue(newValueStr) > 0 ? newValueStr : '';
710
+ }
711
+ else {
712
+ newValueStr = inputValue.slice(0, selectionStart - 1) + inputValue.slice(selectionStart);
713
+ }
714
+ }
715
+ else if (this.mode === 'currency' && deleteChar.search(this._currency) != -1) {
716
+ newValueStr = inputValue.slice(1);
717
+ }
718
+ this.updateValue(event, newValueStr, null, 'delete-single');
719
+ }
720
+ else {
721
+ newValueStr = this.deleteRange(inputValue, selectionStart, selectionEnd);
722
+ this.updateValue(event, newValueStr, null, 'delete-range');
723
+ }
724
+ break;
725
+ }
726
+ case 'Delete':
727
+ event.preventDefault();
728
+ if (selectionStart === selectionEnd) {
729
+ if ((selectionStart == 0 && this.prefix) || (selectionStart == inputValue.length - 1 && this.suffix)) {
730
+ break;
731
+ }
732
+ const deleteChar = inputValue.charAt(selectionStart);
733
+ const { decimalCharIndex, decimalCharIndexWithoutPrefix } = this.getDecimalCharIndexes(inputValue);
734
+ if (this.isNumeralChar(deleteChar)) {
735
+ const decimalLength = this.getDecimalLength(inputValue);
736
+ if (this._group.test(deleteChar)) {
737
+ this._group.lastIndex = 0;
738
+ newValueStr = inputValue.slice(0, selectionStart) + inputValue.slice(selectionStart + 2);
739
+ }
740
+ else if (this._decimal.test(deleteChar)) {
741
+ this._decimal.lastIndex = 0;
742
+ if (decimalLength) {
743
+ this.input?.nativeElement.setSelectionRange(selectionStart + 1, selectionStart + 1);
744
+ }
745
+ else {
746
+ newValueStr = inputValue.slice(0, selectionStart) + inputValue.slice(selectionStart + 1);
747
+ }
748
+ }
749
+ else if (decimalCharIndex > 0 && selectionStart > decimalCharIndex) {
750
+ const insertedText = this.isDecimalMode() && (this.minFractionDigits || 0) < decimalLength ? '' : '0';
751
+ newValueStr = inputValue.slice(0, selectionStart) + insertedText + inputValue.slice(selectionStart + 1);
752
+ }
753
+ else if (decimalCharIndexWithoutPrefix === 1) {
754
+ newValueStr = inputValue.slice(0, selectionStart) + '0' + inputValue.slice(selectionStart + 1);
755
+ newValueStr = this.parseValue(newValueStr) > 0 ? newValueStr : '';
756
+ }
757
+ else {
758
+ newValueStr = inputValue.slice(0, selectionStart) + inputValue.slice(selectionStart + 1);
759
+ }
760
+ }
761
+ this.updateValue(event, newValueStr, null, 'delete-back-single');
762
+ }
763
+ else {
764
+ newValueStr = this.deleteRange(inputValue, selectionStart, selectionEnd);
765
+ this.updateValue(event, newValueStr, null, 'delete-range');
766
+ }
767
+ break;
768
+ case 'Home':
769
+ if (this.min()) {
770
+ this.updateModel(event, this.min());
771
+ event.preventDefault();
772
+ }
773
+ break;
774
+ case 'End':
775
+ if (this.max()) {
776
+ this.updateModel(event, this.max());
777
+ event.preventDefault();
778
+ }
779
+ break;
780
+ default:
781
+ break;
782
+ }
783
+ this.onKeyDown.emit(event);
784
+ }
785
+ onInputKeyPress(event) {
786
+ if (this.readonly) {
787
+ return;
788
+ }
789
+ let code = event.which || event.keyCode;
790
+ let char = String.fromCharCode(code);
791
+ let isDecimalSign = this.isDecimalSign(char);
792
+ const isMinusSign = this.isMinusSign(char);
793
+ if (code != 13) {
794
+ event.preventDefault();
795
+ }
796
+ if (!isDecimalSign && event.code === 'NumpadDecimal') {
797
+ isDecimalSign = true;
798
+ char = this._decimalChar;
799
+ code = char.charCodeAt(0);
800
+ }
801
+ const { value, selectionStart, selectionEnd } = this.input.nativeElement;
802
+ const newValue = this.parseValue(value + char);
803
+ const newValueStr = newValue != null ? newValue.toString() : '';
804
+ const selectedValue = value.substring(selectionStart, selectionEnd);
805
+ const selectedValueParsed = this.parseValue(selectedValue);
806
+ const selectedValueStr = selectedValueParsed != null ? selectedValueParsed.toString() : '';
807
+ if (selectionStart !== selectionEnd && selectedValueStr.length > 0) {
808
+ this.insert(event, char, { isDecimalSign, isMinusSign });
809
+ return;
810
+ }
811
+ if (this.maxlength() && newValueStr.length > this.maxlength()) {
812
+ return;
813
+ }
814
+ if ((48 <= code && code <= 57) || isMinusSign || isDecimalSign) {
815
+ this.insert(event, char, { isDecimalSign, isMinusSign });
816
+ }
817
+ }
818
+ onPaste(event) {
819
+ if (!this.$disabled() && !this.readonly) {
820
+ event.preventDefault();
821
+ let data = (event.clipboardData || this.document.defaultView['clipboardData']).getData('Text');
822
+ if (this.inputId === 'integeronly' && /[^\d-]/.test(data)) {
823
+ return;
824
+ }
825
+ if (data) {
826
+ if (this.maxlength()) {
827
+ data = data.toString().substring(0, this.maxlength());
828
+ }
829
+ let filteredData = this.parseValue(data);
830
+ if (filteredData != null) {
831
+ this.insert(event, filteredData.toString());
832
+ }
833
+ }
834
+ }
835
+ }
836
+ allowMinusSign() {
837
+ return this.min() == null || this.min() < 0;
838
+ }
839
+ isMinusSign(char) {
840
+ if (this._minusSign.test(char) || char === '-') {
841
+ this._minusSign.lastIndex = 0;
842
+ return true;
843
+ }
844
+ return false;
845
+ }
846
+ isDecimalSign(char) {
847
+ if (this._decimal.test(char)) {
848
+ this._decimal.lastIndex = 0;
849
+ return true;
850
+ }
851
+ return false;
852
+ }
853
+ isDecimalMode() {
854
+ return this.mode === 'decimal';
855
+ }
856
+ getDecimalCharIndexes(val) {
857
+ let decimalCharIndex = val.search(this._decimal);
858
+ this._decimal.lastIndex = 0;
859
+ const filteredVal = val
860
+ .replace(this._prefix, '')
861
+ .trim()
862
+ .replace(/\s/g, '')
863
+ .replace(this._currency, '');
864
+ const decimalCharIndexWithoutPrefix = filteredVal.search(this._decimal);
865
+ this._decimal.lastIndex = 0;
866
+ return { decimalCharIndex, decimalCharIndexWithoutPrefix };
867
+ }
868
+ getCharIndexes(val) {
869
+ const decimalCharIndex = val.search(this._decimal);
870
+ this._decimal.lastIndex = 0;
871
+ const minusCharIndex = val.search(this._minusSign);
872
+ this._minusSign.lastIndex = 0;
873
+ const suffixCharIndex = val.search(this._suffix);
874
+ this._suffix.lastIndex = 0;
875
+ const currencyCharIndex = val.search(this._currency);
876
+ this._currency.lastIndex = 0;
877
+ return { decimalCharIndex, minusCharIndex, suffixCharIndex, currencyCharIndex };
878
+ }
879
+ insert(event, text, sign = { isDecimalSign: false, isMinusSign: false }) {
880
+ const minusCharIndexOnText = text.search(this._minusSign);
881
+ this._minusSign.lastIndex = 0;
882
+ if (!this.allowMinusSign() && minusCharIndexOnText !== -1) {
883
+ return;
884
+ }
885
+ let selectionStart = this.input?.nativeElement.selectionStart;
886
+ let selectionEnd = this.input?.nativeElement.selectionEnd;
887
+ let inputValue = this.input?.nativeElement.value.trim();
888
+ const { decimalCharIndex, minusCharIndex, suffixCharIndex, currencyCharIndex } = this.getCharIndexes(inputValue);
889
+ let newValueStr;
890
+ if (sign.isMinusSign) {
891
+ if (selectionStart === 0) {
892
+ newValueStr = inputValue;
893
+ if (minusCharIndex === -1 || selectionEnd !== 0) {
894
+ newValueStr = this.insertText(inputValue, text, 0, selectionEnd);
895
+ }
896
+ this.updateValue(event, newValueStr, text, 'insert');
897
+ }
898
+ }
899
+ else if (sign.isDecimalSign) {
900
+ if (decimalCharIndex > 0 && selectionStart === decimalCharIndex) {
901
+ this.updateValue(event, inputValue, text, 'insert');
902
+ }
903
+ else if (decimalCharIndex > selectionStart && decimalCharIndex < selectionEnd) {
904
+ newValueStr = this.insertText(inputValue, text, selectionStart, selectionEnd);
905
+ this.updateValue(event, newValueStr, text, 'insert');
906
+ }
907
+ else if (decimalCharIndex === -1 && this.maxFractionDigits) {
908
+ newValueStr = this.insertText(inputValue, text, selectionStart, selectionEnd);
909
+ this.updateValue(event, newValueStr, text, 'insert');
910
+ }
911
+ }
912
+ else {
913
+ const maxFractionDigits = this.numberFormat.resolvedOptions().maximumFractionDigits;
914
+ const operation = selectionStart !== selectionEnd ? 'range-insert' : 'insert';
915
+ if (decimalCharIndex > 0 && selectionStart > decimalCharIndex) {
916
+ if (selectionStart + text.length - (decimalCharIndex + 1) <= maxFractionDigits) {
917
+ const charIndex = currencyCharIndex >= selectionStart ? currencyCharIndex - 1 : suffixCharIndex >= selectionStart ? suffixCharIndex : inputValue.length;
918
+ newValueStr = inputValue.slice(0, selectionStart) + text + inputValue.slice(selectionStart + text.length, charIndex) + inputValue.slice(charIndex);
919
+ this.updateValue(event, newValueStr, text, operation);
920
+ }
921
+ }
922
+ else {
923
+ newValueStr = this.insertText(inputValue, text, selectionStart, selectionEnd);
924
+ this.updateValue(event, newValueStr, text, operation);
925
+ }
926
+ }
927
+ }
928
+ insertText(value, text, start, end) {
929
+ let textSplit = text === '.' ? text : text.split('.');
930
+ if (textSplit.length === 2) {
931
+ const decimalCharIndex = value.slice(start, end).search(this._decimal);
932
+ this._decimal.lastIndex = 0;
933
+ return decimalCharIndex > 0 ? value.slice(0, start) + this.formatValue(text) + value.slice(end) : value || this.formatValue(text);
934
+ }
935
+ else if (end - start === value.length) {
936
+ return this.formatValue(text);
937
+ }
938
+ else if (start === 0) {
939
+ return text + value.slice(end);
940
+ }
941
+ else if (end === value.length) {
942
+ return value.slice(0, start) + text;
943
+ }
944
+ else {
945
+ return value.slice(0, start) + text + value.slice(end);
946
+ }
947
+ }
948
+ deleteRange(value, start, end) {
949
+ let newValueStr;
950
+ if (end - start === value.length)
951
+ newValueStr = '';
952
+ else if (start === 0)
953
+ newValueStr = value.slice(end);
954
+ else if (end === value.length)
955
+ newValueStr = value.slice(0, start);
956
+ else
957
+ newValueStr = value.slice(0, start) + value.slice(end);
958
+ return newValueStr;
959
+ }
960
+ initCursor() {
961
+ let selectionStart = this.input?.nativeElement.selectionStart;
962
+ let selectionEnd = this.input?.nativeElement.selectionEnd;
963
+ let inputValue = this.input?.nativeElement.value;
964
+ let valueLength = inputValue.length;
965
+ let index = null;
966
+ // remove prefix
967
+ let prefixLength = (this.prefixChar || '').length;
968
+ inputValue = inputValue.replace(this._prefix, '');
969
+ // Will allow selecting whole prefix. But not a part of it.
970
+ // Negative values will trigger clauses after this to fix the cursor position.
971
+ if (selectionStart === selectionEnd || selectionStart !== 0 || selectionEnd < prefixLength) {
972
+ selectionStart -= prefixLength;
973
+ }
974
+ let char = inputValue.charAt(selectionStart);
975
+ if (this.isNumeralChar(char)) {
976
+ return selectionStart + prefixLength;
977
+ }
978
+ //left
979
+ let i = selectionStart - 1;
980
+ while (i >= 0) {
981
+ char = inputValue.charAt(i);
982
+ if (this.isNumeralChar(char)) {
983
+ index = i + prefixLength;
984
+ break;
985
+ }
986
+ else {
987
+ i--;
988
+ }
989
+ }
990
+ if (index !== null) {
991
+ this.input?.nativeElement.setSelectionRange(index + 1, index + 1);
992
+ }
993
+ else {
994
+ i = selectionStart;
995
+ while (i < valueLength) {
996
+ char = inputValue.charAt(i);
997
+ if (this.isNumeralChar(char)) {
998
+ index = i + prefixLength;
999
+ break;
1000
+ }
1001
+ else {
1002
+ i++;
1003
+ }
1004
+ }
1005
+ if (index !== null) {
1006
+ this.input?.nativeElement.setSelectionRange(index, index);
1007
+ }
1008
+ }
1009
+ return index || 0;
1010
+ }
1011
+ onInputClick() {
1012
+ const currentValue = this.input?.nativeElement.value;
1013
+ if (!this.readonly && currentValue !== getSelection()) {
1014
+ this.initCursor();
1015
+ }
1016
+ }
1017
+ isNumeralChar(char) {
1018
+ if (char.length === 1 && (this._numeral.test(char) || this._decimal.test(char) || this._group.test(char) || this._minusSign.test(char))) {
1019
+ this.resetRegex();
1020
+ return true;
1021
+ }
1022
+ return false;
1023
+ }
1024
+ resetRegex() {
1025
+ this._numeral.lastIndex = 0;
1026
+ this._decimal.lastIndex = 0;
1027
+ this._group.lastIndex = 0;
1028
+ this._minusSign.lastIndex = 0;
1029
+ }
1030
+ updateValue(event, valueStr, insertedValueStr, operation) {
1031
+ let currentValue = this.input?.nativeElement.value;
1032
+ let newValue = null;
1033
+ if (valueStr != null) {
1034
+ newValue = this.parseValue(valueStr);
1035
+ newValue = !newValue && !this.allowEmpty ? 0 : newValue;
1036
+ this.updateInput(newValue, insertedValueStr, operation, valueStr);
1037
+ this.handleOnInput(event, currentValue, newValue);
1038
+ }
1039
+ }
1040
+ handleOnInput(event, currentValue, newValue) {
1041
+ if (this.isValueChanged(currentValue, newValue)) {
1042
+ this.input.nativeElement.value = this.formatValue(newValue);
1043
+ this.input?.nativeElement.setAttribute('aria-valuenow', newValue);
1044
+ this.updateModel(event, newValue);
1045
+ this.onInput.emit({ originalEvent: event, value: newValue, formattedValue: currentValue });
1046
+ }
1047
+ }
1048
+ isValueChanged(currentValue, newValue) {
1049
+ if (newValue === null && currentValue !== null) {
1050
+ return true;
1051
+ }
1052
+ if (newValue != null) {
1053
+ let parsedCurrentValue = typeof currentValue === 'string' ? this.parseValue(currentValue) : currentValue;
1054
+ return newValue !== parsedCurrentValue;
1055
+ }
1056
+ return false;
1057
+ }
1058
+ validateValue(value) {
1059
+ if (value === '-' || value == null) {
1060
+ return null;
1061
+ }
1062
+ if (this.min() != null && value < this.min()) {
1063
+ return this.min();
1064
+ }
1065
+ if (this.max() != null && value > this.max()) {
1066
+ return this.max();
1067
+ }
1068
+ return value;
1069
+ }
1070
+ updateInput(value, insertedValueStr, operation, valueStr) {
1071
+ insertedValueStr = insertedValueStr || '';
1072
+ let inputValue = this.input?.nativeElement.value;
1073
+ let newValue = this.formatValue(value);
1074
+ let currentLength = inputValue.length;
1075
+ if (newValue !== valueStr) {
1076
+ newValue = this.concatValues(newValue, valueStr);
1077
+ }
1078
+ if (currentLength === 0) {
1079
+ this.input.nativeElement.value = newValue;
1080
+ this.input.nativeElement.setSelectionRange(0, 0);
1081
+ const index = this.initCursor();
1082
+ const selectionEnd = index + insertedValueStr.length;
1083
+ this.input.nativeElement.setSelectionRange(selectionEnd, selectionEnd);
1084
+ }
1085
+ else {
1086
+ let selectionStart = this.input.nativeElement.selectionStart;
1087
+ let selectionEnd = this.input.nativeElement.selectionEnd;
1088
+ if (this.maxlength() && newValue.length > this.maxlength()) {
1089
+ newValue = newValue.slice(0, this.maxlength());
1090
+ selectionStart = Math.min(selectionStart, this.maxlength());
1091
+ selectionEnd = Math.min(selectionEnd, this.maxlength());
1092
+ }
1093
+ if (this.maxlength() && this.maxlength() < newValue.length) {
1094
+ return;
1095
+ }
1096
+ this.input.nativeElement.value = newValue;
1097
+ let newLength = newValue.length;
1098
+ if (operation === 'range-insert') {
1099
+ const startValue = this.parseValue((inputValue || '').slice(0, selectionStart));
1100
+ const startValueStr = startValue !== null ? startValue.toString() : '';
1101
+ const startExpr = startValueStr.split('').join(`(${this.groupChar})?`);
1102
+ const sRegex = new RegExp(startExpr, 'g');
1103
+ sRegex.test(newValue);
1104
+ const tExpr = insertedValueStr.split('').join(`(${this.groupChar})?`);
1105
+ const tRegex = new RegExp(tExpr, 'g');
1106
+ tRegex.test(newValue.slice(sRegex.lastIndex));
1107
+ selectionEnd = sRegex.lastIndex + tRegex.lastIndex;
1108
+ this.input.nativeElement.setSelectionRange(selectionEnd, selectionEnd);
1109
+ }
1110
+ else if (newLength === currentLength) {
1111
+ if (operation === 'insert' || operation === 'delete-back-single')
1112
+ this.input.nativeElement.setSelectionRange(selectionEnd + 1, selectionEnd + 1);
1113
+ else if (operation === 'delete-single')
1114
+ this.input.nativeElement.setSelectionRange(selectionEnd - 1, selectionEnd - 1);
1115
+ else if (operation === 'delete-range' || operation === 'spin')
1116
+ this.input.nativeElement.setSelectionRange(selectionEnd, selectionEnd);
1117
+ }
1118
+ else if (operation === 'delete-back-single') {
1119
+ let prevChar = inputValue.charAt(selectionEnd - 1);
1120
+ let nextChar = inputValue.charAt(selectionEnd);
1121
+ let diff = currentLength - newLength;
1122
+ let isGroupChar = this._group.test(nextChar);
1123
+ if (isGroupChar && diff === 1) {
1124
+ selectionEnd += 1;
1125
+ }
1126
+ else if (!isGroupChar && this.isNumeralChar(prevChar)) {
1127
+ selectionEnd += -1 * diff + 1;
1128
+ }
1129
+ this._group.lastIndex = 0;
1130
+ this.input.nativeElement.setSelectionRange(selectionEnd, selectionEnd);
1131
+ }
1132
+ else if (inputValue === '-' && operation === 'insert') {
1133
+ this.input.nativeElement.setSelectionRange(0, 0);
1134
+ const index = this.initCursor();
1135
+ const selectionEnd = index + insertedValueStr.length + 1;
1136
+ this.input.nativeElement.setSelectionRange(selectionEnd, selectionEnd);
1137
+ }
1138
+ else {
1139
+ selectionEnd = selectionEnd + (newLength - currentLength);
1140
+ this.input.nativeElement.setSelectionRange(selectionEnd, selectionEnd);
1141
+ }
1142
+ }
1143
+ this.input.nativeElement.setAttribute('aria-valuenow', value);
1144
+ }
1145
+ concatValues(val1, val2) {
1146
+ if (val1 && val2) {
1147
+ let decimalCharIndex = val2.search(this._decimal);
1148
+ this._decimal.lastIndex = 0;
1149
+ if (this.suffixChar) {
1150
+ return decimalCharIndex !== -1 ? val1.replace(this.suffixChar, '').split(this._decimal)[0] + val2.replace(this.suffixChar, '').slice(decimalCharIndex) + this.suffixChar : val1;
1151
+ }
1152
+ else {
1153
+ return decimalCharIndex !== -1 ? val1.split(this._decimal)[0] + val2.slice(decimalCharIndex) : val1;
1154
+ }
1155
+ }
1156
+ return val1;
1157
+ }
1158
+ getDecimalLength(value) {
1159
+ if (value) {
1160
+ const valueSplit = value.split(this._decimal);
1161
+ if (valueSplit.length === 2) {
1162
+ return valueSplit[1]
1163
+ .replace(this._suffix, '')
1164
+ .trim()
1165
+ .replace(/\s/g, '')
1166
+ .replace(this._currency, '').length;
1167
+ }
1168
+ }
1169
+ return 0;
1170
+ }
1171
+ onInputFocus(event) {
1172
+ this.focused = true;
1173
+ this.onFocus.emit(event);
1174
+ }
1175
+ onInputBlur(event) {
1176
+ this.focused = false;
1177
+ const newValueNumber = this.validateValue(this.parseValue(this.input.nativeElement.value));
1178
+ const newValueString = newValueNumber?.toString();
1179
+ this.input.nativeElement.value = this.formatValue(newValueString);
1180
+ this.input.nativeElement.setAttribute('aria-valuenow', newValueString);
1181
+ this.updateModel(event, newValueNumber);
1182
+ this.onModelTouched();
1183
+ this.onBlur.emit(event);
1184
+ }
1185
+ formattedValue() {
1186
+ const val = !this.value && !this.allowEmpty ? 0 : this.value;
1187
+ return this.formatValue(val);
1188
+ }
1189
+ updateModel(event, value) {
1190
+ const isBlurUpdateOnMode = this.ngControl?.control?.updateOn === 'blur';
1191
+ if (this.value !== value) {
1192
+ this.value = value;
1193
+ if (!(isBlurUpdateOnMode && this.focused)) {
1194
+ this.onModelChange(value);
1195
+ }
1196
+ }
1197
+ else if (isBlurUpdateOnMode) {
1198
+ this.onModelChange(value);
1199
+ }
1200
+ }
1201
+ /**
1202
+ * @override
1203
+ *
1204
+ * @see {@link BaseEditableHolder.writeControlValue}
1205
+ * Writes the value to the control.
1206
+ */
1207
+ writeControlValue(value, setModelValue) {
1208
+ this.value = value ? Number(value) : value;
1209
+ setModelValue(value);
1210
+ this.cd.markForCheck();
1211
+ }
1212
+ clearTimer() {
1213
+ if (this.timer) {
1214
+ clearInterval(this.timer);
1215
+ }
1216
+ }
1217
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumber, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
1218
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "16.1.0", version: "20.2.4", type: InputNumber, isStandalone: true, selector: "p-inputNumber, p-inputnumber, p-input-number", inputs: { showButtons: ["showButtons", "showButtons", booleanAttribute], format: ["format", "format", booleanAttribute], buttonLayout: "buttonLayout", inputId: "inputId", styleClass: "styleClass", placeholder: "placeholder", tabindex: ["tabindex", "tabindex", numberAttribute], title: "title", ariaLabelledBy: "ariaLabelledBy", ariaDescribedBy: "ariaDescribedBy", ariaLabel: "ariaLabel", ariaRequired: ["ariaRequired", "ariaRequired", booleanAttribute], autocomplete: "autocomplete", incrementButtonClass: "incrementButtonClass", decrementButtonClass: "decrementButtonClass", incrementButtonIcon: "incrementButtonIcon", decrementButtonIcon: "decrementButtonIcon", readonly: ["readonly", "readonly", booleanAttribute], allowEmpty: ["allowEmpty", "allowEmpty", booleanAttribute], locale: "locale", localeMatcher: "localeMatcher", mode: "mode", currency: "currency", currencyDisplay: "currencyDisplay", useGrouping: ["useGrouping", "useGrouping", booleanAttribute], minFractionDigits: ["minFractionDigits", "minFractionDigits", (value) => numberAttribute(value, null)], maxFractionDigits: ["maxFractionDigits", "maxFractionDigits", (value) => numberAttribute(value, null)], prefix: "prefix", suffix: "suffix", inputStyle: "inputStyle", inputStyleClass: "inputStyleClass", showClear: ["showClear", "showClear", booleanAttribute], autofocus: ["autofocus", "autofocus", booleanAttribute] }, outputs: { onInput: "onInput", onFocus: "onFocus", onBlur: "onBlur", onKeyDown: "onKeyDown", onClear: "onClear" }, host: { properties: { "attr.data-pc-name": "'inputnumber'", "attr.data-pc-section": "'root'", "class": "cn(cx('root'), styleClass)" } }, providers: [INPUTNUMBER_VALUE_ACCESSOR, InputNumberStyle], queries: [{ propertyName: "clearIconTemplate", first: true, predicate: ["clearicon"] }, { propertyName: "incrementButtonIconTemplate", first: true, predicate: ["incrementbuttonicon"] }, { propertyName: "decrementButtonIconTemplate", first: true, predicate: ["decrementbuttonicon"] }, { propertyName: "templates", predicate: PrimeTemplate }], viewQueries: [{ propertyName: "input", first: true, predicate: ["input"], descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: `
1219
+ <input
1220
+ pInputText
1221
+ #input
1222
+ [attr.id]="inputId"
1223
+ role="spinbutton"
1224
+ [class]="cn(cx('pcInputText'), inputStyleClass)"
1225
+ [value]="formattedValue()"
1226
+ [ngStyle]="inputStyle"
1227
+ [variant]="$variant()"
1228
+ [invalid]="invalid()"
1229
+ [attr.aria-valuemin]="min()"
1230
+ [attr.aria-valuemax]="max()"
1231
+ [attr.aria-valuenow]="value"
1232
+ [attr.placeholder]="placeholder"
1233
+ [attr.aria-label]="ariaLabel"
1234
+ [attr.aria-labelledby]="ariaLabelledBy"
1235
+ [attr.aria-describedby]="ariaDescribedBy"
1236
+ [attr.title]="title"
1237
+ [pSize]="size()"
1238
+ [attr.size]="inputSize()"
1239
+ [attr.name]="name()"
1240
+ [attr.autocomplete]="autocomplete"
1241
+ [attr.maxlength]="maxlength()"
1242
+ [attr.minlength]="minlength()"
1243
+ [attr.tabindex]="tabindex"
1244
+ [attr.aria-required]="ariaRequired"
1245
+ [attr.min]="min()"
1246
+ [attr.max]="max()"
1247
+ [attr.step]="step() ?? 1"
1248
+ [attr.required]="required() ? '' : undefined"
1249
+ [attr.readonly]="readonly ? '' : undefined"
1250
+ [attr.disabled]="$disabled() ? '' : undefined"
1251
+ inputmode="decimal"
1252
+ (input)="onUserInput($event)"
1253
+ (keydown)="onInputKeyDown($event)"
1254
+ (keypress)="onInputKeyPress($event)"
1255
+ (paste)="onPaste($event)"
1256
+ (click)="onInputClick()"
1257
+ (focus)="onInputFocus($event)"
1258
+ (blur)="onInputBlur($event)"
1259
+ [attr.data-pc-section]="'input'"
1260
+ [pAutoFocus]="autofocus"
1261
+ [fluid]="hasFluid"
1262
+ />
1263
+ <ng-container *ngIf="buttonLayout != 'vertical' && showClear && value">
1264
+ <svg data-p-icon="times" *ngIf="!clearIconTemplate && !_clearIconTemplate" [class]="cx('clearIcon')" (click)="clear()" [attr.data-pc-section]="'clearIcon'" />
1265
+ <span *ngIf="clearIconTemplate || _clearIconTemplate" (click)="clear()" [class]="cx('clearIcon')" [attr.data-pc-section]="'clearIcon'">
1266
+ <ng-template *ngTemplateOutlet="clearIconTemplate || _clearIconTemplate"></ng-template>
1267
+ </span>
1268
+ </ng-container>
1269
+ <span [class]="cx('buttonGroup')" *ngIf="showButtons && buttonLayout === 'stacked'" [attr.data-pc-section]="'buttonGroup'">
1270
+ <button
1271
+ type="button"
1272
+ [class]="cn(cx('incrementButton'), incrementButtonClass)"
1273
+ [attr.disabled]="$disabled() ? '' : undefined"
1274
+ tabindex="-1"
1275
+ (mousedown)="onUpButtonMouseDown($event)"
1276
+ (mouseup)="onUpButtonMouseUp()"
1277
+ (mouseleave)="onUpButtonMouseLeave()"
1278
+ (keydown)="onUpButtonKeyDown($event)"
1279
+ (keyup)="onUpButtonKeyUp()"
1280
+ [attr.aria-hidden]="true"
1281
+ [attr.data-pc-section]="'incrementbutton'"
1282
+ >
1283
+ <span *ngIf="incrementButtonIcon" [ngClass]="incrementButtonIcon" [attr.data-pc-section]="'incrementbuttonicon'"></span>
1284
+ <ng-container *ngIf="!incrementButtonIcon">
1285
+ <svg data-p-icon="angle-up" *ngIf="!incrementButtonIconTemplate && !_incrementButtonIconTemplate" [attr.data-pc-section]="'incrementbuttonicon'" />
1286
+ <ng-template *ngTemplateOutlet="incrementButtonIconTemplate || _incrementButtonIconTemplate"></ng-template>
1287
+ </ng-container>
1288
+ </button>
1289
+
1290
+ <button
1291
+ type="button"
1292
+ [class]="cn(cx('decrementButton'), decrementButtonClass)"
1293
+ [attr.disabled]="$disabled() ? '' : undefined"
1294
+ tabindex="-1"
1295
+ [attr.aria-hidden]="true"
1296
+ (mousedown)="onDownButtonMouseDown($event)"
1297
+ (mouseup)="onDownButtonMouseUp()"
1298
+ (mouseleave)="onDownButtonMouseLeave()"
1299
+ (keydown)="onDownButtonKeyDown($event)"
1300
+ (keyup)="onDownButtonKeyUp()"
1301
+ [attr.data-pc-section]="'decrementbutton'"
1302
+ >
1303
+ <span *ngIf="decrementButtonIcon" [ngClass]="decrementButtonIcon" [attr.data-pc-section]="'decrementbuttonicon'"></span>
1304
+ <ng-container *ngIf="!decrementButtonIcon">
1305
+ <svg data-p-icon="angle-down" *ngIf="!decrementButtonIconTemplate && !_decrementButtonIconTemplate" [attr.data-pc-section]="'decrementbuttonicon'" />
1306
+ <ng-template *ngTemplateOutlet="decrementButtonIconTemplate || _decrementButtonIconTemplate"></ng-template>
1307
+ </ng-container>
1308
+ </button>
1309
+ </span>
1310
+ <button
1311
+ *ngIf="showButtons && buttonLayout !== 'stacked'"
1312
+ type="button"
1313
+ [class]="cn(cx('incrementButton'), incrementButtonClass)"
1314
+ [attr.disabled]="$disabled() ? '' : undefined"
1315
+ tabindex="-1"
1316
+ [attr.aria-hidden]="true"
1317
+ (mousedown)="onUpButtonMouseDown($event)"
1318
+ (mouseup)="onUpButtonMouseUp()"
1319
+ (mouseleave)="onUpButtonMouseLeave()"
1320
+ (keydown)="onUpButtonKeyDown($event)"
1321
+ (keyup)="onUpButtonKeyUp()"
1322
+ [attr.data-pc-section]="'incrementbutton'"
1323
+ >
1324
+ <span *ngIf="incrementButtonIcon" [ngClass]="incrementButtonIcon" [attr.data-pc-section]="'incrementbuttonicon'"></span>
1325
+ <ng-container *ngIf="!incrementButtonIcon">
1326
+ <svg data-p-icon="angle-up" *ngIf="!incrementButtonIconTemplate && !_incrementButtonIconTemplate" [attr.data-pc-section]="'incrementbuttonicon'" />
1327
+ <ng-template *ngTemplateOutlet="incrementButtonIconTemplate || _incrementButtonIconTemplate"></ng-template>
1328
+ </ng-container>
1329
+ </button>
1330
+ <button
1331
+ *ngIf="showButtons && buttonLayout !== 'stacked'"
1332
+ type="button"
1333
+ [class]="cn(cx('decrementButton'), decrementButtonClass)"
1334
+ [attr.disabled]="$disabled() ? '' : undefined"
1335
+ tabindex="-1"
1336
+ [attr.aria-hidden]="true"
1337
+ (mousedown)="onDownButtonMouseDown($event)"
1338
+ (mouseup)="onDownButtonMouseUp()"
1339
+ (mouseleave)="onDownButtonMouseLeave()"
1340
+ (keydown)="onDownButtonKeyDown($event)"
1341
+ (keyup)="onDownButtonKeyUp()"
1342
+ [attr.data-pc-section]="'decrementbutton'"
1343
+ >
1344
+ <span *ngIf="decrementButtonIcon" [ngClass]="decrementButtonIcon" [attr.data-pc-section]="'decrementbuttonicon'"></span>
1345
+ <ng-container *ngIf="!decrementButtonIcon">
1346
+ <svg data-p-icon="angle-down" *ngIf="!decrementButtonIconTemplate && !_decrementButtonIconTemplate" [attr.data-pc-section]="'decrementbuttonicon'" />
1347
+ <ng-template *ngTemplateOutlet="decrementButtonIconTemplate || _decrementButtonIconTemplate"></ng-template>
1348
+ </ng-container>
1349
+ </button>
1350
+ `, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: InputText, selector: "[pInputText]", inputs: ["pSize", "variant", "fluid", "invalid"] }, { kind: "directive", type: AutoFocus, selector: "[pAutoFocus]", inputs: ["pAutoFocus"] }, { kind: "component", type: TimesIcon, selector: "[data-p-icon=\"times\"]" }, { kind: "component", type: AngleUpIcon, selector: "[data-p-icon=\"angle-up\"]" }, { kind: "component", type: AngleDownIcon, selector: "[data-p-icon=\"angle-down\"]" }, { kind: "ngmodule", type: SharedModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
1351
+ }
1352
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumber, decorators: [{
1353
+ type: Component,
1354
+ args: [{
1355
+ selector: 'p-inputNumber, p-inputnumber, p-input-number',
1356
+ standalone: true,
1357
+ imports: [CommonModule, InputText, AutoFocus, TimesIcon, AngleUpIcon, AngleDownIcon, SharedModule],
1358
+ template: `
1359
+ <input
1360
+ pInputText
1361
+ #input
1362
+ [attr.id]="inputId"
1363
+ role="spinbutton"
1364
+ [class]="cn(cx('pcInputText'), inputStyleClass)"
1365
+ [value]="formattedValue()"
1366
+ [ngStyle]="inputStyle"
1367
+ [variant]="$variant()"
1368
+ [invalid]="invalid()"
1369
+ [attr.aria-valuemin]="min()"
1370
+ [attr.aria-valuemax]="max()"
1371
+ [attr.aria-valuenow]="value"
1372
+ [attr.placeholder]="placeholder"
1373
+ [attr.aria-label]="ariaLabel"
1374
+ [attr.aria-labelledby]="ariaLabelledBy"
1375
+ [attr.aria-describedby]="ariaDescribedBy"
1376
+ [attr.title]="title"
1377
+ [pSize]="size()"
1378
+ [attr.size]="inputSize()"
1379
+ [attr.name]="name()"
1380
+ [attr.autocomplete]="autocomplete"
1381
+ [attr.maxlength]="maxlength()"
1382
+ [attr.minlength]="minlength()"
1383
+ [attr.tabindex]="tabindex"
1384
+ [attr.aria-required]="ariaRequired"
1385
+ [attr.min]="min()"
1386
+ [attr.max]="max()"
1387
+ [attr.step]="step() ?? 1"
1388
+ [attr.required]="required() ? '' : undefined"
1389
+ [attr.readonly]="readonly ? '' : undefined"
1390
+ [attr.disabled]="$disabled() ? '' : undefined"
1391
+ inputmode="decimal"
1392
+ (input)="onUserInput($event)"
1393
+ (keydown)="onInputKeyDown($event)"
1394
+ (keypress)="onInputKeyPress($event)"
1395
+ (paste)="onPaste($event)"
1396
+ (click)="onInputClick()"
1397
+ (focus)="onInputFocus($event)"
1398
+ (blur)="onInputBlur($event)"
1399
+ [attr.data-pc-section]="'input'"
1400
+ [pAutoFocus]="autofocus"
1401
+ [fluid]="hasFluid"
1402
+ />
1403
+ <ng-container *ngIf="buttonLayout != 'vertical' && showClear && value">
1404
+ <svg data-p-icon="times" *ngIf="!clearIconTemplate && !_clearIconTemplate" [class]="cx('clearIcon')" (click)="clear()" [attr.data-pc-section]="'clearIcon'" />
1405
+ <span *ngIf="clearIconTemplate || _clearIconTemplate" (click)="clear()" [class]="cx('clearIcon')" [attr.data-pc-section]="'clearIcon'">
1406
+ <ng-template *ngTemplateOutlet="clearIconTemplate || _clearIconTemplate"></ng-template>
1407
+ </span>
1408
+ </ng-container>
1409
+ <span [class]="cx('buttonGroup')" *ngIf="showButtons && buttonLayout === 'stacked'" [attr.data-pc-section]="'buttonGroup'">
1410
+ <button
1411
+ type="button"
1412
+ [class]="cn(cx('incrementButton'), incrementButtonClass)"
1413
+ [attr.disabled]="$disabled() ? '' : undefined"
1414
+ tabindex="-1"
1415
+ (mousedown)="onUpButtonMouseDown($event)"
1416
+ (mouseup)="onUpButtonMouseUp()"
1417
+ (mouseleave)="onUpButtonMouseLeave()"
1418
+ (keydown)="onUpButtonKeyDown($event)"
1419
+ (keyup)="onUpButtonKeyUp()"
1420
+ [attr.aria-hidden]="true"
1421
+ [attr.data-pc-section]="'incrementbutton'"
1422
+ >
1423
+ <span *ngIf="incrementButtonIcon" [ngClass]="incrementButtonIcon" [attr.data-pc-section]="'incrementbuttonicon'"></span>
1424
+ <ng-container *ngIf="!incrementButtonIcon">
1425
+ <svg data-p-icon="angle-up" *ngIf="!incrementButtonIconTemplate && !_incrementButtonIconTemplate" [attr.data-pc-section]="'incrementbuttonicon'" />
1426
+ <ng-template *ngTemplateOutlet="incrementButtonIconTemplate || _incrementButtonIconTemplate"></ng-template>
1427
+ </ng-container>
1428
+ </button>
1429
+
1430
+ <button
1431
+ type="button"
1432
+ [class]="cn(cx('decrementButton'), decrementButtonClass)"
1433
+ [attr.disabled]="$disabled() ? '' : undefined"
1434
+ tabindex="-1"
1435
+ [attr.aria-hidden]="true"
1436
+ (mousedown)="onDownButtonMouseDown($event)"
1437
+ (mouseup)="onDownButtonMouseUp()"
1438
+ (mouseleave)="onDownButtonMouseLeave()"
1439
+ (keydown)="onDownButtonKeyDown($event)"
1440
+ (keyup)="onDownButtonKeyUp()"
1441
+ [attr.data-pc-section]="'decrementbutton'"
1442
+ >
1443
+ <span *ngIf="decrementButtonIcon" [ngClass]="decrementButtonIcon" [attr.data-pc-section]="'decrementbuttonicon'"></span>
1444
+ <ng-container *ngIf="!decrementButtonIcon">
1445
+ <svg data-p-icon="angle-down" *ngIf="!decrementButtonIconTemplate && !_decrementButtonIconTemplate" [attr.data-pc-section]="'decrementbuttonicon'" />
1446
+ <ng-template *ngTemplateOutlet="decrementButtonIconTemplate || _decrementButtonIconTemplate"></ng-template>
1447
+ </ng-container>
1448
+ </button>
1449
+ </span>
1450
+ <button
1451
+ *ngIf="showButtons && buttonLayout !== 'stacked'"
1452
+ type="button"
1453
+ [class]="cn(cx('incrementButton'), incrementButtonClass)"
1454
+ [attr.disabled]="$disabled() ? '' : undefined"
1455
+ tabindex="-1"
1456
+ [attr.aria-hidden]="true"
1457
+ (mousedown)="onUpButtonMouseDown($event)"
1458
+ (mouseup)="onUpButtonMouseUp()"
1459
+ (mouseleave)="onUpButtonMouseLeave()"
1460
+ (keydown)="onUpButtonKeyDown($event)"
1461
+ (keyup)="onUpButtonKeyUp()"
1462
+ [attr.data-pc-section]="'incrementbutton'"
1463
+ >
1464
+ <span *ngIf="incrementButtonIcon" [ngClass]="incrementButtonIcon" [attr.data-pc-section]="'incrementbuttonicon'"></span>
1465
+ <ng-container *ngIf="!incrementButtonIcon">
1466
+ <svg data-p-icon="angle-up" *ngIf="!incrementButtonIconTemplate && !_incrementButtonIconTemplate" [attr.data-pc-section]="'incrementbuttonicon'" />
1467
+ <ng-template *ngTemplateOutlet="incrementButtonIconTemplate || _incrementButtonIconTemplate"></ng-template>
1468
+ </ng-container>
1469
+ </button>
1470
+ <button
1471
+ *ngIf="showButtons && buttonLayout !== 'stacked'"
1472
+ type="button"
1473
+ [class]="cn(cx('decrementButton'), decrementButtonClass)"
1474
+ [attr.disabled]="$disabled() ? '' : undefined"
1475
+ tabindex="-1"
1476
+ [attr.aria-hidden]="true"
1477
+ (mousedown)="onDownButtonMouseDown($event)"
1478
+ (mouseup)="onDownButtonMouseUp()"
1479
+ (mouseleave)="onDownButtonMouseLeave()"
1480
+ (keydown)="onDownButtonKeyDown($event)"
1481
+ (keyup)="onDownButtonKeyUp()"
1482
+ [attr.data-pc-section]="'decrementbutton'"
1483
+ >
1484
+ <span *ngIf="decrementButtonIcon" [ngClass]="decrementButtonIcon" [attr.data-pc-section]="'decrementbuttonicon'"></span>
1485
+ <ng-container *ngIf="!decrementButtonIcon">
1486
+ <svg data-p-icon="angle-down" *ngIf="!decrementButtonIconTemplate && !_decrementButtonIconTemplate" [attr.data-pc-section]="'decrementbuttonicon'" />
1487
+ <ng-template *ngTemplateOutlet="decrementButtonIconTemplate || _decrementButtonIconTemplate"></ng-template>
1488
+ </ng-container>
1489
+ </button>
1490
+ `,
1491
+ changeDetection: ChangeDetectionStrategy.OnPush,
1492
+ providers: [INPUTNUMBER_VALUE_ACCESSOR, InputNumberStyle],
1493
+ encapsulation: ViewEncapsulation.None,
1494
+ host: {
1495
+ '[attr.data-pc-name]': "'inputnumber'",
1496
+ '[attr.data-pc-section]': "'root'",
1497
+ '[class]': "cn(cx('root'), styleClass)"
1498
+ }
1499
+ }]
1500
+ }], ctorParameters: () => [{ type: i0.Injector }], propDecorators: { showButtons: [{
1501
+ type: Input,
1502
+ args: [{ transform: booleanAttribute }]
1503
+ }], format: [{
1504
+ type: Input,
1505
+ args: [{ transform: booleanAttribute }]
1506
+ }], buttonLayout: [{
1507
+ type: Input
1508
+ }], inputId: [{
1509
+ type: Input
1510
+ }], styleClass: [{
1511
+ type: Input
1512
+ }], placeholder: [{
1513
+ type: Input
1514
+ }], tabindex: [{
1515
+ type: Input,
1516
+ args: [{ transform: numberAttribute }]
1517
+ }], title: [{
1518
+ type: Input
1519
+ }], ariaLabelledBy: [{
1520
+ type: Input
1521
+ }], ariaDescribedBy: [{
1522
+ type: Input
1523
+ }], ariaLabel: [{
1524
+ type: Input
1525
+ }], ariaRequired: [{
1526
+ type: Input,
1527
+ args: [{ transform: booleanAttribute }]
1528
+ }], autocomplete: [{
1529
+ type: Input
1530
+ }], incrementButtonClass: [{
1531
+ type: Input
1532
+ }], decrementButtonClass: [{
1533
+ type: Input
1534
+ }], incrementButtonIcon: [{
1535
+ type: Input
1536
+ }], decrementButtonIcon: [{
1537
+ type: Input
1538
+ }], readonly: [{
1539
+ type: Input,
1540
+ args: [{ transform: booleanAttribute }]
1541
+ }], allowEmpty: [{
1542
+ type: Input,
1543
+ args: [{ transform: booleanAttribute }]
1544
+ }], locale: [{
1545
+ type: Input
1546
+ }], localeMatcher: [{
1547
+ type: Input
1548
+ }], mode: [{
1549
+ type: Input
1550
+ }], currency: [{
1551
+ type: Input
1552
+ }], currencyDisplay: [{
1553
+ type: Input
1554
+ }], useGrouping: [{
1555
+ type: Input,
1556
+ args: [{ transform: booleanAttribute }]
1557
+ }], minFractionDigits: [{
1558
+ type: Input,
1559
+ args: [{ transform: (value) => numberAttribute(value, null) }]
1560
+ }], maxFractionDigits: [{
1561
+ type: Input,
1562
+ args: [{ transform: (value) => numberAttribute(value, null) }]
1563
+ }], prefix: [{
1564
+ type: Input
1565
+ }], suffix: [{
1566
+ type: Input
1567
+ }], inputStyle: [{
1568
+ type: Input
1569
+ }], inputStyleClass: [{
1570
+ type: Input
1571
+ }], showClear: [{
1572
+ type: Input,
1573
+ args: [{ transform: booleanAttribute }]
1574
+ }], autofocus: [{
1575
+ type: Input,
1576
+ args: [{ transform: booleanAttribute }]
1577
+ }], onInput: [{
1578
+ type: Output
1579
+ }], onFocus: [{
1580
+ type: Output
1581
+ }], onBlur: [{
1582
+ type: Output
1583
+ }], onKeyDown: [{
1584
+ type: Output
1585
+ }], onClear: [{
1586
+ type: Output
1587
+ }], clearIconTemplate: [{
1588
+ type: ContentChild,
1589
+ args: ['clearicon', { descendants: false }]
1590
+ }], incrementButtonIconTemplate: [{
1591
+ type: ContentChild,
1592
+ args: ['incrementbuttonicon', { descendants: false }]
1593
+ }], decrementButtonIconTemplate: [{
1594
+ type: ContentChild,
1595
+ args: ['decrementbuttonicon', { descendants: false }]
1596
+ }], templates: [{
1597
+ type: ContentChildren,
1598
+ args: [PrimeTemplate]
1599
+ }], input: [{
1600
+ type: ViewChild,
1601
+ args: ['input']
1602
+ }] } });
1603
+ class InputNumberModule {
1604
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumberModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1605
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.2.4", ngImport: i0, type: InputNumberModule, imports: [InputNumber, SharedModule], exports: [InputNumber, SharedModule] });
1606
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumberModule, imports: [InputNumber, SharedModule, SharedModule] });
1607
+ }
1608
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: InputNumberModule, decorators: [{
1609
+ type: NgModule,
1610
+ args: [{
1611
+ imports: [InputNumber, SharedModule],
1612
+ exports: [InputNumber, SharedModule]
1613
+ }]
1614
+ }] });
1615
+
1616
+ /**
1617
+ * Generated bundle index. Do not edit.
1618
+ */
1619
+
1620
+ export { INPUTNUMBER_VALUE_ACCESSOR, InputNumber, InputNumberClasses, InputNumberModule, InputNumberStyle };
1621
+ //# sourceMappingURL=primeng-inputnumber.mjs.map