小编Rad*_*1nd的帖子

CSS带背景的旋转文本显示了一些背景问题

我正在使用CSS稍微旋转文本。文本在白色背景上是黑色的,但是由于背景的旋转,所以有一些透明的小线穿过它。此图像将更清楚地显示它:
我的问题

body {
  background: red;
}

.featured-grid-b .item-heading {
  /*Black text on white background*/
  box-shadow: 0 0 0 5px #fff;
  padding: 0;
  background: #fff;
  line-height: 2 !important;
  display: inline;
  color: #000;
  text-shadow: none;
}

.caption h3 {
  /*Rotate Text*/
  transform: rotate(-3deg);
  margin-bottom: 15px;
}
Run Code Online (Sandbox Code Playgroud)
<div class="featured-grid featured-grid-b" data-animation="fade" data-animation-speed="600" data-slide-delay="5000">
  <div class="caption caption-large">
    <h3><a href="http://www.fair-fashion-magazin.de/2019/07/03/das-nachhaltige-mode-label-people-tree/" class="item-heading">Fashion zum Verlieben: Das Fair Fashion Label People Tree</a></h3>
  </div>
</div>
Run Code Online (Sandbox Code Playgroud)

由于这是一个Wordpress网站,因此我无法真正调整HTML并尝试仅通过CSS更改来实现结果。因此,如果可能的话,我正在寻找可以解决该问题的CSS解决方案。文本应该看起来像这样,在每行文本之间留有空格。

html css rotation css-transforms

3
推荐指数
1
解决办法
77
查看次数

标签 统计

css ×1

css-transforms ×1

html ×1

rotation ×1