Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/37.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 R-减少列中元素之间的间距_Css_R_Shiny - Fatal编程技术网

Css R-减少列中元素之间的间距

Css R-减少列中元素之间的间距,css,r,shiny,Css,R,Shiny,我有以下可复制代码: library(shiny) ui <- fluidPage( fluidRow( column(3, align="left", # Input: Quantile ---- selectInput(inputId = "TEST", label = "",choices = c(80, 85, 90,

我有以下可复制代码:

library(shiny)

ui <- fluidPage(
  fluidRow(
    column(3, align="left",
           # Input: Quantile ----
           selectInput(inputId = "TEST",
                       label = "",choices = c(80, 85, 90, 95),selected = 90),
    ),
    
    column(9,
           tabsetPanel(
             tabPanel("Table 1"),
             tabPanel("Figures 1"),
             tabPanel("Figures 2"),
             tabPanel("Figures 3",
                      fluidRow(
                        fluidRow(
                          column(width = 3,
                                 wellPanel(
                                   tags$head(tags$style(type="text/css", "#loadmessage {
                                                                          position: fixed;
                                                                          top: 0px;
                                                                          left: 500px;
                                                                          width: 60%;
                                                                          padding: 5px 0px 5px 0px;
                                                                          text-align: center;
                                                                          font-weight: bold;
                                                                          font-size: 100%;
                                                                          color: #000000;
                                                                          background-color: #DAF7A6;
                                                                          z-index: 105;
                                                                           }")),
                                   conditionalPanel(condition="$('html').hasClass('shiny-busy')",
                                                    tags$div("Chargement...",id="loadmessage")),
                                   selectInput(inputId="CartesFig",
                                               label="",
                                               choices= c("1.Carac", "2.Rangs", "3.Comparaison")),
                                   selectInput(inputId="TypeVisu",
                                               label="",
                                               choices= c("Séparation", "Tout")),
                                   actionButton("GraphCartes", "Go !",
                                                style="color: #fff; background-color: #337ab7; border-color: #2e6da4")
                                 )),
                          column(1,
                                 conditionalPanel(
                                   condition = ("input.CartesFig == '3.Comparaison'"),
                                   selectInput(inputId = "Nb_Compa", label = "Nombre", choices = c(1,2,3), selected = 1),
                                 )),
                          column(2, 
                                 conditionalPanel(
                                   condition = ("input.CartesFig == '3.Comparaison'"),
                                   wellPanel(
                                     conditionalPanel(condition = "(input.CartesFig == '3.Comparaison') && (input.Nb_Compa == 1 || input.Nb_Compa == 2 || input.Nb_Compa == 3)",
                                                      selectInput(inputId = "Comparatif1", label = "", choices = "placeholder1")),
                                     conditionalPanel(condition = "(input.CartesFig == '3.Comparaison') && (input.Nb_Compa == 2 || input.Nb_Compa == 3)",
                                                      selectInput(inputId = "Comparatif2", label = "", choices = "placeholder1")),
                                     conditionalPanel(condition = "(input.CartesFig == '3.Comparaison') && (input.Nb_Compa == 3)",
                                                      selectInput(inputId = "Comparatif3", label = "", choices = "placeholder1")))
                                 )),
                          column(3, align="center",
                                 actionButton("DownloadCartes", "Télécharger la figure",style="Gradient"))),
                        tags$style(type='text/css', "#DownloadCartes { width:60%; margin-top: 40px;}"),
                        mainPanel(plotOutput("CartesPlot", height="700px", width="1300px")))
             ) ##Tab Panel Fig 3
           ) ##tabSetPanel
    ) ##Column
  ) ## FluidRow
) # fluidPage

server <- function(input, output, session) {
  Input_Nb_compa <- reactive({input$Nb_Compa})
  
  observeEvent(input$Nb_Compa,{
    if(Input_Nb_compa()==1) {updateSelectInput(session, "Comparatif1", choices =(1:1500), selected = 1226)}
    if(Input_Nb_compa()==2) {
      updateSelectInput(session, "Comparatif1", choices = (1:1500), selected = 1226)
      updateSelectInput(session, "Comparatif2", choices = (1:1500), selected = 789)}
    if(Input_Nb_compa()==3) {
      updateSelectInput(session, "Comparatif1", choices = (1:1500), selected = 1226)
      updateSelectInput(session, "Comparatif2", choices = (1:1500), selected = 789)
      updateSelectInput(session, "Comparatif3", choices = (1:1500), selected = 20)}
  })
  
  output$CartesPlot <- renderPlot({NULL})
}

shinyApp(ui, server)
库(闪亮)

ui在您的情况下,
label=NULL
应该删除标签的额外空间

                           conditionalPanel(condition="$('html').hasClass('shiny-busy')",
                                            tags$div("Chargement...",id="loadmessage")),
                           selectInput(inputId="CartesFig",
                                       label="",
                                       choices= c("1.Carac", "2.Rangs", "3.Comparaison")),
                           selectInput(inputId="TypeVisu",
                                       label=NULL,
                                       choices= c("Séparation", "Tout")),
                           actionButton("GraphCartes", "Go !",
                                        style="color: #fff; background-color: #337ab7; border-color: #2e6da4")
                         )),
                  column(1,
                         conditionalPanel(
                           condition = ("input.CartesFig == '3.Comparaison'"),
                           selectInput(inputId = "Nb_Compa", label = "Nombre", choices = c(1,2,3), selected = 1),
                         )),
                  column(2,
                         conditionalPanel(
                           condition = ("input.CartesFig == '3.Comparaison'"),
                           wellPanel(
                             conditionalPanel(condition = "(input.CartesFig == '3.Comparaison') && (input.Nb_Compa == 1 || input.Nb_Compa == 2 || input.Nb_Compa == 3)",
                                              selectInput(inputId = "Comparatif1", label = NULL, choices = "placeholder1")),
                             conditionalPanel(condition = "(input.CartesFig == '3.Comparaison') && (input.Nb_Compa == 2 || input.Nb_Compa == 3)",
                                              selectInput(inputId = "Comparatif2", label = NULL, choices = "placeholder1")),
                             conditionalPanel(condition = "(input.CartesFig == '3.Comparaison') && (input.Nb_Compa == 3)",
                                              selectInput(inputId = "Comparatif3", label = NULL, choices = "placeholder1")))
                         ))