0

我是闪亮的新手,并尝试lineplots在每个下添加infobox,如下图所示。但问题是我无法向该行添加更多项目(信息框 + 线图)

在此处输入图像描述

代码:

 
    fluidRow(
        
    
        column(2, selectInput(inputId = "id_country_timeline", label = "Select Country (applies on this page)", 
                              choices = unique(ts_all_long$Country.Region), selected = "India")),
        
        column(1, 
               infoBoxOutput("daily_confrm", width = NULL),
               plotOutput("ConfirmDaily_line_only", height = "40px", width = 80)),
        column(1,
               infoBoxOutput("daily_death", width = NULL),
               plotOutput("DeathDaily_line_only", height = "40px", width = 80)),
        column(1,
               infoBoxOutput("tot_confrm", width = NULL),
               plotOutput("Confirm_line_only", height = "40px", width = 80)),
        column(1,
               infoBoxOutput("tot_death", width = NULL),
               plotOutput("Death_line_only", height = "40px", width = 80))
        ,
        # column(1,
        #        infoBoxOutput("tot_death", width = NULL),
        #        plotOutput("Death_line_only", height = "40px", width = 80))
        # ,
        # column(2,
        #        infoBoxOutput("per_vaccinated", width = NULL),
        #        plotOutput("Death_line_only", height = "40px", width = 80)
        #        ),
        # div(style = "height:80px;")
        
    ),

当我取消注释甚至包含的下一列infobox & plotoutput时,整个页面都会变为空白。我猜流体行可以有 12 个项目列,我没有充分利用,但是可以向行中添加多少项目有限制吗?

当我将列大小从 1 增加到 2 时,它们确实分布在整个行上。

在此处输入图像描述

我不知道为什么我无法向其中添加更多此类项目。

4

1 回答 1

0

遇到问题是因为我id多次使用相同的。如果ids使用过一次或者它们是独一无二的,那么它们似乎工作得很好。

于 2021-04-11T14:20:15.447 回答