Intent to Ship: justify-items: legacy; Deprecate and Remove: justify-items: auto

71 views
Skip to first unread message

Javier Fernandez

unread,
Jan 29, 2018, 6:54:48 PM1/29/18
to blin...@chromium.org
Contact emails
jfern...@igalia.com

Spec
https://drafts.csswg.org/css-align/#justify-items-property

Summary
The CSS WG has decided to change the syntax of the justify-items CSS property so that the 'auto' vale is not valid anymore and a ew keyword must be used instead, defined as 'legacy'. This new CSS value will be also the property's default value.
  - https://github.com/w3c/csswg-drafts/issues/1318

This change affects also to the place-items shorthand, which handles both align-items and justify-items properties.
 

Link to "intent to implement" blink-dev discussion

Covered by the original intent to implement


Interoperability and Compatibility risk
Edge already shipped this new CSS syntax for the justify-items property and Firefox and Safari show positive signals about implementing is soon:
  - https://bugzilla.mozilla.org/show_bug.cgi?id=1363875
  - https://bugs.webkit.org/show_bug.cgi?id=172711

Removing the 'auto' value for justify-items will clearly break sites using the 'legacy' alignment, so we indeed have a Compatibility risk. However, considering that it's only implemented for Grid Layout, it's unlikely to detect a high use of the 'legacy' keyword on this property since we shipped the feature. We can wait for the UseCounter metrics if we consider it more convenient, but the longer we differ from FF and Edge the bigger the interoperability risk we'll have.   

Alternative implementation suggestion for web developers
The new 'legacy' keyword will replace completely the previous functionality achieved with the 'auto' value.

Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, Chrome OS, Android, and Android WebView)?
Yes

OWP launch tracking bug
https://bugs.chromium.org/p/chromium/issues/detail?id=726147

Link to entry on the Chrome Platform Status
https://www.chromestatus.com/features/5751109557682176

Requesting approval to removal too?
Yes

Requesting approval to ship?

Yes

Chris Harrelson

unread,
Jan 30, 2018, 8:53:30 PM1/30/18
to Javier Fernandez, blink-dev
Hi,

Regarding compatibility: this intent renames 'auto' to 'legacy', and 'legacy' is the default. Therefore sites which use auto will receive 'legacy' behavior, correct? Is 'legacy' different in any way than the previous 'auto'?

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/552753c1-9b2f-bb01-4fed-2ae621f2398e%40igalia.com.

Javier Fernandez

unread,
Jan 31, 2018, 3:58:40 AM1/31/18
to blin...@chromium.org
Hi,

On 31/01/18 02:53, Chris Harrelson wrote:
Hi,

Regarding compatibility: this intent renames 'auto' to 'legacy', and 'legacy' is the default. Therefore sites which use auto will receive 'legacy' behavior, correct? Is 'legacy' different in any way than the previous 'auto'?


It's correct, sites will receive 'legacy' behavior, which is the same than what 'auto' provides already. The only issue could be for sites using 'auto' explicitly in any CSS rules. This change will break those sites. That's why I added an UseCounter to evaluate the impact of this change in that scenario.

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAOMQ%2Bw-Z_yow0zeu%2B_t1ZW3S6TT4LgBrgg6Ay7V66KEaQ5fSGw%40mail.gmail.com.

Javier Fernandez

unread,
Jan 31, 2018, 12:48:32 PM1/31/18
to blin...@chromium.org
Hi,

After thinking it more carefully, I think the proposal doesn't imply any Compatibility issue, since the new 'legacy' value will become the default value and will provide the old behavior in case of any explicit 'auto', which will be parsed as invalid.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

Chris Harrelson

unread,
Jan 31, 2018, 1:04:22 PM1/31/18
to Javier Fernandez, blink-dev
Cool!

LGTM1

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/c983c977-8653-76c8-df7c-f863f0d88415%40igalia.com.

Yoav Weiss

unread,
Feb 1, 2018, 3:25:30 AM2/1/18
to Chris Harrelson, Javier Fernandez, blink-dev
LGTM2

Cool!

LGTM1

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAOMQ%2Bw-f8GXj3ja2qMi%2BgM_bJ--eJuvjf3PbgF%3D7qMkEXD6eQQ%40mail.gmail.com.

Ojan Vafai

unread,
Feb 1, 2018, 7:50:20 PM2/1/18
to blink-dev, chri...@chromium.org, jfern...@igalia.com
Is this different from https://groups.google.com/a/chromium.org/forum/#!msg/blink-dev/QDhDKXJqKVE/SVeKgDw4AgAJ? Both intents seem to be proposing the same thing.

According to https://www.chromestatus.com/metrics/css/popularity, grid is used on somewhere between 0.03% to 1% of pages views and justify-items is used on 0.09%, but the latter is probably mostly for flexbox. Also, since this is the default value, there probably aren't many people setting it to auto on grids. In short, I think you're right that the compat risk is probably fairly low.

LGTM3
LGTM2

Cool!

LGTM1

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

Ojan Vafai

unread,
Feb 1, 2018, 7:53:01 PM2/1/18
to blink-dev, chri...@chromium.org, jfern...@igalia.com
Actually, sorry. I just reread https://groups.google.com/a/chromium.org/forum/#!msg/blink-dev/QDhDKXJqKVE/SVeKgDw4AgAJ and I'm confused what each of these proposals. Please ignore my LGTM below for now. I'd like to understand exactly what each proposal is first. :)

Javier Fernandez

unread,
Feb 2, 2018, 7:36:17 AM2/2/18
to Ojan Vafai, blink-dev, chri...@chromium.org, jfern...@igalia.com
Hi Ojan,

Well, both intents are pretty related. The first one  https://groups.google.com/a/chromium.org/forum/#!msg/blink-dev/QDhDKXJqKVE/SVeKgDw4AgAJ was when I intended to implement and ship the new "legacy" value, keeping the current implementation based on 'auto' and without deprecating or removing it from the justify-items syntax. I was worried about compat issues, so I wanted to get data from UseCounter first.

Then, after discussing it with Chris Harrelson, I realized that given the fact that the 'legacy' will replace 'auto' as the default value, we can indeed ship and remove at the same time; hence this second intent. The first one could be seen as a plain intent-to-implement, that this one could refer to. 
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/06bb20ca-a835-4911-b8dd-4d55335d9021%40chromium.org.

Ojan Vafai

unread,
Feb 2, 2018, 5:37:13 PM2/2/18
to Javier Fernandez, blink-dev, chri...@chromium.org

Got it. Lgtm3 then. :)


LGTM2

Cool!

LGTM1

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/CAOMQ%2Bw-f8GXj3ja2qMi%2BgM_bJ--eJuvjf3PbgF%3D7qMkEXD6eQQ%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
Reply all
Reply to author
Forward
0 new messages