@ycodium-ai/agent-antigravity 0.2.3608 → 0.2.3614

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/assets/ui.js CHANGED
@@ -1,4 +1,4 @@
1
- var G=window.__ycodiumPluginHost.modules?.["@ycodium-ai/plugin-api/provider-settings"];if(!G)throw new Error("This plugin needs a newer Ycodium app. Update the app.");var{PROVIDER_SETTINGS_VIEW_CAPABILITY:$,accountDirectoryCandidates:Re,accountDirectorySlug:Be,accountProbeHasSignedInAccount:Ie,allocateAccountDirectory:Ae,providerInstanceAccountPaths:Te}=G;var xe=window.__ycodiumPluginHost.react;var{Activity:Ce,Children:Ee,Component:Ne,Fragment:Pe,Profiler:_e,PureComponent:Ue,StrictMode:Fe,Suspense:Me,__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE:Oe,__COMPILER_RUNTIME:Ke,act:Le,cache:Ve,cacheSignal:ze,captureOwnerStack:He,cloneElement:De,createContext:j,createElement:J,createRef:Ye,forwardRef:qe,isValidElement:We,lazy:Ge,memo:$e,startTransition:je,unstable_useCacheRefresh:Je,use:Qe,useActionState:Xe,useCallback:Ze,useContext:Q,useDebugValue:et,useDeferredValue:tt,useEffect:nt,useEffectEvent:rt,useId:it,useImperativeHandle:ot,useInsertionEffect:at,useLayoutEffect:st,useMemo:lt,useOptimistic:dt,useReducer:ut,useRef:ct,useState:u,useSyncExternalStore:mt,useTransition:pt,version:gt}=xe;var X=j(null),Z=X.Provider;function f(){let e=Q(X);if(e===null)throw new Error("Antigravity UI has not been registered.");return e}var ee={"insufficient-space":"runtime.errors.insufficientSpace","download-failed":"runtime.errors.downloadFailed",timeout:"runtime.errors.timeout","verification-failed":"runtime.errors.verificationFailed","extract-failed":"runtime.errors.extractFailed","validation-failed":"runtime.errors.validationFailed","activate-failed":"runtime.errors.activateFailed","install-failed":"runtime.errors.installFailed","runtime-damaged":"runtime.errors.damaged","unsupported-platform":"runtime.errors.unsupportedPlatform","no-instance":"runtime.errors.noInstance",busy:"runtime.errors.busy","remove-failed":"runtime.errors.removeFailed","runtime-installing":"runtime.removeBlocked.installing","runtime-in-use":"runtime.removeBlocked.inUse","runtime-custom-path":"runtime.removeBlocked.customPath"},te={installing:"runtime.removeBlocked.installing","in-use":"runtime.removeBlocked.inUse","custom-path":"runtime.removeBlocked.customPath"},V={"program-unavailable":"auth.errors.programUnavailable","too-many-processes":"auth.errors.tooManyProcesses","process-exited":"auth.errors.processExited","agent-timeout":"auth.errors.agentTimeout","invalid-url":"auth.errors.invalidUrl","multiple-urls":"auth.errors.multipleUrls",expired:"auth.errors.expired",denied:"auth.errors.denied","subscription-required":"auth.errors.subscriptionRequired","sign-in-unsupported":"auth.errors.signInUnsupported","session-init-failed":"auth.errors.sessionInitFailed","sign-in-required":"auth.errors.signInRequired","callback-too-long":"auth.errors.callbackTooLong","callback-malformed":"auth.errors.callbackMalformed","callback-mismatch":"auth.errors.callbackMismatch","callback-no-response":"auth.errors.callbackNoResponse","callback-bad-issuer":"auth.errors.callbackBadIssuer","callback-already-sent":"auth.errors.callbackAlreadySent","callback-delivery-failed":"auth.errors.callbackDeliveryFailed","no-active-sign-in":"auth.errors.noActiveSignIn","sign-in-not-ready":"auth.errors.signInNotReady","logout-unsupported":"auth.errors.logoutUnsupported","logout-failed":"auth.errors.logoutFailed","refresh-failed":"auth.errors.refreshFailed",busy:"auth.errors.busy","instance-unavailable":"auth.errors.instanceUnavailable","instance-disposed":"auth.errors.instanceDisposed","sign-in-failed":"auth.errors.signInFailed"};function b(e,t,i,p={}){let d=i.code===void 0?void 0:t[i.code];return d===void 0?i.message:e(d,p)}function A(e){return(t=>J(f().ui[e],{...t,className:`ycodium-antigravity-ui ${typeof t.className=="string"?t.className:""}`}))}var l=A("Button"),ne=A("Input"),re=A("Badge"),ie=A("Alert"),oe=A("AlertDescription"),z=A("Spinner");function T(){let e=f().i18n.usePluginTranslation();return{t:(t,i)=>e(t,i)}}var{jsx:n,jsxs:o,Fragment:k}=window.__ycodiumPluginHost.jsxRuntime;function E(e){return o("section",{className:"grid gap-2",children:[n("h3",{className:"text-ui-md font-medium",children:e.title}),e.description===void 0?null:n("p",{className:"text-ui-sm text-muted-foreground",children:e.description}),e.children]})}function R(e){return n(ie,{variant:"error",children:n(oe,{"data-slot":"alert-description",children:e.text})})}function H(e){let[t,i]=u(!1);return t?o("div",{className:"grid gap-2",children:[n("p",{className:"text-ui-sm",children:e.prompt}),o("div",{className:"flex flex-wrap gap-2",children:[n(l,{size:"xs",variant:"destructive-outline",disabled:e.disabled,onClick:()=>{i(!1),e.onConfirm()},children:e.confirmLabel}),n(l,{size:"xs",variant:"ghost",onClick:()=>i(!1),children:e.cancelLabel})]})]}):n("div",{className:"flex flex-wrap gap-2",children:n(l,{size:"xs",variant:"outline",disabled:e.disabled,onClick:()=>i(!0),children:e.label})})}var D=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function ae(e){return!D(e)||typeof e.phase!="string"||typeof e.installed!="boolean"?null:e}function se(e){return!D(e)||typeof e.phase!="string"||typeof e.signedIn!="boolean"?null:e}function le(e){return!D(e)||!Array.isArray(e.models)?null:e}function N(e){let i=(D(e)?e:void 0)?.pluginCode,p=e instanceof Error?e.message:String(e);return{code:typeof i=="string"?i:void 0,message:p}}function h(e){let t=e/1048576;return t>=1024?`${(t/1024).toFixed(1)} GB`:`${Math.max(1,Math.round(t))} MB`}function de(e){let{t}=T(),i=f(),p=i.useFormatTimestamp(),d={environmentId:e.environmentId},c=i.commands.useSubscription("auth.state",{instanceId:e.instanceId},d),g=se(c.data),[S,P]=u(!1),[_,C]=u(null),[s,v]=u(""),[U,r]=u(null),[m,B]=u(null),F=async(a,y)=>{P(!0);try{return await i.commands.invoke(a,y,d)}finally{P(!1)}},x=async(a,y={})=>{C(null);try{return await F(a,{instanceId:e.instanceId,...y}),!0}catch(w){return C(N(w)),!1}},M=async()=>{await x("auth.complete",{callbackUrl:s.trim()})&&v("")},ge=async()=>{r(null),B(null);try{r(le(await F("models.refresh",{instanceId:e.instanceId})))}catch(a){B(N(a))}},ye=async a=>{try{await i.writeClipboard(a),i.notify(t("auth.copied"),"success")}catch{i.notify(t("auth.copyFailed"),"error")}},fe=a=>{let y=a.operation,w=y!==null,O=y==="sign-in",K=O&&a.phase==="waiting"?a.authorizationUrl:null,L=S||e.readOnly,I=w?null:a.programUnavailable,q=_??(w?null:a.error),W=I!==null&&q?.code===I.code?null:q,ve=O?a.phase==="waiting"?"auth.state.waiting":a.phase==="verifying"?"auth.state.verifying":"auth.state.starting":y==="sign-out"?"auth.state.signingOut":y==="refresh-models"?"auth.state.refreshing":a.signedIn?"auth.state.signedIn":a.phase==="cancelled"?"auth.state.cancelled":"auth.state.signedOut";return o(k,{children:[o("p",{className:"flex items-center gap-2 text-ui-md",children:[w?n(z,{className:"size-3.5"}):n(re,{variant:a.signedIn?"success":"outline",children:t(a.signedIn?"auth.badge.signedIn":"auth.badge.signedOut")}),n("span",{children:t(ve)})]}),W===null?null:n(R,{text:b(t,V,W)}),I===null?null:n("p",{className:"text-ui-sm text-muted-foreground",children:b(t,V,I)}),K===null?null:o("div",{className:"grid gap-2",children:[n("p",{className:"text-ui-sm text-muted-foreground",children:t("auth.linkIntro")}),n("p",{className:"break-all text-ui-xs select-text",children:K}),o("div",{className:"flex flex-wrap gap-2",children:[n(l,{size:"xs",variant:"outline",onClick:()=>i.openExternal(K),children:t("auth.open")}),n(l,{size:"xs",variant:"outline",onClick:()=>{ye(K)},children:t("auth.copy")})]}),o("label",{className:"grid gap-1",children:[n("span",{className:"text-ui-sm font-medium",children:t("auth.pasteLabel")}),n(ne,{value:s,onChange:Y=>v(Y.target.value),onKeyDown:Y=>{Y.key==="Enter"&&s.trim().length>0&&!L&&M()},placeholder:t("auth.pastePlaceholder"),spellCheck:!1,autoComplete:"off","aria-label":t("auth.pasteLabel")})]}),n("p",{className:"text-ui-sm text-muted-foreground",children:t("auth.pasteHint")}),n("div",{className:"flex flex-wrap gap-2",children:n(l,{size:"xs",disabled:L||s.trim().length===0,onClick:()=>{M()},children:t("auth.complete")})})]}),a.expiresAt!==null&&O?n("p",{className:"text-ui-xs text-muted-foreground",children:t("auth.expiresAt",{time:p(a.expiresAt)})}):null,o("div",{className:"flex flex-wrap gap-2",children:[!w&&!a.signedIn?n(l,{size:"xs",disabled:L||I!==null,onClick:()=>{v(""),x("auth.start")},children:t("auth.start")}):null,O?n(l,{size:"xs",variant:"outline",disabled:e.readOnly,onClick:()=>{v(""),x("auth.cancel")},children:t("auth.cancel")}):null]}),!w&&a.signedIn?n(H,{label:t("auth.logout"),prompt:t("auth.logoutConfirm"),confirmLabel:t("auth.logoutConfirmAction"),cancelLabel:t("common.cancel"),disabled:L||I!==null,onConfirm:()=>{x("auth.logout")}}):null]})},he=c.error!==null?null:c.isUnavailable?n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.unavailable")}):n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.loading")});return o(k,{children:[o(E,{title:t("auth.title"),description:t("auth.description"),children:[c.error===null?null:n(R,{text:t("common.loadFailed",{message:c.error})}),g===null?he:fe(g)]}),o(E,{title:t("models.title"),description:t("models.description"),children:[n("div",{className:"flex flex-wrap gap-2",children:n(l,{size:"xs",variant:"outline",disabled:g===null||g.operation!==null||g.programUnavailable!==null||S||e.readOnly,onClick:()=>{ge()},children:t("models.refresh")})}),U===null?null:n("p",{className:"text-ui-sm text-muted-foreground",children:t("models.result",{count:U.models.length})}),m===null?null:n(R,{text:b(t,V,m)})]})]})}var we=new Set(["downloading","extracting","verifying"]);function ue(e){let{t}=T(),i=f(),p={environmentId:e.environmentId},d=i.commands.useSubscription("runtime.state",{},p),c=ae(d.data),[g,S]=u(!1),[P,_]=u(null),C=async(r,m)=>{_(null),S(!0);try{await i.commands.invoke(r,m,p)}catch(B){_(N(B))}finally{S(!1)}},s=c?.release??null,v={download:s===null?"":h(s.archiveBytes),installed:s===null?"":h(s.installedBytes),free:s===null?"":h(s.requiredFreeBytes),size:s===null?"":h(s.requiredFreeBytes)},U=r=>{let m=we.has(r.phase),B=s!==null&&(!r.installed||r.updateAvailable),F=m?r.phase==="downloading"?r.totalBytes===null||r.totalBytes<=0?t("runtime.state.downloadingUnknown",{done:h(r.downloadedBytes)}):t("runtime.state.downloading",{done:h(r.downloadedBytes),total:h(r.totalBytes),percent:Math.min(100,Math.floor(r.downloadedBytes*100/r.totalBytes))}):t(r.phase==="extracting"?"runtime.state.extracting":"runtime.state.verifying"):r.installed?r.updateAvailable?t("runtime.state.updateAvailable",{version:r.installedVersion??"",latest:s?.version??""}):t("runtime.state.installed",{version:r.installedVersion??""}):t(s===null?"runtime.state.unsupported":"runtime.state.notInstalled"),x=P??r.error,M=r.canRemove||r.removeBlocked!==null;return o(k,{children:[o("p",{className:"flex items-center gap-2 text-ui-md",children:[m?n(z,{className:"size-3.5"}):null,n("span",{children:F})]}),x===null||m?null:n(R,{text:b(t,ee,x,v)}),B&&!m?o(k,{children:[n("p",{className:"text-ui-sm text-muted-foreground",children:t("runtime.sizes",v)}),n("div",{className:"flex flex-wrap gap-2",children:n(l,{size:"xs",disabled:g||e.readOnly,onClick:()=>{C("runtime.install",{instanceId:e.instanceId})},children:t(r.installed?"runtime.update":"runtime.install")})})]}):null,M?o(k,{children:[n(H,{label:t("runtime.remove"),prompt:t("runtime.removeConfirm"),confirmLabel:t("runtime.removeConfirmAction"),cancelLabel:t("common.cancel"),disabled:g||e.readOnly||!r.canRemove,onConfirm:()=>{C("runtime.remove",{})}}),r.removeBlocked===null?null:n("p",{className:"text-ui-sm text-muted-foreground",children:b(t,te,r.removeBlocked)})]}):null]})};return o(E,{title:t("runtime.title"),description:t("runtime.description"),children:[d.error===null?null:n(R,{text:t("common.loadFailed",{message:d.error})}),c!==null?U(c):d.isUnavailable?n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.unavailable")}):d.error===null?n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.loading")}):null]})}function ce(e){let{t}=T();return e.placement==="add"||e.instanceId===null?n("p",{className:"ycodium-antigravity-ui text-ui-sm text-muted-foreground",children:t("add.hint")}):o("div",{className:"ycodium-antigravity-ui grid gap-6",children:[n(ue,{instanceId:e.instanceId,environmentId:e.environmentId,readOnly:e.readOnly}),n(de,{instanceId:e.instanceId,environmentId:e.environmentId,readOnly:e.readOnly})]})}var me=`/*! tailwindcss v4.3.0 | MIT License | https://tailwindcss.com */
1
+ var $=window.__ycodiumPluginHost.modules?.["@ycodium-ai/plugin-api/provider-settings"];if(!$)throw new Error("This plugin needs a newer Ycodium app. Update the app.");var{PROVIDER_SETTINGS_VIEW_CAPABILITY:j,accountDirectoryCandidates:Re,accountDirectorySlug:Be,accountProbeHasSignedInAccount:Ie,allocateAccountDirectory:Ae,providerInstanceAccountPaths:Te}=$;var xe=window.__ycodiumPluginHost.react;var{Activity:Ce,Children:Ee,Component:Ne,Fragment:Pe,Profiler:_e,PureComponent:Ue,StrictMode:Fe,Suspense:Me,__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE:Ke,__COMPILER_RUNTIME:Le,act:Oe,cache:Ve,cacheSignal:ze,captureOwnerStack:He,cloneElement:De,createContext:J,createElement:Q,createRef:Ye,forwardRef:qe,isValidElement:We,lazy:Ge,memo:$e,startTransition:je,unstable_useCacheRefresh:Je,use:Qe,useActionState:Xe,useCallback:Ze,useContext:X,useDebugValue:et,useDeferredValue:tt,useEffect:nt,useEffectEvent:rt,useId:it,useImperativeHandle:ot,useInsertionEffect:at,useLayoutEffect:lt,useMemo:st,useOptimistic:dt,useReducer:ut,useRef:ct,useState:u,useSyncExternalStore:mt,useTransition:pt,version:gt}=xe;var Z=J(null),ee=Z.Provider;function f(){let e=X(Z);if(e===null)throw new Error("Antigravity UI has not been registered.");return e}var te={"insufficient-space":"runtime.errors.insufficientSpace","download-failed":"runtime.errors.downloadFailed",timeout:"runtime.errors.timeout","verification-failed":"runtime.errors.verificationFailed","extract-failed":"runtime.errors.extractFailed","validation-failed":"runtime.errors.validationFailed","activate-failed":"runtime.errors.activateFailed","install-failed":"runtime.errors.installFailed","runtime-damaged":"runtime.errors.damaged","unsupported-platform":"runtime.errors.unsupportedPlatform","no-instance":"runtime.errors.noInstance",busy:"runtime.errors.busy","remove-failed":"runtime.errors.removeFailed","runtime-installing":"runtime.removeBlocked.installing","runtime-in-use":"runtime.removeBlocked.inUse","runtime-custom-path":"runtime.removeBlocked.customPath"},ne={installing:"runtime.removeBlocked.installing","in-use":"runtime.removeBlocked.inUse","custom-path":"runtime.removeBlocked.customPath"},V={"program-unavailable":"auth.errors.programUnavailable","too-many-processes":"auth.errors.tooManyProcesses","process-exited":"auth.errors.processExited","agent-timeout":"auth.errors.agentTimeout","invalid-url":"auth.errors.invalidUrl","multiple-urls":"auth.errors.multipleUrls",expired:"auth.errors.expired",denied:"auth.errors.denied","subscription-required":"auth.errors.subscriptionRequired","sign-in-unsupported":"auth.errors.signInUnsupported","session-init-failed":"auth.errors.sessionInitFailed","sign-in-required":"auth.errors.signInRequired","callback-too-long":"auth.errors.callbackTooLong","callback-malformed":"auth.errors.callbackMalformed","callback-mismatch":"auth.errors.callbackMismatch","callback-no-response":"auth.errors.callbackNoResponse","callback-bad-issuer":"auth.errors.callbackBadIssuer","callback-already-sent":"auth.errors.callbackAlreadySent","callback-delivery-failed":"auth.errors.callbackDeliveryFailed","no-active-sign-in":"auth.errors.noActiveSignIn","sign-in-not-ready":"auth.errors.signInNotReady","logout-unsupported":"auth.errors.logoutUnsupported","logout-failed":"auth.errors.logoutFailed","refresh-failed":"auth.errors.refreshFailed",busy:"auth.errors.busy","instance-unavailable":"auth.errors.instanceUnavailable","instance-disposed":"auth.errors.instanceDisposed","sign-in-failed":"auth.errors.signInFailed"};function b(e,t,i,p={}){let d=i.code===void 0?void 0:t[i.code];return d===void 0?i.message:e(d,p)}function A(e){return(t=>Q(f().ui[e],{...t,className:`ycodium-antigravity-ui ${typeof t.className=="string"?t.className:""}`}))}var s=A("Button"),re=A("Input"),ie=A("Badge"),oe=A("Alert"),ae=A("AlertDescription"),z=A("Spinner");function T(){let e=f().i18n.usePluginTranslation();return{t:(t,i)=>e(t,i)}}var{jsx:n,jsxs:o,Fragment:k}=window.__ycodiumPluginHost.jsxRuntime;function E(e){return o("section",{className:"grid gap-2",children:[n("h3",{className:"text-ui-md font-medium",children:e.title}),e.description===void 0?null:n("p",{className:"text-ui-sm text-muted-foreground",children:e.description}),e.children]})}function R(e){return n(oe,{variant:"error",children:n(ae,{"data-slot":"alert-description",children:e.text})})}function H(e){let[t,i]=u(!1);return t?o("div",{className:"grid gap-2",children:[n("p",{className:"text-ui-sm",children:e.prompt}),o("div",{className:"flex flex-wrap gap-2",children:[n(s,{size:"xs",variant:"destructive-outline",disabled:e.disabled,onClick:()=>{i(!1),e.onConfirm()},children:e.confirmLabel}),n(s,{size:"xs",variant:"ghost",onClick:()=>i(!1),children:e.cancelLabel})]})]}):n("div",{className:"flex flex-wrap gap-2",children:n(s,{size:"xs",variant:"outline",disabled:e.disabled,onClick:()=>i(!0),children:e.label})})}var D=e=>typeof e=="object"&&e!==null&&!Array.isArray(e);function le(e){return!D(e)||typeof e.phase!="string"||typeof e.installed!="boolean"?null:e}function se(e){return!D(e)||typeof e.phase!="string"||typeof e.signedIn!="boolean"?null:e}function de(e){return!D(e)||!Array.isArray(e.models)?null:e}function N(e){let i=(D(e)?e:void 0)?.pluginCode,p=e instanceof Error?e.message:String(e);return{code:typeof i=="string"?i:void 0,message:p}}function h(e){let t=e/1048576;return t>=1024?`${(t/1024).toFixed(1)} GB`:`${Math.max(1,Math.round(t))} MB`}function ue(e){let{t}=T(),i=f(),p=i.useFormatTimestamp(),d={environmentId:e.environmentId},c=i.commands.useSubscription("auth.state",{instanceId:e.instanceId},d),g=se(c.data),[S,P]=u(!1),[_,C]=u(null),[l,v]=u(""),[U,r]=u(null),[m,B]=u(null),F=async(a,y)=>{P(!0);try{return await i.commands.invoke(a,y,d)}finally{P(!1)}},x=async(a,y={})=>{C(null);try{return await F(a,{instanceId:e.instanceId,...y}),!0}catch(w){return C(N(w)),!1}},M=async()=>{await x("auth.complete",{callbackUrl:l.trim()})&&v("")},ye=async()=>{r(null),B(null);try{r(de(await F("models.refresh",{instanceId:e.instanceId})))}catch(a){B(N(a))}},fe=async a=>{try{await i.writeClipboard(a),i.notify(t("auth.copied"),"success")}catch{i.notify(t("auth.copyFailed"),"error")}},he=a=>{let y=a.operation,w=y!==null,K=y==="sign-in",L=K&&a.phase==="waiting"?a.authorizationUrl:null,O=S||e.readOnly,I=w?null:a.programUnavailable,q=_??(w?null:a.error),W=I!==null&&q?.code===I.code?null:q,G=K?a.phase==="waiting"?"auth.state.waiting":a.phase==="verifying"?"auth.state.verifying":"auth.state.starting":y==="sign-out"?"auth.state.signingOut":y==="refresh-models"?"auth.state.refreshing":a.phase==="cancelled"&&!a.signedIn?"auth.state.cancelled":null;return o(k,{children:[o("p",{className:"flex items-center gap-2 text-ui-md",children:[w?n(z,{className:"size-3.5"}):n(ie,{variant:a.signedIn?"success":"outline",children:t(a.signedIn?"auth.badge.signedIn":"auth.badge.signedOut")}),G===null?null:n("span",{children:t(G)})]}),W===null?null:n(R,{text:b(t,V,W)}),I===null?null:n("p",{className:"text-ui-sm text-muted-foreground",children:b(t,V,I)}),L===null?null:o("div",{className:"grid gap-2",children:[n("p",{className:"text-ui-sm text-muted-foreground",children:t("auth.linkIntro")}),n("p",{className:"break-all text-ui-xs select-text",children:L}),o("div",{className:"flex flex-wrap gap-2",children:[n(s,{size:"xs",variant:"outline",onClick:()=>i.openExternal(L),children:t("auth.open")}),n(s,{size:"xs",variant:"outline",onClick:()=>{fe(L)},children:t("auth.copy")})]}),o("label",{className:"grid gap-1",children:[n("span",{className:"text-ui-sm font-medium",children:t("auth.pasteLabel")}),n(re,{value:l,onChange:Y=>v(Y.target.value),onKeyDown:Y=>{Y.key==="Enter"&&l.trim().length>0&&!O&&M()},placeholder:t("auth.pastePlaceholder"),spellCheck:!1,autoComplete:"off","aria-label":t("auth.pasteLabel")})]}),n("p",{className:"text-ui-sm text-muted-foreground",children:t("auth.pasteHint")}),n("div",{className:"flex flex-wrap gap-2",children:n(s,{size:"xs",disabled:O||l.trim().length===0,onClick:()=>{M()},children:t("auth.complete")})})]}),a.expiresAt!==null&&K?n("p",{className:"text-ui-xs text-muted-foreground",children:t("auth.expiresAt",{time:p(a.expiresAt)})}):null,o("div",{className:"flex flex-wrap gap-2",children:[!w&&!a.signedIn?n(s,{size:"xs",disabled:O||I!==null,onClick:()=>{v(""),x("auth.start")},children:t("auth.start")}):null,K?n(s,{size:"xs",variant:"outline",disabled:e.readOnly,onClick:()=>{v(""),x("auth.cancel")},children:t("auth.cancel")}):null]}),!w&&a.signedIn?n(H,{label:t("auth.logout"),prompt:t("auth.logoutConfirm"),confirmLabel:t("auth.logoutConfirmAction"),cancelLabel:t("common.cancel"),disabled:O||I!==null,onConfirm:()=>{x("auth.logout")}}):null]})},ve=c.error!==null?null:c.isUnavailable?n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.unavailable")}):n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.loading")});return o(k,{children:[o(E,{title:t("auth.title"),description:t("auth.description"),children:[c.error===null?null:n(R,{text:t("common.loadFailed",{message:c.error})}),g===null?ve:he(g)]}),o(E,{title:t("models.title"),description:t("models.description"),children:[n("div",{className:"flex flex-wrap gap-2",children:n(s,{size:"xs",variant:"outline",disabled:g===null||g.operation!==null||g.programUnavailable!==null||S||e.readOnly,onClick:()=>{ye()},children:t("models.refresh")})}),U===null?null:n("p",{className:"text-ui-sm text-muted-foreground",children:t("models.result",{count:U.models.length})}),m===null?null:n(R,{text:b(t,V,m)})]})]})}var we=new Set(["downloading","extracting","verifying"]);function ce(e){let{t}=T(),i=f(),p={environmentId:e.environmentId},d=i.commands.useSubscription("runtime.state",{},p),c=le(d.data),[g,S]=u(!1),[P,_]=u(null),C=async(r,m)=>{_(null),S(!0);try{await i.commands.invoke(r,m,p)}catch(B){_(N(B))}finally{S(!1)}},l=c?.release??null,v={download:l===null?"":h(l.archiveBytes),installed:l===null?"":h(l.installedBytes),free:l===null?"":h(l.requiredFreeBytes),size:l===null?"":h(l.requiredFreeBytes)},U=r=>{let m=we.has(r.phase),B=l!==null&&(!r.installed||r.updateAvailable),F=m?r.phase==="downloading"?r.totalBytes===null||r.totalBytes<=0?t("runtime.state.downloadingUnknown",{done:h(r.downloadedBytes)}):t("runtime.state.downloading",{done:h(r.downloadedBytes),total:h(r.totalBytes),percent:Math.min(100,Math.floor(r.downloadedBytes*100/r.totalBytes))}):t(r.phase==="extracting"?"runtime.state.extracting":"runtime.state.verifying"):r.installed?r.updateAvailable?t("runtime.state.updateAvailable",{version:r.installedVersion??"",latest:l?.version??""}):t("runtime.state.installed",{version:r.installedVersion??""}):t(l===null?"runtime.state.unsupported":"runtime.state.notInstalled"),x=P??r.error,M=r.canRemove||r.removeBlocked!==null;return o(k,{children:[o("p",{className:"flex items-center gap-2 text-ui-md",children:[m?n(z,{className:"size-3.5"}):null,n("span",{children:F})]}),x===null||m?null:n(R,{text:b(t,te,x,v)}),B&&!m?o(k,{children:[n("p",{className:"text-ui-sm text-muted-foreground",children:t("runtime.sizes",v)}),n("div",{className:"flex flex-wrap gap-2",children:n(s,{size:"xs",disabled:g||e.readOnly,onClick:()=>{C("runtime.install",{instanceId:e.instanceId})},children:t(r.installed?"runtime.update":"runtime.install")})})]}):null,M?o(k,{children:[n(H,{label:t("runtime.remove"),prompt:t("runtime.removeConfirm"),confirmLabel:t("runtime.removeConfirmAction"),cancelLabel:t("common.cancel"),disabled:g||e.readOnly||!r.canRemove,onConfirm:()=>{C("runtime.remove",{})}}),r.removeBlocked===null?null:n("p",{className:"text-ui-sm text-muted-foreground",children:b(t,ne,r.removeBlocked)})]}):null]})};return o(E,{title:t("runtime.title"),description:t("runtime.description"),children:[d.error===null?null:n(R,{text:t("common.loadFailed",{message:d.error})}),c!==null?U(c):d.isUnavailable?n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.unavailable")}):d.error===null?n("p",{className:"text-ui-sm text-muted-foreground",children:t("common.loading")}):null]})}function me(e){let{t}=T();return e.placement==="add"||e.instanceId===null?n("p",{className:"ycodium-antigravity-ui text-ui-sm text-muted-foreground",children:t("add.hint")}):o("div",{className:"ycodium-antigravity-ui grid gap-6",children:[n(ce,{instanceId:e.instanceId,environmentId:e.environmentId,readOnly:e.readOnly}),n(ue,{instanceId:e.instanceId,environmentId:e.environmentId,readOnly:e.readOnly})]})}var pe=`/*! tailwindcss v4.3.0 | MIT License | https://tailwindcss.com */
2
2
  @layer properties, theme, base, components, utilities;
