@rt-tools/ui-kit-v2 0.23.3 → 0.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (354) hide show
  1. package/fesm2022/rt-tools-ui-kit-v2-accordion.mjs +142 -71
  2. package/fesm2022/rt-tools-ui-kit-v2-accordion.mjs.map +1 -1
  3. package/fesm2022/rt-tools-ui-kit-v2-action-bar.mjs +467 -231
  4. package/fesm2022/rt-tools-ui-kit-v2-action-bar.mjs.map +1 -1
  5. package/fesm2022/rt-tools-ui-kit-v2-ai-run-status.mjs +260 -91
  6. package/fesm2022/rt-tools-ui-kit-v2-ai-run-status.mjs.map +1 -1
  7. package/fesm2022/rt-tools-ui-kit-v2-aside-section.mjs +80 -46
  8. package/fesm2022/rt-tools-ui-kit-v2-aside-section.mjs.map +1 -1
  9. package/fesm2022/rt-tools-ui-kit-v2-aside.mjs +984 -697
  10. package/fesm2022/rt-tools-ui-kit-v2-aside.mjs.map +1 -1
  11. package/fesm2022/rt-tools-ui-kit-v2-autocomplete.mjs +452 -210
  12. package/fesm2022/rt-tools-ui-kit-v2-autocomplete.mjs.map +1 -1
  13. package/fesm2022/rt-tools-ui-kit-v2-bar-list.mjs +143 -52
  14. package/fesm2022/rt-tools-ui-kit-v2-bar-list.mjs.map +1 -1
  15. package/fesm2022/rt-tools-ui-kit-v2-bottom-sheet.mjs +158 -83
  16. package/fesm2022/rt-tools-ui-kit-v2-bottom-sheet.mjs.map +1 -1
  17. package/fesm2022/rt-tools-ui-kit-v2-breadcrumbs.mjs +335 -0
  18. package/fesm2022/rt-tools-ui-kit-v2-breadcrumbs.mjs.map +1 -0
  19. package/fesm2022/rt-tools-ui-kit-v2-button.mjs +437 -363
  20. package/fesm2022/rt-tools-ui-kit-v2-button.mjs.map +1 -1
  21. package/fesm2022/rt-tools-ui-kit-v2-calendar.mjs +430 -149
  22. package/fesm2022/rt-tools-ui-kit-v2-calendar.mjs.map +1 -1
  23. package/fesm2022/rt-tools-ui-kit-v2-card.mjs +155 -71
  24. package/fesm2022/rt-tools-ui-kit-v2-card.mjs.map +1 -1
  25. package/fesm2022/rt-tools-ui-kit-v2-carousel.mjs +155 -0
  26. package/fesm2022/rt-tools-ui-kit-v2-carousel.mjs.map +1 -0
  27. package/fesm2022/rt-tools-ui-kit-v2-checkbox.mjs +215 -110
  28. package/fesm2022/rt-tools-ui-kit-v2-checkbox.mjs.map +1 -1
  29. package/fesm2022/rt-tools-ui-kit-v2-collapsible-text.mjs +158 -75
  30. package/fesm2022/rt-tools-ui-kit-v2-collapsible-text.mjs.map +1 -1
  31. package/fesm2022/rt-tools-ui-kit-v2-color-palette.mjs +769 -0
  32. package/fesm2022/rt-tools-ui-kit-v2-color-palette.mjs.map +1 -0
  33. package/fesm2022/rt-tools-ui-kit-v2-confirm-popover.mjs +462 -253
  34. package/fesm2022/rt-tools-ui-kit-v2-confirm-popover.mjs.map +1 -1
  35. package/fesm2022/rt-tools-ui-kit-v2-container.mjs +1276 -1316
  36. package/fesm2022/rt-tools-ui-kit-v2-container.mjs.map +1 -1
  37. package/fesm2022/rt-tools-ui-kit-v2-copy-value.mjs +185 -80
  38. package/fesm2022/rt-tools-ui-kit-v2-copy-value.mjs.map +1 -1
  39. package/fesm2022/rt-tools-ui-kit-v2-core.mjs +2321 -2619
  40. package/fesm2022/rt-tools-ui-kit-v2-core.mjs.map +1 -1
  41. package/fesm2022/rt-tools-ui-kit-v2-counter-row.mjs +100 -44
  42. package/fesm2022/rt-tools-ui-kit-v2-counter-row.mjs.map +1 -1
  43. package/fesm2022/rt-tools-ui-kit-v2-counter.mjs +290 -155
  44. package/fesm2022/rt-tools-ui-kit-v2-counter.mjs.map +1 -1
  45. package/fesm2022/rt-tools-ui-kit-v2-data-list.mjs +2097 -858
  46. package/fesm2022/rt-tools-ui-kit-v2-data-list.mjs.map +1 -1
  47. package/fesm2022/rt-tools-ui-kit-v2-data-table.mjs +2247 -1176
  48. package/fesm2022/rt-tools-ui-kit-v2-data-table.mjs.map +1 -1
  49. package/fesm2022/rt-tools-ui-kit-v2-date-picker.mjs +1043 -705
  50. package/fesm2022/rt-tools-ui-kit-v2-date-picker.mjs.map +1 -1
  51. package/fesm2022/rt-tools-ui-kit-v2-date-range.mjs +810 -525
  52. package/fesm2022/rt-tools-ui-kit-v2-date-range.mjs.map +1 -1
  53. package/fesm2022/rt-tools-ui-kit-v2-delta-view.mjs +158 -138
  54. package/fesm2022/rt-tools-ui-kit-v2-delta-view.mjs.map +1 -1
  55. package/fesm2022/rt-tools-ui-kit-v2-detail-list.mjs +177 -67
  56. package/fesm2022/rt-tools-ui-kit-v2-detail-list.mjs.map +1 -1
  57. package/fesm2022/rt-tools-ui-kit-v2-dialog.mjs +550 -477
  58. package/fesm2022/rt-tools-ui-kit-v2-dialog.mjs.map +1 -1
  59. package/fesm2022/rt-tools-ui-kit-v2-dot-field.mjs +185 -168
  60. package/fesm2022/rt-tools-ui-kit-v2-dot-field.mjs.map +1 -1
  61. package/fesm2022/rt-tools-ui-kit-v2-download-link.mjs +116 -43
  62. package/fesm2022/rt-tools-ui-kit-v2-download-link.mjs.map +1 -1
  63. package/fesm2022/rt-tools-ui-kit-v2-draggable-tree.mjs +585 -0
  64. package/fesm2022/rt-tools-ui-kit-v2-draggable-tree.mjs.map +1 -0
  65. package/fesm2022/rt-tools-ui-kit-v2-dynamic-list.mjs +755 -259
  66. package/fesm2022/rt-tools-ui-kit-v2-dynamic-list.mjs.map +1 -1
  67. package/fesm2022/rt-tools-ui-kit-v2-dynamic-selector.mjs +3266 -1115
  68. package/fesm2022/rt-tools-ui-kit-v2-dynamic-selector.mjs.map +1 -1
  69. package/fesm2022/rt-tools-ui-kit-v2-empty-state.mjs +190 -55
  70. package/fesm2022/rt-tools-ui-kit-v2-empty-state.mjs.map +1 -1
  71. package/fesm2022/rt-tools-ui-kit-v2-expansion-panel.mjs +283 -103
  72. package/fesm2022/rt-tools-ui-kit-v2-expansion-panel.mjs.map +1 -1
  73. package/fesm2022/rt-tools-ui-kit-v2-field.mjs +393 -177
  74. package/fesm2022/rt-tools-ui-kit-v2-field.mjs.map +1 -1
  75. package/fesm2022/rt-tools-ui-kit-v2-file-card.mjs +399 -207
  76. package/fesm2022/rt-tools-ui-kit-v2-file-card.mjs.map +1 -1
  77. package/fesm2022/rt-tools-ui-kit-v2-file-drop.mjs +288 -212
  78. package/fesm2022/rt-tools-ui-kit-v2-file-drop.mjs.map +1 -1
  79. package/fesm2022/rt-tools-ui-kit-v2-file-input.mjs +262 -116
  80. package/fesm2022/rt-tools-ui-kit-v2-file-input.mjs.map +1 -1
  81. package/fesm2022/rt-tools-ui-kit-v2-file-list.mjs +57 -31
  82. package/fesm2022/rt-tools-ui-kit-v2-file-list.mjs.map +1 -1
  83. package/fesm2022/rt-tools-ui-kit-v2-filter-control.mjs +258 -90
  84. package/fesm2022/rt-tools-ui-kit-v2-filter-control.mjs.map +1 -1
  85. package/fesm2022/rt-tools-ui-kit-v2-form-control.mjs +249 -215
  86. package/fesm2022/rt-tools-ui-kit-v2-form-control.mjs.map +1 -1
  87. package/fesm2022/rt-tools-ui-kit-v2-header.mjs +199 -71
  88. package/fesm2022/rt-tools-ui-kit-v2-header.mjs.map +1 -1
  89. package/fesm2022/rt-tools-ui-kit-v2-hybrid-tree-selector.mjs +231 -0
  90. package/fesm2022/rt-tools-ui-kit-v2-hybrid-tree-selector.mjs.map +1 -0
  91. package/fesm2022/rt-tools-ui-kit-v2-hybrid-tree.mjs +336 -0
  92. package/fesm2022/rt-tools-ui-kit-v2-hybrid-tree.mjs.map +1 -0
  93. package/fesm2022/rt-tools-ui-kit-v2-icon-button.mjs +451 -162
  94. package/fesm2022/rt-tools-ui-kit-v2-icon-button.mjs.map +1 -1
  95. package/fesm2022/rt-tools-ui-kit-v2-icon.mjs +931 -686
  96. package/fesm2022/rt-tools-ui-kit-v2-icon.mjs.map +1 -1
  97. package/fesm2022/rt-tools-ui-kit-v2-image-cropper.mjs +664 -491
  98. package/fesm2022/rt-tools-ui-kit-v2-image-cropper.mjs.map +1 -1
  99. package/fesm2022/rt-tools-ui-kit-v2-image-upload.mjs +574 -222
  100. package/fesm2022/rt-tools-ui-kit-v2-image-upload.mjs.map +1 -1
  101. package/fesm2022/rt-tools-ui-kit-v2-info-item.mjs +150 -36
  102. package/fesm2022/rt-tools-ui-kit-v2-info-item.mjs.map +1 -1
  103. package/fesm2022/rt-tools-ui-kit-v2-inline-edit.mjs +606 -0
  104. package/fesm2022/rt-tools-ui-kit-v2-inline-edit.mjs.map +1 -0
  105. package/fesm2022/rt-tools-ui-kit-v2-input-number.mjs +461 -355
  106. package/fesm2022/rt-tools-ui-kit-v2-input-number.mjs.map +1 -1
  107. package/fesm2022/rt-tools-ui-kit-v2-input.mjs +338 -143
  108. package/fesm2022/rt-tools-ui-kit-v2-input.mjs.map +1 -1
  109. package/fesm2022/rt-tools-ui-kit-v2-live-badge.mjs +135 -48
  110. package/fesm2022/rt-tools-ui-kit-v2-live-badge.mjs.map +1 -1
  111. package/fesm2022/rt-tools-ui-kit-v2-logo.mjs +166 -92
  112. package/fesm2022/rt-tools-ui-kit-v2-logo.mjs.map +1 -1
  113. package/fesm2022/rt-tools-ui-kit-v2-markdown-text.mjs +118 -56
  114. package/fesm2022/rt-tools-ui-kit-v2-markdown-text.mjs.map +1 -1
  115. package/fesm2022/rt-tools-ui-kit-v2-menu.mjs +1054 -527
  116. package/fesm2022/rt-tools-ui-kit-v2-menu.mjs.map +1 -1
  117. package/fesm2022/rt-tools-ui-kit-v2-message.mjs +230 -104
  118. package/fesm2022/rt-tools-ui-kit-v2-message.mjs.map +1 -1
  119. package/fesm2022/rt-tools-ui-kit-v2-money-list.mjs +210 -70
  120. package/fesm2022/rt-tools-ui-kit-v2-money-list.mjs.map +1 -1
  121. package/fesm2022/rt-tools-ui-kit-v2-multiselect.mjs +532 -311
  122. package/fesm2022/rt-tools-ui-kit-v2-multiselect.mjs.map +1 -1
  123. package/fesm2022/rt-tools-ui-kit-v2-night-grid.mjs +125 -50
  124. package/fesm2022/rt-tools-ui-kit-v2-night-grid.mjs.map +1 -1
  125. package/fesm2022/rt-tools-ui-kit-v2-note.mjs +73 -43
  126. package/fesm2022/rt-tools-ui-kit-v2-note.mjs.map +1 -1
  127. package/fesm2022/rt-tools-ui-kit-v2-notifications-bell.mjs +161 -53
  128. package/fesm2022/rt-tools-ui-kit-v2-notifications-bell.mjs.map +1 -1
  129. package/fesm2022/rt-tools-ui-kit-v2-page-header.mjs +491 -310
  130. package/fesm2022/rt-tools-ui-kit-v2-page-header.mjs.map +1 -1
  131. package/fesm2022/rt-tools-ui-kit-v2-pagination.mjs +374 -174
  132. package/fesm2022/rt-tools-ui-kit-v2-pagination.mjs.map +1 -1
  133. package/fesm2022/rt-tools-ui-kit-v2-photo-viewer.mjs +202 -159
  134. package/fesm2022/rt-tools-ui-kit-v2-photo-viewer.mjs.map +1 -1
  135. package/fesm2022/rt-tools-ui-kit-v2-popover.mjs +438 -309
  136. package/fesm2022/rt-tools-ui-kit-v2-popover.mjs.map +1 -1
  137. package/fesm2022/rt-tools-ui-kit-v2-profile-menu.mjs +295 -0
  138. package/fesm2022/rt-tools-ui-kit-v2-profile-menu.mjs.map +1 -0
  139. package/fesm2022/rt-tools-ui-kit-v2-prompt-suggestion.mjs +135 -45
  140. package/fesm2022/rt-tools-ui-kit-v2-prompt-suggestion.mjs.map +1 -1
  141. package/fesm2022/rt-tools-ui-kit-v2-radio-button.mjs +293 -171
  142. package/fesm2022/rt-tools-ui-kit-v2-radio-button.mjs.map +1 -1
  143. package/fesm2022/rt-tools-ui-kit-v2-radius.mjs +62 -55
  144. package/fesm2022/rt-tools-ui-kit-v2-radius.mjs.map +1 -1
  145. package/fesm2022/rt-tools-ui-kit-v2-rich-editor.mjs +3379 -1466
  146. package/fesm2022/rt-tools-ui-kit-v2-rich-editor.mjs.map +1 -1
  147. package/fesm2022/rt-tools-ui-kit-v2-ripple.mjs +114 -116
  148. package/fesm2022/rt-tools-ui-kit-v2-ripple.mjs.map +1 -1
  149. package/fesm2022/rt-tools-ui-kit-v2-scroll-area.mjs +406 -299
  150. package/fesm2022/rt-tools-ui-kit-v2-scroll-area.mjs.map +1 -1
  151. package/fesm2022/rt-tools-ui-kit-v2-section-nav.mjs +137 -36
  152. package/fesm2022/rt-tools-ui-kit-v2-section-nav.mjs.map +1 -1
  153. package/fesm2022/rt-tools-ui-kit-v2-select.mjs +687 -468
  154. package/fesm2022/rt-tools-ui-kit-v2-select.mjs.map +1 -1
  155. package/fesm2022/rt-tools-ui-kit-v2-side-menu.mjs +2195 -1569
  156. package/fesm2022/rt-tools-ui-kit-v2-side-menu.mjs.map +1 -1
  157. package/fesm2022/rt-tools-ui-kit-v2-skeleton-wrapper.mjs +187 -48
  158. package/fesm2022/rt-tools-ui-kit-v2-skeleton-wrapper.mjs.map +1 -1
  159. package/fesm2022/rt-tools-ui-kit-v2-skeleton.mjs +242 -122
  160. package/fesm2022/rt-tools-ui-kit-v2-skeleton.mjs.map +1 -1
  161. package/fesm2022/rt-tools-ui-kit-v2-speed-menu.mjs +439 -0
  162. package/fesm2022/rt-tools-ui-kit-v2-speed-menu.mjs.map +1 -0
  163. package/fesm2022/rt-tools-ui-kit-v2-spinner.mjs +218 -69
  164. package/fesm2022/rt-tools-ui-kit-v2-spinner.mjs.map +1 -1
  165. package/fesm2022/rt-tools-ui-kit-v2-split-button.mjs +292 -91
  166. package/fesm2022/rt-tools-ui-kit-v2-split-button.mjs.map +1 -1
  167. package/fesm2022/rt-tools-ui-kit-v2-stat-tile.mjs +225 -138
  168. package/fesm2022/rt-tools-ui-kit-v2-stat-tile.mjs.map +1 -1
  169. package/fesm2022/rt-tools-ui-kit-v2-stepper.mjs +150 -116
  170. package/fesm2022/rt-tools-ui-kit-v2-stepper.mjs.map +1 -1
  171. package/fesm2022/rt-tools-ui-kit-v2-table.mjs +2462 -1583
  172. package/fesm2022/rt-tools-ui-kit-v2-table.mjs.map +1 -1
  173. package/fesm2022/rt-tools-ui-kit-v2-tabs.mjs +647 -346
  174. package/fesm2022/rt-tools-ui-kit-v2-tabs.mjs.map +1 -1
  175. package/fesm2022/rt-tools-ui-kit-v2-tag.mjs +335 -121
  176. package/fesm2022/rt-tools-ui-kit-v2-tag.mjs.map +1 -1
  177. package/fesm2022/rt-tools-ui-kit-v2-textarea.mjs +217 -84
  178. package/fesm2022/rt-tools-ui-kit-v2-textarea.mjs.map +1 -1
  179. package/fesm2022/rt-tools-ui-kit-v2-theme-toggle.mjs +151 -72
  180. package/fesm2022/rt-tools-ui-kit-v2-theme-toggle.mjs.map +1 -1
  181. package/fesm2022/rt-tools-ui-kit-v2-thread-list.mjs +697 -226
  182. package/fesm2022/rt-tools-ui-kit-v2-thread-list.mjs.map +1 -1
  183. package/fesm2022/rt-tools-ui-kit-v2-timeline.mjs +92 -38
  184. package/fesm2022/rt-tools-ui-kit-v2-timeline.mjs.map +1 -1
  185. package/fesm2022/rt-tools-ui-kit-v2-toast.mjs +752 -338
  186. package/fesm2022/rt-tools-ui-kit-v2-toast.mjs.map +1 -1
  187. package/fesm2022/rt-tools-ui-kit-v2-toggle-button-group.mjs +310 -129
  188. package/fesm2022/rt-tools-ui-kit-v2-toggle-button-group.mjs.map +1 -1
  189. package/fesm2022/rt-tools-ui-kit-v2-toggle-switch.mjs +286 -158
  190. package/fesm2022/rt-tools-ui-kit-v2-toggle-switch.mjs.map +1 -1
  191. package/fesm2022/rt-tools-ui-kit-v2-toolbar.mjs +270 -134
  192. package/fesm2022/rt-tools-ui-kit-v2-toolbar.mjs.map +1 -1
  193. package/fesm2022/rt-tools-ui-kit-v2-tooltip.mjs +322 -202
  194. package/fesm2022/rt-tools-ui-kit-v2-tooltip.mjs.map +1 -1
  195. package/fesm2022/rt-tools-ui-kit-v2-tree-selector.mjs +908 -0
  196. package/fesm2022/rt-tools-ui-kit-v2-tree-selector.mjs.map +1 -0
  197. package/fesm2022/rt-tools-ui-kit-v2-tree.mjs +785 -0
  198. package/fesm2022/rt-tools-ui-kit-v2-tree.mjs.map +1 -0
  199. package/fesm2022/rt-tools-ui-kit-v2-welcome-dialog.mjs +118 -63
  200. package/fesm2022/rt-tools-ui-kit-v2-welcome-dialog.mjs.map +1 -1
  201. package/fesm2022/rt-tools-ui-kit-v2-workspace-details.mjs +783 -262
  202. package/fesm2022/rt-tools-ui-kit-v2-workspace-details.mjs.map +1 -1
  203. package/fesm2022/rt-tools-ui-kit-v2-workspace.mjs +633 -294
  204. package/fesm2022/rt-tools-ui-kit-v2-workspace.mjs.map +1 -1
  205. package/fesm2022/rt-tools-ui-kit-v2.mjs +100 -103
  206. package/package.json +45 -1
  207. package/src/assets/icons/collapse-all.svg +9 -0
  208. package/src/assets/icons/expand-all.svg +9 -0
  209. package/src/assets/icons-material/collapse-all.fill.svg +5 -0
  210. package/src/assets/icons-material/collapse-all.svg +5 -0
  211. package/src/assets/icons-material/expand-all.fill.svg +5 -0
  212. package/src/assets/icons-material/expand-all.svg +5 -0
  213. package/src/assets/icons-material/undo.fill.svg +5 -0
  214. package/src/assets/icons-material/undo.svg +5 -0
  215. package/src/lib/components/bottom-sheet/CONTEXT.md +20 -2
  216. package/src/lib/components/bottom-sheet/rt-bottom-sheet.component.scss +36 -1
  217. package/src/lib/components/breadcrumbs/CONTEXT.md +37 -0
  218. package/src/lib/components/breadcrumbs/rt-breadcrumbs.component.scss +205 -0
  219. package/src/lib/components/carousel/CONTEXT.md +42 -0
  220. package/src/lib/components/carousel/rt-carousel.component.scss +117 -0
  221. package/src/lib/components/checkbox/CONTEXT.md +3 -0
  222. package/src/lib/components/checkbox/rt-checkbox.component.scss +9 -3
  223. package/src/lib/components/color-palette/CONTEXT.md +49 -0
  224. package/src/lib/components/color-palette/picker/rt-color-picker.component.scss +161 -0
  225. package/src/lib/components/color-palette/rt-color-palette.component.scss +132 -0
  226. package/src/lib/components/draggable-tree/CONTEXT.md +54 -0
  227. package/src/lib/components/draggable-tree/rt-draggable-tree.component.scss +219 -0
  228. package/src/lib/components/hybrid-tree/CONTEXT.md +31 -0
  229. package/src/lib/components/hybrid-tree-selector/CONTEXT.md +25 -0
  230. package/src/lib/components/icon-button/CONTEXT.md +3 -0
  231. package/src/lib/components/inline-edit/CONTEXT.md +41 -0
  232. package/src/lib/components/inline-edit/rt-inline-edit.component.scss +274 -0
  233. package/src/lib/components/popover/CONTEXT.md +3 -0
  234. package/src/lib/components/profile-menu/CONTEXT.md +32 -0
  235. package/src/lib/components/profile-menu/rt-profile-menu.component.scss +104 -0
  236. package/src/lib/components/speed-menu/CONTEXT.md +34 -0
  237. package/src/lib/components/speed-menu/rt-speed-menu.component.scss +118 -0
  238. package/src/lib/components/tag/rt-tag.component.scss +12 -0
  239. package/src/lib/components/thread-list/CONTEXT.md +1 -0
  240. package/src/lib/components/thread-list/rt-thread-list.component.scss +2 -1
  241. package/src/lib/components/toolbar/CONTEXT.md +9 -4
  242. package/src/lib/components/toolbar/rt-toolbar.component.scss +10 -2
  243. package/src/lib/components/tooltip/CONTEXT.md +8 -1
  244. package/src/lib/components/tree/CONTEXT.md +66 -0
  245. package/src/lib/components/tree/rt-tree.component.scss +313 -0
  246. package/src/lib/components/tree-selector/CONTEXT.md +47 -0
  247. package/src/lib/components/tree-selector/rt-tree-selector.component.scss +121 -0
  248. package/src/styles/_primitives.scss +4 -0
  249. package/src/styles/_semantic.scss +5 -0
  250. package/styles/tokens.css +43 -0
  251. package/types/rt-tools-ui-kit-v2-accordion.d.ts +31 -24
  252. package/types/rt-tools-ui-kit-v2-action-bar.d.ts +112 -91
  253. package/types/rt-tools-ui-kit-v2-ai-run-status.d.ts +64 -40
  254. package/types/rt-tools-ui-kit-v2-aside-section.d.ts +13 -10
  255. package/types/rt-tools-ui-kit-v2-aside.d.ts +268 -206
  256. package/types/rt-tools-ui-kit-v2-autocomplete.d.ts +102 -61
  257. package/types/rt-tools-ui-kit-v2-bar-list.d.ts +39 -27
  258. package/types/rt-tools-ui-kit-v2-bottom-sheet.d.ts +31 -20
  259. package/types/rt-tools-ui-kit-v2-breadcrumbs.d.ts +89 -0
  260. package/types/rt-tools-ui-kit-v2-button.d.ts +119 -59
  261. package/types/rt-tools-ui-kit-v2-calendar.d.ts +151 -86
  262. package/types/rt-tools-ui-kit-v2-card.d.ts +42 -21
  263. package/types/rt-tools-ui-kit-v2-carousel.d.ts +76 -0
  264. package/types/rt-tools-ui-kit-v2-checkbox.d.ts +48 -24
  265. package/types/rt-tools-ui-kit-v2-collapsible-text.d.ts +28 -20
  266. package/types/rt-tools-ui-kit-v2-color-palette.d.ts +208 -0
  267. package/types/rt-tools-ui-kit-v2-confirm-popover.d.ts +104 -47
  268. package/types/rt-tools-ui-kit-v2-container.d.ts +278 -221
  269. package/types/rt-tools-ui-kit-v2-copy-value.d.ts +39 -24
  270. package/types/rt-tools-ui-kit-v2-core.d.ts +862 -865
  271. package/types/rt-tools-ui-kit-v2-counter-row.d.ts +20 -12
  272. package/types/rt-tools-ui-kit-v2-counter.d.ts +70 -38
  273. package/types/rt-tools-ui-kit-v2-data-list.d.ts +429 -264
  274. package/types/rt-tools-ui-kit-v2-data-table.d.ts +500 -351
  275. package/types/rt-tools-ui-kit-v2-date-picker.d.ts +164 -138
  276. package/types/rt-tools-ui-kit-v2-date-range.d.ts +102 -84
  277. package/types/rt-tools-ui-kit-v2-delta-view.d.ts +16 -13
  278. package/types/rt-tools-ui-kit-v2-detail-list.d.ts +23 -16
  279. package/types/rt-tools-ui-kit-v2-dialog.d.ts +130 -101
  280. package/types/rt-tools-ui-kit-v2-dot-field.d.ts +10 -13
  281. package/types/rt-tools-ui-kit-v2-download-link.d.ts +22 -17
  282. package/types/rt-tools-ui-kit-v2-draggable-tree.d.ts +132 -0
  283. package/types/rt-tools-ui-kit-v2-dynamic-list.d.ts +185 -96
  284. package/types/rt-tools-ui-kit-v2-dynamic-selector.d.ts +904 -404
  285. package/types/rt-tools-ui-kit-v2-empty-state.d.ts +48 -19
  286. package/types/rt-tools-ui-kit-v2-expansion-panel.d.ts +67 -39
  287. package/types/rt-tools-ui-kit-v2-field.d.ts +90 -49
  288. package/types/rt-tools-ui-kit-v2-file-card.d.ts +115 -75
  289. package/types/rt-tools-ui-kit-v2-file-drop.d.ts +75 -48
  290. package/types/rt-tools-ui-kit-v2-file-input.d.ts +53 -36
  291. package/types/rt-tools-ui-kit-v2-file-list.d.ts +5 -8
  292. package/types/rt-tools-ui-kit-v2-filter-control.d.ts +83 -49
  293. package/types/rt-tools-ui-kit-v2-form-control.d.ts +102 -74
  294. package/types/rt-tools-ui-kit-v2-header.d.ts +40 -22
  295. package/types/rt-tools-ui-kit-v2-hybrid-tree-selector.d.ts +14 -0
  296. package/types/rt-tools-ui-kit-v2-hybrid-tree.d.ts +72 -0
  297. package/types/rt-tools-ui-kit-v2-icon-button.d.ts +190 -90
  298. package/types/rt-tools-ui-kit-v2-icon.d.ts +160 -129
  299. package/types/rt-tools-ui-kit-v2-image-cropper.d.ts +151 -111
  300. package/types/rt-tools-ui-kit-v2-image-upload.d.ts +159 -85
  301. package/types/rt-tools-ui-kit-v2-info-item.d.ts +26 -13
  302. package/types/rt-tools-ui-kit-v2-inline-edit.d.ts +194 -0
  303. package/types/rt-tools-ui-kit-v2-input-number.d.ts +102 -53
  304. package/types/rt-tools-ui-kit-v2-input.d.ts +82 -43
  305. package/types/rt-tools-ui-kit-v2-live-badge.d.ts +30 -17
  306. package/types/rt-tools-ui-kit-v2-logo.d.ts +49 -32
  307. package/types/rt-tools-ui-kit-v2-markdown-text.d.ts +26 -17
  308. package/types/rt-tools-ui-kit-v2-menu.d.ts +272 -155
  309. package/types/rt-tools-ui-kit-v2-message.d.ts +59 -33
  310. package/types/rt-tools-ui-kit-v2-money-list.d.ts +36 -18
  311. package/types/rt-tools-ui-kit-v2-multiselect.d.ts +114 -80
  312. package/types/rt-tools-ui-kit-v2-night-grid.d.ts +34 -25
  313. package/types/rt-tools-ui-kit-v2-note.d.ts +12 -9
  314. package/types/rt-tools-ui-kit-v2-notifications-bell.d.ts +37 -16
  315. package/types/rt-tools-ui-kit-v2-page-header.d.ts +218 -150
  316. package/types/rt-tools-ui-kit-v2-pagination.d.ts +99 -63
  317. package/types/rt-tools-ui-kit-v2-photo-viewer.d.ts +61 -66
  318. package/types/rt-tools-ui-kit-v2-popover.d.ts +116 -55
  319. package/types/rt-tools-ui-kit-v2-profile-menu.d.ts +103 -0
  320. package/types/rt-tools-ui-kit-v2-prompt-suggestion.d.ts +26 -16
  321. package/types/rt-tools-ui-kit-v2-radio-button.d.ts +85 -43
  322. package/types/rt-tools-ui-kit-v2-radius.d.ts +18 -15
  323. package/types/rt-tools-ui-kit-v2-rich-editor.d.ts +931 -590
  324. package/types/rt-tools-ui-kit-v2-ripple.d.ts +28 -25
  325. package/types/rt-tools-ui-kit-v2-scroll-area.d.ts +60 -58
  326. package/types/rt-tools-ui-kit-v2-section-nav.d.ts +32 -22
  327. package/types/rt-tools-ui-kit-v2-select.d.ts +182 -139
  328. package/types/rt-tools-ui-kit-v2-side-menu.d.ts +452 -349
  329. package/types/rt-tools-ui-kit-v2-skeleton-wrapper.d.ts +53 -20
  330. package/types/rt-tools-ui-kit-v2-skeleton.d.ts +55 -26
  331. package/types/rt-tools-ui-kit-v2-speed-menu.d.ts +131 -0
  332. package/types/rt-tools-ui-kit-v2-spinner.d.ts +56 -28
  333. package/types/rt-tools-ui-kit-v2-split-button.d.ts +96 -55
  334. package/types/rt-tools-ui-kit-v2-stat-tile.d.ts +88 -60
  335. package/types/rt-tools-ui-kit-v2-stepper.d.ts +50 -37
  336. package/types/rt-tools-ui-kit-v2-table.d.ts +631 -480
  337. package/types/rt-tools-ui-kit-v2-tabs.d.ts +198 -113
  338. package/types/rt-tools-ui-kit-v2-tag.d.ts +106 -53
  339. package/types/rt-tools-ui-kit-v2-textarea.d.ts +48 -25
  340. package/types/rt-tools-ui-kit-v2-theme-toggle.d.ts +28 -26
  341. package/types/rt-tools-ui-kit-v2-thread-list.d.ts +154 -94
  342. package/types/rt-tools-ui-kit-v2-timeline.d.ts +30 -28
  343. package/types/rt-tools-ui-kit-v2-toast.d.ts +174 -98
  344. package/types/rt-tools-ui-kit-v2-toggle-button-group.d.ts +132 -86
  345. package/types/rt-tools-ui-kit-v2-toggle-switch.d.ts +88 -50
  346. package/types/rt-tools-ui-kit-v2-toolbar.d.ts +30 -27
  347. package/types/rt-tools-ui-kit-v2-tooltip.d.ts +65 -41
  348. package/types/rt-tools-ui-kit-v2-tree-selector.d.ts +257 -0
  349. package/types/rt-tools-ui-kit-v2-tree.d.ts +282 -0
  350. package/types/rt-tools-ui-kit-v2-welcome-dialog.d.ts +21 -24
  351. package/types/rt-tools-ui-kit-v2-workspace-details.d.ts +195 -124
  352. package/types/rt-tools-ui-kit-v2-workspace.d.ts +122 -79
  353. package/types/rt-tools-ui-kit-v2.d.ts +100 -90
  354. package/fesm2022/rt-tools-ui-kit-v2.mjs.map +0 -1
