zen-wdg 2.2.7 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue")):"function"==typeof define&&define.amd?define(["exports","vue"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).ZenWdg={},e.Vue)}(this,function(e,t){"use strict";var o=Object.defineProperty,n=Object.defineProperties,i=Object.getOwnPropertyDescriptors,r=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable,l=(e,t,n)=>t in e?o(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,c=(e,t)=>{for(var o in t||(t={}))s.call(t,o)&&l(e,o,t[o]);if(r)for(var o of r(t))a.call(t,o)&&l(e,o,t[o]);return e},d=(e,t)=>n(e,i(t));const u=(e,t)=>{const o=e.__vccOpts||e;for(const[n,i]of t)o[n]=i;return o},p={class:"clock-container"},f={class:"clock"},m={class:"time"},h={class:"date"};const g=u({name:"ZClockWidget",data:()=>({hours:"00",minutes:"00",seconds:"00",dayOfWeek:"",day:"",month:"",year:""}),mounted(){this.updateClock(),setInterval(this.updateClock,1e3)},methods:{updateClock(){const e=new Date;this.hours=e.getHours().toString().padStart(2,"0"),this.minutes=e.getMinutes().toString().padStart(2,"0"),this.seconds=e.getSeconds().toString().padStart(2,"0"),this.dayOfWeek=this.getDayOfWeek(e.getDay()),this.day=e.getDate(),this.month=this.getMonthName(e.getMonth()),this.year=e.getFullYear()},getDayOfWeek:e=>["Domingo","Lunes","Martes","Miércoles","Jueves","Viernes","Sábado"][e],getMonthName:e=>["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"][e]}},[["render",function(e,o,n,i,r,s){return t.openBlock(),t.createElementBlock("div",p,[t.createElementVNode("div",f,[t.createElementVNode("div",m,[t.createElementVNode("span",null,t.toDisplayString(r.hours),1),o[0]||(o[0]=t.createTextVNode(":",-1)),t.createElementVNode("span",null,t.toDisplayString(r.minutes),1)]),t.createElementVNode("div",h,[t.createElementVNode("span",null,t.toDisplayString(r.dayOfWeek)+", "+t.toDisplayString(r.day)+" "+t.toDisplayString(r.month)+" "+t.toDisplayString(r.year),1)])])])}],["__scopeId","data-v-e9445086"]]),k={data:()=>({}),props:{placeholder:String,modelValue:{type:String,default:""},round:{type:Boolean,default:!1},full:{type:Boolean},rounded:{type:Boolean,default:!1}},methods:{onInput(e){this.$emit("update:modelValue",e.target.value)},onEnter(){this.$emit("enter-pressed",this.modelValue)}}},b=["placeholder","value"];const v=u(k,[["render",function(e,o,n,i,r,s){return t.openBlock(),t.createElementBlock("input",{placeholder:n.placeholder,value:n.modelValue,onInput:o[0]||(o[0]=(...e)=>s.onInput&&s.onInput(...e)),onKeydown:o[1]||(o[1]=t.withKeys((...e)=>s.onEnter&&s.onEnter(...e),["enter"])),class:t.normalizeClass([{"full-width":n.full},{round:n.round},{rounded:n.rounded}])},null,42,b)}],["__scopeId","data-v-2ad90286"]]),y=/^[a-z0-9]+(-[a-z0-9]+)*$/,w=(e,t,o,n="")=>{const i=e.split(":");if("@"===e.slice(0,1)){if(i.length<2||i.length>3)return null;n=i.shift().slice(1)}if(i.length>3||!i.length)return null;if(i.length>1){const e=i.pop(),o=i.pop(),r={provider:i.length>0?i[0]:n,prefix:o,name:e};return t&&!E(r)?null:r}const r=i[0],s=r.split("-");if(s.length>1){const e={provider:n,prefix:s.shift(),name:s.join("-")};return t&&!E(e)?null:e}if(o&&""===n){const e={provider:n,prefix:"",name:r};return t&&!E(e,o)?null:e}return null},E=(e,t)=>!!e&&!(!(t&&""===e.prefix||e.prefix)||!e.name),x=Object.freeze({left:0,top:0,width:16,height:16}),S=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),B=Object.freeze(c(c({},x),S)),C=Object.freeze(d(c({},B),{body:"",hidden:!1}));function T(e,t){const o=function(e,t){const o={};!e.hFlip!=!t.hFlip&&(o.hFlip=!0),!e.vFlip!=!t.vFlip&&(o.vFlip=!0);const n=((e.rotate||0)+(t.rotate||0))%4;return n&&(o.rotate=n),o}(e,t);for(const n in C)n in S?n in e&&!(n in o)&&(o[n]=S[n]):n in t?o[n]=t[n]:n in e&&(o[n]=e[n]);return o}function V(e,t,o){const n=e.icons,i=e.aliases||Object.create(null);let r={};function s(e){r=T(n[e]||i[e],r)}return s(t),o.forEach(s),T(e,r)}function F(e,t){const o=[];if("object"!=typeof e||"object"!=typeof e.icons)return o;e.not_found instanceof Array&&e.not_found.forEach(e=>{t(e,null),o.push(e)});const n=function(e){const t=e.icons,o=e.aliases||Object.create(null),n=Object.create(null);return Object.keys(t).concat(Object.keys(o)).forEach(function e(i){if(t[i])return n[i]=[];if(!(i in n)){n[i]=null;const t=o[i]&&o[i].parent,r=t&&e(t);r&&(n[i]=[t].concat(r))}return n[i]}),n}(e);for(const i in n){const r=n[i];r&&(t(i,V(e,i,r)),o.push(i))}return o}const N=c({provider:"",aliases:{},not_found:{}},x);function O(e,t){for(const o in t)if(o in e&&typeof e[o]!=typeof t[o])return!1;return!0}function z(e){if("object"!=typeof e||null===e)return null;const t=e;if("string"!=typeof t.prefix||!e.icons||"object"!=typeof e.icons)return null;if(!O(e,N))return null;const o=t.icons;for(const i in o){const e=o[i];if(!i||"string"!=typeof e.body||!O(e,C))return null}const n=t.aliases||Object.create(null);for(const i in n){const e=n[i],t=e.parent;if(!i||"string"!=typeof t||!o[t]&&!n[t]||!O(e,C))return null}return t}const j=Object.create(null);function I(e,t){const o=j[e]||(j[e]=Object.create(null));return o[t]||(o[t]=function(e,t){return{provider:e,prefix:t,icons:Object.create(null),missing:new Set}}(e,t))}function D(e,t){return z(t)?F(t,(t,o)=>{o?e.icons[t]=o:e.missing.add(t)}):[]}let A=!1;function M(e){return"boolean"==typeof e&&(A=e),A}function P(e,t){const o=w(e,!0,A);if(!o)return!1;const n=I(o.provider,o.prefix);return t?function(e,t,o){try{if("string"==typeof o.body)return e.icons[t]=c({},o),!0}catch(n){}return!1}(n,o.name,t):(n.missing.add(o.name),!0)}const _=Object.freeze({width:null,height:null}),L=Object.freeze(c(c({},_),S)),W=/(-?[0-9.]*[0-9]+[0-9.]*)/g,q=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function U(e,t,o){if(1===t)return e;if(o=o||100,"number"==typeof e)return Math.ceil(e*t*o)/o;if("string"!=typeof e)return e;const n=e.split(W);if(null===n||!n.length)return e;const i=[];let r=n.shift(),s=q.test(r);for(;;){if(s){const e=parseFloat(r);isNaN(e)?i.push(r):i.push(Math.ceil(e*t*o)/o)}else i.push(r);if(r=n.shift(),void 0===r)return i.join("");s=!s}}const H=/\sid="(\S+)"/g,$="IconifyId"+Date.now().toString(16)+(16777216*Math.random()|0).toString(16);let R=0;const J=Object.create(null);function Q(e){return J[e]||J[""]}function Z(e){let t;if("string"==typeof e.resources)t=[e.resources];else if(t=e.resources,!(t instanceof Array&&t.length))return null;return{resources:t,path:e.path||"/",maxURL:e.maxURL||500,rotate:e.rotate||750,timeout:e.timeout||5e3,random:!0===e.random,index:e.index||0,dataAfterTimeout:!1!==e.dataAfterTimeout}}const G=Object.create(null),K=["https://api.simplesvg.com","https://api.unisvg.com"],Y=[];for(;K.length>0;)1===K.length||Math.random()>.5?Y.push(K.shift()):Y.push(K.pop());function X(e,t){const o=Z(t);return null!==o&&(G[e]=o,!0)}function ee(e){return G[e]}G[""]=Z({resources:["https://api.iconify.design"].concat(Y)});let te=(()=>{let e;try{if(e=fetch,"function"==typeof e)return e}catch(t){}})();const oe={prepare:(e,t,o)=>{const n=[],i=function(e,t){const o=ee(e);if(!o)return 0;let n;if(o.maxURL){let e=0;o.resources.forEach(t=>{const o=t;e=Math.max(e,o.length)});const i=t+".json?icons=";n=o.maxURL-e-o.path.length-i.length}else n=0;return n}(e,t),r="icons";let s={type:r,provider:e,prefix:t,icons:[]},a=0;return o.forEach((o,l)=>{a+=o.length+1,a>=i&&l>0&&(n.push(s),s={type:r,provider:e,prefix:t,icons:[]},a=o.length),s.icons.push(o)}),n.push(s),n},send:(e,t,o)=>{if(!te)return void o("abort",424);let n=function(e){if("string"==typeof e){const t=ee(e);if(t)return t.path}return"/"}(t.provider);switch(t.type){case"icons":{const e=t.prefix,o=t.icons.join(",");n+=e+".json?"+new URLSearchParams({icons:o}).toString();break}case"custom":{const e=t.uri;n+="/"===e.slice(0,1)?e.slice(1):e;break}default:return void o("abort",400)}let i=503;te(e+n).then(e=>{const t=e.status;if(200===t)return i=501,e.json();setTimeout(()=>{o(function(e){return 404===e}(t)?"abort":"next",t)})}).then(e=>{"object"==typeof e&&null!==e?setTimeout(()=>{o("success",e)}):setTimeout(()=>{404===e?o("abort",e):o("next",i)})}).catch(()=>{o("next",i)})}};function ne(e,t){e.forEach(e=>{const o=e.loaderCallbacks;o&&(e.loaderCallbacks=o.filter(e=>e.id!==t))})}let ie=0;var re={resources:[],index:0,timeout:2e3,rotate:750,random:!1,dataAfterTimeout:!1};function se(e,t,o,n){const i=e.resources.length,r=e.random?Math.floor(Math.random()*i):e.index;let s;if(e.random){let t=e.resources.slice(0);for(s=[];t.length>1;){const e=Math.floor(Math.random()*t.length);s.push(t[e]),t=t.slice(0,e).concat(t.slice(e+1))}s=s.concat(t)}else s=e.resources.slice(r).concat(e.resources.slice(0,r));const a=Date.now();let l,c="pending",d=0,u=null,p=[],f=[];function m(){u&&(clearTimeout(u),u=null)}function h(){"pending"===c&&(c="aborted"),m(),p.forEach(e=>{"pending"===e.status&&(e.status="aborted")}),p=[]}function g(e,t){t&&(f=[]),"function"==typeof e&&f.push(e)}function k(){c="failed",f.forEach(e=>{e(void 0,l)})}function b(){p.forEach(e=>{"pending"===e.status&&(e.status="aborted")}),p=[]}function v(){if("pending"!==c)return;m();const n=s.shift();if(void 0===n)return p.length?void(u=setTimeout(()=>{m(),"pending"===c&&(b(),k())},e.timeout)):void k();const i={status:"pending",resource:n,callback:(t,o)=>{!function(t,o,n){const i="success"!==o;switch(p=p.filter(e=>e!==t),c){case"pending":break;case"failed":if(i||!e.dataAfterTimeout)return;break;default:return}if("abort"===o)return l=n,void k();if(i)return l=n,void(p.length||(s.length?v():k()));if(m(),b(),!e.random){const o=e.resources.indexOf(t.resource);-1!==o&&o!==e.index&&(e.index=o)}c="completed",f.forEach(e=>{e(n)})}(i,t,o)}};p.push(i),d++,u=setTimeout(v,e.rotate),o(n,t,i.callback)}return"function"==typeof n&&f.push(n),setTimeout(v),function(){return{startTime:a,payload:t,status:c,queriesSent:d,queriesPending:p.length,subscribe:g,abort:h}}}function ae(e){const t=c(c({},re),e);let o=[];function n(){o=o.filter(e=>"pending"===e().status)}return{query:function(e,i,r){const s=se(t,e,i,(e,t)=>{n(),r&&r(e,t)});return o.push(s),s},find:function(e){return o.find(t=>e(t))||null},setIndex:e=>{t.index=e},getIndex:()=>t.index,cleanup:n}}function le(){}const ce=Object.create(null);function de(e,t,o){let n,i;if("string"==typeof e){const t=Q(e);if(!t)return o(void 0,424),le;i=t.send;const r=function(e){if(!ce[e]){const t=ee(e);if(!t)return;const o={config:t,redundancy:ae(t)};ce[e]=o}return ce[e]}(e);r&&(n=r.redundancy)}else{const t=Z(e);if(t){n=ae(t);const o=Q(e.resources?e.resources[0]:"");o&&(i=o.send)}}return n&&i?n.query(t,i,o)().abort:(o(void 0,424),le)}function ue(){}function pe(e){e.iconsLoaderFlag||(e.iconsLoaderFlag=!0,setTimeout(()=>{e.iconsLoaderFlag=!1,function(e){e.pendingCallbacksFlag||(e.pendingCallbacksFlag=!0,setTimeout(()=>{e.pendingCallbacksFlag=!1;const t=e.loaderCallbacks?e.loaderCallbacks.slice(0):[];if(!t.length)return;let o=!1;const n=e.provider,i=e.prefix;t.forEach(t=>{const r=t.icons,s=r.pending.length;r.pending=r.pending.filter(t=>{if(t.prefix!==i)return!0;const s=t.name;if(e.icons[s])r.loaded.push({provider:n,prefix:i,name:s});else{if(!e.missing.has(s))return o=!0,!0;r.missing.push({provider:n,prefix:i,name:s})}return!1}),r.pending.length!==s&&(o||ne([e],t.id),t.callback(r.loaded.slice(0),r.missing.slice(0),r.pending.slice(0),t.abort))})}))}(e)}))}function fe(e,t,o){function n(){const o=e.pendingIcons;t.forEach(t=>{o&&o.delete(t),e.icons[t]||e.missing.add(t)})}if(o&&"object"==typeof o)try{if(!D(e,o).length)return void n()}catch(i){console.error(i)}n(),pe(e)}function me(e,t){e instanceof Promise?e.then(e=>{t(e)}).catch(()=>{t(null)}):t(e)}function he(e,t){e.iconsToLoad?e.iconsToLoad=e.iconsToLoad.concat(t).sort():e.iconsToLoad=t,e.iconsQueueFlag||(e.iconsQueueFlag=!0,setTimeout(()=>{e.iconsQueueFlag=!1;const{provider:t,prefix:o}=e,n=e.iconsToLoad;if(delete e.iconsToLoad,!n||!n.length)return;const i=e.loadIcon;if(e.loadIcons&&(n.length>1||!i))return void me(e.loadIcons(n,o,t),t=>{fe(e,n,t)});if(i)return void n.forEach(n=>{me(i(n,o,t),t=>{fe(e,[n],t?{prefix:o,icons:{[n]:t}}:null)})});const{valid:r,invalid:s}=function(e){const t=[],o=[];return e.forEach(e=>{(e.match(y)?t:o).push(e)}),{valid:t,invalid:o}}(n);if(s.length&&fe(e,s,null),!r.length)return;const a=o.match(y)?Q(t):null;if(!a)return void fe(e,r,null);a.prepare(t,o,r).forEach(o=>{de(t,o,t=>{fe(e,o.icons,t)})})}))}const ge=(e,t)=>{const o=function(e){const t={loaded:[],missing:[],pending:[]},o=Object.create(null);e.sort((e,t)=>e.provider!==t.provider?e.provider.localeCompare(t.provider):e.prefix!==t.prefix?e.prefix.localeCompare(t.prefix):e.name.localeCompare(t.name));let n={provider:"",prefix:"",name:""};return e.forEach(e=>{if(n.name===e.name&&n.prefix===e.prefix&&n.provider===e.provider)return;n=e;const i=e.provider,r=e.prefix,s=e.name,a=o[i]||(o[i]=Object.create(null)),l=a[r]||(a[r]=I(i,r));let c;c=s in l.icons?t.loaded:""===r||l.missing.has(s)?t.missing:t.pending;const d={provider:i,prefix:r,name:s};c.push(d)}),t}(function(e,t=!0,o=!1){const n=[];return e.forEach(e=>{const i="string"==typeof e?w(e,t,o):e;i&&n.push(i)}),n}(e,!0,M()));if(!o.pending.length){let e=!0;return t&&setTimeout(()=>{e&&t(o.loaded,o.missing,o.pending,ue)}),()=>{e=!1}}const n=Object.create(null),i=[];let r,s;return o.pending.forEach(e=>{const{provider:t,prefix:o}=e;if(o===s&&t===r)return;r=t,s=o,i.push(I(t,o));const a=n[t]||(n[t]=Object.create(null));a[o]||(a[o]=[])}),o.pending.forEach(e=>{const{provider:t,prefix:o,name:i}=e,r=I(t,o),s=r.pendingIcons||(r.pendingIcons=new Set);s.has(i)||(s.add(i),n[t][o].push(i))}),i.forEach(e=>{const t=n[e.provider][e.prefix];t.length&&he(e,t)}),t?function(e,t,o){const n=ie++,i=ne.bind(null,o,n);if(!t.pending.length)return i;const r={id:n,icons:t,callback:e,abort:i};return o.forEach(e=>{(e.loaderCallbacks||(e.loaderCallbacks=[])).push(r)}),i}(t,o,i):ue};const ke=/[\s,]+/;function be(e,t){t.split(ke).forEach(t=>{switch(t.trim()){case"horizontal":e.hFlip=!0;break;case"vertical":e.vFlip=!0}})}function ve(e,t=0){const o=e.replace(/^-?[0-9.]*/,"");function n(e){for(;e<0;)e+=4;return e%4}if(""===o){const t=parseInt(e);return isNaN(t)?0:n(t)}if(o!==e){let t=0;switch(o){case"%":t=25;break;case"deg":t=90}if(t){let i=parseFloat(e.slice(0,e.length-o.length));return isNaN(i)?0:(i/=t,i%1==0?n(i):0)}}return t}const ye=d(c({},L),{inline:!1}),we={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":!0,role:"img"},Ee={display:"inline-block"},xe={backgroundColor:"currentColor"},Se={backgroundColor:"transparent"},Be={Image:"var(--svg)",Repeat:"no-repeat",Size:"100% 100%"},Ce={webkitMask:xe,mask:xe,background:Se};for(const wt in Ce){const e=Ce[wt];for(const t in Be)e[wt+t]=Be[t]}const Te={};function Ve(e){return e+(e.match(/^[-0-9.]+$/)?"px":"")}["horizontal","vertical"].forEach(e=>{const t=e.slice(0,1)+"Flip";Te[e+"-flip"]=t,Te[e.slice(0,1)+"-flip"]=t,Te[e+"Flip"]=t});const Fe=(e,o)=>{const n=function(e,t){const o=c({},e);for(const n in t){const e=t[n],i=typeof e;n in _?(null===e||e&&("string"===i||"number"===i))&&(o[n]=e):i===typeof o[n]&&(o[n]="rotate"===n?e%4:e)}return o}(ye,o),i=c({},we),r=o.mode||"svg",s={},a=o.style,l="object"!=typeof a||a instanceof Array?{}:a;for(let t in o){const e=o[t];if(void 0!==e)switch(t){case"icon":case"style":case"onLoad":case"mode":case"ssr":break;case"inline":case"hFlip":case"vFlip":n[t]=!0===e||"true"===e||1===e;break;case"flip":"string"==typeof e&&be(n,e);break;case"color":s.color=e;break;case"rotate":"string"==typeof e?n[t]=ve(e):"number"==typeof e&&(n[t]=e);break;case"ariaHidden":case"aria-hidden":!0!==e&&"true"!==e&&delete i["aria-hidden"];break;default:{const o=Te[t];o?!0!==e&&"true"!==e&&1!==e||(n[o]=!0):void 0===ye[t]&&(i[t]=e)}}}const u=function(e,t){const o=c(c({},B),e),n=c(c({},L),t),i={left:o.left,top:o.top,width:o.width,height:o.height};let r=o.body;[o,n].forEach(e=>{const t=[],o=e.hFlip,n=e.vFlip;let s,a=e.rotate;switch(o?n?a+=2:(t.push("translate("+(i.width+i.left).toString()+" "+(0-i.top).toString()+")"),t.push("scale(-1 1)"),i.top=i.left=0):n&&(t.push("translate("+(0-i.left).toString()+" "+(i.height+i.top).toString()+")"),t.push("scale(1 -1)"),i.top=i.left=0),a<0&&(a-=4*Math.floor(a/4)),a%=4,a){case 1:s=i.height/2+i.top,t.unshift("rotate(90 "+s.toString()+" "+s.toString()+")");break;case 2:t.unshift("rotate(180 "+(i.width/2+i.left).toString()+" "+(i.height/2+i.top).toString()+")");break;case 3:s=i.width/2+i.left,t.unshift("rotate(-90 "+s.toString()+" "+s.toString()+")")}a%2==1&&(i.left!==i.top&&(s=i.left,i.left=i.top,i.top=s),i.width!==i.height&&(s=i.width,i.width=i.height,i.height=s)),t.length&&(r=function(e,t,o){const n=function(e,t="defs"){let o="";const n=e.indexOf("<"+t);for(;n>=0;){const i=e.indexOf(">",n),r=e.indexOf("</"+t);if(-1===i||-1===r)break;const s=e.indexOf(">",r);if(-1===s)break;o+=e.slice(i+1,r).trim(),e=e.slice(0,n).trim()+e.slice(s+1)}return{defs:o,content:e}}(e);return i=n.defs,r=t+n.content+o,i?"<defs>"+i+"</defs>"+r:r;var i,r}(r,'<g transform="'+t.join(" ")+'">',"</g>"))});const s=n.width,a=n.height,l=i.width,d=i.height;let u,p;null===s?(p=null===a?"1em":"auto"===a?d:a,u=U(p,l/d)):(u="auto"===s?l:s,p=null===a?U(u,d/l):"auto"===a?d:a);const f={},m=(e,t)=>{(e=>"unset"===e||"undefined"===e||"none"===e)(t)||(f[e]=t.toString())};m("width",u),m("height",p);const h=[i.left,i.top,l,d];return f.viewBox=h.join(" "),{attributes:f,viewBox:h,body:r}}(e,n),p=u.attributes;if(n.inline&&(s.verticalAlign="-0.125em"),"svg"===r){i.style=c(c({},s),l),Object.assign(i,p);let e=0,n=o.id;return"string"==typeof n&&(n=n.replace(/-/g,"_")),i.innerHTML=function(e,t=$){const o=[];let n;for(;n=H.exec(e);)o.push(n[1]);if(!o.length)return e;const i="suffix"+(16777216*Math.random()|Date.now()).toString(16);return o.forEach(o=>{const n="function"==typeof t?t(o):t+(R++).toString(),r=o.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+r+')([")]|\\.[a-z])',"g"),"$1"+n+i+"$3")}),e=e.replace(new RegExp(i,"g"),"")}(u.body,n?()=>n+"ID"+e++:"iconifyVue"),t.h("svg",i)}const{body:f,width:m,height:h}=e,g="mask"===r||"bg"!==r&&-1!==f.indexOf("currentColor"),k=function(e,t){let o=-1===e.indexOf("xlink:")?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const n in t)o+=" "+n+'="'+t[n]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+o+">"+e+"</svg>"}(f,d(c({},p),{width:m+"",height:h+""}));var b;return i.style=c(c(c(d(c({},s),{"--svg":(b=k,'url("'+function(e){return"data:image/svg+xml,"+function(e){return e.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}(e)}(b)+'")'),width:Ve(p.width),height:Ve(p.height)}),Ee),g?xe:Se),l),t.h("span",i)};var Ne;if(M(!0),Ne=oe,J[""]=Ne,"undefined"!=typeof document&&"undefined"!=typeof window){const e=window;if(void 0!==e.IconifyPreload){const t=e.IconifyPreload,o="Invalid IconifyPreload syntax.";"object"==typeof t&&null!==t&&(t instanceof Array?t:[t]).forEach(e=>{try{("object"!=typeof e||null===e||e instanceof Array||"object"!=typeof e.icons||"string"!=typeof e.prefix||!function(e,t){if("object"!=typeof e)return!1;if("string"!=typeof t&&(t=e.provider||""),A&&!t&&!e.prefix){let t=!1;return z(e)&&(e.prefix="",F(e,(e,o)=>{P(e,o)&&(t=!0)})),t}const o=e.prefix;return!!E({prefix:o,name:"a"})&&!!D(I(t,o),e)}(e))&&console.error(o)}catch(t){console.error(o)}})}if(void 0!==e.IconifyProviders){const t=e.IconifyProviders;if("object"==typeof t&&null!==t)for(let e in t){const o="IconifyProviders["+e+"] is invalid.";try{const n=t[e];if("object"!=typeof n||!n||void 0===n.resources)continue;X(e,n)||console.error(o)}catch(yt){console.error(o)}}}}const Oe=d(c({},B),{body:""});const ze=u({data:()=>({}),components:{Icon:t.defineComponent((e,{emit:o})=>{const n=t.ref(null);function i(){var e,t;n.value&&(null==(t=(e=n.value).abort)||t.call(e),n.value=null)}const r=t.ref(!!e.ssr),s=t.ref(""),a=t.shallowRef(null);function l(){const r=e.icon;if("object"==typeof r&&null!==r&&"string"==typeof r.body)return s.value="",{data:r};let a;if("string"!=typeof r||null===(a=w(r,!1,!0)))return null;let l=function(e){const t="string"==typeof e?w(e,!0,A):e;if(t){const e=I(t.provider,t.prefix),o=t.name;return e.icons[o]||(e.missing.has(o)?null:void 0)}}(a);if(!l){const e=n.value;return e&&e.name===r||(n.value=null===l?{name:r}:{name:r,abort:ge([a],u)}),null}i(),s.value!==r&&(s.value=r,t.nextTick(()=>{o("load",r)}));const c=e.customise;if(c){l=Object.assign({},l);const e=c(l.body,a.name,a.prefix,a.provider);"string"==typeof e&&(l.body=e)}const d=["iconify"];return""!==a.prefix&&d.push("iconify--"+a.prefix),""!==a.provider&&d.push("iconify--"+a.provider),{data:l,classes:d}}function u(){var e;const t=l();t?t.data!==(null==(e=a.value)?void 0:e.data)&&(a.value=t):a.value=null}return r.value?u():t.onMounted(()=>{r.value=!0,u()}),t.watch(()=>e.icon,u),t.onUnmounted(i),()=>{const t=a.value;if(!t)return Fe(Oe,e);let o=e;return t.classes&&(o=d(c({},e),{class:t.classes.join(" ")})),Fe(c(c({},B),t.data),o)}},{props:["icon","mode","ssr","width","height","style","color","inline","rotate","hFlip","horizontalFlip","vFlip","verticalFlip","flip","id","ariaHidden","customise","title"],emits:["load"]})},props:{title:{type:String,required:!1},bound:{type:Boolean,default:!1},bounded:{type:Boolean,default:!1},flat:{type:Boolean,default:!1},iconLeft:{type:Boolean,required:!1,default:!1},iconRight:{type:Boolean,default:!1},icon:{type:String},size:{type:String},iconSize:{type:String},wFull:{type:Boolean,default:!1},noBg:{type:Boolean,default:!1},color:String},methods:{}},[["render",function(e,o,n,i,r,s){const a=t.resolveComponent("Icon");return t.openBlock(),t.createElementBlock("button",{class:t.normalizeClass([{flat:n.flat},{bound:n.bound},{bounded:n.bounded},{"w-full":n.wFull},{transparent:n.noBg}]),style:t.normalizeStyle([{"font-size":n.size},{color:n.color}])},[n.iconLeft?(t.openBlock(),t.createBlock(a,{key:0,icon:n.icon,style:t.normalizeStyle({"font-size":n.iconSize})},null,8,["icon","style"])):t.createCommentVNode("",!0),t.createTextVNode(" "+t.toDisplayString(n.title)+" ",1),n.icon&&!n.iconLeft?(t.openBlock(),t.createBlock(a,{key:1,icon:n.icon,width:n.iconSize,height:n.iconSize},null,8,["icon","width","height"])):t.createCommentVNode("",!0)],6)}],["__scopeId","data-v-10678914"]]),je={name:"Dropdown",props:{modelValue:Object,options:{type:Array,required:!0},placeholder:{type:String,default:"Seleccionar..."}},data:()=>({isOpen:!1}),created(){console.log(this.options)},computed:{selected(){return this.modelValue}},methods:{toggleDropdown(){this.isOpen=!this.isOpen},selectItem(e){this.$emit("update:modelValue",e),this.isOpen=!1,console.log(e)},selectOption(e){this.selectedOption=e,this.isOpen=!1,this.$emit("update:modelValue",e),this.$emit("change",e)},handleClickOutside(e){this.$refs.dropdown.contains(e.target)||(this.isOpen=!1)}},mounted(){document.addEventListener("click",this.handleClickOutside)},beforeUnmount(){document.removeEventListener("click",this.handleClickOutside)}},Ie={class:"container",ref:"dropdown"},De={key:0},Ae=["src"],Me={key:1,class:"placeholder"},Pe={key:0,class:"column list"},_e=["onClick"],Le={key:0},We=["src"],qe={key:1};const Ue=u(je,[["render",function(e,o,n,i,r,s){return t.openBlock(),t.createElementBlock("div",Ie,[t.createElementVNode("div",{class:"row select",onClick:o[0]||(o[0]=(...e)=>s.toggleDropdown&&s.toggleDropdown(...e))},[s.selected?(t.openBlock(),t.createElementBlock("span",De,[s.selected.logo?(t.openBlock(),t.createElementBlock("img",{key:0,src:s.selected.logo,class:"logo"},null,8,Ae)):t.createCommentVNode("",!0)])):(t.openBlock(),t.createElementBlock("span",Me,"Selecciona una opción"))]),r.isOpen?(t.openBlock(),t.createElementBlock("div",Pe,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(n.options,(e,o)=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["item row",{active:e.id==s.selected.id}]),onClick:t=>s.selectItem(e)},[e.logo?(t.openBlock(),t.createElementBlock("span",Le,[t.createElementVNode("img",{src:e.logo,class:"logo"},null,8,We)])):t.createCommentVNode("",!0),e.label?(t.openBlock(),t.createElementBlock("span",qe,t.toDisplayString(e.label),1)):t.createCommentVNode("",!0)],10,_e))),256))])):t.createCommentVNode("",!0)],512)}],["__scopeId","data-v-d1389195"]]),He={class:"container-search"},$e={class:"search"};const Re=u({name:"ZSearchWidget",data:()=>({text:"",engines:[{id:1,logo:"https://s1.qwant.com/thumbr/474x474/b/c/eae6b919559217567ef067dec4aa1e425d560667e5b8e51333bea1b60f4de7/OIP.G3kcQIn5w4kJtUilFbWaigHaHa.jpg?u=https%3A%2F%2Fthf.bing.com%2Fth%2Fid%2FOIP.G3kcQIn5w4kJtUilFbWaigHaHa%3Fr%3D0%26cb%3Dthfc1%26pid%3DApi&q=0&b=1&p=0&a=0",label:"Qwant",search:"https://www.qwant.com/?l=es&q="},{id:2,logo:"https://astian.org/wp-content/uploads/2025/06/favicon-1.png",label:"MidoriGO",search:"https://astiango.co/?q="}],engine:{id:1,logo:"https://s1.qwant.com/thumbr/474x474/b/c/eae6b919559217567ef067dec4aa1e425d560667e5b8e51333bea1b60f4de7/OIP.G3kcQIn5w4kJtUilFbWaigHaHa.jpg?u=https%3A%2F%2Fthf.bing.com%2Fth%2Fid%2FOIP.G3kcQIn5w4kJtUilFbWaigHaHa%3Fr%3D0%26cb%3Dthfc1%26pid%3DApi&q=0&b=1&p=0&a=0",label:"Qwant",search:"https://www.qwant.com/?l=es&q="},urls:{url:"https://www.qwant.com/?l=es&q=facebook+login&t=web"}}),props:{searchTarget:{type:String,require:!1,default:"Self Tab"},logo:{type:String,require:!1}},components:{Input:v,Button:ze,Dropdown:Ue},methods:{search(){console.log(this.engine.search);const e=`${this.engine.search}${this.text}`;"New Tab"==this.searchTarget?(chrome.tabs.create({url:e}),this.text=""):"Self Tab"==this.searchTarget&&chrome.tabs.update({url:e})}}},[["render",function(e,o,n,i,r,s){const a=t.resolveComponent("Dropdown"),l=t.resolveComponent("Input"),c=t.resolveComponent("Button");return t.openBlock(),t.createElementBlock("div",He,[t.createElementVNode("div",$e,[t.createElementVNode("div",null,[t.createVNode(a,{options:r.engines,modelValue:r.engine,"onUpdate:modelValue":o[0]||(o[0]=e=>r.engine=e)},null,8,["options","modelValue"])]),t.createVNode(l,{placeholder:"Search something",full:"",class:"bg-glass",modelValue:r.text,"onUpdate:modelValue":o[1]||(o[1]=e=>r.text=e),onEnterPressed:o[2]||(o[2]=e=>s.search())},null,8,["modelValue"]),t.createVNode(c,{icon:"material-symbols-light:search-rounded",size:"25px",flat:"",class:"text-color",onClick:o[3]||(o[3]=e=>s.search())})])])}],["__scopeId","data-v-b93f704d"]]),Je={class:"todo-widget"},Qe={class:"task-section"},Ze={key:0,class:"empty"},Ge={class:"actions"},Ke=["onClick"],Ye=["onClick"],Xe={class:"task-section completed"},et={key:0,class:"empty"},tt={class:"done"},ot=["onClick"];const nt=u({name:"ZTodoWidget",data:()=>({newTask:"",pendingTasks:[],completedTasks:[]}),methods:{addTask(){this.newTask.trim()&&(this.pendingTasks.push({text:this.newTask.trim()}),this.newTask="")},completeTask(e){const t=this.pendingTasks.splice(e,1)[0];this.completedTasks.push(t)},deleteTask(e){this.pendingTasks.splice(e,1)},deleteCompleted(e){this.completedTasks.splice(e,1)}}},[["render",function(e,o,n,i,r,s){return t.openBlock(),t.createElementBlock("div",Je,[o[5]||(o[5]=t.createElementVNode("h2",{class:"title"},"📝 Mis Tareas",-1)),t.createElementVNode("form",{onSubmit:o[1]||(o[1]=t.withModifiers((...e)=>s.addTask&&s.addTask(...e),["prevent"])),class:"todo-form"},[t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":o[0]||(o[0]=e=>r.newTask=e),type:"text",placeholder:"Escribe una nueva tarea..."},null,512),[[t.vModelText,r.newTask]]),o[2]||(o[2]=t.createElementVNode("button",{type:"submit"},"Agregar",-1))],32),t.createElementVNode("div",Qe,[o[3]||(o[3]=t.createElementVNode("h3",null,"Tareas Pendientes",-1)),0===r.pendingTasks.length?(t.openBlock(),t.createElementBlock("div",Ze,"Sin tareas.")):t.createCommentVNode("",!0),t.createElementVNode("ul",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.pendingTasks,(e,o)=>(t.openBlock(),t.createElementBlock("li",{key:o},[t.createElementVNode("span",null,t.toDisplayString(e.text),1),t.createElementVNode("div",Ge,[t.createElementVNode("button",{onClick:e=>s.completeTask(o)},"✔️",8,Ke),t.createElementVNode("button",{onClick:e=>s.deleteTask(o)},"🗑️",8,Ye)])]))),128))])]),t.createElementVNode("div",Xe,[o[4]||(o[4]=t.createElementVNode("h3",null,"Completadas",-1)),0===r.completedTasks.length?(t.openBlock(),t.createElementBlock("div",et,"Ninguna aún.")):t.createCommentVNode("",!0),t.createElementVNode("ul",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.completedTasks,(e,o)=>(t.openBlock(),t.createElementBlock("li",{key:"c"+o},[t.createElementVNode("span",tt,t.toDisplayString(e.text),1),t.createElementVNode("button",{onClick:e=>s.deleteCompleted(o)},"❌",8,ot)]))),128))])])])}],["__scopeId","data-v-3560194d"]]),it={name:"ZMarkedWidget",props:{theme:{type:String,default:"light"},small:{type:Boolean,default:!1},categories:{type:Array,default:()=>["Personal","Work","Study"]},open:{type:String,default:"Self Tab"},useStorage:{type:Boolean,default:!1}},data(){const e="bookmark_manager_state",t={Personal:[{title:"Astian",url:"https://astian.org/",logo:"https://www.google.com/s2/favicons?domain=astian.org&sz=64"},{title:"Amazon",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM9HD56Q0VD2QZXQ2AR505&url=https%3A%2F%2Famazon.com",logo:"https://www.google.com/s2/favicons?domain=amazon.com&sz=64"},{title:"Avast",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Favast.com%2F",logo:"https://www.google.com/s2/favicons?domain=avast.com&sz=64"},{title:"Youtube",url:"https://youtube.com",logo:"https://www.google.com/s2/favicons?domain=youtube.com&sz=64"},{title:"Instagram",url:"https://instagram.com",logo:"https://www.google.com/s2/favicons?domain=instagram.com&sz=64"},{title:"Wish.com",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fwish.com",logo:"https://www.google.com/s2/favicons?domain=wish.com&sz=64"},{title:"Prime",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fprimevideo.com",logo:"https://www.google.com/s2/favicons?domain=primevideo.com&sz=64"},{title:"Shein",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fshein.com",logo:"https://www.google.com/s2/favicons?domain=shein.com&sz=64"}],Work:[{title:"GitHub",url:"https://github.com",logo:"https://www.google.com/s2/favicons?domain=github.com&sz=64"},{title:"Notion",url:"https://notion.so",logo:"https://www.google.com/s2/favicons?domain=notion.so&sz=64"}],Study:[{title:"MDN Web Docs",url:"https://developer.mozilla.org",logo:"https://www.google.com/s2/favicons?domain=mozilla.org&sz=64"},{title:"FreeCodeCamp",url:"https://freecodecamp.org",logo:"https://www.google.com/s2/favicons?domain=freecodecamp.org&sz=64"},{title:"Udemy",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fudemy.com%2F",logo:"https://www.google.com/s2/favicons?domain=udemy.com&sz=64"}]};return{STORAGE_KEY:e,bookmarks:this.useStorage&&JSON.parse(localStorage.getItem(e))||t,activeTab:"Personal"}},computed:{currentBookmarks(){return this.bookmarks[this.activeTab]||[]}},methods:{saveState(){this.useStorage&&localStorage.setItem(this.STORAGE_KEY,JSON.stringify(this.bookmarks))},setActiveTab(e){this.activeTab=e},openLink(e){"self"===this.open?window.location.href=e:window.open(e,"_blank")},deleteBookmark(e){const t=this.bookmarks[this.activeTab][e];confirm(`¿Estás seguro de eliminar ${t.title}?`)&&(this.bookmarks[this.activeTab].splice(e,1),this.saveState())},editBookmark(e){const t=this.bookmarks[this.activeTab][e],o=prompt("Nuevo título:",t.title);if(null===o)return;const n=prompt("Nueva URL:",t.url);null!==n&&(t.title=o,t.url=n,t.logo=`https://www.google.com/s2/favicons?domain=${new URL(n).hostname}&sz=64`,this.saveState())},addBookmarkPrompt(){const e=prompt("Nombre del marcador:");if(!e)return;const t=prompt("URL del marcador:");if(!t)return;const o=`https://www.google.com/s2/favicons?domain=${new URL(t).hostname}&sz=64`;this.bookmarks[this.activeTab].push({title:e,url:t,logo:o}),this.saveState()},onImageError(e,t){const o=e.target;o.style.display="none";const n=o.parentNode;n.style.backgroundColor="#066D5A",n.textContent=t.charAt(0).toUpperCase()}},watch:{bookmarks:{handler(){this.saveState()},deep:!0}}},rt={class:"container-marked"},st=["onClick"],at={class:"grid"},lt={class:"option-app"},ct=["onClick"],dt=["onClick"],ut=["href","target"],pt={class:"column"},ft={class:"logo-container"},mt=["src","alt","onError"];const ht=u(it,[["render",function(e,o,n,i,r,s){return t.openBlock(),t.createElementBlock("div",rt,[t.createElementVNode("div",{class:t.normalizeClass(["tabs",["dark"==n.theme?"dark":"light"]])},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(n.categories,e=>(t.openBlock(),t.createElementBlock("div",{key:e,class:"container-tab"},[t.createElementVNode("button",{class:t.normalizeClass(["tab",{active:e===r.activeTab}]),onClick:t=>s.setActiveTab(e)},t.toDisplayString(e),11,st)]))),128))],2),t.createElementVNode("div",at,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(s.currentBookmarks,(e,o)=>(t.openBlock(),t.createElementBlock("div",{key:o,class:t.normalizeClass(["card",n.small?"small":""])},[t.createElementVNode("div",lt,[t.createElementVNode("button",{class:"edit-app",onClick:t.withModifiers(e=>s.editBookmark(o),["prevent"])},"✏️",8,ct),t.createElementVNode("button",{class:"delete-app",onClick:t.withModifiers(e=>s.deleteBookmark(o),["prevent"])},"🗑️",8,dt)]),t.createElementVNode("a",{href:e.url,class:t.normalizeClass(["card-link","dark"==n.theme?"dark":"light"]),target:"Self Tab"==n.open?"_self":"_blank"},[t.createElementVNode("div",pt,[t.createElementVNode("div",ft,[t.createElementVNode("img",{src:e.logo,alt:e.title+" logo",class:t.normalizeClass({small:n.small}),onError:t=>s.onImageError(t,e.title)},null,42,mt)]),t.createTextVNode(" "+t.toDisplayString(e.title),1)])],10,ut)],2))),128)),s.currentBookmarks.length<8?(t.openBlock(),t.createElementBlock("div",{key:0,class:t.normalizeClass(["card",n.small?"small":""])},[t.createElementVNode("a",{href:"#",class:t.normalizeClass(["card-link","dark"==n.theme?"dark":"light"]),onClick:o[0]||(o[0]=t.withModifiers((...e)=>s.addBookmarkPrompt&&s.addBookmarkPrompt(...e),["prevent"]))},o[1]||(o[1]=[t.createElementVNode("div",{class:"column"},[t.createElementVNode("span",{class:"add"},"+"),t.createTextVNode(" Add ")],-1)]),2)],2)):t.createCommentVNode("",!0)])])}],["__scopeId","data-v-5c8411db"]]),gt=t.defineCustomElement(g),kt=t.defineCustomElement(Re),bt=t.defineCustomElement(nt),vt=t.defineCustomElement(ht);customElements.get("z-clock-widget")||customElements.define("z-clock-widget",gt),customElements.get("z-search-widget")||customElements.define("z-search-widget",kt),customElements.get("z-todo-widget")||customElements.define("z-todo-widget",bt),customElements.get("z-marked-widget")||customElements.define("z-marked-widget",vt),e.ZClockWidget=g,e.ZMarkedWidget=ht,e.ZSearchWidget=Re,e.ZTodoWidget=nt,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})});
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("vue")):"function"==typeof define&&define.amd?define(["exports","vue"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).ZenWdg={},e.Vue)}(this,function(e,t){"use strict";var n=Object.defineProperty,o=Object.defineProperties,a=Object.getOwnPropertyDescriptors,r=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable,s=(e,t,o)=>t in e?n(e,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):e[t]=o,c=(e,t)=>{for(var n in t||(t={}))l.call(t,n)&&s(e,n,t[n]);if(r)for(var n of r(t))i.call(t,n)&&s(e,n,t[n]);return e},d=(e,t)=>o(e,a(t)),u=(e,t,n)=>new Promise((o,a)=>{var r=e=>{try{i(n.next(e))}catch(t){a(t)}},l=e=>{try{i(n.throw(e))}catch(t){a(t)}},i=e=>e.done?o(e.value):Promise.resolve(e.value).then(r,l);i((n=n.apply(e,t)).next())});const m=(e,t)=>{const n=e.__vccOpts||e;for(const[o,a]of t)n[o]=a;return n},p={class:"clock-container"},h={class:"clock"},g={class:"time"},f={class:"date"};const v=m({name:"ZClockWidget",data:()=>({hours:"00",minutes:"00",seconds:"00",dayOfWeek:"",day:"",month:"",year:""}),mounted(){this.updateClock(),setInterval(this.updateClock,1e3)},methods:{updateClock(){const e=new Date;this.hours=e.getHours().toString().padStart(2,"0"),this.minutes=e.getMinutes().toString().padStart(2,"0"),this.seconds=e.getSeconds().toString().padStart(2,"0"),this.dayOfWeek=this.getDayOfWeek(e.getDay()),this.day=e.getDate(),this.month=this.getMonthName(e.getMonth()),this.year=e.getFullYear()},getDayOfWeek:e=>["Domingo","Lunes","Martes","Miércoles","Jueves","Viernes","Sábado"][e],getMonthName:e=>["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"][e]}},[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("div",p,[t.createElementVNode("div",h,[t.createElementVNode("div",g,[t.createElementVNode("span",null,t.toDisplayString(r.hours),1),n[0]||(n[0]=t.createTextVNode(":",-1)),t.createElementVNode("span",null,t.toDisplayString(r.minutes),1)]),t.createElementVNode("div",f,[t.createElementVNode("span",null,t.toDisplayString(r.dayOfWeek)+", "+t.toDisplayString(r.day)+" "+t.toDisplayString(r.month)+" "+t.toDisplayString(r.year),1)])])])}],["__scopeId","data-v-e9445086"]]),y={data:()=>({}),props:{placeholder:String,modelValue:{type:String,default:""},round:{type:Boolean,default:!1},full:{type:Boolean},rounded:{type:Boolean,default:!1}},methods:{onInput(e){this.$emit("update:modelValue",e.target.value)},onEnter(){this.$emit("enter-pressed",this.modelValue)}}},b=["placeholder","value"];const k=m(y,[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("input",{placeholder:o.placeholder,value:o.modelValue,onInput:n[0]||(n[0]=(...e)=>l.onInput&&l.onInput(...e)),onKeydown:n[1]||(n[1]=t.withKeys((...e)=>l.onEnter&&l.onEnter(...e),["enter"])),class:t.normalizeClass([{"full-width":o.full},{round:o.round},{rounded:o.rounded}])},null,42,b)}],["__scopeId","data-v-2ad90286"]]),w=/^[a-z0-9]+(-[a-z0-9]+)*$/,E=(e,t,n,o="")=>{const a=e.split(":");if("@"===e.slice(0,1)){if(a.length<2||a.length>3)return null;o=a.shift().slice(1)}if(a.length>3||!a.length)return null;if(a.length>1){const e=a.pop(),n=a.pop(),r={provider:a.length>0?a[0]:o,prefix:n,name:e};return t&&!N(r)?null:r}const r=a[0],l=r.split("-");if(l.length>1){const e={provider:o,prefix:l.shift(),name:l.join("-")};return t&&!N(e)?null:e}if(n&&""===o){const e={provider:o,prefix:"",name:r};return t&&!N(e,n)?null:e}return null},N=(e,t)=>!!e&&!(!(t&&""===e.prefix||e.prefix)||!e.name),C=Object.freeze({left:0,top:0,width:16,height:16}),V=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),S=Object.freeze(c(c({},C),V)),D=Object.freeze(d(c({},S),{body:"",hidden:!1}));function x(e,t){const n=function(e,t){const n={};!e.hFlip!=!t.hFlip&&(n.hFlip=!0),!e.vFlip!=!t.vFlip&&(n.vFlip=!0);const o=((e.rotate||0)+(t.rotate||0))%4;return o&&(n.rotate=o),n}(e,t);for(const o in D)o in V?o in e&&!(o in n)&&(n[o]=V[o]):o in t?n[o]=t[o]:o in e&&(n[o]=e[o]);return n}function B(e,t,n){const o=e.icons,a=e.aliases||Object.create(null);let r={};function l(e){r=x(o[e]||a[e],r)}return l(t),n.forEach(l),x(e,r)}function T(e,t){const n=[];if("object"!=typeof e||"object"!=typeof e.icons)return n;e.not_found instanceof Array&&e.not_found.forEach(e=>{t(e,null),n.push(e)});const o=function(e){const t=e.icons,n=e.aliases||Object.create(null),o=Object.create(null);return Object.keys(t).concat(Object.keys(n)).forEach(function e(a){if(t[a])return o[a]=[];if(!(a in o)){o[a]=null;const t=n[a]&&n[a].parent,r=t&&e(t);r&&(o[a]=[t].concat(r))}return o[a]}),o}(e);for(const a in o){const r=o[a];r&&(t(a,B(e,a,r)),n.push(a))}return n}const z=c({provider:"",aliases:{},not_found:{}},C);function F(e,t){for(const n in t)if(n in e&&typeof e[n]!=typeof t[n])return!1;return!0}function M(e){if("object"!=typeof e||null===e)return null;const t=e;if("string"!=typeof t.prefix||!e.icons||"object"!=typeof e.icons)return null;if(!F(e,z))return null;const n=t.icons;for(const a in n){const e=n[a];if(!a||"string"!=typeof e.body||!F(e,D))return null}const o=t.aliases||Object.create(null);for(const a in o){const e=o[a],t=e.parent;if(!a||"string"!=typeof t||!n[t]&&!o[t]||!F(e,D))return null}return t}const I=Object.create(null);function O(e,t){const n=I[e]||(I[e]=Object.create(null));return n[t]||(n[t]=function(e,t){return{provider:e,prefix:t,icons:Object.create(null),missing:new Set}}(e,t))}function L(e,t){return M(t)?T(t,(t,n)=>{n?e.icons[t]=n:e.missing.add(t)}):[]}let j=!1;function _(e){return"boolean"==typeof e&&(j=e),j}function A(e,t){const n=E(e,!0,j);if(!n)return!1;const o=O(n.provider,n.prefix);return t?function(e,t,n){try{if("string"==typeof n.body)return e.icons[t]=c({},n),!0}catch(o){}return!1}(o,n.name,t):(o.missing.add(n.name),!0)}const P=Object.freeze({width:null,height:null}),$=Object.freeze(c(c({},P),V)),U=/(-?[0-9.]*[0-9]+[0-9.]*)/g,W=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function R(e,t,n){if(1===t)return e;if(n=n||100,"number"==typeof e)return Math.ceil(e*t*n)/n;if("string"!=typeof e)return e;const o=e.split(U);if(null===o||!o.length)return e;const a=[];let r=o.shift(),l=W.test(r);for(;;){if(l){const e=parseFloat(r);isNaN(e)?a.push(r):a.push(Math.ceil(e*t*n)/n)}else a.push(r);if(r=o.shift(),void 0===r)return a.join("");l=!l}}const H=/\sid="(\S+)"/g,J="IconifyId"+Date.now().toString(16)+(16777216*Math.random()|0).toString(16);let Z=0;const q=Object.create(null);function K(e){return q[e]||q[""]}function G(e){let t;if("string"==typeof e.resources)t=[e.resources];else if(t=e.resources,!(t instanceof Array&&t.length))return null;return{resources:t,path:e.path||"/",maxURL:e.maxURL||500,rotate:e.rotate||750,timeout:e.timeout||5e3,random:!0===e.random,index:e.index||0,dataAfterTimeout:!1!==e.dataAfterTimeout}}const Y=Object.create(null),Q=["https://api.simplesvg.com","https://api.unisvg.com"],X=[];for(;Q.length>0;)1===Q.length||Math.random()>.5?X.push(Q.shift()):X.push(Q.pop());function ee(e,t){const n=G(t);return null!==n&&(Y[e]=n,!0)}function te(e){return Y[e]}Y[""]=G({resources:["https://api.iconify.design"].concat(X)});let ne=(()=>{let e;try{if(e=fetch,"function"==typeof e)return e}catch(t){}})();const oe={prepare:(e,t,n)=>{const o=[],a=function(e,t){const n=te(e);if(!n)return 0;let o;if(n.maxURL){let e=0;n.resources.forEach(t=>{const n=t;e=Math.max(e,n.length)});const a=t+".json?icons=";o=n.maxURL-e-n.path.length-a.length}else o=0;return o}(e,t),r="icons";let l={type:r,provider:e,prefix:t,icons:[]},i=0;return n.forEach((n,s)=>{i+=n.length+1,i>=a&&s>0&&(o.push(l),l={type:r,provider:e,prefix:t,icons:[]},i=n.length),l.icons.push(n)}),o.push(l),o},send:(e,t,n)=>{if(!ne)return void n("abort",424);let o=function(e){if("string"==typeof e){const t=te(e);if(t)return t.path}return"/"}(t.provider);switch(t.type){case"icons":{const e=t.prefix,n=t.icons.join(",");o+=e+".json?"+new URLSearchParams({icons:n}).toString();break}case"custom":{const e=t.uri;o+="/"===e.slice(0,1)?e.slice(1):e;break}default:return void n("abort",400)}let a=503;ne(e+o).then(e=>{const t=e.status;if(200===t)return a=501,e.json();setTimeout(()=>{n(function(e){return 404===e}(t)?"abort":"next",t)})}).then(e=>{"object"==typeof e&&null!==e?setTimeout(()=>{n("success",e)}):setTimeout(()=>{404===e?n("abort",e):n("next",a)})}).catch(()=>{n("next",a)})}};function ae(e,t){e.forEach(e=>{const n=e.loaderCallbacks;n&&(e.loaderCallbacks=n.filter(e=>e.id!==t))})}let re=0;var le={resources:[],index:0,timeout:2e3,rotate:750,random:!1,dataAfterTimeout:!1};function ie(e,t,n,o){const a=e.resources.length,r=e.random?Math.floor(Math.random()*a):e.index;let l;if(e.random){let t=e.resources.slice(0);for(l=[];t.length>1;){const e=Math.floor(Math.random()*t.length);l.push(t[e]),t=t.slice(0,e).concat(t.slice(e+1))}l=l.concat(t)}else l=e.resources.slice(r).concat(e.resources.slice(0,r));const i=Date.now();let s,c="pending",d=0,u=null,m=[],p=[];function h(){u&&(clearTimeout(u),u=null)}function g(){"pending"===c&&(c="aborted"),h(),m.forEach(e=>{"pending"===e.status&&(e.status="aborted")}),m=[]}function f(e,t){t&&(p=[]),"function"==typeof e&&p.push(e)}function v(){c="failed",p.forEach(e=>{e(void 0,s)})}function y(){m.forEach(e=>{"pending"===e.status&&(e.status="aborted")}),m=[]}function b(){if("pending"!==c)return;h();const o=l.shift();if(void 0===o)return m.length?void(u=setTimeout(()=>{h(),"pending"===c&&(y(),v())},e.timeout)):void v();const a={status:"pending",resource:o,callback:(t,n)=>{!function(t,n,o){const a="success"!==n;switch(m=m.filter(e=>e!==t),c){case"pending":break;case"failed":if(a||!e.dataAfterTimeout)return;break;default:return}if("abort"===n)return s=o,void v();if(a)return s=o,void(m.length||(l.length?b():v()));if(h(),y(),!e.random){const n=e.resources.indexOf(t.resource);-1!==n&&n!==e.index&&(e.index=n)}c="completed",p.forEach(e=>{e(o)})}(a,t,n)}};m.push(a),d++,u=setTimeout(b,e.rotate),n(o,t,a.callback)}return"function"==typeof o&&p.push(o),setTimeout(b),function(){return{startTime:i,payload:t,status:c,queriesSent:d,queriesPending:m.length,subscribe:f,abort:g}}}function se(e){const t=c(c({},le),e);let n=[];function o(){n=n.filter(e=>"pending"===e().status)}return{query:function(e,a,r){const l=ie(t,e,a,(e,t)=>{o(),r&&r(e,t)});return n.push(l),l},find:function(e){return n.find(t=>e(t))||null},setIndex:e=>{t.index=e},getIndex:()=>t.index,cleanup:o}}function ce(){}const de=Object.create(null);function ue(e,t,n){let o,a;if("string"==typeof e){const t=K(e);if(!t)return n(void 0,424),ce;a=t.send;const r=function(e){if(!de[e]){const t=te(e);if(!t)return;const n={config:t,redundancy:se(t)};de[e]=n}return de[e]}(e);r&&(o=r.redundancy)}else{const t=G(e);if(t){o=se(t);const n=K(e.resources?e.resources[0]:"");n&&(a=n.send)}}return o&&a?o.query(t,a,n)().abort:(n(void 0,424),ce)}function me(){}function pe(e){e.iconsLoaderFlag||(e.iconsLoaderFlag=!0,setTimeout(()=>{e.iconsLoaderFlag=!1,function(e){e.pendingCallbacksFlag||(e.pendingCallbacksFlag=!0,setTimeout(()=>{e.pendingCallbacksFlag=!1;const t=e.loaderCallbacks?e.loaderCallbacks.slice(0):[];if(!t.length)return;let n=!1;const o=e.provider,a=e.prefix;t.forEach(t=>{const r=t.icons,l=r.pending.length;r.pending=r.pending.filter(t=>{if(t.prefix!==a)return!0;const l=t.name;if(e.icons[l])r.loaded.push({provider:o,prefix:a,name:l});else{if(!e.missing.has(l))return n=!0,!0;r.missing.push({provider:o,prefix:a,name:l})}return!1}),r.pending.length!==l&&(n||ae([e],t.id),t.callback(r.loaded.slice(0),r.missing.slice(0),r.pending.slice(0),t.abort))})}))}(e)}))}function he(e,t,n){function o(){const n=e.pendingIcons;t.forEach(t=>{n&&n.delete(t),e.icons[t]||e.missing.add(t)})}if(n&&"object"==typeof n)try{if(!L(e,n).length)return void o()}catch(a){console.error(a)}o(),pe(e)}function ge(e,t){e instanceof Promise?e.then(e=>{t(e)}).catch(()=>{t(null)}):t(e)}function fe(e,t){e.iconsToLoad?e.iconsToLoad=e.iconsToLoad.concat(t).sort():e.iconsToLoad=t,e.iconsQueueFlag||(e.iconsQueueFlag=!0,setTimeout(()=>{e.iconsQueueFlag=!1;const{provider:t,prefix:n}=e,o=e.iconsToLoad;if(delete e.iconsToLoad,!o||!o.length)return;const a=e.loadIcon;if(e.loadIcons&&(o.length>1||!a))return void ge(e.loadIcons(o,n,t),t=>{he(e,o,t)});if(a)return void o.forEach(o=>{ge(a(o,n,t),t=>{he(e,[o],t?{prefix:n,icons:{[o]:t}}:null)})});const{valid:r,invalid:l}=function(e){const t=[],n=[];return e.forEach(e=>{(e.match(w)?t:n).push(e)}),{valid:t,invalid:n}}(o);if(l.length&&he(e,l,null),!r.length)return;const i=n.match(w)?K(t):null;if(!i)return void he(e,r,null);i.prepare(t,n,r).forEach(n=>{ue(t,n,t=>{he(e,n.icons,t)})})}))}const ve=(e,t)=>{const n=function(e){const t={loaded:[],missing:[],pending:[]},n=Object.create(null);e.sort((e,t)=>e.provider!==t.provider?e.provider.localeCompare(t.provider):e.prefix!==t.prefix?e.prefix.localeCompare(t.prefix):e.name.localeCompare(t.name));let o={provider:"",prefix:"",name:""};return e.forEach(e=>{if(o.name===e.name&&o.prefix===e.prefix&&o.provider===e.provider)return;o=e;const a=e.provider,r=e.prefix,l=e.name,i=n[a]||(n[a]=Object.create(null)),s=i[r]||(i[r]=O(a,r));let c;c=l in s.icons?t.loaded:""===r||s.missing.has(l)?t.missing:t.pending;const d={provider:a,prefix:r,name:l};c.push(d)}),t}(function(e,t=!0,n=!1){const o=[];return e.forEach(e=>{const a="string"==typeof e?E(e,t,n):e;a&&o.push(a)}),o}(e,!0,_()));if(!n.pending.length){let e=!0;return t&&setTimeout(()=>{e&&t(n.loaded,n.missing,n.pending,me)}),()=>{e=!1}}const o=Object.create(null),a=[];let r,l;return n.pending.forEach(e=>{const{provider:t,prefix:n}=e;if(n===l&&t===r)return;r=t,l=n,a.push(O(t,n));const i=o[t]||(o[t]=Object.create(null));i[n]||(i[n]=[])}),n.pending.forEach(e=>{const{provider:t,prefix:n,name:a}=e,r=O(t,n),l=r.pendingIcons||(r.pendingIcons=new Set);l.has(a)||(l.add(a),o[t][n].push(a))}),a.forEach(e=>{const t=o[e.provider][e.prefix];t.length&&fe(e,t)}),t?function(e,t,n){const o=re++,a=ae.bind(null,n,o);if(!t.pending.length)return a;const r={id:o,icons:t,callback:e,abort:a};return n.forEach(e=>{(e.loaderCallbacks||(e.loaderCallbacks=[])).push(r)}),a}(t,n,a):me};const ye=/[\s,]+/;function be(e,t){t.split(ye).forEach(t=>{switch(t.trim()){case"horizontal":e.hFlip=!0;break;case"vertical":e.vFlip=!0}})}function ke(e,t=0){const n=e.replace(/^-?[0-9.]*/,"");function o(e){for(;e<0;)e+=4;return e%4}if(""===n){const t=parseInt(e);return isNaN(t)?0:o(t)}if(n!==e){let t=0;switch(n){case"%":t=25;break;case"deg":t=90}if(t){let a=parseFloat(e.slice(0,e.length-n.length));return isNaN(a)?0:(a/=t,a%1==0?o(a):0)}}return t}const we=d(c({},$),{inline:!1}),Ee={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":!0,role:"img"},Ne={display:"inline-block"},Ce={backgroundColor:"currentColor"},Ve={backgroundColor:"transparent"},Se={Image:"var(--svg)",Repeat:"no-repeat",Size:"100% 100%"},De={webkitMask:Ce,mask:Ce,background:Ve};for(const Vo in De){const e=De[Vo];for(const t in Se)e[Vo+t]=Se[t]}const xe={};function Be(e){return e+(e.match(/^[-0-9.]+$/)?"px":"")}["horizontal","vertical"].forEach(e=>{const t=e.slice(0,1)+"Flip";xe[e+"-flip"]=t,xe[e.slice(0,1)+"-flip"]=t,xe[e+"Flip"]=t});const Te=(e,n)=>{const o=function(e,t){const n=c({},e);for(const o in t){const e=t[o],a=typeof e;o in P?(null===e||e&&("string"===a||"number"===a))&&(n[o]=e):a===typeof n[o]&&(n[o]="rotate"===o?e%4:e)}return n}(we,n),a=c({},Ee),r=n.mode||"svg",l={},i=n.style,s="object"!=typeof i||i instanceof Array?{}:i;for(let t in n){const e=n[t];if(void 0!==e)switch(t){case"icon":case"style":case"onLoad":case"mode":case"ssr":break;case"inline":case"hFlip":case"vFlip":o[t]=!0===e||"true"===e||1===e;break;case"flip":"string"==typeof e&&be(o,e);break;case"color":l.color=e;break;case"rotate":"string"==typeof e?o[t]=ke(e):"number"==typeof e&&(o[t]=e);break;case"ariaHidden":case"aria-hidden":!0!==e&&"true"!==e&&delete a["aria-hidden"];break;default:{const n=xe[t];n?!0!==e&&"true"!==e&&1!==e||(o[n]=!0):void 0===we[t]&&(a[t]=e)}}}const u=function(e,t){const n=c(c({},S),e),o=c(c({},$),t),a={left:n.left,top:n.top,width:n.width,height:n.height};let r=n.body;[n,o].forEach(e=>{const t=[],n=e.hFlip,o=e.vFlip;let l,i=e.rotate;switch(n?o?i+=2:(t.push("translate("+(a.width+a.left).toString()+" "+(0-a.top).toString()+")"),t.push("scale(-1 1)"),a.top=a.left=0):o&&(t.push("translate("+(0-a.left).toString()+" "+(a.height+a.top).toString()+")"),t.push("scale(1 -1)"),a.top=a.left=0),i<0&&(i-=4*Math.floor(i/4)),i%=4,i){case 1:l=a.height/2+a.top,t.unshift("rotate(90 "+l.toString()+" "+l.toString()+")");break;case 2:t.unshift("rotate(180 "+(a.width/2+a.left).toString()+" "+(a.height/2+a.top).toString()+")");break;case 3:l=a.width/2+a.left,t.unshift("rotate(-90 "+l.toString()+" "+l.toString()+")")}i%2==1&&(a.left!==a.top&&(l=a.left,a.left=a.top,a.top=l),a.width!==a.height&&(l=a.width,a.width=a.height,a.height=l)),t.length&&(r=function(e,t,n){const o=function(e,t="defs"){let n="";const o=e.indexOf("<"+t);for(;o>=0;){const a=e.indexOf(">",o),r=e.indexOf("</"+t);if(-1===a||-1===r)break;const l=e.indexOf(">",r);if(-1===l)break;n+=e.slice(a+1,r).trim(),e=e.slice(0,o).trim()+e.slice(l+1)}return{defs:n,content:e}}(e);return a=o.defs,r=t+o.content+n,a?"<defs>"+a+"</defs>"+r:r;var a,r}(r,'<g transform="'+t.join(" ")+'">',"</g>"))});const l=o.width,i=o.height,s=a.width,d=a.height;let u,m;null===l?(m=null===i?"1em":"auto"===i?d:i,u=R(m,s/d)):(u="auto"===l?s:l,m=null===i?R(u,d/s):"auto"===i?d:i);const p={},h=(e,t)=>{(e=>"unset"===e||"undefined"===e||"none"===e)(t)||(p[e]=t.toString())};h("width",u),h("height",m);const g=[a.left,a.top,s,d];return p.viewBox=g.join(" "),{attributes:p,viewBox:g,body:r}}(e,o),m=u.attributes;if(o.inline&&(l.verticalAlign="-0.125em"),"svg"===r){a.style=c(c({},l),s),Object.assign(a,m);let e=0,o=n.id;return"string"==typeof o&&(o=o.replace(/-/g,"_")),a.innerHTML=function(e,t=J){const n=[];let o;for(;o=H.exec(e);)n.push(o[1]);if(!n.length)return e;const a="suffix"+(16777216*Math.random()|Date.now()).toString(16);return n.forEach(n=>{const o="function"==typeof t?t(n):t+(Z++).toString(),r=n.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+r+')([")]|\\.[a-z])',"g"),"$1"+o+a+"$3")}),e=e.replace(new RegExp(a,"g"),"")}(u.body,o?()=>o+"ID"+e++:"iconifyVue"),t.h("svg",a)}const{body:p,width:h,height:g}=e,f="mask"===r||"bg"!==r&&-1!==p.indexOf("currentColor"),v=function(e,t){let n=-1===e.indexOf("xlink:")?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const o in t)n+=" "+o+'="'+t[o]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+n+">"+e+"</svg>"}(p,d(c({},m),{width:h+"",height:g+""}));var y;return a.style=c(c(c(d(c({},l),{"--svg":(y=v,'url("'+function(e){return"data:image/svg+xml,"+function(e){return e.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}(e)}(y)+'")'),width:Be(m.width),height:Be(m.height)}),Ne),f?Ce:Ve),s),t.h("span",a)};var ze;if(_(!0),ze=oe,q[""]=ze,"undefined"!=typeof document&&"undefined"!=typeof window){const e=window;if(void 0!==e.IconifyPreload){const t=e.IconifyPreload,n="Invalid IconifyPreload syntax.";"object"==typeof t&&null!==t&&(t instanceof Array?t:[t]).forEach(e=>{try{("object"!=typeof e||null===e||e instanceof Array||"object"!=typeof e.icons||"string"!=typeof e.prefix||!function(e,t){if("object"!=typeof e)return!1;if("string"!=typeof t&&(t=e.provider||""),j&&!t&&!e.prefix){let t=!1;return M(e)&&(e.prefix="",T(e,(e,n)=>{A(e,n)&&(t=!0)})),t}const n=e.prefix;return!!N({prefix:n,name:"a"})&&!!L(O(t,n),e)}(e))&&console.error(n)}catch(t){console.error(n)}})}if(void 0!==e.IconifyProviders){const t=e.IconifyProviders;if("object"==typeof t&&null!==t)for(let e in t){const n="IconifyProviders["+e+"] is invalid.";try{const o=t[e];if("object"!=typeof o||!o||void 0===o.resources)continue;ee(e,o)||console.error(n)}catch(Co){console.error(n)}}}}const Fe=d(c({},S),{body:""});const Me=m({data:()=>({}),components:{Icon:t.defineComponent((e,{emit:n})=>{const o=t.ref(null);function a(){var e,t;o.value&&(null==(t=(e=o.value).abort)||t.call(e),o.value=null)}const r=t.ref(!!e.ssr),l=t.ref(""),i=t.shallowRef(null);function s(){const r=e.icon;if("object"==typeof r&&null!==r&&"string"==typeof r.body)return l.value="",{data:r};let i;if("string"!=typeof r||null===(i=E(r,!1,!0)))return null;let s=function(e){const t="string"==typeof e?E(e,!0,j):e;if(t){const e=O(t.provider,t.prefix),n=t.name;return e.icons[n]||(e.missing.has(n)?null:void 0)}}(i);if(!s){const e=o.value;return e&&e.name===r||(o.value=null===s?{name:r}:{name:r,abort:ve([i],u)}),null}a(),l.value!==r&&(l.value=r,t.nextTick(()=>{n("load",r)}));const c=e.customise;if(c){s=Object.assign({},s);const e=c(s.body,i.name,i.prefix,i.provider);"string"==typeof e&&(s.body=e)}const d=["iconify"];return""!==i.prefix&&d.push("iconify--"+i.prefix),""!==i.provider&&d.push("iconify--"+i.provider),{data:s,classes:d}}function u(){var e;const t=s();t?t.data!==(null==(e=i.value)?void 0:e.data)&&(i.value=t):i.value=null}return r.value?u():t.onMounted(()=>{r.value=!0,u()}),t.watch(()=>e.icon,u),t.onUnmounted(a),()=>{const t=i.value;if(!t)return Te(Fe,e);let n=e;return t.classes&&(n=d(c({},e),{class:t.classes.join(" ")})),Te(c(c({},S),t.data),n)}},{props:["icon","mode","ssr","width","height","style","color","inline","rotate","hFlip","horizontalFlip","vFlip","verticalFlip","flip","id","ariaHidden","customise","title"],emits:["load"]})},props:{title:{type:String,required:!1},bound:{type:Boolean,default:!1},bounded:{type:Boolean,default:!1},flat:{type:Boolean,default:!1},iconLeft:{type:Boolean,required:!1,default:!1},iconRight:{type:Boolean,default:!1},icon:{type:String},size:{type:String},iconSize:{type:String},wFull:{type:Boolean,default:!1},noBg:{type:Boolean,default:!1},color:String},methods:{}},[["render",function(e,n,o,a,r,l){const i=t.resolveComponent("Icon");return t.openBlock(),t.createElementBlock("button",{class:t.normalizeClass([{flat:o.flat},{bound:o.bound},{bounded:o.bounded},{"w-full":o.wFull},{transparent:o.noBg}]),style:t.normalizeStyle([{"font-size":o.size},{color:o.color}])},[o.iconLeft?(t.openBlock(),t.createBlock(i,{key:0,icon:o.icon,style:t.normalizeStyle({"font-size":o.iconSize})},null,8,["icon","style"])):t.createCommentVNode("",!0),t.createTextVNode(" "+t.toDisplayString(o.title)+" ",1),o.icon&&!o.iconLeft?(t.openBlock(),t.createBlock(i,{key:1,icon:o.icon,width:o.iconSize,height:o.iconSize},null,8,["icon","width","height"])):t.createCommentVNode("",!0)],6)}],["__scopeId","data-v-10678914"]]),Ie={name:"Dropdown",props:{modelValue:Object,options:{type:Array,required:!0},placeholder:{type:String,default:"Seleccionar..."}},data:()=>({isOpen:!1}),created(){console.log(this.options)},computed:{selected(){return this.modelValue}},methods:{toggleDropdown(){this.isOpen=!this.isOpen},selectItem(e){this.$emit("update:modelValue",e),this.isOpen=!1,console.log(e)},selectOption(e){this.selectedOption=e,this.isOpen=!1,this.$emit("update:modelValue",e),this.$emit("change",e)},handleClickOutside(e){this.$refs.dropdown.contains(e.target)||(this.isOpen=!1)}},mounted(){document.addEventListener("click",this.handleClickOutside)},beforeUnmount(){document.removeEventListener("click",this.handleClickOutside)}},Oe={class:"container",ref:"dropdown"},Le={key:0},je=["src"],_e={key:1,class:"placeholder"},Ae={key:0,class:"column list"},Pe=["onClick"],$e={key:0},Ue=["src"],We={key:1};const Re=m(Ie,[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("div",Oe,[t.createElementVNode("div",{class:"row select",onClick:n[0]||(n[0]=(...e)=>l.toggleDropdown&&l.toggleDropdown(...e))},[l.selected?(t.openBlock(),t.createElementBlock("span",Le,[l.selected.logo?(t.openBlock(),t.createElementBlock("img",{key:0,src:l.selected.logo,class:"logo"},null,8,je)):t.createCommentVNode("",!0)])):(t.openBlock(),t.createElementBlock("span",_e,"Selecciona una opción"))]),r.isOpen?(t.openBlock(),t.createElementBlock("div",Ae,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.options,(e,n)=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["item row",{active:e.id==l.selected.id}]),onClick:t=>l.selectItem(e)},[e.logo?(t.openBlock(),t.createElementBlock("span",$e,[t.createElementVNode("img",{src:e.logo,class:"logo"},null,8,Ue)])):t.createCommentVNode("",!0),e.label?(t.openBlock(),t.createElementBlock("span",We,t.toDisplayString(e.label),1)):t.createCommentVNode("",!0)],10,Pe))),256))])):t.createCommentVNode("",!0)],512)}],["__scopeId","data-v-d1389195"]]),He={class:"container-search"},Je={class:"search"};const Ze=m({name:"ZSearchWidget",data:()=>({text:"",engines:[{id:1,logo:"https://s1.qwant.com/thumbr/474x474/b/c/eae6b919559217567ef067dec4aa1e425d560667e5b8e51333bea1b60f4de7/OIP.G3kcQIn5w4kJtUilFbWaigHaHa.jpg?u=https%3A%2F%2Fthf.bing.com%2Fth%2Fid%2FOIP.G3kcQIn5w4kJtUilFbWaigHaHa%3Fr%3D0%26cb%3Dthfc1%26pid%3DApi&q=0&b=1&p=0&a=0",label:"Qwant",search:"https://www.qwant.com/?l=es&q="},{id:2,logo:"https://astian.org/wp-content/uploads/2025/06/favicon-1.png",label:"AstianGO",search:"https://astiango.com/?q="}],engine:{id:1,logo:"https://s1.qwant.com/thumbr/474x474/b/c/eae6b919559217567ef067dec4aa1e425d560667e5b8e51333bea1b60f4de7/OIP.G3kcQIn5w4kJtUilFbWaigHaHa.jpg?u=https%3A%2F%2Fthf.bing.com%2Fth%2Fid%2FOIP.G3kcQIn5w4kJtUilFbWaigHaHa%3Fr%3D0%26cb%3Dthfc1%26pid%3DApi&q=0&b=1&p=0&a=0",label:"Qwant",search:"https://www.qwant.com/?l=es&q="},urls:{url:"https://www.qwant.com/?l=es&q=facebook+login&t=web"}}),props:{searchTarget:{type:String,require:!1,default:"Self Tab"},logo:{type:String,require:!1}},components:{Input:k,Button:Me,Dropdown:Re},methods:{search(){console.log(this.engine.search);const e=`${this.engine.search}${this.text}`;"New Tab"==this.searchTarget?(chrome.tabs.create({url:e}),this.text=""):"Self Tab"==this.searchTarget&&chrome.tabs.update({url:e})}}},[["render",function(e,n,o,a,r,l){const i=t.resolveComponent("Dropdown"),s=t.resolveComponent("Input"),c=t.resolveComponent("Button");return t.openBlock(),t.createElementBlock("div",He,[t.createElementVNode("div",Je,[t.createElementVNode("div",null,[t.createVNode(i,{options:r.engines,modelValue:r.engine,"onUpdate:modelValue":n[0]||(n[0]=e=>r.engine=e)},null,8,["options","modelValue"])]),t.createVNode(s,{placeholder:"Search something",full:"",class:"bg-glass",modelValue:r.text,"onUpdate:modelValue":n[1]||(n[1]=e=>r.text=e),onEnterPressed:n[2]||(n[2]=e=>l.search())},null,8,["modelValue"]),t.createVNode(c,{icon:"material-symbols-light:search-rounded",size:"25px",flat:"",class:"text-color",onClick:n[3]||(n[3]=e=>l.search())})])])}],["__scopeId","data-v-834a689a"]]),qe={class:"todo-widget"},Ke={class:"task-section"},Ge={key:0,class:"empty"},Ye={class:"actions"},Qe=["onClick"],Xe=["onClick"],et={class:"task-section completed"},tt={key:0,class:"empty"},nt={class:"done"},ot=["onClick"];const at=m({name:"ZTodoWidget",data:()=>({newTask:"",pendingTasks:[],completedTasks:[]}),methods:{addTask(){this.newTask.trim()&&(this.pendingTasks.push({text:this.newTask.trim()}),this.newTask="")},completeTask(e){const t=this.pendingTasks.splice(e,1)[0];this.completedTasks.push(t)},deleteTask(e){this.pendingTasks.splice(e,1)},deleteCompleted(e){this.completedTasks.splice(e,1)}}},[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("div",qe,[n[5]||(n[5]=t.createElementVNode("h2",{class:"title"},"📝 Mis Tareas",-1)),t.createElementVNode("form",{onSubmit:n[1]||(n[1]=t.withModifiers((...e)=>l.addTask&&l.addTask(...e),["prevent"])),class:"todo-form"},[t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[0]||(n[0]=e=>r.newTask=e),type:"text",placeholder:"Escribe una nueva tarea..."},null,512),[[t.vModelText,r.newTask]]),n[2]||(n[2]=t.createElementVNode("button",{type:"submit"},"Agregar",-1))],32),t.createElementVNode("div",Ke,[n[3]||(n[3]=t.createElementVNode("h3",null,"Tareas Pendientes",-1)),0===r.pendingTasks.length?(t.openBlock(),t.createElementBlock("div",Ge,"Sin tareas.")):t.createCommentVNode("",!0),t.createElementVNode("ul",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.pendingTasks,(e,n)=>(t.openBlock(),t.createElementBlock("li",{key:n},[t.createElementVNode("span",null,t.toDisplayString(e.text),1),t.createElementVNode("div",Ye,[t.createElementVNode("button",{onClick:e=>l.completeTask(n)},"✔️",8,Qe),t.createElementVNode("button",{onClick:e=>l.deleteTask(n)},"🗑️",8,Xe)])]))),128))])]),t.createElementVNode("div",et,[n[4]||(n[4]=t.createElementVNode("h3",null,"Completadas",-1)),0===r.completedTasks.length?(t.openBlock(),t.createElementBlock("div",tt,"Ninguna aún.")):t.createCommentVNode("",!0),t.createElementVNode("ul",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.completedTasks,(e,n)=>(t.openBlock(),t.createElementBlock("li",{key:"c"+n},[t.createElementVNode("span",nt,t.toDisplayString(e.text),1),t.createElementVNode("button",{onClick:e=>l.deleteCompleted(n)},"❌",8,ot)]))),128))])])])}],["__scopeId","data-v-3560194d"]]),rt={name:"ZMarkedWidget",props:{theme:{type:String,default:"light"},small:{type:Boolean,default:!1},categories:{type:Array,default:()=>["Personal","Work","Study"]},open:{type:String,default:"Self Tab"},useStorage:{type:Boolean,default:!1}},data(){const e="bookmark_manager_state",t={Personal:[{title:"Astian",url:"https://astian.org/",domain:"astian.org"},{title:"Amazon",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM9HD56Q0VD2QZXQ2AR505&url=https%3A%2F%2Famazon.com",domain:"amazon.com"},{title:"Avast",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Favast.com%2F",domain:"avast.com"},{title:"Youtube",url:"https://youtube.com",domain:"youtube.com"},{title:"Instagram",url:"https://instagram.com",domain:"instagram.com"},{title:"Wish.com",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fwish.com",domain:"wish.com"},{title:"Prime",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fprimevideo.com",domain:"primevideo.com"},{title:"Shein",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fshein.com",domain:"shein.com"}],Work:[{title:"GitHub",url:"https://github.com",domain:"github.com"},{title:"Notion",url:"https://notion.so",domain:"notion.so"}],Study:[{title:"MDN Web Docs",url:"https://developer.mozilla.org",domain:"mozilla.org"},{title:"FreeCodeCamp",url:"https://freecodecamp.org",domain:"freecodecamp.org"},{title:"Udemy",url:"https://r.v2i8b.com/api/v1/bid/redirect?campaign_id=01JVSM8H9350F4CBP07A8V7C5T&url=http%3A%2F%2Fudemy.com%2F",domain:"udemy.com"}]};return{STORAGE_KEY:e,bookmarks:this.useStorage&&JSON.parse(localStorage.getItem(e))||t,activeTab:"Personal",faviconAttempts:{}}},computed:{currentBookmarks(){return this.bookmarks[this.activeTab]||[]}},methods:{saveState(){this.useStorage&&localStorage.setItem(this.STORAGE_KEY,JSON.stringify(this.bookmarks))},setActiveTab(e){this.activeTab=e},openLink(e){"self"===this.open?window.location.href=e:window.open(e,"_blank")},deleteBookmark(e){return u(this,null,function*(){const t=this.bookmarks[this.activeTab][e];(yield window.ZenModals.showDeleteConfirm(t.title))&&(this.bookmarks[this.activeTab].splice(e,1),this.saveState())})},editBookmark(e){return u(this,null,function*(){const t=this.bookmarks[this.activeTab][e],n=yield window.ZenModals.showPrompt({title:"Editar Marcador",message:"Introduce el nuevo título:",inputDefaultValue:t.title,inputPlaceholder:"Título del marcador"});if(!n)return;const o=yield window.ZenModals.showPrompt({title:"Editar URL",message:"Introduce la nueva URL:",inputDefaultValue:t.url,inputType:"url",inputPlaceholder:"https://ejemplo.com"});if(o)try{t.title=n,t.url=o,t.domain=new URL(o).hostname,delete t.logo,this.saveState()}catch(a){console.error("URL inválida:",a)}})},addBookmarkPrompt(){return u(this,null,function*(){const e=yield window.ZenModals.showPrompt({title:"Nuevo Marcador",message:"Introduce el nombre del marcador:",inputPlaceholder:"Nombre del sitio"});if(!e)return;const t=yield window.ZenModals.showPrompt({title:"URL del Marcador",message:"Introduce la URL:",inputType:"url",inputPlaceholder:"https://ejemplo.com"});if(t)try{const n=new URL(t).hostname;this.bookmarks[this.activeTab].push({title:e,url:t,domain:n}),this.saveState()}catch(n){console.error("URL inválida:",n)}})},getFaviconUrl(e){if(e.logo)return e.logo;const t=e.domain||this.extractDomain(e.url),n=this.faviconAttempts[t]||0,o=[`https://icons.duckduckgo.com/ip3/${t}.ico`,`https://www.google.com/s2/favicons?domain=${t}&sz=128`,`https://logo.clearbit.com/${t}`,`https://favicons.githubusercontent.com/${t}`,`https://${t}/favicon.ico`];return o[Math.min(n,o.length-1)]},extractDomain(e){try{return new URL(e).hostname}catch(Co){return e}},onImageError(e,t){const n=e.target,o=t.domain||this.extractDomain(t.url),a=this.faviconAttempts[o]||0;if(a<4)this.faviconAttempts[o]=a+1,n.src=this.getFaviconUrl(t);else{n.style.display="none";const e=n.parentNode,o=["#066D5A","#0891b2","#7c3aed","#dc2626","#ea580c","#ca8a04","#16a34a"],a=t.title.charCodeAt(0)%o.length;e.style.backgroundColor=o[a],e.style.display="flex",e.style.alignItems="center",e.style.justifyContent="center",e.style.fontSize="1.5rem",e.style.fontWeight="bold",e.style.color="white",e.textContent=t.title.charAt(0).toUpperCase()}}},watch:{bookmarks:{handler(){this.saveState()},deep:!0}}},lt={class:"container-marked"},it=["onClick"],st={class:"grid"},ct={class:"option-app"},dt=["onClick"],ut=["onClick"],mt=["href","target"],pt={class:"column"},ht={class:"logo-container"},gt=["src","alt","onError"];const ft=m(rt,[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("div",lt,[t.createElementVNode("div",{class:t.normalizeClass(["tabs",["dark"==o.theme?"dark":"light"]])},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(o.categories,e=>(t.openBlock(),t.createElementBlock("div",{key:e,class:"container-tab"},[t.createElementVNode("button",{class:t.normalizeClass(["tab",{active:e===r.activeTab}]),onClick:t=>l.setActiveTab(e)},t.toDisplayString(e),11,it)]))),128))],2),t.createElementVNode("div",st,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.currentBookmarks,(e,n)=>(t.openBlock(),t.createElementBlock("div",{key:n,class:t.normalizeClass(["card",o.small?"small":""])},[t.createElementVNode("div",ct,[t.createElementVNode("button",{class:"edit-app",onClick:t.withModifiers(e=>l.editBookmark(n),["prevent"])},"✏️",8,dt),t.createElementVNode("button",{class:"delete-app",onClick:t.withModifiers(e=>l.deleteBookmark(n),["prevent"])},"🗑️",8,ut)]),t.createElementVNode("a",{href:e.url,class:t.normalizeClass(["card-link","dark"==o.theme?"dark":"light"]),target:"Self Tab"==o.open?"_self":"_blank"},[t.createElementVNode("div",pt,[t.createElementVNode("div",ht,[t.createElementVNode("img",{src:l.getFaviconUrl(e),alt:e.title+" logo",class:t.normalizeClass({small:o.small}),onError:t=>l.onImageError(t,e)},null,42,gt)]),t.createTextVNode(" "+t.toDisplayString(e.title),1)])],10,mt)],2))),128)),l.currentBookmarks.length<8?(t.openBlock(),t.createElementBlock("div",{key:0,class:t.normalizeClass(["card",o.small?"small":""])},[t.createElementVNode("a",{href:"#",class:t.normalizeClass(["card-link","dark"==o.theme?"dark":"light"]),onClick:n[0]||(n[0]=t.withModifiers((...e)=>l.addBookmarkPrompt&&l.addBookmarkPrompt(...e),["prevent"]))},n[1]||(n[1]=[t.createElementVNode("div",{class:"column"},[t.createElementVNode("span",{class:"add"},"+"),t.createTextVNode(" Add ")],-1)]),2)],2)):t.createCommentVNode("",!0)])])}],["__scopeId","data-v-1625b2ac"]]),vt={name:"ZCalendarWidget",props:{theme:{type:String,default:"light"},useStorage:{type:Boolean,default:!0}},data(){const e="calendar_widget_events";let t=[];if(this.useStorage){const n=localStorage.getItem(e);t=n?JSON.parse(n):[]}const n={name:"",date:(new Date).toISOString().split("T")[0],startTime:"09:00",endTime:"10:00",color:"#066D5A",isRecurring:!1,recurringType:"daily"};return{STORAGE_KEY:e,currentView:"month",currentDate:new Date,showEventModal:!1,editingEvent:null,events:t,eventForm:n,viewLabels:{day:"Día",week:"Semana",month:"Mes"},dayNames:["Dom","Lun","Mar","Mié","Jue","Vie","Sáb"],colors:["#066D5A","#0891b2","#7c3aed","#dc2626","#ea580c","#ca8a04","#16a34a","#ec4899"]}},computed:{currentDateLabel(){const e=["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Agosto","Septiembre","Octubre","Noviembre","Diciembre"];if("day"===this.currentView)return`${this.currentDate.getDate()} de ${e[this.currentDate.getMonth()]} ${this.currentDate.getFullYear()}`;if("week"===this.currentView){const t=this.getWeekStart(this.currentDate),n=new Date(t);return n.setDate(n.getDate()+6),`${t.getDate()} - ${n.getDate()} ${e[this.currentDate.getMonth()]} ${this.currentDate.getFullYear()}`}return`${e[this.currentDate.getMonth()]} ${this.currentDate.getFullYear()}`},weekDays(){const e=this.getWeekStart(this.currentDate),t=[];for(let n=0;n<7;n++){const o=new Date(e);o.setDate(e.getDate()+n),t.push({date:this.formatDate(o),name:this.dayNames[o.getDay()],number:o.getDate()})}return t},monthDays(){const e=this.currentDate.getFullYear(),t=this.currentDate.getMonth(),n=new Date(e,t,1),o=new Date(n);o.setDate(o.getDate()-n.getDay());const a=[],r=new Date(o);for(let l=0;l<42;l++)a.push({date:this.formatDate(r),number:r.getDate(),isCurrentMonth:r.getMonth()===t}),r.setDate(r.getDate()+1);return a}},methods:{loadEvents(){if(!this.useStorage)return[];const e=localStorage.getItem(this.STORAGE_KEY);return e?JSON.parse(e):[]},saveEvents(){this.useStorage&&localStorage.setItem(this.STORAGE_KEY,JSON.stringify(this.events))},getEmptyForm(){return{name:"",date:this.formatDate(new Date),startTime:"09:00",endTime:"10:00",color:"#066D5A",isRecurring:!1,recurringType:"daily"}},formatDate(e){const t=new Date(e);return`${t.getFullYear()}-${String(t.getMonth()+1).padStart(2,"0")}-${String(t.getDate()).padStart(2,"0")}`},formatHour:e=>`${String(e).padStart(2,"0")}:00`,isToday(e){return e===this.formatDate(new Date)},getWeekStart(e){const t=new Date(e),n=t.getDay(),o=t.getDate()-n;return new Date(t.setDate(o))},previousPeriod(){const e=new Date(this.currentDate);"day"===this.currentView?e.setDate(e.getDate()-1):"week"===this.currentView?e.setDate(e.getDate()-7):e.setMonth(e.getMonth()-1),this.currentDate=e},nextPeriod(){const e=new Date(this.currentDate);"day"===this.currentView?e.setDate(e.getDate()+1):"week"===this.currentView?e.setDate(e.getDate()+7):e.setMonth(e.getMonth()+1),this.currentDate=e},goToToday(){this.currentDate=new Date},selectDay(e){this.currentDate=new Date(e),this.currentView="day"},getEventsForDay(e){return this.events.filter(t=>{if(t.date===e)return!0;if(t.isRecurring){const n=new Date(t.date),o=new Date(e);if(o<n)return!1;if("daily"===t.recurringType)return!0;if("weekly"===t.recurringType)return n.getDay()===o.getDay();if("monthly"===t.recurringType)return n.getDate()===o.getDate()}return!1})},getEventsForHour(e,t){return this.getEventsForDay(e).filter(e=>{const n=parseInt(e.startTime.split(":")[0]),o=parseInt(e.endTime.split(":")[0]);return t>=n&&t<o})},saveEvent(){return u(this,null,function*(){if(this.eventForm.name){if(this.editingEvent){const e=this.events.findIndex(e=>e.id===this.editingEvent.id);this.events[e]=d(c({},this.eventForm),{id:this.editingEvent.id})}else this.events.push(d(c({},this.eventForm),{id:Date.now()+Math.random()}));this.saveEvents(),this.closeModal()}else yield window.ZenModals.showWarning({title:"Nombre requerido",message:"Por favor, ingresa un nombre para el evento"})})},editEvent(e){this.editingEvent=e,this.eventForm=c({},e),this.showEventModal=!0},deleteEvent(){return u(this,null,function*(){(yield window.ZenModals.showDeleteConfirm("este evento"))&&(this.events=this.events.filter(e=>e.id!==this.editingEvent.id),this.saveEvents(),this.closeModal())})},closeModal(){this.showEventModal=!1,this.editingEvent=null,this.eventForm=this.getEmptyForm()}}},yt={class:"calendar-header"},bt={class:"view-selector"},kt=["onClick"],wt={class:"navigation"},Et={class:"current-date"},Nt={class:"calendar-view"},Ct={key:0,class:"day-view"},Vt={class:"time-grid"},St={class:"hour-label"},Dt={class:"hour-content"},xt=["onClick"],Bt={class:"event-title"},Tt={class:"event-time"},zt={key:0,class:"event-recurring"},Ft={key:1,class:"week-view"},Mt={class:"week-header"},It={class:"day-name"},Ot={class:"week-grid"},Lt={class:"week-hour-label"},jt=["onClick"],_t={class:"event-title"},At={key:2,class:"month-view"},Pt={class:"month-header"},$t={class:"month-grid"},Ut=["onClick"],Wt={class:"day-number"},Rt={class:"day-events"},Ht=["title"],Jt={key:0,class:"more-events"},Zt={class:"modal-content"},qt={class:"modal-header"},Kt={class:"modal-body"},Gt={class:"form-group"},Yt={class:"form-group"},Qt={class:"form-row"},Xt={class:"form-group"},en={class:"form-group"},tn={class:"form-group"},nn={class:"color-picker"},on=["onClick"],an={class:"form-group"},rn={class:"checkbox-label"},ln={key:0,class:"form-group"},sn={class:"modal-footer"};const cn=m(vt,[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["calendar-container","dark"===o.theme?"dark":"light"])},[t.createElementVNode("div",yt,[t.createElementVNode("div",bt,[(t.openBlock(),t.createElementBlock(t.Fragment,null,t.renderList(["day","week","month"],e=>t.createElementVNode("button",{key:e,class:t.normalizeClass(["view-btn",{active:r.currentView===e}]),onClick:t=>r.currentView=e},t.toDisplayString(r.viewLabels[e]),11,kt)),64))]),t.createElementVNode("div",wt,[t.createElementVNode("button",{onClick:n[0]||(n[0]=(...e)=>l.previousPeriod&&l.previousPeriod(...e)),class:"nav-btn"},"‹"),t.createElementVNode("span",Et,t.toDisplayString(l.currentDateLabel),1),t.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>l.nextPeriod&&l.nextPeriod(...e)),class:"nav-btn"},"›"),t.createElementVNode("button",{onClick:n[2]||(n[2]=(...e)=>l.goToToday&&l.goToToday(...e)),class:"today-btn"},"Hoy")]),t.createElementVNode("button",{onClick:n[3]||(n[3]=e=>r.showEventModal=!0),class:"add-event-btn"},"+ Evento")]),t.createElementVNode("div",Nt,["day"===r.currentView?(t.openBlock(),t.createElementBlock("div",Ct,[t.createElementVNode("div",Vt,[(t.openBlock(),t.createElementBlock(t.Fragment,null,t.renderList(24,e=>t.createElementVNode("div",{key:e,class:"hour-slot"},[t.createElementVNode("div",St,t.toDisplayString(l.formatHour(e-1)),1),t.createElementVNode("div",Dt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.getEventsForHour(l.formatDate(r.currentDate),e-1),e=>(t.openBlock(),t.createElementBlock("div",{key:e.id,class:"event-card",style:t.normalizeStyle({backgroundColor:e.color}),onClick:t=>l.editEvent(e)},[t.createElementVNode("div",Bt,t.toDisplayString(e.name),1),t.createElementVNode("div",Tt,t.toDisplayString(e.startTime)+" - "+t.toDisplayString(e.endTime),1),e.isRecurring?(t.openBlock(),t.createElementBlock("div",zt,"🔁")):t.createCommentVNode("",!0)],12,xt))),128))])])),64))])])):t.createCommentVNode("",!0),"week"===r.currentView?(t.openBlock(),t.createElementBlock("div",Ft,[t.createElementVNode("div",Mt,[n[15]||(n[15]=t.createElementVNode("div",{class:"week-time-label"},null,-1)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.weekDays,e=>(t.openBlock(),t.createElementBlock("div",{key:e.date,class:"week-day-header"},[t.createElementVNode("div",It,t.toDisplayString(e.name),1),t.createElementVNode("div",{class:t.normalizeClass(["day-number",{today:l.isToday(e.date)}])},t.toDisplayString(e.number),3)]))),128))]),t.createElementVNode("div",Ot,[(t.openBlock(),t.createElementBlock(t.Fragment,null,t.renderList(24,e=>t.createElementVNode("div",{key:e,class:"week-hour-row"},[t.createElementVNode("div",Lt,t.toDisplayString(l.formatHour(e-1)),1),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.weekDays,n=>(t.openBlock(),t.createElementBlock("div",{key:n.date,class:"week-hour-cell"},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.getEventsForHour(n.date,e-1),e=>(t.openBlock(),t.createElementBlock("div",{key:e.id,class:"event-card small",style:t.normalizeStyle({backgroundColor:e.color}),onClick:t=>l.editEvent(e)},[t.createElementVNode("div",_t,t.toDisplayString(e.name),1)],12,jt))),128))]))),128))])),64))])])):t.createCommentVNode("",!0),"month"===r.currentView?(t.openBlock(),t.createElementBlock("div",At,[t.createElementVNode("div",Pt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.dayNames,e=>(t.openBlock(),t.createElementBlock("div",{key:e,class:"month-day-name"},t.toDisplayString(e),1))),128))]),t.createElementVNode("div",$t,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.monthDays,e=>(t.openBlock(),t.createElementBlock("div",{key:e.date,class:t.normalizeClass(["month-day",{"other-month":!e.isCurrentMonth,today:l.isToday(e.date)}]),onClick:t=>l.selectDay(e.date)},[t.createElementVNode("div",Wt,t.toDisplayString(e.number),1),t.createElementVNode("div",Rt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.getEventsForDay(e.date).slice(0,3),e=>(t.openBlock(),t.createElementBlock("div",{key:e.id,class:"event-dot",style:t.normalizeStyle({backgroundColor:e.color}),title:e.name},null,12,Ht))),128)),l.getEventsForDay(e.date).length>3?(t.openBlock(),t.createElementBlock("div",Jt," +"+t.toDisplayString(l.getEventsForDay(e.date).length-3),1)):t.createCommentVNode("",!0)])],10,Ut))),128))])])):t.createCommentVNode("",!0)]),r.showEventModal?(t.openBlock(),t.createElementBlock("div",{key:0,class:"modal-overlay",onClick:n[14]||(n[14]=t.withModifiers((...e)=>l.closeModal&&l.closeModal(...e),["self"]))},[t.createElementVNode("div",Zt,[t.createElementVNode("div",qt,[t.createElementVNode("h3",null,t.toDisplayString(r.editingEvent?"Editar Evento":"Nuevo Evento"),1),t.createElementVNode("button",{onClick:n[4]||(n[4]=(...e)=>l.closeModal&&l.closeModal(...e)),class:"close-btn"},"✕")]),t.createElementVNode("div",Kt,[t.createElementVNode("div",Gt,[n[16]||(n[16]=t.createElementVNode("label",null,"Nombre del evento",-1)),t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[5]||(n[5]=e=>r.eventForm.name=e),type:"text",placeholder:"Ej: Reunión con el equipo"},null,512),[[t.vModelText,r.eventForm.name]])]),t.createElementVNode("div",Yt,[n[17]||(n[17]=t.createElementVNode("label",null,"Fecha",-1)),t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[6]||(n[6]=e=>r.eventForm.date=e),type:"date"},null,512),[[t.vModelText,r.eventForm.date]])]),t.createElementVNode("div",Qt,[t.createElementVNode("div",Xt,[n[18]||(n[18]=t.createElementVNode("label",null,"Hora de inicio",-1)),t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[7]||(n[7]=e=>r.eventForm.startTime=e),type:"time"},null,512),[[t.vModelText,r.eventForm.startTime]])]),t.createElementVNode("div",en,[n[19]||(n[19]=t.createElementVNode("label",null,"Hora de fin",-1)),t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[8]||(n[8]=e=>r.eventForm.endTime=e),type:"time"},null,512),[[t.vModelText,r.eventForm.endTime]])])]),t.createElementVNode("div",tn,[n[20]||(n[20]=t.createElementVNode("label",null,"Color",-1)),t.createElementVNode("div",nn,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.colors,e=>(t.openBlock(),t.createElementBlock("div",{key:e,class:t.normalizeClass(["color-option",{selected:r.eventForm.color===e}]),style:t.normalizeStyle({backgroundColor:e}),onClick:t=>r.eventForm.color=e},null,14,on))),128))])]),t.createElementVNode("div",an,[t.createElementVNode("label",rn,[t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[9]||(n[9]=e=>r.eventForm.isRecurring=e),type:"checkbox"},null,512),[[t.vModelCheckbox,r.eventForm.isRecurring]]),n[21]||(n[21]=t.createTextVNode(" Evento repetitivo ",-1))])]),r.eventForm.isRecurring?(t.openBlock(),t.createElementBlock("div",ln,[n[23]||(n[23]=t.createElementVNode("label",null,"Frecuencia",-1)),t.withDirectives(t.createElementVNode("select",{"onUpdate:modelValue":n[10]||(n[10]=e=>r.eventForm.recurringType=e)},n[22]||(n[22]=[t.createElementVNode("option",{value:"daily"},"Diario",-1),t.createElementVNode("option",{value:"weekly"},"Semanal",-1),t.createElementVNode("option",{value:"monthly"},"Mensual",-1)]),512),[[t.vModelSelect,r.eventForm.recurringType]])])):t.createCommentVNode("",!0)]),t.createElementVNode("div",sn,[r.editingEvent?(t.openBlock(),t.createElementBlock("button",{key:0,onClick:n[11]||(n[11]=(...e)=>l.deleteEvent&&l.deleteEvent(...e)),class:"delete-btn"},"Eliminar")):t.createCommentVNode("",!0),t.createElementVNode("button",{onClick:n[12]||(n[12]=(...e)=>l.closeModal&&l.closeModal(...e)),class:"cancel-btn"},"Cancelar"),t.createElementVNode("button",{onClick:n[13]||(n[13]=(...e)=>l.saveEvent&&l.saveEvent(...e)),class:"save-btn"},t.toDisplayString(r.editingEvent?"Guardar":"Crear"),1)])])])):t.createCommentVNode("",!0)],2)}],["__scopeId","data-v-b191092b"]]),dn={class:"weather-container"},un={class:"weather-widget"},mn={key:0,class:"weather-loading"},pn={key:1,class:"weather-error"},hn={key:2,class:"weather-content"},gn={class:"weather-header"},fn={class:"location"},vn={class:"location-name"},yn={class:"weather-main"},bn={class:"temperature"},kn={class:"temp-value"},wn={class:"weather-icon"},En={class:"weather-description"},Nn={class:"weather-details"},Cn={class:"detail-item"},Vn={class:"detail-value"},Sn={class:"detail-item"},Dn={class:"detail-value"},xn={class:"detail-item"},Bn={class:"detail-value"},Tn={class:"weather-footer"},zn={class:"last-update"};const Fn=m({name:"ZWeatherWidget",data:()=>({loading:!0,error:null,weatherData:null,locationName:"",latitude:null,longitude:null,lastUpdate:"",updateInterval:null}),mounted(){this.getLocation(),this.updateInterval=setInterval(()=>{this.latitude&&this.longitude&&this.fetchWeather(this.latitude,this.longitude)},6e5)},beforeUnmount(){this.updateInterval&&clearInterval(this.updateInterval)},methods:{getLocation(){if(this.loading=!0,this.error=null,!navigator.geolocation)return this.error="La geolocalización no está disponible en tu navegador",void(this.loading=!1);navigator.geolocation.getCurrentPosition(e=>{this.latitude=e.coords.latitude,this.longitude=e.coords.longitude,this.fetchWeather(this.latitude,this.longitude),this.fetchLocationName(this.latitude,this.longitude)},e=>{switch(this.loading=!1,e.code){case e.PERMISSION_DENIED:this.error="Permiso de ubicación denegado. Activa la ubicación para usar este widget.";break;case e.POSITION_UNAVAILABLE:this.error="Información de ubicación no disponible.";break;case e.TIMEOUT:this.error="Tiempo de espera agotado al obtener la ubicación.";break;default:this.error="Error desconocido al obtener la ubicación."}})},fetchWeather(e,t){return u(this,null,function*(){try{const n=`https://api.open-meteo.com/v1/forecast?latitude=${e}&longitude=${t}&current=temperature_2m,relative_humidity_2m,apparent_temperature,weather_code,wind_speed_10m&timezone=auto`,o=yield fetch(n);if(!o.ok)throw new Error("Error al obtener datos del clima");this.weatherData=yield o.json(),this.updateLastUpdateTime(),this.loading=!1}catch(n){this.error="No se pudo obtener la información del clima",this.loading=!1}})},fetchLocationName(e,t){return u(this,null,function*(){try{const n=this.generateCacheKey(e,t),o=this.getLocationFromCache(n);if(o)return this.locationName=o,void console.log("📦 Ubicación obtenida del cache:",o);console.log("🌐 Consultando Nominatim para ubicación...");const a=`https://nominatim.openstreetmap.org/reverse?format=json&lat=${e}&lon=${t}&zoom=10`,r=yield fetch(a,{headers:{"User-Agent":"ZenWDG-WeatherWidget/1.0"}});if(r.ok){const e=yield r.json(),t=e.address.city||e.address.town||e.address.village||e.address.state||"Tu ubicación";this.locationName=t,this.saveLocationToCache(n,t),console.log("💾 Ubicación guardada en cache:",t)}else this.locationName="Tu ubicación"}catch(n){this.locationName="Tu ubicación"}})},generateCacheKey:(e,t)=>`${Math.round(100*e)/100},${Math.round(100*t)/100}`,getLocationFromCache(e){try{const t=localStorage.getItem("weather_location_cache");if(!t)return null;const n=JSON.parse(t),o=n[e];if(!o)return null;const a=Date.now()-o.timestamp;return a>2592e6?(delete n[e],localStorage.setItem("weather_location_cache",JSON.stringify(n)),null):o.name}catch(t){return console.warn("Error al leer cache de ubicaciones:",t),null}},saveLocationToCache(e,t){try{let n={};const o=localStorage.getItem("weather_location_cache");o&&(n=JSON.parse(o)),n[e]={name:t,timestamp:Date.now()};const a=Object.entries(n);a.length>100&&(a.sort((e,t)=>t[1].timestamp-e[1].timestamp),n=Object.fromEntries(a.slice(0,100))),localStorage.setItem("weather_location_cache",JSON.stringify(n))}catch(n){console.warn("Error al guardar en cache de ubicaciones:",n)}},refreshWeather(){this.latitude&&this.longitude?(this.loading=!0,this.fetchWeather(this.latitude,this.longitude)):this.getLocation()},updateLastUpdateTime(){const e=new Date;this.lastUpdate=`${e.getHours().toString().padStart(2,"0")}:${e.getMinutes().toString().padStart(2,"0")}`},getWeatherIcon:e=>({0:"☀️",1:"🌤️",2:"⛅",3:"☁️",45:"🌫️",48:"🌫️",51:"🌦️",53:"🌦️",55:"🌧️",61:"🌧️",63:"🌧️",65:"🌧️",71:"🌨️",73:"🌨️",75:"❄️",77:"🌨️",80:"🌦️",81:"🌧️",82:"⛈️",85:"🌨️",86:"❄️",95:"⛈️",96:"⛈️",99:"⛈️"}[e]||"🌤️"),getWeatherDescription:e=>({0:"Cielo despejado",1:"Principalmente despejado",2:"Parcialmente nublado",3:"Nublado",45:"Niebla",48:"Niebla con escarcha",51:"Llovizna ligera",53:"Llovizna moderada",55:"Llovizna densa",61:"Lluvia ligera",63:"Lluvia moderada",65:"Lluvia fuerte",71:"Nevada ligera",73:"Nevada moderada",75:"Nevada fuerte",77:"Granizo",80:"Chubascos ligeros",81:"Chubascos moderados",82:"Chubascos violentos",85:"Chubascos de nieve ligeros",86:"Chubascos de nieve fuertes",95:"Tormenta eléctrica",96:"Tormenta con granizo ligero",99:"Tormenta con granizo fuerte"}[e]||"Condición desconocida")}},[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("div",dn,[t.createElementVNode("div",un,[r.loading?(t.openBlock(),t.createElementBlock("div",mn,n[2]||(n[2]=[t.createElementVNode("div",{class:"spinner"},null,-1),t.createElementVNode("p",null,"Obteniendo ubicación...",-1)]))):r.error?(t.openBlock(),t.createElementBlock("div",pn,[n[3]||(n[3]=t.createElementVNode("span",{class:"error-icon"},"⚠️",-1)),t.createElementVNode("p",null,t.toDisplayString(r.error),1),t.createElementVNode("button",{onClick:n[0]||(n[0]=(...e)=>l.getLocation&&l.getLocation(...e)),class:"retry-btn"},"Reintentar")])):r.weatherData?(t.openBlock(),t.createElementBlock("div",hn,[t.createElementVNode("div",gn,[t.createElementVNode("div",fn,[n[4]||(n[4]=t.createElementVNode("span",{class:"location-icon"},"📍",-1)),t.createElementVNode("span",vn,t.toDisplayString(r.locationName),1)])]),t.createElementVNode("div",yn,[t.createElementVNode("div",bn,[t.createElementVNode("span",kn,t.toDisplayString(Math.round(r.weatherData.current.temperature_2m)),1),n[5]||(n[5]=t.createElementVNode("span",{class:"temp-unit"},"°C",-1))]),t.createElementVNode("div",wn,t.toDisplayString(l.getWeatherIcon(r.weatherData.current.weather_code)),1)]),t.createElementVNode("div",En,t.toDisplayString(l.getWeatherDescription(r.weatherData.current.weather_code)),1),t.createElementVNode("div",Nn,[t.createElementVNode("div",Cn,[n[6]||(n[6]=t.createElementVNode("span",{class:"detail-icon"},"💨",-1)),n[7]||(n[7]=t.createElementVNode("span",{class:"detail-label"},"Viento",-1)),t.createElementVNode("span",Vn,t.toDisplayString(Math.round(r.weatherData.current.wind_speed_10m))+" km/h",1)]),t.createElementVNode("div",Sn,[n[8]||(n[8]=t.createElementVNode("span",{class:"detail-icon"},"💧",-1)),n[9]||(n[9]=t.createElementVNode("span",{class:"detail-label"},"Humedad",-1)),t.createElementVNode("span",Dn,t.toDisplayString(r.weatherData.current.relative_humidity_2m)+"%",1)]),t.createElementVNode("div",xn,[n[10]||(n[10]=t.createElementVNode("span",{class:"detail-icon"},"🌡️",-1)),n[11]||(n[11]=t.createElementVNode("span",{class:"detail-label"},"Sensación",-1)),t.createElementVNode("span",Bn,t.toDisplayString(Math.round(r.weatherData.current.apparent_temperature))+"°C",1)])]),t.createElementVNode("div",Tn,[t.createElementVNode("span",zn,"Actualizado: "+t.toDisplayString(r.lastUpdate),1),t.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>l.refreshWeather&&l.refreshWeather(...e)),class:"refresh-btn"},"🔄")])])):t.createCommentVNode("",!0)])])}],["__scopeId","data-v-5f11c261"]]),Mn={class:"notes-widget"},In={class:"notes-header"},On={class:"header-actions"},Ln={class:"modal-header"},jn={class:"modal-body"},_n={class:"category-form"},An={class:"categories-list"},Pn={class:"category-name"},$n=["onClick"],Un={key:0,class:"new-note-form"},Wn={class:"note-form-actions"},Rn=["value"],Hn={class:"form-buttons"},Jn={class:"notes-controls"},Zn={class:"filter-controls"},qn=["onClick"],Kn={class:"sort-controls"},Gn={class:"notes-list"},Yn={key:0,class:"empty-state"},Qn={class:"note-card-header"},Xn=["onClick"],eo=["onClick"],to={class:"note-title"},no={class:"note-content"},oo={class:"note-footer"},ao={class:"note-date"},ro={class:"notes-stats"},lo={key:0};const io=m({name:"ZNotesWidget",data:()=>({notes:[],categories:[{id:"default",name:"Sin categoría",color:"#6b7280"}],showNewNoteForm:!1,showCategoryManager:!1,newNote:{title:"",content:"",categoryId:""},newCategoryName:"",newCategoryColor:"#3b82f6",filterCategory:null,sortBy:"date",storageKey:"zen-notes-widget",categoriesKey:"zen-notes-categories"}),computed:{filteredNotes(){let e=[...this.notes];return"pinned"===this.filterCategory?e=e.filter(e=>e.isPinned):this.filterCategory&&(e=e.filter(e=>e.categoryId===this.filterCategory)),e.sort((e,t)=>{if("date"===this.sortBy)return new Date(t.createdAt)-new Date(e.createdAt);if("title"===this.sortBy)return(e.title||"").localeCompare(t.title||"");if("category"===this.sortBy){const n=this.getCategoryName(e.categoryId),o=this.getCategoryName(t.categoryId);return n.localeCompare(o)}return 0}),e.sort((e,t)=>e.isPinned&&!t.isPinned?-1:!e.isPinned&&t.isPinned?1:0)},pinnedNotesCount(){return this.notes.filter(e=>e.isPinned).length}},methods:{toggleNewNote(){this.showNewNoteForm=!this.showNewNoteForm,this.showNewNoteForm&&this.$nextTick(()=>{var e;null==(e=this.$refs.titleInput)||e.focus()})},saveNote(){if(!this.newNote.content.trim())return;const e={id:Date.now().toString(),title:this.newNote.title.trim(),content:this.newNote.content.trim(),categoryId:this.newNote.categoryId,isPinned:!1,createdAt:(new Date).toISOString()};this.notes.unshift(e),this.saveToStorage(),this.cancelNewNote()},cancelNewNote(){this.newNote={title:"",content:"",categoryId:""},this.showNewNoteForm=!1},deleteNote(e){return u(this,null,function*(){(yield window.ZenModals.showDeleteConfirm("esta nota"))&&(this.notes=this.notes.filter(t=>t.id!==e),this.saveToStorage())})},togglePin(e){const t=this.notes.find(t=>t.id===e);t&&(t.isPinned=!t.isPinned,this.saveToStorage())},addCategory(){if(!this.newCategoryName.trim())return;const e={id:Date.now().toString(),name:this.newCategoryName.trim(),color:this.newCategoryColor};this.categories.push(e),this.saveCategoriesToStorage(),this.newCategoryName="",this.newCategoryColor="#3b82f6"},deleteCategory(e){return u(this,null,function*(){(yield window.ZenModals.showConfirm({title:"¿Eliminar categoría?",message:"Las notas de esta categoría no se eliminarán, solo la categoría.",confirmText:"Eliminar",cancelText:"Cancelar",confirmButtonClass:"danger"}))&&(this.categories=this.categories.filter(t=>t.id!==e),this.saveCategoriesToStorage())})},getCategoryName(e){const t=this.categories.find(t=>t.id===e);return t?t.name:"Sin categoría"},getCategoryColor(e){const t=this.categories.find(t=>t.id===e);return t?t.color:"#6b7280"},getNoteColor(e){return e.categoryId?this.getCategoryColor(e.categoryId):"#6b7280"},formatDate(e){const t=new Date(e),n=new Date,o=n-t,a=Math.floor(o/864e5);if(0===a){const e=Math.floor(o/36e5);if(0===e){const e=Math.floor(o/6e4);return 0===e?"Ahora":`Hace ${e}m`}return`Hace ${e}h`}return 1===a?"Ayer":a<7?`Hace ${a} días`:t.toLocaleDateString("es-ES",{day:"numeric",month:"short",year:t.getFullYear()!==n.getFullYear()?"numeric":void 0})},exportNotes(){if(0===this.notes.length)return void alert("No hay notas para exportar");let e="# MIS NOTAS\n";e+=`# Exportado el ${(new Date).toLocaleString("es-ES")}\n\n`,e+="═".repeat(60)+"\n\n";const t={};this.notes.forEach(e=>{const n=this.getCategoryName(e.categoryId);t[n]||(t[n]=[]),t[n].push(e)}),Object.keys(t).sort().forEach(n=>{e+=`## 🏷️ ${n.toUpperCase()}\n`,e+="─".repeat(60)+"\n\n",t[n].forEach(t=>{e+=`### ${t.title||"Sin título"}`,t.isPinned&&(e+=" 📌"),e+="\n",e+=`Fecha: ${new Date(t.createdAt).toLocaleString("es-ES")}\n\n`,e+=`${t.content}\n\n`,e+="─".repeat(60)+"\n\n"})}),e+="\n═".repeat(60)+"\n",e+=`Total de notas: ${this.notes.length}\n`,e+=`Notas fijadas: ${this.pinnedNotesCount}\n`;const n=new Blob([e],{type:"text/plain;charset=utf-8"}),o=URL.createObjectURL(n),a=document.createElement("a");a.href=o,a.download=`notas_${(new Date).toISOString().split("T")[0]}.txt`,document.body.appendChild(a),a.click(),document.body.removeChild(a),URL.revokeObjectURL(o),alert("✅ Notas exportadas exitosamente")},saveToStorage(){try{localStorage.setItem(this.storageKey,JSON.stringify(this.notes))}catch(Co){console.error("Error al guardar notas:",Co)}},loadFromStorage(){try{const e=localStorage.getItem(this.storageKey);e&&(this.notes=JSON.parse(e))}catch(Co){console.error("Error al cargar notas:",Co)}},saveCategoriesToStorage(){try{localStorage.setItem(this.categoriesKey,JSON.stringify(this.categories))}catch(Co){console.error("Error al guardar categorías:",Co)}},loadCategoriesFromStorage(){try{const e=localStorage.getItem(this.categoriesKey);if(e){const t=JSON.parse(e);t.find(e=>"default"===e.id)||t.unshift({id:"default",name:"Sin categoría",color:"#6b7280"}),this.categories=t}}catch(Co){console.error("Error al cargar categorías:",Co)}}},mounted(){this.loadCategoriesFromStorage(),this.loadFromStorage()}},[["render",function(e,n,o,a,r,l){return t.openBlock(),t.createElementBlock("div",Mn,[t.createElementVNode("div",In,[n[19]||(n[19]=t.createElementVNode("h2",{class:"notes-title"},"📝 Notas",-1)),t.createElementVNode("div",On,[t.createElementVNode("button",{onClick:n[0]||(n[0]=e=>r.showCategoryManager=!r.showCategoryManager),class:"icon-btn",title:"Gestionar Categorías"}," 🏷️ "),t.createElementVNode("button",{onClick:n[1]||(n[1]=(...e)=>l.exportNotes&&l.exportNotes(...e)),class:"icon-btn",title:"Exportar Notas"}," 💾 "),t.createElementVNode("button",{onClick:n[2]||(n[2]=(...e)=>l.toggleNewNote&&l.toggleNewNote(...e)),class:"icon-btn add-btn",title:"Nueva Nota"}," ➕ ")])]),t.createVNode(t.Transition,{name:"modal"},{default:t.withCtx(()=>[r.showCategoryManager?(t.openBlock(),t.createElementBlock("div",{key:0,class:"modal-overlay",onClick:n[9]||(n[9]=e=>r.showCategoryManager=!1)},[t.createElementVNode("div",{class:"modal-content",onClick:n[8]||(n[8]=t.withModifiers(()=>{},["stop"]))},[t.createElementVNode("div",Ln,[n[20]||(n[20]=t.createElementVNode("h3",null,"🏷️ Gestionar Categorías",-1)),t.createElementVNode("button",{onClick:n[3]||(n[3]=e=>r.showCategoryManager=!1),class:"close-btn"},"✕")]),t.createElementVNode("div",jn,[t.createElementVNode("div",_n,[t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[4]||(n[4]=e=>r.newCategoryName=e),onKeypress:n[5]||(n[5]=t.withKeys((...e)=>l.addCategory&&l.addCategory(...e),["enter"])),placeholder:"Nombre de categoría",class:"category-input"},null,544),[[t.vModelText,r.newCategoryName]]),t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[6]||(n[6]=e=>r.newCategoryColor=e),type:"color",class:"color-picker"},null,512),[[t.vModelText,r.newCategoryColor]]),t.createElementVNode("button",{onClick:n[7]||(n[7]=(...e)=>l.addCategory&&l.addCategory(...e)),class:"add-category-btn"},"Agregar")]),t.createElementVNode("div",An,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.categories,e=>(t.openBlock(),t.createElementBlock("div",{key:e.id,class:"category-item"},[t.createElementVNode("span",{class:"category-color-preview",style:t.normalizeStyle({backgroundColor:e.color})},null,4),t.createElementVNode("span",Pn,t.toDisplayString(e.name),1),"default"!==e.id?(t.openBlock(),t.createElementBlock("button",{key:0,onClick:t=>l.deleteCategory(e.id),class:"delete-category-btn",title:"Eliminar"}," 🗑️ ",8,$n)):t.createCommentVNode("",!0)]))),128))])])])])):t.createCommentVNode("",!0)]),_:1}),t.createVNode(t.Transition,{name:"slide"},{default:t.withCtx(()=>[r.showNewNoteForm?(t.openBlock(),t.createElementBlock("div",Un,[t.withDirectives(t.createElementVNode("input",{"onUpdate:modelValue":n[10]||(n[10]=e=>r.newNote.title=e),placeholder:"Título de la nota...",class:"note-title-input",ref:"titleInput"},null,512),[[t.vModelText,r.newNote.title]]),t.withDirectives(t.createElementVNode("textarea",{"onUpdate:modelValue":n[11]||(n[11]=e=>r.newNote.content=e),placeholder:"Escribe tu nota aquí...",class:"note-content-input",rows:"4"},null,512),[[t.vModelText,r.newNote.content]]),t.createElementVNode("div",Wn,[t.withDirectives(t.createElementVNode("select",{"onUpdate:modelValue":n[12]||(n[12]=e=>r.newNote.categoryId=e),class:"category-select"},[n[21]||(n[21]=t.createElementVNode("option",{value:""},"Sin categoría",-1)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.categories.filter(e=>"default"!==e.id),e=>(t.openBlock(),t.createElementBlock("option",{key:e.id,value:e.id},t.toDisplayString(e.name),9,Rn))),128))],512),[[t.vModelSelect,r.newNote.categoryId]]),t.createElementVNode("div",Hn,[t.createElementVNode("button",{onClick:n[13]||(n[13]=(...e)=>l.cancelNewNote&&l.cancelNewNote(...e)),class:"cancel-btn"},"Cancelar"),t.createElementVNode("button",{onClick:n[14]||(n[14]=(...e)=>l.saveNote&&l.saveNote(...e)),class:"save-btn"},"Guardar")])])])):t.createCommentVNode("",!0)]),_:1}),t.createElementVNode("div",Jn,[t.createElementVNode("div",Zn,[t.createElementVNode("button",{onClick:n[15]||(n[15]=e=>r.filterCategory=null),class:t.normalizeClass(["filter-btn",{active:null===r.filterCategory}])}," 📋 Todas ",2),t.createElementVNode("button",{onClick:n[16]||(n[16]=e=>r.filterCategory="pinned"),class:t.normalizeClass(["filter-btn",{active:"pinned"===r.filterCategory}])}," 📌 Fijadas ",2),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.categories.filter(e=>"default"!==e.id),e=>(t.openBlock(),t.createElementBlock("button",{key:e.id,onClick:t=>r.filterCategory=e.id,class:t.normalizeClass(["filter-btn",{active:r.filterCategory===e.id}]),style:t.normalizeStyle({borderColor:e.color,color:r.filterCategory===e.id?e.color:""})},t.toDisplayString(e.name),15,qn))),128))]),t.createElementVNode("div",Kn,[t.withDirectives(t.createElementVNode("select",{"onUpdate:modelValue":n[17]||(n[17]=e=>r.sortBy=e),class:"sort-select"},n[22]||(n[22]=[t.createElementVNode("option",{value:"date"},"📅 Fecha",-1),t.createElementVNode("option",{value:"title"},"🔤 Título",-1),t.createElementVNode("option",{value:"category"},"🏷️ Categoría",-1)]),512),[[t.vModelSelect,r.sortBy]])])]),t.createElementVNode("div",Gn,[0===l.filteredNotes.length?(t.openBlock(),t.createElementBlock("div",Yn,[n[23]||(n[23]=t.createElementVNode("div",{class:"empty-icon"},"📭",-1)),n[24]||(n[24]=t.createElementVNode("p",null,"No hay notas",-1)),t.createElementVNode("button",{onClick:n[18]||(n[18]=(...e)=>l.toggleNewNote&&l.toggleNewNote(...e)),class:"create-first-note-btn"}," Crear primera nota ")])):t.createCommentVNode("",!0),t.createVNode(t.TransitionGroup,{name:"note-list",tag:"div",class:"notes-grid"},{default:t.withCtx(()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(l.filteredNotes,e=>(t.openBlock(),t.createElementBlock("div",{key:e.id,class:t.normalizeClass(["note-card",{pinned:e.isPinned}]),style:t.normalizeStyle({borderLeftColor:l.getNoteColor(e)})},[t.createElementVNode("div",Qn,[t.createElementVNode("button",{onClick:t=>l.togglePin(e.id),class:t.normalizeClass(["pin-btn",{pinned:e.isPinned}]),title:"Fijar/Desfijar"},t.toDisplayString(e.isPinned?"📌":"📍"),11,Xn),t.createElementVNode("button",{onClick:t=>l.deleteNote(e.id),class:"delete-btn",title:"Eliminar"}," 🗑️ ",8,eo)]),t.createElementVNode("h3",to,t.toDisplayString(e.title||"Sin título"),1),t.createElementVNode("p",no,t.toDisplayString(e.content),1),t.createElementVNode("div",oo,[e.categoryId?(t.openBlock(),t.createElementBlock("span",{key:0,class:"note-category",style:t.normalizeStyle({backgroundColor:l.getCategoryColor(e.categoryId),color:"white"})},t.toDisplayString(l.getCategoryName(e.categoryId)),5)):t.createCommentVNode("",!0),t.createElementVNode("span",ao,t.toDisplayString(l.formatDate(e.createdAt)),1)])],6))),128))]),_:1})]),t.createElementVNode("div",ro,[t.createElementVNode("span",null,"Total: "+t.toDisplayString(r.notes.length)+" notas",1),l.pinnedNotesCount>0?(t.openBlock(),t.createElementBlock("span",lo,"📌 "+t.toDisplayString(l.pinnedNotesCount)+" fijadas",1)):t.createCommentVNode("",!0)])])}],["__scopeId","data-v-7326bacf"]]);const so=new class{constructor(){this.currentModal=null,this.resolveCallback=null,this.rejectCallback=null}createModalHTML(e){const{title:t="",message:n="",type:o="confirm",confirmText:a="Confirmar",cancelText:r="Cancelar",showCancel:l=!0,showIcon:i=!0,inputLabel:s="",inputPlaceholder:c="",inputType:d="text",inputDefaultValue:u="",confirmButtonClass:m=""}=e,p={confirm:"⚠️",success:"✅",error:"❌",info:"ℹ️",warning:"⚠️",prompt:""};return`\n <div class="z-modal-overlay" data-action="overlay">\n <div class="z-modal-container ${{confirm:"modal-bg-confirm",prompt:"modal-bg-prompt",success:"modal-bg-success",error:"modal-bg-error",warning:"modal-bg-warning",info:"modal-bg-info"}[o]} z-modal-size-medium">\n ${t?`\n <div class="z-modal-header">\n <h3 class="z-modal-title">${t}</h3>\n <button class="z-modal-close" data-action="close" aria-label="Cerrar">\n <svg width="20" height="20" viewBox="0 0 20 20" fill="none">\n <path d="M15 5L5 15M5 5l10 10" stroke="currentColor" stroke-width="2" stroke-linecap="round"/>\n </svg>\n </button>\n </div>\n `:""}\n \n <div class="z-modal-body">\n ${i&&p[o]?`<div class="z-modal-icon">${p[o]}</div>`:""}\n ${n?`<p class="z-modal-message">${n}</p>`:""}\n ${"prompt"===o?`\n <div class="z-modal-input-group">\n ${s?`<label class="z-modal-label">${s}</label>`:""}\n <input \n type="${d}" \n class="z-modal-input" \n placeholder="${c}"\n value="${u}"\n id="z-modal-input"\n />\n </div>\n `:""}\n </div>\n \n <div class="z-modal-footer">\n ${l?`<button class="z-modal-btn z-modal-btn-cancel" data-action="cancel">${r}</button>`:""}\n <button class="z-modal-btn z-modal-btn-confirm ${m}" data-action="confirm">\n ${a}\n </button>\n </div>\n </div>\n </div>\n `}show(e){return new Promise((t,n)=>{this.currentModal&&this.close(),this.resolveCallback=t,this.rejectCallback=n;const o=document.createElement("div");o.innerHTML=this.createModalHTML(e),this.currentModal=o.firstElementChild,document.body.appendChild(this.currentModal),this.injectStyles(),this.setupEventListeners(e.type),requestAnimationFrame(()=>{this.currentModal.classList.add("z-modal-show")}),"prompt"===e.type&&setTimeout(()=>{const e=document.getElementById("z-modal-input");e&&e.focus()},100)})}setupEventListeners(e){const t=t=>{var n;const o=null==(n=t.target.closest("[data-action]"))?void 0:n.dataset.action;if("confirm"===o)if("prompt"===e){const e=document.getElementById("z-modal-input");this.resolve(e?e.value:"")}else this.resolve(!0);else("cancel"===o||"close"===o||"overlay"===o)&&this.resolve(!1)},n=t=>{if("Escape"===t.key)this.resolve(!1);else if("Enter"===t.key&&"prompt"===e){const e=document.getElementById("z-modal-input");this.resolve(e?e.value:"")}};this.currentModal.addEventListener("click",t),document.addEventListener("keydown",n),this.currentModal._handleClick=t,this.currentModal._handleKeydown=n}resolve(e){this.resolveCallback&&this.resolveCallback(e),this.close()}close(){this.currentModal&&(this.currentModal._handleClick&&this.currentModal.removeEventListener("click",this.currentModal._handleClick),this.currentModal._handleKeydown&&document.removeEventListener("keydown",this.currentModal._handleKeydown),this.currentModal.classList.remove("z-modal-show"),setTimeout(()=>{this.currentModal&&this.currentModal.parentNode&&this.currentModal.parentNode.removeChild(this.currentModal),this.currentModal=null,this.resolveCallback=null,this.rejectCallback=null},300))}injectStyles(){if(document.getElementById("z-modal-styles"))return;const e=document.createElement("style");e.id="z-modal-styles",e.textContent="\n .z-modal-overlay {\n position: fixed;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background: rgba(0, 0, 0, 0.6);\n backdrop-filter: blur(8px);\n -webkit-backdrop-filter: blur(8px);\n display: flex;\n align-items: center;\n justify-content: center;\n z-index: 99999;\n padding: 20px;\n opacity: 0;\n transition: opacity 0.3s ease;\n }\n\n .z-modal-overlay.z-modal-show {\n opacity: 1;\n }\n\n .z-modal-overlay.z-modal-show .z-modal-container {\n transform: translateY(0) scale(1);\n opacity: 1;\n }\n\n .z-modal-container {\n background: rgba(30, 30, 35, 0.95);\n backdrop-filter: blur(20px) saturate(180%);\n -webkit-backdrop-filter: blur(20px) saturate(180%);\n border: 1px solid rgba(255, 255, 255, 0.3);\n border-radius: 20px;\n box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);\n max-width: 90vw;\n max-height: 90vh;\n overflow: hidden;\n display: flex;\n flex-direction: column;\n color: #fff;\n transform: translateY(-30px) scale(0.95);\n opacity: 0;\n transition: all 0.3s ease;\n }\n\n .z-modal-size-medium {\n width: 450px;\n }\n\n .z-modal-bg-success {\n background: rgba(16, 185, 129, 0.95);\n }\n\n .z-modal-bg-error, .z-modal-bg-warning {\n background: rgba(239, 68, 68, 0.95);\n }\n\n .z-modal-bg-info {\n background: rgba(59, 130, 246, 0.95);\n }\n\n .z-modal-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 24px 24px 16px 24px;\n border-bottom: 1px solid rgba(255, 255, 255, 0.1);\n }\n\n .z-modal-title {\n margin: 0;\n font-size: 1.25rem;\n font-weight: 600;\n }\n\n .z-modal-close {\n background: none;\n border: none;\n width: 32px;\n height: 32px;\n border-radius: 8px;\n display: flex;\n align-items: center;\n justify-content: center;\n cursor: pointer;\n color: currentColor;\n transition: all 0.2s ease;\n opacity: 0.7;\n }\n\n .z-modal-close:hover {\n background: rgba(255, 255, 255, 0.1);\n opacity: 1;\n }\n\n .z-modal-body {\n padding: 24px;\n text-align: center;\n }\n\n .z-modal-icon {\n font-size: 3rem;\n margin-bottom: 16px;\n animation: z-modal-icon-bounce 0.5s ease-out;\n }\n\n @keyframes z-modal-icon-bounce {\n 0% { transform: scale(0); }\n 50% { transform: scale(1.1); }\n 100% { transform: scale(1); }\n }\n\n .z-modal-message {\n margin: 0;\n font-size: 1rem;\n line-height: 1.6;\n opacity: 0.95;\n }\n\n .z-modal-input-group {\n margin-top: 20px;\n text-align: left;\n }\n\n .z-modal-label {\n display: block;\n margin-bottom: 8px;\n font-size: 0.9rem;\n font-weight: 500;\n opacity: 0.9;\n }\n\n .z-modal-input {\n width: 100%;\n padding: 12px 16px;\n border: 1px solid rgba(255, 255, 255, 0.2);\n border-radius: 10px;\n background: rgba(255, 255, 255, 0.1);\n color: #fff;\n font-size: 1rem;\n transition: all 0.2s ease;\n box-sizing: border-box;\n }\n\n .z-modal-input:focus {\n outline: none;\n border-color: rgba(255, 255, 255, 0.4);\n background: rgba(255, 255, 255, 0.15);\n }\n\n .z-modal-input::placeholder {\n color: rgba(255, 255, 255, 0.5);\n }\n\n .z-modal-footer {\n display: flex;\n gap: 12px;\n padding: 16px 24px 24px 24px;\n justify-content: flex-end;\n }\n\n .z-modal-btn {\n padding: 12px 24px;\n border: none;\n border-radius: 10px;\n font-size: 1rem;\n font-weight: 500;\n cursor: pointer;\n transition: all 0.2s ease;\n min-width: 100px;\n }\n\n .z-modal-btn-cancel {\n background: rgba(255, 255, 255, 0.1);\n color: currentColor;\n border: 1px solid rgba(255, 255, 255, 0.2);\n }\n\n .z-modal-btn-cancel:hover {\n background: rgba(255, 255, 255, 0.2);\n transform: translateY(-1px);\n }\n\n .z-modal-btn-confirm {\n background: rgba(255, 255, 255, 0.9);\n color: #1a1a1a;\n }\n\n .z-modal-btn-confirm:hover {\n background: #fff;\n transform: translateY(-1px);\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);\n }\n\n .z-modal-btn-confirm.danger {\n background: #ef4444;\n color: white;\n }\n\n .z-modal-btn-confirm.danger:hover {\n background: #dc2626;\n }\n\n @media (max-width: 768px) {\n .z-modal-container {\n width: 100% !important;\n max-width: 400px;\n }\n\n .z-modal-footer {\n flex-direction: column-reverse;\n }\n\n .z-modal-btn {\n width: 100%;\n }\n }\n ",document.head.appendChild(e)}};function co(e={}){return so.show(c({type:"confirm",showCancel:!0,showIcon:!0,confirmText:"Confirmar",cancelText:"Cancelar"},e))}function uo(e={}){const t=e,{type:n="info"}=t,o=((e,t)=>{var n={};for(var o in e)l.call(e,o)&&t.indexOf(o)<0&&(n[o]=e[o]);if(null!=e&&r)for(var o of r(e))t.indexOf(o)<0&&i.call(e,o)&&(n[o]=e[o]);return n})(t,["type"]);return so.show(c({type:n,showCancel:!1,showIcon:!0,confirmText:"Entendido"},o))}function mo(e={}){return so.show(c({type:"prompt",showCancel:!0,showIcon:!1,confirmText:"Aceptar",cancelText:"Cancelar",inputType:"text",inputDefaultValue:""},e))}function po(e={}){return uo(c({type:"success",title:"¡Éxito!",message:"Operación completada correctamente"},e))}function ho(e={}){return uo(c({type:"error",title:"Error",message:"Ha ocurrido un error"},e))}function go(e={}){return uo(c({type:"warning",title:"Advertencia"},e))}function fo(e="este elemento"){return co({title:"¿Eliminar?",message:`¿Estás seguro de que deseas eliminar ${e}?`,confirmText:"Eliminar",cancelText:"Cancelar",confirmButtonClass:"danger"})}"undefined"!=typeof window&&(window.ZenModals={showConfirm:co,showAlert:uo,showPrompt:mo,showSuccess:po,showError:ho,showWarning:go,showDeleteConfirm:fo});const vo=t.defineCustomElement(v),yo=t.defineCustomElement(Ze),bo=t.defineCustomElement(at),ko=t.defineCustomElement(ft),wo=t.defineCustomElement(cn),Eo=t.defineCustomElement(Fn),No=t.defineCustomElement(io);customElements.get("z-clock-widget")||customElements.define("z-clock-widget",vo),customElements.get("z-search-widget")||customElements.define("z-search-widget",yo),customElements.get("z-todo-widget")||customElements.define("z-todo-widget",bo),customElements.get("z-marked-widget")||customElements.define("z-marked-widget",ko),customElements.get("z-calendar-widget")||customElements.define("z-calendar-widget",wo),customElements.get("z-weather-widget")||customElements.define("z-weather-widget",Eo),customElements.get("z-notes-widget")||customElements.define("z-notes-widget",No),e.ZCalendarWidget=cn,e.ZClockWidget=v,e.ZMarkedWidget=ft,e.ZNotesWidget=io,e.ZSearchWidget=Ze,e.ZTodoWidget=at,e.ZWeatherWidget=Fn,e.showAlert=uo,e.showConfirm=co,e.showDeleteConfirm=fo,e.showError=ho,e.showPrompt=mo,e.showSuccess=po,e.showWarning=go,Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "zen-wdg",
3
- "version": "2.2.7",
3
+ "version": "2.3.0",
4
4
  "description": "Minimal widget library for Gridstack-based newtab extensions",
