我使用来自 shinyWidget 的 pickerInput
div(class = "choosechannel",
pickerInput(inputId = "choosechannel", label = "business channel", width = "150px",
choices = c("In-Branch", "Agency", "Affinity", "Corporate", "Credit Life"),
multiple = TRUE, selected = c("In-Branch", "Agency", "Affinity", "Corporate", "Credit Life"),
options = list(height = 10)))
我想更改 pickerInput 的高度这是我尝试使用的代码:
tags$style(".choosechannel-button {height: 26.5px; min-height: 26.5px; padding: 0px;}")
tags$head( tags$style( HTML("#choosechannel-button {font-size: 13px; height: 26.5px; min-height: 26.5px;}")))
tags$style(".choosechannel-container {height: 26.5px; min-height: 26.5px; padding: 0px;}")
tags$head( tags$style( HTML("#choosechannel-container {font-size: 13px; height: 26.5px; min-height: 26.5px;}")))
它们都不起作用。有谁知道该怎么做?
.choosechannel .btn {height: 26.5px; font-size: 13px;}
编辑:正如 Wilmar van Ommeren 在他的回答中所建议的那样,我在 tags$style 中尝试过。它几乎可以工作。它下面仍然有空白区域。
它看起来像这样: