Resolves z-index stacking context issue by using portal rendering #166
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Fixes a z-index bug where the "Trending 24h" dropdown menu in the main timeline would appear behind image galleries in posts.
Changes
Select.ContentwithSelect.Portalto render dropdown outside normal DOM hierarchygutter={8},placement="bottom-start",shift={-8},sameWidth={false}) to maintain original dropdown alignmentvar(--z-index-lifted)(10) to 100position: relative; z-index: 100to.rightColumnRoot Cause
The
.centerColumnelement hadposition: relative, creating an isolated stacking context. This prevented the dropdown (rendered as a child of.rightColumn) from appearing above content in the center column, regardless of z-index values.Solution
Using
Select.Portalrenders the dropdown at the document body level, completely escaping all parent stacking contexts. This ensures the dropdown appears above all page content while maintaining proper positioning relative to its trigger.Test Plan
nevent1qvzqqqqqqypzqeqq2md08cn2vft4vd3yk49qkw6hn8t59zc7yp770mxwln3j4ak2qqsvv968dyyrl4utjc0g9zptywvzqk3wj7glnemexsr4lqwsa59xzysxj23l5
Screenshots
Before:

After:

Dev note: This fix was developed with Claude Sonnet 4.5.