PageSourceSearch

https://www.iu.de/build/assets/ContactOption-CCvVfjxj.js

js iu.de collected 2026-09-24 17:37:10 UTC 6,189 bytes, 1 lines download raw bytes

1import{i as e}from"./dist-V0wV9pPA.js";import{D as t,E as n,On as r,Zn as i,_ as a,b as o,g as s,k as c,l,mt as u,o as d,qt as f,tr as p,v as m,vn as h,y as g}from"./runtime-core.esm-bundler-DPmoNEl9.js";import{r as _}from"./pinia-Bk4qx9O9.js";import{n as v}from"./useTracking-DPVxoASA.js";import{t as y}from"./IuStoryblokComponent-DwakwXM-.js";import{n as b}from"./utils-DICGkfbo.js";import{t as x}from"./dist-C0S6jEGJ.js";import{t as S}from"./Headline-C0L232__.js";import{n as C}from"./tracking-CUlrFEbe.js";import{t as w}from"./DynamicIcon-Y9SxWFl1.js";import{t as T}from"./SynteaStore-DqmsuIS1.js";import{t as E}from"./Modal-e3RdMwV9.js";import{a as D}from"./useUsercentric-RtawsFnt.js";import{n as O}from"./SynteaButton-B4EiZSyf.js";import"./usercentricHelper-B3DdalKO.js";import{t as k}from"./useStory-CKp1jFu6.js";import{t as A}from"./UniBuddyEmbed-BRFyKFrI.js";import{r as j}from"./ElevenLabsStore-CpCVHkns.js";var M=x(`inline-flex items-center transition`,{variants:{variant:{default:`flex-row gap-4 bg-interaction-default px-6 py-4 hover:bg-interaction-hover focus-visible:ring-3 focus-visible:ring-foreground focus-visible:outline-none focus-visible:ring-inset active:ring-3 active:ring-foreground active:ring-inset`,bubble:`mb-1 ml-auto bg-white px-5 py-3 font-bold hover:text-gray-700`}},defaultVariants:{variant:`default`}}),N=x(``,{variants:{variant:{default:`size-8 shrink-0`,bubble:`ml-2 inline-block h-6 w-6 fill-current order-2`}},defaultVariants:{variant:`default`}}),P=x(``,{variants:{variant:{default:`font-bold`,bubble:`inline-block rounded bg-white uppercase order-1`}},defaultVariants:{variant:`default`}}),F=(e,t)=>({event:`customPush`,eventData:{"data-t4-eventname":`contact`,"data-t4-type":`syntea`,"data-t4-label":``,"data-t4-formstatus":``,"data-t4-position":t||`contact_bubble`,"data-t4-syntea_id":e}}),I=e=>({event:`customPush`,eventData:{"data-t4-eventname":`contact`,"data-t4-type":`syntea - close`,"data-t4-label":``,"data-t4-formstatus":``,"data-t4-position":`contact_bubble`,"data-t4-syntea_id":e}}),L=(e,t)=>({event:`customPush`,eventData:{"data-t4-eventname":`contact`,"data-t4-type":`syntea - link - ${t}`,"data-t4-label":``,"data-t4-formstatus":``,"data-t4-position":`contact_bubble`,"data-t4-syntea_id":e}}),R=()=>({event:`customPush`,eventData:{"data-t4-eventname":`contact`,"data-t4-type":`syntea - close`,"data-t4-label":``,"data-t4-formstatus":``,"data-t4-position":`attention_bubble`}}),z=e=>({event:`customPush`,eventData:{"data-t4-eventname":`contact`,"data-t4-type":`chat`,"data-t4-label":``,"data-t4-formstatus":``,"data-t4-position":e||`contact_bubble`}});function B(){let{pushEventData:e}=v(),t=s(()=>localStorage.getItem(`public_user_id`)||``);return{userId:t,pushChatOpenEvent:n=>{e(F(t.value,n))},pushChatCloseEvent:()=>{e(I(t.value))},pushChatLinkEvent:n=>{e(L(t.value,n))},pushChatAttentionBubbleCloseEvent:()=>{e(R())},pushElevenLabsChatOpenEvent:t=>{e(z(t))}}}function V(){let t=j(),{isChatConsentOpen:n}=_(t),{pushElevenLabsChatOpenEvent:r}=B(),i=e();function a(e,n){return e?e.elevenlabsAgentId?D(`ElevenLabs Conversational AI (Chatbot)`)?(t.dismissChatRequest(),t.startSession({agentId:e.elevenlabsAgentId,language:i.props.currentLocale}),r(n),!0):(t.parkChatRequest({agentId:e.elevenlabsAgentId,trackingSource:n}),!1):(console.warn("[ElevenLabs] contact option is missing the `elevenlabsAgentId` field; cannot open chat."),!1):!1}function o(){let e=t.acceptChatRequest({language:i.props.currentLocale});r(e)}function s(){t.dismissChatRequest()}return{requestElevenLabsChat:a,acceptElevenLabsChatRequest:o,dismissElevenLabsChatRequest:s,isElevenLabsConsentOpen:n}}var H=h(!1);function U(){let{createSynteaConfig:e}=O(),t=T(),{pushChatOpenEvent:n}=B();function r(r,i){if(!r)return!1;let a=r.chatConversationTemplate;return a&&typeof a!=`string`&&e(`content`in a?a.content:a),D(`Syntea`)?(t.openChat(),n(i),!0):(H.value=!0,!1)}async function i(){await t.openChat()}return{initiateSynteaChat:r,acceptSynteaConsent:i,chatConsentOpenState:H}}var W=[`href`,`data-element-type`,`target`],G={class:`flex flex-col`},K={key:0,class:`text-xs`},q=c({__name:`ContactOption`,props:{option:{},class:{type:[Boolean,null,String,Object,Array]},icon:{},elementType:{},variant:{default:`default`}},emits:[`click`,`modalOpen`],setup(e,{emit:c}){let _=e,v={email:`Mail`,phone:`Phone`,whatsapp:`MessagingWhatsapp`,chat:`TeamMeetingChat`,"chat-elevenlabs":`TeamMeetingChat`,callback:`Calendar`,address:`Pin`,"uni-buddy":`UniBuddy`},x=s(()=>_.icon??v[_.option.type]),T={email:C.MAIL,phone:C.PHONE,whatsapp:C.WHATSAPP,chat:C.CHAT,"chat-elevenlabs":C.CHAT,callback:C.CALLBACK,address:C.LOCATION,"uni-buddy":C.UNI_BUDDY},D=s(()=>_.elementType??T[_.option.type]),O=c,j=h(!1),{initiateSynteaChat:F}=U(),{requestElevenLabsChat:I}=V(),L=[`callback`,`chat`,`chat-elevenlabs`,`uni-buddy`];function R(e){let{type:t}=_.option;if(t===`chat`){e.preventDefault(),F(_.option);return}if(t===`chat-elevenlabs`){e.preventDefault(),I(_.option);return}(t===`callback`||t===`uni-buddy`)&&(e.preventDefault(),O(`modalOpen`),j.value=!0)}let{story:z}=_.option.callbackForm?k(_.option.callbackForm):{story:null};return(s,c)=>(u(),o(d,null,[a(`a`,{href:L.includes(e.option.type)?`#`:e.option.link,onClick:R,class:i(r(b)(r(M)({variant:e.variant}),_.class)),"data-element-type":D.value,target:L.includes(e.option.type)||e.option.type===`phone`?void 0:`_blank`},[t(w,{name:x.value,class:i(r(N)({variant:e.variant}))},null,8,[`name`,`class`]),a(`div`,G,[t(S,{size:`h5`,as:`span`,class:i(r(P)({variant:e.variant}))},{default:f(()=>[n(p(e.option.headline),1)]),_:1},8,[`class`]),e.option.description?(u(),o(`div`,K,p(e.option.description),1)):g(``,!0)])],10,W),t(E,{"is-open":j.value,"onUpdate:isOpen":c[0]||=e=>j.value=e,size:`xl`},{title:f(()=>[t(S,{size:`h3`,as:`span`},{default:f(()=>[n(p(e.option.type===`uni-buddy`?``:s.$t(`schedule_free_callback`)),1)]),_:1})]),default:f(()=>[e.option.type===`uni-buddy`&&e.option.link?(u(),m(A,{key:0,src:e.option.link,class:`min-h-[60vh] w-full`},null,8,[`src`])):(u(),m(l,{key:1},{default:f(()=>[r(z)?(u(),m(y,{key:0,blok:r(z).content},null,8,[`blok`])):g(``,!0)]),_:1}))]),_:1},8,[`is-open`])],64))}});
1export{B as i,U as n,V as r,q as t};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.