@exhaustive-ui/core 3.0.0-alpha.0 → 3.0.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (265) hide show
  1. package/fesm2022/exhaustive-ui-core-accordion.mjs +51 -78
  2. package/fesm2022/exhaustive-ui-core-accordion.mjs.map +1 -1
  3. package/fesm2022/exhaustive-ui-core-animateonscroll.mjs +72 -73
  4. package/fesm2022/exhaustive-ui-core-animateonscroll.mjs.map +1 -1
  5. package/fesm2022/exhaustive-ui-core-api.mjs +6 -13
  6. package/fesm2022/exhaustive-ui-core-api.mjs.map +1 -1
  7. package/fesm2022/exhaustive-ui-core-autocomplete.mjs +485 -683
  8. package/fesm2022/exhaustive-ui-core-autocomplete.mjs.map +1 -1
  9. package/fesm2022/exhaustive-ui-core-autofocus.mjs +21 -31
  10. package/fesm2022/exhaustive-ui-core-autofocus.mjs.map +1 -1
  11. package/fesm2022/exhaustive-ui-core-avatar.mjs +47 -63
  12. package/fesm2022/exhaustive-ui-core-avatar.mjs.map +1 -1
  13. package/fesm2022/exhaustive-ui-core-badge.mjs +88 -115
  14. package/fesm2022/exhaustive-ui-core-badge.mjs.map +1 -1
  15. package/fesm2022/exhaustive-ui-core-blockui.mjs +58 -91
  16. package/fesm2022/exhaustive-ui-core-blockui.mjs.map +1 -1
  17. package/fesm2022/exhaustive-ui-core-breadcrumb.mjs +155 -169
  18. package/fesm2022/exhaustive-ui-core-breadcrumb.mjs.map +1 -1
  19. package/fesm2022/exhaustive-ui-core-button.mjs +280 -385
  20. package/fesm2022/exhaustive-ui-core-button.mjs.map +1 -1
  21. package/fesm2022/exhaustive-ui-core-carousel.mjs +379 -451
  22. package/fesm2022/exhaustive-ui-core-carousel.mjs.map +1 -1
  23. package/fesm2022/exhaustive-ui-core-cascadeselect.mjs +388 -507
  24. package/fesm2022/exhaustive-ui-core-cascadeselect.mjs.map +1 -1
  25. package/fesm2022/exhaustive-ui-core-chart.mjs +75 -91
  26. package/fesm2022/exhaustive-ui-core-chart.mjs.map +1 -1
  27. package/fesm2022/exhaustive-ui-core-checkbox.mjs +109 -160
  28. package/fesm2022/exhaustive-ui-core-checkbox.mjs.map +1 -1
  29. package/fesm2022/exhaustive-ui-core-chip.mjs +98 -137
  30. package/fesm2022/exhaustive-ui-core-chip.mjs.map +1 -1
  31. package/fesm2022/exhaustive-ui-core-colorpicker.mjs +123 -190
  32. package/fesm2022/exhaustive-ui-core-colorpicker.mjs.map +1 -1
  33. package/fesm2022/exhaustive-ui-core-confirmdialog.mjs +157 -332
  34. package/fesm2022/exhaustive-ui-core-confirmdialog.mjs.map +1 -1
  35. package/fesm2022/exhaustive-ui-core-confirmpopup.mjs +187 -210
  36. package/fesm2022/exhaustive-ui-core-confirmpopup.mjs.map +1 -1
  37. package/fesm2022/exhaustive-ui-core-contextmenu.mjs +315 -361
  38. package/fesm2022/exhaustive-ui-core-contextmenu.mjs.map +1 -1
  39. package/fesm2022/exhaustive-ui-core-dataview.mjs +225 -272
  40. package/fesm2022/exhaustive-ui-core-dataview.mjs.map +1 -1
  41. package/fesm2022/exhaustive-ui-core-datepicker.mjs +1012 -1157
  42. package/fesm2022/exhaustive-ui-core-datepicker.mjs.map +1 -1
  43. package/fesm2022/exhaustive-ui-core-dialog.mjs +370 -507
  44. package/fesm2022/exhaustive-ui-core-dialog.mjs.map +1 -1
  45. package/fesm2022/exhaustive-ui-core-dock.mjs +87 -115
  46. package/fesm2022/exhaustive-ui-core-dock.mjs.map +1 -1
  47. package/fesm2022/exhaustive-ui-core-dragdrop.mjs +98 -105
  48. package/fesm2022/exhaustive-ui-core-dragdrop.mjs.map +1 -1
  49. package/fesm2022/exhaustive-ui-core-drawer.mjs +174 -235
  50. package/fesm2022/exhaustive-ui-core-drawer.mjs.map +1 -1
  51. package/fesm2022/exhaustive-ui-core-dynamicdialog.mjs +42 -280
  52. package/fesm2022/exhaustive-ui-core-dynamicdialog.mjs.map +1 -1
  53. package/fesm2022/exhaustive-ui-core-editor.mjs +109 -121
  54. package/fesm2022/exhaustive-ui-core-editor.mjs.map +1 -1
  55. package/fesm2022/exhaustive-ui-core-fieldset.mjs +90 -132
  56. package/fesm2022/exhaustive-ui-core-fieldset.mjs.map +1 -1
  57. package/fesm2022/exhaustive-ui-core-fileupload.mjs +486 -541
  58. package/fesm2022/exhaustive-ui-core-fileupload.mjs.map +1 -1
  59. package/fesm2022/exhaustive-ui-core-floatlabel.mjs +13 -16
  60. package/fesm2022/exhaustive-ui-core-floatlabel.mjs.map +1 -1
  61. package/fesm2022/exhaustive-ui-core-focustrap.mjs +44 -40
  62. package/fesm2022/exhaustive-ui-core-focustrap.mjs.map +1 -1
  63. package/fesm2022/exhaustive-ui-core-galleria.mjs +642 -853
  64. package/fesm2022/exhaustive-ui-core-galleria.mjs.map +1 -1
  65. package/fesm2022/exhaustive-ui-core-iconfield.mjs +15 -27
  66. package/fesm2022/exhaustive-ui-core-iconfield.mjs.map +1 -1
  67. package/fesm2022/exhaustive-ui-core-icons-baseicon.mjs +8 -13
  68. package/fesm2022/exhaustive-ui-core-icons-baseicon.mjs.map +1 -1
  69. package/fesm2022/exhaustive-ui-core-image.mjs +209 -251
  70. package/fesm2022/exhaustive-ui-core-image.mjs.map +1 -1
  71. package/fesm2022/exhaustive-ui-core-imagecompare.mjs +39 -48
  72. package/fesm2022/exhaustive-ui-core-imagecompare.mjs.map +1 -1
  73. package/fesm2022/exhaustive-ui-core-inplace.mjs +64 -98
  74. package/fesm2022/exhaustive-ui-core-inplace.mjs.map +1 -1
  75. package/fesm2022/exhaustive-ui-core-inputgroup.mjs +10 -20
  76. package/fesm2022/exhaustive-ui-core-inputgroup.mjs.map +1 -1
  77. package/fesm2022/exhaustive-ui-core-inputgroupaddon.mjs +15 -24
  78. package/fesm2022/exhaustive-ui-core-inputgroupaddon.mjs.map +1 -1
  79. package/fesm2022/exhaustive-ui-core-inputicon.mjs +11 -22
  80. package/fesm2022/exhaustive-ui-core-inputicon.mjs.map +1 -1
  81. package/fesm2022/exhaustive-ui-core-inputmask.mjs +423 -392
  82. package/fesm2022/exhaustive-ui-core-inputmask.mjs.map +1 -1
  83. package/fesm2022/exhaustive-ui-core-inputnumber.mjs +397 -469
  84. package/fesm2022/exhaustive-ui-core-inputnumber.mjs.map +1 -1
  85. package/fesm2022/exhaustive-ui-core-inputotp.mjs +75 -95
  86. package/fesm2022/exhaustive-ui-core-inputotp.mjs.map +1 -1
  87. package/fesm2022/exhaustive-ui-core-inputtext.mjs +27 -36
  88. package/fesm2022/exhaustive-ui-core-inputtext.mjs.map +1 -1
  89. package/fesm2022/exhaustive-ui-core-keyfilter.mjs +29 -46
  90. package/fesm2022/exhaustive-ui-core-keyfilter.mjs.map +1 -1
  91. package/fesm2022/exhaustive-ui-core-knob.mjs +140 -187
  92. package/fesm2022/exhaustive-ui-core-knob.mjs.map +1 -1
  93. package/fesm2022/exhaustive-ui-core-listbox.mjs +365 -546
  94. package/fesm2022/exhaustive-ui-core-listbox.mjs.map +1 -1
  95. package/fesm2022/exhaustive-ui-core-megamenu.mjs +320 -371
  96. package/fesm2022/exhaustive-ui-core-megamenu.mjs.map +1 -1
  97. package/fesm2022/exhaustive-ui-core-menu.mjs +298 -348
  98. package/fesm2022/exhaustive-ui-core-menu.mjs.map +1 -1
  99. package/fesm2022/exhaustive-ui-core-menubar.mjs +277 -372
  100. package/fesm2022/exhaustive-ui-core-menubar.mjs.map +1 -1
  101. package/fesm2022/exhaustive-ui-core-metergroup.mjs +138 -166
  102. package/fesm2022/exhaustive-ui-core-metergroup.mjs.map +1 -1
  103. package/fesm2022/exhaustive-ui-core-multiselect.mjs +647 -835
  104. package/fesm2022/exhaustive-ui-core-multiselect.mjs.map +1 -1
  105. package/fesm2022/exhaustive-ui-core-orderlist.mjs +337 -409
  106. package/fesm2022/exhaustive-ui-core-orderlist.mjs.map +1 -1
  107. package/fesm2022/exhaustive-ui-core-organizationchart.mjs +114 -175
  108. package/fesm2022/exhaustive-ui-core-organizationchart.mjs.map +1 -1
  109. package/fesm2022/exhaustive-ui-core-overlaybadge.mjs +22 -47
  110. package/fesm2022/exhaustive-ui-core-overlaybadge.mjs.map +1 -1
  111. package/fesm2022/exhaustive-ui-core-paginator.mjs +232 -320
  112. package/fesm2022/exhaustive-ui-core-paginator.mjs.map +1 -1
  113. package/fesm2022/exhaustive-ui-core-panel.mjs +114 -174
  114. package/fesm2022/exhaustive-ui-core-panel.mjs.map +1 -1
  115. package/fesm2022/exhaustive-ui-core-panelmenu.mjs +171 -282
  116. package/fesm2022/exhaustive-ui-core-panelmenu.mjs.map +1 -1
  117. package/fesm2022/exhaustive-ui-core-password.mjs +317 -377
  118. package/fesm2022/exhaustive-ui-core-password.mjs.map +1 -1
  119. package/fesm2022/exhaustive-ui-core-picklist.mjs +557 -655
  120. package/fesm2022/exhaustive-ui-core-picklist.mjs.map +1 -1
  121. package/fesm2022/exhaustive-ui-core-popover.mjs +154 -181
  122. package/fesm2022/exhaustive-ui-core-popover.mjs.map +1 -1
  123. package/fesm2022/exhaustive-ui-core-rating.mjs +87 -119
  124. package/fesm2022/exhaustive-ui-core-rating.mjs.map +1 -1
  125. package/fesm2022/exhaustive-ui-core-scroller.mjs +465 -596
  126. package/fesm2022/exhaustive-ui-core-scroller.mjs.map +1 -1
  127. package/fesm2022/exhaustive-ui-core-scrollpanel.mjs +147 -155
  128. package/fesm2022/exhaustive-ui-core-scrollpanel.mjs.map +1 -1
  129. package/fesm2022/exhaustive-ui-core-scrolltop.mjs +81 -115
  130. package/fesm2022/exhaustive-ui-core-scrolltop.mjs.map +1 -1
  131. package/fesm2022/exhaustive-ui-core-select.mjs +581 -784
  132. package/fesm2022/exhaustive-ui-core-select.mjs.map +1 -1
  133. package/fesm2022/exhaustive-ui-core-selectbutton.mjs +84 -120
  134. package/fesm2022/exhaustive-ui-core-selectbutton.mjs.map +1 -1
  135. package/fesm2022/exhaustive-ui-core-slider.mjs +322 -352
  136. package/fesm2022/exhaustive-ui-core-slider.mjs.map +1 -1
  137. package/fesm2022/exhaustive-ui-core-speeddial.mjs +209 -268
  138. package/fesm2022/exhaustive-ui-core-speeddial.mjs.map +1 -1
  139. package/fesm2022/exhaustive-ui-core-splitbutton.mjs +153 -249
  140. package/fesm2022/exhaustive-ui-core-splitbutton.mjs.map +1 -1
  141. package/fesm2022/exhaustive-ui-core-splitter.mjs +221 -237
  142. package/fesm2022/exhaustive-ui-core-splitter.mjs.map +1 -1
  143. package/fesm2022/exhaustive-ui-core-steps.mjs +56 -72
  144. package/fesm2022/exhaustive-ui-core-steps.mjs.map +1 -1
  145. package/fesm2022/exhaustive-ui-core-styleclass.mjs +145 -146
  146. package/fesm2022/exhaustive-ui-core-styleclass.mjs.map +1 -1
  147. package/fesm2022/exhaustive-ui-core-table.mjs +2213 -2543
  148. package/fesm2022/exhaustive-ui-core-table.mjs.map +1 -1
  149. package/fesm2022/exhaustive-ui-core-terminal.mjs +50 -67
  150. package/fesm2022/exhaustive-ui-core-terminal.mjs.map +1 -1
  151. package/fesm2022/exhaustive-ui-core-textarea.mjs +23 -36
  152. package/fesm2022/exhaustive-ui-core-textarea.mjs.map +1 -1
  153. package/fesm2022/exhaustive-ui-core-tieredmenu.mjs +318 -394
  154. package/fesm2022/exhaustive-ui-core-tieredmenu.mjs.map +1 -1
  155. package/fesm2022/exhaustive-ui-core-timeline.mjs +56 -74
  156. package/fesm2022/exhaustive-ui-core-timeline.mjs.map +1 -1
  157. package/fesm2022/exhaustive-ui-core-togglebutton.mjs +86 -129
  158. package/fesm2022/exhaustive-ui-core-togglebutton.mjs.map +1 -1
  159. package/fesm2022/exhaustive-ui-core-toggleswitch.mjs +57 -94
  160. package/fesm2022/exhaustive-ui-core-toggleswitch.mjs.map +1 -1
  161. package/fesm2022/exhaustive-ui-core-toolbar.mjs +36 -55
  162. package/fesm2022/exhaustive-ui-core-toolbar.mjs.map +1 -1
  163. package/fesm2022/exhaustive-ui-core-tooltip.mjs +264 -343
  164. package/fesm2022/exhaustive-ui-core-tooltip.mjs.map +1 -1
  165. package/fesm2022/exhaustive-ui-core-tree.mjs +508 -639
  166. package/fesm2022/exhaustive-ui-core-tree.mjs.map +1 -1
  167. package/fesm2022/exhaustive-ui-core-treeselect.mjs +327 -421
  168. package/fesm2022/exhaustive-ui-core-treeselect.mjs.map +1 -1
  169. package/fesm2022/exhaustive-ui-core-treetable.mjs +1267 -1473
  170. package/fesm2022/exhaustive-ui-core-treetable.mjs.map +1 -1
  171. package/package.json +5 -5
  172. package/schematics/migrations/remove-dead-inputs/migration.js +213 -7
  173. package/schematics/migrations/renamed-inputs/migration.js +97 -0
  174. package/schematics/migrations/styleclass-to-class/migration.js +92 -1
  175. package/schematics/migrations.json +7 -2
  176. package/schematics/utils/removed-inputs.js +0 -0
  177. package/schematics/utils/renamed-inputs.js +175 -0
  178. package/schematics/utils/styleclass.js +24 -8
  179. package/schematics/utils/versions.json +8 -8
  180. package/types/exhaustive-ui-core-accordion.d.ts +8 -24
  181. package/types/exhaustive-ui-core-animateonscroll.d.ts +19 -21
  182. package/types/exhaustive-ui-core-api.d.ts +2 -3
  183. package/types/exhaustive-ui-core-autocomplete.d.ts +103 -176
  184. package/types/exhaustive-ui-core-autofocus.d.ts +4 -7
  185. package/types/exhaustive-ui-core-avatar.d.ts +18 -25
  186. package/types/exhaustive-ui-core-badge.d.ts +13 -27
  187. package/types/exhaustive-ui-core-blockui.d.ts +18 -30
  188. package/types/exhaustive-ui-core-breadcrumb.d.ts +21 -22
  189. package/types/exhaustive-ui-core-button.d.ts +57 -89
  190. package/types/exhaustive-ui-core-carousel.d.ts +56 -82
  191. package/types/exhaustive-ui-core-cascadeselect.d.ts +77 -111
  192. package/types/exhaustive-ui-core-chart.d.ts +21 -29
  193. package/types/exhaustive-ui-core-checkbox.d.ts +25 -39
  194. package/types/exhaustive-ui-core-chip.d.ts +31 -38
  195. package/types/exhaustive-ui-core-colorpicker.d.ts +23 -57
  196. package/types/exhaustive-ui-core-confirmdialog.d.ts +39 -109
  197. package/types/exhaustive-ui-core-confirmpopup.d.ts +24 -43
  198. package/types/exhaustive-ui-core-contextmenu.d.ts +54 -71
  199. package/types/exhaustive-ui-core-dataview.d.ts +42 -65
  200. package/types/exhaustive-ui-core-datepicker.d.ts +109 -191
  201. package/types/exhaustive-ui-core-dialog.d.ts +73 -123
  202. package/types/exhaustive-ui-core-dock.d.ts +16 -25
  203. package/types/exhaustive-ui-core-dragdrop.d.ts +32 -36
  204. package/types/exhaustive-ui-core-drawer.d.ts +32 -64
  205. package/types/exhaustive-ui-core-dynamicdialog.d.ts +9 -54
  206. package/types/exhaustive-ui-core-editor.d.ts +15 -25
  207. package/types/exhaustive-ui-core-fieldset.d.ts +15 -35
  208. package/types/exhaustive-ui-core-fileupload.d.ts +69 -95
  209. package/types/exhaustive-ui-core-floatlabel.d.ts +4 -6
  210. package/types/exhaustive-ui-core-focustrap.d.ts +5 -10
  211. package/types/exhaustive-ui-core-galleria.d.ts +124 -194
  212. package/types/exhaustive-ui-core-iconfield.d.ts +5 -13
  213. package/types/exhaustive-ui-core-icons-baseicon.d.ts +4 -5
  214. package/types/exhaustive-ui-core-image.d.ts +35 -68
  215. package/types/exhaustive-ui-core-imagecompare.d.ts +19 -20
  216. package/types/exhaustive-ui-core-inplace.d.ts +30 -42
  217. package/types/exhaustive-ui-core-inputgroup.d.ts +2 -9
  218. package/types/exhaustive-ui-core-inputgroupaddon.d.ts +6 -10
  219. package/types/exhaustive-ui-core-inputicon.d.ts +4 -11
  220. package/types/exhaustive-ui-core-inputmask.d.ts +53 -66
  221. package/types/exhaustive-ui-core-inputnumber.d.ts +62 -84
  222. package/types/exhaustive-ui-core-inputotp.d.ts +16 -20
  223. package/types/exhaustive-ui-core-inputtext.d.ts +5 -8
  224. package/types/exhaustive-ui-core-keyfilter.d.ts +11 -15
  225. package/types/exhaustive-ui-core-knob.d.ts +45 -60
  226. package/types/exhaustive-ui-core-listbox.d.ts +90 -126
  227. package/types/exhaustive-ui-core-megamenu.d.ts +45 -66
  228. package/types/exhaustive-ui-core-menu.d.ts +33 -53
  229. package/types/exhaustive-ui-core-menubar.d.ts +38 -85
  230. package/types/exhaustive-ui-core-metergroup.d.ts +39 -48
  231. package/types/exhaustive-ui-core-multiselect.d.ts +166 -219
  232. package/types/exhaustive-ui-core-orderlist.d.ts +58 -81
  233. package/types/exhaustive-ui-core-organizationchart.d.ts +32 -67
  234. package/types/exhaustive-ui-core-overlaybadge.d.ts +10 -20
  235. package/types/exhaustive-ui-core-paginator.d.ts +41 -69
  236. package/types/exhaustive-ui-core-panel.d.ts +18 -45
  237. package/types/exhaustive-ui-core-panelmenu.d.ts +31 -76
  238. package/types/exhaustive-ui-core-password.d.ts +56 -93
  239. package/types/exhaustive-ui-core-picklist.d.ts +107 -121
  240. package/types/exhaustive-ui-core-popover.d.ts +23 -47
  241. package/types/exhaustive-ui-core-rating.d.ts +18 -26
  242. package/types/exhaustive-ui-core-scroller.d.ts +90 -120
  243. package/types/exhaustive-ui-core-scrollpanel.d.ts +35 -46
  244. package/types/exhaustive-ui-core-scrolltop.d.ts +28 -45
  245. package/types/exhaustive-ui-core-select.d.ts +137 -188
  246. package/types/exhaustive-ui-core-selectbutton.d.ts +35 -44
  247. package/types/exhaustive-ui-core-slider.d.ts +52 -67
  248. package/types/exhaustive-ui-core-speeddial.d.ts +40 -56
  249. package/types/exhaustive-ui-core-splitbutton.d.ts +31 -71
  250. package/types/exhaustive-ui-core-splitter.d.ts +47 -59
  251. package/types/exhaustive-ui-core-steps.d.ts +24 -31
  252. package/types/exhaustive-ui-core-styleclass.d.ts +27 -33
  253. package/types/exhaustive-ui-core-table.d.ts +349 -453
  254. package/types/exhaustive-ui-core-terminal.d.ts +10 -22
  255. package/types/exhaustive-ui-core-textarea.d.ts +7 -10
  256. package/types/exhaustive-ui-core-tieredmenu.d.ts +49 -84
  257. package/types/exhaustive-ui-core-timeline.d.ts +20 -28
  258. package/types/exhaustive-ui-core-togglebutton.d.ts +32 -48
  259. package/types/exhaustive-ui-core-toggleswitch.d.ts +26 -37
  260. package/types/exhaustive-ui-core-toolbar.d.ts +17 -25
  261. package/types/exhaustive-ui-core-tooltip.d.ts +53 -88
  262. package/types/exhaustive-ui-core-tree.d.ts +82 -119
  263. package/types/exhaustive-ui-core-treeselect.d.ts +63 -92
  264. package/types/exhaustive-ui-core-treetable.d.ts +203 -280
  265. package/types/exhaustive-ui-core-types-chip.d.ts +1 -1
