@maebgch/rcs-emulator 0.1.4 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,4 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const s=require("react/jsx-runtime"),S=require("react");var ae={exports:{}},de={};var pe;function Ee(){if(pe)return de;pe=1;var c=S.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;return de.c=function(t){return c.H.useMemoCache(t)},de}var fe={};var be;function De(){return be||(be=1,process.env.NODE_ENV!=="production"&&(function(){var c=S.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;fe.c=function(t){var e=c.H;return e===null&&console.error(`Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:
2
- 1. You might have mismatching versions of React and the renderer (such as React DOM)
3
- 2. You might be breaking the Rules of Hooks
4
- 3. You might have more than one copy of React in the same app
5
- See https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.`),e.useMemoCache(t)}})()),fe}var ye;function Be(){return ye||(ye=1,process.env.NODE_ENV==="production"?ae.exports=Ee():ae.exports=De()),ae.exports}var D=Be();function ge(c){return"reply"in c}function se(c){return"action"in c}function We(c){if(!se(c))return!1;const{urlAction:t}=c.action;return t?.openUrl?.application==="WEBVIEW"}function _e(c){const{urlAction:t}=c.action;return t?.openUrl?.application==="WEBVIEW"?t.openUrl:null}const Ve={name:"Business",verified:!1},Ue={currentMessageId:null,chatHistory:[],isTyping:!1,error:null},Le=S.createContext(null);function Se(c){const t=D.c(20),{children:e,theme:n,device:l,businessInfo:i,state:x,showSuggestions:r,isProfileOpen:o,toggleProfile:a,onReply:f,onAction:h,webView:d,openWebView:u,closeWebView:m}=c;let g;t[0]!==i?(g={...Ve,...i},t[0]=i,t[1]=g):g=t[1];let p;t[2]!==x?(p={...Ue,...x},t[2]=x,t[3]=p):p=t[3];let y;t[4]!==m||t[5]!==l||t[6]!==o||t[7]!==h||t[8]!==f||t[9]!==u||t[10]!==r||t[11]!==g||t[12]!==p||t[13]!==n||t[14]!==a||t[15]!==d?(y={theme:n,device:l,businessInfo:g,state:p,showSuggestions:r,isProfileOpen:o,toggleProfile:a,handleReply:f,handleAction:h,webView:d,openWebView:u,closeWebView:m},t[4]=m,t[5]=l,t[6]=o,t[7]=h,t[8]=f,t[9]=u,t[10]=r,t[11]=g,t[12]=p,t[13]=n,t[14]=a,t[15]=d,t[16]=y):y=t[16];const j=y;let b;return t[17]!==e||t[18]!==j?(b=s.jsx(Le.Provider,{value:j,children:e}),t[17]=e,t[18]=j,t[19]=b):b=t[19],b}function Z(){const c=S.useContext(Le);if(!c)throw new Error("useEmulator must be used within an EmulatorProvider");return c}function Me(c){const t=Object.values(c.messages);return t.find(e=>e.is_first)||t[0]||null}function ce(c,t){return c.messages[t]||null}function je(c,t){const e=c.responses?.keyword?.keyword_response?.choices;return e&&e[t]?.next_message||null}function me(c,t){const e=c.parts,n=He(e),l=Pe(e);return{id:`${c.id}-${t}-${Date.now()}`,sender:"business",content:n,timestamp:Date.now(),suggestions:l}}function He(c){for(const t of c){const e=t.RCSMessage;if(e.textMessage)return{type:"text",text:e.textMessage};const n=e.richcardMessage?.message?.generalPurposeCard;if(n)return{type:"richcard",card:ve(n.content,n.layout)};const l=e.richcardMessage?.message?.generalPurposeCardCarousel;if(l)return{type:"carousel",cards:l.content.map(i=>ve(i,{cardOrientation:"VERTICAL",cardWidth:l.layout.cardWidth}))}}return{type:"text",text:"[Unsupported message type]"}}function ve(c,t){const e=()=>{if(c.media){if(c.media.mediaUrl)return c.media.mediaUrl;if(c.media.contentInfo?.fileUrl)return c.media.contentInfo.fileUrl}},n=()=>{if(c.media){if(c.media.thumbnailUri)return c.media.thumbnailUri;if(c.media.contentInfo?.thumbnailUrl)return c.media.contentInfo.thumbnailUrl}},l=e();return{title:c.title,description:c.description,media:l?{url:l,height:Oe(c.media?.height||"MEDIUM_HEIGHT"),thumbnailUrl:n()}:void 0,suggestions:c.suggestions,layout:{orientation:t.cardOrientation==="HORIZONTAL"?"horizontal":"vertical",width:t.cardWidth==="SMALL_WIDTH"?"small":"medium",imageAlignment:t.imageAlignment==="RIGHT"?"right":"left"}}}function Oe(c){switch(c){case"SHORT_HEIGHT":return"short";case"TALL_HEIGHT":return"tall";default:return"medium"}}function Pe(c){const t=[];for(const e of c){const n=e.RCSMessage;n.suggestedChipList?.suggestions&&t.push(...n.suggestedChipList.suggestions)}return t}function Ge(c){return{id:`user-${Date.now()}`,sender:"user",content:{type:"userReply",text:c},timestamp:Date.now()}}function $e(c){if(!c||typeof c!="object")return!1;const t=c;if(typeof t.name!="string"||!t.messages||typeof t.messages!="object")return!1;const e=Object.values(t.messages);if(e.length===0)return!1;for(const n of e){if(!n||typeof n!="object")return!1;const l=n;if(typeof l.id!="string"||!Array.isArray(l.parts))return!1}return!0}function ze(c){const t=Me(c);if(!t||!t.parts.length)return"New message";const n=t.parts[0].RCSMessage;if(n.textMessage)return n.textMessage.slice(0,50)+(n.textMessage.length>50?"...":"");const l=n.richcardMessage?.message?.generalPurposeCard;if(l?.content.title)return l.content.title;const i=n.richcardMessage?.message?.generalPurposeCardCarousel;return i?.content[0]?.title?i.content[0].title:"New message"}const Re={currentMessageId:null,chatHistory:[],isTyping:!1,error:null};function Fe(c,t){switch(t.type){case"INIT":return{...c,currentMessageId:t.messageId,error:null};case"ADD_BUSINESS_MESSAGE":return{...c,chatHistory:[...c.chatHistory,t.message],isTyping:!1};case"ADD_USER_REPLY":{const e=Ge(t.text),n=c.chatHistory.map((l,i)=>i===c.chatHistory.length-1?{...l,suggestions:void 0}:l);return{...c,chatHistory:[...n,e]}}case"SET_TYPING":return{...c,isTyping:t.isTyping};case"NAVIGATE_TO":return{...c,currentMessageId:t.messageId};case"SET_ERROR":return{...c,error:t.error,isTyping:!1};case"RESET":return Re;default:return c}}function qe(c){const t=D.c(18),{flow:e,onUserReply:n,typingDelay:l}=c,i=l===void 0?800:l,[x,r]=S.useReducer(Fe,Re),o=S.useRef(0),a=S.useRef(!1);let f,h;t[0]!==e?(f=()=>{if(a.current)return;a.current=!0;const b=Me(e);if(!b){r({type:"SET_ERROR",error:"No first message found in conversation flow"});return}r({type:"INIT",messageId:b.id}),o.current=o.current+1;const w=me(b,o.current);r({type:"ADD_BUSINESS_MESSAGE",message:w})},h=[e],t[0]=e,t[1]=f,t[2]=h):(f=t[1],h=t[2]),S.useEffect(f,h);let d;t[3]!==e||t[4]!==n||t[5]!==x.currentMessageId||t[6]!==i?(d=b=>{if(!ge(b))return;const{displayText:w,postback:v}=b.reply,k=v.data;r({type:"ADD_USER_REPLY",text:w,postbackData:k});const N={type:"reply",postbackData:k,displayText:w,timestamp:Date.now()};n(N);const L=x.currentMessageId?ce(e,x.currentMessageId):null;if(!L){r({type:"SET_ERROR",error:"Current message not found"});return}const C=je(L,k);if(!C)return;const R=ce(e,C);if(!R){r({type:"SET_ERROR",error:`Next message "${C}" not found`});return}r({type:"SET_TYPING",isTyping:!0}),r({type:"NAVIGATE_TO",messageId:C}),setTimeout(()=>{o.current=o.current+1;const $=me(R,o.current);r({type:"ADD_BUSINESS_MESSAGE",message:$})},i)},t[3]=e,t[4]=n,t[5]=x.currentMessageId,t[6]=i,t[7]=d):d=t[7];const u=d;let m;t[8]!==e||t[9]!==n||t[10]!==x.currentMessageId||t[11]!==i?(m=b=>{if(!se(b))return;const{displayText:w,postback:v,openUrlAction:k,dialAction:N,dialerAction:L,mapAction:C,viewLocationAction:R}=b.action,$=v.data,_=N?.phoneNumber||L?.dialPhoneNumber?.phoneNumber,M=C?.showLocation?.location||R?.latLong;let z;k?z={type:"openUrl",url:k.url}:_?z={type:"dial",phoneNumber:_}:M&&(z={type:"viewLocation",latitude:M.latitude,longitude:M.longitude,query:R?.query});const I={type:"action",postbackData:$,displayText:w,timestamp:Date.now(),actionData:z};if(n(I),k)window.open(k.url,"_blank","noopener,noreferrer");else if(_)window.location.href=`tel:${_}`;else if(M){const A=C?.showLocation?.location?.label||R?.label||"",O=`https://www.google.com/maps/search/?api=1&query=${M.latitude},${M.longitude}${A?`&query_place_id=${encodeURIComponent(A)}`:""}`;window.open(O,"_blank","noopener,noreferrer")}const B=x.currentMessageId?ce(e,x.currentMessageId):null;if(B){const A=je(B,$);if(A){const O=ce(e,A);O&&(r({type:"ADD_USER_REPLY",text:w,postbackData:$}),r({type:"SET_TYPING",isTyping:!0}),r({type:"NAVIGATE_TO",messageId:A}),setTimeout(()=>{o.current=o.current+1;const F=me(O,o.current);r({type:"ADD_BUSINESS_MESSAGE",message:F})},i))}}},t[8]=e,t[9]=n,t[10]=x.currentMessageId,t[11]=i,t[12]=m):m=t[12];const g=m;let p;t[13]===Symbol.for("react.memo_cache_sentinel")?(p=()=>{a.current=!1,o.current=0,r({type:"RESET"})},t[13]=p):p=t[13];const y=p;let j;return t[14]!==g||t[15]!==u||t[16]!==x?(j={state:x,handleReply:u,handleAction:g,reset:y},t[14]=g,t[15]=u,t[16]=x,t[17]=j):j=t[17],j}function Ie(c){const[t,e]=S.useState(null),[n,l]=S.useState(!1),[i,x]=S.useState(null),r=S.useCallback(async()=>{if(!c){e(null),x(null);return}l(!0),x(null);try{const o=await fetch(c,{method:"GET",headers:{Accept:"application/json"}});if(!o.ok)throw new Error(`HTTP ${o.status}: ${o.statusText}`);const a=await o.json();if(!a||typeof a!="object")throw new Error("Invalid JSON: Expected an object");if(!a.messages||typeof a.messages!="object")throw new Error("Invalid RBM JSON: Missing 'messages' object");e(a)}catch(o){const a=o instanceof Error?o.message:"Failed to fetch JSON";x(a),e(null)}finally{l(!1)}},[c]);return S.useEffect(()=>{r()},[r]),{data:t,isLoading:n,error:i,refetch:r}}function Ye(c){const t=D.c(3),e=S.useRef(null);let n;t[0]===Symbol.for("react.memo_cache_sentinel")?(n=()=>{e.current&&e.current.scrollTo({top:e.current.scrollHeight,behavior:"smooth"})},t[0]=n):n=t[0];let l;return t[1]!==c?(l=[c],t[1]=c,t[2]=l):l=t[2],S.useEffect(n,l),e}const Je=S.memo(function(){const t=D.c(34),{theme:e,businessInfo:n,toggleProfile:l}=Z(),i=e==="dark",x=n.brandColor||"#0084ff",r=`
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const s=require("react/jsx-runtime"),B=require("react/compiler-runtime"),M=require("react");function ue(c){return"reply"in c}function se(c){return"action"in c}function $e(c){if(!se(c))return!1;const{urlAction:t}=c.action;return t?.openUrl?.application==="WEBVIEW"}function je(c){const{urlAction:t}=c.action;return t?.openUrl?.application==="WEBVIEW"?t.openUrl:null}const ze={name:"Business",verified:!1},Ie={currentMessageId:null,chatHistory:[],isTyping:!1,error:null},we=M.createContext(null);function ve(c){const t=B.c(20),{children:e,theme:n,device:l,businessInfo:i,state:x,showSuggestions:r,isProfileOpen:o,toggleProfile:a,onReply:f,onAction:h,webView:d,openWebView:u,closeWebView:m}=c;let g;t[0]!==i?(g={...ze,...i},t[0]=i,t[1]=g):g=t[1];let p;t[2]!==x?(p={...Ie,...x},t[2]=x,t[3]=p):p=t[3];let y;t[4]!==m||t[5]!==l||t[6]!==o||t[7]!==h||t[8]!==f||t[9]!==u||t[10]!==r||t[11]!==g||t[12]!==p||t[13]!==n||t[14]!==a||t[15]!==d?(y={theme:n,device:l,businessInfo:g,state:p,showSuggestions:r,isProfileOpen:o,toggleProfile:a,handleReply:f,handleAction:h,webView:d,openWebView:u,closeWebView:m},t[4]=m,t[5]=l,t[6]=o,t[7]=h,t[8]=f,t[9]=u,t[10]=r,t[11]=g,t[12]=p,t[13]=n,t[14]=a,t[15]=d,t[16]=y):y=t[16];const j=y;let b;return t[17]!==e||t[18]!==j?(b=s.jsx(we.Provider,{value:j,children:e}),t[17]=e,t[18]=j,t[19]=b):b=t[19],b}function Z(){const c=M.useContext(we);if(!c)throw new Error("useEmulator must be used within an EmulatorProvider");return c}function ke(c){const t=Object.values(c.messages);return t.find(e=>e.is_first)||t[0]||null}function ae(c,t){return c.messages[t]||null}function he(c,t){const e=c.responses?.keyword?.keyword_response?.choices;return e&&e[t]?.next_message||null}function ce(c,t){const e=c.parts,n=Ae(e),l=Re(e);return{id:`${c.id}-${t}-${Date.now()}`,sender:"business",content:n,timestamp:Date.now(),suggestions:l}}function Ae(c){for(const t of c){const e=t.RCSMessage;if(e.textMessage)return{type:"text",text:e.textMessage};const n=e.richcardMessage?.message?.generalPurposeCard;if(n)return{type:"richcard",card:xe(n.content,n.layout)};const l=e.richcardMessage?.message?.generalPurposeCardCarousel;if(l)return{type:"carousel",cards:l.content.map(i=>xe(i,{cardOrientation:"VERTICAL",cardWidth:l.layout.cardWidth}))}}return{type:"text",text:"[Unsupported message type]"}}function xe(c,t){const e=()=>{if(c.media){if(c.media.mediaUrl)return c.media.mediaUrl;if(c.media.contentInfo?.fileUrl)return c.media.contentInfo.fileUrl}},n=()=>{if(c.media){if(c.media.thumbnailUri)return c.media.thumbnailUri;if(c.media.contentInfo?.thumbnailUrl)return c.media.contentInfo.thumbnailUrl}},l=e();return{title:c.title,description:c.description,media:l?{url:l,height:Te(c.media?.height||"MEDIUM_HEIGHT"),thumbnailUrl:n()}:void 0,suggestions:c.suggestions,layout:{orientation:t.cardOrientation==="HORIZONTAL"?"horizontal":"vertical",width:t.cardWidth==="SMALL_WIDTH"?"small":"medium",imageAlignment:t.imageAlignment==="RIGHT"?"right":"left"}}}function Te(c){switch(c){case"SHORT_HEIGHT":return"short";case"TALL_HEIGHT":return"tall";default:return"medium"}}function Re(c){const t=[];for(const e of c){const n=e.RCSMessage;n.suggestedChipList?.suggestions&&t.push(...n.suggestedChipList.suggestions)}return t}function Ee(c){return{id:`user-${Date.now()}`,sender:"user",content:{type:"userReply",text:c},timestamp:Date.now()}}function Ne(c){if(!c||typeof c!="object")return!1;const t=c;if(typeof t.name!="string"||!t.messages||typeof t.messages!="object")return!1;const e=Object.values(t.messages);if(e.length===0)return!1;for(const n of e){if(!n||typeof n!="object")return!1;const l=n;if(typeof l.id!="string"||!Array.isArray(l.parts))return!1}return!0}function Ce(c){const t=ke(c);if(!t||!t.parts.length)return"New message";const n=t.parts[0].RCSMessage;if(n.textMessage)return n.textMessage.slice(0,50)+(n.textMessage.length>50?"...":"");const l=n.richcardMessage?.message?.generalPurposeCard;if(l?.content.title)return l.content.title;const i=n.richcardMessage?.message?.generalPurposeCardCarousel;return i?.content[0]?.title?i.content[0].title:"New message"}const Le={currentMessageId:null,chatHistory:[],isTyping:!1,error:null};function Be(c,t){switch(t.type){case"INIT":return{...c,currentMessageId:t.messageId,error:null};case"ADD_BUSINESS_MESSAGE":return{...c,chatHistory:[...c.chatHistory,t.message],isTyping:!1};case"ADD_USER_REPLY":{const e=Ee(t.text),n=c.chatHistory.map((l,i)=>i===c.chatHistory.length-1?{...l,suggestions:void 0}:l);return{...c,chatHistory:[...n,e]}}case"SET_TYPING":return{...c,isTyping:t.isTyping};case"NAVIGATE_TO":return{...c,currentMessageId:t.messageId};case"SET_ERROR":return{...c,error:t.error,isTyping:!1};case"RESET":return Le;default:return c}}function We(c){const t=B.c(18),{flow:e,onUserReply:n,typingDelay:l}=c,i=l===void 0?800:l,[x,r]=M.useReducer(Be,Le),o=M.useRef(0),a=M.useRef(!1);let f,h;t[0]!==e?(f=()=>{if(a.current)return;a.current=!0;const b=ke(e);if(!b){r({type:"SET_ERROR",error:"No first message found in conversation flow"});return}r({type:"INIT",messageId:b.id}),o.current=o.current+1;const v=ce(b,o.current);r({type:"ADD_BUSINESS_MESSAGE",message:v})},h=[e],t[0]=e,t[1]=f,t[2]=h):(f=t[1],h=t[2]),M.useEffect(f,h);let d;t[3]!==e||t[4]!==n||t[5]!==x.currentMessageId||t[6]!==i?(d=b=>{if(!ue(b))return;const{displayText:v,postback:w}=b.reply,k=w.data;r({type:"ADD_USER_REPLY",text:v,postbackData:k});const N={type:"reply",postbackData:k,displayText:v,timestamp:Date.now()};n(N);const _=x.currentMessageId?ae(e,x.currentMessageId):null;if(!_){r({type:"SET_ERROR",error:"Current message not found"});return}const C=he(_,k);if(!C)return;const I=ae(e,C);if(!I){r({type:"SET_ERROR",error:`Next message "${C}" not found`});return}r({type:"SET_TYPING",isTyping:!0}),r({type:"NAVIGATE_TO",messageId:C}),setTimeout(()=>{o.current=o.current+1;const $=ce(I,o.current);r({type:"ADD_BUSINESS_MESSAGE",message:$})},i)},t[3]=e,t[4]=n,t[5]=x.currentMessageId,t[6]=i,t[7]=d):d=t[7];const u=d;let m;t[8]!==e||t[9]!==n||t[10]!==x.currentMessageId||t[11]!==i?(m=b=>{if(!se(b))return;const{displayText:v,postback:w,openUrlAction:k,dialAction:N,dialerAction:_,mapAction:C,viewLocationAction:I}=b.action,$=w.data,L=N?.phoneNumber||_?.dialPhoneNumber?.phoneNumber,S=C?.showLocation?.location||I?.latLong;let z;k?z={type:"openUrl",url:k.url}:L?z={type:"dial",phoneNumber:L}:S&&(z={type:"viewLocation",latitude:S.latitude,longitude:S.longitude,query:I?.query});const A={type:"action",postbackData:$,displayText:v,timestamp:Date.now(),actionData:z};if(n(A),k)window.open(k.url,"_blank","noopener,noreferrer");else if(L)window.location.href=`tel:${L}`;else if(S){const T=C?.showLocation?.location?.label||I?.label||"",O=`https://www.google.com/maps/search/?api=1&query=${S.latitude},${S.longitude}${T?`&query_place_id=${encodeURIComponent(T)}`:""}`;window.open(O,"_blank","noopener,noreferrer")}const W=x.currentMessageId?ae(e,x.currentMessageId):null;if(W){const T=he(W,$);if(T){const O=ae(e,T);O&&(r({type:"ADD_USER_REPLY",text:v,postbackData:$}),r({type:"SET_TYPING",isTyping:!0}),r({type:"NAVIGATE_TO",messageId:T}),setTimeout(()=>{o.current=o.current+1;const F=ce(O,o.current);r({type:"ADD_BUSINESS_MESSAGE",message:F})},i))}}},t[8]=e,t[9]=n,t[10]=x.currentMessageId,t[11]=i,t[12]=m):m=t[12];const g=m;let p;t[13]===Symbol.for("react.memo_cache_sentinel")?(p=()=>{a.current=!1,o.current=0,r({type:"RESET"})},t[13]=p):p=t[13];const y=p;let j;return t[14]!==g||t[15]!==u||t[16]!==x?(j={state:x,handleReply:u,handleAction:g,reset:y},t[14]=g,t[15]=u,t[16]=x,t[17]=j):j=t[17],j}function _e(c){const[t,e]=M.useState(null),[n,l]=M.useState(!1),[i,x]=M.useState(null),r=M.useCallback(async()=>{if(!c){e(null),x(null);return}l(!0),x(null);try{const o=await fetch(c,{method:"GET",headers:{Accept:"application/json"}});if(!o.ok)throw new Error(`HTTP ${o.status}: ${o.statusText}`);const a=await o.json();if(!a||typeof a!="object")throw new Error("Invalid JSON: Expected an object");if(!a.messages||typeof a.messages!="object")throw new Error("Invalid RBM JSON: Missing 'messages' object");e(a)}catch(o){const a=o instanceof Error?o.message:"Failed to fetch JSON";x(a),e(null)}finally{l(!1)}},[c]);return M.useEffect(()=>{r()},[r]),{data:t,isLoading:n,error:i,refetch:r}}function De(c){const t=B.c(3),e=M.useRef(null);let n;t[0]===Symbol.for("react.memo_cache_sentinel")?(n=()=>{e.current&&e.current.scrollTo({top:e.current.scrollHeight,behavior:"smooth"})},t[0]=n):n=t[0];let l;return t[1]!==c?(l=[c],t[1]=c,t[2]=l):l=t[2],M.useEffect(n,l),e}const Ve=M.memo(function(){const t=B.c(34),{theme:e,businessInfo:n,toggleProfile:l}=Z(),i=e==="dark",x=n.brandColor||"#0084ff",r=`
6
2
  flex items-center gap-3 px-3 py-2.5 border-b
7
3
  ${i?"bg-zinc-900 border-zinc-800":"bg-white border-gray-100"}
8
4
  `,o=`Chat with ${n.name}`,a=`
@@ -14,13 +10,13 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
14
10
  `,u=n.logo?void 0:x;let m;t[3]!==u?(m={backgroundColor:u},t[3]=u,t[4]=m):m=t[4];let g;t[5]!==n.logo||t[6]!==n.name?(g=n.logo?s.jsx("img",{src:n.logo,alt:`${n.name} logo`,className:"w-full h-full object-cover"}):s.jsx("div",{className:"w-full h-full flex items-center justify-center text-sm font-bold text-white",children:n.name.charAt(0).toUpperCase()}),t[5]=n.logo,t[6]=n.name,t[7]=g):g=t[7];let p;t[8]!==d||t[9]!==m||t[10]!==g?(p=s.jsx("div",{className:d,style:m,children:g}),t[8]=d,t[9]=m,t[10]=g,t[11]=p):p=t[11];const y=`
15
11
  text-base font-medium truncate
16
12
  ${i?"text-white":"text-gray-900"}
17
- `;let j;t[12]!==n.name||t[13]!==y?(j=s.jsx("h1",{className:y,children:n.name}),t[12]=n.name,t[13]=y,t[14]=j):j=t[14];let b;t[15]!==j||t[16]!==p||t[17]!==l?(b=s.jsxs("button",{onClick:l,className:"flex items-center gap-2.5 flex-1 min-w-0 text-left","aria-label":"View business info",children:[p,j]}),t[15]=j,t[16]=p,t[17]=l,t[18]=b):b=t[18];let w;t[19]!==n.verified||t[20]!==i?(w=n.verified&&s.jsx("button",{type:"button",className:`
13
+ `;let j;t[12]!==n.name||t[13]!==y?(j=s.jsx("h1",{className:y,children:n.name}),t[12]=n.name,t[13]=y,t[14]=j):j=t[14];let b;t[15]!==j||t[16]!==p||t[17]!==l?(b=s.jsxs("button",{onClick:l,className:"flex items-center gap-2.5 flex-1 min-w-0 text-left","aria-label":"View business info",children:[p,j]}),t[15]=j,t[16]=p,t[17]=l,t[18]=b):b=t[18];let v;t[19]!==n.verified||t[20]!==i?(v=n.verified&&s.jsx("button",{type:"button",className:`
18
14
  p-2 rounded-full transition-colors
19
15
  ${i?"hover:bg-zinc-800":"hover:bg-gray-100"}
20
- `,"aria-label":"Verified business",children:s.jsxs("svg",{className:"w-5 h-5",viewBox:"0 0 24 24",fill:"none",children:[s.jsx("path",{d:"M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z",stroke:i?"#9ca3af":"#6b7280",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),s.jsx("path",{d:"M9 12l2 2 4-4",stroke:"#3b82f6",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})}),t[19]=n.verified,t[20]=i,t[21]=w):w=t[21];const v=`
16
+ `,"aria-label":"Verified business",children:s.jsxs("svg",{className:"w-5 h-5",viewBox:"0 0 24 24",fill:"none",children:[s.jsx("path",{d:"M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z",stroke:i?"#9ca3af":"#6b7280",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"}),s.jsx("path",{d:"M9 12l2 2 4-4",stroke:"#3b82f6",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"})]})}),t[19]=n.verified,t[20]=i,t[21]=v):v=t[21];const w=`
21
17
  p-2 rounded-full transition-colors
22
18
  ${i?"hover:bg-zinc-800 text-zinc-400":"hover:bg-gray-100 text-gray-500"}
23
- `;let k;t[22]===Symbol.for("react.memo_cache_sentinel")?(k=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 5v.01M12 12v.01M12 19v.01M12 6a1 1 0 110-2 1 1 0 010 2zm0 7a1 1 0 110-2 1 1 0 010 2zm0 7a1 1 0 110-2 1 1 0 010 2z"})}),t[22]=k):k=t[22];let N;t[23]!==v?(N=s.jsx("button",{type:"button",className:v,"aria-label":"More options",children:k}),t[23]=v,t[24]=N):N=t[24];let L;t[25]!==w||t[26]!==N?(L=s.jsxs("div",{className:"flex items-center gap-0.5",children:[w,N]}),t[25]=w,t[26]=N,t[27]=L):L=t[27];let C;return t[28]!==r||t[29]!==o||t[30]!==b||t[31]!==L||t[32]!==h?(C=s.jsxs("header",{className:r,role:"banner","aria-label":o,children:[h,b,L]}),t[28]=r,t[29]=o,t[30]=b,t[31]=L,t[32]=h,t[33]=C):C=t[33],C}),Qe=S.memo(function(){const t=D.c(24),{theme:e,businessInfo:n}=Z(),l=e==="dark",i=n.brandColor||"#0084ff",x=`
19
+ `;let k;t[22]===Symbol.for("react.memo_cache_sentinel")?(k=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 5v.01M12 12v.01M12 19v.01M12 6a1 1 0 110-2 1 1 0 010 2zm0 7a1 1 0 110-2 1 1 0 010 2zm0 7a1 1 0 110-2 1 1 0 010 2z"})}),t[22]=k):k=t[22];let N;t[23]!==w?(N=s.jsx("button",{type:"button",className:w,"aria-label":"More options",children:k}),t[23]=w,t[24]=N):N=t[24];let _;t[25]!==v||t[26]!==N?(_=s.jsxs("div",{className:"flex items-center gap-0.5",children:[v,N]}),t[25]=v,t[26]=N,t[27]=_):_=t[27];let C;return t[28]!==r||t[29]!==o||t[30]!==b||t[31]!==_||t[32]!==h?(C=s.jsxs("header",{className:r,role:"banner","aria-label":o,children:[h,b,_]}),t[28]=r,t[29]=o,t[30]=b,t[31]=_,t[32]=h,t[33]=C):C=t[33],C}),Ue=M.memo(function(){const t=B.c(24),{theme:e,businessInfo:n}=Z(),l=e==="dark",i=n.brandColor||"#0084ff",x=`
24
20
  w-16 h-16 rounded-full overflow-hidden
25
21
  ${l?"bg-zinc-800":"bg-gray-100"}
26
22
  shadow-lg
@@ -30,10 +26,10 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
30
26
  `;let m;t[14]!==n.name||t[15]!==u?(m=s.jsx("h1",{className:u,children:n.name}),t[14]=n.name,t[15]=u,t[16]=m):m=t[16];let g;t[17]!==n.description||t[18]!==l?(g=n.description&&s.jsx("p",{className:`
31
27
  text-sm text-center mt-0.5
32
28
  ${l?"text-zinc-400":"text-gray-500"}
33
- `,children:n.description}),t[17]=n.description,t[18]=l,t[19]=g):g=t[19];let p;return t[20]!==d||t[21]!==m||t[22]!==g?(p=s.jsxs("div",{className:"flex flex-col items-center py-4 px-4",children:[d,m,g]}),t[20]=d,t[21]=m,t[22]=g,t[23]=p):p=t[23],p}),Xe=S.memo(function(t){const e=D.c(26),{text:n,sender:l,timestamp:i}=t,{theme:x,businessInfo:r}=Z(),o=x==="dark",a=l==="business",f=r.brandColor||"#0084ff";let h;e[0]!==i?(h=new Date(i).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=i,e[1]=h):h=e[1];const d=h;if(a){const w=`
29
+ `,children:n.description}),t[17]=n.description,t[18]=l,t[19]=g):g=t[19];let p;return t[20]!==d||t[21]!==m||t[22]!==g?(p=s.jsxs("div",{className:"flex flex-col items-center py-4 px-4",children:[d,m,g]}),t[20]=d,t[21]=m,t[22]=g,t[23]=p):p=t[23],p}),He=M.memo(function(t){const e=B.c(26),{text:n,sender:l,timestamp:i}=t,{theme:x,businessInfo:r}=Z(),o=x==="dark",a=l==="business",f=r.brandColor||"#0084ff";let h;e[0]!==i?(h=new Date(i).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=i,e[1]=h):h=e[1];const d=h;if(a){const v=`
34
30
  px-4 py-3 rounded-2xl text-sm leading-relaxed
35
31
  ${o?"bg-zinc-800 text-white":"bg-gray-100 text-gray-900"}
36
- `;let v;e[2]!==w||e[3]!==n?(v=s.jsx("div",{className:w,children:n}),e[2]=w,e[3]=n,e[4]=v):v=e[4];let k;e[5]!==d?(k=s.jsx("span",{className:"sr-only",children:d}),e[5]=d,e[6]=k):k=e[6];let N;return e[7]!==v||e[8]!==k?(N=s.jsxs("div",{className:"max-w-[90%]",children:[v,k]}),e[7]=v,e[8]=k,e[9]=N):N=e[9],N}let u;e[10]!==f?(u={backgroundColor:f},e[10]=f,e[11]=u):u=e[11];let m;e[12]!==u||e[13]!==n?(m=s.jsx("div",{className:"px-4 py-2.5 rounded-full text-white text-sm leading-relaxed",style:u,children:n}),e[12]=u,e[13]=n,e[14]=m):m=e[14];let g;e[15]!==f?(g={backgroundColor:f},e[15]=f,e[16]=g):g=e[16];let p;e[17]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx("svg",{className:"w-3 h-3 text-white",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:3,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 13l4 4L19 7"})}),e[17]=p):p=e[17];let y;e[18]!==g?(y=s.jsx("div",{className:"w-5 h-5 rounded-full flex items-center justify-center flex-shrink-0",style:g,children:p}),e[18]=g,e[19]=y):y=e[19];let j;e[20]!==d?(j=s.jsx("span",{className:"sr-only",children:d}),e[20]=d,e[21]=j):j=e[21];let b;return e[22]!==m||e[23]!==y||e[24]!==j?(b=s.jsxs("div",{className:"flex items-end gap-1.5 max-w-[85%] ml-auto",children:[m,y,j]}),e[22]=m,e[23]=y,e[24]=j,e[25]=b):b=e[25],b}),Ze=S.memo(function(t){const e=D.c(18),{text:n,timestamp:l}=t,{businessInfo:i}=Z(),x=i.brandColor||"#0084ff";let r;e[0]!==l?(r=new Date(l).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=l,e[1]=r):r=e[1];const o=r;let a;e[2]!==x?(a={backgroundColor:x},e[2]=x,e[3]=a):a=e[3];let f;e[4]!==a||e[5]!==n?(f=s.jsx("div",{className:"px-4 py-2.5 rounded-full text-white text-sm leading-relaxed shadow-sm",style:a,children:n}),e[4]=a,e[5]=n,e[6]=f):f=e[6];let h;e[7]!==x?(h={backgroundColor:x},e[7]=x,e[8]=h):h=e[8];let d;e[9]===Symbol.for("react.memo_cache_sentinel")?(d=s.jsx("svg",{className:"w-3 h-3 text-white",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:3,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 13l4 4L19 7"})}),e[9]=d):d=e[9];let u;e[10]!==h?(u=s.jsx("div",{className:"w-5 h-5 rounded-full flex items-center justify-center flex-shrink-0",style:h,children:d}),e[10]=h,e[11]=u):u=e[11];let m;e[12]!==o?(m=s.jsx("span",{className:"sr-only",children:o}),e[12]=o,e[13]=m):m=e[13];let g;return e[14]!==f||e[15]!==u||e[16]!==m?(g=s.jsxs("div",{className:"flex items-end gap-1.5 max-w-[85%] ml-auto",children:[f,u,m]}),e[14]=f,e[15]=u,e[16]=m,e[17]=g):g=e[17],g}),Ke=S.memo(function(t){const e=D.c(32),{card:n,timestamp:l}=t,{theme:i,handleReply:x,handleAction:r}=Z(),o=i==="dark";let a;e[0]!==l?(a=new Date(l).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=l,e[1]=a):a=e[1];const f=a;let h;e[2]!==r||e[3]!==x?(h=C=>{"reply"in C?x(C):r(C)},e[2]=r,e[3]=x,e[4]=h):h=e[4];const d=h;let u;e[5]===Symbol.for("react.memo_cache_sentinel")?(u={short:"h-36",medium:"h-44",tall:"h-56"},e[5]=u):u=e[5];const m=u,p=`
32
+ `;let w;e[2]!==v||e[3]!==n?(w=s.jsx("div",{className:v,children:n}),e[2]=v,e[3]=n,e[4]=w):w=e[4];let k;e[5]!==d?(k=s.jsx("span",{className:"sr-only",children:d}),e[5]=d,e[6]=k):k=e[6];let N;return e[7]!==w||e[8]!==k?(N=s.jsxs("div",{className:"max-w-[90%]",children:[w,k]}),e[7]=w,e[8]=k,e[9]=N):N=e[9],N}let u;e[10]!==f?(u={backgroundColor:f},e[10]=f,e[11]=u):u=e[11];let m;e[12]!==u||e[13]!==n?(m=s.jsx("div",{className:"px-4 py-2.5 rounded-full text-white text-sm leading-relaxed",style:u,children:n}),e[12]=u,e[13]=n,e[14]=m):m=e[14];let g;e[15]!==f?(g={backgroundColor:f},e[15]=f,e[16]=g):g=e[16];let p;e[17]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx("svg",{className:"w-3 h-3 text-white",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:3,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 13l4 4L19 7"})}),e[17]=p):p=e[17];let y;e[18]!==g?(y=s.jsx("div",{className:"w-5 h-5 rounded-full flex items-center justify-center flex-shrink-0",style:g,children:p}),e[18]=g,e[19]=y):y=e[19];let j;e[20]!==d?(j=s.jsx("span",{className:"sr-only",children:d}),e[20]=d,e[21]=j):j=e[21];let b;return e[22]!==m||e[23]!==y||e[24]!==j?(b=s.jsxs("div",{className:"flex items-end gap-1.5 max-w-[85%] ml-auto",children:[m,y,j]}),e[22]=m,e[23]=y,e[24]=j,e[25]=b):b=e[25],b}),Oe=M.memo(function(t){const e=B.c(18),{text:n,timestamp:l}=t,{businessInfo:i}=Z(),x=i.brandColor||"#0084ff";let r;e[0]!==l?(r=new Date(l).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=l,e[1]=r):r=e[1];const o=r;let a;e[2]!==x?(a={backgroundColor:x},e[2]=x,e[3]=a):a=e[3];let f;e[4]!==a||e[5]!==n?(f=s.jsx("div",{className:"px-4 py-2.5 rounded-full text-white text-sm leading-relaxed shadow-sm",style:a,children:n}),e[4]=a,e[5]=n,e[6]=f):f=e[6];let h;e[7]!==x?(h={backgroundColor:x},e[7]=x,e[8]=h):h=e[8];let d;e[9]===Symbol.for("react.memo_cache_sentinel")?(d=s.jsx("svg",{className:"w-3 h-3 text-white",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:3,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M5 13l4 4L19 7"})}),e[9]=d):d=e[9];let u;e[10]!==h?(u=s.jsx("div",{className:"w-5 h-5 rounded-full flex items-center justify-center flex-shrink-0",style:h,children:d}),e[10]=h,e[11]=u):u=e[11];let m;e[12]!==o?(m=s.jsx("span",{className:"sr-only",children:o}),e[12]=o,e[13]=m):m=e[13];let g;return e[14]!==f||e[15]!==u||e[16]!==m?(g=s.jsxs("div",{className:"flex items-end gap-1.5 max-w-[85%] ml-auto",children:[f,u,m]}),e[14]=f,e[15]=u,e[16]=m,e[17]=g):g=e[17],g}),Pe=M.memo(function(t){const e=B.c(32),{card:n,timestamp:l}=t,{theme:i,handleReply:x,handleAction:r}=Z(),o=i==="dark";let a;e[0]!==l?(a=new Date(l).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=l,e[1]=a):a=e[1];const f=a;let h;e[2]!==r||e[3]!==x?(h=C=>{"reply"in C?x(C):r(C)},e[2]=r,e[3]=x,e[4]=h):h=e[4];const d=h;let u;e[5]===Symbol.for("react.memo_cache_sentinel")?(u={short:"h-36",medium:"h-44",tall:"h-56"},e[5]=u):u=e[5];const m=u,p=`
37
33
  overflow-hidden rounded-2xl w-full shadow-sm
38
34
  ${o?"bg-zinc-800":"bg-[#e8f5e9]"}
39
35
  `;let y;e[6]!==n.media||e[7]!==n.title?(y=n.media&&s.jsx("div",{className:`
@@ -45,23 +41,23 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
45
41
  `,children:n.title}),e[9]=n.title,e[10]=o,e[11]=j):j=e[11];let b;e[12]!==n.description||e[13]!==o?(b=n.description&&s.jsx("p",{className:`
46
42
  text-sm leading-relaxed mt-1.5
47
43
  ${o?"text-zinc-300":"text-gray-700"}
48
- `,children:n.description}),e[12]=n.description,e[13]=o,e[14]=b):b=e[14];let w;e[15]!==n.suggestions||e[16]!==d||e[17]!==o?(w=n.suggestions&&n.suggestions.length>0&&s.jsx("div",{className:`
44
+ `,children:n.description}),e[12]=n.description,e[13]=o,e[14]=b):b=e[14];let v;e[15]!==n.suggestions||e[16]!==d||e[17]!==o?(v=n.suggestions&&n.suggestions.length>0&&s.jsx("div",{className:`
49
45
  mt-4 rounded-xl overflow-hidden divide-y
50
46
  ${o?"divide-zinc-700 bg-zinc-800":"divide-gray-100 bg-white"}
51
- `,children:n.suggestions.map((C,R)=>s.jsx(lt,{suggestion:C,onClick:()=>d(C),isDark:o},R))}),e[15]=n.suggestions,e[16]=d,e[17]=o,e[18]=w):w=e[18];let v;e[19]!==j||e[20]!==b||e[21]!==w?(v=s.jsxs("div",{className:"p-4",children:[j,b,w]}),e[19]=j,e[20]=b,e[21]=w,e[22]=v):v=e[22];let k;e[23]!==p||e[24]!==y||e[25]!==v?(k=s.jsxs("div",{className:p,children:[y,v]}),e[23]=p,e[24]=y,e[25]=v,e[26]=k):k=e[26];let N;e[27]!==f?(N=s.jsx("span",{className:"sr-only",children:f}),e[27]=f,e[28]=N):N=e[28];let L;return e[29]!==k||e[30]!==N?(L=s.jsxs("div",{className:"w-full",children:[k,N]}),e[29]=k,e[30]=N,e[31]=L):L=e[31],L}),re="w-5 h-5 text-gray-400",et=()=>{const c=D.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}),c[0]=t):t=c[0],t},tt=()=>{const c=D.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"})}),c[0]=t):t=c[0],t},st=()=>{const c=D.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsxs("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}),c[0]=t):t=c[0],t},nt=()=>{const c=D.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"})}),c[0]=t):t=c[0],t},we=()=>{const c=D.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"})}),c[0]=t):t=c[0],t},lt=S.memo(function(t){const e=D.c(15),{suggestion:n,onClick:l,isDark:i}=t;let x;e[0]!==n?(x=se(n),e[0]=n,e[1]=x):x=e[1];const r=x,o=r?n.action.displayText:n.reply.displayText;let a;e[2]!==r||e[3]!==n?(a=()=>{if(!r)return s.jsx(we,{});const{action:p}=n;return p.urlAction||p.openUrlAction?s.jsx(et,{}):p.dialerAction||p.dialAction?s.jsx(tt,{}):p.mapAction||p.viewLocationAction?s.jsx(st,{}):p.calendarAction||p.createCalendarEventAction?s.jsx(nt,{}):s.jsx(we,{})},e[2]=r,e[3]=n,e[4]=a):a=e[4];const f=a,h=`
47
+ `,children:n.suggestions.map((C,I)=>s.jsx(Ye,{suggestion:C,onClick:()=>d(C),isDark:o},I))}),e[15]=n.suggestions,e[16]=d,e[17]=o,e[18]=v):v=e[18];let w;e[19]!==j||e[20]!==b||e[21]!==v?(w=s.jsxs("div",{className:"p-4",children:[j,b,v]}),e[19]=j,e[20]=b,e[21]=v,e[22]=w):w=e[22];let k;e[23]!==p||e[24]!==y||e[25]!==w?(k=s.jsxs("div",{className:p,children:[y,w]}),e[23]=p,e[24]=y,e[25]=w,e[26]=k):k=e[26];let N;e[27]!==f?(N=s.jsx("span",{className:"sr-only",children:f}),e[27]=f,e[28]=N):N=e[28];let _;return e[29]!==k||e[30]!==N?(_=s.jsxs("div",{className:"w-full",children:[k,N]}),e[29]=k,e[30]=N,e[31]=_):_=e[31],_}),re="w-5 h-5 text-gray-400",Ge=()=>{const c=B.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}),c[0]=t):t=c[0],t},Fe=()=>{const c=B.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"})}),c[0]=t):t=c[0],t},qe=()=>{const c=B.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsxs("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}),c[0]=t):t=c[0],t},Je=()=>{const c=B.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"})}),c[0]=t):t=c[0],t},ge=()=>{const c=B.c(1);let t;return c[0]===Symbol.for("react.memo_cache_sentinel")?(t=s.jsx("svg",{className:re,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"})}),c[0]=t):t=c[0],t},Ye=M.memo(function(t){const e=B.c(15),{suggestion:n,onClick:l,isDark:i}=t;let x;e[0]!==n?(x=se(n),e[0]=n,e[1]=x):x=e[1];const r=x,o=r?n.action.displayText:n.reply.displayText;let a;e[2]!==r||e[3]!==n?(a=()=>{if(!r)return s.jsx(ge,{});const{action:p}=n;return p.urlAction||p.openUrlAction?s.jsx(Ge,{}):p.dialerAction||p.dialAction?s.jsx(Fe,{}):p.mapAction||p.viewLocationAction?s.jsx(qe,{}):p.calendarAction||p.createCalendarEventAction?s.jsx(Je,{}):s.jsx(ge,{})},e[2]=r,e[3]=n,e[4]=a):a=e[4];const f=a,h=`
52
48
  w-full flex items-center gap-3 px-4 py-3 text-left transition-colors
53
49
  ${i?"hover:bg-zinc-700":"hover:bg-gray-50"}
54
- `;let d;e[5]!==f?(d=s.jsx("span",{className:"flex-shrink-0",children:f()}),e[5]=f,e[6]=d):d=e[6];const u=`text-sm ${i?"text-white":"text-gray-900"}`;let m;e[7]!==o||e[8]!==u?(m=s.jsx("span",{className:u,children:o}),e[7]=o,e[8]=u,e[9]=m):m=e[9];let g;return e[10]!==l||e[11]!==h||e[12]!==d||e[13]!==m?(g=s.jsxs("button",{onClick:l,className:h,children:[d,m]}),e[10]=l,e[11]=h,e[12]=d,e[13]=m,e[14]=g):g=e[14],g}),rt=S.memo(function(t){const e=D.c(32),{cards:n,timestamp:l}=t,{theme:i,handleReply:x,handleAction:r}=Z(),o=S.useRef(null),[a,f]=S.useState(!1),[h,d]=S.useState(n.length>1),u=i==="dark";let m;e[0]!==l?(m=new Date(l).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=l,e[1]=m):m=e[1];const g=m;let p;e[2]!==r||e[3]!==x?(p=z=>{"reply"in z?x(z):r(z)},e[2]=r,e[3]=x,e[4]=p):p=e[4];const y=p;let j;e[5]===Symbol.for("react.memo_cache_sentinel")?(j=()=>{if(o.current){const{scrollLeft:z,scrollWidth:I,clientWidth:B}=o.current;f(z>0),d(z<I-B-10)}},e[5]=j):j=e[5];const b=j;let w;e[6]===Symbol.for("react.memo_cache_sentinel")?(w=z=>{o.current&&o.current.scrollBy({left:z==="left"?-200:200,behavior:"smooth"})},e[6]=w):w=e[6];const v=w;let k;e[7]!==a||e[8]!==u?(k=a&&s.jsx("button",{onClick:()=>v("left"),className:`
50
+ `;let d;e[5]!==f?(d=s.jsx("span",{className:"flex-shrink-0",children:f()}),e[5]=f,e[6]=d):d=e[6];const u=`text-sm ${i?"text-white":"text-gray-900"}`;let m;e[7]!==o||e[8]!==u?(m=s.jsx("span",{className:u,children:o}),e[7]=o,e[8]=u,e[9]=m):m=e[9];let g;return e[10]!==l||e[11]!==h||e[12]!==d||e[13]!==m?(g=s.jsxs("button",{onClick:l,className:h,children:[d,m]}),e[10]=l,e[11]=h,e[12]=d,e[13]=m,e[14]=g):g=e[14],g}),Qe=M.memo(function(t){const e=B.c(32),{cards:n,timestamp:l}=t,{theme:i,handleReply:x,handleAction:r}=Z(),o=M.useRef(null),[a,f]=M.useState(!1),[h,d]=M.useState(n.length>1),u=i==="dark";let m;e[0]!==l?(m=new Date(l).toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}),e[0]=l,e[1]=m):m=e[1];const g=m;let p;e[2]!==r||e[3]!==x?(p=z=>{"reply"in z?x(z):r(z)},e[2]=r,e[3]=x,e[4]=p):p=e[4];const y=p;let j;e[5]===Symbol.for("react.memo_cache_sentinel")?(j=()=>{if(o.current){const{scrollLeft:z,scrollWidth:A,clientWidth:W}=o.current;f(z>0),d(z<A-W-10)}},e[5]=j):j=e[5];const b=j;let v;e[6]===Symbol.for("react.memo_cache_sentinel")?(v=z=>{o.current&&o.current.scrollBy({left:z==="left"?-200:200,behavior:"smooth"})},e[6]=v):v=e[6];const w=v;let k;e[7]!==a||e[8]!==u?(k=a&&s.jsx("button",{onClick:()=>w("left"),className:`
55
51
  absolute left-2 top-1/2 -translate-y-1/2 z-10
56
52
  w-8 h-8 rounded-full flex items-center justify-center
57
53
  shadow-lg transition-opacity
58
54
  ${u?"bg-zinc-700 text-white":"bg-white text-gray-700"}
59
- `,"aria-label":"Scroll left",children:s.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),e[7]=a,e[8]=u,e[9]=k):k=e[9];let N;e[10]===Symbol.for("react.memo_cache_sentinel")?(N={scrollbarWidth:"none",msOverflowStyle:"none"},e[10]=N):N=e[10];let L;if(e[11]!==n||e[12]!==y||e[13]!==u){let z;e[15]!==y||e[16]!==u?(z=(I,B)=>s.jsx(it,{card:I,isDark:u,onSuggestionClick:y},B),e[15]=y,e[16]=u,e[17]=z):z=e[17],L=n.map(z),e[11]=n,e[12]=y,e[13]=u,e[14]=L}else L=e[14];let C;e[18]!==L?(C=s.jsx("div",{ref:o,onScroll:b,className:"flex gap-2.5 overflow-x-auto py-1 px-3 snap-x snap-mandatory",style:N,children:L}),e[18]=L,e[19]=C):C=e[19];let R;e[20]!==h||e[21]!==u?(R=h&&s.jsx("button",{onClick:()=>v("right"),className:`
55
+ `,"aria-label":"Scroll left",children:s.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),e[7]=a,e[8]=u,e[9]=k):k=e[9];let N;e[10]===Symbol.for("react.memo_cache_sentinel")?(N={scrollbarWidth:"none",msOverflowStyle:"none"},e[10]=N):N=e[10];let _;if(e[11]!==n||e[12]!==y||e[13]!==u){let z;e[15]!==y||e[16]!==u?(z=(A,W)=>s.jsx(Ze,{card:A,isDark:u,onSuggestionClick:y},W),e[15]=y,e[16]=u,e[17]=z):z=e[17],_=n.map(z),e[11]=n,e[12]=y,e[13]=u,e[14]=_}else _=e[14];let C;e[18]!==_?(C=s.jsx("div",{ref:o,onScroll:b,className:"flex gap-2.5 overflow-x-auto py-1 px-3 snap-x snap-mandatory",style:N,children:_}),e[18]=_,e[19]=C):C=e[19];let I;e[20]!==h||e[21]!==u?(I=h&&s.jsx("button",{onClick:()=>w("right"),className:`
60
56
  absolute right-2 top-1/2 -translate-y-1/2 z-10
61
57
  w-8 h-8 rounded-full flex items-center justify-center
62
58
  shadow-lg transition-opacity
63
59
  ${u?"bg-zinc-700 text-white":"bg-white text-gray-700"}
64
- `,"aria-label":"Scroll right",children:s.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5l7 7-7 7"})})}),e[20]=h,e[21]=u,e[22]=R):R=e[22];let $;e[23]!==k||e[24]!==C||e[25]!==R?($=s.jsxs("div",{className:"relative",children:[k,C,R]}),e[23]=k,e[24]=C,e[25]=R,e[26]=$):$=e[26];let _;e[27]!==g?(_=s.jsx("span",{className:"sr-only",children:g}),e[27]=g,e[28]=_):_=e[28];let M;return e[29]!==$||e[30]!==_?(M=s.jsxs("div",{className:"w-full -mx-3",children:[$,_]}),e[29]=$,e[30]=_,e[31]=M):M=e[31],M}),le="w-4 h-4 text-gray-400",ot=c=>{if(!se(c))return s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"})});const{action:t}=c;return t.urlAction||t.openUrlAction?s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}):t.dialerAction||t.dialAction?s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"})}):t.mapAction||t.viewLocationAction?s.jsxs("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}):t.calendarAction||t.createCalendarEventAction?s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"})}):s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"})})},it=S.memo(function(t){const e=D.c(21),{card:n,isDark:l,onSuggestionClick:i}=t,r=`
60
+ `,"aria-label":"Scroll right",children:s.jsx("svg",{className:"w-4 h-4",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5l7 7-7 7"})})}),e[20]=h,e[21]=u,e[22]=I):I=e[22];let $;e[23]!==k||e[24]!==C||e[25]!==I?($=s.jsxs("div",{className:"relative",children:[k,C,I]}),e[23]=k,e[24]=C,e[25]=I,e[26]=$):$=e[26];let L;e[27]!==g?(L=s.jsx("span",{className:"sr-only",children:g}),e[27]=g,e[28]=L):L=e[28];let S;return e[29]!==$||e[30]!==L?(S=s.jsxs("div",{className:"w-full -mx-3",children:[$,L]}),e[29]=$,e[30]=L,e[31]=S):S=e[31],S}),le="w-4 h-4 text-gray-400",Xe=c=>{if(!se(c))return s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"})});const{action:t}=c;return t.urlAction||t.openUrlAction?s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}):t.dialerAction||t.dialAction?s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"})}):t.mapAction||t.viewLocationAction?s.jsxs("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}):t.calendarAction||t.createCalendarEventAction?s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"})}):s.jsx("svg",{className:le,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"})})},Ze=M.memo(function(t){const e=B.c(21),{card:n,isDark:l,onSuggestionClick:i}=t,r=`
65
61
  flex-shrink-0 snap-start rounded-2xl overflow-hidden shadow-sm
66
62
  ${n.layout.width==="small"?"w-44":"w-52"}
67
63
  ${l?"bg-zinc-800":"bg-[#e8f5e9]"}
@@ -78,7 +74,7 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
78
74
  w-full flex items-center gap-2 px-3 py-2.5
79
75
  text-xs transition-colors text-left
80
76
  ${l?"hover:bg-zinc-600 text-white":"hover:bg-gray-50 text-gray-900"}
81
- `,children:[s.jsx("span",{className:"flex-shrink-0",children:ot(m)}),s.jsx("span",{className:"truncate",children:y})]},g)})}),e[9]=n.suggestions,e[10]=l,e[11]=i,e[12]=h):h=e[12];let d;e[13]!==a||e[14]!==f||e[15]!==h?(d=s.jsxs("div",{className:"p-3",children:[a,f,h]}),e[13]=a,e[14]=f,e[15]=h,e[16]=d):d=e[16];let u;return e[17]!==r||e[18]!==o||e[19]!==d?(u=s.jsxs("div",{className:r,children:[o,d]}),e[17]=r,e[18]=o,e[19]=d,e[20]=u):u=e[20],u}),at={text:({content:c,sender:t,timestamp:e})=>c.type!=="text"?null:s.jsx(Xe,{text:c.text,sender:t,timestamp:e}),userReply:({content:c,timestamp:t})=>c.type!=="userReply"?null:s.jsx(Ze,{text:c.text,timestamp:t}),richcard:({content:c,timestamp:t})=>c.type!=="richcard"?null:s.jsx(Ke,{card:c.card,timestamp:t}),carousel:({content:c,timestamp:t})=>c.type!=="carousel"?null:s.jsx(rt,{cards:c.cards,timestamp:t})},ct=S.memo(function(t){const e=D.c(7),{message:n,isLast:l}=t,{content:i,sender:x,timestamp:r}=n,o=at[i.type];if(!o){console.warn(`Unknown message type: ${i.type}`);let h;return e[0]===Symbol.for("react.memo_cache_sentinel")?(h=s.jsx("div",{className:"px-4 py-2 text-gray-500 text-sm italic",children:"[Unsupported message type]"}),e[0]=h):h=e[0],h}const a=l&&x==="business";let f;return e[1]!==o||e[2]!==i||e[3]!==x||e[4]!==a||e[5]!==r?(f=s.jsx(o,{content:i,sender:x,timestamp:r,showSuggestions:a}),e[1]=o,e[2]=i,e[3]=x,e[4]=a,e[5]=r,e[6]=f):f=e[6],f}),dt=S.memo(function(){const t=D.c(11),{theme:e}=Z(),n=e==="dark",l=`
77
+ `,children:[s.jsx("span",{className:"flex-shrink-0",children:Xe(m)}),s.jsx("span",{className:"truncate",children:y})]},g)})}),e[9]=n.suggestions,e[10]=l,e[11]=i,e[12]=h):h=e[12];let d;e[13]!==a||e[14]!==f||e[15]!==h?(d=s.jsxs("div",{className:"p-3",children:[a,f,h]}),e[13]=a,e[14]=f,e[15]=h,e[16]=d):d=e[16];let u;return e[17]!==r||e[18]!==o||e[19]!==d?(u=s.jsxs("div",{className:r,children:[o,d]}),e[17]=r,e[18]=o,e[19]=d,e[20]=u):u=e[20],u}),Ke={text:({content:c,sender:t,timestamp:e})=>c.type!=="text"?null:s.jsx(He,{text:c.text,sender:t,timestamp:e}),userReply:({content:c,timestamp:t})=>c.type!=="userReply"?null:s.jsx(Oe,{text:c.text,timestamp:t}),richcard:({content:c,timestamp:t})=>c.type!=="richcard"?null:s.jsx(Pe,{card:c.card,timestamp:t}),carousel:({content:c,timestamp:t})=>c.type!=="carousel"?null:s.jsx(Qe,{cards:c.cards,timestamp:t})},et=M.memo(function(t){const e=B.c(7),{message:n,isLast:l}=t,{content:i,sender:x,timestamp:r}=n,o=Ke[i.type];if(!o){console.warn(`Unknown message type: ${i.type}`);let h;return e[0]===Symbol.for("react.memo_cache_sentinel")?(h=s.jsx("div",{className:"px-4 py-2 text-gray-500 text-sm italic",children:"[Unsupported message type]"}),e[0]=h):h=e[0],h}const a=l&&x==="business";let f;return e[1]!==o||e[2]!==i||e[3]!==x||e[4]!==a||e[5]!==r?(f=s.jsx(o,{content:i,sender:x,timestamp:r,showSuggestions:a}),e[1]=o,e[2]=i,e[3]=x,e[4]=a,e[5]=r,e[6]=f):f=e[6],f}),tt=M.memo(function(){const t=B.c(11),{theme:e}=Z(),n=e==="dark",l=`
82
78
  inline-flex items-center gap-1 px-4 py-3 rounded-2xl rounded-bl-sm
83
79
  ${n?"bg-zinc-800":"bg-gray-100"}
84
80
  `,i=`
@@ -90,7 +86,7 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
90
86
  `;let o;t[2]!==r?(o=s.jsx("span",{className:r}),t[2]=r,t[3]=o):o=t[3];const a=`
91
87
  rcs-typing-dot w-2 h-2 rounded-full
92
88
  ${n?"bg-zinc-500":"bg-gray-400"}
93
- `;let f;t[4]!==a?(f=s.jsx("span",{className:a}),t[4]=a,t[5]=f):f=t[5];let h;return t[6]!==l||t[7]!==x||t[8]!==o||t[9]!==f?(h=s.jsx("div",{className:"flex items-start gap-2 px-4 py-2",role:"status","aria-label":"Business is typing",children:s.jsxs("div",{className:l,children:[x,o,f]})}),t[6]=l,t[7]=x,t[8]=o,t[9]=f,t[10]=h):h=t[10],h}),ft=S.memo(function(){const t=D.c(25),{theme:e,state:n}=Z(),{chatHistory:l,isTyping:i}=n,x=e==="dark";let r;t[0]!==l.length||t[1]!==x?(r=l.length>0&&s.jsx("div",{className:"flex justify-center py-2",children:s.jsx("span",{className:`
89
+ `;let f;t[4]!==a?(f=s.jsx("span",{className:a}),t[4]=a,t[5]=f):f=t[5];let h;return t[6]!==l||t[7]!==x||t[8]!==o||t[9]!==f?(h=s.jsx("div",{className:"flex items-start gap-2 px-4 py-2",role:"status","aria-label":"Business is typing",children:s.jsxs("div",{className:l,children:[x,o,f]})}),t[6]=l,t[7]=x,t[8]=o,t[9]=f,t[10]=h):h=t[10],h}),st=M.memo(function(){const t=B.c(25),{theme:e,state:n}=Z(),{chatHistory:l,isTyping:i}=n,x=e==="dark";let r;t[0]!==l.length||t[1]!==x?(r=l.length>0&&s.jsx("div",{className:"flex justify-center py-2",children:s.jsx("span",{className:`
94
90
  text-xs font-medium px-3 py-1
95
91
  ${x?"text-zinc-500":"text-gray-500"}
96
92
  `,children:"Today"})}),t[0]=l.length,t[1]=x,t[2]=r):r=t[2];const o=`
@@ -98,35 +94,35 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
98
94
  ${x?"bg-zinc-900":"bg-gray-50"}
99
95
  `;let a;t[3]!==l.length||t[4]!==x||t[5]!==i?(a=l.length===0&&!i&&s.jsx("div",{className:"flex items-center justify-center py-12",children:s.jsx("p",{className:`text-sm ${x?"text-zinc-500":"text-gray-400"}`,children:"No messages yet"})}),t[3]=l.length,t[4]=x,t[5]=i,t[6]=a):a=t[6];let f;if(t[7]!==l||t[8]!==i){let g;t[10]!==l.length||t[11]!==i?(g=(p,y)=>s.jsx("div",{className:`
100
96
  ${p.sender==="user"?"flex justify-end":"flex justify-start"}
101
- `,children:s.jsx(ct,{message:p,isLast:y===l.length-1&&!i})},p.id),t[10]=l.length,t[11]=i,t[12]=g):g=t[12],f=l.map(g),t[7]=l,t[8]=i,t[9]=f}else f=t[9];let h;t[13]!==i?(h=i&&s.jsx(dt,{}),t[13]=i,t[14]=h):h=t[14];let d;t[15]!==f||t[16]!==h?(d=s.jsxs("div",{className:"p-3 space-y-3",children:[f,h]}),t[15]=f,t[16]=h,t[17]=d):d=t[17];let u;t[18]!==o||t[19]!==a||t[20]!==d?(u=s.jsxs("div",{className:o,children:[a,d]}),t[18]=o,t[19]=a,t[20]=d,t[21]=u):u=t[21];let m;return t[22]!==r||t[23]!==u?(m=s.jsxs("div",{className:"px-3 pb-3 space-y-3",role:"log","aria-label":"Chat messages","aria-live":"polite",children:[r,u]}),t[22]=r,t[23]=u,t[24]=m):m=t[24],m}),mt=S.memo(function(t){const e=D.c(35),{suggestion:n,onClick:l,variant:i}=t,x=i===void 0?"bar":i,{theme:r,businessInfo:o}=Z(),a=r==="dark";let f;e[0]!==n?(f=se(n),e[0]=n,e[1]=f):f=e[1];const h=f,d=h?n.action.displayText:n.reply.displayText;let u;e[2]!==h||e[3]!==n?(u=h?ut(n):null,e[2]=h,e[3]=n,e[4]=u):u=e[4];const m=u,g=o.brandColor||"#0084ff";if(x==="bar"){const j=`
97
+ `,children:s.jsx(et,{message:p,isLast:y===l.length-1&&!i})},p.id),t[10]=l.length,t[11]=i,t[12]=g):g=t[12],f=l.map(g),t[7]=l,t[8]=i,t[9]=f}else f=t[9];let h;t[13]!==i?(h=i&&s.jsx(tt,{}),t[13]=i,t[14]=h):h=t[14];let d;t[15]!==f||t[16]!==h?(d=s.jsxs("div",{className:"p-3 space-y-3",children:[f,h]}),t[15]=f,t[16]=h,t[17]=d):d=t[17];let u;t[18]!==o||t[19]!==a||t[20]!==d?(u=s.jsxs("div",{className:o,children:[a,d]}),t[18]=o,t[19]=a,t[20]=d,t[21]=u):u=t[21];let m;return t[22]!==r||t[23]!==u?(m=s.jsxs("div",{className:"px-3 pb-3 space-y-3",role:"log","aria-label":"Chat messages","aria-live":"polite",children:[r,u]}),t[22]=r,t[23]=u,t[24]=m):m=t[24],m}),nt=M.memo(function(t){const e=B.c(35),{suggestion:n,onClick:l,variant:i}=t,x=i===void 0?"bar":i,{theme:r,businessInfo:o}=Z(),a=r==="dark";let f;e[0]!==n?(f=se(n),e[0]=n,e[1]=f):f=e[1];const h=f,d=h?n.action.displayText:n.reply.displayText;let u;e[2]!==h||e[3]!==n?(u=h?lt(n):null,e[2]=h,e[3]=n,e[4]=u):u=e[4];const m=u,g=o.brandColor||"#0084ff";if(x==="bar"){const j=`
102
98
  inline-flex items-center gap-2 px-4 py-2 rounded-full text-sm font-medium
103
99
  whitespace-nowrap transition-colors flex-shrink-0
104
100
  border
105
101
  ${a?"bg-zinc-800 border-zinc-700 hover:bg-zinc-700 text-white":"bg-white border-gray-300 hover:bg-gray-50 text-gray-900"}
106
- `;let b;e[5]!==d||e[6]!==h||e[7]!==n?(b=h?`${ht(n)}: ${d}`:d,e[5]=d,e[6]=h,e[7]=n,e[8]=b):b=e[8];let w;e[9]!==m||e[10]!==g?(w=m&&s.jsx("span",{style:{color:g},children:s.jsx(m,{className:"w-4 h-4"})}),e[9]=m,e[10]=g,e[11]=w):w=e[11];let v;e[12]!==d?(v=s.jsx("span",{children:d}),e[12]=d,e[13]=v):v=e[13];let k;return e[14]!==l||e[15]!==j||e[16]!==b||e[17]!==w||e[18]!==v?(k=s.jsxs("button",{type:"button",onClick:l,className:j,"aria-label":b,children:[w,v]}),e[14]=l,e[15]=j,e[16]=b,e[17]=w,e[18]=v,e[19]=k):k=e[19],k}if(x==="card"){const j=`
102
+ `;let b;e[5]!==d||e[6]!==h||e[7]!==n?(b=h?`${rt(n)}: ${d}`:d,e[5]=d,e[6]=h,e[7]=n,e[8]=b):b=e[8];let v;e[9]!==m||e[10]!==g?(v=m&&s.jsx("span",{style:{color:g},children:s.jsx(m,{className:"w-4 h-4"})}),e[9]=m,e[10]=g,e[11]=v):v=e[11];let w;e[12]!==d?(w=s.jsx("span",{children:d}),e[12]=d,e[13]=w):w=e[13];let k;return e[14]!==l||e[15]!==j||e[16]!==b||e[17]!==v||e[18]!==w?(k=s.jsxs("button",{type:"button",onClick:l,className:j,"aria-label":b,children:[v,w]}),e[14]=l,e[15]=j,e[16]=b,e[17]=v,e[18]=w,e[19]=k):k=e[19],k}if(x==="card"){const j=`
107
103
  w-full flex items-center gap-3 px-3 py-2.5 text-left transition-colors rounded-lg
108
104
  ${a?"hover:bg-zinc-700":"hover:bg-gray-100"}
109
- `;let b;e[20]!==m||e[21]!==g?(b=m&&s.jsx("div",{className:"w-8 h-8 rounded-full flex items-center justify-center flex-shrink-0",style:{backgroundColor:`${g}15`},children:s.jsx(m,{className:"w-4 h-4",style:{color:g}})}),e[20]=m,e[21]=g,e[22]=b):b=e[22];const w=`text-sm font-medium ${a?"text-white":"text-gray-900"}`;let v;e[23]!==d||e[24]!==w?(v=s.jsx("span",{className:w,children:d}),e[23]=d,e[24]=w,e[25]=v):v=e[25];let k;return e[26]!==l||e[27]!==j||e[28]!==b||e[29]!==v?(k=s.jsxs("button",{type:"button",onClick:l,className:j,children:[b,v]}),e[26]=l,e[27]=j,e[28]=b,e[29]=v,e[30]=k):k=e[30],k}const p=`
105
+ `;let b;e[20]!==m||e[21]!==g?(b=m&&s.jsx("div",{className:"w-8 h-8 rounded-full flex items-center justify-center flex-shrink-0",style:{backgroundColor:`${g}15`},children:s.jsx(m,{className:"w-4 h-4",style:{color:g}})}),e[20]=m,e[21]=g,e[22]=b):b=e[22];const v=`text-sm font-medium ${a?"text-white":"text-gray-900"}`;let w;e[23]!==d||e[24]!==v?(w=s.jsx("span",{className:v,children:d}),e[23]=d,e[24]=v,e[25]=w):w=e[25];let k;return e[26]!==l||e[27]!==j||e[28]!==b||e[29]!==w?(k=s.jsxs("button",{type:"button",onClick:l,className:j,children:[b,w]}),e[26]=l,e[27]=j,e[28]=b,e[29]=w,e[30]=k):k=e[30],k}const p=`
110
106
  w-full px-3 py-2 rounded-lg text-xs font-medium text-center
111
107
  border transition-colors
112
108
  ${a?"border-zinc-600 hover:bg-zinc-700 text-white":"border-gray-300 hover:bg-gray-50 text-gray-900"}
113
- `;let y;return e[31]!==d||e[32]!==l||e[33]!==p?(y=s.jsx("button",{type:"button",onClick:l,className:p,children:d}),e[31]=d,e[32]=l,e[33]=p,e[34]=y):y=e[34],y});function ut(c){if(!se(c))return null;const{action:t}=c;return t.openUrlAction?({className:e,style:n})=>s.jsx("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}):t.dialAction?({className:e,style:n})=>s.jsx("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"})}):t.shareLocationAction?({className:e,style:n})=>s.jsxs("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}):t.viewLocationAction?({className:e,style:n})=>s.jsxs("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}):t.createCalendarEventAction?({className:e,style:n})=>s.jsx("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"})}):null}function ht(c){if(!se(c))return"Reply";const{action:t}=c;return t.openUrlAction?"Open link":t.dialAction?"Call":t.shareLocationAction?"Share location":t.viewLocationAction?"View location":t.createCalendarEventAction?"Add to calendar":"Action"}const xt=S.memo(function(t){const e=D.c(14),{suggestions:n}=t,{theme:l,handleReply:i,handleAction:x}=Z(),r=l==="dark";if(!n||n.length===0)return null;let o;e[0]!==x||e[1]!==i?(o=g=>{ge(g)?i(g):se(g)&&x(g)},e[0]=x,e[1]=i,e[2]=o):o=e[2];const a=o,f=`
109
+ `;let y;return e[31]!==d||e[32]!==l||e[33]!==p?(y=s.jsx("button",{type:"button",onClick:l,className:p,children:d}),e[31]=d,e[32]=l,e[33]=p,e[34]=y):y=e[34],y});function lt(c){if(!se(c))return null;const{action:t}=c;return t.openUrlAction?({className:e,style:n})=>s.jsx("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"})}):t.dialAction?({className:e,style:n})=>s.jsx("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"})}):t.shareLocationAction?({className:e,style:n})=>s.jsxs("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}):t.viewLocationAction?({className:e,style:n})=>s.jsxs("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:[s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z"}),s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 11a3 3 0 11-6 0 3 3 0 016 0z"})]}):t.createCalendarEventAction?({className:e,style:n})=>s.jsx("svg",{className:e,style:n,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"})}):null}function rt(c){if(!se(c))return"Reply";const{action:t}=c;return t.openUrlAction?"Open link":t.dialAction?"Call":t.shareLocationAction?"Share location":t.viewLocationAction?"View location":t.createCalendarEventAction?"Add to calendar":"Action"}const ot=M.memo(function(t){const e=B.c(14),{suggestions:n}=t,{theme:l,handleReply:i,handleAction:x}=Z(),r=l==="dark";if(!n||n.length===0)return null;let o;e[0]!==x||e[1]!==i?(o=g=>{ue(g)?i(g):se(g)&&x(g)},e[0]=x,e[1]=i,e[2]=o):o=e[2];const a=o,f=`
114
110
  px-3 py-2
115
111
  ${r?"bg-zinc-900":"bg-white"}
116
- `;let h;e[3]===Symbol.for("react.memo_cache_sentinel")?(h={scrollbarWidth:"none",msOverflowStyle:"none"},e[3]=h):h=e[3];let d;if(e[4]!==a||e[5]!==n){let g;e[7]!==a?(g=(p,y)=>s.jsx(mt,{suggestion:p,onClick:()=>a(p),variant:"bar"},y),e[7]=a,e[8]=g):g=e[8],d=n.map(g),e[4]=a,e[5]=n,e[6]=d}else d=e[6];let u;e[9]!==d?(u=s.jsx("div",{className:"flex gap-2 overflow-x-auto pb-1 -mx-1 px-1",style:h,children:d}),e[9]=d,e[10]=u):u=e[10];let m;return e[11]!==f||e[12]!==u?(m=s.jsx("div",{className:f,role:"group","aria-label":"Quick replies",children:u}),e[11]=f,e[12]=u,e[13]=m):m=e[13],m}),gt=S.memo(function(){const t=D.c(39),{theme:e,state:n,showSuggestions:l}=Z(),{chatHistory:i,isTyping:x,error:r}=n;let o;t[0]!==i.length||t[1]!==x?(o=[i.length,x],t[0]=i.length,t[1]=x,t[2]=o):o=t[2];const a=Ye(o),f=e==="dark",h=i[i.length-1],d=l&&h?.sender==="business"&&!x?h.suggestions:void 0,u=`
112
+ `;let h;e[3]===Symbol.for("react.memo_cache_sentinel")?(h={scrollbarWidth:"none",msOverflowStyle:"none"},e[3]=h):h=e[3];let d;if(e[4]!==a||e[5]!==n){let g;e[7]!==a?(g=(p,y)=>s.jsx(nt,{suggestion:p,onClick:()=>a(p),variant:"bar"},y),e[7]=a,e[8]=g):g=e[8],d=n.map(g),e[4]=a,e[5]=n,e[6]=d}else d=e[6];let u;e[9]!==d?(u=s.jsx("div",{className:"flex gap-2 overflow-x-auto pb-1 -mx-1 px-1",style:h,children:d}),e[9]=d,e[10]=u):u=e[10];let m;return e[11]!==f||e[12]!==u?(m=s.jsx("div",{className:f,role:"group","aria-label":"Quick replies",children:u}),e[11]=f,e[12]=u,e[13]=m):m=e[13],m}),it=M.memo(function(){const t=B.c(39),{theme:e,state:n,showSuggestions:l}=Z(),{chatHistory:i,isTyping:x,error:r}=n;let o;t[0]!==i.length||t[1]!==x?(o=[i.length,x],t[0]=i.length,t[1]=x,t[2]=o):o=t[2];const a=De(o),f=e==="dark",h=i[i.length-1],d=l&&h?.sender==="business"&&!x?h.suggestions:void 0,u=`
117
113
  flex flex-col h-full w-full overflow-hidden
118
114
  ${f?"bg-zinc-950":"bg-white"}
119
- `;let m;t[3]===Symbol.for("react.memo_cache_sentinel")?(m=s.jsx(Je,{}),t[3]=m):m=t[3];let g;t[4]!==r?(g=r&&s.jsx("div",{className:"px-4 py-2 bg-red-500/10 border-b border-red-500/20",role:"alert",children:s.jsx("p",{className:"text-sm text-red-500",children:r})}),t[4]=r,t[5]=g):g=t[5];let p,y;t[6]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx(Qe,{}),y=s.jsx(ft,{}),t[6]=p,t[7]=y):(p=t[6],y=t[7]);let j;t[8]!==a?(j=s.jsxs("div",{ref:a,className:"flex-1 overflow-y-auto rcs-scrollbar",children:[p,y]}),t[8]=a,t[9]=j):j=t[9];let b;t[10]!==d?(b=d&&d.length>0&&s.jsx(xt,{suggestions:d}),t[10]=d,t[11]=b):b=t[11];const w=`
115
+ `;let m;t[3]===Symbol.for("react.memo_cache_sentinel")?(m=s.jsx(Ve,{}),t[3]=m):m=t[3];let g;t[4]!==r?(g=r&&s.jsx("div",{className:"px-4 py-2 bg-red-500/10 border-b border-red-500/20",role:"alert",children:s.jsx("p",{className:"text-sm text-red-500",children:r})}),t[4]=r,t[5]=g):g=t[5];let p,y;t[6]===Symbol.for("react.memo_cache_sentinel")?(p=s.jsx(Ue,{}),y=s.jsx(st,{}),t[6]=p,t[7]=y):(p=t[6],y=t[7]);let j;t[8]!==a?(j=s.jsxs("div",{ref:a,className:"flex-1 overflow-y-auto rcs-scrollbar",children:[p,y]}),t[8]=a,t[9]=j):j=t[9];let b;t[10]!==d?(b=d&&d.length>0&&s.jsx(ot,{suggestions:d}),t[10]=d,t[11]=b):b=t[11];const v=`
120
116
  px-3 py-2 flex items-center gap-2
121
117
  ${f?"bg-zinc-900":"bg-white"}
122
- `,v=`
118
+ `,w=`
123
119
  w-9 h-9 flex items-center justify-center rounded-full flex-shrink-0
124
120
  border transition-colors
125
121
  ${f?"border-zinc-700 text-zinc-400 hover:bg-zinc-800":"border-gray-300 text-gray-500 hover:bg-gray-100"}
126
- `;let k;t[12]===Symbol.for("react.memo_cache_sentinel")?(k=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 4v16m8-8H4"})}),t[12]=k):k=t[12];let N;t[13]!==v?(N=s.jsx("button",{type:"button",className:v,"aria-label":"Add attachment",children:k}),t[13]=v,t[14]=N):N=t[14];const L=`
122
+ `;let k;t[12]===Symbol.for("react.memo_cache_sentinel")?(k=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 4v16m8-8H4"})}),t[12]=k):k=t[12];let N;t[13]!==w?(N=s.jsx("button",{type:"button",className:w,"aria-label":"Add attachment",children:k}),t[13]=w,t[14]=N):N=t[14];const _=`
127
123
  flex-1 flex items-center gap-2 px-4 py-2 rounded-full
128
124
  ${f?"bg-zinc-800":"bg-gray-100"}
129
- `,C=`flex-1 text-sm ${f?"text-zinc-500":"text-gray-400"}`;let R;t[15]!==C?(R=s.jsx("span",{className:C,children:"RCS message"}),t[15]=C,t[16]=R):R=t[16];const $=`p-1 ${f?"text-zinc-500":"text-gray-400"}`;let _;t[17]===Symbol.for("react.memo_cache_sentinel")?(_=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M14.828 14.828a4 4 0 01-5.656 0M9 10h.01M15 10h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})}),t[17]=_):_=t[17];let M;t[18]!==$?(M=s.jsx("button",{type:"button",className:$,"aria-label":"Emoji",children:_}),t[18]=$,t[19]=M):M=t[19];const z=`p-1 ${f?"text-zinc-500":"text-gray-400"}`;let I;t[20]===Symbol.for("react.memo_cache_sentinel")?(I=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})}),t[20]=I):I=t[20];let B;t[21]!==z?(B=s.jsx("button",{type:"button",className:z,"aria-label":"Attach image",children:I}),t[21]=z,t[22]=B):B=t[22];let A;t[23]!==L||t[24]!==R||t[25]!==M||t[26]!==B?(A=s.jsxs("div",{className:L,children:[R,M,B]}),t[23]=L,t[24]=R,t[25]=M,t[26]=B,t[27]=A):A=t[27];let O;t[28]===Symbol.for("react.memo_cache_sentinel")?(O=s.jsx("button",{type:"button",className:"w-10 h-10 flex items-center justify-center rounded-full bg-green-100 text-green-600 flex-shrink-0","aria-label":"Voice message",children:s.jsx("svg",{className:"w-5 h-5",fill:"currentColor",viewBox:"0 0 24 24",children:s.jsx("path",{d:"M12 14c1.66 0 3-1.34 3-3V5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm-1 1.93c-3.94-.49-7-3.85-7-7.93h2c0 3.31 2.69 6 6 6s6-2.69 6-6h2c0 4.08-3.06 7.44-7 7.93V20h4v2H8v-2h4v-4.07z"})})}),t[28]=O):O=t[28];let F;t[29]!==N||t[30]!==A||t[31]!==w?(F=s.jsxs("div",{className:w,children:[N,A,O]}),t[29]=N,t[30]=A,t[31]=w,t[32]=F):F=t[32];let V;return t[33]!==u||t[34]!==F||t[35]!==g||t[36]!==j||t[37]!==b?(V=s.jsxs("div",{className:u,children:[m,g,j,b,F]}),t[33]=u,t[34]=F,t[35]=g,t[36]=j,t[37]=b,t[38]=V):V=t[38],V}),pt=S.memo(function(){const t=D.c(73),{theme:e,businessInfo:n,toggleProfile:l}=Z(),[i,x]=S.useState("info"),r=e==="dark",o=n.bannerImage||"https://images.unsplash.com/photo-1436491865332-7a61a109cc05?w=800&q=80",a=n.brandColor||"#0084ff",f=`
125
+ `,C=`flex-1 text-sm ${f?"text-zinc-500":"text-gray-400"}`;let I;t[15]!==C?(I=s.jsx("span",{className:C,children:"RCS message"}),t[15]=C,t[16]=I):I=t[16];const $=`p-1 ${f?"text-zinc-500":"text-gray-400"}`;let L;t[17]===Symbol.for("react.memo_cache_sentinel")?(L=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M14.828 14.828a4 4 0 01-5.656 0M9 10h.01M15 10h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})}),t[17]=L):L=t[17];let S;t[18]!==$?(S=s.jsx("button",{type:"button",className:$,"aria-label":"Emoji",children:L}),t[18]=$,t[19]=S):S=t[19];const z=`p-1 ${f?"text-zinc-500":"text-gray-400"}`;let A;t[20]===Symbol.for("react.memo_cache_sentinel")?(A=s.jsx("svg",{className:"w-5 h-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})}),t[20]=A):A=t[20];let W;t[21]!==z?(W=s.jsx("button",{type:"button",className:z,"aria-label":"Attach image",children:A}),t[21]=z,t[22]=W):W=t[22];let T;t[23]!==_||t[24]!==I||t[25]!==S||t[26]!==W?(T=s.jsxs("div",{className:_,children:[I,S,W]}),t[23]=_,t[24]=I,t[25]=S,t[26]=W,t[27]=T):T=t[27];let O;t[28]===Symbol.for("react.memo_cache_sentinel")?(O=s.jsx("button",{type:"button",className:"w-10 h-10 flex items-center justify-center rounded-full bg-green-100 text-green-600 flex-shrink-0","aria-label":"Voice message",children:s.jsx("svg",{className:"w-5 h-5",fill:"currentColor",viewBox:"0 0 24 24",children:s.jsx("path",{d:"M12 14c1.66 0 3-1.34 3-3V5c0-1.66-1.34-3-3-3S9 3.34 9 5v6c0 1.66 1.34 3 3 3zm-1 1.93c-3.94-.49-7-3.85-7-7.93h2c0 3.31 2.69 6 6 6s6-2.69 6-6h2c0 4.08-3.06 7.44-7 7.93V20h4v2H8v-2h4v-4.07z"})})}),t[28]=O):O=t[28];let F;t[29]!==N||t[30]!==T||t[31]!==v?(F=s.jsxs("div",{className:v,children:[N,T,O]}),t[29]=N,t[30]=T,t[31]=v,t[32]=F):F=t[32];let V;return t[33]!==u||t[34]!==F||t[35]!==g||t[36]!==j||t[37]!==b?(V=s.jsxs("div",{className:u,children:[m,g,j,b,F]}),t[33]=u,t[34]=F,t[35]=g,t[36]=j,t[37]=b,t[38]=V):V=t[38],V}),at=M.memo(function(){const t=B.c(73),{theme:e,businessInfo:n,toggleProfile:l}=Z(),[i,x]=M.useState("info"),r=e==="dark",o=n.bannerImage||"https://images.unsplash.com/photo-1436491865332-7a61a109cc05?w=800&q=80",a=n.brandColor||"#0084ff",f=`
130
126
  absolute inset-0 z-50 flex flex-col
131
127
  ${r?"bg-zinc-950":"bg-white"}
132
128
  `,h=`
@@ -140,37 +136,37 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
140
136
  w-20 h-20 rounded-full overflow-hidden border-4
141
137
  ${r?"border-zinc-950 bg-zinc-800":"border-white bg-gray-100"}
142
138
  shadow-lg
143
- `;let w;t[12]!==a||t[13]!==n.logo||t[14]!==n.name?(w=n.logo?s.jsx("img",{src:n.logo,alt:`${n.name} logo`,className:"w-full h-full object-cover"}):s.jsx("div",{className:"w-full h-full flex items-center justify-center text-2xl font-bold text-white",style:{backgroundColor:a},children:n.name.charAt(0).toUpperCase()}),t[12]=a,t[13]=n.logo,t[14]=n.name,t[15]=w):w=t[15];let v;t[16]!==w||t[17]!==b?(v=s.jsx("div",{className:"relative px-4",children:s.jsx("div",{className:b,children:w})}),t[16]=w,t[17]=b,t[18]=v):v=t[18];const k=`text-xl font-semibold ${r?"text-white":"text-gray-900"}`;let N;t[19]!==n.name||t[20]!==k?(N=s.jsx("h1",{className:k,children:n.name}),t[19]=n.name,t[20]=k,t[21]=N):N=t[21];let L;t[22]!==n.description||t[23]!==r?(L=n.description&&s.jsx("p",{className:`text-sm mt-1 ${r?"text-zinc-400":"text-gray-500"}`,children:n.description}),t[22]=n.description,t[23]=r,t[24]=L):L=t[24];let C;t[25]!==N||t[26]!==L?(C=s.jsxs("div",{className:"pt-12 pb-4 px-4 text-center",children:[N,L]}),t[25]=N,t[26]=L,t[27]=C):C=t[27];let R;t[28]!==a||t[29]!==n.phoneNumbers||t[30]!==r?(R=n.phoneNumbers&&n.phoneNumbers.length>0&&s.jsx(ue,{icon:"phone",label:"Call",isDark:r,brandColor:a,onClick:()=>{const T=n.phoneNumbers?.[0]?.number;T&&(window.location.href=`tel:${T}`)}}),t[28]=a,t[29]=n.phoneNumbers,t[30]=r,t[31]=R):R=t[31];let $;t[32]!==a||t[33]!==n.websites||t[34]!==r?($=n.websites&&n.websites.length>0&&s.jsx(ue,{icon:"globe",label:"Website",isDark:r,brandColor:a,onClick:()=>{const T=n.websites?.[0]?.url;T&&window.open(T,"_blank","noopener,noreferrer")}}),t[32]=a,t[33]=n.websites,t[34]=r,t[35]=$):$=t[35];let _;t[36]!==a||t[37]!==n.emails||t[38]!==r?(_=n.emails&&n.emails.length>0&&s.jsx(ue,{icon:"mail",label:"Contact",isDark:r,brandColor:a,onClick:()=>{const T=n.emails?.[0]?.email;T&&(window.location.href=`mailto:${T}`)}}),t[36]=a,t[37]=n.emails,t[38]=r,t[39]=_):_=t[39];let M;t[40]!==R||t[41]!==$||t[42]!==_?(M=s.jsxs("div",{className:"flex justify-center gap-4 px-4 pb-4",children:[R,$,_]}),t[40]=R,t[41]=$,t[42]=_,t[43]=M):M=t[43];const z=`
139
+ `;let v;t[12]!==a||t[13]!==n.logo||t[14]!==n.name?(v=n.logo?s.jsx("img",{src:n.logo,alt:`${n.name} logo`,className:"w-full h-full object-cover"}):s.jsx("div",{className:"w-full h-full flex items-center justify-center text-2xl font-bold text-white",style:{backgroundColor:a},children:n.name.charAt(0).toUpperCase()}),t[12]=a,t[13]=n.logo,t[14]=n.name,t[15]=v):v=t[15];let w;t[16]!==v||t[17]!==b?(w=s.jsx("div",{className:"relative px-4",children:s.jsx("div",{className:b,children:v})}),t[16]=v,t[17]=b,t[18]=w):w=t[18];const k=`text-xl font-semibold ${r?"text-white":"text-gray-900"}`;let N;t[19]!==n.name||t[20]!==k?(N=s.jsx("h1",{className:k,children:n.name}),t[19]=n.name,t[20]=k,t[21]=N):N=t[21];let _;t[22]!==n.description||t[23]!==r?(_=n.description&&s.jsx("p",{className:`text-sm mt-1 ${r?"text-zinc-400":"text-gray-500"}`,children:n.description}),t[22]=n.description,t[23]=r,t[24]=_):_=t[24];let C;t[25]!==N||t[26]!==_?(C=s.jsxs("div",{className:"pt-12 pb-4 px-4 text-center",children:[N,_]}),t[25]=N,t[26]=_,t[27]=C):C=t[27];let I;t[28]!==a||t[29]!==n.phoneNumbers||t[30]!==r?(I=n.phoneNumbers&&n.phoneNumbers.length>0&&s.jsx(de,{icon:"phone",label:"Call",isDark:r,brandColor:a,onClick:()=>{const R=n.phoneNumbers?.[0]?.number;R&&(window.location.href=`tel:${R}`)}}),t[28]=a,t[29]=n.phoneNumbers,t[30]=r,t[31]=I):I=t[31];let $;t[32]!==a||t[33]!==n.websites||t[34]!==r?($=n.websites&&n.websites.length>0&&s.jsx(de,{icon:"globe",label:"Website",isDark:r,brandColor:a,onClick:()=>{const R=n.websites?.[0]?.url;R&&window.open(R,"_blank","noopener,noreferrer")}}),t[32]=a,t[33]=n.websites,t[34]=r,t[35]=$):$=t[35];let L;t[36]!==a||t[37]!==n.emails||t[38]!==r?(L=n.emails&&n.emails.length>0&&s.jsx(de,{icon:"mail",label:"Contact",isDark:r,brandColor:a,onClick:()=>{const R=n.emails?.[0]?.email;R&&(window.location.href=`mailto:${R}`)}}),t[36]=a,t[37]=n.emails,t[38]=r,t[39]=L):L=t[39];let S;t[40]!==I||t[41]!==$||t[42]!==L?(S=s.jsxs("div",{className:"flex justify-center gap-4 px-4 pb-4",children:[I,$,L]}),t[40]=I,t[41]=$,t[42]=L,t[43]=S):S=t[43];const z=`
144
140
  flex mx-4 rounded-lg overflow-hidden border
145
141
  ${r?"border-zinc-700 bg-zinc-800":"border-gray-200 bg-gray-100"}
146
- `,I=i==="info";let B;t[44]===Symbol.for("react.memo_cache_sentinel")?(B=()=>x("info"),t[44]=B):B=t[44];let A;t[45]!==a||t[46]!==r||t[47]!==I?(A=s.jsx(ke,{active:I,onClick:B,isDark:r,brandColor:a,children:"Info"}),t[45]=a,t[46]=r,t[47]=I,t[48]=A):A=t[48];const O=i==="options";let F;t[49]===Symbol.for("react.memo_cache_sentinel")?(F=()=>x("options"),t[49]=F):F=t[49];let V;t[50]!==a||t[51]!==r||t[52]!==O?(V=s.jsx(ke,{active:O,onClick:F,isDark:r,brandColor:a,children:"Options"}),t[50]=a,t[51]=r,t[52]=O,t[53]=V):V=t[53];let J;t[54]!==z||t[55]!==A||t[56]!==V?(J=s.jsxs("div",{className:z,children:[A,V]}),t[54]=z,t[55]=A,t[56]=V,t[57]=J):J=t[57];let P;t[58]!==i||t[59]!==a||t[60]!==r?(P=s.jsx("div",{className:"p-4",children:i==="info"?s.jsx(bt,{isDark:r,brandColor:a}):s.jsx(yt,{isDark:r})}),t[58]=i,t[59]=a,t[60]=r,t[61]=P):P=t[61];let q;t[62]!==v||t[63]!==C||t[64]!==M||t[65]!==J||t[66]!==P||t[67]!==j?(q=s.jsxs("div",{className:"flex-1 overflow-y-auto",children:[j,v,C,M,J,P]}),t[62]=v,t[63]=C,t[64]=M,t[65]=J,t[66]=P,t[67]=j,t[68]=q):q=t[68];let K;return t[69]!==f||t[70]!==q||t[71]!==y?(K=s.jsxs("div",{className:f,children:[y,q]}),t[69]=f,t[70]=q,t[71]=y,t[72]=K):K=t[72],K}),ue=S.memo(function(t){const e=D.c(12),{icon:n,label:l,isDark:i,brandColor:x,onClick:r}=t;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={phone:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"}),globe:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"}),mail:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 8l7.89 5.26a2 2 0 002.22 0L21 8M5 19h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"})},e[0]=o):o=e[0];const a=o,f=`
142
+ `,A=i==="info";let W;t[44]===Symbol.for("react.memo_cache_sentinel")?(W=()=>x("info"),t[44]=W):W=t[44];let T;t[45]!==a||t[46]!==r||t[47]!==A?(T=s.jsx(pe,{active:A,onClick:W,isDark:r,brandColor:a,children:"Info"}),t[45]=a,t[46]=r,t[47]=A,t[48]=T):T=t[48];const O=i==="options";let F;t[49]===Symbol.for("react.memo_cache_sentinel")?(F=()=>x("options"),t[49]=F):F=t[49];let V;t[50]!==a||t[51]!==r||t[52]!==O?(V=s.jsx(pe,{active:O,onClick:F,isDark:r,brandColor:a,children:"Options"}),t[50]=a,t[51]=r,t[52]=O,t[53]=V):V=t[53];let Y;t[54]!==z||t[55]!==T||t[56]!==V?(Y=s.jsxs("div",{className:z,children:[T,V]}),t[54]=z,t[55]=T,t[56]=V,t[57]=Y):Y=t[57];let P;t[58]!==i||t[59]!==a||t[60]!==r?(P=s.jsx("div",{className:"p-4",children:i==="info"?s.jsx(ct,{isDark:r,brandColor:a}):s.jsx(dt,{isDark:r})}),t[58]=i,t[59]=a,t[60]=r,t[61]=P):P=t[61];let q;t[62]!==w||t[63]!==C||t[64]!==S||t[65]!==Y||t[66]!==P||t[67]!==j?(q=s.jsxs("div",{className:"flex-1 overflow-y-auto",children:[j,w,C,S,Y,P]}),t[62]=w,t[63]=C,t[64]=S,t[65]=Y,t[66]=P,t[67]=j,t[68]=q):q=t[68];let K;return t[69]!==f||t[70]!==q||t[71]!==y?(K=s.jsxs("div",{className:f,children:[y,q]}),t[69]=f,t[70]=q,t[71]=y,t[72]=K):K=t[72],K}),de=M.memo(function(t){const e=B.c(12),{icon:n,label:l,isDark:i,brandColor:x,onClick:r}=t;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={phone:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z"}),globe:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9"}),mail:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M3 8l7.89 5.26a2 2 0 002.22 0L21 8M5 19h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"})},e[0]=o):o=e[0];const a=o,f=`
147
143
  flex flex-col items-center gap-2 px-6 py-3 rounded-xl border transition-colors
148
144
  ${i?"bg-zinc-800 border-zinc-700 hover:bg-zinc-700":"bg-white border-gray-200 hover:bg-gray-50"}
149
- `,h=a[n];let d;e[1]!==x||e[2]!==h?(d=s.jsx("svg",{className:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:x,children:h}),e[1]=x,e[2]=h,e[3]=d):d=e[3];const u=`text-xs font-medium ${i?"text-zinc-300":"text-gray-600"}`;let m;e[4]!==l||e[5]!==u?(m=s.jsx("span",{className:u,children:l}),e[4]=l,e[5]=u,e[6]=m):m=e[6];let g;return e[7]!==r||e[8]!==f||e[9]!==d||e[10]!==m?(g=s.jsxs("button",{onClick:r,className:f,children:[d,m]}),e[7]=r,e[8]=f,e[9]=d,e[10]=m,e[11]=g):g=e[11],g}),ke=S.memo(function(t){const e=D.c(8),{active:n,onClick:l,isDark:i,brandColor:x,children:r}=t,o=`
145
+ `,h=a[n];let d;e[1]!==x||e[2]!==h?(d=s.jsx("svg",{className:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:x,children:h}),e[1]=x,e[2]=h,e[3]=d):d=e[3];const u=`text-xs font-medium ${i?"text-zinc-300":"text-gray-600"}`;let m;e[4]!==l||e[5]!==u?(m=s.jsx("span",{className:u,children:l}),e[4]=l,e[5]=u,e[6]=m):m=e[6];let g;return e[7]!==r||e[8]!==f||e[9]!==d||e[10]!==m?(g=s.jsxs("button",{onClick:r,className:f,children:[d,m]}),e[7]=r,e[8]=f,e[9]=d,e[10]=m,e[11]=g):g=e[11],g}),pe=M.memo(function(t){const e=B.c(8),{active:n,onClick:l,isDark:i,brandColor:x,children:r}=t,o=`
150
146
  flex-1 py-2.5 text-sm font-medium transition-colors rounded-lg
151
147
  ${n?"text-white":i?"text-zinc-400 hover:text-zinc-200":"text-gray-500 hover:text-gray-700"}
152
- `;let a;e[0]!==n||e[1]!==x?(a=n?{backgroundColor:x}:void 0,e[0]=n,e[1]=x,e[2]=a):a=e[2];let f;return e[3]!==r||e[4]!==l||e[5]!==o||e[6]!==a?(f=s.jsx("button",{onClick:l,className:o,style:a,children:r}),e[3]=r,e[4]=l,e[5]=o,e[6]=a,e[7]=f):f=e[7],f}),bt=S.memo(function(t){const e=D.c(19),{isDark:n,brandColor:l}=t,{businessInfo:i}=Z();if(!(i.phoneNumbers&&i.phoneNumbers.length>0||i.websites&&i.websites.length>0||i.emails&&i.emails.length>0)){const d=`text-center py-8 ${n?"text-zinc-500":"text-gray-400"}`;let u;return e[0]!==d?(u=s.jsx("div",{className:d,children:"No contact information available"}),e[0]=d,e[1]=u):u=e[1],u}const r=`
148
+ `;let a;e[0]!==n||e[1]!==x?(a=n?{backgroundColor:x}:void 0,e[0]=n,e[1]=x,e[2]=a):a=e[2];let f;return e[3]!==r||e[4]!==l||e[5]!==o||e[6]!==a?(f=s.jsx("button",{onClick:l,className:o,style:a,children:r}),e[3]=r,e[4]=l,e[5]=o,e[6]=a,e[7]=f):f=e[7],f}),ct=M.memo(function(t){const e=B.c(19),{isDark:n,brandColor:l}=t,{businessInfo:i}=Z();if(!(i.phoneNumbers&&i.phoneNumbers.length>0||i.websites&&i.websites.length>0||i.emails&&i.emails.length>0)){const d=`text-center py-8 ${n?"text-zinc-500":"text-gray-400"}`;let u;return e[0]!==d?(u=s.jsx("div",{className:d,children:"No contact information available"}),e[0]=d,e[1]=u):u=e[1],u}const r=`
153
149
  rounded-xl overflow-hidden border divide-y
154
150
  ${n?"bg-zinc-900 border-zinc-800 divide-zinc-800":"bg-gray-50 border-gray-200 divide-gray-200"}
155
- `;let o;e[2]!==l||e[3]!==i.phoneNumbers||e[4]!==n?(o=i.phoneNumbers?.map((d,u)=>s.jsx(he,{icon:"phone",primary:d.number,secondary:d.label,isDark:n,brandColor:l,onClick:()=>window.location.href=`tel:${d.number}`},`phone-${u}`)),e[2]=l,e[3]=i.phoneNumbers,e[4]=n,e[5]=o):o=e[5];let a;e[6]!==l||e[7]!==i.websites||e[8]!==n?(a=i.websites?.map((d,u)=>s.jsx(he,{icon:"globe",primary:d.url.replace(/^https?:\/\//,""),secondary:d.label||"Website",isDark:n,brandColor:l,onClick:()=>window.open(d.url,"_blank","noopener,noreferrer")},`web-${u}`)),e[6]=l,e[7]=i.websites,e[8]=n,e[9]=a):a=e[9];let f;e[10]!==l||e[11]!==i.emails||e[12]!==n?(f=i.emails?.map((d,u)=>s.jsx(he,{icon:"mail",primary:d.email,secondary:d.label||"Email",isDark:n,brandColor:l,onClick:()=>window.location.href=`mailto:${d.email}`},`email-${u}`)),e[10]=l,e[11]=i.emails,e[12]=n,e[13]=f):f=e[13];let h;return e[14]!==r||e[15]!==o||e[16]!==a||e[17]!==f?(h=s.jsxs("div",{className:r,children:[o,a,f]}),e[14]=r,e[15]=o,e[16]=a,e[17]=f,e[18]=h):h=e[18],h}),he=S.memo(function(t){const e=D.c(20),{icon:n,primary:l,secondary:i,isDark:x,onClick:r}=t;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={phone:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z",globe:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9",mail:"M3 8l7.89 5.26a2 2 0 002.22 0L21 8M5 19h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"},e[0]=o):o=e[0];const a=o,f=`
151
+ `;let o;e[2]!==l||e[3]!==i.phoneNumbers||e[4]!==n?(o=i.phoneNumbers?.map((d,u)=>s.jsx(fe,{icon:"phone",primary:d.number,secondary:d.label,isDark:n,brandColor:l,onClick:()=>window.location.href=`tel:${d.number}`},`phone-${u}`)),e[2]=l,e[3]=i.phoneNumbers,e[4]=n,e[5]=o):o=e[5];let a;e[6]!==l||e[7]!==i.websites||e[8]!==n?(a=i.websites?.map((d,u)=>s.jsx(fe,{icon:"globe",primary:d.url.replace(/^https?:\/\//,""),secondary:d.label||"Website",isDark:n,brandColor:l,onClick:()=>window.open(d.url,"_blank","noopener,noreferrer")},`web-${u}`)),e[6]=l,e[7]=i.websites,e[8]=n,e[9]=a):a=e[9];let f;e[10]!==l||e[11]!==i.emails||e[12]!==n?(f=i.emails?.map((d,u)=>s.jsx(fe,{icon:"mail",primary:d.email,secondary:d.label||"Email",isDark:n,brandColor:l,onClick:()=>window.location.href=`mailto:${d.email}`},`email-${u}`)),e[10]=l,e[11]=i.emails,e[12]=n,e[13]=f):f=e[13];let h;return e[14]!==r||e[15]!==o||e[16]!==a||e[17]!==f?(h=s.jsxs("div",{className:r,children:[o,a,f]}),e[14]=r,e[15]=o,e[16]=a,e[17]=f,e[18]=h):h=e[18],h}),fe=M.memo(function(t){const e=B.c(20),{icon:n,primary:l,secondary:i,isDark:x,onClick:r}=t;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={phone:"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z",globe:"M21 12a9 9 0 01-9 9m9-9a9 9 0 00-9-9m9 9H3m9 9a9 9 0 01-9-9m9 9c1.657 0 3-4.03 3-9s-1.343-9-3-9m0 18c-1.657 0-3-4.03-3-9s1.343-9 3-9m-9 9a9 9 0 019-9",mail:"M3 8l7.89 5.26a2 2 0 002.22 0L21 8M5 19h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"},e[0]=o):o=e[0];const a=o,f=`
156
152
  w-full flex items-center gap-4 px-4 py-3.5 text-left transition-colors
157
153
  ${x?"hover:bg-zinc-800":"hover:bg-gray-100"}
158
- `,h=`w-5 h-5 flex-shrink-0 ${x?"text-zinc-500":"text-gray-400"}`,d=a[n];let u;e[1]!==d?(u=s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d}),e[1]=d,e[2]=u):u=e[2];let m;e[3]!==h||e[4]!==u?(m=s.jsx("svg",{className:h,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:u}),e[3]=h,e[4]=u,e[5]=m):m=e[5];const g=`text-sm font-medium truncate ${x?"text-white":"text-gray-900"}`;let p;e[6]!==l||e[7]!==g?(p=s.jsx("p",{className:g,children:l}),e[6]=l,e[7]=g,e[8]=p):p=e[8];let y;e[9]!==x||e[10]!==i?(y=i&&s.jsx("p",{className:`text-xs truncate ${x?"text-zinc-500":"text-gray-500"}`,children:i}),e[9]=x,e[10]=i,e[11]=y):y=e[11];let j;e[12]!==p||e[13]!==y?(j=s.jsxs("div",{className:"flex-1 min-w-0",children:[p,y]}),e[12]=p,e[13]=y,e[14]=j):j=e[14];let b;return e[15]!==r||e[16]!==j||e[17]!==f||e[18]!==m?(b=s.jsxs("button",{onClick:r,className:f,children:[m,j]}),e[15]=r,e[16]=j,e[17]=f,e[18]=m,e[19]=b):b=e[19],b}),yt=S.memo(function(t){const e=D.c(9),{isDark:n}=t,l=`
154
+ `,h=`w-5 h-5 flex-shrink-0 ${x?"text-zinc-500":"text-gray-400"}`,d=a[n];let u;e[1]!==d?(u=s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d}),e[1]=d,e[2]=u):u=e[2];let m;e[3]!==h||e[4]!==u?(m=s.jsx("svg",{className:h,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:u}),e[3]=h,e[4]=u,e[5]=m):m=e[5];const g=`text-sm font-medium truncate ${x?"text-white":"text-gray-900"}`;let p;e[6]!==l||e[7]!==g?(p=s.jsx("p",{className:g,children:l}),e[6]=l,e[7]=g,e[8]=p):p=e[8];let y;e[9]!==x||e[10]!==i?(y=i&&s.jsx("p",{className:`text-xs truncate ${x?"text-zinc-500":"text-gray-500"}`,children:i}),e[9]=x,e[10]=i,e[11]=y):y=e[11];let j;e[12]!==p||e[13]!==y?(j=s.jsxs("div",{className:"flex-1 min-w-0",children:[p,y]}),e[12]=p,e[13]=y,e[14]=j):j=e[14];let b;return e[15]!==r||e[16]!==j||e[17]!==f||e[18]!==m?(b=s.jsxs("button",{onClick:r,className:f,children:[m,j]}),e[15]=r,e[16]=j,e[17]=f,e[18]=m,e[19]=b):b=e[19],b}),dt=M.memo(function(t){const e=B.c(9),{isDark:n}=t,l=`
159
155
  rounded-xl overflow-hidden border divide-y
160
156
  ${n?"bg-zinc-900 border-zinc-800 divide-zinc-800":"bg-gray-50 border-gray-200 divide-gray-200"}
161
- `;let i,x,r;e[0]!==n?(i=s.jsx(xe,{icon:"bell",label:"Notifications",isDark:n}),x=s.jsx(xe,{icon:"block",label:"Block & report spam",isDark:n}),r=s.jsx(xe,{icon:"info",label:"About RCS",isDark:n}),e[0]=n,e[1]=i,e[2]=x,e[3]=r):(i=e[1],x=e[2],r=e[3]);let o;return e[4]!==l||e[5]!==i||e[6]!==x||e[7]!==r?(o=s.jsxs("div",{className:l,children:[i,x,r]}),e[4]=l,e[5]=i,e[6]=x,e[7]=r,e[8]=o):o=e[8],o}),xe=S.memo(function(t){const e=D.c(13),{icon:n,label:l,isDark:i}=t;let x;e[0]===Symbol.for("react.memo_cache_sentinel")?(x={bell:"M15 17h5l-1.405-1.405A2.032 2.032 0 0118 14.158V11a6.002 6.002 0 00-4-5.659V5a2 2 0 10-4 0v.341C7.67 6.165 6 8.388 6 11v3.159c0 .538-.214 1.055-.595 1.436L4 17h5m6 0v1a3 3 0 11-6 0v-1m6 0H9",block:"M18.364 18.364A9 9 0 005.636 5.636m12.728 12.728A9 9 0 015.636 5.636m12.728 12.728L5.636 5.636",info:"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"},e[0]=x):x=e[0];const r=x,o=`
157
+ `;let i,x,r;e[0]!==n?(i=s.jsx(me,{icon:"bell",label:"Notifications",isDark:n}),x=s.jsx(me,{icon:"block",label:"Block & report spam",isDark:n}),r=s.jsx(me,{icon:"info",label:"About RCS",isDark:n}),e[0]=n,e[1]=i,e[2]=x,e[3]=r):(i=e[1],x=e[2],r=e[3]);let o;return e[4]!==l||e[5]!==i||e[6]!==x||e[7]!==r?(o=s.jsxs("div",{className:l,children:[i,x,r]}),e[4]=l,e[5]=i,e[6]=x,e[7]=r,e[8]=o):o=e[8],o}),me=M.memo(function(t){const e=B.c(13),{icon:n,label:l,isDark:i}=t;let x;e[0]===Symbol.for("react.memo_cache_sentinel")?(x={bell:"M15 17h5l-1.405-1.405A2.032 2.032 0 0118 14.158V11a6.002 6.002 0 00-4-5.659V5a2 2 0 10-4 0v.341C7.67 6.165 6 8.388 6 11v3.159c0 .538-.214 1.055-.595 1.436L4 17h5m6 0v1a3 3 0 11-6 0v-1m6 0H9",block:"M18.364 18.364A9 9 0 005.636 5.636m12.728 12.728A9 9 0 015.636 5.636m12.728 12.728L5.636 5.636",info:"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"},e[0]=x):x=e[0];const r=x,o=`
162
158
  w-full flex items-center gap-4 px-4 py-3.5 text-left transition-colors
163
159
  ${i?"hover:bg-zinc-800":"hover:bg-gray-100"}
164
- `,a=`w-5 h-5 flex-shrink-0 ${i?"text-zinc-500":"text-gray-400"}`,f=r[n];let h;e[1]!==f?(h=s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:f}),e[1]=f,e[2]=h):h=e[2];let d;e[3]!==a||e[4]!==h?(d=s.jsx("svg",{className:a,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:h}),e[3]=a,e[4]=h,e[5]=d):d=e[5];const u=`text-sm font-medium ${i?"text-white":"text-gray-900"}`;let m;e[6]!==l||e[7]!==u?(m=s.jsx("span",{className:u,children:l}),e[6]=l,e[7]=u,e[8]=m):m=e[8];let g;return e[9]!==o||e[10]!==d||e[11]!==m?(g=s.jsxs("button",{className:o,children:[d,m]}),e[9]=o,e[10]=d,e[11]=m,e[12]=g):g=e[12],g}),Ne={FULL:"h-full",TALL:"h-[80%]",HALF:"h-[50%]"},Ae=S.memo(function(){const t=D.c(65),{theme:e,businessInfo:n,webView:l,closeWebView:i}=Z(),[x,r]=S.useState(!0),[o,a]=S.useState(!1),f=e==="dark",h=n.brandColor||"#0084ff";let d;t[0]!==l?.url?(d=()=>{l?.url&&(r(!0),a(!1))},t[0]=l?.url,t[1]=d):d=t[1];const u=l?.url;let m;t[2]!==u?(m=[u],t[2]=u,t[3]=m):m=t[3],S.useEffect(d,m);let g;t[4]===Symbol.for("react.memo_cache_sentinel")?(g=()=>{r(!1)},t[4]=g):g=t[4];const p=g;let y;t[5]===Symbol.for("react.memo_cache_sentinel")?(y=()=>{r(!1),a(!0)},t[5]=y):y=t[5];const j=y,b=jt;if(!l||!l.isOpen)return null;const{url:w,viewMode:v,title:k,postbackData:N}=l;let L;t[6]!==k||t[7]!==w?(L=k||b(w),t[6]=k,t[7]=w,t[8]=L):L=t[8];const C=L,R=v==="FULL",$=v==="TALL"||v==="HALF",_=Ne[v]||Ne.TALL,M=`
160
+ `,a=`w-5 h-5 flex-shrink-0 ${i?"text-zinc-500":"text-gray-400"}`,f=r[n];let h;e[1]!==f?(h=s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:f}),e[1]=f,e[2]=h):h=e[2];let d;e[3]!==a||e[4]!==h?(d=s.jsx("svg",{className:a,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:h}),e[3]=a,e[4]=h,e[5]=d):d=e[5];const u=`text-sm font-medium ${i?"text-white":"text-gray-900"}`;let m;e[6]!==l||e[7]!==u?(m=s.jsx("span",{className:u,children:l}),e[6]=l,e[7]=u,e[8]=m):m=e[8];let g;return e[9]!==o||e[10]!==d||e[11]!==m?(g=s.jsxs("button",{className:o,children:[d,m]}),e[9]=o,e[10]=d,e[11]=m,e[12]=g):g=e[12],g}),be={FULL:"h-full",TALL:"h-[80%]",HALF:"h-[50%]"},Se=M.memo(function(){const t=B.c(65),{theme:e,businessInfo:n,webView:l,closeWebView:i}=Z(),[x,r]=M.useState(!0),[o,a]=M.useState(!1),f=e==="dark",h=n.brandColor||"#0084ff";let d;t[0]!==l?.url?(d=()=>{l?.url&&(r(!0),a(!1))},t[0]=l?.url,t[1]=d):d=t[1];const u=l?.url;let m;t[2]!==u?(m=[u],t[2]=u,t[3]=m):m=t[3],M.useEffect(d,m);let g;t[4]===Symbol.for("react.memo_cache_sentinel")?(g=()=>{r(!1)},t[4]=g):g=t[4];const p=g;let y;t[5]===Symbol.for("react.memo_cache_sentinel")?(y=()=>{r(!1),a(!0)},t[5]=y):y=t[5];const j=y,b=ft;if(!l||!l.isOpen)return null;const{url:v,viewMode:w,title:k,postbackData:N}=l;let _;t[6]!==k||t[7]!==v?(_=k||b(v),t[6]=k,t[7]=v,t[8]=_):_=t[8];const C=_,I=w==="FULL",$=w==="TALL"||w==="HALF",L=be[w]||be.TALL,S=`
165
161
  rcs-webview-overlay absolute inset-0 z-50 flex flex-col
166
- ${R?"":"justify-end"}
162
+ ${I?"":"justify-end"}
167
163
  ${f?"bg-black/60":"bg-black/40"}
168
- `,z=`WebView: ${C}`;let I;t[9]!==i||t[10]!==$?(I=$&&s.jsx("button",{type:"button",className:"absolute inset-0 w-full h-full cursor-default",onClick:i,"aria-label":"Close WebView"}),t[9]=i,t[10]=$,t[11]=I):I=t[11];const B=`
164
+ `,z=`WebView: ${C}`;let A;t[9]!==i||t[10]!==$?(A=$&&s.jsx("button",{type:"button",className:"absolute inset-0 w-full h-full cursor-default",onClick:i,"aria-label":"Close WebView"}),t[9]=i,t[10]=$,t[11]=A):A=t[11];const W=`
169
165
  rcs-webview-container relative flex flex-col overflow-hidden
170
166
  ${f?"bg-zinc-900":"bg-white"}
171
- ${_} w-full
167
+ ${L} w-full
172
168
  ${$?"rounded-t-2xl shadow-2xl":""}
173
- `;let A;t[12]===Symbol.for("react.memo_cache_sentinel")?(A={position:"relative",zIndex:1},t[12]=A):A=t[12];const O=`
169
+ `;let T;t[12]===Symbol.for("react.memo_cache_sentinel")?(T={position:"relative",zIndex:1},t[12]=T):T=t[12];const O=`
174
170
  rcs-webview-header flex items-center gap-3 px-2 py-2 flex-shrink-0
175
171
  border-b
176
172
  ${f?"bg-zinc-900 border-zinc-800":"bg-white border-gray-200"}
@@ -178,41 +174,41 @@ See https://react.dev/link/invalid-hook-call for tips about how to debug and fix
178
174
  rcs-webview-close w-10 h-10 rounded-full flex items-center justify-center
179
175
  transition-colors
180
176
  ${f?"text-white hover:bg-zinc-800":"text-gray-700 hover:bg-gray-100"}
181
- `;let V;t[13]===Symbol.for("react.memo_cache_sentinel")?(V=s.jsx("svg",{className:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 19l-7-7 7-7"})}),t[13]=V):V=t[13];let J;t[14]!==i||t[15]!==F?(J=s.jsx("button",{type:"button",onClick:i,className:F,"aria-label":"Close WebView",children:V}),t[14]=i,t[15]=F,t[16]=J):J=t[16];const P=`
177
+ `;let V;t[13]===Symbol.for("react.memo_cache_sentinel")?(V=s.jsx("svg",{className:"w-6 h-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 19l-7-7 7-7"})}),t[13]=V):V=t[13];let Y;t[14]!==i||t[15]!==F?(Y=s.jsx("button",{type:"button",onClick:i,className:F,"aria-label":"Close WebView",children:V}),t[14]=i,t[15]=F,t[16]=Y):Y=t[16];const P=`
182
178
  rcs-webview-title text-base font-medium truncate
183
179
  ${f?"text-white":"text-gray-900"}
184
180
  `;let q;t[17]!==C||t[18]!==P?(q=s.jsx("h2",{className:P,children:C}),t[17]=C,t[18]=P,t[19]=q):q=t[19];const K=`
185
181
  rcs-webview-url text-xs truncate
186
182
  ${f?"text-zinc-400":"text-gray-500"}
187
- `;let T;t[20]!==w?(T=b(w),t[20]=w,t[21]=T):T=t[21];let G;t[22]!==K||t[23]!==T?(G=s.jsx("p",{className:K,children:T}),t[22]=K,t[23]=T,t[24]=G):G=t[24];let E;t[25]!==q||t[26]!==G?(E=s.jsxs("div",{className:"flex-1 min-w-0",children:[q,G]}),t[25]=q,t[26]=G,t[27]=E):E=t[27];const Y=`
183
+ `;let R;t[20]!==v?(R=b(v),t[20]=v,t[21]=R):R=t[21];let G;t[22]!==K||t[23]!==R?(G=s.jsx("p",{className:K,children:R}),t[22]=K,t[23]=R,t[24]=G):G=t[24];let E;t[25]!==q||t[26]!==G?(E=s.jsxs("div",{className:"flex-1 min-w-0",children:[q,G]}),t[25]=q,t[26]=G,t[27]=E):E=t[27];const J=`
188
184
  w-10 h-10 rounded-full flex items-center justify-center
189
185
  ${f?"text-zinc-400 hover:bg-zinc-800":"text-gray-500 hover:bg-gray-100"}
190
- `;let W;t[28]===Symbol.for("react.memo_cache_sentinel")?(W=s.jsxs("svg",{className:"w-5 h-5",fill:"currentColor",viewBox:"0 0 24 24",children:[s.jsx("circle",{cx:"12",cy:"5",r:"2"}),s.jsx("circle",{cx:"12",cy:"12",r:"2"}),s.jsx("circle",{cx:"12",cy:"19",r:"2"})]}),t[28]=W):W=t[28];let U;t[29]!==Y?(U=s.jsx("button",{type:"button",className:Y,"aria-label":"More options",children:W}),t[29]=Y,t[30]=U):U=t[30];let H;t[31]!==O||t[32]!==J||t[33]!==E||t[34]!==U?(H=s.jsxs("header",{className:O,children:[J,E,U]}),t[31]=O,t[32]=J,t[33]=E,t[34]=U,t[35]=H):H=t[35];let Q;t[36]!==h||t[37]!==x?(Q=x&&s.jsx("div",{className:"rcs-webview-loading absolute top-14 left-0 right-0 h-1 overflow-hidden",style:{backgroundColor:`${h}20`},children:s.jsx("div",{className:"h-full animate-pulse",style:{backgroundColor:h,animation:"webview-loading 1.5s ease-in-out infinite",width:"30%"}})}),t[36]=h,t[37]=x,t[38]=Q):Q=t[38];let X;t[39]!==i||t[40]!==f||t[41]!==o?(X=o&&s.jsxs("div",{className:`
186
+ `;let D;t[28]===Symbol.for("react.memo_cache_sentinel")?(D=s.jsxs("svg",{className:"w-5 h-5",fill:"currentColor",viewBox:"0 0 24 24",children:[s.jsx("circle",{cx:"12",cy:"5",r:"2"}),s.jsx("circle",{cx:"12",cy:"12",r:"2"}),s.jsx("circle",{cx:"12",cy:"19",r:"2"})]}),t[28]=D):D=t[28];let U;t[29]!==J?(U=s.jsx("button",{type:"button",className:J,"aria-label":"More options",children:D}),t[29]=J,t[30]=U):U=t[30];let H;t[31]!==O||t[32]!==Y||t[33]!==E||t[34]!==U?(H=s.jsxs("header",{className:O,children:[Y,E,U]}),t[31]=O,t[32]=Y,t[33]=E,t[34]=U,t[35]=H):H=t[35];let Q;t[36]!==h||t[37]!==x?(Q=x&&s.jsx("div",{className:"rcs-webview-loading absolute top-14 left-0 right-0 h-1 overflow-hidden",style:{backgroundColor:`${h}20`},children:s.jsx("div",{className:"h-full animate-pulse",style:{backgroundColor:h,animation:"webview-loading 1.5s ease-in-out infinite",width:"30%"}})}),t[36]=h,t[37]=x,t[38]=Q):Q=t[38];let X;t[39]!==i||t[40]!==f||t[41]!==o?(X=o&&s.jsxs("div",{className:`
191
187
  rcs-webview-error flex-1 flex flex-col items-center justify-center p-6 text-center
192
188
  ${f?"text-zinc-400":"text-gray-500"}
193
189
  `,children:[s.jsx("svg",{className:"w-16 h-16 mb-4 opacity-50",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"})}),s.jsx("p",{className:"text-sm font-medium mb-2",children:"Unable to load page"}),s.jsx("p",{className:"text-xs opacity-75 mb-4",children:"This content cannot be displayed in the emulator"}),s.jsx("button",{type:"button",onClick:i,className:`
194
190
  px-4 py-2 rounded-full text-sm font-medium
195
191
  ${f?"bg-zinc-800 text-white hover:bg-zinc-700":"bg-gray-100 text-gray-700 hover:bg-gray-200"}
196
- `,children:"Go Back"})]}),t[39]=i,t[40]=f,t[41]=o,t[42]=X):X=t[42];let ee;t[43]!==C||t[44]!==o||t[45]!==w?(ee=!o&&s.jsx("div",{className:"rcs-webview-iframe-container flex-1 overflow-hidden",children:s.jsx("iframe",{src:w,title:C,className:"w-full h-full border-0",onLoad:p,onError:j,sandbox:"allow-scripts allow-same-origin allow-forms allow-popups",referrerPolicy:"no-referrer-when-downgrade",loading:"lazy"})}),t[43]=C,t[44]=o,t[45]=w,t[46]=ee):ee=t[46];let te;t[47]!==$||t[48]!==f?(te=$&&s.jsx("div",{className:`
192
+ `,children:"Go Back"})]}),t[39]=i,t[40]=f,t[41]=o,t[42]=X):X=t[42];let ee;t[43]!==C||t[44]!==o||t[45]!==v?(ee=!o&&s.jsx("div",{className:"rcs-webview-iframe-container flex-1 overflow-hidden",children:s.jsx("iframe",{src:v,title:C,className:"w-full h-full border-0",onLoad:p,onError:j,sandbox:"allow-scripts allow-same-origin allow-forms allow-popups",referrerPolicy:"no-referrer-when-downgrade",loading:"lazy"})}),t[43]=C,t[44]=o,t[45]=v,t[46]=ee):ee=t[46];let te;t[47]!==$||t[48]!==f?(te=$&&s.jsx("div",{className:`
197
193
  rcs-webview-safe-area h-2 flex-shrink-0
198
194
  ${f?"bg-zinc-900":"bg-white"}
199
- `}),t[47]=$,t[48]=f,t[49]=te):te=t[49];let ne;t[50]!==H||t[51]!==Q||t[52]!==X||t[53]!==ee||t[54]!==te||t[55]!==B?(ne=s.jsxs("div",{className:B,style:A,children:[H,Q,X,ee,te]}),t[50]=H,t[51]=Q,t[52]=X,t[53]=ee,t[54]=te,t[55]=B,t[56]=ne):ne=t[56];let oe;t[57]===Symbol.for("react.memo_cache_sentinel")?(oe=s.jsx("style",{children:`
195
+ `}),t[47]=$,t[48]=f,t[49]=te):te=t[49];let ne;t[50]!==H||t[51]!==Q||t[52]!==X||t[53]!==ee||t[54]!==te||t[55]!==W?(ne=s.jsxs("div",{className:W,style:T,children:[H,Q,X,ee,te]}),t[50]=H,t[51]=Q,t[52]=X,t[53]=ee,t[54]=te,t[55]=W,t[56]=ne):ne=t[56];let oe;t[57]===Symbol.for("react.memo_cache_sentinel")?(oe=s.jsx("style",{children:`
200
196
  @keyframes webview-loading {
201
197
  0% { transform: translateX(-100%); }
202
198
  50% { transform: translateX(200%); }
203
199
  100% { transform: translateX(-100%); }
204
200
  }
205
- `}),t[57]=oe):oe=t[57];let ie;return t[58]!==N||t[59]!==ne||t[60]!==M||t[61]!==z||t[62]!==I||t[63]!==v?(ie=s.jsxs("div",{className:M,role:"dialog","aria-modal":"true","aria-label":z,"data-postback":N,"data-view-mode":v,children:[I,ne,oe]}),t[58]=N,t[59]=ne,t[60]=M,t[61]=z,t[62]=I,t[63]=v,t[64]=ie):ie=t[64],ie});function jt(c){try{return new URL(c).hostname}catch{return"Web Page"}}const vt=S.memo(function(t){const e=D.c(39),{onUnlock:n,messagePreview:l}=t,i=l===void 0?"New message":l,{theme:x,businessInfo:r}=Z();let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o=new Date,e[0]=o):o=e[0];const[a,f]=S.useState(o),h=x==="dark";let d,u;e[1]===Symbol.for("react.memo_cache_sentinel")?(d=()=>{const F=setInterval(()=>{f(new Date)},1e3);return()=>clearInterval(F)},u=[],e[1]=d,e[2]=u):(d=e[1],u=e[2]),S.useEffect(d,u);let m;e[3]!==a?(m=a.toLocaleTimeString([],{hour:"numeric",minute:"2-digit",hour12:!0}),e[3]=a,e[4]=m):m=e[4];const g=m;let p;e[5]!==a?(p=a.toLocaleDateString([],{weekday:"short",month:"long",day:"numeric"}),e[5]=a,e[6]=p):p=e[6];const y=p,j=`
201
+ `}),t[57]=oe):oe=t[57];let ie;return t[58]!==N||t[59]!==ne||t[60]!==S||t[61]!==z||t[62]!==A||t[63]!==w?(ie=s.jsxs("div",{className:S,role:"dialog","aria-modal":"true","aria-label":z,"data-postback":N,"data-view-mode":w,children:[A,ne,oe]}),t[58]=N,t[59]=ne,t[60]=S,t[61]=z,t[62]=A,t[63]=w,t[64]=ie):ie=t[64],ie});function ft(c){try{return new URL(c).hostname}catch{return"Web Page"}}const mt=M.memo(function(t){const e=B.c(39),{onUnlock:n,messagePreview:l}=t,i=l===void 0?"New message":l,{theme:x,businessInfo:r}=Z();let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o=new Date,e[0]=o):o=e[0];const[a,f]=M.useState(o),h=x==="dark";let d,u;e[1]===Symbol.for("react.memo_cache_sentinel")?(d=()=>{const F=setInterval(()=>{f(new Date)},1e3);return()=>clearInterval(F)},u=[],e[1]=d,e[2]=u):(d=e[1],u=e[2]),M.useEffect(d,u);let m;e[3]!==a?(m=a.toLocaleTimeString([],{hour:"numeric",minute:"2-digit",hour12:!0}),e[3]=a,e[4]=m):m=e[4];const g=m;let p;e[5]!==a?(p=a.toLocaleDateString([],{weekday:"short",month:"long",day:"numeric"}),e[5]=a,e[6]=p):p=e[6];const y=p,j=`
206
202
  lock-screen flex flex-col h-full w-full select-none
207
203
  ${h?"bg-zinc-900":"bg-zinc-800"}
208
- `;let b;e[7]===Symbol.for("react.memo_cache_sentinel")?(b=s.jsx("div",{className:"h-6"}),e[7]=b):b=e[7];let w;e[8]===Symbol.for("react.memo_cache_sentinel")?(w=s.jsx("div",{className:"flex justify-center mt-4",children:s.jsx("div",{className:"w-8 h-8 rounded-full bg-zinc-700 flex items-center justify-center",children:s.jsx("svg",{className:"w-4 h-4 text-zinc-400",fill:"currentColor",viewBox:"0 0 20 20",children:s.jsx("path",{fillRule:"evenodd",d:"M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z",clipRule:"evenodd"})})})}),e[8]=w):w=e[8];let v;e[9]!==g?(v=s.jsx("div",{className:"mt-6 text-center",children:s.jsx("h1",{className:"text-5xl font-light text-white tracking-tight",children:g})}),e[9]=g,e[10]=v):v=e[10];let k;e[11]!==y?(k=s.jsx("p",{className:"text-zinc-400 text-sm",children:y}),e[11]=y,e[12]=k):k=e[12];let N;e[13]===Symbol.for("react.memo_cache_sentinel")?(N=s.jsxs("div",{className:"flex items-center justify-center gap-1 mt-1 text-zinc-500 text-xs",children:[s.jsx("svg",{className:"w-3.5 h-3.5",fill:"currentColor",viewBox:"0 0 20 20",children:s.jsx("path",{d:"M5.5 16a3.5 3.5 0 01-.369-6.98 4 4 0 117.753-1.977A4.5 4.5 0 1113.5 16h-8z"})}),s.jsx("span",{children:"19°C"})]}),e[13]=N):N=e[13];let L;e[14]!==k?(L=s.jsxs("div",{className:"mt-2 text-center",children:[k,N]}),e[14]=k,e[15]=L):L=e[15];let C;e[16]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx("div",{className:"h-24"}),e[16]=C):C=e[16];let R;e[17]!==r.logo||e[18]!==r.name?(R=s.jsx("div",{className:"w-12 h-12 rounded-xl bg-zinc-900 flex items-center justify-center flex-shrink-0 overflow-hidden",children:r.logo?s.jsx("img",{src:r.logo,alt:r.name,className:"w-full h-full object-cover"}):s.jsx("div",{className:"text-white",children:s.jsxs("svg",{className:"w-7 h-7",viewBox:"0 0 24 24",fill:"currentColor",children:[s.jsx("circle",{cx:"12",cy:"12",r:"1.5"}),s.jsx("circle",{cx:"12",cy:"6",r:"1"}),s.jsx("circle",{cx:"12",cy:"18",r:"1"}),s.jsx("circle",{cx:"6",cy:"12",r:"1"}),s.jsx("circle",{cx:"18",cy:"12",r:"1"}),s.jsx("circle",{cx:"8",cy:"8",r:"0.8"}),s.jsx("circle",{cx:"16",cy:"8",r:"0.8"}),s.jsx("circle",{cx:"8",cy:"16",r:"0.8"}),s.jsx("circle",{cx:"16",cy:"16",r:"0.8"}),s.jsx("circle",{cx:"6",cy:"6",r:"0.5"}),s.jsx("circle",{cx:"18",cy:"6",r:"0.5"}),s.jsx("circle",{cx:"6",cy:"18",r:"0.5"}),s.jsx("circle",{cx:"18",cy:"18",r:"0.5"})]})})}),e[17]=r.logo,e[18]=r.name,e[19]=R):R=e[19];let $;e[20]!==r.name?($=s.jsx("p",{className:"text-sm font-semibold text-gray-900 truncate",children:r.name}),e[20]=r.name,e[21]=$):$=e[21];let _;e[22]!==i?(_=s.jsx("p",{className:"text-sm text-gray-500 truncate",children:i}),e[22]=i,e[23]=_):_=e[23];let M;e[24]!==$||e[25]!==_?(M=s.jsxs("div",{className:"flex-1 text-left min-w-0",children:[$,_]}),e[24]=$,e[25]=_,e[26]=M):M=e[26];let z;e[27]===Symbol.for("react.memo_cache_sentinel")?(z=s.jsx("span",{className:"text-xs text-gray-400 flex-shrink-0",children:"now"}),e[27]=z):z=e[27];let I;e[28]!==n||e[29]!==R||e[30]!==M?(I=s.jsx("div",{className:"px-4 pb-8",children:s.jsxs("button",{onClick:n,className:`w-full bg-white rounded-2xl p-3 flex items-center gap-3 shadow-lg \r
209
- transition-transform active:scale-[0.98] hover:shadow-xl`,children:[R,M,z]})}),e[28]=n,e[29]=R,e[30]=M,e[31]=I):I=e[31];let B;e[32]===Symbol.for("react.memo_cache_sentinel")?(B=s.jsx("div",{className:"flex-1"}),e[32]=B):B=e[32];let A;e[33]===Symbol.for("react.memo_cache_sentinel")?(A=s.jsx("div",{className:"flex justify-center pb-2",children:s.jsx("div",{className:"w-32 h-1 rounded-full bg-zinc-600"})}),e[33]=A):A=e[33];let O;return e[34]!==v||e[35]!==L||e[36]!==I||e[37]!==j?(O=s.jsxs("div",{className:j,children:[b,w,v,L,C,I,B,A]}),e[34]=v,e[35]=L,e[36]=I,e[37]=j,e[38]=O):O=e[38],O}),Ce={name:"Business",verified:!1},wt=S.memo(function(t){const e=D.c(24),{flow:n,onUserReply:l,theme:i,device:x,businessInfo:r,showSuggestions:o}=t;let a;e[0]!==n||e[1]!==l?(a={flow:n,onUserReply:l,typingDelay:800},e[0]=n,e[1]=l,e[2]=a):a=e[2];const{state:f,handleReply:h,handleAction:d}=qe(a),[u,m]=S.useState(!1);let g;e[3]===Symbol.for("react.memo_cache_sentinel")?(g=()=>{m(kt)},e[3]=g):g=e[3];const p=g,[y,j]=S.useState(null);let b;e[4]===Symbol.for("react.memo_cache_sentinel")?(b=M=>{j({...M,isOpen:!0})},e[4]=b):b=e[4];const w=b;let v;e[5]===Symbol.for("react.memo_cache_sentinel")?(v=()=>{j(null)},e[5]=v):v=e[5];const k=v;let N;e[6]!==d||e[7]!==l?(N=M=>{if(!se(M))return;const z=_e(M);if(z){w({url:z.url,viewMode:z.webviewViewMode||"TALL",title:z.description||"",postbackData:M.action.postback.data}),l({type:"action",postbackData:M.action.postback.data,displayText:M.action.displayText,timestamp:Date.now(),actionData:{type:"webview",url:z.url,viewMode:z.webviewViewMode||"TALL",description:z.description}});return}d(M)},e[6]=d,e[7]=l,e[8]=N):N=e[8];const L=N;let C;e[9]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx(gt,{}),e[9]=C):C=e[9];let R;e[10]!==u?(R=u&&s.jsx(pt,{}),e[10]=u,e[11]=R):R=e[11];let $;e[12]===Symbol.for("react.memo_cache_sentinel")?($=s.jsx(Ae,{}),e[12]=$):$=e[12];let _;return e[13]!==r||e[14]!==x||e[15]!==L||e[16]!==h||e[17]!==u||e[18]!==o||e[19]!==f||e[20]!==R||e[21]!==i||e[22]!==y?(_=s.jsxs(Se,{theme:i,device:x,businessInfo:r,state:f,showSuggestions:o,isProfileOpen:u,toggleProfile:p,onReply:h,onAction:L,webView:y,openWebView:w,closeWebView:k,children:[C,R,$]}),e[13]=r,e[14]=x,e[15]=L,e[16]=h,e[17]=u,e[18]=o,e[19]=f,e[20]=R,e[21]=i,e[22]=y,e[23]=_):_=e[23],_}),Te=S.memo(function(t){const e=D.c(84),{messages:n,jsonUrl:l,onUserReply:i,theme:x,device:r,businessInfo:o,className:a,width:f,height:h,showSuggestions:d,showLockScreen:u}=t,m=x===void 0?"light":x,g=r===void 0?"android":r,p=a===void 0?"":a,y=f===void 0?375:f,j=h===void 0?667:h,b=d===void 0?!0:d,w=u===void 0?!1:u,[v,k]=S.useState(w);let N;e[0]===Symbol.for("react.memo_cache_sentinel")?(N=()=>{k(!1)},e[0]=N):N=e[0];const L=N,{data:C,isLoading:R,error:$}=Ie(l),_=l?C:n;let M;e[1]!==_?(M=_?$e(_):!1,e[1]=_,e[2]=M):M=e[2];const z=M;let I;e[3]!==o||e[4]!==_?.name?(I=()=>({...Ce,...o,name:o?.name||_?.name||Ce.name}),e[3]=o,e[4]=_?.name,e[5]=I):I=e[5],_?.name;let B;e[6]!==I?(B=I(),e[6]=I,e[7]=B):B=e[7];const A=B;let O;e[8]!==_||e[9]!==z?(O=_&&z?ze(_):"New message",e[8]=_,e[9]=z,e[10]=O):O=e[10];const F=O,V=m==="dark";let J;e[11]!==p||e[12]!==g||e[13]!==j||e[14]!==V||e[15]!==m||e[16]!==y?(J=T=>{const{children:G}=T;return s.jsx("div",{className:`
204
+ `;let b;e[7]===Symbol.for("react.memo_cache_sentinel")?(b=s.jsx("div",{className:"h-6"}),e[7]=b):b=e[7];let v;e[8]===Symbol.for("react.memo_cache_sentinel")?(v=s.jsx("div",{className:"flex justify-center mt-4",children:s.jsx("div",{className:"w-8 h-8 rounded-full bg-zinc-700 flex items-center justify-center",children:s.jsx("svg",{className:"w-4 h-4 text-zinc-400",fill:"currentColor",viewBox:"0 0 20 20",children:s.jsx("path",{fillRule:"evenodd",d:"M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z",clipRule:"evenodd"})})})}),e[8]=v):v=e[8];let w;e[9]!==g?(w=s.jsx("div",{className:"mt-6 text-center",children:s.jsx("h1",{className:"text-5xl font-light text-white tracking-tight",children:g})}),e[9]=g,e[10]=w):w=e[10];let k;e[11]!==y?(k=s.jsx("p",{className:"text-zinc-400 text-sm",children:y}),e[11]=y,e[12]=k):k=e[12];let N;e[13]===Symbol.for("react.memo_cache_sentinel")?(N=s.jsxs("div",{className:"flex items-center justify-center gap-1 mt-1 text-zinc-500 text-xs",children:[s.jsx("svg",{className:"w-3.5 h-3.5",fill:"currentColor",viewBox:"0 0 20 20",children:s.jsx("path",{d:"M5.5 16a3.5 3.5 0 01-.369-6.98 4 4 0 117.753-1.977A4.5 4.5 0 1113.5 16h-8z"})}),s.jsx("span",{children:"19°C"})]}),e[13]=N):N=e[13];let _;e[14]!==k?(_=s.jsxs("div",{className:"mt-2 text-center",children:[k,N]}),e[14]=k,e[15]=_):_=e[15];let C;e[16]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx("div",{className:"h-24"}),e[16]=C):C=e[16];let I;e[17]!==r.logo||e[18]!==r.name?(I=s.jsx("div",{className:"w-12 h-12 rounded-xl bg-zinc-900 flex items-center justify-center flex-shrink-0 overflow-hidden",children:r.logo?s.jsx("img",{src:r.logo,alt:r.name,className:"w-full h-full object-cover"}):s.jsx("div",{className:"text-white",children:s.jsxs("svg",{className:"w-7 h-7",viewBox:"0 0 24 24",fill:"currentColor",children:[s.jsx("circle",{cx:"12",cy:"12",r:"1.5"}),s.jsx("circle",{cx:"12",cy:"6",r:"1"}),s.jsx("circle",{cx:"12",cy:"18",r:"1"}),s.jsx("circle",{cx:"6",cy:"12",r:"1"}),s.jsx("circle",{cx:"18",cy:"12",r:"1"}),s.jsx("circle",{cx:"8",cy:"8",r:"0.8"}),s.jsx("circle",{cx:"16",cy:"8",r:"0.8"}),s.jsx("circle",{cx:"8",cy:"16",r:"0.8"}),s.jsx("circle",{cx:"16",cy:"16",r:"0.8"}),s.jsx("circle",{cx:"6",cy:"6",r:"0.5"}),s.jsx("circle",{cx:"18",cy:"6",r:"0.5"}),s.jsx("circle",{cx:"6",cy:"18",r:"0.5"}),s.jsx("circle",{cx:"18",cy:"18",r:"0.5"})]})})}),e[17]=r.logo,e[18]=r.name,e[19]=I):I=e[19];let $;e[20]!==r.name?($=s.jsx("p",{className:"text-sm font-semibold text-gray-900 truncate",children:r.name}),e[20]=r.name,e[21]=$):$=e[21];let L;e[22]!==i?(L=s.jsx("p",{className:"text-sm text-gray-500 truncate",children:i}),e[22]=i,e[23]=L):L=e[23];let S;e[24]!==$||e[25]!==L?(S=s.jsxs("div",{className:"flex-1 text-left min-w-0",children:[$,L]}),e[24]=$,e[25]=L,e[26]=S):S=e[26];let z;e[27]===Symbol.for("react.memo_cache_sentinel")?(z=s.jsx("span",{className:"text-xs text-gray-400 flex-shrink-0",children:"now"}),e[27]=z):z=e[27];let A;e[28]!==n||e[29]!==I||e[30]!==S?(A=s.jsx("div",{className:"px-4 pb-8",children:s.jsxs("button",{onClick:n,className:`w-full bg-white rounded-2xl p-3 flex items-center gap-3 shadow-lg
205
+ transition-transform active:scale-[0.98] hover:shadow-xl`,children:[I,S,z]})}),e[28]=n,e[29]=I,e[30]=S,e[31]=A):A=e[31];let W;e[32]===Symbol.for("react.memo_cache_sentinel")?(W=s.jsx("div",{className:"flex-1"}),e[32]=W):W=e[32];let T;e[33]===Symbol.for("react.memo_cache_sentinel")?(T=s.jsx("div",{className:"flex justify-center pb-2",children:s.jsx("div",{className:"w-32 h-1 rounded-full bg-zinc-600"})}),e[33]=T):T=e[33];let O;return e[34]!==w||e[35]!==_||e[36]!==A||e[37]!==j?(O=s.jsxs("div",{className:j,children:[b,v,w,_,C,A,W,T]}),e[34]=w,e[35]=_,e[36]=A,e[37]=j,e[38]=O):O=e[38],O}),ye={name:"Business",verified:!1},ut=M.memo(function(t){const e=B.c(24),{flow:n,onUserReply:l,theme:i,device:x,businessInfo:r,showSuggestions:o}=t;let a;e[0]!==n||e[1]!==l?(a={flow:n,onUserReply:l,typingDelay:800},e[0]=n,e[1]=l,e[2]=a):a=e[2];const{state:f,handleReply:h,handleAction:d}=We(a),[u,m]=M.useState(!1);let g;e[3]===Symbol.for("react.memo_cache_sentinel")?(g=()=>{m(ht)},e[3]=g):g=e[3];const p=g,[y,j]=M.useState(null);let b;e[4]===Symbol.for("react.memo_cache_sentinel")?(b=S=>{j({...S,isOpen:!0})},e[4]=b):b=e[4];const v=b;let w;e[5]===Symbol.for("react.memo_cache_sentinel")?(w=()=>{j(null)},e[5]=w):w=e[5];const k=w;let N;e[6]!==d||e[7]!==l?(N=S=>{if(!se(S))return;const z=je(S);if(z){v({url:z.url,viewMode:z.webviewViewMode||"TALL",title:z.description||"",postbackData:S.action.postback.data}),l({type:"action",postbackData:S.action.postback.data,displayText:S.action.displayText,timestamp:Date.now(),actionData:{type:"webview",url:z.url,viewMode:z.webviewViewMode||"TALL",description:z.description}});return}d(S)},e[6]=d,e[7]=l,e[8]=N):N=e[8];const _=N;let C;e[9]===Symbol.for("react.memo_cache_sentinel")?(C=s.jsx(it,{}),e[9]=C):C=e[9];let I;e[10]!==u?(I=u&&s.jsx(at,{}),e[10]=u,e[11]=I):I=e[11];let $;e[12]===Symbol.for("react.memo_cache_sentinel")?($=s.jsx(Se,{}),e[12]=$):$=e[12];let L;return e[13]!==r||e[14]!==x||e[15]!==_||e[16]!==h||e[17]!==u||e[18]!==o||e[19]!==f||e[20]!==I||e[21]!==i||e[22]!==y?(L=s.jsxs(ve,{theme:i,device:x,businessInfo:r,state:f,showSuggestions:o,isProfileOpen:u,toggleProfile:p,onReply:h,onAction:_,webView:y,openWebView:v,closeWebView:k,children:[C,I,$]}),e[13]=r,e[14]=x,e[15]=_,e[16]=h,e[17]=u,e[18]=o,e[19]=f,e[20]=I,e[21]=i,e[22]=y,e[23]=L):L=e[23],L}),Me=M.memo(function(t){const e=B.c(84),{messages:n,jsonUrl:l,onUserReply:i,theme:x,device:r,businessInfo:o,className:a,width:f,height:h,showSuggestions:d,showLockScreen:u}=t,m=x===void 0?"light":x,g=r===void 0?"android":r,p=a===void 0?"":a,y=f===void 0?375:f,j=h===void 0?667:h,b=d===void 0?!0:d,v=u===void 0?!1:u,[w,k]=M.useState(v);let N;e[0]===Symbol.for("react.memo_cache_sentinel")?(N=()=>{k(!1)},e[0]=N):N=e[0];const _=N,{data:C,isLoading:I,error:$}=_e(l),L=l?C:n;let S;e[1]!==L?(S=L?Ne(L):!1,e[1]=L,e[2]=S):S=e[2];const z=S;let A;e[3]!==o||e[4]!==L?.name?(A=()=>({...ye,...o,name:o?.name||L?.name||ye.name}),e[3]=o,e[4]=L?.name,e[5]=A):A=e[5],L?.name;let W;e[6]!==A?(W=A(),e[6]=A,e[7]=W):W=e[7];const T=W;let O;e[8]!==L||e[9]!==z?(O=L&&z?Ce(L):"New message",e[8]=L,e[9]=z,e[10]=O):O=e[10];const F=O,V=m==="dark";let Y;e[11]!==p||e[12]!==g||e[13]!==j||e[14]!==V||e[15]!==m||e[16]!==y?(Y=R=>{const{children:G}=R;return s.jsx("div",{className:`
210
206
  rcs-emulator relative overflow-hidden
211
207
  rounded-2xl shadow-2xl
212
208
  ${V?"bg-zinc-950":"bg-white"}
213
209
  ${p}
214
- `,style:{width:y,height:j},role:"application","aria-label":"RCS Message Emulator","data-theme":m,"data-device":g,children:G})},e[11]=p,e[12]=g,e[13]=j,e[14]=V,e[15]=m,e[16]=y,e[17]=J):J=e[17];const P=J;if(l&&R){const T=`
210
+ `,style:{width:y,height:j},role:"application","aria-label":"RCS Message Emulator","data-theme":m,"data-device":g,children:G})},e[11]=p,e[12]=g,e[13]=j,e[14]=V,e[15]=m,e[16]=y,e[17]=Y):Y=e[17];const P=Y;if(l&&I){const R=`
215
211
  w-10 h-10 border-3 border-t-transparent rounded-full animate-spin mb-4
216
212
  ${V?"border-zinc-600":"border-gray-300"}
217
- `;let G;e[18]===Symbol.for("react.memo_cache_sentinel")?(G={borderTopColor:"transparent"},e[18]=G):G=e[18];let E;e[19]!==T?(E=s.jsx("div",{className:T,style:G}),e[19]=T,e[20]=E):E=e[20];const Y=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let W;e[21]!==Y?(W=s.jsx("p",{className:Y,children:"Loading conversation..."}),e[21]=Y,e[22]=W):W=e[22];let U;e[23]!==E||e[24]!==W?(U=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6",children:[E,W]}),e[23]=E,e[24]=W,e[25]=U):U=e[25];let H;return e[26]!==P||e[27]!==U?(H=s.jsx(P,{children:U}),e[26]=P,e[27]=U,e[28]=H):H=e[28],H}if(l&&$){let T;e[29]===Symbol.for("react.memo_cache_sentinel")?(T=s.jsx("svg",{className:"w-12 h-12 mx-auto mb-4 text-red-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})}),e[29]=T):T=e[29];const G=`text-lg font-medium mb-2 ${V?"text-white":"text-gray-900"}`;let E;e[30]!==G?(E=s.jsx("h3",{className:G,children:"Failed to Load"}),e[30]=G,e[31]=E):E=e[31];const Y=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let W;e[32]!==$||e[33]!==Y?(W=s.jsx("p",{className:Y,children:$}),e[32]=$,e[33]=Y,e[34]=W):W=e[34];const U=`text-xs mt-2 break-all max-w-full ${V?"text-zinc-500":"text-gray-400"}`;let H;e[35]!==l||e[36]!==U?(H=s.jsx("p",{className:U,children:l}),e[35]=l,e[36]=U,e[37]=H):H=e[37];let Q;e[38]!==E||e[39]!==W||e[40]!==H?(Q=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6 text-center",children:[T,E,W,H]}),e[38]=E,e[39]=W,e[40]=H,e[41]=Q):Q=e[41];let X;return e[42]!==P||e[43]!==Q?(X=s.jsx(P,{children:Q}),e[42]=P,e[43]=Q,e[44]=X):X=e[44],X}if(!_){const T=`w-12 h-12 mx-auto mb-4 ${V?"text-zinc-600":"text-gray-300"}`;let G;e[45]===Symbol.for("react.memo_cache_sentinel")?(G=s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"}),e[45]=G):G=e[45];let E;e[46]!==T?(E=s.jsx("svg",{className:T,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:G}),e[46]=T,e[47]=E):E=e[47];const Y=`text-lg font-medium mb-2 ${V?"text-white":"text-gray-900"}`;let W;e[48]!==Y?(W=s.jsx("h3",{className:Y,children:"No Conversation Data"}),e[48]=Y,e[49]=W):W=e[49];const U=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let H;e[50]===Symbol.for("react.memo_cache_sentinel")?(H=s.jsx("code",{className:"px-1 py-0.5 rounded bg-gray-100 dark:bg-zinc-800",children:"messages"}),e[50]=H):H=e[50];let Q;e[51]===Symbol.for("react.memo_cache_sentinel")?(Q=s.jsx("code",{className:"px-1 py-0.5 rounded bg-gray-100 dark:bg-zinc-800",children:"jsonUrl"}),e[51]=Q):Q=e[51];let X;e[52]!==U?(X=s.jsxs("p",{className:U,children:["Provide either"," ",H," ","or"," ",Q," ","prop"]}),e[52]=U,e[53]=X):X=e[53];let ee;e[54]!==E||e[55]!==W||e[56]!==X?(ee=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6 text-center",children:[E,W,X]}),e[54]=E,e[55]=W,e[56]=X,e[57]=ee):ee=e[57];let te;return e[58]!==P||e[59]!==ee?(te=s.jsx(P,{children:ee}),e[58]=P,e[59]=ee,e[60]=te):te=e[60],te}if(!z){let T;e[61]===Symbol.for("react.memo_cache_sentinel")?(T=s.jsx("svg",{className:"w-12 h-12 mx-auto mb-4 text-amber-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"})}),e[61]=T):T=e[61];const G=`text-lg font-medium mb-2 ${V?"text-white":"text-gray-900"}`;let E;e[62]!==G?(E=s.jsx("h3",{className:G,children:"Invalid RBM JSON"}),e[62]=G,e[63]=E):E=e[63];const Y=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let W;e[64]!==Y?(W=s.jsx("p",{className:Y,children:"The conversation flow structure is not valid"}),e[64]=Y,e[65]=W):W=e[65];let U;e[66]!==E||e[67]!==W?(U=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6 text-center",children:[T,E,W]}),e[66]=E,e[67]=W,e[68]=U):U=e[68];let H;return e[69]!==P||e[70]!==U?(H=s.jsx(P,{children:U}),e[69]=P,e[70]=U,e[71]=H):H=e[71],H}let q;e[72]!==g||e[73]!==_||e[74]!==v||e[75]!==A||e[76]!==F||e[77]!==i||e[78]!==b||e[79]!==m?(q=v?s.jsx(Se,{theme:m,device:g,businessInfo:A,state:{currentMessageId:null,chatHistory:[],isTyping:!1,error:null},showSuggestions:!1,isProfileOpen:!1,toggleProfile:Nt,onReply:Ct,onAction:_t,webView:null,openWebView:Lt,closeWebView:St,children:s.jsx(vt,{onUnlock:L,messagePreview:F})}):s.jsx(wt,{flow:_,onUserReply:i,theme:m,device:g,businessInfo:A,showSuggestions:b}),e[72]=g,e[73]=_,e[74]=v,e[75]=A,e[76]=F,e[77]=i,e[78]=b,e[79]=m,e[80]=q):q=e[80];let K;return e[81]!==P||e[82]!==q?(K=s.jsx(P,{children:q}),e[81]=P,e[82]=q,e[83]=K):K=e[83],K});function kt(c){return!c}function Nt(){}function Ct(){}function _t(){}function Lt(){}function St(){}exports.RcsEmulator=Te;exports.WebViewRenderer=Ae;exports.default=Te;exports.getFirstMessagePreview=ze;exports.getWebViewConfig=_e;exports.isSuggestedAction=se;exports.isSuggestedReply=ge;exports.isWebViewAction=We;exports.useJsonFetch=Ie;exports.validateConversationFlow=$e;
213
+ `;let G;e[18]===Symbol.for("react.memo_cache_sentinel")?(G={borderTopColor:"transparent"},e[18]=G):G=e[18];let E;e[19]!==R?(E=s.jsx("div",{className:R,style:G}),e[19]=R,e[20]=E):E=e[20];const J=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let D;e[21]!==J?(D=s.jsx("p",{className:J,children:"Loading conversation..."}),e[21]=J,e[22]=D):D=e[22];let U;e[23]!==E||e[24]!==D?(U=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6",children:[E,D]}),e[23]=E,e[24]=D,e[25]=U):U=e[25];let H;return e[26]!==P||e[27]!==U?(H=s.jsx(P,{children:U}),e[26]=P,e[27]=U,e[28]=H):H=e[28],H}if(l&&$){let R;e[29]===Symbol.for("react.memo_cache_sentinel")?(R=s.jsx("svg",{className:"w-12 h-12 mx-auto mb-4 text-red-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z"})}),e[29]=R):R=e[29];const G=`text-lg font-medium mb-2 ${V?"text-white":"text-gray-900"}`;let E;e[30]!==G?(E=s.jsx("h3",{className:G,children:"Failed to Load"}),e[30]=G,e[31]=E):E=e[31];const J=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let D;e[32]!==$||e[33]!==J?(D=s.jsx("p",{className:J,children:$}),e[32]=$,e[33]=J,e[34]=D):D=e[34];const U=`text-xs mt-2 break-all max-w-full ${V?"text-zinc-500":"text-gray-400"}`;let H;e[35]!==l||e[36]!==U?(H=s.jsx("p",{className:U,children:l}),e[35]=l,e[36]=U,e[37]=H):H=e[37];let Q;e[38]!==E||e[39]!==D||e[40]!==H?(Q=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6 text-center",children:[R,E,D,H]}),e[38]=E,e[39]=D,e[40]=H,e[41]=Q):Q=e[41];let X;return e[42]!==P||e[43]!==Q?(X=s.jsx(P,{children:Q}),e[42]=P,e[43]=Q,e[44]=X):X=e[44],X}if(!L){const R=`w-12 h-12 mx-auto mb-4 ${V?"text-zinc-600":"text-gray-300"}`;let G;e[45]===Symbol.for("react.memo_cache_sentinel")?(G=s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M8 12h.01M12 12h.01M16 12h.01M21 12c0 4.418-4.03 8-9 8a9.863 9.863 0 01-4.255-.949L3 20l1.395-3.72C3.512 15.042 3 13.574 3 12c0-4.418 4.03-8 9-8s9 3.582 9 8z"}),e[45]=G):G=e[45];let E;e[46]!==R?(E=s.jsx("svg",{className:R,fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:G}),e[46]=R,e[47]=E):E=e[47];const J=`text-lg font-medium mb-2 ${V?"text-white":"text-gray-900"}`;let D;e[48]!==J?(D=s.jsx("h3",{className:J,children:"No Conversation Data"}),e[48]=J,e[49]=D):D=e[49];const U=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let H;e[50]===Symbol.for("react.memo_cache_sentinel")?(H=s.jsx("code",{className:"px-1 py-0.5 rounded bg-gray-100 dark:bg-zinc-800",children:"messages"}),e[50]=H):H=e[50];let Q;e[51]===Symbol.for("react.memo_cache_sentinel")?(Q=s.jsx("code",{className:"px-1 py-0.5 rounded bg-gray-100 dark:bg-zinc-800",children:"jsonUrl"}),e[51]=Q):Q=e[51];let X;e[52]!==U?(X=s.jsxs("p",{className:U,children:["Provide either"," ",H," ","or"," ",Q," ","prop"]}),e[52]=U,e[53]=X):X=e[53];let ee;e[54]!==E||e[55]!==D||e[56]!==X?(ee=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6 text-center",children:[E,D,X]}),e[54]=E,e[55]=D,e[56]=X,e[57]=ee):ee=e[57];let te;return e[58]!==P||e[59]!==ee?(te=s.jsx(P,{children:ee}),e[58]=P,e[59]=ee,e[60]=te):te=e[60],te}if(!z){let R;e[61]===Symbol.for("react.memo_cache_sentinel")?(R=s.jsx("svg",{className:"w-12 h-12 mx-auto mb-4 text-amber-500",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:s.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-3L13.732 4c-.77-1.333-2.694-1.333-3.464 0L3.34 16c-.77 1.333.192 3 1.732 3z"})}),e[61]=R):R=e[61];const G=`text-lg font-medium mb-2 ${V?"text-white":"text-gray-900"}`;let E;e[62]!==G?(E=s.jsx("h3",{className:G,children:"Invalid RBM JSON"}),e[62]=G,e[63]=E):E=e[63];const J=`text-sm ${V?"text-zinc-400":"text-gray-500"}`;let D;e[64]!==J?(D=s.jsx("p",{className:J,children:"The conversation flow structure is not valid"}),e[64]=J,e[65]=D):D=e[65];let U;e[66]!==E||e[67]!==D?(U=s.jsxs("div",{className:"flex flex-col items-center justify-center h-full p-6 text-center",children:[R,E,D]}),e[66]=E,e[67]=D,e[68]=U):U=e[68];let H;return e[69]!==P||e[70]!==U?(H=s.jsx(P,{children:U}),e[69]=P,e[70]=U,e[71]=H):H=e[71],H}let q;e[72]!==g||e[73]!==L||e[74]!==w||e[75]!==T||e[76]!==F||e[77]!==i||e[78]!==b||e[79]!==m?(q=w?s.jsx(ve,{theme:m,device:g,businessInfo:T,state:{currentMessageId:null,chatHistory:[],isTyping:!1,error:null},showSuggestions:!1,isProfileOpen:!1,toggleProfile:xt,onReply:gt,onAction:pt,webView:null,openWebView:bt,closeWebView:yt,children:s.jsx(mt,{onUnlock:_,messagePreview:F})}):s.jsx(ut,{flow:L,onUserReply:i,theme:m,device:g,businessInfo:T,showSuggestions:b}),e[72]=g,e[73]=L,e[74]=w,e[75]=T,e[76]=F,e[77]=i,e[78]=b,e[79]=m,e[80]=q):q=e[80];let K;return e[81]!==P||e[82]!==q?(K=s.jsx(P,{children:q}),e[81]=P,e[82]=q,e[83]=K):K=e[83],K});function ht(c){return!c}function xt(){}function gt(){}function pt(){}function bt(){}function yt(){}exports.RcsEmulator=Me;exports.WebViewRenderer=Se;exports.default=Me;exports.getFirstMessagePreview=Ce;exports.getWebViewConfig=je;exports.isSuggestedAction=se;exports.isSuggestedReply=ue;exports.isWebViewAction=$e;exports.useJsonFetch=_e;exports.validateConversationFlow=Ne;
218
214
  //# sourceMappingURL=rcs-emulator.cjs.js.map