From 5c6a8e98267924f75f2a584c279fde8d1541ec6e Mon Sep 17 00:00:00 2001 From: audrasjb Date: Fri, 1 Apr 2022 11:09:07 +0000 Subject: [PATCH] Adds "select all" shortcut for Mac on permalinks page when `.htaccess` is not writable. This change improves the description of the "select all" shortcut for Mac users in Permalink Settings screen. Props Valer1e, ajoah, audrasjb, SergeyBiryukov. Fixes #54633. Built from https://develop.svn.wordpress.org/trunk@53047 git-svn-id: http://core.svn.wordpress.org/trunk@52636 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-admin/options-permalink.php | 19 +++++++++++-------- .../js/tinymce/plugins/wordpress/plugin.js | 2 +- .../tinymce/plugins/wordpress/plugin.min.js | 2 +- wp-includes/js/tinymce/wp-tinymce.js | 2 +- wp-includes/version.php | 2 +- 5 files changed, 15 insertions(+), 12 deletions(-) diff --git a/wp-admin/options-permalink.php b/wp-admin/options-permalink.php index ffdd14263a..dcea250960 100644 --- a/wp-admin/options-permalink.php +++ b/wp-admin/options-permalink.php @@ -367,11 +367,12 @@ printf( __( 'If you like, you may enter custom structures for your category and

writable, we could do this automatically, but it is not so this is the url rewrite rule you should have in your %1$s file. Click in the field and press %3$s to select all. Then insert this rule inside of the %4$s element in %1$s file.' ), + /* translators: 1: web.config, 2: Documentation URL, 3: Ctrl + A, 4: ⌘ + A, 5: Element code. */ + __( 'If your %1$s file was writable, we could do this automatically, but it is not so this is the url rewrite rule you should have in your %1$s file. Click in the field and press %3$s (or %4$s on Mac) to select all. Then insert this rule inside of the %5$s element in %1$s file.' ), 'web.config', __( 'https://wordpress.org/support/article/changing-file-permissions/' ), 'Ctrl + A', + '⌘ + A', '/<configuration>/<system.webServer>/<rewrite>/<rules>' ); ?> @@ -393,11 +394,12 @@ printf( __( 'If you like, you may enter custom structures for your category and

writable, we could do this automatically, but it is not so this is the url rewrite rule you should have in your %2$s file. Create a new file, called %2$s in the root directory of your site. Click in the field and press %3$s to select all. Then insert this code into the %2$s file.' ), + /* translators: 1: Documentation URL, 2: web.config, 3: Ctrl + A, 4: ⌘ + A */ + __( 'If the root directory of your site was writable, we could do this automatically, but it is not so this is the url rewrite rule you should have in your %2$s file. Create a new file, called %2$s in the root directory of your site. Click in the field and press %3$s (or %4$s on Mac) to select all. Then insert this code into the %2$s file.' ), __( 'https://wordpress.org/support/article/changing-file-permissions/' ), 'web.config', - 'Ctrl + A' + 'Ctrl + A', + '⌘ + A' ); ?>

@@ -423,11 +425,12 @@ else :

writable, we could do this automatically, but it is not so these are the mod_rewrite rules you should have in your %1$s file. Click in the field and press %3$s to select all.' ), + /* translators: 1: .htaccess, 2: Documentation URL, 3: Ctrl + A, 4: ⌘ + A */ + __( 'If your %1$s file was writable, we could do this automatically, but it is not so these are the mod_rewrite rules you should have in your %1$s file. Click in the field and press %3$s (or %4$s on Mac) to select all.' ), '.htaccess', __( 'https://wordpress.org/support/article/changing-file-permissions/' ), - 'Ctrl + A' + 'Ctrl + A', + '⌘ + A' ); ?>

diff --git a/wp-includes/js/tinymce/plugins/wordpress/plugin.js b/wp-includes/js/tinymce/plugins/wordpress/plugin.js index ecfa881449..5aa0bb76f4 100644 --- a/wp-includes/js/tinymce/plugins/wordpress/plugin.js +++ b/wp-includes/js/tinymce/plugins/wordpress/plugin.js @@ -253,7 +253,7 @@ tinymce.PluginManager.add( 'wordpress', function( editor ) { editor.addCommand( 'WP_Help', function() { var access = tinymce.Env.mac ? __( 'Ctrl + Alt + letter:' ) : __( 'Shift + Alt + letter:' ), - meta = tinymce.Env.mac ? __( 'Cmd + letter:' ) : __( 'Ctrl + letter:' ), + meta = tinymce.Env.mac ? __( '⌘ + letter:' ) : __( 'Ctrl + letter:' ), table1 = [], table2 = [], row1 = {}, diff --git a/wp-includes/js/tinymce/plugins/wordpress/plugin.min.js b/wp-includes/js/tinymce/plugins/wordpress/plugin.min.js index c85faad46d..7889f2ab51 100644 --- a/wp-includes/js/tinymce/plugins/wordpress/plugin.min.js +++ b/wp-includes/js/tinymce/plugins/wordpress/plugin.min.js @@ -1 +1 @@ -!function(E){(!E.ui.FloatPanel.zIndex||E.ui.FloatPanel.zIndex<100100)&&(E.ui.FloatPanel.zIndex=100100),E.PluginManager.add("wordpress",function(p){var r,t,x=E.DOM,m=E.each,u=p.editorManager.i18n.translate,i=window.jQuery,o=window.wp,a=o&&o.editor&&o.editor.autop&&p.getParam("wpautop",!0),s=!1;function e(n){var e,t,o,i=0,a=E.$(".block-library-classic__toolbar");"hide"===n?e=!0:a.length&&!a.hasClass("has-advanced-toolbar")&&(a.addClass("has-advanced-toolbar"),n="show"),(t=p.theme.panel?p.theme.panel.find(".toolbar:not(.menubar)"):t)&&1/g,function(e,t){return''})),-1!==e.content.indexOf("\x3c!--nextpage--\x3e")&&(n=u("Page break"),e.content=e.content.replace(//g,'')),e.load&&"raw"!==e.format&&(e.content=a?o.editor.autop(e.content):e.content.replace(/-->\s+\s*/g,function(e,t){return''})),-1!==e.content.indexOf("\x3c!--nextpage--\x3e")&&(n=u("Page break"),e.content=e.content.replace(//g,'')),e.load&&"raw"!==e.format&&(e.content=a?o.editor.autop(e.content):e.content.replace(/-->\s+\s*/g,function(e,t){return''})),-1!==e.content.indexOf("\x3c!--nextpage--\x3e")&&(n=u("Page break"),e.content=e.content.replace(//g,'')),e.load&&"raw"!==e.format&&(e.content=a?o.editor.autop(e.content):e.content.replace(/-->\s+\s*/g,function(e,t){return''})),-1!==e.content.indexOf("\x3c!--nextpage--\x3e")&&(n=u("Page break"),e.content=e.content.replace(//g,'')),e.load&&"raw"!==e.format&&(e.content=a?o.editor.autop(e.content):e.content.replace(/-->\s+\s*