3
3
  @layer properties;
4
4
  @layer utilities {
@@ -92,4 +92,4 @@ var G=window.__ycodiumPluginHost.modules?.["@ycodium-ai/plugin-api/provider-sett
92
92
  }
93
93
  }
94
94
  }
95
- `;var pe="setup";function ke(e){let t=i=>o(Z,{value:e,children:[n("style",{children:me}),n(ce,{...i})]});return{pages:{},panels:{},views:{[pe]:t},viewCapabilities:{[pe]:[$]}}}export{pe as ANTIGRAVITY_SETUP_SECTION_ID,ke as default};
95
+ `;var ge="setup";function ke(e){let t=i=>o(ee,{value:e,children:[n("style",{children:pe}),n(me,{...i})]});return{pages:{},panels:{},views:{[ge]:t},viewCapabilities:{[ge]:[j]}}}export{ge as ANTIGRAVITY_SETUP_SECTION_ID,ke as default};
package/locales/en.json CHANGED
@@ -68,8 +68,6 @@
68
68
  "signedOut": "Not signed in"
69
69
  },
70
70
  "state": {
71
- "signedIn": "This provider is signed in with Google.",
72
- "signedOut": "This provider is not signed in.",
73
71
  "cancelled": "Sign-in was cancelled.",
74
72
  "starting": "Starting Google sign-in…",
75
73
  "waiting": "Waiting for you to finish signing in with Google.",
@@ -125,7 +123,7 @@
125
123
  },
