diff --git a/R/run_app.R b/R/run_app.R index c40388fc3..9bc6068e0 100644 --- a/R/run_app.R +++ b/R/run_app.R @@ -50,10 +50,12 @@ #' run_app(settings = "/path/to/settings.yaml", settings_version = "NCA draft") #' } #' @export + +max_upload_size_mb <- 30 run_app <- function(datapath = NULL, settings = NULL, settings_version = 1L, ...) { # Increase max upload size to 30 MB - options(shiny.maxRequestSize = 30 * 1024^2) + options(shiny.maxRequestSize = max_upload_size_mb * 1024^2) if (!is.null(datapath)) { stopifnot( "Data file does not exist" = file.exists(datapath), diff --git a/inst/shiny/modules/tab_data/data_upload.R b/inst/shiny/modules/tab_data/data_upload.R index a10a0a69d..fe4bfd28d 100644 --- a/inst/shiny/modules/tab_data/data_upload.R +++ b/inst/shiny/modules/tab_data/data_upload.R @@ -15,7 +15,10 @@ data_upload_ui <- function(id) { div( class = "upload-container", id = ns("upload_container"), - p("Upload your PK dataset and Settings file (optional)."), + p("Upload your PK dataset and Settings file (optional).", + tags$br(), + tags$small(style = "color: #6c757d; display: block; margin-top: 4px;", + sprintf("Maximum upload size: %s MB", max_upload_size_mb))), fileInput( ns("data_upload"), width = "50%",