From 1ccd4ee594c7fe838d53031aab100445e516dd26 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9E=97=E4=B8=80=E5=B3=B0?= <1feng.0595@gmail.com> Date: Mon, 28 Aug 2017 00:09:39 +0800 Subject: [PATCH] frozen --- app/Common/OSS.php | 116 + app/Common/Sms.php | 22 + app/Common/Token.php | 4 +- app/Http/Controllers/Api/GoodsController.php | 15 +- app/Http/Controllers/Api/ImageController.php | 6 +- .../Controllers/Api/WechatAuthController.php | 117 + app/Http/Kernel.php | 6 +- app/Http/Middleware/TokenAuth.php | 4 +- app/Http/Model/Goods.php | 11 +- public/css/bxslider.css | 184 - public/css/frozen.css | 2972 +++++++++++++++++ public/css/language-selector.css | 300 -- public/css/lanrenzhijia.css | 218 -- public/fonts/iconfont-full.ttf | Bin 0 -> 13032 bytes public/fonts/iconfont.ttf | Bin 0 -> 4524 bytes public/js/bxslider.min.js | 10 - public/js/frozen.js | 1527 +++++++++ public/js/online.js | 70 - public/js/zepto.min.js | 1773 ++++++++++ routes/web.php | 5 +- 20 files changed, 6551 insertions(+), 809 deletions(-) create mode 100644 app/Common/OSS.php create mode 100644 app/Http/Controllers/Api/WechatAuthController.php delete mode 100644 public/css/bxslider.css create mode 100644 public/css/frozen.css delete mode 100644 public/css/language-selector.css delete mode 100644 public/css/lanrenzhijia.css create mode 100644 public/fonts/iconfont-full.ttf create mode 100644 public/fonts/iconfont.ttf delete mode 100644 public/js/bxslider.min.js create mode 100644 public/js/frozen.js delete mode 100644 public/js/online.js create mode 100644 public/js/zepto.min.js diff --git a/app/Common/OSS.php b/app/Common/OSS.php new file mode 100644 index 0000000..5701b74 --- /dev/null +++ b/app/Common/OSS.php @@ -0,0 +1,116 @@ +ossClient = AliyunOSS::boot( + $serverAddress, + config('app.AccessKeyId'), + config('app.AccessKeySecret') + ); + } + + public static function upload($ossKey, $filePath, $bucket = '') + { + $isInternal = config('app.isInternal'); + !$bucket && $bucket = config('app.ossBucket'); + $oss = new OSS($isInternal); // 上传文件使用内网,免流量费 + $oss->ossClient->setBucket($bucket); + $oss->ossClient->uploadFile($ossKey, $filePath); + } + + /** + * 直接把变量内容上传到oss + * + * @param $osskey + * @param $content + * @param string $bucket + */ + public static function uploadContent($osskey, $content, $bucket = '') + { + $isInternal = config('app.isInternal'); + !$bucket && $bucket = config('app.ossBucket'); + $oss = new OSS($isInternal); // 上传文件使用内网,免流量费 + $oss->ossClient->setBucket($bucket); + $oss->ossClient->uploadContent($osskey, $content); + } + + /** + * 删除存储在oss中的文件 + * + * @param string $ossKey 存储的key(文件路径和文件名) + * @param string $bucket + * + * @return bool + */ + public static function deleteObject($ossKey, $bucket = '') + { + $isInternal = config('app.isInternal'); + !$bucket && $bucket = config('app.ossBucket'); + $oss = new OSS($isInternal); // 上传文件使用内网,免流量费 + return $oss->ossClient->deleteObject($bucket, $ossKey); + } + + /** + * 复制存储在阿里云OSS中的Object + * + * @param string $sourceBuckt 复制的源Bucket + * @param string $sourceKey - 复制的的源Object的Key + * @param string $destBucket - 复制的目的Bucket + * @param string $destKey - 复制的目的Object的Key + * + * @return Models\CopyObjectResult + */ + public function copyObject($sourceBuckt, $sourceKey, $destBucket, $destKey) + { + $oss = new OSS(true); // 上传文件使用内网,免流量费 + + return $oss->ossClient->copyObject($sourceBuckt, $sourceKey, $destBucket, $destKey); + } + + /** + * 移动存储在阿里云OSS中的Object + * + * @param string $sourceBuckt 复制的源Bucket + * @param string $sourceKey - 复制的的源Object的Key + * @param string $destBucket - 复制的目的Bucket + * @param string $destKey - 复制的目的Object的Key + * + * @return Models\CopyObjectResult + */ + public function moveObject($sourceBuckt, $sourceKey, $destBucket, $destKey) + { + $oss = new OSS(true); // 上传文件使用内网,免流量费 + + return $oss->ossClient->moveObject($sourceBuckt, $sourceKey, $destBucket, $destKey); + } + + public static function getUrl($ossKey, $bucket = '') + { + !$bucket && $bucket = config('app.ossBucket'); + $oss = new OSS(); + $oss->ossClient->setBucket($bucket); + return $oss->ossClient->getUrl($ossKey, new \DateTime("+1 day")); + } + + public static function createBucket($bucketName) + { + $oss = new OSS(); + return $oss->ossClient->createBucket($bucketName); + } + + public static function getAllObjectKey($bucketName) + { + $oss = new OSS(); + return $oss->ossClient->getAllObjectKey($bucketName); + } + +} \ No newline at end of file diff --git a/app/Common/Sms.php b/app/Common/Sms.php index e40519b..dc18eff 100644 --- a/app/Common/Sms.php +++ b/app/Common/Sms.php @@ -37,4 +37,26 @@ class Sms SmsLog::success($mobile, $text, $result); return true; } + + /** + * 阿里大于 + * + * @param $text 发送的内容 + * @param $mobile 要发送到哪个手机号上 + * @return bool + */ + public static function SendDySms($text, $mobile) + { + $c = new TopClient; + $c->appkey = $appkey; + $c->secretKey = $secret; + $req = new AlibabaAliqinFcSmsNumSendRequest; + $req->setExtend("123456"); + $req->setSmsType("normal"); + $req->setSmsFreeSignName("阿里大于"); + $req->setSmsParam("{\"code\":\"1234\",\"product\":\"alidayu\"}"); + $req->setRecNum("13000000000"); + $req->setSmsTemplateCode("SMS_585014"); + $resp = $c->execute($req); + } } \ No newline at end of file diff --git a/app/Common/Token.php b/app/Common/Token.php index 1aada0f..ed3eeac 100644 --- a/app/Common/Token.php +++ b/app/Common/Token.php @@ -87,7 +87,7 @@ class Token { if($data == $token->data && strtotime($token->expired_at)>time()) { - return array('token'=>$token->token,'expired_at'=>$token->expired_at); + return array('access_token'=>$token->token,'expired_at'=>$token->expired_at); } } @@ -103,6 +103,6 @@ class Token 'expired_at' => $expired_at )); - return array('token'=>$token,'expired_at'=>$expired_at); + return array('access_token'=>$token,'expired_at'=>$expired_at); } } \ No newline at end of file diff --git a/app/Http/Controllers/Api/GoodsController.php b/app/Http/Controllers/Api/GoodsController.php index 25b407e..1509631 100644 --- a/app/Http/Controllers/Api/GoodsController.php +++ b/app/Http/Controllers/Api/GoodsController.php @@ -19,15 +19,16 @@ class GoodsController extends CommonController //参数 $data['limit'] = $request->input('limit', 10); $data['offset'] = $request->input('offset', 0); - if($request->input('type', null) !== null){$data['type'] = $request->input('type');} - $data['user_id'] = Token::$uid; + if($request->input('typeid', '') != ''){$data['typeid'] = $request->input('typeid');} + if($request->input('tuijian', '') != ''){$data['tuijian'] = $request->input('tuijian');} + if($request->input('status', '') != ''){$data['status'] = $request->input('status');} + if($request->input('keyword', '') != ''){$data['keyword'] = $request->input('keyword');} + if($request->input('min_price', '') != ''){$data['min_price'] = $request->input('min_price');} + if($request->input('max_price', '') != ''){$data['max_price'] = $request->input('max_price');} + if($request->input('orderby', '') != ''){$data['orderby'] = $request->input('orderby');} $res = Goods::getList($data); - if($res === false) - { - return ReturnData::create(ReturnData::SYSTEM_FAIL); - } - + return ReturnData::create(ReturnData::SUCCESS,$res); } diff --git a/app/Http/Controllers/Api/ImageController.php b/app/Http/Controllers/Api/ImageController.php index 09b9100..69e5ac4 100644 --- a/app/Http/Controllers/Api/ImageController.php +++ b/app/Http/Controllers/Api/ImageController.php @@ -40,7 +40,7 @@ class ImageController extends CommonController } //文件小于1M - if ($file["size"] < 102400) + if ($file["size"] < 1024000) { if ($file["error"] > 0) { @@ -48,9 +48,9 @@ class ImageController extends CommonController } else { - if(!file_exists($uploads_path)) + if(!file_exists(base_path('public').$uploads_path)) { - Helper::createDir($uploads_path); //创建文件夹; + Helper::createDir(base_path('public').$uploads_path); //创建文件夹; } move_uploaded_file($file["tmp_name"], base_path('public').$image_path); diff --git a/app/Http/Controllers/Api/WechatAuthController.php b/app/Http/Controllers/Api/WechatAuthController.php new file mode 100644 index 0000000..552e13f --- /dev/null +++ b/app/Http/Controllers/Api/WechatAuthController.php @@ -0,0 +1,117 @@ +code = $this->getCode(); + $this->access_token = $this->getOpenId(); + $userInfo = $this->getUserInfo(); + + //把用户的微信信息存到数据库中 + /* if ($userInfo) + { + $ins = M('Wechat_user_info'); + $map['openid'] = $userInfo['openid']; + $result = $ins->where($map)->find(); //根据OPENID查找数据库中是否有这个用户,如果没有就写数据库。继承该类的其他类,用户都写入了数据库中。 + + if (!$result) + { + $ins->add($userInfo); + } + + $_SESSION['openid'] = $userInfo['openid']; //写到$_SESSION中。微信缓存很坑爹,调试时请及时清除缓存再试。 + } */ + } + } + + /** + * @explain + * 获取code,用于获取openid和access_token + * @remark + * code只能使用一次,当获取到之后code失效,再次获取需要重新进入 + * 不会弹出授权页面,适用于关注公众号后自定义菜单跳转等,如果不关注,那么只能获取openid + **/ + public function getCode() + { + if (isset($_REQUEST["code"])) + { + return $_REQUEST["code"]; + } + else + { + $str = "location: https://open.weixin.qq.com/connect/oauth2/authorize?appid=" . $this->appid . "&redirect_uri=" . $this->redirect_uri . "&response_type=code&scope=snsapi_userinfo&state=". $this->state ."#wechat_redirect"; + header($str); + exit; + } + } + + /** + * @explain + * 用于获取用户openid + **/ + public function getOpenId() + { + $access_token_url = "https://api.weixin.qq.com/sns/oauth2/access_token?appid=" . $this->appid . "&secret=" . $this->appsecret . "&code=" . $this->code . "&grant_type=authorization_code"; + $access_token_json = $this->https_request($access_token_url); + $access_token_array = json_decode($access_token_json, TRUE); + + return $access_token_array; + } + + /** + * @explain + * 通过code获取用户openid以及用户的微信号信息 + * @return + * @remark + * 获取到用户的openid之后可以判断用户是否有数据,可以直接跳过获取access_token,也可以继续获取access_token + * access_token每日获取次数是有限制的,access_token有时间限制,可以存储到数据库7200s. 7200s后access_token失效 + **/ + public function getUserInfo() + { + $userinfo_url = "https://api.weixin.qq.com/sns/userinfo?access_token=".$this->access_token['access_token'] ."&openid=" . $this->access_token['openid']."&lang=zh_CN"; + $userinfo_json = $this->https_request($userinfo_url); + $userinfo_array = json_decode($userinfo_json, TRUE); + + return $userinfo_array; + } + + + /** + * @explain + * 发送http请求,并返回数据 + **/ + public function https_request($url, $data = null) + { + $curl = curl_init(); + curl_setopt($curl, CURLOPT_URL, $url); + curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE); + curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, FALSE); + + if (!empty($data)) + { + curl_setopt($curl, CURLOPT_POST, 1); + curl_setopt($curl, CURLOPT_POSTFIELDS, $data); + } + + curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1); + $output = curl_exec($curl); + curl_close($curl); + + return $output; + } +} \ No newline at end of file diff --git a/app/Http/Kernel.php b/app/Http/Kernel.php index dcfef5f..661a684 100644 --- a/app/Http/Kernel.php +++ b/app/Http/Kernel.php @@ -27,11 +27,11 @@ class Kernel extends HttpKernel */ protected $middlewareGroups = [ 'web' => [ - \App\Http\Middleware\EncryptCookies::class, + //\App\Http\Middleware\EncryptCookies::class, //禁用,FLi \Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class, - \Illuminate\Session\Middleware\StartSession::class, + //\Illuminate\Session\Middleware\StartSession::class, //禁用,FLi // \Illuminate\Session\Middleware\AuthenticateSession::class, - \Illuminate\View\Middleware\ShareErrorsFromSession::class, + //\Illuminate\View\Middleware\ShareErrorsFromSession::class, //禁用,FLi // \App\Http\Middleware\VerifyCsrfToken::class, //禁用VerifyCsrfToken,FLi \Illuminate\Routing\Middleware\SubstituteBindings::class, ], diff --git a/app/Http/Middleware/TokenAuth.php b/app/Http/Middleware/TokenAuth.php index 6b753f9..164a3d2 100644 --- a/app/Http/Middleware/TokenAuth.php +++ b/app/Http/Middleware/TokenAuth.php @@ -13,9 +13,9 @@ class TokenAuth */ public function handle($request, Closure $next) { - $token = $request->header('Token') ?: $request->input('token'); + $token = $request->header('AccessToken','') ?: $request->input('access_token',''); - if (!$token) + if ($token == '') { return ReturnData::create(ReturnData::FORBIDDEN); } diff --git a/app/Http/Model/Goods.php b/app/Http/Model/Goods.php index 2967037..ea9d592 100644 --- a/app/Http/Model/Goods.php +++ b/app/Http/Model/Goods.php @@ -31,8 +31,8 @@ class Goods extends BaseModel //protected $connection = 'connection-name'; //常用字段 - protected $common_field = [ - 'id', 'typeid', 'tuijian', 'click', 'title', 'goods_sn', 'price','litpic', 'pubdate', 'addtime', 'market_price', 'goods_number', 'sale', 'comments','promote_start_date','promote_price','promote_end_date','goods_img','spec','point' + protected static $common_field = [ + 'id', 'typeid', 'tuijian', 'click', 'title', 'sn', 'price','litpic', 'pubdate', 'add_time', 'market_price', 'goods_number', 'sale', 'comments','promote_start_date','promote_price','promote_end_date','goods_img','spec','point' ]; const STATUS = 0; //商品是否删除,0未删除 @@ -66,8 +66,7 @@ class Goods extends BaseModel $model = $model->where($where); } - if(isset($keyword)){$model = $model->where("title", "like", "%$keyword%");} //关键词搜索 - if(isset($goods_sn)){$model = $model->where("goods_sn", "like", "%$goods_sn%");} //货号搜索 + if(isset($keyword)){$model = $model->where("title", "like", "%$keyword%")->orWhere("sn", "like", "%$keyword%");} //关键词搜索 if(isset($max_price) && isset($min_price)){$model = $model->where("price", ">=", $min_price)->where("price", "<=", $max_price);} //价格区间搜索 $res['count'] = $model->count(); @@ -99,10 +98,6 @@ class Goods extends BaseModel { $res['list'] = $model->select(self::$common_field)->skip($offset)->take($limit)->orderBy('id','desc')->get()->toArray(); } - else - { - return false; - } return $res; } diff --git a/public/css/bxslider.css b/public/css/bxslider.css deleted file mode 100644 index d055188..0000000 --- a/public/css/bxslider.css +++ /dev/null @@ -1,184 +0,0 @@ -/* AB模版网 做最好的织梦整站模板下载网站 */ -/* 网址:Www.AdminBuy.Cn */ -/* 图标大全:Sc.AdminBuy.Cn 专业建站素材网站 */ -/* QQ:9490489 */ -/** - * BxSlider v4.1.2 - Fully loaded, responsive content slider - * /bxslider.com - * - * Written by: Steven Wanderski, 2014 - * /stevenwanderski.com - * (while drinking Belgian ales and listening to jazz) - * - * CEO and founder of bxCreative, LTD - * /bxcreative.com - */ - - -/** RESET AND LAYOUT -===================================*/ - - -.bx-wrapper { - position: relative; - /*margin: 0 auto 60px;*/ - margin: 0 auto 0px; - padding: 0; - *zoom: 1; -} -.bx-wrapper img { - max-width: 100%; - display: block; -} -/** THEME -===================================*/ - -.bx-wrapper .bx-viewport { - /* -moz-box-shadow: 0 0 5px #ccc; - -webkit-box-shadow: 0 0 5px #ccc; - box-shadow: 0 0 5px #ccc; - border: 5px solid #fff; - left: -5px; - background: #fff;*/ - - /*fix other elements on the page moving (on Chrome)*/ - -webkit-transform: translatez(0); - -moz-transform: translatez(0); - -ms-transform: translatez(0); - -o-transform: translatez(0); - transform: translatez(0); -} -.bx-wrapper .bx-pager, .bx-wrapper .bx-controls-auto { - position: absolute; - bottom: -30px; - width: 100%; -} -/* LOADER */ - -.bx-wrapper .bx-loading { - min-height: 50px; - background: url(../images/bx_loader.gif) center center no-repeat #fff; - height: 100%; - width: 100%; - position: absolute; - top: 0; - left: 0; - z-index: 2000; -} -/* PAGER */ - -.bx-wrapper .bx-pager { - text-align: center; - font-size: .85em; - font-family: Arial; - font-weight: bold; - color: #666; - padding-top: 20px; -} -.bx-wrapper .bx-pager .bx-pager-item, .bx-wrapper .bx-controls-auto .bx-controls-auto-item { - display: inline-block; - *zoom: 1; - *display: inline; -} -.bx-wrapper .bx-pager.bx-default-pager a { - /*background: #303c4b;*/ - border: 1px solid #fff; - text-indent: -9999px; - display: block; - width: 15px; - height: 15px; - margin: 0 3px; - outline: 0; - -moz-border-radius: 10px; - -webkit-border-radius: 10px; - border-radius: 10px; -} -.bx-wrapper .bx-pager.bx-default-pager a:hover, .bx-wrapper .bx-pager.bx-default-pager a.active { - background: #fff; - border: 1px solid #fff; -} -/* DIRECTION CONTROLS (NEXT / PREV) */ - -.bx-wrapper .bx-prev { - left: 10px; - background: url(../images/controls.png) no-repeat 0 -32px; -} -.bx-wrapper .bx-next { - right: 10px; - background: url(../images/controls.png) no-repeat -43px -32px; -} -.bx-wrapper .bx-prev:hover { - background-position: 0 0; -} -.bx-wrapper .bx-next:hover { - background-position: -43px 0; -} -.bx-wrapper .bx-controls-direction a { - position: absolute; - top: 50%; - margin-top: -16px; - outline: 0; - width: 32px; - height: 32px; - text-indent: -9999px; - z-index: 999; -} -.bx-wrapper .bx-controls-direction a.disabled { - display: none; -} -/* AUTO CONTROLS (START / STOP) */ - -.bx-wrapper .bx-controls-auto { - text-align: center; -} -.bx-wrapper .bx-controls-auto .bx-start { - display: block; - text-indent: -9999px; - width: 10px; - height: 11px; - outline: 0; - background: url(../images/controls.png) -86px -11px no-repeat; - margin: 0 3px; -} -.bx-wrapper .bx-controls-auto .bx-start:hover, .bx-wrapper .bx-controls-auto .bx-start.active { - background-position: -86px 0; -} -.bx-wrapper .bx-controls-auto .bx-stop { - display: block; - text-indent: -9999px; - width: 9px; - height: 11px; - outline: 0; - background: url(../images/controls.png) -86px -44px no-repeat; - margin: 0 3px; -} -.bx-wrapper .bx-controls-auto .bx-stop:hover, .bx-wrapper .bx-controls-auto .bx-stop.active { - background-position: -86px -33px; -} -/* PAGER WITH AUTO-CONTROLS HYBRID LAYOUT */ - -.bx-wrapper .bx-controls.bx-has-controls-auto.bx-has-pager .bx-pager { - text-align: left; - width: 80%; -} -.bx-wrapper .bx-controls.bx-has-controls-auto.bx-has-pager .bx-controls-auto { - right: 0; - width: 35px; -} -/* IMAGE CAPTIONS */ - -.bx-wrapper .bx-caption { - position: absolute; - bottom: 0; - left: 0; - background: #666\9; - background: rgba(80, 80, 80, 0.75); - width: 100%; -} -.bx-wrapper .bx-caption span { - color: #fff; - font-family: Arial; - display: block; - font-size: .85em; - padding: 10px; -} \ No newline at end of file diff --git a/public/css/frozen.css b/public/css/frozen.css new file mode 100644 index 0000000..25180e0 --- /dev/null +++ b/public/css/frozen.css @@ -0,0 +1,2972 @@ +@charset "UTF-8"; +@media screen and (max-width: 319px) { + html { + font-size: 85.33333px; } } +@media screen and (min-width: 320px) and (max-width: 359px) { + html { + font-size: 85.33333px; } } +@media screen and (min-width: 360px) and (max-width: 374px) { + html { + font-size: 96px; } } +@media screen and (min-width: 375px) and (max-width: 383px) { + html { + font-size: 100px; } } +@media screen and (min-width: 384px) and (max-width: 399px) { + html { + font-size: 102.4px; } } +@media screen and (min-width: 400px) and (max-width: 413px) { + html { + font-size: 106.66667px; } } +@media screen and (min-width: 414px) { + html { + font-size: 110.4px; } } +/*CSS Reset*/ +body, +div, +dl, +dt, +dd, +ul, +ol, +li, +h1, +h2, +h3, +h4, +h5, +h6, +pre, +code, +form, +fieldset, +legend, +input, +textarea, +p, +blockquote, +th, +td, +header, +hgroup, +nav, +section, +article, +aside, +footer, +figure, +figcaption, +menu, +button { + margin: 0; + padding: 0; } + +body { + font-family: "Helvetica Neue",Helvetica,STHeiTi,sans-serif; + line-height: 1.5; + font-size: 16px; + color: #000; + background-color: #f8f8f8; + -webkit-user-select: none; + -webkit-text-size-adjust: 100%; + -webkit-tap-highlight-color: transparent; + outline: 0; } + +h1, h2, h3, h4, h5, h6 { + font-size: 100%; + font-weight: normal; } + +table { + border-collapse: collapse; + border-spacing: 0; } + +caption, th { + text-align: left; } + +fieldset, +img { + border: 0; } + +li { + list-style: none; } + +ins { + text-decoration: none; } + +del { + text-decoration: line-through; } + +input, +button, +textarea, +select, +optgroup, +option { + font-family: inherit; + font-size: inherit; + font-style: inherit; + font-weight: inherit; + outline: 0; } + +button { + -webkit-appearance: none; + border: 0; + background: none; } + +a { + -webkit-touch-callout: none; + text-decoration: none; } + +:focus { + outline: 0; + -webkit-tap-highlight-color: transparent; } + +em, i { + font-style: normal; } + +@font-face { + font-family: "iconfont"; + src: url(../font/iconfont.ttf) format("truetype"); } +.ui-icon, [class^="ui-icon-"] { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); } + +.ui-icon-close:before { + content: ""; } + +.ui-icon-search:before { + content: ""; } + +.ui-icon-return:before { + content: ""; } + +.ui-icon-close, +.ui-icon-search { + color: #8e8e93; } + +@font-face { + font-family: "iconfont"; + src: url(../font/iconfont-full.ttf) format("truetype"); } +.ui-icon, [class^="ui-icon-"] { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); } + +.ui-icon-add:before { + content: "\f615"; } + +.ui-icon-more:before { + content: "\f616"; } + +.ui-icon-arrow:before { + content: "\f600"; } + +.ui-icon-return:before { + content: "\f614"; } + +.ui-icon-checked:before { + content: "\f601"; } + +.ui-icon-checked-s:before { + content: "\f602"; } + +.ui-icon-info-block:before { + content: "\f603"; } + +.ui-icon-success-block:before { + content: "\f604"; } + +.ui-icon-warn-block:before { + content: "\f605"; } + +.ui-icon-info:before { + content: "\f606"; } + +.ui-icon-success:before { + content: "\f607"; } + +.ui-icon-warn:before { + content: "\f608"; } + +.ui-icon-next:before { + content: "\f617"; } + +.ui-icon-prev:before { + content: "\f618"; } + +.ui-icon-tag:before { + content: "\f60d"; } + +.ui-icon-tag-pop:before { + content: "\f60f"; } + +.ui-icon-tag-s:before { + content: "\f60e"; } + +.ui-icon-warn-lg:before { + content: "\f609"; } + +.ui-icon-close:before { + content: "\f60a"; } + +.ui-icon-close-progress:before { + content: "\f619"; } + +.ui-icon-close-page:before { + content: "\f60b"; } + +.ui-icon-emo:before { + content: "\f61a"; } + +.ui-icon-delete:before { + content: "\f61b"; } + +.ui-icon-search:before { + content: "\f60c"; } + +.ui-icon-order:before { + content: "\f61c"; } + +.ui-icon-news:before { + content: "\f61d"; } + +.ui-icon-personal:before { + content: "\f61e"; } + +.ui-icon-dressup:before { + content: "\f61f"; } + +.ui-icon-cart:before { + content: "\f620"; } + +.ui-icon-history:before { + content: "\f621"; } + +.ui-icon-wallet:before { + content: "\f622"; } + +.ui-icon-refresh:before { + content: "\f623"; } + +.ui-icon-thumb:before { + content: "\f624"; } + +.ui-icon-file:before { + content: "\f625"; } + +.ui-icon-hall:before { + content: "\f626"; } + +.ui-icon-voice:before { + content: "\f627"; } + +.ui-icon-unfold:before { + content: "\f628"; } + +.ui-icon-gototop:before { + content: "\f629"; } + +.ui-icon-share:before { + content: "\f62a"; } + +.ui-icon-home:before { + content: "\f62b"; } + +.ui-icon-pin:before { + content: "\f62c"; } + +.ui-icon-star:before { + content: "\f62d"; } + +.ui-icon-bugle:before { + content: "\f62e"; } + +.ui-icon-trend:before { + content: "\f62f"; } + +.ui-icon-unchecked:before { + content: "\f610"; } + +.ui-icon-unchecked-s:before { + content: "\f611"; } + +.ui-icon-play-active:before { + content: "\f630"; } + +.ui-icon-stop-active:before { + content: "\f631"; } + +.ui-icon-play:before { + content: "\f632"; } + +.ui-icon-stop:before { + content: "\f633"; } + +.ui-icon-set:before { + content: "\f634"; } + +.ui-icon-add-group:before { + content: "\f635"; } + +.ui-icon-add-people:before { + content: "\f636"; } + +.ui-icon-pc:before { + content: "\f637"; } + +.ui-icon-scan:before { + content: "\f638"; } + +.ui-icon-tag-svip:before { + content: "\f613"; } + +.ui-icon-tag-vip:before { + content: "\f612"; } + +.ui-icon-male:before { + content: "\f639"; } + +.ui-icon-female:before { + content: "\f63a"; } + +.ui-icon-collect:before { + content: "\f63b"; } + +.ui-icon-commented:before { + content: "\f63c"; } + +.ui-icon-like:before { + content: "\f63d"; } + +.ui-icon-liked:before { + content: "\f63e"; } + +.ui-icon-comment:before { + content: "\f63f"; } + +.ui-icon-collected:before { + content: "\f640"; } + +a { + color: #00a5e0; } + +em { + color: #ff8444; } + +::-webkit-input-placeholder { + color: #bbb; } + +/** + * 文字 + */ +h1 { + font-size: 18px; } + +h2 { + font-size: 17px; } + +h3, h4 { + font-size: 16px; } + +h5, .ui-txt-sub { + font-size: 14px; } + +h6, .ui-txt-tips { + font-size: 12px; } + +.ui-txt-default { + color: #000; } + +.ui-txt-white { + color: white; } + +.ui-txt-info { + color: #777; } + +.ui-txt-muted { + color: #bbb; } + +.ui-txt-warning, .ui-txt-red { + color: #ff4222; } + +.ui-txt-feeds { + color: #314c83; } + +/* 同em */ +.ui-txt-highlight { + color: #ff8444; } + +.ui-txt-justify { + text-align: justify; } + +.ui-txt-justify-one { + text-align: justify; + overflow: hidden; + height: 24px; } + +.ui-txt-justify-one:after { + display: inline-block; + content: ''; + overflow: hidden; + width: 100%; + height: 0; } + +/* 1px hack */ +.ui-border-t { + border-top: 1px solid #e0e0e0; } + +.ui-border-b { + border-bottom: 1px solid #e0e0e0; } + +.ui-border-tb { + border-top: #e0e0e0 1px solid; + border-bottom: #e0e0e0 1px solid; + background-image: none; } + +.ui-border-l { + border-left: 1px solid #e0e0e0; } + +.ui-border-r { + border-right: 1px solid #e0e0e0; } + +.ui-border { + border: 1px solid #e0e0e0; } + +.ui-border-radius { + border: 1px solid #e0e0e0; + border-radius: 4px; } + @media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-border-radius { + position: relative; + border: 0; } + .ui-border-radius:before { + content: ""; + width: 200%; + height: 200%; + position: absolute; + top: 0; + left: 0; + border: 1px solid #e0e0e0; + -webkit-transform: scale(0.5); + -webkit-transform-origin: 0 0; + padding: 1px; + -webkit-box-sizing: border-box; + border-radius: 8px; + pointer-events: none; } } + +@media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-border { + position: relative; + border: 0; } + + .ui-border-t, .ui-border-b, .ui-border-l, .ui-border-r, .ui-border-tb { + border: 0; } + + .ui-border-t { + background-position: left top; + background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); } + + .ui-border-b { + background-position: left bottom; + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); } + + .ui-border-t, + .ui-border-b, + .ui-border-tb { + background-repeat: repeat-x; + -webkit-background-size: 100% 1px; } + + .ui-border-tb { + background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)), -webkit-gradient(linear, left top, left bottom, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + background-position: top, bottom; } + + .ui-border-l { + background-position: left top; + background-image: -webkit-gradient(linear, right top, left top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); } + + .ui-border-r { + background-position: right top; + background-image: -webkit-gradient(linear, left top, right top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); } + + .ui-border-l, + .ui-border-r { + background-repeat: repeat-y; + -webkit-background-size: 1px 100%; } + + .ui-border:after { + content: ""; + width: 100%; + height: 100%; + position: absolute; + top: 0; + left: 0; + background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)), -webkit-gradient(linear, left top, right top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)), -webkit-gradient(linear, left top, left bottom, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)), -webkit-gradient(linear, right top, left top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + -webkit-background-size: 100% 1px,1px 100% ,100% 1px, 1px 100%; + background-size: 100% 1px,1px 100% ,100% 1px, 1px 100%; + background-size: 100% 1px,1px 100% ,100% 1px, 1px 100%; + background-repeat: no-repeat; + background-position: top, right, bottom, left; + padding: 1px; + -webkit-box-sizing: border-box; + z-index: 10; + pointer-events: none; } } +/* 箭头链接 */ +.ui-arrowlink { + position: relative; } + .ui-arrowlink:before { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + color: #c7c7c7; + content: ""; + position: absolute; + right: 15px; + top: 50%; + margin-top: -22px; + margin-right: -10px; } + @media (max-width: 320px) { + .ui-arrowlink:before { + right: 10px; } } + +.ui-arrowlink.active { + background: #e5e6e7; } + +/* 文字截断 */ +.ui-nowrap { + max-width: 100%; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; } + +.ui-nowrap-flex { + display: -webkit-box; + overflow: hidden; + text-overflow: ellipsis; + -webkit-box-orient: vertical; + -webkit-line-clamp: 1; + -webkit-box-flex: 1; + height: inherit; } + +.ui-nowrap-multi { + display: -webkit-box; + overflow: hidden; + text-overflow: ellipsis; + -webkit-box-orient: vertical; + -webkit-line-clamp: 2; } + +.ui-placehold-wrap { + padding-top: 31.25%; + position: relative; } + +.ui-placehold { + color: #bbb; + position: absolute; + top: 0; + width: 100%; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-box-pack: center; + -webkit-box-align: center; + -webkit-box-sizing: border-box; + text-align: center; + height: 100%; + z-index: -1; } + +.ui-placehold-img { + padding-top: 31.25%; + position: relative; } + .ui-placehold-img > span { + width: 100%; + height: 100%; + position: absolute; + top: 0; + left: 0; + z-index: 1; + background-repeat: no-repeat; + -webkit-background-size: cover; } + .ui-placehold-img img { + width: 100%; + height: 100%; } + +/* 三等分 */ +.ui-grid, .ui-grid-trisect, .ui-grid-halve { + padding-left: 15px; + padding-right: 10px; + overflow: hidden; + padding-top: 10px; } + @media (max-width: 320px) { + .ui-grid, .ui-grid-trisect, .ui-grid-halve { + padding-left: 10px; + padding-right: 5px; } } + .ui-grid li, .ui-grid-trisect li, .ui-grid-halve li { + padding-right: 5px; + padding-bottom: 10px; + float: left; + position: relative; + -webkit-box-sizing: border-box; } + +.ui-grid-trisect > li { + width: 33.3333%; } + +.ui-grid-trisect-img { + padding-top: 149.47%; } + +.ui-grid-trisect h4 { + position: relative; + margin: 7px 0 3px; } + +.ui-grid-trisect h4 span { + display: inline-block; + margin-left: 12px; + color: #777; } + +/* 二等分 */ +.ui-grid-halve > li { + width: 50%; } + +.ui-grid-halve-img { + padding-top: 55.17%; } + +.ui-grid-trisect-img, .ui-grid-halve-img { + position: relative; + width: 100%; } + .ui-grid-trisect-img > span, .ui-grid-halve-img > span { + width: 100%; + height: 100%; + position: absolute; + top: 0; + left: 0; + z-index: 1; + background-repeat: no-repeat; + -webkit-background-size: cover; } + .ui-grid-trisect-img img, .ui-grid-halve-img img { + width: 100%; + height: 100%; + position: absolute; + left: 0; + top: 0; } + .ui-grid-trisect-img.active, .ui-grid-halve-img.active { + opacity: .5; } + +.ui-row { + display: block; + overflow: hidden; } + +.ui-col { + float: left; + box-sizing: border-box; + width: 100%; } + +.ui-col-10 { + width: 10%; } + +.ui-col-20 { + width: 20%; } + +.ui-col-25 { + width: 25%; } + +.ui-col-33 { + width: 33.3333%; } + +.ui-col-50 { + width: 50%; } + +.ui-col-67 { + width: 66.6666%; } + +.ui-col-75 { + width: 75%; } + +.ui-col-80 { + width: 80%; } + +.ui-col-90 { + width: 90%; } + +.ui-row-flex { + display: -webkit-box; + width: 100%; + -webkit-box-sizing: border-box; } + .ui-row-flex .ui-col { + float: none; + -webkit-box-flex: 1; + width: 0; } + .ui-row-flex .ui-col-2 { + -webkit-box-flex: 2; } + .ui-row-flex .ui-col-3 { + -webkit-box-flex: 3; } + .ui-row-flex .ui-col-4 { + -webkit-box-flex: 4; } + +.ui-row-flex-ver { + -webkit-box-orient: vertical; } + .ui-row-flex-ver .ui-col { + width: 100%; + height: 0; } + +.ui-whitespace { + padding-left: 15px; + padding-right: 15px; + box-sizing: border-box; } + @media (max-width: 320px) { + .ui-whitespace { + padding-left: 10px; + padding-right: 10px; } } + +.ui-whitespace-left { + padding-left: 15px; + box-sizing: border-box; } + @media (max-width: 320px) { + .ui-whitespace-left { + padding-left: 10px; } } + +.ui-whitespace-right { + padding-right: 15px; + box-sizing: border-box; } + @media (max-width: 320px) { + .ui-whitespace-right { + padding-right: 10px; } } + +.ui-justify { + text-align: justify; + font-size: 0; } + .ui-justify:after { + content: ''; + display: inline-block; + width: 100%; + height: 0; + overflow: hidden; } + .ui-justify li { + display: inline-block; + text-align: center; } + .ui-justify p { + font-size: 16px; } + +.ui-justify-flex { + width: 100%; + display: -webkit-box; + -webkit-box-pack: justify; + -webkit-justify-content: space-between; } + +.ui-header, +.ui-footer { + position: fixed; + width: 100%; + z-index: 100; + left: 0; } + +.ui-header { + top: 0; + height: 45px; + line-height: 45px; } + +.ui-header-stable, +.ui-header-positive { + padding: 0 10px; + box-sizing: border-box; } + +.ui-header-stable, +.ui-footer-stable { + background-color: #f8f8f8; } + +.ui-header-positive, +.ui-footer-positive { + background-color: #18b4ed; + color: #fff; } + .ui-header-positive a, .ui-header-positive a:active, .ui-header-positive i, + .ui-footer-positive a, + .ui-footer-positive a:active, + .ui-footer-positive i { + color: #fff; } + +.ui-footer-btn { + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0, #f9f9f9), to(#e0e0e0)); + color: #00a5e0; } + .ui-footer-btn .ui-tiled { + height: 100%; } + +.ui-footer { + bottom: 0; + height: 56px; } + +.ui-header ~ .ui-container { + border-top: 45px solid transparent; } + +.ui-footer ~ .ui-container { + border-bottom: 56px solid transparent; } + +.ui-header h1 { + text-align: center; + font-size: 18px; } + +.ui-header .ui-icon-return { + position: absolute; + left: 0; } + +.ui-header .ui-btn, .ui-header .ui-btn-lg, .ui-header .ui-btn-s { + display: block; + position: absolute; + right: 10px; + top: 50%; + margin-top: -15px; } + +/** + * 垂直上下居中 + */ +.ui-center { + width: 100%; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-box-pack: center; + -webkit-box-align: center; + text-align: center; + height: 150px; } + +/** + * 排版 + */ +.ui-flex, +.ui-tiled { + display: -webkit-box; + width: 100%; + -webkit-box-sizing: border-box; } + +.ui-flex-ver { + -webkit-box-orient: vertical; } + +.ui-flex-pack-start { + -webkit-box-pack: start; } + +.ui-flex-pack-end { + -webkit-box-pack: end; } + +.ui-flex-pack-center { + -webkit-box-pack: center; } + +.ui-flex-align-start { + -webkit-box-align: start; } + +.ui-flex-align-end { + -webkit-box-align: end; } + +.ui-flex-align-center { + -webkit-box-align: center; } + +/** + * 平铺 + */ +.ui-tiled li { + -webkit-box-flex: 1; + width: 100%; + text-align: center; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-box-pack: center; + -webkit-box-align: center; } + +/** + * 未读数通知 + */ +.ui-badge, .ui-badge-muted, .ui-badge-num, .ui-badge-corner, .ui-badge-cornernum { + display: inline-block; + text-align: center; + background: #f74c31; + color: #fff; + font-size: 11px; + height: 16px; + line-height: 16px; + -webkit-border-radius: 8px; + padding: 0 6px; + background-clip: padding-box; } + +/* 浅色的 */ +.ui-badge-muted { + background: #b6cae0; } + +.ui-badge-num { + height: 19px; + line-height: 20px; + font-size: 12px; + min-width: 19px; + -webkit-border-radius: 10px; } + +.ui-badge-wrap { + position: relative; + text-align: center; } + +.ui-badge-corner { + position: absolute; + border: 2px #fff solid; + height: 20px; + line-height: 20px; + top: -4px; + right: -9px; } + +.ui-badge-cornernum { + position: absolute; + top: -4px; + right: -9px; + height: 19px; + line-height: 19px; + font-size: 12px; + min-width: 19px; + -webkit-border-radius: 10px; + top: -5px; + right: -5px; } + +/** +* 红点提醒 +*/ +.ui-reddot, .ui-reddot-border, .ui-reddot-s { + position: relative; + display: inline-block; + line-height: 22px; + padding: 0 6px; } + .ui-reddot:after, .ui-reddot-border:after, .ui-reddot-s:after { + content: ''; + position: absolute; + display: block; + width: 8px; + height: 8px; + background-color: #f74c31; + border-radius: 5px; + right: -3px; + top: -3px; + background-clip: padding-box; } + +.ui-reddot-static { + display: block; + width: 8px; + height: 8px; + padding: 0; } + .ui-reddot-static:after { + top: 0; + right: 0; } + +/* 带白边的 */ +.ui-reddot-border:before { + content: ''; + position: absolute; + display: block; + width: 8px; + height: 8px; + background-color: #fff; + border-radius: 5px; + right: -4px; + top: -4px; + background-clip: padding-box; + padding: 1px; } + +/* 小号的 */ +.ui-reddot-s:after { + width: 6px; + height: 6px; + top: -5px; + right: -5px; } + +/** + * 圆角头像,列表场景 + */ +.ui-avatar, +.ui-avatar-lg, +.ui-avatar-s, +.ui-avatar-one, +.ui-avatar-tiled { + display: block; + -webkit-background-size: cover; + background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAMAAABHPGVmAAAA8FBMVEXp8Peat8+jwNidutKhvtagvdWcudGfu9Kpwteiv9ecudCsxNifvNTM2+ieu9PE1eSdudDO3OmkvtSyyNu/0eKhvNOivdPm7vWlv9WeutHI2Oa5zd+dudG+0eHn7/bG1+Xi6/SzydzT4Ozc5vDe6PLY5O/a5e/P3eqmv9WmwNW6zt/j7PTX4+6uxtno8Pff6fLh6vPW4u280ODg6fLC1OObuM+buNDD1eTU4eza5fDd5/GhvNKowdarw9jA0+K1y93k7PTk7fXl7fW7zt/F1uXc5/DZ5O/R3+vB0+OnwNXg6vKcuNDM2+mtxNjO3eq3zN1UQ75QAAACR0lEQVR4Xu3W1a7cMBAG4PnHDi4zMx5mxiLD+79Ne7YXq6hKHMU+Ui/8XVpKfo0nMwr9hyzLsizLsqx5ZTfX9DyvmXtXOaNXsd+rYqs9mJFx454HiLwMXsi8CzTO35JZ0x1ABLwlBZAzW0yhAzfgKOmiekLmVEII/peAd22u5ZGMSEpzSWYc30cyoim+oe4/wuU4LgZkwq0HyXEkPCMX9hmC4wmcHpK2VhWS40ncHZG2KcBJBAom2l7kJA6eSFsNDicJsB5qt8SH5EToz0nT1zUCRUi4IE3zqjLkm/aaPGsrQ8oz0nSkDgm1Z750AU4mtL/hYQ1FThZgZ4+0HH9BoAzx9knL8hKsoL9YChCsksdAd3PlWcXBhHSM15CsEqCsNY49uKwm4Lcos5MyAk7BRYmyOpxAcBoOqkca/1sBpyKyl1KH4HQc5J4pmzYkpwQsKJsQnFYRI8qmnD7EwdPrh0gcZA9xio76piBY4iFziACUMw+EcLNXEgKd7o5qVtD52UYeu5RNB3iiifIP0qcRgAplU4N/TNdILsVFgVq/0My6Vxa9lyeTF5jAwzPRsF4gLbfNhBSJ/pRMKPThxGbgkcy4iu19HqdkxN7oR2wlDmqrQ9K39JPm8RLYbZGu8T1cJ3mp1ElXJVqGLAKI7DOJxpA0Le8gJP8VSIGN7RE7Lmr6XfneACCKfwgAjfPFdP8qcpSbk76bgX+BDe+gPqMXs3quj43OQekNGTH+WBmV3nc/fdi+b+9m1S2VuqvZM6lZlmVZlmVZvwEAnS9LHbI74gAAAABJRU5ErkJggg==); } + +.ui-avatar { + width: 50px; + height: 50px; + -webkit-border-radius: 200px; + overflow: hidden; } + .ui-avatar > span { + width: 100%; + height: 100%; + display: block; + overflow: hidden; + background-repeat: no-repeat; + -webkit-background-size: cover; + -webkit-border-radius: 200px; } + +.ui-avatar-lg, +.ui-avatar-one { + width: 70px; + height: 70px; + -webkit-border-radius: 200px; + overflow: hidden; } + .ui-avatar-lg > span, + .ui-avatar-one > span { + width: 100%; + height: 100%; + display: block; + overflow: hidden; + background-repeat: no-repeat; + -webkit-background-size: cover; + -webkit-border-radius: 200px; } + +.ui-avatar-s { + width: 40px; + height: 40px; + -webkit-border-radius: 200px; + overflow: hidden; } + .ui-avatar-s > span { + width: 100%; + height: 100%; + display: block; + overflow: hidden; + background-repeat: no-repeat; + -webkit-background-size: cover; + -webkit-border-radius: 200px; } + +/* 平铺场景 */ +.ui-avatar-tiled { + width: 30px; + height: 30px; + -webkit-border-radius: 200px; + overflow: hidden; + display: inline-block; } + .ui-avatar-tiled > span { + width: 100%; + height: 100%; + display: block; + overflow: hidden; + background-repeat: no-repeat; + -webkit-background-size: cover; + -webkit-border-radius: 200px; } + +.ui-label { + display: inline-block; + position: relative; + line-height: 30px; + height: 30px; + padding: 0 15px; + border: 1px solid #cacccd; + border-radius: 15px; } + @media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-label { + position: relative; + border: 0; } + .ui-label:before { + content: ""; + width: 200%; + height: 200%; + position: absolute; + top: 0; + left: 0; + border: 1px solid #cacccd; + -webkit-transform: scale(0.5); + -webkit-transform-origin: 0 0; + padding: 1px; + -webkit-box-sizing: border-box; + border-radius: 30px; + pointer-events: none; } } + .ui-label:active { + background-color: #f3f2f2; } + +.ui-label-list { + margin: 0 10px; } + .ui-label-list .ui-label { + margin: 0 10px 10px 0; } + +.ui-label-s { + font-size: 11px; + line-height: 13px; + display: inline-block; + position: relative; + padding: 0 1px; + color: #ff7f0d; + border: 1px solid #ff7f0d; + border-radius: 2px; } + @media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-label-s { + position: relative; + border: 0; } + .ui-label-s:before { + content: ""; + width: 200%; + height: 200%; + position: absolute; + top: 0; + left: 0; + border: 1px solid #ff7f0d; + -webkit-transform: scale(0.5); + -webkit-transform-origin: 0 0; + padding: 1px; + -webkit-box-sizing: border-box; + border-radius: 4px; + pointer-events: none; } } + .ui-label-s:active { + background-color: #f3f2f2; } + .ui-label-s:after { + content: ""; + position: absolute; + top: -5px; + bottom: -5px; + left: -5px; + right: -5px; } + +.ui-tag-t, .ui-tag-hot, +.ui-tag-new, +.ui-tag-s-hot, +.ui-tag-s-new, +.ui-tag-pop-hot, +.ui-tag-pop-new { + position: relative; } + +.ui-tag-t:before, .ui-tag-hot:before, +.ui-tag-new:before, +.ui-tag-s-hot:before, +.ui-tag-s-new:before, +.ui-tag-pop-hot:before, +.ui-tag-pop-new:before, +.ui-tag-t:after, +.ui-tag-hot:after, +.ui-tag-new:after, +.ui-tag-s-hot:after, +.ui-tag-s-new:after, +.ui-tag-pop-hot:after, +.ui-tag-pop-new:after { + height: 20px; + left: 0; + top: 0; + z-index: 9; + display: block; } + +.ui-tag-t:before, .ui-tag-hot:before, +.ui-tag-new:before, +.ui-tag-s-hot:before, +.ui-tag-s-new:before, +.ui-tag-pop-hot:before, +.ui-tag-pop-new:before, +.ui-tag-vip:before, +.ui-tag-svip:before, +.ui-tag-selected:after { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + position: absolute; } + +.ui-tag-t:before, .ui-tag-hot:before, +.ui-tag-new:before, +.ui-tag-s-hot:before, +.ui-tag-s-new:before, +.ui-tag-pop-hot:before, +.ui-tag-pop-new:before { + content: ""; + line-height: 20px; + color: #ff0000; } + +.ui-tag-t:after, .ui-tag-hot:after, +.ui-tag-new:after, +.ui-tag-s-hot:after, +.ui-tag-s-new:after, +.ui-tag-pop-hot:after, +.ui-tag-pop-new:after { + position: absolute; + content: ''; + width: 22px; + text-align: right; + line-height: 20px; + font-size: 12px; + color: #fff; + padding-right: 14px; } + +.ui-tag-b, .ui-tag-freelimit, +.ui-tag-free, +.ui-tag-last, +.ui-tag-limit, +.ui-tag-act, +.ui-tag-xy, +.ui-tag-vip, +.ui-tag-svip { + position: relative; } + +.ui-tag-b:before, .ui-tag-freelimit:before, +.ui-tag-free:before, +.ui-tag-last:before, +.ui-tag-limit:before, +.ui-tag-act:before, +.ui-tag-xy:before, +.ui-tag-vip:before, +.ui-tag-svip:before { + position: absolute; + font-size: 10px; + width: 28px; + height: 13px; + line-height: 13px; + bottom: 0; + right: 0; + z-index: 9; + color: #fff; + border-radius: 2px; + text-align: center; } + +.ui-tag-vip:before, +.ui-tag-svip:before { + font-size: 32px; + text-indent: -2px; + border-radius: 2px; } + +.ui-tag-vip:before { + background-color: #ff0000; + color: #fffadf; + content: ""; } + +.ui-tag-svip:before { + background-color: #ffd400; + color: #b7440e; + content: ""; } + +.ui-tag-freelimit:before { + background-color: #18b4ed; + content: '限免'; } + +.ui-tag-free:before { + background-color: #5fb336; + content: '免费'; } + +.ui-tag-last:before { + background-color: #8f6adb; + content: '绝版'; } + +.ui-tag-limit:before { + background-color: #3385e6; + content: '限量'; } + +.ui-tag-act:before { + background-color: #00c795; + content: '活动'; } + +.ui-tag-xy:before { + background-color: #d7ba42; + content: '星影'; } + +.ui-tag-freemonthly:before { + background-color: #ff7f0d; + content: '包月'; } + +.ui-tag-onsale:before { + background-color: #00c795; + content: '特价'; } + +.ui-tag-hot:after, +.ui-tag-s-hot:after, +.ui-tag-pop-hot:after { + content: '热'; } + +.ui-tag-new:after, +.ui-tag-s-new:after, +.ui-tag-pop-new:after { + content: '\u65b0'; } + +.ui-tag-hot:before, +.ui-tag-s-hot:before, +.ui-tag-pop-hot:before { + color: #ff7200; } + +.ui-tag-s-hot:before, +.ui-tag-s-new:before { + content: ""; + left: -2px; } + +.ui-tag-s-hot:after, +.ui-tag-s-new:after { + width: 16px; + padding-right: 12px; } + +.ui-tag-selected:after { + content: ""; + color: #18b4ed; + right: -5px; + top: -5px; + z-index: 9; + width: 26px; + height: 26px; + background: #fff; + border-radius: 13px; + line-height: 26px; + text-indent: -3px; } + +.ui-tag-wrap { + display: inline-block; + position: relative; + padding-right: 32px; } + .ui-tag-wrap .ui-tag-vip, + .ui-tag-wrap .ui-tag-svip { + position: static; } + .ui-tag-wrap .ui-tag-vip:before, + .ui-tag-wrap .ui-tag-svip:before { + top: 50%; + margin-top: -7px; } + +.ui-tag-pop-hot:before, +.ui-tag-pop-new:before { + content: ""; + left: -10px; + top: 1px; } + +.ui-tag-pop-hot:after, +.ui-tag-pop-new:after { + font-size: 11px; + padding-right: 0; + text-align: center; + left: -5px; } + +/** + * 按钮 + */ +.ui-btn, .ui-btn-lg, .ui-btn-s { + height: 30px; + line-height: 30px; + padding: 0 11px; + min-width: 55px; + display: inline-block; + position: relative; + text-align: center; + font-size: 15px; + background-color: #fdfdfd; + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0.5, #fff), to(#fafafa)); + vertical-align: top; + color: #00a5e0; + -webkit-box-sizing: border-box; + background-clip: padding-box; + border: 1px solid #cacccd; + border-radius: 3px; } + @media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-btn, .ui-btn-lg, .ui-btn-s { + position: relative; + border: 0; } + .ui-btn:before, .ui-btn-lg:before, .ui-btn-s:before { + content: ""; + width: 200%; + height: 200%; + position: absolute; + top: 0; + left: 0; + border: 1px solid #cacccd; + -webkit-transform: scale(0.5); + -webkit-transform-origin: 0 0; + padding: 1px; + -webkit-box-sizing: border-box; + border-radius: 6px; + pointer-events: none; } } + +.ui-btn:not(.disabled):not(:disabled):active, .ui-btn-lg:not(.disabled):not(:disabled):active, .ui-btn-s:not(.disabled):not(:disabled):active, .ui-btn.active, .active.ui-btn-lg, .active.ui-btn-s { + background: #f2f2f2; + color: rgba(0, 165, 224, 0.5); + background-clip: padding-box; } + +.ui-btn:after, .ui-btn-lg:after, .ui-btn-s:after { + content: ""; + position: absolute; + top: -7px; + bottom: -7px; + left: 0; + right: 0; } + +.ui-btn-primary { + background-color: #18b4ed; + border-color: #0baae4; + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0.5, #1fbaf3), to(#18b4ed)); + color: white; + background-clip: padding-box; } + +.ui-btn-primary:not(.disabled):not(:disabled):active, .ui-btn-primary.active { + background: #1ca7da; + border-color: #1ca7da; + color: rgba(255, 255, 255, 0.5); + background-clip: padding-box; } + +.ui-btn-danger { + background-color: #f75549; + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0.5, #fc6156), to(#f75549)); + color: white; + border-color: #f43d30; + background-clip: padding-box; } + +.ui-btn-danger:not(.disabled):not(:disabled):active, .ui-btn-danger.active { + background: #e2574d; + border-color: #e2574d; + color: rgba(255, 255, 255, 0.5); + background-clip: padding-box; } + +.ui-btn.disabled, .disabled.ui-btn-lg, .disabled.ui-btn-s, .ui-btn:disabled, .ui-btn-lg:disabled, .ui-btn-s:disabled { + border: 0; + color: #ccc; + background: #e9ebec; + background-clip: padding-box; } + +.ui-btn-lg { + font-size: 18px; + height: 44px; + line-height: 44px; + display: block; + width: 100%; + border-radius: 5px; } + +.ui-btn-wrap { + padding: 15px 10px; } + @media (max-width: 320px) { + .ui-btn-wrap { + padding: 10px; } } + +.ui-btn-s { + padding: 0; + width: 55px; + height: 25px; + line-height: 25px; + font-size: 13px; } + +@media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-btn-primary:before { + border: 1px solid #0baae4; } + + .ui-btn-danger:before { + border: 1px solid #f43d30; } + + .ui-btn, .ui-btn-lg, .ui-btn-s { + border: 0; } + + .ui-btn.disabled, .disabled.ui-btn-lg, .disabled.ui-btn-s, + .ui-btn:disabled, + .ui-btn-lg:disabled, + .ui-btn-s:disabled, + .ui-btn.disabled:before, + .disabled.ui-btn-lg:before, + .disabled.ui-btn-s:before, + .ui-btn:disabled:before, + .ui-btn-lg:disabled:before, + .ui-btn-s:disabled:before { + border: 1px solid #e9ebec; } + + .ui-btn-lg:before { + border-radius: 10px; } } +.ui-btn-progress { + width: 55px; + padding: 0; + overflow: hidden; } + .ui-btn-progress .ui-btn-inner { + position: absolute; + left: 0; + top: 0; + height: 100%; + overflow: hidden; + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0.5, #1fbaf3), to(#18b4ed)); + border-bottom-left-radius: 3px; + border-top-left-radius: 3px; } + .ui-btn-progress .ui-btn-inner span { + display: inline-block; + color: white; + position: absolute; + width: 55px; + left: 0; } + .ui-btn-progress.disabled, .ui-btn-progress:disabled { + background-color: #fefefe; + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0.5, white), to(#fafafa)); + color: #ccc; + border: 1px solid #cacccd; + background-clip: padding-box; } + +@media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-btn-progress.disabled, + .ui-btn-progress:disabled { + border: 0; } + + .ui-btn-progress.disabled:before, + .ui-btn-progress:disabled:before { + border: 1px solid #cacccd; } } +.ui-btn-group { + display: -webkit-box; + width: 100%; + box-sizing: border-box; + -webkit-box-align: center; } + +.ui-btn-group button { + display: block; + -webkit-box-flex: 1; + margin-right: 10px; } + .ui-btn-group button:first-child { + margin-left: 10px; } + +.ui-tips { + padding: 20px 15px; + text-align: center; + font-size: 16px; + color: #000; } + .ui-tips i { + display: inline-block; + width: 32px; + height: 1px; + vertical-align: top; } + +.ui-tips i:before { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + content: ""; + color: #0090ff; + line-height: 21px; } + +.ui-tips-success i:before { + content: ""; + color: #65d521; } + +.ui-tips-warn i:before { + content: ""; + color: #f76249; } + +/** + * 页面消息提示 + */ +.ui-newstips-wrap { + margin: 20px 15px; + text-align: center; } + +.ui-newstips { + background: #383939; + position: relative; + height: 40px; + line-height: 40px; + display: -webkit-inline-box; + -webkit-box-align: center; + padding-right: 25px; + border-radius: 5px; + font-size: 14px; + color: #fff; + padding-left: 15px; } + .ui-newstips .ui-avatar-tiled, .ui-newstips .ui-newstips-thumb, .ui-newstips i { + display: block; + margin-left: -5px; + margin-right: 10px; } + .ui-newstips .ui-newstips-thumb { + width: 30px; + height: 30px; + position: relative; } + .ui-newstips .ui-newstips-thumb > span { + display: block; + width: 100%; + height: 100%; + z-index: 1; + background-repeat: no-repeat; + -webkit-background-size: cover; } + .ui-newstips div { + display: -webkit-box; + overflow: hidden; + text-overflow: ellipsis; + -webkit-box-orient: vertical; + -webkit-line-clamp: 1; + -webkit-box-flex: 1; + height: inherit; } + +.ui-newstips:after { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + color: #c7c7c7; + content: ""; + position: absolute; + right: 15px; + top: 50%; + margin-top: -22px; + margin-right: -10px; } + @media (max-width: 320px) { + .ui-newstips:after { + right: 10px; } } + +.ui-newstips .ui-reddot, .ui-newstips .ui-reddot-border, .ui-newstips .ui-reddot-s, .ui-newstips .ui-badge-num { + margin-left: 10px; + margin-right: 5px; } + +.ui-tooltips { + width: 100%; + position: relative; + z-index: 99; + overflow: hidden; + box-sizing: border-box; } + +.ui-tooltips-cnt { + background-color: #fff; + line-height: 44px; + height: 44px; + padding-left: 10px; + padding-right: 30px; + max-width: 100%; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; } + .ui-tooltips-cnt .ui-icon-close:before { + font-size: 40px; + color: rgba(0, 0, 0, 0.2); + margin-left: -10px; + position: absolute; + right: 0; + top: 0; } + +.ui-tooltips-warn .ui-tooltips-cnt { + background-color: rgba(255, 242, 183, 0.95); + color: #000; } + +.ui-tooltips-warn:active .ui-tooltips-cnt { + background-color: #e1d498; } + +.ui-tooltips-guide .ui-tooltips-cnt { + color: #00a5e0; + background-color: rgba(205, 242, 255, 0.95); } + .ui-tooltips-guide .ui-tooltips-cnt .ui-icon-close:before { + color: rgba(0, 165, 224, 0.2); } + +.ui-tooltips-guide:active .ui-tooltips-cnt { + background-color: #b5dbe8; } + +.ui-tooltips-cnt-link:after { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + color: #c7c7c7; + content: ""; + position: absolute; + right: 15px; + top: 50%; + margin-top: -22px; + margin-right: -10px; + color: rgba(0, 0, 0, 0.5); } + @media (max-width: 320px) { + .ui-tooltips-cnt-link:after { + right: 10px; } } + +.ui-tooltips-guide .ui-tooltips-cnt-link:after { + color: #00aeef; } + +.ui-tooltips-warn i { + display: inline-block; + margin-right: 4px; + margin-left: -4px; + width: 32px; + height: 1px; + vertical-align: top; } + +.ui-tooltips-warn i:before { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + content: ""; + color: #f76249; } + +/** + * 表格 + */ +.ui-table { + width: 100%; + border-collapse: collapse; } + +.ui-table th { + font-weight: 500; } + +.ui-table td, .ui-table th { + border-bottom: 1px solid #e0e0e0; + border-right: 1px solid #e0e0e0; + text-align: center; } + +@media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-table td, .ui-table th { + position: relative; + border-right: 0; + border-bottom: 0; } + + .ui-table td:after, .ui-table th:after { + content: ""; + position: absolute; + width: 100%; + height: 100%; + left: 0; + top: 0; + background-image: -webkit-gradient(linear, left top, right top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)), -webkit-gradient(linear, left top, left bottom, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + background-size: 1px 100% ,100% 1px; + background-repeat: no-repeat; + background-position: right, bottom; + pointer-events: none; } + + .ui-table tr td:last-child:after, .ui-table tr th:last-child:after { + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + background-size: 100% 1px; + background-repeat: no-repeat; + background-position: bottom; } + + .ui-table tr:last-child td:not(:last-child):after { + background-image: -webkit-gradient(linear, left top, right top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + background-size: 1px 100%; + background-repeat: no-repeat; + background-position: right; } } +.ui-table tr td:last-child, .ui-table tr th:last-child { + border-right: 0; } + +.ui-table tr:last-child td { + border-bottom: 0; } + +.ui-list { + background-color: #fff; + width: 100%; } + .ui-list > li { + position: relative; + margin-left: 15px; + display: -webkit-box; } + +.ui-list-pure > li { + display: block; } + +/*文字列表*/ +.ui-list-text > li, +.ui-list-pure > li { + position: relative; + padding-top: 10px; + padding-bottom: 10px; + padding-right: 15px; + -webkit-box-align: center; } + +.ui-list-text h4, +.ui-list-text p { + -webkit-box-flex: 1; } + +/*通栏列表*/ +.ui-list-cover > li { + padding-left: 15px; + margin-left: 0px; } + +.ui-list > li.ui-border-t:first-child, +.ui-list > li:first-child > .ui-border-t { + border: none; + background-image: none; } + +/*列表缩略图*/ +.ui-list-thumb, +.ui-list-thumb-s, +.ui-list-img, +.ui-list-icon { + position: relative; + margin: 10px 10px 10px 0px; } + .ui-list-thumb > span, + .ui-list-thumb-s > span, + .ui-list-img > span, + .ui-list-icon > span { + display: block; + width: 100%; + height: 100%; + z-index: 1; + background-repeat: no-repeat; + -webkit-background-size: cover; } + +.ui-list-thumb { + width: 50px; + height: 50px; } + +/*列表普通图片*/ +.ui-list-img { + width: 100px; + height: 68px; } + +.ui-list-thumb-s { + width: 28px; + height: 28px; } + +/*列表icon*/ +.ui-list-icon { + width: 40px; + height: 40px; } + +.ui-list .ui-avatar, +.ui-list .ui-avatar-s, +.ui-list .ui-avatar-lg { + margin: 10px 10px 10px 0px; } + +/*列表主要信息*/ +.ui-list-info { + -webkit-box-flex: 1; + padding-top: 10px; + padding-bottom: 10px; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-box-pack: center; + padding-right: 15px; } + .ui-list-info p { + color: #777; + font-size: 14px; } + +.ui-list-text .ui-list-info { + padding-top: 0; + padding-bottom: 0; } + +.ui-list li h4 { + font-size: 16px; } + +.ui-list:not(.ui-list-text) li > p, +.ui-list li > h5 { + font-size: 14px; + color: #777; } + +/*列表按压态*/ +.ui-list-active > li:active, +.ui-list li.active { + background-color: #e5e6e7; + padding-left: 15px; + margin-left: 0px; } + +.ui-list-active > li:active, +.ui-list > li.active, +.ui-list > li.active > .ui-border-t, +.ui-list > li.active + li > .ui-border-t, +.ui-list > li.active + li.ui-border-t { + background-image: none; + border-top-color: #e5e6e7; } + +/*连接列表*/ +.ui-list-link > li:after { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + color: #c7c7c7; + content: ""; + position: absolute; + right: 15px; + top: 50%; + margin-top: -22px; + margin-right: -10px; } + @media (max-width: 320px) { + .ui-list-link > li:after { + right: 10px; } } + +.ui-list-text.ui-list-link > li { + padding-right: 30px; } + +.ui-list-link .ui-list-info { + padding-right: 30px; } + +/* 功能类 */ +.ui-list-function .ui-list-info { + padding-right: 75px; } + +.ui-list-function .ui-btn, .ui-list-function .ui-btn-lg, .ui-list-function .ui-btn-s { + position: absolute; + top: 50%; + right: 15px; + margin-top: -15px; } + +.ui-list-function .ui-btn-s { + margin-top: -12px; } + +.ui-list-function.ui-list-link .ui-list-info { + padding-right: 90px; } + +.ui-list-function.ui-list-link .ui-btn, .ui-list-function.ui-list-link .ui-btn-lg, .ui-list-function.ui-list-link .ui-btn-s { + right: 30px; } + +.ui-list-function li { + -webkit-box-align: inherit; } + +.ui-list-one > li { + padding-top: 0; + padding-bottom: 0; + line-height: 44px; } +.ui-list-one .ui-list-info { + -webkit-box-orient: horizontal; + -webkit-box-align: center; } +.ui-list-one h4 { + -webkit-box-flex: 1; } + +@media (max-width: 320px) { + .ui-list > li { + margin-left: 10px; } + + .ui-list-text > li, + .ui-list-pure > li, + .ui-list-info { + padding-right: 10px; } + + .ui-list-cover > li, + .ui-list-active > li:active, + .ui-list li.active { + padding-left: 10px; } + + .ui-list-text.ui-list-link > li { + padding-right: 25px; } + + .ui-list-function .ui-list-info { + padding-right: 70px; } + + .ui-list-function .ui-btn, .ui-list-function .ui-btn-lg, .ui-list-function .ui-btn-s { + right: 10px; } + + .ui-list-function.ui-list-link .ui-list-info { + padding-right: 85px; } + + .ui-list-function.ui-list-link .ui-btn, .ui-list-function.ui-list-link .ui-btn-lg, .ui-list-function.ui-list-link .ui-btn-s { + right: 25px; } } +/** + * 出错页面 + */ +.ui-notice { + width: 100%; + height: 100%; + z-index: 99; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-box-pack: center; + -webkit-box-align: center; + position: absolute; + text-align: center; } + +.ui-notice > i { + display: block; + margin-bottom: 20px; } + .ui-notice > i:before { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + content: ""; + font-size: 100px; + line-height: 100px; + color: rgba(0, 0, 0, 0.3); } + +.ui-notice p { + font-size: 16px; + line-height: 20px; + color: #bbb; + text-align: center; + padding: 0 15px; } + +.ui-notice-btn { + width: 100%; + -webkit-box-sizing: border-box; + padding: 50px 15px 15px; } + +.ui-notice-btn button { + margin: 10px 0px; } + +.ui-form { + background-color: #fff; } + +.ui-form-item-order.active { + background-color: #e5e6e7; } + +/* 表单输入项 */ +.ui-form-item { + position: relative; + font-size: 16px; + height: 44px; + line-height: 44px; + padding-right: 15px; + padding-left: 15px; } + .ui-form-item label:not(.ui-switch):not(.ui-checkbox):not(.ui-checkbox-s):not(.ui-radio) { + width: 95px; + position: absolute; + text-align: left; + box-sizing: border-box; } + .ui-form-item input, + .ui-form-item textarea { + width: 100%; + box-sizing: border-box; + -webkit-appearance: none; + border: 0; + background: none; + padding-left: 95px; } + .ui-form-item input[type="checkbox"], .ui-form-item input[type="radio"] { + padding-left: 0; } + .ui-form-item .ui-icon-close { + position: absolute; + top: 0; + right: 6px; } + @media (max-width: 320px) { + .ui-form-item .ui-icon-close { + right: 1px; } } + @media (max-width: 320px) { + .ui-form-item { + padding-left: 10px; + padding-right: 10px; } } + +.ui-form-item-textarea { + height: 65px; } + +.ui-form-item-textarea label { + vertical-align: top; } + +.ui-form-item-textarea textarea { + margin-top: 15px; + border: none; } + +.ui-form-item-textarea textarea:focus { + outline: none; } + +.ui-form-item-link > li:after { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + color: #c7c7c7; + content: ""; + position: absolute; + right: 15px; + top: 50%; + margin-top: -22px; + margin-right: -10px; } + @media (max-width: 320px) { + .ui-form-item-link > li:after { + right: 10px; } } + +.ui-form-item-l label, +.ui-form-item-r button { + color: #00a5e0; + text-align: center; } + +.ui-form-item-r .ui-icon-close { + right: 125px; } + +.ui-form-item-l input:not([type="checkbox"]):not([type="radio"]) { + padding-left: 115px; + -webkit-box-sizing: border-box; + box-sizing: border-box; } + +.ui-form-item-r { + padding-right: 0; } + +.ui-form-item-r input:not([type="checkbox"]):not([type="radio"]) { + padding-left: 0; + padding-right: 150px; + -webkit-box-sizing: border-box; + box-sizing: border-box; } + +.ui-form-item-r button { + width: 110px; + height: 44px; + position: absolute; + top: 0; + right: 0; } + +.ui-form-item-r button.disabled { + color: #bbb; } + +.ui-form-item-r button:not(.disabled):active { + background-color: #e5e6e7; } + +.ui-form-item-pure input, +.ui-form-item-pure textarea { + padding-left: 0; } + +/* 表单展示项 */ +.ui-form-item-show label { + color: #777; } + +.ui-form-item-link:after { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + color: #c7c7c7; + content: ""; + position: absolute; + right: 15px; + top: 50%; + margin-top: -22px; + margin-right: -10px; } + @media (max-width: 320px) { + .ui-form-item-link:after { + right: 10px; } } + +.ui-form-item-checkbox, +.ui-form-item-radio, +.ui-form-item-switch { + display: -webkit-box; + -webkit-box-align: center; } + +.ui-checkbox, .ui-checkbox-s { + display: inline-block; } + +.ui-checkbox input, .ui-checkbox-s input { + display: inline-block; + width: 25px; + height: 1px; + position: relative; + overflow: visible; + border: 0; + background: none; + -webkit-appearance: none; + outline: none; + margin-right: 8px; + vertical-align: middle; } + +.ui-checkbox input:before, .ui-checkbox-s input:before { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + content: ""; + color: #18b4ed; + position: absolute; + top: -22px; + left: -4px; + color: #dedfe0; } + +.ui-checkbox input:checked:before, .ui-checkbox-s input:checked:before { + content: ""; + color: #18b4ed; } + +.ui-checkbox-s input:before { + content: ""; } + +.ui-checkbox-s input:checked:before { + content: ""; } + +.ui-switch { + position: absolute; + font-size: 16px; + right: 15px; + top: 50%; + margin-top: -16px; + width: 52px; + height: 32px; + line-height: 32px; } + @media (max-width: 320px) { + .ui-switch { + right: 10px; } } + .ui-switch input { + width: 52px; + height: 32px; + position: absolute; + z-index: 2; + border: none; + background: none; + -webkit-appearance: none; + outline: none; } + .ui-switch input:before { + content: ''; + width: 50px; + height: 30px; + border: 1px solid #dfdfdf; + background-color: #fdfdfd; + border-radius: 20px; + cursor: pointer; + display: inline-block; + position: relative; + vertical-align: middle; + -webkit-box-sizing: content-box; + box-sizing: content-box; + border-color: #dfdfdf; + box-shadow: #dfdfdf 0px 0px 0px 0px inset; + -webkit-transition: border 0.4s, box-shadow 0.4s; + transition: border 0.4s, box-shadow 0.4s; + -webkit-background-clip: content-box; + background-clip: content-box; } + .ui-switch input:checked:before { + border-color: #64bd63; + box-shadow: #64bd63 0px 0px 0px 16px inset; + background-color: #64bd63; + transition: border 0.4s, box-shadow 0.4s, background-color 1.2s; + -webkit-transition: border 0.4s, box-shadow 0.4s, background-color 1.2s; + background-color: #64bd63; } + .ui-switch input:checked:after { + left: 21px; } + .ui-switch input:after { + content: ''; + width: 30px; + height: 30px; + position: absolute; + top: 1px; + left: 0; + border-radius: 100%; + background-color: #fff; + box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4); + -webkit-transition: left 0.2s; + transition: left 0.2s; } + +.ui-radio { + line-height: 25px; + display: inline-block; } + +.ui-radio input { + display: inline-block; + width: 26px; + height: 26px; + position: relative; + overflow: visible; + border: 0; + background: none; + -webkit-appearance: none; + outline: none; + margin-right: 8px; + vertical-align: middle; } + +.ui-radio input:before { + content: ''; + display: block; + width: 24px; + height: 24px; + border: 1px solid #dfe0e1; + border-radius: 13px; + background-clip: padding-box; + position: absolute; + left: 0px; + top: 0; } + +.ui-radio input:checked:after { + content: ''; + display: block; + width: 14px; + height: 14px; + background: #18b4ed; + border-radius: 7px; + position: absolute; + left: 6px; + top: 6px; } + +.ui-select { + position: relative; + margin-right: 6px; } + +.ui-select select { + -webkit-appearance: none; + border: 0; + background: none; + width: 100%; + padding-right: 14px; } + +.ui-select:after { + position: absolute; + top: 50%; + right: 0; + margin-top: -4px; + width: 0; + height: 0; + border-top: 6px solid; + border-right: 5px solid transparent; + border-left: 5px solid transparent; + color: #a6a6a6; + content: ""; + pointer-events: none; } + +.ui-select-group { + margin-left: 95px; + overflow: hidden; } + .ui-select-group .ui-select { + float: left; } + +.ui-form-item > .ui-select { + margin-left: 95px; } + +.ui-input-wrap { + background-color: #ebeced; + height: 44px; + display: -webkit-box; + -webkit-box-align: center; } + .ui-input-wrap .ui-btn, .ui-input-wrap .ui-btn-lg, .ui-input-wrap .ui-btn-s, .ui-input-wrap i { + margin-right: 10px; } + +.ui-input { + height: 30px; + line-height: 30px; + margin: 7px 10px; + background: #fff; + padding-left: 10px; + -webkit-box-flex: 1; } + +.ui-input input { + width: 100%; + height: 100%; + border: 0; + background: 0 0; + -webkit-appearance: none; + outline: 0; } + +.ui-searchbar-wrap { + display: -webkit-box; + -webkit-box-pack: center; + -webkit-box-align: center; + background-color: #ebeced; + height: 44px; } + .ui-searchbar-wrap button { + margin-right: 10px; } + .ui-searchbar-wrap .ui-searchbar-cancel { + color: #00a5e0; + font-size: 16px; + padding: 4px 8px; } + .ui-searchbar-wrap .ui-searchbar-input, .ui-searchbar-wrap button, .ui-searchbar-wrap .ui-icon-close { + display: none; } + .ui-searchbar-wrap.focus { + -webkit-box-pack: start; } + .ui-searchbar-wrap.focus .ui-searchbar-input, .ui-searchbar-wrap.focus button, .ui-searchbar-wrap.focus .ui-icon-close { + display: block; } + .ui-searchbar-wrap.focus .ui-searchbar-text { + display: none; } + +.ui-searchbar { + border-radius: 5px; + margin: 0 10px; + background: #fff; + height: 30px; + line-height: 30px; + position: relative; + padding-left: 4px; + -webkit-box-flex: 1; + display: -webkit-box; + -webkit-box-pack: center; + -webkit-box-align: center; + color: #bbb; + font-size: 14px; + width: 100%; } + .ui-searchbar input { + -webkit-appearance: none; + border: none; + background: none; + color: #000; + width: 100%; + padding: 4px 0; } + .ui-searchbar .ui-icon-search { + line-height: 30px; } + .ui-searchbar .ui-icon-close { + line-height: 30px; } + +.ui-searchbar-input { + -webkit-box-flex: 1; } + +@media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-searchbar.ui-border-radius:before { + border-radius: 10px; } } +/** + * 轮播组件 + */ +.ui-slider { + width: 100%; + overflow: hidden; + position: relative; + padding-top: 31.25%; } + +.ui-slider-content { + display: -webkit-box; + position: absolute; + left: 0; + top: 0; + height: 100%; } + +.ui-slider-content > li { + -webkit-box-flex: 1; + width: 100%; + height: 100%; } + +.ui-slider-content > li img { + display: block; + width: 100%; } + +.ui-slider-content > li span { + display: block; + width: 100%; + height: 100%; + background-repeat: no-repeat; + -webkit-background-size: 100% 100%; } + +.ui-slider-content > li.active { + opacity: .5; } + +.ui-slider-indicators { + position: absolute; + display: -webkit-box; + -webkit-box-pack: end; + width: 100%; + bottom: 10px; + right: 4px; + font-size: 0; } + +.ui-slider-indicators li { + display: block; + text-indent: 100%; + white-space: nowrap; + overflow: hidden; + font-size: 0; + width: 7px; + height: 7px; + background-color: rgba(0, 0, 0, 0.3); + border-radius: 10px; + margin-right: 6px; + -webkit-box-sizing: border-box; + background-clip: padding-box; + position: relative; } + +.ui-slider-indicators li.current:before { + content: ''; + position: absolute; + background-color: #fff; + left: 1px; + top: 1px; + width: 5px; + height: 5px; + border-radius: 10px; + -webkit-box-sizing: border-box; + background-clip: padding-box; } + +.ui-slider-indicators-center { + -webkit-box-pack: center; + right: 0; } + +.ui-panel { + overflow: hidden; + margin-bottom: 10px; } + .ui-panel .ui-grid-halve, .ui-panel .ui-grid-trisect { + padding-top: 0; } + .ui-panel h1, .ui-panel h2, .ui-panel h3 { + padding-left: 15px; + padding-right: 15px; + line-height: 44px; + position: relative; + overflow: hidden; + display: -webkit-box; } + @media (max-width: 320px) { + .ui-panel h1, .ui-panel h2, .ui-panel h3 { + padding-left: 10px; + padding-right: 10px; } } + .ui-panel h1 span, .ui-panel h2 span, .ui-panel h3 span { + display: block; } + +.ui-panel-card, +.ui-panel-simple { + background-color: #fff; } + +.ui-panel-pure h2, +.ui-panel-pure h3 { + color: #777; } + +.ui-panel-simple { + margin-bottom: 0; } + +.ui-panel-subtitle { + font-size: 14px; + color: #777; + margin-left: 10px; } + +.ui-panel-title-tips { + font-size: 12px; + color: #777; + position: absolute; + right: 15px; } + @media (max-width: 320px) { + .ui-panel-title-tips { + right: 10px; } } + +.ui-arrowlink .ui-panel-title-tips { + right: 30px; } + @media (max-width: 320px) { + .ui-arrowlink .ui-panel-title-tips { + right: 25px; } } + +.ui-progress { + overflow: hidden; + width: 100%; + height: 2px; + font-size: 0px; + background-color: #e2e2e2; + box-sizing: border-box; } + +.ui-progress span { + display: block; + width: 0%; + background: #65d521; + height: 100%; + font-size: 0; } + +.ui-grid-trisect li .ui-progress, +.ui-grid-halve li .ui-progress { + position: absolute; + height: 13px; + bottom: 0px; + z-index: 9; + border: 5px solid rgba(248, 248, 248, 0.9); } + .ui-grid-trisect li .ui-progress span, + .ui-grid-halve li .ui-progress span { + border-radius: 3px; } + +/** + * 选项卡 + */ +.ui-tab { + width: 100%; + overflow: hidden; } + +.ui-tab-nav { + width: 100%; + background-color: #fff; + display: box; + display: -webkit-box; + font-size: 16px; + height: 45px; + box-sizing: border-box; } + +.ui-tab-content { + display: -webkit-box; } + +.ui-tab-content > li { + -webkit-box-flex: 1; + width: 100%; } + +.ui-tab-nav li { + height: 45px; + line-height: 45px; + min-width: 70px; + box-flex: 1; + -webkit-box-flex: 1; + text-align: center; + color: #777; + box-sizing: border-box; + border-bottom: 2px solid transparent; + width: 100%; } + +.ui-tab-nav li.current { + color: #00a5e0; + border-bottom: 2px #00a5e0 solid; } + +.ui-tab-nav li:active { + opacity: .8; } + +.ui-loading-wrap { + display: -webkit-box; + -webkit-box-pack: center; + -webkit-box-align: center; + text-align: center; + height: 40px; } + +.ui-loading { + width: 20px; + height: 20px; + display: block; + background: url(../img/loading_sprite.png); + -webkit-background-size: auto 20px; + -webkit-animation: am-rotate 1s steps(12) infinite; } + +.ui-loading-bright { + width: 37px; + height: 37px; + display: block; + background-image: url(../img/loading_sprite_white.png); + -webkit-background-size: auto 37px; + -webkit-animation: am-rotate2 1s steps(12) infinite; } + +.ui-loading-wrap .ui-loading { + margin: 10px; } + +.ui-loading-block { + position: fixed; + top: 0px; + left: 0px; + width: 100%; + height: 100%; + z-index: 9999; + display: -webkit-box; + -webkit-box-orient: horizontal; + -webkit-box-pack: center; + -webkit-box-align: center; + background: rgba(0, 0, 0, 0.4); + display: none; + background: transparent; } + .ui-loading-block .ui-loading-cnt { + width: 130px; + height: 110px; + display: -webkit-box; + -webkit-box-orient: vertical; + -webkit-box-align: center; + text-align: center; + background: rgba(0, 0, 0, 0.65); + border-radius: 6px; + color: #fff; + font-size: 16px; } + .ui-loading-block .ui-loading-bright { + margin: 18px 0 8px; } + +.ui-loading-block.show { + display: -webkit-box; + display: box; } + +@-webkit-keyframes am-rotate { + from { + background-position: 0 0; } + to { + background-position: -240px 0; } } +@-webkit-keyframes am-rotate2 { + from { + background-position: 0 0; } + to { + background-position: -444px 0; } } +.ui-poptips { + width: 100%; + position: fixed; + top: 0px; + left: 0px; + z-index: 999; + padding: 0px 10px; + box-sizing: border-box; } + +.ui-poptips-cnt { + background-color: rgba(0, 0, 0, 0.6); + line-height: 40px; + height: 40px; + color: #fff; + font-size: 16px; + text-align: center; + border-bottom-left-radius: 3px; + border-bottom-right-radius: 3px; + max-width: 100%; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; } + .ui-poptips-cnt i { + display: inline-block; + width: 32px; + height: 1px; + vertical-align: top; } + .ui-poptips-cnt i:before { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + margin-right: 2px; + margin-left: 4px; + color: #fff; + line-height: 40px; } + +.ui-poptips-info i:before { + content: ""; } + +.ui-poptips-success i:before { + content: ""; } + +.ui-poptips-warn i:before { + content: ""; } + +/** + * 弹窗类 + */ +.ui-dialog { + position: fixed; + top: 0px; + left: 0px; + width: 100%; + height: 100%; + z-index: 9999; + display: -webkit-box; + -webkit-box-orient: horizontal; + -webkit-box-pack: center; + -webkit-box-align: center; + background: rgba(0, 0, 0, 0.4); + display: none; } + +.ui-dialog.show { + display: -webkit-box; + display: box; } + +.ui-dialog-hd { + height: 48px; + line-height: 48px; + text-align: center; + position: relative; } + +.ui-dialog-cnt { + border-radius: 6px; + width: 270px; + -webkit-background-clip: padding-box; + background-clip: padding-box; + pointer-events: auto; + background-color: rgba(253, 253, 253, 0.95); + position: relative; + font-size: 16px; } + +.ui-dialog-bd { + min-height: 71px; + border-top-left-radius: 6px; + border-top-right-radius: 6px; + padding: 18px; + display: -webkit-box; + display: box; + -webkit-box-pack: center; + -webkit-box-align: center; + -webkit-box-orient: vertical; } + +.ui-dialog-bd > h4 { + margin-bottom: 4px; + width: 100%; + text-align: center; } + +.ui-dialog-bd > div, .ui-dialog-bd > ul { + width: 100%; } + +.ui-dialog-ft { + border-bottom-left-radius: 6px; + border-bottom-right-radius: 6px; + display: -webkit-box; + width: 100%; + box-sizing: border-box; + -webkit-box-align: center; + border-top: 1px solid #e0e0e0; + height: 42px; + line-height: 42px; } + +.ui-dialog-close:before { + font-family: "iconfont" !important; + font-size: 32px; + line-height: 44px; + font-style: normal; + -webkit-font-smoothing: antialiased; + -webkit-text-stroke-width: 0.2px; + display: block; + color: rgba(0, 0, 0, 0.5); + content: ""; + color: #828282; + display: block; + line-height: 32px; + position: absolute; + top: 3px; + right: 3px; } + +.ui-dialog-close:active { + opacity: 0.5; } + +.ui-dialog-ft button { + color: #00a5e0; + text-align: center; + border-right: 1px #e0e0e0 solid; + width: 100%; + line-height: 42px; + background: transparent; + display: block; + margin: 0 !important; + -webkit-box-flex: 1; } + .ui-dialog-ft button:active { + background-color: rgba(0, 0, 0, 0.1) !important; } + .ui-dialog-ft button:first-child { + border-bottom-left-radius: 6px; } + .ui-dialog-ft button:last-child { + border-right: 0; + border-bottom-right-radius: 6px; } + +@media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-dialog-ft { + position: relative; + border: 0; + background-position: left top; + background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + background-repeat: repeat-x; + -webkit-background-size: 100% 1px; } + + .ui-dialog-ft button { + border-right: 0; + background-position: right top; + background-image: -webkit-gradient(linear, left top, right top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + background-repeat: repeat-y; + -webkit-background-size: 1px 100%; } + .ui-dialog-ft button:last-child { + background: none; } } +.ui-selector header { + padding: 6px 10px; + color: #a6a6a6; + overflow: hidden; } + +.ui-selector header h3 { + float: left; } + +.ui-selector-content { + background: #fff; } + +.ui-selector-item p { + margin-left: 10px; + -webkit-box-flex: 1; + overflow: hidden; + white-space: nowrap; + text-overflow: ellipsis; } + +.ui-selector-item .ui-txt-info { + margin: 0 10px; + font-size: 12px; } + +.ui-selector-item .ui-list-link li:after { + display: none; } + +.ui-selector-item h3:before { + content: ''; + display: block; + width: 0; + height: 0; + border-left: 6px solid; + border-top: 5px solid transparent; + border-bottom: 5px solid transparent; + color: #a6a6a6; + position: absolute; + left: 25px; + top: 15px; + -webkit-transition: all 0.2s; } + +.ui-selector-item.active h3:before { + -webkit-transform: rotate(90deg); } + +.ui-selector-item.active h3 { + border: none; + background-image: none; } + +.ui-selector-item.active ul { + display: block; } + +.ui-selector-item ul { + display: none; } + +.ui-selector-item h3 { + display: -webkit-box; + font-size: 16px; + padding-left: 54px; + line-height: 44px; + height: 44px; + position: relative; } + +.ui-actionsheet { + position: fixed; + top: 0px; + left: 0px; + width: 100%; + height: 100%; + z-index: 9999; + opacity: 0; + pointer-events: none; + display: -webkit-box; + -webkit-box-orient: horizontal; + -webkit-box-pack: center; + -webkit-box-align: end; + background: rgba(0, 0, 0, 0.4); } + .ui-actionsheet.show { + pointer-events: inherit; + opacity: 1; } + .ui-actionsheet.show .ui-actionsheet-cnt { + -webkit-transform: translateY(0); + -webkit-transition-delay: 0.3s; } + +.ui-actionsheet-cnt { + font-size: 21px; + position: fixed; + bottom: 0; + padding: 0 8px; + width: 100%; + box-sizing: border-box; + text-align: center; + -webkit-transform: translateY(100%); + -webkit-transition-property: all; + -webkit-transition-timing-function: ease-out; + -webkit-transition-duration: 0.3s; } + +.ui-actionsheet button, .ui-actionsheet h4 { + background: rgba(255, 255, 255, 0.84); + display: block; + width: 100%; + color: #0079ff; + box-sizing: border-box; } + +.ui-actionsheet button { + line-height: 44px; + height: 44px; } + +.ui-actionsheet h4 { + line-height: 24px; + padding-left: 20px; + padding-right: 20px; + padding-top: 10px; + padding-bottom: 10px; + border-top-left-radius: 3px; + border-top-right-radius: 3px; } + +.ui-actionsheet button:not(:last-child) { + border-top: 1px #e0e0e0 solid; } + +.ui-actionsheet button:last-child { + margin: 8px 0; + border-radius: 3px; } + +.ui-actionsheet button:nth-last-child(2) { + border-bottom-left-radius: 3px; + border-bottom-right-radius: 3px; } + +.ui-actionsheet button:active { + opacity: 0.84; } + +.ui-actionsheet h4 { + font-size: 13px; + color: #8a8a8a; } + +.ui-actionsheet .ui-actionsheet-del { + color: #fd472b; } + +@media screen and (-webkit-min-device-pixel-ratio: 2) { + .ui-actionsheet button:not(:last-child) { + border: 0; + background-position: left top; + background-image: -webkit-gradient(linear, left bottom, left top, color-stop(0.5, transparent), color-stop(0.5, #e0e0e0), to(#e0e0e0)); + background-repeat: repeat-x; + -webkit-background-size: 100% 1px; } } + +/*# sourceMappingURL=frozen.css.map */ diff --git a/public/css/language-selector.css b/public/css/language-selector.css deleted file mode 100644 index 4433995..0000000 --- a/public/css/language-selector.css +++ /dev/null @@ -1,300 +0,0 @@ -/* IE5.5 hacks */ -* html #lang_sel, -* html #lang_sel_list { - width: 12em; -} -* html #lang_sel a, -* html #lang_sel_list a { - width: 149px; -} -* html #lang_sel a:visited, -* html #lang_sel_list a:visited { - width: 149px; -} -* html #lang_sel ul ul, -* html #lang_sel_list ul { - top: 18px; -} -* html #lang_sel ul ul a, -* html #lang_sel_list ul a { - width: 150px; -} -* html #lang_sel ul ul a:visited, -* html #lang_sel_list ul a:visited { - width: 150px; -} - -/* remove all the bullets, borders and padding from the default list styling */ -#lang_sel { - height: 32px; - position: relative; - font-family: verdana, arial, sans-serif; - display: inline-block; - /* style the table so that it takes no part in the layout - required for IE to work */ - /* style the top level hover */ -} -#lang_sel ul { - padding: 0 !important; - margin: 0 !important; - list-style-type: none !important; - /* hide the sub levels and give them a positon absolute so that they take up no room */ -} -#lang_sel ul li:hover ul, #lang_sel ul a:hover ul { - visibility: visible; -} -#lang_sel ul ul { - - visibility: hidden; - position: absolute; - height: 0; - top: 25px; - left: 0; - border-top: 1px solid #cdcdcd; -} -#lang_sel ul ul a { - background: #ffffff; - color: #444444; - height: auto; - line-height: 1em; - padding: 5px 10px; - border-width: 0 1px 1px 1px; -} -#lang_sel ul ul a:visited { - background: #ffffff; - color: #444444; - height: auto; - line-height: 1em; - padding: 5px 10px; - border-width: 0 1px 1px 1px; -} -#lang_sel li { - float: left; - width: 95px; - position: relative; - padding: 0 !important; - margin: 0 !important; - list-style-type: none !important; -} -#lang_sel li:before { - content: '' !important; -} -#lang_sel a { - display: block; - font-size: 11px; - text-decoration: none !important; - color: #444444; - border: 1px solid #cdcdcd; - background: #fff; - padding-left: 10px; - line-height: 24px; -} -#lang_sel a:visited { - display: block; - font-size: 11px; - text-decoration: none !important; - color: #444444; - border: 1px solid #cdcdcd; - background: #fff; - padding-left: 10px; - line-height: 24px; -} -#lang_sel a.lang_sel_sel { - background: url(../img/nav-arrow-down.png) #fff right no-repeat; - color: #444; -} -#lang_sel a.lang_sel_sel:hover { - text-decoration: none; - color: #000; -} -#lang_sel table { - position: absolute; - top: 0; - left: 0; - border-collapse: collapse; -} -#lang_sel a:hover, #lang_sel ul ul a:hover, #lang_sel :hover > a, #lang_sel ul ul :hover > a { - color: #000; - background: #eee; -} -#lang_sel img.iclflag { - width: 18px; - height: 12px; - position: relative; - top: 1px; - display:inline; - float:none; - vertical-align: middle; -} -#lang_sel.icl_rtl { - text-align: right; - direction: rtl; -} -#lang_sel.icl_rtl .lang_sel_sel { - padding-right: 14px; -} - -/* make the second level visible when hover on first level list OR link */ -#lang_sel_footer { - margin: 0; - padding: 7px; - text-align: center; - font: 11px Verdana, sans-serif; - min-height: 15px; - clear: both; - background-color: #fff; - border: 1px solid #cdcdcd; -} -#lang_sel_footer ul { - list-style: none; - margin: 0; - padding: 0; -} -#lang_sel_footer ul li { - display: inline; - margin: 0 1px 0 0; - padding: 0; - white-space: nowrap; - line-height: 25px; -} -#lang_sel_footer ul li img { - position: relative; - top: 1px; - width: 18px; - height: 12px; - -} -#lang_sel_footer ul li a { - text-decoration: none; - padding: 5px 10px; -} -#lang_sel_footer ul li a:visited { - text-decoration: none; - padding: 5px 10px; -} - -#wpml_credit_footer { - width: 100%; - margin: 10px 0; - padding: 0; - text-align: center; - font-size: 11px; -} - -/* remove all the bullets, borders and padding from the default list styling */ -#lang_sel_list { - height: 32px; - position: relative; - z-index: 99; - font-family: verdana, arial, sans-serif; - /* style the table so that it takes no ppart in the layout - required for IE to work */ -} -#lang_sel_list ul { - padding: 0 !important; - margin: 0 !important; - list-style-type: none !important; -} -#lang_sel_list ul li:hover ul, #lang_sel_list ul a:hover ul { - visibility: visible; -} -#lang_sel_list ul.lang_sel_list_vertical { - width: 149px; -} -#lang_sel_list ul a { - background: #ffffff; - color: #444444; - height: auto; - line-height: 1em; -} -#lang_sel_list li { - float: left; - position: relative; - padding: 0 !important; - margin: 0 !important; - list-style-type: none !important; -} -#lang_sel_list li:before { - content: '' !important; -} -#lang_sel_list a { - display: block; - font-size: 11px; - text-decoration: none !important; - color: #444444; - background: #fff; - line-height: 18px; - padding-left: 5px; -} -#lang_sel_list a:visited { - display: block; - font-size: 11px; - text-decoration: none !important; - color: #444444; - background: #fff; - line-height: 18px; - padding-left: 5px; -} -#lang_sel_list a.lang_sel_sel { - background-image: none; - color: #444; -} -#lang_sel_list a.lang_sel_sel:hover { - text-decoration: none; - color: #000; -} -#lang_sel_list.lang_sel_list_vertical { - width: 149px; - /* hide the sub levels and give them a positon absolute so that they take up no room */ -} -#lang_sel_list.lang_sel_list_vertical ul { - /*visibility:hidden;position:absolute;*/ - height: 0; - top: 19px; - left: 0; - border-top: 1px solid #cdcdcd; -} -#lang_sel_list.lang_sel_list_vertical ul a { - padding: 3px 10px; -} -#lang_sel_list.lang_sel_list_vertical li { - width: 149px; -} -#lang_sel_list.lang_sel_list_vertical a { - border: 1px solid #cdcdcd; - border-top-width: 0; - padding-left: 10px; -} -#lang_sel_list.lang_sel_list_vertical a:visited { - border: 1px solid #cdcdcd; - border-top-width: 0; - padding-left: 10px; -} -#lang_sel_list table { - position: absolute; - top: 0; - left: 0; - border-collapse: collapse; -} -#lang_sel_list img.iclflag { - width: 18px; - height: 12px; - position: relative; - top: 1px; - display:inline; -} - -/* style the second level links */ -#lang_sel_list_list ul a:visited { - background: #ffffff; - color: #444444; - height: auto; - line-height: 1em; - padding: 3px 10px; -} - -/* reset menu img definitions */ -.menu-item-language img.iclflag { - height: 12px !important; - width: 18px !important; - margin-bottom: 0 !important; - margin-right: 4px; -} diff --git a/public/css/lanrenzhijia.css b/public/css/lanrenzhijia.css deleted file mode 100644 index 9cc375f..0000000 --- a/public/css/lanrenzhijia.css +++ /dev/null @@ -1,218 +0,0 @@ -/* ֮ www.lanrenzhijia.com */ -body { - font-family:"microsoft Yahei"; - color:#666; - margin:0; -} -table, td { - font:12px/180% Arial, Helvetica, sans-serif, Verdana; - color:#666; -} -table { - border-collapse2:collapse2; - border-spacing:0; - empty-cells:show; -} -th, td { - border-collapse2:collapse2; -} -A:link { - text-decoration:none; - -} -A:visited { - text-decoration:none; - -} -A:hover { - text-decoration:none; - -} -img { - border:0; -} -div, p, img, ul, li, form, input, label, span, dl, dt, dd { - margin:0; - padding:0; - font-family:microsoft yahei, Helvetica, sans-serif; -} -ol, ul, li { - list-style-type:none; -} -.overh { - overflow:auto; - zoom:1; - overflow-x:hidden; - overflow-y:hidden; -} -html { - -webkit-text-size-adjust:none; -} -input[type="submit"]::-moz-focus-inner { -border:none; -padding:0; -} -a { -blr:expression(this.onFocus=this.blur()) -} /*for IE*/ -a { - outline:none; -} /*for Firefox*/ -h2 { - font-family:'Microsoft yahei'; - font-weight:normal; -} -.overz { - font-size:12px; - overflow:auto; - zoom:1; - overflow-x:hidden; - overflow-y:hidden; -} -.overz A{ color:#666666;} -.overz h2{margin:0; - padding:0; - font-family:microsoft yahei, Helvetica, sans-serif;} -.mn_12 { - margin-bottom:12px; -} -/* ֮ www.lanrenzhijia.com */ -.online_icon { - width:36px; - height:156px; - overflow:hidden; - font-family:''; -} -.online_icon a { - display:block; - width:36px; - height:156px; - background:url(../images/online_bg.png) no-repeat; - _background:url(../images/online_bg_ie6.png) no-repeat; -} -.online_windows { - width:144px; -} -.online_w_top { - background:url(../images/online_bg.png) no-repeat -36px 0; - height:10px; - _background:url(../images/online_bg_ie6.png) no-repeat -36px 0; - _margin-bottom:-7px; -} -.online_w_c { - background:url(../images/online_bg.png) repeat-y 0 -185px; - padding:0 5px; - _background:url(../images/online_bg_ie6.png) repeat-y 0 -185px -} -.online_w_bottom { - background:url(../images/online_bg.png) repeat-y -36px -35px; - height:29px; - _background:url(../images/online_bg_ie6.png) repeat-y -36px -35px; -} -.online_content { - background:url(../images/online_bg.png) no-repeat -147px -185px; - padding-top:11px; - _background:url(../images/online_bg_ie6.png) no-repeat -147px -185px; -} -.online_content a.qq_icon { - background:url(../images/online_bg.png) no-repeat -37px -130px; - width:121px; - height:25px; - display:block; - margin:0 auto; - text-indent:30px; - line-height:23px; - cursor:pointer; - _background:url(../images/online_bg_ie6.png) no-repeat -37px -130px; -} -.online_content a.qq_icon:hover { - background-position:-159px -130px; - color:#FFF; -} -.online_content a.ww_icon { - background:url(../images/w1.png) no-repeat; - width:121px; - height:25px; - display:block; - margin:0 auto; - text-indent:30px; - line-height:23px; - cursor:pointer; - _background:url(../images/w1.png) no-repeat; -} -.online_content a.ww_icon:hover { - background:url(../images/w2.png) no-repeat; - color:#FFF; -} -.online_bar h2 { - background:url(../images/online_bg.png) repeat-x 0 -156px; - height:29px; - line-height:27px; - font-size:12px; - color:#666; - text-align:left; - _background:url(../images/online_bg_ie6.png) repeat-x 0 -156px; -} -.online_bar h2 a { - display:block; - padding-left:14px; - margin-left:6px; - cursor:pointer; -} -.expand h2 a { - background:url(../images/online_bg.png) no-repeat -36px -69px; - _background:url(../images/online_bg_ie6.png) no-repeat -36px -69px; -} -.collapse2 h2 a { -color:#666666; - background:url(../images/online_bg.png) no-repeat -36px -96px; - _background:url(../images/online_bg_ie6.png) no-repeat -36px -96px; -} -.expand h2 a:hover, .collapse2 h2 a:hover { - text-decoration:none; - color:#c81d04; -} -.online_content { - text-align:center; - border-bottom:1px solid #d0d0d0; - margin-bottom:1px; -} -.online_content ul li { - height:24px; - line-height:24px; - margin-bottom:4px; - font-family:''; -} -.online_content ul li a:hover { - color:#c81d04; -} -/* ֮ www.lanrenzhijia.com */ -#online_qq_layer { - position:fixed; - right:0px; - top:150px; - _position:absolute; -} -* html, * html body { - _background-attachment:fixed; -} -* html #online_qq_layer { - _bottom:auto; -_top:expression(eval(document.documentElement.scrollTop + 150)); -} -#online_qq_tab { - float:left; - margin-top: 50px; -} -#onlineService { - float:left; - margin-left:-3px; - display:none; -} -#onlineType1, #onlineType2, #onlineType3, #onlineType4, #onlineType5, #onlineType6 { - display:none; -} -#onlineType1 { - display:block; -} -/* ֮ www.lanrenzhijia.com */ diff --git a/public/fonts/iconfont-full.ttf b/public/fonts/iconfont-full.ttf new file mode 100644 index 0000000000000000000000000000000000000000..859ec87bcdcb9b05a923c96b5cea548c7a8c649e GIT binary patch literal 13032 zcmeHti+dbbm1o_1>)BOZ{qE{+wOaj9cgxnJrEaNPwycNcM;yye!5V_u<*$%ZP!^gs`yQA+R1m zrTyLNk{q>$^M+ISd+vJYhw#$z#JSPZkA4dJ^Bp#?9_P=reGVYrv z_uX?y{B6hmxIc&Q)jRf2+_t%C7_Zvrar)@K+YU_$R|_Wup<@#F={s-Rw(_GlGQc&rsA79;=t+=R$>Ocq+&YPwPM8U%Em$ zx^vxjVeU7=Z-!XgVw>=O)+YP_kNMaI7UO3j?cDM2`H`%@6IS7l*GdW^Y6v)s{QfsX zi;Fl5i;EuO))a`0_y7M#g)A6brq6+MiXhYinLx1;$YqKDm*4xIK%ZOKnx#9zCQ9xT z2I({vgpl(^u~4lIkZ2Q05tAq;$#xJ04^qU3`$Dl$tI`|J$V8P)Lp;M65k;mds&e*> z9PtzRjA)pWUneB^x*AqQDoU@59!+D6QSl4kQm8kqzAi~r@&-W=f-=4MJe#J^3#!nJ z-ezTgG+p%0gcoM@k;RHTw9;Y@de7lbiTy75I3Jwrb>@k+lu z@q;-^D8UcKPIT7kF)HDwgfKgo`VbNtFYAR;j)vuIp{IL*gmOKV9vqPh73#DP1uQEQ z(}SC))9G=HpiXMs%34-H59;=;f6jk)X^aBKID|3AxkNaPc2}ih!AJNZhnq-rkW`mi zCV5>qzO=^BbxFEeH@<7op?c$A(+%TGYjr&LN;eyL;q-l}ZA)motnbX}w^-rSY9`4+ zii#bir@LB?M#3grqIED}F-g&M38RsySCKS@NRdQqgCwi+5?#9#3rM=ANX*K{9#TEB zDhBRp@ntjqV8`+T#sph1>&Vfc3mV3l6I4&_<}sCE!VWog z?6c?S-0Su`PR%;MXBX$#IGqN+8yt?*W!jM`88Qu4LzHktsqpxjGo<;VJP zT<|_yxRUcO&Bwv=fTXF4BvQ_M(@VwZ66dFuh%fweENelF6;+c0ocX$99AD<}zPGnK zhknRHWO0biGaa&968eSp!d78F_@C`yb-G}@iaF=D1U!#~p~opw=0>KcyHJ-C0y*JT zidng?fS5Dd&2^qe!UD^h7)pwk2WU@sheUoSc~nKFQhHfNF?C&2q4dNbWMagd%mo6B z`h%t@rSlC9`9NbZfm0yb)YR706rFha!Ofc=eED@0_D@dt?%8(T>Qa2@*r$rb&w1YRG@6z;lsD&*VmR?hrJ?|iQ_~&dE ze%>c!gesRalVB3deEy1X2wcBlqA<;vEJar2kYiY6r_)Y{OAvP|9GKg`f9_xA_V3&C zlx0o6v}@N(lh-`DtABFmr+hPpe&mR586W$YVO_kU-$V6Rr>0&#@K*=#4zS1xn+prc22K+u{zfNw=_T_r; zdW55n#d&d>jzbfKP=>+SWdw2h&D7Cr7RKqg-7tI;>I^N;v$-qk3^AvUeW}ju;#tP^ zIS3wSpeccHw2xRlm2$Nw&|RSO_7Euc%udgupi?6~_I%IC^z=v%N%xFk+``o244a`R z1;5aQ7M$sD+&3Hutz9;09gw+^BNHnpPMki0^O2E#r}pkW^*>JS9o+jQo#79*pO~09 zv7OgRJ1_R0+PCG&y@QUwtlN7XHi!EXuC+NXx;3u46-Px2RM>NL-M#Df96h=R&gx*_ zp3NO6X!__LJUjY>qiJ}Pj?H`e4xWJB{wLv!EJz;3Ox1*&gbB2ni$qN^r*zPMG;ESa zAdfx>n>fhL1+G$f6qZ|I*7_lKw35rpN&&aLDvSiLOZo{o=ak(Ag;xd>qY*NlCzxJ1 z7AhK%W=WIC8o8P3UZ1Hm(X%rssjw_TRfp!kT@y7p_8=LHI# z%eo?Sr!R)Q)2KJi)~jB>-z&0dRmc4+s;;ZAh;Un!Fn-T3QPv2W2_*{eSM;lO1t|Iv z@Zb^fz%TT`c8&|jITz~V;lrq6oERWD{U_Oy`O{2rzP`i*sZy?WbBE9hdklR|F;Ixs zIST%Qj|vncV%4oQDqD3sUBo1#AJsmtH}nzkMdYmVct$%ZfF=~Q%Gsp)FiBNGbTq%?(?L~607 z=6F~A6?ya`dsY2EoQC&uzL2=ccy!(r17Sjg4SrA9XDGTFRCGL5F-rh+m|48V?B-&L zJXv}PJtKpQuhMVR2L!`GYtgX6fpK>YRyo8GGAuWDZWf8cNqt38?3a`l@f;VS-?TqPM^NhON?6_W#HCX6pm!v@d6*9U}l z$j1_Rf&Z+-86d=N%w8iT2eZki2@~57tBhHr!t?LGOUB-P_jwmQ@4le=)e9>Ac|qsi zwU0X$en0PEYoKQ`bMduP>&iYvgu)ela2x~s$Mc4$FqyugU)F^;-8!g9&gjN#uNeSEZvbGwp$mizEzZ%Cu%n1QiK2nY zWIRne?XzhzO2^aoS?B6K^@ z-5oTf6qRDF2o10lD!^g&?|Sqv;jmDA$U61)715i$fhpf9$2TI(YDlRa9 zvdUJrsBpIS%yq6C-j?2c>~>{p^=f*`^|SEJ+{sS1Z{4(}yAa-W^7}9CB6CpI2DIS`#G>I; zSn_xkUwEN4uyXfRL!)GTixy4yU^ZqP-!ly?QxjGTBf|UOdAWmy=jwn+%8@+ev*_3t znaijt)@@H9T*;Js0(?xUnCAwDo1+X&d@h3+B7m!UGn^%KTr)LM6*2SavxYA+AMqJy zDFQr1Ry@ud9VN4)qYA3nM#wwo4J`^}I-0P@8zNM&XYeuphXCsoGK6L{WwtYD`u%3G z)A`VzQV`H{J$H%>)JMUeA06<3=_5gwc$QKoU2<42^s}OArq7U2^0AfRuEyoO1mV8JD zH&3m^DkvuNkpZ#R0YBM2AajmWPxJoI5>jao`bnxi-RngZ-+bVi4flV6Jhr{a20FBm z&kI-yoeOv>eV$+ zm6P$Dr-%R#K8Gsl&ZNM;24D#>D~Rs`FtvwTdHpId~H9!80r!m(S zH#gqC(cHPLaickT1A*xxX>I_?4U?3ql5Ut@pVvpW!di$#uG(kOd~XZstRmzYRpgcH zu8#Bvjd(*t928Vk_p9wEzF|ZF>{97;D$tdk&I}&dYtPq>qL-xi9vGArzZQvDRx}dg z{1GABZ?iEvCTtRJ6t)T5>v{<;;XmSoodEc1B&eMtwQ`LQ-h%CL05k%XV#W?Xu}nt>bIwGAD5-u%ny!OgTlj{@G{dGzK3Xr6_A`WSAaBtzCws;5*b{(6 zGMXm#ydrUGX*48z%z$PXvLSOCFsv$*4JvgL3sd+B7~O@FyxFkXSue)%og+u57SB0+ zY81M_BPegqs^xevi2(v~7GcWVphC&QaUfNd0?w-O02y$V#y-4gq~gyVyqW(7!W#~90L$x(c+9mCu>DH)Lr0_hGKD+JMnwY3d>3p>B&`TY|qiY z|3t`%gSTIsT66Zq!Hyf(CmNb3S9RaIu7&otQv#<*dynq%@7N)V>cJEJfewP~WU`#~ zw^v%$-P&yix{zY=WdZAlRZ zqGt6J0mlM7;LGrilF4uq0}Ur7%`nM@-j)Se2r!4HTYA%l#KL?mCrY2+_vVS`-n`>^ zU>7f~8-a7lFg{C$k;KuY&X(TZ7CY@2fJC7wiVxm-uKl^6-SIs6Z=9|CJ7Di)j*Lz^ z`Ej1(%<<^S=_r>3Cpecb0+%{^sY90l(v9lBNo|eunNlf3(>O0YmJH8_lf)lRE=<$W z1zgkVByCAHmom1WS0g7gCA>|B{mC#OM>0&N?3r*97;6Xk_i^~kh?8ks3)>>_q$+0` z%!&m+j~qXywF+77hF6bRD4o8V43H|2;fYwzP^2I+-w;qZT$yCU&IGWJ`Q()?3vaZn zP<$*DNJQv#xFHa-e=+VK^3P7Ire|FCAfmDVnGS7W9%bQuipDhJlUowBE7mIch-m-R z?^ji_@1g#Yk^YAoBO!a1jE5rjv01-=_N3-hn5257lVqrcNfPt;A1bX{QGQ4?N<8)ThDB|*kaoBwNSN2<7-S$saE#i9``7hn)`C((?8O^7?iTP5bGhXf0 z013%n)u)pjp+_{tY``_9X8$cQdb;g*CBMfPwSS=pgQhO!(n!R3e4a?$epNMOk;HwZ z*CK)>dF-DfmPIH9+;@yVfrzWdqXZY|W3u{Sb}s1^@;{*xf!13llA=~6TjMJsHHDi4 z)&g}AGNnj9IzGj<*wOnbHA?;_@X6~Qom_=gBeLVfuJ@;Q5pRp5RR;?-x# z9imCLrLWP}?tbD1&GP$qpP29*4IL*AzG1?P@ZT%xZNhTcscSKJ-1$J8cmU&G)jP^r z4V&t)zHSO?d@`Vo<(h_R=D8>UOI~3qk;7+}3X{S;_yQ(MM#hP!{n064_`0@pGY19lBQ-D< z5dnt)78aJ^!|L7VCINq7Hq0Q03Edo#QVt{vJc9+F4GfC$`FNPby&w{-^t-ajfjg67 zlo-e6gi7(|@bbI@7_1lyPX#e#@!Bh0^YX-~s(XBaO*d^FQ6xl^?0l(D^Lc{uioc$??YR|Hl@;BT`d-@UPmuR7R1`#}lJr0Xm{n-$jejV9!y_60 zqA&9Z>;yqhW0cO3d57;vz;mt_ks?@g_?Cu`9!}iyFqwZiGWOa2{?Cp@9lLVR;-}cB z=*!3}>98$a&g-jHBp~Gjc`APXop;Elciyr8jr7{*h)Q36$9~y)wD2`D`SLOQ>@hS0 z`*f)t1JUrMc33V@3E{Zd(l2ANFWa!nz2cWh%-yK!Z|#{(G}S}`WpMq(d- z7AwFjV%ygl8-auIlQ(YJ)!CPPR*nvoZ{M;OE9YysYzq{YMRzs!6fIw(xy@R2V{uLK z>dDEgJGYdA>9#8U^q5|3h~7RFDu#+JbZ{a<69tcS!wpKLDn%v+rD8sq53<#_M`zGTtj}fr*}&RIv8+Qc*rq#ioZ2xJ!IcUnW*q?-Wes6t|l0g{WSWcyjO1-Y366r~>TszFX6M zZH0Ic84hatO6!YXxNpcPPHYV3z>rrNz*a%)qUk0~oW$;ZTToMW*ZOUG9^T!(_-h+`jVfE9{-#Z~4TG-?RD zkrx?YJfEl_4XwyUp7Sx0U%@c@c?5+e#A3BWgps8{*rtet5l@zcqb7AWKS+^GPi8;@ z8=QO_285(Fb69}~NU$wSw|FV+nj8+sw4ADj6fCTGeb|B#Z1gt-n+H-_l8Kh8YKYAx znJ~>8h9Pap`r=JmOcK4xY-b|AJZ@Ru09Ar;YnIX2*wluK5g${Qc{}21zd_F0qoNs$ z6qA#@BMvV)`lvHlR8=Gc<;GOADKc-U7$@mQpGeXjsQ_a+iY)`>o4Q%5(GW?Z7{;2R z6m0i5$hszK-qsB3S>Xwn+LvcSu&G4qrE)Y`N@~4Tw$`FrB;be5mZ@P_jmr~he>`A# z>iM?Qg34NG3nIf3^gFWz1R|IlCpJWo?yNXDkwNGpzNvD=9iiv!A&y7Rp5&rMruq5g zSv>J2!}buz{bUX?0mnCp8iu&vN6Hdm0ip*U2jG30pJ8*)EnZ+T+6y1v#8;3dK>Ior z;ZccmCBv%K>0?8H8(%p%#_0>L=xKXAQ%a-J*>EylYT~_FnCEAT@WUSG4>M#IRn$^u zbd(bw9nF-8gGWpaJ*_{$OKxBJ+Uq1eMSg}o7(AZm(WR0rC{A#qbPxz4a1dm#Sc7K= z2<}njEJBz8>a1?d^pxpg^g(24bV;3D+jPyQ#?rQjOKoy-Eq`>luqPi62D^rbVXx4E#U>3;uT}a` zTWNisuN3pHk>^UKXm9U|7_VvQD>6n@&pMaAv7+2sI{b7VYsQ86>S4^^>BUDee|%ja z27Yl#0)`LdC7v=5@q*71{D$KVl$uqn(Np#m&j2hZg+yDy{;mC+d;^)mCWrZQ$JF(q z+qYX==qXfKs2)B{zr!!gdk@f0U>`&(@cNFO{*nE?J$GX9K?Lm!kl_u8C0nq!ZnHyu zX~j8O9&}=IBslo)FL)O0<8csJ#l0=3kiM7ecU8ROcl2#L&DRPZ+UiMowmyVQdj~|9 zir7$rphA;E4=vq7*Rkm5+=sl-X?{aDAa^m-kl*U@Y{j6a8uIpe)UUslG+ptAF5cGL zbRKv^OE+BpnD8y&_7d_PE3pc(2cwdaOzHptbfO~%9XjEV3_}M{32W~dNuE@2@L~re zxgy|z%$+a-lMW>pKzV*quk}O|We0-Uiv;rP`hL94% zb7JH_nI9k`{&;>a%R=d}zkH4AMZP({tkmJ}Dso+QcvS_jTEQ)3HL8w_fnUMUO-%`; zq)S|pIJ@{de6@xxgfjj0bD?l|EE3?L7Q5?1PFfJep(0Jhf=VSR(yf@GxTvld>9 z5t@kRso$K4#>t_|#Kw5s>1q|tZ()pm(5Mt!! z9G_R|qPzx#q9d=jqQ`Ju4$>bG;nZsv?Jz>Gi}DNWi-m5v#L)l;{}@p;qSU1Uu9JTV zt-Gula={VRC8_+$du3V*c|UoBuHW!UXZdCx%Quk9i$ZMw!xdkXLv_Jj64A4NAmXFm z5N{1DK~ucJ88miDqObgz^MPJwGl1W(uo#R({Xy)NRIacR4{yIcbp2FEdFnlu!4CEG z?jP~*++py=NVJWk;a6{t-RfKQYe5$|HR1b*ZUGo^O5_|Chs0^@@)8g$AdGi@_@=&( zSDfbe;lt>!)lhX<-KC1sp#V{lanfD`6ep9mn-4u_Sz1 z>~!88!TV!4cHkJpR^lz#E&XZKn`A!|Uc~(_99?)9L))FAD%^AV!Twd4z`Nt_aT?`0 z)azwGMP7Yg;Px9RJA3!b33PI<&8QuJb&jQ+<_gWHC$d=ci^V-*=CJ{9}2@AKl z*A)KlfP2l5;k)0x7E$MK-D?Rt{%!YK7Q%$>+<)giJGSq>Xa8NBQG8(Edfcyb?$ccz zo#~b7OBF6%ZQXI#-MjbS$!qkbFZ-h9UOZWLsh+SC8y4?G;$a6CYIdXCFWd!}Sik## zun!CN_4n&8d!Git=@2@FG>m8ZkGAl~THT6P?-K3?72e`f8-2L?<1|`?dtExq{wNL1 z#gZX&7@YI5`cGNJu;=L?s&W5SQVNr;3=gha8SB1YmQK^jQX z*?QGP(j-H&$on;uJSiX})k2m5f3%V|(vG|lpdjgjJXc6J=^<5YwCE)($V#}1Rmgk| zkU=s;R+C}n19$FTU+wI4%PzMpyJf{KyWO(KEvs%>bIV@0T;Z0h-Eyh@HSYadw_N9z z>+5BgOTWvd-{sQpa_M)u^t)X8T`v7DmwuN^zssfH<36yGyIlHRF8wZ-e%Ym8 zcIlU0`em1X*`;50>6cylWtV>0rC)aGmtFd0mwwr$Uv}x2UHWC0e#NC2H4es`xJ{6AOS6KDVc literal 0 HcmV?d00001 diff --git a/public/fonts/iconfont.ttf b/public/fonts/iconfont.ttf new file mode 100644 index 0000000000000000000000000000000000000000..fb9b421943c4565135a5427bdb5c802a0efc9ebc GIT binary patch literal 4524 zcmeHK|8G>s5#QO}_vP;0_pe}seLmZF0mB)eeRl-Ma3MgO+JpcJRcS(v3xUJlx23e%d52&dU(==67B9y2pm6~$b&%S$( zp(6bYy1I9>Gdpi*_A@)P`xr6C+^oa|ORU@2n(cXf4+QK4p5DH}t;5Xw&sP{D51y4f z_B_!4ueWZFGsf>^%=-Dx?OV6$k6n3&F(1ZRekTN`Tl@n2D)3D^2S@H-QSsJ*-wD2F z&rsji`s4G?gMSHpW^n8M!)!i#5&U1kC-!a~+&*{156>~?m$3Kz@X-E|hKMBPoYI=dBs3WQrQ)wdDi!5WrQ#+>laY?`|2NK(05;2?19Apq zgL@JdbyQCv**c2HBK-U1UtPRN z%P&4%{zSN3F8R1&2m|K%!yj`UO%nz`aj~kDh7P=Y+=v)L5=j9a!SOR9w(V)=5eeP{ z+iCDgJrc|2JN%@ph1%v@DZ`gjA)i$qP&TF+&^H8ht&TC}F6R?|)0 zFg1W8eifdSoB0ZH6g?2cFCG=l+RzdKua#XSN_}NB*iB0349p9 zkGh}}s*x_Y&j{6&!%F2s`8>TpS=9s9W0eWf%S*r-)plk-+j~mKeg@3gN_b-Y+vPt^ zO;OX-(T}*WJlcLuA-?I7<+0qnG*um3{DI^iOM5^=Nc7Er1^7T+z{W|~7>13Qjk&WD zU~aEci&imDT?hG$z49rwLo}CZXp$?`4KJ6m8PJCv%jM_iB;!b4!*ppu;BFb7XBXJ8 zFJ0Qv$aEI16vec#fOsqGVyoHRY!J97Gooq~V4H}vsvjb$Mc+baHPJazP_b=$(bCa?`-*9F)_FG)(u+*miA(PnCV?=TU7g$Q-XEz_c&)Bmc^m$ zL<@T|oky+9puVP4cI`p!HFUcGuRzVqub|}w1>XDW;luYfuPH2y-!HjNhF|MmulWrW zU=r)sIihtvGorO!hhIG$UszbvwB^T2rgPb|UgOZm0`FYsh@dZYh}@zFJ_^=bc~p$y zO!u<}mc#jx^bvxWRdGwB_^Vt(O+t7PB||s#kX=P|+hg0?Rw{6I-^9?+#GfaI1_z#s z$9JCEvE$UvJC5z>+S&gd|5I`6$Pp{h_Dkb1B=!e@!2ws^RQtLVoEeG-9U8NFy%beblb%DLxgqh8Epi z)0VCaZ29^YF0r%qp-YXO$?k#f?gJQX3e=_BYF2L9veFd}1p|I#i0(>uHs-papyG$y zMrB%-crSK83pWUqwFV|jZ`Y09akZECmTOmj2|C5fw3xU~rzmWl@~qBS<-DE0AxzqU z>}FNgD0E~SB{J0{3K#j2fyr4 z*vGUwEeh8JEW_#L(Ib7!`o_3e3x9LsX z^7?(2knaAFW}=jYObf~WenGl$gomI6PO2eY6jXwT+-9L*y6IR+w+vk!?=tKyL9Zm% znBG9ZD@Dn)z@IiP%RDV{JaH1>iw9L7odRK=a82qS!@AwV^^4)Qd=xkw1r7mZ)+W}= zUQkHb%U2s9o5xzQNFe>0&@@~F1oHA)AndnianRbcg^pCZJp&6yt}*IEzSap?iB*vW z&cM?^c0}XV>WmlKqwP7nLZ=aGc$4o`>BEl#A*n!fyAL)=-NbDR;6|E(7p>Hrxf|em zgtRE70M!8Gb%543&)|9W^{`u)g3S6bHwyl_e%<2_yO$W2WfUwk;?{}dx@6Rcg+_%r z^-XizszY?_Q>abre}<$Q1v?;i5K=Xt#sKd7WH6#`W1-rBJL2~kmKicE$W4R{7dgb) z9+!=CYMNgUxUeNOXuHIt0;&wRKUqt>YBoekgo z-B6br7H7d#yPGH7NTAXmtc_*Z5|&`g@Z4yI8_70d)_rV0tSE~!b9AD2 zV;eWIgN~gAH?)CR%g>R`555seBivZXBp12KA`f|yKYj{OkU|uu2t|=P z2lnn-lV7sLp=}P$I<(!P9S+SoH1E)YLzg=AW{2MD(3K9o&7rFty4s;@s1)return this.each(function(){t(this).bxSlider(n)}),this;var o={},r=this;e.el=this;var a=t(window).width(),l=t(window).height(),d=function(){o.settings=t.extend({},s,n),o.settings.slideWidth=parseInt(o.settings.slideWidth),o.children=r.children(o.settings.slideSelector),o.children.length1||o.settings.maxSlides>1,o.carousel&&(o.settings.preloadImages="all"),o.minThreshold=o.settings.minSlides*o.settings.slideWidth+(o.settings.minSlides-1)*o.settings.slideMargin,o.maxThreshold=o.settings.maxSlides*o.settings.slideWidth+(o.settings.maxSlides-1)*o.settings.slideMargin,o.working=!1,o.controls={},o.interval=null,o.animProp="vertical"==o.settings.mode?"top":"left",o.usingCSS=o.settings.useCSS&&"fade"!=o.settings.mode&&function(){var t=document.createElement("div"),e=["WebkitPerspective","MozPerspective","OPerspective","msPerspective"];for(var i in e)if(void 0!==t.style[e[i]])return o.cssPrefix=e[i].replace("Perspective","").toLowerCase(),o.animProp="-"+o.cssPrefix+"-transform",!0;return!1}(),"vertical"==o.settings.mode&&(o.settings.maxSlides=o.settings.minSlides),r.data("origStyle",r.attr("style")),r.children(o.settings.slideSelector).each(function(){t(this).data("origStyle",t(this).attr("style"))}),c()},c=function(){r.wrap('
'),o.viewport=r.parent(),o.loader=t('
'),o.viewport.prepend(o.loader),r.css({width:"horizontal"==o.settings.mode?100*o.children.length+215+"%":"auto",position:"relative"}),o.usingCSS&&o.settings.easing?r.css("-"+o.cssPrefix+"-transition-timing-function",o.settings.easing):o.settings.easing||(o.settings.easing="swing"),f(),o.viewport.css({width:"100%",overflow:"hidden",position:"relative"}),o.viewport.parent().css({maxWidth:p()}),o.settings.pager||o.viewport.parent().css({margin:"0 auto 0px"}),o.children.css({"float":"horizontal"==o.settings.mode?"left":"none",listStyle:"none",position:"relative"}),o.children.css("width",u()),"horizontal"==o.settings.mode&&o.settings.slideMargin>0&&o.children.css("marginRight",o.settings.slideMargin),"vertical"==o.settings.mode&&o.settings.slideMargin>0&&o.children.css("marginBottom",o.settings.slideMargin),"fade"==o.settings.mode&&(o.children.css({position:"absolute",zIndex:0,display:"none"}),o.children.eq(o.settings.startSlide).css({zIndex:o.settings.slideZIndex,display:"block"})),o.controls.el=t('
'),o.settings.captions&&P(),o.active.last=o.settings.startSlide==x()-1,o.settings.video&&r.fitVids();var e=o.children.eq(o.settings.startSlide);"all"==o.settings.preloadImages&&(e=o.children),o.settings.ticker?o.settings.pager=!1:(o.settings.pager&&T(),o.settings.controls&&C(),o.settings.auto&&o.settings.autoControls&&E(),(o.settings.controls||o.settings.autoControls||o.settings.pager)&&o.viewport.after(o.controls.el)),g(e,h)},g=function(e,i){var s=e.find("img, iframe").length;if(0==s)return i(),void 0;var n=0;e.find("img, iframe").each(function(){t(this).one("load",function(){++n==s&&i()}).each(function(){this.complete&&t(this).load()})})},h=function(){if(o.settings.infiniteLoop&&"fade"!=o.settings.mode&&!o.settings.ticker){var e="vertical"==o.settings.mode?o.settings.minSlides:o.settings.maxSlides,i=o.children.slice(0,e).clone().addClass("bx-clone"),s=o.children.slice(-e).clone().addClass("bx-clone");r.append(i).prepend(s)}o.loader.remove(),S(),"vertical"==o.settings.mode&&(o.settings.adaptiveHeight=!0),o.viewport.height(v()),r.redrawSlider(),o.settings.onSliderLoad(o.active.index),o.initialized=!0,o.settings.responsive&&t(window).bind("resize",Z),o.settings.auto&&o.settings.autoStart&&H(),o.settings.ticker&&L(),o.settings.pager&&q(o.settings.startSlide),o.settings.controls&&W(),o.settings.touchEnabled&&!o.settings.ticker&&O()},v=function(){var e=0,s=t();if("vertical"==o.settings.mode||o.settings.adaptiveHeight)if(o.carousel){var n=1==o.settings.moveSlides?o.active.index:o.active.index*m();for(s=o.children.eq(n),i=1;i<=o.settings.maxSlides-1;i++)s=n+i>=o.children.length?s.add(o.children.eq(i-1)):s.add(o.children.eq(n+i))}else s=o.children.eq(o.active.index);else s=o.children;return"vertical"==o.settings.mode?(s.each(function(){e+=t(this).outerHeight()}),o.settings.slideMargin>0&&(e+=o.settings.slideMargin*(o.settings.minSlides-1))):e=Math.max.apply(Math,s.map(function(){return t(this).outerHeight(!1)}).get()),e},p=function(){var t="100%";return o.settings.slideWidth>0&&(t="horizontal"==o.settings.mode?o.settings.maxSlides*o.settings.slideWidth+(o.settings.maxSlides-1)*o.settings.slideMargin:o.settings.slideWidth),t},u=function(){var t=o.settings.slideWidth,e=o.viewport.width();return 0==o.settings.slideWidth||o.settings.slideWidth>e&&!o.carousel||"vertical"==o.settings.mode?t=e:o.settings.maxSlides>1&&"horizontal"==o.settings.mode&&(e>o.maxThreshold||e0)if(o.viewport.width()o.maxThreshold)t=o.settings.maxSlides;else{var e=o.children.first().width();t=Math.floor(o.viewport.width()/e)}else"vertical"==o.settings.mode&&(t=o.settings.minSlides);return t},x=function(){var t=0;if(o.settings.moveSlides>0)if(o.settings.infiniteLoop)t=o.children.length/m();else for(var e=0,i=0;e0&&o.settings.moveSlides<=f()?o.settings.moveSlides:f()},S=function(){if(o.children.length>o.settings.maxSlides&&o.active.last&&!o.settings.infiniteLoop){if("horizontal"==o.settings.mode){var t=o.children.last(),e=t.position();b(-(e.left-(o.viewport.width()-t.width())),"reset",0)}else if("vertical"==o.settings.mode){var i=o.children.length-o.settings.minSlides,e=o.children.eq(i).position();b(-e.top,"reset",0)}}else{var e=o.children.eq(o.active.index*m()).position();o.active.index==x()-1&&(o.active.last=!0),void 0!=e&&("horizontal"==o.settings.mode?b(-e.left,"reset",0):"vertical"==o.settings.mode&&b(-e.top,"reset",0))}},b=function(t,e,i,s){if(o.usingCSS){var n="vertical"==o.settings.mode?"translate3d(0, "+t+"px, 0)":"translate3d("+t+"px, 0, 0)";r.css("-"+o.cssPrefix+"-transition-duration",i/1e3+"s"),"slide"==e?(r.css(o.animProp,n),r.bind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd",function(){r.unbind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd"),D()})):"reset"==e?r.css(o.animProp,n):"ticker"==e&&(r.css("-"+o.cssPrefix+"-transition-timing-function","linear"),r.css(o.animProp,n),r.bind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd",function(){r.unbind("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd"),b(s.resetValue,"reset",0),N()}))}else{var a={};a[o.animProp]=t,"slide"==e?r.animate(a,i,o.settings.easing,function(){D()}):"reset"==e?r.css(o.animProp,t):"ticker"==e&&r.animate(a,speed,"linear",function(){b(s.resetValue,"reset",0),N()})}},w=function(){for(var e="",i=x(),s=0;i>s;s++){var n="";o.settings.buildPager&&t.isFunction(o.settings.buildPager)?(n=o.settings.buildPager(s),o.pagerEl.addClass("bx-custom-pager")):(n=s+1,o.pagerEl.addClass("bx-default-pager")),e+='"}o.pagerEl.html(e)},T=function(){o.settings.pagerCustom?o.pagerEl=t(o.settings.pagerCustom):(o.pagerEl=t('
'),o.settings.pagerSelector?t(o.settings.pagerSelector).html(o.pagerEl):o.controls.el.addClass("bx-has-pager").append(o.pagerEl),w()),o.pagerEl.on("click","a",I)},C=function(){o.controls.next=t(''+o.settings.nextText+""),o.controls.prev=t(''+o.settings.prevText+""),o.controls.next.bind("click",y),o.controls.prev.bind("click",z),o.settings.nextSelector&&t(o.settings.nextSelector).append(o.controls.next),o.settings.prevSelector&&t(o.settings.prevSelector).append(o.controls.prev),o.settings.nextSelector||o.settings.prevSelector||(o.controls.directionEl=t('
'),o.controls.directionEl.append(o.controls.prev).append(o.controls.next),o.controls.el.addClass("bx-has-controls-direction").append(o.controls.directionEl))},E=function(){o.controls.start=t('"),o.controls.stop=t('"),o.controls.autoEl=t('
'),o.controls.autoEl.on("click",".bx-start",k),o.controls.autoEl.on("click",".bx-stop",M),o.settings.autoControlsCombine?o.controls.autoEl.append(o.controls.start):o.controls.autoEl.append(o.controls.start).append(o.controls.stop),o.settings.autoControlsSelector?t(o.settings.autoControlsSelector).html(o.controls.autoEl):o.controls.el.addClass("bx-has-controls-auto").append(o.controls.autoEl),A(o.settings.autoStart?"stop":"start")},P=function(){o.children.each(function(){var e=t(this).find("img:first").attr("title");void 0!=e&&(""+e).length&&t(this).append('
'+e+"
")})},y=function(t){o.settings.auto&&r.stopAuto(),r.goToNextSlide(),t.preventDefault()},z=function(t){o.settings.auto&&r.stopAuto(),r.goToPrevSlide(),t.preventDefault()},k=function(t){r.startAuto(),t.preventDefault()},M=function(t){r.stopAuto(),t.preventDefault()},I=function(e){o.settings.auto&&r.stopAuto();var i=t(e.currentTarget),s=parseInt(i.attr("data-slide-index"));s!=o.active.index&&r.goToSlide(s),e.preventDefault()},q=function(e){var i=o.children.length;return"short"==o.settings.pagerType?(o.settings.maxSlides>1&&(i=Math.ceil(o.children.length/o.settings.maxSlides)),o.pagerEl.html(e+1+o.settings.pagerShortSeparator+i),void 0):(o.pagerEl.find("a").removeClass("active"),o.pagerEl.each(function(i,s){t(s).find("a").eq(e).addClass("active")}),void 0)},D=function(){if(o.settings.infiniteLoop){var t="";0==o.active.index?t=o.children.eq(0).position():o.active.index==x()-1&&o.carousel?t=o.children.eq((x()-1)*m()).position():o.active.index==o.children.length-1&&(t=o.children.eq(o.children.length-1).position()),t&&("horizontal"==o.settings.mode?b(-t.left,"reset",0):"vertical"==o.settings.mode&&b(-t.top,"reset",0))}o.working=!1,o.settings.onSlideAfter(o.children.eq(o.active.index),o.oldIndex,o.active.index)},A=function(t){o.settings.autoControlsCombine?o.controls.autoEl.html(o.controls[t]):(o.controls.autoEl.find("a").removeClass("active"),o.controls.autoEl.find("a:not(.bx-"+t+")").addClass("active"))},W=function(){1==x()?(o.controls.prev.addClass("disabled"),o.controls.next.addClass("disabled")):!o.settings.infiniteLoop&&o.settings.hideControlOnEnd&&(0==o.active.index?(o.controls.prev.addClass("disabled"),o.controls.next.removeClass("disabled")):o.active.index==x()-1?(o.controls.next.addClass("disabled"),o.controls.prev.removeClass("disabled")):(o.controls.prev.removeClass("disabled"),o.controls.next.removeClass("disabled")))},H=function(){o.settings.autoDelay>0?setTimeout(r.startAuto,o.settings.autoDelay):r.startAuto(),o.settings.autoHover&&r.hover(function(){o.interval&&(r.stopAuto(!0),o.autoPaused=!0)},function(){o.autoPaused&&(r.startAuto(!0),o.autoPaused=null)})},L=function(){var e=0;if("next"==o.settings.autoDirection)r.append(o.children.clone().addClass("bx-clone"));else{r.prepend(o.children.clone().addClass("bx-clone"));var i=o.children.first().position();e="horizontal"==o.settings.mode?-i.left:-i.top}b(e,"reset",0),o.settings.pager=!1,o.settings.controls=!1,o.settings.autoControls=!1,o.settings.tickerHover&&!o.usingCSS&&o.viewport.hover(function(){r.stop()},function(){var e=0;o.children.each(function(){e+="horizontal"==o.settings.mode?t(this).outerWidth(!0):t(this).outerHeight(!0)});var i=o.settings.speed/e,s="horizontal"==o.settings.mode?"left":"top",n=i*(e-Math.abs(parseInt(r.css(s))));N(n)}),N()},N=function(t){speed=t?t:o.settings.speed;var e={left:0,top:0},i={left:0,top:0};"next"==o.settings.autoDirection?e=r.find(".bx-clone").first().position():i=o.children.first().position();var s="horizontal"==o.settings.mode?-e.left:-e.top,n="horizontal"==o.settings.mode?-i.left:-i.top,a={resetValue:n};b(s,"ticker",speed,a)},O=function(){o.touch={start:{x:0,y:0},end:{x:0,y:0}},o.viewport.bind("touchstart",X)},X=function(t){if(o.working)t.preventDefault();else{o.touch.originalPos=r.position();var e=t.originalEvent;o.touch.start.x=e.changedTouches[0].pageX,o.touch.start.y=e.changedTouches[0].pageY,o.viewport.bind("touchmove",Y),o.viewport.bind("touchend",V)}},Y=function(t){var e=t.originalEvent,i=Math.abs(e.changedTouches[0].pageX-o.touch.start.x),s=Math.abs(e.changedTouches[0].pageY-o.touch.start.y);if(3*i>s&&o.settings.preventDefaultSwipeX?t.preventDefault():3*s>i&&o.settings.preventDefaultSwipeY&&t.preventDefault(),"fade"!=o.settings.mode&&o.settings.oneToOneTouch){var n=0;if("horizontal"==o.settings.mode){var r=e.changedTouches[0].pageX-o.touch.start.x;n=o.touch.originalPos.left+r}else{var r=e.changedTouches[0].pageY-o.touch.start.y;n=o.touch.originalPos.top+r}b(n,"reset",0)}},V=function(t){o.viewport.unbind("touchmove",Y);var e=t.originalEvent,i=0;if(o.touch.end.x=e.changedTouches[0].pageX,o.touch.end.y=e.changedTouches[0].pageY,"fade"==o.settings.mode){var s=Math.abs(o.touch.start.x-o.touch.end.x);s>=o.settings.swipeThreshold&&(o.touch.start.x>o.touch.end.x?r.goToNextSlide():r.goToPrevSlide(),r.stopAuto())}else{var s=0;"horizontal"==o.settings.mode?(s=o.touch.end.x-o.touch.start.x,i=o.touch.originalPos.left):(s=o.touch.end.y-o.touch.start.y,i=o.touch.originalPos.top),!o.settings.infiniteLoop&&(0==o.active.index&&s>0||o.active.last&&0>s)?b(i,"reset",200):Math.abs(s)>=o.settings.swipeThreshold?(0>s?r.goToNextSlide():r.goToPrevSlide(),r.stopAuto()):b(i,"reset",200)}o.viewport.unbind("touchend",V)},Z=function(){var e=t(window).width(),i=t(window).height();(a!=e||l!=i)&&(a=e,l=i,r.redrawSlider(),o.settings.onSliderResize.call(r,o.active.index))};return r.goToSlide=function(e,i){if(!o.working&&o.active.index!=e)if(o.working=!0,o.oldIndex=o.active.index,o.active.index=0>e?x()-1:e>=x()?0:e,o.settings.onSlideBefore(o.children.eq(o.active.index),o.oldIndex,o.active.index),"next"==i?o.settings.onSlideNext(o.children.eq(o.active.index),o.oldIndex,o.active.index):"prev"==i&&o.settings.onSlidePrev(o.children.eq(o.active.index),o.oldIndex,o.active.index),o.active.last=o.active.index>=x()-1,o.settings.pager&&q(o.active.index),o.settings.controls&&W(),"fade"==o.settings.mode)o.settings.adaptiveHeight&&o.viewport.height()!=v()&&o.viewport.animate({height:v()},o.settings.adaptiveHeightSpeed),o.children.filter(":visible").fadeOut(o.settings.speed).css({zIndex:0}),o.children.eq(o.active.index).css("zIndex",o.settings.slideZIndex+1).fadeIn(o.settings.speed,function(){t(this).css("zIndex",o.settings.slideZIndex),D()});else{o.settings.adaptiveHeight&&o.viewport.height()!=v()&&o.viewport.animate({height:v()},o.settings.adaptiveHeightSpeed);var s=0,n={left:0,top:0};if(!o.settings.infiniteLoop&&o.carousel&&o.active.last)if("horizontal"==o.settings.mode){var a=o.children.eq(o.children.length-1);n=a.position(),s=o.viewport.width()-a.outerWidth()}else{var l=o.children.length-o.settings.minSlides;n=o.children.eq(l).position()}else if(o.carousel&&o.active.last&&"prev"==i){var d=1==o.settings.moveSlides?o.settings.maxSlides-m():(x()-1)*m()-(o.children.length-o.settings.maxSlides),a=r.children(".bx-clone").eq(d);n=a.position()}else if("next"==i&&0==o.active.index)n=r.find("> .bx-clone").eq(o.settings.maxSlides).position(),o.active.last=!1;else if(e>=0){var c=e*m();n=o.children.eq(c).position()}if("undefined"!=typeof n){var g="horizontal"==o.settings.mode?-(n.left-s):-n.top;b(g,"slide",o.settings.speed)}}},r.goToNextSlide=function(){if(o.settings.infiniteLoop||!o.active.last){var t=parseInt(o.active.index)+1;r.goToSlide(t,"next")}},r.goToPrevSlide=function(){if(o.settings.infiniteLoop||0!=o.active.index){var t=parseInt(o.active.index)-1;r.goToSlide(t,"prev")}},r.startAuto=function(t){o.interval||(o.interval=setInterval(function(){"next"==o.settings.autoDirection?r.goToNextSlide():r.goToPrevSlide()},o.settings.pause),o.settings.autoControls&&1!=t&&A("stop"))},r.stopAuto=function(t){o.interval&&(clearInterval(o.interval),o.interval=null,o.settings.autoControls&&1!=t&&A("start"))},r.getCurrentSlide=function(){return o.active.index},r.getCurrentSlideElement=function(){return o.children.eq(o.active.index)},r.getSlideCount=function(){return o.children.length},r.redrawSlider=function(){o.children.add(r.find(".bx-clone")).outerWidth(u()),o.viewport.css("height",v()),o.settings.ticker||S(),o.active.last&&(o.active.index=x()-1),o.active.index>=x()&&(o.active.last=!0),o.settings.pager&&!o.settings.pagerCustom&&(w(),q(o.active.index))},r.destroySlider=function(){o.initialized&&(o.initialized=!1,t(".bx-clone",this).remove(),o.children.each(function(){void 0!=t(this).data("origStyle")?t(this).attr("style",t(this).data("origStyle")):t(this).removeAttr("style")}),void 0!=t(this).data("origStyle")?this.attr("style",t(this).data("origStyle")):t(this).removeAttr("style"),t(this).unwrap().unwrap(),o.controls.el&&o.controls.el.remove(),o.controls.next&&o.controls.next.remove(),o.controls.prev&&o.controls.prev.remove(),o.pagerEl&&o.settings.controls&&o.pagerEl.remove(),t(".bx-caption",this).remove(),o.controls.autoEl&&o.controls.autoEl.remove(),clearInterval(o.interval),o.settings.responsive&&t(window).unbind("resize",Z))},r.reloadSlider=function(t){void 0!=t&&(n=t),r.destroySlider(),d()},d(),this}}(jQuery); \ No newline at end of file diff --git a/public/js/frozen.js b/public/js/frozen.js new file mode 100644 index 0000000..f9a0f48 --- /dev/null +++ b/public/js/frozen.js @@ -0,0 +1,1527 @@ +/** + * User: jeakeyliang + * Date: 14-08-22 + * Time: 下午9:20 + */ + + +;(function($){ + var data = {}, dataAttr = $.fn.data, camelize = $.camelCase, + exp = $.expando = 'Zepto' + (+new Date()), emptyArray = [] + + // Get value from node: + // 1. first try key as given, + // 2. then try camelized key, + // 3. fall back to reading "data-*" attribute. + function getData(node, name) { + var id = node[exp], store = id && data[id] + if (name === undefined) return store || setData(node) + else { + if (store) { + if (name in store) return store[name] + var camelName = camelize(name) + if (camelName in store) return store[camelName] + } + return dataAttr.call($(node), name) + } + } + + // Store value under camelized key on node + function setData(node, name, value) { + var id = node[exp] || (node[exp] = ++$.uuid), + store = data[id] || (data[id] = attributeData(node)) + if (name !== undefined) store[camelize(name)] = value + return store + } + + // Read all "data-*" attributes from a node + function attributeData(node) { + var store = {} + $.each(node.attributes || emptyArray, function(i, attr){ + if (attr.name.indexOf('data-') == 0) + store[camelize(attr.name.replace('data-', ''))] = + $.zepto.deserializeValue(attr.value) + }) + return store + } + + $.fn.data = function(name, value) { + return value === undefined ? + // set multiple values via object + $.isPlainObject(name) ? + this.each(function(i, node){ + $.each(name, function(key, value){ setData(node, key, value) }) + }) : + // get value from first element + (0 in this ? getData(this[0], name) : undefined) : + // set value on all elements + this.each(function(){ setData(this, name, value) }) + } + + $.fn.removeData = function(names) { + if (typeof names == 'string') names = names.split(/\s+/) + return this.each(function(){ + var id = this[exp], store = id && data[id] + if (store) $.each(names || store, function(key){ + delete store[names ? camelize(this) : key] + }) + }) + } + + // Generate extended `remove` and `empty` functions + ;['remove', 'empty'].forEach(function(methodName){ + var origFn = $.fn[methodName] + $.fn[methodName] = function() { + var elements = this.find('*') + if (methodName === 'remove') elements = elements.add(this) + elements.removeData() + return origFn.call(this) + } + }) +})(window.Zepto); + +!function ($) { + var _private = {}; + _private.cache = {}; + $.tpl = function (str, data, env) { + // 判断str参数,如str为script标签的id,则取该标签的innerHTML,再递归调用自身 + // 如str为HTML文本,则分析文本并构造渲染函数 + var fn = !/[^\w\-\.:]/.test(str) + ? _private.cache[str] = _private.cache[str] || this.get(document.getElementById(str).innerHTML) + : function (data, env) { + var i, variable = [], value = []; // variable数组存放变量名,对应data结构的成员变量;value数组存放各变量的值 + for (i in data) { + variable.push(i); + value.push(data[i]); + } + return (new Function(variable, fn.code)) + .apply(env || data, value); // 此处的new Function是由下面fn.code产生的渲染函数;执行后即返回渲染结果HTML + }; + + fn.code = fn.code || "var $parts=[]; $parts.push('" + + str + .replace(/\\/g, '\\\\') // 处理模板中的\转义 + .replace(/[\r\t\n]/g, " ") // 去掉换行符和tab符,将模板合并为一行 + .split("<%").join("\t") // 将模板左标签<%替换为tab,起到分割作用 + .replace(/(^|%>)[^\t]*/g, function(str) { return str.replace(/'/g, "\\'"); }) // 将模板中文本部分的单引号替换为\' + .replace(/\t=(.*?)%>/g, "',$1,'") // 将模板中<%= %>的直接数据引用(无逻辑代码)与两侧的文本用'和,隔开,同时去掉了左标签产生的tab符 + .split("\t").join("');") // 将tab符(上面替换左标签产生)替换为'); 由于上一步已经把<%=产生的tab符去掉,因此这里实际替换的只有逻辑代码的左标签 + .split("%>").join("$parts.push('") // 把剩下的右标签%>(逻辑代码的)替换为"$parts.push('" + + "'); return $parts.join('');"; // 最后得到的就是一段JS代码,保留模板中的逻辑,并依次把模板中的常量和变量压入$parts数组 + + return data ? fn(data, env) : fn; // 如果传入了数据,则直接返回渲染结果HTML文本,否则返回一个渲染函数 + }; + $.adaptObject = function (element, defaults, option,template,plugin,pluginName) { + var $this= element; + + if (typeof option != 'string'){ + + // 获得配置信息 + var context=$.extend({}, defaults, typeof option == 'object' && option); + + var isFromTpl=false; + // 如果传入script标签的选择器 + if($.isArray($this) && $this.length && $($this)[0].nodeName.toLowerCase()=="script"){ + // 根据模板获得对象并插入到body中 + $this=$($.tpl($this[0].innerHTML,context)).appendTo("body"); + isFromTpl=true; + } + // 如果传入模板字符串 + else if($.isArray($this) && $this.length && $this.selector== ""){ + // 根据模板获得对象并插入到body中 + $this=$($.tpl($this[0].outerHTML,context)).appendTo("body"); + isFromTpl=true; + } + // 如果通过$.dialog()的方式调用 + else if(!$.isArray($this)){ + // 根据模板获得对象并插入到body中 + $this=$($.tpl(template,context)).appendTo("body"); + isFromTpl=true; + } + + } + + return $this.each(function () { + + var el = $(this); + // 读取对象缓存 + + var data = el.data('fz.'+pluginName); + + + + if (!data) el.data('fz.'+pluginName, + (data = new plugin(this,$.extend({}, defaults, typeof option == 'object' && option),isFromTpl) + + )); + + if (typeof option == 'string') data[option](); + }) + } +}(window.Zepto); + + + +/** + * User: jeakeyliang + * Date: 14-08-22 + * Time: 下午9:20 + */ + +!function($){ + + // 默认模板 + var _dialogTpl='
'+ + '
'+ + '
'+ + '
'+ + '

