@cloudflare/realtimekit-ui 1.1.0-staging.4 → 1.1.0-staging.6

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 (376) hide show
  1. package/dist/browser.js +1 -1
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/realtimekit-ui.cjs.js +1 -1
  4. package/dist/cjs/rtk-ai-transcriptions.cjs.entry.js +1 -1
  5. package/dist/cjs/rtk-audio-grid.cjs.entry.js +1 -1
  6. package/dist/cjs/rtk-audio-visualizer_4.cjs.entry.js +1 -1
  7. package/dist/cjs/rtk-avatar_24.cjs.entry.js +255 -232
  8. package/dist/cjs/rtk-breakout-room-manager_3.cjs.entry.js +4 -4
  9. package/dist/cjs/rtk-breakout-rooms-manager_9.cjs.entry.js +8 -8
  10. package/dist/cjs/rtk-channel-creator.cjs.entry.js +2 -2
  11. package/dist/cjs/rtk-channel-details.cjs.entry.js +1 -1
  12. package/dist/cjs/rtk-channel-selector-ui.cjs.entry.js +2 -2
  13. package/dist/cjs/rtk-chat-message.cjs.entry.js +2 -2
  14. package/dist/cjs/rtk-chat-messages-ui.cjs.entry.js +3 -3
  15. package/dist/cjs/rtk-chat-search-results.cjs.entry.js +1 -1
  16. package/dist/cjs/rtk-chat-toggle.cjs.entry.js +27 -22
  17. package/dist/cjs/rtk-clock.cjs.entry.js +3 -3
  18. package/dist/cjs/rtk-controlbar.cjs.entry.js +1 -1
  19. package/dist/cjs/rtk-debugger-toggle.cjs.entry.js +1 -1
  20. package/dist/cjs/rtk-file-dropzone.cjs.entry.js +1 -1
  21. package/dist/cjs/rtk-file-message_3.cjs.entry.js +8 -8
  22. package/dist/cjs/rtk-header.cjs.entry.js +1 -1
  23. package/dist/cjs/rtk-idle-screen.cjs.entry.js +1 -1
  24. package/dist/cjs/rtk-image-viewer.cjs.entry.js +1 -1
  25. package/dist/cjs/rtk-information-tooltip.cjs.entry.js +1 -1
  26. package/dist/cjs/rtk-leave-button.cjs.entry.js +1 -1
  27. package/dist/cjs/rtk-message-list-view.cjs.entry.js +3 -3
  28. package/dist/cjs/rtk-more-toggle.cjs.entry.js +2 -2
  29. package/dist/cjs/rtk-notification.cjs.entry.js +2 -2
  30. package/dist/cjs/rtk-participant-setup.cjs.entry.js +2 -2
  31. package/dist/cjs/rtk-participant_2.cjs.entry.js +14 -14
  32. package/dist/cjs/rtk-participants-audio.cjs.entry.js +1 -1
  33. package/dist/cjs/rtk-participants-stage-list_4.cjs.entry.js +1 -1
  34. package/dist/cjs/rtk-plugins_2.cjs.entry.js +4 -4
  35. package/dist/cjs/rtk-poll_2.cjs.entry.js +3 -3
  36. package/dist/cjs/rtk-recording-indicator.cjs.entry.js +1 -1
  37. package/dist/cjs/rtk-screenshare-view.cjs.entry.js +5 -5
  38. package/dist/cjs/rtk-settings-toggle.cjs.entry.js +1 -1
  39. package/dist/cjs/rtk-spotlight-grid.cjs.entry.js +2 -2
  40. package/dist/cjs/rtk-stage.cjs.entry.js +1 -1
  41. package/dist/cjs/rtk-transcript.cjs.entry.js +1 -1
  42. package/dist/cjs/rtk-waiting-screen.cjs.entry.js +1 -1
  43. package/dist/collection/components/rtk-ai-transcriptions/rtk-ai-transcriptions.js +1 -1
  44. package/dist/collection/components/rtk-audio-grid/rtk-audio-grid.js +1 -1
  45. package/dist/collection/components/rtk-breakout-room-participants/rtk-breakout-room-participants.js +2 -2
  46. package/dist/collection/components/rtk-broadcast-message-modal/rtk-broadcast-message-modal.js +2 -2
  47. package/dist/collection/components/rtk-channel-creator/rtk-channel-creator.js +2 -2
  48. package/dist/collection/components/rtk-channel-details/rtk-channel-details.js +1 -1
  49. package/dist/collection/components/rtk-channel-selector-ui/rtk-channel-selector-ui.js +2 -2
  50. package/dist/collection/components/rtk-chat-message/rtk-chat-message.js +2 -2
  51. package/dist/collection/components/rtk-chat-messages-ui/rtk-chat-messages-ui.js +3 -3
  52. package/dist/collection/components/rtk-chat-messages-ui-paginated/rtk-chat-messages-ui-paginated.js +1 -1
  53. package/dist/collection/components/rtk-chat-search-results/rtk-chat-search-results.js +1 -1
  54. package/dist/collection/components/rtk-chat-toggle/rtk-chat-toggle.css +1 -1
  55. package/dist/collection/components/rtk-chat-toggle/rtk-chat-toggle.js +27 -26
  56. package/dist/collection/components/rtk-clock/rtk-clock.js +3 -3
  57. package/dist/collection/components/rtk-confirmation-modal/rtk-confirmation-modal.js +1 -1
  58. package/dist/collection/components/rtk-controlbar/rtk-controlbar.js +1 -1
  59. package/dist/collection/components/rtk-counter/rtk-counter.js +2 -2
  60. package/dist/collection/components/rtk-debugger-toggle/rtk-debugger-toggle.js +1 -1
  61. package/dist/collection/components/rtk-draft-attachment-view/rtk-draft-attachment-view.js +1 -1
  62. package/dist/collection/components/rtk-emoji-picker/rtk-emoji-picker.js +1 -1
  63. package/dist/collection/components/rtk-emoji-picker-button/rtk-emoji-picker-button.js +1 -1
  64. package/dist/collection/components/rtk-file-dropzone/rtk-file-dropzone.js +1 -1
  65. package/dist/collection/components/rtk-file-message/rtk-file-message.js +2 -2
  66. package/dist/collection/components/rtk-file-message-view/rtk-file-message-view.js +1 -1
  67. package/dist/collection/components/rtk-file-picker-button/rtk-file-picker-button.js +1 -1
  68. package/dist/collection/components/rtk-header/rtk-header.js +1 -1
  69. package/dist/collection/components/rtk-idle-screen/rtk-idle-screen.js +1 -1
  70. package/dist/collection/components/rtk-image-message/rtk-image-message.js +4 -4
  71. package/dist/collection/components/rtk-image-message-view/rtk-image-message-view.js +3 -3
  72. package/dist/collection/components/rtk-image-viewer/rtk-image-viewer.js +1 -1
  73. package/dist/collection/components/rtk-information-tooltip/rtk-information-tooltip.js +1 -1
  74. package/dist/collection/components/rtk-leave-button/rtk-leave-button.js +1 -1
  75. package/dist/collection/components/rtk-leave-meeting/rtk-leave-meeting.js +2 -2
  76. package/dist/collection/components/rtk-markdown-view/rtk-markdown-view.js +1 -1
  77. package/dist/collection/components/rtk-menu/rtk-menu.js +2 -2
  78. package/dist/collection/components/rtk-menu-item/rtk-menu-item.js +1 -1
  79. package/dist/collection/components/rtk-menu-list/rtk-menu-list.js +1 -1
  80. package/dist/collection/components/rtk-message-list-view/rtk-message-list-view.js +3 -3
  81. package/dist/collection/components/rtk-more-toggle/rtk-more-toggle.js +2 -2
  82. package/dist/collection/components/rtk-mute-all-confirmation/rtk-mute-all-confirmation.js +1 -1
  83. package/dist/collection/components/rtk-notification/rtk-notification.js +2 -2
  84. package/dist/collection/components/rtk-overlay-modal/rtk-overlay-modal.js +1 -1
  85. package/dist/collection/components/rtk-paginated-list/rtk-paginated-list.css +5 -5
  86. package/dist/collection/components/rtk-paginated-list/rtk-paginated-list.js +285 -256
  87. package/dist/collection/components/rtk-participant/rtk-participant.js +12 -12
  88. package/dist/collection/components/rtk-participant-setup/rtk-participant-setup.js +2 -2
  89. package/dist/collection/components/rtk-participants-audio/rtk-participants-audio.js +1 -1
  90. package/dist/collection/components/rtk-participants-stage-list/rtk-participants-stage-list.js +1 -1
  91. package/dist/collection/components/rtk-permissions-message/rtk-permissions-message.js +1 -1
  92. package/dist/collection/components/rtk-plugins/rtk-plugins.js +1 -1
  93. package/dist/collection/components/rtk-poll/rtk-poll.js +1 -1
  94. package/dist/collection/components/rtk-poll-form/rtk-poll-form.js +2 -2
  95. package/dist/collection/components/rtk-polls/rtk-polls.js +3 -3
  96. package/dist/collection/components/rtk-recording-indicator/rtk-recording-indicator.js +1 -1
  97. package/dist/collection/components/rtk-screenshare-view/rtk-screenshare-view.js +5 -5
  98. package/dist/collection/components/rtk-settings-toggle/rtk-settings-toggle.js +1 -1
  99. package/dist/collection/components/rtk-spinner/rtk-spinner.js +1 -1
  100. package/dist/collection/components/rtk-spotlight-grid/rtk-spotlight-grid.js +2 -2
  101. package/dist/collection/components/rtk-stage/rtk-stage.js +1 -1
  102. package/dist/collection/components/rtk-switch/rtk-switch.js +1 -1
  103. package/dist/collection/components/rtk-text-composer-view/rtk-text-composer-view.js +1 -1
  104. package/dist/collection/components/rtk-text-message/rtk-text-message.js +2 -2
  105. package/dist/collection/components/rtk-text-message-view/rtk-text-message-view.js +1 -1
  106. package/dist/collection/components/rtk-tooltip/rtk-tooltip.js +1 -1
  107. package/dist/collection/components/rtk-transcript/rtk-transcript.js +1 -1
  108. package/dist/collection/components/rtk-virtualized-list/rtk-virtualized-participant-list.js +2 -2
  109. package/dist/collection/components/rtk-waiting-screen/rtk-waiting-screen.js +1 -1
  110. package/dist/components/{p-8479343e.js → p-00bb4abb.js} +6 -6
  111. package/dist/components/{p-12ae623e.js → p-02b840f8.js} +3 -3
  112. package/dist/components/{p-20290ade.js → p-0b2b3442.js} +2 -2
  113. package/dist/components/{p-b74221b4.js → p-0e5cc539.js} +2 -2
  114. package/dist/components/{p-7b344a65.js → p-0f2de0f8.js} +5 -5
  115. package/dist/components/{p-b30f3c49.js → p-107e55c1.js} +1 -1
  116. package/dist/components/{p-7965a1a6.js → p-1a9e3806.js} +1 -1
  117. package/dist/components/{p-e31889d3.js → p-1f5a4682.js} +2 -2
  118. package/dist/components/{p-b9b8697d.js → p-2309fb19.js} +2 -2
  119. package/dist/components/{p-95e51bef.js → p-241a8245.js} +1 -1
  120. package/dist/components/{p-402db72e.js → p-2447a26f.js} +2 -2
  121. package/dist/components/{p-4a84c913.js → p-28170a8d.js} +9 -9
  122. package/dist/components/{p-86f18b68.js → p-294cda89.js} +3 -3
  123. package/dist/components/{p-cd790a43.js → p-2a65883d.js} +1 -1
  124. package/dist/components/{p-020800ee.js → p-39e8b34a.js} +1 -1
  125. package/dist/components/{p-8f381eef.js → p-3e58e0f3.js} +1 -1
  126. package/dist/components/{p-c8583d9b.js → p-43d6a221.js} +2 -2
  127. package/dist/components/{p-828db489.js → p-45220ce9.js} +2 -2
  128. package/dist/components/{p-011adf66.js → p-46d99dd9.js} +2 -2
  129. package/dist/components/{p-578d73e5.js → p-48acb953.js} +1 -1
  130. package/dist/components/{p-89cfd513.js → p-4902c5cf.js} +1 -1
  131. package/dist/components/{p-40589702.js → p-4aede34c.js} +1 -1
  132. package/dist/components/{p-0e80bae4.js → p-4e5a54c2.js} +10 -10
  133. package/dist/components/{p-5b66b8f3.js → p-4ebf9684.js} +1 -1
  134. package/dist/components/{p-28d51137.js → p-540d8eb9.js} +1 -1
  135. package/dist/components/{p-4bfb4f60.js → p-5476e3f3.js} +2 -2
  136. package/dist/components/{p-40b1fef2.js → p-5669b6e7.js} +4 -4
  137. package/dist/components/{p-9d40e041.js → p-598dc3f2.js} +2 -2
  138. package/dist/components/{p-ea6b5bf5.js → p-616ae7ab.js} +2 -2
  139. package/dist/components/{p-9c3ca56e.js → p-6739a399.js} +2 -2
  140. package/dist/components/{p-597543af.js → p-713c7ed7.js} +3 -3
  141. package/dist/components/{p-966273a8.js → p-7148ec6a.js} +1 -1
  142. package/dist/components/{p-ce77fdfc.js → p-761c0e78.js} +1 -1
  143. package/dist/components/{p-a0a0867a.js → p-7f489600.js} +1 -1
  144. package/dist/components/{p-520dccab.js → p-819cb785.js} +1 -1
  145. package/dist/components/{p-9936031d.js → p-85872241.js} +20 -20
  146. package/dist/components/{p-2e3c0084.js → p-89025409.js} +3 -3
  147. package/dist/components/{p-bed61d79.js → p-8cfdac0d.js} +5 -5
  148. package/dist/components/{p-757856f4.js → p-8d6b21d5.js} +3 -3
  149. package/dist/components/{p-35af8a84.js → p-a25f3aca.js} +2 -2
  150. package/dist/components/{p-5f0f8967.js → p-a51db0d6.js} +16 -16
  151. package/dist/components/{p-c544502e.js → p-a73665b4.js} +4 -4
  152. package/dist/components/{p-b3447e0c.js → p-a8a6496d.js} +1 -1
  153. package/dist/components/{p-5739b5f1.js → p-af3b99f4.js} +2 -2
  154. package/dist/components/{p-53332481.js → p-b6781e91.js} +12 -12
  155. package/dist/components/{p-11a16ac3.js → p-bb4983b8.js} +2 -2
  156. package/dist/components/{p-3a1dbc0d.js → p-c334f0e5.js} +2 -2
  157. package/dist/components/{p-d2ce1170.js → p-cf8f725b.js} +1 -1
  158. package/dist/components/{p-157c1dc9.js → p-d765dbe4.js} +6 -6
  159. package/dist/components/{p-2eb35b99.js → p-da9018ea.js} +6 -6
  160. package/dist/components/{p-0ca31fce.js → p-dc3143c0.js} +2 -2
  161. package/dist/components/{p-ab842e10.js → p-e0510925.js} +1 -1
  162. package/dist/components/p-e7e2156a.js +375 -0
  163. package/dist/components/{p-09d1805e.js → p-eeb37b16.js} +1 -1
  164. package/dist/components/{p-d3588666.js → p-fa476519.js} +5 -5
  165. package/dist/components/{p-85990be7.js → p-fb836f65.js} +1 -1
  166. package/dist/components/{p-668f57d0.js → p-fb900e8f.js} +2 -2
  167. package/dist/components/rtk-ai-toggle.js +2 -2
  168. package/dist/components/rtk-ai-transcriptions.js +1 -1
  169. package/dist/components/rtk-ai.js +1 -1
  170. package/dist/components/rtk-audio-grid.js +1 -1
  171. package/dist/components/rtk-audio-tile.js +2 -2
  172. package/dist/components/rtk-avatar.js +1 -1
  173. package/dist/components/rtk-breakout-room-manager.js +1 -1
  174. package/dist/components/rtk-breakout-room-participants.js +1 -1
  175. package/dist/components/rtk-breakout-rooms-manager.js +1 -1
  176. package/dist/components/rtk-breakout-rooms-toggle.js +2 -2
  177. package/dist/components/rtk-broadcast-message-modal.js +1 -1
  178. package/dist/components/rtk-camera-toggle.js +3 -3
  179. package/dist/components/rtk-caption-toggle.js +2 -2
  180. package/dist/components/rtk-channel-creator.js +4 -4
  181. package/dist/components/rtk-channel-details.js +1 -1
  182. package/dist/components/rtk-channel-header.js +4 -4
  183. package/dist/components/rtk-channel-selector-ui.js +4 -4
  184. package/dist/components/rtk-channel-selector-view.js +1 -1
  185. package/dist/components/rtk-chat-composer-ui.js +4 -4
  186. package/dist/components/rtk-chat-composer-view.js +1 -1
  187. package/dist/components/rtk-chat-message.js +1 -1
  188. package/dist/components/rtk-chat-messages-ui-paginated.js +1 -1
  189. package/dist/components/rtk-chat-messages-ui.js +14 -14
  190. package/dist/components/rtk-chat-search-results.js +11 -11
  191. package/dist/components/rtk-chat-toggle.js +30 -26
  192. package/dist/components/rtk-chat.js +1 -1
  193. package/dist/components/rtk-clock.js +3 -3
  194. package/dist/components/rtk-confirmation-modal.js +1 -1
  195. package/dist/components/rtk-controlbar-button.js +1 -1
  196. package/dist/components/rtk-controlbar.js +1 -1
  197. package/dist/components/rtk-counter.js +1 -1
  198. package/dist/components/rtk-debugger-toggle.js +3 -3
  199. package/dist/components/rtk-dialog-manager.js +13 -13
  200. package/dist/components/rtk-draft-attachment-view.js +1 -1
  201. package/dist/components/rtk-emoji-picker-button.js +1 -1
  202. package/dist/components/rtk-emoji-picker.js +1 -1
  203. package/dist/components/rtk-file-dropzone.js +1 -1
  204. package/dist/components/rtk-file-message-view.js +1 -1
  205. package/dist/components/rtk-file-message.js +1 -1
  206. package/dist/components/rtk-file-picker-button.js +1 -1
  207. package/dist/components/rtk-fullscreen-toggle.js +1 -1
  208. package/dist/components/rtk-grid-pagination.js +1 -1
  209. package/dist/components/rtk-grid.js +4 -4
  210. package/dist/components/rtk-header.js +1 -1
  211. package/dist/components/rtk-idle-screen.js +2 -2
  212. package/dist/components/rtk-image-message-view.js +1 -1
  213. package/dist/components/rtk-image-message.js +1 -1
  214. package/dist/components/rtk-image-viewer.js +1 -1
  215. package/dist/components/rtk-information-tooltip.js +1 -1
  216. package/dist/components/rtk-leave-button.js +3 -3
  217. package/dist/components/rtk-leave-meeting.js +1 -1
  218. package/dist/components/rtk-livestream-player.js +1 -1
  219. package/dist/components/rtk-livestream-toggle.js +2 -2
  220. package/dist/components/rtk-markdown-view.js +1 -1
  221. package/dist/components/rtk-meeting-title.js +1 -1
  222. package/dist/components/rtk-meeting.js +21 -21
  223. package/dist/components/rtk-menu-item.js +1 -1
  224. package/dist/components/rtk-menu-list.js +1 -1
  225. package/dist/components/rtk-menu.js +1 -1
  226. package/dist/components/rtk-message-list-view.js +4 -4
  227. package/dist/components/rtk-message-view.js +1 -1
  228. package/dist/components/rtk-mic-toggle.js +3 -3
  229. package/dist/components/rtk-mixed-grid.js +3 -3
  230. package/dist/components/rtk-more-toggle.js +4 -4
  231. package/dist/components/rtk-mute-all-button.js +3 -3
  232. package/dist/components/rtk-mute-all-confirmation.js +1 -1
  233. package/dist/components/rtk-notification.js +1 -1
  234. package/dist/components/rtk-notifications.js +1 -1
  235. package/dist/components/rtk-overlay-modal.js +1 -1
  236. package/dist/components/rtk-paginated-list.js +1 -1
  237. package/dist/components/rtk-participant-setup.js +2 -2
  238. package/dist/components/rtk-participant.js +1 -1
  239. package/dist/components/rtk-participants-audio.js +1 -1
  240. package/dist/components/rtk-participants-stage-list.js +1 -1
  241. package/dist/components/rtk-participants-stage-queue.js +1 -1
  242. package/dist/components/rtk-participants-toggle.js +2 -2
  243. package/dist/components/rtk-participants-viewer-list.js +1 -1
  244. package/dist/components/rtk-participants-waiting-list.js +1 -1
  245. package/dist/components/rtk-participants.js +11 -11
  246. package/dist/components/rtk-permissions-message.js +1 -1
  247. package/dist/components/rtk-pip-toggle.js +2 -2
  248. package/dist/components/rtk-plugins-toggle.js +2 -2
  249. package/dist/components/rtk-plugins.js +1 -1
  250. package/dist/components/rtk-poll-form.js +1 -1
  251. package/dist/components/rtk-poll.js +1 -1
  252. package/dist/components/rtk-polls-toggle.js +2 -2
  253. package/dist/components/rtk-polls.js +1 -1
  254. package/dist/components/rtk-recording-indicator.js +1 -1
  255. package/dist/components/rtk-recording-toggle.js +2 -2
  256. package/dist/components/rtk-screen-share-toggle.js +3 -3
  257. package/dist/components/rtk-screenshare-view.js +6 -6
  258. package/dist/components/rtk-settings-audio.js +1 -1
  259. package/dist/components/rtk-settings-toggle.js +3 -3
  260. package/dist/components/rtk-settings-video.js +1 -1
  261. package/dist/components/rtk-settings.js +3 -3
  262. package/dist/components/rtk-setup-screen.js +1 -1
  263. package/dist/components/rtk-sidebar.js +5 -5
  264. package/dist/components/rtk-spinner.js +1 -1
  265. package/dist/components/rtk-spotlight-grid.js +2 -2
  266. package/dist/components/rtk-spotlight-indicator.js +1 -1
  267. package/dist/components/rtk-stage-toggle.js +3 -3
  268. package/dist/components/rtk-stage.js +1 -1
  269. package/dist/components/rtk-switch.js +1 -1
  270. package/dist/components/rtk-tab-bar.js +1 -1
  271. package/dist/components/rtk-text-composer-view.js +1 -1
  272. package/dist/components/rtk-text-message-view.js +1 -1
  273. package/dist/components/rtk-text-message.js +1 -1
  274. package/dist/components/rtk-tooltip.js +1 -1
  275. package/dist/components/rtk-transcript.js +1 -1
  276. package/dist/components/rtk-transcripts.js +1 -1
  277. package/dist/components/rtk-virtualized-participant-list.js +1 -1
  278. package/dist/components/rtk-waiting-screen.js +1 -1
  279. package/dist/docs/docs-components.json +44 -33
  280. package/dist/esm/loader.js +383 -354
  281. package/dist/esm/realtimekit-ui.js +1 -1
  282. package/dist/esm/rtk-ai-transcriptions.entry.js +1 -1
  283. package/dist/esm/rtk-audio-grid.entry.js +1 -1
  284. package/dist/esm/rtk-audio-visualizer_4.entry.js +1 -1
  285. package/dist/esm/rtk-avatar_24.entry.js +255 -232
  286. package/dist/esm/rtk-breakout-room-manager_3.entry.js +4 -4
  287. package/dist/esm/rtk-breakout-rooms-manager_9.entry.js +8 -8
  288. package/dist/esm/rtk-channel-creator.entry.js +2 -2
  289. package/dist/esm/rtk-channel-details.entry.js +1 -1
  290. package/dist/esm/rtk-channel-selector-ui.entry.js +2 -2
  291. package/dist/esm/rtk-chat-message.entry.js +2 -2
  292. package/dist/esm/rtk-chat-messages-ui.entry.js +3 -3
  293. package/dist/esm/rtk-chat-search-results.entry.js +1 -1
  294. package/dist/esm/rtk-chat-toggle.entry.js +27 -22
  295. package/dist/esm/rtk-clock.entry.js +3 -3
  296. package/dist/esm/rtk-controlbar.entry.js +1 -1
  297. package/dist/esm/rtk-debugger-toggle.entry.js +1 -1
  298. package/dist/esm/rtk-file-dropzone.entry.js +1 -1
  299. package/dist/esm/rtk-file-message_3.entry.js +8 -8
  300. package/dist/esm/rtk-header.entry.js +1 -1
  301. package/dist/esm/rtk-idle-screen.entry.js +1 -1
  302. package/dist/esm/rtk-image-viewer.entry.js +1 -1
  303. package/dist/esm/rtk-information-tooltip.entry.js +1 -1
  304. package/dist/esm/rtk-leave-button.entry.js +1 -1
  305. package/dist/esm/rtk-message-list-view.entry.js +3 -3
  306. package/dist/esm/rtk-more-toggle.entry.js +2 -2
  307. package/dist/esm/rtk-notification.entry.js +2 -2
  308. package/dist/esm/rtk-participant-setup.entry.js +2 -2
  309. package/dist/esm/rtk-participant_2.entry.js +14 -14
  310. package/dist/esm/rtk-participants-audio.entry.js +1 -1
  311. package/dist/esm/rtk-participants-stage-list_4.entry.js +1 -1
  312. package/dist/esm/rtk-plugins_2.entry.js +4 -4
  313. package/dist/esm/rtk-poll_2.entry.js +3 -3
  314. package/dist/esm/rtk-recording-indicator.entry.js +1 -1
  315. package/dist/esm/rtk-screenshare-view.entry.js +5 -5
  316. package/dist/esm/rtk-settings-toggle.entry.js +1 -1
  317. package/dist/esm/rtk-spotlight-grid.entry.js +2 -2
  318. package/dist/esm/rtk-stage.entry.js +1 -1
  319. package/dist/esm/rtk-transcript.entry.js +1 -1
  320. package/dist/esm/rtk-waiting-screen.entry.js +1 -1
  321. package/dist/realtimekit-ui/{p-7660a4c1.entry.js → p-00445029.entry.js} +1 -1
  322. package/dist/realtimekit-ui/{p-bb369808.entry.js → p-02c6b025.entry.js} +1 -1
  323. package/dist/realtimekit-ui/{p-0fed7daa.entry.js → p-0baa78d7.entry.js} +1 -1
  324. package/dist/realtimekit-ui/p-19587963.entry.js +1 -0
  325. package/dist/realtimekit-ui/{p-0e2d6b1b.entry.js → p-1fe6003b.entry.js} +1 -1
  326. package/dist/realtimekit-ui/p-21d4bb9c.entry.js +1 -0
  327. package/dist/realtimekit-ui/{p-87f3b9a6.entry.js → p-2441260e.entry.js} +1 -1
  328. package/dist/realtimekit-ui/{p-4822dc9f.entry.js → p-322957ed.entry.js} +1 -1
  329. package/dist/realtimekit-ui/{p-f42c50db.entry.js → p-323d1aa4.entry.js} +1 -1
  330. package/dist/realtimekit-ui/p-421e4c6f.entry.js +1 -0
  331. package/dist/realtimekit-ui/{p-39410e81.entry.js → p-44d69c6b.entry.js} +1 -1
  332. package/dist/realtimekit-ui/p-48c87789.entry.js +1 -0
  333. package/dist/realtimekit-ui/{p-cea6c6ac.entry.js → p-53680d55.entry.js} +1 -1
  334. package/dist/realtimekit-ui/p-54a88fdf.entry.js +1 -0
  335. package/dist/realtimekit-ui/{p-9cab7a57.entry.js → p-5892c1e0.entry.js} +1 -1
  336. package/dist/realtimekit-ui/{p-73f489be.entry.js → p-612a8d25.entry.js} +1 -1
  337. package/dist/realtimekit-ui/p-64206b62.entry.js +1 -0
  338. package/dist/realtimekit-ui/{p-a62e84f9.entry.js → p-67ead213.entry.js} +1 -1
  339. package/dist/realtimekit-ui/{p-f2ce302b.entry.js → p-6896e819.entry.js} +1 -1
  340. package/dist/realtimekit-ui/{p-fea05f1c.entry.js → p-7a9a226e.entry.js} +1 -1
  341. package/dist/realtimekit-ui/{p-9cad5a6d.entry.js → p-80e51a73.entry.js} +1 -1
  342. package/dist/realtimekit-ui/p-820dad23.entry.js +1 -0
  343. package/dist/realtimekit-ui/{p-61d3e2d4.entry.js → p-85b3c0c4.entry.js} +1 -1
  344. package/dist/realtimekit-ui/{p-0c071f00.entry.js → p-8778b3e6.entry.js} +1 -1
  345. package/dist/realtimekit-ui/p-a1408db4.entry.js +1 -0
  346. package/dist/realtimekit-ui/{p-c50f4cab.entry.js → p-a67e2a25.entry.js} +1 -1
  347. package/dist/realtimekit-ui/{p-3e12d77a.entry.js → p-a680da64.entry.js} +1 -1
  348. package/dist/realtimekit-ui/{p-bd226f59.entry.js → p-a7172c2d.entry.js} +1 -1
  349. package/dist/realtimekit-ui/{p-cda80e2c.entry.js → p-a852e0cf.entry.js} +1 -1
  350. package/dist/realtimekit-ui/{p-9dcd9e30.entry.js → p-ac6c8ebe.entry.js} +1 -1
  351. package/dist/realtimekit-ui/{p-1dfe0269.entry.js → p-b25f7d7b.entry.js} +1 -1
  352. package/dist/realtimekit-ui/{p-2c71cc53.entry.js → p-b51e813e.entry.js} +1 -1
  353. package/dist/realtimekit-ui/{p-dded6ad0.entry.js → p-be5bdd0a.entry.js} +1 -1
  354. package/dist/realtimekit-ui/p-c5f704a3.entry.js +1 -0
  355. package/dist/realtimekit-ui/{p-d7a78f65.entry.js → p-cc226b51.entry.js} +1 -1
  356. package/dist/realtimekit-ui/{p-a25bb0ad.entry.js → p-cda276d6.entry.js} +1 -1
  357. package/dist/realtimekit-ui/p-d880fb69.entry.js +1 -0
  358. package/dist/realtimekit-ui/{p-a867b984.entry.js → p-f6c82f1b.entry.js} +1 -1
  359. package/dist/realtimekit-ui/p-fa86682c.entry.js +1 -0
  360. package/dist/realtimekit-ui/realtimekit-ui.esm.js +1 -1
  361. package/dist/types/components/rtk-chat-toggle/rtk-chat-toggle.d.ts +4 -6
  362. package/dist/types/components/rtk-paginated-list/rtk-paginated-list.d.ts +68 -53
  363. package/dist/types/components.d.ts +9 -5
  364. package/package.json +1 -1
  365. package/dist/components/p-78f91ffe.js +0 -357
  366. package/dist/realtimekit-ui/p-02889d02.entry.js +0 -1
  367. package/dist/realtimekit-ui/p-09fb29e7.entry.js +0 -1
  368. package/dist/realtimekit-ui/p-260fc2ed.entry.js +0 -1
  369. package/dist/realtimekit-ui/p-32211408.entry.js +0 -1
  370. package/dist/realtimekit-ui/p-48c76360.entry.js +0 -1
  371. package/dist/realtimekit-ui/p-4d31d165.entry.js +0 -1
  372. package/dist/realtimekit-ui/p-51c72bc8.entry.js +0 -1
  373. package/dist/realtimekit-ui/p-b58dc07c.entry.js +0 -1
  374. package/dist/realtimekit-ui/p-c96e2a96.entry.js +0 -1
  375. package/dist/realtimekit-ui/p-d194317d.entry.js +0 -1
  376. package/dist/realtimekit-ui/p-ff9bc5b0.entry.js +0 -1
