日本搞逼视频_黄色一级片免费在线观看_色99久久_性明星video另类hd_欧美77_综合在线视频

中國最全IT社區平臺 聯系我們 | 收藏本站
阿里云優惠2

jqueryui教程

jQuery UI 教程

jQuery UI 主題

jQuery UI 部件庫

jQuery UI 參考手冊

jQuery UI 實例

jQuery UI 實例 – 特效(Effect)

閱讀 (2298)

jQuery UI 實例 - 特效(Effect)

對一個元素應用動畫特效。

如需了解更多有關 .effect() 方法的細節,請查看 API 文檔 .effect()

.effect() 演示

點擊按鈕預覽特效。

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>jQuery UI 特效 - .effect() 演示</title>
  <link rel="stylesheet" href="/s//code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css">
  <script src="/upload/help///code.jquery.com/jquery-1.9.1.js"></script>
  <script src="/upload/help///code.jquery.com/ui/1.10.4/jquery-ui.js"></script>
  <link rel="stylesheet" >
  <style>
    .toggler { width: 500px; height: 200px; position: relative; }
    #button { padding: .5em 1em; text-decoration: none; }
    #effect { width: 240px; height: 135px; padding: 0.4em; position: relative; }
    #effect h3 { margin: 0; padding: 0.4em; text-align: center; }
    .ui-effects-transfer { border: 2px dotted gray; }
  </style>
  <script>
  $(function() {
    // 運行當前選中的特效
    function runEffect() {
      // 從中獲取特效類型
      var selectedEffect = $( "#effectTypes" ).val();
 
      // 大多數的特效類型默認不需要傳遞選項
      var options = {};
      // 一些特效帶有必需的參數
      if ( selectedEffect === "scale" ) {
        options = { percent: 0 };
      } else if ( selectedEffect === "transfer" ) {
        options = { to: "#button", className: "ui-effects-transfer" };
      } else if ( selectedEffect === "size" ) {
        options = { to: { width: 200, height: 60 } };
      }
 
      // 運行特效
      $( "#effect" ).effect( selectedEffect, options, 500, callback );
    };
 
    // 回調函數
    function callback() {
      setTimeout(function() {
        $( "#effect" ).removeAttr( "style" ).hide().fadeIn();
      }, 1000 );
    };
 
    // 根據選擇菜單值設置特效
    $( "#button" ).click(function() {
      runEffect();
      return false;
    });
  });
  </script>
</head>
<body>
 
<div class="toggler">
  <div id="effect" class="ui-widget-content ui-corner-all">
    <h3 class="ui-widget-header ui-corner-all">特效(Effect)</h3>
    <p>
      Etiam libero neque, luctus a, eleifend nec, semper at, lorem. Sed pede. Nulla lorem metus, adipiscing ut, luctus sed, hendrerit vitae, mi.
    </p>
  </div>
</div>
 
<select name="effects" id="effectTypes">
  <option value="blind">百葉窗特效(Blind Effect)</option>
  <option value="bounce">反彈特效(Bounce Effect)</option>
  <option value="clip">剪輯特效(Clip Effect)</option>
  <option value="drop">降落特效(Drop Effect)</option>
  <option value="explode">爆炸特效(Explode Effect)</option>
  <option value="fade">淡入淡出特效(Fade Effect)</option>
  <option value="fold">折疊特效(Fold Effect)</option>
  <option value="highlight">突出特效(Highlight Effect)</option>
  <option value="puff">膨脹特效(Puff Effect)</option>
  <option value="pulsate">跳動特效(Pulsate Effect)</option>
  <option value="scale">縮放特效(Scale Effect)</option>
  <option value="shake">震動特效(Shake Effect)</option>
  <option value="size">尺寸特效(Size Effect)</option>
  <option value="slide">滑動特效(Slide Effect)</option>
  <option value="transfer">轉移特效(Transfer Effect)</option>
</select>
 
<a href="#" id="button" class="ui-state-default ui-corner-all">運行特效</a>
 
 
</body>
</html>

Easing 演示

