mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-10-26 13:07:49 -04:00
- new blur variants, glow, wobble, motion blur and groupbar support - new inputs support for mouse, touchpad and keyboard settings - greeter, cheatsheet and scroll capture dispatch in Lua - scrolling workspace screenshot focus fix - fix scrolling screenshots from being cut-off on fractional-scale displays - workspaces are keyed by address on the beta branch and upcoming stable release where named workspaces have no id - bind flags, per-device binds, new window-rule keys and effects - outputs default to preferred/auto/auto and gate HDR/VRR on hardwareDetails - new dms setup/installer systemd session support on hyprland-session.target
26 lines
930 B
JavaScript
26 lines
930 B
JavaScript
import assert from "node:assert/strict";
|
|
import { readFileSync } from "node:fs";
|
|
import vm from "node:vm";
|
|
import test from "node:test";
|
|
|
|
const context = vm.createContext({});
|
|
vm.runInContext(readFileSync(new URL("../Common/WindowRuleMerge.js", import.meta.url), "utf8").replace(/^\.pragma.*$/m, ""), context);
|
|
const plain = value => JSON.parse(JSON.stringify(value));
|
|
|
|
test("an edit keeps fields the editor does not own and clears the ones it does", () => {
|
|
const stored = {
|
|
"idleinhibit": "focus",
|
|
"forcergbx": true,
|
|
"focusRingColor": "#ff0000",
|
|
"noGlow": true,
|
|
"opacity": 0.5
|
|
};
|
|
assert.deepEqual(plain(context.carry(stored, ["noGlow", "opacity", "monitor"])), {
|
|
"idleinhibit": "focus",
|
|
"forcergbx": true,
|
|
"focusRingColor": "#ff0000"
|
|
});
|
|
assert.equal(stored.noGlow, true);
|
|
assert.deepEqual(plain(context.carry(null, ["opacity"])), {});
|
|
});
|