shinydashboardPlus icon indicating copy to clipboard operation
shinydashboardPlus copied to clipboard

Accordions with anything other than accordionItem inside of them are broken

Open daattali opened this issue 4 years ago • 1 comments

Prior to f50d8c89e2789ef69384791663c880c470881247 the following code was fine:

shinydashboardPlus::accordion(div(id = "placeholder"))

(The usecase is that the accordion items were being added dynamically so it starts out empty with just a placeholder element)

Since that commit, accordions are broken.

Error in `*tmp*`[[1]] : subscript out of bounds

Looking at the code, it's because there are many assumptions being made about the internal structure of the object being passed to accordion().

I realize the documentation says that these parameters should be accordionItems() but I still wanted to bring this to your attention. Maybe there are others who also use accordions in a similar fashion and are also going to have errors when they update, and perhaps it's not too difficult to make it backwards compatible.

If you feel this doesn't need fixing, feel free to close the issue.

daattali avatar Feb 17 '20 06:02 daattali

Hi @daattali : I will be back on shinydashboardPlus soon (after shinyMobile 0.5.0 release). I see the point, it deserves better attention.

DivadNojnarg avatar Feb 29 '20 14:02 DivadNojnarg