<div class="item" th:each="event : ${events}"> <img class="ui avatar image" style="width: 45px;height: 45px" th:src="${event.data.headerUrl}" > <div class="content"> <div class="ui teal header" th:text="${event.data.nickname}" style="display: inline-block;">小圳</div> <span style="display: inline-block;">回复了你的评论</span> <div class="description" th:text="${event.data.content}">点点关注不迷路</div> <a href="#"><span>博客标题</span></a> </div> </div> 如何设置每个评论之间有一点点距离

时间: 2023-07-02 09:11:34 浏览: 39
您可以使用 CSS 中的 margin 或 padding 属性来为每个评论添加间距,例如: ``` .item { margin-bottom: 10px; /* 添加底部间距 */ } ``` 这将为每个评论底部添加 10px 的间距。您可以根据需要调整间距大小。
相关问题

<div class="ui segment"> <div class="ui relaxed divided list" style="height: 500px; overflow: scroll;"> <div class="item" th:each="event : ${events}"> <img class="ui avatar image" style="width: 45px;height: 45px" th:src="${event.data.headerUrl}" > <div class="content"> <a class="header" th:text="${event.data.nickname}">小圳</a> <span>回复了你的评论</span> <div class="description" th:text="${event.data.content}">点点关注不迷路</div> </div> </div> </div> </div> 如何使 小圳 和 回复了你的评论 在一行啊

可以将小圳和回复了你的评论的标签都放在同一个div中,加上 "inline" 或 "inline-block" 的样式,如下所示: ```html <div class="ui segment"> <div class="ui relaxed divided list" style="height: 500px; overflow: scroll;"> <div class="item" th:each="event : ${events}"> <img class="ui avatar image" style="width: 45px;height: 45px" th:src="${event.data.headerUrl}"> <div class="content"> <div> <a class="header" th:text="${event.data.nickname}" style="display: inline-block;">小圳</a> <span style="display: inline-block;">回复了你的评论</span> </div> <div class="description" th:text="${event.data.content}">点点关注不迷路</div> </div> </div> </div> </div> ``` 这里将小圳和回复了你的评论的标签都放在了一个div中,并将这个div的样式设置为 "display: inline-block;",这样它们就能在同一行显示了。

<div class="item" th:each="event : ${events}"> <img class="ui avatar image" style="width: 45px;height: 45px" th:src="${event.data.headerUrl}" > <div class="content"> <div class="ui teal header" th:text="${event.data.nickname}" style="display: inline-block;">小圳</div> <span style="display: inline-block;">回复了你的评论</span> <div class="description" th:text="${event.data.content}">点点关注不迷路</div> <a href="#"><span>博客标题</span></a> </div> </div> 如何在右侧加上时间和删除图标

您可以在 `content` 元素内部添加一个新的 `div` 元素,然后在该元素中添加时间和删除图标。例如: ``` <div class="content"> <div class="ui teal header" th:text="${event.data.nickname}" style="display: inline-block;">小圳</div> <span style="display: inline-block;">回复了你的评论</span> <div class="description" th:text="${event.data.content}">点点关注不迷路</div> <a href="#"><span>博客标题</span></a> <div class="extras" style="float: right;"> <span>2021-10-15 14:30</span> <i class="trash icon"></i> </div> </div> ``` 在上面的例子中,我们添加了一个名为 `extras` 的新的 `div` 元素,并将其设置为右浮动。在该元素内部,我们添加了一个时间标签和一个删除图标。您可以在 CSS 中进一步调整这些元素的样式和位置。

相关推荐

