PluginProbe
OpenStation: Desktop Windows, Dock & Virtual Desktops for WP Admin / 1.1.13
OpenStation: Desktop Windows, Dock & Virtual Desktops for WP Admin v1.1.13
1.1.13 1.1.12 1.1.11 1.1.10 1.1.9 1.1.8 1.1.7 1.1.6 1.1.5 1.1.4 1.1.3 1.1.2 1.1.1 1.1.0 1.0.1 1.0.0 0.9.8 0.9.7 0.9.6 0.9.4 0.9.5 0.9.3 0.9.2 0.9.1 0.9.0 All 37 releases
desktop-mode / assets / css / effects.css

effects.css in OpenStation: Desktop Windows, Dock & Virtual Desktops for WP Admin 1.1.13, at assets/css/effects.css

82 lines 3.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 /**
2 * OpenStation — Window effects.
3 *
4 * Visual treatments applied to windows by the unfocus-effect engine
5 * (`src/effects/unfocus-engine.ts`). The engine toggles a per-effect
6 * class on the window root (`.os-window`) while the window
7 * is NOT focused; each effect ships the matching rule here (or, for
8 * plugin effects, in the plugin's own stylesheet).
9 *
10 * The fade is driven by the `filter` entry in the shared
11 * `.os-window` transition (see `window-chrome.css`), so
12 * effects that animate via `filter` get a smooth two-way transition as
13 * focus moves between windows — and collapse to instant under
14 * `prefers-reduced-motion` along with every other window transition.
15 *
16 * Registered as its own `os-effects` style handle, chained
17 * by dependency between `os-settings` and
18 * `os-window-links` so its position in the cascade matches
19 * where it sat when these sheets were `@import`ed. Enqueuing
20 * `os-windows` still pulls it in via that chain.
21 *
22 * @since 0.26.0
23 */
24
25 /*
26 * Built-in effect tuning knobs. Every shipped effect is driven by
27 * custom properties so a theme or plugin can re-tune the intensity
28 * without overriding the whole rule. Their defaults live in the `var()`
29 * fallbacks at each use site rather than in a declaration on
30 * `.os-window`: a declaration on the window would outrank anything
31 * the window inherits, and a theme declares them on the body.
32 *
33 * --os-fx-transition-duration 0.5s how long an effect ramps in and
34 * out as focus moves (the filter
35 * entry of the window transition)
36 * --os-fx-darken-brightness 0.82 darken: dim
37 * --os-fx-darken-saturate 0.92 darken: slight desaturate
38 * --os-fx-frost-blur 3px frost: blur
39 * --os-fx-frost-saturate 0.7 frost: cool
40 * --os-fx-frost-brightness 1.08 frost: lift
41 * --os-fx-grayscale-amount 1 grayscale: drain colour
42 * --os-fx-grayscale-brightness 0.95 grayscale: settle brightness
43 */
44
45 /*
46 * `darken` — dims unfocused windows (title bar and body alike) so the
47 * focused window reads as the active surface.
48 */
49 .os-window--fx-darken {
50 filter:
51 brightness( var( --os-fx-darken-brightness, 0.82 ) )
52 saturate( var( --os-fx-darken-saturate, 0.92 ) );
53 }
54
55 /*
56 * `frost` — throws the window literally out of focus. Blur is the
57 * universal "not in focus" cue; lifting the brightness and pulling the
58 * saturation down turns it into a pane of cold, frosted glass between
59 * the user and the content. `filter: blur()` rasterizes the whole
60 * window subtree — iframe content included — so the frosting is total,
61 * not just chrome-deep.
62 */
63 .os-window--fx-frost {
64 filter:
65 blur( var( --os-fx-frost-blur, 3px ) )
66 saturate( var( --os-fx-frost-saturate, 0.7 ) )
67 brightness( var( --os-fx-frost-brightness, 1.08 ) );
68 }
69
70 /*
71 * `grayscale` — drains the colour from unfocused windows so the focused
72 * one is the only thing still in colour. The eye is drawn to colour, so
73 * this makes the active window pop without dimming anything into the
74 * dark. A touch of brightness settling keeps the mono windows from
75 * glaring.
76 */
77 .os-window--fx-grayscale {
78 filter:
79 grayscale( var( --os-fx-grayscale-amount, 1 ) )
80 brightness( var( --os-fx-grayscale-brightness, 0.95 ) );
81 }
82