import{k as p,l as s,G as r,M as l,O as o,a1 as c,u as e,V as d,X as g}from"./BO9AmBA3.js";const h=["id","data-testid"],b={"data-testid":"notification-element-message",class:"ml-3 text-sm font-normal"},k=["data-dismiss-target"],w={class:"sr-only"},$=o("div",{class:"w-5 h-5 i-carbon-close"},null,-1),C=p({__name:"LayoutNotification",props:{notification:{},closeable:{type:Boolean,default:!0}},emits:["click:close"],setup(m){const i=m,f={info:"blue",success:"green",warning:"orange",danger:"red"},u={info:"information",success:"checkmark",warning:"warning-alt",danger:"close-outline"},a=s(()=>f[i.notification.type]||"blue"),y=s(()=>u[i.notification.type]||"information");return(t,n)=>t.notification.message.length>0?(r(),l("div",{key:0,id:`toast-${t.notification.id}`,"data-testid":`notification-element-${t.notification.type}`,class:"flex items-center w-full max-w-xs p-4 mb-4 text-gray-500 bg-white rounded-lg shadow dark:text-gray-400 dark:bg-gray-800",role:"alert"},[o("div",{class:c([`text-${e(a)}-500 bg-${e(a)}-100 dark:bg-${e(a)}-800 dark:text-${e(a)}-200`,"inline-flex items-center justify-center flex-shrink-0 w-8 h-8 rounded-lg"])},[o("div",{class:c(`w-5 h-5 i-carbon-${e(y)}`)},null,2)],2),o("div",b,d(t.notification.message),1),t.closeable?(r(),l("button",{key:0,"data-testid":"notification-element-button",type:"button",class:"ml-auto -mx-1.5 -my-1.5 bg-white text-gray-400 hover:text-gray-900 rounded-lg focus:ring-2 focus:ring-gray-300 p-1.5 hover:bg-gray-100 inline-flex h-8 w-8 dark:text-gray-500 dark:hover:text-white dark:bg-gray-800 dark:hover:bg-gray-700","data-dismiss-target":`toast-${t.notification.id}`,"aria-label":"Close",onClick:n[0]||(n[0]=v=>t.$emit("click:close",t.notification.id))},[o("span",w,d(t.$t("close")),1),$],8,k)):g("",!0)],8,h)):g("",!0)}});export{C as _};