Make WordPress Core

Ticket #64714: 64714.diff

File 64714.diff, 2.3 KB (added by abhishekfdd, 7 months ago)
  • src/wp-admin/css/dashboard.css

    diff --git src/wp-admin/css/dashboard.css src/wp-admin/css/dashboard.css
    index 324637a..871f6b4 100644
     
    5151        padding: 12px 16px;
    5252}
    5353
     54/*
     55 * Normalize the vertical spacing between the postbox header and the first
     56 * content item across Dashboard widgets.
     57 *
     58 * The default `.postbox .inside` rule in common.css applies `margin: 11px 0`,
     59 * which produces an 11px gap for widgets that don't override it. Widgets that
     60 * override `.inside` to `margin: 0; padding: 0` (Activity, WordPress Events
     61 * and News, Quick Draft) instead inherit the gap from their first child,
     62 * producing offsets of 0, 8, or 12px. The resulting mix — 0, 8, 11, 12 —
     63 * makes the Dashboard feel unbalanced.
     64 *
     65 * Resetting the vertical margin here and supplying a uniform 12px top offset
     66 * (either via `.inside` padding or via first-child spacing) brings all five
     67 * widgets into alignment with the 12px design token already used for
     68 * `.hndle` padding and the Quick Draft form. See #64714.
     69 */
    5470#dashboard-widgets .postbox .inside {
     71        margin-top: 0;
    5572        margin-bottom: 0;
    5673}
    5774
     75#dashboard_site_health .inside,
     76#dashboard_right_now .inside {
     77        padding-top: 12px;
     78}
     79
    5880#dashboard-widgets .meta-box-sortables {
    5981        display: flow-root; /* avoid margin collapsing between parent and first/last child elements */
    6082        /* Required min-height to make the jQuery UI Sortable drop zone work. */
    … …  
    651673
    652674#dashboard_primary .inside {
    653675        margin: 0;
    654         padding: 0;
     676        padding: 12px 0 0;
    655677}
    656678
    657679#dashboard_primary .widget-loading {
    658         padding: 12px 12px 0;
     680        padding: 0 12px;
    659681        margin-bottom: 1em !important; /* Needs to override `.postbox .inside > p:last-child` in common.css */
    660682}
    661683
    … … body #dashboard-widgets .postbox form .submit {  
    788810}
    789811
    790812#dashboard_quick_press form {
    791         margin: 12px;
     813        margin: 0 12px 12px;
    792814}
    793815
    794816#dashboard_quick_press .drafts {
    … … body #dashboard-widgets .postbox form .submit {  
    906928
    907929#dashboard_activity .inside {
    908930        margin: 0;
    909         padding: 0 12px;
     931        padding: 12px 12px 0;
     932}
     933
     934#dashboard_activity .inside > #activity-widget > .activity-block:first-child {
     935        padding-top: 0;
    910936}
    911937
    912938#dashboard_activity .no-activity {
    913939        overflow: hidden;
    914         padding: 12px 0;
     940        padding: 0 0 12px;
    915941        text-align: center;
    916942}
    917943