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

fixes #1009 : table duplication issue when screen size less than 800px #1040

Merged
merged 1 commit into from
Nov 14, 2024

Conversation

rahulptl165
Copy link
Contributor

Summary

This pull request addresses an issue where the .stacktable components (stacktable.small-only and stacktable.large-only) were being activated simultaneously on screen sizes below 800px, causing table duplication. Additionally, it ensures that the stacktable() function is called only once after all table content has been fully updated to avoid redundancy or conflicts.

Motivation

The issue arises from calling the stacktable() function multiple times when the table content changes (e.g., when pagination is applied, or the number of table entries is updated). This results in a table duplication issue when both the .stacktable.small-only and .stacktable.large-only classes are triggered at the same time on smaller screens. The goal is to ensure proper handling of table initialization and avoid unnecessary re-initializations.

Testing

Verified that the table displays correctly on both small and large screen sizes, without duplication.
Tested across various screen sizes to ensure the appropriate classes (stacktable.small-only and stacktable.large-only) are applied without overlap.

##Screenshot
Screenshot 2024-11-14 180418

@birm birm changed the base branch from master to develop November 14, 2024 17:36
Copy link
Member

@birm birm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely! Glad you identified the root cause. Your PR and documentation is also quite solid.

I nudged the PR over to the develop branch, since that's where we do active development.

Thanks for the fix!

@birm birm merged commit a703ca5 into camicroscope:develop Nov 14, 2024
1 of 2 checks passed
@rahulptl165
Copy link
Contributor Author

Thanks! Glad the fix and docs were helpful. Noted on the develop branch—I'll keep that in mind for next time!

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.

2 participants