RESOLVED FIXED 194883
Web Inspector: eliminate manual syncing of numeric constants used by JavaScript and CSS
https://bugs.webkit.org/show_bug.cgi?id=194883
Summary Web Inspector: eliminate manual syncing of numeric constants used by JavaScri...
Matt Baker
Reported 2019-02-20 16:43:32 PST
Summary: Eliminate manual syncing of numeric constants used by JavaScript and CSS. Web Inspector CSS occasionally uses numeric constants that must also be available to code. Currently we rely on the developer to keep the JavaScript and CSS worlds in sync. These custom properties should have their values set by Web Inspector code so that can't get out of sync. Note: The CSS custom property `--recording-auto-capture-input-margin` in CanvasOverviewContentView.css has already become out of sync. Let's fix this!
Attachments
Patch (18.73 KB, patch)
2019-03-10 19:31 PDT, Devin Rousso
no flags
Patch (14.31 KB, patch)
2019-03-11 13:05 PDT, Devin Rousso
no flags
Radar WebKit Bug Importer
Comment 1 2019-02-20 16:44:00 PST
Devin Rousso
Comment 2 2019-03-10 19:31:29 PDT
Joseph Pecoraro
Comment 3 2019-03-11 12:21:26 PDT
Comment on attachment 364220 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=364220&action=review r=me > Source/WebInspectorUI/UserInterface/Views/MemoryTimelineView.js:117 > + static get _memoryCategoryViewheight() { return 75; } Typo: "...Viewheight" => "...ViewHeight" I also really dislike _ prefixed getters. They are very confusing / unexpected to work work and this is a constant that doesn't need to be "private". > Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.css:119 > +.network-table .cell.name > .status { > + -webkit-margin-left: 4px; > +} Seems like this should be `-webkit-margin-start` not `-webkit-margin-left`. The sync changes and the -webkit-margin changes should really be different patches. They are almost entirely unrelated changes each with their own possibility of causing regressions. > Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js:201 > + static get _nodeWaterfallDOMEventSize() { return 8; } Same, this doesn't need to be underscore prefixed.
Devin Rousso
Comment 4 2019-03-11 13:05:25 PDT
WebKit Commit Bot
Comment 5 2019-03-11 13:35:27 PDT
Comment on attachment 364280 [details] Patch Clearing flags on attachment: 364280 Committed r242737: <https://trac.webkit.org/changeset/242737>
WebKit Commit Bot
Comment 6 2019-03-11 13:35:29 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.