Making WordPress.org

Ticket #4383: 4383.diff

File 4383.diff, 1.9 KB (added by dufresnesteven, 5 years ago)
  • wordpress.org/public_html/wp-content/plugins/plugin-directory/shortcodes/class-reviews.php

    diff --git wordpress.org/public_html/wp-content/plugins/plugin-directory/shortcodes/class-reviews.php wordpress.org/public_html/wp-content/plugins/plugin-directory/shortcodes/class-reviews.php
    index 9e96d40ac..92930a8ca 100644
    class Reviews { 
    2020                $review_count = array_sum( $ratings );
    2121
    2222                if ( empty( $reviews ) ) {
    23                         return '';
     23                        if( is_user_logged_in() ) {
     24                                return sprintf(
     25                                        '<div class="notice notice-warning notice-alt"><p>%s</p></div>',
     26                                        __( 'There are no reviews for this plugin.', 'wporg-plugins' )
     27                                );
     28                        }
     29
     30                        return sprintf(
     31                                /* translators: %s: login URL */
     32                                __( '<div class="notice notice-warning notice-alt"><p>There are no reviews for this plugin. <a href="%s" rel="nofollow" title="Log in to Wordpress.org">Log in</a> to submit a review.</p></div>', 'wporg-forums' ),
     33                                add_query_arg(
     34                                        'redirect_to',
     35                                        urlencode( esc_url_raw( sprintf( 'https://wordpress.org/support/plugin/%s/reviews/#new-post', get_post()->post_name ) ) ),
     36                                        'https://login.wordpress.org/'
     37                                )
     38                        );
    2439                }
    2540
    2641                ob_start();
  • wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/client/styles/objects/_notices.scss

    diff --git wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/client/styles/objects/_notices.scss wordpress.org/public_html/wp-content/themes/pub/wporg-plugins/client/styles/objects/_notices.scss
    index d7b40f316..8dab9eed0 100644
     
    99                font-size: ms( -2 );
    1010                margin: 0.5em 0;
    1111                padding: 2px;
     12
     13                /* wp4.css is setting a border bottom on anchor tags in paragraphs tags... The notice block requires a paragraph tag */
     14                a {
     15                        border-bottom: 0;
     16                }
    1217        }
    1318
    1419        &.notice-alt {