release: add ErrorPopup component and export

This commit is contained in:
ci
2026-04-23 12:24:18 +00:00
commit 37540bf08e
29 changed files with 620 additions and 0 deletions

1
dist/index.umd.cjs vendored Normal file
View File

@@ -0,0 +1 @@
(function(o,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(o=typeof globalThis<"u"?globalThis:o||self,e(o.LimelightCommonWebComponents={},o.Vue))})(this,(function(o,e){"use strict";const m=["disabled"],d=((t,i)=>{const l=t.__vccOpts||t;for(const[n,r]of i)l[n]=r;return l})(e.defineComponent({__name:"LimelightButton",props:{variant:{},disabled:{type:Boolean}},setup(t){return(i,l)=>(e.openBlock(),e.createElementBlock("button",{type:"button",class:e.normalizeClass(["btn",[t.variant&&`btn--${t.variant}`,{"btn--disabled":t.disabled}]]),disabled:t.disabled},[e.renderSlot(i.$slots,"default",{},void 0,!0)],10,m))}}),[["__scopeId","data-v-e0bc8f43"]]),p={key:0,class:"fixed inset-0 z-50 flex items-center justify-center"},u={class:"relative bg-secondary border border-red-500/40 rounded-2xl p-5 max-w-sm w-[90%] shadow-xl"},k={class:"flex items-center gap-3 mb-3"},b={class:"text-white font-semibold"},g={class:"text-white/80 text-sm whitespace-pre-line"},h=e.defineComponent({__name:"ErrorPopup",props:{message:{},show:{type:Boolean},title:{}},emits:["close"],setup(t,{emit:i}){return(l,n)=>t.show&&t.message?(e.openBlock(),e.createElementBlock("div",p,[e.createElementVNode("div",{class:"absolute inset-0 bg-black/60",onClick:n[0]||(n[0]=r=>l.$emit("close"))}),e.createElementVNode("div",u,[e.createElementVNode("div",k,[n[2]||(n[2]=e.createElementVNode("div",{class:"w-10 h-10 rounded-full bg-red/15 flex items-center justify-center"},[e.createElementVNode("svg",{class:"w-5 h-5 text-red",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 9v2m0 4h.01M10.29 3.86l-8.2 14A1.5 1.5 0 003.3 20h16.4a1.5 1.5 0 001.21-2.14l-8.2-14a1.5 1.5 0 00-2.42 0z"})])],-1)),e.createElementVNode("p",b,e.toDisplayString(t.title??"Verbindungsfehler"),1)]),e.createElementVNode("p",g,e.toDisplayString(t.message),1),e.createVNode(d,{variant:"danger",class:"mt-4 w-full",onClick:n[1]||(n[1]=r=>l.$emit("close"))},{default:e.withCtx(()=>[...n[3]||(n[3]=[e.createTextVNode(" OK ",-1)])]),_:1})])])):e.createCommentVNode("",!0)}});function y(t,i){return typeof FileMaker>"u"?!1:(FileMaker.PerformScript(t,i),!0)}function M(t,i,l){return typeof FileMaker>"u"?!1:(FileMaker.PerformScriptWithOption(t,i,l),!0)}const s=new Map;let w=1;function F(t,i="",l){return new Promise((n,r)=>{if(typeof FileMaker>"u"){r({callbackId:-1,message:"FileMaker runtime not available"});return}const a=w++;s.set(a,{resolve:n,reject:r});const S={callbackId:a,parameter:i};FileMaker.PerformScript(t,JSON.stringify(S)),l!==void 0&&setTimeout(()=>{s.has(a)&&(s.delete(a),r({callbackId:a,message:`Timed out after ${l}ms`}))},l)})}function _(t,i="",l){const n=parseInt(t),r=s.get(n);r&&(s.delete(n),l?r.reject({callbackId:n,message:i}):r.resolve(i))}function c(t,i,l=10,n=0){f()?t():n>=l?i==null||i():setTimeout(()=>c(t,i,l,n+1),100)}function f(){return typeof FileMaker<"u"}o.ErrorPopup=h,o.LimelightButton=d,o.callFileMakerScript=F,o.isFileMakerEnvironment=f,o.performScript=y,o.performScriptWithOption=M,o.resolveFileMakerCallback=_,o.waitForFileMaker=c,Object.defineProperty(o,Symbol.toStringTag,{value:"Module"})}));