- 9
- 21 782
CSS {de}Coder
United States
Приєднався 2 гру 2023
CSS {de}Coder is a place to share modern web styling techniques that help you embrace the cascade!
CSS is a lot more than changing text colors and fonts. I often hear that CSS isn't a programming language and that the frustrations of styling are too great of a barrier to overcome. I started this channel to change the way CSS is viewed and share all the cool things that CSS can do. I'll do my best to bring to light the magic and beauty of CSS!
CSS is a lot more than changing text colors and fonts. I often hear that CSS isn't a programming language and that the frustrations of styling are too great of a barrier to overcome. I started this channel to change the way CSS is viewed and share all the cool things that CSS can do. I'll do my best to bring to light the magic and beauty of CSS!
How to build an accessible accordion: easy HTML enhancements for improved keyboard support
Did you know that about 20% of people surfing the web, do so with the help of assistive technology. In any given day that could be roughly 1 billion people! According to the 2024 WebAIM 1 Million survey, an average of 56 a11y errors were found on the homepages sampled. That’s a 13% increase from the 2023 survey. SO it was no surprise to me when I came across this accordion component that was not keyboard accessible. You might be like me and work in a code base where it’s not always possible to alter HTML. So in this video I’ll show you how I updated this accordion to make it accessible, all without altering the HTML. Then I’ll show you how you can cut your coding time in half by using native HTML elements and only 6 lines of JS. So if you’re ready, fire up your favorite editor and let’s code!
WCAG Understanding SC 2.1.1:
www.w3.org/WAI/WCAG22/Understanding/keyboard.html
WCAG Understanding SC 2.5.3: www.w3.org/WAI/WCAG22/Understanding/label-in-name.html
APG Button pattern: www.w3.org/WAI/ARIA/apg/patterns/button/
Timestamps:
00:00 - Intro
00:44 - Enhancing HTML with ARIA
03:05 - Adding keyboard support via JS
05:18 - Improving accessible names
08:32 - Using the details & summary elements instead
Music from #Uppbeat (free for Creators!):
uppbeat.io/t/moire/new-life
License code: SOE1S7L5DZHTBUOJ
WCAG Understanding SC 2.1.1:
www.w3.org/WAI/WCAG22/Understanding/keyboard.html
WCAG Understanding SC 2.5.3: www.w3.org/WAI/WCAG22/Understanding/label-in-name.html
APG Button pattern: www.w3.org/WAI/ARIA/apg/patterns/button/
Timestamps:
00:00 - Intro
00:44 - Enhancing HTML with ARIA
03:05 - Adding keyboard support via JS
05:18 - Improving accessible names
08:32 - Using the details & summary elements instead
Music from #Uppbeat (free for Creators!):
uppbeat.io/t/moire/new-life
License code: SOE1S7L5DZHTBUOJ
Переглядів: 208
Відео
5 useful tips to help you improve your CSS TODAY!!
Переглядів 1,7 тис.4 місяці тому
Writing CSS can be tricky-getting everything to look just right across different browsers and devices is no small feat. But don’t worry, I’ve got you covered! In this video, I’ll share my top 5 tips and techniques to make your CSS cleaner, more efficient, and easier to maintain. Let’s code! 🔗Links & Resources: CSS Nesting: developer.mozilla.org/en-US/docs/Web/CSS/CSS_nesting/Using_CSS_nesting c...
Animating between states is SUPER EASY thanks to the View Transition API!
Переглядів 7 тис.5 місяців тому
The View Transition API allows developers to easily create custom transitions between different states and pages. Smooth transitions improve the user experience by reducing the effort needed to navigate, by making pages feel faster and more responsive, and can help users understand where they are within your site. In this video, I’ll demonstrate how to leverage the crossfade provided by the API...
Boost accessibility with progressive enhancements for tabs | HTML, CSS, & JS
Переглядів 4077 місяців тому
Creating accessible tabs can seem a bit daunting. The best approach is to start out with a strong foundation of semantic HTML and layer in progressive enhancements as you go. Building for inclusion ensures your projects provide the best experience to as many people as possible. Links & Resources GitHub repo: github.com/Alliemack77/accessible-tab-interface ARIA APG: www.w3.org/WAI/ARIA/apg/patte...
How to build a responsive layout with HTML, CSS, & JavaScript | Part 3: Article section
Переглядів 7069 місяців тому
Building responsive websites that look beautiful on every screen has never been easier! In this 3 part mini-series, I’ll show you how to build this Frontend Mentor landing page from scratch. In this video, I'll use a flexible grid to build the last section - the list of articles. So if you're ready, fire up your favorite editor, and let’s code! Links & Resources Github repo for Part 3: github.c...
How to build a responsive layout with HTML, CSS, & JavaScript | Part 2: Hero layout with subgrid
Переглядів 4089 місяців тому
Building responsive websites that look beautiful on every screen has never been easier! In this 3 part mini-series, I’ll show you how to build this Frontend Mentor landing page from scratch. In this video, I'll use CSS grid and subgrid to build a flexible hero section. So if you're ready, fire up your favorite editor, and let’s code! Links & Resources Github repo for Part 2: github.com/Alliemac...
How to build a responsive layout with HTML, CSS, & JavaScript | Part I: Accessible navigation menu
Переглядів 2,3 тис.9 місяців тому
Building responsive websites that look beautiful on every screen has never been easier! In this 3 part mini-series, I’ll show you how to build this Frontend Mentor landing page from scratch. In this video, I'll use CSS Grid to build a flexible and accessible navigation menu. So if you're ready, fire up your favorite editor, and let’s code! Links & Resources Github repo for Part 1: github.com/Al...
CSS Only Scroll Animations Are AMAZING!
Переглядів 8 тис.11 місяців тому
CSS-only scroll animations are here! The new CSS animation-timeline properties make it easy to create scroll-linked animations without using Javascript! This CSS tutorial will show you how to use these new properties and how to create a cool 3D transformation! So in the words of the Doctor himself, Allons-y!! Can I use...animation-timeline: caniuse.com/?search=animation-timeline animation-timel...
Build flexible layouts (without wrapper classes) using CSS Grid
Переглядів 855Рік тому
Wrapper classes are great for centering content and controlling width, but what happens if you get a design that requires the content to spill outside the wrapper to the edge of the viewport? In this video tutorial, I recreate the function of a wrapper class using a 4-column grid. Finished code: codepen.io/alliemack/pen/KKEPaKb?editors=1100 GitHub repo: github.com/Alliemack77/alternatives-to-th...
If you click on the content in the panel, the tab closes. Can this be fixed?
Thank you, Allison!
This is some excellent a11y content. You nailed the what and why in a very compelling structure that is easy to follow and comprehend. What I appreciate the most is that you're using real world examples that tackle most accessibility concepts in a way that can be applied to other component like markup as well. Keep up the good work and I am looking forward to more great content from you.
Much appreciated! I'm trying to bring more attention to accessibility, glad to hear you found it useful.
Very very cool content. Something people have ignored for too long. Great job!
Thanks! I'm hoping to bring more attention to accessibility.
Love the a11y content ! Would be great to see it built properly from the start , not with everything as divs and then adding roles as needed. When following the recommended pattern on the aria authoring practices guide, I get so confused why it says not to use in production environments. I have seen another pattern since you mentioned JavaScript not loading, where they make the heading and use a link instead of a button that’s set to the panel on question; in case the JavaScript doesn’t load. But then they have to either replace the <a> with a button on the DOM or I guess give the <a> a role of button ? But at least the content is accessible if the JavaScript doesn’t load , it’s not hidden away and it’s still linked to as well as arja-labelledby the heading piece. Luckily we will have support to customize and animate the details/summary soonish!!! Fun to play with on chrome in the meantime !
Hi @@clevermissfox ! I went back and forth about building an accessible accordion from the start. I work with a legacy codebase where I can't always alter the HTML. I thought it would be more beneficial to document the process of adding enhancements since many people may be in a similar situation. Plus there are already tons of tutorials on how to use the details and summary elements. Anytime you add aria, you should be testing for usability. That was something I didn't mention in the video, and the reason why the APG patterns are only suggestions. They assume you will be testing for usability and therefore may find a better pattern based on your testing. The APG is a great place to start, but ultimately the results of your testing will always be the deciding factor. Thanks for watching!
Great to see some content taking accessibility into account. I would not add the "toggle" at the start of the name of the button however. For users using speech recognition software, it may be difficult to find buttons by their name I think. It needs test, for sure! Oh! and you will be able to use the details element with the same name attribute soon enough to create exclusive accordeons :)
@@blokche_dev that's a great point and something I forgot to mention in the video is that usability testing is a huge part of building for a11y. Thanks for the suggestion!
Wow, thank you so much! I actually have a practical idea of how to implement it! Google’s video was nice but I couldn’t really follow along
Probably the best tabbed content with accessibility approach. Please more a11y content like this. Thanks for the detailed and well produced tutorial. Liked and subscribed.
Excellent tutorial and straight to the point. Short and practical at same time. The only thing I would improve here, the use of named grid lines rather than column numbers. This why you could define full width, content width and something in between if necessary or a breakout width.
Excellent explanation!
Thank you!! Your explanation is great!
I have a question with clamp, if it is a mim what you want and max why don't it have 2rem, 5rem, 7rem instead of 2rem, 4vw, 5rem that is confusing to me
Hi @AlThePal78, great question! I'm using viewport units (vw) to ensure that the font size scales with the viewport - 1vw is roughly 1% of the viewport width. If clamp is set to: clamp(1.5rem, 4vw, 3rem) - in a 400px wide viewport the preferred value evaluates to about 16px or 1rem. Since this is less than the minimum, the minimum will be used. If the viewport is 1440px wide, then the preferred value evaluates to about 58px. Since this is larger than the max, then the max value will be used. Units like rem and em are only relative to their parent element's font size (em) or the font size of the root-em (rem) and won't scale with the viewport. Hope that helps!
Your videos are the best! Super clear and helpful, thank you!
This helped me today 😁
Forgot to add the final result of the container query enhancement 🤣Find the final code here: codepen.io/alliemack/pen/ExqxEgw
Great video! but i think in container query section you forgot to show the final result of the applied style.
Hi @fastechx! Glad you liked the video and thanks for letting me know! Check the pinned comment above, I've added a link to Codepen with the final code!☝
I just watched most of your videos, great work, great structure in your video's. And yes please, i love this deep dive with accessibility and such, don't shy away from it.
Awesome! Good to know that more videos on accessibility would be helpful. Glad you found this useful and thanks for watching!
Not finished the video yet, but I'm 100% sure it's waaay better than google's docs on the topic, so thanks! Just some feedback if it helps - an intro might help your videos feel a bit less... I can't put my finger on it - AI like? Formal? Like the start of an ad? Perhaps it's an issue of it being *too* clean and well presented. I dunno, but it took me to the coding part to think 'oh, this might be her real voice/it's not an AI voiceover'. Don't take it the wrong way, looking forward to the rest of the video!
Finished it. MUCH better than Google's docs, thanks!
Thanks for the helpful feedback @nickwoodward819 and so glad you found it useful! I do write my own scripts and record myself reading from them, so I agree it can sound a bit formal sometimes. It's something I'm working on improving. Thanks for watching!
@@CSSdeCoder It was really only the intro that I felt it, the rest was perfect!
very good !
Once this transition is more widely supported, GSAP is gonna take a heavy hit
I wish the screen was zoomed in a bit more; it's difficult to see the code you're typing.
Hi @WPCookie! Thanks for the feedback, I'll keep that in mind for the next video. In case you missed it, here is the link to the code on GitHub: github.com/Alliemack77/view-transitions-photo-gallery
Thanks for sharing this!!
Your teaching style is truly engaging and insightful! I love how you break down complex topics into easy-to-understand concepts.
If you could create more projects that explain JavaScript concepts in detail, that would be fantastic!
Hey @hakiinep ! So glad these videos are helpful! Breaking down these new features also helps me understand what's going on under the hood. Let me know what concepts you'd be interested in seeing. Thanks for watching!
I don't know what's more impressive your video quality or your clear understanding of the tools that you're using. Excellent video.
Thank you so much!! Happy that you found this useful!
I've been soo excited about this API since I first tried it last fall. Now it can work cross-pages too! When will we get production level support 😭 Firefox I'm looking at you!
@@clevermissfox I agree! This API is so much fun to experiment with, I'm only scratching the surface here. It will be great once it's fully supported, but at least we can provide a fallback for Firefox. Thanks for watching!
loved the videos ありがとう!
You have earned a subscriber. 👍🏻
Awesome, thanks! Glad you found the video helpful!
not only CSS but this is really nice!
Exactly, the title is a bit misleading here. Although, with a bit of tweaking to have two states, you could use a checkbox with checked and unchecked status to achieve the same effect without JS.
Such a high quality video! You deserve more views on this :)
How do you only have 450 subs criminally underrated
Thanks for watching @opamaah! Hope you found the video useful!
Subscribed just because you're a doctor who fan
Thanks but little bit hard😄😄
This was great. A lot I didn't know and have to practice. Thank you ❤
You are great. I didn't plan watch this far at this moment because I have school work to catch up on but these are addictive. You make it look easy.
thanks 🙏
😅 very advance
Somehow, UA-cam recommended this to me and I'm happy it was worth it! This look awesome, and maybe there will be use cases where I may use this!! Thanks for the video :)
So glad you found this useful! CSS has so many great features, it's fun to play around with all the new ones like scroll timelines!
Top!
Thanks gitlhub url not exists :)
Hi @greekplayback! Thanks for catching that - the link should be working now. I forgot to switch the repo to public before publishing the video 🤦♀
which theme you are using ?
Hi @samsiddique4751! No themes, just HTML and pure CSS!
@@CSSdeCoder I think the VSC code theme is meant.
Thanks for sharing! This is what I am looking for. Please keep on going. :)
Glad you liked it! More to come...stay tuned!
This is really great. I love the animations in your video. It makes it really easy to follow along & understand what's going on. Definitely subscribing. Can't wait to see future videos.
Glad it was helpful!
Great video. Waiting for more! Love your website 😁
Working on it! Stay tuned! 😁
You said allons-y as if you spoke french that was cute
Haha, apologies if you are a native French speaker! I'd like to say "Yes, I do speak French" but that was my nerdy David Tennant, Doctor Who reference. Thanks for watching!
Muito bom. Obrigado
Glad you liked it. Thanks for watching!
Wow. Great and clear instruction. Quite a handy thing for regular CSS crafters.
Thanks so much! Grid is such a handy tool to have in your CSS toolbox.