Bug 214898

Summary: Web Inspector: REGRESSION(r255396): Audit: button to exit edit mode in main content area is missing border
Product: WebKit Reporter: Devin Rousso <hi>
Component: Web InspectorAssignee: BJ Burg <bburg>
Status: RESOLVED FIXED    
Severity: Normal CC: bburg, hi, inspector-bugzilla-changes, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch hi: review+

Description Devin Rousso 2020-07-28 14:42:11 PDT
# STEPS TO REPRODUCE
1. inspect any page
2. go to the Audit Tab
3. enter Edit mode from the navigation sidebar
  => the Done button in the main content area is missing a border
Comment 1 Radar WebKit Bug Importer 2020-07-28 14:42:26 PDT
<rdar://problem/66238391>
Comment 2 Devin Rousso 2020-07-28 15:10:37 PDT
I'm pretty sure this was caused by the following change from r255396 <https://webkit.org/b/205434>:
```
-.message-text-view .navigation-item-help .navigation-bar > .item {
+.navigation-item-help > .navigation-bar > .item {
```
Comment 3 BJ Burg 2020-07-28 16:00:53 PDT
Created attachment 405425 [details]
Patch
Comment 4 Devin Rousso 2020-07-28 16:12:38 PDT
Comment on attachment 405425 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=405425&action=review

r=me

> Source/WebInspectorUI/UserInterface/Views/Main.css:239
>  .navigation-item-help > .navigation-bar > .item {

we could also adjust `WI.createNavigationItemHelp` to always expect `console.assert(navigationItem instanceof WI.ButtonNavigationItem);` so that we could add `.button` to the CSS since `.text-only` only exists for `WI.ButtonNavigationItem`

> Source/WebInspectorUI/UserInterface/Views/Main.css:246
> +.navigation-item-help > .navigation-bar > .item:not(.text-only) {

ditto (:239)

> Source/WebInspectorUI/UserInterface/Views/Main.css:250
> +.navigation-item-help > .navigation-bar > .item.text-only {

ditto (:239)

> Source/WebInspectorUI/UserInterface/Views/Main.css:251
> +    border: solid 1px var(--border-color);

It's a bit odd that we have the same CSS property repeated twice exactly as is for two rules that should both match the same thing.  Perhaps you could add a comment above it explaining that this is necessary due to the specificity of `.navigation-bar .item.button.text-only`?
Comment 5 BJ Burg 2020-07-28 21:31:35 PDT
Committed r265027: <https://trac.webkit.org/changeset/265027>