Commit graph

696 commits

Author SHA1 Message Date
Basilisk-Dev
3df0ae2323 Revert "Support CSS shadow parts"
This reverts commit a852c0a86a.
2026-06-26 11:54:15 -07:00
Basilisk-Dev
a852c0a86a Support CSS shadow parts 2026-06-25 22:40:07 -07:00
wuggy
b913fa62d9 Enhance DNS prefetching by resolving URIs against the document base URI 2026-04-23 22:19:46 -07:00
wuggy
5212aa7bf1 Revert "implement lazy-loading"
This reverts commit 629f4db8fe.
2026-04-20 22:11:06 -07:00
wuggy
62e367cb90 Revert "Issue #1053 - Part 1c: Remove references to mobile/android targets and paths"
This reverts commit b21588597c.
2026-04-08 15:27:04 -07:00
ownedbywuigi
629f4db8fe implement lazy-loading 2026-03-27 12:38:53 +00:00
ownedbywuigi
d34a9c5778 Refactor MaybeCheckSameAttrVal to streamline old value storage for custom elements 2026-03-27 11:34:40 +00:00
Moonchild
aee2800d48 Issue #2914 - Explicitly allow mixed content websockets on localhost.
This carves out an exception for hard-coded loopback addresses to allow
`ws:` connections from `https:` to allow mixed-mode from secure pages.

Resolves #2914
2026-03-08 22:43:35 +00:00
roytam1
ae1f9364cd Merge remote-tracking branch 'origin/tracking' into custom 2025-08-14 08:55:16 +08:00
Moonchild
df3b213459 Issue #2837 - Implement prefers-reduced-motion media query.
Resolves #2837
2025-08-14 08:11:04 +08:00
roytam1
db9b04cc44 Merge remote-tracking branch 'origin/tracking' into custom 2025-08-04 21:33:36 +08:00
Moonchild
a036cfeb69 Issue #2714 - Implement the Visual Viewport API
This DOM/Web API is entirely irrelevant for desktop use.
We give back the width/height of the root scrollframe of content and
for scale we pass forward our dpp resolution (usually 1.0).
Since we have no "no touch" zones in our content on desktop,. the rest
(origin and offset) is hard-coded to (0,0).
2025-08-04 21:32:39 +08:00
roytam1
3553319265 Merge remote-tracking branch 'origin/tracking' into custom 2025-07-31 22:08:44 +08:00
Moonchild
ace2c1c1ee [DOM] Simplify <object> scheme check code and fix plugin handling.
Trying to do a positive check on nested URIs apparently doesn't work,
but the handling could be simplified to just check for non-null mURI
instead - this also fixes plugin loading (which broke with the previous
check).
2025-07-31 22:08:07 +08:00
roytam1
a88fbfa671 Merge remote-tracking branch 'origin/tracking' into custom 2025-07-31 07:41:04 +08:00
Moonchild
838be26145 [DOM] Fix crash in <object> scheme checking code.
If a website would nor supply a URI for object loading code, the browser
would crash on a null deref.
This reintroduces the nestedURI check to make sure we have a valid URI.
2025-07-31 07:40:43 +08:00
roytam1
4c1a4a4402 Merge remote-tracking branch 'origin/tracking' into custom 2025-07-29 10:44:33 +08:00
MeladJM
4cdfb9e16b Issue #2790 - Part 3: Address BZ bug 1849122 and resolve build issues 2025-07-29 10:14:48 +08:00
MeladJM
d99eab0d9d Issue #2790 - Part 2: Address BZ bugs: 1355438 and 1341230 2025-07-29 10:14:23 +08:00
roytam1
7e0ddfef73 Merge remote-tracking branch 'origin/tracking' into custom 2025-07-25 20:53:55 +08:00
Francis Dominic Fajardo
03f29e75ec Issue #2828 - Part 3: Refactor selector matching and rule cascade data into separate files/classes 2025-07-25 20:47:06 +08:00
roytam1
be6796bb20 Merge remote-tracking branch 'origin/tracking' into custom 2025-07-25 07:33:44 +08:00
Moonchild
f902d2ad0e [DOM] Make object loading use an explicit scheme whitelist. 2025-07-25 07:33:16 +08:00
roytam1
fbb39ce322 Merge remote-tracking branch 'origin/tracking' into custom 2025-07-08 10:02:11 +08:00
Andy
b11affbdf3 Issue #2106 - Clean-up: Un-prefix -moz-user-select in Comments 2025-07-08 10:01:21 +08:00
Andy
abb891ff26 Issue #2106 - Follow-up: Un-prefix DOM Attribute MozUserSelect 2025-07-08 10:00:32 +08:00
Andy
1a5b3dcae6 Issue #2106 - Follow-up: Additional Un-prefixing 2025-07-08 10:00:02 +08:00
roytam1
9175504ffc Merge remote-tracking branch 'origin/tracking' into custom 2025-07-04 22:28:17 +08:00
Andy
4cc014cb6b Unprefix -moz-read-write / -moz-read-only 2025-07-04 22:27:22 +08:00
roytam1
f4d2bf6c3d Merge remote-tracking branch 'origin/tracking' into custom 2025-06-27 23:33:55 +08:00
Moonchild
0c2770ff7b [DOM] Update YouTube embed rewrites.
Youtube's usage patterns have changed regarding video embeds, so we can
remove special handling for the enablejsapi flag.
Applies YouTube embed URL replacement to the path component only.
2025-06-27 23:30:17 +08:00
Moonchild
3c2c7ce1e2 No issue - Escape < and > in element attribute values.
Per spec, extend escaping of attribute value characters to include
`<` and `>`. We already did this for text fragments, and it makes sense
to apply the same to attribute values. We are at parity with mainstream
that default-escape attribute values this way in current releases.
2025-06-27 23:29:12 +08:00
roytam1
6414271c91 Merge remote-tracking branch 'origin/tracking' into custom 2025-06-17 09:32:50 +08:00
Moonchild
2782cded29 Issue #2752 - Change DOMMatrix Rotate{Self}() to the current spec.
This changes Rotate{Self}(angle, translateX, translateY) to
Rotate{Self}(rotateX, rotateY, rotateZ) per the spec.
The resulting matrix will be a 3DMatrix

