Et veniam dolore ipsam. Repellendus doloremque pariatur et et et. Debitis blanditiis enim repellat voluptatem earum impedit.

Daily Cat Drawings: Artist Wants To Adopt A Cat So Bad, She Signs Up For A 100-Day Cat Meme Drawing Challenge

Drawing cats from memes every single day sounds like a dream come true. Well, animation student Emily Paquin aka Catwheezie is certainly living the life! She posts a drawing of a popular and beloved internet cat each day, and she doesn’t plan on stopping until she hits 100, and maybe even beyond! “Most of the cats I draw are from popular cat images I find online through Instagram.


Common WordPress Errors & How to Fix Them

Common WordPress Errors & How to Fix Them

WordPress is an amazingly stable platform thanks to the dedication and talent of the hundreds of professionals contributing to it, and the strict code standards they follow. Even so, the huge variety of themes, plugins and server environments out there make it difficult to guarantee nothing will ever go wrong. This guide will help you […]

 Image of img

The post Common WordPress Errors & How to Fix Them appeared first on Web Designer Wall.

How to Use ARIA Roles, Properties, and States in HTML

How to Use ARIA Roles, Properties, and States in HTML

In this beginner’s accessibility tutorial we’re going to learn what ARIA is, why it is necessary to write our HTML with ARIA in mind, what ARIA roles, properties, and states are, and (very importantly) the 5 rules of ARIA use.

What is ARIA?

ARIA stands for Accessible Rich Internet Applications and it was created by the World Wide Web Consortium (W3C). Nowadays, as a best practice, web developers use semantic HTML when building websites and web pages. Semantic HTML is where the most appropriate and descriptive HTML elements are used, helping robots, services, and those who rely on assistive technologies (AT) understand the meaning of the content.

 Image of aria

ARIA goes one step further, adding a set of attributes which help define the content of a page beyond what HTML can do on its own. These ARIA attributes add things like accessible navigation, form hints, error messages and other useful power ups.

Here’s an example of semantic HTML, done badly and then properly:

Bad Semantics

Here, we can see a body element that contains text nested using either div or span tags. Although this page can be styled to look perfectly good using CSS, it would be difficult for people that rely on screen readers to fully understand this content because it isn’t properly constructed.

Good Semantics

In this example we’ve made the same content more accessible by using the right HTML elements in the structure of the page.

  1. The header contains the introductory content.
  2. The p element serves as a logo.
  3. main indicates that the user is entering the main content of the page.
  4. An h1 element indicates the title of the content.
  5. Another p tag indicates a paragraph.
  6. A footer indicates that the user has reached the end of the page; it contains things like copyright information and extra links.

With semantic HTML it’s easier for users that rely on screen readers to understand the content of the page; screen readers can interpret well-used semantic HTML elements.

Another common example that involves the use of bad semantics involves the use of divs as buttons in HTML, styling them to look like an actual button with CSS.

What Are ARIA Roles?

Native semantic HTML should always be used where possible, but ARIA roles can be used to fill in any gaps. ARIA roles are applied to HTML elements using the role attribute, and can be used:. 

  • to describe newer or conceptual elements that might not have full browser support or be understood by screen readers, for example <button role="tab">Tab</button>.
  • to “fix” (as best as possible) incorrectly implemented HTML where semantics haven’t been used, for example <div role="button">Button</div>.

With these examples non-visual users, with the help of screen readers, will be able to identify the elements as we intend.

Classification of ARIA Roles

ARIA roles can be classified into 4 types;

  1. Abstract Roles: According to W3C official documentation, these are roles used by the browser. They are the foundation upon which all other WAI-ARIA roles are built. Content authors must not use abstract roles because they are not implemented in the API binding. Examples of abstract roles include widget, landmark, window, command, etc.
  2. Widget Roles: Widget roles are used to define a UI element when semantic HTML is not being used. According to W3C, some widget roles serve as standalone user interfaces or act as part of a larger composite widget. Examples of widget roles include alertdialogcheckbox, marquee, etc. Other widget roles serve as containers that manage other contained widgets. Examples of these widgets are tree, tablist, menumenubar, etc.
  3. Document Structure: These are roles that describe structures that organize content on a page and they are not usually interactive. Roles like these help assistive technologies identify and classify the different sections of a page. Examples are article, toolbar, row, list, etc.
  4. Landmark Roles: Landmark roles that identify large content areas. This help assistive technologies define these sections to users that rely on them. Examples of landmark roles are applicationform, main, etc.
 Image of rsz bytxecv2
a list of aria roles, image from Google’s Introduction to ARIA

Taking roles even further, we can also add ARIA states and properties to elements.

What Are ARIA States and Properties?

ARIA states and properties provide support for ARIA roles that exist on a page. When combined with roles, they can supply assistive technologies with extra user interface information. Whenever there are changes in states or properties, assistive technologies are notified of this change so they can alert the user that a change has occurred.

ARIA properties are different from states in that the value of a property (such as aria-labelledby) is often less likely to change throughout the application life-cycle, while a state (for example aria-checked) is likely to change quite often due to user interaction. ARIA properties and states can be classified as:

  1. Widget Attributes
  2. Live Region Attributes
  3. Drag-and-Drop Attributes
  4. Relationship Attributes

Widget Attributes

These types of attributes are used for common user interface elements which receive user input and process user actions. They are also used to support widget roles. Examples include aria-readonlyaria-required, aria-checked.

