javascript - 如何在 vue js 中设置 v-calender 的样式?
问题描述
我很难设置日历样式。我正在使用 vcalender vue 插件。我想更改日历的背景,但我的代码不起作用。这是我的代码。任何人都可以帮忙吗?非常感谢
HTML
<v-calendar :theme-styles='themeStyles'>
</v-calendar>
</div>
JS
<script src="node_modules/vue/dist/vue.js"></script>
<script src='https://unpkg.com/v-calendar'></script>
<script>
var vm = new Vue({
el:'#app',
data :{
working:'working',
themeStyles: {
wrapper: {
background: 'linear-gradient(to bottom right, #ff5050, #ff66b3)',
color: '#fafafa',
border: '0',
borderRadius: '5px',
boxShadow: '0 4px 8px 0 rgba(0, 0, 0, 0.14), 0 6px 20px 0 rgba(0, 0, 0, 0.13)'
}
}
}
});
</script>
解决方案
'themeStyles' 似乎从来没有工作过。您可以通过覆盖其 css 来设置日历样式。它不在任何 iframe 中。
.vc-container {
width: 100%;
border-color: transparent;
background-color: transparent;
}
.vc-pane-container {
background-color: '#ebebeb';
}
.vc-title {
font-size: 16px;
color: white;
font-family: "GTWalsheimPro Medium", serif;
}
推荐阅读
- ios - iOS - 调度队列:NSOperationQueue 崩溃
- c# - 更改自动生成的 WCF 客户端的 XmlReaderSettings
- python-3.x - 从使用 GIS 库(如 geopandas、folium)的 Python 脚本制作 .exe
- vb.net - 保留我使用 vb.net 在 datagridview 的框中选中的值
- angular - 如何仅在请求时间超过 n 时显示加载栏
- c++ - 为什么我的 boost::filesystem::ofstream 不能与 std::ios_base::out 一起使用?
- apache-flink - 为可查询状态找到合适的任务管理器主机地址
- javascript - Polymer 2.0 纸张输入文件自定义样式
- python - 转移数据并创建新列 - python数据框
- javascript - 使用节点 js 每秒加载一次查询