<%=title%>

'+ + '
<%=content%>
'+ + '
'+ + '
'+ + '<% for (var i = 0; i < button.length; i++) { %>' + + '<% if (i == select) { %>' + + '' + + '<% } else { %>' + + '
' + + '<% } %>' + + '<% } %>' + + '
'+ + '
'+ + '
'; + // 默认参数 + var defaults={ + title:'', + content:'', + button:['确认'], + select:0, + allowScroll:false, + callback:function(){} + } + // 构造函数 + var Dialog = function (el,option,isFromTpl) { + + this.option=$.extend(defaults,option); + this.element=$(el); + this._isFromTpl=isFromTpl; + this.button=$(el).find('[data-role="button"]'); + this._bindEvent(); + this.toggle(); + } + Dialog.prototype={ + _bindEvent:function(){ + var self=this; + self.button.on("tap",function(){ + var index=$(self.button).index($(this)); + // self.option.callback("button",index); + var e=$.Event("dialog:action"); + e.index=index; + self.element.trigger(e); + self.hide.apply(self); + }); + }, + toggle:function(){ + if(this.element.hasClass("show")){ + this.hide(); + }else{ + this.show(); + } + }, + show:function(){ + var self=this; + // self.option.callback("show"); + self.element.trigger($.Event("dialog:show")); + self.element.addClass("show"); + this.option.allowScroll && self.element.on("touchmove" , _stopScroll); + + }, + hide :function () { + var self=this; + // self.option.callback("hide"); + self.element.trigger($.Event("dialog:hide")); + self.element.off("touchmove" , _stopScroll); + self.element.removeClass("show"); + + self._isFromTpl&&self.element.remove(); + } + } + // 禁止冒泡 + function _stopScroll(){ + return false; + } + function Plugin(option) { + + return $.adaptObject(this, defaults, option,_dialogTpl,Dialog,"dialog"); + } + $.fn.dialog=$.dialog= Plugin; +}(window.Zepto) + + + +/** + * User: jeakeyliang + * Date: 14-11-07 + * Time: 下午9:20 + */ + +!function($){ + + // 默认模板 + var _loadingTpl='
'+ + '
'+ + ''+ + '

