File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change 3131# '
3232# ' @section Decorating `tm_data_table`:
3333# '
34- # ' This module creates below objects that can be modified with decorators:
34+ # ' This module generates the following objects, which can be modified in place using decorators:
3535# ' - `table` (`DT::datatable`)
3636# '
3737# ' For additional details and examples of decorators, refer to the vignette
@@ -187,6 +187,9 @@ ui_page_data_table <- function(id,
187187 )
188188 )
189189 ),
190+ forms = tagList(
191+ teal.widgets :: verbatim_popup_ui(ns(" rcode" ), " Show R code" )
192+ ),
190193 pre_output = pre_output ,
191194 post_output = post_output
192195 )
@@ -374,5 +377,12 @@ srv_data_table <- function(id,
374377 # no table is displayed
375378 decorated_data_table_data()[[" table" ]]
376379 })
380+
381+ teal.widgets :: verbatim_popup_srv(
382+ id = " rcode" ,
383+ verbatim_content = reactive(teal.code :: get_code(req(decorated_data_table_data()))),
384+ title = " R Code for PCA"
385+ )
386+
377387 })
378388}
You can’t perform that action at this time.
0 commit comments