@stacksjs/desktop 0.2.698 → 0.2.701

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -894,7 +894,7 @@ window.stxWindow = {
894
894
 
895
895
  // Expose as global for backwards compatibility
896
896
  window.desktop = window.stxWindow;
897
- `}import{accessSync as _n,closeSync as Nn,constants as Fn,openSync as Wn,readSync as zn,realpathSync as Hn}from"fs";import{resolveCraftBinary as Un}from"craft-native";import{macOSRuntimeExecutablePath as Vn,pack as jn,packageApp as Kn}from"craft-native";import{craftBinaryNotFoundMessage as Gn,resolveCraftBinary as Yn}from"craft-native";function qn(e){let t=Un(e),r=t;if(t==="craft"){let l=Bun.spawnSync(["pantry","which","craft","--resolve"]);if(l.exitCode!==0){let d=`${l.stderr}${l.stdout}`.trim();throw Error(`Cannot locate Craft's native executable. Install Craft through Pantry and use Pantry 0.11.114 or newer.${d?` ${d}`:""}`)}r=l.stdout.toString().trim()}let n=Hn(r);_n(n,Fn.X_OK);let o=Wn(n,"r"),a=Buffer.alloc(4);try{zn(o,a,0,a.length,0)}finally{Nn(o)}let s=a.readUInt32BE(0);if(!(process.platform==="darwin"?[4277009102,3472551422,4277009103,3489328638,3405691582,3199925962,3405691583,3216703178].includes(s):process.platform==="win32"?a[0]===77&&a[1]===90:s===2135247942))throw Error(`Craft packaging requires a native executable, received: ${n}`);return n}import K from"process";import{spawn as Xn}from"child_process";import{AutoUpdater as Ze,canReplaceBundle as Jn,clearQuarantine as Qn,extractBundle as Zn,generateUpdateManifest as et,readBundleIdentity as Pe,swapBundle as eo,verifyBundleTrust as to}from"craft-native";var tt="update.json";function rt(e,t){return`https://github.com/${e}/releases/latest/download/${t}`}function nt(e,t,r){return`https://github.com/${e}/releases/download/${t}/${r}`}function ot(e){let{repository:t,manifestAsset:r=tt,...n}=e;return new Ze({...n,updateUrl:rt(t,r)})}function ro(e){let t=e.tag??`v${e.version}`,r={};for(let[n,o]of Object.entries(e.artifacts)){if(!o)continue;r[n]={path:o,url:nt(e.repository,t,o.split("/").pop())}}return et({version:e.version,releaseNotes:e.releaseNotes,platforms:r})}function oe(e=K.execPath){let t=e.split("/");for(let r=0;r<t.length;r++)if(t[r].endsWith(".app"))return t.slice(0,r+1).join("/");return null}async function no(){let e=oe();if(!e)return null;return(await Pe(e)).teamId}function it(){let e=K.ppid;if(e>1)try{K.kill(e,"SIGTERM");return}catch{}K.exit(0)}function at(e={}){let t=e.appPath??oe(),r=e.quit??(()=>K.exit(0));if(t)Xn("/usr/bin/open",["-n",t],{detached:!0,stdio:"ignore"}).unref();let n=e.quitDelayMs??0;if(n>0){setTimeout(r,n).unref?.();return}r()}async function oo(e){let{appPath:t,requireSameTeam:r=!0,macos:n,...o}=e,a=t??oe();if(!a)throw Error("createSelfUpdater: this process is not running from an .app bundle, so there is nothing to update. Pass `appPath` explicitly, or skip the updater in development.");let s=n?.teamId??(r?(await Pe(a)).teamId??void 0:void 0);return ot({...o,appPath:a,macos:{...n,teamId:s},relaunch:e.relaunch??((c)=>at({appPath:c,quit:it,quitDelayMs:250}))})}function st(e){if(typeof process>"u"||process.platform!=="darwin")throw Error("Caffeinate requires macOS");let{dlopen:t,ptr:r}=ue("bun:ffi"),n=t("/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation",{CFStringCreateWithCString:{args:["ptr","ptr","u32"],returns:"ptr"},CFRelease:{args:["ptr"],returns:"void"}}),o=t("/System/Library/Frameworks/IOKit.framework/IOKit",{IOPMAssertionCreateWithName:{args:["ptr","u32","ptr","ptr"],returns:"i32"},IOPMAssertionRelease:{args:["u32"],returns:"i32"},IOPMAssertionDeclareUserActivity:{args:["ptr","u32","ptr"],returns:"i32"}}),a=[],s=!1;function c(){if(s)return;s=!0;for(let d of a)o.symbols.IOPMAssertionRelease(d);o.close(),n.close()}function l(d){let p=Buffer.from(`${d}\x00`),f=n.symbols.CFStringCreateWithCString(null,r(p),134217984);if(!f)throw Error("Could not create power assertion name");return f}try{let d=[[e.preventDisplaySleep??!0,"PreventUserIdleDisplaySleep"],[e.preventIdleSleep??!0,"PreventUserIdleSystemSleep"],[e.preventSystemSleep??!0,"PreventSystemSleep"],[e.preventDiskSleep??!1,"PreventDiskIdle"]];for(let[p,f]of d){if(!p)continue;let u=l(e.reason||"stx: keeping your Mac awake"),h=l(f),w=new Uint32Array(1);try{let P=o.symbols.IOPMAssertionCreateWithName(h,255,u,r(w));if(P!==0)throw Error(`Could not acquire ${f} (${P})`);a.push(w[0])}finally{n.symbols.CFRelease(u),n.symbols.CFRelease(h)}}if(!a.length)throw Error("At least one sleep prevention option must be enabled");if(e.assertUserActivity??!0){let p=l("stx: user activity"),f=new Uint32Array(1);try{let u=o.symbols.IOPMAssertionDeclareUserActivity(p,0,r(f));if(u!==0)throw Error(`Could not declare user activity (${u})`);a.push(f[0])}finally{n.symbols.CFRelease(p)}}return c}catch(d){throw c(),d}}var A=null;class ct{_release;_startedAt;_endsAt;_options;_expireHandlers=[];_expireTimer=null;_stopped=!1;constructor(e,t){this._release=e,this._options={...t},this._startedAt=new Date;let r=t.duration;if(r&&r>0){let n=r*60*1000;this._endsAt=new Date(this._startedAt.getTime()+n),this._expireTimer=setTimeout(()=>{this.stop();for(let o of this._expireHandlers)try{o()}catch{}},n)}else this._endsAt=null}get pid(){return process.pid}get startedAt(){return this._startedAt}get endsAt(){return this._endsAt}get options(){return{...this._options}}get isActive(){return!this._stopped}get remainingMs(){if(!this._endsAt)return null;let e=this._endsAt.getTime()-Date.now();return Math.max(0,e)}get elapsedMs(){return Date.now()-this._startedAt.getTime()}stop(){if(this._stopped)return;if(this._stopped=!0,this._expireTimer)clearTimeout(this._expireTimer),this._expireTimer=null;this._release()}onExpire(e){this._expireHandlers.push(e)}}function io(e={}){if(e.duration!==void 0&&e.duration!==-1&&(!Number.isFinite(e.duration)||e.duration<=0))throw RangeError("duration must be positive minutes or -1 for indefinitely");let t=st(e),r=new ct(t,e);return Se(),A=r,r}function Se(e){if(e){if(e.stop(),A===e)A=null;return}if(A)A.stop();A=null}function ao(){return A!==null&&A.isActive}function so(){if(!A||!A.isActive)return{active:!1,instance:null,startedAt:null,endsAt:null,durationMinutes:null};let t=A.options.duration;return{active:!0,instance:A,startedAt:A.startedAt,endsAt:A.endsAt,durationMinutes:t&&t>0?t:-1}}function co(e){let t=e||A;if(!t||!t.isActive)return"0:00";let r=t.remainingMs;if(r===null)return"\u221E";let n=Math.ceil(r/1000),o=Math.floor(n/3600),a=Math.floor(n%3600/60),s=n%60;if(o>0)return`${o}:${String(a).padStart(2,"0")}:${String(s).padStart(2,"0")}`;return`${a}:${String(s).padStart(2,"0")}`}function lo(e){if(e<=0||e===-1)return"Indefinitely";if(e<60)return`${e} minutes`;if(e===60)return"1 hour";if(e%60===0)return`${e/60} hours`;let t=Math.floor(e/60),r=e%60;return`${t}h ${r}m`}if(typeof process<"u")process.once("exit",()=>Se());import{existsSync as ke,mkdirSync as uo,readFileSync as po,watch as fo,writeFileSync as mo}from"fs";import{homedir as go,platform as ho}from"os";import{dirname as wo,join as G}from"path";function bo(e){let t=ho(),r=go();switch(t){case"darwin":return G(r,"Library","Application Support",e);case"win32":return G(process.env.APPDATA||G(r,"AppData","Roaming"),e);default:return G(r,".config",e)}}class lt{_defaults;_data;_path;_changeHandlers=new Map;_anyChangeHandlers=new Set;_watcher=null;_writeTimer=null;_writing=!1;constructor(e){this._defaults={...e.defaults};let t=e.path?wo(e.path):bo(e.name);if(this._path=e.path||G(t,"preferences.json"),!ke(t))uo(t,{recursive:!0});if(this._data=this._load(),e.watch!==!1)this._setupWatcher()}get path(){return this._path}get(e){if(e in this._data)return this._data[e];return this._defaults[e]}set(e,t){let r=this.get(e);if(JSON.stringify(r)===JSON.stringify(t))return;this._data[e]=t,this._scheduleSave(),this._notifyChange(e,t,r)}getAll(){return{...this._defaults,...this._data}}has(e){return e in this._data}delete(e){if(!(e in this._data))return;let t=this._data[e];delete this._data[e],this._scheduleSave(),this._notifyChange(e,this._defaults[e],t)}reset(){let e={...this._data};this._data={},this._save();for(let t of Object.keys(e)){let r=this._defaults[t];this._notifyChange(t,r,e[t])}}onChange(e,t){let r=e;if(!this._changeHandlers.has(r))this._changeHandlers.set(r,new Set);return this._changeHandlers.get(r).add(t),()=>{this._changeHandlers.get(r)?.delete(t)}}onAnyChange(e){return this._anyChangeHandlers.add(e),()=>{this._anyChangeHandlers.delete(e)}}close(){if(this._watcher)this._watcher.close(),this._watcher=null;if(this._writeTimer)clearTimeout(this._writeTimer),this._writeTimer=null,this._save()}_load(){try{if(ke(this._path)){let e=po(this._path,"utf-8");return JSON.parse(e)}}catch{}return{}}_save(){this._writing=!0;try{let e=JSON.stringify({...this._defaults,...this._data},null,2);mo(this._path,e,"utf-8")}catch(e){console.error(`Failed to save preferences to ${this._path}:`,e)}finally{setTimeout(()=>{this._writing=!1},100)}}_scheduleSave(){if(this._writeTimer)clearTimeout(this._writeTimer);this._writeTimer=setTimeout(()=>{this._writeTimer=null,this._save()},50)}_setupWatcher(){try{if(!ke(this._path))this._save();this._watcher=fo(this._path,()=>{if(this._writing)return;let e=this._load(),t={...this._data};this._data=e;let r=new Set([...Object.keys(t),...Object.keys(e)]);for(let n of r){let o=n in t?t[n]:this._defaults[n],a=n in e?e[n]:this._defaults[n];if(JSON.stringify(o)!==JSON.stringify(a))this._notifyChange(n,a,o)}})}catch{}}_notifyChange(e,t,r){let n=this._changeHandlers.get(e);if(n)for(let o of n)try{o(t,r)}catch{}for(let o of this._anyChangeHandlers)try{o(e,t,r)}catch{}}}function xo(e){return new lt(e)}import{existsSync as U,mkdirSync as dt,readFileSync as yo,unlinkSync as ut,writeFileSync as pt}from"fs";import{homedir as ie,platform as ft}from"os";import{join as q}from"path";function mt(e){let t=e.toLowerCase().replace(/[^a-z0-9]/g,"-");return q(ie(),"Library","LaunchAgents",`com.${t}.plist`)}function gt(e){let t=process.env.XDG_CONFIG_HOME||q(ie(),".config");return q(t,"autostart",`${e.toLowerCase()}.desktop`)}async function vo(e,t){let r=t.appName||"StxApp",n=mt(r),o=q(ie(),"Library","LaunchAgents");if(e){let a=t.appPath||process.execPath,s=t.args||[],c=[a,...s],l=`<?xml version="1.0" encoding="UTF-8"?>
897
+ `}import{accessSync as _n,closeSync as Nn,constants as Fn,openSync as Wn,readSync as zn,realpathSync as Hn}from"fs";import{resolveCraftBinary as Un}from"craft-native";import{macOSRuntimeExecutablePath as Vn,pack as jn,packageApp as Kn}from"craft-native";import{craftBinaryNotFoundMessage as Gn,resolveCraftBinary as Yn}from"craft-native";function qn(e,t="full"){let r=Un(e,t),n=r;if(r==="craft"||r==="craft-webview"){let d=Bun.spawnSync(["pantry","which",r,"--resolve"]);if(d.exitCode!==0){let p=`${d.stderr}${d.stdout}`.trim();throw Error(`Cannot locate Craft's native executable. Install Craft through Pantry and use Pantry 0.11.114 or newer.${p?` ${p}`:""}`)}n=d.stdout.toString().trim()}let o=Hn(n);_n(o,Fn.X_OK);let a=Wn(o,"r"),s=Buffer.alloc(4);try{zn(a,s,0,s.length,0)}finally{Nn(a)}let c=s.readUInt32BE(0);if(!(process.platform==="darwin"?[4277009102,3472551422,4277009103,3489328638,3405691582,3199925962,3405691583,3216703178].includes(c):process.platform==="win32"?s[0]===77&&s[1]===90:c===2135247942))throw Error(`Craft packaging requires a native executable, received: ${o}`);return o}import K from"process";import{spawn as Xn}from"child_process";import{AutoUpdater as Ze,canReplaceBundle as Jn,clearQuarantine as Qn,extractBundle as Zn,generateUpdateManifest as et,readBundleIdentity as Pe,swapBundle as eo,verifyBundleTrust as to}from"craft-native";var tt="update.json";function rt(e,t){return`https://github.com/${e}/releases/latest/download/${t}`}function nt(e,t,r){return`https://github.com/${e}/releases/download/${t}/${r}`}function ot(e){let{repository:t,manifestAsset:r=tt,...n}=e;return new Ze({...n,updateUrl:rt(t,r)})}function ro(e){let t=e.tag??`v${e.version}`,r={};for(let[n,o]of Object.entries(e.artifacts)){if(!o)continue;r[n]={path:o,url:nt(e.repository,t,o.split("/").pop())}}return et({version:e.version,releaseNotes:e.releaseNotes,platforms:r})}function oe(e=K.execPath){let t=e.split("/");for(let r=0;r<t.length;r++)if(t[r].endsWith(".app"))return t.slice(0,r+1).join("/");return null}async function no(){let e=oe();if(!e)return null;return(await Pe(e)).teamId}function it(){let e=K.ppid;if(e>1)try{K.kill(e,"SIGTERM");return}catch{}K.exit(0)}function at(e={}){let t=e.appPath??oe(),r=e.quit??(()=>K.exit(0));if(t)Xn("/usr/bin/open",["-n",t],{detached:!0,stdio:"ignore"}).unref();let n=e.quitDelayMs??0;if(n>0){setTimeout(r,n).unref?.();return}r()}async function oo(e){let{appPath:t,requireSameTeam:r=!0,macos:n,...o}=e,a=t??oe();if(!a)throw Error("createSelfUpdater: this process is not running from an .app bundle, so there is nothing to update. Pass `appPath` explicitly, or skip the updater in development.");let s=n?.teamId??(r?(await Pe(a)).teamId??void 0:void 0);return ot({...o,appPath:a,macos:{...n,teamId:s},relaunch:e.relaunch??((c)=>at({appPath:c,quit:it,quitDelayMs:250}))})}function st(e){if(typeof process>"u"||process.platform!=="darwin")throw Error("Caffeinate requires macOS");let{dlopen:t,ptr:r}=ue("bun:ffi"),n=t("/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation",{CFStringCreateWithCString:{args:["ptr","ptr","u32"],returns:"ptr"},CFRelease:{args:["ptr"],returns:"void"}}),o=t("/System/Library/Frameworks/IOKit.framework/IOKit",{IOPMAssertionCreateWithName:{args:["ptr","u32","ptr","ptr"],returns:"i32"},IOPMAssertionRelease:{args:["u32"],returns:"i32"},IOPMAssertionDeclareUserActivity:{args:["ptr","u32","ptr"],returns:"i32"}}),a=[],s=!1;function c(){if(s)return;s=!0;for(let d of a)o.symbols.IOPMAssertionRelease(d);o.close(),n.close()}function l(d){let p=Buffer.from(`${d}\x00`),f=n.symbols.CFStringCreateWithCString(null,r(p),134217984);if(!f)throw Error("Could not create power assertion name");return f}try{let d=[[e.preventDisplaySleep??!0,"PreventUserIdleDisplaySleep"],[e.preventIdleSleep??!0,"PreventUserIdleSystemSleep"],[e.preventSystemSleep??!0,"PreventSystemSleep"],[e.preventDiskSleep??!1,"PreventDiskIdle"]];for(let[p,f]of d){if(!p)continue;let u=l(e.reason||"stx: keeping your Mac awake"),h=l(f),w=new Uint32Array(1);try{let P=o.symbols.IOPMAssertionCreateWithName(h,255,u,r(w));if(P!==0)throw Error(`Could not acquire ${f} (${P})`);a.push(w[0])}finally{n.symbols.CFRelease(u),n.symbols.CFRelease(h)}}if(!a.length)throw Error("At least one sleep prevention option must be enabled");if(e.assertUserActivity??!0){let p=l("stx: user activity"),f=new Uint32Array(1);try{let u=o.symbols.IOPMAssertionDeclareUserActivity(p,0,r(f));if(u!==0)throw Error(`Could not declare user activity (${u})`);a.push(f[0])}finally{n.symbols.CFRelease(p)}}return c}catch(d){throw c(),d}}var A=null;class ct{_release;_startedAt;_endsAt;_options;_expireHandlers=[];_expireTimer=null;_stopped=!1;constructor(e,t){this._release=e,this._options={...t},this._startedAt=new Date;let r=t.duration;if(r&&r>0){let n=r*60*1000;this._endsAt=new Date(this._startedAt.getTime()+n),this._expireTimer=setTimeout(()=>{this.stop();for(let o of this._expireHandlers)try{o()}catch{}},n)}else this._endsAt=null}get pid(){return process.pid}get startedAt(){return this._startedAt}get endsAt(){return this._endsAt}get options(){return{...this._options}}get isActive(){return!this._stopped}get remainingMs(){if(!this._endsAt)return null;let e=this._endsAt.getTime()-Date.now();return Math.max(0,e)}get elapsedMs(){return Date.now()-this._startedAt.getTime()}stop(){if(this._stopped)return;if(this._stopped=!0,this._expireTimer)clearTimeout(this._expireTimer),this._expireTimer=null;this._release()}onExpire(e){this._expireHandlers.push(e)}}function io(e={}){if(e.duration!==void 0&&e.duration!==-1&&(!Number.isFinite(e.duration)||e.duration<=0))throw RangeError("duration must be positive minutes or -1 for indefinitely");let t=st(e),r=new ct(t,e);return Se(),A=r,r}function Se(e){if(e){if(e.stop(),A===e)A=null;return}if(A)A.stop();A=null}function ao(){return A!==null&&A.isActive}function so(){if(!A||!A.isActive)return{active:!1,instance:null,startedAt:null,endsAt:null,durationMinutes:null};let t=A.options.duration;return{active:!0,instance:A,startedAt:A.startedAt,endsAt:A.endsAt,durationMinutes:t&&t>0?t:-1}}function co(e){let t=e||A;if(!t||!t.isActive)return"0:00";let r=t.remainingMs;if(r===null)return"\u221E";let n=Math.ceil(r/1000),o=Math.floor(n/3600),a=Math.floor(n%3600/60),s=n%60;if(o>0)return`${o}:${String(a).padStart(2,"0")}:${String(s).padStart(2,"0")}`;return`${a}:${String(s).padStart(2,"0")}`}function lo(e){if(e<=0||e===-1)return"Indefinitely";if(e<60)return`${e} minutes`;if(e===60)return"1 hour";if(e%60===0)return`${e/60} hours`;let t=Math.floor(e/60),r=e%60;return`${t}h ${r}m`}if(typeof process<"u")process.once("exit",()=>Se());import{existsSync as ke,mkdirSync as uo,readFileSync as po,watch as fo,writeFileSync as mo}from"fs";import{homedir as go,platform as ho}from"os";import{dirname as wo,join as G}from"path";function bo(e){let t=ho(),r=go();switch(t){case"darwin":return G(r,"Library","Application Support",e);case"win32":return G(process.env.APPDATA||G(r,"AppData","Roaming"),e);default:return G(r,".config",e)}}class lt{_defaults;_data;_path;_changeHandlers=new Map;_anyChangeHandlers=new Set;_watcher=null;_writeTimer=null;_writing=!1;constructor(e){this._defaults={...e.defaults};let t=e.path?wo(e.path):bo(e.name);if(this._path=e.path||G(t,"preferences.json"),!ke(t))uo(t,{recursive:!0});if(this._data=this._load(),e.watch!==!1)this._setupWatcher()}get path(){return this._path}get(e){if(e in this._data)return this._data[e];return this._defaults[e]}set(e,t){let r=this.get(e);if(JSON.stringify(r)===JSON.stringify(t))return;this._data[e]=t,this._scheduleSave(),this._notifyChange(e,t,r)}getAll(){return{...this._defaults,...this._data}}has(e){return e in this._data}delete(e){if(!(e in this._data))return;let t=this._data[e];delete this._data[e],this._scheduleSave(),this._notifyChange(e,this._defaults[e],t)}reset(){let e={...this._data};this._data={},this._save();for(let t of Object.keys(e)){let r=this._defaults[t];this._notifyChange(t,r,e[t])}}onChange(e,t){let r=e;if(!this._changeHandlers.has(r))this._changeHandlers.set(r,new Set);return this._changeHandlers.get(r).add(t),()=>{this._changeHandlers.get(r)?.delete(t)}}onAnyChange(e){return this._anyChangeHandlers.add(e),()=>{this._anyChangeHandlers.delete(e)}}close(){if(this._watcher)this._watcher.close(),this._watcher=null;if(this._writeTimer)clearTimeout(this._writeTimer),this._writeTimer=null,this._save()}_load(){try{if(ke(this._path)){let e=po(this._path,"utf-8");return JSON.parse(e)}}catch{}return{}}_save(){this._writing=!0;try{let e=JSON.stringify({...this._defaults,...this._data},null,2);mo(this._path,e,"utf-8")}catch(e){console.error(`Failed to save preferences to ${this._path}:`,e)}finally{setTimeout(()=>{this._writing=!1},100)}}_scheduleSave(){if(this._writeTimer)clearTimeout(this._writeTimer);this._writeTimer=setTimeout(()=>{this._writeTimer=null,this._save()},50)}_setupWatcher(){try{if(!ke(this._path))this._save();this._watcher=fo(this._path,()=>{if(this._writing)return;let e=this._load(),t={...this._data};this._data=e;let r=new Set([...Object.keys(t),...Object.keys(e)]);for(let n of r){let o=n in t?t[n]:this._defaults[n],a=n in e?e[n]:this._defaults[n];if(JSON.stringify(o)!==JSON.stringify(a))this._notifyChange(n,a,o)}})}catch{}}_notifyChange(e,t,r){let n=this._changeHandlers.get(e);if(n)for(let o of n)try{o(t,r)}catch{}for(let o of this._anyChangeHandlers)try{o(e,t,r)}catch{}}}function xo(e){return new lt(e)}import{existsSync as U,mkdirSync as dt,readFileSync as yo,unlinkSync as ut,writeFileSync as pt}from"fs";import{homedir as ie,platform as ft}from"os";import{join as q}from"path";function mt(e){let t=e.toLowerCase().replace(/[^a-z0-9]/g,"-");return q(ie(),"Library","LaunchAgents",`com.${t}.plist`)}function gt(e){let t=process.env.XDG_CONFIG_HOME||q(ie(),".config");return q(t,"autostart",`${e.toLowerCase()}.desktop`)}async function vo(e,t){let r=t.appName||"StxApp",n=mt(r),o=q(ie(),"Library","LaunchAgents");if(e){let a=t.appPath||process.execPath,s=t.args||[],c=[a,...s],l=`<?xml version="1.0" encoding="UTF-8"?>
898
898
  <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
899
899
  <plist version="1.0">
900
900
  <dict>
@@ -6,7 +6,7 @@ export type { PackageConfig, PackageResult } from 'craft-native';
6
6
  * relocated outside its installation tree. Pantry owns that resolution; local
7
7
  * source builds can supply a native executable through CRAFT_BIN or `explicit`.
8
8
  */
9
- export declare function resolveCraftExecutablePath(explicit?: string): string;
9
+ export declare function resolveCraftExecutablePath(explicit?: string, profile?: 'full' | 'webview'): string;
10
10
  export { macOSRuntimeExecutablePath, pack, packageApp } from 'craft-native';
11
11
  /**
12
12
  * Craft's binary resolution contract — PATH (craft installs via pantry), with
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@stacksjs/desktop",
3
3
  "type": "module",
4
- "version": "0.2.698",
4
+ "version": "0.2.701",
5
5
  "description": "Native desktop application framework for stx (powered by Craft)",
6
6
  "author": "Chris Breuer <chris@stacksjs.org>",
7
7
  "license": "MIT",
@@ -59,6 +59,6 @@
59
59
  "typecheck": "bun tsc --noEmit"
60
60
  },
61
61
  "dependencies": {
62
- "craft-native": ">=0.0.338"
62
+ "craft-native": ">=0.0.350"
63
63
  }
64
64
  }