@@ -15,7 +15,6 @@ const config = require('./config-0a88d50b.js');
15
15
  const ResizeObserver_es = require('./ResizeObserver.es-ba961f16.js');
16
16
  const floatingUi_dom_esm = require('./floating-ui.dom.esm-705e65f3.js');
17
17
  const date = require('./date-61ffcd0a.js');
18
- const scroll = require('./scroll-c6404609.js');
19
18
 
20
19
  const rtkAvatarCss = ":host{line-height:initial;font-family:var(--rtk-font-family, sans-serif);font-feature-settings:normal;font-variation-settings:normal}p{margin:var(--rtk-space-0, 0px);padding:var(--rtk-space-0, 0px)}:host{display:flex;height:var(--rtk-space-32, 128px);width:var(--rtk-space-32, 128px);align-items:center;justify-content:center;font-size:28px;--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-brand-500, 33 96 253) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-on-brand-1000, var(--rtk-colors-text-1000, 255 255 255)));overflow:clip;border-radius:9999px;-webkit-user-select:none;-moz-user-select:none;user-select:none}rtk-icon{height:50%;width:50%}.image-ctr{display:flex;height:100%;width:100%;align-items:center;justify-content:center;--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-700, 44 44 44) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-600, 255 255 255 / 0.52))}img{height:var(--rtk-space-0, 0px);width:var(--rtk-space-0, 0px);-o-object-fit:cover;object-fit:cover}img.loaded{height:100%;width:100%}.initials{display:flex;height:100%;width:100%;align-items:center;justify-content:center;text-transform:uppercase}.image{display:flex;height:100%;width:100%;align-items:center;justify-content:center}.image img{display:none;height:100%;width:100%;-o-object-fit:cover;object-fit:cover}.image img.loaded{display:block}:host([variant='hexagon']){border-radius:var(--rtk-border-radius-none, 0);clip-path:polygon(50% 0, 95% 25%, 95% 75%, 50% 100%, 5% 75%, 5% 25%)}:host([variant='square']){border-radius:var(--rtk-border-radius-none, 0);clip-path:polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%)}:host([size='sm']){height:var(--rtk-space-14, 56px);width:var(--rtk-space-14, 56px);font-size:12px}:host([size='md']){height:var(--rtk-space-28, 112px);width:var(--rtk-space-28, 112px)}:host([size='lg']){height:var(--rtk-space-32, 128px);width:var(--rtk-space-32, 128px)}";
