shiny icon indicating copy to clipboard operation
shiny copied to clipboard

numericInput step parameter is not incrementing properly when run via in window or in viewer

Open iamericfletcher opened this issue 4 years ago • 2 comments
trafficstars

System details

Browser Version:

  • Google Chrome Version 89.0.4389.90 (Official Build) (arm64)

Output of sessionInfo():

R version 4.0.3 (2020-10-10)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Big Sur 10.16

Matrix products: default
LAPACK: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRlapack.dylib

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

other attached packages:
[1] ggplot2_3.3.3 shiny_1.6.0  

loaded via a namespace (and not attached):
 [1] tidyselect_1.1.0  xfun_0.22         bslib_0.2.4       purrr_0.3.4       colorspace_2.0-0  sourcetools_0.1.7 vctrs_0.3.6      
 [8] generics_0.1.0    htmltools_0.5.1.1 yaml_2.2.1        utf8_1.2.1        rlang_0.4.10      jquerylib_0.1.3   later_1.1.0.1    
[15] pillar_1.5.1      glue_1.4.2        withr_2.4.1       DBI_1.1.1         lifecycle_1.0.0   munsell_0.5.0     gtable_0.3.0     
[22] evaluate_0.14     knitr_1.31        callr_3.5.1       fastmap_1.1.0     httpuv_1.5.5      ps_1.6.0          fansi_0.4.2      
[29] highr_0.8         Rcpp_1.0.6        clipr_0.7.1       xtable_1.8-4      promises_1.2.0.1  scales_1.1.1      cachem_1.0.4     
[36] jsonlite_1.7.2    mime_0.10         fs_1.5.0          digest_0.6.27     processx_3.4.5    dplyr_1.0.5       grid_4.0.3       
[43] cli_2.3.1         tools_4.0.3       magrittr_2.0.1    sass_0.3.1        tibble_3.1.0      crayon_1.4.1      pkgconfig_2.0.3  
[50] ellipsis_0.3.1    reprex_1.0.0      assertthat_0.2.1  rmarkdown_2.7     rstudioapi_0.13   R6_2.5.0          compiler_4.0.3   
> 

Output of RStudio.Version():

$mode
[1] "desktop"

$version
[1] ‘1.4.1103’

$release_name
[1] "Wax Begonia"

Example application or steps to reproduce the problem

library(shiny)

ui <- fluidPage(
    numericInput("num", "Number one", value = 0, min = 0, max = 10, width = 100,  step = 1)
)

server <- function(input, output){
    
}

shinyApp(ui, server)

Describe the problem in detail

When the code above is run:

  1. Via Run in Window: run_in_window

  2. Via Run in Viewer Pane: run_in_viewer

step = 1 is incrementing incorrectly.

When the code above is run:

  1. Via run_external: run_external

step = 1 is incrementing correctly.

This issue is not unique to step = 1. For example, when step = 4, the increment is 8 in Run in Window and Run in Viewer Pane while incrementing correctly when using Run External.

Expected output

I expected the step to increment correctly in all views when step = 1 or step = 4, etc.

Sincerely,

Eric Fletcher

iamericfletcher avatar Mar 20 '21 03:03 iamericfletcher

If this is something worth addressing, I would love to take a stab at it after discussing.

iamericfletcher avatar Mar 20 '21 03:03 iamericfletcher

FYI - This is still happening in R Studio, but works fine in Chrome (run locally).

nealhaddaway avatar Apr 14 '22 08:04 nealhaddaway