RESOLVED FIXED 228548
Web Inspector: Add standard CSS Logical properties to CSS keyword completion
https://bugs.webkit.org/show_bug.cgi?id=228548
Summary Web Inspector: Add standard CSS Logical properties to CSS keyword completion
Sonia Singla
Reported 2021-07-28 04:43:15 PDT
Replace -webkit-*-* logical properties to standard logical properties in WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js
Attachments
Patch (3.85 KB, patch)
2021-07-28 05:38 PDT, Sonia Singla
no flags
Patch (4.41 KB, patch)
2021-07-29 03:04 PDT, Sonia Singla
no flags
Patch (4.41 KB, patch)
2021-07-29 03:11 PDT, Sonia Singla
no flags
Patch (4.38 KB, patch)
2021-07-29 03:16 PDT, Sonia Singla
no flags
Patch (4.38 KB, patch)
2021-07-29 03:23 PDT, Sonia Singla
no flags
Patch (5.68 KB, patch)
2021-07-29 05:58 PDT, Sonia Singla
no flags
Patch (5.87 KB, patch)
2021-07-29 09:07 PDT, Sonia Singla
no flags
Patch (4.94 KB, patch)
2021-07-29 20:47 PDT, Sonia Singla
no flags
Patch (4.82 KB, patch)
2021-08-02 03:08 PDT, Sonia Singla
no flags
Patch (4.82 KB, patch)
2021-08-02 19:27 PDT, Sonia Singla
no flags
Radar WebKit Bug Importer
Comment 1 2021-07-28 05:24:24 PDT
Sonia Singla
Comment 2 2021-07-28 05:38:26 PDT
Manuel Rego Casasnovas
Comment 3 2021-07-28 06:37:07 PDT
Comment on attachment 434419 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=434419&action=review Thank you! This seems to be a good change as other logical properties are already using the standard name on that file. > Source/WebInspectorUI/ChangeLog:8 > + * UserInterface/Models/CSSKeywordCompletions.js: The file seems to be sorted alphabetically, could you keep it sorted after the renames?
Frédéric Wang (:fredw)
Comment 4 2021-07-28 06:50:36 PDT
Comment on attachment 434419 [details] Patch IIUC, this is removing autocompletion support for these legacy -webkit prefixes. Do we want that?
Sam Sneddon [:gsnedders]
Comment 5 2021-07-28 06:51:56 PDT
(In reply to Frédéric Wang (:fredw) from comment #4) > Comment on attachment 434419 [details] > Patch > > IIUC, this is removing autocompletion support for these legacy -webkit > prefixes. Do we want that? Yeah, we probably want to keep both autocompleting till we remove the -webkit-* properties.
Manuel Rego Casasnovas
Comment 6 2021-07-28 07:32:52 PDT
(In reply to Sam Sneddon [:gsnedders] from comment #5) > (In reply to Frédéric Wang (:fredw) from comment #4) > > Comment on attachment 434419 [details] > > Patch > > > > IIUC, this is removing autocompletion support for these legacy -webkit > > prefixes. Do we want that? > > Yeah, we probably want to keep both autocompleting till we remove the > -webkit-* properties. This is just making a few prefixed logical properties behave like the rest. For example we have support for "-webkit-margin-before" which is the old version of "margin-block-start", and we only have "margin-block-start" in CSSKeywordCompletions.js. That's why we thought it'd be ok to do the same with the remaining logical properties there that have standard ones.
Manuel Rego Casasnovas
Comment 7 2021-07-28 07:34:01 PDT
(In reply to Manuel Rego Casasnovas from comment #6) > (In reply to Sam Sneddon [:gsnedders] from comment #5) > > (In reply to Frédéric Wang (:fredw) from comment #4) > > > Comment on attachment 434419 [details] > > > Patch > > > > > > IIUC, this is removing autocompletion support for these legacy -webkit > > > prefixes. Do we want that? > > > > Yeah, we probably want to keep both autocompleting till we remove the > > -webkit-* properties. > > This is just making a few prefixed logical properties behave like the rest. > For example we have support for "-webkit-margin-before" which is the old > version of "margin-block-start", and we only have "margin-block-start" in > CSSKeywordCompletions.js. Actually "margin-block-start" is not even on this file. So maybe we don't want to do that and just add the standard logical properties in this file. Sorry.
Manuel Rego Casasnovas
Comment 8 2021-07-28 07:36:05 PDT
(In reply to Manuel Rego Casasnovas from comment #7) > (In reply to Manuel Rego Casasnovas from comment #6) > > (In reply to Sam Sneddon [:gsnedders] from comment #5) > > > (In reply to Frédéric Wang (:fredw) from comment #4) > > > > Comment on attachment 434419 [details] > > > > Patch > > > > > > > > IIUC, this is removing autocompletion support for these legacy -webkit > > > > prefixes. Do we want that? > > > > > > Yeah, we probably want to keep both autocompleting till we remove the > > > -webkit-* properties. > > > > This is just making a few prefixed logical properties behave like the rest. > > For example we have support for "-webkit-margin-before" which is the old > > version of "margin-block-start", and we only have "margin-block-start" in > > CSSKeywordCompletions.js. > > Actually "margin-block-start" is not even on this file. So maybe we don't > want to do that and just add the standard logical properties in this file. > Sorry. Not that one, but what I explained happens for "border-block-end-style", it has a prefixed version "-webkit-border-after-style", but only the standard one is listed on CSSKeywordCompletions.js. That's why I got confused. Would it be a good idea to add the standard unprefixed properties to this file and don't remove anything for now?
Devin Rousso
Comment 9 2021-07-28 11:18:07 PDT
Yeah we don't want to remove any legacy properties so long as they're still supported by the engine or any version of the engine still found on commonly used iOS devices.
Sonia Singla
Comment 10 2021-07-29 03:04:32 PDT
Sonia Singla
Comment 11 2021-07-29 03:11:04 PDT
Sonia Singla
Comment 12 2021-07-29 03:16:35 PDT
Sonia Singla
Comment 13 2021-07-29 03:23:37 PDT
Manuel Rego Casasnovas
Comment 14 2021-07-29 03:43:32 PDT
Comment on attachment 434513 [details] Patch Looks good, now that we're adding these I'd also include other properties like margin-block-start, padding-*, etc. thought those only have "auto" value.
Sonia Singla
Comment 15 2021-07-29 05:58:38 PDT
Oriol Brufau
Comment 16 2021-07-29 08:39:02 PDT
Comment on attachment 434517 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=434517&action=review > Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js:608 > + ], Seems a bit strange to have the logical padding properties but not the physical ones.
Sonia Singla
Comment 17 2021-07-29 09:07:06 PDT
> Seems a bit strange to have the logical padding properties but not the physical ones. Made the changes thanks for review Oriol.
Sonia Singla
Comment 18 2021-07-29 09:07:39 PDT
Oriol Brufau
Comment 19 2021-07-29 09:10:14 PDT
Comment on attachment 434525 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=434525&action=review > Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js:620 > + ], Wait, actually the padding properties don't accept "auto" :)
Sonia Singla
Comment 20 2021-07-29 20:47:27 PDT
Manuel Rego Casasnovas
Comment 21 2021-07-29 21:00:16 PDT
Comment on attachment 434601 [details] Patch Thanks. This looks good to me. But I'd prefer if someone more involved on the inspector like Devin Rousso reviews this.
Frédéric Wang (:fredw)
Comment 22 2021-07-30 04:33:21 PDT
Comment on attachment 434601 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=434601&action=review > Source/WebInspectorUI/ChangeLog:3 > + Web Inspector: Add standard logical properties in WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js Shouldn't we also add update ContextualDocumentationDatabase.js to add the unprefixed properties ?
Frédéric Wang (:fredw)
Comment 23 2021-07-30 04:42:22 PDT
Comment on attachment 434601 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=434601&action=review >> Source/WebInspectorUI/ChangeLog:3 >> + Web Inspector: Add standard logical properties in WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js > > Shouldn't we also add update ContextualDocumentationDatabase.js to add the unprefixed properties ? And it seems the JetStream test is also using these -webkit-* values to test WebInspector CSSKeywordCompletions, so this is related to the change here too. I wonder whether you should call this "Web Inspector: Add standard logical properties to CSS keyword completion". PerformanceTests/JetStream2/code-load/inspector-payload.js PerformanceTests/JetStream2/code-load/inspector-payload-minified.js Websites/browserbench.org/JetStream2.0/code-load/inspector-payload-minified.js Websites/browserbench.org/JetStream2.0/code-load/inspector-payload.js BTW, bugzilla's bug title should be updated too.
Patrick Angle
Comment 24 2021-07-30 07:41:58 PDT
Comment on attachment 434601 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=434601&action=review >>> Source/WebInspectorUI/ChangeLog:3 >>> + Web Inspector: Add standard logical properties in WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js >> >> Shouldn't we also add update ContextualDocumentationDatabase.js to add the unprefixed properties ? > > And it seems the JetStream test is also using these -webkit-* values to test WebInspector CSSKeywordCompletions, so this is related to the change here too. > I wonder whether you should call this "Web Inspector: Add standard logical properties to CSS keyword completion". > > PerformanceTests/JetStream2/code-load/inspector-payload.js > PerformanceTests/JetStream2/code-load/inspector-payload-minified.js > Websites/browserbench.org/JetStream2.0/code-load/inspector-payload-minified.js > Websites/browserbench.org/JetStream2.0/code-load/inspector-payload.js > > BTW, bugzilla's bug title should be updated too. `ContextualDocumentationDatabase.js` is a file derived from information in the `vscode-custom-data` open source project, so we shouldn't add anything manually. Properties without documentation available are gracefully handled, so the presence of an entry in that file is not required.
Devin Rousso
Comment 25 2021-07-30 12:37:25 PDT
Comment on attachment 434601 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=434601&action=review r=me >>>> Source/WebInspectorUI/ChangeLog:3 >>>> + Web Inspector: Add standard logical properties in WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js >>> >>> Shouldn't we also add update ContextualDocumentationDatabase.js to add the unprefixed properties ? >> >> And it seems the JetStream test is also using these -webkit-* values to test WebInspector CSSKeywordCompletions, so this is related to the change here too. >> I wonder whether you should call this "Web Inspector: Add standard logical properties to CSS keyword completion". >> >> PerformanceTests/JetStream2/code-load/inspector-payload.js >> PerformanceTests/JetStream2/code-load/inspector-payload-minified.js >> Websites/browserbench.org/JetStream2.0/code-load/inspector-payload-minified.js >> Websites/browserbench.org/JetStream2.0/code-load/inspector-payload.js >> >> BTW, bugzilla's bug title should be updated too. > > `ContextualDocumentationDatabase.js` is a file derived from information in the `vscode-custom-data` open source project, so we shouldn't add anything manually. Properties without documentation available are gracefully handled, so the presence of an entry in that file is not required. You definitely don't need to update any of the perf tests. Those are not meant to represent actual Web Inspector and I believe are just a way to test large JS payloads. They are also _extremely_ out of date. > Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js:466 > + "auto", "intrinsic", "min-intrinsic", "min-content", "-webkit-min-content", "max-content", > + "-webkit-max-content", "-webkit-fill-available", "fit-content", "-webkit-fit-content", "calc()" Style: Please don't split this into two lines. Either keep it all on one line (preferred) or split every item onto it's own line. > Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js:550 > + "auto", "intrinsic", "min-intrinsic", "min-content", "-webkit-min-content", > + "max-content", "-webkit-max-content", "-webkit-fill-available", "fit-content", "-webkit-fit-content", "calc()" ditto (:465) > Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js:559 > + "auto" Style: missing trailing comma (ditto with most of the other added lines in this patch too)
Sonia Singla
Comment 26 2021-08-02 03:08:11 PDT
Sonia Singla
Comment 27 2021-08-02 19:27:10 PDT
EWS
Comment 28 2021-08-03 02:10:28 PDT
Committed r280588 (240210@main): <https://commits.webkit.org/240210@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 434811 [details].
Note You need to log in before you can comment on or make changes to this bug.