21
20
  const RtkAvatarStyle0 = rtkAvatarCss;
@@ -1097,7 +1096,7 @@ const RtkChatMessagesUiPaginated = class {
1097
1096
  this.lastReadMessageIndex = -1;
1098
1097
  }
1099
1098
  render() {
1100
- return (index$1.h(index$1.Host, { key: 'dbe69aec6f462c8cfa5d6574ad77efdbadd641b9' }, index$1.h("rtk-paginated-list", { key: 'b6b525ad58e8173a78577265f2cde2981ca015cf', ref: (el) => (this.$paginatedListRef = el), pageSize: this.pageSize, pagesAllowed: 3, fetchData: this.getChatMessages, createNodes: this.createChatNodes, selectedItemId: this.selectedChannelId, emptyListLabel: this.t('chat.empty_channel') }, index$1.h("slot", { key: '4045a3fccefe09d76edff35b5d0183a89db51491' }))));
1099
+ return (index$1.h(index$1.Host, { key: '012b7189dfbdccfd8017cc9023263e6a7e9afd44' }, index$1.h("rtk-paginated-list", { key: '0ea37ee880fda0acdd7460b6da5f03e11ac304bf', ref: (el) => (this.$paginatedListRef = el), pageSize: this.pageSize, pagesAllowed: 3, fetchData: this.getChatMessages, createNodes: this.createChatNodes, selectedItemId: this.selectedChannelId, emptyListLabel: this.t('chat.empty_channel') }, index$1.h("slot", { key: '53cb197b6d9319f470e87fe73d7ca0d158778e3f' }))));
1101
1100
  }
1102
1101
  get host() { return index$1.getElement(this); }
