Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix duplicate sliders #77

Merged
merged 3 commits into from
Feb 29, 2024
Merged

fix duplicate sliders #77

merged 3 commits into from
Feb 29, 2024

Conversation

yonicd
Copy link
Owner

@yonicd yonicd commented Dec 10, 2023

closes #70, #76

@yonicd yonicd linked an issue Dec 10, 2023 that may be closed by this pull request
@yonicd
Copy link
Owner Author

yonicd commented Dec 10, 2023

this does not create duplicate slides any longer in when rendering in shiny

library(shiny)
library(slickR)

ui <- fluidPage(

    mainPanel(
     
      slickROutput("slickr", width="100%"),
      
      actionButton("submit", "An action button")
      
    )

)

server <- function(input, output) {
  
 load_random_images <- function(x) {
    sample(slickR::nba_player_logo$uri,5)
 }

  
  output$slickr <- renderSlickR({
    input$submit

    slickR(load_random_images(), height = 400, width = "100%",
           padding = 0) + 
      settings(dots = TRUE, infinite = FALSE,
               slidesToShow =  1,
               centerMode =FALSE,
              adaptiveHeight = TRUE)   
  })
  
}

shinyApp(ui = ui, server = server)

@LaytonWashburn
Copy link

The main carousel is not duplicated anymore! It's now just the thumbnail being duplicated.

@yonicd
Copy link
Owner Author

yonicd commented Jan 30, 2024

Thanks for the feedback. Will circle back to this PR to check it out again

@yonicd
Copy link
Owner Author

yonicd commented Feb 27, 2024

@LaytonWashburn can you give an example of duplicate thumbnails? I cant seem to reproduce that behavior

@yonicd yonicd merged commit 1a46996 into master Feb 29, 2024
8 checks passed
@yonicd yonicd deleted the yonicd/issue76 branch February 29, 2024 13:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicated carousels in shiny SlickR and Shiny, duplicated carousels
2 participants