question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

v5: Error - Bootstrap doesn't allow more than one instance per element.

See original GitHub issue

I have this error:

Bootstrap doesn’t allow more than one instance per element. Bound instance: bs.tooltip.

using this code:

<button class="btn btn-dark" type="button" data-bs-toggle="dropdown" data-bs-auto-close="true" data-bs-toggle-2="tooltip" data-bs-placement="bottom" title="Lorem Ipsum" aria-expanded="false">

It looks like you can’t have dropdowns and tooltips together, but it should be possible.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (2 by maintainers)

github_iconTop GitHub Comments

6reactions
ffooddcommented, May 11, 2021

No, from an accessibility perspective it should not exist so we don’t support it.

To elaborate:

  • when using a keyboard to navigate, where does clicking and tabbing would lead to? Tooltip, or dropdown? Cannot be both, obviously.
  • someone using a screenreader wouldn’t know what has been expanded. BTW which one of tooltip ans dropdown would update the aria-expanded attribute?

AFAIK that’s not something we’ll consider.

5reactions
NimaFxcommented, Sep 5, 2021

It’s possible to trigger tooltips on the focus, shortcut key or add an extra icon just for tooltips. I’m aware of that. but still, your assumption is false! It’s a focus, long tap, or click. But not all!

It’s a dropdown that has a tooltip too! How should I handle on the touch screen or keyboard is a framework independent decision.

<select name="cars" id="cars" title="Cars">
  <option value="volvo">Volvo</option>
  <option value="saab">Saab</option>
</select>

From the user’s perspective, What they see on the desktop.
b

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bootstrap doesn't allow more than one instance per element
I have this error: Bootstrap doesn't allow more than one instance per element. Bound instance: bs.tooltip. using this code: <button class="btn ...
Read more >
Bootstrap doesn't allow more than one instance per element ...
I'm developing a WooCommerce plugin, then I encounter this error. But in some themes it's working. However I'm a bit worried because it ......
Read more >
Using Alerts: &#38;quot;Bootstrap doesn&#38;#039
The message shows, but also the javascript error: "Bootstrap doesn't allow more than one instance per element. Bound instance: bs.alert.".
Read more >
Tooltips · Bootstrap v5.0
When triggered from hyperlinks that span multiple lines, tooltips will be centered. ... Tooltips can be triggered thanks to an element inside a...
Read more >
Migrating to v5 - Bootstrap
Use the .bg-gradient class to add gradients to elements instead of the ... box-shadow mixins now allow null values and drop none from...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found