1
0
mirror of https://github.com/msberends/AMR.git synced 2025-07-13 00:32:34 +02:00

reftbl in plots, speedup for as.sir() and mo_validate

This commit is contained in:
2023-07-10 16:43:46 +02:00
parent 70c601ca11
commit a4e2e25e3f
14 changed files with 128 additions and 65 deletions

6
R/mo.R
View File

@ -628,6 +628,12 @@ pillar_shaft.mo <- function(x, ...) {
)
}
# add the names to the bugs as mouse-over!
if (tryCatch(isTRUE(getExportedValue("ansi_has_hyperlink_support", ns = asNamespace("cli"))()), error = function(e) FALSE)) {
out[!x %in% c("UNKNOWN", NA)] <- font_url(url = mo_name(x[!x %in% c("UNKNOWN", NA)], language = NULL, keep_synonyms = TRUE),
txt = out[!x %in% c("UNKNOWN", NA)])
}
# make it always fit exactly
max_char <- max(nchar(x))
if (is.na(max_char)) {