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

Clarification to description list #386

Open
scottaohara opened this issue Aug 5, 2022 · 4 comments
Open

Clarification to description list #386

scottaohara opened this issue Aug 5, 2022 · 4 comments

Comments

@scottaohara
Copy link

the valid dl elements point of failure states:

Any <dl> elements must only contain <dt> and <dd> elements.

But, <div> elements are also allowed so long as they contain <dt> and <dd> elements.

@MelSumner
Copy link
Owner

@scottaohara hmm I thought you had to put the div inside of the dt or dd?

At any rate, thanks for bringing this up!

@scottaohara
Copy link
Author

scottaohara commented Aug 8, 2022

@MelSumner dl element per the HTML spec

example from the dl element definition:

The following example illustrates the use of the dl element to mark up metadata of sorts. At the end of the example, one group has two metadata labels ("Authors" and "Editors") and two values ("Robert Rothman" and "Daniel Jackson"). This example also uses the div element around the groups of dt and dd element, to aid with styling.

<dl>
 <div>
  <dt> Last modified time </dt>
  <dd> 2004-12-23T23:33Z </dd>
 </div>
 <div>
  <dt> Recommended update interval </dt>
  <dd> 60s </dd>
 </div>
 <div>
  <dt> Authors </dt>
  <dt> Editors </dt>
  <dd> Robert Rothman </dd>
  <dd> Daniel Jackson </dd>
 </div>
</dl>

@MelSumner
Copy link
Owner

MelSumner commented Aug 10, 2022

ok, good to know; I think some checkers flag this (and I've definitely asked for changes on PRs if this was the markup).

I did think that ARIA was supposed to take precedence if there was something different in the HTML spec though? WDYT?

@scottaohara
Copy link
Author

I don’t understand the question? There’s nothing in aria about description lists yet.

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