Plugin Directory

Changeset 3445048


Ignore:
Timestamp:
01/22/2026 05:19:34 PM (4 weeks ago)
Author:
wpcoder75
Message:

new widget notice remove

Location:
daily-slider
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • daily-slider/tags/2.6.0/admin/welcome-page.php

    r3445042 r3445048  
    7575                </div>
    7676            </div>
    77 
    78             <?php self::render_new_widget_notice(); ?>
    7977
    8078            <div class="ds-grid">
     
    219217    }
    220218
    221     private static function render_new_widget_notice()
    222     {
    223         // Check if user has seen this notice (you can implement this with user meta)
    224         $notice_dismissed = get_user_meta(get_current_user_id(), 'daily_slider_testimonials_notice_dismissed', true);
    225 
    226         if ($notice_dismissed) {
    227             return;
    228         }
    229     ?>
    230         <div class="daily-slider-notice-container">
    231             <div class="new-widget-notice">
    232                 <div class="notice-content">
    233                     <div class="notice-icon">
    234                         <span class="dashicons dashicons-star-filled"></span>
    235                     </div>
    236                     <div class="notice-text">
    237                         <h3><?php _e('New Widget Added!', 'daily-slider'); ?></h3>
    238                         <p><?php _e('Introducing the <span class="highlight-widget-name">Testimonials Marquee</span> widget - showcase customer reviews with star ratings, author profiles, and smooth scrolling animations. Perfect for building trust and social proof!', 'daily-slider'); ?></p>
    239                     </div>
    240                     <div class="notice-actions">
    241                         <a href="<?php echo admin_url('admin.php?page=daily-slider-widgets'); ?>" class="notice-btn primary">
    242                             <?php _e('Enable Widget', 'daily-slider'); ?>
    243                         </a>
    244                         <button type="button" class="notice-btn secondary dismiss-notice" data-widget="testimonials">
    245                             <?php _e('Dismiss', 'daily-slider'); ?>
    246                         </button>
    247                     </div>
    248                 </div>
    249             </div>
    250         </div>
    251     <?php
    252     }
     219
    253220
    254221    private static function render_quick_actions()
     
    813780            }
    814781
    815             /* New Widget Notice Styles */
    816             .daily-slider-notice-container {
    817                 margin: 0 0 16px;
    818             }
    819 
    820             .new-widget-notice {
    821                 background: linear-gradient(135deg, #a855f7 0%, #7c3aed 100%);
    822                 border-radius: 6px;
    823                 padding: 24px;
    824                 margin-bottom: 20px;
    825                 box-shadow: 0 6px 18px rgba(124, 58, 237, 0.25);
    826                 border: 1px solid rgba(255, 255, 255, 0.2);
    827             }
    828 
    829             .notice-content {
    830                 display: flex;
    831                 align-items: center;
    832                 justify-content: center;
    833                 gap: 20px;
    834                 text-align: left;
    835             }
    836 
    837             .notice-icon {
    838                 background: rgba(255, 255, 255, 0.3);
    839                 border-radius: 50%;
    840                 width: 60px;
    841                 height: 60px;
    842                 display: flex;
    843                 align-items: center;
    844                 justify-content: center;
    845                 flex-shrink: 0;
    846                 margin: 0 auto;
    847             }
    848 
    849             .notice-icon .dashicons {
    850                 color: #ffffff;
    851                 font-size: 28px;
    852                 display: block;
    853                 width: 28px;
    854                 height: 28px;
    855             }
    856 
    857             .notice-text {
    858                 flex: 1;
    859                 color: white;
    860             }
    861 
    862             .notice-text h3 {
    863                 margin: 0 0 8px 0;
    864                 font-size: 18px;
    865                 font-weight: 600;
    866                 color: white;
    867             }
    868 
    869             .notice-text p {
    870                 margin: 0;
    871                 line-height: 1.5;
    872                 opacity: 0.95;
    873             }
    874 
    875             .highlight-widget-name {
    876                 background: rgba(255, 255, 255, 0.18);
    877                 color: #ffffff;
    878                 padding: 2px 8px;
    879                 border-radius: 4px;
    880                 font-weight: 700;
    881                 border: 1px solid rgba(255, 255, 255, 0.28);
    882                 font-style: normal;
    883                 text-shadow: 0 0 8px rgba(255, 255, 255, 0.12);
    884             }
    885 
    886             .notice-actions {
    887                 display: flex;
    888                 gap: 12px;
    889                 flex-shrink: 0;
    890             }
    891 
    892             .notice-btn {
    893                 padding: 8px 16px;
    894                 border-radius: 6px;
    895                 text-decoration: none;
    896                 font-weight: 500;
    897                 font-size: 14px;
    898                 border: none;
    899                 cursor: pointer;
    900                 transition: all 0.3s ease;
    901             }
    902 
    903             .notice-btn.primary {
    904                 background: rgba(255, 255, 255, 0.9);
    905                 color: #7c3aed;
    906             }
    907 
    908             .notice-btn.primary:hover {
    909                 background: white;
    910                 transform: translateY(-1px);
    911             }
    912 
    913             .notice-btn.secondary {
    914                 background: rgba(255, 255, 255, 0.2);
    915                 color: white;
    916                 border: 1px solid rgba(255, 255, 255, 0.3);
    917             }
    918 
    919             .notice-btn.secondary:hover {
    920                 background: rgba(255, 255, 255, 0.3);
    921             }
     782
    922783
    923784            @media (max-width: 768px) {
     
    938799                }
    939800
    940                 .notice-content {
    941                     flex-direction: column;
    942                     text-align: center;
    943                 }
    944 
    945                 .notice-actions {
    946                     width: 100%;
    947                     justify-content: center;
    948                 }
     801
    949802            }
    950803
  • daily-slider/trunk/admin/welcome-page.php

    r3445042 r3445048  
    7575                </div>
    7676            </div>
    77 
    78             <?php self::render_new_widget_notice(); ?>
    7977
    8078            <div class="ds-grid">
     
    219217    }
    220218
    221     private static function render_new_widget_notice()
    222     {
    223         // Check if user has seen this notice (you can implement this with user meta)
    224         $notice_dismissed = get_user_meta(get_current_user_id(), 'daily_slider_testimonials_notice_dismissed', true);
    225 
    226         if ($notice_dismissed) {
    227             return;
    228         }
    229     ?>
    230         <div class="daily-slider-notice-container">
    231             <div class="new-widget-notice">
    232                 <div class="notice-content">
    233                     <div class="notice-icon">
    234                         <span class="dashicons dashicons-star-filled"></span>
    235                     </div>
    236                     <div class="notice-text">
    237                         <h3><?php _e('New Widget Added!', 'daily-slider'); ?></h3>
    238                         <p><?php _e('Introducing the <span class="highlight-widget-name">Testimonials Marquee</span> widget - showcase customer reviews with star ratings, author profiles, and smooth scrolling animations. Perfect for building trust and social proof!', 'daily-slider'); ?></p>
    239                     </div>
    240                     <div class="notice-actions">
    241                         <a href="<?php echo admin_url('admin.php?page=daily-slider-widgets'); ?>" class="notice-btn primary">
    242                             <?php _e('Enable Widget', 'daily-slider'); ?>
    243                         </a>
    244                         <button type="button" class="notice-btn secondary dismiss-notice" data-widget="testimonials">
    245                             <?php _e('Dismiss', 'daily-slider'); ?>
    246                         </button>
    247                     </div>
    248                 </div>
    249             </div>
    250         </div>
    251     <?php
    252     }
     219
    253220
    254221    private static function render_quick_actions()
     
    813780            }
    814781
    815             /* New Widget Notice Styles */
    816             .daily-slider-notice-container {
    817                 margin: 0 0 16px;
    818             }
    819 
    820             .new-widget-notice {
    821                 background: linear-gradient(135deg, #a855f7 0%, #7c3aed 100%);
    822                 border-radius: 6px;
    823                 padding: 24px;
    824                 margin-bottom: 20px;
    825                 box-shadow: 0 6px 18px rgba(124, 58, 237, 0.25);
    826                 border: 1px solid rgba(255, 255, 255, 0.2);
    827             }
    828 
    829             .notice-content {
    830                 display: flex;
    831                 align-items: center;
    832                 justify-content: center;
    833                 gap: 20px;
    834                 text-align: left;
    835             }
    836 
    837             .notice-icon {
    838                 background: rgba(255, 255, 255, 0.3);
    839                 border-radius: 50%;
    840                 width: 60px;
    841                 height: 60px;
    842                 display: flex;
    843                 align-items: center;
    844                 justify-content: center;
    845                 flex-shrink: 0;
    846                 margin: 0 auto;
    847             }
    848 
    849             .notice-icon .dashicons {
    850                 color: #ffffff;
    851                 font-size: 28px;
    852                 display: block;
    853                 width: 28px;
    854                 height: 28px;
    855             }
    856 
    857             .notice-text {
    858                 flex: 1;
    859                 color: white;
    860             }
    861 
    862             .notice-text h3 {
    863                 margin: 0 0 8px 0;
    864                 font-size: 18px;
    865                 font-weight: 600;
    866                 color: white;
    867             }
    868 
    869             .notice-text p {
    870                 margin: 0;
    871                 line-height: 1.5;
    872                 opacity: 0.95;
    873             }
    874 
    875             .highlight-widget-name {
    876                 background: rgba(255, 255, 255, 0.18);
    877                 color: #ffffff;
    878                 padding: 2px 8px;
    879                 border-radius: 4px;
    880                 font-weight: 700;
    881                 border: 1px solid rgba(255, 255, 255, 0.28);
    882                 font-style: normal;
    883                 text-shadow: 0 0 8px rgba(255, 255, 255, 0.12);
    884             }
    885 
    886             .notice-actions {
    887                 display: flex;
    888                 gap: 12px;
    889                 flex-shrink: 0;
    890             }
    891 
    892             .notice-btn {
    893                 padding: 8px 16px;
    894                 border-radius: 6px;
    895                 text-decoration: none;
    896                 font-weight: 500;
    897                 font-size: 14px;
    898                 border: none;
    899                 cursor: pointer;
    900                 transition: all 0.3s ease;
    901             }
    902 
    903             .notice-btn.primary {
    904                 background: rgba(255, 255, 255, 0.9);
    905                 color: #7c3aed;
    906             }
    907 
    908             .notice-btn.primary:hover {
    909                 background: white;
    910                 transform: translateY(-1px);
    911             }
    912 
    913             .notice-btn.secondary {
    914                 background: rgba(255, 255, 255, 0.2);
    915                 color: white;
    916                 border: 1px solid rgba(255, 255, 255, 0.3);
    917             }
    918 
    919             .notice-btn.secondary:hover {
    920                 background: rgba(255, 255, 255, 0.3);
    921             }
     782
    922783
    923784            @media (max-width: 768px) {
     
    938799                }
    939800
    940                 .notice-content {
    941                     flex-direction: column;
    942                     text-align: center;
    943                 }
    944 
    945                 .notice-actions {
    946                     width: 100%;
    947                     justify-content: center;
    948                 }
     801
    949802            }
    950803
Note: See TracChangeset for help on using the changeset viewer.