@cloudflare/realtimekit-ui 2.0.3-staging.8 → 2.0.3

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 (76) hide show
  1. package/dist/browser.js +1 -1
  2. package/dist/cjs/rtk-avatar_26.cjs.entry.js +19 -19
  3. package/dist/cjs/rtk-breakout-rooms-manager_8.cjs.entry.js +2 -2
  4. package/dist/cjs/rtk-grid.cjs.entry.js +3 -1
  5. package/dist/cjs/rtk-message-list-view.cjs.entry.js +3 -3
  6. package/dist/cjs/rtk-sidebar-ui.cjs.entry.js +2 -2
  7. package/dist/cjs/rtk-spotlight-grid.cjs.entry.js +2 -2
  8. package/dist/collection/components/rtk-ai/rtk-ai.js +2 -4
  9. package/dist/collection/components/rtk-broadcast-message-modal/rtk-broadcast-message-modal.js +4 -6
  10. package/dist/collection/components/rtk-chat-composer-view/rtk-chat-composer-view.js +8 -7
  11. package/dist/collection/components/rtk-chat-selector/rtk-chat-selector.js +9 -10
  12. package/dist/collection/components/rtk-grid/rtk-grid.js +3 -1
  13. package/dist/collection/components/rtk-livestream-toggle/rtk-livestream-toggle.js +2 -4
  14. package/dist/collection/components/rtk-message-list-view/rtk-message-list-view.js +4 -4
  15. package/dist/collection/components/rtk-paginated-list/rtk-paginated-list.js +4 -4
  16. package/dist/collection/components/rtk-participants-stage-queue/rtk-participants-stage-queue.js +2 -4
  17. package/dist/collection/components/rtk-pip-toggle/rtk-pip-toggle.js +2 -4
  18. package/dist/collection/components/rtk-sidebar-ui/rtk-sidebar-ui.js +4 -6
  19. package/dist/collection/components/rtk-spotlight-grid/rtk-spotlight-grid.js +3 -3
  20. package/dist/components/{p-EkUCxpDZ.js → p-BoqfUgTL.js} +1 -1
  21. package/dist/components/p-ByPpyWt6.js +1 -0
  22. package/dist/components/{p-BsgKgxKu.js → p-C0ESgBoj.js} +1 -1
  23. package/dist/components/{p-qDy7F0Tr.js → p-C9UuqXCX.js} +1 -1
  24. package/dist/components/{p-Bmk8auxt.js → p-CAsupO2z.js} +1 -1
  25. package/dist/components/{p-CXq0ujSg.js → p-CNaazJXM.js} +1 -1
  26. package/dist/components/{p-DbBGSlfQ.js → p-E1D1eNFh.js} +1 -1
  27. package/dist/components/{p-l-tiOHlG.js → p-Ryaxu6vl.js} +1 -1
  28. package/dist/components/{p-A83Jz8rO.js → p-VHRH6fkb.js} +1 -1
  29. package/dist/components/rtk-broadcast-message-modal.js +1 -1
  30. package/dist/components/rtk-chat-composer-view.js +1 -1
  31. package/dist/components/rtk-chat-header.js +1 -1
  32. package/dist/components/rtk-chat-messages-ui-paginated.js +1 -1
  33. package/dist/components/rtk-chat-search-results.js +1 -1
  34. package/dist/components/rtk-chat-selector.js +1 -1
  35. package/dist/components/rtk-chat.js +1 -1
  36. package/dist/components/rtk-dialog-manager.js +1 -1
  37. package/dist/components/rtk-grid.js +1 -1
  38. package/dist/components/rtk-meeting.js +1 -1
  39. package/dist/components/rtk-message-list-view.js +1 -1
  40. package/dist/components/rtk-paginated-list.js +1 -1
  41. package/dist/components/rtk-participants.js +1 -1
  42. package/dist/components/rtk-pinned-message-selector.js +1 -1
  43. package/dist/components/rtk-sidebar-ui.js +1 -1
  44. package/dist/components/rtk-sidebar.js +1 -1
  45. package/dist/components/rtk-spotlight-grid.js +1 -1
  46. package/dist/docs/docs-components.json +11 -11
  47. package/dist/docs/docs-vscode.json +8 -8
  48. package/dist/esm/loader.js +31 -29
  49. package/dist/esm/rtk-avatar_26.entry.js +19 -19
  50. package/dist/esm/rtk-breakout-rooms-manager_8.entry.js +2 -2
  51. package/dist/esm/rtk-grid.entry.js +3 -1
  52. package/dist/esm/rtk-message-list-view.entry.js +3 -3
  53. package/dist/esm/rtk-sidebar-ui.entry.js +2 -2
  54. package/dist/esm/rtk-spotlight-grid.entry.js +2 -2
  55. package/dist/realtimekit-ui/{p-64bc4514.entry.js → p-20734a3a.entry.js} +1 -1
  56. package/dist/realtimekit-ui/{p-31c97dcd.entry.js → p-8cdd8307.entry.js} +1 -1
  57. package/dist/realtimekit-ui/{p-2da96ec3.entry.js → p-b27db286.entry.js} +1 -1
  58. package/dist/realtimekit-ui/{p-2308568a.entry.js → p-ce81ffaa.entry.js} +1 -1
  59. package/dist/realtimekit-ui/{p-f2de718a.entry.js → p-d30c178f.entry.js} +1 -1
  60. package/dist/realtimekit-ui/p-ff89f0f6.entry.js +1 -0
  61. package/dist/realtimekit-ui/realtimekit-ui.esm.js +1 -1
  62. package/dist/types/components/rtk-ai/rtk-ai.d.ts +2 -4
  63. package/dist/types/components/rtk-broadcast-message-modal/rtk-broadcast-message-modal.d.ts +2 -4
  64. package/dist/types/components/rtk-chat-composer-view/rtk-chat-composer-view.d.ts +1 -0
  65. package/dist/types/components/rtk-chat-selector/rtk-chat-selector.d.ts +1 -1
  66. package/dist/types/components/rtk-livestream-toggle/rtk-livestream-toggle.d.ts +2 -4
  67. package/dist/types/components/rtk-message-list-view/rtk-message-list-view.d.ts +1 -1
  68. package/dist/types/components/rtk-paginated-list/rtk-paginated-list.d.ts +1 -1
  69. package/dist/types/components/rtk-participants-stage-queue/rtk-participants-stage-queue.d.ts +2 -4
  70. package/dist/types/components/rtk-pip-toggle/rtk-pip-toggle.d.ts +2 -4
  71. package/dist/types/components/rtk-sidebar-ui/rtk-sidebar-ui.d.ts +2 -4
  72. package/dist/types/components/rtk-spotlight-grid/rtk-spotlight-grid.d.ts +1 -1
  73. package/dist/types/components.d.ts +57 -79
  74. package/package.json +3 -2
  75. package/dist/components/p-DzDWIdoE.js +0 -1
  76. package/dist/realtimekit-ui/p-cf7f7d9c.entry.js +0 -1
