Space Tourism - Built With React/ Data.json/ SCSS
Design comparison
Solution retrospective
I loved making this project! Lots of nice design challenges. Always pushing myself to learn more about the React layer.
The biggest hurdle in this was finally getting a good fix/workaround for GH-Pages not supporting multi-page React apps using <HashRouter>
, which is a lot simpler than using the 404 redirect method that I've tried in the past.
I was very happy with the SwiperJS integration I use for showing the data on the inner pages. Using this library I was able to add subtle animation effects for transitioning from one slide to the next. In my opinion, subtle animations give for a much nicer UX, nothing is jarring.
Anyway, poke at my code and let me know if you would have done something differently or let me know if something could be done better. Always happy to take constructive criticism.
Community feedback
- @ApplePieGiraffePosted almost 2 years ago
Greetings, Steven Portas! 👋
Amazing job on this challenge! 👏 Your solution looks and feels great and I really like some of the small touches you added (such as the transitions and favicon). 👍
Just a few tiny suggestions/tips!
It might be worth adding some headings to pages for accessibility (e.g., such as by making the "01 Pick Your Destination" text a heading) and using
button
elements for the tabs that change the content of pages to make your HTML more semantic (as this is typically recommended over trying to make elements likediv
s orspan
s interactive).Adding an
aria-label
to the mobile menu button would be a good idea since there isn't any text inside of it to identify it.Also, you don't need to add "Image of..." in your alt text for images, as screen readers will announce that they have found an image before proceeding to the read the alt text.
The logo doesn't need an
aria-label
since it is an image element and already hasalt
text. Thataria-label
would be better placed on thea
element itself. 😉Hope you find these tips helpful. 😊
Keep coding (and happy coding, too)! 😁
Marked as helpful1@satropPosted almost 2 years ago@ApplePieGiraffe awesome! I totally space on the ADA in a few places because I was over concentrating on fixing the routing issue with React and gh-pages that I forgot to do my accessibility pass! But I really do appreciate you looking closely enough to point that out, I’ll go back and fix them.
As for the buttons not being button I was positive that SwiperJS was taking care of that. So I’ll have a look at that as well.
1@satropPosted almost 2 years ago@ApplePieGiraffe Just this second went back in and made all but one update that you recommended.
I didn't change the spans to button elements. I went back and had a wee look and I thought SwiperJS was doing something to this situation and I was right. The spans have an added role attribute of "button". So that will make sure it's more in tune with semantics.
<span class="swiper-pagination-bullet swiper-pagination-bullet-active" tabindex="0" role="button" aria-label="Go to slide 1" aria-current="true"></span>
1@ApplePieGiraffePosted almost 2 years ago@satrop
Haha, I often do the same thing! It's easy to get caught up in JS sometimes. 😆 Glad that helped! 👍
0
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord