shinydashboard icon indicating copy to clipboard operation
shinydashboard copied to clipboard

Popover text when hovering over menuItems

Open NemanjaV opened this issue 6 years ago • 1 comments

Hello, I would like to add the popover text when hovering over certain menuItems from sidebarMenu. I've tried using addTooltip form shinyBS but the problem is that menuItem element doesn't have ID. Is there any other solution for this use case?

NemanjaV avatar Dec 20 '18 13:12 NemanjaV

Although it's probably too late, I wanna share this solution for the problem.

Basically you have to set the IDs yourself.

  add_id_js <- paste0(
    "$('#test').find('.btn-group-vertical > .btn-group-toggle').attr('id', function(i) {",
    "return 'test_row_' + i})    ")
  session$onFlushed(function() { 
  runjs(add_id_js)
  }, once = FALSE)

hdbt avatar May 13 '21 10:05 hdbt