HTML
CSS
JavaScript
play_arrow
HTML
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>菜单 - 级联菜单</title>
  <link rel="stylesheet" href="//cdn.jsdelivr.net/npm/mdui@1.0.1/dist/css/mdui.min.css"/>
</head>
<body class="mdui-theme-primary-indigo mdui-theme-accent-pink">

<div class="mdui-container mdui-p-t-5">
  <button class="mdui-btn mdui-color-theme-accent" mdui-menu="{target: '#example-3'}">open</button>
  <ul class="mdui-menu mdui-menu-cascade" id="example-3">
    <li class="mdui-menu-item">
      <a href="javascript:;" class="mdui-ripple">
        <i class="mdui-menu-item-icon mdui-icon material-icons">format_bold</i>
        Bold
        <span class="mdui-menu-item-helper">Ctrl+B</span>
      </a>
    </li>
    <li class="mdui-menu-item">
      <a href="javascript:;" class="mdui-ripple">
        <i class="mdui-menu-item-icon mdui-icon material-icons">format_italic</i>
        Italic
      </a>
    </li>
    <li class="mdui-menu-item">
      <a href="javascript:;" class="mdui-ripple">
        <i class="mdui-menu-item-icon"></i>
        Superscript
        <span class="mdui-menu-item-helper">Ctrl+.</span>
      </a>
    </li>
    <li class="mdui-divider"></li>
    <li class="mdui-menu-item">
      <a href="javascript:;" class="mdui-ripple">
        Paragraph style
        <span class="mdui-menu-item-more"></span>
      </a>
      <ul class="mdui-menu mdui-menu-cascade">
        <li class="mdui-menu-item">
          <a href="javascript:;" class="mdui-ripple">
            <i class="mdui-menu-item-icon"></i>Single
          </a>
        </li>
        <li class="mdui-menu-item">
          <a href="javascript:;" class="mdui-ripple">
            <i class="mdui-menu-item-icon mdui-icon material-icons">check</i>1.15
          </a>
        </li>
        <li class="mdui-menu-item">
          <a href="javascript:;" class="mdui-ripple">
            <i class="mdui-menu-item-icon"></i>Double
          </a>
        </li>
      </ul>
    </li>
  </ul>
</div>

<script src="//cdn.jsdelivr.net/npm/mdui@1.0.1/dist/js/mdui.min.js"></script>
</body>
</html>
CSS

  
JavaScript