Resolves #2752
2025-06-17 09:26:52 +08:00
Moonchild
c3f1c0cdba Issue #2721 - Remove nsILinkHandler.
This interface inly has a single implementation behind it, which is also
only used in 2 places after the previous commit. That's a lot of
additional complexity and compiler indirection for no good reason.
This change removes the interface and uses direct nsDocShell::Cast calls
instead of going through the interface in the few places left now that
we no longer build on a presentation context for links.
2025-06-17 09:25:00 +08:00
Moonchild
37de431ac0 Issue #2721 - Create special case exception for <A>.Click() outside of DOM
This removes the requirement for there to be a non-null PresShell to
dispatch `Click()` events on `<A>` elements (only), since the exception
to the rule has propagated to the spec.

With these changes it should now be possible do create an anchor and
`Click()` on it from JS without actually first attaching it to the DOM
of the presented document, as abused by scripted downloads in pages
(instead of using the A attribute to custom-name downloads).
2025-06-17 09:24:44 +08:00
roytam1
e72f8a3a81 Merge remote-tracking branch 'origin/tracking' into custom 2025-05-14 14:36:05 +08:00
Moonchild
53a6f6349d Issue #2736 - Part 14: Make CSP-enabled available to workers. 2025-05-14 14:35:35 +08:00
Moonchild
60ad5b2ffd Issue #2736 - Part 12: Re-work style <link> href attribute.
Use subject principal as triggering principal in style <link> "href"
attribute.
2025-05-14 14:33:26 +08:00
Moonchild
2416e71cd3 Issue #2736 - Part 7: Re-work <frame> and <iframe> src attribute.
Use subject principal as triggering principal in <iframe>/<frame> "src" attribute.
2025-05-14 14:26:23 +08:00
Moonchild
2bdb9f3d85 Issue #2736 - Part 5: Re-work img <srcset> attribute.
Use subject principal as triggering principal in <img> "srcset" attribute.
2025-05-14 14:23:33 +08:00
Moonchild
c8db9efb3c Issue #2736 - Part 4: Re-work img <src> attribute.
Use subject principal as triggering principal in <img> "src" attribute.
Also get rid of the `BeforeMaybeChangeAttr`/`AfterMaybeChangeAttr` dance:
It makes more logical sense for these effects to happen _after_ the
attribute has actually been changed.
2025-05-14 14:23:17 +08:00
Moonchild
824d0cad58 Issue #2736 - Part 2: Pass subject principal to SetAttribute and friends.
In order to tailor certain security checks to the caller that is
attempting to load a particular piece of content, we need to be able to
attach an appropriate triggering principal to the corresponding requests.

Since most HTML content is loaded based on attribute values, this means
capturing the subject principal of the caller who sets those attributes,
which in turn means we need to make it available to `AfterSetAttr` hooks
on all relevant element types.
2025-05-14 14:22:13 +08:00
Moonchild
9ad680cfc4 Issue #2736 - Part 1: Provide more consistent principals to CSP.
We're currently fairly vague and inconsistent about the values we provide to
content policy implementations for requestOrigin and requestPrincipal. In some
cases they're the triggering principal, sometimes the loading principal,
sometimes the channel principal.

Our existing content policy implementations which require or expect a
loading principal currently retrieve it from the context node.
Since no current callers require the principal to be the loading
principal, and some already expect it to be the triggering principal
(which there's currently no other way to retrieve), a choice was made
to pass the triggering principal whenever possible, but use the loading
principal to determine the origin URL.
2025-05-14 14:21:46 +08:00
roytam1
6792dc4b66 Merge remote-tracking branch 'origin/tracking' into custom 2025-04-30 23:06:47 +08:00
Moonchild
fd4a224d1d Issue #2737 - Part 1: Base implementation of SVGGeometryElement.
Mostly mechanical changes to generalize path geometry for all SVG draw
elements. No user-exposed changes.
2025-04-30 23:02:16 +08:00
Moonchild
0331e633bd Issue #2728 - Remove obsolete CSP referrer policy.
This has been superseded by the dedicated Referrer-policy header.
Resolves #2728
2025-04-30 22:58:43 +08:00
roytam1
072f98c9ae Merge remote-tracking branch 'origin/tracking' into custom 2025-03-23 12:52:24 +08:00
Moonchild
f1c456c625 Issue #2713 - Check for NaN before std::min/max() in DOMQuad and DOMRect.
If there is a NaN involved we should not return 0 here.
2025-03-23 12:52:03 +08:00
roytam1
e2f07956fb Merge remote-tracking branch 'origin/tracking' into custom 2025-03-23 12:27:56 +08:00