PK ! +) ) code/editor-rtl.cssnu [ .wp-block-code code{
background:none;
}PK ! +) ) code/editor.cssnu [ .wp-block-code code{
background:none;
}PK ! Òy| | code/block.jsonnu [ {
"$schema": "https://schemas.wp.org/trunk/block.json",
"apiVersion": 3,
"name": "core/code",
"title": "Code",
"category": "text",
"description": "Display code snippets that respect your spacing and tabs.",
"textdomain": "default",
"attributes": {
"content": {
"type": "rich-text",
"source": "rich-text",
"selector": "code",
"__unstablePreserveWhiteSpace": true
}
},
"supports": {
"align": [ "wide" ],
"anchor": true,
"typography": {
"fontSize": true,
"lineHeight": true,
"__experimentalFontFamily": true,
"__experimentalFontWeight": true,
"__experimentalFontStyle": true,
"__experimentalTextTransform": true,
"__experimentalTextDecoration": true,
"__experimentalLetterSpacing": true,
"__experimentalDefaultControls": {
"fontSize": true
}
},
"spacing": {
"margin": [ "top", "bottom" ],
"padding": true,
"__experimentalDefaultControls": {
"margin": false,
"padding": false
}
},
"__experimentalBorder": {
"radius": true,
"color": true,
"width": true,
"style": true,
"__experimentalDefaultControls": {
"width": true,
"color": true
}
},
"color": {
"text": true,
"background": true,
"gradients": true,
"__experimentalDefaultControls": {
"background": true,
"text": true
}
},
"interactivity": {
"clientNavigation": true
}
},
"style": "wp-block-code"
}
PK ! EO code/style-rtl.min.cssnu [ .wp-block-code{box-sizing:border-box}.wp-block-code code{display:block;font-family:inherit;overflow-wrap:break-word;white-space:pre-wrap}PK ! a8 code/style-rtl.cssnu [ .wp-block-code{
box-sizing:border-box;
}
.wp-block-code code{
display:block;
font-family:inherit;
overflow-wrap:break-word;
white-space:pre-wrap;
}PK ! ؊Kt t code/theme.min.cssnu [ .wp-block-code{border:1px solid #ccc;border-radius:4px;font-family:Menlo,Consolas,monaco,monospace;padding:.8em 1em}PK ! kvЂ code/theme.cssnu [ .wp-block-code{
border:1px solid #ccc;
border-radius:4px;
font-family:Menlo,Consolas,monaco,monospace;
padding:.8em 1em;
}PK ! ؊Kt t code/theme-rtl.min.cssnu [ .wp-block-code{border:1px solid #ccc;border-radius:4px;font-family:Menlo,Consolas,monaco,monospace;padding:.8em 1em}PK ! pw$ $ code/editor.min.cssnu [ .wp-block-code code{background:none}PK ! pw$ $ code/editor-rtl.min.cssnu [ .wp-block-code code{background:none}PK ! kvЂ code/theme-rtl.cssnu [ .wp-block-code{
border:1px solid #ccc;
border-radius:4px;
font-family:Menlo,Consolas,monaco,monospace;
padding:.8em 1em;
}PK ! a8 code/style.cssnu [ .wp-block-code{
box-sizing:border-box;
}
.wp-block-code code{
display:block;
font-family:inherit;
overflow-wrap:break-word;
white-space:pre-wrap;
}PK ! EO code/style.min.cssnu [ .wp-block-code{box-sizing:border-box}.wp-block-code code{display:block;font-family:inherit;overflow-wrap:break-word;white-space:pre-wrap}PK !
m'^! ^! latest-posts.phpnu &1i $attributes['postsToShow'],
'post_status' => 'publish',
'order' => $attributes['order'],
'orderby' => $attributes['orderBy'],
'ignore_sticky_posts' => true,
'no_found_rows' => true,
);
$block_core_latest_posts_excerpt_length = $attributes['excerptLength'];
add_filter( 'excerpt_length', 'block_core_latest_posts_get_excerpt_length', 20 );
if ( ! empty( $attributes['categories'] ) ) {
$args['category__in'] = array_column( $attributes['categories'], 'id' );
}
if ( isset( $attributes['selectedAuthor'] ) ) {
$args['author'] = $attributes['selectedAuthor'];
}
$query = new WP_Query();
$recent_posts = $query->query( $args );
if ( isset( $attributes['displayFeaturedImage'] ) && $attributes['displayFeaturedImage'] ) {
update_post_thumbnail_cache( $query );
}
$list_items_markup = '';
foreach ( $recent_posts as $post ) {
$post_link = esc_url( get_permalink( $post ) );
$title = get_the_title( $post );
if ( ! $title ) {
$title = __( '(no title)' );
}
$list_items_markup .= '
';
if ( $attributes['displayFeaturedImage'] && has_post_thumbnail( $post ) ) {
$image_style = '';
if ( isset( $attributes['featuredImageSizeWidth'] ) ) {
$image_style .= sprintf( 'max-width:%spx;', $attributes['featuredImageSizeWidth'] );
}
if ( isset( $attributes['featuredImageSizeHeight'] ) ) {
$image_style .= sprintf( 'max-height:%spx;', $attributes['featuredImageSizeHeight'] );
}
$image_classes = 'wp-block-latest-posts__featured-image';
if ( isset( $attributes['featuredImageAlign'] ) ) {
$image_classes .= ' align' . $attributes['featuredImageAlign'];
}
$featured_image = get_the_post_thumbnail(
$post,
$attributes['featuredImageSizeSlug'],
array(
'style' => esc_attr( $image_style ),
)
);
if ( $attributes['addLinkToFeaturedImage'] ) {
$featured_image = sprintf(
'%3$s ',
esc_url( $post_link ),
esc_attr( $title ),
$featured_image
);
}
$list_items_markup .= sprintf(
'%2$s
',
esc_attr( $image_classes ),
$featured_image
);
}
$list_items_markup .= sprintf(
'%2$s ',
esc_url( $post_link ),
$title
);
if ( isset( $attributes['displayAuthor'] ) && $attributes['displayAuthor'] ) {
$author_display_name = get_the_author_meta( 'display_name', $post->post_author );
/* translators: byline. %s: author. */
$byline = sprintf( __( 'by %s' ), $author_display_name );
if ( ! empty( $author_display_name ) ) {
$list_items_markup .= sprintf(
'%1$s
',
$byline
);
}
}
if ( isset( $attributes['displayPostDate'] ) && $attributes['displayPostDate'] ) {
$list_items_markup .= sprintf(
'%2$s ',
esc_attr( get_the_date( 'c', $post ) ),
get_the_date( '', $post )
);
}
if ( isset( $attributes['displayPostContent'] ) && $attributes['displayPostContent']
&& isset( $attributes['displayPostContentRadio'] ) && 'excerpt' === $attributes['displayPostContentRadio'] ) {
$trimmed_excerpt = get_the_excerpt( $post );
/*
* Adds a "Read more" link with screen reader text.
* […] is the default excerpt ending from wp_trim_excerpt() in Core.
*/
if ( str_ends_with( $trimmed_excerpt, ' […]' ) ) {
/** This filter is documented in wp-includes/formatting.php */
$excerpt_length = (int) apply_filters( 'excerpt_length', $block_core_latest_posts_excerpt_length );
if ( $excerpt_length <= $block_core_latest_posts_excerpt_length ) {
$trimmed_excerpt = substr( $trimmed_excerpt, 0, -11 );
$trimmed_excerpt .= sprintf(
/* translators: 1: A URL to a post, 2: Hidden accessibility text: Post title */
__( '… Read more: %2$s ' ),
esc_url( $post_link ),
esc_html( $title )
);
}
}
if ( post_password_required( $post ) ) {
$trimmed_excerpt = __( 'This content is password protected.' );
}
$list_items_markup .= sprintf(
'%1$s
',
$trimmed_excerpt
);
}
if ( isset( $attributes['displayPostContent'] ) && $attributes['displayPostContent']
&& isset( $attributes['displayPostContentRadio'] ) && 'full_post' === $attributes['displayPostContentRadio'] ) {
$post_content = html_entity_decode( $post->post_content, ENT_QUOTES, get_option( 'blog_charset' ) );
if ( post_password_required( $post ) ) {
$post_content = __( 'This content is password protected.' );
}
$list_items_markup .= sprintf(
'%1$s
',
wp_kses_post( $post_content )
);
}
$list_items_markup .= " \n";
}
remove_filter( 'excerpt_length', 'block_core_latest_posts_get_excerpt_length', 20 );
$classes = array( 'wp-block-latest-posts__list' );
if ( isset( $attributes['postLayout'] ) && 'grid' === $attributes['postLayout'] ) {
$classes[] = 'is-grid';
}
if ( isset( $attributes['columns'] ) && 'grid' === $attributes['postLayout'] ) {
$classes[] = 'columns-' . $attributes['columns'];
}
if ( isset( $attributes['displayPostDate'] ) && $attributes['displayPostDate'] ) {
$classes[] = 'has-dates';
}
if ( isset( $attributes['displayAuthor'] ) && $attributes['displayAuthor'] ) {
$classes[] = 'has-author';
}
if ( isset( $attributes['style']['elements']['link']['color']['text'] ) ) {
$classes[] = 'has-link-color';
}
$wrapper_attributes = get_block_wrapper_attributes( array( 'class' => implode( ' ', $classes ) ) );
return sprintf(
'',
$wrapper_attributes,
$list_items_markup
);
}
/**
* Registers the `core/latest-posts` block on server.
*
* @since 5.0.0
*/
function register_block_core_latest_posts() {
register_block_type_from_metadata(
__DIR__ . '/latest-posts',
array(
'render_callback' => 'render_block_core_latest_posts',
)
);
}
add_action( 'init', 'register_block_core_latest_posts' );
/**
* Handles outdated versions of the `core/latest-posts` block by converting
* attribute `categories` from a numeric string to an array with key `id`.
*
* This is done to accommodate the changes introduced in #20781 that sought to
* add support for multiple categories to the block. However, given that this
* block is dynamic, the usual provisions for block migration are insufficient,
* as they only act when a block is loaded in the editor.
*
* TODO: Remove when and if the bottom client-side deprecation for this block
* is removed.
*
* @since 5.5.0
*
* @param array $block A single parsed block object.
*
* @return array The migrated block object.
*/
function block_core_latest_posts_migrate_categories( $block ) {
if (
'core/latest-posts' === $block['blockName'] &&
! empty( $block['attrs']['categories'] ) &&
is_string( $block['attrs']['categories'] )
) {
$block['attrs']['categories'] = array(
array( 'id' => absint( $block['attrs']['categories'] ) ),
);
}
return $block;
}
add_filter( 'render_block_data', 'block_core_latest_posts_migrate_categories' );
PK ! UlQ query-pagination-next/block.jsonnu [ {
"$schema": "https://schemas.wp.org/trunk/block.json",
"apiVersion": 3,
"name": "core/query-pagination-next",
"title": "Next Page",
"category": "theme",
"parent": [ "core/query-pagination" ],
"description": "Displays the next posts page link.",
"textdomain": "default",
"attributes": {
"label": {
"type": "string"
}
},
"usesContext": [
"queryId",
"query",
"paginationArrow",
"showLabel",
"enhancedPagination"
],
"supports": {
"reusable": false,
"html": false,
"color": {
"gradients": true,
"text": false,
"__experimentalDefaultControls": {
"background": true
}
},
"typography": {
"fontSize": true,
"lineHeight": true,
"__experimentalFontFamily": true,
"__experimentalFontWeight": true,
"__experimentalFontStyle": true,
"__experimentalTextTransform": true,
"__experimentalTextDecoration": true,
"__experimentalLetterSpacing": true,
"__experimentalDefaultControls": {
"fontSize": true
}
},
"interactivity": {
"clientNavigation": true
}
}
}
PK ! Ȃ
post-comments-form.phpnu [ context['postId'] ) ) {
return '';
}
if ( post_password_required( $block->context['postId'] ) ) {
return;
}
$classes = array( 'comment-respond' ); // See comment further below.
if ( isset( $attributes['textAlign'] ) ) {
$classes[] = 'has-text-align-' . $attributes['textAlign'];
}
if ( isset( $attributes['style']['elements']['link']['color']['text'] ) ) {
$classes[] = 'has-link-color';
}
$wrapper_attributes = get_block_wrapper_attributes( array( 'class' => implode( ' ', $classes ) ) );
add_filter( 'comment_form_defaults', 'post_comments_form_block_form_defaults' );
ob_start();
comment_form( array(), $block->context['postId'] );
$form = ob_get_clean();
remove_filter( 'comment_form_defaults', 'post_comments_form_block_form_defaults' );
// We use the outermost wrapping `
` returned by `comment_form()`
// which is identified by its default classname `comment-respond` to inject
// our wrapper attributes. This way, it is guaranteed that all styling applied
// to the block is carried along when the comment form is moved to the location
// of the 'Reply' link that the user clicked by Core's `comment-reply.js` script.
$form = str_replace( 'class="comment-respond"', $wrapper_attributes, $form );
// Enqueue the comment-reply script.
wp_enqueue_script( 'comment-reply' );
return $form;
}
/**
* Registers the `core/post-comments-form` block on the server.
*
* @since 6.0.0
*/
function register_block_core_post_comments_form() {
register_block_type_from_metadata(
__DIR__ . '/post-comments-form',
array(
'render_callback' => 'render_block_core_post_comments_form',
)
);
}
add_action( 'init', 'register_block_core_post_comments_form' );
/**
* Use the button block classes for the form-submit button.
*
* @since 6.0.0
*
* @param array $fields The default comment form arguments.
*
* @return array Returns the modified fields.
*/
function post_comments_form_block_form_defaults( $fields ) {
if ( wp_is_block_theme() ) {
$fields['submit_button'] = ' ';
$fields['submit_field'] = '%1$s %2$s
';
}
return $fields;
}
PK ! "$# widget-group.phpnu [ ';
$after_title = '';
}
$html = '';
if ( ! empty( $attributes['title'] ) ) {
$html .= $before_title . esc_html( $attributes['title'] ) . $after_title;
}
$html .= '';
foreach ( $block->inner_blocks as $inner_block ) {
$html .= $inner_block->render();
}
$html .= '
';
return $html;
}
/**
* Registers the 'core/widget-group' block.
*
* @since 5.9.0
*/
function register_block_core_widget_group() {
register_block_type_from_metadata(
__DIR__ . '/widget-group',
array(
'render_callback' => 'render_block_core_widget_group',
)
);
}
add_action( 'init', 'register_block_core_widget_group' );
/**
* Make a note of the sidebar being rendered before WordPress starts rendering
* it. This lets us get to the current sidebar in
* render_block_core_widget_group().
*
* @since 5.9.0
*
* @global int|string $_sidebar_being_rendered
*
* @param int|string $index Index, name, or ID of the dynamic sidebar.
*/
function note_sidebar_being_rendered( $index ) {
global $_sidebar_being_rendered;
$_sidebar_being_rendered = $index;
}
add_action( 'dynamic_sidebar_before', 'note_sidebar_being_rendered' );
/**
* Clear whatever we set in note_sidebar_being_rendered() after WordPress
* finishes rendering a sidebar.
*
* @since 5.9.0
*
* @global int|string $_sidebar_being_rendered
*/
function discard_sidebar_being_rendered() {
global $_sidebar_being_rendered;
unset( $_sidebar_being_rendered );
}
add_action( 'dynamic_sidebar_after', 'discard_sidebar_being_rendered' );
PK !