Skip to content

Commit a86e94d

Browse files
committed
use simple plot for tm_variable_browser
1 parent e32eec8 commit a86e94d

File tree

1 file changed

+1
-19
lines changed

1 file changed

+1
-19
lines changed

R/tm_variable_browser.R

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -491,26 +491,8 @@ srv_variable_browser <- function(id,
491491
})
492492

493493
reactive({
494-
# Version 1
495-
# since data() is not being build up in this module, we need to create a reactive that will
496-
# return the plot in the reactive teal_data()
497494
validation_checks()
498-
obj <- data()
499-
env <- new.env()
500-
assign("plot", variable_plot_r(), envir = env)
501-
obj@.xData <- rlang::env_clone(env)
502-
teal.reporter::teal_card(obj) <-
503-
c(
504-
teal.reporter::teal_card("# Variable Browser Plot"),
505-
teal.reporter::teal_card(obj),
506-
teal.reporter::teal_card("## Module's code")
507-
)
508-
teal.code::eval_code(obj, "plot")
509-
510-
511-
# VERSION 2
512-
# validation_checks()
513-
# teal.data::teal_data(plot = variable_plot_r()) |> teal.code::eval_code("plot")
495+
teal.data::teal_data(plot = variable_plot_r()) |> teal.code::eval_code("plot")
514496
})
515497
})
516498
}

0 commit comments

Comments
 (0)