5
5
  "main": "dist/zen-wdg.umd.js",
6
6
  "module": "dist/zen-wdg.es.js",
package/src/index.js CHANGED
@@ -3,12 +3,21 @@ import ZClockWidget from './widgets/z-clock-widget.vue'
3
3
  import ZSearchWidget from './widgets/z-search-widget.vue'
4
4
  import ZTodoWidget from './widgets/z-todo-widget.vue'
5
5
  import ZMarkedWidget from './widgets/z-marked-widget.vue'
6
+ import ZCalendarWidget from './widgets/z-calendar-widget.vue'
7
+ import ZWeatherWidget from './widgets/z-weather-widget.vue'
8
+ import ZNotesWidget from './widgets/z-notes-widget.vue'
9
+
10
+ // Import modal system to register globally (vanilla JS compatible)
11
+ import './utils/modalManager'
6
12
 
7
13
  // Crear el custom element
8
14
  const ZClockElement = defineCustomElement(ZClockWidget)
9
15
  const ZSearchElement = defineCustomElement(ZSearchWidget)
10
16
  const ZTodoElement = defineCustomElement(ZTodoWidget)
11
17
  const ZMarkedElement = defineCustomElement(ZMarkedWidget)
18
+ const ZCalendarElement = defineCustomElement(ZCalendarWidget)
19
+ const ZWeatherElement = defineCustomElement(ZWeatherWidget)
20
+ const ZNotesElement = defineCustomElement(ZNotesWidget)
12
21
 
