Imgix APIsRendering APIFillFill Gradient Linear

Fill Gradient Linear

fill-gradient-linear

Sets the linear gradient color when fill-gradient-type=linear is used in conjunction with fit=fill&fill=gradient.

Accepts 2 to 16 comma-separated colors, expressed as either a color keyword or a 3- (RGB), 6- (RRGGBB) or 8-digit (AARRGGBB) hexadecimal color value (fill-gradient-linear=color1,color2,…). The colors are spaced evenly by default; use fill-gradient-stops to place them yourself.

A list with fewer than 2 colors, more than 16 colors, or a single unparseable color is ignored in its entirety, and the image palette default below is used instead. A 17-color list is rejected rather than truncated to 16.

When fill-gradient-linear is not specified, we will use the color palette of the image and default to vibrant dark for color1 and vibrant light for color2.