Skip to content

Commit 3d7201a

Browse files
authored
Merge pull request #1007 from basics/feature/fix-font-active-remove-by-update
fix(v-font): fix font active remove by update
2 parents c3364b3 + 7aa02b6 commit 3d7201a

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/runtime/directives/vFont.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ export default {
1818
const rootSelector = fontCollection.add(definitions);
1919
el.setAttribute(rootSelector.name, rootSelector.value);
2020
binding.instance.fontsReady.set(el, isCritical);
21-
vnode.fontActive = isCritical;
22-
2321
if (isCritical) {
2422
if (typeof vnode.props?.class === 'string') {
2523
vnode.props.class = [
@@ -98,7 +96,7 @@ async function activateFonts(el, binding, scope) {
9896
);
9997

10098
el.classList.add(CLASS_FONT_ACTIVE);
101-
binding.instance.fontActive = true;
99+
binding.instance.fontsReady.set(el, true);
102100

103101
emit(scope.props, 'onLoad:font', fonts);
104102
}

0 commit comments

Comments
 (0)