Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/manga grid infinite item width #376

Merged
merged 2 commits into from
Jun 17, 2023
Merged

Fix/manga grid infinite item width #376

merged 2 commits into from
Jun 17, 2023

Conversation

schroda
Copy link
Collaborator

@schroda schroda commented Jun 17, 2023

No description provided.

schroda added 2 commits June 17, 2023 20:41
Was unnecessarily calculated on every item render
Hook only run once, which could lead to an issue where the grid item width was calculated to be infinite.
Could be that this is only an issue in dev mode due to react-strict mode.
@schroda schroda merged commit 48d559e into Suwayomi:master Jun 17, 2023
@schroda schroda deleted the fix/manga_grid_infinite_item_width branch June 17, 2023 18:53
schroda added a commit that referenced this pull request Jun 17, 2023
* Revert "Fix/manga grid infinite item width (#376)"

This reverts commit 48d559e

This fixed (and worked as expected in dev mode) the very rare issue in dev mode (you had to load the page with a small screen size and increase the screen size before the grid and grid items were rendered) and caused it frequently in production build in the Library grid when switching categories

* Fallback grid dimensions to current window dimensions

Hook only run once, which could lead to an issue where the grid item width was calculated to be infinite (e.g. in SearchAll due to strict-mode behaviour in the dev mode).
Could be that this is only an issue in dev mode due to react-strict mode.

* Remove unused "height" grid dimensions property
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant