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

HTML code in the spec has bad quality #51

Open
domel opened this issue Nov 1, 2024 · 12 comments
Open

HTML code in the spec has bad quality #51

domel opened this issue Nov 1, 2024 · 12 comments
Labels
propose closing Proposed for closing spec:editorial Minor change in the specification (markup, typo, informative text; class 1 or 2)

Comments

@domel
Copy link
Contributor

domel commented Nov 1, 2024

The specification inherits a significant amount of low-quality HTML code from older versions (1.0, 1.1). Some of the issues observed include:

  • Tables used in a non-semantic way
  • Missing essential HTML elements
  • Redundant HTML tags
  • Additional miscellaneous issues

Improving the HTML quality will enhance readability, maintainability, and overall compliance with modern standards.

@domel domel mentioned this issue Nov 1, 2024
@pfps pfps added the spec:editorial Minor change in the specification (markup, typo, informative text; class 1 or 2) label Nov 20, 2024
@pfps
Copy link
Contributor

pfps commented Feb 6, 2025

@domel has this been resolved?

@pfps pfps added the propose closing Proposed for closing label Feb 6, 2025
@domel
Copy link
Contributor Author

domel commented Feb 6, 2025

Not at all.

@pfps
Copy link
Contributor

pfps commented Feb 6, 2025

What issues remain?

@domel
Copy link
Contributor Author

domel commented Feb 6, 2025

  • Tables are used in a non-semantic way and lack proper structure.
  • Missing essential HTML elements affect correct document rendering.
  • Redundant HTML tags increase code complexity and should be removed.
  • Outdated meta tags need replacement with modern equivalents.
  • Improper section nesting may cause rendering issues and errors.
  • Duplicated or inconsistent element IDs can create potential conflicts.
  • Excessive section nesting reduces both readability and accessibility.
  • Inline elements inside paragraphs do not follow semantic HTML practices.
  • Some tables have incorrect structures, including nested paragraphs.
  • Missing table elements, such as headers and captions, reduce clarity.
  • Table data cells are incorrectly used instead of proper header elements.
  • Inline styles should be replaced with external CSS for better structure.
  • Lack of use of semantic elements in mathematical formulas.

@pfps
Copy link
Contributor

pfps commented Feb 6, 2025

Do any of these affect the readability of the document?

@domel
Copy link
Contributor Author

domel commented Feb 6, 2025

Yes, some subissues effect for humans and some for machines (that is also indirectly to human eg. people with disabilities).

@pfps
Copy link
Contributor

pfps commented Feb 6, 2025

Please provide examples.

@domel
Copy link
Contributor Author

domel commented Feb 7, 2025

<meta http-equiv='Content-Type' content='text/html;charset=utf-8'/>
  <table id="RDFS_axiomatic_triples">
    <caption>RDFS axiomatic triples.</caption>
    <tr>
      <td class="ruletable"> <code>rdf:type rdfs:domain rdfs:Resource .<br/>
        rdfs:domain rdfs:domain rdf:Property .<br/>
        rdfs:range rdfs:domain rdf:Property .<br/>
        rdfs:subPropertyOf rdfs:domain rdf:Property .<br/>
        rdfs:subClassOf rdfs:domain rdfs:Class .<br/>
        rdf:subject rdfs:domain rdf:Statement .<br/>
        rdf:predicate rdfs:domain rdf:Statement .<br/>
        rdf:object rdfs:domain rdf:Statement .<br/>
        rdfs:member rdfs:domain rdfs:Resource . <br/>
        rdf:first rdfs:domain rdf:List .<br/>
        rdf:rest rdfs:domain rdf:List .<br/>
        rdfs:seeAlso rdfs:domain rdfs:Resource .<br/>
        rdfs:isDefinedBy rdfs:domain rdfs:Resource .<br/>
        rdfs:comment rdfs:domain rdfs:Resource .<br/>
        rdfs:label rdfs:domain rdfs:Resource .<br/>
        rdf:value rdfs:domain rdfs:Resource .<br/>
        <br/>
        rdf:type rdfs:range rdfs:Class .<br/>
        rdfs:domain rdfs:range rdfs:Class .<br/>
        rdfs:range rdfs:range rdfs:Class .<br/>
        rdfs:subPropertyOf rdfs:range rdf:Property .<br/>
        rdfs:subClassOf rdfs:range rdfs:Class .<br/>
        rdf:subject rdfs:range rdfs:Resource .<br/>
        rdf:predicate rdfs:range rdfs:Resource .<br/>
        rdf:object rdfs:range rdfs:Resource .<br/>
        rdfs:member rdfs:range rdfs:Resource .<br/>
        rdf:first rdfs:range rdfs:Resource .<br/>
        rdf:rest rdfs:range rdf:List .<br/>
        rdfs:seeAlso rdfs:range rdfs:Resource .<br/>
        rdfs:isDefinedBy rdfs:range rdfs:Resource .<br/>
        rdfs:comment rdfs:range rdfs:Literal .<br/>
        rdfs:label rdfs:range rdfs:Literal .<br/>
        rdf:value rdfs:range rdfs:Resource .<br/>
        <br/>
        rdf:Alt rdfs:subClassOf rdfs:Container .<br/>
        rdf:Bag rdfs:subClassOf rdfs:Container .<br/>
        rdf:Seq rdfs:subClassOf rdfs:Container .<br/>
        rdfs:ContainerMembershipProperty rdfs:subClassOf rdf:Property .<br/>
        <br/>
        rdfs:isDefinedBy rdfs:subPropertyOf rdfs:seeAlso .<br/>
        <br/>

        rdf:reifies rdfs:range rdfs:Proposition .<br/>
        <br/>
        
        rdfs:Datatype rdfs:subClassOf rdfs:Class .<br/>
        <br/>
        rdf:_1 rdf:type rdfs:ContainerMembershipProperty .<br/>
        <span >rdf:_1 rdfs:domain rdfs:Resource .<br/>
        rdf:_1 rdfs:range rdfs:Resource .</span> <br/>
        rdf:_2 rdf:type rdfs:ContainerMembershipProperty .<br/>
        rdf:_2 rdfs:domain rdfs:Resource .<br/>
        rdf:_2 rdfs:range rdfs:Resource . <br/>
        </code>... <br/> 
        </td>
    </tr>
  </table>
        For example, RDF statements of the form <br/><br/>
        <code>ex:a rdfs:subClassOf "Thing"^^xsd:string .</code><br/><br/>
        are prohibited in the OWL <a>semantic extension</a> based on description logics [[?OWL2-SYNTAX]].
