efficient-shell 4.159.0 → 4.160.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/README.md +12 -1
  2. package/dist/{Browser-OQCHLKM3.js → Browser-3KOGROX7.js} +12 -12
  3. package/dist/{Calculator-YBL65JNM.js → Calculator-QLJJ3ICT.js} +22 -22
  4. package/dist/{CurrencyConverter-6VFY4GF6.js → CurrencyConverter-3GTKDKHH.js} +7 -7
  5. package/dist/{Documents-IPXRU4CT.js → Documents-FDGF7QBQ.js} +12 -12
  6. package/dist/{Files-3MGL4ZT7.js → Files-TTSYOPVB.js} +26 -26
  7. package/dist/{Notepad-RJ2DYW2O.js → Notepad-ITHIATP2.js} +10 -10
  8. package/dist/{PomodoroTimer-6OQ33FY3.js → PomodoroTimer-CRKL26PP.js} +19 -19
  9. package/dist/{Preview-3WRPZWDU.js → Preview-GZTTEZWS.js} +14 -14
  10. package/dist/{Sidebar-FUPFF7BT.js → Sidebar-ECJEQXFK.js} +21 -21
  11. package/dist/{Spreadsheet-6NK53IZV.js → Spreadsheet-PFKZTLSI.js} +12 -12
  12. package/dist/{Stock-ZFLDG6TT.js → Stock-NAHSVLAJ.js} +3 -3
  13. package/dist/{Weather-BBPTXGQA.js → Weather-AY3QWBQT.js} +17 -17
  14. package/dist/{WorldClock-CQGQ2Y6N.js → WorldClock-AXNMA4PG.js} +3 -3
  15. package/dist/apps/index.js +1 -1
  16. package/dist/{chunk-EI4WZOP3.js → chunk-A6FPBD7W.js} +1 -1
  17. package/dist/chunk-GF2XCISN.js +1 -0
  18. package/dist/{chunk-Z3LPT4HB.js → chunk-HQTSPK5Q.js} +1 -1
  19. package/dist/{chunk-CK245P3T.js → chunk-JK3IIJN5.js} +7 -7
  20. package/dist/{chunk-J7AAGG7P.js → chunk-LCB4IVEL.js} +131 -131
  21. package/dist/{chunk-DLD4AKVT.js → chunk-X6E6UULK.js} +74 -74
  22. package/dist/{chunk-M4AKWGQM.js → chunk-XPSADW6W.js} +1 -1
  23. package/dist/chunk-YKZGKYVT.js +2 -0
  24. package/dist/{index-D0K5U1Pb.d.ts → index-Brl0XepS.d.ts} +8 -2
  25. package/dist/index.d.ts +24 -3
  26. package/dist/index.js +645 -645
  27. package/dist/ui/index.d.ts +1 -1
  28. package/dist/ui/index.js +1 -1
  29. package/package.json +1 -1
  30. package/dist/chunk-L4KRS7N3.js +0 -1
  31. package/dist/chunk-MVLIXV7C.js +0 -2
