public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
* Validating Pandoc generated HTML 5
@ 2023-11-15 15:18 Nandakumar Chandrasekhar
       [not found] ` <f5859ff8-3e37-4794-9c85-ef6456cd73c1n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Nandakumar Chandrasekhar @ 2023-11-15 15:18 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 1747 bytes --]

Dear Folks,

I have the following question in regard to the HTML 5 generated by Pandoc.

Is Pandoc generating HTML 5 using the XHTML standard?

When validating the generated HTML through the W3C validator I see the 
following information notices about void elements:

Trailing slash on void elements has no effect 
<https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-in-void-element-start-tags-do-not-mark-the-start-tags-as-self-closing>
 and interacts badly with unquoted attribute values 
<https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-directly-preceded-by-unquoted-attribute-values>
.

Since this is just informational I am not too worried about the trailing 
slash being placed at the end of elements although it does not seem to be 
part of the HTML 5 standard.

However, when I am faced with an error like below I would like to fix it:

Error: Bad value doc-endnotes for attribute role on element aside 
<https://html.spec.whatwg.org/multipage/#the-aside-element>.
</figure>↩<aside id="footnotes" class="footnotes footnotes-end-of-document"↩
role="doc-endnotes">↩<hr />

I would like to know the community's verdict on this and how I may remove 
these messages while validating if at all possible. Many thanks

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com.

[-- Attachment #1.2: Type: text/html, Size: 4901 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Validating Pandoc generated HTML 5
       [not found] ` <f5859ff8-3e37-4794-9c85-ef6456cd73c1n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2023-11-15 17:21   ` John MacFarlane
  2023-11-15 17:45   ` Nandakumar Chandrasekhar
  1 sibling, 0 replies; 7+ messages in thread
From: John MacFarlane @ 2023-11-15 17:21 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

Yes, we try to generate polyglot HTML.

Part of the reason for this is that we use the HTML writer in the EPUB writer, and it needs XHTML.


> Error: Bad value doc-endnotes for attribute role on element aside.
> </figure>↩<aside id="footnotes" class="footnotes footnotes-end-of-document"↩role="doc-endnotes">↩<hr />

Not sure why this should be an error?

I see on https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside
that doc-endnotes is not listed in "permitted aria roles." But then, it is also
not listed in "permitted aria roles" for the section element, contradicting

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside

I'd be grateful for input for people who know more about aria-roles.

What validator are you using?

> On Nov 15, 2023, at 7:18 AM, Nandakumar Chandrasekhar <navanitachora@gmail.com> wrote:
> 
> Dear Folks,
> 
> I have the following question in regard to the HTML 5 generated by Pandoc.
> 
> Is Pandoc generating HTML 5 using the XHTML standard?
> 
> When validating the generated HTML through the W3C validator I see the following information notices about void elements:
> 
> Trailing slash on void elements has no effect and interacts badly with unquoted attribute values.
> 
> Since this is just informational I am not too worried about the trailing slash being placed at the end of elements although it does not seem to be part of the HTML 5 standard.
> 
> However, when I am faced with an error like below I would like to fix it:
> 
> Error: Bad value doc-endnotes for attribute role on element aside.
> </figure>↩<aside id="footnotes" class="footnotes footnotes-end-of-document"↩role="doc-endnotes">↩<hr />
> 
> I would like to know the community's verdict on this and how I may remove these messages while validating if at all possible. Many thanks
> 
> -- 
> You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com.

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/155DA277-EC6D-4AF6-AB17-F993B783187D%40gmail.com.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Validating Pandoc generated HTML 5
       [not found] ` <f5859ff8-3e37-4794-9c85-ef6456cd73c1n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  2023-11-15 17:21   ` John MacFarlane
@ 2023-11-15 17:45   ` Nandakumar Chandrasekhar
       [not found]     ` <CAMhuDe8L9CLLXQVU=c3ZfmpyLe+k4h2E9zjNAk8MGHwXT84N2Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  1 sibling, 1 reply; 7+ messages in thread
From: Nandakumar Chandrasekhar @ 2023-11-15 17:45 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

