简体   繁体   中英

Are there any custom semantic html tags project for designing html pages?

I found Semantic UI project here: http://semantic-ui.com/

Semantic is structured around natural language conventions to make development more intuitive.

For example bellow code creates a menu using Semantic :

<nav class="ui menu">
  <h3 class="header item">Title</h3>
  <a class="active item">Home</a>
  <a class="item">Link</a>
  <a class="item">Link</a>
  <span class="right floated text item">
    Signed in as <a href="#">user</a>
  </span>
</nav>

instead of Bootstrap CSS classes:

<div class="navbar">
  <a class="navbar-brand" href="#">Title</a>
  <ul class="nav navbar-nav">
    <li class="active"><a href="#">Home</a></li>
    <li><a href="#">Link</a></li>
    <li><a href="#">Link</a></li>
    <p class="navbar-text pull-right">Signed in as <a href="#" class="navbar-link">User</a></p>
  </ul>
</div>

My question is: Are there any custom semantic html tags project for designing html pages?

Something like this:

<menu>
    <menu-header>Title</menu-header>
    <menu-item active="true">Home</menu-item>
    <menu-item>Link</menu-item>
    <menu-item>Link</menu-item>
</menu>

There are some of them in the HTML5 definition, for instance the <article> one from https://developer.mozilla.org/en-US/docs/Web/HTML/Element#Content_sectioning .

<menu> happens to be an other one of them : https://developer.mozilla.org/en-US/docs/Web/HTML/Element/menu .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM