I have a problem combining box-decoration-break: clone
with text-align: right
of the parent div, once there is a line break and I set padding.
In Firefox, this works as expected, in Chrome however the first and the last line are indented differently. Does anybody have a solution to this?
.text {
padding-left: 30px;
padding-right: 30px;
box-decoration-break: clone;
-webkit-box-decoration-break: clone;
background: blue;
}
.container {
text-align: right;
width: 80%;
margin: auto;
}
<div class="container">
<h1>
<span class="text">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua.</span>
</h1>
</div>
https://jsfiddle.net/okapi123/a24n1xt3/12/
Thanks in advance!