mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-15 01:41:20 +08:00
26 lines
479 B
Vue
26 lines
479 B
Vue
<script setup lang="ts">
|
|
import { reactive, watch } from 'vue'
|
|
import { isDark } from '~/composables/dark'
|
|
|
|
const font = reactive({
|
|
color: 'rgba(0, 0, 0, .15)',
|
|
})
|
|
|
|
watch(
|
|
isDark,
|
|
() => {
|
|
font.color = isDark.value
|
|
? 'rgba(255, 255, 255, .15)'
|
|
: 'rgba(0, 0, 0, .15)'
|
|
},
|
|
{
|
|
immediate: true,
|
|
}
|
|
)
|
|
</script>
|
|
<template>
|
|
<el-watermark :font="font" :content="['Element+', 'Element Plus']">
|
|
<div style="height: 500px" />
|
|
</el-watermark>
|
|
</template>
|