New to Kendo UI for jQueryStart a free 30-day trial

The array of gradient color stops.

<div id="diagram"></div>
<script>
$("#diagram").kendoDiagram({
    shapeDefaults: {
        fill: {
            gradient: {
                type: "linear",
                start: [0, 0],
                end: [1, 0],
                stops: [
                    { offset: 0, color: "#ff0000", opacity: 0.8 },
                    { offset: 0.5, color: "#00ff00", opacity: 0.9 },
                    { offset: 1, color: "#0000ff", opacity: 1 }
                ]
            }
        }
    },
    shapes: [{
        id: "1",
        content: { text: "Multi-stop Gradient" },
        x: 100,
        y: 20
    }]
});
</script>

The color in any of the following formats:

| Format | Description | --- | --- | --- | red | Basic or Extended CSS Color name | #ff0000 | Hex RGB value | rgb(255, 0, 0) | RGB value

Specifying 'none', 'transparent', or '' (empty string) clears the fill.

<div id="diagram"></div>
<script>
$("#diagram").kendoDiagram({
    shapeDefaults: {
        fill: {
            gradient: {
                type: "linear",
                start: [0, 0],
                end: [1, 0],
                stops: [
                    { offset: 0, color: "red" },
                    { offset: 0.5, color: "#00ff00" },
                    { offset: 1, color: "rgb(0, 0, 255)" }
                ]
            }
        }
    },
    shapes: [{
        id: "1",
        content: { text: "Color Formats" },
        x: 100,
        y: 20
    }]
});
</script>

The stop offset from the start of the element. Ranges from 0 (start of gradient) to 1 (end of gradient).

<div id="diagram"></div>
<script>
$("#diagram").kendoDiagram({
    shapeDefaults: {
        fill: {
            gradient: {
                type: "linear",
                start: [0, 0],
                end: [1, 0],
                stops: [
                    { offset: 0, color: "#ff6600" },
                    { offset: 0.3, color: "#ffcc00" },
                    { offset: 1, color: "#cc0000" }
                ]
            }
        }
    },
    shapes: [{
        id: "1",
        content: { text: "Custom Offsets" },
        x: 100,
        y: 20
    }]
});
</script>

The fill opacity. Ranges from 0 (completely transparent) to 1 (opaque).

<div id="diagram"></div>
<script>
$("#diagram").kendoDiagram({
    shapeDefaults: {
        fill: {
            gradient: {
                type: "linear",
                start: [0, 0],
                end: [1, 0],
                stops: [
                    { offset: 0, color: "#ff0000", opacity: 1 },
                    { offset: 0.5, color: "#ff0000", opacity: 0.5 },
                    { offset: 1, color: "#ff0000", opacity: 0.1 }
                ]
            }
        }
    },
    shapes: [{
        id: "1",
        content: { text: "Opacity Gradient" },
        x: 100,
        y: 20
    }]
});
</script>