Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/master' into latest
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickebates committed Sep 11, 2021
2 parents f10f1bd + 90c6205 commit 503c7ab
Show file tree
Hide file tree
Showing 67 changed files with 1,722 additions and 547 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Project Nami
===============

### Version: `2.8.0` ###
### Version: `2.8.1` ###

### Description: ###
[![Deploy to Azure](http://azuredeploy.net/deploybutton.png)](https://deploy.azure.com/?repository=https://github.com/ProjectNami/projectnami/tree/latest)
Expand Down
37 changes: 35 additions & 2 deletions wp-admin/about.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,39 @@

<hr />

<div class="about__section changelog">
<div class="column">
<h2><?php _e( 'Maintenance and Security Releases' ); ?></h2>
<p>
<?php
printf(
/* translators: 1: WordPress version number, 2: plural number of bugs. */
_n(
'<strong>Version %1$s</strong> addressed a security issue and fixed %2$s bug.',
'<strong>Version %1$s</strong> addressed a security issue and fixed %2$s bugs.',
60
),
'5.8.1',
number_format_i18n( 60 )
);
?>
<?php
printf(
/* translators: %s: HelpHub URL */
__( 'For more information, see <a href="%s">the release notes</a>.' ),
sprintf(
/* translators: %s: WordPress version */
esc_url( __( 'https://wordpress.org/support/wordpress-version/version-%s/' ) ),
sanitize_title( '5.8.1' )
)
);
?>
</p>
</div>
</div>

<hr class="is-large" />

<div class="about__section">
<h2 class="aligncenter">
<?php _e( 'Three Essential Powerhouses' ); ?>
Expand Down Expand Up @@ -160,8 +193,8 @@
</h2>
<div class="column about__image is-vertically-aligned-center">
<picture>
<source srcset="https://s.w.org/images/core/5.8/about-theme-json.png, https://s.w.org/images/core/5.8/about-theme-json-2x.png 2x">
<img src="https://s.w.org/images/core/5.8/about-theme-json.png" alt="">
<source srcset="https://s.w.org/images/core/5.8/about-theme-json.png, https://s.w.org/images/core/5.8/about-theme-json-2x.png 2x" />
<img src="https://s.w.org/images/core/5.8/about-theme-json.png" alt="" />
</picture>
</div>
</div>
Expand Down
4 changes: 4 additions & 0 deletions wp-admin/customize.php
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,10 @@
}
$body_class .= ' locale-' . sanitize_html_class( strtolower( str_replace( '_', '-', get_user_locale() ) ) );

if ( wp_use_widgets_block_editor() ) {
$body_class .= ' wp-embed-responsive';
}

$admin_title = sprintf( $wp_customize->get_document_title_template(), __( 'Loading&hellip;' ) );

?>
Expand Down
2 changes: 1 addition & 1 deletion wp-admin/edit-form-blocks.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ function( $classes ) {
* besides the default value.
*/
$available_templates = wp_get_theme()->get_page_templates( get_post( $post->ID ) );
$available_templates = ! empty( $available_templates ) ? array_merge(
$available_templates = ! empty( $available_templates ) ? array_replace(
array(
/** This filter is documented in wp-admin/includes/meta-boxes.php */
'' => apply_filters( 'default_page_template_title', __( 'Default template' ), 'rest-api' ),
Expand Down
4 changes: 3 additions & 1 deletion wp-admin/includes/ajax-actions.php
Original file line number Diff line number Diff line change
Expand Up @@ -3003,7 +3003,9 @@ function wp_ajax_query_attachments() {
$total_posts = $count_query->found_posts;
}

$max_pages = ceil( $total_posts / (int) $attachments_query->query['posts_per_page'] );
$posts_per_page = (int) $attachments_query->query['posts_per_page'];

$max_pages = $posts_per_page ? ceil( $total_posts / $posts_per_page ) : 0;

header( 'X-WP-Total: ' . (int) $total_posts );
header( 'X-WP-TotalPages: ' . (int) $max_pages );
Expand Down
2 changes: 1 addition & 1 deletion wp-admin/includes/class-custom-background.php
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,7 @@ public function admin_page() {
<div class="button-group">
<?php foreach ( $group as $value => $input ) : ?>
<label>
<input class="screen-reader-text" name="background-position" type="radio" value="<?php echo esc_attr( $value ); ?>"<?php checked( $value, $background_position ); ?>>
<input class="ui-helper-hidden-accessible" name="background-position" type="radio" value="<?php echo esc_attr( $value ); ?>"<?php checked( $value, $background_position ); ?>>
<span class="button display-options position"><span class="<?php echo esc_attr( $input['icon'] ); ?>" aria-hidden="true"></span></span>
<span class="screen-reader-text"><?php echo $input['label']; ?></span>
</label>
Expand Down
27 changes: 16 additions & 11 deletions wp-admin/includes/class-pclzip.php
Original file line number Diff line number Diff line change
Expand Up @@ -2674,7 +2674,12 @@ function privAddFile($p_filedescr, &$p_header, &$p_options)
}

// ----- Read the file content
$v_content = @fread($v_file, $p_header['size']);
if ($p_header['size'] > 0) {
$v_content = @fread($v_file, $p_header['size']);
}
else {
$v_content = '';
}

// ----- Close the file
@fclose($v_file);
Expand Down Expand Up @@ -3884,11 +3889,11 @@ function privExtractFile(&$p_entry, $p_path, $p_remove_path, $p_remove_all_path,


// ----- Read the compressed file in a buffer (one shot)
if ( $p_entry['compressed_size'] > 0 ) {
if ($p_entry['compressed_size'] > 0) {
$v_buffer = @fread($this->zip_fd, $p_entry['compressed_size']);
}
else {
$v_buffer = false;
$v_buffer = '';
}

// ----- Decompress the file
Expand Down Expand Up @@ -4101,11 +4106,11 @@ function privExtractFileInOutput(&$p_entry, &$p_options)
if ($p_entry['compressed_size'] == $p_entry['size']) {

// ----- Read the file in a buffer (one shot)
if ( $p_entry['compressed_size'] > 0 ) {
if ($p_entry['compressed_size'] > 0) {
$v_buffer = @fread($this->zip_fd, $p_entry['compressed_size']);
}
else {
$v_buffer = false;
$v_buffer = '';
}

// ----- Send the file to the output
Expand All @@ -4115,11 +4120,11 @@ function privExtractFileInOutput(&$p_entry, &$p_options)
else {

// ----- Read the compressed file in a buffer (one shot)
if ( $p_entry['compressed_size'] > 0 ) {
if ($p_entry['compressed_size'] > 0) {
$v_buffer = @fread($this->zip_fd, $p_entry['compressed_size']);
}
else {
$v_buffer = false;
$v_buffer = '';
}

// ----- Decompress the file
Expand Down Expand Up @@ -4224,21 +4229,21 @@ function privExtractFileAsString(&$p_entry, &$p_string, &$p_options)
if ($p_entry['compression'] == 0) {

// ----- Reading the file
if ( $p_entry['compressed_size'] > 0 ) {
if ($p_entry['compressed_size'] > 0) {
$p_string = @fread($this->zip_fd, $p_entry['compressed_size']);
}
else {
$p_string = false;
$p_string = '';
}
}
else {

// ----- Reading the file
if ( $p_entry['compressed_size'] > 0 ) {
if ($p_entry['compressed_size'] > 0) {
$v_data = @fread($this->zip_fd, $p_entry['compressed_size']);
}
else {
$v_data = false;
$v_data = '';
}

// ----- Decompress the file
Expand Down
2 changes: 2 additions & 0 deletions wp-admin/includes/theme.php
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,7 @@ function get_theme_update_available( $theme ) {
* @since 5.5.0 Added 'Block Editor Patterns', 'Block Editor Styles',
* and 'Full Site Editing' features.
* @since 5.5.0 Added 'Wide Blocks' layout option.
* @since 5.8.1 Added 'Template Editing' feature.
*
* @param bool $api Optional. Whether try to fetch tags from the WordPress.org API. Defaults to true.
* @return array Array of features keyed by category with translations keyed by slug.
Expand Down Expand Up @@ -334,6 +335,7 @@ function get_theme_feature_list( $api = true ) {
'full-width-template' => __( 'Full Width Template' ),
'post-formats' => __( 'Post Formats' ),
'sticky-post' => __( 'Sticky Post' ),
'template-editing' => __( 'Template Editing' ),
'theme-options' => __( 'Theme Options' ),
),

Expand Down
4 changes: 4 additions & 0 deletions wp-admin/includes/update-core.php
Original file line number Diff line number Diff line change
Expand Up @@ -822,6 +822,10 @@
'wp-includes/block-patterns/large-header-button.php',
'wp-includes/blocks/subhead/block.json',
'wp-includes/blocks/subhead',
'wp-includes/css/dist/editor/editor-styles.css',
'wp-includes/css/dist/editor/editor-styles.min.css',
'wp-includes/css/dist/editor/editor-styles-rtl.css',
'wp-includes/css/dist/editor/editor-styles-rtl.min.css',
);

/**
Expand Down
7 changes: 7 additions & 0 deletions wp-admin/js/customize-controls.js
Original file line number Diff line number Diff line change
Expand Up @@ -8452,6 +8452,13 @@
return;
}

// Abort if we're inside of a block editor instance.
if ( event.target.closest( '.block-editor-writing-flow' ) !== null ||
event.target.closest( '.block-editor-block-list__block-popover' ) !== null
) {
return;
}

// Check for expanded expandable controls (e.g. widgets and nav menus items), sections, and panels.
api.control.each( function( control ) {
if ( control.expanded && control.expanded() && _.isFunction( control.collapse ) ) {
Expand Down
2 changes: 1 addition & 1 deletion wp-admin/js/customize-controls.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion wp-admin/js/widgets/custom-html-widgets.js
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ wp.customHtmlWidgets = ( function( $ ) {
return;
}

idBase = widgetForm.find( '> .widget-control-actions > .id_base' ).val();
idBase = widgetForm.find( '.id_base' ).val();
if ( -1 === component.idBases.indexOf( idBase ) ) {
return;
}
Expand Down
2 changes: 1 addition & 1 deletion wp-admin/js/widgets/custom-html-widgets.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion wp-admin/js/widgets/media-widgets.js
Original file line number Diff line number Diff line change
Expand Up @@ -1212,7 +1212,7 @@ wp.mediaWidgets = ( function( $ ) {
return;
}

idBase = widgetForm.find( '> .widget-control-actions > .id_base' ).val();
idBase = widgetForm.find( '.id_base' ).val();

ControlConstructor = component.controlConstructors[ idBase ];
if ( ! ControlConstructor ) {
Expand Down
Loading

0 comments on commit 503c7ab

Please sign in to comment.