From ed808eeabd8d6b36612cc8ea4cf7d855a3a21498 Mon Sep 17 00:00:00 2001 From: Romain Francois Date: Mon, 26 Feb 2024 10:02:59 +0100 Subject: [PATCH] target = "_blank" --- R/auto.R | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/R/auto.R b/R/auto.R index 3fa861b..c606574 100644 --- a/R/auto.R +++ b/R/auto.R @@ -18,7 +18,7 @@ tip_pkg <- function(pkg, keep_braces = TRUE, text = get_title(url), ...) { url <- downlit::href_package(pkg) link_text <- if (keep_braces) "{{{pkg}}}" else "{pkg}" bslib::tooltip( - tags$a(glue::glue(link_text), href = url, class = "r-link-pkg"), + tags$a(glue::glue(link_text), href = url, target = "_blank", class = "r-link-pkg"), text, ... ) @@ -36,7 +36,7 @@ tip_call <- function(call, keep_pkg_prefix = TRUE, text = get_title(url), ...) { } bslib::tooltip( - tags$a(link_text, href = url, class = "r-link-call"), + tags$a(link_text, href = url, target = "_blank", class = "r-link-call"), text, ... )