126
124
  "models": {
127
125
  "title": "Models",
128
- "description": "Ask Antigravity which models this account can use. This also runs after every sign-in.",
126
+ "description": "This also runs after every sign-in.",
129
127
  "refresh": "Refresh models",
130
128
  "result": "Models available: {{count}}."
131
129
  }
@@ -68,8 +68,6 @@
68
68
  "signedOut": "未登录"
69
69
  },
70
70
  "state": {
71
- "signedIn": "此 provider 已用 Google 账号登录。",
72
- "signedOut": "此 provider 尚未登录。",
73
71
  "cancelled": "登录已取消。",
74
72
  "starting": "正在开始 Google 登录…",
75
73
  "waiting": "等待你完成 Google 登录。",
@@ -125,7 +123,7 @@
125
123
  },
126
124
  "models": {
127
125
  "title": "模型",
128
- "description": "向 Antigravity 询问这个账号可以使用哪些模型。每次登录之后也会自动执行一次。",
126
+ "description": "每次登录之后也会自动执行一次。",
129
127
  "refresh": "刷新模型",
130
128
  "result": "可用模型:{{count}} 个。"
131
129
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ycodium-ai/agent-antigravity",
3
- "version": "0.2.3608",
3
+ "version": "0.2.3614",
4
4
  "description": "Google Antigravity executor: runs the Antigravity agent over Agent Client Protocol stdio.",
5
5
  "keywords": [
6
6
  "ycodium",
@@ -31,8 +31,8 @@
31
31
  "typescript": "~6.0.3",
32
32
  "vite-plus": "0.2.2",
33
33
  "yauzl": "^3.4.0",
34
- "@ycodium-ai/plugin-api": "0.2.3608",
35
- "ycodium-acp-executor": "0.2.3608",
34
+ "@ycodium-ai/plugin-api": "0.2.3614",
35
+ "ycodium-acp-executor": "0.2.3614",
36
36
  "ycodium-executor-testing": "0.0.0"
37
37
  },
38
38
  "ycodium": {