bramus / bramus/get-containing-block
Wrong containing block identified for elements with an animation
- Dominant language
- TypeScript
- Stars
- 3
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
1. Visit https://scroll-driven-animations.style/
2. Inspect one of the buttons in the cards
3. Execute the following:
```js
const { getContainingBlock } = await import("https://esm.sh/get-containing-block@1.0.3");
$0.style.position = 'absolute';
$0.style.top = 0;
getContainingBlock($0);
```
4. Check the reported contents
The reported containing block is `null` (ICB) whereas it should be the wrapping `.card` here is the CB.
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the report on https://scroll-driven-animations.style/ using the provided import and steps, then start at the getContainingBlock entry point. Check the containing-block detection for an absolutely positioned card button and make the result identify the wrapping .card rather than null; verify the reported contents match the expected containing block.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100