@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.
- package/LICENSE +21 -0
- package/README.md +297 -0
- package/dist/index.cjs +603 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +351 -0
- package/dist/index.d.ts +351 -0
- package/dist/index.js +15609 -0
- package/dist/index.js.map +1 -0
- package/dist/styles.css +38 -0
- package/dist/umd/candidate-by-state.js +98 -0
- package/dist/umd/candidate-carrousel-state-results-viewer.js +108 -0
- package/dist/umd/candidate-counting-progress.js +77 -0
- package/dist/umd/candidate-duel-state-result-viewer.js +91 -0
- package/dist/umd/candidate-map-by-state.js +104 -0
- package/dist/umd/candidate-multi-ring-chart-performance-by-municipality.js +105 -0
- package/dist/umd/candidate-performance-by-municipality.js +105 -0
- package/dist/umd/candidate-ranking.js +59 -0
- package/dist/umd/candidate-results-by-municipality.js +103 -0
- package/dist/umd/counting-progress.js +125 -0
- package/dist/umd/current-leader.js +43 -0
- package/dist/umd/election-round-analysis.js +100 -0
- package/dist/umd/election-status.js +135 -0
- package/dist/umd/final-results.js +141 -0
- package/dist/umd/live-summary.js +36 -0
- package/dist/umd/municipality-perfomance-map.js +82 -0
- package/dist/umd/party-performance.js +99 -0
- package/dist/umd/results-by-office.js +94 -0
- package/dist/umd/round-results-analysis.js +99 -0
- package/dist/umd/state-leaders.js +118 -0
- package/dist/umd/state-winners.js +129 -0
- package/dist/umd/top-dispute.js +43 -0
- package/dist/umd/vote-comparison-by-round.js +76 -0
- package/dist/umd/vote-counting-progress.js +23 -0
- package/dist/umd/voting-map.js +112 -0
- package/package.json +96 -0
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
(function(de,ce){typeof exports=="object"&&typeof module<"u"?module.exports=ce():typeof define=="function"&&define.amd?define(ce):(de=typeof globalThis<"u"?globalThis:de||self,de.StateWinners=ce())})(this,(function(){"use strict";var cd=Object.defineProperty;var di=de=>{throw TypeError(de)};var vd=(de,ce,Ee)=>ce in de?cd(de,ce,{enumerable:!0,configurable:!0,writable:!0,value:Ee}):de[ce]=Ee;var gt=(de,ce,Ee)=>vd(de,typeof ce!="symbol"?ce+"":ce,Ee),In=(de,ce,Ee)=>ce.has(de)||di("Cannot "+Ee);var h=(de,ce,Ee)=>(In(de,ce,"read from private field"),Ee?Ee.call(de):ce.get(de)),ae=(de,ce,Ee)=>ce.has(de)?di("Cannot add the same private member more than once"):ce instanceof WeakSet?ce.add(de):ce.set(de,Ee),$=(de,ce,Ee,ja)=>(In(de,ce,"write to private field"),ja?ja.call(de,Ee):ce.set(de,Ee),Ee),Oe=(de,ce,Ee)=>(In(de,ce,"access private method"),Ee);var ua,pa,ea,ha,Oa,Da,ta,Tt,_a,Ge,Nn,jn,qn,ci,lt,Ln,At,aa,ut,pt,We,ht,Mt,na,qt,ga,ma,wa,Lt,Xa,Pe,fd,ud,Fn,en,tn,Un,dt,_t,Ke,ra,Ia,Na,Ja,li;const de="__sevnElectionsState_v1__",ce=globalThis;function Ee(t){return ce[de]||(ce[de]={config:t(),transport:{activeIndex:0,pinnedAt:0}}),ce[de]}const ja="https://failover-api.sevntech.com",vi=/^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?$/i;function Bn(){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 fi=Bn;function xa(){return Ee(Bn)}function ui(t){return[`https://${t}-api1.sevnelections.com`,`https://${t}-api2.sevnelections.com`,ja]}function an(t){if(typeof t!="string"||!vi.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=xa();e.config.key=t,e.config.apiHosts=ui(t)}function Hn(t){const{cache:e,request:a,key:n,...o}=t,r=xa();r.config={...r.config,...o,cache:{...r.config.cache,...e},request:{...r.config.request,...a}},n&&(an(n),o.apiHosts&&(r.config.apiHosts=o.apiHosts))}function nn(){return xa().config}function pi(){return xa().config.apiHosts.length>0}function rn(t){const{assetsBase:e,assetsVersion:a}=xa().config,n=e.replace(/\/+$/,""),o=String(t).replace(/^\/+/,"");return`${n}/${a}/${o}`}const hi=':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}',Ft=typeof window<"u"&&typeof document<"u",Vn="data-sevn-tokens",Gn="data-sevn-theme",Wn={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 _i(){if(!Ft||document.querySelector(`style[${Vn}]`))return;const t=document.createElement("style");t.setAttribute(Vn,""),t.textContent=hi,document.head.prepend(t);const e=nn().theme;e&&on(e)}function on(t){if(!Ft)return;const e=Object.keys(Wn).filter(n=>t[n]).map(n=>` ${Wn[n]}: ${t[n]};`);if(e.length===0)return;let a=document.querySelector(`style[${Gn}]`);a||(a=document.createElement("style"),a.setAttribute(Gn,""),document.head.appendChild(a)),a.textContent=`:root {
|
|
2
|
+
${e.join(`
|
|
3
|
+
`)}
|
|
4
|
+
}`}function gi(){return Ee(fi).transport}function mi(){return nn().apiHosts[gi().activeIndex]??null}const wi={applyKey:an,configure(t){Hn(t),t.theme&&on(t.theme)},getConfig:nn,isReady:pi,assetUrl:rn,setTheme(t){Hn({theme:t}),on(t)},activeHost:mi},sn=!1;var Kn=Array.isArray,xi=Array.prototype.indexOf,ia=Array.prototype.includes,qa=Array.from,bi=Object.defineProperty,oa=Object.getOwnPropertyDescriptor,yi=Object.getOwnPropertyDescriptors,zi=Object.prototype,Si=Array.prototype,Yn=Object.getPrototypeOf,Zn=Object.isExtensible;const ki=()=>{};function Ci(t){for(var e=0;e<t.length;e++)t[e]()}function Xn(){var t,e,a=new Promise((n,o)=>{t=n,e=o});return{promise:a,resolve:t,reject:e}}const De=2,ba=4,Fa=8,Jn=1<<24,mt=16,tt=32,Ut=64,ln=128,Ye=512,Re=1024,Ie=2048,at=4096,Be=8192,wt=16384,Bt=32768,sa=65536,Qn=1<<17,$n=1<<18,la=1<<19,Ei=1<<20,xt=1<<25,Ht=65536,dn=1<<21,cn=1<<22,Pt=1<<23,ya=Symbol("$state"),Ti=Symbol("legacy props"),Ai=Symbol(""),Vt=new class extends Error{constructor(){super(...arguments);gt(this,"name","StaleReactionError");gt(this,"message","The reaction that called `getAbortSignal()` was re-run or destroyed")}};function Mi(t){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function Li(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function Ri(t,e,a){throw new Error("https://svelte.dev/e/each_key_duplicate")}function Pi(t){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Oi(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function Di(t){throw new Error("https://svelte.dev/e/effect_orphan")}function Ii(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Ni(t){throw new Error("https://svelte.dev/e/props_invalid_value")}function ji(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function qi(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Fi(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Ui(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}const Bi=1,Hi=2,er=4,Vi=8,Gi=16,Wi=1,Ki=4,Yi=8,Zi=16,Xi=1,Ji=2,Ne=Symbol(),tr="http://www.w3.org/1999/xhtml";function Qi(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}function ar(t){return t===this.v}function $i(t,e){return t!=t?e==e:t!==e||t!==null&&typeof t=="object"||typeof t=="function"}function nr(t){return!$i(t,this.v)}let eo=!1,He=null;function da(t){He=t}function Gt(t,e=!1,a){He={p:He,i:!1,c:null,e:null,s:t,x:null,l:null}}function Wt(t){var e=He,a=e.e;if(a!==null){e.e=null;for(var n of a)Er(n)}return e.i=!0,He=e.p,{}}function rr(){return!0}let Kt=[];function ir(){var t=Kt;Kt=[],Ci(t)}function bt(t){if(Kt.length===0&&!za){var e=Kt;queueMicrotask(()=>{e===Kt&&ir()})}Kt.push(t)}function to(){for(;Kt.length>0;)ir()}function or(t){var e=se;if(e===null)return ee.f|=Pt,t;if((e.f&Bt)===0&&(e.f&ba)===0)throw t;ca(t,e)}function ca(t,e){for(;e!==null;){if((e.f&ln)!==0){if((e.f&Bt)===0)throw t;try{e.b.error(t);return}catch(a){t=a}}e=e.parent}throw t}const ao=-7169;function Ce(t,e){t.f=t.f&ao|e}function vn(t){(t.f&Ye)!==0||t.deps===null?Ce(t,Re):Ce(t,at)}function sr(t){if(t!==null)for(const e of t)(e.f&De)===0||(e.f&Ht)===0||(e.f^=Ht,sr(e.deps))}function lr(t,e,a){(t.f&Ie)!==0?e.add(t):(t.f&at)!==0&&a.add(t),sr(t.deps),Ce(t,Re)}const Ua=new Set;let ve=null,fn=null,nt=null,je=[],Ba=null,un=!1,za=!1;const Mn=class Mn{constructor(){ae(this,Ge);gt(this,"committed",!1);gt(this,"current",new Map);gt(this,"previous",new Map);ae(this,ua,new Set);ae(this,pa,new Set);ae(this,ea,0);ae(this,ha,0);ae(this,Oa,null);ae(this,Da,new Set);ae(this,ta,new Set);ae(this,Tt,new Map);gt(this,"is_fork",!1);ae(this,_a,!1)}skip_effect(e){h(this,Tt).has(e)||h(this,Tt).set(e,{d:[],m:[]})}unskip_effect(e){var a=h(this,Tt).get(e);if(a){h(this,Tt).delete(e);for(var n of a.d)Ce(n,Ie),rt(n);for(n of a.m)Ce(n,at),rt(n)}}process(e){je=[],this.apply();var a=[],n=[];for(const o of e)Oe(this,Ge,jn).call(this,o,a,n);if(Oe(this,Ge,Nn).call(this)){Oe(this,Ge,qn).call(this,n),Oe(this,Ge,qn).call(this,a);for(const[o,r]of h(this,Tt))ur(o,r)}else{for(const o of h(this,ua))o();h(this,ua).clear(),h(this,ea)===0&&Oe(this,Ge,ci).call(this),fn=this,ve=null,cr(n),cr(a),fn=null,h(this,Oa)?.resolve()}nt=null}capture(e,a){a!==Ne&&!this.previous.has(e)&&this.previous.set(e,a),(e.f&Pt)===0&&(this.current.set(e,e.v),nt?.set(e,e.v))}activate(){ve=this,this.apply()}deactivate(){ve===this&&(ve=null,nt=null)}flush(){if(this.activate(),je.length>0){if(dr(),ve!==null&&ve!==this)return}else h(this,ea)===0&&this.process([]);this.deactivate()}discard(){for(const e of h(this,pa))e(this);h(this,pa).clear()}increment(e){$(this,ea,h(this,ea)+1),e&&$(this,ha,h(this,ha)+1)}decrement(e){$(this,ea,h(this,ea)-1),e&&$(this,ha,h(this,ha)-1),!h(this,_a)&&($(this,_a,!0),bt(()=>{$(this,_a,!1),Oe(this,Ge,Nn).call(this)?je.length>0&&this.flush():this.revive()}))}revive(){for(const e of h(this,Da))h(this,ta).delete(e),Ce(e,Ie),rt(e);for(const e of h(this,ta))Ce(e,at),rt(e);this.flush()}oncommit(e){h(this,ua).add(e)}ondiscard(e){h(this,pa).add(e)}settled(){return(h(this,Oa)??$(this,Oa,Xn())).promise}static ensure(){if(ve===null){const e=ve=new Mn;Ua.add(ve),za||bt(()=>{ve===e&&e.flush()})}return ve}apply(){}};ua=new WeakMap,pa=new WeakMap,ea=new WeakMap,ha=new WeakMap,Oa=new WeakMap,Da=new WeakMap,ta=new WeakMap,Tt=new WeakMap,_a=new WeakMap,Ge=new WeakSet,Nn=function(){return this.is_fork||h(this,ha)>0},jn=function(e,a,n){e.f^=Re;for(var o=e.first;o!==null;){var r=o.f,l=(r&(tt|Ut))!==0,d=l&&(r&Re)!==0,s=d||(r&Be)!==0||h(this,Tt).has(o);if(!s&&o.fn!==null){l?o.f^=Re:(r&ba)!==0?a.push(o):Ca(o)&&((r&mt)!==0&&h(this,ta).add(o),fa(o));var c=o.first;if(c!==null){o=c;continue}}for(;o!==null;){var p=o.next;if(p!==null){o=p;break}o=o.parent}}},qn=function(e){for(var a=0;a<e.length;a+=1)lr(e[a],h(this,Da),h(this,ta))},ci=function(){var o;if(Ua.size>1){this.previous.clear();var e=nt,a=!0;for(const r of Ua){if(r===this){a=!1;continue}const l=[];for(const[s,c]of this.current){if(r.current.has(s))if(a&&c!==r.current.get(s))r.current.set(s,c);else continue;l.push(s)}if(l.length===0)continue;const d=[...r.current.keys()].filter(s=>!this.current.has(s));if(d.length>0){var n=je;je=[];const s=new Set,c=new Map;for(const p of l)vr(p,d,s,c);if(je.length>0){ve=r,r.apply();for(const p of je)Oe(o=r,Ge,jn).call(o,p,[],[]);r.deactivate()}je=n}}ve=null,nt=e}this.committed=!0,Ua.delete(this)};let Ot=Mn;function no(t){var e=za;za=!0;try{for(var a;;){if(to(),je.length===0&&(ve?.flush(),je.length===0))return Ba=null,a;dr()}}finally{za=e}}function dr(){un=!0;var t=null;try{for(var e=0;je.length>0;){var a=Ot.ensure();if(e++>1e3){var n,o;ro()}a.process(je),Dt.clear()}}finally{je=[],un=!1,Ba=null}}function ro(){try{Ii()}catch(t){ca(t,Ba)}}let yt=null;function cr(t){var e=t.length;if(e!==0){for(var a=0;a<e;){var n=t[a++];if((n.f&(wt|Be))===0&&Ca(n)&&(yt=new Set,fa(n),n.deps===null&&n.first===null&&n.nodes===null&&n.teardown===null&&n.ac===null&&Lr(n),yt?.size>0)){Dt.clear();for(const o of yt){if((o.f&(wt|Be))!==0)continue;const r=[o];let l=o.parent;for(;l!==null;)yt.has(l)&&(yt.delete(l),r.push(l)),l=l.parent;for(let d=r.length-1;d>=0;d--){const s=r[d];(s.f&(wt|Be))===0&&fa(s)}}yt.clear()}}yt=null}}function vr(t,e,a,n){if(!a.has(t)&&(a.add(t),t.reactions!==null))for(const o of t.reactions){const r=o.f;(r&De)!==0?vr(o,e,a,n):(r&(cn|mt))!==0&&(r&Ie)===0&&fr(o,e,n)&&(Ce(o,Ie),rt(o))}}function fr(t,e,a){const n=a.get(t);if(n!==void 0)return n;if(t.deps!==null)for(const o of t.deps){if(ia.call(e,o))return!0;if((o.f&De)!==0&&fr(o,e,a))return a.set(o,!0),!0}return a.set(t,!1),!1}function rt(t){var e=Ba=t,a=e.b;if(a?.is_pending&&(t.f&(ba|Fa|Jn))!==0&&(t.f&Bt)===0){a.defer_effect(t);return}for(;e.parent!==null;){e=e.parent;var n=e.f;if(un&&e===se&&(n&mt)!==0&&(n&$n)===0&&(n&Bt)!==0)return;if((n&(Ut|tt))!==0){if((n&Re)===0)return;e.f^=Re}}je.push(e)}function ur(t,e){if(!((t.f&tt)!==0&&(t.f&Re)!==0)){(t.f&Ie)!==0?e.d.push(t):(t.f&at)!==0&&e.m.push(t),Ce(t,Re);for(var a=t.first;a!==null;)ur(a,e),a=a.next}}function io(t){let e=0,a=Yt(0),n;return()=>{gn()&&(i(a),mn(()=>(e===0&&(n=Ta(()=>t(()=>Sa(a)))),e+=1,()=>{bt(()=>{e-=1,e===0&&(n?.(),n=void 0,Sa(a))})})))}}var oo=sa|la;function so(t,e,a){new lo(t,e,a)}class lo{constructor(e,a,n){ae(this,Pe);gt(this,"parent");gt(this,"is_pending",!1);ae(this,lt);ae(this,Ln,null);ae(this,At);ae(this,aa);ae(this,ut);ae(this,pt,null);ae(this,We,null);ae(this,ht,null);ae(this,Mt,null);ae(this,na,0);ae(this,qt,0);ae(this,ga,!1);ae(this,ma,new Set);ae(this,wa,new Set);ae(this,Lt,null);ae(this,Xa,io(()=>($(this,Lt,Yt(h(this,na))),()=>{$(this,Lt,null)})));$(this,lt,e),$(this,At,a),$(this,aa,o=>{var r=se;r.b=this,r.f|=ln,n(o)}),this.parent=se.b,$(this,ut,wn(()=>{Oe(this,Pe,Fn).call(this)},oo))}defer_effect(e){lr(e,h(this,ma),h(this,wa))}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!h(this,At).pending}update_pending_count(e){Oe(this,Pe,Un).call(this,e),$(this,na,h(this,na)+e),!(!h(this,Lt)||h(this,ga))&&($(this,ga,!0),bt(()=>{$(this,ga,!1),h(this,Lt)&&va(h(this,Lt),h(this,na))}))}get_effect_pending(){return h(this,Xa).call(this),i(h(this,Lt))}error(e){var a=h(this,At).onerror;let n=h(this,At).failed;if(!a&&!n)throw e;h(this,pt)&&(qe(h(this,pt)),$(this,pt,null)),h(this,We)&&(qe(h(this,We)),$(this,We,null)),h(this,ht)&&(qe(h(this,ht)),$(this,ht,null));var o=!1,r=!1;const l=()=>{if(o){Qi();return}o=!0,r&&Ui(),h(this,ht)!==null&&Xt(h(this,ht),()=>{$(this,ht,null)}),Oe(this,Pe,tn).call(this,()=>{Ot.ensure(),Oe(this,Pe,Fn).call(this)})};bt(()=>{try{r=!0,a?.(e,l),r=!1}catch(d){ca(d,h(this,ut)&&h(this,ut).parent)}n&&$(this,ht,Oe(this,Pe,tn).call(this,()=>{Ot.ensure();try{return it(()=>{var d=se;d.b=this,d.f|=ln,n(h(this,lt),()=>e,()=>l)})}catch(d){return ca(d,h(this,ut).parent),null}}))})}}lt=new WeakMap,Ln=new WeakMap,At=new WeakMap,aa=new WeakMap,ut=new WeakMap,pt=new WeakMap,We=new WeakMap,ht=new WeakMap,Mt=new WeakMap,na=new WeakMap,qt=new WeakMap,ga=new WeakMap,ma=new WeakMap,wa=new WeakMap,Lt=new WeakMap,Xa=new WeakMap,Pe=new WeakSet,fd=function(){try{$(this,pt,it(()=>h(this,aa).call(this,h(this,lt))))}catch(e){this.error(e)}},ud=function(){const e=h(this,At).pending;e&&(this.is_pending=!0,$(this,We,it(()=>e(h(this,lt)))),bt(()=>{var a=$(this,Mt,document.createDocumentFragment()),n=zt();a.append(n),$(this,pt,Oe(this,Pe,tn).call(this,()=>(Ot.ensure(),it(()=>h(this,aa).call(this,n))))),h(this,qt)===0&&(h(this,lt).before(a),$(this,Mt,null),Xt(h(this,We),()=>{$(this,We,null)}),Oe(this,Pe,en).call(this))}))},Fn=function(){try{if(this.is_pending=this.has_pending_snippet(),$(this,qt,0),$(this,na,0),$(this,pt,it(()=>{h(this,aa).call(this,h(this,lt))})),h(this,qt)>0){var e=$(this,Mt,document.createDocumentFragment());Or(h(this,pt),e);const a=h(this,At).pending;$(this,We,it(()=>a(h(this,lt))))}else Oe(this,Pe,en).call(this)}catch(a){this.error(a)}},en=function(){this.is_pending=!1;for(const e of h(this,ma))Ce(e,Ie),rt(e);for(const e of h(this,wa))Ce(e,at),rt(e);h(this,ma).clear(),h(this,wa).clear()},tn=function(e){var a=se,n=ee,o=He;ct(h(this,ut)),Xe(h(this,ut)),da(h(this,ut).ctx);try{return e()}catch(r){return or(r),null}finally{ct(a),Xe(n),da(o)}},Un=function(e){var a;if(!this.has_pending_snippet()){this.parent&&Oe(a=this.parent,Pe,Un).call(a,e);return}$(this,qt,h(this,qt)+e),h(this,qt)===0&&(Oe(this,Pe,en).call(this),h(this,We)&&Xt(h(this,We),()=>{$(this,We,null)}),h(this,Mt)&&(h(this,lt).before(h(this,Mt)),$(this,Mt,null)))};function co(t,e,a,n){const o=Ha;var r=t.filter(u=>!u.settled);if(a.length===0&&r.length===0){n(e.map(o));return}var l=ve,d=se,s=vo(),c=r.length===1?r[0].promise:r.length>1?Promise.all(r.map(u=>u.promise)):null;function p(u){s();try{n(u)}catch(m){(d.f&wt)===0&&ca(m,d)}l?.deactivate(),pn()}if(a.length===0){c.then(()=>p(e.map(o)));return}function b(){s(),Promise.all(a.map(u=>uo(u))).then(u=>p([...e.map(o),...u])).catch(u=>ca(u,d))}c?c.then(b):b()}function vo(){var t=se,e=ee,a=He,n=ve;return function(r=!0){ct(t),Xe(e),da(a),r&&n?.activate()}}function pn(){ct(null),Xe(null),da(null)}function fo(){var t=se.b,e=ve,a=t.is_rendered();return t.update_pending_count(1),e.increment(a),()=>{t.update_pending_count(-1),e.decrement(a)}}function Ha(t){var e=De|Ie,a=ee!==null&&(ee.f&De)!==0?ee:null;return se!==null&&(se.f|=la),{ctx:He,deps:null,effects:null,equals:ar,f:e,fn:t,reactions:null,rv:0,v:Ne,wv:0,parent:a??se,ac:null}}function uo(t,e,a){se===null&&Li();var o=void 0,r=Yt(Ne),l=!ee,d=new Map;return Co(()=>{var s=Xn();o=s.promise;try{Promise.resolve(t()).then(s.resolve,s.reject).then(()=>{c===ve&&c.committed&&c.deactivate(),pn()})}catch(u){s.reject(u),pn()}var c=ve;if(l){var p=fo();d.get(c)?.reject(Vt),d.delete(c),d.set(c,s)}const b=(u,m=void 0)=>{if(c.activate(),m)m!==Vt&&(r.f|=Pt,va(r,m));else{(r.f&Pt)!==0&&(r.f^=Pt),va(r,u);for(const[z,M]of d){if(d.delete(z),z===c)break;M.reject(Vt)}}p&&p()};s.promise.then(b,u=>b(null,u||"unknown"))}),Cr(()=>{for(const s of d.values())s.reject(Vt)}),new Promise(s=>{function c(p){function b(){p===o?s(r):c(o)}p.then(b,b)}c(o)})}function j(t){const e=Ha(t);return Ir(e),e}function pr(t){const e=Ha(t);return e.equals=nr,e}function po(t){var e=t.effects;if(e!==null){t.effects=null;for(var a=0;a<e.length;a+=1)qe(e[a])}}function ho(t){for(var e=t.parent;e!==null;){if((e.f&De)===0)return(e.f&wt)===0?e:null;e=e.parent}return null}function hn(t){var e,a=se;ct(ho(t));try{t.f&=~Ht,po(t),e=Ur(t)}finally{ct(a)}return e}function hr(t){var e=hn(t);if(!t.equals(e)&&(t.wv=qr(),(!ve?.is_fork||t.deps===null)&&(t.v=e,t.deps===null))){Ce(t,Re);return}Nt||(nt!==null?(gn()||ve?.is_fork)&&nt.set(t,e):vn(t))}function _o(t){if(t.effects!==null)for(const e of t.effects)(e.teardown||e.ac)&&(e.teardown?.(),e.ac?.abort(Vt),e.teardown=ki,e.ac=null,Ea(e,0),xn(e))}function _r(t){if(t.effects!==null)for(const e of t.effects)e.teardown&&fa(e)}let _n=new Set;const Dt=new Map;let gr=!1;function Yt(t,e){var a={f:0,v:t,reactions:null,equals:ar,rv:0,wv:0};return a}function me(t,e){const a=Yt(t);return Ir(a),a}function go(t,e=!1,a=!0){const n=Yt(t);return e||(n.equals=nr),n}function U(t,e,a=!1){ee!==null&&(!ot||(ee.f&Qn)!==0)&&rr()&&(ee.f&(De|mt|cn|Qn))!==0&&(Je===null||!ia.call(Je,t))&&Fi();let n=a?Zt(e):e;return va(t,n)}function va(t,e){if(!t.equals(e)){var a=t.v;Nt?Dt.set(t,e):Dt.set(t,a),t.v=e;var n=Ot.ensure();if(n.capture(t,a),(t.f&De)!==0){const o=t;(t.f&Ie)!==0&&hn(o),vn(o)}t.wv=qr(),mr(t,Ie),se!==null&&(se.f&Re)!==0&&(se.f&(tt|Ut))===0&&(Qe===null?To([t]):Qe.push(t)),!n.is_fork&&_n.size>0&&!gr&&mo()}return e}function mo(){gr=!1;for(const t of _n)(t.f&Re)!==0&&Ce(t,at),Ca(t)&&fa(t);_n.clear()}function Sa(t){U(t,t.v+1)}function mr(t,e){var a=t.reactions;if(a!==null)for(var n=a.length,o=0;o<n;o++){var r=a[o],l=r.f,d=(l&Ie)===0;if(d&&Ce(r,e),(l&De)!==0){var s=r;nt?.delete(s),(l&Ht)===0&&(l&Ye&&(r.f|=Ht),mr(s,at))}else d&&((l&mt)!==0&&yt!==null&&yt.add(r),rt(r))}}function Zt(t){if(typeof t!="object"||t===null||ya in t)return t;const e=Yn(t);if(e!==zi&&e!==Si)return t;var a=new Map,n=Kn(t),o=me(0),r=Qt,l=d=>{if(Qt===r)return d();var s=ee,c=Qt;Xe(null),jr(r);var p=d();return Xe(s),jr(c),p};return n&&a.set("length",me(t.length)),new Proxy(t,{defineProperty(d,s,c){(!("value"in c)||c.configurable===!1||c.enumerable===!1||c.writable===!1)&&ji();var p=a.get(s);return p===void 0?l(()=>{var b=me(c.value);return a.set(s,b),b}):U(p,c.value,!0),!0},deleteProperty(d,s){var c=a.get(s);if(c===void 0){if(s in d){const p=l(()=>me(Ne));a.set(s,p),Sa(o)}}else U(c,Ne),Sa(o);return!0},get(d,s,c){if(s===ya)return t;var p=a.get(s),b=s in d;if(p===void 0&&(!b||oa(d,s)?.writable)&&(p=l(()=>{var m=Zt(b?d[s]:Ne),z=me(m);return z}),a.set(s,p)),p!==void 0){var u=i(p);return u===Ne?void 0:u}return Reflect.get(d,s,c)},getOwnPropertyDescriptor(d,s){var c=Reflect.getOwnPropertyDescriptor(d,s);if(c&&"value"in c){var p=a.get(s);p&&(c.value=i(p))}else if(c===void 0){var b=a.get(s),u=b?.v;if(b!==void 0&&u!==Ne)return{enumerable:!0,configurable:!0,value:u,writable:!0}}return c},has(d,s){if(s===ya)return!0;var c=a.get(s),p=c!==void 0&&c.v!==Ne||Reflect.has(d,s);if(c!==void 0||se!==null&&(!p||oa(d,s)?.writable)){c===void 0&&(c=l(()=>{var u=p?Zt(d[s]):Ne,m=me(u);return m}),a.set(s,c));var b=i(c);if(b===Ne)return!1}return p},set(d,s,c,p){var b=a.get(s),u=s in d;if(n&&s==="length")for(var m=c;m<b.v;m+=1){var z=a.get(m+"");z!==void 0?U(z,Ne):m in d&&(z=l(()=>me(Ne)),a.set(m+"",z))}if(b===void 0)(!u||oa(d,s)?.writable)&&(b=l(()=>me(void 0)),U(b,Zt(c)),a.set(s,b));else{u=b.v!==Ne;var M=l(()=>Zt(c));U(b,M)}var f=Reflect.getOwnPropertyDescriptor(d,s);if(f?.set&&f.set.call(p,c),!u){if(n&&typeof s=="string"){var y=a.get("length"),S=Number(s);Number.isInteger(S)&&S>=y.v&&U(y,S+1)}Sa(o)}return!0},ownKeys(d){i(o);var s=Reflect.ownKeys(d).filter(b=>{var u=a.get(b);return u===void 0||u.v!==Ne});for(var[c,p]of a)p.v!==Ne&&!(c in d)&&s.push(c);return s},setPrototypeOf(){qi()}})}var wr,xr,br,yr;function wo(){if(wr===void 0){wr=window,xr=/Firefox/.test(navigator.userAgent);var t=Element.prototype,e=Node.prototype,a=Text.prototype;br=oa(e,"firstChild").get,yr=oa(e,"nextSibling").get,Zn(t)&&(t.__click=void 0,t.__className=void 0,t.__attributes=null,t.__style=void 0,t.__e=void 0),Zn(a)&&(a.__t=void 0)}}function zt(t=""){return document.createTextNode(t)}function It(t){return br.call(t)}function ka(t){return yr.call(t)}function v(t,e){return It(t)}function Ze(t,e=!1){{var a=It(t);return a instanceof Comment&&a.data===""?ka(a):a}}function _(t,e=1,a=!1){let n=t;for(;e--;)n=ka(n);return n}function xo(t){t.textContent=""}function zr(){return!1}function Sr(t,e,a){return document.createElementNS(tr,t,void 0)}let kr=!1;function bo(){kr||(kr=!0,document.addEventListener("reset",t=>{Promise.resolve().then(()=>{if(!t.defaultPrevented)for(const e of t.target.elements)e.__on_r?.()})},{capture:!0}))}function Va(t){var e=ee,a=se;Xe(null),ct(null);try{return t()}finally{Xe(e),ct(a)}}function yo(t,e,a,n=a){t.addEventListener(e,()=>Va(a));const o=t.__on_r;o?t.__on_r=()=>{o(),n(!0)}:t.__on_r=()=>n(!0),bo()}function zo(t){se===null&&(ee===null&&Di(),Oi()),Nt&&Pi()}function So(t,e){var a=e.last;a===null?e.last=e.first=t:(a.next=t,t.prev=a,e.last=t)}function St(t,e,a){var n=se;n!==null&&(n.f&Be)!==0&&(t|=Be);var o={ctx:He,deps:null,nodes:null,f:t|Ie|Ye,first:null,fn:e,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null};if(a)try{fa(o)}catch(d){throw qe(o),d}else e!==null&&rt(o);var r=o;if(a&&r.deps===null&&r.teardown===null&&r.nodes===null&&r.first===r.last&&(r.f&la)===0&&(r=r.first,(t&mt)!==0&&(t&sa)!==0&&r!==null&&(r.f|=sa)),r!==null&&(r.parent=n,n!==null&&So(r,n),ee!==null&&(ee.f&De)!==0&&(t&Ut)===0)){var l=ee;(l.effects??(l.effects=[])).push(r)}return o}function gn(){return ee!==null&&!ot}function Cr(t){const e=St(Fa,null,!1);return Ce(e,Re),e.teardown=t,e}function kt(t){zo();var e=se.f,a=!ee&&(e&tt)!==0&&(e&Bt)===0;if(a){var n=He;(n.e??(n.e=[])).push(t)}else return Er(t)}function Er(t){return St(ba|Ei,t,!1)}function ko(t){Ot.ensure();const e=St(Ut|la,t,!0);return(a={})=>new Promise(n=>{a.outro?Xt(e,()=>{qe(e),n(void 0)}):(qe(e),n(void 0))})}function Tr(t){return St(ba,t,!1)}function Co(t){return St(cn|la,t,!0)}function mn(t,e=0){return St(Fa|e,t,!0)}function L(t,e=[],a=[],n=[]){co(n,e,a,o=>{St(Fa,()=>t(...o.map(i)),!0)})}function wn(t,e=0){var a=St(mt|e,t,!0);return a}function it(t){return St(tt|la,t,!0)}function Ar(t){var e=t.teardown;if(e!==null){const a=Nt,n=ee;Dr(!0),Xe(null);try{e.call(null)}finally{Dr(a),Xe(n)}}}function xn(t,e=!1){var a=t.first;for(t.first=t.last=null;a!==null;){const o=a.ac;o!==null&&Va(()=>{o.abort(Vt)});var n=a.next;(a.f&Ut)!==0?a.parent=null:qe(a,e),a=n}}function Eo(t){for(var e=t.first;e!==null;){var a=e.next;(e.f&tt)===0&&qe(e),e=a}}function qe(t,e=!0){var a=!1;(e||(t.f&$n)!==0)&&t.nodes!==null&&t.nodes.end!==null&&(Mr(t.nodes.start,t.nodes.end),a=!0),xn(t,e&&!a),Ea(t,0),Ce(t,wt);var n=t.nodes&&t.nodes.t;if(n!==null)for(const r of n)r.stop();Ar(t);var o=t.parent;o!==null&&o.first!==null&&Lr(t),t.next=t.prev=t.teardown=t.ctx=t.deps=t.fn=t.nodes=t.ac=null}function Mr(t,e){for(;t!==null;){var a=t===e?null:ka(t);t.remove(),t=a}}function Lr(t){var e=t.parent,a=t.prev,n=t.next;a!==null&&(a.next=n),n!==null&&(n.prev=a),e!==null&&(e.first===t&&(e.first=n),e.last===t&&(e.last=a))}function Xt(t,e,a=!0){var n=[];Rr(t,n,!0);var o=()=>{a&&qe(t),e&&e()},r=n.length;if(r>0){var l=()=>--r||o();for(var d of n)d.out(l)}else o()}function Rr(t,e,a){if((t.f&Be)===0){t.f^=Be;var n=t.nodes&&t.nodes.t;if(n!==null)for(const d of n)(d.is_global||a)&&e.push(d);for(var o=t.first;o!==null;){var r=o.next,l=(o.f&sa)!==0||(o.f&tt)!==0&&(t.f&mt)!==0;Rr(o,e,l?a:!1),o=r}}}function bn(t){Pr(t,!0)}function Pr(t,e){if((t.f&Be)!==0){t.f^=Be,(t.f&Re)===0&&(Ce(t,Ie),rt(t));for(var a=t.first;a!==null;){var n=a.next,o=(a.f&sa)!==0||(a.f&tt)!==0;Pr(a,o?e:!1),a=n}var r=t.nodes&&t.nodes.t;if(r!==null)for(const l of r)(l.is_global||e)&&l.in()}}function Or(t,e){if(t.nodes)for(var a=t.nodes.start,n=t.nodes.end;a!==null;){var o=a===n?null:ka(a);e.append(a),a=o}}let Ga=!1,Nt=!1;function Dr(t){Nt=t}let ee=null,ot=!1;function Xe(t){ee=t}let se=null;function ct(t){se=t}let Je=null;function Ir(t){ee!==null&&(Je===null?Je=[t]:Je.push(t))}let Fe=null,Ve=0,Qe=null;function To(t){Qe=t}let Nr=1,Jt=0,Qt=Jt;function jr(t){Qt=t}function qr(){return++Nr}function Ca(t){var e=t.f;if((e&Ie)!==0)return!0;if(e&De&&(t.f&=~Ht),(e&at)!==0){for(var a=t.deps,n=a.length,o=0;o<n;o++){var r=a[o];if(Ca(r)&&hr(r),r.wv>t.wv)return!0}(e&Ye)!==0&&nt===null&&Ce(t,Re)}return!1}function Fr(t,e,a=!0){var n=t.reactions;if(n!==null&&!(Je!==null&&ia.call(Je,t)))for(var o=0;o<n.length;o++){var r=n[o];(r.f&De)!==0?Fr(r,e,!1):e===r&&(a?Ce(r,Ie):(r.f&Re)!==0&&Ce(r,at),rt(r))}}function Ur(t){var M;var e=Fe,a=Ve,n=Qe,o=ee,r=Je,l=He,d=ot,s=Qt,c=t.f;Fe=null,Ve=0,Qe=null,ee=(c&(tt|Ut))===0?t:null,Je=null,da(t.ctx),ot=!1,Qt=++Jt,t.ac!==null&&(Va(()=>{t.ac.abort(Vt)}),t.ac=null);try{t.f|=dn;var p=t.fn,b=p();t.f|=Bt;var u=t.deps,m=ve?.is_fork;if(Fe!==null){var z;if(m||Ea(t,Ve),u!==null&&Ve>0)for(u.length=Ve+Fe.length,z=0;z<Fe.length;z++)u[Ve+z]=Fe[z];else t.deps=u=Fe;if(gn()&&(t.f&Ye)!==0)for(z=Ve;z<u.length;z++)((M=u[z]).reactions??(M.reactions=[])).push(t)}else!m&&u!==null&&Ve<u.length&&(Ea(t,Ve),u.length=Ve);if(rr()&&Qe!==null&&!ot&&u!==null&&(t.f&(De|at|Ie))===0)for(z=0;z<Qe.length;z++)Fr(Qe[z],t);if(o!==null&&o!==t){if(Jt++,o.deps!==null)for(let f=0;f<a;f+=1)o.deps[f].rv=Jt;if(e!==null)for(const f of e)f.rv=Jt;Qe!==null&&(n===null?n=Qe:n.push(...Qe))}return(t.f&Pt)!==0&&(t.f^=Pt),b}catch(f){return or(f)}finally{t.f^=dn,Fe=e,Ve=a,Qe=n,ee=o,Je=r,da(l),ot=d,Qt=s}}function Ao(t,e){let a=e.reactions;if(a!==null){var n=xi.call(a,t);if(n!==-1){var o=a.length-1;o===0?a=e.reactions=null:(a[n]=a[o],a.pop())}}if(a===null&&(e.f&De)!==0&&(Fe===null||!ia.call(Fe,e))){var r=e;(r.f&Ye)!==0&&(r.f^=Ye,r.f&=~Ht),vn(r),_o(r),Ea(r,0)}}function Ea(t,e){var a=t.deps;if(a!==null)for(var n=e;n<a.length;n++)Ao(t,a[n])}function fa(t){var e=t.f;if((e&wt)===0){Ce(t,Re);var a=se,n=Ga;se=t,Ga=!0;try{(e&(mt|Jn))!==0?Eo(t):xn(t),Ar(t);var o=Ur(t);t.teardown=typeof o=="function"?o:null,t.wv=Nr;var r;sn&&eo&&(t.f&Ie)!==0&&t.deps}finally{Ga=n,se=a}}}async function Mo(){await Promise.resolve(),no()}function i(t){var e=t.f,a=(e&De)!==0;if(ee!==null&&!ot){var n=se!==null&&(se.f&wt)!==0;if(!n&&(Je===null||!ia.call(Je,t))){var o=ee.deps;if((ee.f&dn)!==0)t.rv<Jt&&(t.rv=Jt,Fe===null&&o!==null&&o[Ve]===t?Ve++:Fe===null?Fe=[t]:Fe.push(t));else{(ee.deps??(ee.deps=[])).push(t);var r=t.reactions;r===null?t.reactions=[ee]:ia.call(r,ee)||r.push(ee)}}}if(Nt&&Dt.has(t))return Dt.get(t);if(a){var l=t;if(Nt){var d=l.v;return((l.f&Re)===0&&l.reactions!==null||Hr(l))&&(d=hn(l)),Dt.set(l,d),d}var s=(l.f&Ye)===0&&!ot&&ee!==null&&(Ga||(ee.f&Ye)!==0),c=(l.f&Bt)===0;Ca(l)&&(s&&(l.f|=Ye),hr(l)),s&&!c&&(_r(l),Br(l))}if(nt?.has(t))return nt.get(t);if((t.f&Pt)!==0)throw t.v;return t.v}function Br(t){if(t.f|=Ye,t.deps!==null)for(const e of t.deps)(e.reactions??(e.reactions=[])).push(t),(e.f&De)!==0&&(e.f&Ye)===0&&(_r(e),Br(e))}function Hr(t){if(t.v===Ne)return!0;if(t.deps===null)return!1;for(const e of t.deps)if(Dt.has(e)||(e.f&De)!==0&&Hr(e))return!0;return!1}function Ta(t){var e=ot;try{return ot=!0,t()}finally{ot=e}}const Lo=["touchstart","touchmove"];function Ro(t){return Lo.includes(t)}const $t=Symbol("events"),Vr=new Set,yn=new Set;function Po(t,e,a,n={}){function o(r){if(n.capture||zn.call(e,r),!r.cancelBubble)return Va(()=>a?.call(this,r))}return t.startsWith("pointer")||t.startsWith("touch")||t==="wheel"?bt(()=>{e.addEventListener(t,o,n)}):e.addEventListener(t,o,n),o}function Gr(t,e,a,n,o){var r={capture:n,passive:o},l=Po(t,e,a,r);(e===document.body||e===window||e===document||e instanceof HTMLMediaElement)&&Cr(()=>{e.removeEventListener(t,l,r)})}function vt(t,e,a){(e[$t]??(e[$t]={}))[t]=a}function Wr(t){for(var e=0;e<t.length;e++)Vr.add(t[e]);for(var a of yn)a(t)}let Kr=null;function zn(t){var e=this,a=e.ownerDocument,n=t.type,o=t.composedPath?.()||[],r=o[0]||t.target;Kr=t;var l=0,d=Kr===t&&t[$t];if(d){var s=o.indexOf(d);if(s!==-1&&(e===document||e===window)){t[$t]=e;return}var c=o.indexOf(e);if(c===-1)return;s<=c&&(l=s)}if(r=o[l]||t.target,r!==e){bi(t,"currentTarget",{configurable:!0,get(){return r||a}});var p=ee,b=se;Xe(null),ct(null);try{for(var u,m=[];r!==null;){var z=r.assignedSlot||r.parentNode||r.host||null;try{var M=r[$t]?.[n];M!=null&&(!r.disabled||t.target===r)&&M.call(r,t)}catch(f){u?m.push(f):u=f}if(t.cancelBubble||z===e||z===null)break;r=z}if(u){for(let f of m)queueMicrotask(()=>{throw f});throw u}}finally{t[$t]=e,delete t.currentTarget,Xe(p),ct(b)}}}const Oo=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:t=>t});function Do(t){return Oo?.createHTML(t)??t}function Yr(t,e=!1){var a=Sr("template");return t=t.replaceAll("<!>","<!---->"),a.innerHTML=e?Do(t):t,a.content}function Aa(t,e){var a=se;a.nodes===null&&(a.nodes={start:t,end:e,a:null,t:null})}function x(t,e){var a=(e&Xi)!==0,n=(e&Ji)!==0,o,r=!t.startsWith("<!>");return()=>{o===void 0&&(o=Yr(r?t:"<!>"+t,!0),a||(o=It(o)));var l=n||xr?document.importNode(o,!0):o.cloneNode(!0);if(a){var d=It(l),s=l.lastChild;Aa(d,s)}else Aa(l,l);return l}}function Wa(t=""){{var e=zt(t+"");return Aa(e,e),e}}function Ma(){var t=document.createDocumentFragment(),e=document.createComment(""),a=zt();return t.append(e,a),Aa(e,a),t}function g(t,e){t!==null&&t.before(e)}function T(t,e){var a=e==null?"":typeof e=="object"?e+"":e;a!==(t.__t??(t.__t=t.nodeValue))&&(t.__t=a,t.nodeValue=a+"")}function Io(t,e){return No(t,e)}const Ka=new Map;function No(t,{target:e,anchor:a,props:n={},events:o,context:r,intro:l=!0}){wo();var d=void 0,s=ko(()=>{var c=a??e.appendChild(zt());so(c,{pending:()=>{}},u=>{Gt({});var m=He;r&&(m.c=r),o&&(n.$$events=o),d=t(u,n)||{},Wt()});var p=new Set,b=u=>{for(var m=0;m<u.length;m++){var z=u[m];if(!p.has(z)){p.add(z);var M=Ro(z);for(const S of[e,document]){var f=Ka.get(S);f===void 0&&(f=new Map,Ka.set(S,f));var y=f.get(z);y===void 0?(S.addEventListener(z,zn,{passive:M}),f.set(z,1)):f.set(z,y+1)}}}};return b(qa(Vr)),yn.add(b),()=>{for(var u of p)for(const M of[e,document]){var m=Ka.get(M),z=m.get(u);--z==0?(M.removeEventListener(u,zn),m.delete(u),m.size===0&&Ka.delete(M)):m.set(u,z)}yn.delete(b),c!==a&&c.parentNode?.removeChild(c)}});return Sn.set(d,s),d}let Sn=new WeakMap;function jo(t,e){const a=Sn.get(t);return a?(Sn.delete(t),a(e)):Promise.resolve()}class qo{constructor(e,a=!0){gt(this,"anchor");ae(this,dt,new Map);ae(this,_t,new Map);ae(this,Ke,new Map);ae(this,ra,new Set);ae(this,Ia,!0);ae(this,Na,()=>{var e=ve;if(h(this,dt).has(e)){var a=h(this,dt).get(e),n=h(this,_t).get(a);if(n)bn(n),h(this,ra).delete(a);else{var o=h(this,Ke).get(a);o&&(h(this,_t).set(a,o.effect),h(this,Ke).delete(a),o.fragment.lastChild.remove(),this.anchor.before(o.fragment),n=o.effect)}for(const[r,l]of h(this,dt)){if(h(this,dt).delete(r),r===e)break;const d=h(this,Ke).get(l);d&&(qe(d.effect),h(this,Ke).delete(l))}for(const[r,l]of h(this,_t)){if(r===a||h(this,ra).has(r))continue;const d=()=>{if(Array.from(h(this,dt).values()).includes(r)){var c=document.createDocumentFragment();Or(l,c),c.append(zt()),h(this,Ke).set(r,{effect:l,fragment:c})}else qe(l);h(this,ra).delete(r),h(this,_t).delete(r)};h(this,Ia)||!n?(h(this,ra).add(r),Xt(l,d,!1)):d()}}});ae(this,Ja,e=>{h(this,dt).delete(e);const a=Array.from(h(this,dt).values());for(const[n,o]of h(this,Ke))a.includes(n)||(qe(o.effect),h(this,Ke).delete(n))});this.anchor=e,$(this,Ia,a)}ensure(e,a){var n=ve,o=zr();if(a&&!h(this,_t).has(e)&&!h(this,Ke).has(e))if(o){var r=document.createDocumentFragment(),l=zt();r.append(l),h(this,Ke).set(e,{effect:it(()=>a(l)),fragment:r})}else h(this,_t).set(e,it(()=>a(this.anchor)));if(h(this,dt).set(n,e),o){for(const[d,s]of h(this,_t))d===e?n.unskip_effect(s):n.skip_effect(s);for(const[d,s]of h(this,Ke))d===e?n.unskip_effect(s.effect):n.skip_effect(s.effect);n.oncommit(h(this,Na)),n.ondiscard(h(this,Ja))}else h(this,Na).call(this)}}dt=new WeakMap,_t=new WeakMap,Ke=new WeakMap,ra=new WeakMap,Ia=new WeakMap,Na=new WeakMap,Ja=new WeakMap;function P(t,e,a=!1){var n=new qo(t),o=a?sa:0;function r(l,d){n.ensure(l,d)}wn(()=>{var l=!1;e((d,s=0)=>{l=!0,r(s,d)}),l||r(!1,null)},o)}function st(t,e){return e}function Fo(t,e,a){for(var n=[],o=e.length,r,l=e.length,d=0;d<o;d++){let b=e[d];Xt(b,()=>{if(r){if(r.pending.delete(b),r.done.add(b),r.pending.size===0){var u=t.outrogroups;kn(qa(r.done)),u.delete(r),u.size===0&&(t.outrogroups=null)}}else l-=1},!1)}if(l===0){var s=n.length===0&&a!==null;if(s){var c=a,p=c.parentNode;xo(p),p.append(c),t.items.clear()}kn(e,!s)}else r={pending:new Set(e),done:new Set},(t.outrogroups??(t.outrogroups=new Set)).add(r)}function kn(t,e=!0){for(var a=0;a<t.length;a++)qe(t[a],e)}var Zr;function $e(t,e,a,n,o,r=null){var l=t,d=new Map,s=(e&er)!==0;if(s){var c=t;l=c.appendChild(zt())}var p=null,b=pr(()=>{var y=a();return Kn(y)?y:y==null?[]:qa(y)}),u,m=!0;function z(){f.fallback=p,Uo(f,u,l,e,n),p!==null&&(u.length===0?(p.f&xt)===0?bn(p):(p.f^=xt,Ra(p,null,l)):Xt(p,()=>{p=null}))}var M=wn(()=>{u=i(b);for(var y=u.length,S=new Set,k=ve,q=zr(),Z=0;Z<y;Z+=1){var J=u[Z],K=n(J,Z),oe=m?null:d.get(K);oe?(oe.v&&va(oe.v,J),oe.i&&va(oe.i,Z),q&&k.unskip_effect(oe.e)):(oe=Bo(d,m?l:Zr??(Zr=zt()),J,K,Z,o,e,a),m||(oe.e.f|=xt),d.set(K,oe)),S.add(K)}if(y===0&&r&&!p&&(m?p=it(()=>r(l)):(p=it(()=>r(Zr??(Zr=zt()))),p.f|=xt)),y>S.size&&Ri(),!m)if(q){for(const[ze,H]of d)S.has(ze)||k.skip_effect(H.e);k.oncommit(z),k.ondiscard(()=>{})}else z();i(b)}),f={effect:M,items:d,outrogroups:null,fallback:p};m=!1}function La(t){for(;t!==null&&(t.f&tt)===0;)t=t.next;return t}function Uo(t,e,a,n,o){var r=(n&Vi)!==0,l=e.length,d=t.items,s=La(t.effect.first),c,p=null,b,u=[],m=[],z,M,f,y;if(r)for(y=0;y<l;y+=1)z=e[y],M=o(z,y),f=d.get(M).e,(f.f&xt)===0&&(f.nodes?.a?.measure(),(b??(b=new Set)).add(f));for(y=0;y<l;y+=1){if(z=e[y],M=o(z,y),f=d.get(M).e,t.outrogroups!==null)for(const H of t.outrogroups)H.pending.delete(f),H.done.delete(f);if((f.f&xt)!==0)if(f.f^=xt,f===s)Ra(f,null,a);else{var S=p?p.next:s;f===t.effect.last&&(t.effect.last=f.prev),f.prev&&(f.prev.next=f.next),f.next&&(f.next.prev=f.prev),jt(t,p,f),jt(t,f,S),Ra(f,S,a),p=f,u=[],m=[],s=La(p.next);continue}if((f.f&Be)!==0&&(bn(f),r&&(f.nodes?.a?.unfix(),(b??(b=new Set)).delete(f))),f!==s){if(c!==void 0&&c.has(f)){if(u.length<m.length){var k=m[0],q;p=k.prev;var Z=u[0],J=u[u.length-1];for(q=0;q<u.length;q+=1)Ra(u[q],k,a);for(q=0;q<m.length;q+=1)c.delete(m[q]);jt(t,Z.prev,J.next),jt(t,p,Z),jt(t,J,k),s=k,p=J,y-=1,u=[],m=[]}else c.delete(f),Ra(f,s,a),jt(t,f.prev,f.next),jt(t,f,p===null?t.effect.first:p.next),jt(t,p,f),p=f;continue}for(u=[],m=[];s!==null&&s!==f;)(c??(c=new Set)).add(s),m.push(s),s=La(s.next);if(s===null)continue}(f.f&xt)===0&&u.push(f),p=f,s=La(f.next)}if(t.outrogroups!==null){for(const H of t.outrogroups)H.pending.size===0&&(kn(qa(H.done)),t.outrogroups?.delete(H));t.outrogroups.size===0&&(t.outrogroups=null)}if(s!==null||c!==void 0){var K=[];if(c!==void 0)for(f of c)(f.f&Be)===0&&K.push(f);for(;s!==null;)(s.f&Be)===0&&s!==t.fallback&&K.push(s),s=La(s.next);var oe=K.length;if(oe>0){var ze=(n&er)!==0&&l===0?a:null;if(r){for(y=0;y<oe;y+=1)K[y].nodes?.a?.measure();for(y=0;y<oe;y+=1)K[y].nodes?.a?.fix()}Fo(t,K,ze)}}r&&bt(()=>{if(b!==void 0)for(f of b)f.nodes?.a?.apply()})}function Bo(t,e,a,n,o,r,l,d){var s=(l&Bi)!==0?(l&Gi)===0?go(a,!1,!1):Yt(a):null,c=(l&Hi)!==0?Yt(o):null;return{v:s,i:c,e:it(()=>(r(e,s??a,c??o,d),()=>{t.delete(n)}))}}function Ra(t,e,a){if(t.nodes)for(var n=t.nodes.start,o=t.nodes.end,r=e&&(e.f&xt)===0?e.nodes.start:a;n!==null;){var l=ka(n);if(r.before(n),n===o)return;n=l}}function jt(t,e,a){e===null?t.effect.first=a:e.next=a,a===null?t.effect.last=e:a.prev=e}function Xr(t,e,a=!1,n=!1,o=!1){var r=t,l="";L(()=>{var d=se;if(l!==(l=e()??"")&&(d.nodes!==null&&(Mr(d.nodes.start,d.nodes.end),d.nodes=null),l!=="")){var s=l+"";a?s=`<svg>${s}</svg>`:n&&(s=`<math>${s}</math>`);var c=Yr(s);if((a||n)&&(c=It(c)),Aa(It(c),c.lastChild),a||n)for(;It(c);)r.before(It(c));else r.before(c)}})}function ft(t,e){Tr(()=>{var a=t.getRootNode(),n=a.host?a:a.head??a.ownerDocument.head;if(!n.querySelector("#"+e.hash)){const o=Sr("style");o.id=e.hash,o.textContent=e.code,n.appendChild(o)}})}const Jr=[...`
|
|
5
|
+
\r\f \v\uFEFF`];function Ho(t,e,a){var n=t==null?"":""+t;if(e&&(n=n?n+" "+e:e),a){for(var o in a)if(a[o])n=n?n+" "+o:o;else if(n.length)for(var r=o.length,l=0;(l=n.indexOf(o,l))>=0;){var d=l+r;(l===0||Jr.includes(n[l-1]))&&(d===n.length||Jr.includes(n[d]))?n=(l===0?"":n.substring(0,l))+n.substring(d+1):l=d}}return n===""?null:n}function Vo(t,e){return t==null?null:String(t)}function Ue(t,e,a,n,o,r){var l=t.__className;if(l!==a||l===void 0){var d=Ho(a,n,r);d==null?t.removeAttribute("class"):t.className=d,t.__className=a}else if(r&&o!==r)for(var s in r){var c=!!r[s];(o==null||c!==!!o[s])&&t.classList.toggle(s,c)}return r}function be(t,e,a,n){var o=t.__style;if(o!==e){var r=Vo(e);r==null?t.removeAttribute("style"):t.style.cssText=r,t.__style=e}return n}const Go=Symbol("is custom element"),Wo=Symbol("is html");function pe(t,e,a,n){var o=Ko(t);o[e]!==(o[e]=a)&&(e==="loading"&&(t[Ai]=a),a==null?t.removeAttribute(e):typeof a!="string"&&Yo(t).includes(e)?t[e]=a:t.setAttribute(e,a))}function Ko(t){return t.__attributes??(t.__attributes={[Go]:t.nodeName.includes("-"),[Wo]:t.namespaceURI===tr})}var Qr=new Map;function Yo(t){var e=t.getAttribute("is")||t.nodeName,a=Qr.get(e);if(a)return a;Qr.set(e,a=[]);for(var n,o=t,r=Element.prototype;r!==o;){n=yi(o);for(var l in n)n[l].set&&a.push(l);o=Yn(o)}return a}function Zo(t,e,a=e){var n=new WeakSet;yo(t,"input",async o=>{var r=o?t.defaultValue:t.value;if(r=Cn(t)?En(r):r,a(r),ve!==null&&n.add(ve),await Mo(),r!==(r=e())){var l=t.selectionStart,d=t.selectionEnd,s=t.value.length;if(t.value=r??"",d!==null){var c=t.value.length;l===d&&d===s&&c>s?(t.selectionStart=c,t.selectionEnd=c):(t.selectionStart=l,t.selectionEnd=Math.min(d,c))}}}),Ta(e)==null&&t.value&&(a(Cn(t)?En(t.value):t.value),ve!==null&&n.add(ve)),mn(()=>{var o=e();if(t===document.activeElement){var r=fn??ve;if(n.has(r))return}Cn(t)&&o===En(t.value)||t.type==="date"&&!o&&!t.value||o!==t.value&&(t.value=o??"")})}function Cn(t){var e=t.type;return e==="number"||e==="range"}function En(t){return t===""?null:+t}function $r(t,e){return t===e||t?.[ya]===e}function Pa(t={},e,a,n){return Tr(()=>{var o,r;return mn(()=>{o=r,r=[],Ta(()=>{t!==a(...r)&&(e(t,...r),o&&$r(a(...o),t)&&e(null,...o))})}),()=>{bt(()=>{r&&$r(a(...r),t)&&e(null,...r)})}}),t}let Ya=!1;function Xo(t){var e=Ya;try{return Ya=!1,[t(),Ya]}finally{Ya=e}}function B(t,e,a,n){var o=(a&Yi)!==0,r=(a&Zi)!==0,l=n,d=!0,s=()=>(d&&(d=!1,l=r?Ta(n):n),l),c;if(o){var p=ya in t||Ti in t;c=oa(t,e)?.set??(p&&e in t?S=>t[e]=S:void 0)}var b,u=!1;o?[b,u]=Xo(()=>t[e]):b=t[e],b===void 0&&n!==void 0&&(b=s(),c&&(Ni(),c(b)));var m;if(m=()=>{var S=t[e];return S===void 0?s():(d=!0,S)},(a&Ki)===0)return m;if(c){var z=t.$$legacy;return(function(S,k){return arguments.length>0?((!k||z||u)&&c(k?m():S),S):m()})}var M=!1,f=((a&Wi)!==0?Ha:pr)(()=>(M=!1,m()));o&&i(f);var y=se;return(function(S,k){if(arguments.length>0){const q=k?i(f):o?Zt(S):S;return U(f,q),M=!0,l!==void 0&&(l=q),S}return Nt&&M||(y.f&wt)!==0?f.v:i(f)})}function Jo(t){He===null&&Mi(),kt(()=>{const e=Ta(t);if(typeof e=="function")return e})}function Qo(t,e){var a,n;return n=class{constructor(r){ae(this,a,null);if(!Ft)throw new Error(`[sevn] ${e} só pode ser instanciado no navegador. Em SSR, monte o componente dentro de um efeito de cliente.`);const{target:l,...d}=r??{},s=typeof l=="string"?document.querySelector(l):l;if(!s)throw new Error(`[sevn] ${e}: alvo não encontrado`+(typeof l=="string"?` para o seletor "${l}".`:"."));_i(),$(this,a,Io(t,{target:s,props:d}))}destroy(){if(!h(this,a))return Promise.resolve();const r=h(this,a);return $(this,a,null),jo(r)}},a=new WeakMap,n}function ei(t){try{return new URL(t,document.baseURI).searchParams.get("cid")}catch{return null}}function $o(){const t=document.currentScript;if(t?.src){const a=ei(t.src);if(a)return a}const e=document.querySelectorAll('script[src*="cid="]');for(const a of e){const n=ei(a.src);if(n)return n}return null}function es(){if(!Ft)return;const t=$o();if(t)try{an(t)}catch(e){console.error("[sevn] Chave inválida na tag <script>:",e)}}const ts="5";typeof window<"u"&&((li=window.__svelte??(window.__svelte={})).v??(li.v=new Set)).add(ts);const as="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",ns="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 rs=x('<span class="avatar-tag svelte-ga6vh2"> </span>'),is=x('<div class="avatar-container svelte-ga6vh2"><div class="avatar svelte-ga6vh2"><img width="1" height="1"/></div> <!></div>');const os={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 Ct(t,e){ft(t,os);let a=B(e,"avatar",3,"man"),n=B(e,"size",3,"md"),o=B(e,"tagColor",3,"var(--sevn-color-green)"),r=me(!1);const l=j(()=>a()==="woman"?ns:as),d=j(()=>!!e.photoUrl&&!i(r)),s=j(()=>i(d)?e.photoUrl:i(l)),c={sm:"40px",md:"56px",lg:"72px"},p={sm:{fontSize:"9px",padding:"1px 5px"},md:{fontSize:"12px",padding:"2px 8px"},lg:{fontSize:"14px",padding:"3px 10px"}},b=j(()=>c[n()]??n()),u=j(()=>p[n()]??p.md);var m=is(),z=v(m),M=v(z);let f;var y=_(z,2);{var S=k=>{var q=rs(),Z=v(q);L(()=>{be(q,`background-color: ${o()??""}; font-size: ${i(u).fontSize??""}; padding: ${i(u).padding??""};`),T(Z,e.tag)}),g(k,q)};P(y,k=>{e.tag&&k(S)})}L(()=>{be(z,`background-color: ${e.avatarColor??"var(--sevn-color-secondary)"??""}; width: ${i(b)??""}; height: ${i(b)??""};`),f=Ue(M,1,"avatar-image svelte-ga6vh2",null,f,{"avatar-image--photo":i(d)}),pe(M,"src",i(s)),pe(M,"alt",e.name)}),Gr("error",M,()=>U(r,!0)),g(t,m)}const ss="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",ti="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",ls="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 ds=x('<span class="mobile-label svelte-1dw55dz"> </span>'),cs=x('<input class="search-input svelte-1dw55dz" type="text"/>'),vs=x('<span class="field-label-prefix svelte-1dw55dz"> </span>'),fs=x('<span class="field-text svelte-1dw55dz"><!> </span>'),us=x("<span> </span>"),ps=x('<button class="icon-clear svelte-1dw55dz" type="button" aria-label="Limpar seleção"><img alt="" aria-hidden="true"/></button>'),hs=x('<img alt="" aria-hidden="true"/>'),_s=x('<img class="icon-search svelte-1dw55dz" alt="" aria-hidden="true"/>'),gs=x('<span class="meta svelte-1dw55dz"> </span>'),ms=x('<div class="web-info svelte-1dw55dz"><span class="selected-label svelte-1dw55dz"><strong class="svelte-1dw55dz">Você selecionou:</strong> </span> <!></div>'),ws=x('<button type="button" role="option"> </button>'),xs=x('<div class="no-results svelte-1dw55dz">Nenhum resultado encontrado</div>'),bs=x('<div class="dropdown svelte-1dw55dz" role="listbox"></div>'),ys=x('<div><!> <div role="combobox" aria-haspopup="listbox"><!> <!></div> <!> <!></div>');const zs={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 Ss(t,e){Gt(e,!0),ft(t,zs);let a=B(e,"label",3,""),n=B(e,"showLabel",3,!0),o=B(e,"options",19,()=>[]),r=B(e,"value",15,null),l=B(e,"meta",3,""),d=B(e,"width",3,"100%"),s=B(e,"height",3,"48px"),c=B(e,"icon",3,ss),p=B(e,"iconSize",3,13),b=B(e,"showLabelInField",3,!1),u=B(e,"showDescriptionSelection",3,!0),m=B(e,"labelAsPlaceholder",3,!0),z=B(e,"showPlaceholderOnMobile",3,!1),M=B(e,"disabled",3,!1),f=B(e,"clearable",3,!0);const y=`autocomplete-listbox-${Math.random().toString(36).slice(2,9)}`;let S=me(!1),k=me(""),q=me(null),Z=me(null),J=j(()=>i(k).trim()?o().filter(w=>w.label.toLowerCase().includes(i(k).trim().toLowerCase())):o()),K=j(()=>r()!=null?o().find(w=>w.value===r())??null:null);function oe(w){r(w.value),U(k,""),U(S,!1)}function ze(){M()||(U(S,!i(S)),i(S)||U(k,""))}function H(w){w.stopPropagation(),r(null),U(k,""),U(S,!1)}function te(w){w.target===w.currentTarget&&(w.key==="Enter"||w.key===" ")&&(w.preventDefault(),ze())}function he(w){i(q)&&!i(q).contains(w.target)&&(U(S,!1),U(k,""))}function ne(w){w.key==="Escape"&&(U(S,!1),U(k,""))}kt(()=>{i(S)&&i(Z)&&i(Z).focus()}),kt(()=>{M()&&(U(S,!1),U(k,""))}),Jo(()=>(document.addEventListener("mousedown",he),()=>document.removeEventListener("mousedown",he)));var _e=ys();let ge;var we=v(_e);{var ye=w=>{var E=ds(),C=v(E);L(()=>T(C,a())),g(w,E)};P(we,w=>{n()&&a()&&w(ye)})}var A=_(we,2);let N;var X=v(A);{var re=w=>{var E=cs();Pa(E,C=>U(Z,C),()=>i(Z)),L(()=>pe(E,"placeholder",a())),vt("keydown",E,ne),vt("click",E,C=>C.stopPropagation()),Zo(E,()=>i(k),C=>U(k,C)),g(w,E)},Se=w=>{var E=fs(),C=v(E);{var D=Y=>{var G=vs(),Q=v(G);L(()=>T(Q,a())),g(Y,G)};P(C,Y=>{b()&&Y(D)})}var W=_(C,1,!0);L(()=>T(W,i(K).label)),g(w,E)},Me=w=>{var E=Ma(),C=Ze(E);{var D=W=>{var Y=us();let G;var Q=v(Y);L(()=>{G=Ue(Y,1,"field-text is-placeholder svelte-1dw55dz",null,G,{"force-placeholder":z()}),T(Q,a())}),g(W,Y)};P(C,W=>{m()&&W(D)})}g(w,E)};P(X,w=>{i(S)?w(re):i(K)?w(Se,1):w(Me,!1)})}var Te=_(X,2);{var ie=w=>{var E=ps(),C=v(E);L(()=>{pe(C,"src",ls),pe(C,"width",p()?p():12),pe(C,"height",p()?p():12)}),vt("click",E,H),g(w,E)},fe=w=>{var E=hs();let C;L(()=>{C=Ue(E,1,"icon-chevron svelte-1dw55dz",null,C,{open:i(S)}),pe(E,"src",ti),pe(E,"width",p()?p():12),pe(E,"height",p()?p():12)}),g(w,E)},ue=w=>{var E=_s();L(()=>{pe(E,"src",c()),pe(E,"width",p()),pe(E,"height",p())}),g(w,E)};P(Te,w=>{i(K)&&f()&&!M()?w(ie):i(K)?w(fe,1):w(ue,!1)})}var ke=_(A,2);{var O=w=>{var E=ms(),C=v(E),D=_(v(C)),W=_(C,2);{var Y=G=>{var Q=gs(),xe=v(Q);L(()=>T(xe,l())),g(G,Q)};P(W,G=>{l()&&G(Y)})}L(()=>T(D,` ${i(K).label??""}`)),g(w,E)};P(ke,w=>{i(K)&&u()&&w(O)})}var R=_(ke,2);{var V=w=>{var E=bs();$e(E,21,()=>i(J),C=>C.value,(C,D)=>{var W=ws();let Y;var G=v(W);L(()=>{Y=Ue(W,1,"option svelte-1dw55dz",null,Y,{selected:i(D).value===r()}),pe(W,"aria-selected",i(D).value===r()),T(G,i(D).label)}),vt("click",W,()=>oe(i(D))),g(C,W)},C=>{var D=xs();g(C,D)}),L(()=>pe(E,"id",y)),g(w,E)};P(R,w=>{i(S)&&w(V)})}Pa(_e,w=>U(q,w),()=>i(q)),L(()=>{ge=Ue(_e,1,"autocomplete svelte-1dw55dz",null,ge,{"show-placeholder-mobile":z()}),be(_e,`--field-width: ${d()??""}; --field-height: ${s()??""}`),N=Ue(A,1,"field svelte-1dw55dz",null,N,{open:i(S),"has-value":i(K)&&!i(S),disabled:M()}),pe(A,"tabindex",M()?-1:0),pe(A,"aria-controls",y),pe(A,"aria-expanded",i(S)),pe(A,"aria-disabled",M())}),vt("click",A,ze),vt("keydown",A,te),g(t,_e),Wt()}Wr(["click","keydown"]);const ai="data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M13.5%206.5L19%2012L13.5%2017.5M17.75%2012L4.75%2012'%20stroke='%231C1C1C'%20stroke-width='2'%20stroke-linecap='square'/%3e%3c/svg%3e";var ks=x("<span> </span>");const Cs={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 Et(t,e){ft(t,Cs);let a=B(e,"color",3,"#1C1C1C"),n=B(e,"fontSize",3,"0.6875rem"),o=B(e,"class",3,"");var r=ks(),l=v(r);L(()=>{Ue(r,1,`tag ${o()??""}`,"svelte-pamnib"),be(r,`background-color: ${a()??""}; font-size: ${n()??""}`),T(l,e.label)}),g(t,r)}var Es=x('<p class="candidate-description svelte-q1jzvs"> </p>'),Ts=x('<span class="candidate-stats-percent-suffix svelte-q1jzvs"> </span>'),As=x('<span class="candidate-stats-percent svelte-q1jzvs"> <!></span>'),Ms=x('<span class="candidate-stats-votes svelte-q1jzvs"> </span>'),Ls=x('<div class="candidate-stats svelte-q1jzvs"><!> <!></div>'),Rs=x('<div class="candidate-wrapper svelte-q1jzvs"><!> <div><div class="candidate-name-row svelte-q1jzvs"><span class="candidate-name svelte-q1jzvs"> </span> <!> <!></div> <!></div></div>'),Ps=x('<p class="candidate-description svelte-q1jzvs"> </p>'),Os=x('<span class="candidate-stats-percent-suffix svelte-q1jzvs"> </span>'),Ds=x('<span class="candidate-stats-percent svelte-q1jzvs"> <!></span>'),Is=x('<span class="candidate-stats-votes svelte-q1jzvs"> </span>'),Ns=x('<div class="candidate-stats svelte-q1jzvs"><!> <!></div>'),js=x('<!> <div><div class="candidate-name-row svelte-q1jzvs"><span class="candidate-name svelte-q1jzvs"> </span> <!> <!></div> <!></div>',1),qs=x("<span> </span>"),Fs=x('<div class="candidate svelte-q1jzvs"><!> <!></div>');const Us={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 Bs(t,e){ft(t,Us);let a=B(e,"avatar",3,"man"),n=B(e,"elected",3,!1),o=B(e,"electedLabel",3,"ELEITO"),r=B(e,"electedColor",3,"var(--sevn-color-green)"),l=B(e,"descriptionSide",3,"inline"),d=B(e,"positionSide",3,"right"),s=B(e,"size",3,"md"),c=B(e,"nameWeight",3,700),p=B(e,"descWeight",3,400),b=B(e,"wrapper",3,!1);const u={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"}},m=j(()=>u[s()]??u.md);var z=Fs(),M=v(z);{var f=q=>{var Z=Rs(),J=v(Z);Ct(J,{get name(){return e.name},get photoUrl(){return e.photoUrl},get avatar(){return a()},get avatarColor(){return e.avatarColor},get size(){return s()},get tag(){return e.avatarTag},get tagColor(){return e.avatarTagColor}});var K=_(J,2);let oe;var ze=v(K),H=v(ze),te=v(H),he=_(H,2);{var ne=N=>{{let X=j(()=>e.tagColor??"var(--sevn-color-secondary)"),re=j(()=>e.tagSize??i(m).tagSize);Et(N,{get label(){return e.tag},get color(){return i(X)},get fontSize(){return i(re)}})}};P(he,N=>{e.tag&&N(ne)})}var _e=_(he,2);{var ge=N=>{{let X=j(()=>e.tagSize??i(m).tagSize);Et(N,{get label(){return o()},get color(){return r()},get fontSize(){return i(X)}})}};P(_e,N=>{n()&&N(ge)})}var we=_(ze,2);{var ye=N=>{var X=Es(),re=v(X);L(()=>T(re,e.description)),g(N,X)},A=N=>{var X=Ls(),re=v(X);{var Se=ie=>{var fe=As(),ue=v(fe),ke=_(ue);{var O=R=>{var V=Ts(),w=v(V);L(()=>T(w,e.percentSuffix)),g(R,V)};P(ke,R=>{e.percentSuffix&&R(O)})}L(()=>T(ue,`${e.percent??""} `)),g(ie,fe)};P(re,ie=>{e.percent&&ie(Se)})}var Me=_(re,2);{var Te=ie=>{var fe=Ms(),ue=v(fe);L(()=>T(ue,e.votes)),g(ie,fe)};P(Me,ie=>{e.votes&&ie(Te)})}g(N,X)};P(we,N=>{e.description?N(ye):(e.percent||e.votes)&&N(A,1)})}L(()=>{oe=Ue(K,1,"candidate-info svelte-q1jzvs",null,oe,{right:l()==="right"&&!!e.description}),T(te,e.name)}),g(q,Z)},y=q=>{var Z=js(),J=Ze(Z);Ct(J,{get name(){return e.name},get photoUrl(){return e.photoUrl},get avatar(){return a()},get avatarColor(){return e.avatarColor},get size(){return s()},get tag(){return e.avatarTag},get tagColor(){return e.avatarTagColor}});var K=_(J,2);let oe;var ze=v(K),H=v(ze),te=v(H),he=_(H,2);{var ne=N=>{{let X=j(()=>e.tagColor??"var(--sevn-color-secondary)"),re=j(()=>e.tagSize??i(m).tagSize);Et(N,{get label(){return e.tag},get color(){return i(X)},get fontSize(){return i(re)}})}};P(he,N=>{e.tag&&N(ne)})}var _e=_(he,2);{var ge=N=>{{let X=j(()=>e.tagSize??i(m).tagSize);Et(N,{get label(){return o()},get color(){return r()},get fontSize(){return i(X)}})}};P(_e,N=>{n()&&N(ge)})}var we=_(ze,2);{var ye=N=>{var X=Ps(),re=v(X);L(()=>T(re,e.description)),g(N,X)},A=N=>{var X=Ns(),re=v(X);{var Se=ie=>{var fe=Ds(),ue=v(fe),ke=_(ue);{var O=R=>{var V=Os(),w=v(V);L(()=>T(w,e.percentSuffix)),g(R,V)};P(ke,R=>{e.percentSuffix&&R(O)})}L(()=>T(ue,`${e.percent??""} `)),g(ie,fe)};P(re,ie=>{e.percent&&ie(Se)})}var Me=_(re,2);{var Te=ie=>{var fe=Is(),ue=v(fe);L(()=>T(ue,e.votes)),g(ie,fe)};P(Me,ie=>{e.votes&&ie(Te)})}g(N,X)};P(we,N=>{e.description?N(ye):(e.percent||e.votes)&&N(A,1)})}L(()=>{oe=Ue(K,1,"candidate-info svelte-q1jzvs",null,oe,{right:l()==="right"&&!!e.description}),T(te,e.name)}),g(q,Z)};P(M,q=>{b()?q(f):q(y,!1)})}var S=_(M,2);{var k=q=>{var Z=qs();let J;var K=v(Z);L(()=>{J=Ue(Z,1,"candidate-position svelte-q1jzvs",null,J,{left:d()==="left"}),T(K,e.position)}),g(q,Z)};P(S,q=>{e.position&&q(k)})}L(()=>be(z,`
|
|
45
|
+
--font-name: ${e.fontSize??i(m).fontSize??""};
|
|
46
|
+
--font-desc: ${e.descSize??i(m).descSize??""};
|
|
47
|
+
--font-tag: ${e.tagSize??i(m).tagSize??""};
|
|
48
|
+
--font-position: ${e.positionSize??i(m).fontSize??""};
|
|
49
|
+
--weight-name: ${c()??""};
|
|
50
|
+
--weight-desc: ${p()??""};
|
|
51
|
+
gap: ${b()?"10px":"18px"};
|
|
52
|
+
`)),g(t,z)}var Hs=x("<span> </span>"),Vs=x('<div class="vote-overview-stats svelte-1m9ufac"></div>'),Gs=x("<span> </span>"),Ws=x('<span class="vote-overview-sep svelte-1m9ufac">|</span>'),Ks=x("<span> </span>"),Ys=x('<div class="vote-overview-meta svelte-1m9ufac"><!> <!> <!></div>'),Zs=x('<div class="vote-overview svelte-1m9ufac"><!> <!></div>');const Xs={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 ni(t,e){Gt(e,!0),ft(t,Xs);let a=B(e,"data",19,()=>[]),n=B(e,"borderTop",3,!1),o=B(e,"align",3,"start");var r=Zs(),l=v(r);{var d=p=>{var b=Vs();$e(b,21,a,st,(u,m)=>{var z=Hs(),M=v(z);L(()=>T(M,`${i(m).text??""} ${i(m).value??""}`)),g(u,z)}),g(p,b)};P(l,p=>{a().length&&p(d)})}var s=_(l,2);{var c=p=>{var b=Ys(),u=v(b);{var m=S=>{var k=Gs(),q=v(k);L(()=>T(q,`Atualizado em ${e.date??""}`)),g(S,k)};P(u,S=>{e.date&&S(m)})}var z=_(u,2);{var M=S=>{var k=Ws();g(S,k)};P(z,S=>{e.date&&e.font&&S(M)})}var f=_(z,2);{var y=S=>{var k=Ks(),q=v(k);L(()=>T(q,`Fonte ${e.font??""}`)),g(S,k)};P(f,S=>{e.font&&S(y)})}g(p,b)};P(s,p=>{(e.date||e.font)&&p(c)})}L(()=>be(r,`justify-content:${o()==="end"?"flex-end":"flex-start"};${n()?"border-top:1px solid var(--sevn-color-neutral)":""}`)),g(t,r),Wt()}function Js(t,e){return`${typeof t=="number"&&Number.isFinite(t)&&t>0?t:e+1}º lugar`}var Qs=x('<div class="bar-seg svelte-10dw06o"></div>'),$s=x('<div class="candidate-percentage-layout duel svelte-10dw06o"><div class="duel-candidates svelte-10dw06o"><!> <div class="duel-center svelte-10dw06o"><div class="duel-infos-row svelte-10dw06o"><div class="duel-info svelte-10dw06o"><span class="name svelte-10dw06o"> <span class="acronym svelte-10dw06o"> </span></span> <span class="percent svelte-10dw06o"> </span> <span class="votes svelte-10dw06o"> </span></div> <div class="duel-info right svelte-10dw06o"><span class="name svelte-10dw06o"> <span class="acronym svelte-10dw06o"> </span></span> <span class="percent svelte-10dw06o"> </span> <span class="votes svelte-10dw06o"> </span></div></div> <div class="bar-dual svelte-10dw06o"></div> <!></div> <!></div></div>'),el=x('<span class="divisor svelte-10dw06o" style="margin-left: 5px;">|</span>'),tl=x('<span class="name svelte-10dw06o"><span class="acronym svelte-10dw06o"> </span> </span> <span class="percent svelte-10dw06o"> </span> <span class="votes svelte-10dw06o"> </span>',1),al=x('<span class="votes svelte-10dw06o"> </span> <span class="percent svelte-10dw06o"> </span> <span class="name svelte-10dw06o"><span class="divisor svelte-10dw06o" style="margin-right: 5px;">|</span> <span class="acronym svelte-10dw06o"> </span> </span>',1),nl=x('<div class="bar-seg svelte-10dw06o"></div>'),rl=x('<div class="bar-dual svelte-10dw06o"></div>'),il=x('<div class="bar-seg svelte-10dw06o"></div>'),ol=x('<div class="bar-dual svelte-10dw06o"></div>'),sl=x('<div class="candidate-percentage-layout duel-compact svelte-10dw06o"><div class="duel-compact-candidates svelte-10dw06o"><!> <div class="duel-compact-info-wrapper svelte-10dw06o"><div class="duel-compact-info-row svelte-10dw06o"><div class="duel-compact-info svelte-10dw06o"><!> <span class="name svelte-10dw06o"> <span class="acronym svelte-10dw06o"> </span> <!></span> <span class="percent svelte-10dw06o"> </span> <span class="votes svelte-10dw06o"> </span></div> <div class="duel-compact-info right svelte-10dw06o"><!> <!></div></div> <!></div> <!></div> <!> <!></div>'),ll=x('<p class="meta svelte-10dw06o"><!><!></p>'),dl=x('<div class="stack-item svelte-10dw06o"><div class="stack-header svelte-10dw06o"><!> <div class="stack-info svelte-10dw06o"><!> <span class="name svelte-10dw06o"> <span class="acronym svelte-10dw06o"> </span></span> <span class="percent svelte-10dw06o"> <span class="percent-label svelte-10dw06o">dos votos válidos</span></span> <div class="bar-track svelte-10dw06o"><div class="bar-fill svelte-10dw06o"></div></div> <span class="votes stack-votes svelte-10dw06o"> </span> <!></div></div></div>'),cl=x('<div class="candidate-percentage-layout stack svelte-10dw06o"></div>'),vl=x('<span class="compact-stat svelte-10dw06o"><span class="compact-stat-text svelte-10dw06o"> </span> <span class="compact-stat-text svelte-10dw06o"> </span></span>'),fl=x('<div class="compact-bottom svelte-10dw06o"><div class="bar-track compact-bar svelte-10dw06o"><div class="bar-fill svelte-10dw06o"></div></div> <div class="compact-stats svelte-10dw06o"></div></div>'),ul=x('<span class="compact-stat svelte-10dw06o"><span class="compact-stat-text svelte-10dw06o"> </span> <span class="compact-stat-text svelte-10dw06o"> </span></span>'),pl=x('<div class="compact-bottom svelte-10dw06o"><div class="bar-track compact-bar svelte-10dw06o"><div class="bar-fill svelte-10dw06o"></div></div> <div class="compact-stats svelte-10dw06o"></div></div>'),hl=x("<span> </span>"),_l=x('<span class="compact-sep svelte-10dw06o">|</span>'),gl=x("<span> </span>"),ml=x('<div class="compact-meta svelte-10dw06o"><!> <!> <!></div>'),wl=x('<div class="compact-row svelte-10dw06o"><!> <div class="compact-content svelte-10dw06o"><div class="compact-top svelte-10dw06o"><span class="name svelte-10dw06o"> <span class="acronym svelte-10dw06o"> </span> <span class="divisor svelte-10dw06o">|</span></span> <span class="percent compact-percent svelte-10dw06o"> </span> <span class="votes compact-votes svelte-10dw06o"> </span></div> <!></div></div> <!> <!>',1),xl=x('<p class="meta svelte-10dw06o"><!><!></p>'),bl=x('<div class="compact-row svelte-10dw06o"><div class="compact-left svelte-10dw06o"><!> <span class="name svelte-10dw06o"> <span class="acronym svelte-10dw06o"> </span></span> <span class="percent svelte-10dw06o"> </span> <span class="votes svelte-10dw06o"> </span></div></div> <div class="bar-track svelte-10dw06o"><div class="bar-fill svelte-10dw06o"></div></div> <!>',1),yl=x('<div class="candidate-percentage-layout compact svelte-10dw06o"><!></div>');const zl={hash:"svelte-10dw06o",code:`.candidate-percentage-layout.svelte-10dw06o {display:flex;flex-direction:column;gap:10px;}
|
|
53
|
+
|
|
54
|
+
/* ─── DUEL ──────────────────────────────── */.duel-candidates.svelte-10dw06o {display:flex;align-items:flex-start;gap:14px;}.duel-center.svelte-10dw06o {flex:1;display:flex;flex-direction:column;gap:10px;min-width:0;}.duel-center.svelte-10dw06o .vote-overview {padding:10px 0;}.duel-infos-row.svelte-10dw06o {display:flex;justify-content:space-between;align-items:flex-start;gap:16px;}.duel-info.svelte-10dw06o {display:flex;flex-direction:column;gap:2px;}.duel-info.right.svelte-10dw06o {text-align:right;}
|
|
55
|
+
|
|
56
|
+
/* ─── STACK ─────────────────────────────── */.stack.svelte-10dw06o {gap:24px;}.stack-item.svelte-10dw06o {display:flex;flex-direction:column;gap:8px;}.stack-header.svelte-10dw06o {display:flex;align-items:center;gap:14px;padding-bottom:12px; /* espaço para a tag do avatar */}.stack-info.svelte-10dw06o {display:flex;flex-direction:column;align-items:flex-start;gap:2px;}.stack-info.svelte-10dw06o .position-tag {margin-bottom:6px;}.stack-votes.svelte-10dw06o {margin-top:5px;margin-bottom:5px;}.percent-label.svelte-10dw06o {font-size:0.75em;font-weight:400;opacity:0.65;}
|
|
57
|
+
|
|
58
|
+
/* ─── DUEL-COMPACT ─────────────────────── */.duel-compact-candidates.svelte-10dw06o {display:flex;align-items:center;gap:10px;}.duel-compact-info-wrapper.svelte-10dw06o {flex:1;display:flex;flex-direction:column;gap:8px;min-width:0;}.duel-compact-info-row.svelte-10dw06o {display:flex;justify-content:space-between;align-items:center;gap:8px;}.duel-compact-info.svelte-10dw06o {display:flex;min-width:0;}.duel-compact-info.right.svelte-10dw06o {text-align:right;}.duel-compact-info.svelte-10dw06o .position-tag {align-self:flex-start;margin-bottom:4px;}.duel-compact-info.right.svelte-10dw06o .position-tag {align-self:flex-end;}.duel-compact.svelte-10dw06o .vote-overview {padding:10px 0;}
|
|
59
|
+
|
|
60
|
+
/* ─── COMPACT WITH OVERVIEW ────────────── */.compact-row.svelte-10dw06o {display:flex;align-items:center;gap:10px;border-bottom:1px solid var(--sevn-color-neutral);padding-bottom:15px;}.compact-content.svelte-10dw06o {flex:1;display:flex;flex-direction:column;min-width:0;}.compact-top.svelte-10dw06o {display:flex;align-items:baseline;gap:8px;}.compact-bottom.svelte-10dw06o {display:flex;align-items:center;gap:12px;}.compact-bar.svelte-10dw06o {flex:1;min-width:60px;width:auto;}.compact-stats.svelte-10dw06o {display:flex;align-items:center;gap:14px;flex-shrink:0;}.compact-stat.svelte-10dw06o {display:flex;align-items:center;gap:4px;font-size:0.75rem;color:var(--sevn-color-tertiary);}.compact-stat-text.svelte-10dw06o {opacity:50%;font-weight:600;}.compact-meta.svelte-10dw06o {display:none;}
|
|
61
|
+
|
|
62
|
+
/* ─── COMPACT ───────────────────────────── */.compact-row.svelte-10dw06o {display:flex;align-items:center;justify-content:space-between;gap:8px;}.compact-left.svelte-10dw06o {display:flex;align-items:center;gap:8px;min-width:0;}
|
|
63
|
+
|
|
64
|
+
/* ─── BARRAS ────────────────────────────── */.bar-dual.svelte-10dw06o {position:relative;height:var(--bar-height);border-radius:999px;overflow:hidden;background-color:#e0e0e0;}.bar-seg.svelte-10dw06o {position:absolute;top:0;left:0;height:100%;border-radius:999px;}.bar-track.svelte-10dw06o {width:100%;height:var(--bar-height);background-color:#e0e0e0;border-radius:999px;overflow:hidden;margin-top:5px;}.bar-fill.svelte-10dw06o {height:100%;border-radius:999px;}
|
|
65
|
+
|
|
66
|
+
/* ─── TIPOGRAFIA ────────────────────────── */.name.svelte-10dw06o {font-size:var(--name-size);color:var(--sevn-color-tertiary);line-height:1.3;white-space:nowrap;}.acronym.svelte-10dw06o {font-size:var(--name-size);font-weight:400;opacity:0.55;margin-left:4px;}.divisor.svelte-10dw06o {opacity:0.2;}.percent.svelte-10dw06o {font-size:var(--percent-size);font-weight:700;color:var(--sevn-color-tertiary);line-height:1.1;white-space:nowrap;}.votes.svelte-10dw06o {font-size:var(--votes-size);color:var(--sevn-color-tertiary);font-weight:600;opacity:0.65;white-space:nowrap;opacity:50%;}
|
|
67
|
+
|
|
68
|
+
/* ─── META ──────────────────────────────── */.meta.svelte-10dw06o {font-size:0.72rem;color:var(--sevn-color-tertiary);opacity:0.55;}
|
|
69
|
+
|
|
70
|
+
/* ─── RESPONSIVO MOBILE ─────────────────── */
|
|
71
|
+
@media (max-width: 480px) {
|
|
72
|
+
/* ── duel ── */.duel-candidates.svelte-10dw06o {gap:8px;}.duel-info.svelte-10dw06o {min-width:0;}.name.svelte-10dw06o {white-space:normal;word-break:break-word;}.percent.svelte-10dw06o {font-size:calc(var(--percent-size) * 0.8);}.votes.svelte-10dw06o {white-space:normal;}
|
|
73
|
+
|
|
74
|
+
/* ── duel-compact ── */.duel-compact-candidates.svelte-10dw06o {gap:6px;}.duel-compact-info-wrapper.svelte-10dw06o {gap:6px;}.duel-compact-info.svelte-10dw06o .name:where(.svelte-10dw06o),
|
|
75
|
+
.duel-compact-info.svelte-10dw06o .percent:where(.svelte-10dw06o),
|
|
76
|
+
.duel-compact-info.svelte-10dw06o .votes:where(.svelte-10dw06o) {white-space:normal;word-break:break-word;}.duel-compact.svelte-10dw06o .vote-overview {padding:3px;font-size:0.7rem;gap:8px;}.duel-compact.svelte-10dw06o .vote-overview .vote-overview-stats {gap:8px;}
|
|
77
|
+
|
|
78
|
+
/* ── compact with overview ── */.compact-row.svelte-10dw06o {align-items:flex-start;}.compact-top.svelte-10dw06o {flex-direction:column;align-items:flex-start;gap:2px;}.compact-percent.svelte-10dw06o {font-size:1.15rem;font-weight:800 !important;color:var(--sevn-color-tertiary);line-height:1;}.compact-votes.svelte-10dw06o {font-size:0.675rem;margin-top:2px;}.compact-bottom.svelte-10dw06o {flex-direction:column;align-items:stretch;gap:6px;}.compact-bar.svelte-10dw06o {flex:none;width:100%;height:8px;}.compact-stats.svelte-10dw06o {flex-wrap:wrap;gap:6px 10px;}.compact-meta.svelte-10dw06o {display:flex;align-items:center;gap:0.4rem;font-size:0.75rem;color:var(--sevn-color-tertiary);opacity:0.6;flex-wrap:wrap;opacity:50%;}.compact-sep.svelte-10dw06o {opacity:0.4;}
|
|
79
|
+
}`};function ri(t,e){Gt(e,!0),ft(t,zl);let a=B(e,"layout",3,"duel"),n=B(e,"duelCompactInfoDirection",3,"column"),o=B(e,"overviewAlign",3,"start"),r=B(e,"showPosition",3,!1);const l=(H,te)=>Js(H.position,te),d=H=>e.positionTagColor??H.color,s={duel:{percentSize:"1.75rem",nameSize:"0.875rem",votesSize:"0.75rem",avatarSize:"lg",barHeight:"10px"},"duel-compact":{percentSize:"1rem",nameSize:"0.8rem",votesSize:"0.75rem",avatarSize:"sm",barHeight:"12px"},stack:{percentSize:"1.5rem",nameSize:"0.875rem",votesSize:"0.75rem",avatarSize:"lg",barHeight:"10px"},compact:{percentSize:"0.875rem",nameSize:"0.8rem",votesSize:"0.75rem",avatarSize:"sm",barHeight:"8px"}},c=j(()=>s[a()]??s.duel),p=j(()=>e.percentSize??i(c).percentSize),b=j(()=>e.nameSize??i(c).nameSize),u=j(()=>e.votesSize??i(c).votesSize),m=j(()=>e.avatarSize??i(c).avatarSize),z=j(()=>e.barHeight??i(c).barHeight),M=j(()=>!!e.overviewData?.length),f=j(()=>!!e.date||!!e.font);let y=me(Zt(Ft?window.innerWidth<=480:!1));kt(()=>{if(!Ft)return;const H=window.matchMedia("(max-width: 480px)");U(y,H.matches,!0);const te=he=>{U(y,he.matches,!0)};return H.addEventListener("change",te),()=>H.removeEventListener("change",te)});function S(H){return H.toLocaleString("pt-BR")}function k(H){return H.toLocaleString("pt-BR",{minimumFractionDigits:2,maximumFractionDigits:2})+"%"}var q=Ma(),Z=Ze(q);{var J=H=>{var te=$s(),he=v(te),ne=v(he);{let G=j(()=>e.candidates[0].avatar??"man");Ct(ne,{get name(){return e.candidates[0].name},get photoUrl(){return e.candidates[0].photoUrl},get avatar(){return i(G)},get avatarColor(){return e.candidates[0].color},get size(){return i(m)},get tag(){return e.candidates[0].avatarTag},get tagColor(){return e.candidates[0].avatarTagColor}})}var _e=_(ne,2),ge=v(_e),we=v(ge),ye=v(we),A=v(ye),N=_(A),X=v(N),re=_(ye,2),Se=v(re),Me=_(re,2),Te=v(Me),ie=_(we,2),fe=v(ie),ue=v(fe),ke=_(ue),O=v(ke),R=_(fe,2),V=v(R),w=_(R,2),E=v(w),C=_(ge,2);$e(C,21,()=>e.candidates,st,(G,Q,xe)=>{var Le=Qs();L(()=>be(Le,`width:calc(${i(Q).percent??""}% - 2px);${xe===0?"left:0;":"left:auto;right:0;"}background-color:${i(Q).color??""};`)),g(G,Le)});var D=_(C,2);{var W=G=>{ni(G,{get data(){return e.overviewData},get date(){return e.date},get font(){return e.font},get align(){return o()}})};P(D,G=>{(i(M)||i(f))&&G(W)})}var Y=_(_e,2);{let G=j(()=>e.candidates[1].avatar??"man");Ct(Y,{get name(){return e.candidates[1].name},get photoUrl(){return e.candidates[1].photoUrl},get avatar(){return i(G)},get avatarColor(){return e.candidates[1].color},get size(){return i(m)},get tag(){return e.candidates[1].avatarTag},get tagColor(){return e.candidates[1].avatarTagColor}})}L((G,Q,xe,Le)=>{be(te,`--percent-size:${i(p)??""};--name-size:${i(b)??""};--votes-size:${i(u)??""};--bar-height:${i(z)??""};`),T(A,`${e.candidates[0].name??""} `),T(X,e.candidates[0].acronym),T(Se,G),T(Te,`${Q??""} votos`),T(ue,`${e.candidates[1].name??""} `),T(O,e.candidates[1].acronym),T(V,xe),T(E,`${Le??""} votos`)},[()=>k(e.candidates[0].percent),()=>S(e.candidates[0].votes),()=>k(e.candidates[1].percent),()=>S(e.candidates[1].votes)]),g(H,te)},K=H=>{var te=sl(),he=v(te),ne=v(he);{let I=j(()=>e.candidates[0].avatar??"man");Ct(ne,{get name(){return e.candidates[0].name},get photoUrl(){return e.candidates[0].photoUrl},get avatar(){return i(I)},get avatarColor(){return e.candidates[0].color},get size(){return i(m)},get tag(){return e.candidates[0].avatarTag},get tagColor(){return e.candidates[0].avatarTagColor}})}var _e=_(ne,2),ge=v(_e),we=v(ge),ye=v(we);{var A=I=>{{let F=j(()=>l(e.candidates[0],0)),le=j(()=>d(e.candidates[0]));Et(I,{get label(){return i(F)},get color(){return i(le)},class:"position-tag"})}};P(ye,I=>{r()&&I(A)})}var N=_(ye,2),X=v(N),re=_(X),Se=v(re),Me=_(re,2);{var Te=I=>{var F=el();g(I,F)};P(Me,I=>{i(y)||I(Te)})}var ie=_(N,2),fe=v(ie),ue=_(ie,2),ke=v(ue),O=_(we,2),R=v(O);{var V=I=>{{let F=j(()=>l(e.candidates[1],1)),le=j(()=>d(e.candidates[1]));Et(I,{get label(){return i(F)},get color(){return i(le)},class:"position-tag"})}};P(R,I=>{r()&&I(V)})}var w=_(R,2);{var E=I=>{var F=tl(),le=Ze(F),Ae=v(le),et=v(Ae),Rt=_(Ae),Qa=_(le,2),$a=v(Qa),Rn=_(Qa,2),Pn=v(Rn);L((On,Dn)=>{T(et,e.candidates[1].acronym),T(Rt,` ${e.candidates[1].name??""}`),T($a,On),T(Pn,`${Dn??""} votos`)},[()=>k(e.candidates[1].percent),()=>S(e.candidates[1].votes)]),g(I,F)},C=I=>{var F=al(),le=Ze(F),Ae=v(le),et=_(le,2),Rt=v(et),Qa=_(et,2),$a=_(v(Qa),2),Rn=v($a),Pn=_($a);L((On,Dn)=>{T(Ae,`${On??""} votos`),T(Rt,Dn),T(Rn,e.candidates[1].acronym),T(Pn,` ${e.candidates[1].name??""}`)},[()=>S(e.candidates[1].votes),()=>k(e.candidates[1].percent)]),g(I,F)};P(w,I=>{i(y)?I(E):I(C,!1)})}var D=_(ge,2);{var W=I=>{var F=rl();$e(F,21,()=>e.candidates,st,(le,Ae,et)=>{var Rt=nl();L(()=>be(Rt,`width:calc(${i(Ae).percent??""}% - 2px);${et===0?"left:0;":"left:auto;right:0;"}background-color:${i(Ae).color??""};`)),g(le,Rt)}),g(I,F)};P(D,I=>{n()==="row"&&I(W)})}var Y=_(_e,2);{let I=j(()=>e.candidates[1].avatar??"man");Ct(Y,{get name(){return e.candidates[1].name},get photoUrl(){return e.candidates[1].photoUrl},get avatar(){return i(I)},get avatarColor(){return e.candidates[1].color},get size(){return i(m)},get tag(){return e.candidates[1].avatarTag},get tagColor(){return e.candidates[1].avatarTagColor}})}var G=_(he,2);{var Q=I=>{var F=ol();$e(F,21,()=>e.candidates,st,(le,Ae,et)=>{var Rt=il();L(()=>be(Rt,`width:calc(${i(Ae).percent??""}% - 2px);${et===0?"left:0;":"left:auto;right:0;"}background-color:${i(Ae).color??""};`)),g(le,Rt)}),g(I,F)};P(G,I=>{n()==="column"&&I(Q)})}var xe=_(G,2);{var Le=I=>{ni(I,{get data(){return e.overviewData},get date(){return e.date},get font(){return e.font},borderTop:!0,get align(){return o()}})};P(xe,I=>{(i(M)||i(f))&&I(Le)})}L((I,F)=>{be(te,`--percent-size:${i(p)??""};--name-size:${i(b)??""};--votes-size:${i(u)??""};--bar-height:${i(z)??""};`),be(we,`flex-direction:${n()??""}; gap: ${n()==="row"?"10px":"2px"}`),T(X,`${e.candidates[0].name??""} `),T(Se,e.candidates[0].acronym),T(fe,I),T(ke,`${F??""} votos`),be(O,`flex-direction:${n()??""}; gap: ${n()==="row"?"10px":"2px"}`)},[()=>k(e.candidates[0].percent),()=>S(e.candidates[0].votes)]),g(H,te)},oe=H=>{var te=cl();$e(te,21,()=>e.candidates,st,(he,ne,_e)=>{var ge=dl(),we=v(ge),ye=v(we);{let E=j(()=>i(ne).avatar??"man");Ct(ye,{get name(){return i(ne).name},get photoUrl(){return i(ne).photoUrl},get avatar(){return i(E)},get avatarColor(){return i(ne).color},get size(){return i(m)},get tag(){return i(ne).avatarTag},get tagColor(){return i(ne).avatarTagColor}})}var A=_(ye,2),N=v(A);{var X=E=>{{let C=j(()=>l(i(ne),_e)),D=j(()=>d(i(ne)));Et(E,{get label(){return i(C)},get color(){return i(D)},class:"position-tag"})}};P(N,E=>{r()&&E(X)})}var re=_(N,2),Se=v(re),Me=_(Se),Te=v(Me),ie=_(re,2),fe=v(ie),ue=_(ie,2),ke=v(ue),O=_(ue,2),R=v(O),V=_(O,2);{var w=E=>{var C=ll(),D=v(C);{var W=Q=>{var xe=Wa();L(()=>T(xe,`Atualizado em ${e.date??""} `)),g(Q,xe)};P(D,Q=>{e.date&&Q(W)})}var Y=_(D);{var G=Q=>{var xe=Wa();L(()=>T(xe,`| Fonte ${e.font??""}`)),g(Q,xe)};P(Y,Q=>{e.font&&Q(G)})}g(E,C)};P(V,E=>{_e===e.candidates.length-1&&i(f)&&E(w)})}L((E,C)=>{T(Se,`${i(ne).name??""} `),T(Te,i(ne).acronym),T(fe,`${E??""} `),be(ke,`width:${i(ne).percent??""}%;background-color:${i(ne).color??""};`),T(R,`${C??""} votos`)},[()=>k(i(ne).percent),()=>S(i(ne).votes)]),g(he,ge)}),L(()=>be(te,`--percent-size:${i(p)??""};--name-size:${i(b)??""};--votes-size:${i(u)??""};--bar-height:${i(z)??""};`)),g(H,te)},ze=H=>{var te=yl(),he=v(te);{var ne=ge=>{var we=wl(),ye=Ze(we),A=v(ye);{let D=j(()=>e.candidates[0].avatar??"man");Ct(A,{get name(){return e.candidates[0].name},get photoUrl(){return e.candidates[0].photoUrl},get avatar(){return i(D)},get avatarColor(){return e.candidates[0].color},get size(){return i(m)},get tag(){return e.candidates[0].avatarTag},get tagColor(){return e.candidates[0].avatarTagColor}})}var N=_(A,2),X=v(N),re=v(X),Se=v(re),Me=_(Se),Te=v(Me),ie=_(re,2),fe=v(ie),ue=_(ie,2),ke=v(ue),O=_(X,2);{var R=D=>{var W=fl(),Y=v(W),G=v(Y),Q=_(Y,2);$e(Q,21,()=>e.overviewData,st,(xe,Le)=>{var I=vl(),F=v(I),le=v(F),Ae=_(F,2),et=v(Ae);L(()=>{T(le,i(Le).text),T(et,i(Le).value)}),g(xe,I)}),L(()=>be(G,`width:${e.candidates[0].percent??""}%;background-color:${e.candidates[0].color??""};`)),g(D,W)};P(O,D=>{i(y)||D(R)})}var V=_(ye,2);{var w=D=>{var W=pl(),Y=v(W),G=v(Y),Q=_(Y,2);$e(Q,21,()=>e.overviewData,st,(xe,Le)=>{var I=ul(),F=v(I),le=v(F),Ae=_(F,2),et=v(Ae);L(()=>{T(le,i(Le).text),T(et,i(Le).value)}),g(xe,I)}),L(()=>be(G,`width:${e.candidates[0].percent??""}%;background-color:${e.candidates[0].color??""};`)),g(D,W)};P(V,D=>{i(y)&&D(w)})}var E=_(V,2);{var C=D=>{var W=ml(),Y=v(W);{var G=F=>{var le=hl(),Ae=v(le);L(()=>T(Ae,`Atualizado em ${e.date??""}`)),g(F,le)};P(Y,F=>{e.date&&F(G)})}var Q=_(Y,2);{var xe=F=>{var le=_l();g(F,le)};P(Q,F=>{e.date&&e.font&&F(xe)})}var Le=_(Q,2);{var I=F=>{var le=gl(),Ae=v(le);L(()=>T(Ae,`Fonte ${e.font??""}`)),g(F,le)};P(Le,F=>{e.font&&F(I)})}g(D,W)};P(E,D=>{i(f)&&D(C)})}L((D,W)=>{T(Se,`${e.candidates[0].name??""} `),T(Te,e.candidates[0].acronym),T(fe,D),T(ke,`${W??""} votos`)},[()=>k(e.candidates[0].percent),()=>S(e.candidates[0].votes)]),g(ge,we)},_e=ge=>{var we=bl(),ye=Ze(we),A=v(ye),N=v(A);{let w=j(()=>e.candidates[0].avatar??"man");Ct(N,{get name(){return e.candidates[0].name},get photoUrl(){return e.candidates[0].photoUrl},get avatar(){return i(w)},get avatarColor(){return e.candidates[0].color},get size(){return i(m)},get tag(){return e.candidates[0].avatarTag},get tagColor(){return e.candidates[0].avatarTagColor}})}var X=_(N,2),re=v(X),Se=_(re),Me=v(Se),Te=_(X,2),ie=v(Te),fe=_(Te,2),ue=v(fe),ke=_(ye,2),O=v(ke),R=_(ke,2);{var V=w=>{var E=xl(),C=v(E);{var D=G=>{var Q=Wa();L(()=>T(Q,`Atualizado em ${e.date??""}`)),g(G,Q)};P(C,G=>{e.date&&G(D)})}var W=_(C);{var Y=G=>{var Q=Wa();L(()=>T(Q,`| Fonte ${e.font??""}`)),g(G,Q)};P(W,G=>{e.font&&G(Y)})}g(w,E)};P(R,w=>{i(f)&&w(V)})}L((w,E)=>{T(re,`${e.candidates[0].name??""} `),T(Me,e.candidates[0].acronym),T(ie,w),T(ue,`${E??""} votos`),be(O,`width:${e.candidates[0].percent??""}%;background-color:${e.candidates[0].color??""};`)},[()=>k(e.candidates[0].percent),()=>S(e.candidates[0].votes)]),g(ge,we)};P(he,ge=>{i(M)?ge(ne):ge(_e,!1)})}L(()=>be(te,`--percent-size:${i(p)??""};--name-size:${i(b)??""};--votes-size:${i(u)??""};--bar-height:${i(z)??""};--bar-color:${e.candidates[0].color??""};`)),g(H,te)};P(Z,H=>{a()==="duel"?H(J):a()==="duel-compact"?H(K,1):a()==="stack"?H(oe,2):a()==="compact"&&H(ze,3)})}g(t,q),Wt()}var Sl=x('<span class="header-tag-above svelte-1xm1ks6"><!></span>'),kl=x('<span class="header-tag-inline svelte-1xm1ks6"><!></span>'),Cl=x('<p class="header-description svelte-1xm1ks6"> </p>'),El=x('<header class="header svelte-1xm1ks6"><!> <div class="header-title-row svelte-1xm1ks6"><h1 class="header-title svelte-1xm1ks6"> </h1> <!></div> <!></header>');const Tl={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);}
|
|
80
|
+
|
|
81
|
+
@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);}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
@media (min-width: 768px) {.header-tag-above.svelte-1xm1ks6 {display:none;}.header-tag-inline.svelte-1xm1ks6 {display:inline-flex;}
|
|
85
|
+
}`};function Al(t,e){ft(t,Tl);var a=El(),n=v(a);{var o=u=>{var m=Sl(),z=v(m);Et(z,{get label(){return e.tag},get color(){return e.tagColor}}),g(u,m)};P(n,u=>{e.tag&&u(o)})}var r=_(n,2),l=v(r),d=v(l),s=_(l,2);{var c=u=>{var m=kl(),z=v(m);Et(z,{get label(){return e.tag},get color(){return e.tagColor}}),g(u,m)};P(s,u=>{e.tag&&u(c)})}var p=_(r,2);{var b=u=>{var m=Cl(),z=v(m);L(()=>T(z,e.description)),g(u,m)};P(p,u=>{e.description&&u(b)})}L(()=>{be(a,`
|
|
86
|
+
--header-title-font-size: ${e.titleFontSize??"1.75rem"??""};
|
|
87
|
+
--header-title-font-weight: ${e.titleFontWeight??700??""};
|
|
88
|
+
--header-description-font-size: ${e.descriptionFontSize??"0.875rem"??""};
|
|
89
|
+
`),T(d,e.title)}),g(t,a)}const ii=new Map,Za=new Map;function Ml(t){const e=ii.get(t);if(e!==void 0)return Promise.resolve(e);const a=Za.get(t);if(a)return a;const n=rn(`maps/${t}.svg`),o=fetch(n).then(r=>{if(!r.ok)throw new Error(`Mapa indisponível (HTTP ${r.status}): ${t}`);return r.text()}).then(r=>(ii.set(t,r),Za.delete(t),r)).catch(r=>{throw Za.delete(t),r});return Za.set(t,o),o}let Ll=0;var Rl=x('<img alt="Mapa do Brasil" decoding="async" class="svelte-1956iuh"/>'),Pl=x('<div class="map-placeholder svelte-1956iuh" aria-hidden="true"></div>'),Ol=x('<div class="map-error svelte-1956iuh">Mapa não encontrado</div>'),Dl=x('<p class="map-modal-title svelte-1956iuh"> </p>'),Il=x('<div class="map-modal-item svelte-1956iuh"><!></div>'),Nl=x('<div class="map-modal-footer svelte-1956iuh"> </div>'),jl=x('<div class="map-modal svelte-1956iuh" role="dialog" tabindex="-1"><div class="map-modal-card svelte-1956iuh"><!> <!> <!></div></div>'),ql=x("<div><!> <!> <!></div>");const Fl={hash:"svelte-1956iuh",code:`.map.svelte-1956iuh {display:block;width:100%;}.map.svelte-1956iuh img:where(.svelte-1956iuh),
|
|
90
|
+
.map.svelte-1956iuh svg {width:100%;height:100%;display:block;}
|
|
91
|
+
|
|
92
|
+
/* Default fill for uncolored paths */.map.svelte-1956iuh path {fill:var(--sevn-color-neutral);}
|
|
93
|
+
|
|
94
|
+
/* Pointer cursor and smooth hover on clickable regions */.map.interactive.svelte-1956iuh path[data-cid],
|
|
95
|
+
.map.interactive.svelte-1956iuh g[data-cid],
|
|
96
|
+
.map.interactive.svelte-1956iuh a[data-cid] {cursor:pointer;}.map.interactive.svelte-1956iuh path[data-cid],
|
|
97
|
+
.map.interactive.svelte-1956iuh a[data-cid] path {transition:filter 0.12s ease;}.map.interactive.svelte-1956iuh path[data-cid]:hover,
|
|
98
|
+
.map.interactive.svelte-1956iuh a[data-cid]:hover path {filter:brightness(1.15);}
|
|
99
|
+
|
|
100
|
+
/* State labels: font-size is set as SVG attr (0.8 user units) so it scales with the map.
|
|
101
|
+
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;}
|
|
102
|
+
|
|
103
|
+
/* Floating modal — positioned at the click point inside the map container.
|
|
104
|
+
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;
|
|
105
|
+
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;}
|
|
106
|
+
|
|
107
|
+
@keyframes svelte-1956iuh-pulse {
|
|
108
|
+
0%, 100% { opacity: 1; }
|
|
109
|
+
50% { opacity: 0.4; }
|
|
110
|
+
}`};function oi(t,e){Gt(e,!0),ft(t,Fl);let a=B(e,"aspectRatio",3,"4/3"),n=B(e,"class",3,""),o=B(e,"priority",3,!1),r=B(e,"selectionStrokeWidth",3,3),l=B(e,"toggleSelection",3,!1),d=B(e,"modalTrigger",3,"click");const s=j(()=>d()==="click"||d()==="both"),c=j(()=>d()==="hover"||d()==="both"),p=++Ll,b=rn("maps/brazil-municipalities.svg");let u=j(()=>e.type==="brazil"?`map--brazil-${p}`:e.type==="state"?`map--state-${e.uf??""}-${p}`:`map--muni-${e.uf??""}-${e.municipio??""}-${p}`),m=j(()=>!!e.interactive||!!e.onRegionClick||!!e.onRegionHover||!!e.selectionStroke||!!e.modalData),z=j(()=>e.type==="brazil-states"||e.type!=="brazil"||!!e.colors?.length||!!e.labels||!!e.onRegionClick||!!e.onRegionHover||!!e.selectionStroke||!!e.modalData),M=j(()=>i(z)?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),f=me(null);kt(()=>{e.selected!==void 0&&U(f,e.selected,!0)});let y=me(null),S=me(0),k=me(0),q=me(""),Z=me(!1),J=me(!1),K=j(()=>e.type==="brazil"||e.type==="state"?`.${i(u)} path{stroke:#8a8a92;stroke-width:0.5px;vector-effect:non-scaling-stroke}`:""),oe=j(()=>e.colors?.length?e.colors.map(({id:O,color:R,match:V})=>{const w=V==="endsWith"?`[data-cid$="::${O}"]`:`[data-cid="${O}"]`;return`.${i(u)} path${w},.${i(u)} ${w} path{fill:${R}!important}`}).join(""):""),ze=j(()=>i(f)&&e.selectionStroke?`.${i(u)} [data-cid="${i(f)}"] path{stroke:${e.selectionStroke}!important;stroke-width:${r()}px!important;vector-effect:non-scaling-stroke!important;paint-order:stroke fill!important}`:""),H=j(()=>Ft?i(K)+i(oe)+i(ze):""),te,he=0;kt(()=>{const O=i(M);if(!O){U(q,""),U(Z,!1);return}const R=++he;function V(){U(Z,!0),U(J,!1),U(q,""),Ml(O).then(E=>{R===he&&(U(q,E,!0),U(Z,!1),queueMicrotask(()=>{const C=te?.querySelector("svg");if(!C)return;const D=C.querySelector(".map-labels");if(D){C.appendChild(D);return}C.querySelectorAll("text").forEach(W=>C.appendChild(W))}))}).catch(()=>{R===he&&(U(J,!0),U(Z,!1))})}if(o()){V();return}if(!te){V();return}const w=new IntersectionObserver(([E])=>{E.isIntersecting&&(w.disconnect(),V())},{rootMargin:"200px"});return w.observe(te),()=>w.disconnect()}),kt(()=>{if(!e.modalData)return;function O(R){R.key==="Escape"&&U(y,null)}return window.addEventListener("keydown",O),()=>window.removeEventListener("keydown",O)});let ne=me(null);function _e(O,R){const V=R.getAttribute("data-cid")??"",w=V.split("::"),E=w.length>1?w[1]||void 0:w[0]||void 0,C=w.length>1&&w[0]||void 0;return{cid:V,uf:E,municipio:C,clientX:O.clientX,clientY:O.clientY,element:R}}function ge(O){if(!i(m))return;const R=O.target.closest("[data-cid]");if(!R){d()==="click"&&U(y,null);return}const V=R.getAttribute("data-cid")??"";if(!V)return;U(f,l()&&i(f)===V?null:V,!0);const w=R.closest("svg"),E=R.parentNode;if(w&&E)if(E===w){const D=w.querySelector(":scope > .map-labels")??Array.from(w.children).find(W=>W.nodeName==="text");D?w.insertBefore(R,D):w.appendChild(R)}else E.appendChild(R);const C=_e(O,R);if(e.modalData&&i(s))if(i(y)?.cid===V)U(y,null);else{const D=O.currentTarget.getBoundingClientRect();U(S,O.clientX-D.left),U(k,O.clientY-D.top),U(y,C,!0)}e.onRegionClick?.(C)}function we(O){if(!i(m)||!e.onRegionHover&&!i(c))return;const R=O.target.closest("[data-cid]");if(!R)return;const V=R.getAttribute("data-cid")??"";if(!V||V===i(ne))return;U(ne,V,!0);const w=_e(O,R);if(e.modalData&&i(c)){const E=O.currentTarget.getBoundingClientRect();U(S,O.clientX-E.left),U(k,O.clientY-E.top),U(y,w,!0)}e.onRegionHover?.(w)}function ye(){U(ne,null),i(c)&&U(y,null)}var A=ql();let N;var X=v(A);{var re=O=>{var R=Ma(),V=Ze(R);Xr(V,()=>`<style>${i(H)}</style>`),g(O,R)};P(X,O=>{i(H)&&O(re)})}var Se=_(X,2);{var Me=O=>{var R=Rl();L(()=>{pe(R,"src",b),pe(R,"fetchpriority",o()?"high":"auto"),pe(R,"loading",o()?"eager":"lazy")}),g(O,R)},Te=O=>{var R=Pl();g(O,R)},ie=O=>{var R=Ol();g(O,R)},fe=O=>{var R=Ma(),V=Ze(R);Xr(V,()=>i(q)),g(O,R)};P(Se,O=>{e.type==="brazil"&&!i(q)&&!i(Z)?O(Me):i(Z)?O(Te,1):i(J)?O(ie,2):i(q)&&O(fe,3)})}var ue=_(Se,2);{var ke=O=>{const R=j(()=>e.modalData[i(y).cid]);var V=Ma(),w=Ze(V);{var E=C=>{var D=jl(),W=v(D),Y=v(W);{var G=I=>{var F=Dl(),le=v(F);L(()=>T(le,`${i(R).title??""}:`)),g(I,F)};P(Y,I=>{i(R).title&&I(G)})}var Q=_(Y,2);$e(Q,17,()=>i(R).items,st,(I,F)=>{var le=Il(),Ae=v(le);Bs(Ae,{get name(){return i(F).name},get tag(){return i(F).tag},get tagColor(){return i(F).tagColor},get photoUrl(){return i(F).photoUrl},get avatar(){return i(F).avatar},get avatarColor(){return i(F).avatarColor},get description(){return i(F).description},get descriptionSide(){return i(F).descriptionSide},get position(){return i(F).position},positionSide:"left",size:"sm",wrapper:!0}),g(I,le)});var xe=_(Q,2);{var Le=I=>{var F=Nl(),le=v(F);L(()=>T(le,i(R).footer)),g(I,F)};P(xe,I=>{i(R).footer&&I(Le)})}L(()=>be(D,`left:${i(S)??""}px;top:${i(k)??""}px`)),vt("click",D,I=>I.stopPropagation()),vt("keydown",D,I=>I.stopPropagation()),g(C,D)};P(w,C=>{i(R)&&C(E)})}g(O,V)};P(ue,O=>{e.modalData&&i(y)&&O(ke)})}Pa(A,O=>te=O,()=>te),L(()=>{N=Ue(A,1,`map ${i(u)??""} ${n()??""}`,"svelte-1956iuh",N,{loading:i(Z),error:i(J),interactive:i(m)}),be(A,`aspect-ratio:${a()??""};contain:layout;position:relative`),pe(A,"role",i(m)?"group":void 0)}),vt("click",A,ge),vt("mousemove",A,we),Gr("mouseleave",A,ye),g(t,A),Wt()}Wr(["click","mousemove","keydown"]);var Ul=x('<p class="map-legend-title svelte-p7lxz6"> </p>'),Bl=x("<div></div>"),Hl=x('<span class="map-legend-label svelte-p7lxz6"> </span>'),Vl=x('<div class="map-legend-labels svelte-p7lxz6"></div>'),Gl=x('<span class="map-legend-extreme-label svelte-p7lxz6"><img alt="arrow-start" class="map-legend-arrow map-legend-arrow--start svelte-p7lxz6"/> </span>'),Wl=x("<span></span>"),Kl=x('<span class="map-legend-extreme-label svelte-p7lxz6"> <img alt="arrow-end" class="map-legend-arrow map-legend-arrow--end svelte-p7lxz6"/></span>'),Yl=x('<div class="map-legend-extremes svelte-p7lxz6"><!> <!></div>'),Zl=x('<div><!> <div class="map-legend-bar svelte-p7lxz6"></div> <!></div>');const Xl={hash:"svelte-p7lxz6",code:`.map-legend.svelte-p7lxz6 {width:100%;display:flex;flex-direction:column;gap:4px;font-family:inherit;box-sizing:border-box;}.map-legend-title.svelte-p7lxz6 {margin:0 0 4px;font-size:0.75rem;font-weight:600;color:var(--sevn-color-tertiary);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}.map-legend-bar.svelte-p7lxz6 {display:flex;height:14px;border-radius:3px;min-width:0;}.map-legend-segment.svelte-p7lxz6 {flex:1;min-width:0;}.map-legend-segment.svelte-p7lxz6:first-child {border-radius:3px 0 0 3px;}.map-legend-segment.svelte-p7lxz6:last-child {border-radius:0 3px 3px 0;}.map-legend-segment.svelte-p7lxz6:only-child {border-radius:3px;}.map-legend-segment--hoverable.svelte-p7lxz6 {position:relative;cursor:default;}.map-legend-segment--hoverable.svelte-p7lxz6:hover::after {content:attr(data-tooltip);position:absolute;bottom:calc(100% + 6px);left:50%;transform:translateX(-50%);z-index:2;padding:4px 8px;border-radius:4px;background:var(--sevn-color-tertiary, #1a1a2e);color:#fff;font-size:0.7rem;font-weight:500;line-height:1.2;white-space:nowrap;pointer-events:none;}.map-legend-segment--hoverable.svelte-p7lxz6:hover::before {content:'';position:absolute;bottom:calc(100% + 2px);left:50%;transform:translateX(-50%);z-index:2;border:4px solid transparent;border-top-color:var(--sevn-color-tertiary, #1a1a2e);pointer-events:none;}.map-legend-labels.svelte-p7lxz6 {display:flex;min-width:0;}.map-legend-label.svelte-p7lxz6 {flex:1;font-size:0.65rem;color:var(--sevn-color-tertiary);text-align:left;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}.map-legend-extremes.svelte-p7lxz6 {display:flex;justify-content:space-between;min-width:0;gap:4px;margin-top:10px;}.map-legend-extreme-label.svelte-p7lxz6 {display:inline-flex;align-items:center;gap:3px;font-size:0.70rem;color:var(--sevn-color-tertiary);white-space:nowrap;min-width:0;overflow:hidden;}.map-legend-arrow.svelte-p7lxz6 {width:12px;height:12px;flex-shrink:0;}.map-legend-arrow--start.svelte-p7lxz6 {transform:scaleX(-1);}
|
|
111
|
+
|
|
112
|
+
@media (max-width: 480px) {.map-legend-title.svelte-p7lxz6 {font-size:0.7rem;}.map-legend-bar.svelte-p7lxz6 {height:10px;}.map-legend-label.svelte-p7lxz6,
|
|
113
|
+
.map-legend-extreme-label.svelte-p7lxz6 {font-size:0.6rem;}.map-legend-arrow.svelte-p7lxz6 {width:10px;height:10px;}
|
|
114
|
+
}`};function Jl(t,e){Gt(e,!0),ft(t,Xl);let a=B(e,"sortSegments",3,!1),n=B(e,"class",3,"");const o=M=>M.label??M.tooltip??"";let r=j(()=>a()?[...e.segments].sort((M,f)=>o(M).localeCompare(o(f),"pt-BR")):e.segments),l=j(()=>i(r).some(M=>M.label)),d=j(()=>!!(e.startLabel||e.endLabel));var s=Zl(),c=v(s);{var p=M=>{var f=Ul(),y=v(f);L(()=>T(y,e.title)),g(M,f)};P(c,M=>{e.title&&M(p)})}var b=_(c,2);$e(b,21,()=>i(r),st,(M,f)=>{var y=Bl();let S;L(()=>{S=Ue(y,1,"map-legend-segment svelte-p7lxz6",null,S,{"map-legend-segment--hoverable":i(f).tooltip}),be(y,`background:${i(f).color??""}`),pe(y,"data-tooltip",i(f).tooltip),pe(y,"role",i(f).tooltip?"img":void 0),pe(y,"aria-label",i(f).tooltip)}),g(M,y)});var u=_(b,2);{var m=M=>{var f=Vl();$e(f,21,()=>i(r),st,(y,S)=>{var k=Hl(),q=v(k);L(()=>T(q,i(S).label??"")),g(y,k)}),g(M,f)},z=M=>{var f=Yl(),y=v(f);{var S=J=>{var K=Gl(),oe=v(K),ze=_(oe);L(()=>{pe(oe,"src",ai),T(ze,` ${e.startLabel??""}`)}),g(J,K)},k=J=>{var K=Wl();g(J,K)};P(y,J=>{e.startLabel?J(S):J(k,!1)})}var q=_(y,2);{var Z=J=>{var K=Kl(),oe=v(K),ze=_(oe);L(()=>{T(oe,`${e.endLabel??""} `),pe(ze,"src",ai)}),g(J,K)};P(q,J=>{e.endLabel&&J(Z)})}g(M,f)};P(u,M=>{i(l)?M(m):i(d)&&M(z,1)})}L(()=>Ue(s,1,`map-legend ${n()??""}`,"svelte-p7lxz6")),g(t,s),Wt()}const Ql=new Set(["da","de","do","das","dos","e"]);function Tn(t){return t.toLowerCase().split(" ").map((e,a)=>a>0&&Ql.has(e)?e:e.charAt(0).toUpperCase()+e.slice(1)).join(" ")}function $l(t){if(typeof t=="string"){const a=t.match(/^(\d{4})-(\d{2})-(\d{2})[T ](\d{2}):(\d{2})(?::(\d{2}))?/);if(a)return new Date(Date.UTC(Number(a[1]),Number(a[2])-1,Number(a[3]),Number(a[4]),Number(a[5]),Number(a[6]??0)))}const e=new Date(t);return Number.isNaN(e.getTime())?null:e}function An(t){if(t==null||t==="")return"";const e=$l(t);if(!e)return"";const a=String(e.getUTCDate()).padStart(2,"0"),n=String(e.getUTCMonth()+1).padStart(2,"0"),o=e.getUTCFullYear(),r=String(e.getUTCHours()).padStart(2,"0"),l=String(e.getUTCMinutes()).padStart(2,"0");return`${a}/${n}/${o} às ${r}h${l}`}function ed(t,e="TSE"){const a=An(t);return a?`Atualizado em ${a} | Fonte ${e}`:`Fonte ${e}`}const td=An("2022-10-31T00:18:00Z");ed("2022-10-31T00:18:00Z");var ad=x('<p class="sevn_state_winners__empty-label svelte-15kfon5"> </p>'),nd=x('<span class="sevn_state_winners__overview__dot_item svelte-15kfon5"><span class="sevn_state_winners__overview__dot svelte-15kfon5"></span> </span>'),rd=x('<!> <div class="sevn_state_winners__overview svelte-15kfon5"><span class="sevn_state_winners__overview__label svelte-15kfon5">Visão geral:</span> <div class="sevn_state_winners__overview__dots svelte-15kfon5"></div></div>',1),id=x('<p class="sevn_state_winners__empty-label svelte-15kfon5"> </p>'),od=x('<div class="sevn_state_winners__grid svelte-15kfon5"><div class="sevn_state_winners__candidates svelte-15kfon5"><!></div> <div class="sevn_state_winners__map svelte-15kfon5"><!></div></div> <div class="sevn_state_winners__mobile svelte-15kfon5"><!> <div class="sevn_state_winners__map svelte-15kfon5"><!></div></div> <!>',1),sd=x('<div><!> <div class="sevn_state_winners__search svelte-15kfon5"><!></div> <!></div>');const ld={hash:"svelte-15kfon5",code:`.sevn_state_winners.svelte-15kfon5 {display:flex;flex-direction:column;gap:32px;}
|
|
115
|
+
|
|
116
|
+
/* ── Search ──────────────────────────────── */.sevn_state_winners__search.svelte-15kfon5 {width:100%;}
|
|
117
|
+
|
|
118
|
+
/* ── Grid web ────────────────────────────── */.sevn_state_winners__grid.svelte-15kfon5 {display:grid;grid-template-columns:2fr 3fr;gap:40px;align-items:center;}.sevn_state_winners__candidates.svelte-15kfon5 {display:flex;flex-direction:column;}.sevn_state_winners__empty-label.svelte-15kfon5 {margin:0;font-size:0.875rem;color:var(--sevn-color-text-secondary, #6b7280);}.sevn_state_winners__map.svelte-15kfon5 {width:100%;}
|
|
119
|
+
|
|
120
|
+
/* ── Mobile layout ───────────────────────── */.sevn_state_winners__mobile.svelte-15kfon5 {display:none;flex-direction:column;gap:24px;}.sevn_state_winners__overview.svelte-15kfon5 {display:flex;flex-direction:column;gap:6px;}.sevn_state_winners__overview__label.svelte-15kfon5 {font-size:0.875rem;font-weight:600;color:var(--sevn-color-tertiary);}.sevn_state_winners__overview__dots.svelte-15kfon5 {display:flex;flex-wrap:wrap;gap:12px;}.sevn_state_winners__overview__dot_item.svelte-15kfon5 {display:inline-flex;align-items:center;gap:6px;font-size:0.8125rem;color:var(--sevn-color-tertiary);}.sevn_state_winners__overview__dot.svelte-15kfon5 {width:10px;height:10px;border-radius:50%;flex-shrink:0;}
|
|
121
|
+
|
|
122
|
+
/* ── Responsivo ──────────────────────────── */
|
|
123
|
+
@media (max-width: 767px) {.sevn_state_winners__grid.svelte-15kfon5 {display:none;}.sevn_state_winners__mobile.svelte-15kfon5 {display:flex;}
|
|
124
|
+
|
|
125
|
+
/* Dropdown flui no documento em vez de sobrepor */.sevn_state_winners__search.svelte-15kfon5 .dropdown {position:static;margin-top:10px;}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/* ── Raw (sem estilos) ───────────────────── */.sevn_state_winners--raw.svelte-15kfon5,
|
|
129
|
+
.sevn_state_winners--raw.svelte-15kfon5 :where(.svelte-15kfon5) {all:revert;}`};function dd(t,e){Gt(e,!0),ft(t,ld);let a=B(e,"mock",3,!1),n=B(e,"rawStyle",3,!1),o=B(e,"data",3,null),r=B(e,"header",19,()=>({title:"Quem ganhou em cada estado",description:"Veja o resultado por estado"}));const l=[{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"}],d={nome:"Candidato A",partido:"ABC",cor:"var(--sevn-color-primary)"},s={nome:"Candidato B",partido:"DEF",cor:"var(--sevn-color-secondary)"},c={ac:{estado:"Acre",candidato:s,percent:54.1},al:{estado:"Alagoas",candidato:d,percent:61.3},am:{estado:"Amazonas",candidato:d,percent:52.7},ap:{estado:"Amapá",candidato:d,percent:57.8},ba:{estado:"Bahia",candidato:d,percent:68.2},ce:{estado:"Ceará",candidato:d,percent:66.4},df:{estado:"Distrito Federal",candidato:s,percent:55.9},es:{estado:"Espírito Santo",candidato:s,percent:51.2},go:{estado:"Goiás",candidato:s,percent:58.6},ma:{estado:"Maranhão",candidato:d,percent:63.5},mg:{estado:"Minas Gerais",candidato:d,percent:53.4},ms:{estado:"Mato Grosso do Sul",candidato:s,percent:56.3},mt:{estado:"Mato Grosso",candidato:s,percent:60.1},pa:{estado:"Pará",candidato:d,percent:59.7},pb:{estado:"Paraíba",candidato:d,percent:62},pe:{estado:"Pernambuco",candidato:d,percent:64.8},pi:{estado:"Piauí",candidato:d,percent:65.3},pr:{estado:"Paraná",candidato:s,percent:57.4},rj:{estado:"Rio de Janeiro",candidato:s,percent:50.8},rn:{estado:"Rio Grande do Norte",candidato:d,percent:60.2},ro:{estado:"Rondônia",candidato:s,percent:62.5},rr:{estado:"Roraima",candidato:s,percent:58},rs:{estado:"Rio Grande do Sul",candidato:s,percent:53.6},sc:{estado:"Santa Catarina",candidato:s,percent:67.1},se:{estado:"Sergipe",candidato:d,percent:58.9},sp:{estado:"São Paulo",candidato:d,percent:54.1},to:{estado:"Tocantins",candidato:s,percent:51.7}},p=j(()=>a()?c:!o()?.states||!Array.isArray(o().states)?{}:Object.fromEntries(o().states.filter(A=>A.leader?.party_color).map(A=>[A.state.toLowerCase(),{estado:A.state_name,candidato:{nome:Tn(A.leader.name),partido:A.leader.party_abbr,cor:A.leader.party_color},percent:A.leader.valid_votes_pct}]))),b=j(()=>Object.entries(i(p)).map(([A,N])=>({id:A,color:N.candidato.cor}))),u=j(()=>Object.entries(i(p)).map(([A,N])=>({value:A,label:`${N.estado} ${A.toUpperCase()}`})).sort((A,N)=>A.label.localeCompare(N.label))),m=j(()=>a()?i(u):l),z=[{name:"Candidato A",acronym:"ABC",percent:50.9,votes:60345999,color:"var(--sevn-color-primary)",avatar:"man",avatarTag:"ELEITO",avatarTagColor:"var(--sevn-color-green)"},{name:"Candidato B",acronym:"DEF",percent:49.1,votes:58206354,color:"var(--sevn-color-secondary)",avatar:"man"}],M=[{text:"Nulos",value:"3,16%"},{text:"Brancos",value:"1,43%"},{text:"Válidos",value:"118.552.353 votos"}];let f=me(null),y=me(void 0),S=me(!1);kt(()=>{const A=()=>{U(S,window.innerWidth<768)};return A(),window.addEventListener("resize",A),()=>window.removeEventListener("resize",A)}),kt(()=>{i(f)&&i(y)&&i(S)&&i(y).scrollIntoView({behavior:"smooth",block:"start"})});const k=j(()=>i(f)&&o()?.states&&Array.isArray(o().states)?o().states.find(A=>A.state.toLowerCase()===i(f)):null),q=j(()=>i(f)?a()?z:!i(k)?.leader||!i(k)?.runner_up?[]:[{name:Tn(i(k).leader.name),acronym:i(k).leader.party_abbr,percent:i(k).leader.valid_votes_pct,votes:i(k).leader.votes,color:i(k).leader.party_color,photoUrl:i(k).leader.photo_url,avatar:"man",avatarTag:i(k).leader.elected?"ELEITO":void 0,avatarTagColor:i(k).leader.elected?"var(--sevn-color-green)":void 0},{name:Tn(i(k).runner_up.name),acronym:i(k).runner_up.party_abbr,percent:i(k).runner_up.valid_votes_pct,votes:i(k).runner_up.votes,color:i(k).runner_up.party_color,photoUrl:i(k).runner_up.photo_url,avatar:"man",avatarTag:i(k).runner_up.elected?"ELEITO":void 0,avatarTagColor:i(k).runner_up.elected?"var(--sevn-color-green)":void 0}]:[]),Z=j(()=>i(q).length>0),J=j(()=>a()?td:An(o()?.last_updated)),K=j(()=>i(f)?a()?M:i(k)?[{text:"Status",value:i(k).status},{text:"Urnas contadas",value:`${i(k).ballots_counted_pct}%`}]:[]:[]),oe=[{color:"#4a0e0e",tooltip:"ABC"},{color:"#8b1a1a",tooltip:"DEF"},{color:"#c0392b",tooltip:"GHI"},{color:"#e74c3c",tooltip:"JKL"},{color:"#f1948a",tooltip:"MNO"},{color:"#fadbd8",tooltip:"PQR"},{color:"#d6e4f0",tooltip:"STU"},{color:"#a9cce3",tooltip:"VWX"},{color:"#5dade2",tooltip:"YZA"},{color:"#2e86c1",tooltip:"BCD"},{color:"#1a5276",tooltip:"EFG"},{color:"#0d2137",tooltip:"HIJ"},{color:"#b7950b",tooltip:"KLM"},{color:"#9a7d0a",tooltip:"NOP"},{color:"#7d6608",tooltip:"QRS"}],ze=j(()=>a()?oe:!o()?.states||!Array.isArray(o().states)?[]:Array.from(new globalThis.Map(o().states.flatMap(A=>[A.leader,A.runner_up]).filter(A=>A?.party_abbr&&A?.party_color).map(A=>[A.party_abbr,{color:A.party_color,tooltip:A.party_abbr}])).values()));function H(A){const N=A.cid;U(f,i(f)===N?null:N,!0)}var te=sd();let he;var ne=v(te);Al(ne,{get title(){return r().title},get description(){return r().description},get tag(){return r().tag},get tagColor(){return r().tagColor}});var _e=_(ne,2),ge=v(_e);Ss(ge,{label:"Busque por estado",get options(){return i(m)},get icon(){return ti},iconSize:13,get value(){return i(f)},set value(A){U(f,A,!0)}});var we=_(_e,2);{var ye=A=>{var N=od(),X=Ze(N),re=v(X),Se=v(re);{var Me=C=>{ri(C,{layout:"stack",get candidates(){return i(q)},get overviewData(){return i(K)},avatarSize:"133px",barHeight:"24px",get date(){return i(J)},font:"TSE"})},Te=C=>{var D=ad(),W=v(D);L(Y=>T(W,`Resultado ainda não publicado para ${Y??""}.`),[()=>l.find(Y=>Y.value===i(f))?.label??i(f)?.toUpperCase()]),g(C,D)};P(Se,C=>{i(Z)?C(Me):C(Te,!1)})}var ie=_(re,2),fe=v(ie);oi(fe,{type:"brazil-states",get colors(){return i(b)},interactive:!0,onRegionClick:H}),Pa(ie,C=>U(y,C),()=>i(y));var ue=_(X,2),ke=v(ue);{var O=C=>{var D=rd(),W=Ze(D);ri(W,{layout:"duel-compact",get candidates(){return i(q)},get overviewData(){return i(K)},get date(){return i(J)},font:"TSE"});var Y=_(W,2),G=_(v(Y),2);$e(G,21,()=>i(q),st,(Q,xe)=>{var Le=nd(),I=v(Le),F=_(I);L(()=>{be(I,`background:${i(xe).color??""}`),T(F,` ${i(xe).name??""} | ${i(xe).acronym??""}`)}),g(Q,Le)}),g(C,D)},R=C=>{var D=id(),W=v(D);L(Y=>T(W,`Resultado ainda não publicado para ${Y??""}.`),[()=>l.find(Y=>Y.value===i(f))?.label??i(f)?.toUpperCase()]),g(C,D)};P(ke,C=>{i(Z)?C(O):C(R,!1)})}var V=_(ke,2),w=v(V);oi(w,{type:"brazil-states",get colors(){return i(b)}}),Pa(V,C=>U(y,C),()=>i(y));var E=_(ue,2);Jl(E,{title:"Partidos",get segments(){return i(ze)},sortSegments:!0}),g(A,N)};P(we,A=>{i(f)&&A(ye)})}L(()=>he=Ue(te,1,"sevn_state_winners svelte-15kfon5",null,he,{"sevn_state_winners--raw":n()})),g(t,te),Wt()}const si=Qo(dd,"StateWinners");return typeof window<"u"&&(window.SevnElections=Object.assign(window.SevnElections||{},{Core:wi,StateWinners:si}),es()),si}));
|