<%=content%>

'+ + '
'+ + '
'; + + // 默认参数 + var defaults={ + content:'加载中...' + } + // 构造函数 + var Loading = function (el,option,isFromTpl) { + var self=this; + this.element=$(el); + this._isFromTpl=isFromTpl; + this.option=$.extend(defaults,option); + this.show(); + } + Loading.prototype={ + show:function(){ + var e=$.Event('loading:show'); + this.element.trigger(e); + this.element.show(); + + }, + hide :function () { + var e=$.Event('loading:hide'); + this.element.trigger(e); + this.element.remove(); + } + } + function Plugin(option) { + + return $.adaptObject(this, defaults, option,_loadingTpl,Loading,"loading"); + } + $.fn.loading=$.loading= Plugin; +}(window.Zepto) + + + +;(function ($) { + +var rAF = window.requestAnimationFrame || + window.webkitRequestAnimationFrame || + window.mozRequestAnimationFrame || + window.oRequestAnimationFrame || + window.msRequestAnimationFrame || + function (callback) { window.setTimeout(callback, 1000 / 60); }; + + +/* + * 工具类 + */ +var utils = (function () { + + var me = {}; + + var _elementStyle = document.createElement('div').style; + + var _vendor = (function () { + var vendors = ['t', 'webkitT', 'MozT', 'msT', 'OT'], + transform, + i = 0, + l = vendors.length; + + for ( ; i < l; i++ ) { + transform = vendors[i] + 'ransform'; + if ( transform in _elementStyle ) return vendors[i].substr(0, vendors[i].length-1); + } + return false; + })(); + + function _prefixStyle (style) { + if ( _vendor === false ) return false; + if ( _vendor === '' ) return style; + return _vendor + style.charAt(0).toUpperCase() + style.substr(1); + } + + + me.getTime = Date.now || function getTime () { return new Date().getTime(); }; + + + me.extend = function (target, obj) { + for ( var i in obj ) { + target[i] = obj[i]; + } + }; + + + me.addEvent = function (el, type, fn, capture) { + el.addEventListener(type, fn, !!capture); + }; + + + me.removeEvent = function (el, type, fn, capture) { + el.removeEventListener(type, fn, !!capture); + }; + + + me.prefixPointerEvent = function (pointerEvent) { + return window.MSPointerEvent ? + 'MSPointer' + pointerEvent.charAt(9).toUpperCase() + pointerEvent.substr(10): + pointerEvent; + }; + + + /** + * 根据一定时间内的滑动距离计算出最终停止距离和时间。 + * @param current:当前滑动位置 + * @param start:touchStart 时候记录的开始位置,但是在touchmove时候可能被重写 + * @param time:touchstart 到手指离开时候经历的时间,同样可能被touchmove重写 + * @param lowerMargin:可移动的最大距离,这个一般为计算得出 this.wrapperHeight - this.scrollerHeight + * @param wrapperSize:如果有边界距离的话就是可拖动,不然碰到0的时候便停止 + * @param deceleration:匀减速 + * @returns {{destination: number, duration: number}} + */ + me.momentum = function (current, start, time, lowerMargin, wrapperSize, deceleration) { + var distance = current - start, + speed = Math.abs(distance) / time, + destination, + duration; + + deceleration = deceleration === undefined ? 0.0006 : deceleration; + + destination = current + ( speed * speed ) / ( 2 * deceleration ) * ( distance < 0 ? -1 : 1 ); + duration = speed / deceleration; + + if ( destination < lowerMargin ) { + destination = wrapperSize ? lowerMargin - ( wrapperSize / 2.5 * ( speed / 8 ) ) : lowerMargin; + distance = Math.abs(destination - current); + duration = distance / speed; + } else if ( destination > 0 ) { + destination = wrapperSize ? wrapperSize / 2.5 * ( speed / 8 ) : 0; + distance = Math.abs(current) + destination; + duration = distance / speed; + } + + return { + destination: Math.round(destination), + duration: duration + }; + }; + + var _transform = _prefixStyle('transform'); + + me.extend(me, { + hasTransform: _transform !== false, + hasPerspective: _prefixStyle('perspective') in _elementStyle, + hasTouch: 'ontouchstart' in window, + hasPointer: window.PointerEvent || window.MSPointerEvent, // IE10 is prefixed + hasTransition: _prefixStyle('transition') in _elementStyle + }); + + // This should find all Android browsers lower than build 535.19 (both stock browser and webview) + me.isBadAndroid = /Android /.test(window.navigator.appVersion) && !(/Chrome\/\d/.test(window.navigator.appVersion)); + + me.extend(me.style = {}, { + transform: _transform, + transitionTimingFunction: _prefixStyle('transitionTimingFunction'), + transitionDuration: _prefixStyle('transitionDuration'), + transitionDelay: _prefixStyle('transitionDelay'), + transformOrigin: _prefixStyle('transformOrigin'), + transitionProperty: _prefixStyle('transitionProperty') + }); + + + me.offset = function (el) { + var left = -el.offsetLeft, + top = -el.offsetTop; + + while (el = el.offsetParent) { + left -= el.offsetLeft; + top -= el.offsetTop; + } + return { + left: left, + top: top + }; + }; + + + /* + * 配合 config 里面的 preventDefaultException 属性 + * 不对匹配到的 element 使用 e.preventDefault() + * 默认阻止所有事件的冒泡,包括 click 或 tap + */ + me.preventDefaultException = function (el, exceptions) { + for ( var i in exceptions ) { + if ( exceptions[i].test(el[i]) ) { + return true; + } + } + return false; + }; + + + me.extend(me.eventType = {}, { + touchstart: 1, + touchmove: 1, + touchend: 1, + + mousedown: 2, + mousemove: 2, + mouseup: 2, + + pointerdown: 3, + pointermove: 3, + pointerup: 3, + + MSPointerDown: 3, + MSPointerMove: 3, + MSPointerUp: 3 + }); + + + me.extend(me.ease = {}, { + quadratic: { + style: 'cubic-bezier(0.25, 0.46, 0.45, 0.94)', + fn: function (k) { + return k * ( 2 - k ); + } + }, + circular: { + style: 'cubic-bezier(0.1, 0.57, 0.1, 1)', // Not properly "circular" but this looks better, it should be (0.075, 0.82, 0.165, 1) + fn: function (k) { + return Math.sqrt( 1 - ( --k * k ) ); + } + }, + back: { + style: 'cubic-bezier(0.175, 0.885, 0.32, 1.275)', + fn: function (k) { + var b = 4; + return ( k = k - 1 ) * k * ( ( b + 1 ) * k + b ) + 1; + } + }, + bounce: { + style: '', + fn: function (k) { + if ( ( k /= 1 ) < ( 1 / 2.75 ) ) { + return 7.5625 * k * k; + } else if ( k < ( 2 / 2.75 ) ) { + return 7.5625 * ( k -= ( 1.5 / 2.75 ) ) * k + 0.75; + } else if ( k < ( 2.5 / 2.75 ) ) { + return 7.5625 * ( k -= ( 2.25 / 2.75 ) ) * k + 0.9375; + } else { + return 7.5625 * ( k -= ( 2.625 / 2.75 ) ) * k + 0.984375; + } + } + }, + elastic: { + style: '', + fn: function (k) { + var f = 0.22, + e = 0.4; + + if ( k === 0 ) { return 0; } + if ( k == 1 ) { return 1; } + + return ( e * Math.pow( 2, - 10 * k ) * Math.sin( ( k - f / 4 ) * ( 2 * Math.PI ) / f ) + 1 ); + } + } + }); + + me.tap = function (e, eventName) { + var ev = document.createEvent('Event'); + ev.initEvent(eventName, true, true); + ev.pageX = e.pageX; + ev.pageY = e.pageY; + e.target.dispatchEvent(ev); + }; + + me.click = function (e) { + var target = e.target, + ev; + if ( !(/(SELECT|INPUT|TEXTAREA)/i).test(target.tagName) ) { + ev = document.createEvent('MouseEvents'); + ev.initMouseEvent('click', true, true, e.view, 1, + target.screenX, target.screenY, target.clientX, target.clientY, + e.ctrlKey, e.altKey, e.shiftKey, e.metaKey, + 0, null); + + ev._constructed = true; + target.dispatchEvent(ev); + } + }; + + return me; +})(); + + + +/* + * 构造函数 + */ +function Scroll(el, options) { + + this.wrapper = typeof el == 'string' ? $(el)[0] : el; + + this.options = { + startX: 0, // 初始化 X 坐标 + startY: 0, // 初始化 Y 坐标 + scrollY: true, // 竖向滚动 + scrollX: false, // 默认非水平 + directionLockThreshold: 5, // 确定滚动方向的阈值 + momentum: true, // 是否开启惯性滚动 + + duration: 300, // transition 过渡时间 + + bounce: true, // 是否有反弹动画 + bounceTime: 600, // 反弹动画时间 + bounceEasing: '', // 反弹动画类型:'circular'(default), 'quadratic', 'back', 'bounce', 'elastic' + + preventDefault: true, // 是否阻止默认滚动事件(和冒泡有区别) + eventPassthrough: true, // 穿透,是否触发原生滑动(取值 true、false、vertical、horizental) + + freeScroll: false, // 任意方向的滚动。若 scrollX 和 scrollY 同时开启,则相当于 freeScroll + + bindToWrapper : true, // 事件是否绑定到 wrapper 元素上,否则大部分绑定到 window(若存在嵌套,则绑定在元素上最好) + resizePolling : 60, // resize 时候隔 60ms 就执行 refresh 方法重新获取位置信息(事件节流) + + disableMouse : false, // 是否禁用鼠标 + disableTouch : false, // 是否禁用touch事件 + disablePointer : false, // 是否禁用win系统的pointer事件 + + tap: true, // 是否模拟 tap 事件 + click: false, // 是否模拟点击事件(false 则使用原生click事件) + + preventDefaultException: { tagName: /^(INPUT|TEXTAREA|BUTTON|SELECT)$/ }, // 当遇到正则内的元素则不阻止冒泡 + + HWCompositing: true, // Hardware acceleration + useTransition: true, // Transition || requestAnimationFrame + useTransform: true // Translate || Left/Top + }; + + + for ( var i in options ) { + this.options[i] = options[i]; + } + + + // scroller + // ================================== + + if (!this.options.role && this.options.scrollX === false) { + this.options.eventPassthrough = 'horizontal'; // 竖直滚动的 scroller 不拦截横向原生滚动 + } + + // slide + // ================================== + + if (this.options.role === 'slider') { + + this.options.scrollX = true; + this.options.scrollY = false; + this.options.momentum = false; + + this.scroller = $('.ui-slider-content')[0]; + $(this.scroller.children[0]).addClass('current'); + + this.currentPage = 0; + this.count = this.scroller.children.length; + + this.scroller.style.width = this.count+"00%"; + + this.itemWidth = this.scroller.children[0].clientWidth; + this.scrollWidth = this.itemWidth * this.count; + + + + if (this.options.indicator) { + var temp = '
    '; + + for (var i=1; i<=this.count; i++) { + if (i===1) { + temp += '
  • '+i+'
  • '; + } + else { + temp += '
  • '+i+'
  • '; + } + } + temp += '
