Skip to content

Commit 8e8075b

Browse files
authored
Merge pull request #4636 from Laravel-Backpack/fix-wrong-datatable-row-colors
fix wrong datatable row colors
2 parents 6ab39f7 + ce0f2b7 commit 8e8075b

File tree

5 files changed

+40
-29
lines changed

5 files changed

+40
-29
lines changed

package-lock.json

Lines changed: 24 additions & 24 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

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: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454
outline: none;
5555
vertical-align: middle;
5656
line-height: 1em;
57+
// box-shadow: none;
5758
}
5859

5960
thead > tr {
@@ -147,14 +148,15 @@
147148
&:not(.has-hidden-columns) {
148149
tr td:first-child {
149150
padding-top: 1.25rem !important;
151+
padding-bottom: 1.25rem !important;
150152
}
151153
}
152154
tr th:first-child,
153155
tr td:first-child {
154156
display: flex;
155157
align-items: center;
156-
padding-top: 1rem !important;
157-
padding-bottom: 1rem !important;
158+
padding-top: 1.1rem !important;
159+
padding-bottom: 1.1rem !important;
158160
padding-left: 0.6rem !important;
159161
}
160162

@@ -326,6 +328,15 @@
326328
}
327329
}
328330

331+
table.dataTable.table-striped>tbody>tr:nth-of-type(2n+1):hover {
332+
background-color: rgba(124,105,239,.1);
333+
}
334+
335+
table.dataTable.table-striped>tbody>tr.odd>*,
336+
table.dataTable.table-hover>tbody>tr:hover>* {
337+
box-shadow: none!important;
338+
}
339+
329340
// Removes the horizontal scroll (if the width allows it)
330341
.box-body.table-responsive {
331342
padding-left: 15px;

src/resources/views/crud/inc/datatables_logic.blade.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ functionsToRunOnDataTablesDrawEvent: [],
123123
let tmpUrl = newUrl.split("?")[0],
124124
params_arr = [],
125125
queryString = (newUrl.indexOf("?") !== -1) ? newUrl.split("?")[1] : false;
126-
126+
127127
// exclude the persistent-table parameter from url
128128
if (queryString !== false) {
129129
params_arr = queryString.split("&");

0 commit comments

Comments
 (0)