From c4aa5cdb5e90ad4b420e22772797d16980232a2b Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Wed, 15 Apr 2026 18:38:55 +0000
Subject: [PATCH] =Updating custom tables to utilize CustomTable.php
---
inc/helpers/ui.php | 22 ++++++++++------------
1 files changed, 10 insertions(+), 12 deletions(-)
diff --git a/inc/helpers/ui.php b/inc/helpers/ui.php
index 4da00a5..6928d43 100644
--- a/inc/helpers/ui.php
+++ b/inc/helpers/ui.php
@@ -111,7 +111,7 @@
*/
function jvbNotificationMenu():string
{
- if (jvbSiteHasNotifications() && is_user_logged_in()) {
+ if (Features::forMembership()->has('notifications') && is_user_logged_in()) {
ob_start();
?>
@@ -253,7 +253,7 @@
function jvbImageCaption(int $imgID, string $start = 'tiny', string $end = 'large', bool $addLink = true, ?string $postSlug = null):string
{
$caption = wp_get_attachment_caption($imgID);
- $caption = ($caption && $caption !== '') ? '<figcaption>'.apply_filters('the_content', $caption).'</figcaption>' : '';
+ $caption = ($caption && $caption !== '') ? '<figcaption>'.jvb_filter_content( $caption).'</figcaption>' : '';
return '<figure>'.jvbFormatImage($imgID, $start, $end, $addLink, $postSlug).$caption.'</figure>';
}
@@ -297,15 +297,13 @@
?>
<nav id="<?=$id?>" class="on-this-page index">
- <label>Jump to:
- <button type="button" aria-label="Show Index" title="Show Index" class="toggle" aria-expanded="false">
- <?= jvbIcon('plus-square') ?>
- </button>
- </label>
+ <button type="button" aria-label="Show Index" title="Show Index" class="toggle main" aria-expanded="false">
+ <span>Jump To:</span><?= jvbIcon('plus-square') ?>
+ </button>
<ul>
- <li>
+ <li id="back-to-top">
<a href="#top" title="Back to Top">
- <?= jvbIcon('caret-circle-up') ?>
+ <?= jvbIcon('caret-circle-up') ?><span>Back to Top</span>
</a>
</li>
<?php
@@ -394,13 +392,13 @@
<h2>'.$config['title'].'</h2>';
if ( array_key_exists('description', $config)) {
if (!is_array($config['description'])) {
- $content .= apply_filters('the_content', $config['description']);
+ $content .= jvb_filter_content( $config['description']);
} else {
// foreach ($config['description'] as $desc) {
-// $content .= apply_filters('the_content', $desc);
+// $content .= jvb_filter_content( $desc);
// }
$content .= implode('',array_map(function ($paragraph) {
- return apply_filters('the_content', $paragraph);
+ return jvb_filter_content( $paragraph);
}, $config['description']));
}
--
Gitblit v1.10.0