@_solaris/messenger-widget 0.1.4 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/messenger.cjs +1 -1
- package/dist/messenger.embed.js +10 -10
- package/dist/messenger.js +2 -1
- package/dist/types/embed.d.ts +1 -0
- package/dist/types/index.d.ts +1 -0
- package/package.json +1 -1
package/dist/messenger.cjs
CHANGED
|
@@ -53,4 +53,4 @@ ${i}`)}return a.join(`
|
|
|
53
53
|
|
|
54
54
|
`)}function P(n,t){if(!Array.isArray(n==null?void 0:n.options))return t;const r=n.options.find(a=>(a==null?void 0:a.value)===t);return(r==null?void 0:r.label)||t}function Jo(n,t){const r=[],a=Array.isArray(n==null?void 0:n.fields)?n.fields:[];for(const s of a){if(!(s!=null&&s.key)||!(s!=null&&s.label))continue;const o=t==null?void 0:t[s.key];if(o==null||o==="")continue;let i;if(Array.isArray(o)){if(i=o.map(f=>P(s,String(f))).join(", "),!i)continue}else typeof o=="boolean"?i=o?"Oui":"Non":i=P(s,String(o));const l=s.type==="textarea"||typeof i=="string"&&(i.length>60||i.includes(`
|
|
55
55
|
`));r.push({label:s.label,value:i,multiline:l})}return{kind:"form_response",data:{title:(n==null?void 0:n.title)||"Formulaire",fields:r}}}const Xo=450,Qo=50,Zo=900,es=12e3,ts=300,ns={name:"Messenger",components:{Launcher:me,Header:pe,Onboarding:fe,MessageList:Ee,Composer:Ae,SuggestionChips:Se,ApprovalCard:Me,FormCard:xe,Feedback:Te,HistoryDrawer:Oe,MoreMenu:Ie},provide(){return{signAttachmentFn:n=>{var t,r;return((r=(t=this.store)==null?void 0:t.signAttachment)==null?void 0:r.call(t,n))||null}}},props:{baseUrl:{type:String,default:ue},widgetId:{type:String,default:""},userId:{type:String,default:""},userHash:{type:String,default:""},customer:{type:Object,default:null},displayMode:{type:String,default:"floating"},devtools:{type:Boolean,default:!1}},data(){return{transport:null,store:null,isOpen:!1,draft:"",busy:!1,bootError:null,pendingAttachments:[],feedbackBusy:!1,feedbackDone:!1,revealedAt:{},nextRevealAt:0,revealTimers:[],convOpenedAt:0,historyOpen:!1,moreOpen:!1,activeConvId:null,showOnboarding:!1,notifEnabled:!0,labelDismissed:!1,readState:{},floatHeight:0,floatRO:null,approvalSettled:!0,approvalSettleTimer:null,approvalLatchId:null}},computed:{isEditor(){return!!this.devtools},isEmbedded(){return this.displayMode==="embedded"},error(){var n;return this.bootError||((n=this.s)==null?void 0:n.error)||null},canBoot(){return!!(this.baseUrl&&this.widgetId&&this.userId&&this.userHash)},s(){var n;return((n=this.store)==null?void 0:n.state)||null},ready(){var n;return!!((n=this.s)!=null&&n.ready)},allConversations(){var t;const n=(t=this.s)==null?void 0:t.conversations;return Array.isArray(n)?n:[]},drawerConversations(){var r;const n=this.readState,t=((r=this.s)==null?void 0:r.messagesByConv)||{};return this.allConversations.map(a=>{const s=t[a.id]||[],o=this.convLastActivity(a,s),i=n[a.id]||"",l=this.lastMessageAuthorType(s),f=!!o&&l!=="user"&&(!i||o>i);return{...a,_preview:this.convPreview(a,s),_unread:f}})},unreadCount(){return this.drawerConversations.filter(n=>n._unread).length},unreadThreads(){var t;const n=((t=this.s)==null?void 0:t.messagesByConv)||{};return this.drawerConversations.filter(r=>r._unread).map(r=>({id:r.id,title:r.name||"Nouvelle conversation",preview:r._preview||"Nouveau message",_ts:this.convLastActivity(r,n[r.id]||[])})).sort((r,a)=>r._ts<a._ts?1:r._ts>a._ts?-1:0).slice(0,3)},latestUnread(){var r;const n=((r=this.s)==null?void 0:r.messagesByConv)||{};let t=null;for(const a of this.drawerConversations){if(!a._unread)continue;const s=this.convLastActivity(a,n[a.id]||[]);(!t||s>t.ts)&&(t={convId:a.id,preview:a._preview,ts:s})}return t},launcherPeek(){if(this.isOpen||this.isEmbedded||this.labelDismissed)return"";const n=this.latestUnread;return n?n.preview||"Vous avez un nouveau message":""},currentConv(){if(this.showOnboarding)return null;const n=this.allConversations;if(!n.length)return null;if(this.activeConvId!=null){const t=n.find(r=>r.id===this.activeConvId);if(t)return t}return n[0]||null},canBack(){return!!this.currentConv},statusUrl(){var r;const n=(r=this.widget)==null?void 0:r.quick_links;if(!Array.isArray(n))return"";const t=n.find(a=>a.icon==="status"&&a.url);return(t==null?void 0:t.url)||""},helpUrl(){var r;const n=(r=this.widget)==null?void 0:r.quick_links;if(!Array.isArray(n))return"";const t=n.find(a=>(a.icon==="chat"||a.icon==="help")&&a.url);return(t==null?void 0:t.url)||""},widget(){var n,t;return((t=(n=this.s)==null?void 0:n.config)==null?void 0:t.widget)||null},widgetWelcomeMessage(){var n;return((n=this.widget)==null?void 0:n.welcome_message)||""},agentName(){var n,t,r;return((r=(t=(n=this.s)==null?void 0:n.config)==null?void 0:t.agent)==null?void 0:r.name)||""},agentAvatarUrl(){var n,t,r;return((r=(t=(n=this.s)==null?void 0:n.config)==null?void 0:t.agent)==null?void 0:r.avatar_url)||null},quickLinks(){var t;const n=(t=this.widget)==null?void 0:t.quick_links;return Array.isArray(n)?n:[]},teamMembers(){var t;const n=(t=this.widget)==null?void 0:t.team_members;return Array.isArray(n)?n:[]},responseLabel(){var n;return((n=this.widget)==null?void 0:n.response_time_label)||""},humanMessageAuthor(){var t,r,a;if(!this.currentConv)return null;const n=((t=this.s.messagesByConv)==null?void 0:t[this.currentConv.id])||[];for(let s=n.length-1;s>=0;s--)if(((a=(r=n[s])==null?void 0:r.author)==null?void 0:a.type)==="agent_human")return n[s].author;return null},humanAgentName(){var n;return((n=this.humanMessageAuthor)==null?void 0:n.name)||""},humanAgentAvatarUrl(){var n;return((n=this.humanMessageAuthor)==null?void 0:n.avatar_url)||null},isEscalated(){return!!this.humanMessageAuthor},isWaitingHuman(){var t;const n=(t=this.currentConv)==null?void 0:t.status;return n==="waiting"||n==="handled"},headerTitle(){var n,t;return((n=this.currentConv)==null?void 0:n.name)||((t=this.widget)==null?void 0:t.name)||"Nouvelle conversation"},composerPlaceholder(){return this.isEscalated&&this.humanAgentName?`Répondre à ${this.humanAgentName.split(" ")[0]}…`:this.isWaitingHuman?"Un agent prend le relais…":"Écrivez votre message…"},displayedMessages(){const n=this.currentConv;if(!n)return[];const t=s=>{var o,i;return(s==null?void 0:s.type)==="action"||(s==null?void 0:s.type)==="system"||((o=s==null?void 0:s.payload)==null?void 0:o.type)==="system"||Array.isArray((i=s==null?void 0:s.payload)==null?void 0:i.attachments)&&s.payload.attachments.length?!0:typeof(s==null?void 0:s.text_md)=="string"&&s.text_md.trim().length>0},r=s=>{var o;return(s==null?void 0:s.type)==="action"&&((o=s==null?void 0:s.payload)==null?void 0:o.state)==="pending"},a=this.revealedAt;return(this.s.messagesByConv[n.id]||[]).filter(s=>!r(s)).filter(s=>J(s)?a[s.id]>0:!0).filter(t)},streamingActive(){var r,a,s;const n=this.currentConv;return n?Object.keys(((r=this.s)==null?void 0:r.streamingByMsgId)||{}).length>0?!0:this.actionInFlight?!1:(((s=(a=this.s)==null?void 0:a.messagesByConv)==null?void 0:s[n.id])||[]).some(o=>J(o)&&!(this.revealedAt[o.id]>0)):!1},currentConvMessages(){var t,r,a;const n=(t=this.currentConv)==null?void 0:t.id;return n?((a=(r=this.s)==null?void 0:r.messagesByConv)==null?void 0:a[n])||[]:[]},pendingApproval(){return!this.currentConv||!this.store||this.actionInFlight?null:this.store.getPendingApproval(this.currentConv.id)},approvalReady(){return this.pendingApproval?this.pendingApproval.id===this.approvalLatchId?!0:!(this.streamingActive||!this.approvalSettled):!1},approvalTitle(){var n,t,r;return((t=(n=this.pendingApproval)==null?void 0:n.payload)==null?void 0:t.name)||((r=this.pendingApproval)==null?void 0:r.text_md)||"Confirmer l'action"},approvalDetail(){var a,s,o,i,l,f;const n=(o=(s=(a=this.pendingApproval)==null?void 0:a.payload)==null?void 0:s.pending)==null?void 0:o.user_explanation;if(typeof n=="string"&&n.trim())return n.trim();const t=(f=(l=(i=this.pendingApproval)==null?void 0:i.payload)==null?void 0:l.pending)==null?void 0:f.prepared_params;if(!t||typeof t!="object")return"";const r=Object.entries(t);return r.length?r.slice(0,2).map(([y,v])=>`${y}: ${v}`).join(" · "):""},actionInFlight(){var n,t;return!this.currentConv||!this.store?null:((t=(n=this.store).getActionInFlight)==null?void 0:t.call(n,this.currentConv.id))||null},actionInFlightName(){var t;const n=this.actionInFlight;return n?((t=n.payload)==null?void 0:t.name)||n.text_md||"Action":""},suggestions(){return!this.currentConv||!this.store?[]:this.streamingActive?[]:this.pendingForm?[]:this.store.getLatestSuggestions(this.currentConv.id)},pendingForm(){var n,t;return!this.currentConv||!this.store||this.pendingApproval||this.actionInFlight||this.streamingActive||!this.approvalSettled?null:((t=(n=this.store).getLatestForm)==null?void 0:t.call(n,this.currentConv.id))||null},showFeedback(){var t;const n=this.currentConv;return n?this.feedbackDone?!0:n.status!=="resolved"?!1:!((t=n.metadata)!=null&&t.feedback):!1},floatVisible(){return this.approvalReady||!!this.pendingForm||this.showFeedback||this.suggestions.length>0},dateLabel(){var r,a,s;const n=this.currentConv;let t=new Date;if(n){const i=((s=(((a=(r=this.s)==null?void 0:r.messagesByConv)==null?void 0:a[n.id])||[]).find(l=>l==null?void 0:l.created_at))==null?void 0:s.created_at)||n.created_at;if(i){const l=new Date(i);Number.isNaN(l.getTime())||(t=l)}}return`Aujourd'hui · ${ee(t)}`},paginationState(){var r,a,s;const n=(r=this.currentConv)==null?void 0:r.id,t=n?(s=(a=this.s)==null?void 0:a.paginationByConv)==null?void 0:s[n]:null;return{loading:!!(t!=null&&t.loading),hasMore:!!(t!=null&&t.nextCursor)}}},watch:{latestUnread:{handler(n,t){if(!n){this.labelDismissed=!1;return}(!t||n.convId!==t.convId||n.ts>t.ts)&&(this.labelDismissed=!1)},deep:!0},"currentConv.id":{handler(){this.cancelReveals(),this.revealedAt={},this.nextRevealAt=0,this.convOpenedAt=Date.now(),this.moreOpen=!1,this.resetApprovalPacing()},immediate:!0},pendingApproval:{handler(n,t){if(n&&!t){const r=n!=null&&n.created_at?Date.parse(n.created_at):NaN;if(!(Number.isFinite(r)&&r>=this.convOpenedAt)){this.resetApprovalPacing();return}this.bumpApprovalSettle(2600)}else!n&&t&&this.resetApprovalPacing()},immediate:!1},streamingActive(n,t){n!==t&&this.pendingApproval&&this.pendingApproval.id!==this.approvalLatchId&&this.bumpApprovalSettle()},approvalReady(n){n&&this.pendingApproval&&(this.approvalLatchId=this.pendingApproval.id)},floatVisible:{handler(n){this.$nextTick(()=>this.syncFloatObserver(n))},immediate:!0},currentConvMessages(n){var a;if(!Array.isArray(n)||!n.length)return;const t=Date.now(),r={...this.revealedAt};for(const s of n){if((s==null?void 0:s.id)==null||r[s.id]!==void 0)continue;if(!J(s)){r[s.id]=t;continue}const o=s!=null&&s.created_at?Date.parse(s.created_at):NaN;if(!Number.isFinite(o)||o<this.convOpenedAt){r[s.id]=t;continue}const i=typeof(s==null?void 0:s.text_md)=="string"&&s.text_md.trim().length>0,l=Array.isArray((a=s==null?void 0:s.payload)==null?void 0:a.attachments)&&s.payload.attachments.length>0;if(!i&&!l){r[s.id]=t;continue}r[s.id]=0,this.scheduleReveal(s)}this.revealedAt=r,(this.isOpen||this.isEmbedded)&&!this.historyOpen&&this.currentConv&&this.markConvRead(this.currentConv)}},async mounted(){if(console.log("[messenger] mounted",{isEditor:this.isEditor,canBoot:this.canBoot,hasBaseUrl:!!this.baseUrl,hasWidgetId:!!this.widgetId,hasUserId:!!this.userId,hasUserHash:!!this.userHash}),typeof document<"u"&&!document.getElementById(ie)){const n=document.createElement("style");n.id=ie,n.textContent=de,document.head.appendChild(n)}this.hydrateReadState(),await this.boot(),this.isEmbedded&&this.store&&await this.open()},beforeUnmount(){this.cancelReveals(),this.disconnectFloatRO(),this.resetApprovalPacing(),this.store&&this.store.destroy()},methods:{syncFloatObserver(n){if(this.disconnectFloatRO(),!n){this.floatHeight=0;return}const t=this.$refs.floatEl;if(t){if(typeof ResizeObserver>"u"){this.floatHeight=Math.ceil(t.getBoundingClientRect().height+8);return}this.floatRO=new ResizeObserver(r=>{const a=r[0];if(!a)return;const s=Math.ceil(a.contentRect.height+8);s!==this.floatHeight&&(this.floatHeight=s,this.$nextTick(()=>{var o,i;(i=(o=this.$refs.messageList)==null?void 0:o.scrollToBottom)==null||i.call(o)}))}),this.floatRO.observe(t)}},disconnectFloatRO(){if(this.floatRO){try{this.floatRO.disconnect()}catch{}this.floatRO=null}},convLastActivity(n,t){let r=(n==null?void 0:n.last_message_at)||(n==null?void 0:n.updated_at)||(n==null?void 0:n.created_at)||"";for(const a of t)a!=null&&a.created_at&&a.created_at>r&&(r=a.created_at);return r},lastMessageAuthorType(n){var t,r;for(let a=n.length-1;a>=0;a--){const s=(r=(t=n[a])==null?void 0:t.author)==null?void 0:r.type;if(s)return s}return""},convPreview(n,t){var r,a,s;for(let o=t.length-1;o>=0;o--){const i=t[o];if(!i)continue;const l=typeof i.text_md=="string"?i.text_md.trim():"";if(l)return(((r=i.author)==null?void 0:r.type)==="user"?"Vous : ":"")+l.replace(/\s+/g," ");const f=(a=i.payload)==null?void 0:a.attachments;if(Array.isArray(f)&&f.length)return"📎 Pièce jointe"}return(n==null?void 0:n.last_message_preview)||(n==null?void 0:n.preview)||((s=n==null?void 0:n.metadata)==null?void 0:s.last_preview)||""},readStorageKey(){const n=this.widgetId||"",t=this.userId||"";return`wm:read:${n}:${t}`},hydrateReadState(){try{if(typeof localStorage>"u")return;const n=localStorage.getItem(this.readStorageKey());if(!n)return;const t=JSON.parse(n);t&&typeof t=="object"&&(this.readState=t)}catch{}},persistReadState(){try{if(typeof localStorage>"u")return;localStorage.setItem(this.readStorageKey(),JSON.stringify(this.readState))}catch{}},markConvRead(n){var a,s;if(!(n!=null&&n.id))return;const t=((s=(a=this.s)==null?void 0:a.messagesByConv)==null?void 0:s[n.id])||[],r=this.convLastActivity(n,t);r&&this.readState[n.id]!==r&&(this.readState={...this.readState,[n.id]:r},this.persistReadState())},cancelReveals(){for(const n of this.revealTimers)try{clearTimeout(n)}catch{}this.revealTimers=[]},resetApprovalPacing(){if(this.approvalSettleTimer){try{clearTimeout(this.approvalSettleTimer)}catch{}this.approvalSettleTimer=null}this.approvalSettled=!0,this.approvalLatchId=null},bumpApprovalSettle(n=800){if(this.approvalSettled=!1,this.approvalSettleTimer)try{clearTimeout(this.approvalSettleTimer)}catch{}this.approvalSettleTimer=setTimeout(()=>{this.approvalSettled=!0,this.approvalSettleTimer=null},n)},scheduleReveal(n){const t=Date.now(),r=((n==null?void 0:n.text_md)||"").length,a=Math.min(es,Math.max(Zo,r*Qo)),o=Math.max(t+Xo,this.nextRevealAt+ts)+a;this.nextRevealAt=o;const i=Math.max(0,o-t),l=n.id,f=setTimeout(()=>{this.revealedAt={...this.revealedAt,[l]:Date.now()},this.revealTimers=this.revealTimers.filter(v=>v!==f)},i);this.revealTimers.push(f);const y=setTimeout(()=>{this.revealedAt[l]>0||(this.revealedAt={...this.revealedAt,[l]:Date.now()}),this.revealTimers=this.revealTimers.filter(v=>v!==y)},i+4e3);this.revealTimers.push(y)},async boot(){if(!this.canBoot){console.warn("[messenger] boot skipped — missing creds",{baseUrl:this.baseUrl,widgetId:this.widgetId,userId:this.userId,hasUserHash:!!this.userHash});return}try{console.log("[messenger] boot start",{baseUrl:this.baseUrl,widgetId:this.widgetId,userId:this.userId}),this.transport=e.markRaw(le({baseUrl:this.baseUrl,widgetId:this.widgetId,userId:this.userId,userHash:this.userHash})),this.store=e.markRaw(ce(this.transport)),await this.store.start(),this.customer&&typeof this.customer=="object"&&await this.store.applyCustomer(this.customer),console.log("[ww-messenger] boot done",{ready:this.store.state.ready,error:this.store.state.error})}catch(n){console.error("[ww-messenger] bootstrap failed",n),this.bootError=(n==null?void 0:n.message)||String(n)}},async refresh(){this.store&&this.store.destroy(),this.cancelReveals(),this.revealedAt={},this.nextRevealAt=0,this.convOpenedAt=0,this.transport=null,this.store=null,this.isOpen=!1,this.draft="",this.busy=!1,this.bootError=null,this.pendingAttachments=[],this.feedbackBusy=!1,this.feedbackDone=!1,this.historyOpen=!1,this.moreOpen=!1,this.activeConvId=null,this.showOnboarding=!1,await this.boot(),this.isEmbedded&&this.store&&await this.open()},async openFromPeek(){var t,r;const n=(t=this.latestUnread)==null?void 0:t.convId;n&&n!==((r=this.currentConv)==null?void 0:r.id)&&(this.activeConvId=n,this.showOnboarding=!1),await this.open()},async open(){if(this.isOpen=!0,this.store&&this.store.setPanelOpen(!0),this.currentConv){try{await this.store.openConversation(this.currentConv.id)}catch(n){console.error("[ww-messenger] load messages failed",n)}this.markConvRead(this.currentConv)}},close(){this.isOpen=!1,this.store&&this.store.setPanelOpen(!1)},async startConv(){if(!this.busy){this.busy=!0;try{const n=await this.store.createConversation({});this.activeConvId=n.id,this.showOnboarding=!1,await this.store.openConversation(n.id),this.markConvRead(n),this.focusComposer()}catch(n){console.error("[ww-messenger] create conv failed",n),this.bootError=(n==null?void 0:n.message)||String(n)}finally{this.busy=!1}}},focusComposer(){this.$nextTick(()=>{var n;return(n=this.$refs.composer)==null?void 0:n.focus()})},toggleMore(){this.historyOpen=!1,this.moreOpen=!this.moreOpen},goHome(){this.historyOpen=!1,this.moreOpen=!1,this.activeConvId=null,this.showOnboarding=!0},async onDrawerPick(n){if(!(n!=null&&n.id)||!this.store)return;this.historyOpen=!1,this.activeConvId=n.id,this.showOnboarding=!1;try{await this.store.openConversation(n.id)}catch(r){console.error("[ww-messenger] open conv failed",r)}const t=this.allConversations.find(r=>r.id===n.id);t&&this.markConvRead(t)},async onDrawerNew(){this.historyOpen=!1,await this.startConv()},onNotifToggle(n){this.notifEnabled=!!n},async onMoreAction(n){switch(this.moreOpen=!1,n){case"history":this.historyOpen=!0;break;case"rename":await this.renameCurrentConv();break;case"clear":await this.clearCurrentConv();break;case"export":this.exportCurrentConv();break;case"status":if(this.statusUrl)try{window.open(this.statusUrl,"_blank","noopener")}catch{}break;case"help":if(this.helpUrl)try{window.open(this.helpUrl,"_blank","noopener")}catch{}break}},async renameCurrentConv(){const n=this.currentConv;if(!n||!this.store)return;let t;try{t=typeof window<"u"&&typeof window.prompt=="function"?window.prompt("Nouveau nom du fil",n.name||""):null}catch{t=null}if(t==null)return;const r=t.trim();if(!(!r||r===n.name))try{await this.store.patchConversation(n.id,{name:r})}catch(a){console.error("[ww-messenger] rename failed",a)}},async clearCurrentConv(){var r;const n=this.currentConv;!n||!this.store||!(!(typeof window<"u"&&typeof window.confirm=="function")||window.confirm("Effacer ce fil de votre côté ? Cette action ne supprime pas les messages côté agent."))||((r=this.s)!=null&&r.messagesByConv&&(this.s.messagesByConv[n.id]=[]),this.activeConvId=null,this.showOnboarding=!0)},exportCurrentConv(){var s,o,i,l,f,y;const n=this.currentConv;if(!n)return;const t=(((o=(s=this.s)==null?void 0:s.messagesByConv)==null?void 0:o[n.id])||[]).slice(),r=[`# ${n.name||"Conversation"}`,n.created_at?`Créée le : ${n.created_at}`:"",""];for(const v of t){if(!v)continue;const w=((i=v.author)==null?void 0:i.name)||(((l=v.author)==null?void 0:l.type)==="user"?"Vous":((f=v.author)==null?void 0:f.type)==="agent_human"?"Agent":((y=v.author)==null?void 0:y.type)==="agent_ia"?"Assistant IA":"Système"),N=v.created_at?new Date(v.created_at).toLocaleString("fr-FR"):"",k=(v.text_md||"").trim();k&&(r.push(`[${N}] ${w} :`),r.push(k),r.push(""))}const a=new Blob([r.join(`
|
|
56
|
-
`)],{type:"text/plain;charset=utf-8"});try{const v=URL.createObjectURL(a),w=document.createElement("a");w.href=v,w.download=`${(n.name||"conversation").replace(/[^a-z0-9-_]+/gi,"_")}.txt`,document.body.appendChild(w),w.click(),document.body.removeChild(w),setTimeout(()=>URL.revokeObjectURL(v),1e3)}catch(v){console.error("[ww-messenger] export failed",v)}},async onSend(n){const t=this.currentConv;if(!t&&(await this.startConv(),!this.currentConv))return;const r=(this.currentConv||t).id,a=this.pendingAttachments.slice();this.pendingAttachments=[],await this.store.send(r,n,{attachments:a.length?a:void 0})},async onSuggestion(n){const t=n==null?void 0:n.label;t&&await this.onSend(t)},async onLoadMore(){var t;const n=(t=this.currentConv)==null?void 0:t.id;!n||!this.store||await this.store.loadMore(n)},async onApprovalCallback(n){const t=this.pendingApproval;t&&await this.store.clickCallback(t.id,n)},async onFormSubmit({values:n}){const t=this.pendingForm;if(!(t!=null&&t.form))return;const r=Yo(t.form,n);if(!r)return;const a=this.currentConv;a&&await this.store.send(a.id,r,{metadata:{artifact:Jo(t.form,n)}})},async onAttach(n){if(!(!n||!this.transport))try{const t=await this.transport.uploadAttachment(n);this.pendingAttachments.push({type:t.type||"file",path:t.path,name:n.name||"fichier",mime_type:n.type,size_bytes:n.size})}catch(t){console.error("[ww-messenger] attachment upload failed",t)}},async onQuickLink(n){if(n){if(n.url){try{window.open(n.url,"_blank","noopener")}catch{}return}await this.startConv(),this.currentConv&&await this.store.send(this.currentConv.id,n.label)}},async onFeedback({rating:n,comment:t}){if(this.currentConv){this.feedbackBusy=!0;try{await this.store.submitFeedback(this.currentConv.id,{rating:n,comment:t}),this.feedbackDone=!0}catch(r){console.error("[ww-messenger] feedback failed",r)}finally{this.feedbackBusy=!1}}}}},rs={key:0,class:"wm-loading","aria-busy":"true","aria-live":"polite"},os={key:0,class:"wm-state"},ss={class:"wm-state__err"},as={class:"wm-state__errSub"},is={class:"wm-bottom"},ls={key:0,ref:"floatEl",class:"wm-float"},cs={key:1,class:"wm-actionWait",role:"status","aria-live":"polite"},ds={class:"wm-actionWait__lbl"},us={key:1,class:"wm-attached"},ms=["onClick"];function hs(n,t,r,a,s,o){const i=e.resolveComponent("Launcher"),l=e.resolveComponent("Header"),f=e.resolveComponent("Onboarding"),y=e.resolveComponent("MessageList"),v=e.resolveComponent("ApprovalCard"),w=e.resolveComponent("FormCard"),N=e.resolveComponent("Feedback"),k=e.resolveComponent("SuggestionChips"),M=e.resolveComponent("Composer"),b=e.resolveComponent("MoreMenu"),x=e.resolveComponent("HistoryDrawer");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["wm-root",`wm-root--${r.displayMode}`])},[!s.isOpen&&!o.isEmbedded?(e.openBlock(),e.createBlock(i,{key:0,"unread-count":o.unreadCount,peek:o.launcherPeek,onOpen:o.openFromPeek,onDismiss:t[0]||(t[0]=S=>s.labelDismissed=!0)},null,8,["unread-count","peek","onOpen"])):e.createCommentVNode("",!0),s.isOpen||o.isEmbedded?(e.openBlock(),e.createElementBlock("section",{key:1,class:e.normalizeClass(["wm-panel",`wm-panel--${r.displayMode}`]),style:e.normalizeStyle(s.floatHeight?{"--wm-float-h":s.floatHeight+"px"}:null),role:"dialog","aria-label":"Messenger"},[!o.ready&&!o.error?(e.openBlock(),e.createElementBlock("div",rs,[o.isEmbedded?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"wm-loading__close","aria-label":"Réduire",onClick:t[1]||(t[1]=(...S)=>o.close&&o.close(...S))},[...t[6]||(t[6]=[e.createElementVNode("svg",{width:"13",height:"13",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M18 6L6 18M6 6l12 12"})],-1)])])),t[7]||(t[7]=e.createElementVNode("div",{class:"wm-loading__spinner","aria-hidden":"true"},null,-1))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(l,{title:o.headerTitle,escalated:o.isEscalated,"agent-name":o.humanAgentName,"agent-avatar-url":o.humanAgentAvatarUrl,"team-members":o.teamMembers,"response-label":o.responseLabel,"show-identity":!!o.currentConv,"show-back":o.canBack,"show-close":!o.isEmbedded,"more-active":s.moreOpen,onBack:o.goHome,onMore:o.toggleMore,onClose:o.close},null,8,["title","escalated","agent-name","agent-avatar-url","team-members","response-label","show-identity","show-back","show-close","more-active","onBack","onMore","onClose"]),o.error?(e.openBlock(),e.createElementBlock("div",os,[e.createElementVNode("div",ss,[t[9]||(t[9]=e.createElementVNode("div",{class:"wm-state__errIcon"},[e.createElementVNode("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M18 6L6 18M6 6l12 12"})])],-1)),e.createElementVNode("div",null,[t[8]||(t[8]=e.createElementVNode("div",{class:"wm-state__errTitle"},"Connexion impossible",-1)),e.createElementVNode("div",as,e.toDisplayString(o.error),1)])])])):o.currentConv?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(y,{ref:"messageList",messages:o.displayedMessages,"streaming-active":o.streamingActive,"date-label":o.dateLabel,"conversation-id":o.currentConv?o.currentConv.id:null,"loading-more":o.paginationState.loading,"has-more":o.paginationState.hasMore,onLoadMore:o.onLoadMore},null,8,["messages","streaming-active","date-label","conversation-id","loading-more","has-more","onLoadMore"]),e.createElementVNode("div",is,[o.floatVisible?(e.openBlock(),e.createElementBlock("div",ls,[o.approvalReady?(e.openBlock(),e.createBlock(v,{key:0,action:o.approvalTitle,detail:o.approvalDetail,callbacks:o.pendingApproval.callbacks,onCallback:o.onApprovalCallback},null,8,["action","detail","callbacks","onCallback"])):o.pendingForm?(e.openBlock(),e.createBlock(w,{key:o.pendingForm.message&&o.pendingForm.message.id,form:o.pendingForm.form,onSubmit:o.onFormSubmit},null,8,["form","onSubmit"])):o.showFeedback?(e.openBlock(),e.createBlock(N,{key:2,busy:s.feedbackBusy,done:s.feedbackDone,onSubmit:o.onFeedback},null,8,["busy","done","onSubmit"])):(e.openBlock(),e.createBlock(k,{key:3,items:o.suggestions,onSelect:o.onSuggestion},null,8,["items","onSelect"]))],512)):e.createCommentVNode("",!0),o.actionInFlight?(e.openBlock(),e.createElementBlock("div",cs,[t[10]||(t[10]=e.createElementVNode("span",{class:"wm-actionWait__spinner","aria-hidden":"true"},null,-1)),e.createElementVNode("span",ds,e.toDisplayString(o.actionInFlightName)+" en cours, veuillez patienter…",1)])):(e.openBlock(),e.createBlock(M,{key:2,ref:"composer",modelValue:s.draft,"onUpdate:modelValue":t[2]||(t[2]=S=>s.draft=S),placeholder:o.composerPlaceholder,disabled:!!o.pendingApproval,"attach-label":"Joindre un fichier",onSend:o.onSend,onAttach:o.onAttach},null,8,["modelValue","placeholder","disabled","onSend","onAttach"]))]),s.moreOpen?(e.openBlock(),e.createBlock(b,{key:0,"can-rename":!!o.currentConv,"can-clear":!!o.currentConv,"can-export":!!o.currentConv,"notif-enabled":s.notifEnabled,"status-url":o.statusUrl,"help-url":o.helpUrl,onClose:t[3]||(t[3]=S=>s.moreOpen=!1),onNotifToggle:o.onNotifToggle,onAction:o.onMoreAction},null,8,["can-rename","can-clear","can-export","notif-enabled","status-url","help-url","onNotifToggle","onAction"])):e.createCommentVNode("",!0),s.pendingAttachments.length?(e.openBlock(),e.createElementBlock("div",us,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.pendingAttachments,(S,T)=>(e.openBlock(),e.createElementBlock("div",{key:T,class:"wm-attached__chip"},[t[12]||(t[12]=e.createElementVNode("svg",{width:"11",height:"11",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M21.44 11.05l-9.19 9.19a6 6 0 01-8.49-8.49l9.19-9.19a4 4 0 015.66 5.66l-9.2 9.19a2 2 0 01-2.83-2.83l8.49-8.48"})],-1)),e.createElementVNode("span",null,e.toDisplayString(S.name),1),e.createElementVNode("button",{type:"button","aria-label":"Retirer",onClick:F=>s.pendingAttachments.splice(T,1)},[...t[11]||(t[11]=[e.createElementVNode("svg",{width:"10",height:"10",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M18 6L6 18M6 6l12 12"})],-1)])],8,ms)]))),128))])):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createBlock(f,{key:1,"welcome-message":o.widgetWelcomeMessage,"agent-name":o.agentName,"quick-links":o.quickLinks,"unread-threads":o.unreadThreads,busy:s.busy,onStart:o.startConv,onSelect:o.onQuickLink,onResume:o.onDrawerPick},null,8,["welcome-message","agent-name","quick-links","unread-threads","busy","onStart","onSelect","onResume"])),s.historyOpen?(e.openBlock(),e.createBlock(x,{key:3,conversations:o.drawerConversations,"active-id":o.currentConv?o.currentConv.id:null,onClose:t[4]||(t[4]=S=>s.historyOpen=!1),onNew:o.onDrawerNew,onPick:o.onDrawerPick},null,8,["conversations","active-id","onNew","onPick"])):e.createCommentVNode("",!0),s.moreOpen&&!o.currentConv?(e.openBlock(),e.createBlock(b,{key:4,"can-rename":!1,"can-clear":!1,"can-export":!1,"notif-enabled":s.notifEnabled,"status-url":o.statusUrl,"help-url":o.helpUrl,onClose:t[5]||(t[5]=S=>s.moreOpen=!1),onNotifToggle:o.onNotifToggle,onAction:o.onMoreAction},null,8,["notif-enabled","status-url","help-url","onNotifToggle","onAction"])):e.createCommentVNode("",!0)],64))],6)):e.createCommentVNode("",!0)],2)}const Le=B(ns,[["render",hs],["__scopeId","data-v-bee7b290"]]);exports.AIAvatar=L;exports.AVATAR_COLORS=z;exports.ActionResult=ye;exports.ApprovalCard=Me;exports.ArtifactFormResponse=_e;exports.ArtifactInfoCard=ve;exports.ArtifactRenderer=re;exports.ArtifactTicket=ge;exports.AttachmentPreview=ke;exports.Bubble=we;exports.Composer=Ae;exports.DEFAULT_BASE_URL=ue;exports.Feedback=Te;exports.FormCard=xe;exports.Header=pe;exports.HistoryDrawer=Oe;exports.HumanAvatar=te;exports.Launcher=me;exports.MEDIA_RECORDER_SUPPORTED=H;exports.MessageList=Ee;exports.Messenger=Le;exports.MoreMenu=Ie;exports.Onboarding=fe;exports.SCREEN_CAPTURE_SUPPORTED=R;exports.SuggestionChips=Se;exports.TeamAvatars=he;exports.Typing=be;exports.avatarColor=Q;exports.avatarInitials=Z;exports.captureScreenshotFile=Ne;exports.colors=A;exports.createStore=ce;exports.createTransport=le;exports.default=Le;exports.formatTime=ee;exports.guessAttachmentKind=ur;exports.pickRecorderMime=Ce;exports.renderMarkdown=ne;exports.startScreenRecording=Ve;exports.tokensCss=de;exports.uuid=X;exports.v4=X;
|
|
56
|
+
`)],{type:"text/plain;charset=utf-8"});try{const v=URL.createObjectURL(a),w=document.createElement("a");w.href=v,w.download=`${(n.name||"conversation").replace(/[^a-z0-9-_]+/gi,"_")}.txt`,document.body.appendChild(w),w.click(),document.body.removeChild(w),setTimeout(()=>URL.revokeObjectURL(v),1e3)}catch(v){console.error("[ww-messenger] export failed",v)}},async onSend(n){const t=this.currentConv;if(!t&&(await this.startConv(),!this.currentConv))return;const r=(this.currentConv||t).id,a=this.pendingAttachments.slice();this.pendingAttachments=[],await this.store.send(r,n,{attachments:a.length?a:void 0})},async onSuggestion(n){const t=n==null?void 0:n.label;t&&await this.onSend(t)},async onLoadMore(){var t;const n=(t=this.currentConv)==null?void 0:t.id;!n||!this.store||await this.store.loadMore(n)},async onApprovalCallback(n){const t=this.pendingApproval;t&&await this.store.clickCallback(t.id,n)},async onFormSubmit({values:n}){const t=this.pendingForm;if(!(t!=null&&t.form))return;const r=Yo(t.form,n);if(!r)return;const a=this.currentConv;a&&await this.store.send(a.id,r,{metadata:{artifact:Jo(t.form,n)}})},async onAttach(n){if(!(!n||!this.transport))try{const t=await this.transport.uploadAttachment(n);this.pendingAttachments.push({type:t.type||"file",path:t.path,name:n.name||"fichier",mime_type:n.type,size_bytes:n.size})}catch(t){console.error("[ww-messenger] attachment upload failed",t)}},async onQuickLink(n){if(n){if(n.url){try{window.open(n.url,"_blank","noopener")}catch{}return}await this.startConv(),this.currentConv&&await this.store.send(this.currentConv.id,n.label)}},async onFeedback({rating:n,comment:t}){if(this.currentConv){this.feedbackBusy=!0;try{await this.store.submitFeedback(this.currentConv.id,{rating:n,comment:t}),this.feedbackDone=!0}catch(r){console.error("[ww-messenger] feedback failed",r)}finally{this.feedbackBusy=!1}}}}},rs={key:0,class:"wm-loading","aria-busy":"true","aria-live":"polite"},os={key:0,class:"wm-state"},ss={class:"wm-state__err"},as={class:"wm-state__errSub"},is={class:"wm-bottom"},ls={key:0,ref:"floatEl",class:"wm-float"},cs={key:1,class:"wm-actionWait",role:"status","aria-live":"polite"},ds={class:"wm-actionWait__lbl"},us={key:1,class:"wm-attached"},ms=["onClick"];function hs(n,t,r,a,s,o){const i=e.resolveComponent("Launcher"),l=e.resolveComponent("Header"),f=e.resolveComponent("Onboarding"),y=e.resolveComponent("MessageList"),v=e.resolveComponent("ApprovalCard"),w=e.resolveComponent("FormCard"),N=e.resolveComponent("Feedback"),k=e.resolveComponent("SuggestionChips"),M=e.resolveComponent("Composer"),b=e.resolveComponent("MoreMenu"),x=e.resolveComponent("HistoryDrawer");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["wm-root",`wm-root--${r.displayMode}`])},[!s.isOpen&&!o.isEmbedded?(e.openBlock(),e.createBlock(i,{key:0,"unread-count":o.unreadCount,peek:o.launcherPeek,onOpen:o.openFromPeek,onDismiss:t[0]||(t[0]=S=>s.labelDismissed=!0)},null,8,["unread-count","peek","onOpen"])):e.createCommentVNode("",!0),s.isOpen||o.isEmbedded?(e.openBlock(),e.createElementBlock("section",{key:1,class:e.normalizeClass(["wm-panel",`wm-panel--${r.displayMode}`]),style:e.normalizeStyle(s.floatHeight?{"--wm-float-h":s.floatHeight+"px"}:null),role:"dialog","aria-label":"Messenger"},[!o.ready&&!o.error?(e.openBlock(),e.createElementBlock("div",rs,[o.isEmbedded?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"wm-loading__close","aria-label":"Réduire",onClick:t[1]||(t[1]=(...S)=>o.close&&o.close(...S))},[...t[6]||(t[6]=[e.createElementVNode("svg",{width:"13",height:"13",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M18 6L6 18M6 6l12 12"})],-1)])])),t[7]||(t[7]=e.createElementVNode("div",{class:"wm-loading__spinner","aria-hidden":"true"},null,-1))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createVNode(l,{title:o.headerTitle,escalated:o.isEscalated,"agent-name":o.humanAgentName,"agent-avatar-url":o.humanAgentAvatarUrl,"team-members":o.teamMembers,"response-label":o.responseLabel,"show-identity":!!o.currentConv,"show-back":o.canBack,"show-close":!o.isEmbedded,"more-active":s.moreOpen,onBack:o.goHome,onMore:o.toggleMore,onClose:o.close},null,8,["title","escalated","agent-name","agent-avatar-url","team-members","response-label","show-identity","show-back","show-close","more-active","onBack","onMore","onClose"]),o.error?(e.openBlock(),e.createElementBlock("div",os,[e.createElementVNode("div",ss,[t[9]||(t[9]=e.createElementVNode("div",{class:"wm-state__errIcon"},[e.createElementVNode("svg",{width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M18 6L6 18M6 6l12 12"})])],-1)),e.createElementVNode("div",null,[t[8]||(t[8]=e.createElementVNode("div",{class:"wm-state__errTitle"},"Connexion impossible",-1)),e.createElementVNode("div",as,e.toDisplayString(o.error),1)])])])):o.currentConv?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createVNode(y,{ref:"messageList",messages:o.displayedMessages,"streaming-active":o.streamingActive,"date-label":o.dateLabel,"conversation-id":o.currentConv?o.currentConv.id:null,"loading-more":o.paginationState.loading,"has-more":o.paginationState.hasMore,onLoadMore:o.onLoadMore},null,8,["messages","streaming-active","date-label","conversation-id","loading-more","has-more","onLoadMore"]),e.createElementVNode("div",is,[o.floatVisible?(e.openBlock(),e.createElementBlock("div",ls,[o.approvalReady?(e.openBlock(),e.createBlock(v,{key:0,action:o.approvalTitle,detail:o.approvalDetail,callbacks:o.pendingApproval.callbacks,onCallback:o.onApprovalCallback},null,8,["action","detail","callbacks","onCallback"])):o.pendingForm?(e.openBlock(),e.createBlock(w,{key:o.pendingForm.message&&o.pendingForm.message.id,form:o.pendingForm.form,onSubmit:o.onFormSubmit},null,8,["form","onSubmit"])):o.showFeedback?(e.openBlock(),e.createBlock(N,{key:2,busy:s.feedbackBusy,done:s.feedbackDone,onSubmit:o.onFeedback},null,8,["busy","done","onSubmit"])):(e.openBlock(),e.createBlock(k,{key:3,items:o.suggestions,onSelect:o.onSuggestion},null,8,["items","onSelect"]))],512)):e.createCommentVNode("",!0),o.actionInFlight?(e.openBlock(),e.createElementBlock("div",cs,[t[10]||(t[10]=e.createElementVNode("span",{class:"wm-actionWait__spinner","aria-hidden":"true"},null,-1)),e.createElementVNode("span",ds,e.toDisplayString(o.actionInFlightName)+" en cours, veuillez patienter…",1)])):(e.openBlock(),e.createBlock(M,{key:2,ref:"composer",modelValue:s.draft,"onUpdate:modelValue":t[2]||(t[2]=S=>s.draft=S),placeholder:o.composerPlaceholder,disabled:!!o.pendingApproval,"attach-label":"Joindre un fichier",onSend:o.onSend,onAttach:o.onAttach},null,8,["modelValue","placeholder","disabled","onSend","onAttach"]))]),s.moreOpen?(e.openBlock(),e.createBlock(b,{key:0,"can-rename":!!o.currentConv,"can-clear":!!o.currentConv,"can-export":!!o.currentConv,"notif-enabled":s.notifEnabled,"status-url":o.statusUrl,"help-url":o.helpUrl,onClose:t[3]||(t[3]=S=>s.moreOpen=!1),onNotifToggle:o.onNotifToggle,onAction:o.onMoreAction},null,8,["can-rename","can-clear","can-export","notif-enabled","status-url","help-url","onNotifToggle","onAction"])):e.createCommentVNode("",!0),s.pendingAttachments.length?(e.openBlock(),e.createElementBlock("div",us,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.pendingAttachments,(S,T)=>(e.openBlock(),e.createElementBlock("div",{key:T,class:"wm-attached__chip"},[t[12]||(t[12]=e.createElementVNode("svg",{width:"11",height:"11",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M21.44 11.05l-9.19 9.19a6 6 0 01-8.49-8.49l9.19-9.19a4 4 0 015.66 5.66l-9.2 9.19a2 2 0 01-2.83-2.83l8.49-8.48"})],-1)),e.createElementVNode("span",null,e.toDisplayString(S.name),1),e.createElementVNode("button",{type:"button","aria-label":"Retirer",onClick:F=>s.pendingAttachments.splice(T,1)},[...t[11]||(t[11]=[e.createElementVNode("svg",{width:"10",height:"10",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("path",{d:"M18 6L6 18M6 6l12 12"})],-1)])],8,ms)]))),128))])):e.createCommentVNode("",!0)],64)):(e.openBlock(),e.createBlock(f,{key:1,"welcome-message":o.widgetWelcomeMessage,"agent-name":o.agentName,"quick-links":o.quickLinks,"unread-threads":o.unreadThreads,busy:s.busy,onStart:o.startConv,onSelect:o.onQuickLink,onResume:o.onDrawerPick},null,8,["welcome-message","agent-name","quick-links","unread-threads","busy","onStart","onSelect","onResume"])),s.historyOpen?(e.openBlock(),e.createBlock(x,{key:3,conversations:o.drawerConversations,"active-id":o.currentConv?o.currentConv.id:null,onClose:t[4]||(t[4]=S=>s.historyOpen=!1),onNew:o.onDrawerNew,onPick:o.onDrawerPick},null,8,["conversations","active-id","onNew","onPick"])):e.createCommentVNode("",!0),s.moreOpen&&!o.currentConv?(e.openBlock(),e.createBlock(b,{key:4,"can-rename":!1,"can-clear":!1,"can-export":!1,"notif-enabled":s.notifEnabled,"status-url":o.statusUrl,"help-url":o.helpUrl,onClose:t[5]||(t[5]=S=>s.moreOpen=!1),onNotifToggle:o.onNotifToggle,onAction:o.onMoreAction},null,8,["notif-enabled","status-url","help-url","onNotifToggle","onAction"])):e.createCommentVNode("",!0)],64))],6)):e.createCommentVNode("",!0)],2)}const Le=B(ns,[["render",hs],["__scopeId","data-v-bee7b290"]]),ps="0.2.0";exports.AIAvatar=L;exports.AVATAR_COLORS=z;exports.ActionResult=ye;exports.ApprovalCard=Me;exports.ArtifactFormResponse=_e;exports.ArtifactInfoCard=ve;exports.ArtifactRenderer=re;exports.ArtifactTicket=ge;exports.AttachmentPreview=ke;exports.Bubble=we;exports.Composer=Ae;exports.DEFAULT_BASE_URL=ue;exports.Feedback=Te;exports.FormCard=xe;exports.Header=pe;exports.HistoryDrawer=Oe;exports.HumanAvatar=te;exports.Launcher=me;exports.MEDIA_RECORDER_SUPPORTED=H;exports.MessageList=Ee;exports.Messenger=Le;exports.MoreMenu=Ie;exports.Onboarding=fe;exports.SCREEN_CAPTURE_SUPPORTED=R;exports.SuggestionChips=Se;exports.TeamAvatars=he;exports.Typing=be;exports.VERSION=ps;exports.avatarColor=Q;exports.avatarInitials=Z;exports.captureScreenshotFile=Ne;exports.colors=A;exports.createStore=ce;exports.createTransport=le;exports.default=Le;exports.formatTime=ee;exports.guessAttachmentKind=ur;exports.pickRecorderMime=Ce;exports.renderMarkdown=ne;exports.startScreenRecording=Ve;exports.tokensCss=de;exports.uuid=X;exports.v4=X;
|