13
22
  // Registrar custom element (evitar doble registro)
14
23
  if (!customElements.get('z-clock-widget')) {
@@ -27,5 +36,28 @@ if (!customElements.get('z-marked-widget')) {
27
36
  customElements.define('z-marked-widget', ZMarkedElement)
28
37
  }
29
38
 
30
- // Exportar el componente para uso tradicional Vue
31
- export { ZClockWidget, ZSearchWidget, ZTodoWidget, ZMarkedWidget }
39
+ if (!customElements.get('z-calendar-widget')) {
40
+ customElements.define('z-calendar-widget', ZCalendarElement)
41
+ }
42
+
43
+ if (!customElements.get('z-weather-widget')) {
44
+ customElements.define('z-weather-widget', ZWeatherElement)
45
+ }
46
+
47
+ if (!customElements.get('z-notes-widget')) {
48
+ customElements.define('z-notes-widget', ZNotesElement)
49
+ }
50
+
51
+ // Exportar componentes
52
+ export { ZClockWidget, ZSearchWidget, ZTodoWidget, ZMarkedWidget, ZCalendarWidget, ZWeatherWidget, ZNotesWidget }
53
+
54
+ // Exportar sistema de modales (vanilla JS compatible)
55
+ export {
56
+ showConfirm,
57
+ showAlert,
58
+ showPrompt,
59
+ showSuccess,
60
+ showError,
61
+ showWarning,
62
+ showDeleteConfirm
63
+ } from './utils/modalManager'