是否有一种方法可以重写unicode字符

Is there a way to write over a unicode character?

本文关键字:重写 unicode 字符 方法 一种 是否      更新时间:2023-09-26

我想在一个网站上的unicode字符'♤'上面写一个数字。我知道我可以只是制作图像并使用这些,但因为我将有超过200♤符号与唯一的数字,我宁愿不使用图像,因为它们会占用大量的空间。

所以字符的大小必须是不同的。带数字的空格将放在div标签内。我真的希望有一种方法可以做到这一点,否则我将满足于图像。

.heart > div:nth-child(1) {
  font-size: 40px;
  color: red;
}
.heart > div:nth-child(2) {
  position: relative;
  font-size: 20px;
  top: -42px;
  left: 13px;
}
<div class="heart">
  <div>♤</div>
  <div>A</div>
</div>