本實例使用 HTML Canvas 元素,繪制了 jQuery UI 提供的所有 easings。 點擊每個圖可查看該 easing 的行為。。

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>jQuery UI 特效 - Easing 演示</title>
  <link rel="stylesheet" href="/s//code.jquery.com/ui/1.10.4/themes/smoothness/jquery-ui.css">
  <script src="/upload/help///code.jquery.com/jquery-1.9.1.js"></script>
  <script src="/upload/help///code.jquery.com/ui/1.10.4/jquery-ui.js"></script>
  <link rel="stylesheet" >
  <style>
  .graph {
    float: left;
    margin-left: 10px;
  }
  </style>
  <script>
  $(function() {
    if ( !$( "<canvas>" )[0].getContext ) {
      $( "<div>" ).text(
        "您的瀏覽器不支持 canvas,本演示需要在支持 canvas 的瀏覽器下進行。"
      ).appendTo( "#graphs" );
      return;
    }
 
    var i = 0,
      width = 100,
      height = 100;
 
    $.each( $.easing, function( name, impl ) {
      var graph = $( "<div>" ).addClass( "graph" ).appendTo( "#graphs" ),
        text = $( "<div>" ).text( ++i + ". " + name ).appendTo( graph ),
        wrap = $( "<div>" ).appendTo( graph ).css( 'overflow', 'hidden' ),
        canvas = $( "<canvas>" ).appendTo( wrap )[ 0 ];
 
      canvas.width = width;
      canvas.height = height;
      var drawHeight = height * 0.8,
        cradius = 10;
        ctx = canvas.getContext( "2d" );
      ctx.fillStyle = "black";
 
      // 繪制背景
      ctx.beginPath();
      ctx.moveTo( cradius, 0 );
      ctx.quadraticCurveTo( 0, 0, 0, cradius );
      ctx.lineTo( 0, height - cradius );
      ctx.quadraticCurveTo( 0, height, cradius, height );
      ctx.lineTo( width - cradius, height );
      ctx.quadraticCurveTo( width, height, width, height - cradius );
      ctx.lineTo( width, 0 );
      ctx.lineTo( cradius, 0 );
      ctx.fill();
 
      // 繪制底線
      ctx.strokeStyle = "#555";
      ctx.beginPath();
      ctx.moveTo( width * 0.1, drawHeight + .5 );
      ctx.lineTo( width * 0.9, drawHeight + .5 );
      ctx.stroke();
 
      // 繪制頂線
      ctx.strokeStyle = "#555";
      ctx.beginPath();
      ctx.moveTo( width * 0.1, drawHeight * .3 - .5 );
      ctx.lineTo( width * 0.9, drawHeight * .3 - .5 );
      ctx.stroke();
 
      // 繪制 easing
      ctx.strokeStyle = "white";
      ctx.beginPath();
      ctx.lineWidth = 2;
      ctx.moveTo( width * 0.1, drawHeight );
      $.each( new Array( width ), function( position ) {
        var state = position / width,
          val = impl( state, position, 0, 1, width );
        ctx.lineTo( position * 0.8 + width * 0.1,
          drawHeight - drawHeight * val * 0.7 );
      });
      ctx.stroke();
 
      // 點擊時動態改變
      graph.click(function() {
        wrap
          .animate( { height: "hide" }, 2000, name )
          .delay( 800 )
          .animate( { height: "show" }, 2000, name );
      });
 
      graph.width( width ).height( height + text.height() + 10 );
    });
  });
  </script>
</head>
<body>
 
<div id="graphs"></div>
 
 
</body>
</html>

關閉
程序員人生
主站蜘蛛池模板: 亚洲国产一区二区三区, | 成人91 | 久久久精品 | 欧美日韩激情一区 | 免费一级毛片在线观看 | 日本在线不卡视频 | 国产精品永久在线 | 精品一区二区三区蜜桃 | 亚洲久久一区 | 91麻豆精品国产自产在线观看一区 | 久久久精品免费观看 | 在线免费av网址 | 自拍偷拍第5页 | 久久综合色婷婷 | 中文字幕专区高清在线观看 | 久久九精品| 国产区一区二区三区 | 天堂网avav | 日本综合视频 | 亚洲精品美女久久久久网站 | 精品国产乱码久久久 | 亚洲激情小视频 | 成人一区二 | 黄视频网站在线观看 | 欧美人交a欧美精品 | 亚洲电影一区二区 | 综合久久久久久久 | 日韩电影在线看 | 久久国产系列 | 在线一级黄色片 | 香蕉视频一区二区三区 | 国产小视频在线观看 | 国产精品电影一区 | 中文字幕二区 | 看全色黄大色黄大片女图片第一次 | 国产精品亚洲第一区在线暖暖韩国 | 国产激情视频在线 | 福利视频一区二区三区 | 免费av黄色片 | 亚洲三级在线看 | 国产一区久久 |