HagalazOS GUI mode is a fully browser-native desktop environment that boots inside a single HTML page. It recreates the feel of a classic windowed OS — draggable windows, a persistent taskbar, and a grid of clickable desktop icons — using nothing but HTML, CSS, and vanilla JavaScript running directly in any modern browser tab.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/linuxfandudeguy/HagalazOS/llms.txt
Use this file to discover all available pages before exploring further.
How it loads
The entry point isos.html. On page load it pulls in three layers of scripts and styles:
Styles
Two CDN stylesheets are applied first:
- 7.css (
unpkg.com/7.css) — provides the complete Windows 7 visual theme for window chrome, buttons, and title bars. - Bootstrap Icons (
cdn.jsdelivr.net/npm/bootstrap-icons) — supplies thebi-*icon classes used on desktop shortcuts and taskbar buttons.
style.css (wallpaper, taskbar, and window-wrapper geometry) and desktop.css (icon grid and highlight pseudo-element).Core scripts
script.js is the kernel: it owns the grid system, window lifecycle (openWindow, minimizeWindow, maximizeWindow, closeWindow), blob-iframe rendering, drag logic, and the Ctrl+X hotkey listener.dragjs.js is loaded immediately after and enables drag-and-drop of .js files onto the desktop — dropped scripts are evaluated in-page, allowing sideloaded app registrations at runtime.DOM regions
The page body contains exactly three top-level regions that cooperate to produce the desktop layout.| Element | Role |
|---|---|
#desktop | Absolutely-positioned container for all desktop icon divs |
#windows | Absolutely-positioned container where .window-wrapper divs are appended when apps open |
.taskbar / #taskbar | Fixed 48 px bar pinned to bottom: 0 holding quick-launch buttons |
#desktop and #windows are both position: absolute; width: 100%; height: 100% so they overlay each other. Windows are rendered above icons because they receive a higher z-index via zIndexCounter.App registration
Apps declare themselves by pushing a descriptor object ontowindow.Apps[] before window.onload fires. The boot loop in script.js reads this array, creates an icon div for each entry, and optionally adds a taskbar button.
gridX/gridY is supplied, findNextFreeCell() picks the first unoccupied cell automatically. See Desktop for the full grid reference.
Keyboard shortcut
| Shortcut | Action |
|---|---|
Ctrl + X | Closes the topmost window (highest z-index among all .window-wrapper elements) |
Explore the subsystems
Windows
Draggable, minimizable, maximizable windows built around the 7.css title-bar structure and blob-iframe sandboxing.
Desktop
The 80 px icon grid,
window.Apps[] descriptor format, and icon rendering rules.Taskbar
The fixed 48 px quick-launch bar and how apps opt in with
taskbar: true.Drag & Drop
Drop a
.js app file directly onto the desktop to sideload it at runtime via dragjs.js.