Skip to content

Improve translatability of text length assessment feedback strings #22307

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

Open
wants to merge 4 commits into
base: trunk
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ describe( "A text length assessment", function() {
expect( assessment.getScore() ).toEqual( 6 );
expect( assessment.getText() ).toEqual( "<a href='https://yoa.st/34n' target='_blank'>Text length</a>: " +
"The text contains 275 words. This is slightly below the recommended minimum of 300 words. <a href='https://yoa.st/34o' " +
"target='_blank'>Add a bit more copy</a>." );
"target='_blank'>Add more content</a>." );
} );


Expand Down Expand Up @@ -201,7 +201,7 @@ describe( "A text length assessment", function() {
expect( result.getScore() ).toEqual( 6 );
expect( result.getText() ).toEqual( "<a href='https://yoa.st/34n' target='_blank'>Text length</a>: " +
"The text contains 155 words. This is slightly below the recommended minimum of 200 words." +
" <a href='https://yoa.st/34o' target='_blank'>Add a bit more copy</a>." );
" <a href='https://yoa.st/34o' target='_blank'>Add more content</a>." );
} );


Expand Down Expand Up @@ -372,7 +372,7 @@ describe( "Tests regular post content type in Japanese. " +
expect( results.getScore() ).toEqual( 6 );
expect( results.getText() ).toEqual( "<a href='https://yoa.st/34n' target='_blank'>Text length</a>: The text contains 599 characters. " +
"This is slightly below the recommended minimum of 600 characters. " +
"<a href='https://yoa.st/34o' target='_blank'>Add a bit more copy</a>." );
"<a href='https://yoa.st/34o' target='_blank'>Add more content</a>." );
} );

