[whatwg] Footnotes, endnotes, sidenotes

Michel Fortin wrote:
> Le 6 nov. 2006 ? 7:04, Matthew Raymond a ?crit :
> 
>> Michel Fortin wrote:
>>
>>>      <p>This paragraph has a footnote<fnref for="my-footnote"
>>>> <sup><a href="#my-footnote">1</a></sup></fnref>.</p>
>>>      <fnl>
>>>      <fn id="my-footnote">
>>>        <p>This footnote can contain block-level elements!</p>
>>>      </fn>
>>>      </fnl>
>>    I have a similar view, although I have some refinements:
>>
>> | <p annotation="my-footnote">
>> |   This paragraph has a footnote
>> |   <a rel="annotation" href="#my-footnote"><sup>[1]</sup></a>.
>> | </p>
>> | [...]
>> | <footnote>
>> |   <p>References:</p>
>> |   <al>
>> |     <ol>
>> |       <li id="my-footnote">
>> |         <p>This footnote can contain block-level elements!</p>
>> |       </li>
>> |     </ol>
>> |   </al>
>> | </footnote>
> 
> I think having an annotation attribute in the paragraph is redundant  
> with the <a rel="annotation"> element. What happens if the attribute  
> is there and there is no link?

   Then there's no fallback for legacy user agents. Is your argument
that fallback should be structured in such a way that it must be
included? (Not that that isn't a valid argument...)

> What if the link is there with no
> annotation attribute?

   While you could imply that the <a rel="annotation"> element applies
to the immediate parent, there is not explicit markup that indicates the
scope of the annotation, and readability is negatively impacted because
the scope could start well before the <a> element occurs in the markup.
Also, because <a> dictates the position of the annotation link, you're
essentially dictating part of the styling. What if the user wants to
move the annotation link to the beginning of the annotated text rather
than the end? Or vice versa? While CSS3 may have some solutions, it's
not something for beginners.

> I think the attribute is completely unnecessary.

   I disagree. Just |rel="annotation"| could just be a microformat to
anyone reading it, and it doesn't clearly establish the scope of the
annotation.

> Also, you're mixing two different terms (footnote and annotations), I  
> don't think that's a so good idea.

   I'm not married to the whole <footnote> idea. That was just there to
give a structured higher-level container to the annotation list (<al>).

> And you're forcing your  
> annotations to be part of a list, which makes difficult to put them  
> in the middle of the text to style them as sidenotes.

   We could have annotation elements with optional annotation list parents:

| <anno>Annotation</anno>
|
| <al>
|   <anno>Annotation 1</anno>
|   <anno>Annotation 2</anno>
|   <anno>Annotation 3</anno>
| <al>
|
| <anno>Annotation</anno>
| <anno>Annotation</anno>

   Or perhaps just drop the <al>, but I like the idea of that list type
for numbering and reordering purposes. The user agent could reorder the
items to the order they're linked to.

Received on Tuesday, 7 November 2006 04:11:56 UTC