Build a simple webpage using at least 5 different semantic HTML5 elements. Include a header, navigation, main content area with articles, and a footer.
Pro Tip: Always use the most specific semantic element available. This improves accessibility and helps search engines understand your content.
Lesson 2: Advanced CSS Layouts
Advanced CSS
Learning Objectives
Master CSS Flexbox for 1D layouts
Implement CSS Grid for 2D layouts
Create responsive designs with media queries
Use modern layout techniques effectively
CSS Flexbox is designed for one-dimensional layouts, while CSS Grid excels at two-dimensional layouts.
Flexbox Fundamentals
Flexbox makes it easy to design flexible responsive layout structures.
Create a webpage that uses Flexbox for a navigation bar and CSS Grid for the main content area. Make it responsive with media queries for mobile, tablet, and desktop views.
Pro Tip: Start with mobile styles first, then use min-width media queries to progressively enhance the layout for larger screens (mobile-first approach).
Lesson 3: Advanced CSS Effects
Advanced CSS 2
Learning Objectives
Create smooth CSS animations and transitions
Apply 2D and 3D transforms to elements
Use advanced visual effects like gradients and shadows
Implement modern CSS features like custom properties
CSS Transforms and Animations can create engaging user experiences without JavaScript.
CSS Transitions and Animations
Transitions allow property changes to occur smoothly over time, while animations provide more control over intermediate steps.
Build a card component that uses CSS transitions for hover effects and a simple animation when the page loads. Use CSS custom properties to make the design easily customizable.
Lesson 4: Web Accessibility Fundamentals
Web Accessibility
Learning Objectives
Understand the importance of web accessibility
Learn WCAG guidelines and principles
Implement proper semantic structure for screen readers
Create keyboard-navigable interfaces
Web Accessibility ensures that people with disabilities can perceive, understand, navigate, and interact with the web.
WCAG Principles (POUR)
The Web Content Accessibility Guidelines are built on four principles:
Perceivable
Information and UI components must be presentable to users in ways they can perceive.
Text alternatives for non-text content
Captions and other alternatives for multimedia
Content that can be presented in different ways
Easy-to-see and -hear content
Operable
UI components and navigation must be operable by all users.
Keyboard accessibility
Enough time to read and use content
Content that does not cause seizures
Easy navigation
Understandable
Information and operation of UI must be understandable.
Readable and predictable text
Input assistance for forms
Consistent navigation
Robust
Content must be robust enough to work with current and future user tools.
Compatible with assistive technologies
Valid and well-structured HTML
Accessible HTML Practices
Proper HTML structure is the foundation of accessibility:
<!-- Use semantic elements --> <navaria-label="Main navigation"> <ul> <li><ahref="#">Home</a></li> <li><ahref="#">About</a></li> </ul> </nav>
<!-- Provide text alternatives --> <imgsrc="chart.jpg"alt="Bar chart showing sales growth from 2018 to 2022">
<!-- Use proper form labels --> <labelfor="username">Username:</label> <inputtype="text"id="username"name="username">
Hands-On Activity
Audit and Improve Accessibility
Take an existing webpage (or create a simple one) and identify at least 5 accessibility issues. Then fix those issues using proper semantic HTML, ARIA attributes, and accessibility best practices.
Lesson 5: Accessibility Implementation
Web Accessibility
Learning Objectives
Use ARIA attributes to enhance accessibility
Implement keyboard navigation and focus management
Test websites for accessibility compliance
Apply accessibility techniques to complex components
ARIA (Accessible Rich Internet Applications) provides attributes to make web content more accessible when native HTML isn't sufficient.
ARIA Attributes and Roles
ARIA helps communicate information about elements to assistive technologies:
<!-- ARIA states and properties --> <buttonaria-expanded="false"aria-controls="dropdown1">
Menu </button> <ulid="dropdown1"aria-hidden="true"> <li><ahref="#">Item 1</a></li> <li><ahref="#">Item 2</a></li> </ul>
<!-- ARIA live regions --> <divaria-live="polite"aria-atomic="true"> <!-- Dynamic content will be announced --> </div>
Keyboard Accessibility
Ensure all interactive elements can be operated with a keyboard:
Several tools can help you test and improve accessibility:
Automated tools: axe, WAVE, Lighthouse
Screen readers: NVDA (Windows), VoiceOver (Mac)
Manual testing: Keyboard navigation, color contrast checkers
Hands-On Activity
Build an Accessible Component
Create an accessible modal dialog or tab component that includes proper ARIA attributes, keyboard navigation, and focus management. Test it with a screen reader and keyboard-only navigation.
Pro Tip: Remember the first rule of ARIA - don't use ARIA if you can use native HTML elements with the required semantics and behavior.