[Django] #35375: Original line of tabular inline admin is always shown on the left, even in RTL

34 views
Skip to first unread message

Django

unread,
Apr 15, 2024, 7:39:49 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
-------------------------------------+-------------------------------------
Reporter: Eyal | Owner: nobody
Cherevatsky |
Type: Bug | Status: new
Component: | Version: 5.0
contrib.admin |
Severity: Normal | Keywords: admin, inline, rtl
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 1
UI/UX: 1 |
-------------------------------------+-------------------------------------
When using a tabular inline admin model, the "original" line (containing
the string representation and, optionally, a view/change link) is always
show on the left. This is fine in most cases, expect for cases where the
language is RTL (right-to-left).

The following CSS, if put in
`django/contrib/admin/static/admin/css/rtl.css`, should resolve the issue:

{{{#!css
.inline-group .tabular td.original p {
right: 0;
}
}}}

Alternatively, instead of having specific styling for RTL, we can use
`inset-inline-start` instead of `left`, which will work correctly for both
LTR and RTL. I believe this should be changed here:
https://github.com/django/django/blob/dd238212082f6547d5b03c5af6ec53368c39568e/django/contrib/admin/static/admin/css/forms.css#L458
--
Ticket URL: <https://code.djangoproject.com/ticket/35375>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Apr 15, 2024, 7:41:29 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
------------------------------------+--------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: new
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution:
Keywords: admin, inline, rtl | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
------------------------------------+--------------------------------------
Changes (by Eyal Cherevatsky):

* Attachment "ltr.png" added.

Django

unread,
Apr 15, 2024, 7:41:35 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
------------------------------------+--------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: new
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution:
Keywords: admin, inline, rtl | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
------------------------------------+--------------------------------------
Changes (by Eyal Cherevatsky):

* Attachment "rtl.png" added.

Django

unread,
Apr 15, 2024, 7:57:15 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
------------------------------------+--------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: new
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution:
Keywords: admin, inline, rtl | Triage Stage: Unreviewed
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
------------------------------------+--------------------------------------
Changes (by Eyal Cherevatsky):

* has_patch: 0 => 1

--
Ticket URL: <https://code.djangoproject.com/ticket/35375#comment:1>

Django

unread,
Apr 15, 2024, 8:10:08 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
------------------------------------+--------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: new
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution:
Keywords: admin, inline, rtl | Triage Stage: Unreviewed
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
------------------------------------+--------------------------------------
Changes (by Eyal Cherevatsky):

* Attachment "ltr-dark.png" added.

Django

unread,
Apr 15, 2024, 8:10:12 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
------------------------------------+--------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: new
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution:
Keywords: admin, inline, rtl | Triage Stage: Unreviewed
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
------------------------------------+--------------------------------------
Changes (by Eyal Cherevatsky):

* Attachment "rtl-dark.png" added.

Django

unread,
Apr 15, 2024, 9:17:44 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
-------------------------------------+-------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: new
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution:
Keywords: admin, inline, rtl, | Triage Stage: Accepted
accessibility |
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
-------------------------------------+-------------------------------------
Changes (by Sarah Boyce):

* keywords: admin, inline, rtl => admin, inline, rtl, accessibility
* stage: Unreviewed => Accepted

Comment:

Thank you for the report and the patch!
I think I prefer option 2 but still testing 👍
--
Ticket URL: <https://code.djangoproject.com/ticket/35375#comment:2>

Django

unread,
Apr 15, 2024, 10:03:40 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
-------------------------------------+-------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: new
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution:
Keywords: admin, inline, rtl, | Triage Stage: Ready for
accessibility | checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
-------------------------------------+-------------------------------------
Changes (by Sarah Boyce):

* stage: Accepted => Ready for checkin

Comment:

Went for option 1 as the accessibility team is in the process of
discussing the use of logical properties, see:
https://github.com/django/django/pull/17560
--
Ticket URL: <https://code.djangoproject.com/ticket/35375#comment:3>

Django

unread,
Apr 15, 2024, 10:12:08 AM4/15/24
to django-...@googlegroups.com
#35375: Original line of tabular inline admin is always shown on the left, even in
RTL
-------------------------------------+-------------------------------------
Reporter: Eyal Cherevatsky | Owner: nobody
Type: Bug | Status: closed
Component: contrib.admin | Version: 5.0
Severity: Normal | Resolution: fixed
Keywords: admin, inline, rtl, | Triage Stage: Ready for
accessibility | checkin
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 1
-------------------------------------+-------------------------------------
Changes (by Sarah Boyce <42296566+sarahboyce@…>):

* resolution: => fixed
* status: new => closed

Comment:

In [changeset:"2bcf555763f3d4fa19c135ac895e5d16e9d7141a" 2bcf555]:
{{{#!CommitTicketReference repository=""
revision="2bcf555763f3d4fa19c135ac895e5d16e9d7141a"
Fixed #35375 -- Fixed tabular inline admin original line to be on the
right in RTL.
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/35375#comment:4>
Reply all
Reply to author
Forward
0 new messages