Change the popover target dynamically
See original GitHub issueI am trying to change the target of the popover dynamically, like, I have 5 targets in the template and I want to display the popover where ever I click, for that, I want to change the target onClick. Seems my target value is changing onClick but that doesn’t affect and no popover showing the new target. My sample codes as below, am I missing something? or it’s known issue.
data () {
return {
targetZone: 'exPopover3'
}
},
methods: {
changeTarget(zone) {
this.targetZone = zone;
}
}
template:
<b-btn id="exPopover2" variant="primary" @click="changeTarget('exPopover2')">Using properties</b-btn>
<b-popover :target="targetZone"
title="Prop Examples"
triggers="hover focus"
content="Embedding content using properties is easy">
</b-popover>
Issue Analytics
- State:
- Created 6 years ago
- Reactions:6
- Comments:5 (3 by maintainers)
Top Results From Across the Web
How can I set b-popover target dynamically in vue js?
Now my problem is, I can't set target dynamically. I want to set the popover target, where user has clicked. I have tried...
Read more >Popover - Dynamic target - DevExpress Support
You can set the Popover's target property to a non-static property value. In the click event, you can change this value dynamically.
Read more >Mde Popover Dynamic Target Position - StackBlitz
A material design popover component created using Angular version 4 with the Angular CDK.
Read more >[Solved]-How can I set b-popover target dynamically in vue js?
Coding example for the question How can I set b-popover target dynamically in vue js?-Vue.js.
Read more >JavaScript - Bootstrap
DEFAULTS.keyboard = false // changes default for the modal plugin's ... In practice, this is used to enable dynamic HTML content to have...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi. This should not be closed, the unability to retarget a popover to different targets one after the other is a huge perfomance issue. My example here
adding one different popover item for each avatar generate a very heavy and slow display.
Currently I played over by adding only one popover by row and just update the content, but the row’s popover remain centered on the whole row’s list of avatar… This is not a correct UI UX experience.
This issue is still relevant. There are many cases where a dynamic target can be helpful or needed. I found stack overflow questions about this, none of them had correct answers and the number of views on each of them tells a lot about how much this feature is needed. This Stackoverflow question has over 3K views!! please consider re-opening this issue