Changeset 9390
- Timestamp:
- 01/10/2020 10:29:25 PM (5 years ago)
- Location:
- sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/comments.php
r9325 r9390 64 64 <?php if ( \DevHub\is_parsed_post_type() && DevHub\can_user_post_note( true, get_the_ID() ) ) : ?> 65 65 66 <?php if ( is_user_logged_in() ) : ?>67 <?php68 /* Hide the add user note link by default.69 * It will be displayed by Javascript.70 * If Javascript is disabled the comment form is displayed and the link stays hidden.71 */72 ?>73 <p id="add-user-note" style="display: none;"><a href="<?php echo user_trailingslashit( get_permalink() ) . '#respond'; ?>"><?php _e( 'Have a note or feedback to contribute?', 'wporg' ); ?></a></p>74 <?php endif; ?>75 76 66 <?php 77 67 if ( class_exists( 'DevHub_User_Submitted_Content' ) ) { -
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/js/user-notes-preview.js
r7754 r9390 72 72 73 73 // Set preview heigth when the textarea is visible 74 $( ' #add-user-note,.table-of-contents a[href="#add-note-or-feedback"]' ).click( function( e ) {74 $( '.table-of-contents a[href="#add-note-or-feedback"]' ).click( function( e ) { 75 75 e.preventDefault(); 76 76 tabs.parents( '.tablist' ).show(); -
sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-developer/js/user-notes.js
r7754 r9390 7 7 8 8 var commentForm = $( '.comment-form textarea' ); 9 var add_user_note = $( '#add-user-note' );10 9 var commentID = window.location.hash; 11 10 var wpAdminBar = 0; … … 53 52 54 53 function showCommentForm() { 55 if( add_user_note.length ) {56 add_user_note.hide();57 }58 59 $( '#respond' ).show();60 61 54 var target = $( '#commentform #add-note-or-feedback' ); 62 55 if ( target.length ) { … … 75 68 } 76 69 77 if( add_user_note.length ) { 78 add_user_note.show(); 79 80 // Hide by default if #add-user-note exists 81 $( '#respond' ).hide(); 82 } 83 84 $( '#add-user-note, .table-of-contents a[href="#add-note-or-feedback"]' ).click( function( e ) { 70 $( '.table-of-contents a[href="#add-note-or-feedback"]' ).click( function( e ) { 85 71 e.preventDefault(); 86 72 showCommentForm();
Note: See TracChangeset
for help on using the changeset viewer.