You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
First, thank you for this amazing package. It perfectly meets my requirements.
I am creating a news feed application where news items are displayed in cards. I am using the Masonry layout to handle the different card sizes, as some cards include images while others do not.
The Masonry layout is working well overall, but I have encountered an issue when implementing a filter functionality. The filter allows users to sort news based on their impact levels: high, medium, and low. Currently, there are 3 high-impact news items, and more than 60 items for both medium and low impact.
When switching to display only high-impact news, I encounter the following error:
Actual Behavior
An error occurs when switching to the high-impact filter, preventing the news items from being displayed correctly. while switching to others work fine as long as the there is large set of data
To Reproduce
Implement a Masonry layout for news cards.
Add a filter functionality to sort news by impact levels (high, medium, low).
Populate the feed with 3 high-impact news items and over 60 medium and low impact news items.
Switch to the high-impact filter.
Expected behavior
The Masonry layout should correctly display the 3 high-impact news items without any errors.
Screenshots
OS: [macOS]
Browser [ chrome,]
The text was updated successfully, but these errors were encountered:
Describe the bug
First, thank you for this amazing package. It perfectly meets my requirements.
I am creating a news feed application where news items are displayed in cards. I am using the Masonry layout to handle the different card sizes, as some cards include images while others do not.
The Masonry layout is working well overall, but I have encountered an issue when implementing a filter functionality. The filter allows users to sort news based on their impact levels: high, medium, and low. Currently, there are 3 high-impact news items, and more than 60 items for both medium and low impact.
When switching to display only high-impact news, I encounter the following error:
` const filterByImpactHigh = filteredData?.filter((item) => item?.impact === 'High');
const filterByImpactMedium = filteredData?.filter((item) => item?.impact === 'Medium');
const filterByImpactLow = filteredData?.filter((item) => item?.impact=== 'Low');
const dataToDisplay =
tab === '0'
? filteredData
: tab === '1'
? filterByImpactHigh
: tab === '2'
? filterByImpactMedium
: filterByImpactLow;
`
` <Box sx={{ margin: '1rem 0', direction: 'rtl' }}>
{dataToDisplay?.length > 0 &&
<Masonry
items={dataToDisplay}
columnGutter={10}
columnWidth={250}
overscanBy={1}
render={({ data}: any) => {
Actual Behavior
An error occurs when switching to the high-impact filter, preventing the news items from being displayed correctly. while switching to others work fine as long as the there is large set of data
To Reproduce
Expected behavior
The Masonry layout should correctly display the 3 high-impact news items without any errors.
Screenshots
The text was updated successfully, but these errors were encountered: