| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Although we store animation and transition style values in StyleUIReset and
define their properties in longhands/ui.mako.rs, but we may move them in
the future if this style struct becomes too large. So let's move the
definition of their values to an independent module, animation, so we
don't have to worry about this again.
This patch doesn't change any other things. Only move code.
Differential Revision: https://phabricator.services.mozilla.com/D173903
|
|
|
|
|
|
|
| |
Refactored ImportLayer into an enum instead of a struct and using
Option everywhere.
Differential Revision: https://phabricator.services.mozilla.com/D176793
|
|
|
|
|
|
|
|
|
| |
NaN and infinity percentages are now serialized as expected.
Also added some new WPT tests as percentages were previously untested
and added some spec comments to previous NaN/inf serialization code.
Differential Revision: https://phabricator.services.mozilla.com/D176726
|
|
|
|
|
|
|
|
|
|
| |
with declaration
No implementation just yet (the default QualifiedRuleParser
implementation just rejects stuff), but this is plumbing that I'd rather
get reviewed separately.
Differential Revision: https://phabricator.services.mozilla.com/D176686
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
More nesting plumbing. Still does nothing because we don't parse the
nested rules.
Should be trivial to prove this patch doesn't change any behavior so
far, but I want to land it on its own because it can have performance
implications.
This follows the pattern of what we do with other rules like layers and
container conditions, that is, keep the ancestor selectors in a stack,
and poke at the last one in order to replace the ancestor.
This changes the behavior of replace_parent_selector as with the newer
version of the spec, stuff like:
div {
.foo {
stuff
}
}
Should work as `div .foo`. A test is added for this case.
Differential Revision: https://phabricator.services.mozilla.com/D176560
|
|
|
|
|
|
|
|
|
| |
Allow to have a CssRules list inside a StyleRule.
This only introduces the storage and serialization code for them, but we
still don't parse it.
Differential Revision: https://phabricator.services.mozilla.com/D176550
|
|
|
|
|
|
|
|
|
| |
They should be stable.
Not sure this is worth writing a test for since the idea is that this
code goes away eventually.
Differential Revision: https://phabricator.services.mozilla.com/D176680
|
| |
|
|
|
|
|
|
| |
The duplication was slightly annoying me :)
Differential Revision: https://phabricator.services.mozilla.com/D176564
|
|
|
|
|
|
|
|
| |
Fixed @import supports() being parsed in the incorrect position as per spec.
Also added more WPT tests for layer and supports in one @import.
Differential Revision: https://phabricator.services.mozilla.com/D176193
|
|
|
|
|
|
|
|
| |
Fixed @import serialization being out of (spec) order.
Also added some more WPT tests.
Differential Revision: https://phabricator.services.mozilla.com/D176182
|
|
|
|
|
|
|
|
|
|
|
| |
This makes our menus closer to GTK4, and depends less on the native menu
rendering etc. Thunderbird already does this to some extent.
Leave the old code behind a pref for now (just in case). Also fix some
code in nsNativeTheme::GetContentState (fixes rendering of radio menu
items).
Differential Revision: https://phabricator.services.mozilla.com/D175664
|
|
|
|
|
|
| |
(non-standard) -webkit-text-security property
Differential Revision: https://phabricator.services.mozilla.com/D174951
|
|
|
|
|
|
|
| |
The test-case in the next patch from 10s to a couple hundred
milliseconds on my machine. No behavior change other than that.
Differential Revision: https://phabricator.services.mozilla.com/D175612
|
|
|
|
|
|
|
|
| |
':popover-open'
See https://github.com/whatwg/html/pull/9077.
Differential Revision: https://phabricator.services.mozilla.com/D175223
|
|
|
|
|
|
| |
These have been enabled by default for quite a while.
Differential Revision: https://phabricator.services.mozilla.com/D175513
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implemented supports conditions using supports() in @import rules as per
CSS Cascading and Inheritance Level 4.
Locked behind new pref, layout.css.import-supports.enabled,
only enabled in nightlies in this patch.
Also added new WPT tests for @import supports() generally.
Spec: https://drafts.csswg.org/css-cascade-4/#conditional-import
WPT tests: https://wpt.fyi/results/css/css-cascade/import-conditions.html
Differential Revision: https://phabricator.services.mozilla.com/D172622
|
| |
|
|
|
|
|
|
|
| |
This allows to clean-up the previous patches by using a single ThinVec
(which stores length / capacity along with the allocation).
Differential Revision: https://phabricator.services.mozilla.com/D175029
|
|
|
|
|
|
|
|
|
| |
This is the other extension to the :lang() pseudo-class in Selectors-4.
(Also supported in Safari.)
Depends on D174999
Differential Revision: https://phabricator.services.mozilla.com/D175000
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implemented the inverted-colors media feature from Media Queries Level 5
for all platforms.
Spec: https://drafts.csswg.org/mediaqueries-5/#inverted
Platform specific implementations:
- Windows: Checks system color filter setting, and if it is inverted
(note: Windows does not live update due to having to read a reg key)
- Mac: Checks dedicated inverted accessibility system setting
- Android: Checks dedicated inverted system setting
- Linux: No GTK API exposes anything like it so always none
Locked behind new pref `layout.css.inverted-colors.enabled`,
always off by default for now.
Also added new WPT tests (none previously).
Other browsers:
- WebKit: shipped since Safari 9.1 (Jan 2017)
- Blink: no signal
Test page: https://goose.icu/inverted-colors
Differential Revision: https://phabricator.services.mozilla.com/D173201
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Make all UA widgets also NAC.
Keep the UA widget flag but break at anonymous subtree boundaries, so
that only nodes inside the UA widget directly (and not NAC from those)
get the flag.
This is important because two callers depend on this difference:
* The style system, since we still want to match content rules from
stylesheets in the UA widget. We also match user rules, which is a
bit sketchy, but that was the previous behavior, will file a
follow-up for that.
* The reflector code, since we want the scope for UA widgets to not
include the NAC nodes inside that UA widget. nsINode::IsInUAWidget
got it wrong.
After this patch, ChromeOnlyAccess is equivalent to
IsInNativeAnonymousSubtree, so we should probably unify the naming.
That's left for a follow-up patch because I don't have a strong
preference.
Differential Revision: https://phabricator.services.mozilla.com/D174310
|
|
|
|
|
|
| |
Trivial, comment-only
Differential Revision: https://phabricator.services.mozilla.com/D174474
|
|
|
|
| |
Differential Revision: https://phabricator.services.mozilla.com/D174054
|
|
|
|
|
|
|
|
|
| |
And some related tests.
A bunch of -moz-box* properties are web exposed, so I'll file a
follow-up for hiding them.
Differential Revision: https://phabricator.services.mozilla.com/D173819
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implemented the scripting media feature.
Not locked behind a pref as it does not do anything new or particularly
give new data which could be used for fingerprinting (see <noscript>,
etc).
Also added new WPT tests (none previously). Not supported in any other
browsers yet.
Test page: https://goose.icu/media-scripting
Differential Revision: https://phabricator.services.mozilla.com/D172995
|
|
|
|
|
|
|
|
|
| |
If NaN is given as any input to CSS comp funcs (min/max/clamp), it
should return NaN. Does not cover simplification (see Bug 1820412).
Adjusted WPT test expectations, 18 newly pass. :tada:
Differential Revision: https://phabricator.services.mozilla.com/D171659
|
|
|
|
|
|
|
| |
This feature was shipped in Fx97, and it seems we don't need this pref
anymore.
Differential Revision: https://phabricator.services.mozilla.com/D173591
|
|
|
|
|
|
|
|
| |
Refactor a bit the code to unify how we deal with this conditional
restyling (we had similar code for
MustCascadeChildrenIfInheritResetStyle).
Differential Revision: https://phabricator.services.mozilla.com/D172890
|
|
|
|
|
|
|
| |
Remove now dead Mul implementations. Use Self rather than the whole type
to shrink a bit the code.
Differential Revision: https://phabricator.services.mozilla.com/D173143
|
|
|
|
|
|
|
| |
Refactor the mul_by function on leafs into a more generic map function
that can be used for more operations like abs, signum and mul.
Differential Revision: https://phabricator.services.mozilla.com/D172936
|
|
|
|
|
|
|
| |
Per the proposal in https://github.com/w3c/csswg-drafts/issues/7747,
we change view-timeline-inset to have an initial value of auto.
Differential Revision: https://phabricator.services.mozilla.com/D173487
|
|
|
|
| |
Differential Revision: https://phabricator.services.mozilla.com/D172700
|
|
|
|
|
|
|
|
| |
Ideally we'd only update the attributes that actually changed. That's a
bit more work I can try to look into, but this and bug 1823686 should
improve things here.
Differential Revision: https://phabricator.services.mozilla.com/D173162
|
|
|
|
|
|
|
|
| |
This page seems to rely on this optimization being present. Optimizing
it is straight-forward. Why do they do that instead of using the #foo
syntax? Who knows.
Differential Revision: https://phabricator.services.mozilla.com/D173148
|
|
|
|
| |
Differential Revision: https://phabricator.services.mozilla.com/D173112
|
|
|
|
|
|
|
|
|
| |
Now that the none keyword is available, we can take it into account when
interpolating colors following the rules from the spec here:
https://drafts.csswg.org/css-color-4/#interpolation-missing
Differential Revision: https://phabricator.services.mozilla.com/D172666
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Make use of the new changes in the cssparser that allows 'none' keywords
in color components where allowed. We store the none values as 0.0 (as
per the spec) and mark the components with the flags. This way we don't
have to check anything on the components before doing calculations.
As this is the last part intended to be released for the new [color-4]
changes, I've also enabled the changes on nightly.
Differential Revision: https://phabricator.services.mozilla.com/D170208
|
|
|
|
|
|
|
|
|
|
| |
You can use this as:
input.try_parse(SupportsCondition::parse_for_import).ok()
Or so.
Differential Revision: https://phabricator.services.mozilla.com/D172668
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
:nth-child(... of <selector list>)
There are separate filters for IDs, classes, attribute local names, and
element state.
Also, we invalidate siblings of elements matched against the selector
list of :nth-child(... of <selector list>) by marking matched elements
with NODE_HAS_SLOW_SELECTOR_NTH_OF.
The only remaining invalidation case invalidation case is
`:nth-child(An+B of :has())` (bug 1818155), which should not block
shipping `layout.css.nth-child-of.enabled`, because :has(...) is still
being implemented (bug 418039).
Depends on D172352
Differential Revision: https://phabricator.services.mozilla.com/D171936
|
|
|
|
|
|
|
|
|
|
|
|
| |
Because restyle events cannot be posted for non-element nodes like the
shadow root, a child's siblings are restyled directly if its parent has
NODE_HAS_SLOW_SELECTOR or NODE_HAS_SLOW_SELECTOR_LATER_SIBLINGS but that
parent is the shadow root.
Drive-by, but braces were also added to some single-line "if" statements
in RestyleManager.
Differential Revision: https://phabricator.services.mozilla.com/D172352
|
|
|
|
|
|
| |
We implemented support for list-style-image anyways.
Differential Revision: https://phabricator.services.mozilla.com/D172343
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implemented the prefers-reduced-transparency media query for all
platforms.
Windows and Mac have specific settings which are used, others (Android
and Linux/GTK) have it enabled if prefers-reduced-motion is also enabled
as there is no dedicated setting to check.
Locked behind new pref `layout.css.prefers-reduced-transparency.enabled`,
off by default always for now.
Also added new WPT tests (none previously).
Demo video: https://goose.icu/firefox_prt.mp4
Test page: https://goose.icu/prefers-reduced-transparency
Differential Revision: https://phabricator.services.mozilla.com/D172424
|
|
|
|
| |
Differential Revision: https://phabricator.services.mozilla.com/D172430
|
|
|
|
|
|
|
| |
Having unused imports and undocumented functions trigger warnings that
don't build in automation.
Differential Revision: https://phabricator.services.mozilla.com/D172429
|
|
|
|
|
|
|
|
|
|
| |
Lengths using NaN and infinity are now serialized properly with some
improvements to computed values as well.
Also added a few minor new relevant WPT tests.
35 WPT tests newly pass :tada:
Differential Revision: https://phabricator.services.mozilla.com/D172183
|