-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
feat(tooltip, popover): overall code refactor for better reactivity and performance (fixes: #1990, #2937, #3480, #3717, #3854, closes #3451) #3908
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov Report
@@ Coverage Diff @@
## dev #3908 +/- ##
=========================================
+ Coverage 99.33% 99.84% +0.5%
=========================================
Files 234 236 +2
Lines 4526 4462 -64
Branches 1275 1250 -25
=========================================
- Hits 4496 4455 -41
+ Misses 24 6 -18
+ Partials 6 1 -5
Continue to review full report at Codecov.
|
|
Added in ability for scoped styles to target root element of tooltips/popovers. Targetting inner elements of the tooltip/popover will require the use of the vue-loader |
|
Now uses |
|
Tweaked some of the docs formatting |
Describe the PR
Complete refactor of tooltip and popover code to be more "Vue" like (less direct DOM manipulations, and no longer a direct port of Bootstrap v4.3 code), more modular, and more reactive.
Clears up many issues with tooltips and popovers
Notable improvements:
variantandcustom-classare reactive and can be changed while tooltip is opencustom-classcan now be a scoped style, but note that one still needs the vue-loader/deep/selector to target the inner elements of the tooltip or popover.titleattribute changes and config option changes while the tooltip or popover is open50ms (delays are applicable forhoverandfocusonly), which will help reduce "spastic" tooltips/popovers.triggersto'manual'which allows only programmatic showing/hiding of tooltips and popovers'hover'(or'focus'), one can now move the mouse over (or move focus to) the tooltip/popover and it will remain open$rootevents can use this ID to open/close/enable/disable the tooltip/popover. Use of the trigger element's ID works as well.Note:
<transition>component. Previously tooltips and popovers could not take advantage of Vue's<transition>component. The use of the<transition>component has greatly reduced the lines of code required, at the expense of a few new lines of custom SCSS.Fixes #1990
Fixes #2937
Fixes #3480
Fixes #3717
Fixes #3854
Closes #3451
Closes #2261
TODO:
b-tooltipto use new instancesb-popoverto use new instancesv-b-tooltipto use new instancesv-b-popoverto use new instancesPR checklist
What kind of change does this PR introduce? (check at least one)
Does this PR introduce a breaking change? (check one)
The PR fulfills these requirements:
devbranch, not themasterbranch[...] (fixes #xxx[,#xxx]), where "xxx" is the issue number)fix(alert): not alerting during SSR render,docs(badge): update pill examples, fix typos,chore: fix typo in README, etc). This is very important, as theCHANGELOGis generated from these messages.If new features/enhancement/fixes are added or changed:
package.jsonfor slot and event changes)If adding a new feature, or changing the functionality of an existing feature, the PR's
description above includes: