# 编辑历史修订箭头对RTL语言不正确

**URL:** <https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707>\
**Category:** Bug\
**Tags:** fixed, rtl\
**Created:** [2025年五月3日 19:25 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707 "2025-05-03T19:25:18Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![discojan](https://avatars.discourse-cdn.com/v4/letter/d/c0e974/32.png) [@discojan](https://meta.discourse.org/u/discojan)\
**Post date:** [2025年五月3日 19:25 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/1 "2025-05-03T19:25:18Z")

</div>

![image](https://global.discourse-cdn.com/meta/original/4X/8/1/2/8127e5c151652b7713d10ad1e4d0c821121e84a5.png)

正如你所见，右侧箭头的悬停文本显示“第一次修订”，而指向另一侧的箭头，对于 RTL 阅读者来说，它们是面对面的。

应该为

 ![image](https://global.discourse-cdn.com/meta/original/4X/8/2/7/8278a4b231a1c7d48227db9cb57b614a9bf18125.png)

---

<div class="post-metadata">

**Author:** ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)\
**Post date:** [2025年五月5日 01:54 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/2 "2025-05-05T01:54:14Z")

</div>

这是一个有趣的问题，我们有一个“反转 CSS”的流程，但似乎这里有一些非常特定的区域需要覆盖。

将此标记为 #pr-welcome 并通知相关产品团队。

---

<div class="post-metadata">

**Author:** ![Osama](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/osama/32/98013_2.png) [@Osama](https://meta.discourse.org/u/Osama)\
**Post date:** [2025年五月5日 02:38 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/4 "2025-05-05T02:38:51Z")

</div>

对于“尖头”图标，我们需要翻转它们，使它们指向 RTL 语言的正确方向。我们通过 CSS 来实现这一点，方法是定位尖头图标并将它们旋转 180 度：

> <https://github.com/discourse/discourse/blob/25dfc64b399f577fbe4d243309ccea2f231121e1/app/assets/stylesheets/common/base/rtl.scss#L2-L24>

我们只需要将这些前进/后退图标添加到上面的列表中。

---

<div class="post-metadata">

**Author:** ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)\
**Post date:** [2025年五月5日 04:52 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/5 "2025-05-05T04:52:05Z")

</div>

但这是否意味着点击“转到上次修订”将带您到第一次修订？

---

<div class="post-metadata">

**Author:** ![Osama](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/osama/32/98013_2.png) [@Osama](https://meta.discourse.org/u/Osama)\
**Post date:** [2025年五月5日 15:04 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/6 "2025-05-05T15:04:50Z")

</div>

不，按钮保持在原位，只是按钮内的图标旋转了 180 度。使用 `transform: rotate(180deg)` 看起来是这样的：

 ![](https://global.discourse-cdn.com/meta/original/4X/5/1/c/51c6069603386703824fa479d38a6d2f34865f7f.png)

“带我到第一个修订版”按钮指向文档的开头，“带我到最后一个修订版”按钮指向文档的末尾。

---

<div class="post-metadata">

**Author:** ![discojan](https://avatars.discourse-cdn.com/v4/letter/d/c0e974/32.png) [@discojan](https://meta.discourse.org/u/discojan)\
**Post date:** [2025年五月5日 18:25 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/7 "2025-05-05T18:25:14Z")

</div>

“返回审查”图标似乎也需要水平翻转 😅。

---

<div class="post-metadata">

**Author:** ![chapoi](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chapoi/32/537252_2.png) [@chapoi](https://meta.discourse.org/u/chapoi)\
**Post date:** [2026年二月5日 12:14 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/8 "2026-02-05T12:14:44Z")

</div>

随着对 RTL 图标的最新更新，我认为这可以视为已修复

> <https://github.com/discourse/discourse/pull/37568>
>
> I think the original intent was to only target directional icons, but things fal…l through the cracks (see https://meta.discourse.org/t/reverse-reply-arrow-icon-for-rtl/385565) so this commit aims to:
> 
> \* apply a catch-all to icons
> \* use \`transform: scaleX(-1);\` which provides a more correct horizontal flip
> 
> As a downside, the transform now gets applied to all icons, but this should come at a negligible performance cost.

---

<div class="post-metadata">

**Author:** ![chapoi](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chapoi/32/537252_2.png) [@chapoi](https://meta.discourse.org/u/chapoi)\
**Post date:** [2026年三月7日 12:15 UTC](https://meta.discourse.org/t/edit-history-revision-arrows-are-not-correct-for-rtl-languages/364707/9 "2026-03-07T12:15:06Z")

</div>

此主题在最后一次回复后 30 天自动关闭。不再允许新的回复。
