click-tracking
11 months ago
date-picker
5 months ago
email
9 months ago
examiner
11 months ago
icons
6 months ago
integrations
11 months ago
interrupt
11 months ago
journeys
6 months ago
notices
6 months ago
overview
6 months ago
partials
5 months ago
settings
5 months ago
tables
6 months ago
campaign-builder.blade.php
11 months ago
chart.blade.php
11 months ago
debug.blade.php
11 months ago
plugin-group-options.blade.php
11 months ago
quick-stat-loading.blade.php
11 months ago
quick-stat.blade.php
5 months ago
quick-stats.blade.php
11 months ago
real-time.blade.php
6 months ago
support.blade.php
6 months ago
updates.blade.php
6 months ago
woocommerce-order-meta-box.blade.php
6 months ago
quick-stats.blade.php
39 lines
| 1 | @php /** @var \IAWP\Plugin_Group[] $plugin_groups */ @endphp |
| 2 | @php /** @var \IAWP\Statistics\Statistic[] $statistics */ @endphp |
| 3 | @php /** @var bool $is_dashboard_widget */ @endphp |
| 4 | @php /** @var bool $hide_unfiltered_statistics */ @endphp |
| 5 | |
| 6 | <div id="quick-stats" data-controller="quick-stats" class="<?php echo esc_attr($quick_stats_html_class); ?>"><?php |
| 7 | if (!$is_dashboard_widget) { |
| 8 | echo iawp_blade()->run('plugin-group-options', [ |
| 9 | 'option_type' => 'quick_stats', |
| 10 | 'option_name' => __('Toggle Stats', 'independent-analytics'), |
| 11 | 'option_icon' => 'visibility', |
| 12 | 'plugin_groups' => $plugin_groups, |
| 13 | 'options' => $statistics, |
| 14 | ]); |
| 15 | } ?> |
| 16 | |
| 17 | {{-- Quick stats --}} |
| 18 | <div class="iawp-stats total-of-<?php echo esc_attr($total_stats); ?>"><?php |
| 19 | foreach ($statistics as $statistic) { |
| 20 | if ($is_dashboard_widget && !$statistic->is_visible_in_dashboard_widget()) { |
| 21 | continue; |
| 22 | } |
| 23 | if(!$statistic->is_group_plugin_enabled()) { |
| 24 | continue; |
| 25 | } |
| 26 | echo iawp_blade()->run('quick-stat', [ |
| 27 | 'id' => $statistic->id(), |
| 28 | 'name' => $statistic->name(), |
| 29 | 'formatted_value' => $statistic->formatted_value(), |
| 30 | 'formatted_unfiltered_value' => $hide_unfiltered_statistics ? null : $statistic->formatted_unfiltered_value(), |
| 31 | 'growth' => $statistic->growth(), |
| 32 | 'formatted_growth' => $statistic->formatted_growth(), |
| 33 | 'growth_html_class' => $statistic->growth_html_class(), |
| 34 | 'icon' => $statistic->icon(), |
| 35 | 'is_visible' => $statistic->is_visible() |
| 36 | ]); |
| 37 | } ?> |
| 38 | </div> |
| 39 | </div> |