Swiper輪播圖原始碼分享解析

巴扎黑
發布: 2018-05-28 17:04:48
原創
4593 人瀏覽過

#le

<br>
登入後複製
<!DOCTYPE html>
登入後複製
<html lang="en">
登入後複製
<head>
登入後複製
<meta charset="utf-8">
登入後複製
<title>Swiper demo</title>
登入後複製
<meta name="viewport" content="width=device-width, initial-scale=1, minimum-scale=1, maximum-scale=1">
登入後複製
rr.

超級簡單的:

ereee
<!-- Link Swiper&#39;s CSS -->
登入後複製
<link rel="stylesheet" href="../dist/css/swiper.min.css?1.1.11">
登入後複製
<!-- Demo styles -->
登入後複製
<style>
登入後複製
html, body {
登入後複製
position: relative;
登入後複製
height: 100%;
登入後複製
登入後複製
}
登入後複製
登入後複製
登入後複製
登入後複製
body {
登入後複製
rrree reee
background: #eee;
登入後複製
font-family: Helvetica Neue, Helvetica, Arial, sans-serif;
登入後複製
font-size: 14px;
登入後複製
color:#000;
登入後複製
margin: 0;
登入後複製
padding: 0;
登入後複製
}
登入後複製
登入後複製
登入後複製
登入後複製
.swiper-container {
登入後複製
width: 100%;
登入後複製
height: 100%;
登入後複製
登入後複製
}
登入後複製
登入後複製
登入後複製
登入後複製
.swiper-slide {
登入後複製
text-align: center;
登入後複製
font-size: 18px;
登入後複製
background: #fff;
登入後複製
/* Center slide text vertically */
登入後複製
display: -webkit-box;
登入後複製
display: -ms-flexbox;
登入後複製
display: -webkit-flex;
登入後複製
display: flex;
登入後複製
-webkit-box-pack: center;
登入後複製
-ms-flex-pack: center;
登入後複製
-webkit-justify-content: center;
登入後複製
justify-content: center;
登入後複製
-webkit-box-align: center;
登入後複製
-ms-flex-align: center;
登入後複製
-webkit-align-items: center;
登入後複製
align-items: center;
登入後複製
}
登入後複製
登入後複製
登入後複製
登入後複製
</style>
登入後複製
</head>
登入後複製
rr東西之前要先引Swiper.css和Swiper.js插件哦!

以上是Swiper輪播圖原始碼分享解析的詳細內容。更多資訊請關注PHP中文網其他相關文章!

相關標籤:
來源:php.cn
本網站聲明
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn
熱門教學
更多>
最新下載
更多>
網站特效
網站源碼
網站素材
前端模板
關於我們 免責聲明 Sitemap
PHP中文網:公益線上PHP培訓,幫助PHP學習者快速成長!