Description Usage Arguments Value Examples
Match the height of one element to the second element. If the height of second element change, the height of first element will change automatically
1 | heightMatcher(div1, div2, isID = TRUE)
|
div1 |
element ID, or jquery selector if |
div2 |
matched element ID or selector, the other element |
isID |
bool, if |
tagList containing javascript
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | if(interactive()){
library(shiny)
library(shinyjqui)
ui <- fluidPage(
column(
3, id = "a",
style = "border: 1px black solid; background-color: gray;",
p("This block's height is matched with orange one")
),
shinyjqui::jqui_resizable(column(
2, id ="b",
style = "border: 1px black solid; background-color: orange;",
p("drag the bottom-right corner")
)),
column(
3, id = "c",
style = "border: 1px black solid; background-color: red;",
p("This block's is not matched with others")
),
heightMatcher("a", "b")
)
server <- function(input, output, session) {
}
# Try to drag `b` from bottom right corner and see what happens to `a`
shinyApp(ui, server)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.