Skip to content

Commit 94c2f3b

Browse files
Antoliny0919sarahboyce
authored andcommitted
Fixed #36055 -- Prevented overlap of object-tools buttons and page header in the admin.
1 parent f96c8f0 commit 94c2f3b

13 files changed

Lines changed: 60 additions & 33 deletions

File tree

django/contrib/admin/static/admin/css/base.css

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -808,19 +808,19 @@ a.deletelink:focus, a.deletelink:hover {
808808
/* OBJECT TOOLS */
809809

810810
.object-tools {
811-
font-size: 0.625rem;
812-
font-weight: bold;
813-
padding-left: 0;
814-
float: right;
815-
position: relative;
816-
margin-top: -48px;
811+
padding: 0;
812+
overflow: hidden;
813+
text-align: right;
814+
margin: 0 0 15px;
817815
}
818816

819817
.object-tools li {
820-
display: block;
821-
float: left;
822-
margin-left: 5px;
823-
height: 1rem;
818+
display: inline-block;
819+
height: auto;
820+
}
821+
822+
.object-tools li + li {
823+
margin-left: 15px;
824824
}
825825

826826
.object-tools a {

django/contrib/admin/static/admin/css/responsive.css

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -442,19 +442,7 @@ input[type="submit"], button {
442442
}
443443

444444
.object-tools {
445-
float: none;
446-
margin: 0 0 15px;
447-
padding: 0;
448-
overflow: hidden;
449-
}
450-
451-
.object-tools li {
452-
height: auto;
453-
margin-left: 0;
454-
}
455-
456-
.object-tools li + li {
457-
margin-left: 15px;
445+
text-align: left;
458446
}
459447

460448
/* Forms */

django/contrib/admin/static/admin/css/responsive_rtl.css

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,15 +34,6 @@
3434
background-position: calc(100% - 8px) 9px;
3535
}
3636

37-
[dir="rtl"] .object-tools li {
38-
float: right;
39-
}
40-
41-
[dir="rtl"] .object-tools li + li {
42-
margin-left: 0;
43-
margin-right: 15px;
44-
}
45-
4637
[dir="rtl"] .dashboard .module table td a {
4738
padding-left: 0;
4839
padding-right: 16px;
@@ -72,6 +63,11 @@
7263
margin-left: 0;
7364
margin-right: 0;
7465
}
66+
67+
[dir="rtl"] .object-tools {
68+
text-align: right;
69+
}
70+
7571
[dir="rtl"] .aligned .vCheckboxLabel {
7672
padding: 1px 5px 0 0;
7773
}

django/contrib/admin/static/admin/css/rtl.css

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,12 @@ th {
2626
}
2727

2828
.object-tools {
29-
float: left;
29+
text-align: left;
30+
}
31+
32+
.object-tools li + li {
33+
margin-right: 15px;
34+
margin-left: 0;
3035
}
3136

3237
thead th:first-child,

docs/intro/_images/admin04t.png

-11.2 KB
Loading

docs/intro/_images/admin05t.png

18.7 KB
Loading

docs/intro/_images/admin12t.png

-8.42 KB
Loading

docs/intro/_images/admin13t.png

-10.9 KB
Loading
-22.1 KB
Loading
-19.8 KB
Loading

0 commit comments

Comments
 (0)