← All changes
|
widgets/widget-mainwp-client-overview-custom-info.php
+23
-18
5.2
→
6.2.2
View file →
| @@ -8,8 +8,13 @@ | ||
| 8 | 8 | */ |
| 9 | 9 | |
| 10 | 10 | namespace MainWP\Dashboard; |
| 11 | 11 | |
| 12 | +// Exit if accessed directly. | |
| 13 | +if ( ! defined( 'ABSPATH' ) ) { | |
| 14 | + exit; | |
| 15 | +} | |
| 16 | + | |
| 12 | 17 | /** |
| 13 | 18 | * Class MainWP_Client_Overview_Custom_Info |
| 14 | 19 | * |
| 15 | 20 | * Displays the Client Custom info. |
| @@ -49,23 +54,23 @@ | ||
| 49 | 54 | $client_info = MainWP_DB_Client::instance()->get_wp_client_by( 'client_id', $client_id, ARRAY_A ); |
| 50 | 55 | $default_client_fields = MainWP_Client_Handler::get_default_client_fields(); |
| 51 | 56 | ?> |
| 52 | 57 | <div class="mainwp-widget-header"> |
| 53 | - <h3 class="ui header handle-drag"> | |
| 54 | - <?php | |
| 55 | - /** | |
| 56 | - * Filter: mainwp_clients_overview_info_widget_title | |
| 57 | - * | |
| 58 | - * Filters the Site info widget title text. | |
| 59 | - * | |
| 60 | - * @param object $client_info Object containing the child site info. | |
| 61 | - * | |
| 62 | - * @since 4.1 | |
| 63 | - */ | |
| 64 | - echo esc_html( apply_filters( 'mainwp_clients_overview_info_widget_title', esc_html__( 'Additional Client Info', 'mainwp' ), $client_info ) ); | |
| 65 | - ?> | |
| 66 | - <div class="sub header"></div> | |
| 67 | - </h3> | |
| 58 | + <h2 class="ui header handle-drag"> | |
| 59 | + <?php | |
| 60 | + /** | |
| 61 | + * Filter: mainwp_clients_overview_info_widget_title | |
| 62 | + * | |
| 63 | + * Filters the Site info widget title text. | |
| 64 | + * | |
| 65 | + * @param object $client_info Object containing the child site info. | |
| 66 | + * | |
| 67 | + * @since 4.1 | |
| 68 | + */ | |
| 69 | + echo esc_html( apply_filters( 'mainwp_clients_overview_info_widget_title', esc_html__( 'Additional Client Info', 'mainwp' ), $client_info ) ); | |
| 70 | + ?> | |
| 71 | + <div class="sub header"></div> | |
| 72 | + </h2> | |
| 68 | 73 | </div> |
| 69 | 74 | <div class="mainwp-widget-client-card mainwp-scrolly-overflow"> |
| 70 | 75 | <?php |
| 71 | 76 | /** |
| @@ -82,9 +87,9 @@ | ||
| 82 | 87 | <?php |
| 83 | 88 | if ( $client_info ) { |
| 84 | 89 | $custom_fields = MainWP_DB_Client::instance()->get_client_fields( true, $client_id ); |
| 85 | 90 | ?> |
| 86 | - <table class="ui table"> | |
| 91 | + <table class="ui very compact mini table"> | |
| 87 | 92 | <tbody> |
| 88 | 93 | <?php |
| 89 | 94 | /** |
| 90 | 95 | * Action: mainwp_clients_overview_info_table_top |
| @@ -139,9 +144,9 @@ | ||
| 139 | 144 | </tbody> |
| 140 | 145 | </table> |
| 141 | 146 | <?php |
| 142 | 147 | } else { |
| 143 | - MainWP_UI::render_empty_element_placeholder(); | |
| 148 | + MainWP_UI::render_empty_element_placeholder( __( 'No Custom Client Info yet', 'mainwp' ), __( 'Create custom fields to capture additional information about your clients.', 'mainwp' ), '<em data-emoji=":pencil:" class="medium"></em>' ); | |
| 144 | 149 | } |
| 145 | 150 | ?> |
| 146 | 151 | <?php |
| 147 | 152 | /** |
| @@ -156,9 +161,9 @@ | ||
| 156 | 161 | do_action( 'mainwp_clients_overview_info_widget_bottom', $client_info ); |
| 157 | 162 | ?> |
| 158 | 163 | </div> |
| 159 | 164 | <div class="ui two columns grid mainwp-widget-footer"> |
| 160 | - <div class="column"><a href="admin.php?page=ClientAddField" title="" class="ui button basic green"><?php echo esc_html__( 'Add Custom Client Info', 'mainwp' ); ?></a></div> | |
| 165 | + <div class="column"><a href="admin.php?page=ClientAddField" title="" class="ui mini basic button"><?php echo esc_html__( 'Add Custom Client Info', 'mainwp' ); ?></a></div> | |
| 161 | 166 | <div class="column"></div> |
| 162 | 167 | </div> |
| 163 | 168 | <?php |
| 164 | 169 | } |