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(UI): tabsbar dropdown button visibility #305

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Darshan808
Copy link
Contributor

Fixes #304

This pull request fixes the issue of tabsbar dropdown button being visible even when tabs bar is not being overflown by ciruit buttons. This was creating a confusion (which i faced too) about the function of the dropdown button when the tabsbar isn't overflowing. For this, I added a V-if directive with computed property which checks whether the tabsbar has been overflown or not and conditionally renders the dropdown button on tabsbar. Now the dropdown button now only appears when necessary, improving the UI clarity and user experience.

I used two browser apis mutationObserver and resizeObserver for observing changes in size of tabsbar and checking overflow on insertion of new circuit buttons. Since resizeObserver is not supported in older browsers, i had to use a polyfill for it which i installed using npm.

Impact

User Experience: Enhances user experience by preventing confusion about the purpose of the dropdown button when there is no overflow.
Performance: Observers are used efficiently to manage and trigger updates only on actual changes to the tabs bar, ensuring minimal performance impact.

Testing: Manual testing was performed to ensure that the dropdown button now only appears when the tabs bar is actually overflowing

Screenshot 2024-05-08 183611
Screenshot 2024-05-08 183934

Copy link

netlify bot commented May 8, 2024

Deploy Preview for circuitverse ready!

Name Link
🔨 Latest commit b611d37
🔍 Latest deploy log https://app.netlify.com/sites/circuitverse/deploys/663b9e71c8ac76000856d271
😎 Deploy Preview https://deploy-preview-305--circuitverse.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

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.

🐞 Bug: [ UI Issue: Dropdown Button Remains Visible Even When Tabs Bar is Not Overflowed ]
1 participant