@@ -1,4 +1,4 @@
1
- import{loadAppearance as e,WidgetSettingsModal as t}from"./chunk-M4AKWGQM.js";import{useWidgetSettings as a}from"./chunk-DLD4AKVT.js";import"./chunk-T6MKFQRH.js";import"./chunk-6UXY7MPY.js";import"./chunk-PH3PRIFP.js";import"./chunk-PDTZTADH.js";import"./chunk-VNEH2Y6H.js";import"./chunk-OSJ3ADF2.js";import"./chunk-MAIHBBWT.js";import"./chunk-VVI77XNV.js";import"./chunk-D65T4H6J.js";import{useState as r,useCallback as n}from"react";import{jsxs as c,Fragment as s,jsx as i}from"react/jsx-runtime";var l=["AAPL","MSFT","GOOGL","TSLA","NVDA"],o="stock_symbols",m="stock_appearance",d={AAPL:{price:229.87,change:1.42,changePct:.62},MSFT:{price:451.16,change:-2.31,changePct:-.51},GOOGL:{price:178.34,change:.89,changePct:.5},AMZN:{price:201.45,change:-1.08,changePct:-.53},TSLA:{price:248.92,change:6.74,changePct:2.78},NVDA:{price:134.81,change:-3.12,changePct:-2.26},META:{price:563.27,change:4.55,changePct:.81}},g=Object.keys(d);function p(){try{const e=JSON.parse(localStorage.getItem(o)||"");if(Array.isArray(e)&&e.length)return e.slice(0,8)}catch{}return l}var h=e=>`${e>=0?"+":""}${e.toFixed(2)}`;function x(){const[l,x]=r(p),[u,y]=r(()=>e(m)),[b,f]=r(!1),[N,v]=r([]),[k,A]=r(u),[S,j]=r(""),P=n(()=>{v([...l]),A({...u}),j(""),f(!0)},[l,u]);a(P);const D=()=>{const e=S.trim().toUpperCase();!e||N.includes(e)||N.length>=8||(v(t=>[...t,e]),j(""))},T=g.filter(e=>!N.includes(e));/* @__PURE__ */
1
+ import{loadAppearance as e,WidgetSettingsModal as t}from"./chunk-XPSADW6W.js";import{useWidgetSettings as a}from"./chunk-X6E6UULK.js";import"./chunk-T6MKFQRH.js";import"./chunk-6UXY7MPY.js";import"./chunk-PH3PRIFP.js";import"./chunk-PDTZTADH.js";import"./chunk-VNEH2Y6H.js";import"./chunk-OSJ3ADF2.js";import"./chunk-MAIHBBWT.js";import"./chunk-VVI77XNV.js";import"./chunk-D65T4H6J.js";import{useState as r,useCallback as n}from"react";import{jsxs as c,Fragment as s,jsx as i}from"react/jsx-runtime";var l=["AAPL","MSFT","GOOGL","TSLA","NVDA"],o="stock_symbols",m="stock_appearance",d={AAPL:{price:229.87,change:1.42,changePct:.62},MSFT:{price:451.16,change:-2.31,changePct:-.51},GOOGL:{price:178.34,change:.89,changePct:.5},AMZN:{price:201.45,change:-1.08,changePct:-.53},TSLA:{price:248.92,change:6.74,changePct:2.78},NVDA:{price:134.81,change:-3.12,changePct:-2.26},META:{price:563.27,change:4.55,changePct:.81}},g=Object.keys(d);function p(){try{const e=JSON.parse(localStorage.getItem(o)||"");if(Array.isArray(e)&&e.length)return e.slice(0,8)}catch{}return l}var h=e=>`${e>=0?"+":""}${e.toFixed(2)}`;function x(){const[l,x]=r(p),[u,y]=r(()=>e(m)),[b,f]=r(!1),[N,v]=r([]),[k,A]=r(u),[S,P]=r(""),j=n(()=>{v([...l]),A({...u}),P(""),f(!0)},[l,u]);a(j);const D=()=>{const e=S.trim().toUpperCase();!e||N.includes(e)||N.length>=8||(v(t=>[...t,e]),P(""))},O=g.filter(e=>!N.includes(e));/* @__PURE__ */
2
2
  return c(s,{children:[
3
3
  /* @__PURE__ */i("div",{style:{backgroundColor:`rgb(var(--taskbar-bg-rgb, 243 244 246) / ${u.activeOpacity/100})`,backdropFilter:u.activeBlur>0?`blur(${u.activeBlur}px)`:void 0},children:/* @__PURE__ */i("div",{className:"px-4 py-3",children:0===l.length?/* @__PURE__ */i("div",{className:"text-xs text-gray-500 text-center py-6",children:"No symbols yet — add some in settings."}):/* @__PURE__ */i("div",{className:"space-y-0.5",children:l.map(e=>{const t=d[e],a=(t?.change??0)>=0,r=t?t.change>0?"text-green-600":t.change<0?"text-red-600":"text-gray-500":"text-gray-400";/* @__PURE__ */
4
4
  return c("div",{className:"flex items-center justify-between px-2 py-2 border-b border-gray-200 last:border-0",children:[
@@ -11,6 +11,6 @@ return c("div",{className:"flex items-center justify-between px-2 py-2 border-b
11
11
  /* @__PURE__ */c("div",{className:"space-y-1 mb-2",children:[N.map((e,t)=>/* @__PURE__ */c("div",{className:"flex items-center justify-between py-1 px-2 bg-gray-50 rounded",children:[
12
12
  /* @__PURE__ */i("span",{className:"text-sm font-semibold text-gray-700",children:e}),
13
13
  /* @__PURE__ */i("button",{onClick:()=>v(e=>e.filter((e,a)=>a!==t)),className:"text-red-400 hover:text-red-600",children:"×"})]},t)),0===N.length&&/* @__PURE__ */i("p",{className:"text-[11px] text-gray-400 italic",children:"No symbols — add a ticker below."})]}),N.length<8?/* @__PURE__ */c("div",{className:"flex items-center gap-2",children:[
14
- /* @__PURE__ */i("input",{value:S,onChange:e=>j(e.target.value),onKeyDown:e=>{"Enter"===e.key&&D()},placeholder:"e.g. NVDA",className:"flex-1 bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm uppercase focus:outline-none focus:ring-1 focus:ring-blue-500"}),
15
- /* @__PURE__ */i("button",{onClick:D,className:"text-sm font-medium text-blue-600 hover:text-blue-800 px-2",children:"+ Add"})]}):/* @__PURE__ */c("p",{className:"text-[11px] text-gray-400 italic",children:["Max ",8," symbols — remove one to add another."]}),T.length>0&&N.length<8&&/* @__PURE__ */i("div",{className:"flex flex-wrap gap-1.5 mt-2",children:T.map(e=>/* @__PURE__ */i("button",{onClick:()=>v(t=>t.length<8?[...t,e]:t),className:"text-[11px] font-medium text-gray-600 bg-gray-100 hover:bg-gray-200 rounded px-2 py-0.5 transition-colors",children:e},e))}),
14
+ /* @__PURE__ */i("input",{value:S,onChange:e=>P(e.target.value),onKeyDown:e=>{"Enter"===e.key&&D()},placeholder:"e.g. NVDA",className:"flex-1 bg-gray-50 border border-gray-200 rounded px-2 py-1 text-sm uppercase focus:outline-none focus:ring-1 focus:ring-blue-500"}),
15
+ /* @__PURE__ */i("button",{onClick:D,className:"text-sm font-medium text-blue-600 hover:text-blue-800 px-2",children:"+ Add"})]}):/* @__PURE__ */c("p",{className:"text-[11px] text-gray-400 italic",children:["Max ",8," symbols — remove one to add another."]}),O.length>0&&N.length<8&&/* @__PURE__ */i("div",{className:"flex flex-wrap gap-1.5 mt-2",children:O.map(e=>/* @__PURE__ */i("button",{onClick:()=>v(t=>t.length<8?[...t,e]:t),className:"text-[11px] font-medium text-gray-600 bg-gray-100 hover:bg-gray-200 rounded px-2 py-0.5 transition-colors",children:e},e))}),
16
16
  /* @__PURE__ */i("p",{className:"text-[11px] text-gray-400 mt-2",children:"Demo prices — static sample data, no live feed."})]})})]})}export{x as default};
@@ -1,4 +1,4 @@
1
- import{fetchCityWeather as e,getCondition as t,AVAILABLE_CITIES as a,toFahrenheit as r}from"./chunk-FBDZGO3V.js";import{loadAppearance as n,WidgetSettingsModal as i}from"./chunk-M4AKWGQM.js";import{useWidgetSettings as s}from"./chunk-DLD4AKVT.js";import{useShellPrefs as o}from"./chunk-T6MKFQRH.js";import"./chunk-6UXY7MPY.js";import"./chunk-PH3PRIFP.js";import"./chunk-PDTZTADH.js";import"./chunk-VNEH2Y6H.js";import"./chunk-OSJ3ADF2.js";import"./chunk-MAIHBBWT.js";import"./chunk-VVI77XNV.js";import"./chunk-D65T4H6J.js";import{useState as l,useEffect as c,useCallback as d}from"react";import{jsx as m,jsxs as p,Fragment as h}from"react/jsx-runtime";var f="weather_city",u="weather_appearance",y={useFahrenheit:!1,showLocalTime:!0,use24Hour:!1};function g(){const e="undefined"!=typeof localStorage?localStorage.getItem(f):null;if(e&&a[e])return e;try{const e=JSON.parse(localStorage.getItem("weather_cities")||"");if(Array.isArray(e)&&e[0]&&a[e[0]])return localStorage.setItem(f,e[0]),e[0]}catch{}return function(){try{const e=Intl.DateTimeFormat().resolvedOptions().timeZone;for(const[t,r]of Object.entries(a))if(r.tz===e)return t}catch{}return"London"}()}var x=r;function b(e,t=!1){try{if(t){const t=new Intl.DateTimeFormat("en-US",{timeZone:e,hour:"numeric",minute:"2-digit",hour12:!1}).formatToParts(/* @__PURE__ */new Date),a=parseInt(t.find(e=>"hour"===e.type)?.value||"0"),r=parseInt(t.find(e=>"minute"===e.type)?.value||"0");return`${String(a).padStart(2,"0")}:${String(r).padStart(2,"0")}`}const a=new Intl.DateTimeFormat("en-US",{timeZone:e,hour:"numeric",minute:"2-digit",hour12:!0}).formatToParts(/* @__PURE__ */new Date),r=parseInt(a.find(e=>"hour"===e.type)?.value||"12"),n=parseInt(a.find(e=>"minute"===e.type)?.value||"0"),i=a.find(e=>"dayPeriod"===e.type)?.value||"";return`${r}:${String(n).padStart(2,"0")} ${i}`}catch{return""}}function w(){/* @__PURE__ */
1
+ import{fetchCityWeather as e,getCondition as t,AVAILABLE_CITIES as a,toFahrenheit as r}from"./chunk-FBDZGO3V.js";import{loadAppearance as n,WidgetSettingsModal as i}from"./chunk-XPSADW6W.js";import{useWidgetSettings as s}from"./chunk-X6E6UULK.js";import{useShellPrefs as o}from"./chunk-T6MKFQRH.js";import"./chunk-6UXY7MPY.js";import"./chunk-PH3PRIFP.js";import"./chunk-PDTZTADH.js";import"./chunk-VNEH2Y6H.js";import"./chunk-OSJ3ADF2.js";import"./chunk-MAIHBBWT.js";import"./chunk-VVI77XNV.js";import"./chunk-D65T4H6J.js";import{useState as l,useEffect as c,useCallback as d}from"react";import{jsx as m,jsxs as p,Fragment as h}from"react/jsx-runtime";var f="weather_city",u="weather_appearance",y={useFahrenheit:!1,showLocalTime:!0,use24Hour:!1};function g(){const e="undefined"!=typeof localStorage?localStorage.getItem(f):null;if(e&&a[e])return e;try{const e=JSON.parse(localStorage.getItem("weather_cities")||"");if(Array.isArray(e)&&e[0]&&a[e[0]])return localStorage.setItem(f,e[0]),e[0]}catch{}return function(){try{const e=Intl.DateTimeFormat().resolvedOptions().timeZone;for(const[t,r]of Object.entries(a))if(r.tz===e)return t}catch{}return"London"}()}var x=r;function b(e,t=!1){try{if(t){const t=new Intl.DateTimeFormat("en-US",{timeZone:e,hour:"numeric",minute:"2-digit",hour12:!1}).formatToParts(/* @__PURE__ */new Date),a=parseInt(t.find(e=>"hour"===e.type)?.value||"0"),r=parseInt(t.find(e=>"minute"===e.type)?.value||"0");return`${String(a).padStart(2,"0")}:${String(r).padStart(2,"0")}`}const a=new Intl.DateTimeFormat("en-US",{timeZone:e,hour:"numeric",minute:"2-digit",hour12:!0}).formatToParts(/* @__PURE__ */new Date),r=parseInt(a.find(e=>"hour"===e.type)?.value||"12"),n=parseInt(a.find(e=>"minute"===e.type)?.value||"0"),i=a.find(e=>"dayPeriod"===e.type)?.value||"";return`${r}:${String(n).padStart(2,"0")} ${i}`}catch{return""}}function w(){/* @__PURE__ */
2
2
  return p("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:[
3
3
  /* @__PURE__ */m("div",{className:"absolute -top-5 -right-5 w-24 h-24",style:{animation:"wx-sun-rays 70s linear infinite"},children:/* @__PURE__ */m("svg",{viewBox:"0 0 100 100",className:"w-full h-full",children:Array.from({length:12}).map((e,t)=>/* @__PURE__ */m("rect",{x:49,y:3,width:2,height:14,rx:1,fill:"rgba(255, 232, 130, 0.55)",transform:`rotate(${30*t} 50 50)`},t))})}),
4
4
  /* @__PURE__ */m("div",{className:"absolute top-1 right-1 w-10 h-10 rounded-full",style:{background:"radial-gradient(circle at 35% 35%, #fff8cc 0%, #ffd84a 55%, #ff9e2a 100%)",boxShadow:"0 0 18px 5px rgba(255, 200, 80, 0.55)",animation:"wx-sun-pulse 4.5s ease-in-out infinite"}})]})}function v(){const e=Array.from({length:16}).map((e,t)=>({left:(53*t+11)%95+"%",top:(37*t+9)%78+"%",size:1+13*t%3,delay:.41*t%4+"s",duration:2.5+7*t%5*.6+"s"}));/* @__PURE__ */
@@ -24,37 +24,37 @@ return p("div",{className:"absolute inset-0 overflow-hidden pointer-events-none"
24
24
  /* @__PURE__ */m(k,{heavy:!0}),
25
25
  /* @__PURE__ */m("div",{className:"absolute inset-0 bg-white",style:{animation:"wx-flash 6s ease-out infinite"}}),
26
26
  /* @__PURE__ */m("div",{className:"absolute inset-y-0 right-1/3 flex items-center justify-center pointer-events-none",style:{animation:"wx-bolt 6s ease-out infinite"},children:/* @__PURE__ */m("svg",{viewBox:"0 0 18 60",className:"h-4/5",style:{filter:"drop-shadow(0 0 6px rgba(255, 240, 150, 0.95)) drop-shadow(0 0 14px rgba(255, 220, 90, 0.7))"},children:/* @__PURE__ */m("path",{d:"M11 0 L2 28 L8 30 L4 60 L16 24 L9 22 Z",fill:"rgba(255, 250, 200, 0.98)",stroke:"rgba(255, 255, 255, 0.9)",strokeWidth:.3})})})]})}function j(){/* @__PURE__ */
27
- return m("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:Array.from({length:4}).map((e,t)=>/* @__PURE__ */m("div",{className:"absolute left-0 right-0",style:{top:10+22*t+"%",height:"14px",background:"linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.55) 50%, rgba(255,255,255,0) 100%)",filter:"blur(2px)",animation:`wx-fog-drift ${10+3*t}s ease-in-out ${.7*t}s infinite alternate`}},t))})}function D({code:e,isDay:t}){return 0===e||1===e?/* @__PURE__ */m(t?w:v,{}):2===e?/* @__PURE__ */p(h,{children:[/* @__PURE__ */m(t?w:v,{}),
28
- /* @__PURE__ */m(N,{tone:t?"light":"dark"})]}):3===e?/* @__PURE__ */m(N,{tone:t?"light":"dark"}):45===e||48===e?/* @__PURE__ */m(j,{}):[51,53,61,80,81].includes(e)?/* @__PURE__ */m(k,{}):[55,63,65,82].includes(e)?/* @__PURE__ */m(k,{heavy:!0}):[71,73,75].includes(e)?/* @__PURE__ */m(S,{}):[95,96,99].includes(e)?/* @__PURE__ */m($,{}):null}function I(){const[r,w]=l(g),[v,N]=l(()=>n(u)),[k,S]=l(null),[$,j]=l(!0),[,I]=l(0);c(()=>{const e=setInterval(()=>I(e=>e+1),6e4);return()=>clearInterval(e)},[]);const[T,A]=l(!1),[F,H]=l(r),[L,C]=l(v),{prefs:z,save:B}=o(),O={...y,...z.weather_prefs??{}},[P,M]=l(O);s(d(()=>{H(r),C({...v}),M({...O}),A(!0)},[r,v,O])),c(()=>{let t=!1;return j(!0),e(r).then(e=>{t||(S(e),j(!1))}),()=>{t=!0}},[r]);const V=e=>O.useFahrenheit?`${x(e)}°F`:`${e}°`;if($&&!k)/* @__PURE__ */
27
+ return m("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:Array.from({length:4}).map((e,t)=>/* @__PURE__ */m("div",{className:"absolute left-0 right-0",style:{top:10+22*t+"%",height:"14px",background:"linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.55) 50%, rgba(255,255,255,0) 100%)",filter:"blur(2px)",animation:`wx-fog-drift ${10+3*t}s ease-in-out ${.7*t}s infinite alternate`}},t))})}function I({code:e,isDay:t}){return 0===e||1===e?/* @__PURE__ */m(t?w:v,{}):2===e?/* @__PURE__ */p(h,{children:[/* @__PURE__ */m(t?w:v,{}),
28
+ /* @__PURE__ */m(N,{tone:t?"light":"dark"})]}):3===e?/* @__PURE__ */m(N,{tone:t?"light":"dark"}):45===e||48===e?/* @__PURE__ */m(j,{}):[51,53,61,80,81].includes(e)?/* @__PURE__ */m(k,{}):[55,63,65,82].includes(e)?/* @__PURE__ */m(k,{heavy:!0}):[71,73,75].includes(e)?/* @__PURE__ */m(S,{}):[95,96,99].includes(e)?/* @__PURE__ */m($,{}):null}function D(){const[r,w]=l(g),[v,N]=l(()=>n(u)),[k,S]=l(null),[$,j]=l(!0),[,D]=l(0);c(()=>{const e=setInterval(()=>D(e=>e+1),6e4);return()=>clearInterval(e)},[]);const[T,F]=l(!1),[H,A]=l(r),[L,C]=l(v),{prefs:z,save:P}=o(),B={...y,...z.weather_prefs??{}},[O,X]=l(B);s(d(()=>{A(r),C({...v}),X({...B}),F(!0)},[r,v,B])),c(()=>{let t=!1;return j(!0),e(r).then(e=>{t||(S(e),j(!1))}),()=>{t=!0}},[r]);const M=e=>B.useFahrenheit?`${x(e)}°F`:`${e}°`;if($&&!k)/* @__PURE__ */
29
29
  return m("div",{className:"flex items-center justify-center h-full bg-gradient-to-b from-sky-400 to-blue-500 rounded-lg text-white/80 text-xs",style:{minHeight:110},children:"Loading…"});if(!k)/* @__PURE__ */
30
- return m("div",{className:"flex items-center justify-center h-full bg-slate-700 rounded-lg text-white/80 text-xs",style:{minHeight:110},children:"Couldn't load weather"});const[X,Z,_]=t(k.code,k.isDay);/* @__PURE__ */
30
+ return m("div",{className:"flex items-center justify-center h-full bg-slate-700 rounded-lg text-white/80 text-xs",style:{minHeight:110},children:"Couldn't load weather"});const[Z,U,V]=t(k.code,k.isDay);/* @__PURE__ */
31
31
  return p(h,{children:[
32
32
  /* @__PURE__ */m("style",{children:"\n@keyframes wx-rain-a { 0% { transform: translate(0,-20px); opacity: 0; } 10% { opacity: 0.95; } 100% { transform: translate(8px,140px); opacity: 0; } }\n@keyframes wx-rain-b { 0% { transform: translate(0,-20px); opacity: 0; } 12% { opacity: 0.85; } 100% { transform: translate(12px,140px); opacity: 0; } }\n@keyframes wx-rain-c { 0% { transform: translate(0,-20px); opacity: 0; } 10% { opacity: 1; } 100% { transform: translate(5px,140px); opacity: 0; } }\n@keyframes wx-snow-a { 0% { transform: translate(0,-12px) rotate(0deg); opacity: 0; } 10% { opacity: 0.9; } 50% { transform: translate(10px,55px) rotate(180deg); } 100% { transform: translate(-4px,140px) rotate(360deg); opacity: 0; } }\n@keyframes wx-snow-b { 0% { transform: translate(0,-12px) rotate(0deg); opacity: 0; } 10% { opacity: 0.85; } 50% { transform: translate(-12px,55px) rotate(-180deg); } 100% { transform: translate(6px,140px) rotate(-360deg); opacity: 0; } }\n@keyframes wx-snow-c { 0% { transform: translate(0,-12px); opacity: 0; } 10% { opacity: 0.7; } 100% { transform: translate(2px,140px); opacity: 0; } }\n@keyframes wx-drift-cloud { 0% { transform: translateX(-40%); } 100% { transform: translateX(140%); } }\n@keyframes wx-twinkle { 0%, 100% { opacity: 0.25; transform: scale(1); } 50% { opacity: 1; transform: scale(1.6); } }\n@keyframes wx-flash { 0%, 86%, 100% { opacity: 0; } 87% { opacity: 0.95; } 88% { opacity: 0.15; } 89% { opacity: 0.85; } 90% { opacity: 0; } }\n@keyframes wx-bolt { 0%, 86%, 90%, 100% { opacity: 0; } 87% { opacity: 1; } 89% { opacity: 0.85; } }\n@keyframes wx-sun-pulse { 0%, 100% { transform: scale(1); opacity: 0.65; } 50% { transform: scale(1.12); opacity: 0.95; } }\n@keyframes wx-sun-rays { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } }\n@keyframes wx-fog-drift { 0% { transform: translateX(-25%); opacity: 0.3; } 50% { opacity: 0.65; } 100% { transform: translateX(25%); opacity: 0.3; } }\n@keyframes wx-shooting-star { 0%, 95% { opacity: 0; transform: translate(0,0) scale(0); } 96% { opacity: 1; transform: translate(0,0) scale(1); } 100% { opacity: 0; transform: translate(40px,30px) scale(1); } }\n"}),
33
- /* @__PURE__ */m("div",{className:"rounded-lg overflow-hidden",style:{backgroundColor:`rgba(15, 23, 42, ${v.activeOpacity/100})`,backdropFilter:v.activeBlur>0?`blur(${v.activeBlur}px)`:void 0},children:/* @__PURE__ */p("div",{className:`relative rounded-lg overflow-hidden text-white bg-gradient-to-br ${_}`,style:{height:110},children:[
34
- /* @__PURE__ */m(D,{code:k.code,isDay:k.isDay}),
33
+ /* @__PURE__ */m("div",{className:"rounded-lg overflow-hidden",style:{backgroundColor:`rgba(15, 23, 42, ${v.activeOpacity/100})`,backdropFilter:v.activeBlur>0?`blur(${v.activeBlur}px)`:void 0},children:/* @__PURE__ */p("div",{className:`relative rounded-lg overflow-hidden text-white bg-gradient-to-br ${V}`,style:{height:110},children:[
34
+ /* @__PURE__ */m(I,{code:k.code,isDay:k.isDay}),
35
35
  /* @__PURE__ */p("div",{className:"relative z-10 px-3 py-2.5 flex flex-col h-full justify-between",children:[
36
36
  /* @__PURE__ */p("div",{className:"flex items-start justify-between gap-2",children:[
37
37
  /* @__PURE__ */p("div",{className:"min-w-0 flex-1",children:[
38
- /* @__PURE__ */m("div",{className:"text-base font-semibold leading-tight truncate drop-shadow-sm",children:k.city}),O.showLocalTime&&/* @__PURE__ */m("div",{className:"text-[10px] opacity-90 leading-tight tabular-nums drop-shadow-sm",children:b(k.timezone,O.use24Hour)})]}),
39
- /* @__PURE__ */m("div",{className:"text-3xl font-extralight leading-none tracking-tight tabular-nums shrink-0 drop-shadow-sm",children:V(k.temp)})]}),
38
+ /* @__PURE__ */m("div",{className:"text-base font-semibold leading-tight truncate drop-shadow-sm",children:k.city}),B.showLocalTime&&/* @__PURE__ */m("div",{className:"text-[10px] opacity-90 leading-tight tabular-nums drop-shadow-sm",children:b(k.timezone,B.use24Hour)})]}),
39
+ /* @__PURE__ */m("div",{className:"text-3xl font-extralight leading-none tracking-tight tabular-nums shrink-0 drop-shadow-sm",children:M(k.temp)})]}),
40
40
  /* @__PURE__ */p("div",{className:"flex items-end justify-between gap-2",children:[
41
41
  /* @__PURE__ */p("div",{className:"flex items-center gap-1.5 min-w-0",children:[
42
- /* @__PURE__ */m("span",{className:"text-lg leading-none drop-shadow-sm",children:Z}),
43
- /* @__PURE__ */m("span",{className:"text-[11px] font-medium drop-shadow-sm truncate",children:X})]}),
44
- /* @__PURE__ */p("span",{className:"text-[10px] opacity-90 tabular-nums drop-shadow-sm shrink-0",children:["H:",V(k.high)," L:",V(k.low)]})]})]})]})}),
45
- /* @__PURE__ */p(i,{open:T,onClose:()=>A(!1),title:"Weather Settings",appearance:L,onAppearanceChange:C,onSave:()=>{w(F),N(L),B({weather_prefs:P}),localStorage.setItem(f,F),localStorage.setItem(u,JSON.stringify(L)),A(!1)},children:[
42
+ /* @__PURE__ */m("span",{className:"text-lg leading-none drop-shadow-sm",children:U}),
43
+ /* @__PURE__ */m("span",{className:"text-[11px] font-medium drop-shadow-sm truncate",children:Z})]}),
44
+ /* @__PURE__ */p("span",{className:"text-[10px] opacity-90 tabular-nums drop-shadow-sm shrink-0",children:["H:",M(k.high)," L:",M(k.low)]})]})]})]})}),
45
+ /* @__PURE__ */p(i,{open:T,onClose:()=>F(!1),title:"Weather Settings",appearance:L,onAppearanceChange:C,onSave:()=>{w(H),N(L),P({weather_prefs:O}),localStorage.setItem(f,H),localStorage.setItem(u,JSON.stringify(L)),F(!1)},children:[
46
46
  /* @__PURE__ */m("div",{className:"space-y-3",children:/* @__PURE__ */p("div",{children:[
47
47
  /* @__PURE__ */m("h3",{className:"text-sm font-semibold text-gray-700 mb-2",children:"Display"}),
48
48
  /* @__PURE__ */p("div",{className:"flex items-center gap-3 mb-2",children:[
49
49
  /* @__PURE__ */m("span",{className:"text-sm text-gray-600 w-24",children:"Temperature"}),
50
- /* @__PURE__ */m("div",{className:"flex gap-1",children:[{key:!1,label:"°C"},{key:!0,label:"°F"}].map(e=>/* @__PURE__ */m("button",{onClick:()=>M(t=>({...t,useFahrenheit:e.key})),className:"px-3 py-1 text-xs font-medium rounded-lg border transition-colors "+(P.useFahrenheit===e.key?"bg-blue-600 text-white border-blue-600":"bg-white text-gray-700 border-gray-300 hover:bg-gray-50"),children:e.label},String(e.key)))})]}),
50
+ /* @__PURE__ */m("div",{className:"flex gap-1",children:[{key:!1,label:"°C"},{key:!0,label:"°F"}].map(e=>/* @__PURE__ */m("button",{onClick:()=>X(t=>({...t,useFahrenheit:e.key})),className:"px-3 py-1 text-xs font-medium rounded-lg border transition-colors "+(O.useFahrenheit===e.key?"bg-blue-600 text-white border-blue-600":"bg-white text-gray-700 border-gray-300 hover:bg-gray-50"),children:e.label},String(e.key)))})]}),
51
51
  /* @__PURE__ */p("div",{className:"flex items-center gap-3 mb-2",children:[
52
52
  /* @__PURE__ */m("span",{className:"text-sm text-gray-600 w-24",children:"Time Format"}),
53
- /* @__PURE__ */m("div",{className:"flex gap-1",children:[{key:!1,label:"AM/PM"},{key:!0,label:"24H"}].map(e=>/* @__PURE__ */m("button",{onClick:()=>M(t=>({...t,use24Hour:e.key})),className:"px-3 py-1 text-xs font-medium rounded-lg border transition-colors "+(P.use24Hour===e.key?"bg-blue-600 text-white border-blue-600":"bg-white text-gray-700 border-gray-300 hover:bg-gray-50"),children:e.label},String(e.key)))})]}),
53
+ /* @__PURE__ */m("div",{className:"flex gap-1",children:[{key:!1,label:"AM/PM"},{key:!0,label:"24H"}].map(e=>/* @__PURE__ */m("button",{onClick:()=>X(t=>({...t,use24Hour:e.key})),className:"px-3 py-1 text-xs font-medium rounded-lg border transition-colors "+(O.use24Hour===e.key?"bg-blue-600 text-white border-blue-600":"bg-white text-gray-700 border-gray-300 hover:bg-gray-50"),children:e.label},String(e.key)))})]}),
54
54
  /* @__PURE__ */p("label",{className:"flex items-center gap-2 cursor-pointer",children:[
55
- /* @__PURE__ */m("input",{type:"checkbox",checked:P.showLocalTime,onChange:e=>M(t=>({...t,showLocalTime:e.target.checked})),className:"rounded border-gray-300 text-blue-600 h-3.5 w-3.5"}),
55
+ /* @__PURE__ */m("input",{type:"checkbox",checked:O.showLocalTime,onChange:e=>X(t=>({...t,showLocalTime:e.target.checked})),className:"rounded border-gray-300 text-blue-600 h-3.5 w-3.5"}),
56
56
  /* @__PURE__ */m("span",{className:"text-sm text-gray-600",children:"Show local time"})]})]})}),
