Open vishnutk opened 1 year ago
Tooltip (popover) on dynamically added html elements are not getting cleared from the ElementMap after removing that html. If we reinsert the html content, elementMap is getting created with new entries and old element entries never gets removed.
Template Toggle
Template Dynamic Button 1
Everytime the new entry gets added in the ElementMap.
Reason: elementMap.has is checking by reference but we are getting new element.
const Data = { set(element, key, instance) { if (!elementMap.has(element)) { elementMap.set(element, new Map()); } const instanceMap = elementMap.get(element);
macOS
Chrome, Firefox
v5.2.3
Please provide a PR with a test case.
Prerequisites
Describe the issue
Tooltip (popover) on dynamically added html elements are not getting cleared from the ElementMap after removing that html. If we reinsert the html content, elementMap is getting created with new entries and old element entries never gets removed.
Reduced test cases
Template Toggle
buttonTemplate Dynamic Button 1
Template Toggle
button to remove htmlTemplate Dynamic Button 1
Everytime the new entry gets added in the ElementMap.
Reason: elementMap.has is checking by reference but we are getting new element.
What operating system(s) are you seeing the problem on?
macOS
What browser(s) are you seeing the problem on?
Chrome, Firefox
What version of Bootstrap are you using?
v5.2.3