@htmlbricks/hb-navbar 0.71.35 → 0.71.36

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/README.md CHANGED
@@ -1,36 +1,170 @@
1
- # hb-navbar
1
+ # `hb-navbar` — integrator guide
2
2
 
3
- ## Description
3
+ **Category:** layout · **Tags:** layout, navigation · **Package:** `@htmlbricks/hb-navbar`
4
4
 
5
- Top navigation bar with optional hamburger to toggle an offcanvas menu, brand name and logo, slottable left, center, and right areas, and an optional user avatar dropdown (hb-dropdown-simple) with item click events.
5
+ ## Summary
6
6
 
7
- ## Types
7
+ `hb-navbar` is a top **navigation bar** built with Bulma layout (`level`, mobile helpers). It provides an optional **menu toggle** (hamburger) that flips an internal open flag and emits `navmenuswitch`, a **brand** area (default: logo + text, or fully replaced via slot), **three projection regions** (left, center, right slots), an optional **`nav-switcher`** slot to replace the default toggle label, and an optional **user avatar menu** backed by **`hb-dropdown-simple`** (declared dependency in `extra/docs.ts`).
8
8
 
9
- ```typescript
9
+ ## Behavior
10
+
11
+ - **Menu toggle:** A `<button>` is shown unless the `noburger` attribute is present with a **non-empty** string (use **`noburger="yes"`** to hide the control; avoid values like `"no"` if you want the button to remain visible, because any non-empty string hides it in the current `{#if !noburger}` logic). The button calls `switchMenu()` on click, toggling `isOpen` and dispatching **`navmenuswitch`** with `{ isOpen }`. Default content is the character `☰`; override with the **`nav-switcher`** slot.
12
+ - **`switchopen`:** String **`"yes"`** or **`"no"`**. On bind/update, the component syncs internal `isOpen` (`"yes"` → open). Omit or use **`"no"`** for a closed starting point (see implementation in `component.wc.svelte`).
13
+ - **Brand:** Default slot **`brand`** shows `companylogouri` as an `<img>` when non-empty, then `companybrandname`. Replace the whole block with **`slot="brand"`** content when you need custom markup.
14
+ - **User menu:** When `usermenu` is provided, `hb-dropdown-simple` is registered via `addComponent` and rendered with `list={JSON.stringify(usermenu.list)}` and the avatar from `imgUri`. Dropdown item selection is forwarded as **`navbarDropDownClick`** with `{ key }` (same shape as `hb-dropdown-simple` item keys).
15
+ - **`usermenu` parsing:** From HTML, pass **`usermenu` as a JSON string** (see Attributes). If the value is a string at runtime, the component attempts `JSON.parse`; parse errors are logged to the console.
16
+ - **`navbarSlotClick`:** Dispatched when the user **clicks** or presses **Enter** on the interactive wrappers around the **left** slot region and the **center / brand** region. The authoring types allow `side: "right"`; in the current markup, only **left** and **center** paths call `dispatch("navbarSlotClick", …)`.
17
+ - **Internationalization:** none (`extra/docs.ts` lists no `i18n` entries).
18
+
19
+ ## Custom element tag
20
+
21
+ ```html
22
+ <hb-navbar …></hb-navbar>
23
+ ```
24
+
25
+ ## Attributes (HTML / reflected props)
26
+
27
+ Attribute names are **snake_case**; values exposed from HTML are **strings** (booleans as **`yes`** / **`no`**, objects as **JSON**), per project conventions.
28
+
29
+ | Attribute | Required | Role |
30
+ |-----------|----------|------|
31
+ | `id` | No | Optional host id. |
32
+ | `style` | No | Optional inline style on the host (per typings). |
33
+ | `companybrandname` | Yes | Brand text shown in the default brand area. |
34
+ | `companylogouri` | Yes | Logo URL for the default brand `<img>`; use an empty string if you only want text or a custom `brand` slot. |
35
+ | `switchopen` | No | **`"yes"`** / **`"no"`** — aligns internal menu-open state with this value. |
36
+ | `usermenu` | No | JSON string: `{ "imgUri": string, "list"?: Array<{ "key": string, "label": string, "badge"?: number, "group"?: string }> }` for the avatar dropdown. |
37
+ | `noburger` | No | Set to **`yes`** to hide the hamburger / menu button entirely. |
38
+
39
+ ## Events
40
+
41
+ Listen with `addEventListener` or framework bindings on the host element.
42
+
43
+ | Event | `detail` |
44
+ |-------|----------|
45
+ | `navmenuswitch` | `{ isOpen: boolean }` |
46
+ | `navbarDropDownClick` | `{ key: string }` — user menu item key from `hb-dropdown-simple`. |
47
+ | `navbarSlotClick` | `{ side: "left" \| "right" \| "center" }` — see Behavior for which regions emit this in the current implementation. |
48
+
49
+ ## CSS custom properties (`::host`)
50
+
51
+ Documented in `extra/docs.ts` / `styleSetup` (Bulma tokens and one component override). Defaults below are the documented fallbacks; override from the light DOM on the host.
52
+
53
+ | Variable | Default (documented) | Notes |
54
+ |----------|----------------------|--------|
55
+ | `--bulma-navbar-background-color` | `#f5f5f5` | Navbar strip background. |
56
+ | `--bulma-navbar-item-color` | `#363636` | Items and icon color on the bar. |
57
+ | `--bulma-navbar-height` | `3.25rem` | Minimum navbar block height. |
58
+ | `--bulma-navbar-item-img-max-height` | `1.75rem` | Max height for the brand logo image. |
59
+ | `--bulma-text` | `#363636` | Text fallback. |
60
+ | `--bulma-scheme-main-bis` | `#f5f5f5` | Background fallback. |
61
+ | `--bulma-radius` | `0.375rem` | Menu toggle and control corner radius. |
62
+ | `--hb-navbar-menu-btn-radius` | _(empty)_ | Optional override for the hamburger / menu button radius. |
63
+
64
+ See [Bulma CSS variables](https://bulma.io/documentation/features/css-variables/) for the wider `--bulma-*` system.
65
+
66
+ ## `::part` and slots
67
+
68
+ **Parts** (for `::part(...)` from outside the shadow root):
69
+
70
+ | Part | Purpose |
71
+ |------|---------|
72
+ | `left-slot` | Left cluster: toggle + left slot (see `extra/docs.ts`). |
73
+ | `center-slot` | Center column: brand + `center-slot` projection. |
74
+ | `right-slot` | Right cluster: `right-slot` + optional user dropdown. |
75
+
76
+ **Slots:**
77
+
78
+ | Slot | Purpose |
79
+ |------|---------|
80
+ | `left-slot` | Custom content to the left of the brand (inside the left region). |
81
+ | `center-slot` | Extra content centered on the bar (sibling to the brand control in the center column). |
82
+ | `right-slot` | Actions or widgets to the right of the brand (before the user menu, if any). |
83
+ | `nav-switcher` | Replaces the default `☰` label inside the menu button. |
84
+ | `brand` | Replaces the default logo + `companybrandname` block. |
85
+
86
+ ## TypeScript typings (authoring)
87
+
88
+ From `types/webcomponent.type.d.ts`:
89
+
90
+ ```ts
10
91
  interface IUserMenuListItem {
11
- key: string;
12
- label: string;
13
- badge?: number;
14
- group?: string;
92
+ key: string;
93
+ label: string;
94
+ badge?: number;
95
+ group?: string;
15
96
  }
16
97
  export interface IUserMenu {
17
- imgUri: string;
18
- list?: IUserMenuListItem[];
98
+ imgUri: string;
99
+ list?: IUserMenuListItem[];
19
100
  }
20
101
  export type Component = {
21
- id?: string;
22
- style?: string;
23
- companybrandname: string;
24
- companylogouri: string;
25
- // pagetitle: string;
26
- switchopen?: "yes" | "no";
27
- usermenu?: IUserMenu;
28
- noburger?: string;
102
+ id?: string;
103
+ style?: string;
104
+ companybrandname: string;
105
+ companylogouri: string;
106
+ switchopen?: "yes" | "no";
107
+ usermenu?: IUserMenu;
108
+ noburger?: string;
29
109
  };
30
110
 
31
111
  export type Events = {
32
- navbarDropDownClick: { key: string };
33
- navmenuswitch: { isOpen: boolean };
34
- navbarSlotClick: { side: "left" | "right" | "center" };
112
+ navbarDropDownClick: { key: string };
113
+ navmenuswitch: { isOpen: boolean };
114
+ navbarSlotClick: { side: "left" | "right" | "center" };
35
115
  };
36
116
  ```
117
+
118
+ ## HTML examples
119
+
120
+ **Minimal bar (text-only brand):**
121
+
122
+ ```html
123
+ <hb-navbar companybrandname="Acme" companylogouri=""></hb-navbar>
124
+ ```
125
+
126
+ **Brand with logo and menu closed explicitly:**
127
+
128
+ ```html
129
+ <hb-navbar
130
+ companybrandname="Acme"
131
+ companylogouri="https://example.com/logo.svg"
132
+ switchopen="no"
133
+ ></hb-navbar>
134
+ ```
135
+
136
+ **No hamburger (e.g. desktop shell with another way to open the drawer):**
137
+
138
+ ```html
139
+ <hb-navbar
140
+ companybrandname="Studio"
141
+ companylogouri=""
142
+ noburger="yes"
143
+ ></hb-navbar>
144
+ ```
145
+
146
+ **User avatar dropdown** (`usermenu` must be a single JSON string in HTML):
147
+
148
+ ```html
149
+ <hb-navbar
150
+ companybrandname="Acme"
151
+ companylogouri=""
152
+ usermenu='{"imgUri":"https://example.com/avatar.png","list":[{"key":"profile","label":"Profile"},{"key":"signout","label":"Sign out"}]}'
153
+ ></hb-navbar>
154
+ ```
155
+
156
+ **Custom toggle glyph and right-slot actions:**
157
+
158
+ ```html
159
+ <hb-navbar companybrandname="App" companylogouri="">
160
+ <span slot="nav-switcher">Menu</span>
161
+ <span slot="right-slot"><!-- host app controls --></span>
162
+ </hb-navbar>
163
+ ```
164
+
165
+ ```js
166
+ const el = document.querySelector("hb-navbar");
167
+ el.addEventListener("navmenuswitch", (e) => console.log("open:", e.detail.isOpen));
168
+ el.addEventListener("navbarDropDownClick", (e) => console.log("menu key:", e.detail.key));
169
+ el.addEventListener("navbarSlotClick", (e) => console.log("slot side:", e.detail.side));
170
+ ```
package/main.iife.js CHANGED
@@ -1,6 +1,6 @@
1
1
  (function(e){Object.defineProperty(e,Symbol.toStringTag,{value:`Module`}),typeof window<`u`&&((window.__svelte??={}).v??=new Set).add(`5`);var t={},n=Symbol(),r=`http://www.w3.org/1999/xhtml`,i=Array.isArray,a=Array.prototype.indexOf,o=Array.prototype.includes,s=Array.from,c=Object.keys,l=Object.defineProperty,u=Object.getOwnPropertyDescriptor,d=Object.getOwnPropertyDescriptors,f=Object.prototype,p=Array.prototype,m=Object.getPrototypeOf,h=Object.isExtensible,ee=()=>{};function g(e){for(var t=0;t<e.length;t++)e[t]()}function _(){var e,t;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}var v=1024,y=2048,b=4096,te=8192,ne=16384,re=32768,ie=1<<25,ae=65536,oe=1<<19,se=1<<20,ce=65536,le=1<<21,ue=1<<22,de=1<<23,fe=Symbol(`$state`),pe=Symbol(`legacy props`),me=Symbol(``),x=new class extends Error{name=`StaleReactionError`;message="The reaction that called `getAbortSignal()` was re-run or destroyed"},he=!!globalThis.document?.contentType&&globalThis.document.contentType.includes(`xml`);function ge(){throw Error(`https://svelte.dev/e/async_derived_orphan`)}function _e(e){throw Error(`https://svelte.dev/e/effect_in_teardown`)}function ve(){throw Error(`https://svelte.dev/e/effect_in_unowned_derived`)}function ye(e){throw Error(`https://svelte.dev/e/effect_orphan`)}function be(){throw Error(`https://svelte.dev/e/effect_update_depth_exceeded`)}function xe(){throw Error(`https://svelte.dev/e/hydration_failed`)}function Se(e){throw Error(`https://svelte.dev/e/props_invalid_value`)}function Ce(){throw Error(`https://svelte.dev/e/state_descriptors_fixed`)}function we(){throw Error(`https://svelte.dev/e/state_prototype_fixed`)}function Te(){throw Error(`https://svelte.dev/e/state_unsafe_mutation`)}function Ee(){throw Error(`https://svelte.dev/e/svelte_boundary_reset_onerror`)}function De(e){console.warn(`https://svelte.dev/e/hydration_mismatch`)}function Oe(){console.warn(`https://svelte.dev/e/svelte_boundary_reset_noop`)}var S=!1;function C(e){S=e}var w;function T(e){if(e===null)throw De(),t;return w=e}function ke(){return T(R(w))}function E(e){if(S){if(R(w)!==null)throw De(),t;w=e}}function Ae(e=1){if(S){for(var t=e,n=w;t--;)n=R(n);w=n}}function je(e=!0){for(var t=0,n=w;;){if(n.nodeType===8){var r=n.data;if(r===`]`){if(t===0)return n;--t}else (r===`[`||r===`[!`||r[0]===`[`&&!isNaN(Number(r.slice(1))))&&(t+=1)}var i=R(n);e&&n.remove(),n=i}}function Me(e){if(!e||e.nodeType!==8)throw De(),t;return e.data}function Ne(e){return e===this.v}function Pe(e,t){return e==e?e!==t||typeof e==`object`&&!!e||typeof e==`function`:t==t}function Fe(e){return!Pe(e,this.v)}var Ie=!1,Le=!1,D=null;function Re(e){D=e}function ze(e,t=!1,n){D={p:D,i:!1,c:null,e:null,s:e,x:null,r:q,l:Le&&!t?{s:null,u:null,$:[]}:null}}function Be(e){var t=D,n=t.e;if(n!==null){t.e=null;for(var r of n)sn(r)}return e!==void 0&&(t.x=e),t.i=!0,D=t.p,e??{}}function Ve(){return!Le||D!==null&&D.l===null}var He=[];function Ue(){var e=He;He=[],g(e)}function We(e){if(He.length===0&&!tt){var t=He;queueMicrotask(()=>{t===He&&Ue()})}He.push(e)}function Ge(){for(;He.length>0;)Ue()}function Ke(e){var t=q;if(t===null)return W.f|=de,e;if(!(t.f&32768)&&!(t.f&4))throw e;O(e,t)}function O(e,t){for(;t!==null;){if(t.f&128){if(!(t.f&32768))throw e;try{t.b.error(e);return}catch(t){e=t}}t=t.parent}throw e}var qe=~(y|b|v);function k(e,t){e.f=e.f&qe|t}function Je(e){e.f&512||e.deps===null?k(e,v):k(e,b)}function Ye(e){if(e!==null)for(let t of e)!(t.f&2)||!(t.f&65536)||(t.f^=ce,Ye(t.deps))}function Xe(e,t,n){e.f&2048?t.add(e):e.f&4096&&n.add(e),Ye(e.deps),k(e,v)}var Ze=!1,Qe=!1;function $e(e){var t=Qe;try{return Qe=!1,[e(),Qe]}finally{Qe=t}}var A=new Set,j=null,M=null,et=null,tt=!1,nt=!1,rt=null,it=null,at=0,ot=1,st=class e{id=ot++;current=new Map;previous=new Map;#e=new Set;#t=new Set;#n=new Map;#r=new Map;#i=null;#a=[];#o=new Set;#s=new Set;#c=new Map;is_fork=!1;#l=!1;#u=new Set;#d(){return this.is_fork||this.#r.size>0}#f(){for(let n of this.#u)for(let r of n.#r.keys()){for(var e=!1,t=r;t.parent!==null;){if(this.#c.has(t)){e=!0;break}t=t.parent}if(!e)return!0}return!1}skip_effect(e){this.#c.has(e)||this.#c.set(e,{d:[],m:[]})}unskip_effect(e){var t=this.#c.get(e);if(t){this.#c.delete(e);for(var n of t.d)k(n,y),this.schedule(n);for(n of t.m)k(n,b),this.schedule(n)}}#p(){if(at++>1e3&&(A.delete(this),lt()),!this.#d()){for(let e of this.#o)this.#s.delete(e),k(e,y),this.schedule(e);for(let e of this.#s)k(e,b),this.schedule(e)}let t=this.#a;this.#a=[],this.apply();var n=rt=[],r=[],i=it=[];for(let e of t)try{this.#m(e,n,r)}catch(t){throw ht(e),t}if(j=null,i.length>0){var a=e.ensure();for(let e of i)a.schedule(e)}if(rt=null,it=null,this.#d()||this.#f()){this.#h(r),this.#h(n);for(let[e,t]of this.#c)mt(e,t)}else{this.#n.size===0&&A.delete(this),this.#o.clear(),this.#s.clear();for(let e of this.#e)e(this);this.#e.clear(),ut(r),ut(n),this.#i?.resolve()}var o=j;if(this.#a.length>0){let e=o??=this;e.#a.push(...this.#a.filter(t=>!e.#a.includes(t)))}o!==null&&(A.add(o),o.#p()),A.has(this)||this.#g()}#m(e,t,n){e.f^=v;for(var r=e.first;r!==null;){var i=r.f,a=(i&96)!=0;if(!(a&&i&1024||i&8192||this.#c.has(r))&&r.fn!==null){a?r.f^=v:i&4?t.push(r):Ie&&i&16777224?n.push(r):Fn(r)&&(i&16&&this.#s.add(r),Bn(r));var o=r.first;if(o!==null){r=o;continue}}for(;r!==null;){var s=r.next;if(s!==null){r=s;break}r=r.parent}}}#h(e){for(var t=0;t<e.length;t+=1)Xe(e[t],this.#o,this.#s)}capture(e,t,r=!1){t!==n&&!this.previous.has(e)&&this.previous.set(e,t),e.f&8388608||(this.current.set(e,[e.v,r]),M?.set(e,e.v))}activate(){j=this}deactivate(){j=null,M=null}flush(){try{nt=!0,j=this,this.#p()}finally{at=0,et=null,rt=null,it=null,nt=!1,j=null,M=null,P.clear()}}discard(){for(let e of this.#t)e(this);this.#t.clear(),A.delete(this)}#g(){for(let c of A){var e=c.id<this.id,t=[];for(let[r,[i,a]]of this.current){if(c.current.has(r)){var n=c.current.get(r)[0];if(e&&i!==n)c.current.set(r,[i,a]);else continue}t.push(r)}var r=[...c.current.keys()].filter(e=>!this.current.has(e));if(r.length===0)e&&c.discard();else if(t.length>0){c.activate();var i=new Set,a=new Map;for(var o of t)dt(o,r,i,a);if(c.#a.length>0){c.apply();for(var s of c.#a)c.#m(s,[],[]);c.#a=[]}c.deactivate()}}for(let e of A)e.#u.has(this)&&(e.#u.delete(this),e.#u.size===0&&!e.#d()&&(e.activate(),e.#p()))}increment(e,t){let n=this.#n.get(t)??0;if(this.#n.set(t,n+1),e){let e=this.#r.get(t)??0;this.#r.set(t,e+1)}}decrement(e,t,n){let r=this.#n.get(t)??0;if(r===1?this.#n.delete(t):this.#n.set(t,r-1),e){let e=this.#r.get(t)??0;e===1?this.#r.delete(t):this.#r.set(t,e-1)}this.#l||n||(this.#l=!0,We(()=>{this.#l=!1,this.flush()}))}transfer_effects(e,t){for(let t of e)this.#o.add(t);for(let e of t)this.#s.add(e);e.clear(),t.clear()}oncommit(e){this.#e.add(e)}ondiscard(e){this.#t.add(e)}settled(){return(this.#i??=_()).promise}static ensure(){if(j===null){let t=j=new e;nt||(A.add(j),tt||We(()=>{j===t&&t.flush()}))}return j}apply(){if(!Ie||!this.is_fork&&A.size===1){M=null;return}M=new Map;for(let[e,[t]]of this.current)M.set(e,t);for(let n of A)if(!(n===this||n.is_fork)){var e=!1,t=!1;if(n.id<this.id)for(let[r,[,i]]of n.current)i||(e||=this.current.has(r),t||=!this.current.has(r));if(e&&t)this.#u.add(n);else for(let[e,t]of n.previous)M.has(e)||M.set(e,t)}}schedule(e){if(et=e,e.b?.is_pending&&e.f&16777228&&!(e.f&32768)){e.b.defer_effect(e);return}for(var t=e;t.parent!==null;){t=t.parent;var n=t.f;if(rt!==null&&t===q&&(Ie||(W===null||!(W.f&2))&&!Ze))return;if(n&96){if(!(n&1024))return;t.f^=v}}this.#a.push(t)}};function ct(e){var t=tt;tt=!0;try{var n;for(e&&(j!==null&&!j.is_fork&&j.flush(),n=e());;){if(Ge(),j===null)return n;j.flush()}}finally{tt=t}}function lt(){try{be()}catch(e){O(e,et)}}var N=null;function ut(e){var t=e.length;if(t!==0){for(var n=0;n<t;){var r=e[n++];if(!(r.f&24576)&&Fn(r)&&(N=new Set,Bn(r),r.deps===null&&r.first===null&&r.nodes===null&&r.teardown===null&&r.ac===null&&yn(r),N?.size>0)){P.clear();for(let e of N){if(e.f&24576)continue;let t=[e],n=e.parent;for(;n!==null;)N.has(n)&&(N.delete(n),t.push(n)),n=n.parent;for(let e=t.length-1;e>=0;e--){let n=t[e];n.f&24576||Bn(n)}}N.clear()}}N=null}}function dt(e,t,n,r){if(!n.has(e)&&(n.add(e),e.reactions!==null))for(let i of e.reactions){let e=i.f;e&2?dt(i,t,n,r):e&4194320&&!(e&2048)&&ft(i,t,r)&&(k(i,y),pt(i))}}function ft(e,t,n){let r=n.get(e);if(r!==void 0)return r;if(e.deps!==null)for(let r of e.deps){if(o.call(t,r))return!0;if(r.f&2&&ft(r,t,n))return n.set(r,!0),!0}return n.set(e,!1),!1}function pt(e){j.schedule(e)}function mt(e,t){if(!(e.f&32&&e.f&1024)){e.f&2048?t.d.push(e):e.f&4096&&t.m.push(e),k(e,v);for(var n=e.first;n!==null;)mt(n,t),n=n.next}}function ht(e){k(e,v);for(var t=e.first;t!==null;)ht(t),t=t.next}function gt(e){let t=0,n=Ft(0),r;return()=>{rn()&&($(n),fn(()=>(t===0&&(r=Un(()=>e(()=>zt(n)))),t+=1,()=>{We(()=>{--t,t===0&&(r?.(),r=void 0,zt(n))})})))}}var _t=ae|oe;function vt(e,t,n,r){new yt(e,t,n,r)}var yt=class{parent;is_pending=!1;transform_error;#e;#t=S?w:null;#n;#r;#i;#a=null;#o=null;#s=null;#c=null;#l=0;#u=0;#d=!1;#f=new Set;#p=new Set;#m=null;#h=gt(()=>(this.#m=Ft(this.#l),()=>{this.#m=null}));constructor(e,t,n,r){this.#e=e,this.#n=t,this.#r=e=>{var t=q;t.b=this,t.f|=128,n(e)},this.parent=q.b,this.transform_error=r??this.parent?.transform_error??(e=>e),this.#i=mn(()=>{if(S){let e=this.#t;ke();let t=e.data===`[!`;if(e.data.startsWith(`[?`)){let t=JSON.parse(e.data.slice(2));this.#_(t)}else t?this.#v():this.#g()}else this.#y()},_t),S&&(this.#e=w)}#g(){try{this.#a=V(()=>this.#r(this.#e))}catch(e){this.error(e)}}#_(e){let t=this.#n.failed;t&&(this.#s=V(()=>{t(this.#e,()=>e,()=>()=>{})}))}#v(){let e=this.#n.pending;e&&(this.is_pending=!0,this.#o=V(()=>e(this.#e)),We(()=>{var e=this.#c=document.createDocumentFragment(),t=L();e.append(t),this.#a=this.#x(()=>V(()=>this.#r(t))),this.#u===0&&(this.#e.before(e),this.#c=null,bn(this.#o,()=>{this.#o=null}),this.#b(j))}))}#y(){try{if(this.is_pending=this.has_pending_snippet(),this.#u=0,this.#l=0,this.#a=V(()=>{this.#r(this.#e)}),this.#u>0){var e=this.#c=document.createDocumentFragment();wn(this.#a,e);let t=this.#n.pending;this.#o=V(()=>t(this.#e))}else this.#b(j)}catch(e){this.error(e)}}#b(e){this.is_pending=!1,e.transfer_effects(this.#f,this.#p)}defer_effect(e){Xe(e,this.#f,this.#p)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#n.pending}#x(e){var t=q,n=W,r=D;J(this.#i),K(this.#i),Re(this.#i.ctx);try{return st.ensure(),e()}catch(e){return Ke(e),null}finally{J(t),K(n),Re(r)}}#S(e,t){if(!this.has_pending_snippet()){this.parent&&this.parent.#S(e,t);return}this.#u+=e,this.#u===0&&(this.#b(t),this.#o&&bn(this.#o,()=>{this.#o=null}),this.#c&&=(this.#e.before(this.#c),null))}update_pending_count(e,t){this.#S(e,t),this.#l+=e,!(!this.#m||this.#d)&&(this.#d=!0,We(()=>{this.#d=!1,this.#m&&Lt(this.#m,this.#l)}))}get_effect_pending(){return this.#h(),$(this.#m)}error(e){var t=this.#n.onerror;let n=this.#n.failed;if(!t&&!n)throw e;this.#a&&=(H(this.#a),null),this.#o&&=(H(this.#o),null),this.#s&&=(H(this.#s),null),S&&(T(this.#t),Ae(),T(je()));var r=!1,i=!1;let a=()=>{if(r){Oe();return}r=!0,i&&Ee(),this.#s!==null&&bn(this.#s,()=>{this.#s=null}),this.#x(()=>{this.#y()})},o=e=>{try{i=!0,t?.(e,a),i=!1}catch(e){O(e,this.#i&&this.#i.parent)}n&&(this.#s=this.#x(()=>{try{return V(()=>{var t=q;t.b=this,t.f|=128,n(this.#e,()=>e,()=>a)})}catch(e){return O(e,this.#i.parent),null}}))};We(()=>{var t;try{t=this.transform_error(e)}catch(e){O(e,this.#i&&this.#i.parent);return}typeof t==`object`&&t&&typeof t.then==`function`?t.then(o,e=>O(e,this.#i&&this.#i.parent)):o(t)})}};function bt(e,t,n,r){let i=Ve()?wt:Et;var a=e.filter(e=>!e.settled);if(n.length===0&&a.length===0){r(t.map(i));return}var o=q,s=xt(),c=a.length===1?a[0].promise:a.length>1?Promise.all(a.map(e=>e.promise)):null;function l(e){s();try{r(e)}catch(e){o.f&16384||O(e,o)}St()}if(n.length===0){c.then(()=>l(t.map(i)));return}var u=Ct();function d(){Promise.all(n.map(e=>Tt(e))).then(e=>l([...t.map(i),...e])).catch(e=>O(e,o)).finally(()=>u())}c?c.then(()=>{s(),d(),St()}):d()}function xt(){var e=q,t=W,n=D,r=j;return function(i=!0){J(e),K(t),Re(n),i&&!(e.f&16384)&&(r?.activate(),r?.apply())}}function St(e=!0){J(null),K(null),Re(null),e&&j?.deactivate()}function Ct(){var e=q,t=e.b,n=j,r=t.is_rendered();return t.update_pending_count(1,n),n.increment(r,e),(i=!1)=>{t.update_pending_count(-1,n),n.decrement(r,e,i)}}function wt(e){var t=2|y,r=W!==null&&W.f&2?W:null;return q!==null&&(q.f|=oe),{ctx:D,deps:null,effects:null,equals:Ne,f:t,fn:e,reactions:null,rv:0,v:n,wv:0,parent:r??q,ac:null}}function Tt(e,t,r){let i=q;i===null&&ge();var a=void 0,o=Ft(n),s=!W,c=new Map;return dn(()=>{var t=q,n=_();a=n.promise;try{Promise.resolve(e()).then(n.resolve,n.reject).finally(St)}catch(e){n.reject(e),St()}var r=j;if(s){if(t.f&32768)var l=Ct();if(i.b.is_rendered())c.get(r)?.reject(x),c.delete(r);else{for(let e of c.values())e.reject(x);c.clear()}c.set(r,n)}let u=(e,n=void 0)=>{if(l&&l(n===x),!(n===x||t.f&16384)){if(r.activate(),n)o.f|=de,Lt(o,n);else{o.f&8388608&&(o.f^=de),Lt(o,e);for(let[e,t]of c){if(c.delete(e),e===r)break;t.reject(x)}}r.deactivate()}};n.promise.then(u,e=>u(null,e||`unknown`))}),an(()=>{for(let e of c.values())e.reject(x)}),new Promise(e=>{function t(n){function r(){n===a?e(o):t(a)}n.then(r,r)}t(a)})}function Et(e){let t=wt(e);return t.equals=Fe,t}function Dt(e){var t=e.effects;if(t!==null){e.effects=null;for(var n=0;n<t.length;n+=1)H(t[n])}}function Ot(e){for(var t=e.parent;t!==null;){if(!(t.f&2))return t.f&16384?null:t;t=t.parent}return null}function kt(e){var t,n=q;J(Ot(e));try{e.f&=~ce,Dt(e),t=Ln(e)}finally{J(n)}return t}function At(e){var t=e.v,n=kt(e);if(!e.equals(n)&&(e.wv=Pn(),(!j?.is_fork||e.deps===null)&&(e.v=n,j?.capture(e,t,!0),e.deps===null))){k(e,v);return}U||(M===null?Je(e):(rn()||j?.is_fork)&&M.set(e,n))}function jt(e){if(e.effects!==null)for(let t of e.effects)(t.teardown||t.ac)&&(t.teardown?.(),t.ac?.abort(x),t.teardown=ee,t.ac=null,zn(t,0),gn(t))}function Mt(e){if(e.effects!==null)for(let t of e.effects)t.teardown&&Bn(t)}var Nt=new Set,P=new Map,Pt=!1;function Ft(e,t){return{f:0,v:e,reactions:null,equals:Ne,rv:0,wv:0}}function F(e,t){let n=Ft(e,t);return On(n),n}function It(e,t=!1,n=!0){let r=Ft(e);return t||(r.equals=Fe),Le&&n&&D!==null&&D.l!==null&&(D.l.s??=[]).push(r),r}function I(e,t,n=!1){return W!==null&&(!G||W.f&131072)&&Ve()&&W.f&4325394&&(Y===null||!o.call(Y,e))&&Te(),Lt(e,n?Vt(t):t,it)}function Lt(e,t,n=null){if(!e.equals(t)){var r=e.v;U?P.set(e,t):P.set(e,r),e.v=t;var i=st.ensure();if(i.capture(e,r),e.f&2){let t=e;e.f&2048&&kt(t),M===null&&Je(t)}e.wv=Pn(),Bt(e,y,n),Ve()&&q!==null&&q.f&1024&&!(q.f&96)&&(Q===null?kn([e]):Q.push(e)),!i.is_fork&&Nt.size>0&&!Pt&&Rt()}return t}function Rt(){Pt=!1;for(let e of Nt)e.f&1024&&k(e,b),Fn(e)&&Bn(e);Nt.clear()}function zt(e){I(e,e.v+1)}function Bt(e,t,n){var r=e.reactions;if(r!==null)for(var i=Ve(),a=r.length,o=0;o<a;o++){var s=r[o],c=s.f;if(!(!i&&s===q)){var l=(c&y)===0;if(l&&k(s,t),c&2){var u=s;M?.delete(u),c&65536||(c&512&&(s.f|=ce),Bt(u,b,n))}else if(l){var d=s;c&16&&N!==null&&N.add(d),n===null?pt(d):n.push(d)}}}}function Vt(e){if(typeof e!=`object`||!e||fe in e)return e;let t=m(e);if(t!==f&&t!==p)return e;var r=new Map,a=i(e),o=F(0),s=null,c=Mn,l=e=>{if(Mn===c)return e();var t=W,n=Mn;K(null),Nn(c);var r=e();return K(t),Nn(n),r};return a&&r.set(`length`,F(e.length,s)),new Proxy(e,{defineProperty(e,t,n){(!(`value`in n)||n.configurable===!1||n.enumerable===!1||n.writable===!1)&&Ce();var i=r.get(t);return i===void 0?l(()=>{var e=F(n.value,s);return r.set(t,e),e}):I(i,n.value,!0),!0},deleteProperty(e,t){var i=r.get(t);if(i===void 0){if(t in e){let e=l(()=>F(n,s));r.set(t,e),zt(o)}}else I(i,n),zt(o);return!0},get(t,i,a){if(i===fe)return e;var o=r.get(i),c=i in t;if(o===void 0&&(!c||u(t,i)?.writable)&&(o=l(()=>F(Vt(c?t[i]:n),s)),r.set(i,o)),o!==void 0){var d=$(o);return d===n?void 0:d}return Reflect.get(t,i,a)},getOwnPropertyDescriptor(e,t){var i=Reflect.getOwnPropertyDescriptor(e,t);if(i&&`value`in i){var a=r.get(t);a&&(i.value=$(a))}else if(i===void 0){var o=r.get(t),s=o?.v;if(o!==void 0&&s!==n)return{enumerable:!0,configurable:!0,value:s,writable:!0}}return i},has(e,t){if(t===fe)return!0;var i=r.get(t),a=i!==void 0&&i.v!==n||Reflect.has(e,t);return(i!==void 0||q!==null&&(!a||u(e,t)?.writable))&&(i===void 0&&(i=l(()=>F(a?Vt(e[t]):n,s)),r.set(t,i)),$(i)===n)?!1:a},set(e,t,i,c){var d=r.get(t),f=t in e;if(a&&t===`length`)for(var p=i;p<d.v;p+=1){var m=r.get(p+``);m===void 0?p in e&&(m=l(()=>F(n,s)),r.set(p+``,m)):I(m,n)}if(d===void 0)(!f||u(e,t)?.writable)&&(d=l(()=>F(void 0,s)),I(d,Vt(i)),r.set(t,d));else{f=d.v!==n;var h=l(()=>Vt(i));I(d,h)}var ee=Reflect.getOwnPropertyDescriptor(e,t);if(ee?.set&&ee.set.call(c,i),!f){if(a&&typeof t==`string`){var g=r.get(`length`),_=Number(t);Number.isInteger(_)&&_>=g.v&&I(g,_+1)}zt(o)}return!0},ownKeys(e){$(o);var t=Reflect.ownKeys(e).filter(e=>{var t=r.get(e);return t===void 0||t.v!==n});for(var[i,a]of r)a.v!==n&&!(i in e)&&t.push(i);return t},setPrototypeOf(){we()}})}var Ht,Ut,Wt,Gt;function Kt(){if(Ht===void 0){Ht=window,Ut=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,n=Text.prototype;Wt=u(t,`firstChild`).get,Gt=u(t,`nextSibling`).get,h(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),h(n)&&(n.__t=void 0)}}function L(e=``){return document.createTextNode(e)}function qt(e){return Wt.call(e)}function R(e){return Gt.call(e)}function z(e,t){if(!S)return qt(e);var n=qt(w);if(n===null)n=w.appendChild(L());else if(t&&n.nodeType!==3){var r=L();return n?.before(r),T(r),r}return t&&$t(n),T(n),n}function Jt(e,t=!1){if(!S){var n=qt(e);return n instanceof Comment&&n.data===``?R(n):n}if(t){if(w?.nodeType!==3){var r=L();return w?.before(r),T(r),r}$t(w)}return w}function Yt(e,t=1,n=!1){let r=S?w:e;for(var i;t--;)i=r,r=R(r);if(!S)return r;if(n){if(r?.nodeType!==3){var a=L();return r===null?i?.after(a):r.before(a),T(a),a}$t(r)}return T(r),r}function Xt(e){e.textContent=``}function Zt(){return!Ie||N!==null?!1:(q.f&re)!==0}function Qt(e,t,n){let r=n?{is:n}:void 0;return document.createElementNS(t??`http://www.w3.org/1999/xhtml`,e,r)}function $t(e){if(e.nodeValue.length<65536)return;let t=e.nextSibling;for(;t!==null&&t.nodeType===3;)t.remove(),e.nodeValue+=t.nodeValue,t=e.nextSibling}function en(e){var t=W,n=q;K(null),J(null);try{return e()}finally{K(t),J(n)}}function tn(e){q===null&&(W===null&&ye(e),ve()),U&&_e(e)}function nn(e,t){var n=t.last;n===null?t.last=t.first=e:(n.next=e,e.prev=n,t.last=e)}function B(e,t){var n=q;n!==null&&n.f&8192&&(e|=te);var r={ctx:D,deps:null,nodes:null,f:e|y|512,first:null,fn:t,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null},i=r;if(e&4)rt===null?st.ensure().schedule(r):rt.push(r);else if(t!==null){try{Bn(r)}catch(e){throw H(r),e}i.deps===null&&i.teardown===null&&i.nodes===null&&i.first===i.last&&!(i.f&524288)&&(i=i.first,e&16&&e&65536&&i!==null&&(i.f|=ae))}if(i!==null&&(i.parent=n,n!==null&&nn(i,n),W!==null&&W.f&2&&!(e&64))){var a=W;(a.effects??=[]).push(i)}return r}function rn(){return W!==null&&!G}function an(e){let t=B(8,null);return k(t,v),t.teardown=e,t}function on(e){tn(`$effect`);var t=q.f;if(!W&&t&32&&!(t&32768)){var n=D;(n.e??=[]).push(e)}else return sn(e)}function sn(e){return B(4|se,e)}function cn(e){st.ensure();let t=B(64|oe,e);return()=>{H(t)}}function ln(e){st.ensure();let t=B(64|oe,e);return(e={})=>new Promise(n=>{e.outro?bn(t,()=>{H(t),n(void 0)}):(H(t),n(void 0))})}function un(e){return B(4,e)}function dn(e){return B(ue|oe,e)}function fn(e,t=0){return B(8|t,e)}function pn(e,t=[],n=[],r=[]){bt(r,t,n,t=>{B(8,()=>e(...t.map($)))})}function mn(e,t=0){return B(16|t,e)}function V(e){return B(32|oe,e)}function hn(e){var t=e.teardown;if(t!==null){let e=U,n=W;Dn(!0),K(null);try{t.call(null)}finally{Dn(e),K(n)}}}function gn(e,t=!1){var n=e.first;for(e.first=e.last=null;n!==null;){let e=n.ac;e!==null&&en(()=>{e.abort(x)});var r=n.next;n.f&64?n.parent=null:H(n,t),n=r}}function _n(e){for(var t=e.first;t!==null;){var n=t.next;t.f&32||H(t),t=n}}function H(e,t=!0){var n=!1;(t||e.f&262144)&&e.nodes!==null&&e.nodes.end!==null&&(vn(e.nodes.start,e.nodes.end),n=!0),k(e,ie),gn(e,t&&!n),zn(e,0);var r=e.nodes&&e.nodes.t;if(r!==null)for(let e of r)e.stop();hn(e),e.f^=ie,e.f|=ne;var i=e.parent;i!==null&&i.first!==null&&yn(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes=e.ac=e.b=null}function vn(e,t){for(;e!==null;){var n=e===t?null:R(e);e.remove(),e=n}}function yn(e){var t=e.parent,n=e.prev,r=e.next;n!==null&&(n.next=r),r!==null&&(r.prev=n),t!==null&&(t.first===e&&(t.first=r),t.last===e&&(t.last=n))}function bn(e,t,n=!0){var r=[];xn(e,r,!0);var i=()=>{n&&H(e),t&&t()},a=r.length;if(a>0){var o=()=>--a||i();for(var s of r)s.out(o)}else i()}function xn(e,t,n){if(!(e.f&8192)){e.f^=te;var r=e.nodes&&e.nodes.t;if(r!==null)for(let e of r)(e.is_global||n)&&t.push(e);for(var i=e.first;i!==null;){var a=i.next,o=(i.f&65536)!=0||(i.f&32)!=0&&(e.f&16)!=0;xn(i,t,o?n:!1),i=a}}}function Sn(e){Cn(e,!0)}function Cn(e,t){if(e.f&8192){e.f^=te,e.f&1024||(k(e,y),st.ensure().schedule(e));for(var n=e.first;n!==null;){var r=n.next,i=(n.f&65536)!=0||(n.f&32)!=0;Cn(n,i?t:!1),n=r}var a=e.nodes&&e.nodes.t;if(a!==null)for(let e of a)(e.is_global||t)&&e.in()}}function wn(e,t){if(e.nodes)for(var n=e.nodes.start,r=e.nodes.end;n!==null;){var i=n===r?null:R(n);t.append(n),n=i}}var Tn=null,En=!1,U=!1;function Dn(e){U=e}var W=null,G=!1;function K(e){W=e}var q=null;function J(e){q=e}var Y=null;function On(e){W!==null&&(!Ie||W.f&2)&&(Y===null?Y=[e]:Y.push(e))}var X=null,Z=0,Q=null;function kn(e){Q=e}var An=1,jn=0,Mn=jn;function Nn(e){Mn=e}function Pn(){return++An}function Fn(e){var t=e.f;if(t&2048)return!0;if(t&2&&(e.f&=~ce),t&4096){for(var n=e.deps,r=n.length,i=0;i<r;i++){var a=n[i];if(Fn(a)&&At(a),a.wv>e.wv)return!0}t&512&&M===null&&k(e,v)}return!1}function In(e,t,n=!0){var r=e.reactions;if(r!==null&&!(!Ie&&Y!==null&&o.call(Y,e)))for(var i=0;i<r.length;i++){var a=r[i];a.f&2?In(a,t,!1):t===a&&(n?k(a,y):a.f&1024&&k(a,b),pt(a))}}function Ln(e){var t=X,n=Z,r=Q,i=W,a=Y,o=D,s=G,c=Mn,l=e.f;X=null,Z=0,Q=null,W=l&96?null:e,Y=null,Re(e.ctx),G=!1,Mn=++jn,e.ac!==null&&(en(()=>{e.ac.abort(x)}),e.ac=null);try{e.f|=le;var u=e.fn,d=u();e.f|=re;var f=e.deps,p=j?.is_fork;if(X!==null){var m;if(p||zn(e,Z),f!==null&&Z>0)for(f.length=Z+X.length,m=0;m<X.length;m++)f[Z+m]=X[m];else e.deps=f=X;if(rn()&&e.f&512)for(m=Z;m<f.length;m++)(f[m].reactions??=[]).push(e)}else !p&&f!==null&&Z<f.length&&(zn(e,Z),f.length=Z);if(Ve()&&Q!==null&&!G&&f!==null&&!(e.f&6146))for(m=0;m<Q.length;m++)In(Q[m],e);if(i!==null&&i!==e){if(jn++,i.deps!==null)for(let e=0;e<n;e+=1)i.deps[e].rv=jn;if(t!==null)for(let e of t)e.rv=jn;Q!==null&&(r===null?r=Q:r.push(...Q))}return e.f&8388608&&(e.f^=de),d}catch(e){return Ke(e)}finally{e.f^=le,X=t,Z=n,Q=r,W=i,Y=a,Re(o),G=s,Mn=c}}function Rn(e,t){let n=t.reactions;if(n!==null){var r=a.call(n,e);if(r!==-1){var i=n.length-1;i===0?n=t.reactions=null:(n[r]=n[i],n.pop())}}if(n===null&&t.f&2&&(X===null||!o.call(X,t))){var s=t;s.f&512&&(s.f^=512,s.f&=~ce),Je(s),jt(s),zn(s,0)}}function zn(e,t){var n=e.deps;if(n!==null)for(var r=t;r<n.length;r++)Rn(e,n[r])}function Bn(e){var t=e.f;if(!(t&16384)){k(e,v);var n=q,r=En;q=e,En=!0;try{t&16777232?_n(e):gn(e),hn(e);var i=Ln(e);e.teardown=typeof i==`function`?i:null,e.wv=An}finally{En=r,q=n}}}function $(e){var t=(e.f&2)!=0;if(Tn?.add(e),W!==null&&!G&&!(q!==null&&q.f&16384)&&(Y===null||!o.call(Y,e))){var n=W.deps;if(W.f&2097152)e.rv<jn&&(e.rv=jn,X===null&&n!==null&&n[Z]===e?Z++:X===null?X=[e]:X.push(e));else{(W.deps??=[]).push(e);var r=e.reactions;r===null?e.reactions=[W]:o.call(r,W)||r.push(W)}}if(U&&P.has(e))return P.get(e);if(t){var i=e;if(U){var a=i.v;return(!(i.f&1024)&&i.reactions!==null||Hn(i))&&(a=kt(i)),P.set(i,a),a}var s=(i.f&512)==0&&!G&&W!==null&&(En||(W.f&512)!=0),c=(i.f&re)===0;Fn(i)&&(s&&(i.f|=512),At(i)),s&&!c&&(Mt(i),Vn(i))}if(M?.has(e))return M.get(e);if(e.f&8388608)throw e.v;return e.v}function Vn(e){if(e.f|=512,e.deps!==null)for(let t of e.deps)(t.reactions??=[]).push(e),t.f&2&&!(t.f&512)&&(Mt(t),Vn(t))}function Hn(e){if(e.v===n)return!0;if(e.deps===null)return!1;for(let t of e.deps)if(P.has(t)||t.f&2&&Hn(t))return!0;return!1}function Un(e){var t=G;try{return G=!0,e()}finally{G=t}}var Wn=Symbol(`events`),Gn=new Set,Kn=new Set;function qn(e,t,n,r={}){function i(e){if(r.capture||Qn.call(t,e),!e.cancelBubble)return en(()=>n?.call(this,e))}return e.startsWith(`pointer`)||e.startsWith(`touch`)||e===`wheel`?We(()=>{t.addEventListener(e,i,r)}):t.addEventListener(e,i,r),i}function Jn(e,t,n,r,i){var a={capture:r,passive:i},o=qn(e,t,n,a);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&an(()=>{t.removeEventListener(e,o,a)})}function Yn(e,t,n){(t[Wn]??={})[e]=n}function Xn(e){for(var t=0;t<e.length;t++)Gn.add(e[t]);for(var n of Kn)n(e)}var Zn=null;function Qn(e){var t=this,n=t.ownerDocument,r=e.type,i=e.composedPath?.()||[],a=i[0]||e.target;Zn=e;var o=0,s=Zn===e&&e[Wn];if(s){var c=i.indexOf(s);if(c!==-1&&(t===document||t===window)){e[Wn]=t;return}var u=i.indexOf(t);if(u===-1)return;c<=u&&(o=c)}if(a=i[o]||e.target,a!==t){l(e,`currentTarget`,{configurable:!0,get(){return a||n}});var d=W,f=q;K(null),J(null);try{for(var p,m=[];a!==null;){var h=a.assignedSlot||a.parentNode||a.host||null;try{var ee=a[Wn]?.[r];ee!=null&&(!a.disabled||e.target===a)&&ee.call(a,e)}catch(e){p?m.push(e):p=e}if(e.cancelBubble||h===t||h===null)break;a=h}if(p){for(let e of m)queueMicrotask(()=>{throw e});throw p}}finally{e[Wn]=t,delete e.currentTarget,K(d),J(f)}}}var $n=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy(`svelte-trusted-html`,{createHTML:e=>e});function er(e){return $n?.createHTML(e)??e}function tr(e){var t=Qt(`template`);return t.innerHTML=er(e.replaceAll(`<!>`,`<!---->`)),t.content}function nr(e,t){var n=q;n.nodes===null&&(n.nodes={start:e,end:t,a:null,t:null})}function rr(e,t){var n=(t&1)!=0,r=(t&2)!=0,i,a=!e.startsWith(`<!>`);return()=>{if(S)return nr(w,null),w;i===void 0&&(i=tr(a?e:`<!>`+e),n||(i=qt(i)));var t=r||Ut?document.importNode(i,!0):i.cloneNode(!0);if(n){var o=qt(t),s=t.lastChild;nr(o,s)}else nr(t,t);return t}}function ir(e=``){if(!S){var t=L(e+``);return nr(t,t),t}var n=w;return n.nodeType===3?$t(n):(n.before(n=L()),T(n)),nr(n,n),n}function ar(e,t){if(S){var n=q;(!(n.f&32768)||n.nodes.end===null)&&(n.nodes.end=w),ke();return}e!==null&&e.before(t)}[...`allowfullscreen.async.autofocus.autoplay.checked.controls.default.disabled.formnovalidate.indeterminate.inert.ismap.loop.multiple.muted.nomodule.novalidate.open.playsinline.readonly.required.reversed.seamless.selected.webkitdirectory.defer.disablepictureinpicture.disableremoteplayback`.split(`.`)];var or=[`touchstart`,`touchmove`];function sr(e){return or.includes(e)}function cr(e,t){var n=t==null?``:typeof t==`object`?`${t}`:t;n!==(e.__t??=e.nodeValue)&&(e.__t=n,e.nodeValue=`${n}`)}function lr(e,t){return fr(e,t)}function ur(e,n){Kt(),n.intro=n.intro??!1;let r=n.target,i=S,a=w;try{for(var o=qt(r);o&&(o.nodeType!==8||o.data!==`[`);)o=R(o);if(!o)throw t;C(!0),T(o);let i=fr(e,{...n,anchor:o});return C(!1),i}catch(i){if(i instanceof Error&&i.message.split(`
2
2
  `).some(e=>e.startsWith(`https://svelte.dev/e/`)))throw i;return i!==t&&console.warn(`Failed to hydrate: `,i),n.recover===!1&&xe(),Kt(),Xt(r),C(!1),lr(e,n)}finally{C(i),T(a)}}var dr=new Map;function fr(e,{target:n,anchor:r,props:i={},events:a,context:o,intro:c=!0,transformError:l}){Kt();var u=void 0,d=ln(()=>{var c=r??n.appendChild(L());vt(c,{pending:()=>{}},n=>{ze({});var r=D;if(o&&(r.c=o),a&&(i.$$events=a),S&&nr(n,null),u=e(n,i)||{},S&&(q.nodes.end=w,w===null||w.nodeType!==8||w.data!==`]`))throw De(),t;Be()},l);var d=new Set,f=e=>{for(var t=0;t<e.length;t++){var r=e[t];if(!d.has(r)){d.add(r);var i=sr(r);for(let e of[n,document]){var a=dr.get(e);a===void 0&&(a=new Map,dr.set(e,a));var o=a.get(r);o===void 0?(e.addEventListener(r,Qn,{passive:i}),a.set(r,1)):a.set(r,o+1)}}}};return f(s(Gn)),Kn.add(f),()=>{for(var e of d)for(let r of[n,document]){var t=dr.get(r),i=t.get(e);--i==0?(r.removeEventListener(e,Qn),t.delete(e),t.size===0&&dr.delete(r)):t.set(e,i)}Kn.delete(f),c!==r&&c.parentNode?.removeChild(c)}});return pr.set(u,d),u}var pr=new WeakMap;function mr(e,t){let n=pr.get(e);return n?(pr.delete(e),n(t)):Promise.resolve()}var hr=class{anchor;#e=new Map;#t=new Map;#n=new Map;#r=new Set;#i=!0;constructor(e,t=!0){this.anchor=e,this.#i=t}#a=e=>{if(this.#e.has(e)){var t=this.#e.get(e),n=this.#t.get(t);if(n)Sn(n),this.#r.delete(t);else{var r=this.#n.get(t);r&&(this.#t.set(t,r.effect),this.#n.delete(t),r.fragment.lastChild.remove(),this.anchor.before(r.fragment),n=r.effect)}for(let[t,n]of this.#e){if(this.#e.delete(t),t===e)break;let r=this.#n.get(n);r&&(H(r.effect),this.#n.delete(n))}for(let[e,r]of this.#t){if(e===t||this.#r.has(e))continue;let i=()=>{if(Array.from(this.#e.values()).includes(e)){var t=document.createDocumentFragment();wn(r,t),t.append(L()),this.#n.set(e,{effect:r,fragment:t})}else H(r);this.#r.delete(e),this.#t.delete(e)};this.#i||!n?(this.#r.add(e),bn(r,i,!1)):i()}}};#o=e=>{this.#e.delete(e);let t=Array.from(this.#e.values());for(let[e,n]of this.#n)t.includes(e)||(H(n.effect),this.#n.delete(e))};ensure(e,t){var n=j,r=Zt();if(t&&!this.#t.has(e)&&!this.#n.has(e))if(r){var i=document.createDocumentFragment(),a=L();i.append(a),this.#n.set(e,{effect:V(()=>t(a)),fragment:i})}else this.#t.set(e,V(()=>t(this.anchor)));if(this.#e.set(n,e),r){for(let[t,r]of this.#t)t===e?n.unskip_effect(r):n.skip_effect(r);for(let[t,r]of this.#n)t===e?n.unskip_effect(r.effect):n.skip_effect(r.effect);n.oncommit(this.#a),n.ondiscard(this.#o)}else S&&(this.anchor=w),this.#a(n)}};function gr(e,t,n=!1){var r;S&&(r=w,ke());var i=new hr(e),a=n?ae:0;function o(e,t){if(S){var n=Me(r);if(e!==parseInt(n.substring(1))){var a=je();T(a),i.anchor=a,C(!1),i.ensure(e,t),C(!0);return}}i.ensure(e,t)}mn(()=>{var e=!1;t((t,n=0)=>{e=!0,o(n,t)}),e||o(-1,null)},a)}function _r(e,t,n,r,i){S&&ke();var a=t.$$slots?.[n],o=!1;a===!0&&(a=t[n===`default`?`children`:n],o=!0),a===void 0?i!==null&&i(e):a(e,o?()=>r:r)}function vr(e,t){un(()=>{var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector(`#`+t.hash)){let e=Qt(`style`);e.id=t.hash,e.textContent=t.code,r.appendChild(e)}})}var yr=[...`
3
- \r\f\xA0\v`];function br(e,t,n){var r=e==null?``:``+e;if(t&&(r=r?r+` `+t:t),n){for(var i of Object.keys(n))if(n[i])r=r?r+` `+i:i;else if(r.length)for(var a=i.length,o=0;(o=r.indexOf(i,o))>=0;){var s=o+a;(o===0||yr.includes(r[o-1]))&&(s===r.length||yr.includes(r[s]))?r=(o===0?``:r.substring(0,o))+r.substring(s+1):o=s}}return r===``?null:r}function xr(e,t,n,r,i,a){var o=e.__className;if(S||o!==n||o===void 0){var s=br(n,r,a);(!S||s!==e.getAttribute(`class`))&&(s==null?e.removeAttribute(`class`):t?e.className=s:e.setAttribute(`class`,s)),e.__className=n}else if(a&&i!==a)for(var c in a){var l=!!a[c];(i==null||l!==!!i[c])&&e.classList.toggle(c,l)}return a}var Sr=Symbol(`is custom element`),Cr=Symbol(`is html`),wr=he?`link`:`LINK`;function Tr(e,t,n,r){var i=Dr(e);S&&(i[t]=e.getAttribute(t),t===`src`||t===`srcset`||t===`href`&&e.nodeName===wr)||i[t]!==(i[t]=n)&&(t===`loading`&&(e[me]=n),n==null?e.removeAttribute(t):typeof n!=`string`&&kr(e).includes(t)?e[t]=n:e.setAttribute(t,n))}function Er(e,t,n){var r=W,i=q;let a=S;S&&C(!1),K(null),J(null);try{t!==`style`&&(Or.has(e.getAttribute(`is`)||e.nodeName)||!customElements||customElements.get(e.getAttribute(`is`)||e.nodeName.toLowerCase())?kr(e).includes(t):n&&typeof n==`object`)?e[t]=n:Tr(e,t,n==null?n:String(n))}finally{K(r),J(i),a&&C(!0)}}function Dr(e){return e.__attributes??={[Sr]:e.nodeName.includes(`-`),[Cr]:e.namespaceURI===r}}var Or=new Map;function kr(e){var t=e.getAttribute(`is`)||e.nodeName,n=Or.get(t);if(n)return n;Or.set(t,n=[]);for(var r,i=e,a=Element.prototype;a!==i;){for(var o in r=d(i),r)r[o].set&&n.push(o);i=m(i)}return n}function Ar(e,t,n,r){var i=!Le||(n&2)!=0,a=(n&8)!=0,o=(n&16)!=0,s=r,c=!0,l=()=>(c&&(c=!1,s=o?Un(r):r),s);let d;if(a){var f=fe in e||pe in e;d=u(e,t)?.set??(f&&t in e?n=>e[t]=n:void 0)}var p,m=!1;a?[p,m]=$e(()=>e[t]):p=e[t],p===void 0&&r!==void 0&&(p=l(),d&&(i&&Se(t),d(p)));var h=i?()=>{var n=e[t];return n===void 0?l():(c=!0,n)}:()=>{var n=e[t];return n!==void 0&&(s=void 0),n===void 0?s:n};if(i&&!(n&4))return h;if(d){var ee=e.$$legacy;return(function(e,t){return arguments.length>0?((!i||!t||ee||m)&&d(t?h():e),e):h()})}var g=!1,_=(n&1?wt:Et)(()=>(g=!1,h()));a&&$(_);var v=q;return(function(e,t){if(arguments.length>0){let n=t?$(_):i&&a?Vt(e):e;return I(_,n),g=!0,s!==void 0&&(s=n),e}return U&&g||v.f&16384?_.v:$(_)})}function jr(e){return new Mr(e)}var Mr=class{#e;#t;constructor(e){var t=new Map,n=(e,n)=>{var r=It(n,!1,!1);return t.set(e,r),r};let r=new Proxy({...e.props||{},$$events:{}},{get(e,r){return $(t.get(r)??n(r,Reflect.get(e,r)))},has(e,r){return r===pe?!0:($(t.get(r)??n(r,Reflect.get(e,r))),Reflect.has(e,r))},set(e,r,i){return I(t.get(r)??n(r,i),i),Reflect.set(e,r,i)}});this.#t=(e.hydrate?ur:lr)(e.component,{target:e.target,anchor:e.anchor,props:r,context:e.context,intro:e.intro??!1,recover:e.recover,transformError:e.transformError}),!Ie&&(!e?.props?.$$host||e.sync===!1)&&ct(),this.#e=r.$$events;for(let e of Object.keys(this.#t))e===`$set`||e===`$destroy`||e===`$on`||l(this,e,{get(){return this.#t[e]},set(t){this.#t[e]=t},enumerable:!0});this.#t.$set=e=>{Object.assign(r,e)},this.#t.$destroy=()=>{mr(this.#t)}}$set(e){this.#t.$set(e)}$on(e,t){this.#e[e]=this.#e[e]||[];let n=(...e)=>t.call(this,...e);return this.#e[e].push(n),()=>{this.#e[e]=this.#e[e].filter(e=>e!==n)}}$destroy(){this.#t.$destroy()}},Nr;typeof HTMLElement==`function`&&(Nr=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;$$shadowRoot=null;constructor(e,t,n){super(),this.$$ctor=e,this.$$s=t,n&&(this.$$shadowRoot=this.attachShadow(n))}addEventListener(e,t,n){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){let n=this.$$c.$on(e,t);this.$$l_u.set(t,n)}super.addEventListener(e,t,n)}removeEventListener(e,t,n){if(super.removeEventListener(e,t,n),this.$$c){let e=this.$$l_u.get(t);e&&(e(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){if(await Promise.resolve(),!this.$$cn||this.$$c)return;function e(e){return t=>{let n=Qt(`slot`);e!==`default`&&(n.name=e),ar(t,n)}}let t={},n=Fr(this);for(let r of this.$$s)r in n&&(r===`default`&&!this.$$d.children?(this.$$d.children=e(r),t.default=!0):t[r]=e(r));for(let e of this.attributes){let t=this.$$g_p(e.name);t in this.$$d||(this.$$d[t]=Pr(t,e.value,this.$$p_d,`toProp`))}for(let e in this.$$p_d)!(e in this.$$d)&&this[e]!==void 0&&(this.$$d[e]=this[e],delete this[e]);this.$$c=jr({component:this.$$ctor,target:this.$$shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=cn(()=>{fn(()=>{this.$$r=!0;for(let e of c(this.$$c)){if(!this.$$p_d[e]?.reflect)continue;this.$$d[e]=this.$$c[e];let t=Pr(e,this.$$d[e],this.$$p_d,`toAttribute`);t==null?this.removeAttribute(this.$$p_d[e].attribute||e):this.setAttribute(this.$$p_d[e].attribute||e,t)}this.$$r=!1})});for(let e in this.$$l)for(let t of this.$$l[e]){let n=this.$$c.$on(e,t);this.$$l_u.set(t,n)}this.$$l={}}}attributeChangedCallback(e,t,n){this.$$r||(e=this.$$g_p(e),this.$$d[e]=Pr(e,n,this.$$p_d,`toProp`),this.$$c?.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(e){return c(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Pr(e,t,n,r){let i=n[e]?.type;if(t=i===`Boolean`&&typeof t!=`boolean`?t!=null:t,!r||!n[e])return t;if(r===`toAttribute`)switch(i){case`Object`:case`Array`:return t==null?null:JSON.stringify(t);case`Boolean`:return t?``:null;case`Number`:return t??null;default:return t}else switch(i){case`Object`:case`Array`:return t&&JSON.parse(t);case`Boolean`:return t;case`Number`:return t==null?t:+t;default:return t}}function Fr(e){let t={};return e.childNodes.forEach(e=>{t[e.slot||`default`]=!0}),t}function Ir(e,t,n,r,i,a){let o=class extends Nr{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return c(t).map(e=>(t[e].attribute||e).toLowerCase())}};return c(t).forEach(e=>{l(o.prototype,e,{get(){return this.$$c&&e in this.$$c?this.$$c[e]:this.$$d[e]},set(n){n=Pr(e,n,t),this.$$d[e]=n;var r=this.$$c;r&&(u(r,e)?.get?r[e]=n:r.$set({[e]:n}))}})}),r.forEach(e=>{l(o.prototype,e,{get(){return this.$$c?.[e]}})}),a&&(o=a(o)),e.element=o,o}var Lr={name:`@htmlbricks/svelte-webcomponent`,private:!0,version:`0.71.35`,type:`module`,scripts:{dev:`vite --open`,build:`vite build`,"publish:wc":`node publish.ts`,"build:wc":`node build.ts`,"watch:wc":`node watch.ts`,preview:`vite preview`,check:`svelte-check --tsconfig ./tsconfig.app.json && tsc -p tsconfig.node.json`,"release:patch":`npm version patch && git push && git push --tags && npm run build:wc && npm run publish:wc`,"release:minor":`npm version minor && git push && git push --tags && npm run build:wc && npm run publish:wc`,"release:major":`npm version major && git push && git push --tags && npm run build:wc && npm run publish:wc`},devDependencies:{"@google-pay/button-element":`^3.2.1`,"@paypal/paypal-js":`^9.5.0`,"@sveltejs/vite-plugin-svelte":`^7.0.0`,"@tsconfig/svelte":`^5.0.8`,"@types/debounce":`^1.2.4`,"@types/node":`^24.10.1`,"@types/rgb-hex":`^3.0.0`,"chart.js":`^4.5.1`,"date-holidays":`^3.26.12`,dayjs:`^1.11.20`,"hls.js":`^1.6.15`,"html5-joystick-new":`^0.0.6`,ol:`^10.8.0`,"perfect-freehand":`^1.2.3`,prettier:`^3.8.1`,"rollup-plugin-terser":`^7.0.2`,"sass-embedded":`^1.98.0`,"simple-serverless-auth-client":`^0.0.6`,"simple-webrtc-element":`^0.0.1`,"simple-webrtc-element-whep":`^0.2.3`,"style-to-object":`^1.0.14`,svelte:`^5.55.0`,"svelte-check":`^4.4.5`,terser:`^5.46.1`,"ts-json-schema-generator":`^2.9.0`,typescript:`^6.0.2`,vite:`^8.0.3`},dependencies:{"@floating-ui/dom":`^1.7.6`,"@popperjs/core":`^2.11.8`,debounce:`^3.0.0`,"html-colors":`^0.0.6`,marked:`^17.0.5`,raphael:`^2.3.0`,"rgb-hex":`^4.1.0`,"wc-js-utils":`^0.5.4`}};function Rr(e){let t=e?.repoName.split(`/`)?.[1]||e?.repoName;if(!t)throw Error(`wrong componentPath `+e?.repoName);if(!e?.version)throw Error(`wrong version `+e?.version);let n=e?.iifePath||`main.iife.js`;if(!document.getElementById(t+`-script`)&&!customElements?.get?.(t)&&!window?.customElements?.get?.(t))try{let r=document.createElement(`script`);if(r.id=t+`-script`,r.src=`https://cdn.jsdelivr.net/npm/${e.repoName}@${e.version}/${n}`,e?.local)r.src=`${e.local}`;else if(location.href.includes(`localhost:6006`)){let e=t.split(`-`)[0];r.src=`http://localhost:6006/webcomponents/${t.replace(e+`-`,``)}/${n}`}document.head.appendChild(r)}catch(e){console.warn(e)}}var zr=rr(`<button type="button" class="hb-navbar__menu-btn svelte-6l0qqc"><!></button>`),Br=rr(`<img class="hb-navbar__brand-logo svelte-6l0qqc" alt=""/>`),Vr=rr(`<!> `,1),Hr=rr(`<hb-dropdown-simple><span slot="dropdownbutton" class="svelte-6l0qqc"><img class="hb-navbar__avatar svelte-6l0qqc" alt=""/></span></hb-dropdown-simple>`,2),Ur=rr(`<nav class="level is-mobile mb-0 py-2 px-3 hb-navbar svelte-6l0qqc" role="navigation"><div class="level-left svelte-6l0qqc"><div class="level-item is-flex is-align-items-center is-justify-content-flex-start hb-navbar__left svelte-6l0qqc" id="left_side" part="left-slot"><!> <span class="hb-navbar__slot is-clickable pl-2 svelte-6l0qqc" role="button" tabindex="0"><!></span></div></div> <div class="level-item has-text-centered hb-navbar__center svelte-6l0qqc" id="center_side" part="center-slot"><span class="hb-navbar__slot is-clickable svelte-6l0qqc" role="button" tabindex="0"><!></span> <!></div> <div class="level-right svelte-6l0qqc"><div class="level-item hb-navbar__right svelte-6l0qqc" id="rigth_side" part="right-slot"><div id="rigth_side_content" class="is-flex is-align-items-center is-justify-content-flex-end pr-2 svelte-6l0qqc"><!> <!></div></div></div></nav>`),Wr={hash:`svelte-6l0qqc`,code:`@charset "UTF-8";
3
+ \r\f\xA0\v`];function br(e,t,n){var r=e==null?``:``+e;if(t&&(r=r?r+` `+t:t),n){for(var i of Object.keys(n))if(n[i])r=r?r+` `+i:i;else if(r.length)for(var a=i.length,o=0;(o=r.indexOf(i,o))>=0;){var s=o+a;(o===0||yr.includes(r[o-1]))&&(s===r.length||yr.includes(r[s]))?r=(o===0?``:r.substring(0,o))+r.substring(s+1):o=s}}return r===``?null:r}function xr(e,t,n,r,i,a){var o=e.__className;if(S||o!==n||o===void 0){var s=br(n,r,a);(!S||s!==e.getAttribute(`class`))&&(s==null?e.removeAttribute(`class`):t?e.className=s:e.setAttribute(`class`,s)),e.__className=n}else if(a&&i!==a)for(var c in a){var l=!!a[c];(i==null||l!==!!i[c])&&e.classList.toggle(c,l)}return a}var Sr=Symbol(`is custom element`),Cr=Symbol(`is html`),wr=he?`link`:`LINK`;function Tr(e,t,n,r){var i=Dr(e);S&&(i[t]=e.getAttribute(t),t===`src`||t===`srcset`||t===`href`&&e.nodeName===wr)||i[t]!==(i[t]=n)&&(t===`loading`&&(e[me]=n),n==null?e.removeAttribute(t):typeof n!=`string`&&kr(e).includes(t)?e[t]=n:e.setAttribute(t,n))}function Er(e,t,n){var r=W,i=q;let a=S;S&&C(!1),K(null),J(null);try{t!==`style`&&(Or.has(e.getAttribute(`is`)||e.nodeName)||!customElements||customElements.get(e.getAttribute(`is`)||e.nodeName.toLowerCase())?kr(e).includes(t):n&&typeof n==`object`)?e[t]=n:Tr(e,t,n==null?n:String(n))}finally{K(r),J(i),a&&C(!0)}}function Dr(e){return e.__attributes??={[Sr]:e.nodeName.includes(`-`),[Cr]:e.namespaceURI===r}}var Or=new Map;function kr(e){var t=e.getAttribute(`is`)||e.nodeName,n=Or.get(t);if(n)return n;Or.set(t,n=[]);for(var r,i=e,a=Element.prototype;a!==i;){for(var o in r=d(i),r)r[o].set&&n.push(o);i=m(i)}return n}function Ar(e,t,n,r){var i=!Le||(n&2)!=0,a=(n&8)!=0,o=(n&16)!=0,s=r,c=!0,l=()=>(c&&(c=!1,s=o?Un(r):r),s);let d;if(a){var f=fe in e||pe in e;d=u(e,t)?.set??(f&&t in e?n=>e[t]=n:void 0)}var p,m=!1;a?[p,m]=$e(()=>e[t]):p=e[t],p===void 0&&r!==void 0&&(p=l(),d&&(i&&Se(t),d(p)));var h=i?()=>{var n=e[t];return n===void 0?l():(c=!0,n)}:()=>{var n=e[t];return n!==void 0&&(s=void 0),n===void 0?s:n};if(i&&!(n&4))return h;if(d){var ee=e.$$legacy;return(function(e,t){return arguments.length>0?((!i||!t||ee||m)&&d(t?h():e),e):h()})}var g=!1,_=(n&1?wt:Et)(()=>(g=!1,h()));a&&$(_);var v=q;return(function(e,t){if(arguments.length>0){let n=t?$(_):i&&a?Vt(e):e;return I(_,n),g=!0,s!==void 0&&(s=n),e}return U&&g||v.f&16384?_.v:$(_)})}function jr(e){return new Mr(e)}var Mr=class{#e;#t;constructor(e){var t=new Map,n=(e,n)=>{var r=It(n,!1,!1);return t.set(e,r),r};let r=new Proxy({...e.props||{},$$events:{}},{get(e,r){return $(t.get(r)??n(r,Reflect.get(e,r)))},has(e,r){return r===pe?!0:($(t.get(r)??n(r,Reflect.get(e,r))),Reflect.has(e,r))},set(e,r,i){return I(t.get(r)??n(r,i),i),Reflect.set(e,r,i)}});this.#t=(e.hydrate?ur:lr)(e.component,{target:e.target,anchor:e.anchor,props:r,context:e.context,intro:e.intro??!1,recover:e.recover,transformError:e.transformError}),!Ie&&(!e?.props?.$$host||e.sync===!1)&&ct(),this.#e=r.$$events;for(let e of Object.keys(this.#t))e===`$set`||e===`$destroy`||e===`$on`||l(this,e,{get(){return this.#t[e]},set(t){this.#t[e]=t},enumerable:!0});this.#t.$set=e=>{Object.assign(r,e)},this.#t.$destroy=()=>{mr(this.#t)}}$set(e){this.#t.$set(e)}$on(e,t){this.#e[e]=this.#e[e]||[];let n=(...e)=>t.call(this,...e);return this.#e[e].push(n),()=>{this.#e[e]=this.#e[e].filter(e=>e!==n)}}$destroy(){this.#t.$destroy()}},Nr;typeof HTMLElement==`function`&&(Nr=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;$$shadowRoot=null;constructor(e,t,n){super(),this.$$ctor=e,this.$$s=t,n&&(this.$$shadowRoot=this.attachShadow(n))}addEventListener(e,t,n){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){let n=this.$$c.$on(e,t);this.$$l_u.set(t,n)}super.addEventListener(e,t,n)}removeEventListener(e,t,n){if(super.removeEventListener(e,t,n),this.$$c){let e=this.$$l_u.get(t);e&&(e(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){if(await Promise.resolve(),!this.$$cn||this.$$c)return;function e(e){return t=>{let n=Qt(`slot`);e!==`default`&&(n.name=e),ar(t,n)}}let t={},n=Fr(this);for(let r of this.$$s)r in n&&(r===`default`&&!this.$$d.children?(this.$$d.children=e(r),t.default=!0):t[r]=e(r));for(let e of this.attributes){let t=this.$$g_p(e.name);t in this.$$d||(this.$$d[t]=Pr(t,e.value,this.$$p_d,`toProp`))}for(let e in this.$$p_d)!(e in this.$$d)&&this[e]!==void 0&&(this.$$d[e]=this[e],delete this[e]);this.$$c=jr({component:this.$$ctor,target:this.$$shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=cn(()=>{fn(()=>{this.$$r=!0;for(let e of c(this.$$c)){if(!this.$$p_d[e]?.reflect)continue;this.$$d[e]=this.$$c[e];let t=Pr(e,this.$$d[e],this.$$p_d,`toAttribute`);t==null?this.removeAttribute(this.$$p_d[e].attribute||e):this.setAttribute(this.$$p_d[e].attribute||e,t)}this.$$r=!1})});for(let e in this.$$l)for(let t of this.$$l[e]){let n=this.$$c.$on(e,t);this.$$l_u.set(t,n)}this.$$l={}}}attributeChangedCallback(e,t,n){this.$$r||(e=this.$$g_p(e),this.$$d[e]=Pr(e,n,this.$$p_d,`toProp`),this.$$c?.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(e){return c(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Pr(e,t,n,r){let i=n[e]?.type;if(t=i===`Boolean`&&typeof t!=`boolean`?t!=null:t,!r||!n[e])return t;if(r===`toAttribute`)switch(i){case`Object`:case`Array`:return t==null?null:JSON.stringify(t);case`Boolean`:return t?``:null;case`Number`:return t??null;default:return t}else switch(i){case`Object`:case`Array`:return t&&JSON.parse(t);case`Boolean`:return t;case`Number`:return t==null?t:+t;default:return t}}function Fr(e){let t={};return e.childNodes.forEach(e=>{t[e.slot||`default`]=!0}),t}function Ir(e,t,n,r,i,a){let o=class extends Nr{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return c(t).map(e=>(t[e].attribute||e).toLowerCase())}};return c(t).forEach(e=>{l(o.prototype,e,{get(){return this.$$c&&e in this.$$c?this.$$c[e]:this.$$d[e]},set(n){n=Pr(e,n,t),this.$$d[e]=n;var r=this.$$c;r&&(u(r,e)?.get?r[e]=n:r.$set({[e]:n}))}})}),r.forEach(e=>{l(o.prototype,e,{get(){return this.$$c?.[e]}})}),a&&(o=a(o)),e.element=o,o}var Lr={name:`@htmlbricks/svelte-webcomponent`,private:!0,version:`0.71.36`,type:`module`,scripts:{dev:`vite --open`,build:`vite build`,"publish:wc":`node publish.ts`,"build:wc":`node build.ts`,"watch:wc":`node watch.ts`,preview:`vite preview`,check:`svelte-check --tsconfig ./tsconfig.app.json && tsc -p tsconfig.node.json`,"release:patch":`npm version patch && git push && git push --tags && npm run build:wc && npm run publish:wc`,"release:minor":`npm version minor && git push && git push --tags && npm run build:wc && npm run publish:wc`,"release:major":`npm version major && git push && git push --tags && npm run build:wc && npm run publish:wc`},devDependencies:{"@google-pay/button-element":`^3.2.1`,"@paypal/paypal-js":`^9.5.0`,"@sveltejs/vite-plugin-svelte":`^7.0.0`,"@tsconfig/svelte":`^5.0.8`,"@types/debounce":`^1.2.4`,"@types/node":`^24.10.1`,"@types/rgb-hex":`^3.0.0`,"chart.js":`^4.5.1`,"date-holidays":`^3.26.12`,dayjs:`^1.11.20`,"hls.js":`^1.6.15`,"html5-joystick-new":`^0.0.6`,ol:`^10.8.0`,"perfect-freehand":`^1.2.3`,prettier:`^3.8.1`,"rollup-plugin-terser":`^7.0.2`,"sass-embedded":`^1.98.0`,"simple-serverless-auth-client":`^0.0.6`,"simple-webrtc-element":`^0.0.1`,"simple-webrtc-element-whep":`^0.2.3`,"style-to-object":`^1.0.14`,svelte:`^5.55.0`,"svelte-check":`^4.4.5`,terser:`^5.46.1`,"ts-json-schema-generator":`^2.9.0`,typescript:`^6.0.2`,vite:`^8.0.3`},dependencies:{"@floating-ui/dom":`^1.7.6`,"@popperjs/core":`^2.11.8`,debounce:`^3.0.0`,"html-colors":`^0.0.6`,marked:`^17.0.5`,raphael:`^2.3.0`,"rgb-hex":`^4.1.0`,"wc-js-utils":`^0.5.4`}};function Rr(e){let t=e?.repoName.split(`/`)?.[1]||e?.repoName;if(!t)throw Error(`wrong componentPath `+e?.repoName);if(!e?.version)throw Error(`wrong version `+e?.version);let n=e?.iifePath||`main.iife.js`;if(!document.getElementById(t+`-script`)&&!customElements?.get?.(t)&&!window?.customElements?.get?.(t))try{let r=document.createElement(`script`);if(r.id=t+`-script`,r.src=`https://cdn.jsdelivr.net/npm/${e.repoName}@${e.version}/${n}`,e?.local)r.src=`${e.local}`;else if(location.href.includes(`localhost:6006`)){let e=t.split(`-`)[0];r.src=`http://localhost:6006/webcomponents/${t.replace(e+`-`,``)}/${n}`}document.head.appendChild(r)}catch(e){console.warn(e)}}var zr=rr(`<button type="button" class="hb-navbar__menu-btn svelte-6l0qqc"><!></button>`),Br=rr(`<img class="hb-navbar__brand-logo svelte-6l0qqc" alt=""/>`),Vr=rr(`<!> `,1),Hr=rr(`<hb-dropdown-simple><span slot="dropdownbutton" class="svelte-6l0qqc"><img class="hb-navbar__avatar svelte-6l0qqc" alt=""/></span></hb-dropdown-simple>`,2),Ur=rr(`<nav class="level is-mobile mb-0 py-2 px-3 hb-navbar svelte-6l0qqc" role="navigation"><div class="level-left svelte-6l0qqc"><div class="level-item is-flex is-align-items-center is-justify-content-flex-start hb-navbar__left svelte-6l0qqc" id="left_side" part="left-slot"><!> <span class="hb-navbar__slot is-clickable pl-2 svelte-6l0qqc" role="button" tabindex="0"><!></span></div></div> <div class="level-item has-text-centered hb-navbar__center svelte-6l0qqc" id="center_side" part="center-slot"><span class="hb-navbar__slot is-clickable svelte-6l0qqc" role="button" tabindex="0"><!></span> <!></div> <div class="level-right svelte-6l0qqc"><div class="level-item hb-navbar__right svelte-6l0qqc" id="rigth_side" part="right-slot"><div id="rigth_side_content" class="is-flex is-align-items-center is-justify-content-flex-end pr-2 svelte-6l0qqc"><!> <!></div></div></div></nav>`),Wr={hash:`svelte-6l0qqc`,code:`@charset "UTF-8";
4
4
  /*!
5
5
  * Bulma 1.x for hb-navbar — navbar surface, buttons, flex helpers.
6
6
  */:host {--bulma-hb-def-control-radius: var(--bulma-radius, var(--bulma-hb-def-radius));--bulma-hb-def-control-radius-small: var(--bulma-radius-small, var(--bulma-hb-def-radius-small));--bulma-hb-def-control-border-width: 1px;--bulma-hb-def-control-height: 2.5em;--bulma-hb-def-control-line-height: 1.5;--bulma-hb-def-control-padding-vertical: calc(0.5em - 1px);--bulma-hb-def-control-padding-horizontal: calc(0.75em - 1px);--bulma-hb-def-control-size: var(--bulma-size-normal, var(--bulma-hb-def-size-normal));--bulma-hb-def-control-focus-shadow-l: 50%;}