Skip to content

Commit

Permalink
Remove support for scrollable elements
Browse files Browse the repository at this point in the history
Firefox has sadly removed support for the `overflow` and `underflow`
events which powered this feature: https://bugzilla.mozilla.org/show_bug.cgi?id=1888737

I don't know of any other way to implement it, so I removed it.
  • Loading branch information
lydell committed Aug 17, 2024
1 parent 6fa26b1 commit 5a56c88
Show file tree
Hide file tree
Showing 10 changed files with 10 additions and 286 deletions.
1 change: 0 additions & 1 deletion docs/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,6 @@ const SECTIONS = [
.
</li>
<li>Tracking of elements with click listeners.</li>
<li>Tracking of scrollable elements in Firefox.</li>
<li>Tracking elements and updating hints while showing them.</li>
<li>Text based hint positioning.</li>
<li>
Expand Down
1 change: 0 additions & 1 deletion html/experiments/intersection-observer-cover.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@
observer.observe(cover);

window.addEventListener("resize", updateCover);
window.addEventListener("underflow", updateCover);

function updateCover() {
const viewport = getViewport();
Expand Down
17 changes: 0 additions & 17 deletions html/hint-position/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -479,17 +479,6 @@
margin: 0;
padding-bottom: 50px;
}

.scroll {
border: 1px solid black;
overflow: auto;
height: 100px;
width: 200px;
}

.scroll > p {
margin-bottom: 200px;
}
</style>
</head>
<body>
Expand Down Expand Up @@ -1065,12 +1054,6 @@ <h2>Images taller than their link</h2>
</a>
</p>

<h2>Scrollable element</h2>
<p>The hint should be placed at the edge, not at children text.</p>
<div class="scroll">
<p>Scrollable element</p>
</div>

<h2>Selectable elements</h2>
<div style="max-width: 500px">
<p>
Expand Down
117 changes: 0 additions & 117 deletions html/scroll/index.html

This file was deleted.

1 change: 0 additions & 1 deletion html/untrusted-events/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@
"clickable-event",
"label",
"link",
"scrollable",
"textarea",
],
viewports: [
Expand Down
1 change: 0 additions & 1 deletion src/background/Program.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2369,7 +2369,6 @@ const CLICK_TYPES: ElementTypes = [
"clickable-event",
"label",
"link",
"scrollable",
"textarea",
];

Expand Down
6 changes: 0 additions & 6 deletions src/renderer/Program.ts
Original file line number Diff line number Diff line change
Expand Up @@ -431,12 +431,6 @@ export default class RendererProgram {
"resize",
this.onResize.bind(this),
"RendererProgram#onResize"
),
addEventListener(
window,
"underflow",
this.onResize.bind(this),
"RendererProgram#onResize"
)
);

Expand Down
1 change: 0 additions & 1 deletion src/shared/hints.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ export const ElementType = stringUnion({
clickable: null,
label: null,
link: null,
scrollable: null,
selectable: null,
textarea: null,
});
Expand Down
Loading

0 comments on commit 5a56c88

Please sign in to comment.