@@ -1 +1 @@
1
- import{p as t,H as i,c as s,h as e,d as r,t as a}from"./p-BBHQOrFK.js";import{c as n,e as o,i as h}from"./p-DhwysA2e.js";import{d as p}from"./p-t72veIFj.js";import{R as c}from"./p-CBJjerDR.js";import{a as l}from"./p-C0vp-Q7v.js";import{S as d}from"./p-bRRQr4xn.js";import{d as g}from"./p-CmmyVCoN.js";import{d as m}from"./p-D6vw6bT2.js";import{d as v}from"./p-CFBS-gbK.js";import{d as u}from"./p-CEK_XoGw.js";import{d as f}from"./p-BYIBbfJ8.js";import{d as k}from"./p-vqPkhXWC.js";import{d as x}from"./p-DhG2PF_5.js";import{d as b}from"./p-B0SC1Zj-.js";import{d as S}from"./p-DViKr-34.js";var y=function(t,i,s,e){var r,a=arguments.length,n=a<3?i:null===e?e=Object.getOwnPropertyDescriptor(i,s):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,i,s,e);else for(var o=t.length-1;o>=0;o--)(r=t[o])&&(n=(a<3?r(n):a>3?r(i,s,n):r(i,s))||n);return a>3&&n&&Object.defineProperty(i,s,n),n};const C=t(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.stateUpdate=s(this,"rtkStateUpdate",7),this.hideSelf=!1,this.participants=[],this.pinnedParticipants=[],this.screenShareParticipants=[],this.plugins=[],this.emptyStage=!1,this.showLiveStreamPlayer=!1,this.canCurrentPeerHost=!1,this.pipSupported=!1,this.pipEnabled=!1,this.hidden=!1,this.layout="row",this.aspectRatio="16:9",this.gap=8,this.config=n(),this.iconPack=o,this.t=h(),this.gridSize=g,this.overrides={},this.invalidRoomStates=["init","waitlisted","ended","kicked","rejected"],this.filterParticipants=t=>{var i;if(this.overrides&&(null===(i=this.overrides)||void 0===i?void 0:i.videoUnsubscribed)){const i=this.overrides.videoUnsubscribed.preset;i.length>0&&(t=t.filter((t=>!i.some((i=>void 0!==t.presetName&&t.presetName.match(i))))))}return t},this.onViewModeChanged=()=>{this.meeting&&this.updateActiveParticipants()},this.refreshParticipants=p((()=>{this.updateActiveParticipants()}),50),this.stageStatusListener=()=>{this.updateActiveParticipants(),this.showLiveStreamPlayer=l(this.meeting),"ON_STAGE"!==this.meeting.stage.status&&this.removeScreenShare(this.meeting.self)},this.peerStageStatusListener=t=>{this.updateActiveParticipants(),"ON_STAGE"!==this.meeting.stage.status&&(this.removePinned(t),this.removeScreenShare(t))},this.onScreenShareUpdate=t=>{t.screenShareEnabled?this.addScreenShare(t):this.removeScreenShare(t)},this.onSelfScreenShareUpdate=({screenShareEnabled:t})=>{t?this.addScreenShare(this.meeting.self):this.removeScreenShare(this.meeting.self)},this.toggleTileListener=({hidden:t})=>{this.hidden=t,this.updateActiveParticipants()},this.onPluginStateUpdate=(t,{active:i})=>{i?this.plugins.some((i=>i.id===t.id))||(this.plugins=[...this.plugins,t]):this.plugins=this.plugins.filter((i=>i.id!==t.id))},this.onParticipantPinned=()=>{this.updateActiveParticipants()},this.onParticipantUnpinned=()=>{this.updateActiveParticipants()},this.updateRoomStateListener=()=>{this.roomState=this.meeting.self.roomState}}connectedCallback(){this.meetingChanged(this.meeting)}disconnectedCallback(){this.disconnectMeeting(this.meeting)}disconnectMeeting(t){var i;if(!t)return;this.refreshParticipants.cancel(),this.participants=[],this.plugins=[];const{self:s,participants:e,plugins:r}=t;s.removeListener("pinned",this.onParticipantPinned),s.removeListener("unpinned",this.onParticipantUnpinned),s.removeListener("roomLeft",this.updateRoomStateListener),s.removeListener("roomJoined",this.updateRoomStateListener),s.removeListener("screenShareUpdate",this.onSelfScreenShareUpdate),s.removeListener("toggleTile",this.toggleTileListener),null==r||r.all.removeListener("stateUpdate",this.onPluginStateUpdate),null===(i=t.stage)||void 0===i||i.removeListener("stageStatusUpdate",this.stageStatusListener),e.removeListener("viewModeChanged",this.onViewModeChanged),e.active.removeListener("participantLeft",this.refreshParticipants),e.active.removeListener("participantJoined",this.refreshParticipants),e.active.removeListener("participantsUpdate",this.refreshParticipants),e.pinned.removeListener("participantJoined",this.onParticipantPinned),e.pinned.removeListener("participantLeft",this.onParticipantUnpinned),e.joined.removeListener("screenShareUpdate",this.onScreenShareUpdate),e.joined.removeListener("stageStatusUpdate",this.peerStageStatusListener)}meetingChanged(t,i){var s,e,r,a;if(null!==i&&this.disconnectMeeting(i),null!=t){const{self:i,participants:n,plugins:o,stage:h}=t;this.pipSupported=(null===(s=this.meeting.participants.pip)||void 0===s?void 0:s.isSupported())&&(null===(e=t.self.config)||void 0===e?void 0:e.pipMode),this.pipSupported&&this.meeting.participants.pip.init();const{permissions:p}=i;this.roomState=i.roomState,this.hideSelf="ON_STAGE"!==this.meeting.stage.status||(null==p?void 0:p.isRecorder)||p.hiddenParticipant,this.participants=this.filterParticipants([...n.active.toArray(),...i.isPinned||this.hideSelf?[]:[i]]),this.pinnedParticipants=[...n.pinned.toArray(),...i.isPinned&&!this.hideSelf?[i]:[]],this.screenShareParticipants=n.joined.toArray().filter((t=>t.screenShareEnabled)),this.plugins=(null==o?void 0:o.active.toArray())||[],(null==p?void 0:p.stageEnabled)&&(this.canCurrentPeerHost=p.acceptStageRequests||"ALLOWED"===p.canProduceAudio||"ALLOWED"===p.canProduceVideo||"ALLOWED"===p.canProduceScreenshare,this.updateStage()),this.hidden=t.self.hidden,i.addListener("roomLeft",this.updateRoomStateListener),i.addListener("roomJoined",this.updateRoomStateListener),i.addListener("screenShareUpdate",this.onSelfScreenShareUpdate),i.addListener("pinned",this.onParticipantPinned),i.addListener("unpinned",this.onParticipantUnpinned),i.addListener("toggleTile",this.toggleTileListener),null==h||h.addListener("stageStatusUpdate",this.stageStatusListener),null==o||o.all.addListener("stateUpdate",this.onPluginStateUpdate),n.addListener("viewModeChanged",this.onViewModeChanged),n.active.addListener("participantLeft",this.refreshParticipants),null===(r=null==n?void 0:n.joined)||void 0===r||r.on("stageStatusUpdate",this.peerStageStatusListener),n.joined.addListener("screenShareUpdate",this.onScreenShareUpdate),n.active.addListener("participantJoined",this.refreshParticipants),n.active.addListener("participantsUpdate",this.refreshParticipants),n.pinned.addListener("participantJoined",this.onParticipantPinned),n.pinned.addListener("participantLeft",this.onParticipantUnpinned),(null===(a=t.stage)||void 0===a?void 0:a.status)&&this.stageStatusListener()}}overridesChanged(t){this.updateActiveParticipants()}screenShareParticipantsChanged(t){const i=t.length>0;!!this.states.activeScreenShare!==i&&(this.stateUpdate.emit({activeScreenShare:i}),this.states.activeScreenShare=i)}pluginsChanged(t){const i=t.length>0;!!this.states.activePlugin!==i&&(this.stateUpdate.emit({activePlugin:i}),this.states.activePlugin=i)}pinnedParticipantsChanged(t){const i=t.length>0;!!this.states.activeSpotlight!==i&&(this.stateUpdate.emit({activeSpotlight:i}),this.states.activeSpotlight=i)}updateActiveParticipants(){var t;const{self:i,participants:s,stage:e}=this.meeting;this.hideSelf=this.hidden||"ON_STAGE"!==e.status||(null===(t=i.permissions)||void 0===t?void 0:t.isRecorder)||i.permissions.hiddenParticipant,this.participants=this.filterParticipants([...s.active.toArray().filter((t=>t.id!==i.id)),..."ACTIVE_GRID"!==s.viewMode||i.isPinned||this.hideSelf?[]:[i]]),this.pinnedParticipants=[...s.pinned.toArray().filter((t=>t.id!==i.id)),...i.isPinned&&!this.hideSelf?[i]:[]],this.screenShareParticipants=s.joined.toArray().filter((t=>t.screenShareEnabled)),i.screenShareEnabled&&(this.screenShareParticipants=this.screenShareParticipants.concat([i])),this.updateStage()}updateStage(){var t;const{self:i}=this.meeting;this.meeting&&(this.emptyStage=!!(null===(t=null==i?void 0:i.permissions)||void 0===t?void 0:t.stageEnabled)&&0===this.participants.length&&0===this.pinnedParticipants.length)}addScreenShare(t){this.screenShareParticipants.some((i=>i.id===t.id))||(this.screenShareParticipants=[...this.screenShareParticipants,t])}removeScreenShare(t){this.screenShareParticipants=this.screenShareParticipants.filter((i=>i.id!==t.id))}removePinned(t){this.pinnedParticipants=this.pinnedParticipants.filter((i=>i.id!==t.id))}render(){var t,i,s,a;const n={meeting:this.meeting,size:this.size,states:this.states,config:this.config,iconPack:this.iconPack,t:this.t};if(this.invalidRoomStates.includes(this.roomState))return e(r,null,e("div",{class:"offline-grid"},e("rtk-icon",{icon:this.iconPack.join_stage,size:"xl"}),e("h3",null,this.t("disconnected")),e("p",null,this.t("disconnected.description"))));if("disconnected"===this.roomState){const n=null===(i=null===(t=this.meeting)||void 0===t?void 0:t.meta)||void 0===i?void 0:i.mediaState;if("connected"!==(null===(s=null==n?void 0:n.send)||void 0===s?void 0:s.state)||"connected"!==(null===(a=null==n?void 0:n.recv)||void 0===a?void 0:a.state))return e(r,null,e("div",{class:"offline-grid"},e("rtk-icon",{icon:this.iconPack.disconnected,size:"xl"}),e("h3",null,this.t("offline")),e("p",null,this.t("offline.description"))))}return"failed"===this.roomState?e(r,null,e("div",{class:"offline-grid"},e("rtk-icon",{icon:this.iconPack.disconnected,size:"xl"}),e("h3",null,this.t("failed")),e("p",null,this.t("failed.description")))):this.showLiveStreamPlayer?e(r,null,e("rtk-livestream-player",{meeting:this.meeting,size:this.size}),e("rtk-livestream-indicator",{meeting:this.meeting,size:"sm",t:this.t}),e("rtk-viewer-count",{meeting:this.meeting,variant:"embedded",t:this.t})):this.emptyStage?e(r,null,e("div",{class:"webinar-stage"},e("div",{class:"center"},this.canCurrentPeerHost&&e("div",{class:"ctr",part:"container"},e("p",{class:"message",part:"message"},this.t("stage.empty_host")),e("span",{class:"description",part:"description"},this.t("stage.empty_host_summary"))),!this.canCurrentPeerHost&&e("div",{class:"ctr",part:"container"},e("p",{class:"message",part:"message"},this.t("stage.empty_viewer")))))):e(r,null,e(c,{element:"rtk-grid",defaults:n,childProps:{participants:this.participants,screenShareParticipants:this.screenShareParticipants,plugins:this.plugins,pinnedParticipants:this.pinnedParticipants,aspectRatio:this.aspectRatio,gap:this.gap,layout:this.layout,gridSize:this.gridSize},onlyChildren:!0}),e("rtk-livestream-indicator",{meeting:this.meeting,size:"sm",t:this.t}),e("rtk-viewer-count",{meeting:this.meeting,variant:"embedded",t:this.t}))}static get watchers(){return{meeting:[{meetingChanged:0}],overrides:[{overridesChanged:0}],screenShareParticipants:[{screenShareParticipantsChanged:0}],plugins:[{pluginsChanged:0}],pinnedParticipants:[{pinnedParticipantsChanged:0}]}}static get style(){return":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:block;height:100%;width:100%}.offline-grid{display:flex;height:100%;width:100%;flex-direction:column;align-items:center;justify-content:center}.offline-grid h3{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);margin-left:var(--rtk-space-0, 0px);margin-right:var(--rtk-space-0, 0px);font-size:20px;font-weight:500;color:rgb(var(--rtk-colors-text-900, 255 255 255 / 0.88))}.offline-grid p{margin-top:var(--rtk-space-1, 4px);margin-bottom:var(--rtk-space-1, 4px);margin-left:var(--rtk-space-0, 0px);margin-right:var(--rtk-space-0, 0px);text-align:center;font-size:16px;font-weight:400;color:rgb(var(--rtk-colors-text-700, 255 255 255 / 0.64))}.offline-grid rtk-icon{margin-bottom:var(--rtk-space-2, 8px)}.webinar-stage{box-sizing:border-box;height:100%;display:flex;align-content:center;align-items:center;justify-content:center;text-align:center}.webinar-stage h2{margin:var(--rtk-space-0, 0px);font-weight:normal}rtk-viewer-count{display:none}.ctr{display:flex;flex-direction:column;align-items:center}.message{font-size:16px;border-radius:var(--rtk-border-radius-lg, 12px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-800, 30 30 30) / var(--tw-bg-opacity));padding-left:var(--rtk-space-8, 32px);padding-right:var(--rtk-space-8, 32px);padding-top:var(--rtk-space-4, 16px);padding-bottom:var(--rtk-space-4, 16px);color:rgb(var(--rtk-colors-text-1000, 255 255 255))}.description{margin-top:var(--rtk-space-4, 16px);margin-bottom:var(--rtk-space-4, 16px);font-size:14px}rtk-livestream-indicator{display:none}@media only screen and (max-device-height: 480px) and (orientation: landscape){rtk-viewer-count[variant='embedded']{position:absolute;top:var(--rtk-space-0, 0px);right:var(--rtk-space-2, 8px);z-index:20;margin-top:var(--rtk-space-0, 0px);margin-left:var(--rtk-space-0, 0px);display:flex}rtk-livestream-indicator{position:absolute;top:var(--rtk-space-0, 0px);left:var(--rtk-space-2, 8px);z-index:20;margin-top:var(--rtk-space-0, 0px);margin-left:var(--rtk-space-0, 0px);display:flex}}"}},[1,"rtk-grid",{layout:[513],aspectRatio:[513,"aspect-ratio"],meeting:[16],gap:[514],size:[513],states:[16],config:[16],iconPack:[16],t:[16],gridSize:[16],overrides:[8],participants:[32],pinnedParticipants:[32],screenShareParticipants:[32],plugins:[32],emptyStage:[32],showLiveStreamPlayer:[32],canCurrentPeerHost:[32],pipSupported:[32],pipEnabled:[32],hidden:[32],roomState:[32]},void 0,{meeting:[{meetingChanged:0}],overrides:[{overridesChanged:0}],screenShareParticipants:[{screenShareParticipantsChanged:0}],plugins:[{pluginsChanged:0}],pinnedParticipants:[{pinnedParticipantsChanged:0}]}]);function w(){"undefined"!=typeof customElements&&["rtk-grid","rtk-button","rtk-controlbar-button","rtk-fullscreen-toggle","rtk-icon","rtk-livestream-indicator","rtk-livestream-player","rtk-spinner","rtk-viewer-count"].forEach((t=>{switch(t){case"rtk-grid":customElements.get(a(t))||customElements.define(a(t),C);break;case"rtk-button":customElements.get(a(t))||m();break;case"rtk-controlbar-button":customElements.get(a(t))||v();break;case"rtk-fullscreen-toggle":customElements.get(a(t))||u();break;case"rtk-icon":customElements.get(a(t))||f();break;case"rtk-livestream-indicator":customElements.get(a(t))||k();break;case"rtk-livestream-player":customElements.get(a(t))||x();break;case"rtk-spinner":customElements.get(a(t))||b();break;case"rtk-viewer-count":customElements.get(a(t))||S()}}))}y([d()],C.prototype,"meeting",void 0),y([d()],C.prototype,"states",void 0),y([d()],C.prototype,"config",void 0),y([d()],C.prototype,"iconPack",void 0),y([d()],C.prototype,"t",void 0),w();const P=C,j=w;export{P as RtkGrid,j as defineCustomElement}
1
+ import{p as t,H as i,c as s,h as e,d as r,t as a}from"./p-BBHQOrFK.js";import{c as n,e as o,i as h}from"./p-DhwysA2e.js";import{d as p}from"./p-t72veIFj.js";import{R as c}from"./p-CBJjerDR.js";import{a as l}from"./p-C0vp-Q7v.js";import{S as d}from"./p-bRRQr4xn.js";import{d as g}from"./p-CmmyVCoN.js";import{d as m}from"./p-D6vw6bT2.js";import{d as v}from"./p-CFBS-gbK.js";import{d as u}from"./p-CEK_XoGw.js";import{d as f}from"./p-BYIBbfJ8.js";import{d as k}from"./p-vqPkhXWC.js";import{d as x}from"./p-DhG2PF_5.js";import{d as b}from"./p-B0SC1Zj-.js";import{d as S}from"./p-DViKr-34.js";var y=function(t,i,s,e){var r,a=arguments.length,n=a<3?i:null===e?e=Object.getOwnPropertyDescriptor(i,s):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,i,s,e);else for(var o=t.length-1;o>=0;o--)(r=t[o])&&(n=(a<3?r(n):a>3?r(i,s,n):r(i,s))||n);return a>3&&n&&Object.defineProperty(i,s,n),n};const C=t(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.stateUpdate=s(this,"rtkStateUpdate",7),this.hideSelf=!1,this.participants=[],this.pinnedParticipants=[],this.screenShareParticipants=[],this.plugins=[],this.emptyStage=!1,this.showLiveStreamPlayer=!1,this.canCurrentPeerHost=!1,this.pipSupported=!1,this.pipEnabled=!1,this.hidden=!1,this.layout="row",this.aspectRatio="16:9",this.gap=8,this.config=n(),this.iconPack=o,this.t=h(),this.gridSize=g,this.overrides={},this.invalidRoomStates=["init","waitlisted","ended","kicked","rejected"],this.filterParticipants=t=>{var i;if(this.overrides&&(null===(i=this.overrides)||void 0===i?void 0:i.videoUnsubscribed)){const i=this.overrides.videoUnsubscribed.preset;i.length>0&&(t=t.filter((t=>!i.some((i=>void 0!==t.presetName&&t.presetName.match(i))))))}return t},this.onViewModeChanged=()=>{this.meeting&&this.updateActiveParticipants()},this.refreshParticipants=p((()=>{this.updateActiveParticipants()}),50),this.stageStatusListener=()=>{this.updateActiveParticipants(),this.showLiveStreamPlayer=l(this.meeting),"ON_STAGE"!==this.meeting.stage.status&&this.removeScreenShare(this.meeting.self)},this.peerStageStatusListener=t=>{this.updateActiveParticipants(),"ON_STAGE"!==this.meeting.stage.status&&(this.removePinned(t),this.removeScreenShare(t))},this.onScreenShareUpdate=t=>{t.screenShareEnabled?this.addScreenShare(t):this.removeScreenShare(t)},this.onSelfScreenShareUpdate=({screenShareEnabled:t})=>{t?this.addScreenShare(this.meeting.self):this.removeScreenShare(this.meeting.self)},this.toggleTileListener=({hidden:t})=>{this.hidden=t,this.updateActiveParticipants()},this.onPluginStateUpdate=(t,{active:i})=>{i?this.plugins.some((i=>i.id===t.id))||(this.plugins=[...this.plugins,t]):this.plugins=this.plugins.filter((i=>i.id!==t.id))},this.onParticipantPinned=()=>{this.updateActiveParticipants()},this.onParticipantUnpinned=()=>{this.updateActiveParticipants()},this.updateRoomStateListener=()=>{this.roomState=this.meeting.self.roomState}}connectedCallback(){this.meetingChanged(this.meeting)}disconnectedCallback(){this.disconnectMeeting(this.meeting)}disconnectMeeting(t){var i;if(!t)return;this.refreshParticipants.cancel(),this.participants=[],this.plugins=[];const{self:s,participants:e,plugins:r}=t;s.removeListener("pinned",this.onParticipantPinned),s.removeListener("unpinned",this.onParticipantUnpinned),s.removeListener("roomLeft",this.updateRoomStateListener),s.removeListener("roomJoined",this.updateRoomStateListener),s.removeListener("screenShareUpdate",this.onSelfScreenShareUpdate),s.removeListener("toggleTile",this.toggleTileListener),null==r||r.all.removeListener("stateUpdate",this.onPluginStateUpdate),null===(i=t.stage)||void 0===i||i.removeListener("stageStatusUpdate",this.stageStatusListener),e.removeListener("viewModeChanged",this.onViewModeChanged),e.active.removeListener("participantLeft",this.refreshParticipants),e.active.removeListener("participantJoined",this.refreshParticipants),e.active.removeListener("participantsUpdate",this.refreshParticipants),e.pinned.removeListener("participantJoined",this.onParticipantPinned),e.pinned.removeListener("participantLeft",this.onParticipantUnpinned),e.joined.removeListener("screenShareUpdate",this.onScreenShareUpdate),e.joined.removeListener("stageStatusUpdate",this.peerStageStatusListener)}meetingChanged(t,i){var s,e,r,a;if(null!==i&&this.disconnectMeeting(i),null!=t){const{self:i,participants:n,plugins:o,stage:h}=t;this.pipSupported=(null===(s=this.meeting.participants.pip)||void 0===s?void 0:s.isSupported())&&(null===(e=t.self.config)||void 0===e?void 0:e.pipMode),this.pipSupported&&this.meeting.participants.pip.init();const{permissions:p}=i;this.roomState=i.roomState,this.hideSelf="ON_STAGE"!==this.meeting.stage.status||(null==p?void 0:p.isRecorder)||p.hiddenParticipant,this.participants=this.filterParticipants([...n.active.toArray(),...i.isPinned||this.hideSelf?[]:[i]]),this.pinnedParticipants=[...n.pinned.toArray(),...i.isPinned&&!this.hideSelf?[i]:[]],this.screenShareParticipants=n.joined.toArray().filter((t=>t.screenShareEnabled)),this.plugins=(null==o?void 0:o.active.toArray())||[],(null==p?void 0:p.stageEnabled)&&(this.canCurrentPeerHost=p.acceptStageRequests||"ALLOWED"===p.canProduceAudio||"ALLOWED"===p.canProduceVideo||"ALLOWED"===p.canProduceScreenshare,this.updateStage()),this.hidden=t.self.hidden,i.addListener("roomLeft",this.updateRoomStateListener),i.addListener("roomJoined",this.updateRoomStateListener),i.addListener("screenShareUpdate",this.onSelfScreenShareUpdate),i.addListener("pinned",this.onParticipantPinned),i.addListener("unpinned",this.onParticipantUnpinned),i.addListener("toggleTile",this.toggleTileListener),null==h||h.addListener("stageStatusUpdate",this.stageStatusListener),null==o||o.all.addListener("stateUpdate",this.onPluginStateUpdate),n.addListener("viewModeChanged",this.onViewModeChanged),n.active.addListener("participantLeft",this.refreshParticipants),null===(r=null==n?void 0:n.joined)||void 0===r||r.on("stageStatusUpdate",this.peerStageStatusListener),n.joined.addListener("screenShareUpdate",this.onScreenShareUpdate),n.active.addListener("participantJoined",this.refreshParticipants),n.active.addListener("participantsUpdate",this.refreshParticipants),n.pinned.addListener("participantJoined",this.onParticipantPinned),n.pinned.addListener("participantLeft",this.onParticipantUnpinned),(null===(a=t.stage)||void 0===a?void 0:a.status)&&this.stageStatusListener()}}overridesChanged(t){this.updateActiveParticipants()}screenShareParticipantsChanged(t){const i=t.length>0;!!this.states.activeScreenShare!==i&&(this.stateUpdate.emit({activeScreenShare:i}),this.states.activeScreenShare=i)}pluginsChanged(t){const i=t.length>0;!!this.states.activePlugin!==i&&(this.stateUpdate.emit({activePlugin:i}),this.states.activePlugin=i)}pinnedParticipantsChanged(t){const i=t.length>0;!!this.states.activeSpotlight!==i&&(this.stateUpdate.emit({activeSpotlight:i}),this.states.activeSpotlight=i)}updateActiveParticipants(){var t;const{self:i,participants:s,stage:e}=this.meeting;this.hideSelf=this.hidden||"ON_STAGE"!==e.status||(null===(t=i.permissions)||void 0===t?void 0:t.isRecorder)||i.permissions.hiddenParticipant,this.participants=this.filterParticipants([...s.active.toArray().filter((t=>t.id!==i.id)),...!["ACTIVE_GRID","MANUAL"].includes(s.viewMode)||i.isPinned||this.hideSelf?[]:[i]]),this.pinnedParticipants=[...s.pinned.toArray().filter((t=>t.id!==i.id)),...i.isPinned&&!this.hideSelf?[i]:[]],this.screenShareParticipants=s.joined.toArray().filter((t=>t.screenShareEnabled)),i.screenShareEnabled&&(this.screenShareParticipants=this.screenShareParticipants.concat([i])),this.updateStage()}updateStage(){var t;const{self:i}=this.meeting;this.meeting&&(this.emptyStage=!!(null===(t=null==i?void 0:i.permissions)||void 0===t?void 0:t.stageEnabled)&&0===this.participants.length&&0===this.pinnedParticipants.length)}addScreenShare(t){this.screenShareParticipants.some((i=>i.id===t.id))||(this.screenShareParticipants=[...this.screenShareParticipants,t])}removeScreenShare(t){this.screenShareParticipants=this.screenShareParticipants.filter((i=>i.id!==t.id))}removePinned(t){this.pinnedParticipants=this.pinnedParticipants.filter((i=>i.id!==t.id))}render(){var t,i,s,a;const n={meeting:this.meeting,size:this.size,states:this.states,config:this.config,iconPack:this.iconPack,t:this.t};if(this.invalidRoomStates.includes(this.roomState))return e(r,null,e("div",{class:"offline-grid"},e("rtk-icon",{icon:this.iconPack.join_stage,size:"xl"}),e("h3",null,this.t("disconnected")),e("p",null,this.t("disconnected.description"))));if("disconnected"===this.roomState){const n=null===(i=null===(t=this.meeting)||void 0===t?void 0:t.meta)||void 0===i?void 0:i.mediaState;if("connected"!==(null===(s=null==n?void 0:n.send)||void 0===s?void 0:s.state)||"connected"!==(null===(a=null==n?void 0:n.recv)||void 0===a?void 0:a.state))return e(r,null,e("div",{class:"offline-grid"},e("rtk-icon",{icon:this.iconPack.disconnected,size:"xl"}),e("h3",null,this.t("offline")),e("p",null,this.t("offline.description"))))}return"failed"===this.roomState?e(r,null,e("div",{class:"offline-grid"},e("rtk-icon",{icon:this.iconPack.disconnected,size:"xl"}),e("h3",null,this.t("failed")),e("p",null,this.t("failed.description")))):this.showLiveStreamPlayer?e(r,null,e("rtk-livestream-player",{meeting:this.meeting,size:this.size}),e("rtk-livestream-indicator",{meeting:this.meeting,size:"sm",t:this.t}),e("rtk-viewer-count",{meeting:this.meeting,variant:"embedded",t:this.t})):this.emptyStage?e(r,null,e("div",{class:"webinar-stage"},e("div",{class:"center"},this.canCurrentPeerHost&&e("div",{class:"ctr",part:"container"},e("p",{class:"message",part:"message"},this.t("stage.empty_host")),e("span",{class:"description",part:"description"},this.t("stage.empty_host_summary"))),!this.canCurrentPeerHost&&e("div",{class:"ctr",part:"container"},e("p",{class:"message",part:"message"},this.t("stage.empty_viewer")))))):e(r,null,e(c,{element:"rtk-grid",defaults:n,childProps:{participants:this.participants,screenShareParticipants:this.screenShareParticipants,plugins:this.plugins,pinnedParticipants:this.pinnedParticipants,aspectRatio:this.aspectRatio,gap:this.gap,layout:this.layout,gridSize:this.gridSize},onlyChildren:!0}),e("rtk-livestream-indicator",{meeting:this.meeting,size:"sm",t:this.t}),e("rtk-viewer-count",{meeting:this.meeting,variant:"embedded",t:this.t}))}static get watchers(){return{meeting:[{meetingChanged:0}],overrides:[{overridesChanged:0}],screenShareParticipants:[{screenShareParticipantsChanged:0}],plugins:[{pluginsChanged:0}],pinnedParticipants:[{pinnedParticipantsChanged:0}]}}static get style(){return":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:block;height:100%;width:100%}.offline-grid{display:flex;height:100%;width:100%;flex-direction:column;align-items:center;justify-content:center}.offline-grid h3{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);margin-left:var(--rtk-space-0, 0px);margin-right:var(--rtk-space-0, 0px);font-size:20px;font-weight:500;color:rgb(var(--rtk-colors-text-900, 255 255 255 / 0.88))}.offline-grid p{margin-top:var(--rtk-space-1, 4px);margin-bottom:var(--rtk-space-1, 4px);margin-left:var(--rtk-space-0, 0px);margin-right:var(--rtk-space-0, 0px);text-align:center;font-size:16px;font-weight:400;color:rgb(var(--rtk-colors-text-700, 255 255 255 / 0.64))}.offline-grid rtk-icon{margin-bottom:var(--rtk-space-2, 8px)}.webinar-stage{box-sizing:border-box;height:100%;display:flex;align-content:center;align-items:center;justify-content:center;text-align:center}.webinar-stage h2{margin:var(--rtk-space-0, 0px);font-weight:normal}rtk-viewer-count{display:none}.ctr{display:flex;flex-direction:column;align-items:center}.message{font-size:16px;border-radius:var(--rtk-border-radius-lg, 12px);--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-800, 30 30 30) / var(--tw-bg-opacity));padding-left:var(--rtk-space-8, 32px);padding-right:var(--rtk-space-8, 32px);padding-top:var(--rtk-space-4, 16px);padding-bottom:var(--rtk-space-4, 16px);color:rgb(var(--rtk-colors-text-1000, 255 255 255))}.description{margin-top:var(--rtk-space-4, 16px);margin-bottom:var(--rtk-space-4, 16px);font-size:14px}rtk-livestream-indicator{display:none}@media only screen and (max-device-height: 480px) and (orientation: landscape){rtk-viewer-count[variant='embedded']{position:absolute;top:var(--rtk-space-0, 0px);right:var(--rtk-space-2, 8px);z-index:20;margin-top:var(--rtk-space-0, 0px);margin-left:var(--rtk-space-0, 0px);display:flex}rtk-livestream-indicator{position:absolute;top:var(--rtk-space-0, 0px);left:var(--rtk-space-2, 8px);z-index:20;margin-top:var(--rtk-space-0, 0px);margin-left:var(--rtk-space-0, 0px);display:flex}}"}},[1,"rtk-grid",{layout:[513],aspectRatio:[513,"aspect-ratio"],meeting:[16],gap:[514],size:[513],states:[16],config:[16],iconPack:[16],t:[16],gridSize:[16],overrides:[8],participants:[32],pinnedParticipants:[32],screenShareParticipants:[32],plugins:[32],emptyStage:[32],showLiveStreamPlayer:[32],canCurrentPeerHost:[32],pipSupported:[32],pipEnabled:[32],hidden:[32],roomState:[32]},void 0,{meeting:[{meetingChanged:0}],overrides:[{overridesChanged:0}],screenShareParticipants:[{screenShareParticipantsChanged:0}],plugins:[{pluginsChanged:0}],pinnedParticipants:[{pinnedParticipantsChanged:0}]}]);function w(){"undefined"!=typeof customElements&&["rtk-grid","rtk-button","rtk-controlbar-button","rtk-fullscreen-toggle","rtk-icon","rtk-livestream-indicator","rtk-livestream-player","rtk-spinner","rtk-viewer-count"].forEach((t=>{switch(t){case"rtk-grid":customElements.get(a(t))||customElements.define(a(t),C);break;case"rtk-button":customElements.get(a(t))||m();break;case"rtk-controlbar-button":customElements.get(a(t))||v();break;case"rtk-fullscreen-toggle":customElements.get(a(t))||u();break;case"rtk-icon":customElements.get(a(t))||f();break;case"rtk-livestream-indicator":customElements.get(a(t))||k();break;case"rtk-livestream-player":customElements.get(a(t))||x();break;case"rtk-spinner":customElements.get(a(t))||b();break;case"rtk-viewer-count":customElements.get(a(t))||S()}}))}y([d()],C.prototype,"meeting",void 0),y([d()],C.prototype,"states",void 0),y([d()],C.prototype,"config",void 0),y([d()],C.prototype,"iconPack",void 0),y([d()],C.prototype,"t",void 0),w();const P=C,j=w;export{P as RtkGrid,j as defineCustomElement}
@@ -1 +1 @@
1
- import{t,p as e,H as s,c as i,h as r}from"./p-BBHQOrFK.js";import{p as o,m as a}from"./p-CfIrQkMg.js";import{u as n,i as m,c as h,e as c,f as d,b as p}from"./p-DhwysA2e.js";import{R as k}from"./p-CBJjerDR.js";import"./p-DxDYE5-a.js";import{g as l}from"./p-B4dw_Fnl.js";import"./p-Dguuxuf6.js";import{i as u}from"./p-FdeAvICb.js";import{g}from"./p-DE1s0fDa.js";import{g as f}from"./p-vBfDtD_u.js";import{d as v}from"./p-BHHJ7_MS.js";import{d as b}from"./p-D6vw6bT2.js";import{d as j}from"./p-BsgKgxKu.js";import{d as E}from"./p-A83Jz8rO.js";import{d as w}from"./p-DbBGSlfQ.js";import{d as C}from"./p-Bmk8auxt.js";import{d as x}from"./p-DzDWIdoE.js";import{d as D}from"./p--CEA0NQj.js";import{d as S}from"./p-NKK4fZcP.js";import{d as y}from"./p-D_AEDHUV.js";import{d as B}from"./p-CuRSxmeD.js";import{d as P}from"./p-gixOLeKl.js";import{d as U}from"./p-BYIBbfJ8.js";import{d as M}from"./p-DZcwJOUW.js";import{d as R}from"./p-oXrlIvqH.js";import{d as I}from"./p-B1HaRABx.js";import{d as J}from"./p-DMbGWtns.js";import{d as O}from"./p-Z8VMlEx7.js";import{d as H}from"./p-BQJoMtIK.js";import{d as L}from"./p-qDy7F0Tr.js";import{d as q}from"./p-EkUCxpDZ.js";import{d as A}from"./p-B0SC1Zj-.js";import{d as K}from"./p-y_feb08f.js";import{d as z}from"./p-sSs7a3Ms.js";import{d as T}from"./p-DHSRRtn3.js";const _=e(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.statesUpdate=i(this,"rtkStatesUpdate",7),this.providerId="provider-"+Math.floor(100*Math.random()),this.roomJoinedListener=()=>{this.updateStates({meeting:"joined",preJoinError:null})},this.waitlistedListener=()=>{this.updateStates({meeting:"waiting"})},this.roomLeftListener=({state:t})=>{"disconnected"!==t&&"failed"!==t&&this.updateStates({meeting:"ended",roomLeftState:t})},this.mediaPermissionUpdateListener=({kind:t,message:e})=>{!["audio","video"].includes(t)||"DENIED"!==e&&"SYSTEM_DENIED"!==e||!0===(this.peerStore||n).state.states.activeDebugger||this.updateStates({activePermissionsMessage:{enabled:!0,kind:t}})},this.socketConnectionUpdateListener=({state:t})=>{"failed"===t&&setTimeout((()=>{this.meeting.leave("disconnected")}),this.leaveRoomTimer)},this.peerStore=null,this.loadConfigFromPreset=!1,this.applyDesignSystem=!1,this.mode="fixed",this.leaveOnUnmount=!1,this.t=m(),this.config=h(),this.gridLayout="row",this.iconPack=c,this.overrides=d,this.handleChangingMeeting=t=>{this.updateStates({activeBreakoutRoomsManager:Object.assign(Object.assign({},(this.peerStore||n).state.states.activeBreakoutRoomsManager),{destinationMeetingId:t})})}}connectedCallback(){var t;"undefined"!=typeof window&&(this.initErrorListener=t=>{const e=g(this.t,t.detail);e&&this.updateStates({preJoinError:e})},window.addEventListener("ClientError",this.initErrorListener)),this.leaveRoomTimer=1e4,this.loadConfigFromPreset=!0,this.applyDesignSystem=!0,this.setupStoreRequestListener(),this.setupStateUpdateListener(),this.meetingChanged(this.meeting),this.iconPackChanged(this.iconPack),this.tChanged(this.t),this.configChanged(this.config),this.overridesChanged(this.overrides),this.resizeObserver=new u((()=>this.handleResize())),this.resizeObserver.observe(this.host),this.applyDesignSystem&&null!=(null===(t=this.config)||void 0===t?void 0:t.designTokens)&&"undefined"!=typeof document&&!0!==(this.peerStore||n).state.states.activeDebugger&&o(document.documentElement,this.config.designTokens)}disconnectedCallback(){var t;this.leaveOnUnmount&&(null===(t=this.meeting)||void 0===t||t.leave()),this.resizeObserver.disconnect(),window.removeEventListener("ClientError",this.initErrorListener),this.storeRequestListener&&(this.host.removeEventListener("rtkRequestStore",this.storeRequestListener),this.storeRequestListener=null),this.stateUpdateListener&&(this.host.removeEventListener("rtkStateUpdate",this.stateUpdateListener),this.stateUpdateListener=null),this.meeting&&this.clearListeners(this.meeting)}setupStoreRequestListener(){this.storeRequestListener&&this.host.removeEventListener("rtkRequestStore",this.storeRequestListener),this.storeRequestListener=t=>{if(!this.peerStore)return;const e=new CustomEvent("rtkProvideStore",{detail:{store:this.peerStore,requestId:t.detail.requestId}});document.dispatchEvent(e),t.stopPropagation()},this.host.addEventListener("rtkRequestStore",this.storeRequestListener)}setupStateUpdateListener(){this.stateUpdateListener&&this.host.removeEventListener("rtkStateUpdate",this.stateUpdateListener),this.stateUpdateListener=t=>{this.host.contains(t.target)&&this.updateStates(t.detail)},this.host.addEventListener("rtkStateUpdate",this.stateUpdateListener)}clearListeners(t){t&&(t.self.removeListener("roomLeft",this.roomLeftListener),t.self.removeListener("roomJoined",this.roomJoinedListener),t.self.removeListener("waitlisted",this.waitlistedListener),t.self.removeListener("mediaPermissionUpdate",this.mediaPermissionUpdateListener),t.meta.removeListener("socketConnectionUpdate",this.socketConnectionUpdateListener))}meetingChanged(t,e){var s,i;if(!t)return;t?(this.peerStore=p({meeting:t,config:this.config,iconPack:this.iconPack,t:this.t,providerId:this.providerId,overrides:a(Object.assign({},d),this.overrides)}),document.dispatchEvent(new CustomEvent("rtkPeerStoreReady",{detail:{peerId:t.self.id}}))):this.peerStore=null;const r=this.peerStore||n;if(this.updateStates({viewType:t.meta.viewType,activeCaptions:e?!!r.state.states.activeCaptions:!!t.self.permissions.transcriptionEnabled}),this.loadConfigFromPreset&&null!=t.self.config){const e=t.self.config,{config:i,data:o}=l(e,t);this.config=i,null==this.showSetupScreen&&(this.showSetupScreen=o.showSetupScreen),(null===(s=r.state.states.activeBreakoutRoomsManager)||void 0===s?void 0:s.destinationMeetingId)&&(this.showSetupScreen=!1)}this.applyDesignSystem&&null!=(null===(i=this.config)||void 0===i?void 0:i.designTokens)&&"undefined"!=typeof document&&!0!==r.state.states.activeDebugger&&o(document.documentElement,this.config.designTokens),t.self.addListener("roomJoined",this.roomJoinedListener),t.self.addListener("waitlisted",this.waitlistedListener),t.self.addListener("roomLeft",this.roomLeftListener),t.self.addListener("mediaPermissionUpdate",this.mediaPermissionUpdateListener),t.meta.addListener("socketConnectionUpdate",this.socketConnectionUpdateListener),t.connectedMeetings.once("changingMeeting",this.handleChangingMeeting),t.self.roomJoined?this.updateStates({meeting:"joined"}):this.showSetupScreen?this.updateStates({meeting:"setup"}):t.join().then((()=>{this.updateStates({preJoinError:null})})).catch((t=>{const{message:e,code:s}=f(this.t,t);this.updateStates({preJoinError:{message:e,code:s}})})),window.removeEventListener("ClientError",this.initErrorListener)}iconPackChanged(t){this.peerStore&&(this.peerStore.state.iconPack=t)}tChanged(t){this.peerStore&&(this.peerStore.state.t=t)}configChanged(t){this.peerStore&&(this.peerStore.state.config=t),(null==t?void 0:t.designTokens)&&"undefined"!=typeof document&&!0!==(this.peerStore||n).state.states.activeDebugger&&o(document.documentElement,t.designTokens)}overridesChanged(t){this.peerStore&&(this.peerStore.state.overrides=a(Object.assign({},d),t))}handleResize(){this.size=(t=>t>=1080?"lg":t>=768?"md":"sm")(this.host.clientWidth)}updateStates(t){const e=this.peerStore||n,s=Object.assign({},e.state.states);e.state.states=a(s,t),this.statesUpdate.emit(e.state.states);const i=new CustomEvent("rtkStatesUpdate",{detail:e.state.states,bubbles:!0,composed:!0});this.host.dispatchEvent(i)}render(){const t={meeting:this.meeting,size:this.size,states:(this.peerStore||n).state.states,config:this.config||h(),iconPack:this.iconPack,t:this.t};return"CHAT"===(this.peerStore||n).state.states.viewType?r("rtk-chat",Object.assign({},t)):r(k,{element:"rtk-meeting",defaults:t,asHost:!0,elementProps:{"rtk-grid":{layout:this.gridLayout}}})}get host(){return this}static get watchers(){return{meeting:[{meetingChanged:0}],iconPack:[{iconPackChanged:0}],t:[{tChanged:0}],config:[{configChanged:0}],overrides:[{overridesChanged:0}]}}static get style(){return":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{box-sizing:border-box;display:flex;flex-direction:column;--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-1000, 8 8 8) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-900, 255 255 255 / 0.88));overflow:hidden;position:fixed;top:var(--rtk-space-0, 0px);right:var(--rtk-space-0, 0px);bottom:var(--rtk-space-0, 0px);left:var(--rtk-space-0, 0px);height:100%;width:100%}:host([mode='fill']){position:relative}"}},[1,"rtk-meeting",{loadConfigFromPreset:[1028,"load-config-from-preset"],applyDesignSystem:[1028,"apply-design-system"],mode:[513],leaveOnUnmount:[4,"leave-on-unmount"],meeting:[16],showSetupScreen:[1028,"show-setup-screen"],t:[16],config:[1040],size:[1537],gridLayout:[1,"grid-layout"],iconPack:[16],overrides:[16]},void 0,{meeting:[{meetingChanged:0}],iconPack:[{iconPackChanged:0}],t:[{tChanged:0}],config:[{configChanged:0}],overrides:[{overridesChanged:0}]}]);function F(){"undefined"!=typeof customElements&&["rtk-meeting","rtk-avatar","rtk-button","rtk-chat","rtk-chat-composer-view","rtk-chat-header","rtk-chat-messages-ui-paginated","rtk-chat-selector","rtk-draft-attachment-view","rtk-emoji-picker","rtk-emoji-picker-button","rtk-file-message-view","rtk-file-picker-button","rtk-icon","rtk-image-message-view","rtk-markdown-view","rtk-menu","rtk-menu-item","rtk-menu-list","rtk-message-view","rtk-paginated-list","rtk-pinned-message-selector","rtk-spinner","rtk-text-composer-view","rtk-text-message-view","rtk-tooltip"].forEach((e=>{switch(e){case"rtk-meeting":customElements.get(t(e))||customElements.define(t(e),_);break;case"rtk-avatar":customElements.get(t(e))||v();break;case"rtk-button":customElements.get(t(e))||b();break;case"rtk-chat":customElements.get(t(e))||j();break;case"rtk-chat-composer-view":customElements.get(t(e))||E();break;case"rtk-chat-header":customElements.get(t(e))||w();break;case"rtk-chat-messages-ui-paginated":customElements.get(t(e))||C();break;case"rtk-chat-selector":customElements.get(t(e))||x();break;case"rtk-draft-attachment-view":customElements.get(t(e))||D();break;case"rtk-emoji-picker":customElements.get(t(e))||S();break;case"rtk-emoji-picker-button":customElements.get(t(e))||y();break;case"rtk-file-message-view":customElements.get(t(e))||B();break;case"rtk-file-picker-button":customElements.get(t(e))||P();break;case"rtk-icon":customElements.get(t(e))||U();break;case"rtk-image-message-view":customElements.get(t(e))||M();break;case"rtk-markdown-view":customElements.get(t(e))||R();break;case"rtk-menu":customElements.get(t(e))||I();break;case"rtk-menu-item":customElements.get(t(e))||J();break;case"rtk-menu-list":customElements.get(t(e))||O();break;case"rtk-message-view":customElements.get(t(e))||H();break;case"rtk-paginated-list":customElements.get(t(e))||L();break;case"rtk-pinned-message-selector":customElements.get(t(e))||q();break;case"rtk-spinner":customElements.get(t(e))||A();break;case"rtk-text-composer-view":customElements.get(t(e))||K();break;case"rtk-text-message-view":customElements.get(t(e))||z();break;case"rtk-tooltip":customElements.get(t(e))||T()}}))}F();const Q=_,Z=F;export{Q as RtkMeeting,Z as defineCustomElement}
1
+ import{t,p as e,H as s,c as i,h as r}from"./p-BBHQOrFK.js";import{p as o,m as a}from"./p-CfIrQkMg.js";import{u as n,i as m,c as h,e as c,f as d,b as p}from"./p-DhwysA2e.js";import{R as k}from"./p-CBJjerDR.js";import"./p-DxDYE5-a.js";import{g as l}from"./p-B4dw_Fnl.js";import"./p-Dguuxuf6.js";import{i as u}from"./p-FdeAvICb.js";import{g}from"./p-DE1s0fDa.js";import{g as f}from"./p-vBfDtD_u.js";import{d as v}from"./p-BHHJ7_MS.js";import{d as b}from"./p-D6vw6bT2.js";import{d as j}from"./p-C0ESgBoj.js";import{d as E}from"./p-VHRH6fkb.js";import{d as w}from"./p-E1D1eNFh.js";import{d as C}from"./p-CAsupO2z.js";import{d as x}from"./p-ByPpyWt6.js";import{d as S}from"./p--CEA0NQj.js";import{d as y}from"./p-NKK4fZcP.js";import{d as D}from"./p-D_AEDHUV.js";import{d as P}from"./p-CuRSxmeD.js";import{d as B}from"./p-gixOLeKl.js";import{d as U}from"./p-BYIBbfJ8.js";import{d as R}from"./p-DZcwJOUW.js";import{d as M}from"./p-oXrlIvqH.js";import{d as H}from"./p-B1HaRABx.js";import{d as I}from"./p-DMbGWtns.js";import{d as J}from"./p-Z8VMlEx7.js";import{d as O}from"./p-BQJoMtIK.js";import{d as L}from"./p-C9UuqXCX.js";import{d as q}from"./p-BoqfUgTL.js";import{d as A}from"./p-B0SC1Zj-.js";import{d as T}from"./p-y_feb08f.js";import{d as _}from"./p-sSs7a3Ms.js";import{d as z}from"./p-DHSRRtn3.js";const F=e(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.statesUpdate=i(this,"rtkStatesUpdate",7),this.providerId="provider-"+Math.floor(100*Math.random()),this.roomJoinedListener=()=>{this.updateStates({meeting:"joined",preJoinError:null})},this.waitlistedListener=()=>{this.updateStates({meeting:"waiting"})},this.roomLeftListener=({state:t})=>{"disconnected"!==t&&"failed"!==t&&this.updateStates({meeting:"ended",roomLeftState:t})},this.mediaPermissionUpdateListener=({kind:t,message:e})=>{!["audio","video"].includes(t)||"DENIED"!==e&&"SYSTEM_DENIED"!==e||!0===(this.peerStore||n).state.states.activeDebugger||this.updateStates({activePermissionsMessage:{enabled:!0,kind:t}})},this.socketConnectionUpdateListener=({state:t})=>{"failed"===t&&setTimeout((()=>{this.meeting.leave("disconnected")}),this.leaveRoomTimer)},this.peerStore=null,this.loadConfigFromPreset=!1,this.applyDesignSystem=!1,this.mode="fixed",this.leaveOnUnmount=!1,this.t=m(),this.config=h(),this.gridLayout="row",this.iconPack=c,this.overrides=d,this.handleChangingMeeting=t=>{this.updateStates({activeBreakoutRoomsManager:Object.assign(Object.assign({},(this.peerStore||n).state.states.activeBreakoutRoomsManager),{destinationMeetingId:t})})}}connectedCallback(){var t;"undefined"!=typeof window&&(this.initErrorListener=t=>{const e=g(this.t,t.detail);e&&this.updateStates({preJoinError:e})},window.addEventListener("ClientError",this.initErrorListener)),this.leaveRoomTimer=1e4,this.loadConfigFromPreset=!0,this.applyDesignSystem=!0,this.setupStoreRequestListener(),this.setupStateUpdateListener(),this.meetingChanged(this.meeting),this.iconPackChanged(this.iconPack),this.tChanged(this.t),this.configChanged(this.config),this.overridesChanged(this.overrides),this.resizeObserver=new u((()=>this.handleResize())),this.resizeObserver.observe(this.host),this.applyDesignSystem&&null!=(null===(t=this.config)||void 0===t?void 0:t.designTokens)&&"undefined"!=typeof document&&!0!==(this.peerStore||n).state.states.activeDebugger&&o(document.documentElement,this.config.designTokens)}disconnectedCallback(){var t;this.leaveOnUnmount&&(null===(t=this.meeting)||void 0===t||t.leave()),this.resizeObserver.disconnect(),window.removeEventListener("ClientError",this.initErrorListener),this.storeRequestListener&&(this.host.removeEventListener("rtkRequestStore",this.storeRequestListener),this.storeRequestListener=null),this.stateUpdateListener&&(this.host.removeEventListener("rtkStateUpdate",this.stateUpdateListener),this.stateUpdateListener=null),this.meeting&&this.clearListeners(this.meeting)}setupStoreRequestListener(){this.storeRequestListener&&this.host.removeEventListener("rtkRequestStore",this.storeRequestListener),this.storeRequestListener=t=>{if(!this.peerStore)return;const e=new CustomEvent("rtkProvideStore",{detail:{store:this.peerStore,requestId:t.detail.requestId}});document.dispatchEvent(e),t.stopPropagation()},this.host.addEventListener("rtkRequestStore",this.storeRequestListener)}setupStateUpdateListener(){this.stateUpdateListener&&this.host.removeEventListener("rtkStateUpdate",this.stateUpdateListener),this.stateUpdateListener=t=>{this.host.contains(t.target)&&this.updateStates(t.detail)},this.host.addEventListener("rtkStateUpdate",this.stateUpdateListener)}clearListeners(t){t&&(t.self.removeListener("roomLeft",this.roomLeftListener),t.self.removeListener("roomJoined",this.roomJoinedListener),t.self.removeListener("waitlisted",this.waitlistedListener),t.self.removeListener("mediaPermissionUpdate",this.mediaPermissionUpdateListener),t.meta.removeListener("socketConnectionUpdate",this.socketConnectionUpdateListener))}meetingChanged(t,e){var s,i;if(!t)return;t?(this.peerStore=p({meeting:t,config:this.config,iconPack:this.iconPack,t:this.t,providerId:this.providerId,overrides:a(Object.assign({},d),this.overrides)}),document.dispatchEvent(new CustomEvent("rtkPeerStoreReady",{detail:{peerId:t.self.id}}))):this.peerStore=null;const r=this.peerStore||n;if(this.updateStates({viewType:t.meta.viewType,activeCaptions:e?!!r.state.states.activeCaptions:!!t.self.permissions.transcriptionEnabled}),this.loadConfigFromPreset&&null!=t.self.config){const e=t.self.config,{config:i,data:o}=l(e,t);this.config=i,null==this.showSetupScreen&&(this.showSetupScreen=o.showSetupScreen),(null===(s=r.state.states.activeBreakoutRoomsManager)||void 0===s?void 0:s.destinationMeetingId)&&(this.showSetupScreen=!1)}this.applyDesignSystem&&null!=(null===(i=this.config)||void 0===i?void 0:i.designTokens)&&"undefined"!=typeof document&&!0!==r.state.states.activeDebugger&&o(document.documentElement,this.config.designTokens),t.self.addListener("roomJoined",this.roomJoinedListener),t.self.addListener("waitlisted",this.waitlistedListener),t.self.addListener("roomLeft",this.roomLeftListener),t.self.addListener("mediaPermissionUpdate",this.mediaPermissionUpdateListener),t.meta.addListener("socketConnectionUpdate",this.socketConnectionUpdateListener),t.connectedMeetings.once("changingMeeting",this.handleChangingMeeting),t.self.roomJoined?this.updateStates({meeting:"joined"}):this.showSetupScreen?this.updateStates({meeting:"setup"}):t.join().then((()=>{this.updateStates({preJoinError:null})})).catch((t=>{const{message:e,code:s}=f(this.t,t);this.updateStates({preJoinError:{message:e,code:s}})})),window.removeEventListener("ClientError",this.initErrorListener)}iconPackChanged(t){this.peerStore&&(this.peerStore.state.iconPack=t)}tChanged(t){this.peerStore&&(this.peerStore.state.t=t)}configChanged(t){this.peerStore&&(this.peerStore.state.config=t),(null==t?void 0:t.designTokens)&&"undefined"!=typeof document&&!0!==(this.peerStore||n).state.states.activeDebugger&&o(document.documentElement,t.designTokens)}overridesChanged(t){this.peerStore&&(this.peerStore.state.overrides=a(Object.assign({},d),t))}handleResize(){this.size=(t=>t>=1080?"lg":t>=768?"md":"sm")(this.host.clientWidth)}updateStates(t){const e=this.peerStore||n,s=Object.assign({},e.state.states);e.state.states=a(s,t),this.statesUpdate.emit(e.state.states);const i=new CustomEvent("rtkStatesUpdate",{detail:e.state.states,bubbles:!0,composed:!0});this.host.dispatchEvent(i)}render(){const t={meeting:this.meeting,size:this.size,states:(this.peerStore||n).state.states,config:this.config||h(),iconPack:this.iconPack,t:this.t};return"CHAT"===(this.peerStore||n).state.states.viewType?r("rtk-chat",Object.assign({},t)):r(k,{element:"rtk-meeting",defaults:t,asHost:!0,elementProps:{"rtk-grid":{layout:this.gridLayout}}})}get host(){return this}static get watchers(){return{meeting:[{meetingChanged:0}],iconPack:[{iconPackChanged:0}],t:[{tChanged:0}],config:[{configChanged:0}],overrides:[{overridesChanged:0}]}}static get style(){return":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{box-sizing:border-box;display:flex;flex-direction:column;--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-1000, 8 8 8) / var(--tw-bg-opacity));color:rgb(var(--rtk-colors-text-900, 255 255 255 / 0.88));overflow:hidden;position:fixed;top:var(--rtk-space-0, 0px);right:var(--rtk-space-0, 0px);bottom:var(--rtk-space-0, 0px);left:var(--rtk-space-0, 0px);height:100%;width:100%}:host([mode='fill']){position:relative}"}},[1,"rtk-meeting",{loadConfigFromPreset:[1028,"load-config-from-preset"],applyDesignSystem:[1028,"apply-design-system"],mode:[513],leaveOnUnmount:[4,"leave-on-unmount"],meeting:[16],showSetupScreen:[1028,"show-setup-screen"],t:[16],config:[1040],size:[1537],gridLayout:[1,"grid-layout"],iconPack:[16],overrides:[16]},void 0,{meeting:[{meetingChanged:0}],iconPack:[{iconPackChanged:0}],t:[{tChanged:0}],config:[{configChanged:0}],overrides:[{overridesChanged:0}]}]);function K(){"undefined"!=typeof customElements&&["rtk-meeting","rtk-avatar","rtk-button","rtk-chat","rtk-chat-composer-view","rtk-chat-header","rtk-chat-messages-ui-paginated","rtk-chat-selector","rtk-draft-attachment-view","rtk-emoji-picker","rtk-emoji-picker-button","rtk-file-message-view","rtk-file-picker-button","rtk-icon","rtk-image-message-view","rtk-markdown-view","rtk-menu","rtk-menu-item","rtk-menu-list","rtk-message-view","rtk-paginated-list","rtk-pinned-message-selector","rtk-spinner","rtk-text-composer-view","rtk-text-message-view","rtk-tooltip"].forEach((e=>{switch(e){case"rtk-meeting":customElements.get(t(e))||customElements.define(t(e),F);break;case"rtk-avatar":customElements.get(t(e))||v();break;case"rtk-button":customElements.get(t(e))||b();break;case"rtk-chat":customElements.get(t(e))||j();break;case"rtk-chat-composer-view":customElements.get(t(e))||E();break;case"rtk-chat-header":customElements.get(t(e))||w();break;case"rtk-chat-messages-ui-paginated":customElements.get(t(e))||C();break;case"rtk-chat-selector":customElements.get(t(e))||x();break;case"rtk-draft-attachment-view":customElements.get(t(e))||S();break;case"rtk-emoji-picker":customElements.get(t(e))||y();break;case"rtk-emoji-picker-button":customElements.get(t(e))||D();break;case"rtk-file-message-view":customElements.get(t(e))||P();break;case"rtk-file-picker-button":customElements.get(t(e))||B();break;case"rtk-icon":customElements.get(t(e))||U();break;case"rtk-image-message-view":customElements.get(t(e))||R();break;case"rtk-markdown-view":customElements.get(t(e))||M();break;case"rtk-menu":customElements.get(t(e))||H();break;case"rtk-menu-item":customElements.get(t(e))||I();break;case"rtk-menu-list":customElements.get(t(e))||J();break;case"rtk-message-view":customElements.get(t(e))||O();break;case"rtk-paginated-list":customElements.get(t(e))||L();break;case"rtk-pinned-message-selector":customElements.get(t(e))||q();break;case"rtk-spinner":customElements.get(t(e))||A();break;case"rtk-text-composer-view":customElements.get(t(e))||T();break;case"rtk-text-message-view":customElements.get(t(e))||_();break;case"rtk-tooltip":customElements.get(t(e))||z()}}))}K();const N=F,Q=K;export{N as RtkMeeting,Q as defineCustomElement}
@@ -1 +1 @@
1
- import{p as t,H as s,w as i,h as e,t as r}from"./p-BBHQOrFK.js";import"./p-DxDYE5-a.js";import"./p-C0vp-Q7v.js";import{e as h}from"./p-DhwysA2e.js";import"./p-Dguuxuf6.js";import{S as o}from"./p-bRRQr4xn.js";import{d as a}from"./p-BYIBbfJ8.js";import{d as n}from"./p-B0SC1Zj-.js";import{d as c}from"./p-DLocSBO3.js";const l=t(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.visibleItemsCount=20,this.estimateItemSize=100,this.iconPack=h,this.isFetching=!1,this.autoScroll=!0,this.totalHeight=0,this.sizes=new Map,this.lastScrollTop=0,this.scrollToBottomRetries=0,this.elementObserver=(()=>{let t=null;const s=()=>t||("undefined"!=typeof ResizeObserver?t=new ResizeObserver((t=>{t.forEach((t=>{this.measureElement(t.target,t)}))})):null);return{disconnect:()=>{var t;return null===(t=s())||void 0===t?void 0:t.disconnect()},observe:t=>{var i;return null===(i=s())||void 0===i?void 0:i.observe(t,{box:"border-box"})},unobserve:t=>{var i;return null===(i=s())||void 0===i?void 0:i.unobserve(t)}}})(),this.measureElement=(t,s)=>{if(!t)return;const i=t.dataset.id;if(this.sizes.has(i))return void this.elementObserver.unobserve(t);if(s){const e=s.borderBoxSize[0];if(e&&e.blockSize>0)return this.saveItemSize(i,e.blockSize),void this.elementObserver.unobserve(t)}const e=t.getBoundingClientRect();e.height>0&&this.saveItemSize(i,e.height)},this.getVisibleItems=()=>this.messages.slice(this.range.start,this.range.end+1),this.updateVisibleItems=(t,s)=>{const i=this.messages.length;let e=t,r=s;i<=this.visibleItemsCount?(e=0,r=i-1):s-t<this.visibleItemsCount-1&&(e=this.range.end-this.visibleItemsCount+1),this.range.start!==e&&(this.range={start:e,end:r},this.totalHeight=this.getRangeSize(0,i))},this.getEstimatedItemSize=()=>this.estimateItemSize,this.getRangeSize=(t,s)=>{let i=0,e=0;for(let r=t;r<s;r++)e=this.sizes.get(this.messages[r].id),i+=e||this.getEstimatedItemSize();return i},this.getScrollTop=()=>this.$listRef?Math.ceil(this.$listRef.scrollTop):0,this.getClientHeight=()=>this.$listRef?Math.ceil(this.$listRef.clientHeight):0,this.getScrollHeight=()=>this.$listRef?Math.ceil(this.$listRef.scrollHeight):0,this.getItemsScrolled=()=>{const t=this.lastScrollTop;if(t<=0)return 0;let s=0,i=0,e=0,r=this.messages.length;for(;s<=r;){if(i=s+r>>>1,e=this.getRangeSize(0,i),e===t)return i;e<t?s=i+1:e>t&&(r=i-1)}return s>0?--s:0},this.getEndByStart=t=>Math.min(t+this.visibleItemsCount,this.messages.length-1),this.scrollToOffset=t=>{this.$listRef&&(this.$listRef.scrollTop=t)},this.scrollToIndex=t=>{if(t>=this.messages.length-1)this.scrollToBottom();else{const s=t<1?0:this.getRangeSize(0,t);this.scrollToOffset(s)}},this.scrollToBottom=()=>{this.$listEndRef&&i((()=>{this.$listEndRef.scrollIntoView(),this.getScrollHeight()-(this.getScrollTop()+this.getClientHeight())>0&&this.scrollToBottomRetries<10?setTimeout((()=>{this.scrollToBottom()}),1e3/60):(this.scrollToBottomRetries=0,this.autoScroll=!0)}))},this.handleScroll=async()=>{if(this.isFetching)return;const t=this.getScrollTop(),s=t<this.lastScrollTop||0===t?"UP":"DOWN";if(this.lastScrollTop=t,this.loadMore&&0===t&&"UP"===s&&!1===this.isFetching){this.isFetching=!0;const t=await this.loadMore(this.messages[0]);t&&t.length&&(this.messages=[...t,...this.messages]),this.isFetching=!1}"UP"===s?this.handleTop():"DOWN"===s&&this.handleBottom()},this.handleTop=()=>{const t=this.getItemsScrolled();if(t<=this.range.end-5&&(this.autoScroll=!1),t>this.range.start+5)return;const s=Math.max(this.range.start-5,0);this.updateVisibleItems(s,this.getEndByStart(s))},this.handleBottom=()=>{if(this.getItemsScrolled()<this.range.start+5)return;const t=this.range.start+5,s=this.getEndByStart(t);this.updateVisibleItems(s===this.messages.length-1?s-this.visibleItemsCount:t,s)},this.updateTotalHeight=c((()=>{this.totalHeight=this.getRangeSize(0,this.messages.length)}),1e3/30,{leading:!0}),this.rendererInternal=(t,s,i)=>{if(!t)return;if(t.dataset.id===s.id)return;const e=this.renderer(s,i);t.hasChildNodes&&(t.innerHTML=""),this.elementObserver.observe(t),t.dataset.id=s.id,t.appendChild(e)}}connectedCallback(){const t=this.messages.length-1;this.range={start:t-this.visibleItemsCount,end:t},this.updateVisibleItems(this.range.start,this.range.end),this.totalHeight=this.getRangeSize(0,t)}componentDidLoad(){this.autoScroll&&this.scrollToBottom()}messagesUpdated(t,s){if(t.length>s.length){const i=t.length-s.length;this.updateVisibleItems(i,this.getEndByStart(i)),this.scrollToIndex(this.range.start)}}saveItemSize(t,s){this.sizes.set(t,Math.round(s)),this.updateTotalHeight()}render(){return e("div",{key:"6564a301cf646ed53993d924111206cf4a382833",class:"scrollbar content-wrapper",ref:t=>this.$listRef=t,onScroll:this.handleScroll},e("div",{key:"81469bde1e421f0a881c3ad33b30a601fc54901c",class:"scroller"},e("div",{key:"5e0c8dd617aa7ed5517cde108539dc23265a29e2",style:{height:this.totalHeight+"px"}}),e("div",{key:"f994d2627b4787f803b9c7ac00f574dbd034f924",class:"smallest-dom-element",id:"list-end",ref:t=>this.$listEndRef=t})),e("div",{key:"4de62649e894f024ecb7d5767f6eefc702544964",class:"content",style:{transform:`translateY(${this.getRangeSize(0,this.range.start)}px)`}},this.isFetching&&e("div",{key:"dfa9a9abbc190896f80aa90191ab654fee7b7d8f",class:"loader"},e("rtk-spinner",{key:"416b800f9d481689860340aff00fe30f30255603",size:"md"})),this.getVisibleItems().map(((t,s)=>e("div",{key:t.id,ref:i=>this.rendererInternal(i,t,s)})))))}static get watchers(){return{messages:[{messagesUpdated:0}]}}static get style(){return":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)}.scrollbar{scrollbar-width:thin;scrollbar-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60))) 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)))}.loading{cursor:wait}.content-wrapper{height:100%;overflow-y:auto;position:relative;contain:strict}.scroller{width:1px;opacity:0}.content{position:absolute;top:0;width:100%}.smallest-dom-element{width:100%;height:2px;background:red}.loader{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);display:flex;justify-content:center}"}},[0,"rtk-message-list-view",{messages:[16],renderer:[16],loadMore:[16],visibleItemsCount:[2,"visible-items-count"],estimateItemSize:[2,"estimate-item-size"],iconPack:[16],range:[32],isFetching:[32],autoScroll:[32],totalHeight:[32]},void 0,{messages:[{messagesUpdated:0}]}]);function d(){"undefined"!=typeof customElements&&["rtk-message-list-view","rtk-icon","rtk-spinner"].forEach((t=>{switch(t){case"rtk-message-list-view":customElements.get(r(t))||customElements.define(r(t),l);break;case"rtk-icon":customElements.get(r(t))||a();break;case"rtk-spinner":customElements.get(r(t))||n()}}))}(function(t,s,i,e){var r,h=arguments.length,o=h<3?s:null===e?e=Object.getOwnPropertyDescriptor(s,i):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,s,i,e);else for(var a=t.length-1;a>=0;a--)(r=t[a])&&(o=(h<3?r(o):h>3?r(s,i,o):r(s,i))||o);h>3&&o&&Object.defineProperty(s,i,o)})([o()],l.prototype,"iconPack",void 0),d();const f=l,p=d;export{f as RtkMessageListView,p as defineCustomElement}
1
+ import{p as t,H as s,w as i,h as e,t as r}from"./p-BBHQOrFK.js";import"./p-DxDYE5-a.js";import"./p-C0vp-Q7v.js";import{e as h}from"./p-DhwysA2e.js";import"./p-Dguuxuf6.js";import{S as a}from"./p-bRRQr4xn.js";import{d as o}from"./p-BYIBbfJ8.js";import{d as n}from"./p-B0SC1Zj-.js";import{d as c}from"./p-DLocSBO3.js";const l=t(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.visibleItemsCount=20,this.estimateItemSize=100,this.iconPack=h,this.isFetching=!1,this.autoScroll=!0,this.totalHeight=0,this.sizes=new Map,this.lastScrollTop=0,this.scrollToBottomRetries=0,this.elementObserver=(()=>{let t=null;const s=()=>t||("undefined"!=typeof ResizeObserver?t=new ResizeObserver((t=>{t.forEach((t=>{this.measureElement(t.target,t)}))})):null);return{disconnect:()=>{var t;return null===(t=s())||void 0===t?void 0:t.disconnect()},observe:t=>{var i;return null===(i=s())||void 0===i?void 0:i.observe(t,{box:"border-box"})},unobserve:t=>{var i;return null===(i=s())||void 0===i?void 0:i.unobserve(t)}}})(),this.measureElement=(t,s)=>{if(!t)return;const i=t.dataset.id;if(this.sizes.has(i))return void this.elementObserver.unobserve(t);if(s){const e=s.borderBoxSize[0];if(e&&e.blockSize>0)return this.saveItemSize(i,e.blockSize),void this.elementObserver.unobserve(t)}const e=t.getBoundingClientRect();e.height>0&&this.saveItemSize(i,e.height)},this.getVisibleItems=()=>this.messages.slice(this.range.start,this.range.end+1),this.updateVisibleItems=(t,s)=>{const i=this.messages.length;let e=t,r=s;i<=this.visibleItemsCount?(e=0,r=i-1):s-t<this.visibleItemsCount-1&&(e=this.range.end-this.visibleItemsCount+1),this.range.start!==e&&(this.range={start:e,end:r},this.totalHeight=this.getRangeSize(0,i))},this.getEstimatedItemSize=()=>this.estimateItemSize,this.getRangeSize=(t,s)=>{let i=0,e=0;for(let r=t;r<s;r++)e=this.sizes.get(this.messages[r].id),i+=e||this.getEstimatedItemSize();return i},this.getScrollTop=()=>this.$listRef?Math.ceil(this.$listRef.scrollTop):0,this.getClientHeight=()=>this.$listRef?Math.ceil(this.$listRef.clientHeight):0,this.getScrollHeight=()=>this.$listRef?Math.ceil(this.$listRef.scrollHeight):0,this.getItemsScrolled=()=>{const t=this.lastScrollTop;if(t<=0)return 0;let s=0,i=0,e=0,r=this.messages.length;for(;s<=r;){if(i=s+r>>>1,e=this.getRangeSize(0,i),e===t)return i;e<t?s=i+1:e>t&&(r=i-1)}return s>0?--s:0},this.getEndByStart=t=>Math.min(t+this.visibleItemsCount,this.messages.length-1),this.scrollToOffset=t=>{this.$listRef&&(this.$listRef.scrollTop=t)},this.scrollToIndex=t=>{if(t>=this.messages.length-1)this.scrollToBottom();else{const s=t<1?0:this.getRangeSize(0,t);this.scrollToOffset(s)}},this.scrollToBottom=()=>{this.$listEndRef&&i((()=>{this.$listEndRef.scrollIntoView(),this.getScrollHeight()-(this.getScrollTop()+this.getClientHeight())>0&&this.scrollToBottomRetries<10?setTimeout((()=>{this.scrollToBottom()}),1e3/60):(this.scrollToBottomRetries=0,this.autoScroll=!0)}))},this.handleScroll=async()=>{if(this.isFetching)return;const t=this.getScrollTop(),s=t<this.lastScrollTop||0===t?"UP":"DOWN";if(this.lastScrollTop=t,this.loadMore&&0===t&&"UP"===s&&!1===this.isFetching){this.isFetching=!0;const t=await this.loadMore(this.messages[0]);t&&t.length&&(this.messages=[...t,...this.messages]),this.isFetching=!1}"UP"===s?this.handleTop():"DOWN"===s&&this.handleBottom()},this.handleTop=()=>{const t=this.getItemsScrolled();if(t<=this.range.end-5&&(this.autoScroll=!1),t>this.range.start+5)return;const s=Math.max(this.range.start-5,0);this.updateVisibleItems(s,this.getEndByStart(s))},this.handleBottom=()=>{if(this.getItemsScrolled()<this.range.start+5)return;const t=this.range.start+5,s=this.getEndByStart(t);this.updateVisibleItems(s===this.messages.length-1?s-this.visibleItemsCount:t,s)},this.updateTotalHeight=c((()=>{this.totalHeight=this.getRangeSize(0,this.messages.length)}),1e3/30,{leading:!0}),this.rendererInternal=(t,s,i)=>{if(!t)return;if(t.dataset.id===s.id)return;const e=this.renderer(s,i);t.hasChildNodes&&(t.innerHTML=""),this.elementObserver.observe(t),t.dataset.id=s.id,t.appendChild(e)}}connectedCallback(){const t=this.messages.length-1;this.range={start:t-this.visibleItemsCount,end:t},this.updateVisibleItems(this.range.start,this.range.end),this.totalHeight=this.getRangeSize(0,t)}componentDidLoad(){this.autoScroll&&this.scrollToBottom()}messagesUpdated(t,s){if(t.length>s.length){const i=t.length-s.length;this.updateVisibleItems(i,this.getEndByStart(i)),this.scrollToIndex(this.range.start)}}saveItemSize(t,s){this.sizes.set(t,Math.round(s)),this.updateTotalHeight()}render(){return e("div",{key:"8da5ac7ee83f43da54ce1af023e178d206436b80",class:"scrollbar content-wrapper",ref:t=>this.$listRef=t,onScroll:this.handleScroll},e("div",{key:"3aeec25e25aeb2864b7ce0d68a08d58bb2b63cef",class:"scroller"},e("div",{key:"b65b2fb4471307f38c08480d268adfaafdb696fb",style:{height:this.totalHeight+"px"}}),e("div",{key:"08aa1dcf4740ce438b152527e8d60aff28704e8a",class:"smallest-dom-element",id:"list-end",ref:t=>this.$listEndRef=t})),e("div",{key:"48ba3788f83f2329174fb3ddd107eaf4da91699a",class:"content",style:{transform:`translateY(${this.getRangeSize(0,this.range.start)}px)`}},this.isFetching&&e("div",{key:"1a53b6b02899df6ce80c781b44fcd71802105fdf",class:"loader"},e("rtk-spinner",{key:"222bdf5ad19f45914f48c91afb65075e3fef277f",size:"md"})),this.getVisibleItems().map(((t,s)=>e("div",{key:t.id,ref:i=>this.rendererInternal(i,t,s)})))))}static get watchers(){return{messages:[{messagesUpdated:0}]}}static get style(){return":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)}.scrollbar{scrollbar-width:thin;scrollbar-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60))) 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)))}.loading{cursor:wait}.content-wrapper{height:100%;overflow-y:auto;position:relative;contain:strict}.scroller{width:1px;opacity:0}.content{position:absolute;top:0;width:100%}.smallest-dom-element{width:100%;height:2px;background:red}.loader{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);display:flex;justify-content:center}"}},[0,"rtk-message-list-view",{messages:[16],renderer:[16],loadMore:[16],visibleItemsCount:[2,"visible-items-count"],estimateItemSize:[2,"estimate-item-size"],iconPack:[16],range:[32],isFetching:[32],autoScroll:[32],totalHeight:[32]},void 0,{messages:[{messagesUpdated:0}]}]);function d(){"undefined"!=typeof customElements&&["rtk-message-list-view","rtk-icon","rtk-spinner"].forEach((t=>{switch(t){case"rtk-message-list-view":customElements.get(r(t))||customElements.define(r(t),l);break;case"rtk-icon":customElements.get(r(t))||o();break;case"rtk-spinner":customElements.get(r(t))||n()}}))}(function(t,s,i,e){var r,h=arguments.length,a=h<3?s:null===e?e=Object.getOwnPropertyDescriptor(s,i):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,s,i,e);else for(var o=t.length-1;o>=0;o--)(r=t[o])&&(a=(h<3?r(a):h>3?r(s,i,a):r(s,i))||a);h>3&&a&&Object.defineProperty(s,i,a)})([a()],l.prototype,"iconPack",void 0),d();const f=l,p=d;export{f as RtkMessageListView,p as defineCustomElement}
@@ -1 +1 @@
1
- import{R as o,d as r}from"./p-qDy7F0Tr.js";const s=o,p=r;export{s as RtkPaginatedList,p as defineCustomElement}
1
+ import{R as o,d as s}from"./p-C9UuqXCX.js";const p=o,r=s;export{p as RtkPaginatedList,r as defineCustomElement}
@@ -1 +1 @@
1
- import{p as t,H as r,c as s,h as a,d as i,t as e}from"./p-BBHQOrFK.js";import{c as o,e as n,i as p}from"./p-DhwysA2e.js";import"./p-DxDYE5-a.js";import"./p-C0vp-Q7v.js";import"./p-Dguuxuf6.js";import{S as c}from"./p-bRRQr4xn.js";import{d as l}from"./p-BHHJ7_MS.js";import{d as h}from"./p-D6vw6bT2.js";import{d}from"./p-BYIBbfJ8.js";import{d as m}from"./p-DMbGWtns.js";import{d as u}from"./p-Z8VMlEx7.js";import{d as b}from"./p--VK1POSX.js";import{d as g}from"./p-Bf-vQ6U9.js";import{d as k}from"./p-93ZUKlQ1.js";import{d as v}from"./p-Bf-HIBwL.js";import{d as f}from"./p-DdSpe6Sb.js";import{d as x}from"./p-l-tiOHlG.js";import{d as E}from"./p-B0SC1Zj-.js";import{d as w}from"./p-DHSRRtn3.js";import{d as T}from"./p-BbJzI1u1.js";import{d as j}from"./p-DLocSBO3.js";var S=function(t,r,s,a){var i,e=arguments.length,o=e<3?r:null===a?a=Object.getOwnPropertyDescriptor(r,s):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,r,s,a);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(o=(e<3?i(o):e>3?i(r,s,o):i(r,s))||o);return e>3&&o&&Object.defineProperty(r,s,o),o};const y=t(class extends r{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.stateUpdate=s(this,"rtkStateUpdate",7),this.config=o(),this.iconPack=n,this.defaultParticipantsTabId="stage-list",this.t=p(),this.currentParticipantsTabId=this.defaultParticipantsTabId,this.tabs=[],this.hasRequests=!1,this.search="",this.updateParticipantCountsInTabs=j((()=>{var t;let r=(null===(t=this.meeting.participants.waitlisted)||void 0===t?void 0:t.size)||0,s=0,i=0;this.meeting.participants.joined.toArray().forEach((t=>{"ON_STAGE"===t.stageStatus&&s++,"OFF_STAGE"===t.stageStatus&&i++,"REQUESTED_TO_JOIN_STAGE"===t.stageStatus&&(r++,i++),"ACCEPTED_TO_JOIN_STAGE"===t.stageStatus&&i++})),"ON_STAGE"===this.meeting.self.stageStatus&&s++,"OFF_STAGE"===this.meeting.self.stageStatus&&i++,"REQUESTED_TO_JOIN_STAGE"===this.meeting.self.stageStatus&&(r++,i++),"ACCEPTED_TO_JOIN_STAGE"===this.meeting.self.stageStatus&&i++;const e=[];this.shouldShowRequestsTab()&&e.push({id:"requests",name:a("span",null,this.t("requests")," ",a("span",{class:`tab-participant-count-badge ${r>0?"requests-pending":""} ${"requests"===this.currentParticipantsTabId?"selected-tab":""}`},r))}),e.push({id:"stage-list",name:a("span",null,this.t("participants")," ",a("span",{class:"tab-participant-count-badge "+("stage-list"===this.currentParticipantsTabId?"selected-tab":"")},s))}),this.shouldShowViewersTab()&&e.push({id:"viewer-list",name:a("span",null,this.t("viewers")," ",a("span",{class:"tab-participant-count-badge "+("viewer-list"===this.currentParticipantsTabId?"selected-tab":"")},i))}),this.tabs=e,this.hasRequests=r>0})),this.onSearchInput=t=>{this.search=t.target.value},this.shouldShowViewersTab=()=>{var t,r,s;return null===(s=null===(r=null===(t=this.meeting)||void 0===t?void 0:t.self)||void 0===r?void 0:r.permissions)||void 0===s?void 0:s.stageEnabled},this.shouldShowRequestsTab=()=>{var t;let r=!1;return r="LIVESTREAM"!==this.meeting.meta.viewType&&(null===(t=this.meeting.self.config.waitingRoom)||void 0===t?void 0:t.isEnabled)&&this.meeting.self.permissions.acceptWaitingRequests,this.meeting.self.permissions.stageEnabled&&this.meeting.self.permissions.acceptStageRequests||r},this.viewSection=t=>{this.currentParticipantsTabId=t}}connectedCallback(){this.meetingChanged(this.meeting)}disconnectedCallback(){this.meeting&&(this.meeting.participants.joined.off("participantJoined",this.updateParticipantCountsInTabs),this.meeting.participants.joined.off("participantsUpdate",this.updateParticipantCountsInTabs),this.meeting.participants.joined.off("participantLeft",this.updateParticipantCountsInTabs),this.meeting.participants.joined.off("stageStatusUpdate",this.updateParticipantCountsInTabs),this.meeting.stage.off("stageStatusUpdate",this.updateParticipantCountsInTabs),this.meeting.participants.waitlisted.off("participantJoined",this.updateParticipantCountsInTabs),this.meeting.participants.waitlisted.off("participantLeft",this.updateParticipantCountsInTabs),this.meeting.participants.waitlisted.off("stageStatusUpdate",this.updateParticipantCountsInTabs))}meetingChanged(t){t&&(t.participants.joined.on("participantJoined",this.updateParticipantCountsInTabs),t.participants.joined.on("participantsUpdate",this.updateParticipantCountsInTabs),t.participants.joined.on("participantLeft",this.updateParticipantCountsInTabs),t.participants.joined.on("stageStatusUpdate",this.updateParticipantCountsInTabs),t.stage.on("stageStatusUpdate",this.updateParticipantCountsInTabs),t.participants.waitlisted.on("participantJoined",this.updateParticipantCountsInTabs),t.participants.waitlisted.on("participantLeft",this.updateParticipantCountsInTabs),t.participants.waitlisted.on("stageStatusUpdate",this.updateParticipantCountsInTabs),this.updateParticipantCountsInTabs())}currentParticipantsTabIdChanged(){this.stateUpdate.emit({participantsTabId:this.currentParticipantsTabId}),this.updateParticipantCountsInTabs()}render(){if(!this.meeting)return null;const t={meeting:this.meeting,states:this.states,config:this.config,size:this.size,iconPack:this.iconPack,t:this.t};return a(i,null,a("div",{class:"search",part:"search"},a("rtk-icon",{icon:this.iconPack.search,part:"search-icon"}),a("input",{type:"search",autocomplete:"off",placeholder:this.t("search"),onInput:this.onSearchInput,part:"search-input"})),a("slot",{name:"start"}),a("div",{class:"ctr scrollbar "+("requests"!==this.currentParticipantsTabId?"virtualised":""),part:"container"},a("rtk-sidebar-ui",{tabs:this.tabs,currentTab:this.currentParticipantsTabId,view:"full-screen",hideHeader:!0,hideCloseAction:!0,style:{position:"relative"},onTabChange:t=>{this.viewSection(t.detail),t.stopPropagation()}},(!this.currentParticipantsTabId||"stage-list"===this.currentParticipantsTabId)&&a("div",{slot:"stage-list",style:{marginTop:"10px",height:"100%"}},a("rtk-participants-stage-list",Object.assign({},t,{search:this.search,hideHeader:!0}))),"requests"===this.currentParticipantsTabId&&a("div",{slot:"requests",style:{marginTop:"10px",height:"100%"}},!this.hasRequests&&a("div",{class:"no-pending-requests"},this.t("participants.no_pending_requests")),a("rtk-participants-stage-queue",Object.assign({},t)),a("rtk-participants-waiting-list",Object.assign({},t))),"viewer-list"===this.currentParticipantsTabId&&a("div",{slot:"viewer-list",style:{marginTop:"10px",height:"100%"}},a("rtk-participants-viewer-list",Object.assign({},t,{search:this.search,hideHeader:!0}))))),a("slot",{name:"end"}))}static get watchers(){return{meeting:[{meetingChanged:0}],currentParticipantsTabId:[{currentParticipantsTabIdChanged:0}]}}static get style(){return":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)}.scrollbar{scrollbar-width:thin;scrollbar-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60))) 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{display:flex;height:100%;width:100%;flex-direction:column;font-size:14px}*{box-sizing:border-box}.ctr{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);box-sizing:border-box;padding-left:var(--rtk-space-3, 12px);padding-right:var(--rtk-space-3, 12px);padding-top:var(--rtk-space-0, 0px);padding-bottom:var(--rtk-space-0, 0px);overflow-y:auto;flex-grow:1;flex-basis:0}.ctr.virtualised{overflow-y:hidden}.search{position:sticky;box-sizing:border-box;display:flex;align-items:center;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));margin-left:var(--rtk-space-3, 12px);margin-right:var(--rtk-space-3, 12px);margin-top:var(--rtk-space-0, 0px);margin-bottom:var(--rtk-space-0, 0px)}.search rtk-icon{margin-left:var(--rtk-space-2, 8px);margin-right:var(--rtk-space-2, 8px);height:var(--rtk-space-5, 20px);width:var(--rtk-space-5, 20px);color:rgb(var(--rtk-colors-text-600, 255 255 255 / 0.52))}.search input{box-sizing:border-box;height:var(--rtk-space-9, 36px);width:100%;padding-right:var(--rtk-space-2, 8px);border-width:var(--rtk-border-width-none, 0);border-style:none;--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-1000, 255 255 255));outline:2px solid transparent;outline-offset:2px;border-radius:var(--rtk-border-radius-sm, 4px);font-size:14px}.search input::-moz-placeholder{color:rgb(var(--rtk-colors-text-800, 255 255 255 / 0.76))}.search input::placeholder{color:rgb(var(--rtk-colors-text-800, 255 255 255 / 0.76))}:host([size='md']) .search{margin-top:var(--rtk-space-4, 16px) !important;margin-bottom:var(--rtk-space-4, 16px) !important}:host([size='sm']) .search{margin-top:var(--rtk-space-4, 16px) !important;margin-bottom:var(--rtk-space-4, 16px) !important}.no-pending-requests{margin-top:var(--rtk-space-4, 16px);margin-bottom:var(--rtk-space-4, 16px);text-align:center;font-size:12px;color:rgb(var(--rtk-colors-text-700, 255 255 255 / 0.64))}"}},[257,"rtk-participants",{meeting:[16],states:[16],config:[16],size:[513],iconPack:[16],defaultParticipantsTabId:[1,"default-participants-tab-id"],t:[16],currentParticipantsTabId:[32],tabs:[32],hasRequests:[32],search:[32]},void 0,{meeting:[{meetingChanged:0}],currentParticipantsTabId:[{currentParticipantsTabIdChanged:0}]}]);function O(){"undefined"!=typeof customElements&&["rtk-participants","rtk-avatar","rtk-button","rtk-icon","rtk-menu-item","rtk-menu-list","rtk-participant","rtk-participants-stage-list","rtk-participants-stage-queue","rtk-participants-viewer-list","rtk-participants-waiting-list","rtk-sidebar-ui","rtk-spinner","rtk-tooltip","rtk-virtualized-participant-list"].forEach((t=>{switch(t){case"rtk-participants":customElements.get(e(t))||customElements.define(e(t),y);break;case"rtk-avatar":customElements.get(e(t))||l();break;case"rtk-button":customElements.get(e(t))||h();break;case"rtk-icon":customElements.get(e(t))||d();break;case"rtk-menu-item":customElements.get(e(t))||m();break;case"rtk-menu-list":customElements.get(e(t))||u();break;case"rtk-participant":customElements.get(e(t))||b();break;case"rtk-participants-stage-list":customElements.get(e(t))||g();break;case"rtk-participants-stage-queue":customElements.get(e(t))||k();break;case"rtk-participants-viewer-list":customElements.get(e(t))||v();break;case"rtk-participants-waiting-list":customElements.get(e(t))||f();break;case"rtk-sidebar-ui":customElements.get(e(t))||x();break;case"rtk-spinner":customElements.get(e(t))||E();break;case"rtk-tooltip":customElements.get(e(t))||w();break;case"rtk-virtualized-participant-list":customElements.get(e(t))||T()}}))}S([c()],y.prototype,"meeting",void 0),S([c()],y.prototype,"states",void 0),S([c()],y.prototype,"config",void 0),S([c()],y.prototype,"iconPack",void 0),S([c()],y.prototype,"t",void 0),O();const _=y,I=O;export{_ as RtkParticipants,I as defineCustomElement}
1
+ import{p as t,H as r,c as s,h as a,d as i,t as e}from"./p-BBHQOrFK.js";import{c as o,e as n,i as p}from"./p-DhwysA2e.js";import"./p-DxDYE5-a.js";import"./p-C0vp-Q7v.js";import"./p-Dguuxuf6.js";import{S as c}from"./p-bRRQr4xn.js";import{d as l}from"./p-BHHJ7_MS.js";import{d as h}from"./p-D6vw6bT2.js";import{d}from"./p-BYIBbfJ8.js";import{d as m}from"./p-DMbGWtns.js";import{d as u}from"./p-Z8VMlEx7.js";import{d as b}from"./p--VK1POSX.js";import{d as g}from"./p-Bf-vQ6U9.js";import{d as k}from"./p-93ZUKlQ1.js";import{d as v}from"./p-Bf-HIBwL.js";import{d as f}from"./p-DdSpe6Sb.js";import{d as x}from"./p-Ryaxu6vl.js";import{d as E}from"./p-B0SC1Zj-.js";import{d as w}from"./p-DHSRRtn3.js";import{d as T}from"./p-BbJzI1u1.js";import{d as j}from"./p-DLocSBO3.js";var S=function(t,r,s,a){var i,e=arguments.length,o=e<3?r:null===a?a=Object.getOwnPropertyDescriptor(r,s):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,r,s,a);else for(var n=t.length-1;n>=0;n--)(i=t[n])&&(o=(e<3?i(o):e>3?i(r,s,o):i(r,s))||o);return e>3&&o&&Object.defineProperty(r,s,o),o};const y=t(class extends r{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.stateUpdate=s(this,"rtkStateUpdate",7),this.config=o(),this.iconPack=n,this.defaultParticipantsTabId="stage-list",this.t=p(),this.currentParticipantsTabId=this.defaultParticipantsTabId,this.tabs=[],this.hasRequests=!1,this.search="",this.updateParticipantCountsInTabs=j((()=>{var t;let r=(null===(t=this.meeting.participants.waitlisted)||void 0===t?void 0:t.size)||0,s=0,i=0;this.meeting.participants.joined.toArray().forEach((t=>{"ON_STAGE"===t.stageStatus&&s++,"OFF_STAGE"===t.stageStatus&&i++,"REQUESTED_TO_JOIN_STAGE"===t.stageStatus&&(r++,i++),"ACCEPTED_TO_JOIN_STAGE"===t.stageStatus&&i++})),"ON_STAGE"===this.meeting.self.stageStatus&&s++,"OFF_STAGE"===this.meeting.self.stageStatus&&i++,"REQUESTED_TO_JOIN_STAGE"===this.meeting.self.stageStatus&&(r++,i++),"ACCEPTED_TO_JOIN_STAGE"===this.meeting.self.stageStatus&&i++;const e=[];this.shouldShowRequestsTab()&&e.push({id:"requests",name:a("span",null,this.t("requests")," ",a("span",{class:`tab-participant-count-badge ${r>0?"requests-pending":""} ${"requests"===this.currentParticipantsTabId?"selected-tab":""}`},r))}),e.push({id:"stage-list",name:a("span",null,this.t("participants")," ",a("span",{class:"tab-participant-count-badge "+("stage-list"===this.currentParticipantsTabId?"selected-tab":"")},s))}),this.shouldShowViewersTab()&&e.push({id:"viewer-list",name:a("span",null,this.t("viewers")," ",a("span",{class:"tab-participant-count-badge "+("viewer-list"===this.currentParticipantsTabId?"selected-tab":"")},i))}),this.tabs=e,this.hasRequests=r>0})),this.onSearchInput=t=>{this.search=t.target.value},this.shouldShowViewersTab=()=>{var t,r,s;return null===(s=null===(r=null===(t=this.meeting)||void 0===t?void 0:t.self)||void 0===r?void 0:r.permissions)||void 0===s?void 0:s.stageEnabled},this.shouldShowRequestsTab=()=>{var t;let r=!1;return r="LIVESTREAM"!==this.meeting.meta.viewType&&(null===(t=this.meeting.self.config.waitingRoom)||void 0===t?void 0:t.isEnabled)&&this.meeting.self.permissions.acceptWaitingRequests,this.meeting.self.permissions.stageEnabled&&this.meeting.self.permissions.acceptStageRequests||r},this.viewSection=t=>{this.currentParticipantsTabId=t}}connectedCallback(){this.meetingChanged(this.meeting)}disconnectedCallback(){this.meeting&&(this.meeting.participants.joined.off("participantJoined",this.updateParticipantCountsInTabs),this.meeting.participants.joined.off("participantsUpdate",this.updateParticipantCountsInTabs),this.meeting.participants.joined.off("participantLeft",this.updateParticipantCountsInTabs),this.meeting.participants.joined.off("stageStatusUpdate",this.updateParticipantCountsInTabs),this.meeting.stage.off("stageStatusUpdate",this.updateParticipantCountsInTabs),this.meeting.participants.waitlisted.off("participantJoined",this.updateParticipantCountsInTabs),this.meeting.participants.waitlisted.off("participantLeft",this.updateParticipantCountsInTabs),this.meeting.participants.waitlisted.off("stageStatusUpdate",this.updateParticipantCountsInTabs))}meetingChanged(t){t&&(t.participants.joined.on("participantJoined",this.updateParticipantCountsInTabs),t.participants.joined.on("participantsUpdate",this.updateParticipantCountsInTabs),t.participants.joined.on("participantLeft",this.updateParticipantCountsInTabs),t.participants.joined.on("stageStatusUpdate",this.updateParticipantCountsInTabs),t.stage.on("stageStatusUpdate",this.updateParticipantCountsInTabs),t.participants.waitlisted.on("participantJoined",this.updateParticipantCountsInTabs),t.participants.waitlisted.on("participantLeft",this.updateParticipantCountsInTabs),t.participants.waitlisted.on("stageStatusUpdate",this.updateParticipantCountsInTabs),this.updateParticipantCountsInTabs())}currentParticipantsTabIdChanged(){this.stateUpdate.emit({participantsTabId:this.currentParticipantsTabId}),this.updateParticipantCountsInTabs()}render(){if(!this.meeting)return null;const t={meeting:this.meeting,states:this.states,config:this.config,size:this.size,iconPack:this.iconPack,t:this.t};return a(i,null,a("div",{class:"search",part:"search"},a("rtk-icon",{icon:this.iconPack.search,part:"search-icon"}),a("input",{type:"search",autocomplete:"off",placeholder:this.t("search"),onInput:this.onSearchInput,part:"search-input"})),a("slot",{name:"start"}),a("div",{class:"ctr scrollbar "+("requests"!==this.currentParticipantsTabId?"virtualised":""),part:"container"},a("rtk-sidebar-ui",{tabs:this.tabs,currentTab:this.currentParticipantsTabId,view:"full-screen",hideHeader:!0,hideCloseAction:!0,style:{position:"relative"},onTabChange:t=>{this.viewSection(t.detail),t.stopPropagation()}},(!this.currentParticipantsTabId||"stage-list"===this.currentParticipantsTabId)&&a("div",{slot:"stage-list",style:{marginTop:"10px",height:"100%"}},a("rtk-participants-stage-list",Object.assign({},t,{search:this.search,hideHeader:!0}))),"requests"===this.currentParticipantsTabId&&a("div",{slot:"requests",style:{marginTop:"10px",height:"100%"}},!this.hasRequests&&a("div",{class:"no-pending-requests"},this.t("participants.no_pending_requests")),a("rtk-participants-stage-queue",Object.assign({},t)),a("rtk-participants-waiting-list",Object.assign({},t))),"viewer-list"===this.currentParticipantsTabId&&a("div",{slot:"viewer-list",style:{marginTop:"10px",height:"100%"}},a("rtk-participants-viewer-list",Object.assign({},t,{search:this.search,hideHeader:!0}))))),a("slot",{name:"end"}))}static get watchers(){return{meeting:[{meetingChanged:0}],currentParticipantsTabId:[{currentParticipantsTabIdChanged:0}]}}static get style(){return":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)}.scrollbar{scrollbar-width:thin;scrollbar-color:var(--rtk-scrollbar-color, rgb(var(--rtk-colors-background-600, 60 60 60))) 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{display:flex;height:100%;width:100%;flex-direction:column;font-size:14px}*{box-sizing:border-box}.ctr{margin-top:var(--rtk-space-2, 8px);margin-bottom:var(--rtk-space-2, 8px);box-sizing:border-box;padding-left:var(--rtk-space-3, 12px);padding-right:var(--rtk-space-3, 12px);padding-top:var(--rtk-space-0, 0px);padding-bottom:var(--rtk-space-0, 0px);overflow-y:auto;flex-grow:1;flex-basis:0}.ctr.virtualised{overflow-y:hidden}.search{position:sticky;box-sizing:border-box;display:flex;align-items:center;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));margin-left:var(--rtk-space-3, 12px);margin-right:var(--rtk-space-3, 12px);margin-top:var(--rtk-space-0, 0px);margin-bottom:var(--rtk-space-0, 0px)}.search rtk-icon{margin-left:var(--rtk-space-2, 8px);margin-right:var(--rtk-space-2, 8px);height:var(--rtk-space-5, 20px);width:var(--rtk-space-5, 20px);color:rgb(var(--rtk-colors-text-600, 255 255 255 / 0.52))}.search input{box-sizing:border-box;height:var(--rtk-space-9, 36px);width:100%;padding-right:var(--rtk-space-2, 8px);border-width:var(--rtk-border-width-none, 0);border-style:none;--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-1000, 255 255 255));outline:2px solid transparent;outline-offset:2px;border-radius:var(--rtk-border-radius-sm, 4px);font-size:14px}.search input::-moz-placeholder{color:rgb(var(--rtk-colors-text-800, 255 255 255 / 0.76))}.search input::placeholder{color:rgb(var(--rtk-colors-text-800, 255 255 255 / 0.76))}:host([size='md']) .search{margin-top:var(--rtk-space-4, 16px) !important;margin-bottom:var(--rtk-space-4, 16px) !important}:host([size='sm']) .search{margin-top:var(--rtk-space-4, 16px) !important;margin-bottom:var(--rtk-space-4, 16px) !important}.no-pending-requests{margin-top:var(--rtk-space-4, 16px);margin-bottom:var(--rtk-space-4, 16px);text-align:center;font-size:12px;color:rgb(var(--rtk-colors-text-700, 255 255 255 / 0.64))}"}},[257,"rtk-participants",{meeting:[16],states:[16],config:[16],size:[513],iconPack:[16],defaultParticipantsTabId:[1,"default-participants-tab-id"],t:[16],currentParticipantsTabId:[32],tabs:[32],hasRequests:[32],search:[32]},void 0,{meeting:[{meetingChanged:0}],currentParticipantsTabId:[{currentParticipantsTabIdChanged:0}]}]);function O(){"undefined"!=typeof customElements&&["rtk-participants","rtk-avatar","rtk-button","rtk-icon","rtk-menu-item","rtk-menu-list","rtk-participant","rtk-participants-stage-list","rtk-participants-stage-queue","rtk-participants-viewer-list","rtk-participants-waiting-list","rtk-sidebar-ui","rtk-spinner","rtk-tooltip","rtk-virtualized-participant-list"].forEach((t=>{switch(t){case"rtk-participants":customElements.get(e(t))||customElements.define(e(t),y);break;case"rtk-avatar":customElements.get(e(t))||l();break;case"rtk-button":customElements.get(e(t))||h();break;case"rtk-icon":customElements.get(e(t))||d();break;case"rtk-menu-item":customElements.get(e(t))||m();break;case"rtk-menu-list":customElements.get(e(t))||u();break;case"rtk-participant":customElements.get(e(t))||b();break;case"rtk-participants-stage-list":customElements.get(e(t))||g();break;case"rtk-participants-stage-queue":customElements.get(e(t))||k();break;case"rtk-participants-viewer-list":customElements.get(e(t))||v();break;case"rtk-participants-waiting-list":customElements.get(e(t))||f();break;case"rtk-sidebar-ui":customElements.get(e(t))||x();break;case"rtk-spinner":customElements.get(e(t))||E();break;case"rtk-tooltip":customElements.get(e(t))||w();break;case"rtk-virtualized-participant-list":customElements.get(e(t))||T()}}))}S([c()],y.prototype,"meeting",void 0),S([c()],y.prototype,"states",void 0),S([c()],y.prototype,"config",void 0),S([c()],y.prototype,"iconPack",void 0),S([c()],y.prototype,"t",void 0),O();const _=y,I=O;export{_ as RtkParticipants,I as defineCustomElement}
@@ -1 +1 @@
1
- import{R as o,d as p}from"./p-EkUCxpDZ.js";const s=o,r=p;export{s as RtkPinnedMessageSelector,r as defineCustomElement}
1
+ import{R as o,d as s}from"./p-BoqfUgTL.js";const p=o,r=s;export{p as RtkPinnedMessageSelector,r as defineCustomElement}
@@ -1 +1 @@
1
- import{R as o,d as s}from"./p-l-tiOHlG.js";const t=o,p=s;export{t as RtkSidebarUi,p as defineCustomElement}
1
+ import{R as o,d as s}from"./p-Ryaxu6vl.js";const a=o,p=s;export{a as RtkSidebarUi,p as defineCustomElement}
@@ -1 +1 @@
1
- import{p as t,H as s,c as i,h as a,d as e,t as r}from"./p-BBHQOrFK.js";import{c as o,e as n,i as l}from"./p-DhwysA2e.js";import{c,d as p,a as h,b as d,e as m}from"./p-D9HGXWKc.js";import{S as k}from"./p-bRRQr4xn.js";import{R as b}from"./p-CBJjerDR.js";import{d as u}from"./p-B1oyTNvb.js";import{d as v}from"./p-CAMtxcI_.js";import{d as g}from"./p-D6vw6bT2.js";import{d as f}from"./p-BYIBbfJ8.js";import{d as w}from"./p-CU7xL-hP.js";import{d as x}from"./p-DjOiGHfI.js";import{d as j}from"./p-BvLjh5Yy.js";import{d as y}from"./p-Bn6JMUc9.js";import{d as C}from"./p-l-tiOHlG.js";import{d as E}from"./p-DHSRRtn3.js";var S=function(t,s,i,a){var e,r=arguments.length,o=r<3?s:null===a?a=Object.getOwnPropertyDescriptor(s,i):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,s,i,a);else for(var n=t.length-1;n>=0;n--)(e=t[n])&&(o=(r<3?e(o):r>3?e(s,i,o):e(s,i))||o);return r>3&&o&&Object.defineProperty(s,i,o),o};const R=t(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.stateUpdate=i(this,"rtkStateUpdate",7),this.enabledSections=[],this.defaultSection="chat",this.config=o(),this.iconPack=n,this.t=l(),this.view="sidebar",this.currentTab=this.defaultSection,this.isFloating=!1,this.enablePinning=!0,this.getTabs=()=>this.meeting.self.config?this.enabledSections.filter((t=>!(t.id in this.meeting.self.config.controlBar.elements)||this.meeting.self.config.controlBar.elements[t.id])):this.enabledSections,this.close=()=>{this.stateUpdate.emit({activeSidebar:!1,sidebar:this.defaultSection})},this.toggleFloating=()=>{this.isFloating=!this.isFloating}}connectedCallback(){var t;this.viewChanged(this.view),this.statesChanged(this.states),this.meetingChanged(this.meeting),this.isFloating=(null===(t=this.states)||void 0===t?void 0:t.sidebarFloating)||!1}disconnectedCallback(){var t,s;null===(s=null===(t=this.meeting)||void 0===t?void 0:t.stage)||void 0===s||s.removeListener("stageStatusUpdate",this.onStageStatusUpdate),this.onStageStatusUpdate=null}meetingChanged(t){var s,i;t&&(this.updateEnabledSections(t),this.onStageStatusUpdate=()=>{this.updateEnabledSections(this.meeting)},null===(i=null===(s=this.meeting)||void 0===s?void 0:s.stage)||void 0===i||i.on("stageStatusUpdate",this.onStageStatusUpdate))}statesChanged(t){(null==t?void 0:t.sidebar)&&(this.currentTab=t.sidebar)}viewChanged(t){this.enablePinning="full-screen"!==t}viewSection(t){this.currentTab=t,this.stateUpdate.emit({activeSidebar:!0,sidebar:this.currentTab})}updateEnabledSections(t=this.meeting){const s=[];c(t)&&s.push({id:"chat",name:this.t("chat")}),p(t)&&s.push({id:"polls",name:this.t("polls")}),h(t)&&s.push({id:"participants",name:this.t("participants")}),d(t)&&s.push({id:"plugins",name:this.t("plugins")}),m(t)&&s.push({id:"ai",name:this.t("ai.meeting_ai")}),this.enabledSections=s}render(){var t;if(!this.meeting)return null;const s={meeting:this.meeting,config:this.config,states:this.states,size:this.size,t:this.t,iconPack:this.iconPack};return!1!==(null===(t=s.states)||void 0===t?void 0:t.activeSidebar)&&this.currentTab?a(e,{class:this.enablePinning?this.isFloating?"floating":"":"floating"},a("rtk-sidebar-ui",{tabs:this.getTabs(),currentTab:this.currentTab,view:this.view,onTabChange:t=>{this.viewSection(t.detail)},onSidebarClose:this.close},this.enablePinning&&a("div",{class:"pinned-state",slot:"pinned-state"},a("rtk-button",{variant:"ghost",kind:"icon",onClick:this.toggleFloating,"aria-label":this.t(this.isFloating?"pin":"unpin")},a("rtk-icon",{icon:this.isFloating?this.iconPack.pin:this.iconPack.pin_off}))),"chat"===s.states.sidebar&&a(b,{element:"rtk-chat",defaults:s,props:{slot:"chat"}}),"polls"===s.states.sidebar&&a("rtk-polls",Object.assign({},s,{slot:"polls"})),"participants"===s.states.sidebar&&a(b,{element:"rtk-participants",defaults:s,props:{slot:"participants"}}),"plugins"===s.states.sidebar&&a("rtk-plugins",Object.assign({},s,{slot:"plugins"})),"ai"===s.states.sidebar&&a("rtk-ai",Object.assign({},s,{slot:"ai"})))):null}static get watchers(){return{meeting:[{meetingChanged:0}],states:[{statesChanged:0}],view:[{viewChanged:0}]}}static get style(){return":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{margin-right:var(--rtk-space-0, 0px);height:100%;width:100%;max-width:var(--rtk-space-96, 384px);box-sizing:border-box;display:flex;flex-direction:column;--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-1000, 8 8 8) / var(--tw-bg-opacity));border-width:var(--rtk-border-width-sm, 1px);border-style:solid;--tw-border-opacity:1;border-color:rgba(var(--rtk-colors-background-700, 44 44 44) / var(--tw-border-opacity))}:host([view='sidebar']){right:var(--rtk-space-2, 8px);margin-right:var(--rtk-space-4, 16px);overflow:clip;border-radius:var(--rtk-border-radius-lg, 12px);--tw-shadow:0 25px 50px -12px rgb(0 0 0 / 0.25);--tw-shadow-colored:0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);--tw-shadow-color:rgb(var(--rtk-colors-background-900, 26 26 26));--tw-shadow:var(--tw-shadow-colored)}:host([view='full-screen']){top:var(--rtk-space-0, 0px);right:var(--rtk-space-0, 0px);bottom:var(--rtk-space-0, 0px);left:var(--rtk-space-0, 0px);max-width:100%}:host(.floating){position:absolute !important;top:var(--rtk-space-0, 0px);right:var(--rtk-space-0, 0px);bottom:var(--rtk-space-0, 0px);left:var(--rtk-space-0, 0px);left:auto;z-index:50}.pinned-state{position:absolute;right:var(--rtk-space-1, 4px);display:inline-flex;width:var(--rtk-space-2, 8px);justify-content:flex-end}"}},[1,"rtk-sidebar",{enabledSections:[1040],defaultSection:[1,"default-section"],meeting:[16],states:[16],config:[16],iconPack:[16],t:[16],size:[513],view:[513],currentTab:[32],isFloating:[32],enablePinning:[32]},void 0,{meeting:[{meetingChanged:0}],states:[{statesChanged:0}],view:[{viewChanged:0}]}]);function B(){"undefined"!=typeof customElements&&["rtk-sidebar","rtk-ai","rtk-ai-transcriptions","rtk-button","rtk-icon","rtk-plugins","rtk-poll","rtk-poll-form","rtk-polls","rtk-sidebar-ui","rtk-tooltip"].forEach((t=>{switch(t){case"rtk-sidebar":customElements.get(r(t))||customElements.define(r(t),R);break;case"rtk-ai":customElements.get(r(t))||u();break;case"rtk-ai-transcriptions":customElements.get(r(t))||v();break;case"rtk-button":customElements.get(r(t))||g();break;case"rtk-icon":customElements.get(r(t))||f();break;case"rtk-plugins":customElements.get(r(t))||w();break;case"rtk-poll":customElements.get(r(t))||x();break;case"rtk-poll-form":customElements.get(r(t))||j();break;case"rtk-polls":customElements.get(r(t))||y();break;case"rtk-sidebar-ui":customElements.get(r(t))||C();break;case"rtk-tooltip":customElements.get(r(t))||E()}}))}S([k()],R.prototype,"meeting",void 0),S([k()],R.prototype,"states",void 0),S([k()],R.prototype,"config",void 0),S([k()],R.prototype,"iconPack",void 0),S([k()],R.prototype,"t",void 0),B();const O=R,D=B;export{O as RtkSidebar,D as defineCustomElement}
1
+ import{p as t,H as s,c as i,h as a,d as e,t as r}from"./p-BBHQOrFK.js";import{c as o,e as n,i as l}from"./p-DhwysA2e.js";import{c,d as p,a as h,b as d,e as m}from"./p-D9HGXWKc.js";import{S as k}from"./p-bRRQr4xn.js";import{R as b}from"./p-CBJjerDR.js";import{d as u}from"./p-B1oyTNvb.js";import{d as v}from"./p-CAMtxcI_.js";import{d as g}from"./p-D6vw6bT2.js";import{d as f}from"./p-BYIBbfJ8.js";import{d as w}from"./p-CU7xL-hP.js";import{d as x}from"./p-DjOiGHfI.js";import{d as j}from"./p-BvLjh5Yy.js";import{d as y}from"./p-Bn6JMUc9.js";import{d as C}from"./p-Ryaxu6vl.js";import{d as E}from"./p-DHSRRtn3.js";var S=function(t,s,i,a){var e,r=arguments.length,o=r<3?s:null===a?a=Object.getOwnPropertyDescriptor(s,i):a;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)o=Reflect.decorate(t,s,i,a);else for(var n=t.length-1;n>=0;n--)(e=t[n])&&(o=(r<3?e(o):r>3?e(s,i,o):e(s,i))||o);return r>3&&o&&Object.defineProperty(s,i,o),o};const R=t(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.stateUpdate=i(this,"rtkStateUpdate",7),this.enabledSections=[],this.defaultSection="chat",this.config=o(),this.iconPack=n,this.t=l(),this.view="sidebar",this.currentTab=this.defaultSection,this.isFloating=!1,this.enablePinning=!0,this.getTabs=()=>this.meeting.self.config?this.enabledSections.filter((t=>!(t.id in this.meeting.self.config.controlBar.elements)||this.meeting.self.config.controlBar.elements[t.id])):this.enabledSections,this.close=()=>{this.stateUpdate.emit({activeSidebar:!1,sidebar:this.defaultSection})},this.toggleFloating=()=>{this.isFloating=!this.isFloating}}connectedCallback(){var t;this.viewChanged(this.view),this.statesChanged(this.states),this.meetingChanged(this.meeting),this.isFloating=(null===(t=this.states)||void 0===t?void 0:t.sidebarFloating)||!1}disconnectedCallback(){var t,s;null===(s=null===(t=this.meeting)||void 0===t?void 0:t.stage)||void 0===s||s.removeListener("stageStatusUpdate",this.onStageStatusUpdate),this.onStageStatusUpdate=null}meetingChanged(t){var s,i;t&&(this.updateEnabledSections(t),this.onStageStatusUpdate=()=>{this.updateEnabledSections(this.meeting)},null===(i=null===(s=this.meeting)||void 0===s?void 0:s.stage)||void 0===i||i.on("stageStatusUpdate",this.onStageStatusUpdate))}statesChanged(t){(null==t?void 0:t.sidebar)&&(this.currentTab=t.sidebar)}viewChanged(t){this.enablePinning="full-screen"!==t}viewSection(t){this.currentTab=t,this.stateUpdate.emit({activeSidebar:!0,sidebar:this.currentTab})}updateEnabledSections(t=this.meeting){const s=[];c(t)&&s.push({id:"chat",name:this.t("chat")}),p(t)&&s.push({id:"polls",name:this.t("polls")}),h(t)&&s.push({id:"participants",name:this.t("participants")}),d(t)&&s.push({id:"plugins",name:this.t("plugins")}),m(t)&&s.push({id:"ai",name:this.t("ai.meeting_ai")}),this.enabledSections=s}render(){var t;if(!this.meeting)return null;const s={meeting:this.meeting,config:this.config,states:this.states,size:this.size,t:this.t,iconPack:this.iconPack};return!1!==(null===(t=s.states)||void 0===t?void 0:t.activeSidebar)&&this.currentTab?a(e,{class:this.enablePinning?this.isFloating?"floating":"":"floating"},a("rtk-sidebar-ui",{tabs:this.getTabs(),currentTab:this.currentTab,view:this.view,onTabChange:t=>{this.viewSection(t.detail)},onSidebarClose:this.close},this.enablePinning&&a("div",{class:"pinned-state",slot:"pinned-state"},a("rtk-button",{variant:"ghost",kind:"icon",onClick:this.toggleFloating,"aria-label":this.t(this.isFloating?"pin":"unpin")},a("rtk-icon",{icon:this.isFloating?this.iconPack.pin:this.iconPack.pin_off}))),"chat"===s.states.sidebar&&a(b,{element:"rtk-chat",defaults:s,props:{slot:"chat"}}),"polls"===s.states.sidebar&&a("rtk-polls",Object.assign({},s,{slot:"polls"})),"participants"===s.states.sidebar&&a(b,{element:"rtk-participants",defaults:s,props:{slot:"participants"}}),"plugins"===s.states.sidebar&&a("rtk-plugins",Object.assign({},s,{slot:"plugins"})),"ai"===s.states.sidebar&&a("rtk-ai",Object.assign({},s,{slot:"ai"})))):null}static get watchers(){return{meeting:[{meetingChanged:0}],states:[{statesChanged:0}],view:[{viewChanged:0}]}}static get style(){return":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{margin-right:var(--rtk-space-0, 0px);height:100%;width:100%;max-width:var(--rtk-space-96, 384px);box-sizing:border-box;display:flex;flex-direction:column;--tw-bg-opacity:1;background-color:rgba(var(--rtk-colors-background-1000, 8 8 8) / var(--tw-bg-opacity));border-width:var(--rtk-border-width-sm, 1px);border-style:solid;--tw-border-opacity:1;border-color:rgba(var(--rtk-colors-background-700, 44 44 44) / var(--tw-border-opacity))}:host([view='sidebar']){right:var(--rtk-space-2, 8px);margin-right:var(--rtk-space-4, 16px);overflow:clip;border-radius:var(--rtk-border-radius-lg, 12px);--tw-shadow:0 25px 50px -12px rgb(0 0 0 / 0.25);--tw-shadow-colored:0 25px 50px -12px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);--tw-shadow-color:rgb(var(--rtk-colors-background-900, 26 26 26));--tw-shadow:var(--tw-shadow-colored)}:host([view='full-screen']){top:var(--rtk-space-0, 0px);right:var(--rtk-space-0, 0px);bottom:var(--rtk-space-0, 0px);left:var(--rtk-space-0, 0px);max-width:100%}:host(.floating){position:absolute !important;top:var(--rtk-space-0, 0px);right:var(--rtk-space-0, 0px);bottom:var(--rtk-space-0, 0px);left:var(--rtk-space-0, 0px);left:auto;z-index:50}.pinned-state{position:absolute;right:var(--rtk-space-1, 4px);display:inline-flex;width:var(--rtk-space-2, 8px);justify-content:flex-end}"}},[1,"rtk-sidebar",{enabledSections:[1040],defaultSection:[1,"default-section"],meeting:[16],states:[16],config:[16],iconPack:[16],t:[16],size:[513],view:[513],currentTab:[32],isFloating:[32],enablePinning:[32]},void 0,{meeting:[{meetingChanged:0}],states:[{statesChanged:0}],view:[{viewChanged:0}]}]);function B(){"undefined"!=typeof customElements&&["rtk-sidebar","rtk-ai","rtk-ai-transcriptions","rtk-button","rtk-icon","rtk-plugins","rtk-poll","rtk-poll-form","rtk-polls","rtk-sidebar-ui","rtk-tooltip"].forEach((t=>{switch(t){case"rtk-sidebar":customElements.get(r(t))||customElements.define(r(t),R);break;case"rtk-ai":customElements.get(r(t))||u();break;case"rtk-ai-transcriptions":customElements.get(r(t))||v();break;case"rtk-button":customElements.get(r(t))||g();break;case"rtk-icon":customElements.get(r(t))||f();break;case"rtk-plugins":customElements.get(r(t))||w();break;case"rtk-poll":customElements.get(r(t))||x();break;case"rtk-poll-form":customElements.get(r(t))||j();break;case"rtk-polls":customElements.get(r(t))||y();break;case"rtk-sidebar-ui":customElements.get(r(t))||C();break;case"rtk-tooltip":customElements.get(r(t))||E()}}))}S([k()],R.prototype,"meeting",void 0),S([k()],R.prototype,"states",void 0),S([k()],R.prototype,"config",void 0),S([k()],R.prototype,"iconPack",void 0),S([k()],R.prototype,"t",void 0),B();const O=R,D=B;export{O as RtkSidebar,D as defineCustomElement}
@@ -1 +1 @@
1
- import{p as t,H as i,h as s,d as e,t as d}from"./p-BBHQOrFK.js";import{c as h,e as a,i as r}from"./p-DhwysA2e.js";import{d as o}from"./p-CmmyVCoN.js";import{R as m}from"./p-CBJjerDR.js";import{S as n}from"./p-bRRQr4xn.js";var c=function(t,i,s,e){var d,h=arguments.length,a=h<3?i:null===e?e=Object.getOwnPropertyDescriptor(i,s):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,s,e);else for(var r=t.length-1;r>=0;r--)(d=t[r])&&(a=(h<3?d(a):h>3?d(i,s,a):d(i,s))||a);return h>3&&a&&Object.defineProperty(i,s,a),a};const p=t(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.layout="row",this.participants=[],this.pinnedParticipants=[],this.aspectRatio="16:9",this.gap=8,this.config=h(),this.iconPack=a,this.t=r(),this.gridSize=o,this.getAdaptiveSize=t=>"sm"===this.size||t>3||"md"===this.size?"sm":"md"}render(){const t={meeting:this.meeting,config:this.config,states:this.states,size:this.size,iconPack:this.iconPack,t:this.t},i=this.participants.filter((t=>this.pinnedParticipants.some((i=>i.id!=t.id))));return s(e,{key:"1cb846cc92b660a8244d16a74f48dfadcef903b6"},s("main",{key:"8564f8b0bf6e7bd668132e2833fe73c73855d090",part:"main"},s(m,{key:"61b96f305727dc74de15f4c3c645069d6300afd9",element:"rtk-simple-grid",defaults:t,props:{part:"main-grid",participants:this.pinnedParticipants,aspectRatio:this.aspectRatio,gap:this.gap,size:this.getAdaptiveSize(this.pinnedParticipants.length)}})),i.length>0&&s("aside",{key:"2e297a8d83c1f7241d8688b643c055331d69299b",part:"aside",class:this.gridSize.spotlight?"grid-width-"+this.gridSize.spotlight:"grid-width-md"},s(m,{key:"2c1969c610018dfb0a23308316f072e3b8d87a6e",element:"rtk-simple-grid",defaults:t,props:{part:"aside-grid",participants:i,aspectRatio:this.aspectRatio,gap:this.gap,size:this.getAdaptiveSize(i.length)}})))}get host(){return this}static get style(){return":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:100%;width:100%}main{flex:1 1 0%}.grid-width-sm{width:25%}.grid-width-md{width:50%}.grid-width-lg{width:66.666667%}:host([size='sm']),:host([size='md']){flex-direction:column}:host([size='md']) aside{max-height:var(--rtk-space-96, 384px);width:100%;max-width:100%}:host([size='md']) .grid-width-sm{height:25%}:host([size='md']) .grid-width-md{height:50%}:host([size='md']) .grid-width-lg{height:66.666667%}:host([size='sm']) aside{max-height:var(--rtk-space-96, 384px);width:100%;max-width:100%}:host([size='sm']) .grid-width-sm,:host([size='sm']) .grid-width-md,:host([size='sm']) .grid-width-lg{height:50%}:host([size='xl']) .grid-width-sm,:host([size='xl']) .grid-width-md,:host([size='xl']) .grid-width-lg{width:400px}:host([layout='column']){flex-direction:column}:host([layout='column']) main{flex:4}:host([layout='column']) aside{flex:2;max-width:100%;width:100%}"}},[1,"rtk-spotlight-grid",{layout:[513],participants:[16],pinnedParticipants:[16],aspectRatio:[1,"aspect-ratio"],gap:[2],size:[513],meeting:[16],states:[16],config:[16],iconPack:[16],t:[16],gridSize:[16]}]);function g(){"undefined"!=typeof customElements&&["rtk-spotlight-grid"].forEach((t=>{"rtk-spotlight-grid"===t&&(customElements.get(d(t))||customElements.define(d(t),p))}))}c([n()],p.prototype,"meeting",void 0),c([n()],p.prototype,"states",void 0),c([n()],p.prototype,"config",void 0),c([n()],p.prototype,"iconPack",void 0),c([n()],p.prototype,"t",void 0),g();const l=p,f=g;export{l as RtkSpotlightGrid,f as defineCustomElement}
1
+ import{p as t,H as i,h as s,d as e,t as d}from"./p-BBHQOrFK.js";import{c as h,e as a,i as r}from"./p-DhwysA2e.js";import{d as o}from"./p-CmmyVCoN.js";import{R as m}from"./p-CBJjerDR.js";import{S as n}from"./p-bRRQr4xn.js";var c=function(t,i,s,e){var d,h=arguments.length,a=h<3?i:null===e?e=Object.getOwnPropertyDescriptor(i,s):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,i,s,e);else for(var r=t.length-1;r>=0;r--)(d=t[r])&&(a=(h<3?d(a):h>3?d(i,s,a):d(i,s))||a);return h>3&&a&&Object.defineProperty(i,s,a),a};const p=t(class extends i{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.layout="row",this.participants=[],this.pinnedParticipants=[],this.aspectRatio="16:9",this.gap=8,this.config=h(),this.iconPack=a,this.t=r(),this.gridSize=o,this.getAdaptiveSize=t=>"sm"===this.size||t>3||"md"===this.size?"sm":"md"}render(){const t={meeting:this.meeting,config:this.config,states:this.states,size:this.size,iconPack:this.iconPack,t:this.t},i=this.participants.filter((t=>this.pinnedParticipants.some((i=>i.id!=t.id))));return s(e,{key:"61c335032f64054d173a44639ab41ead131d0cdf"},s("main",{key:"6dd23dc9d8b600d1747213396968b9601e04f83e",part:"main"},s(m,{key:"efa5e5be367c3423e7fdd280fd9ec66ce5d50134",element:"rtk-simple-grid",defaults:t,props:{part:"main-grid",participants:this.pinnedParticipants,aspectRatio:this.aspectRatio,gap:this.gap,size:this.getAdaptiveSize(this.pinnedParticipants.length)}})),i.length>0&&s("aside",{key:"183ea410b2afb776dec7fc9fd2dbcd33d1ae285a",part:"aside",class:this.gridSize.spotlight?"grid-width-"+this.gridSize.spotlight:"grid-width-md"},s(m,{key:"cb763ff9d4c6358f63e974d1984de3c67ffee3b5",element:"rtk-simple-grid",defaults:t,props:{part:"aside-grid",participants:i,aspectRatio:this.aspectRatio,gap:this.gap,size:this.getAdaptiveSize(i.length)}})))}get host(){return this}static get style(){return":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:100%;width:100%}main{flex:1 1 0%}.grid-width-sm{width:25%}.grid-width-md{width:50%}.grid-width-lg{width:66.666667%}:host([size='sm']),:host([size='md']){flex-direction:column}:host([size='md']) aside{max-height:var(--rtk-space-96, 384px);width:100%;max-width:100%}:host([size='md']) .grid-width-sm{height:25%}:host([size='md']) .grid-width-md{height:50%}:host([size='md']) .grid-width-lg{height:66.666667%}:host([size='sm']) aside{max-height:var(--rtk-space-96, 384px);width:100%;max-width:100%}:host([size='sm']) .grid-width-sm,:host([size='sm']) .grid-width-md,:host([size='sm']) .grid-width-lg{height:50%}:host([size='xl']) .grid-width-sm,:host([size='xl']) .grid-width-md,:host([size='xl']) .grid-width-lg{width:400px}:host([layout='column']){flex-direction:column}:host([layout='column']) main{flex:4}:host([layout='column']) aside{flex:2;max-width:100%;width:100%}"}},[1,"rtk-spotlight-grid",{layout:[513],participants:[16],pinnedParticipants:[16],aspectRatio:[1,"aspect-ratio"],gap:[2],size:[513],meeting:[16],states:[16],config:[16],iconPack:[16],t:[16],gridSize:[16]}]);function g(){"undefined"!=typeof customElements&&["rtk-spotlight-grid"].forEach((t=>{"rtk-spotlight-grid"===t&&(customElements.get(d(t))||customElements.define(d(t),p))}))}c([n()],p.prototype,"meeting",void 0),c([n()],p.prototype,"states",void 0),c([n()],p.prototype,"config",void 0),c([n()],p.prototype,"iconPack",void 0),c([n()],p.prototype,"t",void 0),g();const f=p,l=g;export{f as RtkSpotlightGrid,l as defineCustomElement}
@@ -1,5 +1,5 @@
1
1
  {
2
- "timestamp": "2026-10-07T15:50:03",
2
+ "timestamp": "2026-10-12T06:02:11",
3
3
  "compiler": {
4
4
  "name": "@stencil/core",
5
5
  "version": "4.43.5",
@@ -10,7 +10,7 @@
10
10
  "filePath": "src/components/rtk-ai/rtk-ai.tsx",
11
11
  "encapsulation": "shadow",
12
12
  "tag": "rtk-ai",
13
- "docs": "An AI assistant component for meeting interactions.\n\nProvides AI-powered features like transcription, summarization, and\nintelligent meeting assistance. Rendered inside rtk-sidebar as the 'ai' section.",
13
+ "docs": "The AI panel shows meeting transcriptions. For example, participants can\nread the conversation in the sidebar during a meeting.",
14
14
  "docsTags": [],
15
15
  "usage": {},
16
16
  "props": [
@@ -21513,7 +21513,7 @@
21513
21513
  "filePath": "src/components/rtk-broadcast-message-modal/rtk-broadcast-message-modal.tsx",
21514
21514
  "encapsulation": "shadow",
21515
21515
  "tag": "rtk-broadcast-message-modal",
21516
- "docs": "A modal for sending broadcast messages to all meeting participants.\n\nAllows hosts and moderators to send important announcements that\nappear prominently to all users in the meeting.",
21516
+ "docs": "A modal for writing a broadcast message, such as an announcement to everyone\nin a meeting. It currently shows a confirmation without sending the message.",
21517
21517
  "docsTags": [],
21518
21518
  "usage": {},
21519
21519
  "props": [
@@ -34001,7 +34001,7 @@
34001
34001
  "mutable": false,
34002
34002
  "attr": "is-sending",
34003
34003
  "reflectToAttr": false,
34004
- "docs": "",
34004
+ "docs": "Whether a message is being sent",
34005
34005
  "docsTags": [
34006
34006
  {
34007
34007
  "name": "default",
@@ -111211,7 +111211,7 @@
111211
111211
  "filePath": "src/components/rtk-livestream-toggle/rtk-livestream-toggle.tsx",
111212
111212
  "encapsulation": "shadow",
111213
111213
  "tag": "rtk-livestream-toggle",
111214
- "docs": "A toggle button for starting/stopping livestream broadcasting.\n\nOnly visible to users with livestream permissions. Allows hosts to\nbroadcast the meeting to external streaming platforms.",
111214
+ "docs": "A button for starting or stopping a meeting livestream. It appears only for\nparticipants who have permission to host the livestream.",
111215
111215
  "docsTags": [],
111216
111216
  "usage": {
111217
111217
  "angular-example": "Template\n\n```html\n<rtk-livestream-toggle #one></rtk-livestream-toggle>\n<rtk-livestream-toggle #two></rtk-livestream-toggle>\n<rtk-livestream-toggle #three></rtk-livestream-toggle>\n```\n\nComponent\n\n```js\nclass MyComponent {\n title = 'MyComponent';\n\n @ViewChild('one') componentOne: RtkLivestreamToggle;\n\n @ViewChild('two') componentTwo: RtkLivestreamToggle;\n\n @ViewChild('three') componentTree: RtkLivestreamToggle;\n\n rtkMeeting: RealtimeKitClient; // meeting instance\n\n async ngAfterViewInit() {\n // Change the size to small\n this.componentOne.meeting = this.rtkMeeting;\n this.componentOne.size = 'sm';\n\n // Change the size to large\n this.componentTwo.meeting = this.rtkMeeting;\n this.componentTwo.size = 'lg';\n\n // Render as a horizontal button\n this.componentThree.meeting = this.rtkMeeting;\n this.componentThree.variant = 'horizontal';\n }\n}\n```\n",
@@ -124903,7 +124903,7 @@
124903
124903
  },
124904
124904
  "mutable": false,
124905
124905
  "reflectToAttr": false,
124906
- "docs": "Function to load more messages.\nMessages returned from this will be preprended",
124906
+ "docs": "Function to load more messages.\nMessages returned from this will be prepended",
124907
124907
  "docsTags": [],
124908
124908
  "values": [
124909
124909
  {
@@ -148820,7 +148820,7 @@
148820
148820
  "docs": "- The updated data node"
148821
148821
  }
148822
148822
  ],
148823
- "docs": "Updates a new node anywhere in the list",
148823
+ "docs": "Updates an existing node in the paginated list.",
148824
148824
  "docsTags": [
148825
148825
  {
148826
148826
  "name": "param",
@@ -162860,7 +162860,7 @@
162860
162860
  "filePath": "src/components/rtk-participants-stage-queue/rtk-participants-stage-queue.tsx",
162861
162861
  "encapsulation": "shadow",
162862
162862
  "tag": "rtk-participants-stage-queue",
162863
- "docs": "A component that displays participants waiting in the stage queue.\n\nShows users who are waiting to be promoted to the stage in meetings\nwith stage functionality enabled.",
162863
+ "docs": "Displays participants who have requested access to the stage. The list includes\ncontrols for accepting or denying their requests.",
162864
162864
  "docsTags": [],
162865
162865
  "usage": {},
162866
162866
  "props": [
@@ -174487,7 +174487,7 @@
174487
174487
  "filePath": "src/components/rtk-pip-toggle/rtk-pip-toggle.tsx",
174488
174488
  "encapsulation": "shadow",
174489
174489
  "tag": "rtk-pip-toggle",
174490
- "docs": "A toggle button for enabling/disabling Picture-in-Picture mode.\n\nAllows users to switch the video display to a floating window that stays\non top of other applications.",
174490
+ "docs": "A button to turn Picture-in-Picture mode on or off when available. For example,\na participant can keep the meeting video visible while using another app.",
174491
174491
  "docsTags": [],
174492
174492
  "usage": {},
174493
174493
  "props": [
@@ -209418,7 +209418,7 @@
209418
209418
  "filePath": "src/components/rtk-sidebar-ui/rtk-sidebar-ui.tsx",
209419
209419
  "encapsulation": "shadow",
209420
209420
  "tag": "rtk-sidebar-ui",
209421
- "docs": "A sidebar UI component with tabbed navigation.\n\nProvides a container for sidebar content with tab switching functionality.\nCan be displayed as a sidebar or in full-screen mode.",
209421
+ "docs": "A tabbed container for meeting panels, such as chat and participants. It shows\nthe selected panel in a sidebar or full-screen view.",
209422
209422
  "docsTags": [],
209423
209423
  "usage": {},
209424
209424
  "props": [
@@ -215508,7 +215508,7 @@
215508
215508
  "filePath": "src/components/rtk-spotlight-grid/rtk-spotlight-grid.tsx",
215509
215509
  "encapsulation": "shadow",
215510
215510
  "tag": "rtk-spotlight-grid",
215511
- "docs": "A grid component that renders two lists of participants: `pinnedParticipants` and `participants`.\n\nYou can customize the layout to a `column` view, by default is is `row`.\n\n- Participants from `pinnedParticipants[]` are rendered inside a larger grid.\n- Participants from `participants[]` array are rendered in a smaller grid.",
215511
+ "docs": "A grid component that renders two lists of participants: `pinnedParticipants` and `participants`.\n\nYou can customize the layout to a `column` view, by default is `row`.\n\n- Participants from `pinnedParticipants[]` are rendered inside a larger grid.\n- Participants from `participants[]` array are rendered in a smaller grid.",
215512
215512
  "docsTags": [],
215513
215513
  "usage": {
215514
215514
  "html-example": "```html\n<rtk-spotlight-grid class=\"rtk-el\"></rtk-spotlight-grid>\n<rtk-spotlight-grid layout=\"column\" class=\"rtk-el\"></rtk-spotlight-grid>\n\n<script>\n const elements = document.getElementsByClassName('rtk-el');\n for (const el of elements) {\n el.participants = [meeting.self];\n el.pinnedParticipants = [meeting.self];\n }\n</script>\n\n<style>\n rtk-spotlight-grid {\n height: 360px;\n width: 100%;\n }\n</style>\n```\n",
@@ -5,7 +5,7 @@
5
5
  "name": "rtk-ai",
6
6
  "description": {
7
7
  "kind": "markdown",
8
- "value": "An AI assistant component for meeting interactions.\n\nProvides AI-powered features like transcription, summarization, and\nintelligent meeting assistance. Rendered inside rtk-sidebar as the 'ai' section."
8
+ "value": "The AI panel shows meeting transcriptions. For example, participants can\nread the conversation in the sidebar during a meeting."
9
9
  },
10
10
  "attributes": [
11
11
  {
@@ -330,7 +330,7 @@
330
330
  "name": "rtk-broadcast-message-modal",
331
331
  "description": {
332
332
  "kind": "markdown",
333
- "value": "A modal for sending broadcast messages to all meeting participants.\n\nAllows hosts and moderators to send important announcements that\nappear prominently to all users in the meeting."
333
+ "value": "A modal for writing a broadcast message, such as an announcement to everyone\nin a meeting. It currently shows a confirmation without sending the message."
334
334
  },
335
335
  "attributes": []
336
336
  },
@@ -629,7 +629,7 @@
629
629
  },
630
630
  {
631
631
  "name": "is-sending",
632
- "description": ""
632
+ "description": "Whether a message is being sent"
633
633
  },
634
634
  {
635
635
  "name": "max-length",
@@ -2110,7 +2110,7 @@
2110
2110
  "name": "rtk-livestream-toggle",
2111
2111
  "description": {
2112
2112
  "kind": "markdown",
2113
- "value": "A toggle button for starting/stopping livestream broadcasting.\n\nOnly visible to users with livestream permissions. Allows hosts to\nbroadcast the meeting to external streaming platforms."
2113
+ "value": "A button for starting or stopping a meeting livestream. It appears only for\nparticipants who have permission to host the livestream."
2114
2114
  },
2115
2115
  "attributes": [
2116
2116
  {
@@ -3092,7 +3092,7 @@
3092
3092
  "name": "rtk-participants-stage-queue",
3093
3093
  "description": {
3094
3094
  "kind": "markdown",
3095
- "value": "A component that displays participants waiting in the stage queue.\n\nShows users who are waiting to be promoted to the stage in meetings\nwith stage functionality enabled."
3095
+ "value": "Displays participants who have requested access to the stage. The list includes\ncontrols for accepting or denying their requests."
3096
3096
  },
3097
3097
  "attributes": [
3098
3098
  {
@@ -3263,7 +3263,7 @@
3263
3263
  "name": "rtk-pip-toggle",
3264
3264
  "description": {
3265
3265
  "kind": "markdown",
3266
- "value": "A toggle button for enabling/disabling Picture-in-Picture mode.\n\nAllows users to switch the video display to a floating window that stays\non top of other applications."
3266
+ "value": "A button to turn Picture-in-Picture mode on or off when available. For example,\na participant can keep the meeting video visible while using another app."
3267
3267
  },
3268
3268
  "attributes": [
3269
3269
  {
@@ -3846,7 +3846,7 @@
3846
3846
  "name": "rtk-sidebar-ui",
3847
3847
  "description": {
3848
3848
  "kind": "markdown",
3849
- "value": "A sidebar UI component with tabbed navigation.\n\nProvides a container for sidebar content with tab switching functionality.\nCan be displayed as a sidebar or in full-screen mode."
3849
+ "value": "A tabbed container for meeting panels, such as chat and participants. It shows\nthe selected panel in a sidebar or full-screen view."
3850
3850
  },
3851
3851
  "attributes": [
3852
3852
  {
@@ -3984,7 +3984,7 @@
3984
3984
  "name": "rtk-spotlight-grid",
3985
3985
  "description": {
3986
3986
  "kind": "markdown",
3987
- "value": "A grid component that renders two lists of participants: `pinnedParticipants` and `participants`.\n\nYou can customize the layout to a `column` view, by default is is `row`.\n\n- Participants from `pinnedParticipants[]` are rendered inside a larger grid.\n- Participants from `participants[]` array are rendered in a smaller grid."
3987
+ "value": "A grid component that renders two lists of participants: `pinnedParticipants` and `participants`.\n\nYou can customize the layout to a `column` view, by default is `row`.\n\n- Participants from `pinnedParticipants[]` are rendered inside a larger grid.\n- Participants from `participants[]` array are rendered in a smaller grid."
3988
3988
  },
3989
3989
  "attributes": [
3990
3990
  {