@sevn/elections-components 1.0.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.
Files changed (35) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +297 -0
  3. package/dist/index.cjs +603 -0
  4. package/dist/index.cjs.map +1 -0
  5. package/dist/index.d.cts +351 -0
  6. package/dist/index.d.ts +351 -0
  7. package/dist/index.js +15609 -0
  8. package/dist/index.js.map +1 -0
  9. package/dist/styles.css +38 -0
  10. package/dist/umd/candidate-by-state.js +98 -0
  11. package/dist/umd/candidate-carrousel-state-results-viewer.js +108 -0
  12. package/dist/umd/candidate-counting-progress.js +77 -0
  13. package/dist/umd/candidate-duel-state-result-viewer.js +91 -0
  14. package/dist/umd/candidate-map-by-state.js +104 -0
  15. package/dist/umd/candidate-multi-ring-chart-performance-by-municipality.js +105 -0
  16. package/dist/umd/candidate-performance-by-municipality.js +105 -0
  17. package/dist/umd/candidate-ranking.js +59 -0
  18. package/dist/umd/candidate-results-by-municipality.js +103 -0
  19. package/dist/umd/counting-progress.js +125 -0
  20. package/dist/umd/current-leader.js +43 -0
  21. package/dist/umd/election-round-analysis.js +100 -0
  22. package/dist/umd/election-status.js +135 -0
  23. package/dist/umd/final-results.js +141 -0
  24. package/dist/umd/live-summary.js +36 -0
  25. package/dist/umd/municipality-perfomance-map.js +82 -0
  26. package/dist/umd/party-performance.js +99 -0
  27. package/dist/umd/results-by-office.js +94 -0
  28. package/dist/umd/round-results-analysis.js +99 -0
  29. package/dist/umd/state-leaders.js +118 -0
  30. package/dist/umd/state-winners.js +129 -0
  31. package/dist/umd/top-dispute.js +43 -0
  32. package/dist/umd/vote-comparison-by-round.js +76 -0
  33. package/dist/umd/vote-counting-progress.js +23 -0
  34. package/dist/umd/voting-map.js +112 -0
  35. package/package.json +96 -0