[-- Attachment #1: Type: text/plain, Size: 2924 bytes --]

Thank you for your reply.

I am using the validator put out by the W3C avaliable at:
https://validator.w3.org/

I will experiment with XHTML and figure out the syntactic differences and
see what happens.

I do not know much about aria roles so will have read up on those.

Many thanks.

On Wed, 15 Nov, 2023, 20:48 Nandakumar Chandrasekhar, <
navanitachora-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:

> Dear Folks,
>
> I have the following question in regard to the HTML 5 generated by Pandoc.
>
> Is Pandoc generating HTML 5 using the XHTML standard?
>
> When validating the generated HTML through the W3C validator I see the
> following information notices about void elements:
>
> Trailing slash on void elements has no effect
> <https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-in-void-element-start-tags-do-not-mark-the-start-tags-as-self-closing>
>  and interacts badly with unquoted attribute values
> <https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-directly-preceded-by-unquoted-attribute-values>
> .
>
> Since this is just informational I am not too worried about the trailing
> slash being placed at the end of elements although it does not seem to be
> part of the HTML 5 standard.
>
> However, when I am faced with an error like below I would like to fix it:
>
> Error: Bad value doc-endnotes for attribute role on element aside
> <https://html.spec.whatwg.org/multipage/#the-aside-element>.
> </figure>↩<aside id="footnotes" class="footnotes
> footnotes-end-of-document"↩role="doc-endnotes">↩<hr />
>
> I would like to know the community's verdict on this and how I may remove
> these messages while validating if at all possible. Many thanks
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "pandoc-discuss" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/pandoc-discuss/E7Y0798bvp0/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com
> <https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/CAMhuDe8L9CLLXQVU%3Dc3ZfmpyLe%2Bk4h2E9zjNAk8MGHwXT84N2Q%40mail.gmail.com.

[-- Attachment #2: Type: text/html, Size: 6297 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Validating Pandoc generated HTML 5
       [not found]     ` <CAMhuDe8L9CLLXQVU=c3ZfmpyLe+k4h2E9zjNAk8MGHwXT84N2Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2023-11-16  2:42       ` Nandakumar Chandrasekhar
       [not found]         ` <07c5c0cd-f115-476c-bd17-c1c31470602an-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Nandakumar Chandrasekhar @ 2023-11-16  2:42 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 3513 bytes --]

@jgm I think a possible fix for the ARIA role would be to set it to:

*role="doc-footnote"*

instead of:

*role="doc-endnotes" *
I found this 
at: https://kb.daisy.org/publishing/docs/html/dpub-aria/doc-footnote.html 
which fixes the validation error.

Of course, I have only verified this with my limited use case i.e. 
footnotes, and I am not sure what the far-reaching consequences of making 
this change would be.

Cheers

On Wednesday, November 15, 2023 at 11:15:59 PM UTC+5:30 Nandakumar 
Chandrasekhar wrote:

> Thank you for your reply.
>
> I am using the validator put out by the W3C avaliable at: 
> https://validator.w3.org/
>
> I will experiment with XHTML and figure out the syntactic differences and 
> see what happens.
>
> I do not know much about aria roles so will have read up on those.
>
> Many thanks.
>
> On Wed, 15 Nov, 2023, 20:48 Nandakumar Chandrasekhar, <navani...-Re5JQEeQqe8@public.gmane.orgm> 
> wrote:
>
>> Dear Folks,
>>
>> I have the following question in regard to the HTML 5 generated by Pandoc.
>>
>> Is Pandoc generating HTML 5 using the XHTML standard?
>>
>> When validating the generated HTML through the W3C validator I see the 
>> following information notices about void elements:
>>
>> Trailing slash on void elements has no effect 
>> <https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-in-void-element-start-tags-do-not-mark-the-start-tags-as-self-closing>
>>  and interacts badly with unquoted attribute values 
>> <https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-directly-preceded-by-unquoted-attribute-values>
>> .
>>
>> Since this is just informational I am not too worried about the trailing 
>> slash being placed at the end of elements although it does not seem to be 
>> part of the HTML 5 standard.
>>
>> However, when I am faced with an error like below I would like to fix it:
>>
>> Error: Bad value doc-endnotes for attribute role on element aside 
>> <https://html.spec.whatwg.org/multipage/#the-aside-element>.
>> </figure>↩<aside id="footnotes" class="footnotes 
>> footnotes-end-of-document"↩role="doc-endnotes">↩<hr />
>>
>> I would like to know the community's verdict on this and how I may remove 
>> these messages while validating if at all possible. Many thanks
>>
>> -- 
>> You received this message because you are subscribed to a topic in the 
>> Google Groups "pandoc-discuss" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/pandoc-discuss/E7Y0798bvp0/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to 
>> pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>
>
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com 
>> <https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/07c5c0cd-f115-476c-bd17-c1c31470602an%40googlegroups.com.

[-- Attachment #1.2: Type: text/html, Size: 9749 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Validating Pandoc generated HTML 5
       [not found]         ` <07c5c0cd-f115-476c-bd17-c1c31470602an-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2023-11-17 15:33           ` Nandakumar Chandrasekhar
       [not found]             ` <08116215-7638-4f79-9261-2574aa1422e7n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: Nandakumar Chandrasekhar @ 2023-11-17 15:33 UTC (permalink / raw)
  To: pandoc-discuss


[-- Attachment #1.1: Type: text/plain, Size: 4488 bytes --]

@jgm After doing more research into the value of the role attribute being 
doc-footnote or doc-endnotes, it looks like it all depends on whether we 
are using an <aside> tag or a <section> tag as mentioned here 
<https://kb.daisy.org/publishing/docs/html/notes.html#:~:text=Note%20that%20the%20doc-footnote,to%20group%20notes%20into%20lists.&text=Note%20that%20the%20doc-endnotes,the%20section%20containing%20the%20endnotes.>
.

In Pandoc HTML generation the footnote section is defined as an <aside> and 
should probably use role="doc-footnote" which would fix the HTML5 
validation error.

Should I contribute a pull request for this?

I am not sure if this change will cause issues in the EPUB writer, however.

I would like to know your thoughts.

On Thursday, November 16, 2023 at 8:12:06 AM UTC+5:30 Nandakumar 
Chandrasekhar wrote:

> @jgm I think a possible fix for the ARIA role would be to set it to:
>
> *role="doc-footnote"*
>
> instead of:
>
> *role="doc-endnotes" *
> I found this at: 
> https://kb.daisy.org/publishing/docs/html/dpub-aria/doc-footnote.html 
> which fixes the validation error.
>
> Of course, I have only verified this with my limited use case i.e. 
> footnotes, and I am not sure what the far-reaching consequences of making 
> this change would be.
>
> Cheers
>
> On Wednesday, November 15, 2023 at 11:15:59 PM UTC+5:30 Nandakumar 
> Chandrasekhar wrote:
>
>> Thank you for your reply.
>>
>> I am using the validator put out by the W3C avaliable at: 
>> https://validator.w3.org/
>>
>> I will experiment with XHTML and figure out the syntactic differences and 
>> see what happens.
>>
>> I do not know much about aria roles so will have read up on those.
>>
>> Many thanks.
>>
>> On Wed, 15 Nov, 2023, 20:48 Nandakumar Chandrasekhar, <
>> navani...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
>>
>>> Dear Folks,
>>>
>>> I have the following question in regard to the HTML 5 generated by 
>>> Pandoc.
>>>
>>> Is Pandoc generating HTML 5 using the XHTML standard?
>>>
>>> When validating the generated HTML through the W3C validator I see the 
>>> following information notices about void elements:
>>>
>>> Trailing slash on void elements has no effect 
>>> <https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-in-void-element-start-tags-do-not-mark-the-start-tags-as-self-closing>
>>>  and interacts badly with unquoted attribute values 
>>> <https://github.com/validator/validator/wiki/Markup-%C2%BB-Void-elements#trailing-slashes-directly-preceded-by-unquoted-attribute-values>
>>> .
>>>
>>> Since this is just informational I am not too worried about the trailing 
>>> slash being placed at the end of elements although it does not seem to be 
>>> part of the HTML 5 standard.
>>>
>>> However, when I am faced with an error like below I would like to fix it:
>>>
>>> Error: Bad value doc-endnotes for attribute role on element aside 
>>> <https://html.spec.whatwg.org/multipage/#the-aside-element>.
>>> </figure>↩<aside id="footnotes" class="footnotes 
>>> footnotes-end-of-document"↩role="doc-endnotes">↩<hr />
>>>
>>> I would like to know the community's verdict on this and how I may 
>>> remove these messages while validating if at all possible. Many thanks
>>>
>>> -- 
>>> You received this message because you are subscribed to a topic in the 
>>> Google Groups "pandoc-discuss" group.
>>> To unsubscribe from this topic, visit 
>>> https://groups.google.com/d/topic/pandoc-discuss/E7Y0798bvp0/unsubscribe
>>> .
>>> To unsubscribe from this group and all its topics, send an email to 
>>> pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>>
>>
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com 
>>> <https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>>
>>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/08116215-7638-4f79-9261-2574aa1422e7n%40googlegroups.com.

[-- Attachment #1.2: Type: text/html, Size: 11206 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Validating Pandoc generated HTML 5
       [not found]             ` <08116215-7638-4f79-9261-2574aa1422e7n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
@ 2023-12-04 16:56               ` John MacFarlane
       [not found]                 ` <1EF73A39-A2CD-49D0-9F14-3EDDB1E85A23-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
  0 siblings, 1 reply; 7+ messages in thread
From: John MacFarlane @ 2023-12-04 16:56 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

Thanks. I'll make the change (it's very simple).  It won't affect EPUB.
It feels wrong either way, actually: this aside may contain multiple notes, so 'footnote' (singular) doesn't seem right.
But it's not at the end, so 'endnotes' isn't right either.
At least this way the validator won't complain.

> On Nov 17, 2023, at 7:33 AM, Nandakumar Chandrasekhar <navanitachora@gmail.com> wrote:
> 
> @jgm After doing more research into the value of the role attribute being doc-footnote or doc-endnotes, it looks like it all depends on whether we are using an <aside> tag or a <section> tag as mentioned here.
> 
> In Pandoc HTML generation the footnote section is defined as an <aside> and should probably use role="doc-footnote" which would fix the HTML5 validation error.
> 
> Should I contribute a pull request for this?
> 
> I am not sure if this change will cause issues in the EPUB writer, however.
> 
> I would like to know your thoughts.
> 
> On Thursday, November 16, 2023 at 8:12:06 AM UTC+5:30 Nandakumar Chandrasekhar wrote:
> @jgm I think a possible fix for the ARIA role would be to set it to:
> 
> role="doc-footnote"
> 
> instead of:
> 
> role="doc-endnotes" 
> I found this at: https://kb.daisy.org/publishing/docs/html/dpub-aria/doc-footnote.html which fixes the validation error.
> 
> Of course, I have only verified this with my limited use case i.e. footnotes, and I am not sure what the far-reaching consequences of making this change would be.
> 
> Cheers
> 
> On Wednesday, November 15, 2023 at 11:15:59 PM UTC+5:30 Nandakumar Chandrasekhar wrote:
> Thank you for your reply.
> 
> I am using the validator put out by the W3C avaliable at: https://validator.w3.org/
> 
> I will experiment with XHTML and figure out the syntactic differences and see what happens.
> 
> I do not know much about aria roles so will have read up on those.
> 
> Many thanks.
> 
> On Wed, 15 Nov, 2023, 20:48 Nandakumar Chandrasekhar, <navani...-Re5JQEeQqe8@public.gmane.orgm> wrote:
> Dear Folks,
> 
> I have the following question in regard to the HTML 5 generated by Pandoc.
> 
> Is Pandoc generating HTML 5 using the XHTML standard?
> 
> When validating the generated HTML through the W3C validator I see the following information notices about void elements:
> 
> Trailing slash on void elements has no effect and interacts badly with unquoted attribute values.
> 
> Since this is just informational I am not too worried about the trailing slash being placed at the end of elements although it does not seem to be part of the HTML 5 standard.
> 
> However, when I am faced with an error like below I would like to fix it:
> 
> Error: Bad value doc-endnotes for attribute role on element aside.
> </figure>↩<aside id="footnotes" class="footnotes footnotes-end-of-document"↩role="doc-endnotes">↩<hr />
> 
> I would like to know the community's verdict on this and how I may remove these messages while validating if at all possible. Many thanks
> 
> -- 
> You received this message because you are subscribed to a topic in the Google Groups "pandoc-discuss" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/topic/pandoc-discuss/E7Y0798bvp0/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> 
> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com.
> 
> -- 
> You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/08116215-7638-4f79-9261-2574aa1422e7n%40googlegroups.com.

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/1EF73A39-A2CD-49D0-9F14-3EDDB1E85A23%40gmail.com.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: Validating Pandoc generated HTML 5
       [not found]                 ` <1EF73A39-A2CD-49D0-9F14-3EDDB1E85A23-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
@ 2023-12-04 17:09                   ` John MacFarlane
  0 siblings, 0 replies; 7+ messages in thread
From: John MacFarlane @ 2023-12-04 17:09 UTC (permalink / raw)
  To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw

I'm also going to change the behavior for HTML5 when footnotes are at the end.
Instead of an aside element, we'll use a section, and then it can have the appropriate
role, endnotes.

> On Dec 4, 2023, at 8:56 AM, John MacFarlane <fiddlosopher-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:
> 
> Thanks. I'll make the change (it's very simple).  It won't affect EPUB.
> It feels wrong either way, actually: this aside may contain multiple notes, so 'footnote' (singular) doesn't seem right.
> But it's not at the end, so 'endnotes' isn't right either.
> At least this way the validator won't complain.
> 
>> On Nov 17, 2023, at 7:33 AM, Nandakumar Chandrasekhar <navanitachora@gmail.com> wrote:
>> 
>> @jgm After doing more research into the value of the role attribute being doc-footnote or doc-endnotes, it looks like it all depends on whether we are using an <aside> tag or a <section> tag as mentioned here.
>> 
>> In Pandoc HTML generation the footnote section is defined as an <aside> and should probably use role="doc-footnote" which would fix the HTML5 validation error.
>> 
>> Should I contribute a pull request for this?
>> 
>> I am not sure if this change will cause issues in the EPUB writer, however.
>> 
>> I would like to know your thoughts.
>> 
>> On Thursday, November 16, 2023 at 8:12:06 AM UTC+5:30 Nandakumar Chandrasekhar wrote:
>> @jgm I think a possible fix for the ARIA role would be to set it to:
>> 
>> role="doc-footnote"
>> 
>> instead of:
>> 
>> role="doc-endnotes" 
>> I found this at: https://kb.daisy.org/publishing/docs/html/dpub-aria/doc-footnote.html which fixes the validation error.
>> 
>> Of course, I have only verified this with my limited use case i.e. footnotes, and I am not sure what the far-reaching consequences of making this change would be.
>> 
>> Cheers
>> 
>> On Wednesday, November 15, 2023 at 11:15:59 PM UTC+5:30 Nandakumar Chandrasekhar wrote:
>> Thank you for your reply.
>> 
>> I am using the validator put out by the W3C avaliable at: https://validator.w3.org/
>> 
>> I will experiment with XHTML and figure out the syntactic differences and see what happens.
>> 
>> I do not know much about aria roles so will have read up on those.
>> 
>> Many thanks.
>> 
>> On Wed, 15 Nov, 2023, 20:48 Nandakumar Chandrasekhar, <navani...@gmail.com> wrote:
>> Dear Folks,
>> 
>> I have the following question in regard to the HTML 5 generated by Pandoc.
>> 
>> Is Pandoc generating HTML 5 using the XHTML standard?
>> 
>> When validating the generated HTML through the W3C validator I see the following information notices about void elements:
>> 
>> Trailing slash on void elements has no effect and interacts badly with unquoted attribute values.
>> 
>> Since this is just informational I am not too worried about the trailing slash being placed at the end of elements although it does not seem to be part of the HTML 5 standard.
>> 
>> However, when I am faced with an error like below I would like to fix it:
>> 
>> Error: Bad value doc-endnotes for attribute role on element aside.
>> </figure>↩<aside id="footnotes" class="footnotes footnotes-end-of-document"↩role="doc-endnotes">↩<hr />
>> 
>> I would like to know the community's verdict on this and how I may remove these messages while validating if at all possible. Many thanks
>> 
>> -- 
>> You received this message because you are subscribed to a topic in the Google Groups "pandoc-discuss" group.
>> To unsubscribe from this topic, visit https://groups.google.com/d/topic/pandoc-discuss/E7Y0798bvp0/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>> 
>> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/f5859ff8-3e37-4794-9c85-ef6456cd73c1n%40googlegroups.com.
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
>> To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
>> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/08116215-7638-4f79-9261-2574aa1422e7n%40googlegroups.com.
> 

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/30400E29-2EF8-494E-9AF8-F3EFC7784372%40gmail.com.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2023-12-04 17:09 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-15 15:18 Validating Pandoc generated HTML 5 Nandakumar Chandrasekhar
     [not found] ` <f5859ff8-3e37-4794-9c85-ef6456cd73c1n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2023-11-15 17:21   ` John MacFarlane
2023-11-15 17:45   ` Nandakumar Chandrasekhar
     [not found]     ` <CAMhuDe8L9CLLXQVU=c3ZfmpyLe+k4h2E9zjNAk8MGHwXT84N2Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2023-11-16  2:42       ` Nandakumar Chandrasekhar
     [not found]         ` <07c5c0cd-f115-476c-bd17-c1c31470602an-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2023-11-17 15:33           ` Nandakumar Chandrasekhar
     [not found]             ` <08116215-7638-4f79-9261-2574aa1422e7n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2023-12-04 16:56               ` John MacFarlane
     [not found]                 ` <1EF73A39-A2CD-49D0-9F14-3EDDB1E85A23-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2023-12-04 17:09                   ` John MacFarlane

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).