'; + $(this.wrapper).append(temp); + this.indicator = $('.ui-slider-indicators')[0]; + } + } + + + // tab + // ================================== + + else if (this.options.role === 'tab') { + + this.options.scrollX = true; + this.options.scrollY = false; + this.options.momentum = false; + + this.scroller = $('.ui-tab-content')[0]; + this.nav = $('.ui-tab-nav')[0]; + + $(this.scroller.children[0]).addClass('current'); + $(this.nav.children[0]).addClass('current'); + + this.currentPage = 0; + this.count = this.scroller.children.length; + + this.scroller.style.width = this.count+"00%"; + + this.itemWidth = this.scroller.children[0].clientWidth; + this.scrollWidth = this.itemWidth * this.count; + + + } + else { + this.scroller = this.wrapper.children[0]; + } + this.scrollerStyle = this.scroller.style; + + + this.translateZ = utils.hasPerspective && this.options.HWCompositing ? ' translateZ(0)' : ''; + this.options.useTransition = utils.hasTransition && this.options.useTransition; + this.options.useTransform = utils.hasTransform && this.options.useTransform; + this.options.eventPassthrough = this.options.eventPassthrough === true ? 'vertical' : this.options.eventPassthrough; + this.options.preventDefault = !this.options.eventPassthrough && this.options.preventDefault; + // If you want eventPassthrough I have to lock one of the axes + this.options.scrollX = this.options.eventPassthrough == 'horizontal' ? false : this.options.scrollX; + this.options.scrollY = this.options.eventPassthrough == 'vertical' ? false : this.options.scrollY; + // With eventPassthrough we also need lockDirection mechanism + this.options.freeScroll = this.options.freeScroll && !this.options.eventPassthrough; + this.options.directionLockThreshold = this.options.eventPassthrough ? 0 : this.options.directionLockThreshold; + this.options.bounceEasing = typeof this.options.bounceEasing == 'string' ? utils.ease[this.options.bounceEasing] || utils.ease.circular : this.options.bounceEasing; + this.options.resizePolling = this.options.resizePolling === undefined ? 60 : this.options.resizePolling; + + if (this.options.tap === true) { + this.options.tap = 'tap'; + } + if (this.options.useTransform === false) { + this.scroller.style.position = 'relative'; + } + + // Some defaults + this.x = 0; + this.y = 0; + this.directionX = 0; + this.directionY = 0; + this._events = {}; + + this._init(); // 绑定各种事件 + this.refresh(); + + this.scrollTo(this.options.startX, this.options.startY); + this.enable(); + + // 自动播放 + if (this.options.autoplay) { + var context = this; + this.options.interval = this.options.interval || 2000; + this.options.flag = setTimeout(function(){ + context._autoplay.apply(context) + }, context.options.interval); + } +} + + + +Scroll.prototype = { + + _init: function () { + this._initEvents(); + }, + + _initEvents: function (remove) { + var eventType = remove ? utils.removeEvent : utils.addEvent, + target = this.options.bindToWrapper ? this.wrapper : window; + + /* + * 给 addEventListener 传递 this + * 程序会自动找到 handleEvent 方法作为回调函数 + */ + eventType(window, 'orientationchange', this); + eventType(window, 'resize', this); + + if ( this.options.click ) { + eventType(this.wrapper, 'click', this, true); + } + + if ( !this.options.disableMouse ) { + eventType(this.wrapper, 'mousedown', this); + eventType(target, 'mousemove', this); + eventType(target, 'mousecancel', this); + eventType(target, 'mouseup', this); + } + + if ( utils.hasPointer && !this.options.disablePointer ) { + eventType(this.wrapper, utils.prefixPointerEvent('pointerdown'), this); + eventType(target, utils.prefixPointerEvent('pointermove'), this); + eventType(target, utils.prefixPointerEvent('pointercancel'), this); + eventType(target, utils.prefixPointerEvent('pointerup'), this); + } + + if ( utils.hasTouch && !this.options.disableTouch ) { + eventType(this.wrapper, 'touchstart', this); + eventType(target, 'touchmove', this); + eventType(target, 'touchcancel', this); + eventType(target, 'touchend', this); + } + + eventType(this.scroller, 'transitionend', this); + eventType(this.scroller, 'webkitTransitionEnd', this); + eventType(this.scroller, 'oTransitionEnd', this); + eventType(this.scroller, 'MSTransitionEnd', this); + + // tab + // ============================= + if (this.options.role === 'tab') { + eventType(this.nav, 'touchend', this); + eventType(this.nav, 'mouseup', this); + eventType(this.nav, 'pointerup', this); + } + }, + + + refresh: function () { + var rf = this.wrapper.offsetHeight; // Force reflow + + // http://jsfiddle.net/y8Y32/25/ + // clientWidth = content + padding + this.wrapperWidth = this.wrapper.clientWidth; + this.wrapperHeight = this.wrapper.clientHeight; + + + // 添加 wrapper 的 padding 值到 scroller 身上,更符合使用预期 + var matrix = window.getComputedStyle(this.wrapper, null); + var pt = matrix['padding-top'].replace(/[^-\d.]/g, ''), + pb = matrix['padding-bottom'].replace(/[^-\d.]/g, ''), + pl = matrix['padding-left'].replace(/[^-\d.]/g, ''), + pr = matrix['padding-right'].replace(/[^-\d.]/g, ''); + + var matrix2 = window.getComputedStyle(this.scroller, null); + var mt2 = matrix2['margin-top'].replace(/[^-\d.]/g, ''), + mb2 = matrix2['margin-bottom'].replace(/[^-\d.]/g, ''), + ml2 = matrix2['margin-left'].replace(/[^-\d.]/g, ''), + mr2 = matrix2['margin-right'].replace(/[^-\d.]/g, ''); + + + // offsetWidth = content + padding + border + this.scrollerWidth = this.scroller.offsetWidth+parseInt(pl)+parseInt(pr)+parseInt(ml2)+parseInt(mr2); + this.scrollerHeight = this.scroller.offsetHeight+parseInt(pt)+parseInt(pb)+parseInt(mt2)+parseInt(mb2); + + + // slide + // ================================== + if (this.options.role === 'slider' || this.options.role === 'tab') { + this.itemWidth = this.scroller.children[0].clientWidth; + this.scrollWidth = this.itemWidth * this.count; + this.scrollerWidth = this.scrollWidth; + } + + this.maxScrollX = this.wrapperWidth - this.scrollerWidth; + this.maxScrollY = this.wrapperHeight - this.scrollerHeight; + + this.hasHorizontalScroll = this.options.scrollX && this.maxScrollX < 0; + this.hasVerticalScroll = this.options.scrollY && this.maxScrollY < 0; + + if ( !this.hasHorizontalScroll ) { + this.maxScrollX = 0; + this.scrollerWidth = this.wrapperWidth; + } + + if ( !this.hasVerticalScroll ) { + this.maxScrollY = 0; + this.scrollerHeight = this.wrapperHeight; + } + + this.endTime = 0; + this.directionX = 0; + this.directionY = 0; + + this.wrapperOffset = utils.offset(this.wrapper); + this.resetPosition(); + }, + + + handleEvent: function (e) { + switch ( e.type ) { + case 'touchstart': + case 'pointerdown': + case 'MSPointerDown': + case 'mousedown': + this._start(e); + break; + case 'touchmove': + case 'pointermove': + case 'MSPointerMove': + case 'mousemove': + this._move(e); + break; + case 'touchend': + case 'pointerup': + case 'MSPointerUp': + case 'mouseup': + case 'touchcancel': + case 'pointercancel': + case 'MSPointerCancel': + case 'mousecancel': + this._end(e); + break; + case 'orientationchange': + case 'resize': + this._resize(); + break; + case 'transitionend': + case 'webkitTransitionEnd': + case 'oTransitionEnd': + case 'MSTransitionEnd': + this._transitionEnd(e); + break; + case 'wheel': + case 'DOMMouseScroll': + case 'mousewheel': + this._wheel(e); + break; + case 'keydown': + this._key(e); + break; + case 'click': + if ( !e._constructed ) { + e.preventDefault(); + e.stopPropagation(); + } + break; + } + }, + + + + _start: function (e) { + + if ( utils.eventType[e.type] != 1 ) { // 如果是鼠标点击,则只响应鼠标左键 + if ( e.button !== 0 ) { + return; + } + } + + if ( !this.enabled || (this.initiated && utils.eventType[e.type] !== this.initiated) ) { + return; + } + + // 如果 preventDefault === true 且 不是落后的安卓版本 且 不是需要过滤的 target 就阻止默认的行为 + if ( this.options.preventDefault && !utils.isBadAndroid && !utils.preventDefaultException(e.target, this.options.preventDefaultException) ) { + e.preventDefault(); + } + + var point = e.touches ? e.touches[0] : e, // 检验是触摸事件对象还是鼠标事件对象 + pos; + + this.initiated = utils.eventType[e.type]; // 初始化事件类型(1:触摸,2:鼠标,3:pointer) + this.moved = false; + this.distX = 0; + this.distY = 0; + this.directionX = 0; + this.directionY = 0; + this.directionLocked = 0; + + this._transitionTime(); + this.startTime = utils.getTime(); + + // 定住正在滑动的 scroller,slider/tab 不这么做 + if ( this.options.useTransition && this.isInTransition && this.options.role !== 'slider' && this.options.role !== 'tab') { + this.isInTransition = false; + pos = this.getComputedPosition(); + this._translate(Math.round(pos.x), Math.round(pos.y)); + } + // 场景:(没有使用 Transition 属性) + else if ( !this.options.useTransition && this.isAnimating ) { + this.isAnimating = false; + } + + this.startX = this.x; + this.startY = this.y; + this.absStartX = this.x; + this.absStartY = this.y; + this.pointX = point.pageX; + this.pointY = point.pageY; + + // throttle + // ====================== + if (this.options.autoplay) { + var context = this; + + clearTimeout(this.options.flag); + this.options.flag = setTimeout(function() { + context._autoplay.apply(context); + }, context.options.interval); + } + + event.stopPropagation(); + }, + + + + _move: function (e) { + + if ( !this.enabled || utils.eventType[e.type] !== this.initiated ) { // 如果事件类型和 touchstart 初始化的事件类型不一致,退出 + return; + } + if ( this.options.preventDefault ) { // 这么做才能确保 Android 下 touchend 能被正常触发(需测试) + e.preventDefault(); + } + var point = e.touches ? e.touches[0] : e, + deltaX = point.pageX - this.pointX, + deltaY = point.pageY - this.pointY, + timestamp = utils.getTime(), + newX, newY, + absDistX, absDistY; + + this.pointX = point.pageX; + this.pointY = point.pageY; + + this.distX += deltaX; + this.distY += deltaY; + absDistX = Math.abs(this.distX); + absDistY = Math.abs(this.distY); + + + // 如果在很长的时间内只移动了少于 10 像素的距离,那么不会触发惯性滚动 + if ( timestamp - this.endTime > 300 && (absDistX < 10 && absDistY < 10) ) { + return; + } + + // 屏蔽滚动方向的另外一个方向(可配置) + if ( !this.directionLocked && !this.options.freeScroll ) { + if ( absDistX > absDistY + this.options.directionLockThreshold ) { + this.directionLocked = 'h'; // lock horizontally + } else if ( absDistY >= absDistX + this.options.directionLockThreshold ) { + this.directionLocked = 'v'; // lock vertically + } else { + this.directionLocked = 'n'; // no lock + } + } + if ( this.directionLocked == 'h' ) { + // slider/tab 外层高度自适应 + if (this.options.role === 'tab') { + $(this.scroller).children('li').height('auto'); + } + if ( this.options.eventPassthrough == 'vertical' ) { + e.preventDefault(); + } else if ( this.options.eventPassthrough == 'horizontal' ) { + this.initiated = false; + return; + } + deltaY = 0; // 不断重置垂直偏移量为 0 + } + else if ( this.directionLocked == 'v' ) { + if ( this.options.eventPassthrough == 'horizontal' ) { + e.preventDefault(); + } else if ( this.options.eventPassthrough == 'vertical' ) { + this.initiated = false; + return; + } + deltaX = 0; // 不断重置水平偏移量为 0 + } + + deltaX = this.hasHorizontalScroll ? deltaX : 0; + deltaY = this.hasVerticalScroll ? deltaY : 0; + + newX = this.x + deltaX; + newY = this.y + deltaY; + + // Slow down if outside of the boundaries + if ( newX > 0 || newX < this.maxScrollX ) { + newX = this.options.bounce ? this.x + deltaX / 3 : newX > 0 ? 0 : this.maxScrollX; + } + if ( newY > 0 || newY < this.maxScrollY ) { + newY = this.options.bounce ? this.y + deltaY / 3 : newY > 0 ? 0 : this.maxScrollY; + } + + this.directionX = deltaX > 0 ? -1 : deltaX < 0 ? 1 : 0; + this.directionY = deltaY > 0 ? -1 : deltaY < 0 ? 1 : 0; + + this.moved = true; // 滚动开始 + this._translate(newX, newY); + + if ( timestamp - this.startTime > 300 ) { // 每 300 毫秒重置一次初始值 + this.startTime = timestamp; + this.startX = this.x; + this.startY = this.y; + } + }, + + + + _end: function (e) { + + if ( !this.enabled || utils.eventType[e.type] !== this.initiated ) { + return; + } + + if ( this.options.preventDefault && !utils.preventDefaultException(e.target, this.options.preventDefaultException) ) { + e.preventDefault(); + } + + var point = e.changedTouches ? e.changedTouches[0] : e, // 移开屏幕的那个触摸点,只会包含在 changedTouches 列表中,而不会包含在 touches 或 targetTouches 列表中 + momentumX, + momentumY, + duration = utils.getTime() - this.startTime, + newX = Math.round(this.x), + newY = Math.round(this.y), + distanceX = Math.abs(newX - this.startX), + distanceY = Math.abs(newY - this.startY), + time = 0, + easing = ''; + + this.isInTransition = 0; + this.initiated = 0; + this.endTime = utils.getTime(); + + + if ( this.resetPosition(this.options.bounceTime) ) { // reset if we are outside of the boundaries + if (this.options.role === 'tab') { + $(this.scroller.children[this.currentPage]).siblings('li').height(0); + } + return; + } + + this.scrollTo(newX, newY); // ensures that the last position is rounded + + if (!this.moved) { // we scrolled less than 10 pixels + if (this.options.tap && utils.eventType[e.type] === 1) { + utils.tap(e, this.options.tap); + } + if ( this.options.click) { + utils.click(e); + } + } + + // 300ms 内的滑动要启动惯性滚动 + if ( this.options.momentum && duration < 300 ) { + momentumX = this.hasHorizontalScroll ? utils.momentum(this.x, this.startX, duration, this.maxScrollX, this.options.bounce ? this.wrapperWidth : 0, this.options.deceleration) : { destination: newX, duration: 0 }; + momentumY = this.hasVerticalScroll ? utils.momentum(this.y, this.startY, duration, this.maxScrollY, this.options.bounce ? this.wrapperHeight : 0, this.options.deceleration) : { destination: newY, duration: 0 }; + newX = momentumX.destination; + newY = momentumY.destination; + time = Math.max(momentumX.duration, momentumY.duration); + this.isInTransition = 1; + } + + if ( newX != this.x || newY != this.y ) { + // change easing function when scroller goes out of the boundaries + if ( newX > 0 || newX < this.maxScrollX || newY > 0 || newY < this.maxScrollY ) { + easing = utils.ease.quadratic; + } + this.scrollTo(newX, newY, time, easing); + return; + } + + + // tab + // ========================== + if (this.options.role === 'tab' && $(event.target).closest('ul').hasClass('ui-tab-nav')) { + $(this.nav).children().removeClass('current'); + $(event.target).addClass('current'); + var tempCurrentPage = this.currentPage; + this.currentPage = $(event.target).index(); + + $(this.scroller).children().height('auto'); // tab 外层高度自适应 + this._execEvent('beforeScrollStart', tempCurrentPage, this.currentPage); + } + + + + // slider & tab + // ============================== + if (this.options.role === 'slider' || this.options.role === 'tab') { + + if (distanceX < 30) { + this.scrollTo(-this.itemWidth*this.currentPage, 0, this.options.bounceTime, this.options.bounceEasing); + } + else if (newX-this.startX<0) { // 向前 + this._execEvent('beforeScrollStart', this.currentPage, this.currentPage+1); + this.scrollTo(-this.itemWidth*++this.currentPage, 0, this.options.bounceTime, this.options.bounceEasing); + } + else if (newX-this.startX>=0) { // 向后 + this._execEvent('beforeScrollStart', this.currentPage, this.currentPage-1); + this.scrollTo(-this.itemWidth*--this.currentPage, 0, this.options.bounceTime, this.options.bounceEasing); + } + + // tab 外层高度自适应 + if (this.options.role === 'tab') { + $(this.scroller.children[this.currentPage]).siblings('li').height(0); + } + + if (this.indicator && distanceX >= 30) { + $(this.indicator).children().removeClass('current'); + $(this.indicator.children[this.currentPage]).addClass('current'); + } + else if (this.nav && distanceX >= 30) { + $(this.nav).children().removeClass('current'); + $(this.nav.children[this.currentPage]).addClass('current'); + } + + $(this.scroller).children().removeClass('current'); + $(this.scroller.children[this.currentPage]).addClass('current'); + } + }, + + + _resize: function () { + var that = this; + clearTimeout(this.resizeTimeout); + this.resizeTimeout = setTimeout(function () { + that.refresh(); + }, this.options.resizePolling); + }, + + + _transitionEnd: function (e) { + if ( e.target != this.scroller || !this.isInTransition ) { + return; + } + this._transitionTime(); + + if ( !this.resetPosition(this.options.bounceTime) ) { + this.isInTransition = false; + this._execEvent('scrollEnd', this.currentPage); + } + }, + + + destroy: function () { + this._initEvents(true); // 去除事件绑定 + }, + + + resetPosition: function (time) { + var x = this.x, + y = this.y; + + time = time || 0; + + if ( !this.hasHorizontalScroll || this.x > 0 ) { + x = 0; + } else if ( this.x < this.maxScrollX ) { + x = this.maxScrollX; + } + + if ( !this.hasVerticalScroll || this.y > 0 ) { + y = 0; + } else if ( this.y < this.maxScrollY ) { + y = this.maxScrollY; + } + + if ( x == this.x && y == this.y ) { + return false; + } + this.scrollTo(x, y, time, this.options.bounceEasing); + return true; + }, + + + + disable: function () { + this.enabled = false; + }, + + enable: function () { + this.enabled = true; + }, + + + + on: function (type, fn) { + if ( !this._events[type] ) { + this._events[type] = []; + } + this._events[type].push(fn); + }, + off: function (type, fn) { + if ( !this._events[type] ) { + return; + } + + var index = this._events[type].indexOf(fn); + + if ( index > -1 ) { + this._events[type].splice(index, 1); + } + }, + + + _execEvent: function (type) { + if ( !this._events[type] ) { + return; + } + var i = 0, + l = this._events[type].length; + + if ( !l ) { + return; + } + for ( ; i < l; i++ ) { + this._events[type][i].apply(this, [].slice.call(arguments, 1)); + } + }, + + + scrollTo: function (x, y, time, easing) { + easing = easing || utils.ease.circular; + + this.isInTransition = this.options.useTransition && time > 0; + + if ( !time || (this.options.useTransition && easing.style) ) { + + if (this.options.role === 'slider' || this.options.role === 'tab') { // 不添加判断会影响 left/top 的过渡 + time = this.options.duration; + this.scrollerStyle[utils.style.transitionProperty] = utils.style.transform; + } + this.scrollerStyle[utils.style.transitionTimingFunction] = easing.style; + this._transitionTime(time); + this._translate(x, y); + } else { + this._animate(x, y, time, easing.fn); + } + }, + + + scrollToElement: function (el, time, offsetX, offsetY, easing) { + el = el.nodeType ? el : this.scroller.querySelector(el); + + if ( !el ) { + return; + } + var pos = utils.offset(el); + pos.left -= this.wrapperOffset.left; + pos.top -= this.wrapperOffset.top; + + // if offsetX/Y are true we center the element to the screen + // 若 offsetX/Y 都是 true,则会滚动到元素在屏幕中间的位置 + if ( offsetX === true ) { + offsetX = Math.round(el.offsetWidth / 2 - this.wrapper.offsetWidth / 2); + } + if ( offsetY === true ) { + offsetY = Math.round(el.offsetHeight / 2 - this.wrapper.offsetHeight / 2); + } + pos.left -= offsetX || 0; + pos.top -= offsetY || 0; + pos.left = pos.left > 0 ? 0 : pos.left < this.maxScrollX ? this.maxScrollX : pos.left; + pos.top = pos.top > 0 ? 0 : pos.top < this.maxScrollY ? this.maxScrollY : pos.top; + + time = time === undefined || time === null || time === 'auto' ? Math.max(Math.abs(this.x-pos.left), Math.abs(this.y-pos.top)) : time; + + this.scrollTo(pos.left, pos.top, time, easing); + }, + + + _transitionTime: function (time) { + time = time || 0; + this.scrollerStyle[utils.style.transitionDuration] = time + 'ms'; + + if ( !time && utils.isBadAndroid ) { + this.scrollerStyle[utils.style.transitionDuration] = '0.001s'; + } + }, + + + _translate: function (x, y) { + if ( this.options.useTransform ) { + this.scrollerStyle[utils.style.transform] = 'translate(' + x + 'px,' + y + 'px)' + this.translateZ; + } else { + x = Math.round(x); + y = Math.round(y); + this.scrollerStyle.left = x + 'px'; + this.scrollerStyle.top = y + 'px'; + } + this.x = x; + this.y = y; + }, + + + getComputedPosition: function () { + var matrix = window.getComputedStyle(this.scroller, null), + x, y; + + if ( this.options.useTransform ) { + matrix = matrix[utils.style.transform].split(')')[0].split(', '); + x = +(matrix[12] || matrix[4]); + y = +(matrix[13] || matrix[5]); + } else { + x = +matrix.left.replace(/[^-\d.]/g, ''); + y = +matrix.top.replace(/[^-\d.]/g, ''); + } + + return { x: x, y: y }; + }, + + + _animate: function (destX, destY, duration, easingFn) { // 当浏览器不支持 transition 时提供的退化方案 requestAnimationFrame + var that = this, + startX = this.x, + startY = this.y, + startTime = utils.getTime(), + destTime = startTime + duration; + + function step () { + var now = utils.getTime(), + newX, newY, + easing; + + if ( now >= destTime ) { + that.isAnimating = false; + that._translate(destX, destY); + + if ( !that.resetPosition(that.options.bounceTime) ) { + that._execEvent('scrollEnd', this.currentPage); + } + return; + } + + now = ( now - startTime ) / duration; + easing = easingFn(now); + newX = ( destX - startX ) * easing + startX; + newY = ( destY - startY ) * easing + startY; + that._translate(newX, newY); + + if ( that.isAnimating ) { + rAF(step); + } + } + this.isAnimating = true; + step(); + }, + + + _autoplay: function() { + var self = this, + curPage = self.currentPage; + + self.currentPage = self.currentPage >= self.count-1 ? 0 : ++self.currentPage; + self._execEvent('beforeScrollStart', curPage, self.currentPage); // 对于自动播放的 slider/tab,这个时机就是 beforeScrollStart + + // tab 外层高度自适应 + if (this.options.role === 'tab') { + $(this.scroller).children().height('auto'); + document.body.scrollTop = 0; + } + self.scrollTo(-self.itemWidth*self.currentPage, 0, self.options.bounceTime, self.options.bounceEasing); + + if (self.indicator) { + $(self.indicator).children().removeClass('current'); + $(self.indicator.children[self.currentPage]).addClass('current'); + $(self.scroller).children().removeClass('current'); + $(self.scroller.children[self.currentPage]).addClass('current'); + } + else if (self.nav) { + $(self.nav).children().removeClass('current'); + $(self.nav.children[self.currentPage]).addClass('current'); + $(self.scroller).children().removeClass('current'); + $(self.scroller.children[self.currentPage]).addClass('current'); + } + + self.options.flag = setTimeout(function() { + self._autoplay.apply(self); + }, self.options.interval); + } + + +}; + +// Scroll.utils = utils; +window.fz = window.fz || {}; +window.frozen = window.frozen || {}; +window.fz.Scroll = window.frozen.Scroll = Scroll; + +/* + * 兼容 RequireJS 和 Sea.js + */ +if (typeof define === "function") { + define(function(require, exports, module) { + module.exports = Scroll; + }) +} + +})(window.Zepto); +/** + * User: jeakeyliang + * Date: 14-11-07 + * Time: 下午9:20 + */ + +!function($){ + + // 默认模板 + var _tipsTpl='
'+ + '
'+ + '<%=content%>'+ + '
'+ + '
'; + + // 默认参数 + var defaults={ + content:'', + stayTime:1000, + type:'info', + callback:function(){} + } + // 构造函数 + var Tips = function (el,option,isFromTpl) { + var self=this; + this.element=$(el); + this._isFromTpl=isFromTpl; + this.elementHeight=$(el).height(); + + this.option=$.extend(defaults,option); + $(el).css({ + "-webkit-transform":"translateY(-"+this.elementHeight+"px)" + }); + setTimeout(function(){ + $(el).css({ + "-webkit-transition":"all .5s" + }); + self.show(); + },20); + + } + Tips.prototype={ + show:function(){ + var self=this; + // self.option.callback("show"); + self.element.trigger($.Event("tips:show")); + this.element.css({ + "-webkit-transform":"translateY(0px)" + }); + if(self.option.stayTime>0){ + setTimeout(function(){ + self.hide(); + },self.option.stayTime) + } + }, + hide :function () { + var self=this; + self.element.trigger($.Event("tips:hide")); + this.element.css({ + "-webkit-transform":"translateY(-"+this.elementHeight+"px)" + }); + setTimeout(function(){ + self._isFromTpl&&self.element.remove(); + },500) + + + } + } + function Plugin(option) { + + return $.adaptObject(this, defaults, option,_tipsTpl,Tips,"tips"); + } + $.fn.tips=$.tips= Plugin; +}(window.Zepto) + + diff --git a/public/js/online.js b/public/js/online.js deleted file mode 100644 index 52705d4..0000000 --- a/public/js/online.js +++ /dev/null @@ -1,70 +0,0 @@ -$(function(){ - // cms客服浮动面板 - if($("#cmsFloatPanel")) - { - $("#cmsFloatPanel > .ctrolPanel > a.arrow").click(function(){$("html,body").animate({scrollTop :0}, 800);return false;}); - var objServicePanel = $("#cmsFloatPanel > .servicePanel"); - var objMessagePanel = $("#cmsFloatPanel > .messagePanel"); - var objQrcodePanel = $("#cmsFloatPanel > .qrcodePanel"); - var w_s = objServicePanel.outerWidth(); - var w_m = objMessagePanel.outerWidth(); - var w_q = objQrcodePanel.outerWidth(); - $("#cmsFloatPanel .ctrolPanel > a.service").bind({ - click : function(){return false;}, - mouseover : function(){ - objMessagePanel.stop().hide();objQrcodePanel.stop().hide(); - if(objServicePanel.css("display") == "none"){ - objServicePanel.css("width","0px").show(); - objServicePanel.animate({"width" : w_s + "px"},600); - } - return false; - } - }); - $(".servicePanel-inner > .serviceMsgPanel > .serviceMsgPanel-hd > a",objServicePanel).bind({ - click : function(){ - objServicePanel.animate({"width" : "0px"},600,function(){ - objServicePanel.hide(); - }); - return false; - } - }); - $("#cmsFloatPanel > .ctrolPanel > a.message").bind({ - click : function(){return false;}, - mouseover : function(){ - objServicePanel.stop().hide();objQrcodePanel.stop().hide(); - if(objMessagePanel.css("display") == "none"){ - objMessagePanel.css("width","0px").show(); - objMessagePanel.animate({"width" : w_m + "px"},600); - } - return false; - } - }); - $(".messagePanel-inner > .formPanel > .formPanel-bd > a",objMessagePanel).bind({ - click : function(){ - objMessagePanel.animate({"width" : "0px"},600,function(){ - objMessagePanel.stop().hide(); - }); - return false; - } - }); - $("#cmsFloatPanel > .ctrolPanel > a.qrcode").bind({ - click : function(){return false;}, - mouseover : function(){ - objServicePanel.stop().hide();objMessagePanel.stop().hide(); - if(objQrcodePanel.css("display") == "none"){ - objQrcodePanel.css("width","0px").show(); - objQrcodePanel.animate({"width" : w_q + "px"},600); - } - return false; - } - }); - $(".qrcodePanel-inner > .codePanel > .codePanel-hd > a",objQrcodePanel).bind({ - click : function(){ - objQrcodePanel.animate({"width" : "0px"},600,function(){ - objQrcodePanel.stop().hide(); - }); - return false; - } - }); - } -}); \ No newline at end of file diff --git a/public/js/zepto.min.js b/public/js/zepto.min.js new file mode 100644 index 0000000..648a44a --- /dev/null +++ b/public/js/zepto.min.js @@ -0,0 +1,1773 @@ +// Zepto.js +// (c) 2010-2015 Thomas Fuchs +// Zepto.js may be freely distributed under the MIT license. + +var Zepto = (function() { + var undefined, key, $, classList, emptyArray = [], concat = emptyArray.concat, filter = emptyArray.filter, slice = emptyArray.slice, + document = window.document, + elementDisplay = {}, classCache = {}, + cssNumber = { 'column-count': 1, 'columns': 1, 'font-weight': 1, 'line-height': 1,'opacity': 1, 'z-index': 1, 'zoom': 1 }, + fragmentRE = /^\s*<(\w+|!)[^>]*>/, + singleTagRE = /^<(\w+)\s*\/?>(?:<\/\1>|)$/, + tagExpanderRE = /<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig, + rootNodeRE = /^(?:body|html)$/i, + capitalRE = /([A-Z])/g, + + // special attributes that should be get/set via method calls + methodAttributes = ['val', 'css', 'html', 'text', 'data', 'width', 'height', 'offset'], + + adjacencyOperators = [ 'after', 'prepend', 'before', 'append' ], + table = document.createElement('table'), + tableRow = document.createElement('tr'), + containers = { + 'tr': document.createElement('tbody'), + 'tbody': table, 'thead': table, 'tfoot': table, + 'td': tableRow, 'th': tableRow, + '*': document.createElement('div') + }, + readyRE = /complete|loaded|interactive/, + simpleSelectorRE = /^[\w-]*$/, + class2type = {}, + toString = class2type.toString, + zepto = {}, + camelize, uniq, + tempParent = document.createElement('div'), + propMap = { + 'tabindex': 'tabIndex', + 'readonly': 'readOnly', + 'for': 'htmlFor', + 'class': 'className', + 'maxlength': 'maxLength', + 'cellspacing': 'cellSpacing', + 'cellpadding': 'cellPadding', + 'rowspan': 'rowSpan', + 'colspan': 'colSpan', + 'usemap': 'useMap', + 'frameborder': 'frameBorder', + 'contenteditable': 'contentEditable' + }, + isArray = Array.isArray || + function(object){ return object instanceof Array } + + zepto.matches = function(element, selector) { + if (!selector || !element || element.nodeType !== 1) return false + var matchesSelector = element.webkitMatchesSelector || element.mozMatchesSelector || + element.oMatchesSelector || element.matchesSelector + if (matchesSelector) return matchesSelector.call(element, selector) + // fall back to performing a selector: + var match, parent = element.parentNode, temp = !parent + if (temp) (parent = tempParent).appendChild(element) + match = ~zepto.qsa(parent, selector).indexOf(element) + temp && tempParent.removeChild(element) + return match + } + + function type(obj) { + return obj == null ? String(obj) : + class2type[toString.call(obj)] || "object" + } + + function isFunction(value) { return type(value) == "function" } + function isWindow(obj) { return obj != null && obj == obj.window } + function isDocument(obj) { return obj != null && obj.nodeType == obj.DOCUMENT_NODE } + function isObject(obj) { return type(obj) == "object" } + function isPlainObject(obj) { + return isObject(obj) && !isWindow(obj) && Object.getPrototypeOf(obj) == Object.prototype + } + function likeArray(obj) { return typeof obj.length == 'number' } + + function compact(array) { return filter.call(array, function(item){ return item != null }) } + function flatten(array) { return array.length > 0 ? $.fn.concat.apply([], array) : array } + camelize = function(str){ return str.replace(/-+(.)?/g, function(match, chr){ return chr ? chr.toUpperCase() : '' }) } + function dasherize(str) { + return str.replace(/::/g, '/') + .replace(/([A-Z]+)([A-Z][a-z])/g, '$1_$2') + .replace(/([a-z\d])([A-Z])/g, '$1_$2') + .replace(/_/g, '-') + .toLowerCase() + } + uniq = function(array){ return filter.call(array, function(item, idx){ return array.indexOf(item) == idx }) } + + function classRE(name) { + return name in classCache ? + classCache[name] : (classCache[name] = new RegExp('(^|\\s)' + name + '(\\s|$)')) + } + + function maybeAddPx(name, value) { + return (typeof value == "number" && !cssNumber[dasherize(name)]) ? value + "px" : value + } + + function defaultDisplay(nodeName) { + var element, display + if (!elementDisplay[nodeName]) { + element = document.createElement(nodeName) + document.body.appendChild(element) + display = getComputedStyle(element, '').getPropertyValue("display") + element.parentNode.removeChild(element) + display == "none" && (display = "block") + elementDisplay[nodeName] = display + } + return elementDisplay[nodeName] + } + + function children(element) { + return 'children' in element ? + slice.call(element.children) : + $.map(element.childNodes, function(node){ if (node.nodeType == 1) return node }) + } + + function Z(dom, selector) { + var i, len = dom ? dom.length : 0 + for (i = 0; i < len; i++) this[i] = dom[i] + this.length = len + this.selector = selector || '' + } + + // `$.zepto.fragment` takes a html string and an optional tag name + // to generate DOM nodes nodes from the given html string. + // The generated DOM nodes are returned as an array. + // This function can be overriden in plugins for example to make + // it compatible with browsers that don't support the DOM fully. + zepto.fragment = function(html, name, properties) { + var dom, nodes, container + + // A special case optimization for a single tag + if (singleTagRE.test(html)) dom = $(document.createElement(RegExp.$1)) + + if (!dom) { + if (html.replace) html = html.replace(tagExpanderRE, "<$1>") + if (name === undefined) name = fragmentRE.test(html) && RegExp.$1 + if (!(name in containers)) name = '*' + + container = containers[name] + container.innerHTML = '' + html + dom = $.each(slice.call(container.childNodes), function(){ + container.removeChild(this) + }) + } + + if (isPlainObject(properties)) { + nodes = $(dom) + $.each(properties, function(key, value) { + if (methodAttributes.indexOf(key) > -1) nodes[key](value) + else nodes.attr(key, value) + }) + } + + return dom + } + + // `$.zepto.Z` swaps out the prototype of the given `dom` array + // of nodes with `$.fn` and thus supplying all the Zepto functions + // to the array. This method can be overriden in plugins. + zepto.Z = function(dom, selector) { + return new Z(dom, selector) + } + + // `$.zepto.isZ` should return `true` if the given object is a Zepto + // collection. This method can be overriden in plugins. + zepto.isZ = function(object) { + return object instanceof zepto.Z + } + + // `$.zepto.init` is Zepto's counterpart to jQuery's `$.fn.init` and + // takes a CSS selector and an optional context (and handles various + // special cases). + // This method can be overriden in plugins. + zepto.init = function(selector, context) { + var dom + // If nothing given, return an empty Zepto collection + if (!selector) return zepto.Z() + // Optimize for string selectors + else if (typeof selector == 'string') { + selector = selector.trim() + // If it's a html fragment, create nodes from it + // Note: In both Chrome 21 and Firefox 15, DOM error 12 + // is thrown if the fragment doesn't begin with < + if (selector[0] == '<' && fragmentRE.test(selector)) + dom = zepto.fragment(selector, RegExp.$1, context), selector = null + // If there's a context, create a collection on that context first, and select + // nodes from there + else if (context !== undefined) return $(context).find(selector) + // If it's a CSS selector, use it to select nodes. + else dom = zepto.qsa(document, selector) + } + // If a function is given, call it when the DOM is ready + else if (isFunction(selector)) return $(document).ready(selector) + // If a Zepto collection is given, just return it + else if (zepto.isZ(selector)) return selector + else { + // normalize array if an array of nodes is given + if (isArray(selector)) dom = compact(selector) + // Wrap DOM nodes. + else if (isObject(selector)) + dom = [selector], selector = null + // If it's a html fragment, create nodes from it + else if (fragmentRE.test(selector)) + dom = zepto.fragment(selector.trim(), RegExp.$1, context), selector = null + // If there's a context, create a collection on that context first, and select + // nodes from there + else if (context !== undefined) return $(context).find(selector) + // And last but no least, if it's a CSS selector, use it to select nodes. + else dom = zepto.qsa(document, selector) + } + // create a new Zepto collection from the nodes found + return zepto.Z(dom, selector) + } + + // `$` will be the base `Zepto` object. When calling this + // function just call `$.zepto.init, which makes the implementation + // details of selecting nodes and creating Zepto collections + // patchable in plugins. + $ = function(selector, context){ + return zepto.init(selector, context) + } + + function extend(target, source, deep) { + for (key in source) + if (deep && (isPlainObject(source[key]) || isArray(source[key]))) { + if (isPlainObject(source[key]) && !isPlainObject(target[key])) + target[key] = {} + if (isArray(source[key]) && !isArray(target[key])) + target[key] = [] + extend(target[key], source[key], deep) + } + else if (source[key] !== undefined) target[key] = source[key] + } + + // Copy all but undefined properties from one or more + // objects to the `target` object. + $.extend = function(target){ + var deep, args = slice.call(arguments, 1) + if (typeof target == 'boolean') { + deep = target + target = args.shift() + } + args.forEach(function(arg){ extend(target, arg, deep) }) + return target + } + + // `$.zepto.qsa` is Zepto's CSS selector implementation which + // uses `document.querySelectorAll` and optimizes for some special cases, like `#id`. + // This method can be overriden in plugins. + zepto.qsa = function(element, selector){ + var found, + maybeID = selector[0] == '#', + maybeClass = !maybeID && selector[0] == '.', + nameOnly = maybeID || maybeClass ? selector.slice(1) : selector, // Ensure that a 1 char tag name still gets checked + isSimple = simpleSelectorRE.test(nameOnly) + return (element.getElementById && isSimple && maybeID) ? // Safari DocumentFragment doesn't have getElementById + ( (found = element.getElementById(nameOnly)) ? [found] : [] ) : + (element.nodeType !== 1 && element.nodeType !== 9 && element.nodeType !== 11) ? [] : + slice.call( + isSimple && !maybeID && element.getElementsByClassName ? // DocumentFragment doesn't have getElementsByClassName/TagName + maybeClass ? element.getElementsByClassName(nameOnly) : // If it's simple, it could be a class + element.getElementsByTagName(selector) : // Or a tag + element.querySelectorAll(selector) // Or it's not simple, and we need to query all + ) + } + + function filtered(nodes, selector) { + return selector == null ? $(nodes) : $(nodes).filter(selector) + } + + $.contains = document.documentElement.contains ? + function(parent, node) { + return parent !== node && parent.contains(node) + } : + function(parent, node) { + while (node && (node = node.parentNode)) + if (node === parent) return true + return false + } + + function funcArg(context, arg, idx, payload) { + return isFunction(arg) ? arg.call(context, idx, payload) : arg + } + + function setAttribute(node, name, value) { + value == null ? node.removeAttribute(name) : node.setAttribute(name, value) + } + + // access className property while respecting SVGAnimatedString + function className(node, value){ + var klass = node.className || '', + svg = klass && klass.baseVal !== undefined + + if (value === undefined) return svg ? klass.baseVal : klass + svg ? (klass.baseVal = value) : (node.className = value) + } + + // "true" => true + // "false" => false + // "null" => null + // "42" => 42 + // "42.5" => 42.5 + // "08" => "08" + // JSON => parse if valid + // String => self + function deserializeValue(value) { + try { + return value ? + value == "true" || + ( value == "false" ? false : + value == "null" ? null : + +value + "" == value ? +value : + /^[\[\{]/.test(value) ? $.parseJSON(value) : + value ) + : value + } catch(e) { + return value + } + } + + $.type = type + $.isFunction = isFunction + $.isWindow = isWindow + $.isArray = isArray + $.isPlainObject = isPlainObject + + $.isEmptyObject = function(obj) { + var name + for (name in obj) return false + return true + } + + $.inArray = function(elem, array, i){ + return emptyArray.indexOf.call(array, elem, i) + } + + $.camelCase = camelize + $.trim = function(str) { + return str == null ? "" : String.prototype.trim.call(str) + } + + // plugin compatibility + $.uuid = 0 + $.support = { } + $.expr = { } + $.noop = function() {} + + $.map = function(elements, callback){ + var value, values = [], i, key + if (likeArray(elements)) + for (i = 0; i < elements.length; i++) { + value = callback(elements[i], i) + if (value != null) values.push(value) + } + else + for (key in elements) { + value = callback(elements[key], key) + if (value != null) values.push(value) + } + return flatten(values) + } + + $.each = function(elements, callback){ + var i, key + if (likeArray(elements)) { + for (i = 0; i < elements.length; i++) + if (callback.call(elements[i], i, elements[i]) === false) return elements + } else { + for (key in elements) + if (callback.call(elements[key], key, elements[key]) === false) return elements + } + + return elements + } + + $.grep = function(elements, callback){ + return filter.call(elements, callback) + } + + if (window.JSON) $.parseJSON = JSON.parse + + // Populate the class2type map + $.each("Boolean Number String Function Array Date RegExp Object Error".split(" "), function(i, name) { + class2type[ "[object " + name + "]" ] = name.toLowerCase() + }) + + // Define methods that will be available on all + // Zepto collections + $.fn = { + constructor: zepto.Z, + length: 0, + + // Because a collection acts like an array + // copy over these useful array functions. + forEach: emptyArray.forEach, + reduce: emptyArray.reduce, + push: emptyArray.push, + sort: emptyArray.sort, + splice: emptyArray.splice, + indexOf: emptyArray.indexOf, + concat: function(){ + var i, value, args = [] + for (i = 0; i < arguments.length; i++) { + value = arguments[i] + args[i] = zepto.isZ(value) ? value.toArray() : value + } + return concat.apply(zepto.isZ(this) ? this.toArray() : this, args) + }, + + // `map` and `slice` in the jQuery API work differently + // from their array counterparts + map: function(fn){ + return $($.map(this, function(el, i){ return fn.call(el, i, el) })) + }, + slice: function(){ + return $(slice.apply(this, arguments)) + }, + + ready: function(callback){ + // need to check if document.body exists for IE as that browser reports + // document ready when it hasn't yet created the body element + if (readyRE.test(document.readyState) && document.body) callback($) + else document.addEventListener('DOMContentLoaded', function(){ callback($) }, false) + return this + }, + get: function(idx){ + return idx === undefined ? slice.call(this) : this[idx >= 0 ? idx : idx + this.length] + }, + toArray: function(){ return this.get() }, + size: function(){ + return this.length + }, + remove: function(){ + return this.each(function(){ + if (this.parentNode != null) + this.parentNode.removeChild(this) + }) + }, + each: function(callback){ + emptyArray.every.call(this, function(el, idx){ + return callback.call(el, idx, el) !== false + }) + return this + }, + filter: function(selector){ + if (isFunction(selector)) return this.not(this.not(selector)) + return $(filter.call(this, function(element){ + return zepto.matches(element, selector) + })) + }, + add: function(selector,context){ + return $(uniq(this.concat($(selector,context)))) + }, + is: function(selector){ + return this.length > 0 && zepto.matches(this[0], selector) + }, + not: function(selector){ + var nodes=[] + if (isFunction(selector) && selector.call !== undefined) + this.each(function(idx){ + if (!selector.call(this,idx)) nodes.push(this) + }) + else { + var excludes = typeof selector == 'string' ? this.filter(selector) : + (likeArray(selector) && isFunction(selector.item)) ? slice.call(selector) : $(selector) + this.forEach(function(el){ + if (excludes.indexOf(el) < 0) nodes.push(el) + }) + } + return $(nodes) + }, + has: function(selector){ + return this.filter(function(){ + return isObject(selector) ? + $.contains(this, selector) : + $(this).find(selector).size() + }) + }, + eq: function(idx){ + return idx === -1 ? this.slice(idx) : this.slice(idx, + idx + 1) + }, + first: function(){ + var el = this[0] + return el && !isObject(el) ? el : $(el) + }, + last: function(){ + var el = this[this.length - 1] + return el && !isObject(el) ? el : $(el) + }, + find: function(selector){ + var result, $this = this + if (!selector) result = $() + else if (typeof selector == 'object') + result = $(selector).filter(function(){ + var node = this + return emptyArray.some.call($this, function(parent){ + return $.contains(parent, node) + }) + }) + else if (this.length == 1) result = $(zepto.qsa(this[0], selector)) + else result = this.map(function(){ return zepto.qsa(this, selector) }) + return result + }, + closest: function(selector, context){ + var node = this[0], collection = false + if (typeof selector == 'object') collection = $(selector) + while (node && !(collection ? collection.indexOf(node) >= 0 : zepto.matches(node, selector))) + node = node !== context && !isDocument(node) && node.parentNode + return $(node) + }, + parents: function(selector){ + var ancestors = [], nodes = this + while (nodes.length > 0) + nodes = $.map(nodes, function(node){ + if ((node = node.parentNode) && !isDocument(node) && ancestors.indexOf(node) < 0) { + ancestors.push(node) + return node + } + }) + return filtered(ancestors, selector) + }, + parent: function(selector){ + return filtered(uniq(this.pluck('parentNode')), selector) + }, + children: function(selector){ + return filtered(this.map(function(){ return children(this) }), selector) + }, + contents: function() { + return this.map(function() { return this.contentDocument || slice.call(this.childNodes) }) + }, + siblings: function(selector){ + return filtered(this.map(function(i, el){ + return filter.call(children(el.parentNode), function(child){ return child!==el }) + }), selector) + }, + empty: function(){ + return this.each(function(){ this.innerHTML = '' }) + }, + // `pluck` is borrowed from Prototype.js + pluck: function(property){ + return $.map(this, function(el){ return el[property] }) + }, + show: function(){ + return this.each(function(){ + this.style.display == "none" && (this.style.display = '') + if (getComputedStyle(this, '').getPropertyValue("display") == "none") + this.style.display = defaultDisplay(this.nodeName) + }) + }, + replaceWith: function(newContent){ + return this.before(newContent).remove() + }, + wrap: function(structure){ + var func = isFunction(structure) + if (this[0] && !func) + var dom = $(structure).get(0), + clone = dom.parentNode || this.length > 1 + + return this.each(function(index){ + $(this).wrapAll( + func ? structure.call(this, index) : + clone ? dom.cloneNode(true) : dom + ) + }) + }, + wrapAll: function(structure){ + if (this[0]) { + $(this[0]).before(structure = $(structure)) + var children + // drill down to the inmost element + while ((children = structure.children()).length) structure = children.first() + $(structure).append(this) + } + return this + }, + wrapInner: function(structure){ + var func = isFunction(structure) + return this.each(function(index){ + var self = $(this), contents = self.contents(), + dom = func ? structure.call(this, index) : structure + contents.length ? contents.wrapAll(dom) : self.append(dom) + }) + }, + unwrap: function(){ + this.parent().each(function(){ + $(this).replaceWith($(this).children()) + }) + return this + }, + clone: function(){ + return this.map(function(){ return this.cloneNode(true) }) + }, + hide: function(){ + return this.css("display", "none") + }, + toggle: function(setting){ + return this.each(function(){ + var el = $(this) + ;(setting === undefined ? el.css("display") == "none" : setting) ? el.show() : el.hide() + }) + }, + prev: function(selector){ return $(this.pluck('previousElementSibling')).filter(selector || '*') }, + next: function(selector){ return $(this.pluck('nextElementSibling')).filter(selector || '*') }, + html: function(html){ + return 0 in arguments ? + this.each(function(idx){ + var originHtml = this.innerHTML + $(this).empty().append( funcArg(this, html, idx, originHtml) ) + }) : + (0 in this ? this[0].innerHTML : null) + }, + text: function(text){ + return 0 in arguments ? + this.each(function(idx){ + var newText = funcArg(this, text, idx, this.textContent) + this.textContent = newText == null ? '' : ''+newText + }) : + (0 in this ? this[0].textContent : null) + }, + attr: function(name, value){ + var result + return (typeof name == 'string' && !(1 in arguments)) ? + (!this.length || this[0].nodeType !== 1 ? undefined : + (!(result = this[0].getAttribute(name)) && name in this[0]) ? this[0][name] : result + ) : + this.each(function(idx){ + if (this.nodeType !== 1) return + if (isObject(name)) for (key in name) setAttribute(this, key, name[key]) + else setAttribute(this, name, funcArg(this, value, idx, this.getAttribute(name))) + }) + }, + removeAttr: function(name){ + return this.each(function(){ this.nodeType === 1 && name.split(' ').forEach(function(attribute){ + setAttribute(this, attribute) + }, this)}) + }, + prop: function(name, value){ + name = propMap[name] || name + return (1 in arguments) ? + this.each(function(idx){ + this[name] = funcArg(this, value, idx, this[name]) + }) : + (this[0] && this[0][name]) + }, + data: function(name, value){ + var attrName = 'data-' + name.replace(capitalRE, '-$1').toLowerCase() + + var data = (1 in arguments) ? + this.attr(attrName, value) : + this.attr(attrName) + + return data !== null ? deserializeValue(data) : undefined + }, + val: function(value){ + return 0 in arguments ? + this.each(function(idx){ + this.value = funcArg(this, value, idx, this.value) + }) : + (this[0] && (this[0].multiple ? + $(this[0]).find('option').filter(function(){ return this.selected }).pluck('value') : + this[0].value) + ) + }, + offset: function(coordinates){ + if (coordinates) return this.each(function(index){ + var $this = $(this), + coords = funcArg(this, coordinates, index, $this.offset()), + parentOffset = $this.offsetParent().offset(), + props = { + top: coords.top - parentOffset.top, + left: coords.left - parentOffset.left + } + + if ($this.css('position') == 'static') props['position'] = 'relative' + $this.css(props) + }) + if (!this.length) return null + if (!$.contains(document.documentElement, this[0])) + return {top: 0, left: 0} + var obj = this[0].getBoundingClientRect() + return { + left: obj.left + window.pageXOffset, + top: obj.top + window.pageYOffset, + width: Math.round(obj.width), + height: Math.round(obj.height) + } + }, + css: function(property, value){ + if (arguments.length < 2) { + var computedStyle, element = this[0] + if(!element) return + computedStyle = getComputedStyle(element, '') + if (typeof property == 'string') + return element.style[camelize(property)] || computedStyle.getPropertyValue(property) + else if (isArray(property)) { + var props = {} + $.each(property, function(_, prop){ + props[prop] = (element.style[camelize(prop)] || computedStyle.getPropertyValue(prop)) + }) + return props + } + } + + var css = '' + if (type(property) == 'string') { + if (!value && value !== 0) + this.each(function(){ this.style.removeProperty(dasherize(property)) }) + else + css = dasherize(property) + ":" + maybeAddPx(property, value) + } else { + for (key in property) + if (!property[key] && property[key] !== 0) + this.each(function(){ this.style.removeProperty(dasherize(key)) }) + else + css += dasherize(key) + ':' + maybeAddPx(key, property[key]) + ';' + } + + return this.each(function(){ this.style.cssText += ';' + css }) + }, + index: function(element){ + return element ? this.indexOf($(element)[0]) : this.parent().children().indexOf(this[0]) + }, + hasClass: function(name){ + if (!name) return false + return emptyArray.some.call(this, function(el){ + return this.test(className(el)) + }, classRE(name)) + }, + addClass: function(name){ + if (!name) return this + return this.each(function(idx){ + if (!('className' in this)) return + classList = [] + var cls = className(this), newName = funcArg(this, name, idx, cls) + newName.split(/\s+/g).forEach(function(klass){ + if (!$(this).hasClass(klass)) classList.push(klass) + }, this) + classList.length && className(this, cls + (cls ? " " : "") + classList.join(" ")) + }) + }, + removeClass: function(name){ + return this.each(function(idx){ + if (!('className' in this)) return + if (name === undefined) return className(this, '') + classList = className(this) + funcArg(this, name, idx, classList).split(/\s+/g).forEach(function(klass){ + classList = classList.replace(classRE(klass), " ") + }) + className(this, classList.trim()) + }) + }, + toggleClass: function(name, when){ + if (!name) return this + return this.each(function(idx){ + var $this = $(this), names = funcArg(this, name, idx, className(this)) + names.split(/\s+/g).forEach(function(klass){ + (when === undefined ? !$this.hasClass(klass) : when) ? + $this.addClass(klass) : $this.removeClass(klass) + }) + }) + }, + scrollTop: function(value){ + if (!this.length) return + var hasScrollTop = 'scrollTop' in this[0] + if (value === undefined) return hasScrollTop ? this[0].scrollTop : this[0].pageYOffset + return this.each(hasScrollTop ? + function(){ this.scrollTop = value } : + function(){ this.scrollTo(this.scrollX, value) }) + }, + scrollLeft: function(value){ + if (!this.length) return + var hasScrollLeft = 'scrollLeft' in this[0] + if (value === undefined) return hasScrollLeft ? this[0].scrollLeft : this[0].pageXOffset + return this.each(hasScrollLeft ? + function(){ this.scrollLeft = value } : + function(){ this.scrollTo(value, this.scrollY) }) + }, + position: function() { + if (!this.length) return + + var elem = this[0], + // Get *real* offsetParent + offsetParent = this.offsetParent(), + // Get correct offsets + offset = this.offset(), + parentOffset = rootNodeRE.test(offsetParent[0].nodeName) ? { top: 0, left: 0 } : offsetParent.offset() + + // Subtract element margins + // note: when an element has margin: auto the offsetLeft and marginLeft + // are the same in Safari causing offset.left to incorrectly be 0 + offset.top -= parseFloat( $(elem).css('margin-top') ) || 0 + offset.left -= parseFloat( $(elem).css('margin-left') ) || 0 + + // Add offsetParent borders + parentOffset.top += parseFloat( $(offsetParent[0]).css('border-top-width') ) || 0 + parentOffset.left += parseFloat( $(offsetParent[0]).css('border-left-width') ) || 0 + + // Subtract the two offsets + return { + top: offset.top - parentOffset.top, + left: offset.left - parentOffset.left + } + }, + offsetParent: function() { + return this.map(function(){ + var parent = this.offsetParent || document.body + while (parent && !rootNodeRE.test(parent.nodeName) && $(parent).css("position") == "static") + parent = parent.offsetParent + return parent + }) + } + } + + // for now + $.fn.detach = $.fn.remove + + // Generate the `width` and `height` functions + ;['width', 'height'].forEach(function(dimension){ + var dimensionProperty = + dimension.replace(/./, function(m){ return m[0].toUpperCase() }) + + $.fn[dimension] = function(value){ + var offset, el = this[0] + if (value === undefined) return isWindow(el) ? el['inner' + dimensionProperty] : + isDocument(el) ? el.documentElement['scroll' + dimensionProperty] : + (offset = this.offset()) && offset[dimension] + else return this.each(function(idx){ + el = $(this) + el.css(dimension, funcArg(this, value, idx, el[dimension]())) + }) + } + }) + + function traverseNode(node, fun) { + fun(node) + for (var i = 0, len = node.childNodes.length; i < len; i++) + traverseNode(node.childNodes[i], fun) + } + + // Generate the `after`, `prepend`, `before`, `append`, + // `insertAfter`, `insertBefore`, `appendTo`, and `prependTo` methods. + adjacencyOperators.forEach(function(operator, operatorIndex) { + var inside = operatorIndex % 2 //=> prepend, append + + $.fn[operator] = function(){ + // arguments can be nodes, arrays of nodes, Zepto objects and HTML strings + var argType, nodes = $.map(arguments, function(arg) { + argType = type(arg) + return argType == "object" || argType == "array" || arg == null ? + arg : zepto.fragment(arg) + }), + parent, copyByClone = this.length > 1 + if (nodes.length < 1) return this + + return this.each(function(_, target){ + parent = inside ? target : target.parentNode + + // convert all methods to a "before" operation + target = operatorIndex == 0 ? target.nextSibling : + operatorIndex == 1 ? target.firstChild : + operatorIndex == 2 ? target : + null + + var parentInDocument = $.contains(document.documentElement, parent) + + nodes.forEach(function(node){ + if (copyByClone) node = node.cloneNode(true) + else if (!parent) return $(node).remove() + + parent.insertBefore(node, target) + if (parentInDocument) traverseNode(node, function(el){ + if (el.nodeName != null && el.nodeName.toUpperCase() === 'SCRIPT' && + (!el.type || el.type === 'text/javascript') && !el.src) + window['eval'].call(window, el.innerHTML) + }) + }) + }) + } + + // after => insertAfter + // prepend => prependTo + // before => insertBefore + // append => appendTo + $.fn[inside ? operator+'To' : 'insert'+(operatorIndex ? 'Before' : 'After')] = function(html){ + $(html)[operator](this) + return this + } + }) + + zepto.Z.prototype = Z.prototype = $.fn + + // Export internal API functions in the `$.zepto` namespace + zepto.uniq = uniq + zepto.deserializeValue = deserializeValue + $.zepto = zepto + + return $ +})() + +// If `$` is not yet defined, point it to `Zepto` +window.Zepto = Zepto +window.$ === undefined && (window.$ = Zepto) + +// Zepto.js +// (c) 2010-2015 Thomas Fuchs +// Zepto.js may be freely distributed under the MIT license. + +;(function($){ + var _zid = 1, undefined, + slice = Array.prototype.slice, + isFunction = $.isFunction, + isString = function(obj){ return typeof obj == 'string' }, + handlers = {}, + specialEvents={}, + focusinSupported = 'onfocusin' in window, + focus = { focus: 'focusin', blur: 'focusout' }, + hover = { mouseenter: 'mouseover', mouseleave: 'mouseout' } + + specialEvents.click = specialEvents.mousedown = specialEvents.mouseup = specialEvents.mousemove = 'MouseEvents' + + function zid(element) { + return element._zid || (element._zid = _zid++) + } + function findHandlers(element, event, fn, selector) { + event = parse(event) + if (event.ns) var matcher = matcherFor(event.ns) + return (handlers[zid(element)] || []).filter(function(handler) { + return handler + && (!event.e || handler.e == event.e) + && (!event.ns || matcher.test(handler.ns)) + && (!fn || zid(handler.fn) === zid(fn)) + && (!selector || handler.sel == selector) + }) + } + function parse(event) { + var parts = ('' + event).split('.') + return {e: parts[0], ns: parts.slice(1).sort().join(' ')} + } + function matcherFor(ns) { + return new RegExp('(?:^| )' + ns.replace(' ', ' .* ?') + '(?: |$)') + } + + function eventCapture(handler, captureSetting) { + return handler.del && + (!focusinSupported && (handler.e in focus)) || + !!captureSetting + } + + function realEvent(type) { + return hover[type] || (focusinSupported && focus[type]) || type + } + + function add(element, events, fn, data, selector, delegator, capture){ + var id = zid(element), set = (handlers[id] || (handlers[id] = [])) + events.split(/\s/).forEach(function(event){ + if (event == 'ready') return $(document).ready(fn) + var handler = parse(event) + handler.fn = fn + handler.sel = selector + // emulate mouseenter, mouseleave + if (handler.e in hover) fn = function(e){ + var related = e.relatedTarget + if (!related || (related !== this && !$.contains(this, related))) + return handler.fn.apply(this, arguments) + } + handler.del = delegator + var callback = delegator || fn + handler.proxy = function(e){ + e = compatible(e) + if (e.isImmediatePropagationStopped()) return + e.data = data + var result = callback.apply(element, e._args == undefined ? [e] : [e].concat(e._args)) + if (result === false) e.preventDefault(), e.stopPropagation() + return result + } + handler.i = set.length + set.push(handler) + if ('addEventListener' in element) + element.addEventListener(realEvent(handler.e), handler.proxy, eventCapture(handler, capture)) + }) + } + function remove(element, events, fn, selector, capture){ + var id = zid(element) + ;(events || '').split(/\s/).forEach(function(event){ + findHandlers(element, event, fn, selector).forEach(function(handler){ + delete handlers[id][handler.i] + if ('removeEventListener' in element) + element.removeEventListener(realEvent(handler.e), handler.proxy, eventCapture(handler, capture)) + }) + }) + } + + $.event = { add: add, remove: remove } + + $.proxy = function(fn, context) { + var args = (2 in arguments) && slice.call(arguments, 2) + if (isFunction(fn)) { + var proxyFn = function(){ return fn.apply(context, args ? args.concat(slice.call(arguments)) : arguments) } + proxyFn._zid = zid(fn) + return proxyFn + } else if (isString(context)) { + if (args) { + args.unshift(fn[context], fn) + return $.proxy.apply(null, args) + } else { + return $.proxy(fn[context], fn) + } + } else { + throw new TypeError("expected function") + } + } + + $.fn.bind = function(event, data, callback){ + return this.on(event, data, callback) + } + $.fn.unbind = function(event, callback){ + return this.off(event, callback) + } + $.fn.one = function(event, selector, data, callback){ + return this.on(event, selector, data, callback, 1) + } + + var returnTrue = function(){return true}, + returnFalse = function(){return false}, + ignoreProperties = /^([A-Z]|returnValue$|layer[XY]$)/, + eventMethods = { + preventDefault: 'isDefaultPrevented', + stopImmediatePropagation: 'isImmediatePropagationStopped', + stopPropagation: 'isPropagationStopped' + } + + function compatible(event, source) { + if (source || !event.isDefaultPrevented) { + source || (source = event) + + $.each(eventMethods, function(name, predicate) { + var sourceMethod = source[name] + event[name] = function(){ + this[predicate] = returnTrue + return sourceMethod && sourceMethod.apply(source, arguments) + } + event[predicate] = returnFalse + }) + + if (source.defaultPrevented !== undefined ? source.defaultPrevented : + 'returnValue' in source ? source.returnValue === false : + source.getPreventDefault && source.getPreventDefault()) + event.isDefaultPrevented = returnTrue + } + return event + } + + function createProxy(event) { + var key, proxy = { originalEvent: event } + for (key in event) + if (!ignoreProperties.test(key) && event[key] !== undefined) proxy[key] = event[key] + + return compatible(proxy, event) + } + + $.fn.delegate = function(selector, event, callback){ + return this.on(event, selector, callback) + } + $.fn.undelegate = function(selector, event, callback){ + return this.off(event, selector, callback) + } + + $.fn.live = function(event, callback){ + $(document.body).delegate(this.selector, event, callback) + return this + } + $.fn.die = function(event, callback){ + $(document.body).undelegate(this.selector, event, callback) + return this + } + + $.fn.on = function(event, selector, data, callback, one){ + var autoRemove, delegator, $this = this + if (event && !isString(event)) { + $.each(event, function(type, fn){ + $this.on(type, selector, data, fn, one) + }) + return $this + } + + if (!isString(selector) && !isFunction(callback) && callback !== false) + callback = data, data = selector, selector = undefined + if (callback === undefined || data === false) + callback = data, data = undefined + + if (callback === false) callback = returnFalse + + return $this.each(function(_, element){ + if (one) autoRemove = function(e){ + remove(element, e.type, callback) + return callback.apply(this, arguments) + } + + if (selector) delegator = function(e){ + var evt, match = $(e.target).closest(selector, element).get(0) + if (match && match !== element) { + evt = $.extend(createProxy(e), {currentTarget: match, liveFired: element}) + return (autoRemove || callback).apply(match, [evt].concat(slice.call(arguments, 1))) + } + } + + add(element, event, callback, data, selector, delegator || autoRemove) + }) + } + $.fn.off = function(event, selector, callback){ + var $this = this + if (event && !isString(event)) { + $.each(event, function(type, fn){ + $this.off(type, selector, fn) + }) + return $this + } + + if (!isString(selector) && !isFunction(callback) && callback !== false) + callback = selector, selector = undefined + + if (callback === false) callback = returnFalse + + return $this.each(function(){ + remove(this, event, callback, selector) + }) + } + + $.fn.trigger = function(event, args){ + event = (isString(event) || $.isPlainObject(event)) ? $.Event(event) : compatible(event) + event._args = args + return this.each(function(){ + // handle focus(), blur() by calling them directly + if (event.type in focus && typeof this[event.type] == "function") this[event.type]() + // items in the collection might not be DOM elements + else if ('dispatchEvent' in this) this.dispatchEvent(event) + else $(this).triggerHandler(event, args) + }) + } + + // triggers event handlers on current element just as if an event occurred, + // doesn't trigger an actual event, doesn't bubble + $.fn.triggerHandler = function(event, args){ + var e, result + this.each(function(i, element){ + e = createProxy(isString(event) ? $.Event(event) : event) + e._args = args + e.target = element + $.each(findHandlers(element, event.type || event), function(i, handler){ + result = handler.proxy(e) + if (e.isImmediatePropagationStopped()) return false + }) + }) + return result + } + + // shortcut methods for `.bind(event, fn)` for each event type + ;('focusin focusout focus blur load resize scroll unload click dblclick '+ + 'mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave '+ + 'change select keydown keypress keyup error').split(' ').forEach(function(event) { + $.fn[event] = function(callback) { + return (0 in arguments) ? + this.bind(event, callback) : + this.trigger(event) + } + }) + + $.Event = function(type, props) { + if (!isString(type)) props = type, type = props.type + var event = document.createEvent(specialEvents[type] || 'Events'), bubbles = true + if (props) for (var name in props) (name == 'bubbles') ? (bubbles = !!props[name]) : (event[name] = props[name]) + event.initEvent(type, bubbles, true) + return compatible(event) + } + +})(Zepto) + +// Zepto.js +// (c) 2010-2015 Thomas Fuchs +// Zepto.js may be freely distributed under the MIT license. + +;(function($){ + var touch = {}, + touchTimeout, tapTimeout, swipeTimeout, longTapTimeout, + longTapDelay = 750, + gesture + + function swipeDirection(x1, x2, y1, y2) { + return Math.abs(x1 - x2) >= + Math.abs(y1 - y2) ? (x1 - x2 > 0 ? 'Left' : 'Right') : (y1 - y2 > 0 ? 'Up' : 'Down') + } + + function longTap() { + longTapTimeout = null + if (touch.last) { + touch.el.trigger('longTap') + touch = {} + } + } + + function cancelLongTap() { + if (longTapTimeout) clearTimeout(longTapTimeout) + longTapTimeout = null + } + + function cancelAll() { + if (touchTimeout) clearTimeout(touchTimeout) + if (tapTimeout) clearTimeout(tapTimeout) + if (swipeTimeout) clearTimeout(swipeTimeout) + if (longTapTimeout) clearTimeout(longTapTimeout) + touchTimeout = tapTimeout = swipeTimeout = longTapTimeout = null + touch = {} + } + + function isPrimaryTouch(event){ + return (event.pointerType == 'touch' || + event.pointerType == event.MSPOINTER_TYPE_TOUCH) + && event.isPrimary + } + + function isPointerEventType(e, type){ + return (e.type == 'pointer'+type || + e.type.toLowerCase() == 'mspointer'+type) + } + + $(document).ready(function(){ + var now, delta, deltaX = 0, deltaY = 0, firstTouch, _isPointerType + + if ('MSGesture' in window) { + gesture = new MSGesture() + gesture.target = document.body + } + + $(document) + .bind('MSGestureEnd', function(e){ + var swipeDirectionFromVelocity = + e.velocityX > 1 ? 'Right' : e.velocityX < -1 ? 'Left' : e.velocityY > 1 ? 'Down' : e.velocityY < -1 ? 'Up' : null; + if (swipeDirectionFromVelocity) { + touch.el.trigger('swipe') + touch.el.trigger('swipe'+ swipeDirectionFromVelocity) + } + }) + .on('touchstart MSPointerDown pointerdown', function(e){ + if((_isPointerType = isPointerEventType(e, 'down')) && + !isPrimaryTouch(e)) return + firstTouch = _isPointerType ? e : e.touches[0] + if (e.touches && e.touches.length === 1 && touch.x2) { + // Clear out touch movement data if we have it sticking around + // This can occur if touchcancel doesn't fire due to preventDefault, etc. + touch.x2 = undefined + touch.y2 = undefined + } + now = Date.now() + delta = now - (touch.last || now) + touch.el = $('tagName' in firstTouch.target ? + firstTouch.target : firstTouch.target.parentNode) + touchTimeout && clearTimeout(touchTimeout) + touch.x1 = firstTouch.pageX + touch.y1 = firstTouch.pageY + if (delta > 0 && delta <= 250) touch.isDoubleTap = true + touch.last = now + longTapTimeout = setTimeout(longTap, longTapDelay) + // adds the current touch contact for IE gesture recognition + if (gesture && _isPointerType) gesture.addPointer(e.pointerId); + }) + .on('touchmove MSPointerMove pointermove', function(e){ + if((_isPointerType = isPointerEventType(e, 'move')) && + !isPrimaryTouch(e)) return + firstTouch = _isPointerType ? e : e.touches[0] + cancelLongTap() + touch.x2 = firstTouch.pageX + touch.y2 = firstTouch.pageY + + deltaX += Math.abs(touch.x1 - touch.x2) + deltaY += Math.abs(touch.y1 - touch.y2) + }) + .on('touchend MSPointerUp pointerup', function(e){ + if((_isPointerType = isPointerEventType(e, 'up')) && + !isPrimaryTouch(e)) return + cancelLongTap() + + // swipe + if ((touch.x2 && Math.abs(touch.x1 - touch.x2) > 30) || + (touch.y2 && Math.abs(touch.y1 - touch.y2) > 30)) + + swipeTimeout = setTimeout(function() { + touch.el.trigger('swipe') + touch.el.trigger('swipe' + (swipeDirection(touch.x1, touch.x2, touch.y1, touch.y2))) + touch = {} + }, 0) + + // normal tap + else if ('last' in touch) + // don't fire tap when delta position changed by more than 30 pixels, + // for instance when moving to a point and back to origin + if (deltaX < 30 && deltaY < 30) { + // delay by one tick so we can cancel the 'tap' event if 'scroll' fires + // ('tap' fires before 'scroll') + tapTimeout = setTimeout(function() { + + // trigger universal 'tap' with the option to cancelTouch() + // (cancelTouch cancels processing of single vs double taps for faster 'tap' response) + var event = $.Event('tap') + event.cancelTouch = cancelAll + touch.el.trigger(event) + + // trigger double tap immediately + if (touch.isDoubleTap) { + if (touch.el) touch.el.trigger('doubleTap') + touch = {} + } + + // trigger single tap after 250ms of inactivity + else { + touchTimeout = setTimeout(function(){ + touchTimeout = null + if (touch.el) touch.el.trigger('singleTap') + touch = {} + }, 250) + } + }, 0) + } else { + touch = {} + } + deltaX = deltaY = 0 + + }) + // when the browser window loses focus, + // for example when a modal dialog is shown, + // cancel all ongoing events + .on('touchcancel MSPointerCancel pointercancel', cancelAll) + + // scrolling the window indicates intention of the user + // to scroll, not tap or swipe, so cancel all ongoing events + $(window).on('scroll', cancelAll) + }) + + ;['swipe', 'swipeLeft', 'swipeRight', 'swipeUp', 'swipeDown', + 'doubleTap', 'tap', 'singleTap', 'longTap'].forEach(function(eventName){ + $.fn[eventName] = function(callback){ return this.on(eventName, callback) } + }) +})(Zepto) + +// Zepto.js +// (c) 2010-2015 Thomas Fuchs +// Zepto.js may be freely distributed under the MIT license. + +;(function($){ + var jsonpID = 0, + document = window.document, + key, + name, + rscript = /)<[^<]*)*<\/script>/gi, + scriptTypeRE = /^(?:text|application)\/javascript/i, + xmlTypeRE = /^(?:text|application)\/xml/i, + jsonType = 'application/json', + htmlType = 'text/html', + blankRE = /^\s*$/, + originAnchor = document.createElement('a') + + originAnchor.href = window.location.href + + // trigger a custom event and return false if it was cancelled + function triggerAndReturn(context, eventName, data) { + var event = $.Event(eventName) + $(context).trigger(event, data) + return !event.isDefaultPrevented() + } + + // trigger an Ajax "global" event + function triggerGlobal(settings, context, eventName, data) { + if (settings.global) return triggerAndReturn(context || document, eventName, data) + } + + // Number of active Ajax requests + $.active = 0 + + function ajaxStart(settings) { + if (settings.global && $.active++ === 0) triggerGlobal(settings, null, 'ajaxStart') + } + function ajaxStop(settings) { + if (settings.global && !(--$.active)) triggerGlobal(settings, null, 'ajaxStop') + } + + // triggers an extra global event "ajaxBeforeSend" that's like "ajaxSend" but cancelable + function ajaxBeforeSend(xhr, settings) { + var context = settings.context + if (settings.beforeSend.call(context, xhr, settings) === false || + triggerGlobal(settings, context, 'ajaxBeforeSend', [xhr, settings]) === false) + return false + + triggerGlobal(settings, context, 'ajaxSend', [xhr, settings]) + } + function ajaxSuccess(data, xhr, settings, deferred) { + var context = settings.context, status = 'success' + settings.success.call(context, data, status, xhr) + if (deferred) deferred.resolveWith(context, [data, status, xhr]) + triggerGlobal(settings, context, 'ajaxSuccess', [xhr, settings, data]) + ajaxComplete(status, xhr, settings) + } + // type: "timeout", "error", "abort", "parsererror" + function ajaxError(error, type, xhr, settings, deferred) { + var context = settings.context + settings.error.call(context, xhr, type, error) + if (deferred) deferred.rejectWith(context, [xhr, type, error]) + triggerGlobal(settings, context, 'ajaxError', [xhr, settings, error || type]) + ajaxComplete(type, xhr, settings) + } + // status: "success", "notmodified", "error", "timeout", "abort", "parsererror" + function ajaxComplete(status, xhr, settings) { + var context = settings.context + settings.complete.call(context, xhr, status) + triggerGlobal(settings, context, 'ajaxComplete', [xhr, settings]) + ajaxStop(settings) + } + + // Empty function, used as default callback + function empty() {} + + $.ajaxJSONP = function(options, deferred){ + if (!('type' in options)) return $.ajax(options) + + var _callbackName = options.jsonpCallback, + callbackName = ($.isFunction(_callbackName) ? + _callbackName() : _callbackName) || ('jsonp' + (++jsonpID)), + script = document.createElement('script'), + originalCallback = window[callbackName], + responseData, + abort = function(errorType) { + $(script).triggerHandler('error', errorType || 'abort') + }, + xhr = { abort: abort }, abortTimeout + + if (deferred) deferred.promise(xhr) + + $(script).on('load error', function(e, errorType){ + clearTimeout(abortTimeout) + $(script).off().remove() + + if (e.type == 'error' || !responseData) { + ajaxError(null, errorType || 'error', xhr, options, deferred) + } else { + ajaxSuccess(responseData[0], xhr, options, deferred) + } + + window[callbackName] = originalCallback + if (responseData && $.isFunction(originalCallback)) + originalCallback(responseData[0]) + + originalCallback = responseData = undefined + }) + + if (ajaxBeforeSend(xhr, options) === false) { + abort('abort') + return xhr + } + + window[callbackName] = function(){ + responseData = arguments + } + + script.src = options.url.replace(/\?(.+)=\?/, '?$1=' + callbackName) + document.head.appendChild(script) + + if (options.timeout > 0) abortTimeout = setTimeout(function(){ + abort('timeout') + }, options.timeout) + + return xhr + } + + $.ajaxSettings = { + // Default type of request + type: 'GET', + // Callback that is executed before request + beforeSend: empty, + // Callback that is executed if the request succeeds + success: empty, + // Callback that is executed the the server drops error + error: empty, + // Callback that is executed on request complete (both: error and success) + complete: empty, + // The context for the callbacks + context: null, + // Whether to trigger "global" Ajax events + global: true, + // Transport + xhr: function () { + return new window.XMLHttpRequest() + }, + // MIME types mapping + // IIS returns Javascript as "application/x-javascript" + accepts: { + script: 'text/javascript, application/javascript, application/x-javascript', + json: jsonType, + xml: 'application/xml, text/xml', + html: htmlType, + text: 'text/plain' + }, + // Whether the request is to another domain + crossDomain: false, + // Default timeout + timeout: 0, + // Whether data should be serialized to string + processData: true, + // Whether the browser should be allowed to cache GET responses + cache: true + } + + function mimeToDataType(mime) { + if (mime) mime = mime.split(';', 2)[0] + return mime && ( mime == htmlType ? 'html' : + mime == jsonType ? 'json' : + scriptTypeRE.test(mime) ? 'script' : + xmlTypeRE.test(mime) && 'xml' ) || 'text' + } + + function appendQuery(url, query) { + if (query == '') return url + return (url + '&' + query).replace(/[&?]{1,2}/, '?') + } + + // serialize payload and append it to the URL for GET requests + function serializeData(options) { + if (options.processData && options.data && $.type(options.data) != "string") + options.data = $.param(options.data, options.traditional) + if (options.data && (!options.type || options.type.toUpperCase() == 'GET')) + options.url = appendQuery(options.url, options.data), options.data = undefined + } + + $.ajax = function(options){ + var settings = $.extend({}, options || {}), + deferred = $.Deferred && $.Deferred(), + urlAnchor, hashIndex + for (key in $.ajaxSettings) if (settings[key] === undefined) settings[key] = $.ajaxSettings[key] + + ajaxStart(settings) + + if (!settings.crossDomain) { + urlAnchor = document.createElement('a') + urlAnchor.href = settings.url + // cleans up URL for .href (IE only), see https://github.com/madrobby/zepto/pull/1049 + urlAnchor.href = urlAnchor.href + settings.crossDomain = (originAnchor.protocol + '//' + originAnchor.host) !== (urlAnchor.protocol + '//' + urlAnchor.host) + } + + if (!settings.url) settings.url = window.location.toString() + if ((hashIndex = settings.url.indexOf('#')) > -1) settings.url = settings.url.slice(0, hashIndex) + serializeData(settings) + + var dataType = settings.dataType, hasPlaceholder = /\?.+=\?/.test(settings.url) + if (hasPlaceholder) dataType = 'jsonp' + + if (settings.cache === false || ( + (!options || options.cache !== true) && + ('script' == dataType || 'jsonp' == dataType) + )) + settings.url = appendQuery(settings.url, '_=' + Date.now()) + + if ('jsonp' == dataType) { + if (!hasPlaceholder) + settings.url = appendQuery(settings.url, + settings.jsonp ? (settings.jsonp + '=?') : settings.jsonp === false ? '' : 'callback=?') + return $.ajaxJSONP(settings, deferred) + } + + var mime = settings.accepts[dataType], + headers = { }, + setHeader = function(name, value) { headers[name.toLowerCase()] = [name, value] }, + protocol = /^([\w-]+:)\/\//.test(settings.url) ? RegExp.$1 : window.location.protocol, + xhr = settings.xhr(), + nativeSetHeader = xhr.setRequestHeader, + abortTimeout + + if (deferred) deferred.promise(xhr) + + if (!settings.crossDomain) setHeader('X-Requested-With', 'XMLHttpRequest') + setHeader('Accept', mime || '*/*') + if (mime = settings.mimeType || mime) { + if (mime.indexOf(',') > -1) mime = mime.split(',', 2)[0] + xhr.overrideMimeType && xhr.overrideMimeType(mime) + } + if (settings.contentType || (settings.contentType !== false && settings.data && settings.type.toUpperCase() != 'GET')) + setHeader('Content-Type', settings.contentType || 'application/x-www-form-urlencoded') + + if (settings.headers) for (name in settings.headers) setHeader(name, settings.headers[name]) + xhr.setRequestHeader = setHeader + + xhr.onreadystatechange = function(){ + if (xhr.readyState == 4) { + xhr.onreadystatechange = empty + clearTimeout(abortTimeout) + var result, error = false + if ((xhr.status >= 200 && xhr.status < 300) || xhr.status == 304 || (xhr.status == 0 && protocol == 'file:')) { + dataType = dataType || mimeToDataType(settings.mimeType || xhr.getResponseHeader('content-type')) + result = xhr.responseText + + try { + // http://perfectionkills.com/global-eval-what-are-the-options/ + if (dataType == 'script') (1,eval)(result) + else if (dataType == 'xml') result = xhr.responseXML + else if (dataType == 'json') result = blankRE.test(result) ? null : $.parseJSON(result) + } catch (e) { error = e } + + if (error) ajaxError(error, 'parsererror', xhr, settings, deferred) + else ajaxSuccess(result, xhr, settings, deferred) + } else { + ajaxError(xhr.statusText || null, xhr.status ? 'error' : 'abort', xhr, settings, deferred) + } + } + } + + if (ajaxBeforeSend(xhr, settings) === false) { + xhr.abort() + ajaxError(null, 'abort', xhr, settings, deferred) + return xhr + } + + if (settings.xhrFields) for (name in settings.xhrFields) xhr[name] = settings.xhrFields[name] + + var async = 'async' in settings ? settings.async : true + xhr.open(settings.type, settings.url, async, settings.username, settings.password) + + for (name in headers) nativeSetHeader.apply(xhr, headers[name]) + + if (settings.timeout > 0) abortTimeout = setTimeout(function(){ + xhr.onreadystatechange = empty + xhr.abort() + ajaxError(null, 'timeout', xhr, settings, deferred) + }, settings.timeout) + + // avoid sending empty string (#319) + xhr.send(settings.data ? settings.data : null) + return xhr + } + + // handle optional data/success arguments + function parseArguments(url, data, success, dataType) { + if ($.isFunction(data)) dataType = success, success = data, data = undefined + if (!$.isFunction(success)) dataType = success, success = undefined + return { + url: url + , data: data + , success: success + , dataType: dataType + } + } + + $.get = function(/* url, data, success, dataType */){ + return $.ajax(parseArguments.apply(null, arguments)) + } + + $.post = function(/* url, data, success, dataType */){ + var options = parseArguments.apply(null, arguments) + options.type = 'POST' + return $.ajax(options) + } + + $.getJSON = function(/* url, data, success */){ + var options = parseArguments.apply(null, arguments) + options.dataType = 'json' + return $.ajax(options) + } + + $.fn.load = function(url, data, success){ + if (!this.length) return this + var self = this, parts = url.split(/\s/), selector, + options = parseArguments(url, data, success), + callback = options.success + if (parts.length > 1) options.url = parts[0], selector = parts[1] + options.success = function(response){ + self.html(selector ? + $('
').html(response.replace(rscript, "")).find(selector) + : response) + callback && callback.apply(self, arguments) + } + $.ajax(options) + return this + } + + var escape = encodeURIComponent + + function serialize(params, obj, traditional, scope){ + var type, array = $.isArray(obj), hash = $.isPlainObject(obj) + $.each(obj, function(key, value) { + type = $.type(value) + if (scope) key = traditional ? scope : + scope + '[' + (hash || type == 'object' || type == 'array' ? key : '') + ']' + // handle data in serializeArray() format + if (!scope && array) params.add(value.name, value.value) + // recurse into nested objects + else if (type == "array" || (!traditional && type == "object")) + serialize(params, value, traditional, key) + else params.add(key, value) + }) + } + + $.param = function(obj, traditional){ + var params = [] + params.add = function(key, value) { + if ($.isFunction(value)) value = value() + if (value == null) value = "" + this.push(escape(key) + '=' + escape(value)) + } + serialize(params, obj, traditional) + return params.join('&').replace(/%20/g, '+') + } +})(Zepto) + +// Zepto.js +// (c) 2010-2015 Thomas Fuchs +// Zepto.js may be freely distributed under the MIT license. + +;(function(){ + // getComputedStyle shouldn't freak out when called + // without a valid element as argument + try { + getComputedStyle(undefined) + } catch(e) { + var nativeGetComputedStyle = getComputedStyle; + window.getComputedStyle = function(element){ + try { + return nativeGetComputedStyle(element) + } catch(e) { + return null + } + } + } +})() + +// Zepto.js +// (c) 2010-2015 Thomas Fuchs +// Zepto.js may be freely distributed under the MIT license. + +;(function($){ + $.fn.serializeArray = function() { + var name, type, result = [], + add = function(value) { + if (value.forEach) return value.forEach(add) + result.push({ name: name, value: value }) + } + if (this[0]) $.each(this[0].elements, function(_, field){ + type = field.type, name = field.name + if (name && field.nodeName.toLowerCase() != 'fieldset' && + !field.disabled && type != 'submit' && type != 'reset' && type != 'button' && type != 'file' && + ((type != 'radio' && type != 'checkbox') || field.checked)) + add($(field).val()) + }) + return result + } + + $.fn.serialize = function(){ + var result = [] + this.serializeArray().forEach(function(elm){ + result.push(encodeURIComponent(elm.name) + '=' + encodeURIComponent(elm.value)) + }) + return result.join('&') + } + + $.fn.submit = function(callback) { + if (0 in arguments) this.bind('submit', callback) + else if (this.length) { + var event = $.Event('submit') + this.eq(0).trigger(event) + if (!event.isDefaultPrevented()) this.get(0).submit() + } + return this + } + +})(Zepto) diff --git a/routes/web.php b/routes/web.php index 2a6278c..acd7ed9 100644 --- a/routes/web.php +++ b/routes/web.php @@ -180,8 +180,9 @@ Route::group(['prefix' => 'fladmin', 'namespace' => 'Admin', 'middleware' => ['w }); //接口路由,无需token验证 -Route::group(['prefix' => 'dataapi', 'namespace' => 'Api', 'middleware' => ['web']], function () { - +Route::group(['middleware' => ['web']], function () { + Route::post('/dataapi/customer_login', 'Api\WechatAuthController@customerLogin'); + Route::post('/dataapi/', 'Api\UserController@signin'); //签到 }); //接口路由,需token验证