mirror of
https://gitee.com/dapppp/ruoyi-plus-vben5.git
synced 2026-04-09 13:03:14 +08:00
fix(antd): 禁用模态框和抽屉背景模糊效果
由于当前 mask blur 配置不生效,显式设置 modal 和 drawer 的 mask blur 为 false
This commit is contained in:
@@ -1,4 +1,6 @@
|
|||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
|
import type { ConfigProviderProps } from 'antdv-next';
|
||||||
|
|
||||||
import { computed } from 'vue';
|
import { computed } from 'vue';
|
||||||
|
|
||||||
import { useAntdDesignTokens } from '@vben/hooks';
|
import { useAntdDesignTokens } from '@vben/hooks';
|
||||||
@@ -38,10 +40,25 @@ const waveConfig = computed(() => {
|
|||||||
const found = waveConfigs.find((item) => item.name === buttonWaveMode);
|
const found = waveConfigs.find((item) => item.name === buttonWaveMode);
|
||||||
return found ? found.wave : {};
|
return found ? found.wave : {};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const otherProps = computed<
|
||||||
|
Omit<ConfigProviderProps, 'locale' | 'theme' | 'wave'>
|
||||||
|
>(() => {
|
||||||
|
// 目前不生效?
|
||||||
|
return {
|
||||||
|
modal: { mask: { blur: false } },
|
||||||
|
drawer: { mask: { blur: false } },
|
||||||
|
};
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<ConfigProvider :locale="antdLocale" :theme="tokenTheme" :wave="waveConfig">
|
<ConfigProvider
|
||||||
|
:locale="antdLocale"
|
||||||
|
:theme="tokenTheme"
|
||||||
|
:wave="waveConfig"
|
||||||
|
v-bind="otherProps"
|
||||||
|
>
|
||||||
<App>
|
<App>
|
||||||
<RouterView />
|
<RouterView />
|
||||||
<PopupContext />
|
<PopupContext />
|
||||||
|
|||||||
Reference in New Issue
Block a user