Issue Description: Simply setting filters = T within datagrid() does not add a filter icon and filter features to boolean columns by default. Filters must be explicitly added to boolean columns using grid_filters().
The simple reprex app and the screenshot taken from it below illustrate the problematic behavior and how filters must currently be added to boolean columns.
if (interactive()) {
library(shiny)
library(toastui)
ui <- fluidPage(column(
6,
tags$h2(
"datagrid(..., filters = T) does not add filters to boolean columns by default"
),
datagridOutput("grid1")
),
column(
6,
tags$h2("one must add filters to boolean columns explicitly using grid_filters()"),
datagridOutput("grid2")
))
server <- function(input, output, session) {
df <- data.frame(
index = 1:12,
month = month.name,
letters = letters[1:12],
bool = c(rep(T, 6), rep(F, 6))
)
output$grid1 <- renderDatagrid({
datagrid(df, filters = T)
})
output$grid2 <- renderDatagrid({
datagrid(df, filters = T) %>%
grid_filters(columns = "bool", type = "select")
})
}
shinyApp(ui, server)
}
Desired Resolution: Setting filters = T within datagrid() should properly add a filter icon and filter functionality to boolean columns as well.
Issue Description: Simply setting
filters = T
withindatagrid()
does not add a filter icon and filter features to boolean columns by default. Filters must be explicitly added to boolean columns usinggrid_filters()
.The simple reprex app and the screenshot taken from it below illustrate the problematic behavior and how filters must currently be added to boolean columns.
Desired Resolution: Setting
filters = T
withindatagrid()
should properly add a filter icon and filter functionality to boolean columns as well.