Skip to content

Commit

Permalink
spelling fixes and docs enhancements
Browse files Browse the repository at this point in the history
  • Loading branch information
kpagacz committed Jun 17, 2022
1 parent 0f9ade8 commit edbb8de
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 8 deletions.
10 changes: 7 additions & 3 deletions R/verbatim_popup.R
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
#' A `shiny` module that pops up verbatim text
#' A `shiny` module that pops up verbatim text.
#' @name verbatim_popup
#' @description `r lifecycle::badge("experimental")`
#' This module consists of a button that once clicked pops up a
#' modal window with verbatim-styled text.
#'
#' @param id (`character(1)`) the `shiny` id
#' @param button_label (`charater(1)`) the text printed on the button
#' @param button_label (`character(1)`) the text printed on the button
#' @param ... additional arguments to `[shiny::actionButton()]`
#'
#' @return the UI function returns a `shiny.tag.list` object
Expand All @@ -20,6 +20,7 @@
#'
verbatim_popup_ui <- function(id, button_label, ...) {
checkmate::assert_string(id)
checkmate::assert_string(button_label)
ns <- shiny::NS(id)
shiny::tagList(
shiny::tags$head(shiny::singleton(
Expand Down Expand Up @@ -64,7 +65,7 @@ verbatim_popup_srv <- function(id, verbatim_content, title, disabled = shiny::re
})
}

#' Creates a `shiny` observer handling the disabled flag
#' Creates a `shiny` observer handling the disabled flag.
#'
#' @details
#' When the flag is `TRUE` the button to open the popup is disabled; it is enabled otherwise.
Expand All @@ -87,6 +88,9 @@ disabled_flag_observer <- function(disabled_flag, button_id) {

#' Creates a `shiny` observer handling button clicks.
#'
#' @description
#' When the button is clicked it pop up a modal window with the text.
#'
#' @keywords internal
#' @param click_event `reactive` the click event
#' @param copy_button_id (`character(1)`) the id of the button to copy the modal content
Expand Down
2 changes: 1 addition & 1 deletion man/button_click_observer.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions man/disabled_flag_observer.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions man/verbatim_popup.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit edbb8de

Please sign in to comment.