Merge branch 'main' of https://github.com/vbenjs/vue-vben-admin
This commit is contained in:
@@ -1,8 +1,6 @@
|
||||
import type { Watermark, WatermarkOptions } from 'watermark-js-plus';
|
||||
|
||||
import { nextTick, onUnmounted, ref, watch } from 'vue';
|
||||
|
||||
import { preferences } from '@vben/preferences';
|
||||
import { nextTick, onUnmounted, ref } from 'vue';
|
||||
|
||||
const watermark = ref<Watermark>();
|
||||
const cachedOptions = ref<Partial<WatermarkOptions>>({
|
||||
@@ -67,15 +65,6 @@ export function useWatermark() {
|
||||
watermark.value?.destroy();
|
||||
}
|
||||
|
||||
watch(
|
||||
() => preferences.app.watermark,
|
||||
(enable) => {
|
||||
if (!enable) {
|
||||
destroyWatermark();
|
||||
}
|
||||
},
|
||||
);
|
||||
|
||||
onUnmounted(() => {
|
||||
destroyWatermark();
|
||||
});
|
||||
|
Reference in New Issue
Block a user