CSS实现元素右上角的小圆点
记录两种更好的解决方案:
1.使用sup标签--定义上标文本
<p>
This text contains <sup>superscript上标</sup>
</p>
2.使用css属性vertical-align
<style>
.dot {
width: 8px;
height: 8px;
border-radius: 50%;
/* background-color: @danger; */
display: inline-block;
vertical-align: super;
}
</style>
</head>
<body>
<p class="dot">非</p>
</body>
2、layui的徽章
https://www.layui.com/demo/badge.html