PluginProbe
Visualizer – Tables & Charts Manager with Built-in AI Generator / 3.7.9
Visualizer – Tables & Charts Manager with Built-in AI Generator v3.7.9
4.0.8 4.0.7 4.0.6 4.0.5 4.0.4 4.0.3 3.0.5 3.0.6 3.0.7 3.0.8 3.0.9 3.1.0 3.1.1 3.1.2 3.1.3 3.10.0 3.10.1 3.10.10 3.10.11 3.10.12 3.10.13 3.10.14 3.10.15 3.10.2 3.10.3 All 149 releases
← All changes | vendor/codeinwp/themeisle-sdk/src/Modules/Notification.php +1 -24 4.0.83.7.9 View file →
@@ -255,9 +255,8 @@
255 255 public static function get_notification_html( $notification_details ) {
256 256 $default = [
257 257 'id' => '',
258 258 'heading' => '',
259 - 'img_src' => '',
260 259 'message' => '',
261 260 'ctas' => [
262 261 'confirm' => [
263 262 'link' => '#',
@@ -267,28 +266,19 @@
267 266 'link' => '#',
268 267 'text' => '',
269 268 ],
270 269 ],
271 - 'type' => 'success',
272 270 ];
273 271 $notification_details = wp_parse_args( $notification_details, $default );
274 272 global $pagenow;
275 - $type = in_array( $notification_details['type'], [ 'success', 'info', 'warning', 'error' ], true ) ? $notification_details['type'] : 'success';
276 273 $notification_details['ctas']['cancel']['link'] = wp_nonce_url( add_query_arg( [ 'nid' => $notification_details['id'] ], admin_url( $pagenow ) ), $notification_details['id'], 'tsdk_dismiss_nonce' );
277 - $notification_html = '<div class="notice notice-' . $type . ' is-dismissible themeisle-sdk-notice" data-notification-id="' . esc_attr( $notification_details['id'] ) . '" id="' . esc_attr( $notification_details['id'] ) . '-notification"> <div class="themeisle-sdk-notification-box">';
274 + $notification_html = '<div class="notice notice-success is-dismissible themeisle-sdk-notice" data-notification-id="' . esc_attr( $notification_details['id'] ) . '" id="' . esc_attr( $notification_details['id'] ) . '-notification"> <div class="themeisle-sdk-notification-box">';
278 275
279 276 if ( ! empty( $notification_details['heading'] ) ) {
280 277 $notification_html .= sprintf( '<h4>%s</h4>', wp_kses_post( $notification_details['heading'] ) );
281 278 }
282 - if ( ! empty( $notification_details['img_src'] ) ) {
283 - $notification_html .= '<div class="wrap-flex">';
284 - $notification_html .= sprintf( '<img src="%s" alt="%s" />', esc_attr( $notification_details['img_src'] ), esc_attr( $notification_details['heading'] ) );
285 - }
286 279 if ( ! empty( $notification_details['message'] ) ) {
287 280 $notification_html .= wp_kses_post( $notification_details['message'] );
288 - if ( ! empty( $notification_details['img_src'] ) ) {
289 - $notification_html .= '</div>';
290 - }
291 281 }
292 282 $notification_html .= '<div class="actions">';
293 283
294 284 if ( ! empty( $notification_details['ctas']['confirm']['text'] ) ) {
@@ -326,20 +316,8 @@
326 316 .themeisle-sdk-notification-box {
327 317 padding: 3px;
328 318 }
329 319
330 - .themeisle-sdk-notification-box .wrap-flex {
331 - display: flex;
332 - align-items: center;
333 - justify-content: start;
334 - gap: 12px;
335 - }
336 -
337 - .themeisle-sdk-notification-box .wrap-flex img {
338 - width: 42px;
339 - object-fit: cover;
340 - }
341 -
342 320 .themeisle-sdk-notification-box .actions {
343 321 margin-top: 6px;
344 322 margin-bottom: 4px;
345 323 }
@@ -398,9 +376,8 @@
398 376
399 377 if ( empty( $id ) ) {
400 378 wp_send_json( [] );
401 379 }
402 - self::setup_notifications();
403 380 $ids = wp_list_pluck( self::$notifications, 'id' );
404 381 if ( ! in_array( $id, $ids, true ) ) {
405 382 wp_send_json( [] );
406 383 }