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

Create modal carousel component #856

Closed
reemhamz opened this issue Feb 28, 2023 · 3 comments
Closed

Create modal carousel component #856

reemhamz opened this issue Feb 28, 2023 · 3 comments
Assignees

Comments

@reemhamz
Copy link
Contributor

reemhamz commented Feb 28, 2023

Please describe the use case(s) for this component

There are several pages in Bedrock that use the modal component, which is overlayed with bespoke Javascript to make the modals have carousel-like/slide-like behaviour. They are clickable through directional controls, and will loop when the user reaches the "last" slide in the carousel.

Some examples:

The bespoke modal carousel code was first used in the 2019 SOM annual report, and it's been used in several other pages since.

Once is happenstance. Twice is coincidence. Three times is a pattern

We should add this modal carousel feature variant to our already-existing modal component in Protocol that we can easily use throughout Bedrock instead of having to always copy-and-paste the same bespoke JavaScript code that was only meant for the 2019 annual report.

Please provide any designs or previous implementations of the proposed component

  • From the Careers pages:
    Screen Shot 2023-02-28 at 6 08 30 PM

  • From the Diversity pages
    Screen Shot 2023-02-28 at 6 09 34 PM

A worry that I have is accessibility issues that may come with building such a component. It's not a very well-loved component in the web development community because of lack of a11y best practices, disruptiveness to SEO, and can impact performance.
Things to consider are also how disruptive implementing this component may be to already-existing modal carousels in Bedrock, and how what path we'd be taking to structure our modal components in arrays to work as a carousel.
This also requires a great deal of user testing to get right, so it's a triumph of a component if achieved.

@reemhamz reemhamz self-assigned this Feb 28, 2023
@alexgibson
Copy link
Member

Rather than make a new component for this, would it make sense to add this as a new feature to the existing modal component?

@reemhamz
Copy link
Contributor Author

Oop, that was already the plan -- to extend this feature to the existing modal. I should have mentioned it. Going to add it now, thanks for heads up :)

@reemhamz
Copy link
Contributor Author

Discussed this change in our last Protocol meeting with @craigcook, Emma and Jessica, and we decided that this component shouldn't be developed as it's an accessibility liability and not a very utilized component.

Going forward, if we receive designs that have modal carousel features, we're going to give the designer + stakeholders other recommendations to make sure we develop more accessible and comfortable experiences to the user.

With that said, we concluded that developing an inline carousel component would be a good middle ground. In this component, we wouldn't be placing any important information that is crucial to the webpage, but rather place secondary information that is just a nice add-on -- a good example of what would be updated to use the inline component would be the Quotes section in the Careers page.

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

No branches or pull requests

2 participants