@@ -2,7 +2,7 @@ export * from '@exhaustive-ui/core/types/carousel';
2
2
  import * as i2 from '@angular/common';
3
3
  import { isPlatformBrowser, CommonModule } from '@angular/common';
4
4
  import * as i0 from '@angular/core';
5
- import { Injectable, inject, ElementRef, NgZone, output, viewChild, contentChild, contentChildren, numberAttribute, booleanAttribute, Input, ViewEncapsulation, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
5
+ import { Injectable, inject, input, booleanAttribute, numberAttribute, output, viewChild, contentChild, linkedSignal, signal, computed, afterEveryRender, effect, untracked, contentChildren, ViewEncapsulation, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
6
6
  import { uuid, setAttribute, find, getAttribute, findSingle, removeClass, addClass } from '@exhaustive-ui/utils';
7
7
  import { Header, Footer, PrimeTemplate, SharedModule } from '@exhaustive-ui/core/api';
8
8
  import { BaseComponent, PARENT_INSTANCE } from '@exhaustive-ui/core/basecomponent';
@@ -36,9 +36,9 @@ const classes = {
36
36
  itemClone: ({ instance, index }) => [
37
37
  'p-carousel-item p-carousel-item-clone',
38
38
  {
39
- 'p-carousel-item-active': instance.totalShiftedItems * -1 === instance.value.length,
39
+ 'p-carousel-item-active': instance.totalShiftedItems() * -1 === instance.value().length,
40
40
  'p-carousel-item-start': 0 === index,
41
- 'p-carousel-item-end': instance.clonedItemsForStarting.length - 1 === index
41
+ 'p-carousel-item-end': instance.clonedItemsForStarting().length - 1 === index
42
42
  }
43
43
  ],
44
44
  item: ({ instance, index }) => [
@@ -55,14 +55,14 @@ const classes = {
55
55
  'p-disabled': instance.isForwardNavDisabled()
56
56
  }
57
57
  ],
58
- indicatorList: ({ instance }) => ['p-carousel-indicator-list', instance.indicatorsContentClass],
58
+ indicatorList: ({ instance }) => ['p-carousel-indicator-list', instance.indicatorsContentClass()],
59
59
  indicator: ({ instance, index }) => [
60
60
  'p-carousel-indicator',
61
61
  {
62
- 'p-carousel-indicator-active': instance._page === index
62
+ 'p-carousel-indicator-active': instance._page() === index
63
63
  }
64
64
  ],
65
- indicatorButton: ({ instance }) => ['p-carousel-indicator-button', instance.indicatorStyleClass],
65
+ indicatorButton: ({ instance }) => ['p-carousel-indicator-button', instance.indicatorStyleClass()],
66
66
  footer: 'p-carousel-footer'
67
67
  };
68
68
  class CarouselStyle extends BaseStyle {
@@ -149,153 +149,125 @@ var CarouselClasses;
149
149
  * @group Components
150
150
  */
151
151
  class Carousel extends BaseComponent {
152
- el = inject(ElementRef);
153
- zone = inject(NgZone);
154
152
  componentName = 'Carousel';
155
153
  bindDirectiveInstance = inject(Bind, { self: true });
156
- onAfterViewChecked() {
157
- this.bindDirectiveInstance.setAttrs(this.ptm('root'));
158
- }
159
154
  /**
160
155
  * Index of the first item.
161
156
  * @defaultValue 0
162
157
  * @group Props
163
158
  */
164
- get page() {
165
- return this._page;
166
- }
167
- set page(val) {
168
- if (this.isCreated && val !== this._page) {
169
- if (this.autoplayInterval) {
170
- this.stopAutoplay();
171
- }
172
- if (val > this._page && val <= this.totalDots() - 1) {
173
- this.step(-1, val);
174
- }
175
- else if (val < this._page) {
176
- this.step(1, val);
177
- }
178
- }
179
- this._page = val;
180
- }
159
+ page = input(0, /* @ts-ignore */
160
+ ...(ngDevMode ? [{ debugName: "page" }] : /* istanbul ignore next */ []));
181
161
  /**
182
162
  * Number of items per page.
183
163
  * @defaultValue 1
184
164
  * @group Props
185
165
  */
186
- get numVisible() {
187
- return this._numVisible;
188
- }
189
- set numVisible(val) {
190
- this._numVisible = val;
191
- }
166
+ numVisible = input(1, /* @ts-ignore */
167
+ ...(ngDevMode ? [{ debugName: "numVisible" }] : /* istanbul ignore next */ []));
192
168
  /**
193
169
  * Number of items to scroll.
194
170
  * @defaultValue 1
195
171
  * @group Props
196
172
  */
197
- get numScroll() {
198
- return this._numVisible;
199
- }
200
- set numScroll(val) {
201
- this._numScroll = val;
202
- }
173
+ numScroll = input(1, /* @ts-ignore */
174
+ ...(ngDevMode ? [{ debugName: "numScroll" }] : /* istanbul ignore next */ []));
203
175
  /**
204
176
  * An array of options for responsive design.
205
177
  * @see {CarouselResponsiveOptions}
206
178
  * @group Props
207
179
  */
208
- responsiveOptions;
180
+ responsiveOptions = input(/* @ts-ignore */
181
+ ...(ngDevMode ? [undefined, { debugName: "responsiveOptions" }] : /* istanbul ignore next */ []));
209
182
  /**
210
183
  * Specifies the layout of the component.
211
184
  * @group Props
212
185
  */
213
- orientation = 'horizontal';
186
+ orientation = input('horizontal', /* @ts-ignore */
187
+ ...(ngDevMode ? [{ debugName: "orientation" }] : /* istanbul ignore next */ []));
214
188
  /**
215
189
  * Height of the viewport in vertical layout.
216
190
  * @group Props
217
191
  */
218
- verticalViewPortHeight = '300px';
192
+ verticalViewPortHeight = input('300px', /* @ts-ignore */
193
+ ...(ngDevMode ? [{ debugName: "verticalViewPortHeight" }] : /* istanbul ignore next */ []));
219
194
  /**
220
195
  * Style class of main content.
221
196
  * @group Props
222
197
  */
223
- contentClass = '';
198
+ contentClass = input('', /* @ts-ignore */
199
+ ...(ngDevMode ? [{ debugName: "contentClass" }] : /* istanbul ignore next */ []));
224
200
  /**
225
201
  * Style class of the indicator items.
226
202
  * @group Props
227
203
  */
228
- indicatorsContentClass = '';
204
+ indicatorsContentClass = input('', /* @ts-ignore */
205
+ ...(ngDevMode ? [{ debugName: "indicatorsContentClass" }] : /* istanbul ignore next */ []));
229
206
  /**
230
207
  * Inline style of the indicator items.
231
208
  * @group Props
232
209
  */
233
- indicatorsContentStyle;
210
+ indicatorsContentStyle = input(/* @ts-ignore */
211
+ ...(ngDevMode ? [undefined, { debugName: "indicatorsContentStyle" }] : /* istanbul ignore next */ []));
234
212
  /**
235
213
  * Style class of the indicators.
236
214
  * @group Props
237
215
  */
238
- indicatorStyleClass = '';
216
+ indicatorStyleClass = input('', /* @ts-ignore */
217
+ ...(ngDevMode ? [{ debugName: "indicatorStyleClass" }] : /* istanbul ignore next */ []));
239
218
  /**
240
219
  * Style of the indicators.
241
220
  * @group Props
242
221
  */
243
- indicatorStyle;
222
+ indicatorStyle = input(/* @ts-ignore */
223
+ ...(ngDevMode ? [undefined, { debugName: "indicatorStyle" }] : /* istanbul ignore next */ []));
244
224
  /**
245
225
  * An array of objects to display.
246
226
  * @defaultValue null
247
227
  * @group Props
248
228
  */
249
- get value() {
250
- return this._value;
251
- }
252
- set value(val) {
253
- this._value = val;
254
- }
229
+ value = input(/* @ts-ignore */
230
+ ...(ngDevMode ? [undefined, { debugName: "value" }] : /* istanbul ignore next */ []));
255
231
  /**
256
232
  * Defines if scrolling would be infinite.
257
233
  * @group Props
258
234
  */
259
- circular = false;
235
+ circular = input(false, { ...(ngDevMode ? { debugName: "circular" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
260
236
  /**
261
237
  * Whether to display indicator container.
262
238
  * @group Props
263
239
  */
264
- showIndicators = true;
240
+ showIndicators = input(true, { ...(ngDevMode ? { debugName: "showIndicators" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
265
241
  /**
266
242
  * Whether to display navigation buttons in container.
267
243
  * @group Props
268
244
  */
269
- showNavigators = true;
245
+ showNavigators = input(true, { ...(ngDevMode ? { debugName: "showNavigators" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
270
246
  /**
271
247
  * Time in milliseconds to scroll items automatically.
272
248
  * @group Props
273
249
  */
274
- autoplayInterval = 0;
275
- /**
276
- * Style class of the viewport container.
277
- * @deprecated since v20.0.0, use `class` instead.
278
- * @group Props
279
- */
280
- styleClass;
250
+ autoplayInterval = input(0, { ...(ngDevMode ? { debugName: "autoplayInterval" } : /* istanbul ignore next */ {}), transform: numberAttribute });
281
251
  /**
282
252
  * Used to pass all properties of the ButtonProps to the Button component.
283
253
  * @group Props
284
254
  */
285
- prevButtonProps = {
255
+ prevButtonProps = input({
286
256
  severity: 'secondary',
287
257
  text: true,
288
258
  rounded: true
289
- };
259
+ }, /* @ts-ignore */
260
+ ...(ngDevMode ? [{ debugName: "prevButtonProps" }] : /* istanbul ignore next */ []));
290
261
  /**
291
262
  * Used to pass all properties of the ButtonProps to the Button component.
292
263
  * @group Props
293
264
  */
294
- nextButtonProps = {
265
+ nextButtonProps = input({
295
266
  severity: 'secondary',
296
267
  text: true,
297
268
  rounded: true
298
- };
269
+ }, /* @ts-ignore */
270
+ ...(ngDevMode ? [{ debugName: "nextButtonProps" }] : /* istanbul ignore next */ []));
299
271
  /**
300
272
  * Callback to invoke after scroll.
301
273
  * @param {CarouselPageEvent} event - Custom page event.
@@ -310,33 +282,54 @@ class Carousel extends BaseComponent {
310
282
  ...(ngDevMode ? [{ debugName: "headerFacet" }] : /* istanbul ignore next */ []));
311
283
  footerFacet = contentChild(Footer, /* @ts-ignore */
312
284
  ...(ngDevMode ? [{ debugName: "footerFacet" }] : /* istanbul ignore next */ []));
313
- _numVisible = 1;
314
- _numScroll = 1;
315
- _oldNumScroll = 0;
316
- prevState = {
285
+ _numVisible = linkedSignal(() => this.numVisible(), /* @ts-ignore */
286
+ ...(ngDevMode ? [{ debugName: "_numVisible" }] : /* istanbul ignore next */ []));
287
+ _numScroll = linkedSignal(() => this.numScroll(), /* @ts-ignore */
288
+ ...(ngDevMode ? [{ debugName: "_numScroll" }] : /* istanbul ignore next */ []));
289
+ prevState = signal({
317
290
  numScroll: 0,
318
291
  numVisible: 0,
319
292
  value: []
320
- };
321
- defaultNumScroll = 1;
322
- defaultNumVisible = 1;
323
- _page = 0;
324
- _value;
325
- carouselStyle;
326
- id;
327
- totalShiftedItems;
328
- isRemainingItemsAdded = false;
329
- animationTimeout;
330
- translateTimeout;
331
- remainingItems = 0;
332
- _items;
333
- startPos;
334
- documentResizeListener;
335
- clonedItemsForStarting;
336
- clonedItemsForFinishing;
337
- allowAutoplay;
338
- interval;
339
- isCreated;
293
+ }, /* @ts-ignore */
294
+ ...(ngDevMode ? [{ debugName: "prevState" }] : /* istanbul ignore next */ []));
295
+ defaultNumScroll = computed(() => this.numScroll(), /* @ts-ignore */
296
+ ...(ngDevMode ? [{ debugName: "defaultNumScroll" }] : /* istanbul ignore next */ []));
297
+ defaultNumVisible = computed(() => this.numVisible(), /* @ts-ignore */
298
+ ...(ngDevMode ? [{ debugName: "defaultNumVisible" }] : /* istanbul ignore next */ []));
299
+ _page = signal(0, /* @ts-ignore */
300
+ ...(ngDevMode ? [{ debugName: "_page" }] : /* istanbul ignore next */ []));
301
+ carouselStyle = signal(undefined, /* @ts-ignore */
302
+ ...(ngDevMode ? [{ debugName: "carouselStyle" }] : /* istanbul ignore next */ []));
303
+ id = uuid('pn_id_');
304
+ totalShiftedItems = signal(this._page() * this._numScroll() * -1, /* @ts-ignore */
305
+ ...(ngDevMode ? [{ debugName: "totalShiftedItems" }] : /* istanbul ignore next */ []));
306
+ isRemainingItemsAdded = signal(false, /* @ts-ignore */
307
+ ...(ngDevMode ? [{ debugName: "isRemainingItemsAdded" }] : /* istanbul ignore next */ []));
308
+ remainingItems = computed(() => {
309
+ const value = this.value();
310
+ return value ? (value.length - this._numVisible()) % this._numScroll() : 0;
311
+ }, /* @ts-ignore */
312
+ ...(ngDevMode ? [{ debugName: "remainingItems" }] : /* istanbul ignore next */ []));
313
+ startPos = signal(undefined, /* @ts-ignore */
314
+ ...(ngDevMode ? [{ debugName: "startPos" }] : /* istanbul ignore next */ []));
315
+ documentResizeListener = signal(undefined, /* @ts-ignore */
316
+ ...(ngDevMode ? [{ debugName: "documentResizeListener" }] : /* istanbul ignore next */ []));
317
+ clonedItemsForStarting = computed(() => {
318
+ const value = this.value();
319
+ return this.isCircular() && value ? value.slice(-1 * this._numVisible()) : [];
320
+ }, /* @ts-ignore */
321
+ ...(ngDevMode ? [{ debugName: "clonedItemsForStarting" }] : /* istanbul ignore next */ []));
322
+ clonedItemsForFinishing = computed(() => {
323
+ const value = this.value();
324
+ return this.isCircular() && value ? value.slice(0, this._numVisible()) : [];
325
+ }, /* @ts-ignore */
326
+ ...(ngDevMode ? [{ debugName: "clonedItemsForFinishing" }] : /* istanbul ignore next */ []));
327
+ allowAutoplay = linkedSignal(() => !!this.autoplayInterval(), /* @ts-ignore */
328
+ ...(ngDevMode ? [{ debugName: "allowAutoplay" }] : /* istanbul ignore next */ []));
329
+ interval = signal(undefined, /* @ts-ignore */
330
+ ...(ngDevMode ? [{ debugName: "interval" }] : /* istanbul ignore next */ []));
331
+ isCreated = signal(undefined, /* @ts-ignore */
332
+ ...(ngDevMode ? [{ debugName: "isCreated" }] : /* istanbul ignore next */ []));
340
333
  swipeThreshold = 20;
341
334
  /**
342
335
  * Custom item template.
@@ -363,163 +356,153 @@ class Carousel extends BaseComponent {
363
356
  * @group Templates
364
357
  */
365
358
  nextIconTemplate = contentChild('nexticon', { ...(ngDevMode ? { debugName: "nextIconTemplate" } : /* istanbul ignore next */ {}), descendants: false });
366
- _itemTemplate;
367
- _headerTemplate;
368
- _footerTemplate;
369
- _previousIconTemplate;
370
- _nextIconTemplate;
371
- window;
359
+ _itemTemplate = computed(() => this.templates()
360
+ .filter((item) => !['header', 'footer', 'previousicon', 'nexticon'].includes(item.getType()))
361
+ .at(-1)?.template, /* @ts-ignore */
362
+ ...(ngDevMode ? [{ debugName: "_itemTemplate" }] : /* istanbul ignore next */ []));
363
+ _headerTemplate = computed(() => this.templates()
364
+ .filter((item) => item.getType() === 'header')
365
+ .at(-1)?.template, /* @ts-ignore */
366
+ ...(ngDevMode ? [{ debugName: "_headerTemplate" }] : /* istanbul ignore next */ []));
367
+ _footerTemplate = computed(() => this.templates()
368
+ .filter((item) => item.getType() === 'footer')
369
+ .at(-1)?.template, /* @ts-ignore */
370
+ ...(ngDevMode ? [{ debugName: "_footerTemplate" }] : /* istanbul ignore next */ []));
371
+ _previousIconTemplate = computed(() => this.templates()
372
+ .filter((item) => item.getType() === 'previousicon')
373
+ .at(-1)?.template, /* @ts-ignore */
374
+ ...(ngDevMode ? [{ debugName: "_previousIconTemplate" }] : /* istanbul ignore next */ []));
375
+ _nextIconTemplate = computed(() => this.templates()
376
+ .filter((item) => item.getType() === 'nexticon')
377
+ .at(-1)?.template, /* @ts-ignore */
378
+ ...(ngDevMode ? [{ debugName: "_nextIconTemplate" }] : /* istanbul ignore next */ []));
379
+ window = this.document.defaultView;
372
380
  _componentStyle = inject(CarouselStyle);
373
381
  constructor() {
374
382
  super();
375
- this.totalShiftedItems = this.page * this.numScroll * -1;
376
- this.window = this.document.defaultView;
377
- }
378
- onChanges(simpleChange) {
379
- if (isPlatformBrowser(this.platformId)) {
380
- if (simpleChange.value) {
381
- if (this.circular && this._value) {
382
- this.setCloneItems();
383
- }
384
- }
385
- if (this.isCreated) {
386
- if (simpleChange.numVisible) {
387
- if (this.responsiveOptions) {
388
- this.defaultNumVisible = this.numVisible;
383
+ afterEveryRender(() => this.bindDirectiveInstance.setAttrs(this.ptms(['host', 'root'])));
384
+ effect(() => {
385
+ const page = this.page();
386
+ untracked(() => {
387
+ if (this.isCreated() && page !== this._page()) {
388
+ if (this.autoplayInterval()) {
389
+ this.stopAutoplay();
390
+ }
391
+ if (page > this._page() && page <= this.totalDots() - 1) {
392
+ this.step(-1, page);
389
393
  }
390
- if (this.isCircular()) {
391
- this.setCloneItems();
394
+ else if (page < this._page()) {
395
+ this.step(1, page);
392
396
  }
397
+ }
398
+ this._page.set(page);
399
+ });
400
+ });
401
+ effect(() => {
402
+ this.numVisible();
403
+ untracked(() => {
404
+ if (isPlatformBrowser(this.platformId)) {
393
405
  this.createStyle();
394
406
  this.calculatePosition();
395
407
  }
396
- if (simpleChange.numScroll) {
397
- if (this.responsiveOptions) {
398
- this.defaultNumScroll = this.numScroll;
399
- }
408
+ });
409
+ });
410
+ effect(() => {
411
+ const responsiveOptions = this.responsiveOptions();
412
+ untracked(() => {
413
+ if (responsiveOptions) {
414
+ this.bindDocumentListeners();
400
415
  }
401
- }
402
- }
403
- this.cd.markForCheck();
404
- }
405
- templates = contentChildren(PrimeTemplate, /* @ts-ignore */
406
- ...(ngDevMode ? [{ debugName: "templates" }] : /* istanbul ignore next */ []));
407
- onAfterContentInit() {
408
- this.id = uuid('pn_id_');
409
- if (isPlatformBrowser(this.platformId)) {
410
- this.allowAutoplay = !!this.autoplayInterval;
411
- if (this.circular) {
412
- this.setCloneItems();
413
- }
414
- if (this.responsiveOptions) {
415
- this.defaultNumScroll = this._numScroll;
416
- this.defaultNumVisible = this._numVisible;
417
- }
418
- this.createStyle();
419
- this.calculatePosition();
420
- if (this.responsiveOptions) {
421
- this.bindDocumentListeners();
422
- }
423
- }
424
- this.templates()?.forEach((item) => {
425
- switch (item.getType()) {
426
- case 'item':
427
- this._itemTemplate = item.template;
428
- break;
429
- case 'header':
430
- this._headerTemplate = item.template;
431
- break;
432
- case 'footer':
433
- this._footerTemplate = item.template;
434
- break;
435
- case 'previousicon':
436
- this._previousIconTemplate = item.template;
437
- break;
438
- case 'nexticon':
439
- this._nextIconTemplate = item.template;
440
- break;
441
- default:
442
- this._itemTemplate = item.template;
443
- break;
444
- }
416
+ });
445
417
  });
446
- this.cd.detectChanges();
447
- }
448
- onAfterContentChecked() {
449
- if (isPlatformBrowser(this.platformId)) {
450
- const isCircular = this.isCircular();
451
- let totalShiftedItems = this.totalShiftedItems;
418
+ effect(() => {
419
+ const value = this.value();
452
420
  const itemsContainer = this.itemsContainer();
453
- if (this.value && itemsContainer && (this.prevState.numScroll !== this._numScroll || this.prevState.numVisible !== this._numVisible || this.prevState.value.length !== this.value.length)) {
454
- if (this.autoplayInterval) {
455
- this.stopAutoplay(false);
456
- }
457
- this.remainingItems = (this.value.length - this._numVisible) % this._numScroll;
458
- let page = this._page;
459
- if (this.totalDots() !== 0 && page >= this.totalDots()) {
460
- page = this.totalDots() - 1;
461
- this._page = page;
462
- this.onPage.emit({
463
- page: this.page
464
- });
465
- }
466
- totalShiftedItems = page * this._numScroll * -1;
467
- if (isCircular) {
468
- totalShiftedItems -= this._numVisible;
469
- }
470
- if (page === this.totalDots() - 1 && this.remainingItems > 0) {
471
- totalShiftedItems += -1 * this.remainingItems + this._numScroll;
472
- this.isRemainingItemsAdded = true;
473
- }
474
- else {
475
- this.isRemainingItemsAdded = false;
476
- }
477
- if (totalShiftedItems !== this.totalShiftedItems) {
478
- this.totalShiftedItems = totalShiftedItems;
479
- }
480
- this._oldNumScroll = this._numScroll;
481
- this.prevState.numScroll = this._numScroll;
482
- this.prevState.numVisible = this._numVisible;
483
- this.prevState.value = [...this._value];
484
- if (this.totalDots() > 0 && itemsContainer.nativeElement) {
485
- itemsContainer.nativeElement.style.transform = this.isVertical() ? `translate3d(0, ${totalShiftedItems * (100 / this._numVisible)}%, 0)` : `translate3d(${totalShiftedItems * (100 / this._numVisible)}%, 0, 0)`;
486
- }
487
- this.isCreated = true;
488
- if (this.autoplayInterval && this.isAutoplay()) {
489
- this.startAutoplay();
490
- }
491
- }
492
- if (isCircular) {
493
- if (this.page === 0) {
494
- totalShiftedItems = -1 * this._numVisible;
495
- }
496
- else if (totalShiftedItems === 0) {
497
- totalShiftedItems = -1 * this.value.length;
498
- if (this.remainingItems > 0) {
499
- this.isRemainingItemsAdded = true;
421
+ const _numScroll = this._numScroll();
422
+ const _numVisible = this._numVisible();
423
+ const isCircular = this.isCircular();
424
+ let totalShiftedItems = this.totalShiftedItems();
425
+ this._page();
426
+ untracked(() => {
427
+ if (isPlatformBrowser(this.platformId)) {
428
+ const prevState = this.prevState();
429
+ if (value && itemsContainer && (prevState.numScroll !== _numScroll || prevState.numVisible !== _numVisible || prevState.value.length !== value.length)) {
430
+ if (this.autoplayInterval()) {
431
+ this.stopAutoplay(false);
432
+ }
433
+ let page = this._page();
434
+ if (this.totalDots() !== 0 && page >= this.totalDots()) {
435
+ page = this.totalDots() - 1;
436
+ this._page.set(page);
437
+ this.onPage.emit({
438
+ page: this._page()
439
+ });
440
+ }
441
+ totalShiftedItems = page * _numScroll * -1;
442
+ if (isCircular) {
443
+ totalShiftedItems -= _numVisible;
444
+ }
445
+ if (page === this.totalDots() - 1 && this.remainingItems() > 0) {
446
+ totalShiftedItems += -1 * this.remainingItems() + _numScroll;
447
+ this.isRemainingItemsAdded.set(true);
448
+ }
449
+ else {
450
+ this.isRemainingItemsAdded.set(false);
451
+ }
452
+ if (totalShiftedItems !== this.totalShiftedItems()) {
453
+ this.totalShiftedItems.set(totalShiftedItems);
454
+ }
455
+ this.prevState.set({
456
+ numScroll: _numScroll,
457
+ numVisible: _numVisible,
458
+ value: [...value]
459
+ });
460
+ if (this.totalDots() > 0 && itemsContainer.nativeElement) {
461
+ itemsContainer.nativeElement.style.transform = this.isVertical() ? `translate3d(0, ${totalShiftedItems * (100 / _numVisible)}%, 0)` : `translate3d(${totalShiftedItems * (100 / _numVisible)}%, 0, 0)`;
462
+ }
463
+ this.isCreated.set(true);
464
+ if (this.autoplayInterval() && this.isAutoplay()) {
465
+ this.startAutoplay();
466
+ }
467
+ }
468
+ if (isCircular) {
469
+ if (this._page() === 0) {
470
+ totalShiftedItems = -1 * _numVisible;
471
+ }
472
+ else if (totalShiftedItems === 0) {
473
+ totalShiftedItems = -1 * value.length;
474
+ if (this.remainingItems() > 0) {
475
+ this.isRemainingItemsAdded.set(true);
476
+ }
477
+ }
478
+ if (totalShiftedItems !== this.totalShiftedItems()) {
479
+ this.totalShiftedItems.set(totalShiftedItems);
480
+ }
500
481
  }
501
482
  }
502
- if (totalShiftedItems !== this.totalShiftedItems) {
503
- this.totalShiftedItems = totalShiftedItems;
504
- }
505
- }
506
- }
483
+ });
484
+ });
507
485
  }
486
+ templates = contentChildren(PrimeTemplate, /* @ts-ignore */
487
+ ...(ngDevMode ? [{ debugName: "templates" }] : /* istanbul ignore next */ []));
508
488
  createStyle() {
509
- if (!this.carouselStyle) {
510
- this.carouselStyle = this.renderer.createElement('style');
511
- this.carouselStyle.type = 'text/css';
512
- setAttribute(this.carouselStyle, 'nonce', this.config?.csp()?.nonce);
513
- this.renderer.appendChild(this.document.head, this.carouselStyle);
514
- setAttribute(this.carouselStyle, 'nonce', this.config?.csp()?.nonce);
489
+ let carouselStyle = this.carouselStyle();
490
+ if (!carouselStyle) {
491
+ carouselStyle = this.renderer.createElement('style');
492
+ carouselStyle.type = 'text/css';
493
+ setAttribute(carouselStyle, 'nonce', this.config?.csp()?.nonce);
494
+ this.renderer.appendChild(this.document.head, carouselStyle);
495
+ setAttribute(carouselStyle, 'nonce', this.config?.csp()?.nonce);
496
+ this.carouselStyle.set(carouselStyle);
515
497
  }
516
498
  let innerHTML = `
517
499
  #${this.id} .p-carousel-item {
518
- flex: 1 0 ${100 / this.numVisible}%
500
+ flex: 1 0 ${100 / this._numVisible()}%
519
501
  }
520
502
  `;
521
- if (this.responsiveOptions && !this.$unstyled()) {
522
- this.responsiveOptions.sort((data1, data2) => {
503
+ const responsiveOptions = this.responsiveOptions();
504
+ if (responsiveOptions && !this.$unstyled()) {
505
+ responsiveOptions.sort((data1, data2) => {
523
506
  const value1 = data1.breakpoint;
524
507
  const value2 = data2.breakpoint;
525
508
  let result = null;
@@ -535,8 +518,8 @@ class Carousel extends BaseComponent {
535
518
  result = value1 < value2 ? -1 : value1 > value2 ? 1 : 0;
536
519
  return -1 * result;
537
520
  });
538
- for (let i = 0; i < this.responsiveOptions.length; i++) {
539
- let res = this.responsiveOptions[i];
521
+ for (let i = 0; i < responsiveOptions.length; i++) {
522
+ let res = responsiveOptions[i];
540
523
  innerHTML += `
541
524
  @media screen and (max-width: ${res.breakpoint}) {
542
525
  #${this.id} .p-carousel-item {
@@ -546,88 +529,80 @@ class Carousel extends BaseComponent {
546
529
  `;
547
530
  }
548
531
  }
549
- this.carouselStyle.innerHTML = innerHTML;
532
+ carouselStyle.innerHTML = innerHTML;
550
533
  }
551
534
  calculatePosition() {
552
- if (this.responsiveOptions) {
535
+ const responsiveOptions = this.responsiveOptions();
536
+ if (responsiveOptions) {
553
537
  let matchedResponsiveData = {
554
- numVisible: this.defaultNumVisible,
555
- numScroll: this.defaultNumScroll
538
+ numVisible: this.defaultNumVisible(),
539
+ numScroll: this.defaultNumScroll()
556
540
  };
557
541
  if (typeof window !== 'undefined') {
558
542
  let windowWidth = window.innerWidth;
559
- for (let i = 0; i < this.responsiveOptions.length; i++) {
560
- let res = this.responsiveOptions[i];
543
+ for (let i = 0; i < responsiveOptions.length; i++) {
544
+ let res = responsiveOptions[i];
561
545
  if (parseInt(res.breakpoint, 10) >= windowWidth) {
562
546
  matchedResponsiveData = res;
563
547
  }
564
548
  }
565
549
  }
566
- if (this._numScroll !== matchedResponsiveData.numScroll) {
567
- let page = this._page;
568
- page = Math.floor((page * this._numScroll) / matchedResponsiveData.numScroll);
569
- let totalShiftedItems = matchedResponsiveData.numScroll * this.page * -1;
550
+ if (this._numScroll() !== matchedResponsiveData.numScroll) {
551
+ let page = this._page();
552
+ page = Math.floor((page * this._numScroll()) / matchedResponsiveData.numScroll);
553
+ let totalShiftedItems = matchedResponsiveData.numScroll * this._page() * -1;
570
554
  if (this.isCircular()) {
571
555
  totalShiftedItems -= matchedResponsiveData.numVisible;
572
556
  }
573
- this.totalShiftedItems = totalShiftedItems;
574
- this._numScroll = matchedResponsiveData.numScroll;
575
- this._page = page;
557
+ this.totalShiftedItems.set(totalShiftedItems);
558
+ this._numScroll.set(matchedResponsiveData.numScroll);
559
+ this._page.set(page);
576
560
  this.onPage.emit({
577
- page: this.page
561
+ page: this._page()
578
562
  });
579
563
  }
580
- if (this._numVisible !== matchedResponsiveData.numVisible) {
581
- this._numVisible = matchedResponsiveData.numVisible;
582
- this.setCloneItems();
564
+ if (this._numVisible() !== matchedResponsiveData.numVisible) {
565
+ this._numVisible.set(matchedResponsiveData.numVisible);
583
566
  }
584
- this.cd.markForCheck();
585
- }
586
- }
587
- setCloneItems() {
588
- this.clonedItemsForStarting = [];
589
- this.clonedItemsForFinishing = [];
590
- if (this.isCircular()) {
591
- this.clonedItemsForStarting.push(...this.value.slice(-1 * this._numVisible));
592
- this.clonedItemsForFinishing.push(...this.value.slice(0, this._numVisible));
593
567
  }
594
568
  }
595
- firstIndex() {
596
- return this.isCircular() ? -1 * (this.totalShiftedItems + this.numVisible) : this.totalShiftedItems * -1;
597
- }
598
- lastIndex() {
599
- return this.firstIndex() + this.numVisible - 1;
600
- }
601
- totalDots() {
602
- return this.value?.length ? Math.ceil((this.value.length - this._numVisible) / this._numScroll) + 1 : 0;
603
- }
604
- totalDotsArray() {
569
+ firstIndex = computed(() => (this.isCircular() ? -1 * (this.totalShiftedItems() + this._numVisible()) : this.totalShiftedItems() * -1), /* @ts-ignore */
570
+ ...(ngDevMode ? [{ debugName: "firstIndex" }] : /* istanbul ignore next */ []));
571
+ lastIndex = computed(() => this.firstIndex() + this._numVisible() - 1, /* @ts-ignore */
572
+ ...(ngDevMode ? [{ debugName: "lastIndex" }] : /* istanbul ignore next */ []));
573
+ totalDots = computed(() => {
574
+ const value = this.value();
575
+ return value?.length ? Math.ceil((value.length - this._numVisible()) / this._numScroll()) + 1 : 0;
576
+ }, /* @ts-ignore */
577
+ ...(ngDevMode ? [{ debugName: "totalDots" }] : /* istanbul ignore next */ []));
578
+ totalDotsArray = computed(() => {
605
579
  const totalDots = this.totalDots();
606
580
  return totalDots <= 0 ? [] : Array(totalDots).fill(0);
607
- }
608
- isVertical() {
609
- return this.orientation === 'vertical';
610
- }
611
- isCircular() {
612
- return this.circular && this.value && this.value.length >= this.numVisible;
613
- }
614
- isAutoplay() {
615
- return this.autoplayInterval && this.allowAutoplay;
616
- }
617
- isForwardNavDisabled() {
618
- return this.isEmpty() || (this._page >= this.totalDots() - 1 && !this.isCircular());
619
- }
620
- isBackwardNavDisabled() {
621
- return this.isEmpty() || (this._page <= 0 && !this.isCircular());
622
- }
623
- isEmpty() {
624
- return !this.value || this.value.length === 0;
625
- }
581
+ }, /* @ts-ignore */
582
+ ...(ngDevMode ? [{ debugName: "totalDotsArray" }] : /* istanbul ignore next */ []));
583
+ isVertical = computed(() => this.orientation() === 'vertical', /* @ts-ignore */
584
+ ...(ngDevMode ? [{ debugName: "isVertical" }] : /* istanbul ignore next */ []));
585
+ isCircular = computed(() => {
586
+ const value = this.value();
587
+ return this.circular() && !!value && value.length >= this._numVisible();
588
+ }, /* @ts-ignore */
589
+ ...(ngDevMode ? [{ debugName: "isCircular" }] : /* istanbul ignore next */ []));
590
+ isAutoplay = computed(() => this.autoplayInterval() && this.allowAutoplay(), /* @ts-ignore */
591
+ ...(ngDevMode ? [{ debugName: "isAutoplay" }] : /* istanbul ignore next */ []));
592
+ isForwardNavDisabled = computed(() => this.isEmpty() || (this._page() >= this.totalDots() - 1 && !this.isCircular()), /* @ts-ignore */
593
+ ...(ngDevMode ? [{ debugName: "isForwardNavDisabled" }] : /* istanbul ignore next */ []));
594
+ isBackwardNavDisabled = computed(() => this.isEmpty() || (this._page() <= 0 && !this.isCircular()), /* @ts-ignore */
595
+ ...(ngDevMode ? [{ debugName: "isBackwardNavDisabled" }] : /* istanbul ignore next */ []));
596
+ isEmpty = computed(() => {
597
+ const value = this.value();
598
+ return !value || value.length === 0;
599
+ }, /* @ts-ignore */
600
+ ...(ngDevMode ? [{ debugName: "isEmpty" }] : /* istanbul ignore next */ []));
626
601
  navForward(e, index) {
627
- if (this.isCircular() || this._page < this.totalDots() - 1) {
602
+ if (this.isCircular() || this._page() < this.totalDots() - 1) {
628
603
  this.step(-1, index);
629
604
  }
630
- if (this.autoplayInterval) {
605
+ if (this.autoplayInterval()) {
631
606
  this.stopAutoplay();
632
607
  }
633
608
  if (e && e.cancelable) {
@@ -635,10 +610,10 @@ class Carousel extends BaseComponent {
635
610
  }
636
611
  }
637
612
  navBackward(e, index) {
638
- if (this.isCircular() || this._page !== 0) {
613
+ if (this.isCircular() || this._page() !== 0) {
639
614
  this.step(1, index);
640
615
  }
641
- if (this.autoplayInterval) {
616
+ if (this.autoplayInterval()) {
642
617
  this.stopAutoplay();
643
618
  }
644
619
  if (e && e.cancelable) {
@@ -646,8 +621,8 @@ class Carousel extends BaseComponent {
646
621
  }
647
622
  }
648
623
  onDotClick(e, index) {
649
- let page = this._page;
650
- if (this.autoplayInterval) {
624
+ let page = this._page();
625
+ if (this.autoplayInterval()) {
651
626
  this.stopAutoplay();
652
627
  }
653
628
  if (index > page) {
@@ -707,92 +682,88 @@ class Carousel extends BaseComponent {
707
682
  indicators[nextInd].children[0].focus();
708
683
  }
709
684
  step(dir, page) {
710
- let totalShiftedItems = this.totalShiftedItems;
685
+ let totalShiftedItems = this.totalShiftedItems();
711
686
  const isCircular = this.isCircular();
712
687
  if (page != null) {
713
- totalShiftedItems = this._numScroll * page * -1;
688
+ totalShiftedItems = this._numScroll() * page * -1;
714
689
  if (isCircular) {
715
- totalShiftedItems -= this._numVisible;
690
+ totalShiftedItems -= this._numVisible();
716
691
  }
717
- this.isRemainingItemsAdded = false;
692
+ this.isRemainingItemsAdded.set(false);
718
693
  }
719
694
  else {
720
- totalShiftedItems += this._numScroll * dir;
721
- if (this.isRemainingItemsAdded) {
722
- totalShiftedItems += this.remainingItems - this._numScroll * dir;
723
- this.isRemainingItemsAdded = false;
695
+ totalShiftedItems += this._numScroll() * dir;
696
+ if (this.isRemainingItemsAdded()) {
697
+ totalShiftedItems += this.remainingItems() - this._numScroll() * dir;
698
+ this.isRemainingItemsAdded.set(false);
724
699
  }
725
- let originalShiftedItems = isCircular ? totalShiftedItems + this._numVisible : totalShiftedItems;
726
- page = Math.abs(Math.floor(originalShiftedItems / this._numScroll));
700
+ let originalShiftedItems = isCircular ? totalShiftedItems + this._numVisible() : totalShiftedItems;
701
+ page = Math.abs(Math.floor(originalShiftedItems / this._numScroll()));
727
702
  }
728
- if (isCircular && this.page === this.totalDots() - 1 && dir === -1) {
729
- totalShiftedItems = -1 * (this.value.length + this._numVisible);
703
+ if (isCircular && this._page() === this.totalDots() - 1 && dir === -1) {
704
+ totalShiftedItems = -1 * (this.value().length + this._numVisible());
730
705
  page = 0;
731
706
  }
732
- else if (isCircular && this.page === 0 && dir === 1) {
707
+ else if (isCircular && this._page() === 0 && dir === 1) {
733
708
  totalShiftedItems = 0;
734
709
  page = this.totalDots() - 1;
735
710
  }
736
- else if (page === this.totalDots() - 1 && this.remainingItems > 0) {
737
- totalShiftedItems += this.remainingItems * -1 - this._numScroll * dir;
738
- this.isRemainingItemsAdded = true;
711
+ else if (page === this.totalDots() - 1 && this.remainingItems() > 0) {
712
+ totalShiftedItems += this.remainingItems() * -1 - this._numScroll() * dir;
713
+ this.isRemainingItemsAdded.set(true);
739
714
  }
740
715
  const itemsContainer = this.itemsContainer();
741
716
  if (itemsContainer) {
742
717
  !this.$unstyled() && removeClass(itemsContainer.nativeElement, 'p-items-hidden');
743
- itemsContainer.nativeElement.style.transform = this.isVertical() ? `translate3d(0, ${totalShiftedItems * (100 / this._numVisible)}%, 0)` : `translate3d(${totalShiftedItems * (100 / this._numVisible)}%, 0, 0)`;
718
+ itemsContainer.nativeElement.style.transform = this.isVertical() ? `translate3d(0, ${totalShiftedItems * (100 / this._numVisible())}%, 0)` : `translate3d(${totalShiftedItems * (100 / this._numVisible())}%, 0, 0)`;
744
719
  itemsContainer.nativeElement.style.transition = 'transform 500ms ease 0s';
745
720
  }
746
- this.totalShiftedItems = totalShiftedItems;
747
- this._page = page;
721
+ this.totalShiftedItems.set(totalShiftedItems);
722
+ this._page.set(page);
748
723
  this.onPage.emit({
749
- page: this.page
724
+ page: this._page()
750
725
  });
751
- this.cd.markForCheck();
752
726
  }
753
727
  startAutoplay() {
754
- this.interval = setInterval(() => {
728
+ this.interval.set(setInterval(() => {
755
729
  if (this.totalDots() > 0) {
756
- if (this.page === this.totalDots() - 1) {
730
+ if (this._page() === this.totalDots() - 1) {
757
731
  this.step(-1, 0);
758
732
  }
759
733
  else {
760
- this.step(-1, this.page + 1);
734
+ this.step(-1, this._page() + 1);
761
735
  }
762
736
  }
763
- }, this.autoplayInterval);
764
- this.allowAutoplay = true;
765
- this.cd.markForCheck();
737
+ }, this.autoplayInterval()));
738
+ this.allowAutoplay.set(true);
766
739
  }
767
740
  stopAutoplay(changeAllow = true) {
768
- if (this.interval) {
769
- clearInterval(this.interval);
770
- this.interval = undefined;
741
+ if (this.interval()) {
742
+ clearInterval(this.interval());
743
+ this.interval.set(undefined);
771
744
  if (changeAllow) {
772
- this.allowAutoplay = false;
745
+ this.allowAutoplay.set(false);
773
746
  }
774
747
  }
775
- this.cd.markForCheck();
776
- }
777
- isPlaying() {
778
- return !!this.interval;
779
748
  }
749
+ isPlaying = computed(() => !!this.interval(), /* @ts-ignore */
750
+ ...(ngDevMode ? [{ debugName: "isPlaying" }] : /* istanbul ignore next */ []));
780
751
  onTransitionEnd() {
781
752
  const itemsContainer = this.itemsContainer();
782
753
  if (itemsContainer) {
783
754
  !this.$unstyled() && addClass(itemsContainer.nativeElement, 'p-items-hidden');
784
755
  itemsContainer.nativeElement.style.transition = '';
785
- if ((this.page === 0 || this.page === this.totalDots() - 1) && this.isCircular()) {
786
- itemsContainer.nativeElement.style.transform = this.isVertical() ? `translate3d(0, ${this.totalShiftedItems * (100 / this._numVisible)}%, 0)` : `translate3d(${this.totalShiftedItems * (100 / this._numVisible)}%, 0, 0)`;
756
+ if ((this._page() === 0 || this._page() === this.totalDots() - 1) && this.isCircular()) {
757
+ itemsContainer.nativeElement.style.transform = this.isVertical() ? `translate3d(0, ${this.totalShiftedItems() * (100 / this._numVisible())}%, 0)` : `translate3d(${this.totalShiftedItems() * (100 / this._numVisible())}%, 0, 0)`;
787
758
  }
788
759
  }
789
760
  }
790
761
  onTouchStart(e) {
791
762
  let touchobj = e.changedTouches[0];
792
- this.startPos = {
763
+ this.startPos.set({
793
764
  x: touchobj.pageX,
794
765
  y: touchobj.pageY
795
- };
766
+ });
796
767
  }
797
768
  onTouchMove(e) {
798
769
  if (e.cancelable) {
@@ -802,10 +773,10 @@ class Carousel extends BaseComponent {
802
773
  onTouchEnd(e) {
803
774
  let touchobj = e.changedTouches[0];
804
775
  if (this.isVertical()) {
805
- this.changePageOnTouch(e, touchobj.pageY - this.startPos.y);
776
+ this.changePageOnTouch(e, touchobj.pageY - this.startPos().y);
806
777
  }
807
778
  else {
808
- this.changePageOnTouch(e, touchobj.pageX - this.startPos.x);
779
+ this.changePageOnTouch(e, touchobj.pageX - this.startPos().x);
809
780
  }
810
781
  }
811
782
  changePageOnTouch(e, diff) {
@@ -836,7 +807,7 @@ class Carousel extends BaseComponent {
836
807
  getIndicatorPTOptions(key, index) {
837
808
  return this.ptm(key, {
838
809
  context: {
839
- highlighted: index === this._page
810
+ highlighted: index === this._page()
840
811
  }
841
812
  });
842
813
  }
@@ -852,75 +823,75 @@ class Carousel extends BaseComponent {
852
823
  }
853
824
  bindDocumentListeners() {
854
825
  if (isPlatformBrowser(this.platformId)) {
855
- if (!this.documentResizeListener) {
856
- this.documentResizeListener = this.renderer.listen(this.window, 'resize', (event) => {
826
+ if (!this.documentResizeListener()) {
827
+ this.documentResizeListener.set(this.renderer.listen(this.window, 'resize', (event) => {
857
828
  this.calculatePosition();
858
- });
829
+ }));
859
830
  }
860
831
  }
861
832
  }
862
833
  unbindDocumentListeners() {
863
834
  if (isPlatformBrowser(this.platformId)) {
864
- if (this.documentResizeListener) {
865
- this.documentResizeListener();
866
- this.documentResizeListener = null;
835
+ if (this.documentResizeListener()) {
836
+ this.documentResizeListener()();
837
+ this.documentResizeListener.set(null);
867
838
  }
868
839
  }
869
840
  }
870
841
  onDestroy() {
871
- if (this.responsiveOptions) {
842
+ if (this.responsiveOptions()) {
872
843
  this.unbindDocumentListeners();
873
844
  }
874
- if (this.autoplayInterval) {
845
+ if (this.autoplayInterval()) {
875
846
  this.stopAutoplay();
876
847
  }
877
848
  }
878
849
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: Carousel, deps: [], target: i0.ɵɵFactoryTarget.Component });
879
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.2.1", type: Carousel, isStandalone: true, selector: "p-carousel", inputs: { page: "page", numVisible: "numVisible", numScroll: "numScroll", responsiveOptions: "responsiveOptions", orientation: "orientation", verticalViewPortHeight: "verticalViewPortHeight", contentClass: "contentClass", indicatorsContentClass: "indicatorsContentClass", indicatorsContentStyle: "indicatorsContentStyle", indicatorStyleClass: "indicatorStyleClass", indicatorStyle: "indicatorStyle", value: "value", circular: ["circular", "circular", booleanAttribute], showIndicators: ["showIndicators", "showIndicators", booleanAttribute], showNavigators: ["showNavigators", "showNavigators", booleanAttribute], autoplayInterval: ["autoplayInterval", "autoplayInterval", numberAttribute], styleClass: "styleClass", prevButtonProps: "prevButtonProps", nextButtonProps: "nextButtonProps" }, outputs: { onPage: "onPage" }, host: { properties: { "attr.id": "id", "attr.role": "'region'", "class": "cn(cx('root'), styleClass)" } }, providers: [CarouselStyle, { provide: PARENT_INSTANCE, useExisting: Carousel }], queries: [{ propertyName: "headerFacet", first: true, predicate: Header, descendants: true, isSignal: true }, { propertyName: "footerFacet", first: true, predicate: Footer, descendants: true, isSignal: true }, { propertyName: "itemTemplate", first: true, predicate: ["item"], isSignal: true }, { propertyName: "headerTemplate", first: true, predicate: ["header"], isSignal: true }, { propertyName: "footerTemplate", first: true, predicate: ["footer"], isSignal: true }, { propertyName: "previousIconTemplate", first: true, predicate: ["previousicon"], isSignal: true }, { propertyName: "nextIconTemplate", first: true, predicate: ["nexticon"], isSignal: true }, { propertyName: "templates", predicate: PrimeTemplate, isSignal: true }], viewQueries: [{ propertyName: "itemsContainer", first: true, predicate: ["itemsContainer"], descendants: true, isSignal: true }, { propertyName: "indicatorContent", first: true, predicate: ["indicatorContent"], descendants: true, isSignal: true }], usesInheritance: true, hostDirectives: [{ directive: i1.Bind }], ngImport: i0, template: `
880
- <div [class]="cx('header')" *ngIf="headerFacet() || headerTemplate()" [pBind]="ptm('header')">
850
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "22.2.1", type: Carousel, isStandalone: true, selector: "p-carousel", inputs: { page: { classPropertyName: "page", publicName: "page", isSignal: true, isRequired: false, transformFunction: null }, numVisible: { classPropertyName: "numVisible", publicName: "numVisible", isSignal: true, isRequired: false, transformFunction: null }, numScroll: { classPropertyName: "numScroll", publicName: "numScroll", isSignal: true, isRequired: false, transformFunction: null }, responsiveOptions: { classPropertyName: "responsiveOptions", publicName: "responsiveOptions", isSignal: true, isRequired: false, transformFunction: null }, orientation: { classPropertyName: "orientation", publicName: "orientation", isSignal: true, isRequired: false, transformFunction: null }, verticalViewPortHeight: { classPropertyName: "verticalViewPortHeight", publicName: "verticalViewPortHeight", isSignal: true, isRequired: false, transformFunction: null }, contentClass: { classPropertyName: "contentClass", publicName: "contentClass", isSignal: true, isRequired: false, transformFunction: null }, indicatorsContentClass: { classPropertyName: "indicatorsContentClass", publicName: "indicatorsContentClass", isSignal: true, isRequired: false, transformFunction: null }, indicatorsContentStyle: { classPropertyName: "indicatorsContentStyle", publicName: "indicatorsContentStyle", isSignal: true, isRequired: false, transformFunction: null }, indicatorStyleClass: { classPropertyName: "indicatorStyleClass", publicName: "indicatorStyleClass", isSignal: true, isRequired: false, transformFunction: null }, indicatorStyle: { classPropertyName: "indicatorStyle", publicName: "indicatorStyle", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, circular: { classPropertyName: "circular", publicName: "circular", isSignal: true, isRequired: false, transformFunction: null }, showIndicators: { classPropertyName: "showIndicators", publicName: "showIndicators", isSignal: true, isRequired: false, transformFunction: null }, showNavigators: { classPropertyName: "showNavigators", publicName: "showNavigators", isSignal: true, isRequired: false, transformFunction: null }, autoplayInterval: { classPropertyName: "autoplayInterval", publicName: "autoplayInterval", isSignal: true, isRequired: false, transformFunction: null }, prevButtonProps: { classPropertyName: "prevButtonProps", publicName: "prevButtonProps", isSignal: true, isRequired: false, transformFunction: null }, nextButtonProps: { classPropertyName: "nextButtonProps", publicName: "nextButtonProps", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onPage: "onPage" }, host: { properties: { "attr.id": "id", "attr.role": "'region'", "class": "cx('root')" } }, providers: [CarouselStyle, { provide: PARENT_INSTANCE, useExisting: Carousel }], queries: [{ propertyName: "headerFacet", first: true, predicate: Header, descendants: true, isSignal: true }, { propertyName: "footerFacet", first: true, predicate: Footer, descendants: true, isSignal: true }, { propertyName: "itemTemplate", first: true, predicate: ["item"], isSignal: true }, { propertyName: "headerTemplate", first: true, predicate: ["header"], isSignal: true }, { propertyName: "footerTemplate", first: true, predicate: ["footer"], isSignal: true }, { propertyName: "previousIconTemplate", first: true, predicate: ["previousicon"], isSignal: true }, { propertyName: "nextIconTemplate", first: true, predicate: ["nexticon"], isSignal: true }, { propertyName: "templates", predicate: PrimeTemplate, isSignal: true }], viewQueries: [{ propertyName: "itemsContainer", first: true, predicate: ["itemsContainer"], descendants: true, isSignal: true }, { propertyName: "indicatorContent", first: true, predicate: ["indicatorContent"], descendants: true, isSignal: true }], usesInheritance: true, hostDirectives: [{ directive: i1.Bind }], ngImport: i0, template: `
851
+ <div [class]="cx('header')" *ngIf="headerFacet() || headerTemplate() || _headerTemplate()" [pBind]="ptm('header')">
881
852
  <ng-content select="p-header"></ng-content>
882
- <ng-container *ngTemplateOutlet="headerTemplate()"></ng-container>
853
+ <ng-container *ngTemplateOutlet="headerTemplate() || _headerTemplate()"></ng-container>
883
854
  </div>
884
- <div [class]="contentClass" [ngClass]="cx('contentContainer')" [pBind]="ptm('contentContainer')">
885
- <div [class]="cx('content')" [attr.aria-live]="allowAutoplay ? 'polite' : 'off'" [pBind]="ptm('content')">
855
+ <div [class]="contentClass()" [ngClass]="cx('contentContainer')" [pBind]="ptm('contentContainer')">
856
+ <div [class]="cx('content')" [attr.aria-live]="allowAutoplay() ? 'polite' : 'off'" [pBind]="ptm('content')">
886
857
  <p-button
887
- *ngIf="showNavigators"
858
+ *ngIf="showNavigators()"
888
859
  [class]="cx('pcPrevButton')"
889
860
  [attr.aria-label]="ariaPrevButtonLabel()"
890
861
  (click)="navBackward($event)"
891
862
  [text]="true"
892
- [buttonProps]="prevButtonProps"
863
+ [buttonProps]="prevButtonProps()"
893
864
  [pt]="ptm('pcPrevButton')"
894
865
  [unstyled]="unstyled()"
895
866
  attr.data-pc-group-section="navigator"
896
867
  >
897
868
  <ng-template #icon>
898
- <ng-container *ngIf="!previousIconTemplate() && !_previousIconTemplate && !prevButtonProps?.icon">
869
+ <ng-container *ngIf="!previousIconTemplate() && !_previousIconTemplate() && !prevButtonProps()?.icon">
899
870
  <svg data-p-icon="chevron-left" *ngIf="!isVertical()" />
900
871
  <svg data-p-icon="chevron-up" *ngIf="isVertical()" />
901
872
  </ng-container>
902
- <ng-container *ngIf="(previousIconTemplate() || _previousIconTemplate) && !prevButtonProps?.icon">
903
- <ng-template *ngTemplateOutlet="previousIconTemplate() || _previousIconTemplate"></ng-template>
873
+ <ng-container *ngIf="(previousIconTemplate() || _previousIconTemplate()) && !prevButtonProps()?.icon">
874
+ <ng-template *ngTemplateOutlet="previousIconTemplate() || _previousIconTemplate()"></ng-template>
904
875
  </ng-container>
905
876
  </ng-template>
906
877
  </p-button>
907
- <div [class]="cx('viewport')" [ngStyle]="{ height: isVertical() ? verticalViewPortHeight : 'auto' }" (touchend)="onTouchEnd($event)" (touchstart)="onTouchStart($event)" (touchmove)="onTouchMove($event)" [pBind]="ptm('viewport')">
878
+ <div [class]="cx('viewport')" [ngStyle]="{ height: isVertical() ? verticalViewPortHeight() : 'auto' }" (touchend)="onTouchEnd($event)" (touchstart)="onTouchStart($event)" (touchmove)="onTouchMove($event)" [pBind]="ptm('viewport')">
908
879
  <div #itemsContainer [class]="cx('itemList')" (transitionend)="onTransitionEnd()" [pBind]="ptm('itemList')">
909
880
  <div
910
- *ngFor="let item of clonedItemsForStarting; let index = index"
881
+ *ngFor="let item of clonedItemsForStarting(); let index = index"
911
882
  [class]="cx('itemClone', { index })"
912
- [attr.aria-hidden]="!(totalShiftedItems * -1 === value.length)"
883
+ [attr.aria-hidden]="!(totalShiftedItems() * -1 === value().length)"
913
884
  [attr.aria-label]="ariaSlideNumber(index)"
914
885
  [attr.aria-roledescription]="ariaSlideLabel()"
915
- [attr.data-p-carousel-item-active]="totalShiftedItems * -1 === value.length + _numVisible"
886
+ [attr.data-p-carousel-item-active]="totalShiftedItems() * -1 === value().length + _numVisible()"
916
887
  [attr.data-p-carousel-item-start]="index === 0"
917
- [attr.data-p-carousel-item-end]="clonedItemsForStarting && clonedItemsForStarting.length - 1 === index"
888
+ [attr.data-p-carousel-item-end]="clonedItemsForStarting().length - 1 === index"
918
889
  [pBind]="ptm('itemClone')"
919
890
  >
920
- <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: item }"></ng-container>
891
+ <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: item }"></ng-container>
921
892
  </div>
922
893
  <div
923
- *ngFor="let item of value; let index = index"
894
+ *ngFor="let item of value(); let index = index"
924
895
  [class]="cx('item', { index })"
925
896
  role="group"
926
897
  [attr.aria-hidden]="!(firstIndex() <= index && lastIndex() >= index)"
@@ -931,115 +902,114 @@ class Carousel extends BaseComponent {
931
902
  [attr.data-p-carousel-item-end]="lastIndex() === index"
932
903
  [pBind]="getItemPTOptions('item', index)"
933
904
  >
934
- <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: item }"></ng-container>
905
+ <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: item }"></ng-container>
935
906
  </div>
936
907
  <div
937
- *ngFor="let item of clonedItemsForFinishing; let index = index"
908
+ *ngFor="let item of clonedItemsForFinishing(); let index = index"
938
909
  [class]="cx('itemClone', { index })"
939
910
  [attr.data-p-carousel-item-active]="false"
940
911
  [attr.data-p-carousel-item-start]="false"
941
912
  [attr.data-p-carousel-item-end]="false"
942
913
  [pBind]="ptm('itemClone')"
943
914
  >
944
- <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: item }"></ng-container>
915
+ <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: item }"></ng-container>
945
916
  </div>
946
917
  </div>
947
918
  </div>
948
919
  <p-button
949
920
  type="button"
950
- *ngIf="showNavigators"
921
+ *ngIf="showNavigators()"
951
922
  [class]="cx('pcNextButton')"
952
923
  (click)="navForward($event)"
953
924
  [attr.aria-label]="ariaNextButtonLabel()"
954
- [buttonProps]="nextButtonProps"
925
+ [buttonProps]="nextButtonProps()"
955
926
  [text]="true"
956
927
  [pt]="ptm('pcNextButton')"
957
928
  [unstyled]="unstyled()"
958
929
  attr.data-pc-group-section="navigator"
959
930
  >
960
931
  <ng-template #icon>
961
- <ng-container *ngIf="!nextIconTemplate() && !_nextIconTemplate && !nextButtonProps?.icon">
932
+ <ng-container *ngIf="!nextIconTemplate() && !_nextIconTemplate() && !nextButtonProps()?.icon">
962
933
  <svg data-p-icon="chevron-right" *ngIf="!isVertical()" />
963
934
  <svg data-p-icon="chevron-down" *ngIf="isVertical()" />
964
935
  </ng-container>
965
- <span *ngIf="nextIconTemplate() || (_nextIconTemplate && !nextButtonProps?.icon)">
966
- <ng-template *ngTemplateOutlet="nextIconTemplate() || _nextIconTemplate"></ng-template>
936
+ <span *ngIf="nextIconTemplate() || (_nextIconTemplate() && !nextButtonProps()?.icon)">
937
+ <ng-template *ngTemplateOutlet="nextIconTemplate() || _nextIconTemplate()"></ng-template>
967
938
  </span>
968
939
  </ng-template>
969
940
  </p-button>
970
941
  </div>
971
- <ul #indicatorContent [class]="cx('indicatorList')" [ngStyle]="indicatorsContentStyle" *ngIf="showIndicators" (keydown)="onIndicatorKeydown($event)" [pBind]="ptm('indicatorList')">
972
- <li *ngFor="let totalDot of totalDotsArray(); let i = index" [class]="cx('indicator', { index: i })" [attr.data-p-active]="_page === i" [pBind]="getIndicatorPTOptions('indicator', i)">
942
+ <ul #indicatorContent [class]="cx('indicatorList')" [ngStyle]="indicatorsContentStyle()" *ngIf="showIndicators()" (keydown)="onIndicatorKeydown($event)" [pBind]="ptm('indicatorList')">
943
+ <li *ngFor="let totalDot of totalDotsArray(); let i = index" [class]="cx('indicator', { index: i })" [attr.data-p-active]="_page() === i" [pBind]="getIndicatorPTOptions('indicator', i)">
973
944
  <button
974
945
  type="button"
975
946
  [class]="cx('indicatorButton')"
976
947
  (click)="onDotClick($event, i)"
977
- [ngStyle]="indicatorStyle"
948
+ [ngStyle]="indicatorStyle()"
978
949
  [attr.aria-label]="ariaPageLabel(i + 1)"
979
- [attr.aria-current]="_page === i ? 'page' : undefined"
980
- [tabindex]="_page === i ? 0 : -1"
950
+ [attr.aria-current]="_page() === i ? 'page' : undefined"
951
+ [tabindex]="_page() === i ? 0 : -1"
981
952
  [pBind]="getIndicatorPTOptions('indicatorButton', i)"
982
953
  ></button>
983
954
  </li>
984
955
  </ul>
985
956
  </div>
986
- <div [class]="cx('footer')" *ngIf="footerFacet() || footerTemplate() || _footerTemplate" [pBind]="ptm('footer')">
957
+ <div [class]="cx('footer')" *ngIf="footerFacet() || footerTemplate() || _footerTemplate()" [pBind]="ptm('footer')">
987
958
  <ng-content select="p-footer"></ng-content>
988
- <ng-container *ngTemplateOutlet="footerTemplate() || _footerTemplate"></ng-container>
959
+ <ng-container *ngTemplateOutlet="footerTemplate() || _footerTemplate()"></ng-container>
989
960
  </div>
990
- `, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: ChevronRightIcon, selector: "[data-p-icon=\"chevron-right\"]" }, { kind: "ngmodule", type: ButtonModule }, { kind: "component", type: i3.Button, selector: "p-button", inputs: ["hostName", "type", "badge", "disabled", "raised", "rounded", "text", "plain", "outlined", "link", "tabindex", "size", "variant", "style", "styleClass", "badgeClass", "badgeSeverity", "ariaLabel", "autofocus", "iconPos", "icon", "label", "loading", "loadingIcon", "severity", "buttonProps", "fluid"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: ChevronLeftIcon, selector: "[data-p-icon=\"chevron-left\"]" }, { kind: "component", type: ChevronDownIcon, selector: "[data-p-icon=\"chevron-down\"]" }, { kind: "component", type: ChevronUpIcon, selector: "[data-p-icon=\"chevron-up\"]" }, { kind: "ngmodule", type: SharedModule }, { kind: "ngmodule", type: BindModule }, { kind: "directive", type: i1.Bind, selector: "[pBind]", inputs: ["pBind"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
961
+ `, isInline: true, dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "component", type: ChevronRightIcon, selector: "[data-p-icon=\"chevron-right\"]" }, { kind: "ngmodule", type: ButtonModule }, { kind: "component", type: i3.Button, selector: "p-button", inputs: ["hostName", "type", "badge", "disabled", "raised", "rounded", "text", "plain", "outlined", "link", "tabindex", "size", "variant", "style", "styleClass", "badgeSeverity", "ariaLabel", "autofocus", "iconPos", "icon", "label", "loading", "loadingIcon", "severity", "buttonProps", "fluid"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "component", type: ChevronLeftIcon, selector: "[data-p-icon=\"chevron-left\"]" }, { kind: "component", type: ChevronDownIcon, selector: "[data-p-icon=\"chevron-down\"]" }, { kind: "component", type: ChevronUpIcon, selector: "[data-p-icon=\"chevron-up\"]" }, { kind: "ngmodule", type: SharedModule }, { kind: "ngmodule", type: BindModule }, { kind: "directive", type: i1.Bind, selector: "[pBind]", inputs: ["pBind"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
991
962
  }
992
963
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: Carousel, decorators: [{
993
964
  type: Component,
994
965
  args: [{
995
966
  selector: 'p-carousel',
996
- standalone: true,
997
967
  imports: [CommonModule, ChevronRightIcon, ButtonModule, ChevronLeftIcon, ChevronDownIcon, ChevronUpIcon, SharedModule, BindModule],
998
968
  template: `
999
- <div [class]="cx('header')" *ngIf="headerFacet() || headerTemplate()" [pBind]="ptm('header')">
969
+ <div [class]="cx('header')" *ngIf="headerFacet() || headerTemplate() || _headerTemplate()" [pBind]="ptm('header')">
1000
970
  <ng-content select="p-header"></ng-content>
1001
- <ng-container *ngTemplateOutlet="headerTemplate()"></ng-container>
971
+ <ng-container *ngTemplateOutlet="headerTemplate() || _headerTemplate()"></ng-container>
1002
972
  </div>
1003
- <div [class]="contentClass" [ngClass]="cx('contentContainer')" [pBind]="ptm('contentContainer')">
1004
- <div [class]="cx('content')" [attr.aria-live]="allowAutoplay ? 'polite' : 'off'" [pBind]="ptm('content')">
973
+ <div [class]="contentClass()" [ngClass]="cx('contentContainer')" [pBind]="ptm('contentContainer')">
974
+ <div [class]="cx('content')" [attr.aria-live]="allowAutoplay() ? 'polite' : 'off'" [pBind]="ptm('content')">
1005
975
  <p-button
1006
- *ngIf="showNavigators"
976
+ *ngIf="showNavigators()"
1007
977
  [class]="cx('pcPrevButton')"
1008
978
  [attr.aria-label]="ariaPrevButtonLabel()"
1009
979
  (click)="navBackward($event)"
1010
980
  [text]="true"
1011
- [buttonProps]="prevButtonProps"
981
+ [buttonProps]="prevButtonProps()"
1012
982
  [pt]="ptm('pcPrevButton')"
1013
983
  [unstyled]="unstyled()"
1014
984
  attr.data-pc-group-section="navigator"
1015
985
  >
1016
986
  <ng-template #icon>
1017
- <ng-container *ngIf="!previousIconTemplate() && !_previousIconTemplate && !prevButtonProps?.icon">
987
+ <ng-container *ngIf="!previousIconTemplate() && !_previousIconTemplate() && !prevButtonProps()?.icon">
1018
988
  <svg data-p-icon="chevron-left" *ngIf="!isVertical()" />
1019
989
  <svg data-p-icon="chevron-up" *ngIf="isVertical()" />
1020
990
  </ng-container>
1021
- <ng-container *ngIf="(previousIconTemplate() || _previousIconTemplate) && !prevButtonProps?.icon">
1022
- <ng-template *ngTemplateOutlet="previousIconTemplate() || _previousIconTemplate"></ng-template>
991
+ <ng-container *ngIf="(previousIconTemplate() || _previousIconTemplate()) && !prevButtonProps()?.icon">
992
+ <ng-template *ngTemplateOutlet="previousIconTemplate() || _previousIconTemplate()"></ng-template>
1023
993
  </ng-container>
1024
994
  </ng-template>
1025
995
  </p-button>
1026
- <div [class]="cx('viewport')" [ngStyle]="{ height: isVertical() ? verticalViewPortHeight : 'auto' }" (touchend)="onTouchEnd($event)" (touchstart)="onTouchStart($event)" (touchmove)="onTouchMove($event)" [pBind]="ptm('viewport')">
996
+ <div [class]="cx('viewport')" [ngStyle]="{ height: isVertical() ? verticalViewPortHeight() : 'auto' }" (touchend)="onTouchEnd($event)" (touchstart)="onTouchStart($event)" (touchmove)="onTouchMove($event)" [pBind]="ptm('viewport')">
1027
997
  <div #itemsContainer [class]="cx('itemList')" (transitionend)="onTransitionEnd()" [pBind]="ptm('itemList')">
1028
998
  <div
1029
- *ngFor="let item of clonedItemsForStarting; let index = index"
999
+ *ngFor="let item of clonedItemsForStarting(); let index = index"
1030
1000
  [class]="cx('itemClone', { index })"
1031
- [attr.aria-hidden]="!(totalShiftedItems * -1 === value.length)"
1001
+ [attr.aria-hidden]="!(totalShiftedItems() * -1 === value().length)"
1032
1002
  [attr.aria-label]="ariaSlideNumber(index)"
1033
1003
  [attr.aria-roledescription]="ariaSlideLabel()"
1034
- [attr.data-p-carousel-item-active]="totalShiftedItems * -1 === value.length + _numVisible"
1004
+ [attr.data-p-carousel-item-active]="totalShiftedItems() * -1 === value().length + _numVisible()"
1035
1005
  [attr.data-p-carousel-item-start]="index === 0"
1036
- [attr.data-p-carousel-item-end]="clonedItemsForStarting && clonedItemsForStarting.length - 1 === index"
1006
+ [attr.data-p-carousel-item-end]="clonedItemsForStarting().length - 1 === index"
1037
1007
  [pBind]="ptm('itemClone')"
1038
1008
  >
1039
- <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: item }"></ng-container>
1009
+ <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: item }"></ng-container>
1040
1010
  </div>
1041
1011
  <div
1042
- *ngFor="let item of value; let index = index"
1012
+ *ngFor="let item of value(); let index = index"
1043
1013
  [class]="cx('item', { index })"
1044
1014
  role="group"
1045
1015
  [attr.aria-hidden]="!(firstIndex() <= index && lastIndex() >= index)"
@@ -1050,61 +1020,61 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImpor
1050
1020
  [attr.data-p-carousel-item-end]="lastIndex() === index"
1051
1021
  [pBind]="getItemPTOptions('item', index)"
1052
1022
  >
1053
- <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: item }"></ng-container>
1023
+ <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: item }"></ng-container>
1054
1024
  </div>
1055
1025
  <div
1056
- *ngFor="let item of clonedItemsForFinishing; let index = index"
1026
+ *ngFor="let item of clonedItemsForFinishing(); let index = index"
1057
1027
  [class]="cx('itemClone', { index })"
1058
1028
  [attr.data-p-carousel-item-active]="false"
1059
1029
  [attr.data-p-carousel-item-start]="false"
1060
1030
  [attr.data-p-carousel-item-end]="false"
1061
1031
  [pBind]="ptm('itemClone')"
1062
1032
  >
1063
- <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate; context: { $implicit: item }"></ng-container>
1033
+ <ng-container *ngTemplateOutlet="itemTemplate() || _itemTemplate(); context: { $implicit: item }"></ng-container>
1064
1034
  </div>
1065
1035
  </div>
1066
1036
  </div>
1067
1037
  <p-button
1068
1038
  type="button"
1069
- *ngIf="showNavigators"
1039
+ *ngIf="showNavigators()"
1070
1040
  [class]="cx('pcNextButton')"
1071
1041
  (click)="navForward($event)"
1072
1042
  [attr.aria-label]="ariaNextButtonLabel()"
1073
- [buttonProps]="nextButtonProps"
1043
+ [buttonProps]="nextButtonProps()"
1074
1044
  [text]="true"
1075
1045
  [pt]="ptm('pcNextButton')"
1076
1046
  [unstyled]="unstyled()"
1077
1047
  attr.data-pc-group-section="navigator"
1078
1048
  >
1079
1049
  <ng-template #icon>
1080
- <ng-container *ngIf="!nextIconTemplate() && !_nextIconTemplate && !nextButtonProps?.icon">
1050
+ <ng-container *ngIf="!nextIconTemplate() && !_nextIconTemplate() && !nextButtonProps()?.icon">
1081
1051
  <svg data-p-icon="chevron-right" *ngIf="!isVertical()" />
1082
1052
  <svg data-p-icon="chevron-down" *ngIf="isVertical()" />
1083
1053
  </ng-container>
1084
- <span *ngIf="nextIconTemplate() || (_nextIconTemplate && !nextButtonProps?.icon)">
1085
- <ng-template *ngTemplateOutlet="nextIconTemplate() || _nextIconTemplate"></ng-template>
1054
+ <span *ngIf="nextIconTemplate() || (_nextIconTemplate() && !nextButtonProps()?.icon)">
1055
+ <ng-template *ngTemplateOutlet="nextIconTemplate() || _nextIconTemplate()"></ng-template>
1086
1056
  </span>
1087
1057
  </ng-template>
1088
1058
  </p-button>
1089
1059
  </div>
1090
- <ul #indicatorContent [class]="cx('indicatorList')" [ngStyle]="indicatorsContentStyle" *ngIf="showIndicators" (keydown)="onIndicatorKeydown($event)" [pBind]="ptm('indicatorList')">
1091
- <li *ngFor="let totalDot of totalDotsArray(); let i = index" [class]="cx('indicator', { index: i })" [attr.data-p-active]="_page === i" [pBind]="getIndicatorPTOptions('indicator', i)">
1060
+ <ul #indicatorContent [class]="cx('indicatorList')" [ngStyle]="indicatorsContentStyle()" *ngIf="showIndicators()" (keydown)="onIndicatorKeydown($event)" [pBind]="ptm('indicatorList')">
1061
+ <li *ngFor="let totalDot of totalDotsArray(); let i = index" [class]="cx('indicator', { index: i })" [attr.data-p-active]="_page() === i" [pBind]="getIndicatorPTOptions('indicator', i)">
1092
1062
  <button
1093
1063
  type="button"
1094
1064
  [class]="cx('indicatorButton')"
1095
1065
  (click)="onDotClick($event, i)"
1096
- [ngStyle]="indicatorStyle"
1066
+ [ngStyle]="indicatorStyle()"
1097
1067
  [attr.aria-label]="ariaPageLabel(i + 1)"
1098
- [attr.aria-current]="_page === i ? 'page' : undefined"
1099
- [tabindex]="_page === i ? 0 : -1"
1068
+ [attr.aria-current]="_page() === i ? 'page' : undefined"
1069
+ [tabindex]="_page() === i ? 0 : -1"
1100
1070
  [pBind]="getIndicatorPTOptions('indicatorButton', i)"
1101
1071
  ></button>
1102
1072
  </li>
1103
1073
  </ul>
1104
1074
  </div>
1105
- <div [class]="cx('footer')" *ngIf="footerFacet() || footerTemplate() || _footerTemplate" [pBind]="ptm('footer')">
1075
+ <div [class]="cx('footer')" *ngIf="footerFacet() || footerTemplate() || _footerTemplate()" [pBind]="ptm('footer')">
1106
1076
  <ng-content select="p-footer"></ng-content>
1107
- <ng-container *ngTemplateOutlet="footerTemplate() || _footerTemplate"></ng-container>
1077
+ <ng-container *ngTemplateOutlet="footerTemplate() || _footerTemplate()"></ng-container>
1108
1078
  </div>
1109
1079
  `,
1110
1080
  changeDetection: ChangeDetectionStrategy.OnPush,
@@ -1114,52 +1084,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.2.1", ngImpor
1114
1084
  host: {
1115
1085
  '[attr.id]': 'id',
1116
1086
  '[attr.role]': "'region'",
1117
- '[class]': "cn(cx('root'), styleClass)"
1087
+ '[class]': "cx('root')"
1118
1088
  }
1119
1089
  }]
1120
- }], ctorParameters: () => [], propDecorators: { page: [{
1121
- type: Input
1122
- }], numVisible: [{
1123
- type: Input
1124
- }], numScroll: [{
1125
- type: Input
1126
- }], responsiveOptions: [{
1127
- type: Input
1128
- }], orientation: [{
1129
- type: Input
1130
- }], verticalViewPortHeight: [{
1131
- type: Input
1132
- }], contentClass: [{
1133
- type: Input
1134
- }], indicatorsContentClass: [{
1135
- type: Input
1136
- }], indicatorsContentStyle: [{
1137
- type: Input
1138
- }], indicatorStyleClass: [{
1139
- type: Input
1140
- }], indicatorStyle: [{
1141
- type: Input
1142
- }], value: [{
1143
- type: Input
1144
- }], circular: [{
1145
- type: Input,
1146
- args: [{ transform: booleanAttribute }]
1147
- }], showIndicators: [{
1148
- type: Input,
1149
- args: [{ transform: booleanAttribute }]
1150
- }], showNavigators: [{
1151
- type: Input,
1152
- args: [{ transform: booleanAttribute }]
1153
- }], autoplayInterval: [{
1154
- type: Input,
1155
- args: [{ transform: numberAttribute }]
1156
- }], styleClass: [{
1157
- type: Input
1158
- }], prevButtonProps: [{
1159
- type: Input
1160
- }], nextButtonProps: [{
1161
- type: Input
1162
- }], onPage: [{ type: i0.Output, args: ["onPage"] }], itemsContainer: [{ type: i0.ViewChild, args: ['itemsContainer', { isSignal: true }] }], indicatorContent: [{ type: i0.ViewChild, args: ['indicatorContent', { isSignal: true }] }], headerFacet: [{ type: i0.ContentChild, args: [i0.forwardRef(() => Header), { isSignal: true }] }], footerFacet: [{ type: i0.ContentChild, args: [i0.forwardRef(() => Footer), { isSignal: true }] }], itemTemplate: [{ type: i0.ContentChild, args: ['item', { ...{ descendants: false }, isSignal: true }] }], headerTemplate: [{ type: i0.ContentChild, args: ['header', { ...{ descendants: false }, isSignal: true }] }], footerTemplate: [{ type: i0.ContentChild, args: ['footer', { ...{ descendants: false }, isSignal: true }] }], previousIconTemplate: [{ type: i0.ContentChild, args: ['previousicon', { ...{ descendants: false }, isSignal: true }] }], nextIconTemplate: [{ type: i0.ContentChild, args: ['nexticon', { ...{ descendants: false }, isSignal: true }] }], templates: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => PrimeTemplate), { isSignal: true }] }] } });
1090
+ }], ctorParameters: () => [], propDecorators: { page: [{ type: i0.Input, args: [{ isSignal: true, alias: "page", required: false }] }], numVisible: [{ type: i0.Input, args: [{ isSignal: true, alias: "numVisible", required: false }] }], numScroll: [{ type: i0.Input, args: [{ isSignal: true, alias: "numScroll", required: false }] }], responsiveOptions: [{ type: i0.Input, args: [{ isSignal: true, alias: "responsiveOptions", required: false }] }], orientation: [{ type: i0.Input, args: [{ isSignal: true, alias: "orientation", required: false }] }], verticalViewPortHeight: [{ type: i0.Input, args: [{ isSignal: true, alias: "verticalViewPortHeight", required: false }] }], contentClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "contentClass", required: false }] }], indicatorsContentClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "indicatorsContentClass", required: false }] }], indicatorsContentStyle: [{ type: i0.Input, args: [{ isSignal: true, alias: "indicatorsContentStyle", required: false }] }], indicatorStyleClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "indicatorStyleClass", required: false }] }], indicatorStyle: [{ type: i0.Input, args: [{ isSignal: true, alias: "indicatorStyle", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }], circular: [{ type: i0.Input, args: [{ isSignal: true, alias: "circular", required: false }] }], showIndicators: [{ type: i0.Input, args: [{ isSignal: true, alias: "showIndicators", required: false }] }], showNavigators: [{ type: i0.Input, args: [{ isSignal: true, alias: "showNavigators", required: false }] }], autoplayInterval: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoplayInterval", required: false }] }], prevButtonProps: [{ type: i0.Input, args: [{ isSignal: true, alias: "prevButtonProps", required: false }] }], nextButtonProps: [{ type: i0.Input, args: [{ isSignal: true, alias: "nextButtonProps", required: false }] }], onPage: [{ type: i0.Output, args: ["onPage"] }], itemsContainer: [{ type: i0.ViewChild, args: ['itemsContainer', { isSignal: true }] }], indicatorContent: [{ type: i0.ViewChild, args: ['indicatorContent', { isSignal: true }] }], headerFacet: [{ type: i0.ContentChild, args: [i0.forwardRef(() => Header), { isSignal: true }] }], footerFacet: [{ type: i0.ContentChild, args: [i0.forwardRef(() => Footer), { isSignal: true }] }], itemTemplate: [{ type: i0.ContentChild, args: ['item', { ...{ descendants: false }, isSignal: true }] }], headerTemplate: [{ type: i0.ContentChild, args: ['header', { ...{ descendants: false }, isSignal: true }] }], footerTemplate: [{ type: i0.ContentChild, args: ['footer', { ...{ descendants: false }, isSignal: true }] }], previousIconTemplate: [{ type: i0.ContentChild, args: ['previousicon', { ...{ descendants: false }, isSignal: true }] }], nextIconTemplate: [{ type: i0.ContentChild, args: ['nexticon', { ...{ descendants: false }, isSignal: true }] }], templates: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => PrimeTemplate), { isSignal: true }] }] } });
1163
1091
  class CarouselModule {
1164
1092
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.2.1", ngImport: i0, type: CarouselModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
1165
1093
  static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "22.2.1", ngImport: i0, type: CarouselModule, imports: [Carousel, SharedModule], exports: [Carousel, SharedModule] });