Repository navigation
I18N: Replace 'Toggle' with clearer alternatives in user-facing strings - #11806
itzmekhokan wants to merge 4 commits into
Conversation
Replace user-facing uses of 'toggle' in wp-admin translatable strings with clearer alternatives per style guide recommendations from Microsoft, Apple, and IBM. - template.php: 'Toggle panel: %s' → 'Show or hide panel: %s' - site-health.php: 'Toggle extra menu items' → 'Show or hide extra menu items' - network.php: 'toggle between' → 'switch between' These changes improve clarity for screen reader users and align with established writing style guidelines that recommend avoiding 'toggle' as a verb in user-facing materials. See #34753.
Replace user-facing uses of 'toggle' in wp-includes translatable strings with clearer alternatives per style guide recommendations. - class-wp-editor.php: 'toggle this option off' → 'turn this option off' - script-loader.php: 'Toggle Editor Text Direction' → 'Switch Editor Text Direction' Note: The TinyMCE array key 'Toolbar Toggle' (used as a mapping key for the TinyMCE translation system) is preserved as-is, since changing the key would break the TinyMCE translation mapping. The 'Toolbar Toggle' label refers to a specific TinyMCE button name. See #34753.
Update the TinyMCE 'Toolbar Toggle' button tooltip from 'Toolbar Toggle' to 'Show or hide the toolbar' for better clarity. The TinyMCE array key remains unchanged to maintain compatibility with the TinyMCE translation mapping system. Also update the corresponding help text in edit-form-advanced.php to match the new button description and avoid using 'toggle'. See #34753.
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Core Committers: Use this line as a base for the props when committing in SVN: To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Test using WordPress PlaygroundThe changes in this pull request can previewed and tested using a WordPress Playground instance. WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser. Some things to be aware of
For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation. |
joedolson
left a comment
There was a problem hiding this comment.
A couple minor changes.
|
|
||
| // WordPress strings. | ||
| 'Toolbar Toggle' => array( __( 'Toolbar Toggle' ), 'accessZ' ), | ||
| 'Toolbar Toggle' => array( __( 'Show or hide the toolbar' ), 'accessZ' ), |
There was a problem hiding this comment.
This should probably be something a bit more clear; the toolbar is actually visible by default; this option toggles the extended toolbar. It should just be 'Extended Toolbar'. The button has an aria-pressed attribute to communicate the state, so it doesn't really need show/hide.
This would also make the Help text more clear.
| $title_and_editor = '<p>' . __( '<strong>Title</strong> — Enter a title for your post. After you enter a title, you’ll see the permalink below, which you can edit.' ) . '</p>'; | ||
| $title_and_editor .= '<p>' . __( '<strong>Post editor</strong> — Enter the text for your post. There are two modes of editing: Visual and Code. Choose the mode by clicking on the appropriate tab.' ) . '</p>'; | ||
| $title_and_editor .= '<p>' . __( 'Visual mode gives you an editor that is similar to a word processor. Click the Toolbar Toggle button to get a second row of controls.' ) . '</p>'; | ||
| $title_and_editor .= '<p>' . __( 'Visual mode gives you an editor that is similar to a word processor. Use the toolbar button to show or hide a second row of controls.' ) . '</p>'; |
There was a problem hiding this comment.
Clarify after switching the button label to 'Extended Toolbar' and make the text more like it was before, e.g. 'Click the Extended Toolbar button to get...'. It's going to help users to be referring to an explicit button label here, rather than a more vague description.
Address code review feedback: label the TinyMCE toolbar toggle button as 'Extended Toolbar' (the basic toolbar is visible by default and the button exposes state via aria-pressed), and update the post editor help text to reference that explicit button label.
Thanks for the review, @joedolson ! Good catch on both counts. Updated the TinyMCE button label to 'Extended Toolbar' — you're right that the basic toolbar is visible by default and the button exposes its state via aria-pressed, so show/hide wording isn't needed. |
The word 'Toggle' poses complications in translations in numerous languages, having no direct translation. Replace user facing strings in the admin that currently use 'Toggle' with alternatives appropriate to their usage and actions. Developed in #11806 Props xibe, SergeyBiryukov, afercia, GaryJ, Presskopp, garrett-eclipse, NekoJonez, khokansardar, ramiy, joedolson. Fixes #34753. git-svn-id: https://develop.svn.wordpress.org/trunk@62696 602fd350-edb4-49c9-b593-d223f7449a82
The word 'Toggle' poses complications in translations in numerous languages, having no direct translation. Replace user facing strings in the admin that currently use 'Toggle' with alternatives appropriate to their usage and actions. Developed in WordPress/wordpress-develop#11806 Props xibe, SergeyBiryukov, afercia, GaryJ, Presskopp, garrett-eclipse, NekoJonez, khokansardar, ramiy, joedolson. Fixes #34753. Built from https://develop.svn.wordpress.org/trunk@62696 git-svn-id: http://core.svn.wordpress.org/trunk@61980 1a063a9b-81f0-0310-95a4-ce76da25c4cd
Fix the alignment of the label, input field, and Submit button for getting your user favorites in the plugins screen. Modernizes layout to use flex layout and improves small viewports. Developed in #11806 Props bayejid00, deepakprajapati, shreyasikhar26, tusharaddweb, joedolson, sabernhardt. Fixes #65231. git-svn-id: https://develop.svn.wordpress.org/trunk@62697 602fd350-edb4-49c9-b593-d223f7449a82
Fix the alignment of the label, input field, and Submit button for getting your user favorites in the plugins screen. Modernizes layout to use flex layout and improves small viewports. Developed in WordPress/wordpress-develop#11806 Props bayejid00, deepakprajapati, shreyasikhar26, tusharaddweb, joedolson, sabernhardt. Fixes #65231. Built from https://develop.svn.wordpress.org/trunk@62697 git-svn-id: http://core.svn.wordpress.org/trunk@61981 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This PR resolves by standardizing user-facing terminology and removing the use of "Toggle" as a verb.
Per style guides from Microsoft, Apple, and IBM, "toggle" should generally not be used in user-facing materials, as it can be confusing for screen reader users or non-technical audiences. Instead, this PR updates these strings to describe the action directly (e.g., "Show or hide", "Turn on or off", "Switch").
Trac ticket: https://core.trac.wordpress.org/ticket/34753
Use of AI Tools
N/A
This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.