Skip to content
This repository has been archived by the owner on Sep 30, 2023. It is now read-only.

Commit

Permalink
Add an ability to override colors
Browse files Browse the repository at this point in the history
  • Loading branch information
khasinski committed Jun 13, 2022
1 parent 3fc71e9 commit 5b4126a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/helpers/blazer/base_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def blazer_format_annotations(annotations)
xScaleID: "x-axis-0",
xMin: annotation[:min_date],
xMax: annotation[:max_date],
backgroundColor: blazer_map_annotation_box_colors(index),
backgroundColor: annotation[:color] || blazer_map_annotation_box_colors(index),
}
end

Expand All @@ -61,7 +61,7 @@ def blazer_format_annotations(annotations)
value: annotation[:min_date],
mode: "vertical",
scaleID: "x-axis-0",
borderColor: '#00000050',
borderColor: annotation[:color] || '#00000050',
drawTime: "afterDatasetsDraw",
label: {
content: annotation[:label],
Expand Down

0 comments on commit 5b4126a

Please sign in to comment.