Skip to content

Commit ffbadcd

Browse files
authored
Merge pull request #4780 from Laravel-Backpack/fixes-on-list-table
Fixed shifted column headers and vertical middle alignment
2 parents a13f63b + 2ef3f96 commit ffbadcd

File tree

3 files changed

+18
-31
lines changed

3 files changed

+18
-31
lines changed

src/public/packages/backpack/base/css/blue-bundle.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/public/packages/backpack/base/css/bundle.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/resources/assets/scss/customs/_list.scss

Lines changed: 16 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,9 @@
4444
border: none;
4545
display: inline;
4646
position: relative;
47-
top: 0;
47+
top: 0.2rem;
4848
left: 0;
49-
margin: 0 0 0 -0.25rem;
50-
}
51-
52-
&.dtr-inline.collapsed > tbody > tr > .dtr-control:before {
53-
top: 0;
49+
margin: 0 -0.4rem 0 -0.25rem;
5450
}
5551

5652
td,
@@ -61,13 +57,6 @@
6157
// box-shadow: none;
6258
}
6359

64-
thead > tr {
65-
& > th:not(.sorting_disabled),
66-
& > td {
67-
padding-right: 30px;
68-
}
69-
}
70-
7160
.sorting:before,
7261
.sorting_asc:before,
7362
.sorting_desc:before,
@@ -92,27 +81,27 @@
9281
}
9382

9483
&.has-hidden-columns .details-control {
95-
margin-left: 0.25rem;
84+
margin-left: 0.2rem;
9685
}
9786

9887
&[data-has-bulk-actions="1"] {
9988
&.has-hidden-columns {
10089
thead tr th:first-child,
10190
tfoot tr th:first-child {
102-
padding-left: 1.35rem !important;
91+
padding-left: 1.45rem !important;
10392
}
10493
}
10594

10695
&[data-has-details-row="1"] {
10796
thead tr th:first-child,
10897
tfoot tr th:first-child {
109-
padding-left: 1.6rem !important;
98+
padding-left: 1.8rem !important;
11099
}
111100

112101
&.has-hidden-columns {
113102
thead tr th:first-child,
114103
tfoot tr th:first-child {
115-
padding-left: 2.6rem !important;
104+
padding-left: 2.9rem !important;
116105
}
117106
}
118107
}
@@ -123,30 +112,26 @@
123112
&.has-hidden-columns {
124113
thead tr th:first-child,
125114
tfoot tr th:first-child {
126-
padding-left: 1.8rem !important;
115+
padding-left: 2rem !important;
127116
}
128117
}
129118

130119
&[data-has-details-row="1"].has-hidden-columns {
131120
thead tr th:first-child,
132121
tfoot tr th:first-child {
133-
padding-left: 3rem !important;
122+
padding-left: 3.1rem !important;
134123
}
135124
}
136125
}
137126

138-
.details-control {
139-
display: flex;
140-
}
141-
142127
.crud_bulk_actions_checkbox {
143-
display: flex;
144128
margin: 0 0.6rem 0 0.45rem;
145129
}
146130

147131
.crud_bulk_actions_checkbox input {
148132
width: 1rem;
149133
height: 1rem;
134+
margin-top: 2px;
150135
}
151136

152137
&:not(.has-hidden-columns) {
@@ -157,16 +142,14 @@
157142
}
158143
tr th:first-child,
159144
tr td:first-child {
160-
display: flex;
161-
align-items: center;
162-
padding-top: 1.1rem !important;
163-
padding-bottom: 1.1rem !important;
145+
padding-top: 1rem !important;
146+
padding-bottom: 1rem !important;
164147
padding-left: 0.6rem !important;
165148
}
166149

167150
&[data-has-bulk-actions="0"] .details-control,
168151
&[data-has-bulk-actions="0"][data-has-details-row="0"] .dtr-control:before {
169-
margin-right: 0.4rem !important;
152+
margin-right: 0.2rem !important;
170153
}
171154

172155
&[data-responsive-table="0"] thead tr th,
@@ -252,6 +235,10 @@
252235
font-weight: 600;
253236
text-transform: uppercase;
254237
}
238+
239+
.nav-link.invisible {
240+
display: none;
241+
}
255242
}
256243

257244
@media (min-width: 768px) {

0 commit comments

Comments
 (0)