it( "should assess a 600-character text in the aboveMinimum category", function() {
Expand Down
14 changes: 7 additions & 7 deletions packages/yoastseo/src/scoring/assessments/SCORING SEO PRODUCT.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,13 +67,13 @@ Additionally, Dutch, German and Swedish trigger an orange/red bullet with shorte

**Call to action URL**: [https://yoa.st/34o](https://yoast.com/blog-post-word-count-seo/#utm_source=yoast-seo&utm_medium=software&utm_term=text-length-name&utm_content=content-analysis) (link placement is in bold in the feedback strings)

| Traffic light | Score | Criterion | Feedback |
|-------------------|--------------------------|-----------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Red | -20 | Between 0 and 49 words (cornerstone: between 0 and 0, Japanese: 0-99 characters) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of 200 words (cornerstone: 400 words, Japanese: 400 characters, Japanese cornerstone: 800 characters). **Add more content.** |
| Red | -10 (cornerstone: -20) | Between 50 and 99 words (cornerstone: between 0 and 199, Japanese: 100-199 characters, Japanese cornerstone: 0-399 characters) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of X words/characters. **Add more content.** |
| Red | 3 (cornerstone: -20) | Between 100 and 149 words (cornerstone: between 200 and 299, Japanese: 200-299 characters, Japanese cornerstone: 400-599 characters) | **Text length**: The text contains X words/characters. This is below the recommended minimum of X words/characters. **Add more content.** |
| Orange | 6 | Between 150 and 199 words (cornerstone: between 300 and 399, Japanese: 300-399 characters, Japanese cornerstone: 600-799 characters) | **Text length**: The text contains X words/characters. This is slightly below the recommended minimum of 200 words/400 characters. **Add a bit more copy.** (cornerstone: **Text length**: the text contains X words/characters. This is below the recommended minimum of 400 words/800 characters. **Add more content.**) |
| Green | 9 | More than or exactly 200 words (cornerstone: 400, Japanese: 400 characters, Japanese cornerstone: 800 characters) | **Text length**: The text contains X words/characters. Good job! |
| Traffic light | Score | Criterion | Feedback |
|-------------------|--------------------------|-----------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Red | -20 | Between 0 and 49 words (cornerstone: between 0 and 0, Japanese: 0-99 characters) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of 200 words (cornerstone: 400 words, Japanese: 400 characters, Japanese cornerstone: 800 characters). **Add more content.** |
| Red | -10 (cornerstone: -20) | Between 50 and 99 words (cornerstone: between 0 and 199, Japanese: 100-199 characters, Japanese cornerstone: 0-399 characters) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of X words/characters. **Add more content.** |
| Red | 3 (cornerstone: -20) | Between 100 and 149 words (cornerstone: between 200 and 299, Japanese: 200-299 characters, Japanese cornerstone: 400-599 characters) | **Text length**: The text contains X words/characters. This is below the recommended minimum of X words/characters. **Add more content.** |
| Orange | 6 | Between 150 and 199 words (cornerstone: between 300 and 399, Japanese: 300-399 characters, Japanese cornerstone: 600-799 characters) | **Text length**: The text contains X words/characters. This is slightly below the recommended minimum of 200 words/400 characters. **Add more content.** (cornerstone: **Text length**: the text contains X words/characters. This is below the recommended minimum of 400 words/800 characters. **Add more content.**) |
| Green | 9 | More than or exactly 200 words (cornerstone: 400, Japanese: 400 characters, Japanese cornerstone: 800 characters) | **Text length**: The text contains X words/characters. Good job! |


### Assessments unique to product pages
Expand Down
14 changes: 7 additions & 7 deletions packages/yoastseo/src/scoring/assessments/SCORING SEO.md
Original file line number Diff line number Diff line change
Expand Up @@ -276,13 +276,13 @@ With the example keyphrase `cat and dog` the following criteria would apply to c

**Call to action URL**: [https://yoa.st/34o](https://yoast.com/blog-post-word-count-seo/#utm_source=yoast-seo&utm_medium=software&utm_term=text-length-name&utm_content=content-analysis) (link placement is in bold in the feedback strings)

| Traffic light | Score | Criterion | Feedback |
|-------------------|--------------------------|-----------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Red | -20 | Between 0 and 99 words (_cornerstone_: between 0 and 0, _Japanese_: 0-199) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of 300 words (cornerstone: 900 words, JA: 600 characters, JA cornerstone: 1800 characters). **Add more content.** |
| Red | -10 (cornerstone: -20) | Between 100 and 199 words (cornerstone: between 0 and 299, Japanese: 200-399 characters, Japanese cornerstone: 0-599 characters) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of X words/characters. **Add more content.** |
| Red | 3 (cornerstone: -20) | Between 200 and 249 words (cornerstone: between 300 and 399, Japanese: 400-499 characters, Japanese cornerstone: 600-799 characters) | **Text length**: The text contains X words/characters. This is below the recommended minimum of X words/characters. **Add more content.** |
| Orange | 6 | Between 250 and 299 words (cornerstone: between 400 and 899, Japanese: 500-599 characters, Japanese cornerstone: 800-1799 characters) | **Text length**: The text contains X words/characters. This is slightly below the recommended minimum of 300 words (JA: 600 characters). **Add a bit more copy.** (cornerstone: **Text length**: The text contains X words. This is below the recommended minimum of 900 words (JA: 1800 characters). **Add more content.**) |
| Green | 9 | More than or exactly 300 words (cornerstone: 900, Japanese: 600 characters, Japanese cornerstone: 1800 characters) | **Text length**: The text contains X words/characters. Good job! |
| Traffic light | Score | Criterion | Feedback |
|-------------------|--------------------------|-----------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Red | -20 | Between 0 and 99 words (_cornerstone_: between 0 and 0, _Japanese_: 0-199) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of 300 words (cornerstone: 900 words, JA: 600 characters, JA cornerstone: 1800 characters). **Add more content.** |
| Red | -10 (cornerstone: -20) | Between 100 and 199 words (cornerstone: between 0 and 299, Japanese: 200-399 characters, Japanese cornerstone: 0-599 characters) | **Text length**: The text contains X words/characters. This is far below the recommended minimum of X words/characters. **Add more content.** |
| Red | 3 (cornerstone: -20) | Between 200 and 249 words (cornerstone: between 300 and 399, Japanese: 400-499 characters, Japanese cornerstone: 600-799 characters) | **Text length**: The text contains X words/characters. This is below the recommended minimum of X words/characters. **Add more content.** |
| Orange | 6 | Between 250 and 299 words (cornerstone: between 400 and 899, Japanese: 500-599 characters, Japanese cornerstone: 800-1799 characters) | **Text length**: The text contains X words/characters. This is slightly below the recommended minimum of 300 words (JA: 600 characters). **Add more content.** (cornerstone: **Text length**: The text contains X words. This is below the recommended minimum of 900 words (JA: 1800 characters). **Add more content.**) |
| Green | 9 | More than or exactly 300 words (cornerstone: 900, Japanese: 600 characters, Japanese cornerstone: 1800 characters) | **Text length**: The text contains X words/characters. Good job! |

### 2) Outbound links
**What it does**: Checks if outbound links are present and followed.
Expand Down
Loading