57
57
  /* @__PURE__ */p("div",{children:[
58
58
  /* @__PURE__ */m("h3",{className:"text-sm font-semibold text-gray-700 mb-2",children:"City"}),
59
- /* @__PURE__ */m("select",{value:F,onChange:e=>H(e.target.value),className:"w-full bg-gray-50 border border-gray-200 rounded px-2 py-1.5 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:Object.keys(a).map(e=>/* @__PURE__ */m("option",{value:e,children:e},e))}),
60
- /* @__PURE__ */m("p",{className:"mt-1 text-[10px] text-gray-400",children:"Auto-detected from your timezone; change if needed."})]})]})]})}export{I as default};
59
+ /* @__PURE__ */m("select",{value:H,onChange:e=>A(e.target.value),className:"w-full bg-gray-50 border border-gray-200 rounded px-2 py-1.5 text-sm focus:outline-none focus:ring-1 focus:ring-blue-500",children:Object.keys(a).map(e=>/* @__PURE__ */m("option",{value:e,children:e},e))}),
60
+ /* @__PURE__ */m("p",{className:"mt-1 text-[10px] text-gray-400",children:"Auto-detected from your timezone; change if needed."})]})]})]})}export{D as default};
@@ -1,6 +1,6 @@
1
- import{AVAILABLE_CITIES as e,fetchCityWeather as t,getCondition as a,toFahrenheit as r}from"./chunk-FBDZGO3V.js";import{loadAppearance as n,WidgetSettingsModal as i}from"./chunk-M4AKWGQM.js";import{useWidgetSettings as s}from"./chunk-DLD4AKVT.js";import{useShellPrefs as c}from"./chunk-T6MKFQRH.js";import"./chunk-6UXY7MPY.js";import"./chunk-PH3PRIFP.js";import"./chunk-PDTZTADH.js";import"./chunk-VNEH2Y6H.js";import"./chunk-OSJ3ADF2.js";import"./chunk-MAIHBBWT.js";import"./chunk-VVI77XNV.js";import"./chunk-D65T4H6J.js";import{useState as l,useEffect as o,useCallback as m}from"react";import{jsxs as h,Fragment as d,jsx as p}from"react/jsx-runtime";var u="world_clock_appearance",g=["London","Shanghai","New York"];function x(){const{prefs:x,save:y}=c(),[b,f]=l(()=>n(u)),[k,v]=l(!1),[N,w]=l([]),[j,F]=l(b),D={useFahrenheit:!!x.weather_prefs?.useFahrenheit},[C,T]=l(D),[S,A]=l(()=>/* @__PURE__ */new Date);o(()=>{const e=setInterval(()=>A(/* @__PURE__ */new Date),3e4);return()=>clearInterval(e)},[]);const H=Object.fromEntries(Object.entries(e).map(([e,t])=>[t.tz,e])),P=x.world_clocks,I=(()=>{if(!Array.isArray(P)||0===P.length)return g;const t=[];for(const a of P){const r=e[a]?a:H[a];r&&!t.includes(r)&&t.push(r)}return t.length?t:g})(),[O,_]=l({}),[V,$]=l(!0);o(()=>{let e=!1;return $(!0),(async()=>{const a={};await Promise.all(I.map(async e=>{const r=await t(e);r&&(a[e]=r)})),e||(_(a),$(!1))})(),()=>{e=!0}},[I.join(",")]),s(m(()=>{w([...I]),F({...b}),T({...D}),v(!0)},[I.join(","),b,D.useFahrenheit]));const B=e=>D.useFahrenheit?`${r(e)}°`:`${e}°`;/* @__PURE__ */
1
+ import{AVAILABLE_CITIES as e,fetchCityWeather as t,getCondition as a,toFahrenheit as r}from"./chunk-FBDZGO3V.js";import{loadAppearance as n,WidgetSettingsModal as i}from"./chunk-XPSADW6W.js";import{useWidgetSettings as s}from"./chunk-X6E6UULK.js";import{useShellPrefs as c}from"./chunk-T6MKFQRH.js";import"./chunk-6UXY7MPY.js";import"./chunk-PH3PRIFP.js";import"./chunk-PDTZTADH.js";import"./chunk-VNEH2Y6H.js";import"./chunk-OSJ3ADF2.js";import"./chunk-MAIHBBWT.js";import"./chunk-VVI77XNV.js";import"./chunk-D65T4H6J.js";import{useState as l,useEffect as o,useCallback as m}from"react";import{jsxs as h,Fragment as d,jsx as p}from"react/jsx-runtime";var u="world_clock_appearance",g=["London","Shanghai","New York"];function x(){const{prefs:x,save:y}=c(),[b,f]=l(()=>n(u)),[k,v]=l(!1),[N,w]=l([]),[j,F]=l(b),D={useFahrenheit:!!x.weather_prefs?.useFahrenheit},[C,S]=l(D),[P,T]=l(()=>/* @__PURE__ */new Date);o(()=>{const e=setInterval(()=>T(/* @__PURE__ */new Date),3e4);return()=>clearInterval(e)},[]);const H=Object.fromEntries(Object.entries(e).map(([e,t])=>[t.tz,e])),A=x.world_clocks,I=(()=>{if(!Array.isArray(A)||0===A.length)return g;const t=[];for(const a of A){const r=e[a]?a:H[a];r&&!t.includes(r)&&t.push(r)}return t.length?t:g})(),[O,_]=l({}),[U,$]=l(!0);o(()=>{let e=!1;return $(!0),(async()=>{const a={};await Promise.all(I.map(async e=>{const r=await t(e);r&&(a[e]=r)})),e||(_(a),$(!1))})(),()=>{e=!0}},[I.join(",")]),s(m(()=>{w([...I]),F({...b}),S({...D}),v(!0)},[I.join(","),b,D.useFahrenheit]));const B=e=>D.useFahrenheit?`${r(e)}°`:`${e}°`;/* @__PURE__ */
2
2
  return h(d,{children:[
3
- /* @__PURE__ */p("div",{style:{backgroundColor:`rgb(var(--taskbar-bg-rgb, 243 244 246) / ${b.activeOpacity/100})`,backdropFilter:b.activeBlur>0?`blur(${b.activeBlur}px)`:void 0},children:/* @__PURE__ */h("div",{className:"divide-y divide-gray-200",children:[V&&I.every(e=>!O[e])&&/* @__PURE__ */p("div",{className:"px-3 py-6 text-center text-xs text-gray-500",children:"Loading…"}),I.map(t=>{const r=O[t],n=e[t]?.tz??"UTC",{time:i,ampm:s}=function(e,t){try{const a=new Intl.DateTimeFormat("en-US",{timeZone:e,hour:"numeric",minute:"2-digit",hour12:!0}).formatToParts(t),r=a.find(e=>"hour"===e.type)?.value||"12";return{time:`${r}:${a.find(e=>"minute"===e.type)?.value||"00"}`,ampm:(a.find(e=>"dayPeriod"===e.type)?.value||"").toUpperCase()}}catch{return{time:"",ampm:""}}}(n,S);if(!r)/* @__PURE__ */
3
+ /* @__PURE__ */p("div",{style:{backgroundColor:`rgb(var(--taskbar-bg-rgb, 243 244 246) / ${b.activeOpacity/100})`,backdropFilter:b.activeBlur>0?`blur(${b.activeBlur}px)`:void 0},children:/* @__PURE__ */h("div",{className:"divide-y divide-gray-200",children:[U&&I.every(e=>!O[e])&&/* @__PURE__ */p("div",{className:"px-3 py-6 text-center text-xs text-gray-500",children:"Loading…"}),I.map(t=>{const r=O[t],n=e[t]?.tz??"UTC",{time:i,ampm:s}=function(e,t){try{const a=new Intl.DateTimeFormat("en-US",{timeZone:e,hour:"numeric",minute:"2-digit",hour12:!0}).formatToParts(t),r=a.find(e=>"hour"===e.type)?.value||"12";return{time:`${r}:${a.find(e=>"minute"===e.type)?.value||"00"}`,ampm:(a.find(e=>"dayPeriod"===e.type)?.value||"").toUpperCase()}}catch{return{time:"",ampm:""}}}(n,P);if(!r)/* @__PURE__ */
4
4
  return h("div",{className:"px-4 py-3",children:[
5
5
  /* @__PURE__ */h("div",{className:"flex items-baseline justify-between gap-2",children:[
6
6
  /* @__PURE__ */p("span",{className:"text-[15px] font-semibold tracking-tight text-gray-900 truncate",children:t}),
@@ -24,7 +24,7 @@ return h("div",{className:"px-4 py-3",children:[
24
24
  /* @__PURE__ */p("h3",{className:"text-sm font-semibold text-gray-700 mb-2",children:"Display"}),
25
25
  /* @__PURE__ */h("div",{className:"flex items-center gap-3 mb-2",children:[
26
26
  /* @__PURE__ */p("span",{className:"text-sm text-gray-600 w-24",children:"Temperature"}),
27
- /* @__PURE__ */p("div",{className:"flex gap-1",children:[{key:!1,label:"°C"},{key:!0,label:"°F"}].map(e=>/* @__PURE__ */p("button",{onClick:()=>T(t=>({...t,useFahrenheit:e.key})),className:"px-3 py-1 text-xs font-medium rounded-lg border transition-colors "+(C.useFahrenheit===e.key?"bg-blue-600 text-white border-blue-600":"bg-white text-gray-700 border-gray-300 hover:bg-gray-50"),children:e.label},String(e.key)))})]}),
27
+ /* @__PURE__ */p("div",{className:"flex gap-1",children:[{key:!1,label:"°C"},{key:!0,label:"°F"}].map(e=>/* @__PURE__ */p("button",{onClick:()=>S(t=>({...t,useFahrenheit:e.key})),className:"px-3 py-1 text-xs font-medium rounded-lg border transition-colors "+(C.useFahrenheit===e.key?"bg-blue-600 text-white border-blue-600":"bg-white text-gray-700 border-gray-300 hover:bg-gray-50"),children:e.label},String(e.key)))})]}),
28
28
  /* @__PURE__ */p("p",{className:"text-[10px] text-gray-400 mt-1",children:"Shared with the Weather widget."})]}),
29
29
  /* @__PURE__ */h("div",{children:[
30
30
  /* @__PURE__ */p("h3",{className:"text-sm font-semibold text-gray-700 mb-2",children:"Cities"}),
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- export{openFilesInTrashMode,setFilesDemoTree}from"../chunk-JGHRZYNV.js";export{setBrowserStartUrl}from"../chunk-LWLCNQY7.js";export{BUILTIN_APP_INFO}from"../chunk-EI4WZOP3.js";import"../chunk-KZPQW6UL.js";import{setPdfPreview as e}from"../chunk-ESL5TDNA.js";export{setPdfPreview}from"../chunk-ESL5TDNA.js";import{toast_default as t}from"../chunk-B2TBCVHH.js";import{setSpreadsheetPreview as o}from"../chunk-VTVSMRFX.js";export{setSpreadsheetPreview}from"../chunk-VTVSMRFX.js";import"../chunk-L4KRS7N3.js";import"../chunk-DLD4AKVT.js";import"../chunk-T6MKFQRH.js";import"../chunk-6UXY7MPY.js";import"../chunk-PH3PRIFP.js";import"../chunk-PDTZTADH.js";import"../chunk-VNEH2Y6H.js";import"../chunk-OSJ3ADF2.js";import"../chunk-MAIHBBWT.js";import"../chunk-VVI77XNV.js";import"../chunk-D65T4H6J.js";import{lazy as i}from"react";function n(e){const t=/\.([a-z0-9]+)(?:[?#].*)?$/i.exec((e||"").trim());return t?t[1].toLowerCase():""}var r=/* @__PURE__ */new Set(["csv","tsv"]),s=/* @__PURE__ */new Set(["xlsx","xls","xlsm","ods"]),a=/* @__PURE__ */new Set(["png","jpg","jpeg","gif","webp","bmp","svg","avif"]),l=/* @__PURE__ */new Set(["step","stp","stl","obj","gltf","glb","3mf","iges","igs"]);function c(e){const t=n(e);return"pdf"===t?"pdf":"dxf"===t?"dxf":r.has(t)?"csv":a.has(t)?"image":l.has(t)?"3d":null}function p(e){window.open(e,"_blank","noopener,noreferrer")}async function m(e,t,o){if(t.fetchBlob)return(await t.fetchBlob(o)).text();const i=await fetch(e);if(!i.ok)throw new Error(`fetch failed: ${i.status}`);return i.text()}function u(e,t){return(e instanceof Error?e.message:"")||t}async function h(i,r,a={}){const l=i?.url||"",h=i?.filename||"attachment";if(!l&&!a.fetchBlob)return void t.error("This attachment has no download link.");const d=c(h)??c(l);if("csv"===d){try{o({csv:await m(l,a,i),filename:h}),r("/spreadsheet")}catch{t.error("Could not open the spreadsheet — opening the file instead."),l&&p(l)}return}if(s.has(n(h)||n(l)))return t.error("Spreadsheet preview is unavailable for this file type. Opening the file instead."),void(l&&p(l));if(!d)return l?(t.info("Opening this file outside the app — no viewer can show it here."),void p(l)):void t.error("This attachment has no download link.");if(!a.fetchBlob)return e({url:l,filename:h,kind:d}),void r("/preview");const f=e({filename:h,kind:d,converting:!0,convertingMessage:a.loadingMessage||"LOADING FILE"});r("/preview");try{const e=await a.fetchBlob(i);f.update({url:URL.createObjectURL(e),filename:h,kind:d})}catch(e){f.update({filename:h,kind:d,converting:!1,convertingMessage:u(e,"Failed to load this file.")})}}var d=i(()=>import("../Calculator-YBL65JNM.js")),f=i(()=>import("../Spreadsheet-6NK53IZV.js")),w=i(()=>import("../Weather-BBPTXGQA.js")),j=i(()=>import("../CurrencyConverter-6VFY4GF6.js")),k=i(()=>import("../PomodoroTimer-6OQ33FY3.js")),g=i(()=>import("../Notepad-RJ2DYW2O.js")),v=i(()=>import("../WorldClock-CQGQ2Y6N.js")),T=i(()=>import("../Stock-ZFLDG6TT.js")),b=i(()=>import("../Preview-3WRPZWDU.js")),P=i(()=>import("../PdfViewer-VIT7Y55M.js")),S=i(()=>import("../Documents-IPXRU4CT.js")),x=i(()=>import("../Files-3MGL4ZT7.js")),y=i(()=>import("../Browser-OQCHLKM3.js")),B={"/calculator":{component:d,label:"Calculator",size:"sm",allowPinOnTop:!0,utility:!0,widget:!0,dimensions:[280,420]},"/spreadsheet":{component:f,label:"Spreadsheets",size:"2xl",appStyle:!0,multiInstance:!0},"/notepad":{component:g,label:"Notepad",size:"lg",allowPinOnTop:!0,flushBody:!0},"/weather":{component:w,label:"Weather",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,400]},"/currency":{component:j,label:"Currency Converter",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,480]},"/pomodoro":{component:k,label:"Pomodoro Timer",size:"sm",utility:!0,widget:!0,dimensions:[320,600]},"/world-clock":{component:v,label:"World Clock",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,480]},"/stock":{component:T,label:"Stocks",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,360]}},I={"/preview":{component:b,label:"Preview",size:"2xl",appStyle:!0,multiInstance:!0},"/documents":{component:S,label:"Documents",size:"xl",appStyle:!0,multiInstance:!0},"/files":{component:x,label:"Files",size:"xl",appStyle:!0}},L={"/browser":{component:y,label:"Browser",size:"2xl",appStyle:!0,multiInstance:!0}},F={...B,...I,...L};export{y as Browser,d as Calculator,j as CurrencyConverter,S as Documents,x as Files,g as Notepad,P as PdfViewer,k as PomodoroTimer,b as Preview,f as Spreadsheet,T as Stock,w as Weather,v as WorldClock,c as attachmentKind,F as bundledApps,I as documentApps,h as openAttachment,B as utilityApps,L as webApps};
2
+ export{openFilesInTrashMode,setFilesDemoTree}from"../chunk-JGHRZYNV.js";export{setBrowserStartUrl}from"../chunk-LWLCNQY7.js";export{BUILTIN_APP_INFO}from"../chunk-A6FPBD7W.js";import"../chunk-KZPQW6UL.js";import{setPdfPreview as e}from"../chunk-ESL5TDNA.js";export{setPdfPreview}from"../chunk-ESL5TDNA.js";import{toast_default as t}from"../chunk-B2TBCVHH.js";import{setSpreadsheetPreview as o}from"../chunk-VTVSMRFX.js";export{setSpreadsheetPreview}from"../chunk-VTVSMRFX.js";import"../chunk-GF2XCISN.js";import"../chunk-X6E6UULK.js";import"../chunk-T6MKFQRH.js";import"../chunk-6UXY7MPY.js";import"../chunk-PH3PRIFP.js";import"../chunk-PDTZTADH.js";import"../chunk-VNEH2Y6H.js";import"../chunk-OSJ3ADF2.js";import"../chunk-MAIHBBWT.js";import"../chunk-VVI77XNV.js";import"../chunk-D65T4H6J.js";import{lazy as i}from"react";function n(e){const t=/\.([a-z0-9]+)(?:[?#].*)?$/i.exec((e||"").trim());return t?t[1].toLowerCase():""}var r=/* @__PURE__ */new Set(["csv","tsv"]),s=/* @__PURE__ */new Set(["xlsx","xls","xlsm","ods"]),a=/* @__PURE__ */new Set(["png","jpg","jpeg","gif","webp","bmp","svg","avif"]),l=/* @__PURE__ */new Set(["step","stp","stl","obj","gltf","glb","3mf","iges","igs"]);function c(e){const t=n(e);return"pdf"===t?"pdf":"dxf"===t?"dxf":r.has(t)?"csv":a.has(t)?"image":l.has(t)?"3d":null}function p(e){window.open(e,"_blank","noopener,noreferrer")}async function m(e,t,o){if(t.fetchBlob)return(await t.fetchBlob(o)).text();const i=await fetch(e);if(!i.ok)throw new Error(`fetch failed: ${i.status}`);return i.text()}function u(e,t){return(e instanceof Error?e.message:"")||t}async function h(i,r,a={}){const l=i?.url||"",h=i?.filename||"attachment";if(!l&&!a.fetchBlob)return void t.error("This attachment has no download link.");const d=c(h)??c(l);if("csv"===d){try{o({csv:await m(l,a,i),filename:h}),r("/spreadsheet")}catch{t.error("Could not open the spreadsheet — opening the file instead."),l&&p(l)}return}if(s.has(n(h)||n(l)))return t.error("Spreadsheet preview is unavailable for this file type. Opening the file instead."),void(l&&p(l));if(!d)return l?(t.info("Opening this file outside the app — no viewer can show it here."),void p(l)):void t.error("This attachment has no download link.");if(!a.fetchBlob)return e({url:l,filename:h,kind:d}),void r("/preview");const f=e({filename:h,kind:d,converting:!0,convertingMessage:a.loadingMessage||"LOADING FILE"});r("/preview");try{const e=await a.fetchBlob(i);f.update({url:URL.createObjectURL(e),filename:h,kind:d})}catch(e){f.update({filename:h,kind:d,converting:!1,convertingMessage:u(e,"Failed to load this file.")})}}var d=i(()=>import("../Calculator-QLJJ3ICT.js")),f=i(()=>import("../Spreadsheet-PFKZTLSI.js")),w=i(()=>import("../Weather-AY3QWBQT.js")),j=i(()=>import("../CurrencyConverter-3GTKDKHH.js")),k=i(()=>import("../PomodoroTimer-CRKL26PP.js")),g=i(()=>import("../Notepad-ITHIATP2.js")),v=i(()=>import("../WorldClock-AXNMA4PG.js")),T=i(()=>import("../Stock-NAHSVLAJ.js")),S=i(()=>import("../Preview-GZTTEZWS.js")),b=i(()=>import("../PdfViewer-VIT7Y55M.js")),P=i(()=>import("../Documents-FDGF7QBQ.js")),x=i(()=>import("../Files-TTSYOPVB.js")),y=i(()=>import("../Browser-3KOGROX7.js")),I={"/calculator":{component:d,label:"Calculator",size:"sm",allowPinOnTop:!0,utility:!0,widget:!0,dimensions:[280,420]},"/spreadsheet":{component:f,label:"Spreadsheets",size:"2xl",appStyle:!0,multiInstance:!0},"/notepad":{component:g,label:"Notepad",size:"lg",allowPinOnTop:!0,flushBody:!0},"/weather":{component:w,label:"Weather",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,400]},"/currency":{component:j,label:"Currency Converter",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,480]},"/pomodoro":{component:k,label:"Pomodoro Timer",size:"sm",utility:!0,widget:!0,dimensions:[320,600]},"/world-clock":{component:v,label:"World Clock",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,480]},"/stock":{component:T,label:"Stocks",size:"sm",utility:!0,widget:!0,autoHeight:!0,dimensions:[320,360]}},B={"/preview":{component:S,label:"Preview",size:"2xl",appStyle:!0,multiInstance:!0},"/documents":{component:P,label:"Documents",size:"xl",appStyle:!0,multiInstance:!0},"/files":{component:x,label:"Files",size:"xl",appStyle:!0}},H={"/browser":{component:y,label:"Browser",size:"2xl",appStyle:!0,multiInstance:!0}},F={...I,...B,...H};export{y as Browser,d as Calculator,j as CurrencyConverter,P as Documents,x as Files,g as Notepad,b as PdfViewer,k as PomodoroTimer,S as Preview,f as Spreadsheet,T as Stock,w as Weather,v as WorldClock,c as attachmentKind,F as bundledApps,B as documentApps,h as openAttachment,I as utilityApps,H as webApps};
@@ -1,4 +1,4 @@
1
- import{VERSION as e}from"./chunk-L4KRS7N3.js";import{useWindowMenuItem as t,Modal as r}from"./chunk-DLD4AKVT.js";import{navIcons as o}from"./chunk-6UXY7MPY.js";import{useState as n,useCallback as s,isValidElement as i,cloneElement as a}from"react";import{jsx as l,jsxs as d}from"react/jsx-runtime";var c={spreadsheet:{name:"Spreadsheets",version:"1.1.3",route:"/spreadsheet",description:"Multi-sheet spreadsheet editor with CSV / TSV import and export."},notepad:{name:"Notepad",version:"1.0.1",route:"/notepad",description:"Color-coded notes with checklists, desktop stickies and entity autolinking."},documents:{name:"Documents",version:"1.1.0",route:"/documents",description:"Letter-page editor for Word documents and plain-text files — images, lists, alignment."},preview:{name:"Preview",version:"1.4.1",route:"/preview",description:"Viewer for PDF documents, images, DXF drawings and 3D models — CAD-style measuring with object snap and an AutoCAD-like command bar."},files:{name:"Files",version:"1.1.1",route:"/files",description:"Personal file manager with folders, uploads, quota, trash and desktop shortcut folders."},browser:{name:"Browser",version:"1.0.1",route:"/browser",description:"Minimal web browser with bookmarks, history and navigation bar."}},m=/* @__PURE__ */l("svg",{className:"h-4 w-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */l("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M11.25 11.25l.041-.02a.75.75 0 011.063.852l-.708 2.836a.75.75 0 001.063.853l.041-.021M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9-3.75h.008v.008H12V8.25z"})}),p=/* @__PURE__ */l("svg",{className:"h-9 w-9",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */l("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 6.75A2.25 2.25 0 016 4.5h12a2.25 2.25 0 012.25 2.25v10.5A2.25 2.25 0 0118 19.5H6a2.25 2.25 0 01-2.25-2.25V6.75z M3.75 9h16.5"})});function h({app:h}){const u=c[h],[x,f]=n(!1),g=s(()=>f(!0),[]);if(t(`About ${u.name}`,g,m),!x)return null;const v=o[u.route],w=i(v)?a(v,{className:"h-9 w-9"}):p;/* @__PURE__ */
1
+ import{VERSION as e}from"./chunk-GF2XCISN.js";import{useWindowMenuItem as t,Modal as r}from"./chunk-X6E6UULK.js";import{navIcons as o}from"./chunk-6UXY7MPY.js";import{useState as n,useCallback as s,isValidElement as i,cloneElement as a}from"react";import{jsx as l,jsxs as d}from"react/jsx-runtime";var c={spreadsheet:{name:"Spreadsheets",version:"1.1.3",route:"/spreadsheet",description:"Multi-sheet spreadsheet editor with CSV / TSV import and export."},notepad:{name:"Notepad",version:"1.0.1",route:"/notepad",description:"Color-coded notes with checklists, desktop stickies and entity autolinking."},documents:{name:"Documents",version:"1.1.0",route:"/documents",description:"Letter-page editor for Word documents and plain-text files — images, lists, alignment."},preview:{name:"Preview",version:"1.4.1",route:"/preview",description:"Viewer for PDF documents, images, DXF drawings and 3D models — CAD-style measuring with object snap and an AutoCAD-like command bar."},files:{name:"Files",version:"1.1.1",route:"/files",description:"Personal file manager with folders, uploads, quota, trash and desktop shortcut folders."},browser:{name:"Browser",version:"1.0.1",route:"/browser",description:"Minimal web browser with bookmarks, history and navigation bar."}},m=/* @__PURE__ */l("svg",{className:"h-4 w-4 text-gray-400",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */l("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M11.25 11.25l.041-.02a.75.75 0 011.063.852l-.708 2.836a.75.75 0 001.063.853l.041-.021M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9-3.75h.008v.008H12V8.25z"})}),p=/* @__PURE__ */l("svg",{className:"h-9 w-9",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */l("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 6.75A2.25 2.25 0 016 4.5h12a2.25 2.25 0 012.25 2.25v10.5A2.25 2.25 0 0118 19.5H6a2.25 2.25 0 01-2.25-2.25V6.75z M3.75 9h16.5"})});function h({app:h}){const u=c[h],[x,f]=n(!1),g=s(()=>f(!0),[]);if(t(`About ${u.name}`,g,m),!x)return null;const v=o[u.route],w=i(v)?a(v,{className:"h-9 w-9"}):p;/* @__PURE__ */
2
2
  return l(r,{open:!0,onClose:()=>f(!1),title:`About ${u.name}`,size:"sm",compact:!0,bodyScroll:!1,autoHeight:!0,dimensions:[320,320],children:/* @__PURE__ */d("div",{className:"flex flex-col items-center text-center px-5 pt-5 pb-4",children:[
3
3
  /* @__PURE__ */l("div",{className:"flex h-16 w-16 items-center justify-center rounded-2xl bg-gray-100 text-gray-600 shrink-0",children:w}),
4
4
  /* @__PURE__ */l("h2",{className:"mt-3 text-lg font-bold text-gray-900",children:u.name}),
@@ -0,0 +1 @@
1
+ var r="4.160.0",a=r;export{a as APP_VERSION,r as VERSION};
@@ -1 +1 @@
1
- import{client_default as a}from"./chunk-DLD4AKVT.js";var e=()=>a.get("/auth/numbering-configs/").then(a=>a.data?.results??a.data??[]),t="uploaded:wallpaper";function r(a,e){return"string"!=typeof a||!a||"none"===a||a.startsWith("#")?"":a===t?e||"":a}var p=()=>a.get("/auth/me/wallpaper/").then(a=>a.data),n=e=>{const t=new FormData;return t.append("wallpaper",e),a.post("/auth/me/wallpaper/",t).then(a=>a.data)},l=()=>a.delete("/auth/me/wallpaper/").then(a=>a.data);function s(a){const e=a?.response?.status,t=a?.response?.data,r=Array.isArray(t?.wallpaper)?t.wallpaper[0]:void 0;return r||(413===e?"That picture is too large to use as a wallpaper.":415===e?"That file is not a picture this can use as a wallpaper.":"The wallpaper could not be saved. Please try again.")}export{t as WALLPAPER_PREF_TOKEN,l as deleteWallpaper,e as getNumberingConfigs,p as getWallpaper,n as uploadWallpaper,r as wallpaperSrc,s as wallpaperUploadError};
1
+ import{client_default as a}from"./chunk-X6E6UULK.js";var e=()=>a.get("/auth/numbering-configs/").then(a=>a.data?.results??a.data??[]),t="uploaded:wallpaper";function r(a,e){return"string"!=typeof a||!a||"none"===a||a.startsWith("#")?"":a===t?e||"":a}var p=()=>a.get("/auth/me/wallpaper/").then(a=>a.data),n=e=>{const t=new FormData;return t.append("wallpaper",e),a.post("/auth/me/wallpaper/",t).then(a=>a.data)},l=()=>a.delete("/auth/me/wallpaper/").then(a=>a.data);function s(a){const e=a?.response?.status,t=a?.response?.data,r=Array.isArray(t?.wallpaper)?t.wallpaper[0]:void 0;return r||(413===e?"That picture is too large to use as a wallpaper.":415===e?"That file is not a picture this can use as a wallpaper.":"The wallpaper could not be saved. Please try again.")}export{t as WALLPAPER_PREF_TOKEN,l as deleteWallpaper,e as getNumberingConfigs,p as getWallpaper,n as uploadWallpaper,r as wallpaperSrc,s as wallpaperUploadError};
@@ -1,16 +1,16 @@
1
- import{glassStyle as e}from"./chunk-VNEH2Y6H.js";import{useDismissPopupsOnOpen as r,Z_LAYERS as t}from"./chunk-OSJ3ADF2.js";import{useShellStrings as a}from"./chunk-VVI77XNV.js";import{useState as n,useEffect as l,useRef as o,useCallback as s}from"react";import{jsx as i,jsxs as d}from"react/jsx-runtime";import{createPortal as c}from"react-dom";var m={favicon:"h-8 w-8",compact:"h-10 w-10",wordmark:"h-10 w-40"};function h(e){return e.trim().charAt(0).toLocaleUpperCase()||"·"}function p(e,r,t){return!1===e?"framed":null==e||null==r?"plate-light":r?"light"===t?"plate-dark":"bare":"dark"===t?"plate-light":"bare"}var u={"plate-light":"bg-white shadow-[0_2px_12px_var(--rosh-mark-plate-shadow)]","plate-dark":"bg-neutral-900 shadow-[0_2px_12px_var(--rosh-mark-plate-shadow-strong)]",framed:"border border-black/10 shadow-[0_2px_12px_var(--rosh-mark-plate-shadow)]",bare:""};function g(e,r,t){return"bare"===e?{}:"framed"===e?{borderRadius:r}:{borderRadius:r,padding:t}}function x({src:e,fallbackSrc:r,fallbackHasAlpha:t=null,fallbackIsLight:a=null,fallbackAdaptive:o,alt:s,slot:d="compact",surface:c="light",size:x,width:b,height:f,decorative:y=!1,fallbackMode:v="monogram",adaptive:k=!1,hasAlpha:w=null,isLight:N=null,treatmentPadding:j=4,treatmentRadius:E=8,className:L="",style:C}){const[_,A]=n(e||r||"");l(()=>{A(e||r||"")},[e,r]);const $=Boolean(r&&_===r&&_!==e),D=($?o??k:k)?p($?t:w,$?a:N,c):"bare",B=["inline-flex shrink-0 items-center justify-center overflow-hidden",null==x&&null==b&&null==f?m[d]:"","dark"===c?"text-white":"text-gray-700",u[D],L].filter(Boolean).join(" "),K={...g(D,E,j),...null==x?{width:b,height:f}:{width:x,height:x},...C};return _?/* @__PURE__ */i("span",{className:B,"data-brand-treatment":D,style:K,children:/* @__PURE__ */i("img",{src:_,alt:y?"":s,"data-brand-slot":d,className:"block max-h-full max-w-full",style:{objectFit:"contain"},onError:()=>A(e=>r&&e!==r?r:"")})}):"none"===v?null:/* @__PURE__ */i("span",{"data-brand-fallback":!0,"data-brand-slot":d,"aria-label":y?void 0:s,"aria-hidden":y||void 0,role:y?void 0:"img",className:`${B} rounded-md bg-gray-100 font-semibold`,style:K,children:y?null:h(s)})}var b="M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607z",f="react-os-shell:open-global-search";function y(){"undefined"!=typeof window&&window.dispatchEvent(new CustomEvent(f))}function v({providers:m,typeIcons:h,placeholder:p,onSelect:u}={}){const g=a().search,x=p??g.placeholder,[y,v]=n(!1),[k,w]=n(""),[N,j]=n([]),[E,L]=n(!1),[C,_]=n(0),A=o(null),$=o();l(()=>{const e=e=>{(e.ctrlKey||e.metaKey)&&"k"===e.key&&(e.preventDefault(),v(e=>!e)),"Escape"===e.key&&y&&v(!1)},r=()=>v(!0);return window.addEventListener("keydown",e),window.addEventListener(f,r),()=>{window.removeEventListener("keydown",e),window.removeEventListener(f,r)}},[y]),r(y),l(()=>{y?setTimeout(()=>A.current?.focus(),50):(w(""),j([]))},[y]),l(()=>{if($.current&&clearTimeout($.current),k.length<2)j([]);else{if(m&&0!==m.length)return $.current=setTimeout(async()=>{L(!0);try{const e=await Promise.all(m.map(e=>e(k).catch(()=>[])));j(e.flat()),_(0)}catch{j([])}L(!1)},250),()=>{$.current&&clearTimeout($.current)};j([])}},[k,m]);const D=s(e=>{v(!1),u?.(e)},[u]);return y?c(
1
+ import{glassStyle as e}from"./chunk-VNEH2Y6H.js";import{useDismissPopupsOnOpen as r,Z_LAYERS as t}from"./chunk-OSJ3ADF2.js";import{useShellStrings as a}from"./chunk-VVI77XNV.js";import{useState as n,useEffect as l,useRef as o,useCallback as s}from"react";import{jsx as i,jsxs as d}from"react/jsx-runtime";import{createPortal as c}from"react-dom";var m={favicon:"h-8 w-8",compact:"h-10 w-10",wordmark:"h-10 w-40"};function h(e){return e.trim().charAt(0).toLocaleUpperCase()||"·"}function u(e,r,t){return!1===e?"framed":null==e||null==r?"plate-light":r?"light"===t?"plate-dark":"bare":"dark"===t?"plate-light":"bare"}var p={"plate-light":"bg-white shadow-[0_2px_12px_var(--rosh-mark-plate-shadow)]","plate-dark":"bg-neutral-900 shadow-[0_2px_12px_var(--rosh-mark-plate-shadow-strong)]",framed:"border border-black/10 shadow-[0_2px_12px_var(--rosh-mark-plate-shadow)]",bare:""};function g(e,r,t){return"bare"===e?{}:"framed"===e?{borderRadius:r}:{borderRadius:r,padding:t}}function b({src:e,fallbackSrc:r,fallbackHasAlpha:t=null,fallbackIsLight:a=null,fallbackAdaptive:o,alt:s,slot:d="compact",surface:c="light",size:b,width:x,height:f,decorative:y=!1,fallbackMode:v="monogram",adaptive:k=!1,hasAlpha:w=null,isLight:N=null,treatmentPadding:C=4,treatmentRadius:j=8,className:E="",style:L}){const[A,_]=n(e||r||"");l(()=>{_(e||r||"")},[e,r]);const $=Boolean(r&&A===r&&A!==e),D=($?o??k:k)?u($?t:w,$?a:N,c):"bare",B=["inline-flex shrink-0 items-center justify-center overflow-hidden",null==b&&null==x&&null==f?m[d]:"","dark"===c?"text-white":"text-gray-700",p[D],E].filter(Boolean).join(" "),K={...g(D,j,C),...null==b?{width:x,height:f}:{width:b,height:b},...L};return A?/* @__PURE__ */i("span",{className:B,"data-brand-treatment":D,style:K,children:/* @__PURE__ */i("img",{src:A,alt:y?"":s,"data-brand-slot":d,className:"block max-h-full max-w-full",style:{objectFit:"contain"},onError:()=>_(e=>r&&e!==r?r:"")})}):"none"===v?null:/* @__PURE__ */i("span",{"data-brand-fallback":!0,"data-brand-slot":d,"aria-label":y?void 0:s,"aria-hidden":y||void 0,role:y?void 0:"img",className:`${B} rounded-md bg-gray-100 font-semibold`,style:K,children:y?null:h(s)})}var x="M21 21l-5.197-5.197m0 0A7.5 7.5 0 105.196 5.196a7.5 7.5 0 0010.607 10.607z",f="react-os-shell:open-global-search";function y(){"undefined"!=typeof window&&window.dispatchEvent(new CustomEvent(f))}function v({providers:m,typeIcons:h,placeholder:u,onSelect:p}={}){const g=a().search,b=u??g.placeholder,[y,v]=n(!1),[k,w]=n(""),[N,C]=n([]),[j,E]=n(!1),[L,A]=n(0),_=o(null),$=o(),D=o(function(){let e=0,r=null;const t=()=>{e+=1,r?.abort(),r=null};return{begin:()=>{t();const a=e,n=new AbortController;return r=n,{signal:n.signal,isCurrent:()=>a===e}},cancel:t}}());l(()=>{const e=e=>{(e.ctrlKey||e.metaKey)&&"k"===e.key&&(e.preventDefault(),v(e=>!e)),"Escape"===e.key&&y&&v(!1)},r=()=>v(!0);return window.addEventListener("keydown",e),window.addEventListener(f,r),()=>{window.removeEventListener("keydown",e),window.removeEventListener(f,r)}},[y]),r(y),l(()=>{y?setTimeout(()=>_.current?.focus(),50):(w(""),C([]))},[y]),l(()=>{const e=D.current;return $.current&&clearTimeout($.current),k.length<2||!m||0===m.length?(e.cancel(),C([]),void E(!1)):($.current=setTimeout(async()=>{const r=e.begin();E(!0);const t=await Promise.all(m.map(async e=>{try{return await e(k,{signal:r.signal})}catch{return[]}}));r.isCurrent()&&(C(t.flat()),A(0),E(!1))},250),()=>{$.current&&clearTimeout($.current),e.cancel()})},[k,m]);const B=s(e=>{v(!1),p?.(e)},[p]);return y?c(
2
2
  /* @__PURE__ */d("div",{"data-global-search":"",className:"fixed inset-0 flex items-start justify-center pt-[15vh]",style:{zIndex:t.overlay},onClick:()=>v(!1),children:[
3
3
  /* @__PURE__ */i("div",{"data-global-search-backdrop":"",className:"absolute inset-0 bg-black/50 backdrop-blur-sm"}),
4
4
  /* @__PURE__ */d("div",{className:"relative z-10 w-full max-w-xl rounded-2xl overflow-hidden",onClick:e=>e.stopPropagation(),style:e(),children:[
5
5
  /* @__PURE__ */d("div",{className:"flex items-center gap-3 px-4 py-3 border-b border-gray-200",children:[
6
- /* @__PURE__ */i("svg",{className:"h-5 w-5 text-gray-400 shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:/* @__PURE__ */i("path",{strokeLinecap:"round",strokeLinejoin:"round",d:b})}),
7
- /* @__PURE__ */i("input",{ref:A,type:"text",value:k,onChange:e=>w(e.target.value),onKeyDown:e=>{"ArrowDown"===e.key?(e.preventDefault(),_(e=>Math.min(e+1,N.length-1))):"ArrowUp"===e.key?(e.preventDefault(),_(e=>Math.max(e-1,0))):"Enter"===e.key&&N[C]&&D(N[C])},placeholder:x,className:"flex-1 text-sm bg-transparent border-0 rosh-focus-ring placeholder-gray-400"}),
6
+ /* @__PURE__ */i("svg",{className:"h-5 w-5 text-gray-400 shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:/* @__PURE__ */i("path",{strokeLinecap:"round",strokeLinejoin:"round",d:x})}),
7
+ /* @__PURE__ */i("input",{ref:_,type:"text",value:k,onChange:e=>w(e.target.value),onKeyDown:e=>{"ArrowDown"===e.key?(e.preventDefault(),A(e=>Math.min(e+1,N.length-1))):"ArrowUp"===e.key?(e.preventDefault(),A(e=>Math.max(e-1,0))):"Enter"===e.key&&N[L]&&B(N[L])},placeholder:b,className:"flex-1 text-sm bg-transparent border-0 rosh-focus-ring placeholder-gray-400"}),
8
8
  /* @__PURE__ */i("kbd",{className:"hidden sm:inline-flex items-center rounded border border-gray-300 px-1.5 py-0.5 text-[10px] font-medium text-gray-400",children:g.escBadge})]}),
9
- /* @__PURE__ */d("div",{className:"max-h-[50vh] overflow-y-auto",children:[E&&/* @__PURE__ */i("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:g.searching}),!E&&k.length>=2&&0===N.length&&/* @__PURE__ */i("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:g.noResults}),!E&&N.length>0&&/* @__PURE__ */i("ul",{className:"py-2",children:N.map((e,r)=>/* @__PURE__ */i("li",{children:/* @__PURE__ */d("button",{className:"flex items-center gap-3 w-full px-4 py-2.5 text-left transition-colors "+(r===C?"bg-blue-50":"hover:bg-gray-50"),onClick:()=>D(e),onMouseEnter:()=>_(r),children:[
10
- /* @__PURE__ */i("svg",{className:"h-4 w-4 text-gray-400 shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */i("path",{strokeLinecap:"round",strokeLinejoin:"round",d:h?.[e.type]||b})}),
9
+ /* @__PURE__ */d("div",{className:"max-h-[50vh] overflow-y-auto",children:[j&&/* @__PURE__ */i("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:g.searching}),!j&&k.length>=2&&0===N.length&&/* @__PURE__ */i("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:g.noResults}),!j&&N.length>0&&/* @__PURE__ */i("ul",{className:"py-2",children:N.map((e,r)=>/* @__PURE__ */i("li",{children:/* @__PURE__ */d("button",{className:"flex items-center gap-3 w-full px-4 py-2.5 text-left transition-colors "+(r===L?"bg-blue-50":"hover:bg-gray-50"),onClick:()=>B(e),onMouseEnter:()=>A(r),children:[
10
+ /* @__PURE__ */i("svg",{className:"h-4 w-4 text-gray-400 shrink-0",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:1.5,children:/* @__PURE__ */i("path",{strokeLinecap:"round",strokeLinejoin:"round",d:h?.[e.type]||x})}),
11
11
  /* @__PURE__ */d("div",{className:"flex-1 min-w-0",children:[
12
12
  /* @__PURE__ */i("p",{className:"text-sm font-medium text-gray-900 truncate",children:e.label}),e.sub&&/* @__PURE__ */i("p",{className:"text-xs text-gray-400 truncate",children:e.sub})]}),
13
- /* @__PURE__ */i("span",{className:"shrink-0 rounded-full bg-gray-100 px-2 py-0.5 text-[10px] font-medium text-gray-500",children:e.type})]})},`${e.type}-${e.label}-${r}`))}),!E&&k.length<2&&/* @__PURE__ */i("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:g.minChars(2)})]}),
13
+ /* @__PURE__ */i("span",{className:"shrink-0 rounded-full bg-gray-100 px-2 py-0.5 text-[10px] font-medium text-gray-500",children:e.type})]})},`${e.type}-${e.label}-${r}`))}),!j&&k.length<2&&/* @__PURE__ */i("div",{className:"px-4 py-6 text-center text-sm text-gray-400",children:g.minChars(2)})]}),
14
14
  /* @__PURE__ */d("div",{className:"flex items-center justify-between px-4 py-2 border-t border-gray-100 bg-gray-50 text-[11px] text-gray-400",children:[
15
15
  /* @__PURE__ */d("div",{className:"flex items-center gap-3",children:[
16
16
  /* @__PURE__ */d("span",{className:"flex items-center gap-1",children:[
@@ -19,4 +19,4 @@ import{glassStyle as e}from"./chunk-VNEH2Y6H.js";import{useDismissPopupsOnOpen a
19
19
  /* @__PURE__ */d("span",{className:"flex items-center gap-1",children:[
20
20
  /* @__PURE__ */i("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:g.enterKey}),` ${g.open}`]})]}),
21
21
  /* @__PURE__ */d("span",{className:"flex items-center gap-1",children:[
22
- /* @__PURE__ */i("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:g.escKey}),` ${g.close}`]})]})]})]}),document.body):null}export{x as BrandMark,v as GlobalSearch,y as openGlobalSearch,p as resolveBrandMarkTreatment};
22
+ /* @__PURE__ */i("kbd",{className:"rounded border border-gray-300 px-1 py-0.5 font-medium",children:g.escKey}),` ${g.close}`]})]})]})]}),document.body):null}export{b as BrandMark,v as GlobalSearch,y as openGlobalSearch,u as resolveBrandMarkTreatment};