New issue
Advanced search Search tips

Issue 848621 link

Starred by 3 users

Issue metadata

Status: Started
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: 2018-06-07
OS: ----
Pri: 3
Type: Feature



Sign in to add a comment

word-spacing does not support percent values

Reported by swivelga...@gmail.com, Jun 1 2018

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.181 Safari/537.36

Steps to reproduce the problem:
1. Add a style-able element to an HTML file
2. Give said element multi-word text content
3. Using CSS, set the element's `word-spacing` property to a percentage-value

What is the expected behavior?
When a percentage value is used, spacing between words should be equal to the percentage of the width of a whitespace character.

What went wrong?
After a recent Chrome update, the `white-spacing` property no longer accepts percentages as acceptable values.

Did this work before? Yes Investigating specific version; within recent weeks

Does this work in other browsers? Yes

Chrome version: 66.0.3359.181  Channel: stable
OS Version: OS X 10.13.4
Flash Version: 

This seems to have broken after a very recent update. CSS specification allows for `word-spacing` to be specified as a percentage of the width of a font's whitespace character. This seems to have regressed and was noticed after an update in the middle of completing a design.
 
blink-css-word-spacing-percent-issue.png
5.9 KB View Download
blink-css-word-spacing-percent-issue.zip
7.5 KB Download

Comment 1 by ajha@chromium.org, Jun 1 2018

Labels: Needs-Triage-M66
Are you sure this was actually ever working? MDN shows Chrome not having support for percentage values (https://developer.mozilla.org/en-US/docs/Web/CSS/word-spacing), and a cursory glance at the parsing code shows a TODO to implement percentage values going back several years.
Cc: susan.boorgula@chromium.org
Labels: Triaged-ET Needs-Feedback
swivelgames@ Thanks for the issue.

Tested this issue on Mac OS 10.13.3 and Windows 10 on the reported version 66.0.3359.181 and the latest Canary 69.0.3446.0 by following the below steps.

1. Launched Chrome and launched the given html file.
2. opened Devtools -> Elements -> Styles and added 'word.spacing: -100%;' to element.style block and no issues are observed.
Attached is the screen cast for reference.

Request you to check and confirm if anything is missed from our end in triaging the issue.

Thanks..
848621.mp4
925 KB View Download

Comment 4 by e...@chromium.org, Jun 1 2018

NextAction: 2018-06-07
susan.boorgula@ The proper property name is "word-spacing". "word.spacing" is not a valid property name. This seems to be a separate issue. See the screenshot where the value isn't even added to the property in the style attribute. On any non-body element, it does not show an error. Even with "word-spacing: -100%" on the body element, no error is shown. This seems to be a separate error.

cnardi@ You are correct. This was noticed when I switched from testing the site in Firefox to Google Chrome.

This does not appear to have ever worked in Google Chrome.
Screen Shot 2018-06-03 at 13.51.49.png
99 KB View Download
Screen Shot 2018-06-03 at 14.02.04.png
114 KB View Download
Project Member

Comment 6 by sheriffbot@chromium.org, Jun 3 2018

Labels: -Needs-Feedback
Thank you for providing more feedback. Adding the requester to the cc list.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
cnardi@ That was a mistake I didn't realize until now. My apologies!
Components: -Blink>CSS Blink>Layout
Labels: -Type-Bug-Regression -OS-Mac -Triaged-ET -Needs-Triage-M66 Type-Feature
Status: Untriaged (was: Unconfirmed)
Summary: word-spacing does not parse percentages (was: word-spacing percentages show as "invalid value")
Marking this as a feature request then, since the spec does specify that percentages are a valid value (https://drafts.csswg.org/css-text-3/#propdef-word-spacing). Also moving this to Layout for now since it looks like layout code would need to be modified in addition to parsing code, but if someone feels it fits better in CSS feel free to move it back.
The NextAction date has arrived: 2018-06-07

Comment 10 by e...@chromium.org, Jun 15 2018

Components: -Blink>Layout Blink>CSS
Labels: -Pri-2 Pri-3
Status: Available (was: Untriaged)
Summary: word-spacing does not support percent values (was: word-spacing does not parse percentages)

Comment 11 Deleted

i will take this issue. and i have some questions.

it seems like to support percent value since css-text-3.
there are some layout-tests for previous spec(css-level-1 or 2) which is not supported it.
if we support this feature, the tests would be fail.
so should we just remove the tests or what is good way to treate old tests?

and is this feature need to send "intent to implement and ship"?

Sign in to add a comment