feat: Add and rename screens

- Add windows screen
- Add windows.js
- Different variants of classes for drag and edge snap behaviour
- Rename js files to better distinguish usage
This commit is contained in:
sthag 2025-10-27 21:33:38 +01:00
parent 3c9c438b25
commit e0cfcfac13
8 changed files with 351 additions and 2 deletions

View file

@ -0,0 +1,30 @@
---
title: Windows
tags:
- ui
---
{% assign bodyClass = "body_frame" -%}
{% layout "hippie/app.liquid" %}
{% block body %}
<nav id="task-bar">
<button data-action="start">Start</button>
</nav>
<div id="screen-space"></div>
<div id="placeholder"></div>
{% endblock %}
{%- block script %}
<script src="{{ pageBase }}js/windows.js"></script>
<script>
// Get the space element
const space = document.getElementById('screen-space');
const start = document.querySelector('[data-action=start]');
const draggableElement = document.getElementById('task-bar');
const placeholderElement = document.getElementById('placeholder');
// const draggable = new Draggable(draggableElement);
const dragMore = new DragAdv(draggableElement, placeholderElement);
// const dragBest = new BestDrag(draggableElement, placeholderElement);
</script>
{% endblock %}