summaryrefslogtreecommitdiffstats
path: root/wp-includes/blocks/legacy-widget.php
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:51:18 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-09-19 04:51:18 +0000
commit0e41b5d52fdc6af6442816b5f465c9db9f84e126 (patch)
treee139a90049b158d4eed892d1662ee7f5c358fa31 /wp-includes/blocks/legacy-widget.php
parentAdding upstream version 6.5.5+dfsg1. (diff)
downloadwordpress-0e41b5d52fdc6af6442816b5f465c9db9f84e126.tar.xz
wordpress-0e41b5d52fdc6af6442816b5f465c9db9f84e126.zip
Adding upstream version 6.6.1+dfsg1.upstream/6.6.1+dfsg1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'wp-includes/blocks/legacy-widget.php')
-rw-r--r--wp-includes/blocks/legacy-widget.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/wp-includes/blocks/legacy-widget.php b/wp-includes/blocks/legacy-widget.php
index 94cfb9b..ee13ae9 100644
--- a/wp-includes/blocks/legacy-widget.php
+++ b/wp-includes/blocks/legacy-widget.php
@@ -8,6 +8,10 @@
/**
* Renders the 'core/legacy-widget' block.
*
+ * @since 5.8.0
+ *
+ * @global int $wp_widget_factory.
+ *
* @param array $attributes The block attributes.
*
* @return string Rendered block.
@@ -54,6 +58,8 @@ function render_block_core_legacy_widget( $attributes ) {
/**
* Registers the 'core/legacy-widget' block.
+ *
+ * @since 5.8.0
*/
function register_block_core_legacy_widget() {
register_block_type_from_metadata(
@@ -70,6 +76,8 @@ add_action( 'init', 'register_block_core_legacy_widget' );
* Intercepts any request with legacy-widget-preview in the query param and, if
* set, renders a page containing a preview of the requested Legacy Widget
* block.
+ *
+ * @since 5.8.0
*/
function handle_legacy_widget_preview_iframe() {
if ( empty( $_GET['legacy-widget-preview'] ) ) {