<!DOCTYPE html> <html> <head> <meta charset="UTF-8" /> <style> body { background-image: url('/src/selsectIndex/'); background-size: cover; } .blue-line { width: 100%; height: 30px; background-color: blue; } .images { display: flex; flex-wrap: nowrap; justify-content: center; } .image { width: 350px; height: 220px; margin: 20px; } .button1{ width: 360px; height: 230px; margin: 20px; } .spacer { height: 0px; /* 设置间隙的高度 / } .container { display: flex; flex-direction: column; justify-content: center; align-items: center; height: 100vh; / 设置容器高度为视口高度 */ } .image-container { position: relative; } .image-text { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 50px; color: #ffffff; text-align: rgba(13, 13, 13, 0.5) 0 5px 6px, rgba(0, 0, 0, 0.2) 1px 3px 3px; margin: 0; padding: 0; width: 100%; height: 100%; display: flex; justify-content: center; align-items: center; text-shadow: 2px 2px 0 #000, -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000; } .image-text2 { position: absolute; top: 70%; left: 50%; transform: translate(-50%, -50%); font-size: 40px; color: #ffffff; text-align: rgba(13, 13, 13, 0.5) 0 5px 6px, rgba(0, 0, 0, 0.2) 1px 3px 3px; margin: 0; padding: 0; width: 100%; height: 100%; display: flex; justify-content: center; align-items: center; text-shadow: 2px 2px 0 #000, -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000; } </style> </head> <body> 烘干窑系统 <script> function imageClick() { // Add your code here for what should happen when an image is clicked } </script> </body> </html> 帮我在这个html页面中右上角添加一个用户头像的图像

最新推荐

recommend-type

基于SpringBoot框架仿stackOverflow网站后台开发.zip

基于springboot的java毕业&课程设计
recommend-type

基于SpringBoot洗衣店管理系统.zip

基于springboot的java毕业&课程设计
recommend-type

【优化覆盖】算术算法求解传感器覆盖优化问题【含Matlab源码 2436期】.zip

【优化覆盖】算术算法求解传感器覆盖优化问题【含Matlab源码 2436期】.zip
recommend-type

【优化覆盖】蜣螂算法DBO求解无线传感器WSN覆盖优化问题【含Matlab源码 3567期】.zip

【优化覆盖】蜣螂算法DBO求解无线传感器WSN覆盖优化问题【含Matlab源码 3567期】.zip
recommend-type

FusionCompute修改VRM节点IP地址

FusionCompute修改VRM节点IP地址 该任务指导工程师对VRM节点的IP地址、主机的管理IP地址进行修改。 执行该任务时应注意: • 建议同时修改VRM和主机的管理IP。如果修改了VRM的IP,会导致本地PC与VRM的连接短暂中断。 • 修改前应已完成网络规划,并在FusionCompute中确认VRM节点运行正常,所有主机运行正常(无处于异常或维护状态的主机)。 • 如果跨网段修改IP地址时,则应注意在完成所有节点IP地址的修改后,在相应的汇聚交换机进行配置,保证修改后的主机IP地址、VRM节点及本地PC之间能进行正常通信。相关交换机配置命令,请参考交换机配置样例。 • 如果跨网段修改管理IP地址,同时涉及修改管理VLAN,请先修改管理平面VLAN,待修改完成,且各节点与VRM网络通信正常后,再进行修改VRM IP地址和主机IP地址的操作。
recommend-type

zigbee-cluster-library-specification

最新的zigbee-cluster-library-specification说明文档。
recommend-type

管理建模和仿真的文件

管理Boualem Benatallah引用此版本:布阿利姆·贝纳塔拉。管理建模和仿真。约瑟夫-傅立叶大学-格勒诺布尔第一大学,1996年。法语。NNT:电话:00345357HAL ID:电话:00345357https://theses.hal.science/tel-003453572008年12月9日提交HAL是一个多学科的开放存取档案馆,用于存放和传播科学研究论文,无论它们是否被公开。论文可以来自法国或国外的教学和研究机构,也可以来自公共或私人研究中心。L’archive ouverte pluridisciplinaire
recommend-type

实现实时数据湖架构:Kafka与Hive集成

![实现实时数据湖架构:Kafka与Hive集成](https://img-blog.csdnimg.cn/img_convert/10eb2e6972b3b6086286fc64c0b3ee41.jpeg) # 1. 实时数据湖架构概述** 实时数据湖是一种现代数据管理架构,它允许企业以低延迟的方式收集、存储和处理大量数据。与传统数据仓库不同,实时数据湖不依赖于预先定义的模式,而是采用灵活的架构,可以处理各种数据类型和格式。这种架构为企业提供了以下优势: - **实时洞察:**实时数据湖允许企业访问最新的数据,从而做出更明智的决策。 - **数据民主化:**实时数据湖使各种利益相关者都可
recommend-type

SQL怎么实现 数据透视表

SQL可以通过使用聚合函数和GROUP BY子句来实现数据透视表。 例如,假设有一个销售记录表,其中包含产品名称、销售日期、销售数量和销售额等信息。要创建一个按照产品名称、销售日期和销售额进行汇总的数据透视表,可以使用以下SQL语句: ``` SELECT ProductName, SaleDate, SUM(SaleQuantity) AS TotalQuantity, SUM(SaleAmount) AS TotalAmount FROM Sales GROUP BY ProductName, SaleDate; ``` 该语句将Sales表按照ProductName和SaleDat
recommend-type

JSBSim Reference Manual

JSBSim参考手册,其中包含JSBSim简介,JSBSim配置文件xml的编写语法,编程手册以及一些应用实例等。其中有部分内容还没有写完,估计有生之年很难看到完整版了,但是内容还是很有参考价值的。