PluginProbe
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) / 1.8.13
Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) v1.8.13
1.8.13 1.8.12.3 1.8.12.2 1.8.12.1 1.8.12 1.8.11.3 1.8.11.2 1.8.11.1 1.8.11 1.6.6 1.6.60 1.6.7 1.6.8 1.6.9 1.7.0 1.7.0.1 1.7.0.11 1.7.0.12 1.7.0.14 1.7.0.2 1.7.0.3 1.7.0.5 1.7.0.6 1.7.0.7 1.7.0.9 All 211 releases
charitable / includes / admin / templates / notifications-dashboard.php

notifications-dashboard.php in Charitable – Donation & Fundraising Platform (Donation Forms, Recurring Donations & Fundraising Campaigns) 1.8.13, at includes/admin/templates/notifications-dashboard.php

54 lines 2.8 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Admin Notifications template.
4 *
5 * @since 1.8.3
6 * @version 1.8.8.6
7 *
8 * @package Charitable/Admin/Templates
9 * @var array $notifications
10 */
11
12 if ( ! defined( 'ABSPATH' ) ) {
13 exit;
14 }
15
16 $charitable_active_count = intval( $args['notifications']['active_count'] );
17 $charitable_active_count_string = esc_html( $args['notifications']['active_count'] );
18 $charitable_remaining_active_count = $charitable_active_count > 4 ? $charitable_active_count - 3 : 0;
19 $charitable_dismissed_count = intval( $args['notifications']['dismissed_count'] );
20 $charitable_no_items_css = ( $charitable_active_count > 0 ) ? 'charitable-hidden' : '';
21 $charitable_yes_items_css = ( $charitable_active_count === 0 ) ? 'charitable-hidden' : '';
22 $charitable_notifications_title = $charitable_active_count > 1 ? esc_html__( 'New Notifications', 'charitable' ) : esc_html__( 'New Notification', 'charitable' );
23
24 ?>
25
26
27 <div class="charitable-container charitable-report-card charitable-dashboard-notifications">
28 <div class="header">
29 <?php if ( $charitable_active_count ) : ?>
30 <h4>(<span id="new-notifications-count-dashboard"><?php echo esc_html( $charitable_active_count_string ); ?></span>) <?php echo esc_html( $charitable_notifications_title ); ?></h4>
31 <?php else : ?>
32 <h4><?php echo esc_html__( 'Notifications', 'charitable' ); ?></h4>
33 <?php endif; ?>
34
35 <a href="#" class="charitable-toggle"><i class="fa fa-angle-down charitable-angle-down"></i></a>
36 </div>
37 <div class="charitable-toggle-container charitable-report-ui">
38 <div class="no-items <?php echo esc_attr( $charitable_no_items_css ); ?>">
39 <p><strong><?php echo esc_html__( 'There are currently no active notifications.', 'charitable' ); ?></strong></p>
40 <p class="link charitable-view-notifications"><a href="#"><?php echo esc_html__( 'View Notifications', 'charitable' ); ?><img src="<?php echo charitable()->get_path( 'assets', false ) . 'images/icons/east.svg'; // phpcs:ignore ?>" /></a></p>
41 </div>
42 <div class="the-list <?php echo esc_attr( $charitable_yes_items_css ); ?>">
43 <?php echo $args['notifications']['active_html']; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped ?>
44 </div>
45 </div>
46 <div class="more">
47 <?php if ( $charitable_remaining_active_count ) : ?>
48 <a href="#"><?php wp_sprintf( 'You have %d more notifications', $charitable_remaining_active_count ); ?><img src="<?php echo charitable()->get_path( 'assets', false ) . 'images/icons/east.svg'; // phpcs:ignore ?>" /></a>
49 <?php elseif ( $charitable_active_count > 0 || $charitable_dismissed_count > 0 ) : ?>
50 <a href="#"><?php esc_html_e( 'View Notifications', 'charitable' ); ?><img src="<?php echo charitable()->get_path( 'assets', false ) . 'images/icons/east.svg'; // phpcs:ignore ?>" /></a>
51 <?php endif; ?>
52 </div>
53
54 </div>