@@ -0,0 +1,118 @@
1
+ (function(re,ne){typeof exports=="object"&&typeof module<"u"?module.exports=ne():typeof define=="function"&&define.amd?define(ne):(re=typeof globalThis<"u"?globalThis:re||self,re.StateLeaders=ne())})(this,(function(){"use strict";var xc=Object.defineProperty;var Mi=re=>{throw TypeError(re)};var Cc=(re,ne,ve)=>ne in re?xc(re,ne,{enumerable:!0,configurable:!0,writable:!0,value:ve}):re[ne]=ve;var ht=(re,ne,ve)=>Cc(re,typeof ne!="symbol"?ne+"":ne,ve),Un=(re,ne,ve)=>ne.has(re)||Mi("Cannot "+ve);var u=(re,ne,ve)=>(Un(re,ne,"read from private field"),ve?ve.call(re):ne.get(re)),Y=(re,ne,ve)=>ne.has(re)?Mi("Cannot add the same private member more than once"):ne instanceof WeakSet?ne.add(re):ne.set(re,ve),B=(re,ne,ve,ar)=>(Un(re,ne,"write to private field"),ar?ar.call(re,ve):ne.set(re,ve),ve),ye=(re,ne,ve)=>(Un(re,ne,"access private method"),ve);var gr,_r,$t,mr,Dr,Ir,er,Ct,wr,Fe,Vn,Kn,Gn,Li,nt,Nn,zt,tr,ct,dt,He,ft,St,rr,Dt,br,yr,xr,kt,tn,we,zc,Sc,Yn,an,on,Wn,at,vt,Be,nr,Nr,qr,rn,ki;class re extends Error{constructor(){super('Chave de acesso não configurada. Chame Core.applyKey("sua-chave") antes de montar o componente, ou carregue o script com ?cid=sua-chave.'),this.name="SevnKeyMissingError"}}class ne extends Error{constructor(e,r){super(`Não foi possível contatar a API para ${e}.`),this.name="SevnNetworkError",this.cause=r}}const ve="__sevnElectionsState_v1__",ar=globalThis;function Zn(t){return ar[ve]||(ar[ve]={config:t(),transport:{activeIndex:0,pinnedAt:0}}),ar[ve]}const Ri="https://failover-api.sevntech.com",ji=/^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?$/i;function Jn(){return{key:null,apiHosts:[],assetsBase:"https://cdn.sevnelections.com/static",assetsVersion:"v1",cache:{storageKey:"election_cache",maxEntries:200},request:{timeoutMs:8e3,retriesPerHost:3,retryDelayMs:300,stickyWindowMs:12e4},theme:null}}const Oi=Jn;function ir(){return Zn(Jn)}function Pi(t){return[`https://${t}-api1.sevnelections.com`,`https://${t}-api2.sevnelections.com`,Ri]}function sn(t){if(typeof t!="string"||!ji.test(t))throw new Error(`[sevn] Chave inválida: ${JSON.stringify(t)}. Use apenas letras, números e hífen (a chave vira subdomínio da API).`);const e=ir();e.config.key=t,e.config.apiHosts=Pi(t)}function Xn(t){const{cache:e,request:r,key:n,...a}=t,i=ir();i.config={...i.config,...a,cache:{...i.config.cache,...e},request:{...i.config.request,...r}},n&&(sn(n),a.apiHosts&&(i.config.apiHosts=a.apiHosts))}function zr(){return ir().config}function Qn(){return ir().config.apiHosts.length>0}function $n(){if(!Qn())throw new re;return ir().config.apiHosts}function ln(t){const{assetsBase:e,assetsVersion:r}=ir().config,n=e.replace(/\/+$/,""),a=String(t).replace(/^\/+/,"");return`${n}/${r}/${a}`}const Di=':root{--sevn-color-primary: #0a3e27;--sevn-color-secondary: #c38214;--sevn-color-tertiary: #1c1c1c;--sevn-color-red: #da0000;--sevn-color-yellow: #e4a615;--sevn-color-green: #1e6704;--sevn-color-blue: #0e2a41;--sevn-color-neutral: #f2f2f7;--sevn-color-text-secondary: #6b7280}[class^=sevn_],[class*=" sevn_"],[class^=sevn_] *,[class^=sevn_] *:before,[class^=sevn_] *:after,[class*=" sevn_"] *,[class*=" sevn_"] *:before,[class*=" sevn_"] *:after{box-sizing:border-box}[class^=sevn_] *,[class*=" sevn_"] *{margin:0;padding:0}',Nt=typeof window<"u"&&typeof document<"u",ea="data-sevn-tokens",ta="data-sevn-theme",ra={primary:"--sevn-color-primary",secondary:"--sevn-color-secondary",tertiary:"--sevn-color-tertiary",neutral:"--sevn-color-neutral",red:"--sevn-color-red",green:"--sevn-color-green",blue:"--sevn-color-blue",yellow:"--sevn-color-yellow",textSecondary:"--sevn-color-text-secondary"};function Ii(){if(!Nt||document.querySelector(`style[${ea}]`))return;const t=document.createElement("style");t.setAttribute(ea,""),t.textContent=Di,document.head.prepend(t);const e=zr().theme;e&&cn(e)}function cn(t){if(!Nt)return;const e=Object.keys(ra).filter(n=>t[n]).map(n=>` ${ra[n]}: ${t[n]};`);if(e.length===0)return;let r=document.querySelector(`style[${ta}]`);r||(r=document.createElement("style"),r.setAttribute(ta,""),document.head.appendChild(r)),r.textContent=`:root {
2
+ ${e.join(`
3
+ `)}
4
+ }`}function na(){return Zn(Oi).transport}function aa(t){return new Promise(e=>setTimeout(e,t))}function Ni(t,e){const r=AbortSignal.timeout(t);return e&&typeof AbortSignal.any=="function"?AbortSignal.any([e,r]):r}function qi(t,e){const r=new URL(t),n=new URL(e);return r.protocol=n.protocol,r.host=n.host,r.toString()}function Fi(t,e){return Array.from({length:e},(r,n)=>(t+n)%e)}const Hi=async(t,e)=>{const r=typeof t=="string"?t:t instanceof URL?t.toString():t.url,n=$n(),{timeoutMs:a,retriesPerHost:i,retryDelayMs:s,stickyWindowMs:c}=zr().request,l=na();l.activeIndex!==0&&Date.now()-l.pinnedAt>=c&&(l.activeIndex=0);let d=null;for(const f of Fi(l.activeIndex,n.length)){const _=qi(r,n[f]);for(let v=0;v<i;v++)try{const p=await fetch(_,{...e,signal:Ni(a,e?.signal)});if(p.status>=500){d=new Error(`HTTP ${p.status} em ${n[f]}`),v<i-1&&await aa(s);continue}return l.activeIndex=f,l.pinnedAt=Date.now(),p}catch(p){d=p,v<i-1&&await aa(s)}}throw new ne(r,d)};function Bi(){return zr().apiHosts[na().activeIndex]??null}const Ui={applyKey:sn,configure(t){Xn(t),t.theme&&cn(t.theme)},getConfig:zr,isReady:Qn,assetUrl:ln,setTheme(t){Xn({theme:t}),cn(t)},activeHost:Bi},dn=!1;var ia=Array.isArray,Vi=Array.prototype.indexOf,or=Array.prototype.includes,Vr=Array.from,Ki=Object.defineProperty,sr=Object.getOwnPropertyDescriptor,Gi=Object.getOwnPropertyDescriptors,Yi=Object.prototype,Wi=Array.prototype,oa=Object.getPrototypeOf,sa=Object.isExtensible;const Zi=()=>{};function Ji(t){for(var e=0;e<t.length;e++)t[e]()}function la(){var t,e,r=new Promise((n,a)=>{t=n,e=a});return{promise:r,resolve:t,reject:e}}const xe=2,Sr=4,Kr=8,ca=1<<24,pt=16,Je=32,qt=64,fn=128,Ge=512,me=1024,Ce=2048,Xe=4096,De=8192,gt=16384,Ft=32768,lr=65536,da=1<<17,fa=1<<18,cr=1<<19,Xi=1<<20,_t=1<<25,Ht=65536,vn=1<<21,un=1<<22,At=1<<23,kr=Symbol("$state"),Qi=Symbol("legacy props"),$i=Symbol(""),Bt=new class extends Error{constructor(){super(...arguments);ht(this,"name","StaleReactionError");ht(this,"message","The reaction that called `getAbortSignal()` was re-run or destroyed")}};function eo(t){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function to(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function ro(t,e,r){throw new Error("https://svelte.dev/e/each_key_duplicate")}function no(t){throw new Error("https://svelte.dev/e/effect_in_teardown")}function ao(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function io(t){throw new Error("https://svelte.dev/e/effect_orphan")}function oo(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function so(t){throw new Error("https://svelte.dev/e/props_invalid_value")}function lo(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function co(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function fo(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function vo(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}const uo=1,ho=2,va=4,po=8,go=16,_o=1,mo=4,wo=8,bo=16,yo=1,xo=2,ze=Symbol(),ua="http://www.w3.org/1999/xhtml";function Co(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function ha(t){return t===this.v}function zo(t,e){return t!=t?e==e:t!==e||t!==null&&typeof t=="object"||typeof t=="function"}function pa(t){return!zo(t,this.v)}let So=!1,Ie=null;function dr(t){Ie=t}function Ut(t,e=!1,r){Ie={p:Ie,i:!1,c:null,e:null,s:t,x:null,l:null}}function Vt(t){var e=Ie,r=e.e;if(r!==null){e.e=null;for(var n of r)qa(n)}return e.i=!0,Ie=e.p,{}}function ga(){return!0}let Kt=[];function _a(){var t=Kt;Kt=[],Ji(t)}function mt(t){if(Kt.length===0&&!Er){var e=Kt;queueMicrotask(()=>{e===Kt&&_a()})}Kt.push(t)}function ko(){for(;Kt.length>0;)_a()}function ma(t){var e=J;if(e===null)return G.f|=At,t;if((e.f&Ft)===0&&(e.f&Sr)===0)throw t;fr(t,e)}function fr(t,e){for(;e!==null;){if((e.f&fn)!==0){if((e.f&Ft)===0)throw t;try{e.b.error(t);return}catch(r){t=r}}e=e.parent}throw t}const Eo=-7169;function ue(t,e){t.f=t.f&Eo|e}function hn(t){(t.f&Ge)!==0||t.deps===null?ue(t,me):ue(t,Xe)}function wa(t){if(t!==null)for(const e of t)(e.f&xe)===0||(e.f&Ht)===0||(e.f^=Ht,wa(e.deps))}function ba(t,e,r){(t.f&Ce)!==0?e.add(t):(t.f&Xe)!==0&&r.add(t),wa(t.deps),ue(t,me)}const Gr=new Set;let $=null,pn=null,Qe=null,je=[],Yr=null,gn=!1,Er=!1;const In=class In{constructor(){Y(this,Fe);ht(this,"committed",!1);ht(this,"current",new Map);ht(this,"previous",new Map);Y(this,gr,new Set);Y(this,_r,new Set);Y(this,$t,0);Y(this,mr,0);Y(this,Dr,null);Y(this,Ir,new Set);Y(this,er,new Set);Y(this,Ct,new Map);ht(this,"is_fork",!1);Y(this,wr,!1)}skip_effect(e){u(this,Ct).has(e)||u(this,Ct).set(e,{d:[],m:[]})}unskip_effect(e){var r=u(this,Ct).get(e);if(r){u(this,Ct).delete(e);for(var n of r.d)ue(n,Ce),$e(n);for(n of r.m)ue(n,Xe),$e(n)}}process(e){je=[],this.apply();var r=[],n=[];for(const a of e)ye(this,Fe,Kn).call(this,a,r,n);if(ye(this,Fe,Vn).call(this)){ye(this,Fe,Gn).call(this,n),ye(this,Fe,Gn).call(this,r);for(const[a,i]of u(this,Ct))Sa(a,i)}else{for(const a of u(this,gr))a();u(this,gr).clear(),u(this,$t)===0&&ye(this,Fe,Li).call(this),pn=this,$=null,xa(n),xa(r),pn=null,u(this,Dr)?.resolve()}Qe=null}capture(e,r){r!==ze&&!this.previous.has(e)&&this.previous.set(e,r),(e.f&At)===0&&(this.current.set(e,e.v),Qe?.set(e,e.v))}activate(){$=this,this.apply()}deactivate(){$===this&&($=null,Qe=null)}flush(){if(this.activate(),je.length>0){if(ya(),$!==null&&$!==this)return}else u(this,$t)===0&&this.process([]);this.deactivate()}discard(){for(const e of u(this,_r))e(this);u(this,_r).clear()}increment(e){B(this,$t,u(this,$t)+1),e&&B(this,mr,u(this,mr)+1)}decrement(e){B(this,$t,u(this,$t)-1),e&&B(this,mr,u(this,mr)-1),!u(this,wr)&&(B(this,wr,!0),mt(()=>{B(this,wr,!1),ye(this,Fe,Vn).call(this)?je.length>0&&this.flush():this.revive()}))}revive(){for(const e of u(this,Ir))u(this,er).delete(e),ue(e,Ce),$e(e);for(const e of u(this,er))ue(e,Xe),$e(e);this.flush()}oncommit(e){u(this,gr).add(e)}ondiscard(e){u(this,_r).add(e)}settled(){return(u(this,Dr)??B(this,Dr,la())).promise}static ensure(){if($===null){const e=$=new In;Gr.add($),Er||mt(()=>{$===e&&e.flush()})}return $}apply(){}};gr=new WeakMap,_r=new WeakMap,$t=new WeakMap,mr=new WeakMap,Dr=new WeakMap,Ir=new WeakMap,er=new WeakMap,Ct=new WeakMap,wr=new WeakMap,Fe=new WeakSet,Vn=function(){return this.is_fork||u(this,mr)>0},Kn=function(e,r,n){e.f^=me;for(var a=e.first;a!==null;){var i=a.f,s=(i&(Je|qt))!==0,c=s&&(i&me)!==0,l=c||(i&De)!==0||u(this,Ct).has(a);if(!l&&a.fn!==null){s?a.f^=me:(i&Sr)!==0?r.push(a):Mr(a)&&((i&pt)!==0&&u(this,er).add(a),ur(a));var d=a.first;if(d!==null){a=d;continue}}for(;a!==null;){var f=a.next;if(f!==null){a=f;break}a=a.parent}}},Gn=function(e){for(var r=0;r<e.length;r+=1)ba(e[r],u(this,Ir),u(this,er))},Li=function(){var a;if(Gr.size>1){this.previous.clear();var e=Qe,r=!0;for(const i of Gr){if(i===this){r=!1;continue}const s=[];for(const[l,d]of this.current){if(i.current.has(l))if(r&&d!==i.current.get(l))i.current.set(l,d);else continue;s.push(l)}if(s.length===0)continue;const c=[...i.current.keys()].filter(l=>!this.current.has(l));if(c.length>0){var n=je;je=[];const l=new Set,d=new Map;for(const f of s)Ca(f,c,l,d);if(je.length>0){$=i,i.apply();for(const f of je)ye(a=i,Fe,Kn).call(a,f,[],[]);i.deactivate()}je=n}}$=null,Qe=e}this.committed=!0,Gr.delete(this)};let Tt=In;function Ao(t){var e=Er;Er=!0;try{for(var r;;){if(ko(),je.length===0&&($?.flush(),je.length===0))return Yr=null,r;ya()}}finally{Er=e}}function ya(){gn=!0;var t=null;try{for(var e=0;je.length>0;){var r=Tt.ensure();if(e++>1e3){var n,a;To()}r.process(je),Mt.clear()}}finally{je=[],gn=!1,Yr=null}}function To(){try{oo()}catch(t){fr(t,Yr)}}let wt=null;function xa(t){var e=t.length;if(e!==0){for(var r=0;r<e;){var n=t[r++];if((n.f&(gt|De))===0&&Mr(n)&&(wt=new Set,ur(n),n.deps===null&&n.first===null&&n.nodes===null&&n.teardown===null&&n.ac===null&&Ua(n),wt?.size>0)){Mt.clear();for(const a of wt){if((a.f&(gt|De))!==0)continue;const i=[a];let s=a.parent;for(;s!==null;)wt.has(s)&&(wt.delete(s),i.push(s)),s=s.parent;for(let c=i.length-1;c>=0;c--){const l=i[c];(l.f&(gt|De))===0&&ur(l)}}wt.clear()}}wt=null}}function Ca(t,e,r,n){if(!r.has(t)&&(r.add(t),t.reactions!==null))for(const a of t.reactions){const i=a.f;(i&xe)!==0?Ca(a,e,r,n):(i&(un|pt))!==0&&(i&Ce)===0&&za(a,e,n)&&(ue(a,Ce),$e(a))}}function za(t,e,r){const n=r.get(t);if(n!==void 0)return n;if(t.deps!==null)for(const a of t.deps){if(or.call(e,a))return!0;if((a.f&xe)!==0&&za(a,e,r))return r.set(a,!0),!0}return r.set(t,!1),!1}function $e(t){var e=Yr=t,r=e.b;if(r?.is_pending&&(t.f&(Sr|Kr|ca))!==0&&(t.f&Ft)===0){r.defer_effect(t);return}for(;e.parent!==null;){e=e.parent;var n=e.f;if(gn&&e===J&&(n&pt)!==0&&(n&fa)===0&&(n&Ft)!==0)return;if((n&(qt|Je))!==0){if((n&me)===0)return;e.f^=me}}je.push(e)}function Sa(t,e){if(!((t.f&Je)!==0&&(t.f&me)!==0)){(t.f&Ce)!==0?e.d.push(t):(t.f&Xe)!==0&&e.m.push(t),ue(t,me);for(var r=t.first;r!==null;)Sa(r,e),r=r.next}}function Mo(t){let e=0,r=Gt(0),n;return()=>{bn()&&(o(r),yn(()=>(e===0&&(n=hr(()=>t(()=>Ar(r)))),e+=1,()=>{mt(()=>{e-=1,e===0&&(n?.(),n=void 0,Ar(r))})})))}}var Lo=lr|cr;function Ro(t,e,r){new jo(t,e,r)}class jo{constructor(e,r,n){Y(this,we);ht(this,"parent");ht(this,"is_pending",!1);Y(this,nt);Y(this,Nn,null);Y(this,zt);Y(this,tr);Y(this,ct);Y(this,dt,null);Y(this,He,null);Y(this,ft,null);Y(this,St,null);Y(this,rr,0);Y(this,Dt,0);Y(this,br,!1);Y(this,yr,new Set);Y(this,xr,new Set);Y(this,kt,null);Y(this,tn,Mo(()=>(B(this,kt,Gt(u(this,rr))),()=>{B(this,kt,null)})));B(this,nt,e),B(this,zt,r),B(this,tr,a=>{var i=J;i.b=this,i.f|=fn,n(a)}),this.parent=J.b,B(this,ct,xn(()=>{ye(this,we,Yn).call(this)},Lo))}defer_effect(e){ba(e,u(this,yr),u(this,xr))}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!u(this,zt).pending}update_pending_count(e){ye(this,we,Wn).call(this,e),B(this,rr,u(this,rr)+e),!(!u(this,kt)||u(this,br))&&(B(this,br,!0),mt(()=>{B(this,br,!1),u(this,kt)&&vr(u(this,kt),u(this,rr))}))}get_effect_pending(){return u(this,tn).call(this),o(u(this,kt))}error(e){var r=u(this,zt).onerror;let n=u(this,zt).failed;if(!r&&!n)throw e;u(this,dt)&&(Oe(u(this,dt)),B(this,dt,null)),u(this,He)&&(Oe(u(this,He)),B(this,He,null)),u(this,ft)&&(Oe(u(this,ft)),B(this,ft,null));var a=!1,i=!1;const s=()=>{if(a){Co();return}a=!0,i&&vo(),u(this,ft)!==null&&Wt(u(this,ft),()=>{B(this,ft,null)}),ye(this,we,on).call(this,()=>{Tt.ensure(),ye(this,we,Yn).call(this)})};mt(()=>{try{i=!0,r?.(e,s),i=!1}catch(c){fr(c,u(this,ct)&&u(this,ct).parent)}n&&B(this,ft,ye(this,we,on).call(this,()=>{Tt.ensure();try{return et(()=>{var c=J;c.b=this,c.f|=fn,n(u(this,nt),()=>e,()=>s)})}catch(c){return fr(c,u(this,ct).parent),null}}))})}}nt=new WeakMap,Nn=new WeakMap,zt=new WeakMap,tr=new WeakMap,ct=new WeakMap,dt=new WeakMap,He=new WeakMap,ft=new WeakMap,St=new WeakMap,rr=new WeakMap,Dt=new WeakMap,br=new WeakMap,yr=new WeakMap,xr=new WeakMap,kt=new WeakMap,tn=new WeakMap,we=new WeakSet,zc=function(){try{B(this,dt,et(()=>u(this,tr).call(this,u(this,nt))))}catch(e){this.error(e)}},Sc=function(){const e=u(this,zt).pending;e&&(this.is_pending=!0,B(this,He,et(()=>e(u(this,nt)))),mt(()=>{var r=B(this,St,document.createDocumentFragment()),n=Lt();r.append(n),B(this,dt,ye(this,we,on).call(this,()=>(Tt.ensure(),et(()=>u(this,tr).call(this,n))))),u(this,Dt)===0&&(u(this,nt).before(r),B(this,St,null),Wt(u(this,He),()=>{B(this,He,null)}),ye(this,we,an).call(this))}))},Yn=function(){try{if(this.is_pending=this.has_pending_snippet(),B(this,Dt,0),B(this,rr,0),B(this,dt,et(()=>{u(this,tr).call(this,u(this,nt))})),u(this,Dt)>0){var e=B(this,St,document.createDocumentFragment());Ga(u(this,dt),e);const r=u(this,zt).pending;B(this,He,et(()=>r(u(this,nt))))}else ye(this,we,an).call(this)}catch(r){this.error(r)}},an=function(){this.is_pending=!1;for(const e of u(this,yr))ue(e,Ce),$e(e);for(const e of u(this,xr))ue(e,Xe),$e(e);u(this,yr).clear(),u(this,xr).clear()},on=function(e){var r=J,n=G,a=Ie;st(u(this,ct)),Ye(u(this,ct)),dr(u(this,ct).ctx);try{return e()}catch(i){return ma(i),null}finally{st(r),Ye(n),dr(a)}},Wn=function(e){var r;if(!this.has_pending_snippet()){this.parent&&ye(r=this.parent,we,Wn).call(r,e);return}B(this,Dt,u(this,Dt)+e),u(this,Dt)===0&&(ye(this,we,an).call(this),u(this,He)&&Wt(u(this,He),()=>{B(this,He,null)}),u(this,St)&&(u(this,nt).before(u(this,St)),B(this,St,null)))};function Oo(t,e,r,n){const a=Wr;var i=t.filter(v=>!v.settled);if(r.length===0&&i.length===0){n(e.map(a));return}var s=$,c=J,l=Po(),d=i.length===1?i[0].promise:i.length>1?Promise.all(i.map(v=>v.promise)):null;function f(v){l();try{n(v)}catch(p){(c.f&gt)===0&&fr(p,c)}s?.deactivate(),_n()}if(r.length===0){d.then(()=>f(e.map(a)));return}function _(){l(),Promise.all(r.map(v=>Io(v))).then(v=>f([...e.map(a),...v])).catch(v=>fr(v,c))}d?d.then(_):_()}function Po(){var t=J,e=G,r=Ie,n=$;return function(i=!0){st(t),Ye(e),dr(r),i&&n?.activate()}}function _n(){st(null),Ye(null),dr(null)}function Do(){var t=J.b,e=$,r=t.is_rendered();return t.update_pending_count(1),e.increment(r),()=>{t.update_pending_count(-1),e.decrement(r)}}function Wr(t){var e=xe|Ce,r=G!==null&&(G.f&xe)!==0?G:null;return J!==null&&(J.f|=cr),{ctx:Ie,deps:null,effects:null,equals:ha,f:e,fn:t,reactions:null,rv:0,v:ze,wv:0,parent:r??J,ac:null}}function Io(t,e,r){J===null&&to();var a=void 0,i=Gt(ze),s=!G,c=new Map;return Jo(()=>{var l=la();a=l.promise;try{Promise.resolve(t()).then(l.resolve,l.reject).then(()=>{d===$&&d.committed&&d.deactivate(),_n()})}catch(v){l.reject(v),_n()}var d=$;if(s){var f=Do();c.get(d)?.reject(Bt),c.delete(d),c.set(d,l)}const _=(v,p=void 0)=>{if(d.activate(),p)p!==Bt&&(i.f|=At,vr(i,p));else{(i.f&At)!==0&&(i.f^=At),vr(i,v);for(const[m,A]of c){if(c.delete(m),m===d)break;A.reject(Bt)}}f&&f()};l.promise.then(_,v=>_(null,v||"unknown"))}),Na(()=>{for(const l of c.values())l.reject(Bt)}),new Promise(l=>{function d(f){function _(){f===a?l(i):d(a)}f.then(_,_)}d(a)})}function K(t){const e=Wr(t);return Wa(e),e}function ka(t){const e=Wr(t);return e.equals=pa,e}function No(t){var e=t.effects;if(e!==null){t.effects=null;for(var r=0;r<e.length;r+=1)Oe(e[r])}}function qo(t){for(var e=t.parent;e!==null;){if((e.f&xe)===0)return(e.f&gt)===0?e:null;e=e.parent}return null}function mn(t){var e,r=J;st(qo(t));try{t.f&=~Ht,No(t),e=$a(t)}finally{st(r)}return e}function Ea(t){var e=mn(t);if(!t.equals(e)&&(t.wv=Xa(),(!$?.is_fork||t.deps===null)&&(t.v=e,t.deps===null))){ue(t,me);return}jt||(Qe!==null?(bn()||$?.is_fork)&&Qe.set(t,e):hn(t))}function Fo(t){if(t.effects!==null)for(const e of t.effects)(e.teardown||e.ac)&&(e.teardown?.(),e.ac?.abort(Bt),e.teardown=Zi,e.ac=null,Lr(e,0),Cn(e))}function Aa(t){if(t.effects!==null)for(const e of t.effects)e.teardown&&ur(e)}let wn=new Set;const Mt=new Map;let Ta=!1;function Gt(t,e){var r={f:0,v:t,reactions:null,equals:ha,rv:0,wv:0};return r}function W(t,e){const r=Gt(t);return Wa(r),r}function Ho(t,e=!1,r=!0){const n=Gt(t);return e||(n.equals=pa),n}function y(t,e,r=!1){G!==null&&(!tt||(G.f&da)!==0)&&ga()&&(G.f&(xe|pt|un|da))!==0&&(We===null||!or.call(We,t))&&fo();let n=r?Yt(e):e;return vr(t,n)}function vr(t,e){if(!t.equals(e)){var r=t.v;jt?Mt.set(t,e):Mt.set(t,r),t.v=e;var n=Tt.ensure();if(n.capture(t,r),(t.f&xe)!==0){const a=t;(t.f&Ce)!==0&&mn(a),hn(a)}t.wv=Xa(),Ma(t,Ce),J!==null&&(J.f&me)!==0&&(J.f&(Je|qt))===0&&(Ze===null?Qo([t]):Ze.push(t)),!n.is_fork&&wn.size>0&&!Ta&&Bo()}return e}function Bo(){Ta=!1;for(const t of wn)(t.f&me)!==0&&ue(t,Xe),Mr(t)&&ur(t);wn.clear()}function Ar(t){y(t,t.v+1)}function Ma(t,e){var r=t.reactions;if(r!==null)for(var n=r.length,a=0;a<n;a++){var i=r[a],s=i.f,c=(s&Ce)===0;if(c&&ue(i,e),(s&xe)!==0){var l=i;Qe?.delete(l),(s&Ht)===0&&(s&Ge&&(i.f|=Ht),Ma(l,Xe))}else c&&((s&pt)!==0&&wt!==null&&wt.add(i),$e(i))}}function Yt(t){if(typeof t!="object"||t===null||kr in t)return t;const e=oa(t);if(e!==Yi&&e!==Wi)return t;var r=new Map,n=ia(t),a=W(0),i=Jt,s=c=>{if(Jt===i)return c();var l=G,d=Jt;Ye(null),Ja(i);var f=c();return Ye(l),Ja(d),f};return n&&r.set("length",W(t.length)),new Proxy(t,{defineProperty(c,l,d){(!("value"in d)||d.configurable===!1||d.enumerable===!1||d.writable===!1)&&lo();var f=r.get(l);return f===void 0?s(()=>{var _=W(d.value);return r.set(l,_),_}):y(f,d.value,!0),!0},deleteProperty(c,l){var d=r.get(l);if(d===void 0){if(l in c){const f=s(()=>W(ze));r.set(l,f),Ar(a)}}else y(d,ze),Ar(a);return!0},get(c,l,d){if(l===kr)return t;var f=r.get(l),_=l in c;if(f===void 0&&(!_||sr(c,l)?.writable)&&(f=s(()=>{var p=Yt(_?c[l]:ze),m=W(p);return m}),r.set(l,f)),f!==void 0){var v=o(f);return v===ze?void 0:v}return Reflect.get(c,l,d)},getOwnPropertyDescriptor(c,l){var d=Reflect.getOwnPropertyDescriptor(c,l);if(d&&"value"in d){var f=r.get(l);f&&(d.value=o(f))}else if(d===void 0){var _=r.get(l),v=_?.v;if(_!==void 0&&v!==ze)return{enumerable:!0,configurable:!0,value:v,writable:!0}}return d},has(c,l){if(l===kr)return!0;var d=r.get(l),f=d!==void 0&&d.v!==ze||Reflect.has(c,l);if(d!==void 0||J!==null&&(!f||sr(c,l)?.writable)){d===void 0&&(d=s(()=>{var v=f?Yt(c[l]):ze,p=W(v);return p}),r.set(l,d));var _=o(d);if(_===ze)return!1}return f},set(c,l,d,f){var _=r.get(l),v=l in c;if(n&&l==="length")for(var p=d;p<_.v;p+=1){var m=r.get(p+"");m!==void 0?y(m,ze):p in c&&(m=s(()=>W(ze)),r.set(p+"",m))}if(_===void 0)(!v||sr(c,l)?.writable)&&(_=s(()=>W(void 0)),y(_,Yt(d)),r.set(l,_));else{v=_.v!==ze;var A=s(()=>Yt(d));y(_,A)}var g=Reflect.getOwnPropertyDescriptor(c,l);if(g?.set&&g.set.call(f,d),!v){if(n&&typeof l=="string"){var k=r.get("length"),S=Number(l);Number.isInteger(S)&&S>=k.v&&y(k,S+1)}Ar(a)}return!0},ownKeys(c){o(a);var l=Reflect.ownKeys(c).filter(_=>{var v=r.get(_);return v===void 0||v.v!==ze});for(var[d,f]of r)f.v!==ze&&!(d in c)&&l.push(d);return l},setPrototypeOf(){co()}})}var La,Ra,ja,Oa;function Uo(){if(La===void 0){La=window,Ra=/Firefox/.test(navigator.userAgent);var t=Element.prototype,e=Node.prototype,r=Text.prototype;ja=sr(e,"firstChild").get,Oa=sr(e,"nextSibling").get,sa(t)&&(t.__click=void 0,t.__className=void 0,t.__attributes=null,t.__style=void 0,t.__e=void 0),sa(r)&&(r.__t=void 0)}}function Lt(t=""){return document.createTextNode(t)}function Rt(t){return ja.call(t)}function Tr(t){return Oa.call(t)}function b(t,e){return Rt(t)}function bt(t,e=!1){{var r=Rt(t);return r instanceof Comment&&r.data===""?Tr(r):r}}function L(t,e=1,r=!1){let n=t;for(;e--;)n=Tr(n);return n}function Vo(t){t.textContent=""}function Pa(){return!1}function Da(t,e,r){return document.createElementNS(ua,t,void 0)}let Ia=!1;function Ko(){Ia||(Ia=!0,document.addEventListener("reset",t=>{Promise.resolve().then(()=>{if(!t.defaultPrevented)for(const e of t.target.elements)e.__on_r?.()})},{capture:!0}))}function Zr(t){var e=G,r=J;Ye(null),st(null);try{return t()}finally{Ye(e),st(r)}}function Go(t,e,r,n=r){t.addEventListener(e,()=>Zr(r));const a=t.__on_r;a?t.__on_r=()=>{a(),n(!0)}:t.__on_r=()=>n(!0),Ko()}function Yo(t){J===null&&(G===null&&io(),ao()),jt&&no()}function Wo(t,e){var r=e.last;r===null?e.last=e.first=t:(r.next=t,t.prev=r,e.last=t)}function yt(t,e,r){var n=J;n!==null&&(n.f&De)!==0&&(t|=De);var a={ctx:Ie,deps:null,nodes:null,f:t|Ce|Ge,first:null,fn:e,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null};if(r)try{ur(a)}catch(c){throw Oe(a),c}else e!==null&&$e(a);var i=a;if(r&&i.deps===null&&i.teardown===null&&i.nodes===null&&i.first===i.last&&(i.f&cr)===0&&(i=i.first,(t&pt)!==0&&(t&lr)!==0&&i!==null&&(i.f|=lr)),i!==null&&(i.parent=n,n!==null&&Wo(i,n),G!==null&&(G.f&xe)!==0&&(t&qt)===0)){var s=G;(s.effects??(s.effects=[])).push(i)}return a}function bn(){return G!==null&&!tt}function Na(t){const e=yt(Kr,null,!1);return ue(e,me),e.teardown=t,e}function xt(t){Yo();var e=J.f,r=!G&&(e&Je)!==0&&(e&Ft)===0;if(r){var n=Ie;(n.e??(n.e=[])).push(t)}else return qa(t)}function qa(t){return yt(Sr|Xi,t,!1)}function Zo(t){Tt.ensure();const e=yt(qt|cr,t,!0);return(r={})=>new Promise(n=>{r.outro?Wt(e,()=>{Oe(e),n(void 0)}):(Oe(e),n(void 0))})}function Fa(t){return yt(Sr,t,!1)}function Jo(t){return yt(un|cr,t,!0)}function yn(t,e=0){return yt(Kr|e,t,!0)}function R(t,e=[],r=[],n=[]){Oo(n,e,r,a=>{yt(Kr,()=>t(...a.map(o)),!0)})}function xn(t,e=0){var r=yt(pt|e,t,!0);return r}function et(t){return yt(Je|cr,t,!0)}function Ha(t){var e=t.teardown;if(e!==null){const r=jt,n=G;Ya(!0),Ye(null);try{e.call(null)}finally{Ya(r),Ye(n)}}}function Cn(t,e=!1){var r=t.first;for(t.first=t.last=null;r!==null;){const a=r.ac;a!==null&&Zr(()=>{a.abort(Bt)});var n=r.next;(r.f&qt)!==0?r.parent=null:Oe(r,e),r=n}}function Xo(t){for(var e=t.first;e!==null;){var r=e.next;(e.f&Je)===0&&Oe(e),e=r}}function Oe(t,e=!0){var r=!1;(e||(t.f&fa)!==0)&&t.nodes!==null&&t.nodes.end!==null&&(Ba(t.nodes.start,t.nodes.end),r=!0),Cn(t,e&&!r),Lr(t,0),ue(t,gt);var n=t.nodes&&t.nodes.t;if(n!==null)for(const i of n)i.stop();Ha(t);var a=t.parent;a!==null&&a.first!==null&&Ua(t),t.next=t.prev=t.teardown=t.ctx=t.deps=t.fn=t.nodes=t.ac=null}function Ba(t,e){for(;t!==null;){var r=t===e?null:Tr(t);t.remove(),t=r}}function Ua(t){var e=t.parent,r=t.prev,n=t.next;r!==null&&(r.next=n),n!==null&&(n.prev=r),e!==null&&(e.first===t&&(e.first=n),e.last===t&&(e.last=r))}function Wt(t,e,r=!0){var n=[];Va(t,n,!0);var a=()=>{r&&Oe(t),e&&e()},i=n.length;if(i>0){var s=()=>--i||a();for(var c of n)c.out(s)}else a()}function Va(t,e,r){if((t.f&De)===0){t.f^=De;var n=t.nodes&&t.nodes.t;if(n!==null)for(const c of n)(c.is_global||r)&&e.push(c);for(var a=t.first;a!==null;){var i=a.next,s=(a.f&lr)!==0||(a.f&Je)!==0&&(t.f&pt)!==0;Va(a,e,s?r:!1),a=i}}}function zn(t){Ka(t,!0)}function Ka(t,e){if((t.f&De)!==0){t.f^=De,(t.f&me)===0&&(ue(t,Ce),$e(t));for(var r=t.first;r!==null;){var n=r.next,a=(r.f&lr)!==0||(r.f&Je)!==0;Ka(r,a?e:!1),r=n}var i=t.nodes&&t.nodes.t;if(i!==null)for(const s of i)(s.is_global||e)&&s.in()}}function Ga(t,e){if(t.nodes)for(var r=t.nodes.start,n=t.nodes.end;r!==null;){var a=r===n?null:Tr(r);e.append(r),r=a}}let Jr=!1,jt=!1;function Ya(t){jt=t}let G=null,tt=!1;function Ye(t){G=t}let J=null;function st(t){J=t}let We=null;function Wa(t){G!==null&&(We===null?We=[t]:We.push(t))}let Pe=null,Ne=0,Ze=null;function Qo(t){Ze=t}let Za=1,Zt=0,Jt=Zt;function Ja(t){Jt=t}function Xa(){return++Za}function Mr(t){var e=t.f;if((e&Ce)!==0)return!0;if(e&xe&&(t.f&=~Ht),(e&Xe)!==0){for(var r=t.deps,n=r.length,a=0;a<n;a++){var i=r[a];if(Mr(i)&&Ea(i),i.wv>t.wv)return!0}(e&Ge)!==0&&Qe===null&&ue(t,me)}return!1}function Qa(t,e,r=!0){var n=t.reactions;if(n!==null&&!(We!==null&&or.call(We,t)))for(var a=0;a<n.length;a++){var i=n[a];(i.f&xe)!==0?Qa(i,e,!1):e===i&&(r?ue(i,Ce):(i.f&me)!==0&&ue(i,Xe),$e(i))}}function $a(t){var A;var e=Pe,r=Ne,n=Ze,a=G,i=We,s=Ie,c=tt,l=Jt,d=t.f;Pe=null,Ne=0,Ze=null,G=(d&(Je|qt))===0?t:null,We=null,dr(t.ctx),tt=!1,Jt=++Zt,t.ac!==null&&(Zr(()=>{t.ac.abort(Bt)}),t.ac=null);try{t.f|=vn;var f=t.fn,_=f();t.f|=Ft;var v=t.deps,p=$?.is_fork;if(Pe!==null){var m;if(p||Lr(t,Ne),v!==null&&Ne>0)for(v.length=Ne+Pe.length,m=0;m<Pe.length;m++)v[Ne+m]=Pe[m];else t.deps=v=Pe;if(bn()&&(t.f&Ge)!==0)for(m=Ne;m<v.length;m++)((A=v[m]).reactions??(A.reactions=[])).push(t)}else!p&&v!==null&&Ne<v.length&&(Lr(t,Ne),v.length=Ne);if(ga()&&Ze!==null&&!tt&&v!==null&&(t.f&(xe|Xe|Ce))===0)for(m=0;m<Ze.length;m++)Qa(Ze[m],t);if(a!==null&&a!==t){if(Zt++,a.deps!==null)for(let g=0;g<r;g+=1)a.deps[g].rv=Zt;if(e!==null)for(const g of e)g.rv=Zt;Ze!==null&&(n===null?n=Ze:n.push(...Ze))}return(t.f&At)!==0&&(t.f^=At),_}catch(g){return ma(g)}finally{t.f^=vn,Pe=e,Ne=r,Ze=n,G=a,We=i,dr(s),tt=c,Jt=l}}function $o(t,e){let r=e.reactions;if(r!==null){var n=Vi.call(r,t);if(n!==-1){var a=r.length-1;a===0?r=e.reactions=null:(r[n]=r[a],r.pop())}}if(r===null&&(e.f&xe)!==0&&(Pe===null||!or.call(Pe,e))){var i=e;(i.f&Ge)!==0&&(i.f^=Ge,i.f&=~Ht),hn(i),Fo(i),Lr(i,0)}}function Lr(t,e){var r=t.deps;if(r!==null)for(var n=e;n<r.length;n++)$o(t,r[n])}function ur(t){var e=t.f;if((e&gt)===0){ue(t,me);var r=J,n=Jr;J=t,Jr=!0;try{(e&(pt|ca))!==0?Xo(t):Cn(t),Ha(t);var a=$a(t);t.teardown=typeof a=="function"?a:null,t.wv=Za;var i;dn&&So&&(t.f&Ce)!==0&&t.deps}finally{Jr=n,J=r}}}async function es(){await Promise.resolve(),Ao()}function o(t){var e=t.f,r=(e&xe)!==0;if(G!==null&&!tt){var n=J!==null&&(J.f&gt)!==0;if(!n&&(We===null||!or.call(We,t))){var a=G.deps;if((G.f&vn)!==0)t.rv<Zt&&(t.rv=Zt,Pe===null&&a!==null&&a[Ne]===t?Ne++:Pe===null?Pe=[t]:Pe.push(t));else{(G.deps??(G.deps=[])).push(t);var i=t.reactions;i===null?t.reactions=[G]:or.call(i,G)||i.push(G)}}}if(jt&&Mt.has(t))return Mt.get(t);if(r){var s=t;if(jt){var c=s.v;return((s.f&me)===0&&s.reactions!==null||ti(s))&&(c=mn(s)),Mt.set(s,c),c}var l=(s.f&Ge)===0&&!tt&&G!==null&&(Jr||(G.f&Ge)!==0),d=(s.f&Ft)===0;Mr(s)&&(l&&(s.f|=Ge),Ea(s)),l&&!d&&(Aa(s),ei(s))}if(Qe?.has(t))return Qe.get(t);if((t.f&At)!==0)throw t.v;return t.v}function ei(t){if(t.f|=Ge,t.deps!==null)for(const e of t.deps)(e.reactions??(e.reactions=[])).push(t),(e.f&xe)!==0&&(e.f&Ge)===0&&(Aa(e),ei(e))}function ti(t){if(t.v===ze)return!0;if(t.deps===null)return!1;for(const e of t.deps)if(Mt.has(e)||(e.f&xe)!==0&&ti(e))return!0;return!1}function hr(t){var e=tt;try{return tt=!0,t()}finally{tt=e}}const ts=["touchstart","touchmove"];function rs(t){return ts.includes(t)}const Xt=Symbol("events"),ri=new Set,Sn=new Set;function ns(t,e,r,n={}){function a(i){if(n.capture||An.call(e,i),!i.cancelBubble)return Zr(()=>r?.call(this,i))}return t.startsWith("pointer")||t.startsWith("touch")||t==="wheel"?mt(()=>{e.addEventListener(t,a,n)}):e.addEventListener(t,a,n),a}function kn(t,e,r,n,a){var i={capture:n,passive:a},s=ns(t,e,r,i);(e===document.body||e===window||e===document||e instanceof HTMLMediaElement)&&Na(()=>{e.removeEventListener(t,s,i)})}function qe(t,e,r){(e[Xt]??(e[Xt]={}))[t]=r}function En(t){for(var e=0;e<t.length;e++)ri.add(t[e]);for(var r of Sn)r(t)}let ni=null;function An(t){var e=this,r=e.ownerDocument,n=t.type,a=t.composedPath?.()||[],i=a[0]||t.target;ni=t;var s=0,c=ni===t&&t[Xt];if(c){var l=a.indexOf(c);if(l!==-1&&(e===document||e===window)){t[Xt]=e;return}var d=a.indexOf(e);if(d===-1)return;l<=d&&(s=l)}if(i=a[s]||t.target,i!==e){Ki(t,"currentTarget",{configurable:!0,get(){return i||r}});var f=G,_=J;Ye(null),st(null);try{for(var v,p=[];i!==null;){var m=i.assignedSlot||i.parentNode||i.host||null;try{var A=i[Xt]?.[n];A!=null&&(!i.disabled||t.target===i)&&A.call(i,t)}catch(g){v?p.push(g):v=g}if(t.cancelBubble||m===e||m===null)break;i=m}if(v){for(let g of p)queueMicrotask(()=>{throw g});throw v}}finally{t[Xt]=e,delete t.currentTarget,Ye(f),st(_)}}}const as=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:t=>t});function is(t){return as?.createHTML(t)??t}function ai(t,e=!1){var r=Da("template");return t=t.replaceAll("<!>","<!---->"),r.innerHTML=e?is(t):t,r.content}function Xr(t,e){var r=J;r.nodes===null&&(r.nodes={start:t,end:e,a:null,t:null})}function z(t,e){var r=(e&yo)!==0,n=(e&xo)!==0,a,i=!t.startsWith("<!>");return()=>{a===void 0&&(a=ai(i?t:"<!>"+t,!0),r||(a=Rt(a)));var s=n||Ra?document.importNode(a,!0):a.cloneNode(!0);if(r){var c=Rt(s),l=s.lastChild;Xr(c,l)}else Xr(s,s);return s}}function pr(){var t=document.createDocumentFragment(),e=document.createComment(""),r=Lt();return t.append(e,r),Xr(e,r),t}function x(t,e){t!==null&&t.before(e)}function U(t,e){var r=e==null?"":typeof e=="object"?e+"":e;r!==(t.__t??(t.__t=t.nodeValue))&&(t.__t=r,t.nodeValue=r+"")}function os(t,e){return ss(t,e)}const Qr=new Map;function ss(t,{target:e,anchor:r,props:n={},events:a,context:i,intro:s=!0}){Uo();var c=void 0,l=Zo(()=>{var d=r??e.appendChild(Lt());Ro(d,{pending:()=>{}},v=>{Ut({});var p=Ie;i&&(p.c=i),a&&(n.$$events=a),c=t(v,n)||{},Vt()});var f=new Set,_=v=>{for(var p=0;p<v.length;p++){var m=v[p];if(!f.has(m)){f.add(m);var A=rs(m);for(const S of[e,document]){var g=Qr.get(S);g===void 0&&(g=new Map,Qr.set(S,g));var k=g.get(m);k===void 0?(S.addEventListener(m,An,{passive:A}),g.set(m,1)):g.set(m,k+1)}}}};return _(Vr(ri)),Sn.add(_),()=>{for(var v of f)for(const A of[e,document]){var p=Qr.get(A),m=p.get(v);--m==0?(A.removeEventListener(v,An),p.delete(v),p.size===0&&Qr.delete(A)):p.set(v,m)}Sn.delete(_),d!==r&&d.parentNode?.removeChild(d)}});return Tn.set(c,l),c}let Tn=new WeakMap;function ls(t,e){const r=Tn.get(t);return r?(Tn.delete(t),r(e)):Promise.resolve()}class cs{constructor(e,r=!0){ht(this,"anchor");Y(this,at,new Map);Y(this,vt,new Map);Y(this,Be,new Map);Y(this,nr,new Set);Y(this,Nr,!0);Y(this,qr,()=>{var e=$;if(u(this,at).has(e)){var r=u(this,at).get(e),n=u(this,vt).get(r);if(n)zn(n),u(this,nr).delete(r);else{var a=u(this,Be).get(r);a&&(u(this,vt).set(r,a.effect),u(this,Be).delete(r),a.fragment.lastChild.remove(),this.anchor.before(a.fragment),n=a.effect)}for(const[i,s]of u(this,at)){if(u(this,at).delete(i),i===e)break;const c=u(this,Be).get(s);c&&(Oe(c.effect),u(this,Be).delete(s))}for(const[i,s]of u(this,vt)){if(i===r||u(this,nr).has(i))continue;const c=()=>{if(Array.from(u(this,at).values()).includes(i)){var d=document.createDocumentFragment();Ga(s,d),d.append(Lt()),u(this,Be).set(i,{effect:s,fragment:d})}else Oe(s);u(this,nr).delete(i),u(this,vt).delete(i)};u(this,Nr)||!n?(u(this,nr).add(i),Wt(s,c,!1)):c()}}});Y(this,rn,e=>{u(this,at).delete(e);const r=Array.from(u(this,at).values());for(const[n,a]of u(this,Be))r.includes(n)||(Oe(a.effect),u(this,Be).delete(n))});this.anchor=e,B(this,Nr,r)}ensure(e,r){var n=$,a=Pa();if(r&&!u(this,vt).has(e)&&!u(this,Be).has(e))if(a){var i=document.createDocumentFragment(),s=Lt();i.append(s),u(this,Be).set(e,{effect:et(()=>r(s)),fragment:i})}else u(this,vt).set(e,et(()=>r(this.anchor)));if(u(this,at).set(n,e),a){for(const[c,l]of u(this,vt))c===e?n.unskip_effect(l):n.skip_effect(l);for(const[c,l]of u(this,Be))c===e?n.unskip_effect(l.effect):n.skip_effect(l.effect);n.oncommit(u(this,qr)),n.ondiscard(u(this,rn))}else u(this,qr).call(this)}}at=new WeakMap,vt=new WeakMap,Be=new WeakMap,nr=new WeakMap,Nr=new WeakMap,qr=new WeakMap,rn=new WeakMap;function j(t,e,r=!1){var n=new cs(t),a=r?lr:0;function i(s,c){n.ensure(s,c)}xn(()=>{var s=!1;e((c,l=0)=>{s=!0,i(l,c)}),s||i(!1,null)},a)}function Rr(t,e){return e}function ds(t,e,r){for(var n=[],a=e.length,i,s=e.length,c=0;c<a;c++){let _=e[c];Wt(_,()=>{if(i){if(i.pending.delete(_),i.done.add(_),i.pending.size===0){var v=t.outrogroups;Mn(Vr(i.done)),v.delete(i),v.size===0&&(t.outrogroups=null)}}else s-=1},!1)}if(s===0){var l=n.length===0&&r!==null;if(l){var d=r,f=d.parentNode;Vo(f),f.append(d),t.items.clear()}Mn(e,!l)}else i={pending:new Set(e),done:new Set},(t.outrogroups??(t.outrogroups=new Set)).add(i)}function Mn(t,e=!0){for(var r=0;r<t.length;r++)Oe(t[r],e)}var ii;function Qt(t,e,r,n,a,i=null){var s=t,c=new Map,l=(e&va)!==0;if(l){var d=t;s=d.appendChild(Lt())}var f=null,_=ka(()=>{var k=r();return ia(k)?k:k==null?[]:Vr(k)}),v,p=!0;function m(){g.fallback=f,fs(g,v,s,e,n),f!==null&&(v.length===0?(f.f&_t)===0?zn(f):(f.f^=_t,Or(f,null,s)):Wt(f,()=>{f=null}))}var A=xn(()=>{v=o(_);for(var k=v.length,S=new Set,P=$,O=Pa(),I=0;I<k;I+=1){var ee=v[I],q=n(ee,I),X=p?null:c.get(q);X?(X.v&&vr(X.v,ee),X.i&&vr(X.i,I),O&&P.unskip_effect(X.e)):(X=vs(c,p?s:ii??(ii=Lt()),ee,q,I,a,e,r),p||(X.e.f|=_t),c.set(q,X)),S.add(q)}if(k===0&&i&&!f&&(p?f=et(()=>i(s)):(f=et(()=>i(ii??(ii=Lt()))),f.f|=_t)),k>S.size&&ro(),!p)if(O){for(const[N,F]of c)S.has(N)||P.skip_effect(F.e);P.oncommit(m),P.ondiscard(()=>{})}else m();o(_)}),g={effect:A,items:c,outrogroups:null,fallback:f};p=!1}function jr(t){for(;t!==null&&(t.f&Je)===0;)t=t.next;return t}function fs(t,e,r,n,a){var i=(n&po)!==0,s=e.length,c=t.items,l=jr(t.effect.first),d,f=null,_,v=[],p=[],m,A,g,k;if(i)for(k=0;k<s;k+=1)m=e[k],A=a(m,k),g=c.get(A).e,(g.f&_t)===0&&(g.nodes?.a?.measure(),(_??(_=new Set)).add(g));for(k=0;k<s;k+=1){if(m=e[k],A=a(m,k),g=c.get(A).e,t.outrogroups!==null)for(const F of t.outrogroups)F.pending.delete(g),F.done.delete(g);if((g.f&_t)!==0)if(g.f^=_t,g===l)Or(g,null,r);else{var S=f?f.next:l;g===t.effect.last&&(t.effect.last=g.prev),g.prev&&(g.prev.next=g.next),g.next&&(g.next.prev=g.prev),Ot(t,f,g),Ot(t,g,S),Or(g,S,r),f=g,v=[],p=[],l=jr(f.next);continue}if((g.f&De)!==0&&(zn(g),i&&(g.nodes?.a?.unfix(),(_??(_=new Set)).delete(g))),g!==l){if(d!==void 0&&d.has(g)){if(v.length<p.length){var P=p[0],O;f=P.prev;var I=v[0],ee=v[v.length-1];for(O=0;O<v.length;O+=1)Or(v[O],P,r);for(O=0;O<p.length;O+=1)d.delete(p[O]);Ot(t,I.prev,ee.next),Ot(t,f,I),Ot(t,ee,P),l=P,f=ee,k-=1,v=[],p=[]}else d.delete(g),Or(g,l,r),Ot(t,g.prev,g.next),Ot(t,g,f===null?t.effect.first:f.next),Ot(t,f,g),f=g;continue}for(v=[],p=[];l!==null&&l!==g;)(d??(d=new Set)).add(l),p.push(l),l=jr(l.next);if(l===null)continue}(g.f&_t)===0&&v.push(g),f=g,l=jr(g.next)}if(t.outrogroups!==null){for(const F of t.outrogroups)F.pending.size===0&&(Mn(Vr(F.done)),t.outrogroups?.delete(F));t.outrogroups.size===0&&(t.outrogroups=null)}if(l!==null||d!==void 0){var q=[];if(d!==void 0)for(g of d)(g.f&De)===0&&q.push(g);for(;l!==null;)(l.f&De)===0&&l!==t.fallback&&q.push(l),l=jr(l.next);var X=q.length;if(X>0){var N=(n&va)!==0&&s===0?r:null;if(i){for(k=0;k<X;k+=1)q[k].nodes?.a?.measure();for(k=0;k<X;k+=1)q[k].nodes?.a?.fix()}ds(t,q,N)}}i&&mt(()=>{if(_!==void 0)for(g of _)g.nodes?.a?.apply()})}function vs(t,e,r,n,a,i,s,c){var l=(s&uo)!==0?(s&go)===0?Ho(r,!1,!1):Gt(r):null,d=(s&ho)!==0?Gt(a):null;return{v:l,i:d,e:et(()=>(i(e,l??r,d??a,c),()=>{t.delete(n)}))}}function Or(t,e,r){if(t.nodes)for(var n=t.nodes.start,a=t.nodes.end,i=e&&(e.f&_t)===0?e.nodes.start:r;n!==null;){var s=Tr(n);if(i.before(n),n===a)return;n=s}}function Ot(t,e,r){e===null?t.effect.first=r:e.next=r,r===null?t.effect.last=e:r.prev=e}function oi(t,e,r=!1,n=!1,a=!1){var i=t,s="";R(()=>{var c=J;if(s!==(s=e()??"")&&(c.nodes!==null&&(Ba(c.nodes.start,c.nodes.end),c.nodes=null),s!=="")){var l=s+"";r?l=`<svg>${l}</svg>`:n&&(l=`<math>${l}</math>`);var d=ai(l);if((r||n)&&(d=Rt(d)),Xr(Rt(d),d.lastChild),r||n)for(;Rt(d);)i.before(Rt(d));else i.before(d)}})}function lt(t,e){Fa(()=>{var r=t.getRootNode(),n=r.host?r:r.head??r.ownerDocument.head;if(!n.querySelector("#"+e.hash)){const a=Da("style");a.id=e.hash,a.textContent=e.code,n.appendChild(a)}})}const si=[...`
5
+ \r\f \v\uFEFF`];function us(t,e,r){var n=t==null?"":""+t;if(e&&(n=n?n+" "+e:e),r){for(var a in r)if(r[a])n=n?n+" "+a:a;else if(n.length)for(var i=a.length,s=0;(s=n.indexOf(a,s))>=0;){var c=s+i;(s===0||si.includes(n[s-1]))&&(c===n.length||si.includes(n[c]))?n=(s===0?"":n.substring(0,s))+n.substring(c+1):s=c}}return n===""?null:n}function hs(t,e){return t==null?null:String(t)}function Te(t,e,r,n,a,i){var s=t.__className;if(s!==r||s===void 0){var c=us(r,n,i);c==null?t.removeAttribute("class"):t.className=c,t.__className=r}else if(i&&a!==i)for(var l in i){var d=!!i[l];(a==null||d!==!!a[l])&&t.classList.toggle(l,d)}return i}function rt(t,e,r,n){var a=t.__style;if(a!==e){var i=hs(e);i==null?t.removeAttribute("style"):t.style.cssText=i,t.__style=e}return n}const ps=Symbol("is custom element"),gs=Symbol("is html");function ae(t,e,r,n){var a=_s(t);a[e]!==(a[e]=r)&&(e==="loading"&&(t[$i]=r),r==null?t.removeAttribute(e):typeof r!="string"&&ms(t).includes(e)?t[e]=r:t.setAttribute(e,r))}function _s(t){return t.__attributes??(t.__attributes={[ps]:t.nodeName.includes("-"),[gs]:t.namespaceURI===ua})}var li=new Map;function ms(t){var e=t.getAttribute("is")||t.nodeName,r=li.get(e);if(r)return r;li.set(e,r=[]);for(var n,a=t,i=Element.prototype;i!==a;){n=Gi(a);for(var s in n)n[s].set&&r.push(s);a=oa(a)}return r}function ws(t,e,r=e){var n=new WeakSet;Go(t,"input",async a=>{var i=a?t.defaultValue:t.value;if(i=Ln(t)?Rn(i):i,r(i),$!==null&&n.add($),await es(),i!==(i=e())){var s=t.selectionStart,c=t.selectionEnd,l=t.value.length;if(t.value=i??"",c!==null){var d=t.value.length;s===c&&c===l&&d>l?(t.selectionStart=d,t.selectionEnd=d):(t.selectionStart=s,t.selectionEnd=Math.min(c,d))}}}),hr(e)==null&&t.value&&(r(Ln(t)?Rn(t.value):t.value),$!==null&&n.add($)),yn(()=>{var a=e();if(t===document.activeElement){var i=pn??$;if(n.has(i))return}Ln(t)&&a===Rn(t.value)||t.type==="date"&&!a&&!t.value||a!==t.value&&(t.value=a??"")})}function Ln(t){var e=t.type;return e==="number"||e==="range"}function Rn(t){return t===""?null:+t}function ci(t,e){return t===e||t?.[kr]===e}function Pr(t={},e,r,n){return Fa(()=>{var a,i;return yn(()=>{a=i,i=[],hr(()=>{t!==r(...i)&&(e(t,...i),a&&ci(r(...a),t)&&e(null,...a))})}),()=>{mt(()=>{i&&ci(r(...i),t)&&e(null,...i)})}}),t}let $r=!1;function bs(t){var e=$r;try{return $r=!1,[t(),$r]}finally{$r=e}}function D(t,e,r,n){var a=(r&wo)!==0,i=(r&bo)!==0,s=n,c=!0,l=()=>(c&&(c=!1,s=i?hr(n):n),s),d;if(a){var f=kr in t||Qi in t;d=sr(t,e)?.set??(f&&e in t?S=>t[e]=S:void 0)}var _,v=!1;a?[_,v]=bs(()=>t[e]):_=t[e],_===void 0&&n!==void 0&&(_=l(),d&&(so(),d(_)));var p;if(p=()=>{var S=t[e];return S===void 0?l():(c=!0,S)},(r&mo)===0)return p;if(d){var m=t.$$legacy;return(function(S,P){return arguments.length>0?((!P||m||v)&&d(P?p():S),S):p()})}var A=!1,g=((r&_o)!==0?Wr:ka)(()=>(A=!1,p()));a&&o(g);var k=J;return(function(S,P){if(arguments.length>0){const O=P?o(g):a?Yt(S):S;return y(g,O),A=!0,s!==void 0&&(s=O),S}return jt&&A||(k.f&gt)!==0?g.v:o(g)})}function di(t){Ie===null&&eo(),xt(()=>{const e=hr(t);if(typeof e=="function")return e})}function ys(t,e){var r,n;return n=class{constructor(i){Y(this,r,null);if(!Nt)throw new Error(`[sevn] ${e} só pode ser instanciado no navegador. Em SSR, monte o componente dentro de um efeito de cliente.`);const{target:s,...c}=i??{},l=typeof s=="string"?document.querySelector(s):s;if(!l)throw new Error(`[sevn] ${e}: alvo não encontrado`+(typeof s=="string"?` para o seletor "${s}".`:"."));Ii(),B(this,r,os(t,{target:l,props:c}))}destroy(){if(!u(this,r))return Promise.resolve();const i=u(this,r);return B(this,r,null),ls(i)}},r=new WeakMap,n}function fi(t){try{return new URL(t,document.baseURI).searchParams.get("cid")}catch{return null}}function xs(){const t=document.currentScript;if(t?.src){const r=fi(t.src);if(r)return r}const e=document.querySelectorAll('script[src*="cid="]');for(const r of e){const n=fi(r.src);if(n)return n}return null}function Cs(){if(!Nt)return;const t=xs();if(t)try{sn(t)}catch(e){console.error("[sevn] Chave inválida na tag <script>:",e)}}const zs="5";typeof window<"u"&&((ki=window.__svelte??(window.__svelte={})).v??(ki.v=new Set)).add(zs);const Ss="data:image/svg+xml,%3csvg%20width='37'%20height='45'%20viewBox='0%200%2037%2045'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20opacity='0.5'%3e%3cpath%20d='M11.3846%2028.125H25.6154C30.34%2028.125%2034.1538%2031.8937%2034.1538%2036.5625V42.1875H2.84615V36.5625C2.84615%2031.8937%206.66%2028.125%2011.3846%2028.125ZM11.3846%2011.25H25.6154V18.2812C25.6154%2020.1461%2024.8657%2021.9345%2023.5313%2023.2531C22.1969%2024.5717%2020.3871%2025.3125%2018.5%2025.3125C16.6129%2025.3125%2014.8031%2024.5717%2013.4687%2023.2531C12.1343%2021.9345%2011.3846%2020.1461%2011.3846%2018.2812V11.25ZM25.6154%2011.25C27.1808%2011.25%2028.4615%2012.5156%2028.4615%2014.0625C28.4615%2015.6094%2027.1808%2016.875%2025.6154%2016.875V11.25ZM11.3846%2016.875C9.81923%2016.875%208.53846%2015.6094%208.53846%2014.0625C8.53846%2012.5156%209.81923%2011.25%2011.3846%2011.25V16.875Z'%20fill='%231C1C1C'/%3e%3cpath%20d='M11.7262%2011.5875H10.3031C8.16847%209.84374%208.53847%207.17186%208.53847%204.92186C8.53847%202.67186%209.96154%204.19061%2011.3846%204.19061C12.8077%204.19061%2014.2308%205.59686%2014.2308%205.59686C11.7262%205.59686%2011.3846%202.78436%2011.3846%202.78436H19.9231C23.0539%202.78436%2025.6154%205.31561%2025.6154%208.40936H27.0385C27.0385%208.40936%2027.75%2010.5187%2026.6969%2011.925L11.7546%2011.5875H11.7262Z'%20fill='%231C1C1C'/%3e%3c/g%3e%3c/svg%3e",ks="data:image/svg+xml,%3csvg%20width='37'%20height='45'%20viewBox='0%200%2037%2045'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20opacity='0.5'%3e%3cpath%20d='M11.3846%2028.125H25.6154C30.34%2028.125%2034.1539%2031.8937%2034.1539%2036.5625V42.1875H2.84616V36.5625C2.84616%2031.8937%206.66001%2028.125%2011.3846%2028.125ZM11.3846%2011.25H25.6154V18.2812C25.6154%2020.1461%2024.8657%2021.9345%2023.5313%2023.2531C22.197%2024.5717%2020.3871%2025.3125%2018.5%2025.3125C16.6129%2025.3125%2014.8031%2024.5717%2013.4687%2023.2531C12.1343%2021.9345%2011.3846%2020.1461%2011.3846%2018.2812V11.25Z'%20fill='black'/%3e%3cpath%20d='M27.0385%2011.0531V9.84375C27.0385%206.75%2024.4769%204.21875%2021.3461%204.21875L19.9231%202.8125H15.6538C12.5231%202.8125%209.96153%205.34375%209.96153%208.4375V11.0531C9.96153%2014.7938%208.45307%2018.3656%205.80615%2021.0094L4.26923%2022.5281L6.37538%2023.5688C8.53846%2024.6375%2011.1285%2024.2156%2012.8077%2022.5281H24.1923C25.9%2024.2156%2028.49%2024.6375%2030.6246%2023.5688L32.7308%2022.5281L31.1938%2021.0094C29.8732%2019.701%2028.8264%2018.1483%2028.1134%2016.4399C27.4004%2014.7316%2027.0351%2012.9011%2027.0385%2011.0531Z'%20fill='black'/%3e%3cpath%20d='M19.9231%202.8125C19.9231%202.8125%2021.3462%202.8125%2021.3462%204.21875H19.9231V2.8125Z'%20fill='black'/%3e%3c/g%3e%3c/svg%3e";var Es=z('<span class="avatar-tag svelte-ga6vh2"> </span>'),As=z('<div class="avatar-container svelte-ga6vh2"><div class="avatar svelte-ga6vh2"><img width="1" height="1"/></div> <!></div>');const Ts={hash:"svelte-ga6vh2",code:".avatar-container.svelte-ga6vh2 {position:relative;display:inline-flex;flex-direction:column;align-items:center;flex-shrink:0;}.avatar.svelte-ga6vh2 {border-radius:50%;display:flex;align-items:flex-end;justify-content:center;overflow:hidden;}.avatar-image.svelte-ga6vh2 {width:75%;height:auto;display:block;margin-bottom:-6%;}.avatar-image--photo.svelte-ga6vh2 {width:100%;height:100%;margin-bottom:0;object-fit:cover;object-position:center top;}.avatar-tag.svelte-ga6vh2 {position:absolute;bottom:-5px;color:#fff;font-weight:700;letter-spacing:0.05em;border-radius:4px;border:1px solid #fff;white-space:nowrap;}"};function vi(t,e){lt(t,Ts);let r=D(e,"avatar",3,"man"),n=D(e,"size",3,"md"),a=D(e,"tagColor",3,"var(--sevn-color-green)"),i=W(!1);const s=K(()=>r()==="woman"?ks:Ss),c=K(()=>!!e.photoUrl&&!o(i)),l=K(()=>o(c)?e.photoUrl:o(s)),d={sm:"40px",md:"56px",lg:"72px"},f={sm:{fontSize:"9px",padding:"1px 5px"},md:{fontSize:"12px",padding:"2px 8px"},lg:{fontSize:"14px",padding:"3px 10px"}},_=K(()=>d[n()]??n()),v=K(()=>f[n()]??f.md);var p=As(),m=b(p),A=b(m);let g;var k=L(m,2);{var S=P=>{var O=Es(),I=b(O);R(()=>{rt(O,`background-color: ${a()??""}; font-size: ${o(v).fontSize??""}; padding: ${o(v).padding??""};`),U(I,e.tag)}),x(P,O)};j(k,P=>{e.tag&&P(S)})}R(()=>{rt(m,`background-color: ${e.avatarColor??"var(--sevn-color-secondary)"??""}; width: ${o(_)??""}; height: ${o(_)??""};`),g=Te(A,1,"avatar-image svelte-ga6vh2",null,g,{"avatar-image--photo":o(c)}),ae(A,"src",o(l)),ae(A,"alt",e.name)}),kn("error",A,()=>y(i,!0)),x(t,p)}const Ms="data:image/svg+xml,%3csvg%20width='32'%20height='32'%20viewBox='0%200%2032%2032'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M25.9798%2026.872L17.6305%2018.5227C16.9638%2019.0907%2016.1971%2019.5302%2015.3305%2019.8413C14.4638%2020.1524%2013.5927%2020.308%2012.7171%2020.308C10.582%2020.308%208.77493%2019.5689%207.29582%2018.0907C5.8167%2016.6124%205.07715%2014.8058%205.07715%2012.6707C5.07715%2010.5356%205.81581%208.728%207.29315%207.248C8.77048%205.768%2010.5767%205.02711%2012.7118%205.02533C14.8469%205.02356%2016.6549%205.76311%2018.1358%207.244C19.6167%208.72489%2020.3571%2010.5324%2020.3571%2012.6667C20.3571%2013.5929%2020.1931%2014.4893%2019.8651%2015.356C19.5371%2016.2227%2019.106%2016.964%2018.5718%2017.58L26.9211%2025.928L25.9798%2026.872ZM12.7185%2018.9733C14.4874%2018.9733%2015.9807%2018.3644%2017.1985%2017.1467C18.4163%2015.9289%2019.0251%2014.4351%2019.0251%2012.6653C19.0251%2010.8956%2018.4163%209.40222%2017.1985%208.18533C15.9807%206.96844%2014.4874%206.35956%2012.7185%206.35867C10.9496%206.35778%209.45581%206.96667%208.23715%208.18533C7.01848%209.404%206.40959%2010.8973%206.41048%2012.6653C6.41137%2014.4333%207.02026%2015.9267%208.23715%2017.1453C9.45404%2018.364%2010.9474%2018.9729%2012.7171%2018.972'%20fill='%231C1C1C'/%3e%3c/svg%3e",ui="data:image/svg+xml,%3csvg%20width='13'%20height='8'%20viewBox='0%200%2013%208'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M11.91%20-0.00016065L12.97%201.06084L7.193%206.83984C7.10043%206.93299%206.99036%207.00692%206.86911%207.05737C6.74786%207.10782%206.61783%207.13379%206.4865%207.13379C6.35517%207.13379%206.22514%207.10782%206.10389%207.05737C5.98264%207.00692%205.87257%206.93299%205.78%206.83984L2.65457e-07%201.06084L1.06%200.000838803L6.485%205.42484L11.91%20-0.00016065Z'%20fill='black'/%3e%3c/svg%3e",hi="data:image/svg+xml,%3csvg%20width='12'%20height='12'%20viewBox='0%200%2012%2012'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M10.5%201.5L1.5%2010.5M1.5%201.5L10.5%2010.5'%20stroke='black'%20stroke-width='1.6'%20stroke-linecap='round'/%3e%3c/svg%3e";var Ls=z('<span class="mobile-label svelte-1dw55dz"> </span>'),Rs=z('<input class="search-input svelte-1dw55dz" type="text"/>'),js=z('<span class="field-label-prefix svelte-1dw55dz"> </span>'),Os=z('<span class="field-text svelte-1dw55dz"><!> </span>'),Ps=z("<span> </span>"),Ds=z('<button class="icon-clear svelte-1dw55dz" type="button" aria-label="Limpar seleção"><img alt="" aria-hidden="true"/></button>'),Is=z('<img alt="" aria-hidden="true"/>'),Ns=z('<img class="icon-search svelte-1dw55dz" alt="" aria-hidden="true"/>'),qs=z('<span class="meta svelte-1dw55dz"> </span>'),Fs=z('<div class="web-info svelte-1dw55dz"><span class="selected-label svelte-1dw55dz"><strong class="svelte-1dw55dz">Você selecionou:</strong> </span> <!></div>'),Hs=z('<button type="button" role="option"> </button>'),Bs=z('<div class="no-results svelte-1dw55dz">Nenhum resultado encontrado</div>'),Us=z('<div class="dropdown svelte-1dw55dz" role="listbox"></div>'),Vs=z('<div><!> <div role="combobox" aria-haspopup="listbox"><!> <!></div> <!> <!></div>');const Ks={hash:"svelte-1dw55dz",code:`.autocomplete.svelte-1dw55dz {position:relative;width:var(--field-width);font-family:inherit;}
6
+
7
+ /* ── Label (mobile only) ─────────────────────────────── */.mobile-label.svelte-1dw55dz {display:none;font-size:0.875rem;font-weight:600;color:var(--sevn-color-tertiary);margin-bottom:6px;}
8
+
9
+ @media (max-width: 768px) {.mobile-label.svelte-1dw55dz {display:block;}
10
+ }
11
+
12
+ /* ── Campo principal ─────────────────────────────────── */.field.svelte-1dw55dz {display:flex;align-items:center;width:100%;height:var(--field-height);padding:0 14px;background:var(--sevn-color-neutral);border:1px solid transparent;border-radius:8px;cursor:pointer;gap:8px;transition:border-color 0.15s, box-shadow 0.15s;color:var(--sevn-color-tertiary);}.field.svelte-1dw55dz:hover {border-color:#d1d1d6;}.field.disabled.svelte-1dw55dz {cursor:not-allowed;opacity:0.55;}.field.disabled.svelte-1dw55dz:hover {border-color:transparent;}.field.open.svelte-1dw55dz {border-color:var(--sevn-color-primary);box-shadow:0 0 0 2px color-mix(in srgb, var(--sevn-color-primary) 15%, transparent);background:#fff;}
13
+
14
+ /* ── Texto do campo ──────────────────────────────────── */.field-text.svelte-1dw55dz {flex:1;text-align:left;font-size:0.9375rem;color:var(--sevn-color-tertiary);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}.field-text.is-placeholder.svelte-1dw55dz {color:#9a9aaa;}.field-label-prefix.svelte-1dw55dz {font-weight:600;margin-right:4px;}
15
+
16
+ /* ── Input de busca ──────────────────────────────────── */.search-input.svelte-1dw55dz {flex:1;border:none;outline:none;font-size:0.9375rem;font-family:inherit;color:var(--sevn-color-tertiary);background:transparent;min-width:0;}.search-input.svelte-1dw55dz::placeholder {color:#9a9aaa;}
17
+
18
+ /* ── Ícone de lupa ───────────────────────────────────── */.icon-search.svelte-1dw55dz {flex-shrink:0;}.field.open.svelte-1dw55dz .icon-search:where(.svelte-1dw55dz) {opacity:1;}
19
+
20
+ /* ── Botão de limpar ─────────────────────────────────── */.icon-clear.svelte-1dw55dz {display:flex;align-items:center;justify-content:center;flex-shrink:0;padding:0;background:none;border:none;border-radius:50%;cursor:pointer;transition:background 0.15s;}.icon-clear.svelte-1dw55dz:hover,
21
+ .icon-clear.svelte-1dw55dz:focus-visible {background:rgba(0, 0, 0, 0.08);}
22
+
23
+ /* ── Ícone de chevron ────────────────────────────────── */.icon-chevron.svelte-1dw55dz {flex-shrink:0;transition:transform 0.2s ease;}.icon-chevron.open.svelte-1dw55dz {transform:rotate(180deg);}
24
+
25
+ /* ── "Você selecionou" (web only) ────────────────────── */.web-info.svelte-1dw55dz {display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin-top:20px;font-size:0.8125rem;color:var(--sevn-color-tertiary);}.selected-label.svelte-1dw55dz strong:where(.svelte-1dw55dz) {font-weight:600;}.meta.svelte-1dw55dz {font-size:0.7rem;opacity:50%;}
26
+
27
+ @media (max-width: 768px) {.web-info.svelte-1dw55dz {display:none;}.field-text.svelte-1dw55dz {font-weight:600;}.field-text.is-placeholder.svelte-1dw55dz:not(.force-placeholder) {display:none;}.search-input.svelte-1dw55dz::placeholder {color:transparent;}.show-placeholder-mobile.svelte-1dw55dz .search-input:where(.svelte-1dw55dz)::placeholder {color:#9a9aaa;}.icon-search.svelte-1dw55dz {margin-left:auto;}
28
+ }
29
+
30
+ /* ── Dropdown ────────────────────────────────────────── */.dropdown.svelte-1dw55dz {position:absolute;top:calc(var(--field-height) + 6px);left:0;right:0;background:#fff;border:1px solid #d1d1d6;border-radius:8px;max-height:240px;overflow-y:auto;z-index:200;box-shadow:0 6px 16px rgba(0, 0, 0, 0.1);scrollbar-width:thin;scrollbar-color:#d1d1d6 transparent;}.dropdown.svelte-1dw55dz::-webkit-scrollbar {width:4px;}.dropdown.svelte-1dw55dz::-webkit-scrollbar-track {background:transparent;}.dropdown.svelte-1dw55dz::-webkit-scrollbar-thumb {background-color:#d1d1d6;border-radius:4px;}
31
+
32
+ /* ── Opção ───────────────────────────────────────────── */.option.svelte-1dw55dz {display:block;width:100%;padding:11px 14px;text-align:left;background:none;border:none;border-bottom:1px solid #f0f0f5;cursor:pointer;font-size:0.9375rem;font-family:inherit;color:var(--sevn-color-tertiary);transition:background 0.1s;line-height:1.4;}.option.svelte-1dw55dz:last-child {border-bottom:none;}.option.svelte-1dw55dz:hover {background:var(--sevn-color-neutral);}.option.selected.svelte-1dw55dz {background:color-mix(in srgb, var(--sevn-color-primary) 8%, transparent);color:var(--sevn-color-primary);font-weight:600;}.no-results.svelte-1dw55dz {padding:14px;color:#9a9aaa;font-size:0.875rem;text-align:center;}`};function pi(t,e){Ut(e,!0),lt(t,Ks);let r=D(e,"label",3,""),n=D(e,"showLabel",3,!0),a=D(e,"options",19,()=>[]),i=D(e,"value",15,null),s=D(e,"meta",3,""),c=D(e,"width",3,"100%"),l=D(e,"height",3,"48px"),d=D(e,"icon",3,Ms),f=D(e,"iconSize",3,13),_=D(e,"showLabelInField",3,!1),v=D(e,"showDescriptionSelection",3,!0),p=D(e,"labelAsPlaceholder",3,!0),m=D(e,"showPlaceholderOnMobile",3,!1),A=D(e,"disabled",3,!1),g=D(e,"clearable",3,!0);const k=`autocomplete-listbox-${Math.random().toString(36).slice(2,9)}`;let S=W(!1),P=W(""),O=W(null),I=W(null),ee=K(()=>o(P).trim()?a().filter(w=>w.label.toLowerCase().includes(o(P).trim().toLowerCase())):a()),q=K(()=>i()!=null?a().find(w=>w.value===i())??null:null);function X(w){i(w.value),y(P,""),y(S,!1)}function N(){A()||(y(S,!o(S)),o(S)||y(P,""))}function F(w){w.stopPropagation(),i(null),y(P,""),y(S,!1)}function ie(w){w.target===w.currentTarget&&(w.key==="Enter"||w.key===" ")&&(w.preventDefault(),N())}function ge(w){o(O)&&!o(O).contains(w.target)&&(y(S,!1),y(P,""))}function Se(w){w.key==="Escape"&&(y(S,!1),y(P,""))}xt(()=>{o(S)&&o(I)&&o(I).focus()}),xt(()=>{A()&&(y(S,!1),y(P,""))}),di(()=>(document.addEventListener("mousedown",ge),()=>document.removeEventListener("mousedown",ge)));var ce=Vs();let Ue;var it=b(ce);{var Me=w=>{var M=Ls(),h=b(M);R(()=>U(h,r())),x(w,M)};j(it,w=>{n()&&r()&&w(Me)})}var te=L(it,2);let V;var oe=b(te);{var se=w=>{var M=Rs();Pr(M,h=>y(I,h),()=>o(I)),R(()=>ae(M,"placeholder",r())),qe("keydown",M,Se),qe("click",M,h=>h.stopPropagation()),ws(M,()=>o(P),h=>y(P,h)),x(w,M)},Ve=w=>{var M=Os(),h=b(M);{var C=Q=>{var fe=js(),be=b(fe);R(()=>U(be,r())),x(Q,fe)};j(h,Q=>{_()&&Q(C)})}var H=L(h,1,!0);R(()=>U(H,o(q).label)),x(w,M)},Et=w=>{var M=pr(),h=bt(M);{var C=H=>{var Q=Ps();let fe;var be=b(Q);R(()=>{fe=Te(Q,1,"field-text is-placeholder svelte-1dw55dz",null,fe,{"force-placeholder":m()}),U(be,r())}),x(H,Q)};j(h,H=>{p()&&H(C)})}x(w,M)};j(oe,w=>{o(S)?w(se):o(q)?w(Ve,1):w(Et,!1)})}var ut=L(oe,2);{var he=w=>{var M=Ds(),h=b(M);R(()=>{ae(h,"src",hi),ae(h,"width",f()?f():12),ae(h,"height",f()?f():12)}),qe("click",M,F),x(w,M)},ke=w=>{var M=Is();let h;R(()=>{h=Te(M,1,"icon-chevron svelte-1dw55dz",null,h,{open:o(S)}),ae(M,"src",ui),ae(M,"width",f()?f():12),ae(M,"height",f()?f():12)}),x(w,M)},Ee=w=>{var M=Ns();R(()=>{ae(M,"src",d()),ae(M,"width",f()),ae(M,"height",f())}),x(w,M)};j(ut,w=>{o(q)&&g()&&!A()?w(he):o(q)?w(ke,1):w(Ee,!1)})}var ot=L(te,2);{var T=w=>{var M=Fs(),h=b(M),C=L(b(h)),H=L(h,2);{var Q=fe=>{var be=qs(),pe=b(be);R(()=>U(pe,s())),x(fe,be)};j(H,fe=>{s()&&fe(Q)})}R(()=>U(C,` ${o(q).label??""}`)),x(w,M)};j(ot,w=>{o(q)&&v()&&w(T)})}var E=L(ot,2);{var Z=w=>{var M=Us();Qt(M,21,()=>o(ee),h=>h.value,(h,C)=>{var H=Hs();let Q;var fe=b(H);R(()=>{Q=Te(H,1,"option svelte-1dw55dz",null,Q,{selected:o(C).value===i()}),ae(H,"aria-selected",o(C).value===i()),U(fe,o(C).label)}),qe("click",H,()=>X(o(C))),x(h,H)},h=>{var C=Bs();x(h,C)}),R(()=>ae(M,"id",k)),x(w,M)};j(E,w=>{o(S)&&w(Z)})}Pr(ce,w=>y(O,w),()=>o(O)),R(()=>{Ue=Te(ce,1,"autocomplete svelte-1dw55dz",null,Ue,{"show-placeholder-mobile":m()}),rt(ce,`--field-width: ${c()??""}; --field-height: ${l()??""}`),V=Te(te,1,"field svelte-1dw55dz",null,V,{open:o(S),"has-value":o(q)&&!o(S),disabled:A()}),ae(te,"tabindex",A()?-1:0),ae(te,"aria-controls",k),ae(te,"aria-expanded",o(S)),ae(te,"aria-disabled",A())}),qe("click",te,N),qe("keydown",te,ie),x(t,ce),Vt()}En(["click","keydown"]);var Gs=z("<span> </span>");const Ys={hash:"svelte-pamnib",code:".tag.svelte-pamnib {display:inline-flex;align-items:center;padding:4px 8px;border-radius:5px;font-family:inherit;font-weight:700;color:#ffffff;white-space:nowrap;letter-spacing:0.03em;width:fit-content;}"};function Pt(t,e){lt(t,Ys);let r=D(e,"color",3,"#1C1C1C"),n=D(e,"fontSize",3,"0.6875rem"),a=D(e,"class",3,"");var i=Gs(),s=b(i);R(()=>{Te(i,1,`tag ${a()??""}`,"svelte-pamnib"),rt(i,`background-color: ${r()??""}; font-size: ${n()??""}`),U(s,e.label)}),x(t,i)}var Ws=z('<p class="candidate-description svelte-q1jzvs"> </p>'),Zs=z('<span class="candidate-stats-percent-suffix svelte-q1jzvs"> </span>'),Js=z('<span class="candidate-stats-percent svelte-q1jzvs"> <!></span>'),Xs=z('<span class="candidate-stats-votes svelte-q1jzvs"> </span>'),Qs=z('<div class="candidate-stats svelte-q1jzvs"><!> <!></div>'),$s=z('<div class="candidate-wrapper svelte-q1jzvs"><!> <div><div class="candidate-name-row svelte-q1jzvs"><span class="candidate-name svelte-q1jzvs"> </span> <!> <!></div> <!></div></div>'),el=z('<p class="candidate-description svelte-q1jzvs"> </p>'),tl=z('<span class="candidate-stats-percent-suffix svelte-q1jzvs"> </span>'),rl=z('<span class="candidate-stats-percent svelte-q1jzvs"> <!></span>'),nl=z('<span class="candidate-stats-votes svelte-q1jzvs"> </span>'),al=z('<div class="candidate-stats svelte-q1jzvs"><!> <!></div>'),il=z('<!> <div><div class="candidate-name-row svelte-q1jzvs"><span class="candidate-name svelte-q1jzvs"> </span> <!> <!></div> <!></div>',1),ol=z("<span> </span>"),sl=z('<div class="candidate svelte-q1jzvs"><!> <!></div>');const ll={hash:"svelte-q1jzvs",code:`.candidate.svelte-q1jzvs {display:flex;align-items:center;justify-content:space-between;}.candidate-wrapper.svelte-q1jzvs {display:flex;align-items:center;gap:15px;}.candidate-info.svelte-q1jzvs {display:flex;flex-direction:column;gap:2px;}
33
+
34
+ /* Desktop: description on the right inside the info block */.candidate-info.right.svelte-q1jzvs {flex:1;flex-direction:row;flex-wrap:wrap;align-items:center;}.candidate-info.right.svelte-q1jzvs .candidate-description:where(.svelte-q1jzvs) {margin-left:auto;flex-shrink:0;}.candidate-name-row.svelte-q1jzvs {display:flex;align-items:center;gap:8px;flex-wrap:wrap;}.candidate-name.svelte-q1jzvs {font-size:var(--font-name);font-weight:var(--weight-name);color:var(--sevn-color-tertiary);line-height:1.2;}.candidate-description.svelte-q1jzvs {font-size:var(--font-desc);font-weight:var(--weight-desc);color:var(--sevn-color-tertiary);opacity:0.7;}.candidate-position.svelte-q1jzvs {font-size:var(--font-position);font-weight:600;color:var(--sevn-color-tertiary);white-space:nowrap;flex-shrink:0;margin-left:auto;}.candidate-position.left.svelte-q1jzvs {order:-1;margin-left:0;}
35
+
36
+ /* ── Stats ─────────────────────────────── */.candidate-stats.svelte-q1jzvs {display:flex;flex-direction:column;gap:4px;align-items:baseline;flex-shrink:0;}.candidate-stats-percent.svelte-q1jzvs {font-size:1rem;font-weight:700;color:var(--sevn-color-tertiary);line-height:1.2;}.candidate-stats-votes.svelte-q1jzvs {font-size:var(--font-desc);font-weight:400;color:var(--sevn-color-tertiary);opacity:0.7;}.candidate-stats-percent-suffix.svelte-q1jzvs {display:inline;margin-left:4px;}
37
+
38
+ @media (min-width: 768px) {.candidate-stats.svelte-q1jzvs {flex-direction:row;gap:8px;}.candidate-stats-percent-suffix.svelte-q1jzvs {display:none;}
39
+ }
40
+
41
+ @media (max-width: 640px) {.candidate.svelte-q1jzvs {flex:1;flex-wrap:wrap;align-items:center;}.candidate-info.svelte-q1jzvs {flex:1;}
42
+
43
+ /* Mobile: description keeps right alignment */.candidate-info.right.svelte-q1jzvs {flex-direction:row;align-items:center;}.candidate-position.svelte-q1jzvs {order:3;margin-left:auto;}.candidate-position.left.svelte-q1jzvs {order:-1;margin-left:0;}
44
+ }`};function cl(t,e){lt(t,ll);let r=D(e,"avatar",3,"man"),n=D(e,"elected",3,!1),a=D(e,"electedLabel",3,"ELEITO"),i=D(e,"electedColor",3,"var(--sevn-color-green)"),s=D(e,"descriptionSide",3,"inline"),c=D(e,"positionSide",3,"right"),l=D(e,"size",3,"md"),d=D(e,"nameWeight",3,700),f=D(e,"descWeight",3,400),_=D(e,"wrapper",3,!1);const v={sm:{fontSize:"0.875rem",descSize:"0.75rem",tagSize:"0.625rem"},md:{fontSize:"1.125rem",descSize:"0.875rem",tagSize:"0.6875rem"},lg:{fontSize:"1.375rem",descSize:"1rem",tagSize:"0.75rem"}},p=K(()=>v[l()]??v.md);var m=sl(),A=b(m);{var g=O=>{var I=$s(),ee=b(I);vi(ee,{get name(){return e.name},get photoUrl(){return e.photoUrl},get avatar(){return r()},get avatarColor(){return e.avatarColor},get size(){return l()},get tag(){return e.avatarTag},get tagColor(){return e.avatarTagColor}});var q=L(ee,2);let X;var N=b(q),F=b(N),ie=b(F),ge=L(F,2);{var Se=V=>{{let oe=K(()=>e.tagColor??"var(--sevn-color-secondary)"),se=K(()=>e.tagSize??o(p).tagSize);Pt(V,{get label(){return e.tag},get color(){return o(oe)},get fontSize(){return o(se)}})}};j(ge,V=>{e.tag&&V(Se)})}var ce=L(ge,2);{var Ue=V=>{{let oe=K(()=>e.tagSize??o(p).tagSize);Pt(V,{get label(){return a()},get color(){return i()},get fontSize(){return o(oe)}})}};j(ce,V=>{n()&&V(Ue)})}var it=L(N,2);{var Me=V=>{var oe=Ws(),se=b(oe);R(()=>U(se,e.description)),x(V,oe)},te=V=>{var oe=Qs(),se=b(oe);{var Ve=he=>{var ke=Js(),Ee=b(ke),ot=L(Ee);{var T=E=>{var Z=Zs(),w=b(Z);R(()=>U(w,e.percentSuffix)),x(E,Z)};j(ot,E=>{e.percentSuffix&&E(T)})}R(()=>U(Ee,`${e.percent??""} `)),x(he,ke)};j(se,he=>{e.percent&&he(Ve)})}var Et=L(se,2);{var ut=he=>{var ke=Xs(),Ee=b(ke);R(()=>U(Ee,e.votes)),x(he,ke)};j(Et,he=>{e.votes&&he(ut)})}x(V,oe)};j(it,V=>{e.description?V(Me):(e.percent||e.votes)&&V(te,1)})}R(()=>{X=Te(q,1,"candidate-info svelte-q1jzvs",null,X,{right:s()==="right"&&!!e.description}),U(ie,e.name)}),x(O,I)},k=O=>{var I=il(),ee=bt(I);vi(ee,{get name(){return e.name},get photoUrl(){return e.photoUrl},get avatar(){return r()},get avatarColor(){return e.avatarColor},get size(){return l()},get tag(){return e.avatarTag},get tagColor(){return e.avatarTagColor}});var q=L(ee,2);let X;var N=b(q),F=b(N),ie=b(F),ge=L(F,2);{var Se=V=>{{let oe=K(()=>e.tagColor??"var(--sevn-color-secondary)"),se=K(()=>e.tagSize??o(p).tagSize);Pt(V,{get label(){return e.tag},get color(){return o(oe)},get fontSize(){return o(se)}})}};j(ge,V=>{e.tag&&V(Se)})}var ce=L(ge,2);{var Ue=V=>{{let oe=K(()=>e.tagSize??o(p).tagSize);Pt(V,{get label(){return a()},get color(){return i()},get fontSize(){return o(oe)}})}};j(ce,V=>{n()&&V(Ue)})}var it=L(N,2);{var Me=V=>{var oe=el(),se=b(oe);R(()=>U(se,e.description)),x(V,oe)},te=V=>{var oe=al(),se=b(oe);{var Ve=he=>{var ke=rl(),Ee=b(ke),ot=L(Ee);{var T=E=>{var Z=tl(),w=b(Z);R(()=>U(w,e.percentSuffix)),x(E,Z)};j(ot,E=>{e.percentSuffix&&E(T)})}R(()=>U(Ee,`${e.percent??""} `)),x(he,ke)};j(se,he=>{e.percent&&he(Ve)})}var Et=L(se,2);{var ut=he=>{var ke=nl(),Ee=b(ke);R(()=>U(Ee,e.votes)),x(he,ke)};j(Et,he=>{e.votes&&he(ut)})}x(V,oe)};j(it,V=>{e.description?V(Me):(e.percent||e.votes)&&V(te,1)})}R(()=>{X=Te(q,1,"candidate-info svelte-q1jzvs",null,X,{right:s()==="right"&&!!e.description}),U(ie,e.name)}),x(O,I)};j(A,O=>{_()?O(g):O(k,!1)})}var S=L(A,2);{var P=O=>{var I=ol();let ee;var q=b(I);R(()=>{ee=Te(I,1,"candidate-position svelte-q1jzvs",null,ee,{left:c()==="left"}),U(q,e.position)}),x(O,I)};j(S,O=>{e.position&&O(P)})}R(()=>rt(m,`
45
+ --font-name: ${e.fontSize??o(p).fontSize??""};
46
+ --font-desc: ${e.descSize??o(p).descSize??""};
47
+ --font-tag: ${e.tagSize??o(p).tagSize??""};
48
+ --font-position: ${e.positionSize??o(p).fontSize??""};
49
+ --weight-name: ${d()??""};
50
+ --weight-desc: ${f()??""};
51
+ gap: ${_()?"10px":"18px"};
52
+ `)),x(t,m)}var dl=z("<span> </span>"),fl=z('<div class="vote-overview-stats svelte-1m9ufac"></div>'),vl=z("<span> </span>"),ul=z('<span class="vote-overview-sep svelte-1m9ufac">|</span>'),hl=z("<span> </span>"),pl=z('<div class="vote-overview-meta svelte-1m9ufac"><!> <!> <!></div>'),gl=z('<div class="vote-overview svelte-1m9ufac"><!> <!></div>');const _l={hash:"svelte-1m9ufac",code:".vote-overview.svelte-1m9ufac {display:flex;align-items:center;padding:0.5rem 1rem;font-size:0.8rem;color:#1c1c1c;gap:1rem;flex-wrap:wrap;opacity:50%;}.vote-overview-stats.svelte-1m9ufac {display:flex;align-items:center;gap:1.5rem;font-weight:600;}.vote-overview-meta.svelte-1m9ufac {display:flex;align-items:center;gap:0.4rem;font-weight:400;white-space:nowrap;}.vote-overview-sep.svelte-1m9ufac {opacity:0.4;}"};function gi(t,e){Ut(e,!0),lt(t,_l);let r=D(e,"data",19,()=>[]),n=D(e,"borderTop",3,!1),a=D(e,"align",3,"start");var i=gl(),s=b(i);{var c=f=>{var _=fl();Qt(_,21,r,Rr,(v,p)=>{var m=dl(),A=b(m);R(()=>U(A,`${o(p).text??""} ${o(p).value??""}`)),x(v,m)}),x(f,_)};j(s,f=>{r().length&&f(c)})}var l=L(s,2);{var d=f=>{var _=pl(),v=b(_);{var p=S=>{var P=vl(),O=b(P);R(()=>U(O,`Atualizado em ${e.date??""}`)),x(S,P)};j(v,S=>{e.date&&S(p)})}var m=L(v,2);{var A=S=>{var P=ul();x(S,P)};j(m,S=>{e.date&&e.font&&S(A)})}var g=L(m,2);{var k=S=>{var P=hl(),O=b(P);R(()=>U(O,`Fonte ${e.font??""}`)),x(S,P)};j(g,S=>{e.font&&S(k)})}x(f,_)};j(l,f=>{(e.date||e.font)&&f(d)})}R(()=>rt(i,`justify-content:${a()==="end"?"flex-end":"flex-start"};${n()?"border-top:1px solid var(--sevn-color-neutral)":""}`)),x(t,i),Vt()}var ml=z('<span class="trigger-label svelte-hkzjiw"> </span>'),wl=z('<img alt="" aria-hidden="true" width="10" height="10"/>'),bl=z('<button class="clear svelte-hkzjiw" type="button"><img alt="" aria-hidden="true" width="8" height="8"/></button>'),yl=z('<button type="button" role="option"> </button>'),xl=z('<div class="dropdown svelte-hkzjiw" role="listbox"></div>'),Cl=z('<div class="filter-dropdown svelte-hkzjiw"><button type="button" aria-haspopup="listbox"><!> <span class="trigger-value svelte-hkzjiw"> </span> <!></button> <!> <!></div>');const zl={hash:"svelte-hkzjiw",code:`.filter-dropdown.svelte-hkzjiw {position:relative;display:inline-flex;align-items:center;}
53
+
54
+ /* ── Trigger ─────────────────────────────── */.trigger.svelte-hkzjiw {display:inline-flex;align-items:center;gap:4px;padding:0;background:none;border:none;cursor:pointer;font-family:inherit;font-size:0.875rem;color:var(--sevn-color-tertiary);white-space:nowrap;}.trigger-label.svelte-hkzjiw {font-weight:700;}.trigger-value.svelte-hkzjiw {font-weight:400;}.trigger-chevron.svelte-hkzjiw {flex-shrink:0;transition:transform 0.2s ease;margin-left:2px;}.trigger-chevron.rotated.svelte-hkzjiw {transform:rotate(180deg);}
55
+
56
+ /* ── Botão de limpar ─────────────────────── */.clear.svelte-hkzjiw {display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;width:16px;height:16px;margin-left:4px;padding:0;background:none;border:none;border-radius:50%;cursor:pointer;transition:background 0.15s;}.clear.svelte-hkzjiw:hover,
57
+ .clear.svelte-hkzjiw:focus-visible {background:rgba(0, 0, 0, 0.08);}
58
+
59
+ /* ── Dropdown ────────────────────────────── */.dropdown.svelte-hkzjiw {position:absolute;top:calc(100% + 6px);left:0;min-width:100%;background:#fff;border:1px solid #d1d1d6;border-radius:8px;box-shadow:0 6px 16px rgba(0, 0, 0, 0.1);z-index:200;overflow:hidden;}
60
+
61
+ /* ── Options ─────────────────────────────── */.option.svelte-hkzjiw {display:block;width:100%;padding:10px 14px;text-align:left;background:none;border:none;border-bottom:1px solid #f0f0f5;cursor:pointer;font-size:0.875rem;font-family:inherit;color:var(--sevn-color-tertiary);white-space:nowrap;transition:background 0.1s;}.option.svelte-hkzjiw:last-child {border-bottom:none;}.option.svelte-hkzjiw:hover {background:var(--sevn-color-neutral);}.option.selected.svelte-hkzjiw {background:color-mix(in srgb, var(--sevn-color-primary) 8%, transparent);color:var(--sevn-color-primary);font-weight:600;}`};function Sl(t,e){Ut(e,!0),lt(t,zl);let r=D(e,"label",3,""),n=D(e,"options",19,()=>[]),a=D(e,"value",15,null),i=D(e,"clearable",3,!0),s=W(!1),c=W(null);const l=K(()=>a()!=null?n().find(N=>N.value===a())??null:null);function d(N){a(N.value),y(s,!1)}function f(){a(null),y(s,!1)}function _(N){o(c)&&!o(c).contains(N.target)&&y(s,!1)}di(()=>(document.addEventListener("mousedown",_),()=>document.removeEventListener("mousedown",_)));var v=Cl(),p=b(v);let m;var A=b(p);{var g=N=>{var F=ml(),ie=b(F);R(()=>U(ie,`${r()??""}:`)),x(N,F)};j(A,N=>{r()&&N(g)})}var k=L(A,2),S=b(k),P=L(k,2);{var O=N=>{var F=wl();let ie;R(()=>{ie=Te(F,1,"trigger-chevron svelte-hkzjiw",null,ie,{rotated:o(s)}),ae(F,"src",ui)}),x(N,F)};j(P,N=>{o(l)&&i()||N(O)})}var I=L(p,2);{var ee=N=>{var F=bl(),ie=b(F);R(()=>{ae(F,"aria-label",`Limpar ${(r()||"filtro")??""}`),ae(ie,"src",hi)}),qe("click",F,f),x(N,F)};j(I,N=>{o(l)&&i()&&N(ee)})}var q=L(I,2);{var X=N=>{var F=xl();Qt(F,21,n,ie=>ie.value,(ie,ge)=>{var Se=yl();let ce;var Ue=b(Se);R(()=>{ce=Te(Se,1,"option svelte-hkzjiw",null,ce,{selected:o(ge).value===a()}),ae(Se,"aria-selected",o(ge).value===a()),U(Ue,o(ge).label)}),qe("click",Se,()=>d(o(ge))),x(ie,Se)}),x(N,F)};j(q,N=>{o(s)&&N(X)})}Pr(v,N=>y(c,N),()=>o(c)),R(()=>{m=Te(p,1,"trigger svelte-hkzjiw",null,m,{open:o(s)}),ae(p,"aria-expanded",o(s)),U(S,o(l)?o(l).label:"")}),qe("click",p,()=>y(s,!o(s))),x(t,v),Vt()}En(["click"]);var kl=z('<span class="header-tag-above svelte-1xm1ks6"><!></span>'),El=z('<span class="header-tag-inline svelte-1xm1ks6"><!></span>'),Al=z('<p class="header-description svelte-1xm1ks6"> </p>'),Tl=z('<header class="header svelte-1xm1ks6"><!> <div class="header-title-row svelte-1xm1ks6"><h1 class="header-title svelte-1xm1ks6"> </h1> <!></div> <!></header>');const Ml={hash:"svelte-1xm1ks6",code:`.header.svelte-1xm1ks6 {display:flex;flex-direction:column;gap:4px;}.header-tag-inline.svelte-1xm1ks6 {display:none;}.header-title-row.svelte-1xm1ks6 {display:flex;align-items:center;gap:10px;}.header-title.svelte-1xm1ks6 {font-size:var(--header-title-font-size);font-weight:var(--header-title-font-weight);color:var(--sevn-color-tertiary);line-height:1.15;}.header-description.svelte-1xm1ks6 {font-size:var(--header-description-font-size);color:var(--sevn-color-tertiary);}
62
+
63
+ @media (max-width: 767px) {.header-title.svelte-1xm1ks6 {font-size:calc(var(--header-title-font-size) * 0.75);max-width:60%;}.header-description.svelte-1xm1ks6 {font-size:calc(var(--header-description-font-size) * 0.9);}
64
+ }
65
+
66
+ @media (min-width: 768px) {.header-tag-above.svelte-1xm1ks6 {display:none;}.header-tag-inline.svelte-1xm1ks6 {display:inline-flex;}
67
+ }`};function Ll(t,e){lt(t,Ml);var r=Tl(),n=b(r);{var a=v=>{var p=kl(),m=b(p);Pt(m,{get label(){return e.tag},get color(){return e.tagColor}}),x(v,p)};j(n,v=>{e.tag&&v(a)})}var i=L(n,2),s=b(i),c=b(s),l=L(s,2);{var d=v=>{var p=El(),m=b(p);Pt(m,{get label(){return e.tag},get color(){return e.tagColor}}),x(v,p)};j(l,v=>{e.tag&&v(d)})}var f=L(i,2);{var _=v=>{var p=Al(),m=b(p);R(()=>U(m,e.description)),x(v,p)};j(f,v=>{e.description&&v(_)})}R(()=>{rt(r,`
68
+ --header-title-font-size: ${e.titleFontSize??"1.75rem"??""};
69
+ --header-title-font-weight: ${e.titleFontWeight??700??""};
70
+ --header-description-font-size: ${e.descriptionFontSize??"0.875rem"??""};
71
+ `),U(c,e.title)}),x(t,r)}const _i=new Map,en=new Map;function Rl(t){const e=_i.get(t);if(e!==void 0)return Promise.resolve(e);const r=en.get(t);if(r)return r;const n=ln(`maps/${t}.svg`),a=fetch(n).then(i=>{if(!i.ok)throw new Error(`Mapa indisponível (HTTP ${i.status}): ${t}`);return i.text()}).then(i=>(_i.set(t,i),en.delete(t),i)).catch(i=>{throw en.delete(t),i});return en.set(t,a),a}let jl=0;var Ol=z('<img alt="Mapa do Brasil" decoding="async" class="svelte-1956iuh"/>'),Pl=z('<div class="map-placeholder svelte-1956iuh" aria-hidden="true"></div>'),Dl=z('<div class="map-error svelte-1956iuh">Mapa não encontrado</div>'),Il=z('<p class="map-modal-title svelte-1956iuh"> </p>'),Nl=z('<div class="map-modal-item svelte-1956iuh"><!></div>'),ql=z('<div class="map-modal-footer svelte-1956iuh"> </div>'),Fl=z('<div class="map-modal svelte-1956iuh" role="dialog" tabindex="-1"><div class="map-modal-card svelte-1956iuh"><!> <!> <!></div></div>'),Hl=z("<div><!> <!> <!></div>");const Bl={hash:"svelte-1956iuh",code:`.map.svelte-1956iuh {display:block;width:100%;}.map.svelte-1956iuh img:where(.svelte-1956iuh),
72
+ .map.svelte-1956iuh svg {width:100%;height:100%;display:block;}
73
+
74
+ /* Default fill for uncolored paths */.map.svelte-1956iuh path {fill:var(--sevn-color-neutral);}
75
+
76
+ /* Pointer cursor and smooth hover on clickable regions */.map.interactive.svelte-1956iuh path[data-cid],
77
+ .map.interactive.svelte-1956iuh g[data-cid],
78
+ .map.interactive.svelte-1956iuh a[data-cid] {cursor:pointer;}.map.interactive.svelte-1956iuh path[data-cid],
79
+ .map.interactive.svelte-1956iuh a[data-cid] path {transition:filter 0.12s ease;}.map.interactive.svelte-1956iuh path[data-cid]:hover,
80
+ .map.interactive.svelte-1956iuh a[data-cid]:hover path {filter:brightness(1.15);}
81
+
82
+ /* State labels: font-size is set as SVG attr (0.8 user units) so it scales with the map.
83
+ stroke-width in em stays proportional to font-size. */.map.svelte-1956iuh .map-labels text {font-family:inherit;font-weight:600;fill:white;stroke:rgba(0, 0, 0, 0.35);stroke-width:0.06em;paint-order:stroke fill;letter-spacing:0.04em;}
84
+
85
+ /* Floating modal — positioned at the click point inside the map container.
86
+ transform centers it horizontally and places it above the cursor. */.map-modal.svelte-1956iuh {position:absolute;z-index:10;transform:translate(-50%, calc(-100% - 12px));pointer-events:auto;}.map-modal-card.svelte-1956iuh {background:white;border-radius:10px;box-shadow:0 4px 20px rgba(0, 0, 0, 0.15);padding:14px 16px;min-width:210px;font-family:inherit;}.map-modal-title.svelte-1956iuh {font-size:0.8125rem;font-weight:600;color:var(--sevn-color-tertiary);margin:0 0 10px;}.map-modal-item.svelte-1956iuh {margin-bottom:10px;}.map-modal-footer.svelte-1956iuh {border-top:1px solid #f0f0f5;margin-top:10px;padding-top:8px;font-size:0.75rem;color:#9a9aaa;}.map-placeholder.svelte-1956iuh {position:absolute;inset:0;background:var(--sevn-color-neutral);border-radius:4px;
87
+ animation: svelte-1956iuh-pulse 1.4s ease-in-out infinite;}.map-error.svelte-1956iuh {position:absolute;inset:0;display:flex;align-items:center;justify-content:center;color:var(--sevn-color-red);font-size:0.85rem;}.map-modal-card.svelte-1956iuh .candidate {justify-content:flex-start;}
88
+
89
+ @keyframes svelte-1956iuh-pulse {
90
+ 0%, 100% { opacity: 1; }
91
+ 50% { opacity: 0.4; }
92
+ }`};function mi(t,e){Ut(e,!0),lt(t,Bl);let r=D(e,"aspectRatio",3,"4/3"),n=D(e,"class",3,""),a=D(e,"priority",3,!1),i=D(e,"selectionStrokeWidth",3,3),s=D(e,"toggleSelection",3,!1),c=D(e,"modalTrigger",3,"click");const l=K(()=>c()==="click"||c()==="both"),d=K(()=>c()==="hover"||c()==="both"),f=++jl,_=ln("maps/brazil-municipalities.svg");let v=K(()=>e.type==="brazil"?`map--brazil-${f}`:e.type==="state"?`map--state-${e.uf??""}-${f}`:`map--muni-${e.uf??""}-${e.municipio??""}-${f}`),p=K(()=>!!e.interactive||!!e.onRegionClick||!!e.onRegionHover||!!e.selectionStroke||!!e.modalData),m=K(()=>e.type==="brazil-states"||e.type!=="brazil"||!!e.colors?.length||!!e.labels||!!e.onRegionClick||!!e.onRegionHover||!!e.selectionStroke||!!e.modalData),A=K(()=>o(m)?e.type==="brazil-states"?"br":e.type==="brazil"&&e.labels?"brazil-municipalities-labeled":e.type==="brazil"?"brazil-municipalities":e.type==="state"&&e.uf?`states/${e.uf}`:e.uf&&e.municipio?`municipalities/${e.uf}/${e.municipio}`:null:null),g=W(null);xt(()=>{e.selected!==void 0&&y(g,e.selected,!0)});let k=W(null),S=W(0),P=W(0),O=W(""),I=W(!1),ee=W(!1),q=K(()=>e.type==="brazil"||e.type==="state"?`.${o(v)} path{stroke:#8a8a92;stroke-width:0.5px;vector-effect:non-scaling-stroke}`:""),X=K(()=>e.colors?.length?e.colors.map(({id:T,color:E,match:Z})=>{const w=Z==="endsWith"?`[data-cid$="::${T}"]`:`[data-cid="${T}"]`;return`.${o(v)} path${w},.${o(v)} ${w} path{fill:${E}!important}`}).join(""):""),N=K(()=>o(g)&&e.selectionStroke?`.${o(v)} [data-cid="${o(g)}"] path{stroke:${e.selectionStroke}!important;stroke-width:${i()}px!important;vector-effect:non-scaling-stroke!important;paint-order:stroke fill!important}`:""),F=K(()=>Nt?o(q)+o(X)+o(N):""),ie,ge=0;xt(()=>{const T=o(A);if(!T){y(O,""),y(I,!1);return}const E=++ge;function Z(){y(I,!0),y(ee,!1),y(O,""),Rl(T).then(M=>{E===ge&&(y(O,M,!0),y(I,!1),queueMicrotask(()=>{const h=ie?.querySelector("svg");if(!h)return;const C=h.querySelector(".map-labels");if(C){h.appendChild(C);return}h.querySelectorAll("text").forEach(H=>h.appendChild(H))}))}).catch(()=>{E===ge&&(y(ee,!0),y(I,!1))})}if(a()){Z();return}if(!ie){Z();return}const w=new IntersectionObserver(([M])=>{M.isIntersecting&&(w.disconnect(),Z())},{rootMargin:"200px"});return w.observe(ie),()=>w.disconnect()}),xt(()=>{if(!e.modalData)return;function T(E){E.key==="Escape"&&y(k,null)}return window.addEventListener("keydown",T),()=>window.removeEventListener("keydown",T)});let Se=W(null);function ce(T,E){const Z=E.getAttribute("data-cid")??"",w=Z.split("::"),M=w.length>1?w[1]||void 0:w[0]||void 0,h=w.length>1&&w[0]||void 0;return{cid:Z,uf:M,municipio:h,clientX:T.clientX,clientY:T.clientY,element:E}}function Ue(T){if(!o(p))return;const E=T.target.closest("[data-cid]");if(!E){c()==="click"&&y(k,null);return}const Z=E.getAttribute("data-cid")??"";if(!Z)return;y(g,s()&&o(g)===Z?null:Z,!0);const w=E.closest("svg"),M=E.parentNode;if(w&&M)if(M===w){const C=w.querySelector(":scope > .map-labels")??Array.from(w.children).find(H=>H.nodeName==="text");C?w.insertBefore(E,C):w.appendChild(E)}else M.appendChild(E);const h=ce(T,E);if(e.modalData&&o(l))if(o(k)?.cid===Z)y(k,null);else{const C=T.currentTarget.getBoundingClientRect();y(S,T.clientX-C.left),y(P,T.clientY-C.top),y(k,h,!0)}e.onRegionClick?.(h)}function it(T){if(!o(p)||!e.onRegionHover&&!o(d))return;const E=T.target.closest("[data-cid]");if(!E)return;const Z=E.getAttribute("data-cid")??"";if(!Z||Z===o(Se))return;y(Se,Z,!0);const w=ce(T,E);if(e.modalData&&o(d)){const M=T.currentTarget.getBoundingClientRect();y(S,T.clientX-M.left),y(P,T.clientY-M.top),y(k,w,!0)}e.onRegionHover?.(w)}function Me(){y(Se,null),o(d)&&y(k,null)}var te=Hl();let V;var oe=b(te);{var se=T=>{var E=pr(),Z=bt(E);oi(Z,()=>`<style>${o(F)}</style>`),x(T,E)};j(oe,T=>{o(F)&&T(se)})}var Ve=L(oe,2);{var Et=T=>{var E=Ol();R(()=>{ae(E,"src",_),ae(E,"fetchpriority",a()?"high":"auto"),ae(E,"loading",a()?"eager":"lazy")}),x(T,E)},ut=T=>{var E=Pl();x(T,E)},he=T=>{var E=Dl();x(T,E)},ke=T=>{var E=pr(),Z=bt(E);oi(Z,()=>o(O)),x(T,E)};j(Ve,T=>{e.type==="brazil"&&!o(O)&&!o(I)?T(Et):o(I)?T(ut,1):o(ee)?T(he,2):o(O)&&T(ke,3)})}var Ee=L(Ve,2);{var ot=T=>{const E=K(()=>e.modalData[o(k).cid]);var Z=pr(),w=bt(Z);{var M=h=>{var C=Fl(),H=b(C),Q=b(H);{var fe=le=>{var _e=Il(),Re=b(_e);R(()=>U(Re,`${o(E).title??""}:`)),x(le,_e)};j(Q,le=>{o(E).title&&le(fe)})}var be=L(Q,2);Qt(be,17,()=>o(E).items,Rr,(le,_e)=>{var Re=Nl(),It=b(Re);cl(It,{get name(){return o(_e).name},get tag(){return o(_e).tag},get tagColor(){return o(_e).tagColor},get photoUrl(){return o(_e).photoUrl},get avatar(){return o(_e).avatar},get avatarColor(){return o(_e).avatarColor},get description(){return o(_e).description},get descriptionSide(){return o(_e).descriptionSide},get position(){return o(_e).position},positionSide:"left",size:"sm",wrapper:!0}),x(le,Re)});var pe=L(be,2);{var Le=le=>{var _e=ql(),Re=b(_e);R(()=>U(Re,o(E).footer)),x(le,_e)};j(pe,le=>{o(E).footer&&le(Le)})}R(()=>rt(C,`left:${o(S)??""}px;top:${o(P)??""}px`)),qe("click",C,le=>le.stopPropagation()),qe("keydown",C,le=>le.stopPropagation()),x(h,C)};j(w,h=>{o(E)&&h(M)})}x(T,Z)};j(Ee,T=>{e.modalData&&o(k)&&T(ot)})}Pr(te,T=>ie=T,()=>ie),R(()=>{V=Te(te,1,`map ${o(v)??""} ${n()??""}`,"svelte-1956iuh",V,{loading:o(I),error:o(ee),interactive:o(p)}),rt(te,`aspect-ratio:${r()??""};contain:layout;position:relative`),ae(te,"role",o(p)?"group":void 0)}),qe("click",te,Ue),qe("mousemove",te,it),kn("mouseleave",te,Me),x(t,te),Vt()}En(["click","mousemove","keydown"]);var Ul=z('<div class="table-candidate-title svelte-tgla0e"> </div>'),Vl=z('<span class="table-candidate-badge svelte-tgla0e">ELEITO</span>'),Kl=z('<div><div class="table-candidate-color-bar svelte-tgla0e"></div> <div class="table-candidate-content svelte-tgla0e"><div class="table-candidate-name-group svelte-tgla0e"><span class="table-candidate-name svelte-tgla0e"> </span> <!></div> <span class="table-candidate-percent svelte-tgla0e"> </span> <span class="table-candidate-votes svelte-tgla0e"> </span></div></div>'),Gl=z('<div class="table-candidate-wrapper svelte-tgla0e"><!> <!></div>');const Yl={hash:"svelte-tgla0e",code:`.table-candidate-wrapper.svelte-tgla0e {background:#fff;border-radius:12px;overflow:hidden;box-shadow:0 2px 8px rgba(0, 0, 0, 0.08);font-family:inherit;}.table-candidate-title.svelte-tgla0e {display:none;}.table-candidate-row.svelte-tgla0e {display:flex;align-items:stretch;border-bottom:1px solid #f0f0f0;}.table-candidate-row.svelte-tgla0e:last-child {border-bottom:none;}.table-candidate-row.elected.svelte-tgla0e {background-color:#e8f5ee;}.table-candidate-color-bar.svelte-tgla0e {width:3px;flex-shrink:0;}.table-candidate-content.svelte-tgla0e {flex:1;display:flex;flex-wrap:wrap;align-items:center;padding:12px 16px 10px 12px;gap:0 8px;min-width:0;}.table-candidate-name-group.svelte-tgla0e {flex:1;display:flex;align-items:center;gap:8px;min-width:0;}.table-candidate-name.svelte-tgla0e {font-weight:700;font-size:0.85rem;color:var(--sevn-color-tertiary);}.table-candidate-badge.svelte-tgla0e {background-color:var(--sevn-color-green);color:#fff;font-size:0.58rem;font-weight:600;padding:2px 4px;border-radius:4px;letter-spacing:0.5px;white-space:nowrap;flex-shrink:0;}.table-candidate-percent.svelte-tgla0e {font-size:0.85rem;font-weight:400;color:var(--sevn-color-tertiary);white-space:nowrap;flex-shrink:0;}.table-candidate-votes.svelte-tgla0e {flex-basis:100%;font-size:0.80rem;font-weight:400;color:var(--sevn-color-tertiary);margin-top:2px;}
93
+
94
+ @media (min-width: 600px) {.table-candidate-title.svelte-tgla0e {display:block;padding:16px 20px 12px;font-weight:700;font-size:1rem;color:var(--sevn-color-tertiary);border-bottom:1px solid #e8e8e8;}.table-candidate-color-bar.svelte-tgla0e {width:6px;}.table-candidate-content.svelte-tgla0e {display:grid;grid-template-columns:1fr 120px 230px;align-items:center;gap:0;}.table-candidate-name.svelte-tgla0e {font-weight:700;font-size:0.95rem;color:var(--sevn-color-tertiary);}.table-candidate-badge.svelte-tgla0e {font-size:0.68rem;padding:3px 8px;}.table-candidate-percent.svelte-tgla0e {text-align:right;font-size:0.95rem;}.table-candidate-votes.svelte-tgla0e {flex-basis:auto;font-size:0.95rem;margin-top:0;text-align:right;}
95
+ }`};function wi(t,e){Ut(e,!0),lt(t,Yl);function r(l){return l.toLocaleString("pt-BR")+" votos"}function n(l){return l.toFixed(1).replace(".",",")+"%"}var a=Gl(),i=b(a);{var s=l=>{var d=Ul(),f=b(d);R(()=>U(f,e.title)),x(l,d)};j(i,l=>{e.title&&l(s)})}var c=L(i,2);Qt(c,17,()=>e.candidates,Rr,(l,d)=>{var f=Kl();let _;var v=b(f),p=L(v,2),m=b(p),A=b(m),g=b(A),k=L(A,2);{var S=q=>{var X=Vl();x(q,X)};j(k,q=>{o(d).elected&&q(S)})}var P=L(m,2),O=b(P),I=L(P,2),ee=b(I);R((q,X)=>{_=Te(f,1,"table-candidate-row svelte-tgla0e",null,_,{elected:o(d).elected}),rt(v,`background-color: ${o(d).color??""}`),U(g,`${o(d).name??""}, ${o(d).party??""}`),U(O,q),U(ee,X)},[()=>n(o(d).percentage),()=>r(o(d).votes)]),x(l,f)}),x(t,a),Vt()}class bi{constructor(e={}){var r,n,a;this.inflight=new Map,this.tick=0,this.storageKey=(r=e.storageKey)!==null&&r!==void 0?r:"reqcache",this.maxEntries=(n=e.maxEntries)!==null&&n!==void 0?n:100,this.storage=(a=e.storage)!==null&&a!==void 0?a:Zl()}async getFetch(e,r,n={}){const a=Date.now(),i=this.readAll(),s=i.find(d=>d.rota===e);if(s&&a<s.expiresAt)return s.lastAccess=this.nextAccess(),this.writeAll(i),s.data;const c=this.inflight.get(e);if(c)return c;const l=this.revalidate(e,r,n,s??null).finally(()=>this.inflight.delete(e));return this.inflight.set(e,l),l}invalidate(e){const r=this.readAll().filter(n=>n.rota!==e);this.writeAll(r)}cleanup(e=3600){const r=Date.now()-e*1e3,n=this.readAll(),a=n.filter(i=>i.expiresAt>r);return this.writeAll(a),n.length-a.length}clear(){if(this.storage)try{this.storage.removeItem(this.storageKey)}catch{}}nextAccess(){return this.tick=Math.max(Date.now(),this.tick+1),this.tick}async revalidate(e,r,n,a){var i,s;const c=(i=n.fetcher)!==null&&i!==void 0?i:fetch;let l;try{const f=await c(e,n.fetchOptions);if(!f.ok)throw new Error(`HTTP ${f.status} ao buscar ${e}`);l=await f.json()}catch(f){if(a&&(!((s=n.staleOnError)!==null&&s!==void 0)||s))return this.upsert({...a,expiresAt:Date.now()+r,lastAccess:this.nextAccess()}),a.data;throw f}if(a&&n.monotonicKey){const f=yi(a.data,n.monotonicKey),_=yi(l,n.monotonicKey);if(typeof f=="number"&&typeof _=="number"&&_<=f)return this.upsert({...a,expiresAt:Date.now()+r,lastAccess:this.nextAccess()}),a.data}const d=Date.now();return this.upsert({rota:e,data:l,createdAt:d,expiresAt:d+r,lastAccess:this.nextAccess()}),l}upsert(e){const r=this.readAll().filter(n=>n.rota!==e.rota);r.push(e),this.evictIfNeeded(r),this.writeAll(r)}evictIfNeeded(e){for(;e.length>this.maxEntries;){let r=0;for(let n=1;n<e.length;n++)e[n].lastAccess<e[r].lastAccess&&(r=n);e.splice(r,1)}}readAll(){if(!this.storage)return[];try{const e=this.storage.getItem(this.storageKey);if(!e)return[];const r=JSON.parse(e);return Array.isArray(r)?r:[]}catch{return[]}}writeAll(e){if(this.storage)try{this.storage.setItem(this.storageKey,JSON.stringify(e))}catch(r){if(Wl(r)&&e.length>0){const n=[...e].sort((a,i)=>a.lastAccess-i.lastAccess);n.splice(0,Math.ceil(n.length/2));try{this.storage.setItem(this.storageKey,JSON.stringify(n))}catch{}}}}}function yi(t,e){return e.split(".").reduce((r,n)=>{if(r&&typeof r=="object"&&n in r)return r[n]},t)}function Wl(t){return t instanceof Error&&(t.name==="QuotaExceededError"||t.name==="NS_ERROR_DOM_QUOTA_REACHED")}function Zl(){try{if(typeof localStorage<"u"){const t="__reqcache_probe__";return localStorage.setItem(t,"1"),localStorage.removeItem(t),localStorage}}catch{}return null}new bi;const xi=300,jn=new Map;function On(){try{return typeof window<"u"&&typeof localStorage<"u"}catch{return!1}}const Jl={getItem(t){return On()?localStorage.getItem(t):jn.get(t)??null},setItem(t,e){if(On())try{localStorage.setItem(t,e)}catch{console.warn("[api] Cota do localStorage excedida, ignorando escrita")}else jn.set(t,e)},removeItem(t){On()?localStorage.removeItem(t):jn.delete(t)}};let Pn=null;function Xl(){if(!Pn){const{storageKey:t,maxEntries:e}=zr().cache;Pn=new bi({storage:Jl,storageKey:t,maxEntries:e})}return Pn}async function Ci(t,e,r=xi,n){const[a]=$n(),i=t.replace(/^\/+/,""),s=new URL(i,`${a.replace(/\/+$/,"")}/`);let c;try{c=await Xl().getFetch(s.toString(),r*1e3,{monotonicKey:n,fetcher:Hi})}catch(l){throw l instanceof Error&&/^HTTP 404 /.test(l.message)?new Error("Dados ainda não publicados"):l}if(c&&typeof c=="object"&&c.published===!1)throw new Error(c.reason??"Dados ainda não publicados");return c}function Ql(t,e){const r=e?.round,n=e?.office??"president";let a="br";return e?.municipalityId?a=`mun/${e.municipalityId}`:e?.state&&(a=`uf/${e.state.toUpperCase()}`),Ci(`v1/elections/${t}/r${r}/${n}/${a}/results.json`,void 0,xi,"summary.ballots_counted")}function $l(t,e,r){return Ci(`v1/elections/${t}/r${r}/${e}/by-state.json`)}const ec=new Set(["da","de","do","das","dos","e"]);function zi(t){return t.toLowerCase().split(" ").map((e,r)=>r>0&&ec.has(e)?e:e.charAt(0).toUpperCase()+e.slice(1)).join(" ")}function tc(t){if(typeof t=="string"){const r=t.match(/^(\d{4})-(\d{2})-(\d{2})[T ](\d{2}):(\d{2})(?::(\d{2}))?/);if(r)return new Date(Date.UTC(Number(r[1]),Number(r[2])-1,Number(r[3]),Number(r[4]),Number(r[5]),Number(r[6]??0)))}const e=new Date(t);return Number.isNaN(e.getTime())?null:e}function Dn(t){if(t==null||t==="")return"";const e=tc(t);if(!e)return"";const r=String(e.getUTCDate()).padStart(2,"0"),n=String(e.getUTCMonth()+1).padStart(2,"0"),a=e.getUTCFullYear(),i=String(e.getUTCHours()).padStart(2,"0"),s=String(e.getUTCMinutes()).padStart(2,"0");return`${r}/${n}/${a} às ${i}h${s}`}function rc(t,e="TSE"){const r=Dn(t);return r?`Atualizado em ${r} | Fonte ${e}`:`Fonte ${e}`}const nc=Dn("2022-10-31T00:18:00Z");rc("2022-10-31T00:18:00Z");var ac=z('<div class="sevn_state_leaders__filter-web svelte-10aer1n"><!></div> <div class="sevn_state_leaders__filter-mobile svelte-10aer1n"><!></div>',1),ic=z('<p class="sevn_state_leaders__empty-label svelte-10aer1n">Carregando resultados...</p>'),oc=z('<p class="sevn_state_leaders__empty-label sevn_state_leaders__empty-label--error svelte-10aer1n"> </p>'),sc=z('<p class="sevn_state_leaders__empty-label svelte-10aer1n"> </p>'),lc=z('<div class="sevn_state_leaders__table-overlay svelte-10aer1n"><!></div>'),cc=z('<p class="sevn_state_leaders__empty-label svelte-10aer1n"> </p>'),dc=z('<div class="sevn_state_leaders__overview-web svelte-10aer1n"><!></div>'),fc=z('<div class="sevn_state_leaders__overview-mobile svelte-10aer1n"><span class="sevn_state_leaders__overview-label svelte-10aer1n">Visão geral:</span> <div class="sevn_state_leaders__tags-row svelte-10aer1n"></div></div> <div class="sevn_state_leaders__map-web svelte-10aer1n" role="presentation"><!> <div class="sevn_state_leaders__legend-overlay svelte-10aer1n"></div> <!></div> <div class="sevn_state_leaders__mobile-section svelte-10aer1n"><div class="sevn_state_leaders__map-mobile svelte-10aer1n"><!></div> <div class="sevn_state_leaders__search-mobile svelte-10aer1n"><!></div> <!> <!></div> <!>',1),vc=z("<div><!> <!> <!></div>");const uc={hash:"svelte-10aer1n",code:`.sevn_state_leaders.svelte-10aer1n {display:flex;flex-direction:column;gap:24px;}.sevn_state_leaders__filter-web.svelte-10aer1n {display:none;}.sevn_state_leaders__filter-mobile.svelte-10aer1n {display:block;width:220px;}
96
+
97
+ @media (min-width: 768px) {.sevn_state_leaders__filter-web.svelte-10aer1n {display:block;}.sevn_state_leaders__filter-mobile.svelte-10aer1n {display:none;}
98
+ }.sevn_state_leaders__empty-label--error.svelte-10aer1n {color:#e11d48;opacity:1;}
99
+
100
+ /* ── Visão geral mobile ──────────────────────────────── */.sevn_state_leaders__overview-mobile.svelte-10aer1n {display:flex;flex-direction:column;gap:8px;}.sevn_state_leaders__overview-label.svelte-10aer1n {font-size:0.875rem;font-weight:600;color:var(--sevn-color-tertiary);}.sevn_state_leaders__tags-row.svelte-10aer1n {display:flex;flex-wrap:wrap;gap:8px;}
101
+
102
+ /* ── Mapa web ────────────────────────────────────────── */.sevn_state_leaders__map-web.svelte-10aer1n {display:none;position:relative;}
103
+
104
+ /* ── Legenda overlay (web) ───────────────────────────── */.sevn_state_leaders__legend-overlay.svelte-10aer1n {position:absolute;bottom:0;left:0;display:flex;flex-direction:column;gap:6px;z-index:5;}
105
+
106
+ /* ── TableCandidate overlay (web) ────────────────────── */.sevn_state_leaders__table-overlay.svelte-10aer1n {position:absolute;z-index:10;width:500px;transform:translate(-50%, 12px);filter:drop-shadow(0 4px 16px rgba(0, 0, 0, 0.18));pointer-events:none;}.sevn_state_leaders__empty-label.svelte-10aer1n {margin:0;padding:14px 18px;background:#fff;border-radius:8px;box-shadow:0 4px 16px rgba(0, 0, 0, 0.18);font-size:0.875rem;color:var(--sevn-color-text-secondary, #6b7280);text-align:center;}.sevn_state_leaders__table-overlay.svelte-10aer1n .table-candidate-content {display:grid;grid-template-columns:1fr 55px 120px;align-items:center;gap:0;}.sevn_state_leaders__table-overlay.svelte-10aer1n .table-candidate-percent {text-align:right;}.sevn_state_leaders__table-overlay.svelte-10aer1n .table-candidate-votes {flex-basis:auto;margin-top:0;text-align:right;}
107
+
108
+ /* ── Seção mobile ────────────────────────────────────── */.sevn_state_leaders__mobile-section.svelte-10aer1n {display:flex;flex-direction:column;gap:20px;}.sevn_state_leaders__map-mobile.svelte-10aer1n {width:100%;}.sevn_state_leaders.svelte-10aer1n .vote-overview {padding:8px 0;gap:8px;align-items:flex-end;}
109
+
110
+ @media (max-width: 767px) {.sevn_state_leaders__search-mobile.svelte-10aer1n .dropdown {position:static;margin-top:10px;}.sevn_state_leaders.svelte-10aer1n .vote-overview {padding:3px;font-size:0.7rem;gap:8px;}.sevn_state_leaders.svelte-10aer1n .vote-overview .vote-overview-stats {gap:8px;}
111
+ }.sevn_state_leaders__overview-web.svelte-10aer1n {display:none;}
112
+
113
+ /* ── Desktop ─────────────────────────────────────────── */
114
+ @media (min-width: 768px) {.sevn_state_leaders__overview-mobile.svelte-10aer1n {display:none;}.sevn_state_leaders__map-web.svelte-10aer1n {display:block;}.sevn_state_leaders__mobile-section.svelte-10aer1n {display:none;}.sevn_state_leaders__overview-web.svelte-10aer1n {display:block;}
115
+ }
116
+
117
+ /* ── Raw ─────────────────────────────────────────────── */.sevn_state_leaders--raw.svelte-10aer1n,
118
+ .sevn_state_leaders--raw.svelte-10aer1n :where(.svelte-10aer1n) {all:revert;}`};function hc(t,e){Ut(e,!0),lt(t,uc);let r=D(e,"mock",3,!1),n=D(e,"rawStyle",3,!1),a=D(e,"year",3,2026),i=D(e,"defaultOffice",3,"president"),s=D(e,"header",19,()=>({title:"Veja quem lidera em cada estado",description:"As cores no mapa representam o partido que está em primeiro lugar no momento",tag:"VISÃO NACIONAL",tagColor:"var(--sevn-color-tertiary, #1a1a2e)"}));const c=[{value:"presidente",label:"Presidente"},{value:"governador",label:"Governador"}],l={presidente:"president",governador:"governor"},d={president:"presidente",governor:"governador"};let f=W(Yt(hr(()=>d[i()]??"presidente"))),_=W(null),v=W(!1),p=W(null);xt(()=>{if(!Nt||r())return;if(!o(f)){y(_,null);return}const h=l[o(f)]||"president";y(v,!0),y(p,null),y(_,null),$l(a(),h,1).then(C=>{y(_,C,!0),y(v,!1)}).catch(C=>{console.error("Failed to fetch state results:",C),y(p,C instanceof Error?C.message:"Não foi possível carregar os resultados.",!0),y(v,!1)})});const m=[{party:"ABC",color:"var(--sevn-color-primary)"},{party:"DEF",color:"var(--sevn-color-secondary)"},{party:"GHI",color:"#1e4d6b"},{party:"JKL",color:"#0f172a"},{party:"MNO",color:"#16a34a"},{party:"PQR",color:"#e11d48"}],A=Object.fromEntries(m.map(h=>[h.party,h.color])),g=[{text:"Nulos",value:"3,16%"},{text:"Brancos",value:"1,43%"},{text:"Válidos",value:"118.552.353 votos"}];let k=W(null);const S=K(()=>r()||l[o(f)]==="president");xt(()=>{if(!Nt||r()||!o(f))return;const h=l[o(f)]||"president";if(h!=="president"){y(k,null);return}Ql(a(),{office:h,round:1}).then(C=>{y(k,C?.summary??null,!0)}).catch(C=>{console.error("Failed to fetch national summary:",C)})});const P=K(()=>{if(r())return g;if(!o(k))return[];const{total_valid_votes:h,null_votes:C,blank_votes:H}=o(k),Q=h+C+H;return Q?[{text:"Nulos",value:`${(C/Q*100).toFixed(2)}%`},{text:"Brancos",value:`${(H/Q*100).toFixed(2)}%`},{text:"Válidos",value:`${h.toLocaleString("pt-BR")} votos`}]:[]}),O=K(()=>r()?nc:Dn(o(k)?.last_updated)),I={ac:"PQR",al:"ABC",am:"ABC",ap:"GHI",ba:"ABC",ce:"GHI",df:"JKL",es:"GHI",go:"DEF",ma:"DEF",mg:"GHI",ms:"DEF",mt:"DEF",pa:"GHI",pb:"JKL",pe:"GHI",pi:"ABC",pr:"DEF",rj:"ABC",rn:"MNO",ro:"DEF",rr:"PQR",rs:"JKL",sc:"JKL",se:"ABC",sp:"ABC",to:"DEF"},ee=K(()=>r()?Object.entries(I).map(([h,C])=>({id:h,color:A[C]})):(o(_)?.states??[]).filter(h=>h.leader?.party_color).map(h=>({id:h.state.toLowerCase(),color:h.leader.party_color}))),q=K(()=>{if(!r()&&o(_)?.states){const h=new Set,C=[];for(const H of o(_).states){const Q=H.leader?.party_abbr;Q&&!h.has(Q)&&(h.add(Q),C.push({party:Q,color:H.leader.party_color}))}return C.sort((H,Q)=>H.party.localeCompare(Q.party,"pt-BR"))}return m}),X=[{value:"ac",label:"Acre AC"},{value:"al",label:"Alagoas AL"},{value:"am",label:"Amazonas AM"},{value:"ap",label:"Amapá AP"},{value:"ba",label:"Bahia BA"},{value:"ce",label:"Ceará CE"},{value:"df",label:"Distrito Federal DF"},{value:"es",label:"Espírito Santo ES"},{value:"go",label:"Goiás GO"},{value:"ma",label:"Maranhão MA"},{value:"mg",label:"Minas Gerais MG"},{value:"ms",label:"Mato Grosso do Sul MS"},{value:"mt",label:"Mato Grosso MT"},{value:"pa",label:"Pará PA"},{value:"pb",label:"Paraíba PB"},{value:"pe",label:"Pernambuco PE"},{value:"pi",label:"Piauí PI"},{value:"pr",label:"Paraná PR"},{value:"rj",label:"Rio de Janeiro RJ"},{value:"rn",label:"Rio Grande do Norte RN"},{value:"ro",label:"Rondônia RO"},{value:"rr",label:"Roraima RR"},{value:"rs",label:"Rio Grande do Sul RS"},{value:"sc",label:"Santa Catarina SC"},{value:"se",label:"Sergipe SE"},{value:"sp",label:"São Paulo SP"},{value:"to",label:"Tocantins TO"}].sort((h,C)=>h.label.localeCompare(C.label));function N(h){return X.find(C=>C.value===h)?.label?.replace(/\s+[A-Z]{2}$/,"")??h.toUpperCase()}const F="var(--sevn-color-primary)",ie="var(--sevn-color-secondary)",ge={sp:[{name:"Candidato A",party:"ABC",percentage:54.1,votes:1728159,color:F,elected:!0},{name:"Candidato B",party:"DEF",percentage:43.1,votes:1377441,color:ie},{name:"Candidato C",party:"GHI",percentage:1.1,votes:35623,color:"#1e4d6b"},{name:"Candidato D",party:"JKL",percentage:.7,votes:21439,color:"#0f172a"},{name:"Candidato E",party:"MNO",percentage:.5,votes:17344,color:"#16a34a"},{name:"Candidato F",party:"PQR",percentage:.2,votes:5149,color:"#e11d48"}],mg:[{name:"Candidato C",party:"GHI",percentage:41.8,votes:1832400,color:"#1e4d6b",elected:!0},{name:"Candidato A",party:"ABC",percentage:36.4,votes:1595680,color:F},{name:"Candidato B",party:"DEF",percentage:14.2,votes:622480,color:ie},{name:"Candidato D",party:"JKL",percentage:4.6,votes:201640,color:"#0f172a"},{name:"Candidato E",party:"MNO",percentage:3,votes:131490,color:"#16a34a"}],rj:[{name:"Candidato A",party:"ABC",percentage:50.8,votes:1200450,color:F,elected:!0},{name:"Candidato B",party:"DEF",percentage:33.4,votes:789230,color:ie},{name:"Candidato C",party:"GHI",percentage:9.6,votes:226840,color:"#1e4d6b"},{name:"Candidato F",party:"PQR",percentage:4.2,votes:99246,color:"#e11d48"},{name:"Candidato E",party:"MNO",percentage:2,votes:47245,color:"#16a34a"}],rs:[{name:"Candidato D",party:"JKL",percentage:53.6,votes:1580120,color:"#0f172a",elected:!0},{name:"Candidato A",party:"ABC",percentage:28.4,votes:837580,color:F},{name:"Candidato B",party:"DEF",percentage:12.8,votes:377560,color:ie},{name:"Candidato C",party:"GHI",percentage:5.2,votes:153340,color:"#1e4d6b"}]};function Se(h){if(ge[h])return ge[h];const C=h.charCodeAt(0)*7+h.charCodeAt(1)*3,H=I[h],Q=A[H],fe=38+C%18,be=24+C%10,pe=Math.max(5,100-fe-be-15),Le=100-fe-be-pe,le=3e5+C*6e3,_e=m.filter(nn=>nn.party!==H),[Re,It,Cr,Fr,Hr]=_e;return[{name:`Candidato ${H}`,party:H,percentage:fe,votes:Math.round(le*fe/100),color:Q,elected:!0},{name:`Candidato ${Re.party}`,party:Re.party,percentage:be,votes:Math.round(le*be/100),color:Re.color},{name:`Candidato ${It.party}`,party:It.party,percentage:pe,votes:Math.round(le*pe/100),color:It.color},{name:`Candidato ${Cr.party}`,party:Cr.party,percentage:Math.round(Le*.5),votes:Math.round(le*Le*.5/100),color:Cr.color},{name:`Candidato ${Fr.party}`,party:Fr.party,percentage:Math.round(Le*.3),votes:Math.round(le*Le*.3/100),color:Fr.color},{name:`Candidato ${Hr.party}`,party:Hr.party,percentage:Math.round(Le*.2),votes:Math.round(le*Le*.2/100),color:Hr.color}]}let ce=W(null),Ue=W(0),it=W(0),Me=W(null),te=W(null),V=W(0),oe=W(0);const se=K(()=>o(te)??o(ce)),Ve=K(()=>{if(!o(se))return[];if(r())return Se(o(se));const h=o(_)?.states?.find(H=>H.state.toLowerCase()===o(se).toLowerCase());if(!h)return null;const C=[];return h.leader&&C.push({name:zi(h.leader.name),party:h.leader.party_abbr,percentage:h.leader.valid_votes_pct,votes:h.leader.votes,color:h.leader.party_color,elected:h.leader.elected??!1}),h.runner_up&&C.push({name:zi(h.runner_up.name),party:h.runner_up.party_abbr,percentage:h.runner_up.valid_votes_pct,votes:h.runner_up.votes,color:h.runner_up.party_color,elected:!1}),C.length>0?C:null}),Et=K(()=>c.find(h=>h.value===o(f))?.label??"Presidente"),ut=K(()=>o(se)?`${o(Et)}: ${N(o(se))}`:"");function he(h){if(y(ce,h.cid,!0),o(Me)){const C=o(Me).getBoundingClientRect();y(Ue,h.clientX-C.left),y(it,h.clientY-C.top)}}function ke(h){if(!o(Me))return;const C=o(Me).getBoundingClientRect();o(te)===h.cid?y(te,null):(y(te,h.cid,!0),y(V,h.clientX-C.left),y(oe,h.clientY-C.top))}xt(()=>{if(!o(te))return;function h(C){o(Me)&&!o(Me).contains(C.target)&&y(te,null)}return document.addEventListener("click",h),()=>document.removeEventListener("click",h)});var Ee=vc();let ot;var T=b(Ee);Ll(T,{get title(){return s().title},get description(){return s().description},get tag(){return s().tag},get tagColor(){return s().tagColor}});var E=L(T,2);{var Z=h=>{var C=ac(),H=bt(C),Q=b(H);Sl(Q,{label:"Cargo",get options(){return c},get value(){return o(f)},set value(pe){y(f,pe,!0)}});var fe=L(H,2),be=b(fe);pi(be,{label:"Cargo:",showLabel:!1,showLabelInField:!0,labelAsPlaceholder:!0,showPlaceholderOnMobile:!0,get options(){return c},get value(){return o(f)},set value(pe){y(f,pe,!0)}}),x(h,C)};j(E,h=>{r()||h(Z)})}var w=L(E,2);{var M=h=>{var C=pr(),H=bt(C);{var Q=pe=>{var Le=ic();x(pe,Le)},fe=pe=>{var Le=oc(),le=b(Le);R(()=>U(le,o(p))),x(pe,Le)},be=pe=>{var Le=fc(),le=bt(Le),_e=L(b(le),2);Qt(_e,21,()=>o(q),Rr,(de,Ae)=>{Pt(de,{get label(){return o(Ae).party},get color(){return o(Ae).color}})});var Re=L(le,2),It=b(Re);mi(It,{type:"brazil-states",get colors(){return o(ee)},interactive:!0,onRegionHover:he,onRegionClick:ke});var Cr=L(It,2);Qt(Cr,21,()=>o(q),Rr,(de,Ae)=>{Pt(de,{get label(){return o(Ae).party},get color(){return o(Ae).color}})});var Fr=L(Cr,2);{var Hr=de=>{var Ae=lc(),Br=b(Ae);{var qn=Ke=>{wi(Ke,{get title(){return o(ut)},get candidates(){return o(Ve)}})},Fn=Ke=>{var Ur=sc(),Hn=b(Ur);R(Bn=>U(Hn,`Resultado ainda não publicado para ${Bn??""}.`),[()=>N(o(se))]),x(Ke,Ur)};j(Br,Ke=>{o(Ve)?Ke(qn):Ke(Fn,!1)})}R(()=>rt(Ae,`left:${o(Ue)??""}px;top:${o(it)??""}px`)),x(de,Ae)};j(Fr,de=>{o(se)&&de(Hr)})}Pr(Re,de=>y(Me,de),()=>o(Me));var nn=L(Re,2),Ei=b(nn),pc=b(Ei);mi(pc,{type:"brazil-states",get colors(){return o(ee)}});var Ai=L(Ei,2),gc=b(Ai);{let de=K(()=>o(ce)?"Você selecionou":"Busque por estado:");pi(gc,{get label(){return o(de)},get options(){return X},get value(){return o(ce)},set value(Ae){y(ce,Ae,!0)}})}var Ti=L(Ai,2);{var _c=de=>{var Ae=pr(),Br=bt(Ae);{var qn=Ke=>{wi(Ke,{get title(){return o(ut)},get candidates(){return o(Ve)}})},Fn=Ke=>{var Ur=cc(),Hn=b(Ur);R(Bn=>U(Hn,`Resultado ainda não publicado para ${Bn??""}.`),[()=>N(o(ce))]),x(Ke,Ur)};j(Br,Ke=>{o(Ve)?Ke(qn):Ke(Fn,!1)})}x(de,Ae)};j(Ti,de=>{o(ce)&&de(_c)})}var mc=L(Ti,2);{var wc=de=>{gi(de,{get data(){return o(P)},get date(){return o(O)},font:"TSE"})};j(mc,de=>{o(S)&&de(wc)})}var bc=L(nn,2);{var yc=de=>{var Ae=dc(),Br=b(Ae);gi(Br,{get data(){return o(P)},get date(){return o(O)},font:"TSE"}),x(de,Ae)};j(bc,de=>{o(S)&&de(yc)})}kn("mouseleave",Re,()=>y(ce,null)),x(pe,Le)};j(H,pe=>{o(v)?pe(Q):o(p)?pe(fe,1):pe(be,!1)})}x(h,C)};j(w,h=>{(r()||o(f))&&h(M)})}R(()=>ot=Te(Ee,1,"sevn_state_leaders svelte-10aer1n",null,ot,{"sevn_state_leaders--raw":n()})),x(t,Ee),Vt()}const Si=ys(hc,"StateLeaders");return typeof window<"u"&&(window.SevnElections=Object.assign(window.SevnElections||{},{Core:Ui,StateLeaders:Si}),Cs()),Si}));