RinteRface / fullPage

📄 fullPage.js, pagePiling.js and multiScroll.js for shiny
https://fullpage.rinterface.com
Other
111 stars 12 forks source link

Cant reproduce callbacks examples #11

Closed jbkunst closed 3 years ago

jbkunst commented 3 years ago

Hi Rinterface team :)!

I can't reproduce callbacks examples. Consider this app.

library(shiny)
library(fullPage)

ui <- fullPage(
  center = TRUE,
  fullSection(menu = "a", h1("a")),
  fullSection(menu = "b", h1("b")),
  fullSection(menu = "c", h1("c"))
)

server <- function(input, output, session){

  observeEvent(input$fp_origin,      { message(1); print(input$fp_origin) })

  observeEvent(input$fp_destination, { message(2); print(input$fp_destination) })

  observeEvent(input$fp_direction,   { message(3); print(input$fp_direction) })

  observeEvent(input$slide_origin,   { message(4); print(input$slide_origin) })

  observeEvent(input$slide_destination, { message(5); print(input$slide_destination)})

  observeEvent(input$slide_direction,   { message(6); print(input$slide_direction) })

}

shinyApp(ui, server)

In the console only I get:

Listening on http://127.0.0.1:5882
1
[1] "a"
2
[1] 1

Session information:

``` > sessioninfo::session_info() - Session info --------------------------------------------------------------------------------- setting value version R version 3.6.3 (2020-02-29) os Windows 10 x64 system x86_64, mingw32 ui RStudio language (EN) collate Spanish_Mexico.1252 ctype Spanish_Mexico.1252 tz America/Santiago date 2021-08-25 - Packages ------------------------------------------------------------------------------------- package * version date lib source bslib 0.2.5.1 2021-05-18 [1] CRAN (R 3.6.3) cachem 1.0.5 2021-05-15 [1] CRAN (R 3.6.3) cli 3.0.1 2021-07-17 [1] standard (@3.0.1) digest 0.6.27 2020-10-24 [1] CRAN (R 3.6.3) ellipsis 0.3.2 2021-04-29 [1] CRAN (R 3.6.3) fastmap 1.1.0 2021-01-25 [1] CRAN (R 3.6.3) fullPage * 0.1.0 2021-06-08 [1] Github (RinteRface/fullPage@9e918af) htmltools 0.5.1.1 2021-01-22 [1] CRAN (R 3.6.3) httpuv 1.6.1 2021-05-07 [1] CRAN (R 3.6.3) jquerylib 0.1.4 2021-04-26 [1] CRAN (R 3.6.3) jsonlite 1.7.2 2020-12-09 [1] CRAN (R 3.6.3) later 1.2.0 2021-04-23 [1] CRAN (R 3.6.3) lifecycle 1.0.0 2021-02-15 [1] CRAN (R 3.6.3) magrittr 2.0.1 2020-11-17 [1] CRAN (R 3.6.3) mime 0.11 2021-06-23 [1] standard (@0.11) promises 1.2.0.1 2021-02-11 [1] CRAN (R 3.6.3) R6 2.5.0 2020-10-28 [1] CRAN (R 3.6.3) Rcpp 1.0.7 2021-07-07 [1] standard (@1.0.7) rlang 0.4.11 2021-04-30 [1] CRAN (R 3.6.3) rsconnect 0.8.18 2021-05-24 [1] CRAN (R 3.6.3) sass 0.4.0 2021-05-12 [1] CRAN (R 3.6.3) sessioninfo 1.1.1 2018-11-05 [1] CRAN (R 3.6.3) shiny * 1.6.0 2021-01-25 [1] CRAN (R 3.6.3) withr 2.4.2 2021-04-18 [1] CRAN (R 3.6.3) xtable 1.8-4 2019-04-21 [1] CRAN (R 3.6.3) [1] C:/Users/Joshua/Documents/R/win-library/3.6 [2] C:/Program Files/R/R-3.6.3/library ```
JohnCoene commented 3 years ago

Sorry for the late reply, I was away last week.

I just pushed a fix, feel free to reopen if it does not work.

jbkunst commented 3 years ago

No problem!

Thanks so much. The fix worked for me