Make WordPress Core


Ignore:
Timestamp:
03/29/2022 08:16:36 PM (4 years ago)
Author:
audrasjb
Message:

Customizer: When a block theme is active, add an information about Site Editor in the Customizer.

This change adds an information notice to the customizer when a block theme is active and the customizer is also available (for example when a plugin activates it), to encourage people to use the Site Editor for the best full site customization experience.

Props ironprogrammer, antonvlasenko, Clorith, audrasjb, psmits1567, tobifjellner, costdev, webcommsat, joedolson, pbiron.
Merges [53024] and [53025] to the 5.9 branch.
Fixes #54939.

Location:
branches/5.9
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/5.9

  • branches/5.9/src/wp-includes/script-loader.php

    r53017 r53026  
    12211221            'invalidDate'             => __( 'Invalid date.' ),
    12221222            'invalidValue'            => __( 'Invalid value.' ),
     1223            'blockThemeNotification'  => sprintf(
     1224                /* translators: 1: Link to Site Editor documentation on HelpHub, 2: HTML button. */
     1225                __( 'Hurray! Your theme supports Full Site Editing with blocks. <a href="%1$s">Tell me more</a>. %2$s' ),
     1226                __( 'https://wordpress.org/support/article/site-editor/' ),
     1227                sprintf(
     1228                    '<button type="button" data-action="%1$s" class="button switch-to-editor">%2$s</button>',
     1229                    esc_url( admin_url( 'site-editor.php' ) ),
     1230                    __( 'Use Site Editor' )
     1231                )
     1232            ),
    12231233        )
    12241234    );
Note: See TracChangeset for help on using the changeset viewer.