(function (H) {
// override dash style to provide a custom dashes
H.wrap(
H.SVGElement.prototype,
'dashstyleSetter',
function (proceed, value) {
if (value === 'EgmGrid') {
this.element
.setAttribute(
'stroke-dasharray', '0, 3, 1, 3, 1, 3, 1, 3, 1, 4'
);
} else {
proceed.apply(this, [].slice.call(arguments, 1));
}
});
H.Axis.prototype.getMinorTickPositions = function() {
const axis = this, options = axis.options, tickPositions = axis.tickPositions, minorTickInterval = axis.minorTickInterval, pointRangePadding = axis.pointRangePadding || 0, min = (axis.min || 0) - pointRangePadding, // #1498
max = (axis.max || 0) + pointRangePadding, // #1498
// --- Workaround - take correct range for broken axis
range = axis.brokenAxis ? axis.brokenAxis.unitLength : max - min;
// ---
let minorTickPositions = [], pos;
// If minor ticks get too dense, they are hard to read, and may cause
// long running script. So we don't draw them.
if (range && range / minorTickInterval < axis.len / 3) { // #3875
const logarithmic = axis.logarithmic;
if (logarithmic) {
// For each interval in the major ticks, compute the minor ticks
// separately.
this.paddedTicks.forEach(function (_pos, i, paddedTicks) {
if (i) {
minorTickPositions.push.apply(minorTickPositions, logarithmic.getLogTickPositions(minorTickInterval, paddedTicks[i - 1], paddedTicks[i], true));
}
});
}
else if (axis.dateTime &&
...
Please Whitelist JSFiddle in your content blocker.
Help keep JSFiddle free for always by one of two ways:
Whitelist JSFiddle in your content blocker (two clicks)
Go PRO and get access to additional PRO features →
Join the 4+ million users, and keep the JSFiddle dream alive.
Ad-free
All ads in the editor and listing pages are turned completely off.
Use pre-released features
You get to try and use features (like the Palette Color Generator) months before everyone else.
Fiddle collections
Sort and categorize your Fiddles into multiple collections.
Private collections and fiddles
You can make as many Private Fiddles, and Private Collections as you wish!
Console
Debug your Fiddle with a minimal built-in JavaScript console.