Skip to content

Commit

Permalink
Improved scrollbar defaults and styled mode.
Browse files Browse the repository at this point in the history
  • Loading branch information
kamil-musialowski authored and TorsteinHonsi committed May 3, 2023
1 parent 5a4c45f commit 1146308
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 7 deletions.
2 changes: 1 addition & 1 deletion css/highcharts.css
Original file line number Diff line number Diff line change
Expand Up @@ -829,7 +829,7 @@ circle.highcharts-legend-nav-inactive { /* tracker */
}

.highcharts-scrollbar-track {
fill: none;
fill: rgba(255, 255, 255, 0.001);
stroke: var(--highcharts-neutral-color-20);
stroke-width: 1px;
}
Expand Down
6 changes: 1 addition & 5 deletions ts/Stock/Scrollbar/Scrollbar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -666,7 +666,6 @@ class Scrollbar {
const scroller = this,
renderer = scroller.renderer,
options = scroller.options,
chartOptions = scroller.chart.options,
size = scroller.size,
styledMode = scroller.chart.styledMode,
group = renderer.g('scrollbar')
Expand All @@ -690,10 +689,7 @@ class Scrollbar {

if (!styledMode) {
scroller.track.attr({
// #18922 Transparent track doesn't catch click events
fill: options.trackBackgroundColor === 'none' ?
chartOptions.chart.backgroundColor :
options.trackBackgroundColor,
fill: options.trackBackgroundColor,
stroke: options.trackBorderColor,
'stroke-width': options.trackBorderWidth
});
Expand Down
2 changes: 1 addition & 1 deletion ts/Stock/Scrollbar/ScrollbarDefaults.ts
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ const ScrollbarDefaults: ScrollbarOptions = {
*
* @type {Highcharts.ColorString|Highcharts.GradientColorObject|Highcharts.PatternObject}
*/
trackBackgroundColor: 'none',
trackBackgroundColor: 'rgba(255, 255, 255, 0.001)', // #18922

/**
* The color of the border of the scrollbar track.
Expand Down

0 comments on commit 1146308

Please sign in to comment.