Skip to main content

SHEET 06 OF 41

/DOC/:SLUG

PART:
03 DOCUMENTATION
CIRCULATION:
PUBLIC
SOURCE:
pages/Doc/[...Slug].astro
AS OF:
2026-12-02

Sky is the UI component layer of Land - the Astro-based interface that renders the editor, side bar, activity bar, status bar, and panels inside the Tauri WebView, loading the VS Code workbench from Output.

/Elements

Sky: UI Component Layer

Sky is the UI component layer of Land - the Astro-based interface that renders the editor, side bar, activity bar, status bar, and panels inside the Tauri WebView, loading the VS Code workbench from Output.

PUBLISHED ELEMENTS Source/Content/doc/sky.md UNAVAILABLE UNAVAILABLE ARCHITECTURE 9

STATUS UNAVAILABLE NEXT OPEN THE ELEMENT'S MANUAL - IT DESCRIBES THE THING THE CAPTURE WOULD HAVE SHOWN.

# PLATE_01 / SKY

FIGURE: The capture this record's evidence would show: night sky with distant light.

The manifest is in the build and the plate beside it is not. The capture it describes is a texture study of the element's material, not a screenshot of its interface.

SUBJECT:
NIGHT SKY WITH DISTANT LIGHT
MANIFEST:
Public/Evidence/Sky/manifest.yaml
STATE:
MANIFEST PLACEHOLDER
PLATE:
UNAVAILABLE

SOURCE: Public/Evidence/Sky/manifest.yaml

Sky is the UI component layer of Land.

  • Sky is built with the Astro framework.
  • It renders the editor interface inside the Tauri WebView:
    • editor
    • side bar
    • activity bar
    • status bar
    • panels
  • It loads the VS Code workbench from @codeeditorland/output.
  • It communicates via SkyBridge for event routing.

Mermaid diagram

Overview 📋

Sky is the rendering layer that presents the Land editor to the user.

Attribute Value
Language TypeScript (Astro v6, Vite v8)
Framework Astro + Vite
IPC Tauri events (via SkyBridge)
Dependencies @codeeditorland/wind, @codeeditorland/output, @codeeditorland/cocoon, @codeeditorland/worker, @xterm/xterm, astro, vite, zod
Consumes Wind (services), Output (bundles), Worker (service worker)

Architecture 🏗️

Mermaid diagram

Module Map 🗺️

Path Purpose
Source/pages/index.astro Main entry page
Source/pages/Mountain.astro Mountain workbench variant
Source/pages/Browser.astro Browser workbench variant
Source/pages/Electron.astro Electron workbench variant
Source/pages/Isolation.astro Isolation mode variant
Source/Workbench/Mountain.astro Mountain workbench component
Source/Workbench/Browser.astro Browser workbench component
Source/Workbench/Electron/ Electron workbench component
Source/Workbench/Bundled/ Pre-compiled workbench chunks
Source/Function/SkyBridge.ts Tauri event routing bridge
Source/Function/Debug.ts Debug utilities
Source/Function/Shared.ts Shared UI utilities
Source/Function/Build/ Build-time compilation helpers

Page Structure 📄

Sky provides multiple page entry points, each selecting a different workbench variant.

index.astro

The default entry point. It selects the active workbench at build time based on environment variables:

---
// Pseudo-code from Sky's build-time conditional import
const WorkbenchComponent =
	TierWorkbench === "Mountain"
		? MountainWorkbench
		: TierWorkbench === "Electron"
			? ElectronWorkbench
			: TierWorkbench === "Browser"
				? BrowserWorkbench
				: DefaultWorkbench;
---

<WorkbenchComponent />

Pages Overview

Page Workbench Purpose
index.astro Dynamic Default entry point, delegates to workbench selector
Mountain.astro Mountain Production workbench for Tauri runtime
Browser.astro Browser Development workbench with limited native features
Electron.astro Electron Maximum VS Code compatibility variant
BrowserProxy.astro Browser Proxy-mode workbench
Isolation.astro Isolation Minimal workbench for testing

Workbench Variants 🖥️

Sky supports multiple workbench variants compiled through Vite/Rollup:

Variant Astro Page Feature Coverage Build Profile
Mountain Mountain.astro 80-90% debug-mountain
Browser Browser.astro 70-80% debug
Electron Electron.astro 95%+ debug-electron
Default Default.astro Base workbench debug-workbench-bundled
BrowserProxy BrowserProxy.astro 70-80% debug-browser
NLS NLS.astro Natural language search (experimental)

