-
Notifications
You must be signed in to change notification settings - Fork 875
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Meta description mentions block/classic/elementor-editor #21184
Meta description mentions block/classic/elementor-editor #21184
Conversation
Pull Request Test Coverage Report for Build 41a2a2603968e234b1eef8a7fa9288446598633aDetails
💛 - Coveralls |
…description-length-includes-date-but-thats-not-very-clear
…description-length-includes-date-but-thats-not-very-clear
…seo into 974-meta-description-length-includes-date-but-thats-not-very-clear
…description-length-includes-date-but-thats-not-very-clear
…seo into 974-meta-description-length-includes-date-but-thats-not-very-clear
…description-length-includes-date-but-thats-not-very-clear
…description-length-includes-date-but-thats-not-very-clear
…description-length-includes-date-but-thats-not-very-clear
…description-length-includes-date-but-thats-not-very-clear
…-length-includes-date-but-thats-not-very-clear
packages/js/src/shared-admin/helpers/search-appearance-description-mention.js
Outdated
Show resolved
Hide resolved
*/ | ||
const filterReplacementVariableEditorMentions = ( mentions, { fieldId } ) => { | ||
const isRtl = get( window, "wpseoScriptData.metabox.isRtl", false ); | ||
const dateCharacters = date().length; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess you can use the following code to get date and avoid global variable.
const getDate = select( "yoast-seo/editor" ).getDateFromSettings;
const dateCharacters = getDate().length;
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call! 💯
packages/js/src/shared-admin/helpers/search-appearance-description-mention.js
Outdated
Show resolved
Hide resolved
…can be removed #93 Fix Insert variable dropdown.
…description-length-includes-date-but-thats-not-very-clear
Changes are reverted in this PR #21385 |
Context
date
andseparator
variables within the editor. Now, when users hover over these variables, a tooltip displays the information with the exact number of characters counted. This will offer users clarity on what is included in the character count and help them craft meta descriptions more effectively.Summary
This PR can be summarized in the following changelog entry:
date
and aseparator
snippet variable to the meta description text field, to make clear that both the date and a separator are automatically added to the character count of the meta description. Hovering over the variables reveals a tooltip with more explanation.Relevant technical choices:
mentions
in the code, matching our naming in the ReplacementVariableEditorStandalone.js and the SnippetEditor.additional-mentions.css
file to adjust the alignment of the elements in the Meta description text editor.Test instructions
Test instructions for the acceptance test before the PR gets merged
This PR can be acceptance tested by following these steps:
Date
andSeparator
badges.tooltip
is shown providing the information over the number of characters counted for the Meta description length analysis.Date
andSeparator
badges will be in the selected language. Thetooltip
information text will still show in English, until it is released and translated.Relevant test scenarios
Test instructions for QA when the code is in the RC
QA can test this PR by following these steps:
Impact check
This PR affects the following parts of the plugin, which may require extra testing:
UI changes
Other environments
[shopify-seo]
, added test instructions for Shopify and attached theShopify
label to this PR.Documentation
Quality assurance
Innovation
innovation
label.Fixes #