Skip to content

Commit

Permalink
🐛 change dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
ecoisilva committed Jun 20, 2024
1 parent a688a97 commit 0db4da1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 16 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Imports:
shinyWidgets,
stats,
stringr,
sysfonts,
gdtools,
terra,
tidyr,
utils,
Expand Down
28 changes: 13 additions & 15 deletions R/mod_tab_about.R
Original file line number Diff line number Diff line change
Expand Up @@ -286,21 +286,19 @@ mod_tab_about_server <- function(id, rv) {

# MAIN REACTIVE VALUES ------------------------------------------------

# observe({
#
# font_available <- tryCatch({
# sysfonts::font_add_google(name = "Roboto Condensed",
# family = "Roboto Condensed")
# }, error = function(e) {
# warning("Font failed.")
# })
#
# rv$is_font <- TRUE
# if (inherits(font_available, "error")) {
# rv$is_font <- FALSE
# }
#
# }) # end of observe
observe({

font_available <- tryCatch({
gdtools::register_gfont(family = "Roboto Condensed")
})

if (inherits(font_available, "error")) {
rv$is_font <- FALSE
} else {
rv$is_font <- TRUE
}

}) # end of observe

observe({
rv$which_data <- input$which_data
Expand Down

0 comments on commit 0db4da1

Please sign in to comment.