Skip to main content

Function: vignette()

vignette(options?: object): (target: HTMLElement | ReactiveElementBase | Background | DOMElement) => void

Decorates an element or background with a radial dark vignette.

Parameters​

ParameterTypeDescription
options{ color?: string; opacity?: number; shape?: string; }-
options.color?stringVignette color (default: "#09090b").
options.opacity?numberCenter darkness opacity from 0 to 1 (default: 1).
options.shape?stringCustom radial gradient falloff shape (default: "ellipse 55% 55% at 50% 50%").

Returns​

(target: HTMLElement | ReactiveElementBase | Background | DOMElement) => void