HTML
CSS
JavaScript
HTML
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>浮动操作按钮动画</title>
  <link rel="stylesheet" href="../assets/mdui-v0.2.1/css/mdui.min.css"/>
</head>
<body class="mdui-theme-primary-indigo mdui-theme-accent-pink">

<div class="mdui-container">
  <button class="mdui-fab mdui-color-theme-accent mdui-ripple" id="fab-animation"><i class="mdui-icon material-icons">&#xe145;</i></button>

  <button class="mdui-btn" id="fab-animation-show">show</button>
  <button class="mdui-btn" id="fab-animation-hide">hide</button>
</div>

<script src="../assets/mdui-v0.2.1/js/mdui.min.js"></script>
</body>
</html>
CSS

    
JavaScript
var $$ = mdui.JQ;

$$('#fab-animation-show').on('click', function () {
  $$('#fab-animation').removeClass('mdui-fab-hide');
});

$$('#fab-animation-hide').on('click', function () {
  $$('#fab-animation').addClass('mdui-fab-hide');
});