Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/r/71.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Css 选择输入旁边的标签_Css_R_User Interface_Label_Shiny - Fatal编程技术网

Css 选择输入旁边的标签

Css 选择输入旁边的标签,css,r,user-interface,label,shiny,Css,R,User Interface,Label,Shiny,我有这样一个闪亮的应用程序: 服务器.R: library(shiny) function(input, output) { NULL } 和ui.R: library(shiny) pageWithSidebar( headerPanel("side-by-side"), fluidRow( column(2), column(4, wellPanel(

我有这样一个闪亮的应用程序:

服务器.R:

    library(shiny)

    function(input, output) { NULL }
和ui.R:

    library(shiny)  


    pageWithSidebar( 

       headerPanel("side-by-side"), 

     fluidRow(

        column(2),
        column(4,
           wellPanel(
               selectInput(inputId = "options", label = "some text", 
                           choices = list(a = 0, b = 1)))   
           )
      ),

      fluidRow( 
         h3("bla bla")
     )
    )
我想把selectInput标签放在它旁边,而不是上面。你知道怎么做吗

我发现:
但这对我不起作用。

有多种方法可以做到这一点,这里有一种:

library(shiny)

server <- shinyServer(function(input, output) { NULL })
ui <- shinyUI(
  pageWithSidebar( 

    headerPanel("side-by-side"), 

    sidebarPanel(
    fluidRow(
      tags$head(
        tags$style(type="text/css", "label.control-label, .selectize-control.single{ display: table-cell; text-align: center; vertical-align: middle; } .form-group { display: table-row;}")
      ),
      column(2),
      column(4,
               selectInput(inputId = "options", label = "some text", 
                           choices = list(a = 0, b = 1))
      )
    )),
    mainPanel(
    fluidRow( 
      h3("bla bla")
    ))
  )
)

shinyApp(ui=ui,server=server)
库(闪亮)
服务器