<p>Any process which constructs a graph E from
      some other graph S is (simply) <dfn>valid</dfn> if S

      <p><img src="RDF12SemanticsDiagrams/example5.svg" alt="Overlapping Graphs" style="max-width: 100%"></p> 
<img src="RDF12SemanticsDiagrams/example1.svg" alt="Graph 1" />
A triple <b><i>appears in</i></b> a graph G
<p/>

@domel
Copy link
Contributor Author

domel commented Feb 7, 2025

I would be grateful if you could remove the propose closing label.

@TallTed
Copy link
Member

TallTed commented Feb 7, 2025

@domel — It would be helpful to me, and probably to others, if you could break this into one issue per concern, as listed in #51 (comment).

I would ask that you include in each such issue the explicit codeblock(s) (and/or links to same) as seen in #51 (comment).

This would make it more possible to understand your concerns, and thus to respond to them, whether by PR or otherwise.

As it stands, I don't understand your complaint about, for instance, <p/>, which is (so far as I can see) just a unnecessary / in a possibly unnecessary (but possibly helpful in adding vertical whitespace where it occurs) <p>.

Indeed, you could skip ahead, and submit PRs for each of the concerns you've loosely identified above, which PRs should make the resolution you desire clear to the rest of us.

@domel
Copy link
Contributor Author

domel commented Feb 7, 2025

As it stands, I don't understand your complaint about, for instance, <p/>, which is (so far as I can see) just a unnecessary / in a possibly unnecessary (but possibly helpful in adding vertical whitespace where it occurs) <p>.

No, in HTML, there is no <p/>, there is <p></p>. It is also possible to use <p> then the end tag may be omitted if the p element is immediately followed by an address, article, aside, blockquote, details, div, dl, fieldset, figcaption, figure, footer, form, h1, h2, h3, h4, h5, h6, header, hgroup, hr, main, menu, nav, ol, pre, search, section, table, ul or another p element, or if there is no more content in the parent element and the parent element is not an a, audio, del, ins, map, noscript or video element, or an autonomous custom element. If one wants to achieve greater vertical spacing from this is CSS not HTML. HTML defines the structure and content of a webpage, while CSS controls its presentation and styling.

Indeed, you could skip ahead, and submit PRs for each of the concerns you've loosely identified above, which PRs should make the resolution you desire clear to the rest of us.

No chance, sorry. I have had too many negative experiences working with a few people here in this context.

@TallTed
Copy link
Member

TallTed commented Feb 7, 2025

No, in HTML, there is no <p/>

Wow... That's the sort of thing I usually catch.

Digging into the document, I found one <p/> was a typo for </p>. Easy fix. PR #88 in progress.

The other (there were only two instances) is a pure orphan, but it separates two tables in the source HTML. I'm betting these get blurred together without such separator. I'll find out in a minute, when I preview my PR in progress.

... Confirmed. It's a separator between two tables. I've now changed the markup from <p/> to <p></p> which I'm sure is imperfect, but it does the necessary job (scroll up a bit from this anchor) for the moment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
propose closing Proposed for closing spec:editorial Minor change in the specification (markup, typo, informative text; class 1 or 2)
Projects
None yet
Development

No branches or pull requests

3 participants