MCPcopy Index your code
hub / github.com/nextapps-de/winbox

github.com/nextapps-de/winbox @0.2.82 sqlite

repository ↗ · DeepWiki ↗ · release 0.2.82 ↗
28 symbols 65 edges 9 files 6 documented · 21%
README

WinBox.js: A modern HTML5 window manager for the web.

Modern window manager for the web: lightweight, outstanding performance, no dependencies, fully customizable, open source!

Demo  •  Getting Started  •  Options  •  API  •  Themes  •  Customize  •  Changelog

Live Demo and Code Examples

https://nextapps-de.github.io/winbox/

Support this Project

Hello my name is Thomas, also known as ts-thomas. This is a personal project which I fully made in my free time. It is hosted by the Github account from the company Nextapps where I work to give it more exposure. I have never received any financial support for this project from the company Nextapps as some of you might have guessed, since it is a free and open source project. I'm really happy that WinBox.js is getting so much positive feedback and also feature requests. Please feel free to support me by making a personal donation which helps me a lot to keep this project alive and also to providing all the contribution to keep WinBox.js on a professional top-end level.

Donate using Open Collective Donate using Github Sponsors Donate using Liberapay Donate using Patreon Donate using Bountysource Donate using PayPal

Thanks a lot, Thomas (ts-thomas)

Plugins / Add-ons / Extensions

Vue 2 and 3 (a wrapper component that adds the ability to mount Vue components in WinBox.js):

https://github.com/wobsoriano/vue-winbox

A React controlled component for WinBox.js, with full Reactful props and state.:

https://github.com/rickonono3/react-winbox

Getting Started

Get Latest Stable Build (Recommended):

Bundle: (all assets bundled into one single file: js + css + html + icons)
winbox.bundle.min.js Download https://rawcdn.githack.com/nextapps-de/winbox/0.2.82/dist/winbox.bundle.min.js
Non-Bundled: (js and css are separated, css includes icons as base64)
winbox.min.js Download https://rawcdn.githack.com/nextapps-de/winbox/0.2.82/dist/js/winbox.min.js
winbox.min.css Download https://rawcdn.githack.com/nextapps-de/winbox/0.2.82/dist/css/winbox.min.css
Sources: (not bundled at all, images as url to original resources)
ES6 Modules Download The /src/js folder of this Github repository
LESS Files (source) Download The /src/css folder of this Github repository
winbox.css (compiled) Download https://rawcdn.githack.com/nextapps-de/winbox/0.2.82/src/css/winbox.css
src.zip Download Download all source files including image original resources.

Get Latest (NPM):

npm install winbox

Use Bundled Version (Recommended)

The bundled version includes all assets like js, css, html and icon images as base64.

A best practice is to load the library as async and use some modern preloading mechanism:

<html>
<head>
    <link rel="preload" href="https://github.com/nextapps-de/winbox/raw/0.2.82/winbox.bundle.min.js" as="script">
</head>
<body>


    <script src="https://github.com/nextapps-de/winbox/raw/0.2.82/winbox.bundle.min.js" async></script>

    <script src="https://github.com/nextapps-de/winbox/raw/0.2.82/my-script.js" defer></script>
</body>
</html>

When you get troubles with unavailable references then remove the async or defer from this example and invest some minutes later to find out how you can properly load js assets asynchronously today.

Use Non-Bundled Version

The non-bundled version needs to load js and css separately (css already includes icons as base64).

<html>
<head>
    <link rel="stylesheet" href="https://github.com/nextapps-de/winbox/raw/0.2.82/winbox.min.css">
    <script src="https://github.com/nextapps-de/winbox/raw/0.2.82/winbox.min.js"></script>
</head>
<body></body>
</html>

You can also load the non-bundled version in the same way.

ES6 Modules

The ES6 modules are located in src/js/. But you need to load the stylesheet file explicitly since this is just automatically loaded by the bundled version.

<head>
    <link rel="stylesheet" href="https://github.com/nextapps-de/winbox/raw/0.2.82/dist/css/winbox.min.css">
</head>
<script type="module">
  import WinBox from "./src/js/winbox.js";
</script>

You can also load modules via CDN, e.g.:

<script type="module">
  import WinBox from "https://unpkg.com/winbox@0.2.82/src/js/winbox.js";
</script>

The ES6 modules are not minified. Please use your favored bundler or build tool for this purpose.

Overview

Constructor:

Global methods:

Instance member methods:

Instance properties (readonly):

Instance properties (writable):

Instance state boolean properties (readonly):

Callback methods:

Options

Option Values Description
id number | string Set a unique id to the window. Used to define custom styles in css, query elements by context or just to identify the corresponding window instance. If no ID was set it will automatically create one for you.
index number Set the initial z-index of the window to this value (will be increased automatically when unfocused/focused).
title string The window title.
mount HTMLElement Mount an element (widget, template, etc.) to the window body.
html string Set the innerHTML of the window body.
url string Open URL inside the window (loaded via iframe).
width height number | string Set the initial width/height of the window (supports units "px" and "%").
minwidth minheight number | string Set the minimal width/height of the window (supports u

Core symbols most depended-on inside this repo

parse
called by 16
src/js/winbox.js
addListener
called by 15
src/js/helper.js
setStyle
called by 14
src/js/helper.js
getByClass
called by 11
src/js/helper.js
addWindowListener
called by 9
src/js/winbox.js
preventEvent
called by 7
src/js/helper.js
remove_min_stack
called by 4
src/js/winbox.js
cancel_fullscreen
called by 4
src/js/winbox.js

Shape

Function 28

Languages

TypeScript100%

Modules by API surface

src/js/winbox.js15 symbols
src/js/helper.js11 symbols
task/clean.js1 symbols
task/build.js1 symbols

Dependencies from manifests, versioned

base64-img1.0.4 · 1×
cpx1.5.0 · 1×
csso5.0.4 · 1×
csso-cli4.0.1 · 1×
google-closure-compiler20220719.0.0 · 1×
less4.1.3 · 1×
less-plugin-autoprefix2.0.0 · 1×
less-plugin-clean-css1.5.1 · 1×
svgo2.8.0 · 1×
web-servo0.5.1 · 1×

For agents

$ claude mcp add winbox \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact