(prompt: string)
| 122 | }; |
| 123 | |
| 124 | const handleExampleClick = (prompt: string) => { |
| 125 | const width = |
| 126 | iFrameWrapperRef.current?.clientWidth || |
| 127 | (window.innerWidth < 768 ? window.innerWidth - 32 : 1024); |
| 128 | const height = |
| 129 | iFrameWrapperRef.current?.clientHeight || |
| 130 | (window.innerWidth < 768 ? Math.min(window.innerHeight * 0.4, 400) : 768); |
| 131 | |
| 132 | sendMessage({ |
| 133 | content: prompt, |
| 134 | sandboxId: sandboxId || undefined, |
| 135 | environment: "linux", |
| 136 | resolution: [width, height], |
| 137 | }); |
| 138 | }; |
| 139 | |
| 140 | const handleSandboxCreated = (newSandboxId: string, newVncUrl: string) => { |
| 141 | setSandboxId(newSandboxId); |
nothing calls this directly
no test coverage detected