Live Region Attributes

These attributes are used to indicate to a user that a specific content might change or update (or simply put, live regions). They are applied directly on the element that changes so assistive technologies can notify users of the change in such document/page. For instance, it would be important to make use of aria-live on an element that displays live data from an endpoint like the Stock exchange. Examples of attributes like this are aria-livearia-atomicaria-busy, and aria-relevant.

Drag-and-Drop Attributes

They are used for elements that are either draggable or are drop targets. Forms that require upload of any form of file (image, pdf document, etc.) often make use of drag-and-drop as a means of uploading such file. It is important that users that rely on assistive technologies are not left out, and this type of attribute can help with that. Examples are aria-dropeffect for elements that receive drop event and aria-draggable for elements that are draggable.

Relationship Attributes

These types of attributes help connect two elements that are difficult to otherwise identify using the HTML document’s structure. An example of this type of attribute is the aria-labelledby attribute. This attributes helps connect an input field to a label in a form (but can be used for less obvious relationships):

Other examples of relationship attributes are aria-colspan, aria-controls, aria-owns, aria-flowto, etc.

5 Rules of ARIA Use

When using ARIA, there are some dos and don’ts that must be followed in order to ensure that your site or the project you’re working on is accessible to users that rely on screen readers and other assistive technologies. These are known as the Rules of ARIA Use and they are five in number:

ARIA Rule #1

The first rule of ARIA use goes as follows;

If you can use a native HTML element or attribute with the semantics and behaviour you require already built in, instead of re-purposing an element and adding an ARIA role, state or property to make it accessible, then do so..

This means it’s best to use semantic HTML where it is available as much as possible and not resort to using elements like div in place of button element and adding ARIA roles, states, or properties to make such elements accessible. There are some instances in which this might not be possible and they include:

  1. The feature is currently not available in HTML
  2. If the visual design constraints rule out the use of a particular native element because the element cannot be styled as required.
  3. When the native HTML element does not have accessibility support.

ARIA Rule #2

The second rule of ARIA use warns against the changing of native HTML semantics with ARIA roles, states, or properties. For example;

Do not do this

Do this

ARIA Rule #3

The third rule of ARIA use states that all interactive ARIA controls must be accessible via the keyboard. This means that whatever action (drag, drop, click, etc) elements on a page requires to perform an action, users must also be able to perform the equivalent using just the keyboard. 

An example of this would be submitting a form using a button. A user must be able to submit the form by clicking on the enter or return button, which must also be capable of receiving focus.

ARIA Rule #4

The fourth rule of ARIA use warns against the use of the role attribute with presentation and aria-hidden='true' on elements that are visible and focusable to the user. Doing either of these would result in the user focusing on nothing in the end. Only use aria-hidden='true' on elements that aren’t visible or cannot be interacted with (but are interactive).

ARIA Rule #5

The fifth and final rule of ARIA use states that all interactive elements must have accessible names, i.e the name of a user interface element. Take this example:

This is wrong because assistive technologies would not be able to connect the label value to the input field and its users would also struggle to understand that the field is meant for their email address. Instead, do either of the following;


You Now Understand ARIA!

This introduction has given you a basic knowledge of ARIA. Next time you’re writing HTML or JavaScript think about whether ARIA would improve what you’ve built and help those with accessibility impairments. And Don’t forget the 5 rules of using ARIA roles, properties, and states!

More Accessibility Tutorials

Accessibility is an oft-overlooked but essential part of web development. Sami Keijonen’s article about its importance will motivate you to think about web accessibility more:

Learn more about accessibility right here at Tuts+:

 Image of mf Image of a2 Image of a2t

Marcela Laiferová singles (Opus Records, 1974–1979)

Marcela Laiferová singles (Opus Records, 1974–1979)

Contributed by Jorge Iván Moreno Majul
 Image of Marcela Laiferova%CC%81

Source: License: All Rights Reserved.
 Image of joc line
 Image of futura
 Image of unidentified typeface

Joc Line in use for a series of singles by Slovak pop singer Marcela Laiferová, released in 1974, 1977, and 1979 on Opus Records. The three records use the same front and back cover.

The typeface was designed by Gabriel Fumanal Martinez, a designer from Barcelona, at the age of 20. It 1973, it was selected as winner in Letraset’s International Typeface Competition. It was released in their Letragraphica range and is shown in the 18 New Type Faces catalog.

The geometrically constructed unicase letterforms were partly filled with color; once in red and yellow, and once in blue and green. On the back cover, there’s an acute accent inside the letter á. On the front side, however, the uncredited designer used a period to mark this diacritic in the singer’s name.

Price and catalog number are set in Futura. The bold compressed sans used in all caps for the song titles is the same typeface that was used by Supraphon in 1980 and 1982. It hasn’t been identified yet.

[More info on Discogs]

 Image of R 14709261 1580069678 2417 jpeg%20%281%29

Source: License: All Rights Reserved.

“Hymna Lúčnych Rán” / “Káva Zrnková”, 1974.

 Image of R 9956174 1549695509 8844 jpeg

Source: License: All Rights Reserved.

“Spi, Môj Synček” / “Harlekýna Zdobí Svet”, 1977.

 Image of R 7556929 1450689177 2093 jpeg

Source: License: All Rights Reserved.

“Hrdá Láska” / “Kvapka Medu”, 1979.

 Image of UzCwMEebVqU