Bug 150391 - Web Inspector: Typo in a property name: style.inerhited
Summary: Web Inspector: Typo in a property name: style.inerhited
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: Nikita Vasilyev
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2015-10-21 05:05 PDT by Nikita Vasilyev
Modified: 2015-10-21 14:13 PDT (History)
10 users (show)

See Also:


Attachments
Patch (1.60 KB, patch)
2015-10-21 05:07 PDT, Nikita Vasilyev
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Nikita Vasilyev 2015-10-21 05:05:05 PDT
Should be "inherited". WebStorm spotted a missing property, otherwise I wouldn't notice.

http://trac.webkit.org/changeset/187195
https://github.com/WebKit/webkit/blob/f83708780100ed4be51a136ec33b3ddfdddcc9dd/Source/WebInspectorUI/UserInterface/Views/RulesStyleDetailsPanel.js#L293

I searched in Source/WebInspectorUI. That's the only place where "inerhited" is used.
Comment 1 Radar WebKit Bug Importer 2015-10-21 05:05:42 PDT
<rdar://problem/23199935>
Comment 2 Nikita Vasilyev 2015-10-21 05:07:44 PDT
Created attachment 263675 [details]
Patch
Comment 3 Nikita Vasilyev 2015-10-21 06:03:37 PDT
I've been looking at this over 300 lines long refresh method for a while and I still don't quite understand what difference fixing this typo made.

Devin, in insertAllMatchingPseudoStyles(force), what is the point of the force agrument?
Comment 4 WebKit Commit Bot 2015-10-21 06:37:36 PDT
Comment on attachment 263675 [details]
Patch

Clearing flags on attachment: 263675

Committed r191387: <http://trac.webkit.org/changeset/191387>
Comment 5 WebKit Commit Bot 2015-10-21 06:37:39 PDT
All reviewed patches have been landed.  Closing bug.
Comment 6 Devin Rousso 2015-10-21 10:07:31 PDT
(In reply to comment #3)
> I've been looking at this over 300 lines long refresh method for a while and
> I still don't quite understand what difference fixing this typo made.
> 
> Devin, in insertAllMatchingPseudoStyles(force), what is the point of the
> force agrument?

The idea behind the force argument was that pseudo-element styles (::before, ::after, etc) should never be seen below user-agent or inherited rules.  They should always be inserted before the first of those rules in the absolute worst case.  On most websites, there will be a matching rule that doesn't have the pseudo-element, so this is not necessary (like having ".example" and ".example::before").  It is possible, however, to have pseudo-rules without a matching non-pseudo-element rule, and it is for this case that the force was added.

Example:
on a blank page, create a rule and give it the selector "body::before" (and give the ::before a content).  This pseudo-element rule should appear before the user-agent "body" rule.
Comment 7 Nikita Vasilyev 2015-10-21 14:13:01 PDT
Thanks Devin, that makes sense now.