Variant Selection

The active variant is selected at build time and compiled by Vite. Unused variants are tree-shaken and do not enter the production module graph:

// astro.config.ts maps TierWorkbench to import path
const workbenchPath =
	{
		mountain: "./Workbench/Mountain.astro",
		browser: "./Workbench/Browser.astro",
		electron: "./Workbench/Electron.astro",
	}[TierWorkbench] || "./Workbench/Default.astro";

SkyBridge 🌉

SkyBridge (Source/Function/SkyBridge.ts, ~2900 lines) is the runtime event routing bridge between Tauri’s IPC system and the VS Code workbench’s internal message channel system.

Event Translation Table

Tauri Event VS Code Workbench Channel Direction
mountain:configurationChanged onDidChangeConfiguration Mountain -> Workbench
mountain:extensionsChanged onDidChangeExtensions Mountain -> Workbench
mountain:themeChanged onDidChangeColorTheme Mountain -> Workbench
mountain:fileChanged FileSystem watcher events Mountain -> Workbench
cocoon:commandExecuted Extension command result Cocoon -> Workbench

Bridge Architecture

flowchart TD
    A["Mountain emits Tauri event"] --> B["Tauri WebView event listener"]
    B --> C["SkyBridge intercepts event"]
    C --> D["Translates to VS Code internal channel format"]
    C --> E["Dispatches to registered workbench handlers"]
    C --> F["Handles async responses if required"]
    D --> G["VS Code workbench service receives notification"]
    E --> G
    F --> G

Webview Panel Management

SkyBridge manages webview content injection through first-set-html logging:

Extension calls vscode.window.createWebviewPanel()
    |
    v
Cocoon sends gRPC createWebviewPanel request
    |
    v
Mountain creates Wry webview
    |
    v
SkyBridge sets HTML content:
    applied=method  -> Content reached real WebviewInput
    applied=setter  -> Content stored, view not yet parked
    applied=skipped -> No parked view available (silent drop)

Build-time Variant Selection 🔧

Sky uses Vite’s conditional dynamic imports to select the active workbench at build time:

// vite.config.ts / astro.config.ts
// The TierWorkbench env var determines which variant is compiled
const activeWorkbench = process.env.TierWorkbench || "Mountain";

Bundle Output

Each variant produces its own bundle:

Sky/Target/Static/
+-- Bundled/
    +-- Mountain/          # When TierWorkbench=Mountain
    |   +-- workbench.js
    |   +-- workbench.css
    +-- Electron/          # When TierWorkbench=Electron
    |   +-- workbench.js
    |   +-- workbench.css
    +-- Browser/           # When TierWorkbench=Browser
        +-- workbench.js
        +-- workbench.css
+-- Application/          # Static assets (non-bundled mode)

Static Asset Layout 📁

After a successful build, Sky’s output is organized as:

Sky/Target/
+-- Static/
    +-- Bundled/
    |   +-- {Variant}/
    |       +-- workbench.js          # Compiled workbench bundle
    |       +-- workbench.css         # Compiled workbench styles
    |       +-- chunks/               # Lazy-loaded code chunks
    +-- Application/                  # Dev mode static assets
        +-- index.html                # Compiled entry page
        +-- assets/                   # CSS, JS, fonts
        +-- worker.js                 # Service worker script


Project Maintainers: Source Open (Source/[email protected]) | GitHub Repository | Report an Issue

The record this page documents, as the site files it: the six facts the claim is checked against, and the three files the manual names to check it.

WORKING, 06

FORM:
UI LAYER
WRITTEN IN:
ASTRO
BOUNDARY:
TAURI WEBVIEW
DEPENDS ON:
WIND
EVIDENCE:
MANIFEST PLACEHOLDER PLATE NOT IN BUILD

# TRACE / SKY 03 STEPS

  1. 01 Browser.astro THE BROWSER ENTRY
  2. 02 Electron.astro THE ELECTRON SHIM
  3. 03 InstallCommands.ts THE COMMANDS

SOURCE: /DOC/DEEP-DIVE-SKY

Elements, 17 PAGES, page 12 of 17

THE LAYER'S INDEX

NEXT: /BLOG 04 BLOG

NOTES FROM THE BUILD, NEWEST FIRST

〈06〉 /DOC/:SLUG 41 SHEETS AS OF: 2026-12-02