@@ -1,343 +1,757 @@
1
- import * as i0 from '@angular/core';
2
- import { InjectionToken, inject, ElementRef, signal, computed, input, booleanAttribute, output, effect, HostBinding, ViewEncapsulation, ChangeDetectionStrategy, Component, linkedSignal, numberAttribute } from '@angular/core';
3
- import { BlockDirective, ElemDirective } from '@rt-tools/core';
4
- import { RT_KIT_LABELS, NotificationBus, rtKitLabel } from '@rt-tools/ui-kit-v2/core';
5
- import { RtButtonDirective } from '@rt-tools/ui-kit-v2/button';
6
- import { RtIconButtonComponent } from '@rt-tools/ui-kit-v2/icon-button';
7
- import { RtIconComponent } from '@rt-tools/ui-kit-v2/icon';
8
- import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
9
-
1
+ import * as i0 from "@angular/core";
2
+ import { ChangeDetectionStrategy, Component, ElementRef, HostBinding, InjectionToken, ViewEncapsulation, booleanAttribute, computed, effect, inject, input, linkedSignal, numberAttribute, output, signal } from "@angular/core";
3
+ import { BlockDirective, ElemDirective } from "@rt-tools/core";
4
+ import { NotificationBus, RT_KIT_LABELS, rtKitLabel } from "@rt-tools/ui-kit-v2/core";
5
+ import { RtButtonDirective } from "@rt-tools/ui-kit-v2/button";
6
+ import { RtIconButtonComponent } from "@rt-tools/ui-kit-v2/icon-button";
7
+ import { RtIconComponent } from "@rt-tools/ui-kit-v2/icon";
8
+ import { takeUntilDestroyed } from "@angular/core/rxjs-interop";
10
9
  const RT_TOASTER_GAP_PX = 14;
