java - Vaadin Java:css文件的导入问题
问题描述
我正在编写 Vaadin 教程系列第 8 部分
视频:https ://www.youtube.com/watch?v=ttuBu8dYNn0
因此,我正在努力导入给定的 css 文件的最后一步。我所做的与所示教程中的完全相同,但表单样式没有改变。似乎css文件不起作用。
Vaadin 版本 14.4.2
我的项目文件夹包括。主视图:
CSS 文件:
/* List view */
.list-view .content {
display: flex;
}
.list-view .contact-grid {
flex: 2;
}
.list-view .contact-form {
flex: 1;
padding: var(--lumo-space-m);
}
@media all and (max-width: 1100px) {
.list-view.editing .toolbar,
.list-view.editing .contact-grid {
display: none;
}
}
我的网络应用程序
应该是这样的:
解决方案
在我添加了有关其他问题的以下依赖项后解决:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-validation</artifactId>
</dependency>
推荐阅读
- regex - 在 Google 表格单元格之间以“学习”方式转换文本?
- html - 显示:与 google chrome 相比,Firefox 浏览器中的块链接占用更多宽度
- c# - 使用 RestSharp 动态访问 JSON 属性
- python - Spread custom tick labels evenly over colorbar
- r - 计算 r 中二元变量的相关系数
- sql - SQL (lite) 值映射
- javascript - 一次性清理任务 firebase firestore
- javascript - Threejs ,导入的 .objs 被拉伸,它们没有保存它们的实际大小
- c# - 将 Mat 数组从 EmguCV 传递到 OpenCV?
- javascript - 突出显示画布元素中的特定像素