Skip to content

Commit 798a625

Browse files
authored
Merge pull request #457 from janboddez/main
Fix #396
2 parents b1deda1 + 11c1d4e commit 798a625

File tree

2 files changed

+38
-1
lines changed

2 files changed

+38
-1
lines changed

assets/css/admin.css

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
.repost .dashboard-comment-wrap,
2+
.like .dashboard-comment-wrap,
3+
.favorite .dashboard-comment-wrap,
4+
.tag .dashboard-comment-wrap,
5+
.bookmark .dashboard-comment-wrap,
6+
.listen .dashboard-comment-wrap,
7+
.watch .dashboard-comment-wrap,
8+
.read .dashboard-comment-wrap,
9+
.follow .dashboard-comment-wrap,
10+
.mention .dashboard-comment-wrap,
11+
.reacji .dashboard-comment-wrap {
12+
padding-inline-start: 63px;
13+
}
14+
15+
.repost .dashboard-comment-wrap .comment-author,
16+
.like .dashboard-comment-wrap .comment-author,
17+
.favorite .dashboard-comment-wrap .comment-author,
18+
.tag .dashboard-comment-wrap .comment-author,
19+
.bookmark .dashboard-comment-wrap .comment-author,
20+
.listen .dashboard-comment-wrap .comment-author,
21+
.watch .dashboard-comment-wrap .comment-author,
22+
.read .dashboard-comment-wrap .comment-author,
23+
.follow .dashboard-comment-wrap .comment-author,
24+
.mention .dashboard-comment-wrap .comment-author,
25+
.reacji .dashboard-comment-wrap .comment-author {
26+
margin-block: 0;
27+
}

includes/class-admin.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public static function admin_init() {
2020

2121
/* Add meta boxes on the 'add_meta_boxes' hook. */
2222
add_action( 'add_meta_boxes', array( static::class, 'add_meta_boxes' ) );
23-
23+
add_action( 'admin_enqueue_scripts', array( static::class, 'enqueue_scripts' ) );
2424
add_filter( 'plugin_action_links', array( static::class, 'plugin_action_links' ), 10, 2 );
2525
add_filter( 'plugin_row_meta', array( static::class, 'plugin_row_meta' ), 10, 2 );
2626

@@ -457,4 +457,14 @@ public static function add_privacy_policy_content() {
457457
wp_add_privacy_policy_content( __( 'Webmention', 'webmention' ), $content );
458458
}
459459
}
460+
461+
/**
462+
* Enqueue admin styles.
463+
*/
464+
public static function enqueue_scripts() {
465+
$current_screen = get_current_screen();
466+
if ( isset( $current_screen->base ) && 'dashboard' === $current_screen->base ) {
467+
wp_enqueue_style( 'webmention-admin', plugins_url( '/assets/css/admin.css', __DIR__ ), array(), version() );
468+
}
469+
}
460470
}

0 commit comments

Comments
 (0)