1
我注意到當我使用帶填充的border-radius和HTML的方向是RTL時,它不像預期的那樣工作。它工作正常,如果刪除方向部分dir="rtl"
。下面的代碼將展示它是如何工作的,並沒有與dir="rtl"
IE中的邊界半徑和RTL問題
沒有dir="rtl"
:
<!DOCTYPE html>
<html >
<head>
<title>test</title>
</head>
<body>
<style type="text/css">
.main {
padding:5px;
}
.tag{
background-color: #0473c0;
border-radius: 3px 3px 3px 3px;
padding:5px;
}
</style>
<div class="main">
<span class="tag">test</span>
</div>
</body>
</html>
結果:
與dir="rtl"
:
<!DOCTYPE html>
<html dir="rtl">
<head>
<title>test</title>
</head>
<body>
<style type="text/css">
.main {
padding:5px;
}
.tag{
background-color: #0473c0;
border-radius: 3px 3px 3px 3px;
padding:5px;
}
</style>
<div class="main">
<span class="tag">test</span>
</div>
</body>
</html>
結果:
正如你所看到的文字移動到左邊,背景移到了右邊。我在IE10和IE9上測試過它。有沒有解決這個問題或任何工作?
在這裏正常工作 – ShibinRagh
我可以重現它。奇怪的問題。它似乎使跨度'內聯塊'有所幫助,但我不知道它對RTL文檔中的文本流是什麼。 – Jeroen