Skip to content

ID on <math> element for referencing equations #94

@MartheGjelstad

Description

@MartheGjelstad

Earlier, we have had long discussions about how we should id and reference equations. Because the validator in Webarch didn't support IDs on <math> elements, we decided to place the <math> element in a <p> or <span> element and the ID on these outer elements.

Then we discussed if a <math> element must be in a <p> element if it is inside a list element, table cell etc. We concluded with "no". However, with the current solution for IDs for expressions, an expressions with an ID must be in a <p> or <span> element.

We have asked that the validator in Webarch accept IDs on <math> elements. Hopefully, this will be possible. If so, could the markup below be used to reference an equation? This works in Thorium, in the Tibi app and in browser. (IDs on <math> elements are not supported by EasyReader.) Or do we need aria-labelledby or something similar?

 <math xmlns="http://www.w3.org/1998/Math/MathML" display="block" id="eq-1-1">
   <mtable>
     <mtr>
       <mtd><mtext>(1.1)</mtext></mtd>
       <mtd><mi>x</mi><mo>=</mo><mtext>&#8197;block</mtext></mtd>
     </mtr>
   </mtable>
</math>

<p>A reference to equation <a href="#eq-1-1">(1.1)</a></p>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions