-
Notifications
You must be signed in to change notification settings - Fork 566
Context location setup #838
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…wing. May need to fix on the frontend
includes/CMB2_hookup.php
Outdated
| $classes = 'postbox context-' . $cmb->prop( 'context' ) . '-box context-box '; | ||
| $classes .= in_array( $cmb->cmb_id, $hidden ) ? ' hide-if-js' : ''; | ||
| $classes .= postbox_classes( $cmb->cmb_id, $screen->id ); | ||
| $classes = 'postbox context-' . $this->cmb->prop( 'context' ) . '-box context-box postbox-container '; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why did you add the postbox-container class as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The postbox-container class was being used to style the field rows, but I refactored it a bit so that it's not needed. You can see those changes in Update context metabox output to handle no-title or no-wrap better
includes/CMB2_hookup.php
Outdated
| // Call our before hook. | ||
| if ( ! empty( $this->cmb->prop( 'title' ) ) ) { | ||
| $this::context_box_title_markup_open( $this->cmb ); | ||
| $this->context_box_title_markup_open( $this->cmb ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if you're not going to use the $cmb variable passed in the function, can be removed from here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Changes proposed in this pull request