ProtectedconstructorMultiply lux intensity by a 0..1 factor. Sources scale in lockstep so the cap stays accurate.
JSON serialization shape for tests / debugging.
StaticapplyBand shift arithmetic delegates to the generic Quantity.shiftTag
machinery applied to the lux unit.
StaticbandMap a lux numeric value to a LightBand. Consults the live
Quantity tag-table registry — the lux thresholds live in
mud/config/quantity-tags.yaml and load at boot via
QuantityApi.loadTagTables. A thin typed adapter over
Quantity.tag() for the lux unit; reload of the YAML propagates
here transparently.
Throws if the lux table isn't registered (test setup gap) or if
the registered tags don't match LightBand (content-side bug —
the YAML tag list must equal the typed union by construction).
StaticcoerceCoerce a tag string, a Quantity<'K'>, or null into a
Quantity<'K'> | null. Used by Light.of and the mixin setters.
String input resolves through the registered KELVIN_TAGS table
(in api/light.ts), so author-friendly tags like 'warm' and
'cool' round-trip to their canonical Kelvin values.
StaticcompareBand compare arithmetic delegates to the generic
Quantity.compareTag machinery applied to the lux unit.
StaticfromCoerce a Light | LightDataShape into a Light. Utility for
callers holding an externally-sourced plain-object shape and
needing a Light instance. NOT part of the persistence path.
StaticofPublic construct-with-defaults helper. Accepts numeric lux or a
Quantity<'lux'> for intensity; tag-string, Quantity<'K'>, or
null for color temperature.
Optionalsource: LightSourceRef
The zero-light singleton.