inj3ct0r
(inj3ct0r)
2023 年 9 月 26 日午後 9:26
1
こんにちは、お元気でお過ごしでしょうか。
今日の最後のアップデートの後、クラッシュしたユーザーカードが表示されました
そして、メインコンテナと一緒にダウンしています。
「いいね!」 2
simon
2023 年 9 月 26 日午後 10:04
2
以前は、RTLロケールに対してユーザーカードの位置を特別に処理していました: discourse/app/assets/javascripts/discourse/views/user-card.js.es6 at 4896a7dec79203cd44265bb2372c2b4a223c3d26 · discourse/discourse · GitHub
ユーザーカードのアップデートにより、それが削除されたようです。ユーザーカードのインラインスタイルでの left 位置は、RTLロケールでは間違っています。記憶している限りでは、RTLロケールが使用されているときにユーザーカードに right 位置を設定するのが最も簡単な対処法だと思います。ただし、left プロパティと right プロパティをインラインスタイルのルールで単に切り替えることはできません。
「いいね!」 1
inj3ct0r
(inj3ct0r)
2023 年 9 月 26 日午後 10:36
3
こんにちは、新しいアップデートです。
返信ボタンが機能しません。
「いいね!」 2
simon
2023 年 9 月 26 日午後 10:46
4
inj3ct0r:
返信ボタンが機能しません
「機能」しますが、投稿エディターが使用できません。
これらの問題は、インターフェイス言語に RTL ロケールを選択すると、Meta で再現できます。
編集: Meta のコンポーザーで見つかった問題は、GitHub - discourse/discourse-full-width-component: Make Discourse occupy the full browser width に関連しているようです。
ユーザーカードの問題は、Meta または try.discourse.org でセーフモードで再現できます。
また、ユーザーチップモーダルは、セーフモードで RTL ロケールの場合、正しく配置されません。
「いいね!」 2
simon
2023 年 9 月 26 日午後 11:31
6
サイトをセーフモードで読み込んで、問題が解決するかどうか試してみていただけますか。そのために、ブラウザのアドレスバーのURLに以下を追加してください。
?safe_mode=no_themes,no_plugins
例えば、\u003chttps://try.discourse.org/t/what-do-the-avatars-in-the-topic-list-mean/65?safe_mode=no_themes,no_plugins\u003e
「いいね!」 3
inj3ct0r
(inj3ct0r)
2023 年 9 月 26 日午後 11:56
7
はい、返信ボタンは修正されましたが、ユーザーカードはまだ壊れています。
「いいね!」 1
Osama
2023 年 12 月 15 日午後 3:45
12
Hi @inj3ct0r
This has been fixed via this commit:
committed 10:16AM - 15 Dec 23 UTC
Float-kit elements (menus/tooltips) are positioned where they should be by setti… ng an inline `left` property in JavaScript when they're rendered. For some reasons, we also set `left: 0` on float-kit elements here:
https://github.com/discourse/discourse/blob/25d9927785b07697132504fca77b8156600966ff/app/assets/stylesheets/common/float-kit/d-menu.scss#L11-L15
This property is overridden by the inline property that the library sets in JavaScript. However, in RTL mode, all of our scss files are flipped where everything left becomes right and vice versa. In this case, the `left: 0` property in the scss file above becomes `right: 0`.
This results in a conflict specific to RTL mode where both the `left` and `right` properties are defined on the same absolute-positioned element; the `right` property will always be set to 0 because it comes from the (flipped) scss file above, and the inline `left` property will be set to some px amount determined in JavaScript.
The `right` property will take precedence over the inline `left` property due to the page being right-to-left (source: https://developer.mozilla.org/en-US/docs/Web/CSS/right#description) and this causes float-kit elements to incorrectly always stick to the right.
This commit removes the `left: 0` property altogether for float-kit elements from our scss files. It's not clear from git history why the property was added, and removing it doesn't seem to cause any issues.
Meta topic: https://meta.discourse.org/t/positioning-issues-with-rtl-locales-after-recent-updates/280220?u=osama
「いいね!」 2
Osama
クローズされました:
2023 年 12 月 19 日午後 3:45
13
このトピックは4日後に自動的に閉じられました。返信はもう許可されていません。