Solve Warning: The elevation provided <Paper elevation={24}> is not available in the theme.
2021/10/14 23:16:16
本文主要是介绍Solve Warning: The elevation provided <Paper elevation={24}> is not available in the theme.,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!
If you got the following warning:
The elevation provided <Paper elevation={24}> is not available in the theme. Please make sure that `theme.shadows[24]` is defined
In order to mitigate this, you can change your shadows to a dictionary instead of array, for example:
const theme = createMuiTheme({ shadows: { 24: '0px 11px 15px -7px red,0px 24px 38px 3px red,0px 9px 46px 8px red', }, });
Or you can initialize shadows[24] with current existing item, for example:
const theme = createMuiTheme({ shadows: [ '0px 11px 15px -7px red,0px 24px 38px 3px red,0px 9px 46px 8px red', ], }); theme.shadows[24] = theme.shadows[0];
Refereces:
https://github.com/mui-org/material-ui/issues/8289
这篇关于Solve Warning: The elevation provided <Paper elevation={24}> is not available in the theme.的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!
- 2024-11-20实战:30 行代码做一个网页端的 AI 聊天助手
- 2024-11-185分钟搞懂大模型的重复惩罚后处理
- 2024-11-18基于Ollama和pgai的个人知识助手项目:用Postgres和向量扩展打造智能数据库
- 2024-11-15我用同一个提示测试了4款AI工具,看看谁设计的界面更棒
- 2024-11-15深度学习面试的时候,如何回答1x1卷积的作用
- 2024-11-15检索增强生成即服务:开发者的得力新帮手
- 2024-11-15技术与传统:人工智能时代的最后一袭纱丽
- 2024-11-15未结构化数据不仅仅是给嵌入用的:利用隐藏结构提升检索性能
- 2024-11-15Emotion项目实战:新手入门教程
- 2024-11-157 个开源库助你构建增强检索生成(RAG)、代理和 AI 搜索