Skip to content

Commit

Permalink
Add an ability to override colors
Browse files Browse the repository at this point in the history
  • Loading branch information
khasinski committed Sep 24, 2023
1 parent 04137a4 commit d0b7a24
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 @@ -46,7 +46,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 @@ -57,7 +57,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 d0b7a24

Please sign in to comment.