From 1d22c2ed7691f0f930e991b68b524c243234776b Mon Sep 17 00:00:00 2001 From: Teun van den Brand Date: Thu, 23 Jan 2025 12:07:02 +0100 Subject: [PATCH] fallback for boolean `space_free` --- R/facet-.R | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/R/facet-.R b/R/facet-.R index b124b54872..20e61638a2 100644 --- a/R/facet-.R +++ b/R/facet-.R @@ -213,7 +213,8 @@ Facet <- ggproto("Facet", NULL, heights <- unit(rep(1 * abs(aspect_ratio %||% 1), dim[1]), "null") # When space are free, let panel parameter limits determine size of panel - space <- params$space_free %||% list(x = FALSE, y = FALSE) + space <- dual_param(params$space_free, default = list(x = FALSE, y = FALSE)) + if (space$x) { idx <- layout$PANEL[layout$ROW == 1] widths <- vapply(idx, function(i) diff(ranges[[i]]$x.range), numeric(1))