Skip to content

Commit

Permalink
fix colour palette length effectively harcoded
Browse files Browse the repository at this point in the history
  • Loading branch information
giocomai committed Jan 21, 2024
1 parent 6f7a438 commit 4809f25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/ganttrify.R
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ ganttrify <- function(project,
axis_text_align = "right") {

# repeat colours if not enough colours given
if (length(unique(project$wp))>length(as.character(wesanderson::wes_palette("Darjeeling1")))) {
if (length(unique(project$wp))>length(as.character(colour_palette))) {
colour_palette <- rep(colour_palette, length(unique(project$wp)))[1:length(unique(project$wp))]
}

Expand Down

0 comments on commit 4809f25

Please sign in to comment.