From 0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Fri, 19 Apr 2024 03:47:29 +0200 Subject: Adding upstream version 115.8.0esr. Signed-off-by: Daniel Baumann --- .../experimental-features/resources/common.js | 94 +++++++++++++++++++++ ...s-without-user-activation-iframe-tentative.html | 47 +++++++++++ .../resources/lazyload-contents.html | 13 +++ .../experimental-features/resources/lazyload.png | Bin 0 -> 20819 bytes ...ions-policy-private-state-token-redemption.html | 61 +++++++++++++ .../resources/unload-helper.js | 41 +++++++++ .../vertical-scroll-scrollable-content.html | 16 ++++ .../resources/vertical-scroll-scrollbar-ref.html | 13 +++ .../resources/vertical-scroll-scrollintoview.html | 45 ++++++++++ .../resources/vertical-scroll-touch-action.html | 14 +++ .../resources/vertical-scroll-touch-block.html | 42 +++++++++ .../resources/vertical-scroll-wheel-block.html | 22 +++++ .../resources/vertical-scroll.js | 25 ++++++ 13 files changed, 433 insertions(+) create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/common.js create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/focus-without-user-activation-iframe-tentative.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/lazyload-contents.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/lazyload.png create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/permissions-policy-private-state-token-redemption.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/unload-helper.js create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-scrollable-content.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-scrollbar-ref.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-scrollintoview.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-action.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-block.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-wheel-block.html create mode 100644 testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll.js (limited to 'testing/web-platform/tests/permissions-policy/experimental-features/resources') diff --git a/testing/web-platform/tests/permissions-policy/experimental-features/resources/common.js b/testing/web-platform/tests/permissions-policy/experimental-features/resources/common.js new file mode 100644 index 0000000000..308f787da6 --- /dev/null +++ b/testing/web-platform/tests/permissions-policy/experimental-features/resources/common.js @@ -0,0 +1,94 @@ +const url_base = "/permissions-policy/experimental-features/resources/"; +window.messageResponseCallback = null; + +function setFeatureState(iframe, feature, origins) { + iframe.setAttribute("allow", `${feature} ${origins};`); +} + +// Returns a promise which is resolved when the + + diff --git a/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-scrollintoview.html b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-scrollintoview.html new file mode 100644 index 0000000000..7bed27c260 --- /dev/null +++ b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-scrollintoview.html @@ -0,0 +1,45 @@ + + +
+
+ +
+ diff --git a/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-action.html b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-action.html new file mode 100644 index 0000000000..51b715f30a --- /dev/null +++ b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-action.html @@ -0,0 +1,14 @@ + + + +

This page blocks all 'touch-action'.

+ diff --git a/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-block.html b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-block.html new file mode 100644 index 0000000000..4c204055af --- /dev/null +++ b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-touch-block.html @@ -0,0 +1,42 @@ + + + +
+

This page blocks 'touchstart' and 'touchmove'.

+
+ + diff --git a/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-wheel-block.html b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-wheel-block.html new file mode 100644 index 0000000000..21fc2b9b39 --- /dev/null +++ b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll-wheel-block.html @@ -0,0 +1,22 @@ + + + +

This page blocks all 'mouse-wheel'.

+ + diff --git a/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll.js b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll.js new file mode 100644 index 0000000000..88835cc602 --- /dev/null +++ b/testing/web-platform/tests/permissions-policy/experimental-features/resources/vertical-scroll.js @@ -0,0 +1,25 @@ +function rectMaxY(rect) { + return rect.height + rect.y; +} + +function rectMaxX(rect) { + return rect.width + rect.x; +} + +function isEmptyRect(rect) { + return !rect.width || !rect.height; +} + +// Returns true if the given rectangles intersect. +function rects_intersect(rect1, rect2) { + if (isEmptyRect(rect1) || isEmptyRect(rect2)) + return false; + return rect1.x < rectMaxX(rect2) && + rect2.x < rectMaxX(rect1) && + rect1.y < rectMaxY(rect2) && + rect2.y < rectMaxY(rect1); +} + +function rectToString(rect) { + return `Location: (${rect.x}, ${rect.y}) Size: (${rect.width}, ${rect.height})`; +} -- cgit v1.2.3