fix(v1.7.1): wordmark image on every beep + reply, restore updater

- Render the Beep wordmark bottom-right of every beep AND reply, with the
  delete button furthest right (was: wordmark right of delete, missing on
  replies, and duplicated after the replies block).
- Draw the wordmark as crisp inline SVG via beep_post_wordmark() (filterable);
  the bundled beep-wordmark.png assets are corrupted. Readable on dark theme.
- Restore class-updater.php (self-hosted Gitea updates) deleted in the
  master->main consolidation; re-wire it in beep.php.
- Remove stray includes/class-shortcode.php.bak.
- Bump to 1.7.1; sync readme.txt stable tag + changelog.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Krystie
2026-06-07 21:09:28 -07:00
parent b7345c462d
commit 1703a09319
6 changed files with 367 additions and 311 deletions
+25 -6
View File
@@ -54,6 +54,25 @@ function beep_logo_svg() {
. ' alt="Beep!" style="height:32px;width:auto;filter:' . esc_attr( $filter ) . ';">';
}
/**
* Small "Beep!" brand wordmark shown at the bottom-right of every beep and reply.
*
* Rendered as crisp inline SVG so it stays sharp at any size and inherits its
* colour from CSS (currentColor). The bundled beep-wordmark.png assets are
* corrupted, so we draw the wordmark as vector text instead. To use a real
* image once you have a clean asset, hook the `beep_post_wordmark` filter:
* add_filter('beep_post_wordmark', fn() => '<img class="beep-post-wordmark" src="...">');
*/
function beep_post_wordmark() {
$svg = '<svg class="beep-post-wordmark" viewBox="0 0 62 20" width="50" height="16"'
. ' role="img" aria-label="Beep">'
. '<text x="0" y="15"'
. ' font-family="-apple-system,BlinkMacSystemFont,&quot;Segoe UI&quot;,Roboto,Helvetica,Arial,sans-serif"'
. ' font-size="16" font-weight="800" letter-spacing="-0.5" fill="currentColor">Beep!</text>'
. '</svg>';
return apply_filters('beep_post_wordmark', $svg);
}
/**
* Is this user banned from posting/liking/replying?
*/
@@ -332,6 +351,7 @@ function beep_render_post($post) {
<svg viewBox="0 0 24 24" width="18" height="18" fill="currentColor"><path d="M8 5H6v2H4v12h2v-2h2v2h8V9h-2V7h-2v2H8V5zm10 0v2h2v12h-2v-2h-2v2H8V9h2v2h2V7h2V5h2z"/></svg>
</a>
<div class="beep-bottom-bar">
<?php echo beep_post_wordmark(); ?>
<?php if ($can_delete) : ?>
<button class="beep-delete-link"
data-beep-delete="<?php echo (int) $post->ID; ?>"
@@ -339,7 +359,6 @@ function beep_render_post($post) {
aria-label="Delete this beep"
title="Delete">&times;</button>
<?php endif; ?>
<span class="beep-wordmark">Beep!</span>
</div>
<?php if ($can_interact) : ?>
@@ -352,7 +371,6 @@ function beep_render_post($post) {
echo beep_render_replies_tree($all, 0, 0, $post->ID, $can_interact);
?>
</div>
<span class="beep-wordmark">Beep!</span>
</div>
</article>
<?php
@@ -465,15 +483,16 @@ function beep_render_reply($comment, $all_comments = [], $depth = 0, $post_id =
</div>
<?php echo beep_render_reply_form($post_id, $comment->comment_ID); ?>
<?php endif; ?>
<?php if ($can_delete) : ?>
<div class="beep-delete-row">
<div class="beep-bottom-bar beep-bottom-bar-reply">
<?php echo beep_post_wordmark(); ?>
<?php if ($can_delete) : ?>
<button class="beep-delete-link"
data-beep-delete-reply="<?php echo (int) $comment->comment_ID; ?>"
type="button"
aria-label="Delete this reply"
title="Delete">&times;</button>
</div>
<?php endif; ?>
<?php endif; ?>
</div>
<?php
// Recursively render children