feat(ui): bring back quick launcher (#5144)

Signed-off-by: Abhijay007 <Abhijay007j@gmail.com>
Co-authored-by: Alex Hancock <alexhancock@block.xyz>
This commit is contained in:
Abhijay Jain
2025-11-06 21:05:31 +05:30
committed by GitHub
parent 803bb78308
commit 0a4cf49064
5 changed files with 191 additions and 45 deletions
+18 -13
View File
@@ -8,20 +8,25 @@ import { client } from './api/client.gen';
const App = lazy(() => import('./App'));
(async () => {
console.log('window created, getting goosed connection info');
const baseUrl = await window.electron.getGoosedHostPort();
if (baseUrl === null) {
window.alert('failed to start goose backend process');
return;
// Check if we're in the launcher view (doesn't need goosed connection)
const isLauncher = window.location.hash === '#/launcher';
if (!isLauncher) {
console.log('window created, getting goosed connection info');
const baseUrl = await window.electron.getGoosedHostPort();
if (baseUrl === null) {
window.alert('failed to start goose backend process');
return;
}
console.log('connecting at', baseUrl);
client.setConfig({
baseUrl,
headers: {
'Content-Type': 'application/json',
'X-Secret-Key': await window.electron.getSecretKey(),
},
});
}
console.log('connecting at', baseUrl);
client.setConfig({
baseUrl,
headers: {
'Content-Type': 'application/json',
'X-Secret-Key': await window.electron.getSecretKey(),
},
});
ReactDOM.createRoot(document.getElementById('root')!).render(
<React.StrictMode>