11
- /**
12
- * Значки severity у тоста. Приложение подменяет карту целиком — например, на имена
13
- * Material, — а тост со своим `icon` берёт свой значок мимо карты.
14
- */
15
- const RT_TOAST_SEVERITY_ICONS = new InjectionToken('RT_TOAST_SEVERITY_ICONS', {
16
- providedIn: 'root',
17
- factory: () => ({
18
- info: 'info-circle',
19
- success: 'check-circle',
20
- warning: 'exclamation-circle',
21
- danger: 'times-circle',
22
- }),
10
+ const RT_TOAST_SEVERITY_ICONS = new InjectionToken("RT_TOAST_SEVERITY_ICONS", {
11
+ providedIn: "root",
12
+ factory: () => ({
13
+ info: "info-circle",
14
+ success: "check-circle",
15
+ warning: "exclamation-circle",
16
+ danger: "times-circle"
17
+ })
23
18
  });
24
-
25
- const BEM_BLOCK$1 = 'rt-toast';
19
+ const BEM_BLOCK$1 = "rt-toast";
26
20
  const UNMOUNT_DELAY_MS = 200;
27
- class RtToastComponent {
28
- #host;
29
- #severityIcons;
30
- #mounted;
31
- #removed;
32
- #offsetBeforeRemove;
33
- #initialHeight;
34
- #heightIndex;
35
- #heightBefore;
36
- #offset;
37
- #positionY;
38
- #timeoutId;
39
- #unmountTimeoutId;
40
- #remainingTimeMs;
41
- #closeTimerStartedAt;
42
- #closeTimerPausedAt;
43
- get hostModifierClasses() {
44
- return {
45
- [`${BEM_BLOCK$1}--severity--${this.toast().severity}`]: true,
46
- [`${BEM_BLOCK$1}--filled`]: this.toast().filled === true,
47
- [`${BEM_BLOCK$1}--y--${this.#positionY()}`]: true,
48
- [`${BEM_BLOCK$1}--mounted`]: this.#mounted(),
49
- [`${BEM_BLOCK$1}--removed`]: this.#removed(),
50
- [`${BEM_BLOCK$1}--front`]: this.index() === 0,
51
- [`${BEM_BLOCK$1}--hidden`]: this.index() + 1 > this.visibleToasts(),
52
- [`${BEM_BLOCK$1}--expanded`]: this.expanded() || (this.expandByDefault() && this.#mounted()),
53
- [`${BEM_BLOCK$1}--paused`]: this.paused(),
54
- };
55
- }
56
- get hostStackStyles() {
57
- return {
58
- '--index': `${this.index()}`,
59
- '--toasts-before': `${this.index()}`,
60
- '--z-index': `${this.totalToasts() - this.index()}`,
61
- '--offset': `${this.#removed() ? this.#offsetBeforeRemove() : this.#offset()}px`,
62
- '--initial-height': this.expandByDefault() ? 'auto' : `${this.#initialHeight()}px`,
63
- '--lifetime': `${this.lifetime() ?? 0}ms`,
64
- };
65
- }
66
- constructor() {
67
- this.#host = inject(ElementRef);
68
- this.#severityIcons = inject(RT_TOAST_SEVERITY_ICONS);
69
- this.#mounted = signal(false, /* @ts-ignore */
70
- ...(ngDevMode ? [{ debugName: "#mounted" }] : /* istanbul ignore next */ []));
71
- this.#removed = signal(false, /* @ts-ignore */
72
- ...(ngDevMode ? [{ debugName: "#removed" }] : /* istanbul ignore next */ []));
73
- this.#offsetBeforeRemove = signal(0, /* @ts-ignore */
74
- ...(ngDevMode ? [{ debugName: "#offsetBeforeRemove" }] : /* istanbul ignore next */ []));
75
- this.#initialHeight = signal(0, /* @ts-ignore */
76
- ...(ngDevMode ? [{ debugName: "#initialHeight" }] : /* istanbul ignore next */ []));
77
- this.#heightIndex = computed(() => this.heights().findIndex((item) => item.toastId === this.toast().id), /* @ts-ignore */
78
- ...(ngDevMode ? [{ debugName: "#heightIndex" }] : /* istanbul ignore next */ []));
79
- this.#heightBefore = computed(() => this.heights().reduce((total, item, itemIndex) => itemIndex >= this.#heightIndex() ? total : total + item.height, 0), /* @ts-ignore */
80
- ...(ngDevMode ? [{ debugName: "#heightBefore" }] : /* istanbul ignore next */ []));
81
- this.#offset = computed(() => Math.round(this.#heightIndex() * RT_TOASTER_GAP_PX + this.#heightBefore()), /* @ts-ignore */
82
- ...(ngDevMode ? [{ debugName: "#offset" }] : /* istanbul ignore next */ []));
83
- this.#positionY = computed(() => this.position().startsWith('top') ? 'top' : 'bottom', /* @ts-ignore */
84
- ...(ngDevMode ? [{ debugName: "#positionY" }] : /* istanbul ignore next */ []));
85
- this.#remainingTimeMs = 0;
86
- this.#closeTimerStartedAt = 0;
87
- this.#closeTimerPausedAt = 0;
88
- this.t = inject(RT_KIT_LABELS);
89
- /** Свой значок тоста важнее карты severity; `null` у тоста значок снимает. */
90
- this.icon = computed(() => {
91
- const icon = this.toast().icon;
92
- return icon === undefined ? this.#severityIcons[this.toast().severity] : icon;
93
- }, /* @ts-ignore */
94
- ...(ngDevMode ? [{ debugName: "icon" }] : /* istanbul ignore next */ []));
95
- /** Срок жизни тоста: свой, если задан, иначе тостера; `null` — таймера нет. */
96
- this.lifetime = computed(() => {
97
- const duration = this.toast().duration;
98
- return duration === undefined ? this.duration() : duration;
99
- }, /* @ts-ignore */
100
- ...(ngDevMode ? [{ debugName: "lifetime" }] : /* istanbul ignore next */ []));
101
- this.showProgress = computed(() => this.toast().progress === true && this.lifetime() !== null, /* @ts-ignore */
102
- ...(ngDevMode ? [{ debugName: "showProgress" }] : /* istanbul ignore next */ []));
103
- /** Таймер и полоса срока встают от одного признака, чтобы не разойтись. */
104
- this.paused = computed(() => this.expanded() || this.interacting(), /* @ts-ignore */
105
- ...(ngDevMode ? [{ debugName: "paused" }] : /* istanbul ignore next */ []));
106
- this.toast = input.required(/* @ts-ignore */
107
- ...(ngDevMode ? [{ debugName: "toast" }] : /* istanbul ignore next */ []));
108
- this.index = input.required(/* @ts-ignore */
109
- ...(ngDevMode ? [{ debugName: "index" }] : /* istanbul ignore next */ []));
110
- this.totalToasts = input.required(/* @ts-ignore */
111
- ...(ngDevMode ? [{ debugName: "totalToasts" }] : /* istanbul ignore next */ []));
112
- this.heights = input.required(/* @ts-ignore */
113
- ...(ngDevMode ? [{ debugName: "heights" }] : /* istanbul ignore next */ []));
114
- this.expanded = input.required({ ...(ngDevMode ? { debugName: "expanded" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
115
- this.expandByDefault = input(false, { ...(ngDevMode ? { debugName: "expandByDefault" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
116
- this.interacting = input(false, { ...(ngDevMode ? { debugName: "interacting" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
117
- this.position = input('bottom-right', /* @ts-ignore */
118
- ...(ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []));
119
- this.visibleToasts = input(3, /* @ts-ignore */
120
- ...(ngDevMode ? [{ debugName: "visibleToasts" }] : /* istanbul ignore next */ []));
121
- this.duration = input(4000, /* @ts-ignore */
122
- ...(ngDevMode ? [{ debugName: "duration" }] : /* istanbul ignore next */ []));
123
- this.heightAdded = output();
124
- this.heightRemoved = output();
125
- this.dismissed = output();
126
- effect((onCleanup) => {
127
- if (!this.#mounted() || this.#removed() || this.lifetime() === null) {
128
- return;
129
- }
130
- if (this.paused()) {
131
- this.#pauseTimer();
132
- }
133
- else {
134
- this.#startTimer();
135
- }
136
- onCleanup(() => clearTimeout(this.#timeoutId));
137
- });
138
- // Вытесненный в режиме `replace` уходит тем же путём, что и закрытый крестиком.
139
- effect(() => {
140
- if (this.#mounted() && this.toast().replaced === true) {
141
- this.#deleteToast('replaced');
142
- }
143
- });
144
- }
145
- ngAfterViewInit() {
146
- this.#remainingTimeMs = this.lifetime() ?? 0;
147
- const height = this.#host.nativeElement.getBoundingClientRect().height;
148
- this.#initialHeight.set(height);
149
- this.heightAdded.emit({ toastId: this.toast().id, height });
150
- this.#mounted.set(true);
151
- }
152
- ngOnDestroy() {
153
- clearTimeout(this.#timeoutId);
154
- clearTimeout(this.#unmountTimeoutId);
155
- }
156
- onAction() {
157
- this.toast().action?.handler();
158
- this.#deleteToast(null);
159
- }
160
- onSecondaryAction() {
161
- this.toast().secondaryAction?.handler();
162
- this.#deleteToast(null);
163
- }
164
- onClose() {
165
- this.#deleteToast('close');
166
- }
167
- /** Уход тоста. Причина — для колбэка приложения; ушедший по действию её не сообщает: `null`. */
168
- #deleteToast(reason) {
169
- if (this.#removed()) {
170
- return;
171
- }
172
- this.#removed.set(true);
173
- if (reason !== null) {
174
- this.toast().onDismiss?.(reason);
175
- }
176
- this.#offsetBeforeRemove.set(this.#offset());
177
- this.heightRemoved.emit(this.toast().id);
178
- this.#unmountTimeoutId = setTimeout(() => this.dismissed.emit(this.toast().id), UNMOUNT_DELAY_MS);
179
- }
180
- #startTimer() {
181
- this.#closeTimerStartedAt = Date.now();
182
- this.#timeoutId = setTimeout(() => this.#deleteToast('timeout'), this.#remainingTimeMs);
183
- }
184
- #pauseTimer() {
185
- if (this.#closeTimerPausedAt < this.#closeTimerStartedAt) {
186
- const elapsedMs = Date.now() - this.#closeTimerStartedAt;
187
- this.#remainingTimeMs = this.#remainingTimeMs - elapsedMs;
188
- }
189
- this.#closeTimerPausedAt = Date.now();
190
- }
191
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: RtToastComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
192
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.6", type: RtToastComponent, isStandalone: true, selector: "rt-toast", inputs: { toast: { classPropertyName: "toast", publicName: "toast", isSignal: true, isRequired: true, transformFunction: null }, index: { classPropertyName: "index", publicName: "index", isSignal: true, isRequired: true, transformFunction: null }, totalToasts: { classPropertyName: "totalToasts", publicName: "totalToasts", isSignal: true, isRequired: true, transformFunction: null }, heights: { classPropertyName: "heights", publicName: "heights", isSignal: true, isRequired: true, transformFunction: null }, expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: true, transformFunction: null }, expandByDefault: { classPropertyName: "expandByDefault", publicName: "expandByDefault", isSignal: true, isRequired: false, transformFunction: null }, interacting: { classPropertyName: "interacting", publicName: "interacting", isSignal: true, isRequired: false, transformFunction: null }, position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null }, visibleToasts: { classPropertyName: "visibleToasts", publicName: "visibleToasts", isSignal: true, isRequired: false, transformFunction: null }, duration: { classPropertyName: "duration", publicName: "duration", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { heightAdded: "heightAdded", heightRemoved: "heightRemoved", dismissed: "dismissed" }, host: { attributes: { "role": "status", "aria-atomic": "true" }, properties: { "class": "this.hostModifierClasses", "style": "this.hostStackStyles" }, classAttribute: "rt-toast" }, ngImport: i0, template: "<ng-container rtBlock=\"rt-toast\">\n @if (icon(); as icon) {\n <rt-icon rtElem=\"icon\" qa-dataid=\"toast-icon\" size=\"sm\" [name]=\"icon\" />\n }\n <div rtElem=\"content\" qa-dataid=\"toast-content\">\n @if (toast().meta; as meta) {\n <span rtElem=\"meta\" qa-dataid=\"toast-meta\">{{ meta }}</span>\n }\n <span rtElem=\"message\" qa-dataid=\"toast-message\">{{ toast().message }}</span>\n @if (toast().description; as description) {\n <span rtElem=\"description\" qa-dataid=\"toast-description\">{{ description }}</span>\n }\n @if (toast().action || toast().secondaryAction) {\n <div rtElem=\"actions\">\n @if (toast().action; as action) {\n <button rtButton rtElem=\"action\" qa-dataid=\"toast-action\" size=\"sm\" type=\"button\" (click)=\"onAction()\">\n {{ action.label }}\n </button>\n }\n @if (toast().secondaryAction; as secondaryAction) {\n <button\n rtButton\n rtElem=\"action\"\n qa-dataid=\"toast-secondary-action\"\n size=\"sm\"\n theme=\"secondary\"\n appearance=\"text\"\n type=\"button\"\n (click)=\"onSecondaryAction()\">\n {{ secondaryAction.label }}\n </button>\n }\n </div>\n }\n </div>\n <rt-icon-button\n rtElem=\"close\"\n qa-dataid=\"toast-close\"\n icon=\"ico-close\"\n variant=\"ghost\"\n size=\"sm\"\n [ariaLabel]=\"t().uiClose\"\n (clicked)=\"onClose()\" />\n @if (showProgress()) {\n <span rtElem=\"progress\" qa-dataid=\"toast-progress\" aria-hidden=\"true\"></span>\n }\n</ng-container>\n", styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toast{--rt-toast-radius: var(--rt-radius-md);--rt-toast-border-width: var(--rt-border-width-thin);--rt-toast-shadow: var(--rt-shadow-card);--rt-toast-enter-duration: var(--rt-duration-slow);--rt-toast-shadow-duration: var(--rt-duration-base);--rt-toast-leave-duration: var(--rt-duration-slower);--rt-toast-fade-duration: var(--rt-duration-fast);--rt-toast-severity-color: var(--rt-color-state-info);--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));position:absolute;z-index:var(--z-index);display:flex;width:100%;box-sizing:border-box;align-items:center;padding:var(--rt-space-4);border:var(--rt-toast-border-width) solid var(--rt-toast-border-color, var(--rt-color-border-subtle));border-radius:var(--rt-toast-radius);background:var(--rt-toast-bg, var(--rt-color-bg-surface));box-shadow:var(--rt-toast-shadow);color:var(--rt-toast-color, var(--rt-color-text-primary));font-size:var(--rt-text-sm);font-weight:var(--rt-font-weight-medium);gap:var(--rt-space-2);line-height:var(--rt-leading-normal);opacity:0;outline:none;overflow-wrap:anywhere;touch-action:none;transform:var(--y);transition:transform var(--rt-toast-enter-duration),opacity var(--rt-toast-enter-duration),height var(--rt-toast-enter-duration),box-shadow var(--rt-toast-shadow-duration)}.rt-toast:after{position:absolute;bottom:100%;left:0;width:100%;height:calc(var(--gap) + 1px);content:\"\"}.rt-toast>*{transition:opacity var(--rt-toast-enter-duration)}.rt-toast--y--top{--y: translateY(-100%);--lift: 1;top:0}.rt-toast--y--bottom{--y: translateY(100%);--lift: -1;bottom:0}.rt-toast--severity--success{--rt-toast-severity-color: var(--rt-color-state-success)}.rt-toast--severity--warning{--rt-toast-severity-color: var(--rt-color-state-warning)}.rt-toast--severity--danger{--rt-toast-severity-color: var(--rt-color-state-danger)}.rt-toast--filled .rt-toast__description{color:inherit}.rt-toast--filled .rt-toast__icon{color:currentcolor}.rt-toast--filled.rt-toast--severity--info{border-color:var(--rt-toast-filled-info-border-color, var(--rt-color-state-info-bg));background:var(--rt-toast-filled-info-bg, var(--rt-color-state-info-bg));color:var(--rt-toast-filled-info-color, var(--rt-color-state-info))}.rt-toast--filled.rt-toast--severity--success{border-color:var(--rt-toast-filled-success-border-color, var(--rt-color-state-success-bg));background:var(--rt-toast-filled-success-bg, var(--rt-color-state-success-bg));color:var(--rt-toast-filled-success-color, var(--rt-color-state-success))}.rt-toast--filled.rt-toast--severity--warning{border-color:var(--rt-toast-filled-warning-border-color, var(--rt-color-state-warning-bg));background:var(--rt-toast-filled-warning-bg, var(--rt-color-state-warning-bg));color:var(--rt-toast-filled-warning-color, var(--rt-color-state-warning))}.rt-toast--filled.rt-toast--severity--danger{border-color:var(--rt-toast-filled-danger-border-color, var(--rt-color-state-danger-bg));background:var(--rt-toast-filled-danger-bg, var(--rt-color-state-danger-bg));color:var(--rt-toast-filled-danger-color, var(--rt-color-state-danger))}.rt-toast--mounted{--y: translateY(0);opacity:1}.rt-toast:not(.rt-toast--expanded,.rt-toast--front){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}.rt-toast:not(.rt-toast--expanded,.rt-toast--front)>*{opacity:0}.rt-toast--hidden{opacity:0;pointer-events:none}.rt-toast--mounted.rt-toast--expanded{--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}.rt-toast--removed.rt-toast--front{--y: translateY(calc(var(--lift) * -100%));opacity:0}.rt-toast--removed.rt-toast--expanded:not(.rt-toast--front){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}.rt-toast--removed:not(.rt-toast--front,.rt-toast--expanded){--y: translateY(40%);opacity:0;transition:transform var(--rt-toast-leave-duration),opacity var(--rt-toast-shadow-duration)}.rt-toast--removed:not(.rt-toast--front):before{position:absolute;content:\"\";inset:0;transform:scaleY(2)}.rt-toast__icon{flex-shrink:0;color:var(--rt-toast-icon-color, var(--rt-toast-severity-color))}.rt-toast__progress{position:absolute;bottom:0;animation:rt-toast-progress var(--lifetime) linear forwards;background:var(--rt-toast-progress-color, var(--rt-toast-severity-color));block-size:var(--rt-toast-progress-height, var(--rt-space-0-5));border-end-end-radius:var(--rt-toast-radius);border-end-start-radius:var(--rt-toast-radius);inset-inline:0;transform-origin:left center}.rt-toast--paused .rt-toast__progress{animation-play-state:paused}.rt-toast__content{display:flex;min-width:0;flex:1 1 auto;flex-direction:column;gap:var(--rt-space-0-5)}.rt-toast__description,.rt-toast__meta{color:var(--rt-color-text-muted);font-size:var(--rt-text-xs);font-weight:var(--rt-font-weight-regular)}.rt-toast__actions{display:flex;flex-wrap:wrap;align-items:center;gap:var(--rt-space-2);margin-block-start:var(--rt-space-1)}.rt-toast .rt-toast__action{align-self:flex-start}.rt-toast .rt-toast__action:not(.rt-button--text){--rt-btn-bg: var(--rt-toast-action-color, var(--rt-color-action-primary));--rt-btn-bg-hover: var(--rt-toast-action-color, var(--rt-color-action-primary-hover));--rt-btn-bg-active: var(--rt-toast-action-color, var(--rt-color-action-primary-active))}.rt-toast .rt-toast__close{--rt-icon-button-color: var(--rt-toast-close-color, var(--rt-color-text-primary));flex-shrink:0;align-self:flex-start;margin-inline-start:auto;opacity:0;transition:opacity var(--rt-toast-fade-duration)}.rt-toast:hover .rt-toast__close,.rt-toast .rt-toast__close:focus-visible{opacity:1}@media(prefers-reduced-motion){.rt-toast{transition:none}.rt-toast>*{transition:none}}@keyframes rt-toast-progress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}}\n"], dependencies: [{ kind: "directive", type: RtButtonDirective, selector: "button[rtButton], a[rtButton]", inputs: ["label", "icon", "iconPos", "theme", "appearance", "size", "loading", "loadingIcon", "loadingLabel", "pressed"] }, { kind: "component", type: RtIconComponent, selector: "rt-icon", inputs: ["name", "glyph", "glyphStrategy", "size", "color", "fill", "spin", "rotate"] }, { kind: "component", type: RtIconButtonComponent, selector: "rt-icon-button", inputs: ["icon", "glyph", "ariaLabel", "variant", "iconColor", "iconFill", "size", "iconSize", "type", "tooltip", "tabIndex", "loading", "disabled", "active", "indicator"], outputs: ["clicked"] }, { kind: "directive", type: BlockDirective, selector: "[rtBlock]", inputs: ["rtMod"] }, { kind: "directive", type: ElemDirective, selector: "[rtElem]", inputs: ["rtMod"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
193
- }
194
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: RtToastComponent, decorators: [{
195
- type: Component,
196
- args: [{ selector: 'rt-toast', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [RtButtonDirective, RtIconComponent, RtIconButtonComponent, BlockDirective, ElemDirective], host: {
197
- class: BEM_BLOCK$1,
198
- role: 'status',
199
- 'aria-atomic': 'true',
200
- }, template: "<ng-container rtBlock=\"rt-toast\">\n @if (icon(); as icon) {\n <rt-icon rtElem=\"icon\" qa-dataid=\"toast-icon\" size=\"sm\" [name]=\"icon\" />\n }\n <div rtElem=\"content\" qa-dataid=\"toast-content\">\n @if (toast().meta; as meta) {\n <span rtElem=\"meta\" qa-dataid=\"toast-meta\">{{ meta }}</span>\n }\n <span rtElem=\"message\" qa-dataid=\"toast-message\">{{ toast().message }}</span>\n @if (toast().description; as description) {\n <span rtElem=\"description\" qa-dataid=\"toast-description\">{{ description }}</span>\n }\n @if (toast().action || toast().secondaryAction) {\n <div rtElem=\"actions\">\n @if (toast().action; as action) {\n <button rtButton rtElem=\"action\" qa-dataid=\"toast-action\" size=\"sm\" type=\"button\" (click)=\"onAction()\">\n {{ action.label }}\n </button>\n }\n @if (toast().secondaryAction; as secondaryAction) {\n <button\n rtButton\n rtElem=\"action\"\n qa-dataid=\"toast-secondary-action\"\n size=\"sm\"\n theme=\"secondary\"\n appearance=\"text\"\n type=\"button\"\n (click)=\"onSecondaryAction()\">\n {{ secondaryAction.label }}\n </button>\n }\n </div>\n }\n </div>\n <rt-icon-button\n rtElem=\"close\"\n qa-dataid=\"toast-close\"\n icon=\"ico-close\"\n variant=\"ghost\"\n size=\"sm\"\n [ariaLabel]=\"t().uiClose\"\n (clicked)=\"onClose()\" />\n @if (showProgress()) {\n <span rtElem=\"progress\" qa-dataid=\"toast-progress\" aria-hidden=\"true\"></span>\n }\n</ng-container>\n", styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toast{--rt-toast-radius: var(--rt-radius-md);--rt-toast-border-width: var(--rt-border-width-thin);--rt-toast-shadow: var(--rt-shadow-card);--rt-toast-enter-duration: var(--rt-duration-slow);--rt-toast-shadow-duration: var(--rt-duration-base);--rt-toast-leave-duration: var(--rt-duration-slower);--rt-toast-fade-duration: var(--rt-duration-fast);--rt-toast-severity-color: var(--rt-color-state-info);--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));position:absolute;z-index:var(--z-index);display:flex;width:100%;box-sizing:border-box;align-items:center;padding:var(--rt-space-4);border:var(--rt-toast-border-width) solid var(--rt-toast-border-color, var(--rt-color-border-subtle));border-radius:var(--rt-toast-radius);background:var(--rt-toast-bg, var(--rt-color-bg-surface));box-shadow:var(--rt-toast-shadow);color:var(--rt-toast-color, var(--rt-color-text-primary));font-size:var(--rt-text-sm);font-weight:var(--rt-font-weight-medium);gap:var(--rt-space-2);line-height:var(--rt-leading-normal);opacity:0;outline:none;overflow-wrap:anywhere;touch-action:none;transform:var(--y);transition:transform var(--rt-toast-enter-duration),opacity var(--rt-toast-enter-duration),height var(--rt-toast-enter-duration),box-shadow var(--rt-toast-shadow-duration)}.rt-toast:after{position:absolute;bottom:100%;left:0;width:100%;height:calc(var(--gap) + 1px);content:\"\"}.rt-toast>*{transition:opacity var(--rt-toast-enter-duration)}.rt-toast--y--top{--y: translateY(-100%);--lift: 1;top:0}.rt-toast--y--bottom{--y: translateY(100%);--lift: -1;bottom:0}.rt-toast--severity--success{--rt-toast-severity-color: var(--rt-color-state-success)}.rt-toast--severity--warning{--rt-toast-severity-color: var(--rt-color-state-warning)}.rt-toast--severity--danger{--rt-toast-severity-color: var(--rt-color-state-danger)}.rt-toast--filled .rt-toast__description{color:inherit}.rt-toast--filled .rt-toast__icon{color:currentcolor}.rt-toast--filled.rt-toast--severity--info{border-color:var(--rt-toast-filled-info-border-color, var(--rt-color-state-info-bg));background:var(--rt-toast-filled-info-bg, var(--rt-color-state-info-bg));color:var(--rt-toast-filled-info-color, var(--rt-color-state-info))}.rt-toast--filled.rt-toast--severity--success{border-color:var(--rt-toast-filled-success-border-color, var(--rt-color-state-success-bg));background:var(--rt-toast-filled-success-bg, var(--rt-color-state-success-bg));color:var(--rt-toast-filled-success-color, var(--rt-color-state-success))}.rt-toast--filled.rt-toast--severity--warning{border-color:var(--rt-toast-filled-warning-border-color, var(--rt-color-state-warning-bg));background:var(--rt-toast-filled-warning-bg, var(--rt-color-state-warning-bg));color:var(--rt-toast-filled-warning-color, var(--rt-color-state-warning))}.rt-toast--filled.rt-toast--severity--danger{border-color:var(--rt-toast-filled-danger-border-color, var(--rt-color-state-danger-bg));background:var(--rt-toast-filled-danger-bg, var(--rt-color-state-danger-bg));color:var(--rt-toast-filled-danger-color, var(--rt-color-state-danger))}.rt-toast--mounted{--y: translateY(0);opacity:1}.rt-toast:not(.rt-toast--expanded,.rt-toast--front){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}.rt-toast:not(.rt-toast--expanded,.rt-toast--front)>*{opacity:0}.rt-toast--hidden{opacity:0;pointer-events:none}.rt-toast--mounted.rt-toast--expanded{--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}.rt-toast--removed.rt-toast--front{--y: translateY(calc(var(--lift) * -100%));opacity:0}.rt-toast--removed.rt-toast--expanded:not(.rt-toast--front){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}.rt-toast--removed:not(.rt-toast--front,.rt-toast--expanded){--y: translateY(40%);opacity:0;transition:transform var(--rt-toast-leave-duration),opacity var(--rt-toast-shadow-duration)}.rt-toast--removed:not(.rt-toast--front):before{position:absolute;content:\"\";inset:0;transform:scaleY(2)}.rt-toast__icon{flex-shrink:0;color:var(--rt-toast-icon-color, var(--rt-toast-severity-color))}.rt-toast__progress{position:absolute;bottom:0;animation:rt-toast-progress var(--lifetime) linear forwards;background:var(--rt-toast-progress-color, var(--rt-toast-severity-color));block-size:var(--rt-toast-progress-height, var(--rt-space-0-5));border-end-end-radius:var(--rt-toast-radius);border-end-start-radius:var(--rt-toast-radius);inset-inline:0;transform-origin:left center}.rt-toast--paused .rt-toast__progress{animation-play-state:paused}.rt-toast__content{display:flex;min-width:0;flex:1 1 auto;flex-direction:column;gap:var(--rt-space-0-5)}.rt-toast__description,.rt-toast__meta{color:var(--rt-color-text-muted);font-size:var(--rt-text-xs);font-weight:var(--rt-font-weight-regular)}.rt-toast__actions{display:flex;flex-wrap:wrap;align-items:center;gap:var(--rt-space-2);margin-block-start:var(--rt-space-1)}.rt-toast .rt-toast__action{align-self:flex-start}.rt-toast .rt-toast__action:not(.rt-button--text){--rt-btn-bg: var(--rt-toast-action-color, var(--rt-color-action-primary));--rt-btn-bg-hover: var(--rt-toast-action-color, var(--rt-color-action-primary-hover));--rt-btn-bg-active: var(--rt-toast-action-color, var(--rt-color-action-primary-active))}.rt-toast .rt-toast__close{--rt-icon-button-color: var(--rt-toast-close-color, var(--rt-color-text-primary));flex-shrink:0;align-self:flex-start;margin-inline-start:auto;opacity:0;transition:opacity var(--rt-toast-fade-duration)}.rt-toast:hover .rt-toast__close,.rt-toast .rt-toast__close:focus-visible{opacity:1}@media(prefers-reduced-motion){.rt-toast{transition:none}.rt-toast>*{transition:none}}@keyframes rt-toast-progress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}}\n"] }]
201
- }], ctorParameters: () => [], propDecorators: { toast: [{ type: i0.Input, args: [{ isSignal: true, alias: "toast", required: true }] }], index: [{ type: i0.Input, args: [{ isSignal: true, alias: "index", required: true }] }], totalToasts: [{ type: i0.Input, args: [{ isSignal: true, alias: "totalToasts", required: true }] }], heights: [{ type: i0.Input, args: [{ isSignal: true, alias: "heights", required: true }] }], expanded: [{ type: i0.Input, args: [{ isSignal: true, alias: "expanded", required: true }] }], expandByDefault: [{ type: i0.Input, args: [{ isSignal: true, alias: "expandByDefault", required: false }] }], interacting: [{ type: i0.Input, args: [{ isSignal: true, alias: "interacting", required: false }] }], position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], visibleToasts: [{ type: i0.Input, args: [{ isSignal: true, alias: "visibleToasts", required: false }] }], duration: [{ type: i0.Input, args: [{ isSignal: true, alias: "duration", required: false }] }], heightAdded: [{ type: i0.Output, args: ["heightAdded"] }], heightRemoved: [{ type: i0.Output, args: ["heightRemoved"] }], dismissed: [{ type: i0.Output, args: ["dismissed"] }], hostModifierClasses: [{
202
- type: HostBinding,
203
- args: ['class']
204
- }], hostStackStyles: [{
205
- type: HostBinding,
206
- args: ['style']
207
- }] } });
208
-
209
- const BEM_BLOCK = 'rt-toaster';
210
- const DEFAULT_DURATION_MS = 4000;
21
+ var RtToastComponent = class RtToastComponent {
22
+ #host;
23
+ #severityIcons;
24
+ #mounted;
25
+ #removed;
26
+ #offsetBeforeRemove;
27
+ #initialHeight;
28
+ #heightIndex;
29
+ #heightBefore;
30
+ #offset;
31
+ #positionY;
32
+ #timeoutId;
33
+ #unmountTimeoutId;
34
+ #remainingTimeMs;
35
+ #closeTimerStartedAt;
36
+ #closeTimerPausedAt;
37
+ get hostModifierClasses() {
38
+ return {
39
+ [`${BEM_BLOCK$1}--severity--${this.toast().severity}`]: true,
40
+ [`${BEM_BLOCK$1}--filled`]: this.toast().filled === true,
41
+ [`${BEM_BLOCK$1}--y--${this.#positionY()}`]: true,
42
+ [`${BEM_BLOCK$1}--mounted`]: this.#mounted(),
43
+ [`${BEM_BLOCK$1}--removed`]: this.#removed(),
44
+ [`${BEM_BLOCK$1}--front`]: this.index() === 0,
45
+ [`${BEM_BLOCK$1}--hidden`]: this.index() + 1 > this.visibleToasts(),
46
+ [`${BEM_BLOCK$1}--expanded`]: this.expanded() || this.expandByDefault() && this.#mounted(),
47
+ [`${BEM_BLOCK$1}--paused`]: this.paused()
48
+ };
49
+ }
50
+ get hostStackStyles() {
51
+ return {
52
+ "--index": `${this.index()}`,
53
+ "--toasts-before": `${this.index()}`,
54
+ "--z-index": `${this.totalToasts() - this.index()}`,
55
+ "--offset": `${this.#removed() ? this.#offsetBeforeRemove() : this.#offset()}px`,
56
+ "--initial-height": this.expandByDefault() ? "auto" : `${this.#initialHeight()}px`,
57
+ "--lifetime": `${this.lifetime() ?? 0}ms`
58
+ };
59
+ }
60
+ constructor() {
61
+ this.#host = inject(ElementRef);
62
+ this.#severityIcons = inject(RT_TOAST_SEVERITY_ICONS);
63
+ this.#mounted = signal(false, ...ngDevMode ? [{ debugName: "#mounted" }] : /* istanbul ignore next */ []);
64
+ this.#removed = signal(false, ...ngDevMode ? [{ debugName: "#removed" }] : /* istanbul ignore next */ []);
65
+ this.#offsetBeforeRemove = signal(0, ...ngDevMode ? [{ debugName: "#offsetBeforeRemove" }] : /* istanbul ignore next */ []);
66
+ this.#initialHeight = signal(0, ...ngDevMode ? [{ debugName: "#initialHeight" }] : /* istanbul ignore next */ []);
67
+ this.#heightIndex = computed(() => this.heights().findIndex((item) => item.toastId === this.toast().id), ...ngDevMode ? [{ debugName: "#heightIndex" }] : /* istanbul ignore next */ []);
68
+ this.#heightBefore = computed(() => this.heights().reduce((total, item, itemIndex) => itemIndex >= this.#heightIndex() ? total : total + item.height, 0), ...ngDevMode ? [{ debugName: "#heightBefore" }] : /* istanbul ignore next */ []);
69
+ this.#offset = computed(() => Math.round(this.#heightIndex() * 14 + this.#heightBefore()), ...ngDevMode ? [{ debugName: "#offset" }] : /* istanbul ignore next */ []);
70
+ this.#positionY = computed(() => this.position().startsWith("top") ? "top" : "bottom", ...ngDevMode ? [{ debugName: "#positionY" }] : /* istanbul ignore next */ []);
71
+ this.#remainingTimeMs = 0;
72
+ this.#closeTimerStartedAt = 0;
73
+ this.#closeTimerPausedAt = 0;
74
+ this.t = inject(RT_KIT_LABELS);
75
+ this.icon = computed(() => {
76
+ const icon = this.toast().icon;
77
+ return icon === void 0 ? this.#severityIcons[this.toast().severity] : icon;
78
+ }, ...ngDevMode ? [{ debugName: "icon" }] : /* istanbul ignore next */ []);
79
+ this.lifetime = computed(() => {
80
+ const duration = this.toast().duration;
81
+ return duration === void 0 ? this.duration() : duration;
82
+ }, ...ngDevMode ? [{ debugName: "lifetime" }] : /* istanbul ignore next */ []);
83
+ this.showProgress = computed(() => this.toast().progress === true && this.lifetime() !== null, ...ngDevMode ? [{ debugName: "showProgress" }] : /* istanbul ignore next */ []);
84
+ this.paused = computed(() => this.expanded() || this.interacting(), ...ngDevMode ? [{ debugName: "paused" }] : /* istanbul ignore next */ []);
85
+ this.toast = input.required(...ngDevMode ? [{ debugName: "toast" }] : /* istanbul ignore next */ []);
86
+ this.index = input.required(...ngDevMode ? [{ debugName: "index" }] : /* istanbul ignore next */ []);
87
+ this.totalToasts = input.required(...ngDevMode ? [{ debugName: "totalToasts" }] : /* istanbul ignore next */ []);
88
+ this.heights = input.required(...ngDevMode ? [{ debugName: "heights" }] : /* istanbul ignore next */ []);
89
+ this.expanded = input.required({
90
+ ...ngDevMode ? { debugName: "expanded" } : /* istanbul ignore next */ {},
91
+ transform: booleanAttribute
92
+ });
93
+ this.expandByDefault = input(false, {
94
+ ...ngDevMode ? { debugName: "expandByDefault" } : /* istanbul ignore next */ {},
95
+ transform: booleanAttribute
96
+ });
97
+ this.interacting = input(false, {
98
+ ...ngDevMode ? { debugName: "interacting" } : /* istanbul ignore next */ {},
99
+ transform: booleanAttribute
100
+ });
101
+ this.position = input("bottom-right", ...ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []);
102
+ this.visibleToasts = input(3, ...ngDevMode ? [{ debugName: "visibleToasts" }] : /* istanbul ignore next */ []);
103
+ this.duration = input(4e3, ...ngDevMode ? [{ debugName: "duration" }] : /* istanbul ignore next */ []);
104
+ this.heightAdded = output();
105
+ this.heightRemoved = output();
106
+ this.dismissed = output();
107
+ effect((onCleanup) => {
108
+ if (!this.#mounted() || this.#removed() || this.lifetime() === null) return;
109
+ if (this.paused()) this.#pauseTimer();
110
+ else this.#startTimer();
111
+ onCleanup(() => clearTimeout(this.#timeoutId));
112
+ });
113
+ effect(() => {
114
+ if (this.#mounted() && this.toast().replaced === true) this.#deleteToast("replaced");
115
+ });
116
+ }
117
+ ngAfterViewInit() {
118
+ this.#remainingTimeMs = this.lifetime() ?? 0;
119
+ const height = this.#host.nativeElement.getBoundingClientRect().height;
120
+ this.#initialHeight.set(height);
121
+ this.heightAdded.emit({
122
+ toastId: this.toast().id,
123
+ height
124
+ });
125
+ this.#mounted.set(true);
126
+ }
127
+ ngOnDestroy() {
128
+ clearTimeout(this.#timeoutId);
129
+ clearTimeout(this.#unmountTimeoutId);
130
+ }
131
+ onAction() {
132
+ this.toast().action?.handler();
133
+ this.#deleteToast(null);
134
+ }
135
+ onSecondaryAction() {
136
+ this.toast().secondaryAction?.handler();
137
+ this.#deleteToast(null);
138
+ }
139
+ onClose() {
140
+ this.#deleteToast("close");
141
+ }
142
+ #deleteToast(reason) {
143
+ if (this.#removed()) return;
144
+ this.#removed.set(true);
145
+ if (reason !== null) this.toast().onDismiss?.(reason);
146
+ this.#offsetBeforeRemove.set(this.#offset());
147
+ this.heightRemoved.emit(this.toast().id);
148
+ this.#unmountTimeoutId = setTimeout(() => this.dismissed.emit(this.toast().id), UNMOUNT_DELAY_MS);
149
+ }
150
+ #startTimer() {
151
+ this.#closeTimerStartedAt = Date.now();
152
+ this.#timeoutId = setTimeout(() => this.#deleteToast("timeout"), this.#remainingTimeMs);
153
+ }
154
+ #pauseTimer() {
155
+ if (this.#closeTimerPausedAt < this.#closeTimerStartedAt) {
156
+ const elapsedMs = Date.now() - this.#closeTimerStartedAt;
157
+ this.#remainingTimeMs = this.#remainingTimeMs - elapsedMs;
158
+ }
159
+ this.#closeTimerPausedAt = Date.now();
160
+ }
161
+ static {
162
+ this.ɵfac = i0.ɵɵngDeclareFactory({
163
+ minVersion: "12.0.0",
164
+ version: "22.2.2",
165
+ ngImport: i0,
166
+ type: RtToastComponent,
167
+ deps: [],
168
+ target: i0.ɵɵFactoryTarget.Component
169
+ });
170
+ }
171
+ static {
172
+ this.ɵcmp = i0.ɵɵngDeclareComponent({
173
+ minVersion: "17.0.0",
174
+ version: "22.2.2",
175
+ type: RtToastComponent,
176
+ isStandalone: true,
177
+ selector: "rt-toast",
178
+ inputs: {
179
+ toast: {
180
+ classPropertyName: "toast",
181
+ publicName: "toast",
182
+ isSignal: true,
183
+ isRequired: true,
184
+ transformFunction: null
185
+ },
186
+ index: {
187
+ classPropertyName: "index",
188
+ publicName: "index",
189
+ isSignal: true,
190
+ isRequired: true,
191
+ transformFunction: null
192
+ },
193
+ totalToasts: {
194
+ classPropertyName: "totalToasts",
195
+ publicName: "totalToasts",
196
+ isSignal: true,
197
+ isRequired: true,
198
+ transformFunction: null
199
+ },
200
+ heights: {
201
+ classPropertyName: "heights",
202
+ publicName: "heights",
203
+ isSignal: true,
204
+ isRequired: true,
205
+ transformFunction: null
206
+ },
207
+ expanded: {
208
+ classPropertyName: "expanded",
209
+ publicName: "expanded",
210
+ isSignal: true,
211
+ isRequired: true,
212
+ transformFunction: null
213
+ },
214
+ expandByDefault: {
215
+ classPropertyName: "expandByDefault",
216
+ publicName: "expandByDefault",
217
+ isSignal: true,
218
+ isRequired: false,
219
+ transformFunction: null
220
+ },
221
+ interacting: {
222
+ classPropertyName: "interacting",
223
+ publicName: "interacting",
224
+ isSignal: true,
225
+ isRequired: false,
226
+ transformFunction: null
227
+ },
228
+ position: {
229
+ classPropertyName: "position",
230
+ publicName: "position",
231
+ isSignal: true,
232
+ isRequired: false,
233
+ transformFunction: null
234
+ },
235
+ visibleToasts: {
236
+ classPropertyName: "visibleToasts",
237
+ publicName: "visibleToasts",
238
+ isSignal: true,
239
+ isRequired: false,
240
+ transformFunction: null
241
+ },
242
+ duration: {
243
+ classPropertyName: "duration",
244
+ publicName: "duration",
245
+ isSignal: true,
246
+ isRequired: false,
247
+ transformFunction: null
248
+ }
249
+ },
250
+ outputs: {
251
+ heightAdded: "heightAdded",
252
+ heightRemoved: "heightRemoved",
253
+ dismissed: "dismissed"
254
+ },
255
+ host: {
256
+ attributes: {
257
+ "role": "status",
258
+ "aria-atomic": "true"
259
+ },
260
+ properties: {
261
+ "class": "this.hostModifierClasses",
262
+ "style": "this.hostStackStyles"
263
+ },
264
+ classAttribute: "rt-toast"
265
+ },
266
+ ngImport: i0,
267
+ template: "<ng-container rtBlock=\"rt-toast\">\n @if (icon(); as icon) {\n <rt-icon rtElem=\"icon\" qa-dataid=\"toast-icon\" size=\"sm\" [name]=\"icon\" />\n }\n <div rtElem=\"content\" qa-dataid=\"toast-content\">\n @if (toast().meta; as meta) {\n <span rtElem=\"meta\" qa-dataid=\"toast-meta\">{{ meta }}</span>\n }\n <span rtElem=\"message\" qa-dataid=\"toast-message\">{{ toast().message }}</span>\n @if (toast().description; as description) {\n <span rtElem=\"description\" qa-dataid=\"toast-description\">{{ description }}</span>\n }\n @if (toast().action || toast().secondaryAction) {\n <div rtElem=\"actions\">\n @if (toast().action; as action) {\n <button rtButton rtElem=\"action\" qa-dataid=\"toast-action\" size=\"sm\" type=\"button\" (click)=\"onAction()\">\n {{ action.label }}\n </button>\n }\n @if (toast().secondaryAction; as secondaryAction) {\n <button\n rtButton\n rtElem=\"action\"\n qa-dataid=\"toast-secondary-action\"\n size=\"sm\"\n theme=\"secondary\"\n appearance=\"text\"\n type=\"button\"\n (click)=\"onSecondaryAction()\">\n {{ secondaryAction.label }}\n </button>\n }\n </div>\n }\n </div>\n <rt-icon-button\n rtElem=\"close\"\n qa-dataid=\"toast-close\"\n icon=\"ico-close\"\n variant=\"ghost\"\n size=\"sm\"\n [ariaLabel]=\"t().uiClose\"\n (clicked)=\"onClose()\" />\n @if (showProgress()) {\n <span rtElem=\"progress\" qa-dataid=\"toast-progress\" aria-hidden=\"true\"></span>\n }\n</ng-container>\n",
268
+ styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toast{--rt-toast-radius: var(--rt-radius-md);--rt-toast-border-width: var(--rt-border-width-thin);--rt-toast-shadow: var(--rt-shadow-card);--rt-toast-enter-duration: var(--rt-duration-slow);--rt-toast-shadow-duration: var(--rt-duration-base);--rt-toast-leave-duration: var(--rt-duration-slower);--rt-toast-fade-duration: var(--rt-duration-fast);--rt-toast-severity-color: var(--rt-color-state-info);--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));position:absolute;z-index:var(--z-index);display:flex;width:100%;box-sizing:border-box;align-items:center;padding:var(--rt-space-4);border:var(--rt-toast-border-width) solid var(--rt-toast-border-color, var(--rt-color-border-subtle));border-radius:var(--rt-toast-radius);background:var(--rt-toast-bg, var(--rt-color-bg-surface));box-shadow:var(--rt-toast-shadow);color:var(--rt-toast-color, var(--rt-color-text-primary));font-size:var(--rt-text-sm);font-weight:var(--rt-font-weight-medium);gap:var(--rt-space-2);line-height:var(--rt-leading-normal);opacity:0;outline:none;overflow-wrap:anywhere;touch-action:none;transform:var(--y);transition:transform var(--rt-toast-enter-duration),opacity var(--rt-toast-enter-duration),height var(--rt-toast-enter-duration),box-shadow var(--rt-toast-shadow-duration)}.rt-toast:after{position:absolute;bottom:100%;left:0;width:100%;height:calc(var(--gap) + 1px);content:\"\"}.rt-toast>*{transition:opacity var(--rt-toast-enter-duration)}.rt-toast--y--top{--y: translateY(-100%);--lift: 1;top:0}.rt-toast--y--bottom{--y: translateY(100%);--lift: -1;bottom:0}.rt-toast--severity--success{--rt-toast-severity-color: var(--rt-color-state-success)}.rt-toast--severity--warning{--rt-toast-severity-color: var(--rt-color-state-warning)}.rt-toast--severity--danger{--rt-toast-severity-color: var(--rt-color-state-danger)}.rt-toast--filled .rt-toast__description{color:inherit}.rt-toast--filled .rt-toast__icon{color:currentcolor}.rt-toast--filled.rt-toast--severity--info{border-color:var(--rt-toast-filled-info-border-color, var(--rt-color-state-info-bg));background:var(--rt-toast-filled-info-bg, var(--rt-color-state-info-bg));color:var(--rt-toast-filled-info-color, var(--rt-color-state-info))}.rt-toast--filled.rt-toast--severity--success{border-color:var(--rt-toast-filled-success-border-color, var(--rt-color-state-success-bg));background:var(--rt-toast-filled-success-bg, var(--rt-color-state-success-bg));color:var(--rt-toast-filled-success-color, var(--rt-color-state-success))}.rt-toast--filled.rt-toast--severity--warning{border-color:var(--rt-toast-filled-warning-border-color, var(--rt-color-state-warning-bg));background:var(--rt-toast-filled-warning-bg, var(--rt-color-state-warning-bg));color:var(--rt-toast-filled-warning-color, var(--rt-color-state-warning))}.rt-toast--filled.rt-toast--severity--danger{border-color:var(--rt-toast-filled-danger-border-color, var(--rt-color-state-danger-bg));background:var(--rt-toast-filled-danger-bg, var(--rt-color-state-danger-bg));color:var(--rt-toast-filled-danger-color, var(--rt-color-state-danger))}.rt-toast--mounted{--y: translateY(0);opacity:1}.rt-toast:not(.rt-toast--expanded,.rt-toast--front){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}.rt-toast:not(.rt-toast--expanded,.rt-toast--front)>*{opacity:0}.rt-toast--hidden{opacity:0;pointer-events:none}.rt-toast--mounted.rt-toast--expanded{--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}.rt-toast--removed.rt-toast--front{--y: translateY(calc(var(--lift) * -100%));opacity:0}.rt-toast--removed.rt-toast--expanded:not(.rt-toast--front){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}.rt-toast--removed:not(.rt-toast--front,.rt-toast--expanded){--y: translateY(40%);opacity:0;transition:transform var(--rt-toast-leave-duration),opacity var(--rt-toast-shadow-duration)}.rt-toast--removed:not(.rt-toast--front):before{position:absolute;content:\"\";inset:0;transform:scaleY(2)}.rt-toast__icon{flex-shrink:0;color:var(--rt-toast-icon-color, var(--rt-toast-severity-color))}.rt-toast__progress{position:absolute;bottom:0;animation:rt-toast-progress var(--lifetime) linear forwards;background:var(--rt-toast-progress-color, var(--rt-toast-severity-color));block-size:var(--rt-toast-progress-height, var(--rt-space-0-5));border-end-end-radius:var(--rt-toast-radius);border-end-start-radius:var(--rt-toast-radius);inset-inline:0;transform-origin:left center}.rt-toast--paused .rt-toast__progress{animation-play-state:paused}.rt-toast__content{display:flex;min-width:0;flex:1 1 auto;flex-direction:column;gap:var(--rt-space-0-5)}.rt-toast__description,.rt-toast__meta{color:var(--rt-color-text-muted);font-size:var(--rt-text-xs);font-weight:var(--rt-font-weight-regular)}.rt-toast__actions{display:flex;flex-wrap:wrap;align-items:center;gap:var(--rt-space-2);margin-block-start:var(--rt-space-1)}.rt-toast .rt-toast__action{align-self:flex-start}.rt-toast .rt-toast__action:not(.rt-button--text){--rt-btn-bg: var(--rt-toast-action-color, var(--rt-color-action-primary));--rt-btn-bg-hover: var(--rt-toast-action-color, var(--rt-color-action-primary-hover));--rt-btn-bg-active: var(--rt-toast-action-color, var(--rt-color-action-primary-active))}.rt-toast .rt-toast__close{--rt-icon-button-color: var(--rt-toast-close-color, var(--rt-color-text-primary));flex-shrink:0;align-self:flex-start;margin-inline-start:auto;opacity:0;transition:opacity var(--rt-toast-fade-duration)}.rt-toast:hover .rt-toast__close,.rt-toast .rt-toast__close:focus-visible{opacity:1}@media(prefers-reduced-motion){.rt-toast{transition:none}.rt-toast>*{transition:none}}@keyframes rt-toast-progress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}}\n"],
269
+ dependencies: [
270
+ {
271
+ kind: "directive",
272
+ type: RtButtonDirective,
273
+ selector: "button[rtButton], a[rtButton]",
274
+ inputs: [
275
+ "label",
276
+ "icon",
277
+ "iconPos",
278
+ "theme",
279
+ "appearance",
280
+ "size",
281
+ "loading",
282
+ "loadingIcon",
283
+ "loadingLabel",
284
+ "pressed"
285
+ ]
286
+ },
287
+ {
288
+ kind: "component",
289
+ type: RtIconComponent,
290
+ selector: "rt-icon",
291
+ inputs: [
292
+ "name",
293
+ "glyph",
294
+ "glyphStrategy",
295
+ "size",
296
+ "color",
297
+ "fill",
298
+ "spin",
299
+ "rotate"
300
+ ]
301
+ },
302
+ {
303
+ kind: "component",
304
+ type: RtIconButtonComponent,
305
+ selector: "rt-icon-button",
306
+ inputs: [
307
+ "icon",
308
+ "glyph",
309
+ "ariaLabel",
310
+ "variant",
311
+ "iconColor",
312
+ "iconFill",
313
+ "size",
314
+ "iconSize",
315
+ "type",
316
+ "tooltip",
317
+ "tooltipHideOnClick",
318
+ "tabIndex",
319
+ "loading",
320
+ "disabled",
321
+ "active",
322
+ "expanded",
323
+ "indicator"
324
+ ],
325
+ outputs: ["clicked"]
326
+ },
327
+ {
328
+ kind: "directive",
329
+ type: BlockDirective,
330
+ selector: "[rtBlock]",
331
+ inputs: ["rtMod"]
332
+ },
333
+ {
334
+ kind: "directive",
335
+ type: ElemDirective,
336
+ selector: "[rtElem]",
337
+ inputs: ["rtMod"]
338
+ }
339
+ ],
340
+ changeDetection: i0.ChangeDetectionStrategy.OnPush,
341
+ encapsulation: i0.ViewEncapsulation.None
342
+ });
343
+ }
344
+ };
345
+ i0.ɵɵngDeclareClassMetadata({
346
+ minVersion: "12.0.0",
347
+ version: "22.2.2",
348
+ ngImport: i0,
349
+ type: RtToastComponent,
350
+ decorators: [{
351
+ type: Component,
352
+ args: [{
353
+ selector: "rt-toast",
354
+ changeDetection: ChangeDetectionStrategy.OnPush,
355
+ encapsulation: ViewEncapsulation.None,
356
+ imports: [
357
+ RtButtonDirective,
358
+ RtIconComponent,
359
+ RtIconButtonComponent,
360
+ BlockDirective,
361
+ ElemDirective
362
+ ],
363
+ host: {
364
+ class: BEM_BLOCK$1,
365
+ role: "status",
366
+ "aria-atomic": "true"
367
+ },
368
+ template: "<ng-container rtBlock=\"rt-toast\">\n @if (icon(); as icon) {\n <rt-icon rtElem=\"icon\" qa-dataid=\"toast-icon\" size=\"sm\" [name]=\"icon\" />\n }\n <div rtElem=\"content\" qa-dataid=\"toast-content\">\n @if (toast().meta; as meta) {\n <span rtElem=\"meta\" qa-dataid=\"toast-meta\">{{ meta }}</span>\n }\n <span rtElem=\"message\" qa-dataid=\"toast-message\">{{ toast().message }}</span>\n @if (toast().description; as description) {\n <span rtElem=\"description\" qa-dataid=\"toast-description\">{{ description }}</span>\n }\n @if (toast().action || toast().secondaryAction) {\n <div rtElem=\"actions\">\n @if (toast().action; as action) {\n <button rtButton rtElem=\"action\" qa-dataid=\"toast-action\" size=\"sm\" type=\"button\" (click)=\"onAction()\">\n {{ action.label }}\n </button>\n }\n @if (toast().secondaryAction; as secondaryAction) {\n <button\n rtButton\n rtElem=\"action\"\n qa-dataid=\"toast-secondary-action\"\n size=\"sm\"\n theme=\"secondary\"\n appearance=\"text\"\n type=\"button\"\n (click)=\"onSecondaryAction()\">\n {{ secondaryAction.label }}\n </button>\n }\n </div>\n }\n </div>\n <rt-icon-button\n rtElem=\"close\"\n qa-dataid=\"toast-close\"\n icon=\"ico-close\"\n variant=\"ghost\"\n size=\"sm\"\n [ariaLabel]=\"t().uiClose\"\n (clicked)=\"onClose()\" />\n @if (showProgress()) {\n <span rtElem=\"progress\" qa-dataid=\"toast-progress\" aria-hidden=\"true\"></span>\n }\n</ng-container>\n",
369
+ styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toast{--rt-toast-radius: var(--rt-radius-md);--rt-toast-border-width: var(--rt-border-width-thin);--rt-toast-shadow: var(--rt-shadow-card);--rt-toast-enter-duration: var(--rt-duration-slow);--rt-toast-shadow-duration: var(--rt-duration-base);--rt-toast-leave-duration: var(--rt-duration-slower);--rt-toast-fade-duration: var(--rt-duration-fast);--rt-toast-severity-color: var(--rt-color-state-info);--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));position:absolute;z-index:var(--z-index);display:flex;width:100%;box-sizing:border-box;align-items:center;padding:var(--rt-space-4);border:var(--rt-toast-border-width) solid var(--rt-toast-border-color, var(--rt-color-border-subtle));border-radius:var(--rt-toast-radius);background:var(--rt-toast-bg, var(--rt-color-bg-surface));box-shadow:var(--rt-toast-shadow);color:var(--rt-toast-color, var(--rt-color-text-primary));font-size:var(--rt-text-sm);font-weight:var(--rt-font-weight-medium);gap:var(--rt-space-2);line-height:var(--rt-leading-normal);opacity:0;outline:none;overflow-wrap:anywhere;touch-action:none;transform:var(--y);transition:transform var(--rt-toast-enter-duration),opacity var(--rt-toast-enter-duration),height var(--rt-toast-enter-duration),box-shadow var(--rt-toast-shadow-duration)}.rt-toast:after{position:absolute;bottom:100%;left:0;width:100%;height:calc(var(--gap) + 1px);content:\"\"}.rt-toast>*{transition:opacity var(--rt-toast-enter-duration)}.rt-toast--y--top{--y: translateY(-100%);--lift: 1;top:0}.rt-toast--y--bottom{--y: translateY(100%);--lift: -1;bottom:0}.rt-toast--severity--success{--rt-toast-severity-color: var(--rt-color-state-success)}.rt-toast--severity--warning{--rt-toast-severity-color: var(--rt-color-state-warning)}.rt-toast--severity--danger{--rt-toast-severity-color: var(--rt-color-state-danger)}.rt-toast--filled .rt-toast__description{color:inherit}.rt-toast--filled .rt-toast__icon{color:currentcolor}.rt-toast--filled.rt-toast--severity--info{border-color:var(--rt-toast-filled-info-border-color, var(--rt-color-state-info-bg));background:var(--rt-toast-filled-info-bg, var(--rt-color-state-info-bg));color:var(--rt-toast-filled-info-color, var(--rt-color-state-info))}.rt-toast--filled.rt-toast--severity--success{border-color:var(--rt-toast-filled-success-border-color, var(--rt-color-state-success-bg));background:var(--rt-toast-filled-success-bg, var(--rt-color-state-success-bg));color:var(--rt-toast-filled-success-color, var(--rt-color-state-success))}.rt-toast--filled.rt-toast--severity--warning{border-color:var(--rt-toast-filled-warning-border-color, var(--rt-color-state-warning-bg));background:var(--rt-toast-filled-warning-bg, var(--rt-color-state-warning-bg));color:var(--rt-toast-filled-warning-color, var(--rt-color-state-warning))}.rt-toast--filled.rt-toast--severity--danger{border-color:var(--rt-toast-filled-danger-border-color, var(--rt-color-state-danger-bg));background:var(--rt-toast-filled-danger-bg, var(--rt-color-state-danger-bg));color:var(--rt-toast-filled-danger-color, var(--rt-color-state-danger))}.rt-toast--mounted{--y: translateY(0);opacity:1}.rt-toast:not(.rt-toast--expanded,.rt-toast--front){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}.rt-toast:not(.rt-toast--expanded,.rt-toast--front)>*{opacity:0}.rt-toast--hidden{opacity:0;pointer-events:none}.rt-toast--mounted.rt-toast--expanded{--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}.rt-toast--removed.rt-toast--front{--y: translateY(calc(var(--lift) * -100%));opacity:0}.rt-toast--removed.rt-toast--expanded:not(.rt-toast--front){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}.rt-toast--removed:not(.rt-toast--front,.rt-toast--expanded){--y: translateY(40%);opacity:0;transition:transform var(--rt-toast-leave-duration),opacity var(--rt-toast-shadow-duration)}.rt-toast--removed:not(.rt-toast--front):before{position:absolute;content:\"\";inset:0;transform:scaleY(2)}.rt-toast__icon{flex-shrink:0;color:var(--rt-toast-icon-color, var(--rt-toast-severity-color))}.rt-toast__progress{position:absolute;bottom:0;animation:rt-toast-progress var(--lifetime) linear forwards;background:var(--rt-toast-progress-color, var(--rt-toast-severity-color));block-size:var(--rt-toast-progress-height, var(--rt-space-0-5));border-end-end-radius:var(--rt-toast-radius);border-end-start-radius:var(--rt-toast-radius);inset-inline:0;transform-origin:left center}.rt-toast--paused .rt-toast__progress{animation-play-state:paused}.rt-toast__content{display:flex;min-width:0;flex:1 1 auto;flex-direction:column;gap:var(--rt-space-0-5)}.rt-toast__description,.rt-toast__meta{color:var(--rt-color-text-muted);font-size:var(--rt-text-xs);font-weight:var(--rt-font-weight-regular)}.rt-toast__actions{display:flex;flex-wrap:wrap;align-items:center;gap:var(--rt-space-2);margin-block-start:var(--rt-space-1)}.rt-toast .rt-toast__action{align-self:flex-start}.rt-toast .rt-toast__action:not(.rt-button--text){--rt-btn-bg: var(--rt-toast-action-color, var(--rt-color-action-primary));--rt-btn-bg-hover: var(--rt-toast-action-color, var(--rt-color-action-primary-hover));--rt-btn-bg-active: var(--rt-toast-action-color, var(--rt-color-action-primary-active))}.rt-toast .rt-toast__close{--rt-icon-button-color: var(--rt-toast-close-color, var(--rt-color-text-primary));flex-shrink:0;align-self:flex-start;margin-inline-start:auto;opacity:0;transition:opacity var(--rt-toast-fade-duration)}.rt-toast:hover .rt-toast__close,.rt-toast .rt-toast__close:focus-visible{opacity:1}@media(prefers-reduced-motion){.rt-toast{transition:none}.rt-toast>*{transition:none}}@keyframes rt-toast-progress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}}\n"]
370
+ }]
371
+ }],
372
+ ctorParameters: () => [],
373
+ propDecorators: {
374
+ toast: [{
375
+ type: i0.Input,
376
+ args: [{
377
+ isSignal: true,
378
+ alias: "toast",
379
+ required: true
380
+ }]
381
+ }],
382
+ index: [{
383
+ type: i0.Input,
384
+ args: [{
385
+ isSignal: true,
386
+ alias: "index",
387
+ required: true
388
+ }]
389
+ }],
390
+ totalToasts: [{
391
+ type: i0.Input,
392
+ args: [{
393
+ isSignal: true,
394
+ alias: "totalToasts",
395
+ required: true
396
+ }]
397
+ }],
398
+ heights: [{
399
+ type: i0.Input,
400
+ args: [{
401
+ isSignal: true,
402
+ alias: "heights",
403
+ required: true
404
+ }]
405
+ }],
406
+ expanded: [{
407
+ type: i0.Input,
408
+ args: [{
409
+ isSignal: true,
410
+ alias: "expanded",
411
+ required: true
412
+ }]
413
+ }],
414
+ expandByDefault: [{
415
+ type: i0.Input,
416
+ args: [{
417
+ isSignal: true,
418
+ alias: "expandByDefault",
419
+ required: false
420
+ }]
421
+ }],
422
+ interacting: [{
423
+ type: i0.Input,
424
+ args: [{
425
+ isSignal: true,
426
+ alias: "interacting",
427
+ required: false
428
+ }]
429
+ }],
430
+ position: [{
431
+ type: i0.Input,
432
+ args: [{
433
+ isSignal: true,
434
+ alias: "position",
435
+ required: false
436
+ }]
437
+ }],
438
+ visibleToasts: [{
439
+ type: i0.Input,
440
+ args: [{
441
+ isSignal: true,
442
+ alias: "visibleToasts",
443
+ required: false
444
+ }]
445
+ }],
446
+ duration: [{
447
+ type: i0.Input,
448
+ args: [{
449
+ isSignal: true,
450
+ alias: "duration",
451
+ required: false
452
+ }]
453
+ }],
454
+ heightAdded: [{
455
+ type: i0.Output,
456
+ args: ["heightAdded"]
457
+ }],
458
+ heightRemoved: [{
459
+ type: i0.Output,
460
+ args: ["heightRemoved"]
461
+ }],
462
+ dismissed: [{
463
+ type: i0.Output,
464
+ args: ["dismissed"]
465
+ }],
466
+ hostModifierClasses: [{
467
+ type: HostBinding,
468
+ args: ["class"]
469
+ }],
470
+ hostStackStyles: [{
471
+ type: HostBinding,
472
+ args: ["style"]
473
+ }]
474
+ }
475
+ });
476
+ const BEM_BLOCK = "rt-toaster";
477
+ const DEFAULT_DURATION_MS = 4e3;
211
478
  const DEFAULT_VISIBLE_TOASTS = 3;
212
- class RtToasterComponent {
213
- #notificationBus;
214
- #toastCounter;
215
- get hostModifierClasses() {
216
- return {
217
- [`${BEM_BLOCK}--y--${this.positionY()}`]: true,
218
- [`${BEM_BLOCK}--x--${this.positionX()}`]: true,
219
- };
220
- }
221
- get hostStackStyles() {
222
- return {
223
- '--front-toast-height': `${this.heights()[0]?.height ?? 0}px`,
224
- '--gap': `${RT_TOASTER_GAP_PX}px`,
225
- };
226
- }
227
- constructor() {
228
- this.#notificationBus = inject(NotificationBus);
229
- this.ariaLabel = rtKitLabel('uiNotifications');
230
- this.#toastCounter = 0;
231
- this.toasts = signal([], /* @ts-ignore */
232
- ...(ngDevMode ? [{ debugName: "toasts" }] : /* istanbul ignore next */ []));
233
- this.heights = signal([], /* @ts-ignore */
234
- ...(ngDevMode ? [{ debugName: "heights" }] : /* istanbul ignore next */ []));
235
- this.expanded = linkedSignal({ ...(ngDevMode ? { debugName: "expanded" } : /* istanbul ignore next */ {}), source: this.toasts,
236
- computation: (toasts) => toasts.length < 1 });
237
- this.interacting = signal(false, /* @ts-ignore */
238
- ...(ngDevMode ? [{ debugName: "interacting" }] : /* istanbul ignore next */ []));
239
- this.positionY = computed(() => this.position().startsWith('top') ? 'top' : 'bottom', /* @ts-ignore */
240
- ...(ngDevMode ? [{ debugName: "positionY" }] : /* istanbul ignore next */ []));
241
- this.positionX = computed(() => {
242
- if (this.position().endsWith('left')) {
243
- return 'left';
244
- }
245
- return this.position().endsWith('center') ? 'center' : 'right';
246
- }, /* @ts-ignore */
247
- ...(ngDevMode ? [{ debugName: "positionX" }] : /* istanbul ignore next */ []));
248
- this.position = input('bottom-right', /* @ts-ignore */
249
- ...(ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []));
250
- this.duration = input(DEFAULT_DURATION_MS, { ...(ngDevMode ? { debugName: "duration" } : /* istanbul ignore next */ {}), transform: numberAttribute });
251
- this.visibleToasts = input(DEFAULT_VISIBLE_TOASTS, { ...(ngDevMode ? { debugName: "visibleToasts" } : /* istanbul ignore next */ {}), transform: numberAttribute });
252
- /** `replace` — новый тост уводит прежние их же анимацией ухода, а не копится стопкой. */
253
- this.mode = input('stack', /* @ts-ignore */
254
- ...(ngDevMode ? [{ debugName: "mode" }] : /* istanbul ignore next */ []));
255
- this.expand = input(false, { ...(ngDevMode ? { debugName: "expand" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
256
- this.#notificationBus
257
- .onEmit()
258
- .pipe(takeUntilDestroyed())
259
- .subscribe((event) => this.#addToast(event));
260
- }
261
- onStackEnter() {
262
- if (this.toasts().length > 0) {
263
- this.expanded.set(true);
264
- }
265
- }
266
- onStackLeave() {
267
- if (!this.interacting()) {
268
- this.expanded.set(false);
269
- }
270
- }
271
- onStackPointerDown() {
272
- this.interacting.set(true);
273
- }
274
- onStackPointerUp() {
275
- this.interacting.set(false);
276
- }
277
- onHeightAdded(height) {
278
- this.heights.update((items) => this.#sortHeights([height, ...items.filter((item) => item.toastId !== height.toastId)]));
279
- }
280
- onHeightRemoved(toastId) {
281
- this.heights.update((items) => items.filter((item) => item.toastId !== toastId));
282
- }
283
- onDismissed(toastId) {
284
- this.onHeightRemoved(toastId);
285
- this.toasts.update((items) => items.filter((item) => item.id !== toastId));
286
- }
287
- #addToast(event) {
288
- this.#toastCounter += 1;
289
- const toast = {
290
- id: this.#toastCounter,
291
- severity: event.payload.severity,
292
- message: event.payload.message,
293
- description: event.payload.description,
294
- meta: event.payload.meta,
295
- action: event.payload.action,
296
- secondaryAction: event.payload.secondaryAction,
297
- filled: event.payload.filled,
298
- duration: event.payload.duration,
299
- progress: event.payload.progress,
300
- icon: event.payload.icon,
301
- onDismiss: event.payload.onDismiss,
302
- };
303
- this.toasts.update((items) => [
304
- toast,
305
- ...(this.mode() === 'replace' ? items.map((item) => this.#replaced(item)) : items),
306
- ]);
307
- }
308
- #replaced(toast) {
309
- return toast.replaced ? toast : { ...toast, replaced: true };
310
- }
311
- #sortHeights(items) {
312
- const order = this.toasts().map((toast) => toast.id);
313
- return [...items].sort((left, right) => order.indexOf(left.toastId) - order.indexOf(right.toastId));
314
- }
315
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: RtToasterComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
316
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.6", type: RtToasterComponent, isStandalone: true, selector: "rt-toaster", inputs: { position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null }, duration: { classPropertyName: "duration", publicName: "duration", isSignal: true, isRequired: false, transformFunction: null }, visibleToasts: { classPropertyName: "visibleToasts", publicName: "visibleToasts", isSignal: true, isRequired: false, transformFunction: null }, mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null }, expand: { classPropertyName: "expand", publicName: "expand", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "region" }, listeners: { "mouseenter": "onStackEnter()", "mousemove": "onStackEnter()", "mouseleave": "onStackLeave()", "pointerdown": "onStackPointerDown()", "pointerup": "onStackPointerUp()" }, properties: { "attr.aria-label": "ariaLabel()", "class": "this.hostModifierClasses", "style": "this.hostStackStyles" }, classAttribute: "rt-toaster" }, ngImport: i0, template: "@for (item of toasts(); track item.id) {\n <rt-toast\n qa-dataid=\"toast\"\n [toast]=\"item\"\n [index]=\"$index\"\n [totalToasts]=\"toasts().length\"\n [heights]=\"heights()\"\n [expanded]=\"expanded()\"\n [expandByDefault]=\"expand()\"\n [interacting]=\"interacting()\"\n [position]=\"position()\"\n [visibleToasts]=\"visibleToasts()\"\n [duration]=\"duration()\"\n (heightAdded)=\"onHeightAdded($event)\"\n (heightRemoved)=\"onHeightRemoved($event)\"\n (dismissed)=\"onDismissed($event)\" />\n}\n", styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toaster{--width: 356px;--toaster-offset: 32px;--rt-toaster-z-index: var(--rt-z-sticky);position:fixed;z-index:var(--rt-toaster-z-index);width:var(--width);box-sizing:border-box;padding:0;margin:0;outline:none}.rt-toaster--x--right{right:max(var(--toaster-offset),env(safe-area-inset-right))}.rt-toaster--x--left{left:max(var(--toaster-offset),env(safe-area-inset-left))}.rt-toaster--x--center{left:50%;transform:translate(-50%)}.rt-toaster--y--top{top:max(var(--toaster-offset),env(safe-area-inset-top))}.rt-toaster--y--bottom{bottom:max(var(--toaster-offset),env(safe-area-inset-bottom))}@media(width<=480px){.rt-toaster{--toaster-offset: 16px;right:var(--toaster-offset);left:var(--toaster-offset);width:auto}.rt-toaster--x--center{transform:none}}}\n"], dependencies: [{ kind: "component", type: RtToastComponent, selector: "rt-toast", inputs: ["toast", "index", "totalToasts", "heights", "expanded", "expandByDefault", "interacting", "position", "visibleToasts", "duration"], outputs: ["heightAdded", "heightRemoved", "dismissed"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
317
- }
318
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.6", ngImport: i0, type: RtToasterComponent, decorators: [{
319
- type: Component,
320
- args: [{ selector: 'rt-toaster', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [RtToastComponent], host: {
321
- class: BEM_BLOCK,
322
- role: 'region',
323
- '[attr.aria-label]': 'ariaLabel()',
324
- '(mouseenter)': 'onStackEnter()',
325
- '(mousemove)': 'onStackEnter()',
326
- '(mouseleave)': 'onStackLeave()',
327
- '(pointerdown)': 'onStackPointerDown()',
328
- '(pointerup)': 'onStackPointerUp()',
329
- }, template: "@for (item of toasts(); track item.id) {\n <rt-toast\n qa-dataid=\"toast\"\n [toast]=\"item\"\n [index]=\"$index\"\n [totalToasts]=\"toasts().length\"\n [heights]=\"heights()\"\n [expanded]=\"expanded()\"\n [expandByDefault]=\"expand()\"\n [interacting]=\"interacting()\"\n [position]=\"position()\"\n [visibleToasts]=\"visibleToasts()\"\n [duration]=\"duration()\"\n (heightAdded)=\"onHeightAdded($event)\"\n (heightRemoved)=\"onHeightRemoved($event)\"\n (dismissed)=\"onDismissed($event)\" />\n}\n", styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toaster{--width: 356px;--toaster-offset: 32px;--rt-toaster-z-index: var(--rt-z-sticky);position:fixed;z-index:var(--rt-toaster-z-index);width:var(--width);box-sizing:border-box;padding:0;margin:0;outline:none}.rt-toaster--x--right{right:max(var(--toaster-offset),env(safe-area-inset-right))}.rt-toaster--x--left{left:max(var(--toaster-offset),env(safe-area-inset-left))}.rt-toaster--x--center{left:50%;transform:translate(-50%)}.rt-toaster--y--top{top:max(var(--toaster-offset),env(safe-area-inset-top))}.rt-toaster--y--bottom{bottom:max(var(--toaster-offset),env(safe-area-inset-bottom))}@media(width<=480px){.rt-toaster{--toaster-offset: 16px;right:var(--toaster-offset);left:var(--toaster-offset);width:auto}.rt-toaster--x--center{transform:none}}}\n"] }]
330
- }], ctorParameters: () => [], propDecorators: { position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], duration: [{ type: i0.Input, args: [{ isSignal: true, alias: "duration", required: false }] }], visibleToasts: [{ type: i0.Input, args: [{ isSignal: true, alias: "visibleToasts", required: false }] }], mode: [{ type: i0.Input, args: [{ isSignal: true, alias: "mode", required: false }] }], expand: [{ type: i0.Input, args: [{ isSignal: true, alias: "expand", required: false }] }], hostModifierClasses: [{
331
- type: HostBinding,
332
- args: ['class']
333
- }], hostStackStyles: [{
334
- type: HostBinding,
335
- args: ['style']
336
- }] } });
337
-
338
- /**
339
- * Generated bundle index. Do not edit.
340
- */
341
-
479
+ var RtToasterComponent = class RtToasterComponent {
480
+ #notificationBus;
481
+ #toastCounter;
482
+ get hostModifierClasses() {
483
+ return {
484
+ [`${BEM_BLOCK}--y--${this.positionY()}`]: true,
485
+ [`${BEM_BLOCK}--x--${this.positionX()}`]: true
486
+ };
487
+ }
488
+ get hostStackStyles() {
489
+ return {
490
+ "--front-toast-height": `${this.heights()[0]?.height ?? 0}px`,
491
+ "--gap": `14px`
492
+ };
493
+ }
494
+ constructor() {
495
+ this.#notificationBus = inject(NotificationBus);
496
+ this.ariaLabel = rtKitLabel("uiNotifications");
497
+ this.#toastCounter = 0;
498
+ this.toasts = signal([], ...ngDevMode ? [{ debugName: "toasts" }] : /* istanbul ignore next */ []);
499
+ this.heights = signal([], ...ngDevMode ? [{ debugName: "heights" }] : /* istanbul ignore next */ []);
500
+ this.expanded = linkedSignal({
501
+ ...ngDevMode ? { debugName: "expanded" } : /* istanbul ignore next */ {},
502
+ source: this.toasts,
503
+ computation: (toasts) => toasts.length < 1
504
+ });
505
+ this.interacting = signal(false, ...ngDevMode ? [{ debugName: "interacting" }] : /* istanbul ignore next */ []);
506
+ this.positionY = computed(() => this.position().startsWith("top") ? "top" : "bottom", ...ngDevMode ? [{ debugName: "positionY" }] : /* istanbul ignore next */ []);
507
+ this.positionX = computed(() => {
508
+ if (this.position().endsWith("left")) return "left";
509
+ return this.position().endsWith("center") ? "center" : "right";
510
+ }, ...ngDevMode ? [{ debugName: "positionX" }] : /* istanbul ignore next */ []);
511
+ this.position = input("bottom-right", ...ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []);
512
+ this.duration = input(DEFAULT_DURATION_MS, {
513
+ ...ngDevMode ? { debugName: "duration" } : /* istanbul ignore next */ {},
514
+ transform: numberAttribute
515
+ });
516
+ this.visibleToasts = input(DEFAULT_VISIBLE_TOASTS, {
517
+ ...ngDevMode ? { debugName: "visibleToasts" } : /* istanbul ignore next */ {},
518
+ transform: numberAttribute
519
+ });
520
+ this.mode = input("stack", ...ngDevMode ? [{ debugName: "mode" }] : /* istanbul ignore next */ []);
521
+ this.expand = input(false, {
522
+ ...ngDevMode ? { debugName: "expand" } : /* istanbul ignore next */ {},
523
+ transform: booleanAttribute
524
+ });
525
+ this.#notificationBus.onEmit().pipe(takeUntilDestroyed()).subscribe((event) => this.#addToast(event));
526
+ }
527
+ onStackEnter() {
528
+ if (this.toasts().length > 0) this.expanded.set(true);
529
+ }
530
+ onStackLeave() {
531
+ if (!this.interacting()) this.expanded.set(false);
532
+ }
533
+ onStackPointerDown() {
534
+ this.interacting.set(true);
535
+ }
536
+ onStackPointerUp() {
537
+ this.interacting.set(false);
538
+ }
539
+ onHeightAdded(height) {
540
+ this.heights.update((items) => this.#sortHeights([height, ...items.filter((item) => item.toastId !== height.toastId)]));
541
+ }
542
+ onHeightRemoved(toastId) {
543
+ this.heights.update((items) => items.filter((item) => item.toastId !== toastId));
544
+ }
545
+ onDismissed(toastId) {
546
+ this.onHeightRemoved(toastId);
547
+ this.toasts.update((items) => items.filter((item) => item.id !== toastId));
548
+ }
549
+ #addToast(event) {
550
+ this.#toastCounter += 1;
551
+ const toast = {
552
+ id: this.#toastCounter,
553
+ severity: event.payload.severity,
554
+ message: event.payload.message,
555
+ description: event.payload.description,
556
+ meta: event.payload.meta,
557
+ action: event.payload.action,
558
+ secondaryAction: event.payload.secondaryAction,
559
+ filled: event.payload.filled,
560
+ duration: event.payload.duration,
561
+ progress: event.payload.progress,
562
+ icon: event.payload.icon,
563
+ onDismiss: event.payload.onDismiss
564
+ };
565
+ this.toasts.update((items) => [toast, ...this.mode() === "replace" ? items.map((item) => this.#replaced(item)) : items]);
566
+ }
567
+ #replaced(toast) {
568
+ return toast.replaced ? toast : {
569
+ ...toast,
570
+ replaced: true
571
+ };
572
+ }
573
+ #sortHeights(items) {
574
+ const order = this.toasts().map((toast) => toast.id);
575
+ return [...items].sort((left, right) => order.indexOf(left.toastId) - order.indexOf(right.toastId));
576
+ }
577
+ static {
578
+ this.ɵfac = i0.ɵɵngDeclareFactory({
579
+ minVersion: "12.0.0",
580
+ version: "22.2.2",
581
+ ngImport: i0,
582
+ type: RtToasterComponent,
583
+ deps: [],
584
+ target: i0.ɵɵFactoryTarget.Component
585
+ });
586
+ }
587
+ static {
588
+ this.ɵcmp = i0.ɵɵngDeclareComponent({
589
+ minVersion: "17.0.0",
590
+ version: "22.2.2",
591
+ type: RtToasterComponent,
592
+ isStandalone: true,
593
+ selector: "rt-toaster",
594
+ inputs: {
595
+ position: {
596
+ classPropertyName: "position",
597
+ publicName: "position",
598
+ isSignal: true,
599
+ isRequired: false,
600
+ transformFunction: null
601
+ },
602
+ duration: {
603
+ classPropertyName: "duration",
604
+ publicName: "duration",
605
+ isSignal: true,
606
+ isRequired: false,
607
+ transformFunction: null
608
+ },
609
+ visibleToasts: {
610
+ classPropertyName: "visibleToasts",
611
+ publicName: "visibleToasts",
612
+ isSignal: true,
613
+ isRequired: false,
614
+ transformFunction: null
615
+ },
616
+ mode: {
617
+ classPropertyName: "mode",
618
+ publicName: "mode",
619
+ isSignal: true,
620
+ isRequired: false,
621
+ transformFunction: null
622
+ },
623
+ expand: {
624
+ classPropertyName: "expand",
625
+ publicName: "expand",
626
+ isSignal: true,
627
+ isRequired: false,
628
+ transformFunction: null
629
+ }
630
+ },
631
+ host: {
632
+ attributes: { "role": "region" },
633
+ listeners: {
634
+ "mouseenter": "onStackEnter()",
635
+ "mousemove": "onStackEnter()",
636
+ "mouseleave": "onStackLeave()",
637
+ "pointerdown": "onStackPointerDown()",
638
+ "pointerup": "onStackPointerUp()"
639
+ },
640
+ properties: {
641
+ "attr.aria-label": "ariaLabel()",
642
+ "class": "this.hostModifierClasses",
643
+ "style": "this.hostStackStyles"
644
+ },
645
+ classAttribute: "rt-toaster"
646
+ },
647
+ ngImport: i0,
648
+ template: "@for (item of toasts(); track item.id) {\n <rt-toast\n qa-dataid=\"toast\"\n [toast]=\"item\"\n [index]=\"$index\"\n [totalToasts]=\"toasts().length\"\n [heights]=\"heights()\"\n [expanded]=\"expanded()\"\n [expandByDefault]=\"expand()\"\n [interacting]=\"interacting()\"\n [position]=\"position()\"\n [visibleToasts]=\"visibleToasts()\"\n [duration]=\"duration()\"\n (heightAdded)=\"onHeightAdded($event)\"\n (heightRemoved)=\"onHeightRemoved($event)\"\n (dismissed)=\"onDismissed($event)\" />\n}\n",
649
+ styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toaster{--width: 356px;--toaster-offset: 32px;--rt-toaster-z-index: var(--rt-z-sticky);position:fixed;z-index:var(--rt-toaster-z-index);width:var(--width);box-sizing:border-box;padding:0;margin:0;outline:none}.rt-toaster--x--right{right:max(var(--toaster-offset),env(safe-area-inset-right))}.rt-toaster--x--left{left:max(var(--toaster-offset),env(safe-area-inset-left))}.rt-toaster--x--center{left:50%;transform:translate(-50%)}.rt-toaster--y--top{top:max(var(--toaster-offset),env(safe-area-inset-top))}.rt-toaster--y--bottom{bottom:max(var(--toaster-offset),env(safe-area-inset-bottom))}@media(width<=480px){.rt-toaster{--toaster-offset: 16px;right:var(--toaster-offset);left:var(--toaster-offset);width:auto}.rt-toaster--x--center{transform:none}}}\n"],
650
+ dependencies: [{
651
+ kind: "component",
652
+ type: RtToastComponent,
653
+ selector: "rt-toast",
654
+ inputs: [
655
+ "toast",
656
+ "index",
657
+ "totalToasts",
658
+ "heights",
659
+ "expanded",
660
+ "expandByDefault",
661
+ "interacting",
662
+ "position",
663
+ "visibleToasts",
664
+ "duration"
665
+ ],
666
+ outputs: [
667
+ "heightAdded",
668
+ "heightRemoved",
669
+ "dismissed"
670
+ ]
671
+ }],
672
+ changeDetection: i0.ChangeDetectionStrategy.OnPush,
673
+ encapsulation: i0.ViewEncapsulation.None
674
+ });
675
+ }
676
+ };
677
+ i0.ɵɵngDeclareClassMetadata({
678
+ minVersion: "12.0.0",
679
+ version: "22.2.2",
680
+ ngImport: i0,
681
+ type: RtToasterComponent,
682
+ decorators: [{
683
+ type: Component,
684
+ args: [{
685
+ selector: "rt-toaster",
686
+ changeDetection: ChangeDetectionStrategy.OnPush,
687
+ encapsulation: ViewEncapsulation.None,
688
+ imports: [RtToastComponent],
689
+ host: {
690
+ class: BEM_BLOCK,
691
+ role: "region",
692
+ "[attr.aria-label]": "ariaLabel()",
693
+ "(mouseenter)": "onStackEnter()",
694
+ "(mousemove)": "onStackEnter()",
695
+ "(mouseleave)": "onStackLeave()",
696
+ "(pointerdown)": "onStackPointerDown()",
697
+ "(pointerup)": "onStackPointerUp()"
698
+ },
699
+ template: "@for (item of toasts(); track item.id) {\n <rt-toast\n qa-dataid=\"toast\"\n [toast]=\"item\"\n [index]=\"$index\"\n [totalToasts]=\"toasts().length\"\n [heights]=\"heights()\"\n [expanded]=\"expanded()\"\n [expandByDefault]=\"expand()\"\n [interacting]=\"interacting()\"\n [position]=\"position()\"\n [visibleToasts]=\"visibleToasts()\"\n [duration]=\"duration()\"\n (heightAdded)=\"onHeightAdded($event)\"\n (heightRemoved)=\"onHeightRemoved($event)\"\n (dismissed)=\"onDismissed($event)\" />\n}\n",
700
+ styles: ["@charset \"UTF-8\";@layer rt-kit.components{.rt-toaster{--width: 356px;--toaster-offset: 32px;--rt-toaster-z-index: var(--rt-z-sticky);position:fixed;z-index:var(--rt-toaster-z-index);width:var(--width);box-sizing:border-box;padding:0;margin:0;outline:none}.rt-toaster--x--right{right:max(var(--toaster-offset),env(safe-area-inset-right))}.rt-toaster--x--left{left:max(var(--toaster-offset),env(safe-area-inset-left))}.rt-toaster--x--center{left:50%;transform:translate(-50%)}.rt-toaster--y--top{top:max(var(--toaster-offset),env(safe-area-inset-top))}.rt-toaster--y--bottom{bottom:max(var(--toaster-offset),env(safe-area-inset-bottom))}@media(width<=480px){.rt-toaster{--toaster-offset: 16px;right:var(--toaster-offset);left:var(--toaster-offset);width:auto}.rt-toaster--x--center{transform:none}}}\n"]
701
+ }]
702
+ }],
703
+ ctorParameters: () => [],
704
+ propDecorators: {
705
+ position: [{
706
+ type: i0.Input,
707
+ args: [{
708
+ isSignal: true,
709
+ alias: "position",
710
+ required: false
711
+ }]
712
+ }],
713
+ duration: [{
714
+ type: i0.Input,
715
+ args: [{
716
+ isSignal: true,
717
+ alias: "duration",
718
+ required: false
719
+ }]
720
+ }],
721
+ visibleToasts: [{
722
+ type: i0.Input,
723
+ args: [{
724
+ isSignal: true,
725
+ alias: "visibleToasts",
726
+ required: false
727
+ }]
728
+ }],
729
+ mode: [{
730
+ type: i0.Input,
731
+ args: [{
732
+ isSignal: true,
733
+ alias: "mode",
734
+ required: false
735
+ }]
736
+ }],
737
+ expand: [{
738
+ type: i0.Input,
739
+ args: [{
740
+ isSignal: true,
741
+ alias: "expand",
742
+ required: false
743
+ }]
744
+ }],
745
+ hostModifierClasses: [{
746
+ type: HostBinding,
747
+ args: ["class"]
748
+ }],
749
+ hostStackStyles: [{
750
+ type: HostBinding,
751
+ args: ["style"]
752
+ }]
753
+ }
754
+ });
342
755
  export { RT_TOASTER_GAP_PX, RT_TOAST_SEVERITY_ICONS, RtToastComponent, RtToasterComponent };
343
- //# sourceMappingURL=rt-tools-ui-kit-v2-toast.mjs.map
756
+
757
+ //# sourceMappingURL=rt-tools-ui-kit-v2-toast.mjs.map