New to Kendo UI for jQuery? Start a free 30-day trial

The crosshair configuration options.

<div id="sparkline"></div>
<script>
$("#sparkline").kendoSparkline({
    categoryAxis: {
        crosshair: {
            visible: true,
            color: "red",
            width: 2,
            opacity: 0.8,
            dashType: "dash"
        },
        categories: ["Q1", "Q2", "Q3", "Q4"]
    },
    series: [{
        data: [10, 15, 8, 12]
    }]
});
</script>

The color of the crosshair.

<div id="sparkline"></div>
<script>
$("#sparkline").kendoSparkline({
    categoryAxis: {
        crosshair: {
            visible: true,
            color: "blue"
        },
        categories: ["Q1", "Q2", "Q3", "Q4"]
    },
    series: [{
        data: [10, 15, 8, 12]
    }]
});
</script>

The dash type of the crosshair.

<div id="sparkline"></div>
<script>
$("#sparkline").kendoSparkline({
    categoryAxis: {
        crosshair: {
            visible: true,
            dashType: "dot"
        },
        categories: ["Q1", "Q2", "Q3", "Q4"]
    },
    series: [{
        data: [10, 15, 8, 12]
    }]
});
</script>

The opacity of the crosshair.

<div id="sparkline"></div>
<script>
$("#sparkline").kendoSparkline({
    categoryAxis: {
        crosshair: {
            visible: true,
            opacity: 0.5
        },
        categories: ["Q1", "Q2", "Q3", "Q4"]
    },
    series: [{
        data: [10, 15, 8, 12]
    }]
});
</script>

The crosshair tooltip configuration options.

<div id="sparkline"></div>
<script>
$("#sparkline").kendoSparkline({
    categoryAxis: {
        crosshair: {
            visible: true,
            tooltip: {
                visible: true,
                background: "lightblue",
                color: "darkblue"
            }
        },
        categories: ["Q1", "Q2", "Q3", "Q4"]
    },
    series: [{
        data: [10, 15, 8, 12]
    }]
});
</script>

The dash type of the crosshair.

Default: false

<div id="sparkline"></div>
<script>
$("#sparkline").kendoSparkline({
    categoryAxis: {
        crosshair: {
            visible: true
        },
        categories: ["Q1", "Q2", "Q3", "Q4"]
    },
    series: [{
        data: [10, 15, 8, 12]
    }]
});
</script>

The width of the crosshair.

<div id="sparkline"></div>
<script>
$("#sparkline").kendoSparkline({
    categoryAxis: {
        crosshair: {
            visible: true,
            width: 3
        },
        categories: ["Q1", "Q2", "Q3", "Q4"]
    },
    series: [{
        data: [10, 15, 8, 12]
    }]
});
</script>