Skip to content

Commit 0c56b7a

Browse files
authored
Merge pull request #46 from maurice2k/maurice2k-patch-issue-45
🐛 Fixes updating of tooltip (as action) on data changes
2 parents 9ad91ad + bc37551 commit 0c56b7a

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/action.js

+7-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export const tooltip = (element, props) => {
1212
}
1313
};
1414

15-
const config = {
15+
let config = {
1616
...props,
1717
targetElement: element
1818
};
@@ -101,6 +101,12 @@ export const tooltip = (element, props) => {
101101
if (title) {
102102
element.setAttribute('title', title);
103103
}
104+
},
105+
update(updatedProps) {
106+
Object.assign(config, updatedProps);
107+
if (component) {
108+
component.$set(config);
109+
}
104110
}
105111
};
106112
};

0 commit comments

Comments
 (0)