Skip to content

Commit 55765f5

Browse files
Administration: Improve dashboard meta box control visuals
1 parent 752d544 commit 55765f5

2 files changed

Lines changed: 18 additions & 5 deletions

File tree

‎src/wp-admin/css/common.css‎

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2196,6 +2196,7 @@ html.wp-toolbar {
21962196
/* one column on the dash */
21972197
@media only screen and (max-width: 799px) {
21982198
#wpbody-content .metabox-holder .postbox-container .empty-container {
2199+
border: 0;
21992200
outline: none;
22002201
height: 0;
22012202
min-height: 0;
@@ -2235,6 +2236,12 @@ html.wp-toolbar {
22352236

22362237
.postbox-header .handle-actions {
22372238
flex-shrink: 0;
2239+
padding-right: 8px;
2240+
}
2241+
2242+
.rtl .postbox-header .handle-actions {
2243+
padding-right: 0;
2244+
padding-left: 8px;
22382245
}
22392246

22402247
/* Post box order and toggle buttons. */
@@ -3341,7 +3348,13 @@ img {
33413348
}
33423349

33433350
.postbox .handle-order-higher:focus,
3344-
.postbox .handle-order-lower:focus,
3351+
.postbox .handle-order-lower:focus {
3352+
border-radius: 2px;
3353+
box-shadow: 0 0 0 var(--wp-admin-border-width-focus, 1.5px) var(--wp-admin-theme-color, #3858e9);
3354+
/* Only visible in Windows High Contrast mode */
3355+
outline: 2px solid transparent;
3356+
}
3357+
33453358
.postbox .handlediv:focus {
33463359
box-shadow: inset 0 0 0 var(--wp-admin-border-width-focus, 1.5px) var(--wp-admin-theme-color);
33473360
border-radius: 50%;

‎src/wp-admin/css/dashboard.css‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,11 +67,10 @@
6767
}
6868

6969
#dashboard-widgets .postbox-container .empty-container {
70-
outline: 2px dashed rgb(0, 0, 0, 0.15);
71-
outline-offset: -2px;
70+
box-sizing: border-box;
71+
border: 1px dashed #c3c4c7;
7272
border-radius: 8px;
7373
height: 250px;
74-
margin: 4px;
7574
}
7675

7776
/* Only highlight drop zones when dragging. */
@@ -82,7 +81,7 @@
8281
}
8382

8483
.is-dragging-metaboxes #dashboard-widgets .postbox-container .empty-container {
85-
background: rgb(0, 0, 0, 0.01);
84+
background: rgb(var(--wp-admin-theme-color--rgb), 0.04);
8685
}
8786

8887
#dashboard-widgets .postbox-container .empty-container:after {
@@ -1288,6 +1287,7 @@ a.rsswidget {
12881287
}
12891288

12901289
#dashboard-widgets .meta-box-sortables.empty-container {
1290+
border: 0;
12911291
margin-bottom: 0;
12921292
}
12931293
}

0 commit comments

Comments
 (0)