w3d-theme

The one place the --w3d-* theme variables are read. Every SVG-UI module (widgets3d, keyboard, table, …) draws from this table instead of re-typing the variable names and fallback literals — three drifting copies of this block is exactly how a themed color ends up wrong in one widget only (caught by the 0.6.0 review).

Values are resolved ONCE, at module load, in JS — deliberately. These surfaces rasterize onto 3D textures via XMLSerializer, where a literal var(--w3d-text) in a serialized attribute resolves against nothing and paints black. Reading the computed value at load and baking the literal into the SVG is what makes the same markup render identically in the DOM and on a plane. The cost: the theme is not live-reactive to later JS changes — restyle before the bundle loads (tosijs's vars/StyleSheet at startup is fine).