LightningWeb.Live.Helpers.ProjectTheme (Lightning v2.15.0-pre5)
View SourceRuntime theme utilities. Builds a full primary scale (50..950) from a base hex
and returns inline CSS variable overrides for Tailwind v4's --color-primary-*.
Summary
Functions
If the project is a sandbox with a color, returns a string of CSS custom
properties that override the full --color-primary-* scale.
Returns nil for non-sandboxes or missing color.
Returns the sidebar variables that your CSS reads (--primary-*), pointing at the
primary scale. Safe to append anywhere you put inline_primary_scale/1.
Functions
@spec inline_primary_scale(Lightning.Projects.Project.t() | nil) :: String.t() | nil
If the project is a sandbox with a color, returns a string of CSS custom
properties that override the full --color-primary-* scale.
Returns nil for non-sandboxes or missing color.
@spec inline_sidebar_vars() :: String.t()
Returns the sidebar variables that your CSS reads (--primary-*), pointing at the
primary scale. Safe to append anywhere you put inline_primary_scale/1.