@codeyam/codeyam-cli 0.1.13 → 0.1.15
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/analyzer-template/.build-info.json +6 -6
- package/analyzer-template/log.txt +3 -3
- package/codeyam-cli/src/commands/editor.js +62 -27
- package/codeyam-cli/src/commands/editor.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorAudit.test.js +440 -1
- package/codeyam-cli/src/utils/__tests__/editorAudit.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorEntityHelpers.test.js +58 -4
- package/codeyam-cli/src/utils/__tests__/editorEntityHelpers.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/editorScenarios.test.js +76 -0
- package/codeyam-cli/src/utils/__tests__/editorScenarios.test.js.map +1 -1
- package/codeyam-cli/src/utils/__tests__/scenariosManifest.test.js +139 -1
- package/codeyam-cli/src/utils/__tests__/scenariosManifest.test.js.map +1 -1
- package/codeyam-cli/src/utils/backgroundServer.js +1 -1
- package/codeyam-cli/src/utils/backgroundServer.js.map +1 -1
- package/codeyam-cli/src/utils/editorAudit.js +107 -6
- package/codeyam-cli/src/utils/editorAudit.js.map +1 -1
- package/codeyam-cli/src/utils/editorEntityHelpers.js +18 -3
- package/codeyam-cli/src/utils/editorEntityHelpers.js.map +1 -1
- package/codeyam-cli/src/utils/editorScenarios.js +10 -1
- package/codeyam-cli/src/utils/editorScenarios.js.map +1 -1
- package/codeyam-cli/src/utils/scenariosManifest.js +30 -0
- package/codeyam-cli/src/utils/scenariosManifest.js.map +1 -1
- package/codeyam-cli/src/webserver/backgroundServer.js +42 -57
- package/codeyam-cli/src/webserver/backgroundServer.js.map +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{CopyButton-CzTDWkF2.js → CopyButton-CLe80MMu.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{EntityItem-BFbq6iFk.js → EntityItem-Crt_KN_U.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{EntityTypeIcon-B6OMi58N.js → EntityTypeIcon-CD7lGABo.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{InlineSpinner-DuYodzo1.js → InlineSpinner-CgTNOhnu.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{InteractivePreview-CXo9EeCl.js → InteractivePreview-CKeQT5Ty.js} +2 -2
- package/codeyam-cli/src/webserver/build/client/assets/{LibraryFunctionPreview-DYCNb2It.js → LibraryFunctionPreview-D3s1MFkb.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{LogViewer-CZgY3sxX.js → LogViewer-CM5zg40N.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{ReportIssueModal-CnYYwRDw.js → ReportIssueModal-C2PLkej3.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{SafeScreenshot-CDoF7ZpU.js → SafeScreenshot-DanvyBPb.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{ScenarioViewer-DrnfvaLL.js → ScenarioViewer-DUMfcNVK.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{Spinner-Df3UCi8k.js → Spinner-D0LgAaSa.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{ViewportInspectBar-DRKR9T0U.js → ViewportInspectBar-BA_Ry-rs.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{_index-ClR-g3tY.js → _index-BAWd-Xjf.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{activity.(_tab)-DTH6ydEA.js → activity.(_tab)-BOARiB-g.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{addon-web-links-74hnHF59.js → addon-web-links-CHx25PAe.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{agent-transcripts-B8CYhCO9.js → agent-transcripts-Bg3e7q4S.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{book-open-CLaoh4ac.js → book-open-CL-lMgHh.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{chevron-down-BZ2DZxbW.js → chevron-down-GmAjGS9-.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{chunk-JZWAC4HX-BBXArFPl.js → chunk-JZWAC4HX-BAdwhyCx.js} +11 -11
- package/codeyam-cli/src/webserver/build/client/assets/{circle-check-CT4unAk-.js → circle-check-DFcQkN5j.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{copy-zK0B6Nu-.js → copy-C6iF61Xs.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{createLucideIcon-DJB0YQJL.js → createLucideIcon-4ImjHTVC.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{dev.empty-CkXFP_i-.js → dev.empty-C8y4mmyv.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/editor._tab-Gbk_i5Js.js +1 -0
- package/codeyam-cli/src/webserver/build/client/assets/editor.entity.(_sha)-B7xQ9Sjy.js +58 -0
- package/codeyam-cli/src/webserver/build/client/assets/editorPreview-CxmrE6AF.js +41 -0
- package/codeyam-cli/src/webserver/build/client/assets/{entity._sha._-BqAN7hyG.js → entity._sha._-Blfy9UlN.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{entity._sha.scenarios._scenarioId.dev-BOi8kpwd.js → entity._sha.scenarios._scenarioId.dev-CUobbQdQ.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{entity._sha.scenarios._scenarioId.fullscreen-Dg1NhIms.js → entity._sha.scenarios._scenarioId.fullscreen-C6eeL24i.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{entity._sha_.create-scenario-CJX6kkkV.js → entity._sha_.create-scenario-DQM8E7L4.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{entity._sha_.edit._scenarioId-BhVjZhKg.js → entity._sha_.edit._scenarioId-CAoXLsQr.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{entry.client-_gzKltPN.js → entry.client-SuW9syRS.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{files-CV_17tZS.js → files-D-xGrg29.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{git-D-YXmMbR.js → git-Bq_fbXP5.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/globals-fAqOD9ex.css +1 -0
- package/codeyam-cli/src/webserver/build/client/assets/{index-CCrgCshv.js → index-Bp1l4hSv.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{index-BsX0F-9C.js → index-CWV9XZiG.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{index-Blo6EK8G.js → index-DE3jI_dv.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{labs-Byazq8Pv.js → labs-B_IX45ih.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{loader-circle-DVQ0oHR7.js → loader-circle-De-7qQ2u.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/manifest-5d53342d.js +1 -0
- package/codeyam-cli/src/webserver/build/client/assets/{memory-b-VmA2Vj.js → memory-Cx2xEx7s.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{pause-DGcndCAa.js → pause-CFxEKL1u.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/root-DB3O9_9j.js +67 -0
- package/codeyam-cli/src/webserver/build/client/assets/{search-C0Uw0bcK.js → search-BdBb5aqc.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{settings-OoNgHIfW.js → settings-DdE-Untf.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{simulations-Bcemfu8a.js → simulations-DSCdE99u.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{terminal-BgMmG7R9.js → terminal-CrplD4b1.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{triangle-alert-Cs87hJYK.js → triangle-alert-DqJ0j69l.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{useCustomSizes-BR3Rs7JY.js → useCustomSizes-DhXHbEjP.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{useLastLogLine-BxxP_XF9.js → useLastLogLine-BNd5hYuW.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{useReportContext-BermyNU5.js → useReportContext-Cy5Qg_UR.js} +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/{useToast-a_QN_W9_.js → useToast-5HR2j9ZE.js} +1 -1
- package/codeyam-cli/src/webserver/build/server/assets/{analysisRunner-lv2ooewK.js → analysisRunner-DcJSnBCE.js} +1 -1
- package/codeyam-cli/src/webserver/build/server/assets/{index-Im3Smyei.js → index-CEaDhUiv.js} +1 -1
- package/codeyam-cli/src/webserver/build/server/assets/{init-BjuAFKGM.js → init-DA7guOrE.js} +1 -1
- package/codeyam-cli/src/webserver/build/server/assets/server-build-juyiY2m6.js +551 -0
- package/codeyam-cli/src/webserver/build/server/index.js +1 -1
- package/codeyam-cli/src/webserver/build-info.json +5 -5
- package/codeyam-cli/src/webserver/terminalServer.js +1 -1
- package/codeyam-cli/src/webserver/terminalServer.js.map +1 -1
- package/codeyam-cli/templates/nextjs-prisma-sqlite/package.json +1 -1
- package/codeyam-cli/templates/nextjs-prisma-supabase/package.json +1 -1
- package/package.json +1 -1
- package/codeyam-cli/src/webserver/build/client/assets/editor._tab-DPw7NZHc.js +0 -1
- package/codeyam-cli/src/webserver/build/client/assets/editor.entity.(_sha)-CjC3_6JI.js +0 -58
- package/codeyam-cli/src/webserver/build/client/assets/editorPreview-DBa7T2FK.js +0 -41
- package/codeyam-cli/src/webserver/build/client/assets/globals-DRvOjyO3.css +0 -1
- package/codeyam-cli/src/webserver/build/client/assets/manifest-75b1b319.js +0 -1
- package/codeyam-cli/src/webserver/build/client/assets/root-F-k2uYj5.js +0 -67
- package/codeyam-cli/src/webserver/build/server/assets/server-build-CNjF0B9B.js +0 -551
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as o}from"./jsx-runtime-D_zvdyIk.js";import{r as i}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as o}from"./jsx-runtime-D_zvdyIk.js";import{r as i}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{C as u,a as x}from"./copy-C6iF61Xs.js";function h({content:t,label:p="Copy",copiedLabel:l="✓ Copied!",className:c="",duration:a=2e3,ariaLabel:C,icon:n=!1,iconSize:s=14}){const[e,r]=i.useState(!1),d=i.useCallback(()=>{navigator.clipboard.writeText(t).then(()=>{r(!0),setTimeout(()=>r(!1),a)}).catch(m=>{console.error("Failed to copy:",m)})},[t,a]);return o.jsx("button",{onClick:d,className:`cursor-pointer ${c}`,disabled:e,"aria-label":C||(e?"Copied to clipboard":"Copy to clipboard"),"aria-live":"polite",children:n?e?o.jsx(u,{size:s,className:"text-green-500"}):o.jsx(x,{size:s}):e?l:p})}export{h as C};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{c as k}from"./createLucideIcon-
|
|
1
|
+
import{c as k}from"./createLucideIcon-4ImjHTVC.js";import{d as E,r as u,L as N}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{u as T}from"./useToast-5HR2j9ZE.js";import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{f as D,g as F}from"./fileTableUtils-Daa96Fr1.js";import{T as P}from"./TruncatedFilePath-CK7-NaPZ.js";import{S as C}from"./SafeScreenshot-DanvyBPb.js";import{L as B}from"./LibraryFunctionPreview-D3s1MFkb.js";import{T as I}from"./triangle-alert-DqJ0j69l.js";import{E as v}from"./EntityTypeIcon-CD7lGABo.js";import{E as L}from"./EntityTypeBadge-CQgyEGV-.js";/**
|
|
2
2
|
* @license lucide-react v0.577.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{c}from"./createLucideIcon-
|
|
1
|
+
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{c}from"./createLucideIcon-4ImjHTVC.js";/**
|
|
2
2
|
* @license lucide-react v0.577.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as o}from"./jsx-runtime-D_zvdyIk.js";import{r as e}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as o}from"./jsx-runtime-D_zvdyIk.js";import{r as e}from"./chunk-JZWAC4HX-BAdwhyCx.js";const n=["⣾","⣽","⣻","⢿","⡿","⣟","⣯","⣷"],c=80;function m(){const[t,r]=e.useState(0);return e.useEffect(()=>{const s=setInterval(()=>{r(a=>(a+1)%n.length)},c);return()=>clearInterval(s)},[]),o.jsx("span",{className:"inline-block mr-2",children:n[t]})}export{m as I};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-
|
|
2
|
-
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as t}from"./chunk-JZWAC4HX-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-Bp1l4hSv.js","assets/chunk-JZWAC4HX-BAdwhyCx.js","assets/index-CWV9XZiG.js","assets/styles-CMKNK2uU.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as t}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{_ as L}from"./preload-helper-ckwbz45p.js";import{u as Q}from"./useLastLogLine-BNd5hYuW.js";import{S as P}from"./Spinner-D0LgAaSa.js";import{I as B}from"./InlineSpinner-CgTNOhnu.js";const $=t.createContext({dimensions:{height:720,width:1200},updateDimensions:()=>{},iframeRef:{current:null},scale:1,updateScale:()=>{},maxWidth:1200,updateMaxWidth:()=>{}}),U=()=>{const o=t.useContext($);if(!o)throw new Error("useWebContainer must be used within a WebContainerProvider");return o},ce=({children:o})=>{const[i,r]=t.useState({height:720,width:1200}),[d,f]=t.useState(1),[u,g]=t.useState(1200),x=t.useRef(null),h=t.useCallback(({height:l,width:j})=>{r(S=>({height:l??S.height,width:j??S.width}))},[]),v=t.useCallback(l=>{f(l)},[]),w=t.useCallback(l=>{g(l)},[]);return e.jsx($.Provider,{value:{dimensions:i,updateDimensions:h,iframeRef:x,scale:d,updateScale:v,maxWidth:u,updateMaxWidth:w},children:o})},X=typeof window<"u";function Z(){const[o,i]=t.useState(null);return t.useEffect(()=>{L(()=>import("./index-Bp1l4hSv.js").then(r=>r.i),__vite__mapDeps([0,1,2])).then(r=>{i(()=>r.ResizableBox)}),L(()=>Promise.resolve({}),__vite__mapDeps([3]))},[]),o}const ee=1200,te=720,H=30,se=({id:o,scenarioName:i,iframeUrl:r,defaultWidth:d=1440,defaultHeight:f=900,onDataOverride:u,onIframeLoad:g,onScaleChange:x,onDimensionChange:h})=>{const v=Z(),[w,l]=t.useState(!1),[j,S]=t.useState(!1),[c,A]=t.useState(ee),[_,D]=t.useState(te),[E,T]=t.useState(null),[M,I]=t.useState(null),{dimensions:a,updateDimensions:y,iframeRef:m,updateScale:N,updateMaxWidth:R}=U(),k=t.useMemo(()=>Math.min(1,c/a.width),[c,a.width]),p=M!==null?M:k;t.useEffect(()=>{w||(N(p),x==null||x(p))},[p,N,x,w]),t.useEffect(()=>{R(c)},[c,R]);const G=t.useCallback(()=>{l(!0),I(k)},[k]),O=t.useCallback(()=>{l(!1),I(null)},[]),V=t.useCallback((n,s)=>{const b=M!==null?M:1,z=Math.round(s.size.width/b);y({width:z}),h==null||h(z,a.height)},[y,M,h,a.height]),F=t.useCallback(()=>{setTimeout(()=>{S(!0)},100),g&&g()},[g]);t.useEffect(()=>{const n=s=>{if(s.data.type==="codeyam-resize"){if(i&&s.data.name!==i||a.height===s.data.height||s.data.height===0)return;y({height:s.data.height})}};return window.addEventListener("message",n),()=>{window.removeEventListener("message",n)}},[m,i,d,a,y]),t.useEffect(()=>{j&&u&&u(m.current)},[j,u,m]),t.useEffect(()=>{if(!i)return;const n=setInterval(()=>{var s,b;(b=(s=m==null?void 0:m.current)==null?void 0:s.contentWindow)==null||b.postMessage({type:"codeyam-respond",name:i},"*")},1e3);return()=>clearInterval(n)},[i,m]),t.useEffect(()=>{const n=()=>{const s=document.getElementById("scenario-container");if(!s)return;const b=s.getBoundingClientRect(),z=s.clientWidth-H*2,q=window.innerHeight-b.top-H*2,J=Math.max(q,400),K=window.innerHeight-b.top;A(z),D(J),T(K)};return n(),window.addEventListener("resize",n),()=>window.removeEventListener("resize",n)},[]),t.useEffect(()=>{y({width:d,height:f})},[d,f,y]);const C=t.useMemo(()=>a.width*p,[a.width,p]),W=t.useMemo(()=>{const n=a.height,s=n*p;return n&&n!==720&&n!==900&&s<_?s:_},[a.height,_,p]),Y=t.useCallback(()=>{window.history.back()},[]);return!X||!v?e.jsx("div",{className:"relative bg-gray-100 w-full h-full flex items-center justify-center",children:e.jsx("p",{className:"text-gray-500",children:"Loading interactive view..."})}):e.jsxs("div",{id:"scenario-container",className:"relative bg-gray-100 w-full flex items-center justify-center",style:E?{height:`${E}px`}:{},children:[w&&e.jsx("div",{className:"fixed inset-0 z-50 bg-transparent"}),e.jsx("style",{children:`
|
|
3
3
|
.react-resizable-handle-e {
|
|
4
4
|
display: flex !important;
|
|
5
5
|
align-items: center !important;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{j as r}from"./jsx-runtime-D_zvdyIk.js";import{L as C}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as r}from"./jsx-runtime-D_zvdyIk.js";import{L as C}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{g as L}from"./scenarioStatus-B_8jpV3e.js";function V({scenario:s,entitySha:m,size:g="medium",showBorder:j=!0,isOutdated:E=!1}){var x,h,u,p,f,$;const t=L(s,void 0,void 0,m,void 0),e=(x=s.metadata)==null?void 0:x.executionResult,o=!!e,b=(((u=(h=s.metadata)==null?void 0:h.data)==null?void 0:u.argumentsData)||[]).length,c=(e==null?void 0:e.returnValue)!==void 0&&(e==null?void 0:e.returnValue)!==null,i=((f=(p=e==null?void 0:e.sideEffects)==null?void 0:p.consoleOutput)==null?void 0:f.length)||0,d=(($=e==null?void 0:e.timing)==null?void 0:$.duration)||0;let a=0;b>0&&a++,b>2&&a++,c&&a++,i>0&&a++,a=Math.min(3,a);const l=g==="small"?{width:"w-[50px]",height:"h-[38px]",iconSize:"text-base",textSize:"text-[8px]"}:{width:"w-20",height:"h-15",iconSize:"text-xl",textSize:"text-[10px]"},n=t.hasError?{border:"border-red-400",bg:"bg-red-50",icon:"text-red-600",badge:"bg-red-100 text-red-700"}:o?E?{border:"border-amber-500",bg:"bg-amber-50",icon:"text-amber-700",badge:"bg-amber-100 text-amber-700"}:{border:"border-blue-400",bg:"bg-blue-50",icon:"text-blue-600",badge:"bg-blue-100 text-blue-700"}:{border:"border-gray-300 border-dashed",bg:"bg-gray-50",icon:"text-gray-400",badge:"bg-gray-100 text-gray-600"},w=j?`border-2 ${n.border}`:"",S=Array.from({length:3},(v,y)=>r.jsx("div",{className:`w-1 h-1 rounded-full ${y<a?n.icon.replace("text-","bg-"):"bg-gray-300"}`},y)),N=t.hasError?`Error: ${t.errorMessage||"Unknown error"}`:o?`${s.name}
|
|
2
2
|
${b} args → ${c?"value":"void"}${i>0?` (${i} logs)`:""}
|
|
3
3
|
${d}ms`:`Not executed: ${s.name}`;return r.jsxs(C,{to:`/entity/${m}/scenarios/${s.id}`,className:`relative ${l.width} ${l.height} ${w} rounded ${n.bg} flex flex-col items-center justify-center gap-0.5 cursor-pointer transition-all hover:scale-105 hover:shadow-md`,title:N,onClick:v=>v.stopPropagation(),children:[r.jsx("div",{className:`${n.icon} ${l.iconSize} font-mono font-bold`,children:t.hasError?"⚠":o?"ƒ":"○"}),o&&!t.hasError&&r.jsxs("div",{className:`flex items-center gap-0.5 ${l.textSize} ${n.badge} px-1 rounded`,children:[r.jsx("span",{children:b}),r.jsx("span",{children:"→"}),r.jsx("span",{children:c?"✓":"∅"})]}),o&&!t.hasError&&g==="medium"&&r.jsx("div",{className:"flex gap-0.5 mt-0.5",children:S}),o&&!t.hasError&&d>100&&g==="medium"&&r.jsx("div",{className:`absolute top-0.5 right-0.5 ${l.textSize} ${n.badge} px-1 rounded`,children:d>1e3?`${Math.round(d/1e3)}s`:`${d}ms`}),o&&!t.hasError&&i>0&&g==="medium"&&r.jsxs("div",{className:"absolute bottom-0.5 left-0.5 text-[8px] text-gray-500",children:["📝",i]})]})}export{V as L};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r}from"./chunk-JZWAC4HX-BAdwhyCx.js";function j({projectSlug:x,onClose:o}){const[m,l]=r.useState("Loading logs..."),[u,f]=r.useState(!0),[d,g]=r.useState(!0),[n,b]=r.useState("all"),a=r.useRef(null);return r.useEffect(()=>{const t=async()=>{try{const s=await fetch(`/api/logs/${x}`);if(s.ok){const h=await s.text();if(n==="all")l(h);else{const c=h.trim().split(`
|
|
2
2
|
`).filter(i=>{if(i.length===0)return!1;const p=i.match(/^.*CodeYam Log Level (\d+):/);return!!p&&Number(p[1])<=n});l(c.map(i=>i.replace(/^.*CodeYam Log Level \d+:\s*/,"")).join(`
|
|
3
3
|
`))}d&&a.current&&setTimeout(()=>{var c;(c=a.current)==null||c.scrollTo({top:a.current.scrollHeight,behavior:"smooth"})},100)}else l(`Error: ${s.status} - ${await s.text()}`)}catch(s){l(`Error fetching logs: ${s.message}`)}};if(t().catch(()=>{}),u){const s=setInterval(()=>{t().catch(()=>{})},2e3);return()=>clearInterval(s)}},[x,u,d,n]),r.useEffect(()=>{const t=s=>{s.key==="Escape"&&o()};return window.addEventListener("keydown",t),()=>window.removeEventListener("keydown",t)},[o]),e.jsx("div",{className:"fixed inset-0 bg-black/70 flex items-center justify-center z-9999 p-5",onClick:o,children:e.jsxs("div",{className:"bg-[#1e1e1e] rounded-lg shadow-2xl flex flex-col max-w-[1200px] w-full max-h-[90vh] overflow-hidden",onClick:t=>t.stopPropagation(),children:[e.jsxs("div",{className:"flex justify-between items-center px-5 py-4 border-b border-[#333] bg-[#252525]",children:[e.jsxs("h3",{className:"m-0 text-lg font-semibold text-white",children:["Analysis Logs - ",x]}),e.jsxs("div",{className:"flex items-center gap-4",children:[e.jsxs("label",{className:"flex items-center gap-2 text-sm text-[#ccc] select-none",children:[e.jsx("span",{children:"Log Level:"}),e.jsxs("select",{value:n,onChange:t=>b(t.target.value==="all"?"all":Number(t.target.value)),className:"bg-[#333] text-white border border-[#555] rounded px-2 py-1 text-sm cursor-pointer outline-none transition-all hover:border-[#777] hover:bg-[#3a3a3a] focus:border-blue-600",children:[e.jsx("option",{value:"1",children:"1"}),e.jsx("option",{value:"2",children:"2"}),e.jsx("option",{value:"3",children:"3"}),e.jsx("option",{value:"4",children:"4"}),e.jsx("option",{value:"all",children:"All"})]})]}),e.jsxs("label",{className:"flex items-center gap-1.5 text-sm text-[#ccc] cursor-pointer select-none group",children:[e.jsx("input",{type:"checkbox",checked:u,onChange:t=>f(t.target.checked),className:"cursor-pointer"}),e.jsx("span",{className:"group-hover:text-white",children:"Auto-refresh"})]}),e.jsxs("label",{className:"flex items-center gap-1.5 text-sm text-[#ccc] cursor-pointer select-none group",children:[e.jsx("input",{type:"checkbox",checked:d,onChange:t=>g(t.target.checked),className:"cursor-pointer"}),e.jsx("span",{className:"group-hover:text-white",children:"Auto-scroll"})]}),e.jsx("button",{onClick:o,className:"bg-transparent border-none text-[#999] text-2xl cursor-pointer p-0 w-8 h-8 flex items-center justify-center rounded transition-all hover:bg-[#333] hover:text-white",title:"Close (Esc)",children:"✕"})]})]}),e.jsx("pre",{className:"flex-1 m-0 px-5 py-4 overflow-auto font-mono text-[13px] leading-relaxed text-[#d4d4d4] bg-[#1e1e1e] whitespace-pre-wrap wrap-break-word scrollbar-thin scrollbar-thumb-[#424242] scrollbar-track-[#1e1e1e] hover:scrollbar-thumb-[#4f4f4f]",ref:a,children:m})]})})}export{j as L};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as t,d as T}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as t,d as T}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{c as S}from"./createLucideIcon-4ImjHTVC.js";import{C as F}from"./circle-check-DFcQkN5j.js";import{T as k}from"./triangle-alert-DqJ0j69l.js";import{C as E,a as A}from"./copy-C6iF61Xs.js";/**
|
|
2
2
|
* @license lucide-react v0.577.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as a}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as a}from"./chunk-JZWAC4HX-BAdwhyCx.js";function j({screenshotPath:l,cacheBuster:o,alt:x,className:f="",title:n}){const[i,s]=a.useState("loading"),[c,r]=a.useState(!1),d=a.useRef(null),u=o?`/api/screenshot/${l}?cb=${o}`:`/api/screenshot/${l}`,m=()=>{s("success"),r(!0)},h=()=>{s("error"),r(!1)};return a.useEffect(()=>{s("loading"),r(!1);const t=d.current;t!=null&&t.complete&&(t.naturalHeight!==0?(s("success"),r(!0)):(s("error"),r(!1)))},[u]),l?e.jsxs("div",{className:"relative w-full h-full flex items-center justify-center",title:n,children:[e.jsx("img",{ref:d,src:u,alt:x,onLoad:m,onError:h,className:f||"max-w-full max-h-full object-contain",style:{visibility:c?"visible":"hidden",position:c?"relative":"absolute"}}),i==="loading"&&e.jsx("div",{className:"absolute inset-0 bg-gray-100 animate-pulse rounded flex items-center justify-center",children:e.jsx("svg",{className:"w-8 h-8 text-gray-300",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"})})}),i==="error"&&e.jsxs("div",{className:"absolute inset-0 border-2 border-dashed border-gray-300 bg-gray-50 rounded flex flex-col items-center justify-center text-xs gap-1",children:[e.jsx("span",{className:"text-2xl text-gray-400",children:"📷"}),e.jsx("span",{className:"text-gray-400 whitespace-nowrap",children:"No Screenshot"})]})]}):e.jsx("div",{className:"w-full h-full border-2 border-dashed border-gray-300 bg-gray-50 rounded flex flex-col items-center justify-center text-xs gap-1",title:n,children:e.jsx("span",{className:"text-2xl text-gray-400",children:"📷"})})}export{j as S};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as i,d as ge,L as ie}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{r as i,d as ge,L as ie}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{I as be}from"./InteractivePreview-CKeQT5Ty.js";import{V as je}from"./ViewportInspectBar-BA_Ry-rs.js";import{u as we,S as Ne}from"./useCustomSizes-DhXHbEjP.js";import{L as J}from"./LogViewer-CM5zg40N.js";import{S as ve}from"./SafeScreenshot-DanvyBPb.js";import{u as ke}from"./useLastLogLine-BNd5hYuW.js";import{u as Ce}from"./Spinner-D0LgAaSa.js";import{_ as ye}from"./preload-helper-ckwbz45p.js";import{R as Ie}from"./ReportIssueModal-C2PLkej3.js";import{C as Ee,a as Le}from"./copy-C6iF61Xs.js";import{g as Pe}from"./scenarioStatus-B_8jpV3e.js";function $e({presets:s,customSizes:t,currentWidth:n,currentHeight:o,scale:v,onSizeChange:N,onSaveCustomSize:w,onRemoveCustomSize:d,className:k=""}){const[h,x]=i.useState(!1),[g,b]=i.useState(String(n)),[m,j]=i.useState(String(o)),[C,u]=i.useState(!1),[l,R]=i.useState(!1),P=i.useRef(null);i.useEffect(()=>{C||b(String(n))},[n,C]),i.useEffect(()=>{l||j(String(o))},[o,l]),i.useEffect(()=>{const r=f=>{P.current&&!P.current.contains(f.target)&&x(!1)};return document.addEventListener("mousedown",r),()=>document.removeEventListener("mousedown",r)},[]);const $=i.useMemo(()=>{const r=s.find(c=>c.width===n&&c.height===o);if(r)return r.name;const f=t.find(c=>c.width===n&&c.height===o);return f?f.name:"Custom"},[s,t,n,o]),O=$==="Custom",S=r=>{N(r.width,r.height),x(!1)},W=r=>{const f=r.target.value;b(f);const c=parseInt(f,10);!isNaN(c)&&c>0&&N(c,o)},U=r=>{const f=r.target.value;j(f);const c=parseInt(f,10);!isNaN(c)&&c>0&&N(n,c)},A=()=>{u(!1);const r=parseInt(g,10);(isNaN(r)||r<=0)&&b(String(n))},K=()=>{R(!1);const r=parseInt(m,10);(isNaN(r)||r<=0)&&j(String(o))},D=r=>{(r.key==="Enter"||r.key==="Escape")&&r.target.blur()};return e.jsxs("div",{className:`flex items-center gap-3 ${k}`,children:[e.jsxs("div",{className:"relative",ref:P,children:[e.jsxs("button",{onClick:()=>x(!h),className:"flex items-center gap-2 px-3 py-1.5 bg-white border border-gray-300 rounded-md text-sm font-medium text-gray-700 hover:bg-gray-50 focus:outline-none focus:ring-2 focus:ring-[#005c75] focus:ring-offset-1 min-w-[120px] justify-between",children:[e.jsx("span",{children:$}),e.jsx("svg",{className:`w-4 h-4 transition-transform ${h?"rotate-180":""}`,fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})})]}),h&&e.jsx("div",{className:"absolute top-full left-0 mt-1 min-w-full bg-white border border-gray-200 rounded-md shadow-lg z-50",children:e.jsxs("div",{className:"py-1",children:[s.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"px-3 py-1 text-xs font-semibold text-gray-500 uppercase tracking-wider whitespace-nowrap",children:"Presets"}),s.map(r=>e.jsxs("button",{onClick:()=>S(r),className:`w-full text-left px-3 py-2 text-sm hover:bg-gray-100 flex justify-between items-center gap-4 whitespace-nowrap ${$===r.name?"bg-[#f0f7f9] text-[#005c75]":"text-gray-700"}`,children:[e.jsx("span",{children:r.name}),e.jsxs("span",{className:"text-xs text-gray-500",children:[r.width," x ",r.height]})]},r.name))]}),t.length>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"border-t border-gray-100 my-1"}),e.jsx("div",{className:"px-3 py-1 text-xs font-semibold text-gray-500 uppercase tracking-wider whitespace-nowrap",children:"Custom"}),[...t].sort((r,f)=>r.width-f.width).map(r=>e.jsxs("div",{className:`flex items-center gap-1 hover:bg-gray-100 ${$===r.name?"bg-[#f0f7f9] text-[#005c75]":"text-gray-700"}`,children:[e.jsxs("button",{onClick:()=>S(r),className:"flex-1 text-left px-3 py-2 text-sm flex justify-between items-center gap-4 whitespace-nowrap cursor-pointer",children:[e.jsx("span",{children:r.name}),e.jsxs("span",{className:"text-xs text-gray-500",children:[r.width," x ",r.height]})]}),d&&e.jsx("button",{onClick:f=>{f.stopPropagation(),$===r.name&&s.length>0&&N(s[0].width,s[0].height),d(r.name)},className:"p-1.5 mr-1 text-gray-400 hover:text-red-500 hover:bg-red-50 rounded cursor-pointer transition-colors",title:"Remove custom size",children:e.jsx("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:e.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})})})]},r.name))]})]})})]}),e.jsxs("div",{className:"flex items-center gap-1 text-sm",children:[e.jsxs("div",{className:"flex items-center",children:[e.jsx("input",{type:"text",value:g,onChange:W,onFocus:()=>u(!0),onBlur:A,onKeyDown:D,className:"w-16 px-2 py-1 text-right border border-gray-300 rounded-l-md text-sm focus:outline-none focus:ring-2 focus:ring-[#005c75] focus:border-[#005c75]"}),e.jsx("span",{className:"px-2 py-1 bg-gray-100 border border-l-0 border-gray-300 rounded-r-md text-gray-500 text-sm",children:"px"})]}),e.jsx("span",{className:"text-gray-400 mx-1",children:"×"}),e.jsxs("div",{className:"flex items-center",children:[e.jsx("input",{type:"text",value:m,onChange:U,onFocus:()=>R(!0),onBlur:K,onKeyDown:D,className:"w-16 px-2 py-1 text-right border border-gray-300 rounded-l-md text-sm focus:outline-none focus:ring-2 focus:ring-[#005c75] focus:border-[#005c75]"}),e.jsx("span",{className:"px-2 py-1 bg-gray-100 border border-l-0 border-gray-300 rounded-r-md text-gray-500 text-sm",children:"px"})]}),v!==void 0&&v<1&&e.jsxs("span",{className:"text-xs text-gray-500 ml-1",children:["(",Math.round(v*100),"%)"]})]}),O&&e.jsx("button",{onClick:w,className:"px-3 py-1.5 bg-[#005c75] text-white text-sm font-medium rounded-md hover:bg-[#004a5c] focus:outline-none focus:ring-2 focus:ring-[#005c75] focus:ring-offset-1 transition-colors",children:"Save Custom Size"})]})}function de({size:s=24,className:t=""}){return e.jsxs("svg",{width:s,height:s,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:t,"aria-hidden":"true",children:[e.jsx("path",{d:"M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z",fill:"#ef4444",stroke:"none"}),e.jsx("line",{x1:"12",y1:"9",x2:"12",y2:"13",stroke:"#FFFFFF",strokeWidth:"2",strokeLinecap:"round"}),e.jsx("circle",{cx:"12",cy:"17",r:"1",fill:"#FFFFFF"})]})}function _e({scenario:s,analysis:t,entity:n}){var w,d,k;const o=((w=s.metadata)==null?void 0:w.executionResult)||null,v=((k=(d=s.metadata)==null?void 0:d.data)==null?void 0:k.argumentsData)||[],N=h=>{var j,C,u;if(!h)return"No execution results available yet. Run the function to capture side effects including console output, file operations, and API calls.";const x=[],g=((j=h.sideEffects)==null?void 0:j.consoleOutput)||[];g.length>0&&(x.push(`Console Output: ${g.length} log ${g.length===1?"entry":"entries"} captured`),g.forEach(l=>{x.push(` [${l.level.toUpperCase()}] ${l.args.join(" ")}`)}));const b=((C=h.sideEffects)==null?void 0:C.fileWrites)||[];b.length>0&&(x.push(`
|
|
2
2
|
File System Operations: ${b.length} ${b.length===1?"operation":"operations"} detected`),b.forEach(l=>{x.push(` ${l.operation}: ${l.path}${l.size?` (${l.size} bytes)`:""}`)}));const m=((u=h.sideEffects)==null?void 0:u.apiCalls)||[];return m.length>0&&(x.push(`
|
|
3
3
|
API Calls: ${m.length} ${m.length===1?"call":"calls"} made`),m.forEach(l=>{x.push(` ${l.method} ${l.url}${l.status?` → ${l.status}`:""}${l.duration?` (${l.duration}ms)`:""}`)})),h.error&&x.push(`
|
|
4
4
|
Error: ${h.error.name||"Error"}: ${h.error.message}`),x.length===0?"No side effects detected. The function executed without console output, file operations, or API calls.":x.join(`
|
package/codeyam-cli/src/webserver/build/client/assets/{Spinner-Df3UCi8k.js → Spinner-D0LgAaSa.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{d as P,r as t}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{d as P,r as t}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{u as _}from"./useLastLogLine-BNd5hYuW.js";import{j as y}from"./jsx-runtime-D_zvdyIk.js";function R(s){const o=s.replace(/[^a-zA-Z0-9_]+/g,"_");return o.slice(0,1).toUpperCase()+o.slice(1)}function G({analysisId:s,scenarioId:o,scenarioName:i,entityName:c,projectSlug:m,enabled:x=!0,refreshTrigger:p=0}){const k=P(),[b,E]=t.useState(null),[q,U]=t.useState(!1),[z,u]=t.useState(!1),[A,f]=t.useState(!1),v=t.useRef(!1),I=t.useRef(null),g=t.useRef(null),h=t.useRef(null),[F,w]=t.useState(0),[j,M]=t.useState(0),r=t.useRef(null),l=t.useRef(!1),{interactiveUrl:L,resetLogs:T}=_(m,x),C=t.useRef(o),B=t.useRef(p);t.useEffect(()=>{B.current!==p&&(B.current=p,b&&(console.log("[useInteractiveMode] Manual refresh triggered"),u(!0),f(!1),w(0),M(e=>e+1),l.current=!1,r.current&&(clearTimeout(r.current),r.current=null)))},[p,b]),t.useEffect(()=>{if(C.current!==o&&(C.current=o,I.current&&g.current&&i)){let e=I.current;if(h.current&&c){const a=R(h.current),d=R(c);a!==d&&(e=e.replace(a,d),h.current=c)}const n=R(g.current),S=R(i);e=e.replace(n,S),g.current=i,E(e),u(!0),f(!1),w(0),M(a=>a+1),l.current=!1,r.current&&(clearTimeout(r.current),r.current=null);return}},[o,i,c]),t.useEffect(()=>{if(L){const e=L+"?width=600px";I.current=e,i&&(g.current=i),c&&(h.current=c),E(e),U(!1),u(!0)}},[L]),t.useEffect(()=>{const e=n=>{n.data.type==="codeyam-resize"&&(l.current||(l.current=!0,r.current&&(clearTimeout(r.current),r.current=null),w(0),f(!0),requestAnimationFrame(()=>{requestAnimationFrame(()=>{u(!1)})})))};return window.addEventListener("message",e),()=>window.removeEventListener("message",e)},[]);const D=()=>{l.current=!1,r.current&&clearTimeout(r.current);const e=300*Math.pow(2,F);r.current=setTimeout(()=>{l.current||(F<2?(w(n=>n+1),M(n=>n+1),u(!0)):(console.error("[useInteractiveMode] Interactive mode failed to load after 3 attempts - showing iframe anyway"),f(!0),u(!1)))},e)};return t.useEffect(()=>{x&&!v.current&&o&&s&&(v.current=!0,U(!0),f(!1),E(null),(async()=>{if(m)try{await fetch(`/api/logs/${m}`,{method:"DELETE"})}catch(n){console.error("[useInteractiveMode] Failed to clear log file:",n)}T(),k.submit({action:"start",analysisId:s,scenarioId:o},{method:"post",action:"/api/interactive-mode"})})())},[x,o,s,T,m]),t.useEffect(()=>{const e=s,n=()=>{if(v.current&&e){const a=new URLSearchParams({action:"stop",analysisId:e});console.log("[useInteractiveMode] Sending stop request via sendBeacon");const d=navigator.sendBeacon("/api/interactive-mode",a);console.log("[useInteractiveMode] sendBeacon result:",d),d||(console.log("[useInteractiveMode] sendBeacon failed, using fetch fallback"),fetch("/api/interactive-mode",{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:a,keepalive:!0}).catch(K=>console.error("Failed to stop interactive mode:",K)))}},S=()=>{n()};return window.addEventListener("beforeunload",S),()=>{window.removeEventListener("beforeunload",S),console.log("[useInteractiveMode] Cleanup running:",{hasStarted:v.current,analysisId:e}),n()}},[s]),{interactiveServerUrl:b,isStarting:q,isLoading:z,showIframe:A,iframeKey:j,onIframeLoad:D}}function H(){return y.jsxs("div",{className:"spinner-container",children:[y.jsx("span",{className:"loader"}),y.jsx("style",{children:`
|
|
2
2
|
.loader {
|
|
3
3
|
width: 48px;
|
|
4
4
|
height: 48px;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as n}from"./jsx-runtime-D_zvdyIk.js";import{r as u}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{j as n}from"./jsx-runtime-D_zvdyIk.js";import{r as u}from"./chunk-JZWAC4HX-BAdwhyCx.js";const m=10,W=1024;function L({currentViewportWidth:g,currentPresetName:P,onDevicePresetClick:w,devicePresets:p,onHoverChange:c,hideLabel:E=!1,lightMode:d=!1}){const[r,v]=u.useState(null),x=u.useRef(null),j=u.useMemo(()=>[...p].sort((t,s)=>t.width-s.width),[p]),{fittingPresets:o,overflowPresets:i}=u.useMemo(()=>{const t=[],s=[];for(const e of j)e.width<=W?t.push(e):s.push(e);return s.sort((e,l)=>l.width-e.width),{fittingPresets:t,overflowPresets:s}},[j]),b=u.useCallback(t=>{if(!x.current)return null;const s=x.current.getBoundingClientRect(),e=t-s.left,l=s.width,h=l/2,y=(o.length>0?o[o.length-1].width:0)/2,S=h-y,X=h+y,$=i.length>0?(i.length-1)*m:0;if(i.length>0){if(e<S){if(e<=$){const a=Math.min(Math.floor(e/m),i.length-1);return i[a]}return i[i.length-1]}if(e>X){const a=l-e;if(a<=$){const f=Math.min(Math.floor(a/m),i.length-1);return i[f]}return i[i.length-1]}}const k=Math.abs(e-h);for(let a=o.length-1;a>=0;a--){const f=o[a],F=o[a-1],B=f.width/2,T=F?F.width/2:0;if(k<=B&&k>=T)return f}return o[0]||i[i.length-1]||null},[o,i]),I=u.useCallback(t=>{const s=b(t.clientX);v(s),c==null||c(s)},[b,c]),M=u.useCallback(()=>{v(null),c==null||c(null)},[c]),R=u.useCallback(t=>{const s=b(t.clientX);s&&w(s)},[b,w]),N=r||{name:P,width:g};return n.jsxs("div",{ref:x,className:"relative h-6 shrink-0 overflow-hidden cursor-pointer",onMouseMove:I,onMouseLeave:M,onClick:R,children:[r&&n.jsx("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:n.jsx("div",{className:"h-full transition-all duration-100 bg-[#005C75]",style:{width:`${r.width}px`}})}),n.jsx("div",{className:"absolute inset-0 pointer-events-none",children:o.map(t=>{const s=t.width===g,e=(r==null?void 0:r.name)===t.name,l=t.width/2;return n.jsxs("div",{children:[n.jsx("div",{className:"absolute top-0 bottom-0",style:{left:`calc(50% - ${l}px)`},children:n.jsx("div",{className:`w-0.5 h-full transition-colors duration-75 ${s||e?d?"bg-gray-900":"bg-white":d?"bg-[rgba(0,0,0,0.2)]":"bg-[rgba(255,255,255,0.3)]"}`})}),n.jsx("div",{className:"absolute top-0 bottom-0",style:{left:`calc(50% + ${l}px)`},children:n.jsx("div",{className:`w-0.5 h-full transition-colors duration-75 ${s||e?d?"bg-gray-900":"bg-white":d?"bg-[rgba(0,0,0,0.2)]":"bg-[rgba(255,255,255,0.3)]"}`})})]},t.name)})}),n.jsx("div",{className:"absolute inset-0 pointer-events-none",children:i.map((t,s)=>{const e=s*m,l=t.width===g,h=(r==null?void 0:r.name)===t.name;return n.jsxs("div",{children:[n.jsx("div",{className:"absolute top-0 bottom-0",style:{left:`${e}px`},children:n.jsx("div",{className:`w-0.5 h-full transition-colors duration-75 ${l||h?d?"bg-gray-900":"bg-white":d?"bg-[rgba(0,0,0,0.2)]":"bg-[rgba(255,255,255,0.3)]"}`})}),n.jsx("div",{className:"absolute top-0 bottom-0",style:{right:`${e}px`},children:n.jsx("div",{className:`w-0.5 h-full transition-colors duration-75 ${l||h?d?"bg-gray-900":"bg-white":d?"bg-[rgba(0,0,0,0.2)]":"bg-[rgba(255,255,255,0.3)]"}`})})]},t.name)})}),!E&&n.jsx("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:n.jsxs("div",{className:`text-[10px] px-2 py-0.5 rounded shadow-sm whitespace-nowrap transition-colors ${r?"bg-[#005c75] text-white":"bg-white/90 text-[#005c75] border border-[rgba(0,92,117,0.25)]"}`,children:[N.name," - ",N.width,"px"]})})]})}export{L as V};
|
package/codeyam-cli/src/webserver/build/client/assets/{_index-ClR-g3tY.js → _index-BAWd-Xjf.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{r as u,L as p,w as se,u as te,d as ae,f as re}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{r as u,L as p,w as se,u as te,d as ae,f as re}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{u as ne}from"./useLastLogLine-BNd5hYuW.js";import{u as le}from"./useToast-5HR2j9ZE.js";import{u as oe}from"./useReportContext-Cy5Qg_UR.js";import{L as ie}from"./LogViewer-CM5zg40N.js";import{I as E,C as P,E as ce}from"./EntityTypeIcon-CD7lGABo.js";import{S as Y}from"./SafeScreenshot-DanvyBPb.js";import{g as de}from"./scenarioStatus-B_8jpV3e.js";import{c as q}from"./createLucideIcon-4ImjHTVC.js";import{C as xe}from"./circle-check-DFcQkN5j.js";import{L as S}from"./loader-circle-De-7qQ2u.js";/**
|
|
2
2
|
* @license lucide-react v0.577.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{w as se,u as te,j as re,r as f,L as b,f as R}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{w as se,u as te,j as re,r as f,L as b,f as R}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{L as oe}from"./LogViewer-CM5zg40N.js";import{u as ie}from"./useLastLogLine-BNd5hYuW.js";import{u as le}from"./useReportContext-Cy5Qg_UR.js";import{E as q}from"./EntityTypeIcon-CD7lGABo.js";import{E as ee}from"./EntityTypeBadge-CQgyEGV-.js";import{S as Z}from"./SafeScreenshot-DanvyBPb.js";import{L as ae}from"./LoadingDots-By5zI316.js";import{L as ne}from"./loader-circle-De-7qQ2u.js";import{P as ce,F as de}from"./pause-CFxEKL1u.js";import{c as X}from"./createLucideIcon-4ImjHTVC.js";/**
|
|
2
2
|
* @license lucide-react v0.577.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{g as O}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{g as O}from"./chunk-JZWAC4HX-BAdwhyCx.js";function j(b,k){for(var _=0;_<k.length;_++){const l=k[_];if(typeof l!="string"&&!Array.isArray(l)){for(const u in l)if(u!=="default"&&!(u in b)){const L=Object.getOwnPropertyDescriptor(l,u);L&&Object.defineProperty(b,u,L.get?L:{enumerable:!0,get:()=>l[u]})}}}return Object.freeze(Object.defineProperty(b,Symbol.toStringTag,{value:"Module"}))}var w={exports:{}},$;function A(){return $||($=1,(function(b,k){(function(_,l){b.exports=l()})(self,(()=>(()=>{var _={6:(p,d)=>{function h(n){try{const e=new URL(n),t=e.password&&e.username?`${e.protocol}//${e.username}:${e.password}@${e.host}`:e.username?`${e.protocol}//${e.username}@${e.host}`:`${e.protocol}//${e.host}`;return n.toLocaleLowerCase().startsWith(t.toLocaleLowerCase())}catch{return!1}}Object.defineProperty(d,"__esModule",{value:!0}),d.LinkComputer=d.WebLinkProvider=void 0,d.WebLinkProvider=class{constructor(n,e,t,r={}){this._terminal=n,this._regex=e,this._handler=t,this._options=r}provideLinks(n,e){const t=f.computeLink(n,this._regex,this._terminal,this._handler);e(this._addCallbacks(t))}_addCallbacks(n){return n.map((e=>(e.leave=this._options.leave,e.hover=(t,r)=>{if(this._options.hover){const{range:c}=e;this._options.hover(t,r,c)}},e)))}};class f{static computeLink(e,t,r,c){const g=new RegExp(t.source,(t.flags||"")+"g"),[o,s]=f._getWindowedLineStrings(e-1,r),i=o.join("");let a;const x=[];for(;a=g.exec(i);){const v=a[0];if(!h(v))continue;const[m,W]=f._mapStrIdx(r,s,0,a.index),[y,P]=f._mapStrIdx(r,m,W,v.length);if(m===-1||W===-1||y===-1||P===-1)continue;const S={start:{x:W+1,y:m+1},end:{x:P,y:y+1}};x.push({range:S,text:v,activate:c})}return x}static _getWindowedLineStrings(e,t){let r,c=e,g=e,o=0,s="";const i=[];if(r=t.buffer.active.getLine(e)){const a=r.translateToString(!0);if(r.isWrapped&&a[0]!==" "){for(o=0;(r=t.buffer.active.getLine(--c))&&o<2048&&(s=r.translateToString(!0),o+=s.length,i.push(s),r.isWrapped&&s.indexOf(" ")===-1););i.reverse()}for(i.push(a),o=0;(r=t.buffer.active.getLine(++g))&&r.isWrapped&&o<2048&&(s=r.translateToString(!0),o+=s.length,i.push(s),s.indexOf(" ")===-1););}return[i,c]}static _mapStrIdx(e,t,r,c){const g=e.buffer.active,o=g.getNullCell();let s=r;for(;c;){const i=g.getLine(t);if(!i)return[-1,-1];for(let a=s;a<i.length;++a){i.getCell(a,o);const x=o.getChars();if(o.getWidth()&&(c-=x.length||1,a===i.length-1&&x==="")){const v=g.getLine(t+1);v&&v.isWrapped&&(v.getCell(0,o),o.getWidth()===2&&(c+=1))}if(c<0)return[t,a]}t++,s=0}return[t,s]}}d.LinkComputer=f}},l={};function u(p){var d=l[p];if(d!==void 0)return d.exports;var h=l[p]={exports:{}};return _[p](h,h.exports,u),h.exports}var L={};return(()=>{var p=L;Object.defineProperty(p,"__esModule",{value:!0}),p.WebLinksAddon=void 0;const d=u(6),h=/(https?|HTTPS?):[/]{2}[^\s"'!*(){}|\\\^<>`]*[^\s"':,.!?{}|\\\^~\[\]`()<>]/;function f(n,e){const t=window.open();if(t){try{t.opener=null}catch{}t.location.href=e}else console.warn("Opening link blocked as opener could not be cleared")}p.WebLinksAddon=class{constructor(n=f,e={}){this._handler=n,this._options=e}activate(n){this._terminal=n;const e=this._options,t=e.urlRegex||h;this._linkProvider=this._terminal.registerLinkProvider(new d.WebLinkProvider(this._terminal,t,this._handler,e))}dispose(){var n;(n=this._linkProvider)==null||n.dispose()}}})(),L})()))})(w)),w.exports}var C=A();const T=O(C),E=j({__proto__:null,default:T},[C]);export{E as a};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{w as O,u as P,a as I,i as B,r as m,L as D}from"./chunk-JZWAC4HX-
|
|
1
|
+
import{w as O,u as P,a as I,i as B,r as m,L as D}from"./chunk-JZWAC4HX-BAdwhyCx.js";import{j as e}from"./jsx-runtime-D_zvdyIk.js";import{u as U}from"./useReportContext-Cy5Qg_UR.js";import{c as w}from"./createLucideIcon-4ImjHTVC.js";import{T as F,C as N}from"./terminal-CrplD4b1.js";import{S as V}from"./search-BdBb5aqc.js";import{C as _}from"./chevron-down-GmAjGS9-.js";import{B as A}from"./book-open-CL-lMgHh.js";import{T as H}from"./triangle-alert-DqJ0j69l.js";import{C as q,a as z}from"./copy-C6iF61Xs.js";/**
|
|
2
2
|
* @license lucide-react v0.577.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|