1103
1102
  static get watchers() { return {
@@ -1170,7 +1169,7 @@ const RtkDraftAttachmentView = class {
1170
1169
  this.onAttachmentChange();
1171
1170
  }
1172
1171
  render() {
1173
- return (index$1.h(index$1.Host, { key: '4ccd7a73401d3931dadc59779ec4edfddef219f1' }, index$1.h("div", { key: 'a75fa81f358436f6ac349a56b8a62671a25f38d7', class: "preview-overlay" }, index$1.h("div", { key: 'b95e371e0108cf613305f74c204ebb8fec26140d', class: "preview" }, index$1.h("rtk-tooltip", { key: '9c43de18dbdcff2d5cd6fdd344a13cd0d1e7c2f8', label: this.t('chat.cancel_upload') }, index$1.h("rtk-button", { key: 'e99f168f015abc65b33876e44d3a2d80f6fa6169', variant: "secondary", kind: "icon", onClick: this.onDeleteClickHandler }, index$1.h("rtk-icon", { key: '53f0ffd566825e8cb3d7a7b69c93a62c63206505', icon: this.iconPack.dismiss }))), this.attachment.type === 'image' ? (index$1.h("img", { class: "preview-image", src: this.filePreview })) : (index$1.h("div", { class: "preview-file" }, index$1.h("span", null, this.filePreview)))))));
1172
+ return (index$1.h(index$1.Host, { key: 'f6ede093bcdf8100807baab4de2a296fc4960a07' }, index$1.h("div", { key: 'b19bbe9b2ea58ea4adccc2028a1b24ea6bc9f0a9', class: "preview-overlay" }, index$1.h("div", { key: 'cbb2bfcb3a50e6e7fbfd4109eb340ba51d6a162d', class: "preview" }, index$1.h("rtk-tooltip", { key: '15b50c547470b0fa22014e0992a1c7e26b234573', label: this.t('chat.cancel_upload') }, index$1.h("rtk-button", { key: '940332a51747af3368ffec497d5ef76fa64ecf75', variant: "secondary", kind: "icon", onClick: this.onDeleteClickHandler }, index$1.h("rtk-icon", { key: 'cc04b0ac70753e970ff638f187ad5f702dc3656b', icon: this.iconPack.dismiss }))), this.attachment.type === 'image' ? (index$1.h("img", { class: "preview-image", src: this.filePreview })) : (index$1.h("div", { class: "preview-file" }, index$1.h("span", null, this.filePreview)))))));
1174
1173
  }
1175
1174
  static get watchers() { return {
1176
1175
  "attachment": ["onAttachmentChange"]
@@ -1255,7 +1254,7 @@ const RtkEmojiPicker = class {
1255
1254
  return (index$1.h("div", { id: "emoji-grid", class: "scrollbar max-w-40" }, this.filteredEmojis.map((e) => (index$1.h("rtk-button", { key: `emoji-button-${e.name}`, class: "emoji", variant: "ghost", kind: "icon", title: e.name, onClick: () => this.handleEmojiClick(e.emoji) }, e.emoji)))));
1256
1255
  }
1257
1256
  render() {
1258
- return (index$1.h(index$1.Host, { key: 'f448ab61063b55b8e5572fbcb8be3f520b0704ea' }, index$1.h("div", { key: '459b42557c8e7b853410b53e42dd663461b0593a', class: 'close-parent' }, index$1.h("rtk-button", { key: '8b64136b51a96bda767b7fbbc05b51a335d1a7b9', variant: "ghost", kind: "icon", class: "close", onClick: () => { var _a; return (_a = this.pickerClose) === null || _a === void 0 ? void 0 : _a.emit(); }, "aria-label": this.t('close') }, index$1.h("rtk-icon", { key: '82bdc4ea24be656d182c9e420bd86b0b5cbfa589', icon: this.iconPack.dismiss }))), index$1.h("div", { key: '934d08102c4cffda109752eecd5be41854030133', class: 'emoji-parent' }, index$1.h("input", { key: '8c21c91a89d77fce9847ade88663d9ec969491da', value: this.filterVal, onInput: (event) => this.handleInputChange(event.target), placeholder: this.t('search'), ref: (el) => (this.inputElement = el) }), this.mapEmojiList())));
1257
+ return (index$1.h(index$1.Host, { key: '6581d26d75a7b869d0ba00243ec74ee06b927e7d' }, index$1.h("div", { key: '3705d8c557ac3e05769171998e9176e7e40a232c', class: 'close-parent' }, index$1.h("rtk-button", { key: 'b437e579cb828a709de255ddfa6b751e4bdfbe51', variant: "ghost", kind: "icon", class: "close", onClick: () => { var _a; return (_a = this.pickerClose) === null || _a === void 0 ? void 0 : _a.emit(); }, "aria-label": this.t('close') }, index$1.h("rtk-icon", { key: '7fac79a21c6be57156d17ceeff9ceb2834bbf709', icon: this.iconPack.dismiss }))), index$1.h("div", { key: '46cb2af6654ef36b7258baf47e3cd9e5bd60bf89', class: 'emoji-parent' }, index$1.h("input", { key: 'cfde33638d531f9bac1b1bf25d966a369f4dfb38', value: this.filterVal, onInput: (event) => this.handleInputChange(event.target), placeholder: this.t('search'), ref: (el) => (this.inputElement = el) }), this.mapEmojiList())));
1259
1258
  }
1260
1259
  };
1261
1260
  __decorate$b([
@@ -1288,7 +1287,7 @@ const RtkEmojiPickerButton = class {
1288
1287
  this.t = uiStore.useLanguage();
1289
1288
  }
1290
1289
  render() {
1291
- return (index$1.h("rtk-tooltip", { key: '45792cf2e2523dc94b5dd4c861d4006fae8aee56', label: this.t('chat.send_emoji') }, index$1.h("rtk-button", { key: 'd2f80aede59b62d7e0587515f4823bdb5e278c28', variant: "ghost", kind: "icon", class: { active: this.isActive }, title: this.t('chat.send_emoji') }, index$1.h("rtk-icon", { key: '15229de453f1cbf93c8de5c002d6ea33ff54ed3b', icon: this.iconPack.emoji_multiple }))));
1290
+ return (index$1.h("rtk-tooltip", { key: '45ef1f18da6d1ecc3c02882590cd22e930461562', label: this.t('chat.send_emoji') }, index$1.h("rtk-button", { key: '6504abab2f1c6537443699c53a8cbdcf13530cba', variant: "ghost", kind: "icon", class: { active: this.isActive }, title: this.t('chat.send_emoji') }, index$1.h("rtk-icon", { key: 'd730c81abce72d9c3226f1f666941e1136bee77f', icon: this.iconPack.emoji_multiple }))));
1292
1291
  }
1293
1292
  };
1294
1293
  __decorate$a([
@@ -1319,7 +1318,7 @@ const RtkFileMessageView = class {
1319
1318
  this.iconPack = uiStore.defaultIconPack;
1320
1319
  }
1321
1320
  render() {
1322
- return (index$1.h("div", { key: 'f25ec20ac84c7ec0961abbdc58d74b64b3261042', class: "file" }, index$1.h("rtk-button", { key: '9daa2ca8992821456f7dad66550c1f3b0e07e5c2', variant: "secondary", kind: "icon", onClick: () => file.downloadFile(string.sanitizeLink(this.url), { name: this.name, fallbackName: 'file' }), part: "button" }, index$1.h("rtk-icon", { key: 'f4a578a8613eab5a2b91a86870ee02ff2659c4ec', icon: this.iconPack.download })), index$1.h("div", { key: '61d6a100bd716741e15f80404796ad8e5850d2a3', class: "file-data" }, index$1.h("div", { key: 'be8f7fdf168388073e5f094cb717d75766b291df', class: "name" }, this.name), index$1.h("div", { key: 'f1dbb45817084612a31baf71784d713ec85a3b79', class: "file-data-split" }, index$1.h("div", { key: '49ac2abd19ae9fb07da0a4f234c45b932cd41221', class: "ext" }, file.getExtension(this.name)), index$1.h("span", { key: 'fe7e8660a54184ffc3d5cff5a320a1f8929ec3e6', class: "divider" }), index$1.h("div", { key: '402df689a8cf059bd3031c9c036544c486846d40', class: "size" }, file.getFileSize(this.size))))));
1321
+ return (index$1.h("div", { key: '5cc29b4780f581a2f8b045e5051bcc66f3fdaf55', class: "file" }, index$1.h("rtk-button", { key: '4100b47bc1d72f08ec5fe645291bfbb58e3a6486', variant: "secondary", kind: "icon", onClick: () => file.downloadFile(string.sanitizeLink(this.url), { name: this.name, fallbackName: 'file' }), part: "button" }, index$1.h("rtk-icon", { key: '52ae14abb7c27b89861d5ba4c907d606257628c9', icon: this.iconPack.download })), index$1.h("div", { key: '02c9ad8d173172a85cc474273a966607d456360e', class: "file-data" }, index$1.h("div", { key: '6ceca21685d04f175006ba35a6de194cc98879ad', class: "name" }, this.name), index$1.h("div", { key: 'b07d07bcaedee3fd6fbcfe81ce2f6bf757655b5f', class: "file-data-split" }, index$1.h("div", { key: '280635ef486de02bc68ca3e774be14fa5a461d1c', class: "ext" }, file.getExtension(this.name)), index$1.h("span", { key: '84f72d8b37b7d15c257faed036b76c737eec780b', class: "divider" }), index$1.h("div", { key: '1b88f48f51afe3fceb57920c3d17f586e848a25f', class: "size" }, file.getFileSize(this.size))))));
1323
1322
  }
1324
1323
  };
1325
1324
  __decorate$9([
@@ -1375,7 +1374,7 @@ const RtkFilePickerButton = class {
1375
1374
  render() {
1376
1375
  const label = this.label || this.t('chat.send_file');
1377
1376
  const icon = this.iconPack[this.icon];
1378
- return (index$1.h("rtk-tooltip", { key: '03d24cebc847667a6d59e21d22105c48db0c589c', label: label }, index$1.h("rtk-button", { key: 'bddd8cac214d897979c9a38b26643e1027e696e3', variant: "ghost", kind: "icon", onClick: () => this.uploadFile(), title: label }, index$1.h("rtk-icon", { key: '0a9756a9f6c1e8ab0c34ea46b3614816aa257df4', icon: icon }))));
1377
+ return (index$1.h("rtk-tooltip", { key: '057a0a5a714dbbde228e3481e53adea4f88fb3ad', label: label }, index$1.h("rtk-button", { key: '04193df1053b14687fb9464a122b9158707bdda1', variant: "ghost", kind: "icon", onClick: () => this.uploadFile(), title: label }, index$1.h("rtk-icon", { key: 'ed2fce30b93dfce9dd6b967d5993c93496cf3388', icon: icon }))));
1379
1378
  }
1380
1379
  };
1381
1380
  __decorate$8([
@@ -1435,7 +1434,7 @@ const RtkImageMessageView = class {
1435
1434
  this.status = 'loading';
1436
1435
  }
1437
1436
  render() {
1438
- return (index$1.h("div", { key: '99e8a76eea11e740c21642445fb803b3027f95ff', class: { image: true, loaded: this.status === 'loaded' } }, index$1.h("img", { key: '98c0477fab6ae6f86657579d4d4e44dab3af0bf5', src: string.sanitizeLink(this.url), onLoad: () => {
1437
+ return (index$1.h("div", { key: '066606e6ae62634b2466bb46b453e0c2d91b17ea', class: { image: true, loaded: this.status === 'loaded' } }, index$1.h("img", { key: 'f042e5d3c1a6341e9fc0845e6643016f1be5b5f7', src: string.sanitizeLink(this.url), onLoad: () => {
1439
1438
  this.status = 'loaded';
1440
1439
  }, onError: () => {
1441
1440
  this.status = 'errored';
@@ -1443,9 +1442,9 @@ const RtkImageMessageView = class {
1443
1442
  if (this.status === 'loaded') {
1444
1443
  this.onPreview.emit(this.url);
1445
1444
  }
1446
- } }), this.status === 'loading' && (index$1.h("div", { key: '91005900f67fb450d9b1515b8fc493e09f5ccebd', class: "image-spinner", title: this.t('chat.img.loading'), "aria-label": this.t('chat.img.loading') }, index$1.h("rtk-spinner", { key: 'c96f80a0a53426058635254c5efd78cdccd3a23f', iconPack: this.iconPack }))), this.status === 'errored' && (index$1.h("div", { key: 'c1f7a709ccaf0c0ba1104992616f8405e2380c95', class: "image-errored", title: this.t('chat.error.img_not_found'), "aria-label": this.t('chat.error.img_not_found') }, index$1.h("rtk-icon", { key: '27d22b3f706d641b5d77a5fa75ba4233663afb88', icon: this.iconPack.image_off }))), this.status === 'loaded' && (index$1.h("div", { key: '2caf4c258128cf03dae23769c832a3b7bb76be9e', class: "actions" }, index$1.h("rtk-button", { key: 'e668325aa6f1f20a2d4f7d172e483521b709b7c8', class: "action", variant: "secondary", kind: "icon", onClick: () => {
1445
+ } }), this.status === 'loading' && (index$1.h("div", { key: 'd4a5030468fbf70afae62bd55ae4d0fa989e15c2', class: "image-spinner", title: this.t('chat.img.loading'), "aria-label": this.t('chat.img.loading') }, index$1.h("rtk-spinner", { key: '216aba361a46cc100e7d26cc2daf1ffb0948d695', iconPack: this.iconPack }))), this.status === 'errored' && (index$1.h("div", { key: '01f5da8f70872c9fa22dc9a9b70b046b0001d05b', class: "image-errored", title: this.t('chat.error.img_not_found'), "aria-label": this.t('chat.error.img_not_found') }, index$1.h("rtk-icon", { key: '0f7e6fed2730f6366d07fc6afddb2b247e9b7d3a', icon: this.iconPack.image_off }))), this.status === 'loaded' && (index$1.h("div", { key: '5ac0e61c65a88a8d6b9ee54c900b856854d1b84b', class: "actions" }, index$1.h("rtk-button", { key: 'fd83dfecd7b5d9c3976374c3c55731b1f026fc0a', class: "action", variant: "secondary", kind: "icon", onClick: () => {
1447
1446
  this.onPreview.emit(this.url);
1448
- } }, index$1.h("rtk-icon", { key: 'ceea157f0a5e4802d2c4041f4304b9202b95bc11', icon: this.iconPack.full_screen_maximize })), index$1.h("rtk-button", { key: '2941579aef2546aa70c056bdee9bb76fea9e286f', class: "action", variant: "secondary", kind: "icon", onClick: () => file.downloadFile(this.url, { fallbackName: 'image' }) }, index$1.h("rtk-icon", { key: '3878b4a96f77e419e4a26725bfe7a49e29af8760', icon: this.iconPack.download }))))));
1447
+ } }, index$1.h("rtk-icon", { key: '3ca7384fa28e6716345acacf9225ae9471ff8d63', icon: this.iconPack.full_screen_maximize })), index$1.h("rtk-button", { key: '198787808c389e4df48d3609a53c2d27cf2e7fb3', class: "action", variant: "secondary", kind: "icon", onClick: () => file.downloadFile(this.url, { fallbackName: 'image' }) }, index$1.h("rtk-icon", { key: 'f38fe3da48d1fc854001c719164c95f0673808c5', icon: this.iconPack.download }))))));
1449
1448
  }
1450
1449
  };
1451
1450
  __decorate$7([
@@ -1536,7 +1535,7 @@ const RtkMarkdownView = class {
1536
1535
  const slicedMessage = this.text.slice(0, this.maxLength);
1537
1536
  const withReply = chat.extractReplyBlock(slicedMessage, true);
1538
1537
  const withoutReply = chat.stripOutReplyBlock(slicedMessage);
1539
- return (index$1.h("p", { key: 'beef042bc590e1cb543ddfa4a45b699ab78db63c' }, withReply.length !== 0 && index$1.h("blockquote", { key: '5fd5c57b235c15cdd009474d70e2a6074dd0ec0a' }, this.renderMessage(withReply)), withoutReply.length !== 0 && this.renderMessage(withoutReply)));
1538
+ return (index$1.h("p", { key: '787e6d3177f4faf1c8dcd7c73d83a6de9c57b42b' }, withReply.length !== 0 && index$1.h("blockquote", { key: '1c4b82fb870994e6707d35adcd5e6f2f0e65dd26' }, this.renderMessage(withReply)), withoutReply.length !== 0 && this.renderMessage(withoutReply)));
1540
1539
  }
1541
1540
  };
1542
1541
  RtkMarkdownView.style = RtkMarkdownViewStyle0;
@@ -1917,7 +1916,7 @@ const RtkMenu$1 = class {
1917
1916
  });
1918
1917
  }
1919
1918
  render() {
1920
- return (index$1.h(index$1.Host, { key: '5d80123d52e211d4f120441d9f79582b4dc53247' }, index$1.h("span", { key: '996b1faea4afd983ea69c2bb197b1b6c56c0eca6', id: "trigger", ref: (el) => (this.triggerEl = el), onClick: () => {
1919
+ return (index$1.h(index$1.Host, { key: '15461c803838be1651df6116a61598ce8ab988f9' }, index$1.h("span", { key: 'f36cdd2f1141f46a993daa880682382904a72509', id: "trigger", ref: (el) => (this.triggerEl = el), onClick: () => {
1921
1920
  this.clickedThis = true;
1922
1921
  if (this.menuListEl.style.display !== 'block') {
1923
1922
  this.menuListEl.style.display = 'block';
@@ -1926,7 +1925,7 @@ const RtkMenu$1 = class {
1926
1925
  else {
1927
1926
  this.menuListEl.style.display = 'none';
1928
1927
  }
1929
- } }, index$1.h("slot", { key: 'd54671184af01247f285e27bda8dbb9faf1ba399', name: "trigger" })), index$1.h("span", { key: '3d57dcf7805d7fb53577e722a265a60acea6971a', part: "menu-list", id: "menu-list", ref: (el) => (this.menuListEl = el) }, index$1.h("slot", { key: 'b516e727fc4d435fed30d422ba311099aff70605' }))));
1928
+ } }, index$1.h("slot", { key: 'af622c9dbb3394cb46a6bb909a45c5e3248b1a09', name: "trigger" })), index$1.h("span", { key: '445258e31b4b775fbc22b268234fe15a33f809c9', part: "menu-list", id: "menu-list", ref: (el) => (this.menuListEl = el) }, index$1.h("slot", { key: '87396622c6078253736cbe43a1cac55c6f90754f' }))));
1930
1929
  }
1931
1930
  };
1932
1931
  __decorate$6([
@@ -1961,7 +1960,7 @@ const RtkMenuItem = class {
1961
1960
  this.t = uiStore.useLanguage();
1962
1961
  }
1963
1962
  render() {
1964
- return (index$1.h(index$1.Host, { key: '05ed5b993b4c05f4fc295e2ac45c5337d9b993b3', class: { [this.menuVariant]: true } }, index$1.h("slot", { key: '80aebd20b238627fa7aa2ab3777ebafd8876faaf', name: "start" }), index$1.h("slot", { key: '50ff6c2c4fa7dfe9976030d1e7e39385578b902d' }), index$1.h("slot", { key: 'd93c2517156791d636d0b86569bcd79e08ed4e29', name: "end" })));
1963
+ return (index$1.h(index$1.Host, { key: '8679dae05e846bb8b83a1dbc9580aa2dcad18ccd', class: { [this.menuVariant]: true } }, index$1.h("slot", { key: 'da53376b8188bfc47f904d348212fedff932b03a', name: "start" }), index$1.h("slot", { key: '4394a3afa13bd298880c1be5255f5a004c5ed42e' }), index$1.h("slot", { key: '2be62c70172912e6516ce207b571ea4794aa4f6c', name: "end" })));
1965
1964
  }
1966
1965
  };
1967
1966
  __decorate$5([
@@ -1996,7 +1995,7 @@ const RtkMenuList = class {
1996
1995
  this.t = uiStore.useLanguage();
1997
1996
  }
1998
1997
  render() {
1999
- return (index$1.h(index$1.Host, { key: '758a8f0419b51b59f46391e28265bf6201f537d3', class: { [this.menuVariant]: true } }, index$1.h("slot", { key: '9bc391de012f416c8c29c33fcc26a146f33afe82' })));
1998
+ return (index$1.h(index$1.Host, { key: 'b743da0bae39c93cff7896968a64c84166b8a751', class: { [this.menuVariant]: true } }, index$1.h("slot", { key: '46ca973e68fccbf5c8c7544f61bb9745840d0054' })));
2000
1999
  }
2001
2000
  };
2002
2001
  __decorate$4([
@@ -2055,9 +2054,37 @@ __decorate$3([
2055
2054
  ], RtkMessageView.prototype, "iconPack", void 0);
2056
2055
  RtkMessageView.style = RtkMessageViewStyle0;
2057
2056
 
2058
- const rtkPaginatedListCss = ".scrollbar{scrollbar-width:thin;scrollbar-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60)))\n var(--rtk-scrollbar-background, transparent)}.scrollbar::-webkit-scrollbar{height:var(--rtk-space-1\\.5, 6px);width:var(--rtk-space-1\\.5, 6px);border-radius:9999px;background-color:var(--rtk-scrollbar-background, transparent)}.scrollbar::-webkit-scrollbar-thumb{border-radius:9999px;background-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60)))}:host{position:relative;display:flex;flex-direction:column;flex:1}.container{box-sizing:border-box;display:flex;flex-direction:column-reverse;padding-top:var(--rtk-space-4, 16px);padding-bottom:var(--rtk-space-4, 16px);padding-left:var(--rtk-space-2, 8px);padding-right:var(--rtk-space-2, 8px);flex:1 0 0px;overflow-y:scroll}.file-picker{display:none}.chat *:first-child{margin-top:var(--rtk-space-0, 0px)}.chat .head{display:flex;align-items:center}.chat .head .name{margin-right:var(--rtk-space-4, 16px);font-size:12px;font-weight:700}.chat .head .time{font-size:12px;color:rgb(var(--rtk-colors-text-800, 255 255 255 / 0.76))}.chat .body{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);overflow-wrap:break-word;font-size:14px;line-height:1.375}.chat .body .emoji{font-size:24px}p{margin-top:var(--rtk-space-0, 0px);margin-bottom:var(--rtk-space-3, 12px)}rtk-text-message,rtk-image-message,rtk-file-message{margin-top:var(--rtk-space-4, 16px);display:block;padding-left:var(--rtk-space-3, 12px);padding-right:var(--rtk-space-3, 12px);font-family:var(--rtk-font-family, sans-serif);color:rgb(var(--rtk-colors-text-900, 255 255 255 / 0.88));box-sizing:border-box}*[is-continued]{margin-top:var(--rtk-space-3, 12px)}rtk-text-message[is-continued]{margin-top:var(--rtk-space-2, 8px)}.chat .image{position:relative;height:var(--rtk-space-40, 160px);max-width:var(--rtk-space-64, 256px);cursor:pointer}.chat .image img{display:none;height:100%;width:100%;border-radius:var(--rtk-border-radius-sm, 4px);-o-object-fit:cover;object-fit:cover}.chat .image .image-spinner{display:flex;height:100%;width:100%;flex-direction:column;align-items:center;justify-content:center;border-radius:var(--rtk-border-radius-sm, 4px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-800, 30 30 30) / var(--tw-bg-opacity))}.chat .image .image-spinner rtk-spinner{--tw-text-opacity:1;color:rgba(var(--rtk-colors-brand-500, 33 96 253) / var(--tw-text-opacity))}.chat .image .image-errored{display:flex;height:100%;width:100%;flex-direction:column;align-items:center;justify-content:center;border-radius:var(--rtk-border-radius-sm, 4px);background-color:rgba(var(--rtk-colors-danger, 255 45 45) / 0.1);--tw-text-opacity:1;color:rgba(var(--rtk-colors-danger, 255 45 45) / var(--tw-text-opacity))}.chat .image .actions{display:none;height:var(--rtk-space-8, 32px);align-items:center;position:absolute;top:var(--rtk-space-2, 8px);right:var(--rtk-space-2, 8px);border-radius:var(--rtk-border-radius-sm, 4px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-900, 26 26 26) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-1000, 255 255 255));overflow:hidden;--tw-shadow:0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.chat .image .actions .action{height:var(--rtk-space-8, 32px);width:var(--rtk-space-8, 32px);border-radius:var(--rtk-border-radius-none, 0);border-width:var(--rtk-border-width-none, 0);border-style:none;background-color:transparent;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.chat .image .actions .action:hover{--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}.image.loaded img{display:block}.image.loaded .image-spinner{display:none}.image:hover .actions,.image:focus .actions{display:flex}.chat .file{display:flex;align-items:center;gap:var(--rtk-space-1, 4px);padding-left:var(--rtk-space-2, 8px);padding-right:var(--rtk-space-2, 8px);padding-top:var(--rtk-space-1\\.5, 6px);padding-bottom:var(--rtk-space-1\\.5, 6px);border-radius:var(--rtk-border-radius-sm, 4px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-700, 44 44 44) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-700, 255 255 255 / 0.64))}.chat .file .file-data{flex:1 1 0%}.chat .file .file-data .name{word-break:break-all;color:rgb(var(--rtk-colors-text-1000, 255 255 255));overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.chat .file .file-data .file-data-split{margin-top:var(--rtk-space-0\\.5, 2px);display:flex;align-items:center;font-size:12px}.chat .file .file-data .file-data-split .ext{margin-right:var(--rtk-space-2, 8px);text-transform:uppercase;overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.chat .file .file-data .file-data-split .divider{height:var(--rtk-space-4, 16px);width:var(--rtk-space-0\\.5, 2px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}.chat .file .file-data .file-data-split .size{margin-left:var(--rtk-space-2, 8px)}.smallest-dom-element{width:1px}#top-scroll{transform:translateY(20vh)}#bottom-scroll{transform:translateY(-20vh)}a{--tw-text-opacity:1;color:rgba(var(--rtk-colors-brand-300, 73 124 253) / var(--tw-text-opacity));text-decoration-line:none}a:hover{text-decoration-line:underline}.show-new-messages-ctr{pointer-events:none;position:absolute;bottom:var(--rtk-space-2, 8px);right:var(--rtk-space-4, 16px);z-index:10;margin-top:calc(var(--rtk-space-14, 56px) * -1);--tw-translate-y:var(--rtk-space-28, 112px);transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));opacity:0;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-duration:150ms}.show-new-messages-ctr.active{--tw-translate-y:var(--rtk-space-0, 0px);transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));opacity:1}.show-new-messages{pointer-events:auto;border-radius:9999px}.show-new-messages:hover{border-radius:9999px;--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);--tw-ring-opacity:1;--tw-ring-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-ring-opacity));--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}rtk-spinner,.empty-list{margin:auto}.page-wrapper{margin-left:var(--rtk-space-1, 4px);margin-right:var(--rtk-space-1, 4px)}.message-wrapper{margin-bottom:var(--rtk-space-2, 8px)}.pinned .message-wrapper{position:relative}.pinned .pin-icon{position:absolute;right:calc(var(--rtk-space-1, 4px) * -1);top:calc(var(--rtk-space-1, 4px) * -1);display:flex;border-radius:var(--rtk-border-radius-sm, 4px)}.pinned rtk-message-view{--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-700, 44 44 44) / var(--tw-bg-opacity));padding-top:var(--rtk-space-1, 4px);padding-bottom:var(--rtk-space-1, 4px)}.load-more-on-top-container{pointer-events:none;position:absolute;top:var(--rtk-space-2, 8px);right:var(--rtk-space-4, 16px);z-index:10}.load-more-icon{pointer-events:auto;border-radius:9999px}.load-more-icon:hover{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);--tw-ring-opacity:1;--tw-ring-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-ring-opacity));--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}";
2057
+ const rtkPaginatedListCss = ".scrollbar{scrollbar-width:thin;scrollbar-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60)))\n var(--rtk-scrollbar-background, transparent)}.scrollbar::-webkit-scrollbar{height:var(--rtk-space-1\\.5, 6px);width:var(--rtk-space-1\\.5, 6px);border-radius:9999px;background-color:var(--rtk-scrollbar-background, transparent)}.scrollbar::-webkit-scrollbar-thumb{border-radius:9999px;background-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60)))}:host{position:relative;display:flex;flex-direction:column;flex:1}.container{box-sizing:border-box;display:flex;flex-direction:column-reverse;padding-top:var(--rtk-space-4, 16px);padding-bottom:var(--rtk-space-4, 16px);padding-left:var(--rtk-space-2, 8px);padding-right:var(--rtk-space-2, 8px);flex:1 0 0px;overflow-y:scroll}.file-picker{display:none}.chat *:first-child{margin-top:var(--rtk-space-0, 0px)}.chat .head{display:flex;align-items:center}.chat .head .name{margin-right:var(--rtk-space-4, 16px);font-size:12px;font-weight:700}.chat .head .time{font-size:12px;color:rgb(var(--rtk-colors-text-800, 255 255 255 / 0.76))}.chat .body{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);overflow-wrap:break-word;font-size:14px;line-height:1.375}.chat .body .emoji{font-size:24px}p{margin-top:var(--rtk-space-0, 0px);margin-bottom:var(--rtk-space-3, 12px)}rtk-text-message,rtk-image-message,rtk-file-message{margin-top:var(--rtk-space-4, 16px);display:block;padding-left:var(--rtk-space-3, 12px);padding-right:var(--rtk-space-3, 12px);font-family:var(--rtk-font-family, sans-serif);color:rgb(var(--rtk-colors-text-900, 255 255 255 / 0.88));box-sizing:border-box}*[is-continued]{margin-top:var(--rtk-space-3, 12px)}rtk-text-message[is-continued]{margin-top:var(--rtk-space-2, 8px)}.chat .image{position:relative;height:var(--rtk-space-40, 160px);max-width:var(--rtk-space-64, 256px);cursor:pointer}.chat .image img{display:none;height:100%;width:100%;border-radius:var(--rtk-border-radius-sm, 4px);-o-object-fit:cover;object-fit:cover}.chat .image .image-spinner{display:flex;height:100%;width:100%;flex-direction:column;align-items:center;justify-content:center;border-radius:var(--rtk-border-radius-sm, 4px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-800, 30 30 30) / var(--tw-bg-opacity))}.chat .image .image-spinner rtk-spinner{--tw-text-opacity:1;color:rgba(var(--rtk-colors-brand-500, 33 96 253) / var(--tw-text-opacity))}.chat .image .image-errored{display:flex;height:100%;width:100%;flex-direction:column;align-items:center;justify-content:center;border-radius:var(--rtk-border-radius-sm, 4px);background-color:rgba(var(--rtk-colors-danger, 255 45 45) / 0.1);--tw-text-opacity:1;color:rgba(var(--rtk-colors-danger, 255 45 45) / var(--tw-text-opacity))}.chat .image .actions{display:none;height:var(--rtk-space-8, 32px);align-items:center;position:absolute;top:var(--rtk-space-2, 8px);right:var(--rtk-space-2, 8px);border-radius:var(--rtk-border-radius-sm, 4px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-900, 26 26 26) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-1000, 255 255 255));overflow:hidden;--tw-shadow:0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);--tw-shadow-colored:0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.chat .image .actions .action{height:var(--rtk-space-8, 32px);width:var(--rtk-space-8, 32px);border-radius:var(--rtk-border-radius-none, 0);border-width:var(--rtk-border-width-none, 0);border-style:none;background-color:transparent;--tw-shadow:0 0 #0000;--tw-shadow-colored:0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.chat .image .actions .action:hover{--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}.image.loaded img{display:block}.image.loaded .image-spinner{display:none}.image:hover .actions,.image:focus .actions{display:flex}.chat .file{display:flex;align-items:center;gap:var(--rtk-space-1, 4px);padding-left:var(--rtk-space-2, 8px);padding-right:var(--rtk-space-2, 8px);padding-top:var(--rtk-space-1\\.5, 6px);padding-bottom:var(--rtk-space-1\\.5, 6px);border-radius:var(--rtk-border-radius-sm, 4px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-700, 44 44 44) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-700, 255 255 255 / 0.64))}.chat .file .file-data{flex:1 1 0%}.chat .file .file-data .name{word-break:break-all;color:rgb(var(--rtk-colors-text-1000, 255 255 255));overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.chat .file .file-data .file-data-split{margin-top:var(--rtk-space-0\\.5, 2px);display:flex;align-items:center;font-size:12px}.chat .file .file-data .file-data-split .ext{margin-right:var(--rtk-space-2, 8px);text-transform:uppercase;overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:1}.chat .file .file-data .file-data-split .divider{height:var(--rtk-space-4, 16px);width:var(--rtk-space-0\\.5, 2px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}.chat .file .file-data .file-data-split .size{margin-left:var(--rtk-space-2, 8px)}.smallest-dom-element{width:1px}#top-scroll{transform:translateY(20vh);transform:translateY(20px)}a{--tw-text-opacity:1;color:rgba(var(--rtk-colors-brand-300, 73 124 253) / var(--tw-text-opacity));text-decoration-line:none}a:hover{text-decoration-line:underline}.show-new-messages-ctr{position:absolute;bottom:var(--rtk-space-4, 16px);right:var(--rtk-space-4, 16px);z-index:10;margin-top:calc(var(--rtk-space-14, 56px) * -1);--tw-translate-y:var(--rtk-space-28, 112px);transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));opacity:0;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-duration:150ms}.show-new-messages-ctr.active{--tw-translate-y:var(--rtk-space-0, 0px);transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));cursor:pointer;opacity:1}.show-new-messages{pointer-events:auto;border-radius:9999px}.show-new-messages:hover{border-radius:9999px;--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);--tw-ring-opacity:1;--tw-ring-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-ring-opacity));--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}rtk-spinner,.empty-list{margin:auto}.page-wrapper{margin-left:var(--rtk-space-1, 4px);margin-right:var(--rtk-space-1, 4px);display:flex;flex-direction:column-reverse}.message-wrapper{margin-bottom:var(--rtk-space-2, 8px)}.pinned .message-wrapper{position:relative}.pinned .pin-icon{position:absolute;right:calc(var(--rtk-space-1, 4px) * -1);top:calc(var(--rtk-space-1, 4px) * -1);display:flex;border-radius:var(--rtk-border-radius-sm, 4px)}.pinned rtk-message-view{--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-700, 44 44 44) / var(--tw-bg-opacity));padding-top:var(--rtk-space-1, 4px);padding-bottom:var(--rtk-space-1, 4px)}.load-more-on-top-container{pointer-events:none;position:absolute;top:var(--rtk-space-2, 8px);right:var(--rtk-space-4, 16px);z-index:10}.load-more-icon{pointer-events:auto;border-radius:9999px}.load-more-icon:hover{--tw-ring-offset-shadow:var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow:var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow, 0 0 #0000);--tw-ring-opacity:1;--tw-ring-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-ring-opacity));--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-600, 60 60 60) / var(--tw-bg-opacity))}";
2059
2058
  const RtkPaginatedListStyle0 = rtkPaginatedListCss;
2060
2059
 
2060
+ /**
2061
+ * HOW INFINITE SCROLL WORKS:
2062
+ *
2063
+ * We use intersectionObserver to scroll up.
2064
+ * We use scrollEnd listener to scroll down.
2065
+ *
2066
+ * Why?
2067
+ * intersectionObserver doesn't work reliably for 2 way scrolling but has great ux,
2068
+ * so we use it to smoothly scroll up.
2069
+ *
2070
+ * We have empty divs at the top and bottom ($topRef, $bottomRef)
2071
+ * which act as triggers to tell that we have reached the top or end of our messages and need to fetch new messages,
2072
+ *
2073
+ * When scrolling up, we can't remove pages as intersectionObserver relies on
2074
+ * the index of dom elements to work properly.
2075
+ * So instead, we fetch older messages and push them to the end of the 2d array
2076
+ * if length exceeds pagesAllowed, we free up the pages and keep the first empty index in memory (firstEmptyIndex).
2077
+ *
2078
+ * For scrolling down, when scroll ends we see if the bottomRef is in view.
2079
+ * If yes, we fetch the new page and insert it at the firstEmptyIndex.
2080
+ * We update timestamps & firstEmptyIndex, then we rerender.
2081
+ *
2082
+ * If we have exceeded our page allowance we delete old pages.
2083
+ *
2084
+ * In this case deleting pages is okay as we are not relying on the index of dom elements to detect page end.
2085
+ *
2086
+ * This also simplifies the code because when a user scrolls up we do not need to manage a lastEmptyIndex.
2087
+ */
2061
2088
  var __decorate$2 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
2062
2089
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2063
2090
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
@@ -2071,274 +2098,270 @@ var __decorate$2 = (undefined && undefined.__decorate) || function (decorators,
2071
2098
  const RtkPaginatedList = class {
2072
2099
  constructor(hostRef) {
2073
2100
  index$1.registerInstance(this, hostRef);
2101
+ /**
2102
+ * when scrolling up, we can't remove pages as intersectionObserver relies on
2103
+ * the index of dom elements to stay stable.
2104
+ * So, instead we free up the pages and keep the last empty index in memory.
2105
+ */
2106
+ this.firstEmptyIndex = -1;
2107
+ this.maxTS = 0;
2108
+ // the length of pages will always be pageSize + 2
2109
+ this.pages = [];
2110
+ /** label to show when empty */
2111
+ this.emptyListLabel = null;
2112
+ this.rerenderBoolean = false;
2113
+ this.showEmptyListLabel = false;
2074
2114
  /** Icon pack */
2075
2115
  this.iconPack = uiStore.defaultIconPack;
2076
2116
  /** Language */
2077
2117
  this.t = uiStore.useLanguage();
2078
- /** label to show when empty */
2079
- this.emptyListLabel = null;
2080
2118
  this.isLoading = false;
2081
2119
  this.isLoadingTop = false;
2082
2120
  this.isLoadingBottom = false;
2083
- this.hasMoreDataAtTop = false;
2084
- this.rerenderBoolean = false;
2085
- /**
2086
- * This gets disabled when the user scrolls up and the bottom node
2087
- * is not visible anymore.
2088
- */
2089
- this.shouldRenderNewNodes = true;
2090
- /**
2091
- * This gets disabled when the user scrolls up and the bottom node
2092
- * is not visible anymore.
2093
- */
2094
- this.hasNewNodesToRender = false;
2095
- this.showEmptyListLabel = false;
2096
2121
  /**
2097
- * This is a private variable not a state
2098
- * since we want to debounce rerenders
2099
- *
2100
- * A list of pages where each page contains a number of Nodes
2101
- * [
2102
- * [Node 1, Node 2, Node 3.... Node N],
2103
- * [Node 1, Node 2, Node 3.... Node N],
2104
- * ]
2105
- */
2106
- this.pagesToRender = [[]];
2107
- this.currentTime = () => {
2108
- return new Date().getTime();
2109
- };
2122
+ * Even when auto scroll is enabled, we only want to scroll if a new realtime message has arrived.
2123
+ * This variable tells us if we should respect auto scroll after a new page has been loaded.
2124
+ * It is also used by the scroll to bottom button.
2125
+ * */
2126
+ this.shouldScrollToBottom = false;
2127
+ /** UI Indicator for the "scroll to bottom" button.
2128
+ * Toggles on when a new node is added and autoscroll is disabled.
2129
+ * Toggles off when all nodes are loaded */
2130
+ this.showNewMessagesCTR = false;
2110
2131
  this.observe = (el) => {
2111
2132
  if (!el)
2112
2133
  return;
2113
2134
  this.intersectionObserver.observe(el);
2114
2135
  };
2136
+ this.isAtBottom = () => {
2137
+ const rect = this.$bottomRef.getBoundingClientRect();
2138
+ return rect.top >= 0 && rect.bottom <= window.innerHeight;
2139
+ };
2115
2140
  }
2116
2141
  /**
2117
- * On a new node created
2142
+ * Adds a new node to the beginning of the paginated list
2143
+ * @param {DataNode} node - The data node to add to the beginning of the list
2118
2144
  */
2119
2145
  async onNewNode(node) {
2120
- if (!this.shouldRenderNewNodes) {
2121
- this.hasNewNodesToRender = true;
2122
- return;
2146
+ // Always update the maxTS. New messages will load on scroll till the end cursor (newTS) reaches this value.
2147
+ this.maxTS = Math.max(this.maxTS, node.timeMs);
2148
+ // if we are at the bottom of the page
2149
+ if (this.firstEmptyIndex === -1) {
2150
+ // if there are no pages, load the first page
2151
+ if (this.pages.length < 1) {
2152
+ // update old timer to 1ms ahead of the latest message as we subtract this value to avoid loading duplicate messages when scrolling
2153
+ this.oldTS = node.timeMs + 1;
2154
+ this.loadPrevPage();
2155
+ }
2156
+ else {
2157
+ // append messages to the page if page has not reached full capacity
2158
+ if (this.pages[0].length < this.pageSize) {
2159
+ this.pages[0].unshift(node);
2160
+ this.newTS = node.timeMs;
2161
+ this.rerender();
2162
+ }
2163
+ else {
2164
+ // if page is at full capacity, load next page
2165
+ this.loadNextPage();
2166
+ }
2167
+ }
2123
2168
  }
2124
- this.addNodeToRender(node, false);
2125
- this.rerender();
2126
- }
2127
- /**
2128
- * On node deleted
2129
- */
2130
- async onNodeDelete(key) {
2131
- const oldLength = this.pagesToRender.flat().length;
2132
- this.pagesToRender = this.pagesToRender.map((page) => page.filter((item) => item.id !== key));
2133
- if (oldLength !== this.pagesToRender.flat().length) {
2134
- this.rerender();
2169
+ // If autoscroll is enabled, this method will scroll to the bottom
2170
+ if (this.autoScroll) {
2171
+ this.shouldScrollToBottom = true;
2172
+ this.scrollToBottom();
2173
+ }
2174
+ else {
2175
+ this.showNewMessagesCTR = true;
2135
2176
  }
2136
2177
  }
2178
+ // this method is called recursively based on shouldScrollToBottom (see scrollEnd listener)
2179
+ scrollToBottom() {
2180
+ this.$bottomRef.scrollIntoView({ behavior: 'smooth' });
2181
+ }
2137
2182
  /**
2138
- * On node updated
2139
- */
2140
- async onNodeUpdate(key, newItem) {
2141
- let shouldRerender = false;
2142
- this.pagesToRender = this.pagesToRender.map((page) => page.map((item) => {
2143
- if (item.id === key) {
2144
- shouldRerender = true;
2145
- return newItem;
2183
+ * Deletes a node anywhere from the list
2184
+ * @param {string} id - The id of the node to delete
2185
+ * */
2186
+ async onNodeDelete(id) {
2187
+ // Iterate only over pages that have content (not empty)
2188
+ for (let i = this.pages.length - 1; i > this.firstEmptyIndex; i--) {
2189
+ const index = this.pages[i].findIndex((node) => node.id === id);
2190
+ // message in view
2191
+ if (index !== -1) {
2192
+ // delete message
2193
+ this.pages[i].splice(index, 1);
2194
+ // if we are on the first page and it's now empty, we need to go back to initial state
2195
+ if (i === 0 && this.pages[i].length === 0) {
2196
+ this.pages.shift();
2197
+ this.firstEmptyIndex = -1;
2198
+ }
2199
+ else if (i === this.firstEmptyIndex + 1) {
2200
+ // if newest page is empty, update first empty index
2201
+ if (this.pages[i].length === 0)
2202
+ this.firstEmptyIndex++;
2203
+ // update timestamp, first empty index could be -1, so we need to cap it at 0
2204
+ this.newTS = this.pages[Math.max(this.firstEmptyIndex, 0)][0].timeMs;
2205
+ }
2206
+ else if (i === this.firstEmptyIndex + this.pagesAllowed) {
2207
+ // if oldest page is empty, remove it
2208
+ if (this.pages[i].length === 0)
2209
+ this.pages.pop();
2210
+ // update timestamp
2211
+ const lastPage = this.pages[this.firstEmptyIndex + this.pagesAllowed];
2212
+ this.oldTS = lastPage[lastPage.length - 1].timeMs;
2213
+ }
2214
+ this.rerender();
2146
2215
  }
2147
- return item;
2148
- }));
2149
- if (shouldRerender)
2150
- this.rerender();
2151
- }
2152
- onItemChanged(newItemId, oldItemId) {
2153
- if (newItemId !== oldItemId) {
2154
- this.pagesToRender = [[]];
2155
- this.loadFirstPage().then(() => this.rerender());
2156
2216
  }
2157
2217
  }
2218
+ /**
2219
+ * Updates a new node anywhere in the list
2220
+ * @param {string} _id - The id of the node to update
2221
+ * @param {DataNode} _node - The updated data node
2222
+ * */
2223
+ async onNodeUpdate(_id, _node) { }
2224
+ rerender() {
2225
+ this.rerenderBoolean = !this.rerenderBoolean;
2226
+ }
2158
2227
  connectedCallback() {
2159
2228
  this.rerender = debounce.debounce(this.rerender.bind(this), 50, { maxWait: 200 });
2160
- this.autoScroll = true;
2161
2229
  this.intersectionObserver = new IntersectionObserver((entries) => {
2162
- index$1.writeTask(() => {
2230
+ index$1.writeTask(async () => {
2163
2231
  for (const entry of entries) {
2164
- if (entry.target.id === 'bottom-scroll') {
2165
- if (entry.isIntersecting)
2166
- this.loadBottom();
2167
- else
2168
- this.shouldRenderNewNodes = false;
2169
- }
2170
2232
  if (entry.target.id === 'top-scroll' && entry.isIntersecting) {
2171
- this.loadTop();
2233
+ this.isLoadingTop = true;
2234
+ await this.loadPrevPage();
2235
+ this.isLoadingTop = false;
2172
2236
  }
2173
2237
  }
2174
2238
  });
2175
2239
  });
2176
2240
  }
2177
- disconnectedCallback() {
2178
- this.intersectionObserver.disconnect();
2179
- }
2180
2241
  componentDidLoad() {
2181
- /**
2182
- * Adding observes here so that on the first render we scroll down
2183
- * and shouldRenderNewNodes remains true
2184
- */
2185
- this.loadFirstPage();
2186
2242
  this.observe(this.$topRef);
2187
- this.observe(this.$bottomRef);
2188
- }
2189
- componentDidRender() {
2190
- if (this.shouldRenderNewNodes && this.autoScroll)
2191
- scroll.smoothScrollToBottom(this.$paginatedList);
2192
- }
2193
- loadFirstPage() {
2194
- return this.loadPage(this.currentTime(), this.pageSize, true, (data) => {
2195
- if (data.length === 0) {
2196
- this.showEmptyListLabel = true;
2197
- }
2198
- });
2199
- }
2200
- loadTop() {
2201
- /**
2202
- * If there is only one unfilled page or no page, no need to check
2203
- * for top since it will be empty
2204
- */
2205
- if (this.pagesToRender.length === 0)
2206
- return;
2207
- if (this.pagesToRender.length === 1 && this.pagesToRender[0].length < this.pageSize)
2208
- return;
2209
- /**
2210
- * TODO: Make this more flexible currently this only works with chat
2211
- */
2212
- const oldestVNode = this.pagesToRender[0][0];
2213
- const oldestTimestamp = oldestVNode.timeMs;
2214
- // TODO: scrollIntoView
2215
- const onPageRendered = () => { }; // oldestVNode.$elm$?.scrollIntoView();
2216
- this.isLoadingTop = true;
2217
- this.loadPage(oldestTimestamp - 1, this.pageSize, true, onPageRendered, 'top');
2218
- }
2219
- loadBottom() {
2220
- /**
2221
- * If there is only one unfilled page or no page, no need to check
2222
- * for top since it will be empty
2223
- */
2224
- if (this.pagesToRender.length === 0) {
2225
- this.shouldRenderNewNodes = true;
2226
- return;
2227
- }
2228
- if (this.pagesToRender.length === 1 && this.pagesToRender[0].length < this.pageSize) {
2229
- this.shouldRenderNewNodes = true;
2230
- return;
2231
- }
2232
- const newestVNode = this.pagesToRender.at(-1).at(-1);
2233
- const newestTimestamp = newestVNode.timeMs;
2234
- // TODO: scrollIntoView
2235
- const onPageRendered = () => scroll.smoothScrollToBottom(this.$paginatedList);
2236
- this.isLoadingBottom = true;
2237
- this.loadPage(newestTimestamp + 1, this.pageSize, false, onPageRendered, 'bottom');
2238
- }
2239
- addNodeToRender(node, addToStart) {
2240
- if (addToStart) {
2241
- const firstPage = this.pagesToRender[0];
2242
- if (firstPage && (firstPage === null || firstPage === void 0 ? void 0 : firstPage.length) < this.pageSize) {
2243
+ if (this.$containerRef) {
2244
+ this.$containerRef.onscrollend = async () => {
2243
2245
  /**
2244
- * If first page is not full then just add to that page
2246
+ * Load new page if:
2247
+ * if there are nodes to load at the bottom (maxTS > newTS)
2248
+ * or if there are pages to fill at the bottom (firstEmptyIndex > -1)
2245
2249
  */
2246
- firstPage.unshift(node);
2247
- }
2248
- else {
2249
- /**
2250
- * If first page is full then add a new page to the start
2251
- */
2252
- const newPage = [node];
2253
- this.pagesToRender.unshift(newPage);
2254
- this.removeLastPageIfNeeded(false);
2255
- }
2256
- }
2257
- else {
2258
- const [lastPage] = this.pagesToRender.slice(-1);
2259
- if (lastPage && (lastPage === null || lastPage === void 0 ? void 0 : lastPage.length) < this.pageSize) {
2260
- /**
2261
- * If last page is not full then just add it
2262
- */
2263
- lastPage.push(node);
2264
- }
2265
- else {
2266
- /**
2267
- * If last page is full add a new page with just
2268
- * this node
2269
- */
2270
- const newPage = [node];
2271
- this.pagesToRender.push(newPage);
2272
- this.removeLastPageIfNeeded(true);
2273
- }
2250
+ if (this.isAtBottom() && (this.maxTS > this.newTS || this.firstEmptyIndex > -1)) {
2251
+ this.isLoadingBottom = true;
2252
+ await this.loadNextPage();
2253
+ this.isLoadingBottom = false;
2254
+ if (this.shouldScrollToBottom)
2255
+ this.scrollToBottom();
2256
+ }
2257
+ };
2274
2258
  }
2275
2259
  }
2276
- /**
2277
- * @param start
2278
- * @param end
2279
- * @param reversed Defines whether to add the page at the beginning or the end
2280
- * @param onPageLoaded Callback for when all new nodes are rendered
2281
- * @param direction Indicates if loading from 'top' or 'bottom'
2282
- */
2283
- async loadPage(timestamp, size, reversed, onPageRendered = () => { }, direction) {
2260
+ async loadPrevPage() {
2261
+ if (this.isLoading)
2262
+ return;
2263
+ /**
2264
+ * NOTE(ikabra): this case also runs on initial load
2265
+ * if scrolling up ->
2266
+ * fetch older messages and push to the end of the array
2267
+ * cleanup 1st non empty page from the array if length exceeds pagesAllowed
2268
+ */
2269
+ // if no old timestamp, it means we are at initial state
2270
+ if (!this.oldTS)
2271
+ this.oldTS = new Date().getTime();
2272
+ // load data
2284
2273
  this.isLoading = true;
2285
- const data = (await this.fetchData(timestamp, size, reversed));
2274
+ const data = await this.fetchData(this.oldTS - 1, this.pageSize, true);
2286
2275
  this.isLoading = false;
2287
- if (direction === 'top') {
2288
- this.isLoadingTop = false;
2289
- this.hasMoreDataAtTop = (data === null || data === void 0 ? void 0 : data.length) > 0;
2290
- }
2291
- if (direction === 'bottom') {
2292
- this.isLoadingBottom = false;
2293
- }
2294
- if (!(data === null || data === void 0 ? void 0 : data.length)) {
2276
+ // no more old messages to show, we are at the top of the page
2277
+ if (!data.length)
2278
+ return;
2279
+ // add old data to the end of the array
2280
+ this.pages.push(data);
2281
+ // clear old pages when we reach the limit
2282
+ if (this.pages.length > this.pagesAllowed) {
2283
+ this.pages[this.pages.length - this.pagesAllowed - 1] = [];
2295
2284
  /**
2296
- * While scrolling down if there were no new items found
2297
- * then start rendering new nodes;
2285
+ * find last non empty page in range (this.pages.length, this.firstEmptyIndex)
2286
+ * we are doing this because any of the middle pages in the currently rendered pages
2287
+ * could be empty as we allow deleting messages.
2288
+ * This helps us set the first empty index correctly.
2298
2289
  */
2299
- if (!reversed) {
2300
- this.hasNewNodesToRender = false;
2301
- this.shouldRenderNewNodes = true;
2290
+ for (let i = this.firstEmptyIndex + 1; i < this.pages.length; i++) {
2291
+ if (this.pages[i].length > 0)
2292
+ break;
2293
+ this.firstEmptyIndex = i;
2302
2294
  }
2303
- onPageRendered([]);
2304
- return;
2305
2295
  }
2306
- data.forEach((node) => this.addNodeToRender(node, reversed));
2296
+ // update the old timestamp
2297
+ const lastPage = this.pages[this.pages.length - 1];
2298
+ this.oldTS = lastPage[lastPage.length - 1].timeMs;
2299
+ // update the new timestamp
2300
+ this.newTS = this.pages[this.firstEmptyIndex + 1][0].timeMs;
2307
2301
  this.rerender();
2308
- onPageRendered(data);
2309
- }
2310
- rerender() {
2311
- this.rerenderBoolean = !this.rerenderBoolean;
2312
2302
  }
2313
- removeLastPageIfNeeded(removeFromStart) {
2314
- if (this.pagesToRender.length > this.pagesAllowed) {
2315
- if (removeFromStart)
2316
- this.pagesToRender.shift();
2317
- else
2318
- this.pagesToRender.pop();
2303
+ async loadNextPage() {
2304
+ if (this.isLoading)
2305
+ return;
2306
+ // new timestamp needs to be assigned by loadPrevPage method
2307
+ if (!this.newTS) {
2308
+ this.showNewMessagesCTR = false;
2309
+ this.shouldScrollToBottom = false;
2310
+ return;
2319
2311
  }
2320
- }
2321
- onDownArrowClicked() {
2322
- /**
2323
- * Load the freshest pages
2324
- */
2325
- this.loadBottom();
2326
- }
2327
- onLoadMoreOnTopClicked() {
2328
- this.loadTop();
2312
+ // load data
2313
+ this.isLoading = true;
2314
+ const data = await this.fetchData(this.newTS + 1, this.pageSize, false);
2315
+ this.isLoading = false;
2316
+ // no more new messages to load
2317
+ if (!data.length) {
2318
+ this.showNewMessagesCTR = false;
2319
+ this.shouldScrollToBottom = false;
2320
+ // remove extra pages from the start if any (could be due to users deleting messages)
2321
+ this.pages = this.pages.filter((page) => page.length > 0);
2322
+ this.firstEmptyIndex = -1;
2323
+ return;
2324
+ }
2325
+ // when filling empty pages
2326
+ if (this.firstEmptyIndex > -1) {
2327
+ this.pages[this.firstEmptyIndex] = data.reverse();
2328
+ }
2329
+ else {
2330
+ // when already at the bottom and loading messages in realtime
2331
+ this.pages.unshift(data.reverse());
2332
+ }
2333
+ if (this.pages.length > this.pagesAllowed) {
2334
+ this.pages.pop();
2335
+ }
2336
+ // smallest value for firstEmptyIndex can be -1, so we cap the index at 0
2337
+ this.newTS = this.pages[Math.max(0, this.firstEmptyIndex)][0].timeMs;
2338
+ // remove all empty pages from the end
2339
+ for (let i = this.pages.length - 1; i > this.firstEmptyIndex; i--) {
2340
+ if (this.pages[i].length > 0)
2341
+ break;
2342
+ // if page is empty, remove it
2343
+ this.pages.pop();
2344
+ }
2345
+ // update the old timestamp
2346
+ const lastPage = this.pages[this.pages.length - 1];
2347
+ this.oldTS = lastPage[lastPage.length - 1].timeMs;
2348
+ // when scrolling too fast scroll a bit to the top to be able to load new messages when you scroll down
2349
+ if (this.$containerRef.scrollTop === 0)
2350
+ this.$containerRef.scrollTop = -60;
2351
+ // smallest value for this index can be -1 (indicates we are at the bottom of the page).
2352
+ this.firstEmptyIndex = Math.max(-1, this.firstEmptyIndex - 1);
2353
+ this.rerender();
2329
2354
  }
2330
2355
  render() {
2331
- var _a;
2332
2356
  /**
2333
2357
  * div.container is flex=column-reverse
2334
2358
  * which is why div#bottom-scroll comes before div#top-scroll
2335
- * div.page-wrapper prevents reversal of messages
2336
2359
  */
2337
- return (index$1.h(index$1.Host, { key: '2ee90baa6b1b9f88829d04632c129287b936ba30' }, index$1.h("div", { key: 'd68db998539fd1df12e92d61828a04628f7d9f0a', class: "scrollbar container", part: "container", ref: (el) => (this.$paginatedList = el) }, index$1.h("div", { key: '4fe1ae2b1aa961242ba6be8ca3b8b6c6e504ef5c', class: { 'show-new-messages-ctr': true, active: !this.shouldRenderNewNodes } }, index$1.h("rtk-button", { key: '5c7ad4c553eb6f1b7f14bad406e49fe18f63d100', class: "show-new-messages", kind: "icon", variant: "secondary", part: "show-new-messages", onClick: () => this.onDownArrowClicked() }, index$1.h("rtk-icon", { key: 'dacfc24e3fb9ec34e40447b606e256eefaefdc6e', icon: this.iconPack.chevron_down }))), index$1.h("div", { key: '569ffce0c198638b831a3eb0bac9a032c863ed9d', class: "smallest-dom-element", id: "bottom-scroll", ref: (el) => (this.$bottomRef = el) }), this.isLoadingBottom && index$1.h("rtk-spinner", { key: '06f571694e1877d8eba4ec939bc6a74f68f16caa', size: "sm" }), this.isLoading && this.pagesToRender.flat().length === 0 && index$1.h("rtk-spinner", { key: '628c0eef27fe29d2c3cbf6f0da7d10a12560c127', size: "lg" }), this.pagesToRender.flat().length === 0 && this.showEmptyListLabel ? (index$1.h("div", { class: "empty-list" }, (_a = this.emptyListLabel) !== null && _a !== void 0 ? _a : this.t('list.empty'))) : (index$1.h("div", { class: "page-wrapper" }, this.pagesToRender.map((page) => this.createNodes(page)))), this.hasMoreDataAtTop && !this.isLoadingTop && (index$1.h("div", { key: 'fc5207945ed0949074e3460d9943130eb4289409', class: "load-more-on-top-container" }, index$1.h("rtk-button", { key: '4fff7d14798340dc576e4aeeebfe9e3946cbcf6a', class: "load-more-icon", kind: "icon", variant: "secondary", part: "load-more-icon", onClick: () => this.onLoadMoreOnTopClicked() }, index$1.h("rtk-icon", { key: '87b2abaf1c850189246d1b9aa84b55c374b31d1d', icon: this.iconPack.chevron_up })))), this.isLoadingTop && index$1.h("rtk-spinner", { key: '766ac48eebaa236a9a44f770d777c2c31fabe10e', size: "sm" }), index$1.h("div", { key: '6a5287556030f9f426ac2d8b6063b13a966135ff', class: "smallest-dom-element", id: "top-scroll", ref: (el) => (this.$topRef = el) }))));
2360
+ return (index$1.h(index$1.Host, { key: '9bf695bccf42f2dd43b04725a855b6b77a4062fd' }, index$1.h("div", { key: '7c6805ed8b5e831ea6d932cfb5dc3ecf3d312775', class: "scrollbar container", part: "container", ref: (el) => (this.$containerRef = el) }, index$1.h("div", { key: 'eb6c68f97385b5a14a94ab2dc0abff4836f016f3', class: { 'show-new-messages-ctr': true, active: this.showNewMessagesCTR } }, index$1.h("rtk-button", { key: 'd1f04db290a9e4128ca58c9bd20b2146a7fc8f12', class: "show-new-messages", kind: "icon", variant: "secondary", part: "show-new-messages", onClick: () => {
2361
+ this.shouldScrollToBottom = true;
2362
+ this.scrollToBottom();
2363
+ } }, index$1.h("rtk-icon", { key: '71d8a85911513bb4069578a63ae45f21ac53554c', icon: this.iconPack.chevron_down }))), index$1.h("div", { key: 'b1aa46b8163431df6060163d7c5a87eb1ebcffa3', class: "smallest-dom-element", id: "bottom-scroll", ref: (el) => (this.$bottomRef = el) }), this.isLoadingBottom && this.pages.length > 0 && index$1.h("rtk-spinner", { key: 'a3de0e7b8ca1ac505a596d86c0b8ecafee5fabba', size: "sm" }), this.isLoading && this.pages.length < 1 && index$1.h("rtk-spinner", { key: '21fa3a4091d3f1311f5d575c277859602718338c', size: "lg" }), !this.isLoading && this.pages.flat().length === 0 ? (index$1.h("div", { class: "empty-list" }, this.t('list.empty'))) : (index$1.h("div", { class: "page-wrapper" }, this.pages.map((page, pageIndex) => (index$1.h("div", { class: "page", "data-page-index": pageIndex }, this.createNodes([...page].reverse())))))), this.isLoadingTop && this.pages.length > 0 && index$1.h("rtk-spinner", { key: '7e018af534e7cd0be3345ca9ad9c8f0a7ab7cc3f', size: "sm" }), index$1.h("div", { key: '6c877368fc03c884338402bbcd878929cd4034fb', class: "smallest-dom-element", id: "top-scroll", ref: (el) => (this.$topRef = el) }))));
2338
2364
  }
2339
- static get watchers() { return {
2340
- "selectedItemId": ["onItemChanged"]
2341
- }; }
2342
2365
  };
2343
2366
  __decorate$2([
2344
2367
  index.SyncWithStore()
@@ -2370,7 +2393,7 @@ const RtkSpinner = class {
2370
2393
  this.size = 'md';
2371
2394
  }
2372
2395
  render() {
2373
- return (index$1.h(index$1.Host, { key: '6533b4dea247db4d15d92409c6a9dc8f9662833d' }, index$1.h("rtk-icon", { key: '1db4c3e42e78355313ea59f3247cc0a5ef8283c7', class: "spinner", icon: this.iconPack.spinner })));
2396
+ return (index$1.h(index$1.Host, { key: 'c042cbd31d8fa9e58c0cbbc5646575a3172fc824' }, index$1.h("rtk-icon", { key: '0171ba3d5f7506e2c67eb813c5ad5b263352088d', class: "spinner", icon: this.iconPack.spinner })));
2374
2397
  }
2375
2398
  };
2376
2399
  __decorate$1([
@@ -2448,7 +2471,7 @@ const RtkTextComposerView = class {
2448
2471
  }
2449
2472
  }
2450
2473
  render() {
2451
- return (index$1.h("div", { key: 'f6fee4d5766f78409f6bcc788be8ecdd5ad8b865', class: "chat-input", part: "chat-input-container" }, this.maxLengthBreached > 0 && (index$1.h("div", { key: '10c3721417e791557b4d0b126838209880e9f570', class: 'text-error ' + (this.maxLengthBreached === this.maxLength ? 'breached' : '') }, index$1.h("rtk-icon", { key: 'e806de9d5db9bf708d06ede1c4a958583f87b08b', id: "warning-indicator", icon: this.iconPack.warning, part: "warning-indicator" }), ' ', this.maxLengthBreached, " / ", this.maxLength, " ", this.t('chat.max_limit_warning'))), this.rateLimitBreached && (index$1.h("div", { key: '8c84906b5247775bf404e626f45f30b183fb9086', class: 'text-error breached' }, index$1.h("rtk-icon", { key: 'b2b646474d6702e4191ac9c50eef0d3c0efd0e4f', id: "warning-indicator", icon: this.iconPack.warning, part: "warning-indicator" }), ' ', this.t('chat.rate_limit_error'))), index$1.h("textarea", { key: 'f17233beb688a811ebe11f965a39c7df288b6ea5', ref: (el) => (this.$textArea = el), placeholder: this.placeholder, disabled: this.disabled, onInput: this.onInputHandler, onKeyDown: this.keyDownHandler, part: "chat-input", value: this.value })));
2474
+ return (index$1.h("div", { key: 'e5f7fa2bd4a2386ff5185001981477ccacf24556', class: "chat-input", part: "chat-input-container" }, this.maxLengthBreached > 0 && (index$1.h("div", { key: '4c06c853ddc7bebafe45fdb2e2c5c9e1c20021fe', class: 'text-error ' + (this.maxLengthBreached === this.maxLength ? 'breached' : '') }, index$1.h("rtk-icon", { key: '524037dc257f0aea206fbc3503d1fe1cb03449be', id: "warning-indicator", icon: this.iconPack.warning, part: "warning-indicator" }), ' ', this.maxLengthBreached, " / ", this.maxLength, " ", this.t('chat.max_limit_warning'))), this.rateLimitBreached && (index$1.h("div", { key: 'cf975664f367f2621593239ab1cf2e73f5acdb45', class: 'text-error breached' }, index$1.h("rtk-icon", { key: '70a6555f1fa9752f91951181b46e0ed0e7eb8679', id: "warning-indicator", icon: this.iconPack.warning, part: "warning-indicator" }), ' ', this.t('chat.rate_limit_error'))), index$1.h("textarea", { key: '7fc7280dd143cd701d5037e04c2b36c3ea8ec023', ref: (el) => (this.$textArea = el), placeholder: this.placeholder, disabled: this.disabled, onInput: this.onInputHandler, onKeyDown: this.keyDownHandler, part: "chat-input", value: this.value })));
2452
2475
  }
2453
2476
  };
2454
2477
  __decorate([
@@ -2469,7 +2492,7 @@ const RtkTextMessageView = class {
2469
2492
  this.isMarkdown = false;
2470
2493
  }
2471
2494
  render() {
2472
- return (index$1.h("p", { key: 'a52466b9a67706f84af1fc84c9504b028af8b082', class: { text: true, emoji: string.hasOnlyEmojis(this.text) } }, this.isMarkdown ? index$1.h("rtk-markdown-view", { text: this.text }) : this.text));
2495
+ return (index$1.h("p", { key: 'b4cbabb44d32f96a23cd72f108d6a36b05491c97', class: { text: true, emoji: string.hasOnlyEmojis(this.text) } }, this.isMarkdown ? index$1.h("rtk-markdown-view", { text: this.text }) : this.text));
2473
2496
  }
2474
2497
  };
2475
2498
  RtkTextMessageView.style = RtkTextMessageViewStyle0;
@@ -2575,7 +2598,7 @@ const RtkMenu = class {
2575
2598
  });
2576
2599
  }
2577
2600
  render() {
2578
- return (index$1.h(index$1.Host, { key: '502a8095ff2d516209a343d9fd9d6869757bf68b' }, index$1.h("span", { key: '18089635a87113958cb9ff8f3f5f5a44a32456e8', part: "trigger", id: "trigger", ref: (el) => (this.triggerEl = el) }, index$1.h("slot", { key: '5a31f0ab6825d8fc822afbb2a55604b5dd306b1c' })), index$1.h("div", { key: '8d2859fcdda1429d4527659ff5f7127f6e6fb4d2', part: "tooltip", class: "tooltip", id: "tooltip", role: "tooltip", ref: (el) => (this.tooltipEl = el) }, index$1.h("div", { key: '21ee9c44389decfac5bb43a3182ea645b237900d', id: "arrow", ref: (el) => (this.arrowEl = el), part: "arrow" }), this.label, index$1.h("slot", { key: '43d0841146bc003133e1b6747fae4a676f9b5324', name: "tooltip" }))));
2601
+ return (index$1.h(index$1.Host, { key: '5278137bc9b99d9fe9ffeb0fc30bd887d600494d' }, index$1.h("span", { key: 'cbefda068a15340dad76668c3696a10bd94cb8e9', part: "trigger", id: "trigger", ref: (el) => (this.triggerEl = el) }, index$1.h("slot", { key: 'f160cf29ece64145e795a9a11459bd458482c446' })), index$1.h("div", { key: '1056b2bbc8cbacd3c32280d334d9f703a578b5ef', part: "tooltip", class: "tooltip", id: "tooltip", role: "tooltip", ref: (el) => (this.tooltipEl = el) }, index$1.h("div", { key: '6c6816fa1b18d49fa22ab6ffb600aaa23c5b9ec5', id: "arrow", ref: (el) => (this.arrowEl = el), part: "arrow" }), this.label, index$1.h("slot", { key: '3c2d3425b2e8b4d810de2ce40394491c4698aede', name: "tooltip" }))));
2579
2602
  }
2580
2603
  static get watchers() { return {
2581
2604
  "open": ["openChanged"]