fix(desktop): find the sidecar in a macOS app bundle and fit the startup screen (UF-004, UF-017)

- The packaged macOS app stayed on "Starting Waggle…": the shell looked
  for node, service.js, native/ and node_modules/ next to the executable,
  the Windows layout, while a macOS bundle keeps them in
  Contents/Resources/resources. bundled_resources_dir() checks both.
- The startup screen used min-height 100vh on an unstyled body, which
  showed scroll bars, and a fixed light text colour that is invisible in
  the light theme. It is now styled from index.html, fixed to the window,
  with a dark text colour for the light theme.
This commit is contained in:
shumeiko.it
2026-10-24 19:10:23 +02:00
parent 276808cd69
commit 1f536151d8
4 changed files with 64 additions and 20 deletions

View File

@@ -11,6 +11,18 @@
<style>
html { background-color: #14110b; }
html[data-theme="light"] { background-color: #f7f1e4; }
/* Startup screen (src/main.tsx), shown before the app's styles load. It
fills the window without overflowing the unstyled body. */
[data-waggle-startup] {
position: fixed;
inset: 0;
display: flex;
align-items: center;
justify-content: center;
font: 16px system-ui, sans-serif;
color: #f6f1e4;
}
html[data-theme="light"] [data-waggle-startup] { color: #14110b; }
</style>
<link rel="icon" type="image/png" href="/waggle-logo.png" />

View File

@@ -6,16 +6,8 @@ if (!root) throw new Error('Waggle root element is missing');
const startup = document.createElement('main');
startup.setAttribute('role', 'status');
startup.setAttribute('aria-live', 'polite');
// Styled by the [data-waggle-startup] rules in index.html.
startup.dataset.waggleStartup = 'loading';
Object.assign(startup.style, {
alignItems: 'center',
color: '#f6f1e4',
display: 'flex',
fontFamily: 'system-ui, sans-serif',
fontSize: '16px',
justifyContent: 'center',
minHeight: '100vh',
});
const startupMessage = document.createElement('p');
startupMessage.textContent = 'Starting Waggle…';