@quickwatch/preview 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,29 @@
1
- /* @quickwatch/preview 0.2.0. Roboto Flex: SIL Open Font License, dist/fonts/RobotoFlex-OFL.txt */
2
- "use strict";var QuickWatch=(()=>{var kn=Object.defineProperty;var sl=Object.getOwnPropertyDescriptor;var il=Object.getOwnPropertyNames;var al=Object.prototype.hasOwnProperty;var ss=e=>{throw TypeError(e)};var ll=(e,t,n)=>t in e?kn(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var cl=(e,t)=>{for(var n in t)kn(e,n,{get:t[n],enumerable:!0})},pl=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of il(t))!al.call(e,o)&&o!==n&&kn(e,o,{get:()=>t[o],enumerable:!(r=sl(t,o))||r.enumerable});return e};var ul=e=>pl(kn({},"__esModule",{value:!0}),e);var C=(e,t,n)=>ll(e,typeof t!="symbol"?t+"":t,n),Mr=(e,t,n)=>t.has(e)||ss("Cannot "+n);var f=(e,t,n)=>(Mr(e,t,"read from private field"),n?n.call(e):t.get(e)),_=(e,t,n)=>t.has(e)?ss("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),v=(e,t,n,r)=>(Mr(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),L=(e,t,n)=>(Mr(e,t,"access private method"),n);var is=(e,t,n,r)=>({set _(o){v(e,t,o,n)},get _(){return f(e,t,r)}});var mu={};cl(mu,{devices:()=>rl,link:()=>ts,render:()=>ns,themes:()=>fu,version:()=>du,widget:()=>Ka});var dl=/\p{L}/u,fl=/[\p{L}\p{Nd}]/u,ls=/^[\x00-\x7f]*$/;function yt(e){let t=e.charCodeAt(0);return t<128?t>=65&&t<=90||t>=97&&t<=122:dl.test(e)}function cs(e){let t=e.charCodeAt(0);return t<128?t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122:fl.test(e)}function Pe(e){let t=e.charCodeAt(0);return t>=48&&t<=57}function Qe(e){return e===32||e>=9&&e<=13?!0:e<133?!1:e===133||e===160||e===5760||e>=8192&&e<=8202||e===8232||e===8233||e===8239||e===8287||e===12288}function U(e){let t=0,n=e.length;for(;t<n&&Qe(e.charCodeAt(t));)t++;for(;n>t&&Qe(e.charCodeAt(n-1));)n--;return t===0&&n===e.length?e:e.slice(t,n)}function Ke(e){if(!e)return!0;for(let t=0;t<e.length;t++)if(!Qe(e.charCodeAt(t)))return!1;return!0}function hl(e){return e===304||e===305?e:e>=8064&&e<=8071||e>=8080&&e<=8087||e>=8096&&e<=8103?e+8:e===8115||e===8131||e===8179?e+9:null}function as(e){return e===411||e===42972||e===612||e===42955||e===7305||e===7306||e>=68944&&e<=68997}function ps(e,t,n){let r="";for(let o of e){let s=o.codePointAt(0),i=n(s);if(i!==null){r+=String.fromCodePoint(i);continue}let a=t(o),l=a.length===o.length||[...a].length===1;r+=l&&!as(s)&&!as(a.codePointAt(0))?a:o}return r}function Tn(e){return ls.test(e)?e.toUpperCase():ps(e,t=>t.toUpperCase(),hl)}function et(e){return ls.test(e)?e.toLowerCase():ps(e,t=>t.toLowerCase(),t=>t===304||t===305?t:null)}function Lr(e,t){return e===t||Tn(e)===Tn(t)}function us(e){let t=0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);if(r>=55296&&r<=56319&&n+1<e.length){let o=e.charCodeAt(n+1);o>=56320&&o<=57343&&n++}t++}return t}function ds(e,t){let n=0;for(let r=0;r<t&&n<e.length;r++){let o=e.charCodeAt(n);n+=o>=55296&&o<=56319&&n+1<e.length&&(e.charCodeAt(n+1)&64512)===56320?2:1}return n>=e.length?e:e.slice(0,n)}var Rr={UTC:"Etc/UTC","GMT Standard Time":"Europe/London","Greenwich Standard Time":"Atlantic/Reykjavik","W. Europe Standard Time":"Europe/Berlin","Central Europe Standard Time":"Europe/Budapest","Romance Standard Time":"Europe/Paris","Central European Standard Time":"Europe/Warsaw","E. Europe Standard Time":"Europe/Chisinau","FLE Standard Time":"Europe/Kiev","GTB Standard Time":"Europe/Bucharest","Russian Standard Time":"Europe/Moscow","Turkey Standard Time":"Europe/Istanbul","Israel Standard Time":"Asia/Jerusalem","Egypt Standard Time":"Africa/Cairo","South Africa Standard Time":"Africa/Johannesburg","W. Central Africa Standard Time":"Africa/Lagos","E. Africa Standard Time":"Africa/Nairobi","Morocco Standard Time":"Africa/Casablanca","Arabian Standard Time":"Asia/Dubai","Arab Standard Time":"Asia/Riyadh","Iran Standard Time":"Asia/Tehran","Pakistan Standard Time":"Asia/Karachi","India Standard Time":"Asia/Calcutta","Nepal Standard Time":"Asia/Katmandu","Bangladesh Standard Time":"Asia/Dhaka","SE Asia Standard Time":"Asia/Bangkok","China Standard Time":"Asia/Shanghai","Singapore Standard Time":"Asia/Singapore","Taipei Standard Time":"Asia/Taipei","Tokyo Standard Time":"Asia/Tokyo","Korea Standard Time":"Asia/Seoul","W. Australia Standard Time":"Australia/Perth","Cen. Australia Standard Time":"Australia/Adelaide","AUS Central Standard Time":"Australia/Darwin","AUS Eastern Standard Time":"Australia/Sydney","E. Australia Standard Time":"Australia/Brisbane","Tasmania Standard Time":"Australia/Hobart","New Zealand Standard Time":"Pacific/Auckland","Hawaiian Standard Time":"Pacific/Honolulu","Alaskan Standard Time":"America/Anchorage","Pacific Standard Time":"America/Los_Angeles","US Mountain Standard Time":"America/Phoenix","Mountain Standard Time":"America/Denver","Central Standard Time":"America/Chicago","Central America Standard Time":"America/Guatemala","Central Standard Time (Mexico)":"America/Mexico_City","Canada Central Standard Time":"America/Regina","Eastern Standard Time":"America/New_York","US Eastern Standard Time":"America/Indianapolis","SA Pacific Standard Time":"America/Bogota","Atlantic Standard Time":"America/Halifax","Newfoundland Standard Time":"America/St_Johns","E. South America Standard Time":"America/Sao_Paulo","Argentina Standard Time":"America/Buenos_Aires","Pacific SA Standard Time":"America/Santiago","SA Western Standard Time":"America/La_Paz","Venezuela Standard Time":"America/Caracas"},Sn=new Map;function An(e){if(!e||e.trim()==="")return null;let t=Sn.get(e);return t!==void 0||(t=fs(e)?e:Object.hasOwn(Rr,e)&&fs(Rr[e])?Rr[e]:null,Sn.size>256&&Sn.clear(),Sn.set(e,t)),t}function tt(e){return An(e)??"UTC"}function fs(e){try{return new Intl.DateTimeFormat("en-US",{timeZone:e}),!0}catch{return!1}}var Bt=864e5;function ml(e,t,n){let r=t<=2?e-1:e,o=Math.floor(r/400),s=r-o*400,i=(t+9)%12,a=Math.floor((153*i+2)/5)+n-1,l=s*365+Math.floor(s/4)-Math.floor(s/100)+a;return o*146097+l-719468}function Ft(e,t,n,r=0,o=0,s=0,i=0){return ml(e,t,n)*Bt+r*36e5+o*6e4+s*1e3+i}function Pr(e){let t=Math.floor(e/Bt),n=Math.floor(e-t*Bt),r=t+719468,o=Math.floor(r/146097),s=r-o*146097,i=Math.floor((s-Math.floor(s/1460)+Math.floor(s/36524)-Math.floor(s/146096))/365),a=s-(365*i+Math.floor(i/4)-Math.floor(i/100)),l=Math.floor((5*a+2)/153),c=a-Math.floor((153*l+2)/5)+1,p=l<10?l+3:l-9,d=i+o*400+(p<=2?1:0),b=Math.floor(n/36e5);n-=b*36e5;let y=Math.floor(n/6e4);n-=y*6e4;let m=Math.floor(n/1e3);return{year:d,month:p,day:c,hour:b,minute:y,second:m,millisecond:n-m*1e3,dayOfWeek:(t%7+11)%7}}function hs(e,t){return t===2?e%4===0&&e%100!==0||e%400===0?29:28:t===4||t===6||t===9||t===11?30:31}var Ut=-621355968e5,Ht=0xe677d21fdbff,On=new Map,gl={formatter:null,offsets:new Map};function ms(e){let t=On.get(e);if(t)return t;let n=tt(e);return t=n==="UTC"||n==="Etc/UTC"?gl:{formatter:new Intl.DateTimeFormat("en-US",{timeZone:n,hourCycle:"h23",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),offsets:new Map},On.size>256&&On.clear(),On.set(e,t),t}function Vt(e,t){let n=ms(e);if(!n.formatter)return 0;let r=Math.floor(t/6e4),o=n.offsets.get(r);if(o!==void 0)return o;let s=1970,i=1,a=1,l=0,c=0,p=0;for(let b of n.formatter.formatToParts(r*6e4))switch(b.type){case"year":s=Number(b.value);break;case"month":i=Number(b.value);break;case"day":a=Number(b.value);break;case"hour":l=Number(b.value)%24;break;case"minute":c=Number(b.value);break;case"second":p=Number(b.value);break}let d=Ft(s,i,a,l,c,p)-r*6e4;return n.offsets.size>4096&&n.offsets.clear(),n.offsets.set(r,d),d}function _n(e,t){return Pr(Math.min(Ht,Math.max(Ut,e+Vt(t,e))))}function En(e,t){if(!ms(t).formatter)return e;let n=Vt(t,e-Bt/2),r=Vt(t,e+Bt/2);if(n===r)return e-n;let o=Vt(t,e-n)===n,s=Vt(t,e-r)===r;return o!==s?e-(o?n:r):e-Math.min(n,r)}var Mn=String.raw`(?:[Tt ]\s*(\d{1,2}):(\d{2})(?::(\d{2})(?:[.,](\d{1,9}))?)?\s*([AaPp][Mm])?)?`,Ln=String.raw`\s*([Zz]|UTC|GMT|[+-]\d{2}(?::?\d{2})?)?`,bl=new RegExp(String.raw`^(\d{4})[-/](\d{1,2})[-/](\d{1,2})${Mn}${Ln}$`),wl=new RegExp(String.raw`^(?:[A-Za-z]+,?\s+)?(\d{1,2})[\s-]+([A-Za-z]{3,9})\.?[\s-]+(\d{4})${Mn}${Ln}$`),yl=new RegExp(String.raw`^(?:[A-Za-z]+,?\s+)?([A-Za-z]{3,9})\.?\s+(\d{1,2}),?\s+(\d{4})${Mn}${Ln}$`),vl=new RegExp(String.raw`^(\d{1,2})/(\d{1,2})/(\d{4})${Mn}${Ln}$`),xl=/^([A-Za-z]{3,9})\.?,?\s+(\d{4})$/,kl=/^(\d{4})\s+([A-Za-z]{3,9})\.?$/,Tl=/(^|\s)(\d{1,2})\s*([AaPp][Mm])(?=\s|$)/,Sl=/^(\d{1,2}:\d{2}(?::\d{2})?(?:\s*[AaPp][Mm])?)\s+(\d{4}-\d{1,2}-\d{1,2})$/,Al=["january","february","march","april","may","june","july","august","september","october","november","december"],gs=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function Nr(e){let t=e.toLowerCase(),n=Al.findIndex(r=>r===t||t.length===3&&r.startsWith(t));return n<0?null:n+1}function ws(e,t){let n=Ol(e.replace(Tl,"$1$2:00 $3").replace(Sl,"$2 $1"),t);return n===null||n<Ut||n>Ht?null:n}function Ol(e,t){let n=bl.exec(e);if(n)return Wt(n[1],n[2],n[3],n,4,t);if(n=wl.exec(e),n){let o=Nr(n[2]);return o===null?null:Wt(n[3],String(o),n[1],n,4,t)}if(n=yl.exec(e),n){let o=Nr(n[1]);return o===null?null:Wt(n[3],String(o),n[2],n,4,t)}if(n=vl.exec(e),n)return Wt(n[3],n[1],n[2],n,4,t);n=xl.exec(e);let r=n?[n[1],n[2]]:(n=kl.exec(e))?[n[2],n[1]]:null;if(r){let o=Nr(r[0]);return o===null?null:Wt(r[1],String(o),"1",[],0,t)}return null}function Wt(e,t,n,r,o,s){let i=Number(e),a=Number(t),l=Number(n);if(i<1||a<1||a>12||l<1||l>hs(i,a))return null;let c=Number(r[o]??0),p=Number(r[o+1]??0),d=Number(r[o+2]??0),b=Number((r[o+3]??"").padEnd(3,"0").slice(0,3)),y=(r[o+4]??"").toLowerCase();if(y==="am"){if(c===12)c=0;else if(c>12)return null}if(y==="pm"){if(c<12)c+=12;else if(c>12)return null}if(c>23||p>59||d>59)return null;let m=Ft(i,a,l,c,p,d,b),T=r[o+5];if(T===void 0)return En(m,s);if(T==="Z"||T==="z"||T==="UTC"||T==="GMT")return m;let E=T.slice(1).replace(":",""),O=Number(E.slice(0,2)),j=E.length>2?Number(E.slice(2)):0;if(O>14||j>59)return null;let w=(O*60+j)*6e4;return T[0]==="-"?m+w:m-w}var _l=new Set(["yyyy","yy","MMMM","MMM","MM","M","dddd","ddd","dd","d","HH","H","hh","h","mm","m","ss","s","tt"]);function $r(e){if(e.length===0||e.length===1&&yt(e))return!1;let t=0;for(;t<e.length;){let n=e[t];if(n==="'"||n==='"'){let o=e.indexOf(n,t+1);if(o<0)return!1;t=o+1;continue}if(n==="\\"){if(t+1>=e.length)return!1;t+=2;continue}if(n==="%")return!1;if(!yt(n)){t++;continue}let r=1;for(;t+r<e.length&&e[t+r]===n;)r++;if(!_l.has(e.slice(t,t+r)))return!1;t+=r}return!0}var nt=e=>e<10?"0"+e:String(e);function ys(e,t,n){let r=_n(e,t),o="",s=0;for(;s<n.length;){let i=n[s];if(i==="'"||i==='"'){let c=n.indexOf(i,s+1);o+=n.slice(s+1,c),s=c+1;continue}if(i==="\\"){o+=n[s+1]??"",s+=2;continue}if(!yt(i)){o+=i,s++;continue}let a=1;for(;s+a<n.length&&n[s+a]===i;)a++;let l=r.hour%12===0?12:r.hour%12;switch(n.slice(s,s+a)){case"yyyy":o+=String(r.year).padStart(4,"0");break;case"yy":o+=nt(r.year%100);break;case"MMMM":o+=bs[r.month-1];break;case"MMM":o+=bs[r.month-1].slice(0,3);break;case"MM":o+=nt(r.month);break;case"M":o+=r.month;break;case"dddd":o+=gs[r.dayOfWeek];break;case"ddd":o+=gs[r.dayOfWeek].slice(0,3);break;case"dd":o+=nt(r.day);break;case"d":o+=r.day;break;case"HH":o+=nt(r.hour);break;case"H":o+=r.hour;break;case"hh":o+=nt(l);break;case"h":o+=l;break;case"mm":o+=nt(r.minute);break;case"m":o+=r.minute;break;case"ss":o+=nt(r.second);break;case"s":o+=r.second;break;case"tt":o+=r.hour<12?"AM":"PM";break}s+=a}return o}var bs=["January","February","March","April","May","June","July","August","September","October","November","December"];var Ie=6e4,vs=36e5,jr=864e5,xs=365e4*jr,El=/^(?:now\s*)?([+-])\s*((?:\d+(?:\.\d+)?(?:ms|s|m|h|d)\s*)+)$/i,Ml=/\d+(?:\.\d+)?(?:ms|s|m|h|d)/gi,Ll=/^(\d{1,2}):(\d{2})(?::(\d{2}))?$/,Rl=/^\d{4}[-/]\d{1,2}[-/]\d{1,2}|\p{L}.*\d|\d.*\p{L}/u,Pl=/^(\d+(?:\.\d+)?)\s*(ms|s|m|h|d)?$/i;function ks(e,t,n){if(Ke(e))return null;let r=U(e);if(r.length===3&&r.toLowerCase()==="now")return t;let o=El.exec(r);if(o){let i=0;for(let l of o[2].matchAll(Ml)){let c=Nl(l[0]);if(c===null||c>xs-i)return null;i+=c}let a=o[1]==="-"?t-i:t+i;return a<Ut||a>Ht?null:a}let s=Ll.exec(r);if(s){let i=Number(s[1]),a=Number(s[2]),l=Number(s[3]??0);if(i>23||a>59||l>59)return null;let c=_n(t,n);return En(Ft(c.year,c.month,c.day,i,a,l),n)}return Rl.test(r)?ws(r,n):null}function Nl(e){if(Ke(e))return null;let t=Pl.exec(U(e));if(!t)return null;let n=Number(t[1]),r=(t[2]??"").toLowerCase(),o=n*(r==="ms"?.001:r==="m"?60:r==="h"?3600:r==="d"?86400:1);return Number.isFinite(o)&&o<=xs/1e3?o*1e3:null}var fe=(e,t)=>String(e).padStart(t,"0");function qt(e){let t=Pr(Math.floor(e)),n=`${fe(t.year,4)}-${fe(t.month,2)}-${fe(t.day,2)}T${fe(t.hour,2)}:${fe(t.minute,2)}:${fe(t.second,2)}`;return t.millisecond!==0?`${n}.${fe(t.millisecond,3)}Z`:n+"Z"}function Ts(e,t,n,r=!1){let o=e-t;if(r){let i=Math.ceil(o/Ie);if(i>0)return Gt(i*Ie);if(n)return"0:00";let a=-i*Ie;return a<Ie?"Now":`${Gt(a)} ago`}if(n){let i=Math.max(0,Math.ceil(o/1e3)),a=Math.floor(i/3600),l=Math.floor(i%3600/60),c=i%60;return a>0?`${a}:${fe(l,2)}:${fe(c,2)}`:`${l}:${fe(c,2)}`}let s=Math.floor(o/1e3);if(s<=0){let i=-s*1e3;return i<Ie?"Now":`${Gt(i)} ago`}return s<180?`${Math.floor(s/60)}:${fe(s%60,2)}`:Gt(s*1e3)}function Ss(e,t,n=!1){let r=e-t,o=r<0,s=o?-r:r;if(s<Ie)return"now";let i=Gt(s);return n?o?"-"+i:i:o?`${i} ago`:`in ${i}`}function Gt(e){if(e<vs)return`${Math.floor(e/Ie)} min`;if(e<jr){let t=Math.floor(e/Ie)%60,n=Math.floor(e/vs);return t===0?`${n} h`:`${n} h ${t} min`}return`${Math.floor(e/jr)} d`}var Je="--";function Rn(e,t){if(!Number.isFinite(e)||Math.abs(e)>=1e16)return e;let n=10**t,r=e*n,o=Math.floor(r),s=r-o;return(s>.5||s===.5&&o%2!==0)&&(o+=1),o===0?r<0||Object.is(r,-0)?-0:0:o/n}function zr(e){return Object.is(e,-0)?"-0":String(e)}function G(e){return zr(Rn(e,2))}function Ne(e){if(Number.isNaN(e))return"NaN";if(!Number.isFinite(e))return e>0?"\u221E":"-\u221E";let t=e<0||Object.is(e,-0),[n,r]=Math.abs(e).toExponential(14).split("e"),o=n.replace(".",""),s=Number(r)+1,i=s>0?o.padEnd(s+2,"0"):"0".repeat(1-s)+o,a=s>0?s:1,l=BigInt(i.slice(0,a+1)||"0");(i[a+1]??"0")>="5"&&(l+=1n);let c=l/10n,p=l%10n,d=p===0n?`${c}`:`${c}.${p}`;return t?"-"+d:d}function Cr(e,t){return e==null?"":t!=null&&e.length>t?e.slice(0,Math.max(0,t-1))+"\u2026":e}function Os(e,t,n,r){return e==null?Je:Ts(e,t,n,r)}function Pn(e,t){let n=Math.floor((t-e)/6e4);return n<1?"Updated just now":`Updated ${$l(n)} ago`}function $l(e){return e<60?`${e} min`:e<1440?e%60===0?`${Math.trunc(e/60)} h`:`${Math.trunc(e/60)} h ${e%60} min`:`${Math.trunc(e/1440)} d`}function Nn(e,t,n){return t===0&&n===100?`${Ne(e)}%`:`${Ne(e)}/${Ne(n)}`}function $n(e){let t=new Date(e),n=(r,o=2)=>String(r).padStart(o,"0");return`${n(t.getUTCFullYear(),4)}-${n(t.getUTCMonth()+1)}-${n(t.getUTCDate())}T${n(t.getUTCHours())}:${n(t.getUTCMinutes())}:${n(t.getUTCSeconds())}.${n(t.getUTCMilliseconds(),3)}0000+00:00`}var As=new Map;function _s(e,t){let n=As.get(t);n||(n=new Intl.DateTimeFormat("en-US",{timeZone:tt(t),hourCycle:"h23",hour:"numeric",minute:"2-digit",weekday:"short",day:"numeric"}),As.set(t,n));let r={};for(let o of n.formatToParts(e))r[o.type]=o.value;return{hour:Number(r.hour)%24,minute:Number(r.minute),weekday:r.weekday??"",day:Number(r.day)}}function jn(e,t){let{hour:n,minute:r}=_s(e,t);return`${n}:${String(r).padStart(2,"0")}`}function Es(e,t){let{weekday:n,day:r}=_s(e,t);return`${n} ${r}`.toUpperCase()}var le={version:1,insets:{safePercent:14.64,tileHorizontalPercent:7.1,screenHorizontalPercent:5.2,screenTopPercent:13,screenBottomPercent:23},spacing:{xxs:2,xs:4,s:6,m:8,l:12,xl:16},radius:{rounded:{extraSmall:4,small:8,medium:18,large:26,extraLarge:36,full:999},sharp:{extraSmall:0,small:2,medium:3,large:4,extraLarge:6,full:8},pill:{extraSmall:8,small:12,medium:999,large:999,extraLarge:999,full:999}},sizes:{chipHeight:52,compactChipHeight:32,listRowMinHeight:52,iconSmall:18,iconMedium:24,iconLarge:32,progressRingStroke:8,progressBarHeight:8,toggleWidth:32,toggleHeight:22,frameBezelPercent:7,edgeButtonHeight:46,edgeButtonWidthPercent:48,tileButtonSize:65,curvedTextInset:16,confirmButtonSize:60,progressRingSize:84,tileRingStroke:8,toggleThumb:18,statusDot:10,statusIcon:28,badgeHeight:18,toastHeight:32,skeletonLine:12,scrollIndicatorWidth:6,scrollIndicatorLength:50,scrollIndicatorGap:3,scrollIndicatorEdgePadding:2,rangedStroke:3,complicationPercent:25,longComplicationWidthPercent:64,largeScreenMinWidth:225,buttonPaddingX:14,buttonPaddingY:6,buttonIconSpacing:6,buttonIcon:26,switchPaddingY:8,toggleThumbOff:12,toggleTrackBorder:2,toggleSpacing:6,listHeaderMinHeight:48,listHeaderPaddingX:14,listHeaderPaddingTop:16,listHeaderPaddingBottom:12,progressRingStrokeSmallScreen:5,scrollIndicatorWidthSmallScreen:5,edgeButtonWidthPercentSmallScreen:52,edgeButtonBottom:3,edgeButtonTopMargin:4,edgeButtonTopRadius:17,confirmButtonWidth:63,confirmButtonHeight:54,tileHeaderIcon:24,tileTitleTop:3,tileTitleBottom:6,tileTitleBottomSmallScreen:4,tileIconTitleSpacing:4,tileIconTitleSpacingSmallScreen:2,tileTitleSidePercent:14.5,tileMarginNoEdgePercent:10,tileBottomNoEdgePercent:16.64},effects:{edgeScaleSmall:.7,edgeScaleLarge:.6,edgeAlpha:.5,edgeMinElementHeightSmall:.2,edgeMinElementHeightLarge:.15,edgeMaxElementHeightSmall:.6,edgeMaxElementHeightLarge:.45,edgeMinTransitionAreaSmall:.35,edgeMinTransitionAreaLarge:.4,edgeMaxTransitionAreaSmall:.55,edgeMaxTransitionAreaLarge:.6,edgeSpecSmallScreenWidth:192,edgeSpecLargeScreenWidth:240},font:{family:"'Roboto Flex', Roboto, 'Google Sans', 'Segoe UI', system-ui, sans-serif",numeralFamily:"'Roboto Flex', Roboto, 'Google Sans', 'Segoe UI', system-ui, sans-serif"},typeScale:{display:{size:30,lineHeight:34,weight:520,letterSpacing:.2,width:110},numeral:{size:40,lineHeight:40,weight:580,letterSpacing:0,width:100},title:{size:16,lineHeight:18,weight:550,letterSpacing:.4,width:110},label:{size:15,lineHeight:18,weight:500,letterSpacing:.4,width:110},body:{size:14,lineHeight:16,weight:450,letterSpacing:.4,width:110},labelSmall:{size:13,lineHeight:16,weight:500,letterSpacing:.4,width:110},caption:{size:12,lineHeight:14,weight:500,letterSpacing:.4,width:110},timeText:{size:15,lineHeight:18,weight:599,letterSpacing:.6,width:100},tileTitle:{size:14,lineHeight:16,weight:500,letterSpacing:.4,width:110},faceTime:{size:44,lineHeight:48,weight:400,letterSpacing:0,width:100}},colors:{ambient:{background:"#000000",surface:"#000000",onSurface:"#B0B0B0",onSurfaceVariant:"#8A8A8A",outline:"#6A6A6A",onAccent:"#B0B0B0",timeText:"#B0B0B0",scrollThumb:"#8A8A8A",scrollTrack:"#303030",warningText:"#8A8A8A"}},limits:{textMaxLines:3,screenListMaxRows:10,tileListMaxRows:3,tileCompactListMaxRows:8,tileCompactListMaxRowsSmallScreen:6,tileMaxButtons:2,tileMaxToggles:1,minPollSeconds:60,tileMinRefreshSeconds:60}};function zn(e){return{...e,widthDp:e.widthPx/e.density,heightDp:e.heightPx/e.density,isRound:e.shape==="round"}}function Ns(e,t){let n=t.tileTheme;return n?{...e,shape:n.corners?e.shape:{corners:"rounded"},type:{weight:n.typeWeight?e.type.weight:0,width:n.typeWidth?e.type.width:0}}:e}var Ms=(e,t,n)=>Math.min(Math.max(e,t),n),Ls="SmallScreen",Rs="Percent";function Jr(e,t=le){return e.widthDp<(t.sizes.largeScreenMinWidth??225)}function Cn(e,t=le){let n=Jr(e,t),r={};for(let[o,s]of Object.entries(t.sizes)){if(o.endsWith(Ls))continue;let i=t.sizes[o+Ls];r[o]=n&&i!==void 0?i:s}return r}function vt(e,t){return Math.ceil(Rn(e.widthDp*t/100,4))}var jl=(e,t)=>(Math.ceil(e*t*1900/2048)+Math.ceil(e*t*500/2048))/t,Zt=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();function $s(e,t,n,r=le){let o="",s=(y,m)=>{o+=`--wb-${y}:${G(m)}px;`},i=(y,m)=>{o+=`--wb-${y}:${m};`},a=Cn(e,r);s("width",e.widthDp),s("height",e.heightDp),i("radius-screen",e.isRound?"50%":"0px"),s("inset-safe",e.isRound?vt(e,r.insets.safePercent):0),s("pad-x",vt(e,r.insets.screenHorizontalPercent)),s("tile-pad-x",vt(e,r.insets.tileHorizontalPercent)),s("pad-top",vt(e,r.insets.screenTopPercent)),s("pad-bottom",vt(e,r.insets.screenBottomPercent)),s("bezel",e.widthDp*(a.frameBezelPercent??7)/100);for(let[y,m]of Object.entries(r.spacing))s(`space-${Zt(y)}`,m);let l=r.radius[t.shape.corners]??r.radius.rounded??{};for(let[y,m]of Object.entries(l))s(`radius-${Zt(y)}`,m);for(let[y,m]of Object.entries(a))y.endsWith(Rs)?y!=="frameBezelPercent"&&s(Zt(y.slice(0,-Rs.length)),vt(e,m)):s(Zt(y),m);let c=Dr(e,a.listRowMinHeight??52,r);i("edge-scale",G(c.scale)),i("edge-opacity",G(c.alpha)),s("edge-zone",c.zoneDp);for(let[y,m]of Object.entries(r.typeScale)){let T=Zt(y);s(`type-${T}-size`,m.size);let E=Math.max(m.lineHeight,jl(m.size,e.density));s(`type-${T}-line`,E),s(`type-${T}-pitch`,m.lineHeight),s(`type-${T}-lead`,(E-m.lineHeight)/2),i(`type-${T}-weight`,String(Ms(m.weight+t.type.weight,100,1e3))),s(`type-${T}-tracking`,m.letterSpacing),i(`type-${T}-width`,`${G(Ms(m.width+t.type.width,25,151))}%`)}i("font",r.font.family),i("font-numeral",r.font.numeralFamily);let p=t.colors,d=n?{...r.colors.ambient,accent:r.colors.ambient.onSurface}:p;i("bg",d.background),i("surface",d.surface),i("on-surface",d.onSurface),i("on-surface-variant",d.onSurfaceVariant),i("outline",d.outline),i("time-text",d.timeText),i("scroll-thumb",d.scrollThumb),i("scroll-track",d.scrollTrack),i("accent",n?d.onSurface:p.accent),i("accent-fill",n?"transparent":p.accent),i("on-accent",n?d.onSurface:p.onAccent),i("accent-container",n?"transparent":`color-mix(in srgb, ${p.accent} 22%, ${p.surface})`),i("on-accent-container",n?d.onSurface:`color-mix(in srgb, ${p.accent} 35%, ${p.onSurface})`),i("track",n?d.outline:`color-mix(in srgb, ${p.accent} 22%, ${p.background})`),i("skeleton",n?d.outline:`color-mix(in srgb, ${p.onSurface} 14%, ${p.background})`);let b={ok:p.statusOk,warn:p.statusWarn,error:p.statusError,unknown:p.statusUnknown};for(let[y,m]of Object.entries(b))i(`status-${y}`,n?d.onSurfaceVariant:m);return i("warning-text",d.warningText),o}var Ir=(e,t,n)=>Math.min(Math.max(e,t),n);function Dr(e,t,n=le){let r=(O,j)=>n.effects[O]??j,o=r("edgeSpecSmallScreenWidth",192),s=r("edgeSpecLargeScreenWidth",240),i=s>o?Ir((e.heightDp-o)/(s-o),0,1):1,a=(O,j,w)=>r(O+"Small",j)+(r(O+"Large",w)-r(O+"Small",j))*i,l=a("edgeScale",.7,.6),c=a("edgeMinElementHeight",.2,.15),p=a("edgeMaxElementHeight",.6,.45),d=a("edgeMinTransitionArea",.35,.4),b=a("edgeMaxTransitionArea",.55,.6),y=e.heightDp,m=y>0?t/y:0,T=p>c?Ir((m-c)/(p-c),0,1):0,E=Math.min(d+(b-d)*T,(1+m)/2);return{scale:l,alpha:r("edgeAlpha",.5),zoneDp:E*y}}var De=e=>zr(Rn(e,3));function Xt(e,t,n,r){let o=r*Math.PI/180;return`${De(e+n*Math.cos(o))} ${De(t+n*Math.sin(o))}`}function In(e,t,n,r,o){if(o<=0||n<=0)return"";if(o>=359.99)return`M${Xt(e,t,n,r)} A${De(n)} ${De(n)} 0 0 1 ${Xt(e,t,n,r+180)} A${De(n)} ${De(n)} 0 0 1 ${Xt(e,t,n,r+360)}`;let s=o>180?1:0;return`M${Xt(e,t,n,r)} A${De(n)} ${De(n)} 0 ${s} 1 ${Xt(e,t,n,r+o)}`}function Ps(e,t){return t<=0?0:2*Math.asin(Ir(e/2/t,-1,1))*180/Math.PI}function Jn(e,t,n,r=le){let o=Cn(e,r),s=o.scrollIndicatorWidth??6,i=e.widthDp/2,a=i-(o.scrollIndicatorEdgePadding??2),l=a-s/2,c=Ps(s+(o.scrollIndicatorGap??3),a),p=Ps(o.scrollIndicatorLength??50,a)+c,d=(y,m)=>m*p>c?In(i,i,l,-p/2+y*p+c/2,m*p-c):"";return{track:[d(0,t),d(t+n,1-t-n)].filter(Boolean).join(" "),thumb:d(t,n),width:s}}var xt=[{id:"dark",name:"Dark",description:"The Wear OS Material 3 dark palette on black: the default.",tone:"dark",colors:{background:"#000000",surface:"#252626",onSurface:"#E3E3E3",onSurfaceVariant:"#C4C7C5",outline:"#8E918F",accent:"#A8C7FA",onAccent:"#062E6F",timeText:"#C6C6C6",scrollThumb:"#C6C6C6",scrollTrack:"#303030",warningText:"#FDD663",statusOk:"#6DD58C",statusWarn:"#FDD663",statusError:"#F28B82",statusUnknown:"#9AA0A6"},shape:{corners:"rounded"},type:{weight:0,width:0}},{id:"light",name:"Light",description:"The Material 3 light palette: dark text on a near-white background with a deep blue accent.",tone:"light",colors:{background:"#F8FAFD",surface:"#E1E3E1",onSurface:"#1F1F1F",onSurfaceVariant:"#444746",outline:"#747775",accent:"#0B57D0",onAccent:"#FFFFFF",timeText:"#444746",scrollThumb:"#444746",scrollTrack:"#C4C7C5",warningText:"#7C5800",statusOk:"#6DD58C",statusWarn:"#FDD663",statusError:"#F28B82",statusUnknown:"#9AA0A6"},shape:{corners:"rounded"},type:{weight:0,width:0}},{id:"high-contrast",name:"High contrast",description:"White on black with a yellow accent and heavier type, for reading at a glance in any light.",tone:"dark",colors:{background:"#000000",surface:"#1F1F1F",onSurface:"#FFFFFF",onSurfaceVariant:"#E6E6E6",outline:"#BFBFBF",accent:"#FFE14D",onAccent:"#000000",timeText:"#FFFFFF",scrollThumb:"#FFFFFF",scrollTrack:"#4D4D4D",warningText:"#FFE14D",statusOk:"#00E676",statusWarn:"#FFE14D",statusError:"#FF6E6E",statusUnknown:"#CCCCCC"},shape:{corners:"rounded"},type:{weight:100,width:0}},{id:"ember",name:"Ember",description:"Warm browns with an amber accent and pill-shaped chips.",tone:"dark",colors:{background:"#140D08",surface:"#2D2017",onSurface:"#F6E7D9",onSurfaceVariant:"#D9C3AF",outline:"#A68B75",accent:"#FFB37A",onAccent:"#4A2300",timeText:"#E5CDB8",scrollThumb:"#E5CDB8",scrollTrack:"#3B2B20",warningText:"#FFD27A",statusOk:"#A8D67A",statusWarn:"#FFC85C",statusError:"#FF8F7A",statusUnknown:"#B3A08F"},shape:{corners:"pill"},type:{weight:0,width:0}},{id:"mono",name:"Monochrome",description:"Greys only, white for emphasis and a lighter weight: quiet and neutral.",tone:"dark",colors:{background:"#000000",surface:"#262626",onSurface:"#F2F2F2",onSurfaceVariant:"#BDBDBD",outline:"#8C8C8C",accent:"#FFFFFF",onAccent:"#000000",timeText:"#BDBDBD",scrollThumb:"#BDBDBD",scrollTrack:"#333333",warningText:"#E0E0E0",statusOk:"#E0E0E0",statusWarn:"#A6A6A6",statusError:"#FFFFFF",statusUnknown:"#6E6E6E"},shape:{corners:"rounded"},type:{weight:-50,width:0}},{id:"slate",name:"Slate",description:"Blue-grey with a teal accent, sharp corners and condensed, slightly heavier type: a technical look.",tone:"dark",colors:{background:"#0B1015",surface:"#1C252E",onSurface:"#E6EDF3",onSurfaceVariant:"#A9B6C3",outline:"#6B7A89",accent:"#5CD6CB",onAccent:"#00312D",timeText:"#A9B6C3",scrollThumb:"#A9B6C3",scrollTrack:"#2A3540",warningText:"#F2C14E",statusOk:"#5FD38D",statusWarn:"#F2C14E",statusError:"#FF7B72",statusUnknown:"#8B98A5"},shape:{corners:"sharp"},type:{weight:50,width:-10}}],Vr="dark";function $e(e){return xt.find(t=>t.id===e)}var Br=["background","surface","onSurface","onSurfaceVariant","outline","accent","onAccent","timeText","scrollThumb","scrollTrack","warningText","statusOk","statusWarn","statusError","statusUnknown"],Fr=["sharp","rounded","pill"],js={min:-200,max:200},zs={min:-30,max:30};var zl=/^#[0-9A-Fa-f]{6}$/,Yt=e=>e!==null&&typeof e=="object"&&!Array.isArray(e),Cl=new Set(Br);function kt(e){return{id:e.id,name:e.name,tone:e.tone,colors:{...e.colors},shape:{...e.shape},type:{...e.type}}}function Tt(){return kt($e(Vr))}function Cs(e){let t=$e(e.base);return{...Hr(t?kt(t):Tt(),e.overrides,"overrides",[]),id:`saved:${e.id}`,name:e.name}}function Ur(e,t={}){let n=[],r=t.inherit!==void 0?Is(t.inherit):Tt(),o=t.inheritLabel??(t.inherit!==void 0?"the App theme":"the default theme");if(e==null)return{theme:r,problems:n};if(!Yt(e))return n.push({path:"",rule:"theme-invalid",severity:"error",message:'A theme is an object: { "base": "<theme id>", "overrides": { \u2026 } }.'}),{theme:r,problems:n};for(let l of Object.keys(e))l!=="base"&&l!=="overrides"&&n.push({path:l,rule:"theme-invalid",severity:"error",message:`Unknown theme property '${l}': use base and overrides.`});let s=r,i=e.base;if(i!==void 0)if(typeof i!="string")n.push({path:"base",rule:"theme-invalid",severity:"error",message:'base is a theme id such as "dark" or "saved:thm_\u2026".'});else if(i.startsWith("saved:")){let l=i.slice(6),c=t.saved?.find(p=>p.id===l);c?s=Cs(c):n.push({path:"base",rule:"theme-saved-unknown",severity:"warning",message:`This account has no saved theme '${l}' (it may belong to another account): ${o} is used instead.`})}else{let l=$e(i);l?s=kt(l):n.push({path:"base",rule:"theme-unknown",severity:"error",message:`Unknown theme '${i}': ${o} is used instead.`})}let a=e.overrides;return a!==void 0&&(s=Hr(s,a,"overrides",n)),{theme:s,problems:n}}function Hr(e,t,n,r){let o=Is(e),s=(i,a)=>r.push({path:i,rule:"theme-invalid",severity:"error",message:a});if(t==null)return o;if(!Yt(t))return s(n,"overrides is an object: { tone, colors, shape, type }."),o;for(let[i,a]of Object.entries(t)){let l=`${n}.${i}`;if(i==="tone")a==="dark"||a==="light"?o.tone=a:s(l,"tone is dark or light.");else if(i==="colors"){if(!Yt(a)){s(l,"colors maps colour roles to #RRGGBB.");continue}for(let[c,p]of Object.entries(a))Cl.has(c)?typeof p!="string"||!zl.test(p)?s(`${l}.${c}`,`${c} must be a colour as #RRGGBB.`):o.colors[c]=p.toUpperCase():s(`${l}.${c}`,`Unknown colour role '${c}'. Roles: ${Br.join(", ")}.`)}else if(i==="shape"){if(!Yt(a)){s(l,"shape is { corners }.");continue}for(let[c,p]of Object.entries(a))c!=="corners"?s(`${l}.${c}`,`Unknown shape property '${c}': use corners.`):typeof p=="string"&&Fr.includes(p)?o.shape.corners=p:s(`${l}.corners`,`corners is ${Fr.join(", ")}.`)}else if(i==="type"){if(!Yt(a)){s(l,"type is { weight, width }.");continue}for(let[c,p]of Object.entries(a)){let d=c==="weight"?js:c==="width"?zs:null;d===null?s(`${l}.${c}`,`Unknown type property '${c}': use weight and width.`):typeof p!="number"||!Number.isInteger(p)||p<d.min||p>d.max?s(`${l}.${c}`,`${c} is a whole number from ${d.min} to ${d.max}.`):o.type[c]=p}}else s(l,`Unknown override '${i}': use tone, colors, shape and type.`)}return o}function Is(e){return{id:e.id,name:e.name,tone:e.tone,colors:{...e.colors},shape:{...e.shape},type:{...e.type}}}var h=(e,t)=>{let n=e?.[t];return typeof n=="string"?n:void 0},Y=(e,t)=>{let n=e?.[t];return typeof n=="number"?n:void 0},D=(e,t)=>{let n=e?.[t];return n!==null&&typeof n=="object"&&!Array.isArray(n)?n:void 0},Te=(e,t)=>{let n=e?.[t];return Array.isArray(n)?n.filter(r=>r!==null&&typeof r=="object"&&!Array.isArray(r)):[]},$=e=>e==null||e==="";function St(e){if(e===void 0)return null;let t=Date.parse(e);return Number.isNaN(t)?null:t}var Qt={phase:"ready",updatedAt:null,staleAfter:10*6e4};function Dn(e,t){return e.updatedAt!==null&&t-e.updatedAt>=e.staleAfter}function Wr(e,t){let n=h(e,"state"),r=St(h(e,"lastUpdated"));if(n==="loading"&&t)return{...Qt,phase:"loading",updatedAt:r};if(n==="error"&&t){let o=h(e,"message");return o===void 0?{...Qt,phase:"error",updatedAt:r}:{...Qt,phase:"error",updatedAt:r,errorMessage:o}}return n==="empty"?{...Qt,phase:"empty"}:n==="stale"?{phase:"ready",updatedAt:r,staleAfter:0}:Qt}function ce(e,t){return e===void 0&&t===void 0?null:{name:e,url:t}}function Js(e){let t=0;return n=>`${e}-${n}-${++t}`}var ee=e=>e.data.phase==="loading",te=e=>e.data.phase==="empty";var Gr="0 0 24 24",Ds={add:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z",alarm:"M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39 6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12.5 8H11v6l4.75 2.85.75-1.23-4-2.37V8zM12 4a9 9 0 1 0 0 18 9 9 0 0 0 0-18zm0 16a7 7 0 1 1 0-14 7 7 0 0 1 0 14z","arrow-down":"M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z","arrow-up":"M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z",battery:"M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z",bell:"M12 22c1.1 0 2-.9 2-2h-4c0 1.1.89 2 2 2zm6-6v-5c0-3.07-1.64-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.63 5.36 6 7.92 6 11v5l-2 2v1h16v-1l-2-2z",bike:"M5 20.5a3.5 3.5 0 1 1 0-7 3.5 3.5 0 0 1 0 7zm0-5.5a2 2 0 1 0 0 4 2 2 0 0 0 0-4zm14 5.5a3.5 3.5 0 1 1 0-7 3.5 3.5 0 0 1 0 7zm0-5.5a2 2 0 1 0 0 4 2 2 0 0 0 0-4zM15.5 5.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4zM12.6 8.8 15 11h3V9h-2.2l-2.6-2.6c-.4-.4-.9-.6-1.4-.6s-1 .2-1.4.6L7.8 9c-.4.4-.6.9-.6 1.4 0 .6.2 1.1.6 1.4L11 14.5V19h2v-5.6l-2.2-2.1z",bolt:"M7 2v11h3v9l7-12h-4l4-8z",build:"M22.7 19l-9.1-9.1c.9-2.3.4-5-1.5-6.9-2-2-5-2.4-7.4-1.3L9 6 6 9 1.6 4.7C.4 7.1.9 10.1 2.9 12.1c1.9 1.9 4.6 2.4 6.9 1.5l9.1 9.1c.4.4 1 .4 1.4 0l2.3-2.3c.5-.4.5-1.1.1-1.4z",bus:"M4 16c0 .88.39 1.67 1 2.22V20c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h8v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1.78c.61-.55 1-1.34 1-2.22V6c0-3.5-3.58-4-8-4s-8 .5-8 4v10zm3.5 1a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm9 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zM18 11H6V6h12v5z",calendar:"M20 3h-1V1h-2v2H7V1H5v2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 18H4V8h16v13z",car:"M18.92 6.01C18.72 5.42 18.16 5 17.5 5h-11c-.66 0-1.21.42-1.42 1.01L3 12v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 16a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm11 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zM5 11l1.5-4.5h11L19 11H5z",check:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z","chevron-right":"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z",clock:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20a8 8 0 1 1 0-16 8 8 0 0 1 0 16zm.5-13H11v6l5.25 3.15.75-1.23-4.5-2.67z",close:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z",cloud:"M19.35 10.04A7.49 7.49 0 0 0 12 4C9.11 4 6.6 5.64 5.35 8.04A5.994 5.994 0 0 0 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96z",code:"M9.4 16.6 4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0 4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z",door:"M19 19V5c0-1.1-.9-2-2-2H7c-1.1 0-2 .9-2 2v14H3v2h18v-2h-2zm-4-6h-2v-2h2v2z",error:"M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z",fan:"M12 11a1 1 0 1 0 0 2 1 1 0 0 0 0-2zm.5-9C17 2 17.11 5.57 14.75 6.75c-.99.49-1.43 1.54-1.62 2.47.48.2.9.51 1.22.91 3.7-2 7.68-1.21 7.68 2.37C22 17 18.43 17.11 17.25 14.75c-.5-.99-1.56-1.43-2.49-1.62-.2.48-.51.89-.91 1.22 2 3.69 1.2 7.65-2.37 7.65C7 22 6.89 18.42 9.24 17.24c.98-.49 1.42-1.53 1.62-2.45-.49-.2-.92-.52-1.24-.92C5.94 15.85 2 15.07 2 11.5 2 7 5.56 6.89 6.74 9.25c.5.99 1.55 1.42 2.48 1.61.19-.48.51-.9.92-1.22C8.15 5.96 8.94 2 12.5 2z",flag:"M14.4 6 14 4H5v17h2v-7h5.6l.4 2h7V6z",git:"M5 2a3 3 0 0 1 1 5.83v8.34A3 3 0 1 1 4 16.17V7.83A3 3 0 0 1 5 2zm14 4a3 3 0 0 1-2 2.83V10a4 4 0 0 1-4 4H7v-2h6a2 2 0 0 0 2-2V8.83A3 3 0 1 1 19 6z",heart:"M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z",home:"M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z",info:"M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z",light:"M9 21c0 .55.45 1 1 1h4c.55 0 1-.45 1-1v-1H9v1zm3-19C8.14 2 5 5.14 5 9c0 2.38 1.19 4.47 3 5.74V17c0 .55.45 1 1 1h6c.55 0 1-.45 1-1v-2.26c1.81-1.27 3-3.36 3-5.74 0-3.86-3.14-7-7-7z",lock:"M18 8h-1V6A5 5 0 0 0 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm3.1-9H8.9V6a3.1 3.1 0 0 1 6.2 0v2z",mail:"M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4-8 5-8-5V6l8 5 8-5v2z","map-pin":"M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5a2.5 2.5 0 0 1 0-5 2.5 2.5 0 0 1 0 5z",music:"M12 3v10.55A4 4 0 1 0 14 17V7h4V3h-6z",pause:"M6 19h4V5H6v14zm8-14v14h4V5h-4z",phone:"M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1C10.61 21 3 13.39 3 4c0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z",play:"M8 5v14l11-7z",plug:"M16 7V3h-2v4h-4V3H8v4H7c-.55 0-1 .45-1 1v5.5L9.5 17v4h5v-4l3.5-3.5V8c0-.55-.45-1-1-1h-1z",power:"M13 3h-2v10h2V3zm4.83 2.17-1.42 1.42A6.92 6.92 0 0 1 19 12a7 7 0 0 1-14 0c0-2.08.9-3.95 2.58-5.42L6.17 5.17A8.93 8.93 0 0 0 3 12a9 9 0 0 0 18 0c0-2.74-1.23-5.18-3.17-6.83z",rain:"M18 5.5a6 6 0 0 0-11.6 1.1A4.5 4.5 0 0 0 6.5 15.5h11a5 5 0 0 0 .5-10zM8.1 17 6.6 21h1.6l1.5-4zm4 0-1.5 4h1.6l1.5-4zm4 0-1.5 4h1.6l1.5-4z",refresh:"M17.65 6.35A7.96 7.96 0 0 0 12 4a8 8 0 1 0 7.73 10h-2.08A6 6 0 1 1 12 6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z",remove:"M19 13H5v-2h14v2z",robot:"M20 9V7c0-1.1-.9-2-2-2h-3a3 3 0 0 0-6 0H6c-1.1 0-2 .9-2 2v2a3 3 0 0 0 0 6v4c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-4a3 3 0 0 0 0-6zM7.5 11.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0zM16 17H8v-2h8v2zm-1.5-4a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3z",rocket:"M12 2.5s4.5 2 4.5 9.5l2 2.5V19l-3-1.5h-7L5.5 19v-4.5l2-2.5C7.5 4.5 12 2.5 12 2.5zm0 7a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3zM10 19h4l-2 3z",settings:"M19.14 12.94c.04-.3.06-.61.06-.94 0-.32-.02-.64-.07-.94l2.03-1.58a.49.49 0 0 0 .12-.61l-1.92-3.32a.49.49 0 0 0-.59-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54a.48.48 0 0 0-.48-.41h-3.84c-.24 0-.43.17-.47.41l-.36 2.54c-.59.24-1.13.57-1.62.94l-2.39-.96a.49.49 0 0 0-.59.22L2.74 8.87c-.12.21-.08.47.12.61l2.03 1.58c-.05.3-.09.63-.09.94s.02.64.07.94l-2.03 1.58a.49.49 0 0 0-.12.61l1.92 3.32c.12.22.37.29.59.22l2.39-.96c.5.38 1.03.7 1.62.94l.36 2.54c.05.24.24.41.48.41h3.84c.24 0 .44-.17.47-.41l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.22.08.47 0 .59-.22l1.92-3.32c.12-.22.07-.47-.12-.61l-2.01-1.58zM12 15.6a3.6 3.6 0 1 1 0-7.2 3.6 3.6 0 0 1 0 7.2z",ship:"M20 21c-1.39 0-2.78-.47-4-1.32-2.44 1.71-5.56 1.71-8 0C6.78 20.53 5.39 21 4 21H2v2h2c1.38 0 2.74-.35 4-.99a8.75 8.75 0 0 0 8 0c1.26.65 2.62.99 4 .99h2v-2h-2zM3.95 19H4c1.6 0 3.02-.88 4-2 .98 1.12 2.4 2 4 2s3.02-.88 4-2c.98 1.12 2.4 2 4 2h.05l1.89-6.68c.08-.26.06-.54-.06-.78s-.34-.42-.6-.5L20 10.62V6c0-1.1-.9-2-2-2h-3V1H9v3H6c-1.1 0-2 .9-2 2v4.62l-1.29.42a1 1 0 0 0-.66 1.28L3.95 19zM6 6h12v3.97L12 8 6 9.97V6z",snow:"M22 11h-4.17l3.24-3.24-1.41-1.42L15 11h-2V9l4.66-4.66-1.42-1.41L13 6.17V2h-2v4.17L7.76 2.93 6.34 4.34 11 9v2H9L4.34 6.34 2.93 7.76 6.17 11H2v2h4.17l-3.24 3.24 1.41 1.42L9 13h2v2l-4.66 4.66 1.42 1.41L11 17.83V22h2v-4.17l3.24 3.24 1.42-1.41L13 15v-2h2l4.66 4.66 1.41-1.42L17.83 13H22z",star:"M12 17.27 18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z",stop:"M6 6h12v12H6z",sun:"M12 7a5 5 0 1 0 0 10 5 5 0 0 0 0-10zM11 1h2v3h-2zm0 19h2v3h-2zM1 11h3v2H1zm19 0h3v2h-3zM4.22 5.64l1.42-1.42 2.12 2.12-1.42 1.42zm12.02 12.02 1.42-1.42 2.12 2.12-1.42 1.42zM4.22 18.36l2.12-2.12 1.42 1.42-2.12 2.12zM16.24 6.34l2.12-2.12 1.42 1.42-2.12 2.12z",temp:"M15 13V5a3 3 0 0 0-6 0v8a5 5 0 1 0 6 0zm-3-10a2 2 0 0 1 2 2v3h-4V5a2 2 0 0 1 2-2z",thermometer:"M15 13V5a3 3 0 0 0-6 0v8a5 5 0 1 0 6 0zm-4-8a1 1 0 0 1 2 0h-1v1h1v2h-1v1h1v2h-2V5z",timer:"M15 1H9v2h6V1zm-4 13h2V8h-2v6zm8.03-6.61 1.42-1.42c-.43-.51-.9-.99-1.41-1.41l-1.42 1.42A8.96 8.96 0 0 0 12 4a9 9 0 1 0 9 9c0-2.12-.74-4.07-1.97-5.61zM12 20a7 7 0 1 1 0-14 7 7 0 0 1 0 14z",train:"M12 2c-4 0-8 .5-8 4v9.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h2.23l2-2H14l2 2h2v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V6c0-3.5-3.58-4-8-4zM7.5 17a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm3.5-7H6V6h5v4zm2 0V6h5v4h-5zm3.5 7a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3z",tram:"M19 16.94V8.5c0-2.79-2.61-3.4-6.01-3.49l.76-1.51H17V2H7v1.5h4.75l-.76 1.52C7.86 5.11 5 5.73 5 8.5v8.44c0 1.45 1.19 2.66 2.59 2.97L6 21.5v.5h2.23l2-2H14l2 2h2v-.5L16.5 20h-.08c1.69 0 2.58-1.37 2.58-3.06zM12 18.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm5-4.5H7V9h10v5z",unlock:"M12 17a2 2 0 1 0 0-4 2 2 0 0 0 0 4zm6-9h-1V6A5 5 0 0 0 7 6h1.9a3.1 3.1 0 0 1 6.2 0v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm0 12H6V10h12v10z",user:"M12 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z",walk:"M13.5 5.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4zM9.8 8.9 7 23h2.1l1.8-8 2.1 2v6h2v-7.5l-2.1-2 .6-3A7.3 7.3 0 0 0 19 13v-2c-1.9 0-3.5-1-4.3-2.4l-1-1.6c-.4-.6-1-1-1.7-1-.3 0-.5.1-.8.1L6 8.3V13h2V9.6l1.8-.7z",warning:"M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z",wifi:"M1 9l2 2c4.97-4.97 13.03-4.97 18 0l2-2C16.93 2.93 7.08 2.93 1 9zm8 8 3 3 3-3a4.24 4.24 0 0 0-6 0zm-4-4 2 2a7.07 7.07 0 0 1 10 0l2-2C15.14 9.14 8.87 9.14 5 13z",wind:"M14.5 17a3 3 0 0 1-6 0h2a1 1 0 1 0 1-1H2v-2h9.5a3 3 0 0 1 3 3zM19 6.5a3.5 3.5 0 0 0-7 0h2a1.5 1.5 0 1 1 1.5 1.5H2v2h13.5A3.5 3.5 0 0 0 19 6.5zm-.5 4.5H2v2h16.5a1.5 1.5 0 0 1 0 3v2a3.5 3.5 0 0 0 0-7z"};var R={ButtonView:"wb-scope-button-view",Buttons2TileView:"wb-scope-buttons2-tile-view",CompactListTileView:"wb-scope-compact-list-tile-view",ComplicationView:"wb-scope-complication-view",ConfirmOverlay:"wb-scope-confirm-overlay",CountdownView:"wb-scope-countdown-view",CurvedText:"wb-scope-curved-text",ErrorView:"wb-scope-error-view",FeedbackOverlay:"wb-scope-feedback-overlay",IconView:"wb-scope-icon-view",List3TileView:"wb-scope-list3-tile-view",ListRow:"wb-scope-list-row",ListView:"wb-scope-list-view",PlaceholderView:"wb-scope-placeholder-view",ProgressRing:"wb-scope-progress-ring",ProgressRingTileView:"wb-scope-progress-ring-tile-view",ProgressView:"wb-scope-progress-view",ScreenView:"wb-scope-screen-view",Skeleton:"wb-scope-skeleton",StackView:"wb-scope-stack-view",StatView:"wb-scope-stat-view",StatusTileView:"wb-scope-status-tile-view",StatusView:"wb-scope-status-view",TextTileView:"wb-scope-text-tile-view",TextView:"wb-scope-text-view",TileFrame:"wb-scope-tile-frame",ToggleView:"wb-scope-toggle-view",UnsupportedView:"wb-scope-unsupported-view",WatchIcon:"wb-scope-watch-icon",WatchOverview:"wb-scope-watch-overview",WatchPreview:"wb-scope-watch-preview"};var he=e=>"text"in e;function u(e,t,n,...r){let o=[],s=e===null;if(n)for(let[a,l]of Object.entries(n))l==null||l===!1||(a==="class"&&e?(o.push([a,`${l===!0?"":String(l)} ${e}`.trim()]),s=!0):o.push([a,l===!0?!0:String(l)]));s||o.push(["class",e]);let i=[];return Fs(r,i),{tag:t,attrs:o,children:i}}function Fs(e,t){for(let n of e)if(!(n==null||n===!1||n===""))if(Array.isArray(n))Fs(n,t);else if(typeof n=="string"){let r=t[t.length-1];r&&he(r)?r.text+=n:t.push({text:n})}else t.push(n)}var Us="http://www.w3.org/2000/svg";function qr(e){if(he(e))return null;for(let t of["data-wb-key","id","data-path","data-screen","data-glance","data-wb-surface"]){let n=e.attrs.find(r=>r[0]===t);if(n)return n[1]===!0?"":n[1]}return null}function Hs(e,t,n){t==="style"&&"style"in e?e.style.cssText=n===!0?"":n:e.setAttribute(t,n===!0?"":n)}function Vn(e,t,n){if(he(t))return t.dom=e.createTextNode(t.text);let r=n||t.tag==="svg",o=r?e.createElementNS(Us,t.tag):e.createElement(t.tag);for(let[s,i]of t.attrs)Hs(o,s,i);for(let s of t.children)o.appendChild(Vn(e,s,r));return t.dom=o,o}function Il(e,t,n,r){if(he(t)||he(n))return he(t)&&he(n)&&t.dom?(t.text!==n.text&&(t.dom.nodeValue=n.text),n.dom=t.dom,t.dom):Vs(e,t,n,r);if(t.tag!==n.tag||!t.dom)return Vs(e,t,n,r);let o=t.dom,s=new Map(t.attrs);for(let[i,a]of n.attrs)s.get(i)!==a&&Hs(o,i,a),s.delete(i);for(let i of s.keys())i==="style"&&"style"in o&&(o.style.cssText=""),o.removeAttribute(i);return n.dom=o,Ws(e,o,t.children,n.children,r||n.tag==="svg"),o}function Vs(e,t,n,r){let o=Vn(e,n,r);return t.dom?.parentNode?.replaceChild(o,t.dom),o}function Ws(e,t,n,r,o){let s=new Map;for(let p of n){let d=qr(p);d!==null&&!s.has(d)&&s.set(d,p)}let i=new Set,a=0,l=()=>{for(;a<n.length&&(i.has(n[a])||qr(n[a])!==null);)a++},c=t.firstChild;for(let p of r){let d=qr(p),b;if(d!==null)b=s.get(d),b&&s.delete(d);else{l();let y=n[a];y&&Jl(y,p)&&(b=y,a++)}b&&b.dom?(i.add(b),b.dom!==c?t.insertBefore(b.dom,c):c=c.nextSibling,Il(e,b,p,o)):t.insertBefore(Vn(e,p,o),c)}for(let p of n)!i.has(p)&&p.dom?.parentNode===t&&t.removeChild(p.dom)}function Jl(e,t){return he(e)||he(t)?he(e)&&he(t):e.tag===t.tag}var Bs=new WeakMap;function Gs(e,t){let n=e.ownerDocument,r=Bs.get(e),o=e.namespaceURI===Us;r?Ws(n,e,r,t,o):e.replaceChildren(...t.map(s=>Vn(n,s,o))),Bs.set(e,t)}var Kt=R.WatchIcon;function pe(e,t="medium",n){let r=e?.name,o=e?.url,s=n??"";if(o!==void 0&&o.trim()!=="")return u(Kt,"img",{class:`wb-icon wb-icon--${t} wb-icon--image ${s}`,src:o,alt:"",loading:"lazy"});let i=r===void 0?void 0:Ds[r];return i!==void 0?u(Kt,"svg",{class:`wb-icon wb-icon--${t} ${s}`,viewBox:Gr,"data-icon":r,"aria-hidden":"true"},u(Kt,"path",{d:i})):$(r)?null:u(Kt,"svg",{class:`wb-icon wb-icon--${t} wb-icon--unknown ${s}`,viewBox:Gr,"data-icon":r,"aria-hidden":"true"},u(Kt,"circle",{cx:"12",cy:"12",r:"5"}))}var ue=(e,t,n)=>pe({name:e},t,n),qs=R.Skeleton;function B(e={}){let{shape:t="line",lines:n=1,width:r,cls:o=""}=e;if(t==="line"){let s=[];for(let i=0;i<n;i++)s.push(u(qs,"span",{class:`wb-skeleton wb-skeleton--line ${o}`,style:`width:${i===n-1&&n>1?"60%":r??"80%"}`}));return s}return[u(qs,"span",{class:`wb-skeleton wb-skeleton--${t} ${o}`,style:r===void 0?null:`width:${r}`})]}var en=R.CurvedText;function Bn(e,t,n,r=!1){let o=e.newId("arc"),s=e.device,i=e.tokens.sizes.curvedTextInset??18,a=s.widthDp/2,l=s.heightDp/2,c=r?a-i/3-(e.tokens.typeScale.caption?.size??12)*500/2048:a-i,p=`M${G(a-c)} ${G(l)} A${G(c)} ${G(c)} 0 0 ${r?0:1} ${G(a+c)} ${G(l)}`;return u(en,"svg",{class:`wb-curved ${n}`,viewBox:`0 0 ${G(s.widthDp)} ${G(s.heightDp)}`,"aria-label":t},u(en,"defs",null,u(en,"path",{id:o,d:p})),u(en,"text",null,u(en,"textPath",{href:`#${o}`,startOffset:"50%","text-anchor":"middle"},t)))}var Zr=R.ProgressRing;function tn(e,t={}){let{stroke:n="var(--wb-progress-ring-stroke)",gapPercent:r=0,radius:o=44,cls:s=""}=t,i=100-r,a=Math.min(Math.max(e,0),1)*i*3.6,l=r>0?90+r*3.6/2:-90;return u(Zr,"svg",{class:`wb-ring ${s}`,viewBox:"0 0 100 100","aria-hidden":"true"},u(Zr,"path",{class:"wb-ring__track",d:In(50,50,o,l,i*3.6),style:`stroke-width:${n}`}),e>0&&u(Zr,"path",{class:"wb-ring__fill",d:In(50,50,o,l,a),"data-sweep":G(a),style:`stroke-width:${n}`}))}function nn(e,t,n){let r=St(h(e,"target"));return r===null?null:{"data-wb-countdown":!0,"data-target":$n(r),"data-format":h(e,"format")==="clock"?"clock":"relative","data-ambient":t.ambient?"true":"false","data-max":n==null?null:String(n)}}function rn(e,t){return Os(St(h(e,"target")),t.now,h(e,"format")==="clock",t.ambient)}var rt=R.ListRow;function Fn(e,t,n,r=!1){let o=D(t,"action"),s=`wb-row${r?" wb-row--compact":""}${o?" wb-row--action":""}`,i=h(t,"subtitle"),a=h(t,"badge"),l=D(t,"trailing"),c=[pe(ce(h(t,"icon")),r?"small":"medium","wb-row__icon"),u(rt,"span",{class:"wb-row__text"},u(rt,"span",{class:"wb-row__title"},h(t,"title")??""),!$(i)&&u(rt,"span",{class:"wb-row__subtitle"},i)),!$(a)&&u(rt,"span",{class:"wb-row__badge"},a),Xr(e,l,rt,"wb-row__trailing")];return o?u(rt,"button",{type:"button",class:s,"data-path":n,"data-wb-tap":"action"},c):u(rt,"div",{class:s,"data-path":n},c)}function Xr(e,t,n,r){if(!t)return null;let o=h(t,"type");if(o==="countdown")return u(n,"span",{class:`${r} ${r}--countdown`,...nn(t,e)},rn(t,e));let s=h(t,"value");return o==="text"&&!$(s)?u(n,"span",{class:r},s):null}function on(e){return u(R.UnsupportedView,"div",{class:"wb-unsupported",title:`No renderer for ${e} yet`},e)}function sn(e,t,n){if(!t)return null;switch(h(t,"type")){case"text":return Dl(e,t);case"stat":return eo(e,t);case"list":return Vl(e,t,n);case"status":return Bl(e,t);case"progress":return Fl(e,t);case"countdown":return Ul(e,t);case"button":return Hl(t,n);case"toggle":return ro(t,n);case"icon":return Wl(t);case"stack":return Gl(e,t,n);case"placeholder":return ql(t);case"error":return Zl(t);case"unsupported":return on(h(t,"component")??"");default:return on(h(t,"type")??"")}}var Zs=R.TextView;function Dl(e,t){let n=h(t,"style")??"body",r=Y(t,"maxLines")??3;if(ee(e))return u(Zs,"div",{class:`wb-text wb-text--${n} wb-text--loading`},B({lines:Math.min(r,2)}));let o=Math.max(1,r);return u(Zs,"div",{class:`wb-text wb-text--${n} wb-text--clamp`,style:`-webkit-line-clamp:${o}`,"data-max-lines":String(o)},h(t,"value")??"")}var je=R.StatView,Xs={up:"Up",down:"Down",flat:"Flat"};function eo(e,t){let n=ee(e),r=h(t,"trend")??"none",o=te(e)||$(h(t,"value"))?Je:h(t,"value"),s=h(t,"unit"),i=h(t,"label"),a=r in Xs&&!te(e)?u(je,"svg",{class:`wb-stat__trend wb-stat__trend--${r}`,viewBox:"0 0 24 24","aria-label":Xs[r]},r==="up"?u(je,"path",{d:"M12 5l7 9H5z"}):r==="down"?u(je,"path",{d:"M12 19l-7-9h14z"}):u(je,"rect",{x:"5",y:"10.5",width:"14",height:"3",rx:"1.5"})):null;return u(je,"div",{class:`wb-stat ${n?"wb-stat--loading":""}`},pe(ce(h(t,"icon")),"small","wb-stat__icon"),n?B({cls:"wb-stat__skeleton",width:"50%"}):u(je,"div",{class:"wb-stat__value-row"},a,u(je,"span",{class:"wb-stat__value"},o),!$(s)&&u(je,"span",{class:"wb-stat__unit"},s)),!$(i)&&u(je,"div",{class:"wb-stat__label"},i))}var At=R.ListView;function Vl(e,t,n){let r=h(t,"header"),o=Te(t,"items"),s=Y(t,"maxRows")??0,i=Y(t,"totalCount")??0,a;if(ee(e)){let l=s>0&&s<3?s:3;a=Array.from({length:l},()=>u(At,"div",{class:"wb-list__placeholder"},B({shape:"circle"}),u(At,"span",{class:"wb-list__placeholder-text"},B({width:"70%"}),B({width:"45%"}))))}else if(te(e)||o.length===0){let l=h(t,"emptyText");a=u(At,"div",{class:"wb-list__empty"},$(l)?"Nothing to show":l)}else a=[o.map((l,c)=>Fn(e,l,`${n}.items[${c}]`)),i>o.length&&u(At,"div",{class:"wb-list__more"},`+${i-o.length} more`)];return u(At,"section",{class:"wb-list"},!$(r)&&u(At,"header",{class:"wb-list__header"},r),a)}var Ot=R.StatusView,to=e=>e==="ok"?"check":e==="warn"?"warning":e==="error"?"error":"info",no=e=>e==="ok"?"OK":e==="warn"?"Warning":e==="error"?"Error":"Unknown";function Bl(e,t){let n=h(t,"state")??"unknown",r=h(t,"label"),o=h(t,"detail");return u(Ot,"div",{class:`wb-status wb-status--${n}`,"data-state":n},ee(e)?[B({shape:"circle"}),u(Ot,"span",{class:"wb-status__text"},B({width:"70%"}))]:[u(Ot,"span",{class:"wb-status__badge"},ue(to(n),"small")),u(Ot,"span",{class:"wb-status__text"},u(Ot,"span",{class:"wb-status__label"},$(r)?no(n):r),!$(o)&&u(Ot,"span",{class:"wb-status__detail"},o))])}var Se=R.ProgressView;function Hn(e,t,n){return n>t?Math.min(Math.max((e-t)/(n-t),0),1):0}function Fl(e,t){let n=Y(t,"value")??0,r=Y(t,"min")??0,o=Y(t,"max")??100,s=h(t,"label"),i=ee(e),a=i||te(e)?0:Hn(n,r,o),l=te(e)?Je:Nn(n,r,o),c={role:"progressbar","aria-valuenow":Ne(n),"aria-valuemin":Ne(r),"aria-valuemax":Ne(o)};return h(t,"style")==="ring"?u(Se,"div",{class:"wb-progress wb-progress--ring",...c},u(Se,"div",{class:"wb-progress__ring"},tn(a),u(Se,"span",{class:"wb-progress__value"},i?B({width:"60%"}):l)),!$(s)&&u(Se,"div",{class:"wb-progress__label"},s)):u(Se,"div",{class:"wb-progress wb-progress--bar",...c},u(Se,"div",{class:"wb-progress__caption"},u(Se,"span",{class:"wb-progress__label"},s??""),u(Se,"span",{class:"wb-progress__value"},i?"":l)),u(Se,"div",{class:`wb-progress__track ${i?"wb-progress__track--loading":""}`},u(Se,"div",{class:"wb-progress__fill",style:`width:${G(a*100)}%`})))}var Yr=R.CountdownView;function Ul(e,t){let n=St(h(t,"target")),r=h(t,"label");return u(Yr,"div",{class:`wb-countdown wb-countdown--${h(t,"format")??"relative"}`,"data-target":n===null?null:$n(n)},ee(e)?B({width:"45%",cls:"wb-countdown__skeleton"}):u(Yr,"span",{class:"wb-countdown__value",...te(e)?null:nn(t,e)},te(e)?Je:rn(t,e)),!$(r)&&u(Yr,"span",{class:"wb-countdown__label"},r))}var Ys=R.ButtonView;function Hl(e,t){let n=D(e,"action"),r=ce(h(e,"icon"));return u(Ys,"button",{type:"button",class:`wb-button wb-button--${h(e,"style")??"primary"} ${r?"wb-button--icon":""} ${n?"":"wb-button--disabled"}`,disabled:!n,"data-action":h(n,"id"),"data-wb-tap":n?"action":null,"data-path":t},pe(r,"medium","wb-button__icon"),u(Ys,"span",{class:"wb-button__label"},h(e,"label")??""))}var ot=R.ToggleView;function ro(e,t,n=!1,r=null){let o=e.on===!0,s=ce(h(e,"icon"))??(n?r:null),i=h(e,"label")??"";return u(ot,"button",{type:"button",role:"switch","aria-checked":o?"true":"false",class:`wb-toggle ${o?"wb-toggle--on":""} ${n?"wb-toggle--tile":""}`,"data-path":t,"data-wb-tap":"toggle","data-on":o?"true":"false"},s&&pe(s,"medium","wb-toggle__icon"),n?u(ot,"span",{class:"wb-toggle__text"},u(ot,"span",{class:"wb-toggle__label"},i),u(ot,"span",{class:"wb-toggle__state"},o?"On":"Off")):[u(ot,"span",{class:"wb-toggle__label"},i),u(ot,"span",{class:"wb-toggle__switch"},u(ot,"span",{class:"wb-toggle__thumb"}))])}function Wl(e){let t=h(e,"size")??"medium";return u(R.IconView,"div",{class:`wb-icon-node wb-icon-node--${t}`},pe(ce(h(e,"icon"),h(e,"imageUrl"))??{},t))}var Qr=R.StackView;function Gl(e,t,n){let r=h(t,"header");return u(Qr,"section",{class:`wb-stack wb-stack--${h(t,"direction")??"vertical"}`},!$(r)&&u(Qr,"header",{class:"wb-stack__header"},r),u(Qr,"div",{class:"wb-stack__children"},Te(t,"children").map((o,s)=>sn(e,o,`${n}.children[${s}]`))))}var Kr=R.PlaceholderView;function ql(e){let t=h(e,"component")??"",n=Math.max(1,Y(e,"rows")??1),r=(s,i)=>u(Kr,"div",{class:"wb-placeholder__chip"},B({shape:"circle"}),u(Kr,"span",{class:"wb-placeholder__lines"},B({width:s}),i!==void 0&&B({width:i}))),o;switch(t){case"list":o=Array.from({length:n},()=>r("70%","45%"));break;case"button":case"toggle":case"status":o=r("60%");break;case"stat":case"countdown":o=[B({width:"50%",cls:"wb-placeholder__big"}),B({width:"35%"})];break;case"progress":o=B({shape:"circle",cls:"wb-placeholder__ring"});break;default:o=B({lines:n})}return u(Kr,"div",{class:`wb-placeholder wb-placeholder--${t}`,"data-component":t,"aria-busy":"true"},o)}var Un=R.ErrorView;function Zl(e){let t=h(e,"source"),n=h(e,"message")??"",r=t===void 0?"Couldn't load":`Couldn't load ${t}`;return u(Un,"div",{class:"wb-error-node",role:"alert","data-component":h(e,"component")??"","data-source":t},ue("error","small"),u(Un,"span",{class:"wb-error-node__text"},u(Un,"span",{class:"wb-error-node__title"},r),!$(n)&&n!==r&&u(Un,"span",{class:"wb-error-node__message"},n)))}var Xl={shortText:7,longText:24},oo=e=>`$.glances.${e}`;function Qs(e,t){let n=oo(h(t,"id")??"");switch(h(t,"template")){case"text":return Be(e,t,"text",!0,u(R.TextTileView,"div",{class:"wb-text-tile"},sn(e,D(t,"text"),`${n}.text`)));case"single-stat":return Be(e,t,"single-stat",!0,eo(e,D(t,"stat")??{}));case"list3":return Yl(e,t,n);case"compact-list":return Ql(e,t,n);case"status":return Kl(e,t);case"progress-ring":return ec(e,t);case"buttons2":return tc(e,t,n);case"toggle":return Be(e,t,"toggle",!1,ro(D(t,"toggle")??{},`${n}.toggle`,!0,ce(h(t,"icon"))));default:return on(`${h(t,"template")??"Unknown"}Tile`)}}var Ve=R.TileFrame;function Be(e,t,n,r,...o){let s=oo(h(t,"id")??""),i=h(t,"opens"),a=r&&i!==void 0,l=n==="progress-ring"?null:ce(h(t,"icon")),c=h(t,"title"),p=h(D(t,"data"),"state"),d=p==="stale"&&e.data.updatedAt!==null?Pn(e.data.updatedAt,e.now):p==="sample"?"Sample data":null,b=e.data.phase==="error"&&u(Ve,"div",{class:"wb-tile__error",role:"alert"},ue("warning","small"),"Couldn't refresh");return u(Ve,"div",{class:`wb-tile wb-tile--${n} ${a?"wb-tile--edge":""}`,"data-glance":h(t,"id"),"data-wb-tap":i===void 0?null:"open","data-path":s,role:"button"},u(Ve,"header",{class:"wb-tile__title"},l?pe(l,"medium","wb-tile__title-icon"):u(Ve,"span",{class:"wb-tile__icon-slot","aria-hidden":"true"}),!$(c)&&u(Ve,"span",{class:"wb-tile__title-text"},c)),u(Ve,"div",{class:"wb-tile__main"},b,o),!$(d)&&u(Ve,"div",{class:"wb-tile__bottom-label"},d),a&&u(Ve,"button",{type:"button",class:"wb-edge-button","data-wb-tap":"open","data-path":s},"Open"))}function Yl(e,t,n){let r=R.List3TileView,o=e.tokens.limits.tileListMaxRows??3,s=Te(t,"items"),i=s.slice(0,o),a=Math.max(Y(t,"totalCount")??0,s.length)-i.length,l=h(t,"emptyText");return Be(e,t,"list3",!0,u(r,"div",{class:"wb-list3"},ee(e)?Array.from({length:o},()=>B({width:"90%"})):te(e)||i.length===0?u(r,"div",{class:"wb-list3__empty"},$(l)?"Nothing to show":l):[i.map((c,p)=>Fn(e,c,`${n}.items[${p}]`,!0)),a>0&&u(r,"div",{class:"wb-list3__more"},`+${a} more`)]))}function Ql(e,t,n){let r=R.CompactListTileView,o=e.tokens.limits,s=Jr(e.device,e.tokens)?o.tileCompactListMaxRowsSmallScreen??6:o.tileCompactListMaxRows??8;e.data.phase==="error"&&s--,Dn(e.data,e.now)&&s--,s=Math.max(1,s);let i=Te(t,"items").slice(0,s),a=h(t,"emptyText");return Be(e,t,"compact-list",!1,u(r,"div",{class:"wb-compact-list"},ee(e)?Array.from({length:s},()=>u(r,"div",{class:"wb-compact-list__row"},B({width:"90%"}))):te(e)||i.length===0?u(r,"div",{class:"wb-compact-list__empty"},$(a)?"Nothing to show":a):i.map((l,c)=>u(r,"div",{class:"wb-compact-list__row","data-path":`${n}.items[${c}]`},u(r,"span",{class:"wb-compact-list__title"},h(l,"title")??""),Xr(e,D(l,"trailing"),r,"wb-compact-list__trailing")))))}function Kl(e,t){let n=R.StatusTileView,r=D(t,"status"),o=h(r,"state")??"unknown",s=h(r,"label"),i=h(r,"detail");return Be(e,t,"status",!0,u(n,"div",{class:`wb-status-tile wb-status-tile--${o}`,"data-state":o},ee(e)?[B({shape:"circle",cls:"wb-status-tile__skeleton"}),B({width:"60%"})]:[u(n,"span",{class:"wb-status-tile__badge"},ue(to(o),"large")),u(n,"span",{class:"wb-status-tile__label"},$(s)?no(o):s),!$(i)&&u(n,"span",{class:"wb-status-tile__detail"},i)]))}function ec(e,t){let n=R.ProgressRingTileView,r=D(t,"progress"),o=Y(r,"value")??0,s=Y(r,"min")??0,i=Y(r,"max")??100,a=h(r,"label"),l=e.device.widthDp-2*(e.tokens.spacing.xs??4),c=Cn(e.device,e.tokens).tileRingStroke??8,p=l>0?50-c/2/l*100:47,d=ee(e)||te(e)?0:Hn(o,s,i);return Be(e,t,"progress-ring",!0,u(n,"div",{class:"wb-progress-tile__ring"},tn(d,{radius:p,stroke:"var(--wb-tile-ring-stroke)",gapPercent:h(t,"opens")===void 0?0:22})),u(n,"div",{class:"wb-progress-tile"},ee(e)?B({width:"50%",cls:"wb-progress-tile__skeleton"}):u(n,"span",{class:"wb-progress-tile__value"},te(e)?Je:Nn(o,s,i)),!$(a)&&u(n,"span",{class:"wb-progress-tile__label"},a)))}function tc(e,t,n){let r=R.Buttons2TileView,o=Te(t,"buttons").slice(0,e.tokens.limits.tileMaxButtons??2),s=i=>i.trim()===""?"?":i.trim().slice(0,1).toUpperCase();return Be(e,t,"buttons2",!1,u(r,"div",{class:"wb-buttons2"},o.map((i,a)=>{let l=D(i,"action"),c=ce(h(i,"icon")),p=h(i,"label")??"";return u(r,"div",{class:"wb-buttons2__item"},u(r,"button",{type:"button",class:`wb-buttons2__button wb-buttons2__button--${h(i,"style")??"primary"}`,disabled:!l,"data-action":h(l,"id"),"data-wb-tap":l?"action":null,"data-path":`${n}.buttons[${a}]`,"aria-label":p},c?pe(c,"large"):u(r,"span",{class:"wb-buttons2__initial"},s(p))),u(r,"span",{class:"wb-buttons2__label"},p))})))}var nc={shortText:"short-text",longText:"long-text",rangedValue:"ranged-value",image:"image"};function Ks(e,t){let n=R.ComplicationView,r=h(t,"kind")??"shortText",o=nc[r]??"image",s=r==="longText",i=h(t,"opens"),a=h(t,"title"),l=ce(h(t,"icon"),h(t,"imageUrl")),c=Xl[r],p=l===null&&!$(a),d=D(t,"text"),b;if(ee(e))b="\u2026";else if(te(e))b=Je;else{let z=h(d,"type"),x=Y(t,"value");b=Cr(z==="text"?h(d,"value")??"":z==="countdown"?rn(d,e):r==="rangedValue"&&x!==void 0?Ne(x):"",c)}let y=d&&h(d,"type")==="countdown"&&!ee(e)&&!te(e)?nn(d,e,c):null,m=u(n,"span",{class:"wb-comp__text",...y},b),T=u(n,"span",{class:"wb-comp__title"},Cr(a,c)),E=z=>l&&pe(l,z,"wb-comp__icon"),O=0,j=Y(t,"value");!ee(e)&&!te(e)&&j!==void 0&&(O=Hn(j,Y(t,"min")??0,Y(t,"max")??100));let w;switch(r){case"shortText":w=[E("small"),m,p&&T];break;case"longText":w=[E("medium"),u(n,"span",{class:"wb-comp__lines"},!$(a)&&T,m)];break;case"rangedValue":w=[u(n,"span",{class:"wb-comp__ring"},tn(O,{radius:45,gapPercent:22,stroke:"var(--wb-ranged-stroke)"})),E("small"),m,p&&T];break;default:w=l&&pe(l,$(l.url)?"large":"fill")}let I=()=>!s&&u(n,"span",{class:"wb-face__placeholder"});return u(n,"div",{class:`wb-face ${e.device.isRound?"":"wb-face--square"}`},u(n,"div",{class:"wb-face__ticks"}),u(n,"div",{class:"wb-face__time"},jn(e.now,e.timeZone)),u(n,"div",{class:"wb-face__date"},Es(e.now,e.timeZone)),u(n,"div",{class:`wb-face__slots ${s?"wb-face__slots--long":""}`},I(),u(n,"div",{class:`wb-comp wb-comp--${o} ${i===void 0?"":"wb-comp--tappable"}`,"data-glance":h(t,"id"),"data-kind":o,"data-wb-tap":i===void 0?null:"open","data-path":oo(h(t,"id")??""),role:"button"},w),I()))}function rc(e){let t=h(e,"main"),n=Te(e,"screens"),o=[...n.filter(a=>h(a,"id")===t),...n.filter(a=>h(a,"id")!==t)].map(a=>({key:`page:${h(a,"id")}`,label:h(a,"id")??"",kind:"screen",node:a})),s=D(e,"tile"),i=D(e,"complication");return s&&o.push({key:"tile",label:"Tile",kind:"glance",node:s}),i&&o.push({key:"complication",label:"Complication",kind:"glance",node:i}),o}function oc(e,t){let n=Te(e,"screens"),r=[D(e,"tile"),D(e,"complication")].filter(p=>p!==void 0),o=p=>n.find(d=>h(d,"id")===p),s=p=>r.find(d=>h(d,"id")===p),i=t.screen!==void 0?`screen:${t.screen}`:t.surface??`page:${h(e,"main")}`,[a,l]=i.includes(":")?[i.slice(0,i.indexOf(":")),i.slice(i.indexOf(":")+1)]:[i,void 0],c=a==="page"||a==="screen"?o(l)&&{kind:"screen",node:o(l)}:a==="glance"?s(l)&&{kind:"glance",node:s(l)}:a==="tile"||a==="complication"?D(e,a)&&{kind:"glance",node:D(e,a)}:void 0;return c||(n[0]?{kind:"screen",node:n[0]}:r[0]?{kind:"glance",node:r[0]}:null)}var so=R.WatchPreview;function ao(e,t){let n=zn(t.deviceProfile),r=t.ambient===!0,o=oc(e,t),i=o!==null&&o.kind==="glance"&&h(o.node,"template")!==void 0?Ns(t.theme??Tt(),n):t.theme??Tt(),a=o?Wr(D(o.node,"data"),o.kind==="glance"):Wr(void 0,!1),l={device:n,theme:i,tokens:le,ambient:r,data:a,now:t.now??Date.now(),timeZone:t.timeZone??h(e,"timeZone")??"UTC",newId:Js(t.idPrefix??"wbp")},c=[o===null?u(null,"div",{class:"wb-empty"},"Nothing to show"):o.kind==="screen"?sc(l,o.node):h(o.node,"kind")!==void 0&&h(o.node,"template")===void 0?Ks(l,o.node):Qs(l,o.node),t.feedback&&ic(t.feedback),t.confirm&&ac(t.confirm)],p=u(so,"div",{class:"wb-screen"},c),d=n.isRound?n.id.includes("classic")?"wb-case--classic":"":"wb-case--square";return u(so,"div",{class:`wb-preview ${r?"wb-ambient":""} wb-tone-${i.tone} wb-shape-${n.isRound?"round":"square"} wb-platform-${n.platform}`,style:`zoom:${G(t.scale??1)};${$s(n,i,r)}`,"data-device":n.id,"data-data-phase":a.phase},t.frame===!1?p:u(so,"div",{class:`wb-case ${d}`},p))}var Ae=R.ScreenView;function sc(e,t){let n=h(t,"id")??"",r=e.data.phase==="error",o=G(e.device.widthDp),s=Bn(e,jn(e.now,e.timeZone),"wb-time-text"),i=e.data.errorMessage,a=u(Ae,"div",{class:"wb-scroll"},u(Ae,"div",{class:"wb-content"},r&&u(Ae,"div",{class:"wb-data-error",role:"alert"},ue("warning","small"),u(Ae,"span",{class:"wb-data-error__text"},u(Ae,"span",{class:"wb-data-error__title"},"Couldn't refresh"),!$(i)&&u(Ae,"span",{class:"wb-data-error__detail"},i))),sn(e,D(t,"root"),`$.screens.${n}.root`))),l=Jn(e.device,0,.7,e.tokens),c=u(Ae,"svg",{class:"wb-position-indicator",viewBox:`0 0 ${o} ${o}`,"aria-hidden":"true",style:`stroke-width:${G(l.width)}px`},u(Ae,"path",{class:"wb-position-indicator__track",d:l.track}),u(Ae,"path",{class:"wb-position-indicator__thumb",d:l.thumb})),p=e.data.updatedAt,d=h(D(t,"data"),"state")==="sample",b=p!==null&&Dn(e.data,e.now)?Bn(e,Pn(p,e.now),"wb-stale-hint",!0):d?Bn(e,"Sample data","wb-stale-hint",!0):null;return u(Ae,"div",{class:`wb-screen-view ${e.device.isRound?"wb-screen-view--round":"wb-screen-view--square"} ${r?"wb-screen-view--error":""}`,"data-screen":n},s,a,c,b)}var io=R.FeedbackOverlay;function ic(e){let t=e.sequence??0,n=e.success,r=[u(io,"div",{"data-wb-key":`haptic-${t}`,class:`wb-haptic ${n?"wb-haptic--ok":"wb-haptic--error"}`,"aria-hidden":"true"})];return e.toast!==!1&&r.push(u(io,"div",{"data-wb-key":`toast-${t}`,class:`wb-toast ${n?"wb-toast--ok":"wb-toast--error"}`,role:"status"},ue(n?"check":"error","small"),u(io,"span",{class:"wb-toast__text"},e.message??(n?"Done":"Failed")))),r}var an=R.ConfirmOverlay;function ac(e){return u(an,"div",{class:"wb-confirm",role:"alertdialog","aria-label":e.prompt},!$(e.icon)&&ue(e.icon,"medium","wb-confirm__icon"),u(an,"div",{class:"wb-confirm__prompt"},e.prompt),u(an,"div",{class:"wb-confirm__buttons"},u(an,"button",{type:"button",class:"wb-confirm__cancel","aria-label":"Cancel","data-wb-tap":"cancel"},ue("close")),u(an,"button",{type:"button",class:"wb-confirm__ok","aria-label":"Confirm","data-wb-tap":"confirm"},ue("check"))))}var Wn=R.WatchOverview;function ei(e,t){let n=`${t.idPrefix??"wbp"}-ov`,{confirm:r,feedback:o,screen:s,...i}=t;return u(Wn,"div",{class:"wb-overview","data-wb-overview":!0},rc(e).map((a,l)=>u(Wn,"figure",{class:"wb-overview__item","data-wb-surface":a.key,"data-wb-key":`overview-${a.key}`},u(Wn,"div",{class:"wb-overview__watch"},ao(e,{...i,surface:a.key,idPrefix:`${n}-${l}`})),u(Wn,"figcaption",{class:"wb-overview__label"},a.label))))}var lc=[":scope > .wb-stack--vertical > .wb-stack__header",":scope > .wb-stack--vertical > .wb-stack__children > :not(.wb-list)",":scope > .wb-stack--vertical > .wb-stack__children > .wb-list > *",":scope > .wb-list > *",":scope > :not(.wb-stack--vertical):not(.wb-list):not(.wb-data-error)"].join(",");function cc(e){if(e<=0)return 0;if(e>=1)return 1;let t=(o,s,i)=>3*s*o*(1-o)**2+3*i*o*o*(1-o)+o**3,n=0,r=1;for(let o=0;o<30;o++){let s=(n+r)/2;t(s,.3,.7)<e?n=s:r=s}return t((n+r)/2,0,1)}var Gn=(e,t,n)=>e+(t-e)*n,lo=e=>Math.min(Math.max(e,0),1);function pc(e,t,n,r){let o=m=>le.effects[m]??0,s=lo((e.widthDp-o("edgeSpecSmallScreenWidth"))/(o("edgeSpecLargeScreenWidth")-o("edgeSpecSmallScreenWidth"))),i=m=>Gn(o(`${m}Small`),o(`${m}Large`),s),a=t/r,l=n/r,c=l-a,p=i("edgeMinElementHeight"),d=i("edgeMaxElementHeight"),b=lo((c-p)/(d-p)),y=Math.min(Gn(i("edgeMinTransitionArea"),i("edgeMaxTransitionArea"),b),(1+c)/2);return lo(l<1-a?l/y:(1-a)/y)}function po(e,t){for(let r of e.querySelectorAll(".wb-screen-view .wb-scroll"))ti(r,t);let n=e.ownerDocument.fonts;n&&n.status!=="loaded"&&n.ready.then(()=>{e.isConnected&&po(e,t)})}function ti(e,t){let n=e.firstElementChild;if(!n)return;e.dataset.wbWear||(e.dataset.wbWear="1",e.addEventListener("scroll",()=>ti(e,t),{passive:!0}));let r=[...n.querySelectorAll(lc)];for(let x of r)x.style.removeProperty("scale"),x.style.removeProperty("opacity"),x.style.removeProperty("margin-bottom"),x.style.removeProperty("transform-origin");let o=e.clientHeight;if(o<=0||r.length===0)return co(e,t,0,0);let s=t.density,i=e.getBoundingClientRect(),a=i.height/o||1,l=r.map(x=>(x.getBoundingClientRect().top-i.top)/a),c=r.map(x=>x.getBoundingClientRect().height/a),p=n.scrollHeight<=o+.5,d=l.map((x,g)=>g===0?0:x-(l[g-1]+c[g-1])),b=Dr(t,0).scale,y=le.effects.edgeAlpha??.5,m=r.map(()=>1),T=m,E=l;for(let x=0;x<3;x++){let g=c.map((S,J)=>S-Math.ceil(S*T[J]*s)/s),M=l[0]+(p?g.reduce((S,J)=>S+J,0)/2:0);E=c.map((S,J)=>{M+=d[J];let _r=M;return M+=S-g[J],_r}),m=c.map((S,J)=>cc(pc(t,E[J]-d[J],E[J]+S,o))),T=m.map(S=>Gn(b,1,S))}r.forEach((x,g)=>{let M=T[g];if(m[g]>=1)return;let S=c[g];x.style.setProperty("margin-bottom",`${-(S-Math.ceil(S*M*s)/s)}px`),!x.matches(".wb-row:not(.wb-row--action)")&&(x.style.setProperty("scale",String(M)),x.style.setProperty("transform-origin","50% 0"),x.style.setProperty("opacity",String(Gn(y,1,m[g]))))});let O=-1,j=0;E.forEach((x,g)=>{let M=c[g]*T[g],S=x+M;S<=0||x>=o||(O<0&&(O=g+(x<0?-x/M:0)),j=g+(S>o?(o-x)/M:1))});let w=r.length;if(e.scrollHeight<=o)return co(e,t,0,0);let I=O<0?0:Math.min(Math.max((j-O)/w,.3),.7),z=O+(w-j);co(e,t,O<0||z<=0?0:O/z*(1-I),I)}function co(e,t,n,r){let o=e.parentElement?.querySelector(".wb-position-indicator");if(!o)return;o.style.display=r>0?"":"none";let s=Jn(t,n,r);o.querySelector(".wb-position-indicator__track")?.setAttribute("d",s.track),o.querySelector(".wb-position-indicator__thumb")?.setAttribute("d",s.thumb)}function uc(e,t){return[t.surface==="overview"&&t.screen===void 0?ei(e,t):ao(e,t)]}function ni(e,t,n){Gs(e,uc(t,n)),po(e,zn(n.deviceProfile))}var uo=new DataView(new ArrayBuffer(8)),qn=[1n];function dc(e){for(let t=qn.length;t<=e;t++)qn.push(qn[t-1]*5n);return qn[e]}function ri(e){uo.setFloat64(0,e);let t=uo.getUint32(0),n=uo.getUint32(4),r=t>>>20&2047,o=BigInt(t&1048575)<<32n|BigInt(n);return r===0?r++:o|=1n<<52n,r-=1075,o===0n?{digits:"",exp:0}:r>=0?ln((o<<BigInt(r)).toString(),0):ln((o*dc(-r)).toString(),r)}function ln(e,t){let n=0;for(;n<e.length&&e.charCodeAt(n)===48;)n++;let r=e.length;for(;r>n&&e.charCodeAt(r-1)===48;)r--,t++;return{digits:e.slice(n,r),exp:n===r?0:t}}function oi(e){let t=e.length-1;for(;t>=0&&e.charCodeAt(t)===57;)t--;return t<0?"1"+"0".repeat(e.length):e.slice(0,t)+String.fromCharCode(e.charCodeAt(t)+1)+"0".repeat(e.length-t-1)}function si(e,t){let n=-t-e.exp;if(n<=0)return e;if(n>e.digits.length)return{digits:"",exp:0};let r=e.digits.slice(0,e.digits.length-n),o=e.digits.charCodeAt(e.digits.length-n)>=53;return ln(o?oi(r||"0"):r,-t)}function fc(e,t){let n=e.digits.length-t;if(n<=0)return e;let r=e.digits.slice(0,t),o=e.digits.charCodeAt(t),s=o>53;if(o===53){let i=!1;for(let a=t+1;a<e.digits.length&&!i;a++)i=e.digits.charCodeAt(a)!==48;s=i||(r.charCodeAt(r.length-1)&1)===1}return ln(s?oi(r):r,e.exp+n)}function ii(e,t){if(e.digits==="")return["0","0".repeat(t)];let n,r;if(e.exp>=0)n=e.digits+"0".repeat(e.exp),r="";else{let o=e.digits.length+e.exp;n=o>0?e.digits.slice(0,o):"0",r=o>=0?e.digits.slice(o):"0".repeat(-o)+e.digits}return[n,r.length<t?r+"0".repeat(t-r.length):r]}function hc(e){if(e.length<=3)return e;let t=e.length%3,n=t>0?e.slice(0,t):"";for(let r=t;r<e.length;r+=3)n+=(n.length>0?",":"")+e.slice(r,r+3);return n}function cn(e,t,n,r,o){if(!Number.isFinite(e))return"";let s=ri(e),i=si(s.digits===""?s:{digits:s.digits,exp:s.exp+o},t),[a,l]=ii(i,t),c=l;if(r){let d=c.length;for(;d>0&&c.charCodeAt(d-1)===48;)d--;c=c.slice(0,d)}return(e<0&&i.digits!==""?"-":"")+(n?hc(a):a)+(c.length>0?"."+c:"")}var mc=(e,t)=>cn(e,t,!0,!1,0),gc=(e,t)=>cn(e,t,!1,!1,0),bc=(e,t)=>cn(e,t,!0,!1,2)+" %",ai=e=>cn(e,2,!0,!0,0),wc=(e,t)=>cn(e,t,!1,!0,0),yc=[[1,""],[1e3,"k"],[1e6,"M"],[1e9,"B"]];function li(e){for(let[t,n]of yc){let r=ho(Math.abs(e)/t,1);if(r<1e3||n==="B")return wc(Math.sign(e)*r,1)+n}return""}var ci=/^[NFP](?:10|[0-9])$/;function pi(e,t){if(!ci.test(t))return null;let n=Number(t.slice(1));return t[0]==="N"?mc(e,n):t[0]==="F"?gc(e,n):bc(e,n)}function fo(e){return e===null||e==="compact"||ci.test(e)}var vc=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13,1e14,1e15];function ho(e,t){if(Math.abs(e)>=1e16)return e;let n=vc[t];return xc(e*n)/n}function xc(e){let t=Math.trunc(e),n=e-t;return Math.abs(n)>=.5?t+Math.sign(n):t}var kc=9223372036854776e3;function ui(e){if(!Number.isFinite(e))return"";if(Number.isInteger(e)&&Math.abs(e)<kc)return e===0?"0":BigInt(e).toString();let t=si(fc(Tc(e),15),10),[n,r]=ii(t,0);return(e<0?"-":"")+n+(r.length>0?"."+r:"")}function Tc(e){let t=String(Math.abs(e)),n=t.indexOf("e"),r=n<0?t:t.slice(0,n),o=r.indexOf("."),s=o<0?r:r.slice(0,o)+r.slice(o+1),i=(n<0?0:Number(t.slice(n+1)))-(o<0?0:r.length-o-1),a=ln(s,i);return a.digits.length<=15?a:ri(e)}var ze=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function bo(e,t){return Object.hasOwn(e,t)?e[t]:null}function fi(e,t,n){t==="__proto__"?Object.defineProperty(e,t,{value:n,enumerable:!0,writable:!0,configurable:!0}):e[t]=n}var Sc=/^[+-]?(?:\d+\.?\d*|\.\d+)(?:[eE][+-]?\d+)?$/,Ac=/^[+-]?(?:\d[\d,]*\.?\d*|\.\d+)(?:[eE][+-]?\d+)?$/,Oc=/^[\t\n\v\f\r ]+|[\t\n\v\f\r ]+$/g,_c=/\0+$/;function _t(e,t=!1){let n=e.replace(_c,"").replace(Oc,"");if(!(t?Ac:Sc).test(n))return null;let r=Number(t?n.replaceAll(",",""):n);return Number.isFinite(r)?r:null}function X(e){return typeof e=="number"?Number.isFinite(e)?e:null:typeof e=="string"?_t(e):null}function me(e){return Number.isFinite(e)?e===0?0:e:null}function hi(e){if(typeof e=="boolean")return e;if(typeof e=="number")return Number.isFinite(e)?e!==0:null;if(typeof e=="string")switch(U(e).toLowerCase()){case"true":case"on":case"yes":case"1":return!0;case"false":case"off":case"no":case"0":return!1}return null}function Oe(e){if(e===null||e===!1)return!1;switch(typeof e){case"string":return e.length>0;case"number":return Number.isFinite(e)&&e!==0;case"boolean":return!0}if(Array.isArray(e))return e.length>0;for(let t in e)if(Object.hasOwn(e,t))return!0;return!1}function Xn(e){return e===null?!0:typeof e=="string"||Array.isArray(e)?e.length===0:ze(e)&&!Oe(e)}function Yn(e,t){if(typeof e=="number"||typeof t=="number"){let n=X(e),r=X(t);if(n!==null&&r!==null)return n===r}return Zn(e,t)}function Zn(e,t){if(e===t)return!0;if(e===null||t===null||typeof e!="object"||typeof t!="object")return!1;if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(!Zn(e[r],t[r]))return!1;return!0}if(Array.isArray(t))return!1;let n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let r of n)if(!Object.hasOwn(t,r)||!Zn(e[r],t[r]))return!1;return!0}function wo(e,t){let n=X(e),r=X(t);return n!==null&&r!==null?n<r?-1:n>r?1:0:typeof e=="string"&&typeof t=="string"?e<t?-1:e>t?1:0:null}function V(e){if(e===null)return"";switch(typeof e){case"string":return e;case"number":return ui(e);case"boolean":return e?"true":"false"}if(Array.isArray(e)){let t="";for(let n=0;n<e.length;n++)t+=(n>0?", ":"")+V(e[n]);return t}return go(e)}var Ec=/[\p{Cc}\p{Co}\p{Cn}\p{Zl}\p{Zp}\uFEFF"\\\p{Cs}]|(?! )\p{Zs}|[\u{10000}-\u{10FFFF}]/gu,Mc={'"':'\\"',"\\":"\\\\","\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r"},mo=e=>"\\u"+e.toString(16).toUpperCase().padStart(4,"0");function di(e){return'"'+e.replace(Ec,t=>Mc[t]??(t.length===1?mo(t.charCodeAt(0)):mo(t.charCodeAt(0))+mo(t.charCodeAt(1))))+'"'}function go(e){if(e===null)return"null";switch(typeof e){case"string":return di(e);case"number":return Number.isFinite(e)?JSON.stringify(e):"null";case"boolean":return e?"true":"false"}if(Array.isArray(e))return"["+e.map(go).join(",")+"]";let t="";for(let n of Object.keys(e))t+=(t?",":"")+di(n)+":"+go(e[n]);return"{"+t+"}"}function st(e,t,n){if(typeof e=="string")return ks(e,t,n);if(typeof e!="number"||!Number.isFinite(e)||e<=0)return null;let r=e<253402300799?e*1e3:e;return r>=253402300799e3?null:Math.trunc(r)}var mi=["ok","warn","error","unknown"],yo=new Map;for(let[e,t]of[["ok","ok okay success succeeded successful passed pass green up healthy online on true done complete completed good fine operational"],["warn","warn warning yellow amber orange degraded pending running in_progress in-progress queued waiting slow delayed partial unstable"],["error","error err fail failed failure red down unhealthy offline off false critical broken outage cancelled canceled"],["unknown","unknown"]])for(let n of t.split(" "))yo.set(n,e);function Rc(e){let t=yo.get(e);if(t)return t;let n=et(e),r=yo.get(n);return r&&Lr(e,n)?r:void 0}function Pc(e,t,n){if(e.op==="*"||e.operands.length===1&&e.operands[0]==="*")return e.op!=="!=";if(e.op==="="||e.op==="!="){let s=e.operands.some(i=>Lr(i,n));return e.op==="="?s:!s}let r=X(t),o=_t(e.operands[0]);if(r===null||o===null)return!1;switch(e.op){case"<":return r<o;case"<=":return r<=o;case">":return r>o;case">=":return r>=o}return!1}var Qn=new Map;function gi(e){let t=Qn.get(e);if(t!==void 0)return t;let n=Nc(e);return Qn.size>512&&Qn.clear(),Qn.set(e,n),n}function Nc(e){let t=[];for(let n of e.split(",").map(U).filter(r=>r.length>0)){let r=n.search(/[=<>!]/),o=et(U(r<0?n:n.slice(0,r)));if(!mi.includes(o))return`"${n}" must start with a state (${mi.join(", ")}), e.g. status:ok=green,warn=yellow.`;if(r<0){t.push({state:o,op:"*",operands:[]});continue}let s=n.slice(r),i=s.startsWith("<=")||s.startsWith(">=")||s.startsWith("!=")?s.slice(0,2):s.slice(0,1);if(i==="!")return`"${n}": use != for "not equal".`;let a=U(s.slice(i.length));if((i==="<"||i==="<="||i===">"||i===">=")&&_t(a)===null)return`"${n}": ${i} needs a number, e.g. warn<20.`;if(a.length===0)return`"${n}" needs a value after ${i}, e.g. ok=green.`;t.push({state:o,op:i,operands:a.split("/").map(U)})}return t}function Kn(e,t){let n=U(V(e));if(t!==null){let r=gi(t);if(typeof r!="string"){for(let o of r)if(Pc(o,e,n))return o.state}}return Rc(n)??"unknown"}function bi(e){if(e===null)return null;let t=gi(e);return typeof t=="string"?t:null}var pn=e=>e===void 0?null:e;var vo=e=>X(pn(e)),wi=e=>hi(pn(e)),yi=(e,t,n)=>st(pn(e),t,n),$c=e=>V(pn(e)),vi=e=>et(U($c(e))),xi=e=>Kn(pn(e),null);var ki=15*6e4,Bd=15*6e4;var xo=new Map([["iso","yyyy-MM-dd"],["short","d MMM"],["long","d MMMM yyyy"],["weekday","ddd"],["day","dddd"],["datetime","d MMM HH:mm"],["clock","HH:mm"],["seconds","HH:mm:ss"]]);function ko(e){return typeof e!="string"||X(e)!==null?e:_t(e,!0)??e}var jc=/^[0-9]+$/,Ti=(e,t,n)=>jc.test(e)&&Number(e)>=t&&Number(e)<=n,Si=e=>t=>t===null?`needs an argument, e.g. ${e}.`:null;function zc(e,t){let n=X(ko(e));return n===null||!fo(t)?null:t===null||t===""?ai(n):t==="compact"?li(n):pi(n,t)}function Cc(e,t){let n=X(ko(e));return n===null?null:me(ho(n,t===null?0:Number(t)))}function Ai(e,t,n,r){let o=st(e,n.relativeTo,n.zone);if(o===null)return null;let s=t===null?r:xo.get(t)??t;return $r(s)?ys(o,n.zone,s):null}function Oi(e){return e===null||xo.has(e)||$r(e)?null:`"${e}" is not a supported date format. Use a pattern from the tokens yyyy yy MMMM MMM MM M dddd ddd dd d HH H hh h mm m ss s tt (with 'quoted' literals), such as 'HH:mm' or 'd MMM', or one of: ${[...xo.keys()].join(", ")}.`}var er=new Map;function _i(e){if(e===null||U(e).length===0)return null;let t=er.get(e);return t!==void 0||(t=Ic(e),er.size>512&&er.clear(),er.set(e,t)),t}function Ic(e){let t=[],n="",r="",o=!1;for(let s=0;s<=e.length;s++){if(s===e.length||e[s]===","){if(!o)return null;t.push([U(n),U(r)]),n=r="",o=!1;continue}let i=e[s],a=e[s+1];if(i==="\\"&&(a==="="||a===","||a==="\\")){o?r+=a:n+=a,s++;continue}if(i==="="&&!o){o=!0;continue}o?r+=i:n+=i}return t}function Jc(e,t){let n=_i(t);if(n===null)return null;let r=V(e),o=null;for(let[s,i]of n){if(s==="*"){o??(o=i);continue}if(e!==null&&s===r)return i}return o}function Dc(e,t){let n=Number(t);return Array.isArray(e)?e.slice(0,n):typeof e=="string"?ds(e,n):e}var tr=new Map([["default",{apply:(e,t)=>Xn(e)?t??"":e}],["upper",{apply:e=>e===null?null:Tn(V(e))}],["lower",{apply:e=>e===null?null:et(V(e))}],["prefix",{apply:(e,t)=>Xn(e)?e:t+V(e),validate:Si("prefix:'text '")}],["suffix",{apply:(e,t)=>Xn(e)?e:V(e)+t,validate:Si("suffix:' km'")}],["number",{apply:zc,validate:e=>fo(e)?null:`"${e}" is not a supported number format. Use number (default), number:compact, number:N0\u2013N10, number:F0\u2013F10 or number:P0\u2013P10.`}],["round",{apply:Cc,validate:e=>e===null||Ti(e,0,10)?null:"round takes a number of decimals from 0 to 10, e.g. round:1."}],["date",{apply:(e,t,n)=>Ai(e,t,n,"yyyy-MM-dd"),validate:Oi}],["time",{apply:(e,t,n)=>Ai(e,t,n,"HH:mm"),validate:Oi}],["relative",{apply:(e,t,n)=>{let r=st(e,n.relativeTo,n.zone);return r===null?null:Ss(r,n.now,t==="compact"||t==="short")},validate:e=>e===null||e==="compact"||e==="short"?null:'relative takes no argument, or "compact" (e.g. "5 min" instead of "in 5 min").'}],["take",{apply:Dc,validate:e=>e!==null&&Ti(e,0,1e3)?null:"take needs a count, e.g. take:3."}],["status",{apply:(e,t)=>Kn(ko(e),t),validate:bi}],["lookup",{apply:Jc,validate:e=>(_i(e)?.length??0)>0?null:"lookup needs rules such as lookup:METRO=train,BUS=bus,*=train (write a literal = or , as \\= or \\,)."}]]);var Vc=1e4;function H(e,t){switch(e.kind){case"literal":return e.value;case"path":return Fc(e.segments,t);case"postfix":return Li(H(e.target,t),e.segments,0);case"array":{let n=new Array(e.items.length);for(let r=0;r<e.items.length;r++)n[r]=H(e.items[r],t);return n}case"unary":{let n=H(e.operand,t);if(e.op==="not")return!Oe(n);let r=X(n);return r===null?null:me(-r)}case"ternary":return Oe(H(e.condition,t))?H(e.then,t):H(e.otherwise,t);case"binary":return Bc(e.op,e.left,e.right,t);case"pipeline":{let n=H(e.input,t);for(let r of e.filters)n=Uc(r,n,t);return n}}}function Bc(e,t,n,r){switch(e){case"and":{let l=H(t,r);return Oe(l)?H(n,r):l}case"or":{let l=H(t,r);return Oe(l)?l:H(n,r)}case"??":return H(t,r)??H(n,r)}let o=H(t,r),s=H(n,r);switch(e){case"~":return V(o)+V(s);case"==":return Yn(o,s);case"!=":return!Yn(o,s);case"<":case"<=":case">":case">=":{let l=wo(o,s);return l===null?null:e==="<"?l<0:e==="<="?l<=0:e===">"?l>0:l>=0}case"in":return Ei(o,s);case"not in":return!Ei(o,s)}let i=X(o),a=X(s);if(i===null||a===null)return null;switch(e){case"+":return me(i+a);case"-":return me(i-a);case"*":return me(i*a);case"/":return a===0?null:me(i/a);case"%":return a===0?null:me(i%a)}return null}function Ei(e,t){if(Array.isArray(t)){for(let n of t)if(Yn(e,n))return!0;return!1}return ze(t)?Object.hasOwn(t,V(e)):typeof t=="string"?t.includes(V(e)):!1}function Fc(e,t){let n=e[0];if(typeof n!="string")return null;let r;switch(n){case"$root":r=t.root;break;case"$item":r=t.item??null;break;case"$index":return t.index!==void 0&&e.length===1?t.index:null;case"$now":return e.length===1?qt(t.now):null;case"$secret":{let o=e[1];return e.length!==2||typeof o!="string"||t.secrets===void 0?null:t.secrets(o)??null}default:if(n.charCodeAt(0)===36){let o=n.slice(1);r=o==="params"&&t.params!==void 0?t.params:t.vars!==void 0&&Object.hasOwn(t.vars,o)?t.vars[o]:null}else if(t.item!==void 0&&ze(t.item)&&Object.hasOwn(t.item,n))r=t.item[n];else if(ze(t.root))r=bo(t.root,n);else return null}return Li(r,e,1)}function Li(e,t,n){for(let r=n;r<t.length&&e!==null;r++){let o=t[r];if(typeof o=="string")e=ze(e)?bo(e,o):null;else if(Array.isArray(e)){let s=o.index<0?e.length+o.index:o.index;e=s>=0&&s<e.length?e[s]:null}else e=null}return e}function Uc(e,t,n){try{let r=tr.get(e.name);if(r)return r.apply(t,e.argument,n);switch(e.name){case"where":{if(!Array.isArray(t))return null;let o=[];return nr(e,t,n,(s,i)=>{Oe(i)&&o.push(s)})?o:null}case"map":{if(!Array.isArray(t))return null;let o=[];return nr(e,t,n,(s,i)=>{o.push(i)})?o:null}case"find":return Array.isArray(t)?Hc(e,t,n):null;case"sortBy":return Array.isArray(t)?Wc(e,t,n):null;case"indexBy":return Array.isArray(t)?qc(e,t,n):null;case"count":return Zc(e,t,n);case"sum":return Xc(e,t,n);case"first":return Array.isArray(t)&&t.length>0?t[0]:null;case"last":return Array.isArray(t)&&t.length>0?t[t.length-1]:null;case"join":{if(!Array.isArray(t))return null;let o=e.args.length>0?V(H(e.args[0],n)):", ",s="";for(let i=0;i<t.length;i++)s+=(i>0?o:"")+V(t[i]);return s}case"toNumber":{let o=X(t);return o===null?null:me(o)}case"toText":return V(t);case"toTime":{let o=st(t,n.relativeTo,n.zone);return o===null?null:qt(o)}}return t}catch{return null}}function Ri(e){return e.lambdaLimitHit?!1:++e.lambdaEvaluations<=Vc?!0:(e.lambdaLimitHit=!0,!1)}function nr(e,t,n,r){let o=e.args[0],s=n.item,i=n.index;try{for(let a=0;a<t.length;a++){if(!Ri(n))return!1;let l=t[a];n.item=l,n.index=a;let c=H(o,n);n.item=s,n.index=i,r(l,c)}}finally{n.item=s,n.index=i}return!n.lambdaLimitHit}function To(e,t,n){let r=[];return nr(e,t,n,(o,s)=>{r.push(s)})?r:null}function Hc(e,t,n){let r=null,o=!1,s=e.args[0],i=n.item,a=n.index;try{for(let l=0;l<t.length&&!o;l++){if(!Ri(n))return null;n.item=t[l],n.index=l,Oe(H(s,n))&&(r=t[l],o=!0)}}finally{n.item=i,n.index=a}return r}function Wc(e,t,n){let r=To(e,t,n);if(r===null)return null;let o=e.args.length>1&&V(H(e.args[1],n))==="desc",s=t.map((i,a)=>a);return s.sort((i,a)=>Gc(r[i],r[a],o)||i-a),s.map(i=>t[i])}function Gc(e,t,n){if(e===null||t===null)return e===null?t===null?0:1:-1;let r=wo(e,t);return r===null&&(r=Mi(e)-Mi(t),r===0&&typeof e=="boolean"&&typeof t=="boolean"?r=e===t?0:e?1:-1:r=Math.sign(r)),n?-r:r}var Mi=e=>typeof e=="number"?0:typeof e=="string"?1:typeof e=="boolean"?2:3;function qc(e,t,n){let r=To(e,t,n);if(r===null)return null;let o={};for(let s=0;s<t.length;s++){let i=V(r[s]);Object.hasOwn(o,i)||fi(o,i,t[s])}return o}function Zc(e,t,n){if(Array.isArray(t)){if(e.args.length===0)return t.length;let r=0;return nr(e,t,n,(o,s)=>{Oe(s)&&r++})?r:null}return ze(t)?Object.keys(t).length:typeof t=="string"?us(t):null}function Xc(e,t,n){if(!Array.isArray(t))return null;let r=e.args.length>0?To(e,t,n):t;if(r===null||n.lambdaLimitHit)return null;let o=0;for(let s of r){let i=X(s);i!==null&&(o+=i)}return me(o)}var ge=e=>({kind:"text",optional:e}),Pi=e=>({kind:"expr",optional:e}),it=e=>({kind:"lambda",optional:e}),Ni={number:[ge(!0)],date:[ge(!0)],time:[ge(!0)],relative:[ge(!0)],upper:[],lower:[],default:[ge(!0)],take:[ge(!1)],status:[ge(!0)],round:[ge(!0)],prefix:[ge(!1)],suffix:[ge(!1)],lookup:[ge(!1)],where:[it(!1)],map:[it(!1)],sortBy:[it(!1),Pi(!0)],find:[it(!1)],count:[it(!0)],sum:[it(!0)],indexBy:[it(!1)],first:[],last:[],join:[Pi(!0)],toNumber:[],toText:[],toTime:[]},rr=new Map(Object.entries(Ni).map(([e,t])=>[e,{name:e,args:t,isText:t.length===0||t[0].kind==="text",requiredCount:t.filter(n=>!n.optional).length}])),$i=Object.keys(Ni);var ji=4096,zi=32,Ci=64;var So=e=>e==="_"||e==="$"||e!==""&&yt(e),Ao=e=>e==="_"||e==="$"||e==="-"||e!==""&&cs(e);var at=(e,t,n)=>e.startsWith(n,t);function Di(e){if(e.length>ji)return{template:null,errors:[{position:0,kind:"tooLong",length:e.length,message:`The template is ${e.length} characters long; the limit is ${ji}.`}]};let t=[],n=[],r="",o=0;for(;o<e.length;){if(e[o]==="\\"&&at(e,o+1,"{{")){r+="{{",o+=3;continue}if(!at(e,o,"{{")){let c=o+1;for(;c<e.length&&e[c]!=="{"&&e[c]!=="\\";)c++;r+=e.slice(o,c),o=c;continue}r.length>0&&(t.push(r),r="");let a=new Oo(e,o+2,n),l=a.parseExpression();if(l&&t.push(l),a.unclosed)break;o=a.pos}if(r.length>0&&t.push(r),n.length>0)return n.sort((a,l)=>a.position-l.position),{template:null,errors:n};let s=null,i=0;for(let a of t){if(typeof a=="string"){Ke(a)||(i=2);continue}i++,s=a.expr}return{template:{source:e,parts:t,single:i===1?s:null},errors:[]}}var Ii={failed:!0},Oo=class{constructor(t,n,r){C(this,"text");C(this,"errors");C(this,"open");C(this,"pos");C(this,"unclosed",!1);C(this,"depth",0);C(this,"parens",0);C(this,"filterCalls",0);C(this,"hasFailed",!1);this.text=t,this.errors=r,this.open=n-2,this.pos=n}parseExpression(){this.skipSpace();let t=this.pos;if(this.atEnd())return this.unclosedAt();if(this.atClose())return this.error(this.open,"syntax","Empty expression: put a data path inside {{ }}, e.g. {{ source.field }}.",4),this.pos+=2,null;let n;try{if(n=this.parsePipeline(),this.skipSpace(),this.atEnd())return this.unclosedAt();this.atClose()||this.fail(this.pos,this.peek()==="}"?`Expected "}}" to close the expression at position ${this.pos}.`:`Unexpected "${this.peek()}" at position ${this.pos}: expected "|" followed by a filter, or "}}".`)}catch(o){if(o!==Ii)throw o;return this.recover(),null}let r=U(this.text.slice(t,this.pos));return this.pos+=2,{expr:n,text:r,position:t}}parsePipeline(){this.enter();let t=this.parseExpr(),n=[];for(;this.skipSpace(),this.peek()==="|";)this.pos++,n.push(this.parseFilter());return this.leave(),n.length===0?t:{kind:"pipeline",input:t,filters:n,position:t.position}}parseExpr(){this.enter();let t=this.parseCoalesce();if(this.skipSpace(),this.peek()==="?"&&this.peekAt(1)!=="?"){this.pos++;let n=this.parseExpr();this.skipSpace(),this.peek()!==":"&&this.fail(this.pos,`Expected ":" at position ${this.pos} to complete "condition ? a : b".`),this.pos++;let r=this.parseExpr();t={kind:"ternary",condition:t,then:n,otherwise:r,position:t.position}}return this.leave(),t}parseCoalesce(){let t=this.parseOr();for(;this.skipSpaceThen("??");)this.pos+=2,t={kind:"binary",op:"??",left:t,right:this.parseOr(),position:t.position};return t}parseOr(){let t=this.parseAnd();for(;this.skipSpaceThenKeyword("or");)this.pos+=2,t={kind:"binary",op:"or",left:t,right:this.parseAnd(),position:t.position};return t}parseAnd(){let t=this.parseNot();for(;this.skipSpaceThenKeyword("and");)this.pos+=3,t={kind:"binary",op:"and",left:t,right:this.parseNot(),position:t.position};return t}parseNot(){if(this.skipSpaceThenKeyword("not")){let t=this.pos;this.pos+=3,this.enter();let n=this.parseNot();return this.leave(),{kind:"unary",op:"not",operand:n,position:t}}return this.parseComparison()}parseComparison(){let t=this.parseConcat(),n=this.readComparisonOperator(!1);if(n===null)return t;let r=this.parseConcat(),o={kind:"binary",op:n,left:t,right:r,position:t.position},s=this.readComparisonOperator(!0);return s!==null&&this.fail(this.pos,`Comparisons cannot be chained ("a < b < c"); combine them with "and". Found "${s}" at position ${this.pos}.`),o}readComparisonOperator(t){this.skipSpace();let n=null,r=0;for(let s of["==","!=","<=",">="])at(this.text,this.pos,s)&&(n=s,r=2);let o=this.peek();if(n===null&&(o==="<"||o===">")&&(n=o,r=1),n===null&&this.isKeywordAt(this.pos,"in")&&(n="in",r=2),n===null&&this.isKeywordAt(this.pos,"not")){let s=this.pos+3;for(;s<this.text.length&&Qe(this.text.charCodeAt(s));)s++;this.isKeywordAt(s,"in")&&(n="not in",r=s+2-this.pos)}return n!==null&&!t&&(this.pos+=r),n}parseConcat(){let t=this.parseAdditive();for(;this.skipSpaceThen("~");)this.pos++,t={kind:"binary",op:"~",left:t,right:this.parseAdditive(),position:t.position};return t}parseAdditive(){let t=this.parseMultiplicative();for(;;){this.skipSpace();let n=this.peek();if(n!=="+"&&n!=="-")return t;this.pos++,t={kind:"binary",op:n,left:t,right:this.parseMultiplicative(),position:t.position}}}parseMultiplicative(){let t=this.parseUnary();for(;;){this.skipSpace();let n=this.peek();if(n!=="*"&&n!=="/"&&n!=="%")return t;this.pos++,t={kind:"binary",op:n,left:t,right:this.parseUnary(),position:t.position}}}parseUnary(){if(this.skipSpace(),this.peek()!=="-")return this.parsePostfix();let t=this.pos++;this.enter();let n=this.parseUnary();return this.leave(),n.kind==="literal"&&typeof n.value=="number"?{kind:"literal",value:-n.value,position:t}:{kind:"unary",op:"-",operand:n,position:t}}parsePostfix(){this.skipSpace();let t=this.pos,n=this.peek();if(this.atEnd())throw this.unclosedFailure();if(n==="("){this.pos++,this.parens++;let s=this.parsePipeline();if(this.skipSpace(),this.atEnd())throw this.unclosedFailure();return this.peek()!==")"&&this.fail(this.pos,`Expected ")" at position ${this.pos} to close the "(" at position ${t}.`),this.pos++,this.parens--,this.withSegments(s,t)}if(n==="["){this.pos++;let s=[];if(this.skipSpace(),this.peek()!=="]")for(;;){if(s.push(this.parseExpr()),this.skipSpace(),this.peek()===","){this.pos++;continue}if(this.peek()==="]")break;if(this.atEnd())throw this.unclosedFailure();this.fail(this.pos,`Expected "," or "]" at position ${this.pos} in the array starting at position ${t}.`)}return this.pos++,this.withSegments({kind:"array",items:s,position:t},t)}if(n==="'"||n==='"')return this.withSegments({kind:"literal",value:this.readString(),position:t},t);if(Pe(n))return this.withSegments(this.readNumber(),t);So(n)||this.fail(this.pos,`Expected a data path or a literal at position ${this.pos}, found "${n}". Example: {{ source.field }}.`);let r=this.readName();switch(r){case"true":case"false":return this.withSegments({kind:"literal",value:r==="true",position:t},t);case"null":return this.withSegments({kind:"literal",value:null,position:t},t);case"and":case"or":case"not":case"in":this.fail(t,`"${r}" is a keyword and cannot start a path (position ${t}). Use $item.${r} or ['${r}'].`)}let o=[r];return this.readSegments(o,t),{kind:"path",segments:o,position:t}}withSegments(t,n){let r=[];return this.readSegments(r,n),r.length===0?t:{kind:"postfix",target:t,segments:r,position:n}}readSegments(t,n){for(;;){let r=this.peek();if(r==="."){this.pos++,So(this.peek())||this.fail(this.pos,`Invalid path "${this.snippet(n)}": expected a field name after "." at position ${this.pos}.`),t.push(this.readName());continue}if(r!=="[")return;let o=this.pos++;if(this.skipSpace(),this.peek()==="'"||this.peek()==='"')t.push(this.readString());else{let s=this.pos;for(this.peek()==="-"&&this.pos++;Pe(this.peek());)this.pos++;let i=this.text.slice(s,this.pos),a=Number(i);(i===""||i==="-"||!Number.isInteger(a)||a>2147483647||a<-2147483648)&&this.fail(o,`Invalid index in "${this.snippet(n)}" at position ${o}: use a whole number such as [0] or [-1], or a quoted key such as ['name'].`),t.push({index:a===0?0:a})}this.skipSpace(),this.peek()!=="]"&&this.fail(this.pos,`Expected "]" at position ${this.pos} in "${this.snippet(n)}".`),this.pos++}}parseFilter(){this.skipSpace();let t=this.pos;So(this.peek())||this.fail(this.pos,`Expected a filter name after "|" at position ${this.pos}. Allowed: ${Ji()}.`);let n=this.readName();if(++this.filterCalls>Ci)throw this.error(t,"tooLong",`More than ${Ci} filter calls in one expression.`,n.length),this.markFailed();this.skipSpace();let r=rr.get(n);if(!r)throw this.error(t,"unknownFilter",`Unknown filter "${n}" at position ${t}. Allowed: ${Ji()}.`,n.length,n),this.markFailed();if(r.isText){let i=null,a=this.pos;this.peek()===":"&&(this.pos++,this.skipSpace(),a=this.pos,i=this.peek()==="'"||this.peek()==='"'?this.readString():this.readBareArgument()),r.args.length===0&&i!==null&&this.invalidArgument(n,a,`Filter "${n}" at position ${t} takes no argument.`);let l=tr.get(n)?.validate?.(i)??null;return l!==null&&this.invalidArgument(n,a,`Filter "${n}" at position ${t}: ${l}`),{name:n,argument:i,args:[],position:t}}let o=[],s=this.pos;if(this.peek()===":")for(this.pos++,s=this.pos;o.push(this.parseExpr()),this.skipSpace(),this.peek()===",";)this.pos++;return o.length<r.requiredCount&&this.invalidArgument(n,s,`Filter "${n}" at position ${t} needs an argument, e.g. ${Yc(n)}.`),o.length>r.args.length&&this.invalidArgument(n,s,`Filter "${n}" at position ${t} takes at most ${r.args.length} argument(s).`),{name:n,argument:null,args:o,position:t}}invalidArgument(t,n,r){throw this.error(n,"invalidArgument",r,Math.max(1,this.pos-n),t),this.markFailed()}readBareArgument(){let t=this.pos;for(;!this.atEnd()&&!this.atClose()&&this.peek()!=="|"&&!(this.parens>0&&this.peek()===")");)this.pos++;return U(this.text.slice(t,this.pos))}readString(){let t=this.text[this.pos],n=this.pos++,r="";for(;!this.atEnd();){let o=this.text[this.pos++];if(o===t)return r;if(o==="\\"&&!this.atEnd()){let s=this.text[this.pos++];r+=s==="n"?`
3
- `:s==="t"?" ":s;continue}r+=o}return this.unclosed=!0,this.fail(n,`Unterminated string starting at position ${n}: add a closing ${t}.`)}readNumber(){let t=this.pos;for(;Pe(this.peek());)this.pos++;if(this.peek()==="."&&Pe(this.peekAt(1)))for(this.pos++;Pe(this.peek());)this.pos++;let n=this.peek();if((n==="e"||n==="E")&&(Pe(this.peekAt(1))||(this.peekAt(1)==="+"||this.peekAt(1)==="-")&&Pe(this.peekAt(2))))for(this.pos+=2;Pe(this.peek());)this.pos++;let r=Number(this.text.slice(t,this.pos));return Number.isFinite(r)||this.fail(t,`Invalid number "${this.text.slice(t,this.pos)}" at position ${t}.`),{kind:"literal",value:r,position:t}}readName(){let t=this.pos++;for(;Ao(this.peek());)this.pos++;return this.text.slice(t,this.pos)}isKeywordAt(t,n){let r=this.text;return at(r,t,n)&&!(t+n.length<r.length&&Ao(r[t+n.length]))&&!(t>0&&Ao(r[t-1]))}skipSpaceThen(t){return this.skipSpace(),at(this.text,this.pos,t)}skipSpaceThenKeyword(t){return this.skipSpace(),this.isKeywordAt(this.pos,t)}enter(){if(++this.depth>zi)throw this.error(this.pos,"tooDeep",`The expression is nested more than ${zi} levels deep at position ${this.pos}.`),this.markFailed()}leave(){this.depth--}unclosedAt(){return this.hasFailed||this.error(this.open,"syntax",`Unclosed "{{" at position ${this.open}: add a matching "}}".`,2),this.unclosed=!0,this.pos=this.text.length,null}unclosedFailure(){return this.unclosedAt(),this.markFailed()}recover(){if(this.unclosed){this.pos=this.text.length;return}let t=this.text.indexOf("}}",Math.min(this.pos,this.text.length));if(t<0){this.unclosed=!0,this.pos=this.text.length;return}this.pos=t+2}markFailed(){return this.hasFailed=!0,Ii}error(t,n,r,o=1,s){this.errors.push(s===void 0?{position:t,kind:n,length:o,message:r}:{position:t,kind:n,length:o,message:r,filter:s})}fail(t,n){throw this.hasFailed||this.error(t,"syntax",n),this.markFailed()}snippet(t){let n=t,r=this.text;for(;n<r.length&&!at(r,n,"}}")&&r[n]!=="|"&&!Qe(r.charCodeAt(n));)n++;return r.slice(t,n)}skipSpace(){for(;this.pos<this.text.length&&Qe(this.text.charCodeAt(this.pos));)this.pos++}atEnd(){return this.pos>=this.text.length}atClose(){return at(this.text,this.pos,"}}")}peek(){return this.pos<this.text.length?this.text[this.pos]:""}peekAt(t){let n=this.pos+t;return n>=0&&n<this.text.length?this.text[n]:""}},Ji=()=>[...$i].sort().join(", ");function Yc(e){switch(e){case"where":return"where: price > 10";case"map":return"map: name";case"sortBy":return"sortBy: expected";case"find":return"find: id == 3";case"indexBy":return"indexBy: entity_id";default:return e+": x"}}var Qc=new Set(["$item","$index","$now","$params","$secret","$response"]);function Bi(e,t,n,r){let o=[];for(let s of e.parts)typeof s!="string"&&be(s.expr,t,n,r,o);return o}function be(e,t,n,r,o){switch(e.kind){case"path":{let s=Kc(e.segments,t,n,r);s&&o.push(s);break}case"postfix":be(e.target,t,n,r,o);break;case"array":for(let s of e.items)be(s,t,n,r,o);break;case"unary":be(e.operand,t,n,r,o);break;case"binary":be(e.left,t,n,r,o),be(e.right,t,n,r,o);break;case"ternary":be(e.condition,t,n,r,o),be(e.then,t,n,r,o),be(e.otherwise,t,n,r,o);break;case"pipeline":be(e.input,t,n,r,o);for(let s of e.filters){let i=rr.get(s.name);s.args.forEach((a,l)=>{let c=i!==void 0&&l<i.args.length&&i.args[l].kind==="lambda";be(a,c||t,n,c?void 0:r,o)})}break}}function Kc(e,t,n,r){let o=e[0];return typeof o!="string"?null:o==="$root"?typeof e[1]=="string"?{source:e[1],key:Vi(e,2)}:null:Qc.has(o)||o.startsWith("$")||t&&!(n(o)&&!(r!==void 0&&ze(r)&&Object.hasOwn(r,o)))?null:{source:o,key:Vi(e,1)}}var Vi=(e,t)=>{let n=e[t];return typeof n=="string"?n:null};function Fi(e){for(let t of e.parts)if(typeof t!="string"&&we(t.expr))return!0;return!1}function we(e){switch(e.kind){case"literal":return!1;case"path":return e.segments[0]==="$now";case"postfix":return we(e.target);case"array":return e.items.some(we);case"unary":return we(e.operand);case"binary":return we(e.left)||we(e.right);case"ternary":return we(e.condition)||we(e.then)||we(e.otherwise);case"pipeline":return we(e.input)||e.filters.some(t=>t.name==="relative"||t.args.some(we))}}var sr="Europe/Stockholm",ep=4096,or=new Map;function un(e){let t=or.get(e);return t===void 0&&(or.size>=ep&&or.clear(),t=Di(e),or.set(e,t)),t}function Ui(e){return un(e).template}function Hi(e){return{root:e.root??null,now:e.now,relativeTo:e.dataTime??e.now,zone:e.timeZone??sr,item:e.item,index:e.index,params:e.params,vars:e.vars,secrets:e.secrets,lambdaEvaluations:0,lambdaLimitHit:!1}}function Wi(e,t){let n=e.parts;if(n.length===1&&typeof n[0]=="string")return n[0];let r="";for(let o of n)r+=typeof o=="string"?o:V(H(o.expr,t));return r}function ne(e,t){if(!e)return"";let n=un(e).template;return n===null?"":Wi(n,Hi(t))}function Fe(e,t){if(!e)return null;let n=un(e).template;if(n===null)return null;let r=Hi(t);return n.single!==null?H(n.single,r):Wi(n,r)}function _o(e,t){if(Ke(e))return null;let n=U(e);return Fe(n.startsWith("{{")?n:`{{ ${n} }}`,t)}function Gi(e){let t=un(e);return t.readsClock===void 0&&(t.readsClock=t.template!==null&&Fi(t.template)),t.readsClock}function tp(e,t,n,r){let o=un(e).template;return o===null?[]:Bi(o,t,n,r)}function Et(e,t,n,r){return[...new Set(tp(e,t,n,r).map(o=>o.source))]}var qi=1,Eo=1,Mt=class extends Error{},_e=e=>typeof e=="object"&&e!==null&&!Array.isArray(e),Q=e=>typeof e=="string"?e:void 0,ir=(e,t)=>typeof e=="number"&&Number.isInteger(e)?e:t;function ar(e,t){let n=e[t];if(typeof n!="string")throw new Mt(`Bundle does not match schema/bundle.schema.json: "${t}" is required.`);return n}function Zi(e,t){let n={};if(_e(e))for(let[r,o]of Object.entries(e))_e(o)&&(n[r]=t(o));return n}function dn(e,t){for(let[n,r]of Object.entries(t))r!==void 0&&(e[n]=r);return e}function Xi(e){let t=ir(e.bundleVersion,qi);if(t!==qi)throw new Mt(`Unsupported bundleVersion ${t}.`);let n=ir(e.engine,Eo);if(n>Eo)throw new Mt(`The bundle needs engine ${n}; this build has ${Eo}.`);let r=e.entry,o=e.tile;if(!_e(r)||!_e(o)||!_e(e.pages))throw new Mt("Bundle does not match schema/bundle.schema.json: entry, pages and tile are required.");let s={};for(let[a,l]of Object.entries(e.pages))_e(l)&&(s[a]=l);let i={bundleVersion:t,schemaVersion:ir(e.schemaVersion,2),engine:n,experienceId:ar(e,"experienceId"),localId:ar(e,"localId"),version:ir(e.version,1),timeZone:Q(e.timeZone)??sr,entry:dn({title:ar(r,"title")},{subtitle:Q(r.subtitle),icon:Q(r.icon),iconUrl:Q(r.iconUrl),description:Q(r.description)}),main:ar(e,"main"),pages:s,tile:o,sources:Zi(e.sources,a=>dn({mode:Q(a.mode)??"proxied",ref:Q(a.ref)??"",raw:a},{refresh:_e(a.refresh)?a.refresh:void 0,push:Q(a.push)})),actions:Zi(e.actions,a=>{let l=a.toast,c=a.refresh;return dn({kind:Q(a.kind)??"http"},{mode:Q(a.mode),source:Q(a.source),screen:Q(a.screen),confirm:Q(a.confirm),toast:_e(l)?dn({},{success:Q(l.success),failure:Q(l.failure)}):void 0,refresh:Array.isArray(c)?c.filter(p=>typeof p=="string"):void 0})})};return dn(i,{projectId:Q(e.projectId),publishedAt:Q(e.publishedAt),complication:_e(e.complication)?e.complication:void 0,sample:_e(e.sample)?e.sample:void 0})}var Yi=new Set(["add","alarm","arrow-down","arrow-up","battery","bell","bike","bolt","build","bus","calendar","car","check","chevron-right","clock","close","cloud","code","door","error","fan","flag","git","heart","home","info","light","lock","mail","map-pin","music","pause","phone","play","plug","power","rain","refresh","remove","robot","rocket","settings","ship","snow","star","stop","sun","temp","thermometer","timer","train","tram","unlock","user","walk","warning","wifi","wind"]),lt={screenListMaxRows:10,textMaxLines:3,tileListMaxRows:3,tileCompactListMaxRows:8,tileMaxButtons:2};function Lt(e){if(!e)return!1;try{let t=new URL(e);return(t.protocol==="https:"||t.protocol==="http:")&&t.hostname.length>0}catch{return!1}}var hn=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function K(e){for(let t of Object.keys(e))e[t]===void 0&&delete e[t];return e}function np(e){if(Number.isInteger(e)&&Math.abs(e)<1e15)return String(e);let[t="",n="0"]=e.toExponential().split("e"),r=Number(n);return r<15&&r>=-5?String(e):`${t}E${r<0?"-":"+"}${String(Math.abs(r)).padStart(2,"0")}`}function k(e){if(typeof e=="string")return e;if(typeof e=="boolean")return e?"true":"false";if(typeof e=="number")return Number.isFinite(e)?np(e):void 0}var Mo=e=>typeof e=="number"&&Number.isInteger(e)&&Math.abs(e)<=2147483647?e:void 0,rp=e=>typeof e=="boolean"?e:void 0;function fn(e){if(!hn(e))return;let t=e,n=k(t.id),r=typeof t.type=="string"?t.type:void 0;switch(r){case"text":return K({type:r,id:n,value:k(t.value),style:k(t.style),maxLines:Mo(t.maxLines)});case"stat":return K({type:r,id:n,value:k(t.value),unit:k(t.unit),label:k(t.label),trend:k(t.trend),icon:k(t.icon)});case"list":return K({type:r,id:n,items:Ki(t.items),item:ea(t.item),maxRows:Mo(t.maxRows),header:k(t.header),emptyText:k(t.emptyText)});case"status":return K({type:r,id:n,state:k(t.state),label:k(t.label),detail:k(t.detail)});case"progress":return K({type:r,id:n,value:k(t.value),min:k(t.min),max:k(t.max),style:k(t.style),label:k(t.label)});case"countdown":return K({type:r,id:n,target:k(t.target),format:k(t.format),label:k(t.label)});case"button":return K({type:r,id:n,label:k(t.label),icon:k(t.icon),action:k(t.action),confirm:rp(t.confirm),style:k(t.style)});case"toggle":return K({type:r,id:n,label:k(t.label),state:k(t.state),onAction:k(t.onAction),offAction:k(t.offAction),icon:k(t.icon)});case"icon":return K({type:r,id:n,icon:k(t.icon),url:k(t.url),size:k(t.size)});case"stack":{let o=t.children;return K({type:r,id:n,direction:k(t.direction),header:k(t.header),children:Array.isArray(o)?o.map(fn):[]})}default:return K({type:"unknown",id:n,typeName:r})}}function Qi(e){return hn(e)?K({title:k(e.title),root:fn(e.root)}):void 0}function Lo(e,t,n){let r=e.buttons;return K({surface:t,opens:k(e.opens)??n,template:k(e.template),kind:k(e.kind),title:k(e.title),icon:k(e.icon),url:k(e.url),text:ta(e.text),value:k(e.value),unit:k(e.unit),label:k(e.label),detail:k(e.detail),trend:k(e.trend),state:k(e.state),min:k(e.min),max:k(e.max),items:Ki(e.items),item:ea(e.item),emptyText:k(e.emptyText),buttons:Array.isArray(r)?r.map(fn):void 0,toggle:fn(e.toggle)})}function Ki(e){return typeof e=="string"?{bind:e}:hn(e)?K({bind:k(e.bind),take:Mo(e.take)}):void 0}function ea(e){if(hn(e))return K({title:k(e.title),subtitle:k(e.subtitle),trailing:ta(e.trailing),badge:k(e.badge),icon:k(e.icon),action:k(e.action)})}function ta(e){if(e!=null){if(hn(e))return K({component:fn(e)});if(!Array.isArray(e))return K({text:k(e)})}}function A(e){let t={};for(let[n,r]of Object.entries(e))r!==void 0&&(t[n]=r);return t}function Rt(e){let{type:t,...n}=e;return n}var ct=(e,t=2)=>String(e).padStart(t,"0");function pt(e){let t=new Date(e),n=`${ct(t.getUTCFullYear(),4)}-${ct(t.getUTCMonth()+1)}-${ct(t.getUTCDate())}T${ct(t.getUTCHours())}:${ct(t.getUTCMinutes())}:${ct(t.getUTCSeconds())}`,r=t.getUTCMilliseconds();return r===0?`${n}Z`:`${n}.${ct(r,3)}Z`}function ut(e,t,n){if(e===void 0||/^\s*[+-]?\d+\s*$/.test(e))return n;let r=e.replace(/-/g,"").trim().toLowerCase();return t.find(o=>o.replace(/-/g,"").toLowerCase()===r)??n}function na(e){let t=2166136261;for(let n=0;n<e.length;n++)t=Math.imul(t^e.charCodeAt(n),16777619)>>>0;return t.toString(16).padStart(8,"0")}var ra="No items",op="Are you sure?",lr=e=>typeof e=="object"&&e!==null&&!Array.isArray(e),Ro=(e,t,n)=>Math.min(Math.max(e,t),n),sa=e=>{let t=e.trim();return t.startsWith("{{")?t:`{{ ${t} }}`},cr=class{constructor(t,n,r,o,s,i){C(this,"sources",new Map);C(this,"scope");C(this,"touched",new Set);C(this,"replaceBlocked",!1);C(this,"bundle");C(this,"now");C(this,"options");C(this,"isSource",t=>this.sources.has(t));this.bundle=t,this.now=o,this.options=i;for(let a of new Set([...Object.keys(t.sources),...Object.keys(r)])){let l=n.get(a),c=l?.state??"sample",p=l?.fetchedAt??(c==="loading"?void 0:c==="stale"||c==="error"?o-i.fallbackStaleAge:o);this.sources.set(a,A({name:a,state:c,lastUpdated:p,message:c==="error"?l?.message??`Couldn't load ${a}`:void 0}))}this.scope=A({root:this.effectiveRoot(r),now:o,timeZone:s,dataTime:i.dataTime,vars:i.vars})}effectiveRoot(t){if([...this.sources.values()].map(o=>o.state).every(o=>o==="sample"||o==="live"||o==="stale"))return t;let r={};for(let[o,s]of Object.entries(t)){let i=this.sources.get(o)?.state;i==="loading"||i==="error"||(r[o]=i==="empty"?ip(s):s)}return r}screens(){let t=[];for(let[n,r]of Object.entries(this.bundle.pages)){let o=Qi(r);if(!o)continue;this.beginSurface(!0),this.track([[o.title,!1]]);let s=this.renderOrNull(o.title),i=o.root?this.node(o.root,`$.screens.${n}.root`):void 0;t.push(A({id:n,title:s,root:i,data:this.aggregate()}))}return t}tile(){let t=Lo(this.bundle.tile,"tile",this.bundle.main);return this.glance(`${this.bundle.localId}.tile`,t)}complication(){let t=this.bundle.complication;if(t)return this.glance(`${this.bundle.localId}.complication`,Lo(t,"complication",this.bundle.main))}node(t,n,r=!1){if(t.type==="unknown")return A({type:"unsupported",id:t.id,component:t.typeName??""});let o=t.type==="list"?this.firstItem(t.items):void 0,s=this.track(mn(t,r),o);if(this.replaceBlocked){let i=this.blocking(s);if(i)return i.state==="error"?A({type:"error",id:t.id,component:t.type,message:i.message??"",source:i.name}):A({type:"placeholder",id:t.id,component:t.type,rows:t.type==="list"?Ro(t.maxRows??t.items?.take??3,1,3):1})}switch(t.type){case"text":return A({type:"text",id:t.id,value:ne(t.value,this.scope),style:ut(t.style,sp,"body"),maxLines:Ro(t.maxLines??lt.textMaxLines,1,lt.textMaxLines)});case"stat":return this.stat(t);case"list":return this.list(t,n);case"status":return this.status(t);case"progress":return this.progress(t);case"countdown":return A({type:"countdown",id:t.id,target:this.timestamp(t.target),format:ut(t.format,["relative","clock"],"relative"),label:this.renderOrNull(t.label)});case"button":return this.button(t);case"toggle":return this.toggle(t,n);case"icon":{let i=this.icon(t.icon,t.url);return A({type:"icon",id:t.id,icon:i?.name,imageUrl:i?.url,size:ut(t.size,["medium","small","large"],"medium")})}case"stack":return this.stack(t,n)}}stat(t){return A({type:"stat",id:t.id,value:ne(t.value,this.scope),unit:this.renderOrNull(t.unit),label:this.renderOrNull(t.label),trend:t.trend===void 0?"none":ap(Fe(t.trend,this.scope)),icon:this.icon(t.icon,void 0)?.name})}list(t,n){let r=this.items(t.items),o=lt.screenListMaxRows,s=Math.min(t.items?.take??Number.MAX_SAFE_INTEGER,t.maxRows??o,o);return A({type:"list",id:t.id,header:this.renderOrNull(t.header),items:this.rows(t.item,r,s,n),totalCount:r.length,maxRows:Math.max(s,0),emptyText:this.renderOrNull(t.emptyText)??ra})}rows(t,n,r,o){let s=[];if(!t)return s;let i=this.scope;try{for(let a=0;a<Math.min(r,n.length);a++){this.scope={...i,item:n[a]??null,index:a};let l=`${o}.items[${a}]`,c=ne(t.title,this.scope),p=this.renderOrNull(t.subtitle),d=t.trailing?this.trailing(t.trailing,`${l}.trailing`):void 0,b=this.renderOrNull(t.badge),y=this.icon(t.icon,void 0)?.name,m=this.action(t.action);s.push(A({title:c,subtitle:p,trailing:d,badge:b,icon:y,action:m&&{...m,item:a}}))}}finally{this.scope=i}return s}trailing(t,n){if(t.component)return this.node(t.component,n,!0);let r=ne(t.text,this.scope);return r===""?void 0:{type:"text",value:r,style:"caption",maxLines:1}}firstItem(t){if(t?.bind===void 0)return;let n=_o(t.bind,this.scope);if(Array.isArray(n))return n[0];if(lr(n))for(let r in n)return n[r]}items(t){if(t?.bind===void 0)return[];let n=_o(t.bind,this.scope);return Array.isArray(n)?n:lr(n)?Object.values(n):[]}status(t){return A({type:"status",id:t.id,state:xi(Fe(t.state,this.scope)),label:this.renderOrNull(t.label),detail:this.renderOrNull(t.detail)})}progress(t,n){let r=this.number(t.min)??0,o=this.number(t.max)??100;return o<=r&&(o=r+100),A({type:"progress",id:t.id,value:Ro(this.number(t.value)??r,r,o),min:r,max:o,style:n??ut(t.style,["ring","bar"],"ring"),label:this.renderOrNull(t.label)})}button(t){return A({type:"button",id:t.id,label:ne(t.label,this.scope),icon:this.icon(t.icon,void 0)?.name,style:ut(t.style,["primary","secondary"],"primary"),action:this.action(t.action,t.confirm)})}toggle(t,n){let r=t.state?.includes("{{")?"state:"+t.state.replace(/\s/g,""):void 0,o=this.options.toggleStates,s=na(r??`path:${n}`),i=Po(o,n)??(r!==void 0?Po(o,r):void 0)??Po(o,s),a=ne(t.label,this.scope),l=i??wi(Fe(t.state,this.scope))===!0,c=this.icon(t.icon,void 0)?.name,p=this.action(t.onAction),d=this.action(t.offAction);return A({type:"toggle",id:t.id,label:a,on:l,key:s,icon:c,onAction:p&&{...p,targetState:"on"},offAction:d&&{...d,targetState:"off"}})}stack(t,n){let r=[];t.children.forEach((s,i)=>{s&&r.push(this.node(s,`${n}.children[${i}]`))});let o=r[0];return r.length>=2&&o?.type==="error"&&r.every(s=>s.type==="error"&&s.source===o.source)?A({...o,id:t.id,component:t.type}):A({type:"stack",id:t.id,direction:ut(t.direction,["vertical","horizontal"],"vertical"),header:this.renderOrNull(t.header),children:r})}glance(t,n){this.beginSurface(!1),this.track(lp(n),this.firstItem(n.items));let r=`$.glances.${t}`,o=this.renderOrNull(n.title),s=this.icon(n.icon,n.kind==="image"?n.url:void 0),i=c=>A({id:t,template:c,opens:n.opens,title:o,icon:s?.name}),a;if(n.surface==="tile")switch(n.template){case"text":a={...i("text"),text:this.contentSlot(n.text,`${r}.text`)};break;case"single-stat":a={...i("single-stat"),stat:Rt(this.stat(A({value:n.value,unit:n.unit,label:n.label,trend:n.trend})))};break;case"list3":case"compact-list":{let c=this.items(n.items),p=n.template==="list3"?lt.tileListMaxRows:lt.tileCompactListMaxRows,d=Math.min(n.items?.take??p,p);a={...i(n.template),items:this.rows(n.item,c,d,r),totalCount:c.length,emptyText:this.renderOrNull(n.emptyText)??ra};break}case"status":a={...i("status"),status:Rt(this.status({state:n.state,label:n.label,detail:n.detail}))};break;case"progress-ring":a={...i("progress-ring"),progress:Rt(this.progress(A({value:n.value,min:n.min,max:n.max,label:n.label}),"ring"))};break;case"buttons2":{let c=(n.buttons??[]).slice(0,lt.tileMaxButtons).flatMap(p=>p?.type==="button"?[Rt(this.button(p))]:[]);a={...i("buttons2"),buttons:c};break}case"toggle":{let c=n.toggle?.type==="toggle"?n.toggle:{};a={...i("toggle"),toggle:Rt(this.toggle(c,`${r}.toggle`))};break}}else if(n.kind==="shortText"||n.kind==="longText")a=A({id:t,kind:n.kind,opens:n.opens,text:this.contentSlot(n.text,`${r}.text`),title:o,icon:s?.name,imageUrl:s?.url});else if(n.kind==="rangedValue"){let c=this.progress(A({value:n.value,min:n.min,max:n.max}));a=A({id:t,kind:"rangedValue",opens:n.opens,text:n.text?this.contentSlot(n.text,`${r}.text`):void 0,title:o,icon:s?.name,imageUrl:s?.url,value:c.value,min:c.min,max:c.max})}else n.kind==="image"&&(a=A({id:t,kind:"image",opens:n.opens,icon:s?.name,imageUrl:s?.url}));if(!a)return;let l=this.aggregate();return l?{...a,data:l}:a}contentSlot(t,n){return t?.component?this.node(t.component,n):{type:"text",value:ne(t?.text,this.scope),style:"body",maxLines:3}}icon(t,n){let r=this.renderOrNull(t)?.trim();r!==void 0&&!Yi.has(r)&&(r=void 0);let o=this.renderOrNull(n)?.trim();return o!==void 0&&!Lt(o)&&(o=void 0),r===void 0&&o===void 0?void 0:A({name:r,url:o})}action(t,n){if(t===void 0||!Object.hasOwn(this.bundle.actions,t))return;let r=this.bundle.actions[t],o=r.kind==="refreshSource"||r.kind==="openScreen"||r.kind==="connector"?r.kind:"http",s=n===!1||n===void 0&&r.confirm===void 0?void 0:this.renderBlank(r.confirm)??op,i=r.toast?A({success:this.renderBlank(r.toast.success),failure:this.renderBlank(r.toast.failure)}):void 0,a=this.scope.item;return A({id:t,kind:o,screen:o==="openScreen"?r.screen:void 0,confirm:s,mode:o==="http"?r.mode??"proxied":void 0,context:a??void 0,toast:i&&(i.success!==void 0||i.failure!==void 0)?i:void 0})}timestamp(t){let n=yi(Fe(t,this.scope),this.scope.dataTime??this.now,this.scope.timeZone);return n===null?void 0:pt(n)}number(t){return t===void 0?null:vo(Fe(t,this.scope))}renderOrNull(t){if(t===void 0)return;let n=ne(t,this.scope);return n===""?void 0:n}renderBlank(t){if(t===void 0)return;let n=ne(t,this.scope);return n.trim()===""?void 0:n}beginSurface(t){this.touched.clear(),this.replaceBlocked=t}track(t,n){let r=[];for(let[o,s]of t)if(!(!o||!o.includes("{{")))for(let i of Et(o,s,this.isSource,n))this.sources.has(i)&&!r.includes(i)&&r.push(i);for(let o of r)this.touched.add(o);return r}blocking(t){let n=t.map(r=>this.sources.get(r)).filter(r=>r.state==="error"||r.state==="loading");return n.find(r=>r.state==="error")??n[0]}aggregate(){let t=[...this.sources.values()].filter(o=>this.touched.has(o.name));if(t.length===0)return;let n=t[0];for(let o of t)oa[o.state]>oa[n.state]&&(n=o);let r=t.flatMap(o=>o.lastUpdated===void 0?[]:[o.lastUpdated]);return A({state:n.state,lastUpdated:r.length?pt(Math.min(...r)):void 0,message:t.find(o=>o.state==="error")?.message,sources:t.map(o=>o.name)})}},sp=["body","title","caption","display"],oa={error:5,loading:4,stale:3,empty:2,live:1,sample:0},Po=(e,t)=>Object.hasOwn(e,t)?e[t]:void 0;function ip(e){let t=r=>Array.isArray(r)||lr(r)&&Object.values(r).some(t),n=r=>Array.isArray(r)?[]:lr(r)?Object.fromEntries(Object.entries(r).map(([o,s])=>[o,n(s)])):r;return t(e)?n(e):null}function ap(e){let t=vo(e);if(t!==null)return t>0?"up":t<0?"down":"flat";switch(vi(e)){case"up":case"rising":case"increasing":case"higher":return"up";case"down":case"falling":case"decreasing":case"lower":return"down";case"flat":case"steady":case"stable":case"same":return"flat";default:return"none"}}function mn(e,t){let n=(...r)=>r.map(o=>[o,t]);switch(e.type){case"text":return n(e.value);case"stat":return n(e.value,e.unit,e.label,e.trend,e.icon);case"list":return[...n(e.header,e.emptyText),...e.items?.bind!==void 0?n(sa(e.items.bind)):[],...ia(e.item)];case"status":return n(e.state,e.label,e.detail);case"progress":return n(e.value,e.min,e.max,e.label);case"countdown":return n(e.target,e.label);case"button":return n(e.label,e.icon);case"toggle":return n(e.label,e.state,e.icon);case"icon":return n(e.icon,e.url);case"stack":return n(e.header);case"unknown":return[]}}function ia(e){if(!e)return[];let t=[e.title,e.subtitle,e.badge,e.icon,e.trailing?.text].map(n=>[n,!0]);return e.trailing?.component&&t.push(...mn(e.trailing.component,!0)),t}function lp(e){let t=[e.title,e.icon,e.url,e.text?.text,e.value,e.unit,e.label,e.detail,e.trend,e.state,e.min,e.max,e.emptyText].map(n=>[n,!1]);e.text?.component&&t.push(...mn(e.text.component,!1)),e.items?.bind!==void 0&&t.push([sa(e.items.bind),!1]),t.push(...ia(e.item));for(let n of e.buttons??[])n?.type==="button"&&t.push(...mn(n,!1));return e.toggle&&t.push(...mn(e.toggle,!1)),t}function $o(e){let t=e.screen,n=e.surfaces.tile.theme,r=n&&{corners:n.corners.support==="supported",typeWeight:n.typeWeight.support==="supported",typeWidth:n.typeWidth.support==="supported"};return A({id:e.id,name:e.name,platform:e.platform,shape:t.shape,widthPx:t.widthPx,heightPx:t.heightPx,density:t.density,caseMm:t.caseMm,tileTheme:r})}function gn(e,t){let n=[],r=t.surfaces.screen,o=e.screens.map(a=>a.root===void 0?a:{...a,root:jo(a.root,r.components,r.limits??{},`$.screens.${a.id}.root`,n)}),s=e.tile&&cp(e.tile,t.surfaces.tile,n),i=e.complication&&pp(e.complication,t.surfaces.complication,n);return{view:A({...e,screens:o,tile:s,complication:i}),notes:n}}function Ue(e,t,n){n.support!=="supported"&&e.push(A({path:t,support:n.support,to:n.to,reason:n.reason}))}function No(e,t){return e!==void 0&&t!==void 0&&e.length>t?e.slice(0,Math.max(t,0)):e}function jo(e,t,n,r,o){let s=Object.hasOwn(t,e.type)?t[e.type]:void 0;if(!s)return e;if(s.support==="unsupported")return Ue(o,r,s),A({type:"unsupported",id:e.id,component:e.type});Ue(o,r,s);let i={...e};if(i.type==="list"){let a=s.limits?.maxRows??n.listMaxRows;a!==void 0&&i.maxRows>a&&(i.maxRows=a),i.items=No(i.items,a)}else if(i.type==="text"){let a=s.limits?.maxLines??n.textMaxLines;a!==void 0&&i.maxLines>a&&(i.maxLines=a)}else if(i.type==="stack"){let a=i;i={...a,children:a.children.map((l,c)=>jo(l,t,n,`${r}.children[${c}]`,o))}}return zo(i,s.slots,r,o)}function cp(e,t,n){let r=Object.hasOwn(t.templates,e.template)?t.templates[e.template]:void 0;if(!r)return e;if(Ue(n,"$.tile",r),r.support==="unsupported")return;let o=t.limits??{},s={...e};if(e.template==="list3"||e.template==="compact-list"){let a=r.limits?.maxRows??o[e.template==="list3"?"listMaxRows":"compactListMaxRows"],l=No(s.items,a);l&&(s.items=l)}let i=No(s.buttons,r.limits?.maxButtons??o.maxButtons);if(i&&(s.buttons=i),s.text){let a=jo(s.text,t.components,{},"$.tile.text",n),l=r.limits?.maxLines;s.text=a.type==="text"&&l!==void 0&&a.maxLines>l?{...a,maxLines:l}:a}return s=zo(s,r.slots,"$.tile",n),s}function pp(e,t,n){let r=Object.hasOwn(t.kinds,e.kind)?t.kinds[e.kind]:void 0;if(!r)return e;if(Ue(n,"$.complication",r),r.support==="unsupported")return;let o=r.limits?.maxTextChars;return o!==void 0&&e.text?.type==="text"&&[...e.text.value].length>o&&n.push({path:"$.complication.text",support:"degraded",to:`the watch face cuts it to about ${o} characters`,reason:`${e.kind} complications fit ${o} characters.`}),zo(e,r.slots,"$.complication",n)}var aa=e=>e==="url"?"imageUrl":e;function zo(e,t,n,r){if(!t)return e;let o={...e};for(let[s,i]of Object.entries(t)){if(i.support==="supported")continue;let a=s.indexOf(".");if(a<0){let d=aa(s);if(o[d]===void 0)continue;Ue(r,`${n}.${d}`,i),i.support==="unsupported"&&delete o[d];continue}let l=s.slice(0,a)==="item"?"items":s.slice(0,a),c=aa(s.slice(a+1)),p=o[l];if(Array.isArray(p)){let d=b=>b[c]!==void 0||b.action?.[c]!==void 0;if(!p.some(b=>d(b)))continue;Ue(r,`${n}.${l}[*].${c}`,i),i.support==="unsupported"&&(o[l]=p.map(b=>{let{[c]:y,...m}=b;return m}))}else if(p!==null&&typeof p=="object"){if(p.type!==c&&p[c]===void 0)continue;Ue(r,`${n}.${l}`,i)}else p===c&&Ue(r,`${n}.${l}`,i)}return o}function ca(e,t,n,r){return up(Xi(e),t,n,r)}function up(e,t,n,r={},o="all"){let s=An(r.timeZone)??tt(e.timeZone),i=r.fallbackStaleAge??ki,a=dp(e,t,n,i),l={};for(let[m,T]of a)T.data!==null&&T.data!==void 0&&(l[m]=T.data);let c=new cr(e,a,l,n,s,A({toggleStates:r.toggleStates??{},fallbackStaleAge:i,dataTime:r.dataTime,vars:r.vars})),p=o==="all"?c.screens():[],d=o==="all"||o==="tile"?c.tile():void 0,b=o==="all"||o==="complication"?c.complication():void 0,y=A({manifestVersion:2,experience:{id:e.experienceId,localId:e.localId,version:e.version},entry:fp(e,l,a,n,s,r.vars),main:e.main,generatedAt:pt(n),timeZone:s,sources:[...c.sources.values()].map(m=>A({name:m.name,state:m.state,lastUpdated:m.lastUpdated===void 0?void 0:pt(m.lastUpdated),message:m.message})),screens:p,tile:d,complication:b});return r.profile?gn(y,r.profile).view:y}function dp(e,t,n,r){let o=new Map;for(let s of Object.keys(e.sources)){let i=Object.hasOwn(t,s)?t[s]:void 0;if(i){o.set(s,i.state==="sample"&&i.fetchedAt!==void 0&&n-i.fetchedAt>r?{...i,state:"stale"}:i);continue}let a=e.sample&&Object.hasOwn(e.sample,s)?e.sample[s]??null:null;o.set(s,{data:a,state:"sample"})}return o}function fp(e,t,n,r,o,s){let i={};for(let[b,y]of Object.entries(t)){let m=n.get(b)?.state;m!=="loading"&&m!=="error"&&(i[b]=y)}let a=A({root:i,now:r,timeZone:o,vars:s}),l=b=>n.has(b),c=new Set;for(let b of[e.entry.title,e.entry.subtitle,e.entry.icon,e.entry.iconUrl])if(b!==void 0)for(let y of Et(b,!1,l))n.has(y)&&c.add(y);let p=Co(ne(e.entry.icon,a)),d=Co(ne(e.entry.iconUrl,a));return A({title:ne(e.entry.title,a),subtitle:Co(ne(e.entry.subtitle,a)),icon:p,imageUrl:p===void 0&&d!==void 0&&Lt(d)?d:void 0,data:c.size===0?void 0:hp([...c].sort(mp),n)})}var la={error:0,loading:1,stale:2,empty:3,live:4,sample:5};function hp(e,t){let n=e.map(s=>t.get(s)),r=n[0];for(let s of n)la[s.state]<la[r.state]&&(r=s);let o=n.flatMap(s=>s.fetchedAt===void 0?[]:[s.fetchedAt]);return A({state:r.state,lastUpdated:o.length?pt(Math.min(...o)):void 0,message:r.state==="error"||r.state==="stale"?r.message:void 0,sources:e})}var mp=(e,t)=>e<t?-1:e>t?1:0,Co=e=>e.trim()===""?void 0:e;function pr(e,t,n,r){return ca(e,t,n,r??{})}var ye,Ce,Ee,He,ie,bn,Pt,ur,dr=class{constructor(t){_(this,Pt);_(this,ye);_(this,Ce);_(this,Ee);_(this,He,1);_(this,ie,!1);_(this,bn,0);v(this,ye,t),v(this,Ce,v(this,Ee,t()))}now(){return f(this,ie)?f(this,Ee):f(this,Ee)+(f(this,ye).call(this)-f(this,Ce))*f(this,He)}get paused(){return f(this,ie)}get speed(){return f(this,He)}get offset(){return this.now()-L(this,Pt,ur).call(this)}get isLive(){return!f(this,ie)&&f(this,He)===1&&Math.abs(this.offset)<1e3}goLive(){v(this,ie,!1),v(this,He,1),v(this,Ce,v(this,Ee,f(this,ye).call(this)))}pause(){f(this,ie)||(v(this,Ee,this.now()),v(this,bn,f(this,ye).call(this)),v(this,ie,!0))}resume(){f(this,ie)&&(v(this,Ce,f(this,ye).call(this)),v(this,ie,!1))}togglePause(){f(this,ie)?this.resume():this.pause()}setOffset(t){let n=Math.max(-315576e7,Math.min(315576e7,Number.isFinite(t)?t:0));v(this,Ee,L(this,Pt,ur).call(this)+n),v(this,Ce,f(this,ye).call(this))}shift(t){this.setOffset(this.offset+t)}setTime(t){this.setOffset(t-L(this,Pt,ur).call(this))}setSpeed(t){if(!Number.isFinite(t)||t<=0)throw new RangeError("The clock speed must be a positive number.");v(this,Ee,this.now()),v(this,Ce,f(this,ye).call(this)),v(this,He,Math.min(t,3600))}};ye=new WeakMap,Ce=new WeakMap,Ee=new WeakMap,He=new WeakMap,ie=new WeakMap,bn=new WeakMap,Pt=new WeakSet,ur=function(){return f(this,ie)?f(this,bn):f(this,ye).call(this)};function gp(e){if(e.startsWith("/"))return e.slice(1).split("/").map(s=>s.replace(/~1/g,"/").replace(/~0/g,"~")).map(s=>/^\d+$/.test(s)?Number(s):s);let t=e.startsWith("$.")?e.slice(2):e,n=[],r=/([^.[\]]+)|\[(\d+)\]/g,o=0;for(let s=r.exec(t);s;s=r.exec(t)){let i=t.slice(o,s.index);if(i!==""&&i!==".")return null;n.push(s[1]!==void 0?s[1]:Number(s[2])),o=r.lastIndex}return o===t.length&&n.length>0?n:null}function pa(e){return e.map((t,n)=>typeof t=="number"?`[${t}]`:n===0?t:`.${t}`).join("")}function q(e){return e!=null&&typeof e=="object"&&!Array.isArray(e)}function ua(e,t){let n=gp(t);if(!n)return;let r=e,o=0;if(t.startsWith("$.")&&q(e)){let[s]=n,i=a=>{for(let l=n.length;l>1;l--){let c=n.slice(1,l).join("."),p=a.find(d=>q(d)&&d.id===c);if(p)return o=l,p}};if(s==="screens")r=i(Array.isArray(e.screens)?e.screens:[]);else if(s==="glances")r=i([e.tile??null,e.complication??null]);else return}for(;o<n.length;o++){let s=n[o];if(r===null||typeof r!="object")return;r=Array.isArray(r)?typeof s=="number"?r[s]:void 0:r[String(s)]}return r}function*Nt(e,t=[]){if(Array.isArray(e))for(let n=0;n<e.length;n++)yield*Nt(e[n],[...t,n]);else if(q(e)){yield[e,t];for(let[n,r]of Object.entries(e))r!==null&&typeof r=="object"&&(yield*Nt(r,[...t,n]))}}var Io=["sample","live","loading","error","empty","stale"];function Jo(e){return"experiences"in e?e:{payloadVersion:1,experiences:[e]}}function bp(e){if(!e)return;let t=Date.parse(e);return Number.isNaN(t)?void 0:t}function da(e,t,n){let r={};if(t==="sample")return r;let o=e.bundle.sources,s=o&&typeof o=="object"&&!Array.isArray(o)?Object.keys(o):[],i=e.bundle.sample;for(let a of s){let l=e.data?.[a],c=i&&typeof i=="object"&&!Array.isArray(i)?i[a]:void 0,p=l?l.data:c??null,d=bp(l?.receivedAt)??n;switch(t){case"live":if(!l)break;r[a]=wp({data:p,state:l.state??"live"},d,l.message);break;case"empty":r[a]={data:p,state:"empty",fetchedAt:d};break;case"stale":r[a]={data:p,state:"stale"};break;default:r[a]={data:null,state:t}}}return r}function wp(e,t,n){return t!==void 0&&e.state!=="loading"&&(e.fetchedAt=t),n!==void 0&&(e.message=n),e}var Ge="overview",yp=2e3,vp=20,xp=100,de=class extends Error{};function hr(e){let t=typeof e.main=="string"?e.main:void 0,r=(Array.isArray(e.screens)?e.screens.filter(q):[]).map(i=>String(i.id)),s=[...r.filter(i=>i===t),...r.filter(i=>i!==t)].map(i=>({kind:"page",label:i,target:i,key:`page:${i}`}));return q(e.tile)&&s.push({kind:"tile",label:"tile",target:String(e.tile.id??"tile"),key:"tile"}),q(e.complication)&&s.push({kind:"complication",label:"complication",target:String(e.complication.id??"complication"),key:"complication"}),s.push({kind:"home",label:"App home",target:"home",key:"home"}),s}function br(e,t){if(e.startsWith("screen:"))return e.slice(7);let n=t.find(r=>r.key===e);return n?.kind==="page"?n.target:null}function kp(e,t){if(!t)return null;let n=ua(e,t),r=t;if(!q(n)){for(let[s,i]of Nt(e))if(s.id===t&&s.type!=="tile"&&s.type!=="complication"&&i[0]!=="experience"){n=s,r=pa(i);break}}if(!q(n))return null;if(n===e.tile||n===e.complication||r==="tile"||r==="complication")return typeof n.opens=="string"?{kind:"open",path:t,node:n,opens:n.opens}:null;let o=typeof n.icon=="string"?n.icon:void 0;return n.type==="toggle"||typeof n.key=="string"&&typeof n.on=="boolean"?{kind:"toggle",path:t,node:n,...o?{icon:o}:{}}:q(n.action)?{kind:"action",path:t,node:n,action:n.action,...o?{icon:o}:{}}:null}var dt,ft,wn,ve,xe,ht,se,We,$t,mt,gr,P,ga,ba,wa,ya,Do,fr,Vo,Bo,Fo,Uo,va,xa,ka,mr=class{constructor(t,n={}){_(this,P);C(this,"clock");_(this,dt);_(this,ft);_(this,wn);_(this,ve,null);_(this,xe,[]);_(this,ht,{});_(this,se,null);_(this,We,null);_(this,$t,0);_(this,mt,[]);_(this,gr,0);C(this,"settings",{theme:"auto",ambient:!1,showCase:!0});C(this,"data","sample");C(this,"mock",{outcome:"succeed",failureRate:.3});C(this,"dataTime");C(this,"version",0);v(this,dt,t),this.clock=new dr(t),this.dataTime=t(),v(this,ft,n.devices??[]),v(this,wn,n.random??Math.random)}get surfaceKey(){return f(this,ve)}get backStack(){return f(this,xe)}get canGoBack(){return f(this,xe).length>0||f(this,se)!==null}get toggles(){return f(this,ht)}get confirm(){return f(this,se)}get log(){return f(this,mt)}get overlay(){return f(this,We)&&f(this,dt).call(this)<f(this,$t)?f(this,We):null}get overlayExpiresAt(){return this.overlay?f(this,$t):null}restart(){v(this,ve,null),v(this,xe,[]),v(this,ht,{}),v(this,se,null),v(this,We,null),this.dataTime=f(this,dt).call(this),this.version++}effectiveSurface(t,n=hr(t)){return f(this,ve)!==null&&ma(f(this,ve),t,n)?f(this,ve):n[0]?.key??Ge}apply(t,n){let r=n?hr(n):[],o;switch(t.type){case"surface":o=L(this,P,ga).call(this,t.surface,n,r);break;case"back":o=L(this,P,ba).call(this);break;case"tap":o=L(this,P,wa).call(this,t.path,n,r);break;case"confirm":o=L(this,P,ya).call(this,n,r);break;case"cancel":o=L(this,P,Do).call(this);break;case"settings":o=L(this,P,va).call(this,t);break;case"clock":o=L(this,P,xa).call(this,t);break;case"data":o=L(this,P,ka).call(this,t.data);break;default:throw new de(`Unknown command type '${String(t.type)}'.`)}return o&&this.version++,o}};dt=new WeakMap,ft=new WeakMap,wn=new WeakMap,ve=new WeakMap,xe=new WeakMap,ht=new WeakMap,se=new WeakMap,We=new WeakMap,$t=new WeakMap,mt=new WeakMap,gr=new WeakMap,P=new WeakSet,ga=function(t,n,r){if(!t||!n||!ma(t,n,r))throw new de(`Unknown surface '${t}'. Use one of: ${[...r.map(s=>s.key),Ge].join(", ")}.`);let o=this.effectiveSurface(n,r);return v(this,se,null),t===o?!1:(v(this,xe,[]),v(this,ve,t),!0)},ba=function(){if(f(this,se))return L(this,P,Do).call(this);let t=f(this,xe).pop();return t===void 0?!1:(v(this,ve,t),!0)},wa=function(t,n,r){let o=n?kp(n,t):null;if(!o||!n)return!1;if(o.kind==="open")return L(this,P,Fo).call(this,o.opens,n,r);if(o.kind==="toggle"){let i=String(o.node.key??o.path),a=o.node.on!==!0;f(this,ht)[i]=a;let l=o.node[a?"onAction":"offAction"];if(q(l)&&l.kind==="openScreen")return L(this,P,fr).call(this,l,o.path,n,r),!0;let c=q(l)?L(this,P,Vo).call(this,l,o.path):!0;return c||(f(this,ht)[i]=!a),L(this,P,Uo).call(this,c,c?void 0:ha(l),!c),!0}let s=o.action;return typeof s.confirm=="string"&&s.confirm.trim()!==""?(v(this,se,{prompt:s.confirm,action:s,path:o.path,...o.icon?{icon:o.icon}:{}}),!0):(L(this,P,fr).call(this,s,o.path,n,r),!0)},ya=function(t,n){let r=f(this,se);return r?(v(this,se,null),L(this,P,fr).call(this,r.action,r.path,t,n),!0):!1},Do=function(){return f(this,se)?(v(this,se,null),!0):!1},fr=function(t,n,r,o){if(t.kind==="openScreen"&&typeof t.screen=="string"){L(this,P,Bo).call(this,t,n,!0,`Navigated to ${t.screen}`),r&&L(this,P,Fo).call(this,t.screen,r,o);return}let s=L(this,P,Vo).call(this,t,n),i=q(t.toast)?t.toast:void 0,a=s?typeof i?.success=="string"?i.success:t.kind==="refreshSource"?"Refreshed":"Sent":ha(t);L(this,P,Uo).call(this,s,a,!0)},Vo=function(t,n){let r=this.mock.outcome==="succeed"?!0:this.mock.outcome==="fail"?!1:f(this,wn).call(this)>=this.mock.failureRate,o=r?t.kind==="refreshSource"?"200 OK (mock) \xB7 source refreshed":'200 OK (mock) \xB7 {"ok":true}':"503 Service Unavailable (mock)";return L(this,P,Bo).call(this,t,n,r,o),r},Bo=function(t,n,r,o){f(this,mt).unshift({id:++is(this,gr)._,at:this.clock.now(),action:String(t.id??"?"),kind:String(t.kind??"?"),path:n,...t.context!==void 0?{context:t.context}:{},status:r?"succeeded":"failed",result:o}),f(this,mt).length>xp&&f(this,mt).pop()},Fo=function(t,n,r){let o=r.find(i=>i.kind==="page"&&i.target===t)?.key??`screen:${t}`,s=this.effectiveSurface(n,r);return o===s?!1:(f(this,xe).push(s),f(this,xe).length>vp&&f(this,xe).shift(),v(this,ve,o),v(this,se,null),!0)},Uo=function(t,n,r){v(this,We,{success:t,toast:r,sequence:(f(this,We)?.sequence??0)+1,...n!==void 0?{message:n}:{}}),v(this,$t,f(this,dt).call(this)+yp)},va=function(t){let n={...this.settings};if(t.device!==void 0){if(f(this,ft).length>0&&!f(this,ft).includes(t.device))throw new de(`Unknown device '${t.device}'. Use one of: ${f(this,ft).join(", ")}.`);n.device=t.device}if(t.theme!==void 0){if(t.theme!=="auto"&&!$e(t.theme))throw new de(`Unknown theme '${t.theme}'. Use auto or one of: ${xt.map(o=>o.id).join(", ")}.`);n.theme=t.theme}t.ambient!==void 0&&(n.ambient=t.ambient),t.case!==void 0&&(n.showCase=t.case);let r=n.device!==this.settings.device||n.theme!==this.settings.theme||n.ambient!==this.settings.ambient||n.showCase!==this.settings.showCase;return this.settings=n,r},xa=function(t){let n=this.clock,r=[n.paused,Math.round(n.offset),n.speed].join();switch(t.clock){case void 0:break;case"live":n.goLive();break;case"frozen":n.pause();break;case"running":n.resume();break;default:throw new de(`Unknown clock mode '${String(t.clock)}'. Use live, frozen or running.`)}let o=s=>{if(!Number.isFinite(s))throw new de("Clock minutes must be a finite number.");return Math.max(-315576e7,Math.min(315576e7,s*6e4))};if(t.offsetMinutes!==void 0&&n.setOffset(o(t.offsetMinutes)),t.shiftMinutes!==void 0&&n.shift(o(t.shiftMinutes)),t.speed!==void 0)try{n.setSpeed(t.speed)}catch(s){throw new de(s.message)}return r!==[n.paused,Math.round(n.offset),n.speed].join()},ka=function(t){if(!Io.includes(t))throw new de(`Unknown data state '${t}'. Use ${Io.join(", ")}.`);return t===this.data?!1:(this.data=t,!0)};function ha(e){let t=q(e)?e.toast:void 0;return q(t)&&typeof t.failure=="string"?t.failure:"Failed"}function ma(e,t,n){if(e===Ge||n.some(o=>o.key===e))return!0;if(!e.startsWith("screen:"))return!1;let r=e.slice(7);return Array.isArray(t.screens)&&t.screens.some(o=>q(o)&&o.id===r)}var Tp=/\$ms\b/,Sp=/\$now|\$ms|\$dataTime|\b(relative|ago|countdown|time|date|since|until)\b/,Ta=new WeakMap;function Ap(e,t){let n=Ta.get(e);if(n)return n;let r=a=>{try{return t(a)}catch{return Sp.test(a)}},o={},s=(a,l)=>{o[a]=Op(l,r)},i=e.pages;if(q(i))for(let[a,l]of Object.entries(i))s(`page:${a}`,l);return s("tile",e.tile),s("complication",e.complication),s("home",e.entry),Ta.set(e,o),o}function Op(e,t){let n={clock:!1,subSecond:!1},r=o=>{if(typeof o=="string"){if(!o.includes("{{"))return;Tp.test(o)?n.clock=n.subSecond=!0:!n.clock&&t(o)&&(n.clock=!0)}else Array.isArray(o)?o.forEach(r):q(o)&&Object.values(o).forEach(r)};return r(e),n}function _p(e,t,n){if(t===Ge)return e;if(t==="tile"||t==="complication")return e[t];if(t==="home")return e.entry;let r=br(t,n);return Array.isArray(e.screens)?e.screens.find(o=>q(o)&&o.id===r):void 0}function Ep(e,t,n){for(let[r]of Nt(_p(e,t,n)))if(r.type==="countdown"&&typeof r.target=="string"||r.state==="stale"&&Array.isArray(r.sources))return!0;return!1}function Sa(e,t,n,r,o){let s=Ap(e,o),i=n===Ge?Object.keys(s):[n.startsWith("screen:")?`page:${n.slice(7)}`:n],a=!1;for(let l of i){let c=s[l];if(c?.subSecond)return"frame";c?.clock&&(a=!0)}return a||Ep(t,n,r)?"second":"none"}var gt,Me,ae,oe,Le,bt,qe,Ze,jt,Re,Xe,yn,zt,wt,re,Ho,Wo,Aa,Oa,wr,yr=class{constructor(t,n,r,o={}){_(this,re);C(this,"session");_(this,gt);_(this,Me);_(this,ae);_(this,oe);_(this,Le);_(this,bt,null);_(this,qe,[]);_(this,Ze,"");_(this,jt,null);_(this,Re,null);_(this,Xe,null);_(this,yn);_(this,zt,!1);_(this,wt,{resolve:0,render:0});C(this,"stats",{frames:0,firstResolveMs:null,lastResolveMs:0,lastRenderMs:0,avgResolveMs:0,maxResolveMs:0,avgRenderMs:0,maxRenderMs:0,cadence:"none",lastDrawAt:0});v(this,gt,n),v(this,Me,r),v(this,ae,o),v(this,oe,Jo(t)),v(this,Le,L(this,re,Ho).call(this,o.experience)),this.session=new mr(()=>r.now(),{...o.devices?{devices:o.devices}:{},...o.random?{random:o.random}:{}});let s=this.session;s.data=o.data??(this.experience?.data&&Object.keys(this.experience.data).length>0?"live":"sample"),s.settings={theme:o.theme??"auto",ambient:o.ambient??!1,showCase:o.showCase??!0,...o.device?{device:o.device}:{}},v(this,yn,r.onVisibility(()=>{r.hidden()?L(this,re,wr).call(this):this.draw()}));try{this.draw(),o.surface&&f(this,bt)&&this.command({type:"surface",surface:o.surface})}catch(i){throw this.destroy(),i}}get payload(){return f(this,oe)}get experiences(){return f(this,oe).experiences}get experienceKey(){return f(this,Le)}get experience(){return f(this,oe).experiences.find(t=>t.key===f(this,Le))}get view(){return f(this,bt)}get surfaces(){return f(this,qe)}get surface(){return f(this,Ze)}get error(){return f(this,jt)}get destroyed(){return f(this,zt)}command(t){let n=this.session.apply(t,f(this,bt));return n&&this.draw(),n}selectExperience(t){if(t===f(this,Le))return!1;if(!f(this,oe).experiences.some(n=>n.key===t))throw new Error(`Unknown Experience '${t}'.`);if(f(this,oe).limits?.experiences&&!f(this,oe).limits.experiences.includes(t))throw new Error(`The Experience '${t}' is not part of this preview.`);return v(this,Le,t),this.session.restart(),this.draw(),!0}setPayload(t){let n=this.experience?.bundleHash;v(this,oe,Jo(t)),f(this,oe).experiences.some(r=>r.key===f(this,Le))?n!==void 0&&n!==this.experience?.bundleHash&&this.session.version++:(v(this,Le,L(this,re,Ho).call(this,void 0)),this.session.restart()),this.draw()}setData(t,n,r=f(this,Me).now()){let o=this.experience;if(!o)return;let s={data:n,state:"live",receivedAt:new Date(r).toISOString()};o.data={...o.data??{},[t]:s},this.draw()}draw(){if(f(this,zt))return;L(this,re,wr).call(this);let t=this.experience;if(!t)return;let n=this.session,r=f(this,Me),o=n.clock.now(),s=da(t,n.data,n.dataTime),i={toggleStates:{...n.toggles},dataTime:n.dataTime,vars:f(this,ae).vars?f(this,ae).vars(o):{ms:o},...f(this,ae).timeZone?{timeZone:f(this,ae).timeZone}:{}},a=r.perf(),l;try{l=f(this,gt).resolve(t.bundle,s,o,i)}catch(O){L(this,re,Wo).call(this,O);return}let c=r.perf();v(this,bt,l),v(this,qe,hr(l)),v(this,Ze,n.effectiveSurface(l,f(this,qe)));let p=br(f(this,Ze),f(this,qe)),d=n.confirm,b=n.overlay,y=n.settings.theme==="auto"?void 0:$e(n.settings.theme),m=y?kt(y):t.theme,T={surface:f(this,Ze),ambient:n.settings.ambient,now:o,frame:n.settings.showCase,...p!==null?{screen:p}:{},...n.settings.device?{device:n.settings.device}:{},...m?{theme:m}:{},...f(this,ae).timeZone?{timeZone:f(this,ae).timeZone}:{},...d?{confirm:{prompt:d.prompt,...d.icon?{icon:d.icon}:{}}}:{},...b?{feedback:b}:{}};try{f(this,gt).render(l,T)}catch(O){L(this,re,Wo).call(this,O);return}let E=r.perf();v(this,jt,null),L(this,re,Aa).call(this,c-a,E-c),this.stats.cadence=n.clock.paused?"none":Sa(t.bundle,l,f(this,Ze),f(this,qe),O=>f(this,gt).readsClock(O)),L(this,re,Oa).call(this),f(this,ae).onUpdate?.(this)}destroy(){v(this,zt,!0),L(this,re,wr).call(this),f(this,yn).call(this)}};gt=new WeakMap,Me=new WeakMap,ae=new WeakMap,oe=new WeakMap,Le=new WeakMap,bt=new WeakMap,qe=new WeakMap,Ze=new WeakMap,jt=new WeakMap,Re=new WeakMap,Xe=new WeakMap,yn=new WeakMap,zt=new WeakMap,wt=new WeakMap,re=new WeakSet,Ho=function(t){let n=f(this,oe).experiences.filter(o=>!f(this,oe).limits?.experiences||f(this,oe).limits.experiences.includes(o.key));if(t!==void 0){if(!n.some(o=>o.key===t))throw new Error(`Unknown Experience '${t}'.`);return t}let r=n[0];if(!r)throw new Error("The payload has no Experience to show.");return r.key},Wo=function(t){v(this,jt,t),this.stats.cadence="none",f(this,ae).onError?.(t),f(this,ae).onUpdate?.(this)},Aa=function(t,n){let r=this.stats;r.frames++,r.firstResolveMs??(r.firstResolveMs=t),r.lastResolveMs=t,r.lastRenderMs=n,f(this,wt).resolve+=t,f(this,wt).render+=n,r.avgResolveMs=f(this,wt).resolve/r.frames,r.avgRenderMs=f(this,wt).render/r.frames,r.maxResolveMs=Math.max(r.maxResolveMs,t),r.maxRenderMs=Math.max(r.maxRenderMs,n),r.lastDrawAt=f(this,Me).now()},Oa=function(){let t=f(this,Me),n=this.session.clock;if(t.hidden())return;let r=1/0;if(this.stats.cadence==="frame")v(this,Re,t.frame(()=>{v(this,Re,null),this.draw()}));else if(this.stats.cadence==="second"){let i=(1e3-(n.now()%1e3+1e3)%1e3)/n.speed;i<16?v(this,Re,t.frame(()=>{v(this,Re,null),this.draw()})):r=Math.ceil(i)+1}let o=this.session.overlayExpiresAt;o!==null&&(r=Math.min(r,Math.max(0,o-t.now()))),r!==1/0&&v(this,Xe,t.timeout(()=>{v(this,Xe,null),this.draw()},r))},wr=function(){f(this,Re)!==null&&f(this,Me).cancelFrame(f(this,Re)),f(this,Xe)!==null&&f(this,Me).cancelTimeout(f(this,Xe)),v(this,Re,v(this,Xe,null))};function _a(){let e=typeof document>"u"?void 0:document,t=typeof performance>"u"?void 0:performance;return{now:()=>t?t.timeOrigin+t.now():Date.now(),perf:()=>t?t.now():Date.now(),frame:n=>typeof requestAnimationFrame=="function"?requestAnimationFrame(()=>n()):setTimeout(n,16),cancelFrame:n=>typeof cancelAnimationFrame=="function"?cancelAnimationFrame(n):clearTimeout(n),timeout:(n,r)=>setTimeout(n,r),cancelTimeout:n=>clearTimeout(n),hidden:()=>e?.visibilityState==="hidden",onVisibility:n=>e?(e.addEventListener("visibilitychange",n),()=>e.removeEventListener("visibilitychange",n)):()=>{}}}function Go(e,t,n){let r={resolve:n.engine.resolve??pr,readsClock:n.engine.readsClock??Gi,render:n.engine.render},o=null,s=a=>{if(!(!o||!(a.target instanceof Element)))try{if(o.surface===Ge){let p=a.target.closest("[data-wb-surface]");p&&e.contains(p)&&(a.preventDefault(),o.command({type:"surface",surface:p.getAttribute("data-wb-surface")??""}));return}let l=a.target.closest("[data-wb-tap]");if(!l||!e.contains(l))return;a.preventDefault();let c=l.getAttribute("data-wb-tap");c==="confirm"||c==="cancel"?o.command({type:c}):o.command({type:"tap",path:l.getAttribute("data-path")??""})}catch(l){if(!(l instanceof de))throw l}};o=new yr(t,r,n.scheduler??_a(),n),e.addEventListener("click",s);let i=o.destroy.bind(o);return o.destroy=()=>{i(),e.removeEventListener("click",s)},o}var qo=`/* The watch renderer's stylesheet (render/). Each component's rules match its scope class (.wb-scope-*, render/scopes.ts
1
+ /* @quickwatch/preview 0.3.0. Roboto Flex: SIL Open Font License, dist/fonts/RobotoFlex-OFL.txt */
2
+ "use strict";var QuickWatch=(()=>{var An=Object.defineProperty;var pl=Object.getOwnPropertyDescriptor;var ul=Object.getOwnPropertyNames;var dl=Object.prototype.hasOwnProperty;var cs=e=>{throw TypeError(e)};var fl=(e,t,n)=>t in e?An(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var hl=(e,t)=>{for(var n in t)An(e,n,{get:t[n],enumerable:!0})},ml=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let o of ul(t))!dl.call(e,o)&&o!==n&&An(e,o,{get:()=>t[o],enumerable:!(r=pl(t,o))||r.enumerable});return e};var gl=e=>ml(An({},"__esModule",{value:!0}),e);var I=(e,t,n)=>fl(e,typeof t!="symbol"?t+"":t,n),Pr=(e,t,n)=>t.has(e)||cs("Cannot "+n);var f=(e,t,n)=>(Pr(e,t,"read from private field"),n?n.call(e):t.get(e)),E=(e,t,n)=>t.has(e)?cs("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),v=(e,t,n,r)=>(Pr(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),M=(e,t,n)=>(Pr(e,t,"access private method"),n);var ps=(e,t,n,r)=>({set _(o){v(e,t,o,n)},get _(){return f(e,t,r)}});var Tu={};hl(Tu,{devices:()=>ll,isolate:()=>Er,link:()=>ts,mountAll:()=>rs,render:()=>ns,themes:()=>vu,version:()=>yu,widget:()=>_r});var bl=/\p{L}/u,wl=/[\p{L}\p{Nd}]/u,ds=/^[\x00-\x7f]*$/;function kt(e){let t=e.charCodeAt(0);return t<128?t>=65&&t<=90||t>=97&&t<=122:bl.test(e)}function fs(e){let t=e.charCodeAt(0);return t<128?t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122:wl.test(e)}function je(e){let t=e.charCodeAt(0);return t>=48&&t<=57}function tt(e){return e===32||e>=9&&e<=13?!0:e<133?!1:e===133||e===160||e===5760||e>=8192&&e<=8202||e===8232||e===8233||e===8239||e===8287||e===12288}function U(e){let t=0,n=e.length;for(;t<n&&tt(e.charCodeAt(t));)t++;for(;n>t&&tt(e.charCodeAt(n-1));)n--;return t===0&&n===e.length?e:e.slice(t,n)}function nt(e){if(!e)return!0;for(let t=0;t<e.length;t++)if(!tt(e.charCodeAt(t)))return!1;return!0}function yl(e){return e===304||e===305?e:e>=8064&&e<=8071||e>=8080&&e<=8087||e>=8096&&e<=8103?e+8:e===8115||e===8131||e===8179?e+9:null}function us(e){return e===411||e===42972||e===612||e===42955||e===7305||e===7306||e>=68944&&e<=68997}function hs(e,t,n){let r="";for(let o of e){let s=o.codePointAt(0),i=n(s);if(i!==null){r+=String.fromCodePoint(i);continue}let a=t(o),l=a.length===o.length||[...a].length===1;r+=l&&!us(s)&&!us(a.codePointAt(0))?a:o}return r}function On(e){return ds.test(e)?e.toUpperCase():hs(e,t=>t.toUpperCase(),yl)}function rt(e){return ds.test(e)?e.toLowerCase():hs(e,t=>t.toLowerCase(),t=>t===304||t===305?t:null)}function Nr(e,t){return e===t||On(e)===On(t)}function ms(e){let t=0;for(let n=0;n<e.length;n++){let r=e.charCodeAt(n);if(r>=55296&&r<=56319&&n+1<e.length){let o=e.charCodeAt(n+1);o>=56320&&o<=57343&&n++}t++}return t}function gs(e,t){let n=0;for(let r=0;r<t&&n<e.length;r++){let o=e.charCodeAt(n);n+=o>=55296&&o<=56319&&n+1<e.length&&(e.charCodeAt(n+1)&64512)===56320?2:1}return n>=e.length?e:e.slice(0,n)}var $r={UTC:"Etc/UTC","GMT Standard Time":"Europe/London","Greenwich Standard Time":"Atlantic/Reykjavik","W. Europe Standard Time":"Europe/Berlin","Central Europe Standard Time":"Europe/Budapest","Romance Standard Time":"Europe/Paris","Central European Standard Time":"Europe/Warsaw","E. Europe Standard Time":"Europe/Chisinau","FLE Standard Time":"Europe/Kiev","GTB Standard Time":"Europe/Bucharest","Russian Standard Time":"Europe/Moscow","Turkey Standard Time":"Europe/Istanbul","Israel Standard Time":"Asia/Jerusalem","Egypt Standard Time":"Africa/Cairo","South Africa Standard Time":"Africa/Johannesburg","W. Central Africa Standard Time":"Africa/Lagos","E. Africa Standard Time":"Africa/Nairobi","Morocco Standard Time":"Africa/Casablanca","Arabian Standard Time":"Asia/Dubai","Arab Standard Time":"Asia/Riyadh","Iran Standard Time":"Asia/Tehran","Pakistan Standard Time":"Asia/Karachi","India Standard Time":"Asia/Calcutta","Nepal Standard Time":"Asia/Katmandu","Bangladesh Standard Time":"Asia/Dhaka","SE Asia Standard Time":"Asia/Bangkok","China Standard Time":"Asia/Shanghai","Singapore Standard Time":"Asia/Singapore","Taipei Standard Time":"Asia/Taipei","Tokyo Standard Time":"Asia/Tokyo","Korea Standard Time":"Asia/Seoul","W. Australia Standard Time":"Australia/Perth","Cen. Australia Standard Time":"Australia/Adelaide","AUS Central Standard Time":"Australia/Darwin","AUS Eastern Standard Time":"Australia/Sydney","E. Australia Standard Time":"Australia/Brisbane","Tasmania Standard Time":"Australia/Hobart","New Zealand Standard Time":"Pacific/Auckland","Hawaiian Standard Time":"Pacific/Honolulu","Alaskan Standard Time":"America/Anchorage","Pacific Standard Time":"America/Los_Angeles","US Mountain Standard Time":"America/Phoenix","Mountain Standard Time":"America/Denver","Central Standard Time":"America/Chicago","Central America Standard Time":"America/Guatemala","Central Standard Time (Mexico)":"America/Mexico_City","Canada Central Standard Time":"America/Regina","Eastern Standard Time":"America/New_York","US Eastern Standard Time":"America/Indianapolis","SA Pacific Standard Time":"America/Bogota","Atlantic Standard Time":"America/Halifax","Newfoundland Standard Time":"America/St_Johns","E. South America Standard Time":"America/Sao_Paulo","Argentina Standard Time":"America/Buenos_Aires","Pacific SA Standard Time":"America/Santiago","SA Western Standard Time":"America/La_Paz","Venezuela Standard Time":"America/Caracas"},_n=new Map;function En(e){if(!e||e.trim()==="")return null;let t=_n.get(e);return t!==void 0||(t=bs(e)?e:Object.hasOwn($r,e)&&bs($r[e])?$r[e]:null,_n.size>256&&_n.clear(),_n.set(e,t)),t}function ot(e){return En(e)??"UTC"}function bs(e){try{return new Intl.DateTimeFormat("en-US",{timeZone:e}),!0}catch{return!1}}var Ht=864e5;function vl(e,t,n){let r=t<=2?e-1:e,o=Math.floor(r/400),s=r-o*400,i=(t+9)%12,a=Math.floor((153*i+2)/5)+n-1,l=s*365+Math.floor(s/4)-Math.floor(s/100)+a;return o*146097+l-719468}function Wt(e,t,n,r=0,o=0,s=0,i=0){return vl(e,t,n)*Ht+r*36e5+o*6e4+s*1e3+i}function jr(e){let t=Math.floor(e/Ht),n=Math.floor(e-t*Ht),r=t+719468,o=Math.floor(r/146097),s=r-o*146097,i=Math.floor((s-Math.floor(s/1460)+Math.floor(s/36524)-Math.floor(s/146096))/365),a=s-(365*i+Math.floor(i/4)-Math.floor(i/100)),l=Math.floor((5*a+2)/153),c=a-Math.floor((153*l+2)/5)+1,p=l<10?l+3:l-9,d=i+o*400+(p<=2?1:0),m=Math.floor(n/36e5);n-=m*36e5;let b=Math.floor(n/6e4);n-=b*6e4;let g=Math.floor(n/1e3);return{year:d,month:p,day:c,hour:m,minute:b,second:g,millisecond:n-g*1e3,dayOfWeek:(t%7+11)%7}}function ws(e,t){return t===2?e%4===0&&e%100!==0||e%400===0?29:28:t===4||t===6||t===9||t===11?30:31}var Gt=-621355968e5,qt=0xe677d21fdbff,Mn=new Map,xl={formatter:null,offsets:new Map};function ys(e){let t=Mn.get(e);if(t)return t;let n=ot(e);return t=n==="UTC"||n==="Etc/UTC"?xl:{formatter:new Intl.DateTimeFormat("en-US",{timeZone:n,hourCycle:"h23",year:"numeric",month:"numeric",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric"}),offsets:new Map},Mn.size>256&&Mn.clear(),Mn.set(e,t),t}function Ut(e,t){let n=ys(e);if(!n.formatter)return 0;let r=Math.floor(t/6e4),o=n.offsets.get(r);if(o!==void 0)return o;let s=1970,i=1,a=1,l=0,c=0,p=0;for(let m of n.formatter.formatToParts(r*6e4))switch(m.type){case"year":s=Number(m.value);break;case"month":i=Number(m.value);break;case"day":a=Number(m.value);break;case"hour":l=Number(m.value)%24;break;case"minute":c=Number(m.value);break;case"second":p=Number(m.value);break}let d=Wt(s,i,a,l,c,p)-r*6e4;return n.offsets.size>4096&&n.offsets.clear(),n.offsets.set(r,d),d}function Ln(e,t){return jr(Math.min(qt,Math.max(Gt,e+Ut(t,e))))}function Rn(e,t){if(!ys(t).formatter)return e;let n=Ut(t,e-Ht/2),r=Ut(t,e+Ht/2);if(n===r)return e-n;let o=Ut(t,e-n)===n,s=Ut(t,e-r)===r;return o!==s?e-(o?n:r):e-Math.min(n,r)}var Pn=String.raw`(?:[Tt ]\s*(\d{1,2}):(\d{2})(?::(\d{2})(?:[.,](\d{1,9}))?)?\s*([AaPp][Mm])?)?`,Nn=String.raw`\s*([Zz]|UTC|GMT|[+-]\d{2}(?::?\d{2})?)?`,kl=new RegExp(String.raw`^(\d{4})[-/](\d{1,2})[-/](\d{1,2})${Pn}${Nn}$`),Tl=new RegExp(String.raw`^(?:[A-Za-z]+,?\s+)?(\d{1,2})[\s-]+([A-Za-z]{3,9})\.?[\s-]+(\d{4})${Pn}${Nn}$`),Sl=new RegExp(String.raw`^(?:[A-Za-z]+,?\s+)?([A-Za-z]{3,9})\.?\s+(\d{1,2}),?\s+(\d{4})${Pn}${Nn}$`),Al=new RegExp(String.raw`^(\d{1,2})/(\d{1,2})/(\d{4})${Pn}${Nn}$`),Ol=/^([A-Za-z]{3,9})\.?,?\s+(\d{4})$/,_l=/^(\d{4})\s+([A-Za-z]{3,9})\.?$/,El=/(^|\s)(\d{1,2})\s*([AaPp][Mm])(?=\s|$)/,Ml=/^(\d{1,2}:\d{2}(?::\d{2})?(?:\s*[AaPp][Mm])?)\s+(\d{4}-\d{1,2}-\d{1,2})$/,Ll=["january","february","march","april","may","june","july","august","september","october","november","december"],vs=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"];function Cr(e){let t=e.toLowerCase(),n=Ll.findIndex(r=>r===t||t.length===3&&r.startsWith(t));return n<0?null:n+1}function ks(e,t){let n=Rl(e.replace(El,"$1$2:00 $3").replace(Ml,"$2 $1"),t);return n===null||n<Gt||n>qt?null:n}function Rl(e,t){let n=kl.exec(e);if(n)return Zt(n[1],n[2],n[3],n,4,t);if(n=Tl.exec(e),n){let o=Cr(n[2]);return o===null?null:Zt(n[3],String(o),n[1],n,4,t)}if(n=Sl.exec(e),n){let o=Cr(n[1]);return o===null?null:Zt(n[3],String(o),n[2],n,4,t)}if(n=Al.exec(e),n)return Zt(n[3],n[1],n[2],n,4,t);n=Ol.exec(e);let r=n?[n[1],n[2]]:(n=_l.exec(e))?[n[2],n[1]]:null;if(r){let o=Cr(r[0]);return o===null?null:Zt(r[1],String(o),"1",[],0,t)}return null}function Zt(e,t,n,r,o,s){let i=Number(e),a=Number(t),l=Number(n);if(i<1||a<1||a>12||l<1||l>ws(i,a))return null;let c=Number(r[o]??0),p=Number(r[o+1]??0),d=Number(r[o+2]??0),m=Number((r[o+3]??"").padEnd(3,"0").slice(0,3)),b=(r[o+4]??"").toLowerCase();if(b==="am"){if(c===12)c=0;else if(c>12)return null}if(b==="pm"){if(c<12)c+=12;else if(c>12)return null}if(c>23||p>59||d>59)return null;let g=Wt(i,a,l,c,p,d,m),S=r[o+5];if(S===void 0)return Rn(g,s);if(S==="Z"||S==="z"||S==="UTC"||S==="GMT")return g;let _=S.slice(1).replace(":",""),A=Number(_.slice(0,2)),J=_.length>2?Number(_.slice(2)):0;if(A>14||J>59)return null;let w=(A*60+J)*6e4;return S[0]==="-"?g+w:g-w}var Pl=new Set(["yyyy","yy","MMMM","MMM","MM","M","dddd","ddd","dd","d","HH","H","hh","h","mm","m","ss","s","tt"]);function zr(e){if(e.length===0||e.length===1&&kt(e))return!1;let t=0;for(;t<e.length;){let n=e[t];if(n==="'"||n==='"'){let o=e.indexOf(n,t+1);if(o<0)return!1;t=o+1;continue}if(n==="\\"){if(t+1>=e.length)return!1;t+=2;continue}if(n==="%")return!1;if(!kt(n)){t++;continue}let r=1;for(;t+r<e.length&&e[t+r]===n;)r++;if(!Pl.has(e.slice(t,t+r)))return!1;t+=r}return!0}var st=e=>e<10?"0"+e:String(e);function Ts(e,t,n){let r=Ln(e,t),o="",s=0;for(;s<n.length;){let i=n[s];if(i==="'"||i==='"'){let c=n.indexOf(i,s+1);o+=n.slice(s+1,c),s=c+1;continue}if(i==="\\"){o+=n[s+1]??"",s+=2;continue}if(!kt(i)){o+=i,s++;continue}let a=1;for(;s+a<n.length&&n[s+a]===i;)a++;let l=r.hour%12===0?12:r.hour%12;switch(n.slice(s,s+a)){case"yyyy":o+=String(r.year).padStart(4,"0");break;case"yy":o+=st(r.year%100);break;case"MMMM":o+=xs[r.month-1];break;case"MMM":o+=xs[r.month-1].slice(0,3);break;case"MM":o+=st(r.month);break;case"M":o+=r.month;break;case"dddd":o+=vs[r.dayOfWeek];break;case"ddd":o+=vs[r.dayOfWeek].slice(0,3);break;case"dd":o+=st(r.day);break;case"d":o+=r.day;break;case"HH":o+=st(r.hour);break;case"H":o+=r.hour;break;case"hh":o+=st(l);break;case"h":o+=l;break;case"mm":o+=st(r.minute);break;case"m":o+=r.minute;break;case"ss":o+=st(r.second);break;case"s":o+=r.second;break;case"tt":o+=r.hour<12?"AM":"PM";break}s+=a}return o}var xs=["January","February","March","April","May","June","July","August","September","October","November","December"];var Ve=6e4,Ss=36e5,Ir=864e5,As=365e4*Ir,Nl=/^(?:now\s*)?([+-])\s*((?:\d+(?:\.\d+)?(?:ms|s|m|h|d)\s*)+)$/i,$l=/\d+(?:\.\d+)?(?:ms|s|m|h|d)/gi,jl=/^(\d{1,2}):(\d{2})(?::(\d{2}))?$/,Cl=/^\d{4}[-/]\d{1,2}[-/]\d{1,2}|\p{L}.*\d|\d.*\p{L}/u,zl=/^(\d+(?:\.\d+)?)\s*(ms|s|m|h|d)?$/i;function Os(e,t,n){if(nt(e))return null;let r=U(e);if(r.length===3&&r.toLowerCase()==="now")return t;let o=Nl.exec(r);if(o){let i=0;for(let l of o[2].matchAll($l)){let c=Il(l[0]);if(c===null||c>As-i)return null;i+=c}let a=o[1]==="-"?t-i:t+i;return a<Gt||a>qt?null:a}let s=jl.exec(r);if(s){let i=Number(s[1]),a=Number(s[2]),l=Number(s[3]??0);if(i>23||a>59||l>59)return null;let c=Ln(t,n);return Rn(Wt(c.year,c.month,c.day,i,a,l),n)}return Cl.test(r)?ks(r,n):null}function Il(e){if(nt(e))return null;let t=zl.exec(U(e));if(!t)return null;let n=Number(t[1]),r=(t[2]??"").toLowerCase(),o=n*(r==="ms"?.001:r==="m"?60:r==="h"?3600:r==="d"?86400:1);return Number.isFinite(o)&&o<=As/1e3?o*1e3:null}var ge=(e,t)=>String(e).padStart(t,"0");function Yt(e){let t=jr(Math.floor(e)),n=`${ge(t.year,4)}-${ge(t.month,2)}-${ge(t.day,2)}T${ge(t.hour,2)}:${ge(t.minute,2)}:${ge(t.second,2)}`;return t.millisecond!==0?`${n}.${ge(t.millisecond,3)}Z`:n+"Z"}function _s(e,t,n,r=!1){let o=e-t;if(r){let i=Math.ceil(o/Ve);if(i>0)return Xt(i*Ve);if(n)return"0:00";let a=-i*Ve;return a<Ve?"Now":`${Xt(a)} ago`}if(n){let i=Math.max(0,Math.ceil(o/1e3)),a=Math.floor(i/3600),l=Math.floor(i%3600/60),c=i%60;return a>0?`${a}:${ge(l,2)}:${ge(c,2)}`:`${l}:${ge(c,2)}`}let s=Math.floor(o/1e3);if(s<=0){let i=-s*1e3;return i<Ve?"Now":`${Xt(i)} ago`}return s<180?`${Math.floor(s/60)}:${ge(s%60,2)}`:Xt(s*1e3)}function Es(e,t,n=!1){let r=e-t,o=r<0,s=o?-r:r;if(s<Ve)return"now";let i=Xt(s);return n?o?"-"+i:i:o?`${i} ago`:`in ${i}`}function Xt(e){if(e<Ss)return`${Math.floor(e/Ve)} min`;if(e<Ir){let t=Math.floor(e/Ve)%60,n=Math.floor(e/Ss);return t===0?`${n} h`:`${n} h ${t} min`}return`${Math.floor(e/Ir)} d`}var Be="--";function $n(e,t){if(!Number.isFinite(e)||Math.abs(e)>=1e16)return e;let n=10**t,r=e*n,o=Math.floor(r),s=r-o;return(s>.5||s===.5&&o%2!==0)&&(o+=1),o===0?r<0||Object.is(r,-0)?-0:0:o/n}function Jr(e){return Object.is(e,-0)?"-0":String(e)}function G(e){return Jr($n(e,2))}function Ce(e){if(Number.isNaN(e))return"NaN";if(!Number.isFinite(e))return e>0?"\u221E":"-\u221E";let t=e<0||Object.is(e,-0),[n,r]=Math.abs(e).toExponential(14).split("e"),o=n.replace(".",""),s=Number(r)+1,i=s>0?o.padEnd(s+2,"0"):"0".repeat(1-s)+o,a=s>0?s:1,l=BigInt(i.slice(0,a+1)||"0");(i[a+1]??"0")>="5"&&(l+=1n);let c=l/10n,p=l%10n,d=p===0n?`${c}`:`${c}.${p}`;return t?"-"+d:d}function Dr(e,t){return e==null?"":t!=null&&e.length>t?e.slice(0,Math.max(0,t-1))+"\u2026":e}function Ls(e,t,n,r){return e==null?Be:_s(e,t,n,r)}function jn(e,t){let n=Math.floor((t-e)/6e4);return n<1?"Updated just now":`Updated ${Jl(n)} ago`}function Jl(e){return e<60?`${e} min`:e<1440?e%60===0?`${Math.trunc(e/60)} h`:`${Math.trunc(e/60)} h ${e%60} min`:`${Math.trunc(e/1440)} d`}function Cn(e,t,n){return t===0&&n===100?`${Ce(e)}%`:`${Ce(e)}/${Ce(n)}`}function zn(e){let t=new Date(e),n=(r,o=2)=>String(r).padStart(o,"0");return`${n(t.getUTCFullYear(),4)}-${n(t.getUTCMonth()+1)}-${n(t.getUTCDate())}T${n(t.getUTCHours())}:${n(t.getUTCMinutes())}:${n(t.getUTCSeconds())}.${n(t.getUTCMilliseconds(),3)}0000+00:00`}var Ms=new Map;function Rs(e,t){let n=Ms.get(t);n||(n=new Intl.DateTimeFormat("en-US",{timeZone:ot(t),hourCycle:"h23",hour:"numeric",minute:"2-digit",weekday:"short",day:"numeric"}),Ms.set(t,n));let r={};for(let o of n.formatToParts(e))r[o.type]=o.value;return{hour:Number(r.hour)%24,minute:Number(r.minute),weekday:r.weekday??"",day:Number(r.day)}}function In(e,t){let{hour:n,minute:r}=Rs(e,t);return`${n}:${String(r).padStart(2,"0")}`}function Ps(e,t){let{weekday:n,day:r}=Rs(e,t);return`${n} ${r}`.toUpperCase()}var ue={version:1,insets:{safePercent:14.64,tileHorizontalPercent:7.1,screenHorizontalPercent:5.2,screenTopPercent:13,screenBottomPercent:23},spacing:{xxs:2,xs:4,s:6,m:8,l:12,xl:16},radius:{rounded:{extraSmall:4,small:8,medium:18,large:26,extraLarge:36,full:999},sharp:{extraSmall:0,small:2,medium:3,large:4,extraLarge:6,full:8},pill:{extraSmall:8,small:12,medium:999,large:999,extraLarge:999,full:999}},sizes:{chipHeight:52,compactChipHeight:32,listRowMinHeight:52,iconSmall:18,iconMedium:24,iconLarge:32,progressRingStroke:8,progressBarHeight:8,toggleWidth:32,toggleHeight:22,frameBezelPercent:7,edgeButtonHeight:46,edgeButtonWidthPercent:48,tileButtonSize:65,curvedTextInset:16,confirmButtonSize:60,progressRingSize:84,tileRingStroke:8,toggleThumb:18,statusDot:10,statusIcon:28,badgeHeight:18,toastHeight:32,skeletonLine:12,scrollIndicatorWidth:6,scrollIndicatorLength:50,scrollIndicatorGap:3,scrollIndicatorEdgePadding:2,rangedStroke:3,complicationPercent:25,longComplicationWidthPercent:64,largeScreenMinWidth:225,buttonPaddingX:14,buttonPaddingY:6,buttonIconSpacing:6,buttonIcon:26,switchPaddingY:8,toggleThumbOff:12,toggleTrackBorder:2,toggleSpacing:6,listHeaderMinHeight:48,listHeaderPaddingX:14,listHeaderPaddingTop:16,listHeaderPaddingBottom:12,progressRingStrokeSmallScreen:5,scrollIndicatorWidthSmallScreen:5,edgeButtonWidthPercentSmallScreen:52,edgeButtonBottom:3,edgeButtonTopMargin:4,edgeButtonTopRadius:17,confirmButtonWidth:63,confirmButtonHeight:54,tileHeaderIcon:24,tileTitleTop:3,tileTitleBottom:6,tileTitleBottomSmallScreen:4,tileIconTitleSpacing:4,tileIconTitleSpacingSmallScreen:2,tileTitleSidePercent:14.5,tileMarginNoEdgePercent:10,tileBottomNoEdgePercent:16.64},effects:{edgeScaleSmall:.7,edgeScaleLarge:.6,edgeAlpha:.5,edgeMinElementHeightSmall:.2,edgeMinElementHeightLarge:.15,edgeMaxElementHeightSmall:.6,edgeMaxElementHeightLarge:.45,edgeMinTransitionAreaSmall:.35,edgeMinTransitionAreaLarge:.4,edgeMaxTransitionAreaSmall:.55,edgeMaxTransitionAreaLarge:.6,edgeSpecSmallScreenWidth:192,edgeSpecLargeScreenWidth:240},font:{family:"'Roboto Flex', Roboto, 'Google Sans', 'Segoe UI', system-ui, sans-serif",numeralFamily:"'Roboto Flex', Roboto, 'Google Sans', 'Segoe UI', system-ui, sans-serif"},typeScale:{display:{size:30,lineHeight:34,weight:520,letterSpacing:.2,width:110},numeral:{size:40,lineHeight:40,weight:580,letterSpacing:0,width:100},title:{size:16,lineHeight:18,weight:550,letterSpacing:.4,width:110},label:{size:15,lineHeight:18,weight:500,letterSpacing:.4,width:110},body:{size:14,lineHeight:16,weight:450,letterSpacing:.4,width:110},labelSmall:{size:13,lineHeight:16,weight:500,letterSpacing:.4,width:110},caption:{size:12,lineHeight:14,weight:500,letterSpacing:.4,width:110},timeText:{size:15,lineHeight:18,weight:599,letterSpacing:.6,width:100},tileTitle:{size:14,lineHeight:16,weight:500,letterSpacing:.4,width:110},faceTime:{size:44,lineHeight:48,weight:400,letterSpacing:0,width:100}},colors:{ambient:{background:"#000000",surface:"#000000",onSurface:"#B0B0B0",onSurfaceVariant:"#8A8A8A",outline:"#6A6A6A",onAccent:"#B0B0B0",timeText:"#B0B0B0",scrollThumb:"#8A8A8A",scrollTrack:"#303030",warningText:"#8A8A8A"}},limits:{textMaxLines:3,screenListMaxRows:10,tileListMaxRows:3,tileCompactListMaxRows:8,tileCompactListMaxRowsSmallScreen:6,tileMaxButtons:2,tileMaxToggles:1,minPollSeconds:60,tileMinRefreshSeconds:60}};function Jn(e){return{...e,widthDp:e.widthPx/e.density,heightDp:e.heightPx/e.density,isRound:e.shape==="round"}}function zs(e,t){let n=t.tileTheme;return n?{...e,shape:n.corners?e.shape:{corners:"rounded"},type:{weight:n.typeWeight?e.type.weight:0,width:n.typeWidth?e.type.width:0}}:e}var Ns=(e,t,n)=>Math.min(Math.max(e,t),n),$s="SmallScreen",js="Percent";function Br(e,t=ue){return e.widthDp<(t.sizes.largeScreenMinWidth??225)}function Dn(e,t=ue){let n=Br(e,t),r={};for(let[o,s]of Object.entries(t.sizes)){if(o.endsWith($s))continue;let i=t.sizes[o+$s];r[o]=n&&i!==void 0?i:s}return r}function Tt(e,t){return Math.ceil($n(e.widthDp*t/100,4))}var Dl=(e,t)=>(Math.ceil(e*t*1900/2048)+Math.ceil(e*t*500/2048))/t,Qt=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();function Is(e,t,n,r=ue){let o="",s=(b,g)=>{o+=`--wb-${b}:${G(g)}px;`},i=(b,g)=>{o+=`--wb-${b}:${g};`},a=Dn(e,r);s("width",e.widthDp),s("height",e.heightDp),i("radius-screen",e.isRound?"50%":"0px"),s("inset-safe",e.isRound?Tt(e,r.insets.safePercent):0),s("pad-x",Tt(e,r.insets.screenHorizontalPercent)),s("tile-pad-x",Tt(e,r.insets.tileHorizontalPercent)),s("pad-top",Tt(e,r.insets.screenTopPercent)),s("pad-bottom",Tt(e,r.insets.screenBottomPercent)),s("bezel",e.widthDp*(a.frameBezelPercent??7)/100);for(let[b,g]of Object.entries(r.spacing))s(`space-${Qt(b)}`,g);let l=r.radius[t.shape.corners]??r.radius.rounded??{};for(let[b,g]of Object.entries(l))s(`radius-${Qt(b)}`,g);for(let[b,g]of Object.entries(a))b.endsWith(js)?b!=="frameBezelPercent"&&s(Qt(b.slice(0,-js.length)),Tt(e,g)):s(Qt(b),g);let c=Fr(e,a.listRowMinHeight??52,r);i("edge-scale",G(c.scale)),i("edge-opacity",G(c.alpha)),s("edge-zone",c.zoneDp);for(let[b,g]of Object.entries(r.typeScale)){let S=Qt(b);s(`type-${S}-size`,g.size);let _=Math.max(g.lineHeight,Dl(g.size,e.density));s(`type-${S}-line`,_),s(`type-${S}-pitch`,g.lineHeight),s(`type-${S}-lead`,(_-g.lineHeight)/2),i(`type-${S}-weight`,String(Ns(g.weight+t.type.weight,100,1e3))),s(`type-${S}-tracking`,g.letterSpacing),i(`type-${S}-width`,`${G(Ns(g.width+t.type.width,25,151))}%`)}i("font",r.font.family),i("font-numeral",r.font.numeralFamily);let p=t.colors,d=n?{...r.colors.ambient,accent:r.colors.ambient.onSurface}:p;i("bg",d.background),i("surface",d.surface),i("on-surface",d.onSurface),i("on-surface-variant",d.onSurfaceVariant),i("outline",d.outline),i("time-text",d.timeText),i("scroll-thumb",d.scrollThumb),i("scroll-track",d.scrollTrack),i("accent",n?d.onSurface:p.accent),i("accent-fill",n?"transparent":p.accent),i("on-accent",n?d.onSurface:p.onAccent),i("accent-container",n?"transparent":`color-mix(in srgb, ${p.accent} 22%, ${p.surface})`),i("on-accent-container",n?d.onSurface:`color-mix(in srgb, ${p.accent} 35%, ${p.onSurface})`),i("track",n?d.outline:`color-mix(in srgb, ${p.accent} 22%, ${p.background})`),i("skeleton",n?d.outline:`color-mix(in srgb, ${p.onSurface} 14%, ${p.background})`);let m={ok:p.statusOk,warn:p.statusWarn,error:p.statusError,unknown:p.statusUnknown};for(let[b,g]of Object.entries(m))i(`status-${b}`,n?d.onSurfaceVariant:g);return i("warning-text",d.warningText),o}var Vr=(e,t,n)=>Math.min(Math.max(e,t),n);function Fr(e,t,n=ue){let r=(A,J)=>n.effects[A]??J,o=r("edgeSpecSmallScreenWidth",192),s=r("edgeSpecLargeScreenWidth",240),i=s>o?Vr((e.heightDp-o)/(s-o),0,1):1,a=(A,J,w)=>r(A+"Small",J)+(r(A+"Large",w)-r(A+"Small",J))*i,l=a("edgeScale",.7,.6),c=a("edgeMinElementHeight",.2,.15),p=a("edgeMaxElementHeight",.6,.45),d=a("edgeMinTransitionArea",.35,.4),m=a("edgeMaxTransitionArea",.55,.6),b=e.heightDp,g=b>0?t/b:0,S=p>c?Vr((g-c)/(p-c),0,1):0,_=Math.min(d+(m-d)*S,(1+g)/2);return{scale:l,alpha:r("edgeAlpha",.5),zoneDp:_*b}}var Fe=e=>Jr($n(e,3));function Kt(e,t,n,r){let o=r*Math.PI/180;return`${Fe(e+n*Math.cos(o))} ${Fe(t+n*Math.sin(o))}`}function Vn(e,t,n,r,o){if(o<=0||n<=0)return"";if(o>=359.99)return`M${Kt(e,t,n,r)} A${Fe(n)} ${Fe(n)} 0 0 1 ${Kt(e,t,n,r+180)} A${Fe(n)} ${Fe(n)} 0 0 1 ${Kt(e,t,n,r+360)}`;let s=o>180?1:0;return`M${Kt(e,t,n,r)} A${Fe(n)} ${Fe(n)} 0 ${s} 1 ${Kt(e,t,n,r+o)}`}function Cs(e,t){return t<=0?0:2*Math.asin(Vr(e/2/t,-1,1))*180/Math.PI}function Bn(e,t,n,r=ue){let o=Dn(e,r),s=o.scrollIndicatorWidth??6,i=e.widthDp/2,a=i-(o.scrollIndicatorEdgePadding??2),l=a-s/2,c=Cs(s+(o.scrollIndicatorGap??3),a),p=Cs(o.scrollIndicatorLength??50,a)+c,d=(b,g)=>g*p>c?Vn(i,i,l,-p/2+b*p+c/2,g*p-c):"";return{track:[d(0,t),d(t+n,1-t-n)].filter(Boolean).join(" "),thumb:d(t,n),width:s}}var St=[{id:"dark",name:"Dark",description:"The Wear OS Material 3 dark palette on black: the default.",tone:"dark",colors:{background:"#000000",surface:"#252626",onSurface:"#E3E3E3",onSurfaceVariant:"#C4C7C5",outline:"#8E918F",accent:"#A8C7FA",onAccent:"#062E6F",timeText:"#C6C6C6",scrollThumb:"#C6C6C6",scrollTrack:"#303030",warningText:"#FDD663",statusOk:"#6DD58C",statusWarn:"#FDD663",statusError:"#F28B82",statusUnknown:"#9AA0A6"},shape:{corners:"rounded"},type:{weight:0,width:0}},{id:"light",name:"Light",description:"The Material 3 light palette: dark text on a near-white background with a deep blue accent.",tone:"light",colors:{background:"#F8FAFD",surface:"#E1E3E1",onSurface:"#1F1F1F",onSurfaceVariant:"#444746",outline:"#747775",accent:"#0B57D0",onAccent:"#FFFFFF",timeText:"#444746",scrollThumb:"#444746",scrollTrack:"#C4C7C5",warningText:"#7C5800",statusOk:"#6DD58C",statusWarn:"#FDD663",statusError:"#F28B82",statusUnknown:"#9AA0A6"},shape:{corners:"rounded"},type:{weight:0,width:0}},{id:"high-contrast",name:"High contrast",description:"White on black with a yellow accent and heavier type, for reading at a glance in any light.",tone:"dark",colors:{background:"#000000",surface:"#1F1F1F",onSurface:"#FFFFFF",onSurfaceVariant:"#E6E6E6",outline:"#BFBFBF",accent:"#FFE14D",onAccent:"#000000",timeText:"#FFFFFF",scrollThumb:"#FFFFFF",scrollTrack:"#4D4D4D",warningText:"#FFE14D",statusOk:"#00E676",statusWarn:"#FFE14D",statusError:"#FF6E6E",statusUnknown:"#CCCCCC"},shape:{corners:"rounded"},type:{weight:100,width:0}},{id:"ember",name:"Ember",description:"Warm browns with an amber accent and pill-shaped chips.",tone:"dark",colors:{background:"#140D08",surface:"#2D2017",onSurface:"#F6E7D9",onSurfaceVariant:"#D9C3AF",outline:"#A68B75",accent:"#FFB37A",onAccent:"#4A2300",timeText:"#E5CDB8",scrollThumb:"#E5CDB8",scrollTrack:"#3B2B20",warningText:"#FFD27A",statusOk:"#A8D67A",statusWarn:"#FFC85C",statusError:"#FF8F7A",statusUnknown:"#B3A08F"},shape:{corners:"pill"},type:{weight:0,width:0}},{id:"mono",name:"Monochrome",description:"Greys only, white for emphasis and a lighter weight: quiet and neutral.",tone:"dark",colors:{background:"#000000",surface:"#262626",onSurface:"#F2F2F2",onSurfaceVariant:"#BDBDBD",outline:"#8C8C8C",accent:"#FFFFFF",onAccent:"#000000",timeText:"#BDBDBD",scrollThumb:"#BDBDBD",scrollTrack:"#333333",warningText:"#E0E0E0",statusOk:"#E0E0E0",statusWarn:"#A6A6A6",statusError:"#FFFFFF",statusUnknown:"#6E6E6E"},shape:{corners:"rounded"},type:{weight:-50,width:0}},{id:"slate",name:"Slate",description:"Blue-grey with a teal accent, sharp corners and condensed, slightly heavier type: a technical look.",tone:"dark",colors:{background:"#0B1015",surface:"#1C252E",onSurface:"#E6EDF3",onSurfaceVariant:"#A9B6C3",outline:"#6B7A89",accent:"#5CD6CB",onAccent:"#00312D",timeText:"#A9B6C3",scrollThumb:"#A9B6C3",scrollTrack:"#2A3540",warningText:"#F2C14E",statusOk:"#5FD38D",statusWarn:"#F2C14E",statusError:"#FF7B72",statusUnknown:"#8B98A5"},shape:{corners:"sharp"},type:{weight:50,width:-10}}],Ur="dark";function ze(e){return St.find(t=>t.id===e)}var Hr=["background","surface","onSurface","onSurfaceVariant","outline","accent","onAccent","timeText","scrollThumb","scrollTrack","warningText","statusOk","statusWarn","statusError","statusUnknown"],Wr=["sharp","rounded","pill"],Js={min:-200,max:200},Ds={min:-30,max:30};var Vl=/^#[0-9A-Fa-f]{6}$/,en=e=>e!==null&&typeof e=="object"&&!Array.isArray(e),Bl=new Set(Hr);function At(e){return{id:e.id,name:e.name,tone:e.tone,colors:{...e.colors},shape:{...e.shape},type:{...e.type}}}function Ot(){return At(ze(Ur))}function Vs(e){let t=ze(e.base);return{...qr(t?At(t):Ot(),e.overrides,"overrides",[]),id:`saved:${e.id}`,name:e.name}}function Gr(e,t={}){let n=[],r=t.inherit!==void 0?Bs(t.inherit):Ot(),o=t.inheritLabel??(t.inherit!==void 0?"the App theme":"the default theme");if(e==null)return{theme:r,problems:n};if(!en(e))return n.push({path:"",rule:"theme-invalid",severity:"error",message:'A theme is an object: { "base": "<theme id>", "overrides": { \u2026 } }.'}),{theme:r,problems:n};for(let l of Object.keys(e))l!=="base"&&l!=="overrides"&&n.push({path:l,rule:"theme-invalid",severity:"error",message:`Unknown theme property '${l}': use base and overrides.`});let s=r,i=e.base;if(i!==void 0)if(typeof i!="string")n.push({path:"base",rule:"theme-invalid",severity:"error",message:'base is a theme id such as "dark" or "saved:thm_\u2026".'});else if(i.startsWith("saved:")){let l=i.slice(6),c=t.saved?.find(p=>p.id===l);c?s=Vs(c):n.push({path:"base",rule:"theme-saved-unknown",severity:"warning",message:`This account has no saved theme '${l}' (it may belong to another account): ${o} is used instead.`})}else{let l=ze(i);l?s=At(l):n.push({path:"base",rule:"theme-unknown",severity:"error",message:`Unknown theme '${i}': ${o} is used instead.`})}let a=e.overrides;return a!==void 0&&(s=qr(s,a,"overrides",n)),{theme:s,problems:n}}function qr(e,t,n,r){let o=Bs(e),s=(i,a)=>r.push({path:i,rule:"theme-invalid",severity:"error",message:a});if(t==null)return o;if(!en(t))return s(n,"overrides is an object: { tone, colors, shape, type }."),o;for(let[i,a]of Object.entries(t)){let l=`${n}.${i}`;if(i==="tone")a==="dark"||a==="light"?o.tone=a:s(l,"tone is dark or light.");else if(i==="colors"){if(!en(a)){s(l,"colors maps colour roles to #RRGGBB.");continue}for(let[c,p]of Object.entries(a))Bl.has(c)?typeof p!="string"||!Vl.test(p)?s(`${l}.${c}`,`${c} must be a colour as #RRGGBB.`):o.colors[c]=p.toUpperCase():s(`${l}.${c}`,`Unknown colour role '${c}'. Roles: ${Hr.join(", ")}.`)}else if(i==="shape"){if(!en(a)){s(l,"shape is { corners }.");continue}for(let[c,p]of Object.entries(a))c!=="corners"?s(`${l}.${c}`,`Unknown shape property '${c}': use corners.`):typeof p=="string"&&Wr.includes(p)?o.shape.corners=p:s(`${l}.corners`,`corners is ${Wr.join(", ")}.`)}else if(i==="type"){if(!en(a)){s(l,"type is { weight, width }.");continue}for(let[c,p]of Object.entries(a)){let d=c==="weight"?Js:c==="width"?Ds:null;d===null?s(`${l}.${c}`,`Unknown type property '${c}': use weight and width.`):typeof p!="number"||!Number.isInteger(p)||p<d.min||p>d.max?s(`${l}.${c}`,`${c} is a whole number from ${d.min} to ${d.max}.`):o.type[c]=p}}else s(l,`Unknown override '${i}': use tone, colors, shape and type.`)}return o}function Bs(e){return{id:e.id,name:e.name,tone:e.tone,colors:{...e.colors},shape:{...e.shape},type:{...e.type}}}var h=(e,t)=>{let n=e?.[t];return typeof n=="string"?n:void 0},Q=(e,t)=>{let n=e?.[t];return typeof n=="number"?n:void 0},D=(e,t)=>{let n=e?.[t];return n!==null&&typeof n=="object"&&!Array.isArray(n)?n:void 0},Oe=(e,t)=>{let n=e?.[t];return Array.isArray(n)?n.filter(r=>r!==null&&typeof r=="object"&&!Array.isArray(r)):[]},j=e=>e==null||e==="";function _t(e){if(e===void 0)return null;let t=Date.parse(e);return Number.isNaN(t)?null:t}var tn={phase:"ready",updatedAt:null,staleAfter:10*6e4};function Fn(e,t){return e.updatedAt!==null&&t-e.updatedAt>=e.staleAfter}function Zr(e,t){let n=h(e,"state"),r=_t(h(e,"lastUpdated"));if(n==="loading"&&t)return{...tn,phase:"loading",updatedAt:r};if(n==="error"&&t){let o=h(e,"message");return o===void 0?{...tn,phase:"error",updatedAt:r}:{...tn,phase:"error",updatedAt:r,errorMessage:o}}return n==="empty"?{...tn,phase:"empty"}:n==="stale"?{phase:"ready",updatedAt:r,staleAfter:0}:tn}function de(e,t){return e===void 0&&t===void 0?null:{name:e,url:t}}function Fs(e){let t=0;return n=>`${e}-${n}-${++t}`}var ne=e=>e.data.phase==="loading",re=e=>e.data.phase==="empty";var Xr="0 0 24 24",Us={add:"M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z",alarm:"M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39 6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12.5 8H11v6l4.75 2.85.75-1.23-4-2.37V8zM12 4a9 9 0 1 0 0 18 9 9 0 0 0 0-18zm0 16a7 7 0 1 1 0-14 7 7 0 0 1 0 14z","arrow-down":"M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z","arrow-up":"M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z",battery:"M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z",bell:"M12 22c1.1 0 2-.9 2-2h-4c0 1.1.89 2 2 2zm6-6v-5c0-3.07-1.64-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.63 5.36 6 7.92 6 11v5l-2 2v1h16v-1l-2-2z",bike:"M5 20.5a3.5 3.5 0 1 1 0-7 3.5 3.5 0 0 1 0 7zm0-5.5a2 2 0 1 0 0 4 2 2 0 0 0 0-4zm14 5.5a3.5 3.5 0 1 1 0-7 3.5 3.5 0 0 1 0 7zm0-5.5a2 2 0 1 0 0 4 2 2 0 0 0 0-4zM15.5 5.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4zM12.6 8.8 15 11h3V9h-2.2l-2.6-2.6c-.4-.4-.9-.6-1.4-.6s-1 .2-1.4.6L7.8 9c-.4.4-.6.9-.6 1.4 0 .6.2 1.1.6 1.4L11 14.5V19h2v-5.6l-2.2-2.1z",bolt:"M7 2v11h3v9l7-12h-4l4-8z",build:"M22.7 19l-9.1-9.1c.9-2.3.4-5-1.5-6.9-2-2-5-2.4-7.4-1.3L9 6 6 9 1.6 4.7C.4 7.1.9 10.1 2.9 12.1c1.9 1.9 4.6 2.4 6.9 1.5l9.1 9.1c.4.4 1 .4 1.4 0l2.3-2.3c.5-.4.5-1.1.1-1.4z",bus:"M4 16c0 .88.39 1.67 1 2.22V20c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h8v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1.78c.61-.55 1-1.34 1-2.22V6c0-3.5-3.58-4-8-4s-8 .5-8 4v10zm3.5 1a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm9 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zM18 11H6V6h12v5z",calendar:"M20 3h-1V1h-2v2H7V1H5v2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 18H4V8h16v13z",car:"M18.92 6.01C18.72 5.42 18.16 5 17.5 5h-11c-.66 0-1.21.42-1.42 1.01L3 12v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-8l-2.08-5.99zM6.5 16a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm11 0a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zM5 11l1.5-4.5h11L19 11H5z",check:"M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z","chevron-right":"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z",clock:"M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20a8 8 0 1 1 0-16 8 8 0 0 1 0 16zm.5-13H11v6l5.25 3.15.75-1.23-4.5-2.67z",close:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z",cloud:"M19.35 10.04A7.49 7.49 0 0 0 12 4C9.11 4 6.6 5.64 5.35 8.04A5.994 5.994 0 0 0 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96z",code:"M9.4 16.6 4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0 4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z",door:"M19 19V5c0-1.1-.9-2-2-2H7c-1.1 0-2 .9-2 2v14H3v2h18v-2h-2zm-4-6h-2v-2h2v2z",error:"M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z",fan:"M12 11a1 1 0 1 0 0 2 1 1 0 0 0 0-2zm.5-9C17 2 17.11 5.57 14.75 6.75c-.99.49-1.43 1.54-1.62 2.47.48.2.9.51 1.22.91 3.7-2 7.68-1.21 7.68 2.37C22 17 18.43 17.11 17.25 14.75c-.5-.99-1.56-1.43-2.49-1.62-.2.48-.51.89-.91 1.22 2 3.69 1.2 7.65-2.37 7.65C7 22 6.89 18.42 9.24 17.24c.98-.49 1.42-1.53 1.62-2.45-.49-.2-.92-.52-1.24-.92C5.94 15.85 2 15.07 2 11.5 2 7 5.56 6.89 6.74 9.25c.5.99 1.55 1.42 2.48 1.61.19-.48.51-.9.92-1.22C8.15 5.96 8.94 2 12.5 2z",flag:"M14.4 6 14 4H5v17h2v-7h5.6l.4 2h7V6z",git:"M5 2a3 3 0 0 1 1 5.83v8.34A3 3 0 1 1 4 16.17V7.83A3 3 0 0 1 5 2zm14 4a3 3 0 0 1-2 2.83V10a4 4 0 0 1-4 4H7v-2h6a2 2 0 0 0 2-2V8.83A3 3 0 1 1 19 6z",heart:"M12 21.35l-1.45-1.32C5.4 15.36 2 12.28 2 8.5 2 5.42 4.42 3 7.5 3c1.74 0 3.41.81 4.5 2.09C13.09 3.81 14.76 3 16.5 3 19.58 3 22 5.42 22 8.5c0 3.78-3.4 6.86-8.55 11.54L12 21.35z",home:"M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z",info:"M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z",light:"M9 21c0 .55.45 1 1 1h4c.55 0 1-.45 1-1v-1H9v1zm3-19C8.14 2 5 5.14 5 9c0 2.38 1.19 4.47 3 5.74V17c0 .55.45 1 1 1h6c.55 0 1-.45 1-1v-2.26c1.81-1.27 3-3.36 3-5.74 0-3.86-3.14-7-7-7z",lock:"M18 8h-1V6A5 5 0 0 0 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm3.1-9H8.9V6a3.1 3.1 0 0 1 6.2 0v2z",mail:"M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4-8 5-8-5V6l8 5 8-5v2z","map-pin":"M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5a2.5 2.5 0 0 1 0-5 2.5 2.5 0 0 1 0 5z",music:"M12 3v10.55A4 4 0 1 0 14 17V7h4V3h-6z",pause:"M6 19h4V5H6v14zm8-14v14h4V5h-4z",phone:"M6.62 10.79c1.44 2.83 3.76 5.14 6.59 6.59l2.2-2.2c.27-.27.67-.36 1.02-.24 1.12.37 2.33.57 3.57.57.55 0 1 .45 1 1V20c0 .55-.45 1-1 1C10.61 21 3 13.39 3 4c0-.55.45-1 1-1h3.5c.55 0 1 .45 1 1 0 1.25.2 2.45.57 3.57.11.35.03.74-.25 1.02l-2.2 2.2z",play:"M8 5v14l11-7z",plug:"M16 7V3h-2v4h-4V3H8v4H7c-.55 0-1 .45-1 1v5.5L9.5 17v4h5v-4l3.5-3.5V8c0-.55-.45-1-1-1h-1z",power:"M13 3h-2v10h2V3zm4.83 2.17-1.42 1.42A6.92 6.92 0 0 1 19 12a7 7 0 0 1-14 0c0-2.08.9-3.95 2.58-5.42L6.17 5.17A8.93 8.93 0 0 0 3 12a9 9 0 0 0 18 0c0-2.74-1.23-5.18-3.17-6.83z",rain:"M18 5.5a6 6 0 0 0-11.6 1.1A4.5 4.5 0 0 0 6.5 15.5h11a5 5 0 0 0 .5-10zM8.1 17 6.6 21h1.6l1.5-4zm4 0-1.5 4h1.6l1.5-4zm4 0-1.5 4h1.6l1.5-4z",refresh:"M17.65 6.35A7.96 7.96 0 0 0 12 4a8 8 0 1 0 7.73 10h-2.08A6 6 0 1 1 12 6c1.66 0 3.14.69 4.22 1.78L13 11h7V4l-2.35 2.35z",remove:"M19 13H5v-2h14v2z",robot:"M20 9V7c0-1.1-.9-2-2-2h-3a3 3 0 0 0-6 0H6c-1.1 0-2 .9-2 2v2a3 3 0 0 0 0 6v4c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-4a3 3 0 0 0 0-6zM7.5 11.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0zM16 17H8v-2h8v2zm-1.5-4a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3z",rocket:"M12 2.5s4.5 2 4.5 9.5l2 2.5V19l-3-1.5h-7L5.5 19v-4.5l2-2.5C7.5 4.5 12 2.5 12 2.5zm0 7a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3zM10 19h4l-2 3z",settings:"M19.14 12.94c.04-.3.06-.61.06-.94 0-.32-.02-.64-.07-.94l2.03-1.58a.49.49 0 0 0 .12-.61l-1.92-3.32a.49.49 0 0 0-.59-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54a.48.48 0 0 0-.48-.41h-3.84c-.24 0-.43.17-.47.41l-.36 2.54c-.59.24-1.13.57-1.62.94l-2.39-.96a.49.49 0 0 0-.59.22L2.74 8.87c-.12.21-.08.47.12.61l2.03 1.58c-.05.3-.09.63-.09.94s.02.64.07.94l-2.03 1.58a.49.49 0 0 0-.12.61l1.92 3.32c.12.22.37.29.59.22l2.39-.96c.5.38 1.03.7 1.62.94l.36 2.54c.05.24.24.41.48.41h3.84c.24 0 .44-.17.47-.41l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.22.08.47 0 .59-.22l1.92-3.32c.12-.22.07-.47-.12-.61l-2.01-1.58zM12 15.6a3.6 3.6 0 1 1 0-7.2 3.6 3.6 0 0 1 0 7.2z",ship:"M20 21c-1.39 0-2.78-.47-4-1.32-2.44 1.71-5.56 1.71-8 0C6.78 20.53 5.39 21 4 21H2v2h2c1.38 0 2.74-.35 4-.99a8.75 8.75 0 0 0 8 0c1.26.65 2.62.99 4 .99h2v-2h-2zM3.95 19H4c1.6 0 3.02-.88 4-2 .98 1.12 2.4 2 4 2s3.02-.88 4-2c.98 1.12 2.4 2 4 2h.05l1.89-6.68c.08-.26.06-.54-.06-.78s-.34-.42-.6-.5L20 10.62V6c0-1.1-.9-2-2-2h-3V1H9v3H6c-1.1 0-2 .9-2 2v4.62l-1.29.42a1 1 0 0 0-.66 1.28L3.95 19zM6 6h12v3.97L12 8 6 9.97V6z",snow:"M22 11h-4.17l3.24-3.24-1.41-1.42L15 11h-2V9l4.66-4.66-1.42-1.41L13 6.17V2h-2v4.17L7.76 2.93 6.34 4.34 11 9v2H9L4.34 6.34 2.93 7.76 6.17 11H2v2h4.17l-3.24 3.24 1.41 1.42L9 13h2v2l-4.66 4.66 1.42 1.41L11 17.83V22h2v-4.17l3.24 3.24 1.42-1.41L13 15v-2h2l4.66 4.66 1.41-1.42L17.83 13H22z",star:"M12 17.27 18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z",stop:"M6 6h12v12H6z",sun:"M12 7a5 5 0 1 0 0 10 5 5 0 0 0 0-10zM11 1h2v3h-2zm0 19h2v3h-2zM1 11h3v2H1zm19 0h3v2h-3zM4.22 5.64l1.42-1.42 2.12 2.12-1.42 1.42zm12.02 12.02 1.42-1.42 2.12 2.12-1.42 1.42zM4.22 18.36l2.12-2.12 1.42 1.42-2.12 2.12zM16.24 6.34l2.12-2.12 1.42 1.42-2.12 2.12z",temp:"M15 13V5a3 3 0 0 0-6 0v8a5 5 0 1 0 6 0zm-3-10a2 2 0 0 1 2 2v3h-4V5a2 2 0 0 1 2-2z",thermometer:"M15 13V5a3 3 0 0 0-6 0v8a5 5 0 1 0 6 0zm-4-8a1 1 0 0 1 2 0h-1v1h1v2h-1v1h1v2h-2V5z",timer:"M15 1H9v2h6V1zm-4 13h2V8h-2v6zm8.03-6.61 1.42-1.42c-.43-.51-.9-.99-1.41-1.41l-1.42 1.42A8.96 8.96 0 0 0 12 4a9 9 0 1 0 9 9c0-2.12-.74-4.07-1.97-5.61zM12 20a7 7 0 1 1 0-14 7 7 0 0 1 0 14z",train:"M12 2c-4 0-8 .5-8 4v9.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h2.23l2-2H14l2 2h2v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V6c0-3.5-3.58-4-8-4zM7.5 17a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm3.5-7H6V6h5v4zm2 0V6h5v4h-5zm3.5 7a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3z",tram:"M19 16.94V8.5c0-2.79-2.61-3.4-6.01-3.49l.76-1.51H17V2H7v1.5h4.75l-.76 1.52C7.86 5.11 5 5.73 5 8.5v8.44c0 1.45 1.19 2.66 2.59 2.97L6 21.5v.5h2.23l2-2H14l2 2h2v-.5L16.5 20h-.08c1.69 0 2.58-1.37 2.58-3.06zM12 18.5a1.5 1.5 0 1 1 0-3 1.5 1.5 0 0 1 0 3zm5-4.5H7V9h10v5z",unlock:"M12 17a2 2 0 1 0 0-4 2 2 0 0 0 0 4zm6-9h-1V6A5 5 0 0 0 7 6h1.9a3.1 3.1 0 0 1 6.2 0v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm0 12H6V10h12v10z",user:"M12 12a4 4 0 1 0 0-8 4 4 0 0 0 0 8zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z",walk:"M13.5 5.5a2 2 0 1 0 0-4 2 2 0 0 0 0 4zM9.8 8.9 7 23h2.1l1.8-8 2.1 2v6h2v-7.5l-2.1-2 .6-3A7.3 7.3 0 0 0 19 13v-2c-1.9 0-3.5-1-4.3-2.4l-1-1.6c-.4-.6-1-1-1.7-1-.3 0-.5.1-.8.1L6 8.3V13h2V9.6l1.8-.7z",warning:"M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z",wifi:"M1 9l2 2c4.97-4.97 13.03-4.97 18 0l2-2C16.93 2.93 7.08 2.93 1 9zm8 8 3 3 3-3a4.24 4.24 0 0 0-6 0zm-4-4 2 2a7.07 7.07 0 0 1 10 0l2-2C15.14 9.14 8.87 9.14 5 13z",wind:"M14.5 17a3 3 0 0 1-6 0h2a1 1 0 1 0 1-1H2v-2h9.5a3 3 0 0 1 3 3zM19 6.5a3.5 3.5 0 0 0-7 0h2a1.5 1.5 0 1 1 1.5 1.5H2v2h13.5A3.5 3.5 0 0 0 19 6.5zm-.5 4.5H2v2h16.5a1.5 1.5 0 0 1 0 3v2a3.5 3.5 0 0 0 0-7z"};var L={ButtonView:"wb-scope-button-view",Buttons2TileView:"wb-scope-buttons2-tile-view",CompactListTileView:"wb-scope-compact-list-tile-view",ComplicationView:"wb-scope-complication-view",ConfirmOverlay:"wb-scope-confirm-overlay",CountdownView:"wb-scope-countdown-view",CurvedText:"wb-scope-curved-text",ErrorView:"wb-scope-error-view",FeedbackOverlay:"wb-scope-feedback-overlay",IconView:"wb-scope-icon-view",List3TileView:"wb-scope-list3-tile-view",ListRow:"wb-scope-list-row",ListView:"wb-scope-list-view",PlaceholderView:"wb-scope-placeholder-view",ProgressRing:"wb-scope-progress-ring",ProgressRingTileView:"wb-scope-progress-ring-tile-view",ProgressView:"wb-scope-progress-view",ScreenView:"wb-scope-screen-view",Skeleton:"wb-scope-skeleton",StackView:"wb-scope-stack-view",StatView:"wb-scope-stat-view",StatusTileView:"wb-scope-status-tile-view",StatusView:"wb-scope-status-view",TextTileView:"wb-scope-text-tile-view",TextView:"wb-scope-text-view",TileFrame:"wb-scope-tile-frame",ToggleView:"wb-scope-toggle-view",UnsupportedView:"wb-scope-unsupported-view",WatchIcon:"wb-scope-watch-icon",WatchOverview:"wb-scope-watch-overview",WatchPreview:"wb-scope-watch-preview"};var be=e=>"text"in e;function u(e,t,n,...r){let o=[],s=e===null;if(n)for(let[a,l]of Object.entries(n))l==null||l===!1||(a==="class"&&e?(o.push([a,`${l===!0?"":String(l)} ${e}`.trim()]),s=!0):o.push([a,l===!0?!0:String(l)]));s||o.push(["class",e]);let i=[];return Gs(r,i),{tag:t,attrs:o,children:i}}function Gs(e,t){for(let n of e)if(!(n==null||n===!1||n===""))if(Array.isArray(n))Gs(n,t);else if(typeof n=="string"){let r=t[t.length-1];r&&be(r)?r.text+=n:t.push({text:n})}else t.push(n)}var qs="http://www.w3.org/2000/svg";function Yr(e){if(be(e))return null;for(let t of["data-wb-key","id","data-path","data-screen","data-glance","data-wb-surface"]){let n=e.attrs.find(r=>r[0]===t);if(n)return n[1]===!0?"":n[1]}return null}function Zs(e,t,n){t==="style"&&"style"in e?e.style.cssText=n===!0?"":n:e.setAttribute(t,n===!0?"":n)}function Un(e,t,n){if(be(t))return t.dom=e.createTextNode(t.text);let r=n||t.tag==="svg",o=r?e.createElementNS(qs,t.tag):e.createElement(t.tag);for(let[s,i]of t.attrs)Zs(o,s,i);for(let s of t.children)o.appendChild(Un(e,s,r));return t.dom=o,o}function Fl(e,t,n,r){if(be(t)||be(n))return be(t)&&be(n)&&t.dom?(t.text!==n.text&&(t.dom.nodeValue=n.text),n.dom=t.dom,t.dom):Hs(e,t,n,r);if(t.tag!==n.tag||!t.dom)return Hs(e,t,n,r);let o=t.dom,s=new Map(t.attrs);for(let[i,a]of n.attrs)s.get(i)!==a&&Zs(o,i,a),s.delete(i);for(let i of s.keys())i==="style"&&"style"in o&&(o.style.cssText=""),o.removeAttribute(i);return n.dom=o,Xs(e,o,t.children,n.children,r||n.tag==="svg"),o}function Hs(e,t,n,r){let o=Un(e,n,r);return t.dom?.parentNode?.replaceChild(o,t.dom),o}function Xs(e,t,n,r,o){let s=new Map;for(let p of n){let d=Yr(p);d!==null&&!s.has(d)&&s.set(d,p)}let i=new Set,a=0,l=()=>{for(;a<n.length&&(i.has(n[a])||Yr(n[a])!==null);)a++},c=t.firstChild;for(let p of r){let d=Yr(p),m;if(d!==null)m=s.get(d),m&&s.delete(d);else{l();let b=n[a];b&&Ul(b,p)&&(m=b,a++)}m&&m.dom?(i.add(m),m.dom!==c?t.insertBefore(m.dom,c):c=c.nextSibling,Fl(e,m,p,o)):t.insertBefore(Un(e,p,o),c)}for(let p of n)!i.has(p)&&p.dom?.parentNode===t&&t.removeChild(p.dom)}function Ul(e,t){return be(e)||be(t)?be(e)&&be(t):e.tag===t.tag}var Ws=new WeakMap;function Ys(e,t){let n=e.ownerDocument,r=Ws.get(e),o=e.namespaceURI===qs;r?Xs(n,e,r,t,o):e.replaceChildren(...t.map(s=>Un(n,s,o))),Ws.set(e,t)}var nn=L.WatchIcon;function fe(e,t="medium",n){let r=e?.name,o=e?.url,s=n??"";if(o!==void 0&&o.trim()!=="")return u(nn,"img",{class:`wb-icon wb-icon--${t} wb-icon--image ${s}`,src:o,alt:"",loading:"lazy"});let i=r===void 0?void 0:Us[r];return i!==void 0?u(nn,"svg",{class:`wb-icon wb-icon--${t} ${s}`,viewBox:Xr,"data-icon":r,"aria-hidden":"true"},u(nn,"path",{d:i})):j(r)?null:u(nn,"svg",{class:`wb-icon wb-icon--${t} wb-icon--unknown ${s}`,viewBox:Xr,"data-icon":r,"aria-hidden":"true"},u(nn,"circle",{cx:"12",cy:"12",r:"5"}))}var he=(e,t,n)=>fe({name:e},t,n),Qs=L.Skeleton;function B(e={}){let{shape:t="line",lines:n=1,width:r,cls:o=""}=e;if(t==="line"){let s=[];for(let i=0;i<n;i++)s.push(u(Qs,"span",{class:`wb-skeleton wb-skeleton--line ${o}`,style:`width:${i===n-1&&n>1?"60%":r??"80%"}`}));return s}return[u(Qs,"span",{class:`wb-skeleton wb-skeleton--${t} ${o}`,style:r===void 0?null:`width:${r}`})]}var rn=L.CurvedText;function Hn(e,t,n,r=!1){let o=e.newId("arc"),s=e.device,i=e.tokens.sizes.curvedTextInset??18,a=s.widthDp/2,l=s.heightDp/2,c=r?a-i/3-(e.tokens.typeScale.caption?.size??12)*500/2048:a-i,p=`M${G(a-c)} ${G(l)} A${G(c)} ${G(c)} 0 0 ${r?0:1} ${G(a+c)} ${G(l)}`;return u(rn,"svg",{class:`wb-curved ${n}`,viewBox:`0 0 ${G(s.widthDp)} ${G(s.heightDp)}`,"aria-label":t},u(rn,"defs",null,u(rn,"path",{id:o,d:p})),u(rn,"text",null,u(rn,"textPath",{href:`#${o}`,startOffset:"50%","text-anchor":"middle"},t)))}var Qr=L.ProgressRing;function on(e,t={}){let{stroke:n="var(--wb-progress-ring-stroke)",gapPercent:r=0,radius:o=44,cls:s=""}=t,i=100-r,a=Math.min(Math.max(e,0),1)*i*3.6,l=r>0?90+r*3.6/2:-90;return u(Qr,"svg",{class:`wb-ring ${s}`,viewBox:"0 0 100 100","aria-hidden":"true"},u(Qr,"path",{class:"wb-ring__track",d:Vn(50,50,o,l,i*3.6),style:`stroke-width:${n}`}),e>0&&u(Qr,"path",{class:"wb-ring__fill",d:Vn(50,50,o,l,a),"data-sweep":G(a),style:`stroke-width:${n}`}))}function sn(e,t,n){let r=_t(h(e,"target"));return r===null?null:{"data-wb-countdown":!0,"data-target":zn(r),"data-format":h(e,"format")==="clock"?"clock":"relative","data-ambient":t.ambient?"true":"false","data-max":n==null?null:String(n)}}function an(e,t){return Ls(_t(h(e,"target")),t.now,h(e,"format")==="clock",t.ambient)}var it=L.ListRow;function Wn(e,t,n,r=!1){let o=D(t,"action"),s=`wb-row${r?" wb-row--compact":""}${o?" wb-row--action":""}`,i=h(t,"subtitle"),a=h(t,"badge"),l=D(t,"trailing"),c=[fe(de(h(t,"icon")),r?"small":"medium","wb-row__icon"),u(it,"span",{class:"wb-row__text"},u(it,"span",{class:"wb-row__title"},h(t,"title")??""),!j(i)&&u(it,"span",{class:"wb-row__subtitle"},i)),!j(a)&&u(it,"span",{class:"wb-row__badge"},a),Kr(e,l,it,"wb-row__trailing")];return o?u(it,"button",{type:"button",class:s,"data-path":n,"data-wb-tap":"action"},c):u(it,"div",{class:s,"data-path":n},c)}function Kr(e,t,n,r){if(!t)return null;let o=h(t,"type");if(o==="countdown")return u(n,"span",{class:`${r} ${r}--countdown`,...sn(t,e)},an(t,e));let s=h(t,"value");return o==="text"&&!j(s)?u(n,"span",{class:r},s):null}function ln(e){return u(L.UnsupportedView,"div",{class:"wb-unsupported",title:`No renderer for ${e} yet`},e)}function cn(e,t,n){if(!t)return null;switch(h(t,"type")){case"text":return Hl(e,t);case"stat":return ro(e,t);case"list":return Wl(e,t,n);case"status":return Gl(e,t);case"progress":return ql(e,t);case"countdown":return Zl(e,t);case"button":return Xl(t,n);case"toggle":return io(t,n);case"icon":return Yl(t);case"stack":return Ql(e,t,n);case"placeholder":return Kl(t);case"error":return ec(t);case"unsupported":return ln(h(t,"component")??"");default:return ln(h(t,"type")??"")}}var Ks=L.TextView;function Hl(e,t){let n=h(t,"style")??"body",r=Q(t,"maxLines")??3;if(ne(e))return u(Ks,"div",{class:`wb-text wb-text--${n} wb-text--loading`},B({lines:Math.min(r,2)}));let o=Math.max(1,r);return u(Ks,"div",{class:`wb-text wb-text--${n} wb-text--clamp`,style:`-webkit-line-clamp:${o}`,"data-max-lines":String(o)},h(t,"value")??"")}var Ie=L.StatView,ei={up:"Up",down:"Down",flat:"Flat"};function ro(e,t){let n=ne(e),r=h(t,"trend")??"none",o=re(e)||j(h(t,"value"))?Be:h(t,"value"),s=h(t,"unit"),i=h(t,"label"),a=r in ei&&!re(e)?u(Ie,"svg",{class:`wb-stat__trend wb-stat__trend--${r}`,viewBox:"0 0 24 24","aria-label":ei[r]},r==="up"?u(Ie,"path",{d:"M12 5l7 9H5z"}):r==="down"?u(Ie,"path",{d:"M12 19l-7-9h14z"}):u(Ie,"rect",{x:"5",y:"10.5",width:"14",height:"3",rx:"1.5"})):null;return u(Ie,"div",{class:`wb-stat ${n?"wb-stat--loading":""}`},fe(de(h(t,"icon")),"small","wb-stat__icon"),n?B({cls:"wb-stat__skeleton",width:"50%"}):u(Ie,"div",{class:"wb-stat__value-row"},a,u(Ie,"span",{class:"wb-stat__value"},o),!j(s)&&u(Ie,"span",{class:"wb-stat__unit"},s)),!j(i)&&u(Ie,"div",{class:"wb-stat__label"},i))}var Et=L.ListView;function Wl(e,t,n){let r=h(t,"header"),o=Oe(t,"items"),s=Q(t,"maxRows")??0,i=Q(t,"totalCount")??0,a;if(ne(e)){let l=s>0&&s<3?s:3;a=Array.from({length:l},()=>u(Et,"div",{class:"wb-list__placeholder"},B({shape:"circle"}),u(Et,"span",{class:"wb-list__placeholder-text"},B({width:"70%"}),B({width:"45%"}))))}else if(re(e)||o.length===0){let l=h(t,"emptyText");a=u(Et,"div",{class:"wb-list__empty"},j(l)?"Nothing to show":l)}else a=[o.map((l,c)=>Wn(e,l,`${n}.items[${c}]`)),i>o.length&&u(Et,"div",{class:"wb-list__more"},`+${i-o.length} more`)];return u(Et,"section",{class:"wb-list"},!j(r)&&u(Et,"header",{class:"wb-list__header"},r),a)}var Mt=L.StatusView,oo=e=>e==="ok"?"check":e==="warn"?"warning":e==="error"?"error":"info",so=e=>e==="ok"?"OK":e==="warn"?"Warning":e==="error"?"Error":"Unknown";function Gl(e,t){let n=h(t,"state")??"unknown",r=h(t,"label"),o=h(t,"detail");return u(Mt,"div",{class:`wb-status wb-status--${n}`,"data-state":n},ne(e)?[B({shape:"circle"}),u(Mt,"span",{class:"wb-status__text"},B({width:"70%"}))]:[u(Mt,"span",{class:"wb-status__badge"},he(oo(n),"small")),u(Mt,"span",{class:"wb-status__text"},u(Mt,"span",{class:"wb-status__label"},j(r)?so(n):r),!j(o)&&u(Mt,"span",{class:"wb-status__detail"},o))])}var _e=L.ProgressView;function qn(e,t,n){return n>t?Math.min(Math.max((e-t)/(n-t),0),1):0}function ql(e,t){let n=Q(t,"value")??0,r=Q(t,"min")??0,o=Q(t,"max")??100,s=h(t,"label"),i=ne(e),a=i||re(e)?0:qn(n,r,o),l=re(e)?Be:Cn(n,r,o),c={role:"progressbar","aria-valuenow":Ce(n),"aria-valuemin":Ce(r),"aria-valuemax":Ce(o)};return h(t,"style")==="ring"?u(_e,"div",{class:"wb-progress wb-progress--ring",...c},u(_e,"div",{class:"wb-progress__ring"},on(a),u(_e,"span",{class:"wb-progress__value"},i?B({width:"60%"}):l)),!j(s)&&u(_e,"div",{class:"wb-progress__label"},s)):u(_e,"div",{class:"wb-progress wb-progress--bar",...c},u(_e,"div",{class:"wb-progress__caption"},u(_e,"span",{class:"wb-progress__label"},s??""),u(_e,"span",{class:"wb-progress__value"},i?"":l)),u(_e,"div",{class:`wb-progress__track ${i?"wb-progress__track--loading":""}`},u(_e,"div",{class:"wb-progress__fill",style:`width:${G(a*100)}%`})))}var eo=L.CountdownView;function Zl(e,t){let n=_t(h(t,"target")),r=h(t,"label");return u(eo,"div",{class:`wb-countdown wb-countdown--${h(t,"format")??"relative"}`,"data-target":n===null?null:zn(n)},ne(e)?B({width:"45%",cls:"wb-countdown__skeleton"}):u(eo,"span",{class:"wb-countdown__value",...re(e)?null:sn(t,e)},re(e)?Be:an(t,e)),!j(r)&&u(eo,"span",{class:"wb-countdown__label"},r))}var ti=L.ButtonView;function Xl(e,t){let n=D(e,"action"),r=de(h(e,"icon"));return u(ti,"button",{type:"button",class:`wb-button wb-button--${h(e,"style")??"primary"} ${r?"wb-button--icon":""} ${n?"":"wb-button--disabled"}`,disabled:!n,"data-action":h(n,"id"),"data-wb-tap":n?"action":null,"data-path":t},fe(r,"medium","wb-button__icon"),u(ti,"span",{class:"wb-button__label"},h(e,"label")??""))}var at=L.ToggleView;function io(e,t,n=!1,r=null){let o=e.on===!0,s=de(h(e,"icon"))??(n?r:null),i=h(e,"label")??"";return u(at,"button",{type:"button",role:"switch","aria-checked":o?"true":"false",class:`wb-toggle ${o?"wb-toggle--on":""} ${n?"wb-toggle--tile":""}`,"data-path":t,"data-wb-tap":"toggle","data-on":o?"true":"false"},s&&fe(s,"medium","wb-toggle__icon"),n?u(at,"span",{class:"wb-toggle__text"},u(at,"span",{class:"wb-toggle__label"},i),u(at,"span",{class:"wb-toggle__state"},o?"On":"Off")):[u(at,"span",{class:"wb-toggle__label"},i),u(at,"span",{class:"wb-toggle__switch"},u(at,"span",{class:"wb-toggle__thumb"}))])}function Yl(e){let t=h(e,"size")??"medium";return u(L.IconView,"div",{class:`wb-icon-node wb-icon-node--${t}`},fe(de(h(e,"icon"),h(e,"imageUrl"))??{},t))}var to=L.StackView;function Ql(e,t,n){let r=h(t,"header");return u(to,"section",{class:`wb-stack wb-stack--${h(t,"direction")??"vertical"}`},!j(r)&&u(to,"header",{class:"wb-stack__header"},r),u(to,"div",{class:"wb-stack__children"},Oe(t,"children").map((o,s)=>cn(e,o,`${n}.children[${s}]`))))}var no=L.PlaceholderView;function Kl(e){let t=h(e,"component")??"",n=Math.max(1,Q(e,"rows")??1),r=(s,i)=>u(no,"div",{class:"wb-placeholder__chip"},B({shape:"circle"}),u(no,"span",{class:"wb-placeholder__lines"},B({width:s}),i!==void 0&&B({width:i}))),o;switch(t){case"list":o=Array.from({length:n},()=>r("70%","45%"));break;case"button":case"toggle":case"status":o=r("60%");break;case"stat":case"countdown":o=[B({width:"50%",cls:"wb-placeholder__big"}),B({width:"35%"})];break;case"progress":o=B({shape:"circle",cls:"wb-placeholder__ring"});break;default:o=B({lines:n})}return u(no,"div",{class:`wb-placeholder wb-placeholder--${t}`,"data-component":t,"aria-busy":"true"},o)}var Gn=L.ErrorView;function ec(e){let t=h(e,"source"),n=h(e,"message")??"",r=t===void 0?"Couldn't load":`Couldn't load ${t}`;return u(Gn,"div",{class:"wb-error-node",role:"alert","data-component":h(e,"component")??"","data-source":t},he("error","small"),u(Gn,"span",{class:"wb-error-node__text"},u(Gn,"span",{class:"wb-error-node__title"},r),!j(n)&&n!==r&&u(Gn,"span",{class:"wb-error-node__message"},n)))}var tc={shortText:7,longText:24},ao=e=>`$.glances.${e}`;function ni(e,t){let n=ao(h(t,"id")??"");switch(h(t,"template")){case"text":return He(e,t,"text",!0,u(L.TextTileView,"div",{class:"wb-text-tile"},cn(e,D(t,"text"),`${n}.text`)));case"single-stat":return He(e,t,"single-stat",!0,ro(e,D(t,"stat")??{}));case"list3":return nc(e,t,n);case"compact-list":return rc(e,t,n);case"status":return oc(e,t);case"progress-ring":return sc(e,t);case"buttons2":return ic(e,t,n);case"toggle":return He(e,t,"toggle",!1,io(D(t,"toggle")??{},`${n}.toggle`,!0,de(h(t,"icon"))));default:return ln(`${h(t,"template")??"Unknown"}Tile`)}}var Ue=L.TileFrame;function He(e,t,n,r,...o){let s=ao(h(t,"id")??""),i=h(t,"opens"),a=r&&i!==void 0,l=n==="progress-ring"?null:de(h(t,"icon")),c=h(t,"title"),p=h(D(t,"data"),"state"),d=p==="stale"&&e.data.updatedAt!==null?jn(e.data.updatedAt,e.now):p==="sample"?"Sample data":null,m=e.data.phase==="error"&&u(Ue,"div",{class:"wb-tile__error",role:"alert"},he("warning","small"),"Couldn't refresh");return u(Ue,"div",{class:`wb-tile wb-tile--${n} ${a?"wb-tile--edge":""}`,"data-glance":h(t,"id"),"data-wb-tap":i===void 0?null:"open","data-path":s,role:"button"},u(Ue,"header",{class:"wb-tile__title"},l?fe(l,"medium","wb-tile__title-icon"):u(Ue,"span",{class:"wb-tile__icon-slot","aria-hidden":"true"}),!j(c)&&u(Ue,"span",{class:"wb-tile__title-text"},c)),u(Ue,"div",{class:"wb-tile__main"},m,o),!j(d)&&u(Ue,"div",{class:"wb-tile__bottom-label"},d),a&&u(Ue,"button",{type:"button",class:"wb-edge-button","data-wb-tap":"open","data-path":s},"Open"))}function nc(e,t,n){let r=L.List3TileView,o=e.tokens.limits.tileListMaxRows??3,s=Oe(t,"items"),i=s.slice(0,o),a=Math.max(Q(t,"totalCount")??0,s.length)-i.length,l=h(t,"emptyText");return He(e,t,"list3",!0,u(r,"div",{class:"wb-list3"},ne(e)?Array.from({length:o},()=>B({width:"90%"})):re(e)||i.length===0?u(r,"div",{class:"wb-list3__empty"},j(l)?"Nothing to show":l):[i.map((c,p)=>Wn(e,c,`${n}.items[${p}]`,!0)),a>0&&u(r,"div",{class:"wb-list3__more"},`+${a} more`)]))}function rc(e,t,n){let r=L.CompactListTileView,o=e.tokens.limits,s=Br(e.device,e.tokens)?o.tileCompactListMaxRowsSmallScreen??6:o.tileCompactListMaxRows??8;e.data.phase==="error"&&s--,Fn(e.data,e.now)&&s--,s=Math.max(1,s);let i=Oe(t,"items").slice(0,s),a=h(t,"emptyText");return He(e,t,"compact-list",!1,u(r,"div",{class:"wb-compact-list"},ne(e)?Array.from({length:s},()=>u(r,"div",{class:"wb-compact-list__row"},B({width:"90%"}))):re(e)||i.length===0?u(r,"div",{class:"wb-compact-list__empty"},j(a)?"Nothing to show":a):i.map((l,c)=>u(r,"div",{class:"wb-compact-list__row","data-path":`${n}.items[${c}]`},u(r,"span",{class:"wb-compact-list__title"},h(l,"title")??""),Kr(e,D(l,"trailing"),r,"wb-compact-list__trailing")))))}function oc(e,t){let n=L.StatusTileView,r=D(t,"status"),o=h(r,"state")??"unknown",s=h(r,"label"),i=h(r,"detail");return He(e,t,"status",!0,u(n,"div",{class:`wb-status-tile wb-status-tile--${o}`,"data-state":o},ne(e)?[B({shape:"circle",cls:"wb-status-tile__skeleton"}),B({width:"60%"})]:[u(n,"span",{class:"wb-status-tile__badge"},he(oo(o),"large")),u(n,"span",{class:"wb-status-tile__label"},j(s)?so(o):s),!j(i)&&u(n,"span",{class:"wb-status-tile__detail"},i)]))}function sc(e,t){let n=L.ProgressRingTileView,r=D(t,"progress"),o=Q(r,"value")??0,s=Q(r,"min")??0,i=Q(r,"max")??100,a=h(r,"label"),l=e.device.widthDp-2*(e.tokens.spacing.xs??4),c=Dn(e.device,e.tokens).tileRingStroke??8,p=l>0?50-c/2/l*100:47,d=ne(e)||re(e)?0:qn(o,s,i);return He(e,t,"progress-ring",!0,u(n,"div",{class:"wb-progress-tile__ring"},on(d,{radius:p,stroke:"var(--wb-tile-ring-stroke)",gapPercent:h(t,"opens")===void 0?0:22})),u(n,"div",{class:"wb-progress-tile"},ne(e)?B({width:"50%",cls:"wb-progress-tile__skeleton"}):u(n,"span",{class:"wb-progress-tile__value"},re(e)?Be:Cn(o,s,i)),!j(a)&&u(n,"span",{class:"wb-progress-tile__label"},a)))}function ic(e,t,n){let r=L.Buttons2TileView,o=Oe(t,"buttons").slice(0,e.tokens.limits.tileMaxButtons??2),s=i=>i.trim()===""?"?":i.trim().slice(0,1).toUpperCase();return He(e,t,"buttons2",!1,u(r,"div",{class:"wb-buttons2"},o.map((i,a)=>{let l=D(i,"action"),c=de(h(i,"icon")),p=h(i,"label")??"";return u(r,"div",{class:"wb-buttons2__item"},u(r,"button",{type:"button",class:`wb-buttons2__button wb-buttons2__button--${h(i,"style")??"primary"}`,disabled:!l,"data-action":h(l,"id"),"data-wb-tap":l?"action":null,"data-path":`${n}.buttons[${a}]`,"aria-label":p},c?fe(c,"large"):u(r,"span",{class:"wb-buttons2__initial"},s(p))),u(r,"span",{class:"wb-buttons2__label"},p))})))}var ac={shortText:"short-text",longText:"long-text",rangedValue:"ranged-value",image:"image"};function ri(e,t){let n=L.ComplicationView,r=h(t,"kind")??"shortText",o=ac[r]??"image",s=r==="longText",i=h(t,"opens"),a=h(t,"title"),l=de(h(t,"icon"),h(t,"imageUrl")),c=tc[r],p=l===null&&!j(a),d=D(t,"text"),m;if(ne(e))m="\u2026";else if(re(e))m=Be;else{let P=h(d,"type"),x=Q(t,"value");m=Dr(P==="text"?h(d,"value")??"":P==="countdown"?an(d,e):r==="rangedValue"&&x!==void 0?Ce(x):"",c)}let b=d&&h(d,"type")==="countdown"&&!ne(e)&&!re(e)?sn(d,e,c):null,g=u(n,"span",{class:"wb-comp__text",...b},m),S=u(n,"span",{class:"wb-comp__title"},Dr(a,c)),_=P=>l&&fe(l,P,"wb-comp__icon"),A=0,J=Q(t,"value");!ne(e)&&!re(e)&&J!==void 0&&(A=qn(J,Q(t,"min")??0,Q(t,"max")??100));let w;switch(r){case"shortText":w=[_("small"),g,p&&S];break;case"longText":w=[_("medium"),u(n,"span",{class:"wb-comp__lines"},!j(a)&&S,g)];break;case"rangedValue":w=[u(n,"span",{class:"wb-comp__ring"},on(A,{radius:45,gapPercent:22,stroke:"var(--wb-ranged-stroke)"})),_("small"),g,p&&S];break;default:w=l&&fe(l,j(l.url)?"large":"fill")}let C=()=>!s&&u(n,"span",{class:"wb-face__placeholder"});return u(n,"div",{class:`wb-face ${e.device.isRound?"":"wb-face--square"}`},u(n,"div",{class:"wb-face__ticks"}),u(n,"div",{class:"wb-face__time"},In(e.now,e.timeZone)),u(n,"div",{class:"wb-face__date"},Ps(e.now,e.timeZone)),u(n,"div",{class:`wb-face__slots ${s?"wb-face__slots--long":""}`},C(),u(n,"div",{class:`wb-comp wb-comp--${o} ${i===void 0?"":"wb-comp--tappable"}`,"data-glance":h(t,"id"),"data-kind":o,"data-wb-tap":i===void 0?null:"open","data-path":ao(h(t,"id")??""),role:"button"},w),C()))}function lc(e){let t=h(e,"main"),n=Oe(e,"screens"),o=[...n.filter(a=>h(a,"id")===t),...n.filter(a=>h(a,"id")!==t)].map(a=>({key:`page:${h(a,"id")}`,label:h(a,"id")??"",kind:"screen",node:a})),s=D(e,"tile"),i=D(e,"complication");return s&&o.push({key:"tile",label:"Tile",kind:"glance",node:s}),i&&o.push({key:"complication",label:"Complication",kind:"glance",node:i}),o}function cc(e,t){let n=Oe(e,"screens"),r=[D(e,"tile"),D(e,"complication")].filter(p=>p!==void 0),o=p=>n.find(d=>h(d,"id")===p),s=p=>r.find(d=>h(d,"id")===p),i=t.screen!==void 0?`screen:${t.screen}`:t.surface??`page:${h(e,"main")}`,[a,l]=i.includes(":")?[i.slice(0,i.indexOf(":")),i.slice(i.indexOf(":")+1)]:[i,void 0],c=a==="page"||a==="screen"?o(l)&&{kind:"screen",node:o(l)}:a==="glance"?s(l)&&{kind:"glance",node:s(l)}:a==="tile"||a==="complication"?D(e,a)&&{kind:"glance",node:D(e,a)}:void 0;return c||(n[0]?{kind:"screen",node:n[0]}:r[0]?{kind:"glance",node:r[0]}:null)}var lo=L.WatchPreview;function po(e,t){let n=Jn(t.deviceProfile),r=t.ambient===!0,o=cc(e,t),i=o!==null&&o.kind==="glance"&&h(o.node,"template")!==void 0?zs(t.theme??Ot(),n):t.theme??Ot(),a=o?Zr(D(o.node,"data"),o.kind==="glance"):Zr(void 0,!1),l={device:n,theme:i,tokens:ue,ambient:r,data:a,now:t.now??Date.now(),timeZone:t.timeZone??h(e,"timeZone")??"UTC",newId:Fs(t.idPrefix??"wbp")},c=[o===null?u(null,"div",{class:"wb-empty"},"Nothing to show"):o.kind==="screen"?pc(l,o.node):h(o.node,"kind")!==void 0&&h(o.node,"template")===void 0?ri(l,o.node):ni(l,o.node),t.feedback&&uc(t.feedback),t.confirm&&dc(t.confirm)],p=u(lo,"div",{class:"wb-screen"},c),d=n.isRound?n.id.includes("classic")?"wb-case--classic":"":"wb-case--square";return u(lo,"div",{class:`wb-preview ${r?"wb-ambient":""} wb-tone-${i.tone} wb-shape-${n.isRound?"round":"square"} wb-platform-${n.platform}`,style:`zoom:${G(t.scale??1)};${Is(n,i,r)}`,"data-device":n.id,"data-data-phase":a.phase},t.frame===!1?p:u(lo,"div",{class:`wb-case ${d}`},p))}var Ee=L.ScreenView;function pc(e,t){let n=h(t,"id")??"",r=e.data.phase==="error",o=G(e.device.widthDp),s=Hn(e,In(e.now,e.timeZone),"wb-time-text"),i=e.data.errorMessage,a=u(Ee,"div",{class:"wb-scroll"},u(Ee,"div",{class:"wb-content"},r&&u(Ee,"div",{class:"wb-data-error",role:"alert"},he("warning","small"),u(Ee,"span",{class:"wb-data-error__text"},u(Ee,"span",{class:"wb-data-error__title"},"Couldn't refresh"),!j(i)&&u(Ee,"span",{class:"wb-data-error__detail"},i))),cn(e,D(t,"root"),`$.screens.${n}.root`))),l=Bn(e.device,0,.7,e.tokens),c=u(Ee,"svg",{class:"wb-position-indicator",viewBox:`0 0 ${o} ${o}`,"aria-hidden":"true",style:`stroke-width:${G(l.width)}px`},u(Ee,"path",{class:"wb-position-indicator__track",d:l.track}),u(Ee,"path",{class:"wb-position-indicator__thumb",d:l.thumb})),p=e.data.updatedAt,d=h(D(t,"data"),"state")==="sample",m=p!==null&&Fn(e.data,e.now)?Hn(e,jn(p,e.now),"wb-stale-hint",!0):d?Hn(e,"Sample data","wb-stale-hint",!0):null;return u(Ee,"div",{class:`wb-screen-view ${e.device.isRound?"wb-screen-view--round":"wb-screen-view--square"} ${r?"wb-screen-view--error":""}`,"data-screen":n},s,a,c,m)}var co=L.FeedbackOverlay;function uc(e){let t=e.sequence??0,n=e.success,r=[u(co,"div",{"data-wb-key":`haptic-${t}`,class:`wb-haptic ${n?"wb-haptic--ok":"wb-haptic--error"}`,"aria-hidden":"true"})];return e.toast!==!1&&r.push(u(co,"div",{"data-wb-key":`toast-${t}`,class:`wb-toast ${n?"wb-toast--ok":"wb-toast--error"}`,role:"status"},he(n?"check":"error","small"),u(co,"span",{class:"wb-toast__text"},e.message??(n?"Done":"Failed")))),r}var pn=L.ConfirmOverlay;function dc(e){return u(pn,"div",{class:"wb-confirm",role:"alertdialog","aria-label":e.prompt},!j(e.icon)&&he(e.icon,"medium","wb-confirm__icon"),u(pn,"div",{class:"wb-confirm__prompt"},e.prompt),u(pn,"div",{class:"wb-confirm__buttons"},u(pn,"button",{type:"button",class:"wb-confirm__cancel","aria-label":"Cancel","data-wb-tap":"cancel"},he("close")),u(pn,"button",{type:"button",class:"wb-confirm__ok","aria-label":"Confirm","data-wb-tap":"confirm"},he("check"))))}var Zn=L.WatchOverview;function oi(e,t){let n=`${t.idPrefix??"wbp"}-ov`,{confirm:r,feedback:o,screen:s,...i}=t;return u(Zn,"div",{class:"wb-overview","data-wb-overview":!0},lc(e).map((a,l)=>u(Zn,"figure",{class:"wb-overview__item","data-wb-surface":a.key,"data-wb-key":`overview-${a.key}`},u(Zn,"div",{class:"wb-overview__watch"},po(e,{...i,surface:a.key,idPrefix:`${n}-${l}`})),u(Zn,"figcaption",{class:"wb-overview__label"},a.label))))}var fc=[":scope > .wb-stack--vertical > .wb-stack__header",":scope > .wb-stack--vertical > .wb-stack__children > :not(.wb-list)",":scope > .wb-stack--vertical > .wb-stack__children > .wb-list > *",":scope > .wb-list > *",":scope > :not(.wb-stack--vertical):not(.wb-list):not(.wb-data-error)"].join(",");function hc(e){if(e<=0)return 0;if(e>=1)return 1;let t=(o,s,i)=>3*s*o*(1-o)**2+3*i*o*o*(1-o)+o**3,n=0,r=1;for(let o=0;o<30;o++){let s=(n+r)/2;t(s,.3,.7)<e?n=s:r=s}return t((n+r)/2,0,1)}var Xn=(e,t,n)=>e+(t-e)*n,uo=e=>Math.min(Math.max(e,0),1);function mc(e,t,n,r){let o=g=>ue.effects[g]??0,s=uo((e.widthDp-o("edgeSpecSmallScreenWidth"))/(o("edgeSpecLargeScreenWidth")-o("edgeSpecSmallScreenWidth"))),i=g=>Xn(o(`${g}Small`),o(`${g}Large`),s),a=t/r,l=n/r,c=l-a,p=i("edgeMinElementHeight"),d=i("edgeMaxElementHeight"),m=uo((c-p)/(d-p)),b=Math.min(Xn(i("edgeMinTransitionArea"),i("edgeMaxTransitionArea"),m),(1+c)/2);return uo(l<1-a?l/b:(1-a)/b)}function ho(e,t){for(let r of e.querySelectorAll(".wb-screen-view .wb-scroll"))si(r,t);let n=e.ownerDocument.fonts;n&&n.status!=="loaded"&&n.ready.then(()=>{e.isConnected&&ho(e,t)})}function si(e,t){let n=e.firstElementChild;if(!n)return;e.dataset.wbWear||(e.dataset.wbWear="1",e.addEventListener("scroll",()=>si(e,t),{passive:!0}));let r=[...n.querySelectorAll(fc)];for(let x of r)x.style.removeProperty("scale"),x.style.removeProperty("opacity"),x.style.removeProperty("margin-bottom"),x.style.removeProperty("transform-origin");let o=e.clientHeight;if(o<=0||r.length===0)return fo(e,t,0,0);let s=t.density,i=e.getBoundingClientRect(),a=i.height/o||1,l=r.map(x=>(x.getBoundingClientRect().top-i.top)/a),c=r.map(x=>x.getBoundingClientRect().height/a),p=n.scrollHeight<=o+.5,d=l.map((x,y)=>y===0?0:x-(l[y-1]+c[y-1])),m=Fr(t,0).scale,b=ue.effects.edgeAlpha??.5,g=r.map(()=>1),S=g,_=l;for(let x=0;x<3;x++){let y=c.map((N,T)=>N-Math.ceil(N*S[T]*s)/s),z=l[0]+(p?y.reduce((N,T)=>N+T,0)/2:0);_=c.map((N,T)=>{z+=d[T];let Z=z;return z+=N-y[T],Z}),g=c.map((N,T)=>hc(mc(t,_[T]-d[T],_[T]+N,o))),S=g.map(N=>Xn(m,1,N))}r.forEach((x,y)=>{let z=S[y];if(g[y]>=1)return;let N=c[y];x.style.setProperty("margin-bottom",`${-(N-Math.ceil(N*z*s)/s)}px`),!x.matches(".wb-row:not(.wb-row--action)")&&(x.style.setProperty("scale",String(z)),x.style.setProperty("transform-origin","50% 0"),x.style.setProperty("opacity",String(Xn(b,1,g[y]))))});let A=-1,J=0;_.forEach((x,y)=>{let z=c[y]*S[y],N=x+z;N<=0||x>=o||(A<0&&(A=y+(x<0?-x/z:0)),J=y+(N>o?(o-x)/z:1))});let w=r.length;if(e.scrollHeight<=o)return fo(e,t,0,0);let C=A<0?0:Math.min(Math.max((J-A)/w,.3),.7),P=A+(w-J);fo(e,t,A<0||P<=0?0:A/P*(1-C),C)}function fo(e,t,n,r){let o=e.parentElement?.querySelector(".wb-position-indicator");if(!o)return;o.style.display=r>0?"":"none";let s=Bn(t,n,r);o.querySelector(".wb-position-indicator__track")?.setAttribute("d",s.track),o.querySelector(".wb-position-indicator__thumb")?.setAttribute("d",s.thumb)}function gc(e,t){return[t.surface==="overview"&&t.screen===void 0?oi(e,t):po(e,t)]}function ii(e,t,n){Ys(e,gc(t,n)),ho(e,Jn(n.deviceProfile))}var mo=new DataView(new ArrayBuffer(8)),Yn=[1n];function bc(e){for(let t=Yn.length;t<=e;t++)Yn.push(Yn[t-1]*5n);return Yn[e]}function ai(e){mo.setFloat64(0,e);let t=mo.getUint32(0),n=mo.getUint32(4),r=t>>>20&2047,o=BigInt(t&1048575)<<32n|BigInt(n);return r===0?r++:o|=1n<<52n,r-=1075,o===0n?{digits:"",exp:0}:r>=0?un((o<<BigInt(r)).toString(),0):un((o*bc(-r)).toString(),r)}function un(e,t){let n=0;for(;n<e.length&&e.charCodeAt(n)===48;)n++;let r=e.length;for(;r>n&&e.charCodeAt(r-1)===48;)r--,t++;return{digits:e.slice(n,r),exp:n===r?0:t}}function li(e){let t=e.length-1;for(;t>=0&&e.charCodeAt(t)===57;)t--;return t<0?"1"+"0".repeat(e.length):e.slice(0,t)+String.fromCharCode(e.charCodeAt(t)+1)+"0".repeat(e.length-t-1)}function ci(e,t){let n=-t-e.exp;if(n<=0)return e;if(n>e.digits.length)return{digits:"",exp:0};let r=e.digits.slice(0,e.digits.length-n),o=e.digits.charCodeAt(e.digits.length-n)>=53;return un(o?li(r||"0"):r,-t)}function wc(e,t){let n=e.digits.length-t;if(n<=0)return e;let r=e.digits.slice(0,t),o=e.digits.charCodeAt(t),s=o>53;if(o===53){let i=!1;for(let a=t+1;a<e.digits.length&&!i;a++)i=e.digits.charCodeAt(a)!==48;s=i||(r.charCodeAt(r.length-1)&1)===1}return un(s?li(r):r,e.exp+n)}function pi(e,t){if(e.digits==="")return["0","0".repeat(t)];let n,r;if(e.exp>=0)n=e.digits+"0".repeat(e.exp),r="";else{let o=e.digits.length+e.exp;n=o>0?e.digits.slice(0,o):"0",r=o>=0?e.digits.slice(o):"0".repeat(-o)+e.digits}return[n,r.length<t?r+"0".repeat(t-r.length):r]}function yc(e){if(e.length<=3)return e;let t=e.length%3,n=t>0?e.slice(0,t):"";for(let r=t;r<e.length;r+=3)n+=(n.length>0?",":"")+e.slice(r,r+3);return n}function dn(e,t,n,r,o){if(!Number.isFinite(e))return"";let s=ai(e),i=ci(s.digits===""?s:{digits:s.digits,exp:s.exp+o},t),[a,l]=pi(i,t),c=l;if(r){let d=c.length;for(;d>0&&c.charCodeAt(d-1)===48;)d--;c=c.slice(0,d)}return(e<0&&i.digits!==""?"-":"")+(n?yc(a):a)+(c.length>0?"."+c:"")}var vc=(e,t)=>dn(e,t,!0,!1,0),xc=(e,t)=>dn(e,t,!1,!1,0),kc=(e,t)=>dn(e,t,!0,!1,2)+" %",ui=e=>dn(e,2,!0,!0,0),Tc=(e,t)=>dn(e,t,!1,!0,0),Sc=[[1,""],[1e3,"k"],[1e6,"M"],[1e9,"B"]];function di(e){for(let[t,n]of Sc){let r=bo(Math.abs(e)/t,1);if(r<1e3||n==="B")return Tc(Math.sign(e)*r,1)+n}return""}var fi=/^[NFP](?:10|[0-9])$/;function hi(e,t){if(!fi.test(t))return null;let n=Number(t.slice(1));return t[0]==="N"?vc(e,n):t[0]==="F"?xc(e,n):kc(e,n)}function go(e){return e===null||e==="compact"||fi.test(e)}var Ac=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13,1e14,1e15];function bo(e,t){if(Math.abs(e)>=1e16)return e;let n=Ac[t];return Oc(e*n)/n}function Oc(e){let t=Math.trunc(e),n=e-t;return Math.abs(n)>=.5?t+Math.sign(n):t}var _c=9223372036854776e3;function mi(e){if(!Number.isFinite(e))return"";if(Number.isInteger(e)&&Math.abs(e)<_c)return e===0?"0":BigInt(e).toString();let t=ci(wc(Ec(e),15),10),[n,r]=pi(t,0);return(e<0?"-":"")+n+(r.length>0?"."+r:"")}function Ec(e){let t=String(Math.abs(e)),n=t.indexOf("e"),r=n<0?t:t.slice(0,n),o=r.indexOf("."),s=o<0?r:r.slice(0,o)+r.slice(o+1),i=(n<0?0:Number(t.slice(n+1)))-(o<0?0:r.length-o-1),a=un(s,i);return a.digits.length<=15?a:ai(e)}var Je=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function vo(e,t){return Object.hasOwn(e,t)?e[t]:null}function bi(e,t,n){t==="__proto__"?Object.defineProperty(e,t,{value:n,enumerable:!0,writable:!0,configurable:!0}):e[t]=n}var Mc=/^[+-]?(?:\d+\.?\d*|\.\d+)(?:[eE][+-]?\d+)?$/,Lc=/^[+-]?(?:\d[\d,]*\.?\d*|\.\d+)(?:[eE][+-]?\d+)?$/,Rc=/^[\t\n\v\f\r ]+|[\t\n\v\f\r ]+$/g,Pc=/\0+$/;function Lt(e,t=!1){let n=e.replace(Pc,"").replace(Rc,"");if(!(t?Lc:Mc).test(n))return null;let r=Number(t?n.replaceAll(",",""):n);return Number.isFinite(r)?r:null}function Y(e){return typeof e=="number"?Number.isFinite(e)?e:null:typeof e=="string"?Lt(e):null}function we(e){return Number.isFinite(e)?e===0?0:e:null}function wi(e){if(typeof e=="boolean")return e;if(typeof e=="number")return Number.isFinite(e)?e!==0:null;if(typeof e=="string")switch(U(e).toLowerCase()){case"true":case"on":case"yes":case"1":return!0;case"false":case"off":case"no":case"0":return!1}return null}function Me(e){if(e===null||e===!1)return!1;switch(typeof e){case"string":return e.length>0;case"number":return Number.isFinite(e)&&e!==0;case"boolean":return!0}if(Array.isArray(e))return e.length>0;for(let t in e)if(Object.hasOwn(e,t))return!0;return!1}function Kn(e){return e===null?!0:typeof e=="string"||Array.isArray(e)?e.length===0:Je(e)&&!Me(e)}function er(e,t){if(typeof e=="number"||typeof t=="number"){let n=Y(e),r=Y(t);if(n!==null&&r!==null)return n===r}return Qn(e,t)}function Qn(e,t){if(e===t)return!0;if(e===null||t===null||typeof e!="object"||typeof t!="object")return!1;if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(!Qn(e[r],t[r]))return!1;return!0}if(Array.isArray(t))return!1;let n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let r of n)if(!Object.hasOwn(t,r)||!Qn(e[r],t[r]))return!1;return!0}function xo(e,t){let n=Y(e),r=Y(t);return n!==null&&r!==null?n<r?-1:n>r?1:0:typeof e=="string"&&typeof t=="string"?e<t?-1:e>t?1:0:null}function V(e){if(e===null)return"";switch(typeof e){case"string":return e;case"number":return mi(e);case"boolean":return e?"true":"false"}if(Array.isArray(e)){let t="";for(let n=0;n<e.length;n++)t+=(n>0?", ":"")+V(e[n]);return t}return yo(e)}var Nc=/[\p{Cc}\p{Co}\p{Cn}\p{Zl}\p{Zp}\uFEFF"\\\p{Cs}]|(?! )\p{Zs}|[\u{10000}-\u{10FFFF}]/gu,$c={'"':'\\"',"\\":"\\\\","\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r"},wo=e=>"\\u"+e.toString(16).toUpperCase().padStart(4,"0");function gi(e){return'"'+e.replace(Nc,t=>$c[t]??(t.length===1?wo(t.charCodeAt(0)):wo(t.charCodeAt(0))+wo(t.charCodeAt(1))))+'"'}function yo(e){if(e===null)return"null";switch(typeof e){case"string":return gi(e);case"number":return Number.isFinite(e)?JSON.stringify(e):"null";case"boolean":return e?"true":"false"}if(Array.isArray(e))return"["+e.map(yo).join(",")+"]";let t="";for(let n of Object.keys(e))t+=(t?",":"")+gi(n)+":"+yo(e[n]);return"{"+t+"}"}function lt(e,t,n){if(typeof e=="string")return Os(e,t,n);if(typeof e!="number"||!Number.isFinite(e)||e<=0)return null;let r=e<253402300799?e*1e3:e;return r>=253402300799e3?null:Math.trunc(r)}var yi=["ok","warn","error","unknown"],ko=new Map;for(let[e,t]of[["ok","ok okay success succeeded successful passed pass green up healthy online on true done complete completed good fine operational"],["warn","warn warning yellow amber orange degraded pending running in_progress in-progress queued waiting slow delayed partial unstable"],["error","error err fail failed failure red down unhealthy offline off false critical broken outage cancelled canceled"],["unknown","unknown"]])for(let n of t.split(" "))ko.set(n,e);function Cc(e){let t=ko.get(e);if(t)return t;let n=rt(e),r=ko.get(n);return r&&Nr(e,n)?r:void 0}function zc(e,t,n){if(e.op==="*"||e.operands.length===1&&e.operands[0]==="*")return e.op!=="!=";if(e.op==="="||e.op==="!="){let s=e.operands.some(i=>Nr(i,n));return e.op==="="?s:!s}let r=Y(t),o=Lt(e.operands[0]);if(r===null||o===null)return!1;switch(e.op){case"<":return r<o;case"<=":return r<=o;case">":return r>o;case">=":return r>=o}return!1}var tr=new Map;function vi(e){let t=tr.get(e);if(t!==void 0)return t;let n=Ic(e);return tr.size>512&&tr.clear(),tr.set(e,n),n}function Ic(e){let t=[];for(let n of e.split(",").map(U).filter(r=>r.length>0)){let r=n.search(/[=<>!]/),o=rt(U(r<0?n:n.slice(0,r)));if(!yi.includes(o))return`"${n}" must start with a state (${yi.join(", ")}), e.g. status:ok=green,warn=yellow.`;if(r<0){t.push({state:o,op:"*",operands:[]});continue}let s=n.slice(r),i=s.startsWith("<=")||s.startsWith(">=")||s.startsWith("!=")?s.slice(0,2):s.slice(0,1);if(i==="!")return`"${n}": use != for "not equal".`;let a=U(s.slice(i.length));if((i==="<"||i==="<="||i===">"||i===">=")&&Lt(a)===null)return`"${n}": ${i} needs a number, e.g. warn<20.`;if(a.length===0)return`"${n}" needs a value after ${i}, e.g. ok=green.`;t.push({state:o,op:i,operands:a.split("/").map(U)})}return t}function nr(e,t){let n=U(V(e));if(t!==null){let r=vi(t);if(typeof r!="string"){for(let o of r)if(zc(o,e,n))return o.state}}return Cc(n)??"unknown"}function xi(e){if(e===null)return null;let t=vi(e);return typeof t=="string"?t:null}var fn=e=>e===void 0?null:e;var To=e=>Y(fn(e)),ki=e=>wi(fn(e)),Ti=(e,t,n)=>lt(fn(e),t,n),Jc=e=>V(fn(e)),Si=e=>rt(U(Jc(e))),Ai=e=>nr(fn(e),null);var Oi=15*6e4,Xd=15*6e4;var So=new Map([["iso","yyyy-MM-dd"],["short","d MMM"],["long","d MMMM yyyy"],["weekday","ddd"],["day","dddd"],["datetime","d MMM HH:mm"],["clock","HH:mm"],["seconds","HH:mm:ss"]]);function Ao(e){return typeof e!="string"||Y(e)!==null?e:Lt(e,!0)??e}var Dc=/^[0-9]+$/,_i=(e,t,n)=>Dc.test(e)&&Number(e)>=t&&Number(e)<=n,Ei=e=>t=>t===null?`needs an argument, e.g. ${e}.`:null;function Vc(e,t){let n=Y(Ao(e));return n===null||!go(t)?null:t===null||t===""?ui(n):t==="compact"?di(n):hi(n,t)}function Bc(e,t){let n=Y(Ao(e));return n===null?null:we(bo(n,t===null?0:Number(t)))}function Mi(e,t,n,r){let o=lt(e,n.relativeTo,n.zone);if(o===null)return null;let s=t===null?r:So.get(t)??t;return zr(s)?Ts(o,n.zone,s):null}function Li(e){return e===null||So.has(e)||zr(e)?null:`"${e}" is not a supported date format. Use a pattern from the tokens yyyy yy MMMM MMM MM M dddd ddd dd d HH H hh h mm m ss s tt (with 'quoted' literals), such as 'HH:mm' or 'd MMM', or one of: ${[...So.keys()].join(", ")}.`}var rr=new Map;function Ri(e){if(e===null||U(e).length===0)return null;let t=rr.get(e);return t!==void 0||(t=Fc(e),rr.size>512&&rr.clear(),rr.set(e,t)),t}function Fc(e){let t=[],n="",r="",o=!1;for(let s=0;s<=e.length;s++){if(s===e.length||e[s]===","){if(!o)return null;t.push([U(n),U(r)]),n=r="",o=!1;continue}let i=e[s],a=e[s+1];if(i==="\\"&&(a==="="||a===","||a==="\\")){o?r+=a:n+=a,s++;continue}if(i==="="&&!o){o=!0;continue}o?r+=i:n+=i}return t}function Uc(e,t){let n=Ri(t);if(n===null)return null;let r=V(e),o=null;for(let[s,i]of n){if(s==="*"){o??(o=i);continue}if(e!==null&&s===r)return i}return o}function Hc(e,t){let n=Number(t);return Array.isArray(e)?e.slice(0,n):typeof e=="string"?gs(e,n):e}var or=new Map([["default",{apply:(e,t)=>Kn(e)?t??"":e}],["upper",{apply:e=>e===null?null:On(V(e))}],["lower",{apply:e=>e===null?null:rt(V(e))}],["prefix",{apply:(e,t)=>Kn(e)?e:t+V(e),validate:Ei("prefix:'text '")}],["suffix",{apply:(e,t)=>Kn(e)?e:V(e)+t,validate:Ei("suffix:' km'")}],["number",{apply:Vc,validate:e=>go(e)?null:`"${e}" is not a supported number format. Use number (default), number:compact, number:N0\u2013N10, number:F0\u2013F10 or number:P0\u2013P10.`}],["round",{apply:Bc,validate:e=>e===null||_i(e,0,10)?null:"round takes a number of decimals from 0 to 10, e.g. round:1."}],["date",{apply:(e,t,n)=>Mi(e,t,n,"yyyy-MM-dd"),validate:Li}],["time",{apply:(e,t,n)=>Mi(e,t,n,"HH:mm"),validate:Li}],["relative",{apply:(e,t,n)=>{let r=lt(e,n.relativeTo,n.zone);return r===null?null:Es(r,n.now,t==="compact"||t==="short")},validate:e=>e===null||e==="compact"||e==="short"?null:'relative takes no argument, or "compact" (e.g. "5 min" instead of "in 5 min").'}],["take",{apply:Hc,validate:e=>e!==null&&_i(e,0,1e3)?null:"take needs a count, e.g. take:3."}],["status",{apply:(e,t)=>nr(Ao(e),t),validate:xi}],["lookup",{apply:Uc,validate:e=>(Ri(e)?.length??0)>0?null:"lookup needs rules such as lookup:METRO=train,BUS=bus,*=train (write a literal = or , as \\= or \\,)."}]]);var Wc=1e4;function H(e,t){switch(e.kind){case"literal":return e.value;case"path":return qc(e.segments,t);case"postfix":return $i(H(e.target,t),e.segments,0);case"array":{let n=new Array(e.items.length);for(let r=0;r<e.items.length;r++)n[r]=H(e.items[r],t);return n}case"unary":{let n=H(e.operand,t);if(e.op==="not")return!Me(n);let r=Y(n);return r===null?null:we(-r)}case"ternary":return Me(H(e.condition,t))?H(e.then,t):H(e.otherwise,t);case"binary":return Gc(e.op,e.left,e.right,t);case"pipeline":{let n=H(e.input,t);for(let r of e.filters)n=Zc(r,n,t);return n}}}function Gc(e,t,n,r){switch(e){case"and":{let l=H(t,r);return Me(l)?H(n,r):l}case"or":{let l=H(t,r);return Me(l)?l:H(n,r)}case"??":return H(t,r)??H(n,r)}let o=H(t,r),s=H(n,r);switch(e){case"~":return V(o)+V(s);case"==":return er(o,s);case"!=":return!er(o,s);case"<":case"<=":case">":case">=":{let l=xo(o,s);return l===null?null:e==="<"?l<0:e==="<="?l<=0:e===">"?l>0:l>=0}case"in":return Pi(o,s);case"not in":return!Pi(o,s)}let i=Y(o),a=Y(s);if(i===null||a===null)return null;switch(e){case"+":return we(i+a);case"-":return we(i-a);case"*":return we(i*a);case"/":return a===0?null:we(i/a);case"%":return a===0?null:we(i%a)}return null}function Pi(e,t){if(Array.isArray(t)){for(let n of t)if(er(e,n))return!0;return!1}return Je(t)?Object.hasOwn(t,V(e)):typeof t=="string"?t.includes(V(e)):!1}function qc(e,t){let n=e[0];if(typeof n!="string")return null;let r;switch(n){case"$root":r=t.root;break;case"$item":r=t.item??null;break;case"$index":return t.index!==void 0&&e.length===1?t.index:null;case"$now":return e.length===1?Yt(t.now):null;case"$secret":{let o=e[1];return e.length!==2||typeof o!="string"||t.secrets===void 0?null:t.secrets(o)??null}default:if(n.charCodeAt(0)===36){let o=n.slice(1);r=o==="params"&&t.params!==void 0?t.params:t.vars!==void 0&&Object.hasOwn(t.vars,o)?t.vars[o]:null}else if(t.item!==void 0&&Je(t.item)&&Object.hasOwn(t.item,n))r=t.item[n];else if(Je(t.root))r=vo(t.root,n);else return null}return $i(r,e,1)}function $i(e,t,n){for(let r=n;r<t.length&&e!==null;r++){let o=t[r];if(typeof o=="string")e=Je(e)?vo(e,o):null;else if(Array.isArray(e)){let s=o.index<0?e.length+o.index:o.index;e=s>=0&&s<e.length?e[s]:null}else e=null}return e}function Zc(e,t,n){try{let r=or.get(e.name);if(r)return r.apply(t,e.argument,n);switch(e.name){case"where":{if(!Array.isArray(t))return null;let o=[];return sr(e,t,n,(s,i)=>{Me(i)&&o.push(s)})?o:null}case"map":{if(!Array.isArray(t))return null;let o=[];return sr(e,t,n,(s,i)=>{o.push(i)})?o:null}case"find":return Array.isArray(t)?Xc(e,t,n):null;case"sortBy":return Array.isArray(t)?Yc(e,t,n):null;case"indexBy":return Array.isArray(t)?Kc(e,t,n):null;case"count":return ep(e,t,n);case"sum":return tp(e,t,n);case"first":return Array.isArray(t)&&t.length>0?t[0]:null;case"last":return Array.isArray(t)&&t.length>0?t[t.length-1]:null;case"join":{if(!Array.isArray(t))return null;let o=e.args.length>0?V(H(e.args[0],n)):", ",s="";for(let i=0;i<t.length;i++)s+=(i>0?o:"")+V(t[i]);return s}case"toNumber":{let o=Y(t);return o===null?null:we(o)}case"toText":return V(t);case"toTime":{let o=lt(t,n.relativeTo,n.zone);return o===null?null:Yt(o)}}return t}catch{return null}}function ji(e){return e.lambdaLimitHit?!1:++e.lambdaEvaluations<=Wc?!0:(e.lambdaLimitHit=!0,!1)}function sr(e,t,n,r){let o=e.args[0],s=n.item,i=n.index;try{for(let a=0;a<t.length;a++){if(!ji(n))return!1;let l=t[a];n.item=l,n.index=a;let c=H(o,n);n.item=s,n.index=i,r(l,c)}}finally{n.item=s,n.index=i}return!n.lambdaLimitHit}function Oo(e,t,n){let r=[];return sr(e,t,n,(o,s)=>{r.push(s)})?r:null}function Xc(e,t,n){let r=null,o=!1,s=e.args[0],i=n.item,a=n.index;try{for(let l=0;l<t.length&&!o;l++){if(!ji(n))return null;n.item=t[l],n.index=l,Me(H(s,n))&&(r=t[l],o=!0)}}finally{n.item=i,n.index=a}return r}function Yc(e,t,n){let r=Oo(e,t,n);if(r===null)return null;let o=e.args.length>1&&V(H(e.args[1],n))==="desc",s=t.map((i,a)=>a);return s.sort((i,a)=>Qc(r[i],r[a],o)||i-a),s.map(i=>t[i])}function Qc(e,t,n){if(e===null||t===null)return e===null?t===null?0:1:-1;let r=xo(e,t);return r===null&&(r=Ni(e)-Ni(t),r===0&&typeof e=="boolean"&&typeof t=="boolean"?r=e===t?0:e?1:-1:r=Math.sign(r)),n?-r:r}var Ni=e=>typeof e=="number"?0:typeof e=="string"?1:typeof e=="boolean"?2:3;function Kc(e,t,n){let r=Oo(e,t,n);if(r===null)return null;let o={};for(let s=0;s<t.length;s++){let i=V(r[s]);Object.hasOwn(o,i)||bi(o,i,t[s])}return o}function ep(e,t,n){if(Array.isArray(t)){if(e.args.length===0)return t.length;let r=0;return sr(e,t,n,(o,s)=>{Me(s)&&r++})?r:null}return Je(t)?Object.keys(t).length:typeof t=="string"?ms(t):null}function tp(e,t,n){if(!Array.isArray(t))return null;let r=e.args.length>0?Oo(e,t,n):t;if(r===null||n.lambdaLimitHit)return null;let o=0;for(let s of r){let i=Y(s);i!==null&&(o+=i)}return we(o)}var ye=e=>({kind:"text",optional:e}),Ci=e=>({kind:"expr",optional:e}),ct=e=>({kind:"lambda",optional:e}),zi={number:[ye(!0)],date:[ye(!0)],time:[ye(!0)],relative:[ye(!0)],upper:[],lower:[],default:[ye(!0)],take:[ye(!1)],status:[ye(!0)],round:[ye(!0)],prefix:[ye(!1)],suffix:[ye(!1)],lookup:[ye(!1)],where:[ct(!1)],map:[ct(!1)],sortBy:[ct(!1),Ci(!0)],find:[ct(!1)],count:[ct(!0)],sum:[ct(!0)],indexBy:[ct(!1)],first:[],last:[],join:[Ci(!0)],toNumber:[],toText:[],toTime:[]},ir=new Map(Object.entries(zi).map(([e,t])=>[e,{name:e,args:t,isText:t.length===0||t[0].kind==="text",requiredCount:t.filter(n=>!n.optional).length}])),Ii=Object.keys(zi);var Ji=4096,Di=32,Vi=64;var _o=e=>e==="_"||e==="$"||e!==""&&kt(e),Eo=e=>e==="_"||e==="$"||e==="-"||e!==""&&fs(e);var pt=(e,t,n)=>e.startsWith(n,t);function Ui(e){if(e.length>Ji)return{template:null,errors:[{position:0,kind:"tooLong",length:e.length,message:`The template is ${e.length} characters long; the limit is ${Ji}.`}]};let t=[],n=[],r="",o=0;for(;o<e.length;){if(e[o]==="\\"&&pt(e,o+1,"{{")){r+="{{",o+=3;continue}if(!pt(e,o,"{{")){let c=o+1;for(;c<e.length&&e[c]!=="{"&&e[c]!=="\\";)c++;r+=e.slice(o,c),o=c;continue}r.length>0&&(t.push(r),r="");let a=new Mo(e,o+2,n),l=a.parseExpression();if(l&&t.push(l),a.unclosed)break;o=a.pos}if(r.length>0&&t.push(r),n.length>0)return n.sort((a,l)=>a.position-l.position),{template:null,errors:n};let s=null,i=0;for(let a of t){if(typeof a=="string"){nt(a)||(i=2);continue}i++,s=a.expr}return{template:{source:e,parts:t,single:i===1?s:null},errors:[]}}var Bi={failed:!0},Mo=class{constructor(t,n,r){I(this,"text");I(this,"errors");I(this,"open");I(this,"pos");I(this,"unclosed",!1);I(this,"depth",0);I(this,"parens",0);I(this,"filterCalls",0);I(this,"hasFailed",!1);this.text=t,this.errors=r,this.open=n-2,this.pos=n}parseExpression(){this.skipSpace();let t=this.pos;if(this.atEnd())return this.unclosedAt();if(this.atClose())return this.error(this.open,"syntax","Empty expression: put a data path inside {{ }}, e.g. {{ source.field }}.",4),this.pos+=2,null;let n;try{if(n=this.parsePipeline(),this.skipSpace(),this.atEnd())return this.unclosedAt();this.atClose()||this.fail(this.pos,this.peek()==="}"?`Expected "}}" to close the expression at position ${this.pos}.`:`Unexpected "${this.peek()}" at position ${this.pos}: expected "|" followed by a filter, or "}}".`)}catch(o){if(o!==Bi)throw o;return this.recover(),null}let r=U(this.text.slice(t,this.pos));return this.pos+=2,{expr:n,text:r,position:t}}parsePipeline(){this.enter();let t=this.parseExpr(),n=[];for(;this.skipSpace(),this.peek()==="|";)this.pos++,n.push(this.parseFilter());return this.leave(),n.length===0?t:{kind:"pipeline",input:t,filters:n,position:t.position}}parseExpr(){this.enter();let t=this.parseCoalesce();if(this.skipSpace(),this.peek()==="?"&&this.peekAt(1)!=="?"){this.pos++;let n=this.parseExpr();this.skipSpace(),this.peek()!==":"&&this.fail(this.pos,`Expected ":" at position ${this.pos} to complete "condition ? a : b".`),this.pos++;let r=this.parseExpr();t={kind:"ternary",condition:t,then:n,otherwise:r,position:t.position}}return this.leave(),t}parseCoalesce(){let t=this.parseOr();for(;this.skipSpaceThen("??");)this.pos+=2,t={kind:"binary",op:"??",left:t,right:this.parseOr(),position:t.position};return t}parseOr(){let t=this.parseAnd();for(;this.skipSpaceThenKeyword("or");)this.pos+=2,t={kind:"binary",op:"or",left:t,right:this.parseAnd(),position:t.position};return t}parseAnd(){let t=this.parseNot();for(;this.skipSpaceThenKeyword("and");)this.pos+=3,t={kind:"binary",op:"and",left:t,right:this.parseNot(),position:t.position};return t}parseNot(){if(this.skipSpaceThenKeyword("not")){let t=this.pos;this.pos+=3,this.enter();let n=this.parseNot();return this.leave(),{kind:"unary",op:"not",operand:n,position:t}}return this.parseComparison()}parseComparison(){let t=this.parseConcat(),n=this.readComparisonOperator(!1);if(n===null)return t;let r=this.parseConcat(),o={kind:"binary",op:n,left:t,right:r,position:t.position},s=this.readComparisonOperator(!0);return s!==null&&this.fail(this.pos,`Comparisons cannot be chained ("a < b < c"); combine them with "and". Found "${s}" at position ${this.pos}.`),o}readComparisonOperator(t){this.skipSpace();let n=null,r=0;for(let s of["==","!=","<=",">="])pt(this.text,this.pos,s)&&(n=s,r=2);let o=this.peek();if(n===null&&(o==="<"||o===">")&&(n=o,r=1),n===null&&this.isKeywordAt(this.pos,"in")&&(n="in",r=2),n===null&&this.isKeywordAt(this.pos,"not")){let s=this.pos+3;for(;s<this.text.length&&tt(this.text.charCodeAt(s));)s++;this.isKeywordAt(s,"in")&&(n="not in",r=s+2-this.pos)}return n!==null&&!t&&(this.pos+=r),n}parseConcat(){let t=this.parseAdditive();for(;this.skipSpaceThen("~");)this.pos++,t={kind:"binary",op:"~",left:t,right:this.parseAdditive(),position:t.position};return t}parseAdditive(){let t=this.parseMultiplicative();for(;;){this.skipSpace();let n=this.peek();if(n!=="+"&&n!=="-")return t;this.pos++,t={kind:"binary",op:n,left:t,right:this.parseMultiplicative(),position:t.position}}}parseMultiplicative(){let t=this.parseUnary();for(;;){this.skipSpace();let n=this.peek();if(n!=="*"&&n!=="/"&&n!=="%")return t;this.pos++,t={kind:"binary",op:n,left:t,right:this.parseUnary(),position:t.position}}}parseUnary(){if(this.skipSpace(),this.peek()!=="-")return this.parsePostfix();let t=this.pos++;this.enter();let n=this.parseUnary();return this.leave(),n.kind==="literal"&&typeof n.value=="number"?{kind:"literal",value:-n.value,position:t}:{kind:"unary",op:"-",operand:n,position:t}}parsePostfix(){this.skipSpace();let t=this.pos,n=this.peek();if(this.atEnd())throw this.unclosedFailure();if(n==="("){this.pos++,this.parens++;let s=this.parsePipeline();if(this.skipSpace(),this.atEnd())throw this.unclosedFailure();return this.peek()!==")"&&this.fail(this.pos,`Expected ")" at position ${this.pos} to close the "(" at position ${t}.`),this.pos++,this.parens--,this.withSegments(s,t)}if(n==="["){this.pos++;let s=[];if(this.skipSpace(),this.peek()!=="]")for(;;){if(s.push(this.parseExpr()),this.skipSpace(),this.peek()===","){this.pos++;continue}if(this.peek()==="]")break;if(this.atEnd())throw this.unclosedFailure();this.fail(this.pos,`Expected "," or "]" at position ${this.pos} in the array starting at position ${t}.`)}return this.pos++,this.withSegments({kind:"array",items:s,position:t},t)}if(n==="'"||n==='"')return this.withSegments({kind:"literal",value:this.readString(),position:t},t);if(je(n))return this.withSegments(this.readNumber(),t);_o(n)||this.fail(this.pos,`Expected a data path or a literal at position ${this.pos}, found "${n}". Example: {{ source.field }}.`);let r=this.readName();switch(r){case"true":case"false":return this.withSegments({kind:"literal",value:r==="true",position:t},t);case"null":return this.withSegments({kind:"literal",value:null,position:t},t);case"and":case"or":case"not":case"in":this.fail(t,`"${r}" is a keyword and cannot start a path (position ${t}). Use $item.${r} or ['${r}'].`)}let o=[r];return this.readSegments(o,t),{kind:"path",segments:o,position:t}}withSegments(t,n){let r=[];return this.readSegments(r,n),r.length===0?t:{kind:"postfix",target:t,segments:r,position:n}}readSegments(t,n){for(;;){let r=this.peek();if(r==="."){this.pos++,_o(this.peek())||this.fail(this.pos,`Invalid path "${this.snippet(n)}": expected a field name after "." at position ${this.pos}.`),t.push(this.readName());continue}if(r!=="[")return;let o=this.pos++;if(this.skipSpace(),this.peek()==="'"||this.peek()==='"')t.push(this.readString());else{let s=this.pos;for(this.peek()==="-"&&this.pos++;je(this.peek());)this.pos++;let i=this.text.slice(s,this.pos),a=Number(i);(i===""||i==="-"||!Number.isInteger(a)||a>2147483647||a<-2147483648)&&this.fail(o,`Invalid index in "${this.snippet(n)}" at position ${o}: use a whole number such as [0] or [-1], or a quoted key such as ['name'].`),t.push({index:a===0?0:a})}this.skipSpace(),this.peek()!=="]"&&this.fail(this.pos,`Expected "]" at position ${this.pos} in "${this.snippet(n)}".`),this.pos++}}parseFilter(){this.skipSpace();let t=this.pos;_o(this.peek())||this.fail(this.pos,`Expected a filter name after "|" at position ${this.pos}. Allowed: ${Fi()}.`);let n=this.readName();if(++this.filterCalls>Vi)throw this.error(t,"tooLong",`More than ${Vi} filter calls in one expression.`,n.length),this.markFailed();this.skipSpace();let r=ir.get(n);if(!r)throw this.error(t,"unknownFilter",`Unknown filter "${n}" at position ${t}. Allowed: ${Fi()}.`,n.length,n),this.markFailed();if(r.isText){let i=null,a=this.pos;this.peek()===":"&&(this.pos++,this.skipSpace(),a=this.pos,i=this.peek()==="'"||this.peek()==='"'?this.readString():this.readBareArgument()),r.args.length===0&&i!==null&&this.invalidArgument(n,a,`Filter "${n}" at position ${t} takes no argument.`);let l=or.get(n)?.validate?.(i)??null;return l!==null&&this.invalidArgument(n,a,`Filter "${n}" at position ${t}: ${l}`),{name:n,argument:i,args:[],position:t}}let o=[],s=this.pos;if(this.peek()===":")for(this.pos++,s=this.pos;o.push(this.parseExpr()),this.skipSpace(),this.peek()===",";)this.pos++;return o.length<r.requiredCount&&this.invalidArgument(n,s,`Filter "${n}" at position ${t} needs an argument, e.g. ${np(n)}.`),o.length>r.args.length&&this.invalidArgument(n,s,`Filter "${n}" at position ${t} takes at most ${r.args.length} argument(s).`),{name:n,argument:null,args:o,position:t}}invalidArgument(t,n,r){throw this.error(n,"invalidArgument",r,Math.max(1,this.pos-n),t),this.markFailed()}readBareArgument(){let t=this.pos;for(;!this.atEnd()&&!this.atClose()&&this.peek()!=="|"&&!(this.parens>0&&this.peek()===")");)this.pos++;return U(this.text.slice(t,this.pos))}readString(){let t=this.text[this.pos],n=this.pos++,r="";for(;!this.atEnd();){let o=this.text[this.pos++];if(o===t)return r;if(o==="\\"&&!this.atEnd()){let s=this.text[this.pos++];r+=s==="n"?`
3
+ `:s==="t"?" ":s;continue}r+=o}return this.unclosed=!0,this.fail(n,`Unterminated string starting at position ${n}: add a closing ${t}.`)}readNumber(){let t=this.pos;for(;je(this.peek());)this.pos++;if(this.peek()==="."&&je(this.peekAt(1)))for(this.pos++;je(this.peek());)this.pos++;let n=this.peek();if((n==="e"||n==="E")&&(je(this.peekAt(1))||(this.peekAt(1)==="+"||this.peekAt(1)==="-")&&je(this.peekAt(2))))for(this.pos+=2;je(this.peek());)this.pos++;let r=Number(this.text.slice(t,this.pos));return Number.isFinite(r)||this.fail(t,`Invalid number "${this.text.slice(t,this.pos)}" at position ${t}.`),{kind:"literal",value:r,position:t}}readName(){let t=this.pos++;for(;Eo(this.peek());)this.pos++;return this.text.slice(t,this.pos)}isKeywordAt(t,n){let r=this.text;return pt(r,t,n)&&!(t+n.length<r.length&&Eo(r[t+n.length]))&&!(t>0&&Eo(r[t-1]))}skipSpaceThen(t){return this.skipSpace(),pt(this.text,this.pos,t)}skipSpaceThenKeyword(t){return this.skipSpace(),this.isKeywordAt(this.pos,t)}enter(){if(++this.depth>Di)throw this.error(this.pos,"tooDeep",`The expression is nested more than ${Di} levels deep at position ${this.pos}.`),this.markFailed()}leave(){this.depth--}unclosedAt(){return this.hasFailed||this.error(this.open,"syntax",`Unclosed "{{" at position ${this.open}: add a matching "}}".`,2),this.unclosed=!0,this.pos=this.text.length,null}unclosedFailure(){return this.unclosedAt(),this.markFailed()}recover(){if(this.unclosed){this.pos=this.text.length;return}let t=this.text.indexOf("}}",Math.min(this.pos,this.text.length));if(t<0){this.unclosed=!0,this.pos=this.text.length;return}this.pos=t+2}markFailed(){return this.hasFailed=!0,Bi}error(t,n,r,o=1,s){this.errors.push(s===void 0?{position:t,kind:n,length:o,message:r}:{position:t,kind:n,length:o,message:r,filter:s})}fail(t,n){throw this.hasFailed||this.error(t,"syntax",n),this.markFailed()}snippet(t){let n=t,r=this.text;for(;n<r.length&&!pt(r,n,"}}")&&r[n]!=="|"&&!tt(r.charCodeAt(n));)n++;return r.slice(t,n)}skipSpace(){for(;this.pos<this.text.length&&tt(this.text.charCodeAt(this.pos));)this.pos++}atEnd(){return this.pos>=this.text.length}atClose(){return pt(this.text,this.pos,"}}")}peek(){return this.pos<this.text.length?this.text[this.pos]:""}peekAt(t){let n=this.pos+t;return n>=0&&n<this.text.length?this.text[n]:""}},Fi=()=>[...Ii].sort().join(", ");function np(e){switch(e){case"where":return"where: price > 10";case"map":return"map: name";case"sortBy":return"sortBy: expected";case"find":return"find: id == 3";case"indexBy":return"indexBy: entity_id";default:return e+": x"}}var rp=new Set(["$item","$index","$now","$params","$secret","$response"]);function Wi(e,t,n,r){let o=[];for(let s of e.parts)typeof s!="string"&&ve(s.expr,t,n,r,o);return o}function ve(e,t,n,r,o){switch(e.kind){case"path":{let s=op(e.segments,t,n,r);s&&o.push(s);break}case"postfix":ve(e.target,t,n,r,o);break;case"array":for(let s of e.items)ve(s,t,n,r,o);break;case"unary":ve(e.operand,t,n,r,o);break;case"binary":ve(e.left,t,n,r,o),ve(e.right,t,n,r,o);break;case"ternary":ve(e.condition,t,n,r,o),ve(e.then,t,n,r,o),ve(e.otherwise,t,n,r,o);break;case"pipeline":ve(e.input,t,n,r,o);for(let s of e.filters){let i=ir.get(s.name);s.args.forEach((a,l)=>{let c=i!==void 0&&l<i.args.length&&i.args[l].kind==="lambda";ve(a,c||t,n,c?void 0:r,o)})}break}}function op(e,t,n,r){let o=e[0];return typeof o!="string"?null:o==="$root"?typeof e[1]=="string"?{source:e[1],key:Hi(e,2)}:null:rp.has(o)||o.startsWith("$")||t&&!(n(o)&&!(r!==void 0&&Je(r)&&Object.hasOwn(r,o)))?null:{source:o,key:Hi(e,1)}}var Hi=(e,t)=>{let n=e[t];return typeof n=="string"?n:null};function Gi(e){for(let t of e.parts)if(typeof t!="string"&&xe(t.expr))return!0;return!1}function xe(e){switch(e.kind){case"literal":return!1;case"path":return e.segments[0]==="$now";case"postfix":return xe(e.target);case"array":return e.items.some(xe);case"unary":return xe(e.operand);case"binary":return xe(e.left)||xe(e.right);case"ternary":return xe(e.condition)||xe(e.then)||xe(e.otherwise);case"pipeline":return xe(e.input)||e.filters.some(t=>t.name==="relative"||t.args.some(xe))}}var lr="Europe/Stockholm",sp=4096,ar=new Map;function hn(e){let t=ar.get(e);return t===void 0&&(ar.size>=sp&&ar.clear(),t=Ui(e),ar.set(e,t)),t}function qi(e){return hn(e).template}function Zi(e){return{root:e.root??null,now:e.now,relativeTo:e.dataTime??e.now,zone:e.timeZone??lr,item:e.item,index:e.index,params:e.params,vars:e.vars,secrets:e.secrets,lambdaEvaluations:0,lambdaLimitHit:!1}}function Xi(e,t){let n=e.parts;if(n.length===1&&typeof n[0]=="string")return n[0];let r="";for(let o of n)r+=typeof o=="string"?o:V(H(o.expr,t));return r}function oe(e,t){if(!e)return"";let n=hn(e).template;return n===null?"":Xi(n,Zi(t))}function We(e,t){if(!e)return null;let n=hn(e).template;if(n===null)return null;let r=Zi(t);return n.single!==null?H(n.single,r):Xi(n,r)}function Lo(e,t){if(nt(e))return null;let n=U(e);return We(n.startsWith("{{")?n:`{{ ${n} }}`,t)}function Yi(e){let t=hn(e);return t.readsClock===void 0&&(t.readsClock=t.template!==null&&Gi(t.template)),t.readsClock}function ip(e,t,n,r){let o=hn(e).template;return o===null?[]:Wi(o,t,n,r)}function Rt(e,t,n,r){return[...new Set(ip(e,t,n,r).map(o=>o.source))]}var Qi=1,Ro=1,Pt=class extends Error{},Le=e=>typeof e=="object"&&e!==null&&!Array.isArray(e),K=e=>typeof e=="string"?e:void 0,cr=(e,t)=>typeof e=="number"&&Number.isInteger(e)?e:t;function pr(e,t){let n=e[t];if(typeof n!="string")throw new Pt(`Bundle does not match schema/bundle.schema.json: "${t}" is required.`);return n}function Ki(e,t){let n={};if(Le(e))for(let[r,o]of Object.entries(e))Le(o)&&(n[r]=t(o));return n}function mn(e,t){for(let[n,r]of Object.entries(t))r!==void 0&&(e[n]=r);return e}function ea(e){let t=cr(e.bundleVersion,Qi);if(t!==Qi)throw new Pt(`Unsupported bundleVersion ${t}.`);let n=cr(e.engine,Ro);if(n>Ro)throw new Pt(`The bundle needs engine ${n}; this build has ${Ro}.`);let r=e.entry,o=e.tile;if(!Le(r)||!Le(o)||!Le(e.pages))throw new Pt("Bundle does not match schema/bundle.schema.json: entry, pages and tile are required.");let s={};for(let[a,l]of Object.entries(e.pages))Le(l)&&(s[a]=l);let i={bundleVersion:t,schemaVersion:cr(e.schemaVersion,2),engine:n,experienceId:pr(e,"experienceId"),localId:pr(e,"localId"),version:cr(e.version,1),timeZone:K(e.timeZone)??lr,entry:mn({title:pr(r,"title")},{subtitle:K(r.subtitle),icon:K(r.icon),iconUrl:K(r.iconUrl),description:K(r.description)}),main:pr(e,"main"),pages:s,tile:o,sources:Ki(e.sources,a=>mn({mode:K(a.mode)??"proxied",ref:K(a.ref)??"",raw:a},{refresh:Le(a.refresh)?a.refresh:void 0,push:K(a.push)})),actions:Ki(e.actions,a=>{let l=a.toast,c=a.refresh;return mn({kind:K(a.kind)??"http"},{mode:K(a.mode),source:K(a.source),screen:K(a.screen),confirm:K(a.confirm),toast:Le(l)?mn({},{success:K(l.success),failure:K(l.failure)}):void 0,refresh:Array.isArray(c)?c.filter(p=>typeof p=="string"):void 0})})};return mn(i,{projectId:K(e.projectId),publishedAt:K(e.publishedAt),complication:Le(e.complication)?e.complication:void 0,sample:Le(e.sample)?e.sample:void 0})}var ta=new Set(["add","alarm","arrow-down","arrow-up","battery","bell","bike","bolt","build","bus","calendar","car","check","chevron-right","clock","close","cloud","code","door","error","fan","flag","git","heart","home","info","light","lock","mail","map-pin","music","pause","phone","play","plug","power","rain","refresh","remove","robot","rocket","settings","ship","snow","star","stop","sun","temp","thermometer","timer","train","tram","unlock","user","walk","warning","wifi","wind"]),ut={screenListMaxRows:10,textMaxLines:3,tileListMaxRows:3,tileCompactListMaxRows:8,tileMaxButtons:2};function Nt(e){if(!e)return!1;try{let t=new URL(e);return(t.protocol==="https:"||t.protocol==="http:")&&t.hostname.length>0}catch{return!1}}var bn=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function ee(e){for(let t of Object.keys(e))e[t]===void 0&&delete e[t];return e}function ap(e){if(Number.isInteger(e)&&Math.abs(e)<1e15)return String(e);let[t="",n="0"]=e.toExponential().split("e"),r=Number(n);return r<15&&r>=-5?String(e):`${t}E${r<0?"-":"+"}${String(Math.abs(r)).padStart(2,"0")}`}function k(e){if(typeof e=="string")return e;if(typeof e=="boolean")return e?"true":"false";if(typeof e=="number")return Number.isFinite(e)?ap(e):void 0}var Po=e=>typeof e=="number"&&Number.isInteger(e)&&Math.abs(e)<=2147483647?e:void 0,lp=e=>typeof e=="boolean"?e:void 0;function gn(e){if(!bn(e))return;let t=e,n=k(t.id),r=typeof t.type=="string"?t.type:void 0;switch(r){case"text":return ee({type:r,id:n,value:k(t.value),style:k(t.style),maxLines:Po(t.maxLines)});case"stat":return ee({type:r,id:n,value:k(t.value),unit:k(t.unit),label:k(t.label),trend:k(t.trend),icon:k(t.icon)});case"list":return ee({type:r,id:n,items:ra(t.items),item:oa(t.item),maxRows:Po(t.maxRows),header:k(t.header),emptyText:k(t.emptyText)});case"status":return ee({type:r,id:n,state:k(t.state),label:k(t.label),detail:k(t.detail)});case"progress":return ee({type:r,id:n,value:k(t.value),min:k(t.min),max:k(t.max),style:k(t.style),label:k(t.label)});case"countdown":return ee({type:r,id:n,target:k(t.target),format:k(t.format),label:k(t.label)});case"button":return ee({type:r,id:n,label:k(t.label),icon:k(t.icon),action:k(t.action),confirm:lp(t.confirm),style:k(t.style)});case"toggle":return ee({type:r,id:n,label:k(t.label),state:k(t.state),onAction:k(t.onAction),offAction:k(t.offAction),icon:k(t.icon)});case"icon":return ee({type:r,id:n,icon:k(t.icon),url:k(t.url),size:k(t.size)});case"stack":{let o=t.children;return ee({type:r,id:n,direction:k(t.direction),header:k(t.header),children:Array.isArray(o)?o.map(gn):[]})}default:return ee({type:"unknown",id:n,typeName:r})}}function na(e){return bn(e)?ee({title:k(e.title),root:gn(e.root)}):void 0}function No(e,t,n){let r=e.buttons;return ee({surface:t,opens:k(e.opens)??n,template:k(e.template),kind:k(e.kind),title:k(e.title),icon:k(e.icon),url:k(e.url),text:sa(e.text),value:k(e.value),unit:k(e.unit),label:k(e.label),detail:k(e.detail),trend:k(e.trend),state:k(e.state),min:k(e.min),max:k(e.max),items:ra(e.items),item:oa(e.item),emptyText:k(e.emptyText),buttons:Array.isArray(r)?r.map(gn):void 0,toggle:gn(e.toggle)})}function ra(e){return typeof e=="string"?{bind:e}:bn(e)?ee({bind:k(e.bind),take:Po(e.take)}):void 0}function oa(e){if(bn(e))return ee({title:k(e.title),subtitle:k(e.subtitle),trailing:sa(e.trailing),badge:k(e.badge),icon:k(e.icon),action:k(e.action)})}function sa(e){if(e!=null){if(bn(e))return ee({component:gn(e)});if(!Array.isArray(e))return ee({text:k(e)})}}function O(e){let t={};for(let[n,r]of Object.entries(e))r!==void 0&&(t[n]=r);return t}function $t(e){let{type:t,...n}=e;return n}var dt=(e,t=2)=>String(e).padStart(t,"0");function ft(e){let t=new Date(e),n=`${dt(t.getUTCFullYear(),4)}-${dt(t.getUTCMonth()+1)}-${dt(t.getUTCDate())}T${dt(t.getUTCHours())}:${dt(t.getUTCMinutes())}:${dt(t.getUTCSeconds())}`,r=t.getUTCMilliseconds();return r===0?`${n}Z`:`${n}.${dt(r,3)}Z`}function ht(e,t,n){if(e===void 0||/^\s*[+-]?\d+\s*$/.test(e))return n;let r=e.replace(/-/g,"").trim().toLowerCase();return t.find(o=>o.replace(/-/g,"").toLowerCase()===r)??n}function ia(e){let t=2166136261;for(let n=0;n<e.length;n++)t=Math.imul(t^e.charCodeAt(n),16777619)>>>0;return t.toString(16).padStart(8,"0")}var aa="No items",cp="Are you sure?",ur=e=>typeof e=="object"&&e!==null&&!Array.isArray(e),$o=(e,t,n)=>Math.min(Math.max(e,t),n),ca=e=>{let t=e.trim();return t.startsWith("{{")?t:`{{ ${t} }}`},dr=class{constructor(t,n,r,o,s,i){I(this,"sources",new Map);I(this,"scope");I(this,"touched",new Set);I(this,"replaceBlocked",!1);I(this,"bundle");I(this,"now");I(this,"options");I(this,"isSource",t=>this.sources.has(t));this.bundle=t,this.now=o,this.options=i;for(let a of new Set([...Object.keys(t.sources),...Object.keys(r)])){let l=n.get(a),c=l?.state??"sample",p=l?.fetchedAt??(c==="loading"?void 0:c==="stale"||c==="error"?o-i.fallbackStaleAge:o);this.sources.set(a,O({name:a,state:c,lastUpdated:p,message:c==="error"?l?.message??`Couldn't load ${a}`:void 0}))}this.scope=O({root:this.effectiveRoot(r),now:o,timeZone:s,dataTime:i.dataTime,vars:i.vars})}effectiveRoot(t){if([...this.sources.values()].map(o=>o.state).every(o=>o==="sample"||o==="live"||o==="stale"))return t;let r={};for(let[o,s]of Object.entries(t)){let i=this.sources.get(o)?.state;i==="loading"||i==="error"||(r[o]=i==="empty"?up(s):s)}return r}screens(){let t=[];for(let[n,r]of Object.entries(this.bundle.pages)){let o=na(r);if(!o)continue;this.beginSurface(!0),this.track([[o.title,!1]]);let s=this.renderOrNull(o.title),i=o.root?this.node(o.root,`$.screens.${n}.root`):void 0;t.push(O({id:n,title:s,root:i,data:this.aggregate()}))}return t}tile(){let t=No(this.bundle.tile,"tile",this.bundle.main);return this.glance(`${this.bundle.localId}.tile`,t)}complication(){let t=this.bundle.complication;if(t)return this.glance(`${this.bundle.localId}.complication`,No(t,"complication",this.bundle.main))}node(t,n,r=!1){if(t.type==="unknown")return O({type:"unsupported",id:t.id,component:t.typeName??""});let o=t.type==="list"?this.firstItem(t.items):void 0,s=this.track(wn(t,r),o);if(this.replaceBlocked){let i=this.blocking(s);if(i)return i.state==="error"?O({type:"error",id:t.id,component:t.type,message:i.message??"",source:i.name}):O({type:"placeholder",id:t.id,component:t.type,rows:t.type==="list"?$o(t.maxRows??t.items?.take??3,1,3):1})}switch(t.type){case"text":return O({type:"text",id:t.id,value:oe(t.value,this.scope),style:ht(t.style,pp,"body"),maxLines:$o(t.maxLines??ut.textMaxLines,1,ut.textMaxLines)});case"stat":return this.stat(t);case"list":return this.list(t,n);case"status":return this.status(t);case"progress":return this.progress(t);case"countdown":return O({type:"countdown",id:t.id,target:this.timestamp(t.target),format:ht(t.format,["relative","clock"],"relative"),label:this.renderOrNull(t.label)});case"button":return this.button(t);case"toggle":return this.toggle(t,n);case"icon":{let i=this.icon(t.icon,t.url);return O({type:"icon",id:t.id,icon:i?.name,imageUrl:i?.url,size:ht(t.size,["medium","small","large"],"medium")})}case"stack":return this.stack(t,n)}}stat(t){return O({type:"stat",id:t.id,value:oe(t.value,this.scope),unit:this.renderOrNull(t.unit),label:this.renderOrNull(t.label),trend:t.trend===void 0?"none":dp(We(t.trend,this.scope)),icon:this.icon(t.icon,void 0)?.name})}list(t,n){let r=this.items(t.items),o=ut.screenListMaxRows,s=Math.min(t.items?.take??Number.MAX_SAFE_INTEGER,t.maxRows??o,o);return O({type:"list",id:t.id,header:this.renderOrNull(t.header),items:this.rows(t.item,r,s,n),totalCount:r.length,maxRows:Math.max(s,0),emptyText:this.renderOrNull(t.emptyText)??aa})}rows(t,n,r,o){let s=[];if(!t)return s;let i=this.scope;try{for(let a=0;a<Math.min(r,n.length);a++){this.scope={...i,item:n[a]??null,index:a};let l=`${o}.items[${a}]`,c=oe(t.title,this.scope),p=this.renderOrNull(t.subtitle),d=t.trailing?this.trailing(t.trailing,`${l}.trailing`):void 0,m=this.renderOrNull(t.badge),b=this.icon(t.icon,void 0)?.name,g=this.action(t.action);s.push(O({title:c,subtitle:p,trailing:d,badge:m,icon:b,action:g&&{...g,item:a}}))}}finally{this.scope=i}return s}trailing(t,n){if(t.component)return this.node(t.component,n,!0);let r=oe(t.text,this.scope);return r===""?void 0:{type:"text",value:r,style:"caption",maxLines:1}}firstItem(t){if(t?.bind===void 0)return;let n=Lo(t.bind,this.scope);if(Array.isArray(n))return n[0];if(ur(n))for(let r in n)return n[r]}items(t){if(t?.bind===void 0)return[];let n=Lo(t.bind,this.scope);return Array.isArray(n)?n:ur(n)?Object.values(n):[]}status(t){return O({type:"status",id:t.id,state:Ai(We(t.state,this.scope)),label:this.renderOrNull(t.label),detail:this.renderOrNull(t.detail)})}progress(t,n){let r=this.number(t.min)??0,o=this.number(t.max)??100;return o<=r&&(o=r+100),O({type:"progress",id:t.id,value:$o(this.number(t.value)??r,r,o),min:r,max:o,style:n??ht(t.style,["ring","bar"],"ring"),label:this.renderOrNull(t.label)})}button(t){return O({type:"button",id:t.id,label:oe(t.label,this.scope),icon:this.icon(t.icon,void 0)?.name,style:ht(t.style,["primary","secondary"],"primary"),action:this.action(t.action,t.confirm)})}toggle(t,n){let r=t.state?.includes("{{")?"state:"+t.state.replace(/\s/g,""):void 0,o=this.options.toggleStates,s=ia(r??`path:${n}`),i=jo(o,n)??(r!==void 0?jo(o,r):void 0)??jo(o,s),a=oe(t.label,this.scope),l=i??ki(We(t.state,this.scope))===!0,c=this.icon(t.icon,void 0)?.name,p=this.action(t.onAction),d=this.action(t.offAction);return O({type:"toggle",id:t.id,label:a,on:l,key:s,icon:c,onAction:p&&{...p,targetState:"on"},offAction:d&&{...d,targetState:"off"}})}stack(t,n){let r=[];t.children.forEach((s,i)=>{s&&r.push(this.node(s,`${n}.children[${i}]`))});let o=r[0];return r.length>=2&&o?.type==="error"&&r.every(s=>s.type==="error"&&s.source===o.source)?O({...o,id:t.id,component:t.type}):O({type:"stack",id:t.id,direction:ht(t.direction,["vertical","horizontal"],"vertical"),header:this.renderOrNull(t.header),children:r})}glance(t,n){this.beginSurface(!1),this.track(fp(n),this.firstItem(n.items));let r=`$.glances.${t}`,o=this.renderOrNull(n.title),s=this.icon(n.icon,n.kind==="image"?n.url:void 0),i=c=>O({id:t,template:c,opens:n.opens,title:o,icon:s?.name}),a;if(n.surface==="tile")switch(n.template){case"text":a={...i("text"),text:this.contentSlot(n.text,`${r}.text`)};break;case"single-stat":a={...i("single-stat"),stat:$t(this.stat(O({value:n.value,unit:n.unit,label:n.label,trend:n.trend})))};break;case"list3":case"compact-list":{let c=this.items(n.items),p=n.template==="list3"?ut.tileListMaxRows:ut.tileCompactListMaxRows,d=Math.min(n.items?.take??p,p);a={...i(n.template),items:this.rows(n.item,c,d,r),totalCount:c.length,emptyText:this.renderOrNull(n.emptyText)??aa};break}case"status":a={...i("status"),status:$t(this.status({state:n.state,label:n.label,detail:n.detail}))};break;case"progress-ring":a={...i("progress-ring"),progress:$t(this.progress(O({value:n.value,min:n.min,max:n.max,label:n.label}),"ring"))};break;case"buttons2":{let c=(n.buttons??[]).slice(0,ut.tileMaxButtons).flatMap(p=>p?.type==="button"?[$t(this.button(p))]:[]);a={...i("buttons2"),buttons:c};break}case"toggle":{let c=n.toggle?.type==="toggle"?n.toggle:{};a={...i("toggle"),toggle:$t(this.toggle(c,`${r}.toggle`))};break}}else if(n.kind==="shortText"||n.kind==="longText")a=O({id:t,kind:n.kind,opens:n.opens,text:this.contentSlot(n.text,`${r}.text`),title:o,icon:s?.name,imageUrl:s?.url});else if(n.kind==="rangedValue"){let c=this.progress(O({value:n.value,min:n.min,max:n.max}));a=O({id:t,kind:"rangedValue",opens:n.opens,text:n.text?this.contentSlot(n.text,`${r}.text`):void 0,title:o,icon:s?.name,imageUrl:s?.url,value:c.value,min:c.min,max:c.max})}else n.kind==="image"&&(a=O({id:t,kind:"image",opens:n.opens,icon:s?.name,imageUrl:s?.url}));if(!a)return;let l=this.aggregate();return l?{...a,data:l}:a}contentSlot(t,n){return t?.component?this.node(t.component,n):{type:"text",value:oe(t?.text,this.scope),style:"body",maxLines:3}}icon(t,n){let r=this.renderOrNull(t)?.trim();r!==void 0&&!ta.has(r)&&(r=void 0);let o=this.renderOrNull(n)?.trim();return o!==void 0&&!Nt(o)&&(o=void 0),r===void 0&&o===void 0?void 0:O({name:r,url:o})}action(t,n){if(t===void 0||!Object.hasOwn(this.bundle.actions,t))return;let r=this.bundle.actions[t],o=r.kind==="refreshSource"||r.kind==="openScreen"||r.kind==="connector"?r.kind:"http",s=n===!1||n===void 0&&r.confirm===void 0?void 0:this.renderBlank(r.confirm)??cp,i=r.toast?O({success:this.renderBlank(r.toast.success),failure:this.renderBlank(r.toast.failure)}):void 0,a=this.scope.item;return O({id:t,kind:o,screen:o==="openScreen"?r.screen:void 0,confirm:s,mode:o==="http"?r.mode??"proxied":void 0,context:a??void 0,toast:i&&(i.success!==void 0||i.failure!==void 0)?i:void 0})}timestamp(t){let n=Ti(We(t,this.scope),this.scope.dataTime??this.now,this.scope.timeZone);return n===null?void 0:ft(n)}number(t){return t===void 0?null:To(We(t,this.scope))}renderOrNull(t){if(t===void 0)return;let n=oe(t,this.scope);return n===""?void 0:n}renderBlank(t){if(t===void 0)return;let n=oe(t,this.scope);return n.trim()===""?void 0:n}beginSurface(t){this.touched.clear(),this.replaceBlocked=t}track(t,n){let r=[];for(let[o,s]of t)if(!(!o||!o.includes("{{")))for(let i of Rt(o,s,this.isSource,n))this.sources.has(i)&&!r.includes(i)&&r.push(i);for(let o of r)this.touched.add(o);return r}blocking(t){let n=t.map(r=>this.sources.get(r)).filter(r=>r.state==="error"||r.state==="loading");return n.find(r=>r.state==="error")??n[0]}aggregate(){let t=[...this.sources.values()].filter(o=>this.touched.has(o.name));if(t.length===0)return;let n=t[0];for(let o of t)la[o.state]>la[n.state]&&(n=o);let r=t.flatMap(o=>o.lastUpdated===void 0?[]:[o.lastUpdated]);return O({state:n.state,lastUpdated:r.length?ft(Math.min(...r)):void 0,message:t.find(o=>o.state==="error")?.message,sources:t.map(o=>o.name)})}},pp=["body","title","caption","display"],la={error:5,loading:4,stale:3,empty:2,live:1,sample:0},jo=(e,t)=>Object.hasOwn(e,t)?e[t]:void 0;function up(e){let t=r=>Array.isArray(r)||ur(r)&&Object.values(r).some(t),n=r=>Array.isArray(r)?[]:ur(r)?Object.fromEntries(Object.entries(r).map(([o,s])=>[o,n(s)])):r;return t(e)?n(e):null}function dp(e){let t=To(e);if(t!==null)return t>0?"up":t<0?"down":"flat";switch(Si(e)){case"up":case"rising":case"increasing":case"higher":return"up";case"down":case"falling":case"decreasing":case"lower":return"down";case"flat":case"steady":case"stable":case"same":return"flat";default:return"none"}}function wn(e,t){let n=(...r)=>r.map(o=>[o,t]);switch(e.type){case"text":return n(e.value);case"stat":return n(e.value,e.unit,e.label,e.trend,e.icon);case"list":return[...n(e.header,e.emptyText),...e.items?.bind!==void 0?n(ca(e.items.bind)):[],...pa(e.item)];case"status":return n(e.state,e.label,e.detail);case"progress":return n(e.value,e.min,e.max,e.label);case"countdown":return n(e.target,e.label);case"button":return n(e.label,e.icon);case"toggle":return n(e.label,e.state,e.icon);case"icon":return n(e.icon,e.url);case"stack":return n(e.header);case"unknown":return[]}}function pa(e){if(!e)return[];let t=[e.title,e.subtitle,e.badge,e.icon,e.trailing?.text].map(n=>[n,!0]);return e.trailing?.component&&t.push(...wn(e.trailing.component,!0)),t}function fp(e){let t=[e.title,e.icon,e.url,e.text?.text,e.value,e.unit,e.label,e.detail,e.trend,e.state,e.min,e.max,e.emptyText].map(n=>[n,!1]);e.text?.component&&t.push(...wn(e.text.component,!1)),e.items?.bind!==void 0&&t.push([ca(e.items.bind),!1]),t.push(...pa(e.item));for(let n of e.buttons??[])n?.type==="button"&&t.push(...wn(n,!1));return e.toggle&&t.push(...wn(e.toggle,!1)),t}function zo(e){let t=e.screen,n=e.surfaces.tile.theme,r=n&&{corners:n.corners.support==="supported",typeWeight:n.typeWeight.support==="supported",typeWidth:n.typeWidth.support==="supported"};return O({id:e.id,name:e.name,platform:e.platform,shape:t.shape,widthPx:t.widthPx,heightPx:t.heightPx,density:t.density,caseMm:t.caseMm,tileTheme:r})}function yn(e,t){let n=[],r=t.surfaces.screen,o=e.screens.map(a=>a.root===void 0?a:{...a,root:Io(a.root,r.components,r.limits??{},`$.screens.${a.id}.root`,n)}),s=e.tile&&hp(e.tile,t.surfaces.tile,n),i=e.complication&&mp(e.complication,t.surfaces.complication,n);return{view:O({...e,screens:o,tile:s,complication:i}),notes:n}}function Ge(e,t,n){n.support!=="supported"&&e.push(O({path:t,support:n.support,to:n.to,reason:n.reason}))}function Co(e,t){return e!==void 0&&t!==void 0&&e.length>t?e.slice(0,Math.max(t,0)):e}function Io(e,t,n,r,o){let s=Object.hasOwn(t,e.type)?t[e.type]:void 0;if(!s)return e;if(s.support==="unsupported")return Ge(o,r,s),O({type:"unsupported",id:e.id,component:e.type});Ge(o,r,s);let i={...e};if(i.type==="list"){let a=s.limits?.maxRows??n.listMaxRows;a!==void 0&&i.maxRows>a&&(i.maxRows=a),i.items=Co(i.items,a)}else if(i.type==="text"){let a=s.limits?.maxLines??n.textMaxLines;a!==void 0&&i.maxLines>a&&(i.maxLines=a)}else if(i.type==="stack"){let a=i;i={...a,children:a.children.map((l,c)=>Io(l,t,n,`${r}.children[${c}]`,o))}}return Jo(i,s.slots,r,o)}function hp(e,t,n){let r=Object.hasOwn(t.templates,e.template)?t.templates[e.template]:void 0;if(!r)return e;if(Ge(n,"$.tile",r),r.support==="unsupported")return;let o=t.limits??{},s={...e};if(e.template==="list3"||e.template==="compact-list"){let a=r.limits?.maxRows??o[e.template==="list3"?"listMaxRows":"compactListMaxRows"],l=Co(s.items,a);l&&(s.items=l)}let i=Co(s.buttons,r.limits?.maxButtons??o.maxButtons);if(i&&(s.buttons=i),s.text){let a=Io(s.text,t.components,{},"$.tile.text",n),l=r.limits?.maxLines;s.text=a.type==="text"&&l!==void 0&&a.maxLines>l?{...a,maxLines:l}:a}return s=Jo(s,r.slots,"$.tile",n),s}function mp(e,t,n){let r=Object.hasOwn(t.kinds,e.kind)?t.kinds[e.kind]:void 0;if(!r)return e;if(Ge(n,"$.complication",r),r.support==="unsupported")return;let o=r.limits?.maxTextChars;return o!==void 0&&e.text?.type==="text"&&[...e.text.value].length>o&&n.push({path:"$.complication.text",support:"degraded",to:`the watch face cuts it to about ${o} characters`,reason:`${e.kind} complications fit ${o} characters.`}),Jo(e,r.slots,"$.complication",n)}var ua=e=>e==="url"?"imageUrl":e;function Jo(e,t,n,r){if(!t)return e;let o={...e};for(let[s,i]of Object.entries(t)){if(i.support==="supported")continue;let a=s.indexOf(".");if(a<0){let d=ua(s);if(o[d]===void 0)continue;Ge(r,`${n}.${d}`,i),i.support==="unsupported"&&delete o[d];continue}let l=s.slice(0,a)==="item"?"items":s.slice(0,a),c=ua(s.slice(a+1)),p=o[l];if(Array.isArray(p)){let d=m=>m[c]!==void 0||m.action?.[c]!==void 0;if(!p.some(m=>d(m)))continue;Ge(r,`${n}.${l}[*].${c}`,i),i.support==="unsupported"&&(o[l]=p.map(m=>{let{[c]:b,...g}=m;return g}))}else if(p!==null&&typeof p=="object"){if(p.type!==c&&p[c]===void 0)continue;Ge(r,`${n}.${l}`,i)}else p===c&&Ge(r,`${n}.${l}`,i)}return o}function fa(e,t,n,r){return gp(ea(e),t,n,r)}function gp(e,t,n,r={},o="all"){let s=En(r.timeZone)??ot(e.timeZone),i=r.fallbackStaleAge??Oi,a=bp(e,t,n,i),l={};for(let[g,S]of a)S.data!==null&&S.data!==void 0&&(l[g]=S.data);let c=new dr(e,a,l,n,s,O({toggleStates:r.toggleStates??{},fallbackStaleAge:i,dataTime:r.dataTime,vars:r.vars})),p=o==="all"?c.screens():[],d=o==="all"||o==="tile"?c.tile():void 0,m=o==="all"||o==="complication"?c.complication():void 0,b=O({manifestVersion:2,experience:{id:e.experienceId,localId:e.localId,version:e.version},entry:wp(e,l,a,n,s,r.vars),main:e.main,generatedAt:ft(n),timeZone:s,sources:[...c.sources.values()].map(g=>O({name:g.name,state:g.state,lastUpdated:g.lastUpdated===void 0?void 0:ft(g.lastUpdated),message:g.message})),screens:p,tile:d,complication:m});return r.profile?yn(b,r.profile).view:b}function bp(e,t,n,r){let o=new Map;for(let s of Object.keys(e.sources)){let i=Object.hasOwn(t,s)?t[s]:void 0;if(i){o.set(s,i.state==="sample"&&i.fetchedAt!==void 0&&n-i.fetchedAt>r?{...i,state:"stale"}:i);continue}let a=e.sample&&Object.hasOwn(e.sample,s)?e.sample[s]??null:null;o.set(s,{data:a,state:"sample"})}return o}function wp(e,t,n,r,o,s){let i={};for(let[m,b]of Object.entries(t)){let g=n.get(m)?.state;g!=="loading"&&g!=="error"&&(i[m]=b)}let a=O({root:i,now:r,timeZone:o,vars:s}),l=m=>n.has(m),c=new Set;for(let m of[e.entry.title,e.entry.subtitle,e.entry.icon,e.entry.iconUrl])if(m!==void 0)for(let b of Rt(m,!1,l))n.has(b)&&c.add(b);let p=Do(oe(e.entry.icon,a)),d=Do(oe(e.entry.iconUrl,a));return O({title:oe(e.entry.title,a),subtitle:Do(oe(e.entry.subtitle,a)),icon:p,imageUrl:p===void 0&&d!==void 0&&Nt(d)?d:void 0,data:c.size===0?void 0:yp([...c].sort(vp),n)})}var da={error:0,loading:1,stale:2,empty:3,live:4,sample:5};function yp(e,t){let n=e.map(s=>t.get(s)),r=n[0];for(let s of n)da[s.state]<da[r.state]&&(r=s);let o=n.flatMap(s=>s.fetchedAt===void 0?[]:[s.fetchedAt]);return O({state:r.state,lastUpdated:o.length?ft(Math.min(...o)):void 0,message:r.state==="error"||r.state==="stale"?r.message:void 0,sources:e})}var vp=(e,t)=>e<t?-1:e>t?1:0,Do=e=>e.trim()===""?void 0:e;function fr(e,t,n,r){return fa(e,t,n,r??{})}var ke,De,Re,qe,le,vn,jt,hr,mr=class{constructor(t){E(this,jt);E(this,ke);E(this,De);E(this,Re);E(this,qe,1);E(this,le,!1);E(this,vn,0);v(this,ke,t),v(this,De,v(this,Re,t()))}now(){return f(this,le)?f(this,Re):f(this,Re)+(f(this,ke).call(this)-f(this,De))*f(this,qe)}get paused(){return f(this,le)}get speed(){return f(this,qe)}get offset(){return this.now()-M(this,jt,hr).call(this)}get isLive(){return!f(this,le)&&f(this,qe)===1&&Math.abs(this.offset)<1e3}goLive(){v(this,le,!1),v(this,qe,1),v(this,De,v(this,Re,f(this,ke).call(this)))}pause(){f(this,le)||(v(this,Re,this.now()),v(this,vn,f(this,ke).call(this)),v(this,le,!0))}resume(){f(this,le)&&(v(this,De,f(this,ke).call(this)),v(this,le,!1))}togglePause(){f(this,le)?this.resume():this.pause()}setOffset(t){let n=Math.max(-315576e7,Math.min(315576e7,Number.isFinite(t)?t:0));v(this,Re,M(this,jt,hr).call(this)+n),v(this,De,f(this,ke).call(this))}shift(t){this.setOffset(this.offset+t)}setTime(t){this.setOffset(t-M(this,jt,hr).call(this))}setSpeed(t){if(!Number.isFinite(t)||t<=0)throw new RangeError("The clock speed must be a positive number.");v(this,Re,this.now()),v(this,De,f(this,ke).call(this)),v(this,qe,Math.min(t,3600))}};ke=new WeakMap,De=new WeakMap,Re=new WeakMap,qe=new WeakMap,le=new WeakMap,vn=new WeakMap,jt=new WeakSet,hr=function(){return f(this,le)?f(this,vn):f(this,ke).call(this)};function xp(e){if(e.startsWith("/"))return e.slice(1).split("/").map(s=>s.replace(/~1/g,"/").replace(/~0/g,"~")).map(s=>/^\d+$/.test(s)?Number(s):s);let t=e.startsWith("$.")?e.slice(2):e,n=[],r=/([^.[\]]+)|\[(\d+)\]/g,o=0;for(let s=r.exec(t);s;s=r.exec(t)){let i=t.slice(o,s.index);if(i!==""&&i!==".")return null;n.push(s[1]!==void 0?s[1]:Number(s[2])),o=r.lastIndex}return o===t.length&&n.length>0?n:null}function ha(e){return e.map((t,n)=>typeof t=="number"?`[${t}]`:n===0?t:`.${t}`).join("")}function q(e){return e!=null&&typeof e=="object"&&!Array.isArray(e)}function ma(e,t){let n=xp(t);if(!n)return;let r=e,o=0;if(t.startsWith("$.")&&q(e)){let[s]=n,i=a=>{for(let l=n.length;l>1;l--){let c=n.slice(1,l).join("."),p=a.find(d=>q(d)&&d.id===c);if(p)return o=l,p}};if(s==="screens")r=i(Array.isArray(e.screens)?e.screens:[]);else if(s==="glances")r=i([e.tile??null,e.complication??null]);else return}for(;o<n.length;o++){let s=n[o];if(r===null||typeof r!="object")return;r=Array.isArray(r)?typeof s=="number"?r[s]:void 0:r[String(s)]}return r}function*Ct(e,t=[]){if(Array.isArray(e))for(let n=0;n<e.length;n++)yield*Ct(e[n],[...t,n]);else if(q(e)){yield[e,t];for(let[n,r]of Object.entries(e))r!==null&&typeof r=="object"&&(yield*Ct(r,[...t,n]))}}var Vo=["sample","live","loading","error","empty","stale"];function Bo(e){return"experiences"in e?e:{payloadVersion:1,experiences:[e]}}function kp(e){if(!e)return;let t=Date.parse(e);return Number.isNaN(t)?void 0:t}function ga(e,t,n){let r={};if(t==="sample")return r;let o=e.bundle.sources,s=o&&typeof o=="object"&&!Array.isArray(o)?Object.keys(o):[],i=e.bundle.sample;for(let a of s){let l=e.data?.[a],c=i&&typeof i=="object"&&!Array.isArray(i)?i[a]:void 0,p=l?l.data:c??null,d=kp(l?.receivedAt)??n;switch(t){case"live":if(!l)break;r[a]=Tp({data:p,state:l.state??"live"},d,l.message);break;case"empty":r[a]={data:p,state:"empty",fetchedAt:d};break;case"stale":r[a]={data:p,state:"stale"};break;default:r[a]={data:null,state:t}}}return r}function Tp(e,t,n){return t!==void 0&&e.state!=="loading"&&(e.fetchedAt=t),n!==void 0&&(e.message=n),e}var Xe="overview",Sp=2e3,Ap=20,Op=100,me=class extends Error{};function br(e){let t=typeof e.main=="string"?e.main:void 0,r=(Array.isArray(e.screens)?e.screens.filter(q):[]).map(i=>String(i.id)),s=[...r.filter(i=>i===t),...r.filter(i=>i!==t)].map(i=>({kind:"page",label:i,target:i,key:`page:${i}`}));return q(e.tile)&&s.push({kind:"tile",label:"tile",target:String(e.tile.id??"tile"),key:"tile"}),q(e.complication)&&s.push({kind:"complication",label:"complication",target:String(e.complication.id??"complication"),key:"complication"}),s.push({kind:"home",label:"App home",target:"home",key:"home"}),s}function vr(e,t){if(e.startsWith("screen:"))return e.slice(7);let n=t.find(r=>r.key===e);return n?.kind==="page"?n.target:null}function _p(e,t){if(!t)return null;let n=ma(e,t),r=t;if(!q(n)){for(let[s,i]of Ct(e))if(s.id===t&&s.type!=="tile"&&s.type!=="complication"&&i[0]!=="experience"){n=s,r=ha(i);break}}if(!q(n))return null;if(n===e.tile||n===e.complication||r==="tile"||r==="complication")return typeof n.opens=="string"?{kind:"open",path:t,node:n,opens:n.opens}:null;let o=typeof n.icon=="string"?n.icon:void 0;return n.type==="toggle"||typeof n.key=="string"&&typeof n.on=="boolean"?{kind:"toggle",path:t,node:n,...o?{icon:o}:{}}:q(n.action)?{kind:"action",path:t,node:n,action:n.action,...o?{icon:o}:{}}:null}var mt,gt,xn,Te,Se,bt,ae,Ze,zt,wt,yr,R,va,xa,ka,Ta,Fo,gr,Uo,Ho,Wo,Go,Sa,Aa,Oa,wr=class{constructor(t,n={}){E(this,R);I(this,"clock");E(this,mt);E(this,gt);E(this,xn);E(this,Te,null);E(this,Se,[]);E(this,bt,{});E(this,ae,null);E(this,Ze,null);E(this,zt,0);E(this,wt,[]);E(this,yr,0);I(this,"settings",{theme:"auto",ambient:!1,showCase:!0});I(this,"data","sample");I(this,"mock",{outcome:"succeed",failureRate:.3});I(this,"dataTime");I(this,"version",0);v(this,mt,t),this.clock=new mr(t),this.dataTime=t(),v(this,gt,n.devices??[]),v(this,xn,n.random??Math.random)}get surfaceKey(){return f(this,Te)}get backStack(){return f(this,Se)}get canGoBack(){return f(this,Se).length>0||f(this,ae)!==null}get toggles(){return f(this,bt)}get confirm(){return f(this,ae)}get log(){return f(this,wt)}get overlay(){return f(this,Ze)&&f(this,mt).call(this)<f(this,zt)?f(this,Ze):null}get overlayExpiresAt(){return this.overlay?f(this,zt):null}restart(){v(this,Te,null),v(this,Se,[]),v(this,bt,{}),v(this,ae,null),v(this,Ze,null),this.dataTime=f(this,mt).call(this),this.version++}effectiveSurface(t,n=br(t)){return f(this,Te)!==null&&ya(f(this,Te),t,n)?f(this,Te):n[0]?.key??Xe}apply(t,n){let r=n?br(n):[],o;switch(t.type){case"surface":o=M(this,R,va).call(this,t.surface,n,r);break;case"back":o=M(this,R,xa).call(this);break;case"tap":o=M(this,R,ka).call(this,t.path,n,r);break;case"confirm":o=M(this,R,Ta).call(this,n,r);break;case"cancel":o=M(this,R,Fo).call(this);break;case"settings":o=M(this,R,Sa).call(this,t);break;case"clock":o=M(this,R,Aa).call(this,t);break;case"data":o=M(this,R,Oa).call(this,t.data);break;default:throw new me(`Unknown command type '${String(t.type)}'.`)}return o&&this.version++,o}};mt=new WeakMap,gt=new WeakMap,xn=new WeakMap,Te=new WeakMap,Se=new WeakMap,bt=new WeakMap,ae=new WeakMap,Ze=new WeakMap,zt=new WeakMap,wt=new WeakMap,yr=new WeakMap,R=new WeakSet,va=function(t,n,r){if(!t||!n||!ya(t,n,r))throw new me(`Unknown surface '${t}'. Use one of: ${[...r.map(s=>s.key),Xe].join(", ")}.`);let o=this.effectiveSurface(n,r);return v(this,ae,null),t===o?!1:(v(this,Se,[]),v(this,Te,t),!0)},xa=function(){if(f(this,ae))return M(this,R,Fo).call(this);let t=f(this,Se).pop();return t===void 0?!1:(v(this,Te,t),!0)},ka=function(t,n,r){let o=n?_p(n,t):null;if(!o||!n)return!1;if(o.kind==="open")return M(this,R,Wo).call(this,o.opens,n,r);if(o.kind==="toggle"){let i=String(o.node.key??o.path),a=o.node.on!==!0;f(this,bt)[i]=a;let l=o.node[a?"onAction":"offAction"];if(q(l)&&l.kind==="openScreen")return M(this,R,gr).call(this,l,o.path,n,r),!0;let c=q(l)?M(this,R,Uo).call(this,l,o.path):!0;return c||(f(this,bt)[i]=!a),M(this,R,Go).call(this,c,c?void 0:wa(l),!c),!0}let s=o.action;return typeof s.confirm=="string"&&s.confirm.trim()!==""?(v(this,ae,{prompt:s.confirm,action:s,path:o.path,...o.icon?{icon:o.icon}:{}}),!0):(M(this,R,gr).call(this,s,o.path,n,r),!0)},Ta=function(t,n){let r=f(this,ae);return r?(v(this,ae,null),M(this,R,gr).call(this,r.action,r.path,t,n),!0):!1},Fo=function(){return f(this,ae)?(v(this,ae,null),!0):!1},gr=function(t,n,r,o){if(t.kind==="openScreen"&&typeof t.screen=="string"){M(this,R,Ho).call(this,t,n,!0,`Navigated to ${t.screen}`),r&&M(this,R,Wo).call(this,t.screen,r,o);return}let s=M(this,R,Uo).call(this,t,n),i=q(t.toast)?t.toast:void 0,a=s?typeof i?.success=="string"?i.success:t.kind==="refreshSource"?"Refreshed":"Sent":wa(t);M(this,R,Go).call(this,s,a,!0)},Uo=function(t,n){let r=this.mock.outcome==="succeed"?!0:this.mock.outcome==="fail"?!1:f(this,xn).call(this)>=this.mock.failureRate,o=r?t.kind==="refreshSource"?"200 OK (mock) \xB7 source refreshed":'200 OK (mock) \xB7 {"ok":true}':"503 Service Unavailable (mock)";return M(this,R,Ho).call(this,t,n,r,o),r},Ho=function(t,n,r,o){f(this,wt).unshift({id:++ps(this,yr)._,at:this.clock.now(),action:String(t.id??"?"),kind:String(t.kind??"?"),path:n,...t.context!==void 0?{context:t.context}:{},status:r?"succeeded":"failed",result:o}),f(this,wt).length>Op&&f(this,wt).pop()},Wo=function(t,n,r){let o=r.find(i=>i.kind==="page"&&i.target===t)?.key??`screen:${t}`,s=this.effectiveSurface(n,r);return o===s?!1:(f(this,Se).push(s),f(this,Se).length>Ap&&f(this,Se).shift(),v(this,Te,o),v(this,ae,null),!0)},Go=function(t,n,r){v(this,Ze,{success:t,toast:r,sequence:(f(this,Ze)?.sequence??0)+1,...n!==void 0?{message:n}:{}}),v(this,zt,f(this,mt).call(this)+Sp)},Sa=function(t){let n={...this.settings};if(t.device!==void 0){if(f(this,gt).length>0&&!f(this,gt).includes(t.device))throw new me(`Unknown device '${t.device}'. Use one of: ${f(this,gt).join(", ")}.`);n.device=t.device}if(t.theme!==void 0){if(t.theme!=="auto"&&!ze(t.theme))throw new me(`Unknown theme '${t.theme}'. Use auto or one of: ${St.map(o=>o.id).join(", ")}.`);n.theme=t.theme}t.ambient!==void 0&&(n.ambient=t.ambient),t.case!==void 0&&(n.showCase=t.case);let r=n.device!==this.settings.device||n.theme!==this.settings.theme||n.ambient!==this.settings.ambient||n.showCase!==this.settings.showCase;return this.settings=n,r},Aa=function(t){let n=this.clock,r=[n.paused,Math.round(n.offset),n.speed].join();switch(t.clock){case void 0:break;case"live":n.goLive();break;case"frozen":n.pause();break;case"running":n.resume();break;default:throw new me(`Unknown clock mode '${String(t.clock)}'. Use live, frozen or running.`)}let o=s=>{if(!Number.isFinite(s))throw new me("Clock minutes must be a finite number.");return Math.max(-315576e7,Math.min(315576e7,s*6e4))};if(t.offsetMinutes!==void 0&&n.setOffset(o(t.offsetMinutes)),t.shiftMinutes!==void 0&&n.shift(o(t.shiftMinutes)),t.speed!==void 0)try{n.setSpeed(t.speed)}catch(s){throw new me(s.message)}return r!==[n.paused,Math.round(n.offset),n.speed].join()},Oa=function(t){if(!Vo.includes(t))throw new me(`Unknown data state '${t}'. Use ${Vo.join(", ")}.`);return t===this.data?!1:(this.data=t,!0)};function wa(e){let t=q(e)?e.toast:void 0;return q(t)&&typeof t.failure=="string"?t.failure:"Failed"}function ya(e,t,n){if(e===Xe||n.some(o=>o.key===e))return!0;if(!e.startsWith("screen:"))return!1;let r=e.slice(7);return Array.isArray(t.screens)&&t.screens.some(o=>q(o)&&o.id===r)}var Ep=/\$ms\b/,Mp=/\$now|\$ms|\$dataTime|\b(relative|ago|countdown|time|date|since|until)\b/,_a=new WeakMap;function Lp(e,t){let n=_a.get(e);if(n)return n;let r=a=>{try{return t(a)}catch{return Mp.test(a)}},o={},s=(a,l)=>{o[a]=Rp(l,r)},i=e.pages;if(q(i))for(let[a,l]of Object.entries(i))s(`page:${a}`,l);return s("tile",e.tile),s("complication",e.complication),s("home",e.entry),_a.set(e,o),o}function Rp(e,t){let n={clock:!1,subSecond:!1},r=o=>{if(typeof o=="string"){if(!o.includes("{{"))return;Ep.test(o)?n.clock=n.subSecond=!0:!n.clock&&t(o)&&(n.clock=!0)}else Array.isArray(o)?o.forEach(r):q(o)&&Object.values(o).forEach(r)};return r(e),n}function Pp(e,t,n){if(t===Xe)return e;if(t==="tile"||t==="complication")return e[t];if(t==="home")return e.entry;let r=vr(t,n);return Array.isArray(e.screens)?e.screens.find(o=>q(o)&&o.id===r):void 0}function Np(e,t,n){for(let[r]of Ct(Pp(e,t,n)))if(r.type==="countdown"&&typeof r.target=="string"||r.state==="stale"&&Array.isArray(r.sources))return!0;return!1}function Ea(e,t,n,r,o){let s=Lp(e,o),i=n===Xe?Object.keys(s):[n.startsWith("screen:")?`page:${n.slice(7)}`:n],a=!1;for(let l of i){let c=s[l];if(c?.subSecond)return"frame";c?.clock&&(a=!0)}return a||Np(t,n,r)?"second":"none"}var yt,Pe,ce,ie,Ne,vt,Ye,Qe,It,$e,Ke,kn,Jt,xt,se,qo,Zo,Ma,La,xr,kr=class{constructor(t,n,r,o={}){E(this,se);I(this,"session");E(this,yt);E(this,Pe);E(this,ce);E(this,ie);E(this,Ne);E(this,vt,null);E(this,Ye,[]);E(this,Qe,"");E(this,It,null);E(this,$e,null);E(this,Ke,null);E(this,kn);E(this,Jt,!1);E(this,xt,{resolve:0,render:0});I(this,"stats",{frames:0,firstResolveMs:null,lastResolveMs:0,lastRenderMs:0,avgResolveMs:0,maxResolveMs:0,avgRenderMs:0,maxRenderMs:0,cadence:"none",lastDrawAt:0});v(this,yt,n),v(this,Pe,r),v(this,ce,o),v(this,ie,Bo(t)),v(this,Ne,M(this,se,qo).call(this,o.experience)),this.session=new wr(()=>r.now(),{...o.devices?{devices:o.devices}:{},...o.random?{random:o.random}:{}});let s=this.session;s.data=o.data??(this.experience?.data&&Object.keys(this.experience.data).length>0?"live":"sample"),s.settings={theme:o.theme??"auto",ambient:o.ambient??!1,showCase:o.showCase??!0,...o.device?{device:o.device}:{}},v(this,kn,r.onVisibility(()=>{r.hidden()?M(this,se,xr).call(this):this.draw()}));try{this.draw(),o.surface&&f(this,vt)&&this.command({type:"surface",surface:o.surface})}catch(i){throw this.destroy(),i}}get payload(){return f(this,ie)}get experiences(){return f(this,ie).experiences}get experienceKey(){return f(this,Ne)}get experience(){return f(this,ie).experiences.find(t=>t.key===f(this,Ne))}get view(){return f(this,vt)}get surfaces(){return f(this,Ye)}get surface(){return f(this,Qe)}get error(){return f(this,It)}get destroyed(){return f(this,Jt)}command(t){let n=this.session.apply(t,f(this,vt));return n&&this.draw(),n}selectExperience(t){if(t===f(this,Ne))return!1;if(!f(this,ie).experiences.some(n=>n.key===t))throw new Error(`Unknown Experience '${t}'.`);if(f(this,ie).limits?.experiences&&!f(this,ie).limits.experiences.includes(t))throw new Error(`The Experience '${t}' is not part of this preview.`);return v(this,Ne,t),this.session.restart(),this.draw(),!0}setPayload(t){let n=this.experience?.bundleHash;v(this,ie,Bo(t)),f(this,ie).experiences.some(r=>r.key===f(this,Ne))?n!==void 0&&n!==this.experience?.bundleHash&&this.session.version++:(v(this,Ne,M(this,se,qo).call(this,void 0)),this.session.restart()),this.draw()}setData(t,n,r=f(this,Pe).now()){let o=this.experience;if(!o)return;let s={data:n,state:"live",receivedAt:new Date(r).toISOString()};o.data={...o.data??{},[t]:s},this.draw()}draw(){if(f(this,Jt))return;M(this,se,xr).call(this);let t=this.experience;if(!t)return;let n=this.session,r=f(this,Pe),o=n.clock.now(),s=ga(t,n.data,n.dataTime),i={toggleStates:{...n.toggles},dataTime:n.dataTime,vars:f(this,ce).vars?f(this,ce).vars(o):{ms:o},...f(this,ce).timeZone?{timeZone:f(this,ce).timeZone}:{}},a=r.perf(),l;try{l=f(this,yt).resolve(t.bundle,s,o,i)}catch(A){M(this,se,Zo).call(this,A);return}let c=r.perf();v(this,vt,l),v(this,Ye,br(l)),v(this,Qe,n.effectiveSurface(l,f(this,Ye)));let p=vr(f(this,Qe),f(this,Ye)),d=n.confirm,m=n.overlay,b=n.settings.theme==="auto"?void 0:ze(n.settings.theme),g=b?At(b):t.theme,S={surface:f(this,Qe),ambient:n.settings.ambient,now:o,frame:n.settings.showCase,...p!==null?{screen:p}:{},...n.settings.device?{device:n.settings.device}:{},...g?{theme:g}:{},...f(this,ce).timeZone?{timeZone:f(this,ce).timeZone}:{},...d?{confirm:{prompt:d.prompt,...d.icon?{icon:d.icon}:{}}}:{},...m?{feedback:m}:{}};try{f(this,yt).render(l,S)}catch(A){M(this,se,Zo).call(this,A);return}let _=r.perf();v(this,It,null),M(this,se,Ma).call(this,c-a,_-c),this.stats.cadence=n.clock.paused?"none":Ea(t.bundle,l,f(this,Qe),f(this,Ye),A=>f(this,yt).readsClock(A)),M(this,se,La).call(this),f(this,ce).onUpdate?.(this)}destroy(){v(this,Jt,!0),M(this,se,xr).call(this),f(this,kn).call(this)}};yt=new WeakMap,Pe=new WeakMap,ce=new WeakMap,ie=new WeakMap,Ne=new WeakMap,vt=new WeakMap,Ye=new WeakMap,Qe=new WeakMap,It=new WeakMap,$e=new WeakMap,Ke=new WeakMap,kn=new WeakMap,Jt=new WeakMap,xt=new WeakMap,se=new WeakSet,qo=function(t){let n=f(this,ie).experiences.filter(o=>!f(this,ie).limits?.experiences||f(this,ie).limits.experiences.includes(o.key));if(t!==void 0){if(!n.some(o=>o.key===t))throw new Error(`Unknown Experience '${t}'.`);return t}let r=n[0];if(!r)throw new Error("The payload has no Experience to show.");return r.key},Zo=function(t){v(this,It,t),this.stats.cadence="none",f(this,ce).onError?.(t),f(this,ce).onUpdate?.(this)},Ma=function(t,n){let r=this.stats;r.frames++,r.firstResolveMs??(r.firstResolveMs=t),r.lastResolveMs=t,r.lastRenderMs=n,f(this,xt).resolve+=t,f(this,xt).render+=n,r.avgResolveMs=f(this,xt).resolve/r.frames,r.avgRenderMs=f(this,xt).render/r.frames,r.maxResolveMs=Math.max(r.maxResolveMs,t),r.maxRenderMs=Math.max(r.maxRenderMs,n),r.lastDrawAt=f(this,Pe).now()},La=function(){let t=f(this,Pe),n=this.session.clock;if(t.hidden())return;let r=1/0;if(this.stats.cadence==="frame")v(this,$e,t.frame(()=>{v(this,$e,null),this.draw()}));else if(this.stats.cadence==="second"){let i=(1e3-(n.now()%1e3+1e3)%1e3)/n.speed;i<16?v(this,$e,t.frame(()=>{v(this,$e,null),this.draw()})):r=Math.ceil(i)+1}let o=this.session.overlayExpiresAt;o!==null&&(r=Math.min(r,Math.max(0,o-t.now()))),r!==1/0&&v(this,Ke,t.timeout(()=>{v(this,Ke,null),this.draw()},r))},xr=function(){f(this,$e)!==null&&f(this,Pe).cancelFrame(f(this,$e)),f(this,Ke)!==null&&f(this,Pe).cancelTimeout(f(this,Ke)),v(this,$e,v(this,Ke,null))};function Ra(){let e=typeof document>"u"?void 0:document,t=typeof performance>"u"?void 0:performance;return{now:()=>t?t.timeOrigin+t.now():Date.now(),perf:()=>t?t.now():Date.now(),frame:n=>typeof requestAnimationFrame=="function"?requestAnimationFrame(()=>n()):setTimeout(n,16),cancelFrame:n=>typeof cancelAnimationFrame=="function"?cancelAnimationFrame(n):clearTimeout(n),timeout:(n,r)=>setTimeout(n,r),cancelTimeout:n=>clearTimeout(n),hidden:()=>e?.visibilityState==="hidden",onVisibility:n=>e?(e.addEventListener("visibilitychange",n),()=>e.removeEventListener("visibilitychange",n)):()=>{}}}function Xo(e,t,n){let r={resolve:n.engine.resolve??fr,readsClock:n.engine.readsClock??Yi,render:n.engine.render},o=null,s=a=>{if(!(!o||!(a.target instanceof Element)))try{if(o.surface===Xe){let p=a.target.closest("[data-wb-surface]");p&&e.contains(p)&&(a.preventDefault(),o.command({type:"surface",surface:p.getAttribute("data-wb-surface")??""}));return}let l=a.target.closest("[data-wb-tap]");if(!l||!e.contains(l))return;a.preventDefault();let c=l.getAttribute("data-wb-tap");c==="confirm"||c==="cancel"?o.command({type:c}):o.command({type:"tap",path:l.getAttribute("data-path")??""})}catch(l){if(!(l instanceof me))throw l}};o=new kr(t,r,n.scheduler??Ra(),n),e.addEventListener("click",s);let i=o.destroy.bind(o);return o.destroy=()=>{i(),e.removeEventListener("click",s)},o}var Dt=class extends Error{};function $p(e){let t="";for(let n=0;n<e.length;n+=32768)t+=String.fromCharCode(...e.subarray(n,n+32768));return btoa(t).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function jp(e,t){let n=e.getReader(),r=[],o=0;for(;;){let{done:a,value:l}=await n.read();if(a)break;if(o+=l.length,o>t)throw n.cancel().catch(()=>{}),new Dt(`The project in the link is larger than ${t/1024} KB.`);r.push(l)}let s=new Uint8Array(o),i=0;for(let a of r)s.set(a,i),i+=a.length;return s}async function Pa(e,t={}){let n=new TextEncoder().encode(JSON.stringify({v:1,config:e,data:t}));if(n.length>32768)throw new Dt(`The project is ${(n.length/1024).toFixed(1)} KB as JSON; a link holds at most ${32768/1024} KB.`);return $p(await jp(new Blob([n]).stream().pipeThrough(new CompressionStream("deflate-raw")),Number.MAX_SAFE_INTEGER))}function Tr(e,t=!1){let n=e.length,r=0,o="",s=0,i=16,a=0,l=0,c=0,p=0,d=0;function m(w,C){let P=0,x=0;for(;P<w||!C;){let y=e.charCodeAt(r);if(y>=48&&y<=57)x=x*16+y-48;else if(y>=65&&y<=70)x=x*16+y-65+10;else if(y>=97&&y<=102)x=x*16+y-97+10;else break;r++,P++}return P<w&&(x=-1),x}function b(w){r=w,o="",s=0,i=16,d=0}function g(){let w=r;if(e.charCodeAt(r)===48)r++;else for(r++;r<e.length&&Vt(e.charCodeAt(r));)r++;if(r<e.length&&e.charCodeAt(r)===46)if(r++,r<e.length&&Vt(e.charCodeAt(r)))for(r++;r<e.length&&Vt(e.charCodeAt(r));)r++;else return d=3,e.substring(w,r);let C=r;if(r<e.length&&(e.charCodeAt(r)===69||e.charCodeAt(r)===101))if(r++,(r<e.length&&e.charCodeAt(r)===43||e.charCodeAt(r)===45)&&r++,r<e.length&&Vt(e.charCodeAt(r))){for(r++;r<e.length&&Vt(e.charCodeAt(r));)r++;C=r}else d=3;return e.substring(w,C)}function S(){let w="",C=r;for(;;){if(r>=n){w+=e.substring(C,r),d=2;break}let P=e.charCodeAt(r);if(P===34){w+=e.substring(C,r),r++;break}if(P===92){if(w+=e.substring(C,r),r++,r>=n){d=2;break}switch(e.charCodeAt(r++)){case 34:w+='"';break;case 92:w+="\\";break;case 47:w+="/";break;case 98:w+="\b";break;case 102:w+="\f";break;case 110:w+=`
4
+ `;break;case 114:w+="\r";break;case 116:w+=" ";break;case 117:let y=m(4,!0);y>=0?w+=String.fromCharCode(y):d=4;break;default:d=5}C=r;continue}if(P>=0&&P<=31)if(Tn(P)){w+=e.substring(C,r),d=2;break}else d=6;r++}return w}function _(){if(o="",d=0,s=r,l=a,p=c,r>=n)return s=n,i=17;let w=e.charCodeAt(r);if(Yo(w)){do r++,o+=String.fromCharCode(w),w=e.charCodeAt(r);while(Yo(w));return i=15}if(Tn(w))return r++,o+=String.fromCharCode(w),w===13&&e.charCodeAt(r)===10&&(r++,o+=`
5
+ `),a++,c=r,i=14;switch(w){case 123:return r++,i=1;case 125:return r++,i=2;case 91:return r++,i=3;case 93:return r++,i=4;case 58:return r++,i=6;case 44:return r++,i=5;case 34:return r++,o=S(),i=10;case 47:let C=r-1;if(e.charCodeAt(r+1)===47){for(r+=2;r<n&&!Tn(e.charCodeAt(r));)r++;return o=e.substring(C,r),i=12}if(e.charCodeAt(r+1)===42){r+=2;let P=n-1,x=!1;for(;r<P;){let y=e.charCodeAt(r);if(y===42&&e.charCodeAt(r+1)===47){r+=2,x=!0;break}r++,Tn(y)&&(y===13&&e.charCodeAt(r)===10&&r++,a++,c=r)}return x||(r++,d=1),o=e.substring(C,r),i=13}return o+=String.fromCharCode(w),r++,i=16;case 45:if(o+=String.fromCharCode(w),r++,r===n||!Vt(e.charCodeAt(r)))return i=16;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return o+=g(),i=11;default:for(;r<n&&A(w);)r++,w=e.charCodeAt(r);if(s!==r){switch(o=e.substring(s,r),o){case"true":return i=8;case"false":return i=9;case"null":return i=7}return i=16}return o+=String.fromCharCode(w),r++,i=16}}function A(w){if(Yo(w)||Tn(w))return!1;switch(w){case 125:case 93:case 123:case 91:case 34:case 58:case 44:case 47:return!1}return!0}function J(){let w;do w=_();while(w>=12&&w<=15);return w}return{setPosition:b,getPosition:()=>r,scan:t?J:_,getToken:()=>i,getTokenValue:()=>o,getTokenOffset:()=>s,getTokenLength:()=>r-s,getTokenStartLine:()=>l,getTokenStartCharacter:()=>s-p,getTokenError:()=>d}}function Yo(e){return e===32||e===9}function Tn(e){return e===10||e===13}function Vt(e){return e>=48&&e<=57}var Na;(function(e){e[e.lineFeed=10]="lineFeed",e[e.carriageReturn=13]="carriageReturn",e[e.space=32]="space",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e.asterisk=42]="asterisk",e[e.backslash=92]="backslash",e[e.closeBrace=125]="closeBrace",e[e.closeBracket=93]="closeBracket",e[e.colon=58]="colon",e[e.comma=44]="comma",e[e.dot=46]="dot",e[e.doubleQuote=34]="doubleQuote",e[e.minus=45]="minus",e[e.openBrace=123]="openBrace",e[e.openBracket=91]="openBracket",e[e.plus=43]="plus",e[e.slash=47]="slash",e[e.formFeed=12]="formFeed",e[e.tab=9]="tab"})(Na||(Na={}));var zp=new Array(20).fill(0).map((e,t)=>" ".repeat(t)),Bt=200,Ip={" ":{"\n":new Array(Bt).fill(0).map((e,t)=>`
6
+ `+" ".repeat(t)),"\r":new Array(Bt).fill(0).map((e,t)=>"\r"+" ".repeat(t)),"\r\n":new Array(Bt).fill(0).map((e,t)=>`\r
7
+ `+" ".repeat(t))}," ":{"\n":new Array(Bt).fill(0).map((e,t)=>`
8
+ `+" ".repeat(t)),"\r":new Array(Bt).fill(0).map((e,t)=>"\r"+" ".repeat(t)),"\r\n":new Array(Bt).fill(0).map((e,t)=>`\r
9
+ `+" ".repeat(t))}};var Sr;(function(e){e.DEFAULT={allowTrailingComma:!1}})(Sr||(Sr={}));function Qo(e,t=[],n=Sr.DEFAULT){let r={type:"array",offset:-1,length:-1,children:[],parent:void 0};function o(l){r.type==="property"&&(r.length=l-r.offset,r=r.parent)}function s(l){return r.children.push(l),l}Ko(e,{onObjectBegin:l=>{r=s({type:"object",offset:l,length:-1,parent:r,children:[]})},onObjectProperty:(l,c,p)=>{r=s({type:"property",offset:c,length:-1,parent:r,children:[]}),r.children.push({type:"string",value:l,offset:c,length:p,parent:r})},onObjectEnd:(l,c)=>{o(l+c),r.length=l+c-r.offset,r=r.parent,o(l+c)},onArrayBegin:(l,c)=>{r=s({type:"array",offset:l,length:-1,parent:r,children:[]})},onArrayEnd:(l,c)=>{r.length=l+c-r.offset,r=r.parent,o(l+c)},onLiteralValue:(l,c,p)=>{s({type:Dp(l),offset:c,length:p,parent:r,value:l}),o(c+p)},onSeparator:(l,c,p)=>{r.type==="property"&&(l===":"?r.colonOffset=c:l===","&&o(c))},onError:(l,c,p)=>{t.push({error:l,offset:c,length:p})}},n);let a=r.children[0];return a&&delete a.parent,a}function Ko(e,t,n=Sr.DEFAULT){let r=Tr(e,!1),o=[],s=0;function i($){return $?()=>s===0&&$(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter()):()=>!0}function a($){return $?X=>s===0&&$(X,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter()):()=>!0}function l($){return $?X=>s===0&&$(X,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter(),()=>o.slice()):()=>!0}function c($){return $?()=>{s>0?s++:$(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter(),()=>o.slice())===!1&&(s=1)}:()=>!0}function p($){return $?()=>{s>0&&s--,s===0&&$(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter())}:()=>!0}let d=c(t.onObjectBegin),m=l(t.onObjectProperty),b=p(t.onObjectEnd),g=c(t.onArrayBegin),S=p(t.onArrayEnd),_=l(t.onLiteralValue),A=a(t.onSeparator),J=i(t.onComment),w=a(t.onError),C=n&&n.disallowComments,P=n&&n.allowTrailingComma;function x(){for(;;){let $=r.scan();switch(r.getTokenError()){case 4:y(14);break;case 5:y(15);break;case 3:y(13);break;case 1:C||y(11);break;case 2:y(12);break;case 6:y(16);break}switch($){case 12:case 13:C?y(10):J();break;case 16:y(1);break;case 15:case 14:break;default:return $}}}function y($,X=[],ls=[]){if(w($),X.length+ls.length>0){let Sn=r.getToken();for(;Sn!==17;){if(X.indexOf(Sn)!==-1){x();break}else if(ls.indexOf(Sn)!==-1)break;Sn=x()}}}function z($){let X=r.getTokenValue();return $?_(X):(m(X),o.push(X)),x(),!0}function N(){switch(r.getToken()){case 11:let $=r.getTokenValue(),X=Number($);isNaN(X)&&(y(2),X=0),_(X);break;case 7:_(null);break;case 8:_(!0);break;case 9:_(!1);break;default:return!1}return x(),!0}function T(){return r.getToken()!==10?(y(3,[],[2,5]),!1):(z(!1),r.getToken()===6?(A(":"),x(),pe()||y(4,[],[2,5])):y(5,[],[2,5]),o.pop(),!0)}function Z(){d(),x();let $=!1;for(;r.getToken()!==2&&r.getToken()!==17;){if(r.getToken()===5){if($||y(4,[],[]),A(","),x(),r.getToken()===2&&P)break}else $&&y(6,[],[]);T()||y(4,[],[2,5]),$=!0}return b(),r.getToken()!==2?y(7,[2],[]):x(),!0}function te(){g(),x();let $=!0,X=!1;for(;r.getToken()!==4&&r.getToken()!==17;){if(r.getToken()===5){if(X||y(4,[],[]),A(","),x(),r.getToken()===4&&P)break}else X&&y(6,[],[]);$?(o.push(0),$=!1):o[o.length-1]++,pe()||y(4,[],[4,5]),X=!0}return S(),$||o.pop(),r.getToken()!==4?y(8,[4],[]):x(),!0}function pe(){switch(r.getToken()){case 3:return te();case 1:return Z();case 10:return z(!0);default:return N()}}return x(),r.getToken()===17?n.allowEmptyContent?!0:(y(4,[],[]),!1):pe()?(r.getToken()!==17&&y(9,[],[]),!0):(y(4,[],[]),!1)}function Dp(e){switch(typeof e){case"boolean":return"boolean";case"number":return"number";case"string":return"string";case"object":{if(e){if(Array.isArray(e))return"array"}else return"null";return"object"}default:return"null"}}var $a;(function(e){e[e.None=0]="None",e[e.UnexpectedEndOfComment=1]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=2]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=3]="UnexpectedEndOfNumber",e[e.InvalidUnicode=4]="InvalidUnicode",e[e.InvalidEscapeCharacter=5]="InvalidEscapeCharacter",e[e.InvalidCharacter=6]="InvalidCharacter"})($a||($a={}));var ja;(function(e){e[e.OpenBraceToken=1]="OpenBraceToken",e[e.CloseBraceToken=2]="CloseBraceToken",e[e.OpenBracketToken=3]="OpenBracketToken",e[e.CloseBracketToken=4]="CloseBracketToken",e[e.CommaToken=5]="CommaToken",e[e.ColonToken=6]="ColonToken",e[e.NullKeyword=7]="NullKeyword",e[e.TrueKeyword=8]="TrueKeyword",e[e.FalseKeyword=9]="FalseKeyword",e[e.StringLiteral=10]="StringLiteral",e[e.NumericLiteral=11]="NumericLiteral",e[e.LineCommentTrivia=12]="LineCommentTrivia",e[e.BlockCommentTrivia=13]="BlockCommentTrivia",e[e.LineBreakTrivia=14]="LineBreakTrivia",e[e.Trivia=15]="Trivia",e[e.Unknown=16]="Unknown",e[e.EOF=17]="EOF"})(ja||(ja={}));var za=Qo;var Ia=Ko;var Ca;(function(e){e[e.InvalidSymbol=1]="InvalidSymbol",e[e.InvalidNumberFormat=2]="InvalidNumberFormat",e[e.PropertyNameExpected=3]="PropertyNameExpected",e[e.ValueExpected=4]="ValueExpected",e[e.ColonExpected=5]="ColonExpected",e[e.CommaExpected=6]="CommaExpected",e[e.CloseBraceExpected=7]="CloseBraceExpected",e[e.CloseBracketExpected=8]="CloseBracketExpected",e[e.EndOfFileExpected=9]="EndOfFileExpected",e[e.InvalidCommentToken=10]="InvalidCommentToken",e[e.UnexpectedEndOfComment=11]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=12]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=13]="UnexpectedEndOfNumber",e[e.InvalidUnicode=14]="InvalidUnicode",e[e.InvalidEscapeCharacter=15]="InvalidEscapeCharacter",e[e.InvalidCharacter=16]="InvalidCharacter"})(Ca||(Ca={}));function Ja(e){switch(e){case 1:return"InvalidSymbol";case 2:return"InvalidNumberFormat";case 3:return"PropertyNameExpected";case 4:return"ValueExpected";case 5:return"ColonExpected";case 6:return"CommaExpected";case 7:return"CloseBraceExpected";case 8:return"CloseBracketExpected";case 9:return"EndOfFileExpected";case 10:return"InvalidCommentToken";case 11:return"UnexpectedEndOfComment";case 12:return"UnexpectedEndOfString";case 13:return"UnexpectedEndOfNumber";case 14:return"InvalidUnicode";case 15:return"InvalidEscapeCharacter";case 16:return"InvalidCharacter"}return"<unknown ParseErrorCode>"}var F=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function Ar(e,t){let n=t==="data.json"?{file:t}:{};if(!e||!e.trim())return t==="data.json"?{value:{},issues:[]}:{value:null,issues:[{path:"$",rule:"json-syntax",message:"watch.json is empty.",allowed:[],severity:"error"}]};let r=[],o=za(e,r,{allowTrailingComma:!0,disallowComments:!1});if(r.length||!o){let i=r[0],{line:a,column:l}=Wp(e,i?.offset??0),c=i?Hp(Ja(i.error)):"unexpected end of the text";return{value:null,issues:[{path:"$",rule:"json-syntax",message:`Invalid JSON (line ${a}, column ${l}): ${c}.`,allowed:[],severity:"error",...n,line:a,column:l}]}}let s=Gp(e);return s?{value:null,issues:[{path:s.path,rule:"json-syntax",message:`Invalid JSON (line ${s.line}, column ${s.column}): '${s.name}' appears twice in the same object.`,allowed:[],severity:"error",...n,line:s.line,column:s.column}]}:o.type!=="object"?{value:null,issues:[{path:"$",rule:"json-type",message:t==="data.json"?"data.json must be an object keyed by source name.":"watch.json must be a JSON object.",allowed:[],severity:"error",...n,line:1,column:1}]}:{value:es(o),issues:[]}}function es(e){switch(e.type){case"object":{let t={};for(let n of e.children??[]){let[r,o]=n.children??[];r&&o&&(t[r.value]=es(o))}return t}case"array":return(e.children??[]).map(es);default:return e.value}}var Hp=e=>e.replace(/([a-z])([A-Z])/g,"$1 $2").toLowerCase();function Wp(e,t){let n=1,r=0;for(let o=0;o<t&&o<e.length;o++)e[o]===`
10
+ `&&(n++,r=o+1);return{line:n,column:t-r+1}}function Gp(e){let t=[],n=null;return Ia(e,{onObjectBegin:()=>{t.push(new Set)},onObjectEnd:()=>{t.pop()},onObjectProperty:(r,o,s,i,a,l)=>{let c=t[t.length-1];!c||n||(c.has(r)&&(n={path:qp([...l(),r]),name:r,line:i+1,column:a+1}),c.add(r))}},{allowTrailingComma:!0,disallowComments:!1}),n}var qp=e=>"$"+e.map(t=>typeof t=="number"?`[${t}]`:`.${t}`).join("");var Zp="https://quickwatch.app",Xp=`
11
+ .qw-widget { --qw-fg: #1f2328; --qw-muted: #59636e; --qw-line: #d1d9e0; --qw-chip: #f1f3f5; --qw-accent: #0b57d0; --qw-on-accent: #fff;
12
+ color: var(--qw-fg); font: 14px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; display: flex; flex-direction: column;
13
+ align-items: center; gap: 12px; padding: 16px; box-sizing: border-box; color-scheme: light; }
14
+ .qw-widget.qw-dark { color-scheme: dark; --qw-fg: #e6edf3; --qw-muted: #9198a1; --qw-line: #3d444d; --qw-chip: #22272e; --qw-accent: #8ab4f8; --qw-on-accent: #0d1117; }
15
+ .qw-widget * { box-sizing: border-box; }
16
+ .qw-widget .qw-title { font-weight: 600; font-size: 15px; margin: 0; }
17
+ .qw-widget .qw-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
18
+ .qw-widget .qw-chip { font: inherit; font-size: 13px; padding: 5px 12px; border-radius: 999px; border: 1px solid var(--qw-line);
19
+ background: var(--qw-chip); color: var(--qw-fg); cursor: pointer; }
20
+ .qw-widget .qw-chip[aria-pressed="true"] { background: var(--qw-fg); border-color: var(--qw-fg); color: var(--qw-chip); }
21
+ .qw-widget .qw-open { display: inline-block; font-weight: 600; font-size: 14px; padding: 9px 18px; border-radius: 999px;
22
+ background: var(--qw-accent); color: var(--qw-on-accent); text-decoration: none; }
23
+ .qw-widget .qw-open[aria-disabled="true"] { opacity: .5; pointer-events: none; }
24
+ .qw-widget .qw-problems { color: #d93025; font-size: 12px; margin: 0; padding-left: 18px; max-width: 420px; }
25
+ .qw-widget .qw-note { color: var(--qw-muted); font-size: 12px; margin: 0; text-align: center; }
26
+ `;function Yp(e){let t=e.ownerDocument.defaultView;if(!t)return!1;for(let r=e;r;r=r.parentElement){let o=t.getComputedStyle(r).backgroundColor.match(/[\d.]+/g)?.map(Number);if(o&&o.length>=3&&(o[3]??1)>.5)return .2126*o[0]+.7152*o[1]+.0722*o[2]<128}let n=t.getComputedStyle(e.ownerDocument.documentElement).colorScheme;return/dark/.test(n)&&!/light/.test(n)?!0:/light/.test(n)&&!/dark/.test(n)?!1:t.matchMedia("(prefers-color-scheme: dark)").matches}function Or(e,t){return e===void 0?{}:typeof e!="string"?e:Ar(e,t).value??{}}async function ts(e,t,n={}){let{$schema:r,...o}=Or(e,"watch.json"),s=await Pa(o,Or(t,"data.json"));return`${(n.origin??Zp).replace(/\/+$/,"")}/new#c=${s}`}var Da=(e,t)=>{let r=e.experiences?.[t]?.title;if(typeof r=="string"&&!r.includes("{{"))return r;let o=t.replace(/-/g," ");return o.charAt(0).toUpperCase()+o.slice(1)};function _r(e,t,n,r={}){let o=e.ownerDocument,s=(T,Z)=>{let te=o.createElement(T);return te.className=Z,te},i=s("div","qw-widget"),a=s("p","qw-title"),l=s("div","qw-row"),c=s("div","qw-stage"),p=s("div","qw-row"),d=s("ul","qw-problems"),m=s("a","qw-open"),b=s("p","qw-note");m.textContent="Open in QuickWatch",m.target="_blank",m.rel="noopener",b.textContent="Opens the app in QuickWatch, where you can keep it and send it to your watch.",i.append(a,l,c,p,d,m,b);let g=r.appearance??"auto",S=g==="auto"?Yp(e):g==="dark";i.classList.toggle("qw-dark",S),Er(e,Xp).append(i);let _={watch:Or(t,"watch.json"),raw:t,data:n},A=r.experience,J=(T,Z,te)=>{let pe=s("button","qw-chip");return pe.type="button",pe.textContent=T,pe.setAttribute("aria-pressed",String(Z)),pe.onclick=te,pe},w=T=>{let Z=A??T.experiences[0]??"";a.textContent=r.title??(Z?Da(_.watch,Z):"QuickWatch"),l.replaceChildren(...T.experiences.length>1?T.experiences.map(te=>J(Da(_.watch,te),te===Z,()=>y(te))):[]),p.replaceChildren(...T.surfaces.map(te=>J(te.label,te.key===T.surface,()=>T.show(te.key)))),d.replaceChildren(...T.errors.map(te=>{let pe=s("li","");return pe.textContent=te,pe}))},C=T=>{let Z=s("li","");Z.textContent=`The preview failed: ${T instanceof Error?T.message:String(T)}`,d.replaceChildren(Z)},P,x=()=>{try{P?.destroy(),P=ns(c,_.raw,_.data,{size:300,...r,...A?{experience:A}:{},onError:C,onUpdate:T=>{try{w(T)}catch(Z){C(Z)}}}),w(P)}catch(T){C(T)}},y=T=>{A=T,x()},z={get preview(){return P},link:Promise.resolve(""),update(T,Z){_={watch:Or(T,"watch.json"),raw:T,data:Z},P.update(T,Z),w(P),N()},destroy(){P.destroy(),i.remove()}},N=()=>{m.setAttribute("aria-disabled","true"),z.link=ts(_.raw,_.data,r),z.link.then(T=>{m.href=T,m.removeAttribute("aria-disabled")},T=>{b.textContent=T instanceof Dt?T.message:"Could not build the link in this browser."}),z.link.catch(()=>{})};return x(),N(),z}var Va=new WeakSet;function Qp(e){let t=e.getAttribute("data-qw-watch"),n=[...e.ownerDocument.querySelectorAll("script[data-qw-data]")];if(t){let r=n.find(o=>o.getAttribute("data-qw-data")===t);if(r)return r}return n.find(r=>e.compareDocumentPosition(r)&Node.DOCUMENT_POSITION_FOLLOWING)??null}function Kp(e){if(Va.has(e))return;Va.add(e);let t=e.ownerDocument,n=t.querySelector("[data-qw-mount]:not([data-qw-mounted])")??t.createElement("div");n.setAttribute("data-qw-mounted",""),n.isConnected||e.parentNode?.insertBefore(n,e);let r=Qp(e),o={},s=e.getAttribute("data-qw-origin");s&&(o.origin=s),_r(n,e.textContent??"",r?.textContent??void 0,o)}function rs(e=document){for(let t of e.querySelectorAll("script[data-qw-watch]"))Kp(t)}function Ba(){if(typeof document>"u")return;let e=()=>rs();document.readyState==="loading"?document.addEventListener("DOMContentLoaded",e,{once:!0}):e();let t=n=>n instanceof Element&&(n.matches("script[data-qw-watch]")||!!n.querySelector("script[data-qw-watch]"));new MutationObserver(n=>{n.some(r=>[...r.addedNodes].some(t))&&e()}).observe(document.documentElement,{childList:!0,subtree:!0})}var os=`/* The watch renderer's stylesheet (render/). Each component's rules match its scope class (.wb-scope-*, render/scopes.ts
4
27
  * puts it on the component's elements); the platform layer at the end gives the Wear OS look of the goldens.
5
28
  * Fonts: fonts/ (Roboto Flex, OFL). */
6
29
 
@@ -1968,28 +1991,8 @@
1968
1991
  stroke: none;
1969
1992
  }
1970
1993
 
1971
- `;function Ea(e,t){return e<t?-1:e>t?1:0}function*ke(e){switch(e.kind){case"path":yield e;break;case"postfix":yield*ke(e.target);break;case"array":for(let t of e.items)yield*ke(t);break;case"unary":yield*ke(e.operand);break;case"binary":yield*ke(e.left),yield*ke(e.right);break;case"ternary":yield*ke(e.condition),yield*ke(e.then),yield*ke(e.otherwise);break;case"pipeline":yield*ke(e.input);for(let t of e.filters)for(let n of t.args)yield*ke(n);break}}function*Lp(e){for(let t of e.parts)typeof t!="string"&&(yield*ke(t.expr))}function Ma(e){let t=[];for(let n of Lp(e))n.segments[0]==="$secret"&&n.segments.length>1&&typeof n.segments[1]=="string"&&t.push(n.segments[1]);return t}function La(e){let t=new Set;for(let n of Rp(e)){let r=Ui(n);if(r!==null)for(let o of Ma(r))t.add(o)}return[...t].sort(Ea)}function*Rp(e){typeof e.url=="string"&&(yield e.url);for(let t of Object.values(e.headers??{}))typeof t=="string"&&(yield t);yield*Zo(e.body)}function*Zo(e){if(typeof e=="string")yield e;else if(Array.isArray(e))for(let t of e)yield*Zo(t);else if(e!==null&&typeof e=="object")for(let t of Object.values(e))yield*Zo(t)}var Ra="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",$h=Ra+"!$&'()*+,;=:",jh=Ra+"!$'()*,;:@/?";var zh=new TextEncoder;function vr(e,t=!1){let n=e.length,r=0,o="",s=0,i=16,a=0,l=0,c=0,p=0,d=0;function b(w,I){let z=0,x=0;for(;z<w||!I;){let g=e.charCodeAt(r);if(g>=48&&g<=57)x=x*16+g-48;else if(g>=65&&g<=70)x=x*16+g-65+10;else if(g>=97&&g<=102)x=x*16+g-97+10;else break;r++,z++}return z<w&&(x=-1),x}function y(w){r=w,o="",s=0,i=16,d=0}function m(){let w=r;if(e.charCodeAt(r)===48)r++;else for(r++;r<e.length&&Ct(e.charCodeAt(r));)r++;if(r<e.length&&e.charCodeAt(r)===46)if(r++,r<e.length&&Ct(e.charCodeAt(r)))for(r++;r<e.length&&Ct(e.charCodeAt(r));)r++;else return d=3,e.substring(w,r);let I=r;if(r<e.length&&(e.charCodeAt(r)===69||e.charCodeAt(r)===101))if(r++,(r<e.length&&e.charCodeAt(r)===43||e.charCodeAt(r)===45)&&r++,r<e.length&&Ct(e.charCodeAt(r))){for(r++;r<e.length&&Ct(e.charCodeAt(r));)r++;I=r}else d=3;return e.substring(w,I)}function T(){let w="",I=r;for(;;){if(r>=n){w+=e.substring(I,r),d=2;break}let z=e.charCodeAt(r);if(z===34){w+=e.substring(I,r),r++;break}if(z===92){if(w+=e.substring(I,r),r++,r>=n){d=2;break}switch(e.charCodeAt(r++)){case 34:w+='"';break;case 92:w+="\\";break;case 47:w+="/";break;case 98:w+="\b";break;case 102:w+="\f";break;case 110:w+=`
1972
- `;break;case 114:w+="\r";break;case 116:w+=" ";break;case 117:let g=b(4,!0);g>=0?w+=String.fromCharCode(g):d=4;break;default:d=5}I=r;continue}if(z>=0&&z<=31)if(vn(z)){w+=e.substring(I,r),d=2;break}else d=6;r++}return w}function E(){if(o="",d=0,s=r,l=a,p=c,r>=n)return s=n,i=17;let w=e.charCodeAt(r);if(Xo(w)){do r++,o+=String.fromCharCode(w),w=e.charCodeAt(r);while(Xo(w));return i=15}if(vn(w))return r++,o+=String.fromCharCode(w),w===13&&e.charCodeAt(r)===10&&(r++,o+=`
1973
- `),a++,c=r,i=14;switch(w){case 123:return r++,i=1;case 125:return r++,i=2;case 91:return r++,i=3;case 93:return r++,i=4;case 58:return r++,i=6;case 44:return r++,i=5;case 34:return r++,o=T(),i=10;case 47:let I=r-1;if(e.charCodeAt(r+1)===47){for(r+=2;r<n&&!vn(e.charCodeAt(r));)r++;return o=e.substring(I,r),i=12}if(e.charCodeAt(r+1)===42){r+=2;let z=n-1,x=!1;for(;r<z;){let g=e.charCodeAt(r);if(g===42&&e.charCodeAt(r+1)===47){r+=2,x=!0;break}r++,vn(g)&&(g===13&&e.charCodeAt(r)===10&&r++,a++,c=r)}return x||(r++,d=1),o=e.substring(I,r),i=13}return o+=String.fromCharCode(w),r++,i=16;case 45:if(o+=String.fromCharCode(w),r++,r===n||!Ct(e.charCodeAt(r)))return i=16;case 48:case 49:case 50:case 51:case 52:case 53:case 54:case 55:case 56:case 57:return o+=m(),i=11;default:for(;r<n&&O(w);)r++,w=e.charCodeAt(r);if(s!==r){switch(o=e.substring(s,r),o){case"true":return i=8;case"false":return i=9;case"null":return i=7}return i=16}return o+=String.fromCharCode(w),r++,i=16}}function O(w){if(Xo(w)||vn(w))return!1;switch(w){case 125:case 93:case 123:case 91:case 34:case 58:case 44:case 47:return!1}return!0}function j(){let w;do w=E();while(w>=12&&w<=15);return w}return{setPosition:y,getPosition:()=>r,scan:t?j:E,getToken:()=>i,getTokenValue:()=>o,getTokenOffset:()=>s,getTokenLength:()=>r-s,getTokenStartLine:()=>l,getTokenStartCharacter:()=>s-p,getTokenError:()=>d}}function Xo(e){return e===32||e===9}function vn(e){return e===10||e===13}function Ct(e){return e>=48&&e<=57}var Pa;(function(e){e[e.lineFeed=10]="lineFeed",e[e.carriageReturn=13]="carriageReturn",e[e.space=32]="space",e[e._0=48]="_0",e[e._1=49]="_1",e[e._2=50]="_2",e[e._3=51]="_3",e[e._4=52]="_4",e[e._5=53]="_5",e[e._6=54]="_6",e[e._7=55]="_7",e[e._8=56]="_8",e[e._9=57]="_9",e[e.a=97]="a",e[e.b=98]="b",e[e.c=99]="c",e[e.d=100]="d",e[e.e=101]="e",e[e.f=102]="f",e[e.g=103]="g",e[e.h=104]="h",e[e.i=105]="i",e[e.j=106]="j",e[e.k=107]="k",e[e.l=108]="l",e[e.m=109]="m",e[e.n=110]="n",e[e.o=111]="o",e[e.p=112]="p",e[e.q=113]="q",e[e.r=114]="r",e[e.s=115]="s",e[e.t=116]="t",e[e.u=117]="u",e[e.v=118]="v",e[e.w=119]="w",e[e.x=120]="x",e[e.y=121]="y",e[e.z=122]="z",e[e.A=65]="A",e[e.B=66]="B",e[e.C=67]="C",e[e.D=68]="D",e[e.E=69]="E",e[e.F=70]="F",e[e.G=71]="G",e[e.H=72]="H",e[e.I=73]="I",e[e.J=74]="J",e[e.K=75]="K",e[e.L=76]="L",e[e.M=77]="M",e[e.N=78]="N",e[e.O=79]="O",e[e.P=80]="P",e[e.Q=81]="Q",e[e.R=82]="R",e[e.S=83]="S",e[e.T=84]="T",e[e.U=85]="U",e[e.V=86]="V",e[e.W=87]="W",e[e.X=88]="X",e[e.Y=89]="Y",e[e.Z=90]="Z",e[e.asterisk=42]="asterisk",e[e.backslash=92]="backslash",e[e.closeBrace=125]="closeBrace",e[e.closeBracket=93]="closeBracket",e[e.colon=58]="colon",e[e.comma=44]="comma",e[e.dot=46]="dot",e[e.doubleQuote=34]="doubleQuote",e[e.minus=45]="minus",e[e.openBrace=123]="openBrace",e[e.openBracket=91]="openBracket",e[e.plus=43]="plus",e[e.slash=47]="slash",e[e.formFeed=12]="formFeed",e[e.tab=9]="tab"})(Pa||(Pa={}));var Np=new Array(20).fill(0).map((e,t)=>" ".repeat(t)),It=200,$p={" ":{"\n":new Array(It).fill(0).map((e,t)=>`
1974
- `+" ".repeat(t)),"\r":new Array(It).fill(0).map((e,t)=>"\r"+" ".repeat(t)),"\r\n":new Array(It).fill(0).map((e,t)=>`\r
1975
- `+" ".repeat(t))}," ":{"\n":new Array(It).fill(0).map((e,t)=>`
1976
- `+" ".repeat(t)),"\r":new Array(It).fill(0).map((e,t)=>"\r"+" ".repeat(t)),"\r\n":new Array(It).fill(0).map((e,t)=>`\r
1977
- `+" ".repeat(t))}};var xr;(function(e){e.DEFAULT={allowTrailingComma:!1}})(xr||(xr={}));function Yo(e,t=[],n=xr.DEFAULT){let r={type:"array",offset:-1,length:-1,children:[],parent:void 0};function o(l){r.type==="property"&&(r.length=l-r.offset,r=r.parent)}function s(l){return r.children.push(l),l}Qo(e,{onObjectBegin:l=>{r=s({type:"object",offset:l,length:-1,parent:r,children:[]})},onObjectProperty:(l,c,p)=>{r=s({type:"property",offset:c,length:-1,parent:r,children:[]}),r.children.push({type:"string",value:l,offset:c,length:p,parent:r})},onObjectEnd:(l,c)=>{o(l+c),r.length=l+c-r.offset,r=r.parent,o(l+c)},onArrayBegin:(l,c)=>{r=s({type:"array",offset:l,length:-1,parent:r,children:[]})},onArrayEnd:(l,c)=>{r.length=l+c-r.offset,r=r.parent,o(l+c)},onLiteralValue:(l,c,p)=>{s({type:zp(l),offset:c,length:p,parent:r,value:l}),o(c+p)},onSeparator:(l,c,p)=>{r.type==="property"&&(l===":"?r.colonOffset=c:l===","&&o(c))},onError:(l,c,p)=>{t.push({error:l,offset:c,length:p})}},n);let a=r.children[0];return a&&delete a.parent,a}function Qo(e,t,n=xr.DEFAULT){let r=vr(e,!1),o=[],s=0;function i(N){return N?()=>s===0&&N(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter()):()=>!0}function a(N){return N?Z=>s===0&&N(Z,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter()):()=>!0}function l(N){return N?Z=>s===0&&N(Z,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter(),()=>o.slice()):()=>!0}function c(N){return N?()=>{s>0?s++:N(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter(),()=>o.slice())===!1&&(s=1)}:()=>!0}function p(N){return N?()=>{s>0&&s--,s===0&&N(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter())}:()=>!0}let d=c(t.onObjectBegin),b=l(t.onObjectProperty),y=p(t.onObjectEnd),m=c(t.onArrayBegin),T=p(t.onArrayEnd),E=l(t.onLiteralValue),O=a(t.onSeparator),j=i(t.onComment),w=a(t.onError),I=n&&n.disallowComments,z=n&&n.allowTrailingComma;function x(){for(;;){let N=r.scan();switch(r.getTokenError()){case 4:g(14);break;case 5:g(15);break;case 3:g(13);break;case 1:I||g(11);break;case 2:g(12);break;case 6:g(16);break}switch(N){case 12:case 13:I?g(10):j();break;case 16:g(1);break;case 15:case 14:break;default:return N}}}function g(N,Z=[],os=[]){if(w(N),Z.length+os.length>0){let xn=r.getToken();for(;xn!==17;){if(Z.indexOf(xn)!==-1){x();break}else if(os.indexOf(xn)!==-1)break;xn=x()}}}function M(N){let Z=r.getTokenValue();return N?E(Z):(b(Z),o.push(Z)),x(),!0}function S(){switch(r.getToken()){case 11:let N=r.getTokenValue(),Z=Number(N);isNaN(Z)&&(g(2),Z=0),E(Z);break;case 7:E(null);break;case 8:E(!0);break;case 9:E(!1);break;default:return!1}return x(),!0}function J(){return r.getToken()!==10?(g(3,[],[2,5]),!1):(M(!1),r.getToken()===6?(O(":"),x(),Er()||g(4,[],[2,5])):g(5,[],[2,5]),o.pop(),!0)}function _r(){d(),x();let N=!1;for(;r.getToken()!==2&&r.getToken()!==17;){if(r.getToken()===5){if(N||g(4,[],[]),O(","),x(),r.getToken()===2&&z)break}else N&&g(6,[],[]);J()||g(4,[],[2,5]),N=!0}return y(),r.getToken()!==2?g(7,[2],[]):x(),!0}function ol(){m(),x();let N=!0,Z=!1;for(;r.getToken()!==4&&r.getToken()!==17;){if(r.getToken()===5){if(Z||g(4,[],[]),O(","),x(),r.getToken()===4&&z)break}else Z&&g(6,[],[]);N?(o.push(0),N=!1):o[o.length-1]++,Er()||g(4,[],[4,5]),Z=!0}return T(),N||o.pop(),r.getToken()!==4?g(8,[4],[]):x(),!0}function Er(){switch(r.getToken()){case 3:return ol();case 1:return _r();case 10:return M(!0);default:return S()}}return x(),r.getToken()===17?n.allowEmptyContent?!0:(g(4,[],[]),!1):Er()?(r.getToken()!==17&&g(9,[],[]),!0):(g(4,[],[]),!1)}function zp(e){switch(typeof e){case"boolean":return"boolean";case"number":return"number";case"string":return"string";case"object":{if(e){if(Array.isArray(e))return"array"}else return"null";return"object"}default:return"null"}}var Na;(function(e){e[e.None=0]="None",e[e.UnexpectedEndOfComment=1]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=2]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=3]="UnexpectedEndOfNumber",e[e.InvalidUnicode=4]="InvalidUnicode",e[e.InvalidEscapeCharacter=5]="InvalidEscapeCharacter",e[e.InvalidCharacter=6]="InvalidCharacter"})(Na||(Na={}));var $a;(function(e){e[e.OpenBraceToken=1]="OpenBraceToken",e[e.CloseBraceToken=2]="CloseBraceToken",e[e.OpenBracketToken=3]="OpenBracketToken",e[e.CloseBracketToken=4]="CloseBracketToken",e[e.CommaToken=5]="CommaToken",e[e.ColonToken=6]="ColonToken",e[e.NullKeyword=7]="NullKeyword",e[e.TrueKeyword=8]="TrueKeyword",e[e.FalseKeyword=9]="FalseKeyword",e[e.StringLiteral=10]="StringLiteral",e[e.NumericLiteral=11]="NumericLiteral",e[e.LineCommentTrivia=12]="LineCommentTrivia",e[e.BlockCommentTrivia=13]="BlockCommentTrivia",e[e.LineBreakTrivia=14]="LineBreakTrivia",e[e.Trivia=15]="Trivia",e[e.Unknown=16]="Unknown",e[e.EOF=17]="EOF"})($a||($a={}));var za=Yo;var Ca=Qo;var ja;(function(e){e[e.InvalidSymbol=1]="InvalidSymbol",e[e.InvalidNumberFormat=2]="InvalidNumberFormat",e[e.PropertyNameExpected=3]="PropertyNameExpected",e[e.ValueExpected=4]="ValueExpected",e[e.ColonExpected=5]="ColonExpected",e[e.CommaExpected=6]="CommaExpected",e[e.CloseBraceExpected=7]="CloseBraceExpected",e[e.CloseBracketExpected=8]="CloseBracketExpected",e[e.EndOfFileExpected=9]="EndOfFileExpected",e[e.InvalidCommentToken=10]="InvalidCommentToken",e[e.UnexpectedEndOfComment=11]="UnexpectedEndOfComment",e[e.UnexpectedEndOfString=12]="UnexpectedEndOfString",e[e.UnexpectedEndOfNumber=13]="UnexpectedEndOfNumber",e[e.InvalidUnicode=14]="InvalidUnicode",e[e.InvalidEscapeCharacter=15]="InvalidEscapeCharacter",e[e.InvalidCharacter=16]="InvalidCharacter"})(ja||(ja={}));function Ia(e){switch(e){case 1:return"InvalidSymbol";case 2:return"InvalidNumberFormat";case 3:return"PropertyNameExpected";case 4:return"ValueExpected";case 5:return"ColonExpected";case 6:return"CommaExpected";case 7:return"CloseBraceExpected";case 8:return"CloseBracketExpected";case 9:return"EndOfFileExpected";case 10:return"InvalidCommentToken";case 11:return"UnexpectedEndOfComment";case 12:return"UnexpectedEndOfString";case 13:return"UnexpectedEndOfNumber";case 14:return"InvalidUnicode";case 15:return"InvalidEscapeCharacter";case 16:return"InvalidCharacter"}return"<unknown ParseErrorCode>"}var F=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function kr(e,t){let n=t==="data.json"?{file:t}:{};if(!e||!e.trim())return t==="data.json"?{value:{},issues:[]}:{value:null,issues:[{path:"$",rule:"json-syntax",message:"watch.json is empty.",allowed:[],severity:"error"}]};let r=[],o=za(e,r,{allowTrailingComma:!0,disallowComments:!1});if(r.length||!o){let i=r[0],{line:a,column:l}=Bp(e,i?.offset??0),c=i?Vp(Ia(i.error)):"unexpected end of the text";return{value:null,issues:[{path:"$",rule:"json-syntax",message:`Invalid JSON (line ${a}, column ${l}): ${c}.`,allowed:[],severity:"error",...n,line:a,column:l}]}}let s=Fp(e);return s?{value:null,issues:[{path:s.path,rule:"json-syntax",message:`Invalid JSON (line ${s.line}, column ${s.column}): '${s.name}' appears twice in the same object.`,allowed:[],severity:"error",...n,line:s.line,column:s.column}]}:o.type!=="object"?{value:null,issues:[{path:"$",rule:"json-type",message:t==="data.json"?"data.json must be an object keyed by source name.":"watch.json must be a JSON object.",allowed:[],severity:"error",...n,line:1,column:1}]}:{value:Ko(o),issues:[]}}function Ko(e){switch(e.type){case"object":{let t={};for(let n of e.children??[]){let[r,o]=n.children??[];r&&o&&(t[r.value]=Ko(o))}return t}case"array":return(e.children??[]).map(Ko);default:return e.value}}var Vp=e=>e.replace(/([a-z])([A-Z])/g,"$1 $2").toLowerCase();function Bp(e,t){let n=1,r=0;for(let o=0;o<t&&o<e.length;o++)e[o]===`
1978
- `&&(n++,r=o+1);return{line:n,column:t-r+1}}function Fp(e){let t=[],n=null;return Ca(e,{onObjectBegin:()=>{t.push(new Set)},onObjectEnd:()=>{t.pop()},onObjectProperty:(r,o,s,i,a,l)=>{let c=t[t.length-1];!c||n||(c.has(r)&&(n={path:Up([...l(),r]),name:r,line:i+1,column:a+1}),c.add(r))}},{allowTrailingComma:!0,disallowComments:!1}),n}var Up=e=>"$"+e.map(t=>typeof t=="number"?`[${t}]`:`.${t}`).join("");var Jt={maxBundleBytes:256*1024,maxSampleBytes:16*1024,maxAssets:8,maxAssetBytes:256*1024},Hp="Europe/Stockholm",Wp=10,Da=e=>new TextEncoder().encode(e).length,Gp=e=>"src_local_"+e.toLowerCase().replace(/[^a-z0-9_]/g,"_"),W=e=>typeof e=="string"?e:typeof e=="number"||typeof e=="boolean"?String(e):void 0,Tr=(e,t)=>e<t?-1:e>t?1:0;function Ye(e){let t={};for(let[n,r]of Object.entries(e))r!=null&&(t[n]=r);return t}var Va=e=>Object.fromEntries(Object.keys(e).sort(Tr).map(t=>[t,e[t]])),qp=new Set(["maxLines","maxRows","take"]),Zp=new Set(["confirm"]);function Sr(e,t){if(e!=null){if(t==="items"){if(typeof e=="string")return{bind:e};if(F(e))return Ye({bind:W(e.bind),take:typeof e.take=="number"?e.take:void 0})}if(Array.isArray(e))return e.map(n=>Sr(n)??null);if(F(e)){let n=["type","id",...Object.keys(e).filter(o=>o!=="type"&&o!=="id")],r={};for(let o of n){let s=Sr(e[o],o);s!==void 0&&(r[o]=s)}return r}return t!==void 0&&(qp.has(t)||Zp.has(t))?e:W(e)}}var Xp=["title","icon","url","text","value","unit","label","detail","trend","state","min","max","items","item","emptyText","buttons","toggle"];function Ja(e,t){let n={opens:W(e.opens)??t,template:W(e.template),kind:W(e.kind)};for(let r of Xp)n[r]=Sr(e[r],r);return Ye(n)}function Ba(e,t,n,r){let s=(F(e.experiences)?e.experiences:{})[n];if(!F(s))throw new Error(`The project has no Experience '${n}'.`);let i=F(e.sources)?e.sources:{},a=F(e.actions)?e.actions:{},l=[],c=F(s.pages)?s.pages:{},p=W(s.main)??Object.keys(c)[0]??"",d={};for(let[M,S]of Object.entries(c))d[M]=Sr(S)??{};let b=Ja(F(s.tile)?s.tile:{template:"text"},p),y=F(s.complication)?Ja(s.complication,p):void 0,m=Ye({title:W(s.title)??n,subtitle:W(s.subtitle),icon:W(s.icon),iconUrl:W(s.iconUrl),description:W(s.description)}),T=[d,b,y??null,m],E=new Set;es(T,E,a);let O=new Set;Ar(T,O,i);for(let M of E){let S=a[M];typeof S.source=="string"&&S.source in i&&O.add(S.source);for(let J of Array.isArray(S.refresh)?S.refresh:[])typeof J=="string"&&J in i&&O.add(J);Ar([S.confirm??null,S.toast??null],O,i)}let j={};for(let M of Object.keys(i).filter(S=>O.has(S)).sort(Tr))j[M]=Yp(M,i[M],e,r);let w={};for(let M of[...E].sort(Tr))w[M]=Qp(a[M],e);let I=Kp(T),z=Ye({bundleVersion:1,schemaVersion:2,engine:1,experienceId:r.experienceId,localId:n,projectId:r.projectId,version:r.version,publishedAt:r.publishedAt===void 0?void 0:qt(r.publishedAt),timeZone:W(e.timeZone)??Hp,entry:m,main:p,pages:d,tile:b,complication:y,sources:j,actions:w,assets:I.length?I:void 0,sample:eu(t,Object.keys(j),l)}),x=JSON.stringify(z),g=Da(x);return g>Jt.maxBundleBytes&&l.push({path:`$.experiences.${n}`,rule:"bundle-too-large",message:`The bundle of '${n}' is ${Math.floor(g/1024)} KiB; the limit is ${Jt.maxBundleBytes/1024} KiB.`,allowed:[],severity:"error"}),{bundle:z,json:x,bytes:g,issues:l}}function Fa(e,t){if(!(!F(e)&&!F(t)))return Va({...F(e)?e:{},...F(t)?t:{}})}function Ua(e,t){let n=F(t.headers)&&Object.keys(t.headers).length?Va(t.headers):void 0;return Ye({method:e,url:W(t.url)??"",headers:n,body:t.body,timeoutSeconds:Wp})}var Ha=e=>{let t=La({url:W(e.url),headers:F(e.headers)?e.headers:void 0,body:e.body});return t.length?t:void 0};function Yp(e,t,n,r){let o=r.sourceRefs?.[e]??Gp(e),s=t.mode==="direct",i=W(t.push)??(s?"signal":"values"),a=F(t.refresh)?t.refresh:void 0;return Ye(s?{mode:"direct",ref:o,refresh:a,push:i,request:Ua(W(t.method)??"GET",t),params:Fa(n.params,t.params),secrets:Ha(t),map:t.map}:{mode:"proxied",ref:o,refresh:a,push:i})}function Qp(e,t){let n=W(e.type)??"http",r=W(e.mode)??"proxied",o=n==="http"&&r==="direct";return Ye({kind:n,mode:n==="http"?r:void 0,source:W(e.source),screen:W(e.screen),confirm:W(e.confirm),toast:F(e.toast)?e.toast:void 0,refresh:Array.isArray(e.refresh)&&e.refresh.length?e.refresh:void 0,request:o?Ua(W(e.method)??"POST",e):void 0,params:o?Fa(t.params,e.params):void 0,secrets:o?Ha(e):void 0})}function es(e,t,n){if(Array.isArray(e))e.forEach(r=>es(r,t,n));else if(F(e))for(let[r,o]of Object.entries(e))(r==="action"||r==="onAction"||r==="offAction")&&typeof o=="string"&&F(n[o])&&t.add(o),es(o,t,n)}function Ar(e,t,n){let r=o=>{for(let s of Et(o,!0,i=>i in n))s in n&&t.add(s)};if(Array.isArray(e))e.forEach(o=>Ar(o,t,n));else if(F(e))for(let[o,s]of Object.entries(e))o==="bind"&&typeof s=="string"?r(s.trimStart().startsWith("{{")?s:`{{ ${s} }}`):Ar(s,t,n);else typeof e=="string"&&e.includes("{{")&&r(e)}function Kp(e){let t=new Set,n=r=>{if(Array.isArray(r))r.forEach(n);else if(F(r))for(let[o,s]of Object.entries(r))(o==="url"||o==="iconUrl")&&typeof s=="string"&&!s.includes("{{")&&Lt(s)&&t.add(s),n(s)};return n(e),[...t].sort(Tr).slice(0,Jt.maxAssets).map(r=>({url:r,maxBytes:Jt.maxAssetBytes}))}function eu(e,t,n){if(!e)return;let r={};for(let s of t)s in e&&e[s]!==void 0&&(r[s]=structuredClone(e[s]));if(!Object.keys(r).length)return;let o=!1;for(;Da(JSON.stringify(r))>Jt.maxSampleBytes;){let s=tu(r);if(s)s.splice(s.length-Math.max(1,Math.floor(s.length/8)));else{let i=Object.keys(r).sort((a,l)=>JSON.stringify(r[l]).length-JSON.stringify(r[a]).length)[0];delete r[i]}o=!0}return o&&n.push({path:"$",rule:"sample-truncated",message:`The sample data was cut to ${Jt.maxSampleBytes/1024} KiB for the bundle (it is shipped to the watch).`,allowed:[],severity:"warning",file:"data.json"}),Object.keys(r).length?r:void 0}function tu(e){let t=null,n=0,r=o=>{if(Array.isArray(o)){let s=JSON.stringify(o).length;o.length&&s>n&&([t,n]=[o,s]),o.forEach(r)}else F(o)&&Object.values(o).forEach(r)};return r(e),t}var Wa={$schema:"../device-profile.schema.json",id:"galaxy-watch",name:"Galaxy Watch 44mm",platform:"wear",measured:!1,source:"Public specs for Galaxy Watch4/5 44mm, Watch4 Classic 46mm and Watch5 Pro (450x450, about 321 ppi, assumed xhdpi = density 2.0), as docs/wear-tokens.md. Not verified: one report says a Galaxy Watch4 returns wm density 340 (2.125, 212dp, a small screen). Measure with adb shell wm size / wm density on a real watch (plan step 8) and then set measured to true. Tile slots, complication behaviour and limits are what the Wear app does today.",screen:{shape:"round",widthPx:450,heightPx:450,density:2,widthDp:225,heightDp:225,sizeClass:"large",caseMm:44},insets:{safe:33,screenHorizontal:12,screenTop:30,screenBottom:52,tileHorizontal:16},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system (One UI Watch font, not measured)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:8,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:8},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (8 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:8}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},LONG_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},RANGED_VALUE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},SMALL_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},MONOCHROMATIC_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var Ga={$schema:"../device-profile.schema.json",id:"pixel-watch",name:"Pixel Watch 3 41mm",platform:"wear",measured:!1,source:"Public specs for Pixel Watch 3 41mm (408x408 px; Google lists 320 ppi, assumed xhdpi = density 2.0, 204dp, a small screen). Not verified on a watch: measure with adb shell wm size / wm density and then set measured to true. Tile and complication behaviour are what the Wear app does today.",screen:{shape:"round",widthPx:408,heightPx:408,density:2,widthDp:204,heightDp:204,sizeClass:"small",caseMm:41},insets:{safe:30,screenHorizontal:11,screenTop:27,screenBottom:47,tileHorizontal:15},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system (Google Sans Flex on Pixel Watch, not measured)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:6,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:6},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (6 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:6}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},LONG_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},RANGED_VALUE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},SMALL_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},MONOCHROMATIC_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var qa={$schema:"../device-profile.schema.json",id:"wear-large-round",name:"Wear OS Large Round (emulator)",platform:"wear",measured:!0,source:"Android Studio device definition 'Wear OS Large Round' (454x454 px, xhdpi; the AVD Wear_OS_Large_Round has hw.lcd 454x454 at 320 dpi, sdklib devices/wear.xml) and the Wear app rendered under Robolectric with these qualifiers.",screen:{shape:"round",widthPx:454,heightPx:454,density:2,widthDp:227,heightDp:227,sizeClass:"large"},insets:{safe:34,screenHorizontal:12,screenTop:30,screenBottom:53,tileHorizontal:17},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system font (Roboto on the emulator image; Robolectric's system font in the JVM goldens)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:8,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:8},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (8 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:8}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported"},LONG_TEXT:{support:"supported"},RANGED_VALUE:{support:"supported"},SMALL_IMAGE:{support:"supported"},MONOCHROMATIC_IMAGE:{support:"supported"},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var Za={$schema:"../device-profile.schema.json",id:"wear-small-round",name:"Wear OS Small Round (emulator)",platform:"wear",measured:!0,source:"Android Studio device definition 'Wear OS Small Round' (384x384 px, xhdpi, sdklib devices/wear.xml) and the Wear app rendered under Robolectric with these qualifiers.",screen:{shape:"round",widthPx:384,heightPx:384,density:2,widthDp:192,heightDp:192,sizeClass:"small",caseMm:40},insets:{safe:29,screenHorizontal:10,screenTop:25,screenBottom:45,tileHorizontal:14},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system font (Roboto on the emulator image; Robolectric's system font in the JVM goldens)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:6,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:6},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (6 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:6}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported"},LONG_TEXT:{support:"supported"},RANGED_VALUE:{support:"supported"},SMALL_IMAGE:{support:"supported"},MONOCHROMATIC_IMAGE:{support:"supported"},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var Xa={$schema:"../device-profile.schema.json",id:"wear-square",name:"Wear OS Square (emulator)",platform:"wear",measured:!0,source:"Android Studio device definition 'Wear OS Square' (360x360 px, xhdpi, sdklib devices/wear.xml) and the Wear app rendered under Robolectric with these qualifiers.",screen:{shape:"square",widthPx:360,heightPx:360,density:2,widthDp:180,heightDp:180,sizeClass:"small"},insets:{safe:0,screenHorizontal:10,screenTop:24,screenBottom:42,tileHorizontal:13},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system font (Roboto on the emulator image; Robolectric's system font in the JVM goldens)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:6,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:6},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring is drawn as a circle inside the square screen, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (6 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:6}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported"},LONG_TEXT:{support:"supported"},RANGED_VALUE:{support:"supported"},SMALL_IMAGE:{support:"supported"},MONOCHROMATIC_IMAGE:{support:"supported"},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var Dt=class extends Error{};function au(e){let t="";for(let n=0;n<e.length;n+=32768)t+=String.fromCharCode(...e.subarray(n,n+32768));return btoa(t).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function lu(e,t){let n=e.getReader(),r=[],o=0;for(;;){let{done:a,value:l}=await n.read();if(a)break;if(o+=l.length,o>t)throw n.cancel().catch(()=>{}),new Dt(`The project in the link is larger than ${t/1024} KB.`);r.push(l)}let s=new Uint8Array(o),i=0;for(let a of r)s.set(a,i),i+=a.length;return s}async function Ya(e,t={}){let n=new TextEncoder().encode(JSON.stringify({v:1,config:e,data:t}));if(n.length>32768)throw new Dt(`The project is ${(n.length/1024).toFixed(1)} KB as JSON; a link holds at most ${32768/1024} KB.`);return au(await lu(new Blob([n]).stream().pipeThrough(new CompressionStream("deflate-raw")),Number.MAX_SAFE_INTEGER))}var cu="https://quickwatch.app",pu=`
1979
- .qw-widget { --qw-fg: #1f2328; --qw-muted: #59636e; --qw-line: #d1d9e0; --qw-chip: #f1f3f5; --qw-accent: #0b57d0; --qw-on-accent: #fff;
1980
- color: var(--qw-fg); font: 14px/1.4 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; display: flex; flex-direction: column;
1981
- align-items: center; gap: 12px; padding: 16px; box-sizing: border-box; }
1982
- @media (prefers-color-scheme: dark) { .qw-widget { --qw-fg: #e6edf3; --qw-muted: #9198a1; --qw-line: #3d444d; --qw-chip: #22272e; --qw-accent: #8ab4f8; --qw-on-accent: #0d1117; } }
1983
- .qw-widget * { box-sizing: border-box; }
1984
- .qw-widget .qw-title { font-weight: 600; font-size: 15px; margin: 0; }
1985
- .qw-widget .qw-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
1986
- .qw-widget .qw-chip { font: inherit; font-size: 13px; padding: 5px 12px; border-radius: 999px; border: 1px solid var(--qw-line);
1987
- background: var(--qw-chip); color: var(--qw-fg); cursor: pointer; }
1988
- .qw-widget .qw-chip[aria-pressed="true"] { background: var(--qw-fg); border-color: var(--qw-fg); color: var(--qw-chip); }
1989
- .qw-widget .qw-open { display: inline-block; font-weight: 600; font-size: 14px; padding: 9px 18px; border-radius: 999px;
1990
- background: var(--qw-accent); color: var(--qw-on-accent); text-decoration: none; }
1991
- .qw-widget .qw-open[aria-disabled="true"] { opacity: .5; pointer-events: none; }
1992
- .qw-widget .qw-problems { color: #d93025; font-size: 12px; margin: 0; padding-left: 18px; max-width: 420px; }
1993
- .qw-widget .qw-note { color: var(--qw-muted); font-size: 12px; margin: 0; text-align: center; }
1994
- `;function uu(e){if(e.getElementById("quickwatch-widget-css"))return;let t=e.createElement("style");t.id="quickwatch-widget-css",t.textContent=pu,e.head.appendChild(t)}function Or(e,t){return e===void 0?{}:typeof e!="string"?e:kr(e,t).value??{}}async function ts(e,t,n={}){let{$schema:r,...o}=Or(e,"watch.json"),s=await Ya(o,Or(t,"data.json"));return`${(n.origin??cu).replace(/\/+$/,"")}/new#c=${s}`}var Qa=(e,t)=>{let r=e.experiences?.[t]?.title;if(typeof r=="string"&&!r.includes("{{"))return r;let o=t.replace(/-/g," ");return o.charAt(0).toUpperCase()+o.slice(1)};function Ka(e,t,n,r={}){let o=e.ownerDocument;uu(o);let s=(g,M)=>{let S=o.createElement(g);return S.className=M,S},i=s("div","qw-widget"),a=s("p","qw-title"),l=s("div","qw-row"),c=s("div","qw-stage"),p=s("div","qw-row"),d=s("ul","qw-problems"),b=s("a","qw-open"),y=s("p","qw-note");b.textContent="Open in QuickWatch",b.target="_blank",b.rel="noopener",y.textContent="Opens the app in QuickWatch, where you can keep it and send it to your watch.",i.append(a,l,c,p,d,b,y),e.replaceChildren(i);let m={watch:Or(t,"watch.json"),raw:t,data:n},T=r.experience,E=(g,M,S)=>{let J=s("button","qw-chip");return J.type="button",J.textContent=g,J.setAttribute("aria-pressed",String(M)),J.onclick=S,J},O=g=>{let M=T??g.experiences[0]??"";a.textContent=r.title??(M?Qa(m.watch,M):"QuickWatch"),l.replaceChildren(...g.experiences.length>1?g.experiences.map(S=>E(Qa(m.watch,S),S===M,()=>I(S))):[]),p.replaceChildren(...g.surfaces.map(S=>E(S.label,S.key===g.surface,()=>g.show(S.key)))),d.replaceChildren(...g.errors.map(S=>{let J=s("li","");return J.textContent=S,J}))},j,w=()=>{j?.destroy(),j=ns(c,m.raw,m.data,{size:300,...r,...T?{experience:T}:{},onUpdate:O}),O(j)},I=g=>{T=g,w()},z={get preview(){return j},link:Promise.resolve(""),update(g,M){m={watch:Or(g,"watch.json"),raw:g,data:M},j.update(g,M),O(j),x()},destroy(){j.destroy(),i.remove()}},x=()=>{b.setAttribute("aria-disabled","true"),z.link=ts(m.raw,m.data,r),z.link.then(g=>{b.href=g,b.removeAttribute("aria-disabled")},g=>{y.textContent=g instanceof Dt?g.message:"Could not build the link in this browser."}),z.link.catch(()=>{})};return w(),x(),z}var rs=[Wa,Ga,qa,Za,Xa],du="0.2.0",rl=rs.map(e=>e.id),fu=xt.map(e=>e.id),el=typeof document<"u"&&document.currentScript instanceof HTMLScriptElement?document.currentScript.src:"";function hu(e){if(e.getElementById("quickwatch-preview-css"))return;let t=e.createElement("style");t.id="quickwatch-preview-css",t.textContent=el?qo.replace(/url\('fonts\//g,`url('${new URL("fonts/",el).href}`):qo.replace(/@font-face\s*\{[^}]*\}/g,""),e.head.appendChild(t)}function tl(e,t,n){if(e===void 0)return{};if(typeof e!="string")return e;let r=kr(e,t);for(let o of r.issues)n.push(`${t}: ${o.message}`);return r.value&&typeof r.value=="object"&&!Array.isArray(r.value)?r.value:null}function nl(e,t){let n=[],r=tl(e,"watch.json",n),o=tl(t,"data.json",n),s=r&&typeof r.experiences=="object"&&r.experiences&&!Array.isArray(r.experiences)?r.experiences:{},i=[];if(r)for(let[a,l]of Object.entries(s))try{let c=Ba(r,o??{},a,{experienceId:`draft_${a}`,version:0}),p=l&&typeof l=="object"&&!Array.isArray(l)?l.theme:void 0;i.push({key:a,label:a,bundle:c.bundle,theme:Ur(p).theme})}catch(c){n.push(`${a}: ${c instanceof Error?c.message:String(c)}`)}return r&&!Object.keys(s).length&&n.push("watch.json: no experiences"),{list:i,errors:n}}function ns(e,t,n,r={}){hu(e.ownerDocument);let o=rs.find(d=>d.id===r.device)??rs[0],s=r.size?r.size/o.screen.widthDp:1,{list:i,errors:a}=nl(t,n),l=null,c={get experiences(){return i.map(d=>d.key)},get surfaces(){return(l?.surfaces??[]).map(d=>({key:d.key,label:d.label,kind:d.kind}))},get surface(){return l?.surface??""},get errors(){return a},show(d){l?.command({type:"surface",surface:d})},update(d,b){({list:i,errors:a}=nl(d,b)),l&&i.length?l.setPayload({payloadVersion:1,experiences:i}):p()},destroy(){l?.destroy(),l=null}};function p(){if(l?.destroy(),l=null,!i.length){e.textContent=a.join(`
1995
- `)||"Nothing to show.";return}l=Go(e,{payloadVersion:1,experiences:i},{...r.experience?{experience:r.experience}:{},...r.surface?{surface:r.surface}:{},device:o.id,theme:r.theme??"auto",data:r.data??"sample",ambient:r.ambient??!1,devices:rl,...r.onUpdate?{onUpdate:()=>r.onUpdate(c)}:{},engine:{resolve:(d,b,y,m)=>gn(pr(d,b,y,m),o).view,render:(d,b)=>ni(e,d,{...b,deviceProfile:$o(o),scale:s,frame:r.frame??!0,idPrefix:"qwp"})}})}return p(),c}return ul(mu);})();
1994
+ `;function Fa(e,t){return e<t?-1:e>t?1:0}function*Ae(e){switch(e.kind){case"path":yield e;break;case"postfix":yield*Ae(e.target);break;case"array":for(let t of e.items)yield*Ae(t);break;case"unary":yield*Ae(e.operand);break;case"binary":yield*Ae(e.left),yield*Ae(e.right);break;case"ternary":yield*Ae(e.condition),yield*Ae(e.then),yield*Ae(e.otherwise);break;case"pipeline":yield*Ae(e.input);for(let t of e.filters)for(let n of t.args)yield*Ae(n);break}}function*tu(e){for(let t of e.parts)typeof t!="string"&&(yield*Ae(t.expr))}function Ua(e){let t=[];for(let n of tu(e))n.segments[0]==="$secret"&&n.segments.length>1&&typeof n.segments[1]=="string"&&t.push(n.segments[1]);return t}function Ha(e){let t=new Set;for(let n of nu(e)){let r=qi(n);if(r!==null)for(let o of Ua(r))t.add(o)}return[...t].sort(Fa)}function*nu(e){typeof e.url=="string"&&(yield e.url);for(let t of Object.values(e.headers??{}))typeof t=="string"&&(yield t);yield*ss(e.body)}function*ss(e){if(typeof e=="string")yield e;else if(Array.isArray(e))for(let t of e)yield*ss(t);else if(e!==null&&typeof e=="object")for(let t of Object.values(e))yield*ss(t)}var Wa="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",mm=Wa+"!$&'()*+,;=:",gm=Wa+"!$'()*,;:@/?";var bm=new TextEncoder;var Ft={maxBundleBytes:256*1024,maxSampleBytes:16*1024,maxAssets:8,maxAssetBytes:256*1024},ru="Europe/Stockholm",ou=10,qa=e=>new TextEncoder().encode(e).length,su=e=>"src_local_"+e.toLowerCase().replace(/[^a-z0-9_]/g,"_"),W=e=>typeof e=="string"?e:typeof e=="number"||typeof e=="boolean"?String(e):void 0,Mr=(e,t)=>e<t?-1:e>t?1:0;function et(e){let t={};for(let[n,r]of Object.entries(e))r!=null&&(t[n]=r);return t}var Za=e=>Object.fromEntries(Object.keys(e).sort(Mr).map(t=>[t,e[t]])),iu=new Set(["maxLines","maxRows","take"]),au=new Set(["confirm"]);function Lr(e,t){if(e!=null){if(t==="items"){if(typeof e=="string")return{bind:e};if(F(e))return et({bind:W(e.bind),take:typeof e.take=="number"?e.take:void 0})}if(Array.isArray(e))return e.map(n=>Lr(n)??null);if(F(e)){let n=["type","id",...Object.keys(e).filter(o=>o!=="type"&&o!=="id")],r={};for(let o of n){let s=Lr(e[o],o);s!==void 0&&(r[o]=s)}return r}return t!==void 0&&(iu.has(t)||au.has(t))?e:W(e)}}var lu=["title","icon","url","text","value","unit","label","detail","trend","state","min","max","items","item","emptyText","buttons","toggle"];function Ga(e,t){let n={opens:W(e.opens)??t,template:W(e.template),kind:W(e.kind)};for(let r of lu)n[r]=Lr(e[r],r);return et(n)}function Xa(e,t,n,r){let s=(F(e.experiences)?e.experiences:{})[n];if(!F(s))throw new Error(`The project has no Experience '${n}'.`);let i=F(e.sources)?e.sources:{},a=F(e.actions)?e.actions:{},l=[],c=F(s.pages)?s.pages:{},p=W(s.main)??Object.keys(c)[0]??"",d={};for(let[z,N]of Object.entries(c))d[z]=Lr(N)??{};let m=Ga(F(s.tile)?s.tile:{template:"text"},p),b=F(s.complication)?Ga(s.complication,p):void 0,g=et({title:W(s.title)??n,subtitle:W(s.subtitle),icon:W(s.icon),iconUrl:W(s.iconUrl),description:W(s.description)}),S=[d,m,b??null,g],_=new Set;is(S,_,a);let A=new Set;Rr(S,A,i);for(let z of _){let N=a[z];typeof N.source=="string"&&N.source in i&&A.add(N.source);for(let T of Array.isArray(N.refresh)?N.refresh:[])typeof T=="string"&&T in i&&A.add(T);Rr([N.confirm??null,N.toast??null],A,i)}let J={};for(let z of Object.keys(i).filter(N=>A.has(N)).sort(Mr))J[z]=cu(z,i[z],e,r);let w={};for(let z of[..._].sort(Mr))w[z]=pu(a[z],e);let C=uu(S),P=et({bundleVersion:1,schemaVersion:2,engine:1,experienceId:r.experienceId,localId:n,projectId:r.projectId,version:r.version,publishedAt:r.publishedAt===void 0?void 0:Yt(r.publishedAt),timeZone:W(e.timeZone)??ru,entry:g,main:p,pages:d,tile:m,complication:b,sources:J,actions:w,assets:C.length?C:void 0,sample:du(t,Object.keys(J),l)}),x=JSON.stringify(P),y=qa(x);return y>Ft.maxBundleBytes&&l.push({path:`$.experiences.${n}`,rule:"bundle-too-large",message:`The bundle of '${n}' is ${Math.floor(y/1024)} KiB; the limit is ${Ft.maxBundleBytes/1024} KiB.`,allowed:[],severity:"error"}),{bundle:P,json:x,bytes:y,issues:l}}function Ya(e,t){if(!(!F(e)&&!F(t)))return Za({...F(e)?e:{},...F(t)?t:{}})}function Qa(e,t){let n=F(t.headers)&&Object.keys(t.headers).length?Za(t.headers):void 0;return et({method:e,url:W(t.url)??"",headers:n,body:t.body,timeoutSeconds:ou})}var Ka=e=>{let t=Ha({url:W(e.url),headers:F(e.headers)?e.headers:void 0,body:e.body});return t.length?t:void 0};function cu(e,t,n,r){let o=r.sourceRefs?.[e]??su(e),s=t.mode==="direct",i=W(t.push)??(s?"signal":"values"),a=F(t.refresh)?t.refresh:void 0;return et(s?{mode:"direct",ref:o,refresh:a,push:i,request:Qa(W(t.method)??"GET",t),params:Ya(n.params,t.params),secrets:Ka(t),map:t.map}:{mode:"proxied",ref:o,refresh:a,push:i})}function pu(e,t){let n=W(e.type)??"http",r=W(e.mode)??"proxied",o=n==="http"&&r==="direct";return et({kind:n,mode:n==="http"?r:void 0,source:W(e.source),screen:W(e.screen),confirm:W(e.confirm),toast:F(e.toast)?e.toast:void 0,refresh:Array.isArray(e.refresh)&&e.refresh.length?e.refresh:void 0,request:o?Qa(W(e.method)??"POST",e):void 0,params:o?Ya(t.params,e.params):void 0,secrets:o?Ka(e):void 0})}function is(e,t,n){if(Array.isArray(e))e.forEach(r=>is(r,t,n));else if(F(e))for(let[r,o]of Object.entries(e))(r==="action"||r==="onAction"||r==="offAction")&&typeof o=="string"&&F(n[o])&&t.add(o),is(o,t,n)}function Rr(e,t,n){let r=o=>{for(let s of Rt(o,!0,i=>i in n))s in n&&t.add(s)};if(Array.isArray(e))e.forEach(o=>Rr(o,t,n));else if(F(e))for(let[o,s]of Object.entries(e))o==="bind"&&typeof s=="string"?r(s.trimStart().startsWith("{{")?s:`{{ ${s} }}`):Rr(s,t,n);else typeof e=="string"&&e.includes("{{")&&r(e)}function uu(e){let t=new Set,n=r=>{if(Array.isArray(r))r.forEach(n);else if(F(r))for(let[o,s]of Object.entries(r))(o==="url"||o==="iconUrl")&&typeof s=="string"&&!s.includes("{{")&&Nt(s)&&t.add(s),n(s)};return n(e),[...t].sort(Mr).slice(0,Ft.maxAssets).map(r=>({url:r,maxBytes:Ft.maxAssetBytes}))}function du(e,t,n){if(!e)return;let r={};for(let s of t)s in e&&e[s]!==void 0&&(r[s]=structuredClone(e[s]));if(!Object.keys(r).length)return;let o=!1;for(;qa(JSON.stringify(r))>Ft.maxSampleBytes;){let s=fu(r);if(s)s.splice(s.length-Math.max(1,Math.floor(s.length/8)));else{let i=Object.keys(r).sort((a,l)=>JSON.stringify(r[l]).length-JSON.stringify(r[a]).length)[0];delete r[i]}o=!0}return o&&n.push({path:"$",rule:"sample-truncated",message:`The sample data was cut to ${Ft.maxSampleBytes/1024} KiB for the bundle (it is shipped to the watch).`,allowed:[],severity:"warning",file:"data.json"}),Object.keys(r).length?r:void 0}function fu(e){let t=null,n=0,r=o=>{if(Array.isArray(o)){let s=JSON.stringify(o).length;o.length&&s>n&&([t,n]=[o,s]),o.forEach(r)}else F(o)&&Object.values(o).forEach(r)};return r(e),t}var el={$schema:"../device-profile.schema.json",id:"galaxy-watch",name:"Galaxy Watch 44mm",platform:"wear",measured:!1,source:"Public specs for Galaxy Watch4/5 44mm, Watch4 Classic 46mm and Watch5 Pro (450x450, about 321 ppi, assumed xhdpi = density 2.0), as docs/wear-tokens.md. Not verified: one report says a Galaxy Watch4 returns wm density 340 (2.125, 212dp, a small screen). Measure with adb shell wm size / wm density on a real watch (plan step 8) and then set measured to true. Tile slots, complication behaviour and limits are what the Wear app does today.",screen:{shape:"round",widthPx:450,heightPx:450,density:2,widthDp:225,heightDp:225,sizeClass:"large",caseMm:44},insets:{safe:33,screenHorizontal:12,screenTop:30,screenBottom:52,tileHorizontal:16},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system (One UI Watch font, not measured)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:8,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:8},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (8 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:8}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},LONG_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},RANGED_VALUE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},SMALL_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},MONOCHROMATIC_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face (Samsung's own faces mostly offer SHORT_TEXT, RANGED_VALUE and SMALL_IMAGE slots). Not measured."},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var tl={$schema:"../device-profile.schema.json",id:"pixel-watch",name:"Pixel Watch 3 41mm",platform:"wear",measured:!1,source:"Public specs for Pixel Watch 3 41mm (408x408 px; Google lists 320 ppi, assumed xhdpi = density 2.0, 204dp, a small screen). Not verified on a watch: measure with adb shell wm size / wm density and then set measured to true. Tile and complication behaviour are what the Wear app does today.",screen:{shape:"round",widthPx:408,heightPx:408,density:2,widthDp:204,heightDp:204,sizeClass:"small",caseMm:41},insets:{safe:30,screenHorizontal:11,screenTop:27,screenBottom:47,tileHorizontal:15},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system (Google Sans Flex on Pixel Watch, not measured)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:6,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:6},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (6 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:6}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},LONG_TEXT:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},RANGED_VALUE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},SMALL_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},MONOCHROMATIC_IMAGE:{support:"supported",reason:"Offered by the data source; which types a slot takes depends on the face. Not measured."},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var nl={$schema:"../device-profile.schema.json",id:"wear-large-round",name:"Wear OS Large Round (emulator)",platform:"wear",measured:!0,source:"Android Studio device definition 'Wear OS Large Round' (454x454 px, xhdpi; the AVD Wear_OS_Large_Round has hw.lcd 454x454 at 320 dpi, sdklib devices/wear.xml) and the Wear app rendered under Robolectric with these qualifiers.",screen:{shape:"round",widthPx:454,heightPx:454,density:2,widthDp:227,heightDp:227,sizeClass:"large"},insets:{safe:34,screenHorizontal:12,screenTop:30,screenBottom:53,tileHorizontal:17},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system font (Roboto on the emulator image; Robolectric's system font in the JVM goldens)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:8,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:8},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (8 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:8}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported"},LONG_TEXT:{support:"supported"},RANGED_VALUE:{support:"supported"},SMALL_IMAGE:{support:"supported"},MONOCHROMATIC_IMAGE:{support:"supported"},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var rl={$schema:"../device-profile.schema.json",id:"wear-small-round",name:"Wear OS Small Round (emulator)",platform:"wear",measured:!0,source:"Android Studio device definition 'Wear OS Small Round' (384x384 px, xhdpi, sdklib devices/wear.xml) and the Wear app rendered under Robolectric with these qualifiers.",screen:{shape:"round",widthPx:384,heightPx:384,density:2,widthDp:192,heightDp:192,sizeClass:"small",caseMm:40},insets:{safe:29,screenHorizontal:10,screenTop:25,screenBottom:45,tileHorizontal:14},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system font (Roboto on the emulator image; Robolectric's system font in the JVM goldens)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:6,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:6},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring runs along the screen edge, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (6 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:6}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported"},LONG_TEXT:{support:"supported"},RANGED_VALUE:{support:"supported"},SMALL_IMAGE:{support:"supported"},MONOCHROMATIC_IMAGE:{support:"supported"},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var ol={$schema:"../device-profile.schema.json",id:"wear-square",name:"Wear OS Square (emulator)",platform:"wear",measured:!0,source:"Android Studio device definition 'Wear OS Square' (360x360 px, xhdpi, sdklib devices/wear.xml) and the Wear app rendered under Robolectric with these qualifiers.",screen:{shape:"square",widthPx:360,heightPx:360,density:2,widthDp:180,heightDp:180,sizeClass:"small"},insets:{safe:0,screenHorizontal:10,screenTop:24,screenBottom:42,tileHorizontal:13},fonts:{app:{family:"Roboto Flex",typeScale:"tokens.json#/typeScale",note:"Bundled with the app as static instances (res/font), so every watch draws pages in the same font as the web preview."},tile:{family:"system font (Roboto on the emulator image; Robolectric's system font in the JVM goldens)",note:"Tiles cannot use app fonts: ProtoLayout draws them with the system font and its own Material 3 typography tokens (TITLE_SMALL, NUMERAL_MEDIUM, BODY_SMALL, ...), not tokens.json typeScale."},complication:{family:"the watch face",note:"The watch face draws complications with its own font, size and colours; previews are a guide, not a pixel reference."}},surfaces:{screen:{limits:{listMaxRows:10,textMaxLines:3},components:{text:{support:"supported",limits:{maxLines:3}},stat:{support:"supported"},list:{support:"supported",limits:{maxRows:10}},status:{support:"supported"},progress:{support:"supported"},countdown:{support:"supported",reason:"Ticks every second against the watch clock while the page is open."},button:{support:"supported",reason:"A confirm asks first in a Material 3 AlertDialog."},toggle:{support:"supported",reason:"Optimistic per toggle key; rolls back when the action fails."},icon:{support:"supported",reason:"Built-in icons are vector drawables from the same path data as the web; image URLs are fetched and cached."},stack:{support:"supported",reason:"The root stack and its lists are flattened into the scrolling column so each row scales at the screen edge on its own."}}},tile:{theme:{corners:{support:"degraded",to:"rounded",reason:"ProtoLayout Material 3 draws tile buttons and the edge button in its own shapes; the theme's corner style applies to the App's pages."},typeWeight:{support:"degraded",to:"the system font's weights",reason:"Tiles use the system font with ProtoLayout's own typography (fonts.tile), so the theme's weight offset does not apply."},typeWidth:{support:"unsupported",reason:"ProtoLayout tiles have no width axis: the system font is drawn at its normal width."}},instances:10,minRefreshSeconds:60,limits:{listMaxRows:3,compactListMaxRows:6,maxButtons:2,maxToggles:1,countdownTimelineEntries:40},templates:{text:{support:"supported",limits:{maxLines:3},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},"single-stat":{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}},list3:{support:"supported",limits:{maxRows:3},reason:"Rows past the limit become a '+N more' line.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.subtitle":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.badge":{support:"unsupported",reason:"list3 rows are one line: icon, title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},"compact-list":{support:"supported",limits:{maxRows:6},reason:"One-line rows in the space of the edge button (no Open button: the whole tile opens the page). An error banner and the stale hint each take the place of one row.",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"item.icon":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.subtitle":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.badge":{support:"unsupported",reason:"compact-list rows are one line of title and trailing value."},"item.action":{support:"degraded",to:"a tap on the tile opens the page",reason:"Tile rows are not separately clickable."}}},status:{support:"supported",slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},detail:{support:"supported",limits:{maxLines:2}}}},"progress-ring":{support:"supported",reason:"The ring is drawn as a circle inside the square screen, with a gap for the edge button.",slots:{icon:{support:"unsupported",reason:"The template wraps primaryLayout in the ring's box, so the system leaves the header icon slot empty (checked on the Wear OS 6 emulator, 2026-11-07): neither the glance icon nor the app icon is shown."}}},buttons2:{support:"supported",limits:{maxButtons:2},slots:{icon:{support:"degraded",to:"the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."},"buttons.label":{support:"degraded",to:"a one-line caption under a round icon button (the first letter in the button when it has no icon)",reason:"Tile buttons are round icon buttons."},"buttons.confirm":{support:"degraded",to:"opens the app, which asks to confirm",reason:"Tiles cannot show dialogs."}}},toggle:{support:"supported",limits:{maxToggles:1},slots:{icon:{support:"degraded",to:"the toggle's icon (or the glance icon) inside the toggle button; the header shows the app icon",reason:"ProtoLayout's primaryLayout reserves the header icon slot and the system draws the app icon there; the glance icon is not repeated."}}}},components:{text:{support:"supported",limits:{maxLines:3},reason:"In the text template's slot, at TITLE_MEDIUM."},stat:{support:"supported",reason:"single-stat template."},list:{support:"degraded",to:"list3 (3 rows and '+N more') or compact-list (6 one-line rows)",reason:"Tiles do not scroll.",limits:{maxRows:6}},status:{support:"supported",reason:"status template."},progress:{support:"supported",reason:"progress-ring template.",slots:{"style.bar":{support:"degraded",to:"a ring",reason:"The tile template is progress-ring only."}}},countdown:{support:"degraded",to:"timeline entries pre-rendered at the instants the text changes",reason:"Tiles cannot tick: every 10 s in the last 3 minutes, every minute before that, at most 40 entries over 30 minutes; then the tile asks again.",limits:{timelineEntries:40}},button:{support:"degraded",to:"buttons2: round icon buttons with a one-line caption",reason:"Tile buttons are round icon buttons; a confirm opens the app.",limits:{maxButtons:2}},toggle:{support:"supported",reason:"toggle template.",limits:{maxToggles:1}},icon:{support:"degraded",to:"built-in icons inside list rows, buttons and toggles only",reason:"The header icon is the app icon (system), and tile resources are the bundled icons.",slots:{url:{support:"unsupported",reason:"Tile images must be bundled resources; image URLs are not fetched."}}},stack:{support:"unsupported",reason:"A tile shows one fixed template, not a free layout."}}},complication:{instances:1,minRefreshSeconds:300,kinds:{shortText:{support:"supported",limits:{maxTextChars:7},fills:["SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"The watch face ticks complications with TimeDifferenceComplicationText, which cannot print the app strings (SHORT_SINGLE_UNIT, STOPWATCH in the last 3 minutes and for format clock)."}}},longText:{support:"supported",limits:{maxTextChars:24},fills:["LONG_TEXT","SHORT_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],slots:{"text.countdown":{support:"degraded",to:"the platform's ticking time-difference text ('7m', '02:30')",reason:"As shortText."}}},rangedValue:{support:"supported",limits:{maxTextChars:7},fills:["RANGED_VALUE","SHORT_TEXT","LONG_TEXT"],fillsWithIcon:["SMALL_IMAGE","MONOCHROMATIC_IMAGE"],reason:"In a text slot it shows its text, or else its value as a number."},image:{support:"supported",fills:["SMALL_IMAGE"],fillsWithIcon:["MONOCHROMATIC_IMAGE"],slots:{url:{support:"degraded",to:"SMALL_IMAGE of type PHOTO only",reason:"A fetched bitmap cannot be tinted, so MONOCHROMATIC_IMAGE needs a built-in icon."}}}},types:{SHORT_TEXT:{support:"supported"},LONG_TEXT:{support:"supported"},RANGED_VALUE:{support:"supported"},SMALL_IMAGE:{support:"supported"},MONOCHROMATIC_IMAGE:{support:"supported"},PHOTO_IMAGE:{support:"unsupported",reason:"The QuickWatch data source does not offer it (AndroidManifest SUPPORTED_TYPES)."},GOAL_PROGRESS:{support:"unsupported",reason:"The QuickWatch data source does not offer it; rangedValue covers progress."},WEIGHTED_ELEMENTS:{support:"unsupported",reason:"The QuickWatch data source does not offer it."}}}}};var as=[el,tl,nl,rl,ol],yu="0.3.0",ll=as.map(e=>e.id),vu=St.map(e=>e.id),sl=typeof document<"u"&&document.currentScript instanceof HTMLScriptElement?document.currentScript.src:"",cl=/@font-face\s*\{[^}]*\}/g,xu=os.replace(cl,"");function ku(e){if(!sl||e.getElementById("quickwatch-preview-fonts"))return;let t=e.createElement("style");t.id="quickwatch-preview-fonts",t.textContent=(os.match(cl)??[]).join(`
1995
+ `).replace(/url\('fonts\//g,`url('${new URL("fonts/",sl).href}`),e.head.appendChild(t)}function Er(e,t){let n=e.ownerDocument;ku(n);let r=n.createElement("div");e.replaceChildren(r);let o=r.attachShadow({mode:"open"}),s=n.createElement("style");s.textContent=`:host { all: initial !important; display: block !important; } * { overscroll-behavior: contain; }
1996
+ ${t}`;let i=n.createElement("div");return o.append(s,i),i}function il(e,t,n){if(e===void 0)return{};if(typeof e!="string")return e;let r=Ar(e,t);for(let o of r.issues)n.push(`${t}: ${o.message}`);return r.value&&typeof r.value=="object"&&!Array.isArray(r.value)?r.value:null}function al(e,t){let n=[],r=il(e,"watch.json",n),o=il(t,"data.json",n),s=r&&typeof r.experiences=="object"&&r.experiences&&!Array.isArray(r.experiences)?r.experiences:{},i=[];if(r)for(let[a,l]of Object.entries(s))try{let c=Xa(r,o??{},a,{experienceId:`draft_${a}`,version:0}),p=l&&typeof l=="object"&&!Array.isArray(l)?l.theme:void 0;i.push({key:a,label:a,bundle:c.bundle,theme:Gr(p).theme})}catch(c){n.push(`${a}: ${c instanceof Error?c.message:String(c)}`)}return r&&!Object.keys(s).length&&n.push("watch.json: no experiences"),{list:i,errors:n}}function ns(e,t,n,r={}){let o=Er(e,xu),s=as.find(m=>m.id===r.device)??as[0],i=r.size?r.size/s.screen.widthDp:1,{list:a,errors:l}=al(t,n),c=null,p={get experiences(){return a.map(m=>m.key)},get surfaces(){return(c?.surfaces??[]).map(m=>({key:m.key,label:m.label,kind:m.kind}))},get surface(){return c?.surface??""},get errors(){return l},show(m){c?.command({type:"surface",surface:m})},update(m,b){({list:a,errors:l}=al(m,b)),c&&a.length?c.setPayload({payloadVersion:1,experiences:a}):d()},destroy(){c?.destroy(),c=null}};function d(){if(c?.destroy(),c=null,!a.length){o.textContent=l.join(`
1997
+ `)||"Nothing to show.";return}c=Xo(o,{payloadVersion:1,experiences:a},{...r.experience?{experience:r.experience}:{},...r.surface?{surface:r.surface}:{},device:s.id,theme:r.theme??"auto",data:r.data??"sample",ambient:r.ambient??!1,devices:ll,...r.onUpdate?{onUpdate:()=>r.onUpdate(p)}:{},...r.onError?{onError:r.onError}:{},engine:{resolve:(m,b,g,S)=>yn(fr(m,b,g,S),s).view,render:(m,b)=>ii(o,m,{...b,deviceProfile:zo(s),scale:i,frame:r.frame??!0,idPrefix:"qwp"})}})}return d(),p}Ba();return gl(Tu);})();
1998
+ globalThis.QuickWatch = QuickWatch;