-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into try/block-mover-appear-on-delay
- Loading branch information
Showing
80 changed files
with
239 additions
and
154 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
## Master | ||
## 4.5.0 (2019-08-29) | ||
|
||
### Bug Fixes | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
export default function save( { attributes } ) { | ||
/** | ||
* WordPress dependencies | ||
*/ | ||
import { | ||
InnerBlocks, | ||
} from '@wordpress/block-editor'; | ||
|
||
export default function save() { | ||
return ( | ||
<a | ||
href={ attributes.destination } | ||
rel={ attributes.nofollow && 'nofollow' } | ||
title={ attributes.title } | ||
target={ attributes.opensInNewTab && '_blank' } | ||
> | ||
{ attributes.label } | ||
</a> | ||
<InnerBlocks.Content /> | ||
); | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
<?php | ||
/** | ||
* Server-side rendering of the `core/navigation-menu` block. | ||
* | ||
* @package gutenberg | ||
*/ | ||
|
||
/** | ||
* Renders the `core/navigation-menu` block on server. | ||
* | ||
* @param array $attributes The block attributes. | ||
* @param array $content The saved content. | ||
* @param array $block The parsed block. | ||
* | ||
* @return string Returns the post content with the legacy widget added. | ||
*/ | ||
function render_block_navigation_menu( $attributes, $content, $block ) { | ||
return '<nav className="wp-block-navigation-menu">' . build_navigation_menu_html( $block ) . '</nav>'; | ||
} | ||
|
||
/** | ||
* Walks the inner block structure and returns an HTML list for it. | ||
* | ||
* @param array $block The block. | ||
* | ||
* @return string Returns an HTML list from innerBlocks. | ||
*/ | ||
function build_navigation_menu_html( $block ) { | ||
$html = ''; | ||
foreach ( (array) $block['innerBlocks'] as $key => $menu_item ) { | ||
$html .= '<li class="wp-block-navigation-menu-item"><a class="wp-block-navigation-menu-item"'; | ||
if ( isset( $menu_item['attrs']['destination'] ) ) { | ||
$html .= ' href="' . $menu_item['attrs']['destination'] . '"'; | ||
} | ||
if ( isset( $menu_item['attrs']['title'] ) ) { | ||
$html .= ' title="' . $menu_item['attrs']['title'] . '"'; | ||
} | ||
$html .= '>'; | ||
if ( isset( $menu_item['attrs']['label'] ) ) { | ||
$html .= $menu_item['attrs']['label']; | ||
} | ||
$html .= '</a>'; | ||
|
||
if ( count( (array) $menu_item['innerBlocks'] ) > 0 ) { | ||
$html .= build_navigation_menu_html( $menu_item ); | ||
} | ||
|
||
$html .= '</li>'; | ||
} | ||
return '<ul>' . $html . '</ul>'; | ||
} | ||
|
||
/** | ||
* Register the navigation menu block. | ||
*/ | ||
function register_block_core_navigation_menu() { | ||
register_block_type( | ||
'core/navigation-menu', | ||
array( | ||
'category' => 'layout', | ||
'attributes' => array( | ||
'automaticallyAdd' => array( | ||
'type' => 'boolean', | ||
'default' => false, | ||
), | ||
), | ||
'render_callback' => 'render_block_navigation_menu', | ||
) | ||
); | ||
} | ||
|
||
add_action( 'init', 'register_block_core_navigation_menu' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ | |
} | ||
|
||
.editor-video-poster-control .components-button { | ||
display: block; | ||
margin-right: 8px; | ||
} | ||
|
||
|
Oops, something went wrong.